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

remove eslint-enable indent

This commit is contained in:
grafixeyehero 2021-09-08 03:28:04 +03:00
parent d6c00aa6f4
commit 0cda86dfdd

View file

@ -10,22 +10,20 @@ import '../formdialog.scss';
import '../../elements/emby-button/emby-button'; import '../../elements/emby-button/emby-button';
import alert from '../alert'; import alert from '../alert';
/* eslint-disable indent */ function getSystemInfo() {
function getSystemInfo() {
return systemInfo ? Promise.resolve(systemInfo) : ApiClient.getPublicSystemInfo().then( return systemInfo ? Promise.resolve(systemInfo) : ApiClient.getPublicSystemInfo().then(
info => { info => {
systemInfo = info; systemInfo = info;
return info; return info;
} }
); );
} }
function onDialogClosed() { function onDialogClosed() {
loading.hide(); loading.hide();
} }
function refreshDirectoryBrowser(page, path, fileOptions, updatePathOnError) { function refreshDirectoryBrowser(page, path, fileOptions, updatePathOnError) {
if (path && typeof path !== 'string') { if (path && typeof path !== 'string') {
throw new Error('invalid path'); throw new Error('invalid path');
} }
@ -77,9 +75,9 @@ import alert from '../alert';
} }
} }
); );
} }
function getItem(cssClass, type, path, name) { function getItem(cssClass, type, path, name) {
let html = ''; let html = '';
html += `<div class="listItem listItem-border ${cssClass}" data-type="${type}" data-path="${path}">`; html += `<div class="listItem listItem-border ${cssClass}" data-type="${type}" data-path="${path}">`;
html += '<div class="listItemBody" style="padding-left:0;padding-top:.5em;padding-bottom:.5em;">'; html += '<div class="listItemBody" style="padding-left:0;padding-top:.5em;padding-bottom:.5em;">';
@ -90,9 +88,9 @@ import alert from '../alert';
html += '<span class="material-icons arrow_forward" style="font-size:inherit;"></span>'; html += '<span class="material-icons arrow_forward" style="font-size:inherit;"></span>';
html += '</div>'; html += '</div>';
return html; return html;
} }
function getEditorHtml(options, systemInfo) { function getEditorHtml(options, systemInfo) {
let html = ''; let html = '';
html += '<div class="formDialogContent scrollY">'; html += '<div class="formDialogContent scrollY">';
html += '<div class="dialogContentInner dialog-content-centered" style="padding-top:2em;">'; html += '<div class="dialogContentInner dialog-content-centered" style="padding-top:2em;">';
@ -149,19 +147,19 @@ import alert from '../alert';
html += '</div>'; html += '</div>';
return html; return html;
} }
function alertText(text) { function alertText(text) {
alertTextWithOptions({ alertTextWithOptions({
text: text text: text
}); });
} }
function alertTextWithOptions(options) { function alertTextWithOptions(options) {
alert(options); alert(options);
} }
function validatePath(path, validateWriteable, apiClient) { function validatePath(path, validateWriteable, apiClient) {
return apiClient.ajax({ return apiClient.ajax({
type: 'POST', type: 'POST',
url: apiClient.getUrl('Environment/ValidatePath'), url: apiClient.getUrl('Environment/ValidatePath'),
@ -187,9 +185,9 @@ import alert from '../alert';
} }
return Promise.resolve(); return Promise.resolve();
}); });
} }
function initEditor(content, options, fileOptions) { function initEditor(content, options, fileOptions) {
content.addEventListener('click', e => { content.addEventListener('click', e => {
const lnkPath = dom.parentWithClass(e.target, 'lnkPath'); const lnkPath = dom.parentWithClass(e.target, 'lnkPath');
if (lnkPath) { if (lnkPath) {
@ -227,9 +225,9 @@ import alert from '../alert';
e.stopPropagation(); e.stopPropagation();
return false; return false;
}); });
} }
function getDefaultPath(options) { function getDefaultPath(options) {
if (options.path) { if (options.path) {
return Promise.resolve(options.path); return Promise.resolve(options.path);
} else { } else {
@ -241,10 +239,10 @@ import alert from '../alert';
} }
); );
} }
} }
let systemInfo; let systemInfo;
class DirectoryBrowser { class DirectoryBrowser {
currentDialog; currentDialog;
constructor() {} constructor() {}
@ -306,7 +304,6 @@ import alert from '../alert';
dialogHelper.close(this.currentDialog); dialogHelper.close(this.currentDialog);
} }
}; };
} }
/* eslint-enable indent */
export default DirectoryBrowser; export default DirectoryBrowser;