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

~ convert subtitlesettings to class

~ use base import name instead of relative file path
~ fix "new" calling

Signed-off-by: Christoph Potas <christoph286@googlemail.com>
This commit is contained in:
Christoph Potas 2020-05-04 03:20:38 +02:00
parent 257ce4974e
commit 6f0843cc6d
5 changed files with 97 additions and 46 deletions

View file

@ -0,0 +1,24 @@
import globalize from 'globalize';
/**
* Helper for handling settings
* @module components/settingsHelper
*/
export function populateLanguages(select, languages) {
let html = "";
html += "<option value=''>" + globalize.translate('AnyLanguage') + "</option>";
for (let i = 0, length = languages.length; i < length; i++) {
const culture = languages[i];
html += "<option value='" + culture.ThreeLetterISOLanguageName + "'>" + culture.DisplayName + "</option>";
}
select.innerHTML = html;
}
export default {
populateLanguages: populateLanguages
};