mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2025-02-17 04:49:55 +00:00
Add option to enable/disable libraries
This commit adds the option to enable/disable libraries from the library options editor. The backend changes required for this functionality are in jellyfin PR 11037. This commit adds a checkbox in the library options editor. It adds a checkbox saying "Library Enabled" that is checked by default. libraryoptionseditor.js - added logic to handle enable libraries checkbox. Enables libraries by default libraryoptionseditor.template.html - added "enable libraries" checkbox src/strings/en-us.json - added English strings for enable library checkbox.
This commit is contained in:
parent
6c8967110e
commit
60fc2c72b2
@ -79,6 +79,7 @@
|
||||
- [Kevin Tan (Valius)](https://github.com/valius)
|
||||
- [Rasmus Krämer](https://github.com/rasmuslos)
|
||||
- [ntarelix](https://github.com/ntarelix)
|
||||
- [btopherjohnson](https://github.com/btopherjohnson)
|
||||
|
||||
## Emby Contributors
|
||||
|
||||
|
@ -511,6 +511,7 @@ function setImageOptionsIntoOptions(options) {
|
||||
|
||||
export function getLibraryOptions(parent) {
|
||||
const options = {
|
||||
Disabled: !parent.querySelector('.chkEnabled').checked,
|
||||
EnableArchiveMediaFiles: false,
|
||||
EnablePhotos: parent.querySelector('.chkEnablePhotos').checked,
|
||||
EnableRealtimeMonitor: parent.querySelector('.chkEnableRealtimeMonitor').checked,
|
||||
@ -574,6 +575,7 @@ export function setLibraryOptions(parent, options) {
|
||||
parent.querySelector('#selectCountry').value = options.MetadataCountryCode || '';
|
||||
parent.querySelector('#selectAutoRefreshInterval').value = options.AutomaticRefreshIntervalDays || '0';
|
||||
parent.querySelector('#txtSeasonZeroName').value = options.SeasonZeroDisplayName || 'Specials';
|
||||
parent.querySelector('.chkEnabled').checked = !options.Disabled;
|
||||
parent.querySelector('.chkEnablePhotos').checked = options.EnablePhotos;
|
||||
parent.querySelector('.chkEnableRealtimeMonitor').checked = options.EnableRealtimeMonitor;
|
||||
parent.querySelector('.chkEnableLUFSScan').checked = options.EnableLUFSScan;
|
||||
|
@ -1,4 +1,12 @@
|
||||
<h2>${HeaderLibrarySettings}</h2>
|
||||
<div class="checkboxContainer checkboxContainer-withDescription chkEnable">
|
||||
<label>
|
||||
<input type="checkbox" is="emby-checkbox" class="chkEnabled" checked />
|
||||
<span>${EnableLibrary}</span>
|
||||
</label>
|
||||
<div class="fieldDescription checkboxFieldDescription">${EnableLibraryHelp}</div>
|
||||
</div>
|
||||
|
||||
<div class="selectContainer fldMetadataLanguage hide">
|
||||
<select is="emby-select" id="selectLanguage" label="${LabelMetadataDownloadLanguage}"></select>
|
||||
</div>
|
||||
|
@ -237,6 +237,8 @@
|
||||
"EnableFasterAnimations": "Faster animations",
|
||||
"EnableFasterAnimationsHelp": "Use faster animations and transitions.",
|
||||
"EnableHardwareEncoding": "Enable hardware encoding",
|
||||
"EnableLibrary": "Enable the library",
|
||||
"EnableLibraryHelp": "Allows the library to be enabled/disabled",
|
||||
"EnableNextVideoInfoOverlay": "Show next video info during playback",
|
||||
"EnableNextVideoInfoOverlayHelp": "At the end of a video, display info about the next video coming up in the current playlist.",
|
||||
"EnablePhotos": "Display the photos",
|
||||
|
Loading…
x
Reference in New Issue
Block a user