From 1d14288f584e1986a83be9107a581ededac527bf Mon Sep 17 00:00:00 2001 From: jboix Date: Wed, 20 Nov 2024 09:24:08 +0000 Subject: [PATCH] =?UTF-8?q?Deploy=20preview=20for=20PR=2045=20=F0=9F=9B=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pr-45/assets/{index-XKQDRvQE.js => index-9SZSMbQ4.js} | 4 ++-- .../assets/{index-XKQDRvQE.js.map => index-9SZSMbQ4.js.map} | 2 +- pr-preview/pr-45/assets/quality-menu-B8MP43Ca.js | 2 -- pr-preview/pr-45/assets/quality-menu-DGFFFm6m.js | 2 ++ ...lity-menu-B8MP43Ca.js.map => quality-menu-DGFFFm6m.js.map} | 2 +- pr-preview/pr-45/assets/quality-menu-PMLfcXBG.css | 1 + pr-preview/pr-45/index.html | 2 +- pr-preview/pr-45/static/showcases/quality-menu.html | 4 ++-- 8 files changed, 10 insertions(+), 9 deletions(-) rename pr-preview/pr-45/assets/{index-XKQDRvQE.js => index-9SZSMbQ4.js} (99%) rename pr-preview/pr-45/assets/{index-XKQDRvQE.js.map => index-9SZSMbQ4.js.map} (69%) delete mode 100644 pr-preview/pr-45/assets/quality-menu-B8MP43Ca.js create mode 100644 pr-preview/pr-45/assets/quality-menu-DGFFFm6m.js rename pr-preview/pr-45/assets/{quality-menu-B8MP43Ca.js.map => quality-menu-DGFFFm6m.js.map} (99%) create mode 100644 pr-preview/pr-45/assets/quality-menu-PMLfcXBG.css diff --git a/pr-preview/pr-45/assets/index-XKQDRvQE.js b/pr-preview/pr-45/assets/index-9SZSMbQ4.js similarity index 99% rename from pr-preview/pr-45/assets/index-XKQDRvQE.js rename to pr-preview/pr-45/assets/index-9SZSMbQ4.js index bf6cf31..e6d0dd1 100644 --- a/pr-preview/pr-45/assets/index-XKQDRvQE.js +++ b/pr-preview/pr-45/assets/index-9SZSMbQ4.js @@ -806,7 +806,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`),_=c,w=f),h===void 0&&( Pillarbox Demo - Quality Menu - + @@ -1003,4 +1003,4 @@ https://github.com/highlightjs/highlight.js/issues/2277`),_=c,w=f),h===void 0&&( `},x(jt,"properties",{debug:{type:Boolean,state:!0}}),x(jt,"styles",[q,B(Sr)]);customElements.define("demo-header",jt);class So extends N{constructor(){super(),this.route=v.currentRoute,v.addEventListener("routechanged",({detail:{route:n}})=>{var e;(e=this.route)==null||e.destroy(),this.route=n})}render(){return nn(`<${this.route.component}>`)}}x(So,"properties",{route:{state:!0}});customElements.define("route-outlet",So);const et=Se.loadPreferences();z.host=et.dataProviderHost;v.start({defaultPath:"examples"});v.queryParams.debug?(et.debug=v.queryParams.debug==="true",Se.savePreferences(et)):et.debug&&v.updateState({debug:"true"}); -//# sourceMappingURL=index-XKQDRvQE.js.map +//# sourceMappingURL=index-9SZSMbQ4.js.map diff --git a/pr-preview/pr-45/assets/index-XKQDRvQE.js.map b/pr-preview/pr-45/assets/index-9SZSMbQ4.js.map similarity index 69% rename from pr-preview/pr-45/assets/index-XKQDRvQE.js.map rename to pr-preview/pr-45/assets/index-9SZSMbQ4.js.map index 7582542..b1866ed 100644 --- a/pr-preview/pr-45/assets/index-XKQDRvQE.js.map +++ b/pr-preview/pr-45/assets/index-9SZSMbQ4.js.map @@ -1 +1 @@ -{"version":3,"file":"index-XKQDRvQE.js","sources":["../../src/components/dialog/demo-dialog-component.js","../../src/layout/content/settings/preferences-provider.js","../../src/utils/il-provider.js","../../src/components/player/player.js","../../node_modules/lit-html/directives/class-map.js","../../src/layout/content/examples/load-media-form-component.js","../../src/components/content-link/content-link-component.js","../../src/layout/content/examples/examples.js","../../node_modules/lit-html/directives/map.js","../../node_modules/lit-html/directives/when.js","../../src/layout/content/examples/examples-page.js","../../src/components/spinner/spinner-component.js","../../src/components/intersection-observer/intersection-observer-component.js","../../src/components/scroll-to-top/scroll-to-top-component.js","../../src/utils/string-utils.js","../../src/layout/content/lists/lists-page-state-manager.js","../../src/layout/content/lists/lists-sections.js","../../src/layout/content/lists/lists-page.js","../../src/layout/content/search/search-bar-component.js","../../src/layout/content/search/search-page.js","../../src/components/toggle-switch/toggle-switch-component.js","../../src/layout/content/settings/settings-page.js","../../node_modules/highlight.js/lib/core.js","../../node_modules/highlight.js/es/languages/javascript.js","../../src/components/code-block/code-block.js","../../src/layout/content/showcase/showcase-component.js","../../static/showcases/start-time.html?raw","../../static/showcases/multi-player.html?raw","../../static/showcases/blocked-segment.html?raw","../../static/showcases/chapters.html?raw","../../static/showcases/skip-credits.html?raw","../../static/showcases/playlist.html?raw","../../static/showcases/quality-menu.html?raw","../../src/layout/content/showcase/example-parser.js","../../src/layout/content/showcase/showcase-page.js","../../src/layout/header/demo-header-component.js","../../src/router/route-outlet-component.js","../../src/index.js"],"sourcesContent":["/**\n * Defines the behaviour of the demo dialog.\n *\n * @module\n */\nimport { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../theme/theme';\nimport componentCSS from './demo-dialog-component.scss?inline';\n\nexport class DemoDialog extends LitElement {\n static properties = {\n open: { type: Boolean, reflect: true }\n };\n\n static styles = [\n theme, animations, unsafeCSS(componentCSS)\n ];\n\n #dialog;\n\n constructor() {\n super();\n this.open = false;\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (_changedProperties.has('open')) {\n if (this.open) {\n this.#dialog.showModal();\n this.#dialog.classList.toggle('slide-up-fade-in', true);\n } else {\n this.#dialog.close();\n }\n }\n }\n\n firstUpdated(_changedProperties) {\n super.firstUpdated(_changedProperties);\n this.#dialog = this.shadowRoot.querySelector('dialog');\n }\n\n #onDialogClosed() {\n this.dispatchEvent(new CustomEvent('close'));\n }\n\n #onDialogClicked(e) {\n if (this.#dialog !== e.target) return;\n this.open = false;\n }\n\n render() {\n return html`\n e.target.classList.remove('slide-up-fade-in')}\">\n \n \n \n `;\n }\n}\n\ncustomElements.define('demo-dialog', DemoDialog);\n","/**\n * Utility class for loading and saving preferences to local storage.\n *\n * @class PreferencesProvider\n */\nclass PreferencesProvider {\n /**\n * Load preferences from local storage.\n *\n * @static\n * @returns {Object} An object representing the loaded preferences.\n */\n static loadPreferences() {\n return JSON.parse(localStorage.getItem('preferences')) || {};\n }\n\n /**\n * Save preferences to local storage.\n *\n * @static\n * @param {Object} preferences - An object representing the preferences to be saved.\n * @returns {void}\n */\n static savePreferences(preferences) {\n localStorage.setItem('preferences', JSON.stringify(preferences));\n }\n}\n\nexport default PreferencesProvider;\n","export const IL_DEFAULT_HOST = 'il.srgssr.ch';\n\nconst DEFAULT_QUERY_PARAMS = {\n vector: 'srgplay'\n};\nconst DEFAULT_SEARCH_PARAMS = {\n includeAggregations: false,\n includeSuggestions: false,\n sortBy: 'default',\n sortDir: 'desc',\n pageSize: 50,\n ...DEFAULT_QUERY_PARAMS\n};\nconst DEFAULT_SHOWLIST_PARAMS = {\n onlyActiveShows: true,\n ...DEFAULT_QUERY_PARAMS\n};\n\nconst toMedia = ({ title, urn, mediaType, date, duration }) => ({\n title, urn, mediaType, date, duration\n});\n\n/**\n * Class representing a provider for the integration layer.\n *\n * @class\n */\nclass ILProvider {\n #host;\n\n /**\n * Creates an instance of ILProvider.\n *\n * @param {string} [host='il.srgssr.ch'] - The hostname for the integration layer (without the protocol).\n */\n constructor(host = IL_DEFAULT_HOST) {\n this.host = host;\n }\n\n /**\n * Get the current hostname for the integration layer.\n *\n * @returns {string} the hostname for the integration layer.\n */\n get host() {\n return this.#host;\n }\n\n /**\n * Set the hostname for the integration layer (without the protocol). Forces\n * `il.srgssr.ch` if null, undefined or empty string is passed.\n *\n * @param {string} host The hostname for the integration layer,\n */\n set host(host) {\n this.#host = host || IL_DEFAULT_HOST;\n }\n\n /**\n * Performs a search for media content based on the provided business unit and query.\n *\n * @param {string} bu - The business unit for which the search is performed (rsi, rtr, rts, srf or swi).\n * @param {string} query - The search query.\n * @param {AbortSignal} [signal=undefined] - (Optional) An abort signal,\n * allows to abort the query through an abort controller.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the search results.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async search(bu, query, signal = undefined) {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/searchResultMediaList`,\n { ...DEFAULT_SEARCH_PARAMS, q: query },\n signal\n );\n const toResults = (data) => data.searchResultMediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves a list of topics for the specified business unit and transmission type.\n *\n * @param {string} bu - The business unit for which to retrieve topics (rsi, rtr, rts, srf, or swi).\n * @param {string} [transmission='tv'] - The transmission type ('tv' or 'radio').\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and URN of the topics.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async topics(bu, transmission = 'tv') {\n const data = await this.#fetch(`/${bu.toLowerCase()}/topicList/${transmission}`);\n\n return data.topicList.map(\n ({ title, urn }) => ({ title, urn })\n );\n }\n\n /**\n * Retrieves the latest media content for a specific topic.\n *\n * @param {string} topicUrn - The URN (Unique Resource Name) of the topic.\n * @param {number} [pageSize=30] - The maximum number of episodes to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async latestByTopic(topicUrn, pageSize = 30) {\n const data = await this.#fetch(`/mediaList/latest/byTopicUrn/${topicUrn}`, { pageSize });\n\n const toResults = (data) => data.mediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves a list of shows for the specified business unit, transmission type, and ordering.\n *\n * @param {string} bu - The business unit for which to retrieve shows (rsi, rtr, rts, srf, or swi).\n * @param {string} [pageSize='unlimited'] - The maximum number of shows to retrieve. Use 'unlimited' for all shows.\n * @param {string} [transmission='tv'] - The transmission type ('tv' or 'radio').\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and URN of the shows.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async shows(bu, pageSize = 'unlimited', transmission = 'tv') {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/showList/${transmission}/alphabetical`,\n { ...DEFAULT_SHOWLIST_PARAMS, pageSize }\n );\n\n return data.showList.map(\n ({ title, urn }) => ({ title, urn })\n );\n }\n\n /**\n * Retrieves the latest media content for a specific show.\n *\n * @param {string} showUrn - The URN (Unique Resource Name) of the show.\n * @param {number} [pageSize=30] - The maximum number of episodes to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async latestByShow(showUrn, pageSize = 30) {\n const data = await this.#fetch(\n `/episodeComposition/latestByShow/byUrn/${showUrn}`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n\n const toResults = (data) => data.episodeList\n .map(({ mediaList }) => mediaList[0])\n .map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves editorial media content for the specified business unit.\n *\n * @param {string} bu - The business unit for which to retrieve editorial media (rsi, rtr, rts, srf, or swi).\n * @param {number} [pageSize=30] - The maximum number of editorial media items to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async editorial(bu, pageSize = 30) {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/mediaList/video/editorial`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n\n const toResults = (data) => data.mediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves livestream media content for the specified business unit and media type.\n *\n * @param {string} bu - The business unit for which to retrieve livestreams (rsi, rtr, rts, srf, or swi).\n * @param {string} [mediaType='video'] - The media type ('video' or 'audio').\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and URN of the livestream media content.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async livestreams(bu, mediaType = 'video') {\n const data = await this.#fetch(`/${bu.toLowerCase()}/mediaList/${mediaType}/livestreams`);\n\n return data.mediaList.map(toMedia);\n }\n\n /**\n * Retrieves scheduled livestream media content for the specified business unit.\n *\n * @param {string} bu - The business unit for which to retrieve scheduled livestreams (rsi, rtr, rts, srf, or swi).\n * @param {number} [pageSize=10] - The maximum number of scheduled livestreams to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async scheduledLivestream(bu, pageSize = 10) {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/mediaList/video/scheduledLivestreams`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n const toResults = (data) => data.mediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves media content for the livecenter for the specified business unit.\n *\n * @param {string} bu - The business unit for which to retrieve livecenter media (rsi, rtr, rts, srf, or swi).\n * @param {number} [pageSize=10] - The maximum number of livecenter media items to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async livecenter(bu, pageSize = 10) {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/mediaList/video/scheduledLivestreams/livecenter`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n const toResults = (data) => data.mediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves a list of channels for the specified business unit and transmission type.\n *\n * @param {string} bu - The business unit for which to retrieve channels (rsi, rtr, rts, srf, or swi).\n * @param {string} [transmission='radio'] - The transmission type ('tv' or 'radio').\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and ID of the channels.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async channels(bu, transmission = 'radio') {\n const data = await this.#fetch(`/${bu.toLowerCase()}/channelList/${transmission}`);\n\n return data.channelList.map(\n ({ title, id }) => ({ title, id })\n );\n }\n\n /**\n * Retrieves radio shows for the specified business unit and channel.\n *\n * @param {string} bu - The business unit for which to retrieve radio shows (rsi, rtr, rts, srf, or swi).\n * @param {string} channelId - The ID of the channel.\n * @param {string} [pageSize='unlimited'] - The maximum number of radio shows to retrieve. Use 'unlimited' for all shows.\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and URN of the radio shows.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async radioShowByChannel(bu, channelId, pageSize = 'unlimited') {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/showList/radio/alphabeticalByChannel/${channelId}`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n\n return data.showList.map(\n ({ title, urn }) => ({ title, urn })\n );\n }\n\n /**\n * Asynchronously fetches data from the IL for the specified path and parameters.\n *\n * @private\n * @param {string} path - The path to fetch data from.\n * @param {Object} [params=DEFAULT_QUERY_PARAMS] - (Optional) parameters for the request.\n * @param {AbortSignal} [signal=undefined] - (Optional) AbortSignal to abort the request.\n *\n * @returns {Promise<*>} A Promise that resolves to the JSON response data.\n *\n * @throws {Response} If the HTTP response is not ok (status code other than 2xx).\n * @throws {Error} If the fetch operation fails for any other reason.\n */\n async #fetch(path, params = DEFAULT_QUERY_PARAMS, signal = undefined) {\n const queryParams = new URLSearchParams(params).toString();\n const url = `https://${this.host}/integrationlayer/2.0/${path.replace(/^\\/+/, '')}?${queryParams}`;\n\n return fetch(url, { signal }).then(response => {\n if (!response.ok) {\n return Promise.reject(response);\n }\n\n return response.json();\n }).catch((reason) => {\n return Promise.reject(reason);\n });\n }\n\n /**\n * Generates a function that, when called, retrieves the next set of data and\n * returns a new object with updated results and the next function.\n *\n * @private\n * @template T - The type of data returned by the resultMapper function.\n *\n * @param {string} nextUrl - The URL for fetching the next set of data.\n * @param {(data: any) => T} resultMapper - A function to map the raw data to the desired format.\n *\n * @returns {(signal?: AbortSignal) => Promise<{ results: T, next: function }>} - A function that,\n * when called, retrieves the next set of data and returns a new object with updated results and the next function.\n */\n #nextProvider(nextUrl, resultMapper) {\n return async(signal = undefined) => {\n const nextData = await fetch(nextUrl, { signal }).then(response => {\n if (!response.ok) {\n return Promise.reject(response);\n }\n\n return response.json();\n }).catch((reason) => {\n return Promise.reject(reason);\n });\n\n const nextResults = resultMapper(nextData);\n\n return {\n results: nextResults,\n next: this.#nextProvider(nextData.next, resultMapper)\n };\n };\n }\n}\n\nexport default new ILProvider();\n","/**\n * Initialized the demo player.\n *\n * @module\n */\nimport '../dialog/demo-dialog-component';\nimport PreferencesProvider\n from '../../layout/content/settings/preferences-provider';\nimport router from '../../router/router';\nimport Pillarbox from '@srgssr/pillarbox-web';\nimport { IL_DEFAULT_HOST } from '../../utils/il-provider.js';\n\nconst DEMO_PLAYER_ID = 'demo-player';\nconst DEFAULT_OPTIONS = {\n restoreEl: true\n};\n\nconst preferencesToPlayerOptions = (preferences) => {\n return {\n muted: preferences.muted ?? true,\n autoplay: preferences.autoplay ?? false,\n debug: preferences.debug ?? false,\n srgOptions: {\n dataProviderHost: preferences.dataProviderHost ?? IL_DEFAULT_HOST\n }\n };\n};\n/**\n * Creates and configures a Pillarbox player.\n *\n * @param {Object} options - (Optional) options to customize the player behaviour.\n *\n * @returns {Object} The configured Pillarbox player instance.\n */\nconst createPlayer = (options = {}) => {\n window.player = new Pillarbox(DEMO_PLAYER_ID, {\n ...DEFAULT_OPTIONS,\n ...preferencesToPlayerOptions(PreferencesProvider.loadPreferences()),\n ...options\n });\n\n return window.player;\n};\n\n/**\n * Disposes of the Pillarbox video player instance.\n */\nconst destroyPlayer = () => {\n Pillarbox.getPlayer(DEMO_PLAYER_ID).dispose();\n window.player = null;\n};\n\n// Expose Pillarbox and player in the window object for debugging\nwindow.pillarbox = Pillarbox;\n// Configure the dialog\nconst playerDialog = document.querySelector('demo-dialog');\n\nconst toParams = (keySystems) => {\n const vendor = Object.keys(keySystems ?? {})[0];\n\n if (!vendor) {\n return {};\n }\n\n return {\n vendor,\n ...(vendor === 'com.apple.fps.1_0' ? keySystems[vendor] : { licenseUri: keySystems[vendor] })\n };\n};\n\nconst toKeySystem = (params) => {\n if (!params.vendor) {\n return undefined;\n }\n\n const { certificateUri, licenseUri } = params;\n\n if (params.vendor === 'com.apple.fps.1_0') {\n return { [params.vendor]: { certificateUri, licenseUri } };\n }\n\n return { [params.vendor]: licenseUri };\n};\n\nexport const asQueryParams = ({ src, type, keySystems }) => {\n return new URLSearchParams({ src, type, ...toParams(keySystems) }).toString();\n};\n\nplayerDialog.addEventListener('close', () => {\n destroyPlayer();\n router.updateState({}, ['src', 'type', 'vendor', 'certificateUri', 'licenseUri']);\n});\n\nconst loadPlayerFromRouter = (e) => {\n if (window.player) {\n return;\n }\n\n const params = e.detail.queryParams;\n\n if ('src' in params) {\n const { src, type } = params;\n const keySystems = toKeySystem(params);\n\n openPlayerModal({ src, type, keySystems });\n }\n};\n\nrouter.addEventListener('routechanged', loadPlayerFromRouter);\nrouter.addEventListener('queryparams', loadPlayerFromRouter);\n\n/**\n * Opens a modal containing a video player with specified source and type. Can only\n * load URN if the type 'srgssr/urn`is explicitly provided, otherwise the created\n * Pillarbox player tries to guess the type.\n *\n * @param {object} options - An object containing the source and type of the video to be played.\n * @param {string} options.src - The source URL of the video.\n * @param {string} [options.type] - (Optional) The type/format of the video (e.g., 'video/mp4').\n * @param {object} [options.keySystems] - (Optional) The DRM configuration for DRM protected sources.\n * @param {object} [options.playerOptions] - (Optional) Additional configuration for the player.\n * @param {Boolean} shouldUpdateRouter - Whether the router should be updated or not (Default: true).\n *\n * @returns {Object} The configured Pillarbox player instance.\n */\nexport const openPlayerModal = (\n { src, type, keySystems, playerOptions },\n shouldUpdateRouter = true\n) => {\n const player = createPlayer(playerOptions ?? {});\n\n playerDialog.open = true;\n player.src({ src, type, keySystems });\n\n if (shouldUpdateRouter) {\n router.updateState({\n src,\n ...(type ? { type } : {}),\n ...toParams(keySystems)\n });\n }\n\n return player;\n};\n","import{noChange as t}from\"../lit-html.js\";import{directive as s,Directive as i,PartType as r}from\"../directive.js\";\n/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */const e=s(class extends i{constructor(t){if(super(t),t.type!==r.ATTRIBUTE||\"class\"!==t.name||t.strings?.length>2)throw Error(\"`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.\")}render(t){return\" \"+Object.keys(t).filter((s=>t[s])).join(\" \")+\" \"}update(s,[i]){if(void 0===this.st){this.st=new Set,void 0!==s.strings&&(this.nt=new Set(s.strings.join(\" \").split(/\\s/).filter((t=>\"\"!==t))));for(const t in i)i[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(i)}const r=s.element.classList;for(const t of this.st)t in i||(r.remove(t),this.st.delete(t));for(const t in i){const s=!!i[t];s===this.st.has(t)||this.nt?.has(t)||(s?(r.add(t),this.st.add(t)):(r.remove(t),this.st.delete(t)))}return t}});export{e as classMap};\n//# sourceMappingURL=class-map.js.map\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport componentCSS from './load-media-form-component.scss?inline';\nimport { classMap } from 'lit/directives/class-map.js';\n\n/**\n * LoadMediaFormComponent is a LitElement that provides a user interface for loading media content.\n *\n * @element load-media-form\n *\n * @fires LoadMediaFormComponent#submit-media - Dispatched when the user submits media with the specified details.\n *\n * @prop {String} src - The URL or URN of the media content to be loaded.\n * @prop {{vendor: String, certificateUri: String, licenseUri: String}} drmSettings - DRM settings for the loaded media.\n */\nexport class LoadMediaFormComponent extends LitElement {\n static properties = {\n src: { type: String },\n drmSettings: { type: Object },\n drmSettingsShown: { state: true, type: Boolean }\n };\n\n static styles = [theme, animations, unsafeCSS(componentCSS)];\n\n constructor() {\n super();\n\n this.src = '';\n this.#initDrmSettings();\n }\n\n #initDrmSettings() {\n this.drmSettings = {\n vendor: '',\n certificateUri: '',\n licenseUri: ''\n };\n }\n\n #getSource() {\n try {\n return new URL(this.src).searchParams.get('urn') ?? this.src;\n } catch {\n return this.src;\n }\n }\n\n #submitMedia() {\n const src = this.#getSource()?.trim();\n const type = src.startsWith('urn:') ? 'srgssr/urn' : undefined;\n const keySystems = this.#keySystems;\n\n /**\n * Custom event dispatched by LoadMediaFormComponent when the user submits media.\n *\n * @event LoadMediaFormComponent#submit-media\n * @type {CustomEvent}\n * @property {Object} detail - The event detail object.\n * @property {string} detail.src - The URL or URN of the media content to be loaded.\n * @property {string | undefined} detail.type - The type of media. Undefined if the type cannot be determined.\n * @property {Object | undefined} detail.keySystems - DRM key systems for the loaded media.\n */\n this.dispatchEvent(new CustomEvent('submit-media', {\n detail: { src, type, keySystems }\n }));\n }\n\n #handleLoadBarKeyUp(event) {\n this.src = event.target.value;\n\n if (event.key === 'Enter' && this.src) {\n this.#submitMedia();\n }\n }\n\n get #keySystems() {\n if (!this.drmSettings?.vendor) {\n return undefined;\n }\n\n return this.#toKeySystem();\n }\n\n #toKeySystem() {\n const certificateUri = this.drmSettings.certificateUri?.trim();\n const licenseUri = this.drmSettings.licenseUri?.trim();\n\n if (this.drmSettings.vendor === 'com.apple.fps.1_0') {\n return { [this.drmSettings.vendor]: { certificateUri, licenseUri } };\n }\n\n return { [this.drmSettings.vendor]: licenseUri };\n }\n\n render() {\n const btnSettingsClassMap = {\n spin: this.drmSettingsShown === true,\n 'spin-back': this.drmSettingsShown === false\n };\n\n return html`\n
e.target.classList.remove('fade-in')}\">\n
\n insert_link\n \n \n
\n \n ${this.#drmSettingsTemplate()}\n\n \n
\n `;\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (_changedProperties.has('drmSettingsShown') && this.drmSettingsShown) {\n this.shadowRoot.querySelector('.drm-settings-container').classList.add('active');\n }\n }\n\n #onFormAnimationEnd(e) {\n e.target.classList.toggle('active', !e.target.classList.contains('fade-out-shrink'));\n e.target.classList.remove('fade-in-grow', 'fade-out-shrink');\n }\n\n #formAnimationClassMap() {\n return {\n 'fade-in-grow': this.drmSettingsShown === true,\n 'fade-out-shrink': this.drmSettingsShown === false\n };\n }\n\n #drmSettingsTemplate() {\n return html`\n
this.#onFormAnimationEnd(e)}\">\n

DRM Settings

\n \n { this.drmSettings.licenseUri = e.target.value; }}\">\n { this.drmSettings.certificateUri = e.target.value; }}\">\n \n
\n
\n `;\n }\n}\n\ncustomElements.define('load-media-form', LoadMediaFormComponent);\n","import router from '../../router/router';\nimport { html, LitElement, unsafeCSS } from 'lit';\nimport componentCSS from './content-link-component.scss?inline';\n\n/**\n * A component for rendering a content link.\n *\n * @prop {string} href - The URL to navigate to.\n * @prop {string} title - The title attribute for the link.\n *\n * @csspart a - The anchor element.\n * @csspart title - The title span within the anchor.\n * @csspart description - The slot for additional description content within the anchor.\n *\n * @example\n * \n * Additional Description Content\n * \n */\nexport class ContentLinkComponent extends LitElement {\n static properties = {\n href: {}\n };\n\n static styles = unsafeCSS(componentCSS);\n\n #onClick = (event) => {\n event.preventDefault();\n\n const url = new URL(`${window.location.origin}/${this.href}`);\n const queryParams = Object.fromEntries(url.searchParams.entries());\n\n router.navigateTo(url.pathname, queryParams);\n };\n\n connectedCallback() {\n super.connectedCallback();\n this.addEventListener('click', this.#onClick);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.removeEventListener('click', this.#onClick);\n }\n\n render() {\n return html`\n \n ${this.title}\n \n \n `;\n }\n}\n\ncustomElements.define('content-link', ContentLinkComponent);\n","const EXAMPLES = {\n SRGSSR: [\n {\n title: 'Horizontal video',\n src: 'urn:rts:video:14827306',\n type: 'srgssr/urn'\n },\n {\n title: 'Square video',\n src: 'urn:rts:video:8393241',\n type: 'srgssr/urn'\n },\n {\n title: 'Vertical video',\n src: 'urn:rts:video:13444390',\n type: 'srgssr/urn'\n },\n {\n title: 'Token-protected video',\n description: 'Ski alpin, Slalom Messieurs',\n src: 'urn:swisstxt:video:rts:c56ea781-99ad-40c3-8d9b-444cc5ac3aea',\n type: 'srgssr/urn'\n },\n {\n title: 'Superfluously token-protected video',\n description: 'Telegiornale flash',\n src: 'urn:rsi:video:15916771',\n type: 'srgssr/urn'\n },\n {\n title: 'DRM-protected video',\n description: 'Top Models 8870',\n src: 'urn:rts:video:13639837',\n type: 'srgssr/urn'\n },\n {\n title: 'Live video',\n description: 'SRF 1',\n src: 'urn:srf:video:c4927fcf-e1a0-0001-7edd-1ef01d441651',\n type: 'srgssr/urn'\n },\n {\n title: 'DVR video livestream',\n description: 'RTS 1',\n src: 'urn:rts:video:3608506',\n type: 'srgssr/urn'\n },\n {\n title: 'DVR audio livestream',\n description: 'Couleur 3 (DVR)',\n src: 'urn:rts:audio:3262363',\n type: 'srgssr/urn'\n },\n {\n title: 'On-demand audio stream',\n description: 'Il lavoro di TerraProject per una fotografia documentaria',\n src: 'urn:rsi:audio:8833144',\n type: 'srgssr/urn'\n },\n {\n title: 'Expired URN',\n description: 'Content that is not available anymore',\n src: 'urn:rts:video:13382911',\n type: 'srgssr/urn'\n },\n {\n title: 'Unknown URN',\n description: 'Content that does not exist',\n src: 'urn:srf:video:unknown',\n type: 'srgssr/urn'\n }\n ],\n HLS: [\n {\n title: 'VOD - HLS',\n description: 'Switzerland says sorry! The fondue invasion',\n src: 'https://swi-vod.akamaized.net/videoJson/47603186/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'VOD - HLS (short)',\n description: 'Des violents orages ont touché Ajaccio, chef-lieu de la Corse, jeudi',\n src: 'https://rts-vod-amd.akamaized.net/ww/13317145/f1d49f18-f302-37ce-866c-1c1c9b76a824/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Brain Farm Skate Phantom Flex',\n description: '4K video',\n src: 'https://sample.vodobox.net/skate_phantom_flex_4k/skate_phantom_flex_4k.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Video livestream - HLS',\n description: 'Couleur 3 en vidéo (live)',\n src: 'https://rtsc3video.akamaized.net/hls/live/2042837/c3video/3/playlist.m3u8?dw=0',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Video livestream with DVR - HLS',\n description: 'Couleur 3 en vidéo (DVR)',\n src: 'https://rtsc3video.akamaized.net/hls/live/2042837/c3video/3/playlist.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Video livestream with DVR and timestamps - HLS',\n description: 'Tageschau',\n src: 'https://tagesschau.akamaized.net/hls/live/2020115/tagesschau/tagesschau_1/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Audio livestream - HLS',\n description: 'Couleur 3 (DVR)',\n src: 'https://lsaplus.swisstxt.ch/audio/couleur3_96.stream/playlist.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Basic 4:3',\n description: '4x3 aspect ratio, H.264 @ 30Hz',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/bipbop_4x3/bipbop_4x3_variant.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Basic 16:9',\n description: '16x9 aspect ratio, H.264 @ 30Hz',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/bipbop_16x9/bipbop_16x9_variant.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Advanced 16:9 (TS)',\n description: '16x9 aspect ratio, H.264 @ 30Hz and 60Hz, Transport stream',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_ts/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Advanced 16:9 (fMP4)',\n description: '16x9 aspect ratio, H.264 @ 30Hz and 60Hz, Fragmented MP4',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_fmp4/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Advanced 16:9 (HEVC/H.264)',\n description: '16x9 aspect ratio, H.264 and HEVC @ 30Hz and 60Hz',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/bipbop_adv_example_hevc/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Atmos',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/adv_dv_atmos/main.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple WWDC Keynote 2023',\n src: 'https://events-delivery.apple.com/0105cftwpxxsfrpdwklppzjhjocakrsk/m3u8/vod_index-PQsoJoECcKHTYzphNkXohHsQWACugmET.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple tv trailer',\n description: 'Lot of audios and subtitles choices',\n src: 'https://play-edge.itunes.apple.com/WebObjects/MZPlayLocal.woa/hls/subscription/playlist.m3u8?cc=CH&svcId=tvs.vds.4021&a=1522121579&isExternal=true&brandId=tvs.sbd.4000&id=518077009&l=en-GB&aec=UHD\\n',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Multiple subtitles and audio tracks',\n description: 'On some devices codec may crash',\n src: 'https://bitmovin-a.akamaihd.net/content/sintel/hls/playlist.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: '4K, HEVC',\n src: 'https://cdn.bitmovin.com/content/encoding_test_dash_hls/4k/hls/4k_profile/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'VoD, single audio track',\n src: 'https://bitmovin-a.akamaihd.net/content/MI201109210084_1/m3u8s/f08e80da-bf1d-4e3d-8899-f0f6155f6efa.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'AES-128',\n src: 'https://bitmovin-a.akamaihd.net/content/art-of-motion_drm/m3u8s/11331.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'HLS - Fragmented MP4',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.ism/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'HLS - Alternate audio language',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-lang.ism/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'HLS - Audio only',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-lang.ism/.m3u8?filter=(type!=%22video%22)',\n type: 'application/x-mpegURL'\n },\n {\n title: 'HLS - Trickplay',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/no-handler-origin/tears-of-steel/tears-of-steel-trickplay.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Limiting bandwidth use',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.ism/.m3u8?max_bitrate=800000',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Dynamic Track Selection',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.ism/.m3u8?filter=%28type%3D%3D%22audio%22%26%26systemBitrate%3C100000%29%7C%7C%28type%3D%3D%22video%22%26%26systemBitrate%3C1024000%29',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Pure live',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Timeshift (5 minutes)',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.m3u8?time_shift=300',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Live audio',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.m3u8?filter=(type!=%22video%22)',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Pure live (scte35)',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/scte35.isml/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'fMP4, clear',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-fmp4.ism/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'fMP4, HEVC 4K',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-hevc.ism/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Test1',\n description: 'Forced subtitles',\n src: 'https://prd.vod-srgssr.ch/origin/1053457/fr/master.m3u8?complexSubs=true',\n type: 'application/x-mpegURL'\n }\n ],\n DASH: [\n {\n title: 'VoD - Dash (H264)',\n src: 'https://storage.googleapis.com/wvmedia/clear/h264/tears/tears.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'VoD - Dash Widewine cenc (H264)',\n src: 'https://storage.googleapis.com/wvmedia/cenc/h264/tears/tears.mpd',\n type: 'application/dash+xml',\n keySystems: {\n 'com.widevine.alpha': 'https://proxy.uat.widevine.com/proxy?video_id=2015_tears&provider=widevine_test'\n }\n },\n {\n title: 'VoD - Dash (H265)',\n src: 'https://storage.googleapis.com/wvmedia/clear/hevc/tears/tears.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'VoD - Dash widewine cenc (H265)',\n src: 'https://storage.googleapis.com/wvmedia/cenc/hevc/tears/tears.mpd',\n type: 'application/dash+xml',\n keySystems: {\n 'com.widevine.alpha': 'https://proxy.uat.widevine.com/proxy?video_id=2015_tears&provider=widevine_test'\n }\n },\n {\n title: 'VoD - Dash - MP4',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.mp4/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Fragmented MP4',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - TrickPlay',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/no-handler-origin/tears-of-steel/tears-of-steel-trickplay.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Tiled thumbnails (live/timeline)',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-tiled-thumbnails-timeline.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Accessibility - hard of hearing',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-hoh-subs.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Single - fragmented TTML',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-en.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Multiple - RFC 5646 language tags',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-rfc5646.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Multiple - fragmented TTML',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-ttml.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Audio only',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-lang.ism/.mpd?filter=(type!=%22video%22)',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Multiple audio codecs',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-codec.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Alternate audio language',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-lang.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Accessibility - audio description',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-desc-aud.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Pure live',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Timeshift (5 minutes)',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.mpd?time_shift=300',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - DVB DASH low latency',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live-low-latency.isml/.mpd',\n type: 'application/dash+xml'\n }\n ],\n MP4: [\n {\n title: 'VOD - MP4',\n description: 'The dig',\n src: 'https://media.swissinfo.ch/media/video/dddaff93-c2cd-4b6e-bdad-55f75a519480/rendition/154a844b-de1d-4854-93c1-5c61cd07e98c.mp4',\n type: 'video/mp4'\n },\n {\n title: 'AVC Progressive',\n src: 'https://bitmovin-a.akamaihd.net/content/MI201109210084_1/MI201109210084_mpeg-4_hd_high_1080p25_10mbits.mp4',\n type: 'video/mp4'\n }\n ],\n AOD: [\n {\n title: 'Audio HLS',\n description: 'Content with PTS rollover',\n src: 'https://cdn.rts.ch/audio-sample/playlist.m3u8',\n type: 'application/x-mpegURL'\n }\n ]\n};\n\nexport default EXAMPLES;\n","/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nfunction*o(o,f){if(void 0!==o){let i=0;for(const t of o)yield f(t,i++)}}export{o as map};\n//# sourceMappingURL=map.js.map\n","/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nfunction n(n,r,t){return n?r(n):t?.(n)}export{n as when};\n//# sourceMappingURL=when.js.map\n","import router from '../../../router/router';\nimport { css, html, LitElement } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport './load-media-form-component';\nimport '../../../components/content-link/content-link-component';\nimport Examples from './examples';\nimport { map } from 'lit/directives/map.js';\nimport { when } from 'lit/directives/when.js';\nimport { asQueryParams, openPlayerModal } from '../../../components/player/player';\n\n/**\n * A web component that represents the examples page.\n *\n * @element examples-page\n */\nexport class ExamplesPage extends LitElement {\n static styles = [\n theme, animations, css`\n .example-section p {\n margin-bottom: 0;\n color: var(--color-5);\n font-size: var(--size-3);\n text-align: left;\n }`\n ];\n\n render() {\n return html`\n openPlayerModal(e.detail)}\">\n \n\n \n
e.target.classList.remove('fade-in')}\">\n ${map(Object.entries(Examples), ([section, examples]) => html`\n
\n

${section}

\n ${map(examples, example => html`\n \n ${when(example.description, () => html`\n ${example.title}\n `)}\n \n `)}\n
\n `)}\n
\n `;\n }\n}\n\ncustomElements.define('examples-page', ExamplesPage);\nrouter.addRoute('examples', 'examples-page');\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport spinnerCss from './spinner-component.scss?inline';\nimport { animations } from '../../theme/theme';\n\n/**\n * A spinner component.\n *\n * @element loading-spinner\n */\nexport class SpinnerComponent extends LitElement {\n static properties = {\n loading: { type: Boolean, reflect: true }\n };\n\n static styles = [animations, unsafeCSS(spinnerCss)];\n\n constructor() {\n super();\n this.loading = false;\n }\n\n render() {\n return html`\n
\n
\n
\n `;\n }\n}\n\ncustomElements.define('loading-spinner', SpinnerComponent);\n","import { html, LitElement } from 'lit';\nimport { animations } from '../../theme/theme';\n\nconst DEFAULT_INT_OPTIONS = {\n root: null,\n rootMargin: '0px',\n threshold: 0.1\n};\n\n/**\n * Attach an Intersection Observer to a target element and execute a callback when it becomes visible.\n *\n * @param {Element} target - The target element to observe.\n * @param {Function} callback - The callback function to execute when the target is intersecting.\n * @param {Object} options - (Optional) Options to configure the Intersection Observer.\n * @param {Element} [options.root=null] - The element that is used as the viewport for checking visibility.\n * @param {string} [options.rootMargin='0px'] - Margin around the root. Can have values similar to CSS margin property.\n * @param {number} [options.threshold=0.1] - The threshold at which the callback will be triggered.\n */\nconst onIntersecting = (target, callback, options = DEFAULT_INT_OPTIONS) => {\n new IntersectionObserver((entries) => {\n entries.forEach(entry => {\n if (entry.isIntersecting) {\n callback();\n }\n });\n }, options).observe(target);\n};\n\n/**\n * This web component acts as a sentinel for an Intersection Observer,\n * dispatching an 'intersecting' event when the observed element intersects\n * with the view.\n *\n * @element intersection-observer\n * @csspart sentinel - the sentinel element.\n *\n * @fires IntersectionObserverComponent#intersecting - Dispatched when the observed element intersects with the view.\n */\nexport class IntersectionObserverComponent extends LitElement {\n static styles = [\n animations\n ];\n\n firstUpdated(_changedProperties) {\n super.firstUpdated(_changedProperties);\n onIntersecting(\n this.renderRoot.querySelector('div'),\n () => {\n /**\n * Custom event dispatched by IntersectionObserverComponent when the observed element intersects\n * with the view.\n *\n * @event IntersectionObserverComponent#intersecting\n * @type {CustomEvent}\n * @property {Object} detail - The event detail object.\n * @property {string} detail.src - The URL or URN of the media content to be loaded.\n * @property {string | undefined} detail.type - The type of media. Undefined if the type cannot be determined.\n * @property {Object | undefined} detail.keySystems - DRM key systems for the loaded media.\n */\n this.dispatchEvent(new CustomEvent('intersecting'));\n }\n );\n }\n\n render() {\n return html`\n
\n `;\n }\n}\n\ncustomElements.define('intersection-observer', IntersectionObserverComponent);\n","import { css, html, LitElement } from 'lit';\nimport { animations, theme } from '../../theme/theme';\n\n/**\n * A custom web component that provides a button to scroll to the top of the page.\n *\n * @element scroll-to-top-button\n */\nexport class ScrollToTopComponent extends LitElement {\n static styles = [\n theme,\n animations,\n css`\n .scroll-to-top-button {\n position: fixed;\n right: 20px;\n bottom: 20px;\n z-index: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n width: var(--size-7);\n height: var(--size-7);\n padding: 0;\n border: none;\n border-radius: var(--radius-round);\n }\n\n .scroll-to-top-button i {\n font-size: var(--size-8);\n }\n `];\n\n render() {\n return html`\n \n `;\n }\n}\n\ncustomElements.define('scroll-to-top-button', ScrollToTopComponent);\n","/**\n * Converts a given string to kebab case, spaces are replaced with hyphens\n * and all letters are converted to lowercase.\n *\n * @param {string} str - The input string to be converted to kebab case.\n * @returns {string} - The input string converted to kebab case.\n *\n * @example\n * const result = toKebabCase(\"Hello World\");\n * console.log(result); // Output: \"hello-world\"\n *\n * @example\n * const result = toKebabCase(\"CamelCase Example\");\n * console.log(result); // Output: \"camelcase-example\"\n */\nexport const toKebabCase = (str) => str.replace(/\\s+/g, '-').toLowerCase();\n","import { toKebabCase } from '../../../utils/string-utils';\n\n/**\n * Manages the state of a lists page, allowing navigation and retrieval of section data.\n *\n * @class\n */\nclass ListsPageStateManager {\n /**\n * Creates an instance of ListsPageStateManager.\n *\n * @constructor\n * @param {Array
} root - The root level of the lists page.\n */\n constructor(root) {\n /**\n * Stack to keep track of the traversal steps for navigation.\n *\n * @type {Array<{level: Array
, sectionIndex: number, nodeIndex: number}>}\n */\n this.stack = [];\n /**\n * The current level of the content tree.\n *\n * @type {Array
}\n */\n this.level = root;\n }\n\n /**\n * Initializes the state manager with the provided section, business unit, and nodes.\n *\n * @async\n * @param {string} section - The section to initialize.\n * @param {string} bu - The business unit associated with the section.\n * @param {string} nodes - A comma-separated string of nodes representing the initial state.\n * @returns {Promise} - A promise that resolves when initialization is complete.\n *\n * @example\n * // Example Usage:\n * await stateManager.initialize(\"radio-shows\", \"rts\", \"a9e7621504c6959e35c3ecbe7f6bed0446cdf8da,urn:rts:show:radio:9801398\");\n */\n async initialize(section, bu, nodes) {\n if (!section || !bu) {\n return;\n }\n\n const sectionIndex = this.#findSectionIndex(section);\n const nodeIndex = this.#findNodeIndex(this.level[sectionIndex].nodes, bu);\n\n await this.fetchNextState(sectionIndex, nodeIndex);\n await this.#processNodeString(nodes);\n }\n\n async #processNodeString(nodes) {\n for (const nodeStr of (nodes?.split(',') || [])) {\n const nodeIndex = this.#findNodeIndex(this.level[0].nodes, nodeStr);\n\n await this.fetchNextState(0, nodeIndex);\n }\n }\n\n /**\n * Fetches the next state based on the provided section index and node index.\n *\n * @param {number} sectionIndex - The index of the section.\n * @param {number} nodeIndex - The index of the node.\n * @returns {Promise} - A promise that resolves when the state is fetched.\n */\n async fetchNextState(sectionIndex, nodeIndex) {\n const section = this.level[sectionIndex];\n\n this.stack.push({ level: this.level, sectionIndex, nodeIndex });\n this.level = [await section.resolve(section.nodes[nodeIndex])];\n }\n\n /**\n * Fetches the previous state based on the provided stack index.\n *\n * @param {number} stackIndex - The index in the stack.\n */\n fetchPreviousState(stackIndex) {\n this.level = this.stack[stackIndex].level;\n this.stack.splice(stackIndex);\n }\n\n /**\n * Checks if the specified section at the given index is a leaf section.\n *\n * @param {number} sectionIndex - The index of the section.\n *\n * @returns {boolean} - True if the section is a leaf section, false otherwise.\n */\n isLeafSection(sectionIndex) {\n return this.level[sectionIndex]?.isLeaf();\n }\n\n /**\n * Retrieves the node at the specified section and node indices.\n *\n * @param {number} sectionIndex - The index of the section.\n * @param {number} nodeIndex - The index of the node.\n *\n * @returns {any} - The retrieved node.\n */\n retrieveNode(sectionIndex, nodeIndex) {\n return this.level[sectionIndex]?.nodes[nodeIndex];\n }\n\n /**\n * Gets the root level of the content tree.\n *\n * @returns {Array
} - The root level of the content tree.\n */\n get root() {\n return this.stack[0]?.level || this.level;\n }\n\n /**\n * Return the current state of this manager as query params that are parsable\n * by {@link #initialize}.\n *\n * @returns {{}|{bu: string, section: string, nodes?: string}} The current state as query params.\n */\n get params() {\n return ListsPageStateManager.#params(this.stack);\n }\n\n static #params(stack) {\n if (stack.length === 0) {\n return {};\n }\n\n const root = stack[0];\n const rootSection = root.level[root.sectionIndex];\n const nodes = stack.slice(1).map(n => {\n const node = n.level[n.sectionIndex].nodes[n.nodeIndex];\n\n return node.id || node.urn;\n });\n const params = {\n section: toKebabCase(rootSection.title),\n bu: rootSection.nodes[root.nodeIndex].toLowerCase()\n };\n\n if (nodes && nodes.length) {\n params.nodes = nodes.join(',');\n }\n\n return params;\n }\n\n paramsAt(sectionIndex, nodeIndex) {\n return ListsPageStateManager.#params(\n [...this.stack, { level: this.level, sectionIndex, nodeIndex }]\n );\n }\n\n /**\n * Finds the index of a section based on its title in kebab case.\n *\n * @private\n * @param {string} sectionStr - The section title to find.\n * @returns {number} - The index of the section.\n *\n * @example\n * const index = stateManager.#findSectionIndex(\"Products\");\n */\n #findSectionIndex(sectionStr) {\n const normalizedSectionStr = toKebabCase(sectionStr).toLowerCase();\n\n return this.level\n .map(s => toKebabCase(s.title).toLowerCase())\n .findIndex(title => title === normalizedSectionStr);\n }\n\n /**\n * Finds the index of a node based on its string representation.\n *\n * @private\n * @param {Array} nodes - The array of nodes to search.\n * @param {string} str - The string representation of the node to find.\n *\n * @returns {number} - The index of the node.\n */\n #findNodeIndex(nodes, str) {\n const normalizedStr = str.toLowerCase();\n\n return nodes\n .map(n => (n.urn || n.id || n.toString()).toLowerCase())\n .findIndex(n => n === normalizedStr);\n }\n}\n\nexport default ListsPageStateManager;\n","import ilProvider from '../../../utils/il-provider';\n\n/**\n * A section within the content hierarchy.\n *\n * @property {string} title - The title of the section node.\n * @property {string[]} values - An array of values associated with the section.\n * @property {function} resolve - A function that, when defined, resolves the next level\n * of the hierarchy asynchronously.\n */\nclass Section {\n /**\n * Creates an instance of Section.\n *\n * @param {Object} options - The options for creating the section.\n * @param {string} options.title - The title of the section.\n * @param {string[]} options.nodes - An array of nodes associated with the section.\n * @param {function} [options.resolve] - (Optional) A function that, when defined, resolves the next level\n * of the hierarchy asynchronously.\n * @param {function} [options.next] - (Optional) A function that, when defined, resolves the next level\n * of the hierarchy asynchronously.\n */\n constructor({\n title,\n nodes,\n resolve = undefined,\n next = undefined\n }) {\n this.title = title;\n this.nodes = nodes;\n this.resolve = resolve;\n this.next = next;\n }\n\n /**\n * Checks if the node is a leaf node (i.e., has no further levels to resolve).\n *\n * @returns {boolean} True if the node is a leaf node, false otherwise.\n */\n isLeaf() {\n return !this.resolve;\n }\n\n /**\n * Fetch more nodes from the next function if available.\n * @param signal\n * @returns {Promise<*>}\n */\n async fetchNext(signal = undefined) {\n if (!this.next) return;\n const data = await this.next(signal);\n\n this.next = data.next;\n this.nodes.push(...data.results);\n\n return data.results;\n }\n}\n\nconst toNodesAndNext = (data) => ({\n nodes: data.results,\n next: data.next\n});\n\n/**\n * An asynchronous tree-like structure that allows traversing the SRG SSR content\n * by category in a hierarchical fashion.\n *\n * @type {Section[]}\n */\nexport const listsSections = [\n new Section({\n title: 'TV Topics',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF', 'SWI'],\n resolve: async(bu) => new Section({\n title: `${bu} TV Topics`,\n nodes: await ilProvider.topics(bu),\n resolve: async(topic) => new Section({\n title: topic.title,\n ...toNodesAndNext(await ilProvider.latestByTopic(topic.urn))\n })\n })\n }),\n new Section({\n title: 'TV Shows',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF', 'SWI'],\n resolve: async(bu) => new Section({\n title: `${bu} TV Shows`,\n nodes: await ilProvider.shows(bu),\n resolve: async(show) => new Section({\n title: show.title,\n ...toNodesAndNext(await ilProvider.latestByShow(show.urn))\n })\n })\n }),\n new Section({\n title: 'TV Latest Videos',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} TV Latest Videos`,\n ...toNodesAndNext(await ilProvider.editorial(bu))\n })\n }),\n new Section({\n title: 'TV Livestreams',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} TV Livestreams`,\n nodes: await ilProvider.livestreams(bu)\n })\n }),\n new Section({\n title: 'Live web',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} Live web`,\n ...toNodesAndNext(await ilProvider.scheduledLivestream(bu))\n })\n }),\n new Section({\n title: 'Live center',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} Live center`,\n nodes: await ilProvider.livecenter(bu)\n })\n }),\n new Section({\n title: 'Radio Shows',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} Radio Channels`,\n nodes: await ilProvider.channels(bu),\n resolve: async(channel) => new Section({\n title: `${channel.title} Radio shows`,\n nodes: await ilProvider.radioShowByChannel(bu, channel.id),\n resolve: async(show) => new Section({\n title: show.title,\n ...toNodesAndNext(await ilProvider.latestByShow(show.urn))\n })\n })\n })\n }),\n new Section({\n title: 'Radio Livestreams',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} Radio Livestreams`,\n nodes: await ilProvider.livestreams(bu, 'audio')\n })\n })\n];\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport router from '../../../router/router';\nimport componentCSS from './lists-page.scss?inline';\nimport '../../../components/spinner/spinner-component';\nimport '../../../components/intersection-observer/intersection-observer-component';\nimport '../../../components/scroll-to-top/scroll-to-top-component';\nimport { map } from 'lit/directives/map.js';\nimport { when } from 'lit/directives/when.js';\nimport ListsPageStateManager from './lists-page-state-manager';\nimport { listsSections } from './lists-sections';\nimport Pillarbox from 'video.js';\n\nexport class ListsPage extends LitElement {\n static properties = {\n loading: { state: true, type: Boolean },\n stack: { state: true, type: Array },\n level: { state: true, type: Object },\n nextPage: { state: true, type: Function }\n };\n\n static styles = [\n theme, animations, unsafeCSS(componentCSS)\n ];\n\n /**\n * The abort controller for handling search cancellation.\n *\n * @private\n * @type {AbortController}\n */\n #abortController = new AbortController();\n /**\n * Keeps track of the state of the list page : the current level in display, as\n * well as the traversal stack.\n *\n * @private\n * @type {ListsPageStateManager}\n */\n #stateManager;\n /**\n * The reference to the query params changed event handler.\n *\n * @private\n * @type {Function}\n */\n #onQueryParamsChanged;\n\n constructor() {\n super();\n\n this.loading = false;\n this.#stateManager = new ListsPageStateManager(listsSections);\n this.#updateState();\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.#onQueryParamsChanged = async(event) => {\n if (!event.detail.popstate) return;\n\n this.abortFetch();\n const manager = new ListsPageStateManager(this.#stateManager.root);\n const { section, bu, nodes } = event.detail.queryParams;\n\n this.loading = true;\n try {\n await manager.initialize(section, bu, nodes);\n this.#stateManager = manager;\n this.#updateState();\n } finally {\n this.loading = false;\n }\n };\n router.addEventListener('queryparams', this.#onQueryParamsChanged);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.abortFetch();\n router.removeEventListener('queryparams', this.#onQueryParamsChanged);\n }\n\n firstUpdated(_changedProperties) {\n super.firstUpdated(_changedProperties);\n this.#onQueryParamsChanged(\n { detail: { popstate: true, queryParams: router.queryParams } }\n );\n }\n\n #updateState() {\n this.stack = [...this.#stateManager.stack];\n this.level = [...this.#stateManager.level];\n }\n\n /**\n * Navigates to the specified section and node in the content tree.\n *\n * @param {number} sectionIndex - The index of the section.\n * @param {number} nodeIndex - The index of the node.\n */\n async navigateTo(sectionIndex, nodeIndex) {\n if (!this.#stateManager.isLeafSection(sectionIndex)) {\n this.abortFetch();\n this.loading = true;\n try {\n await this.#stateManager.fetchNextState(sectionIndex, nodeIndex);\n this.#updateState();\n } finally {\n this.loading = false;\n }\n }\n }\n\n /**\n * Aborts the previous fetch by cancelling the associated abort signal and\n * creates a new abort controller for the next fetch.\n *\n * @returns {AbortSignal} - The abort signal associated with the new fetch.\n */\n abortFetch() {\n this.#abortController?.abort('New search launched');\n this.#abortController = new AbortController();\n\n return this.#abortController.signal;\n }\n\n #toMediaButtonParams(node) {\n return new URLSearchParams({ ...router.queryParams, src: node.urn, type: 'srgssr/urn' }).toString();\n }\n\n #renderMediaButton(node) {\n const date = new Intl.DateTimeFormat('fr-CH').format(new Date(node.date));\n const duration = Pillarbox.formatTime(node.duration / 1000);\n\n return html`\n \n
\n ${node.mediaType === 'VIDEO' ? 'movie' : 'audiotrack'}\n  | ${date} | ${duration}\n
\n
\n `;\n }\n\n #toLevelParams(sectionIdx, nodeIdx) {\n const params = this.#stateManager.paramsAt(sectionIdx, nodeIdx);\n\n return new URLSearchParams(params).toString();\n }\n\n #renderLevelButton(node, sectionIdx, nodeIdx) {\n return html`\n \n \n `;\n }\n\n async #nextPage(section) {\n const signal = this.abortFetch();\n\n await section.fetchNext(signal);\n this.#updateState();\n }\n\n #renderNodes(nodes, sectionIdx) {\n const firstSection = this.level[0];\n const hasIntesectionObserver = this.level.length === 1 && firstSection.next;\n\n return html`\n ${map(nodes, (node, idx) => html`\n ${when(node.mediaType, () => this.#renderMediaButton(node, idx), () => this.#renderLevelButton(node, sectionIdx, idx))}\n `)}\n ${when(hasIntesectionObserver, () => html`\n this.#nextPage(firstSection)}\">\n \n `)}\n `;\n }\n\n async #onSectionsClicked(e) {\n const button = e.target.closest('content-link');\n\n if (this.loading || !('nodeIdx' in button.dataset)) return;\n\n const sectionIndex = button.dataset.sectionIdx;\n const nodeIndex = button.dataset.nodeIdx;\n\n await this.navigateTo(sectionIndex, nodeIndex);\n }\n\n #renderResults() {\n return html`\n
e.target.classList.remove('fade-in')}\"\n @click=\"${this.#onSectionsClicked.bind(this)}\">\n ${map(this.level, (section, idx) => html`\n
\n

${section.title}

\n ${this.#renderNodes(section.nodes, idx)}\n
\n `)}\n
\n `;\n }\n\n #renderSpinner() {\n return html`\n e.target.classList.remove('slide-up-fade-in')}\">\n \n `;\n }\n\n #renderScrollToTopBtn() {\n return html`\n `;\n }\n\n #onNavigationClicked(e) {\n if (e.target.tagName.toLowerCase() !== 'button') return;\n this.abortFetch();\n this.#stateManager.fetchPreviousState(e.target.dataset.navigationIdx);\n this.#updateState();\n router.updateState(this.#stateManager.params, ['section', 'bu', 'nodes']);\n }\n\n #renderNavigation() {\n return html`\n
\n ${when(this.stack.length > 0, () => html`\n \n `)}\n ${map(this.stack.slice(1), (step, idx) => html`\n chevron_right\n \n `)}\n
\n `;\n }\n\n render() {\n const renderScrollBtn = this.level.length === 1 && this.level[0].next;\n\n return html`\n ${this.#renderNavigation()}\n ${when(this.loading, this.#renderSpinner.bind(this), this.#renderResults.bind(this))}\n ${when(renderScrollBtn, this.#renderScrollToTopBtn.bind(this))}\n `;\n }\n}\n\ncustomElements.define('lists-page', ListsPage);\nrouter.addRoute('lists', 'lists-page');\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport componentCSS from './search-bar-component.scss?inline';\nimport Pillarbox from 'video.js';\n\nconst DEFAULT_BU = 'rsi';\n\n/**\n * A search bar component for filtering content based on a query and business unit.\n *\n * @element search-bar\n *\n * @fires SearchBarComponent#change - Dispatched when the value of the search bar changes.\n */\nexport class SearchBarComponent extends LitElement {\n static properties = {\n bu: { type: String },\n query: { type: String }\n };\n\n static styles = [theme, animations, unsafeCSS(componentCSS)];\n\n constructor() {\n super();\n this.bu = DEFAULT_BU;\n this.query = '';\n }\n\n #handleSearchBarKeyUp() {\n this.query = this.renderRoot.querySelector('input').value;\n }\n\n #handleSelectChange(e) {\n this.bu = e.target.value;\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (['bu', 'query'].some(property => _changedProperties.has(property))) {\n const query = this.query ?? '';\n const bu = this.bu ?? DEFAULT_BU;\n\n /**\n * Custom event dispatched by SearchBarComponent when the value of the bar changes.\n *\n * @event SearchBarComponent#change\n * @type {CustomEvent}\n * @property {Object} detail - The event detail object.\n * @property {string} detail.query - The query on the search bar.a\n * @property {string} detail.bu - The selected bu.\n */\n this.dispatchEvent(new CustomEvent('change', {\n detail: { query, bu }\n }));\n }\n }\n\n #clearSearchBar() {\n this.query = '';\n this.renderRoot.querySelector('input').value = '';\n }\n\n render() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n \n \n
\n `;\n }\n}\n\ncustomElements.define('search-bar', SearchBarComponent);\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport router from '../../../router/router';\nimport componentCSS from './search-page.scss?inline';\nimport './search-bar-component';\nimport ilProvider from '../../../utils/il-provider';\nimport '../../../components/spinner/spinner-component';\nimport '../../../components/intersection-observer/intersection-observer-component';\nimport '../../../components/scroll-to-top/scroll-to-top-component';\nimport '../../../components/content-link/content-link-component';\nimport { map } from 'lit/directives/map.js';\nimport Pillarbox from 'video.js';\nimport { when } from 'lit/directives/when.js';\nimport { classMap } from 'lit/directives/class-map.js';\n\nexport class SearchPage extends LitElement {\n static properties = {\n loading: {\n state: true,\n type: Boolean\n },\n results: {\n state: true,\n type: Array\n },\n nextPage: {\n state: true,\n type: Function\n }\n };\n\n static styles = [\n theme, animations, unsafeCSS(componentCSS)\n ];\n\n /**\n * The abort controller for handling search cancellation.\n *\n * @private\n * @type {AbortController}\n */\n #abortController = new AbortController();\n /**\n * The reference to the query params changed event handler.\n *\n * @private\n * @type {Function}\n */\n #onQueryParamsChanged;\n\n constructor() {\n super();\n\n this.loading = false;\n this.results = null;\n this.nextPage = null;\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.#onQueryParamsChanged = () => {\n const searchBar = this.renderRoot.querySelector('search-bar');\n\n searchBar.query = router.queryParams.query ?? '';\n searchBar.bu = router.queryParams.bu ?? 'rsi';\n };\n router.addEventListener('queryparams', this.#onQueryParamsChanged);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.abortSearch();\n router.removeEventListener('queryparams', this.#onQueryParamsChanged);\n }\n\n async firstUpdated(_changedProperties) {\n super.firstUpdated(_changedProperties);\n const searchBar = this.renderRoot.querySelector('search-bar');\n\n this.#onQueryParamsChanged();\n await this.#search(searchBar.bu, searchBar.query);\n }\n\n async #onSearchBarChanged(bu, query) {\n router.updateState({ bu, ...(query ? { query } : {}) });\n await this.#search(bu, query);\n }\n\n /**\n * Performs a search based on the specified business unit and query. Performing\n * a new search will abort the previous search if it's ongoing and display a\n * loading spinner for the asynchronous operation.\n *\n * @param {string} bu - The selected business unit.\n * @param {string} query - The search query.\n *\n * @throws {Promise} - A rejected promise with the response object if\n * the fetch request for the search results fails.\n */\n async #search(bu, query) {\n const signal = this.abortSearch();\n\n if (!query) {\n [this.results, this.nextPage] = [null, null];\n\n return;\n }\n\n this.loading = true;\n try {\n const data = await ilProvider.search(bu, query, signal);\n\n [this.results, this.nextPage] = [data.results, data.next];\n } finally {\n this.loading = false;\n }\n }\n\n /**\n * Advances to the next page of search results and updates the UI accordingly.\n *\n * @throws {Promise} - A rejected promise with the response object if\n * the fetch request for the next page fails.\n */\n async #fetchNextPage() {\n const signal = this.abortSearch();\n const data = await this.nextPage(signal);\n\n this.nextPage = data.next;\n this.results = [...this.results, ...data.results];\n }\n\n /**\n * Aborts the previous search by cancelling the associated abort signal and\n * creates a new abort controller for the next search.\n *\n * @returns {AbortSignal} - The abort signal associated with the new search.\n */\n abortSearch() {\n this.#abortController?.abort('New search launched');\n this.#abortController = new AbortController();\n\n return this.#abortController.signal;\n }\n\n #toQueryParams(r) {\n return new URLSearchParams({\n ...router.queryParams,\n src: r.urn,\n type: 'srgssr/urn'\n }).toString();\n }\n\n #renderButton(r) {\n const date = new Intl.DateTimeFormat('fr-CH').format(new Date(r.date));\n const duration = Pillarbox.formatTime(r.duration / 1000);\n\n return html`\n \n
\n ${r.mediaType === 'VIDEO' ? 'movie' : 'audiotrack'}\n  | ${date} | ${duration}\n
\n
\n `;\n }\n\n #renderResults() {\n const resultsClassMap = {\n empty: this.results == null,\n 'no-results': this.results && this.results.length === 0,\n 'material-icons': !this.results || this.results.length === 0\n };\n\n return html`\n
e.target.classList.remove('fade-in')}\">\n ${map(this.results ?? [], this.#renderButton.bind(this))}\n ${when(this.nextPage, () => html`\n \n \n `)}\n
\n `;\n }\n\n #renderSpinner() {\n return html`\n e.target.classList.remove('slide-up-fade-in')}\">\n \n `;\n }\n\n #renderScrollToTopBtn() {\n return html`\n `;\n }\n\n render() {\n return html`\n this.#onSearchBarChanged(e.detail.bu, e.detail.query)}\">\n \n\n \n ${when(this.loading, this.#renderSpinner.bind(this), this.#renderResults.bind(this))}\n ${when(this.results?.length > 0, this.#renderScrollToTopBtn.bind(this))}\n `;\n }\n}\n\ncustomElements.define('search-page', SearchPage);\nrouter.addRoute('search', 'search-page');\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { theme } from '../../theme/theme';\nimport componentCSS from './toggle-switch-component.scss?inline';\n\n/**\n * Custom element representing a toggle switch.\n *\n * @element toggle-switch\n *\n * @csspart switch - The container for the toggle switch.\n * @csspart slider - The slider button of the toggle switch.\n *\n * @prop {Boolean} checked - Reflects the current state of the toggle switch.\n * @prop {Boolean} disabled - Indicates whether the toggle switch is disabled.\n *\n * @attribute {String} role - ARIA role for accessibility, set to 'switch'.\n * @attribute {String} tabindex - ARIA tabindex for accessibility, set to '0'.\n *\n * @fires ToggleSwitchComponent#change\n *\n * @example\n * \n *\n * @customElement\n */\nexport class ToggleSwitchComponent extends LitElement {\n static formAssociated = true;\n static properties = {\n checked: { type: Boolean, reflect: true },\n disabled: { type: Boolean }\n };\n\n constructor() {\n super();\n this.checked = false;\n this.disabled = false;\n }\n\n static styles = [\n theme, unsafeCSS(componentCSS)\n ];\n\n #onKeyDown = (e) => {\n if (e.key === ' ') {\n e.preventDefault();\n this.toggle();\n }\n };\n\n #onClick = () => {\n this.toggle();\n };\n\n connectedCallback() {\n super.connectedCallback();\n\n if (!this.hasAttribute('role')) {\n this.setAttribute('role', 'switch');\n }\n\n if (!this.hasAttribute('tabindex')) {\n this.setAttribute('tabindex', '0');\n }\n\n this.addEventListener('click', this.#onClick);\n this.addEventListener('keydown', this.#onKeyDown);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n\n this.removeEventListener('click', this.#onClick);\n this.removeEventListener('keydown', this.#onKeyDown);\n }\n\n toggle(force) {\n if (!this.disabled) {\n this.checked = force ?? !this.checked;\n }\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (_changedProperties.has('checked')) {\n this.setAttribute('aria-checked', this.checked.toString());\n /**\n * Custom event dispatched when the state of the toggle switch changes.\n *\n * @event ToggleSwitchComponent#change\n * @type {CustomEvent}\n * @property {Object} detail - The event detail object.\n * @property {Boolean} detail.checked - The new state of the toggle switch.\n */\n this.dispatchEvent(new CustomEvent('change', { detail: { checked: this.checked } }));\n }\n }\n\n render() {\n return html`\n
\n
\n
\n `;\n }\n}\n\ncustomElements.define('toggle-switch', ToggleSwitchComponent);\n","import router from '../../../router/router';\nimport { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport '../../../components/toggle-switch/toggle-switch-component.js';\nimport PreferencesProvider from './preferences-provider';\nimport componentCss from './settings-page.scss?inline';\nimport ilProvider from '../../../utils/il-provider.js';\n\n/**\n * A web component that represents the settings page.\n *\n * @element settings-page\n */\nexport class SettingsPage extends LitElement {\n static properties = {\n autoplay: { type: Boolean, state: true },\n muted: { type: Boolean, state: true },\n debug: { type: Boolean, state: true },\n dataProviderHost: { type: String, state: true }\n };\n\n static styles = [theme, animations, unsafeCSS(componentCss)];\n\n constructor() {\n super();\n const preferences = PreferencesProvider.loadPreferences();\n\n this.autoplay = preferences.autoplay ?? false;\n this.muted = preferences.muted ?? true;\n this.debug = preferences.debug ?? false;\n this.dataProviderHost = preferences.dataProviderHost;\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n const preferences = PreferencesProvider.loadPreferences();\n\n [..._changedProperties.keys()]\n .filter(property => ['autoplay', 'muted', 'debug', 'dataProviderHost'].includes(property))\n .forEach((property) => {\n preferences[property] = this[property];\n });\n\n PreferencesProvider.savePreferences(preferences);\n\n if (_changedProperties.has('debug')) {\n router.replaceState(this.debug ? { debug: 'true' } : {});\n }\n\n if (_changedProperties.has('dataProviderHost')) {\n ilProvider.host = this.dataProviderHost;\n }\n }\n\n #renderToggle(property, label) {\n return html`\n
\n \n {\n this[property] = e.detail.checked;\n }}\">\n \n
\n `;\n }\n\n #renderInput(property, label) {\n return html`\n
\n \n {\n this[property] = e.target.value === '' ? undefined : e.target.value;\n }}\">\n
\n `;\n }\n\n render() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n

Player Settings

\n ${this.#renderToggle('autoplay', 'Autoplay')}\n ${this.#renderToggle('muted', 'Player starts muted')}\n ${this.#renderToggle('debug', 'Enable debug mode')}\n ${this.#renderInput('dataProviderHost', 'Data provider host')}\n
\n `;\n }\n}\n\ncustomElements.define('settings-page', SettingsPage);\nrouter.addRoute('settings', 'settings-page');\n","/* eslint-disable no-multi-assign */\n\nfunction deepFreeze(obj) {\n if (obj instanceof Map) {\n obj.clear =\n obj.delete =\n obj.set =\n function () {\n throw new Error('map is read-only');\n };\n } else if (obj instanceof Set) {\n obj.add =\n obj.clear =\n obj.delete =\n function () {\n throw new Error('set is read-only');\n };\n }\n\n // Freeze self\n Object.freeze(obj);\n\n Object.getOwnPropertyNames(obj).forEach((name) => {\n const prop = obj[name];\n const type = typeof prop;\n\n // Freeze prop if it is an object or function and also not already frozen\n if ((type === 'object' || type === 'function') && !Object.isFrozen(prop)) {\n deepFreeze(prop);\n }\n });\n\n return obj;\n}\n\n/** @typedef {import('highlight.js').CallbackResponse} CallbackResponse */\n/** @typedef {import('highlight.js').CompiledMode} CompiledMode */\n/** @implements CallbackResponse */\n\nclass Response {\n /**\n * @param {CompiledMode} mode\n */\n constructor(mode) {\n // eslint-disable-next-line no-undefined\n if (mode.data === undefined) mode.data = {};\n\n this.data = mode.data;\n this.isMatchIgnored = false;\n }\n\n ignoreMatch() {\n this.isMatchIgnored = true;\n }\n}\n\n/**\n * @param {string} value\n * @returns {string}\n */\nfunction escapeHTML(value) {\n return value\n .replace(/&/g, '&')\n .replace(//g, '>')\n .replace(/\"/g, '"')\n .replace(/'/g, ''');\n}\n\n/**\n * performs a shallow merge of multiple objects into one\n *\n * @template T\n * @param {T} original\n * @param {Record[]} objects\n * @returns {T} a single new object\n */\nfunction inherit$1(original, ...objects) {\n /** @type Record */\n const result = Object.create(null);\n\n for (const key in original) {\n result[key] = original[key];\n }\n objects.forEach(function(obj) {\n for (const key in obj) {\n result[key] = obj[key];\n }\n });\n return /** @type {T} */ (result);\n}\n\n/**\n * @typedef {object} Renderer\n * @property {(text: string) => void} addText\n * @property {(node: Node) => void} openNode\n * @property {(node: Node) => void} closeNode\n * @property {() => string} value\n */\n\n/** @typedef {{scope?: string, language?: string, sublanguage?: boolean}} Node */\n/** @typedef {{walk: (r: Renderer) => void}} Tree */\n/** */\n\nconst SPAN_CLOSE = '';\n\n/**\n * Determines if a node needs to be wrapped in \n *\n * @param {Node} node */\nconst emitsWrappingTags = (node) => {\n // rarely we can have a sublanguage where language is undefined\n // TODO: track down why\n return !!node.scope;\n};\n\n/**\n *\n * @param {string} name\n * @param {{prefix:string}} options\n */\nconst scopeToCSSClass = (name, { prefix }) => {\n // sub-language\n if (name.startsWith(\"language:\")) {\n return name.replace(\"language:\", \"language-\");\n }\n // tiered scope: comment.line\n if (name.includes(\".\")) {\n const pieces = name.split(\".\");\n return [\n `${prefix}${pieces.shift()}`,\n ...(pieces.map((x, i) => `${x}${\"_\".repeat(i + 1)}`))\n ].join(\" \");\n }\n // simple scope\n return `${prefix}${name}`;\n};\n\n/** @type {Renderer} */\nclass HTMLRenderer {\n /**\n * Creates a new HTMLRenderer\n *\n * @param {Tree} parseTree - the parse tree (must support `walk` API)\n * @param {{classPrefix: string}} options\n */\n constructor(parseTree, options) {\n this.buffer = \"\";\n this.classPrefix = options.classPrefix;\n parseTree.walk(this);\n }\n\n /**\n * Adds texts to the output stream\n *\n * @param {string} text */\n addText(text) {\n this.buffer += escapeHTML(text);\n }\n\n /**\n * Adds a node open to the output stream (if needed)\n *\n * @param {Node} node */\n openNode(node) {\n if (!emitsWrappingTags(node)) return;\n\n const className = scopeToCSSClass(node.scope,\n { prefix: this.classPrefix });\n this.span(className);\n }\n\n /**\n * Adds a node close to the output stream (if needed)\n *\n * @param {Node} node */\n closeNode(node) {\n if (!emitsWrappingTags(node)) return;\n\n this.buffer += SPAN_CLOSE;\n }\n\n /**\n * returns the accumulated buffer\n */\n value() {\n return this.buffer;\n }\n\n // helpers\n\n /**\n * Builds a span element\n *\n * @param {string} className */\n span(className) {\n this.buffer += ``;\n }\n}\n\n/** @typedef {{scope?: string, language?: string, children: Node[]} | string} Node */\n/** @typedef {{scope?: string, language?: string, children: Node[]} } DataNode */\n/** @typedef {import('highlight.js').Emitter} Emitter */\n/** */\n\n/** @returns {DataNode} */\nconst newNode = (opts = {}) => {\n /** @type DataNode */\n const result = { children: [] };\n Object.assign(result, opts);\n return result;\n};\n\nclass TokenTree {\n constructor() {\n /** @type DataNode */\n this.rootNode = newNode();\n this.stack = [this.rootNode];\n }\n\n get top() {\n return this.stack[this.stack.length - 1];\n }\n\n get root() { return this.rootNode; }\n\n /** @param {Node} node */\n add(node) {\n this.top.children.push(node);\n }\n\n /** @param {string} scope */\n openNode(scope) {\n /** @type Node */\n const node = newNode({ scope });\n this.add(node);\n this.stack.push(node);\n }\n\n closeNode() {\n if (this.stack.length > 1) {\n return this.stack.pop();\n }\n // eslint-disable-next-line no-undefined\n return undefined;\n }\n\n closeAllNodes() {\n while (this.closeNode());\n }\n\n toJSON() {\n return JSON.stringify(this.rootNode, null, 4);\n }\n\n /**\n * @typedef { import(\"./html_renderer\").Renderer } Renderer\n * @param {Renderer} builder\n */\n walk(builder) {\n // this does not\n return this.constructor._walk(builder, this.rootNode);\n // this works\n // return TokenTree._walk(builder, this.rootNode);\n }\n\n /**\n * @param {Renderer} builder\n * @param {Node} node\n */\n static _walk(builder, node) {\n if (typeof node === \"string\") {\n builder.addText(node);\n } else if (node.children) {\n builder.openNode(node);\n node.children.forEach((child) => this._walk(builder, child));\n builder.closeNode(node);\n }\n return builder;\n }\n\n /**\n * @param {Node} node\n */\n static _collapse(node) {\n if (typeof node === \"string\") return;\n if (!node.children) return;\n\n if (node.children.every(el => typeof el === \"string\")) {\n // node.text = node.children.join(\"\");\n // delete node.children;\n node.children = [node.children.join(\"\")];\n } else {\n node.children.forEach((child) => {\n TokenTree._collapse(child);\n });\n }\n }\n}\n\n/**\n Currently this is all private API, but this is the minimal API necessary\n that an Emitter must implement to fully support the parser.\n\n Minimal interface:\n\n - addText(text)\n - __addSublanguage(emitter, subLanguageName)\n - startScope(scope)\n - endScope()\n - finalize()\n - toHTML()\n\n*/\n\n/**\n * @implements {Emitter}\n */\nclass TokenTreeEmitter extends TokenTree {\n /**\n * @param {*} options\n */\n constructor(options) {\n super();\n this.options = options;\n }\n\n /**\n * @param {string} text\n */\n addText(text) {\n if (text === \"\") { return; }\n\n this.add(text);\n }\n\n /** @param {string} scope */\n startScope(scope) {\n this.openNode(scope);\n }\n\n endScope() {\n this.closeNode();\n }\n\n /**\n * @param {Emitter & {root: DataNode}} emitter\n * @param {string} name\n */\n __addSublanguage(emitter, name) {\n /** @type DataNode */\n const node = emitter.root;\n if (name) node.scope = `language:${name}`;\n\n this.add(node);\n }\n\n toHTML() {\n const renderer = new HTMLRenderer(this, this.options);\n return renderer.value();\n }\n\n finalize() {\n this.closeAllNodes();\n return true;\n }\n}\n\n/**\n * @param {string} value\n * @returns {RegExp}\n * */\n\n/**\n * @param {RegExp | string } re\n * @returns {string}\n */\nfunction source(re) {\n if (!re) return null;\n if (typeof re === \"string\") return re;\n\n return re.source;\n}\n\n/**\n * @param {RegExp | string } re\n * @returns {string}\n */\nfunction lookahead(re) {\n return concat('(?=', re, ')');\n}\n\n/**\n * @param {RegExp | string } re\n * @returns {string}\n */\nfunction anyNumberOfTimes(re) {\n return concat('(?:', re, ')*');\n}\n\n/**\n * @param {RegExp | string } re\n * @returns {string}\n */\nfunction optional(re) {\n return concat('(?:', re, ')?');\n}\n\n/**\n * @param {...(RegExp | string) } args\n * @returns {string}\n */\nfunction concat(...args) {\n const joined = args.map((x) => source(x)).join(\"\");\n return joined;\n}\n\n/**\n * @param { Array } args\n * @returns {object}\n */\nfunction stripOptionsFromArgs(args) {\n const opts = args[args.length - 1];\n\n if (typeof opts === 'object' && opts.constructor === Object) {\n args.splice(args.length - 1, 1);\n return opts;\n } else {\n return {};\n }\n}\n\n/** @typedef { {capture?: boolean} } RegexEitherOptions */\n\n/**\n * Any of the passed expresssions may match\n *\n * Creates a huge this | this | that | that match\n * @param {(RegExp | string)[] | [...(RegExp | string)[], RegexEitherOptions]} args\n * @returns {string}\n */\nfunction either(...args) {\n /** @type { object & {capture?: boolean} } */\n const opts = stripOptionsFromArgs(args);\n const joined = '('\n + (opts.capture ? \"\" : \"?:\")\n + args.map((x) => source(x)).join(\"|\") + \")\";\n return joined;\n}\n\n/**\n * @param {RegExp | string} re\n * @returns {number}\n */\nfunction countMatchGroups(re) {\n return (new RegExp(re.toString() + '|')).exec('').length - 1;\n}\n\n/**\n * Does lexeme start with a regular expression match at the beginning\n * @param {RegExp} re\n * @param {string} lexeme\n */\nfunction startsWith(re, lexeme) {\n const match = re && re.exec(lexeme);\n return match && match.index === 0;\n}\n\n// BACKREF_RE matches an open parenthesis or backreference. To avoid\n// an incorrect parse, it additionally matches the following:\n// - [...] elements, where the meaning of parentheses and escapes change\n// - other escape sequences, so we do not misparse escape sequences as\n// interesting elements\n// - non-matching or lookahead parentheses, which do not capture. These\n// follow the '(' with a '?'.\nconst BACKREF_RE = /\\[(?:[^\\\\\\]]|\\\\.)*\\]|\\(\\??|\\\\([1-9][0-9]*)|\\\\./;\n\n// **INTERNAL** Not intended for outside usage\n// join logically computes regexps.join(separator), but fixes the\n// backreferences so they continue to match.\n// it also places each individual regular expression into it's own\n// match group, keeping track of the sequencing of those match groups\n// is currently an exercise for the caller. :-)\n/**\n * @param {(string | RegExp)[]} regexps\n * @param {{joinWith: string}} opts\n * @returns {string}\n */\nfunction _rewriteBackreferences(regexps, { joinWith }) {\n let numCaptures = 0;\n\n return regexps.map((regex) => {\n numCaptures += 1;\n const offset = numCaptures;\n let re = source(regex);\n let out = '';\n\n while (re.length > 0) {\n const match = BACKREF_RE.exec(re);\n if (!match) {\n out += re;\n break;\n }\n out += re.substring(0, match.index);\n re = re.substring(match.index + match[0].length);\n if (match[0][0] === '\\\\' && match[1]) {\n // Adjust the backreference.\n out += '\\\\' + String(Number(match[1]) + offset);\n } else {\n out += match[0];\n if (match[0] === '(') {\n numCaptures++;\n }\n }\n }\n return out;\n }).map(re => `(${re})`).join(joinWith);\n}\n\n/** @typedef {import('highlight.js').Mode} Mode */\n/** @typedef {import('highlight.js').ModeCallback} ModeCallback */\n\n// Common regexps\nconst MATCH_NOTHING_RE = /\\b\\B/;\nconst IDENT_RE = '[a-zA-Z]\\\\w*';\nconst UNDERSCORE_IDENT_RE = '[a-zA-Z_]\\\\w*';\nconst NUMBER_RE = '\\\\b\\\\d+(\\\\.\\\\d+)?';\nconst C_NUMBER_RE = '(-?)(\\\\b0[xX][a-fA-F0-9]+|(\\\\b\\\\d+(\\\\.\\\\d*)?|\\\\.\\\\d+)([eE][-+]?\\\\d+)?)'; // 0x..., 0..., decimal, float\nconst BINARY_NUMBER_RE = '\\\\b(0b[01]+)'; // 0b...\nconst RE_STARTERS_RE = '!|!=|!==|%|%=|&|&&|&=|\\\\*|\\\\*=|\\\\+|\\\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\\\?|\\\\[|\\\\{|\\\\(|\\\\^|\\\\^=|\\\\||\\\\|=|\\\\|\\\\||~';\n\n/**\n* @param { Partial & {binary?: string | RegExp} } opts\n*/\nconst SHEBANG = (opts = {}) => {\n const beginShebang = /^#![ ]*\\//;\n if (opts.binary) {\n opts.begin = concat(\n beginShebang,\n /.*\\b/,\n opts.binary,\n /\\b.*/);\n }\n return inherit$1({\n scope: 'meta',\n begin: beginShebang,\n end: /$/,\n relevance: 0,\n /** @type {ModeCallback} */\n \"on:begin\": (m, resp) => {\n if (m.index !== 0) resp.ignoreMatch();\n }\n }, opts);\n};\n\n// Common modes\nconst BACKSLASH_ESCAPE = {\n begin: '\\\\\\\\[\\\\s\\\\S]', relevance: 0\n};\nconst APOS_STRING_MODE = {\n scope: 'string',\n begin: '\\'',\n end: '\\'',\n illegal: '\\\\n',\n contains: [BACKSLASH_ESCAPE]\n};\nconst QUOTE_STRING_MODE = {\n scope: 'string',\n begin: '\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [BACKSLASH_ESCAPE]\n};\nconst PHRASAL_WORDS_MODE = {\n begin: /\\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\\b/\n};\n/**\n * Creates a comment mode\n *\n * @param {string | RegExp} begin\n * @param {string | RegExp} end\n * @param {Mode | {}} [modeOptions]\n * @returns {Partial}\n */\nconst COMMENT = function(begin, end, modeOptions = {}) {\n const mode = inherit$1(\n {\n scope: 'comment',\n begin,\n end,\n contains: []\n },\n modeOptions\n );\n mode.contains.push({\n scope: 'doctag',\n // hack to avoid the space from being included. the space is necessary to\n // match here to prevent the plain text rule below from gobbling up doctags\n begin: '[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)',\n end: /(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,\n excludeBegin: true,\n relevance: 0\n });\n const ENGLISH_WORD = either(\n // list of common 1 and 2 letter words in English\n \"I\",\n \"a\",\n \"is\",\n \"so\",\n \"us\",\n \"to\",\n \"at\",\n \"if\",\n \"in\",\n \"it\",\n \"on\",\n // note: this is not an exhaustive list of contractions, just popular ones\n /[A-Za-z]+['](d|ve|re|ll|t|s|n)/, // contractions - can't we'd they're let's, etc\n /[A-Za-z]+[-][a-z]+/, // `no-way`, etc.\n /[A-Za-z][a-z]{2,}/ // allow capitalized words at beginning of sentences\n );\n // looking like plain text, more likely to be a comment\n mode.contains.push(\n {\n // TODO: how to include \", (, ) without breaking grammars that use these for\n // comment delimiters?\n // begin: /[ ]+([()\"]?([A-Za-z'-]{3,}|is|a|I|so|us|[tT][oO]|at|if|in|it|on)[.]?[()\":]?([.][ ]|[ ]|\\))){3}/\n // ---\n\n // this tries to find sequences of 3 english words in a row (without any\n // \"programming\" type syntax) this gives us a strong signal that we've\n // TRULY found a comment - vs perhaps scanning with the wrong language.\n // It's possible to find something that LOOKS like the start of the\n // comment - but then if there is no readable text - good chance it is a\n // false match and not a comment.\n //\n // for a visual example please see:\n // https://github.com/highlightjs/highlight.js/issues/2827\n\n begin: concat(\n /[ ]+/, // necessary to prevent us gobbling up doctags like /* @author Bob Mcgill */\n '(',\n ENGLISH_WORD,\n /[.]?[:]?([.][ ]|[ ])/,\n '){3}') // look for 3 words in a row\n }\n );\n return mode;\n};\nconst C_LINE_COMMENT_MODE = COMMENT('//', '$');\nconst C_BLOCK_COMMENT_MODE = COMMENT('/\\\\*', '\\\\*/');\nconst HASH_COMMENT_MODE = COMMENT('#', '$');\nconst NUMBER_MODE = {\n scope: 'number',\n begin: NUMBER_RE,\n relevance: 0\n};\nconst C_NUMBER_MODE = {\n scope: 'number',\n begin: C_NUMBER_RE,\n relevance: 0\n};\nconst BINARY_NUMBER_MODE = {\n scope: 'number',\n begin: BINARY_NUMBER_RE,\n relevance: 0\n};\nconst REGEXP_MODE = {\n scope: \"regexp\",\n begin: /\\/(?=[^/\\n]*\\/)/,\n end: /\\/[gimuy]*/,\n contains: [\n BACKSLASH_ESCAPE,\n {\n begin: /\\[/,\n end: /\\]/,\n relevance: 0,\n contains: [BACKSLASH_ESCAPE]\n }\n ]\n};\nconst TITLE_MODE = {\n scope: 'title',\n begin: IDENT_RE,\n relevance: 0\n};\nconst UNDERSCORE_TITLE_MODE = {\n scope: 'title',\n begin: UNDERSCORE_IDENT_RE,\n relevance: 0\n};\nconst METHOD_GUARD = {\n // excludes method names from keyword processing\n begin: '\\\\.\\\\s*' + UNDERSCORE_IDENT_RE,\n relevance: 0\n};\n\n/**\n * Adds end same as begin mechanics to a mode\n *\n * Your mode must include at least a single () match group as that first match\n * group is what is used for comparison\n * @param {Partial} mode\n */\nconst END_SAME_AS_BEGIN = function(mode) {\n return Object.assign(mode,\n {\n /** @type {ModeCallback} */\n 'on:begin': (m, resp) => { resp.data._beginMatch = m[1]; },\n /** @type {ModeCallback} */\n 'on:end': (m, resp) => { if (resp.data._beginMatch !== m[1]) resp.ignoreMatch(); }\n });\n};\n\nvar MODES = /*#__PURE__*/Object.freeze({\n __proto__: null,\n APOS_STRING_MODE: APOS_STRING_MODE,\n BACKSLASH_ESCAPE: BACKSLASH_ESCAPE,\n BINARY_NUMBER_MODE: BINARY_NUMBER_MODE,\n BINARY_NUMBER_RE: BINARY_NUMBER_RE,\n COMMENT: COMMENT,\n C_BLOCK_COMMENT_MODE: C_BLOCK_COMMENT_MODE,\n C_LINE_COMMENT_MODE: C_LINE_COMMENT_MODE,\n C_NUMBER_MODE: C_NUMBER_MODE,\n C_NUMBER_RE: C_NUMBER_RE,\n END_SAME_AS_BEGIN: END_SAME_AS_BEGIN,\n HASH_COMMENT_MODE: HASH_COMMENT_MODE,\n IDENT_RE: IDENT_RE,\n MATCH_NOTHING_RE: MATCH_NOTHING_RE,\n METHOD_GUARD: METHOD_GUARD,\n NUMBER_MODE: NUMBER_MODE,\n NUMBER_RE: NUMBER_RE,\n PHRASAL_WORDS_MODE: PHRASAL_WORDS_MODE,\n QUOTE_STRING_MODE: QUOTE_STRING_MODE,\n REGEXP_MODE: REGEXP_MODE,\n RE_STARTERS_RE: RE_STARTERS_RE,\n SHEBANG: SHEBANG,\n TITLE_MODE: TITLE_MODE,\n UNDERSCORE_IDENT_RE: UNDERSCORE_IDENT_RE,\n UNDERSCORE_TITLE_MODE: UNDERSCORE_TITLE_MODE\n});\n\n/**\n@typedef {import('highlight.js').CallbackResponse} CallbackResponse\n@typedef {import('highlight.js').CompilerExt} CompilerExt\n*/\n\n// Grammar extensions / plugins\n// See: https://github.com/highlightjs/highlight.js/issues/2833\n\n// Grammar extensions allow \"syntactic sugar\" to be added to the grammar modes\n// without requiring any underlying changes to the compiler internals.\n\n// `compileMatch` being the perfect small example of now allowing a grammar\n// author to write `match` when they desire to match a single expression rather\n// than being forced to use `begin`. The extension then just moves `match` into\n// `begin` when it runs. Ie, no features have been added, but we've just made\n// the experience of writing (and reading grammars) a little bit nicer.\n\n// ------\n\n// TODO: We need negative look-behind support to do this properly\n/**\n * Skip a match if it has a preceding dot\n *\n * This is used for `beginKeywords` to prevent matching expressions such as\n * `bob.keyword.do()`. The mode compiler automatically wires this up as a\n * special _internal_ 'on:begin' callback for modes with `beginKeywords`\n * @param {RegExpMatchArray} match\n * @param {CallbackResponse} response\n */\nfunction skipIfHasPrecedingDot(match, response) {\n const before = match.input[match.index - 1];\n if (before === \".\") {\n response.ignoreMatch();\n }\n}\n\n/**\n *\n * @type {CompilerExt}\n */\nfunction scopeClassName(mode, _parent) {\n // eslint-disable-next-line no-undefined\n if (mode.className !== undefined) {\n mode.scope = mode.className;\n delete mode.className;\n }\n}\n\n/**\n * `beginKeywords` syntactic sugar\n * @type {CompilerExt}\n */\nfunction beginKeywords(mode, parent) {\n if (!parent) return;\n if (!mode.beginKeywords) return;\n\n // for languages with keywords that include non-word characters checking for\n // a word boundary is not sufficient, so instead we check for a word boundary\n // or whitespace - this does no harm in any case since our keyword engine\n // doesn't allow spaces in keywords anyways and we still check for the boundary\n // first\n mode.begin = '\\\\b(' + mode.beginKeywords.split(' ').join('|') + ')(?!\\\\.)(?=\\\\b|\\\\s)';\n mode.__beforeBegin = skipIfHasPrecedingDot;\n mode.keywords = mode.keywords || mode.beginKeywords;\n delete mode.beginKeywords;\n\n // prevents double relevance, the keywords themselves provide\n // relevance, the mode doesn't need to double it\n // eslint-disable-next-line no-undefined\n if (mode.relevance === undefined) mode.relevance = 0;\n}\n\n/**\n * Allow `illegal` to contain an array of illegal values\n * @type {CompilerExt}\n */\nfunction compileIllegal(mode, _parent) {\n if (!Array.isArray(mode.illegal)) return;\n\n mode.illegal = either(...mode.illegal);\n}\n\n/**\n * `match` to match a single expression for readability\n * @type {CompilerExt}\n */\nfunction compileMatch(mode, _parent) {\n if (!mode.match) return;\n if (mode.begin || mode.end) throw new Error(\"begin & end are not supported with match\");\n\n mode.begin = mode.match;\n delete mode.match;\n}\n\n/**\n * provides the default 1 relevance to all modes\n * @type {CompilerExt}\n */\nfunction compileRelevance(mode, _parent) {\n // eslint-disable-next-line no-undefined\n if (mode.relevance === undefined) mode.relevance = 1;\n}\n\n// allow beforeMatch to act as a \"qualifier\" for the match\n// the full match begin must be [beforeMatch][begin]\nconst beforeMatchExt = (mode, parent) => {\n if (!mode.beforeMatch) return;\n // starts conflicts with endsParent which we need to make sure the child\n // rule is not matched multiple times\n if (mode.starts) throw new Error(\"beforeMatch cannot be used with starts\");\n\n const originalMode = Object.assign({}, mode);\n Object.keys(mode).forEach((key) => { delete mode[key]; });\n\n mode.keywords = originalMode.keywords;\n mode.begin = concat(originalMode.beforeMatch, lookahead(originalMode.begin));\n mode.starts = {\n relevance: 0,\n contains: [\n Object.assign(originalMode, { endsParent: true })\n ]\n };\n mode.relevance = 0;\n\n delete originalMode.beforeMatch;\n};\n\n// keywords that should have no default relevance value\nconst COMMON_KEYWORDS = [\n 'of',\n 'and',\n 'for',\n 'in',\n 'not',\n 'or',\n 'if',\n 'then',\n 'parent', // common variable name\n 'list', // common variable name\n 'value' // common variable name\n];\n\nconst DEFAULT_KEYWORD_SCOPE = \"keyword\";\n\n/**\n * Given raw keywords from a language definition, compile them.\n *\n * @param {string | Record | Array} rawKeywords\n * @param {boolean} caseInsensitive\n */\nfunction compileKeywords(rawKeywords, caseInsensitive, scopeName = DEFAULT_KEYWORD_SCOPE) {\n /** @type {import(\"highlight.js/private\").KeywordDict} */\n const compiledKeywords = Object.create(null);\n\n // input can be a string of keywords, an array of keywords, or a object with\n // named keys representing scopeName (which can then point to a string or array)\n if (typeof rawKeywords === 'string') {\n compileList(scopeName, rawKeywords.split(\" \"));\n } else if (Array.isArray(rawKeywords)) {\n compileList(scopeName, rawKeywords);\n } else {\n Object.keys(rawKeywords).forEach(function(scopeName) {\n // collapse all our objects back into the parent object\n Object.assign(\n compiledKeywords,\n compileKeywords(rawKeywords[scopeName], caseInsensitive, scopeName)\n );\n });\n }\n return compiledKeywords;\n\n // ---\n\n /**\n * Compiles an individual list of keywords\n *\n * Ex: \"for if when while|5\"\n *\n * @param {string} scopeName\n * @param {Array} keywordList\n */\n function compileList(scopeName, keywordList) {\n if (caseInsensitive) {\n keywordList = keywordList.map(x => x.toLowerCase());\n }\n keywordList.forEach(function(keyword) {\n const pair = keyword.split('|');\n compiledKeywords[pair[0]] = [scopeName, scoreForKeyword(pair[0], pair[1])];\n });\n }\n}\n\n/**\n * Returns the proper score for a given keyword\n *\n * Also takes into account comment keywords, which will be scored 0 UNLESS\n * another score has been manually assigned.\n * @param {string} keyword\n * @param {string} [providedScore]\n */\nfunction scoreForKeyword(keyword, providedScore) {\n // manual scores always win over common keywords\n // so you can force a score of 1 if you really insist\n if (providedScore) {\n return Number(providedScore);\n }\n\n return commonKeyword(keyword) ? 0 : 1;\n}\n\n/**\n * Determines if a given keyword is common or not\n *\n * @param {string} keyword */\nfunction commonKeyword(keyword) {\n return COMMON_KEYWORDS.includes(keyword.toLowerCase());\n}\n\n/*\n\nFor the reasoning behind this please see:\nhttps://github.com/highlightjs/highlight.js/issues/2880#issuecomment-747275419\n\n*/\n\n/**\n * @type {Record}\n */\nconst seenDeprecations = {};\n\n/**\n * @param {string} message\n */\nconst error = (message) => {\n console.error(message);\n};\n\n/**\n * @param {string} message\n * @param {any} args\n */\nconst warn = (message, ...args) => {\n console.log(`WARN: ${message}`, ...args);\n};\n\n/**\n * @param {string} version\n * @param {string} message\n */\nconst deprecated = (version, message) => {\n if (seenDeprecations[`${version}/${message}`]) return;\n\n console.log(`Deprecated as of ${version}. ${message}`);\n seenDeprecations[`${version}/${message}`] = true;\n};\n\n/* eslint-disable no-throw-literal */\n\n/**\n@typedef {import('highlight.js').CompiledMode} CompiledMode\n*/\n\nconst MultiClassError = new Error();\n\n/**\n * Renumbers labeled scope names to account for additional inner match\n * groups that otherwise would break everything.\n *\n * Lets say we 3 match scopes:\n *\n * { 1 => ..., 2 => ..., 3 => ... }\n *\n * So what we need is a clean match like this:\n *\n * (a)(b)(c) => [ \"a\", \"b\", \"c\" ]\n *\n * But this falls apart with inner match groups:\n *\n * (a)(((b)))(c) => [\"a\", \"b\", \"b\", \"b\", \"c\" ]\n *\n * Our scopes are now \"out of alignment\" and we're repeating `b` 3 times.\n * What needs to happen is the numbers are remapped:\n *\n * { 1 => ..., 2 => ..., 5 => ... }\n *\n * We also need to know that the ONLY groups that should be output\n * are 1, 2, and 5. This function handles this behavior.\n *\n * @param {CompiledMode} mode\n * @param {Array} regexes\n * @param {{key: \"beginScope\"|\"endScope\"}} opts\n */\nfunction remapScopeNames(mode, regexes, { key }) {\n let offset = 0;\n const scopeNames = mode[key];\n /** @type Record */\n const emit = {};\n /** @type Record */\n const positions = {};\n\n for (let i = 1; i <= regexes.length; i++) {\n positions[i + offset] = scopeNames[i];\n emit[i + offset] = true;\n offset += countMatchGroups(regexes[i - 1]);\n }\n // we use _emit to keep track of which match groups are \"top-level\" to avoid double\n // output from inside match groups\n mode[key] = positions;\n mode[key]._emit = emit;\n mode[key]._multi = true;\n}\n\n/**\n * @param {CompiledMode} mode\n */\nfunction beginMultiClass(mode) {\n if (!Array.isArray(mode.begin)) return;\n\n if (mode.skip || mode.excludeBegin || mode.returnBegin) {\n error(\"skip, excludeBegin, returnBegin not compatible with beginScope: {}\");\n throw MultiClassError;\n }\n\n if (typeof mode.beginScope !== \"object\" || mode.beginScope === null) {\n error(\"beginScope must be object\");\n throw MultiClassError;\n }\n\n remapScopeNames(mode, mode.begin, { key: \"beginScope\" });\n mode.begin = _rewriteBackreferences(mode.begin, { joinWith: \"\" });\n}\n\n/**\n * @param {CompiledMode} mode\n */\nfunction endMultiClass(mode) {\n if (!Array.isArray(mode.end)) return;\n\n if (mode.skip || mode.excludeEnd || mode.returnEnd) {\n error(\"skip, excludeEnd, returnEnd not compatible with endScope: {}\");\n throw MultiClassError;\n }\n\n if (typeof mode.endScope !== \"object\" || mode.endScope === null) {\n error(\"endScope must be object\");\n throw MultiClassError;\n }\n\n remapScopeNames(mode, mode.end, { key: \"endScope\" });\n mode.end = _rewriteBackreferences(mode.end, { joinWith: \"\" });\n}\n\n/**\n * this exists only to allow `scope: {}` to be used beside `match:`\n * Otherwise `beginScope` would necessary and that would look weird\n\n {\n match: [ /def/, /\\w+/ ]\n scope: { 1: \"keyword\" , 2: \"title\" }\n }\n\n * @param {CompiledMode} mode\n */\nfunction scopeSugar(mode) {\n if (mode.scope && typeof mode.scope === \"object\" && mode.scope !== null) {\n mode.beginScope = mode.scope;\n delete mode.scope;\n }\n}\n\n/**\n * @param {CompiledMode} mode\n */\nfunction MultiClass(mode) {\n scopeSugar(mode);\n\n if (typeof mode.beginScope === \"string\") {\n mode.beginScope = { _wrap: mode.beginScope };\n }\n if (typeof mode.endScope === \"string\") {\n mode.endScope = { _wrap: mode.endScope };\n }\n\n beginMultiClass(mode);\n endMultiClass(mode);\n}\n\n/**\n@typedef {import('highlight.js').Mode} Mode\n@typedef {import('highlight.js').CompiledMode} CompiledMode\n@typedef {import('highlight.js').Language} Language\n@typedef {import('highlight.js').HLJSPlugin} HLJSPlugin\n@typedef {import('highlight.js').CompiledLanguage} CompiledLanguage\n*/\n\n// compilation\n\n/**\n * Compiles a language definition result\n *\n * Given the raw result of a language definition (Language), compiles this so\n * that it is ready for highlighting code.\n * @param {Language} language\n * @returns {CompiledLanguage}\n */\nfunction compileLanguage(language) {\n /**\n * Builds a regex with the case sensitivity of the current language\n *\n * @param {RegExp | string} value\n * @param {boolean} [global]\n */\n function langRe(value, global) {\n return new RegExp(\n source(value),\n 'm'\n + (language.case_insensitive ? 'i' : '')\n + (language.unicodeRegex ? 'u' : '')\n + (global ? 'g' : '')\n );\n }\n\n /**\n Stores multiple regular expressions and allows you to quickly search for\n them all in a string simultaneously - returning the first match. It does\n this by creating a huge (a|b|c) regex - each individual item wrapped with ()\n and joined by `|` - using match groups to track position. When a match is\n found checking which position in the array has content allows us to figure\n out which of the original regexes / match groups triggered the match.\n\n The match object itself (the result of `Regex.exec`) is returned but also\n enhanced by merging in any meta-data that was registered with the regex.\n This is how we keep track of which mode matched, and what type of rule\n (`illegal`, `begin`, end, etc).\n */\n class MultiRegex {\n constructor() {\n this.matchIndexes = {};\n // @ts-ignore\n this.regexes = [];\n this.matchAt = 1;\n this.position = 0;\n }\n\n // @ts-ignore\n addRule(re, opts) {\n opts.position = this.position++;\n // @ts-ignore\n this.matchIndexes[this.matchAt] = opts;\n this.regexes.push([opts, re]);\n this.matchAt += countMatchGroups(re) + 1;\n }\n\n compile() {\n if (this.regexes.length === 0) {\n // avoids the need to check length every time exec is called\n // @ts-ignore\n this.exec = () => null;\n }\n const terminators = this.regexes.map(el => el[1]);\n this.matcherRe = langRe(_rewriteBackreferences(terminators, { joinWith: '|' }), true);\n this.lastIndex = 0;\n }\n\n /** @param {string} s */\n exec(s) {\n this.matcherRe.lastIndex = this.lastIndex;\n const match = this.matcherRe.exec(s);\n if (!match) { return null; }\n\n // eslint-disable-next-line no-undefined\n const i = match.findIndex((el, i) => i > 0 && el !== undefined);\n // @ts-ignore\n const matchData = this.matchIndexes[i];\n // trim off any earlier non-relevant match groups (ie, the other regex\n // match groups that make up the multi-matcher)\n match.splice(0, i);\n\n return Object.assign(match, matchData);\n }\n }\n\n /*\n Created to solve the key deficiently with MultiRegex - there is no way to\n test for multiple matches at a single location. Why would we need to do\n that? In the future a more dynamic engine will allow certain matches to be\n ignored. An example: if we matched say the 3rd regex in a large group but\n decided to ignore it - we'd need to started testing again at the 4th\n regex... but MultiRegex itself gives us no real way to do that.\n\n So what this class creates MultiRegexs on the fly for whatever search\n position they are needed.\n\n NOTE: These additional MultiRegex objects are created dynamically. For most\n grammars most of the time we will never actually need anything more than the\n first MultiRegex - so this shouldn't have too much overhead.\n\n Say this is our search group, and we match regex3, but wish to ignore it.\n\n regex1 | regex2 | regex3 | regex4 | regex5 ' ie, startAt = 0\n\n What we need is a new MultiRegex that only includes the remaining\n possibilities:\n\n regex4 | regex5 ' ie, startAt = 3\n\n This class wraps all that complexity up in a simple API... `startAt` decides\n where in the array of expressions to start doing the matching. It\n auto-increments, so if a match is found at position 2, then startAt will be\n set to 3. If the end is reached startAt will return to 0.\n\n MOST of the time the parser will be setting startAt manually to 0.\n */\n class ResumableMultiRegex {\n constructor() {\n // @ts-ignore\n this.rules = [];\n // @ts-ignore\n this.multiRegexes = [];\n this.count = 0;\n\n this.lastIndex = 0;\n this.regexIndex = 0;\n }\n\n // @ts-ignore\n getMatcher(index) {\n if (this.multiRegexes[index]) return this.multiRegexes[index];\n\n const matcher = new MultiRegex();\n this.rules.slice(index).forEach(([re, opts]) => matcher.addRule(re, opts));\n matcher.compile();\n this.multiRegexes[index] = matcher;\n return matcher;\n }\n\n resumingScanAtSamePosition() {\n return this.regexIndex !== 0;\n }\n\n considerAll() {\n this.regexIndex = 0;\n }\n\n // @ts-ignore\n addRule(re, opts) {\n this.rules.push([re, opts]);\n if (opts.type === \"begin\") this.count++;\n }\n\n /** @param {string} s */\n exec(s) {\n const m = this.getMatcher(this.regexIndex);\n m.lastIndex = this.lastIndex;\n let result = m.exec(s);\n\n // The following is because we have no easy way to say \"resume scanning at the\n // existing position but also skip the current rule ONLY\". What happens is\n // all prior rules are also skipped which can result in matching the wrong\n // thing. Example of matching \"booger\":\n\n // our matcher is [string, \"booger\", number]\n //\n // ....booger....\n\n // if \"booger\" is ignored then we'd really need a regex to scan from the\n // SAME position for only: [string, number] but ignoring \"booger\" (if it\n // was the first match), a simple resume would scan ahead who knows how\n // far looking only for \"number\", ignoring potential string matches (or\n // future \"booger\" matches that might be valid.)\n\n // So what we do: We execute two matchers, one resuming at the same\n // position, but the second full matcher starting at the position after:\n\n // /--- resume first regex match here (for [number])\n // |/---- full match here for [string, \"booger\", number]\n // vv\n // ....booger....\n\n // Which ever results in a match first is then used. So this 3-4 step\n // process essentially allows us to say \"match at this position, excluding\n // a prior rule that was ignored\".\n //\n // 1. Match \"booger\" first, ignore. Also proves that [string] does non match.\n // 2. Resume matching for [number]\n // 3. Match at index + 1 for [string, \"booger\", number]\n // 4. If #2 and #3 result in matches, which came first?\n if (this.resumingScanAtSamePosition()) {\n if (result && result.index === this.lastIndex) ; else { // use the second matcher result\n const m2 = this.getMatcher(0);\n m2.lastIndex = this.lastIndex + 1;\n result = m2.exec(s);\n }\n }\n\n if (result) {\n this.regexIndex += result.position + 1;\n if (this.regexIndex === this.count) {\n // wrap-around to considering all matches again\n this.considerAll();\n }\n }\n\n return result;\n }\n }\n\n /**\n * Given a mode, builds a huge ResumableMultiRegex that can be used to walk\n * the content and find matches.\n *\n * @param {CompiledMode} mode\n * @returns {ResumableMultiRegex}\n */\n function buildModeRegex(mode) {\n const mm = new ResumableMultiRegex();\n\n mode.contains.forEach(term => mm.addRule(term.begin, { rule: term, type: \"begin\" }));\n\n if (mode.terminatorEnd) {\n mm.addRule(mode.terminatorEnd, { type: \"end\" });\n }\n if (mode.illegal) {\n mm.addRule(mode.illegal, { type: \"illegal\" });\n }\n\n return mm;\n }\n\n /** skip vs abort vs ignore\n *\n * @skip - The mode is still entered and exited normally (and contains rules apply),\n * but all content is held and added to the parent buffer rather than being\n * output when the mode ends. Mostly used with `sublanguage` to build up\n * a single large buffer than can be parsed by sublanguage.\n *\n * - The mode begin ands ends normally.\n * - Content matched is added to the parent mode buffer.\n * - The parser cursor is moved forward normally.\n *\n * @abort - A hack placeholder until we have ignore. Aborts the mode (as if it\n * never matched) but DOES NOT continue to match subsequent `contains`\n * modes. Abort is bad/suboptimal because it can result in modes\n * farther down not getting applied because an earlier rule eats the\n * content but then aborts.\n *\n * - The mode does not begin.\n * - Content matched by `begin` is added to the mode buffer.\n * - The parser cursor is moved forward accordingly.\n *\n * @ignore - Ignores the mode (as if it never matched) and continues to match any\n * subsequent `contains` modes. Ignore isn't technically possible with\n * the current parser implementation.\n *\n * - The mode does not begin.\n * - Content matched by `begin` is ignored.\n * - The parser cursor is not moved forward.\n */\n\n /**\n * Compiles an individual mode\n *\n * This can raise an error if the mode contains certain detectable known logic\n * issues.\n * @param {Mode} mode\n * @param {CompiledMode | null} [parent]\n * @returns {CompiledMode | never}\n */\n function compileMode(mode, parent) {\n const cmode = /** @type CompiledMode */ (mode);\n if (mode.isCompiled) return cmode;\n\n [\n scopeClassName,\n // do this early so compiler extensions generally don't have to worry about\n // the distinction between match/begin\n compileMatch,\n MultiClass,\n beforeMatchExt\n ].forEach(ext => ext(mode, parent));\n\n language.compilerExtensions.forEach(ext => ext(mode, parent));\n\n // __beforeBegin is considered private API, internal use only\n mode.__beforeBegin = null;\n\n [\n beginKeywords,\n // do this later so compiler extensions that come earlier have access to the\n // raw array if they wanted to perhaps manipulate it, etc.\n compileIllegal,\n // default to 1 relevance if not specified\n compileRelevance\n ].forEach(ext => ext(mode, parent));\n\n mode.isCompiled = true;\n\n let keywordPattern = null;\n if (typeof mode.keywords === \"object\" && mode.keywords.$pattern) {\n // we need a copy because keywords might be compiled multiple times\n // so we can't go deleting $pattern from the original on the first\n // pass\n mode.keywords = Object.assign({}, mode.keywords);\n keywordPattern = mode.keywords.$pattern;\n delete mode.keywords.$pattern;\n }\n keywordPattern = keywordPattern || /\\w+/;\n\n if (mode.keywords) {\n mode.keywords = compileKeywords(mode.keywords, language.case_insensitive);\n }\n\n cmode.keywordPatternRe = langRe(keywordPattern, true);\n\n if (parent) {\n if (!mode.begin) mode.begin = /\\B|\\b/;\n cmode.beginRe = langRe(cmode.begin);\n if (!mode.end && !mode.endsWithParent) mode.end = /\\B|\\b/;\n if (mode.end) cmode.endRe = langRe(cmode.end);\n cmode.terminatorEnd = source(cmode.end) || '';\n if (mode.endsWithParent && parent.terminatorEnd) {\n cmode.terminatorEnd += (mode.end ? '|' : '') + parent.terminatorEnd;\n }\n }\n if (mode.illegal) cmode.illegalRe = langRe(/** @type {RegExp | string} */ (mode.illegal));\n if (!mode.contains) mode.contains = [];\n\n mode.contains = [].concat(...mode.contains.map(function(c) {\n return expandOrCloneMode(c === 'self' ? mode : c);\n }));\n mode.contains.forEach(function(c) { compileMode(/** @type Mode */ (c), cmode); });\n\n if (mode.starts) {\n compileMode(mode.starts, parent);\n }\n\n cmode.matcher = buildModeRegex(cmode);\n return cmode;\n }\n\n if (!language.compilerExtensions) language.compilerExtensions = [];\n\n // self is not valid at the top-level\n if (language.contains && language.contains.includes('self')) {\n throw new Error(\"ERR: contains `self` is not supported at the top-level of a language. See documentation.\");\n }\n\n // we need a null object, which inherit will guarantee\n language.classNameAliases = inherit$1(language.classNameAliases || {});\n\n return compileMode(/** @type Mode */ (language));\n}\n\n/**\n * Determines if a mode has a dependency on it's parent or not\n *\n * If a mode does have a parent dependency then often we need to clone it if\n * it's used in multiple places so that each copy points to the correct parent,\n * where-as modes without a parent can often safely be re-used at the bottom of\n * a mode chain.\n *\n * @param {Mode | null} mode\n * @returns {boolean} - is there a dependency on the parent?\n * */\nfunction dependencyOnParent(mode) {\n if (!mode) return false;\n\n return mode.endsWithParent || dependencyOnParent(mode.starts);\n}\n\n/**\n * Expands a mode or clones it if necessary\n *\n * This is necessary for modes with parental dependenceis (see notes on\n * `dependencyOnParent`) and for nodes that have `variants` - which must then be\n * exploded into their own individual modes at compile time.\n *\n * @param {Mode} mode\n * @returns {Mode | Mode[]}\n * */\nfunction expandOrCloneMode(mode) {\n if (mode.variants && !mode.cachedVariants) {\n mode.cachedVariants = mode.variants.map(function(variant) {\n return inherit$1(mode, { variants: null }, variant);\n });\n }\n\n // EXPAND\n // if we have variants then essentially \"replace\" the mode with the variants\n // this happens in compileMode, where this function is called from\n if (mode.cachedVariants) {\n return mode.cachedVariants;\n }\n\n // CLONE\n // if we have dependencies on parents then we need a unique\n // instance of ourselves, so we can be reused with many\n // different parents without issue\n if (dependencyOnParent(mode)) {\n return inherit$1(mode, { starts: mode.starts ? inherit$1(mode.starts) : null });\n }\n\n if (Object.isFrozen(mode)) {\n return inherit$1(mode);\n }\n\n // no special dependency issues, just return ourselves\n return mode;\n}\n\nvar version = \"11.10.0\";\n\nclass HTMLInjectionError extends Error {\n constructor(reason, html) {\n super(reason);\n this.name = \"HTMLInjectionError\";\n this.html = html;\n }\n}\n\n/*\nSyntax highlighting with language autodetection.\nhttps://highlightjs.org/\n*/\n\n\n\n/**\n@typedef {import('highlight.js').Mode} Mode\n@typedef {import('highlight.js').CompiledMode} CompiledMode\n@typedef {import('highlight.js').CompiledScope} CompiledScope\n@typedef {import('highlight.js').Language} Language\n@typedef {import('highlight.js').HLJSApi} HLJSApi\n@typedef {import('highlight.js').HLJSPlugin} HLJSPlugin\n@typedef {import('highlight.js').PluginEvent} PluginEvent\n@typedef {import('highlight.js').HLJSOptions} HLJSOptions\n@typedef {import('highlight.js').LanguageFn} LanguageFn\n@typedef {import('highlight.js').HighlightedHTMLElement} HighlightedHTMLElement\n@typedef {import('highlight.js').BeforeHighlightContext} BeforeHighlightContext\n@typedef {import('highlight.js/private').MatchType} MatchType\n@typedef {import('highlight.js/private').KeywordData} KeywordData\n@typedef {import('highlight.js/private').EnhancedMatch} EnhancedMatch\n@typedef {import('highlight.js/private').AnnotatedError} AnnotatedError\n@typedef {import('highlight.js').AutoHighlightResult} AutoHighlightResult\n@typedef {import('highlight.js').HighlightOptions} HighlightOptions\n@typedef {import('highlight.js').HighlightResult} HighlightResult\n*/\n\n\nconst escape = escapeHTML;\nconst inherit = inherit$1;\nconst NO_MATCH = Symbol(\"nomatch\");\nconst MAX_KEYWORD_HITS = 7;\n\n/**\n * @param {any} hljs - object that is extended (legacy)\n * @returns {HLJSApi}\n */\nconst HLJS = function(hljs) {\n // Global internal variables used within the highlight.js library.\n /** @type {Record} */\n const languages = Object.create(null);\n /** @type {Record} */\n const aliases = Object.create(null);\n /** @type {HLJSPlugin[]} */\n const plugins = [];\n\n // safe/production mode - swallows more errors, tries to keep running\n // even if a single syntax or parse hits a fatal error\n let SAFE_MODE = true;\n const LANGUAGE_NOT_FOUND = \"Could not find the language '{}', did you forget to load/include a language module?\";\n /** @type {Language} */\n const PLAINTEXT_LANGUAGE = { disableAutodetect: true, name: 'Plain text', contains: [] };\n\n // Global options used when within external APIs. This is modified when\n // calling the `hljs.configure` function.\n /** @type HLJSOptions */\n let options = {\n ignoreUnescapedHTML: false,\n throwUnescapedHTML: false,\n noHighlightRe: /^(no-?highlight)$/i,\n languageDetectRe: /\\blang(?:uage)?-([\\w-]+)\\b/i,\n classPrefix: 'hljs-',\n cssSelector: 'pre code',\n languages: null,\n // beta configuration options, subject to change, welcome to discuss\n // https://github.com/highlightjs/highlight.js/issues/1086\n __emitter: TokenTreeEmitter\n };\n\n /* Utility functions */\n\n /**\n * Tests a language name to see if highlighting should be skipped\n * @param {string} languageName\n */\n function shouldNotHighlight(languageName) {\n return options.noHighlightRe.test(languageName);\n }\n\n /**\n * @param {HighlightedHTMLElement} block - the HTML element to determine language for\n */\n function blockLanguage(block) {\n let classes = block.className + ' ';\n\n classes += block.parentNode ? block.parentNode.className : '';\n\n // language-* takes precedence over non-prefixed class names.\n const match = options.languageDetectRe.exec(classes);\n if (match) {\n const language = getLanguage(match[1]);\n if (!language) {\n warn(LANGUAGE_NOT_FOUND.replace(\"{}\", match[1]));\n warn(\"Falling back to no-highlight mode for this block.\", block);\n }\n return language ? match[1] : 'no-highlight';\n }\n\n return classes\n .split(/\\s+/)\n .find((_class) => shouldNotHighlight(_class) || getLanguage(_class));\n }\n\n /**\n * Core highlighting function.\n *\n * OLD API\n * highlight(lang, code, ignoreIllegals, continuation)\n *\n * NEW API\n * highlight(code, {lang, ignoreIllegals})\n *\n * @param {string} codeOrLanguageName - the language to use for highlighting\n * @param {string | HighlightOptions} optionsOrCode - the code to highlight\n * @param {boolean} [ignoreIllegals] - whether to ignore illegal matches, default is to bail\n *\n * @returns {HighlightResult} Result - an object that represents the result\n * @property {string} language - the language name\n * @property {number} relevance - the relevance score\n * @property {string} value - the highlighted HTML code\n * @property {string} code - the original raw code\n * @property {CompiledMode} top - top of the current mode stack\n * @property {boolean} illegal - indicates whether any illegal matches were found\n */\n function highlight(codeOrLanguageName, optionsOrCode, ignoreIllegals) {\n let code = \"\";\n let languageName = \"\";\n if (typeof optionsOrCode === \"object\") {\n code = codeOrLanguageName;\n ignoreIllegals = optionsOrCode.ignoreIllegals;\n languageName = optionsOrCode.language;\n } else {\n // old API\n deprecated(\"10.7.0\", \"highlight(lang, code, ...args) has been deprecated.\");\n deprecated(\"10.7.0\", \"Please use highlight(code, options) instead.\\nhttps://github.com/highlightjs/highlight.js/issues/2277\");\n languageName = codeOrLanguageName;\n code = optionsOrCode;\n }\n\n // https://github.com/highlightjs/highlight.js/issues/3149\n // eslint-disable-next-line no-undefined\n if (ignoreIllegals === undefined) { ignoreIllegals = true; }\n\n /** @type {BeforeHighlightContext} */\n const context = {\n code,\n language: languageName\n };\n // the plugin can change the desired language or the code to be highlighted\n // just be changing the object it was passed\n fire(\"before:highlight\", context);\n\n // a before plugin can usurp the result completely by providing it's own\n // in which case we don't even need to call highlight\n const result = context.result\n ? context.result\n : _highlight(context.language, context.code, ignoreIllegals);\n\n result.code = context.code;\n // the plugin can change anything in result to suite it\n fire(\"after:highlight\", result);\n\n return result;\n }\n\n /**\n * private highlight that's used internally and does not fire callbacks\n *\n * @param {string} languageName - the language to use for highlighting\n * @param {string} codeToHighlight - the code to highlight\n * @param {boolean?} [ignoreIllegals] - whether to ignore illegal matches, default is to bail\n * @param {CompiledMode?} [continuation] - current continuation mode, if any\n * @returns {HighlightResult} - result of the highlight operation\n */\n function _highlight(languageName, codeToHighlight, ignoreIllegals, continuation) {\n const keywordHits = Object.create(null);\n\n /**\n * Return keyword data if a match is a keyword\n * @param {CompiledMode} mode - current mode\n * @param {string} matchText - the textual match\n * @returns {KeywordData | false}\n */\n function keywordData(mode, matchText) {\n return mode.keywords[matchText];\n }\n\n function processKeywords() {\n if (!top.keywords) {\n emitter.addText(modeBuffer);\n return;\n }\n\n let lastIndex = 0;\n top.keywordPatternRe.lastIndex = 0;\n let match = top.keywordPatternRe.exec(modeBuffer);\n let buf = \"\";\n\n while (match) {\n buf += modeBuffer.substring(lastIndex, match.index);\n const word = language.case_insensitive ? match[0].toLowerCase() : match[0];\n const data = keywordData(top, word);\n if (data) {\n const [kind, keywordRelevance] = data;\n emitter.addText(buf);\n buf = \"\";\n\n keywordHits[word] = (keywordHits[word] || 0) + 1;\n if (keywordHits[word] <= MAX_KEYWORD_HITS) relevance += keywordRelevance;\n if (kind.startsWith(\"_\")) {\n // _ implied for relevance only, do not highlight\n // by applying a class name\n buf += match[0];\n } else {\n const cssClass = language.classNameAliases[kind] || kind;\n emitKeyword(match[0], cssClass);\n }\n } else {\n buf += match[0];\n }\n lastIndex = top.keywordPatternRe.lastIndex;\n match = top.keywordPatternRe.exec(modeBuffer);\n }\n buf += modeBuffer.substring(lastIndex);\n emitter.addText(buf);\n }\n\n function processSubLanguage() {\n if (modeBuffer === \"\") return;\n /** @type HighlightResult */\n let result = null;\n\n if (typeof top.subLanguage === 'string') {\n if (!languages[top.subLanguage]) {\n emitter.addText(modeBuffer);\n return;\n }\n result = _highlight(top.subLanguage, modeBuffer, true, continuations[top.subLanguage]);\n continuations[top.subLanguage] = /** @type {CompiledMode} */ (result._top);\n } else {\n result = highlightAuto(modeBuffer, top.subLanguage.length ? top.subLanguage : null);\n }\n\n // Counting embedded language score towards the host language may be disabled\n // with zeroing the containing mode relevance. Use case in point is Markdown that\n // allows XML everywhere and makes every XML snippet to have a much larger Markdown\n // score.\n if (top.relevance > 0) {\n relevance += result.relevance;\n }\n emitter.__addSublanguage(result._emitter, result.language);\n }\n\n function processBuffer() {\n if (top.subLanguage != null) {\n processSubLanguage();\n } else {\n processKeywords();\n }\n modeBuffer = '';\n }\n\n /**\n * @param {string} text\n * @param {string} scope\n */\n function emitKeyword(keyword, scope) {\n if (keyword === \"\") return;\n\n emitter.startScope(scope);\n emitter.addText(keyword);\n emitter.endScope();\n }\n\n /**\n * @param {CompiledScope} scope\n * @param {RegExpMatchArray} match\n */\n function emitMultiClass(scope, match) {\n let i = 1;\n const max = match.length - 1;\n while (i <= max) {\n if (!scope._emit[i]) { i++; continue; }\n const klass = language.classNameAliases[scope[i]] || scope[i];\n const text = match[i];\n if (klass) {\n emitKeyword(text, klass);\n } else {\n modeBuffer = text;\n processKeywords();\n modeBuffer = \"\";\n }\n i++;\n }\n }\n\n /**\n * @param {CompiledMode} mode - new mode to start\n * @param {RegExpMatchArray} match\n */\n function startNewMode(mode, match) {\n if (mode.scope && typeof mode.scope === \"string\") {\n emitter.openNode(language.classNameAliases[mode.scope] || mode.scope);\n }\n if (mode.beginScope) {\n // beginScope just wraps the begin match itself in a scope\n if (mode.beginScope._wrap) {\n emitKeyword(modeBuffer, language.classNameAliases[mode.beginScope._wrap] || mode.beginScope._wrap);\n modeBuffer = \"\";\n } else if (mode.beginScope._multi) {\n // at this point modeBuffer should just be the match\n emitMultiClass(mode.beginScope, match);\n modeBuffer = \"\";\n }\n }\n\n top = Object.create(mode, { parent: { value: top } });\n return top;\n }\n\n /**\n * @param {CompiledMode } mode - the mode to potentially end\n * @param {RegExpMatchArray} match - the latest match\n * @param {string} matchPlusRemainder - match plus remainder of content\n * @returns {CompiledMode | void} - the next mode, or if void continue on in current mode\n */\n function endOfMode(mode, match, matchPlusRemainder) {\n let matched = startsWith(mode.endRe, matchPlusRemainder);\n\n if (matched) {\n if (mode[\"on:end\"]) {\n const resp = new Response(mode);\n mode[\"on:end\"](match, resp);\n if (resp.isMatchIgnored) matched = false;\n }\n\n if (matched) {\n while (mode.endsParent && mode.parent) {\n mode = mode.parent;\n }\n return mode;\n }\n }\n // even if on:end fires an `ignore` it's still possible\n // that we might trigger the end node because of a parent mode\n if (mode.endsWithParent) {\n return endOfMode(mode.parent, match, matchPlusRemainder);\n }\n }\n\n /**\n * Handle matching but then ignoring a sequence of text\n *\n * @param {string} lexeme - string containing full match text\n */\n function doIgnore(lexeme) {\n if (top.matcher.regexIndex === 0) {\n // no more regexes to potentially match here, so we move the cursor forward one\n // space\n modeBuffer += lexeme[0];\n return 1;\n } else {\n // no need to move the cursor, we still have additional regexes to try and\n // match at this very spot\n resumeScanAtSamePosition = true;\n return 0;\n }\n }\n\n /**\n * Handle the start of a new potential mode match\n *\n * @param {EnhancedMatch} match - the current match\n * @returns {number} how far to advance the parse cursor\n */\n function doBeginMatch(match) {\n const lexeme = match[0];\n const newMode = match.rule;\n\n const resp = new Response(newMode);\n // first internal before callbacks, then the public ones\n const beforeCallbacks = [newMode.__beforeBegin, newMode[\"on:begin\"]];\n for (const cb of beforeCallbacks) {\n if (!cb) continue;\n cb(match, resp);\n if (resp.isMatchIgnored) return doIgnore(lexeme);\n }\n\n if (newMode.skip) {\n modeBuffer += lexeme;\n } else {\n if (newMode.excludeBegin) {\n modeBuffer += lexeme;\n }\n processBuffer();\n if (!newMode.returnBegin && !newMode.excludeBegin) {\n modeBuffer = lexeme;\n }\n }\n startNewMode(newMode, match);\n return newMode.returnBegin ? 0 : lexeme.length;\n }\n\n /**\n * Handle the potential end of mode\n *\n * @param {RegExpMatchArray} match - the current match\n */\n function doEndMatch(match) {\n const lexeme = match[0];\n const matchPlusRemainder = codeToHighlight.substring(match.index);\n\n const endMode = endOfMode(top, match, matchPlusRemainder);\n if (!endMode) { return NO_MATCH; }\n\n const origin = top;\n if (top.endScope && top.endScope._wrap) {\n processBuffer();\n emitKeyword(lexeme, top.endScope._wrap);\n } else if (top.endScope && top.endScope._multi) {\n processBuffer();\n emitMultiClass(top.endScope, match);\n } else if (origin.skip) {\n modeBuffer += lexeme;\n } else {\n if (!(origin.returnEnd || origin.excludeEnd)) {\n modeBuffer += lexeme;\n }\n processBuffer();\n if (origin.excludeEnd) {\n modeBuffer = lexeme;\n }\n }\n do {\n if (top.scope) {\n emitter.closeNode();\n }\n if (!top.skip && !top.subLanguage) {\n relevance += top.relevance;\n }\n top = top.parent;\n } while (top !== endMode.parent);\n if (endMode.starts) {\n startNewMode(endMode.starts, match);\n }\n return origin.returnEnd ? 0 : lexeme.length;\n }\n\n function processContinuations() {\n const list = [];\n for (let current = top; current !== language; current = current.parent) {\n if (current.scope) {\n list.unshift(current.scope);\n }\n }\n list.forEach(item => emitter.openNode(item));\n }\n\n /** @type {{type?: MatchType, index?: number, rule?: Mode}}} */\n let lastMatch = {};\n\n /**\n * Process an individual match\n *\n * @param {string} textBeforeMatch - text preceding the match (since the last match)\n * @param {EnhancedMatch} [match] - the match itself\n */\n function processLexeme(textBeforeMatch, match) {\n const lexeme = match && match[0];\n\n // add non-matched text to the current mode buffer\n modeBuffer += textBeforeMatch;\n\n if (lexeme == null) {\n processBuffer();\n return 0;\n }\n\n // we've found a 0 width match and we're stuck, so we need to advance\n // this happens when we have badly behaved rules that have optional matchers to the degree that\n // sometimes they can end up matching nothing at all\n // Ref: https://github.com/highlightjs/highlight.js/issues/2140\n if (lastMatch.type === \"begin\" && match.type === \"end\" && lastMatch.index === match.index && lexeme === \"\") {\n // spit the \"skipped\" character that our regex choked on back into the output sequence\n modeBuffer += codeToHighlight.slice(match.index, match.index + 1);\n if (!SAFE_MODE) {\n /** @type {AnnotatedError} */\n const err = new Error(`0 width match regex (${languageName})`);\n err.languageName = languageName;\n err.badRule = lastMatch.rule;\n throw err;\n }\n return 1;\n }\n lastMatch = match;\n\n if (match.type === \"begin\") {\n return doBeginMatch(match);\n } else if (match.type === \"illegal\" && !ignoreIllegals) {\n // illegal match, we do not continue processing\n /** @type {AnnotatedError} */\n const err = new Error('Illegal lexeme \"' + lexeme + '\" for mode \"' + (top.scope || '') + '\"');\n err.mode = top;\n throw err;\n } else if (match.type === \"end\") {\n const processed = doEndMatch(match);\n if (processed !== NO_MATCH) {\n return processed;\n }\n }\n\n // edge case for when illegal matches $ (end of line) which is technically\n // a 0 width match but not a begin/end match so it's not caught by the\n // first handler (when ignoreIllegals is true)\n if (match.type === \"illegal\" && lexeme === \"\") {\n // advance so we aren't stuck in an infinite loop\n return 1;\n }\n\n // infinite loops are BAD, this is a last ditch catch all. if we have a\n // decent number of iterations yet our index (cursor position in our\n // parsing) still 3x behind our index then something is very wrong\n // so we bail\n if (iterations > 100000 && iterations > match.index * 3) {\n const err = new Error('potential infinite loop, way more iterations than matches');\n throw err;\n }\n\n /*\n Why might be find ourselves here? An potential end match that was\n triggered but could not be completed. IE, `doEndMatch` returned NO_MATCH.\n (this could be because a callback requests the match be ignored, etc)\n\n This causes no real harm other than stopping a few times too many.\n */\n\n modeBuffer += lexeme;\n return lexeme.length;\n }\n\n const language = getLanguage(languageName);\n if (!language) {\n error(LANGUAGE_NOT_FOUND.replace(\"{}\", languageName));\n throw new Error('Unknown language: \"' + languageName + '\"');\n }\n\n const md = compileLanguage(language);\n let result = '';\n /** @type {CompiledMode} */\n let top = continuation || md;\n /** @type Record */\n const continuations = {}; // keep continuations for sub-languages\n const emitter = new options.__emitter(options);\n processContinuations();\n let modeBuffer = '';\n let relevance = 0;\n let index = 0;\n let iterations = 0;\n let resumeScanAtSamePosition = false;\n\n try {\n if (!language.__emitTokens) {\n top.matcher.considerAll();\n\n for (;;) {\n iterations++;\n if (resumeScanAtSamePosition) {\n // only regexes not matched previously will now be\n // considered for a potential match\n resumeScanAtSamePosition = false;\n } else {\n top.matcher.considerAll();\n }\n top.matcher.lastIndex = index;\n\n const match = top.matcher.exec(codeToHighlight);\n // console.log(\"match\", match[0], match.rule && match.rule.begin)\n\n if (!match) break;\n\n const beforeMatch = codeToHighlight.substring(index, match.index);\n const processedCount = processLexeme(beforeMatch, match);\n index = match.index + processedCount;\n }\n processLexeme(codeToHighlight.substring(index));\n } else {\n language.__emitTokens(codeToHighlight, emitter);\n }\n\n emitter.finalize();\n result = emitter.toHTML();\n\n return {\n language: languageName,\n value: result,\n relevance,\n illegal: false,\n _emitter: emitter,\n _top: top\n };\n } catch (err) {\n if (err.message && err.message.includes('Illegal')) {\n return {\n language: languageName,\n value: escape(codeToHighlight),\n illegal: true,\n relevance: 0,\n _illegalBy: {\n message: err.message,\n index,\n context: codeToHighlight.slice(index - 100, index + 100),\n mode: err.mode,\n resultSoFar: result\n },\n _emitter: emitter\n };\n } else if (SAFE_MODE) {\n return {\n language: languageName,\n value: escape(codeToHighlight),\n illegal: false,\n relevance: 0,\n errorRaised: err,\n _emitter: emitter,\n _top: top\n };\n } else {\n throw err;\n }\n }\n }\n\n /**\n * returns a valid highlight result, without actually doing any actual work,\n * auto highlight starts with this and it's possible for small snippets that\n * auto-detection may not find a better match\n * @param {string} code\n * @returns {HighlightResult}\n */\n function justTextHighlightResult(code) {\n const result = {\n value: escape(code),\n illegal: false,\n relevance: 0,\n _top: PLAINTEXT_LANGUAGE,\n _emitter: new options.__emitter(options)\n };\n result._emitter.addText(code);\n return result;\n }\n\n /**\n Highlighting with language detection. Accepts a string with the code to\n highlight. Returns an object with the following properties:\n\n - language (detected language)\n - relevance (int)\n - value (an HTML string with highlighting markup)\n - secondBest (object with the same structure for second-best heuristically\n detected language, may be absent)\n\n @param {string} code\n @param {Array} [languageSubset]\n @returns {AutoHighlightResult}\n */\n function highlightAuto(code, languageSubset) {\n languageSubset = languageSubset || options.languages || Object.keys(languages);\n const plaintext = justTextHighlightResult(code);\n\n const results = languageSubset.filter(getLanguage).filter(autoDetection).map(name =>\n _highlight(name, code, false)\n );\n results.unshift(plaintext); // plaintext is always an option\n\n const sorted = results.sort((a, b) => {\n // sort base on relevance\n if (a.relevance !== b.relevance) return b.relevance - a.relevance;\n\n // always award the tie to the base language\n // ie if C++ and Arduino are tied, it's more likely to be C++\n if (a.language && b.language) {\n if (getLanguage(a.language).supersetOf === b.language) {\n return 1;\n } else if (getLanguage(b.language).supersetOf === a.language) {\n return -1;\n }\n }\n\n // otherwise say they are equal, which has the effect of sorting on\n // relevance while preserving the original ordering - which is how ties\n // have historically been settled, ie the language that comes first always\n // wins in the case of a tie\n return 0;\n });\n\n const [best, secondBest] = sorted;\n\n /** @type {AutoHighlightResult} */\n const result = best;\n result.secondBest = secondBest;\n\n return result;\n }\n\n /**\n * Builds new class name for block given the language name\n *\n * @param {HTMLElement} element\n * @param {string} [currentLang]\n * @param {string} [resultLang]\n */\n function updateClassName(element, currentLang, resultLang) {\n const language = (currentLang && aliases[currentLang]) || resultLang;\n\n element.classList.add(\"hljs\");\n element.classList.add(`language-${language}`);\n }\n\n /**\n * Applies highlighting to a DOM node containing code.\n *\n * @param {HighlightedHTMLElement} element - the HTML element to highlight\n */\n function highlightElement(element) {\n /** @type HTMLElement */\n let node = null;\n const language = blockLanguage(element);\n\n if (shouldNotHighlight(language)) return;\n\n fire(\"before:highlightElement\",\n { el: element, language });\n\n if (element.dataset.highlighted) {\n console.log(\"Element previously highlighted. To highlight again, first unset `dataset.highlighted`.\", element);\n return;\n }\n\n // we should be all text, no child nodes (unescaped HTML) - this is possibly\n // an HTML injection attack - it's likely too late if this is already in\n // production (the code has likely already done its damage by the time\n // we're seeing it)... but we yell loudly about this so that hopefully it's\n // more likely to be caught in development before making it to production\n if (element.children.length > 0) {\n if (!options.ignoreUnescapedHTML) {\n console.warn(\"One of your code blocks includes unescaped HTML. This is a potentially serious security risk.\");\n console.warn(\"https://github.com/highlightjs/highlight.js/wiki/security\");\n console.warn(\"The element with unescaped HTML:\");\n console.warn(element);\n }\n if (options.throwUnescapedHTML) {\n const err = new HTMLInjectionError(\n \"One of your code blocks includes unescaped HTML.\",\n element.innerHTML\n );\n throw err;\n }\n }\n\n node = element;\n const text = node.textContent;\n const result = language ? highlight(text, { language, ignoreIllegals: true }) : highlightAuto(text);\n\n element.innerHTML = result.value;\n element.dataset.highlighted = \"yes\";\n updateClassName(element, language, result.language);\n element.result = {\n language: result.language,\n // TODO: remove with version 11.0\n re: result.relevance,\n relevance: result.relevance\n };\n if (result.secondBest) {\n element.secondBest = {\n language: result.secondBest.language,\n relevance: result.secondBest.relevance\n };\n }\n\n fire(\"after:highlightElement\", { el: element, result, text });\n }\n\n /**\n * Updates highlight.js global options with the passed options\n *\n * @param {Partial} userOptions\n */\n function configure(userOptions) {\n options = inherit(options, userOptions);\n }\n\n // TODO: remove v12, deprecated\n const initHighlighting = () => {\n highlightAll();\n deprecated(\"10.6.0\", \"initHighlighting() deprecated. Use highlightAll() now.\");\n };\n\n // TODO: remove v12, deprecated\n function initHighlightingOnLoad() {\n highlightAll();\n deprecated(\"10.6.0\", \"initHighlightingOnLoad() deprecated. Use highlightAll() now.\");\n }\n\n let wantsHighlight = false;\n\n /**\n * auto-highlights all pre>code elements on the page\n */\n function highlightAll() {\n // if we are called too early in the loading process\n if (document.readyState === \"loading\") {\n wantsHighlight = true;\n return;\n }\n\n const blocks = document.querySelectorAll(options.cssSelector);\n blocks.forEach(highlightElement);\n }\n\n function boot() {\n // if a highlight was requested before DOM was loaded, do now\n if (wantsHighlight) highlightAll();\n }\n\n // make sure we are in the browser environment\n if (typeof window !== 'undefined' && window.addEventListener) {\n window.addEventListener('DOMContentLoaded', boot, false);\n }\n\n /**\n * Register a language grammar module\n *\n * @param {string} languageName\n * @param {LanguageFn} languageDefinition\n */\n function registerLanguage(languageName, languageDefinition) {\n let lang = null;\n try {\n lang = languageDefinition(hljs);\n } catch (error$1) {\n error(\"Language definition for '{}' could not be registered.\".replace(\"{}\", languageName));\n // hard or soft error\n if (!SAFE_MODE) { throw error$1; } else { error(error$1); }\n // languages that have serious errors are replaced with essentially a\n // \"plaintext\" stand-in so that the code blocks will still get normal\n // css classes applied to them - and one bad language won't break the\n // entire highlighter\n lang = PLAINTEXT_LANGUAGE;\n }\n // give it a temporary name if it doesn't have one in the meta-data\n if (!lang.name) lang.name = languageName;\n languages[languageName] = lang;\n lang.rawDefinition = languageDefinition.bind(null, hljs);\n\n if (lang.aliases) {\n registerAliases(lang.aliases, { languageName });\n }\n }\n\n /**\n * Remove a language grammar module\n *\n * @param {string} languageName\n */\n function unregisterLanguage(languageName) {\n delete languages[languageName];\n for (const alias of Object.keys(aliases)) {\n if (aliases[alias] === languageName) {\n delete aliases[alias];\n }\n }\n }\n\n /**\n * @returns {string[]} List of language internal names\n */\n function listLanguages() {\n return Object.keys(languages);\n }\n\n /**\n * @param {string} name - name of the language to retrieve\n * @returns {Language | undefined}\n */\n function getLanguage(name) {\n name = (name || '').toLowerCase();\n return languages[name] || languages[aliases[name]];\n }\n\n /**\n *\n * @param {string|string[]} aliasList - single alias or list of aliases\n * @param {{languageName: string}} opts\n */\n function registerAliases(aliasList, { languageName }) {\n if (typeof aliasList === 'string') {\n aliasList = [aliasList];\n }\n aliasList.forEach(alias => { aliases[alias.toLowerCase()] = languageName; });\n }\n\n /**\n * Determines if a given language has auto-detection enabled\n * @param {string} name - name of the language\n */\n function autoDetection(name) {\n const lang = getLanguage(name);\n return lang && !lang.disableAutodetect;\n }\n\n /**\n * Upgrades the old highlightBlock plugins to the new\n * highlightElement API\n * @param {HLJSPlugin} plugin\n */\n function upgradePluginAPI(plugin) {\n // TODO: remove with v12\n if (plugin[\"before:highlightBlock\"] && !plugin[\"before:highlightElement\"]) {\n plugin[\"before:highlightElement\"] = (data) => {\n plugin[\"before:highlightBlock\"](\n Object.assign({ block: data.el }, data)\n );\n };\n }\n if (plugin[\"after:highlightBlock\"] && !plugin[\"after:highlightElement\"]) {\n plugin[\"after:highlightElement\"] = (data) => {\n plugin[\"after:highlightBlock\"](\n Object.assign({ block: data.el }, data)\n );\n };\n }\n }\n\n /**\n * @param {HLJSPlugin} plugin\n */\n function addPlugin(plugin) {\n upgradePluginAPI(plugin);\n plugins.push(plugin);\n }\n\n /**\n * @param {HLJSPlugin} plugin\n */\n function removePlugin(plugin) {\n const index = plugins.indexOf(plugin);\n if (index !== -1) {\n plugins.splice(index, 1);\n }\n }\n\n /**\n *\n * @param {PluginEvent} event\n * @param {any} args\n */\n function fire(event, args) {\n const cb = event;\n plugins.forEach(function(plugin) {\n if (plugin[cb]) {\n plugin[cb](args);\n }\n });\n }\n\n /**\n * DEPRECATED\n * @param {HighlightedHTMLElement} el\n */\n function deprecateHighlightBlock(el) {\n deprecated(\"10.7.0\", \"highlightBlock will be removed entirely in v12.0\");\n deprecated(\"10.7.0\", \"Please use highlightElement now.\");\n\n return highlightElement(el);\n }\n\n /* Interface definition */\n Object.assign(hljs, {\n highlight,\n highlightAuto,\n highlightAll,\n highlightElement,\n // TODO: Remove with v12 API\n highlightBlock: deprecateHighlightBlock,\n configure,\n initHighlighting,\n initHighlightingOnLoad,\n registerLanguage,\n unregisterLanguage,\n listLanguages,\n getLanguage,\n registerAliases,\n autoDetection,\n inherit,\n addPlugin,\n removePlugin\n });\n\n hljs.debugMode = function() { SAFE_MODE = false; };\n hljs.safeMode = function() { SAFE_MODE = true; };\n hljs.versionString = version;\n\n hljs.regex = {\n concat: concat,\n lookahead: lookahead,\n either: either,\n optional: optional,\n anyNumberOfTimes: anyNumberOfTimes\n };\n\n for (const key in MODES) {\n // @ts-ignore\n if (typeof MODES[key] === \"object\") {\n // @ts-ignore\n deepFreeze(MODES[key]);\n }\n }\n\n // merge all the modes/regexes into our main object\n Object.assign(hljs, MODES);\n\n return hljs;\n};\n\n// Other names for the variable may break build script\nconst highlight = HLJS({});\n\n// returns a new instance of the highlighter to be used for extensions\n// check https://github.com/wooorm/lowlight/issues/47\nhighlight.newInstance = () => HLJS({});\n\nmodule.exports = highlight;\nhighlight.HighlightJS = highlight;\nhighlight.default = highlight;\n","const IDENT_RE = '[A-Za-z$_][0-9A-Za-z$_]*';\nconst KEYWORDS = [\n \"as\", // for exports\n \"in\",\n \"of\",\n \"if\",\n \"for\",\n \"while\",\n \"finally\",\n \"var\",\n \"new\",\n \"function\",\n \"do\",\n \"return\",\n \"void\",\n \"else\",\n \"break\",\n \"catch\",\n \"instanceof\",\n \"with\",\n \"throw\",\n \"case\",\n \"default\",\n \"try\",\n \"switch\",\n \"continue\",\n \"typeof\",\n \"delete\",\n \"let\",\n \"yield\",\n \"const\",\n \"class\",\n // JS handles these with a special rule\n // \"get\",\n // \"set\",\n \"debugger\",\n \"async\",\n \"await\",\n \"static\",\n \"import\",\n \"from\",\n \"export\",\n \"extends\"\n];\nconst LITERALS = [\n \"true\",\n \"false\",\n \"null\",\n \"undefined\",\n \"NaN\",\n \"Infinity\"\n];\n\n// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects\nconst TYPES = [\n // Fundamental objects\n \"Object\",\n \"Function\",\n \"Boolean\",\n \"Symbol\",\n // numbers and dates\n \"Math\",\n \"Date\",\n \"Number\",\n \"BigInt\",\n // text\n \"String\",\n \"RegExp\",\n // Indexed collections\n \"Array\",\n \"Float32Array\",\n \"Float64Array\",\n \"Int8Array\",\n \"Uint8Array\",\n \"Uint8ClampedArray\",\n \"Int16Array\",\n \"Int32Array\",\n \"Uint16Array\",\n \"Uint32Array\",\n \"BigInt64Array\",\n \"BigUint64Array\",\n // Keyed collections\n \"Set\",\n \"Map\",\n \"WeakSet\",\n \"WeakMap\",\n // Structured data\n \"ArrayBuffer\",\n \"SharedArrayBuffer\",\n \"Atomics\",\n \"DataView\",\n \"JSON\",\n // Control abstraction objects\n \"Promise\",\n \"Generator\",\n \"GeneratorFunction\",\n \"AsyncFunction\",\n // Reflection\n \"Reflect\",\n \"Proxy\",\n // Internationalization\n \"Intl\",\n // WebAssembly\n \"WebAssembly\"\n];\n\nconst ERROR_TYPES = [\n \"Error\",\n \"EvalError\",\n \"InternalError\",\n \"RangeError\",\n \"ReferenceError\",\n \"SyntaxError\",\n \"TypeError\",\n \"URIError\"\n];\n\nconst BUILT_IN_GLOBALS = [\n \"setInterval\",\n \"setTimeout\",\n \"clearInterval\",\n \"clearTimeout\",\n\n \"require\",\n \"exports\",\n\n \"eval\",\n \"isFinite\",\n \"isNaN\",\n \"parseFloat\",\n \"parseInt\",\n \"decodeURI\",\n \"decodeURIComponent\",\n \"encodeURI\",\n \"encodeURIComponent\",\n \"escape\",\n \"unescape\"\n];\n\nconst BUILT_IN_VARIABLES = [\n \"arguments\",\n \"this\",\n \"super\",\n \"console\",\n \"window\",\n \"document\",\n \"localStorage\",\n \"sessionStorage\",\n \"module\",\n \"global\" // Node.js\n];\n\nconst BUILT_INS = [].concat(\n BUILT_IN_GLOBALS,\n TYPES,\n ERROR_TYPES\n);\n\n/*\nLanguage: JavaScript\nDescription: JavaScript (JS) is a lightweight, interpreted, or just-in-time compiled programming language with first-class functions.\nCategory: common, scripting, web\nWebsite: https://developer.mozilla.org/en-US/docs/Web/JavaScript\n*/\n\n\n/** @type LanguageFn */\nfunction javascript(hljs) {\n const regex = hljs.regex;\n /**\n * Takes a string like \" {\n const tag = \"',\n end: ''\n };\n // to avoid some special cases inside isTrulyOpeningTag\n const XML_SELF_CLOSING = /<[A-Za-z0-9\\\\._:-]+\\s*\\/>/;\n const XML_TAG = {\n begin: /<[A-Za-z0-9\\\\._:-]+/,\n end: /\\/[A-Za-z0-9\\\\._:-]+>|\\/>/,\n /**\n * @param {RegExpMatchArray} match\n * @param {CallbackResponse} response\n */\n isTrulyOpeningTag: (match, response) => {\n const afterMatchIndex = match[0].length + match.index;\n const nextChar = match.input[afterMatchIndex];\n if (\n // HTML should not include another raw `<` inside a tag\n // nested type?\n // `>`, etc.\n nextChar === \"<\" ||\n // the , gives away that this is not HTML\n // ``\n nextChar === \",\"\n ) {\n response.ignoreMatch();\n return;\n }\n\n // ``\n // Quite possibly a tag, lets look for a matching closing tag...\n if (nextChar === \">\") {\n // if we cannot find a matching closing tag, then we\n // will ignore it\n if (!hasClosingTag(match, { after: afterMatchIndex })) {\n response.ignoreMatch();\n }\n }\n\n // `` (self-closing)\n // handled by simpleSelfClosing rule\n\n let m;\n const afterMatch = match.input.substring(afterMatchIndex);\n\n // some more template typing stuff\n // (key?: string) => Modify<\n if ((m = afterMatch.match(/^\\s*=/))) {\n response.ignoreMatch();\n return;\n }\n\n // ``\n // technically this could be HTML, but it smells like a type\n // NOTE: This is ugh, but added specifically for https://github.com/highlightjs/highlight.js/issues/3276\n if ((m = afterMatch.match(/^\\s+extends\\s+/))) {\n if (m.index === 0) {\n response.ignoreMatch();\n // eslint-disable-next-line no-useless-return\n return;\n }\n }\n }\n };\n const KEYWORDS$1 = {\n $pattern: IDENT_RE,\n keyword: KEYWORDS,\n literal: LITERALS,\n built_in: BUILT_INS,\n \"variable.language\": BUILT_IN_VARIABLES\n };\n\n // https://tc39.es/ecma262/#sec-literals-numeric-literals\n const decimalDigits = '[0-9](_?[0-9])*';\n const frac = `\\\\.(${decimalDigits})`;\n // DecimalIntegerLiteral, including Annex B NonOctalDecimalIntegerLiteral\n // https://tc39.es/ecma262/#sec-additional-syntax-numeric-literals\n const decimalInteger = `0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*`;\n const NUMBER = {\n className: 'number',\n variants: [\n // DecimalLiteral\n { begin: `(\\\\b(${decimalInteger})((${frac})|\\\\.)?|(${frac}))` +\n `[eE][+-]?(${decimalDigits})\\\\b` },\n { begin: `\\\\b(${decimalInteger})\\\\b((${frac})\\\\b|\\\\.)?|(${frac})\\\\b` },\n\n // DecimalBigIntegerLiteral\n { begin: `\\\\b(0|[1-9](_?[0-9])*)n\\\\b` },\n\n // NonDecimalIntegerLiteral\n { begin: \"\\\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\\\b\" },\n { begin: \"\\\\b0[bB][0-1](_?[0-1])*n?\\\\b\" },\n { begin: \"\\\\b0[oO][0-7](_?[0-7])*n?\\\\b\" },\n\n // LegacyOctalIntegerLiteral (does not include underscore separators)\n // https://tc39.es/ecma262/#sec-additional-syntax-numeric-literals\n { begin: \"\\\\b0[0-7]+n?\\\\b\" },\n ],\n relevance: 0\n };\n\n const SUBST = {\n className: 'subst',\n begin: '\\\\$\\\\{',\n end: '\\\\}',\n keywords: KEYWORDS$1,\n contains: [] // defined later\n };\n const HTML_TEMPLATE = {\n begin: '\\.?html`',\n end: '',\n starts: {\n end: '`',\n returnEnd: false,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ],\n subLanguage: 'xml'\n }\n };\n const CSS_TEMPLATE = {\n begin: '\\.?css`',\n end: '',\n starts: {\n end: '`',\n returnEnd: false,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ],\n subLanguage: 'css'\n }\n };\n const GRAPHQL_TEMPLATE = {\n begin: '\\.?gql`',\n end: '',\n starts: {\n end: '`',\n returnEnd: false,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ],\n subLanguage: 'graphql'\n }\n };\n const TEMPLATE_STRING = {\n className: 'string',\n begin: '`',\n end: '`',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ]\n };\n const JSDOC_COMMENT = hljs.COMMENT(\n /\\/\\*\\*(?!\\/)/,\n '\\\\*/',\n {\n relevance: 0,\n contains: [\n {\n begin: '(?=@[A-Za-z]+)',\n relevance: 0,\n contains: [\n {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n },\n {\n className: 'type',\n begin: '\\\\{',\n end: '\\\\}',\n excludeEnd: true,\n excludeBegin: true,\n relevance: 0\n },\n {\n className: 'variable',\n begin: IDENT_RE$1 + '(?=\\\\s*(-)|$)',\n endsParent: true,\n relevance: 0\n },\n // eat spaces (not newlines) so we can find\n // types or variables\n {\n begin: /(?=[^\\n])\\s/,\n relevance: 0\n }\n ]\n }\n ]\n }\n );\n const COMMENT = {\n className: \"comment\",\n variants: [\n JSDOC_COMMENT,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.C_LINE_COMMENT_MODE\n ]\n };\n const SUBST_INTERNALS = [\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n HTML_TEMPLATE,\n CSS_TEMPLATE,\n GRAPHQL_TEMPLATE,\n TEMPLATE_STRING,\n // Skip numbers when they are part of a variable name\n { match: /\\$\\d+/ },\n NUMBER,\n // This is intentional:\n // See https://github.com/highlightjs/highlight.js/issues/3288\n // hljs.REGEXP_MODE\n ];\n SUBST.contains = SUBST_INTERNALS\n .concat({\n // we need to pair up {} inside our subst to prevent\n // it from ending too early by matching another }\n begin: /\\{/,\n end: /\\}/,\n keywords: KEYWORDS$1,\n contains: [\n \"self\"\n ].concat(SUBST_INTERNALS)\n });\n const SUBST_AND_COMMENTS = [].concat(COMMENT, SUBST.contains);\n const PARAMS_CONTAINS = SUBST_AND_COMMENTS.concat([\n // eat recursive parens in sub expressions\n {\n begin: /(\\s*)\\(/,\n end: /\\)/,\n keywords: KEYWORDS$1,\n contains: [\"self\"].concat(SUBST_AND_COMMENTS)\n }\n ]);\n const PARAMS = {\n className: 'params',\n // convert this to negative lookbehind in v12\n begin: /(\\s*)\\(/, // to match the parms with \n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS$1,\n contains: PARAMS_CONTAINS\n };\n\n // ES6 classes\n const CLASS_OR_EXTENDS = {\n variants: [\n // class Car extends vehicle\n {\n match: [\n /class/,\n /\\s+/,\n IDENT_RE$1,\n /\\s+/,\n /extends/,\n /\\s+/,\n regex.concat(IDENT_RE$1, \"(\", regex.concat(/\\./, IDENT_RE$1), \")*\")\n ],\n scope: {\n 1: \"keyword\",\n 3: \"title.class\",\n 5: \"keyword\",\n 7: \"title.class.inherited\"\n }\n },\n // class Car\n {\n match: [\n /class/,\n /\\s+/,\n IDENT_RE$1\n ],\n scope: {\n 1: \"keyword\",\n 3: \"title.class\"\n }\n },\n\n ]\n };\n\n const CLASS_REFERENCE = {\n relevance: 0,\n match:\n regex.either(\n // Hard coded exceptions\n /\\bJSON/,\n // Float32Array, OutT\n /\\b[A-Z][a-z]+([A-Z][a-z]*|\\d)*/,\n // CSSFactory, CSSFactoryT\n /\\b[A-Z]{2,}([A-Z][a-z]+|\\d)+([A-Z][a-z]*)*/,\n // FPs, FPsT\n /\\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\\d)*([A-Z][a-z]*)*/,\n // P\n // single letters are not highlighted\n // BLAH\n // this will be flagged as a UPPER_CASE_CONSTANT instead\n ),\n className: \"title.class\",\n keywords: {\n _: [\n // se we still get relevance credit for JS library classes\n ...TYPES,\n ...ERROR_TYPES\n ]\n }\n };\n\n const USE_STRICT = {\n label: \"use_strict\",\n className: 'meta',\n relevance: 10,\n begin: /^\\s*['\"]use (strict|asm)['\"]/\n };\n\n const FUNCTION_DEFINITION = {\n variants: [\n {\n match: [\n /function/,\n /\\s+/,\n IDENT_RE$1,\n /(?=\\s*\\()/\n ]\n },\n // anonymous function\n {\n match: [\n /function/,\n /\\s*(?=\\()/\n ]\n }\n ],\n className: {\n 1: \"keyword\",\n 3: \"title.function\"\n },\n label: \"func.def\",\n contains: [ PARAMS ],\n illegal: /%/\n };\n\n const UPPER_CASE_CONSTANT = {\n relevance: 0,\n match: /\\b[A-Z][A-Z_0-9]+\\b/,\n className: \"variable.constant\"\n };\n\n function noneOf(list) {\n return regex.concat(\"(?!\", list.join(\"|\"), \")\");\n }\n\n const FUNCTION_CALL = {\n match: regex.concat(\n /\\b/,\n noneOf([\n ...BUILT_IN_GLOBALS,\n \"super\",\n \"import\"\n ].map(x => `${x}\\\\s*\\\\(`)),\n IDENT_RE$1, regex.lookahead(/\\s*\\(/)),\n className: \"title.function\",\n relevance: 0\n };\n\n const PROPERTY_ACCESS = {\n begin: regex.concat(/\\./, regex.lookahead(\n regex.concat(IDENT_RE$1, /(?![0-9A-Za-z$_(])/)\n )),\n end: IDENT_RE$1,\n excludeBegin: true,\n keywords: \"prototype\",\n className: \"property\",\n relevance: 0\n };\n\n const GETTER_OR_SETTER = {\n match: [\n /get|set/,\n /\\s+/,\n IDENT_RE$1,\n /(?=\\()/\n ],\n className: {\n 1: \"keyword\",\n 3: \"title.function\"\n },\n contains: [\n { // eat to avoid empty params\n begin: /\\(\\)/\n },\n PARAMS\n ]\n };\n\n const FUNC_LEAD_IN_RE = '(\\\\(' +\n '[^()]*(\\\\(' +\n '[^()]*(\\\\(' +\n '[^()]*' +\n '\\\\)[^()]*)*' +\n '\\\\)[^()]*)*' +\n '\\\\)|' + hljs.UNDERSCORE_IDENT_RE + ')\\\\s*=>';\n\n const FUNCTION_VARIABLE = {\n match: [\n /const|var|let/, /\\s+/,\n IDENT_RE$1, /\\s*/,\n /=\\s*/,\n /(async\\s*)?/, // async is optional\n regex.lookahead(FUNC_LEAD_IN_RE)\n ],\n keywords: \"async\",\n className: {\n 1: \"keyword\",\n 3: \"title.function\"\n },\n contains: [\n PARAMS\n ]\n };\n\n return {\n name: 'JavaScript',\n aliases: ['js', 'jsx', 'mjs', 'cjs'],\n keywords: KEYWORDS$1,\n // this will be extended by TypeScript\n exports: { PARAMS_CONTAINS, CLASS_REFERENCE },\n illegal: /#(?![$_A-z])/,\n contains: [\n hljs.SHEBANG({\n label: \"shebang\",\n binary: \"node\",\n relevance: 5\n }),\n USE_STRICT,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n HTML_TEMPLATE,\n CSS_TEMPLATE,\n GRAPHQL_TEMPLATE,\n TEMPLATE_STRING,\n COMMENT,\n // Skip numbers when they are part of a variable name\n { match: /\\$\\d+/ },\n NUMBER,\n CLASS_REFERENCE,\n {\n className: 'attr',\n begin: IDENT_RE$1 + regex.lookahead(':'),\n relevance: 0\n },\n FUNCTION_VARIABLE,\n { // \"value\" container\n begin: '(' + hljs.RE_STARTERS_RE + '|\\\\b(case|return|throw)\\\\b)\\\\s*',\n keywords: 'return throw case',\n relevance: 0,\n contains: [\n COMMENT,\n hljs.REGEXP_MODE,\n {\n className: 'function',\n // we have to count the parens to make sure we actually have the\n // correct bounding ( ) before the =>. There could be any number of\n // sub-expressions inside also surrounded by parens.\n begin: FUNC_LEAD_IN_RE,\n returnBegin: true,\n end: '\\\\s*=>',\n contains: [\n {\n className: 'params',\n variants: [\n {\n begin: hljs.UNDERSCORE_IDENT_RE,\n relevance: 0\n },\n {\n className: null,\n begin: /\\(\\s*\\)/,\n skip: true\n },\n {\n begin: /(\\s*)\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS$1,\n contains: PARAMS_CONTAINS\n }\n ]\n }\n ]\n },\n { // could be a comma delimited list of params to a function call\n begin: /,/,\n relevance: 0\n },\n {\n match: /\\s+/,\n relevance: 0\n },\n { // JSX\n variants: [\n { begin: FRAGMENT.begin, end: FRAGMENT.end },\n { match: XML_SELF_CLOSING },\n {\n begin: XML_TAG.begin,\n // we carefully check the opening tag to see if it truly\n // is a tag and not a false positive\n 'on:begin': XML_TAG.isTrulyOpeningTag,\n end: XML_TAG.end\n }\n ],\n subLanguage: 'xml',\n contains: [\n {\n begin: XML_TAG.begin,\n end: XML_TAG.end,\n skip: true,\n contains: ['self']\n }\n ]\n }\n ],\n },\n FUNCTION_DEFINITION,\n {\n // prevent this from getting swallowed up by function\n // since they appear \"function like\"\n beginKeywords: \"while if switch catch for\"\n },\n {\n // we have to count the parens to make sure we actually have the correct\n // bounding ( ). There could be any number of sub-expressions inside\n // also surrounded by parens.\n begin: '\\\\b(?!function)' + hljs.UNDERSCORE_IDENT_RE +\n '\\\\(' + // first parens\n '[^()]*(\\\\(' +\n '[^()]*(\\\\(' +\n '[^()]*' +\n '\\\\)[^()]*)*' +\n '\\\\)[^()]*)*' +\n '\\\\)\\\\s*\\\\{', // end parens\n returnBegin:true,\n label: \"func.def\",\n contains: [\n PARAMS,\n hljs.inherit(hljs.TITLE_MODE, { begin: IDENT_RE$1, className: \"title.function\" })\n ]\n },\n // catch ... so it won't trigger the property rule below\n {\n match: /\\.\\.\\./,\n relevance: 0\n },\n PROPERTY_ACCESS,\n // hack: prevents detection of keywords in some circumstances\n // .keyword()\n // $keyword = x\n {\n match: '\\\\$' + IDENT_RE$1,\n relevance: 0\n },\n {\n match: [ /\\bconstructor(?=\\s*\\()/ ],\n className: { 1: \"title.function\" },\n contains: [ PARAMS ]\n },\n FUNCTION_CALL,\n UPPER_CASE_CONSTANT,\n CLASS_OR_EXTENDS,\n GETTER_OR_SETTER,\n {\n match: /\\$[(.]/ // relevance booster for a pattern common to JS libs: `$(something)` and `$.something`\n }\n ]\n };\n}\n\nexport { javascript as default };\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport componentCss from './code-block.scss?inline';\nimport { unsafeHTML } from 'lit/directives/unsafe-html.js';\nimport hljs from 'highlight.js/lib/core';\nimport javascript from 'highlight.js/lib/languages/javascript';\n\nhljs.registerLanguage('javascript', javascript);\n\nexport class CodeBlock extends LitElement {\n static styles = [unsafeCSS(componentCss)];\n static properties = {\n language: { type: String },\n code: { tyoe: String, state: true }\n };\n\n constructor(props) {\n super(props);\n this.language = 'javascript';\n }\n\n #onCodeChanged() {\n const slottedElements = this.shadowRoot.querySelector('slot').assignedNodes();\n const codeStr = slottedElements[0].textContent;\n\n this.code = hljs.highlight(codeStr, { language: this.language }).value;\n }\n\n render() {\n return html`\n
${unsafeHTML(this.code)}
\n this.#onCodeChanged()}\">\n `;\n }\n}\n\ncustomElements.define('code-block', CodeBlock);\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport '../../../components/code-block/code-block';\nimport { animations, theme } from '../../../theme/theme';\nimport showcaseComponentCss from './showcase-component.scss?inline';\nimport { when } from 'lit/directives/when.js';\nimport { classMap } from 'lit/directives/class-map.js';\n\nexport class ShowcaseComponent extends LitElement {\n static styles = [theme, animations, unsafeCSS(showcaseComponentCss)];\n\n static properties = {\n collapsed: { type: Boolean },\n hasCodeExample: { type: Boolean, state: true },\n exampleLanguage: { type: String },\n href: { type: String }\n };\n\n connectedCallback() {\n super.connectedCallback();\n this.collapsed = true;\n this.shadowRoot.addEventListener('slotchange', () => {\n this.hasCodeExample = this.#hasSlot('code');\n });\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (_changedProperties.has('collapsed') && !this.collapsed) {\n this.shadowRoot.querySelector('[part=\"implementation\"]').classList.add('active');\n }\n }\n\n #hasSlot(name) {\n return this.shadowRoot.querySelector(`slot[name=\"${name}\"]`).assignedNodes().length > 0;\n }\n\n #implementationSectionAnimationEnd(e) {\n e.target.classList.toggle('active', !e.target.classList.contains('fade-out-shrink'));\n e.target.classList.remove('fade-in-grow', 'fade-out-shrink');\n }\n\n #implementationSectionClassMap() {\n return {\n 'fade-in-grow': this.collapsed === false,\n 'fade-out-shrink': this.collapsed === true\n };\n }\n\n render() {\n return html`\n \n \n\n
\n

{\n this.collapsed = !this.collapsed;\n }}\">\n ${this.collapsed ? 'visibility' : 'visibility_off'}\n ${this.collapsed ? 'See the Implementation' : 'Hide the Implementation'} \n

\n
this.#implementationSectionAnimationEnd(e)}\">\n
\n \n
\n ${when(this.href, () => html`\n
\n \n view on github\n \n
\n `)}\n
\n
\n `;\n }\n}\n\ncustomElements.define('showcase-component', ShowcaseComponent);\n","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Start Time Showcase\\n \\n \\n\\n\\n\\n\\n
\\n

Start the player at a given position

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Multi Player Showcase\\n \\n \\n\\n\\n\\n\\n
\\n

Multiple players

\\n\\n
\\n \\n
\\n\\n \\n\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Detect blocked segment\\n \\n \\n\\n\\n\\n\\n
\\n

Detect blocked segment

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Display Current Chapter\\n \\n \\n\\n\\n\\n\\n
\\n

Display Current Chapter

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Skip Credits\\n \\n \\n\\n\\n\\n\\n
\\n

Skip Credits

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Playlist\\n \\n \\n\\n\\n\\n\\n
\\n

Playlist

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Quality Menu\\n \\n \\n\\n\\n\\n\\n
\\n

Quality Menu

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","/**\n * Aligns the lines of a block of code by removing leading spaces.\n *\n * This function calculates the number of leading spaces on the first line of the code,\n * then creates a regular expression that matches this number of leading spaces.\n * It finally replaces these leading spaces in each line of the code.\n *\n * @param {string} code - The block of code to align.\n * @returns {string} The aligned block of code.\n */\nfunction alignLines(code) {\n // Remove leading and trailing new lines.\n const normalizeCode = code.replace(/^[\\r\\n]+|[\\r\\n]+$/g, '');\n // Calculate the number of leading spaces on the first line\n const firstLine = normalizeCode.split('\\n')[0];\n const leadingSpaces = firstLine.match(/^ */)[0].length;\n // Create a regular expression that matches 'leadingSpaces' number of leading spaces\n const regex = new RegExp(`^ {${leadingSpaces}}`, 'gm');\n\n // Replace leading spaces in each line\n return normalizeCode.replace(regex, '');\n}\n\nconst parser = new DOMParser();\n\n/**\n * Parses an HTML string and returns the text content of the first element that matches the provided selector.\n *\n * @param {string} html - The HTML string to parse.\n * @param {string} [selector='[data-implementation]'] - The CSS selector to match elements. Defaults to '[data-example]'.\n * @returns {string} The text content of the first matching element. If no elements match the selector, it returns an empty string.\n *\n * @example\n * const html = '
Hello, world!
';\n * const content = parseHTML(html);\n * console.log(content); // Logs: 'Hello, world!'\n */\nexport function getTextFromHTML(html, selector = '[data-implementation]') {\n return alignLines(\n parser.parseFromString(html, 'text/html').querySelector(selector).textContent\n );\n}\n","import router from '../../../router/router';\nimport { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport './showcase-component.js';\nimport '../../../components/code-block/code-block';\nimport showcasePageCss from './showcase-page.scss?inline';\nimport rawStartTimeExample from '../../../../static/showcases/start-time.html?raw';\nimport rawMultiPlayerExample from '../../../../static/showcases/multi-player.html?raw';\nimport rawDetectBlockedSegmentsExample from '../../../../static/showcases/blocked-segment.html?raw';\nimport rawDisplayCurrentChapterExample from '../../../../static/showcases/chapters.html?raw';\nimport rawSkipCreditsExample from '../../../../static/showcases/skip-credits.html?raw';\nimport rawPlaylistExample from '../../../../static/showcases/playlist.html?raw';\nimport rawqualityMenuExample from '../../../../static/showcases/quality-menu.html?raw';\nimport { getTextFromHTML } from './example-parser.js';\n\nconst startTimeExampleTxt = getTextFromHTML(rawStartTimeExample);\nconst multiPlayerExampleTxt = getTextFromHTML(rawMultiPlayerExample);\nconst detectBlockedSegmentsExampleTxt =\n getTextFromHTML(rawDetectBlockedSegmentsExample);\nconst displayCurrentChapterExampleTxt =\n getTextFromHTML(rawDisplayCurrentChapterExample);\nconst skipCreditsExampleTxt = getTextFromHTML(rawSkipCreditsExample);\nconst playlistExampleTxt = getTextFromHTML(rawPlaylistExample);\nconst qualityMenuExampleTxt = getTextFromHTML(rawqualityMenuExample);\n\nexport class ShowCasePage extends LitElement {\n static styles = [theme, animations, unsafeCSS(showcasePageCss)];\n\n render() {\n return html`\n ${this.#renderStartTime()}\n ${this.#renderMultiplePlayers()}\n ${this.#renderDetectBlockedSegments()}\n ${this.#renderDisplayCurrentChapter()}\n ${this.#renderSkipCredits()}\n ${this.#renderPlaylist()}\n ${this.#renderQualityMenu()}\n `;\n }\n\n #renderStartTime() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Start the player at a given position

\n

\n In this showcase, we'll demonstrate how to load a video source and\n start playback at a specific position using Pillarbox. This can be\n useful when you want to provide users with the option to begin\n watching a video from a predefined timestamp. To achieve this\n functionality, follow the code snippet below:\n

\n ${startTimeExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderMultiplePlayers() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Multiple Players

\n

\n This example demonstrates how to incorporate multiple video players\n on a webpage.In this showcase, two players are initialized, each\n with its own configuration, a button allows to toggle the mute state\n for both players.\n

\n ${multiPlayerExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderDetectBlockedSegments() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Detect Blocked Segments

\n

\n This tutorial covers how to use pillarbox to create a plugin that\n detects and notifies when a blocked segment is skipped.\n

\n ${detectBlockedSegmentsExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderDisplayCurrentChapter() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Display Current Chapter

\n

\n This showcase explains how to use pillarbox to create a plugin that\n displays the currently playing chapter in a box above the progress\n bar.\n

\n ${displayCurrentChapterExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderSkipCredits() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Skip Credits

\n

\n This example shows how to use the\n Pillarbox Skip Button component\n to add a \"Skip\" button during detected credit intervals.\n

\n ${skipCreditsExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderPlaylist() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Playlist

\n

\n This example shows how to fetch media data for a set of video sources \n and load them into the Pillarbox Playlist plugin\n with metadata such as title and duration.\n

\n ${playlistExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderQualityMenu() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Quality Menu

\n

\n In this showcase, we'll demonstrate howto display a quality selector\n menu using the videojs-contrib-quality-menu\n plugin.\n

\n ${qualityMenuExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n}\n\ncustomElements.define('showcase-page', ShowCasePage);\nrouter.addRoute('showcase', 'showcase-page');\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport '../../router/route-link-component';\nimport { theme } from '../../theme/theme';\nimport headerCSS from './demo-header-component.scss?inline';\nimport router from '../../router/router';\nimport './core-demo-header-component.js';\n\n/**\n * A web component that represents the header of the demo page. This header contains\n * the {@link CoreDemoHeaderComponent} as well as the navigation menu of the\n * different demo app sections.\n *\n * @element demo-header\n *\n * @prop {Boolean} debug - Indicates whether the debug mode is enabled.\n *\n * @example\n * \n */\nexport class DemoHeaderElement extends LitElement {\n static properties = {\n debug: { type: Boolean, state: true }\n };\n\n static styles = [theme, unsafeCSS(headerCSS)];\n\n #onRouteUpdated = ({ detail: { queryParams } }) => {\n this.debug = queryParams.debug === 'true';\n };\n\n connectedCallback() {\n super.connectedCallback();\n\n this.debug = router.queryParams.debug === 'true';\n router.addEventListener('routechanged', this.#onRouteUpdated);\n router.addEventListener('queryparams', this.#onRouteUpdated);\n }\n\n disconnectedCallback() {\n router.removeEventListener('routechanged', this.#onRouteUpdated);\n router.removeEventListener('queryparams', this.#onRouteUpdated);\n }\n\n render() {\n return html`\n ${this.#renderHeaderElement()}\n ${this.#renderNavElement()}\n `;\n }\n\n #renderHeaderElement() {\n return html`\n \n \n settings\n \n \n `;\n }\n\n #renderNavElement() {\n return html`\n `;\n }\n}\n\ncustomElements.define('demo-header', DemoHeaderElement);\n","import router from './router';\nimport { LitElement } from 'lit';\nimport { unsafeHTML } from 'lit/directives/unsafe-html.js';\n\nexport class RouteOutletComponent extends LitElement {\n static properties = {\n route: { state: true }\n };\n\n constructor() {\n super();\n\n this.route = router.currentRoute;\n router.addEventListener('routechanged', ({ detail: { route } }) => {\n this.route?.destroy();\n this.route = route;\n });\n }\n\n render() {\n return unsafeHTML(`<${this.route.component}>`);\n }\n}\n\ncustomElements.define('route-outlet', RouteOutletComponent);\n","/**\n * Main module to import and initialize the demo as a single page application.\n *\n * @module\n */\nimport './components/dialog/demo-dialog-component';\nimport './components/player/player';\nimport './layout/content/examples/examples-page';\nimport './layout/content/lists/lists-page';\nimport './layout/content/search/search-page';\nimport './layout/content/settings/settings-page';\nimport './layout/content/showcase/showcase-page';\nimport './layout/header/demo-header-component.js';\nimport './router/route-outlet-component';\nimport router from './router/router';\nimport PreferencesProvider\n from './layout/content/settings/preferences-provider';\nimport ilProvider from './utils/il-provider.js';\n\n// Load preferences and initializes il host\nconst preferences = PreferencesProvider.loadPreferences();\n\nilProvider.host = preferences.dataProviderHost;\n\n// Initialize the router with the current path or 'examples' if none is found\nrouter.start({ defaultPath: 'examples' });\n\nif (router.queryParams.debug) {\n preferences.debug = router.queryParams.debug === 'true';\n PreferencesProvider.savePreferences(preferences);\n} else if (preferences.debug) {\n router.updateState({ debug: 'true' });\n}\n"],"names":["DemoDialog","LitElement","__privateAdd","_DemoDialog_instances","_dialog","_changedProperties","__privateGet","__privateSet","html","__privateMethod","onDialogClicked_fn","onDialogClosed_fn","__publicField","theme","animations","unsafeCSS","componentCSS","PreferencesProvider","preferences","IL_DEFAULT_HOST","DEFAULT_QUERY_PARAMS","DEFAULT_SEARCH_PARAMS","DEFAULT_SHOWLIST_PARAMS","toMedia","title","urn","mediaType","date","duration","ILProvider","host","_ILProvider_instances","_host","bu","query","signal","data","fetch_fn","toResults","nextProvider_fn","transmission","topicUrn","pageSize","showUrn","mediaList","id","channelId","path","params","queryParams","url","response","reason","nextUrl","resultMapper","nextData","ilProvider","DEMO_PLAYER_ID","DEFAULT_OPTIONS","preferencesToPlayerOptions","createPlayer","options","Pillarbox","destroyPlayer","playerDialog","toParams","keySystems","vendor","toKeySystem","certificateUri","licenseUri","asQueryParams","src","type","router","loadPlayerFromRouter","e","openPlayerModal","playerOptions","shouldUpdateRouter","player","s","i","t","r","_a","_b","LoadMediaFormComponent","_LoadMediaFormComponent_instances","initDrmSettings_fn","btnSettingsClassMap","handleLoadBarKeyUp_fn","classMap","drmSettingsTemplate_fn","submitMedia_fn","getSource_fn","keySystems_get","event","toKeySystem_fn","onFormAnimationEnd_fn","formAnimationClassMap_fn","ContentLinkComponent","_onClick","EXAMPLES","o","f","n","ExamplesPage","map","Examples","section","examples","example","when","css","SpinnerComponent","spinnerCss","DEFAULT_INT_OPTIONS","onIntersecting","target","callback","entries","entry","IntersectionObserverComponent","ScrollToTopComponent","toKebabCase","str","_ListsPageStateManager","root","_ListsPageStateManager_instances","nodes","sectionIndex","findSectionIndex_fn","nodeIndex","findNodeIndex_fn","processNodeString_fn","stackIndex","_ListsPageStateManager_static","params_fn","nodeStr","stack","rootSection","node","sectionStr","normalizedSectionStr","normalizedStr","ListsPageStateManager","Section","resolve","next","toNodesAndNext","listsSections","topic","show","channel","ListsPage","_ListsPage_instances","_abortController","_stateManager","_onQueryParamsChanged","updateState_fn","manager","renderScrollBtn","renderNavigation_fn","renderSpinner_fn","renderResults_fn","renderScrollToTopBtn_fn","toMediaButtonParams_fn","renderMediaButton_fn","toLevelParams_fn","sectionIdx","nodeIdx","renderLevelButton_fn","nextPage_fn","renderNodes_fn","firstSection","hasIntesectionObserver","idx","onSectionsClicked_fn","button","onNavigationClicked_fn","step","DEFAULT_BU","SearchBarComponent","_SearchBarComponent_instances","property","handleSelectChange_fn","handleSearchBarKeyUp_fn","clearSearchBar_fn","SearchPage","_SearchPage_instances","searchBar","search_fn","onSearchBarChanged_fn","fetchNextPage_fn","toQueryParams_fn","renderButton_fn","resultsClassMap","ToggleSwitchComponent","_onKeyDown","force","SettingsPage","_SettingsPage_instances","renderToggle_fn","renderInput_fn","label","componentCss","deepFreeze","obj","name","prop","Response","mode","escapeHTML","value","inherit$1","original","objects","result","key","SPAN_CLOSE","emitsWrappingTags","scopeToCSSClass","prefix","pieces","x","HTMLRenderer","parseTree","text","className","newNode","opts","TokenTree","scope","builder","child","el","TokenTreeEmitter","emitter","source","re","lookahead","concat","anyNumberOfTimes","optional","args","stripOptionsFromArgs","either","countMatchGroups","startsWith","lexeme","match","BACKREF_RE","_rewriteBackreferences","regexps","joinWith","numCaptures","regex","offset","out","MATCH_NOTHING_RE","IDENT_RE","UNDERSCORE_IDENT_RE","NUMBER_RE","C_NUMBER_RE","BINARY_NUMBER_RE","RE_STARTERS_RE","SHEBANG","beginShebang","m","resp","BACKSLASH_ESCAPE","APOS_STRING_MODE","QUOTE_STRING_MODE","PHRASAL_WORDS_MODE","COMMENT","begin","end","modeOptions","ENGLISH_WORD","C_LINE_COMMENT_MODE","C_BLOCK_COMMENT_MODE","HASH_COMMENT_MODE","NUMBER_MODE","C_NUMBER_MODE","BINARY_NUMBER_MODE","REGEXP_MODE","TITLE_MODE","UNDERSCORE_TITLE_MODE","METHOD_GUARD","END_SAME_AS_BEGIN","MODES","skipIfHasPrecedingDot","scopeClassName","_parent","beginKeywords","parent","compileIllegal","compileMatch","compileRelevance","beforeMatchExt","originalMode","COMMON_KEYWORDS","DEFAULT_KEYWORD_SCOPE","compileKeywords","rawKeywords","caseInsensitive","scopeName","compiledKeywords","compileList","keywordList","keyword","pair","scoreForKeyword","providedScore","commonKeyword","seenDeprecations","error","message","warn","deprecated","version","MultiClassError","remapScopeNames","regexes","scopeNames","emit","positions","beginMultiClass","endMultiClass","scopeSugar","MultiClass","compileLanguage","language","langRe","global","MultiRegex","terminators","matchData","ResumableMultiRegex","index","matcher","m2","buildModeRegex","mm","term","compileMode","cmode","ext","keywordPattern","c","expandOrCloneMode","dependencyOnParent","variant","HTMLInjectionError","escape","inherit","NO_MATCH","MAX_KEYWORD_HITS","HLJS","hljs","languages","aliases","plugins","SAFE_MODE","LANGUAGE_NOT_FOUND","PLAINTEXT_LANGUAGE","shouldNotHighlight","languageName","blockLanguage","block","classes","getLanguage","_class","highlight","codeOrLanguageName","optionsOrCode","ignoreIllegals","code","context","fire","_highlight","codeToHighlight","continuation","keywordHits","keywordData","matchText","processKeywords","top","modeBuffer","lastIndex","buf","word","kind","keywordRelevance","relevance","cssClass","emitKeyword","processSubLanguage","continuations","highlightAuto","processBuffer","emitMultiClass","max","klass","startNewMode","endOfMode","matchPlusRemainder","matched","doIgnore","resumeScanAtSamePosition","doBeginMatch","newMode","beforeCallbacks","cb","doEndMatch","endMode","origin","processContinuations","list","current","item","lastMatch","processLexeme","textBeforeMatch","err","processed","iterations","md","beforeMatch","processedCount","justTextHighlightResult","languageSubset","plaintext","results","autoDetection","sorted","a","b","best","secondBest","updateClassName","element","currentLang","resultLang","highlightElement","configure","userOptions","initHighlighting","highlightAll","initHighlightingOnLoad","wantsHighlight","boot","registerLanguage","languageDefinition","lang","error$1","registerAliases","unregisterLanguage","alias","listLanguages","aliasList","upgradePluginAPI","plugin","addPlugin","removePlugin","deprecateHighlightBlock","core","KEYWORDS","LITERALS","TYPES","ERROR_TYPES","BUILT_IN_GLOBALS","BUILT_IN_VARIABLES","BUILT_INS","javascript","hasClosingTag","after","tag","IDENT_RE$1","FRAGMENT","XML_SELF_CLOSING","XML_TAG","afterMatchIndex","nextChar","afterMatch","KEYWORDS$1","decimalDigits","frac","decimalInteger","NUMBER","SUBST","HTML_TEMPLATE","CSS_TEMPLATE","GRAPHQL_TEMPLATE","TEMPLATE_STRING","SUBST_INTERNALS","SUBST_AND_COMMENTS","PARAMS_CONTAINS","PARAMS","CLASS_OR_EXTENDS","CLASS_REFERENCE","USE_STRICT","FUNCTION_DEFINITION","UPPER_CASE_CONSTANT","noneOf","FUNCTION_CALL","PROPERTY_ACCESS","GETTER_OR_SETTER","FUNC_LEAD_IN_RE","FUNCTION_VARIABLE","CodeBlock","props","_CodeBlock_instances","unsafeHTML","onCodeChanged_fn","codeStr","ShowcaseComponent","_ShowcaseComponent_instances","hasSlot_fn","implementationSectionClassMap_fn","implementationSectionAnimationEnd_fn","showcaseComponentCss","rawStartTimeExample","rawMultiPlayerExample","rawDetectBlockedSegmentsExample","rawDisplayCurrentChapterExample","rawSkipCreditsExample","rawPlaylistExample","rawqualityMenuExample","alignLines","normalizeCode","leadingSpaces","parser","getTextFromHTML","selector","startTimeExampleTxt","multiPlayerExampleTxt","detectBlockedSegmentsExampleTxt","displayCurrentChapterExampleTxt","skipCreditsExampleTxt","playlistExampleTxt","qualityMenuExampleTxt","ShowCasePage","_ShowCasePage_instances","renderStartTime_fn","renderMultiplePlayers_fn","renderDetectBlockedSegments_fn","renderDisplayCurrentChapter_fn","renderSkipCredits_fn","renderPlaylist_fn","renderQualityMenu_fn","showcasePageCss","DemoHeaderElement","_DemoHeaderElement_instances","_onRouteUpdated","renderHeaderElement_fn","renderNavElement_fn","headerCSS","RouteOutletComponent","route"],"mappings":"2kCASO,MAAMA,WAAmBC,CAA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,YAAa,QACb,IAAK,qDACL,KAAM,YACP,EACD,CACE,MAAO,uBACP,YAAa,QACb,IAAK,wBACL,KAAM,YACP,EACD,CACE,MAAO,uBACP,YAAa,kBACb,IAAK,wBACL,KAAM,YACP,EACD,CACE,MAAO,yBACP,YAAa,4DACb,IAAK,wBACL,KAAM,YACP,EACD,CACE,MAAO,cACP,YAAa,wCACb,IAAK,yBACL,KAAM,YACP,EACD,CACE,MAAO,cACP,YAAa,8BACb,IAAK,wBACL,KAAM,YACZ,CACG,EACD,IAAK,CACH,CACE,MAAO,YACP,YAAa,8CACb,IAAK,+DACL,KAAM,uBACP,EACD,CACE,MAAO,oBACP,YAAa,uEACb,IAAK,iGACL,KAAM,uBACP,EACD,CACE,MAAO,gCACP,YAAa,WACb,IAAK,8EACL,KAAM,uBACP,EACD,CACE,MAAO,yBACP,YAAa,4BACb,IAAK,iFACL,KAAM,uBACP,EACD,CACE,MAAO,kCACP,YAAa,2BACb,IAAK,4EACL,KAAM,uBACP,EACD,CACE,MAAO,iDACP,YAAa,YACb,IAAK,wFACL,KAAM,uBACP,EACD,CACE,MAAO,yBACP,YAAa,kBACb,IAAK,qEACL,KAAM,uBACP,EACD,CACE,MAAO,kBACP,YAAa,iCACb,IAAK,kGACL,KAAM,uBACP,EACD,CACE,MAAO,mBACP,YAAa,kCACb,IAAK,oGACL,KAAM,uBACP,EACD,CACE,MAAO,2BACP,YAAa,6DACb,IAAK,qGACL,KAAM,uBACP,EACD,CACE,MAAO,6BACP,YAAa,2DACb,IAAK,uGACL,KAAM,uBACP,EACD,CACE,MAAO,mCACP,YAAa,oDACb,IAAK,mGACL,KAAM,uBACP,EACD,CACE,MAAO,cACP,IAAK,sFACL,KAAM,uBACP,EACD,CACE,MAAO,0BACP,IAAK,0HACL,KAAM,uBACP,EACD,CACE,MAAO,mBACP,YAAa,sCACb,IAAK;AAAA,EACL,KAAM,uBACP,EACD,CACE,MAAO,sCACP,YAAa,kCACb,IAAK,mEACL,KAAM,uBACP,EACD,CACE,MAAO,WACP,IAAK,wFACL,KAAM,uBACP,EACD,CACE,MAAO,0BACP,IAAK,2GACL,KAAM,uBACP,EACD,CACE,MAAO,UACP,IAAK,6EACL,KAAM,uBACP,EACD,CACE,MAAO,uBACP,IAAK,uGACL,KAAM,uBACP,EACD,CACE,MAAO,iCACP,IAAK,kHACL,KAAM,uBACP,EACD,CACE,MAAO,mBACP,IAAK,6IACL,KAAM,uBACP,EACD,CACE,MAAO,kBACP,IAAK,wHACL,KAAM,uBACP,EACD,CACE,MAAO,yBACP,IAAK,0HACL,KAAM,uBACP,EACD,CACE,MAAO,0BACP,IAAK,oOACL,KAAM,uBACP,EACD,CACE,MAAO,YACP,IAAK,qEACL,KAAM,uBACP,EACD,CACE,MAAO,wBACP,IAAK,oFACL,KAAM,uBACP,EACD,CACE,MAAO,aACP,IAAK,gGACL,KAAM,uBACP,EACD,CACE,MAAO,qBACP,IAAK,uEACL,KAAM,uBACP,EACD,CACE,MAAO,cACP,IAAK,4GACL,KAAM,uBACP,EACD,CACE,MAAO,gBACP,IAAK,4GACL,KAAM,uBACP,EACD,CACE,MAAO,QACP,YAAa,mBACb,IAAK,2EACL,KAAM,uBACZ,CACG,EACD,KAAM,CACJ,CACE,MAAO,oBACP,IAAK,oEACL,KAAM,sBACP,EACD,CACE,MAAO,kCACP,IAAK,mEACL,KAAM,uBACN,WAAY,CACV,qBAAsB,iFAC9B,CACK,EACD,CACE,MAAO,oBACP,IAAK,oEACL,KAAM,sBACP,EACD,CACE,MAAO,kCACP,IAAK,mEACL,KAAM,uBACN,WAAY,CACV,qBAAsB,iFAC9B,CACK,EACD,CACE,MAAO,mBACP,IAAK,sGACL,KAAM,sBACP,EACD,CACE,MAAO,wBACP,IAAK,sGACL,KAAM,sBACP,EACD,CACE,MAAO,mBACP,IAAK,uHACL,KAAM,sBACP,EACD,CACE,MAAO,0CACP,IAAK,gIACL,KAAM,sBACP,EACD,CACE,MAAO,yCACP,IAAK,+GACL,KAAM,sBACP,EAC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V,iBAAkBD,EACnB,EAED,UAAWxB,KAAOwE,GAEZ,OAAOA,GAAMxE,CAAG,GAAM,UAExBZ,GAAWoF,GAAMxE,CAAG,CAAC,EAKzB,cAAO,OAAO6I,EAAMrE,EAAK,EAElBqE,CACT,EAGMc,GAAYf,GAAK,EAAE,EAIzBe,GAAU,YAAc,IAAMf,GAAK,EAAE,MAErC4G,GAAiB7F,GACjBA,GAAU,YAAcA,GACxBA,GAAU,QAAUA,mBCpiFdjH,GAAW,2BACX+M,GAAW,CACf,KACA,KACA,KACA,KACA,MACA,QACA,UACA,MACA,MACA,WACA,KACA,SACA,OACA,OACA,QACA,QACA,aACA,OACA,QACA,OACA,UACA,MACA,SACA,WACA,SACA,SACA,MACA,QACA,QACA,QAIA,WACA,QACA,QACA,SACA,SACA,OACA,SACA,SACF,EACMC,GAAW,CACf,OACA,QACA,OACA,YACA,MACA,UACF,EAGMC,GAAQ,CAEZ,SACA,WACA,UACA,SAEA,OACA,OACA,SACA,SAEA,SACA,SAEA,QACA,eACA,eACA,YACA,aACA,oBACA,aACA,aACA,cACA,cACA,gBACA,iBAEA,MACA,MACA,UACA,UAEA,cACA,oBACA,UACA,WACA,OAEA,UACA,YACA,oBACA,gBAEA,UACA,QAEA,OAEA,aACF,EAEMC,GAAc,CAClB,QACA,YACA,gBACA,aACA,iBACA,cACA,YACA,UACF,EAEMC,GAAmB,CACvB,cACA,aACA,gBACA,eAEA,UACA,UAEA,OACA,WACA,QACA,aACA,WACA,YACA,qBACA,YACA,qBACA,SACA,UACF,EAEMC,GAAqB,CACzB,YACA,OACA,QACA,UACA,SACA,WACA,eACA,iBACA,SACA,QACF,EAEMC,GAAY,CAAE,EAAC,OACnBF,GACAF,GACAC,EACF,EAWA,SAASI,GAAWnH,EAAM,CACxB,MAAMvG,EAAQuG,EAAK,MAQboH,EAAgB,CAACjO,EAAO,CAAE,MAAAkO,CAAK,IAAO,CAC1C,MAAMC,EAAM,KAAOnO,EAAM,CAAC,EAAE,MAAM,C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EpCA,EAAO,YAAY,OACrBxD,GAAY,MAAQwD,EAAO,YAAY,QAAU,OACjDzD,GAAoB,gBAAgBC,EAAW,GACtCA,GAAY,OACrBwD,EAAO,YAAY,CAAE,MAAO,MAAM,CAAE","x_google_ignoreList":[4,8,9,22,23]} \ No newline at end of file +{"version":3,"file":"index-9SZSMbQ4.js","sources":["../../src/components/dialog/demo-dialog-component.js","../../src/layout/content/settings/preferences-provider.js","../../src/utils/il-provider.js","../../src/components/player/player.js","../../node_modules/lit-html/directives/class-map.js","../../src/layout/content/examples/load-media-form-component.js","../../src/components/content-link/content-link-component.js","../../src/layout/content/examples/examples.js","../../node_modules/lit-html/directives/map.js","../../node_modules/lit-html/directives/when.js","../../src/layout/content/examples/examples-page.js","../../src/components/spinner/spinner-component.js","../../src/components/intersection-observer/intersection-observer-component.js","../../src/components/scroll-to-top/scroll-to-top-component.js","../../src/utils/string-utils.js","../../src/layout/content/lists/lists-page-state-manager.js","../../src/layout/content/lists/lists-sections.js","../../src/layout/content/lists/lists-page.js","../../src/layout/content/search/search-bar-component.js","../../src/layout/content/search/search-page.js","../../src/components/toggle-switch/toggle-switch-component.js","../../src/layout/content/settings/settings-page.js","../../node_modules/highlight.js/lib/core.js","../../node_modules/highlight.js/es/languages/javascript.js","../../src/components/code-block/code-block.js","../../src/layout/content/showcase/showcase-component.js","../../static/showcases/start-time.html?raw","../../static/showcases/multi-player.html?raw","../../static/showcases/blocked-segment.html?raw","../../static/showcases/chapters.html?raw","../../static/showcases/skip-credits.html?raw","../../static/showcases/playlist.html?raw","../../static/showcases/quality-menu.html?raw","../../src/layout/content/showcase/example-parser.js","../../src/layout/content/showcase/showcase-page.js","../../src/layout/header/demo-header-component.js","../../src/router/route-outlet-component.js","../../src/index.js"],"sourcesContent":["/**\n * Defines the behaviour of the demo dialog.\n *\n * @module\n */\nimport { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../theme/theme';\nimport componentCSS from './demo-dialog-component.scss?inline';\n\nexport class DemoDialog extends LitElement {\n static properties = {\n open: { type: Boolean, reflect: true }\n };\n\n static styles = [\n theme, animations, unsafeCSS(componentCSS)\n ];\n\n #dialog;\n\n constructor() {\n super();\n this.open = false;\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (_changedProperties.has('open')) {\n if (this.open) {\n this.#dialog.showModal();\n this.#dialog.classList.toggle('slide-up-fade-in', true);\n } else {\n this.#dialog.close();\n }\n }\n }\n\n firstUpdated(_changedProperties) {\n super.firstUpdated(_changedProperties);\n this.#dialog = this.shadowRoot.querySelector('dialog');\n }\n\n #onDialogClosed() {\n this.dispatchEvent(new CustomEvent('close'));\n }\n\n #onDialogClicked(e) {\n if (this.#dialog !== e.target) return;\n this.open = false;\n }\n\n render() {\n return html`\n e.target.classList.remove('slide-up-fade-in')}\">\n \n \n \n `;\n }\n}\n\ncustomElements.define('demo-dialog', DemoDialog);\n","/**\n * Utility class for loading and saving preferences to local storage.\n *\n * @class PreferencesProvider\n */\nclass PreferencesProvider {\n /**\n * Load preferences from local storage.\n *\n * @static\n * @returns {Object} An object representing the loaded preferences.\n */\n static loadPreferences() {\n return JSON.parse(localStorage.getItem('preferences')) || {};\n }\n\n /**\n * Save preferences to local storage.\n *\n * @static\n * @param {Object} preferences - An object representing the preferences to be saved.\n * @returns {void}\n */\n static savePreferences(preferences) {\n localStorage.setItem('preferences', JSON.stringify(preferences));\n }\n}\n\nexport default PreferencesProvider;\n","export const IL_DEFAULT_HOST = 'il.srgssr.ch';\n\nconst DEFAULT_QUERY_PARAMS = {\n vector: 'srgplay'\n};\nconst DEFAULT_SEARCH_PARAMS = {\n includeAggregations: false,\n includeSuggestions: false,\n sortBy: 'default',\n sortDir: 'desc',\n pageSize: 50,\n ...DEFAULT_QUERY_PARAMS\n};\nconst DEFAULT_SHOWLIST_PARAMS = {\n onlyActiveShows: true,\n ...DEFAULT_QUERY_PARAMS\n};\n\nconst toMedia = ({ title, urn, mediaType, date, duration }) => ({\n title, urn, mediaType, date, duration\n});\n\n/**\n * Class representing a provider for the integration layer.\n *\n * @class\n */\nclass ILProvider {\n #host;\n\n /**\n * Creates an instance of ILProvider.\n *\n * @param {string} [host='il.srgssr.ch'] - The hostname for the integration layer (without the protocol).\n */\n constructor(host = IL_DEFAULT_HOST) {\n this.host = host;\n }\n\n /**\n * Get the current hostname for the integration layer.\n *\n * @returns {string} the hostname for the integration layer.\n */\n get host() {\n return this.#host;\n }\n\n /**\n * Set the hostname for the integration layer (without the protocol). Forces\n * `il.srgssr.ch` if null, undefined or empty string is passed.\n *\n * @param {string} host The hostname for the integration layer,\n */\n set host(host) {\n this.#host = host || IL_DEFAULT_HOST;\n }\n\n /**\n * Performs a search for media content based on the provided business unit and query.\n *\n * @param {string} bu - The business unit for which the search is performed (rsi, rtr, rts, srf or swi).\n * @param {string} query - The search query.\n * @param {AbortSignal} [signal=undefined] - (Optional) An abort signal,\n * allows to abort the query through an abort controller.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the search results.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async search(bu, query, signal = undefined) {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/searchResultMediaList`,\n { ...DEFAULT_SEARCH_PARAMS, q: query },\n signal\n );\n const toResults = (data) => data.searchResultMediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves a list of topics for the specified business unit and transmission type.\n *\n * @param {string} bu - The business unit for which to retrieve topics (rsi, rtr, rts, srf, or swi).\n * @param {string} [transmission='tv'] - The transmission type ('tv' or 'radio').\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and URN of the topics.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async topics(bu, transmission = 'tv') {\n const data = await this.#fetch(`/${bu.toLowerCase()}/topicList/${transmission}`);\n\n return data.topicList.map(\n ({ title, urn }) => ({ title, urn })\n );\n }\n\n /**\n * Retrieves the latest media content for a specific topic.\n *\n * @param {string} topicUrn - The URN (Unique Resource Name) of the topic.\n * @param {number} [pageSize=30] - The maximum number of episodes to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async latestByTopic(topicUrn, pageSize = 30) {\n const data = await this.#fetch(`/mediaList/latest/byTopicUrn/${topicUrn}`, { pageSize });\n\n const toResults = (data) => data.mediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves a list of shows for the specified business unit, transmission type, and ordering.\n *\n * @param {string} bu - The business unit for which to retrieve shows (rsi, rtr, rts, srf, or swi).\n * @param {string} [pageSize='unlimited'] - The maximum number of shows to retrieve. Use 'unlimited' for all shows.\n * @param {string} [transmission='tv'] - The transmission type ('tv' or 'radio').\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and URN of the shows.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async shows(bu, pageSize = 'unlimited', transmission = 'tv') {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/showList/${transmission}/alphabetical`,\n { ...DEFAULT_SHOWLIST_PARAMS, pageSize }\n );\n\n return data.showList.map(\n ({ title, urn }) => ({ title, urn })\n );\n }\n\n /**\n * Retrieves the latest media content for a specific show.\n *\n * @param {string} showUrn - The URN (Unique Resource Name) of the show.\n * @param {number} [pageSize=30] - The maximum number of episodes to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async latestByShow(showUrn, pageSize = 30) {\n const data = await this.#fetch(\n `/episodeComposition/latestByShow/byUrn/${showUrn}`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n\n const toResults = (data) => data.episodeList\n .map(({ mediaList }) => mediaList[0])\n .map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves editorial media content for the specified business unit.\n *\n * @param {string} bu - The business unit for which to retrieve editorial media (rsi, rtr, rts, srf, or swi).\n * @param {number} [pageSize=30] - The maximum number of editorial media items to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async editorial(bu, pageSize = 30) {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/mediaList/video/editorial`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n\n const toResults = (data) => data.mediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves livestream media content for the specified business unit and media type.\n *\n * @param {string} bu - The business unit for which to retrieve livestreams (rsi, rtr, rts, srf, or swi).\n * @param {string} [mediaType='video'] - The media type ('video' or 'audio').\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and URN of the livestream media content.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async livestreams(bu, mediaType = 'video') {\n const data = await this.#fetch(`/${bu.toLowerCase()}/mediaList/${mediaType}/livestreams`);\n\n return data.mediaList.map(toMedia);\n }\n\n /**\n * Retrieves scheduled livestream media content for the specified business unit.\n *\n * @param {string} bu - The business unit for which to retrieve scheduled livestreams (rsi, rtr, rts, srf, or swi).\n * @param {number} [pageSize=10] - The maximum number of scheduled livestreams to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async scheduledLivestream(bu, pageSize = 10) {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/mediaList/video/scheduledLivestreams`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n const toResults = (data) => data.mediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves media content for the livecenter for the specified business unit.\n *\n * @param {string} bu - The business unit for which to retrieve livecenter media (rsi, rtr, rts, srf, or swi).\n * @param {number} [pageSize=10] - The maximum number of livecenter media items to retrieve.\n *\n * @returns {Promise<{ results: Array<{ title: string, urn: string }>, next: function }>} - A promise\n * that resolves to an object containing :\n * - `results`: An array of objects containing the title, URN, media type, date, and duration of the medias.\n * - `next`: A function that, when called, retrieves the next set of data and returns a new object with updated results and the next function.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async livecenter(bu, pageSize = 10) {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/mediaList/video/scheduledLivestreams/livecenter`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n const toResults = (data) => data.mediaList.map(toMedia);\n\n return {\n results: toResults(data),\n next: data.next ? this.#nextProvider(data.next, toResults) : undefined\n };\n }\n\n /**\n * Retrieves a list of channels for the specified business unit and transmission type.\n *\n * @param {string} bu - The business unit for which to retrieve channels (rsi, rtr, rts, srf, or swi).\n * @param {string} [transmission='radio'] - The transmission type ('tv' or 'radio').\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and ID of the channels.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async channels(bu, transmission = 'radio') {\n const data = await this.#fetch(`/${bu.toLowerCase()}/channelList/${transmission}`);\n\n return data.channelList.map(\n ({ title, id }) => ({ title, id })\n );\n }\n\n /**\n * Retrieves radio shows for the specified business unit and channel.\n *\n * @param {string} bu - The business unit for which to retrieve radio shows (rsi, rtr, rts, srf, or swi).\n * @param {string} channelId - The ID of the channel.\n * @param {string} [pageSize='unlimited'] - The maximum number of radio shows to retrieve. Use 'unlimited' for all shows.\n *\n * @returns {Promise>} - A promise that resolves to an array\n * of objects containing the title and URN of the radio shows.\n *\n * @throws {Promise} - A rejected promise with the response object if the fetch request fails.\n */\n async radioShowByChannel(bu, channelId, pageSize = 'unlimited') {\n const data = await this.#fetch(\n `/${bu.toLowerCase()}/showList/radio/alphabeticalByChannel/${channelId}`,\n { ...DEFAULT_QUERY_PARAMS, pageSize }\n );\n\n return data.showList.map(\n ({ title, urn }) => ({ title, urn })\n );\n }\n\n /**\n * Asynchronously fetches data from the IL for the specified path and parameters.\n *\n * @private\n * @param {string} path - The path to fetch data from.\n * @param {Object} [params=DEFAULT_QUERY_PARAMS] - (Optional) parameters for the request.\n * @param {AbortSignal} [signal=undefined] - (Optional) AbortSignal to abort the request.\n *\n * @returns {Promise<*>} A Promise that resolves to the JSON response data.\n *\n * @throws {Response} If the HTTP response is not ok (status code other than 2xx).\n * @throws {Error} If the fetch operation fails for any other reason.\n */\n async #fetch(path, params = DEFAULT_QUERY_PARAMS, signal = undefined) {\n const queryParams = new URLSearchParams(params).toString();\n const url = `https://${this.host}/integrationlayer/2.0/${path.replace(/^\\/+/, '')}?${queryParams}`;\n\n return fetch(url, { signal }).then(response => {\n if (!response.ok) {\n return Promise.reject(response);\n }\n\n return response.json();\n }).catch((reason) => {\n return Promise.reject(reason);\n });\n }\n\n /**\n * Generates a function that, when called, retrieves the next set of data and\n * returns a new object with updated results and the next function.\n *\n * @private\n * @template T - The type of data returned by the resultMapper function.\n *\n * @param {string} nextUrl - The URL for fetching the next set of data.\n * @param {(data: any) => T} resultMapper - A function to map the raw data to the desired format.\n *\n * @returns {(signal?: AbortSignal) => Promise<{ results: T, next: function }>} - A function that,\n * when called, retrieves the next set of data and returns a new object with updated results and the next function.\n */\n #nextProvider(nextUrl, resultMapper) {\n return async(signal = undefined) => {\n const nextData = await fetch(nextUrl, { signal }).then(response => {\n if (!response.ok) {\n return Promise.reject(response);\n }\n\n return response.json();\n }).catch((reason) => {\n return Promise.reject(reason);\n });\n\n const nextResults = resultMapper(nextData);\n\n return {\n results: nextResults,\n next: this.#nextProvider(nextData.next, resultMapper)\n };\n };\n }\n}\n\nexport default new ILProvider();\n","/**\n * Initialized the demo player.\n *\n * @module\n */\nimport '../dialog/demo-dialog-component';\nimport PreferencesProvider\n from '../../layout/content/settings/preferences-provider';\nimport router from '../../router/router';\nimport Pillarbox from '@srgssr/pillarbox-web';\nimport { IL_DEFAULT_HOST } from '../../utils/il-provider.js';\n\nconst DEMO_PLAYER_ID = 'demo-player';\nconst DEFAULT_OPTIONS = {\n restoreEl: true\n};\n\nconst preferencesToPlayerOptions = (preferences) => {\n return {\n muted: preferences.muted ?? true,\n autoplay: preferences.autoplay ?? false,\n debug: preferences.debug ?? false,\n srgOptions: {\n dataProviderHost: preferences.dataProviderHost ?? IL_DEFAULT_HOST\n }\n };\n};\n/**\n * Creates and configures a Pillarbox player.\n *\n * @param {Object} options - (Optional) options to customize the player behaviour.\n *\n * @returns {Object} The configured Pillarbox player instance.\n */\nconst createPlayer = (options = {}) => {\n window.player = new Pillarbox(DEMO_PLAYER_ID, {\n ...DEFAULT_OPTIONS,\n ...preferencesToPlayerOptions(PreferencesProvider.loadPreferences()),\n ...options\n });\n\n return window.player;\n};\n\n/**\n * Disposes of the Pillarbox video player instance.\n */\nconst destroyPlayer = () => {\n Pillarbox.getPlayer(DEMO_PLAYER_ID).dispose();\n window.player = null;\n};\n\n// Expose Pillarbox and player in the window object for debugging\nwindow.pillarbox = Pillarbox;\n// Configure the dialog\nconst playerDialog = document.querySelector('demo-dialog');\n\nconst toParams = (keySystems) => {\n const vendor = Object.keys(keySystems ?? {})[0];\n\n if (!vendor) {\n return {};\n }\n\n return {\n vendor,\n ...(vendor === 'com.apple.fps.1_0' ? keySystems[vendor] : { licenseUri: keySystems[vendor] })\n };\n};\n\nconst toKeySystem = (params) => {\n if (!params.vendor) {\n return undefined;\n }\n\n const { certificateUri, licenseUri } = params;\n\n if (params.vendor === 'com.apple.fps.1_0') {\n return { [params.vendor]: { certificateUri, licenseUri } };\n }\n\n return { [params.vendor]: licenseUri };\n};\n\nexport const asQueryParams = ({ src, type, keySystems }) => {\n return new URLSearchParams({ src, type, ...toParams(keySystems) }).toString();\n};\n\nplayerDialog.addEventListener('close', () => {\n destroyPlayer();\n router.updateState({}, ['src', 'type', 'vendor', 'certificateUri', 'licenseUri']);\n});\n\nconst loadPlayerFromRouter = (e) => {\n if (window.player) {\n return;\n }\n\n const params = e.detail.queryParams;\n\n if ('src' in params) {\n const { src, type } = params;\n const keySystems = toKeySystem(params);\n\n openPlayerModal({ src, type, keySystems });\n }\n};\n\nrouter.addEventListener('routechanged', loadPlayerFromRouter);\nrouter.addEventListener('queryparams', loadPlayerFromRouter);\n\n/**\n * Opens a modal containing a video player with specified source and type. Can only\n * load URN if the type 'srgssr/urn`is explicitly provided, otherwise the created\n * Pillarbox player tries to guess the type.\n *\n * @param {object} options - An object containing the source and type of the video to be played.\n * @param {string} options.src - The source URL of the video.\n * @param {string} [options.type] - (Optional) The type/format of the video (e.g., 'video/mp4').\n * @param {object} [options.keySystems] - (Optional) The DRM configuration for DRM protected sources.\n * @param {object} [options.playerOptions] - (Optional) Additional configuration for the player.\n * @param {Boolean} shouldUpdateRouter - Whether the router should be updated or not (Default: true).\n *\n * @returns {Object} The configured Pillarbox player instance.\n */\nexport const openPlayerModal = (\n { src, type, keySystems, playerOptions },\n shouldUpdateRouter = true\n) => {\n const player = createPlayer(playerOptions ?? {});\n\n playerDialog.open = true;\n player.src({ src, type, keySystems });\n\n if (shouldUpdateRouter) {\n router.updateState({\n src,\n ...(type ? { type } : {}),\n ...toParams(keySystems)\n });\n }\n\n return player;\n};\n","import{noChange as t}from\"../lit-html.js\";import{directive as s,Directive as i,PartType as r}from\"../directive.js\";\n/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */const e=s(class extends i{constructor(t){if(super(t),t.type!==r.ATTRIBUTE||\"class\"!==t.name||t.strings?.length>2)throw Error(\"`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.\")}render(t){return\" \"+Object.keys(t).filter((s=>t[s])).join(\" \")+\" \"}update(s,[i]){if(void 0===this.st){this.st=new Set,void 0!==s.strings&&(this.nt=new Set(s.strings.join(\" \").split(/\\s/).filter((t=>\"\"!==t))));for(const t in i)i[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(i)}const r=s.element.classList;for(const t of this.st)t in i||(r.remove(t),this.st.delete(t));for(const t in i){const s=!!i[t];s===this.st.has(t)||this.nt?.has(t)||(s?(r.add(t),this.st.add(t)):(r.remove(t),this.st.delete(t)))}return t}});export{e as classMap};\n//# sourceMappingURL=class-map.js.map\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport componentCSS from './load-media-form-component.scss?inline';\nimport { classMap } from 'lit/directives/class-map.js';\n\n/**\n * LoadMediaFormComponent is a LitElement that provides a user interface for loading media content.\n *\n * @element load-media-form\n *\n * @fires LoadMediaFormComponent#submit-media - Dispatched when the user submits media with the specified details.\n *\n * @prop {String} src - The URL or URN of the media content to be loaded.\n * @prop {{vendor: String, certificateUri: String, licenseUri: String}} drmSettings - DRM settings for the loaded media.\n */\nexport class LoadMediaFormComponent extends LitElement {\n static properties = {\n src: { type: String },\n drmSettings: { type: Object },\n drmSettingsShown: { state: true, type: Boolean }\n };\n\n static styles = [theme, animations, unsafeCSS(componentCSS)];\n\n constructor() {\n super();\n\n this.src = '';\n this.#initDrmSettings();\n }\n\n #initDrmSettings() {\n this.drmSettings = {\n vendor: '',\n certificateUri: '',\n licenseUri: ''\n };\n }\n\n #getSource() {\n try {\n return new URL(this.src).searchParams.get('urn') ?? this.src;\n } catch {\n return this.src;\n }\n }\n\n #submitMedia() {\n const src = this.#getSource()?.trim();\n const type = src.startsWith('urn:') ? 'srgssr/urn' : undefined;\n const keySystems = this.#keySystems;\n\n /**\n * Custom event dispatched by LoadMediaFormComponent when the user submits media.\n *\n * @event LoadMediaFormComponent#submit-media\n * @type {CustomEvent}\n * @property {Object} detail - The event detail object.\n * @property {string} detail.src - The URL or URN of the media content to be loaded.\n * @property {string | undefined} detail.type - The type of media. Undefined if the type cannot be determined.\n * @property {Object | undefined} detail.keySystems - DRM key systems for the loaded media.\n */\n this.dispatchEvent(new CustomEvent('submit-media', {\n detail: { src, type, keySystems }\n }));\n }\n\n #handleLoadBarKeyUp(event) {\n this.src = event.target.value;\n\n if (event.key === 'Enter' && this.src) {\n this.#submitMedia();\n }\n }\n\n get #keySystems() {\n if (!this.drmSettings?.vendor) {\n return undefined;\n }\n\n return this.#toKeySystem();\n }\n\n #toKeySystem() {\n const certificateUri = this.drmSettings.certificateUri?.trim();\n const licenseUri = this.drmSettings.licenseUri?.trim();\n\n if (this.drmSettings.vendor === 'com.apple.fps.1_0') {\n return { [this.drmSettings.vendor]: { certificateUri, licenseUri } };\n }\n\n return { [this.drmSettings.vendor]: licenseUri };\n }\n\n render() {\n const btnSettingsClassMap = {\n spin: this.drmSettingsShown === true,\n 'spin-back': this.drmSettingsShown === false\n };\n\n return html`\n
e.target.classList.remove('fade-in')}\">\n
\n insert_link\n \n \n
\n \n ${this.#drmSettingsTemplate()}\n\n \n
\n `;\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (_changedProperties.has('drmSettingsShown') && this.drmSettingsShown) {\n this.shadowRoot.querySelector('.drm-settings-container').classList.add('active');\n }\n }\n\n #onFormAnimationEnd(e) {\n e.target.classList.toggle('active', !e.target.classList.contains('fade-out-shrink'));\n e.target.classList.remove('fade-in-grow', 'fade-out-shrink');\n }\n\n #formAnimationClassMap() {\n return {\n 'fade-in-grow': this.drmSettingsShown === true,\n 'fade-out-shrink': this.drmSettingsShown === false\n };\n }\n\n #drmSettingsTemplate() {\n return html`\n
this.#onFormAnimationEnd(e)}\">\n

DRM Settings

\n \n { this.drmSettings.licenseUri = e.target.value; }}\">\n { this.drmSettings.certificateUri = e.target.value; }}\">\n \n
\n
\n `;\n }\n}\n\ncustomElements.define('load-media-form', LoadMediaFormComponent);\n","import router from '../../router/router';\nimport { html, LitElement, unsafeCSS } from 'lit';\nimport componentCSS from './content-link-component.scss?inline';\n\n/**\n * A component for rendering a content link.\n *\n * @prop {string} href - The URL to navigate to.\n * @prop {string} title - The title attribute for the link.\n *\n * @csspart a - The anchor element.\n * @csspart title - The title span within the anchor.\n * @csspart description - The slot for additional description content within the anchor.\n *\n * @example\n * \n * Additional Description Content\n * \n */\nexport class ContentLinkComponent extends LitElement {\n static properties = {\n href: {}\n };\n\n static styles = unsafeCSS(componentCSS);\n\n #onClick = (event) => {\n event.preventDefault();\n\n const url = new URL(`${window.location.origin}/${this.href}`);\n const queryParams = Object.fromEntries(url.searchParams.entries());\n\n router.navigateTo(url.pathname, queryParams);\n };\n\n connectedCallback() {\n super.connectedCallback();\n this.addEventListener('click', this.#onClick);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.removeEventListener('click', this.#onClick);\n }\n\n render() {\n return html`\n \n ${this.title}\n \n \n `;\n }\n}\n\ncustomElements.define('content-link', ContentLinkComponent);\n","const EXAMPLES = {\n SRGSSR: [\n {\n title: 'Horizontal video',\n src: 'urn:rts:video:14827306',\n type: 'srgssr/urn'\n },\n {\n title: 'Square video',\n src: 'urn:rts:video:8393241',\n type: 'srgssr/urn'\n },\n {\n title: 'Vertical video',\n src: 'urn:rts:video:13444390',\n type: 'srgssr/urn'\n },\n {\n title: 'Token-protected video',\n description: 'Ski alpin, Slalom Messieurs',\n src: 'urn:swisstxt:video:rts:c56ea781-99ad-40c3-8d9b-444cc5ac3aea',\n type: 'srgssr/urn'\n },\n {\n title: 'Superfluously token-protected video',\n description: 'Telegiornale flash',\n src: 'urn:rsi:video:15916771',\n type: 'srgssr/urn'\n },\n {\n title: 'DRM-protected video',\n description: 'Top Models 8870',\n src: 'urn:rts:video:13639837',\n type: 'srgssr/urn'\n },\n {\n title: 'Live video',\n description: 'SRF 1',\n src: 'urn:srf:video:c4927fcf-e1a0-0001-7edd-1ef01d441651',\n type: 'srgssr/urn'\n },\n {\n title: 'DVR video livestream',\n description: 'RTS 1',\n src: 'urn:rts:video:3608506',\n type: 'srgssr/urn'\n },\n {\n title: 'DVR audio livestream',\n description: 'Couleur 3 (DVR)',\n src: 'urn:rts:audio:3262363',\n type: 'srgssr/urn'\n },\n {\n title: 'On-demand audio stream',\n description: 'Il lavoro di TerraProject per una fotografia documentaria',\n src: 'urn:rsi:audio:8833144',\n type: 'srgssr/urn'\n },\n {\n title: 'Expired URN',\n description: 'Content that is not available anymore',\n src: 'urn:rts:video:13382911',\n type: 'srgssr/urn'\n },\n {\n title: 'Unknown URN',\n description: 'Content that does not exist',\n src: 'urn:srf:video:unknown',\n type: 'srgssr/urn'\n }\n ],\n HLS: [\n {\n title: 'VOD - HLS',\n description: 'Switzerland says sorry! The fondue invasion',\n src: 'https://swi-vod.akamaized.net/videoJson/47603186/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'VOD - HLS (short)',\n description: 'Des violents orages ont touché Ajaccio, chef-lieu de la Corse, jeudi',\n src: 'https://rts-vod-amd.akamaized.net/ww/13317145/f1d49f18-f302-37ce-866c-1c1c9b76a824/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Brain Farm Skate Phantom Flex',\n description: '4K video',\n src: 'https://sample.vodobox.net/skate_phantom_flex_4k/skate_phantom_flex_4k.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Video livestream - HLS',\n description: 'Couleur 3 en vidéo (live)',\n src: 'https://rtsc3video.akamaized.net/hls/live/2042837/c3video/3/playlist.m3u8?dw=0',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Video livestream with DVR - HLS',\n description: 'Couleur 3 en vidéo (DVR)',\n src: 'https://rtsc3video.akamaized.net/hls/live/2042837/c3video/3/playlist.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Video livestream with DVR and timestamps - HLS',\n description: 'Tageschau',\n src: 'https://tagesschau.akamaized.net/hls/live/2020115/tagesschau/tagesschau_1/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Audio livestream - HLS',\n description: 'Couleur 3 (DVR)',\n src: 'https://lsaplus.swisstxt.ch/audio/couleur3_96.stream/playlist.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Basic 4:3',\n description: '4x3 aspect ratio, H.264 @ 30Hz',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/bipbop_4x3/bipbop_4x3_variant.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Basic 16:9',\n description: '16x9 aspect ratio, H.264 @ 30Hz',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/bipbop_16x9/bipbop_16x9_variant.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Advanced 16:9 (TS)',\n description: '16x9 aspect ratio, H.264 @ 30Hz and 60Hz, Transport stream',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_ts/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Advanced 16:9 (fMP4)',\n description: '16x9 aspect ratio, H.264 @ 30Hz and 60Hz, Fragmented MP4',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_fmp4/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Advanced 16:9 (HEVC/H.264)',\n description: '16x9 aspect ratio, H.264 and HEVC @ 30Hz and 60Hz',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/bipbop_adv_example_hevc/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple Atmos',\n src: 'https://devstreaming-cdn.apple.com/videos/streaming/examples/adv_dv_atmos/main.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple WWDC Keynote 2023',\n src: 'https://events-delivery.apple.com/0105cftwpxxsfrpdwklppzjhjocakrsk/m3u8/vod_index-PQsoJoECcKHTYzphNkXohHsQWACugmET.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Apple tv trailer',\n description: 'Lot of audios and subtitles choices',\n src: 'https://play-edge.itunes.apple.com/WebObjects/MZPlayLocal.woa/hls/subscription/playlist.m3u8?cc=CH&svcId=tvs.vds.4021&a=1522121579&isExternal=true&brandId=tvs.sbd.4000&id=518077009&l=en-GB&aec=UHD\\n',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Multiple subtitles and audio tracks',\n description: 'On some devices codec may crash',\n src: 'https://bitmovin-a.akamaihd.net/content/sintel/hls/playlist.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: '4K, HEVC',\n src: 'https://cdn.bitmovin.com/content/encoding_test_dash_hls/4k/hls/4k_profile/master.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'VoD, single audio track',\n src: 'https://bitmovin-a.akamaihd.net/content/MI201109210084_1/m3u8s/f08e80da-bf1d-4e3d-8899-f0f6155f6efa.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'AES-128',\n src: 'https://bitmovin-a.akamaihd.net/content/art-of-motion_drm/m3u8s/11331.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'HLS - Fragmented MP4',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.ism/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'HLS - Alternate audio language',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-lang.ism/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'HLS - Audio only',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-lang.ism/.m3u8?filter=(type!=%22video%22)',\n type: 'application/x-mpegURL'\n },\n {\n title: 'HLS - Trickplay',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/no-handler-origin/tears-of-steel/tears-of-steel-trickplay.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Limiting bandwidth use',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.ism/.m3u8?max_bitrate=800000',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Dynamic Track Selection',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.ism/.m3u8?filter=%28type%3D%3D%22audio%22%26%26systemBitrate%3C100000%29%7C%7C%28type%3D%3D%22video%22%26%26systemBitrate%3C1024000%29',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Pure live',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Timeshift (5 minutes)',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.m3u8?time_shift=300',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Live audio',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.m3u8?filter=(type!=%22video%22)',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Pure live (scte35)',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/scte35.isml/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'fMP4, clear',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-fmp4.ism/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'fMP4, HEVC 4K',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-hevc.ism/.m3u8',\n type: 'application/x-mpegURL'\n },\n {\n title: 'Test1',\n description: 'Forced subtitles',\n src: 'https://prd.vod-srgssr.ch/origin/1053457/fr/master.m3u8?complexSubs=true',\n type: 'application/x-mpegURL'\n }\n ],\n DASH: [\n {\n title: 'VoD - Dash (H264)',\n src: 'https://storage.googleapis.com/wvmedia/clear/h264/tears/tears.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'VoD - Dash Widewine cenc (H264)',\n src: 'https://storage.googleapis.com/wvmedia/cenc/h264/tears/tears.mpd',\n type: 'application/dash+xml',\n keySystems: {\n 'com.widevine.alpha': 'https://proxy.uat.widevine.com/proxy?video_id=2015_tears&provider=widevine_test'\n }\n },\n {\n title: 'VoD - Dash (H265)',\n src: 'https://storage.googleapis.com/wvmedia/clear/hevc/tears/tears.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'VoD - Dash widewine cenc (H265)',\n src: 'https://storage.googleapis.com/wvmedia/cenc/hevc/tears/tears.mpd',\n type: 'application/dash+xml',\n keySystems: {\n 'com.widevine.alpha': 'https://proxy.uat.widevine.com/proxy?video_id=2015_tears&provider=widevine_test'\n }\n },\n {\n title: 'VoD - Dash - MP4',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.mp4/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Fragmented MP4',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - TrickPlay',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/no-handler-origin/tears-of-steel/tears-of-steel-trickplay.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Tiled thumbnails (live/timeline)',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-tiled-thumbnails-timeline.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Accessibility - hard of hearing',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-hoh-subs.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Single - fragmented TTML',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-en.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Multiple - RFC 5646 language tags',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-rfc5646.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Multiple - fragmented TTML',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-ttml.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Audio only',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-lang.ism/.mpd?filter=(type!=%22video%22)',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Multiple audio codecs',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-codec.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Alternate audio language',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-multi-lang.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Accessibility - audio description',\n src: 'https://demo.unified-streaming.com/k8s/features/stable/video/tears-of-steel/tears-of-steel-desc-aud.ism/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Pure live',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.mpd',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - Timeshift (5 minutes)',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live.isml/.mpd?time_shift=300',\n type: 'application/dash+xml'\n },\n {\n title: 'Dash - DVB DASH low latency',\n src: 'https://demo.unified-streaming.com/k8s/live/stable/live-low-latency.isml/.mpd',\n type: 'application/dash+xml'\n }\n ],\n MP4: [\n {\n title: 'VOD - MP4',\n description: 'The dig',\n src: 'https://media.swissinfo.ch/media/video/dddaff93-c2cd-4b6e-bdad-55f75a519480/rendition/154a844b-de1d-4854-93c1-5c61cd07e98c.mp4',\n type: 'video/mp4'\n },\n {\n title: 'AVC Progressive',\n src: 'https://bitmovin-a.akamaihd.net/content/MI201109210084_1/MI201109210084_mpeg-4_hd_high_1080p25_10mbits.mp4',\n type: 'video/mp4'\n }\n ],\n AOD: [\n {\n title: 'Audio HLS',\n description: 'Content with PTS rollover',\n src: 'https://cdn.rts.ch/audio-sample/playlist.m3u8',\n type: 'application/x-mpegURL'\n }\n ]\n};\n\nexport default EXAMPLES;\n","/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nfunction*o(o,f){if(void 0!==o){let i=0;for(const t of o)yield f(t,i++)}}export{o as map};\n//# sourceMappingURL=map.js.map\n","/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nfunction n(n,r,t){return n?r(n):t?.(n)}export{n as when};\n//# sourceMappingURL=when.js.map\n","import router from '../../../router/router';\nimport { css, html, LitElement } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport './load-media-form-component';\nimport '../../../components/content-link/content-link-component';\nimport Examples from './examples';\nimport { map } from 'lit/directives/map.js';\nimport { when } from 'lit/directives/when.js';\nimport { asQueryParams, openPlayerModal } from '../../../components/player/player';\n\n/**\n * A web component that represents the examples page.\n *\n * @element examples-page\n */\nexport class ExamplesPage extends LitElement {\n static styles = [\n theme, animations, css`\n .example-section p {\n margin-bottom: 0;\n color: var(--color-5);\n font-size: var(--size-3);\n text-align: left;\n }`\n ];\n\n render() {\n return html`\n openPlayerModal(e.detail)}\">\n \n\n \n
e.target.classList.remove('fade-in')}\">\n ${map(Object.entries(Examples), ([section, examples]) => html`\n
\n

${section}

\n ${map(examples, example => html`\n \n ${when(example.description, () => html`\n ${example.title}\n `)}\n \n `)}\n
\n `)}\n
\n `;\n }\n}\n\ncustomElements.define('examples-page', ExamplesPage);\nrouter.addRoute('examples', 'examples-page');\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport spinnerCss from './spinner-component.scss?inline';\nimport { animations } from '../../theme/theme';\n\n/**\n * A spinner component.\n *\n * @element loading-spinner\n */\nexport class SpinnerComponent extends LitElement {\n static properties = {\n loading: { type: Boolean, reflect: true }\n };\n\n static styles = [animations, unsafeCSS(spinnerCss)];\n\n constructor() {\n super();\n this.loading = false;\n }\n\n render() {\n return html`\n
\n
\n
\n `;\n }\n}\n\ncustomElements.define('loading-spinner', SpinnerComponent);\n","import { html, LitElement } from 'lit';\nimport { animations } from '../../theme/theme';\n\nconst DEFAULT_INT_OPTIONS = {\n root: null,\n rootMargin: '0px',\n threshold: 0.1\n};\n\n/**\n * Attach an Intersection Observer to a target element and execute a callback when it becomes visible.\n *\n * @param {Element} target - The target element to observe.\n * @param {Function} callback - The callback function to execute when the target is intersecting.\n * @param {Object} options - (Optional) Options to configure the Intersection Observer.\n * @param {Element} [options.root=null] - The element that is used as the viewport for checking visibility.\n * @param {string} [options.rootMargin='0px'] - Margin around the root. Can have values similar to CSS margin property.\n * @param {number} [options.threshold=0.1] - The threshold at which the callback will be triggered.\n */\nconst onIntersecting = (target, callback, options = DEFAULT_INT_OPTIONS) => {\n new IntersectionObserver((entries) => {\n entries.forEach(entry => {\n if (entry.isIntersecting) {\n callback();\n }\n });\n }, options).observe(target);\n};\n\n/**\n * This web component acts as a sentinel for an Intersection Observer,\n * dispatching an 'intersecting' event when the observed element intersects\n * with the view.\n *\n * @element intersection-observer\n * @csspart sentinel - the sentinel element.\n *\n * @fires IntersectionObserverComponent#intersecting - Dispatched when the observed element intersects with the view.\n */\nexport class IntersectionObserverComponent extends LitElement {\n static styles = [\n animations\n ];\n\n firstUpdated(_changedProperties) {\n super.firstUpdated(_changedProperties);\n onIntersecting(\n this.renderRoot.querySelector('div'),\n () => {\n /**\n * Custom event dispatched by IntersectionObserverComponent when the observed element intersects\n * with the view.\n *\n * @event IntersectionObserverComponent#intersecting\n * @type {CustomEvent}\n * @property {Object} detail - The event detail object.\n * @property {string} detail.src - The URL or URN of the media content to be loaded.\n * @property {string | undefined} detail.type - The type of media. Undefined if the type cannot be determined.\n * @property {Object | undefined} detail.keySystems - DRM key systems for the loaded media.\n */\n this.dispatchEvent(new CustomEvent('intersecting'));\n }\n );\n }\n\n render() {\n return html`\n
\n `;\n }\n}\n\ncustomElements.define('intersection-observer', IntersectionObserverComponent);\n","import { css, html, LitElement } from 'lit';\nimport { animations, theme } from '../../theme/theme';\n\n/**\n * A custom web component that provides a button to scroll to the top of the page.\n *\n * @element scroll-to-top-button\n */\nexport class ScrollToTopComponent extends LitElement {\n static styles = [\n theme,\n animations,\n css`\n .scroll-to-top-button {\n position: fixed;\n right: 20px;\n bottom: 20px;\n z-index: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n width: var(--size-7);\n height: var(--size-7);\n padding: 0;\n border: none;\n border-radius: var(--radius-round);\n }\n\n .scroll-to-top-button i {\n font-size: var(--size-8);\n }\n `];\n\n render() {\n return html`\n \n `;\n }\n}\n\ncustomElements.define('scroll-to-top-button', ScrollToTopComponent);\n","/**\n * Converts a given string to kebab case, spaces are replaced with hyphens\n * and all letters are converted to lowercase.\n *\n * @param {string} str - The input string to be converted to kebab case.\n * @returns {string} - The input string converted to kebab case.\n *\n * @example\n * const result = toKebabCase(\"Hello World\");\n * console.log(result); // Output: \"hello-world\"\n *\n * @example\n * const result = toKebabCase(\"CamelCase Example\");\n * console.log(result); // Output: \"camelcase-example\"\n */\nexport const toKebabCase = (str) => str.replace(/\\s+/g, '-').toLowerCase();\n","import { toKebabCase } from '../../../utils/string-utils';\n\n/**\n * Manages the state of a lists page, allowing navigation and retrieval of section data.\n *\n * @class\n */\nclass ListsPageStateManager {\n /**\n * Creates an instance of ListsPageStateManager.\n *\n * @constructor\n * @param {Array
} root - The root level of the lists page.\n */\n constructor(root) {\n /**\n * Stack to keep track of the traversal steps for navigation.\n *\n * @type {Array<{level: Array
, sectionIndex: number, nodeIndex: number}>}\n */\n this.stack = [];\n /**\n * The current level of the content tree.\n *\n * @type {Array
}\n */\n this.level = root;\n }\n\n /**\n * Initializes the state manager with the provided section, business unit, and nodes.\n *\n * @async\n * @param {string} section - The section to initialize.\n * @param {string} bu - The business unit associated with the section.\n * @param {string} nodes - A comma-separated string of nodes representing the initial state.\n * @returns {Promise} - A promise that resolves when initialization is complete.\n *\n * @example\n * // Example Usage:\n * await stateManager.initialize(\"radio-shows\", \"rts\", \"a9e7621504c6959e35c3ecbe7f6bed0446cdf8da,urn:rts:show:radio:9801398\");\n */\n async initialize(section, bu, nodes) {\n if (!section || !bu) {\n return;\n }\n\n const sectionIndex = this.#findSectionIndex(section);\n const nodeIndex = this.#findNodeIndex(this.level[sectionIndex].nodes, bu);\n\n await this.fetchNextState(sectionIndex, nodeIndex);\n await this.#processNodeString(nodes);\n }\n\n async #processNodeString(nodes) {\n for (const nodeStr of (nodes?.split(',') || [])) {\n const nodeIndex = this.#findNodeIndex(this.level[0].nodes, nodeStr);\n\n await this.fetchNextState(0, nodeIndex);\n }\n }\n\n /**\n * Fetches the next state based on the provided section index and node index.\n *\n * @param {number} sectionIndex - The index of the section.\n * @param {number} nodeIndex - The index of the node.\n * @returns {Promise} - A promise that resolves when the state is fetched.\n */\n async fetchNextState(sectionIndex, nodeIndex) {\n const section = this.level[sectionIndex];\n\n this.stack.push({ level: this.level, sectionIndex, nodeIndex });\n this.level = [await section.resolve(section.nodes[nodeIndex])];\n }\n\n /**\n * Fetches the previous state based on the provided stack index.\n *\n * @param {number} stackIndex - The index in the stack.\n */\n fetchPreviousState(stackIndex) {\n this.level = this.stack[stackIndex].level;\n this.stack.splice(stackIndex);\n }\n\n /**\n * Checks if the specified section at the given index is a leaf section.\n *\n * @param {number} sectionIndex - The index of the section.\n *\n * @returns {boolean} - True if the section is a leaf section, false otherwise.\n */\n isLeafSection(sectionIndex) {\n return this.level[sectionIndex]?.isLeaf();\n }\n\n /**\n * Retrieves the node at the specified section and node indices.\n *\n * @param {number} sectionIndex - The index of the section.\n * @param {number} nodeIndex - The index of the node.\n *\n * @returns {any} - The retrieved node.\n */\n retrieveNode(sectionIndex, nodeIndex) {\n return this.level[sectionIndex]?.nodes[nodeIndex];\n }\n\n /**\n * Gets the root level of the content tree.\n *\n * @returns {Array
} - The root level of the content tree.\n */\n get root() {\n return this.stack[0]?.level || this.level;\n }\n\n /**\n * Return the current state of this manager as query params that are parsable\n * by {@link #initialize}.\n *\n * @returns {{}|{bu: string, section: string, nodes?: string}} The current state as query params.\n */\n get params() {\n return ListsPageStateManager.#params(this.stack);\n }\n\n static #params(stack) {\n if (stack.length === 0) {\n return {};\n }\n\n const root = stack[0];\n const rootSection = root.level[root.sectionIndex];\n const nodes = stack.slice(1).map(n => {\n const node = n.level[n.sectionIndex].nodes[n.nodeIndex];\n\n return node.id || node.urn;\n });\n const params = {\n section: toKebabCase(rootSection.title),\n bu: rootSection.nodes[root.nodeIndex].toLowerCase()\n };\n\n if (nodes && nodes.length) {\n params.nodes = nodes.join(',');\n }\n\n return params;\n }\n\n paramsAt(sectionIndex, nodeIndex) {\n return ListsPageStateManager.#params(\n [...this.stack, { level: this.level, sectionIndex, nodeIndex }]\n );\n }\n\n /**\n * Finds the index of a section based on its title in kebab case.\n *\n * @private\n * @param {string} sectionStr - The section title to find.\n * @returns {number} - The index of the section.\n *\n * @example\n * const index = stateManager.#findSectionIndex(\"Products\");\n */\n #findSectionIndex(sectionStr) {\n const normalizedSectionStr = toKebabCase(sectionStr).toLowerCase();\n\n return this.level\n .map(s => toKebabCase(s.title).toLowerCase())\n .findIndex(title => title === normalizedSectionStr);\n }\n\n /**\n * Finds the index of a node based on its string representation.\n *\n * @private\n * @param {Array} nodes - The array of nodes to search.\n * @param {string} str - The string representation of the node to find.\n *\n * @returns {number} - The index of the node.\n */\n #findNodeIndex(nodes, str) {\n const normalizedStr = str.toLowerCase();\n\n return nodes\n .map(n => (n.urn || n.id || n.toString()).toLowerCase())\n .findIndex(n => n === normalizedStr);\n }\n}\n\nexport default ListsPageStateManager;\n","import ilProvider from '../../../utils/il-provider';\n\n/**\n * A section within the content hierarchy.\n *\n * @property {string} title - The title of the section node.\n * @property {string[]} values - An array of values associated with the section.\n * @property {function} resolve - A function that, when defined, resolves the next level\n * of the hierarchy asynchronously.\n */\nclass Section {\n /**\n * Creates an instance of Section.\n *\n * @param {Object} options - The options for creating the section.\n * @param {string} options.title - The title of the section.\n * @param {string[]} options.nodes - An array of nodes associated with the section.\n * @param {function} [options.resolve] - (Optional) A function that, when defined, resolves the next level\n * of the hierarchy asynchronously.\n * @param {function} [options.next] - (Optional) A function that, when defined, resolves the next level\n * of the hierarchy asynchronously.\n */\n constructor({\n title,\n nodes,\n resolve = undefined,\n next = undefined\n }) {\n this.title = title;\n this.nodes = nodes;\n this.resolve = resolve;\n this.next = next;\n }\n\n /**\n * Checks if the node is a leaf node (i.e., has no further levels to resolve).\n *\n * @returns {boolean} True if the node is a leaf node, false otherwise.\n */\n isLeaf() {\n return !this.resolve;\n }\n\n /**\n * Fetch more nodes from the next function if available.\n * @param signal\n * @returns {Promise<*>}\n */\n async fetchNext(signal = undefined) {\n if (!this.next) return;\n const data = await this.next(signal);\n\n this.next = data.next;\n this.nodes.push(...data.results);\n\n return data.results;\n }\n}\n\nconst toNodesAndNext = (data) => ({\n nodes: data.results,\n next: data.next\n});\n\n/**\n * An asynchronous tree-like structure that allows traversing the SRG SSR content\n * by category in a hierarchical fashion.\n *\n * @type {Section[]}\n */\nexport const listsSections = [\n new Section({\n title: 'TV Topics',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF', 'SWI'],\n resolve: async(bu) => new Section({\n title: `${bu} TV Topics`,\n nodes: await ilProvider.topics(bu),\n resolve: async(topic) => new Section({\n title: topic.title,\n ...toNodesAndNext(await ilProvider.latestByTopic(topic.urn))\n })\n })\n }),\n new Section({\n title: 'TV Shows',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF', 'SWI'],\n resolve: async(bu) => new Section({\n title: `${bu} TV Shows`,\n nodes: await ilProvider.shows(bu),\n resolve: async(show) => new Section({\n title: show.title,\n ...toNodesAndNext(await ilProvider.latestByShow(show.urn))\n })\n })\n }),\n new Section({\n title: 'TV Latest Videos',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} TV Latest Videos`,\n ...toNodesAndNext(await ilProvider.editorial(bu))\n })\n }),\n new Section({\n title: 'TV Livestreams',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} TV Livestreams`,\n nodes: await ilProvider.livestreams(bu)\n })\n }),\n new Section({\n title: 'Live web',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} Live web`,\n ...toNodesAndNext(await ilProvider.scheduledLivestream(bu))\n })\n }),\n new Section({\n title: 'Live center',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} Live center`,\n nodes: await ilProvider.livecenter(bu)\n })\n }),\n new Section({\n title: 'Radio Shows',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} Radio Channels`,\n nodes: await ilProvider.channels(bu),\n resolve: async(channel) => new Section({\n title: `${channel.title} Radio shows`,\n nodes: await ilProvider.radioShowByChannel(bu, channel.id),\n resolve: async(show) => new Section({\n title: show.title,\n ...toNodesAndNext(await ilProvider.latestByShow(show.urn))\n })\n })\n })\n }),\n new Section({\n title: 'Radio Livestreams',\n nodes: ['RSI', 'RTR', 'RTS', 'SRF'],\n resolve: async(bu) => new Section({\n title: `${bu} Radio Livestreams`,\n nodes: await ilProvider.livestreams(bu, 'audio')\n })\n })\n];\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport router from '../../../router/router';\nimport componentCSS from './lists-page.scss?inline';\nimport '../../../components/spinner/spinner-component';\nimport '../../../components/intersection-observer/intersection-observer-component';\nimport '../../../components/scroll-to-top/scroll-to-top-component';\nimport { map } from 'lit/directives/map.js';\nimport { when } from 'lit/directives/when.js';\nimport ListsPageStateManager from './lists-page-state-manager';\nimport { listsSections } from './lists-sections';\nimport Pillarbox from 'video.js';\n\nexport class ListsPage extends LitElement {\n static properties = {\n loading: { state: true, type: Boolean },\n stack: { state: true, type: Array },\n level: { state: true, type: Object },\n nextPage: { state: true, type: Function }\n };\n\n static styles = [\n theme, animations, unsafeCSS(componentCSS)\n ];\n\n /**\n * The abort controller for handling search cancellation.\n *\n * @private\n * @type {AbortController}\n */\n #abortController = new AbortController();\n /**\n * Keeps track of the state of the list page : the current level in display, as\n * well as the traversal stack.\n *\n * @private\n * @type {ListsPageStateManager}\n */\n #stateManager;\n /**\n * The reference to the query params changed event handler.\n *\n * @private\n * @type {Function}\n */\n #onQueryParamsChanged;\n\n constructor() {\n super();\n\n this.loading = false;\n this.#stateManager = new ListsPageStateManager(listsSections);\n this.#updateState();\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.#onQueryParamsChanged = async(event) => {\n if (!event.detail.popstate) return;\n\n this.abortFetch();\n const manager = new ListsPageStateManager(this.#stateManager.root);\n const { section, bu, nodes } = event.detail.queryParams;\n\n this.loading = true;\n try {\n await manager.initialize(section, bu, nodes);\n this.#stateManager = manager;\n this.#updateState();\n } finally {\n this.loading = false;\n }\n };\n router.addEventListener('queryparams', this.#onQueryParamsChanged);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.abortFetch();\n router.removeEventListener('queryparams', this.#onQueryParamsChanged);\n }\n\n firstUpdated(_changedProperties) {\n super.firstUpdated(_changedProperties);\n this.#onQueryParamsChanged(\n { detail: { popstate: true, queryParams: router.queryParams } }\n );\n }\n\n #updateState() {\n this.stack = [...this.#stateManager.stack];\n this.level = [...this.#stateManager.level];\n }\n\n /**\n * Navigates to the specified section and node in the content tree.\n *\n * @param {number} sectionIndex - The index of the section.\n * @param {number} nodeIndex - The index of the node.\n */\n async navigateTo(sectionIndex, nodeIndex) {\n if (!this.#stateManager.isLeafSection(sectionIndex)) {\n this.abortFetch();\n this.loading = true;\n try {\n await this.#stateManager.fetchNextState(sectionIndex, nodeIndex);\n this.#updateState();\n } finally {\n this.loading = false;\n }\n }\n }\n\n /**\n * Aborts the previous fetch by cancelling the associated abort signal and\n * creates a new abort controller for the next fetch.\n *\n * @returns {AbortSignal} - The abort signal associated with the new fetch.\n */\n abortFetch() {\n this.#abortController?.abort('New search launched');\n this.#abortController = new AbortController();\n\n return this.#abortController.signal;\n }\n\n #toMediaButtonParams(node) {\n return new URLSearchParams({ ...router.queryParams, src: node.urn, type: 'srgssr/urn' }).toString();\n }\n\n #renderMediaButton(node) {\n const date = new Intl.DateTimeFormat('fr-CH').format(new Date(node.date));\n const duration = Pillarbox.formatTime(node.duration / 1000);\n\n return html`\n \n
\n ${node.mediaType === 'VIDEO' ? 'movie' : 'audiotrack'}\n  | ${date} | ${duration}\n
\n
\n `;\n }\n\n #toLevelParams(sectionIdx, nodeIdx) {\n const params = this.#stateManager.paramsAt(sectionIdx, nodeIdx);\n\n return new URLSearchParams(params).toString();\n }\n\n #renderLevelButton(node, sectionIdx, nodeIdx) {\n return html`\n \n \n `;\n }\n\n async #nextPage(section) {\n const signal = this.abortFetch();\n\n await section.fetchNext(signal);\n this.#updateState();\n }\n\n #renderNodes(nodes, sectionIdx) {\n const firstSection = this.level[0];\n const hasIntesectionObserver = this.level.length === 1 && firstSection.next;\n\n return html`\n ${map(nodes, (node, idx) => html`\n ${when(node.mediaType, () => this.#renderMediaButton(node, idx), () => this.#renderLevelButton(node, sectionIdx, idx))}\n `)}\n ${when(hasIntesectionObserver, () => html`\n this.#nextPage(firstSection)}\">\n \n `)}\n `;\n }\n\n async #onSectionsClicked(e) {\n const button = e.target.closest('content-link');\n\n if (this.loading || !('nodeIdx' in button.dataset)) return;\n\n const sectionIndex = button.dataset.sectionIdx;\n const nodeIndex = button.dataset.nodeIdx;\n\n await this.navigateTo(sectionIndex, nodeIndex);\n }\n\n #renderResults() {\n return html`\n
e.target.classList.remove('fade-in')}\"\n @click=\"${this.#onSectionsClicked.bind(this)}\">\n ${map(this.level, (section, idx) => html`\n
\n

${section.title}

\n ${this.#renderNodes(section.nodes, idx)}\n
\n `)}\n
\n `;\n }\n\n #renderSpinner() {\n return html`\n e.target.classList.remove('slide-up-fade-in')}\">\n \n `;\n }\n\n #renderScrollToTopBtn() {\n return html`\n `;\n }\n\n #onNavigationClicked(e) {\n if (e.target.tagName.toLowerCase() !== 'button') return;\n this.abortFetch();\n this.#stateManager.fetchPreviousState(e.target.dataset.navigationIdx);\n this.#updateState();\n router.updateState(this.#stateManager.params, ['section', 'bu', 'nodes']);\n }\n\n #renderNavigation() {\n return html`\n
\n ${when(this.stack.length > 0, () => html`\n \n `)}\n ${map(this.stack.slice(1), (step, idx) => html`\n chevron_right\n \n `)}\n
\n `;\n }\n\n render() {\n const renderScrollBtn = this.level.length === 1 && this.level[0].next;\n\n return html`\n ${this.#renderNavigation()}\n ${when(this.loading, this.#renderSpinner.bind(this), this.#renderResults.bind(this))}\n ${when(renderScrollBtn, this.#renderScrollToTopBtn.bind(this))}\n `;\n }\n}\n\ncustomElements.define('lists-page', ListsPage);\nrouter.addRoute('lists', 'lists-page');\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport componentCSS from './search-bar-component.scss?inline';\nimport Pillarbox from 'video.js';\n\nconst DEFAULT_BU = 'rsi';\n\n/**\n * A search bar component for filtering content based on a query and business unit.\n *\n * @element search-bar\n *\n * @fires SearchBarComponent#change - Dispatched when the value of the search bar changes.\n */\nexport class SearchBarComponent extends LitElement {\n static properties = {\n bu: { type: String },\n query: { type: String }\n };\n\n static styles = [theme, animations, unsafeCSS(componentCSS)];\n\n constructor() {\n super();\n this.bu = DEFAULT_BU;\n this.query = '';\n }\n\n #handleSearchBarKeyUp() {\n this.query = this.renderRoot.querySelector('input').value;\n }\n\n #handleSelectChange(e) {\n this.bu = e.target.value;\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (['bu', 'query'].some(property => _changedProperties.has(property))) {\n const query = this.query ?? '';\n const bu = this.bu ?? DEFAULT_BU;\n\n /**\n * Custom event dispatched by SearchBarComponent when the value of the bar changes.\n *\n * @event SearchBarComponent#change\n * @type {CustomEvent}\n * @property {Object} detail - The event detail object.\n * @property {string} detail.query - The query on the search bar.a\n * @property {string} detail.bu - The selected bu.\n */\n this.dispatchEvent(new CustomEvent('change', {\n detail: { query, bu }\n }));\n }\n }\n\n #clearSearchBar() {\n this.query = '';\n this.renderRoot.querySelector('input').value = '';\n }\n\n render() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n \n \n
\n `;\n }\n}\n\ncustomElements.define('search-bar', SearchBarComponent);\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport router from '../../../router/router';\nimport componentCSS from './search-page.scss?inline';\nimport './search-bar-component';\nimport ilProvider from '../../../utils/il-provider';\nimport '../../../components/spinner/spinner-component';\nimport '../../../components/intersection-observer/intersection-observer-component';\nimport '../../../components/scroll-to-top/scroll-to-top-component';\nimport '../../../components/content-link/content-link-component';\nimport { map } from 'lit/directives/map.js';\nimport Pillarbox from 'video.js';\nimport { when } from 'lit/directives/when.js';\nimport { classMap } from 'lit/directives/class-map.js';\n\nexport class SearchPage extends LitElement {\n static properties = {\n loading: {\n state: true,\n type: Boolean\n },\n results: {\n state: true,\n type: Array\n },\n nextPage: {\n state: true,\n type: Function\n }\n };\n\n static styles = [\n theme, animations, unsafeCSS(componentCSS)\n ];\n\n /**\n * The abort controller for handling search cancellation.\n *\n * @private\n * @type {AbortController}\n */\n #abortController = new AbortController();\n /**\n * The reference to the query params changed event handler.\n *\n * @private\n * @type {Function}\n */\n #onQueryParamsChanged;\n\n constructor() {\n super();\n\n this.loading = false;\n this.results = null;\n this.nextPage = null;\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.#onQueryParamsChanged = () => {\n const searchBar = this.renderRoot.querySelector('search-bar');\n\n searchBar.query = router.queryParams.query ?? '';\n searchBar.bu = router.queryParams.bu ?? 'rsi';\n };\n router.addEventListener('queryparams', this.#onQueryParamsChanged);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.abortSearch();\n router.removeEventListener('queryparams', this.#onQueryParamsChanged);\n }\n\n async firstUpdated(_changedProperties) {\n super.firstUpdated(_changedProperties);\n const searchBar = this.renderRoot.querySelector('search-bar');\n\n this.#onQueryParamsChanged();\n await this.#search(searchBar.bu, searchBar.query);\n }\n\n async #onSearchBarChanged(bu, query) {\n router.updateState({ bu, ...(query ? { query } : {}) });\n await this.#search(bu, query);\n }\n\n /**\n * Performs a search based on the specified business unit and query. Performing\n * a new search will abort the previous search if it's ongoing and display a\n * loading spinner for the asynchronous operation.\n *\n * @param {string} bu - The selected business unit.\n * @param {string} query - The search query.\n *\n * @throws {Promise} - A rejected promise with the response object if\n * the fetch request for the search results fails.\n */\n async #search(bu, query) {\n const signal = this.abortSearch();\n\n if (!query) {\n [this.results, this.nextPage] = [null, null];\n\n return;\n }\n\n this.loading = true;\n try {\n const data = await ilProvider.search(bu, query, signal);\n\n [this.results, this.nextPage] = [data.results, data.next];\n } finally {\n this.loading = false;\n }\n }\n\n /**\n * Advances to the next page of search results and updates the UI accordingly.\n *\n * @throws {Promise} - A rejected promise with the response object if\n * the fetch request for the next page fails.\n */\n async #fetchNextPage() {\n const signal = this.abortSearch();\n const data = await this.nextPage(signal);\n\n this.nextPage = data.next;\n this.results = [...this.results, ...data.results];\n }\n\n /**\n * Aborts the previous search by cancelling the associated abort signal and\n * creates a new abort controller for the next search.\n *\n * @returns {AbortSignal} - The abort signal associated with the new search.\n */\n abortSearch() {\n this.#abortController?.abort('New search launched');\n this.#abortController = new AbortController();\n\n return this.#abortController.signal;\n }\n\n #toQueryParams(r) {\n return new URLSearchParams({\n ...router.queryParams,\n src: r.urn,\n type: 'srgssr/urn'\n }).toString();\n }\n\n #renderButton(r) {\n const date = new Intl.DateTimeFormat('fr-CH').format(new Date(r.date));\n const duration = Pillarbox.formatTime(r.duration / 1000);\n\n return html`\n \n
\n ${r.mediaType === 'VIDEO' ? 'movie' : 'audiotrack'}\n  | ${date} | ${duration}\n
\n
\n `;\n }\n\n #renderResults() {\n const resultsClassMap = {\n empty: this.results == null,\n 'no-results': this.results && this.results.length === 0,\n 'material-icons': !this.results || this.results.length === 0\n };\n\n return html`\n
e.target.classList.remove('fade-in')}\">\n ${map(this.results ?? [], this.#renderButton.bind(this))}\n ${when(this.nextPage, () => html`\n \n \n `)}\n
\n `;\n }\n\n #renderSpinner() {\n return html`\n e.target.classList.remove('slide-up-fade-in')}\">\n \n `;\n }\n\n #renderScrollToTopBtn() {\n return html`\n `;\n }\n\n render() {\n return html`\n this.#onSearchBarChanged(e.detail.bu, e.detail.query)}\">\n \n\n \n ${when(this.loading, this.#renderSpinner.bind(this), this.#renderResults.bind(this))}\n ${when(this.results?.length > 0, this.#renderScrollToTopBtn.bind(this))}\n `;\n }\n}\n\ncustomElements.define('search-page', SearchPage);\nrouter.addRoute('search', 'search-page');\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport { theme } from '../../theme/theme';\nimport componentCSS from './toggle-switch-component.scss?inline';\n\n/**\n * Custom element representing a toggle switch.\n *\n * @element toggle-switch\n *\n * @csspart switch - The container for the toggle switch.\n * @csspart slider - The slider button of the toggle switch.\n *\n * @prop {Boolean} checked - Reflects the current state of the toggle switch.\n * @prop {Boolean} disabled - Indicates whether the toggle switch is disabled.\n *\n * @attribute {String} role - ARIA role for accessibility, set to 'switch'.\n * @attribute {String} tabindex - ARIA tabindex for accessibility, set to '0'.\n *\n * @fires ToggleSwitchComponent#change\n *\n * @example\n * \n *\n * @customElement\n */\nexport class ToggleSwitchComponent extends LitElement {\n static formAssociated = true;\n static properties = {\n checked: { type: Boolean, reflect: true },\n disabled: { type: Boolean }\n };\n\n constructor() {\n super();\n this.checked = false;\n this.disabled = false;\n }\n\n static styles = [\n theme, unsafeCSS(componentCSS)\n ];\n\n #onKeyDown = (e) => {\n if (e.key === ' ') {\n e.preventDefault();\n this.toggle();\n }\n };\n\n #onClick = () => {\n this.toggle();\n };\n\n connectedCallback() {\n super.connectedCallback();\n\n if (!this.hasAttribute('role')) {\n this.setAttribute('role', 'switch');\n }\n\n if (!this.hasAttribute('tabindex')) {\n this.setAttribute('tabindex', '0');\n }\n\n this.addEventListener('click', this.#onClick);\n this.addEventListener('keydown', this.#onKeyDown);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n\n this.removeEventListener('click', this.#onClick);\n this.removeEventListener('keydown', this.#onKeyDown);\n }\n\n toggle(force) {\n if (!this.disabled) {\n this.checked = force ?? !this.checked;\n }\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (_changedProperties.has('checked')) {\n this.setAttribute('aria-checked', this.checked.toString());\n /**\n * Custom event dispatched when the state of the toggle switch changes.\n *\n * @event ToggleSwitchComponent#change\n * @type {CustomEvent}\n * @property {Object} detail - The event detail object.\n * @property {Boolean} detail.checked - The new state of the toggle switch.\n */\n this.dispatchEvent(new CustomEvent('change', { detail: { checked: this.checked } }));\n }\n }\n\n render() {\n return html`\n
\n
\n
\n `;\n }\n}\n\ncustomElements.define('toggle-switch', ToggleSwitchComponent);\n","import router from '../../../router/router';\nimport { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport '../../../components/toggle-switch/toggle-switch-component.js';\nimport PreferencesProvider from './preferences-provider';\nimport componentCss from './settings-page.scss?inline';\nimport ilProvider from '../../../utils/il-provider.js';\n\n/**\n * A web component that represents the settings page.\n *\n * @element settings-page\n */\nexport class SettingsPage extends LitElement {\n static properties = {\n autoplay: { type: Boolean, state: true },\n muted: { type: Boolean, state: true },\n debug: { type: Boolean, state: true },\n dataProviderHost: { type: String, state: true }\n };\n\n static styles = [theme, animations, unsafeCSS(componentCss)];\n\n constructor() {\n super();\n const preferences = PreferencesProvider.loadPreferences();\n\n this.autoplay = preferences.autoplay ?? false;\n this.muted = preferences.muted ?? true;\n this.debug = preferences.debug ?? false;\n this.dataProviderHost = preferences.dataProviderHost;\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n const preferences = PreferencesProvider.loadPreferences();\n\n [..._changedProperties.keys()]\n .filter(property => ['autoplay', 'muted', 'debug', 'dataProviderHost'].includes(property))\n .forEach((property) => {\n preferences[property] = this[property];\n });\n\n PreferencesProvider.savePreferences(preferences);\n\n if (_changedProperties.has('debug')) {\n router.replaceState(this.debug ? { debug: 'true' } : {});\n }\n\n if (_changedProperties.has('dataProviderHost')) {\n ilProvider.host = this.dataProviderHost;\n }\n }\n\n #renderToggle(property, label) {\n return html`\n
\n \n {\n this[property] = e.detail.checked;\n }}\">\n \n
\n `;\n }\n\n #renderInput(property, label) {\n return html`\n
\n \n {\n this[property] = e.target.value === '' ? undefined : e.target.value;\n }}\">\n
\n `;\n }\n\n render() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n

Player Settings

\n ${this.#renderToggle('autoplay', 'Autoplay')}\n ${this.#renderToggle('muted', 'Player starts muted')}\n ${this.#renderToggle('debug', 'Enable debug mode')}\n ${this.#renderInput('dataProviderHost', 'Data provider host')}\n
\n `;\n }\n}\n\ncustomElements.define('settings-page', SettingsPage);\nrouter.addRoute('settings', 'settings-page');\n","/* eslint-disable no-multi-assign */\n\nfunction deepFreeze(obj) {\n if (obj instanceof Map) {\n obj.clear =\n obj.delete =\n obj.set =\n function () {\n throw new Error('map is read-only');\n };\n } else if (obj instanceof Set) {\n obj.add =\n obj.clear =\n obj.delete =\n function () {\n throw new Error('set is read-only');\n };\n }\n\n // Freeze self\n Object.freeze(obj);\n\n Object.getOwnPropertyNames(obj).forEach((name) => {\n const prop = obj[name];\n const type = typeof prop;\n\n // Freeze prop if it is an object or function and also not already frozen\n if ((type === 'object' || type === 'function') && !Object.isFrozen(prop)) {\n deepFreeze(prop);\n }\n });\n\n return obj;\n}\n\n/** @typedef {import('highlight.js').CallbackResponse} CallbackResponse */\n/** @typedef {import('highlight.js').CompiledMode} CompiledMode */\n/** @implements CallbackResponse */\n\nclass Response {\n /**\n * @param {CompiledMode} mode\n */\n constructor(mode) {\n // eslint-disable-next-line no-undefined\n if (mode.data === undefined) mode.data = {};\n\n this.data = mode.data;\n this.isMatchIgnored = false;\n }\n\n ignoreMatch() {\n this.isMatchIgnored = true;\n }\n}\n\n/**\n * @param {string} value\n * @returns {string}\n */\nfunction escapeHTML(value) {\n return value\n .replace(/&/g, '&')\n .replace(//g, '>')\n .replace(/\"/g, '"')\n .replace(/'/g, ''');\n}\n\n/**\n * performs a shallow merge of multiple objects into one\n *\n * @template T\n * @param {T} original\n * @param {Record[]} objects\n * @returns {T} a single new object\n */\nfunction inherit$1(original, ...objects) {\n /** @type Record */\n const result = Object.create(null);\n\n for (const key in original) {\n result[key] = original[key];\n }\n objects.forEach(function(obj) {\n for (const key in obj) {\n result[key] = obj[key];\n }\n });\n return /** @type {T} */ (result);\n}\n\n/**\n * @typedef {object} Renderer\n * @property {(text: string) => void} addText\n * @property {(node: Node) => void} openNode\n * @property {(node: Node) => void} closeNode\n * @property {() => string} value\n */\n\n/** @typedef {{scope?: string, language?: string, sublanguage?: boolean}} Node */\n/** @typedef {{walk: (r: Renderer) => void}} Tree */\n/** */\n\nconst SPAN_CLOSE = '';\n\n/**\n * Determines if a node needs to be wrapped in \n *\n * @param {Node} node */\nconst emitsWrappingTags = (node) => {\n // rarely we can have a sublanguage where language is undefined\n // TODO: track down why\n return !!node.scope;\n};\n\n/**\n *\n * @param {string} name\n * @param {{prefix:string}} options\n */\nconst scopeToCSSClass = (name, { prefix }) => {\n // sub-language\n if (name.startsWith(\"language:\")) {\n return name.replace(\"language:\", \"language-\");\n }\n // tiered scope: comment.line\n if (name.includes(\".\")) {\n const pieces = name.split(\".\");\n return [\n `${prefix}${pieces.shift()}`,\n ...(pieces.map((x, i) => `${x}${\"_\".repeat(i + 1)}`))\n ].join(\" \");\n }\n // simple scope\n return `${prefix}${name}`;\n};\n\n/** @type {Renderer} */\nclass HTMLRenderer {\n /**\n * Creates a new HTMLRenderer\n *\n * @param {Tree} parseTree - the parse tree (must support `walk` API)\n * @param {{classPrefix: string}} options\n */\n constructor(parseTree, options) {\n this.buffer = \"\";\n this.classPrefix = options.classPrefix;\n parseTree.walk(this);\n }\n\n /**\n * Adds texts to the output stream\n *\n * @param {string} text */\n addText(text) {\n this.buffer += escapeHTML(text);\n }\n\n /**\n * Adds a node open to the output stream (if needed)\n *\n * @param {Node} node */\n openNode(node) {\n if (!emitsWrappingTags(node)) return;\n\n const className = scopeToCSSClass(node.scope,\n { prefix: this.classPrefix });\n this.span(className);\n }\n\n /**\n * Adds a node close to the output stream (if needed)\n *\n * @param {Node} node */\n closeNode(node) {\n if (!emitsWrappingTags(node)) return;\n\n this.buffer += SPAN_CLOSE;\n }\n\n /**\n * returns the accumulated buffer\n */\n value() {\n return this.buffer;\n }\n\n // helpers\n\n /**\n * Builds a span element\n *\n * @param {string} className */\n span(className) {\n this.buffer += ``;\n }\n}\n\n/** @typedef {{scope?: string, language?: string, children: Node[]} | string} Node */\n/** @typedef {{scope?: string, language?: string, children: Node[]} } DataNode */\n/** @typedef {import('highlight.js').Emitter} Emitter */\n/** */\n\n/** @returns {DataNode} */\nconst newNode = (opts = {}) => {\n /** @type DataNode */\n const result = { children: [] };\n Object.assign(result, opts);\n return result;\n};\n\nclass TokenTree {\n constructor() {\n /** @type DataNode */\n this.rootNode = newNode();\n this.stack = [this.rootNode];\n }\n\n get top() {\n return this.stack[this.stack.length - 1];\n }\n\n get root() { return this.rootNode; }\n\n /** @param {Node} node */\n add(node) {\n this.top.children.push(node);\n }\n\n /** @param {string} scope */\n openNode(scope) {\n /** @type Node */\n const node = newNode({ scope });\n this.add(node);\n this.stack.push(node);\n }\n\n closeNode() {\n if (this.stack.length > 1) {\n return this.stack.pop();\n }\n // eslint-disable-next-line no-undefined\n return undefined;\n }\n\n closeAllNodes() {\n while (this.closeNode());\n }\n\n toJSON() {\n return JSON.stringify(this.rootNode, null, 4);\n }\n\n /**\n * @typedef { import(\"./html_renderer\").Renderer } Renderer\n * @param {Renderer} builder\n */\n walk(builder) {\n // this does not\n return this.constructor._walk(builder, this.rootNode);\n // this works\n // return TokenTree._walk(builder, this.rootNode);\n }\n\n /**\n * @param {Renderer} builder\n * @param {Node} node\n */\n static _walk(builder, node) {\n if (typeof node === \"string\") {\n builder.addText(node);\n } else if (node.children) {\n builder.openNode(node);\n node.children.forEach((child) => this._walk(builder, child));\n builder.closeNode(node);\n }\n return builder;\n }\n\n /**\n * @param {Node} node\n */\n static _collapse(node) {\n if (typeof node === \"string\") return;\n if (!node.children) return;\n\n if (node.children.every(el => typeof el === \"string\")) {\n // node.text = node.children.join(\"\");\n // delete node.children;\n node.children = [node.children.join(\"\")];\n } else {\n node.children.forEach((child) => {\n TokenTree._collapse(child);\n });\n }\n }\n}\n\n/**\n Currently this is all private API, but this is the minimal API necessary\n that an Emitter must implement to fully support the parser.\n\n Minimal interface:\n\n - addText(text)\n - __addSublanguage(emitter, subLanguageName)\n - startScope(scope)\n - endScope()\n - finalize()\n - toHTML()\n\n*/\n\n/**\n * @implements {Emitter}\n */\nclass TokenTreeEmitter extends TokenTree {\n /**\n * @param {*} options\n */\n constructor(options) {\n super();\n this.options = options;\n }\n\n /**\n * @param {string} text\n */\n addText(text) {\n if (text === \"\") { return; }\n\n this.add(text);\n }\n\n /** @param {string} scope */\n startScope(scope) {\n this.openNode(scope);\n }\n\n endScope() {\n this.closeNode();\n }\n\n /**\n * @param {Emitter & {root: DataNode}} emitter\n * @param {string} name\n */\n __addSublanguage(emitter, name) {\n /** @type DataNode */\n const node = emitter.root;\n if (name) node.scope = `language:${name}`;\n\n this.add(node);\n }\n\n toHTML() {\n const renderer = new HTMLRenderer(this, this.options);\n return renderer.value();\n }\n\n finalize() {\n this.closeAllNodes();\n return true;\n }\n}\n\n/**\n * @param {string} value\n * @returns {RegExp}\n * */\n\n/**\n * @param {RegExp | string } re\n * @returns {string}\n */\nfunction source(re) {\n if (!re) return null;\n if (typeof re === \"string\") return re;\n\n return re.source;\n}\n\n/**\n * @param {RegExp | string } re\n * @returns {string}\n */\nfunction lookahead(re) {\n return concat('(?=', re, ')');\n}\n\n/**\n * @param {RegExp | string } re\n * @returns {string}\n */\nfunction anyNumberOfTimes(re) {\n return concat('(?:', re, ')*');\n}\n\n/**\n * @param {RegExp | string } re\n * @returns {string}\n */\nfunction optional(re) {\n return concat('(?:', re, ')?');\n}\n\n/**\n * @param {...(RegExp | string) } args\n * @returns {string}\n */\nfunction concat(...args) {\n const joined = args.map((x) => source(x)).join(\"\");\n return joined;\n}\n\n/**\n * @param { Array } args\n * @returns {object}\n */\nfunction stripOptionsFromArgs(args) {\n const opts = args[args.length - 1];\n\n if (typeof opts === 'object' && opts.constructor === Object) {\n args.splice(args.length - 1, 1);\n return opts;\n } else {\n return {};\n }\n}\n\n/** @typedef { {capture?: boolean} } RegexEitherOptions */\n\n/**\n * Any of the passed expresssions may match\n *\n * Creates a huge this | this | that | that match\n * @param {(RegExp | string)[] | [...(RegExp | string)[], RegexEitherOptions]} args\n * @returns {string}\n */\nfunction either(...args) {\n /** @type { object & {capture?: boolean} } */\n const opts = stripOptionsFromArgs(args);\n const joined = '('\n + (opts.capture ? \"\" : \"?:\")\n + args.map((x) => source(x)).join(\"|\") + \")\";\n return joined;\n}\n\n/**\n * @param {RegExp | string} re\n * @returns {number}\n */\nfunction countMatchGroups(re) {\n return (new RegExp(re.toString() + '|')).exec('').length - 1;\n}\n\n/**\n * Does lexeme start with a regular expression match at the beginning\n * @param {RegExp} re\n * @param {string} lexeme\n */\nfunction startsWith(re, lexeme) {\n const match = re && re.exec(lexeme);\n return match && match.index === 0;\n}\n\n// BACKREF_RE matches an open parenthesis or backreference. To avoid\n// an incorrect parse, it additionally matches the following:\n// - [...] elements, where the meaning of parentheses and escapes change\n// - other escape sequences, so we do not misparse escape sequences as\n// interesting elements\n// - non-matching or lookahead parentheses, which do not capture. These\n// follow the '(' with a '?'.\nconst BACKREF_RE = /\\[(?:[^\\\\\\]]|\\\\.)*\\]|\\(\\??|\\\\([1-9][0-9]*)|\\\\./;\n\n// **INTERNAL** Not intended for outside usage\n// join logically computes regexps.join(separator), but fixes the\n// backreferences so they continue to match.\n// it also places each individual regular expression into it's own\n// match group, keeping track of the sequencing of those match groups\n// is currently an exercise for the caller. :-)\n/**\n * @param {(string | RegExp)[]} regexps\n * @param {{joinWith: string}} opts\n * @returns {string}\n */\nfunction _rewriteBackreferences(regexps, { joinWith }) {\n let numCaptures = 0;\n\n return regexps.map((regex) => {\n numCaptures += 1;\n const offset = numCaptures;\n let re = source(regex);\n let out = '';\n\n while (re.length > 0) {\n const match = BACKREF_RE.exec(re);\n if (!match) {\n out += re;\n break;\n }\n out += re.substring(0, match.index);\n re = re.substring(match.index + match[0].length);\n if (match[0][0] === '\\\\' && match[1]) {\n // Adjust the backreference.\n out += '\\\\' + String(Number(match[1]) + offset);\n } else {\n out += match[0];\n if (match[0] === '(') {\n numCaptures++;\n }\n }\n }\n return out;\n }).map(re => `(${re})`).join(joinWith);\n}\n\n/** @typedef {import('highlight.js').Mode} Mode */\n/** @typedef {import('highlight.js').ModeCallback} ModeCallback */\n\n// Common regexps\nconst MATCH_NOTHING_RE = /\\b\\B/;\nconst IDENT_RE = '[a-zA-Z]\\\\w*';\nconst UNDERSCORE_IDENT_RE = '[a-zA-Z_]\\\\w*';\nconst NUMBER_RE = '\\\\b\\\\d+(\\\\.\\\\d+)?';\nconst C_NUMBER_RE = '(-?)(\\\\b0[xX][a-fA-F0-9]+|(\\\\b\\\\d+(\\\\.\\\\d*)?|\\\\.\\\\d+)([eE][-+]?\\\\d+)?)'; // 0x..., 0..., decimal, float\nconst BINARY_NUMBER_RE = '\\\\b(0b[01]+)'; // 0b...\nconst RE_STARTERS_RE = '!|!=|!==|%|%=|&|&&|&=|\\\\*|\\\\*=|\\\\+|\\\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\\\?|\\\\[|\\\\{|\\\\(|\\\\^|\\\\^=|\\\\||\\\\|=|\\\\|\\\\||~';\n\n/**\n* @param { Partial & {binary?: string | RegExp} } opts\n*/\nconst SHEBANG = (opts = {}) => {\n const beginShebang = /^#![ ]*\\//;\n if (opts.binary) {\n opts.begin = concat(\n beginShebang,\n /.*\\b/,\n opts.binary,\n /\\b.*/);\n }\n return inherit$1({\n scope: 'meta',\n begin: beginShebang,\n end: /$/,\n relevance: 0,\n /** @type {ModeCallback} */\n \"on:begin\": (m, resp) => {\n if (m.index !== 0) resp.ignoreMatch();\n }\n }, opts);\n};\n\n// Common modes\nconst BACKSLASH_ESCAPE = {\n begin: '\\\\\\\\[\\\\s\\\\S]', relevance: 0\n};\nconst APOS_STRING_MODE = {\n scope: 'string',\n begin: '\\'',\n end: '\\'',\n illegal: '\\\\n',\n contains: [BACKSLASH_ESCAPE]\n};\nconst QUOTE_STRING_MODE = {\n scope: 'string',\n begin: '\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [BACKSLASH_ESCAPE]\n};\nconst PHRASAL_WORDS_MODE = {\n begin: /\\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\\b/\n};\n/**\n * Creates a comment mode\n *\n * @param {string | RegExp} begin\n * @param {string | RegExp} end\n * @param {Mode | {}} [modeOptions]\n * @returns {Partial}\n */\nconst COMMENT = function(begin, end, modeOptions = {}) {\n const mode = inherit$1(\n {\n scope: 'comment',\n begin,\n end,\n contains: []\n },\n modeOptions\n );\n mode.contains.push({\n scope: 'doctag',\n // hack to avoid the space from being included. the space is necessary to\n // match here to prevent the plain text rule below from gobbling up doctags\n begin: '[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)',\n end: /(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,\n excludeBegin: true,\n relevance: 0\n });\n const ENGLISH_WORD = either(\n // list of common 1 and 2 letter words in English\n \"I\",\n \"a\",\n \"is\",\n \"so\",\n \"us\",\n \"to\",\n \"at\",\n \"if\",\n \"in\",\n \"it\",\n \"on\",\n // note: this is not an exhaustive list of contractions, just popular ones\n /[A-Za-z]+['](d|ve|re|ll|t|s|n)/, // contractions - can't we'd they're let's, etc\n /[A-Za-z]+[-][a-z]+/, // `no-way`, etc.\n /[A-Za-z][a-z]{2,}/ // allow capitalized words at beginning of sentences\n );\n // looking like plain text, more likely to be a comment\n mode.contains.push(\n {\n // TODO: how to include \", (, ) without breaking grammars that use these for\n // comment delimiters?\n // begin: /[ ]+([()\"]?([A-Za-z'-]{3,}|is|a|I|so|us|[tT][oO]|at|if|in|it|on)[.]?[()\":]?([.][ ]|[ ]|\\))){3}/\n // ---\n\n // this tries to find sequences of 3 english words in a row (without any\n // \"programming\" type syntax) this gives us a strong signal that we've\n // TRULY found a comment - vs perhaps scanning with the wrong language.\n // It's possible to find something that LOOKS like the start of the\n // comment - but then if there is no readable text - good chance it is a\n // false match and not a comment.\n //\n // for a visual example please see:\n // https://github.com/highlightjs/highlight.js/issues/2827\n\n begin: concat(\n /[ ]+/, // necessary to prevent us gobbling up doctags like /* @author Bob Mcgill */\n '(',\n ENGLISH_WORD,\n /[.]?[:]?([.][ ]|[ ])/,\n '){3}') // look for 3 words in a row\n }\n );\n return mode;\n};\nconst C_LINE_COMMENT_MODE = COMMENT('//', '$');\nconst C_BLOCK_COMMENT_MODE = COMMENT('/\\\\*', '\\\\*/');\nconst HASH_COMMENT_MODE = COMMENT('#', '$');\nconst NUMBER_MODE = {\n scope: 'number',\n begin: NUMBER_RE,\n relevance: 0\n};\nconst C_NUMBER_MODE = {\n scope: 'number',\n begin: C_NUMBER_RE,\n relevance: 0\n};\nconst BINARY_NUMBER_MODE = {\n scope: 'number',\n begin: BINARY_NUMBER_RE,\n relevance: 0\n};\nconst REGEXP_MODE = {\n scope: \"regexp\",\n begin: /\\/(?=[^/\\n]*\\/)/,\n end: /\\/[gimuy]*/,\n contains: [\n BACKSLASH_ESCAPE,\n {\n begin: /\\[/,\n end: /\\]/,\n relevance: 0,\n contains: [BACKSLASH_ESCAPE]\n }\n ]\n};\nconst TITLE_MODE = {\n scope: 'title',\n begin: IDENT_RE,\n relevance: 0\n};\nconst UNDERSCORE_TITLE_MODE = {\n scope: 'title',\n begin: UNDERSCORE_IDENT_RE,\n relevance: 0\n};\nconst METHOD_GUARD = {\n // excludes method names from keyword processing\n begin: '\\\\.\\\\s*' + UNDERSCORE_IDENT_RE,\n relevance: 0\n};\n\n/**\n * Adds end same as begin mechanics to a mode\n *\n * Your mode must include at least a single () match group as that first match\n * group is what is used for comparison\n * @param {Partial} mode\n */\nconst END_SAME_AS_BEGIN = function(mode) {\n return Object.assign(mode,\n {\n /** @type {ModeCallback} */\n 'on:begin': (m, resp) => { resp.data._beginMatch = m[1]; },\n /** @type {ModeCallback} */\n 'on:end': (m, resp) => { if (resp.data._beginMatch !== m[1]) resp.ignoreMatch(); }\n });\n};\n\nvar MODES = /*#__PURE__*/Object.freeze({\n __proto__: null,\n APOS_STRING_MODE: APOS_STRING_MODE,\n BACKSLASH_ESCAPE: BACKSLASH_ESCAPE,\n BINARY_NUMBER_MODE: BINARY_NUMBER_MODE,\n BINARY_NUMBER_RE: BINARY_NUMBER_RE,\n COMMENT: COMMENT,\n C_BLOCK_COMMENT_MODE: C_BLOCK_COMMENT_MODE,\n C_LINE_COMMENT_MODE: C_LINE_COMMENT_MODE,\n C_NUMBER_MODE: C_NUMBER_MODE,\n C_NUMBER_RE: C_NUMBER_RE,\n END_SAME_AS_BEGIN: END_SAME_AS_BEGIN,\n HASH_COMMENT_MODE: HASH_COMMENT_MODE,\n IDENT_RE: IDENT_RE,\n MATCH_NOTHING_RE: MATCH_NOTHING_RE,\n METHOD_GUARD: METHOD_GUARD,\n NUMBER_MODE: NUMBER_MODE,\n NUMBER_RE: NUMBER_RE,\n PHRASAL_WORDS_MODE: PHRASAL_WORDS_MODE,\n QUOTE_STRING_MODE: QUOTE_STRING_MODE,\n REGEXP_MODE: REGEXP_MODE,\n RE_STARTERS_RE: RE_STARTERS_RE,\n SHEBANG: SHEBANG,\n TITLE_MODE: TITLE_MODE,\n UNDERSCORE_IDENT_RE: UNDERSCORE_IDENT_RE,\n UNDERSCORE_TITLE_MODE: UNDERSCORE_TITLE_MODE\n});\n\n/**\n@typedef {import('highlight.js').CallbackResponse} CallbackResponse\n@typedef {import('highlight.js').CompilerExt} CompilerExt\n*/\n\n// Grammar extensions / plugins\n// See: https://github.com/highlightjs/highlight.js/issues/2833\n\n// Grammar extensions allow \"syntactic sugar\" to be added to the grammar modes\n// without requiring any underlying changes to the compiler internals.\n\n// `compileMatch` being the perfect small example of now allowing a grammar\n// author to write `match` when they desire to match a single expression rather\n// than being forced to use `begin`. The extension then just moves `match` into\n// `begin` when it runs. Ie, no features have been added, but we've just made\n// the experience of writing (and reading grammars) a little bit nicer.\n\n// ------\n\n// TODO: We need negative look-behind support to do this properly\n/**\n * Skip a match if it has a preceding dot\n *\n * This is used for `beginKeywords` to prevent matching expressions such as\n * `bob.keyword.do()`. The mode compiler automatically wires this up as a\n * special _internal_ 'on:begin' callback for modes with `beginKeywords`\n * @param {RegExpMatchArray} match\n * @param {CallbackResponse} response\n */\nfunction skipIfHasPrecedingDot(match, response) {\n const before = match.input[match.index - 1];\n if (before === \".\") {\n response.ignoreMatch();\n }\n}\n\n/**\n *\n * @type {CompilerExt}\n */\nfunction scopeClassName(mode, _parent) {\n // eslint-disable-next-line no-undefined\n if (mode.className !== undefined) {\n mode.scope = mode.className;\n delete mode.className;\n }\n}\n\n/**\n * `beginKeywords` syntactic sugar\n * @type {CompilerExt}\n */\nfunction beginKeywords(mode, parent) {\n if (!parent) return;\n if (!mode.beginKeywords) return;\n\n // for languages with keywords that include non-word characters checking for\n // a word boundary is not sufficient, so instead we check for a word boundary\n // or whitespace - this does no harm in any case since our keyword engine\n // doesn't allow spaces in keywords anyways and we still check for the boundary\n // first\n mode.begin = '\\\\b(' + mode.beginKeywords.split(' ').join('|') + ')(?!\\\\.)(?=\\\\b|\\\\s)';\n mode.__beforeBegin = skipIfHasPrecedingDot;\n mode.keywords = mode.keywords || mode.beginKeywords;\n delete mode.beginKeywords;\n\n // prevents double relevance, the keywords themselves provide\n // relevance, the mode doesn't need to double it\n // eslint-disable-next-line no-undefined\n if (mode.relevance === undefined) mode.relevance = 0;\n}\n\n/**\n * Allow `illegal` to contain an array of illegal values\n * @type {CompilerExt}\n */\nfunction compileIllegal(mode, _parent) {\n if (!Array.isArray(mode.illegal)) return;\n\n mode.illegal = either(...mode.illegal);\n}\n\n/**\n * `match` to match a single expression for readability\n * @type {CompilerExt}\n */\nfunction compileMatch(mode, _parent) {\n if (!mode.match) return;\n if (mode.begin || mode.end) throw new Error(\"begin & end are not supported with match\");\n\n mode.begin = mode.match;\n delete mode.match;\n}\n\n/**\n * provides the default 1 relevance to all modes\n * @type {CompilerExt}\n */\nfunction compileRelevance(mode, _parent) {\n // eslint-disable-next-line no-undefined\n if (mode.relevance === undefined) mode.relevance = 1;\n}\n\n// allow beforeMatch to act as a \"qualifier\" for the match\n// the full match begin must be [beforeMatch][begin]\nconst beforeMatchExt = (mode, parent) => {\n if (!mode.beforeMatch) return;\n // starts conflicts with endsParent which we need to make sure the child\n // rule is not matched multiple times\n if (mode.starts) throw new Error(\"beforeMatch cannot be used with starts\");\n\n const originalMode = Object.assign({}, mode);\n Object.keys(mode).forEach((key) => { delete mode[key]; });\n\n mode.keywords = originalMode.keywords;\n mode.begin = concat(originalMode.beforeMatch, lookahead(originalMode.begin));\n mode.starts = {\n relevance: 0,\n contains: [\n Object.assign(originalMode, { endsParent: true })\n ]\n };\n mode.relevance = 0;\n\n delete originalMode.beforeMatch;\n};\n\n// keywords that should have no default relevance value\nconst COMMON_KEYWORDS = [\n 'of',\n 'and',\n 'for',\n 'in',\n 'not',\n 'or',\n 'if',\n 'then',\n 'parent', // common variable name\n 'list', // common variable name\n 'value' // common variable name\n];\n\nconst DEFAULT_KEYWORD_SCOPE = \"keyword\";\n\n/**\n * Given raw keywords from a language definition, compile them.\n *\n * @param {string | Record | Array} rawKeywords\n * @param {boolean} caseInsensitive\n */\nfunction compileKeywords(rawKeywords, caseInsensitive, scopeName = DEFAULT_KEYWORD_SCOPE) {\n /** @type {import(\"highlight.js/private\").KeywordDict} */\n const compiledKeywords = Object.create(null);\n\n // input can be a string of keywords, an array of keywords, or a object with\n // named keys representing scopeName (which can then point to a string or array)\n if (typeof rawKeywords === 'string') {\n compileList(scopeName, rawKeywords.split(\" \"));\n } else if (Array.isArray(rawKeywords)) {\n compileList(scopeName, rawKeywords);\n } else {\n Object.keys(rawKeywords).forEach(function(scopeName) {\n // collapse all our objects back into the parent object\n Object.assign(\n compiledKeywords,\n compileKeywords(rawKeywords[scopeName], caseInsensitive, scopeName)\n );\n });\n }\n return compiledKeywords;\n\n // ---\n\n /**\n * Compiles an individual list of keywords\n *\n * Ex: \"for if when while|5\"\n *\n * @param {string} scopeName\n * @param {Array} keywordList\n */\n function compileList(scopeName, keywordList) {\n if (caseInsensitive) {\n keywordList = keywordList.map(x => x.toLowerCase());\n }\n keywordList.forEach(function(keyword) {\n const pair = keyword.split('|');\n compiledKeywords[pair[0]] = [scopeName, scoreForKeyword(pair[0], pair[1])];\n });\n }\n}\n\n/**\n * Returns the proper score for a given keyword\n *\n * Also takes into account comment keywords, which will be scored 0 UNLESS\n * another score has been manually assigned.\n * @param {string} keyword\n * @param {string} [providedScore]\n */\nfunction scoreForKeyword(keyword, providedScore) {\n // manual scores always win over common keywords\n // so you can force a score of 1 if you really insist\n if (providedScore) {\n return Number(providedScore);\n }\n\n return commonKeyword(keyword) ? 0 : 1;\n}\n\n/**\n * Determines if a given keyword is common or not\n *\n * @param {string} keyword */\nfunction commonKeyword(keyword) {\n return COMMON_KEYWORDS.includes(keyword.toLowerCase());\n}\n\n/*\n\nFor the reasoning behind this please see:\nhttps://github.com/highlightjs/highlight.js/issues/2880#issuecomment-747275419\n\n*/\n\n/**\n * @type {Record}\n */\nconst seenDeprecations = {};\n\n/**\n * @param {string} message\n */\nconst error = (message) => {\n console.error(message);\n};\n\n/**\n * @param {string} message\n * @param {any} args\n */\nconst warn = (message, ...args) => {\n console.log(`WARN: ${message}`, ...args);\n};\n\n/**\n * @param {string} version\n * @param {string} message\n */\nconst deprecated = (version, message) => {\n if (seenDeprecations[`${version}/${message}`]) return;\n\n console.log(`Deprecated as of ${version}. ${message}`);\n seenDeprecations[`${version}/${message}`] = true;\n};\n\n/* eslint-disable no-throw-literal */\n\n/**\n@typedef {import('highlight.js').CompiledMode} CompiledMode\n*/\n\nconst MultiClassError = new Error();\n\n/**\n * Renumbers labeled scope names to account for additional inner match\n * groups that otherwise would break everything.\n *\n * Lets say we 3 match scopes:\n *\n * { 1 => ..., 2 => ..., 3 => ... }\n *\n * So what we need is a clean match like this:\n *\n * (a)(b)(c) => [ \"a\", \"b\", \"c\" ]\n *\n * But this falls apart with inner match groups:\n *\n * (a)(((b)))(c) => [\"a\", \"b\", \"b\", \"b\", \"c\" ]\n *\n * Our scopes are now \"out of alignment\" and we're repeating `b` 3 times.\n * What needs to happen is the numbers are remapped:\n *\n * { 1 => ..., 2 => ..., 5 => ... }\n *\n * We also need to know that the ONLY groups that should be output\n * are 1, 2, and 5. This function handles this behavior.\n *\n * @param {CompiledMode} mode\n * @param {Array} regexes\n * @param {{key: \"beginScope\"|\"endScope\"}} opts\n */\nfunction remapScopeNames(mode, regexes, { key }) {\n let offset = 0;\n const scopeNames = mode[key];\n /** @type Record */\n const emit = {};\n /** @type Record */\n const positions = {};\n\n for (let i = 1; i <= regexes.length; i++) {\n positions[i + offset] = scopeNames[i];\n emit[i + offset] = true;\n offset += countMatchGroups(regexes[i - 1]);\n }\n // we use _emit to keep track of which match groups are \"top-level\" to avoid double\n // output from inside match groups\n mode[key] = positions;\n mode[key]._emit = emit;\n mode[key]._multi = true;\n}\n\n/**\n * @param {CompiledMode} mode\n */\nfunction beginMultiClass(mode) {\n if (!Array.isArray(mode.begin)) return;\n\n if (mode.skip || mode.excludeBegin || mode.returnBegin) {\n error(\"skip, excludeBegin, returnBegin not compatible with beginScope: {}\");\n throw MultiClassError;\n }\n\n if (typeof mode.beginScope !== \"object\" || mode.beginScope === null) {\n error(\"beginScope must be object\");\n throw MultiClassError;\n }\n\n remapScopeNames(mode, mode.begin, { key: \"beginScope\" });\n mode.begin = _rewriteBackreferences(mode.begin, { joinWith: \"\" });\n}\n\n/**\n * @param {CompiledMode} mode\n */\nfunction endMultiClass(mode) {\n if (!Array.isArray(mode.end)) return;\n\n if (mode.skip || mode.excludeEnd || mode.returnEnd) {\n error(\"skip, excludeEnd, returnEnd not compatible with endScope: {}\");\n throw MultiClassError;\n }\n\n if (typeof mode.endScope !== \"object\" || mode.endScope === null) {\n error(\"endScope must be object\");\n throw MultiClassError;\n }\n\n remapScopeNames(mode, mode.end, { key: \"endScope\" });\n mode.end = _rewriteBackreferences(mode.end, { joinWith: \"\" });\n}\n\n/**\n * this exists only to allow `scope: {}` to be used beside `match:`\n * Otherwise `beginScope` would necessary and that would look weird\n\n {\n match: [ /def/, /\\w+/ ]\n scope: { 1: \"keyword\" , 2: \"title\" }\n }\n\n * @param {CompiledMode} mode\n */\nfunction scopeSugar(mode) {\n if (mode.scope && typeof mode.scope === \"object\" && mode.scope !== null) {\n mode.beginScope = mode.scope;\n delete mode.scope;\n }\n}\n\n/**\n * @param {CompiledMode} mode\n */\nfunction MultiClass(mode) {\n scopeSugar(mode);\n\n if (typeof mode.beginScope === \"string\") {\n mode.beginScope = { _wrap: mode.beginScope };\n }\n if (typeof mode.endScope === \"string\") {\n mode.endScope = { _wrap: mode.endScope };\n }\n\n beginMultiClass(mode);\n endMultiClass(mode);\n}\n\n/**\n@typedef {import('highlight.js').Mode} Mode\n@typedef {import('highlight.js').CompiledMode} CompiledMode\n@typedef {import('highlight.js').Language} Language\n@typedef {import('highlight.js').HLJSPlugin} HLJSPlugin\n@typedef {import('highlight.js').CompiledLanguage} CompiledLanguage\n*/\n\n// compilation\n\n/**\n * Compiles a language definition result\n *\n * Given the raw result of a language definition (Language), compiles this so\n * that it is ready for highlighting code.\n * @param {Language} language\n * @returns {CompiledLanguage}\n */\nfunction compileLanguage(language) {\n /**\n * Builds a regex with the case sensitivity of the current language\n *\n * @param {RegExp | string} value\n * @param {boolean} [global]\n */\n function langRe(value, global) {\n return new RegExp(\n source(value),\n 'm'\n + (language.case_insensitive ? 'i' : '')\n + (language.unicodeRegex ? 'u' : '')\n + (global ? 'g' : '')\n );\n }\n\n /**\n Stores multiple regular expressions and allows you to quickly search for\n them all in a string simultaneously - returning the first match. It does\n this by creating a huge (a|b|c) regex - each individual item wrapped with ()\n and joined by `|` - using match groups to track position. When a match is\n found checking which position in the array has content allows us to figure\n out which of the original regexes / match groups triggered the match.\n\n The match object itself (the result of `Regex.exec`) is returned but also\n enhanced by merging in any meta-data that was registered with the regex.\n This is how we keep track of which mode matched, and what type of rule\n (`illegal`, `begin`, end, etc).\n */\n class MultiRegex {\n constructor() {\n this.matchIndexes = {};\n // @ts-ignore\n this.regexes = [];\n this.matchAt = 1;\n this.position = 0;\n }\n\n // @ts-ignore\n addRule(re, opts) {\n opts.position = this.position++;\n // @ts-ignore\n this.matchIndexes[this.matchAt] = opts;\n this.regexes.push([opts, re]);\n this.matchAt += countMatchGroups(re) + 1;\n }\n\n compile() {\n if (this.regexes.length === 0) {\n // avoids the need to check length every time exec is called\n // @ts-ignore\n this.exec = () => null;\n }\n const terminators = this.regexes.map(el => el[1]);\n this.matcherRe = langRe(_rewriteBackreferences(terminators, { joinWith: '|' }), true);\n this.lastIndex = 0;\n }\n\n /** @param {string} s */\n exec(s) {\n this.matcherRe.lastIndex = this.lastIndex;\n const match = this.matcherRe.exec(s);\n if (!match) { return null; }\n\n // eslint-disable-next-line no-undefined\n const i = match.findIndex((el, i) => i > 0 && el !== undefined);\n // @ts-ignore\n const matchData = this.matchIndexes[i];\n // trim off any earlier non-relevant match groups (ie, the other regex\n // match groups that make up the multi-matcher)\n match.splice(0, i);\n\n return Object.assign(match, matchData);\n }\n }\n\n /*\n Created to solve the key deficiently with MultiRegex - there is no way to\n test for multiple matches at a single location. Why would we need to do\n that? In the future a more dynamic engine will allow certain matches to be\n ignored. An example: if we matched say the 3rd regex in a large group but\n decided to ignore it - we'd need to started testing again at the 4th\n regex... but MultiRegex itself gives us no real way to do that.\n\n So what this class creates MultiRegexs on the fly for whatever search\n position they are needed.\n\n NOTE: These additional MultiRegex objects are created dynamically. For most\n grammars most of the time we will never actually need anything more than the\n first MultiRegex - so this shouldn't have too much overhead.\n\n Say this is our search group, and we match regex3, but wish to ignore it.\n\n regex1 | regex2 | regex3 | regex4 | regex5 ' ie, startAt = 0\n\n What we need is a new MultiRegex that only includes the remaining\n possibilities:\n\n regex4 | regex5 ' ie, startAt = 3\n\n This class wraps all that complexity up in a simple API... `startAt` decides\n where in the array of expressions to start doing the matching. It\n auto-increments, so if a match is found at position 2, then startAt will be\n set to 3. If the end is reached startAt will return to 0.\n\n MOST of the time the parser will be setting startAt manually to 0.\n */\n class ResumableMultiRegex {\n constructor() {\n // @ts-ignore\n this.rules = [];\n // @ts-ignore\n this.multiRegexes = [];\n this.count = 0;\n\n this.lastIndex = 0;\n this.regexIndex = 0;\n }\n\n // @ts-ignore\n getMatcher(index) {\n if (this.multiRegexes[index]) return this.multiRegexes[index];\n\n const matcher = new MultiRegex();\n this.rules.slice(index).forEach(([re, opts]) => matcher.addRule(re, opts));\n matcher.compile();\n this.multiRegexes[index] = matcher;\n return matcher;\n }\n\n resumingScanAtSamePosition() {\n return this.regexIndex !== 0;\n }\n\n considerAll() {\n this.regexIndex = 0;\n }\n\n // @ts-ignore\n addRule(re, opts) {\n this.rules.push([re, opts]);\n if (opts.type === \"begin\") this.count++;\n }\n\n /** @param {string} s */\n exec(s) {\n const m = this.getMatcher(this.regexIndex);\n m.lastIndex = this.lastIndex;\n let result = m.exec(s);\n\n // The following is because we have no easy way to say \"resume scanning at the\n // existing position but also skip the current rule ONLY\". What happens is\n // all prior rules are also skipped which can result in matching the wrong\n // thing. Example of matching \"booger\":\n\n // our matcher is [string, \"booger\", number]\n //\n // ....booger....\n\n // if \"booger\" is ignored then we'd really need a regex to scan from the\n // SAME position for only: [string, number] but ignoring \"booger\" (if it\n // was the first match), a simple resume would scan ahead who knows how\n // far looking only for \"number\", ignoring potential string matches (or\n // future \"booger\" matches that might be valid.)\n\n // So what we do: We execute two matchers, one resuming at the same\n // position, but the second full matcher starting at the position after:\n\n // /--- resume first regex match here (for [number])\n // |/---- full match here for [string, \"booger\", number]\n // vv\n // ....booger....\n\n // Which ever results in a match first is then used. So this 3-4 step\n // process essentially allows us to say \"match at this position, excluding\n // a prior rule that was ignored\".\n //\n // 1. Match \"booger\" first, ignore. Also proves that [string] does non match.\n // 2. Resume matching for [number]\n // 3. Match at index + 1 for [string, \"booger\", number]\n // 4. If #2 and #3 result in matches, which came first?\n if (this.resumingScanAtSamePosition()) {\n if (result && result.index === this.lastIndex) ; else { // use the second matcher result\n const m2 = this.getMatcher(0);\n m2.lastIndex = this.lastIndex + 1;\n result = m2.exec(s);\n }\n }\n\n if (result) {\n this.regexIndex += result.position + 1;\n if (this.regexIndex === this.count) {\n // wrap-around to considering all matches again\n this.considerAll();\n }\n }\n\n return result;\n }\n }\n\n /**\n * Given a mode, builds a huge ResumableMultiRegex that can be used to walk\n * the content and find matches.\n *\n * @param {CompiledMode} mode\n * @returns {ResumableMultiRegex}\n */\n function buildModeRegex(mode) {\n const mm = new ResumableMultiRegex();\n\n mode.contains.forEach(term => mm.addRule(term.begin, { rule: term, type: \"begin\" }));\n\n if (mode.terminatorEnd) {\n mm.addRule(mode.terminatorEnd, { type: \"end\" });\n }\n if (mode.illegal) {\n mm.addRule(mode.illegal, { type: \"illegal\" });\n }\n\n return mm;\n }\n\n /** skip vs abort vs ignore\n *\n * @skip - The mode is still entered and exited normally (and contains rules apply),\n * but all content is held and added to the parent buffer rather than being\n * output when the mode ends. Mostly used with `sublanguage` to build up\n * a single large buffer than can be parsed by sublanguage.\n *\n * - The mode begin ands ends normally.\n * - Content matched is added to the parent mode buffer.\n * - The parser cursor is moved forward normally.\n *\n * @abort - A hack placeholder until we have ignore. Aborts the mode (as if it\n * never matched) but DOES NOT continue to match subsequent `contains`\n * modes. Abort is bad/suboptimal because it can result in modes\n * farther down not getting applied because an earlier rule eats the\n * content but then aborts.\n *\n * - The mode does not begin.\n * - Content matched by `begin` is added to the mode buffer.\n * - The parser cursor is moved forward accordingly.\n *\n * @ignore - Ignores the mode (as if it never matched) and continues to match any\n * subsequent `contains` modes. Ignore isn't technically possible with\n * the current parser implementation.\n *\n * - The mode does not begin.\n * - Content matched by `begin` is ignored.\n * - The parser cursor is not moved forward.\n */\n\n /**\n * Compiles an individual mode\n *\n * This can raise an error if the mode contains certain detectable known logic\n * issues.\n * @param {Mode} mode\n * @param {CompiledMode | null} [parent]\n * @returns {CompiledMode | never}\n */\n function compileMode(mode, parent) {\n const cmode = /** @type CompiledMode */ (mode);\n if (mode.isCompiled) return cmode;\n\n [\n scopeClassName,\n // do this early so compiler extensions generally don't have to worry about\n // the distinction between match/begin\n compileMatch,\n MultiClass,\n beforeMatchExt\n ].forEach(ext => ext(mode, parent));\n\n language.compilerExtensions.forEach(ext => ext(mode, parent));\n\n // __beforeBegin is considered private API, internal use only\n mode.__beforeBegin = null;\n\n [\n beginKeywords,\n // do this later so compiler extensions that come earlier have access to the\n // raw array if they wanted to perhaps manipulate it, etc.\n compileIllegal,\n // default to 1 relevance if not specified\n compileRelevance\n ].forEach(ext => ext(mode, parent));\n\n mode.isCompiled = true;\n\n let keywordPattern = null;\n if (typeof mode.keywords === \"object\" && mode.keywords.$pattern) {\n // we need a copy because keywords might be compiled multiple times\n // so we can't go deleting $pattern from the original on the first\n // pass\n mode.keywords = Object.assign({}, mode.keywords);\n keywordPattern = mode.keywords.$pattern;\n delete mode.keywords.$pattern;\n }\n keywordPattern = keywordPattern || /\\w+/;\n\n if (mode.keywords) {\n mode.keywords = compileKeywords(mode.keywords, language.case_insensitive);\n }\n\n cmode.keywordPatternRe = langRe(keywordPattern, true);\n\n if (parent) {\n if (!mode.begin) mode.begin = /\\B|\\b/;\n cmode.beginRe = langRe(cmode.begin);\n if (!mode.end && !mode.endsWithParent) mode.end = /\\B|\\b/;\n if (mode.end) cmode.endRe = langRe(cmode.end);\n cmode.terminatorEnd = source(cmode.end) || '';\n if (mode.endsWithParent && parent.terminatorEnd) {\n cmode.terminatorEnd += (mode.end ? '|' : '') + parent.terminatorEnd;\n }\n }\n if (mode.illegal) cmode.illegalRe = langRe(/** @type {RegExp | string} */ (mode.illegal));\n if (!mode.contains) mode.contains = [];\n\n mode.contains = [].concat(...mode.contains.map(function(c) {\n return expandOrCloneMode(c === 'self' ? mode : c);\n }));\n mode.contains.forEach(function(c) { compileMode(/** @type Mode */ (c), cmode); });\n\n if (mode.starts) {\n compileMode(mode.starts, parent);\n }\n\n cmode.matcher = buildModeRegex(cmode);\n return cmode;\n }\n\n if (!language.compilerExtensions) language.compilerExtensions = [];\n\n // self is not valid at the top-level\n if (language.contains && language.contains.includes('self')) {\n throw new Error(\"ERR: contains `self` is not supported at the top-level of a language. See documentation.\");\n }\n\n // we need a null object, which inherit will guarantee\n language.classNameAliases = inherit$1(language.classNameAliases || {});\n\n return compileMode(/** @type Mode */ (language));\n}\n\n/**\n * Determines if a mode has a dependency on it's parent or not\n *\n * If a mode does have a parent dependency then often we need to clone it if\n * it's used in multiple places so that each copy points to the correct parent,\n * where-as modes without a parent can often safely be re-used at the bottom of\n * a mode chain.\n *\n * @param {Mode | null} mode\n * @returns {boolean} - is there a dependency on the parent?\n * */\nfunction dependencyOnParent(mode) {\n if (!mode) return false;\n\n return mode.endsWithParent || dependencyOnParent(mode.starts);\n}\n\n/**\n * Expands a mode or clones it if necessary\n *\n * This is necessary for modes with parental dependenceis (see notes on\n * `dependencyOnParent`) and for nodes that have `variants` - which must then be\n * exploded into their own individual modes at compile time.\n *\n * @param {Mode} mode\n * @returns {Mode | Mode[]}\n * */\nfunction expandOrCloneMode(mode) {\n if (mode.variants && !mode.cachedVariants) {\n mode.cachedVariants = mode.variants.map(function(variant) {\n return inherit$1(mode, { variants: null }, variant);\n });\n }\n\n // EXPAND\n // if we have variants then essentially \"replace\" the mode with the variants\n // this happens in compileMode, where this function is called from\n if (mode.cachedVariants) {\n return mode.cachedVariants;\n }\n\n // CLONE\n // if we have dependencies on parents then we need a unique\n // instance of ourselves, so we can be reused with many\n // different parents without issue\n if (dependencyOnParent(mode)) {\n return inherit$1(mode, { starts: mode.starts ? inherit$1(mode.starts) : null });\n }\n\n if (Object.isFrozen(mode)) {\n return inherit$1(mode);\n }\n\n // no special dependency issues, just return ourselves\n return mode;\n}\n\nvar version = \"11.10.0\";\n\nclass HTMLInjectionError extends Error {\n constructor(reason, html) {\n super(reason);\n this.name = \"HTMLInjectionError\";\n this.html = html;\n }\n}\n\n/*\nSyntax highlighting with language autodetection.\nhttps://highlightjs.org/\n*/\n\n\n\n/**\n@typedef {import('highlight.js').Mode} Mode\n@typedef {import('highlight.js').CompiledMode} CompiledMode\n@typedef {import('highlight.js').CompiledScope} CompiledScope\n@typedef {import('highlight.js').Language} Language\n@typedef {import('highlight.js').HLJSApi} HLJSApi\n@typedef {import('highlight.js').HLJSPlugin} HLJSPlugin\n@typedef {import('highlight.js').PluginEvent} PluginEvent\n@typedef {import('highlight.js').HLJSOptions} HLJSOptions\n@typedef {import('highlight.js').LanguageFn} LanguageFn\n@typedef {import('highlight.js').HighlightedHTMLElement} HighlightedHTMLElement\n@typedef {import('highlight.js').BeforeHighlightContext} BeforeHighlightContext\n@typedef {import('highlight.js/private').MatchType} MatchType\n@typedef {import('highlight.js/private').KeywordData} KeywordData\n@typedef {import('highlight.js/private').EnhancedMatch} EnhancedMatch\n@typedef {import('highlight.js/private').AnnotatedError} AnnotatedError\n@typedef {import('highlight.js').AutoHighlightResult} AutoHighlightResult\n@typedef {import('highlight.js').HighlightOptions} HighlightOptions\n@typedef {import('highlight.js').HighlightResult} HighlightResult\n*/\n\n\nconst escape = escapeHTML;\nconst inherit = inherit$1;\nconst NO_MATCH = Symbol(\"nomatch\");\nconst MAX_KEYWORD_HITS = 7;\n\n/**\n * @param {any} hljs - object that is extended (legacy)\n * @returns {HLJSApi}\n */\nconst HLJS = function(hljs) {\n // Global internal variables used within the highlight.js library.\n /** @type {Record} */\n const languages = Object.create(null);\n /** @type {Record} */\n const aliases = Object.create(null);\n /** @type {HLJSPlugin[]} */\n const plugins = [];\n\n // safe/production mode - swallows more errors, tries to keep running\n // even if a single syntax or parse hits a fatal error\n let SAFE_MODE = true;\n const LANGUAGE_NOT_FOUND = \"Could not find the language '{}', did you forget to load/include a language module?\";\n /** @type {Language} */\n const PLAINTEXT_LANGUAGE = { disableAutodetect: true, name: 'Plain text', contains: [] };\n\n // Global options used when within external APIs. This is modified when\n // calling the `hljs.configure` function.\n /** @type HLJSOptions */\n let options = {\n ignoreUnescapedHTML: false,\n throwUnescapedHTML: false,\n noHighlightRe: /^(no-?highlight)$/i,\n languageDetectRe: /\\blang(?:uage)?-([\\w-]+)\\b/i,\n classPrefix: 'hljs-',\n cssSelector: 'pre code',\n languages: null,\n // beta configuration options, subject to change, welcome to discuss\n // https://github.com/highlightjs/highlight.js/issues/1086\n __emitter: TokenTreeEmitter\n };\n\n /* Utility functions */\n\n /**\n * Tests a language name to see if highlighting should be skipped\n * @param {string} languageName\n */\n function shouldNotHighlight(languageName) {\n return options.noHighlightRe.test(languageName);\n }\n\n /**\n * @param {HighlightedHTMLElement} block - the HTML element to determine language for\n */\n function blockLanguage(block) {\n let classes = block.className + ' ';\n\n classes += block.parentNode ? block.parentNode.className : '';\n\n // language-* takes precedence over non-prefixed class names.\n const match = options.languageDetectRe.exec(classes);\n if (match) {\n const language = getLanguage(match[1]);\n if (!language) {\n warn(LANGUAGE_NOT_FOUND.replace(\"{}\", match[1]));\n warn(\"Falling back to no-highlight mode for this block.\", block);\n }\n return language ? match[1] : 'no-highlight';\n }\n\n return classes\n .split(/\\s+/)\n .find((_class) => shouldNotHighlight(_class) || getLanguage(_class));\n }\n\n /**\n * Core highlighting function.\n *\n * OLD API\n * highlight(lang, code, ignoreIllegals, continuation)\n *\n * NEW API\n * highlight(code, {lang, ignoreIllegals})\n *\n * @param {string} codeOrLanguageName - the language to use for highlighting\n * @param {string | HighlightOptions} optionsOrCode - the code to highlight\n * @param {boolean} [ignoreIllegals] - whether to ignore illegal matches, default is to bail\n *\n * @returns {HighlightResult} Result - an object that represents the result\n * @property {string} language - the language name\n * @property {number} relevance - the relevance score\n * @property {string} value - the highlighted HTML code\n * @property {string} code - the original raw code\n * @property {CompiledMode} top - top of the current mode stack\n * @property {boolean} illegal - indicates whether any illegal matches were found\n */\n function highlight(codeOrLanguageName, optionsOrCode, ignoreIllegals) {\n let code = \"\";\n let languageName = \"\";\n if (typeof optionsOrCode === \"object\") {\n code = codeOrLanguageName;\n ignoreIllegals = optionsOrCode.ignoreIllegals;\n languageName = optionsOrCode.language;\n } else {\n // old API\n deprecated(\"10.7.0\", \"highlight(lang, code, ...args) has been deprecated.\");\n deprecated(\"10.7.0\", \"Please use highlight(code, options) instead.\\nhttps://github.com/highlightjs/highlight.js/issues/2277\");\n languageName = codeOrLanguageName;\n code = optionsOrCode;\n }\n\n // https://github.com/highlightjs/highlight.js/issues/3149\n // eslint-disable-next-line no-undefined\n if (ignoreIllegals === undefined) { ignoreIllegals = true; }\n\n /** @type {BeforeHighlightContext} */\n const context = {\n code,\n language: languageName\n };\n // the plugin can change the desired language or the code to be highlighted\n // just be changing the object it was passed\n fire(\"before:highlight\", context);\n\n // a before plugin can usurp the result completely by providing it's own\n // in which case we don't even need to call highlight\n const result = context.result\n ? context.result\n : _highlight(context.language, context.code, ignoreIllegals);\n\n result.code = context.code;\n // the plugin can change anything in result to suite it\n fire(\"after:highlight\", result);\n\n return result;\n }\n\n /**\n * private highlight that's used internally and does not fire callbacks\n *\n * @param {string} languageName - the language to use for highlighting\n * @param {string} codeToHighlight - the code to highlight\n * @param {boolean?} [ignoreIllegals] - whether to ignore illegal matches, default is to bail\n * @param {CompiledMode?} [continuation] - current continuation mode, if any\n * @returns {HighlightResult} - result of the highlight operation\n */\n function _highlight(languageName, codeToHighlight, ignoreIllegals, continuation) {\n const keywordHits = Object.create(null);\n\n /**\n * Return keyword data if a match is a keyword\n * @param {CompiledMode} mode - current mode\n * @param {string} matchText - the textual match\n * @returns {KeywordData | false}\n */\n function keywordData(mode, matchText) {\n return mode.keywords[matchText];\n }\n\n function processKeywords() {\n if (!top.keywords) {\n emitter.addText(modeBuffer);\n return;\n }\n\n let lastIndex = 0;\n top.keywordPatternRe.lastIndex = 0;\n let match = top.keywordPatternRe.exec(modeBuffer);\n let buf = \"\";\n\n while (match) {\n buf += modeBuffer.substring(lastIndex, match.index);\n const word = language.case_insensitive ? match[0].toLowerCase() : match[0];\n const data = keywordData(top, word);\n if (data) {\n const [kind, keywordRelevance] = data;\n emitter.addText(buf);\n buf = \"\";\n\n keywordHits[word] = (keywordHits[word] || 0) + 1;\n if (keywordHits[word] <= MAX_KEYWORD_HITS) relevance += keywordRelevance;\n if (kind.startsWith(\"_\")) {\n // _ implied for relevance only, do not highlight\n // by applying a class name\n buf += match[0];\n } else {\n const cssClass = language.classNameAliases[kind] || kind;\n emitKeyword(match[0], cssClass);\n }\n } else {\n buf += match[0];\n }\n lastIndex = top.keywordPatternRe.lastIndex;\n match = top.keywordPatternRe.exec(modeBuffer);\n }\n buf += modeBuffer.substring(lastIndex);\n emitter.addText(buf);\n }\n\n function processSubLanguage() {\n if (modeBuffer === \"\") return;\n /** @type HighlightResult */\n let result = null;\n\n if (typeof top.subLanguage === 'string') {\n if (!languages[top.subLanguage]) {\n emitter.addText(modeBuffer);\n return;\n }\n result = _highlight(top.subLanguage, modeBuffer, true, continuations[top.subLanguage]);\n continuations[top.subLanguage] = /** @type {CompiledMode} */ (result._top);\n } else {\n result = highlightAuto(modeBuffer, top.subLanguage.length ? top.subLanguage : null);\n }\n\n // Counting embedded language score towards the host language may be disabled\n // with zeroing the containing mode relevance. Use case in point is Markdown that\n // allows XML everywhere and makes every XML snippet to have a much larger Markdown\n // score.\n if (top.relevance > 0) {\n relevance += result.relevance;\n }\n emitter.__addSublanguage(result._emitter, result.language);\n }\n\n function processBuffer() {\n if (top.subLanguage != null) {\n processSubLanguage();\n } else {\n processKeywords();\n }\n modeBuffer = '';\n }\n\n /**\n * @param {string} text\n * @param {string} scope\n */\n function emitKeyword(keyword, scope) {\n if (keyword === \"\") return;\n\n emitter.startScope(scope);\n emitter.addText(keyword);\n emitter.endScope();\n }\n\n /**\n * @param {CompiledScope} scope\n * @param {RegExpMatchArray} match\n */\n function emitMultiClass(scope, match) {\n let i = 1;\n const max = match.length - 1;\n while (i <= max) {\n if (!scope._emit[i]) { i++; continue; }\n const klass = language.classNameAliases[scope[i]] || scope[i];\n const text = match[i];\n if (klass) {\n emitKeyword(text, klass);\n } else {\n modeBuffer = text;\n processKeywords();\n modeBuffer = \"\";\n }\n i++;\n }\n }\n\n /**\n * @param {CompiledMode} mode - new mode to start\n * @param {RegExpMatchArray} match\n */\n function startNewMode(mode, match) {\n if (mode.scope && typeof mode.scope === \"string\") {\n emitter.openNode(language.classNameAliases[mode.scope] || mode.scope);\n }\n if (mode.beginScope) {\n // beginScope just wraps the begin match itself in a scope\n if (mode.beginScope._wrap) {\n emitKeyword(modeBuffer, language.classNameAliases[mode.beginScope._wrap] || mode.beginScope._wrap);\n modeBuffer = \"\";\n } else if (mode.beginScope._multi) {\n // at this point modeBuffer should just be the match\n emitMultiClass(mode.beginScope, match);\n modeBuffer = \"\";\n }\n }\n\n top = Object.create(mode, { parent: { value: top } });\n return top;\n }\n\n /**\n * @param {CompiledMode } mode - the mode to potentially end\n * @param {RegExpMatchArray} match - the latest match\n * @param {string} matchPlusRemainder - match plus remainder of content\n * @returns {CompiledMode | void} - the next mode, or if void continue on in current mode\n */\n function endOfMode(mode, match, matchPlusRemainder) {\n let matched = startsWith(mode.endRe, matchPlusRemainder);\n\n if (matched) {\n if (mode[\"on:end\"]) {\n const resp = new Response(mode);\n mode[\"on:end\"](match, resp);\n if (resp.isMatchIgnored) matched = false;\n }\n\n if (matched) {\n while (mode.endsParent && mode.parent) {\n mode = mode.parent;\n }\n return mode;\n }\n }\n // even if on:end fires an `ignore` it's still possible\n // that we might trigger the end node because of a parent mode\n if (mode.endsWithParent) {\n return endOfMode(mode.parent, match, matchPlusRemainder);\n }\n }\n\n /**\n * Handle matching but then ignoring a sequence of text\n *\n * @param {string} lexeme - string containing full match text\n */\n function doIgnore(lexeme) {\n if (top.matcher.regexIndex === 0) {\n // no more regexes to potentially match here, so we move the cursor forward one\n // space\n modeBuffer += lexeme[0];\n return 1;\n } else {\n // no need to move the cursor, we still have additional regexes to try and\n // match at this very spot\n resumeScanAtSamePosition = true;\n return 0;\n }\n }\n\n /**\n * Handle the start of a new potential mode match\n *\n * @param {EnhancedMatch} match - the current match\n * @returns {number} how far to advance the parse cursor\n */\n function doBeginMatch(match) {\n const lexeme = match[0];\n const newMode = match.rule;\n\n const resp = new Response(newMode);\n // first internal before callbacks, then the public ones\n const beforeCallbacks = [newMode.__beforeBegin, newMode[\"on:begin\"]];\n for (const cb of beforeCallbacks) {\n if (!cb) continue;\n cb(match, resp);\n if (resp.isMatchIgnored) return doIgnore(lexeme);\n }\n\n if (newMode.skip) {\n modeBuffer += lexeme;\n } else {\n if (newMode.excludeBegin) {\n modeBuffer += lexeme;\n }\n processBuffer();\n if (!newMode.returnBegin && !newMode.excludeBegin) {\n modeBuffer = lexeme;\n }\n }\n startNewMode(newMode, match);\n return newMode.returnBegin ? 0 : lexeme.length;\n }\n\n /**\n * Handle the potential end of mode\n *\n * @param {RegExpMatchArray} match - the current match\n */\n function doEndMatch(match) {\n const lexeme = match[0];\n const matchPlusRemainder = codeToHighlight.substring(match.index);\n\n const endMode = endOfMode(top, match, matchPlusRemainder);\n if (!endMode) { return NO_MATCH; }\n\n const origin = top;\n if (top.endScope && top.endScope._wrap) {\n processBuffer();\n emitKeyword(lexeme, top.endScope._wrap);\n } else if (top.endScope && top.endScope._multi) {\n processBuffer();\n emitMultiClass(top.endScope, match);\n } else if (origin.skip) {\n modeBuffer += lexeme;\n } else {\n if (!(origin.returnEnd || origin.excludeEnd)) {\n modeBuffer += lexeme;\n }\n processBuffer();\n if (origin.excludeEnd) {\n modeBuffer = lexeme;\n }\n }\n do {\n if (top.scope) {\n emitter.closeNode();\n }\n if (!top.skip && !top.subLanguage) {\n relevance += top.relevance;\n }\n top = top.parent;\n } while (top !== endMode.parent);\n if (endMode.starts) {\n startNewMode(endMode.starts, match);\n }\n return origin.returnEnd ? 0 : lexeme.length;\n }\n\n function processContinuations() {\n const list = [];\n for (let current = top; current !== language; current = current.parent) {\n if (current.scope) {\n list.unshift(current.scope);\n }\n }\n list.forEach(item => emitter.openNode(item));\n }\n\n /** @type {{type?: MatchType, index?: number, rule?: Mode}}} */\n let lastMatch = {};\n\n /**\n * Process an individual match\n *\n * @param {string} textBeforeMatch - text preceding the match (since the last match)\n * @param {EnhancedMatch} [match] - the match itself\n */\n function processLexeme(textBeforeMatch, match) {\n const lexeme = match && match[0];\n\n // add non-matched text to the current mode buffer\n modeBuffer += textBeforeMatch;\n\n if (lexeme == null) {\n processBuffer();\n return 0;\n }\n\n // we've found a 0 width match and we're stuck, so we need to advance\n // this happens when we have badly behaved rules that have optional matchers to the degree that\n // sometimes they can end up matching nothing at all\n // Ref: https://github.com/highlightjs/highlight.js/issues/2140\n if (lastMatch.type === \"begin\" && match.type === \"end\" && lastMatch.index === match.index && lexeme === \"\") {\n // spit the \"skipped\" character that our regex choked on back into the output sequence\n modeBuffer += codeToHighlight.slice(match.index, match.index + 1);\n if (!SAFE_MODE) {\n /** @type {AnnotatedError} */\n const err = new Error(`0 width match regex (${languageName})`);\n err.languageName = languageName;\n err.badRule = lastMatch.rule;\n throw err;\n }\n return 1;\n }\n lastMatch = match;\n\n if (match.type === \"begin\") {\n return doBeginMatch(match);\n } else if (match.type === \"illegal\" && !ignoreIllegals) {\n // illegal match, we do not continue processing\n /** @type {AnnotatedError} */\n const err = new Error('Illegal lexeme \"' + lexeme + '\" for mode \"' + (top.scope || '') + '\"');\n err.mode = top;\n throw err;\n } else if (match.type === \"end\") {\n const processed = doEndMatch(match);\n if (processed !== NO_MATCH) {\n return processed;\n }\n }\n\n // edge case for when illegal matches $ (end of line) which is technically\n // a 0 width match but not a begin/end match so it's not caught by the\n // first handler (when ignoreIllegals is true)\n if (match.type === \"illegal\" && lexeme === \"\") {\n // advance so we aren't stuck in an infinite loop\n return 1;\n }\n\n // infinite loops are BAD, this is a last ditch catch all. if we have a\n // decent number of iterations yet our index (cursor position in our\n // parsing) still 3x behind our index then something is very wrong\n // so we bail\n if (iterations > 100000 && iterations > match.index * 3) {\n const err = new Error('potential infinite loop, way more iterations than matches');\n throw err;\n }\n\n /*\n Why might be find ourselves here? An potential end match that was\n triggered but could not be completed. IE, `doEndMatch` returned NO_MATCH.\n (this could be because a callback requests the match be ignored, etc)\n\n This causes no real harm other than stopping a few times too many.\n */\n\n modeBuffer += lexeme;\n return lexeme.length;\n }\n\n const language = getLanguage(languageName);\n if (!language) {\n error(LANGUAGE_NOT_FOUND.replace(\"{}\", languageName));\n throw new Error('Unknown language: \"' + languageName + '\"');\n }\n\n const md = compileLanguage(language);\n let result = '';\n /** @type {CompiledMode} */\n let top = continuation || md;\n /** @type Record */\n const continuations = {}; // keep continuations for sub-languages\n const emitter = new options.__emitter(options);\n processContinuations();\n let modeBuffer = '';\n let relevance = 0;\n let index = 0;\n let iterations = 0;\n let resumeScanAtSamePosition = false;\n\n try {\n if (!language.__emitTokens) {\n top.matcher.considerAll();\n\n for (;;) {\n iterations++;\n if (resumeScanAtSamePosition) {\n // only regexes not matched previously will now be\n // considered for a potential match\n resumeScanAtSamePosition = false;\n } else {\n top.matcher.considerAll();\n }\n top.matcher.lastIndex = index;\n\n const match = top.matcher.exec(codeToHighlight);\n // console.log(\"match\", match[0], match.rule && match.rule.begin)\n\n if (!match) break;\n\n const beforeMatch = codeToHighlight.substring(index, match.index);\n const processedCount = processLexeme(beforeMatch, match);\n index = match.index + processedCount;\n }\n processLexeme(codeToHighlight.substring(index));\n } else {\n language.__emitTokens(codeToHighlight, emitter);\n }\n\n emitter.finalize();\n result = emitter.toHTML();\n\n return {\n language: languageName,\n value: result,\n relevance,\n illegal: false,\n _emitter: emitter,\n _top: top\n };\n } catch (err) {\n if (err.message && err.message.includes('Illegal')) {\n return {\n language: languageName,\n value: escape(codeToHighlight),\n illegal: true,\n relevance: 0,\n _illegalBy: {\n message: err.message,\n index,\n context: codeToHighlight.slice(index - 100, index + 100),\n mode: err.mode,\n resultSoFar: result\n },\n _emitter: emitter\n };\n } else if (SAFE_MODE) {\n return {\n language: languageName,\n value: escape(codeToHighlight),\n illegal: false,\n relevance: 0,\n errorRaised: err,\n _emitter: emitter,\n _top: top\n };\n } else {\n throw err;\n }\n }\n }\n\n /**\n * returns a valid highlight result, without actually doing any actual work,\n * auto highlight starts with this and it's possible for small snippets that\n * auto-detection may not find a better match\n * @param {string} code\n * @returns {HighlightResult}\n */\n function justTextHighlightResult(code) {\n const result = {\n value: escape(code),\n illegal: false,\n relevance: 0,\n _top: PLAINTEXT_LANGUAGE,\n _emitter: new options.__emitter(options)\n };\n result._emitter.addText(code);\n return result;\n }\n\n /**\n Highlighting with language detection. Accepts a string with the code to\n highlight. Returns an object with the following properties:\n\n - language (detected language)\n - relevance (int)\n - value (an HTML string with highlighting markup)\n - secondBest (object with the same structure for second-best heuristically\n detected language, may be absent)\n\n @param {string} code\n @param {Array} [languageSubset]\n @returns {AutoHighlightResult}\n */\n function highlightAuto(code, languageSubset) {\n languageSubset = languageSubset || options.languages || Object.keys(languages);\n const plaintext = justTextHighlightResult(code);\n\n const results = languageSubset.filter(getLanguage).filter(autoDetection).map(name =>\n _highlight(name, code, false)\n );\n results.unshift(plaintext); // plaintext is always an option\n\n const sorted = results.sort((a, b) => {\n // sort base on relevance\n if (a.relevance !== b.relevance) return b.relevance - a.relevance;\n\n // always award the tie to the base language\n // ie if C++ and Arduino are tied, it's more likely to be C++\n if (a.language && b.language) {\n if (getLanguage(a.language).supersetOf === b.language) {\n return 1;\n } else if (getLanguage(b.language).supersetOf === a.language) {\n return -1;\n }\n }\n\n // otherwise say they are equal, which has the effect of sorting on\n // relevance while preserving the original ordering - which is how ties\n // have historically been settled, ie the language that comes first always\n // wins in the case of a tie\n return 0;\n });\n\n const [best, secondBest] = sorted;\n\n /** @type {AutoHighlightResult} */\n const result = best;\n result.secondBest = secondBest;\n\n return result;\n }\n\n /**\n * Builds new class name for block given the language name\n *\n * @param {HTMLElement} element\n * @param {string} [currentLang]\n * @param {string} [resultLang]\n */\n function updateClassName(element, currentLang, resultLang) {\n const language = (currentLang && aliases[currentLang]) || resultLang;\n\n element.classList.add(\"hljs\");\n element.classList.add(`language-${language}`);\n }\n\n /**\n * Applies highlighting to a DOM node containing code.\n *\n * @param {HighlightedHTMLElement} element - the HTML element to highlight\n */\n function highlightElement(element) {\n /** @type HTMLElement */\n let node = null;\n const language = blockLanguage(element);\n\n if (shouldNotHighlight(language)) return;\n\n fire(\"before:highlightElement\",\n { el: element, language });\n\n if (element.dataset.highlighted) {\n console.log(\"Element previously highlighted. To highlight again, first unset `dataset.highlighted`.\", element);\n return;\n }\n\n // we should be all text, no child nodes (unescaped HTML) - this is possibly\n // an HTML injection attack - it's likely too late if this is already in\n // production (the code has likely already done its damage by the time\n // we're seeing it)... but we yell loudly about this so that hopefully it's\n // more likely to be caught in development before making it to production\n if (element.children.length > 0) {\n if (!options.ignoreUnescapedHTML) {\n console.warn(\"One of your code blocks includes unescaped HTML. This is a potentially serious security risk.\");\n console.warn(\"https://github.com/highlightjs/highlight.js/wiki/security\");\n console.warn(\"The element with unescaped HTML:\");\n console.warn(element);\n }\n if (options.throwUnescapedHTML) {\n const err = new HTMLInjectionError(\n \"One of your code blocks includes unescaped HTML.\",\n element.innerHTML\n );\n throw err;\n }\n }\n\n node = element;\n const text = node.textContent;\n const result = language ? highlight(text, { language, ignoreIllegals: true }) : highlightAuto(text);\n\n element.innerHTML = result.value;\n element.dataset.highlighted = \"yes\";\n updateClassName(element, language, result.language);\n element.result = {\n language: result.language,\n // TODO: remove with version 11.0\n re: result.relevance,\n relevance: result.relevance\n };\n if (result.secondBest) {\n element.secondBest = {\n language: result.secondBest.language,\n relevance: result.secondBest.relevance\n };\n }\n\n fire(\"after:highlightElement\", { el: element, result, text });\n }\n\n /**\n * Updates highlight.js global options with the passed options\n *\n * @param {Partial} userOptions\n */\n function configure(userOptions) {\n options = inherit(options, userOptions);\n }\n\n // TODO: remove v12, deprecated\n const initHighlighting = () => {\n highlightAll();\n deprecated(\"10.6.0\", \"initHighlighting() deprecated. Use highlightAll() now.\");\n };\n\n // TODO: remove v12, deprecated\n function initHighlightingOnLoad() {\n highlightAll();\n deprecated(\"10.6.0\", \"initHighlightingOnLoad() deprecated. Use highlightAll() now.\");\n }\n\n let wantsHighlight = false;\n\n /**\n * auto-highlights all pre>code elements on the page\n */\n function highlightAll() {\n // if we are called too early in the loading process\n if (document.readyState === \"loading\") {\n wantsHighlight = true;\n return;\n }\n\n const blocks = document.querySelectorAll(options.cssSelector);\n blocks.forEach(highlightElement);\n }\n\n function boot() {\n // if a highlight was requested before DOM was loaded, do now\n if (wantsHighlight) highlightAll();\n }\n\n // make sure we are in the browser environment\n if (typeof window !== 'undefined' && window.addEventListener) {\n window.addEventListener('DOMContentLoaded', boot, false);\n }\n\n /**\n * Register a language grammar module\n *\n * @param {string} languageName\n * @param {LanguageFn} languageDefinition\n */\n function registerLanguage(languageName, languageDefinition) {\n let lang = null;\n try {\n lang = languageDefinition(hljs);\n } catch (error$1) {\n error(\"Language definition for '{}' could not be registered.\".replace(\"{}\", languageName));\n // hard or soft error\n if (!SAFE_MODE) { throw error$1; } else { error(error$1); }\n // languages that have serious errors are replaced with essentially a\n // \"plaintext\" stand-in so that the code blocks will still get normal\n // css classes applied to them - and one bad language won't break the\n // entire highlighter\n lang = PLAINTEXT_LANGUAGE;\n }\n // give it a temporary name if it doesn't have one in the meta-data\n if (!lang.name) lang.name = languageName;\n languages[languageName] = lang;\n lang.rawDefinition = languageDefinition.bind(null, hljs);\n\n if (lang.aliases) {\n registerAliases(lang.aliases, { languageName });\n }\n }\n\n /**\n * Remove a language grammar module\n *\n * @param {string} languageName\n */\n function unregisterLanguage(languageName) {\n delete languages[languageName];\n for (const alias of Object.keys(aliases)) {\n if (aliases[alias] === languageName) {\n delete aliases[alias];\n }\n }\n }\n\n /**\n * @returns {string[]} List of language internal names\n */\n function listLanguages() {\n return Object.keys(languages);\n }\n\n /**\n * @param {string} name - name of the language to retrieve\n * @returns {Language | undefined}\n */\n function getLanguage(name) {\n name = (name || '').toLowerCase();\n return languages[name] || languages[aliases[name]];\n }\n\n /**\n *\n * @param {string|string[]} aliasList - single alias or list of aliases\n * @param {{languageName: string}} opts\n */\n function registerAliases(aliasList, { languageName }) {\n if (typeof aliasList === 'string') {\n aliasList = [aliasList];\n }\n aliasList.forEach(alias => { aliases[alias.toLowerCase()] = languageName; });\n }\n\n /**\n * Determines if a given language has auto-detection enabled\n * @param {string} name - name of the language\n */\n function autoDetection(name) {\n const lang = getLanguage(name);\n return lang && !lang.disableAutodetect;\n }\n\n /**\n * Upgrades the old highlightBlock plugins to the new\n * highlightElement API\n * @param {HLJSPlugin} plugin\n */\n function upgradePluginAPI(plugin) {\n // TODO: remove with v12\n if (plugin[\"before:highlightBlock\"] && !plugin[\"before:highlightElement\"]) {\n plugin[\"before:highlightElement\"] = (data) => {\n plugin[\"before:highlightBlock\"](\n Object.assign({ block: data.el }, data)\n );\n };\n }\n if (plugin[\"after:highlightBlock\"] && !plugin[\"after:highlightElement\"]) {\n plugin[\"after:highlightElement\"] = (data) => {\n plugin[\"after:highlightBlock\"](\n Object.assign({ block: data.el }, data)\n );\n };\n }\n }\n\n /**\n * @param {HLJSPlugin} plugin\n */\n function addPlugin(plugin) {\n upgradePluginAPI(plugin);\n plugins.push(plugin);\n }\n\n /**\n * @param {HLJSPlugin} plugin\n */\n function removePlugin(plugin) {\n const index = plugins.indexOf(plugin);\n if (index !== -1) {\n plugins.splice(index, 1);\n }\n }\n\n /**\n *\n * @param {PluginEvent} event\n * @param {any} args\n */\n function fire(event, args) {\n const cb = event;\n plugins.forEach(function(plugin) {\n if (plugin[cb]) {\n plugin[cb](args);\n }\n });\n }\n\n /**\n * DEPRECATED\n * @param {HighlightedHTMLElement} el\n */\n function deprecateHighlightBlock(el) {\n deprecated(\"10.7.0\", \"highlightBlock will be removed entirely in v12.0\");\n deprecated(\"10.7.0\", \"Please use highlightElement now.\");\n\n return highlightElement(el);\n }\n\n /* Interface definition */\n Object.assign(hljs, {\n highlight,\n highlightAuto,\n highlightAll,\n highlightElement,\n // TODO: Remove with v12 API\n highlightBlock: deprecateHighlightBlock,\n configure,\n initHighlighting,\n initHighlightingOnLoad,\n registerLanguage,\n unregisterLanguage,\n listLanguages,\n getLanguage,\n registerAliases,\n autoDetection,\n inherit,\n addPlugin,\n removePlugin\n });\n\n hljs.debugMode = function() { SAFE_MODE = false; };\n hljs.safeMode = function() { SAFE_MODE = true; };\n hljs.versionString = version;\n\n hljs.regex = {\n concat: concat,\n lookahead: lookahead,\n either: either,\n optional: optional,\n anyNumberOfTimes: anyNumberOfTimes\n };\n\n for (const key in MODES) {\n // @ts-ignore\n if (typeof MODES[key] === \"object\") {\n // @ts-ignore\n deepFreeze(MODES[key]);\n }\n }\n\n // merge all the modes/regexes into our main object\n Object.assign(hljs, MODES);\n\n return hljs;\n};\n\n// Other names for the variable may break build script\nconst highlight = HLJS({});\n\n// returns a new instance of the highlighter to be used for extensions\n// check https://github.com/wooorm/lowlight/issues/47\nhighlight.newInstance = () => HLJS({});\n\nmodule.exports = highlight;\nhighlight.HighlightJS = highlight;\nhighlight.default = highlight;\n","const IDENT_RE = '[A-Za-z$_][0-9A-Za-z$_]*';\nconst KEYWORDS = [\n \"as\", // for exports\n \"in\",\n \"of\",\n \"if\",\n \"for\",\n \"while\",\n \"finally\",\n \"var\",\n \"new\",\n \"function\",\n \"do\",\n \"return\",\n \"void\",\n \"else\",\n \"break\",\n \"catch\",\n \"instanceof\",\n \"with\",\n \"throw\",\n \"case\",\n \"default\",\n \"try\",\n \"switch\",\n \"continue\",\n \"typeof\",\n \"delete\",\n \"let\",\n \"yield\",\n \"const\",\n \"class\",\n // JS handles these with a special rule\n // \"get\",\n // \"set\",\n \"debugger\",\n \"async\",\n \"await\",\n \"static\",\n \"import\",\n \"from\",\n \"export\",\n \"extends\"\n];\nconst LITERALS = [\n \"true\",\n \"false\",\n \"null\",\n \"undefined\",\n \"NaN\",\n \"Infinity\"\n];\n\n// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects\nconst TYPES = [\n // Fundamental objects\n \"Object\",\n \"Function\",\n \"Boolean\",\n \"Symbol\",\n // numbers and dates\n \"Math\",\n \"Date\",\n \"Number\",\n \"BigInt\",\n // text\n \"String\",\n \"RegExp\",\n // Indexed collections\n \"Array\",\n \"Float32Array\",\n \"Float64Array\",\n \"Int8Array\",\n \"Uint8Array\",\n \"Uint8ClampedArray\",\n \"Int16Array\",\n \"Int32Array\",\n \"Uint16Array\",\n \"Uint32Array\",\n \"BigInt64Array\",\n \"BigUint64Array\",\n // Keyed collections\n \"Set\",\n \"Map\",\n \"WeakSet\",\n \"WeakMap\",\n // Structured data\n \"ArrayBuffer\",\n \"SharedArrayBuffer\",\n \"Atomics\",\n \"DataView\",\n \"JSON\",\n // Control abstraction objects\n \"Promise\",\n \"Generator\",\n \"GeneratorFunction\",\n \"AsyncFunction\",\n // Reflection\n \"Reflect\",\n \"Proxy\",\n // Internationalization\n \"Intl\",\n // WebAssembly\n \"WebAssembly\"\n];\n\nconst ERROR_TYPES = [\n \"Error\",\n \"EvalError\",\n \"InternalError\",\n \"RangeError\",\n \"ReferenceError\",\n \"SyntaxError\",\n \"TypeError\",\n \"URIError\"\n];\n\nconst BUILT_IN_GLOBALS = [\n \"setInterval\",\n \"setTimeout\",\n \"clearInterval\",\n \"clearTimeout\",\n\n \"require\",\n \"exports\",\n\n \"eval\",\n \"isFinite\",\n \"isNaN\",\n \"parseFloat\",\n \"parseInt\",\n \"decodeURI\",\n \"decodeURIComponent\",\n \"encodeURI\",\n \"encodeURIComponent\",\n \"escape\",\n \"unescape\"\n];\n\nconst BUILT_IN_VARIABLES = [\n \"arguments\",\n \"this\",\n \"super\",\n \"console\",\n \"window\",\n \"document\",\n \"localStorage\",\n \"sessionStorage\",\n \"module\",\n \"global\" // Node.js\n];\n\nconst BUILT_INS = [].concat(\n BUILT_IN_GLOBALS,\n TYPES,\n ERROR_TYPES\n);\n\n/*\nLanguage: JavaScript\nDescription: JavaScript (JS) is a lightweight, interpreted, or just-in-time compiled programming language with first-class functions.\nCategory: common, scripting, web\nWebsite: https://developer.mozilla.org/en-US/docs/Web/JavaScript\n*/\n\n\n/** @type LanguageFn */\nfunction javascript(hljs) {\n const regex = hljs.regex;\n /**\n * Takes a string like \" {\n const tag = \"',\n end: ''\n };\n // to avoid some special cases inside isTrulyOpeningTag\n const XML_SELF_CLOSING = /<[A-Za-z0-9\\\\._:-]+\\s*\\/>/;\n const XML_TAG = {\n begin: /<[A-Za-z0-9\\\\._:-]+/,\n end: /\\/[A-Za-z0-9\\\\._:-]+>|\\/>/,\n /**\n * @param {RegExpMatchArray} match\n * @param {CallbackResponse} response\n */\n isTrulyOpeningTag: (match, response) => {\n const afterMatchIndex = match[0].length + match.index;\n const nextChar = match.input[afterMatchIndex];\n if (\n // HTML should not include another raw `<` inside a tag\n // nested type?\n // `>`, etc.\n nextChar === \"<\" ||\n // the , gives away that this is not HTML\n // ``\n nextChar === \",\"\n ) {\n response.ignoreMatch();\n return;\n }\n\n // ``\n // Quite possibly a tag, lets look for a matching closing tag...\n if (nextChar === \">\") {\n // if we cannot find a matching closing tag, then we\n // will ignore it\n if (!hasClosingTag(match, { after: afterMatchIndex })) {\n response.ignoreMatch();\n }\n }\n\n // `` (self-closing)\n // handled by simpleSelfClosing rule\n\n let m;\n const afterMatch = match.input.substring(afterMatchIndex);\n\n // some more template typing stuff\n // (key?: string) => Modify<\n if ((m = afterMatch.match(/^\\s*=/))) {\n response.ignoreMatch();\n return;\n }\n\n // ``\n // technically this could be HTML, but it smells like a type\n // NOTE: This is ugh, but added specifically for https://github.com/highlightjs/highlight.js/issues/3276\n if ((m = afterMatch.match(/^\\s+extends\\s+/))) {\n if (m.index === 0) {\n response.ignoreMatch();\n // eslint-disable-next-line no-useless-return\n return;\n }\n }\n }\n };\n const KEYWORDS$1 = {\n $pattern: IDENT_RE,\n keyword: KEYWORDS,\n literal: LITERALS,\n built_in: BUILT_INS,\n \"variable.language\": BUILT_IN_VARIABLES\n };\n\n // https://tc39.es/ecma262/#sec-literals-numeric-literals\n const decimalDigits = '[0-9](_?[0-9])*';\n const frac = `\\\\.(${decimalDigits})`;\n // DecimalIntegerLiteral, including Annex B NonOctalDecimalIntegerLiteral\n // https://tc39.es/ecma262/#sec-additional-syntax-numeric-literals\n const decimalInteger = `0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*`;\n const NUMBER = {\n className: 'number',\n variants: [\n // DecimalLiteral\n { begin: `(\\\\b(${decimalInteger})((${frac})|\\\\.)?|(${frac}))` +\n `[eE][+-]?(${decimalDigits})\\\\b` },\n { begin: `\\\\b(${decimalInteger})\\\\b((${frac})\\\\b|\\\\.)?|(${frac})\\\\b` },\n\n // DecimalBigIntegerLiteral\n { begin: `\\\\b(0|[1-9](_?[0-9])*)n\\\\b` },\n\n // NonDecimalIntegerLiteral\n { begin: \"\\\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\\\b\" },\n { begin: \"\\\\b0[bB][0-1](_?[0-1])*n?\\\\b\" },\n { begin: \"\\\\b0[oO][0-7](_?[0-7])*n?\\\\b\" },\n\n // LegacyOctalIntegerLiteral (does not include underscore separators)\n // https://tc39.es/ecma262/#sec-additional-syntax-numeric-literals\n { begin: \"\\\\b0[0-7]+n?\\\\b\" },\n ],\n relevance: 0\n };\n\n const SUBST = {\n className: 'subst',\n begin: '\\\\$\\\\{',\n end: '\\\\}',\n keywords: KEYWORDS$1,\n contains: [] // defined later\n };\n const HTML_TEMPLATE = {\n begin: '\\.?html`',\n end: '',\n starts: {\n end: '`',\n returnEnd: false,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ],\n subLanguage: 'xml'\n }\n };\n const CSS_TEMPLATE = {\n begin: '\\.?css`',\n end: '',\n starts: {\n end: '`',\n returnEnd: false,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ],\n subLanguage: 'css'\n }\n };\n const GRAPHQL_TEMPLATE = {\n begin: '\\.?gql`',\n end: '',\n starts: {\n end: '`',\n returnEnd: false,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ],\n subLanguage: 'graphql'\n }\n };\n const TEMPLATE_STRING = {\n className: 'string',\n begin: '`',\n end: '`',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ]\n };\n const JSDOC_COMMENT = hljs.COMMENT(\n /\\/\\*\\*(?!\\/)/,\n '\\\\*/',\n {\n relevance: 0,\n contains: [\n {\n begin: '(?=@[A-Za-z]+)',\n relevance: 0,\n contains: [\n {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n },\n {\n className: 'type',\n begin: '\\\\{',\n end: '\\\\}',\n excludeEnd: true,\n excludeBegin: true,\n relevance: 0\n },\n {\n className: 'variable',\n begin: IDENT_RE$1 + '(?=\\\\s*(-)|$)',\n endsParent: true,\n relevance: 0\n },\n // eat spaces (not newlines) so we can find\n // types or variables\n {\n begin: /(?=[^\\n])\\s/,\n relevance: 0\n }\n ]\n }\n ]\n }\n );\n const COMMENT = {\n className: \"comment\",\n variants: [\n JSDOC_COMMENT,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.C_LINE_COMMENT_MODE\n ]\n };\n const SUBST_INTERNALS = [\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n HTML_TEMPLATE,\n CSS_TEMPLATE,\n GRAPHQL_TEMPLATE,\n TEMPLATE_STRING,\n // Skip numbers when they are part of a variable name\n { match: /\\$\\d+/ },\n NUMBER,\n // This is intentional:\n // See https://github.com/highlightjs/highlight.js/issues/3288\n // hljs.REGEXP_MODE\n ];\n SUBST.contains = SUBST_INTERNALS\n .concat({\n // we need to pair up {} inside our subst to prevent\n // it from ending too early by matching another }\n begin: /\\{/,\n end: /\\}/,\n keywords: KEYWORDS$1,\n contains: [\n \"self\"\n ].concat(SUBST_INTERNALS)\n });\n const SUBST_AND_COMMENTS = [].concat(COMMENT, SUBST.contains);\n const PARAMS_CONTAINS = SUBST_AND_COMMENTS.concat([\n // eat recursive parens in sub expressions\n {\n begin: /(\\s*)\\(/,\n end: /\\)/,\n keywords: KEYWORDS$1,\n contains: [\"self\"].concat(SUBST_AND_COMMENTS)\n }\n ]);\n const PARAMS = {\n className: 'params',\n // convert this to negative lookbehind in v12\n begin: /(\\s*)\\(/, // to match the parms with \n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS$1,\n contains: PARAMS_CONTAINS\n };\n\n // ES6 classes\n const CLASS_OR_EXTENDS = {\n variants: [\n // class Car extends vehicle\n {\n match: [\n /class/,\n /\\s+/,\n IDENT_RE$1,\n /\\s+/,\n /extends/,\n /\\s+/,\n regex.concat(IDENT_RE$1, \"(\", regex.concat(/\\./, IDENT_RE$1), \")*\")\n ],\n scope: {\n 1: \"keyword\",\n 3: \"title.class\",\n 5: \"keyword\",\n 7: \"title.class.inherited\"\n }\n },\n // class Car\n {\n match: [\n /class/,\n /\\s+/,\n IDENT_RE$1\n ],\n scope: {\n 1: \"keyword\",\n 3: \"title.class\"\n }\n },\n\n ]\n };\n\n const CLASS_REFERENCE = {\n relevance: 0,\n match:\n regex.either(\n // Hard coded exceptions\n /\\bJSON/,\n // Float32Array, OutT\n /\\b[A-Z][a-z]+([A-Z][a-z]*|\\d)*/,\n // CSSFactory, CSSFactoryT\n /\\b[A-Z]{2,}([A-Z][a-z]+|\\d)+([A-Z][a-z]*)*/,\n // FPs, FPsT\n /\\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\\d)*([A-Z][a-z]*)*/,\n // P\n // single letters are not highlighted\n // BLAH\n // this will be flagged as a UPPER_CASE_CONSTANT instead\n ),\n className: \"title.class\",\n keywords: {\n _: [\n // se we still get relevance credit for JS library classes\n ...TYPES,\n ...ERROR_TYPES\n ]\n }\n };\n\n const USE_STRICT = {\n label: \"use_strict\",\n className: 'meta',\n relevance: 10,\n begin: /^\\s*['\"]use (strict|asm)['\"]/\n };\n\n const FUNCTION_DEFINITION = {\n variants: [\n {\n match: [\n /function/,\n /\\s+/,\n IDENT_RE$1,\n /(?=\\s*\\()/\n ]\n },\n // anonymous function\n {\n match: [\n /function/,\n /\\s*(?=\\()/\n ]\n }\n ],\n className: {\n 1: \"keyword\",\n 3: \"title.function\"\n },\n label: \"func.def\",\n contains: [ PARAMS ],\n illegal: /%/\n };\n\n const UPPER_CASE_CONSTANT = {\n relevance: 0,\n match: /\\b[A-Z][A-Z_0-9]+\\b/,\n className: \"variable.constant\"\n };\n\n function noneOf(list) {\n return regex.concat(\"(?!\", list.join(\"|\"), \")\");\n }\n\n const FUNCTION_CALL = {\n match: regex.concat(\n /\\b/,\n noneOf([\n ...BUILT_IN_GLOBALS,\n \"super\",\n \"import\"\n ].map(x => `${x}\\\\s*\\\\(`)),\n IDENT_RE$1, regex.lookahead(/\\s*\\(/)),\n className: \"title.function\",\n relevance: 0\n };\n\n const PROPERTY_ACCESS = {\n begin: regex.concat(/\\./, regex.lookahead(\n regex.concat(IDENT_RE$1, /(?![0-9A-Za-z$_(])/)\n )),\n end: IDENT_RE$1,\n excludeBegin: true,\n keywords: \"prototype\",\n className: \"property\",\n relevance: 0\n };\n\n const GETTER_OR_SETTER = {\n match: [\n /get|set/,\n /\\s+/,\n IDENT_RE$1,\n /(?=\\()/\n ],\n className: {\n 1: \"keyword\",\n 3: \"title.function\"\n },\n contains: [\n { // eat to avoid empty params\n begin: /\\(\\)/\n },\n PARAMS\n ]\n };\n\n const FUNC_LEAD_IN_RE = '(\\\\(' +\n '[^()]*(\\\\(' +\n '[^()]*(\\\\(' +\n '[^()]*' +\n '\\\\)[^()]*)*' +\n '\\\\)[^()]*)*' +\n '\\\\)|' + hljs.UNDERSCORE_IDENT_RE + ')\\\\s*=>';\n\n const FUNCTION_VARIABLE = {\n match: [\n /const|var|let/, /\\s+/,\n IDENT_RE$1, /\\s*/,\n /=\\s*/,\n /(async\\s*)?/, // async is optional\n regex.lookahead(FUNC_LEAD_IN_RE)\n ],\n keywords: \"async\",\n className: {\n 1: \"keyword\",\n 3: \"title.function\"\n },\n contains: [\n PARAMS\n ]\n };\n\n return {\n name: 'JavaScript',\n aliases: ['js', 'jsx', 'mjs', 'cjs'],\n keywords: KEYWORDS$1,\n // this will be extended by TypeScript\n exports: { PARAMS_CONTAINS, CLASS_REFERENCE },\n illegal: /#(?![$_A-z])/,\n contains: [\n hljs.SHEBANG({\n label: \"shebang\",\n binary: \"node\",\n relevance: 5\n }),\n USE_STRICT,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n HTML_TEMPLATE,\n CSS_TEMPLATE,\n GRAPHQL_TEMPLATE,\n TEMPLATE_STRING,\n COMMENT,\n // Skip numbers when they are part of a variable name\n { match: /\\$\\d+/ },\n NUMBER,\n CLASS_REFERENCE,\n {\n className: 'attr',\n begin: IDENT_RE$1 + regex.lookahead(':'),\n relevance: 0\n },\n FUNCTION_VARIABLE,\n { // \"value\" container\n begin: '(' + hljs.RE_STARTERS_RE + '|\\\\b(case|return|throw)\\\\b)\\\\s*',\n keywords: 'return throw case',\n relevance: 0,\n contains: [\n COMMENT,\n hljs.REGEXP_MODE,\n {\n className: 'function',\n // we have to count the parens to make sure we actually have the\n // correct bounding ( ) before the =>. There could be any number of\n // sub-expressions inside also surrounded by parens.\n begin: FUNC_LEAD_IN_RE,\n returnBegin: true,\n end: '\\\\s*=>',\n contains: [\n {\n className: 'params',\n variants: [\n {\n begin: hljs.UNDERSCORE_IDENT_RE,\n relevance: 0\n },\n {\n className: null,\n begin: /\\(\\s*\\)/,\n skip: true\n },\n {\n begin: /(\\s*)\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS$1,\n contains: PARAMS_CONTAINS\n }\n ]\n }\n ]\n },\n { // could be a comma delimited list of params to a function call\n begin: /,/,\n relevance: 0\n },\n {\n match: /\\s+/,\n relevance: 0\n },\n { // JSX\n variants: [\n { begin: FRAGMENT.begin, end: FRAGMENT.end },\n { match: XML_SELF_CLOSING },\n {\n begin: XML_TAG.begin,\n // we carefully check the opening tag to see if it truly\n // is a tag and not a false positive\n 'on:begin': XML_TAG.isTrulyOpeningTag,\n end: XML_TAG.end\n }\n ],\n subLanguage: 'xml',\n contains: [\n {\n begin: XML_TAG.begin,\n end: XML_TAG.end,\n skip: true,\n contains: ['self']\n }\n ]\n }\n ],\n },\n FUNCTION_DEFINITION,\n {\n // prevent this from getting swallowed up by function\n // since they appear \"function like\"\n beginKeywords: \"while if switch catch for\"\n },\n {\n // we have to count the parens to make sure we actually have the correct\n // bounding ( ). There could be any number of sub-expressions inside\n // also surrounded by parens.\n begin: '\\\\b(?!function)' + hljs.UNDERSCORE_IDENT_RE +\n '\\\\(' + // first parens\n '[^()]*(\\\\(' +\n '[^()]*(\\\\(' +\n '[^()]*' +\n '\\\\)[^()]*)*' +\n '\\\\)[^()]*)*' +\n '\\\\)\\\\s*\\\\{', // end parens\n returnBegin:true,\n label: \"func.def\",\n contains: [\n PARAMS,\n hljs.inherit(hljs.TITLE_MODE, { begin: IDENT_RE$1, className: \"title.function\" })\n ]\n },\n // catch ... so it won't trigger the property rule below\n {\n match: /\\.\\.\\./,\n relevance: 0\n },\n PROPERTY_ACCESS,\n // hack: prevents detection of keywords in some circumstances\n // .keyword()\n // $keyword = x\n {\n match: '\\\\$' + IDENT_RE$1,\n relevance: 0\n },\n {\n match: [ /\\bconstructor(?=\\s*\\()/ ],\n className: { 1: \"title.function\" },\n contains: [ PARAMS ]\n },\n FUNCTION_CALL,\n UPPER_CASE_CONSTANT,\n CLASS_OR_EXTENDS,\n GETTER_OR_SETTER,\n {\n match: /\\$[(.]/ // relevance booster for a pattern common to JS libs: `$(something)` and `$.something`\n }\n ]\n };\n}\n\nexport { javascript as default };\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport componentCss from './code-block.scss?inline';\nimport { unsafeHTML } from 'lit/directives/unsafe-html.js';\nimport hljs from 'highlight.js/lib/core';\nimport javascript from 'highlight.js/lib/languages/javascript';\n\nhljs.registerLanguage('javascript', javascript);\n\nexport class CodeBlock extends LitElement {\n static styles = [unsafeCSS(componentCss)];\n static properties = {\n language: { type: String },\n code: { tyoe: String, state: true }\n };\n\n constructor(props) {\n super(props);\n this.language = 'javascript';\n }\n\n #onCodeChanged() {\n const slottedElements = this.shadowRoot.querySelector('slot').assignedNodes();\n const codeStr = slottedElements[0].textContent;\n\n this.code = hljs.highlight(codeStr, { language: this.language }).value;\n }\n\n render() {\n return html`\n
${unsafeHTML(this.code)}
\n this.#onCodeChanged()}\">\n `;\n }\n}\n\ncustomElements.define('code-block', CodeBlock);\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport '../../../components/code-block/code-block';\nimport { animations, theme } from '../../../theme/theme';\nimport showcaseComponentCss from './showcase-component.scss?inline';\nimport { when } from 'lit/directives/when.js';\nimport { classMap } from 'lit/directives/class-map.js';\n\nexport class ShowcaseComponent extends LitElement {\n static styles = [theme, animations, unsafeCSS(showcaseComponentCss)];\n\n static properties = {\n collapsed: { type: Boolean },\n hasCodeExample: { type: Boolean, state: true },\n exampleLanguage: { type: String },\n href: { type: String }\n };\n\n connectedCallback() {\n super.connectedCallback();\n this.collapsed = true;\n this.shadowRoot.addEventListener('slotchange', () => {\n this.hasCodeExample = this.#hasSlot('code');\n });\n }\n\n updated(_changedProperties) {\n super.updated(_changedProperties);\n\n if (_changedProperties.has('collapsed') && !this.collapsed) {\n this.shadowRoot.querySelector('[part=\"implementation\"]').classList.add('active');\n }\n }\n\n #hasSlot(name) {\n return this.shadowRoot.querySelector(`slot[name=\"${name}\"]`).assignedNodes().length > 0;\n }\n\n #implementationSectionAnimationEnd(e) {\n e.target.classList.toggle('active', !e.target.classList.contains('fade-out-shrink'));\n e.target.classList.remove('fade-in-grow', 'fade-out-shrink');\n }\n\n #implementationSectionClassMap() {\n return {\n 'fade-in-grow': this.collapsed === false,\n 'fade-out-shrink': this.collapsed === true\n };\n }\n\n render() {\n return html`\n \n \n\n
\n

{\n this.collapsed = !this.collapsed;\n }}\">\n ${this.collapsed ? 'visibility' : 'visibility_off'}\n ${this.collapsed ? 'See the Implementation' : 'Hide the Implementation'} \n

\n
this.#implementationSectionAnimationEnd(e)}\">\n
\n \n
\n ${when(this.href, () => html`\n
\n \n view on github\n \n
\n `)}\n
\n
\n `;\n }\n}\n\ncustomElements.define('showcase-component', ShowcaseComponent);\n","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Start Time Showcase\\n \\n \\n\\n\\n\\n\\n
\\n

Start the player at a given position

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Multi Player Showcase\\n \\n \\n\\n\\n\\n\\n
\\n

Multiple players

\\n\\n
\\n \\n
\\n\\n \\n\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Detect blocked segment\\n \\n \\n\\n\\n\\n\\n
\\n

Detect blocked segment

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Display Current Chapter\\n \\n \\n\\n\\n\\n\\n
\\n

Display Current Chapter

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Skip Credits\\n \\n \\n\\n\\n\\n\\n
\\n

Skip Credits

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Playlist\\n \\n \\n\\n\\n\\n\\n
\\n

Playlist

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","export default \"\\n\\n\\n \\n \\n \\n Pillarbox Demo - Quality Menu\\n \\n \\n\\n\\n\\n\\n
\\n

Quality Menu

\\n
\\n \\n
\\n\\n \\n
\\n\\n\\n\\n\\n\\n\\n\\n\"","/**\n * Aligns the lines of a block of code by removing leading spaces.\n *\n * This function calculates the number of leading spaces on the first line of the code,\n * then creates a regular expression that matches this number of leading spaces.\n * It finally replaces these leading spaces in each line of the code.\n *\n * @param {string} code - The block of code to align.\n * @returns {string} The aligned block of code.\n */\nfunction alignLines(code) {\n // Remove leading and trailing new lines.\n const normalizeCode = code.replace(/^[\\r\\n]+|[\\r\\n]+$/g, '');\n // Calculate the number of leading spaces on the first line\n const firstLine = normalizeCode.split('\\n')[0];\n const leadingSpaces = firstLine.match(/^ */)[0].length;\n // Create a regular expression that matches 'leadingSpaces' number of leading spaces\n const regex = new RegExp(`^ {${leadingSpaces}}`, 'gm');\n\n // Replace leading spaces in each line\n return normalizeCode.replace(regex, '');\n}\n\nconst parser = new DOMParser();\n\n/**\n * Parses an HTML string and returns the text content of the first element that matches the provided selector.\n *\n * @param {string} html - The HTML string to parse.\n * @param {string} [selector='[data-implementation]'] - The CSS selector to match elements. Defaults to '[data-example]'.\n * @returns {string} The text content of the first matching element. If no elements match the selector, it returns an empty string.\n *\n * @example\n * const html = '
Hello, world!
';\n * const content = parseHTML(html);\n * console.log(content); // Logs: 'Hello, world!'\n */\nexport function getTextFromHTML(html, selector = '[data-implementation]') {\n return alignLines(\n parser.parseFromString(html, 'text/html').querySelector(selector).textContent\n );\n}\n","import router from '../../../router/router';\nimport { html, LitElement, unsafeCSS } from 'lit';\nimport { animations, theme } from '../../../theme/theme';\nimport './showcase-component.js';\nimport '../../../components/code-block/code-block';\nimport showcasePageCss from './showcase-page.scss?inline';\nimport rawStartTimeExample from '../../../../static/showcases/start-time.html?raw';\nimport rawMultiPlayerExample from '../../../../static/showcases/multi-player.html?raw';\nimport rawDetectBlockedSegmentsExample from '../../../../static/showcases/blocked-segment.html?raw';\nimport rawDisplayCurrentChapterExample from '../../../../static/showcases/chapters.html?raw';\nimport rawSkipCreditsExample from '../../../../static/showcases/skip-credits.html?raw';\nimport rawPlaylistExample from '../../../../static/showcases/playlist.html?raw';\nimport rawqualityMenuExample from '../../../../static/showcases/quality-menu.html?raw';\nimport { getTextFromHTML } from './example-parser.js';\n\nconst startTimeExampleTxt = getTextFromHTML(rawStartTimeExample);\nconst multiPlayerExampleTxt = getTextFromHTML(rawMultiPlayerExample);\nconst detectBlockedSegmentsExampleTxt =\n getTextFromHTML(rawDetectBlockedSegmentsExample);\nconst displayCurrentChapterExampleTxt =\n getTextFromHTML(rawDisplayCurrentChapterExample);\nconst skipCreditsExampleTxt = getTextFromHTML(rawSkipCreditsExample);\nconst playlistExampleTxt = getTextFromHTML(rawPlaylistExample);\nconst qualityMenuExampleTxt = getTextFromHTML(rawqualityMenuExample);\n\nexport class ShowCasePage extends LitElement {\n static styles = [theme, animations, unsafeCSS(showcasePageCss)];\n\n render() {\n return html`\n ${this.#renderStartTime()}\n ${this.#renderMultiplePlayers()}\n ${this.#renderDetectBlockedSegments()}\n ${this.#renderDisplayCurrentChapter()}\n ${this.#renderSkipCredits()}\n ${this.#renderPlaylist()}\n ${this.#renderQualityMenu()}\n `;\n }\n\n #renderStartTime() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Start the player at a given position

\n

\n In this showcase, we'll demonstrate how to load a video source and\n start playback at a specific position using Pillarbox. This can be\n useful when you want to provide users with the option to begin\n watching a video from a predefined timestamp. To achieve this\n functionality, follow the code snippet below:\n

\n ${startTimeExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderMultiplePlayers() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Multiple Players

\n

\n This example demonstrates how to incorporate multiple video players\n on a webpage.In this showcase, two players are initialized, each\n with its own configuration, a button allows to toggle the mute state\n for both players.\n

\n ${multiPlayerExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderDetectBlockedSegments() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Detect Blocked Segments

\n

\n This tutorial covers how to use pillarbox to create a plugin that\n detects and notifies when a blocked segment is skipped.\n

\n ${detectBlockedSegmentsExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderDisplayCurrentChapter() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Display Current Chapter

\n

\n This showcase explains how to use pillarbox to create a plugin that\n displays the currently playing chapter in a box above the progress\n bar.\n

\n ${displayCurrentChapterExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderSkipCredits() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Skip Credits

\n

\n This example shows how to use the\n Pillarbox Skip Button component\n to add a \"Skip\" button during detected credit intervals.\n

\n ${skipCreditsExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderPlaylist() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Playlist

\n

\n This example shows how to fetch media data for a set of video sources \n and load them into the Pillarbox Playlist plugin\n with metadata such as title and duration.\n

\n ${playlistExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n\n #renderQualityMenu() {\n return html`\n
e.target.classList.remove('fade-in')}\">\n \n

Quality Menu

\n

\n In this showcase, we'll demonstrate howto display a quality selector\n menu using the videojs-contrib-quality-menu\n plugin.\n

\n ${qualityMenuExampleTxt}\n
\n \n Open this showcase\n \n
\n `;\n }\n}\n\ncustomElements.define('showcase-page', ShowCasePage);\nrouter.addRoute('showcase', 'showcase-page');\n","import { html, LitElement, unsafeCSS } from 'lit';\nimport '../../router/route-link-component';\nimport { theme } from '../../theme/theme';\nimport headerCSS from './demo-header-component.scss?inline';\nimport router from '../../router/router';\nimport './core-demo-header-component.js';\n\n/**\n * A web component that represents the header of the demo page. This header contains\n * the {@link CoreDemoHeaderComponent} as well as the navigation menu of the\n * different demo app sections.\n *\n * @element demo-header\n *\n * @prop {Boolean} debug - Indicates whether the debug mode is enabled.\n *\n * @example\n * \n */\nexport class DemoHeaderElement extends LitElement {\n static properties = {\n debug: { type: Boolean, state: true }\n };\n\n static styles = [theme, unsafeCSS(headerCSS)];\n\n #onRouteUpdated = ({ detail: { queryParams } }) => {\n this.debug = queryParams.debug === 'true';\n };\n\n connectedCallback() {\n super.connectedCallback();\n\n this.debug = router.queryParams.debug === 'true';\n router.addEventListener('routechanged', this.#onRouteUpdated);\n router.addEventListener('queryparams', this.#onRouteUpdated);\n }\n\n disconnectedCallback() {\n router.removeEventListener('routechanged', this.#onRouteUpdated);\n router.removeEventListener('queryparams', this.#onRouteUpdated);\n }\n\n render() {\n return html`\n ${this.#renderHeaderElement()}\n ${this.#renderNavElement()}\n `;\n }\n\n #renderHeaderElement() {\n return html`\n \n \n settings\n \n \n `;\n }\n\n #renderNavElement() {\n return html`\n `;\n }\n}\n\ncustomElements.define('demo-header', DemoHeaderElement);\n","import router from './router';\nimport { LitElement } from 'lit';\nimport { unsafeHTML } from 'lit/directives/unsafe-html.js';\n\nexport class RouteOutletComponent extends LitElement {\n static properties = {\n route: { state: true }\n };\n\n constructor() {\n super();\n\n this.route = router.currentRoute;\n router.addEventListener('routechanged', ({ detail: { route } }) => {\n this.route?.destroy();\n this.route = route;\n });\n }\n\n render() {\n return unsafeHTML(`<${this.route.component}>`);\n }\n}\n\ncustomElements.define('route-outlet', RouteOutletComponent);\n","/**\n * Main module to import and initialize the demo as a single page application.\n *\n * @module\n */\nimport './components/dialog/demo-dialog-component';\nimport './components/player/player';\nimport './layout/content/examples/examples-page';\nimport './layout/content/lists/lists-page';\nimport './layout/content/search/search-page';\nimport './layout/content/settings/settings-page';\nimport './layout/content/showcase/showcase-page';\nimport './layout/header/demo-header-component.js';\nimport './router/route-outlet-component';\nimport router from './router/router';\nimport PreferencesProvider\n from './layout/content/settings/preferences-provider';\nimport ilProvider from './utils/il-provider.js';\n\n// Load preferences and initializes il host\nconst preferences = PreferencesProvider.loadPreferences();\n\nilProvider.host = preferences.dataProviderHost;\n\n// Initialize the router with the current path or 'examples' if none is found\nrouter.start({ defaultPath: 'examples' });\n\nif (router.queryParams.debug) {\n preferences.debug = router.queryParams.debug === 'true';\n PreferencesProvider.savePreferences(preferences);\n} else if (preferences.debug) {\n router.updateState({ debug: 'true' });\n}\n"],"names":["DemoDialog","LitElement","__privateAdd","_DemoDialog_instances","_dialog","_changedProperties","__privateGet","__privateSet","html","__privateMethod","onDialogClicked_fn","onDialogClosed_fn","__publicField","theme","animations","unsafeCSS","componentCSS","PreferencesProvider","preferences","IL_DEFAULT_HOST","DEFAULT_QUERY_PARAMS","DEFAULT_SEARCH_PARAMS","DEFAULT_SHOWLIST_PARAMS","toMedia","title","urn","mediaType","date","duration","ILProvider","host","_ILProvider_instances","_host","bu","query","signal","data","fetch_fn","toResults","nextProvider_fn","transmission","topicUrn","pageSize","showUrn","mediaList","id","channelId","path","params","queryParams","url","response","reason","nextUrl","resultMapper","nextData","ilProvider","DEMO_PLAYER_ID","DEFAULT_OPTIONS","preferencesToPlayerOptions","createPlayer","options","Pillarbox","destroyPlayer","playerDialog","toParams","keySystems","vendor","toKeySystem","certificateUri","licenseUri","asQueryParams","src","type","router","loadPlayerFromRouter","e","openPlayerModal","playerOptions","shouldUpdateRouter","player","s","i","t","r","_a","_b","LoadMediaFormComponent","_LoadMediaFormComponent_instances","initDrmSettings_fn","btnSettingsClassMap","handleLoadBarKeyUp_fn","classMap","drmSettingsTemplate_fn","submitMedia_fn","getSource_fn","keySystems_get","event","toKeySystem_fn","onFormAnimationEnd_fn","formAnimationClassMap_fn","ContentLinkComponent","_onClick","EXAMPLES","o","f","n","ExamplesPage","map","Examples","section","examples","example","when","css","SpinnerComponent","spinnerCss","DEFAULT_INT_OPTIONS","onIntersecting","target","callback","entries","entry","IntersectionObserverComponent","ScrollToTopComponent","toKebabCase","str","_ListsPageStateManager","root","_ListsPageStateManager_instances","nodes","sectionIndex","findSectionIndex_fn","nodeIndex","findNodeIndex_fn","processNodeString_fn","stackIndex","_ListsPageStateManager_static","params_fn","nodeStr","stack","rootSection","node","sectionStr","normalizedSectionStr","normalizedStr","ListsPageStateManager","Section","resolve","next","toNodesAndNext","listsSections","topic","show","channel","ListsPage","_ListsPage_instances","_abortController","_stateManager","_onQueryParamsChanged","updateState_fn","manager","renderScrollBtn","renderNavigation_fn","renderSpinner_fn","renderResults_fn","renderScrollToTopBtn_fn","toMediaButtonParams_fn","renderMediaButton_fn","toLevelParams_fn","sectionIdx","nodeIdx","renderLevelButton_fn","nextPage_fn","renderNodes_fn","firstSection","hasIntesectionObserver","idx","onSectionsClicked_fn","button","onNavigationClicked_fn","step","DEFAULT_BU","SearchBarComponent","_SearchBarComponent_instances","property","handleSelectChange_fn","handleSearchBarKeyUp_fn","clearSearchBar_fn","SearchPage","_SearchPage_instances","searchBar","search_fn","onSearchBarChanged_fn","fetchNextPage_fn","toQueryParams_fn","renderButton_fn","resultsClassMap","ToggleSwitchComponent","_onKeyDown","force","SettingsPage","_SettingsPage_instances","renderToggle_fn","renderInput_fn","label","componentCss","deepFreeze","obj","name","prop","Response","mode","escapeHTML","value","inherit$1","original","objects","result","key","SPAN_CLOSE","emitsWrappingTags","scopeToCSSClass","prefix","pieces","x","HTMLRenderer","parseTree","text","className","newNode","opts","TokenTree","scope","builder","child","el","TokenTreeEmitter","emitter","source","re","lookahead","concat","anyNumberOfTimes","optional","args","stripOptionsFromArgs","either","countMatchGroups","startsWith","lexeme","match","BACKREF_RE","_rewriteBackreferences","regexps","joinWith","numCaptures","regex","offset","out","MATCH_NOTHING_RE","IDENT_RE","UNDERSCORE_IDENT_RE","NUMBER_RE","C_NUMBER_RE","BINARY_NUMBER_RE","RE_STARTERS_RE","SHEBANG","beginShebang","m","resp","BACKSLASH_ESCAPE","APOS_STRING_MODE","QUOTE_STRING_MODE","PHRASAL_WORDS_MODE","COMMENT","begin","end","modeOptions","ENGLISH_WORD","C_LINE_COMMENT_MODE","C_BLOCK_COMMENT_MODE","HASH_COMMENT_MODE","NUMBER_MODE","C_NUMBER_MODE","BINARY_NUMBER_MODE","REGEXP_MODE","TITLE_MODE","UNDERSCORE_TITLE_MODE","METHOD_GUARD","END_SAME_AS_BEGIN","MODES","skipIfHasPrecedingDot","scopeClassName","_parent","beginKeywords","parent","compileIllegal","compileMatch","compileRelevance","beforeMatchExt","originalMode","COMMON_KEYWORDS","DEFAULT_KEYWORD_SCOPE","compileKeywords","rawKeywords","caseInsensitive","scopeName","compiledKeywords","compileList","keywordList","keyword","pair","scoreForKeyword","providedScore","commonKeyword","seenDeprecations","error","message","warn","deprecated","version","MultiClassError","remapScopeNames","regexes","scopeNames","emit","positions","beginMultiClass","endMultiClass","scopeSugar","MultiClass","compileLanguage","language","langRe","global","MultiRegex","terminators","matchData","ResumableMultiRegex","index","matcher","m2","buildModeRegex","mm","term","compileMode","cmode","ext","keywordPattern","c","expandOrCloneMode","dependencyOnParent","variant","HTMLInjectionError","escape","inherit","NO_MATCH","MAX_KEYWORD_HITS","HLJS","hljs","languages","aliases","plugins","SAFE_MODE","LANGUAGE_NOT_FOUND","PLAINTEXT_LANGUAGE","shouldNotHighlight","languageName","blockLanguage","block","classes","getLanguage","_class","highlight","codeOrLanguageName","optionsOrCode","ignoreIllegals","code","context","fire","_highlight","codeToHighlight","continuation","keywordHits","keywordData","matchText","processKeywords","top","modeBuffer","lastIndex","buf","word","kind","keywordRelevance","relevance","cssClass","emitKeyword","processSubLanguage","continuations","highlightAuto","processBuffer","emitMultiClass","max","klass","startNewMode","endOfMode","matchPlusRemainder","matched","doIgnore","resumeScanAtSamePosition","doBeginMatch","newMode","beforeCallbacks","cb","doEndMatch","endMode","origin","processContinuations","list","current","item","lastMatch","processLexeme","textBeforeMatch","err","processed","iterations","md","beforeMatch","processedCount","justTextHighlightResult","languageSubset","plaintext","results","autoDetection","sorted","a","b","best","secondBest","updateClassName","element","currentLang","resultLang","highlightElement","configure","userOptions","initHighlighting","highlightAll","initHighlightingOnLoad","wantsHighlight","boot","registerLanguage","languageDefinition","lang","error$1","registerAliases","unregisterLanguage","alias","listLanguages","aliasList","upgradePluginAPI","plugin","addPlugin","removePlugin","deprecateHighlightBlock","core","KEYWORDS","LITERALS","TYPES","ERROR_TYPES","BUILT_IN_GLOBALS","BUILT_IN_VARIABLES","BUILT_INS","javascript","hasClosingTag","after","tag","IDENT_RE$1","FRAGMENT","XML_SELF_CLOSING","XML_TAG","afterMatchIndex","nextChar","afterMatch","KEYWORDS$1","decimalDigits","frac","decimalInteger","NUMBER","SUBST","HTML_TEMPLATE","CSS_TEMPLATE","GRAPHQL_TEMPLATE","TEMPLATE_STRING","SUBST_INTERNALS","SUBST_AND_COMMENTS","PARAMS_CONTAINS","PARAMS","CLASS_OR_EXTENDS","CLASS_REFERENCE","USE_STRICT","FUNCTION_DEFINITION","UPPER_CASE_CONSTANT","noneOf","FUNCTION_CALL","PROPERTY_ACCESS","GETTER_OR_SETTER","FUNC_LEAD_IN_RE","FUNCTION_VARIABLE","CodeBlock","props","_CodeBlock_instances","unsafeHTML","onCodeChanged_fn","codeStr","ShowcaseComponent","_ShowcaseComponent_instances","hasSlot_fn","implementationSectionClassMap_fn","implementationSectionAnimationEnd_fn","showcaseComponentCss","rawStartTimeExample","rawMultiPlayerExample","rawDetectBlockedSegmentsExample","rawDisplayCurrentChapterExample","rawSkipCreditsExample","rawPlaylistExample","rawqualityMenuExample","alignLines","normalizeCode","leadingSpaces","parser","getTextFromHTML","selector","startTimeExampleTxt","multiPlayerExampleTxt","detectBlockedSegmentsExampleTxt","displayCurrentChapterExampleTxt","skipCreditsExampleTxt","playlistExampleTxt","qualityMenuExampleTxt","ShowCasePage","_ShowCasePage_instances","renderStartTime_fn","renderMultiplePlayers_fn","renderDetectBlockedSegments_fn","renderDisplayCurrentChapter_fn","renderSkipCredits_fn","renderPlaylist_fn","renderQualityMenu_fn","showcasePageCss","DemoHeaderElement","_DemoHeaderElement_instances","_onRouteUpdated","renderHeaderElement_fn","renderNavElement_fn","headerCSS","RouteOutletComponent","route"],"mappings":"2kCASO,MAAMA,WAAmBC,CAAW,CAWzC,aAAc,CACZ,MAAO,EAZJC,EAAA,KAAAC,IASLD,EAAA,KAAAE,IAIE,KAAK,KAAO,EAChB,CAEE,QAAQC,EAAoB,CAC1B,MAAM,QAAQA,CAAkB,EAE5BA,EAAmB,IAAI,MAAM,IAC3B,KAAK,MACPC,EAAA,KAAKF,IAAQ,UAAW,EACxBE,EAAA,KAAKF,IAAQ,UAAU,OAAO,mBAAoB,EAAI,GAEtDE,EAAA,KAAKF,IAAQ,MAAO,EAG5B,CAEE,aAAaC,EAAoB,CAC/B,MAAM,aAAaA,CAAkB,EACrCE,EAAA,KAAKH,GAAU,KAAK,WAAW,cAAc,QAAQ,EACzD,CAWE,QAAS,CACP,OAAOI;AAAAA;AAAAA,wBAEaC,EAAA,KAAKN,GAAAO,IAAiB,KAAK,IAAI,CAAC;AAAA,wBAChCD,EAAA,KAAKN,GAAAQ,IAAgB,KAAK,IAAI,CAAC;AAAA,+BACxB,GAAK,EAAE,OAAO,UAAU,OAAO,kBAA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AS,CACP,OAAO9F;AAAAA,iBACM,KAAK,IAAI,YAAY,KAAK,KAAK;AAAA,6BACnB,KAAK,KAAK;AAAA;AAAA;AAAA,KAIvC,CACA,CA3BE8F,GAAA,YANA1F,EADWyF,GACJ,aAAa,CAClB,KAAM,CAAA,CACP,GAEDzF,EALWyF,GAKJ,SAAStF,EAAUC,EAAY,GA+BxC,eAAe,OAAO,eAAgBqF,EAAoB,ECvD1D,MAAME,GAAW,CACf,OAAQ,CACN,CACE,MAAO,mBACP,IAAK,yBACL,KAAM,YACP,EACD,CACE,MAAO,eACP,IAAK,wBACL,KAAM,YACP,EACD,CACE,MAAO,iBACP,IAAK,yBACL,KAAM,YACP,EACD,CACE,MAAO,wBACP,YAAa,8BACb,IAAK,8DACL,KAAM,YACP,EACD,CACE,MAAO,sCACP,YAAa,qBACb,IAAK,yBACL,KAAM,YACP,EACD,CACE,MAAO,sBACP,YAAa,kBACb,IAAK,yBACL,KAAM,YACP,EACD,CACE,MAAO,aACP,YAAa,QACb,IAAK,qDACL,KAAM,YACP,EACD,CACE,MAAO,uBACP,YAAa,QACb,IAAK,wBACL,KAAM,YACP,EACD,CACE,MAAO,uBACP,YAAa,kBACb,IAAK,wBACL,KAAM,YACP,EACD,CACE,MAAO,yBACP,YAAa,4DACb,IAAK,wBACL,KAAM,YACP,EACD,CACE,MAAO,cACP,YAAa,wCACb,IAAK,yBACL,KAAM,YACP,EACD,CACE,MAAO,cACP,YAAa,8BACb,IAAK,wBACL,KAAM,YACZ,CACG,EACD,IAAK,CACH,CACE,MAAO,YACP,YAAa,8CACb,IAAK,+DACL,KAAM,uBACP,EACD,CACE,MAAO,oBACP,YAAa,uEACb,IAAK,iGACL,KAAM,uBACP,EACD,CACE,MAAO,gCACP,YAAa,WACb,IAAK,8EACL,KAAM,uBACP,EACD,CACE,MAAO,yBACP,YAAa,4BACb,IAAK,iFACL,KAAM,uBACP,EACD,CACE,MAAO,kCACP,YAAa,2BACb,IAAK,4EACL,KAAM,uBACP,EACD,CACE,MAAO,iDACP,YAAa,YACb,IAAK,wFACL,KAAM,uBACP,EACD,CACE,MAAO,yBACP,YAAa,kBACb,IAAK,qEACL,KAAM,uBACP,EACD,CACE,MAAO,kBACP,YAAa,iCACb,IAAK,kGACL,KAAM,uBACP,EACD,CACE,MAAO,mBACP,YAAa,kCACb,IAAK,oGACL,KAAM,uBACP,EACD,CACE,MAAO,2BACP,YAAa,6DACb,IAAK,qGACL,KAAM,uBACP,EACD,CACE,MAAO,6BACP,YAAa,2DACb,IAAK,uGACL,KAAM,uBACP,EACD,CACE,MAAO,mCACP,YAAa,oDACb,IAAK,mGACL,KAAM,uBACP,EACD,CACE,MAAO,cACP,IAAK,sFACL,KAAM,uBACP,EACD,CACE,MAAO,0BACP,IAAK,0HACL,KAAM,uBACP,EACD,CACE,MAAO,mBACP,YAAa,sCACb,IAAK;AAAA,EACL,KAAM,uBACP,EACD,CACE,MAAO,sCACP,YAAa,kCACb,IAAK,mEACL,KAAM,uBACP,EACD,CACE,MAAO,WACP,IAAK,wFACL,KAAM,uBACP,EACD,CACE,MAAO,0BACP,IAAK,2GACL,KAAM,uBACP,EACD,CACE,MAAO,UACP,IAAK,6EACL,KAAM,uBACP,EACD,CACE,MAAO,uBACP,IAAK,uGACL,KAAM,uBACP,EACD,CACE,MAAO,iCACP,IAAK,kHACL,KAAM,uBACP,EACD,CACE,MAAO,mBACP,IAAK,6IACL,KAAM,uBACP,EACD,CACE,MAAO,kBACP,IAAK,wHACL,KAAM,uBACP,EACD,CACE,MAAO,yBACP,IAAK,0HACL,KAAM,uBACP,EACD,CACE,MAAO,0BACP,IAAK,oOACL,KAAM,uBACP,EACD,CACE,MAAO,YACP,IAAK,qEACL,KAAM,uBACP,EACD,CACE,MAAO,wBACP,IAAK,oFACL,KAAM,uBACP,EACD,CACE,MAAO,aACP,IAAK,gGACL,KAAM,uBACP,EACD,CACE,MAAO,qBACP,IAAK,uEACL,KAAM,uBACP,EACD,CACE,MAAO,cACP,IAAK,4GACL,KAAM,uBACP,EACD,CACE,MAAO,gBACP,IAAK,4GACL,KAAM,uBACP,EACD,CACE,MAAO,QACP,YAAa,mBACb,IAAK,2EACL,KAAM,uBACZ,CACG,EACD,KAAM,CACJ,CACE,MAAO,oBACP,IAAK,oEACL,KAAM,sBACP,EACD,CACE,MAAO,kCACP,IAAK,mEACL,KAAM,uBACN,WAAY,CACV,qBAAsB,iFAC9B,CACK,EACD,CACE,MAAO,oBACP,IAAK,oEACL,KAAM,sBACP,EACD,CACE,MAAO,kCACP,IAAK,mEACL,KAAM,uBACN,WAAY,CACV,qBAAsB,iFAC9B,CACK,EACD,CACE,MAAO,mBACP,IAAK,sGACL,KAAM,sBACP,EACD,CACE,MAAO,wBACP,IAAK,sGACL,KAAM,sBACP,EACD,CACE,MAAO,mBACP,IAAK,uHACL,KAAM,sBACP,EACD,CACE,MAAO,0CACP,IAAK,gIACL,KAAM,sBACP,EACD,CACE,MAAO,yCACP,IAAK,+GACL,KAAM,sBACP,EACD,CACE,MAAO,kCACP,IAAK,yGACL,KAAM,sBACP,EACD,CACE,MAAO,2CACP,IAAK,8GACL,KAAM,sBACP,EACD,CACE,MAAO,oCACP,IAAK,2GACL,KAAM,sBACP,EACD,CACE,MAAO,oBACP,IAAK,4IACL,KAAM,sBACP,EACD,CACE,MAAO,+BACP,IAAK,kHACL,KAAM,sBACP,EACD,CACE,MAAO,kCACP,IAAK,iHACL,KAAM,sBACP,EACD,CACE,MAAO,2CACP,IAAK,+GACL,KAAM,sBACP,EACD,CACE,MAAO,mBACP,IAAK,oEACL,KAAM,sBACP,EACD,CACE,MAAO,+BACP,IAAK,mFACL,KAAM,sBACP,EACD,CACE,MAAO,8BACP,IAAK,gFACL,KAAM,sBACZ,CACG,EACD,IAAK,CACH,CACE,MAAO,YACP,YAAa,UACb,IAAK,iIACL,KAAM,WACP,EACD,CACE,MAAO,kBACP,IAAK,6GACL,KAAM,WACZ,CACG,EACD,IAAK,CACH,CACE,MAAO,YACP,YAAa,4BAC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B,EAAOE,EAAU+hB,EAAS,CAAC,GAgE9C,eAAe,OAAO,cAAeL,EAAiB,ECpF/C,MAAMM,WAA6B9iB,CAAW,CAKnD,aAAc,CACZ,MAAO,EAEP,KAAK,MAAQyE,EAAO,aACpBA,EAAO,iBAAiB,eAAgB,CAAC,CAAE,OAAQ,CAAE,MAAAse,CAAK,KAAS,QACjE3d,EAAA,KAAK,QAAL,MAAAA,EAAY,UACZ,KAAK,MAAQ2d,CACnB,CAAK,CACL,CAEE,QAAS,CACP,OAAO9C,GAAW,IAAI,KAAK,MAAM,SAAS,MAAM,KAAK,MAAM,SAAS,GAAG,CAC3E,CACA,CAjBEtf,EADWmiB,GACJ,aAAa,CAClB,MAAO,CAAE,MAAO,EAAI,CACrB,GAiBH,eAAe,OAAO,eAAgBA,EAAoB,ECJ1D,MAAM7hB,GAAcD,GAAoB,gBAAiB,EAEzDuC,EAAW,KAAOtC,GAAY,iBAG9BwD,EAAO,MAAM,CAAE,YAAa,WAAY,EAEpCA,EAAO,YAAY,OACrBxD,GAAY,MAAQwD,EAAO,YAAY,QAAU,OACjDzD,GAAoB,gBAAgBC,EAAW,GACtCA,GAAY,OACrBwD,EAAO,YAAY,CAAE,MAAO,MAAM,CAAE","x_google_ignoreList":[4,8,9,22,23]} \ No newline at end of file diff --git a/pr-preview/pr-45/assets/quality-menu-B8MP43Ca.js b/pr-preview/pr-45/assets/quality-menu-B8MP43Ca.js deleted file mode 100644 index a34d83f..0000000 --- a/pr-preview/pr-45/assets/quality-menu-B8MP43Ca.js +++ /dev/null @@ -1,2 +0,0 @@ -import{v as u,p as b}from"./core-demo-header-component-BNyRgtzK.js";/* empty css *//*! @name videojs-contrib-quality-menu @version 1.0.3 @license Apache-2.0 */const m=u.getComponent("MenuItem"),p=u.dom||u;class c extends m{constructor(e,t={}){const s=t.selected;t.selected=t.active,super(e,t);const l=e.qualityLevels();this.levels_=t.levels,this.selected_=s,this.handleQualityChange=this.handleQualityChange.bind(this),this.controlText(t.controlText),this.on(l,"change",this.handleQualityChange),this.on("dispose",()=>{this.off(l,"change",this.handleQualityChange)})}createEl(e,t,s){const l=super.createEl(e,t,s),n=p.createEl("span",{className:"vjs-quality-menu-item-sub-label",innerHTML:this.localize(this.options_.subLabel||"")});return this.subLabel_=n,l&&l.appendChild(n),l}handleClick(){this.updateSiblings_();const e=this.player().qualityLevels(),t=e.selectedIndex;for(let s=0,l=e.length;s-1;this.selected(t)}selected(e){if(this.selectable)if(this.selected_){this.addClass("vjs-selected"),this.el_.setAttribute("aria-checked","true"),this.controlText(this.localize("{1}, selected",this.localize(this.options_.controlText)));const s=this.player().controlBar.getChild("QualityMenuButton");e?s.removeClass("vjs-quality-menu-button-waiting"):s.addClass("vjs-quality-menu-button-waiting")}else this.removeClass("vjs-selected"),this.el_.setAttribute("aria-checked","false"),this.controlText(this.options_.controlText)}updateSiblings_(){const e=this.player().qualityLevels(),s=this.player().controlBar.getChild("QualityMenuButton").items;for(let l=0,n=s.length;l-1;a.selected_=a===this,a.selected(r)}}}const q=u.getComponent("MenuButton"),v=function(i){return Array.from(i).some(e=>e.height)},f=function(i){return i>=2160?"4K":i>=720?"HD":""};class L extends q{constructor(e,t={}){super(e,t),this.el_.setAttribute("aria-label",this.localize("Quality Levels")),this.controlText("Quality Levels"),e.options().experimentalSvgIcons||this.$(".vjs-icon-placeholder").classList.add("vjs-icon-cog"),this.setIcon("cog"),this.qualityLevels_=e.qualityLevels(),this.update=this.update.bind(this),this.hide=this.hide.bind(this),this.handleQualityChange_=this.handleQualityChange_.bind(this),this.firstChangeHandler_=this.firstChangeHandler_.bind(this),this.enableDefaultResolution_=this.enableDefaultResolution_.bind(this),this.on(this.qualityLevels_,"addqualitylevel",this.update),this.on(this.qualityLevels_,"removequalitylevel",this.update),this.on(this.qualityLevels_,"change",this.handleQualityChange_),this.one(this.qualityLevels_,"change",this.firstChangeHandler_),e.on("adstart",this.hide),e.on(["adend","adtimeout"],this.update),this.update(),this.on("dispose",()=>{this.off(this.qualityLevels_,"addqualitylevel",this.update),this.off(this.qualityLevels_,"removequalitylevel",this.update),this.off(this.qualityLevels_,"change",this.handleQualityChange_),this.off(this.qualityLevels_,"change",this.firstChangeHandler_),e.off("adstart",this.hide),e.off(["adend","adtimeout"],this.update),e.off("loadedmetadata",this.enableDefaultResolution_)})}buildWrapperCSSClass(){return`vjs-quality-menu-wrapper ${super.buildWrapperCSSClass()}`}buildCSSClass(){return`vjs-quality-menu-button ${super.buildCSSClass()}`}createItems(){const e=[];if(!(this.qualityLevels_&&this.qualityLevels_.length))return e;let t;if(this.options_.useResolutionLabels&&v(this.qualityLevels_)?(t=this.groupByResolution_(),this.addClass("vjs-quality-menu-button-use-resolution")):(t=this.groupByBitrate_(),this.removeClass("vjs-quality-menu-button-use-resolution")),t.length<=1)return[];t.forEach(l=>{l.levels.length&&(l.selectable=!0,e.push(new c(this.player(),l)))});const s=new c(this.player(),{levels:Array.prototype.map.call(this.qualityLevels_,(l,n)=>n),label:"Auto",controlText:"Auto",active:!0,selected:!0,selectable:!0});return this.autoMenuItem_=s,e.push(s),e}groupByResolution_(){const e={},t=[];for(let l=0,n=this.qualityLevels_.length;ln.lines-l.lines);const s=[];return t.forEach(l=>{s.push(e[l.label])}),s}groupByBitrate_(){const e=[{levels:[],label:"HD",controlText:"High Definition"},{levels:[],label:"SD",controlText:"Standard Definition"}];for(let t=0,s=this.qualityLevels_.length;t=this.options_.sdBitrateLimit&&(s="HD")),s==="HD"?(this.addClass("vjs-quality-menu-button-HD-flag"),this.removeClass("vjs-quality-menu-button-4K-flag")):s==="4K"?(this.removeClass("vjs-quality-menu-button-HD-flag"),this.addClass("vjs-quality-menu-button-4K-flag")):(this.removeClass("vjs-quality-menu-button-HD-flag"),this.removeClass("vjs-quality-menu-button-4K-flag")),this.autoMenuItem_&&(this.autoMenuItem_.manuallySelected_&&e?this.autoMenuItem_.subLabel_.innerHTML=this.localize(s):this.autoMenuItem_.subLabel_.innerHTML="")}enableDefaultResolution_(){const e=this.options_.defaultResolution;for(let t=0;t{i.addClass("vjs-quality-menu");const t=i.getChild("controlBar"),s=t.addChild("QualityMenuButton",e,t.children_.length-2);return function(){i.removeClass("vjs-quality-menu"),t.removeChild(s),s.dispose()}},B=function(i,e){if(typeof i.qualityLevels<"u"){i.qualityLevels();let t=()=>{};i.ready(()=>{t=y(i,e),i.on("loadstart",()=>{t(),t=y(i,e)})}),i.qualityMenu=()=>{},i.qualityMenu.VERSION=_}},g=function(i){B(this,u.obj.merge(C,i))};u.registerPlugin("qualityMenu",g);g.VERSION=_;const x=b("video-element-id",{plugins:{qualityMenu:!0}});x.src({src:"urn:srf:video:593535b2-87c0-433a-8d2c-baf819233df1",type:"srgssr/urn"});document.querySelector("#close-btn").addEventListener("click",()=>{window.close()});window.pillarbox=b; -//# sourceMappingURL=quality-menu-B8MP43Ca.js.map diff --git a/pr-preview/pr-45/assets/quality-menu-DGFFFm6m.js b/pr-preview/pr-45/assets/quality-menu-DGFFFm6m.js new file mode 100644 index 0000000..1ee53a8 --- /dev/null +++ b/pr-preview/pr-45/assets/quality-menu-DGFFFm6m.js @@ -0,0 +1,2 @@ +import{v as u,p as b}from"./core-demo-header-component-BNyRgtzK.js";/*! @name videojs-contrib-quality-menu @version 1.0.3 @license Apache-2.0 */const m=u.getComponent("MenuItem"),p=u.dom||u;class c extends m{constructor(e,t={}){const s=t.selected;t.selected=t.active,super(e,t);const l=e.qualityLevels();this.levels_=t.levels,this.selected_=s,this.handleQualityChange=this.handleQualityChange.bind(this),this.controlText(t.controlText),this.on(l,"change",this.handleQualityChange),this.on("dispose",()=>{this.off(l,"change",this.handleQualityChange)})}createEl(e,t,s){const l=super.createEl(e,t,s),n=p.createEl("span",{className:"vjs-quality-menu-item-sub-label",innerHTML:this.localize(this.options_.subLabel||"")});return this.subLabel_=n,l&&l.appendChild(n),l}handleClick(){this.updateSiblings_();const e=this.player().qualityLevels(),t=e.selectedIndex;for(let s=0,l=e.length;s-1;this.selected(t)}selected(e){if(this.selectable)if(this.selected_){this.addClass("vjs-selected"),this.el_.setAttribute("aria-checked","true"),this.controlText(this.localize("{1}, selected",this.localize(this.options_.controlText)));const s=this.player().controlBar.getChild("QualityMenuButton");e?s.removeClass("vjs-quality-menu-button-waiting"):s.addClass("vjs-quality-menu-button-waiting")}else this.removeClass("vjs-selected"),this.el_.setAttribute("aria-checked","false"),this.controlText(this.options_.controlText)}updateSiblings_(){const e=this.player().qualityLevels(),s=this.player().controlBar.getChild("QualityMenuButton").items;for(let l=0,n=s.length;l-1;a.selected_=a===this,a.selected(r)}}}const q=u.getComponent("MenuButton"),v=function(i){return Array.from(i).some(e=>e.height)},f=function(i){return i>=2160?"4K":i>=720?"HD":""};class L extends q{constructor(e,t={}){super(e,t),this.el_.setAttribute("aria-label",this.localize("Quality Levels")),this.controlText("Quality Levels"),e.options().experimentalSvgIcons||this.$(".vjs-icon-placeholder").classList.add("vjs-icon-cog"),this.setIcon("cog"),this.qualityLevels_=e.qualityLevels(),this.update=this.update.bind(this),this.hide=this.hide.bind(this),this.handleQualityChange_=this.handleQualityChange_.bind(this),this.firstChangeHandler_=this.firstChangeHandler_.bind(this),this.enableDefaultResolution_=this.enableDefaultResolution_.bind(this),this.on(this.qualityLevels_,"addqualitylevel",this.update),this.on(this.qualityLevels_,"removequalitylevel",this.update),this.on(this.qualityLevels_,"change",this.handleQualityChange_),this.one(this.qualityLevels_,"change",this.firstChangeHandler_),e.on("adstart",this.hide),e.on(["adend","adtimeout"],this.update),this.update(),this.on("dispose",()=>{this.off(this.qualityLevels_,"addqualitylevel",this.update),this.off(this.qualityLevels_,"removequalitylevel",this.update),this.off(this.qualityLevels_,"change",this.handleQualityChange_),this.off(this.qualityLevels_,"change",this.firstChangeHandler_),e.off("adstart",this.hide),e.off(["adend","adtimeout"],this.update),e.off("loadedmetadata",this.enableDefaultResolution_)})}buildWrapperCSSClass(){return`vjs-quality-menu-wrapper ${super.buildWrapperCSSClass()}`}buildCSSClass(){return`vjs-quality-menu-button ${super.buildCSSClass()}`}createItems(){const e=[];if(!(this.qualityLevels_&&this.qualityLevels_.length))return e;let t;if(this.options_.useResolutionLabels&&v(this.qualityLevels_)?(t=this.groupByResolution_(),this.addClass("vjs-quality-menu-button-use-resolution")):(t=this.groupByBitrate_(),this.removeClass("vjs-quality-menu-button-use-resolution")),t.length<=1)return[];t.forEach(l=>{l.levels.length&&(l.selectable=!0,e.push(new c(this.player(),l)))});const s=new c(this.player(),{levels:Array.prototype.map.call(this.qualityLevels_,(l,n)=>n),label:"Auto",controlText:"Auto",active:!0,selected:!0,selectable:!0});return this.autoMenuItem_=s,e.push(s),e}groupByResolution_(){const e={},t=[];for(let l=0,n=this.qualityLevels_.length;ln.lines-l.lines);const s=[];return t.forEach(l=>{s.push(e[l.label])}),s}groupByBitrate_(){const e=[{levels:[],label:"HD",controlText:"High Definition"},{levels:[],label:"SD",controlText:"Standard Definition"}];for(let t=0,s=this.qualityLevels_.length;t=this.options_.sdBitrateLimit&&(s="HD")),s==="HD"?(this.addClass("vjs-quality-menu-button-HD-flag"),this.removeClass("vjs-quality-menu-button-4K-flag")):s==="4K"?(this.removeClass("vjs-quality-menu-button-HD-flag"),this.addClass("vjs-quality-menu-button-4K-flag")):(this.removeClass("vjs-quality-menu-button-HD-flag"),this.removeClass("vjs-quality-menu-button-4K-flag")),this.autoMenuItem_&&(this.autoMenuItem_.manuallySelected_&&e?this.autoMenuItem_.subLabel_.innerHTML=this.localize(s):this.autoMenuItem_.subLabel_.innerHTML="")}enableDefaultResolution_(){const e=this.options_.defaultResolution;for(let t=0;t{i.addClass("vjs-quality-menu");const t=i.getChild("controlBar"),s=t.addChild("QualityMenuButton",e,t.children_.length-2);return function(){i.removeClass("vjs-quality-menu"),t.removeChild(s),s.dispose()}},B=function(i,e){if(typeof i.qualityLevels<"u"){i.qualityLevels();let t=()=>{};i.ready(()=>{t=y(i,e),i.on("loadstart",()=>{t(),t=y(i,e)})}),i.qualityMenu=()=>{},i.qualityMenu.VERSION=_}},g=function(i){B(this,u.obj.merge(C,i))};u.registerPlugin("qualityMenu",g);g.VERSION=_;const x=b("video-element-id",{plugins:{qualityMenu:!0}});x.src({src:"urn:srf:video:593535b2-87c0-433a-8d2c-baf819233df1",type:"srgssr/urn"});document.querySelector("#close-btn").addEventListener("click",()=>{window.close()});window.pillarbox=b; +//# sourceMappingURL=quality-menu-DGFFFm6m.js.map diff --git a/pr-preview/pr-45/assets/quality-menu-B8MP43Ca.js.map b/pr-preview/pr-45/assets/quality-menu-DGFFFm6m.js.map similarity index 99% rename from pr-preview/pr-45/assets/quality-menu-B8MP43Ca.js.map rename to pr-preview/pr-45/assets/quality-menu-DGFFFm6m.js.map index 1bf403c..49a2452 100644 --- a/pr-preview/pr-45/assets/quality-menu-B8MP43Ca.js.map +++ b/pr-preview/pr-45/assets/quality-menu-DGFFFm6m.js.map @@ -1 +1 @@ -{"version":3,"file":"quality-menu-B8MP43Ca.js","sources":["../../node_modules/videojs-contrib-quality-menu/dist/videojs-contrib-quality-menu.es.js","../../static/showcases/quality-menu.html?html-proxy&index=0.js","../../static/showcases/quality-menu.html?html-proxy&index=1.js"],"sourcesContent":["/*! @name videojs-contrib-quality-menu @version 1.0.3 @license Apache-2.0 */\nimport videojs from 'video.js';\n\n/**\n * @file quality-menu-item.js\n */\nconst MenuItem = videojs.getComponent('MenuItem');\nconst dom = videojs.dom || videojs;\n\n/**\n * The quality level menu quality\n *\n * @extends MenuItem\n * @class QualityMenuItem\n */\nclass QualityMenuItem extends MenuItem {\n /**\n * Creates a QualityMenuItem\n *\n * @param {Player|Object} player\n * Main Player\n * @param {Object} [options]\n * Options for menu item\n * @param {number[]} options.levels\n * Array of indices mapping to QualityLevels in the QualityLevelList for\n * this menu item\n * @param {string} options.label\n * Label for this menu item\n * @param {string} options.controlText\n * control text for this menu item\n * @param {string} options.subLabel\n * sub label text for this menu item\n * @param {boolean} options.active\n * True if the QualityLevelList.selectedIndex is contained in the levels list\n * for this menu\n * @param {boolean} options.selected\n * True if this menu item is the selected item in the UI\n * @param {boolean} options.selectable\n * True if this menu item should be selectable in the UI\n */\n constructor(player, options = {}) {\n const selectedOption = options.selected;\n\n // We need to change options.seleted to options.active because the call to super\n // causes us to run MenuItem's constructor which calls this.selected(options.selected)\n // However, for QualityMenuItem, we change the meaning of the parameter to\n // this.selected() to be what we mean for 'active' which is True if the\n // QualityLevelList.selectedIndex is contained in the levels list for this menu\n options.selected = options.active;\n super(player, options);\n const qualityLevels = player.qualityLevels();\n this.levels_ = options.levels;\n this.selected_ = selectedOption;\n this.handleQualityChange = this.handleQualityChange.bind(this);\n this.controlText(options.controlText);\n this.on(qualityLevels, 'change', this.handleQualityChange);\n this.on('dispose', () => {\n this.off(qualityLevels, 'change', this.handleQualityChange);\n });\n }\n\n /**\n * Create the component's DOM element\n *\n * @param {string} [type]\n * Element type\n * @param {Object} [props]\n * Element properties\n * @param {Object} [attrs]\n * An object of attributes that should be set on the element\n * @return {Element}\n * The DOM element\n * @method createEl\n */\n createEl(type, props, attrs) {\n const el = super.createEl(type, props, attrs);\n const subLabel = dom.createEl('span', {\n className: 'vjs-quality-menu-item-sub-label',\n innerHTML: this.localize(this.options_.subLabel || '')\n });\n this.subLabel_ = subLabel;\n if (el) {\n el.appendChild(subLabel);\n }\n return el;\n }\n\n /**\n * Handle a click on the menu item, and set it to selected\n *\n * @method handleClick\n */\n handleClick() {\n this.updateSiblings_();\n const qualityLevels = this.player().qualityLevels();\n const currentlySelected = qualityLevels.selectedIndex;\n for (let i = 0, l = qualityLevels.length; i < l; i++) {\n // do not disable the currently selected quality until the end to prevent\n // playlist selection from selecting something new until we've enabled/disabled\n // all the quality levels\n if (i !== currentlySelected) {\n qualityLevels[i].enabled = false;\n }\n }\n for (let i = 0, l = this.levels_.length; i < l; i++) {\n qualityLevels[this.levels_[i]].enabled = true;\n }\n\n // Disable the quality level that was selected before the click if it is not\n // associated with this menu item\n if (currentlySelected !== -1 && this.levels_.indexOf(currentlySelected) === -1) {\n qualityLevels[currentlySelected].enabled = false;\n }\n }\n\n /**\n * Handle a change event from the QualityLevelList\n *\n * @method handleQualityChange\n */\n handleQualityChange() {\n const qualityLevels = this.player().qualityLevels();\n const active = this.levels_.indexOf(qualityLevels.selectedIndex) > -1;\n this.selected(active);\n }\n\n /**\n * Set this menu item as selected or not\n *\n * @param {boolean} active\n * True if the active quality level is controlled by this item\n * @method selected\n */\n selected(active) {\n if (!this.selectable) {\n return;\n }\n if (this.selected_) {\n this.addClass('vjs-selected');\n this.el_.setAttribute('aria-checked', 'true');\n // aria-checked isn't fully supported by browsers/screen readers,\n // so indicate selected state to screen reader in the control text.\n this.controlText(this.localize('{1}, selected', this.localize(this.options_.controlText)));\n const controlBar = this.player().controlBar;\n const menuButton = controlBar.getChild('QualityMenuButton');\n if (!active) {\n // This menu item is manually selected but the current playing quality level\n // is NOT associated with this menu item. This can happen if the quality hasnt\n // changed yet or something went wrong with rendition selection such as failed\n // server responses for playlists\n menuButton.addClass('vjs-quality-menu-button-waiting');\n } else {\n menuButton.removeClass('vjs-quality-menu-button-waiting');\n }\n } else {\n this.removeClass('vjs-selected');\n this.el_.setAttribute('aria-checked', 'false');\n // Indicate un-selected state to screen reader\n // Note that a space clears out the selected state text\n this.controlText(this.options_.controlText);\n }\n }\n\n /**\n * Sets this QualityMenuItem to be selected and deselects the other items\n *\n * @method updateSiblings_\n */\n updateSiblings_() {\n const qualityLevels = this.player().qualityLevels();\n const controlBar = this.player().controlBar;\n const menuItems = controlBar.getChild('QualityMenuButton').items;\n for (let i = 0, l = menuItems.length; i < l; i++) {\n const item = menuItems[i];\n const active = item.levels_.indexOf(qualityLevels.selectedIndex) > -1;\n item.selected_ = item === this;\n item.selected(active);\n }\n }\n}\n\n/**\n * @file quality-menu-button.js\n */\nconst MenuButton = videojs.getComponent('MenuButton');\n\n/**\n * Checks whether any of the QualityLevels in a QualityLevelList have resolution information\n *\n * @param {QualityLevelList} qualityLevelList\n * The list of QualityLevels\n * @return {boolean}\n * True if any levels have resolution information, false if none have\n * @function hasResolutionInfo\n */\nconst hasResolutionInfo = function (qualityLevelList) {\n return Array.from(qualityLevelList).some(level => level.height);\n};\n\n/**\n * Determines the appropriate sub label for the given lines of resolution\n *\n * @param {number} lines\n * The horizontal lines of resolution\n * @return {string}\n * sub label for given resolution\n * @function getSubLabel\n */\nconst getSubLabel = function (lines) {\n if (lines >= 2160) {\n return '4K';\n }\n if (lines >= 720) {\n return 'HD';\n }\n return '';\n};\n\n/**\n * The component for controlling the quality menu\n *\n * @extends MenuButton\n * @class QualityMenuButton\n */\nclass QualityMenuButton extends MenuButton {\n /**\n * Creates a QualityMenuButton\n *\n * @param {Player|Object} player\n * Main Player\n * @param {Object} [options]\n * Options for QualityMenuButton\n */\n constructor(player, options = {}) {\n super(player, options);\n this.el_.setAttribute('aria-label', this.localize('Quality Levels'));\n this.controlText('Quality Levels');\n if (!player.options().experimentalSvgIcons) {\n this.$('.vjs-icon-placeholder').classList.add('vjs-icon-cog');\n }\n this.setIcon('cog');\n this.qualityLevels_ = player.qualityLevels();\n this.update = this.update.bind(this);\n this.hide = this.hide.bind(this);\n this.handleQualityChange_ = this.handleQualityChange_.bind(this);\n this.firstChangeHandler_ = this.firstChangeHandler_.bind(this);\n this.enableDefaultResolution_ = this.enableDefaultResolution_.bind(this);\n this.on(this.qualityLevels_, 'addqualitylevel', this.update);\n this.on(this.qualityLevels_, 'removequalitylevel', this.update);\n this.on(this.qualityLevels_, 'change', this.handleQualityChange_);\n\n // TODO: Remove this and the `defaultResolution` option once videojs/http-streaming supports comparable functionality\n this.one(this.qualityLevels_, 'change', this.firstChangeHandler_);\n player.on('adstart', this.hide);\n player.on(['adend', 'adtimeout'], this.update);\n this.update();\n this.on('dispose', () => {\n this.off(this.qualityLevels_, 'addqualitylevel', this.update);\n this.off(this.qualityLevels_, 'removequalitylevel', this.update);\n this.off(this.qualityLevels_, 'change', this.handleQualityChange_);\n this.off(this.qualityLevels_, 'change', this.firstChangeHandler_);\n player.off('adstart', this.hide);\n player.off(['adend', 'adtimeout'], this.update);\n player.off('loadedmetadata', this.enableDefaultResolution_);\n });\n }\n\n /**\n * Allow sub components to stack CSS class names\n *\n * @return {string}\n * The constructed class name\n * @method buildWrapperCSSClass\n */\n buildWrapperCSSClass() {\n return `vjs-quality-menu-wrapper ${super.buildWrapperCSSClass()}`;\n }\n\n /**\n * Allow sub components to stack CSS class names\n *\n * @return {string}\n * The constructed class name\n * @method buildCSSClass\n */\n buildCSSClass() {\n return `vjs-quality-menu-button ${super.buildCSSClass()}`;\n }\n\n /**\n * Create the list of menu items.\n *\n * @return {Array}\n * The list of menu items\n * @method createItems\n */\n createItems() {\n const items = [];\n if (!(this.qualityLevels_ && this.qualityLevels_.length)) {\n return items;\n }\n let groups;\n if (this.options_.useResolutionLabels && hasResolutionInfo(this.qualityLevels_)) {\n groups = this.groupByResolution_();\n this.addClass('vjs-quality-menu-button-use-resolution');\n } else {\n groups = this.groupByBitrate_();\n this.removeClass('vjs-quality-menu-button-use-resolution');\n }\n\n // if there is only 1 or 0 menu items, we should just return an empty list so\n // the ui does not appear when there are no options. We consider 1 to be no options\n // since Auto will have the same behavior as selecting the only other option,\n // so it is as effective as not having any options.\n if (groups.length <= 1) {\n return [];\n }\n groups.forEach(group => {\n if (group.levels.length) {\n group.selectable = true;\n items.push(new QualityMenuItem(this.player(), group));\n }\n });\n\n // Add the Auto menu item\n const auto = new QualityMenuItem(this.player(), {\n levels: Array.prototype.map.call(this.qualityLevels_, (level, i) => i),\n label: 'Auto',\n controlText: 'Auto',\n active: true,\n selected: true,\n selectable: true\n });\n this.autoMenuItem_ = auto;\n items.push(auto);\n return items;\n }\n\n /**\n * Group quality levels by lines of resolution\n *\n * @return {Array}\n * Array of each group\n * @method groupByResolution_\n */\n groupByResolution_() {\n const groups = {};\n const order = [];\n for (let i = 0, l = this.qualityLevels_.length; i < l; i++) {\n const level = this.qualityLevels_[i];\n const active = this.qualityLevels_.selectedIndex === i;\n const lines = level.height;\n\n // Do not include an audio-only level\n if (!lines) {\n continue;\n }\n let label;\n if (this.options_.resolutionLabelBitrates) {\n const kbRate = Math.round(level.bitrate / 1000);\n label = `${lines}p @ ${kbRate} kbps`;\n } else {\n label = lines + 'p';\n }\n if (!groups[label]) {\n const subLabel = getSubLabel(lines);\n groups[label] = {\n levels: [],\n label,\n controlText: label,\n subLabel\n };\n order.push({\n label,\n lines\n });\n }\n if (active) {\n groups[label].active = true;\n }\n groups[label].levels.push(i);\n }\n\n // Sort from High to Low\n order.sort((a, b) => b.lines - a.lines);\n const sortedGroups = [];\n order.forEach(group => {\n sortedGroups.push(groups[group.label]);\n });\n return sortedGroups;\n }\n\n /**\n * Group quality levels by bitrate into SD and HD buckets\n *\n * @return {Array}\n * Array of each group\n * @method groupByBitrate_\n */\n groupByBitrate_() {\n // groups[0] for HD, groups[1] for SD, since we want sorting from high to low\\\n const groups = [{\n levels: [],\n label: 'HD',\n controlText: 'High Definition'\n }, {\n levels: [],\n label: 'SD',\n controlText: 'Standard Definition'\n }];\n for (let i = 0, l = this.qualityLevels_.length; i < l; i++) {\n const level = this.qualityLevels_[i];\n const active = this.qualityLevels_.selectedIndex === i;\n let group;\n if (level.bitrate < this.options_.sdBitrateLimit) {\n group = groups[1];\n } else {\n group = groups[0];\n }\n if (active) {\n group.active = true;\n }\n group.levels.push(i);\n }\n if (!groups[0].levels.length || !groups[1].levels.length) {\n // Either HD or SD do not have any quality levels, we should just return an empty\n // list so the ui does not appear when there are no options. We consider 1\n // to be no options since Auto will have the same behavior as selecting the only\n // other option, so it is as effective as not having any options.\n return [];\n }\n return groups;\n }\n\n /**\n * Handle a change event from the QualityLevelList\n *\n * @method handleQualityChange_\n */\n handleQualityChange_() {\n const selected = this.qualityLevels_[this.qualityLevels_.selectedIndex];\n const useResolution = this.options_.useResolutionLabels && hasResolutionInfo(this.qualityLevels_);\n let subLabel = '';\n if (selected) {\n if (useResolution) {\n subLabel = getSubLabel(selected.height);\n } else if (selected.bitrate >= this.options_.sdBitrateLimit) {\n subLabel = 'HD';\n }\n }\n if (subLabel === 'HD') {\n this.addClass('vjs-quality-menu-button-HD-flag');\n this.removeClass('vjs-quality-menu-button-4K-flag');\n } else if (subLabel === '4K') {\n this.removeClass('vjs-quality-menu-button-HD-flag');\n this.addClass('vjs-quality-menu-button-4K-flag');\n } else {\n this.removeClass('vjs-quality-menu-button-HD-flag');\n this.removeClass('vjs-quality-menu-button-4K-flag');\n }\n if (this.autoMenuItem_) {\n if (this.autoMenuItem_.manuallySelected_ && selected) {\n // auto mode, update the sub label\n this.autoMenuItem_.subLabel_.innerHTML = this.localize(subLabel);\n } else {\n this.autoMenuItem_.subLabel_.innerHTML = '';\n }\n }\n }\n\n /**\n * Enable the `defaultResolution`, if specified\n *\n * @method enableDefaultResolution_\n */\n enableDefaultResolution_() {\n const defaultResolution = this.options_.defaultResolution;\n for (let i = 0; i < this.items.length; i++) {\n if (this.items[i].options_.label.indexOf(defaultResolution) !== -1) {\n this.items[i].handleClick();\n }\n }\n }\n\n /**\n * Handle the first change event in order to enable the `defaultResolution`, if specified\n *\n * @method firstChangeHandler_\n */\n firstChangeHandler_() {\n // If we haven't loaded metadata yet and we expect it before playback is initiated, wait to perform the quality switch.\n // Doing so before 'loadedmetadata' can result in cancelling requests for init segments required for the browser to fire 'loadedmetadata'.\n if (this.player_.readyState() < 1 && this.player_.preload() !== 'none') {\n this.player_.one('loadedmetadata', this.enableDefaultResolution_);\n return;\n }\n this.enableDefaultResolution_();\n }\n}\nvideojs.registerComponent('QualityMenuButton', QualityMenuButton);\n\nvar version = \"1.0.3\";\n\n// Default options for the plugin.\nconst defaults = {\n sdBitrateLimit: 2000000,\n useResolutionLabels: true,\n resolutionLabelBitrates: false,\n defaultResolution: 'none'\n};\n\n/**\n * Function to invoke when the player is ready.\n *\n * This is a great place for your plugin to initialize itself. When this\n * function is called, the player will have its DOM and child components\n * in place.\n *\n * @function onPlayerReady\n * @param {Player} player\n * A Video.js player.\n * @param {Object} [options={}]\n * An object of options left to the plugin author to define.\n * @return {Function} disposal function for re initialization\n */\nconst onPlayerReady = (player, options) => {\n player.addClass('vjs-quality-menu');\n const controlBar = player.getChild('controlBar');\n const button = controlBar.addChild('QualityMenuButton', options, controlBar.children_.length - 2);\n return function () {\n player.removeClass('vjs-quality-menu');\n controlBar.removeChild(button);\n button.dispose();\n };\n};\n\n/**\n * Main entry point for the plugin\n *\n * @function initPlugin\n * @param {Player} player a reference to a videojs Player instance\n * @param {Object} [options] an object with plugin options\n */\nconst initPlugin = function (player, options) {\n if (typeof player.qualityLevels !== 'undefined') {\n // call qualityLevels to initialize it in case it hasnt been initialized yet\n player.qualityLevels();\n let disposeFn = () => {};\n player.ready(() => {\n disposeFn = onPlayerReady(player, options);\n player.on('loadstart', () => {\n disposeFn();\n disposeFn = onPlayerReady(player, options);\n });\n });\n\n // reinitialization is no-op for now\n player.qualityMenu = () => {};\n player.qualityMenu.VERSION = version;\n }\n};\n\n/**\n * A video.js plugin.\n *\n * In the plugin function, the value of `this` is a video.js `Player`\n * instance. You cannot rely on the player being in a \"ready\" state here,\n * depending on how the plugin is invoked. This may or may not be important\n * to you; if not, remove the wait for \"ready\"!\n *\n * @function qualityMenu\n * @param {Object} [options={}]\n * An object of options left to the plugin author to define.\n */\nconst qualityMenu = function (options) {\n initPlugin(this, videojs.obj.merge(defaults, options));\n};\n\n// Register the plugin with video.js.\nvideojs.registerPlugin('qualityMenu', qualityMenu);\n\n// Include the version number.\nqualityMenu.VERSION = version;\n\nexport { qualityMenu as default };\n","\n import pillarbox from '@srgssr/pillarbox-web';\n // Import the quality menu plugin\n import 'videojs-contrib-quality-menu';\n\n // Create a pillarbox player instance with the quality menu plugin\n const player = pillarbox('video-element-id', { plugins: { qualityMenu: true } });\n\n // Load the video source\n player.src({ src: 'urn:srf:video:593535b2-87c0-433a-8d2c-baf819233df1', type: 'srgssr/urn' });\n","\n import pillarbox from '@srgssr/pillarbox-web';\n import '../../src/layout/header/core-demo-header-component.js';\n\n document.querySelector('#close-btn').addEventListener('click', () => {\n window.close();\n });\n\n window.pillarbox = pillarbox;\n"],"names":["MenuItem","videojs","dom","QualityMenuItem","player","options","selectedOption","qualityLevels","type","props","attrs","el","subLabel","currentlySelected","i","active","menuButton","menuItems","l","item","MenuButton","hasResolutionInfo","qualityLevelList","level","getSubLabel","lines","QualityMenuButton","items","groups","group","auto","order","label","kbRate","a","b","sortedGroups","selected","useResolution","defaultResolution","version","defaults","onPlayerReady","controlBar","button","initPlugin","disposeFn","qualityMenu","pillarbox"],"mappings":"0GAAA,4EAMA,MAAMA,EAAWC,EAAQ,aAAa,UAAU,EAC1CC,EAAMD,EAAQ,KAAOA,EAQ3B,MAAME,UAAwBH,CAAS,CAyBrC,YAAYI,EAAQC,EAAU,GAAI,CAChC,MAAMC,EAAiBD,EAAQ,SAO/BA,EAAQ,SAAWA,EAAQ,OAC3B,MAAMD,EAAQC,CAAO,EACrB,MAAME,EAAgBH,EAAO,cAAe,EAC5C,KAAK,QAAUC,EAAQ,OACvB,KAAK,UAAYC,EACjB,KAAK,oBAAsB,KAAK,oBAAoB,KAAK,IAAI,EAC7D,KAAK,YAAYD,EAAQ,WAAW,EACpC,KAAK,GAAGE,EAAe,SAAU,KAAK,mBAAmB,EACzD,KAAK,GAAG,UAAW,IAAM,CACvB,KAAK,IAAIA,EAAe,SAAU,KAAK,mBAAmB,CAChE,CAAK,CACL,CAeE,SAASC,EAAMC,EAAOC,EAAO,CAC3B,MAAMC,EAAK,MAAM,SAASH,EAAMC,EAAOC,CAAK,EACtCE,EAAWV,EAAI,SAAS,OAAQ,CACpC,UAAW,kCACX,UAAW,KAAK,SAAS,KAAK,SAAS,UAAY,EAAE,CAC3D,CAAK,EACD,YAAK,UAAYU,EACbD,GACFA,EAAG,YAAYC,CAAQ,EAElBD,CACX,CAOE,aAAc,CACZ,KAAK,gBAAiB,EACtB,MAAMJ,EAAgB,KAAK,OAAM,EAAG,cAAe,EAC7CM,EAAoBN,EAAc,cACxC,QAASO,EAAI,EAAG,EAAIP,EAAc,OAAQO,EAAI,EAAGA,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CwC,EAASD,EAAW,SAAS,oBAAqBtC,EAASsC,EAAW,UAAU,OAAS,CAAC,EAChG,OAAO,UAAY,CACjBvC,EAAO,YAAY,kBAAkB,EACrCuC,EAAW,YAAYC,CAAM,EAC7BA,EAAO,QAAS,CACjB,CACH,EASMC,EAAa,SAAUzC,EAAQC,EAAS,CAC5C,GAAI,OAAOD,EAAO,cAAkB,IAAa,CAE/CA,EAAO,cAAe,EACtB,IAAI0C,EAAY,IAAM,CAAE,EACxB1C,EAAO,MAAM,IAAM,CACjB0C,EAAYJ,EAActC,EAAQC,CAAO,EACzCD,EAAO,GAAG,YAAa,IAAM,CAC3B0C,EAAW,EACXA,EAAYJ,EAActC,EAAQC,CAAO,CACjD,CAAO,CACP,CAAK,EAGDD,EAAO,YAAc,IAAM,CAAE,EAC7BA,EAAO,YAAY,QAAUoC,CACjC,CACA,EAcMO,EAAc,SAAU1C,EAAS,CACrCwC,EAAW,KAAM5C,EAAQ,IAAI,MAAMwC,EAAUpC,CAAO,CAAC,CACvD,EAGAJ,EAAQ,eAAe,cAAe8C,CAAW,EAGjDA,EAAY,QAAUP,EChkBpB,MAAMpC,EAAS4C,EAAU,mBAAoB,CAAE,QAAS,CAAE,YAAa,EAAI,EAAI,EAG/E5C,EAAO,IAAI,CAAE,IAAK,qDAAsD,KAAM,aAAc,ECL5F,SAAS,cAAc,YAAY,EAAE,iBAAiB,QAAS,IAAM,CACnE,OAAO,MAAO,CAClB,CAAG,EAED,OAAO,UAAY4C","x_google_ignoreList":[0]} \ No newline at end of file +{"version":3,"file":"quality-menu-DGFFFm6m.js","sources":["../../node_modules/videojs-contrib-quality-menu/dist/videojs-contrib-quality-menu.es.js","../../static/showcases/quality-menu.html?html-proxy&index=0.js","../../static/showcases/quality-menu.html?html-proxy&index=1.js"],"sourcesContent":["/*! @name videojs-contrib-quality-menu @version 1.0.3 @license Apache-2.0 */\nimport videojs from 'video.js';\n\n/**\n * @file quality-menu-item.js\n */\nconst MenuItem = videojs.getComponent('MenuItem');\nconst dom = videojs.dom || videojs;\n\n/**\n * The quality level menu quality\n *\n * @extends MenuItem\n * @class QualityMenuItem\n */\nclass QualityMenuItem extends MenuItem {\n /**\n * Creates a QualityMenuItem\n *\n * @param {Player|Object} player\n * Main Player\n * @param {Object} [options]\n * Options for menu item\n * @param {number[]} options.levels\n * Array of indices mapping to QualityLevels in the QualityLevelList for\n * this menu item\n * @param {string} options.label\n * Label for this menu item\n * @param {string} options.controlText\n * control text for this menu item\n * @param {string} options.subLabel\n * sub label text for this menu item\n * @param {boolean} options.active\n * True if the QualityLevelList.selectedIndex is contained in the levels list\n * for this menu\n * @param {boolean} options.selected\n * True if this menu item is the selected item in the UI\n * @param {boolean} options.selectable\n * True if this menu item should be selectable in the UI\n */\n constructor(player, options = {}) {\n const selectedOption = options.selected;\n\n // We need to change options.seleted to options.active because the call to super\n // causes us to run MenuItem's constructor which calls this.selected(options.selected)\n // However, for QualityMenuItem, we change the meaning of the parameter to\n // this.selected() to be what we mean for 'active' which is True if the\n // QualityLevelList.selectedIndex is contained in the levels list for this menu\n options.selected = options.active;\n super(player, options);\n const qualityLevels = player.qualityLevels();\n this.levels_ = options.levels;\n this.selected_ = selectedOption;\n this.handleQualityChange = this.handleQualityChange.bind(this);\n this.controlText(options.controlText);\n this.on(qualityLevels, 'change', this.handleQualityChange);\n this.on('dispose', () => {\n this.off(qualityLevels, 'change', this.handleQualityChange);\n });\n }\n\n /**\n * Create the component's DOM element\n *\n * @param {string} [type]\n * Element type\n * @param {Object} [props]\n * Element properties\n * @param {Object} [attrs]\n * An object of attributes that should be set on the element\n * @return {Element}\n * The DOM element\n * @method createEl\n */\n createEl(type, props, attrs) {\n const el = super.createEl(type, props, attrs);\n const subLabel = dom.createEl('span', {\n className: 'vjs-quality-menu-item-sub-label',\n innerHTML: this.localize(this.options_.subLabel || '')\n });\n this.subLabel_ = subLabel;\n if (el) {\n el.appendChild(subLabel);\n }\n return el;\n }\n\n /**\n * Handle a click on the menu item, and set it to selected\n *\n * @method handleClick\n */\n handleClick() {\n this.updateSiblings_();\n const qualityLevels = this.player().qualityLevels();\n const currentlySelected = qualityLevels.selectedIndex;\n for (let i = 0, l = qualityLevels.length; i < l; i++) {\n // do not disable the currently selected quality until the end to prevent\n // playlist selection from selecting something new until we've enabled/disabled\n // all the quality levels\n if (i !== currentlySelected) {\n qualityLevels[i].enabled = false;\n }\n }\n for (let i = 0, l = this.levels_.length; i < l; i++) {\n qualityLevels[this.levels_[i]].enabled = true;\n }\n\n // Disable the quality level that was selected before the click if it is not\n // associated with this menu item\n if (currentlySelected !== -1 && this.levels_.indexOf(currentlySelected) === -1) {\n qualityLevels[currentlySelected].enabled = false;\n }\n }\n\n /**\n * Handle a change event from the QualityLevelList\n *\n * @method handleQualityChange\n */\n handleQualityChange() {\n const qualityLevels = this.player().qualityLevels();\n const active = this.levels_.indexOf(qualityLevels.selectedIndex) > -1;\n this.selected(active);\n }\n\n /**\n * Set this menu item as selected or not\n *\n * @param {boolean} active\n * True if the active quality level is controlled by this item\n * @method selected\n */\n selected(active) {\n if (!this.selectable) {\n return;\n }\n if (this.selected_) {\n this.addClass('vjs-selected');\n this.el_.setAttribute('aria-checked', 'true');\n // aria-checked isn't fully supported by browsers/screen readers,\n // so indicate selected state to screen reader in the control text.\n this.controlText(this.localize('{1}, selected', this.localize(this.options_.controlText)));\n const controlBar = this.player().controlBar;\n const menuButton = controlBar.getChild('QualityMenuButton');\n if (!active) {\n // This menu item is manually selected but the current playing quality level\n // is NOT associated with this menu item. This can happen if the quality hasnt\n // changed yet or something went wrong with rendition selection such as failed\n // server responses for playlists\n menuButton.addClass('vjs-quality-menu-button-waiting');\n } else {\n menuButton.removeClass('vjs-quality-menu-button-waiting');\n }\n } else {\n this.removeClass('vjs-selected');\n this.el_.setAttribute('aria-checked', 'false');\n // Indicate un-selected state to screen reader\n // Note that a space clears out the selected state text\n this.controlText(this.options_.controlText);\n }\n }\n\n /**\n * Sets this QualityMenuItem to be selected and deselects the other items\n *\n * @method updateSiblings_\n */\n updateSiblings_() {\n const qualityLevels = this.player().qualityLevels();\n const controlBar = this.player().controlBar;\n const menuItems = controlBar.getChild('QualityMenuButton').items;\n for (let i = 0, l = menuItems.length; i < l; i++) {\n const item = menuItems[i];\n const active = item.levels_.indexOf(qualityLevels.selectedIndex) > -1;\n item.selected_ = item === this;\n item.selected(active);\n }\n }\n}\n\n/**\n * @file quality-menu-button.js\n */\nconst MenuButton = videojs.getComponent('MenuButton');\n\n/**\n * Checks whether any of the QualityLevels in a QualityLevelList have resolution information\n *\n * @param {QualityLevelList} qualityLevelList\n * The list of QualityLevels\n * @return {boolean}\n * True if any levels have resolution information, false if none have\n * @function hasResolutionInfo\n */\nconst hasResolutionInfo = function (qualityLevelList) {\n return Array.from(qualityLevelList).some(level => level.height);\n};\n\n/**\n * Determines the appropriate sub label for the given lines of resolution\n *\n * @param {number} lines\n * The horizontal lines of resolution\n * @return {string}\n * sub label for given resolution\n * @function getSubLabel\n */\nconst getSubLabel = function (lines) {\n if (lines >= 2160) {\n return '4K';\n }\n if (lines >= 720) {\n return 'HD';\n }\n return '';\n};\n\n/**\n * The component for controlling the quality menu\n *\n * @extends MenuButton\n * @class QualityMenuButton\n */\nclass QualityMenuButton extends MenuButton {\n /**\n * Creates a QualityMenuButton\n *\n * @param {Player|Object} player\n * Main Player\n * @param {Object} [options]\n * Options for QualityMenuButton\n */\n constructor(player, options = {}) {\n super(player, options);\n this.el_.setAttribute('aria-label', this.localize('Quality Levels'));\n this.controlText('Quality Levels');\n if (!player.options().experimentalSvgIcons) {\n this.$('.vjs-icon-placeholder').classList.add('vjs-icon-cog');\n }\n this.setIcon('cog');\n this.qualityLevels_ = player.qualityLevels();\n this.update = this.update.bind(this);\n this.hide = this.hide.bind(this);\n this.handleQualityChange_ = this.handleQualityChange_.bind(this);\n this.firstChangeHandler_ = this.firstChangeHandler_.bind(this);\n this.enableDefaultResolution_ = this.enableDefaultResolution_.bind(this);\n this.on(this.qualityLevels_, 'addqualitylevel', this.update);\n this.on(this.qualityLevels_, 'removequalitylevel', this.update);\n this.on(this.qualityLevels_, 'change', this.handleQualityChange_);\n\n // TODO: Remove this and the `defaultResolution` option once videojs/http-streaming supports comparable functionality\n this.one(this.qualityLevels_, 'change', this.firstChangeHandler_);\n player.on('adstart', this.hide);\n player.on(['adend', 'adtimeout'], this.update);\n this.update();\n this.on('dispose', () => {\n this.off(this.qualityLevels_, 'addqualitylevel', this.update);\n this.off(this.qualityLevels_, 'removequalitylevel', this.update);\n this.off(this.qualityLevels_, 'change', this.handleQualityChange_);\n this.off(this.qualityLevels_, 'change', this.firstChangeHandler_);\n player.off('adstart', this.hide);\n player.off(['adend', 'adtimeout'], this.update);\n player.off('loadedmetadata', this.enableDefaultResolution_);\n });\n }\n\n /**\n * Allow sub components to stack CSS class names\n *\n * @return {string}\n * The constructed class name\n * @method buildWrapperCSSClass\n */\n buildWrapperCSSClass() {\n return `vjs-quality-menu-wrapper ${super.buildWrapperCSSClass()}`;\n }\n\n /**\n * Allow sub components to stack CSS class names\n *\n * @return {string}\n * The constructed class name\n * @method buildCSSClass\n */\n buildCSSClass() {\n return `vjs-quality-menu-button ${super.buildCSSClass()}`;\n }\n\n /**\n * Create the list of menu items.\n *\n * @return {Array}\n * The list of menu items\n * @method createItems\n */\n createItems() {\n const items = [];\n if (!(this.qualityLevels_ && this.qualityLevels_.length)) {\n return items;\n }\n let groups;\n if (this.options_.useResolutionLabels && hasResolutionInfo(this.qualityLevels_)) {\n groups = this.groupByResolution_();\n this.addClass('vjs-quality-menu-button-use-resolution');\n } else {\n groups = this.groupByBitrate_();\n this.removeClass('vjs-quality-menu-button-use-resolution');\n }\n\n // if there is only 1 or 0 menu items, we should just return an empty list so\n // the ui does not appear when there are no options. We consider 1 to be no options\n // since Auto will have the same behavior as selecting the only other option,\n // so it is as effective as not having any options.\n if (groups.length <= 1) {\n return [];\n }\n groups.forEach(group => {\n if (group.levels.length) {\n group.selectable = true;\n items.push(new QualityMenuItem(this.player(), group));\n }\n });\n\n // Add the Auto menu item\n const auto = new QualityMenuItem(this.player(), {\n levels: Array.prototype.map.call(this.qualityLevels_, (level, i) => i),\n label: 'Auto',\n controlText: 'Auto',\n active: true,\n selected: true,\n selectable: true\n });\n this.autoMenuItem_ = auto;\n items.push(auto);\n return items;\n }\n\n /**\n * Group quality levels by lines of resolution\n *\n * @return {Array}\n * Array of each group\n * @method groupByResolution_\n */\n groupByResolution_() {\n const groups = {};\n const order = [];\n for (let i = 0, l = this.qualityLevels_.length; i < l; i++) {\n const level = this.qualityLevels_[i];\n const active = this.qualityLevels_.selectedIndex === i;\n const lines = level.height;\n\n // Do not include an audio-only level\n if (!lines) {\n continue;\n }\n let label;\n if (this.options_.resolutionLabelBitrates) {\n const kbRate = Math.round(level.bitrate / 1000);\n label = `${lines}p @ ${kbRate} kbps`;\n } else {\n label = lines + 'p';\n }\n if (!groups[label]) {\n const subLabel = getSubLabel(lines);\n groups[label] = {\n levels: [],\n label,\n controlText: label,\n subLabel\n };\n order.push({\n label,\n lines\n });\n }\n if (active) {\n groups[label].active = true;\n }\n groups[label].levels.push(i);\n }\n\n // Sort from High to Low\n order.sort((a, b) => b.lines - a.lines);\n const sortedGroups = [];\n order.forEach(group => {\n sortedGroups.push(groups[group.label]);\n });\n return sortedGroups;\n }\n\n /**\n * Group quality levels by bitrate into SD and HD buckets\n *\n * @return {Array}\n * Array of each group\n * @method groupByBitrate_\n */\n groupByBitrate_() {\n // groups[0] for HD, groups[1] for SD, since we want sorting from high to low\\\n const groups = [{\n levels: [],\n label: 'HD',\n controlText: 'High Definition'\n }, {\n levels: [],\n label: 'SD',\n controlText: 'Standard Definition'\n }];\n for (let i = 0, l = this.qualityLevels_.length; i < l; i++) {\n const level = this.qualityLevels_[i];\n const active = this.qualityLevels_.selectedIndex === i;\n let group;\n if (level.bitrate < this.options_.sdBitrateLimit) {\n group = groups[1];\n } else {\n group = groups[0];\n }\n if (active) {\n group.active = true;\n }\n group.levels.push(i);\n }\n if (!groups[0].levels.length || !groups[1].levels.length) {\n // Either HD or SD do not have any quality levels, we should just return an empty\n // list so the ui does not appear when there are no options. We consider 1\n // to be no options since Auto will have the same behavior as selecting the only\n // other option, so it is as effective as not having any options.\n return [];\n }\n return groups;\n }\n\n /**\n * Handle a change event from the QualityLevelList\n *\n * @method handleQualityChange_\n */\n handleQualityChange_() {\n const selected = this.qualityLevels_[this.qualityLevels_.selectedIndex];\n const useResolution = this.options_.useResolutionLabels && hasResolutionInfo(this.qualityLevels_);\n let subLabel = '';\n if (selected) {\n if (useResolution) {\n subLabel = getSubLabel(selected.height);\n } else if (selected.bitrate >= this.options_.sdBitrateLimit) {\n subLabel = 'HD';\n }\n }\n if (subLabel === 'HD') {\n this.addClass('vjs-quality-menu-button-HD-flag');\n this.removeClass('vjs-quality-menu-button-4K-flag');\n } else if (subLabel === '4K') {\n this.removeClass('vjs-quality-menu-button-HD-flag');\n this.addClass('vjs-quality-menu-button-4K-flag');\n } else {\n this.removeClass('vjs-quality-menu-button-HD-flag');\n this.removeClass('vjs-quality-menu-button-4K-flag');\n }\n if (this.autoMenuItem_) {\n if (this.autoMenuItem_.manuallySelected_ && selected) {\n // auto mode, update the sub label\n this.autoMenuItem_.subLabel_.innerHTML = this.localize(subLabel);\n } else {\n this.autoMenuItem_.subLabel_.innerHTML = '';\n }\n }\n }\n\n /**\n * Enable the `defaultResolution`, if specified\n *\n * @method enableDefaultResolution_\n */\n enableDefaultResolution_() {\n const defaultResolution = this.options_.defaultResolution;\n for (let i = 0; i < this.items.length; i++) {\n if (this.items[i].options_.label.indexOf(defaultResolution) !== -1) {\n this.items[i].handleClick();\n }\n }\n }\n\n /**\n * Handle the first change event in order to enable the `defaultResolution`, if specified\n *\n * @method firstChangeHandler_\n */\n firstChangeHandler_() {\n // If we haven't loaded metadata yet and we expect it before playback is initiated, wait to perform the quality switch.\n // Doing so before 'loadedmetadata' can result in cancelling requests for init segments required for the browser to fire 'loadedmetadata'.\n if (this.player_.readyState() < 1 && this.player_.preload() !== 'none') {\n this.player_.one('loadedmetadata', this.enableDefaultResolution_);\n return;\n }\n this.enableDefaultResolution_();\n }\n}\nvideojs.registerComponent('QualityMenuButton', QualityMenuButton);\n\nvar version = \"1.0.3\";\n\n// Default options for the plugin.\nconst defaults = {\n sdBitrateLimit: 2000000,\n useResolutionLabels: true,\n resolutionLabelBitrates: false,\n defaultResolution: 'none'\n};\n\n/**\n * Function to invoke when the player is ready.\n *\n * This is a great place for your plugin to initialize itself. When this\n * function is called, the player will have its DOM and child components\n * in place.\n *\n * @function onPlayerReady\n * @param {Player} player\n * A Video.js player.\n * @param {Object} [options={}]\n * An object of options left to the plugin author to define.\n * @return {Function} disposal function for re initialization\n */\nconst onPlayerReady = (player, options) => {\n player.addClass('vjs-quality-menu');\n const controlBar = player.getChild('controlBar');\n const button = controlBar.addChild('QualityMenuButton', options, controlBar.children_.length - 2);\n return function () {\n player.removeClass('vjs-quality-menu');\n controlBar.removeChild(button);\n button.dispose();\n };\n};\n\n/**\n * Main entry point for the plugin\n *\n * @function initPlugin\n * @param {Player} player a reference to a videojs Player instance\n * @param {Object} [options] an object with plugin options\n */\nconst initPlugin = function (player, options) {\n if (typeof player.qualityLevels !== 'undefined') {\n // call qualityLevels to initialize it in case it hasnt been initialized yet\n player.qualityLevels();\n let disposeFn = () => {};\n player.ready(() => {\n disposeFn = onPlayerReady(player, options);\n player.on('loadstart', () => {\n disposeFn();\n disposeFn = onPlayerReady(player, options);\n });\n });\n\n // reinitialization is no-op for now\n player.qualityMenu = () => {};\n player.qualityMenu.VERSION = version;\n }\n};\n\n/**\n * A video.js plugin.\n *\n * In the plugin function, the value of `this` is a video.js `Player`\n * instance. You cannot rely on the player being in a \"ready\" state here,\n * depending on how the plugin is invoked. This may or may not be important\n * to you; if not, remove the wait for \"ready\"!\n *\n * @function qualityMenu\n * @param {Object} [options={}]\n * An object of options left to the plugin author to define.\n */\nconst qualityMenu = function (options) {\n initPlugin(this, videojs.obj.merge(defaults, options));\n};\n\n// Register the plugin with video.js.\nvideojs.registerPlugin('qualityMenu', qualityMenu);\n\n// Include the version number.\nqualityMenu.VERSION = version;\n\nexport { qualityMenu as default };\n","\n import pillarbox from '@srgssr/pillarbox-web';\n // Import the quality menu plugin\n import 'videojs-contrib-quality-menu';\n\n // Create a pillarbox player instance with the quality menu plugin\n const player = pillarbox('video-element-id', { plugins: { qualityMenu: true } });\n\n // Load the video source\n player.src({ src: 'urn:srf:video:593535b2-87c0-433a-8d2c-baf819233df1', type: 'srgssr/urn' });\n","\n import pillarbox from '@srgssr/pillarbox-web';\n import '../../src/layout/header/core-demo-header-component.js';\n\n document.querySelector('#close-btn').addEventListener('click', () => {\n window.close();\n });\n\n window.pillarbox = pillarbox;\n"],"names":["MenuItem","videojs","dom","QualityMenuItem","player","options","selectedOption","qualityLevels","type","props","attrs","el","subLabel","currentlySelected","i","active","menuButton","menuItems","l","item","MenuButton","hasResolutionInfo","qualityLevelList","level","getSubLabel","lines","QualityMenuButton","items","groups","group","auto","order","label","kbRate","a","b","sortedGroups","selected","useResolution","defaultResolution","version","defaults","onPlayerReady","controlBar","button","initPlugin","disposeFn","qualityMenu","pillarbox"],"mappings":"oEAAA,4EAMA,MAAMA,EAAWC,EAAQ,aAAa,UAAU,EAC1CC,EAAMD,EAAQ,KAAOA,EAQ3B,MAAME,UAAwBH,CAAS,CAyBrC,YAAYI,EAAQC,EAAU,GAAI,CAChC,MAAMC,EAAiBD,EAAQ,SAO/BA,EAAQ,SAAWA,EAAQ,OAC3B,MAAMD,EAAQC,CAAO,EACrB,MAAME,EAAgBH,EAAO,cAAe,EAC5C,KAAK,QAAUC,EAAQ,OACvB,KAAK,UAAYC,EACjB,KAAK,oBAAsB,KAAK,oBAAoB,KAAK,IAAI,EAC7D,KAAK,YAAYD,EAAQ,WAAW,EACpC,KAAK,GAAGE,EAAe,SAAU,KAAK,mBAAmB,EACzD,KAAK,GAAG,UAAW,IAAM,CACvB,KAAK,IAAIA,EAAe,SAAU,KAAK,mBAAmB,CA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AsD,KAAM,aAAc,ECL5F,SAAS,cAAc,YAAY,EAAE,iBAAiB,QAAS,IAAM,CACnE,OAAO,MAAO,CAClB,CAAG,EAED,OAAO,UAAY4C","x_google_ignoreList":[0]} \ No newline at end of file diff --git a/pr-preview/pr-45/assets/quality-menu-PMLfcXBG.css b/pr-preview/pr-45/assets/quality-menu-PMLfcXBG.css new file mode 100644 index 0000000..a3d7ab4 --- /dev/null +++ b/pr-preview/pr-45/assets/quality-menu-PMLfcXBG.css @@ -0,0 +1 @@ +.video-js.vjs-quality-menu{display:block}.video-js.vjs-quality-menu .vjs-quality-menu-button{position:relative}.video-js.vjs-quality-menu .vjs-quality-menu-button li{text-transform:none}.video-js.vjs-quality-menu .vjs-quality-menu-button.vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:25em;width:10em;left:0}.video-js.vjs-quality-menu .vjs-menu-item .vjs-control-text{position:absolute}.video-js.vjs-quality-menu .vjs-quality-menu-wrapper{position:relative}.video-js.vjs-quality-menu .vjs-quality-menu-wrapper li{text-transform:none}.video-js.vjs-quality-menu .vjs-quality-menu-wrapper.vjs-menu-wrapper-popup .vjs-menu .vjs-menu-content{max-height:25em;width:10em;left:0}.video-js.vjs-quality-menu .vjs-quality-menu-item-sub-label{font-size:75%;font-weight:700;position:absolute;right:0;text-align:center;width:4em}.video-js.vjs-quality-menu .vjs-quality-menu-button-use-resolution .vjs-quality-menu-item-sub-label{position:absolute;right:0;text-align:center;width:4em}.video-js.vjs-quality-menu .vjs-quality-menu-button-4K-flag:after,.video-js.vjs-quality-menu .vjs-quality-menu-button-HD-flag:after{background-color:#2b333f;color:inherit;content:"";font-family:Helvetica Neue,Helvetica,Arial,sans-serif;font-size:.7em;font-weight:300;height:2.2em;line-height:2.2em;padding:0;position:absolute;right:0;text-align:center;top:.5em;width:2.2em;border-radius:2em;letter-spacing:.1em}.video-js.vjs-quality-menu .vjs-quality-menu-button-HD-flag:after{content:"HD"}.video-js.vjs-quality-menu .vjs-quality-menu-button-4K-flag:after{content:"4K"}.video-js.vjs-quality-menu .vjs-quality-menu-button-waiting:before{-webkit-animation:vjs-spinner-spin 1.1s cubic-bezier(.6,.2,0,.8) infinite;animation:vjs-spinner-spin 1.1s cubic-bezier(.6,.2,0,.8) infinite}:where(html){--font-system-ui:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif;--font-transitional:Charter,Bitstream Charter,Sitka Text,Cambria,serif;--font-old-style:Iowan Old Style,Palatino Linotype,URW Palladio L,P052,serif;--font-humanist:Seravek,Gill Sans Nova,Ubuntu,Calibri,DejaVu Sans,source-sans-pro,sans-serif;--font-geometric-humanist:Avenir,Montserrat,Corbel,URW Gothic,source-sans-pro,sans-serif;--font-classical-humanist:Optima,Candara,Noto Sans,source-sans-pro,sans-serif;--font-neo-grotesque:Inter,Roboto,Helvetica Neue,Arial Nova,Nimbus Sans,Arial,sans-serif;--font-monospace-slab-serif:Nimbus Mono PS,Courier New,monospace;--font-monospace-code:Dank Mono,Operator Mono,Inconsolata,Fira Mono,ui-monospace,SF Mono,Monaco,Droid Sans Mono,Source Code Pro,Cascadia Code,Menlo,Consolas,DejaVu Sans Mono,monospace;--font-industrial:Bahnschrift,DIN Alternate,Franklin Gothic Medium,Nimbus Sans Narrow,sans-serif-condensed,sans-serif;--font-rounded-sans:ui-rounded,Hiragino Maru Gothic ProN,Quicksand,Comfortaa,Manjari,Arial Rounded MT,Arial Rounded MT Bold,Calibri,source-sans-pro,sans-serif;--font-slab-serif:Rockwell,Rockwell Nova,Roboto Slab,DejaVu Serif,Sitka Small,serif;--font-antique:Superclarendon,Bookman Old Style,URW Bookman,URW Bookman L,Georgia Pro,Georgia,serif;--font-didone:Didot,Bodoni MT,Noto Serif Display,URW Palladio L,P052,Sylfaen,serif;--font-handwritten:Segoe Print,Bradley Hand,Chilanka,TSCu_Comic,casual,cursive;--font-sans:var(--font-system-ui);--font-serif:ui-serif,serif;--font-mono:var(--font-monospace-code);--font-weight-1:100;--font-weight-2:200;--font-weight-3:300;--font-weight-4:400;--font-weight-5:500;--font-weight-6:600;--font-weight-7:700;--font-weight-8:800;--font-weight-9:900;--font-lineheight-00:.95;--font-lineheight-0:1.1;--font-lineheight-1:1.25;--font-lineheight-2:1.375;--font-lineheight-3:1.5;--font-lineheight-4:1.75;--font-lineheight-5:2;--font-letterspacing-0:-.05em;--font-letterspacing-1:.025em;--font-letterspacing-2:.05em;--font-letterspacing-3:.075em;--font-letterspacing-4:.15em;--font-letterspacing-5:.5em;--font-letterspacing-6:.75em;--font-letterspacing-7:1em;--font-size-00:.5rem;--font-size-0:.75rem;--font-size-1:1rem;--font-size-2:1.1rem;--font-size-3:1.25rem;--font-size-4:1.5rem;--font-size-5:2rem;--font-size-6:2.5rem;--font-size-7:3rem;--font-size-8:3.5rem;--font-size-fluid-0:clamp(.75rem,2vw,1rem);--font-size-fluid-1:clamp(1rem,4vw,1.5rem);--font-size-fluid-2:clamp(1.5rem,6vw,2.5rem);--font-size-fluid-3:clamp(2rem,9vw,3.5rem);--size-000:-.5rem;--size-00:-.25rem;--size-1:.25rem;--size-2:.5rem;--size-3:1rem;--size-4:1.25rem;--size-5:1.5rem;--size-6:1.75rem;--size-7:2rem;--size-8:3rem;--size-9:4rem;--size-10:5rem;--size-11:7.5rem;--size-12:10rem;--size-13:15rem;--size-14:20rem;--size-15:30rem;--size-px-000:-8px;--size-px-00:-4px;--size-px-1:4px;--size-px-2:8px;--size-px-3:16px;--size-px-4:20px;--size-px-5:24px;--size-px-6:28px;--size-px-7:32px;--size-px-8:48px;--size-px-9:64px;--size-px-10:80px;--size-px-11:120px;--size-px-12:160px;--size-px-13:240px;--size-px-14:320px;--size-px-15:480px;--size-fluid-1:clamp(.5rem,1vw,1rem);--size-fluid-2:clamp(1rem,2vw,1.5rem);--size-fluid-3:clamp(1.5rem,3vw,2rem);--size-fluid-4:clamp(2rem,4vw,3rem);--size-fluid-5:clamp(4rem,5vw,5rem);--size-fluid-6:clamp(5rem,7vw,7.5rem);--size-fluid-7:clamp(7.5rem,10vw,10rem);--size-fluid-8:clamp(10rem,20vw,15rem);--size-fluid-9:clamp(15rem,30vw,20rem);--size-fluid-10:clamp(20rem,40vw,30rem);--size-content-1:20ch;--size-content-2:45ch;--size-content-3:60ch;--size-header-1:20ch;--size-header-2:25ch;--size-header-3:35ch;--size-xxs:240px;--size-xs:360px;--size-sm:480px;--size-md:768px;--size-lg:1024px;--size-xl:1440px;--size-xxl:1920px;--size-relative-000:-.5ch;--size-relative-00:-.25ch;--size-relative-1:.25ch;--size-relative-2:.5ch;--size-relative-3:1ch;--size-relative-4:1.25ch;--size-relative-5:1.5ch;--size-relative-6:1.75ch;--size-relative-7:2ch;--size-relative-8:3ch;--size-relative-9:4ch;--size-relative-10:5ch;--size-relative-11:7.5ch;--size-relative-12:10ch;--size-relative-13:15ch;--size-relative-14:20ch;--size-relative-15:30ch;--ease-1:cubic-bezier(.25,0,.5,1);--ease-2:cubic-bezier(.25,0,.4,1);--ease-3:cubic-bezier(.25,0,.3,1);--ease-4:cubic-bezier(.25,0,.2,1);--ease-5:cubic-bezier(.25,0,.1,1);--ease-in-1:cubic-bezier(.25,0,1,1);--ease-in-2:cubic-bezier(.5,0,1,1);--ease-in-3:cubic-bezier(.7,0,1,1);--ease-in-4:cubic-bezier(.9,0,1,1);--ease-in-5:cubic-bezier(1,0,1,1);--ease-out-1:cubic-bezier(0,0,.75,1);--ease-out-2:cubic-bezier(0,0,.5,1);--ease-out-3:cubic-bezier(0,0,.3,1);--ease-out-4:cubic-bezier(0,0,.1,1);--ease-out-5:cubic-bezier(0,0,0,1);--ease-in-out-1:cubic-bezier(.1,0,.9,1);--ease-in-out-2:cubic-bezier(.3,0,.7,1);--ease-in-out-3:cubic-bezier(.5,0,.5,1);--ease-in-out-4:cubic-bezier(.7,0,.3,1);--ease-in-out-5:cubic-bezier(.9,0,.1,1);--ease-elastic-out-1:cubic-bezier(.5,.75,.75,1.25);--ease-elastic-out-2:cubic-bezier(.5,1,.75,1.25);--ease-elastic-out-3:cubic-bezier(.5,1.25,.75,1.25);--ease-elastic-out-4:cubic-bezier(.5,1.5,.75,1.25);--ease-elastic-out-5:cubic-bezier(.5,1.75,.75,1.25);--ease-elastic-in-1:cubic-bezier(.5,-.25,.75,1);--ease-elastic-in-2:cubic-bezier(.5,-.5,.75,1);--ease-elastic-in-3:cubic-bezier(.5,-.75,.75,1);--ease-elastic-in-4:cubic-bezier(.5,-1,.75,1);--ease-elastic-in-5:cubic-bezier(.5,-1.25,.75,1);--ease-elastic-in-out-1:cubic-bezier(.5,-.1,.1,1.5);--ease-elastic-in-out-2:cubic-bezier(.5,-.3,.1,1.5);--ease-elastic-in-out-3:cubic-bezier(.5,-.5,.1,1.5);--ease-elastic-in-out-4:cubic-bezier(.5,-.7,.1,1.5);--ease-elastic-in-out-5:cubic-bezier(.5,-.9,.1,1.5);--ease-step-1:steps(2);--ease-step-2:steps(3);--ease-step-3:steps(4);--ease-step-4:steps(7);--ease-step-5:steps(10);--ease-elastic-1:var(--ease-elastic-out-1);--ease-elastic-2:var(--ease-elastic-out-2);--ease-elastic-3:var(--ease-elastic-out-3);--ease-elastic-4:var(--ease-elastic-out-4);--ease-elastic-5:var(--ease-elastic-out-5);--ease-squish-1:var(--ease-elastic-in-out-1);--ease-squish-2:var(--ease-elastic-in-out-2);--ease-squish-3:var(--ease-elastic-in-out-3);--ease-squish-4:var(--ease-elastic-in-out-4);--ease-squish-5:var(--ease-elastic-in-out-5);--ease-spring-1:linear(0,.006,.025 2.8%,.101 6.1%,.539 18.9%,.721 25.3%,.849 31.5%,.937 38.1%,.968 41.8%,.991 45.7%,1.006 50.1%,1.015 55%,1.017 63.9%,1.001);--ease-spring-2:linear(0,.007,.029 2.2%,.118 4.7%,.625 14.4%,.826 19%,.902,.962,1.008 26.1%,1.041 28.7%,1.064 32.1%,1.07 36%,1.061 40.5%,1.015 53.4%,.999 61.6%,.995 71.2%,1);--ease-spring-3:linear(0,.009,.035 2.1%,.141 4.4%,.723 12.9%,.938 16.7%,1.017,1.077,1.121,1.149 24.3%,1.159,1.163,1.161,1.154 29.9%,1.129 32.8%,1.051 39.6%,1.017 43.1%,.991,.977 51%,.974 53.8%,.975 57.1%,.997 69.8%,1.003 76.9%,1);--ease-spring-4:linear(0,.009,.037 1.7%,.153 3.6%,.776 10.3%,1.001,1.142 16%,1.185,1.209 19%,1.215 19.9% 20.8%,1.199,1.165 25%,1.056 30.3%,1.008 33%,.973,.955 39.2%,.953 41.1%,.957 43.3%,.998 53.3%,1.009 59.1% 63.7%,.998 78.9%,1);--ease-spring-5:linear(0,.01,.04 1.6%,.161 3.3%,.816 9.4%,1.046,1.189 14.4%,1.231,1.254 17%,1.259,1.257 18.6%,1.236,1.194 22.3%,1.057 27%,.999 29.4%,.955 32.1%,.942,.935 34.9%,.933,.939 38.4%,1 47.3%,1.011,1.017 52.6%,1.016 56.4%,1 65.2%,.996 70.2%,1.001 87.2%,1);--ease-bounce-1:linear(0,.004,.016,.035,.063,.098,.141,.191,.25,.316,.391 36.8%,.563,.766,1 58.8%,.946,.908 69.1%,.895,.885,.879,.878,.879,.885,.895,.908 89.7%,.946,1);--ease-bounce-2:linear(0,.004,.016,.035,.063,.098,.141 15.1%,.25,.391,.562,.765,1,.892 45.2%,.849,.815,.788,.769,.757,.753,.757,.769,.788,.815,.85,.892 75.2%,1 80.2%,.973,.954,.943,.939,.943,.954,.973,1);--ease-bounce-3:linear(0,.004,.016,.035,.062,.098,.141 11.4%,.25,.39,.562,.764,1 30.3%,.847 34.8%,.787,.737,.699,.672,.655,.65,.656,.672,.699,.738,.787,.847 61.7%,1 66.2%,.946,.908,.885 74.2%,.879,.878,.879,.885 79.5%,.908,.946,1 87.4%,.981,.968,.96,.957,.96,.968,.981,1);--ease-bounce-4:linear(0,.004,.016 3%,.062,.141,.25,.391,.562 18.2%,1 24.3%,.81,.676 32.3%,.629,.595,.575,.568,.575,.595,.629,.676 48.2%,.811,1 56.2%,.918,.86,.825,.814,.825,.86,.918,1 77.2%,.94 80.6%,.925,.92,.925,.94 87.5%,1 90.9%,.974,.965,.974,1);--ease-bounce-5:linear(0,.004,.016 2.5%,.063,.141,.25 10.1%,.562,1 20.2%,.783,.627,.534 30.9%,.511,.503,.511,.534 38%,.627,.782,1 48.7%,.892,.815,.769 56.3%,.757,.753,.757,.769 61.3%,.815,.892,1 68.8%,.908 72.4%,.885,.878,.885,.908 79.4%,1 83%,.954 85.5%,.943,.939,.943,.954 90.5%,1 93%,.977,.97,.977,1);--layer-1:1;--layer-2:2;--layer-3:3;--layer-4:4;--layer-5:5;--layer-important:2147483647;--shadow-color:220 3% 15%;--shadow-strength:1%;--inner-shadow-highlight:inset 0 -.5px 0 0 #fff,inset 0 .5px 0 0 rgba(0,0,0,.067);--shadow-1:0 1px 2px -1px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 9%));--shadow-2:0 3px 5px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 3%)),0 7px 14px -5px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 5%));--shadow-3:0 -1px 3px 0 hsl(var(--shadow-color)/calc(var(--shadow-strength) + 2%)),0 1px 2px -5px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 2%)),0 2px 5px -5px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 4%)),0 4px 12px -5px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 5%)),0 12px 15px -5px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 7%));--shadow-4:0 -2px 5px 0 hsl(var(--shadow-color)/calc(var(--shadow-strength) + 2%)),0 1px 1px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 3%)),0 2px 2px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 3%)),0 5px 5px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 4%)),0 9px 9px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 5%)),0 16px 16px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 6%));--shadow-5:0 -1px 2px 0 hsl(var(--shadow-color)/calc(var(--shadow-strength) + 2%)),0 2px 1px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 3%)),0 5px 5px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 3%)),0 10px 10px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 4%)),0 20px 20px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 5%)),0 40px 40px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 7%));--shadow-6:0 -1px 2px 0 hsl(var(--shadow-color)/calc(var(--shadow-strength) + 2%)),0 3px 2px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 3%)),0 7px 5px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 3%)),0 12px 10px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 4%)),0 22px 18px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 5%)),0 41px 33px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 6%)),0 100px 80px -2px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 7%));--inner-shadow-0:inset 0 0 0 1px hsl(var(--shadow-color)/calc(var(--shadow-strength) + 9%));--inner-shadow-1:inset 0 1px 2px 0 hsl(var(--shadow-color)/calc(var(--shadow-strength) + 9%)),var(--inner-shadow-highlight);--inner-shadow-2:inset 0 1px 4px 0 hsl(var(--shadow-color)/calc(var(--shadow-strength) + 9%)),var(--inner-shadow-highlight);--inner-shadow-3:inset 0 2px 8px 0 hsl(var(--shadow-color)/calc(var(--shadow-strength) + 9%)),var(--inner-shadow-highlight);--inner-shadow-4:inset 0 2px 14px 0 hsl(var(--shadow-color)/calc(var(--shadow-strength) + 9%)),var(--inner-shadow-highlight);--ratio-square:1;--ratio-landscape:4/3;--ratio-portrait:3/4;--ratio-widescreen:16/9;--ratio-ultrawide:18/5;--ratio-golden:1.618/1;--gray-0:#f8f9fa;--gray-1:#f1f3f5;--gray-2:#e9ecef;--gray-3:#dee2e6;--gray-4:#ced4da;--gray-5:#adb5bd;--gray-6:#868e96;--gray-7:#495057;--gray-8:#343a40;--gray-9:#212529;--gray-10:#16191d;--gray-11:#0d0f12;--gray-12:#030507;--stone-0:#f8fafb;--stone-1:#f2f4f6;--stone-2:#ebedef;--stone-3:#e0e4e5;--stone-4:#d1d6d8;--stone-5:#b1b6b9;--stone-6:#979b9d;--stone-7:#7e8282;--stone-8:#666968;--stone-9:#50514f;--stone-10:#3a3a37;--stone-11:#252521;--stone-12:#121210;--red-0:#fff5f5;--red-1:#ffe3e3;--red-2:#ffc9c9;--red-3:#ffa8a8;--red-4:#ff8787;--red-5:#ff6b6b;--red-6:#fa5252;--red-7:#f03e3e;--red-8:#e03131;--red-9:#c92a2a;--red-10:#b02525;--red-11:#962020;--red-12:#7d1a1a;--pink-0:#fff0f6;--pink-1:#ffdeeb;--pink-2:#fcc2d7;--pink-3:#faa2c1;--pink-4:#f783ac;--pink-5:#f06595;--pink-6:#e64980;--pink-7:#d6336c;--pink-8:#c2255c;--pink-9:#a61e4d;--pink-10:#8c1941;--pink-11:#731536;--pink-12:#59102a;--purple-0:#f8f0fc;--purple-1:#f3d9fa;--purple-2:#eebefa;--purple-3:#e599f7;--purple-4:#da77f2;--purple-5:#cc5de8;--purple-6:#be4bdb;--purple-7:#ae3ec9;--purple-8:#9c36b5;--purple-9:#862e9c;--purple-10:#702682;--purple-11:#5a1e69;--purple-12:#44174f;--violet-0:#f3f0ff;--violet-1:#e5dbff;--violet-2:#d0bfff;--violet-3:#b197fc;--violet-4:#9775fa;--violet-5:#845ef7;--violet-6:#7950f2;--violet-7:#7048e8;--violet-8:#6741d9;--violet-9:#5f3dc4;--violet-10:#5235ab;--violet-11:#462d91;--violet-12:#3a2578;--indigo-0:#edf2ff;--indigo-1:#dbe4ff;--indigo-2:#bac8ff;--indigo-3:#91a7ff;--indigo-4:#748ffc;--indigo-5:#5c7cfa;--indigo-6:#4c6ef5;--indigo-7:#4263eb;--indigo-8:#3b5bdb;--indigo-9:#364fc7;--indigo-10:#2f44ad;--indigo-11:#283a94;--indigo-12:#21307a;--blue-0:#e7f5ff;--blue-1:#d0ebff;--blue-2:#a5d8ff;--blue-3:#74c0fc;--blue-4:#4dabf7;--blue-5:#339af0;--blue-6:#228be6;--blue-7:#1c7ed6;--blue-8:#1971c2;--blue-9:#1864ab;--blue-10:#145591;--blue-11:#114678;--blue-12:#0d375e;--cyan-0:#e3fafc;--cyan-1:#c5f6fa;--cyan-2:#99e9f2;--cyan-3:#66d9e8;--cyan-4:#3bc9db;--cyan-5:#22b8cf;--cyan-6:#15aabf;--cyan-7:#1098ad;--cyan-8:#0c8599;--cyan-9:#0b7285;--cyan-10:#095c6b;--cyan-11:#074652;--cyan-12:#053038;--teal-0:#e6fcf5;--teal-1:#c3fae8;--teal-2:#96f2d7;--teal-3:#63e6be;--teal-4:#38d9a9;--teal-5:#20c997;--teal-6:#12b886;--teal-7:#0ca678;--teal-8:#099268;--teal-9:#087f5b;--teal-10:#066649;--teal-11:#054d37;--teal-12:#033325;--green-0:#ebfbee;--green-1:#d3f9d8;--green-2:#b2f2bb;--green-3:#8ce99a;--green-4:#69db7c;--green-5:#51cf66;--green-6:#40c057;--green-7:#37b24d;--green-8:#2f9e44;--green-9:#2b8a3e;--green-10:#237032;--green-11:#1b5727;--green-12:#133d1b;--lime-0:#f4fce3;--lime-1:#e9fac8;--lime-2:#d8f5a2;--lime-3:#c0eb75;--lime-4:#a9e34b;--lime-5:#94d82d;--lime-6:#82c91e;--lime-7:#74b816;--lime-8:#66a80f;--lime-9:#5c940d;--lime-10:#4c7a0b;--lime-11:#3c6109;--lime-12:#2c4706;--yellow-0:#fff9db;--yellow-1:#fff3bf;--yellow-2:#ffec99;--yellow-3:#ffe066;--yellow-4:#ffd43b;--yellow-5:#fcc419;--yellow-6:#fab005;--yellow-7:#f59f00;--yellow-8:#f08c00;--yellow-9:#e67700;--yellow-10:#b35c00;--yellow-11:#804200;--yellow-12:#663500;--orange-0:#fff4e6;--orange-1:#ffe8cc;--orange-2:#ffd8a8;--orange-3:#ffc078;--orange-4:#ffa94d;--orange-5:#ff922b;--orange-6:#fd7e14;--orange-7:#f76707;--orange-8:#e8590c;--orange-9:#d9480f;--orange-10:#bf400d;--orange-11:#99330b;--orange-12:#802b09;--choco-0:#fff8dc;--choco-1:#fce1bc;--choco-2:#f7ca9e;--choco-3:#f1b280;--choco-4:#e99b62;--choco-5:#df8545;--choco-6:#d46e25;--choco-7:#bd5f1b;--choco-8:#a45117;--choco-9:#8a4513;--choco-10:#703a13;--choco-11:#572f12;--choco-12:#3d210d;--brown-0:#faf4eb;--brown-1:#ede0d1;--brown-2:#e0cab7;--brown-3:#d3b79e;--brown-4:#c5a285;--brown-5:#b78f6d;--brown-6:#a87c56;--brown-7:#956b47;--brown-8:#825b3a;--brown-9:#6f4b2d;--brown-10:#5e3a21;--brown-11:#4e2b15;--brown-12:#422412;--sand-0:#f8fafb;--sand-1:#e6e4dc;--sand-2:#d5cfbd;--sand-3:#c2b9a0;--sand-4:#aea58c;--sand-5:#9a9178;--sand-6:#867c65;--sand-7:#736a53;--sand-8:#5f5746;--sand-9:#4b4639;--sand-10:#38352d;--sand-11:#252521;--sand-12:#121210;--camo-0:#f9fbe7;--camo-1:#e8ed9c;--camo-2:#d2df4e;--camo-3:#c2ce34;--camo-4:#b5bb2e;--camo-5:#a7a827;--camo-6:#999621;--camo-7:#8c851c;--camo-8:#7e7416;--camo-9:#6d6414;--camo-10:#5d5411;--camo-11:#4d460e;--camo-12:#36300a;--jungle-0:#ecfeb0;--jungle-1:#def39a;--jungle-2:#d0e884;--jungle-3:#c2dd6e;--jungle-4:#b5d15b;--jungle-5:#a8c648;--jungle-6:#9bbb36;--jungle-7:#8fb024;--jungle-8:#84a513;--jungle-9:#7a9908;--jungle-10:#658006;--jungle-11:#516605;--jungle-12:#3d4d04;--gradient-1:linear-gradient(to bottom right,#1f005c,#5b0060,#870160,#ac255e,#ca485c,#e16b5c,#f39060,#ffb56b);--gradient-2:linear-gradient(to bottom right,#48005c,#8300e2,#a269ff);--gradient-3:radial-gradient(circle at top right,#0ff,rgba(0,255,255,0)),radial-gradient(circle at bottom left,#ff1492,rgba(255,20,146,0));--gradient-4:linear-gradient(to bottom right,#00f5a0,#00d9f5);--gradient-5:conic-gradient(from -270deg at 75% 110%,#f0f,#fffaf0);--gradient-6:conic-gradient(from -90deg at top left,#000,#fff);--gradient-7:linear-gradient(to bottom right,#72c6ef,#004e8f);--gradient-8:conic-gradient(from 90deg at 50% 0%,#111,50%,#222,#111);--gradient-9:conic-gradient(from .5turn at bottom center,#add8e6,#fff);--gradient-10:conic-gradient(from 90deg at 40% -25%,gold,#f79d03,#ee6907,#e6390a,#de0d0d,#d61039,#cf1261,#c71585,#cf1261,#d61039,#de0d0d,#ee6907,#f79d03,gold,gold,gold);--gradient-11:conic-gradient(at bottom left,#ff1493,cyan);--gradient-12:conic-gradient(from 90deg at 25% -10%,#ff4500,#d3f340,#7bee85,#afeeee,#7bee85);--gradient-13:radial-gradient(circle at 50% 200%,#000142,#3b0083,#b300c3,#ff059f,#ff4661,#ffad86,#fff3c7);--gradient-14:conic-gradient(at top right,lime,cyan);--gradient-15:linear-gradient(to bottom right,#c7d2fe,#fecaca,#fef3c7);--gradient-16:radial-gradient(circle at 50% -250%,#374151,#111827,#000);--gradient-17:conic-gradient(from -90deg at 50% -25%,blue,#8a2be2);--gradient-18:linear-gradient(0deg,rgba(255,0,0,.8),rgba(255,0,0,0) 75%),linear-gradient(60deg,rgba(255,255,0,.8),rgba(255,255,0,0) 75%),linear-gradient(120deg,rgba(0,255,0,.8),rgba(0,255,0,0) 75%),linear-gradient(180deg,rgba(0,255,255,.8),rgba(0,255,255,0) 75%),linear-gradient(240deg,rgba(0,0,255,.8),rgba(0,0,255,0) 75%),linear-gradient(300deg,rgba(255,0,255,.8),rgba(255,0,255,0) 75%);--gradient-19:linear-gradient(to bottom right,#ffe259,#ffa751);--gradient-20:conic-gradient(from -135deg at -10% center,orange,#ff7715,#ff522a,#ff3f47,#ff5482,#ff69b4);--gradient-21:conic-gradient(from -90deg at 25% 115%,red,#f06,#f0c,#c0f,#60f,#00f,#00f,#00f,#00f);--gradient-22:linear-gradient(to bottom right,#acb6e5,#86fde8);--gradient-23:linear-gradient(to bottom right,#536976,#292e49);--gradient-24:conic-gradient(from .5turn at 0% 0%,#00c476,10%,#82b0ff,90%,#00c476);--gradient-25:conic-gradient(at 125% 50%,#b78cf7,#ff7c94,#ffcf0d,#ff7c94,#b78cf7);--gradient-26:linear-gradient(to bottom right,#9796f0,#fbc7d4);--gradient-27:conic-gradient(from .5turn at bottom left,#ff1493,#639);--gradient-28:conic-gradient(from -90deg at 50% 105%,#fff,orchid);--gradient-29:radial-gradient(circle at top right,#bfb3ff,rgba(191,179,255,0)),radial-gradient(circle at bottom left,#86acf9,rgba(134,172,249,0));--gradient-30:radial-gradient(circle at top right,#00ff80,rgba(0,255,128,0)),radial-gradient(circle at bottom left,#adffd6,rgba(173,255,214,0));--noise-1:url("data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='a'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.005' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)'/%3E%3C/svg%3E");--noise-2:url("data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 300 300' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='a'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.05' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)'/%3E%3C/svg%3E");--noise-3:url("data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 1024 1024' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='a'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.25' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)'/%3E%3C/svg%3E");--noise-4:url("data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 2056 2056' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='a'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.5' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)'/%3E%3C/svg%3E");--noise-5:url("data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 2056 2056' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='a'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.75' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)'/%3E%3C/svg%3E");--noise-filter-1:contrast(300%) brightness(100%);--noise-filter-2:contrast(200%) brightness(150%);--noise-filter-3:contrast(200%) brightness(250%);--noise-filter-4:contrast(200%) brightness(500%);--noise-filter-5:contrast(200%) brightness(1000%);--animation-fade-in:fade-in .5s var(--ease-3);--animation-fade-in-bloom:fade-in-bloom 2s var(--ease-3);--animation-fade-out:fade-out .5s var(--ease-3);--animation-fade-out-bloom:fade-out-bloom 2s var(--ease-3);--animation-scale-up:scale-up .5s var(--ease-3);--animation-scale-down:scale-down .5s var(--ease-3);--animation-slide-out-up:slide-out-up .5s var(--ease-3);--animation-slide-out-down:slide-out-down .5s var(--ease-3);--animation-slide-out-right:slide-out-right .5s var(--ease-3);--animation-slide-out-left:slide-out-left .5s var(--ease-3);--animation-slide-in-up:slide-in-up .5s var(--ease-3);--animation-slide-in-down:slide-in-down .5s var(--ease-3);--animation-slide-in-right:slide-in-right .5s var(--ease-3);--animation-slide-in-left:slide-in-left .5s var(--ease-3);--animation-shake-x:shake-x .75s var(--ease-out-5);--animation-shake-y:shake-y .75s var(--ease-out-5);--animation-shake-z:shake-z 1s var(--ease-in-out-3);--animation-spin:spin 2s linear infinite;--animation-ping:ping 5s var(--ease-out-3) infinite;--animation-blink:blink 1s var(--ease-out-3) infinite;--animation-float:float 3s var(--ease-in-out-3) infinite;--animation-bounce:bounce 2s var(--ease-squish-2) infinite;--animation-pulse:pulse 2s var(--ease-out-3) infinite;--border-size-1:1px;--border-size-2:2px;--border-size-3:5px;--border-size-4:10px;--border-size-5:25px;--radius-1:2px;--radius-2:5px;--radius-3:1rem;--radius-4:2rem;--radius-5:4rem;--radius-6:8rem;--radius-drawn-1:255px 15px 225px 15px/15px 225px 15px 255px;--radius-drawn-2:125px 10px 20px 185px/25px 205px 205px 25px;--radius-drawn-3:15px 255px 15px 225px/225px 15px 255px 15px;--radius-drawn-4:15px 25px 155px 25px/225px 150px 25px 115px;--radius-drawn-5:250px 25px 15px 20px/15px 80px 105px 115px;--radius-drawn-6:28px 100px 20px 15px/150px 30px 205px 225px;--radius-round:1e5px;--radius-blob-1:30% 70% 70% 30%/53% 30% 70% 47%;--radius-blob-2:53% 47% 34% 66%/63% 46% 54% 37%;--radius-blob-3:37% 63% 56% 44%/49% 56% 44% 51%;--radius-blob-4:63% 37% 37% 63%/43% 37% 63% 57%;--radius-blob-5:49% 51% 48% 52%/57% 44% 56% 43%;--radius-conditional-1:clamp(0px, calc(100vw - 100%) * 1e5,var(--radius-1));--radius-conditional-2:clamp(0px, calc(100vw - 100%) * 1e5,var(--radius-2));--radius-conditional-3:clamp(0px, calc(100vw - 100%) * 1e5,var(--radius-3));--radius-conditional-4:clamp(0px, calc(100vw - 100%) * 1e5,var(--radius-4));--radius-conditional-5:clamp(0px, calc(100vw - 100%) * 1e5,var(--radius-5));--radius-conditional-6:clamp(0px, calc(100vw - 100%) * 1e5,var(--radius-6))}@media (prefers-color-scheme:dark){:where(html){--shadow-color:220 40% 2%;--shadow-strength:25%;--inner-shadow-highlight:inset 0 -.5px 0 0 hsla(0,0%,100%,.067),inset 0 .5px 0 0 rgba(0,0,0,.467)}}@keyframes fade-in{to{opacity:1}}@keyframes fade-in-bloom{0%{filter:brightness(1) blur(20px);opacity:0}10%{filter:brightness(2) blur(10px);opacity:1}to{filter:brightness(1) blur(0);opacity:1}}@keyframes fade-out{to{opacity:0}}@keyframes fade-out-bloom{to{filter:brightness(1) blur(20px);opacity:0}10%{filter:brightness(2) blur(10px);opacity:1}0%{filter:brightness(1) blur(0);opacity:1}}@keyframes scale-up{to{transform:scale(1.25)}}@keyframes scale-down{to{transform:scale(.75)}}@keyframes slide-out-up{to{transform:translateY(-100%)}}@keyframes slide-out-down{to{transform:translateY(100%)}}@keyframes slide-out-right{to{transform:translate(100%)}}@keyframes slide-out-left{to{transform:translate(-100%)}}@keyframes slide-in-up{0%{transform:translateY(100%)}}@keyframes slide-in-down{0%{transform:translateY(-100%)}}@keyframes slide-in-right{0%{transform:translate(-100%)}}@keyframes slide-in-left{0%{transform:translate(100%)}}@keyframes shake-x{0%,to{transform:translate(0)}20%{transform:translate(-5%)}40%{transform:translate(5%)}60%{transform:translate(-5%)}80%{transform:translate(5%)}}@keyframes shake-y{0%,to{transform:translateY(0)}20%{transform:translateY(-5%)}40%{transform:translateY(5%)}60%{transform:translateY(-5%)}80%{transform:translateY(5%)}}@keyframes shake-z{0%,to{transform:rotate(0)}20%{transform:rotate(-2deg)}40%{transform:rotate(2deg)}60%{transform:rotate(-2deg)}80%{transform:rotate(2deg)}}@keyframes spin{to{transform:rotate(1turn)}}@keyframes ping{90%,to{opacity:0;transform:scale(2)}}@keyframes blink{0%,to{opacity:1}50%{opacity:.5}}@keyframes float{50%{transform:translateY(-25%)}}@keyframes bounce{25%{transform:translateY(-20%)}40%{transform:translateY(-3%)}0%,60%,to{transform:translateY(0)}}@keyframes pulse{50%{transform:scale(.9)}}@media (prefers-color-scheme:dark){@keyframes fade-in-bloom{0%{filter:brightness(1) blur(20px);opacity:0}10%{filter:brightness(.5) blur(10px);opacity:1}to{filter:brightness(1) blur(0);opacity:1}}}@media (prefers-color-scheme:dark){@keyframes fade-out-bloom{to{filter:brightness(1) blur(20px);opacity:0}10%{filter:brightness(.5) blur(10px);opacity:1}0%{filter:brightness(1) blur(0);opacity:1}}}@font-face{font-family:Material Icons;font-style:normal;font-weight:400;font-display:block;src:url(./material-icons-kAwBdRge.woff2) format("woff2"),url(./material-icons-Dr0goTwe.woff) format("woff")}.material-icons{font-family:Material Icons;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility;font-feature-settings:"liga"}@font-face{font-family:Material Icons Outlined;font-style:normal;font-weight:400;font-display:block;src:url(./material-icons-outlined-DZhiGvEA.woff2) format("woff2"),url(./material-icons-outlined-BpWbwl2n.woff) format("woff")}.material-icons-outlined{font-family:Material Icons Outlined;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility;font-feature-settings:"liga"}@font-face{font-family:Material Icons Round;font-style:normal;font-weight:400;font-display:block;src:url(./material-icons-round-DrirKXBx.woff2) format("woff2"),url(./material-icons-round-BDlwx-sv.woff) format("woff")}.material-icons-round{font-family:Material Icons Round;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility;font-feature-settings:"liga"}@font-face{font-family:Material Icons Sharp;font-style:normal;font-weight:400;font-display:block;src:url(./material-icons-sharp-gidztirS.woff2) format("woff2"),url(./material-icons-sharp-CH1KkVu7.woff) format("woff")}.material-icons-sharp{font-family:Material Icons Sharp;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility;font-feature-settings:"liga"}@font-face{font-family:Material Icons Two Tone;font-style:normal;font-weight:400;font-display:block;src:url(./material-icons-two-tone-DuNIpaEj.woff2) format("woff2"),url(./material-icons-two-tone-B7wz7mED.woff) format("woff")}.material-icons-two-tone{font-family:Material Icons Two Tone;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility;font-feature-settings:"liga"}.vjs-svg-icon{display:inline-block;background-repeat:no-repeat;background-position:center;fill:currentColor;height:1.8em;width:1.8em}.vjs-svg-icon:before{content:none!important}.vjs-svg-icon:hover,.vjs-control:focus .vjs-svg-icon{filter:drop-shadow(0 0 .25em #fff)}.vjs-modal-dialog .vjs-modal-dialog-content,.video-js .vjs-modal-dialog,.pillarbox-js .vjs-modal-dialog,.vjs-button>.vjs-icon-placeholder:before,.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{position:absolute;top:0;left:0;width:100%;height:100%}.vjs-button>.vjs-icon-placeholder:before,.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{text-align:center}@font-face{font-family:VideoJS;src:url(data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAABUgAAsAAAAAItAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADsAAABUIIslek9TLzIAAAFEAAAAPgAAAFZRiV33Y21hcAAAAYQAAAEJAAAD5p42+VxnbHlmAAACkAAADwwAABdk9R/WHmhlYWQAABGcAAAAKwAAADYn8kSnaGhlYQAAEcgAAAAdAAAAJA+RCL1obXR4AAAR6AAAABMAAAC8Q44AAGxvY2EAABH8AAAAYAAAAGB7SIHGbWF4cAAAElwAAAAfAAAAIAFAAI9uYW1lAAASfAAAASUAAAIK1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AdDDFCijEy5JhgileYYRd72MccBzjEa7zBEY5xglO8xTu8xwd8xCd8xhd8xTec4RwXuMR3/MBP/MJvMPzBFYpk2Cr+OF0fTEgrFI1aHhxN740KDbEmeJpsWZlVj40s+45aLuv9KijlhCXSjLQnu/d/4UH6sWul1mRzFxZeekUuE7z10mg3qMtM1FGQddPSrLQyvJR6OaukItYXDp6pCJrmz0umqkau5pZ2hFmm7m+ImG5W2t0kZoJXUtPhVnYTbbdOBdeCVGqpJe7XKTqSbRK7zbdwXfR0U+SVsStuS3Y76em6+Ic3xYiHUppc04Nn0lMzay3dSxNcp8auDlWlaCi48yetFD7Y9USsx87G45cuop1ZxQUtjLnL4j53FO0a+5X08UXqQ7NQNo92R0XOz7sxWEnxN2TneJI8Acttu4Q=) format("woff");font-weight:400;font-style:normal}.vjs-icon-play,.video-js .vjs-play-control .vjs-icon-placeholder,.pillarbox-js .vjs-play-control .vjs-icon-placeholder,.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-play:before,.video-js .vjs-play-control .vjs-icon-placeholder:before,.pillarbox-js .vjs-play-control .vjs-icon-placeholder:before,.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{content:""}.vjs-icon-play-circle{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-play-circle:before{content:""}.vjs-icon-pause,.video-js .vjs-play-control.vjs-playing .vjs-icon-placeholder,.pillarbox-js .vjs-play-control.vjs-playing .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-pause:before,.video-js .vjs-play-control.vjs-playing .vjs-icon-placeholder:before,.pillarbox-js .vjs-play-control.vjs-playing .vjs-icon-placeholder:before{content:""}.vjs-icon-volume-mute,.video-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder,.pillarbox-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-volume-mute:before,.video-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder:before,.pillarbox-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder:before{content:""}.vjs-icon-volume-low,.video-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder,.pillarbox-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-volume-low:before,.video-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder:before,.pillarbox-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder:before{content:""}.vjs-icon-volume-mid,.video-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder,.pillarbox-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-volume-mid:before,.video-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder:before,.pillarbox-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder:before{content:""}.vjs-icon-volume-high,.video-js .vjs-mute-control .vjs-icon-placeholder,.pillarbox-js .vjs-mute-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-volume-high:before,.video-js .vjs-mute-control .vjs-icon-placeholder:before,.pillarbox-js .vjs-mute-control .vjs-icon-placeholder:before{content:""}.vjs-icon-fullscreen-enter,.video-js .vjs-fullscreen-control .vjs-icon-placeholder,.pillarbox-js .vjs-fullscreen-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-fullscreen-enter:before,.video-js .vjs-fullscreen-control .vjs-icon-placeholder:before,.pillarbox-js .vjs-fullscreen-control .vjs-icon-placeholder:before{content:""}.vjs-icon-fullscreen-exit,.video-js.vjs-fullscreen .vjs-fullscreen-control .vjs-icon-placeholder,.vjs-fullscreen.pillarbox-js .vjs-fullscreen-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-fullscreen-exit:before,.video-js.vjs-fullscreen .vjs-fullscreen-control .vjs-icon-placeholder:before,.vjs-fullscreen.pillarbox-js .vjs-fullscreen-control .vjs-icon-placeholder:before{content:""}.vjs-icon-spinner{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-spinner:before{content:""}.vjs-icon-subtitles,.video-js .vjs-subs-caps-button .vjs-icon-placeholder,.pillarbox-js .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-GB) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-IE) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-AU) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-NZ) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js .vjs-subtitles-button .vjs-icon-placeholder,.pillarbox-js .vjs-subtitles-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-subtitles:before,.video-js .vjs-subs-caps-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-GB) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-IE) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-AU) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-NZ) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js .vjs-subtitles-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-subtitles-button .vjs-icon-placeholder:before{content:""}.vjs-icon-captions,.video-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder,.pillarbox-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder,.pillarbox-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js .vjs-captions-button .vjs-icon-placeholder,.pillarbox-js .vjs-captions-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-captions:before,.video-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder:before,.pillarbox-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder:before,.pillarbox-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js .vjs-captions-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-captions-button .vjs-icon-placeholder:before{content:""}.vjs-icon-hd{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-hd:before{content:""}.vjs-icon-chapters,.video-js .vjs-chapters-button .vjs-icon-placeholder,.pillarbox-js .vjs-chapters-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-chapters:before,.video-js .vjs-chapters-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-chapters-button .vjs-icon-placeholder:before{content:""}.vjs-icon-downloading{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-downloading:before{content:""}.vjs-icon-file-download{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-file-download:before{content:""}.vjs-icon-file-download-done{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-file-download-done:before{content:""}.vjs-icon-file-download-off{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-file-download-off:before{content:""}.vjs-icon-share{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-share:before{content:""}.vjs-icon-cog{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-cog:before{content:""}.vjs-icon-square{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-square:before{content:""}.vjs-icon-circle,.vjs-seek-to-live-control .vjs-icon-placeholder,.video-js .vjs-volume-level,.pillarbox-js .vjs-volume-level,.video-js .vjs-play-progress,.pillarbox-js .vjs-play-progress{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-circle:before,.vjs-seek-to-live-control .vjs-icon-placeholder:before,.video-js .vjs-volume-level:before,.pillarbox-js .vjs-volume-level:before,.video-js .vjs-play-progress:before,.pillarbox-js .vjs-play-progress:before{content:""}.vjs-icon-circle-outline{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-circle-outline:before{content:""}.vjs-icon-circle-inner-circle{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-circle-inner-circle:before{content:""}.vjs-icon-cancel,.video-js .vjs-control.vjs-close-button .vjs-icon-placeholder,.pillarbox-js .vjs-control.vjs-close-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-cancel:before,.video-js .vjs-control.vjs-close-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-control.vjs-close-button .vjs-icon-placeholder:before{content:""}.vjs-icon-repeat{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-repeat:before{content:""}.vjs-icon-replay,.video-js .vjs-play-control.vjs-ended .vjs-icon-placeholder,.pillarbox-js .vjs-play-control.vjs-ended .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-replay:before,.video-js .vjs-play-control.vjs-ended .vjs-icon-placeholder:before,.pillarbox-js .vjs-play-control.vjs-ended .vjs-icon-placeholder:before{content:""}.vjs-icon-replay-5,.video-js .vjs-skip-backward-5 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-backward-5 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-replay-5:before,.video-js .vjs-skip-backward-5 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-backward-5 .vjs-icon-placeholder:before{content:""}.vjs-icon-replay-10,.video-js .vjs-skip-backward-10 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-backward-10 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-replay-10:before,.video-js .vjs-skip-backward-10 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-backward-10 .vjs-icon-placeholder:before{content:""}.vjs-icon-replay-30,.video-js .vjs-skip-backward-30 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-backward-30 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-replay-30:before,.video-js .vjs-skip-backward-30 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-backward-30 .vjs-icon-placeholder:before{content:""}.vjs-icon-forward-5,.video-js .vjs-skip-forward-5 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-forward-5 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-forward-5:before,.video-js .vjs-skip-forward-5 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-forward-5 .vjs-icon-placeholder:before{content:""}.vjs-icon-forward-10,.video-js .vjs-skip-forward-10 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-forward-10 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-forward-10:before,.video-js .vjs-skip-forward-10 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-forward-10 .vjs-icon-placeholder:before{content:""}.vjs-icon-forward-30,.video-js .vjs-skip-forward-30 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-forward-30 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-forward-30:before,.video-js .vjs-skip-forward-30 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-forward-30 .vjs-icon-placeholder:before{content:""}.vjs-icon-audio,.video-js .vjs-audio-button .vjs-icon-placeholder,.pillarbox-js .vjs-audio-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-audio:before,.video-js .vjs-audio-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-audio-button .vjs-icon-placeholder:before{content:""}.vjs-icon-next-item{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-next-item:before{content:""}.vjs-icon-previous-item{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-previous-item:before{content:""}.vjs-icon-shuffle{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-shuffle:before{content:""}.vjs-icon-cast{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-cast:before{content:""}.vjs-icon-picture-in-picture-enter,.video-js .vjs-picture-in-picture-control .vjs-icon-placeholder,.pillarbox-js .vjs-picture-in-picture-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-picture-in-picture-enter:before,.video-js .vjs-picture-in-picture-control .vjs-icon-placeholder:before,.pillarbox-js .vjs-picture-in-picture-control .vjs-icon-placeholder:before{content:""}.vjs-icon-picture-in-picture-exit,.video-js.vjs-picture-in-picture .vjs-picture-in-picture-control .vjs-icon-placeholder,.vjs-picture-in-picture.pillarbox-js .vjs-picture-in-picture-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-picture-in-picture-exit:before,.video-js.vjs-picture-in-picture .vjs-picture-in-picture-control .vjs-icon-placeholder:before,.vjs-picture-in-picture.pillarbox-js .vjs-picture-in-picture-control .vjs-icon-placeholder:before{content:""}.vjs-icon-facebook{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-facebook:before{content:""}.vjs-icon-linkedin{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-linkedin:before{content:""}.vjs-icon-twitter{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-twitter:before{content:""}.vjs-icon-tumblr{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-tumblr:before{content:""}.vjs-icon-pinterest{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-pinterest:before{content:""}.vjs-icon-audio-description,.video-js .vjs-descriptions-button .vjs-icon-placeholder,.pillarbox-js .vjs-descriptions-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-audio-description:before,.video-js .vjs-descriptions-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-descriptions-button .vjs-icon-placeholder:before{content:""}.video-js,.pillarbox-js{display:inline-block;vertical-align:top;box-sizing:border-box;color:#fff;background-color:#000;position:relative;padding:0;font-size:10px;line-height:1;font-weight:400;font-style:normal;font-family:Arial,Helvetica,sans-serif;word-break:initial}.video-js:-moz-full-screen,.pillarbox-js:-moz-full-screen{position:absolute}.video-js:-webkit-full-screen,.pillarbox-js:-webkit-full-screen{width:100%!important;height:100%!important}.video-js[tabindex="-1"],[tabindex="-1"].pillarbox-js{outline:none}.video-js *,.pillarbox-js *,.video-js *:before,.pillarbox-js *:before,.video-js *:after,.pillarbox-js *:after{box-sizing:inherit}.video-js ul,.pillarbox-js ul{font-family:inherit;font-size:inherit;line-height:inherit;list-style-position:outside;margin:0}.video-js.vjs-fluid,.vjs-fluid.pillarbox-js,.video-js.vjs-16-9,.vjs-16-9.pillarbox-js,.video-js.vjs-4-3,.vjs-4-3.pillarbox-js,.video-js.vjs-9-16,.vjs-9-16.pillarbox-js,.video-js.vjs-1-1,.vjs-1-1.pillarbox-js{width:100%;max-width:100%}.video-js.vjs-fluid:not(.vjs-audio-only-mode),.vjs-fluid.pillarbox-js:not(.vjs-audio-only-mode),.video-js.vjs-16-9:not(.vjs-audio-only-mode),.vjs-16-9.pillarbox-js:not(.vjs-audio-only-mode),.video-js.vjs-4-3:not(.vjs-audio-only-mode),.vjs-4-3.pillarbox-js:not(.vjs-audio-only-mode),.video-js.vjs-9-16:not(.vjs-audio-only-mode),.vjs-9-16.pillarbox-js:not(.vjs-audio-only-mode),.video-js.vjs-1-1:not(.vjs-audio-only-mode),.vjs-1-1.pillarbox-js:not(.vjs-audio-only-mode){height:0}.video-js.vjs-16-9:not(.vjs-audio-only-mode),.vjs-16-9.pillarbox-js:not(.vjs-audio-only-mode){padding-top:56.25%}.video-js.vjs-4-3:not(.vjs-audio-only-mode),.vjs-4-3.pillarbox-js:not(.vjs-audio-only-mode){padding-top:75%}.video-js.vjs-9-16:not(.vjs-audio-only-mode),.vjs-9-16.pillarbox-js:not(.vjs-audio-only-mode){padding-top:177.7777777778%}.video-js.vjs-1-1:not(.vjs-audio-only-mode),.vjs-1-1.pillarbox-js:not(.vjs-audio-only-mode){padding-top:100%}.video-js.vjs-fill:not(.vjs-audio-only-mode),.vjs-fill.pillarbox-js:not(.vjs-audio-only-mode){width:100%;height:100%}.video-js .vjs-tech,.pillarbox-js .vjs-tech{position:absolute;top:0;left:0;width:100%;height:100%}.video-js.vjs-audio-only-mode .vjs-tech,.vjs-audio-only-mode.pillarbox-js .vjs-tech{display:none}body.vjs-full-window,body.vjs-pip-window{padding:0;margin:0;height:100%}.vjs-full-window .video-js.vjs-fullscreen,.vjs-full-window .vjs-fullscreen.pillarbox-js,body.vjs-pip-window .video-js,body.vjs-pip-window .pillarbox-js{position:fixed;overflow:hidden;z-index:1000;left:0;top:0;bottom:0;right:0}.video-js.vjs-fullscreen:not(.vjs-ios-native-fs),.vjs-fullscreen.pillarbox-js:not(.vjs-ios-native-fs),body.vjs-pip-window .video-js,body.vjs-pip-window .pillarbox-js{width:100%!important;height:100%!important;padding-top:0!important;display:block}.video-js.vjs-fullscreen.vjs-user-inactive,.vjs-fullscreen.vjs-user-inactive.pillarbox-js{cursor:none}.vjs-pip-container .vjs-pip-text{position:absolute;bottom:10%;font-size:2em;background-color:#000000b3;padding:.5em;text-align:center;width:100%}.vjs-layout-tiny.vjs-pip-container .vjs-pip-text,.vjs-layout-x-small.vjs-pip-container .vjs-pip-text,.vjs-layout-small.vjs-pip-container .vjs-pip-text{bottom:0;font-size:1.4em}.vjs-hidden{display:none!important}.vjs-disabled{opacity:.5;cursor:default}.video-js .vjs-offscreen,.pillarbox-js .vjs-offscreen{height:1px;left:-9999px;position:absolute;top:0;width:1px}.vjs-lock-showing{display:block!important;opacity:1!important;visibility:visible!important}.vjs-no-js{padding:20px;color:#fff;background-color:#000;font-size:18px;font-family:Arial,Helvetica,sans-serif;text-align:center;width:300px;height:150px;margin:0 auto}.vjs-no-js a,.vjs-no-js a:visited{color:#66a8cc}.video-js .vjs-big-play-button,.pillarbox-js .vjs-big-play-button{font-size:3em;line-height:1.5em;height:1.63332em;width:3em;display:block;position:absolute;top:50%;left:50%;padding:0;margin-top:-.81666em;margin-left:-1.5em;cursor:pointer;opacity:1;border:.06666em solid #fff;background-color:#2b333f;background-color:#2b333fb3;border-radius:.3em;transition:all .4s}.vjs-big-play-button .vjs-svg-icon{width:1em;height:1em;position:absolute;top:50%;left:50%;line-height:1;transform:translate(-50%,-50%)}.video-js:hover .vjs-big-play-button,.pillarbox-js:hover .vjs-big-play-button,.video-js .vjs-big-play-button:focus,.pillarbox-js .vjs-big-play-button:focus{border-color:#fff;background-color:#73859f;background-color:#73859f80;transition:all 0s}.vjs-controls-disabled .vjs-big-play-button,.vjs-has-started .vjs-big-play-button,.vjs-using-native-controls .vjs-big-play-button,.vjs-error .vjs-big-play-button{display:none}.vjs-has-started.vjs-paused.vjs-show-big-play-button-on-pause:not(.vjs-seeking,.vjs-scrubbing,.vjs-error) .vjs-big-play-button{display:block}.video-js button,.pillarbox-js button{background:none;border:none;color:inherit;display:inline-block;font-size:inherit;line-height:inherit;text-transform:none;text-decoration:none;transition:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}.vjs-control .vjs-button{width:100%;height:100%}.video-js .vjs-control.vjs-close-button,.pillarbox-js .vjs-control.vjs-close-button{cursor:pointer;height:3em;position:absolute;right:0;top:.5em;z-index:2}.video-js .vjs-modal-dialog,.pillarbox-js .vjs-modal-dialog{background:#000c;background:linear-gradient(180deg,#000c,#fff0);overflow:auto}.video-js .vjs-modal-dialog>*,.pillarbox-js .vjs-modal-dialog>*{box-sizing:border-box}.vjs-modal-dialog .vjs-modal-dialog-content{font-size:1.2em;line-height:1.5;padding:20px 24px;z-index:1}.vjs-menu-button{cursor:pointer}.vjs-menu-button.vjs-disabled{cursor:default}.vjs-workinghover .vjs-menu-button.vjs-disabled:hover .vjs-menu{display:none}.vjs-menu .vjs-menu-content{display:block;padding:0;margin:0;font-family:Arial,Helvetica,sans-serif;overflow:auto}.vjs-menu .vjs-menu-content>*{box-sizing:border-box}.vjs-scrubbing .vjs-control.vjs-menu-button:hover .vjs-menu{display:none}.vjs-menu li{display:flex;justify-content:center;list-style:none;margin:0;padding:.2em 0;line-height:1.4em;font-size:1.2em;text-align:center;text-transform:lowercase}.vjs-menu li.vjs-menu-item:focus,.vjs-menu li.vjs-menu-item:hover,.js-focus-visible .vjs-menu li.vjs-menu-item:hover{background-color:#73859f;background-color:#73859f80}.vjs-menu li.vjs-selected,.vjs-menu li.vjs-selected:focus,.vjs-menu li.vjs-selected:hover,.js-focus-visible .vjs-menu li.vjs-selected:hover{background-color:#fff;color:#2b333f}.vjs-menu li.vjs-selected .vjs-svg-icon,.vjs-menu li.vjs-selected:focus .vjs-svg-icon,.vjs-menu li.vjs-selected:hover .vjs-svg-icon,.js-focus-visible .vjs-menu li.vjs-selected:hover .vjs-svg-icon{fill:#000}.video-js .vjs-menu *:not(.vjs-selected):focus:not(:focus-visible),.pillarbox-js .vjs-menu *:not(.vjs-selected):focus:not(:focus-visible),.js-focus-visible .vjs-menu *:not(.vjs-selected):focus:not(.focus-visible){background:none}.vjs-menu li.vjs-menu-title{text-align:center;text-transform:uppercase;font-size:1em;line-height:2em;padding:0;margin:0 0 .3em;font-weight:700;cursor:default}.vjs-menu-button-popup .vjs-menu{display:none;position:absolute;bottom:0;width:10em;left:-3em;height:0em;margin-bottom:1.5em;border-top-color:#2b333fb3}.vjs-pip-window .vjs-menu-button-popup .vjs-menu{left:unset;right:1em}.vjs-menu-button-popup .vjs-menu .vjs-menu-content{background-color:#2b333f;background-color:#2b333fb3;position:absolute;width:100%;bottom:1.5em;max-height:15em}.vjs-layout-tiny .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-x-small .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:5em}.vjs-layout-small .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:10em}.vjs-layout-medium .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:14em}.vjs-layout-large .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-x-large .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-huge .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:25em}.vjs-workinghover .vjs-menu-button-popup.vjs-hover .vjs-menu,.vjs-menu-button-popup .vjs-menu.vjs-lock-showing{display:block}.video-js .vjs-menu-button-inline,.pillarbox-js .vjs-menu-button-inline{transition:all .4s;overflow:hidden}.video-js .vjs-menu-button-inline:before,.pillarbox-js .vjs-menu-button-inline:before{width:2.222222222em}.video-js .vjs-menu-button-inline:hover,.pillarbox-js .vjs-menu-button-inline:hover,.video-js .vjs-menu-button-inline:focus,.pillarbox-js .vjs-menu-button-inline:focus,.video-js .vjs-menu-button-inline.vjs-slider-active,.pillarbox-js .vjs-menu-button-inline.vjs-slider-active{width:12em}.vjs-menu-button-inline .vjs-menu{opacity:0;height:100%;width:auto;position:absolute;left:4em;top:0;padding:0;margin:0;transition:all .4s}.vjs-menu-button-inline:hover .vjs-menu,.vjs-menu-button-inline:focus .vjs-menu,.vjs-menu-button-inline.vjs-slider-active .vjs-menu{display:block;opacity:1}.vjs-menu-button-inline .vjs-menu-content{width:auto;height:100%;margin:0;overflow:hidden}.video-js .vjs-control-bar,.pillarbox-js .vjs-control-bar{display:none;width:100%;position:absolute;bottom:0;left:0;right:0;height:3em;background-color:#2b333f;background-color:#2b333fb3}.video-js:not(.vjs-controls-disabled,.vjs-using-native-controls,.vjs-error) .vjs-control-bar.vjs-lock-showing,.pillarbox-js:not(.vjs-controls-disabled,.vjs-using-native-controls,.vjs-error) .vjs-control-bar.vjs-lock-showing{display:flex!important}.vjs-has-started .vjs-control-bar,.vjs-audio-only-mode .vjs-control-bar{display:flex;visibility:visible;opacity:1;transition:visibility .1s,opacity .1s}.vjs-has-started.vjs-user-inactive.vjs-playing .vjs-control-bar{visibility:visible;opacity:0;pointer-events:none;transition:visibility 1s,opacity 1s}.vjs-controls-disabled .vjs-control-bar,.vjs-using-native-controls .vjs-control-bar,.vjs-error .vjs-control-bar{display:none!important}.vjs-audio.vjs-has-started.vjs-user-inactive.vjs-playing .vjs-control-bar,.vjs-audio-only-mode.vjs-has-started.vjs-user-inactive.vjs-playing .vjs-control-bar{opacity:1;visibility:visible;pointer-events:auto}.video-js .vjs-control,.pillarbox-js .vjs-control{position:relative;text-align:center;margin:0;padding:0;height:100%;width:4em;flex:none}.video-js .vjs-control.vjs-visible-text,.pillarbox-js .vjs-control.vjs-visible-text{width:auto;padding-left:1em;padding-right:1em}.vjs-button>.vjs-icon-placeholder:before{font-size:1.8em;line-height:1.67}.vjs-button>.vjs-icon-placeholder{display:block}.vjs-button>.vjs-svg-icon{display:inline-block}.video-js .vjs-control:focus:before,.pillarbox-js .vjs-control:focus:before,.video-js .vjs-control:hover:before,.pillarbox-js .vjs-control:hover:before,.video-js .vjs-control:focus,.pillarbox-js .vjs-control:focus{text-shadow:0em 0em 1em white}.video-js *:not(.vjs-visible-text)>.vjs-control-text,.pillarbox-js *:not(.vjs-visible-text)>.vjs-control-text{border:0;clip:rect(0 0 0 0);height:1px;overflow:hidden;padding:0;position:absolute;width:1px}.video-js .vjs-custom-control-spacer,.pillarbox-js .vjs-custom-control-spacer{display:none}.video-js .vjs-progress-control,.pillarbox-js .vjs-progress-control{cursor:pointer;flex:auto;display:flex;align-items:center;min-width:4em;touch-action:none}.video-js .vjs-progress-control.disabled,.pillarbox-js .vjs-progress-control.disabled{cursor:default}.vjs-live .vjs-progress-control{display:none}.vjs-liveui .vjs-progress-control{display:flex;align-items:center}.video-js .vjs-progress-holder,.pillarbox-js .vjs-progress-holder{flex:auto;transition:all .2s;height:.3em}.video-js .vjs-progress-control .vjs-progress-holder,.pillarbox-js .vjs-progress-control .vjs-progress-holder{margin:0 10px}.video-js .vjs-progress-control:hover .vjs-progress-holder,.pillarbox-js .vjs-progress-control:hover .vjs-progress-holder{font-size:1.6666666667em}.video-js .vjs-progress-control:hover .vjs-progress-holder.disabled,.pillarbox-js .vjs-progress-control:hover .vjs-progress-holder.disabled{font-size:1em}.video-js .vjs-progress-holder .vjs-play-progress,.pillarbox-js .vjs-progress-holder .vjs-play-progress,.video-js .vjs-progress-holder .vjs-load-progress,.pillarbox-js .vjs-progress-holder .vjs-load-progress,.video-js .vjs-progress-holder .vjs-load-progress div,.pillarbox-js .vjs-progress-holder .vjs-load-progress div{position:absolute;display:block;height:100%;margin:0;padding:0;width:0}.video-js .vjs-play-progress,.pillarbox-js .vjs-play-progress{background-color:#fff}.video-js .vjs-play-progress:before,.pillarbox-js .vjs-play-progress:before{font-size:.9em;position:absolute;right:-.5em;line-height:.35em;z-index:1}.vjs-svg-icons-enabled .vjs-play-progress:before{content:none!important}.vjs-play-progress .vjs-svg-icon{position:absolute;top:-.35em;right:-.4em;width:.9em;height:.9em;pointer-events:none;line-height:.15em;z-index:1}.video-js .vjs-load-progress,.pillarbox-js .vjs-load-progress{background:#73859f80}.video-js .vjs-load-progress div,.pillarbox-js .vjs-load-progress div{background:#73859fbf}.video-js .vjs-time-tooltip,.pillarbox-js .vjs-time-tooltip{background-color:#fff;background-color:#fffc;border-radius:.3em;color:#000;float:right;font-family:Arial,Helvetica,sans-serif;font-size:1em;padding:6px 8px 8px;pointer-events:none;position:absolute;top:-3.4em;visibility:hidden;z-index:1}.video-js .vjs-progress-holder:focus .vjs-time-tooltip,.pillarbox-js .vjs-progress-holder:focus .vjs-time-tooltip{display:none}.video-js .vjs-progress-control:hover .vjs-time-tooltip,.pillarbox-js .vjs-progress-control:hover .vjs-time-tooltip,.video-js .vjs-progress-control:hover .vjs-progress-holder:focus .vjs-time-tooltip{display:block;font-size:.6em;visibility:visible}.video-js .vjs-progress-control.disabled:hover .vjs-time-tooltip,.pillarbox-js .vjs-progress-control.disabled:hover .vjs-time-tooltip{font-size:1em}.video-js .vjs-progress-control .vjs-mouse-display,.pillarbox-js .vjs-progress-control .vjs-mouse-display{display:none;position:absolute;width:1px;height:100%;background-color:#000;z-index:1}.video-js .vjs-progress-control:hover .vjs-mouse-display,.pillarbox-js .vjs-progress-control:hover .vjs-mouse-display{display:block}.video-js.vjs-user-inactive .vjs-progress-control .vjs-mouse-display,.vjs-user-inactive.pillarbox-js .vjs-progress-control .vjs-mouse-display{visibility:hidden;opacity:0;transition:visibility 1s,opacity 1s}.vjs-mouse-display .vjs-time-tooltip{color:#fff;background-color:#000;background-color:#000c}.video-js .vjs-slider,.pillarbox-js .vjs-slider{position:relative;cursor:pointer;padding:0;margin:0 .45em;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;background-color:#73859f;background-color:#73859f80}.video-js .vjs-slider.disabled,.pillarbox-js .vjs-slider.disabled{cursor:default}.video-js .vjs-slider:focus,.pillarbox-js .vjs-slider:focus{text-shadow:0em 0em 1em white;box-shadow:0 0 1em #fff}.video-js .vjs-mute-control,.pillarbox-js .vjs-mute-control{cursor:pointer;flex:none}.video-js .vjs-volume-control,.pillarbox-js .vjs-volume-control{cursor:pointer;margin-right:1em;display:flex}.video-js .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-control.vjs-volume-horizontal{width:5em}.video-js .vjs-volume-panel .vjs-volume-control,.pillarbox-js .vjs-volume-panel .vjs-volume-control{visibility:visible;opacity:0;width:1px;height:1px;margin-left:-1px}.video-js .vjs-volume-panel,.pillarbox-js .vjs-volume-panel{transition:width 1s}.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control,.pillarbox-js .vjs-volume-panel.vjs-hover .vjs-volume-control,.video-js .vjs-volume-panel:active .vjs-volume-control,.pillarbox-js .vjs-volume-panel:active .vjs-volume-control,.video-js .vjs-volume-panel:focus .vjs-volume-control,.pillarbox-js .vjs-volume-panel:focus .vjs-volume-control,.video-js .vjs-volume-panel .vjs-volume-control:active,.pillarbox-js .vjs-volume-panel .vjs-volume-control:active,.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active{visibility:visible;opacity:1;position:relative;transition:visibility .1s,opacity .1s,height .1s,width .1s,left 0s,top 0s}.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-horizontal,.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-horizontal{width:5em;height:3em;margin-right:0}.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-vertical,.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-vertical{left:-3.5em;transition:left 0s}.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.video-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active{width:10em;transition:width .1s}.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-mute-toggle-only,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-mute-toggle-only{width:4em}.video-js .vjs-volume-panel .vjs-volume-control.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-volume-vertical{height:8em;width:3em;left:-3000em;transition:visibility 1s,opacity 1s,height 1s 1s,width 1s 1s,left 1s 1s,top 1s 1s}.video-js .vjs-volume-panel .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-volume-horizontal{transition:visibility 1s,opacity 1s,height 1s 1s,width 1s,left 1s 1s,top 1s 1s}.video-js .vjs-volume-panel,.pillarbox-js .vjs-volume-panel{display:flex}.video-js .vjs-volume-bar,.pillarbox-js .vjs-volume-bar{margin:1.35em .45em}.vjs-volume-bar.vjs-slider-horizontal{width:5em;height:.3em}.vjs-volume-bar.vjs-slider-vertical{width:.3em;height:5em;margin:1.35em auto}.video-js .vjs-volume-level,.pillarbox-js .vjs-volume-level{position:absolute;bottom:0;left:0;background-color:#fff}.video-js .vjs-volume-level:before,.pillarbox-js .vjs-volume-level:before{position:absolute;font-size:.9em;z-index:1}.vjs-slider-vertical .vjs-volume-level{width:.3em}.vjs-slider-vertical .vjs-volume-level:before{top:-.5em;left:-.3em;z-index:1}.vjs-svg-icons-enabled .vjs-volume-level:before{content:none}.vjs-volume-level .vjs-svg-icon{position:absolute;width:.9em;height:.9em;pointer-events:none;z-index:1}.vjs-slider-horizontal .vjs-volume-level{height:.3em}.vjs-slider-horizontal .vjs-volume-level:before{line-height:.35em;right:-.5em}.vjs-slider-horizontal .vjs-volume-level .vjs-svg-icon{right:-.3em;transform:translateY(-50%)}.vjs-slider-vertical .vjs-volume-level .vjs-svg-icon{top:-.55em;transform:translate(-50%)}.video-js .vjs-volume-panel.vjs-volume-panel-vertical,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-vertical{width:4em}.vjs-volume-bar.vjs-slider-vertical .vjs-volume-level{height:100%}.vjs-volume-bar.vjs-slider-horizontal .vjs-volume-level{width:100%}.video-js .vjs-volume-vertical,.pillarbox-js .vjs-volume-vertical{width:3em;height:8em;bottom:8em;background-color:#2b333f;background-color:#2b333fb3}.video-js .vjs-volume-horizontal .vjs-menu,.pillarbox-js .vjs-volume-horizontal .vjs-menu{left:-2em}.video-js .vjs-volume-tooltip,.pillarbox-js .vjs-volume-tooltip{background-color:#fff;background-color:#fffc;border-radius:.3em;color:#000;float:right;font-family:Arial,Helvetica,sans-serif;font-size:1em;padding:6px 8px 8px;pointer-events:none;position:absolute;top:-3.4em;visibility:hidden;z-index:1}.video-js .vjs-volume-control:hover .vjs-volume-tooltip,.pillarbox-js .vjs-volume-control:hover .vjs-volume-tooltip,.video-js .vjs-volume-control:hover .vjs-progress-holder:focus .vjs-volume-tooltip{display:block;font-size:1em;visibility:visible}.video-js .vjs-volume-vertical:hover .vjs-volume-tooltip,.pillarbox-js .vjs-volume-vertical:hover .vjs-volume-tooltip,.video-js .vjs-volume-vertical:hover .vjs-progress-holder:focus .vjs-volume-tooltip{left:1em;top:-12px}.video-js .vjs-volume-control.disabled:hover .vjs-volume-tooltip,.pillarbox-js .vjs-volume-control.disabled:hover .vjs-volume-tooltip{font-size:1em}.video-js .vjs-volume-control .vjs-mouse-display,.pillarbox-js .vjs-volume-control .vjs-mouse-display{display:none;position:absolute;width:100%;height:1px;background-color:#000;z-index:1}.video-js .vjs-volume-horizontal .vjs-mouse-display,.pillarbox-js .vjs-volume-horizontal .vjs-mouse-display{width:1px;height:100%}.video-js .vjs-volume-control:hover .vjs-mouse-display,.pillarbox-js .vjs-volume-control:hover .vjs-mouse-display{display:block}.video-js.vjs-user-inactive .vjs-volume-control .vjs-mouse-display,.vjs-user-inactive.pillarbox-js .vjs-volume-control .vjs-mouse-display{visibility:hidden;opacity:0;transition:visibility 1s,opacity 1s}.vjs-mouse-display .vjs-volume-tooltip{color:#fff;background-color:#000;background-color:#000c}.vjs-poster{display:inline-block;vertical-align:middle;cursor:pointer;margin:0;padding:0;position:absolute;top:0;right:0;bottom:0;left:0;height:100%}.vjs-has-started .vjs-poster,.vjs-using-native-controls .vjs-poster{display:none}.vjs-audio.vjs-has-started .vjs-poster,.vjs-has-started.vjs-audio-poster-mode .vjs-poster,.vjs-pip-container.vjs-has-started .vjs-poster{display:block}.vjs-poster img{width:100%;height:100%;-o-object-fit:contain;object-fit:contain}.video-js .vjs-live-control,.pillarbox-js .vjs-live-control{display:flex;align-items:flex-start;flex:auto;font-size:1em;line-height:3em}.video-js:not(.vjs-live) .vjs-live-control,.pillarbox-js:not(.vjs-live) .vjs-live-control,.video-js.vjs-liveui .vjs-live-control,.vjs-liveui.pillarbox-js .vjs-live-control{display:none}.video-js .vjs-seek-to-live-control,.pillarbox-js .vjs-seek-to-live-control{align-items:center;cursor:pointer;flex:none;display:inline-flex;height:100%;padding-left:.5em;padding-right:.5em;font-size:1em;line-height:3em;width:auto;min-width:4em}.video-js.vjs-live:not(.vjs-liveui) .vjs-seek-to-live-control,.vjs-live.pillarbox-js:not(.vjs-liveui) .vjs-seek-to-live-control,.video-js:not(.vjs-live) .vjs-seek-to-live-control,.pillarbox-js:not(.vjs-live) .vjs-seek-to-live-control{display:none}.vjs-seek-to-live-control.vjs-control.vjs-at-live-edge{cursor:auto}.vjs-seek-to-live-control .vjs-icon-placeholder{margin-right:.5em;color:#888}.vjs-svg-icons-enabled .vjs-seek-to-live-control{line-height:0}.vjs-seek-to-live-control .vjs-svg-icon{width:1em;height:1em;pointer-events:none;fill:#888}.vjs-seek-to-live-control.vjs-control.vjs-at-live-edge .vjs-icon-placeholder{color:red}.vjs-seek-to-live-control.vjs-control.vjs-at-live-edge .vjs-svg-icon{fill:red}.video-js .vjs-time-control,.pillarbox-js .vjs-time-control{flex:none;font-size:1em;line-height:3em;min-width:2em;width:auto;padding-left:1em;padding-right:1em}.vjs-live .vjs-time-control,.vjs-live .vjs-time-divider,.video-js .vjs-current-time,.pillarbox-js .vjs-current-time,.video-js .vjs-duration,.pillarbox-js .vjs-duration{display:none}.vjs-time-divider{display:none;line-height:3em}.video-js .vjs-play-control,.pillarbox-js .vjs-play-control{cursor:pointer}.video-js .vjs-play-control .vjs-icon-placeholder,.pillarbox-js .vjs-play-control .vjs-icon-placeholder{flex:none}.vjs-text-track-display{position:absolute;bottom:3em;left:0;right:0;top:0;pointer-events:none}.vjs-error .vjs-text-track-display{display:none}.video-js.vjs-controls-disabled .vjs-text-track-display,.vjs-controls-disabled.pillarbox-js .vjs-text-track-display,.video-js.vjs-user-inactive.vjs-playing .vjs-text-track-display,.vjs-user-inactive.vjs-playing.pillarbox-js .vjs-text-track-display{bottom:1em}.video-js .vjs-text-track,.pillarbox-js .vjs-text-track{font-size:1.4em;text-align:center;margin-bottom:.1em}.vjs-subtitles{color:#fff}.vjs-captions{color:#fc6}.vjs-tt-cue{display:block}video::-webkit-media-text-track-display{transform:translateY(-3em)}.video-js.vjs-controls-disabled video::-webkit-media-text-track-display,.vjs-controls-disabled.pillarbox-js video::-webkit-media-text-track-display,.video-js.vjs-user-inactive.vjs-playing video::-webkit-media-text-track-display,.vjs-user-inactive.vjs-playing.pillarbox-js video::-webkit-media-text-track-display{transform:translateY(-1.5em)}.video-js.vjs-force-center-align-cues .vjs-text-track-cue,.vjs-force-center-align-cues.pillarbox-js .vjs-text-track-cue{text-align:center!important;width:80%!important}.video-js .vjs-picture-in-picture-control,.pillarbox-js .vjs-picture-in-picture-control{cursor:pointer;flex:none}.video-js.vjs-audio-only-mode .vjs-picture-in-picture-control,.vjs-audio-only-mode.pillarbox-js .vjs-picture-in-picture-control,.vjs-pip-window .vjs-picture-in-picture-control{display:none}.video-js .vjs-fullscreen-control,.pillarbox-js .vjs-fullscreen-control{cursor:pointer;flex:none}.video-js.vjs-audio-only-mode .vjs-fullscreen-control,.vjs-audio-only-mode.pillarbox-js .vjs-fullscreen-control,.vjs-pip-window .vjs-fullscreen-control{display:none}.vjs-playback-rate>.vjs-menu-button,.vjs-playback-rate .vjs-playback-rate-value{position:absolute;top:0;left:0;width:100%;height:100%}.vjs-playback-rate .vjs-playback-rate-value{pointer-events:none;font-size:1.5em;line-height:2;text-align:center}.vjs-playback-rate .vjs-menu{width:4em;left:0}.vjs-error .vjs-error-display .vjs-modal-dialog-content{font-size:1.4em;text-align:center}.vjs-loading-spinner{display:none;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);opacity:.85;text-align:left;border:.6em solid rgba(43,51,63,.7);box-sizing:border-box;background-clip:padding-box;width:5em;height:5em;border-radius:50%;visibility:hidden}.vjs-seeking .vjs-loading-spinner,.vjs-waiting .vjs-loading-spinner{display:flex;justify-content:center;align-items:center;animation:vjs-spinner-show 0s linear .3s forwards}.vjs-error .vjs-loading-spinner{display:none}.vjs-loading-spinner:before,.vjs-loading-spinner:after{content:"";position:absolute;box-sizing:inherit;width:inherit;height:inherit;border-radius:inherit;opacity:1;border:inherit;border-color:transparent;border-top-color:#fff}.vjs-seeking .vjs-loading-spinner:before,.vjs-seeking .vjs-loading-spinner:after,.vjs-waiting .vjs-loading-spinner:before,.vjs-waiting .vjs-loading-spinner:after{animation:vjs-spinner-spin 1.1s cubic-bezier(.6,.2,0,.8) infinite,vjs-spinner-fade 1.1s linear infinite}.vjs-seeking .vjs-loading-spinner:before,.vjs-waiting .vjs-loading-spinner:before{border-top-color:#fff}.vjs-seeking .vjs-loading-spinner:after,.vjs-waiting .vjs-loading-spinner:after{border-top-color:#fff;animation-delay:.44s}@keyframes vjs-spinner-show{to{visibility:visible}}@keyframes vjs-spinner-spin{to{transform:rotate(360deg)}}@keyframes vjs-spinner-fade{0%{border-top-color:#73859f}20%{border-top-color:#73859f}35%{border-top-color:#fff}60%{border-top-color:#73859f}to{border-top-color:#73859f}}.video-js.vjs-audio-only-mode .vjs-captions-button,.vjs-audio-only-mode.pillarbox-js .vjs-captions-button{display:none}.vjs-chapters-button .vjs-menu ul{width:24em}.video-js.vjs-audio-only-mode .vjs-descriptions-button,.vjs-audio-only-mode.pillarbox-js .vjs-descriptions-button{display:none}.vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-svg-icon{width:1.5em;height:1.5em}.video-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder,.pillarbox-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder{vertical-align:middle;display:inline-block;margin-bottom:-.1em}.video-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before,.pillarbox-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before{font-family:VideoJS;content:"";font-size:1.5em;line-height:inherit}.video-js.vjs-audio-only-mode .vjs-subs-caps-button,.vjs-audio-only-mode.pillarbox-js .vjs-subs-caps-button{display:none}.video-js .vjs-audio-button+.vjs-menu .vjs-description-menu-item .vjs-menu-item-text .vjs-icon-placeholder,.pillarbox-js .vjs-audio-button+.vjs-menu .vjs-description-menu-item .vjs-menu-item-text .vjs-icon-placeholder,.video-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder,.pillarbox-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder{vertical-align:middle;display:inline-block;margin-bottom:-.1em}.video-js .vjs-audio-button+.vjs-menu .vjs-description-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before,.pillarbox-js .vjs-audio-button+.vjs-menu .vjs-description-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before,.video-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before,.pillarbox-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before{font-family:VideoJS;content:" ";font-size:1.5em;line-height:inherit}.video-js.vjs-layout-small .vjs-current-time,.vjs-layout-small.pillarbox-js .vjs-current-time,.video-js.vjs-layout-small .vjs-time-divider,.vjs-layout-small.pillarbox-js .vjs-time-divider,.video-js.vjs-layout-small .vjs-duration,.vjs-layout-small.pillarbox-js .vjs-duration,.video-js.vjs-layout-small .vjs-remaining-time,.vjs-layout-small.pillarbox-js .vjs-remaining-time,.video-js.vjs-layout-small .vjs-playback-rate,.vjs-layout-small.pillarbox-js .vjs-playback-rate,.video-js.vjs-layout-small .vjs-volume-control,.vjs-layout-small.pillarbox-js .vjs-volume-control,.video-js.vjs-layout-x-small .vjs-current-time,.vjs-layout-x-small.pillarbox-js .vjs-current-time,.video-js.vjs-layout-x-small .vjs-time-divider,.vjs-layout-x-small.pillarbox-js .vjs-time-divider,.video-js.vjs-layout-x-small .vjs-duration,.vjs-layout-x-small.pillarbox-js .vjs-duration,.video-js.vjs-layout-x-small .vjs-remaining-time,.vjs-layout-x-small.pillarbox-js .vjs-remaining-time,.video-js.vjs-layout-x-small .vjs-playback-rate,.vjs-layout-x-small.pillarbox-js .vjs-playback-rate,.video-js.vjs-layout-x-small .vjs-volume-control,.vjs-layout-x-small.pillarbox-js .vjs-volume-control,.video-js.vjs-layout-tiny .vjs-current-time,.vjs-layout-tiny.pillarbox-js .vjs-current-time,.video-js.vjs-layout-tiny .vjs-time-divider,.vjs-layout-tiny.pillarbox-js .vjs-time-divider,.video-js.vjs-layout-tiny .vjs-duration,.vjs-layout-tiny.pillarbox-js .vjs-duration,.video-js.vjs-layout-tiny .vjs-remaining-time,.vjs-layout-tiny.pillarbox-js .vjs-remaining-time,.video-js.vjs-layout-tiny .vjs-playback-rate,.vjs-layout-tiny.pillarbox-js .vjs-playback-rate,.video-js.vjs-layout-tiny .vjs-volume-control,.vjs-layout-tiny.pillarbox-js .vjs-volume-control{display:none}.video-js.vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.vjs-layout-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.video-js.vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal:active,.vjs-layout-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js.vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.vjs-layout-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js.vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.vjs-layout-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.video-js.vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.vjs-layout-x-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.video-js.vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal:active,.vjs-layout-x-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js.vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.vjs-layout-x-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js.vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.vjs-layout-x-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.video-js.vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.vjs-layout-tiny.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.video-js.vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal:active,.vjs-layout-tiny.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js.vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.vjs-layout-tiny.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js.vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.vjs-layout-tiny.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover{width:auto;width:initial}.video-js.vjs-layout-x-small .vjs-progress-control,.vjs-layout-x-small.pillarbox-js .vjs-progress-control,.video-js.vjs-layout-tiny .vjs-progress-control,.vjs-layout-tiny.pillarbox-js .vjs-progress-control{display:none}.video-js.vjs-layout-x-small .vjs-custom-control-spacer,.vjs-layout-x-small.pillarbox-js .vjs-custom-control-spacer{flex:auto;display:block}.vjs-modal-dialog.vjs-text-track-settings{background-color:#2b333f;background-color:#2b333fbf;color:#fff;height:70%}.vjs-error .vjs-text-track-settings{display:none}.vjs-text-track-settings .vjs-modal-dialog-content{display:table}.vjs-text-track-settings .vjs-track-settings-colors,.vjs-text-track-settings .vjs-track-settings-font,.vjs-text-track-settings .vjs-track-settings-controls{display:table-cell}.vjs-text-track-settings .vjs-track-settings-controls{text-align:right;vertical-align:bottom}@supports (display: grid){.vjs-text-track-settings .vjs-modal-dialog-content{display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr;padding:20px 24px 0}.vjs-track-settings-controls .vjs-default-button{margin-bottom:20px}.vjs-text-track-settings .vjs-track-settings-controls{grid-column:1/-1}.vjs-layout-small .vjs-text-track-settings .vjs-modal-dialog-content,.vjs-layout-x-small .vjs-text-track-settings .vjs-modal-dialog-content,.vjs-layout-tiny .vjs-text-track-settings .vjs-modal-dialog-content{grid-template-columns:1fr}}.vjs-text-track-settings select{font-size:inherit}.vjs-track-setting>select{margin-right:1em;margin-bottom:.5em}.vjs-text-track-settings fieldset{margin:10px;border:none}.vjs-text-track-settings fieldset span{display:inline-block;padding:0 .6em .8em}.vjs-text-track-settings fieldset span>select{max-width:7.3em}.vjs-text-track-settings legend{color:#fff;font-weight:700;font-size:1.2em}.vjs-text-track-settings .vjs-label{margin:0 .5em .5em 0}.vjs-track-settings-controls button:focus,.vjs-track-settings-controls button:active{outline-style:solid;outline-width:medium;background-image:linear-gradient(0deg,#fff 88%,#73859f)}.vjs-track-settings-controls button:hover{color:#2b333fbf}.vjs-track-settings-controls button{background-color:#fff;background-image:linear-gradient(-180deg,#fff 88%,#73859f);color:#2b333f;cursor:pointer;border-radius:2px}.vjs-track-settings-controls .vjs-default-button{margin-right:1em}.vjs-title-bar{background:#000000e6;background:linear-gradient(180deg,#000000e6,#000000b3 60%,#0000);font-size:1.2em;line-height:1.5;transition:opacity .1s;padding:.666em 1.333em 4em;pointer-events:none;position:absolute;top:0;width:100%}.vjs-error .vjs-title-bar{display:none}.vjs-title-bar-title,.vjs-title-bar-description{margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.vjs-title-bar-title{font-weight:700;margin-bottom:.333em}.vjs-playing.vjs-user-inactive .vjs-title-bar{opacity:0;transition:opacity 1s}.video-js .vjs-skip-forward-5,.pillarbox-js .vjs-skip-forward-5,.video-js .vjs-skip-forward-10,.pillarbox-js .vjs-skip-forward-10,.video-js .vjs-skip-forward-30,.pillarbox-js .vjs-skip-forward-30,.video-js .vjs-skip-backward-5,.pillarbox-js .vjs-skip-backward-5,.video-js .vjs-skip-backward-10,.pillarbox-js .vjs-skip-backward-10,.video-js .vjs-skip-backward-30,.pillarbox-js .vjs-skip-backward-30{cursor:pointer}@media print{.video-js>*:not(.vjs-tech):not(.vjs-poster),.pillarbox-js>*:not(.vjs-tech):not(.vjs-poster){visibility:hidden}}.vjs-resize-manager{position:absolute;top:0;left:0;width:100%;height:100%;border:none;z-index:-1000}.js-focus-visible .video-js *:focus:not(.focus-visible),.js-focus-visible .pillarbox-js *:focus:not(.focus-visible){outline:none}.video-js *:focus:not(:focus-visible),.pillarbox-js *:focus:not(:focus-visible){outline:none}.pillarbox-js:hover .vjs-big-play-button{background-color:#16161688;transition:background-color .25s ease}.pillarbox-js .vjs-big-play-button{width:2em;height:2em;margin:0;font-size:2.25em;background:#0000;border:.1em solid #fff;border-radius:50%;transform:translate(-50%,-50%);transition:background-color .25s ease}.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{position:initial;display:flex;align-items:center;justify-content:center;font-size:1.75em}.pillarbox-js .vjs-modal-dialog.vjs-text-track-settings{top:50%;left:50%;max-width:25em;max-height:50em;background:#161616f2;border-radius:.5em;box-shadow:2px 2px 3px #0005;transform:translate(-50%,-50%);overscroll-behavior:contain}.pillarbox-js .vjs-text-track-settings .vjs-modal-dialog-content{display:flex;flex-direction:column;padding:1em 1.5em 0}.pillarbox-js .vjs-text-track-settings legend{font-size:1em}.pillarbox-js .vjs-text-track-settings fieldset span{padding-inline:0}.pillarbox-js .vjs-text-track-settings fieldset{display:flex;margin:0 0 1em;padding:0}.pillarbox-js.video-js .vjs-text-track-settings select,.pillarbox-js .vjs-text-track-settings select{margin:.25em 0 0;padding:.5em;color:#fff;background:#3f3f3f;border:none;-webkit-appearance:auto;-moz-appearance:auto;appearance:auto}.pillarbox-js.video-js .vjs-text-track-settings select:focus-within,.pillarbox-js .vjs-text-track-settings select:focus-within{outline:solid}.pillarbox-js .vjs-track-settings-controls{display:flex;flex-direction:row;gap:1em;justify-content:end}.pillarbox-js .vjs-track-settings-controls button{margin-block:1em;padding:.25em .5em;color:#fff;background:#3f3f3f}.pillarbox-js .vjs-track-settings-controls button:hover{background:#5c5c5c}.pillarbox-js .vjs-track-settings-controls .vjs-default-button{margin-right:0}.pillarbox-js .vjs-control{height:3em}.pillarbox-js:not(.vjs-audio-only-mode) .vjs-control-bar{align-items:flex-end;height:6em;padding-inline:1em;background:linear-gradient(#000,#0000 0%,#000000b3)}.pillarbox-js.vjs-audio-only-mode .vjs-control-bar{background-color:#1e232c}.pillarbox-js:not(.vjs-audio-only-mode) .vjs-custom-control-spacer{display:block;flex:auto}.pillarbox-js .vjs-error-display .vjs-modal-dialog-content{display:flex;align-items:center;justify-content:center}.pillarbox-js.vjs-layout-tiny{font-size:8px}.pillarbox-js.vjs-layout-x-small{font-size:10px}.pillarbox-js.vjs-layout-small{font-size:12px}.pillarbox-js.vjs-layout-medium{font-size:14px}.pillarbox-js.vjs-layout-large{font-size:16px}.pillarbox-js.vjs-layout-x-large{font-size:18px}.pillarbox-js.vjs-layout-huge{font-size:20px}.pillarbox-js:not(.vjs-layout-tiny,.vjs-layout-x-small,.vjs-live) .vjs-time-divider,.pillarbox-js:not(.vjs-layout-tiny,.vjs-layout-x-small,.vjs-live) .vjs-current-time,.pillarbox-js:not(.vjs-layout-tiny,.vjs-layout-x-small,.vjs-live) .vjs-duration{display:block;padding:0;font-weight:700}.pillarbox-js.vjs-layout-tiny .vjs-progress-control,.pillarbox-js.vjs-layout-x-small .vjs-progress-control{display:flex}.pillarbox-js.vjs-layout-x-small.vjs-audio-only-mode .vjs-custom-control-spacer{display:none}.pillarbox-js .vjs-loading-spinner{border:.25em solid rgba(0,0,0,0)}.pillarbox-js .vjs-loading-spinner{display:flex;align-items:center;justify-content:center}@keyframes vjs-spinner-fade{0%{border-top-color:#333}20%{border-top-color:#333}35%{border-top-color:#fff}60%{border-top-color:#333}to{border-top-color:#333}}.pillarbox-js .vjs-menu .vjs-menu-item{border-radius:.25em}.pillarbox-js .vjs-menu .vjs-menu-item:not(.vjs-selected):focus,.pillarbox-js .vjs-menu .vjs-menu-item:not(.vjs-selected):hover{background-color:#3f3f3f}.pillarbox-js .vjs-menu .vjs-menu-item.vjs-texttrack-settings:focus,.pillarbox-js .vjs-menu .vjs-menu-item.vjs-texttrack-settings:hover{background-color:#0000}.pillarbox-js .vjs-menu .vjs-menu-item .vjs-selected{color:#222;background-color:#fff;pointer-events:none}.pillarbox-js .vjs-menu-button-popup.vjs-hover .vjs-menu{display:none}.pillarbox-js .vjs-menu-button-popup .vjs-menu{right:0;bottom:0;left:unset;width:100%;margin:0}.pillarbox-js .vjs-menu-button-popup .vjs-menu .vjs-menu-content{right:50%;bottom:5em;display:grid;gap:.25em;min-width:13em;padding:1em .5em;background:#161616f2;border-radius:.5em;transform:translate(50%);overscroll-behavior:contain}.pillarbox-js .vjs-slider{background-color:#ffffff4d;border-radius:1em}.pillarbox-js .vjs-text-track-display{top:0;right:0;bottom:4em;left:0}.pillarbox-js .vjs-current-time{margin-left:1em}.pillarbox-js .vjs-time-divider{min-width:1em;text-align:center}.pillarbox-js .vjs-remaining-time{display:none}.pillarbox-js.vjs-audio-only-mode .vjs-current-time,.pillarbox-js.vjs-audio-only-mode .vjs-time-divider,.pillarbox-js.vjs-audio-only-mode .vjs-duration{order:1}.pillarbox-js.vjs-audio-only-mode .vjs-duration{margin-right:1em}.pillarbox-js .vjs-title-bar{padding-bottom:2em;background:linear-gradient(rgba(0,0,0,.6) 0%,transparent 100%)}.pillarbox-js:not(.vjs-audio-only-mode) .vjs-progress-control{position:absolute;bottom:3em;width:calc(100% - 2em);height:1em}.pillarbox-js .vjs-progress-holder{margin:0}.pillarbox-js .vjs-load-progress{background:#ffffff4d;border-radius:1em}.pillarbox-js .vjs-load-progress div{background:#0000}.pillarbox-js.vjs-scrubbing .vjs-play-progress .vjs-time-tooltip,.pillarbox-js.vjs-seeking .vjs-play-progress .vjs-time-tooltip{display:none}.pillarbox-js .vjs-play-progress{color:#af001e;background:#af001e;border-radius:1em}.pillarbox-js .vjs-play-progress:before{font-size:0px;text-shadow:0px 0px 1px #000}.pillarbox-js .vjs-progress-control:hover .vjs-play-progress:before{font-size:.9em}.pillarbox-js .vjs-progress-control:hover .vjs-time-tooltip{right:0%!important;transform:translate(50%)}.pillarbox-js .vjs-progress-holder:focus-visible .vjs-play-progress:before{font-size:.9em}.pillarbox-js .vjs-time-tooltip,.pillarbox-js .vjs-mouse-display .vjs-time-tooltip{top:-3em;padding:.4em;color:#fff;font-weight:700;text-shadow:1px 1px 3px #000,1px 1px 2px #000;background-color:#0000}.pillarbox-js .vjs-volume-level{border-radius:1em}.pillarbox-js .vjs-volume-tooltip{top:-2em;padding:.4em;font-weight:700;text-shadow:1px 1px 3px #000;background-color:#0000}*,*:before,*:after{box-sizing:border-box}html{overflow-y:scroll;--color-1: var(--gray-1);--color-2: var(--gray-2);--color-3: var(--gray-3);--color-4: var(--gray-4);--color-5: var(--gray-5);--color-6: var(--gray-6);--color-7: var(--gray-7);--color-8: var(--gray-8);--color-9: var(--gray-9);--color-10: var(--gray-10);--color-11: var(--gray-11);--color-12: var(--gray-12)}@media (prefers-color-scheme: light){html{--color-1: var(--gray-12);--color-2: var(--gray-11);--color-3: var(--gray-10);--color-4: var(--gray-9);--color-5: var(--gray-8);--color-6: var(--gray-7);--color-7: var(--gray-6);--color-8: var(--gray-5);--color-9: var(--gray-4);--color-10: var(--gray-3);--color-11: var(--gray-2);--color-12: var(--gray-1)}}body{max-width:var(--size-md);margin:0 auto;padding:0 var(--size-2);color:var(--color-4);font-size:var(--size-5);font-family:var(--font-sans);background-color:var(--color-11)}body{max-width:var(--size-md)}.showcase-content{padding:0}.video-container{width:100%;height:auto;aspect-ratio:var(--ratio-widescreen);padding:0}h2{padding-left:var(--size-2);font-size:var(--size-4)}.showcase-btn{width:100%;margin:var(--size-3) 0;padding:var(--size-4) var(--size-3);color:var(--color-0);font-weight:var(--font-weight-6);font-size:var(--size-3);text-align:center;text-decoration:none;background-color:var(--color-9);border:0;border-radius:var(--radius-2);cursor:pointer;transition:background-color .4s,border-color .4s}.showcase-btn:hover{background-color:var(--color-8);border-color:var(--color-9)} diff --git a/pr-preview/pr-45/index.html b/pr-preview/pr-45/index.html index 2f1152e..9bcd6cf 100644 --- a/pr-preview/pr-45/index.html +++ b/pr-preview/pr-45/index.html @@ -31,7 +31,7 @@ }(window.location)); - + diff --git a/pr-preview/pr-45/static/showcases/quality-menu.html b/pr-preview/pr-45/static/showcases/quality-menu.html index 53ecb7c..0b41a1c 100644 --- a/pr-preview/pr-45/static/showcases/quality-menu.html +++ b/pr-preview/pr-45/static/showcases/quality-menu.html @@ -6,9 +6,9 @@ Pillarbox Demo - Quality Menu - + - +