1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[59e3],{59e3:function(e,t,i){let a;i.d(t,{ZP:function(){return c3}});var r=i(2512),n=i(28844),s=i(50598),o=s.ZP,l={VIDEO:"video",DRM:"drm"},d={NETWORK_OFFLINE:2000002,NETWORK_UNKNOWN_ERROR:2e6,NETWORK_INVALID_URL:24e5,NETWORK_NOT_FOUND:2404e3,NETWORK_NOT_READY:2412e3,NETWORK_TOKEN_MISSING:2403201,NETWORK_TOKEN_MALFORMED:2412202,NETWORK_TOKEN_EXPIRED:2403210,NETWORK_TOKEN_AUD_MISSING:2403221,NETWORK_TOKEN_AUD_MISMATCH:2403222,NETWORK_TOKEN_SUB_MISMATCH:2403232,ENCRYPTED_ERROR:5e6,ENCRYPTED_UNSUPPORTED_KEY_SYSTEM:5000001,ENCRYPTED_GENERATE_REQUEST_FAILED:5000002,ENCRYPTED_UPDATE_LICENSE_FAILED:5000003,ENCRYPTED_UPDATE_SERVER_CERT_FAILED:5000004,ENCRYPTED_CDM_ERROR:5000005,ENCRYPTED_OUTPUT_RESTRICTED:5000006,ENCRYPTED_MISSING_TOKEN:5000002},u=e=>e===l.VIDEO?"playback":e,c=class e extends Error{constructor(t,i=e.MEDIA_ERR_CUSTOM,a,r){var n;super(t),this.name="MediaError",this.code=i,this.context=r,this.fatal=null!=a?a:i>=e.MEDIA_ERR_NETWORK&&i<=e.MEDIA_ERR_ENCRYPTED,this.message||(this.message=null!=(n=e.defaultMessages[this.code])?n:"")}};c.MEDIA_ERR_ABORTED=1,c.MEDIA_ERR_NETWORK=2,c.MEDIA_ERR_DECODE=3,c.MEDIA_ERR_SRC_NOT_SUPPORTED=4,c.MEDIA_ERR_ENCRYPTED=5,c.MEDIA_ERR_CUSTOM=100,c.defaultMessages={1:"You aborted the media playback",2:"A network error caused the media download to fail.",3:"A media error caused playback to be aborted. The media could be corrupt or your browser does not support this format.",4:"An unsupported error occurred. The server or network failed, or your browser does not support this format.",5:"The media is encrypted and there are no keys to decrypt it."};var h=e=>null==e,m=(e,t)=>!h(t)&&e in t,p={ANY:"any",MUTED:"muted"},b={ON_DEMAND:"on-demand",LIVE:"live",UNKNOWN:"unknown"},v={MSE:"mse",NATIVE:"native"},E={HEADER:"header",QUERY:"query",NONE:"none"},g=Object.values(E),f={M3U8:"application/vnd.apple.mpegurl",MP4:"video/mp4"},A={HLS:f.M3U8};Object.keys(A),[...Object.values(f)];var y={code:"en"},T=(e,t,i,a,r=e)=>{r.addEventListener(t,i,a),e.addEventListener("teardown",()=>{r.removeEventListener(t,i)},{once:!0})},k=e=>{let t=e.indexOf("?");return t<0?[e]:[e.slice(0,t),e.slice(t)]},M=e=>{let{type:t}=e;if(t){let e=t.toUpperCase();return m(e,A)?A[e]:t}return w(e)},I=e=>"VOD"===e?b.ON_DEMAND:b.LIVE,_=e=>"EVENT"===e?Number.POSITIVE_INFINITY:"VOD"===e?Number.NaN:0,w=e=>{let{src:t}=e;if(!t)return"";let i="";try{i=S(t).pathname}catch{console.error("Invalid url when trying to infer mime type",t)}let a=i.lastIndexOf(".");if(a<0)return D(e)?f.M3U8:"";let r=i.slice(a+1).toUpperCase();return m(r,f)?f[r]:""},C=e=>{try{return new URL(e),!1}catch{return!0}},R=e=>e.split(` 2`).find((e,t,i)=>t>0&&i[t-1].startsWith("#EXT-X-STREAM-INF")),S=(e,t)=>{var i;if(!C(e))return new URL(e);let a=null==(i=null==window?void 0:window.location)?void 0:i.href,r=null!=t?t:a;return t&&C(t.toString())&&(r=new URL(t,a)),new URL(e,r)},L="mux.com",D=({src:e,customDomain:t=L})=>{let i;try{i=new URL(`${e}`)}catch{return!1}let a="https:"===i.protocol,r=i.hostname===`stream.${t}`.toLowerCase(),n=i.pathname.split("/"),s=2===n.length,o=!(null!=n&&n[1].includes("."));return a&&r&&s&&o},x=e=>{let t=(null!=e?e:"").split(".")[1];if(t)try{let e=t.replace(/-/g,"+").replace(/_/g,"/"),i=decodeURIComponent(atob(e).split("").map(function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)}).join(""));return JSON.parse(i)}catch{return}},N=({exp:e},t=Date.now())=>!e||1e3*e<t,O=({sub:e},t)=>e!==t,P=({aud:e},t)=>!e,U=({aud:e},t)=>e!==t;function W(e,t=!0){var i;return new $(t&&null!=(i=null==y?void 0:y[e])?i:e,t?y.code:"en")}var $=class{constructor(e,t=(e=>null!=(e=y)?e:"en")()){this.message=e,this.locale=t}format(e){return this.message.replace(/\{(\w+)\}/g,(t,i)=>{var a;return null!=(a=e[i])?a:""})}toString(){return this.message}},B=Object.values(p),H=e=>"boolean"==typeof e||"string"==typeof e&&B.includes(e),V=(e,t,i)=>{let{autoplay:a}=e,r=!1,n=!1,s=H(a)?a:!!a,l=()=>{r||T(t,"playing",()=>{r=!0},{once:!0})};if(l(),T(t,"loadstart",()=>{r=!1,l(),K(t,s)},{once:!0}),T(t,"loadstart",()=>{i||(n=e.streamType&&e.streamType!==b.UNKNOWN?e.streamType===b.LIVE:!Number.isFinite(t.duration)),K(t,s)},{once:!0}),i&&i.once(o.Events.LEVEL_LOADED,(t,i)=>{var a;n=e.streamType&&e.streamType!==b.UNKNOWN?e.streamType===b.LIVE:null!=(a=i.details.live)&&a}),!s){let a=()=>{!n||Number.isFinite(e.startTime)||(null!=i&&i.liveSyncPosition?t.currentTime=i.liveSyncPosition:Number.isFinite(t.seekable.end(0))&&(t.currentTime=t.
2seekable.end(0)))};i&&T(t,"play",()=>{"metadata"===t.preload?i.once(o.Events.LEVEL_UPDATED,a):a()},{once:!0})}return e=>{r||K(t,s=H(e)?e:!!e)}},K=(e,t)=>{if(!t)return;let i=e.muted,a=()=>e.muted=i;switch(t){case p.ANY:e.play().catch(()=>{e.muted=!0,e.play().catch(a)});break;case p.MUTED:e.muted=!0,e.play().catch(a);break;default:e.play().catch(()=>{})}},F=({preload:e,src:t},i,a)=>{let r=e=>{null!=e&&["","none","metadata","auto"].includes(e)?i.setAttribute("preload",e):i.removeAttribute("preload")};if(!a)return r(e),r;let n=!1,s=!1,o=a.config.maxBufferLength,l=a.config.maxBufferSize,d=e=>{r(e);let t=null!=e?e:i.preload;s||"none"===t||("metadata"===t?(a.config.maxBufferLength=1,a.config.maxBufferSize=1):(a.config.maxBufferLength=o,a.config.maxBufferSize=l),u())},u=()=>{!n&&t&&(n=!0,a.loadSource(t))};return T(i,"play",()=>{s=!0,a.config.maxBufferLength=o,a.config.maxBufferSize=l,u()},{once:!0}),d(e),d},Y=(e,t,i)=>{let{minPreloadSegments:a}=e;if(null==a||a<=0||!i)return;let r=0,n=!1,s=t.playbackRate||1,l=()=>{0!==t.playbackRate&&(s=t.playbackRate,t.playbackRate=0)};t.playbackRate=0,T(t,"ratechange",l);let d=(e,{frag:i})=>{n||"main"!==i.type||++r>=a&&(n=!0,t.removeEventListener("ratechange",l),t.playbackRate=s)};i.on(o.Events.FRAG_BUFFERED,d),t.addEventListener("teardown",()=>{n||(n=!0,i.off(o.Events.FRAG_BUFFERED,d),t.playbackRate=s)},{once:!0})},q=(e,t,i)=>{let{initialEstimateSegments:a}=e;if(null==a||a<=0||!i)return;let r=0;i.on(o.Events.FRAG_BUFFERED,(e,{frag:t})=>{"main"===t.type&&++r<a&&i.abrController.resetEstimator(i.config.abrEwmaDefaultEstimate)})},G=e=>"time"in e?e.time:e.startTime;function j(e,t,i,a,r,n){let s=document.createElement("track");return s.kind=t,s.label=i,a&&(s.srclang=a),r&&(s.id=r),n&&(s.default=!0),s.track.mode=["subtitles","captions"].includes(t)?"disabled":"hidden",s.setAttribute("data-removeondestroy",""),e.append(s),s.track}function Z(e,t,i){var a;return null==(a=Array.from(e.querySelectorAll("track")).find(e=>e.track.label===t&&e.track.kind===i))?void 0:a.track}async function z(e,t,i,a){let r=Z(e,i,a);return r||((r=j(e,a,i)).mode="hidden",await new Promise(e=>setTimeout(()=>e(void 0),0))),"hidden"!==r.mode&&(r.mode="hidden"),[...t].sort((e,t)=>
2G(t)-G(e)).forEach(t=>{var i,n;let s=t.value,o=G(t);if("endTime"in t&&null!=t.endTime)null==r||r.addCue(new VTTCue(o,t.endTime,"chapters"===a?s:JSON.stringify(null!=s?s:null)));else{let t=Array.prototype.findIndex.call(null==r?void 0:r.cues,e=>e.startTime>=o),l=null==(i=null==r?void 0:r.cues)?void 0:i[t],d=l?l.startTime:Number.isFinite(e.duration)?e.duration:Number.MAX_SAFE_INTEGER,u=null==(n=null==r?void 0:r.cues)?void 0:n[t-1];u&&(u.endTime=o),null==r||r.addCue(new VTTCue(o,d,"chapters"===a?s:JSON.stringify(null!=s?s:null)))}}),e.textTracks.dispatchEvent(new Event("change",{bubbles:!0,composed:!0})),r}var X="cuepoints",Q=Object.freeze({label:X});async function J(e,t,i=Q){return z(e,t,i.label,"metadata")}var ee=e=>({time:e.startTime,value:JSON.parse(e.text)});function et(e,t={label:X}){var i,a;let r=Z(e,t.label,"metadata");if(!(null!=(i=null==r?void 0:r.activeCues)&&i.length))return;if(1===r.activeCues.length)return ee(r.activeCues[0]);let{currentTime:n}=e;return ee(Array.prototype.find.call(null!=(a=r.activeCues)?a:[],({startTime:e,endTime:t})=>e<=n&&t>n)||r.activeCues[0])}async function ei(e,t=Q){return new Promise(i=>{T(e,"loadstart",async()=>{let a=await J(e,[],t);T(e,"cuechange",()=>{let t=et(e);if(t){let i=new CustomEvent("cuepointchange",{composed:!0,bubbles:!0,detail:t});e.dispatchEvent(i)}},{},a),i(a)})})}var ea="chapters",er=Object.freeze({label:ea}),en=e=>({startTime:e.startTime,endTime:e.endTime,value:e.text});async function es(e,t,i=er){return z(e,t,i.label,"chapters")}function eo(e,t={label:ea}){var i,a;let r=Z(e,t.label,"chapters");if(!(null!=(i=null==r?void 0:r.activeCues)&&i.length))return;if(1===r.activeCues.length)return en(r.activeCues[0]);let{currentTime:n}=e;return en(Array.prototype.find.call(null!=(a=r.activeCues)?a:[],({startTime:e,endTime:t})=>e<=n&&t>n)||r.activeCues[0])}async function el(e,t=er){return new Promise(i=>{T(e,"loadstart",async()=>{let a=await es(e,[],t);T(e,"cuechange",()=>{let t=eo(e);if(t){let i=new CustomEvent("chapterchange",{composed:!0,bubbles:!0,detail:t});e.dispatchEvent(i)}},{},a),i(a)})})}var ed={VIDEO:"v",THUMBNAIL:"t",STORYBOARD:"s",DRM:"d"},eu=e=>e===l.VIDEO?ed.VIDEO:e===l.DRM?ed.DRM:void 0,ec=(e,t)=>{var i,a;let r=u(e),n=`${r}Token`;return null!=(i=t.tokens)&&i[r]?null==(a=t.tokens)?void 0:a[r]:m(n,t)?t[n]:void 0},eh=(e,t,i,a,r=!1,n=!(e=>null==(e=globalThis.navigator)?void 0:e.onLine)())=>{var s,o;if(n){let i=W("Your device appears to be offline",r),a=c.MEDIA_ERR_NETWORK,n=new c(i,a,!1,void 0);return n.errorCategory=t,n.muxCode=d.NETWORK_OFFLINE,n.data=e,n}let l="status"in e?e.status:e.code,h=Date.now(),m=c.MEDIA_ERR_NETWORK;if(200===l)return;let p=u(t),v=ec(t,i),E=eu(t),[g]=k(null!=(s=i.playbackId)?s:"");if(!l||!g)return;let f=x(v);if(v&&!f){let i=new c(W("The {tokenNamePrefix}-token provided is invalid or malformed.",r).format({tokenNamePrefix:p}),m,!0,W("Compact JWT string: {token}",r).format({token:v}));return i.errorCategory=t,i.muxCode=d.NETWORK_TOKEN_MALFORMED,i.data=e,i}if(l>=500){let e=new c("",m,null==a||a);return e.errorCategory=t,e.muxCode=d.NETWORK_UNKNOWN_ERROR,e}if(403===l){if(f){if(N(f,h)){let i={timeStyle:"medium",dateStyle:"medium"},a=new c(W("The videoâs secured {tokenNamePrefix}-token has expired.",r).format({tokenNamePrefix:p}),m,!0,W("Expired at: {expiredDate}. Current time: {currentDate}.",r).format({expiredDate:new Intl.DateTimeFormat("en",i).format(null!=(o=f.exp)?o:0),currentDate:new Intl.DateTimeFormat("en",i).format(h)}));return a.errorCategory=t,a.muxCode=d.NETWORK_TOKEN_EXPIRED,a.data=e,a}if(O(f,g)){let i=new c(W("The videoâs playback ID does not match the one encoded in the {tokenNamePrefix}-token.",r).format({tokenNamePrefix:p}),m,!0,W("Specified playback ID: {playbackId} and the playback ID encoded in the {tokenNamePrefix}-token: {tokenPlaybackId}",r).format({tokenNamePrefix:p,playbackId:g,tokenPlaybackId:f.sub}));return i.errorCategory=t,i.muxCode=d.NETWORK_TOKEN_SUB_MISMATCH,i.data=e,i}if(P(f,E)){let i=new c(W("The {tokenNamePrefix}-token is formatted with incorrect information.",r).format({tokenNamePrefix:p}),m,!0,W("The {tokenNamePrefix}-token has no aud value. aud value should be {expectedAud}.",r).format({tokenNamePrefix:p,expectedAud:E}));return i.errorCategory=t,i.muxCode=d.NETWORK_TOKEN_AUD_MISSING,i.data=e,i}if(U(f,E)){let i=new c(W("The {tokenNamePrefix}-token is formatted with incorrect information.",r).format({tokenNamePrefix:p}),m,!0,W("The {tokenNamePrefix}-token has an incorrect aud value: {aud}. aud value should be {expectedAud}.",r).format({tokenNamePrefix:p,expectedAud:E,aud:f.aud}));return i.errorCategory=t,i.muxCode=d.NETWORK_TOKEN_AUD_MISMATCH,i.data=e,i}}else{let i=new c(W("Authorization error trying to access this {category} URL. If this is a signed URL, you might need to provide a {tokenNamePrefix}-token.",r).format({tokenNamePrefix:p,category:t}),m,null==a||a,W("Specified playback ID: {playbackId}",r).format({playbackId:g}));return i.errorCategory=t,i.muxCode=d.NETWORK_TOKEN_MISSING,i.data=e,i}}if(412===l){let n=new c(W("This playback-id may belong to a live stream that is not currently active or an asset that is not ready.",r),m,null==a||a,W("Specified playback ID: {playbackId}",r).format({playbackId:g}));return n.errorCategory=t,n.muxCode=d.NETWORK_NOT_READY,n.streamType=i.streamType===b.LIVE?"live":i.streamType===b.ON_DEMAND?"on-demand":"unknown",n.data=e,n}if(404===l){let i=new c(W("This URL or playback-id does not exist. You may have used an Asset ID or an ID from a different resource.",r),m,null==a||a,W("Specified playback ID: {playbackId}",r).format({playbackId:g}));return i.errorCategory=t,i.muxCode=d.NETWORK_NOT_FOUND,i.data=e,i}
2if(400===l){let i=new c(W("The URL or playback-id was invalid. You may have used an invalid value as a playback-id."),m,null==a||a,W("Specified playback ID: {playbackId}",r).format({playbackId:g}));return i.errorCategory=t,i.muxCode=d.NETWORK_INVALID_URL,i.data=e,i}let A=new c("",m,null==a||a);return A.errorCategory=t,A.muxCode=d.NETWORK_UNKNOWN_ERROR,A.data=e,A},em=o.DefaultConfig.capLevelController,ep={"720p":921600,"1080p":2073600,"1440p":4194304,"2160p":8294400},eb=class e extends em{constructor(e){super(e)}static setMaxAutoResolution(t,i){i?e.maxAutoResolution.set(t,i):e.maxAutoResolution.delete(t)}getMaxAutoResolution(){var t;let i=this.hls;return null!=(t=e.maxAutoResolution.get(i))?t:void 0}get levels(){var e;return null!=(e=this.hls.levels)?e:[]}getValidLevels(e){return this.levels.filter((t,i)=>this.isLevelAllowed(t)&&i<=e)}getMaxLevelCapped(e){let t=this.getValidLevels(e),i=this.getMaxAutoResolution();if(!i)return super.getMaxLevel(e);let a=ep[i.toLowerCase().trim()];if(!a)return super.getMaxLevel(e);let r=t.filter(e=>e.width*e.height<=a),n=r.findIndex(e=>e.width*e.height===a);if(-1!==n){let e=r[n];return t.findIndex(t=>t===e)}if(0===r.length)return 0;let s=r[r.length-1];return t.findIndex(e=>e===s)}getMaxLevel(t){if(void 0!==this.getMaxAutoResolution())return this.getMaxLevelCapped(t);let i=super.getMaxLevel(t),a=this.getValidLevels(t);if(!a[i])return i;let r=Math.min(a[i].width,a[i].height),n=e.minMaxResolution;return r>=n?i:em.getMaxLevelByMediaSize(a,16/9*n,n)}};eb.minMaxResolution=720,eb.maxAutoResolution=new WeakMap;var ev,eE,eg,ef,eA,ey,eT=({mediaEl:e,getAppCertificate:t,getLicenseKey:i,saveAndDispatchError:a,drmTypeCb:r})=>{if(!window.WebKitMediaKeys||!("onwebkitneedkey"in e)){console.error("No WebKitMediaKeys. FairPlay may not be supported");let t=new c(W("Cannot play DRM-protected content with current security configuration on this browser. Try playing in another browser."),c.MEDIA_ERR_ENCRYPTED,!0);return t.errorCategory=l.DRM,t.muxCode=d.ENCRYPTED_CDM_ERROR,a(e,t),()=>{}}let n=t(),s=null,o=t=>{(async()=>{try{e.webkitKeys||u();let i=await n;if(null===t.initData||null==i)return;let a=ek(t.initData,i);h(a)}catch(t){console.error("Could not start encrypted playback due to exception",t),a(e,t)}})()},u=()=>{try{let t=new WebKitMediaKeys("com.apple.fps.1_0");e.webkitSetMediaKeys(t),r()}catch{let e=new c("Cannot play DRM-protected content with current security configuration on this browser. Try playing in another browser.",c.MEDIA_ERR_ENCRYPTED,!0);throw e.errorCategory=l.DRM,e.muxCode=d.ENCRYPTED_UNSUPPORTED_KEY_SYSTEM,e}},h=t=>{let r=e.webkitKeys.createSession("application/vnd.apple.mpegurl",t),n=async t=>{try{let e=t.message,a=await i(e);r.update(a)}catch(t){console.error("Error on FairPlay session message",t),a(e,t)}},o=t=>{let i=t.target.error;if(!i)return;console.error(`Internal Webkit Key Session Error - sysCode: ${i.systemCode} code: ${i.code}`);let r=new c(W("The DRM Content Decryption Module system had an internal failure. Try reloading the page, upading your browser, or playing in another browser."),c.MEDIA_ERR_ENCRYPTED,!0);r.errorCategory=l.DRM,r.muxCode=d.ENCRYPTED_CDM_ERROR,a(e,r)},u=()=>{r.removeEventListener("webkitkeymessage",n),r.removeEventListener("webkitkeyerror",o),e.removeEventListener("teardown",u),"webkitCurrentPlaybackTargetIsWireless"in e&&e.removeEventListener("webkitcurrentplaybacktargetiswirelesschanged",u),s=null;try{r.close()}catch{}};"webkitCurrentPlaybackTargetIsWireless"in e&&e.addEventListener("webkitcurrentplaybacktargetiswirelesschanged",u,{once:!0}),r.addEventListener("webkitkeymessage",n),r.addEventListener("webkitkeyerror",o),e.addEventListener("teardown",u),s=u},m=()=>{e.removeEventListener("webkitneedkey",o),e.removeEventListener("teardown",m),null==s||s();try{e.webkitSetMediaKeys(null)}catch{}};return e.addEventListener("webkitneedkey",o),e.addEventListener("teardown",m,{once:!0}),m},ek=(e,t)=>{let i=function(e){let t=new ArrayBuffer(2*e.length),i=new DataView(t);for(let t=0;t<e.length;t++)i.setUint16(2*t,e.charCodeAt(t),!0);return t}(eM(e)),a=new Uint8Array(e),r=new Uint8Array(i),n=new Uint8Array(t),s=new Uint8Array(a.byteLength+4+n.byteLength+4+r.byteLength),o=0,l=e=>{s.set(e,o),o+=e.byteLength},d=e=>{let t=new DataView(s.buffer),i=e.byteLength;t.setUint32(o,i,!0),o+=4,l(e)};return l(a),d(r),d(n),s},eM=e=>new TextDecoder("utf-16le").decode(e).replace("skd://","").slice(1),eI=({mediaEl:e,getAppCertificate:t,getLicenseKey:i,saveAndDispatchError:a,drmTypeCb:r,fallbackToWebkitFairplay:n})=>{let s=null,o=async t=>{try{let i=t.initDataType;if("skd"!==i){console.error(`Received unexpected initialization data type "${i}"`);return}e.mediaKeys||await u(i);let a=t.initData;if(null==a){console.error(`Could not start encrypted playback due to missing initData in ${t.type} event`);return}await h(i,a)}catch(t){a(e,t);return}},u=async i=>{let n=await navigator.requestMediaKeySystemAccess("com.apple.fps",[{initDataTypes:[i],videoCapabilities:[{contentType:"application/vnd.apple.mpegurl",robustness:""}],distinctiveIdentifier:"not-allowed",persistentState:"not-allowed",sessionTypes:["temporary"]}]).then(e=>(r(),e)).catch(()=>{let t=new c(W("Cannot play DRM-protected content with current security configuration on this browser. Try playing in another browser."),c.MEDIA_ERR_ENCRYPTED,!0);
2t.errorCategory=l.DRM,t.muxCode=d.ENCRYPTED_UNSUPPORTED_KEY_SYSTEM,a(e,t)});if(!n)return;let s=await n.createMediaKeys();try{let e=await t();await s.setServerCertificate(e).catch(()=>{let e=W("Your server certificate failed when attempting to set it. This may be an issue with a no longer valid certificate."),t=new c(e,c.MEDIA_ERR_ENCRYPTED,!0);return t.errorCategory=l.DRM,t.muxCode=d.ENCRYPTED_UPDATE_SERVER_CERT_FAILED,Promise.reject(t)})}catch(t){a(e,t);return}await e.setMediaKeys(s)},h=async(t,r)=>{let o=e.mediaKeys.createSession(),u=async t=>{let r=t.message,n=await i(r);try{await o.update(n)}catch{let t=new c(W("Failed to update DRM license. This may be an issue with the player or your protected content."),c.MEDIA_ERR_ENCRYPTED,!0);t.errorCategory=l.DRM,t.muxCode=d.ENCRYPTED_UPDATE_LICENSE_FAILED,a(e,t)}},h=()=>{let t=t=>{let i;"internal-error"===t?((i=new c(W("The DRM Content Decryption Module system had an internal failure. Try reloading the page, upading your browser, or playing in another browser."),c.MEDIA_ERR_ENCRYPTED,!0)).errorCategory=l.DRM,i.muxCode=d.ENCRYPTED_CDM_ERROR):("output-restricted"===t||"output-downscaled"===t)&&((i=new c(W("DRM playback is being attempted in an environment that is not sufficiently secure. User may see black screen."),c.MEDIA_ERR_ENCRYPTED,!1)).errorCategory=l.DRM,i.muxCode=d.ENCRYPTED_OUTPUT_RESTRICTED),i&&a(e,i)};o.keyStatuses.forEach(e=>t(e))};o.addEventListener("keystatuseschange",h),o.addEventListener("message",u);let m=async()=>{o.removeEventListener("keystatuseschange",h),o.removeEventListener("message",u),"webkitCurrentPlaybackTargetIsWireless"in e&&e.removeEventListener("webkitcurrentplaybacktargetiswirelesschanged",m),e.removeEventListener("teardown",m),await o.close().catch(e=>{console.warn("There was an error when closing EME session",e)}),s=null};"webkitCurrentPlaybackTargetIsWireless"in e&&e.addEventListener("webkitcurrentplaybacktargetiswirelesschanged",m,{once:!0}),e.addEventListener("teardown",m,{once:!0}),s=m,await o.generateRequest(t,r).catch(async t=>{if("NotSupportedError"===t.name&&"webkitCurrentPlaybackTargetIsWireless"in e&&e.webkitCurrentPlaybackTargetIsWireless)console.warn("Failed to generate a DRM license request. Attempting to fallback to Webkit DRM"),null==n||n();else{let e=new c(W("Failed to generate a DRM license request. This may be an issue with the player or your protected content."),c.MEDIA_ERR_ENCRYPTED,!0);return e.errorCategory=l.DRM,e.muxCode=d.ENCRYPTED_GENERATE_REQUEST_FAILED,console.error("Failed to generate license request",t),Promise.reject(e)}})},m=async()=>{e.removeEventListener("encrypted",o),e.removeEventListener("teardown",m),s&&await s(),await e.setMediaKeys(null).catch(()=>{})};return e.addEventListener("encrypted",o),e.addEventListener("teardown",m,{once:!0}),m},e_={FAIRPLAY:"fairplay",PLAYREADY:"playready",WIDEVINE:"widevine"},ew=e=>e.includes("fps")?e_.FAIRPLAY:e.includes("playready")?e_.PLAYREADY:e.includes("widevine")?e_.WIDEVINE:void 0,eC=(e,t)=>{let i,a=R(e);if(!a)return Promise.reject(Error("No media playlist URL found in multivariant playlist"));if(C(a)&&!t)return Promise.reject(Error("masterPlaylistUrl is required to resolve relative media playlist URL"));try{i=S(a,t)}catch(e){return Promise.reject(e)}return fetch(i).then(e=>200!==e.status?Promise.reject(e):e.text())},eR=e=>{let t=e.split(` 3`).filter(e=>e.startsWith("#EXT-X-SESSION-DATA"));if(!t.length)return{};let i={};for(let e of t){let t=Object.fromEntries([...e.matchAll(eS)].map(([,e,t])=>[e,t])),a=t["DATA-ID"];a&&(i[a]={...t})}return{sessionData:i}},eS=/([A-Z0-9-]+)="?(.*?)"?(?:,|$)/g,eL=e=>{var t,i,a;let r=e.split(` 4`),n=null==(i=(null!=(t=r.find(e=>e.startsWith("#EXT-X-PLAYLIST-TYPE")))?t:"").split(":")[1])?void 0:i.trim(),s=I(n),o=_(n),l;if(s===b.LIVE){let e=r.find(e=>e.startsWith("#EXT-X-PART-INF"));if(e)l=2*+e.split(":")[1].split("=")[1];else{let e=r.find(e=>e.startsWith("#EXT-X-TARGETDURATION")),t=null==(a=null==e?void 0:e.split(":"))?void 0:a[1];l=3*+(null!=t?t:6)}}return{streamType:s,targetLiveWindow:o,liveEdgeStartOffset:l}},eD=async(e,t)=>{if(t===f.MP4)return{streamType:b.ON_DEMAND,targetLiveWindow:Number.NaN,liveEdgeStartOffset:void 0,sessionData:void 0};if(t===f.M3U8){let t=await fetch(e);if(!t.ok)return Promise.reject(t);let i=await t.text(),a=await eC(i,t.url);return{...eR(i),...eL(a)}}return console.error(`Media type ${t} is an unrecognized or unsupported type for src ${e}.`),{streamType:void 0,targetLiveWindow:void 0,liveEdgeStartOffset:void 0,sessionData:void 0}},ex=async(e,t,i=M({src:e}))=>{var a,r,n,s;let{streamType:o,targetLiveWindow:l,liveEdgeStartOffset:d,sessionData:u}=await eD(e,i),c=null==u?void 0:u["com.apple.hls.chapters"];(null!=c&&c.URI||null!=c&&c.VALUE.toLocaleLowerCase().startsWith("http"))&&eN(null!=(a=c.URI)?a:c.VALUE,t),(null!=(r=eH.get(t))?r:{}).liveEdgeStartOffset=d,(null!=(n=eH.get(t))?n:{}).targetLiveWindow=l,t.dispatchEvent(new CustomEvent("targetlivewindowch
4ange",{composed:!0,bubbles:!0})),(null!=(s=eH.get(t))?s:{}).streamType=o,t.dispatchEvent(new CustomEvent("streamtypechange",{composed:!0,bubbles:!0}))},eN=async(e,t)=>{var i,a;try{let r=await fetch(e);if(!r.ok)throw Error(`Failed to fetch Mux metadata: ${r.status} ${r.statusText}`);let n=await r.json(),s={};if(!(null!=(i=null==n?void 0:n[0])&&i.metadata))return;for(let e of n[0].metadata)e.key&&e.value&&(s[e.key]=e.value);(null!=(a=eH.get(t))?a:{}).metadata=s;let o=new CustomEvent("muxmetadata");t.dispatchEvent(o)}catch(e){console.error(e)}},eO=e=>{var t;let i=e.type,a=I(i),r=_(i),n,s=!!(null!=(t=e.partList)&&t.length);return a===b.LIVE&&(n=s?2*e.partTarget:3*e.targetduration),{streamType:a,targetLiveWindow:r,liveEdgeStartOffset:n,lowLatency:s}},eP=(e,t,i)=>{var a,r,n,s,o,l,d,u;let{streamType:c,targetLiveWindow:h,liveEdgeStartOffset:m,lowLatency:p}=eO(e);if(c===b.LIVE){p?(i.config.backBufferLength=null!=(a=i.userConfig.backBufferLength)?a:4,i.config.maxFragLookUpTolerance=null!=(r=i.userConfig.maxFragLookUpTolerance)?r:.001,i.config.abrBandWidthUpFactor=null!=(n=i.userConfig.abrBandWidthUpFactor)?n:i.config.abrBandWidthFactor):i.config.backBufferLength=null!=(s=i.userConfig.backBufferLength)?s:8;let e=Object.freeze({get length(){return t.seekable.length},start:e=>t.seekable.start(e),end(e){var a;return e>this.length||e<0||Number.isFinite(t.duration)?t.seekable.end(e):null!=(a=i.liveSyncPosition)?a:t.seekable.end(e)}});(null!=(o=eH.get(t))?o:{}).seekable=e}(null!=(l=eH.get(t))?l:{}).liveEdgeStartOffset=m,(null!=(d=eH.get(t))?d:{}).targetLiveWindow=h,t.dispatchEvent(new CustomEvent("targetlivewindowchange",{composed:!0,bubbles:!0})),(null!=(u=eH.get(t))?u:{}).streamType=c,t.dispatchEvent(new CustomEvent("streamtypechange",{composed:!0,bubbles:!0}))},eU=null!=(eE=null==(ev=null==globalThis?void 0:globalThis.navigator)?void 0:ev.userAgent)?eE:"",eW=null!=(eA=null==(ef=null==(eg=null==globalThis?void 0:globalThis.navigator)?void 0:eg.userAgentData)?void 0:ef.platform)?eA:"",e$=eU.toLowerCase().includes("android")||["x11","android"].some(e=>eW.toLowerCase().includes(e)),eB=e=>/^((?!chrome|android).)*safari/i.test(eU)&&!!e.canPlayType("application/vnd.apple.mpegurl"),eH=new WeakMap,eV="mux.com",eK=null==(ey=o.isSupported)?void 0:ey.call(o),eF=e=>e$||!eB(e),eY=()=>{if("undefined"!=typeof window)return n.Z.utils.now()},eq=n.Z.utils.generateUUID,eG=({playbackId:e,customDomain:t=eV,maxResolution:i,minResolution:a,renditionOrder:r,programStartTime:n,programEndTime:s,assetStartTime:o,assetEndTime:l,playbackToken:d,tokens:{playback:u=d}={},extraSourceParams:c={}}={})=>{if(!e)return;let[h,m=""]=k(e),p=new URL(`https://stream.${t}/${h}.m3u8${m}`);return u||p.searchParams.has("token")?(p.searchParams.forEach((e,t)=>{"token"!=t&&p.searchParams.delete(t)}),u&&p.searchParams.set("token",u)):(i&&p.searchParams.set("max_resolution",i),a&&(p.searchParams.set("min_resolution",a),i&&+i.slice(0,-1)<+a.slice(0,-1)&&console.error("minResolution must be <= maxResolution","minResolution",a,"maxResolution",i)),r&&p.searchParams.set("rendition_order",r),n&&p.searchParams.set("program_start_time",`${n}`),s&&p.searchParams.set("program_end_time",`${s}`),o&&p.searchParams.set("asset_start_time",`${o}`),l&&p.searchParams.set("asset_end_time",`${l}`),Object.entries(c).forEach(([e,t])=>{null!=t&&p.searchParams.set(e,t)})),p.toString()},ej=e=>{if(!e)return;let[t]=e.split("?");return t||void 0},eZ=e=>{if(!e||!e.startsWith("https://stream."))return;let[t]=new URL(e).pathname.slice(1).split(/\.m3u8|\//);return t||void 0},ez=e=>{var t,i,a;return null!=(t=null==e?void 0:e.metadata)&&t.video_id?e.metadata.video_id:tc(e)&&null!=(a=null!=(i=ej(e.playbackId))?i:eZ(e.src))?a:e.src},eX=e=>{var t;return null==(t=eH.get(e))?void 0:t.error},eQ=e=>{var t;return null==(t=eH.get(e))?void 0:t.metadata},eJ=e=>{var t,i;return null!=(i=null==(t=eH.get(e))?void 0:t.streamType)?i:b.UNKNOWN},e0=e=>{var t,i;return null!=(i=null==(t=eH.get(e))?void 0:t.targetLiveWindow)?i:Number.NaN},e1=e=>{var t,i;return null!=(i=null==(t=eH.get(e))?void 0:t.seekable)?i:e.seekable},e2=e=>{var t;let i=null==(t=eH.get(e))?void 0:t.liveEdgeStartOffset;if("number"!=typeof i)return Number.NaN;let a=e1(e);return a.length?a.end(a.length-1)-i:Number.NaN},e3=e=>{var t;return null==(t=eH.get(e))?void 0:t.coreReference},e4=.034,e5=(e,t,i=e4)=>
4Math.abs(e-t)<=i,e9=(e,t,i=e4)=>e>t||e5(e,t,i),e8=(e,t=e4)=>e.paused&&e9(e.currentTime,e.duration,t),e6=(e,t)=>{var i,a,r;if(!t||!e.buffered.length)return;if(e.readyState>2)return!1;let n=t.currentLevel>=0?null==(a=null==(i=t.levels)?void 0:i[t.currentLevel])?void 0:a.details:null==(r=t.levels.find(e=>!!e.details))?void 0:r.details;if(!n||n.live)return;let{fragments:s}=n;if(!(null!=s&&s.length))return;if(e.currentTime<e.duration-(n.targetduration+.5))return!1;let o=s[s.length-1];if(e.currentTime<=o.start)return!1;let l=o.start+o.duration/2,d=e.buffered.start(e.buffered.length-1),u=e.buffered.end(e.buffered.length-1);return l>d&&l<u},e7=(e,t)=>e.ended||e.loop?e.ended:!!(t&&e6(e,t))||e8(e),te=(e,t,i)=>{tt(t,i,e);let{metadata:a={}}=e,{view_session_id:r=eq()}=a,n=ez(e);a.view_session_id=r,a.video_id=n,e.metadata=a,e.drmTypeCb=e=>{var i;null==(i=t.mux)||i.emit("hb",{view_drm_type:e})},e.fallbackToWebkitFairplay=async()=>{var i;let a=!t.paused,r=t.currentTime;e.useWebkitFairplay=!0;let n=e.muxDataKeepSession;e.muxDataKeepSession=!0;let s=null==(i=eH.get(t))?void 0:i.coreReference;te(e,t,s),e.muxDataKeepSession=n,e.useWebkitFairplay=!1,a&&await t.play().then(()=>{t.currentTime=r}).catch(()=>{}),t.currentTime=r},eH.set(t,{retryCount:0});let s=ta(e,t),l=F(e,t,s);null!=e&&e.muxDataKeepSession&&null!=t&&t.mux&&!t.mux.deleted?s&&t.mux.addHLSJS({hlsjs:s,Hls:s?o:void 0}):tm(e,t,s),tp(e,t,s),ei(t),el(t);let d=V(e,t,s);
4Y(e,t,s),q(e,t,s);let u={engine:s,setAutoplay:d,setPreload:l},c=eH.get(t);return c&&(c.coreReference=u),u},tt=(e,t,i)=>{let a=null==t?void 0:t.engine;null!=e&&e.mux&&!e.mux.deleted&&(null!=i&&i.muxDataKeepSession?a&&e.mux.removeHLSJS():(e.mux.destroy(),delete e.mux)),a&&(a.detachMedia(),a.destroy()),e&&(e.hasAttribute("src")&&(e.removeAttribute("src"),e.load()),e.removeEventListener("error",tv),e.removeEventListener("error",tg),e.removeEventListener("durationchange",tb),eH.delete(e),e.dispatchEvent(new Event("teardown")))};function ti(e,t){var i;let a=M(e);if(a!==f.M3U8)return!0;let r=!a||null==(i=t.canPlayType(a))||i,{preferPlayback:n}=e,s=n===v.MSE,o=n===v.NATIVE,l=eK&&(s||eF(t));return r&&(o||!l)}var ta=(e,t)=>{let{debug:i,streamType:a,startTime:r=-1,metadata:n,preferCmcd:s,_hlsConfig:l={},maxAutoResolution:d,initialBandwidthEstimateKbps:u}=e,c=M(e)===f.M3U8,h=ti(e,t);if(c&&!h&&eK){let c={backBufferLength:30,renderTextTracksNatively:!1,liveDurationInfinity:!0,capLevelOnFPSDrop:!0,...null!=u?{abrEwmaDefaultEstimate:1e3*u}:{}},h=tr(a),m=tn(e),p=[E.QUERY,E.HEADER].includes(s)?{useHeaders:s===E.HEADER,sessionId:null==n?void 0:n.view_session_id,contentId:null==n?void 0:n.video_id}:void 0,b=th(e,l),v=new o({debug:i,startPosition:r,cmcd:p,xhrSetup:(e,t)=>{var i,a;if(s&&s!==E.QUERY)return;let r=S(t);if(!r.searchParams.has("CMCD"))return;let n=(null!=(a=null==(i=r.searchParams.get("CMCD"))?void 0:i.split(","))?a:[]).filter(e=>e.startsWith("sid")||e.startsWith("cid")).join(",");r.searchParams.set("CMCD",n),e.open("GET",r)},...c,...b,...h,...m,...l});return b.capLevelController===eb&&void 0!==d&&eb.setMaxAutoResolution(v,d),v.on(o.Events.MANIFEST_PARSED,async function(e,i){var a,r;let n=null==(a=i.sessionData)?void 0:a["com.apple.hls.chapters"];(null!=n&&n.URI||null!=n&&n.VALUE.toLocaleLowerCase().startsWith("http"))&&eN(null!=(r=null==n?void 0:n.URI)?r:null==n?void 0:n.VALUE,t)}),v}},tr=e=>e===b.LIVE?{backBufferLength:8}:{},tn=e=>{let{tokens:{drm:t}={},playbackId:i,drmTypeCb:a}=e,r=ej(i);return t&&r?{emeEnabled:!0,drmSystems:{"com.apple.fps":{licenseUrl:td(e,"fairplay"),serverCertificateUrl:tu(e,"fairplay")},"com.widevine.alpha":{licenseUrl:td(e,"widevine")},"com.microsoft.playready":{licenseUrl:td(e,"playready")}},requestMediaKeySystemAccessFunc:(e,t)=>("com.widevine.alpha"===e&&(t=[...t.map(e=>{var t;let i=null==(t=e.videoCapabilities)?void 0:t.map(e=>({...e,robustness:"HW_SECURE_ALL"}));return{...e,videoCapabilities:i}}),...t]),navigator.requestMediaKeySystemAccess(e,t).then(t=>{let i=ew(e);return null==a||a(i),t}))}:{}},ts=async e=>{let t=await fetch(e);return 200!==t.status?Promise.reject(t):await t.arrayBuffer()},to=async(e,t)=>{let i=await fetch(t,{method:"POST",headers:{"Content-type":"application/octet-stream"},body:e});return 200!==i.status?Promise.reject(i):new Uint8Array(await i.arrayBuffer())},tl=(e,t)=>{let i={mediaEl:t,getAppCertificate:()=>ts(tu(e,"fairplay")).catch(t=>{if(t instanceof Response){let i=eh(t,l.DRM,e);return console.error("mediaError",null==i?void 0:i.message,null==i?void 0:i.context),i?Promise.reject(i):Promise.reject(Error("Unexpected error in app cert request"))}return Promise.reject(t)}),getLicenseKey:t=>to(t,td(e,"fairplay")).catch(t=>{if(t instanceof Response){let i=eh(t,l.DRM,e);return console.error("mediaError",null==i?void 0:i.message,null==i?void 0:i.context),i?Promise.reject(i):Promise.reject(Error("Unexpected error in license key request"))}return Promise.reject(t)}),saveAndDispatchError:tE,drmTypeCb:()=>{var t;null==(t=e.drmTypeCb)||t.call(e,e_.FAIRPLAY)}};if(e.useWebkitFairplay)eT(i);else{let t=eI({fallbackToWebkitFairplay:async()=>{var i;await t(),null==(i=e.fallbackToWebkitFairplay)||i.call(e)},...i})}},td=({playbackId:e,tokens:{drm:t}={},customDomain:i=eV},a)=>{let r=ej(e);return`https://license.${i.toLocaleLowerCase().endsWith(eV)?i:eV}/license/${a}/${r}?token=${t}`},tu=({playbackId:e,tokens:{drm:t}={},customDomain:i=eV},a)=>{let r=ej(e);return`https://license.${i.toLocaleLowerCase().endsWith(eV)?i:eV}/appcert/${a}/${r}?token=${t}`},tc=({playbackId:e,src:t,customDomain:i})=>{if(e)return!0;
4if("string"!=typeof t)return!1;let a=new URL(t,null==window?void 0:window.location.href).hostname.toLocaleLowerCase();return a.includes(eV)||!!i&&a.includes(i.toLocaleLowerCase())},th=(e,t)=>{let i={};return i.capLevelToPlayerSize=e.capRenditionToPlayerSize,null==i.capLevelToPlayerSize?(i.capLevelController=eb,i.capLevelToPlayerSize=!0):i.capLevelController=s.wl,i},tm=(e,t,i)=>{var a;let{envKey:r,disableTracking:s,muxDataSDK:l=n.Z,muxDataSDKOptions:d={}}=e,u=tc(e);if(!s&&(r||u)){let{playerInitTime:n,playerSoftwareName:s,playerSoftwareVersion:u,beaconCollectionDomain:c,debug:h,disableCookies:m}=e,p={...e.metadata,video_title:(null==(a=null==e?void 0:e.metadata)?void 0:a.video_title)||void 0};l.monitor(t,{debug:h,beaconCollectionDomain:c,hlsjs:i,Hls:i?o:void 0,automaticErrorTracking:!1,errorTranslator:t=>"string"!=typeof t.player_error_code&&("function"==typeof e.errorTranslator?e.errorTranslator(t):t),disableCookies:m,...d,data:{...r?{env_key:r}:{},player_software_name:s,player_software:s,player_software_version:u,player_init_time:n,...p}})}},tp=(e,t,i)=>{var a,r;let n=ti(e,t),{src:s,customDomain:u=eV}=e,h=()=>{t.ended||e.disablePseudoEnded||!e7(t,i)||(e6(t,i)?t.currentTime=t.buffered.end(t.buffered.length-1):t.dispatchEvent(new Event("ended")))},m,p,v=()=>{let e=e1(t),i,a;e.length>0&&(i=e.start(0),a=e.end(0)),(p!==a||m!==i)&&t.dispatchEvent(new CustomEvent("seekablechange",{composed:!0})),m=i,p=a};if(T(t,"durationchange",v),t&&n){let i=M(e);if("string"==typeof s){if(s.endsWith(".mp4")&&s.includes(u)){let e=eZ(s);eN(new URL(`https://stream.${u}/${e}/metadata.json`).toString(),t)}let n=()=>{if(eJ(t)!==b.LIVE||Number.isFinite(t.duration))return;let e=setInterval(v,1e3);t.addEventListener("teardown",()=>{clearInterval(e)},{once:!0}),T(t,"durationchange",()=>{Number.isFinite(t.duration)&&clearInterval(e)})},o=async()=>ex(s,t,i).then(n).catch(i=>{if(i instanceof Response){let a=eh(i,l.VIDEO,e);if(a){tE(t,a);return}}});if("none"===t.preload){let e=()=>{o(),t.removeEventListener("loadedmetadata",i)},i=()=>{o(),t.removeEventListener("play",e)};T(t,"play",e,{once:!0}),T(t,"loadedmetadata",i,{once:!0})}else o();null!=(a=e.tokens)&&a.drm?tl(e,t):T(t,"encrypted",()=>{let e=new c(W("Attempting to play DRM-protected content without providing a DRM token."),c.MEDIA_ERR_ENCRYPTED,!0);e.errorCategory=l.DRM,e.muxCode=d.ENCRYPTED_MISSING_TOKEN,tE(t,e)},{once:!0}),t.setAttribute("src",s),e.startTime&&((null!=(r=eH.get(t))?r:{}).startTime=e.startTime,t.addEventListener("durationchange",tb,{once:!0}))}else t.removeAttribute("src");t.addEventListener("error",tv),t.addEventListener("error",tg),t.addEventListener("emptied",()=>{t.querySelectorAll("track[data-removeondestroy]").forEach(e=>{e.remove()})},{once:!0}),T(t,"pause",h),T(t,"seeked",h),T(t,"play",()=>{t.ended||e9(t.currentTime,t.duration)&&(t.currentTime=t.seekable.length?t.seekable.start(0):0)})}else i&&s?(i.once(o.Events.LEVEL_LOADED,(e,a)=>{eP(a.details,t,i),v(),eJ(t)!==b.LIVE||Number.isFinite(t.duration)||(i.on(o.Events.LEVEL_UPDATED,v),T(t,"durationchange",()=>{Number.isFinite(t.duration)&&i.off(o.Events.LEVELS_UPDATED,v)}))}),i.on(o.Events.ERROR,(a,r)=>{var n,s;let o=tf(r,e);if(o.muxCode===d.NETWORK_NOT_READY){let e=null!=(n=eH.get(t))?n:{},a=null!=(s=e.retryCount)?s:0;if(a<6){let n=0===a?5e3:6e4,s=new c(`Retrying in ${n/1e3} seconds...`,o.code,o.fatal);Object.assign(s,o),tE(t,s);let l=setTimeout(()=>{e.retryCount=a+1,"manifestLoadError"===r.details&&r.url&&i.loadSource(r.url)},n);t.addEventListener("teardown",()=>clearTimeout(l),{once:!0});return}{e.retryCount=0;let i=new c('Try again later or <a href="#" onclick="window.location.reload(); return false;" style="color: #4a90e2;">click here to retry</a>',o.code,o.fatal);Object.assign(i,o),tE(t,i);return}}tE(t,o)}),i.on(o.Events.MANIFEST_LOADED,()=>{let e=eH.get(t);e&&e.error&&(e.error=null,e.retryCount=0,t.dispatchEvent(new Event("emptied")),t.dispatchEvent(new Event("loadstart")))}),t.addEventListener("error",tg),T(t,"waiting",h),function(e,t){var i;if(!("videoTracks"in e))return;let a=new WeakMap;t.on(o.Events.MANIFEST_PARSED,function(t,i){d();let r=e.addVideoTrack("main");for(let[e,t]of(r.selected=!0,i.levels.entries())){let i=r.addRendition(t.url[0],t.width,t.height,t.videoCodec,t.bitrate);a.set(t,`${e}`),i.id=`${e}`}}),t.on(o.Events.AUDIO_TRACKS_UPDATED,function(t,i){for(let t of(l(),i.audioTracks)){let i=t.default?"main":"alternative",a=e.addAudioTrack(i,t.name,t.lang);a.id=`${t.id}`,t.default&&(a.enabled=!0)}});let r=()=>{var i;let a=+(null==(i=[...e.audioTracks].find(e=>e.enabled))?void 0:i.id),r=t.audioTracks.map(e=>e.id);a!=t.audioTrack&&r.includes(a)&&(t.audioTrack=a)};e.audioTracks.addEventListener("change",r),t.on(o.Events.LEVELS_UPDATED,function(t,i){var r;let n=e.videoTracks[null!=(r=e.videoTracks.selectedIndex)?r:0];if(!n)return;let s=i.levels.map(e=>a.get(e));for(let t of e.videoRenditions)t.id&&!s.includes(t.id)&&n.removeRendition(t)});let n=e=>{let i=e.target.selectedIndex;i!=t.nextLevel&&(t.nextLevel=i)};null==(i=e.videoRenditions)||i.addEventListener("change",n);let s=()=>{for(let t of e.videoTracks)e.removeVideoTrack(t)},l=()=>{for(let t of e.audioTracks)e.removeAudioTrack(t)},d=()=>{s(),l()};t.once(o.Events.DESTROYING,()=>{var t,i;d(),null==(t=e.audioTracks)||t.removeEventListener("change",r),null==(i=e.videoRenditions)||i.removeEventListener("change",n)})}(e,i),function(e,t){t.on(o.Events.NON_NATIVE_TEXT_TRACKS_FOUND,(i,{tracks:a})=>{a.forEach(i=>
4{var a,r;let n=null!=(a=i.subtitleTrack)?a:i.closedCaptions,s=t.subtitleTracks.findIndex(({lang:e,name:t,type:a})=>e==(null==n?void 0:n.lang)&&t===i.label&&a.toLowerCase()===i.kind),o=(null!=(r=i._id)?r:i.default)?"default":`${i.kind}${s}`;j(e,i.kind,i.label,null==n?void 0:n.lang,o,i.default)})});let i=()=>{if(!t.subtitleTracks.length)return;let i=Array.from(e.textTracks).find(e=>e.id&&"showing"===e.mode&&["subtitles","captions"].includes(e.kind));if(!i)return;let a=t.subtitleTracks[t.subtitleTrack],r=a?a.default?"default":`${t.subtitleTracks[t.subtitleTrack].type.toLowerCase()}${t.subtitleTrack}`:void 0;if(t.subtitleTrack<0||(null==i?void 0:i.id)!==r){let e=t.subtitleTracks.findIndex(({lang:e,name:t,type:a,default:r})=>"default"===i.id&&r||e==i.language&&t===i.label&&a.toLowerCase()===i.kind);t.subtitleTrack=e}(null==i?void 0:i.id)===r&&i.cues&&Array.from(i.cues).forEach(e=>{i.addCue(e)})};e.textTracks.addEventListener("change",i),t.on(o.Events.CUES_PARSED,(t,{track:i,cues:a})=>{let r=e.textTracks.getTrackById(i);if(!r)return;let n="disabled"===r.mode;n&&(r.mode="hidden"),a.forEach(e=>{var t;null!=(t=r.cues)&&t.getCueById(e.id)||r.addCue(e)}),n&&(r.mode="disabled")}),t.once(o.Events.DESTROYING,()=>{e.textTracks.removeEventListener("change",i),e.querySelectorAll("track[data-removeondestroy]").forEach(e=>{e.remove()})});let a=()=>
4{Array.from(e.textTracks).forEach(t=>{var i,a;if(!["subtitles","caption"].includes(t.kind)&&("thumbnails"===t.label||"chapters"===t.kind)){if(!(null!=(i=t.cues)&&i.length)){let i="track";t.kind&&(i+=`[kind="${t.kind}"]`),t.label&&(i+=`[label="${t.label}"]`);let r=e.querySelector(i),n=null!=(a=null==r?void 0:r.getAttribute("src"))?a:"";null==r||r.removeAttribute("src"),setTimeout(()=>{null==r||r.setAttribute("src",n)},0)}"hidden"!==t.mode&&(t.mode="hidden")}})};t.once(o.Events.MANIFEST_LOADED,a),t.once(o.Events.MEDIA_ATTACHED,a)}(t,i),i.attachMedia(t)):console.error("It looks like the video you're trying to play will not work on this system! If possible, try upgrading to the newest versions of your browser or software.")};function tb(e){var t;let i=e.target,a=null==(t=eH.get(i))?void 0:t.startTime;if(a&&function(e,t,i){t&&i>t&&(i=t);for(let t=0;t<e.length;t++)if(e.start(t)<=i&&e.end(t)>=i)return!0;return!1}(i.seekable,i.duration,a)){let e="auto"===i.preload;e&&(i.preload="none"),i.currentTime=a,e&&(i.preload="auto")}}async function tv(e){if(!e.isTrusted)return;e.stopImmediatePropagation();let t=e.target;if(!(null!=t&&t.error))return;let{message:i,code:a}=t.error,r=new c(i,a);if(t.src&&a===c.MEDIA_ERR_SRC_NOT_SUPPORTED&&t.readyState===HTMLMediaElement.HAVE_NOTHING){setTimeout(()=>{var e;let i=null!=(e=eX(t))?e:t.error;(null==i?void 0:i.code)===c.MEDIA_ERR_SRC_NOT_SUPPORTED&&tE(t,r)},500);return}if(t.src&&(a!==c.MEDIA_ERR_DECODE||void 0!==a))try{let{status:e}=await fetch(t.src);r.data={response:{code:e}}}catch{}tE(t,r)}function tE(e,t){var i;t.fatal&&((null!=(i=eH.get(e))?i:{}).error=t,e.dispatchEvent(new CustomEvent("error",{detail:t})))}function tg(e){var t,i;if(!(e instanceof CustomEvent)||!(e.detail instanceof c))return;let a=e.target,r=e.detail;r&&r.fatal&&((null!=(t=eH.get(a))?t:{}).error=r,null==(i=a.mux)||i.emit("error",{player_error_code:r.code,player_error_message:r.message,player_error_context:r.context}))}var tf=(e,t)=>{var i,a,r;e.fatal?console.error("getErrorFromHlsErrorData()",e):t.debug&&console.warn("getErrorFromHlsErrorData() (non-fatal)",e);let n={[o.ErrorTypes.NETWORK_ERROR]:c.MEDIA_ERR_NETWORK,[o.ErrorTypes.MEDIA_ERROR]:c.MEDIA_ERR_DECODE,[o.ErrorTypes.KEY_SYSTEM_ERROR]:c.MEDIA_ERR_ENCRYPTED},s,u=[o.ErrorDetails.KEY_SYSTEM_LICENSE_REQUEST_FAILED,o.ErrorDetails.KEY_SYSTEM_SERVER_CERTIFICATE_REQUEST_FAILED].includes(e.details)?c.MEDIA_ERR_NETWORK:n[e.type];if(u===c.MEDIA_ERR_NETWORK&&e.response){let r=null!=(i=e.type===o.ErrorTypes.KEY_SYSTEM_ERROR?l.DRM:e.type===o.ErrorTypes.NETWORK_ERROR?l.VIDEO:void 0)?i:l.VIDEO;s=null!=(a=eh(e.response,r,t,e.fatal))?a:new c("",u,e.fatal)}else u===c.MEDIA_ERR_ENCRYPTED?e.details===o.ErrorDetails.KEY_SYSTEM_NO_CONFIGURED_LICENSE?((s=new c(W("Attempting to play DRM-protected content without providing a DRM token."),c.MEDIA_ERR_ENCRYPTED,e.fatal)).errorCategory=l.DRM,s.muxCode=d.ENCRYPTED_MISSING_TOKEN):e.details===o.ErrorDetails.KEY_SYSTEM_NO_ACCESS?((s=new c(W("Cannot play DRM-protected content with current security configuration on this browser. Try playing in another browser."),c.MEDIA_ERR_ENCRYPTED,e.fatal)).errorCategory=l.DRM,s.muxCode=d.ENCRYPTED_UNSUPPORTED_KEY_SYSTEM):e.details===o.ErrorDetails.KEY_SYSTEM_NO_SESSION?((s=new c(W("Failed to generate a DRM license request. This may be an issue with the player or your protected content."),c.MEDIA_ERR_ENCRYPTED,!0)).errorCategory=l.DRM,s.muxCode=d.ENCRYPTED_GENERATE_REQUEST_FAILED):e.details===o.ErrorDetails.KEY_SYSTEM_SESSION_UPDATE_FAILED?((s=new c(W("Failed to update DRM license. This may be an issue with the player or your protected content."),c.MEDIA_ERR_ENCRYPTED,e.fatal)).errorCategory=l.DRM,s.muxCode=d.ENCRYPTED_UPDATE_LICENSE_FAILED):e.details===o.ErrorDetails.KEY_SYSTEM_SERVER_CERTIFICATE_UPDATE_FAILED?((s=new c(W("Your server certificate failed when attempting to set it. This may be an issue with a no longer valid certificate."),c.MEDIA_ERR_ENCRYPTED,e.fatal)).errorCategory=l.DRM,s.muxCode=d.ENCRYPTED_UPDATE_SERVER_CERT_FAILED):e.details===o.ErrorDetails.KEY_SYSTEM_STATUS_INTERNAL_ERROR?((s=new c(W("The DRM Content Decryption Module system had an internal failure. Try reloading the page, upading your browser, or playing in another browser."),c.MEDIA_ERR_ENCRYPTED,e.fatal)).errorCategory=l.DRM,s.muxCode=d.ENCRYPTED_CDM_ER
4ROR):e.details===o.ErrorDetails.KEY_SYSTEM_STATUS_OUTPUT_RESTRICTED?((s=new c(W("DRM playback is being attempted in an environment that is not sufficiently secure. User may see black screen."),c.MEDIA_ERR_ENCRYPTED,!1)).errorCategory=l.DRM,s.muxCode=d.ENCRYPTED_OUTPUT_RESTRICTED):((s=new c(e.error.message,c.MEDIA_ERR_ENCRYPTED,e.fatal)).errorCategory=l.DRM,s.muxCode=d.ENCRYPTED_ERROR):s=new c("",u,e.fatal);return s.context||(s.context=`${e.url?`url: ${e.url} 5`:""}${e.response&&(e.response.code||e.response.text)?`response: ${e.response.code}, ${e.response.text} 6`:""}${e.reason?`failure reason: ${e.reason} 7`:""}${e.level?`level: ${e.level} 8`:""}${e.parent?`parent stream controller: ${e.parent} 9`:""}${e.buffer?`buffer length: ${e.buffer} 10`:""}${e.error?`error: ${e.error} 11`:""}${e.event?`event: ${e.event} 12`:""}${e.err?`error message: ${null==(r=e.err)?void 0:r.message} 13`:""}`),s.data=e,s};let tA=["abort","canplay","canplaythrough","durationchange","emptied","encrypted","ended","error","loadeddata","loadedmetadata","loadstart","pause","play","playing","progress","ratechange","seeked","seeking","stalled","suspend","timeupdate","volumechange","waiting","waitingforkey","resize","enterpictureinpicture","leavepictureinpicture","webkitbeginfullscreen","webkitendfullscreen","webkitpresentationmodechanged"],ty=["autopictureinpicture","disablepictureinpicture","disableremoteplayback","autoplay","controls","controlslist","crossorigin","loop","muted","playsinline","poster","preload","src"];function tT(e){return` 14 <style> 15 :host { 16 display: inline-flex; 17 line-height: 0; 18 flex-direction: column; 19 justify-content: end; 20 } 21 22 audio { 23 width: 100%; 24 } 25 </style> 26 <slot name="media"> 27 <audio${tI(e)}></audio> 28 </slot> 29 <slot></slot> 30 `}function tk(e){return` 31 <style> 32 :host { 33 display: inline-block; 34 line-height: 0; 35 } 36 37 video { 38 max-width: 100%; 39 max-height: 100%; 40 min-width: 100%; 41 min-height: 100%; 42 object-fit: var(--media-object-fit, contain); 43 object-position: var(--media-object-position, 50% 50%); 44 } 45 46 video::-webkit-media-text-track-container { 47 transform: var(--media-webkit-text-track-transform); 48 transition: var(--media-webkit-text-track-transition); 49 } 50 </style> 51 <slot name="media"> 52 <video${tI(e)}></video> 53 </slot> 54 <slot></slot> 55 `}function tM(e,{tag:t,is:i}){let a=globalThis.document?.createElement?.(t,{is:i}),r=a?function(e){let t=[];for(let i=Object.getPrototypeOf(e);i&&i!==HTMLElement.prototype;i=Object.getPrototypeOf(i)){let e=Object.getOwnPropertyNames(i);t.push(...e)}return t}(a):[];return class n extends e{static getTemplateHTML=t.endsWith("audio")?tT:tk;static shadowRootOptions={mode:"open"};static Events=tA;static #e=!1;static get observedAttributes(){return n.#t(),[...a?.constructor?.observedAttributes??[],...ty]}static #t(){if(this.#e)return;this.#e=!0;let e=new Set(this.observedAttributes);for(let t of(e.delete("muted"),r))if(!(t in this.prototype)){if("function"==typeof a[t])this.prototype[t]=function(...e){return this.#i(),(()=>{if(this.call)return this.call(t,...e);let i=this.nativeEl?.[t];return i?.apply(this.nativeEl,e)})()};else{let i={get(){this.#i();let i=t.toLowerCase();if(e.has(i)){let e=this.getAttribute(i);return null!==e&&(""===e||e)}return this.get?.(t)??this.nativeEl?.[t]}};t!==t.toUpperCase()&&(i.set=function(i){this.#i();let a=t.toLowerCase();if(e.has(a)){!0===i||!1===i||null==i?this.toggleAttribute(a,!!i):this.setAttribute(a,i);return}if(this.set){this.set(t,i);return}this.nativeEl&&(this.nativeEl[t]=i)}),Object.defineProperty(this.prototype,t,i)}}}#a=!1;#r=null;#n=new Map;#s;#o;get;set;call;get nativeEl(){return this.#i(),this.#r??this.querySelector(":scope > [slot=media]")??this.querySelector(t)??this.shadowRoot?.querySelector(t)??null}set nativeEl(e){this.#r=e}get defaultMuted(){return this.hasAttribute("muted")}set defaultMuted(e){this.toggleAttribute("muted",e)}get src(){return this.getAttribute("src")}set src(e){this.setAttribute("src",`${e}`)}get preload(){return this.getAttribute("preload")??this.nativeEl?.preload}set preload(e){this.setAttribute("preload",`${e}`)}#i(){this.#a||(this.#a=!0,this.init())}init(){if(!this.shadowRoot){this.attachShadow({mode:"open"});let e=function(e){let t={};for(let i of e)t[i.name]=i.value;return t}(this.attributes);i&&(e.is=i),t&&(e.part=t),this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}for(let e of(this.nativeEl.muted=this.hasAttribute("muted"),r))this.#l(e);this.#d()}#d(){for(let e of(this.#s=new MutationObserver(this.#u.bind(this)),this.#o=()=>this.#c(),this.shadowRoot?.addEventListener("slotchange",this.#o),this.#c(),this.constructor.Events))this.shadowRoot?.addEventListener(e,this,!0)}handleEvent(e){e.target===this.nativeEl&&this.dispatchEvent(new CustomEvent(e.type,{detail:e.detail}))}#c(){let e=new Map(this.#n),t=this.shadowRoot?.querySelector("slot:not([name])");(t?.assignedElements({flatten:!0}).filter(e=>
55["track","source"].includes(e.localName))).forEach(t=>{e.delete(t);let i=this.#n.get(t);i||(i=t.cloneNode(),this.#n.set(t,i),this.#s?.observe(t,{attributes:!0})),this.nativeEl?.append(i),this.#h(i)}),e.forEach((e,t)=>{e.remove(),this.#n.delete(t)})}#u(e){for(let t of e)if("attributes"===t.type){let{target:e,attributeName:i}=t,a=this.#n.get(e);a&&i&&(a.setAttribute(i,e.getAttribute(i)??""),this.#h(a))}}#h(e){e&&"track"===e.localName&&e.default&&("chapters"===e.kind||"metadata"===e.kind)&&"disabled"===e.track.mode&&(e.track.mode="hidden")}#l(e){if(Object.prototype.hasOwnProperty.call(this,e)){let t=this[e];delete this[e],this[e]=t}}attributeChangedCallback(e,t,i){this.#i(),this.#m(e,t,i)}#m(e,t,i){["id","class"].includes(e)||!n.observedAttributes.includes(e)&&this.constructor.observedAttributes.includes(e)||(null===i?this.nativeEl?.removeAttribute(e):this.nativeEl?.getAttribute(e)!==i&&this.nativeEl?.setAttribute(e,i))}connectedCallback(){this.#i(),this.#o||this.#d()}disconnectedCallback(){for(let e of(this.#s?.disconnect(),this.#s=void 0,this.#o&&(this.shadowRoot?.removeEventListener("slotchange",this.#o),this.#o=void 0),this.constructor.Events))this.shadowRoot?.removeEventListener(e,this,!0);this.#n.forEach(e=>e.remove()),this.#n.clear(),this.#r=null}}}function tI(e){let t="";for(let i in e){if(!ty.includes(i))continue;let a=e[i];""===a?t+=` ${i}`:t+=` ${i}="${a}"`}return t}let t_=tM(globalThis.HTMLElement??class{},{tag:"video"});tM(globalThis.HTMLElement??class{},{tag:"audio"});var tw,tC,tR,tS,tL,tD,tx,tN,tO,tP,tU,tW,t$,tB,tH=e=>{throw TypeError(e)},tV=(e,t,i)=>t.has(e)||tH("Cannot "+i),tK=(e,t,i)=>(tV(e,t,"read from private field"),i?i.call(e):t.get(e)),tF=(e,t,i)=>t.has(e)?tH("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,i),tY=(e,t,i,a)=>(tV(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),tq=(e,t,i)=>(tV(e,t,"access private method"),i),tG=(()=>{try{return"0.31.0"}catch{}return"UNKNOWN"})(),tj=` 56<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" part="logo" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2" viewBox="0 0 1600 500"><g fill="#fff"><path d="M994.287 93.486c-17.121 0-31-13.879-31-31 0-17.121 13.879-31 31-31 17.121 0 31 13.879 31 31 0 17.121-13.879 31-31 31m0-93.486c-34.509 0-62.484 27.976-62.484 62.486v187.511c0 68.943-56.09 125.033-125.032 125.033s-125.03-56.09-125.03-125.033V62.486C681.741 27.976 653.765 0 619.256 0s-62.484 27.976-62.484 62.486v187.511C556.772 387.85 668.921 500 806.771 500c137.851 0 250.001-112.15 250.001-250.003V62.486c0-34.51-27.976-62.486-62.485-62.486M1537.51 468.511c-17.121 0-31-13.879-31-31 0-17.121 13.879-31 31-31 17.121 0 31 13.879 31 31 0 17.121-13.879 31-31 31m-275.883-218.509-143.33 143.329c-24.402 24.402-24.402 63.966 0 88.368 24.402 24.402 63.967 24.402 88.369 0l143.33-143.329 143.328 143.329c24.402 24.4 63.967 24.402 88.369 0 24.403-24.402 24.403-63.966.001-88.368l-143.33-143.329.001-.004 143.329-143.329c24.402-24.402 24.402-63.965 0-88.367s-63.967-24.402-88.369 0L1349.996 161.63 1206.667 18.302c-24.402-24.401-63.967-24.402-88.369 0s-24.402 63.965 0 88.367l143.329 143.329v.004ZM437.511 468.521c-17.121 0-31-13.879-31-31 0-17.121 13.879-31 31-31 17.121 0 31 13.879 31 31 0 17.121-13.879 31-31 31M461.426 4.759C438.078-4.913 411.2.432 393.33 18.303L249.999 161.632 106.669 18.303C88.798.432 61.922-4.913 38.573 4.759 15.224 14.43-.001 37.214-.001 62.488v375.026c0 34.51 27.977 62.486 62.487 62.486 34.51 0 62.486-27.976 62.486-62.486V213.341l80.843 80.844c24.404 24.402 63.965 24.402 88.369 0l80.843-80.844v224.173c0 34.51 27.976 62.486 62.486 62.486s62.486-27.976 62.486-62.486V62.488c0-25.274-15.224-48.058-38.573-57.729" style="fill-rule:nonzero"/></g></svg>`,tZ={BEACON_COLLECTION_DOMAIN:"beacon-collection-domain",CUSTOM_DOMAIN:"custom-domain",DEBUG:"debug",DISABLE_TRACKING:"disable-tracking",DISABLE_COOKIES:"disable-cookies",DISABLE_PSEUDO_ENDED:"disable-pseudo-ended",DRM_TOKEN:"drm-token",PLAYBACK_TOKEN:"playback-token",ENV_KEY:"env-key",MAX_RESOLUTION:"max-resolution",MIN_RESOLUTION:"min-resolution",MAX_AUTO_RESOLUTION:"max-auto-resolution",RENDITION_ORDER:"rendition-order",PROGRAM_START_TIME:"program-start-time",PROGRAM_END_TIME:"program-end-time",ASSET_START_TIME:"asset-start-time",ASSET_END_TIME:"asset-end-time",METADATA_URL:"metadata-url",PLAYBACK_ID:"playback-id",PLAYER_SOFTWARE_NAME:"player-software-name",PLAYER_SOFTWARE_VERSION:"player-software-version",PLAYER_INIT_TIME:"player-init-time",PREFER_CMCD:"prefer-cmcd",PREFER_PLAYBACK:"prefer-playback",START_TIME:"start-time",STREAM_TYPE:"stream-type",TARGET_LIVE_WINDOW:"target-live-window",LIVE_EDGE_OFFSET:"live-edge-offset",TYPE:"type",LOGO:"logo",CAP_RENDITION_TO_PLAYER_SIZE:"cap-rendition-to-player-size",INITIAL_BANDWIDTH_ESTIMATE_KBPS:"initial-bandwidth-estimate-kbps",INITIAL_ESTIMATE_SEGMENTS:"initial-estimate-segments",MIN_PRELOAD_SEGMENTS:"min-preload-segments"}
56,tz=Object.values(tZ),tX="mux-video",tQ=class extends t_{constructor(){super(),tF(this,tU),tF(this,tw),tF(this,tC),tF(this,tR,{}),tF(this,tS,{}),tF(this,tL),tF(this,tD),tF(this,tx),tF(this,tN),tF(this,tO,""),tF(this,tP,e=>{var t;let i=eQ(this.nativeEl),a=null!=(t=this.metadata)?t:{};this.metadata={...i,...a},(null==i?void 0:i["com.mux.video.branding"])==="mux-free-plan"&&(tY(this,tO,"default"),this.updateLogo())}),tF(this,t$),tY(this,tC,eY())}static get NAME(){return tX}static get VERSION(){return tG}static get observedAttributes(){var e;return[...tz,...null!=(e=t_.observedAttributes)?e:[]]}static getLogoHTML(e){return e&&"false"!==e?"default"===e?tj:`<img part="logo" src="${e}" />`:""}static getTemplateHTML(e={}){var t;return` 57 ${t_.getTemplateHTML(e)} 58 <style> 59 :host { 60 position: relative; 61 } 62 slot[name="logo"] { 63 display: flex; 64 justify-content: end; 65 position: absolute; 66 top: 1rem; 67 right: 1rem; 68 opacity: 0; 69 transition: opacity 0.25s ease-in-out; 70 z-index: 1; 71 } 72 slot[name="logo"]:has([part="logo"]) { 73 opacity: 1; 74 } 75 slot[name="logo"] [part="logo"] { 76 width: 5rem; 77 pointer-events: none; 78 user-select: none; 79 } 80 </style> 81 <slot name="logo"> 82 ${this.getLogoHTML(null!=(t=e[tZ.LOGO])?t:"")} 83 </slot> 84 `}get preferCmcd(){var e;return null!=(e=this.getAttribute(tZ.PREFER_CMCD))?e:void 0}set preferCmcd(e){e!==this.preferCmcd&&(e?g.includes(e)?this.setAttribute(tZ.PREFER_CMCD,e):console.warn(`Invalid value for preferCmcd. Must be one of ${g.join()}`):this.removeAttribute(tZ.PREFER_CMCD))}get playerInitTime(){return this.hasAttribute(tZ.PLAYER_INIT_TIME)?+this.getAttribute(tZ.PLAYER_INIT_TIME):tK(this,tC)}set playerInitTime(e){e!=this.playerInitTime&&(null==e?this.removeAttribute(tZ.PLAYER_INIT_TIME):this.setAttribute(tZ.PLAYER_INIT_TIME,`${+e}`))}get playerSoftwareName(){var e;return null!=(e=tK(this,tx))?e:tX}set playerSoftwareName(e){tY(this,tx,e)}get playerSoftwareVersion(){var e;return null!=(e=tK(this,tD))?e:tG}set playerSoftwareVersion(e){tY(this,tD,e)}get _hls(){var e;return null==(e=tK(this,tU,tW))?void 0:e.engine}get mux(){var e;return null==(e=this.nativeEl)?void 0:e.mux}get error(){var e;return null!=(e=eX(this.nativeEl))?e:null}get errorTranslator(){return tK(this,tN)}set errorTranslator(e){tY(this,tN,e)}get src(){return this.getAttribute("src")}set src(e){e!==this.src&&(null==e?this.removeAttribute("src"):this.setAttribute("src",e))}get type(){var e;return null!=(e=this.getAttribute(tZ.TYPE))?e:void 0}set type(e){e!==this.type&&(e?this.setAttribute(tZ.TYPE,e):this.removeAttribute(tZ.TYPE))}get preload(){let e=this.getAttribute("preload");return""===e?"auto":["none","metadata","auto"].includes(e)?e:super.preload}set preload(e){e!=this.getAttribute("preload")&&(["","none","metadata","auto"].includes(e)?this.setAttribute("preload",e):this.removeAttribute("preload"))}get debug(){return null!=this.getAttribute(tZ.DEBUG)}set debug(e){e!==this.debug&&(e?this.setAttribute(tZ.DEBUG,""):this.removeAttribute(tZ.DEBUG))}get disableTracking(){return this.hasAttribute(tZ.DISABLE_TRACKING)}set disableTracking(e){e!==this.disableTracking&&this.toggleAttribute(tZ.DISABLE_TRACKING,!!e)}get disableCookies(){return this.hasAttribute(tZ.DISABLE_COOKIES)}set disableCookies(e){e!==this.disableCookies&&(e?this.setAttribute(tZ.DISABLE_COOKIES,""):this.removeAttribute(tZ.DISABLE_COOKIES))}get disablePseudoEnded(){return this.hasAttribute(tZ.DISABLE_PSEUDO_ENDED)}set disablePseudoEnded(e){e!==this.disablePseudoEnded&&(e?this.setAttribute(tZ.DISABLE_PSEUDO_ENDED,""):this.removeAttribute(tZ.DISABLE_PSEUDO_ENDED))}get startTime(){let e=this.getAttribute(tZ.START_TIME);if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}set startTime(e){e!==this.startTime&&(null==e?this.removeAttribute(tZ.START_TIME):this.setAttribute(tZ.START_TIME,`${e}`))}get initialBandwidthEstimateKbps(){let e=this.getAttribute(tZ.INITIAL_BANDWIDTH_ESTIMATE_KBPS);if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}set initialBandwidthEstimateKbps(e){e!==this.initialBandwidthEstimateKbps&&(null==e?this.removeAttribute(tZ.INITIAL_BANDWIDTH_ESTIMATE_KBPS):this.setAttribute(tZ.INITIAL_BANDWIDTH_ESTIMATE_KBPS,`${e}`))}get initialEstimateSegments(){let e=this.getAttribute(tZ.INITIAL_ESTIMATE_SEGMENTS);if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}set initialEstimateSegments(e){e!==this.initialEstimateSegments&&(null==e?this.removeAttribute(tZ.INITIAL_ESTIMATE_SEGMENTS):this.setAttribute(tZ.INITIAL_ESTIMATE_SEGMENTS,`${e}`))}get minPreloadSegments(){let e=this.getAttribute(tZ.MIN_PRELOAD_SEGMENTS);if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}set minPreloadSegments(e){e!==this.minPreloadSegments&&(null==e?this.removeAttribute(tZ.MIN_PRELOAD_SEGMENTS):this.setAttribute(tZ.MIN_PRELOAD_SEGMENTS,`${e}`))}get playbackId(){var e;return this.hasAttribute(tZ.PLAYBACK_ID)?this.getAttribute(tZ.PLAYBACK_ID):null!=(e=eZ(this.src))?e:void 0}set playbackId(e){e!==this.playbackId&&(e?this.setAttribute(tZ.PLAYBACK_ID,e):this.removeAttribute(tZ.PLAYBACK_ID))}get maxResolution(){var e;return null!=(e=this.getAttribute(tZ.MAX_RESOLUTION))?e:void 0}set maxResolution(e){e!==this.maxResolution&&(e?this.setAttribute(tZ.MAX_RESOLUTION,e):this.removeAttribute(tZ.MAX_RESOLUTION))}get minResolution(){var e;return null!=(e=this.getAttribute(tZ.MIN_RESOLUTION))?e:void 0}set minResolution(e){e!==this.minResolution&&(e?this.setAttribute(tZ.MIN_RESOLUTION,e):this.removeAttribute(tZ.MIN_RESOLUTION))}get maxAutoResolution(){var e;return null!=(e=this.getAttribute(tZ.MAX_AUTO_RESOLUTION))?e:void 0}set maxAutoResolution(e){null==e?this.removeAttribute(tZ.MAX_AUTO_RESOLUTION):this.setAttribute(tZ.MAX_AUTO_RESOLUTION,e)}get renditionOrder(){var e;return null!=(e=this.getAttribute(tZ.RENDITION_ORDER))?e:void 0}set renditionOrder(e){e!==this.renditionOrder&&(e?this.setAttribute(tZ.RENDITION_ORDER,e):this.removeAttribute(tZ.RENDITION_ORDER))}get programStartTime(){let e=this.getAttribute(tZ.PROGRAM_START_TIME);if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}set programStartTime(e){null==e?this.removeAttribute(tZ.PROGRAM_START_TIME):this.setAttribute(tZ.PROGRAM_START_TIME,`${e}`)}get programEndTime(){let e=this.getAttribute(tZ.PROGRAM_END_TIME);if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}set programEndTime(e){null==e?this.removeAttribute(tZ.PROGRAM_END_TIME):this.setAttribute(tZ.PROGRAM_END_TIME,`${e}`)}get assetStartTime(){let e=this.getAttribute(tZ.ASSET_START_TIME);if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}set assetStartTime(e){null==e?this.removeAttribute(tZ.ASSET_START_TIME):this.setAttribute(tZ.ASSET_START_TIME,`${e}`)}get assetEndTime(){let e=this.getAttribute(tZ.ASSET_END_TIME);if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}set assetEndTime(e){null==e?this.removeAttribute(tZ.ASSET_END_TIME):this.setAttribute(tZ.ASSET_END_TIME,`${e}`)}get customDomain(){var e;return null!=(e=this.getAttribute(tZ.CUSTOM_DOMAIN))?e:void 0}set customDomain(e){e!==this.customDomain&&(e?this.setAttribute(tZ.CUSTOM_DOMAIN,e):this.removeAttribute(tZ.CUSTOM_DOMAIN))}get capRenditionToPlayerSize(){var e;return(null==(e=this._hlsConfig)?void 0:e.capLevelToPlayerSize)!=null?this._hlsConfig.capLevelToPlayerSize:tK(this,t$)}set capRenditionToPlayerSize(e){tY(this,t$,e)}get drmToken(){var e;return null!=(e=this.getAttribute(tZ.DRM_TOKEN))?e:void 0}
84set drmToken(e){e!==this.drmToken&&(e?this.setAttribute(tZ.DRM_TOKEN,e):this.removeAttribute(tZ.DRM_TOKEN))}get playbackToken(){var e,t,i,a;if(this.hasAttribute(tZ.PLAYBACK_TOKEN))return null!=(e=this.getAttribute(tZ.PLAYBACK_TOKEN))?e:void 0;if(this.hasAttribute(tZ.PLAYBACK_ID)){let[,e]=k(null!=(t=this.playbackId)?t:"");return null!=(i=new URLSearchParams(e).get("token"))?i:void 0}if(this.src)return null!=(a=new URLSearchParams(this.src).get("token"))?a:void 0}set playbackToken(e){e!==this.playbackToken&&(e?this.setAttribute(tZ.PLAYBACK_TOKEN,e):this.removeAttribute(tZ.PLAYBACK_TOKEN))}get tokens(){let e=this.getAttribute(tZ.PLAYBACK_TOKEN),t=this.getAttribute(tZ.DRM_TOKEN);return{...tK(this,tS),...null!=e?{playback:e}:{},...null!=t?{drm:t}:{}}}set tokens(e){tY(this,tS,null!=e?e:{})}get ended(){return e7(this.nativeEl,this._hls)}get envKey(){var e;return null!=(e=this.getAttribute(tZ.ENV_KEY))?e:void 0}set envKey(e){e!==this.envKey&&(e?this.setAttribute(tZ.ENV_KEY,e):this.removeAttribute(tZ.ENV_KEY))}get beaconCollectionDomain(){var e;return null!=(e=this.getAttribute(tZ.BEACON_COLLECTION_DOMAIN))?e:void 0}set beaconCollectionDomain(e){e!==this.beaconCollectionDomain&&(e?this.setAttribute(tZ.BEACON_COLLECTION_DOMAIN,e):this.removeAttribute(tZ.BEACON_COLLECTION_DOMAIN))}get streamType(){var e;return null!=(e=this.getAttribute(tZ.STREAM_TYPE))?e:eJ(this.nativeEl)}set streamType(e){e!==this.streamType&&(e?this.setAttribute(tZ.STREAM_TYPE,e):this.removeAttribute(tZ.STREAM_TYPE))}get targetLiveWindow(){return this.hasAttribute(tZ.TARGET_LIVE_WINDOW)?+this.getAttribute(tZ.TARGET_LIVE_WINDOW):e0(this.nativeEl)}set targetLiveWindow(e){e!=this.targetLiveWindow&&(null==e?this.removeAttribute(tZ.TARGET_LIVE_WINDOW):this.setAttribute(tZ.TARGET_LIVE_WINDOW,`${+e}`))}get liveEdgeStart(){var e,t;if(this.hasAttribute(tZ.LIVE_EDGE_OFFSET)){let{liveEdgeOffset:i}=this,a=null!=(e=this.nativeEl.seekable.end(0))?e:0;return Math.max(null!=(t=this.nativeEl.seekable.start(0))?t:0,a-i)}return e2(this.nativeEl)}get liveEdgeOffset(){if(this.hasAttribute(tZ.LIVE_EDGE_OFFSET))return+this.getAttribute(tZ.LIVE_EDGE_OFFSET)}set liveEdgeOffset(e){e!=this.liveEdgeOffset&&(null==e?this.removeAttribute(tZ.LIVE_EDGE_OFFSET):this.setAttribute(tZ.LIVE_EDGE_OFFSET,`${+e}`))}get seekable(){return e1(this.nativeEl)}async addCuePoints(e){return J(this.nativeEl,e)}get activeCuePoint(){return et(this.nativeEl)}get cuePoints(){return function(e,t={label:X}){let i=Z(e,t.label,"metadata");return null!=i&&i.cues?Array.from(i.cues,e=>ee(e)):[]}(this.nativeEl)}async addChapters(e){return es(this.nativeEl,e)}get activeChapter(){return eo(this.nativeEl)}get chapters(){return function(e,t={label:ea}){var i;let a=Z(e,t.label,"chapters");return null!=(i=null==a?void 0:a.cues)&&i.length?Array.from(a.cues,e=>en(e)):[]}(this.nativeEl)}getStartDate(){return function(e,t){if(t){let i=t.playingDate;if(null!=i)return new Date(i.getTime()-1e3*e.currentTime)}return"function"==typeof e.getStartDate?e.getStartDate():new Date(NaN)}(this.nativeEl,this._hls)}get currentPdt(){var e,t;return e=this.nativeEl,(t=this._hls)&&t.playingDate?t.playingDate:new Date("function"==typeof e.getStartDate?e.getStartDate().getTime()+1e3*e.currentTime:NaN)}get preferPlayback(){let e=this.getAttribute(tZ.PREFER_PLAYBACK);if(e===v.MSE||e===v.NATIVE)return e}set preferPlayback(e){e!==this.preferPlayback&&(e===v.MSE||e===v.NATIVE?this.setAttribute(tZ.PREFER_PLAYBACK,e):this.removeAttribute(tZ.PREFER_PLAYBACK))}get metadata(){return{...this.getAttributeNames().filter(e=>e.startsWith("metadata-")&&![tZ.METADATA_URL].includes(e)).reduce((e,t)=>{let i=this.getAttribute(t);return null!=i&&(e[t.replace(/^metadata-/,"").replace(/-/g,"_")]=i),e},{}),...tK(this,tR)}}set metadata(e){tY(this,tR,null!=e?e:{}),this.mux&&this.mux.emit("hb",tK(this,tR))}get _hlsConfig(){return tK(this,tL)}set _hlsConfig(e){tY(this,tL,e)}get logo(){var e;return null!=(e=this.getAttribute(tZ.LOGO))?e:tK(this,tO)}set logo(e){e?this.setAttribute(tZ.LOGO,e):this.removeAttribute(tZ.LOGO)}load(){te(this,this.nativeEl,tK(this,tU,tW))}unload(){tt(this.nativeEl,tK(this,tU,tW),this)}attributeChangedCallback(e,t,i){var a,r;
84switch(t_.observedAttributes.includes(e)&&!["src","autoplay","preload"].includes(e)&&super.attributeChangedCallback(e,t,i),e){case tZ.PLAYER_SOFTWARE_NAME:this.playerSoftwareName=null!=i?i:void 0;break;case tZ.PLAYER_SOFTWARE_VERSION:this.playerSoftwareVersion=null!=i?i:void 0;break;case"src":{let e=!!t,a=!!i;!e&&a?tq(this,tU,tB).call(this):e&&!a?this.unload():e&&a&&(this.unload(),tq(this,tU,tB).call(this));break}case"autoplay":if(i===t)break;null==(a=tK(this,tU,tW))||a.setAutoplay(this.autoplay);break;case"preload":if(i===t)break;null==(r=tK(this,tU,tW))||r.setPreload(i);break;case tZ.PLAYBACK_ID:case tZ.CUSTOM_DOMAIN:case tZ.MAX_RESOLUTION:case tZ.MIN_RESOLUTION:case tZ.RENDITION_ORDER:case tZ.PROGRAM_START_TIME:case tZ.PROGRAM_END_TIME:case tZ.ASSET_START_TIME:case tZ.ASSET_END_TIME:case tZ.PLAYBACK_TOKEN:this.src=eG(this);break;case tZ.DEBUG:{let e=this.debug;this.mux&&console.info("Cannot toggle debug mode of mux data after initialization. Make sure you set all metadata to override before setting the src."),this._hls&&(this._hls.config.debug=e);break}case tZ.METADATA_URL:i&&fetch(i).then(e=>e.json()).then(e=>this.metadata=e).catch(()=>console.error(`Unable to load or parse metadata JSON from metadata-url ${i}!`));break;case tZ.STREAM_TYPE:(null==i||i!==t)&&this.dispatchEvent(new CustomEvent("streamtypechange",{composed:!0,bubbles:!0}));break;case tZ.TARGET_LIVE_WINDOW:(null==i||i!==t)&&this.dispatchEvent(new CustomEvent("targetlivewindowchange",{composed:!0,bubbles:!0,detail:this.targetLiveWindow}));break;case tZ.LOGO:(null==i||i!==t)&&this.updateLogo();break;case tZ.DISABLE_TRACKING:if(null==i||i!==t){let e=this.currentTime,t=this.paused;this.unload(),tq(this,tU,tB).call(this).then(()=>{this.currentTime=e,t||this.play()})}break;case tZ.DISABLE_COOKIES:(null==i||i!==t)&&this.disableCookies&&document.cookie.split(";").forEach(e=>{e.trim().startsWith("muxData")&&(document.cookie=e.replace(/^ +/,"").replace(/=.*/,"=;expires="+new Date().toUTCString()+";path=/"))});break;case tZ.CAP_RENDITION_TO_PLAYER_SIZE:(null==i||i!==t)&&(this.capRenditionToPlayerSize=null!=i||void 0)}}updateLogo(){if(!this.shadowRoot)return;let e=this.shadowRoot.querySelector('slot[name="logo"]');if(!e)return;let t=this.constructor.getLogoHTML(tK(this,tO)||this.logo);e.innerHTML=t}connectedCallback(){var e,t;null==(e=super.connectedCallback)||e.call(this),null==(t=this.nativeEl)||t.addEventListener("muxmetadata",tK(this,tP)),this.nativeEl&&this.src&&!tK(this,tU,tW)&&tq(this,tU,tB).call(this)}disconnectedCallback(){var e,t;null==(e=this.nativeEl)||e.removeEventListener("muxmetadata",tK(this,tP)),this.unload(),null==(t=super.disconnectedCallback)||t.call(this)}handleEvent(e){e.target===this.nativeEl&&this.dispatchEvent(new CustomEvent(e.type,{composed:!0,detail:e.detail}))}};tw=new WeakMap,tC=new WeakMap,tR=new WeakMap,tS=new WeakMap,tL=new WeakMap,tD=new WeakMap,tx=new WeakMap,tN=new WeakMap,tO=new WeakMap,tP=new WeakMap,tU=new WeakSet,tW=function(){return e3(this.nativeEl)},t$=new WeakMap,tB=async function(){tK(this,tw)||(await tY(this,tw,Promise.resolve()),tY(this,tw,null),this.load())};let tJ=new WeakMap;class t0 extends Error{}class t1 extends Error{}let t2=["application/x-mpegURL","application/vnd.apple.mpegurl","audio/mpegurl"];function t3(){return globalThis.cast?.framework?.CastContext.getInstance()}function t4(){return t3()?.getCurrentSession()}function t5(){return t4()?.getSessionObj().media[0]}function t9(e){return t3().setOptions({...t8(),...e})}function t8(){return{receiverApplicationId:"CC1AD845",autoJoinPolicy:"origin_scoped",androidReceiverCompatible:!1,language:"en-US",resumeSavedSession:!0}}function t6(e){if(!e)return;let t=e.match(/\.([a-zA-Z0-9]+)(?:\?.*)?$/);return t?t[1]:null}function t7(e){let t=e.split("\n").find(e=>!e.trim().startsWith("#")&&""!==e.trim());return t?.trim()}async function ie(e){if(!e)return!1;if(/\.m3u8?(\?.*)?$/i.test(e))return!0;if(e.startsWith("blob:"))return!1;try{let t=(await fetch(e,{method:"HEAD"})).headers.get("Content-Type");return t2.some(e=>t===e)}catch(e){return console.error("Error while trying to get the Content-Type of the manifest",e),!1}}async function it(e){if(!e||e.startsWith("blob:"))return{videoFormat:void 0,audioFormat:void 0};try{let t=await (await fetch(e)).text(),i=t,a=function(e){let t=e.split("\n"),i=[];for(let e=0;e<t.length;e++)if(t[e].trim().startsWith("#EXT-X-STREAM-INF")){let a=t[e+1]?t[e+1].trim():"";a&&!a.startsWith("#")&&i.push(a)}return i}(t);if(a.length>0){let t=new URL(a[0],e).toString();i=await (await fetch(t)).text()}let r=t7(i),n=t6(r),s=function(e){for(let t of e.split("\n")){let e=t.trim();if(e.startsWith("#EXT-X-MEDIA")&&/TYPE=AUDIO/i.test(e)){let t=e.match(/URI="([^"]+)"/i);if(t)return t[1]}}}(t),o=n;if(s)try{let t=new URL(s,e).toString(),i=await (await fetch(t)).text(),a=t7(i);o=t6(a)??n}catch(e){console.error("Error while trying to parse the audio rendition playlist",e)}return{videoFormat:n,audioFormat:o}}catch(e){return console.error("Error while trying to parse the manifest playlist",e),{videoFormat:void 0,audioFormat:void 0}}}let ii=new(globalThis.WeakRef?class extends Set{add(e){super.add(new WeakRef(e))}forEach(e){super.forEach(t=>{let i=t.deref();i&&e(i)})}}:Set),ia=new WeakSet;iU=()=>
84{if(!globalThis.chrome?.cast?.isAvailable){console.debug("chrome.cast.isAvailable",globalThis.chrome?.cast?.isAvailable);return}a||(a=cast.framework,t3().addEventListener(a.CastContextEventType.CAST_STATE_CHANGED,e=>{ii.forEach(t=>tJ.get(t).onCastStateChanged?.(e))}),t3().addEventListener(a.CastContextEventType.SESSION_STATE_CHANGED,e=>{ii.forEach(t=>tJ.get(t).onSessionStateChanged?.(e))}),ii.forEach(e=>tJ.get(e).init?.()))},globalThis.chrome?.cast?.isAvailable?globalThis.cast?.framework?iU():customElements.whenDefined("google-cast-button").then(iU):globalThis.__onGCastApiAvailable=()=>{customElements.whenDefined("google-cast-button").then(iU)};let ir=0;class is extends EventTarget{#p;#a;#b;#v;#E="disconnected";#g=!1;#f=new Set;#A=new WeakMap;#y=()=>this.#T();constructor(e){super(),this.#p=e,ii.add(this),tJ.set(this,{init:()=>this.#i(),onCastStateChanged:()=>this.#k(),onSessionStateChanged:()=>this.#M(),getCastPlayer:()=>this.#I}),this.#i()}destroy(){this.#p?.textTracks?.removeEventListener("change",this.#y),this.#v&&this.#b?.controller&&Object.entries(this.#v).forEach(([e,t])=>{this.#b.controller.removeEventListener(e,t)}),this.#p&&ia.delete(this.#p),this.#a=!1}get #I(){if(ia.has(this.#p))return this.#b}get state(){return this.#E}async watchAvailability(e){if(this.#p.disableRemotePlayback)throw new t0("disableRemotePlayback attribute is present.");return this.#A.set(e,++ir),this.#f.add(e),queueMicrotask(()=>e(this.#_())),ir}async cancelWatchAvailability(e){if(this.#p.disableRemotePlayback)throw new t0("disableRemotePlayback attribute is present.");e?this.#f.delete(e):this.#f.clear()}async prompt(){if(this.#p.disableRemotePlayback)throw new t0("disableRemotePlayback attribute is present.");if(!globalThis.chrome?.cast?.isAvailable)throw new t1("The RemotePlayback API is disabled on this platform.");let e=ia.has(this.#p);ia.add(this.#p),t9(this.#p.castOptions),Object.entries(this.#v).forEach(([e,t])=>{this.#b.controller.addEventListener(e,t)});try{await t3().requestSession()}catch(t){if(e||ia.delete(this.#p),"cancel"===t)return;throw Error(t)}tJ.get(this.#p)?.loadOnPrompt?.()}#w(){ia.has(this.#p)&&(Object.entries(this.#v).forEach(([e,t])=>{this.#b.controller.removeEventListener(e,t)}),ia.delete(this.#p),this.#p.muted=this.#b.isMuted,this.#p.currentTime=this.#b.savedPlayerState.currentTime,!1===this.#b.savedPlayerState.isPau
84sed&&this.#p.play())}#_(){let e=t3()?.getCastState();return e&&"NO_DEVICES_AVAILABLE"!==e}#k(){let e=t3().getCastState();if(ia.has(this.#p)&&"CONNECTING"===e&&(this.#E="connecting",this.dispatchEvent(new Event("connecting"))),!this.#g&&e?.includes("CONNECT"))for(let e of(this.#g=!0,this.#f))e(!0);else if(this.#g&&(!e||"NO_DEVICES_AVAILABLE"===e))for(let e of(this.#g=!1,this.#f))e(!1)}async #M(){let{SESSION_RESUMED:e}=a.SessionState;if(t3().getSessionState()===e&&this.#p.castSrc===t5()?.media.contentId){ia.add(this.#p),Object.entries(this.#v).forEach(([e,t])=>{this.#b.controller.addEventListener(e,t)});try{var t;await (t=new chrome.cast.media.GetStatusRequest,new Promise((e,i)=>{t5().getStatus(t,e,i)}))}catch(e){console.error(e)}this.#v[a.RemotePlayerEventType.IS_PAUSED_CHANGED](),this.#v[a.RemotePlayerEventType.PLAYER_STATE_CHANGED]()}}#i(){a&&!this.#a&&(this.#a=!0,t9(this.#p.castOptions),this.#p.textTracks.addEventListener("change",this.#y),this.#k(),this.#b=new a.RemotePlayer,new a.RemotePlayerController(this.#b),this.#v={[a.RemotePlayerEventType.IS_CONNECTED_CHANGED]:({value:e})=>{!0===e?(this.#E="connected",this.dispatchEvent(new Event("connect"))):(this.#w(),this.#E="disconnected",this.dispatchEvent(new Event("disconnect")))},[a.RemotePlayerEventType.DURATION_CHANGED]:()=>{this.#p.dispatchEvent(new Event("durationchange"))},[a.RemotePlayerEventType.VOLUME_LEVEL_CHANGED]:()=>{this.#p.dispatchEvent(new Event("volumechange"))},[a.RemotePlayerEventType.IS_MUTED_CHANGED]:()=>{this.#p.dispatchEvent(new Event("volumechange"))},[a.RemotePlayerEventType.CURRENT_TIME_CHANGED]:()=>{this.#I?.isMediaLoaded&&this.#p.dispatchEvent(new Event("timeupdate"))},[a.RemotePlayerEventType.VIDEO_INFO_CHANGED]:()=>{this.#p.dispatchEvent(new Event("resize"))},[a.RemotePlayerEventType.IS_PAUSED_CHANGED]:()=>{this.#p.dispatchEvent(new Event(this.paused?"pause":"play"))},[a.RemotePlayerEventType.PLAYER_STATE_CHANGED]:()=>{this.#I?.playerState!==chrome.cast.media.PlayerState.PAUSED&&this.#p.dispatchEvent(new Event({[chrome.cast.media.PlayerState.PLAYING]:"playing",[chrome.cast.media.PlayerState.BUFFERING]:"waiting",[chrome.cast.media.PlayerState.IDLE]:"emptied"}[this.#I?.playerState]))},[a.RemotePlayerEventType.IS_MEDIA_LOADED_CHANGED]:async()=>{this.#I?.isMediaLoaded&&(await Promise.resolve(),this.#C())}})}#C(){this.#T()}async #T(){let e;if(!this.#I)return;let t=(this.#b.mediaInfo?.tracks??[]).filter(({type:e})=>e===chrome.cast.media.TrackType.TEXT),i=[...this.#p.textTracks].filter(({kind:e})=>"subtitles"===e||"captions"===e),a=t.map(({language:e,name:t,trackId:a})=>{let{mode:r}=i.find(i=>i.language===e&&i.label===t)??{};return!!r&&{mode:r,trackId:a}}).filter(Boolean),r=a.filter(({mode:e})=>"showing"!==e).map(({trackId:e})=>e),n=a.find(({mode:e})=>"showing"===e),s=t4()?.getSessionObj().media[0]?.activeTrackIds??[],o=s;if(s.length&&(o=o.filter(e=>!r.includes(e))),n?.trackId&&(o=[...o,n.trackId]),e=o=[...new Set(o)],!(s.length===e.length&&s.every(t=>e.includes(t))))try{let e=new chrome.cast.media.EditTracksInfoRequest(o);await new Promise((t,i)=>{t5().editTracksInfo(e,t,i)})}catch(e){console.error(e)}}}let io=e=>class extends e{static observedAttributes=[...e.observedAttributes??[],"cast-src","cast-content-type","cast-stream-type","cast-receiver"];#R={paused:!1};#S=t8();#L;#D;get remote(){if(this.#D)return this.#D;if(globalThis.chrome){if(!this.isConnected)return;return this.disableRemotePlayback||function(){let e="https://www.gstatic.com/cv/js/sender/v1/cast_sender.js?loadCastFramework=1";if(globalThis.chrome?.cast||document.querySelector(`script[src="${e}"]`))return;let t=document.createElement("script");t.src=e,document.head.append(t)}(),tJ.set(this,{loadOnPrompt:()=>this.#x()}),this.#D=new is(this)}return super.remote}get #I(){return tJ.get(this.#D)?.getCastPlayer?.()}disconnectedCallback(){this.#D?.destroy(),this.#D=null,tJ.delete(this),super.disconnectedCallback?.()}attributeChangedCallback(e,t,i){if(super.attributeChangedCallback(e,t,i),"cast-receiver"===e&&i){this.#S.receiverApplicationId=i;return}if(this.#I)switch(e){case"cast-stream-type":case"cast-src":this.load()}}async #x(){this.#R.paused=super.paused,super.pause(),this.muted=super.muted;try{await this.load()}catch(e){console.error(e)}}async load(){if(!this.#I)return super.load();let e=new chrome.cast.media.MediaInfo(this.castSrc,this.castContentType);e.customData=this.castCustomData;let t=[...this.querySelectorAll("track")].filter(({kind:e,src:t})=>t&&("subtitles"===e||"captions"===e)),i=[],a=0;if(t.length&&(e.tracks=t.map(e=>{let t=++a;0===i.length&&"showing"===e.track.mode&&i.push(t);let r=new chrome.cast.media.Track(t,chrome.cast.media.TrackType.TEXT);return r.trackContentId=e.src,r.trackContentType="text/vtt",r.subtype="captions"===e.kind?chrome.cast.media.TextTrackType.CAPTIONS:chrome.cast.media.TextTrackType.SUBTITLES,r.name=e.label,r.language=e.srclang,r})),"live"===this.castStreamType?e.streamType=chrome.cast.media.StreamType.LIVE:e.streamType=chrome.cast.media.StreamType.BUFFERED,e.metadata=new chrome.cast.media.GenericMediaMetadata,e.metadata.title=this.title,e.metadata.images=[{url:this.poster}],await ie(this.castSrc)){e.contentType||(e.contentType="application/x-mpegURL");let{videoFormat:t,audioFormat:i}=await it(this.castSrc);t?.includes("m4s")||t?.includes("mp4")||t?.includes("m4a")?(e.hlsSegmentFormat=chrome.cast.media.HlsSegmentFormat.FMP4,e.hlsVideoSegmentFormat=chrome.cast.media.HlsVideoSegmentFormat.FMP4):i?.includes("aac")?(e.hlsSegmentFormat=chrome.cast.media.HlsSegmentFormat.AAC,e.hlsVideoSegmentFormat=chrome.cast.media.HlsVideoSegmentFormat.MPEG2_TS):(t?.includes("ts")||i?.includes("ts"))&&(e.hlsSegmentFormat=chrome.cast.media.HlsSegmentFormat.TS,e.hlsVideoSegmentFormat=chrome.cast.media.HlsVideoSegmentFormat.MPEG2_TS)}let r=new chrome.cast.media.LoadRequest(e);r.currentTime=super.currentTime??0,r.autoplay=!this.#R.paused,r.activeTrackIds=i,await t4()?.loadMedia(r),this.dispatchEvent(new Event("volumechange"))}play(){if(this.#I){this.#I.isPaused&&this.#I.controller?.playOrPause();return}return super.play()}pause(){if(this.#I){this.#I.isPaused||this.#I.controller?.playOrPause();return}super.pause()}get castOptions(){return this.#S}get castReceiver(){return this.getAttribute("cast-receiver")??void 0}set castReceiver(e){this.castReceiver!=e&&this.setAttribute("cast-receiver",`${e}`)}get castSrc(){let e=this.currentSrc,t=e?.startsWith("blob:")?void 0:e;return this.getAttribute("cast-src")??this.querySelector("source")?.src??t??this.getAttribute("src")??void 0}set castSrc(e){this.castSrc!=e&&this.setAttribute("cast-src",`${e}`)}get castContentType(){return this.getAttribute("cast-content-type")??void 0}set castContentType(e){this.setAttribute("cast-content-type",`${e}`)}get castStreamType(){return this.getAttribute("cast-stream-type")??this.streamType??void 0}set castStreamType(e){this.setAttribute("cast-stream-type",`${e}`)}get castCustomData(){return this.#L}set castCustomData(e){let t=typeof e;if(!["object","undefined"].includes(t)){console.error(`castCustomData must be nullish or an object but value was of type ${t}`);return}this.#L=e}get readyState(){if(this.#I)switch(this.#I.playerState){case chrome.cast.media.PlayerState.IDLE:return 0;case chrome.cast.media.PlayerState.BUFFERING:return 2;default:return 3}return super.readyState}get paused(){return this.#I?this.#I.isPaused:super.paused}get muted(){return this.#I?this.#I?.isMuted:super.muted}set muted(e){if(this.#I){(e&&!this.#I.isMuted||!e&&this.#I.isMuted)&&this.#I.controller?.muteOr
84Unmute();return}super.muted=e}get volume(){return this.#I?this.#I?.volumeLevel??1:super.volume}set volume(e){if(this.#I){this.#I.volumeLevel=+e,this.#I.controller?.setVolumeLevel();return}super.volume=e}get duration(){return this.#I&&this.#I?.isMediaLoaded?this.#I?.duration??NaN:super.duration}get currentTime(){return this.#I&&this.#I?.isMediaLoaded?this.#I?.currentTime??0:super.currentTime}set currentTime(e){if(this.#I){this.#I.currentTime=e,this.#I.controller?.seek();return}super.currentTime=e}};class il extends Event{track;constructor(e,t){super(e),this.track=t.track}}let id=new WeakMap;function iu(e){var t;let i;return id.get(e)??(t={},(i=id.get(e))||id.set(e,i={}),Object.assign(i,t))}function ic(e,t){let i=e.videoTracks;iu(t).media=new WeakRef(e),iu(t).renditionSet||(iu(t).renditionSet=new Set);let a=iu(i).trackSet;a.add(t);let r=a.size-1;r in im.prototype||Object.defineProperty(im.prototype,r,{get(){return[...iu(this).trackSet][r]}}),queueMicrotask(()=>{i.dispatchEvent(new il("addtrack",{track:t}))})}function ih(e){let t=iu(e).media?.deref()?.videoTracks;t&&(iu(t).trackSet.delete(e),queueMicrotask(()=>{t.dispatchEvent(new il("removetrack",{track:e}))}))}class im extends EventTarget{#N;#O;#P;constructor(){super(),iu(this).trackSet=new Set}get #U(){return iu(this).trackSet}[Symbol.iterator](){return this.#U.values()}get length(){return this.#U.size}getTrackById(e){return[...this.#U].find(t=>t.id===e)??null}get selectedIndex(){return[...this.#U].findIndex(e=>e.selected)}get onaddtrack(){return this.#N}set onaddtrack(e){this.#N&&(this.removeEventListener("addtrack",this.#N),this.#N=void 0),"function"==typeof e&&(this.#N=e,this.addEventListener("addtrack",e))}get onremovetrack(){return this.#O}set onremovetrack(e){this.#O&&(this.removeEventListener("removetrack",this.#O),this.#O=void 0),"function"==typeof e&&(this.#O=e,this.addEventListener("removetrack",e))}get onchange(){return this.#P}set onchange(e){this.#P&&(this.removeEventListener("change",this.#P),this.#P=void 0),"function"==typeof e&&(this.#P=e,this.addEventListener("change",e))}}class ip extends Event{rendition;constructor(e,t){super(e),this.rendition=t.rendition}}function ib(e){let t=iu(e).media?.deref();return t?[...t.videoTracks].filter(e=>e.selected).flatMap(e=>[...iu(e).renditionSet]):[]}class iv extends EventTarget{#W;#$;#P;[Symbol.iterator](){return ib(this).values()}get length(){return ib(this).length}getRenditionById(e){return ib(this).find(t=>`${t.id}`==`${e}`)??null}get selectedIndex(){return ib(this).findIndex(e=>e.selected)}set selectedIndex(e){for(let[t,i]of ib(this).entries())i.selected=t===e}get onaddrendition(){return this.#W}set onaddrendition(e){this.#W&&(this.removeEventListener("addrendition",this.#W),this.#W=void 0),"function"==typeof e&&(this.#W=e,this.addEventListener("addrendition",e))}get onremoverendition(){return this.#$}set onremoverendition(e){this.#$&&(this.removeEventListener("removerendition",this.#$),this.#$=void 0),"function"==typeof e&&(this.#$=e,this.addEventListener("removerendition",e))}get onchange(){return this.#P}set onchange(e){this.#P&&(this.removeEventListener("change",this.#P),this.#P=void 0),"function"==typeof e&&(this.#P=e,this.addEventListener("change",e))}}class iE{src;id;width;height;bitrate;frameRate;codec;#B=!1;get selected(){return this.#B}set selected(e){this.#B!==e&&(this.#B=e,function(e){let t=iu(e).media?.deref()?.videoRenditions;t&&!iu(t).changeRequested&&(iu(t).changeRequested=!0,queueMicrotask(()=>{delete iu(t).changeRequested,iu(e).track.selected&&t.dispatchEvent(new Event("change"))}))}(this))}}class ig{id;kind;label="";language="";sourceBuffer;#B=!1;addRendition(e,t,i,a,r,n){let s=new iE;return s.src=e,s.width=t,s.height=i,s.frameRate=n,s.bitrate=r,s.codec=a,!function(e,t){let i=iu(e).media?.deref()?.videoRenditions;iu(t).media=iu(e).media,iu(t).track=e;let a=iu(e).renditionSet;a.add(t);let r=a.size-1;r in iv.prototype||Object.defineProperty(iv.prototype,r,{get(){return ib(this)[r]}}),queueMicrotask(()=>{i&&e.selected&&i.dispatchEvent(new ip("addrendition",{rendition:t}))})}(this,s),s}removeRendition(e){!function(e){let t=iu(e).media?.deref()?.videoRenditions,i=iu(e).track;iu(i).renditionSet.delete(e),queueMicrotask(()=>{let i=iu(e).track;t&&i.selected&&t.dispatchEvent(new ip("removerendition",{rendition:e}))})}(e)}get selected(){return this.#B}set selected(e){this.#B!==e&&(this.#B=e,!0===e&&function(e){let t=iu(e).media?.deref()?.videoTracks??[],i=!1;for(let a of t)a!==e&&(a.selected=!1,i=!0);if(i){if(iu(t).changeRequested)return;iu(t).changeRequested=!0,queueMicrotask(()=>{delete iu(t).changeRequested,t.dispatchEvent(new Event("change"))})}}(this))}}function iA(e){let t=iu(e).media?.deref();return t?[...t.audioTracks].filter(e=>e.enabled).flatMap(e=>[...iu(e).renditionSet]):[]}
84class iy extends EventTarget{#W;#$;#P;[Symbol.iterator](){return iA(this).values()}get length(){return iA(this).length}getRenditionById(e){return iA(this).find(t=>`${t.id}`==`${e}`)??null}get selectedIndex(){return iA(this).findIndex(e=>e.selected)}set selectedIndex(e){for(let[t,i]of iA(this).entries())i.selected=t===e}get onaddrendition(){return this.#W}set onaddrendition(e){this.#W&&(this.removeEventListener("addrendition",this.#W),this.#W=void 0),"function"==typeof e&&(this.#W=e,this.addEventListener("addrendition",e))}get onremoverendition(){return this.#$}set onremoverendition(e){this.#$&&(this.removeEventListener("removerendition",this.#$),this.#$=void 0),"function"==typeof e&&(this.#$=e,this.addEventListener("removerendition",e))}get onchange(){return this.#P}set onchange(e){this.#P&&(this.removeEventListener("change",this.#P),this.#P=void 0),"function"==typeof e&&(this.#P=e,this.addEventListener("change",e))}}class iT{src;id;bitrate;codec;#B=!1;get selected(){return this.#B}set selected(e){this.#B!==e&&(this.#B=e,function(e){let t=iu(e).media?.deref()?.audioRenditions;t&&!iu(t).changeRequested&&(iu(t).changeRequested=!0,queueMicrotask(()=>{delete iu(t).changeRequested,iu(e).track.enabled&&t.dispatchEvent(new Event("change"))}))}(this))}}function ik(e,t){let i=e.audioTracks;iu(t).media=new WeakRef(e),iu(t).renditionSet||(iu(t).renditionSet=new Set);let a=iu(i).trackSet;a.add(t);let r=a.size-1;r in iI.prototype||Object.defineProperty(iI.prototype,r,{get(){return[...iu(this).trackSet][r]}}),queueMicrotask(()=>{i.dispatchEvent(new il("addtrack",{track:t}))})}function iM(e){let t=iu(e).media?.deref()?.audioTracks;t&&(iu(t).trackSet.delete(e),queueMicrotask(()=>{t.dispatchEvent(new il("removetrack",{track:e}))}))}class iI extends EventTarget{#N;#O;#P;constructor(){super(),iu(this).trackSet=new Set}get #U(){return iu(this).trackSet}[Symbol.iterator](){return this.#U.values()}get length(){return this.#U.size}getTrackById(e){return[...this.#U].find(t=>t.id===e)??null}get onaddtrack(){return this.#N}set onaddtrack(e){this.#N&&(this.removeEventListener("addtrack",this.#N),this.#N=void 0),"function"==typeof e&&(this.#N=e,this.addEventListener("addtrack",e))}get onremovetrack(){return this.#O}set onremovetrack(e){this.#O&&(this.removeEventListener("removetrack",this.#O),this.#O=void 0),"function"==typeof e&&(this.#O=e,this.addEventListener("removetrack",e))}get onchange(){return this.#P}set onchange(e){this.#P&&(this.removeEventListener("change",this.#P),this.#P=void 0),"function"==typeof e&&(this.#P=e,this.addEventListener("change",e))}}class i_{id;kind;label="";language="";sourceBuffer;#H=!1;addRendition(e,t,i){let a=new iT;return a.src=e,a.codec=t,a.bitrate=i,!function(e,t){let i=iu(e).media?.deref()?.audioRenditions;iu(t).media=iu(e).media,iu(t).track=e;let a=iu(e).renditionSet;a.add(t);let r=a.size-1;r in iy.prototype||Object.defineProperty(iy.prototype,r,{get(){return iA(this)[r]}}),queueMicrotask(()=>{i&&e.enabled&&i.dispatchEvent(new ip("addrendition",{rendition:t}))})}(this,a),a}removeRendition(e){!function(e){let t=iu(e).media?.deref()?.audioRenditions,i=iu(e).track;iu(i).renditionSet.delete(e),queueMicrotask(()=>{let i=iu(e).track;t&&i.enabled&&t.dispatchEvent(new ip("removerendition",{rendition:e}))})}(e)}get enabled(){return this.#H}set enabled(e){this.#H!==e&&(this.#H=e,function(e){let t=iu(e).media?.deref()?.audioTracks;t&&!iu(t).changeRequested&&(iu(t).changeRequested=!0,queueMicrotask(()=>{delete iu(t).changeRequested,t.dispatchEvent(new Event("change"))}))}(this))}}let iw=iS(globalThis.HTMLMediaElement,"video"),iC=iS(globalThis.HTMLMediaElement,"audio");function iR(e){if(!e?.prototype)return e;let t=iS(e,"video");(!t||`${t}`.includes("[native code]"))&&Object.defineProperty(e.prototype,"videoTracks",{get(){return function(e){let t=iu(e).videoTracks;if(!t&&(t=new im,iu(e).videoTracks=t,iw)){let i=iw.call(e.nativeEl??e);for(let t of i)ic(e,t);i.addEventListener("change",()=>{t.dispatchEvent(new Event("change"))}),i.addEventListener("addtrack",a=>{if([...t].some(e=>e instanceof ig)){for(let e of i)ih(e);return}ic(e,a.track)}),i.addEventListener("removetrack",e=>{ih(e.track)})}return t}(this)}});let i=iS(e,"audio");(!i||`${i}`.includes("[native code]"))&&Object.defineProperty(e.prototype,"audioTracks",{get(){return function(e){let t=iu(e).audioTracks;
84if(!t&&(t=new iI,iu(e).audioTracks=t,iC)){let i=iC.call(e.nativeEl??e);for(let t of i)ik(e,t);i.addEventListener("change",()=>{t.dispatchEvent(new Event("change"))}),i.addEventListener("addtrack",a=>{if([...t].some(e=>e instanceof i_)){for(let e of i)iM(e);return}ik(e,a.track)}),i.addEventListener("removetrack",e=>{iM(e.track)})}return t}(this)}}),"addVideoTrack"in e.prototype||(e.prototype.addVideoTrack=function(e,t="",i=""){let a=new ig;return a.kind=e,a.label=t,a.language=i,ic(this,a),a}),"removeVideoTrack"in e.prototype||(e.prototype.removeVideoTrack=ih),"addAudioTrack"in e.prototype||(e.prototype.addAudioTrack=function(e,t="",i=""){let a=new i_;return a.kind=e,a.label=t,a.language=i,ik(this,a),a}),"removeAudioTrack"in e.prototype||(e.prototype.removeAudioTrack=iM),"videoRenditions"in e.prototype||Object.defineProperty(e.prototype,"videoRenditions",{get(){return a(this)}});let a=e=>{let t=iu(e).videoRenditions;return t||(iu(t=new iv).media=new WeakRef(e),iu(e).videoRenditions=t),t};"audioRenditions"in e.prototype||Object.defineProperty(e.prototype,"audioRenditions",{get(){return r(this)}});let r=e=>{let t=iu(e).audioRenditions;return t||(iu(t=new iy).media=new WeakRef(e),iu(e).audioRenditions=t),t};return e}function iS(e,t){if(e?.prototype)return Object.getOwnPropertyDescriptor(e.prototype,`${t}Tracks`)?.get}var iL=e=>{throw TypeError(e)},iD=(e,t,i)=>t.has(e)||iL("Cannot "+i),ix=(e,t,i)=>(iD(e,t,"read from private field"),i?i.call(e):t.get(e)),iN=(e,t,i)=>t.has(e)?iL("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,i),iO=(e,t,i,a)=>(iD(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),iP=class{addEventListener(){}removeEventListener(){}dispatchEvent(e){return!0}};if("undefined"==typeof DocumentFragment){class e extends iP{}globalThis.DocumentFragment=e}var iU,iW,i$=class extends iP{},iB=class{constructor(e,t={}){iN(this,iW),iO(this,iW,null==t?void 0:t.detail)}get detail(){return ix(this,iW)}initCustomEvent(){}};iW=new WeakMap;var iH={document:{createElement:function(e,t){return new i$}},DocumentFragment,customElements:{get(e){},define(e,t,i){},getName:e=>null,upgrade(e){},whenDefined:e=>Promise.resolve(i$)},CustomEvent:iB,EventTarget:iP,HTMLElement:i$,HTMLVideoElement:class extends iP{}},iV="undefined"==typeof window||void 0===globalThis.customElements,iK=iV?iH:globalThis;iV&&iH.document;var iF,iY=class extends io(iR(tQ)){constructor(){super(...arguments),iN(this,iF)}get autoplay(){let e=this.getAttribute("autoplay");return null!==e&&(""===e||e)}set autoplay(e){e!==this.autoplay&&(e?this.setAttribute("autoplay","string"==typeof e?e:""):this.removeAttribute("autoplay"))}get muxCastCustomData(){return{mux:{playbackId:this.playbackId,minResolution:this.minResolution,maxResolution:this.maxResolution,renditionOrder:this.renditionOrder,customDomain:this.customDomain,tokens:{drm:this.drmToken},envKey:this.envKey,metadata:this.metadata,disableCookies:this.disableCookies,disableTracking:this.disableTracking,beaconCollectionDomain:this.beaconCollectionDomain,startTime:this.startTime,preferCmcd:this.preferCmcd}}}get castCustomData(){var e;return null!=(e=ix(this,iF))?e:this.muxCastCustomData}set castCustomData(e){iO(this,iF,e)}};iF=new WeakMap,iK.customElements.get("mux-video")||(iK.customElements.define("mux-video",iY),iK.MuxVideoElement=iY);var iq=i(70668),iG=i(91160),ij=i(16562);let iZ=[{singular:"hour",plural:"hours"},{singular:"minute",plural:"minutes"},{singular:"second",plural:"seconds"}],iz=(e,t)=>{let i=1===e?(0,ij.t)(iZ[t].singular):(0,ij.t)(iZ[t].plural);return`${e} ${i}`},iX=e=>{if(!(0,iG.qh)(e))return"";let t=Math.abs(e),i=t!==e,a=new Date(0,0,0,0,0,t,0),r=[a.getHours(),a.getMinutes(),a.getSeconds()].map((e,t)=>e&&iz(e,t)).filter(e=>e).join(", ");return i?(0,ij.t)("{time} remaining",{time:r}):r};function iQ(e,t){let i=!1;e<0&&(i=!0,e=0-e);let a=Math.floor((e=e<0?0:e)%60),r=Math.floor(e/60%60),n=Math.floor(e/3600);return(isNaN(e)||e===1/0)&&(n=r=a="0"),r=(((n=n>0||Math.floor(t/3600)>0?n+":":"")||Math.floor(t/60%60)>=10)&&r<10?"0"+r:r)+":",(i?"-":"")+n+r+(a=a<10?"0"+a:a)}Object.freeze({length:0,start(e){let t=e>>>0;
84if(t>=this.length)throw new DOMException(`Failed to execute 'start' on 'TimeRanges': The index provided (${t}) is greater than or equal to the maximum bound (${this.length}).`);return 0},end(e){let t=e>>>0;if(t>=this.length)throw new DOMException(`Failed to execute 'end' on 'TimeRanges': The index provided (${t}) is greater than or equal to the maximum bound (${this.length}).`);return 0}});var iJ=i(41302),i0=i(96678),i1=i(80196);let i2="placement",i3="bounds";class i4 extends i1.Mq.HTMLElement{constructor(){if(super(),this.updateXOffset=()=>{var e;if(!(0,i0.Jv)(this,{checkOpacity:!1,checkVisibilityCSS:!1}))return;let t=this.placement;if("left"===t||"right"===t){this.style.removeProperty("--media-tooltip-offset-x");return}let i=getComputedStyle(this),a=null!=(e=(0,i0.l5)(this,"#"+this.bounds))?e:(0,i0.Xq)(this);if(!a)return;let{x:r,width:n}=a.getBoundingClientRect(),{x:s,width:o}=this.getBoundingClientRect(),l=i.getPropertyValue("--media-tooltip-offset-x"),d=l?parseFloat(l.replace("px","")):0,u=i.getPropertyValue("--media-tooltip-container-margin"),c=u?parseFloat(u.replace("px","")):0,h=s-r+d-c,m=s+o-(r+n)+d+c;if(h<0){this.style.setProperty("--media-tooltip-offset-x",`${h}px`);return}if(m>0){this.style.setProperty("--media-tooltip-offset-x",`${m}px`);return}this.style.removeProperty("--media-tooltip-offset-x")},!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}if(this.arrowEl=this.shadowRoot.querySelector("#arrow"),Object.prototype.hasOwnProperty.call(this,"placement")){let e=this.placement;delete this.placement,this.placement=e}}static get observedAttributes(){return[i2,i3]}get placement(){return(0,i0.ST)(this,i2)}set placement(e){(0,i0.Lb)(this,i2,e)}get bounds(){return(0,i0.ST)(this,i3)}set bounds(e){(0,i0.Lb)(this,i3,e)}}i4.shadowRootOptions={mode:"open"},i4.getTemplateHTML=function(e){return` 85 <style> 86 :host { 87 --_tooltip-background-color: var(--media-tooltip-background-color, var(--media-secondary-color, rgba(20, 20, 30, .7))); 88 --_tooltip-background: var(--media-tooltip-background, var(--_tooltip-background-color)); 89 --_tooltip-arrow-half-width: calc(var(--media-tooltip-arrow-width, 12px) / 2); 90 --_tooltip-arrow-height: var(--media-tooltip-arrow-height, 5px); 91 --_tooltip-arrow-background: var(--media-tooltip-arrow-color, var(--_tooltip-background-color)); 92 position: relative; 93 pointer-events: none; 94 display: var(--media-tooltip-display, inline-flex); 95 justify-content: center; 96 align-items: center; 97 box-sizing: border-box; 98 z-index: var(--media-tooltip-z-index, 1); 99 background: var(--_tooltip-background); 100 color: var(--media-text-color, var(--media-primary-color, rgb(238 238 238))); 101 font: var(--media-font, 102 var(--media-font-weight, 400) 103 var(--media-font-size, 13px) / 104 var(--media-text-content-height, var(--media-control-height, 18px)) 105 var(--media-font-family, helvetica neue, segoe ui, roboto, arial, sans-serif)); 106 padding: var(--media-tooltip-padding, .35em .7em); 107 border: var(--media-tooltip-border, none); 108 border-radius: var(--media-tooltip-border-radius, 5px); 109 filter: var(--media-tooltip-filter, drop-shadow(0 0 4px rgba(0, 0, 0, .2))); 110 white-space: var(--media-tooltip-white-space, nowrap); 111 } 112 113 :host([hidden]) { 114 display: none; 115 } 116 117 img, svg { 118 display: inline-block; 119 } 120 121 #arrow { 122 position: absolute; 123 width: 0px; 124 height: 0px; 125 border-style: solid; 126 display: var(--media-tooltip-arrow-display, block); 127 } 128 129 :host(:not([placement])), 130 :host([placement="top"]) { 131 position: absolute; 132 bottom: calc(100% + var(--media-tooltip-distance, 12px)); 133 left: 50%; 134 transform: translate(calc(-50% - var(--media-tooltip-offset-x, 0px)), 0); 135 } 136 :host(:not([placement])) #arrow, 137 :host([placement="top"]) #arrow { 138 top: 100%; 139 left: 50%; 140 border-width: var(--_tooltip-arrow-height) var(--_tooltip-arrow-half-width) 0 var(--_tooltip-arrow-half-width); 141 border-color: var(--_tooltip-arrow-background) transparent transparent transparent; 142 transform: translate(calc(-50% + var(--media-tooltip-offset-x, 0px)), 0
142); 143 } 144 145 :host([placement="right"]) { 146 position: absolute; 147 left: calc(100% + var(--media-tooltip-distance, 12px)); 148 top: 50%; 149 transform: translate(0, -50%); 150 } 151 :host([placement="right"]) #arrow { 152 top: 50%; 153 right: 100%; 154 border-width: var(--_tooltip-arrow-half-width) var(--_tooltip-arrow-height) var(--_tooltip-arrow-half-width) 0; 155 border-color: transparent var(--_tooltip-arrow-background) transparent transparent; 156 transform: translate(0, -50%); 157 } 158 159 :host([placement="bottom"]) { 160 position: absolute; 161 top: calc(100% + var(--media-tooltip-distance, 12px)); 162 left: 50%; 163 transform: translate(calc(-50% - var(--media-tooltip-offset-x, 0px)), 0); 164 } 165 :host([placement="bottom"]) #arrow { 166 bottom: 100%; 167 left: 50%; 168 border-width: 0 var(--_tooltip-arrow-half-width) var(--_tooltip-arrow-height) var(--_tooltip-arrow-half-width); 169 border-color: transparent transparent var(--_tooltip-arrow-background) transparent; 170 transform: translate(calc(-50% + var(--media-tooltip-offset-x, 0px)), 0); 171 } 172 173 :host([placement="left"]) { 174 position: absolute; 175 right: calc(100% + var(--media-tooltip-distance, 12px)); 176 top: 50%; 177 transform: translate(0, -50%); 178 } 179 :host([placement="left"]) #arrow { 180 top: 50%; 181 left: 100%; 182 border-width: var(--_tooltip-arrow-half-width) 0 var(--_tooltip-arrow-half-width) var(--_tooltip-arrow-height); 183 border-color: transparent transparent transparent var(--_tooltip-arrow-background); 184 transform: translate(0, -50%); 185 } 186 187 :host([placement="none"]) #arrow { 188 display: none; 189 } 190 </style> 191 <slot></slot> 192 <div id="arrow"></div> 193 `},i1.Mq.customElements.get("media-tooltip")||i1.Mq.customElements.define("media-tooltip",i4);var i5=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},i9=(e,t,i)=>(i5(e,t,"read from private field"),i?i.call(e):t.get(e)),i8=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},i6=(e,t,i,a)=>(i5(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),i7=(e,t,i)=>(i5(e,t,"access private method"),i);let ae={TOOLTIP_PLACEMENT:"tooltipplacement",DISABLED:"disabled",NO_TOOLTIP:"notooltip"};class at extends i1.Mq.HTMLElement{constructor(){if(super(),i8(this,s2),i8(this,sX,void 0),this.preventClick=!1,this.tooltipEl=null,i8(this,sQ,e=>{this.preventClick||this.handleClick(e),setTimeout(i9(this,sJ),0)}),i8(this,sJ,()=>{var e,t;null==(t=null==(e=this.tooltipEl)?void 0:e.updateXOffset)||t.call(e)}),i8(this,s0,e=>{let{key:t}=e;if(!this.keysUsed.includes(t)){this.removeEventListener("keyup",i9(this,s0));return}this.preventClick||this.handleClick(e)}),i8(this,s1,e=>{let{metaKey:t,altKey:i,key:a}=e;if(t||i||!this.keysUsed.includes(a)){this.removeEventListener("keyup",i9(this,s0));return}this.addEventListener("keyup",i9(this,s0),{once:!0})}),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes),t=this.constructor.getTemplateHTML(e);this.shadowRoot.setHTMLUnsafe?this.shadowRoot.setHTMLUnsafe(t):this.shadowRoot.innerHTML=t}this.tooltipEl=this.shadowRoot.querySelector("media-tooltip")}static get observedAttributes(){return["disabled",ae.TOOLTIP_PLACEMENT,iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER,iq.MediaUIAttributes.MEDIA_LANG]}enable(){this.addEventListener("click",i9(this,sQ)),this.addEventListener("keydown",i9(this,s1)),this.tabIndex=0}disable(){this.removeEventListener("click",i9(this,sQ)),this.removeEventListener("keydown",i9(this,s1)),this.removeEventListener("keyup",i9(this,s0)),this.tabIndex=-1}attributeChangedCallback(e,t,i){var a,r,n,s,o;e===iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER?(t&&(null==(r=null==(a=i9(this,sX))?void 0:a.unassociateElement)||r.call(a,this),i6(this,sX,null)),i&&this.isConnected&&(i6(this,sX,null==(n=this.getRootNode())?void 0:n.getElementById(i)),null==(o=null==(s=i9(this,sX))?void 0:s.associateElement)||o.call(s,this))):"disabled"===e&&i!==t?null==i?this.enable():this.disable():e===ae.TOOLTIP_PLACEMENT&&this.tooltipEl&&i!==t?this.tooltipEl.placement=i:e===iq.MediaUIAttributes.MEDIA_LA
193NG&&(this.shadowRoot.querySelector('slot[name="tooltip-content"]').innerHTML=this.constructor.getTooltipContentHTML()),i9(this,sJ).call(this)}connectedCallback(){var e,t,i;let{style:a}=(0,i0.R7)(this.shadowRoot,":host");a.setProperty("display",`var(--media-control-display, var(--${this.localName}-display, inline-flex))`),this.hasAttribute("disabled")?this.disable():this.enable(),this.setAttribute("role","button");let r=this.getAttribute(iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER);r&&(i6(this,sX,null==(e=this.getRootNode())?void 0:e.getElementById(r)),null==(i=null==(t=i9(this,sX))?void 0:t.associateElement)||i.call(t,this)),i1.Mq.customElements.whenDefined("media-tooltip").then(()=>i7(this,s2,s3).call(this))}disconnectedCallback(){var e,t;this.disable(),null==(t=null==(e=i9(this,sX))?void 0:e.unassociateElement)||t.call(e,this),i6(this,sX,null),this.removeEventListener("mouseenter",i9(this,sJ)),this.removeEventListener("focus",i9(this,sJ)),this.removeEventListener("click",i9(this,sQ))}get keysUsed(){return["Enter"," "]}get tooltipPlacement(){return(0,i0.ST)(this,ae.TOOLTIP_PLACEMENT)}set tooltipPlacement(e){(0,i0.Lb)(this,ae.TOOLTIP_PLACEMENT,e)}get mediaController(){return(0,i0.ST)(this,iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER)}set mediaController(e){(0,i0.Lb)(this,iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER,e)}get disabled(){return(0,i0.zc)(this,ae.DISABLED)}set disabled(e){(0,i0.Pj)(this,ae.DISABLED,e)}get noTooltip(){return(0,i0.zc)(this,ae.NO_TOOLTIP)}set noTooltip(e){(0,i0.Pj)(this,ae.NO_TOOLTIP,e)}handleClick(e){}}sX=new WeakMap,sQ=new WeakMap,sJ=new WeakMap,s0=new WeakMap,s1=new WeakMap,s2=new WeakSet,s3=function(){this.addEventListener("mouseenter",i9(this,sJ)),this.addEventListener("focus",i9(this,sJ)),this.addEventListener("click",i9(this,sQ));let e=this.tooltipPlacement;e&&this.tooltipEl&&(this.tooltipEl.placement=e)},at.shadowRootOptions={mode:"open"},at.getTemplateHTML=function(e,t={}){return` 194 <style> 195 :host { 196 position: relative; 197 font: var(--media-font, 198 var(--media-font-weight, bold) 199 var(--media-font-size, 14px) / 200 var(--media-text-content-height, var(--media-control-height, 24px)) 201 var(--media-font-family, helvetica neue, segoe ui, roboto, arial, sans-serif)); 202 color: var(--media-text-color, var(--media-primary-color, rgb(238 238 238))); 203 background: var(--media-control-background, var(--media-secondary-color, rgb(20 20 30 / .7))); 204 padding: var(--media-button-padding, var(--media-control-padding, 10px)); 205 justify-content: var(--media-button-justify-content, center); 206 display: inline-flex; 207 align-items: center; 208 vertical-align: middle; 209 box-sizing: border-box; 210 transition: background .15s linear; 211 pointer-events: auto; 212 cursor: var(--media-cursor, pointer); 213 -webkit-tap-highlight-color: transparent; 214 } 215 216 217 :host(:focus-visible) { 218 box-shadow: var(--media-focus-box-shadow, inset 0 0 0 2px rgb(27 127 204 / .9)); 219 outline: 0; 220 } 221 222 :host(:where(:focus)) { 223 box-shadow: none; 224 outline: 0; 225 } 226 227 :host(:hover) { 228 background: var(--media-control-hover-background, rgba(50 50 70 / .7)); 229 } 230 231 slot[name="icon"] { 232 display: inline-flex; 233 align-items: center; 234 } 235 236 svg, img, ::slotted(svg), ::slotted(img) { 237 width: var(--media-button-icon-width); 238 height: var(--media-button-icon-height, var(--media-control-height, 24px)); 239 transform: var(--media-button-icon-transform); 240 transition: var(--media-button-icon-transition); 241 fill: var(--media-icon-color, var(--media-primary-color, rgb(238 238 238))); 242 vertical-align: middle; 243 max-width: 100%; 244 max-height: 100%; 245 min-width: 100%; 246 } 247 248 media-tooltip { 249 250 max-width: 0; 251 overflow-x: clip; 252 opacity: 0; 253 transition: opacity .3s, max-width 0s 9s; 254 } 255 256 :host(:hover) media-tooltip, 257 :host(:focus-visible) media-tooltip { 258 max-width: 100vw; 259 opacity: 1; 260 transition: opacity .3s; 261 } 262 263 :host([notooltip]) slot[name="tooltip"] { 264 display: none; 265 } 266 </style> 267
268 ${this.getSlotTemplateHTML(e,t)} 269 270 <slot name="tooltip"> 271 <media-tooltip part="tooltip" aria-hidden="true"> 272 <template shadowrootmode="${i4.shadowRootOptions.mode}"> 273 ${i4.getTemplateHTML({})} 274 </template> 275 <slot name="tooltip-content"> 276 ${this.getTooltipContentHTML(e)} 277 </slot> 278 </media-tooltip> 279 </slot> 280 `},at.getSlotTemplateHTML=function(e,t){return` 281 <slot></slot> 282 `},at.getTooltipContentHTML=function(){return""},i1.Mq.customElements.get("media-chrome-button")||i1.Mq.customElements.define("media-chrome-button",at);let ai=`<svg aria-hidden="true" viewBox="0 0 26 24"> 283 <path d="M22.13 3H3.87a.87.87 0 0 0-.87.87v13.26a.87.87 0 0 0 .87.87h3.4L9 16H5V5h16v11h-4l1.72 2h3.4a.87.87 0 0 0 .87-.87V3.87a.87.87 0 0 0-.86-.87Zm-8.75 11.44a.5.5 0 0 0-.76 0l-4.91 5.73a.5.5 0 0 0 .38.83h9.82a.501.501 0 0 0 .38-.83l-4.91-5.73Z"/> 284</svg> 285`,aa=e=>{let t=e.mediaIsAirplaying?(0,ij.t)("stop airplay"):(0,ij.t)("start airplay");e.setAttribute("aria-label",t)};class ar extends at{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_IS_AIRPLAYING,iq.MediaUIAttributes.MEDIA_AIRPLAY_UNAVAILABLE]}connectedCallback(){super.connectedCallback(),aa(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_IS_AIRPLAYING&&aa(this)}get mediaIsAirplaying(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_IS_AIRPLAYING)}set mediaIsAirplaying(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_IS_AIRPLAYING,e)}get mediaAirplayUnavailable(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_AIRPLAY_UNAVAILABLE)}set mediaAirplayUnavailable(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_AIRPLAY_UNAVAILABLE,e)}handleClick(){let e=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_AIRPLAY_REQUEST,{composed:!0,bubbles:!0});this.dispatchEvent(e)}}ar.getSlotTemplateHTML=function(e){return` 286 <style> 287 :host([${iq.MediaUIAttributes.MEDIA_IS_AIRPLAYING}]) slot[name=icon] slot:not([name=exit]) { 288 display: none !important; 289 } 290 291 292 :host(:not([${iq.MediaUIAttributes.MEDIA_IS_AIRPLAYING}])) slot[name=icon] slot:not([name=enter]) { 293 display: none !important; 294 } 295 296 :host([${iq.MediaUIAttributes.MEDIA_IS_AIRPLAYING}]) slot[name=tooltip-enter], 297 :host(:not([${iq.MediaUIAttributes.MEDIA_IS_AIRPLAYING}])) slot[name=tooltip-exit] { 298 display: none; 299 } 300 </style> 301 302 <slot name="icon"> 303 <slot name="enter">${ai}</slot> 304 <slot name="exit">${ai}</slot> 305 </slot> 306 `},ar.getTooltipContentHTML=function(){return` 307 <slot name="tooltip-enter">${(0,ij.t)("start airplay")}</slot> 308 <slot name="tooltip-exit">${(0,ij.t)("stop airplay")}</slot> 309 `},i1.Mq.customElements.get("media-airplay-button")||i1.Mq.customElements.define("media-airplay-button",ar);var an=i(78766);let as=`<svg aria-hidden="true" viewBox="0 0 26 24"> 310 <path d="M22.83 5.68a2.58 2.58 0 0 0-2.3-2.5c-3.62-.24-11.44-.24-15.06 0a2.58 2.58 0 0 0-2.3 2.5c-.23 4.21-.23 8.43 0 12.64a2.58 2.58 0 0 0 2.3 2.5c3.62.24 11.44.24 15.06 0a2.58 2.58 0 0 0 2.3-2.5c.23-4.21.23-8.43 0-12.64Zm-11.39 9.45a3.07 3.07 0 0 1-1.91.57 3.06 3.06 0 0 1-2.34-1 3.75 3.75 0 0 1-.92-2.67 3.92 3.92 0 0 1 .92-2.77 3.18 3.18 0 0 1 2.43-1 2.94 2.94 0 0 1 2.13.78c.364.359.62.813.74 1.31l-1.43.35a1.49 1.49 0 0 0-1.51-1.17 1.61 1.61 0 0 0-1.29.58 2.79 2.79 0 0 0-.5 1.89 3 3 0 0 0 .49 1.93 1.61 1.61 0 0 0 1.27.58 1.48 1.48 0 0 0 1-.37 2.1 2.1 0 0 0 .59-1.14l1.4.44a3.23 3.23 0 0 1-1.07 1.69Zm7.22 0a3.07 3.07 0 0 1-1.91.57 3.06 3.06 0 0 1-2.34-1 3.75 3.75 0 0 1-.92-2.67 3.88 3.88 0 0 1 .93-2.77 3.14 3.14 0 0 1 2.42-1 3 3 0 0 1 2.16.82 2.8 2.8 0 0 1 .73 1.31l-1.43.35a1.49 1.49 0 0 0-1.51-1.21 1.61 1.61 0 0 0-1.29.58A2.79 2.79 0 0 0 15 12a3 3 0 0 0 .49 1.93 1.61 1.61 0 0 0 1.27.58 1.44 1.44 0 0 0 1-.37 2.1 2.1 0 0 0 .6-1.15l1.4.44a3.17 3.17 0 0 1-1.1 1.7Z"/> 311</svg>`,ao=`<svg aria-hidden="true" viewBox="0 0 26 24"> 312 <path d="M17.73 14.09a1.4 1.4 0 0 1-1 .37 1.579 1.579 0 0 1-1.27-.58A3 3 0 0 1 15 12a2.8 2.8 0 0 1 .5-1.85 1.63 1.63 0 0 1 1.29-.57 1.47 1.47 0 0 1 1.51 1.2l1.43-.34A2.89 2.89 0 0 0 19 9.07a3 3 0 0 0-2.14-.78 3.14 3.14 0 0 0-2.42 1 3.91 3.91 0 0 0-.93 2.78 3.74 3.74 0 0 0 .92 2.66 3.07 3.07 0 0 0 2.34 1 3.07 3.07 0 0 0 1.91-.57 3.17 3.17 0 0 0 1.07-1.74l-1.4-.45c-.083.43-.3.822-.62 1.12Zm-7.22 0a1.43 1.43 0 0 1-1 .37 1.58 1.58 0 0 1-1.27-.58A3 3 0 0 1 7.76 12a2.8 2.8 0 0 1 .5-1.85 1.63 1.63 0 0 1 1.29-.57 1.47 1.47 0 0 1 1.51 1.2l1.43-.34a2.8
3121 2.81 0 0 0-.74-1.32 2.94 2.94 0 0 0-2.13-.78 3.18 3.18 0 0 0-2.43 1 4 4 0 0 0-.92 2.78 3.74 3.74 0 0 0 .92 2.66 3.07 3.07 0 0 0 2.34 1 3.07 3.07 0 0 0 1.91-.57 3.23 3.23 0 0 0 1.07-1.74l-1.4-.45a2.06 2.06 0 0 1-.6 1.07Zm12.32-8.41a2.59 2.59 0 0 0-2.3-2.51C18.72 3.05 15.86 3 13 3c-2.86 0-5.72.05-7.53.17a2.59 2.59 0 0 0-2.3 2.51c-.23 4.207-.23 8.423 0 12.63a2.57 2.57 0 0 0 2.3 2.5c1.81.13 4.67.19 7.53.19 2.86 0 5.72-.06 7.53-.19a2.57 2.57 0 0 0 2.3-2.5c.23-4.207.23-8.423 0-12.63Zm-1.49 12.53a1.11 1.11 0 0 1-.91 1.11c-1.67.11-4.45.18-7.43.18-2.98 0-5.76-.07-7.43-.18a1.11 1.11 0 0 1-.91-1.11c-.21-4.14-.21-8.29 0-12.43a1.11 1.11 0 0 1 .91-1.11C7.24 4.56 10 4.49 13 4.49s5.76.07 7.43.18a1.11 1.11 0 0 1 .91 1.11c.21 4.14.21 8.29 0 12.43Z"/> 313</svg>`,al=e=>{e.setAttribute("aria-checked",(0,an.hi)(e).toString())};class ad extends at{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING]}connectedCallback(){super.connectedCallback(),this.setAttribute("role","button"),this.setAttribute("aria-label",(0,ij.t)("closed captions")),al(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING&&al(this)}get mediaSubtitlesList(){return au(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST)}set mediaSubtitlesList(e){ac(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST,e)}get mediaSubtitlesShowing(){return au(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING)}set mediaSubtitlesShowing(e){ac(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING,e)}handleClick(){this.dispatchEvent(new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_TOGGLE_SUBTITLES_REQUEST,{composed:!0,bubbles:!0}))}}ad.getSlotTemplateHTML=function(e){return` 314 <style> 315 :host([aria-checked="true"]) slot[name=off] { 316 display: none !important; 317 } 318 319 320 :host(:not([aria-checked="true"])) slot[name=on] { 321 display: none !important; 322 } 323 324 :host([aria-checked="true"]) slot[name=tooltip-enable], 325 :host(:not([aria-checked="true"])) slot[name=tooltip-disable] { 326 display: none; 327 } 328 </style> 329 330 <slot name="icon"> 331 <slot name="on">${as}</slot> 332 <slot name="off">${ao}</slot> 333 </slot> 334 `},ad.getTooltipContentHTML=function(){return` 335 <slot name="tooltip-enable">${(0,ij.t)("Enable captions")}</slot> 336 <slot name="tooltip-disable">${(0,ij.t)("Disable captions")}</slot> 337 `};let au=(e,t)=>{let i=e.getAttribute(t);return i?(0,an.tm)(i):[]},ac=(e,t,i)=>{if(!(null==i?void 0:i.length)){e.removeAttribute(t);return}let a=(0,an.fj)(i);e.getAttribute(t)!==a&&e.setAttribute(t,a)};i1.Mq.customElements.get("media-captions-button")||i1.Mq.customElements.define("media-captions-button",ad);let ah=e=>{let t=e.mediaIsCasting?(0,ij.t)("stop casting"):(0,ij.t)("start casting");e.setAttribute("aria-label",t)};class am extends at{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_IS_CASTING,iq.MediaUIAttributes.MEDIA_CAST_UNAVAILABLE]}connectedCallback(){super.connectedCallback(),ah(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_IS_CASTING&&ah(this)}get mediaIsCasting(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_IS_CASTING)}set mediaIsCasting(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_IS_CASTING,e)}get mediaCastUnavailable(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_CAST_UNAVAILABLE)}set mediaCastUnavailable(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_CAST_UNAVAILABLE,e)}handleClick(){let e=this.mediaIsCasting?iq.MediaUIEvents.MEDIA_EXIT_CAST_REQUEST:iq.MediaUIEvents.MEDIA_ENTER_CAST_REQUEST;this.dispatchEvent(new i1.Mq.CustomEvent(e,{composed:!0,bubbles:!0}))}}am.getSlotTemplateHTML=function(e){return` 338 <style> 339 :host([${iq.MediaUIAttributes.MEDIA_IS_CASTING}]) slot[name=icon] slot:not([name=exit]) { 340 display: none !important; 341 } 342 343 344 :host(:not([${iq.MediaUIAttributes.MEDIA_IS_CASTING}])) slot[name=icon] slot:not([name=enter]) { 345 display: none !important; 346 } 347 348 :host([${iq.MediaUIAttributes.MEDIA_IS_CASTING}]) slot[name=tooltip-enter], 349 :host(:not([${iq.MediaUIAttributes.MEDIA_IS_CASTING}])) slot[name=tooltip-exit] { 350 display: none; 351 } 352 </style> 353 354 <slot name="icon"> 355 <slot name="enter"><svg aria-hidden="true" viewBox="0 0 24 24"><g><path class="cast_caf_icon_arch0" d="M1,18 L1,21 L4,21 C4,19.3 2.66,18 1,18 L1,18 Z"/><path class="cast_caf_icon_arch1" d="M1,14 L1,16 C3.76,16 6,18.2 6,21 L8,21 C8,17.13 4.87,14 1,14 L1,14 Z"/><path class="cast_caf_icon_arch2" d="M1,10 L1,12 C5.97,12 10,16.0 10,21 L12,21 C12,14.92 7.07,10 1,10 L1,10 Z"/><path class="cast_caf_icon_box" d="M21,3 L3,3 C1.9,3 1,3.9 1,5 L1,8 L3,8 L3,5 L21,5 L21,19 L14,19 L14,21 L21,21 C22.1,21 23,20.1 23,19 L23,5 C23,3.9 22.1,3 21,3 L21,3 Z"/></g></svg></slot> 356 <slot name="exit"><svg aria-hidden="true" viewBox="0 0 24 24"><g><path class="cast_caf_icon_arch0" d="M1,18 L1,21 L4,21 C4,19.3 2.66,18 1,18 L1,18 Z"/><path class="cast_caf_icon_arch1" d="M1,14 L1,16 C3.76,16 6,18.2 6,21 L8,21 C8,17.13 4.87,14 1,14 L1,14 Z"/><path class="cast_caf_icon_arch2" d="M1,10 L1,12 C5.97,12 10,16.0 10,21 L12,21 C12,14.92 7.07,10 1,10 L1,10 Z"/><path class="cast_caf_icon_box" d="M21,3 L3,3 C1.9,3 1,3.9 1,5 L1,8 L3,8 L3,5 L21,5 L21,19 L14,19 L14,21 L21,21 C22.1,21 23,20.1 23,19 L23,5 C23,3.9 22.1,3 21,3 L21,3 Z"/><path class="cast_caf_icon_boxfill" d="M5,7 L5,8.63 C8,8.6 13.37,14 13.37,17 L19,17 L19,7 Z"/></g></svg></slot> 357 </slot> 358 `},am.getTooltipContentHTML=function(){return` 359 <slot name="tooltip-enter">${(0,ij.t)("Start casting")}</slot> 360 <slot name="tooltip-exit">${(0,ij.t)("Stop casting")}</slot> 361 `},i1.Mq.customElements.get("media-cast-button")||i1.Mq.customElements.define("media-cast-button",am);var ap=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},ab=(e,t,i)=>(ap(e,t,"read from private field"),i?i.call(e):t.get(e)),av=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},aE=(e,t,i,a)=>(ap(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),ag=(e,t,i)=>(ap(e,t,"access private method"),i);let af="open";class aA extends i1.Mq.HTMLElement{constructor(){super(),av(this,s8),av(this,s7),av(this,ot),av(this,oa),av(this,on),av(this,oo),av(this,s4,!1),av(this,s5,null),av(this,s9,null)}static get observedAttributes(){return[af,"anchor"]}get open(){return(0,i0.zc)(this,af)}set open(e){(0,i0.Pj)(this,af,e)}handleEvent(e){switch(e.type){case"invoke":ag(this,oa,or).call(this,e);break;case"focusout":ag(this,on,os).call(this,e);break;case"keydown":ag(this,oo,ol).call(this,e)}}connectedCallback(){ag(this,s8,s6).call(this),this.role||(this.role="dialog"),this.addEventListener("invoke",this),this.addEventListener("focusout",this),this.addEventListener("keydown",this)}disconnectedCallback(){this.removeEventListener("invoke",this),this.removeEventListener("focusout",this),this.removeEventListener("keydown",this)}attributeChangedCallback(e,t,i){ag(this,s8,s6).call(this),e===af&&i!==t&&(this.open?ag(this,s7,oe).call(this):ag(this,ot,oi).call(this))}focus(){aE(this,s5,(0,i0.vY)());let e=!this.dispatchEvent(new Event("focus",{composed:!0,cancelable:!0})),t=!this.dispatchEvent(new Event("focusin",{composed:!0,bubbles:!0,cancelable:!0}));if(e||t)return;
361let i=this.querySelector('[autofocus], [tabindex]:not([tabindex="-1"]), [role="menu"]');null==i||i.focus()}get keysUsed(){return["Escape","Tab"]}}s4=new WeakMap,s5=new WeakMap,s9=new WeakMap,s8=new WeakSet,s6=function(){if(!ab(this,s4)&&(aE(this,s4,!0),!this.shadowRoot)){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e),queueMicrotask(()=>{let{style:e}=(0,i0.R7)(this.shadowRoot,":host");e.setProperty("transition","display .15s, visibility .15s, opacity .15s ease-in, transform .15s ease-in")})}},s7=new WeakSet,oe=function(){var e;null==(e=ab(this,s9))||e.setAttribute("aria-expanded","true"),this.dispatchEvent(new Event("open",{composed:!0,bubbles:!0})),this.addEventListener("transitionend",()=>this.focus(),{once:!0})},ot=new WeakSet,oi=function(){var e;null==(e=ab(this,s9))||e.setAttribute("aria-expanded","false"),this.dispatchEvent(new Event("close",{composed:!0,bubbles:!0}))},oa=new WeakSet,or=function(e){aE(this,s9,e.relatedTarget),(0,i0.Mj)(this,e.relatedTarget)||(this.open=!this.open)},on=new WeakSet,os=function(e){var t;!(0,i0.Mj)(this,e.relatedTarget)&&(null==(t=ab(this,s5))||t.focus(),ab(this,s9)&&ab(this,s9)!==e.relatedTarget&&this.open&&(this.open=!1))},oo=new WeakSet,ol=function(e){var t,i,a,r,n;let{key:s,ctrlKey:o,altKey:l,metaKey:d}=e;!o&&!l&&!d&&this.keysUsed.includes(s)&&(e.preventDefault(),e.stopPropagation(),"Tab"===s?(e.shiftKey?null==(i=null==(t=this.previousElementSibling)?void 0:t.focus)||i.call(t):null==(r=null==(a=this.nextElementSibling)?void 0:a.focus)||r.call(a),this.blur()):"Escape"===s&&(null==(n=ab(this,s5))||n.focus(),this.open=!1))},aA.shadowRootOptions={mode:"open"},aA.getTemplateHTML=function(e){return` 362 <style> 363 :host { 364 font: var(--media-font, 365 var(--media-font-weight, normal) 366 var(--media-font-size, 14px) / 367 var(--media-text-content-height, var(--media-control-height, 24px)) 368 var(--media-font-family, helvetica neue, segoe ui, roboto, arial, sans-serif)); 369 color: var(--media-text-color, var(--media-primary-color, rgb(238 238 238))); 370 display: var(--media-dialog-display, inline-flex); 371 justify-content: center; 372 align-items: center; 373 374 transition-behavior: allow-discrete; 375 visibility: hidden; 376 opacity: 0; 377 transform: translateY(2px) scale(.99); 378 pointer-events: none; 379 } 380 381 :host([open]) { 382 transition: display .2s, visibility 0s, opacity .2s ease-out, transform .15s ease-out; 383 visibility: visible; 384 opacity: 1; 385 transform: translateY(0) scale(1); 386 pointer-events: auto; 387 } 388 389 #content { 390 display: flex; 391 position: relative; 392 box-sizing: border-box; 393 width: min(320px, 100%); 394 word-wrap: break-word; 395 max-height: 100%; 396 overflow: auto; 397 text-align: center; 398 line-height: 1.4; 399 } 400 </style> 401 ${this.getSlotTemplateHTML(e)} 402 `},aA.getSlotTemplateHTML=function(e){return` 403 <slot id="content"></slot> 404 `},i1.Mq.customElements.get("media-chrome-dialog")||i1.Mq.customElements.define("media-chrome-dialog",aA);var ay=i(13174),aT=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},ak=(e,t,i)=>(aT(e,t,"read from private field"),i?i.call(e):t.get(e)),aM=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},aI=(e,t,i,a)=>(aT(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),a_=(e,t,i)=>(aT(e,t,"access private method"),i);class aw extends i1.Mq.HTMLElement{constructor(){if(super(),aM(this,og),aM(this,oA),aM(this,oT),aM(this,oM),aM(this,o_),aM(this,oC),aM(this,oS),aM(this,oD),aM(this,od,void 0),aM(this,ou,void 0),aM(this,oc,void 0),aM(this,oh,void 0),aM(this,om,{}),aM(this,op,[]),aM(this,ob,()=>{if(this.range.matches(":focus-visible")){let{style:e}=(0,i0.R7)(this.shadowRoot,":host");e.setProperty("--_focus-visible-box-shadow","var(--_focus-box-shadow)")}}),aM(this,ov,()=>{let{style:e}=(0,i0.R7)(this.shadowRoot,":host");e.removeProperty("--_focus-visible-box-shadow")}),aM(this,oE,()=>{let e=this.shadowRoot.querySelector("#segments-clipping");e&&e.parentNode.append(e)}),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes),t=this.constructor.getTemplateHTML(e);this.shadowRoot.setHTMLUnsafe?this.shadowRoot.setHTMLUnsafe(t):this.shadowRoot.innerHTML=t}this.container=this.shadowRoot.querySelector("#container"),aI(this,oc,this.shadowRoot.querySelector("#startpoint")),aI(this,oh,this.shadowRoot.querySelector("#endpoint")),this.range=this.shadowRoot.querySelector("#range"),this.appearance=this.shadowRoot.querySelector("#appearance")}static get observedAttributes(){return["disabled","aria-disabled",iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER]}attributeChangedCallback(e,t,i){var a,r,n,s,o;e===iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER?(t&&(null==(r=null==(a=ak(this,od))?void 0:a.unassociateElement)||r.call(a,this),aI(this,od,null)),i&&this.isConnected&&(aI(this,od,null==(n=this.getRootNode())?void 0:n.getElementById(i)),null==(o=null==(s=ak(this,od))?void 0:s.associateElement)||o.call(s,this))):("disabled"===e||"aria-disabled"===e&&t!==i)&&(null==i?(this.range.removeAttribute(e),a_(this,oA,oy).call(this)):(this.range.setAttribute(e,i),a_(this,oT,ok).call(this)))}connectedCallback(){var e,t,i;let{style:a}=(0,i0.R7)(this.shadowRoot,":host");a.setProperty("display",`var(--media-control-display, var(--${this.localName}-display, inline-flex))`),ak(this,om).pointer=(0,i0.R7)(this.shadowRoot,"#pointer"),ak(this,om).progress=(0,i0.R7)(this.shadowRoot,"#progress"),ak(this,om).thumb=(0,i0.R7)(this.shadowRoot,'#thumb, ::slotted([slot="thumb"])'),ak(this,om).activeSegment=(0,i0.R7)(this.shadowRoot,"#segments-clipping rect:nth-child(0)");let r=this.getAttribute(iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER);r&&(aI(this,od,null==(e=this.getRootNode())?void 0:e.getElementById(r)),null==(i=null==(t=ak(this,od))?void 0:t.associateElement)||i.call(t,this)),this.updateBar(),this.shadowRoot.addEventListener("focusin",ak(this,ob)),this.shadowRoot.addEventListener("focusout",ak(this,ov)),a_(this,oA,oy).call(this),(0,ay.X)(this.container,ak(this,oE))}disconnectedCallback(){var e,t;a_(this,oT,ok).call(this),null==(t=null==(e=ak(this,od))?void 0:e.unassociateElement)||t.call(e,this),aI(this,od,null),this.shadowRoot.removeEventListener("focusin",ak(this,ob)),this.shadowRoot.removeEventListener("focusout",ak(this,ov)),(0,ay.U)(this.container,ak(this,oE))}updatePointerBar(e){var t;null==(t=ak(this,om).pointer)||t.style.setProperty("width",`${100*this.getPointerRatio(e)}%`)}updateBar(){var e,t;let i=100*this.range.valueAsNumber;null==(e=ak(this,om).progress)||e.style.setProperty("width",`${i}%`),null==(t=ak(this,om).thumb)||t.style.setProperty("left",`${i}%`)}updateSegments(e){let t=this.shadowRoot.querySelector("#segments-clipping");if(t.textContent="",this.container.classList.toggle("segments",!!(null==e?void 0:e.length)),!(null==e?void 0:e.length))return;let i=[...new Set([+this.range.min,...e.flatMap(e=>[e.start,e.end]),+this.range.max])];aI(this,op,[...i]);let a=i.pop();for(let[e,r]of i.entries()){let[n,s]=[0===e,e===i.length-1],o=n?"calc(var(--segments-gap) / -1)":`${100*r}%`,l=s?a:i[e+1],d=`calc(${(l-r)*100}%${n||s?"":" - var(--segments-gap)"})`,u=i1.tj.createElementNS("http://www.w3.org/2000/svg","rect"),c=(0,i0._l)(this.shadowRoot,`#segments-clipping rect:nth-child(${e+1})`);c.style.setProperty("x",o),c.style.setProperty("width",d),t.append(u)}}getPointerRatio(e){return(0,i0.Zo)(e.clientX,e.clientY,ak(this,oc).getBoundingClientRect(),ak(this,oh).getBoundingClientRect())}get dragging(){return this.hasAttribute("dragging")}handleEvent(e){switch(e.type){case"pointermove":a_(this,oD,ox).call(this,e);break;case"input":this.updateBar();break;case"pointerenter":a_(this,o_,ow).call(this,e);break;case"pointerdown":a_(this,oM,oI).call(this,e);break;case"pointerup":a_(this,oC,oR).call(this);break;case"pointerleave":a_(this,oS,oL).call(this)}}get keysUsed(){return["ArrowUp","ArrowRight","ArrowDown","ArrowLeft"]}}od=new WeakMap,ou=new WeakMap,oc=new WeakMap,oh=new WeakMap,om=new WeakMap,op=new WeakMap,ob=new WeakMap,ov=new WeakMap,oE=new WeakMap,og=new WeakSet,of=function(e){let t=ak(this,om).activeSegment;if(!t)return;let i=this.getPointerRatio(e),a=ak(this,op).findIndex((e,t,a)=>{let r=a[t+1];return null!=r&&i>=e&&i<=r}),r=`#segments-clipping rect:nth-child(${a+1})`;t.selectorText==r&&t.style.transform||(t.selectorText=r,t.style.setProperty("transform","var(--media-range-segment-hover-transform, scaleY(2))"))},oA=new WeakSet,oy=function(){!this.hasAttribute("disabled")&&this.isConnected&&(this.addEventListener("input",this),this.addEventListener("pointerdown",this),this.addEventListener("pointerenter",this))}
404,oT=new WeakSet,ok=function(){var e,t;this.removeEventListener("input",this),this.removeEventListener("pointerdown",this),this.removeEventListener("pointerenter",this),this.removeEventListener("pointerleave",this),null==(e=i1.Mq.window)||e.removeEventListener("pointerup",this),null==(t=i1.Mq.window)||t.removeEventListener("pointermove",this)},oM=new WeakSet,oI=function(e){var t;aI(this,ou,e.composedPath().includes(this.range)),null==(t=i1.Mq.window)||t.addEventListener("pointerup",this,{once:!0})},o_=new WeakSet,ow=function(e){var t;"mouse"!==e.pointerType&&a_(this,oM,oI).call(this,e),this.addEventListener("pointerleave",this,{once:!0}),null==(t=i1.Mq.window)||t.addEventListener("pointermove",this)},oC=new WeakSet,oR=function(){var e;null==(e=i1.Mq.window)||e.removeEventListener("pointerup",this),this.toggleAttribute("dragging",!1),this.range.disabled=this.hasAttribute("disabled")},oS=new WeakSet,oL=function(){var e,t;this.removeEventListener("pointerleave",this),null==(e=i1.Mq.window)||e.removeEventListener("pointermove",this),this.toggleAttribute("dragging",!1),this.range.disabled=this.hasAttribute("disabled"),null==(t=ak(this,om).activeSegment)||t.style.removeProperty("transform")},oD=new WeakSet,ox=function(e){("pen"!==e.pointerType||0!==e.buttons)&&(this.toggleAttribute("dragging",1===e.buttons||"mouse"!==e.pointerType),this.updatePointerBar(e),a_(this,og,of).call(this,e),this.dragging&&("mouse"!==e.pointerType||!ak(this,ou))&&(this.range.disabled=!0,this.range.valueAsNumber=this.getPointerRatio(e),this.range.dispatchEvent(new Event("input",{bubbles:!0,composed:!0}))))},aw.shadowRootOptions={mode:"open"},aw.getTemplateHTML=function(e){return
vendor: 7,165 bytes, lines 404-640
404` 405 <style> 406 :host { 407 --_focus-box-shadow: var(--media-focus-box-shadow, inset 0 0 0 2px rgb(27 127 204 / .9)); 408 --_media-range-padding: var(--media-range-padding, var(--media-control-padding, 10px)); 409 410 box-shadow: var(--_focus-visible-box-shadow, none); 411 background: var(--media-control-background, var(--media-secondary-color, rgb(20 20 30 / .7))); 412 height: calc(var(--media-control-height, 24px) + 2 * var(--_media-range-padding)); 413 display: inline-flex; 414 align-items: center; 415 416 vertical-align: middle; 417 box-sizing: border-box; 418 position: relative; 419 width: 100px; 420 transition: background .15s linear; 421 cursor: var(--media-cursor, pointer); 422 pointer-events: auto; 423 touch-action: none; 424 } 425 426 427 input[type=range]:focus { 428 outline: 0; 429 } 430 input[type=range]:focus::-webkit-slider-runnable-track { 431 outline: 0; 432 } 433 434 :host(:hover) { 435 background: var(--media-control-hover-background, rgb(50 50 70 / .7)); 436 } 437 438 #leftgap { 439 padding-left: var(--media-range-padding-left, var(--_media-range-padding)); 440 } 441 442 #rightgap { 443 padding-right: var(--media-range-padding-right, var(--_media-range-padding)); 444 } 445 446 #startpoint, 447 #endpoint { 448 position: absolute; 449 } 450 451 #endpoint { 452 right: 0; 453 } 454 455 #container { 456 457 width: var(--media-range-track-width, 100%); 458 transform: translate(var(--media-range-track-translate-x, 0px), var(--media-range-track-translate-y, 0px)); 459 position: relative; 460 height: 100%; 461 display: flex; 462 align-items: center; 463 min-width: 40px; 464 } 465 466 #range { 467 468 display: var(--media-time-range-hover-display, block); 469 bottom: var(--media-time-range-hover-bottom, 0); 470 height: var(--media-time-range-hover-height, max(100% , 25px)); 471 width: 100%; 472 position: absolute; 473 cursor: var(--media-cursor, pointer); 474 475 -webkit-appearance: none; 476 -webkit-tap-highlight-color: transparent; 477 background: transparent; 478 margin: 0; 479 z-index: 1; 480 } 481 482 @media (hover: hover) { 483 #range { 484 bottom: var(--media-time-range-hover-bottom, 0); 485 height: var(--media-time-range-hover-height, max(100%, 20px)); 486 } 487 } 488 489 490 491 #range::-webkit-slider-thumb { 492 -webkit-appearance: none; 493 background: transparent; 494 width: .1px; 495 height: .1px; 496 } 497 498 499 #range::-moz-range-thumb { 500 background: transparent; 501 border: transparent; 502 width: .1px; 503 height: .1px; 504 } 505 506 #appearance { 507 height: var(--media-range-track-height, 4px); 508 display: flex; 509 flex-direction: column; 510 justify-content: center; 511 width: 100%; 512 position: absolute; 513 514 will-change: transform; 515 } 516 517 #track { 518 background: var(--media-range-track-background, rgb(255 255 255 / .2)); 519 border-radius: var(--media-range-track-border-radius, 1px); 520 border: var(--media-range-track-border, none); 521 outline: var(--media-range-track-outline); 522 outline-offset: var(--media-range-track-outline-offset); 523 backdrop-filter: var(--media-range-track-backdrop-filter); 524 -webkit-backdrop-filter: var(--media-range-track-backdrop-filter); 525 box-shadow: var(--media-range-track-box-shadow, none); 526 position: absolute; 527 width: 100%; 528 height: 100%; 529 overflow: hidden; 530 } 531 532 #progress, 533 #pointer { 534 position: absolute; 535 height: 100%; 536 will-change: width; 537 } 538 539 #progress { 540 background: var(--media-range-bar-color, var(--media-primary-color, rgb(238 238 238))); 541 transition: var(--media-range-track-transition); 542 } 543 544 #pointer { 545 background: var(--media-range-track-pointer-background); 546 border-right: var(--media-range-track-pointer-border-right); 547 transition: visibility .25s, opacity .25s; 548 visibility: hidden; 549 opacity: 0; 550 } 551 552 @media (hover: hover) { 553 :host(:hover) #pointer { 554 transition: visibility .5s, opacity .5s; 555 visibility: visible; 556 opacity: 1; 557 } 558 } 559 560 #thumb, 561 ::slotted([slot=thumb]) { 562 width: var(--media-range-thumb-width, 10px); 563 height: var(--media-range-thumb-height, 10px); 564 transition: var(--media-range-thumb-transition); 565 transform: var(--media-range-thumb-transform, none); 566 opacity: var(--media-range-thumb-opacity, 1); 567 translate: -50%; 568 position: absolute; 569 left: 0; 570 cursor: var(--media-cursor, pointer); 571 } 572 573 #thumb { 574 border-radius: var(--media-range-thumb-border-radius, 10px); 575 background: var(--media-range-thumb-background, var(--media-primary-color, rgb(238 238 238))); 576 box-shadow: var(--media-range-thumb-box-shadow, 1px 1px 1px transparent); 577 border: var(--media-range-thumb-border, none); 578 } 579 580 :host([disabled]) #thumb { 581 background-color: #777; 582 } 583 584 .segments #appearance { 585 height: var(--media-range-segment-hover-height, 7px); 586 } 587 588 #track { 589 clip-path: url(#segments-clipping); 590 } 591 592 #segments { 593 --segments-gap: var(--media-range-segments-gap, 2px); 594 position: absolute; 595 width: 100%; 596 height: 100%; 597 } 598 599 #segments-clipping { 600 transform: translateX(calc(var(--segments-gap) / 2)); 601 } 602 603 #segments-clipping:empty { 604 display: none; 605 } 606 607 #segments-clipping rect { 608 height: var(--media-range-track-height, 4px); 609 y: calc((var(--media-range-segment-hover-height, 7px) - var(--media-range-track-height, 4px)) / 2); 610 transition: var(--media-range-segment-transition, transform .1s ease-in-out); 611 transform: var(--media-range-segment-transform, scaleY(1)); 612 transform-origin: center; 613 } 614 615 /* Visible label for accessibility - positioned off-screen but technically visible (Firefox requires visible labels) */ 616 #range-label { 617 position: absolute; 618 left: -10000px; 619 background: var(--media-control-background, var(--media-secondary-color, rgb(20 20 30 / .7))); 620 pointer-events: none; 621 } 622 </style> 623 <div id="leftgap"></div> 624 <div id="container"> 625 <div id="startpoint"></div> 626 <div id="endpoint"></div> 627 <div id="appearance"> 628 <div id="track" part="track"> 629 <div id="pointer"></div> 630 <div id="progress" part="progress"></div> 631 </div> 632 <slot name="thumb"> 633 <div id="thumb" part="thumb"></div> 634 </slot> 635 <svg id="segments" aria-hidden="true"><clipPath id="segments-clipping"></clipPath></svg> 636 </div> 637 <input id="range" type="range" min="0" max="1" step="any" value="0"> 638 <label for="range" id="range-label"></label> 639 640 ${this.getContainerTemplateHTML(
640e)} 641 </div> 642 <div id="rightgap"></div> 643 `},aw.getContainerTemplateHTML=function(e){return""},i1.Mq.customElements.get("media-chrome-range")||i1.Mq.customElements.define("media-chrome-range",aw);var aC=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},aR=(e,t,i)=>(aC(e,t,"read from private field"),i?i.call(e):t.get(e)),aS=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},aL=(e,t,i,a)=>(aC(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);class aD extends i1.Mq.HTMLElement{constructor(){if(super(),aS(this,oN,void 0),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}}static get observedAttributes(){return[iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER]}attributeChangedCallback(e,t,i){var a,r,n,s,o;e===iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER&&(t&&(null==(r=null==(a=aR(this,oN))?void 0:a.unassociateElement)||r.call(a,this),aL(this,oN,null)),i&&this.isConnected&&(aL(this,oN,null==(n=this.getRootNode())?void 0:n.getElementById(i)),null==(o=null==(s=aR(this,oN))?void 0:s.associateElement)||o.call(s,this)))}connectedCallback(){var e,t,i;let a=this.getAttribute(iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER);a&&(aL(this,oN,null==(e=this.getRootNode())?void 0:e.getElementById(a)),null==(i=null==(t=aR(this,oN))?void 0:t.associateElement)||i.call(t,this))}disconnectedCallback(){var e,t;null==(t=null==(e=aR(this,oN))?void 0:e.unassociateElement)||t.call(e,this),aL(this,oN,null)}}oN=new WeakMap,aD.shadowRootOptions={mode:"open"},aD.getTemplateHTML=function(e){return` 644 <style> 645 :host { 646 647 box-sizing: border-box; 648 display: var(--media-control-display, var(--media-control-bar-display, inline-flex)); 649 color: var(--media-text-color, var(--media-primary-color, rgb(238 238 238))); 650 --media-loading-indicator-icon-height: 44px; 651 } 652 653 ::slotted(media-time-range), 654 ::slotted(media-volume-range) { 655 min-height: 100%; 656 } 657 658 ::slotted(media-time-range), 659 ::slotted(media-clip-selector) { 660 flex-grow: 1; 661 } 662 663 ::slotted([role="menu"]) { 664 position: absolute; 665 } 666 </style> 667 668 <slot></slot> 669 `},i1.Mq.customElements.get("media-control-bar")||i1.Mq.customElements.define("media-control-bar",aD);var ax=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},aN=(e,t,i)=>(ax(e,t,"read from private field"),i?i.call(e):t.get(e)),aO=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},aP=(e,t,i,a)=>(ax(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);class aU extends i1.Mq.HTMLElement{constructor(){if(super(),aO(this,oO,void 0),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}}static get observedAttributes(){return[iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER]}attributeChangedCallback(e,t,i){var a,r,n,s,o;e===iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER&&(t&&(null==(r=null==(a=aN(this,oO))?void 0:a.unassociateElement)||r.call(a,this),aP(this,oO,null)),i&&this.isConnected&&(aP(this,oO,null==(n=this.getRootNode())?void 0:n.getElementById(i)),null==(o=null==(s=aN(this,oO))?void 0:s.associateElement)||o.call(s,this)))}connectedCallback(){var e,t,i;let{style:a}=(0,i0.R7)(this.shadowRoot,":host");a.setProperty("display",`var(--media-control-display, var(--${this.localName}-display, inline-flex))`);let r=this.getAttribute(iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER);r&&(aP(this,oO,null==(e=this.getRootNode())?void 0:e.getElementById(r)),null==(i=null==(t=aN(this,oO))?void 0:t.associateElement)||i.call(t,this))}disconnectedCallback(){var e,t;null==(t=null==(e=aN(this,oO))?void 0:e.unassociateElement)||t.call(e,this),aP(this,oO,null)}}oO=new WeakMap,aU.shadowRootOptions={mode:"open"},aU.getTemplateHTML=function(e,t={}){return` 670 <style> 671 :host { 672 font: var(--media-font, 673 var(--media-font-weight, normal) 674 var(--media-font-size, 14px) / 675 var(--media-text-content-height, var(--media-control-height, 24px)) 676 var(--media-font-family, helvetica neue, segoe ui, roboto, arial, sans-serif)); 677 color: var(--media-text-color, var(--media-primary-color, rgb(238 238 238))); 678 background: var(--media-text-background, var(--media-control-background, var(--media-secondary-color, rgb(20 20 30 / .7)))); 679 padding: var(--media-control-padding, 10px); 680 display: inline-flex; 681 justify-content: center; 682 align-items: center; 683 vertical-align: middle; 684 box-sizing: border-box; 685 text-align: center; 686 pointer-events: auto; 687 } 688 689 690 :host(:focus-visible) {
691 box-shadow: var(--media-focus-box-shadow, inset 0 0 0 2px rgb(27 127 204 / .9)); 692 outline: 0; 693 } 694 695 696 :host(:where(:focus)) { 697 box-shadow: none; 698 outline: 0; 699 } 700 </style> 701 702 ${this.getSlotTemplateHTML(e,t)} 703 `},aU.getSlotTemplateHTML=function(e,t){return` 704 <slot></slot> 705 `},i1.Mq.customElements.get("media-text-display")||i1.Mq.customElements.define("media-text-display",aU);var aW=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},a$=(e,t,i)=>(aW(e,t,"read from private field"),i?i.call(e):t.get(e)),aB=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},aH=(e,t,i,a)=>(aW(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);class aV extends aU{constructor(){var e;super(),aB(this,oP,void 0),aH(this,oP,this.shadowRoot.querySelector("slot")),a$(this,oP).textContent=iQ(null!=(e=this.mediaDuration)?e:0)}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_DURATION]}attributeChangedCallback(e,t,i){e===iq.MediaUIAttributes.MEDIA_DURATION&&(a$(this,oP).textContent=iQ(+i)),super.attributeChangedCallback(e,t,i)}get mediaDuration(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_DURATION)}set mediaDuration(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_DURATION,e)}}oP=new WeakMap,aV.getSlotTemplateHTML=function(e,t){return` 706 <slot>${iQ(t.mediaDuration)}</slot> 707 `},i1.Mq.customElements.get("media-duration-display")||i1.Mq.customElements.define("media-duration-display",aV);let aK={2:(0,ij.t)("Network Error"),3:(0,ij.t)("Decode Error"),4:(0,ij.t)("Source Not Supported"),5:(0,ij.t)("Encryption
707Error")},aF={2:(0,ij.t)("A network error caused the media download to fail."),3:(0,ij.t)("A media error caused playback to be aborted. The media could be corrupt or your browser does not support this format."),4:(0,ij.t)("An unsupported error occurred. The server or network failed, or your browser does not support this format."),5:(0,ij.t)("The media is encrypted and there are no keys to decrypt it.")},aY=e=>{var t,i;return 1===e.code?null:{title:null!=(t=aK[e.code])?t:`Error ${e.code}`,message:null!=(i=aF[e.code])?i:e.message}};var aq=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},aG=(e,t,i)=>(aq(e,t,"read from private field"),i?i.call(e):t.get(e)),aj=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},aZ=(e,t,i,a)=>(aq(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);function az(e){var t;let{title:i,message:a}=null!=(t=aY(e))?t:{},r="";return i&&(r+=`<slot name="error-${e.code}-title"><h3>${i}</h3></slot>`),a&&(r+=`<slot name="error-${e.code}-message"><p>${a}</p></slot>`),r}let aX=[iq.MediaUIAttributes.MEDIA_ERROR_CODE,iq.MediaUIAttributes.MEDIA_ERROR_MESSAGE];class aQ extends aA{constructor(){super(...arguments),aj(this,oU,null)}static get observedAttributes(){return[...super.observedAttributes,...aX]}formatErrorMessage(e){return this.constructor.formatErrorMessage(e)}attributeChangedCallback(e,t,i){var a;if(super.attributeChangedCallback(e,t,i),!aX.includes(e))return;let r=null!=(a=this.mediaError)?a:{code:this.mediaErrorCode,message:this.mediaErrorMessage};if(this.open=r.code&&null!==aY(r),this.open&&(this.shadowRoot.querySelector("slot").name=`error-${this.mediaErrorCode}`,this.shadowRoot.querySelector("#content").innerHTML=this.formatErrorMessage(r),!this.hasAttribute("aria-label"))){let{title:e}=aY(r);e&&this.setAttribute("aria-label",e)}}get mediaError(){return aG(this,oU)}set mediaError(e){aZ(this,oU,e)}get mediaErrorCode(){return(0,i0.Uf)(this,"mediaerrorcode")}set mediaErrorCode(e){(0,i0.AI)(this,"mediaerrorcode",e)}get mediaErrorMessage(){return(0,i0.ST)(this,"mediaerrormessage")}set mediaErrorMessage(e){(0,i0.Lb)(this,"mediaerrormessage",e)}}oU=new WeakMap,aQ.getSlotTemplateHTML=function(e){return` 708 <style> 709 :host { 710 background: rgb(20 20 30 / .8); 711 } 712 713 #content { 714 display: block; 715 padding: 1.2em 1.5em; 716 } 717 718 h3, 719 p { 720 margin-block: 0 .3em; 721 } 722 </style> 723 <slot name="error-${e.mediaerrorcode}" id="content"> 724 ${az({code:+e.mediaerrorcode,message:e.mediaerrormessage})} 725 </slot> 726 `},aQ.formatErrorMessage=az,i1.Mq.customElements.get("media-error-dialog")||i1.Mq.customElements.define("media-error-dialog",aQ);var aJ=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},a0=(e,t,i)=>(aJ(e,t,"read from private field"),i?i.call(e):t.get(e)),a1=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)};class a2 extends aA{constructor(){super(...arguments),a1(this,oW,e=>{var t;if(!this.open)return;let i=null==(t=this.shadowRoot)?void 0:t.querySelector("#content");if(!i)return;let a=e.composedPath(),r=a[0]===this||a.includes(this),n=a.includes(i);r&&!n&&(this.open=!1)}),a1(this,o$,e=>{if(!this.open)return;let t=e.shiftKey&&("/"===e.key||"?"===e.key);"Escape"!==e.key&&!t||e.ctrlKey||e.altKey||e.metaKey||(this.open=!1,e.preventDefault(),e.stopPropagation())})}connectedCallback(){super.connectedCallback(),this.open&&(this.addEventListener("click",a0(this,oW)),document.addEventListener("keydown",a0(this,o$)))}disconnectedCallback(){this.removeEventListener("click",a0(this,oW)),document.removeEventListener("keydown",a0(this,o$))}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),"open"===e&&(this.open?(this.addEventListener("click",a0(this,oW)),document.addEventListener("keydown",a0(this,o$))):(this.removeEventListener("click",a0(this,oW)),document.removeEventListener("keydown",a0(this,o$))))}}oW=new WeakMap,o$=new WeakMap,a2.getSlotTemplateHTML=function(e){return` 727 <style> 728 :host { 729 position: fixed; 730 top: 0; 731 left: 0; 732 z-index: 9999; 733 background: rgb(20 20 30 / .8); 734 backdrop-filter: blur(10px); 735 } 736 737 #content { 738 display: block; 739 width: clamp(400px, 40vw, 700px); 740 max-width: 90vw; 741 text-align: left; 742 } 743 744 h2 { 745 margin: 0 0 1.5rem 0; 746 font-size: 1.5rem; 747 font-weight: 500; 748 text-align: center; 749 } 750 751 .shortcuts-table { 752 width: 100%; 753 border-collapse: collapse; 754 } 755 756 .shortcuts-table tr { 757 border-bottom: 1px solid rgba(255, 255, 255, 0.1); 758 } 759 760 .shortcuts-table tr:last-child { 761 border-bottom: none; 762 } 763 764 .shortcuts-table td { 765 padding: 0.75rem 0.5rem; 766 } 767 768 .shortcuts-table td:first-child { 769 text-align: right; 770 padding-right: 1rem; 771 width: 40%; 772 min-width: 120px; 773 } 774 775 .shortcuts-table td:last-child { 776 padding-left: 1rem; 777 } 778 779 .key { 780 display: inline-block; 781 background: rgba(255, 255, 255, 0.15); 782 border: 1px solid rgba(255, 255, 255, 0.2); 783 border-radius: 4px; 784 padding: 0.25rem 0.5rem; 785 font-family: 'Courier New', monospace; 786 font-size: 0.9rem; 787 font-weight: 500; 788 min-width: 1.5rem; 789 text-align: center; 790 margin: 0 0.2rem; 791 } 792 793 .description { 794 color: rgba(255, 255, 255, 0.9); 795 font-size: 0.95rem; 796 } 797 798 .key-combo { 799 display: flex; 800 align-items: center; 801 justify-content: flex-end; 802 gap: 0.3rem; 803 } 804 805 .key-separator { 806 color: rgba(255, 255, 255, 0.5); 807 font-size: 0.9rem; 808 } 809 </style> 810 <slot id="content"> 811 ${function(){let e=[{keys:["Space","k"],description:"Toggle Playback"},{keys:["m"],description:"Toggle mute"},{keys:["f"],description:"Toggle fullscreen"},{keys:["c"],description:"Toggle captions or subtitles, if available"},{keys:["p"],description:"Toggle Picture in Picture"},{keys:["â","j"],description:"Seek back 10s"},{keys:["â","l"],description:"Seek forward 10s"},{keys:["â"],description:"Turn volume up"},{keys:["â"],description:"Turn volume down"},{keys:["< (SHIFT+,)"],description:"Decrease playback rate"},{keys:["> (SHIFT+.)"],description:"Increase playback rate"}].map(({keys:e,description:t})=>{let i=e.map((e,t)=>t>0?`<span class="key-separator">or</span><span class="key">${e}</span>`:`<span class="key">${e}</span>`).join("");return` 812 <tr> 813 <td> 814 <div class="key-combo">${i}</div> 815 </td> 816 <td class="description">${t}</td> 817 </tr> 818 `}).join("");return` 819 <h2>Keyboard Shortcuts</h2> 820 <table class="shortcuts-table">${e}</table> 821 `}()} 822 </slot> 823 `},i1.Mq.customElements.get("media-keyboard-shortcuts-dialog")||i1.Mq.customElements.define("media-keyboard-shortcuts-dialog",a2);var a3=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},a4=(e,t,i)=>(a3(e,t,"read from private field"),i?i.call(e):t.get(e)),a5=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},a9=(e,t,i,a)=>(a3(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);let a8=`<svg aria-hidden="true" viewBox="0 0 26 24"> 824 <path d="M16 3v2.5h3.5V9H22V3h-6ZM4 9h2.5V5.5H10V3H4v6Zm15.5 9.5H16V21h6v-6h-2.5v3.5ZM6.5 15H4v6h6v-2.5H6.5V15Z"/> 825</svg>`,a6=`<svg aria-hidden="true" viewBox="0 0 26 24"> 826 <path d="M18.5 6.5V3H16v6h6V6.5h-3.5ZM16 21h2.5v-3.5H22V15h-6v6ZM4 17.5h3.5V21H10v-6H4v2.5Zm3.5-11H4V9h6V3H7.5v3.5Z"/> 827</svg>`,a7=e=>{let t=e.mediaIsFullscreen?(0,ij.t)("exit fullscreen mode"):(0,ij.t)("enter fullscreen mode");e.setAttribute("aria-label",t)};class re extends at{constructor(){super(...arguments),a5(this,oB,null)}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN,iq.MediaUIAttributes.MEDIA_FULLSCREEN_UNAVAILABLE]}connectedCallback(){super.connectedCallback(),a7(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN&&a7(this)}get mediaFullscreenUnavailable(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_FULLSCREEN_UNAVAILABLE)}set mediaFullscreenUnavailable(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_FULLSCREEN_UNAVAILABLE,e)}get mediaIsFullscreen(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN)}set mediaIsFullscreen(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN,e)}handleClick(e){a9(this,oB,e);let t=a4(this,oB) instanceof PointerEvent,i=this.mediaIsFullscreen?new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_EXIT_FULLSCREEN_REQUEST,{composed:!0,bubbles:!0}):new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_ENTER_FULLSCREEN_REQUEST,{composed:!0,bubbles:!0,detail:t});this.dispatchEvent(i)}}oB=new WeakMap,re.getSlotTemplateHTML=function(e){return` 828 <style> 829 :host([${iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN}]) slot[name=icon] slot:not([name=exit]) { 830 display: none !important; 831 } 832 833 834 :host(:not([${iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN}])) slot[name=icon] slot:not([name=enter]) { 835 display: none !important; 836 } 837 838 :host([${iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN}]) slot[name=tooltip-enter], 839 :host(:not([${iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN}])) slot[name=tooltip-exit] { 840 display: none; 841 } 842 </style> 843 844 <slot name="icon"> 845 <slot name="enter">${a8}</slot> 846 <slot name="exit">${a6}</slot> 847 </slot> 848 `},re.getTooltipContentHTML=function(){return` 849 <slot name="tooltip-enter">${(0,ij.t)("Enter fullscreen mode")}</slot> 850 <slot name="tooltip-exit">${(0,ij.t)("Exit fullscreen mode")}</slot> 851 `},i1.Mq.customElements.get("media-fullscreen-button")||i1.Mq.customElements.define("media-fullscreen-button",re),i(42046);let{MEDIA_TIME_IS_LIVE:rt,MEDIA_PAUSED:ri}=iq.MediaUIAttributes,{MEDIA_SEEK_TO_LIVE_REQUEST:ra,MEDIA_PLAY_REQUEST:rr}=iq.MediaUIEvents,rn=e=>{var t;let i=e.mediaPaused||!e.mediaTimeIsLive,a=i?(0,ij.t)("seek to live"):(0,ij.t)("playing live");e.setAttribute("aria-label",a);let r=null==(t=e.shadowRoot)?void 0:t.querySelector('slot[name="text"]');r&&(r.textContent=(0,ij.t)("live")),i?e.removeAttribute("aria-disabled"):e.setAttribute("aria-disabled","true")};class rs extends at{static get observedAttributes(){return[...super.observedAttributes,rt,ri]}connectedCallback(){super.connectedCallback(),rn(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),rn(this)}get mediaPaused(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_PAUSED)}set mediaPaused(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_PAUSED,e)}get mediaTimeIsLive(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_TIME_IS_LIVE)}set mediaTimeIsLive(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_TIME_IS_LIVE,e)}handleClick(){(this.mediaPaused||!this.mediaTimeIsLive)&&(this.dispatchEvent(new i1.Mq.CustomEvent(ra,{composed:!0,bubbles:!0})),this.hasAttribute(ri)&&this.dispatchEvent(new i1.Mq.CustomEvent(rr,{composed:!0,bubbles:!0})))}}rs.getSlotTemplateHTML=function(e){return` 852 <style> 853 :host { --media-tooltip-display: none; } 854 855 slot[name=indicator] > *, 856 :host ::slotted([slot=indicator]) { 857 858 min-width: auto; 859 fill: var(--media-live-button-icon-color, rgb(140, 140, 140)); 860 color: var(--media-live-button-icon-color, rgb(140, 140, 140)); 861 } 862 863 :host([${rt}]:not([${ri}])) slot[name=indicator] > *, 864 :host([${rt}]:not([${ri}])) ::slotted([slot=indicator]) { 865 fill: var(--media-live-button-indicator-color, rgb(255, 0, 0)); 866 color: var(--media-live-button-indicator-color, rgb(255, 0, 0)); 867 } 868 869 :host([${rt}]:not([${ri}])) { 870 cursor: var(--media-cursor, not-allowed); 871 } 872 873 slot[name=text]{ 874 text-transform: uppercase; 875 } 876 877 </style> 878 879 <slot name="indicator"><svg viewBox="0 0 6 12" aria-hidden="true"><circle cx="3" cy="6" r="2"></circle></svg></slot> 880 881 <slot name="spacer"> </slot><slot name="text">${(0,ij.t)("live")}</slot> 882 `},i1.Mq.customElements.get("media-live-button")||i1.Mq.customElements.define("media-live-button",rs);var ro=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},rl=(e,t,i)=>(ro(e,t,"read from private field"),i?i.call(e):t.get(e)),rd=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},ru=(e,t,i,a)=>(ro(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);let rc="loadingdelay",rh="noautohide",rm=` 883<svg aria-hidden="true" viewBox="0 0 100 100"> 884 <path d="M73,50c0-12.7-10.3-23-23-23S27,37.3,27,50 M30.9,50c0-10.5,8.5-19.1,19.1-19.1S69.1,39.5,69.1,50"> 885 <animateTransform 886 attributeName="transform" 887 attributeType="XML" 888 type="rotate" 889 dur="1s" 890 from="0 50 50" 891 to="360 50 50"
892 repeatCount="indefinite" /> 893 </path> 894</svg> 895`;class rp extends i1.Mq.HTMLElement{constructor(){if(super(),rd(this,oH,void 0),rd(this,oV,500),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}}static get observedAttributes(){return[iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER,iq.MediaUIAttributes.MEDIA_PAUSED,iq.MediaUIAttributes.MEDIA_LOADING,rc]}attributeChangedCallback(e,t,i){var a,r,n,s,o;e===rc&&t!==i?this.loadingDelay=Number(i):e===iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER&&(t&&(null==(r=null==(a=rl(this,oH))?void 0:a.unassociateElement)||r.call(a,this),ru(this,oH,null)),i&&this.isConnected&&(ru(this,oH,null==(n=this.getRootNode())?void 0:n.getElementById(i)),null==(o=null==(s=rl(this,oH))?void 0:s.associateElement)||o.call(s,this)))}connectedCallback(){var e,t,i;let a=this.getAttribute(iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER);a&&(ru(this,oH,null==(e=this.getRootNode())?void 0:e.getElementById(a)),null==(i=null==(t=rl(this,oH))?void 0:t.associateElement)||i.call(t,this))}disconnectedCallback(){var e,t;null==(t=null==(e=rl(this,oH))?void 0:e.unassociateElement)||t.call(e,this),ru(this,oH,null)}get loadingDelay(){return rl(this,oV)}set loadingDelay(e){ru(this,oV,e);let{style:t}=(0,i0.R7)(this.shadowRoot,":host");t.setProperty("--_loading-indicator-delay",`var(--media-loading-indicator-transition-delay, ${e}ms)`)}get mediaPaused(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_PAUSED)}set mediaPaused(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_PAUSED,e)}get mediaLoading(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_LOADING)}set mediaLoading(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_LOADING,e)}get mediaController(){return(0,i0.ST)(this,iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER)}set mediaController(e){(0,i0.Lb)(this,iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER,e)}get noAutohide(){return(0,i0.zc)(this,rh)}set noAutohide(e){(0,i0.Pj)(this,rh,e)}}oH=new WeakMap,oV=new WeakMap,rp.shadowRootOptions={mode:"open"},rp.getTemplateHTML=function(e){return` 896 <style> 897 :host { 898 display: var(--media-control-display, var(--media-loading-indicator-display, inline-block)); 899 vertical-align: middle; 900 box-sizing: border-box; 901 --_loading-indicator-delay: var(--media-loading-indicator-transition-delay, 500ms); 902 } 903 904 #status { 905 color: rgba(0,0,0,0); 906 width: 0px; 907 height: 0px; 908 } 909 910 :host slot[name=icon] > *, 911 :host ::slotted([slot=icon]) { 912 opacity: var(--media-loading-indicator-opacity, 0); 913 transition: opacity 0.15s; 914 } 915 916 :host([${iq.MediaUIAttributes.MEDIA_LOADING}]:not([${iq.MediaUIAttributes.MEDIA_PAUSED}])) slot[name=icon] > *, 917 :host([${iq.MediaUIAttributes.MEDIA_LOADING}]:not([${iq.MediaUIAttributes.MEDIA_PAUSED}])) ::slotted([slot=icon]) { 918 opacity: var(--media-loading-indicator-opacity, 1); 919 transition: opacity 0.15s var(--_loading-indicator-delay); 920 } 921 922 :host #status { 923 visibility: var(--media-loading-indicator-opacity, hidden); 924 transition: visibility 0.15s; 925 } 926 927 :host([${iq.MediaUIAttributes.MEDIA_LOADING}]:not([${iq.MediaUIAttributes.MEDIA_PAUSED}])) #status { 928 visibility: var(--media-loading-indicator-opacity, visible); 929 transition: visibility 0.15s var(--_loading-indicator-delay); 930 } 931 932 svg, img, ::slotted(svg), ::slotted(img) { 933 width: var(--media-loading-indicator-icon-width); 934 height: var(--media-loading-indicator-icon-height, 100px); 935 fill: var(--media-icon-color, var(--media-primary-color, rgb(238 238 238))); 936 vertical-align: middle; 937 } 938 </style> 939 940 <slot name="icon">${rm}</slot> 941 <div id="status" role="status" aria-live="polite">${(0,ij.t)("media loading")}</div> 942 `},i1.Mq.customElements.get("media-loading-indicator")||i1.Mq.customElements.define("media-loading-indicator",rp);let rb=`<svg aria-hidden="true" viewBox="0 0 24 24"> 943 <path d="M16.5 12A4.5 4.5 0 0 0 14 8v2.18l2.45 2.45a4.22 4.22 0 0 0 .05-.63Zm2.5 0a6.84 6.84 0 0 1-.54 2.64L20 16.15A8.8 8.8 0 0 0 21 12a9 9 0 0 0-7-8.77v2.06A7 7 0 0 1 19 12ZM4.27 3 3 4.27 7.73 9H3v6h4l5 5v-6.73l4.25 4.25A6.92 6.92 0 0 1 14 18.7v2.06A9 9 0 0 0 17.69 19l2 2.05L21 19.73l-9-9L4.27 3ZM12 4 9.91 6.09 12 8.18V4Z"/> 944</svg>`,rv=`<svg aria-hidden="true" viewBox="0 0 24 24"> 945 <path d="M3 9v6h4l5 5V4L7 9H3Zm13.5 3A4.5 4.5 0 0 0 14 8v8a4.47 4.47 0 0 0 2.5-4Z"/> 946</svg>`,rE=`<svg aria-hidden="true" viewBox="0 0 24 24"> 947 <path d="M3 9v6h4l5 5V4L7 9H3Zm13.5 3A4.5 4.5 0 0 0 14 8v8a4.47 4.47 0 0 0 2.5-4ZM14 3.23v2.06a7 7 0 0 1 0 13.42v2.06a9 9 0 0 0 0-17.54Z"/> 948</svg>`,rg=e=>{let t="off"===e.mediaVolumeLevel?(0,ij.t)("unmute"):(0,ij.t)("mute");e.setAttribute("aria-label",t)};class rf extends at{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL]}connectedCallback(){super.connectedCallback(),rg(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL&&rg(this)}get mediaVolumeLevel(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL)}set mediaVolumeLevel(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL,e)}handleClick(){let e="off"===this.mediaVolumeLevel?iq.MediaUIEvents.MEDIA_UNMUTE_REQUEST:iq.MediaUIEvents.MEDIA_MUTE_REQUEST;this.dispatchEvent(new i1.Mq.CustomEvent(e,{composed:!0,bubbles:!0}))}}rf.getSlotTemplateHTML=function(e){return` 949 <style> 950 :host(:not([${iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL}])) slot[name=icon] slot:not([name=high]), 951 :host([${iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL}=high]) slot[name=icon] slot:not([name=high]) { 952 display: none !important; 953 } 954 955 :host([${iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL}=off]) slot[name=icon] slot:not([name=off]) { 956 display: none !important; 957 } 958 959 :host([${iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL}=low]) slot[name=icon] slot:not([name=low]) { 960 display: none !important; 961 } 962 963 :host([${iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL}=medium]) slot[name=icon] slot:not([name=medium]) { 964 display: none !important; 965 } 966 967 :host(:not([${iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL}=off])) slot[name=tooltip-unmute], 968 :host([${iq.MediaUIAttributes.MEDIA_VOLUME_LEVEL}=off]) slot[name=tooltip-mute] { 969 display: none; 970 } 971 </style> 972 973 <slot name="icon"> 974 <slot name="off">${rb}</slot> 975 <slot name="low">${rv}</slot> 976 <slot name="medium">${rv}</slot> 977 <slot name="high">${rE}</slot> 978 </slot> 979 `},rf.getTooltipContentHTML=function(){return` 980 <slot name="tooltip-mute">${(0,ij.t)("Mute")}</slot> 981 <slot name="tooltip-unmute">${(0,ij.t)("Unmute")}</slot> 982 `},i1.Mq.customElements.get("media-mute-button")||i1.Mq.customElements.define("media-mute-button",rf);let rA=`<svg aria-hidden="true" viewBox="0 0 28 24"> 983 <path d="M24 3H4a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h20a1 1 0 0 0 1-1V4a1 1 0 0 0-1-1Zm-1 16H5V5h18v14Zm-3-8h-7v5h7v-5Z"/> 984</svg>`,ry=e=>{let t=e.mediaIsPip?(0,ij.t)("exit picture in picture mode"):(0,ij.t)("enter picture in picture mode");e.setAttribute("aria-label",t)};class rT extends at{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_IS_PIP,iq.MediaUIAttributes.MEDIA_PIP_UNAVAILABLE]}connectedCallback(){super.connectedCallback(),ry(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_IS_PIP&&ry(this)}get mediaPipUnavailable(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_PIP_UNAVAILABLE)}set mediaPipUnavailable(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_PIP_UNAVAILABLE,e)}get mediaIsPip(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_IS_PIP)}set mediaIsPip(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_IS_PIP,e)}handleClick(){let e=this.mediaIsPip?iq.MediaUIEvents.MEDIA_EXIT_PIP_REQUEST:iq.MediaUIEvents.MEDIA_ENTER_PIP_REQUEST;this.dispatchEvent(new i1.Mq.CustomEvent(e,{composed:!0,bubbles:!0}))}}rT.getSlotTemplateHTML=function(e){return` 985 <style> 986 :host([${iq.MediaUIAttributes.MEDIA_IS_PIP}]) slot[name=icon] slot:not([name=exit]) { 987 display: none !important; 988 } 989 990 :host(:not([${iq.MediaUIAttributes.MEDIA_IS_PIP}])) slot[name=icon] slot:not([name=enter]) { 991 display: none !important; 992 } 993 994 :host([${iq.MediaUIAttributes.MEDIA_IS_PIP}]) slot[name=tooltip-enter], 995 :host(:not([${iq.MediaUIAttributes.MEDIA_IS_PIP}])) slot[name=tooltip-exit] { 996 display: none; 997 } 998 </style> 999 1000 <slot name="icon"> 1001 <slot name="enter">${rA}</slot> 1002 <slot name="exit">${rA}</slot> 1003 </slot> 1004 `},rT.getTooltipContentHTML=function(){return` 1005 <slot name="tooltip-enter">${(0,ij.t)("Enter picture in picture mode")}</slot> 1006 <slot name="tooltip-exit">${(0,ij.t)("Exit picture in picture mode")}</slot> 1007 `},i1.Mq.customElements.get("media-pip-button")||i1.Mq.customElements.define("media-pip-button",rT);var rk=i(37559),rM=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},rI=(e,t,i)=>(rM(e,t,"read from private field"),i?i.call(e):t.get(e)),r_=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)};let rw="rates",rC=[1,1.2,1.5,1.7,2];function rR(e){return Math.round(100*e)/100}class rS extends at{constructor(){var e;
1007super(),r_(this,oK,new rk.D(this,rw,{defaultValue:rC})),this.container=this.shadowRoot.querySelector('slot[name="icon"]'),this.container.innerHTML=`${rR(null!=(e=this.mediaPlaybackRate)?e:1)}x`}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,rw]}attributeChangedCallback(e,t,i){if(super.attributeChangedCallback(e,t,i),e===rw&&(rI(this,oK).value=i),e===iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE){let e=i?+i:Number.NaN,t=rR(Number.isNaN(e)?1:e);this.container.innerHTML=`${t}x`,this.setAttribute("aria-label",(0,ij.t)("Playback rate {playbackRate}",{playbackRate:t}))}}get rates(){return rI(this,oK)}set rates(e){e?Array.isArray(e)?rI(this,oK).value=e.join(" "):"string"==typeof e&&(rI(this,oK).value=e):rI(this,oK).value=""}get mediaPlaybackRate(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,1)}set mediaPlaybackRate(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,e)}handleClick(){var e,t;let i=Array.from(rI(this,oK).values(),e=>+e).sort((e,t)=>e-t),a=null!=(t=null!=(e=i.find(e=>e>this.mediaPlaybackRate))?e:i[0])?t:1,r=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_PLAYBACK_RATE_REQUEST,{composed:!0,bubbles:!0,detail:a});this.dispatchEvent(r)}}oK=new WeakMap,rS.getSlotTemplateHTML=function(e){let t=e.mediaplaybackrate?rR(+e.mediaplaybackrate):1;return` 1008 <style> 1009 :host { 1010 min-width: 5ch; 1011 padding: var(--media-button-padding, var(--media-control-padding, 10px 5px)); 1012 } 1013 </style> 1014 <slot name="icon">${t}x</slot> 1015 `},rS.getTooltipContentHTML=function(){return(0,ij.t)("Playback rate")},i1.Mq.customElements.get("media-playback-rate-button")||i1.Mq.customElements.define("media-playback-rate-button",rS);let rL=`<svg aria-hidden="true" viewBox="0 0 24 24"> 1016 <path d="m6 21 15-9L6 3v18Z"/> 1017</svg>`,rD=`<svg aria-hidden="true" viewBox="0 0 24 24"> 1018 <path d="M6 20h4V4H6v16Zm8-16v16h4V4h-4Z"/> 1019</svg>`,rx=e=>{let t=e.mediaPaused?(0,ij.t)("play"):(0,ij.t)("pause");e.setAttribute("aria-label",t)};class rN extends at{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_PAUSED,iq.MediaUIAttributes.MEDIA_ENDED]}connectedCallback(){super.connectedCallback(),rx(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),(e===iq.MediaUIAttributes.MEDIA_PAUSED||e===iq.MediaUIAttributes.MEDIA_LANG)&&rx(this)}get mediaPaused(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_PAUSED)}set mediaPaused(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_PAUSED,e)}handleClick(){let e=this.mediaPaused?iq.MediaUIEvents.MEDIA_PLAY_REQUEST:iq.MediaUIEvents.MEDIA_PAUSE_REQUEST;this.dispatchEvent(new i1.Mq.CustomEvent(e,{composed:!0,bubbles:!0}))}}rN.getSlotTemplateHTML=function(e){return` 1020 <style> 1021 :host([${iq.MediaUIAttributes.MEDIA_PAUSED}]) slot[name=pause], 1022 :host(:not([${iq.MediaUIAttributes.MEDIA_PAUSED}])) slot[name=play] { 1023 display: none !important; 1024 } 1025 1026 :host([${iq.MediaUIAttributes.MEDIA_PAUSED}]) slot[name=tooltip-pause], 1027 :host(:not([${iq.MediaUIAttributes.MEDIA_PAUSED}])) slot[name=tooltip-play] { 1028 display: none; 1029 } 1030 </style> 1031 1032 <slot name="icon"> 1033 <slot name="play">${rL}</slot> 1034 <slot name="pause">${rD}</slot> 1035 </slot> 1036 `},rN.getTooltipContentHTML=function(){return` 1037 <slot name="tooltip-play">${(0,ij.t)("Play")}</slot> 1038 <slot name="tooltip-pause">${(0,ij.t)("Pause")}</slot> 1039 `},i1.Mq.customElements.get("media-play-button")||i1.Mq.customElements.define("media-play-button",rN);let rO={PLACEHOLDER_SRC:"placeholdersrc",SRC:"src"},rP=e=>{e.style.removeProperty("background-image")},rU=(e,t)=>{e.style["background-image"]=`url('${t}')`};class rW extends i1.Mq.HTMLElement{static get observedAttributes(){return[rO.PLACEHOLDER_SRC,rO.SRC]}constructor(){if(super(),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}this.image=this.shadowRoot.querySelector("#image")}attributeChangedCallback(e,t,i){e===rO.SRC&&(null==i?this.image.removeAttribute(rO.SRC):this.image.setAttribute(rO.SRC,i)),e===rO.PLACEHOLDER_SRC&&(null==i?rP(this.image):rU(this.image,i))}get placeholderSrc(){return(0,i0.ST)(this,rO.PLACEHOLDER_SRC)}set placeholderSrc(e){(0,i0.Lb)(this,rO.SRC,e)}get src(){return(0,i0.ST)(this,rO.SRC)}set src(e){(0,i0.Lb)(this,rO.SRC,e)}}rW.shadowRootOptions={mode:"open"},rW.getTemplateHTML=function(e){return` 1040 <style> 1041 :host { 1042 pointer-events: none; 1043 display: var(--media-poster-image-display, inline-block); 1044 box-sizing: border-box; 1045 } 1046 1047 img { 1048 max-width: 100%; 1049 max-height: 100%; 1050 min-width: 100%; 1051 min-height: 100%; 1052 background-repeat: no-repeat; 1053 background-position: var(--media-poster-image-background-position, var(--media-object-position, center)); 1054 background-size: var(--media-poster-image-background-size, var(--media-object-fit, contain)); 1055 object-fit: var(--media-object-fit, contain); 1056 object-position: var(--media-object-position, center); 1057 } 1058 </style> 1059 1060 <img part="poster img" aria-hidden="true" id="image"/> 1061 `},i1.Mq.customElements.get("media-poster-image")||i1.Mq.customElements.define("media-poster-image",rW);var r$=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},rB=(e,t,i)=>(r$(e,t,"read from private field"),i?i.call(e):t.get(e)),rH=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},rV=(e,t,i,a)=>(r$(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);class rK extends aU{constructor(){super(),rH(this,oF,void 0),rV(this,oF,this.shadowRoot.querySelector("slot"))}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_PREVIEW_CHAPTER,iq.MediaUIAttributes.MEDIA_LA
1061NG]}attributeChangedCallback(e,t,i){if(super.attributeChangedCallback(e,t,i),(e===iq.MediaUIAttributes.MEDIA_PREVIEW_CHAPTER||e===iq.MediaUIAttributes.MEDIA_LANG)&&i!==t&&null!=i){if(rB(this,oF).textContent=i,""!==i){let e=(0,ij.t)("chapter: {chapterName}",{chapterName:i});this.setAttribute("aria-valuetext",e)}else this.removeAttribute("aria-valuetext")}}get mediaPreviewChapter(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_CHAPTER)}set mediaPreviewChapter(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_CHAPTER,e)}}oF=new WeakMap,i1.Mq.customElements.get("media-preview-chapter-display")||i1.Mq.customElements.define("media-preview-chapter-display",rK);var rF=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},rY=(e,t,i)=>(rF(e,t,"read from private field"),i?i.call(e):t.get(e)),rq=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},rG=(e,t,i,a)=>(rF(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);class rj extends i1.Mq.HTMLElement{constructor(){if(super(),rq(this,oY,void 0),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}}static get observedAttributes(){return[iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER,iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE,iq.MediaUIAttributes.MEDIA_PREVIEW_COORDS]}connectedCallback(){var e,t,i;let a=this.getAttribute(iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER);a&&(rG(this,oY,null==(e=this.getRootNode())?void 0:e.getElementById(a)),null==(i=null==(t=rY(this,oY))?void 0:t.associateElement)||i.call(t,this))}disconnectedCallback(){var e,t;null==(t=null==(e=rY(this,oY))?void 0:e.unassociateElement)||t.call(e,this),rG(this,oY,null)}attributeChangedCallback(e,t,i){var a,r,n,s,o;[iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE,iq.MediaUIAttributes.MEDIA_PREVIEW_COORDS].includes(e)&&this.update(),e===iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER&&(t&&(null==(r=null==(a=rY(this,oY))?void 0:a.unassociateElement)||r.call(a,this),rG(this,oY,null)),i&&this.isConnected&&(rG(this,oY,null==(n=this.getRootNode())?void 0:n.getElementById(i)),null==(o=null==(s=rY(this,oY))?void 0:s.associateElement)||o.call(s,this)))}get mediaPreviewImage(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE)}set mediaPreviewImage(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE,e)}get mediaPreviewCoords(){let e=this.getAttribute(iq.MediaUIAttributes.MEDIA_PREVIEW_COORDS);if(e)return e.split(/\s+/).map(e=>+e)}set mediaPreviewCoords(e){if(!e){this.removeAttribute(iq.MediaUIAttributes.MEDIA_PREVIEW_COORDS);return}this.setAttribute(iq.MediaUIAttributes.MEDIA_PREVIEW_COORDS,e.join(" "))}update(){let e,t;let i=this.mediaPreviewCoords,a=this.mediaPreviewImage;if(!(i&&a))return;let[r,n,s,o]=i,l=a.split("#")[0],d=getComputedStyle(this),{maxWidth:u,maxHeight:c,minWidth:h,minHeight:m}=d;if("fill"===(d.getPropertyValue("--media-preview-thumbnail-object-fit").trim()||"contain")){let i=parseInt(u)/s,a=parseInt(c)/o,r=parseInt(h)/s,n=parseInt(m)/o;e=i<1?i:Math.max(i,r),t=a<1?a:Math.max(a,n)}else{let i=Math.min(parseInt(u)/s,parseInt(c)/o),a=Math.max(parseInt(h)/s,parseInt(m)/o),r=i<1?i:a>1?a:1;e=r,t=r}let{style:p}=(0,i0.R7)(this.shadowRoot,":host"),b=(0,i0.R7)(this.shadowRoot,"img").style,v=this.shadowRoot.querySelector("img"),E=1>Math.min(e,t)?"min":"max";p.setProperty(`${E}-width`,"initial","important"),p.setProperty(`${E}-height`,"initial","important"),p.width=`${s*e}px`,p.height=`${o*t}px`;let g=()=>{b.width=`${this.imgWidth*e}px`,b.height=`${this.imgHeight*t}px`,b.display="block"};v.src!==l&&(v.onload=()=>{this.imgWidth=v.naturalWidth,this.imgHeight=v.naturalHeight,g(),v.onload=null},v.src=l,g()),g(),b.transform=`translate(-${r*e}px, -${n*t}px)`}}oY=new WeakMap,rj.shadowRootOptions={mode:"open"},rj.getTemplateHTML=function(e){return` 1062 <style> 1063 :host { 1064 box-sizing: border-box; 1065 display: var(--media-control-display, var(--media-preview-thumbnail-display, inline-block)); 1066 overflow: hidden; 1067 } 1068 1069 img { 1070 display: none; 1071 position: relative; 1072 } 1073 </style> 1074 <img crossorigin loading="eager" decoding="async"> 1075 `}
1075,i1.Mq.customElements.get("media-preview-thumbnail")||i1.Mq.customElements.define("media-preview-thumbnail",rj);var rZ=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},rz=(e,t,i)=>(rZ(e,t,"read from private field"),i?i.call(e):t.get(e)),rX=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},rQ=(e,t,i,a)=>(rZ(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i);class rJ extends aU{constructor(){super(),rX(this,oq,void 0),rQ(this,oq,this.shadowRoot.querySelector("slot")),rz(this,oq).textContent=iQ(0)}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_PREVIEW_TIME]}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_PREVIEW_TIME&&null!=i&&(rz(this,oq).textContent=iQ(parseFloat(i)))}get mediaPreviewTime(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_TIME)}set mediaPreviewTime(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_TIME,e)}}oq=new WeakMap,i1.Mq.customElements.get("media-preview-time-display")||i1.Mq.customElements.define("media-preview-time-display",rJ);let r0={SEEK_OFFSET:"seekoffset"},r1=e=>` 1076 <svg aria-hidden="true" viewBox="0 0 20 24"> 1077 <defs> 1078 <style>.text{font-size:8px;font-family:Arial-BoldMT, Arial;font-weight:700;}</style> 1079 </defs> 1080 <text class="text value" transform="translate(2.18 19.87)">${e}</text> 1081 <path d="M10 6V3L4.37 7 10 10.94V8a5.54 5.54 0 0 1 1.9 10.48v2.12A7.5 7.5 0 0 0 10 6Z"/> 1082 </svg>`,r2=(e,t)=>{e.setAttribute("aria-label",(0,ij.t)("seek back {seekOffset} seconds",{seekOffset:t}))};class r3 extends at{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,r0.SEEK_OFFSET]}connectedCallback(){super.connectedCallback(),this.seekOffset=(0,i0.Uf)(this,r0.SEEK_OFFSET,30)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),r2(this,this.seekOffset),e===r0.SEEK_OFFSET&&(this.seekOffset=(0,i0.Uf)(this,r0.SEEK_OFFSET,30))}get seekOffset(){return(0,i0.Uf)(this,r0.SEEK_OFFSET,30)}set seekOffset(e){(0,i0.AI)(this,r0.SEEK_OFFSET,e),this.setAttribute("aria-label",(0,ij.t)("seek back {seekOffset} seconds",{seekOffset:this.seekOffset})),(0,i0.wl)((0,i0.PV)(this,"icon"),this.seekOffset)}get mediaCurrentTime(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,0)}set mediaCurrentTime(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,e)}handleClick(){let e=Math.max(this.mediaCurrentTime-this.seekOffset,0),t=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_SEEK_REQUEST,{composed:!0,bubbles:!0,detail:e});this.dispatchEvent(t)}}r3.getSlotTemplateHTML=function(e,t){return` 1083 <slot name="icon">${r1(t.seekOffset)}</slot> 1084 `},r3.getTooltipContentHTML=function(){return(0,ij.t)("Seek backward")},i1.Mq.customElements.get("media-seek-backward-button")||i1.Mq.customElements.define("media-seek-backward-button",r3);let r4={SEEK_OFFSET:"seekoffset"},r5=e=>` 1085 <svg aria-hidden="true" viewBox="0 0 20 24"> 1086 <defs> 1087 <style>.text{font-size:8px;font-family:Arial-BoldMT, Arial;font-weight:700;}</style> 1088 </defs> 1089 <text class="text value" transform="translate(8.9 19.87)">${e}</text> 1090 <path d="M10 6V3l5.61 4L10 10.94V8a5.54 5.54 0 0 0-1.9 10.48v2.12A7.5 7.5 0 0 1 10 6Z"/> 1091 </svg>`,r9=(e,t)=>{e.setAttribute("aria-label",(0,ij.t)("seek forward {seekOffset} seconds",{seekOffset:t}))};class r8 extends at{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,r4.SEEK_OFFSET]}connectedCallback(){super.connectedCallback(),this.seekOffset=(0,i0.Uf)(this,r4.SEEK_OFFSET,30)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),r9(this,this.seekOffset),e===r4.SEEK_OFFSET&&(this.seekOffset=(0,i0.Uf)(this,r4.SEEK_OFFSET,30))}get seekOffset(){return(0,i0.Uf)(this,r4.SEEK_OFFSET,30)}set seekOffset(e){(0,i0.AI)(this,r4.SEEK_OFFSET,e),this.setAttribute("aria-label",(0,ij.t)("seek forward {seekOffset} seconds",{seekOffset:this.seekOffset})),(0,i0.wl)((0,i0.PV)(this,"icon"),this.seekOffset)}get mediaCurrentTime(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,0)}set mediaCurrentTime(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,e)}handleClick(){let e=this.mediaCurrentTime+this.seekOffset,t=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_SEEK_REQUEST,{composed:!0,bubbles:!0,detail:e});this.dispatchEvent(t)}}r8.getSlotTemplateHTML=function(e,t){return` 1092 <slot name="icon">${r5(t.seekOffset)}</slot> 1093 `},r8.getTooltipContentHTML=function(){return(0,ij.t)("Seek forward")},i1.Mq.customElements.get("media-seek-forward-button")||i1.Mq.customElements.define("media-seek-forward-button",r8);var r6=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},r7=(e,t,i)=>
1093(r6(e,t,"read from private field"),i?i.call(e):t.get(e)),ne=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},nt=(e,t,i,a)=>(r6(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),ni=(e,t,i)=>(r6(e,t,"access private method"),i);let na={REMAINING:"remaining",SHOW_DURATION:"showduration",NO_TOGGLE:"notoggle"},nr=[...Object.values(na),iq.MediaUIAttributes.MEDIA_CURRENT_TIME,iq.MediaUIAttributes.MEDIA_DURATION,iq.MediaUIAttributes.MEDIA_SEEKABLE],nn=["Enter"," "],ns=" / ",no=(e,{timesSep:t=ns}={})=>{var i,a;let r=null!=(i=e.mediaCurrentTime)?i:0,[,n]=null!=(a=e.mediaSeekable)?a:[],s=0;Number.isFinite(e.mediaDuration)?s=e.mediaDuration:Number.isFinite(n)&&(s=n);let o=e.remaining?iQ(0-(s-r)):iQ(r);return e.showDuration?`${o}${t}${iQ(s)}`:o},nl=e=>{var t;let i=e.mediaCurrentTime,[,a]=null!=(t=e.mediaSeekable)?t:[],r=null;if(Number.isFinite(e.mediaDuration)?r=e.mediaDuration:Number.isFinite(a)&&(r=a),null==i||null===r){e.setAttribute("aria-description",(0,ij.t)("video not loaded, unknown time."));return}let n=e.remaining?iX(0-(r-i)):iX(i);if(!e.showDuration){e.setAttribute("aria-description",n);return}let s=iX(r),o=(0,ij.t)("{currentTime} of {totalTime}",{currentTime:n,totalTime:s});e.setAttribute("aria-description",o)},nd=e=>{e.setAttribute("aria-label",(0,ij.t)("playback time"))};class nu extends aU{constructor(){super(),ne(this,oz),ne(this,oQ),ne(this,o0),ne(this,o2),ne(this,oG,void 0),ne(this,oj,null),ne(this,oZ,e=>{let{metaKey:t,altKey:i,key:a}=e;if(t||i||!nn.includes(a)){this.removeEventListener("keyup",r7(this,oj));return}this.addEventListener("keyup",r7(this,oj))}),nt(this,oG,this.shadowRoot.querySelector("slot")),r7(this,oG).innerHTML=`${no(this)}`}static get observedAttributes(){return[...super.observedAttributes,...nr,"disabled"]}connectedCallback(){let{style:e}=(0,i0.R7)(this.shadowRoot,":host(:hover:not([notoggle]))");e.setProperty("cursor","var(--media-cursor, pointer)"),e.setProperty("background","var(--media-control-hover-background, rgba(50 50 70 / .7))"),this.setAttribute("aria-label",(0,ij.t)("playback time")),ni(this,o0,o1).call(this),super.connectedCallback()}toggleTimeDisplay(){this.noToggle||(this.hasAttribute("remaining")?this.removeAttribute("remaining"):this.setAttribute("remaining",""))}disconnectedCallback(){this.disable(),ni(this,oQ,oJ).call(this),super.disconnectedCallback()}attributeChangedCallback(e,t,i){nd(this),nr.includes(e)?this.update():"disabled"===e&&i!==t?null==i?ni(this,o0,o1).call(this):ni(this,o2,o3).call(this):e===na.NO_TOGGLE&&i!==t&&(this.noToggle?ni(this,o2,o3).call(this):ni(this,o0,o1).call(this)),super.attributeChangedCallback(e,t,i)}enable(){this.noToggle||(this.tabIndex=0)}disable(){this.tabIndex=-1}get remaining(){return(0,i0.zc)(this,na.REMAINING)}set remaining(e){(0,i0.Pj)(this,na.REMAINING,e)}get showDuration(){return(0,i0.zc)(this,na.SHOW_DURATION)}set showDuration(e){(0,i0.Pj)(this,na.SHOW_DURATION,e)}get noToggle(){return(0,i0.zc)(this,na.NO_TOGGLE)}set noToggle(e){(0,i0.Pj)(this,na.NO_TOGGLE,e)}get mediaDuration(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_DURATION)}set mediaDuration(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_DURATION,e)}get mediaCurrentTime(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_CURRENT_TIME)}set mediaCurrentTime(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,e)}get mediaSeekable(){let e=this.getAttribute(iq.MediaUIAttributes.MEDIA_SEEKABLE);if(e)return e.split(":").map(e=>+e)}set mediaSeekable(e){if(null==e){this.removeAttribute(iq.MediaUIAttributes.MEDIA_SEEKABLE);return}this.setAttribute(iq.MediaUIAttributes.MEDIA_SEEKABLE,e.join(":"))}update(){let e=no(this);nl(this),e!==r7(this,oG).innerHTML&&(r7(this,oG).innerHTML=e)}}oG=new WeakMap,oj=new WeakMap,oZ=new WeakMap,oz=new WeakSet,oX=function(){r7(this,oj)||(nt(this,oj,e=>{let{key:t}=e;if(!nn.includes(t)){this.removeEventListener("keyup",r7(this,oj));return}this.toggleTimeDisplay()}),this.addEventListener("keydown",r7(this,oZ)),this.addEventListener("click",this.toggleTimeDisplay))},oQ=new WeakSet,oJ=function(){r7(this,oj)&&(this.removeEventListener("keyup",r7(this,oj)),this.removeEventListener("keydown",r7(this,oZ)),this.removeEventListener("click",this.toggleTimeDisplay),nt
1093(this,oj,null))},o0=new WeakSet,o1=function(){this.noToggle||this.hasAttribute("disabled")||(this.setAttribute("role","button"),this.enable(),ni(this,oz,oX).call(this))},o2=new WeakSet,o3=function(){this.removeAttribute("role"),this.disable(),ni(this,oQ,oJ).call(this)},nu.getSlotTemplateHTML=function(e,t){return` 1094 <slot>${no(t)}</slot> 1095 `},i1.Mq.customElements.get("media-time-display")||i1.Mq.customElements.define("media-time-display",nu);var nc=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},nh=(e,t,i)=>(nc(e,t,"read from private field"),i?i.call(e):t.get(e)),nm=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},np=(e,t,i,a)=>(nc(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),nb=(e,t,i,a)=>({set _(value){np(e,t,value,i)},get _(){return nh(e,t,a)}});class nv{constructor(e,t,i){nm(this,o4,void 0),nm(this,o5,void 0),nm(this,o9,void 0),nm(this,o8,void 0),nm(this,o6,void 0),nm(this,o7,void 0),nm(this,le,void 0),nm(this,lt,void 0),nm(this,li,0),nm(this,la,(e=performance.now())=>{np(this,li,requestAnimationFrame(nh(this,la))),np(this,o8,performance.now()-nh(this,o9));let t=1e3/this.fps;if(nh(this,o8)>t){np(this,o9,e-nh(this,o8)%t);let i=1e3/((e-nh(this,o5))/++nb(this,o6)._),a=(e-nh(this,o7))/1e3/this.duration,r=nh(this,le)+a*this.playbackRate;r-nh(this,o4).valueAsNumber>0?np(this,lt,this.playbackRate/this.duration/i):(np(this,lt,.995*nh(this,lt)),r=nh(this,o4).valueAsNumber+nh(this,lt)),this.callback(r)}}),np(this,o4,e),this.callback=t,this.fps=i}start(){0===nh(this,li)&&(np(this,o9,performance.now()),np(this,o5,nh(this,o9)),np(this,o6,0),nh(this,la).call(this))}stop(){0!==nh(this,li)&&(cancelAnimationFrame(nh(this,li)),np(this,li,0))}update({start:e,duration:t,playbackRate:i}){let a=e-nh(this,o4).valueAsNumber,r=Math.abs(t-this.duration);(a>0||a<-.03||r>=.5)&&this.callback(e),np(this,le,e),np(this,o7,performance.now()),this.duration=t,this.playbackRate=i}}o4=new WeakMap,o5=new WeakMap,o9=new WeakMap,o8=new WeakMap,o6=new WeakMap,o7=new WeakMap,le=new WeakMap,lt=new WeakMap,li=new WeakMap,la=new WeakMap;var nE=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},ng=(e,t,i)=>(nE(e,t,"read from private field"),i?i.call(e):t.get(e)),nf=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},nA=(e,t,i,a)=>(nE(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),ny=(e,t,i)=>(nE(e,t,"access private method"),i);let nT=e=>{let t=e.range,i=iX(+nM(e)),a=iX(+e.mediaSeekableEnd),r=i&&a?(0,ij.t)("{currentTime} of {totalTime}",{currentTime:i,totalTime:a}):(0,ij.t)("video not loaded, unknown time.");t.setAttribute("aria-valuetext",r)},nk=(e,t=e.mediaCurrentTime)=>{let i=Number.isFinite(e.mediaSeekableStart)?e.mediaSeekableStart:0,a=Number.isFinite(e.mediaDuration)?e.mediaDuration:e.mediaSeekableEnd;return Number.isNaN(a)?0:Math.max(0,Math.min((t-i)/(a-i),1))},nM=(e,t=e.range.valueAsNumber)=>{let i=Number.isFinite(e.mediaSeekableStart)?e.mediaSeekableStart:0,a=Number.isFinite(e.mediaDuration)?e.mediaDuration:e.mediaSeekableEnd;return Number.isNaN(a)?0:t*(a-i)+i};class nI extends aw{constructor(){super(),nf(this,lb),nf(this,lg),nf(this,lA),nf(this,lT),nf(this,lM),nf(this,l_),nf(this,lC),nf(this,lr,null),nf(this,ln,void 0),nf(this,ls,void 0),nf(this,lo,void 0),nf(this,ll,void 0),nf(this,ld,void 0),nf(this,lu,void 0),nf(this,lc,void 0),nf(this,lh,void 0),nf(this,lm,void 0),nf(this,lp,()=>{ny(this,lb,lv).call(this)?ng(this,ln).start():ng(this,ln).stop()}),nf(this,lE,e=>{this.dragging||((0,iG.qh)(e)&&(this.range.valueAsNumber=e),ng(this,lm)||this.updateBar())}),this.shadowRoot.querySelector("#track").insertAdjacentHTML("afterbegin",'<div id="buffered" part="buffered"></div>'),nA(this,ls,this.shadowRoot.querySelectorAll('[part~="box"]')),nA(this,ll,this.shadowRoot.querySelector('[part~="preview-box"]')),nA(this,ld,this.shadowRoot.querySelector('[part~="current-box"]'));let e=getComputedStyle(this);nA(this,lu,parseInt(e.getPropertyValue("--media-box-padding-left"))),nA(this,lc,parseInt(e.getPropertyValue("--media-box-padding-right"))),nA(this,ln,new nv(this.range,ng(this,lE),60))}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_PAUSED,iq.MediaUIAttributes.MEDIA_DURATION,iq.MediaUIAttributes.MEDIA_SEEKABLE,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE,iq.MediaUIAttributes.MEDIA_PREVIEW_TIME,iq.MediaUIAttributes.MEDIA_PREVIEW_CHAPTER,iq.MediaUIAttributes.MEDIA_BUFFERED,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,iq.MediaUIAttributes.MEDIA_LOADING,iq.MediaUIAttributes.MEDIA_ENDED]}connectedCallback(){var e;super.connectedCallback(),this.range.setAttribute("aria-label",(0,ij.t)("seek")),ng(this,lp).call(this),nA(this,lr,this.getRootNode()),null==(e=ng(this,lr))||e.addEventListener("transitionstart",this)}disconnectedCallback(){var e;super.disconnectedCallback(),ng(this,ln).stop(),null==(e=ng(this,lr))||e.removeEventListener("transitionstart",this),nA(this,lr,null)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),t!=i&&(e===iq.MediaUIAttributes.MEDIA_CURRENT_TIME||e===iq.MediaUIAttributes.MEDIA_PAUSED||e===iq.MediaUIAttributes.MEDIA_ENDED||e===iq.MediaUIAttributes.MEDIA_LOADING||e===iq.MediaUIAttributes.MEDIA_DURATION||e===iq.MediaUIAttributes.MEDIA_SEEKABLE?(ng(this,ln).update({start:nk(this),duration:this.mediaSeekableEnd-this.mediaSeekableStart,playbackRate:this.mediaPlaybackRate}),ng(this,lp).call(this),nT(this)):e===iq.MediaUIAttributes.MEDIA_BUFFERED&&this.updateBufferedBar(),(e===iq.MediaUIAttributes.MEDIA_DURATION||e===iq.MediaUIAttributes.MEDIA_SEEKABLE)&&(this.mediaChapter
1095sCues=ng(this,lh),this.updateBar()))}get mediaChaptersCues(){return ng(this,lh)}set mediaChaptersCues(e){var t;nA(this,lh,e),this.updateSegments(null==(t=ng(this,lh))?void 0:t.map(e=>({start:nk(this,e.startTime),end:nk(this,e.endTime)})))}get mediaPaused(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_PAUSED)}set mediaPaused(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_PAUSED,e)}get mediaLoading(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_LOADING)}set mediaLoading(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_LOADING,e)}get mediaDuration(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_DURATION)}set mediaDuration(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_DURATION,e)}get mediaCurrentTime(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_CURRENT_TIME)}set mediaCurrentTime(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_CURRENT_TIME,e)}get mediaPlaybackRate(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,1)}set mediaPlaybackRate(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,e)}get mediaBuffered(){let e=this.getAttribute(iq.MediaUIAttributes.MEDIA_BUFFERED);return e?e.split(" ").map(e=>e.split(":").map(e=>+e)):[]}set mediaBuffered(e){if(!e){this.removeAttribute(iq.MediaUIAttributes.MEDIA_BUFFERED);return}let t=e.map(e=>e.join(":")).join(" ");this.setAttribute(iq.MediaUIAttributes.MEDIA_BUFFERED,t)}get mediaSeekable(){let e=this.getAttribute(iq.MediaUIAttributes.MEDIA_SEEKABLE);if(e)return e.split(":").map(e=>+e)}set mediaSeekable(e){if(null==e){this.removeAttribute(iq.MediaUIAttributes.MEDIA_SEEKABLE);return}this.setAttribute(iq.MediaUIAttributes.MEDIA_SEEKABLE,e.join(":"))}get mediaSeekableEnd(){var e;let[,t=this.mediaDuration]=null!=(e=this.mediaSeekable)?e:[];return t}get mediaSeekableStart(){var e;let[t=0]=null!=(e=this.mediaSeekable)?e:[];return t}get mediaPreviewImage(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE)}set mediaPreviewImage(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE,e)}get mediaPreviewTime(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_TIME)}set mediaPreviewTime(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_PREVIEW_TIME,e)}get mediaEnded(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_ENDED)}set mediaEnded(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_ENDED,e)}updateBar(){super.updateBar(),this.updateBufferedBar(),this.updateCurrentBox()}updateBufferedBar(){var e;let t;let i=this.mediaBuffered;if(!i.length)return;if(this.mediaEnded)t=1;else{let a=this.mediaCurrentTime,[,r=this.mediaSeekableStart]=null!=(e=i.find(([e,t])=>e<=a&&a<=t))?e:[];t=nk(this,r)}let{style:a}=(0,i0.R7)(this.shadowRoot,"#buffered");a.setProperty("width",`${100*t}%`)}updateCurrentBox(){if(!this.shadowRoot.querySelector('slot[name="current"]').assignedElements().length)return;let e=(0,i0.R7)(this.shadowRoot,"#current-rail"),t=(0,i0.R7)(this.shadowRoot,'[part~="current-box"]'),i=ny(this,lg,lf).call(this,ng(this,ld)),a=ny(this,lA,ly).call(this,i,this.range.valueAsNumber),r=ny(this,lT,lk).call(this,i,this.range.valueAsNumber);e.style.transform=`translateX(${a})`,e.style.setProperty("--_range-width",`${i.range.width}`),t.style.setProperty("--_box-shift",`${r}`),t.style.setProperty("--_box-width",`${i.box.width}px`),t.style.setProperty("visibility","initial")}handleEvent(e){switch(super.handleEvent(e),e.type){case"input":ny(this,lC,lR).call(this);break;case"pointermove":ny(this,lM,lI).call(this,e);break;case"pointerup":ng(this,lm)&&nA(this,lm,!1);break;case"pointerdown":nA(this,lm,!0);break;case"pointerleave":ny(this,l_,lw).call(this,null);break;case"transitionstart":(0,i0.Mj)(e.target,this)&&setTimeout(()=>ng(this,lp).call(this),0)}}}lr=new WeakMap,ln=new WeakMap,ls=new WeakMap,lo=new WeakMap,ll=new WeakMap,ld=new WeakMap,lu=new WeakMap,lc=new WeakMap,lh=new WeakMap,lm=new WeakMap,lp=new WeakMap,lb=new WeakSet,lv=function(){return this.isConnected&&!this.mediaPaused&&!this.mediaLoading&&!this.mediaEnded&&this.mediaSeekableEnd>0&&(0,i0.Jv)(this)},lE=new WeakMap,lg=new WeakSet,lf=function(e){var t;let i=(null!=(t=this.getAttribute("bounds")?(0,i0.l5)(this,`#${this.getAttribute("bounds")}`):this.parentElement)?t:this).getBoundingClientRect(),a=this.range.getBoundingClientRect(),r=e.offsetWidth,n=-(a.left-i.left-r/2),s=i.right-a.left-r/2;return{box:{width:r,min:n,max:s},bounds:i,range:a}},lA=new WeakSet,ly=function(e,t){let i=`${100*t}%`,{width:a,min:r,max:n}=e.box;if(!a)return i;if(!Number.isNaN(r)){let e=`calc(1 / var(--_range-width) * 100 * ${r}% + var(--media-box-padding-left))`;i=`max(${e}, ${i})`}if(!Number.isNaN(n)){let e=`calc(1 / var(--_range-width) * 100 * ${n}% - var(--media-box-padding-right))`;i=`min(${i}, ${e})`}return i},lT=new WeakSet,lk=function(e,t){let{width:i,min:a,max:r}
1095=e.box,n=t*e.range.width;if(n<a+ng(this,lu)){let t=e.range.left-e.bounds.left-ng(this,lu);return`${n-i/2+t}px`}if(n>r-ng(this,lc)){let t=e.bounds.right-e.range.right-ng(this,lc);return`${n+i/2-t-e.range.width}px`}return 0},lM=new WeakSet,lI=function(e){let t=[...ng(this,ls)].some(t=>e.composedPath().includes(t));if(!this.dragging&&(t||!e.composedPath().includes(this))){ny(this,l_,lw).call(this,null);return}let i=this.mediaSeekableEnd;if(!i)return;let a=(0,i0.R7)(this.shadowRoot,"#preview-rail"),r=(0,i0.R7)(this.shadowRoot,'[part~="preview-box"]'),n=ny(this,lg,lf).call(this,ng(this,ll)),s=(e.clientX-n.range.left)/n.range.width;s=Math.max(0,Math.min(1,s));let o=ny(this,lA,ly).call(this,n,s),l=ny(this,lT,lk).call(this,n,s);a.style.transform=`translateX(${o})`,a.style.setProperty("--_range-width",`${n.range.width}`),r.style.setProperty("--_box-shift",`${l}`),r.style.setProperty("--_box-width",`${n.box.width}px`),1>Math.abs(Math.round(ng(this,lo))-Math.round(s*i))&&s>.01&&s<.99||(nA(this,lo,s*i),ny(this,l_,lw).call(this,ng(this,lo)))},l_=new WeakSet,lw=function(e){this.dispatchEvent(new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_PREVIEW_REQUEST,{composed:!0,bubbles:!0,detail:e}))},lC=new WeakSet,lR=function(){ng(this,ln).stop();let e=nM(this);this.dispatchEvent(new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_SEEK_REQUEST,{composed:!0,bubbles:!0,detail:e}))},nI.shadowRootOptions={mode:"open"},nI.getContainerTemplateHTML=function(e){return` 1096 <style> 1097 :host { 1098 --media-box-border-radius: 4px; 1099 --media-box-padding-left: 10px; 1100 --media-box-padding-right: 10px; 1101 --media-preview-border-radius: var(--media-box-border-radius); 1102 --media-box-arrow-offset: var(--media-box-border-radius); 1103 --_control-background: var(--media-control-background, var(--media-secondary-color, rgb(20 20 30 / .7))); 1104 --_preview-background: var(--media-preview-background, var(--_control-background)); 1105 1106 1107 contain: layout; 1108 } 1109 1110 #buffered { 1111 background: var(--media-time-range-buffered-color, rgb(255 255 255 / .4)); 1112 position: absolute; 1113 height: 100%; 1114 will-change: width; 1115 } 1116 1117 #preview-rail, 1118 #current-rail { 1119 width: 100%; 1120 position: absolute; 1121 left: 0; 1122 bottom: 100%; 1123 pointer-events: none; 1124 will-change: transform; 1125 } 1126 1127 [part~="box"] { 1128 width: min-content; 1129 1130 position: absolute; 1131 bottom: 100%; 1132 flex-direction: column; 1133 align-items: center; 1134 transform: translateX(-50%); 1135 } 1136 1137 [part~="current-box"] { 1138 display: var(--media-current-box-display, var(--media-box-display, flex)); 1139 margin: var(--media-current-box-margin, var(--media-box-margin, 0 0 5px)); 1140 visibility: hidden; 1141 } 1142 1143 [part~="preview-box"] { 1144 display: var(--media-preview-box-display, var(--media-box-display, flex)); 1145 margin: var(--media-preview-box-margin, var(--media-box-margin, 0 0 5px)); 1146 transition-property: var(--media-preview-transition-property, visibility, opacity); 1147 transition-duration: var(--media-preview-transition-duration-out, .25s); 1148 transition-delay: var(--media-preview-transition-delay-out, 0s); 1149 visibility: hidden; 1150 opacity: 0; 1151 } 1152 1153 :host(:is([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}], [${iq.MediaUIAttributes.MEDIA_PREVIEW_TIME}])[dragging]) [part~="preview-box"] { 1154 transition-duration: var(--media-preview-transition-duration-in, .5s); 1155 transition-delay: var(--media-preview-transition-delay-in, .25s); 1156 visibility: visible; 1157 opacity: 1; 1158 } 1159 1160 @media (hover: hover) { 1161 :host(:is([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}], [${iq.MediaUIAttributes.MEDIA_PREVIEW_TIME}]):hover) [part~="preview-box"] { 1162 transition-duration: var(--media-preview-transition-duration-in, .5s); 1163 transition-delay: var(--media-preview-transition-delay-in, .25s); 1164 visibility: visible; 1165 opacity: 1; 1166 } 1167 } 1168
1169 media-preview-thumbnail, 1170 ::slotted(media-preview-thumbnail) { 1171 visibility: hidden; 1172 1173 transition: visibility 0s .25s; 1174 transition-delay: calc(var(--media-preview-transition-delay-out, 0s) + var(--media-preview-transition-duration-out, .25s)); 1175 background: var(--media-preview-thumbnail-background, var(--_preview-background)); 1176 box-shadow: var(--media-preview-thumbnail-box-shadow, 0 0 4px rgb(0 0 0 / .2)); 1177 max-width: var(--media-preview-thumbnail-max-width, 180px); 1178 max-height: var(--media-preview-thumbnail-max-height, 160px); 1179 min-width: var(--media-preview-thumbnail-min-width, 120px); 1180 min-height: var(--media-preview-thumbnail-min-height, 80px); 1181 border: var(--media-preview-thumbnail-border); 1182 border-radius: var(--media-preview-thumbnail-border-radius, 1183 var(--media-preview-border-radius) var(--media-preview-border-radius) 0 0); 1184 } 1185 1186 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}][dragging]) media-preview-thumbnail, 1187 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}][dragging]) ::slotted(media-preview-thumbnail) { 1188 transition-delay: var(--media-preview-transition-delay-in, .25s); 1189 visibility: visible; 1190 } 1191 1192 @media (hover: hover) { 1193 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}]:hover) media-preview-thumbnail, 1194 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}]:hover) ::slotted(media-preview-thumbnail) { 1195 transition-delay: var(--media-preview-transition-delay-in, .25s); 1196 visibility: visible; 1197 } 1198 1199 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_TIME}]:hover) { 1200 --media-time-range-hover-display: block; 1201 } 1202 } 1203 1204 media-preview-chapter-display, 1205 ::slotted(media-preview-chapter-display) { 1206 font-size: var(--media-font-size, 13px); 1207 line-height: 17px; 1208 min-width: 0; 1209 visibility: hidden; 1210 1211 transition: min-width 0s, border-radius 0s, margin 0s, padding 0s, visibility 0s; 1212 transition-delay: calc(var(--media-preview-transition-delay-out, 0s) + var(--media-preview-transition-duration-out, .25s)); 1213 background: var(--media-preview-chapter-background, var(--_preview-background)); 1214 border-radius: var(--media-preview-chapter-border-radius, 1215 var(--media-preview-border-radius) var(--media-preview-border-radius) 1216 var(--media-preview-border-radius) var(--media-preview-border-radius)); 1217 padding: var(--media-preview-chapter-padding, 3.5px 9px); 1218 margin: var(--media-preview-chapter-margin, 0 0 5px); 1219 text-shadow: var(--media-preview-chapter-text-shadow, 0 0 4px rgb(0 0 0 / .75)); 1220 } 1221 1222 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}]) media-preview-chapter-display, 1223 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}]) ::slotted(media-preview-chapter-display) { 1224 transition-delay: var(--media-preview-transition-delay-in, .25s); 1225 border-radius: var(--media-preview-chapter-border-radius, 0); 1226 padding: var(--media-preview-chapter-padding, 3.5px 9px 0); 1227 margin: var(--media-preview-chapter-margin, 0); 1228 min-width: 100%; 1229 } 1230 1231 media-preview-chapter-display[${iq.MediaUIAttributes.MEDIA_PREVIEW_CHAPTER}], 1232 ::slotted(media-preview-chapter-display[${iq.MediaUIAttributes.MEDIA_PREVIEW_CHAPTER}]) { 1233 visibility: visible; 1234 } 1235 1236 media-preview-chapter-display:not([aria-valuetext]), 1237 ::slotted(media-preview-chapter-display:not([aria-valuetext])) { 1238 display: none; 1239 } 1240 1241 media-preview-time-display, 1242 ::slotted(media-preview-time-display), 1243 media-time-display, 1244 ::slotted(media-time-display) { 1245 font-size: var(--media-font-size, 13px); 1246 line-height: 17px; 1247 min-width: 0; 1248 1249 transition: min-width 0s, border-radius 0s; 1250 transition-delay: calc(var(--media-preview-transition-delay-out, 0s) + var(--media-preview-transition-duration-out, .25s)); 1251 background: var(--media-preview-time-background, var(--_preview-background)); 1252 border-radius: var(--media-preview-time-border-radius, 1253 var(--media-preview-border-radius) var(--media-preview-border-radius) 1254 var(--media-preview-border-radius) var(--media-preview-border-radius)); 1255 padding: var(--media-preview-time-padding, 3.5px 9px); 1256 margin: var(--media-preview-time-margin, 0); 1257 text-shadow: var(--media-preview-time-text-shadow, 0 0 4px rgb(0 0 0 / .75)); 1258 transform: translateX(min( 1259 max(calc(50% - var(--_box-width) / 2), 1260 calc(var(--_box-shift, 0))), 1261 calc(var(--_box-width) / 2 - 50%) 1262 )); 1263 } 1264 1265 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}]) media-preview-time-display, 1266 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_IMAGE}]) ::slotted(media-preview-time-display) { 1267 transition-delay: var(--media-preview-transition-delay-in, .25s); 1268 border-radius: var(--media-preview-time-border-radius, 1269 0 0 var(--media-preview-border-radius) var(--media-preview-border-radius)); 1270 min-width: 100%; 1271 } 1272 1273 :host([${iq.MediaUIAttributes.MEDIA_PREVIEW_TIME}]:hover) { 1274 --media-time-range-hover-display: block; 1275 } 1276 1277 [part~="arrow"], 1278 ::slotted([part~="arrow"]) { 1279 display: var(--media-box-arrow-display, inline-block); 1280 transform: translateX(min( 1281 max(calc(50% - var(--_box-width) / 2 + var(--media-box-arrow-offset)), 1282 calc(var(--_box-shift, 0))), 1283 calc(var(--_box-width) / 2 - 50% - var(--media-box-arrow-offset)) 1284 )); 1285 1286 border-color: transparent; 1287 border-top-color: var(--media-box-arrow-background, var(--_control-background)); 1288 border-width: var(--media-box-arrow-border-width, 1289 var(--media-box-arrow-height, 5px) var(--media-box-arrow-width, 6px) 0); 1290 border-style: solid; 1291 justify-content: center; 1292 height: 0; 1293 } 1294 </style> 1295 <div id="preview-rail"> 1296 <slot name="preview" part="box preview-box">
1297 <media-preview-thumbnail> 1298 <template shadowrootmode="${rj.shadowRootOptions.mode}"> 1299 ${rj.getTemplateHTML({})} 1300 </template> 1301 </media-preview-thumbnail> 1302 <media-preview-chapter-display></media-preview-chapter-display> 1303 <media-preview-time-display></media-preview-time-display> 1304 <slot name="preview-arrow"><div part="arrow"></div></slot> 1305 </slot> 1306 </div> 1307 <div id="current-rail"> 1308 <slot name="current" part="box current-box"> 1309 1310 </slot> 1311 </div> 1312 `},i1.Mq.customElements.get("media-time-range")||i1.Mq.customElements.define("media-time-range",nI);var n_=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},nw=(e,t,i)=>(n_(e,t,"read from private field"),i?i.call(e):t.get(e)),nC=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)};let nR=e=>e.mediaMuted?0:e.mediaVolume,nS=e=>`${Math.round(100*e)}%`;class nL extends aw{constructor(){super(...arguments),nC(this,lS,()=>{let e=this.range.value,t=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_VOLUME_REQUEST,{composed:!0,bubbles:!0,detail:e});this.dispatchEvent(t)})}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_VOLUME,iq.MediaUIAttributes.MEDIA_MUTED,iq.MediaUIAttributes.MEDIA_VOLUME_UNAVAILABLE]}connectedCallback(){super.connectedCallback(),this.range.setAttribute("aria-label",(0,ij.t)("volume")),this.range.addEventListener("input",nw(this,lS))}disconnectedCallback(){this.range.removeEventListener("input",nw(this,lS)),super.disconnectedCallback()}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),(e===iq.MediaUIAttributes.MEDIA_VOLUME||e===iq.MediaUIAttributes.MEDIA_MUTED)&&(this.range.valueAsNumber=nR(this),this.range.setAttribute("aria-valuetext",nS(this.range.valueAsNumber)),this.updateBar())}get mediaVolume(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_VOLUME,
13121)}set mediaVolume(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_VOLUME,e)}get mediaMuted(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_MUTED)}set mediaMuted(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_MUTED,e)}get mediaVolumeUnavailable(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_VOLUME_UNAVAILABLE)}set mediaVolumeUnavailable(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_VOLUME_UNAVAILABLE,e)}}lS=new WeakMap,i1.Mq.customElements.get("media-volume-range")||i1.Mq.customElements.define("media-volume-range",nL);var nD=i(87321);class nx extends at{constructor(){super(...arguments),this.container=null}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_LOOP]}connectedCallback(){var e;super.connectedCallback(),this.container=(null==(e=this.shadowRoot)?void 0:e.querySelector("#icon"))||null,this.container&&(this.container.textContent=(0,ij.t)("Loop"))}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_LOOP&&this.container&&this.setAttribute("aria-checked",this.mediaLoop?"true":"false")}get mediaLoop(){return(0,i0.zc)(this,iq.MediaUIAttributes.MEDIA_LOOP)}set mediaLoop(e){(0,i0.Pj)(this,iq.MediaUIAttributes.MEDIA_LOOP,e)}handleClick(){let e=!this.mediaLoop,t=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_LOOP_REQUEST,{composed:!0,bubbles:!0,detail:e});this.dispatchEvent(t)}}nx.getSlotTemplateHTML=function(e){return` 1313 <style> 1314 :host { 1315 min-width: 4ch; 1316 padding: var(--media-button-padding, var(--media-control-padding, 10px 5px)); 1317 width: 100%; 1318 display: grid; 1319 grid-template-columns: 1fr auto; 1320 gap: 1rem; 1321 font-weight: var(--media-button-font-weight, normal); 1322 } 1323 1324 #checked-indicator { 1325 display: none; 1326 } 1327 1328 :host([${iq.MediaUIAttributes.MEDIA_LOOP}]) #checked-indicator { 1329 display: block; 1330 } 1331 </style> 1332 1333 <span id="icon"> 1334 </span> 1335 1336 <div id="checked-indicator"> 1337 <svg aria-hidden="true" viewBox="0 1 24 24" part="checked-indicator indicator"> 1338 <path d="m10 15.17 9.193-9.191 1.414 1.414-10.606 10.606-6.364-6.364 1.414-1.414 4.95 4.95Z"/> 1339 </svg> 1340 </div> 1341 `},nx.getTooltipContentHTML=function(){return(0,ij.t)("Loop")},i1.Mq.customElements.get("media-loop-button")||i1.Mq.customElements.define("media-loop-button",nx);var nN=i(34709);function nO(e){return e.split("-")[0]}class nP extends Event{constructor({action:e="auto",relatedTarget:t,...i}){super("invoke",i),this.action=e,this.relatedTarget=t}}class nU extends Event{constructor({newState:e,oldState:t,...i}){super("toggle",i),this.newState=e,this.oldState=t}}var nW=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},n$=(e,t,i)=>(nW(e,t,"read from private field"),i?i.call(e):t.get(e)),nB=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},nH=(e,t,i,a)=>(nW(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),nV=(e,t,i)=>(nW(e,t,"access private method"),i);function nK({type:e,text:t,value:i,checked:a}){let r=i1.tj.createElement("media-chrome-menu-item");r.type=null!=e?e:"",r.part.add("menu-item"),e&&r.part.add(e),r.value=i,r.checked=a;let n=i1.tj.createElement("span");return n.textContent=t,r.append(n),r}function nF(e,t){let i=e.querySelector(`:scope > [slot="${t}"]`);if((null==i?void 0:i.nodeName)=="SLOT"&&(i=i.assignedElements({flatten:!0})[0]),i)return i.cloneNode(!0);let a=e.shadowRoot.querySelector(`[name="${t}"] > svg`);return a?a.cloneNode(!0):""}let nY={STYLE:"style",HIDDEN:"hidden",DISABLED:"disabled",ANCHOR:"anchor"};class nq extends i1.Mq.HTMLElement{constructor(){if(super(),nB(this,lW),nB(this,lB),nB(this,lK),nB(this,lY),nB(this,lG),nB(this,lZ),nB(this,lJ),nB(this,l1),nB(this,l3),nB(this,l5),nB(this,l8),nB(this,l7),nB(this,dt),nB(this,da),nB(this,dn),nB(this,dl),nB(this,du),nB(this,dh),nB(this,lL,null),nB(this,lD,null),nB(this,lx,null),nB(this,lN,new Set),nB(this,lO,void 0),nB(this,lP,!1),nB(this,lU,null),nB(this,lV,()=>{let e=n$(this,lN),t=new Set(this.items);for(let i of e)t.has(i)||this.dispatchEvent(new CustomEvent("removemenuitem",{detail:i}));for(let i of t)e.has(i)||this.dispatchEvent(new CustomEvent("addmenuitem",{detail:i}));nH(this,lN,t)}),nB(this,lX,()=>{nV(this,lJ,l0).call(this),nV(this,l1,l2).call(this,!1)}),nB(this,lQ,()=>{nV(this,lJ,l0).call(this)}),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}this.container=this.shadowRoot.querySelector("#container"),this.defaultSlot=this.shadowRoot.querySelector("slot:not([name])"),nH(this,lO,new MutationObserver(n$(this,lV)))}static get observedAttributes(){return[nY.DISABLED,nY.HIDDEN,nY.STYLE,nY.ANCHOR,iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER]}static formatMenuItemText(e,t){return e}enable(){this.addEventListener("click",this),this.addEventListener("focusout",this),this.addEventListener("keydown",this),this.addEventListener("invoke",this),this.addEventListener("toggle",this)}disable(){this.removeEventListener("click",this),this.removeEventListener("focusout",this),this.removeEventListener("keyup",this),this.removeEventListener("invoke",this),this.removeEventListener("toggle",this)}handleEvent(e){switch(e.type){case"slotchange":nV(this,lW,l$).call(this,e);break;case"invoke":nV(this,lY,lq).call(this,e);break;case"click":nV(this,l3,l4).call(this,e);break;case"toggle":nV(this,l8,l6).call(this,e);break;case"focusout":nV(this,dt,di).call(this,e);break;case"keydown":nV(this,da,dr).call(this,e)}}connectedCallback(){var e,t;n$(this,lO).observe(this.defaultSlot,{childList:!0}),nH(this,lU,(0,i0._l)(this.shadowRoot,":host")),nV(this,lK,lF).call(this),this.hasAttribute("disabled")||this.enable(),this.role||(this.role="menu"),nH(this,lL,(0,i0.iP)(this)),null==(t=null==(e=n$(this,lL))?void 0:e.associateElement)||t.call(e,this),this.hidden||((0,ay.X)(nj(this),n$(this,lX)),(0,ay.X)(this,n$(this,lQ))),nV(this,lB,lH).call(this),this.shadowRoot.addEventListener("slotchange",this)}disconnectedCallback(){var e,t;n$(this,lO).disconnect(),(0,ay.U)(nj(this),n$(this,lX)),(0,ay.U)(this,n$(this,lQ)),this.disable(),null==(t=null==(e=n$(this,lL))?void 0:e.unassociateElement)||t.call(e,this),nH(this,lL,null),nH(this,lD,null),nH(this,lx,null),this.shadowRoot.removeEventListener("slotchange",this)}attributeChangedCallback(e,t,i){var a,r,n,s;e===nY.HIDDEN&&i!==t?(n$(this,lP)||nH(this,lP,!0),this.hidden?nV(this,lZ,lz).
1341call(this):nV(this,lG,lj).call(this),this.dispatchEvent(new nU({oldState:this.hidden?"open":"closed",newState:this.hidden?"closed":"open",bubbles:!0}))):e===iq.MediaStateReceiverAttributes.MEDIA_CONTROLLER?(t&&(null==(r=null==(a=n$(this,lL))?void 0:a.unassociateElement)||r.call(a,this),nH(this,lL,null)),i&&this.isConnected&&(nH(this,lL,(0,i0.iP)(this)),null==(s=null==(n=n$(this,lL))?void 0:n.associateElement)||s.call(n,this))):e===nY.DISABLED&&i!==t?null==i?this.enable():this.disable():e===nY.STYLE&&i!==t&&nV(this,lK,lF).call(this)}formatMenuItemText(e,t){return this.constructor.formatMenuItemText(e,t)}get anchor(){return this.getAttribute("anchor")}set anchor(e){this.setAttribute("anchor",`${e}`)}get anchorElement(){var e;return this.anchor?null==(e=(0,i0.sy)(this))?void 0:e.querySelector(`#${this.anchor}`):null}get items(){return this.defaultSlot.assignedElements({flatten:!0}).filter(nG)}get radioGroupItems(){return this.items.filter(e=>"menuitemradio"===e.role)}get checkedItems(){return this.items.filter(e=>e.checked)}get value(){var e,t;return null!=(t=null==(e=this.checkedItems[0])?void 0:e.value)?t:""}set value(e){let t=this.items.find(t=>t.value===e);t&&nV(this,dh,dm).call(this,t)}focus(){if(nH(this,lD,(0,i0.vY)()),this.items.length){nV(this,du,dc).call(this,this.items[0]),this.items[0].focus();return}let e=this.querySelector('[autofocus], [tabindex]:not([tabindex="-1"]), [role="menu"]');null==e||e.focus()}handleSelect(e){var t;let i=nV(this,dn,ds).call(this,e);i&&(nV(this,dh,dm).call(this,i,"checkbox"===i.type),n$(this,lx)&&!this.hidden&&(null==(t=n$(this,lD))||t.focus(),this.hidden=!0))}get keysUsed(){return["Enter","Escape","Tab"," ","ArrowDown","ArrowUp","Home","End"]}handleMove(e){var t,i;let{key:a}=e,r=this.items,n=null!=(i=null!=(t=nV(this,dn,ds).call(this,e))?t:nV(this,dl,dd).call(this))?i:r[0],s=Math.max(0,r.indexOf(n));"ArrowDown"===a?s++:"ArrowUp"===a?s--:"Home"===e.key?s=0:"End"===e.key&&(s=r.length-1),s<0&&(s=r.length-1),s>r.length-1&&(s=0),nV(this,du,dc).call(this,r[s]),r[s].focus()}}function nG(e){return["menuitem","menuitemradio","menuitemcheckbox"].includes(null==e?void 0:e.role)}function nj(e){var t;return null!=(t=e.getAttribute("bounds")?(0,i0.l5)(e,`#${e.getAttribute("bounds")}`):(0,i0.Xq)(e)||e.parentElement)?t:e}lL=new WeakMap,lD=new WeakMap,lx=new WeakMap,lN=new WeakMap,lO=new WeakMap,lP=new WeakMap,lU=new WeakMap,lW=new WeakSet,l$=function(e){let t=e.target;for(let e of t.assignedNodes({flatten:!0}))3===e.nodeType&&""===e.textContent.trim()&&e.remove();["header","title"].includes(t.name)&&nV(this,lB,lH).call(this),t.name||n$(this,lV).call(this)},lB=new WeakSet,lH=function(){let e=this.shadowRoot.querySelector('slot[name="header"]'),t=this.shadowRoot.querySelector('slot[name="title"]');e.hidden=0===t.assignedNodes().length&&0===e.assignedNodes().length},lV=new WeakMap,lK=new WeakSet,lF=function(){var e;let t=this.shadowRoot.querySelector("#layout-row"),i=null==(e=getComputedStyle(this).getPropertyValue("--media-menu-layout"))?void 0:e.trim();t.setAttribute("media","row"===i?"":"width:0")},lY=new WeakSet,lq=function(e){nH(this,lx,e.relatedTarget),(0,i0.Mj)(this,e.relatedTarget)||(this.hidden=!this.hidden)},lG=new WeakSet,lj=function(){var e;null==(e=n$(this,lx))||e.setAttribute("aria-expanded","true"),this.addEventListener("transitionend",()=>this.focus(),{once:!0}),(0,ay.X)(nj(this),n$(this,lX)),(0,ay.X)(this,n$(this,lQ))},lZ=new WeakSet,lz=function(){var e;null==(e=n$(this,lx))||e.setAttribute("aria-expanded","false"),(0,ay.U)(nj(this),n$(this,lX)),(0,ay.U)(this,n$(this,lQ))},lX=new WeakMap,lQ=new WeakMap,lJ=new WeakSet,l0=function(e){if(this.hasAttribute("mediacontroller")&&!this.anchor||this.hidden||!this.anchorElement)return;let{x:t,y:i}=function({anchor:e,floating:t,placement:i}){let{x:a,y:r}=function({anchor:e,floating:t},i){let a;let r="x"==(["top","bottom"].includes(nO(i))?"y":"x")?"y":"x",n="y"===r?"height":"width",s=nO(i),o=e.x+e.width/2-t.width/2,l=e.y+e.height/2-t.height/2,d=e[n]/2-t[n]/2;switch(s){case"top":a={x:o,y:e.y-t.height};break;case"bottom":a={x:o,y:e.y+e.height};break;case"right":a={x:e.x+e.width,y:l};break;case"left":a={x:e.x-t.width,y:l};break;default:a={x:e.x,y:e.y}}switch(i.split("-")[1]){case"start":a[r]-=d;break;case"end":a[r]+=d}return a}(function({anchor:e,floating:t}){return{anchor:function(e,t){var i;let a=e.getBoundingClientRect(),r=null!=(i=null==t?void 0:t.getBoundingClientRect())?i:{x:0,y:0};return{x:a.x-r.x,y:a.y-r.y,width:a.width,height:a.height}}(e,t.offsetParent),floating:{x:0,y:0,width:t.offsetWidth,height:t.offsetHeight}}}({anchor:e,floating:t}),i);return{x:a,y:r}}({anchor:this.anchorElement,floating:this,placement:"top-start"});null!=e||(e=this.offsetWidth);let a=nj(this).getBoundingClientRect(),r=a.width-t-e,n=a.height-i-this.offsetHeight,{style:s}=n$(this,lU);s.setProperty("position","absolute"),s.setProperty("right",`${Math.max(0,r)}px`),s.setProperty("--_menu-bottom",`${n}px`);let o=getComputedStyle(this),l=s.getPropertyValue("--_menu-bottom")===o.bottom?n:parseFloat(o.bottom),d=a.height-l-parseFloat(o.marginBottom);this.style.setProperty("--_menu-max-height",`${d}px`)},l1=new WeakSet,l2=function(e){let t=this.querySelector('[role="menuitem"][aria-haspopup][aria-expanded="true"]'),i=null==t?void 0:t.querySelector('[role="menu"]'),{style:a}=n$(this,lU);if(e||a.setProperty("--media-menu-transition-in","none"),i){let e=i.offsetHeight,a=Math.max(i.offsetWidth,t.offsetWidth);this.style.setProperty("min-width",`${a}px`),this.style.setProperty("min-height",`${e}px`),nV(this,lJ,l0).call(this,a)}else this.style.removeProperty("min-width"),this.style.removeProperty("min-height"),nV(this,lJ,l0).call(this);a.removeProperty("--media-menu-transition-in")}
1341,l3=new WeakSet,l4=function(e){var t;if(e.stopPropagation(),e.composedPath().includes(n$(this,l5,l9))){null==(t=n$(this,lD))||t.focus(),this.hidden=!0;return}let i=nV(this,dn,ds).call(this,e);!i||i.hasAttribute("disabled")||(nV(this,du,dc).call(this,i),this.handleSelect(e))},l5=new WeakSet,l9=function(){var e;return null==(e=this.shadowRoot.querySelector('slot[name="header"]').assignedElements({flatten:!0}))?void 0:e.find(e=>e.matches('button[part~="back"]'))},l8=new WeakSet,l6=function(e){if(e.target===this)return;nV(this,l7,de).call(this);let t=Array.from(this.querySelectorAll('[role="menuitem"][aria-haspopup]'));for(let i of t)i.invokeTargetElement==e.target||"open"!=e.newState||"true"!=i.getAttribute("aria-expanded")||i.invokeTargetElement.hidden||i.invokeTargetElement.dispatchEvent(new nP({relatedTarget:i}));for(let e of t)e.setAttribute("aria-expanded",`${!e.submenuElement.hidden}`);nV(this,l1,l2).call(this,!0)},l7=new WeakSet,de=function(){let e=this.querySelector('[role="menuitem"] > [role="menu"]:not([hidden])');this.container.classList.toggle("has-expanded",!!e)},dt=new WeakSet,di=function(e){var t;(0,i0.Mj)(this,e.relatedTarget)||(n$(this,lP)&&(null==(t=n$(this,lD))||t.focus()),!n$(this,lx)||n$(this,lx)===e.relatedTarget||this.hidden||(this.hidden=!0))},da=new WeakSet,dr=function(e){var t,i,a,r,n;let{key:s,ctrlKey:o,altKey:l,metaKey:d}=e;if(!o&&!l&&!d&&this.keysUsed.includes(s)){if(e.preventDefault(),e.stopPropagation(),"Tab"===s){if(n$(this,lP)){this.hidden=!0;return}e.shiftKey?null==(i=null==(t=this.previousElementSibling)?void 0:t.focus)||i.call(t):null==(r=null==(a=this.nextElementSibling)?void 0:a.focus)||r.call(a),this.blur()}else"Escape"===s?(null==(n=n$(this,lD))||n.focus(),n$(this,lP)&&(this.hidden=!0)):"Enter"===s||" "===s?this.handleSelect(e):this.handleMove(e)}},dn=new WeakSet,ds=function(e){return e.composedPath().find(e=>["menuitemradio","menuitemcheckbox"].includes(e.role))},dl=new WeakSet,dd=function(){return this.items.find(e=>0===e.tabIndex)},du=new WeakSet,dc=function(e){for(let t of this.items)t.tabIndex=t===e?0:-1},dh=new WeakSet,dm=function(e,t){let i=[...this.checkedItems];"radio"===e.type&&this.radioGroupItems.forEach(e=>e.checked=!1),t?e.checked=!e.checked:e.checked=!0,this.checkedItems.some((e,t)=>e!=i[t])&&this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0}))},nq.shadowRootOptions={mode:"open"},nq.getTemplateHTML=function(e){return` 1342 <style> 1343 :host { 1344 font: var(--media-font, 1345 var(--media-font-weight, normal) 1346 var(--media-font-size, 14px) / 1347 var(--media-text-content-height, var(--media-control-height, 24px)) 1348 var(--media-font-family, helvetica neue, segoe ui, roboto, arial, sans-serif)); 1349 color: var(--media-text-color, var(--media-primary-color, rgb(238 238 238))); 1350 --_menu-bg: rgb(20 20 30 / .8); 1351 background: var(--media-menu-background, var(--media-control-background, var(--media-secondary-color, var(--_menu-bg)))); 1352 border-radius: var(--media-menu-border-radius); 1353 border: var(--media-menu-border, none); 1354 display: var(--media-menu-display, inline-flex) !important; 1355 1356 transition: var(--media-menu-transition-in, 1357 visibility 0s, 1358 opacity .2s ease-out, 1359 transform .15s ease-out, 1360 left .2s ease-in-out, 1361 min-width .2s ease-in-out, 1362 min-height .2s ease-in-out 1363 ) !important; 1364 1365 visibility: var(--media-menu-visibility, visible); 1366 opacity: var(--media-menu-opacity, 1); 1367 max-height: var(--media-menu-max-height, var(--_menu-max-height, 300px)); 1368 transform: var(--media-menu-transform-in, translateY(0) scale(1)); 1369 flex-direction: column; 1370 1371 min-height: 0; 1372 position: relative; 1373 bottom: var(--_menu-bottom); 1374 box-sizing: border-box; 1375 } 1376 1377 @-moz-document url-prefix() { 1378 :host{ 1379 --_menu-bg: rgb(20 20 30); 1380 } 1381 } 1382 1383 :host([hidden]) { 1384 transition: var(--media-menu-transition-out, 1385 visibility .15s ease-in, 1386 opacity .15s ease-in, 1387 transform .15s ease-in 1388 ) !important; 1389 visibility: var(--media-menu-hidden-visibility, hidden); 1390 opacity: var(--media-menu-hidden-opacity, 0); 1391 max-height: var(--media-menu-hidden-max-height, 1392 var(--media-menu-max-height, var(--_menu-max-height, 300px))); 1393 transform: var(--media-menu-transform-out, translateY(2px) scale(.99)); 1394 pointer-events: none; 1395 } 1396 1397 :host([slot="submenu"]) { 1398 background: none; 1399 width: 100%; 1400 min-height: 100%; 1401 position: absolute; 1402 bottom: 0; 1403 right: -100%; 1404 } 1405 1406 #container { 1407 display: flex; 1408 flex-direction: column; 1409 min-height: 0; 1410 transition: transform .2s ease-out; 1411 transform: translate(0, 0); 1412 } 1413 1414 #container.has-expanded { 1415 transition: transform .2s ease-in; 1416 transform: translate(-100%, 0); 1417 } 1418 1419 button { 1420 background: none; 1421 color: inherit; 1422 border: none; 1423 padding: 0; 1424 font: inherit; 1425 outline: inherit; 1426 display: inline-flex; 1427 align-items: center; 1428 } 1429 1430 slot[name="header"][hidden] { 1431 display: none; 1432 } 1433 1434 slot[name="header"] > *, 1435 slot[name="header"]::slotted(*) { 1436 padding: .4em .7em; 1437 border-bottom: 1px solid rgb(255 255 255 / .25); 1438 cursor: var(--media-cursor, default); 1439 } 1440 1441 slot[name="header"] > button[part~="back"], 1442 slot[name="header"]::slotted(button[part~="back"]) { 1443 cursor: var(--media-cursor, pointer); 1444 } 1445 1446 svg[part~="back"] { 1447 height: var(--media-menu-icon-height, var(--media-control-height, 24px)); 1448 fill: var(--media-icon-color, var(--media-primary-color, rgb(238 238 238))); 1449 display: block; 1450 margin-right: .5ch; 1451 } 1452 1453 slot:not([name]) { 1454 gap: var(--media-menu-gap); 1455 flex-direction: var(--media-menu-flex-direction, column); 1456 overflow: var(--media-menu-overflow, hidden auto); 1457 display: flex; 1458 min-height: 0; 1459 } 1460 1461 :host([role="menu"]) slot:not([name]) { 1462 padding-block: .4em; 1463 } 1464 1465 slot:not([name])::slotted([role="menu"]) { 1466 background: none; 1467 } 1468 1469 media-chrome-menu-item > span { 1470 margin-right: .5ch; 1471 max-width: var(--media-menu-item-max-width); 1472 text-overflow: ellipsis; 1473 overflow: hidden; 1474 } 1475 </style> 1476 <style id="layout-row" media="width:0"> 1477 1478 slot[name="header"] > *, 1479 slot[name="header"]::slotted(*) { 1480 padding: .4em .5em; 1481 } 1482 1483 slot:not([name]) { 1484 gap: var(--media-menu-gap, .25em); 1485 flex-direction: var(--media-menu-flex-direction, row); 1486 padding-inline: .5em; 1487 } 1488 1489 media-chrome-menu-item { 1490 padding: .3em .5em; 1491 } 1492 1493 media-chrome-menu-item[aria-checked="true"] { 1494 background: var(--media-menu-item-checked-background, rgb(255 255 255 / .2)); 1495 } 1496 1497 1498 media-chrome-menu-item::part(checked-indicator) { 1499 display: var(--media-menu-item-checked-indicator-display, none); 1500 } 1501 </style> 1502 <div id="container" part="container"> 1503 <slot name="header" hidden> 1504 <button part="back button" aria-label="Back to previous menu"> 1505 <slot name="back-icon"> 1506 <svg aria-hidden="true" viewBox="0 0 20 24" part="back indicator"> 1507 <path d="m11.88 17.585.742-.669-4.2-4.665 4.2-4.666-.743-.669-4.803 5.335 4.803 5.334Z"/> 1508 </svg> 1509 </slot> 1510 <slot name="title"></slot> 1511 </button> 1512 </slot> 1513 <slot></slot> 1514 </div> 1515 <slot name="checked-indicator" hidden></slot> 1516 `},i1.Mq.customElements.get("media-chrome-menu")||i1.Mq.customElements.define("media-chrome-menu",nq);var nZ=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},nz=(e,t,i)=>
1516(nZ(e,t,"read from private field"),i?i.call(e):t.get(e)),nX=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},nQ=(e,t,i,a)=>(nZ(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),nJ=(e,t,i)=>(nZ(e,t,"access private method"),i);let n0={TYPE:"type",VALUE:"value",CHECKED:"checked",DISABLED:"disabled"};class n1 extends i1.Mq.HTMLElement{constructor(){if(super(),nX(this,dv),nX(this,dg),nX(this,dA),nX(this,dI),nX(this,dp,!1),nX(this,db,void 0),nX(this,dT,()=>{var e,t;this.submenuElement.items&&this.setAttribute("submenusize",`${this.submenuElement.items.length}`);let i=this.shadowRoot.querySelector('slot[name="description"]'),a=null==(e=this.submenuElement.checkedItems)?void 0:e[0],r=null!=(t=null==a?void 0:a.dataset.description)?t:null==a?void 0:a.text,n=i1.tj.createElement("span");n.textContent=null!=r?r:"",i.replaceChildren(n)}),nX(this,dk,e=>{let{key:t}=e;if(!this.keysUsed.includes(t)){this.removeEventListener("keyup",nz(this,dk));return}this.handleClick(e)}),nX(this,dM,e=>{let{metaKey:t,altKey:i,key:a}=e;if(t||i||!this.keysUsed.includes(a)){this.removeEventListener("keyup",nz(this,dk));return}this.addEventListener("keyup",nz(this,dk),{once:!0})}),!this.shadowRoot){this.attachShadow(this.constructor.shadowRootOptions);let e=(0,i0.OO)(this.attributes);this.shadowRoot.innerHTML=this.constructor.getTemplateHTML(e)}}static get observedAttributes(){return[n0.TYPE,n0.DISABLED,n0.CHECKED,n0.VALUE]}enable(){this.hasAttribute("tabindex")||this.setAttribute("tabindex","-1"),n2(this)&&!this.hasAttribute("aria-checked")&&this.setAttribute("aria-checked","false"),this.addEventListener("click",this),this.addEventListener("keydown",this)}disable(){this.removeAttribute("tabindex"),this.removeEventListener("click",this),this.removeEventListener("keydown",this),this.removeEventListener("keyup",this)}handleEvent(e){switch(e.type){case"slotchange":nJ(this,dv,dE).call(this,e);break;case"click":this.handleClick(e);break;case"keydown":nz(this,dM).call(this,e);break;case"keyup":nz(this,dk).call(this,e)}}attributeChangedCallback(e,t,i){e===n0.CHECKED&&n2(this)&&!nz(this,dp)?this.setAttribute("aria-checked",null!=i?"true":"false"):e===n0.TYPE&&i!==t?this.role="menuitem"+i:e===n0.DISABLED&&i!==t&&(null==i?this.enable():this.disable())}connectedCallback(){this.hasAttribute(n0.DISABLED)||this.enable(),this.role="menuitem"+this.type,nQ(this,db,function e(t,i){if(!t)return null;let{host:a}=t.getRootNode();return!i&&a?e(t,a):(null==i?void 0:i.items)?i:e(i,null==i?void 0:i.parentNode)}(this,this.parentNode)),nJ(this,dI,d_).call(this),this.submenuElement&&nJ(this,dg,df).call(this),this.shadowRoot.addEventListener("slotchange",this)}disconnectedCallback(){this.disable(),nJ(this,dI,d_).call(this),nQ(this,db,null),this.shadowRoot.removeEventListener("slotchange",this)}get invokeTarget(){return this.getAttribute("invoketarget")}set invokeTarget(e){this.setAttribute("invoketarget",`${e}`)}get invokeTargetElement(){var e;return this.invokeTarget?null==(e=(0,i0.sy)(this))?void 0:e.querySelector(`#${this.invokeTarget}`):this.submenuElement}get submenuElement(){return this.shadowRoot.querySelector('slot[name="submenu"]').assignedElements({flatten:!0})[0]}get type(){var e;return null!=(e=this.getAttribute(n0.TYPE))?e:""}set type(e){this.setAttribute(n0.TYPE,`${e}`)}get value(){var e;return null!=(e=this.getAttribute(n0.VALUE))?e:this.text}set value(e){this.setAttribute(n0.VALUE,e)}get text(){var e;return(null!=(e=this.textContent)?e:"").trim()}get checked(){if(n2(this))return"true"===this.getAttribute("aria-checked")}set checked(e){n2(this)&&(nQ(this,dp,!0),this.setAttribute("aria-checked",e?"true":"false"),e?this.part.add("checked"):this.part.remove("checked"))}handleClick(e){!n2(this)&&this.invokeTargetElement&&(0,i0.Mj)(this,e.target)&&this.invokeTargetElement.dispatchEvent(new nP({relatedTarget:this}))}get keysUsed(){return["Enter"," "]}}function n2(e){return"radio"===e.type||"checkbox"===e.type}dp=new WeakMap,db=new WeakMap,dv=new WeakSet,dE=function(e){let t=e.target;if(!(null==t?void 0:t.name))for(let e of t.assignedNodes({flatten:!0}))e instanceof Text&&""===e.textContent.trim()&&e.remove();"submenu"===t.name&&(this.submenuElement?nJ(this,dg,df).call(this):nJ(this,dA,dy).call(this))},dg=new WeakSet,df=async function(){this.setAttribute("aria-haspopup","menu"),this.setAttribute("aria-expanded",`${!this.submenuElement.hidden}`),this.submenuElement.addEventListener("change",nz(this,dT)),this.submenuElement.addEventListener("addmenuitem",nz(this,dT)),this.submenuElement.addEventListener("removemenuitem",nz(this,dT)),nz(this,dT).call(this)},dA=new WeakSet,dy=function(){this.removeAttribute("aria-haspopup"),this.removeAttribute("aria-expanded"),this.submenuElement.removeEventListener("change",nz(this,dT)),this.submenuElement.removeEventListener("addmenuitem",nz(this,dT)),this.submenuElement.removeEventListener("removemenuitem",nz(this,dT)),nz(this,dT).call(this)},dT=new WeakMap,dk=new WeakMap,dM=new WeakMap,dI=new WeakSet,d_=function(){var e;let t=null==(e=nz(this,db))?void 0:e.radioGroupItems;if(!t)return;let i=t.filter(e=>"true"===e.getAttribute("aria-checked")).pop();
1516for(let e of(i||(i=t[0]),t))e.setAttribute("aria-checked","false");null==i||i.setAttribute("aria-checked","true")},n1.shadowRootOptions={mode:"open"},n1.getTemplateHTML=function(e){return` 1517 <style> 1518 :host { 1519 transition: var(--media-menu-item-transition, 1520 background .15s linear, 1521 opacity .2s ease-in-out 1522 ); 1523 outline: var(--media-menu-item-outline, 0); 1524 outline-offset: var(--media-menu-item-outline-offset, -1px); 1525 cursor: var(--media-cursor, pointer); 1526 display: flex; 1527 align-items: center; 1528 align-self: stretch; 1529 justify-self: stretch; 1530 white-space: nowrap; 1531 white-space-collapse: collapse; 1532 text-wrap: nowrap; 1533 padding: .4em .8em .4em 1em; 1534 } 1535 1536 :host(:focus-visible) { 1537 box-shadow: var(--media-menu-item-focus-shadow, inset 0 0 0 2px rgb(27 127 204 / .9)); 1538 outline: var(--media-menu-item-hover-outline, 0); 1539 outline-offset: var(--media-menu-item-hover-outline-offset, var(--media-menu-item-outline-offset, -1px)); 1540 } 1541 1542 :host(:hover) { 1543 cursor: var(--media-cursor, pointer); 1544 background: var(--media-menu-item-hover-background, rgb(92 92 102 / .5)); 1545 outline: var(--media-menu-item-hover-outline); 1546 outline-offset: var(--media-menu-item-hover-outline-offset, var(--media-menu-item-outline-offset, -1px)); 1547 } 1548 1549 :host([aria-checked="true"]) { 1550 background: var(--media-menu-item-checked-background); 1551 } 1552 1553 :host([hidden]) { 1554 display: none; 1555 } 1556 1557 :host([disabled]) { 1558 pointer-events: none; 1559 color: rgba(255, 255, 255, .3); 1560 } 1561 1562 slot:not([name]) { 1563 width: 100%; 1564 } 1565 1566 slot:not([name="submenu"]) { 1567 display: inline-flex; 1568 align-items: center; 1569 transition: inherit; 1570 opacity: var(--media-menu-item-opacity, 1); 1571 } 1572 1573 slot[name="description"] { 1574 justify-content: end; 1575 } 1576 1577 slot[name="description"] > span { 1578 display: inline-block; 1579 margin-inline: 1em .2em; 1580 max-width: var(--media-menu-item-description-max-width, 100px); 1581 text-overflow: ellipsis; 1582 overflow: hidden; 1583 font-size: .8em; 1584 font-weight: 400; 1585 text-align: right; 1586 position: relative; 1587 top: .04em; 1588 } 1589 1590 slot[name="checked-indicator"] { 1591 display: none; 1592 } 1593 1594 :host(:is([role="menuitemradio"],[role="menuitemcheckbox"])) slot[name="checked-indicator"] { 1595 display: var(--media-menu-item-checked-indicator-display, inline-block); 1596 } 1597 1598 1599 svg, img, ::slotted(svg), ::slotted(img) { 1600 height: var(--media-menu-item-icon-height, var(--media-control-height, 24px)); 1601 fill: var(--media-icon-color, var(--media-primary-color, rgb(238 238 238))); 1602 display: block; 1603 } 1604 1605 1606 [part~="indicator"], 1607 ::slotted([part~="indicator"]) { 1608 fill: var(--media-menu-item-indicator-fill, 1609 var(--media-icon-color, var(--media-primary-color, rgb(238 238 238)))); 1610 height: var(--media-menu-item-indicator-height, 1.25em); 1611 margin-right: .5ch; 1612 } 1613 1614 [part~="checked-indicator"] { 1615 visibility: hidden; 1616 } 1617 1618 :host([aria-checked="true"]) [part~="checked-indicator"] { 1619 visibility: visible; 1620 } 1621 </style> 1622 <slot name="checked-indicator"> 1623 <svg aria-hidden="true" viewBox="0 1 24 24" part="checked-indicator indicator"> 1624 <path d="m10 15.17 9.193-9.191 1.414 1.414-10.606 10.606-6.364-6.364 1.414-1.414 4.95 4.95Z"/> 1625 </svg> 1626 </slot> 1627 <slot name="prefix"></slot> 1628 <slot></slot> 1629 <slot name="description"></slot> 1630 <slot name="suffix"> 1631 ${this.getSuffixSlotInnerHTML(e)} 1632 </slot> 1633 <slot name="submenu"></slot> 1634 `},n1.getSuffixSlotInnerHTML=function(e){return""},i1.Mq.customElements.get("media-chrome-menu-item")||i1.Mq.customElements.define("media-chrome-menu-item",n1);class n3 extends nq{get anchorElement(){return"auto"!==this.anchor?super.anchorElement:(0,i0.Xq)(this).querySelector("media-settings-menu-button")}}n3.getTemplateHTML=function(e){return` 1635 ${nq.getTemplateHTML(e)} 1636 <style> 1637 :host { 1638 --_menu-bg: rgb(20 20 30 / .8); 1639 background: var(--media-settings-menu-background, 1640 var(--media-menu-background, 1641 var(--media-control-background, 1642 var(--media-secondary-color, var(--_menu-bg))))); 1643 min-width: var(--media-settings-menu-min-width, 170px); 1644 border-radius: 2px 2px 0 0; 1645 overflow: hidden; 1646 } 1647 1648 @-moz-document url-prefix() { 1649 :host{ 1650 --_menu-bg: rgb(20 20 30); 1651 } 1652 } 1653 1654 :host([role="menu"]) { 1655 1656 justify-content: end; 1657 } 1658 1659 slot:not([name]) { 1660 justify-content: var(--media-settings-menu-justify-content); 1661 flex-direction: var(--media-settings-menu-flex-direction, column); 1662 overflow: visible; 1663 } 1664 1665 #container.has-expanded { 1666 --media-settings-menu-item-opacity: 0; 1667 } 1668 </style> 1669 `},i1.Mq.customElements.get("media-settings-menu")||i1.Mq.customElements.define("media-settings-menu",n3);class n4 extends n1{}n4.shadowRootOptions={mode:"open"},n4.getTemplateHTML=function(e){return` 1670 ${n1.getTemplateHTML.call(this,e)} 1671 <style> 1672 slot:not([name="submenu"]) { 1673 opacity: var(--media-settings-menu-item-opacity, var(--media-menu-item-opacity)); 1674 } 1675 1676 :host([aria-expanded="true"]:hover) { 1677 background: transparent; 1678 } 1679 </style> 1680 `},n4.getSuffixSlotInnerHTML=function(e){return` 1681 <svg aria-hidden="true" viewBox="0 0 20 24"> 1682 <path d="m8.12 17.585-.742-.669 4.2-4.665-4.2-4.666.743-.669 4.803 5.335-4.803 5.334Z"/> 1683 </svg> 1684 `},i1.Mq.customElements.get("media-settings-menu-item")||i1.Mq.customElements.define("media-settings-menu-item",n4);class n5 extends at{connectedCallback(){super.connectedCallback(),this.invokeTargetElement&&this.setAttribute("aria-haspopup","menu")}get invokeTarget(){return this.getAttribute("invoketarget")}set invokeTarget(e){this.setAttribute("invoketarget",`${e}`)}get invokeTargetElement(){var e;return this.invokeTarget?null==(e=(0,i0.sy)(this))?void 0:e.querySelector(`#${this.invokeTarget}`):null}handleClick(){var e;null==(e=this.invokeTargetElement)||e.dispatchEvent(new nP({relatedTarget:this}))}}i1.Mq.customElements.get("media-chrome-menu-button")||i1.Mq.customElements.define("media-chrome-menu-button",n5);
1684class n9 extends n5{static get observedAttributes(){return[...super.observedAttributes,"target"]}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-label",(0,ij.t)("settings"))}get invokeTargetElement(){return void 0!=this.invokeTarget?super.invokeTargetElement:(0,i0.Xq)(this).querySelector("media-settings-menu")}}n9.getSlotTemplateHTML=function(){return` 1685 <style> 1686 :host([aria-expanded="true"]) slot[name=tooltip] { 1687 display: none; 1688 } 1689 </style> 1690 <slot name="icon"> 1691 <svg aria-hidden="true" viewBox="0 0 24 24"> 1692 <path d="M4.5 14.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Zm7.5 0a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Zm7.5 0a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Z"/> 1693 </svg> 1694 </slot> 1695 `},n9.getTooltipContentHTML=function(){return(0,ij.t)("Settings")},i1.Mq.customElements.get("media-settings-menu-button")||i1.Mq.customElements.define("media-settings-menu-button",n9);var n8=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},n6=(e,t,i)=>(n8(e,t,"read from private field"),i?i.call(e):t.get(e)),n7=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},se=(e,t,i,a)=>(n8(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),st=(e,t,i)=>(n8(e,t,"access private method"),i);class si extends nq{constructor(){super(...arguments),n7(this,dR),n7(this,dL),n7(this,dw,[]),n7(this,dC,void 0)}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_LIST,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_ENABLED,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_UNAVAILABLE]}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_ENABLED&&t!==i?this.value=i:e===iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_LIST&&t!==i&&(se(this,dw,(0,iG.Du)(null!=i?i:"")),st(this,dR,dS).call(this))}connectedCallback(){super.connectedCallback(),this.addEventListener("change",st(this,dL,dD))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("change",st(this,dL,dD))}get anchorElement(){var e;return"auto"!==this.anchor?super.anchorElement:null==(e=(0,i0.Xq)(this))?void 0:e.querySelector("media-audio-track-menu-button")}get mediaAudioTrackList(){return n6(this,dw)}set mediaAudioTrackList(e){se(this,dw,e),st(this,dR,dS).call(this)}get mediaAudioTrackEnabled(){var e;return null!=(e=(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_ENABLED))?e:""}set mediaAudioTrackEnabled(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_ENABLED,e)}}dw=new WeakMap,dC=new WeakMap,dR=new WeakSet,dS=function(){if(n6(this,dC)===JSON.stringify(this.mediaAudioTrackList))return;se(this,dC,JSON.stringify(this.mediaAudioTrackList));let e=this.mediaAudioTrackList;for(let t of(this.defaultSlot.textContent="",e.sort((e,t)=>e.id.localeCompare(t.id,void 0,{numeric:!0})),e)){let e=nK({type:"radio",text:this.formatMenuItemText(t.label,t),value:`${t.id}`,checked:t.enabled});
1695e.prepend(nF(this,"checked-indicator")),this.defaultSlot.append(e)}},dL=new WeakSet,dD=function(){if(null==this.value)return;let e=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_AUDIO_TRACK_REQUEST,{composed:!0,bubbles:!0,detail:this.value});this.dispatchEvent(e)},i1.Mq.customElements.get("media-audio-track-menu")||i1.Mq.customElements.define("media-audio-track-menu",si);let sa=`<svg aria-hidden="true" viewBox="0 0 24 24"> 1696 <path d="M11 17H9.5V7H11v10Zm-3-3H6.5v-4H8v4Zm6-5h-1.5v6H14V9Zm3 7h-1.5V8H17v8Z"/> 1697 <path d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Zm-2 0a8 8 0 1 0-16 0 8 8 0 0 0 16 0Z"/> 1698</svg>`,sr=e=>{let t=(0,ij.t)("Audio");e.setAttribute("aria-label",t)};class sn extends n5{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_ENABLED,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_UNAVAILABLE]}connectedCallback(){super.connectedCallback(),sr(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_LANG&&sr(this)}get invokeTargetElement(){var e;return void 0!=this.invokeTarget?super.invokeTargetElement:null==(e=(0,i0.Xq)(this))?void 0:e.querySelector("media-audio-track-menu")}get mediaAudioTrackEnabled(){var e;return null!=(e=(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_ENABLED))?e:""}set mediaAudioTrackEnabled(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_AUDIO_TRACK_ENABLED,e)}}sn.getSlotTemplateHTML=function(){return` 1699 <style> 1700 :host([aria-expanded="true"]) slot[name=tooltip] { 1701 display: none; 1702 } 1703 </style> 1704 <slot name="icon">${sa}</slot> 1705 `},sn.getTooltipContentHTML=function(){return(0,ij.t)("Audio")},i1.Mq.customElements.get("media-audio-track-menu-button")||i1.Mq.customElements.define("media-audio-track-menu-button",sn);var ss=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},so=(e,t,i)=>(ss(e,t,"read from private field"),i?i.call(e):t.get(e)),sl=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},sd=(e,t,i,a)=>(ss(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),su=(e,t,i)=>(ss(e,t,"access private method"),i);let sc=` 1706 <svg aria-hidden="true" viewBox="0 0 26 24" part="captions-indicator indicator"> 1707 <path d="M22.83 5.68a2.58 2.58 0 0 0-2.3-2.5c-3.62-.24-11.44-.24-15.06 0a2.58 2.58 0 0 0-2.3 2.5c-.23 4.21-.23 8.43 0 12.64a2.58 2.58 0 0 0 2.3 2.5c3.62.24 11.44.24 15.06 0a2.58 2.58 0 0 0 2.3-2.5c.23-4.21.23-8.43 0-12.64Zm-11.39 9.45a3.07 3.07 0 0 1-1.91.57 3.06 3.06 0 0 1-2.34-1 3.75 3.75 0 0 1-.92-2.67 3.92 3.92 0 0 1 .92-2.77 3.18 3.18 0 0 1 2.43-1 2.94 2.94 0 0 1 2.13.78c.364.359.62.813.74 1.31l-1.43.35a1.49 1.49 0 0 0-1.51-1.17 1.61 1.61 0 0 0-1.29.58 2.79 2.79 0 0 0-.5 1.89 3 3 0 0 0 .49 1.93 1.61 1.61 0 0 0 1.27.58 1.48 1.48 0 0 0 1-.37 2.1 2.1 0 0 0 .59-1.14l1.4.44a3.23 3.23 0 0 1-1.07 1.69Zm7.22 0a3.07 3.07 0 0 1-1.91.57 3.06 3.06 0 0 1-2.34-1 3.75 3.75 0 0 1-.92-2.67 3.88 3.88 0 0 1 .93-2.77 3.14 3.14 0 0 1 2.42-1 3 3 0 0 1 2.16.82 2.8 2.8 0 0 1 .73 1.31l-1.43.35a1.49 1.49 0 0 0-1.51-1.21 1.61 1.61 0 0 0-1.29.58A2.79 2.79 0 0 0 15 12a3 3 0 0 0 .49 1.93 1.61 1.61 0 0 0 1.27.58 1.44 1.44 0 0 0 1-.37 2.1 2.1 0 0 0 .6-1.15l1.4.44a3.17 3.17 0 0 1-1.1 1.7Z"/> 1708 </svg>`;class sh extends nq{constructor(){super(...arguments),sl(this,dN),sl(this,dP),sl(this,dx,void 0)}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING]}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST&&t!==i?su(this,dN,dO).call(this):e===iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING&&t!==i&&(this.value=i||"",su(this,dN,dO).call(this))}connectedCallback(){super.connectedCallback(),this.addEventListener("change",su(this,dP,dU))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("change",su(this,dP,dU))}get anchorElement(){return"auto"!==this.anchor?super.anchorElement:(0,i0.Xq)(this).querySelector("media-captions-menu-button")}get mediaSubtitlesList(){return sm(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST)}set mediaSubtitlesList(e){sp(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST,e)}get mediaSubtitlesShowing(){return sm(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING)}set mediaSubtitlesShowing(e){sp(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING,e)}}dx=new WeakMap,dN=new WeakSet,dO=function(){var e;let t=so(this,dx)!==JSON.stringify(this.mediaSubtitlesList),i=this.value!==this.getAttribute(iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING);if(!t&&!i)return;sd(this,dx,JSON.stringify(this.mediaSubtitlesList)),this.defaultSlot.textContent="";let a=!this.value,r=nK({type:"radio",text:this.formatMenuItemText((0,ij.t)("Off")),value:"off",checked:a});for(let t of(r.prepend(nF(this,"checked-indicator")),this.defaultSlot.append(r),this.mediaSubtitlesList)){let i=nK({type:"radio",text:this.formatMenuItemText(t.label,t),value:(0,an.Ly)(t),checked:this.value==(0,an.Ly)(t)});i.prepend(nF(this,"checked-indicator")),"captions"===(null!=(e=t.kind)?e:"subs")&&i.append(nF(this,"captions-indicator")),this.defaultSlot.append(i)}},dP=new WeakSet,dU=function(){let e=this.mediaSubtitlesShowing,t=this.getAttribute(iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING),i=this.value!==t;if((null==e?void 0:e.length)&&i&&this.dispatchEvent(new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_DISABLE_SUBTITLES_REQUEST,{composed:!0,bubbles:!0,detail:e})),!this.value||!i)return;let a=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_SHOW_SUBTITLES_REQUEST,{composed:!0,bubbles:!0,detail:this.value});this.dispatchEvent(a)},sh.getTemplateHTML=function(e){return` 1709 ${nq.getTemplateHTML(e)} 1710 <slot name="captions-indicator" hidden>${sc}</slot> 1711 `};let sm=(e,t)=>{let i=e.getAttribute(t);return i?(0,an.tm)(i):[]},sp=(e,t,i)=>{if(!(null==i?void 0:i.length)){e.removeAttribute(t);return}let a=(0,an.fj)(i);e.getAttribute(t)!==a&&e.setAttribute(t,a)};i1.Mq.customElements.get("media-captions-menu")||i1.Mq.customElements.define("media-captions-menu",sh);let sb=`<svg aria-hidden="true" viewBox="0 0 26 24"> 1712 <path d="M22.83 5.68a2.58 2.58 0 0 0-2.3-2.5c-3.62-.24-11.44-.24-15.06 0a2.58 2.58 0 0 0-2.3 2.5c-.23 4.21-.23 8.43 0 12.64a2.58 2.58 0 0 0 2.3 2.5c3.62.24 11.44.24 15.06 0a2.58 2.58 0 0 0 2.3-2.5c.23-4.21.23-8.43 0-12.64Zm-11.39 9.45a3.07 3.07 0 0 1-1.91.57 3.06 3.06 0 0 1-2.34-1 3.75 3.75 0 0 1-.92-2.67 3.92 3.92 0 0 1 .92-2.77 3.18 3.18 0 0 1 2.43-1 2.94 2.94 0 0 1 2.13.78c.364.359.62.813.74 1.31l-1.43.35a1.49 1.49 0 0 0-1.51-1.17 1.61 1.61 0 0 0-1.29.58 2.79 2.79
17120 0 0-.5 1.89 3 3 0 0 0 .49 1.93 1.61 1.61 0 0 0 1.27.58 1.48 1.48 0 0 0 1-.37 2.1 2.1 0 0 0 .59-1.14l1.4.44a3.23 3.23 0 0 1-1.07 1.69Zm7.22 0a3.07 3.07 0 0 1-1.91.57 3.06 3.06 0 0 1-2.34-1 3.75 3.75 0 0 1-.92-2.67 3.88 3.88 0 0 1 .93-2.77 3.14 3.14 0 0 1 2.42-1 3 3 0 0 1 2.16.82 2.8 2.8 0 0 1 .73 1.31l-1.43.35a1.49 1.49 0 0 0-1.51-1.21 1.61 1.61 0 0 0-1.29.58A2.79 2.79 0 0 0 15 12a3 3 0 0 0 .49 1.93 1.61 1.61 0 0 0 1.27.58 1.44 1.44 0 0 0 1-.37 2.1 2.1 0 0 0 .6-1.15l1.4.44a3.17 3.17 0 0 1-1.1 1.7Z"/> 1713</svg>`,sv=`<svg aria-hidden="true" viewBox="0 0 26 24"> 1714 <path d="M17.73 14.09a1.4 1.4 0 0 1-1 .37 1.579 1.579 0 0 1-1.27-.58A3 3 0 0 1 15 12a2.8 2.8 0 0 1 .5-1.85 1.63 1.63 0 0 1 1.29-.57 1.47 1.47 0 0 1 1.51 1.2l1.43-.34A2.89 2.89 0 0 0 19 9.07a3 3 0 0 0-2.14-.78 3.14 3.14 0 0 0-2.42 1 3.91 3.91 0 0 0-.93 2.78 3.74 3.74 0 0 0 .92 2.66 3.07 3.07 0 0 0 2.34 1 3.07 3.07 0 0 0 1.91-.57 3.17 3.17 0 0 0 1.07-1.74l-1.4-.45c-.083.43-.3.822-.62 1.12Zm-7.22 0a1.43 1.43 0 0 1-1 .37 1.58 1.58 0 0 1-1.27-.58A3 3 0 0 1 7.76 12a2.8 2.8 0 0 1 .5-1.85 1.63 1.63 0 0 1 1.29-.57 1.47 1.47 0 0 1 1.51 1.2l1.43-.34a2.81 2.81 0 0 0-.74-1.32 2.94 2.94 0 0 0-2.13-.78 3.18 3.18 0 0 0-2.43 1 4 4 0 0 0-.92 2.78 3.74 3.74 0 0 0 .92 2.66 3.07 3.07 0 0 0 2.34 1 3.07 3.07 0 0 0 1.91-.57 3.23 3.23 0 0 0 1.07-1.74l-1.4-.45a2.06 2.06 0 0 1-.6 1.07Zm12.32-8.41a2.59 2.59 0 0 0-2.3-2.51C18.72 3.05 15.86 3 13 3c-2.86 0-5.72.05-7.53.17a2.59 2.59 0 0 0-2.3 2.51c-.23 4.207-.23 8.423 0 12.63a2.57 2.57 0 0 0 2.3 2.5c1.81.13 4.67.19 7.53.19 2.86 0 5.72-.06 7.53-.19a2.57 2.57 0 0 0 2.3-2.5c.23-4.207.23-8.423 0-12.63Zm-1.49 12.53a1.11 1.11 0 0 1-.91 1.11c-1.67.11-4.45.18-7.43.18-2.98 0-5.76-.07-7.43-.18a1.11 1.11 0 0 1-.91-1.11c-.21-4.14-.21-8.29 0-12.43a1.11 1.11 0 0 1 .91-1.11C7.24 4.56 10 4.49 13 4.49s5.76.07 7.43.18a1.11 1.11 0 0 1 .91 1.11c.21 4.14.21 8.29 0 12.43Z"/> 1715</svg>`,sE=e=>{e.setAttribute("data-captions-enabled",(0,an.hi)(e).toString())},sg=e=>{e.setAttribute("aria-label",(0,ij.t)("closed captions"))};class sf extends n5{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING,iq.MediaUIAttributes.MEDIA_LANG]}connectedCallback(){super.connectedCallback(),sg(this),sE(this)}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING?sE(this):e===iq.MediaUIAttributes.MEDIA_LANG&&sg(this)}get invokeTargetElement(){var e;return void 0!=this.invokeTarget?super.invokeTargetElement:null==(e=(0,i0.Xq)(this))?void 0:e.querySelector("media-captions-menu")}get mediaSubtitlesList(){return sA(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST)}set mediaSubtitlesList(e){sy(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_LIST,e)}get mediaSubtitlesShowing(){return sA(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING)}set mediaSubtitlesShowing(e){sy(this,iq.MediaUIAttributes.MEDIA_SUBTITLES_SHOWING,e)}}sf.getSlotTemplateHTML=function(){return` 1716 <style> 1717 :host([data-captions-enabled="true"]) slot[name=off] { 1718 display: none !important; 1719 } 1720 1721 1722 :host(:not([data-captions-enabled="true"])) slot[name=on] { 1723 display: none !important; 1724 } 1725 1726 :host([aria-expanded="true"]) slot[name=tooltip] { 1727 display: none; 1728 } 1729 </style> 1730 1731 <slot name="icon"> 1732 <slot name="on">${sb}</slot> 1733 <slot name="off">${sv}</slot> 1734 </slot> 1735 `},sf.getTooltipContentHTML=function(){return(0,ij.t)("Captions")};let sA=(e,t)=>{let i=e.getAttribute(t);return i?(0,an.tm)(i):[]},sy=(e,t,i)=>{if(!(null==i?void 0:i.length)){e.removeAttribute(t);return}let a=(0,an.fj)(i);e.getAttribute(t)!==a&&e.setAttribute(t,a)};i1.Mq.customElements.get("media-captions-menu-button")||i1.Mq.customElements.define("media-captions-menu-button",sf);var sT=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},sk=(e,t,i)=>(sT(e,t,"read from private field"),i?i.call(e):t.get(e)),sM=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},sI=(e,t,i)=>(sT(e,t,"access private method"),i);let s_={RATES:"rates"};class sw extends nq{constructor(){super(),sM(this,d$),sM(this,dH),sM(this,dW,new rk.D(this,s_.RATES,{defaultValue:rC}
1735)),sI(this,d$,dB).call(this)}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,s_.RATES]}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE&&t!=i?(this.value=i,sI(this,d$,dB).call(this)):e===s_.RATES&&t!=i&&(sk(this,dW).value=i,sI(this,d$,dB).call(this))}connectedCallback(){super.connectedCallback(),this.addEventListener("change",sI(this,dH,dV))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("change",sI(this,dH,dV))}get anchorElement(){return"auto"!==this.anchor?super.anchorElement:(0,i0.Xq)(this).querySelector("media-playback-rate-menu-button")}get rates(){return sk(this,dW)}set rates(e){e?Array.isArray(e)?sk(this,dW).value=e.join(" "):"string"==typeof e&&(sk(this,dW).value=e):sk(this,dW).value="",sI(this,d$,dB).call(this)}get mediaPlaybackRate(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,1)}set mediaPlaybackRate(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,e)}}dW=new WeakMap,d$=new WeakSet,dB=function(){this.defaultSlot.textContent="";let e=rR(this.mediaPlaybackRate),t=new Set(Array.from(sk(this,dW)).map(e=>rR(Number(e))));for(let i of(e>0&&!t.has(e)&&t.add(e),Array.from(t).sort((e,t)=>e-t))){let t=nK({type:"radio",text:this.formatMenuItemText(`${i}x`,i),value:i.toString(),checked:e===i});t.prepend(nF(this,"checked-indicator")),this.defaultSlot.append(t)}},dH=new WeakSet,dV=function(){if(!this.value)return;let e=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_PLAYBACK_RATE_REQUEST,{composed:!0,bubbles:!0,detail:this.value});this.dispatchEvent(e)},i1.Mq.customElements.get("media-playback-rate-menu")||i1.Mq.customElements.define("media-playback-rate-menu",sw);class sC extends n5{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE]}constructor(){var e;super(),this.container=this.shadowRoot.querySelector('slot[name="icon"]'),this.container.innerHTML=`${rR(null!=(e=this.mediaPlaybackRate)?e:1)}x`}attributeChangedCallback(e,t,i){if(super.attributeChangedCallback(e,t,i),e===iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE){let e=i?+i:Number.NaN,t=rR(Number.isNaN(e)?1:e);this.container.innerHTML=`${t}x`,this.setAttribute("aria-label",(0,ij.t)("Playback rate {playbackRate}",{playbackRate:t}))}}get invokeTargetElement(){return void 0!=this.invokeTarget?super.invokeTargetElement:(0,i0.Xq)(this).querySelector("media-playback-rate-menu")}get mediaPlaybackRate(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,1)}set mediaPlaybackRate(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_PLAYBACK_RATE,e)}}sC.getSlotTemplateHTML=function(e){let t=e.mediaplaybackrate?rR(+e.mediaplaybackrate):1;return` 1736 <style> 1737 :host { 1738 min-width: 5ch; 1739 padding: var(--media-button-padding, var(--media-control-padding, 10px 5px)); 1740 } 1741 1742 :host([aria-expanded="true"]) slot { 1743 display: block; 1744 } 1745 1746 :host([aria-expanded="true"]) slot[name=tooltip] { 1747 display: none; 1748 } 1749 </style> 1750 <slot name="icon">${t}x</slot> 1751 `},sC.getTooltipContentHTML=function(){return(0,ij.t)("Playback rate")},i1.Mq.customElements.get("media-playback-rate-menu-button")||i1.Mq.customElements.define("media-playback-rate-menu-button",sC);var sR=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},sS=(e,t,i)=>(sR(e,t,"read from private field"),i?i.call(e):t.get(e)),sL=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},sD=(e,t,i,a)=>(sR(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),sx=(e,t,i)=>(sR(e,t,"access private method"),i);class sN extends nq{constructor(){super(...arguments),sL(this,dY),sL(this,dG),sL(this,dK,[]),sL(this,dF,{})}static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_RENDITION_LIST,iq.MediaUIAttributes.MEDIA_RENDITION_SELECTED,iq.MediaUIAttributes.MEDIA_RENDITION_UNAVAILABLE,iq.MediaUIAttributes.MEDIA_HEIGHT,iq.MediaUIAttributes.MEDIA_WIDTH]}static formatMenuItemText(e,t){return super.formatMenuItemText(e,t)}static formatRendition(e,{showBitrate:t=!1}={}){let i=`${Math.min(e.width,e.height)}p`;if(t&&e.bitrate){let t=e.bitrate/1e6,a=`${t.toFixed(t<1?1:0)} Mbps`;return`${i} (${a})`}return this.formatMenuItemText(i,e)}static compareRendition(e,t){var i,a;return t.height===e.height?(null!=(i=t.bitrate)?i:0)-(null!=(a=e.bitrate)?a:0):t.height-e.height}attributeChangedCallback(e,t,i){if(super.attributeChangedCallback(e,t,i),t!==i)switch(e){case iq.MediaUIAttributes.MEDIA_RENDITION_SELECTED:this.value=null!=i?i:"auto",sx(this,dY,dq).
1751call(this);break;case iq.MediaUIAttributes.MEDIA_RENDITION_LIST:sD(this,dK,(0,iG.MS)(i)),sx(this,dY,dq).call(this);break;case iq.MediaUIAttributes.MEDIA_HEIGHT:case iq.MediaUIAttributes.MEDIA_WIDTH:sx(this,dY,dq).call(this)}}connectedCallback(){super.connectedCallback(),this.addEventListener("change",sx(this,dG,dj))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("change",sx(this,dG,dj))}get anchorElement(){return"auto"!==this.anchor?super.anchorElement:(0,i0.Xq)(this).querySelector("media-rendition-menu-button")}get mediaRenditionList(){return sS(this,dK)}set mediaRenditionList(e){sD(this,dK,e),sx(this,dY,dq).call(this)}get mediaRenditionSelected(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_RENDITION_SELECTED)}set mediaRenditionSelected(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_RENDITION_SELECTED,e)}get mediaHeight(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_HEIGHT)}set mediaHeight(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_HEIGHT,e)}get mediaWidth(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_WIDTH)}set mediaWidth(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_WIDTH,e)}compareRendition(e,t){return this.constructor.compareRendition(e,t)}formatMenuItemText(e,t){return this.constructor.formatMenuItemText(e,t)}formatRendition(e,t){return this.constructor.formatRendition(e,t)}showRenditionBitrate(e){return this.mediaRenditionList.some(t=>t!==e&&t.height===e.height&&t.bitrate!==e.bitrate)}}dK=new WeakMap,dF=new WeakMap,dY=new WeakSet,dq=function(){let e;let t=!this.mediaRenditionSelected;if(sS(this,dF).mediaRenditionList===JSON.stringify(this.mediaRenditionList)&&sS(this,dF).mediaHeight===this.mediaHeight&&sS(this,dF).mediaWidth===this.mediaWidth&&sS(this,dF).isAuto===t)return;sS(this,dF).mediaRenditionList=JSON.stringify(this.mediaRenditionList),sS(this,dF).mediaHeight=this.mediaHeight,sS(this,dF).mediaWidth=this.mediaWidth,sS(this,dF).isAuto=t;let i=this.mediaRenditionList.sort(this.compareRendition.bind(this)),a=i.find(e=>e.id===this.mediaRenditionSelected);for(let e of i)e.selected=e===a;for(let e of(this.defaultSlot.textContent="",i)){let i=nK({type:"radio",text:this.formatRendition(e,{showBitrate:this.showRenditionBitrate(e)}),value:`${e.id}`,checked:e.selected&&!t});i.prepend(nF(this,"checked-indicator")),this.defaultSlot.append(i)}let r=a&&this.showRenditionBitrate(a);t&&(a?e=this.formatMenuItemText(`${(0,ij.t)("Auto")} \u2022 ${this.formatRendition(a,{showBitrate:r})}`,a):this.mediaHeight>0&&this.mediaWidth>0&&(e=this.formatMenuItemText(`${(0,ij.t)("Auto")} (${Math.min(this.mediaWidth,this.mediaHeight)}p)`))),e||(e=this.formatMenuItemText((0,ij.t)("Auto")));let n=nK({type:"radio",text:e,value:"auto",checked:t});n.dataset.description=e,n.prepend(nF(this,"checked-indicator")),this.defaultSlot.append(n)},dG=new WeakSet,dj=function(){if(null==this.value)return;let e=new i1.Mq.CustomEvent(iq.MediaUIEvents.MEDIA_RENDITION_REQUEST,{composed:!0,bubbles:!0,detail:this.value});this.dispatchEvent(e)},i1.Mq.customElements.get("media-rendition-menu")||i1.Mq.customElements.define("media-rendition-menu",sN);let sO=`<svg aria-hidden="true" viewBox="0 0 24 24"> 1752 <path d="M13.5 2.5h2v6h-2v-2h-11v-2h11v-2Zm4 2h4v2h-4v-2Zm-12 4h2v6h-2v-2h-3v-2h3v-2Zm4 2h12v2h-12v-2Zm1 4h2v6h-2v-2h-8v-2h8v-2Zm4 2h7v2h-7v-2Z" /> 1753</svg>`;class sP extends n5{static get observedAttributes(){return[...super.observedAttributes,iq.MediaUIAttributes.MEDIA_RENDITION_SELECTED,iq.MediaUIAttributes.MEDIA_RENDITION_UNAVAILABLE,iq.MediaUIAttributes.MEDIA_HEIGHT]}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-label",(0,ij.t)("quality"))}get invokeTargetElement(){return void 0!=this.invokeTarget?super.invokeTargetElement:(0,i0.Xq)(this).querySelector("media-rendition-menu")}get mediaRenditionSelected(){return(0,i0.ST)(this,iq.MediaUIAttributes.MEDIA_RENDITION_SELECTED)}set mediaRenditionSelected(e){(0,i0.Lb)(this,iq.MediaUIAttributes.MEDIA_RENDITION_SELECTED,e)}get mediaHeight(){return(0,i0.Uf)(this,iq.MediaUIAttributes.MEDIA_HEIGHT)}set mediaHeight(e){(0,i0.AI)(this,iq.MediaUIAttributes.MEDIA_HEIGHT,e)}}sP.getSlotTemplateHTML=function(){return` 1754 <style> 1755 :host([aria-expanded="true"]) slot[name=tooltip] { 1756 display: none; 1757 } 1758 </style> 1759 <slot name="icon">${sO}</slot> 1760 `},sP.getTooltipContentHTML=function(){return(0,ij.t)("Quality")},i1.Mq.customElements.get("media-rendition-menu-button")||i1.Mq.customElements.define("media-rendition-menu-button",sP);var sU=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},sW=(e,t,i)=>(sU(e,t,"read from private field"),i?i.call(e):t.get(e)),s$=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},sB=(e,t,i,a)=>(sU(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),sH=(e,t,i)=>(sU(e,t,"access private method"),i);class sV extends nq{constructor(){super(),s$(this,dz),s$(this,dQ),s$(this,d0),s$(this,d2),s$(this,d5),s$(this,dZ,!1),s$(this,d4,e=>{let t=e.target,i=(null==t?void 0:t.nodeName)==="VIDEO",a=sH(this,d2,d3).call(this,t);(i||a)&&(sW(this,dZ)?sH(this,dQ,dJ).call(this):sH(this,d5,d9).call(this,e))}),s$(this,d8,e=>{let t=e.target,i=this.contains(t),a=2===e.button,r=(null==t?void 0:t.nodeName)==="VIDEO",n=sH(this,d2,d3).call(this,t);!i&&(a&&(r||n)||sH(this,dQ,dJ).call(this))}),s$(this,d6,e=>{"Escape"===e.key&&sH(this,dQ,dJ).call(this)}),s$(this,d7,e=>{var t,i;let a=e.target;if(null==(t=a.matches)?void 0:t.call(a,'button[invoke="copy"]')){let e=null==(i=a.closest("media-context-menu-item"))?void 0:i.querySelector('input[slot="copy"]');e&&navigator.clipboard.writeText(e.value)}sH(this,dQ,dJ).call(this)}),this.setAttribute("noautohide",""),sH(this,dz,dX).call(this)}connectedCallback(){super.connectedCallback(),(0,i0.Xq)(this).addEventListener("contextmenu",sW(this,d4)),this.addEventListener("click",
1760sW(this,d7))}disconnectedCallback(){super.disconnectedCallback(),(0,i0.Xq)(this).removeEventListener("contextmenu",sW(this,d4)),this.removeEventListener("click",sW(this,d7)),document.removeEventListener("mousedown",sW(this,d8)),document.removeEventListener("keydown",sW(this,d6))}}dZ=new WeakMap,dz=new WeakSet,dX=function(){this.hidden=!sW(this,dZ)},dQ=new WeakSet,dJ=function(){sB(this,dZ,!1),sH(this,dz,dX).call(this)},d0=new WeakSet,d1=function(){document.querySelectorAll("media-context-menu").forEach(e=>{e!==this&&sH(e,dQ,dJ).call(e)})},d2=new WeakSet,d3=function(e){return!!e&&(!!e.hasAttribute("slot")&&"media"===e.getAttribute("slot")||!!(e.nodeName.includes("-")&&e.tagName.includes("-"))&&(e.hasAttribute("src")||e.hasAttribute("poster")||e.hasAttribute("preload")||e.hasAttribute("playsinline")))},d4=new WeakMap,d5=new WeakSet,d9=function(e){e.preventDefault(),sH(this,d0,d1).call(this),sB(this,dZ,!0),this.style.position="fixed",this.style.left=`${e.clientX}px`,this.style.top=`${e.clientY}px`,sH(this,dz,dX).call(this),document.addEventListener("mousedown",sW(this,d8),{once:!0}),document.addEventListener("keydown",sW(this,d6),{once:!0})},d8=new WeakMap,d6=new WeakMap,d7=new WeakMap,sV.getTemplateHTML=function(e){return` 1761 ${nq.getTemplateHTML(e)} 1762 <style> 1763 :host { 1764 --_menu-bg: rgb(20 20 30 / .8); 1765 background: var(--media-settings-menu-background, 1766 var(--media-menu-background, 1767 var(--media-control-background, 1768 var(--media-secondary-color, var(--_menu-bg))))); 1769 min-width: var(--media-settings-menu-min-width, 170px); 1770 border-radius: 2px; 1771 overflow: hidden; 1772 } 1773 </style> 1774 `},i1.Mq.customElements.get("media-context-menu")||i1.Mq.customElements.define("media-context-menu",sV);class sK extends n1{}sK.shadowRootOptions={mode:"open"},sK.getTemplateHTML=function(e){return` 1775 ${n1.getTemplateHTML.call(this,e)} 1776 <style> 1777 ::slotted(*) { 1778 color: var(--media-text-color, white); 1779 text-decoration: none; 1780 border: none; 1781 background: none; 1782 cursor: pointer; 1783 padding: 0; 1784 min-height: var(--media-control-height, 24px); 1785 } 1786 </style> 1787 `},i1.Mq.customElements.get("media-context-menu-item")||i1.Mq.customElements.define("media-context-menu-item",sK);var sF=e=>{throw TypeError(e)},sY=(e,t,i)=>t.has(e)||sF("Cannot "+i),sq=(e,t,i)=>(sY(e,t,"read from private field"),i?i.call(e):t.get(e)),sG=(e,t,i)=>t.has(e)?sF("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,i),sj=(e,t,i,a)=>(sY(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),sZ=(e,t,i)=>(sY(e,t,"access private method"),i),sz=class{addEventListener(){}removeEventListener(){}dispatchEvent(e){return!0}};if("undefined"==typeof DocumentFragment){class e extends sz{}globalThis.DocumentFragment=e}var sX,sQ,sJ,s0,s1,s2,s3,s4,s5,s9,s8,s6,s7,oe,ot,oi,oa,or,on,os,oo,ol,od,ou,oc,oh,om,op,ob,ov,oE,og,of,oA,oy,oT,ok,oM,oI,o_,ow,oC,oR,oS,oL,oD,ox,oN,oO,oP,oU,oW,o$,oB,oH,oV,oK,oF,oY,oq,oG,oj,oZ,oz,oX,oQ,oJ,o0,o1,o2,o3,o4,o5,o9,o8,o6,o7,le,lt,li,la,lr,ln,ls,lo,ll,ld,lu,lc,lh,lm,lp,lb,lv,lE,lg,lf,lA,ly,lT,lk,lM,lI,l_,lw,lC,lR,lS,lL,lD,lx,lN,lO,lP,lU,lW,l$,lB,lH,lV,lK,lF,lY,lq,lG,lj,lZ,lz,lX,lQ,lJ,l0,l1,l2,l3,l4,l5,l9,l8,l6,l7,de,dt,di,da,dr,dn,ds,dl,dd,du,dc,dh,dm,dp,db,dv,dE,dg,df,dA,dy,dT,dk,dM,dI,d_,dw,dC,dR,dS,dL,dD,dx,dN,dO,dP,dU,dW,d$,dB,dH,dV,dK,dF,dY,dq,dG,dj,dZ,dz,dX,dQ,dJ,d0,d1,d2,d3,d4,d5,d9,d8,d6,d7,ue,ut=class extends sz{},ui=class{constructor(e,t={}){sG(this,ue),sj(this,ue,null==t?void 0:t.detail)}get detail(){return sq(this,ue)}initCustomEvent(){}};ue=new WeakMap;var ua={document:{createElement:function(e,t){return new ut}},DocumentFragment,customElements:{get(e){},define(e,t,i){},getName:e=>null,upgrade(e){},whenDefined:e=>Promise.resolve(ut)},CustomEvent:ui,EventTarget:sz,HTMLElement:ut,HTMLVideoElement:class extends sz{}},ur="undefined"==typeof window||void 0===globalThis.customElements,un=ur?ua:globalThis,us=ur?ua.document:globalThis.document;function uo(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function ul(e){return e.replace(/[-_]([a-z])/g,(e,t)=>t.toUpperCase())}function ud(e){if(null==e)return;let t=+e;return Number.isNaN(t)?void 0:t}function uu(e){let t=(function(e){let t={};for(let i in e)null!=e[i]&&(t[i]=e[i]);return new URLSearchParams(t)})(e).toString();return t?"?"+t:""}var uc,uh,um,up=(e,t)=>!!e&&!!t&&(!!e.contains(t)||up(e,t.getRootNode().host)),ub="mux.com",uv=(()=>{try{return"3.13.0"}catch{}return"UNKNOWN"})(),uE=(e,{token:t,customDomain:i=ub,thumbnailTime:a,programTime:r}={})=>{var n;let s=null==t?a:void 0,{aud:o}=null!=(n=x(t))?n:{};if(!(t&&"t"!==o))return`https://image.${i}/${e}/thumbnail.webp${uu({token:t,time:s,program_time:r})}`},ug=(e,{token:t,customDomain:i=ub,programStartTime:a,programEndTime:r}={})=>{var n;let{aud:s}=null!=(n=x(t))?n:{};if(!(t&&"s"!==s))return`https://image.${i}/${e}/storyboard.vtt${uu({token:t,format:"webp",program_start_time:a,program_end_time:r})}`},uf=e=>{if(e){if([b.LIVE,b.ON_DEMAND].includes(e))return e;if(null!=e&&e.includes("live"))return b.LIVE}}
1787,uA={crossorigin:"crossOrigin",playsinline:"playsInline"},uy=class{constructor(e,t){sG(this,uc),sG(this,uh),sG(this,um,[]),sj(this,uc,e),sj(this,uh,t)}[Symbol.iterator](){return sq(this,um).values()}get length(){return sq(this,um).length}get value(){var e;return null!=(e=sq(this,um).join(" "))?e:""}set value(e){var t;e!==this.value&&(sj(this,um,[]),this.add(...null!=(t=null==e?void 0:e.split(" "))?t:[]))}toString(){return this.value}item(e){return sq(this,um)[e]}values(){return sq(this,um).values()}keys(){return sq(this,um).keys()}forEach(e){sq(this,um).forEach(e)}add(...e){var t,i;e.forEach(e=>{this.contains(e)||sq(this,um).push(e)}),(""!==this.value||null!=(t=sq(this,uc))&&t.hasAttribute(`${sq(this,uh)}`))&&null!=(i=sq(this,uc))&&i.setAttribute(`${sq(this,uh)}`,`${this.value}`)}remove(...e){var t;e.forEach(e=>{sq(this,um).splice(sq(this,um).indexOf(e),1)}),null==(t=sq(this,uc))||t.setAttribute(`${sq(this,uh)}`,`${this.value}`)}contains(e){return sq(this,um).includes(e)}toggle(e,t){return void 0!==t?t?(this.add(e),!0):(this.remove(e),!1):this.contains(e)?(this.remove(e),!1):(this.add(e),!0)}replace(e,t){this.remove(e),this.add(t)}};uc=new WeakMap,uh=new WeakMap,um=new WeakMap;var uT=`[mux-player ${uv}]`;function uk(...e){console.warn(uT,...e)}function uM(...e){console.error(uT,...e)}function uI(e){var t;let i=null!=(t=e.message)?t:"";e.context&&(i+=` ${e.context}`),e.file&&(i+=` ${W("Read more: ")} 1788https://github.com/muxinc/elements/blob/main/errors/${e.file}`),uk(i)}var u_={AUTOPLAY:"autoplay",CROSSORIGIN:"crossorigin",LOOP:"loop",MUTED:"muted",PLAYSINLINE:"playsinline",PRELOAD:"preload"},uw={VOLUME:"volume",PLAYBACKRATE:"playbackrate",MUTED:"muted"},uC=Object.freeze({length:0,start(e){let t=e>>>0;if(t>=this.length)throw new DOMException(`Failed to execute 'start' on 'TimeRanges': The index provided (${t}) is greater than or equal to the maximum bound (${this.length}).`);return 0},end(e){let t=e>>>0;if(t>=this.length)throw new DOMException(`Failed to execute 'end' on 'TimeRanges': The index provided (${t}) is greater than or equal to the maximum bound (${this.length}).`);return 0}}),uR=[...Object.values(u_).filter(e=>u_.PLAYSINLINE!==e),...Object.values(uw)];function uS(e,t){return e.media?e.media.getAttribute(t):e.getAttribute(t)}var uL=class extends un.HTMLElement{static get observedAttributes(){return uR}constructor(){super()}attributeChangedCallback(e,t,i){var a,r;switch(e){case uw.MUTED:this.media&&(this.media.muted=null!=i,this.media.defaultMuted=null!=i);return;case uw.VOLUME:{let e=null!=(a=ud(i))?a:1;this.media&&(this.media.volume=e);return}case uw.PLAYBACKRATE:{let e=null!=(r=ud(i))?r:1;this.media&&(this.media.playbackRate=e,this.media.defaultPlaybackRate=e);return}}}play(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.play())?t:Promise.reject()}pause(){var e;null==(e=this.media)||e.pause()}load(){var e;null==(e=this.media)||e.load()}get media(){var e;return null==(e=this.shadowRoot)?void 0:e.querySelector("mux-video")}get audioTracks(){return this.media.audioTracks}get videoTracks(){return this.media.videoTracks}get audioRenditions(){return this.media.audioRenditions}get videoRenditions(){return this.media.videoRenditions}get paused(){var e,t;return null==(t=null==(e=this.media)?void 0:e.paused)||t}get duration(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.duration)?t:NaN}get ended(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.ended)&&t}get buffered(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.buffered)?t:uC}get seekable(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.seekable)?t:uC}get readyState(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.readyState)?t:0}get videoWidth(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.videoWidth)?t:0}get videoHeight(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.videoHeight)?t:0}get currentSrc(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.currentSrc)?t:""}get currentTime(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.currentTime)?t:0}set currentTime(e){this.media&&(this.media.currentTime=Number(e))}get volume(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.volume)?t:1}set volume(e){this.media&&(this.media.volume=Number(e))}get playbackRate(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.playbackRate)?t:1}set playbackRate(e){this.media&&(this.media.playbackRate=Number(e))}get defaultPlaybackRate(){var e;return null!=(e=ud(this.getAttribute(uw.PLAYBACKRATE)))?e:1}set defaultPlaybackRate(e){null!=e?this.setAttribute(uw.PLAYBACKRATE,`${e}`):this.removeAttribute(uw.PLAYBACKRATE)}get crossOrigin(){return uS(this,u_.CROSSORIGIN)}set crossOrigin(e){this.setAttribute(u_.CROSSORIGIN,`${e}`)}get autoplay(){return null!=uS(this,u_.AUTOPLAY)}set autoplay(e){e?this.setAttribute(u_.AUTOPLAY,"string"==typeof e?e:""):this.removeAttribute(u_.AUTOPLAY)}get loop(){return null!=uS(this,u_.LOOP)}set loop(e){e?this.setAttribute(u_.LOOP,""):this.removeAttribute(u_.LOOP)}get muted(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.muted)&&t}set muted(e){this.media&&(this.media.muted=!!e)}get defaultMuted(){return null!=uS(this,u_.MUTED)}set defaultMuted(e){e?this.setAttribute(u_.MUTED,""):this.removeAttribute(u_.MUTED)}
1788get playsInline(){return null!=uS(this,u_.PLAYSINLINE)}set playsInline(e){uM("playsInline is set to true by default and is not currently supported as a setter.")}get preload(){return this.media?this.media.preload:this.getAttribute("preload")}set preload(e){["","none","metadata","auto"].includes(e)?this.setAttribute(u_.PRELOAD,e):this.removeAttribute(u_.PRELOAD)}},uD=`:host { 1789 --media-control-display: var(--controls); 1790 --media-loading-indicator-display: var(--loading-indicator); 1791 --media-dialog-display: var(--dialog); 1792 --media-play-button-display: var(--play-button); 1793 --media-live-button-display: var(--live-button); 1794 --media-seek-backward-button-display: var(--seek-backward-button); 1795 --media-seek-forward-button-display: var(--seek-forward-button); 1796 --media-mute-button-display: var(--mute-button); 1797 --media-captions-button-display: var(--captions-button); 1798 --media-captions-menu-button-display: var(--captions-menu-button, var(--media-captions-button-display)); 1799 --media-rendition-menu-button-display: var(--rendition-menu-button); 1800 --media-audio-track-menu-button-display: var(--audio-track-menu-button); 1801 --media-airplay-button-display: var(--airplay-button); 1802 --media-pip-button-display: var(--pip-button); 1803 --media-fullscreen-button-display: var(--fullscreen-button); 1804 --media-cast-button-display: var(--cast-button, var(--_cast-button-drm-display)); 1805 --media-playback-rate-button-display: var(--playback-rate-button); 1806 --media-playback-rate-menu-button-display: var(--playback-rate-menu-button); 1807 --media-volume-range-display: var(--volume-range); 1808 --media-time-range-display: var(--time-range); 1809 --media-time-display-display: var(--time-display); 1810 --media-duration-display-display: var(--duration-display); 1811 --media-title-display-display: var(--title-display); 1812 1813 display: inline-block; 1814 line-height: 0; 1815 width: 100%; 1816} 1817 1818a { 1819 color: #fff; 1820 font-size: 0.9em; 1821 text-decoration: underline; 1822} 1823 1824media-theme { 1825 display: inline-block; 1826 line-height: 0; 1827 width: 100%; 1828 height: 100%; 1829 direction: ltr; 1830} 1831 1832media-poster-image { 1833 display: inline-block; 1834 line-height: 0; 1835 width: 100%; 1836 height: 100%; 1837} 1838 1839media-poster-image:not([src]):not([placeholdersrc]) { 1840 display: none; 1841} 1842 1843::part(top), 1844[part~='top'] { 1845 --media-control-display: var(--controls, var(--top-controls)); 1846 --media-play-button-display: var(--play-button, var(--top-play-button)); 1847 --media-live-button-display: var(--live-button, var(--top-live-button)); 1848 --media-seek-backward-button-display: var(--seek-backward-button, var(--top-seek-backward-button)); 1849 --media-seek-forward-button-display: var(--seek-forward-button, var(--top-seek-forward-button)); 1850 --media-mute-button-display: var(--mute-button, var(--top-mute-button)); 1851 --media-captions-button-display: var(--captions-button, var(--top-captions-button)); 1852 --media-captions-menu-button-display: var( 1853 --captions-menu-button, 1854 var(--media-captions-button-display, var(--top-captions-menu-button)) 1855 ); 1856 --media-rendition-menu-button-display: var(--rendition-menu-button, var(--top-rendition-menu-button)); 1857 --media-audio-track-menu-button-display: var(--audio-track-menu-button, var(--top-audio-track-menu-button)); 1858 --media-airplay-button-display: var(--airplay-button, var(--top-airplay-button)); 1859 --media-pip-button-display: var(--pip-button, var(--top-pip-button)); 1860 --media-fullscreen-button-display: var(--fullscreen-button, var(--top-fullscreen-button)); 1861 --media-cast-button-display: var(--cast-button, var(--top-cast-button, var(--_cast-button-drm-display))); 1862 --media-playback-rate-button-display: var(--playback-rate-button, var(--top-playback-rate-button)); 1863 --media-playback-rate-menu-button-display: var( 1864 --captions-menu-button, 1865 var(--media-playback-rate-button-display, var(--top-playback-rate-menu-button)) 1866 ); 1867 --media-volume-range-display: var(--volume-range, var(--top-volume-range)); 1868 --media-time-range-display: var(--time-range, var(--top-time-range)); 1869 --media-time-display-display: var(--time-display, var(--top-time-display)); 1870 --media-duration-display-display: var(--duration-display, var(--top-duration-display)); 1871 --media-title-display-display: var(--title-display, var(--top-title-display)); 1872} 1873 1874::part(center), 1875[part~='center'] {
1876 --media-control-display: var(--controls, var(--center-controls)); 1877 --media-play-button-display: var(--play-button, var(--center-play-button)); 1878 --media-live-button-display: var(--live-button, var(--center-live-button)); 1879 --media-seek-backward-button-display: var(--seek-backward-button, var(--center-seek-backward-button)); 1880 --media-seek-forward-button-display: var(--seek-forward-button, var(--center-seek-forward-button)); 1881 --media-mute-button-display: var(--mute-button, var(--center-mute-button)); 1882 --media-captions-button-display: var(--captions-button, var(--center-captions-button)); 1883 --media-captions-menu-button-display: var( 1884 --captions-menu-button, 1885 var(--media-captions-button-display, var(--center-captions-menu-button)) 1886 ); 1887 --media-rendition-menu-button-display: var(--rendition-menu-button, var(--center-rendition-menu-button)); 1888 --media-audio-track-menu-button-display: var(--audio-track-menu-button, var(--center-audio-track-menu-button)); 1889 --media-airplay-button-display: var(--airplay-button, var(--center-airplay-button)); 1890 --media-pip-button-display: var(--pip-button, var(--center-pip-button)); 1891 --media-fullscreen-button-display: var(--fullscreen-button, var(--center-fullscreen-button)); 1892 --media-cast-button-display: var(--cast-button, var(--center-cast-button, var(--_cast-button-drm-display))); 1893 --media-playback-rate-button-display: var(--playback-rate-button, var(--center-playback-rate-button)); 1894 --media-playback-rate-menu-button-display: var( 1895 --playback-rate-menu-button, 1896 var(--media-playback-rate-button-display, var(--center-playback-rate-menu-button)) 1897 ); 1898 --media-volume-range-display: var(--volume-range, var(--center-volume-range)); 1899 --media-time-range-display: var(--time-range, var(--center-time-range)); 1900 --media-time-display-display: var(--time-display, var(--center-time-display)); 1901 --media-duration-display-display: var(--duration-display, var(--center-duration-display)); 1902} 1903 1904::part(bottom), 1905[part~='bottom'] { 1906 --media-control-display: var(--controls, var(--bottom-controls)); 1907 --media-play-button-display: var(--play-button, var(--bottom-play-button)); 1908 --media-live-button-display: var(--live-button, var(--bottom-live-button)); 1909 --media-seek-backward-button-display: var(--seek-backward-button, var(--bottom-seek-backward-button)); 1910 --media-seek-forward-button-display: var(--seek-forward-button, var(--bottom-seek-forward-button)); 1911 --media-mute-button-display: var(--mute-button, var(--bottom-mute-button)); 1912 --media-captions-button-display: var(--captions-button, var(--bottom-captions-button)); 1913 --media-captions-menu-button-display: var( 1914 --captions-menu-button, 1915 var(--media-captions-button-display, var(--bottom-captions-menu-button)) 1916 ); 1917 --media-rendition-menu-button-display: var(--rendition-menu-button, var(--bottom-rendition-menu-button)); 1918 --media-audio-track-menu-button-display: var(--audio-track-menu-button, var(--bottom-audio-track-menu-button)); 1919 --media-airplay-button-display: var(--airplay-button, var(--bottom-airplay-button)); 1920 --media-pip-button-display: var(--pip-button, var(--bottom-pip-button)); 1921 --media-fullscreen-button-display: var(--fullscreen-button, var(--bottom-fullscreen-button)); 1922 --media-cast-button-display: var(--cast-button, var(--bottom-cast-button, var(--_cast-button-drm-display))); 1923 --media-playback-rate-button-display: var(--playback-rate-button, var(--bottom-playback-rate-button)); 1924 --media-playback-rate-menu-button-display: var( 1925 --playback-rate-menu-button, 1926 var(--media-playback-rate-button-display, var(--bottom-playback-rate-menu-button)) 1927 ); 1928 --media-volume-range-display: var(--volume-range, var(--bottom-volume-range)); 1929 --media-time-range-display: var(--time-range, var(--bottom-time-range)); 1930 --media-time-display-display: var(--time-display, var(--bottom-time-display)); 1931 --media-duration-display-display: var(--duration-display, var(--bottom-duration-display)); 1932 --media-title-display-display: var(--title-display, var(--bottom-title-display)); 1933} 1934 1935:host([no-tooltips]) { 1936 --media-tooltip-display: none; 1937} 1938`,ux=new WeakMap,uN=class e{constructor(e,t){this.element=e,this.type=t,this.element.addEventListener(this.type,this);let i=ux.get(this.element);i&&i.set(this.type,this)}set(e){if("function"==typeof e)this.handleEvent=e.bind(this.element);else if("object"==typeof e&&"function"==typeof e.handleEvent)this.handleEvent=e.handleEvent.bind(e);else{this.element.removeEventListener(this.type,this);let e=ux.get(this.element);
1938e&&e.delete(this.type)}}static for(t){ux.has(t.element)||ux.set(t.element,new Map);let i=t.attributeName.slice(2),a=ux.get(t.element);return a&&a.has(i)?a.get(i):new e(t.element,i)}},uO=new Map,uP=new WeakMap,uU=new WeakMap,uW=class{constructor(e,t,i){this.strings=e,this.values=t,this.processor=i,this.stringsKey=this.strings.join("\x01")}get template(){if(uO.has(this.stringsKey))return uO.get(this.stringsKey);{let e=us.createElement("template"),t=this.strings.length-1;return e.innerHTML=this.strings.reduce((e,i,a)=>e+i+(a<t?`{{ ${a} }}`:""),""),uO.set(this.stringsKey,e),e}}renderInto(e){var t;let i=this.template;if(uP.get(e)!==i){uP.set(e,i);let t=new nN.R(i,this.values,this.processor);uU.set(e,t),e instanceof nN.X5?e.replace(...t.children):e.appendChild(t);return}let a=uU.get(e);null==(t=null==a?void 0:a.update)||t.call(a,this.values)}},u$={processCallback(e,t,i){var a,r,n;if(i)for(let[e,s]of t){e in i&&(function(e,t){if(e instanceof nN.cf&&t instanceof Element){let i=e.element;return i[e.attributeName]!==t&&(e.element.removeAttributeNS(e.attributeNamespace,e.attributeName),i[e.attributeName]=t),!0}return!1}(r=s,n=null!=(a=i[e])?a:"")||function(e,t){if("boolean"==typeof t&&e instanceof nN.cf){let i=e.attributeNamespace;return t!==e.element.hasAttributeNS(i,e.attributeName)&&(e.booleanValue=t),!0}return!1}(r,n)||r instanceof nN.cf&&r.attributeName.startsWith("on")&&(uN.for(r).set(n),r.element.removeAttributeNS(r.attributeNamespace,r.attributeName),1)||!1===n&&r instanceof nN.X5&&(r.replace(""),1)||n instanceof uW&&r instanceof nN.X5&&(n.renderInto(r),1)||n instanceof DocumentFragment&&r instanceof nN.X5&&(n.childNodes.length&&r.replace(...n.childNodes),1)||function(e,t){if(e instanceof nN.cf){let i=e.attributeNamespace,a=e.element.getAttributeNS(i,e.attributeName);return String(t)!==a&&(e.value=String(t))}e.value=String(t)}(r,n))}}};function uB(e,...t){return new uW(e,t,u$)}var uH=e=>{let{tokens:t}=e;return t.drm?":host(:not([cast-receiver])) { --_cast-button-drm-display: none; }":""},uV=e=>uB` 1939 <style> 1940 ${uH(e)} 1941 ${uD} 1942 </style> 1943 ${uY(e)} 1944`,uK=e=>{let t=e.hotKeys?`${e.hotKeys}`:"";return"live"===uf(e.streamType)&&(t+=" noarrowleft noarrowright"),t},uF=Object.values({TOP:"top",CENTER:"center",BOTTOM:"bottom",LAYER:"layer",MEDIA_LAYER:"media-layer",POSTER_LAYER:"poster-layer",VERTICAL_LAYER:"vertical-layer",CENTERED_LAYER:"centered-layer",GESTURE_LAYER:"gesture-layer",CONTROLLER_LAYER:"controller",BUTTON:"button",RANGE:"range",THUMB:"thumb",DISPLAY:"display",CONTROL_BAR:"control-bar",MENU_BUTTON:"menu-button",MENU:"menu",MENU_ITEM:"menu-item",OPTION:"option",POSTER:"poster",LIVE:"live",PLAY:"play",PRE_PLAY:"pre-play",SEEK_BACKWARD:"seek-backward",SEEK_FORWARD:"seek-forward",MUTE:"mute",CAPTIONS:"captions",AIRPLAY:"airplay",PIP:"pip",FULLSCREEN:"fullscreen",CAST:"cast",PLAYBACK_RATE:"playback-rate",VOLUME:"volume",TIME:"time",TITLE:"title",AUDIO_TRACK:"audio-track",RENDITION:"rendition"}).join(", "),uY=e=>{var t,i,a,r,n,s,o,l,d,u,c,h,m,p,v,E,g,f,A,y,T,k,M,I,_,w,C,R,S,L,D,x,N,O,P,U,W,$,B,H,V,K;let F;return uB` 1945 <media-theme 1946 template="${e.themeTemplate||!1}" 1947 defaultstreamtype="${null!=(t=e.defaultStreamType)&&t}" 1948 hotkeys="${uK(e)||!1}" 1949 nohotkeys="${e.noHotKeys||!e.hasSrc||!1}" 1950 noautoseektolive="${!!(null!=(i=e.streamType)&&i.includes(b.LIVE))&&0!==e.targetLiveWindow}" 1951 novolumepref="${e.novolumepref||!1}" 1952 nomutedpref="${e.nomutedpref||!1}" 1953 disabled="${!e.hasSrc||e.isDialogOpen}" 1954 audio="${null!=(a=e.audio)&&a}" 1955 style="${null!=(K={"--media-primary-color":e.primaryColor,"--media-secondary-color":e.secondaryColor,"--media-accent-color":e.accentColor}
1955,F="",Object.entries(K).forEach(([e,t])=>{null!=t&&(F+=`${uo(e)}: ${t}; `)}),r=F?F.trim():void 0)&&r}" 1956 defaultsubtitles="${!e.defaultHiddenCaptions}" 1957 forwardseekoffset="${null!=(n=e.forwardSeekOffset)&&n}" 1958 backwardseekoffset="${null!=(s=e.backwardSeekOffset)&&s}" 1959 playbackrates="${null!=(o=e.playbackRates)&&o}" 1960 defaultshowremainingtime="${null!=(l=e.defaultShowRemainingTime)&&l}" 1961 defaultduration="${null!=(d=e.defaultDuration)&&d}" 1962 hideduration="${null!=(u=e.hideDuration)&&u}" 1963 title="${null!=(c=e.title)&&c}" 1964 videotitle="${null!=(h=e.videoTitle)&&h}" 1965 proudlydisplaymuxbadge="${null!=(m=e.proudlyDisplayMuxBadge)&&m}" 1966 exportparts="${uF}" 1967 onclose="${e.onCloseErrorDialog}" 1968 onfocusin="${e.onFocusInErrorDialog}" 1969 > 1970 <mux-video 1971 slot="media" 1972 inert="${null!=(p=e.noHotKeys)&&p}" 1973 target-live-window="${null!=(v=e.targetLiveWindow)&&v}" 1974 stream-type="${null!=(E=uf(e.streamType))&&E}" 1975 crossorigin="${null!=(g=e.crossOrigin)?g:""}" 1976 playsinline 1977 autoplay="${null!=(f=e.autoplay)&&f}" 1978 muted="${null!=(A=e.muted)&&A}" 1979 loop="${null!=(y=e.loop)&&y}" 1980 preload="${null!=(T=e.preload)&&T}" 1981 debug="${null!=(k=e.debug)&&k}" 1982 prefer-cmcd="${null!=(M=e.preferCmcd)&&M}" 1983 disable-tracking="${null!=(I=e.disableTracking)&&I}" 1984 disable-cookies="${null!=(_=e.disableCookies)&&_}" 1985 prefer-playback="${null!=(w=e.preferPlayback)&&w}" 1986 start-time="${null!=e.startTime&&e.startTime}" 1987 initial-bandwidth-estimate-kbps="${null!=e.initialBandwidthEstimateKbps&&e.initialBandwidthEstimateKbps}" 1988 initial-estimate-segments="${null!=e.initialEstimateSegments&&e.initialEstimateSegments}" 1989 min-preload-segments="${null!=e.minPreloadSegments&&e.minPreloadSegments}" 1990 beacon-collection-domain="${null!=(C=e.beaconCollectionDomain)&&C}" 1991 player-init-time="${null!=(R=e.playerInitTime)&&R}" 1992 player-software-name="${null!=(S=e.playerSoftwareName)&&S}" 1993 player-software-version="${null!=(L=e.playerSoftwareVersion)&&L}" 1994 env-key="${null!=(D=e.envKey)&&D}" 1995 custom-domain="${null!=(x=e.customDomain)&&x}" 1996 src="${e.src?e.src:!!e.playbackId&&eG(e)}" 1997 cast-src="${e.src?e.src:!!e.playbackId&&eG(e)}" 1998 cast-receiver="${null!=(N=e.castReceiver)&&N}" 1999 drm-token="${null!=(P=null==(O=e.tokens)?void 0:O.drm)&&P}" 2000 playback-token="${null!=(W=null==(U=e.tokens)?void 0:U.playback)&&W}" 2001 exportparts="video" 2002 disable-pseudo-ended="${null!=($=e.disablePseudoEnded)&&$}" 2003 max-auto-resolution="${null!=(B=e.maxAutoResolution)&&B}" 2004 cap-rendition-to-player-size="${null!=(H=e.capRenditionToPlayerSize)&&H}" 2005 > 2006 ${e.storyboard?uB`<track label="thumbnails" default kind="metadata" src="${e.storyboard}" />`:uB``} 2007 <slot></slot> 2008 </mux-video> 2009 <slot name="poster" slot="poster"> 2010 <media-poster-image 2011 part="poster" 2012 exportparts="poster, img" 2013 src="${!!e.poster&&e.poster}" 2014 placeholdersrc="${null!=(V=e.placeholder)&&V}" 2015 ></media-poster-image> 2016 </slot> 2017 </media-theme> 2018`},uq=e=>e.charAt(0).toUpperCase()+e.slice(1),uG=(e,t=!1)=>{var i,a;if(e.muxCode){let r=uq(null!=(i=e.errorCategory)?i:"video"),n=u(null!=(a=e.errorCategory)?a:l.VIDEO);if(e.muxCode===d.NETWORK_OFFLINE)return W("Your device appears to be offline",t);if(e.muxCode===d.NETWORK_TOKEN_EXPIRED)return W("{category} URL has expired",t).format({category:r});if([d.NETWORK_TOKEN_SUB_MISMATCH,d.NETWORK_TOKEN_AUD_MISMATCH,d.NETWORK_TOKEN_AUD_MISSING,d.NETWORK_TOKEN_MALFORMED].includes(e.muxCode))return W("{category} URL is formatted incorrectly",t).format({category:r});if(e.muxCode===d.NETWORK_TOKEN_MISSING)return W("Invalid {categoryName} URL",t).format({categoryName:n});if(e.muxCode===d.NETWORK_NOT_FOUND)return W("{category} does not exist",t).format({category:r});if(e.muxCode===d.NETWORK_NOT_READY){let i="live"===e.streamType?"Live stream":"Video";return W("{mediaType} is not currently available",t).format({mediaType:i})}}if(e.code){if(e.code===c.MEDIA_ERR_NETWORK)return W("Network Error",t);if(e.code===c.MEDIA_ERR_DECODE)return W("Media Error",t);if(e.code===c.MEDIA_ERR_SRC_NOT_SUPPORTED)return W("Source Not Supported",t)}return W("Error",t)},uj=(e,t=!1)=>{var i,a;if(e.muxCode){let r=uq(null!=(i=e.errorCategory)?i:"video"),n=u(null!=(a=e.errorCategory)?a:l.VIDEO);return e.muxCode===d.NETWORK_OFFLINE?W("Check your internet connection and try reloading this video.",t):e.muxCode===d.NETWORK_TOKEN_EXPIRED?W("The videoâs secured {tokenNamePrefix}-token has expired.",t).format({tokenNamePrefix:n}):e.muxCode===d.NETWORK_TOKEN_SUB_MISMATCH?W("The videoâs playback ID does not match the one encoded in the {tokenNamePrefix}-token.",t).format({tokenNamePrefix:n}):e.muxCode===d.NETWORK_TOKEN_MALFORMED?W("{category} URL is formatted incorrectly",t).format({category:r}):[d.NETWORK_TOKEN_AUD_MISMATCH,d.NETWORK_TOKEN_AUD_MISSING].includes(e.muxCode)?W("The {tokenNamePrefix}-token is formatted with incorrect information.",t).format({tokenNamePrefix:n}):[d.NETWORK_TOKEN_MISSING,d.NETWORK_INVALID_URL].includes(e.muxCode)?W("The video URL or {tokenNamePrefix}-token are formatted with incorrect or incomplete information.",t).format({tokenNamePrefix:n}):e.muxCode===d.NETWORK_NOT_FOUND?"":e.message}return e.code&&(e.code===c.MEDIA_ERR_NETWORK||e.code===c.MEDIA_ERR_DECODE||(e.code,c.MEDIA_ERR_SRC_NOT_SUPPORTED)),e.message},uZ=(e,t=!1)=>({title:uG(e,t).toString(),message:uj(e,t).toString()}),uz=e=>{if(e.muxCode){if(e.muxCode===d.NETWORK_TOKEN_EXPIRED)return"403-expired-token.md";if(e.muxCode===d.NETWORK_TOKEN_MALFORMED)return"403-malformatted-token.md";if([d.NETWORK_TOKEN_AUD_MISMATCH,d.NETWORK_TOKEN_AUD_MISSING].includes(e.muxCode))return"403-incorrect-aud-value.md";if(e.muxCode===d.NETWORK_TOKEN_SUB_MISMATCH)return"403-playback-id-mismatch.md";if(e.muxCode===d.NETWORK_TOKEN_MISSING)return"missing-signed-tokens.md";if(e.muxCode===d.NETWORK_NOT_FOUND)return"404-not-found.md";if(e.muxCode===d.NETWORK_NOT_READY)return"412-not-playable.md"}if(e.code){if(e.code===c.MEDIA_ERR_NETWORK)return"";if(e.code===c.MEDIA_ERR_DECODE)return"media-decode-error.md";if(e.code===c.MEDIA_ERR_SRC_NOT_SUPPORTED)return"media-src-not-supported.md"}return""},uX=(e,t)=>{let i=uz(e);return{message:e.message,context:e.context,file:i}},uQ
vendor: 8,830 bytes, lines 2018-2318
2018=`<template id="media-theme-gerwig"> 2019 <style> 2020 @keyframes pre-play-hide { 2021 0% { 2022 transform: scale(1); 2023 opacity: 1; 2024 } 2025 2026 30% { 2027 transform: scale(0.7); 2028 } 2029 2030 100% { 2031 transform: scale(1.5); 2032 opacity: 0; 2033 } 2034 } 2035 2036 :host { 2037 --_primary-color: var(--media-primary-color, #fff); 2038 --_secondary-color: var(--media-secondary-color, transparent); 2039 --_accent-color: var(--media-accent-color, #fa50b5); 2040 --_text-color: var(--media-text-color, #000); 2041 2042 --media-icon-color: var(--_primary-color); 2043 --media-control-background: var(--_secondary-color); 2044 --media-control-hover-background: var(--_accent-color); 2045 --media-time-buffered-color: rgba(255, 255, 255, 0.4); 2046 --media-preview-time-text-shadow: none; 2047 --media-control-height: 14px; 2048 --media-control-padding: 6px; 2049 --media-tooltip-container-margin: 6px; 2050 --media-tooltip-distance: 18px; 2051 2052 color: var(--_primary-color); 2053 display: inline-block; 2054 width: 100%; 2055 height: 100%; 2056 } 2057 2058 :host([audio]) { 2059 --_secondary-color: var(--media-secondary-color, black); 2060 --media-preview-time-text-shadow: none; 2061 } 2062 2063 :host([audio]) ::slotted([slot='media']) { 2064 height: 0px; 2065 } 2066 2067 :host([audio]) media-loading-indicator { 2068 display: none; 2069 } 2070 2071 :host([audio]) media-controller { 2072 background: transparent; 2073 } 2074 2075 :host([audio]) media-controller::part(vertical-layer) { 2076 background: transparent; 2077 } 2078 2079 :host([audio]) media-control-bar { 2080 width: 100%; 2081 background-color: var(--media-control-background); 2082 } 2083 2084 /* 2085 * 0.433s is the transition duration for VTT Regions. 2086 * Borrowed here, so the captions don't move too fast. 2087 */ 2088 media-controller { 2089 --media-webkit-text-track-transform: translateY(0) scale(0.98); 2090 --media-webkit-text-track-transition: transform 0.433s ease-out 0.3s; 2091 } 2092 media-controller:is([mediapaused], :not([userinactive])) { 2093 --media-webkit-text-track-transform: translateY(-50px) scale(0.98); 2094 --media-webkit-text-track-transition: transform 0.15s ease; 2095 } 2096 2097 /* 2098 * CSS specific to iOS devices. 2099 * See: https://stackoverflow.com/questions/30102792/css-media-query-to-target-only-ios-devices/60220757#60220757 2100 */ 2101 @supports (-webkit-touch-callout: none) { 2102 /* Disable subtitle adjusting for iOS Safari */ 2103 media-controller[mediaisfullscreen] { 2104 --media-webkit-text-track-transform: unset; 2105 --media-webkit-text-track-transition: unset; 2106 } 2107 } 2108 2109 media-time-range { 2110 --media-box-padding-left: 6px; 2111 --media-box-padding-right: 6px; 2112 --media-range-bar-color: var(--_accent-color); 2113 --media-time-range-buffered-color: var(--_primary-color); 2114 --media-range-track-color: transparent; 2115 --media-range-track-background: rgba(255, 255, 255, 0.4); 2116 --media-range-thumb-background: radial-gradient( 2117 circle, 2118 #000 0%, 2119 #000 25%, 2120 var(--_accent-color) 25%, 2121 var(--_accent-color) 2122 ); 2123 --media-range-thumb-width: 12px; 2124 --media-range-thumb-height: 12px; 2125 --media-range-thumb-transform: scale(0); 2126 --media-range-thumb-transition: transform 0.3s; 2127 --media-range-thumb-opacity: 1; 2128 --media-preview-background: var(--_primary-color); 2129 --media-box-arrow-background: var(--_primary-color); 2130 --media-preview-thumbnail-border: 5px solid var(--_primary-color); 2131 --media-preview-border-radius: 5px; 2132 --media-text-color: var(--_text-color); 2133 --media-control-hover-background: transparent; 2134 --media-preview-chapter-text-shadow: none; 2135 color: var(--_accent-color); 2136 padding: 0 6px; 2137 } 2138 2139 :host([audio]) media-time-range { 2140 --media-preview-time-padding: 1.5px 6px; 2141 --media-preview-box-margin: 0 0 -5px; 2142 } 2143 2144 media-time-range:hover { 2145 --media-range-thumb-transform: scale(1); 2146 } 2147 2148 media-preview-thumbnail { 2149 border-bottom-width: 0; 2150 } 2151 2152 [part~='menu'] { 2153 border-radius: 2px; 2154 border: 1px solid rgba(0, 0, 0, 0.1); 2155 bottom: 50px; 2156 padding: 2.5px 10px; 2157 } 2158 2159 [part~='menu']::part(indicator) { 2160 fill: var(--_accent-color); 2161 } 2162 2163 [part~='menu']::part(menu-item) { 2164 box-sizing: border-box; 2165 display: flex; 2166 align-items: center; 2167 padding: 6px 10px; 2168 min-height: 34px; 2169 } 2170 2171 [part~='menu']::part(checked) { 2172 font-weight: 700; 2173 } 2174 2175 media-captions-menu, 2176 media-rendition-menu, 2177 media-audio-track-menu, 2178 media-playback-rate-menu { 2179 position: absolute; /* ensure they don't take up space in DOM on load */ 2180 --media-menu-background: var(--_primary-color); 2181 --media-menu-item-checked-background: transparent; 2182 --media-text-color: var(--_text-color); 2183 --media-menu-item-hover-background: transparent; 2184 --media-menu-item-hover-outline: var(--_accent-color) solid 1px; 2185 } 2186 2187 media-rendition-menu { 2188 min-width: 140px; 2189 } 2190 2191 /* The icon is a circle so make it 16px high instead of 14px for more balance. */ 2192 media-audio-track-menu-button { 2193 --media-control-padding: 5px; 2194 --media-control-height: 16px; 2195 } 2196 2197 media-playback-rate-menu-button { 2198 --media-control-padding: 6px 3px; 2199 min-width: 4.4ch; 2200 } 2201 2202 media-playback-rate-menu { 2203 --media-menu-flex-direction: row; 2204 --media-menu-item-checked-background: var(--_accent-color); 2205 --media-menu-item-checked-indicator-display: none; 2206 margin-right: 6px; 2207 padding: 0; 2208 --media-menu-gap: 0.25em; 2209 } 2210 2211 media-playback-rate-menu[part~='menu']::part(menu-item) { 2212 padding: 6px 6px 6px 8px; 2213 } 2214 2215 media-playback-rate-menu[part~='menu']::part(checked) { 2216 color: #fff; 2217 } 2218 2219 :host(:not([audio])) media-time-range { 2220 /* Adding px is required here for calc() */ 2221 --media-range-padding: 0px; 2222 background: transparent; 2223 z-index: 10; 2224 height: 10px; 2225 bottom: -3px; 2226 width: 100%; 2227 } 2228 2229 media-control-bar :is([role='button'], [role='switch'], button) { 2230 line-height: 0; 2231 } 2232 2233 media-control-bar :is([part*='button'], [part*='range'], [part*='display']) { 2234 border-radius: 3px; 2235 } 2236 2237 .spacer { 2238 flex-grow: 1; 2239 background-color: var(--media-control-background, rgba(20, 20, 30, 0.7)); 2240 } 2241 2242 media-control-bar[slot~='top-chrome'] { 2243 min-height: 42px; 2244 pointer-events: none; 2245 } 2246 2247 media-control-bar { 2248 --gradient-steps: 2249 hsl(0 0% 0% / 0) 0%, hsl(0 0% 0% / 0.013) 8.1%, hsl(0 0% 0% / 0.049) 15.5%, hsl(0 0% 0% / 0.104) 22.5%, 2250 hsl(0 0% 0% / 0.175) 29%, hsl(0 0% 0% / 0.259) 35.3%, hsl(0 0% 0% / 0.352) 41.2%, hsl(0 0% 0% / 0.45) 47.1%, 2251 hsl(0 0% 0% / 0.55) 52.9%, hsl(0 0% 0% / 0.648) 58.8%, hsl(0 0% 0% / 0.741) 64.7%, hsl(0 0% 0% / 0.825) 71%, 2252 hsl(0 0% 0% / 0.896) 77.5%, hsl(0 0% 0% / 0.951) 84.5%, hsl(0 0% 0% / 0.987) 91.9%, hsl(0 0% 0%) 100%; 2253 } 2254 2255 :host([title]) media-control-bar[slot='top-chrome']::before, 2256 :host([videotitle]) media-control-bar[slot='top-chrome']::before { 2257 content: ''; 2258 position: absolute; 2259 width: 100%; 2260 padding-bottom: min(100px, 25%); 2261 background: linear-gradient(to top, var(--gradient-steps)); 2262 opacity: 0.8; 2263 pointer-events: none; 2264 } 2265 2266 :host(:not([audio])) media-control-bar[part~='bottom']::before { 2267 content: ''; 2268 position: absolute; 2269 width: 100%; 2270 bottom: 0; 2271 left: 0; 2272 padding-bottom: min(100px, 25%); 2273 background: linear-gradient(to bottom, var(--gradient-steps)); 2274 opacity: 0.8; 2275 z-index: 1; 2276 pointer-events: none; 2277 } 2278 2279 media-control-bar[part~='bottom'] > * { 2280 z-index: 20; 2281 } 2282 2283 media-control-bar[part~='bottom'] { 2284 padding: 6px 6px; 2285 } 2286 2287 media-control-bar[slot~='top-chrome'] > * { 2288 --media-control-background: transparent; 2289 --media-control-hover-background: transparent; 2290 position: relative; 2291 } 2292 2293 media-controller::part(vertical-layer) { 2294 transition: background-color 1s; 2295 } 2296 2297 media-controller:is([mediapaused], :not([userinactive]))::part(vertical-layer) { 2298 background-color: var(--controls-backdrop-color, var(--controls, transparent)); 2299 transition: background-color 0.25s; 2300 } 2301 2302 .center-controls { 2303 --media-button-icon-width: 100%; 2304 --media-button-icon-height: auto; 2305 --media-tooltip-display: none; 2306 pointer-events: none; 2307 width: 100%; 2308 display: flex; 2309 flex-flow: row; 2310 align-items: center; 2311 justify-content: center; 2312 paint-order: stroke; 2313 stroke: rgba(102, 102, 102, 1); 2314 stroke-width: 0.3px; 2315 text-shadow: 2316 0 0 2px rgb(0 0 0 / 0.25), 2317 0 0 6px rgb(0 0 0 / 0.25); 2318
2318} 2319 2320 .center-controls media-play-button { 2321 --media-control-background: transparent; 2322 --media-control-hover-background: transparent; 2323 --media-control-padding: 0; 2324 width: 40px; 2325 filter: drop-shadow(0 0 2px rgb(0 0 0 / 0.25)) drop-shadow(0 0 6px rgb(0 0 0 / 0.25))
vendor: 38,939 bytes, lines 2325-3150
2325; 2326 } 2327 2328 [breakpointsm] .center-controls media-play-button { 2329 width: 90px; 2330 height: 90px; 2331 border-radius: 50%; 2332 transition: background 0.4s; 2333 padding: 24px; 2334 --media-control-background: #000; 2335 --media-control-hover-background: var(--_accent-color); 2336 } 2337 2338 .center-controls media-seek-backward-button, 2339 .center-controls media-seek-forward-button { 2340 --media-control-background: transparent; 2341 --media-control-hover-background: transparent; 2342 padding: 0; 2343 margin: 0 20px; 2344 width: max(33px, min(8%, 40px)); 2345 text-shadow: 2346 0 0 2px rgb(0 0 0 / 0.25), 2347 0 0 6px rgb(0 0 0 / 0.25); 2348 } 2349 2350 [breakpointsm]:not([audio]) .center-controls.pre-playback { 2351 display: grid; 2352 align-items: initial; 2353 justify-content: initial; 2354 height: 100%; 2355 overflow: hidden; 2356 } 2357 2358 [breakpointsm]:not([audio]) .center-controls.pre-playback media-play-button { 2359 place-self: var(--_pre-playback-place, center); 2360 grid-area: 1 / 1; 2361 margin: 16px; 2362 } 2363 2364 /* Show and hide controls or pre-playback state */ 2365 2366 [breakpointsm]:is([mediahasplayed], :not([mediapaused])):not([audio]) 2367 .center-controls.pre-playback 2368 media-play-button { 2369 /* Using \`forwards\` would lead to a laggy UI after the animation got in the end state */ 2370 animation: 0.3s linear pre-play-hide; 2371 opacity: 0; 2372 pointer-events: none; 2373 } 2374 2375 .autoplay-unmute { 2376 --media-control-hover-background: transparent; 2377 width: 100%; 2378 display: flex; 2379 align-items: center; 2380 justify-content: center; 2381 filter: drop-shadow(0 0 2px rgb(0 0 0 / 0.25)) drop-shadow(0 0 6px rgb(0 0 0 / 0.25)); 2382 } 2383 2384 .autoplay-unmute-btn { 2385 --media-control-height: 16px; 2386 border-radius: 8px; 2387 background: #000; 2388 color: var(--_primary-color); 2389 display: flex; 2390 align-items: center; 2391 padding: 8px 16px; 2392 font-size: 18px; 2393 font-weight: 500; 2394 cursor: pointer; 2395 } 2396 2397 .autoplay-unmute-btn:hover { 2398 background: var(--_accent-color); 2399 } 2400 2401 [breakpointsm] .autoplay-unmute-btn { 2402 --media-control-height: 30px; 2403 padding: 14px 24px; 2404 font-size: 26px; 2405 } 2406 2407 .autoplay-unmute-btn svg { 2408 margin: 0 6px 0 0; 2409 } 2410 2411 [breakpointsm] .autoplay-unmute-btn svg { 2412 margin: 0 10px 0 0; 2413 } 2414 2415 media-controller:not([audio]):not([mediahasplayed]) *:is(media-control-bar, media-time-range) { 2416 display: none; 2417 } 2418 2419 media-error-dialog:not([mediaerrorcode]) { 2420 opacity: 0; 2421 } 2422 2423 media-loading-indicator { 2424 --media-loading-icon-width: 100%; 2425 --media-button-icon-height: auto; 2426 display: var(--media-control-display, var(--media-loading-indicator-display, flex)); 2427 pointer-events: none; 2428 position: absolute; 2429 width: min(15%, 150px); 2430 flex-flow: row; 2431 align-items: center; 2432 justify-content: center; 2433 } 2434 2435 /* Intentionally don't target the div for transition but the children 2436 of the div. Prevents messing with media-chrome's autohide feature. */ 2437 media-loading-indicator + div * { 2438 transition: opacity 0.15s; 2439 opacity: 1; 2440 } 2441 2442 media-loading-indicator[medialoading]:not([mediapaused]) ~ div > * { 2443 opacity: 0; 2444 transition-delay: 400ms; 2445 } 2446 2447 media-volume-range { 2448 width: min(100%, 100px); 2449 --media-range-padding-left: 10px; 2450 --media-range-padding-right: 10px; 2451 --media-range-thumb-width: 12px; 2452 --media-range-thumb-height: 12px; 2453 --media-range-thumb-background: radial-gradient( 2454 circle, 2455 #000 0%, 2456 #000 25%, 2457 var(--_primary-color) 25%, 2458 var(--_primary-color) 2459 ); 2460 --media-control-hover-background: none; 2461 } 2462 2463 media-time-display { 2464 white-space: nowrap; 2465 } 2466 2467 /* Generic style for explicitly disabled controls */ 2468 media-control-bar[part~='bottom'] [disabled], 2469 media-control-bar[part~='bottom'] [aria-disabled='true'] { 2470 opacity: 60%; 2471 cursor: not-allowed; 2472 } 2473 2474 media-text-display { 2475 --media-font-size: 16px; 2476 --media-control-padding: 14px; 2477 font-weight: 500; 2478 } 2479 2480 media-play-button.animated *:is(g, path) { 2481 transition: all 0.3s; 2482 } 2483 2484 media-play-button.animated[mediapaused] .pause-icon-pt1 { 2485 opacity: 0; 2486 } 2487 2488 media-play-button.animated[mediapaused] .pause-icon-pt2 { 2489 transform-origin: center center; 2490 transform: scaleY(0); 2491 } 2492 2493 media-play-button.animated[mediapaused] .play-icon { 2494 clip-path: inset(0 0 0 0); 2495 } 2496 2497 media-play-button.animated:not([mediapaused]) .play-icon { 2498 clip-path: inset(0 0 0 100%); 2499 } 2500 2501 media-seek-forward-button, 2502 media-seek-backward-button { 2503 --media-font-weight: 400; 2504 } 2505 2506 .mute-icon { 2507 display: inline-block; 2508 } 2509 2510 .mute-icon :is(path, g) { 2511 transition: opacity 0.5s; 2512 } 2513 2514 .muted { 2515 opacity: 0; 2516 } 2517 2518 media-mute-button[mediavolumelevel='low'] :is(.volume-medium, .volume-high), 2519 media-mute-button[mediavolumelevel='medium'] :is(.volume-high) { 2520 opacity: 0; 2521 } 2522 2523 media-mute-button[mediavolumelevel='off'] .unmuted { 2524 opacity: 0; 2525 } 2526 2527 media-mute-button[mediavolumelevel='off'] .muted { 2528 opacity: 1; 2529 } 2530 2531 /** 2532 * Our defaults for these buttons are to hide them at small sizes 2533 * users can override this with CSS 2534 */ 2535 media-controller:not([breakpointsm]):not([audio]) { 2536 --bottom-play-button: none; 2537 --bottom-seek-backward-button: none; 2538 --bottom-seek-forward-button: none; 2539 --bottom-time-display: none; 2540 --bottom-playback-rate-menu-button: none; 2541 --bottom-pip-button: none; 2542 } 2543 2544 [part='mux-badge'] { 2545 position: absolute; 2546 bottom: 10px; 2547 right: 10px; 2548 z-index: 2; 2549 opacity: 0.6; 2550 transition: 2551 opacity 0.2s ease-in-out, 2552 bottom 0.2s ease-in-out; 2553 } 2554 2555 [part='mux-badge']:hover { 2556 opacity: 1; 2557 } 2558 2559 [part='mux-badge'] a { 2560 font-size: 14px; 2561 font-family: var(--_font-family); 2562 color: var(--_primary-color); 2563 text-decoration: none; 2564 display: flex; 2565 align-items: center; 2566 gap: 5px; 2567 } 2568 2569 [part='mux-badge'] .mux-badge-text { 2570 transition: opacity 0.5s ease-in-out; 2571 opacity: 0; 2572 } 2573 2574 [part='mux-badge'] .mux-badge-logo { 2575 width: 40px; 2576 height: auto; 2577 display: inline-block; 2578 } 2579 2580 [part='mux-badge'] .mux-badge-logo svg { 2581 width: 100%; 2582 height: 100%; 2583 fill: white; 2584 } 2585 2586 media-controller:not([userinactive]):not([mediahasplayed]) [part='mux-badge'], 2587 media-controller:not([userinactive]) [part='mux-badge'], 2588 media-controller[mediahasplayed][mediapaused] [part='mux-badge'] { 2589 transition: bottom 0.1s ease-in-out; 2590 } 2591 2592 media-controller[userinactive]:not([mediapaused]) [part='mux-badge'] { 2593 transition: bottom 0.2s ease-in-out 0.62s; 2594 } 2595 2596 media-controller:not([userinactive]) [part='mux-badge'] .mux-badge-text, 2597 media-controller[mediahasplayed][mediapaused] [part='mux-badge'] .mux-badge-text { 2598 opacity: 1; 2599 } 2600 2601 media-controller[userinactive]:not([mediapaused]) [part='mux-badge'] .mux-badge-text { 2602 opacity: 0; 2603 } 2604 2605 media-controller[userinactive]:not([mediapaused]) [part='mux-badge'] { 2606 bottom: 10px; 2607 } 2608 2609 media-controller:not([userinactive]):not([mediahasplayed]) [part='mux-badge'] { 2610 bottom: 10px; 2611 } 2612 2613 media-controller:not([userinactive])[mediahasplayed] [part='mux-badge'], 2614 media-controller[mediahasplayed][mediapaused] [part='mux-badge'] { 2615 bottom: calc(28px + var(--media-control-height, 0px) + var(--media-control-padding, 0px) * 2); 2616 } 2617 </style> 2618 2619 <template partial="TitleDisplay"> 2620 <template if="videotitle"> 2621 <template if="videotitle != true"> 2622 <media-text-display part="top title display" class="title-display">{{videotitle}}</media-text-display> 2623 </template> 2624 </template> 2625 <template if="!videotitle"> 2626 <template if="title"> 2627 <media-text-display part="top title display" class="title-display">{{title}}</media-text-display> 2628 </template> 2629 </template> 2630 </template> 2631 2632 <template partial="PlayButton"> 2633 <media-play-button 2634 part="{{section ?? 'bottom'}} play button" 2635 disabled="{{disabled}}" 2636 aria-disabled="{{disabled}}" 2637 class="animated" 2638 > 2639 <svg aria-hidden="true" viewBox="0 0 18 14" slot="icon"> 2640 <g class="play-icon"> 2641 <path 2642 d="M15.5987 6.2911L3.45577 0.110898C2.83667 -0.204202 2.06287 0.189698 2.06287 0.819798V13.1802C2.06287 13.8103 2.83667 14.2042 3.45577 13.8891L15.5987 7.7089C16.2178 7.3938 16.2178 6.6061 15.5987 6.2911Z" 2643 /> 2644 </g> 2645 <g class="pause-icon"> 2646 <path 2647 class="pause-icon-pt1" 2648 d="M5.90709 0H2.96889C2.46857 0 2.06299 0.405585 2.06299 0.9059V13.0941C2.06299 13.5944 2.46857 14 2.96889 14H5.90709C6.4074 14 6.81299 13.5944 6.81299 13.0941V0.9059C6.81299 0.405585 6.4074 0 5.90709 0Z" 2649 /> 2650 <path 2651 class="pause-icon-pt2" 2652 d="M15.1571 0H12.2189C11.7186 0 11.313 0.405585 11.313 0.9059V13.0941C11.313 13.5944 11.7186 14 12.2189 14H15.1571C15.6574 14 16.063 13.5944 16.063 13.0941V0.9059C16.063 0.405585 15.6574 0 15.1571 0Z" 2653 /> 2654 </g> 2655 </svg> 2656 </media-play-button> 2657 </template> 2658 2659 <template partial="PrePlayButton"> 2660 <media-play-button 2661 part="{{section ?? 'center'}} play button pre-play" 2662 disabled="{{disabled}}" 2663 aria-disabled="{{disabled}}" 2664 > 2665 <svg aria-hidden="true" viewBox="0 0 18 14" slot="icon" style="transform: translate(3px, 0)"> 2666 <path 2667 d="M15.5987 6.2911L3.45577 0.110898C2.83667 -0.204202 2.06287 0.189698 2.06287 0.819798V13.1802C2.06287 13.8103 2.83667 14.2042 3.45577 13.8891L15.5987 7.7089C16.2178 7.3938 16.2178 6.6061 15.5987 6.2911Z" 2668 /> 2669 </svg> 2670 </media-play-button> 2671 </template> 2672 2673 <template partial="SeekBackwardButton"> 2674 <media-seek-backward-button 2675 seekoffset="{{backwardseekoffset}}" 2676 part="{{section ?? 'bottom'}} seek-backward button" 2677 disabled="{{disabled}}" 2678 aria-disabled="{{disabled}}" 2679 > 2680 <svg viewBox="0 0 22 14" aria-hidden="true" slot="icon"> 2681 <path 2682 d="M3.65 2.07888L0.0864 6.7279C-0.0288 6.87812 -0.0288 7.12188 0.0864 7.2721L3.65 11.9211C3.7792 12.0896 4 11.9703 4 11.7321V2.26787C4 2.02968 3.7792 1.9104 3.65 2.07888Z" 2683 /> 2684 <text transform="translate(6 12)" style="font-size: 14px; font-family: 'ArialMT', 'Arial'"> 2685 {{backwardseekoffset}} 2686 </text> 2687 </svg> 2688 </media-seek-backward-button> 2689 </template> 2690 2691 <template partial="SeekForwardButton"> 2692 <media-seek-forward-button 2693 seekoffset="{{forwardseekoffset}}" 2694 part="{{section ?? 'bottom'}} seek-forward button" 2695 disabled="{{disabled}}" 2696 aria-disabled="{{disabled}}" 2697 > 2698 <svg viewBox="0 0 22 14" aria-hidden="true" slot="icon"> 2699 <g> 2700 <text transform="translate(-1 12)" style="font-size: 14px; font-family: 'ArialMT', 'Arial'"> 2701 {{forwardseekoffset}} 2702 </text> 2703 <path 2704 d="M18.35 11.9211L21.9136 7.2721C22.0288 7.12188 22.0288 6.87812 21.9136 6.7279L18.35 2.07888C18.2208 1.91041 18 2.02968 18 2.26787V11.7321C18 11.9703 18.2208 12.0896 18.35 11.9211Z" 2705 /> 2706 </g> 2707 </svg> 2708 </media-seek-forward-button> 2709 </template> 2710 2711 <template partial="MuteButton"> 2712 <media-mute-button part="bottom mute button" disabled="{{disabled}}" aria-disabled="{{disabled}}"> 2713 <svg viewBox="0 0 18 14" slot="icon" class="mute-icon" aria-hidden="true"> 2714 <g class="unmuted"> 2715 <path 2716 d="M6.76786 1.21233L3.98606 3.98924H1.19937C0.593146 3.98924 0.101743 4.51375 0.101743 5.1607V6.96412L0 6.99998L0.101743 7.03583V8.83926C0.101743 9.48633 0.593146 10.0108 1.19937 10.0108H3.98606L6.76773 12.7877C7.23561 13.2547 8 12.9007 8 12.2171V1.78301C8 1.09925 7.23574 0.745258 6.76786 1.21233Z" 2717 /> 2718 <path 2719 class="volume-low" 2720 d="M10 3.54781C10.7452 4.55141 11.1393 5.74511 11.1393 6.99991C11.1393 8.25471 10.7453 9.44791 10 10.4515L10.7988 11.0496C11.6734 9.87201 12.1356 8.47161 12.1356 6.99991C12.1356 5.52821 11.6735 4.12731 10.7988 2.94971L10 3.54781Z" 2721 /> 2722 <path 2723 class="volume-medium" 2724 d="M12.3778 2.40086C13.2709 3.76756 13.7428 5.35806 13.7428 7.00026C13.7428 8.64246 13.2709 10.233 12.3778 11.5992L13.2106 12.1484C14.2107 10.6185 14.739 8.83796 14.739 7.00016C14.739 5.16236 14.2107 3.38236 13.2106 1.85156L12.3778 2.40086Z" 2725 /> 2726 <path 2727 class="volume-high" 2728 d="M15.5981 0.75L14.7478 1.2719C15.7937 2.9919 16.3468 4.9723 16.3468 7C16.3468 9.0277 15.7937 11.0082 14.7478 12.7281L15.5981 13.25C16.7398 11.3722 17.343 9.211 17.343 7C17.343 4.789 16.7398 2.6268 15.5981 0.75Z" 2729 /> 2730 </g> 2731 <g class="muted"> 2732 <path 2733 fill-rule="evenodd" 2734 clip-rule="evenodd" 2735 d="M4.39976 4.98924H1.19937C1.19429 4.98924 1.17777 4.98961 1.15296 5.01609C1.1271 5.04369 1.10174 5.09245 1.10174 5.1607V8.83926C1.10174 8.90761 1.12714 8.95641 1.15299 8.984C1.17779 9.01047 1.1943 9.01084 1.19937 9.01084H4.39977L7 11.6066V2.39357L4.39976 4.98924ZM7.47434 1.92006C7.4743 1.9201 7.47439 1.92002 7.47434 1.92006V1.92006ZM6.76773 12.7877L3.98606 10.0108H1.19937C0.593146 10.0108 0.101743 9.48633 0.101743 8.83926V7.03583L0 6.99998L0.101743 6.96412V5.1607C0.101743 4.51375 0.593146 3.98924 1.19937 3.98924H3.98606L6.76786 1.21233C7.23574 0.745258 8 1.09925 8 1.78301V12.2171C8 12.9007 7.23561 13.2547 6.76773 12.7877Z" 2736 /> 2737 <path 2738 fill-rule="evenodd" 2739 clip-rule="evenodd" 2740 d="M15.2677 9.30323C15.463 9.49849 15.7796 9.49849 15.9749 9.30323C16.1701 9.10796 16.1701 8.79138 15.9749 8.59612L14.2071 6.82841L15.9749 5.06066C16.1702 4.8654 16.1702 4.54882 15.9749 4.35355C15.7796 4.15829 15.4631 4.15829 15.2678 4.35355L13.5 6.1213L11.7322 4.35348C11.537 4.15822 11.2204 4.15822 11.0251 4.35348C10.8298 4.54874 10.8298 4.86532 11.0251 5.06058L12.7929 6.82841L11.0251 8.59619C10.8299 8.79146 10.8299 9.10804 11.0251 9.3033C11.2204 9.49856 11.537 9.49856 11.7323 9.3033L13.5 7.53552L15.2677 9.30323Z" 2741 /> 2742 </g> 2743 </svg> 2744 </media-mute-button> 2745 </template> 2746 2747 <template partial="PipButton"> 2748 <media-pip-button part="bottom pip button" disabled="{{disabled}}" aria-disabled="{{disabled}}"> 2749 <svg viewBox="0 0 18 14" aria-hidden="true" slot="icon"> 2750 <path 2751 d="M15.9891 0H2.011C0.9004 0 0 0.9003 0 2.0109V11.989C0 13.0996 0.9004 14 2.011 14H15.9891C17.0997 14 18 13.0997 18 11.9891V2.0109C18 0.9003 17.0997 0 15.9891 0ZM17 11.9891C17 12.5465 16.5465 13 15.9891 13H2.011C1.4536 13 1.0001 12.5465 1.0001 11.9891V2.0109C1.0001 1.4535 1.4536 0.9999 2.011 0.9999H15.9891C16.5465 0.9999 17 1.4535 17 2.0109V11.9891Z" 2752 /> 2753 <path 2754 d="M15.356 5.67822H8.19523C8.03253 5.67822 7.90063 5.81012 7.90063 5.97282V11.3836C7.90063 11.5463 8.03253 11.6782 8.19523 11.6782H15.356C15.5187 11.6782 15.6506 11.5463 15.6506 11.3836V5.97282C15.6506 5.81012 15.5187 5.67822 15.356 5.67822Z" 2755 /> 2756 </svg> 2757 </media-pip-button> 2758 </template> 2759 2760 <template partial="CaptionsMenu"> 2761 <media-captions-menu-button part="bottom captions button"> 2762 <svg aria-hidden="true" viewBox="0 0 18 14" slot="on"> 2763 <path 2764 d="M15.989 0H2.011C0.9004 0 0 0.9003 0 2.0109V11.9891C0 13.0997 0.9004 14 2.011 14H15.989C17.0997 14 18 13.0997 18 11.9891V2.0109C18 0.9003 17.0997 0 15.989 0ZM4.2292 8.7639C4.5954 9.1902 5.0935 9.4031 5.7233 9.4031C6.1852 9.4031 6.5544 9.301 6.8302 9.0969C7.1061 8.8933 7.2863 8.614 7.3702 8.26H8.4322C8.3062 8.884 8.0093 9.3733 7.5411 9.7273C7.0733 10.0813 6.4703 10.2581 5.732 10.2581C5.108 10.2581 4.5699 10.1219 4.1168 9.8489C3.6637 9.5759 3.3141 9.1946 3.0685 8.7058C2.8224 8.2165 2.6994 7.6511 2.6994 7.009C2.6994 6.3611 2.8224 5.7927 3.0685 5.3034C3.3141 4.8146 3.6637 4.4323 4.1168 4.1559C4.5699 3.88 5.108 3.7418 5.732 3.7418C6.4703 3.7418 7.0733 3.922 7.5411 4.2818C8.0094 4.6422 8.3062 5.1461 8.4322 5.794H7.3702C7.2862 5.4283 7.106 5.1368 6.8302 4.921C6.5544 4.7052 6.1852 4.5968 5.7233 4.5968C5.0934 4.5968 4.5954 4.8116 4.2292 5.2404C3.8635 5.6696 3.6804 6.259 3.6804 7.009C3.6804 7.7531 3.8635 8.3381 4.2292 8.7639ZM11.0974 8.7639C11.4636 9.1902 11.9617 9.4031 12.5915 9.4031C13.0534 9.4031 13.4226 9.301 13.6984 9.0969C13.9743 8.8933 14.1545 8.614 14.2384 8.26H15.3004C15.1744 8.884 14.8775 9.3733 14.4093 9.7273C13.9415 10.0813 13.3385 10.2581 12.6002 10.2581C11.9762 10.2581 11.4381 10.1219 10.985 9.8489C10.5319 9.5759 10.1823 9.1946 9.9367 8.7058C9.6906 8.2165 9.5676 7.6511 9.5676 7.009C9.5676 6.3611 9.6906 5.7927 9.9367 5.3034C10.1823 4.8146 10.5319 4.4323 10.985 4.1559C11.4381 3.88 11.9762 3.7418 12.6002 3.7418C13.3385 3.7418 13.9415 3.922 14.4093 4.2818C14.8776 4.6422 15.1744 5.1461 15.3004 5.794H14.2384C14.1544 5.4283 13.9742 5.1368 13.6984 4.921C13.4226 4.7052 13.0534 4.5968 12.5915 4.5968C11.9616 4.5968 11.4636 4.8116 11.0974 5.2404C10.7317 5.6696 10.5486 6.259 10.5486 7.009C10.5486 7.7531 10.7317 8.3381 11.0974 8.7639Z" 2765 /> 2766 </svg> 2767 <svg aria-hidden="true" viewBox="0 0 18 14" slot="off"> 2768 <path 2769 d="M5.73219 10.258C5.10819 10.258 4.57009 10.1218 4.11699 9.8488C3.66389 9.5758 3.31429 9.1945 3.06869 8.7057C2.82259 8.2164 2.69958 7.651 2.69958 7.0089C2.69958 6.361 2.82259 5.7926 3.06869 5.3033C3.31429 4.8145 3.66389 4.4322 4.11699 4.1558C4.57009 3.8799 5.10819 3.7417 5.73219 3.7417C6.47049 3.7417 7.07348 3.9219 7.54128 4.2817C8.00958 4.6421 8.30638 5.146 8.43238 5.7939H7.37039C7.28639 5.4282 7.10618 5.1367 6.83039 4.9209C6.55459 4.7051 6.18538 4.5967 5.72348 4.5967C5.09358 4.5967 4.59559 4.8115 4.22939 5.2403C3.86369 5.6695 3.68058 6.2589 3.68058 7.0089C3.68058 7.753 3.86369 8.338 4.22939 8.7638C4.59559 9.1901 5.09368 9.403 5.72348 9.403C6.18538 9.403 6.55459 9.3009 6.83039 9.0968C7.10629 8.8932 7.28649 8.6139 7.37039 8.2599H8.43238C8.30638 8.8839 8.00948 9.3732 7.54128 9.7272C7.07348 10.0812 6.47049 10.258 5.73219 10.258Z" 2770 /> 2771 <path 2772 d="M12.6003 10.258C11.9763 10.258 11.4382 10.1218 10.9851 9.8488C10.532 9.5758 10.1824 9.1945 9.93685 8.7057C9.69075 8.2164 9.56775 7.651 9.56775 7.0089C9.56775 6.361 9.69075 5.7926 9.93685 5.3033C10.1824 4.8145 10.532 4.4322 10.9851 4.1558C11.4382 3.8799 11.9763 3.7417 12.6003 3.7417C13.3386 3.7417 13.9416 3.9219 14.4094 4.2817C14.8777 4.6421 15.1745 5.146 15.3005 5.7939H14.2385C14.1545 5.4282 13.9743 5.1367 13.6985 4.9209C13.4227 4.7051 13.0535 4.5967 12.5916 4.5967C11.9617 4.5967 11.4637 4.8115 11.0975 5.2403C10.7318 5.6695 10.5487 6.2589 10.5487 7.0089C10.5487 7.753 10.7318 8.338 11.0975 8.7638C11.4637 9.1901 11.9618 9.403 12.5916 9.403C13.0535 9.403 13.4227 9.3009 13.6985 9.0968C13.9744 8.8932 14.1546 8.6139 14.2385 8.2599H15.3005C15.1745 8.8839 14.8776 9.3732 14.4094 9.7272C13.9416 10.0812 13.3386 10.258 12.6003 10.258Z" 2773 /> 2774 <path 2775 d="M15.9891 1C16.5465 1 17 1.4535 17 2.011V11.9891C17 12.5465 16.5465 13 15.9891 13H2.0109C1.4535 13 1 12.5465 1 11.9891V2.0109C1 1.4535 1.4535 0.9999 2.0109 0.9999L15.9891 1ZM15.9891 0H2.0109C0.9003 0 0 0.9003 0 2.0109V11.9891C0 13.0997 0.9003 14 2.0109 14H15.9891C17.0997 14 18 13.0997 18 11.9891V2.0109C18 0.9003 17.0997 0 15.9891 0Z" 2776 /> 2777 </svg> 2778 </media-captions-menu-button> 2779 <media-captions-menu 2780 hidden 2781 anchor="auto" 2782 part="bottom captions menu" 2783 disabled="{{disabled}}" 2784 aria-disabled="{{disabled}}" 2785 exportparts="menu-item" 2786 > 2787 <div slot="checked-indicator"> 2788 <style> 2789 .indicator { 2790 position: relative; 2791 top: 1px; 2792 width: 0.9em; 2793 height: auto; 2794 fill: var(--_accent-color); 2795 margin-right: 5px; 2796 } 2797 2798 [aria-checked='false'] .indicator { 2799 display: none; 2800 } 2801 </style> 2802 <svg viewBox="0 0 14 18" class="indicator"> 2803 <path 2804 d="M12.252 3.48c-.115.033-.301.161-.425.291-.059.063-1.407 1.815-2.995 3.894s-2.897 3.79-2.908 3.802c-.013.014-.661-.616-1.672-1.624-.908-.905-1.702-1.681-1.765-1.723-.401-.27-.783-.211-1.176.183a1.285 1.285 0 0 0-.261.342.582.582 0 0 0-.082.35c0 .165.01.205.08.35.075.153.213.296 2.182 2.271 1.156 1.159 2.17 2.159 2.253 2.222.189.143.338.196.539.194.203-.003.412-.104.618-.299.205-.193 6.7-8.693 6.804-8.903a.716.716 0 0 0 .085-.345c.01-.179.005-.203-.062-.339-.124-.252-.45-.531-.746-.639a.784.784 0 0 0-.469-.027" 2805 fill-rule="evenodd" 2806 /> 2807 </svg></div 2808 ></media-captions-menu> 2809 </template> 2810 2811 <template partial="AirplayButton"> 2812 <media-airplay-button part="bottom airplay button" disabled="{{disabled}}" aria-disabled="{{disabled}}"> 2813 <svg viewBox="0 0 18 14" aria-hidden="true" slot="icon"> 2814 <path 2815 d="M16.1383 0H1.8618C0.8335 0 0 0.8335 0 1.8617V10.1382C0 11.1664 0.8335 12 1.8618 12H3.076C3.1204 11.9433 3.1503 11.8785 3.2012 11.826L4.004 11H1.8618C1.3866 11 1 10.6134 1 10.1382V1.8617C1 1.3865 1.3866 0.9999 1.8618 0.9999H16.1383C16.6135 0.9999 17.0001 1.3865 17.0001 1.8617V10.1382C17.0001 10.6134 16.6135 11 16.1383 11H13.9961L14.7989 11.826C14.8499 11.8785 14.8798 11.9432 14.9241 12H16.1383C17.1665 12 18.0001 11.1664 18.0001 10.1382V1.8617C18 0.8335 17.1665 0 16.1383 0Z" 2816 /> 2817 <path 2818 d="M9.55061 8.21903C9.39981 8.06383 9.20001 7.98633 9.00011 7.98633C8.80021 7.98633 8.60031 8.06383 8.44951 8.21903L4.09771 12.697C3.62471 13.1838 3.96961 13.9998 4.64831 13.9998H13.3518C14.0304 13.9998 14.3754 13.1838 13.9023 12.697L9.55061 8.21903Z" 2819 /> 2820 </svg> 2821 </media-airplay-button> 2822 </template> 2823 2824 <template partial="FullscreenButton"> 2825 <media-fullscreen-button part="bottom fullscreen button" disabled="{{disabled}}" aria-disabled="{{disabled}}"> 2826 <svg viewBox="0 0 18 14" aria-hidden="true" slot="enter"> 2827 <path 2828 d="M1.00745 4.39539L1.01445 1.98789C1.01605 1.43049 1.47085 0.978289 2.02835 0.979989L6.39375 0.992589L6.39665 -0.007411L2.03125 -0.020011C0.920646 -0.023211 0.0176463 0.874489 0.0144463 1.98509L0.00744629 4.39539H1.00745Z" 2829 /> 2830 <path 2831 d="M17.0144 2.03431L17.0076 4.39541H18.0076L18.0144 2.03721C18.0176 0.926712 17.1199 0.0237125 16.0093 0.0205125L11.6439 0.0078125L11.641 1.00781L16.0064 1.02041C16.5638 1.02201 17.016 1.47681 17.0144 2.03431Z" 2832 /> 2833 <path 2834 d="M16.9925 9.60498L16.9855 12.0124C16.9839 12.5698 16.5291 13.022 15.9717 13.0204L11.6063 13.0078L11.6034 14.0078L15.9688 14.0204C17.0794 14.0236 17.9823 13.1259 17.9855 12.0153L17.9925 9.60498H16.9925Z" 2835 /> 2836 <path 2837 d="M0.985626 11.9661L0.992426 9.60498H-0.0074737L-0.0142737 11.9632C-0.0174737 13.0738 0.880226 13.9767 1.99083 13.98L6.35623 13.9926L6.35913 12.9926L1.99373 12.98C1.43633 12.9784 0.983926 12.5236 0.985626 11.9661Z" 2838 /> 2839 </svg> 2840 <svg viewBox="0 0 18 14" aria-hidden="true" slot="exit"> 2841 <path 2842 d="M5.39655 -0.0200195L5.38955 2.38748C5.38795 2.94488 4.93315 3.39708 4.37565 3.39538L0.0103463 3.38278L0.00744629 4.38278L4.37285 4.39538C5.48345 4.39858 6.38635 3.50088 6.38965 2.39028L6.39665 -0.0200195H5.39655Z" 2843 /> 2844 <path 2845 d="M12.6411 2.36891L12.6479 0.0078125H11.6479L11.6411 2.36601C11.6379 3.47651 12.5356 4.37951 13.6462 4.38271L18.0116 4.39531L18.0145 3.39531L13.6491 3.38271C13.0917 3.38111 12.6395 2.92641 12.6411 2.36891Z" 2846 /> 2847 <path 2848 d="M12.6034 14.0204L12.6104 11.613C12.612 11.0556 13.0668 10.6034 13.6242 10.605L17.9896 10.6176L17.9925 9.61759L13.6271 9.60499C12.5165 9.60179 11.6136 10.4995 11.6104 11.6101L11.6034 14.0204H12.6034Z" 2849 /> 2850 <path 2851 d="M5.359 11.6315L5.3522 13.9926H6.3522L6.359 11.6344C6.3622 10.5238 5.4645 9.62088 4.3539 9.61758L-0.0115043 9.60498L-0.0144043 10.605L4.351 10.6176C4.9084 10.6192 5.3607 11.074 5.359 11.6315Z" 2852 /> 2853 </svg> 2854 </media-fullscreen-button> 2855 </template> 2856 2857 <template partial="CastButton"> 2858 <media-cast-button part="bottom cast button" disabled="{{disabled}}" aria-disabled="{{disabled}}"> 2859 <svg viewBox="0 0 18 14" aria-hidden="true" slot="enter"> 2860 <path 2861 d="M16.0072 0H2.0291C0.9185 0 0.0181 0.9003 0.0181 2.011V5.5009C0.357 5.5016 0.6895 5.5275 1.0181 5.5669V2.011C1.0181 1.4536 1.4716 1 2.029 1H16.0072C16.5646 1 17.0181 1.4536 17.0181 2.011V11.9891C17.0181 12.5465 16.5646 13 16.0072 13H8.4358C8.4746 13.3286 8.4999 13.6611 8.4999 13.9999H16.0071C17.1177 13.9999 18.018 13.0996 18.018 11.989V2.011C18.0181 0.9003 17.1178 0 16.0072 0ZM0 6.4999V7.4999C3.584 7.4999 6.5 10.4159 6.5 13.9999H7.5C7.5 9.8642 4.1357 6.4999 0 6.4999ZM0 8.7499V9.7499C2.3433 9.7499 4.25 11.6566 4.25 13.9999H5.25C5.25 11.1049 2.895 8.7499 0 8.7499ZM0.0181 11V14H3.0181C3.0181 12.3431 1.675 11 0.0181 11Z" 2862 /> 2863 </svg> 2864 <svg viewBox="0 0 18 14" aria-hidden="true" slot="exit"> 2865 <path 2866 d="M15.9891 0H2.01103C0.900434 0 3.35947e-05 0.9003 3.35947e-05 2.011V5.5009C0.338934 5.5016 0.671434 5.5275 1.00003 5.5669V2.011C1.00003 1.4536 1.45353 1 2.01093 1H15.9891C16.5465 1 17 1.4536 17 2.011V11.9891C17 12.5465 16.5465 13 15.9891 13H8.41773C8.45653 13.3286 8.48183 13.6611 8.48183 13.9999H15.989C17.0996 13.9999 17.9999 13.0996 17.9999 11.989V2.011C18 0.9003 17.0997 0 15.9891 0ZM-0.0180664 6.4999V7.4999C3.56593 7.4999 6.48193 10.4159 6.48193 13.9999H7.48193C7.48193 9.8642 4.11763 6.4999 -0.0180664 6.4999ZM-0.0180664 8.7499V9.7499C2.32523 9.7499 4.23193 11.6566 4.23193 13.9999H5.23193C5.23193 11.1049 2.87693 8.7499 -0.0180664 8.7499ZM3.35947e-05 11V14H3.00003C3.00003 12.3431 1.65693 11 3.35947e-05 11Z" 2867 /> 2868 <path d="M2.15002 5.634C5.18352 6.4207 7.57252 8.8151 8.35282 11.8499H15.8501V2.1499H2.15002V5.634Z" /> 2869 </svg> 2870 </media-cast-button> 2871 </template> 2872 2873 <template partial="LiveButton"> 2874 <media-live-button part="{{section ?? 'top'}} live button" disabled="{{disabled}}" aria-disabled="{{disabled}}"> 2875 <span slot="text">Live</span> 2876 </media-live-button> 2877 </template> 2878 2879 <template partial="PlaybackRateMenu"> 2880 <media-playback-rate-menu-button part="bottom playback-rate button"></media-playback-rate-menu-button> 2881 <media-playback-rate-menu 2882 hidden 2883 anchor="auto" 2884 rates="{{playbackrates}}" 2885 exportparts="menu-item" 2886 part="bottom playback-rate menu" 2887 disabled="{{disabled}}" 2888 aria-disabled="{{disabled}}" 2889 ></media-playback-rate-menu> 2890 </template> 2891 2892 <template partial="VolumeRange"> 2893 <media-volume-range 2894 part="bottom volume range" 2895 disabled="{{disabled}}" 2896 aria-disabled="{{disabled}}" 2897 ></media-volume-range> 2898 </template> 2899 2900 <template partial="TimeDisplay"> 2901 <media-time-display 2902 remaining="{{defaultshowremainingtime}}" 2903 showduration="{{!hideduration}}" 2904 part="bottom time display" 2905 disabled="{{disabled}}" 2906 aria-disabled="{{disabled}}" 2907 ></media-time-display> 2908 </template> 2909 2910 <template partial="TimeRange"> 2911 <media-time-range part="bottom time range" disabled="{{disabled}}" aria-disabled="{{disabled}}" exportparts="thumb"> 2912 <media-preview-thumbnail slot="preview"></media-preview-thumbnail> 2913 <media-preview-chapter-display slot="preview"></media-preview-chapter-display> 2914 <media-preview-time-display slot="preview"></media-preview-time-display> 2915 <div slot="preview" part="arrow"></div> 2916 </media-time-range> 2917 </template> 2918 2919 <template partial="AudioTrackMenu"> 2920 <media-audio-track-menu-button part="bottom audio-track button"> 2921 <svg aria-hidden="true" slot="icon" viewBox="0 0 18 16"> 2922 <path d="M9 15A7 7 0 1 1 9 1a7 7 0 0 1 0 14Zm0 1A8 8 0 1 0 9 0a8 8 0 0 0 0 16Z" /> 2923 <path 2924 d="M5.2 6.3a.5.5 0 0 1 .5.5v2.4a.5.5 0 1 1-1 0V6.8a.5.5 0 0 1 .5-.5Zm2.4-2.4a.5.5 0 0 1 .5.5v7.2a.5.5 0 0 1-1 0V4.4a.5.5 0 0 1 .5-.5ZM10 5.5a.5.5 0 0 1 .5.5v4a.5.5 0 0 1-1 0V6a.5.5 0 0 1 .5-.5Zm2.4-.8a.5.5 0 0 1 .5.5v5.6a.5.5 0 0 1-1 0V5.2a.5.5 0 0 1 .5-.5Z" 2925 /> 2926 </svg> 2927 </media-audio-track-menu-button> 2928 <media-audio-track-menu 2929 hidden 2930 anchor="auto" 2931 part="bottom audio-track menu" 2932 disabled="{{disabled}}" 2933 aria-disabled="{{disabled}}" 2934 exportparts="menu-item" 2935 > 2936 <div slot="checked-indicator"> 2937 <style> 2938 .indicator { 2939 position: relative; 2940 top: 1px; 2941 width: 0.9em; 2942 height: auto; 2943 fill: var(--_accent-color); 2944 margin-right: 5px; 2945 } 2946 2947 [aria-checked='false'] .indicator { 2948 display: none; 2949 } 2950 </style> 2951 <svg viewBox="0 0 14 18" class="indicator"> 2952 <path 2953 d="M12.252 3.48c-.115.033-.301.161-.425.291-.059.063-1.407 1.815-2.995 3.894s-2.897 3.79-2.908 3.802c-.013.014-.661-.616-1.672-1.624-.908-.905-1.702-1.681-1.765-1.723-.401-.27-.783-.211-1.176.183a1.285 1.285 0 0 0-.261.342.582.582 0 0 0-.082.35c0 .165.01.205.08.35.075.153.213.296 2.182 2.271 1.156 1.159 2.17 2.159 2.253 2.222.189.143.338.196.539.194.203-.003.412-.104.618-.299.205-.193 6.7-8.693 6.804-8.903a.716.716 0 0 0 .085-.345c.01-.179.005-.203-.062-.339-.124-.252-.45-.531-.746-.639a.784.784 0 0 0-.469-.027" 2954 fill-rule="evenodd" 2955 /> 2956 </svg> 2957 </div> 2958 </media-audio-track-menu> 2959 </template> 2960 2961 <template partial="RenditionMenu"> 2962 <media-rendition-menu-button part="bottom rendition button"> 2963 <svg aria-hidden="true" slot="icon" viewBox="0 0 18 14"> 2964 <path 2965 d="M2.25 9a2 2 0 1 0 0-4 2 2 0 0 0 0 4ZM9 9a2 2 0 1 0 0-4 2 2 0 0 0 0 4Zm6.75 0a2 2 0 1 0 0-4 2 2 0 0 0 0 4Z" 2966 /> 2967 </svg> 2968 </media-rendition-menu-button> 2969 <media-rendition-menu 2970 hidden 2971 anchor="auto" 2972 part="bottom rendition menu" 2973 disabled="{{disabled}}" 2974 aria-disabled="{{disabled}}" 2975 > 2976 <div slot="checked-indicator"> 2977 <style> 2978 .indicator { 2979 position: relative; 2980 top: 1px; 2981 width: 0.9em; 2982 height: auto; 2983 fill: var(--_accent-color); 2984 margin-right: 5px; 2985 } 2986 2987 [aria-checked='false'] .indicator { 2988 opacity: 0; 2989 } 2990 </style> 2991 <svg viewBox="0 0 14 18" class="indicator"> 2992 <path 2993 d="M12.252 3.48c-.115.033-.301.161-.425.291-.059.063-1.407 1.815-2.995 3.894s-2.897 3.79-2.908 3.802c-.013.014-.661-.616-1.672-1.624-.908-.905-1.702-1.681-1.765-1.723-.401-.27-.783-.211-1.176.183a1.285 1.285 0 0 0-.261.342.582.582 0 0 0-.082.35c0 .165.01.205.08.35.075.153.213.296 2.182 2.271 1.156 1.159 2.17 2.159 2.253 2.222.189.143.338.196.539.194.203-.003.412-.104.618-.299.205-.193 6.7-8.693 6.804-8.903a.716.716 0 0 0 .085-.345c.01-.179.005-.203-.062-.339-.124-.252-.45-.531-.746-.639a.784.784 0 0 0-.469-.027" 2994 fill-rule="evenodd" 2995 /> 2996 </svg> 2997 </div> 2998 </media-rendition-menu> 2999 </template> 3000 3001 <template partial="MuxBadge"> 3002 <div part="mux-badge"> 3003 <a href="https://www.mux.com/player" target="_blank"> 3004 <span class="mux-badge-text">Powered by</span> 3005 <div class="mux-badge-logo"> 3006 <svg 3007 viewBox="0 0 1600 500" 3008 style="fill-rule: evenodd; clip-rule: evenodd; stroke-linejoin: round; stroke-miterlimit: 2" 3009 > 3010 <g> 3011 <path 3012 d="M994.287,93.486c-17.121,-0 -31,-13.879 -31,-31c0,-17.121 13.879,-31 31,-31c17.121,-0 31,13.879 31,31c0,17.121 -13.879,31 -31,31m0,-93.486c-34.509,-0 -62.484,27.976 -62.484,62.486l0,187.511c0,68.943 -56.09,125.033 -125.032,125.033c-68.942,-0 -125.03,-56.09 -125.03,-125.033l0,-187.511c0,-34.51 -27.976,-62.486 -62.485,-62.486c-34.509,-0 -62.484,27.976 -62.484,62.486l0,187.511c0,137.853 112.149,250.003 249.999,250.003c137.851,-0 250.001,-112.15 250.001,-250.003l0,-187.511c0,-34.51 -27.976,-62.486 -62.485,-62.486" 3013 style="fill-rule: nonzero" 3014 ></path> 3015 <path 3016 d="M1537.51,468.511c-17.121,-0 -31,-13.879 -31,-31c0,-17.121 13.879,-31 31,-31c17.121,-0 31,13.879 31,31c0,17.121 -13.879,31 -31,31m-275.883,-218.509l-143.33,143.329c-24.402,24.402 -24.402,63.966 0,88.368c24.402,24.402 63.967,24.402 88.369,-0l143.33,-143.329l143.328,143.329c24.402,24.4 63.967,24.402 88.369,-0c24.403,-24.402 24.403,-63.966 0.001,-88.368l-143.33,-143.329l0.001,-0.004l143.329,-143.329c24.402,-24.402 24.402,-63.965 0,-88.367c-24.402,-24.402 -63.967,-24.402 -88.369,-0l-143.329,143.328l-143.329,-143.328c-24.402,-24.401 -63.967,-24.402 -88.369,-0c-24.402,24.402 -24.402,63.965 0,88.367l143.329,143.329l0,0.004Z" 3017 style="fill-rule: nonzero" 3018 ></path> 3019 <path 3020 d="M437.511,468.521c-17.121,-0 -31,-13.879 -31,-31c0,-17.121 13.879,-31 31,-31c17.121,-0 31,13.879 31,31c0,17.121 -13.879,31 -31,31m23.915,-463.762c-23.348,-9.672 -50.226,-4.327 -68.096,13.544l-143.331,143.329l-143.33,-143.329c-17.871,-17.871 -44.747,-23.216 -68.096,-13.544c-23.349,9.671 -38.574,32.455 -38.574,57.729l0,375.026c0,34.51 27.977,62.486 62.487,62.486c34.51,-0 62.486,-27.976 62.486,-62.486l0,-224.173l80.843,80.844c24.404,24.402 63.965,24.402 88.369,-0l80.843,-80.844l0,224.173c0,34.51 27.976,62.486 62.486,62.486c34.51,-0 62.486,-27.976 62.486,-62.486l0,-375.026c0,-25.274 -15.224,-48.058 -38.573,-57.729" 3021 style="fill-rule: nonzero" 3022 ></path> 3023 </g> 3024 </svg> 3025 </div> 3026 </a> 3027 </div> 3028 </template> 3029 3030 <media-controller 3031 part="controller" 3032 defaultstreamtype="{{defaultstreamtype ?? 'on-demand'}}" 3033 breakpoints="sm:470" 3034 gesturesdisabled="{{disabled}}" 3035 hotkeys="{{hotkeys}}" 3036 nohotkeys="{{nohotkeys}}" 3037 novolumepref="{{novolumepref}}" 3038 audio="{{audio}}" 3039 noautoseektolive="{{noautoseektolive}}" 3040 defaultsubtitles="{{defaultsubtitles}}" 3041 defaultduration="{{defaultduration ?? false}}" 3042 keyboardforwardseekoffset="{{forwardseekoffset}}" 3043 keyboardbackwardseekoffset="{{backwardseekoffset}}" 3044 exportparts="layer, media-layer, poster-layer, vertical-layer, centered-layer, gesture-layer" 3045 style="--_pre-playback-place:{{preplaybackplace ?? 'center'}}" 3046 > 3047 <slot name="media" slot="media"></slot> 3048 <slot name="poster" slot="poster"></slot> 3049 3050 <media-loading-indicator slot="centered-chrome" noautohide></media-loading-indicator> 3051 3052 <template if="!audio"> 3053 <media-error-dialog slot="dialog" noautohide></media-error-dialog> 3054 <!-- Pre-playback UI --> 3055 <!-- same for both on-demand and live --> 3056 <div slot="centered-chrome" class="center-controls pre-playback"> 3057 <template if="!breakpointsm">{{>PlayButton section="center"}}</template> 3058 <template if="breakpointsm">{{>PrePlayButton section="center"}}</template> 3059 </div> 3060 3061 <!-- Mux Badge --> 3062 <template if="proudlydisplaymuxbadge"> {{>MuxBadge}} </template> 3063 3064 <!-- Autoplay centered unmute button --> 3065 <!-- 3066 todo: figure out how show this with available state variables 3067 needs to show when: 3068 - autoplay is enabled 3069 - playback has been successful 3070 - audio is muted 3071 - in place / instead of the pre-plaback play button 3072 - not to show again after user has interacted with this button 3073 - OR user has interacted with the mute button in the control bar 3074 --> 3075 <!-- 3076 There should be a >MuteButton to the left of the "Unmute" text, but a templating bug 3077 makes it appear even if commented out in the markup, add it back when code is un-commented 3078 --> 3079 <!-- <div slot="centered-chrome" class="autoplay-unmute"> 3080 <div role="button" class="autoplay-unmute-btn">Unmute</div> 3081 </div> --> 3082 3083 <template if="streamtype == 'on-demand'"> 3084 <template if="breakpointsm"> 3085 <media-control-bar part="control-bar top" slot="top-chrome">{{>TitleDisplay}} </media-control-bar> 3086 </template> 3087 {{>TimeRange}} 3088 <media-control-bar part="control-bar bottom"> 3089 {{>PlayButton}} {{>SeekBackwardButton}} {{>SeekForwardButton}} {{>TimeDisplay}} {{>MuteButton}} 3090 {{>VolumeRange}} 3091 <div class="spacer"></div> 3092 {{>RenditionMenu}} {{>PlaybackRateMenu}} {{>AudioTrackMenu}} {{>CaptionsMenu}} {{>AirplayButton}} 3093 {{>CastButton}} {{>PipButton}} {{>FullscreenButton}} 3094 </media-control-bar> 3095 </template> 3096 3097 <template if="streamtype == 'live'"> 3098 <media-control-bar part="control-bar top" slot="top-chrome"> 3099 {{>LiveButton}} 3100 <template if="breakpointsm"> {{>TitleDisplay}} </template> 3101 </media-control-bar> 3102 <template if="targetlivewindow > 0">{{>TimeRange}}</template> 3103 <media-control-bar part="control-bar bottom"> 3104 {{>PlayButton}} 3105 <template if="targetlivewindow > 0">{{>SeekBackwardButton}} {{>SeekForwardButton}}</template> 3106 {{>MuteButton}} {{>VolumeRange}} 3107 <div class="spacer"></div> 3108 {{>RenditionMenu}} {{>AudioTrackMenu}} {{>CaptionsMenu}} {{>AirplayButton}} {{>CastButton}} {{>PipButton}} 3109 {{>FullscreenButton}} 3110 </media-control-bar> 3111 </template> 3112 </template> 3113 3114 <template if="audio"> 3115 <template if="streamtype == 'on-demand'"> 3116 <template if="title"> 3117 <media-control-bar part="control-bar top">{{>TitleDisplay}}</media-control-bar> 3118 </template> 3119 <media-control-bar part="control-bar bottom"> 3120 {{>PlayButton}} 3121 <template if="breakpointsm"> {{>SeekBackwardButton}} {{>SeekForwardButton}} </template> 3122 {{>MuteButton}} 3123 <template if="breakpointsm">{{>VolumeRange}}</template> 3124 {{>TimeDisplay}} {{>TimeRange}} 3125 <template if="breakpointsm">{{>PlaybackRateMenu}}</template> 3126 {{>AirplayButton}} {{>CastButton}} 3127 </media-control-bar> 3128 </template> 3129 3130 <template if="streamtype == 'live'"> 3131 <template if="title"> 3132 <media-control-bar part="control-bar top">{{>TitleDisplay}}</media-control-bar> 3133 </template> 3134 <media-control-bar part="control-bar bottom"> 3135 {{>PlayButton}} {{>LiveButton section="bottom"}} {{>MuteButton}} 3136 <template if="breakpointsm"> 3137 {{>VolumeRange}} 3138 <template if="targetlivewindow > 0"> {{>SeekBackwardButton}} {{>SeekForwardButton}} </template> 3139 </template> 3140 <template if="targetlivewindow > 0"> {{>TimeDisplay}} {{>TimeRange}} </template> 3141 <template if="!targetlivewindow"><div class="spacer"></div></template> 3142 {{>AirplayButton}} {{>CastButton}} 3143 </media-control-bar> 3144 </template> 3145 </template> 3146 3147 <slot></slot> 3148 </media-controller> 3149</template> 3150`
3150,uJ=us.createElement("template");"innerHTML"in uJ&&(uJ.innerHTML=uQ);var u0,u1,u2=class extends nN.E${};u2.template=null==(u1=null==(u0=uJ.content)?void 0:u0.children)?void 0:u1[0],un.customElements.get("media-theme-gerwig")||un.customElements.define("media-theme-gerwig",u2);var u3={SRC:"src",POSTER:"poster"},u4={STYLE:"style",DEFAULT_HIDDEN_CAPTIONS:"default-hidden-captions",PRIMARY_COLOR:"primary-color",SECONDARY_COLOR:"secondary-color",ACCENT_COLOR:"accent-color",FORWARD_SEEK_OFFSET:"forward-seek-offset",BACKWARD_SEEK_OFFSET:"backward-seek-offset",PLAYBACK_TOKEN:"playback-token",THUMBNAIL_TOKEN:"thumbnail-token",STORYBOARD_TOKEN:"storyboard-token",FULLSCREEN_ELEMENT:"fullscreen-element",DRM_TOKEN:"drm-token",STORYBOARD_SRC:"storyboard-src",THUMBNAIL_TIME:"thumbnail-time",AUDIO:"audio",NOHOTKEYS:"nohotkeys",HOTKEYS:"hotkeys",PLAYBACK_RATES:"playbackrates",DEFAULT_SHOW_REMAINING_TIME:"default-show-remaining-time",DEFAULT_DURATION:"default-duration",TITLE:"title",VIDEO_TITLE:"video-title",PLACEHOLDER:"placeholder",THEME:"theme",DEFAULT_STREAM_TYPE:"default-stream-type",TARGET_LIVE_WINDOW:"target-live-window",EXTRA_SOURCE_PARAMS:"extra-source-params",NO_VOLUME_PREF:"no-volume-pref",NO_MUTED_PREF:"no-muted-pref",CAST_RECEIVER:"cast-receiver",NO_TOOLTIPS:"no-tooltips",PROUDLY_DISPLAY_MUX_BADGE:"proudly-display-mux-badge",DISABLE_PSEUDO_ENDED:"disable-pseudo-ended"},u5=["audio","backwardseekoffset","defaultduration","defaultshowremainingtime","defaultsubtitles","noautoseektolive","disabled","exportparts","forwardseekoffset","hideduration","hotkeys","nohotkeys","playbackrates","defaultstreamtype","streamtype","style","targetlivewindow","template","title","videotitle","novolumepref","nomutedpref","proudlydisplaymuxbadge"],u9=aQ.formatErrorMessage;function u8(e){let t=e.videoTitle?{video_title:e.videoTitle}:{};return e.getAttributeNames().filter(e=>e.startsWith("metadata-")).reduce((t,i)=>{let a=e.getAttribute(i);return null!==a&&(t[i.replace(/^metadata-/,"").replace(/-/g,"_")]=a),t},t)}aQ.formatErrorMessage=e=>{var t,i;if(e instanceof c){let a=uZ(e,!1);return` 3151 ${null!=a&&a.title?`<h3>${a.title}</h3>`:""} 3152 ${null!=a&&a.message||null!=a&&a.linkUrl?`<p> 3153 ${null==a?void 0:a.message} 3154 ${null!=a&&a.linkUrl?`<a 3155 href="${a.linkUrl}" 3156 target="_blank" 3157 rel="external noopener" 3158 aria-label="${null!=(t=a.linkText)?t:""} ${W("(opens in a new window)")}" 3159 >${null!=(i=a.linkText)?i:a.linkUrl}</a 3160 >`:""} 3161 </p>`:""} 3162 `}return u9(e)};var u6,u7,ce,ct,ci,ca,cr,cn,cs,co,cl,cd,cu,cc,ch,cm,cp,cb,cv,cE,cg,cf=Object.values(tZ),cA=Object.values(u3),cy=Object.values(u4),cT="mux-player",ck={isDialogOpen:!1},cM={redundant_streams:!0},cI=class extends uL{constructor(){super(),sG(this,cu),sG(this,u6),sG(this,u7,!1),sG(this,ce,{}),sG(this,ct,!0),sG(this,ci,new uy(this,"hotkeys")),sG(this,ca),sG(this,cr,()=>sZ(this,cu,cp).call(this)),sG(this,cn,()=>sZ(this,cu,cp).call(this)),sG(this,cs,()=>sZ(this,cu,cp).call(this)),sG(this,co),sG(this,cl,{...ck,onCloseErrorDialog:e=>{var t;(null==(t=e.composedPath()[0])?void 0:t.localName)==="media-error-dialog"&&sZ(this,cu,cm).call(this,{isDialogOpen:!1})},onFocusInErrorDialog:e=>{var t;(null==(t=e.composedPath()[0])?void 0:t.localName)==="media-error-dialog"&&(up(this,us.activeElement)||e.preventDefault())}}),sG(this,cd,e=>{var t;let i=null==(t=this.media)?void 0:t.error;if(!(i instanceof c)){let{message:e,code:t}=null!=i?i:{};i=new c(e,t)}if(!(null!=i&&i.fatal)){uk(i),i.data&&uk(`${i.name} data:`,i.data);return}let a=uX(i,!1);a.message&&uI(a),uM(i),i.data&&uM(`${i.name} data:`,i.data),sZ(this,cu,cm).call(this,{isDialogOpen:!0})}),sj(this,u6,eY()),this.attachShadow({mode:"open"}),sZ(this,cu,ch).call(this),this.isConnected&&sZ(this,cu,cc).call(this)}static get NAME(){return cT}static get VERSION(){return uv}static get observedAttributes(){var e;return[...null!=(e=uL.observedAttributes)?e:[],...cA,...cf,...cy]}get mediaTheme(){var e;return null==(e=this.shadowRoot)?void 0:e.querySelector("media-theme")}get mediaController(){var e,t;return null==(t=null==(e=this.mediaTheme)?void 0:e.shadowRoot)?void 0:t.querySelector("media-controller")}connectedCallback(){sZ(this,cu,cc).call(this);let e=this.media;e&&(e.metadata=u8(this))}disconnectedCallback(){var e,t,i,a,r,n,s,o;null==(e=sq(this,ca))||e.disconnect(),null==(t=this.media)||t.removeEventListener("streamtypechange",sq(this,cr)),null==(i=this.media)||i.removeEventListener("loadstart",sq(this,cn)),this.removeEventListener("error",sq(this,cd)),this.media&&(this.media.errorTranslator=void 0),null==(r=null==(a=this.media)?void 0:a.textTracks)||r.removeEventListener("addtrack",sq(this,cs)),null==(s=null==(n=this.media)?void 0:n.textTracks)||s.removeEventListener("removetrack",sq(this,cs)),null==(o=sq(this,co))||o.call(this),sj(this,co,void 0),sj(this,u7,!1)}attributeChangedCallback(e,t,i){var a;switch(sZ(this,cu,cc).call(this),super.attributeChangedCallback(e,t,i),e){case u4.HOTKEYS:sq(this,ci).value=i;break;case u4.THUMBNAIL_TIME:null!=i&&this.tokens.thumbnail&&uk(W("Use of thumbnail-time with thumbnail-token is currently unsupported. Ignore thumbnail-time.").toString());break;case u4.THUMBNAIL_TOKEN:if(i){let e=x(i);if(e){let{aud:t}=e,i=ed.THUMBNAIL;t!==i&&uk(W("The {tokenNamePrefix}-token has an incorrect aud value: {aud}. aud value should be {expectedAud}.").format({aud:t,expectedAud:i,tokenNamePrefix:"thumbnail"}))}}break;case u4.STORYBOARD_TOKEN:if(i){let e=x(i);if(e){let{aud:t}=e,i=ed.STORYBOARD;t!==i&&uk(W("The {tokenNamePrefix}-token has an incorrect aud value: {aud}. aud value should be {expectedAud}.").format({aud:t,expectedAud:i,tokenNamePrefix:"storyboard"}))}}break;case u4.DRM_TOKEN:if(i){let e=x(i);if(e){let{aud:t}=e,i=ed.DRM;t!==i&&uk(W("The {tokenNamePrefix}-token has an incorrect aud value: {aud}. aud value should be {expectedAud}.").format({aud:t,expectedAud:i,tokenNamePrefix:"drm"}))}}break;case tZ.PLAYBACK_ID:null!=i&&i.includes("?token")&&uM(W("The specificed playback ID {playbackId} contains a token which must be provided via the playback-token attribute.").format({playbackId:i}));break;case tZ.STREAM_TYPE:i&&![b.LIVE,b.ON_DEMAND,b.UNKNOWN].includes(i)?["ll-live","live:dvr","ll-live:dvr"].includes(this.streamType)?this.targetLiveWindow=i.includes("dvr")?Number.POSITIVE_INFINITY:0:uI({file:"invalid-stream-type.md",message:W("Invalid stream-type value supplied: `{streamType}`. Please provide stream-type as either: `on-demand` or `live`").format({streamType:this.streamType})}):i===b.LIVE?null==this.getAttribute(u4.TARGET_LIVE_WINDOW)&&(this.targetLiveWindow=0):this.targetLiveWindow=Number.NaN;break;case u4.FULLSCREEN_ELEMENT:if(null!=i||i!==t){let e=us.getElementById(i),t=null==e?void 0:e.querySelector("mux-player");this.mediaController&&e&&t&&(this.mediaController.fullscreenElement=e)}break;case tZ.CAP_RENDITION_TO_PLAYER_SIZE:(null==i||i!==t)&&(this.capRenditionToPlayerSize=null!=i||void 0)}[tZ.PLAYBACK_ID,u3.SRC,u4.PLAYBACK_TOKEN].includes(e)&&t!==i&&sj(this,cl,{...sq(this,cl),...ck}
3162),sZ(this,cu,cp).call(this,{[null!=(a=uA[e])?a:ul(e)]:i})}async requestFullscreen(e){var t;if(!(!this.mediaController||this.mediaController.hasAttribute(iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN)))return null==(t=this.mediaController)||t.dispatchEvent(new un.CustomEvent(iq.MediaUIEvents.MEDIA_ENTER_FULLSCREEN_REQUEST,{composed:!0,bubbles:!0})),new Promise((e,t)=>{var i;null==(i=this.mediaController)||i.addEventListener(iq.TP.MEDIA_IS_FULLSCREEN,()=>e(),{once:!0})})}async exitFullscreen(){var e;if(!(!this.mediaController||!this.mediaController.hasAttribute(iq.MediaUIAttributes.MEDIA_IS_FULLSCREEN)))return null==(e=this.mediaController)||e.dispatchEvent(new un.CustomEvent(iq.MediaUIEvents.MEDIA_EXIT_FULLSCREEN_REQUEST,{composed:!0,bubbles:!0})),new Promise((e,t)=>{var i;null==(i=this.mediaController)||i.addEventListener(iq.TP.MEDIA_IS_FULLSCREEN,()=>e(),{once:!0})})}get preferCmcd(){var e;return null!=(e=this.getAttribute(tZ.PREFER_CMCD))?e:void 0}set preferCmcd(e){e!==this.preferCmcd&&(e?g.includes(e)?this.setAttribute(tZ.PREFER_CMCD,e):uk(`Invalid value for preferCmcd. Must be one of ${g.join()}`):this.removeAttribute(tZ.PREFER_CMCD))}get hasPlayed(){var e,t;return null!=(t=null==(e=this.mediaController)?void 0:e.hasAttribute(iq.MediaUIAttributes.MEDIA_HAS_PLAYED))&&t}get inLiveWindow(){var e;return null==(e=this.mediaController)?void 0:e.hasAttribute(iq.MediaUIAttributes.MEDIA_TIME_IS_LIVE)}get _hls(){var e;return null==(e=this.media)?void 0:e._hls}get mux(){var e;return null==(e=this.media)?void 0:e.mux}get theme(){var e;return null!=(e=this.getAttribute(u4.THEME))?e:"gerwig"}set theme(e){this.setAttribute(u4.THEME,`${e}`)}get themeProps(){let e=this.mediaTheme;if(!e)return;let t={};for(let i of e.getAttributeNames()){if(u5.includes(i))continue;let a=e.getAttribute(i);t[ul(i)]=""===a||a}return t}set themeProps(e){var t,i;sZ(this,cu,cc).call(this);let a={...this.themeProps,...e};for(let r in a){if(u5.includes(r))continue;let a=null==e?void 0:e[r];"boolean"==typeof a||null==a?null==(t=this.mediaTheme)||t.toggleAttribute(uo(r),!!a):null==(i=this.mediaTheme)||i.setAttribute(uo(r),a)}}get playbackId(){var e;return null!=(e=this.getAttribute(tZ.PLAYBACK_ID))?e:void 0}set playbackId(e){e?this.setAttribute(tZ.PLAYBACK_ID,e):this.removeAttribute(tZ.PLAYBACK_ID)}get src(){var e,t;return this.playbackId?null!=(e=c_(this,u3.SRC))?e:void 0:null!=(t=this.getAttribute(u3.SRC))?t:void 0}set src(e){e?this.setAttribute(u3.SRC,e):this.removeAttribute(u3.SRC)}get poster(){var e;let t=this.getAttribute(u3.POSTER);if(null!=t)return t;let{tokens:i}=this;if(i.playback&&!i.thumbnail){uk("Missing expected thumbnail token. No poster image will be shown");return}if(this.playbackId&&!this.audio)return uE(this.playbackId,{customDomain:this.customDomain,thumbnailTime:null!=(e=this.thumbnailTime)?e:this.startTime,programTime:this.programStartTime,token:i.thumbnail})}set poster(e){e||""===e?this.setAttribute(u3.POSTER,e):this.removeAttribute(u3.POSTER)}get storyboardSrc(){var e;return null!=(e=this.getAttribute(u4.STORYBOARD_SRC))?e:void 0}set storyboardSrc(e){e?this.setAttribute(u4.STORYBOARD_SRC,e):this.removeAttribute(u4.STORYBOARD_SRC)}get storyboard(){let{tokens:e}=this;return this.storyboardSrc&&!e.storyboard?this.storyboardSrc:this.audio||!this.playbackId||!this.streamType||[b.LIVE,b.UNKNOWN].includes(this.streamType)||e.playback&&!e.storyboard?void 0:ug(this.playbackId,{customDomain:this.customDomain,token:e.storyboard,programStartTime:this.programStartTime,programEndTime:this.programEndTime})}get audio(){return this.hasAttribute(u4.AUDIO)}set audio(e){if(!e){this.removeAttribute(u4.AUDIO);return}this.setAttribute(u4.AUDIO,"")}get hotkeys(){return sq(this,ci)}get nohotkeys(){return this.hasAttribute(u4.NOHOTKEYS)}set nohotkeys(e){if(!e){this.removeAttribute(u4.NOHOTKEYS);return}this.setAttribute(u4.NOHOTKEYS,"")}get thumbnailTime(){return ud(this.getAttribute(u4.THUMBNAIL_TIME))}set thumbnailTime(e){this.setAttribute(u4.THUMBNAIL_TIME,`${e}`)}get videoTitle(){var e,t;return null!=(t=null!=(e=this.getAttribute(u4.VIDEO_TITLE))?e:this.getAttribute(u4.TITLE))?t:""}set videoTitle(e){e!==this.videoTitle&&(e?this.setAttribute(u4.VIDEO_TITLE,e):this.removeAttribute(u4.VIDEO_TITLE))}get placeholder(){var e;return null!=(e=c_(this,u4.PLACEHOLDER))?e:""}set placeholder(e){this.setAttribute(u4.PLACEHOLDER,`${e}`)}get primaryColor(){var e,t;let i=this.getAttribute(u4.PRIMARY_COLOR);if(null!=i||this.mediaTheme&&(i=null==(t=null==(e=un.getComputedStyle(this.mediaTheme))?void 0:e.getPropertyValue("--_primary-color"))?void 0:t.trim()))return i}set primaryColor(e){this.setAttribute(u4.PRIMARY_COLOR,`${e}`)}get secondaryColor(){var e,t;let i=this.getAttribute(u4.SECONDARY_COLOR);if(null!=i||this.mediaTheme&&(i=null==(t=null==(e=un.getComputedStyle(this.mediaTheme))?void 0:e.getPropertyValue("--_secondary-color"))?void 0:t.trim()))return i}set secondaryColor(e){this.setAttribute(u4.SECONDARY_COLOR,`${e}`)}get accentColor(){var e,t;let i=this.getAttribute(u4.ACCENT_COLOR);if(null!=i||this.mediaTheme&&(i=null==(t=null==(e=un.getComputedStyle(this.mediaTheme))?void 0:e.getPropertyValue("--_accent-color"))?void 0:t.trim()))return i}set accentColor(e){this.setAttribute(u4.ACCENT_COLOR,`${e}`)}get defaultShowRemainingTime(){return this.hasAttribute(u4.DEFAULT_SHOW_REMAINING_TIME)}set defaultShowRemainingTime(e){e?this.setAttribute(u4.DEFAULT_SHOW_REMAINING_TIME,""):this.removeAttribute(u4.DEFAULT_SHOW_REMAINING_TIME)}get playbackRates(){if(this.hasAttribute(u4.PLAYBACK_RATES))return this.getAttribute(u4.PLAYBACK_RATES).trim().split(/\s*,?\s+/).map(e=>Number(e)).filter(e=>!Number.isNaN(e)).sort((e,t)=>
3162e-t)}set playbackRates(e){if(!e){this.removeAttribute(u4.PLAYBACK_RATES);return}this.setAttribute(u4.PLAYBACK_RATES,e.join(" "))}get forwardSeekOffset(){var e;return null!=(e=ud(this.getAttribute(u4.FORWARD_SEEK_OFFSET)))?e:10}set forwardSeekOffset(e){this.setAttribute(u4.FORWARD_SEEK_OFFSET,`${e}`)}get backwardSeekOffset(){var e;return null!=(e=ud(this.getAttribute(u4.BACKWARD_SEEK_OFFSET)))?e:10}set backwardSeekOffset(e){this.setAttribute(u4.BACKWARD_SEEK_OFFSET,`${e}`)}get defaultHiddenCaptions(){return this.hasAttribute(u4.DEFAULT_HIDDEN_CAPTIONS)}set defaultHiddenCaptions(e){e?this.setAttribute(u4.DEFAULT_HIDDEN_CAPTIONS,""):this.removeAttribute(u4.DEFAULT_HIDDEN_CAPTIONS)}get defaultDuration(){return ud(this.getAttribute(u4.DEFAULT_DURATION))}set defaultDuration(e){null==e?this.removeAttribute(u4.DEFAULT_DURATION):this.setAttribute(u4.DEFAULT_DURATION,`${e}`)}get playerInitTime(){return this.hasAttribute(tZ.PLAYER_INIT_TIME)?ud(this.getAttribute(tZ.PLAYER_INIT_TIME)):sq(this,u6)}set playerInitTime(e){e!=this.playerInitTime&&(null==e?this.removeAttribute(tZ.PLAYER_INIT_TIME):this.setAttribute(tZ.PLAYER_INIT_TIME,`${+e}`))}get playerSoftwareName(){var e;return null!=(e=this.getAttribute(tZ.PLAYER_SOFTWARE_NAME))?e:cT}get playerSoftwareVersion(){var e;return null!=(e=this.getAttribute(tZ.PLAYER_SOFTWARE_VERSION))?e:uv}get beaconCollectionDomain(){var e;return null!=(e=this.getAttribute(tZ.BEACON_COLLECTION_DOMAIN))?e:void 0}set beaconCollectionDomain(e){e!==this.beaconCollectionDomain&&(e?this.setAttribute(tZ.BEACON_COLLECTION_DOMAIN,e):this.removeAttribute(tZ.BEACON_COLLECTION_DOMAIN))}get maxResolution(){var e;return null!=(e=this.getAttribute(tZ.MAX_RESOLUTION))?e:void 0}set maxResolution(e){e!==this.maxResolution&&(e?this.setAttribute(tZ.MAX_RESOLUTION,e):this.removeAttribute(tZ.MAX_RESOLUTION))}get minResolution(){var e;return null!=(e=this.getAttribute(tZ.MIN_RESOLUTION))?e:void 0}set minResolution(e){e!==this.minResolution&&(e?this.setAttribute(tZ.MIN_RESOLUTION,e):this.removeAttribute(tZ.MIN_RESOLUTION))}get maxAutoResolution(){var e;return null!=(e=this.getAttribute(tZ.MAX_AUTO_RESOLUTION))?e:void 0}set maxAutoResolution(e){null==e?this.removeAttribute(tZ.MAX_AUTO_RESOLUTION):this.setAttribute(tZ.MAX_AUTO_RESOLUTION,e)}get renditionOrder(){var e;return null!=(e=this.getAttribute(tZ.RENDITION_ORDER))?e:void 0}set renditionOrder(e){e!==this.renditionOrder&&(e?this.setAttribute(tZ.RENDITION_ORDER,e):this.removeAttribute(tZ.RENDITION_ORDER))}get programStartTime(){return ud(this.getAttribute(tZ.PROGRAM_START_TIME))}set programStartTime(e){null==e?this.removeAttribute(tZ.PROGRAM_START_TIME):this.setAttribute(tZ.PROGRAM_START_TIME,`${e}`)}get programEndTime(){return ud(this.getAttribute(tZ.PROGRAM_END_TIME))}set programEndTime(e){null==e?this.removeAttribute(tZ.PROGRAM_END_TIME):this.setAttribute(tZ.PROGRAM_END_TIME,`${e}`)}get assetStartTime(){return ud(this.getAttribute(tZ.ASSET_START_TIME))}set assetStartTime(e){null==e?this.removeAttribute(tZ.ASSET_START_TIME):this.setAttribute(tZ.ASSET_START_TIME,`${e}`)}get assetEndTime(){return ud(this.getAttribute(tZ.ASSET_END_TIME))}set assetEndTime(e){null==e?this.removeAttribute(tZ.ASSET_END_TIME):this.setAttribute(tZ.ASSET_END_TIME,`${e}`)}get extraSourceParams(){return this.hasAttribute(u4.EXTRA_SOURCE_PARAMS)?[...new URLSearchParams(this.getAttribute(u4.EXTRA_SOURCE_PARAMS)).entries()].reduce((e,[t,i])=>(e[t]=i,e),{}):cM}set extraSourceParams(e){null==e?this.removeAttribute(u4.EXTRA_SOURCE_PARAMS):this.setAttribute(u4.EXTRA_SOURCE_PARAMS,new URLSearchParams(e).toString())}get customDomain(){var e;return null!=(e=this.getAttribute(tZ.CUSTOM_DOMAIN))?e:void 0}set customDomain(e){e!==this.customDomain&&(e?this.setAttribute(tZ.CUSTOM_DOMAIN,e):this.removeAttribute(tZ.CUSTOM_DOMAIN))}get envKey(){var e;return null!=(e=c_(this,tZ.ENV_KEY))?e:void 0}set envKey(e){this.setAttribute(tZ.ENV_KEY,`${e}`)}get noVolumePref(){return this.hasAttribute(u4.NO_VOLUME_PREF)}set noVolumePref(e){e?this.setAttribute(u4.NO_VOLUME_PREF,""):this.removeAttribute(u4.NO_VOLUME_PREF)}get noMutedPref(){return this.hasAttribute(u4.NO_MUTED_PREF)}set noMutedPref(e){e?this.setAttribute(u4.NO_MUTED_PREF,""):this.removeAttribute(u4.NO_MUTED_PREF)}get debug(){return null!=c_(this,tZ.DEBUG)}set debug(e){e?this.setAttribute(tZ.DEBUG,""):this.removeAttribute(tZ.DEBUG)}get disableTracking(){return null!=c_(this,tZ.DISABLE_TRACKING)}set disableTracking(e){this.toggleAttribute(tZ.DISABLE_TRACKING,!!e)}get disableCookies(){return null!=c_(this,tZ.DISABLE_COOKIES)}set disableCookies(e){e?this.setAttribute(tZ.DISABLE_COOKIES,""):this.removeAttribute(tZ.DISABLE_COOKIES)}get streamType(){var e,t,i;return null!=(i=null!=(t=this.getAttribute(tZ.STREAM_TYPE))?t:null==(e=this.media)?void 0:e.streamType)?i:b.UNKNOWN}set streamType(e){this.setAttribute(tZ.STREAM_TYPE,`${e}`)}get defaultStreamType(){var e,t,i;return null!=(i=null!=(t=this.getAttribute(u4.DEFAULT_STREAM_TYPE))?t:null==(e=this.mediaController)?void 0:e.getAttribute(u4.DEFAULT_STREAM_TYPE))?i:b.ON_DEMAND}set defaultStreamType(e){e?this.setAttribute(u4.DEFAULT_STREAM_TYPE,e):this.removeAttribute(u4.DEFAULT_STREAM_TYPE)}get targetLiveWindow(){var e,t;return this.hasAttribute(u4.TARGET_LIVE_WINDOW)?+this.getAttribute(u4.TARGET_LIVE_WINDOW):null!=(t=null==(e=this.media)?void 0:e.targetLiveWindow)?t:Number.NaN}set targetLiveWindow(e){e==this.targetLiveWindow||Number.isNaN(e)&&Number.isNaN(this.targetLiveWindow)||(null==e?this.removeAttribute(u4.TARGET_LIVE_WINDOW):this.setAttribute(u4.TARGET_LIVE_WINDOW,`${+e}`))}get liveEdgeStart(){var e;return null==(e=this.media)?void 0:e.liveEdgeStart}get startTime(){return ud(c_(this,tZ.START_TIME))}set startTime(e){this.setAttribute(tZ.START_TIME,`${e}`)}get initialBandwidthEstimateKbps(){return ud(c_(this,tZ.INITIAL_BANDWIDTH_ESTIMATE_KBPS))}set initialBandwidthEstimateKbps(e){null==e?this.removeAttribute(tZ.INITIAL_BANDWIDTH_ESTIMATE_KBPS):this.setAttribute(tZ.INITIAL_BANDWIDTH_ESTIMATE_KBPS,`${e}`)}get initialEstimateSegments(){return ud(c_(this,tZ.INITIAL_ESTIMATE_SEGMENTS))}set initialEstimateSegments(e){null==e?this.removeAttribute(tZ.INITIAL_ESTIMATE_SEGMENTS):this.setAttribute(tZ.INITIAL_ESTIMATE_SEGMENTS,`${e}`)}get minPreloadSegments(){return ud(c_(this,tZ.MIN_PRELOAD_SEGMENTS))}set minPreloadSegments(e){null==e?this.removeAttribute(tZ.MIN_PRELOAD_SEGMENTS):this.setAttribute(tZ.MIN_PRELOAD_SEGMENTS,`${e}`)}get preferPlayback(){let e=this.getAttribute(tZ.PREFER_PLAYBACK);if(e===v.MSE||e===v.NATIVE)return e}set preferPlayback(e){e!==this.preferPlayback&&(e===v.MSE||e===v.NATIVE?this.setAttribute(tZ.PREFER_PLAYBACK,e):this.removeAttribute(tZ.PREFER_PLAYBACK))}get metadata(){var e;return null==(e=this.media)?void 0:e.metadata}set metadata(e){if(sZ(this,cu,cc).call(this),!this.media){uM("underlying media element missing when trying to set metadata. metadata will not be set.");return}this.media.metadata={...u8(this),...e}}
3162get _hlsConfig(){var e;return null==(e=this.media)?void 0:e._hlsConfig}set _hlsConfig(e){if(sZ(this,cu,cc).call(this),!this.media){uM("underlying media element missing when trying to set _hlsConfig. _hlsConfig will not be set.");return}this.media._hlsConfig=e}async addCuePoints(e){var t;if(sZ(this,cu,cc).call(this),!this.media){uM("underlying media element missing when trying to addCuePoints. cuePoints will not be added.");return}return null==(t=this.media)?void 0:t.addCuePoints(e)}get activeCuePoint(){var e;return null==(e=this.media)?void 0:e.activeCuePoint}get cuePoints(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.cuePoints)?t:[]}addChapters(e){var t;if(sZ(this,cu,cc).call(this),!this.media){uM("underlying media element missing when trying to addChapters. chapters will not be added.");return}return null==(t=this.media)?void 0:t.addChapters(e)}get activeChapter(){var e;return null==(e=this.media)?void 0:e.activeChapter}get chapters(){var e,t;return null!=(t=null==(e=this.media)?void 0:e.chapters)?t:[]}getStartDate(){var e;return null==(e=this.media)?void 0:e.getStartDate()}get currentPdt(){var e;return null==(e=this.media)?void 0:e.currentPdt}get tokens(){let e=this.getAttribute(u4.PLAYBACK_TOKEN),t=this.getAttribute(u4.DRM_TOKEN),i=this.getAttribute(u4.THUMBNAIL_TOKEN),a=this.getAttribute(u4.STORYBOARD_TOKEN);return{...sq(this,ce),...null!=e?{playback:e}:{},...null!=t?{drm:t}:{},...null!=i?{thumbnail:i}:{},...null!=a?{storyboard:a}:{}}}set tokens(e){sj(this,ce,null!=e?e:{})}get playbackToken(){var e;return null!=(e=this.getAttribute(u4.PLAYBACK_TOKEN))?e:void 0}set playbackToken(e){this.setAttribute(u4.PLAYBACK_TOKEN,`${e}`)}get drmToken(){var e;return null!=(e=this.getAttribute(u4.DRM_TOKEN))?e:void 0}set drmToken(e){this.setAttribute(u4.DRM_TOKEN,`${e}`)}get thumbnailToken(){var e;return null!=(e=this.getAttribute(u4.THUMBNAIL_TOKEN))?e:void 0}set thumbnailToken(e){this.setAttribute(u4.THUMBNAIL_TOKEN,`${e}`)}get storyboardToken(){var e;return null!=(e=this.getAttribute(u4.STORYBOARD_TOKEN))?e:void 0}set storyboardToken(e){this.setAttribute(u4.STORYBOARD_TOKEN,`${e}`)}addTextTrack(e,t,i,a){var r;let n=null==(r=this.media)?void 0:r.nativeEl;if(n)return j(n,e,t,i,a)}removeTextTrack(e){var t;let i=null==(t=this.media)?void 0:t.nativeEl;if(i){let t;return void(null==(t=Array.prototype.find.call(i.querySelectorAll("track"),t=>t.track===e))||t.remove())}}get textTracks(){var e;return null==(e=this.media)?void 0:e.textTracks}get castReceiver(){var e;return null!=(e=this.getAttribute(u4.CAST_RECEIVER))?e:void 0}set castReceiver(e){e!==this.castReceiver&&(e?this.setAttribute(u4.CAST_RECEIVER,e):this.removeAttribute(u4.CAST_RECEIVER))}get castCustomData(){var e;return null==(e=this.media)?void 0:e.castCustomData}set castCustomData(e){if(!this.media){uM("underlying media element missing when trying to set castCustomData. castCustomData will not be set.");return}this.media.castCustomData=e}get noTooltips(){return this.hasAttribute(u4.NO_TOOLTIPS)}set noTooltips(e){if(!e){this.removeAttribute(u4.NO_TOOLTIPS);return}this.setAttribute(u4.NO_TOOLTIPS,"")}get proudlyDisplayMuxBadge(){return this.hasAttribute(u4.PROUDLY_DISPLAY_MUX_BADGE)}set proudlyDisplayMuxBadge(e){e?this.setAttribute(u4.PROUDLY_DISPLAY_MUX_BADGE,""):this.removeAttribute(u4.PROUDLY_DISPLAY_MUX_BADGE)}get capRenditionToPlayerSize(){var e;return null==(e=this.media)?void 0:e.capRenditionToPlayerSize}set capRenditionToPlayerSize(e){if(!this.media){uM("underlying media element missing when trying to set capRenditionToPlayerSize");return}this.media.capRenditionToPlayerSize=e}};function c_(e,t){return e.media?e.media.getAttribute(t):e.getAttribute(t)}u6=new WeakMap,u7=new WeakMap,ce=new WeakMap,ct=new WeakMap,ci=new WeakMap,ca=new WeakMap,cr=new WeakMap,cn=new WeakMap,cs=new WeakMap,co=new WeakMap,cl=new WeakMap,cd=new WeakMap,cu=new WeakSet,cc=function(){var e,t,i,a;if(!sq(this,u7)){sj(this,u7,!0),sZ(this,cu,cp).call(this);try{if(customElements.upgrade(this.mediaTheme),!(this.mediaTheme instanceof un.HTMLElement))throw""}catch{uM("<media-theme> failed to upgrade!")}try{customElements.upgrade(this.media)}catch{uM("underlying media element failed to upgrade!")}
3162try{if(customElements.upgrade(this.mediaController),!(this.mediaController instanceof iJ.ZP))throw""}catch{uM("<media-controller> failed to upgrade!")}sZ(this,cu,cb).call(this),sZ(this,cu,cv).call(this),sZ(this,cu,cE).call(this),sj(this,ct,null==(t=null==(e=this.mediaController)?void 0:e.hasAttribute(nD.zj.USER_INACTIVE))||t),sZ(this,cu,cg).call(this),null==(i=this.media)||i.addEventListener("streamtypechange",sq(this,cr)),null==(a=this.media)||a.addEventListener("loadstart",sq(this,cn))}},ch=function(){var e,t;try{null==(e=null==window?void 0:window.CSS)||e.registerProperty({name:"--media-primary-color",syntax:"<color>",inherits:!0}),null==(t=null==window?void 0:window.CSS)||t.registerProperty({name:"--media-secondary-color",syntax:"<color>",inherits:!0})}catch{}},cm=function(e){Object.assign(sq(this,cl),e),sZ(this,cu,cp).call(this)},cp=function(e={}){var t,i,a,r,n;let s;(function(e,t){e.renderInto(t)})(uV((t={...sq(this,cl),...e},{src:!this.playbackId&&this.src,playbackId:this.playbackId,hasSrc:!!this.playbackId||!!this.src||!!this.currentSrc,poster:this.poster,storyboard:(null==(i=this.media)?void 0:i.currentSrc)&&this.storyboard,storyboardSrc:this.getAttribute(u4.STORYBOARD_SRC),fullscreenElement:this.getAttribute(u4.FULLSCREEN_ELEMENT),placeholder:this.getAttribute("placeholder"),themeTemplate:function(e){var t,i;let a=e.theme;if(a){let r=null==(i=null==(t=e.getRootNode())?void 0:t.getElementById)?void 0:i.call(t,a);if(r&&r instanceof HTMLTemplateElement)return r;a.startsWith("media-theme-")||(a=`media-theme-${a}`);let n=un.customElements.get(a);if(null!=n&&n.template)return n.template}}(this),thumbnailTime:!this.tokens.thumbnail&&this.thumbnailTime,autoplay:this.autoplay,crossOrigin:this.crossOrigin,loop:this.loop,noHotKeys:this.hasAttribute(u4.NOHOTKEYS),hotKeys:this.getAttribute(u4.HOTKEYS),muted:this.muted,paused:this.paused,preload:this.preload,envKey:this.envKey,preferCmcd:this.preferCmcd,debug:this.debug,disableTracking:this.disableTracking,disableCookies:this.disableCookies,tokens:this.tokens,beaconCollectionDomain:this.beaconCollectionDomain,maxResolution:this.maxResolution,minResolution:this.minResolution,maxAutoResolution:this.maxAutoResolution,programStartTime:this.programStartTime,programEndTime:this.programEndTime,assetStartTime:this.assetStartTime,assetEndTime:this.assetEndTime,renditionOrder:this.renditionOrder,metadata:this.metadata,playerInitTime:this.playerInitTime,playerSoftwareName:this.playerSoftwareName,playerSoftwareVersion:this.playerSoftwareVersion,startTime:this.startTime,initialBandwidthEstimateKbps:this.initialBandwidthEstimateKbps,initialEstimateSegments:this.initialEstimateSegments,minPreloadSegments:this.minPreloadSegments,preferPlayback:this.preferPlayback,audio:this.audio,defaultStreamType:this.defaultStreamType,targetLiveWindow:this.getAttribute(tZ.TARGET_LIVE_WINDOW),streamType:uf(this.getAttribute(tZ.STREAM_TYPE)),primaryColor:this.getAttribute(u4.PRIMARY_COLOR),secondaryColor:this.getAttribute(u4.SECONDARY_COLOR),accentColor:this.getAttribute(u4.ACCENT_COLOR),forwardSeekOffset:this.forwardSeekOffset,backwardSeekOffset:this.backwardSeekOffset,defaultHiddenCaptions:this.defaultHiddenCaptions,defaultDuration:this.defaultDuration,defaultShowRemainingTime:this.defaultShowRemainingTime,hideDuration:(s=null==(n=this.mediaController)?void 0:n.querySelector("media-time-display"))&&"none"===getComputedStyle(s).getPropertyValue("--media-duration-display-display").trim(),playbackRates:this.getAttribute(u4.PLAYBACK_RATES),customDomain:null!=(a=this.getAttribute(tZ.CUSTOM_DOMAIN))?a:void 0,title:this.getAttribute(u4.TITLE),videoTitle:null!=(r=this.getAttribute(u4.VIDEO_TITLE))?r:this.getAttribute(u4.TITLE),novolumepref:this.hasAttribute(u4.NO_VOLUME_PREF),nomutedpref:this.hasAttribute(u4.NO_MUTED_PREF),proudlyDisplayMuxBadge:this.hasAttribute(u4.PROUDLY_DISPLAY_MUX_BADGE),castReceiver:this.castReceiver,disablePseudoEnded:this.hasAttribute(u4.DISABLE_PSEUDO_ENDED),capRenditionToPlayerSize:this.capRenditionToPlayerSize,...t,extraSourceParams:this.extraSourceParams})),this.shadowRoot)},cb=function(){let e=e=>{var t,i;if(!(null!=e&&e.startsWith("theme-")))return;let a=e.replace(/^theme-/,"");if(u5.includes(a))return;let r=this.getAttribute(e);null!=r?null==(t=this.mediaTheme)||t.setAttribute(a,r):null==(i=this.mediaTheme)||i.removeAttribute(a)};sj(this,ca,new MutationObserver(t=>{for(let{attributeName:i}of t)e(i)})),sq(this,ca).observe(this,{attributes:!0}
3162),this.getAttributeNames().forEach(e)},cv=function(){this.addEventListener("error",sq(this,cd)),this.media&&(this.media.errorTranslator=(e={})=>{var t,i,a;if(!((null==(t=this.media)?void 0:t.error)instanceof c))return e;let r=uX(null==(i=this.media)?void 0:i.error,!1);return{player_error_code:null==(a=this.media)?void 0:a.error.code,player_error_message:r.message?String(r.message):e.player_error_message,player_error_context:r.context?String(r.context):e.player_error_context}})},cE=function(){var e,t,i,a;null==(t=null==(e=this.media)?void 0:e.textTracks)||t.addEventListener("addtrack",sq(this,cs)),null==(a=null==(i=this.media)?void 0:i.textTracks)||a.addEventListener("removetrack",sq(this,cs))},cg=function(){var e,t;if(!/Firefox/i.test(navigator.userAgent))return;let i,a=new WeakMap,r=()=>this.streamType===b.LIVE&&!this.secondaryColor&&this.offsetWidth>=800,n=(e,t,i=!1)=>{r()||Array.from(e&&e.activeCues||[]).forEach(e=>{if(!(!e.snapToLines||e.line<-5||e.line>=0&&e.line<10)){if(!t||this.paused){let t=e.text.split(` 3163`).length,r=-3;this.streamType===b.LIVE&&(r=-2);let n=r-t;(e.line!==n||i)&&(a.has(e)||a.set(e,e.line),e.line=n)}else setTimeout(()=>{e.line=a.get(e)||"auto"},500)}})},s=()=>{var e,t;n(i,null!=(t=null==(e=this.mediaController)?void 0:e.hasAttribute(nD.zj.USER_INACTIVE))&&t)},o=()=>{var e,t;let a=Array.from((null==(t=null==(e=this.mediaController)?void 0:e.media)?void 0:t.textTracks)||[]).filter(e=>["subtitles","captions"].includes(e.kind)&&"showing"===e.mode)[0];a!==i&&(null==i||i.removeEventListener("cuechange",s)),null==(i=a)||i.addEventListener("cuechange",s),n(i,sq(this,ct))};o(),null==(e=this.textTracks)||e.addEventListener("change",o),null==(t=this.textTracks)||t.addEventListener("addtrack",o);let l=()=>{var e,t;let a=null==(t=null==(e=this.mediaController)?void 0:e.hasAttribute(nD.zj.USER_INACTIVE))||t;sq(this,ct)!==a&&(sj(this,ct,a),n(i,sq(this,ct)))};this.addEventListener("userinactivechange",l),sj(this,co,()=>{var e,t;null==i||i.removeEventListener("cuechange",s),null==(e=this.textTracks)||e.removeEventListener("change",o),null==(t=this.textTracks)||t.removeEventListener("addtrack",o),this.removeEventListener("userinactivechange",l)})};var cw=e=>{throw TypeError(e)},cC=(e,t,i)=>t.has(e)||cw("Cannot "+i),cR=(e,t,i)=>(cC(e,t,"read from private field"),i?i.call(e):t.get(e)),cS=(e,t,i)=>t.has(e)?cw("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,i),cL=(e,t,i,a)=>(cC(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),cD=class{addEventListener(){}removeEventListener(){}dispatchEvent(e){return!0}};if("undefined"==typeof DocumentFragment){class e extends cD{}globalThis.DocumentFragment=e}var cx,cN=class extends cD{},cO=class{constructor(e,t={}){cS(this,cx),cL(this,cx,null==t?void 0:t.detail)}get detail(){return cR(this,cx)}initCustomEvent(){}};cx=new WeakMap;var cP={document:{createElement:function(e,t){return new cN}},DocumentFragment,customElements:{get(e){},define(e,t,i){},getName:e=>null,upgrade(e){},whenDefined:e=>Promise.resolve(cN)},CustomEvent:cO,EventTarget:cD,HTMLElement:cN,HTMLVideoElement:class extends cD{}},cU="undefined"==typeof window||void 0===globalThis.customElements,cW=cU?cP:globalThis;cU&&cP.document,cW.customElements.get("mux-player")||(cW.customElements.define("mux-player",cI),cW.MuxPlayerElement=cI);var c$=parseInt(r.version)>=19,cB={className:"class",classname:"class",htmlFor:"for",crossOrigin:"crossorigin",viewBox:"viewBox",playsInline:"playsinline",autoPlay:"autoplay",playbackRate:"playbackrate"},cH=e=>null==e,cV=(e,t)=>!cH(t)&&e in t,cK=e=>e.replace(/[A-Z]/g,e=>"-".concat(e.toLowerCase())),cF=(e,t)=>{if(!(!c$&&"boolean"==typeof t&&!t)){if(cV(e,cB))return cB[e];if(void 0!==t)return/[A-Z]/.test(e)?cK(e):e}},cY=(e,t)=>c$||"boolean"!=typeof e?e:"",cq=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{ref:t,...i}=e;return Object.entries(i).reduce((e,t)=>{let[i,a]=t,r=cF(i,a);if(!r)return e;let n=cY(a,i);return e[r]=n,e},{})};function cG(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}var cj=Object.prototype.hasOwnProperty,cZ=(e,t)=>{if(Object.is(e,t))return!0;
3163if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;if(Array.isArray(e))return!!Array.isArray(t)&&e.length===t.length&&e.some((e,i)=>t[i]===e);let i=Object.keys(e),a=Object.keys(t);if(i.length!==a.length)return!1;for(let a=0;a<i.length;a++)if(!cj.call(t,i[a])||!Object.is(e[i[a]],t[i[a]]))return!1;return!0},cz=(e,t,i)=>!cZ(t,e[i]),cX=(e,t,i)=>{e[i]=t},cQ=function(e,t,i){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:cX,n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:cz;return(0,r.useEffect)(()=>{let r=null==i?void 0:i.current;r&&n(r,t,e)&&a(r,t,e)},[null==i?void 0:i.current,t])},cJ=(()=>{try{return"3.13.0"}catch(e){}return"UNKNOWN"})(),c0=(e,t,i)=>(0,r.useEffect)(()=>{let a=null==t?void 0:t.current;if(a&&i)return a.addEventListener(e,i),()=>{a.removeEventListener(e,i)}},[null==t?void 0:t.current,i,e]),c1=r.forwardRef((e,t)=>{let{children:i,...a}=e;return r.createElement("mux-player",{suppressHydrationWarning:!0,...cq(a),ref:t},i)}),c2=(e,t)=>{let{onAbort:i,onCanPlay:a,onCanPlayThrough:r,onEmptied:n,onLoadStart:s,onLoadedData:o,onLoadedMetadata:l,onProgress:d,onDurationChange:u,onVolumeChange:c,onRateChange:h,onResize:m,onWaiting:p,onPlay:b,onPlaying:v,onTimeUpdate:E,onPause:g,onSeeking:f,onSeeked:A,onStalled:y,onSuspend:T,onEnded:k,onError:M,onCuePointChange:I,onChapterChange:_,metadata:w,tokens:C,paused:R,playbackId:S,playbackRates:L,currentTime:D,themeProps:x,extraSourceParams:N,castCustomData:O,_hlsConfig:P,...U}=t;return cQ("tokens",C,e),cQ("playbackId",S,e),cQ("playbackRates",L,e),cQ("metadata",w,e),cQ("extraSourceParams",N,e),cQ("_hlsConfig",P,e),cQ("themeProps",x,e),cQ("castCustomData",O,e),cQ("paused",R,e,(e,t)=>{null!=t&&(t?e.pause():e.play())},(e,t,i)=>(!e.hasAttribute("autoplay")||!!e.hasPlayed)&&cz(e,t,i)),cQ("currentTime",D,e,(e,t)=>{null!=t&&(e.currentTime=t)}),c0("abort",e,i),c0("canplay",e,a),c0("canplaythrough",e,r),c0("emptied",e,n),c0("loadstart",e,s),c0("loadeddata",e,o),c0("loadedmetadata",e,l),c0("progress",e,d),c0("durationchange",e,u),c0("volumechange",e,c),c0("ratechange",e,h),c0("resize",e,m),c0("waiting",e,p),c0("play",e,b),c0("playing",e,v),c0("timeupdate",e,E),c0("pause",e,g),c0("seeking",e,f),c0("seeked",e,A),c0("stalled",e,y),c0("suspend",e,T),c0("ended",e,k),c0("error",e,M),c0("cuepointchange",e,I),c0("chapterchange",e,_),[U]},c3=r.forwardRef((e,t)=>{var i;let a=(0,r.useRef)(null),n=function(){for(var e=arguments.length,t=Array(e),i=0;i<e;i++)t[i]=arguments[i];return r.useCallback(function(){for(var e=arguments.length,t=Array(e),i=0;i<e;i++)t[i]=arguments[i];return e=>{let i=!1,a=t.map(t=>{let a=cG(t,e);return i||"function"!=typeof a||(i=!0),a});if(i)return()=>{for(let e=0;e<a.length;e++){let i=a[e];"function"==typeof i?i():cG(t[e],null)}}}}(...t),t)}(a,t),[s]=c2(a,e),[o]=(0,r.useState)(null!=(i=e.playerInitTime)?i:eY());return r.createElement(c1,{ref:n,defaultHiddenCaptions:e.defaultHiddenCaptions,playerSoftwareName:"mux-player-react",playerSoftwareVersion:cJ,playerInitTime:o,...s})})}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.