mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2025-01-31 19:22:26 +00:00
fix: babel jassub worker
This commit is contained in:
parent
71e9b46a81
commit
434029dae9
@ -12,14 +12,7 @@ module.exports = {
|
||||
corejs: 3
|
||||
}
|
||||
],
|
||||
'@babel/preset-react',
|
||||
[
|
||||
'@babel/preset-typescript',
|
||||
{
|
||||
isTSX: true,
|
||||
allExtensions: true
|
||||
}
|
||||
]
|
||||
'@babel/preset-react'
|
||||
],
|
||||
plugins: [
|
||||
'@babel/plugin-proposal-class-properties',
|
||||
|
@ -1213,8 +1213,10 @@ function tryRemoveElement(elem) {
|
||||
fonts: avaliableFonts,
|
||||
fallbackFont: 'liberation sans',
|
||||
availableFonts: {'liberation sans': `${appRouter.baseUrl()}/libraries/default.woff2`},
|
||||
workerUrl: `${appRouter.baseUrl()}/libraries/jassub-worker.js`,
|
||||
legacyWorkerUrl: `${appRouter.baseUrl()}/libraries/jassub-worker-legacy.js`,
|
||||
// eslint-disable-next-line compat/compat
|
||||
workerUrl: `${appRouter.baseUrl()}/${new URL('jassub/dist/jassub-worker.js', import.meta.url)}`,
|
||||
// eslint-disable-next-line compat/compat
|
||||
legacyWorkerUrl: `${appRouter.baseUrl()}/${new URL('jassub/dist/jassub-worker-legacy.js', import.meta.url)}`,
|
||||
timeOffset: (this._currentPlayOptions.transcodingOffsetTicks || 0) / 10000000,
|
||||
// new jassub options; override all, even defaults
|
||||
blendMode: 'js',
|
||||
|
@ -8,9 +8,7 @@ const { DefinePlugin } = require('webpack');
|
||||
const Assets = [
|
||||
'native-promise-only/npo.js',
|
||||
'libarchive.js/dist/worker-bundle.js',
|
||||
'jassub/dist/jassub-worker.js',
|
||||
'jassub/dist/jassub-worker.wasm',
|
||||
'jassub/dist/jassub-worker-legacy.js',
|
||||
'jassub/dist/jassub-worker-legacy.mem',
|
||||
'jassub/dist/default.woff2',
|
||||
'pdfjs-dist/build/pdf.worker.js'
|
||||
@ -146,7 +144,6 @@ const config = {
|
||||
{
|
||||
test: /\.(js|jsx)$/,
|
||||
include: [
|
||||
path.resolve(__dirname, 'node_modules/jassub'),
|
||||
path.resolve(__dirname, 'node_modules/rvfc-polyfill'),
|
||||
path.resolve(__dirname, 'node_modules/@jellyfin/sdk'),
|
||||
path.resolve(__dirname, 'node_modules/@remix-run/router'),
|
||||
@ -174,6 +171,20 @@ const config = {
|
||||
}
|
||||
}]
|
||||
},
|
||||
{
|
||||
test: /\.js$/,
|
||||
include: [
|
||||
path.resolve(__dirname, 'node_modules/jassub')
|
||||
],
|
||||
use: [{
|
||||
loader: 'babel-loader',
|
||||
options: {
|
||||
cacheCompression: false,
|
||||
cacheDirectory: true,
|
||||
presets: ['@babel/preset-env']
|
||||
}
|
||||
}]
|
||||
},
|
||||
{
|
||||
test: /\.worker\.ts$/,
|
||||
exclude: /node_modules/,
|
||||
|
Loading…
x
Reference in New Issue
Block a user