diff --git a/src/main/base/browserwindow.ts b/src/main/base/browserwindow.ts index 26312caa..3cdbe555 100644 --- a/src/main/base/browserwindow.ts +++ b/src/main/base/browserwindow.ts @@ -558,15 +558,11 @@ export class BrowserWindow { res.send("Stopped"); break; case "next": - BrowserWindow.win.webContents.executeJavaScript( - "if (MusicKit.getInstance().queue.nextPlayableItemIndex != -1 && MusicKit.getInstance().queue.nextPlayableItemIndex != null) {MusicKit.getInstance().changeToMediaAtIndex(MusicKit.getInstance().queue.nextPlayableItemIndex);}" - ); + BrowserWindow.win.webContents.executeJavaScript("if (MusicKit.getInstance().queue.nextPlayableItemIndex != -1 && MusicKit.getInstance().queue.nextPlayableItemIndex != null) {MusicKit.getInstance().changeToMediaAtIndex(MusicKit.getInstance().queue.nextPlayableItemIndex);}"); res.send("Next"); break; case "previous": - BrowserWindow.win.webContents.executeJavaScript( - "if (MusicKit.getInstance().queue.previousPlayableItemIndex != -1 && MusicKit.getInstance().queue.previousPlayableItemIndex != null) {MusicKit.getInstance().changeToMediaAtIndex(MusicKit.getInstance().queue.previousPlayableItemIndex);}" - ); + BrowserWindow.win.webContents.executeJavaScript("if (MusicKit.getInstance().queue.previousPlayableItemIndex != -1 && MusicKit.getInstance().queue.previousPlayableItemIndex != null) {MusicKit.getInstance().changeToMediaAtIndex(MusicKit.getInstance().queue.previousPlayableItemIndex);}"); res.send("Previous"); break; default: { diff --git a/src/main/base/wsapi.ts b/src/main/base/wsapi.ts index 7fc25619..d161b279 100644 --- a/src/main/base/wsapi.ts +++ b/src/main/base/wsapi.ts @@ -208,9 +208,7 @@ export class wsapi { response.message = "Next"; break; case "previous": - this._win.webContents.executeJavaScript( - `if (MusicKit.getInstance().queue.previousPlayableItemIndex != -1 && MusicKit.getInstance().queue.previousPlayableItemIndex != null) {MusicKit.getInstance().changeToMediaAtIndex(MusicKit.getInstance().queue.previousPlayableItemIndex)}` - ); + this._win.webContents.executeJavaScript(`if (MusicKit.getInstance().queue.previousPlayableItemIndex != -1 && MusicKit.getInstance().queue.previousPlayableItemIndex != null) {MusicKit.getInstance().changeToMediaAtIndex(MusicKit.getInstance().queue.previousPlayableItemIndex)}`); response.message = "Previous"; break; case "musickit-api": diff --git a/src/main/plugins/lastfm.ts b/src/main/plugins/lastfm.ts index ba912370..b9d4cc2a 100644 --- a/src/main/plugins/lastfm.ts +++ b/src/main/plugins/lastfm.ts @@ -170,13 +170,7 @@ export default class lastfm { return; } - if ( - !this._authenticated || - !attributes || - this._utils.getStoreValue("connectivity.lastfm.filter_types")[attributes.playParams.kind] || - (this._utils.getStoreValue("connectivity.lastfm.filter_loop") && this._scrobbleCache.track === attributes.lfmTrack.name) - ) - return; + if (!this._authenticated || !attributes || this._utils.getStoreValue("connectivity.lastfm.filter_types")[attributes.playParams.kind] || (this._utils.getStoreValue("connectivity.lastfm.filter_loop") && this._scrobbleCache.track === attributes.lfmTrack.name)) return; // Scrobble const scrobble = { @@ -216,13 +210,7 @@ export default class lastfm { return; } - if ( - !this._authenticated || - !attributes || - this._utils.getStoreValue("connectivity.lastfm.filter_types")[attributes.playParams.kind] || - (this._utils.getStoreValue("connectivity.lastfm.filter_loop") && this._nowPlayingCache.track === attributes.lfmTrack.name) - ) - return; + if (!this._authenticated || !attributes || this._utils.getStoreValue("connectivity.lastfm.filter_types")[attributes.playParams.kind] || (this._utils.getStoreValue("connectivity.lastfm.filter_loop") && this._nowPlayingCache.track === attributes.lfmTrack.name)) return; const nowPlaying = { artist: attributes.lfmTrack.artist.name, diff --git a/src/main/plugins/menubar.ts b/src/main/plugins/menubar.ts index 261605e4..dc652dec 100644 --- a/src/main/plugins/menubar.ts +++ b/src/main/plugins/menubar.ts @@ -53,20 +53,7 @@ export default class Thumbar { { label: utils.getLocale(utils.getStoreValue("general.language"), "menubar.options.view"), submenu: [ - ...(this.isMac - ? [ - { role: "reload" }, - { role: "forceReload" }, - { role: "toggleDevTools" }, - { type: "separator" }, - { role: "resetZoom" }, - { role: "zoomIn" }, - { role: "zoomOut" }, - { type: "separator" }, - { role: "togglefullscreen" }, - { type: "separator" }, - ] - : []), + ...(this.isMac ? [{ role: "reload" }, { role: "forceReload" }, { role: "toggleDevTools" }, { type: "separator" }, { role: "resetZoom" }, { role: "zoomIn" }, { role: "zoomOut" }, { type: "separator" }, { role: "togglefullscreen" }, { type: "separator" }] : []), { label: utils.getLocale(utils.getStoreValue("general.language"), "term.search"), accelerator: utils.getStoreValue("general.keybindings.search").join("+"), diff --git a/src/main/plugins/raop.ts b/src/main/plugins/raop.ts index 74eb513b..cdca5b52 100644 --- a/src/main/plugins/raop.ts +++ b/src/main/plugins/raop.ts @@ -259,8 +259,7 @@ export default class RAOP { // this.airtunes.stopAll(() => { // console.log("end"); // }); - if (this.devices[idx]?.state != null && this.devices[idx].state != -1) - this._win.webContents.executeJavaScript(`app.airplayDisconnect(true, ${JSON.stringify([ipv4, ipport, sepassword, title, artist, album, artworkURL, txt, airplay2dv])})`).catch((err: any) => console.error(err)); + if (this.devices[idx]?.state != null && this.devices[idx].state != -1) this._win.webContents.executeJavaScript(`app.airplayDisconnect(true, ${JSON.stringify([ipv4, ipport, sepassword, title, artist, album, artworkURL, txt, airplay2dv])})`).catch((err: any) => console.error(err)); // this.airtunes = null; // this.device = null; // this.ipairplay = ""; diff --git a/src/renderer/audio/audio.js b/src/renderer/audio/audio.js index 99645e24..9a993c14 100644 --- a/src/renderer/audio/audio.js +++ b/src/renderer/audio/audio.js @@ -301,9 +301,7 @@ const CiderAudio = { filterlessGain = filterlessGain * spatialProfile.gainComp; } filterlessGain = Math.pow(10, (-1 * (20 * Math.log10(filterlessGain))) / 20).toFixed(4); - filterlessGain > 1.0 - ? CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudio.context.currentTime + 0.3) - : CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(filterlessGain, CiderAudio.context.currentTime + 0.3); + filterlessGain > 1.0 ? CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudio.context.currentTime + 0.3) : CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(filterlessGain, CiderAudio.context.currentTime + 0.3); console.debug(`[Cider][Audio] IntelliGainComp: ${filterlessGain > 1.0 ? 0 : (20 * Math.log10(filterlessGain)).toFixed(2)} dB (${filterlessGain > 1.0 ? 1 : filterlessGain})`); return; } @@ -358,9 +356,7 @@ const CiderAudio = { maxGain = maxGain * spatialProfile.gainComp; } maxGain = Math.pow(10, (-1 * (20 * Math.log10(maxGain))) / 20).toFixed(4); - maxGain > 1.0 - ? CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudio.context.currentTime + 0.3) - : CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(maxGain, CiderAudio.context.currentTime + 0.3); + maxGain > 1.0 ? CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudio.context.currentTime + 0.3) : CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(maxGain, CiderAudio.context.currentTime + 0.3); console.debug(`[Cider][Audio] IntelliGainComp: ${maxGain > 1.0 ? 0 : (20 * Math.log10(maxGain)).toFixed(2)} dB (${maxGain > 1.0 ? 1 : maxGain})`); }, sendAudio: function () { diff --git a/src/renderer/audio/renderer.js b/src/renderer/audio/renderer.js index 8ab2ea60..04d6cd8a 100644 --- a/src/renderer/audio/renderer.js +++ b/src/renderer/audio/renderer.js @@ -171,9 +171,7 @@ const CiderAudioRenderer = { maxGain = maxGain * spatialProfile.gainComp; } maxGain = Math.pow(10, (-1 * (20 * Math.log10(maxGain))) / 20).toFixed(4); - maxGain > 1.0 - ? CiderAudioRenderer.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudioRenderer.context.currentTime + 0.3) - : CiderAudioRenderer.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(maxGain, CiderAudioRenderer.context.currentTime + 0.3); + maxGain > 1.0 ? CiderAudioRenderer.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudioRenderer.context.currentTime + 0.3) : CiderAudioRenderer.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(maxGain, CiderAudioRenderer.context.currentTime + 0.3); console.debug(`[Cider][Audio] IntelliGainComp: ${maxGain > 1.0 ? 0 : (20 * Math.log10(maxGain)).toFixed(2)} dB (${maxGain > 1.0 ? 1 : maxGain})`); }, atmosphereRealizer2_n6: function (status, destination) { diff --git a/src/renderer/hlscider.js b/src/renderer/hlscider.js index 9e4c34da..f7da6d23 100644 --- a/src/renderer/hlscider.js +++ b/src/renderer/hlscider.js @@ -1589,9 +1589,7 @@ typeof window !== "undefined" && } var levelDetails = levelInfo.details; - var avgDuration = - (partCurrent ? (levelDetails === null || levelDetails === void 0 ? void 0 : levelDetails.partTarget) : levelDetails === null || levelDetails === void 0 ? void 0 : levelDetails.averagetargetduration) || - currentFragDuration; + var avgDuration = (partCurrent ? (levelDetails === null || levelDetails === void 0 ? void 0 : levelDetails.partTarget) : levelDetails === null || levelDetails === void 0 ? void 0 : levelDetails.averagetargetduration) || currentFragDuration; var adjustedbw = void 0; // follow algorithm captured from stagefright : // https://android.googlesource.com/platform/frameworks/av/+/master/media/libstagefright/httplive/LiveSession.cpp // Pick the highest bandwidth stream below or equal to estimated bandwidth. @@ -1607,9 +1605,7 @@ typeof window !== "undefined" && var bitrate = levels[i].maxBitrate; var fetchDuration = (bitrate * avgDuration) / adjustedbw; - _utils_logger__WEBPACK_IMPORTED_MODULE_6__["logger"].trace( - "level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: " + i + "/" + Math.round(adjustedbw) + "/" + bitrate + "/" + avgDuration + "/" + maxFetchDuration + "/" + fetchDuration - ); // if adjusted bw is greater than level bitrate AND + _utils_logger__WEBPACK_IMPORTED_MODULE_6__["logger"].trace("level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: " + i + "/" + Math.round(adjustedbw) + "/" + bitrate + "/" + avgDuration + "/" + maxFetchDuration + "/" + fetchDuration); // if adjusted bw is greater than level bitrate AND if ( adjustedbw > bitrate && // fragment fetchDuration unknown OR live stream OR fragment fetchDuration less than max allowed fetch duration, then this level matches @@ -1971,11 +1967,7 @@ typeof window !== "undefined" && if (this.bufferFlushed) { this.bufferFlushed = false; - this.afterBufferFlushed( - this.mediaBuffer ? this.mediaBuffer : this.media, - _loader_fragment__WEBPACK_IMPORTED_MODULE_7__["ElementaryStreamTypes"].AUDIO, - _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].AUDIO - ); + this.afterBufferFlushed(this.mediaBuffer ? this.mediaBuffer : this.media, _loader_fragment__WEBPACK_IMPORTED_MODULE_7__["ElementaryStreamTypes"].AUDIO, _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].AUDIO); } var bufferInfo = this.getFwdBufferInfo(this.mediaBuffer ? this.mediaBuffer : this.media, _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].AUDIO); @@ -2024,10 +2016,7 @@ typeof window !== "undefined" && return; } - if ( - ((_frag$decryptdata = frag.decryptdata) === null || _frag$decryptdata === void 0 ? void 0 : _frag$decryptdata.keyFormat) === "identity" && - !((_frag$decryptdata2 = frag.decryptdata) !== null && _frag$decryptdata2 !== void 0 && _frag$decryptdata2.key) - ) { + if (((_frag$decryptdata = frag.decryptdata) === null || _frag$decryptdata === void 0 ? void 0 : _frag$decryptdata.keyFormat) === "identity" && !((_frag$decryptdata2 = frag.decryptdata) !== null && _frag$decryptdata2 !== void 0 && _frag$decryptdata2.key)) { this.loadKey(frag, trackDetails); } else { this.loadFragment(frag, trackDetails, targetBufferTime); @@ -2176,12 +2165,7 @@ typeof window !== "undefined" && var transmuxer = this.transmuxer; if (!transmuxer) { - transmuxer = this.transmuxer = new _demux_transmuxer_interface__WEBPACK_IMPORTED_MODULE_9__["default"]( - this.CiderHls, - _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].AUDIO, - this._handleTransmuxComplete.bind(this), - this._handleTransmuxerFlush.bind(this) - ); + transmuxer = this.transmuxer = new _demux_transmuxer_interface__WEBPACK_IMPORTED_MODULE_9__["default"](this.CiderHls, _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].AUDIO, this._handleTransmuxComplete.bind(this), this._handleTransmuxerFlush.bind(this)); } // Check if we have video initPTS // If not we need to wait for it @@ -2198,9 +2182,7 @@ typeof window !== "undefined" && var chunkMeta = new _types_transmuxer__WEBPACK_IMPORTED_MODULE_10__["ChunkMetadata"](frag.level, frag.sn, frag.stats.chunkCount, payload.byteLength, partIndex, partial); transmuxer.push(payload, initSegmentData, audioCodec, "", frag, part, details.totalduration, accurateTimeOffset, chunkMeta, initPTS); } else { - _utils_logger__WEBPACK_IMPORTED_MODULE_14__["logger"].log( - "Unknown video PTS for cc " + frag.cc + ", waiting for video PTS before demuxing audio frag " + frag.sn + " of [" + details.startSN + " ," + details.endSN + "],track " + trackId - ); + _utils_logger__WEBPACK_IMPORTED_MODULE_14__["logger"].log("Unknown video PTS for cc " + frag.cc + ", waiting for video PTS before demuxing audio frag " + frag.sn + " of [" + details.startSN + " ," + details.endSN + "],track " + trackId); var _this$waitingData = (this.waitingData = this.waitingData || { frag: frag, @@ -3267,9 +3249,7 @@ typeof window !== "undefined" && state = this.state; var currentTime = media ? media.currentTime : 0; var bufferInfo = _utils_buffer_helper__WEBPACK_IMPORTED_MODULE_3__["BufferHelper"].bufferInfo(mediaBuffer || media, currentTime, config.maxBufferHole); - this.log( - "media seeking to " + (Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(currentTime) ? currentTime.toFixed(3) : currentTime) + ", state: " + state - ); + this.log("media seeking to " + (Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(currentTime) ? currentTime.toFixed(3) : currentTime) + ", state: " + state); if (state === State.ENDED) { this.resetLoadingState(); @@ -3619,19 +3599,7 @@ typeof window !== "undefined" && } } - this.log( - "Loading fragment " + - frag.sn + - " cc: " + - frag.cc + - " " + - (details ? "of [" + details.startSN + "-" + details.endSN + "] " : "") + - (this.logPrefix === "[stream-controller]" ? "level" : "track") + - ": " + - frag.level + - ", target: " + - parseFloat(targetBufferTime.toFixed(3)) - ); // Don't update nextLoadPosition for fragments which are not buffered + this.log("Loading fragment " + frag.sn + " cc: " + frag.cc + " " + (details ? "of [" + details.startSN + "-" + details.endSN + "] " : "") + (this.logPrefix === "[stream-controller]" ? "level" : "track") + ": " + frag.level + ", target: " + parseFloat(targetBufferTime.toFixed(3))); // Don't update nextLoadPosition for fragments which are not buffered if (Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(frag.sn) && !this.bitrateTest) { this.nextLoadPosition = frag.start + frag.duration; @@ -4099,18 +4067,7 @@ typeof window !== "undefined" && if (firstLevelLoad || (!aligned && !slidingStart)) { Object(_utils_discontinuities__WEBPACK_IMPORTED_MODULE_9__["alignStream"])(fragPrevious, lastLevel, details); var alignedSlidingStart = details.fragments[0].start; - this.log( - "Live playlist sliding: " + - alignedSlidingStart.toFixed(2) + - " start-sn: " + - (previousDetails ? previousDetails.startSN : "na") + - "->" + - details.startSN + - " prev-sn: " + - (fragPrevious ? fragPrevious.sn : "na") + - " fragments: " + - length - ); + this.log("Live playlist sliding: " + alignedSlidingStart.toFixed(2) + " start-sn: " + (previousDetails ? previousDetails.startSN : "na") + "->" + details.startSN + " prev-sn: " + (fragPrevious ? fragPrevious.sn : "na") + " fragments: " + length); return alignedSlidingStart; } @@ -5767,11 +5724,7 @@ typeof window !== "undefined" && ot: ot, }; - if ( - ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].VIDEO || - ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].AUDIO || - ot == _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].MUXED - ) { + if (ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].VIDEO || ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].AUDIO || ot == _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].MUXED) { data.br = level.bitrate / 1000; data.tb = _this.getTopBandwidth(ot); data.bl = _this.getBufferLength(ot); @@ -5871,10 +5824,7 @@ typeof window !== "undefined" && // apply baseline data _extends(data, this.createData()); - var isVideo = - data.ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].INIT || - data.ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].VIDEO || - data.ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].MUXED; + var isVideo = data.ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].INIT || data.ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].VIDEO || data.ot === _types_cmcd__WEBPACK_IMPORTED_MODULE_1__["CMCDObjectType"].MUXED; if (this.starved && isVideo) { data.bs = true; @@ -8610,10 +8560,7 @@ typeof window !== "undefined" && levels = levels.filter(function (_ref2) { var audioCodec = _ref2.audioCodec, videoCodec = _ref2.videoCodec; - return ( - (!audioCodec || Object(_utils_codecs__WEBPACK_IMPORTED_MODULE_3__["isCodecSupportedInMp4"])(audioCodec, "audio")) && - (!videoCodec || Object(_utils_codecs__WEBPACK_IMPORTED_MODULE_3__["isCodecSupportedInMp4"])(videoCodec, "video")) - ); + return (!audioCodec || Object(_utils_codecs__WEBPACK_IMPORTED_MODULE_3__["isCodecSupportedInMp4"])(audioCodec, "audio")) && (!videoCodec || Object(_utils_codecs__WEBPACK_IMPORTED_MODULE_3__["isCodecSupportedInMp4"])(videoCodec, "video")); }); if (data.audioTracks) { @@ -9319,10 +9266,7 @@ typeof window !== "undefined" && ccOffset = oldFrag.cc - newFrag.cc; } - if ( - Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(oldFrag.startPTS) && - Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(oldFrag.endPTS) - ) { + if (Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(oldFrag.startPTS) && Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(oldFrag.endPTS)) { newFrag.start = newFrag.startPTS = oldFrag.startPTS; newFrag.startDTS = oldFrag.startDTS; newFrag.appendedPTS = oldFrag.appendedPTS; @@ -9902,10 +9846,7 @@ typeof window !== "undefined" && } // We want to load the key if we're dealing with an identity key, because we will decrypt // this content using the key we fetch. Other keys will be handled by the DRM CDM via EME. - if ( - ((_frag$decryptdata = frag.decryptdata) === null || _frag$decryptdata === void 0 ? void 0 : _frag$decryptdata.keyFormat) === "identity" && - !((_frag$decryptdata2 = frag.decryptdata) !== null && _frag$decryptdata2 !== void 0 && _frag$decryptdata2.key) - ) { + if (((_frag$decryptdata = frag.decryptdata) === null || _frag$decryptdata === void 0 ? void 0 : _frag$decryptdata.keyFormat) === "identity" && !((_frag$decryptdata2 = frag.decryptdata) !== null && _frag$decryptdata2 !== void 0 && _frag$decryptdata2.key)) { this.loadKey(frag, levelDetails); } else { this.loadFragment(frag, levelDetails, targetBufferTime); @@ -10257,13 +10198,7 @@ typeof window !== "undefined" && // this.log(`Transmuxing ${frag.sn} of [${details.startSN} ,${details.endSN}],level ${frag.level}, cc ${frag.cc}`); var transmuxer = (this.transmuxer = - this.transmuxer || - new _demux_transmuxer_interface__WEBPACK_IMPORTED_MODULE_8__["default"]( - this.CiderHls, - _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].MAIN, - this._handleTransmuxComplete.bind(this), - this._handleTransmuxerFlush.bind(this) - )); + this.transmuxer || new _demux_transmuxer_interface__WEBPACK_IMPORTED_MODULE_8__["default"](this.CiderHls, _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].MAIN, this._handleTransmuxComplete.bind(this), this._handleTransmuxerFlush.bind(this))); var partIndex = part ? part.index : -1; var partial = partIndex !== -1; var chunkMeta = new _types_transmuxer__WEBPACK_IMPORTED_MODULE_9__["ChunkMetadata"](frag.level, frag.sn, frag.stats.chunkCount, payload.byteLength, partIndex, partial); @@ -14779,8 +14714,8 @@ typeof window !== "undefined" && */ var chromeVersion = null; var BitratesMap = [ - 32, 64, 96, 128, 160, 192, 224, 256, 288, 320, 352, 384, 416, 448, 32, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 384, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 32, 48, 56, 64, 80, 96, 112, - 128, 144, 160, 176, 192, 224, 256, 8, 16, 24, 32, 40, 48, 56, 64, 80, 96, 112, 128, 144, 160, + 32, 64, 96, 128, 160, 192, 224, 256, 288, 320, 352, 384, 416, 448, 32, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 384, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 32, 48, 56, 64, 80, 96, 112, 128, 144, 160, 176, 192, 224, 256, 8, 16, 24, 32, 40, 48, 56, + 64, 80, 96, 112, 128, 144, 160, ]; var SamplingRateMap = [44100, 48000, 32000, 22050, 24000, 16000, 11025, 12000, 8000]; var SamplesCoefficients = [ @@ -18354,9 +18289,7 @@ typeof window !== "undefined" && var _sourceBuffer$prototy; var sourceBuffer = getSourceBuffer(); - return ( - typeof (sourceBuffer === null || sourceBuffer === void 0 ? void 0 : (_sourceBuffer$prototy = sourceBuffer.prototype) === null || _sourceBuffer$prototy === void 0 ? void 0 : _sourceBuffer$prototy.changeType) === "function" - ); + return typeof (sourceBuffer === null || sourceBuffer === void 0 ? void 0 : (_sourceBuffer$prototy = sourceBuffer.prototype) === null || _sourceBuffer$prototy === void 0 ? void 0 : _sourceBuffer$prototy.changeType) === "function"; } /***/ @@ -18743,10 +18676,7 @@ typeof window !== "undefined" && var start = segment.byteRangeStartOffset; var end = segment.byteRangeEndOffset; - if ( - Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(start) && - Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(end) - ) { + if (Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(start) && Object(_home_runner_work_CiderHls_js_CiderHls_js_src_polyfills_number__WEBPACK_IMPORTED_MODULE_0__["isFiniteNumber"])(end)) { loaderContext.rangeStart = start; loaderContext.rangeEnd = end; } @@ -18854,12 +18784,7 @@ typeof window !== "undefined" && this._url = null; this.baseurl = void 0; this.relurl = void 0; - this.elementaryStreams = - ((_this$elementaryStrea = {}), - (_this$elementaryStrea[ElementaryStreamTypes.AUDIO] = null), - (_this$elementaryStrea[ElementaryStreamTypes.VIDEO] = null), - (_this$elementaryStrea[ElementaryStreamTypes.AUDIOVIDEO] = null), - _this$elementaryStrea); + this.elementaryStreams = ((_this$elementaryStrea = {}), (_this$elementaryStrea[ElementaryStreamTypes.AUDIO] = null), (_this$elementaryStrea[ElementaryStreamTypes.VIDEO] = null), (_this$elementaryStrea[ElementaryStreamTypes.AUDIOVIDEO] = null), _this$elementaryStrea); this.baseurl = baseurl; } // setByteRange converts a EXT-X-BYTERANGE attribute into a two element array @@ -19730,11 +19655,7 @@ typeof window !== "undefined" && function isMP4Url(url) { var _URLToolkit$parseURL$, _URLToolkit$parseURL; - return MP4_REGEX_SUFFIX.test( - (_URLToolkit$parseURL$ = (_URLToolkit$parseURL = url_toolkit__WEBPACK_IMPORTED_MODULE_1__["parseURL"](url)) === null || _URLToolkit$parseURL === void 0 ? void 0 : _URLToolkit$parseURL.path) != null - ? _URLToolkit$parseURL$ - : "" - ); + return MP4_REGEX_SUFFIX.test((_URLToolkit$parseURL$ = (_URLToolkit$parseURL = url_toolkit__WEBPACK_IMPORTED_MODULE_1__["parseURL"](url)) === null || _URLToolkit$parseURL === void 0 ? void 0 : _URLToolkit$parseURL.path) != null ? _URLToolkit$parseURL$ : ""); } var M3U8Parser = /*#__PURE__*/ (function () { @@ -20819,9 +20740,7 @@ typeof window !== "undefined" && timeout = false; } - _utils_logger__WEBPACK_IMPORTED_MODULE_3__["logger"].warn( - "[playlist-loader]: A network " + (timeout ? "timeout" : "error") + " occurred while loading " + context.type + " level: " + context.level + " id: " + context.id + ' group-id: "' + context.groupId + '"' - ); + _utils_logger__WEBPACK_IMPORTED_MODULE_3__["logger"].warn("[playlist-loader]: A network " + (timeout ? "timeout" : "error") + " occurred while loading " + context.type + " level: " + context.level + " id: " + context.id + ' group-id: "' + context.groupId + '"'); var details = _errors__WEBPACK_IMPORTED_MODULE_2__["ErrorDetails"].UNKNOWN; var fatal = false; var loader = this.getInternalLoader(context); @@ -21004,20 +20923,20 @@ typeof window !== "undefined" && if (channelCount === 1) { // ffmpeg -y -f lavfi -i "aevalsrc=0:d=0.05" -c:a libfdk_aac -profile:a aac_he -b:a 4k output.aac && hexdump -v -e '16/1 "0x%x," "\n"' -v output.aac return new Uint8Array([ - 0x1, 0x40, 0x22, 0x80, 0xa3, 0x4e, 0xe6, 0x80, 0xba, 0x8, 0x0, 0x0, 0x0, 0x1c, 0x6, 0xf1, 0xc1, 0xa, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, - 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5e, + 0x1, 0x40, 0x22, 0x80, 0xa3, 0x4e, 0xe6, 0x80, 0xba, 0x8, 0x0, 0x0, 0x0, 0x1c, 0x6, 0xf1, 0xc1, 0xa, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, + 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5e, ]); } else if (channelCount === 2) { // ffmpeg -y -f lavfi -i "aevalsrc=0|0:d=0.05" -c:a libfdk_aac -profile:a aac_he_v2 -b:a 4k output.aac && hexdump -v -e '16/1 "0x%x," "\n"' -v output.aac return new Uint8Array([ - 0x1, 0x40, 0x22, 0x80, 0xa3, 0x5e, 0xe6, 0x80, 0xba, 0x8, 0x0, 0x0, 0x0, 0x0, 0x95, 0x0, 0x6, 0xf1, 0xa1, 0xa, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, - 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5e, + 0x1, 0x40, 0x22, 0x80, 0xa3, 0x5e, 0xe6, 0x80, 0xba, 0x8, 0x0, 0x0, 0x0, 0x0, 0x95, 0x0, 0x6, 0xf1, 0xa1, 0xa, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, + 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5e, ]); } else if (channelCount === 3) { // ffmpeg -y -f lavfi -i "aevalsrc=0|0|0:d=0.05" -c:a libfdk_aac -profile:a aac_he_v2 -b:a 4k output.aac && hexdump -v -e '16/1 "0x%x," "\n"' -v output.aac return new Uint8Array([ - 0x1, 0x40, 0x22, 0x80, 0xa3, 0x5e, 0xe6, 0x80, 0xba, 0x8, 0x0, 0x0, 0x0, 0x0, 0x95, 0x0, 0x6, 0xf1, 0xa1, 0xa, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, - 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5e, + 0x1, 0x40, 0x22, 0x80, 0xa3, 0x5e, 0xe6, 0x80, 0xba, 0x8, 0x0, 0x0, 0x0, 0x0, 0x95, 0x0, 0x6, 0xf1, 0xa1, 0xa, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, + 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5a, 0x5e, ]); } @@ -22334,13 +22253,7 @@ typeof window !== "undefined" && initSegment = this.generateIS(audioTrack, videoTrack, timeOffset); } - audio = this.remuxAudio( - audioTrack, - audioTimeOffset, - this.isAudioContiguous, - accurateTimeOffset, - hasVideo || enoughVideoSamples || playlistType === _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].AUDIO ? videoTimeOffset : undefined - ); + audio = this.remuxAudio(audioTrack, audioTimeOffset, this.isAudioContiguous, accurateTimeOffset, hasVideo || enoughVideoSamples || playlistType === _types_loader__WEBPACK_IMPORTED_MODULE_6__["PlaylistLevelType"].AUDIO ? videoTimeOffset : undefined); if (enoughVideoSamples) { var audioTrackLength = audio ? audio.endPTS - audio.startPTS : 0; // if initSegment was generated without video samples, regenerate it again @@ -22531,9 +22444,7 @@ typeof window !== "undefined" && if (ptsDtsShift < averageSampleDuration * -2) { // Fix for "CNN special report, with CC" in test-streams (including Safari browser) // With large PTS < DTS errors such as this, we want to correct CTS while maintaining increasing DTS values - _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn( - "PTS < DTS detected in video samples, offsetting DTS from PTS by " + Object(_utils_timescale_conversion__WEBPACK_IMPORTED_MODULE_7__["toMsFromMpegTsClock"])(-averageSampleDuration, true) + " ms" - ); + _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn("PTS < DTS detected in video samples, offsetting DTS from PTS by " + Object(_utils_timescale_conversion__WEBPACK_IMPORTED_MODULE_7__["toMsFromMpegTsClock"])(-averageSampleDuration, true) + " ms"); var lastDts = ptsDtsShift; for (var _i = 0; _i < nbSamples; _i++) { @@ -22543,9 +22454,7 @@ typeof window !== "undefined" && } else { // Fix for "Custom IV with bad PTS DTS" in test-streams // With smaller PTS < DTS errors we can simply move all DTS back. This increases CTS without causing buffer gaps or decode errors in Safari - _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn( - "PTS < DTS detected in video samples, shifting DTS by " + Object(_utils_timescale_conversion__WEBPACK_IMPORTED_MODULE_7__["toMsFromMpegTsClock"])(ptsDtsShift, true) + " ms to overcome this issue" - ); + _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn("PTS < DTS detected in video samples, shifting DTS by " + Object(_utils_timescale_conversion__WEBPACK_IMPORTED_MODULE_7__["toMsFromMpegTsClock"])(ptsDtsShift, true) + " ms to overcome this issue"); for (var _i2 = 0; _i2 < nbSamples; _i2++) { inputSamples[_i2].dts = inputSamples[_i2].dts + ptsDtsShift; @@ -22563,13 +22472,9 @@ typeof window !== "undefined" && if (foundHole || foundOverlap) { if (foundHole) { - _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn( - "AVC: " + Object(_utils_timescale_conversion__WEBPACK_IMPORTED_MODULE_7__["toMsFromMpegTsClock"])(delta, true) + " ms (" + delta + "dts) hole between fragments detected, filling it" - ); + _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn("AVC: " + Object(_utils_timescale_conversion__WEBPACK_IMPORTED_MODULE_7__["toMsFromMpegTsClock"])(delta, true) + " ms (" + delta + "dts) hole between fragments detected, filling it"); } else { - _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn( - "AVC: " + Object(_utils_timescale_conversion__WEBPACK_IMPORTED_MODULE_7__["toMsFromMpegTsClock"])(-delta, true) + " ms (" + delta + "dts) overlapping between fragments detected" - ); + _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn("AVC: " + Object(_utils_timescale_conversion__WEBPACK_IMPORTED_MODULE_7__["toMsFromMpegTsClock"])(-delta, true) + " ms (" + delta + "dts) overlapping between fragments detected"); } firstDTS = nextAvcDts; @@ -22682,9 +22587,7 @@ typeof window !== "undefined" && mp4SampleDuration = lastFrameDuration; } - _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].log( - "[mp4-remuxer]: It is approximately " + deltaToFrameEnd / 90 + " ms to the next segment; using duration " + mp4SampleDuration / 90 + " ms for the last video frame." - ); + _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].log("[mp4-remuxer]: It is approximately " + deltaToFrameEnd / 90 + " ms to the next segment; using duration " + mp4SampleDuration / 90 + " ms for the last video frame."); } else { mp4SampleDuration = lastFrameDuration; } @@ -22759,10 +22662,7 @@ typeof window !== "undefined" && var timeOffsetMpegTS = timeOffset * inputTimeScale; this.isAudioContiguous = contiguous = - contiguous || - (inputSamples.length && - nextAudioPts > 0 && - ((accurateTimeOffset && Math.abs(timeOffsetMpegTS - nextAudioPts) < 9000) || Math.abs(normalizePts(inputSamples[0].pts - initPTS, timeOffsetMpegTS) - nextAudioPts) < 20 * inputSampleDuration)); // compute normalized PTS + contiguous || (inputSamples.length && nextAudioPts > 0 && ((accurateTimeOffset && Math.abs(timeOffsetMpegTS - nextAudioPts) < 9000) || Math.abs(normalizePts(inputSamples[0].pts - initPTS, timeOffsetMpegTS) - nextAudioPts) < 20 * inputSampleDuration)); // compute normalized PTS inputSamples.forEach(function (sample) { sample.pts = normalizePts(sample.pts - initPTS, timeOffsetMpegTS); @@ -22833,9 +22733,7 @@ typeof window !== "undefined" && this.nextAudioPts = nextAudioPts = nextPts; } - _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn( - "[mp4-remuxer]: Injecting " + missing + " audio frame @ " + (nextPts / inputTimeScale).toFixed(3) + "s due to " + Math.round((1000 * delta) / inputTimeScale) + " ms gap." - ); + _utils_logger__WEBPACK_IMPORTED_MODULE_5__["logger"].warn("[mp4-remuxer]: Injecting " + missing + " audio frame @ " + (nextPts / inputTimeScale).toFixed(3) + "s due to " + Math.round((1000 * delta) / inputTimeScale) + " ms gap."); for (var j = 0; j < missing; j++) { var newStamp = Math.max(nextPts, 0); diff --git a/src/renderer/main/components/i18n-editor.js b/src/renderer/main/components/i18n-editor.js index 0482fac6..24cbb25f 100644 --- a/src/renderer/main/components/i18n-editor.js +++ b/src/renderer/main/components/i18n-editor.js @@ -9,35 +9,60 @@ export const i18nEditor = Vue.component("i18n-editor", {

i18n Editor

- + + - +

diff --git a/src/renderer/main/components/sidebar-library-item.js b/src/renderer/main/components/sidebar-library-item.js index e02ba490..419343eb 100644 --- a/src/renderer/main/components/sidebar-library-item.js +++ b/src/renderer/main/components/sidebar-library-item.js @@ -2,8 +2,14 @@ import { html } from "../html.js"; export const sidebarLibraryItem = Vue.component("sidebar-library-item", { template: html` - `, diff --git a/src/renderer/main/components/svg-icon.js b/src/renderer/main/components/svg-icon.js index b2c197dc..8ed68095 100644 --- a/src/renderer/main/components/svg-icon.js +++ b/src/renderer/main/components/svg-icon.js @@ -1,7 +1,13 @@ import { html } from "../html.js"; export const svgIcon = Vue.component("svg-icon", { - template: html`
`, + template: html` +
+ `, props: { name: { type: String, diff --git a/src/renderer/main/vueapp.js b/src/renderer/main/vueapp.js index d9ec091d..8e95b1d2 100644 --- a/src/renderer/main/vueapp.js +++ b/src/renderer/main/vueapp.js @@ -3104,9 +3104,7 @@ const app = new Vue({ return; } try { - let mfu = await app.mk.api.v3.music( - "/v1/me/library/playlists?platform=web&extend=editorialVideo&fields%5Bplaylists%5D=lastModifiedDate&filter%5Bfeatured%5D=made-for-you&include%5Blibrary-playlists%5D=catalog&fields%5Blibrary-playlists%5D=artwork%2Cname%2CplayParams%2CdateAdded" - ); + let mfu = await app.mk.api.v3.music("/v1/me/library/playlists?platform=web&extend=editorialVideo&fields%5Bplaylists%5D=lastModifiedDate&filter%5Bfeatured%5D=made-for-you&include%5Blibrary-playlists%5D=catalog&fields%5Blibrary-playlists%5D=artwork%2Cname%2CplayParams%2CdateAdded"); this.madeforyou = mfu.data; } catch (e) { console.log(e); @@ -3286,10 +3284,7 @@ const app = new Vue({ let id, songLang = ""; try { - if ( - jsonResponse["message"]["body"]["macro_calls"]["matcher.track.get"]["message"]["header"]["status_code"] == 200 && - jsonResponse["message"]["body"]["macro_calls"]["track.subtitles.get"]["message"]["header"]["status_code"] == 200 - ) { + if (jsonResponse["message"]["body"]["macro_calls"]["matcher.track.get"]["message"]["header"]["status_code"] == 200 && jsonResponse["message"]["body"]["macro_calls"]["track.subtitles.get"]["message"]["header"]["status_code"] == 200) { id = jsonResponse["message"]["body"]["macro_calls"]["matcher.track.get"]["message"]["body"]["track"]["track_id"] ?? ""; lrcfile = jsonResponse["message"]["body"]["macro_calls"]["track.subtitles.get"]["message"]["body"]["subtitle_list"][0]["subtitle"]["subtitle_body"]; vanity_id = jsonResponse["message"]["body"]["macro_calls"]["matcher.track.get"]["message"]["body"]["track"]["commontrack_vanity_id"]; @@ -4202,13 +4197,7 @@ const app = new Vue({ } this.currentArtUrl = ""; this.currentArtUrlRaw = ""; - if ( - app.mk.nowPlayingItem != null && - app.mk.nowPlayingItem.attributes != null && - app.mk.nowPlayingItem.attributes.artwork != null && - app.mk.nowPlayingItem.attributes.artwork.url != null && - app.mk.nowPlayingItem.attributes.artwork.url != "" - ) { + if (app.mk.nowPlayingItem != null && app.mk.nowPlayingItem.attributes != null && app.mk.nowPlayingItem.attributes.artwork != null && app.mk.nowPlayingItem.attributes.artwork.url != null && app.mk.nowPlayingItem.attributes.artwork.url != "") { this.currentArtUrlRaw = this.mk["nowPlayingItem"]["attributes"]["artwork"]["url"] ?? ""; this.currentArtUrl = (this.mk["nowPlayingItem"]["attributes"]["artwork"]["url"] ?? "").replace("{w}", artworkSize).replace("{h}", artworkSize); if (this.mk.nowPlayingItem._assets[0].artworkURL) { diff --git a/src/web-remote/vue.js b/src/web-remote/vue.js index e9e49672..a58f80cc 100644 --- a/src/web-remote/vue.js +++ b/src/web-remote/vue.js @@ -696,8 +696,7 @@ } function it(e, n, i, o, a, s) { var c, u, l, f; - for (c in e) - (u = e[c]), (l = n[c]), (f = nt(c)), t(u) || (t(l) ? (t(u.fns) && (u = e[c] = rt(u, s)), r(f.once) && (u = e[c] = a(f.name, u, f.capture)), i(f.name, u, f.capture, f.passive, f.params)) : u !== l && ((l.fns = u), (e[c] = l))); + for (c in e) (u = e[c]), (l = n[c]), (f = nt(c)), t(u) || (t(l) ? (t(u.fns) && (u = e[c] = rt(u, s)), r(f.once) && (u = e[c] = a(f.name, u, f.capture)), i(f.name, u, f.capture, f.passive, f.params)) : u !== l && ((l.fns = u), (e[c] = l))); for (c in n) t(e[c]) && o((f = nt(c)).name, n[c], f.capture); } function ot(e, i, o) { @@ -1166,8 +1165,7 @@ var u, l; if ("string" == typeof i) { var f; - (l = (e.$vnode && e.$vnode.ns) || F.getTagNamespace(i)), - (u = F.isReservedTag(i) ? new pe(F.parsePlatformTagName(i), a, s, void 0, void 0, e) : (a && a.pre) || !n((f = Le(e.$options, "components", i))) ? new pe(i, a, s, void 0, void 0, e) : Mt(f, a, e, s, i)); + (l = (e.$vnode && e.$vnode.ns) || F.getTagNamespace(i)), (u = F.isReservedTag(i) ? new pe(F.parsePlatformTagName(i), a, s, void 0, void 0, e) : (a && a.pre) || !n((f = Le(e.$options, "components", i))) ? new pe(i, a, s, void 0, void 0, e) : Mt(f, a, e, s, i)); } else u = Mt(i, a, e, s); return Array.isArray(u) ? u @@ -1862,9 +1860,7 @@ (function (e) { I.forEach(function (t) { e[t] = function (e, n) { - return n - ? ("component" === t && s(n) && ((n.name = n.name || e), (n = this.options._base.extend(n))), "directive" === t && "function" == typeof n && (n = { bind: n, update: n }), (this.options[t + "s"][e] = n), n) - : this.options[t + "s"][e]; + return n ? ("component" === t && s(n) && ((n.name = n.name || e), (n = this.options._base.extend(n))), "directive" === t && "function" == typeof n && (n = { bind: n, update: n }), (this.options[t + "s"][e] = n), n) : this.options[t + "s"][e]; }; }); })(e); @@ -2264,11 +2260,7 @@ } function Mr(t, n, r, i, o, a, s, c) { var u; - (i = i || e).right - ? c - ? (n = "(" + n + ")==='click'?'contextmenu':(" + n + ")") - : "click" === n && ((n = "contextmenu"), delete i.right) - : i.middle && (c ? (n = "(" + n + ")==='click'?'mouseup':(" + n + ")") : "click" === n && (n = "mouseup")), + (i = i || e).right ? (c ? (n = "(" + n + ")==='click'?'contextmenu':(" + n + ")") : "click" === n && ((n = "contextmenu"), delete i.right)) : i.middle && (c ? (n = "(" + n + ")==='click'?'mouseup':(" + n + ")") : "click" === n && (n = "mouseup")), i.capture && (delete i.capture, (n = Ir("!", n, c))), i.once && (delete i.once, (n = Ir("~", n, c))), i.passive && (delete i.passive, (n = Ir("&", n, c))), @@ -2558,9 +2550,7 @@ Oi = "transitionend", Si = "animation", Ti = "animationend"; - Ci && - (void 0 === window.ontransitionend && void 0 !== window.onwebkittransitionend && ((Ai = "WebkitTransition"), (Oi = "webkitTransitionEnd")), - void 0 === window.onanimationend && void 0 !== window.onwebkitanimationend && ((Si = "WebkitAnimation"), (Ti = "webkitAnimationEnd"))); + Ci && (void 0 === window.ontransitionend && void 0 !== window.onwebkittransitionend && ((Ai = "WebkitTransition"), (Oi = "webkitTransitionEnd")), void 0 === window.onanimationend && void 0 !== window.onwebkitanimationend && ((Si = "WebkitAnimation"), (Ti = "webkitAnimationEnd"))); var Ni = V ? window.requestAnimationFrame ? window.requestAnimationFrame.bind(window) @@ -2786,11 +2776,7 @@ var f = e.data, p = e.children, m = e.tag; - n(m) - ? ((e.elm = e.ns ? u.createElementNS(e.ns, m) : u.createElement(m, e)), g(e), h(e, p, t), n(f) && y(e, t), v(i, e.elm, o)) - : r(e.isComment) - ? ((e.elm = u.createComment(e.text)), v(i, e.elm, o)) - : ((e.elm = u.createTextNode(e.text)), v(i, e.elm, o)); + n(m) ? ((e.elm = e.ns ? u.createElementNS(e.ns, m) : u.createElement(m, e)), g(e), h(e, p, t), n(f) && y(e, t), v(i, e.elm, o)) : r(e.isComment) ? ((e.elm = u.createComment(e.text)), v(i, e.elm, o)) : ((e.elm = u.createTextNode(e.text)), v(i, e.elm, o)); } } function d(e, t) { @@ -2894,9 +2880,7 @@ ? (x(h, b, o, i, y), w && u.insertBefore(e, h.elm, u.nextSibling(m.elm)), (h = r[++p]), (b = i[--y])) : or(m, g) ? (x(m, g, o, i, d), w && u.insertBefore(e, m.elm, h.elm), (m = r[--v]), (g = i[++d])) - : (t(s) && (s = ar(r, p, v)), - t((c = n(g.key) ? s[g.key] : C(g, r, p, v))) ? f(g, o, e, h.elm, !1, i, d) : or((l = r[c]), g) ? (x(l, g, o, i, d), (r[c] = void 0), w && u.insertBefore(e, l.elm, h.elm)) : f(g, o, e, h.elm, !1, i, d), - (g = i[++d])); + : (t(s) && (s = ar(r, p, v)), t((c = n(g.key) ? s[g.key] : C(g, r, p, v))) ? f(g, o, e, h.elm, !1, i, d) : or((l = r[c]), g) ? (x(l, g, o, i, d), (r[c] = void 0), w && u.insertBefore(e, l.elm, h.elm)) : f(g, o, e, h.elm, !1, i, d), (g = i[++d])); p > v ? _(e, t(i[y + 1]) ? null : i[y + 1].elm, i, d, y, o) : d > y && $(r, p, v); })(p, h, y, o, l) : n(y) @@ -3015,8 +2999,7 @@ }) : Ji(e, t, n.context), (e._vOptions = [].map.call(e.options, Zi))) - : ("textarea" === n.tag || Yn(e.type)) && - ((e._vModifiers = t.modifiers), t.modifiers.lazy || (e.addEventListener("compositionstart", Gi), e.addEventListener("compositionend", Xi), e.addEventListener("change", Xi), W && (e.vmodel = !0))); + : ("textarea" === n.tag || Yn(e.type)) && ((e._vModifiers = t.modifiers), t.modifiers.lazy || (e.addEventListener("compositionstart", Gi), e.addEventListener("compositionend", Xi), e.addEventListener("change", Xi), W && (e.vmodel = !0))); }, componentUpdated: function (e, t, n) { if ("select" === n.tag) { @@ -3884,8 +3867,7 @@ if (e.component) return Br(e, r, i), !1; if ("select" === o) !(function (e, t, n) { - var r = - 'var $$selectedVal = Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = "_value" in o ? o._value : o.value;return ' + (n && n.number ? "_n(val)" : "val") + "});"; + var r = 'var $$selectedVal = Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = "_value" in o ? o._value : o.value;return ' + (n && n.number ? "_n(val)" : "val") + "});"; (r = r + " " + Ur(t, "$event.target.multiple ? $$selectedVal : $$selectedVal[0]")), Mr(e, "change", r, null, !0); })(e, r, i); else if ("input" === o && "checkbox" === a) @@ -4408,9 +4390,7 @@ function Ya(e) { return e.replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029"); } - new RegExp( - "\\b" + "do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,super,throw,while,yield,delete,export,import,return,switch,default,extends,finally,continue,debugger,function,arguments".split(",").join("\\b|\\b") + "\\b" - ); + new RegExp("\\b" + "do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,super,throw,while,yield,delete,export,import,return,switch,default,extends,finally,continue,debugger,function,arguments".split(",").join("\\b|\\b") + "\\b"); function Qa(e, t) { try { return new Function(e);