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

remove lyric fetcher management (not supported)

This commit is contained in:
Cody Robibero 2024-05-04 10:34:20 -06:00
parent 54fda13100
commit be4836ffd3
3 changed files with 0 additions and 49 deletions

View file

@ -213,39 +213,6 @@ function renderSubtitleFetchers(page, availableOptions, libraryOptions) {
elem.innerHTML = html;
}
function renderLyricFetchers(page, availableOptions, libraryOptions) {
let html = '';
const elem = page.querySelector('.lyricFetchers');
const plugins = availableOptions.LyricFetchers;
if (!plugins.length) return html;
html += `<h3 class="checkboxListLabel">${globalize.translate('LabelLyricDownloaders')}</h3>`;
html += '<div class="checkboxList paperList checkboxList-paperList">';
console.log(libraryOptions);
for (let i = 0; i < plugins.length; i++) {
const plugin = plugins[i];
html += `<div class="listItem lyricFetcherItem sortableOption" data-pluginname="${escapeHtml(plugin.Name)}">`;
const isChecked = libraryOptions.DisabledLyricFetchers ? !libraryOptions.DisabledLyricFetchers.includes(plugin.Name) : plugin.DefaultEnabled;
const checkedHtml = isChecked ? ' checked="checked"' : '';
html += `<label class="listItemCheckboxContainer"><input type="checkbox" is="emby-checkbox" class="chkLyricFetcher" data-pluginname="${escapeHtml(plugin.Name)}" ${checkedHtml}><span></span></label>`;
html += '<div class="listItemBody">';
html += '<h3 class="listItemBodyText">';
html += escapeHtml(plugin.Name);
html += '</h3>';
html += '</div>';
if (i > 0) {
html += `<button type="button" is="paper-icon-button-light" title="${globalize.translate('Up')}" class="btnSortableMoveUp btnSortable" data-pluginindex="${i}"><span class="material-icons keyboard_arrow_up" aria-hidden="true"></span></button>`;
} else if (plugins.length > 1) {
html += `<button type="button" is="paper-icon-button-light" title="${globalize.translate('Down')}" class="btnSortableMoveDown btnSortable" data-pluginindex="${i}"><span class="material-icons keyboard_arrow_down" aria-hidden="true"></span></button>`;
}
html += '</div>';
}
html += '</div>';
html += `<div class="fieldDescription">${globalize.translate('LyricDownloadersHelp')}</div>`;
elem.innerHTML = html;
}
function getImageFetchersForTypeHtml(availableTypeOptions, libraryOptionsForType) {
let html = '';
let plugins = availableTypeOptions.ImageFetchers;
@ -315,7 +282,6 @@ function populateMetadataSettings(parent, contentType) {
renderMetadataReaders(parent, availableOptions.MetadataReaders);
renderMetadataFetchers(parent, availableOptions, {});
renderSubtitleFetchers(parent, availableOptions, {});
renderLyricFetchers(parent, availableOptions, {});
renderImageFetchers(parent, availableOptions, {});
availableOptions.SubtitleFetchers.length ? parent.querySelector('.subtitleDownloadSettings').classList.remove('hide') : parent.querySelector('.subtitleDownloadSettings').classList.add('hide');
}).catch(() => {
@ -489,14 +455,6 @@ function setSubtitleFetchersIntoOptions(parent, options) {
});
}
function setLyricFetchersIntoOptions(parent, options) {
options.DisabledLyricFetchers = Array.prototype.map.call(Array.prototype.filter.call(parent.querySelectorAll('.chkLyricFetcher'), elem => {
return !elem.checked;
}), elem => {
return elem.getAttribute('data-pluginname');
});
}
function setMetadataFetchersIntoOptions(parent, options) {
const sections = parent.querySelectorAll('.metadataFetcher');
for (const section of sections) {
@ -604,7 +562,6 @@ export function getLibraryOptions(parent) {
return elem.getAttribute('data-lang');
});
setSubtitleFetchersIntoOptions(parent, options);
setLyricFetchersIntoOptions(parent, options);
setMetadataFetchersIntoOptions(parent, options);
setImageFetchersIntoOptions(parent, options);
setImageOptionsIntoOptions(options);
@ -660,7 +617,6 @@ export function setLibraryOptions(parent, options) {
renderMetadataFetchers(parent, parent.availableOptions, options);
renderImageFetchers(parent, parent.availableOptions, options);
renderSubtitleFetchers(parent, parent.availableOptions, options);
renderLyricFetchers(parent, parent.availableOptions, options);
}
let currentLibraryOptions;

View file

@ -197,9 +197,6 @@
<div class="lyricSettingsSection hide">
<h2>${Lyrics}</h2>
<div class="lyricFetchers advanced" style="margin-bottom: 2em;">
</div>
<div class="checkboxContainer checkboxContainer-withDescription advanced">
<label>
<input type="checkbox" is="emby-checkbox" id="chkSaveLyricsLocally" checked />

View file

@ -712,7 +712,6 @@
"LabelLoginDisclaimer": "Login disclaimer",
"LabelLoginDisclaimerHelp": "A message that will be displayed at the bottom of the login page.",
"LabelLogs": "Logs",
"LabelLyricDownloaders": "Lyric downloaders",
"LabelMaxAudiobookResume": "Audiobook remaining minutes to resume",
"LabelMaxAudiobookResumeHelp": "Titles are assumed fully played if stopped when the remaining duration is less than this value.",
"LabelMaxBackdropsPerItem": "Maximum number of backdrops per item",
@ -968,7 +967,6 @@
"Lyric": "Lyric",
"Lyricist": "Lyricist",
"Lyrics": "Lyrics",
"LyricDownloadersHelp": "Enable and rank your preferred subtitle downloaders in order of priority.",
"ManageLibrary": "Manage library",
"ManageRecording": "Manage recording",
"MapChannels": "Map Channels",