mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2024-11-15 09:58:18 -07:00
fixes for lint errors
added missing packages for lint removed unecessary babel/polyfill
This commit is contained in:
parent
03e659e629
commit
a48d466e6a
@ -10,13 +10,13 @@
|
||||
"@babel/eslint-plugin": "^7.12.1",
|
||||
"@babel/plugin-proposal-class-properties": "^7.10.1",
|
||||
"@babel/plugin-proposal-private-methods": "^7.12.1",
|
||||
"@babel/polyfill": "^7.11.5",
|
||||
"@babel/preset-env": "^7.12.1",
|
||||
"autoprefixer": "^9.8.6",
|
||||
"babel-loader": "^8.0.6",
|
||||
"browser-sync": "^2.26.13",
|
||||
"confusing-browser-globals": "^1.0.10",
|
||||
"clean-webpack-plugin": "^3.0.0",
|
||||
"confusing-browser-globals": "^1.0.9",
|
||||
"copy-webpack-plugin": "^6.0.3",
|
||||
"css-loader": "^5.0.0",
|
||||
"cssnano": "^4.1.10",
|
||||
|
@ -18,7 +18,7 @@ class ServerConnections extends ConnectionManager {
|
||||
if (!AppInfo.isNativeApp) {
|
||||
console.debug('creating ApiClient singleton');
|
||||
|
||||
var apiClient = new ApiClient(
|
||||
const apiClient = new ApiClient(
|
||||
Dashboard.serverAddress(),
|
||||
appHost.appName(),
|
||||
appHost.appVersion(),
|
||||
|
@ -311,7 +311,7 @@ function askForExit() {
|
||||
});
|
||||
}
|
||||
|
||||
let deviceId = getDeviceId();
|
||||
const deviceId = getDeviceId();
|
||||
const deviceName = getDeviceName();
|
||||
const appName = 'Jellyfin Web';
|
||||
const appVersion = '10.7.0';
|
||||
|
@ -194,7 +194,7 @@ function initEditor(context, settings) {
|
||||
}
|
||||
}
|
||||
function loadDynamicFilters(context, options) {
|
||||
var apiClient = ServerConnections.getApiClient(options.serverId);
|
||||
const apiClient = ServerConnections.getApiClient(options.serverId);
|
||||
|
||||
const filterMenuOptions = Object.assign(options.filterMenuOptions, {
|
||||
|
||||
|
@ -2,6 +2,8 @@ import { playbackManager } from '../playback/playbackmanager';
|
||||
import nowPlayingHelper from '../playback/nowplayinghelper';
|
||||
import { Events } from 'jellyfin-apiclient';
|
||||
import ServerConnections from '../ServerConnections';
|
||||
import shell from '../../scripts/shell';
|
||||
|
||||
/* eslint-disable indent */
|
||||
|
||||
// Reports media playback to the device for lock screen control
|
||||
|
@ -251,7 +251,7 @@ export function show(options) {
|
||||
return showWithUser(options, player, null);
|
||||
}
|
||||
|
||||
var apiClient = ServerConnections.getApiClient(currentItem.ServerId);
|
||||
const apiClient = ServerConnections.getApiClient(currentItem.ServerId);
|
||||
return apiClient.getCurrentUser().then(function (user) {
|
||||
return showWithUser(options, player, user);
|
||||
});
|
||||
|
@ -414,7 +414,7 @@ import ServerConnections from '../ServerConnections';
|
||||
name: 'Original Media Info'
|
||||
});
|
||||
|
||||
var apiClient = ServerConnections.getApiClient(playbackManager.currentItem(player).ServerId);
|
||||
const apiClient = ServerConnections.getApiClient(playbackManager.currentItem(player).ServerId);
|
||||
if (syncPlayManager.isSyncPlayEnabled() && apiClient.isMinServerVersion('10.6.0')) {
|
||||
categories.push({
|
||||
stats: getSyncPlayStats(),
|
||||
|
@ -1,5 +1,6 @@
|
||||
import globalize from '../../scripts/globalize';
|
||||
import toast from '../toast/toast';
|
||||
import Dashboard from '../../scripts/clientUtils';
|
||||
|
||||
export class QuickConnectSettings {
|
||||
constructor() { }
|
||||
|
@ -17,7 +17,7 @@ import './remotecontrol.css';
|
||||
import '../../elements/emby-ratingbutton/emby-ratingbutton';
|
||||
import ServerConnections from '../ServerConnections';
|
||||
import toast from '../toast/toast';
|
||||
import { appRouter } from "../appRouter";
|
||||
import { appRouter } from '../appRouter';
|
||||
|
||||
/*eslint prefer-const: "error"*/
|
||||
|
||||
|
@ -9,6 +9,7 @@ import '../../elements/emby-select/emby-select';
|
||||
import '../../elements/emby-button/emby-button';
|
||||
import '../../assets/css/flexstyles.css';
|
||||
import Dashboard from '../../scripts/clientUtils';
|
||||
import { Events } from 'jellyfin-apiclient';
|
||||
|
||||
export default function (page, providerId, options) {
|
||||
function reload() {
|
||||
|
@ -6,6 +6,7 @@ import '../../elements/emby-input/emby-input';
|
||||
import '../listview/listview.css';
|
||||
import '../../elements/emby-button/paper-icon-button-light';
|
||||
import Dashboard from '../../scripts/clientUtils';
|
||||
import { Events } from 'jellyfin-apiclient';
|
||||
|
||||
export default function (page, providerId, options) {
|
||||
function getListingProvider(config, id) {
|
||||
|
@ -99,6 +99,7 @@ function dispatchViewEvent(view, eventInfo, eventName, isCancellable) {
|
||||
|
||||
function getViewEventDetail(view, {state, url, options = {}}, isRestored) {
|
||||
const index = url.indexOf('?');
|
||||
// eslint-disable-next-line compat/compat
|
||||
const searchParams = new URLSearchParams(url.substring(index + 1));
|
||||
const params = {};
|
||||
|
||||
|
@ -1,13 +1,14 @@
|
||||
import loading from '../../components/loading/loading';
|
||||
import keyboardnavigation from '../../scripts/keyboardNavigation';
|
||||
import dialogHelper from '../../components/dialogHelper/dialogHelper';
|
||||
import dom from '../../scripts/dom';
|
||||
import '../../scripts/dom';
|
||||
import { Events } from 'jellyfin-apiclient';
|
||||
import './style.css';
|
||||
import 'material-design-icons-iconfont';
|
||||
import '../../elements/emby-button/paper-icon-button-light';
|
||||
import ServerConnections from '../../components/ServerConnections';
|
||||
import TableOfContents from './tableOfContents';
|
||||
import browser from '../../scripts/browser';
|
||||
|
||||
export class BookPlayer {
|
||||
constructor() {
|
||||
|
@ -1,4 +1,5 @@
|
||||
import { Archive } from 'libarchive.js/main.js';
|
||||
// eslint-disable-next-line import/named, import/namespace
|
||||
import { Archive } from 'libarchive.js';
|
||||
import loading from '../../components/loading/loading';
|
||||
import dialogHelper from '../../components/dialogHelper/dialogHelper';
|
||||
import keyboardnavigation from '../../scripts/keyboardNavigation';
|
||||
|
@ -11,11 +11,11 @@ export default class PhotoPlayer {
|
||||
play(options) {
|
||||
return new Promise(function (resolve, reject) {
|
||||
import('../../components/slideshow/slideshow').then(({default: Slideshow}) => {
|
||||
var index = options.startIndex || 0;
|
||||
const index = options.startIndex || 0;
|
||||
|
||||
var apiClient = ServerConnections.currentApiClient();
|
||||
const apiClient = ServerConnections.currentApiClient();
|
||||
apiClient.getCurrentUser().then(function(result) {
|
||||
var newSlideShow = new Slideshow({
|
||||
const newSlideShow = new Slideshow({
|
||||
showTitle: false,
|
||||
cover: false,
|
||||
items: options.items,
|
||||
|
@ -163,7 +163,7 @@ import { Events } from 'jellyfin-apiclient';
|
||||
return;
|
||||
}
|
||||
|
||||
let url = filtered[0].path;
|
||||
const url = filtered[0].path;
|
||||
|
||||
import(`../strings/${url}`).then((fileContent) => {
|
||||
resolve(fileContent);
|
||||
|
@ -73,7 +73,7 @@ window.pageIdOn = function(eventName, id, fn) {
|
||||
});
|
||||
};
|
||||
|
||||
if (self.appMode === 'cordova' || self.appMode === 'android' || self.appMode === 'standalone') {
|
||||
if (window.appMode === 'cordova' || window.appMode === 'android' || window.appMode === 'standalone') {
|
||||
AppInfo.isNativeApp = true;
|
||||
}
|
||||
|
||||
|
@ -17,7 +17,7 @@ function getThemes() {
|
||||
|
||||
function getThemeStylesheetInfo(id) {
|
||||
return getThemes().then(themes => {
|
||||
const theme = themes.find(theme => {
|
||||
let theme = themes.find(theme => {
|
||||
return id ? theme.id === id : theme.default;
|
||||
});
|
||||
|
||||
|
@ -13,7 +13,7 @@ module.exports = merge(common, {
|
||||
test: /\.js$/,
|
||||
enforce: 'pre',
|
||||
use: ['source-map-loader']
|
||||
},
|
||||
}
|
||||
]
|
||||
},
|
||||
plugins: [
|
||||
|
@ -3,5 +3,5 @@ const merge = require('webpack-merge');
|
||||
|
||||
module.exports = merge(common, {
|
||||
mode: 'production',
|
||||
entry: './scripts/site.js',
|
||||
entry: './scripts/site.js'
|
||||
});
|
||||
|
15
yarn.lock
15
yarn.lock
@ -717,14 +717,6 @@
|
||||
"@babel/helper-create-regexp-features-plugin" "^7.12.1"
|
||||
"@babel/helper-plugin-utils" "^7.10.4"
|
||||
|
||||
"@babel/polyfill@^7.11.5":
|
||||
version "7.12.1"
|
||||
resolved "https://registry.yarnpkg.com/@babel/polyfill/-/polyfill-7.12.1.tgz#1f2d6371d1261bbd961f3c5d5909150e12d0bd96"
|
||||
integrity sha512-X0pi0V6gxLi6lFZpGmeNa4zxtwEmCs42isWLNjZZDE0Y8yVfgu0T2OAHlzBbdYlqbW/YXVvoBHpATEM+goCj8g==
|
||||
dependencies:
|
||||
core-js "^2.6.5"
|
||||
regenerator-runtime "^0.13.4"
|
||||
|
||||
"@babel/preset-env@^7.12.1":
|
||||
version "7.12.1"
|
||||
resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.12.1.tgz#9c7e5ca82a19efc865384bb4989148d2ee5d7ac2"
|
||||
@ -2934,7 +2926,7 @@ config-chain@^1.1.11:
|
||||
ini "^1.3.4"
|
||||
proto-list "~1.2.1"
|
||||
|
||||
confusing-browser-globals@^1.0.10:
|
||||
confusing-browser-globals@^1.0.9:
|
||||
version "1.0.10"
|
||||
resolved "https://registry.yarnpkg.com/confusing-browser-globals/-/confusing-browser-globals-1.0.10.tgz#30d1e7f3d1b882b25ec4933d1d1adac353d20a59"
|
||||
integrity sha512-gNld/3lySHwuhaVluJUKLePYirM3QNCKzVxqAdhJII9/WXKVX5PURzMVJspS1jTslSqjeuG4KMVTSouit5YPHA==
|
||||
@ -3063,11 +3055,6 @@ core-js-compat@^3.6.2:
|
||||
browserslist "^4.8.5"
|
||||
semver "7.0.0"
|
||||
|
||||
core-js@^2.6.5:
|
||||
version "2.6.11"
|
||||
resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.11.tgz#38831469f9922bded8ee21c9dc46985e0399308c"
|
||||
integrity sha512-5wjnpaT/3dV+XB4borEsnAYQchn00XSgTAWKDkEqv+K8KevjbzmofK6hfJ9TZIlpj2N0xQpazy7PiRQiWHqzWg==
|
||||
|
||||
core-js@^3.6.5:
|
||||
version "3.6.5"
|
||||
resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.6.5.tgz#7395dc273af37fb2e50e9bd3d9fe841285231d1a"
|
||||
|
Loading…
Reference in New Issue
Block a user