mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2024-11-15 18:08:17 -07:00
Move class change handlers to init
This commit is contained in:
parent
4f2edf416a
commit
4af7fc6e3e
@ -58,6 +58,14 @@ build: ${__JF_BUILD_VERSION__}`);
|
||||
window.Events = Events;
|
||||
window.TaskButton = taskButton;
|
||||
|
||||
// Register handlers to update header classes
|
||||
pageClassOn('viewshow', 'standalonePage', function () {
|
||||
document.querySelector('.skinHeader').classList.add('noHeaderRight');
|
||||
});
|
||||
pageClassOn('viewhide', 'standalonePage', function () {
|
||||
document.querySelector('.skinHeader').classList.remove('noHeaderRight');
|
||||
});
|
||||
|
||||
// Initialize the api client
|
||||
const serverUrl = await serverAddress();
|
||||
if (serverUrl) {
|
||||
@ -253,11 +261,3 @@ async function renderApp() {
|
||||
}
|
||||
|
||||
init();
|
||||
|
||||
pageClassOn('viewshow', 'standalonePage', function () {
|
||||
document.querySelector('.skinHeader').classList.add('noHeaderRight');
|
||||
});
|
||||
|
||||
pageClassOn('viewhide', 'standalonePage', function () {
|
||||
document.querySelector('.skinHeader').classList.remove('noHeaderRight');
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user