mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
rename more components and update references
This commit is contained in:
parent
35094da328
commit
1aaaffde4c
24 changed files with 23 additions and 23 deletions
37
src/components/appFooter/appFooter.js
Normal file
37
src/components/appFooter/appFooter.js
Normal file
|
@ -0,0 +1,37 @@
|
|||
define(['browser', 'css!./appFooter'], function (browser) {
|
||||
'use strict';
|
||||
|
||||
function render(options) {
|
||||
var elem = document.createElement('div');
|
||||
elem.classList.add('appfooter');
|
||||
|
||||
document.body.appendChild(elem);
|
||||
|
||||
return elem;
|
||||
}
|
||||
|
||||
function appFooter(options) {
|
||||
var self = this;
|
||||
|
||||
self.element = render(options);
|
||||
self.add = function (elem) {
|
||||
self.element.appendChild(elem);
|
||||
};
|
||||
|
||||
self.insert = function (elem) {
|
||||
if (typeof elem === 'string') {
|
||||
self.element.insertAdjacentHTML('afterbegin', elem);
|
||||
} else {
|
||||
self.element.insertBefore(elem, self.element.firstChild);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
appFooter.prototype.destroy = function () {
|
||||
var self = this;
|
||||
|
||||
self.element = null;
|
||||
};
|
||||
|
||||
return appFooter;
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue