1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

update themes

This commit is contained in:
Luke Pulverenti 2017-10-23 02:01:49 -04:00
parent 90e4adb8c1
commit d788d58e92
11 changed files with 19 additions and 9 deletions

File diff suppressed because one or more lines are too long

View file

@ -78,6 +78,15 @@
<select id="selectTheme" is="emby-select" label="${LabelTheme}"></select>
<div class="fieldDescription">${FeatureRequiresEmbyPremiere}</div>
</div>
<div class="checkboxContainer checkboxContainer-withDescription">
<label>
<input type="checkbox" is="emby-checkbox" id="chkSeasonalThemes" />
<span>${AllowSeasonalThemes}</span>
</label>
<div class="fieldDescription checkboxFieldDescription">${AllowSeasonalThemesHelp}</div>
</div>
<div class="selectContainer selectDashboardThemeContainer hide">
<select id="selectDashboardTheme" is="emby-select" label="${LabelDashboardTheme}"></select>
<div class="fieldDescription">${FeatureRequiresEmbyPremiere}</div>

File diff suppressed because one or more lines are too long

View file

@ -599,5 +599,7 @@
"HeaderLatestMedia": "Latest Media",
"HeaderRestartingEmbyServer": "Restarting Emby Server",
"RestartPleaseWaitMessage": "Please wait while Emby Server shuts down and restarts. This may take a minute or two.",
"PlayNext": "Play next"
"PlayNext": "Play next",
"AllowSeasonalThemes": "Allow automatic seasonal themes",
"AllowSeasonalThemesHelp": "If enabled, seasonal themes will occasionally override your theme setting."
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 133 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -1 +1 @@
define(["userSettings","skinManager"],function(userSettings,skinManager){"use strict";pageClassOn("viewbeforeshow","page",function(){var viewType=this.getAttribute("data-theme");viewType||(viewType=this.classList.contains("type-interior")||this.classList.contains("wizardPage")?"a":"b",this.setAttribute("data-theme",viewType));var theme,context;"a"===viewType?(theme=userSettings.dashboardTheme(),context="serverdashboard"):theme=userSettings.theme(),skinManager.setTheme(theme,context)})});
define(["userSettings","skinManager"],function(userSettings,skinManager){"use strict";var currentViewType;pageClassOn("viewbeforeshow","page",function(){var viewType=this.getAttribute("data-theme");if(viewType||(viewType=this.classList.contains("type-interior")||this.classList.contains("wizardPage")?"a":"b"),viewType!==currentViewType){currentViewType=viewType;var theme,context;"a"===viewType?(theme=userSettings.dashboardTheme(),context="serverdashboard"):theme=userSettings.theme(),skinManager.setTheme(theme,context)}})});

View file

@ -1 +0,0 @@
define(["appSettings","backdrop","browser","globalize","require","paper-icon-button-light"],function(appSettings,backdrop,browser,globalize,require){"use strict";function onPageShow(){var page=this;if(!destroyed){if(appSettings.get(cancelKey)==cancelValue)return void(destroyed=!0);browser.mobile||(require(["css!./style.css"]),page.classList.contains("itemDetailPage")||backdrop.setBackdrop("themes/halloween/bg.jpg"),0==lastSound?playSound("http://github.com/MediaBrowser/Emby.Resources/raw/master/themes/halloween/monsterparadefade.mp3",.1):(new Date).getTime()-lastSound>3e4&&playSound("http://github.com/MediaBrowser/Emby.Resources/raw/master/themes/halloween/howl.wav"),addIcon())}}function addIcon(){if(!iconCreated){iconCreated=!0;var viewMenuSecondary=document.querySelector(".viewMenuSecondary");if(viewMenuSecondary){var html='<button is="paper-icon-button-light" class="halloweenInfoButton"><i class="md-icon">info</i></button>';viewMenuSecondary.insertAdjacentHTML("afterbegin",html),viewMenuSecondary.querySelector(".halloweenInfoButton").addEventListener("click",onIconClick)}}}function onIconClick(){require(["dialog"],function(dialog){dialog({title:"Happy Halloween",text:"Happy Halloween from the Emby Team. We hope your Halloween is spooktacular! Would you like to allow the Halloween theme to continue?",buttons:[{id:"yes",name:globalize.translate("ButtonYes"),type:"submit"},{id:"no",name:globalize.translate("ButtonNo"),type:"cancel"}]}).then(function(result){"no"==result&&destroyTheme()})})}function destroyTheme(){destroyed=!0;var halloweenInfoButton=document.querySelector(".halloweenInfoButton");halloweenInfoButton&&halloweenInfoButton.parentNode.removeChild(halloweenInfoButton),currentSound&&currentSound.stop(),backdrop.clear(),appSettings.set(cancelKey,cancelValue),window.location.reload(!0)}function playSound(path,volume){require(["howler"],function(howler){var sound=new Howl({urls:[path],volume:volume||.3});sound.play(),currentSound=sound,lastSound=(new Date).getTime()})}var iconCreated,destroyed,currentSound,lastSound=0,cancelKey="cancelHalloween2015",cancelValue="6";pageClassOn("pageshow","libraryPage",onPageShow)});