From 2c37a3f47d2364e06465d085aad1ea5c3db77e5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gi=C3=B2=20Diani?= Date: Fri, 1 Nov 2024 15:26:36 +0100 Subject: [PATCH] added build --- VANA-php/.gitignore | 1 - VANA-php/public/build/assets/app-Bj0O7PhW.js | 307 ++++++++++++++++++ VANA-php/public/build/assets/app-Brxm-Dry.css | 1 + .../build/assets/pillarbox-CCcjZzR7.css | 1 + VANA-php/public/build/manifest.json | 18 + database.sqlite | Bin 2187264 -> 2187264 bytes 6 files changed, 327 insertions(+), 1 deletion(-) create mode 100644 VANA-php/public/build/assets/app-Bj0O7PhW.js create mode 100644 VANA-php/public/build/assets/app-Brxm-Dry.css create mode 100644 VANA-php/public/build/assets/pillarbox-CCcjZzR7.css create mode 100644 VANA-php/public/build/manifest.json diff --git a/VANA-php/.gitignore b/VANA-php/.gitignore index afa306b..839effa 100644 --- a/VANA-php/.gitignore +++ b/VANA-php/.gitignore @@ -1,6 +1,5 @@ /.phpunit.cache /node_modules -/public/build /public/hot /public/storage /storage/*.key diff --git a/VANA-php/public/build/assets/app-Bj0O7PhW.js b/VANA-php/public/build/assets/app-Bj0O7PhW.js new file mode 100644 index 0000000..656f128 --- /dev/null +++ b/VANA-php/public/build/assets/app-Bj0O7PhW.js @@ -0,0 +1,307 @@ +function v6(r,e){return function(){return r.apply(e,arguments)}}const{toString:qY}=Object.prototype,{getPrototypeOf:hC}=Object,v_=(r=>e=>{const t=qY.call(e);return r[t]||(r[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),ba=r=>(r=r.toLowerCase(),e=>v_(e)===r),g_=r=>e=>typeof e===r,{isArray:mf}=Array,Hp=g_("undefined");function jY(r){return r!==null&&!Hp(r)&&r.constructor!==null&&!Hp(r.constructor)&&dn(r.constructor.isBuffer)&&r.constructor.isBuffer(r)}const g6=ba("ArrayBuffer");function XY(r){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(r):e=r&&r.buffer&&g6(r.buffer),e}const YY=g_("string"),dn=g_("function"),m6=g_("number"),m_=r=>r!==null&&typeof r=="object",KY=r=>r===!0||r===!1,r0=r=>{if(v_(r)!=="object")return!1;const e=hC(r);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in r)&&!(Symbol.iterator in r)},ZY=ba("Date"),QY=ba("File"),JY=ba("Blob"),eK=ba("FileList"),tK=r=>m_(r)&&dn(r.pipe),rK=r=>{let e;return r&&(typeof FormData=="function"&&r instanceof FormData||dn(r.append)&&((e=v_(r))==="formdata"||e==="object"&&dn(r.toString)&&r.toString()==="[object FormData]"))},iK=ba("URLSearchParams"),[nK,aK,sK,oK]=["ReadableStream","Request","Response","Headers"].map(ba),lK=r=>r.trim?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ov(r,e,{allOwnKeys:t=!1}={}){if(r===null||typeof r>"u")return;let i,n;if(typeof r!="object"&&(r=[r]),mf(r))for(i=0,n=r.length;i0;)if(n=t[i],e===n.toLowerCase())return n;return null}const fu=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,_6=r=>!Hp(r)&&r!==fu;function vT(){const{caseless:r}=_6(this)&&this||{},e={},t=(i,n)=>{const a=r&&y6(e,n)||n;r0(e[a])&&r0(i)?e[a]=vT(e[a],i):r0(i)?e[a]=vT({},i):mf(i)?e[a]=i.slice():e[a]=i};for(let i=0,n=arguments.length;i(Ov(e,(n,a)=>{t&&dn(n)?r[a]=v6(n,t):r[a]=n},{allOwnKeys:i}),r),cK=r=>(r.charCodeAt(0)===65279&&(r=r.slice(1)),r),hK=(r,e,t,i)=>{r.prototype=Object.create(e.prototype,i),r.prototype.constructor=r,Object.defineProperty(r,"super",{value:e.prototype}),t&&Object.assign(r.prototype,t)},fK=(r,e,t,i)=>{let n,a,s;const o={};if(e=e||{},r==null)return e;do{for(n=Object.getOwnPropertyNames(r),a=n.length;a-- >0;)s=n[a],(!i||i(s,r,e))&&!o[s]&&(e[s]=r[s],o[s]=!0);r=t!==!1&&hC(r)}while(r&&(!t||t(r,e))&&r!==Object.prototype);return e},dK=(r,e,t)=>{r=String(r),(t===void 0||t>r.length)&&(t=r.length),t-=e.length;const i=r.indexOf(e,t);return i!==-1&&i===t},pK=r=>{if(!r)return null;if(mf(r))return r;let e=r.length;if(!m6(e))return null;const t=new Array(e);for(;e-- >0;)t[e]=r[e];return t},vK=(r=>e=>r&&e instanceof r)(typeof Uint8Array<"u"&&hC(Uint8Array)),gK=(r,e)=>{const i=(r&&r[Symbol.iterator]).call(r);let n;for(;(n=i.next())&&!n.done;){const a=n.value;e.call(r,a[0],a[1])}},mK=(r,e)=>{let t;const i=[];for(;(t=r.exec(e))!==null;)i.push(t);return i},yK=ba("HTMLFormElement"),_K=r=>r.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(t,i,n){return i.toUpperCase()+n}),N3=(({hasOwnProperty:r})=>(e,t)=>r.call(e,t))(Object.prototype),bK=ba("RegExp"),b6=(r,e)=>{const t=Object.getOwnPropertyDescriptors(r),i={};Ov(t,(n,a)=>{let s;(s=e(n,a,r))!==!1&&(i[a]=s||n)}),Object.defineProperties(r,i)},SK=r=>{b6(r,(e,t)=>{if(dn(r)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const i=r[t];if(dn(i)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},TK=(r,e)=>{const t={},i=n=>{n.forEach(a=>{t[a]=!0})};return mf(r)?i(r):i(String(r).split(e)),t},xK=()=>{},wK=(r,e)=>r!=null&&Number.isFinite(r=+r)?r:e,t2="abcdefghijklmnopqrstuvwxyz",B3="0123456789",S6={DIGIT:B3,ALPHA:t2,ALPHA_DIGIT:t2+t2.toUpperCase()+B3},CK=(r=16,e=S6.ALPHA_DIGIT)=>{let t="";const{length:i}=e;for(;r--;)t+=e[Math.random()*i|0];return t};function AK(r){return!!(r&&dn(r.append)&&r[Symbol.toStringTag]==="FormData"&&r[Symbol.iterator])}const DK=r=>{const e=new Array(10),t=(i,n)=>{if(m_(i)){if(e.indexOf(i)>=0)return;if(!("toJSON"in i)){e[n]=i;const a=mf(i)?[]:{};return Ov(i,(s,o)=>{const l=t(s,n+1);!Hp(l)&&(a[o]=l)}),e[n]=void 0,a}}return i};return t(r,0)},EK=ba("AsyncFunction"),IK=r=>r&&(m_(r)||dn(r))&&dn(r.then)&&dn(r.catch),T6=((r,e)=>r?setImmediate:e?((t,i)=>(fu.addEventListener("message",({source:n,data:a})=>{n===fu&&a===t&&i.length&&i.shift()()},!1),n=>{i.push(n),fu.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",dn(fu.postMessage)),PK=typeof queueMicrotask<"u"?queueMicrotask.bind(fu):typeof process<"u"&&process.nextTick||T6,ne={isArray:mf,isArrayBuffer:g6,isBuffer:jY,isFormData:rK,isArrayBufferView:XY,isString:YY,isNumber:m6,isBoolean:KY,isObject:m_,isPlainObject:r0,isReadableStream:nK,isRequest:aK,isResponse:sK,isHeaders:oK,isUndefined:Hp,isDate:ZY,isFile:QY,isBlob:JY,isRegExp:bK,isFunction:dn,isStream:tK,isURLSearchParams:iK,isTypedArray:vK,isFileList:eK,forEach:Ov,merge:vT,extend:uK,trim:lK,stripBOM:cK,inherits:hK,toFlatObject:fK,kindOf:v_,kindOfTest:ba,endsWith:dK,toArray:pK,forEachEntry:gK,matchAll:mK,isHTMLForm:yK,hasOwnProperty:N3,hasOwnProp:N3,reduceDescriptors:b6,freezeMethods:SK,toObjectSet:TK,toCamelCase:_K,noop:xK,toFiniteNumber:wK,findKey:y6,global:fu,isContextDefined:_6,ALPHABET:S6,generateString:CK,isSpecCompliantForm:AK,toJSONObject:DK,isAsyncFn:EK,isThenable:IK,setImmediate:T6,asap:PK};function at(r,e,t,i,n){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=r,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),i&&(this.request=i),n&&(this.response=n,this.status=n.status?n.status:null)}ne.inherits(at,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:ne.toJSONObject(this.config),code:this.code,status:this.status}}});const x6=at.prototype,w6={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(r=>{w6[r]={value:r}});Object.defineProperties(at,w6);Object.defineProperty(x6,"isAxiosError",{value:!0});at.from=(r,e,t,i,n,a)=>{const s=Object.create(x6);return ne.toFlatObject(r,s,function(l){return l!==Error.prototype},o=>o!=="isAxiosError"),at.call(s,r.message,e,t,i,n),s.cause=r,s.name=r.name,a&&Object.assign(s,a),s};const MK=null;function gT(r){return ne.isPlainObject(r)||ne.isArray(r)}function C6(r){return ne.endsWith(r,"[]")?r.slice(0,-2):r}function F3(r,e,t){return r?r.concat(e).map(function(n,a){return n=C6(n),!t&&a?"["+n+"]":n}).join(t?".":""):e}function LK(r){return ne.isArray(r)&&!r.some(gT)}const kK=ne.toFlatObject(ne,{},null,function(e){return/^is[A-Z]/.test(e)});function y_(r,e,t){if(!ne.isObject(r))throw new TypeError("target must be an object");e=e||new FormData,t=ne.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(v,g){return!ne.isUndefined(g[v])});const i=t.metaTokens,n=t.visitor||c,a=t.dots,s=t.indexes,l=(t.Blob||typeof Blob<"u"&&Blob)&&ne.isSpecCompliantForm(e);if(!ne.isFunction(n))throw new TypeError("visitor must be a function");function u(p){if(p===null)return"";if(ne.isDate(p))return p.toISOString();if(!l&&ne.isBlob(p))throw new at("Blob is not supported. Use a Buffer instead.");return ne.isArrayBuffer(p)||ne.isTypedArray(p)?l&&typeof Blob=="function"?new Blob([p]):Buffer.from(p):p}function c(p,v,g){let m=p;if(p&&!g&&typeof p=="object"){if(ne.endsWith(v,"{}"))v=i?v:v.slice(0,-2),p=JSON.stringify(p);else if(ne.isArray(p)&&LK(p)||(ne.isFileList(p)||ne.endsWith(v,"[]"))&&(m=ne.toArray(p)))return v=C6(v),m.forEach(function(_,b){!(ne.isUndefined(_)||_===null)&&e.append(s===!0?F3([v],b,a):s===null?v:v+"[]",u(_))}),!1}return gT(p)?!0:(e.append(F3(g,v,a),u(p)),!1)}const h=[],d=Object.assign(kK,{defaultVisitor:c,convertValue:u,isVisitable:gT});function f(p,v){if(!ne.isUndefined(p)){if(h.indexOf(p)!==-1)throw Error("Circular reference detected in "+v.join("."));h.push(p),ne.forEach(p,function(m,y){(!(ne.isUndefined(m)||m===null)&&n.call(e,m,ne.isString(y)?y.trim():y,v,d))===!0&&f(m,v?v.concat(y):[y])}),h.pop()}}if(!ne.isObject(r))throw new TypeError("data must be an object");return f(r),e}function U3(r){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(r).replace(/[!'()~]|%20|%00/g,function(i){return e[i]})}function fC(r,e){this._pairs=[],r&&y_(r,this,e)}const A6=fC.prototype;A6.append=function(e,t){this._pairs.push([e,t])};A6.toString=function(e){const t=e?function(i){return e.call(this,i,U3)}:U3;return this._pairs.map(function(n){return t(n[0])+"="+t(n[1])},"").join("&")};function RK(r){return encodeURIComponent(r).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function D6(r,e,t){if(!e)return r;const i=t&&t.encode||RK,n=t&&t.serialize;let a;if(n?a=n(e,t):a=ne.isURLSearchParams(e)?e.toString():new fC(e,t).toString(i),a){const s=r.indexOf("#");s!==-1&&(r=r.slice(0,s)),r+=(r.indexOf("?")===-1?"?":"&")+a}return r}class V3{constructor(){this.handlers=[]}use(e,t,i){return this.handlers.push({fulfilled:e,rejected:t,synchronous:i?i.synchronous:!1,runWhen:i?i.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){ne.forEach(this.handlers,function(i){i!==null&&e(i)})}}const E6={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},OK=typeof URLSearchParams<"u"?URLSearchParams:fC,NK=typeof FormData<"u"?FormData:null,BK=typeof Blob<"u"?Blob:null,FK={isBrowser:!0,classes:{URLSearchParams:OK,FormData:NK,Blob:BK},protocols:["http","https","file","blob","url","data"]},dC=typeof window<"u"&&typeof document<"u",mT=typeof navigator=="object"&&navigator||void 0,UK=dC&&(!mT||["ReactNative","NativeScript","NS"].indexOf(mT.product)<0),VK=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",zK=dC&&window.location.href||"http://localhost",GK=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:dC,hasStandardBrowserEnv:UK,hasStandardBrowserWebWorkerEnv:VK,navigator:mT,origin:zK},Symbol.toStringTag,{value:"Module"})),Gi={...GK,...FK};function HK(r,e){return y_(r,new Gi.classes.URLSearchParams,Object.assign({visitor:function(t,i,n,a){return Gi.isNode&&ne.isBuffer(t)?(this.append(i,t.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},e))}function $K(r){return ne.matchAll(/\w+|\[(\w*)]/g,r).map(e=>e[0]==="[]"?"":e[1]||e[0])}function WK(r){const e={},t=Object.keys(r);let i;const n=t.length;let a;for(i=0;i=t.length;return s=!s&&ne.isArray(n)?n.length:s,l?(ne.hasOwnProp(n,s)?n[s]=[n[s],i]:n[s]=i,!o):((!n[s]||!ne.isObject(n[s]))&&(n[s]=[]),e(t,i,n[s],a)&&ne.isArray(n[s])&&(n[s]=WK(n[s])),!o)}if(ne.isFormData(r)&&ne.isFunction(r.entries)){const t={};return ne.forEachEntry(r,(i,n)=>{e($K(i),n,t,0)}),t}return null}function qK(r,e,t){if(ne.isString(r))try{return(e||JSON.parse)(r),ne.trim(r)}catch(i){if(i.name!=="SyntaxError")throw i}return(0,JSON.stringify)(r)}const Nv={transitional:E6,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const i=t.getContentType()||"",n=i.indexOf("application/json")>-1,a=ne.isObject(e);if(a&&ne.isHTMLForm(e)&&(e=new FormData(e)),ne.isFormData(e))return n?JSON.stringify(I6(e)):e;if(ne.isArrayBuffer(e)||ne.isBuffer(e)||ne.isStream(e)||ne.isFile(e)||ne.isBlob(e)||ne.isReadableStream(e))return e;if(ne.isArrayBufferView(e))return e.buffer;if(ne.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let o;if(a){if(i.indexOf("application/x-www-form-urlencoded")>-1)return HK(e,this.formSerializer).toString();if((o=ne.isFileList(e))||i.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return y_(o?{"files[]":e}:e,l&&new l,this.formSerializer)}}return a||n?(t.setContentType("application/json",!1),qK(e)):e}],transformResponse:[function(e){const t=this.transitional||Nv.transitional,i=t&&t.forcedJSONParsing,n=this.responseType==="json";if(ne.isResponse(e)||ne.isReadableStream(e))return e;if(e&&ne.isString(e)&&(i&&!this.responseType||n)){const s=!(t&&t.silentJSONParsing)&&n;try{return JSON.parse(e)}catch(o){if(s)throw o.name==="SyntaxError"?at.from(o,at.ERR_BAD_RESPONSE,this,null,this.response):o}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Gi.classes.FormData,Blob:Gi.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};ne.forEach(["delete","get","head","post","put","patch"],r=>{Nv.headers[r]={}});const jK=ne.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),XK=r=>{const e={};let t,i,n;return r&&r.split(` +`).forEach(function(s){n=s.indexOf(":"),t=s.substring(0,n).trim().toLowerCase(),i=s.substring(n+1).trim(),!(!t||e[t]&&jK[t])&&(t==="set-cookie"?e[t]?e[t].push(i):e[t]=[i]:e[t]=e[t]?e[t]+", "+i:i)}),e},z3=Symbol("internals");function id(r){return r&&String(r).trim().toLowerCase()}function i0(r){return r===!1||r==null?r:ne.isArray(r)?r.map(i0):String(r)}function YK(r){const e=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let i;for(;i=t.exec(r);)e[i[1]]=i[2];return e}const KK=r=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(r.trim());function r2(r,e,t,i,n){if(ne.isFunction(i))return i.call(this,e,t);if(n&&(e=t),!!ne.isString(e)){if(ne.isString(i))return e.indexOf(i)!==-1;if(ne.isRegExp(i))return i.test(e)}}function ZK(r){return r.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,i)=>t.toUpperCase()+i)}function QK(r,e){const t=ne.toCamelCase(" "+e);["get","set","has"].forEach(i=>{Object.defineProperty(r,i+t,{value:function(n,a,s){return this[i].call(this,e,n,a,s)},configurable:!0})})}class Hi{constructor(e){e&&this.set(e)}set(e,t,i){const n=this;function a(o,l,u){const c=id(l);if(!c)throw new Error("header name must be a non-empty string");const h=ne.findKey(n,c);(!h||n[h]===void 0||u===!0||u===void 0&&n[h]!==!1)&&(n[h||l]=i0(o))}const s=(o,l)=>ne.forEach(o,(u,c)=>a(u,c,l));if(ne.isPlainObject(e)||e instanceof this.constructor)s(e,t);else if(ne.isString(e)&&(e=e.trim())&&!KK(e))s(XK(e),t);else if(ne.isHeaders(e))for(const[o,l]of e.entries())a(l,o,i);else e!=null&&a(t,e,i);return this}get(e,t){if(e=id(e),e){const i=ne.findKey(this,e);if(i){const n=this[i];if(!t)return n;if(t===!0)return YK(n);if(ne.isFunction(t))return t.call(this,n,i);if(ne.isRegExp(t))return t.exec(n);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=id(e),e){const i=ne.findKey(this,e);return!!(i&&this[i]!==void 0&&(!t||r2(this,this[i],i,t)))}return!1}delete(e,t){const i=this;let n=!1;function a(s){if(s=id(s),s){const o=ne.findKey(i,s);o&&(!t||r2(i,i[o],o,t))&&(delete i[o],n=!0)}}return ne.isArray(e)?e.forEach(a):a(e),n}clear(e){const t=Object.keys(this);let i=t.length,n=!1;for(;i--;){const a=t[i];(!e||r2(this,this[a],a,e,!0))&&(delete this[a],n=!0)}return n}normalize(e){const t=this,i={};return ne.forEach(this,(n,a)=>{const s=ne.findKey(i,a);if(s){t[s]=i0(n),delete t[a];return}const o=e?ZK(a):String(a).trim();o!==a&&delete t[a],t[o]=i0(n),i[o]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return ne.forEach(this,(i,n)=>{i!=null&&i!==!1&&(t[n]=e&&ne.isArray(i)?i.join(", "):i)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join(` +`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const i=new this(e);return t.forEach(n=>i.set(n)),i}static accessor(e){const i=(this[z3]=this[z3]={accessors:{}}).accessors,n=this.prototype;function a(s){const o=id(s);i[o]||(QK(n,s),i[o]=!0)}return ne.isArray(e)?e.forEach(a):a(e),this}}Hi.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);ne.reduceDescriptors(Hi.prototype,({value:r},e)=>{let t=e[0].toUpperCase()+e.slice(1);return{get:()=>r,set(i){this[t]=i}}});ne.freezeMethods(Hi);function i2(r,e){const t=this||Nv,i=e||t,n=Hi.from(i.headers);let a=i.data;return ne.forEach(r,function(o){a=o.call(t,a,n.normalize(),e?e.status:void 0)}),n.normalize(),a}function P6(r){return!!(r&&r.__CANCEL__)}function yf(r,e,t){at.call(this,r??"canceled",at.ERR_CANCELED,e,t),this.name="CanceledError"}ne.inherits(yf,at,{__CANCEL__:!0});function M6(r,e,t){const i=t.config.validateStatus;!t.status||!i||i(t.status)?r(t):e(new at("Request failed with status code "+t.status,[at.ERR_BAD_REQUEST,at.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function JK(r){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(r);return e&&e[1]||""}function eZ(r,e){r=r||10;const t=new Array(r),i=new Array(r);let n=0,a=0,s;return e=e!==void 0?e:1e3,function(l){const u=Date.now(),c=i[a];s||(s=u),t[n]=l,i[n]=u;let h=a,d=0;for(;h!==n;)d+=t[h++],h=h%r;if(n=(n+1)%r,n===a&&(a=(a+1)%r),u-s{t=c,n=null,a&&(clearTimeout(a),a=null),r.apply(null,u)};return[(...u)=>{const c=Date.now(),h=c-t;h>=i?s(u,c):(n=u,a||(a=setTimeout(()=>{a=null,s(n)},i-h)))},()=>n&&s(n)]}const R0=(r,e,t=3)=>{let i=0;const n=eZ(50,250);return tZ(a=>{const s=a.loaded,o=a.lengthComputable?a.total:void 0,l=s-i,u=n(l),c=s<=o;i=s;const h={loaded:s,total:o,progress:o?s/o:void 0,bytes:l,rate:u||void 0,estimated:u&&o&&c?(o-s)/u:void 0,event:a,lengthComputable:o!=null,[e?"download":"upload"]:!0};r(h)},t)},G3=(r,e)=>{const t=r!=null;return[i=>e[0]({lengthComputable:t,total:r,loaded:i}),e[1]]},H3=r=>(...e)=>ne.asap(()=>r(...e)),rZ=Gi.hasStandardBrowserEnv?function(){const e=Gi.navigator&&/(msie|trident)/i.test(Gi.navigator.userAgent),t=document.createElement("a");let i;function n(a){let s=a;return e&&(t.setAttribute("href",s),s=t.href),t.setAttribute("href",s),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:t.pathname.charAt(0)==="/"?t.pathname:"/"+t.pathname}}return i=n(window.location.href),function(s){const o=ne.isString(s)?n(s):s;return o.protocol===i.protocol&&o.host===i.host}}():function(){return function(){return!0}}(),iZ=Gi.hasStandardBrowserEnv?{write(r,e,t,i,n,a){const s=[r+"="+encodeURIComponent(e)];ne.isNumber(t)&&s.push("expires="+new Date(t).toGMTString()),ne.isString(i)&&s.push("path="+i),ne.isString(n)&&s.push("domain="+n),a===!0&&s.push("secure"),document.cookie=s.join("; ")},read(r){const e=document.cookie.match(new RegExp("(^|;\\s*)("+r+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(r){this.write(r,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function nZ(r){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(r)}function aZ(r,e){return e?r.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):r}function L6(r,e){return r&&!nZ(e)?aZ(r,e):e}const $3=r=>r instanceof Hi?{...r}:r;function qu(r,e){e=e||{};const t={};function i(u,c,h){return ne.isPlainObject(u)&&ne.isPlainObject(c)?ne.merge.call({caseless:h},u,c):ne.isPlainObject(c)?ne.merge({},c):ne.isArray(c)?c.slice():c}function n(u,c,h){if(ne.isUndefined(c)){if(!ne.isUndefined(u))return i(void 0,u,h)}else return i(u,c,h)}function a(u,c){if(!ne.isUndefined(c))return i(void 0,c)}function s(u,c){if(ne.isUndefined(c)){if(!ne.isUndefined(u))return i(void 0,u)}else return i(void 0,c)}function o(u,c,h){if(h in e)return i(u,c);if(h in r)return i(void 0,u)}const l={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:o,headers:(u,c)=>n($3(u),$3(c),!0)};return ne.forEach(Object.keys(Object.assign({},r,e)),function(c){const h=l[c]||n,d=h(r[c],e[c],c);ne.isUndefined(d)&&h!==o||(t[c]=d)}),t}const k6=r=>{const e=qu({},r);let{data:t,withXSRFToken:i,xsrfHeaderName:n,xsrfCookieName:a,headers:s,auth:o}=e;e.headers=s=Hi.from(s),e.url=D6(L6(e.baseURL,e.url),r.params,r.paramsSerializer),o&&s.set("Authorization","Basic "+btoa((o.username||"")+":"+(o.password?unescape(encodeURIComponent(o.password)):"")));let l;if(ne.isFormData(t)){if(Gi.hasStandardBrowserEnv||Gi.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if((l=s.getContentType())!==!1){const[u,...c]=l?l.split(";").map(h=>h.trim()).filter(Boolean):[];s.setContentType([u||"multipart/form-data",...c].join("; "))}}if(Gi.hasStandardBrowserEnv&&(i&&ne.isFunction(i)&&(i=i(e)),i||i!==!1&&rZ(e.url))){const u=n&&a&&iZ.read(a);u&&s.set(n,u)}return e},sZ=typeof XMLHttpRequest<"u",oZ=sZ&&function(r){return new Promise(function(t,i){const n=k6(r);let a=n.data;const s=Hi.from(n.headers).normalize();let{responseType:o,onUploadProgress:l,onDownloadProgress:u}=n,c,h,d,f,p;function v(){f&&f(),p&&p(),n.cancelToken&&n.cancelToken.unsubscribe(c),n.signal&&n.signal.removeEventListener("abort",c)}let g=new XMLHttpRequest;g.open(n.method.toUpperCase(),n.url,!0),g.timeout=n.timeout;function m(){if(!g)return;const _=Hi.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders()),T={data:!o||o==="text"||o==="json"?g.responseText:g.response,status:g.status,statusText:g.statusText,headers:_,config:r,request:g};M6(function(C){t(C),v()},function(C){i(C),v()},T),g=null}"onloadend"in g?g.onloadend=m:g.onreadystatechange=function(){!g||g.readyState!==4||g.status===0&&!(g.responseURL&&g.responseURL.indexOf("file:")===0)||setTimeout(m)},g.onabort=function(){g&&(i(new at("Request aborted",at.ECONNABORTED,r,g)),g=null)},g.onerror=function(){i(new at("Network Error",at.ERR_NETWORK,r,g)),g=null},g.ontimeout=function(){let b=n.timeout?"timeout of "+n.timeout+"ms exceeded":"timeout exceeded";const T=n.transitional||E6;n.timeoutErrorMessage&&(b=n.timeoutErrorMessage),i(new at(b,T.clarifyTimeoutError?at.ETIMEDOUT:at.ECONNABORTED,r,g)),g=null},a===void 0&&s.setContentType(null),"setRequestHeader"in g&&ne.forEach(s.toJSON(),function(b,T){g.setRequestHeader(T,b)}),ne.isUndefined(n.withCredentials)||(g.withCredentials=!!n.withCredentials),o&&o!=="json"&&(g.responseType=n.responseType),u&&([d,p]=R0(u,!0),g.addEventListener("progress",d)),l&&g.upload&&([h,f]=R0(l),g.upload.addEventListener("progress",h),g.upload.addEventListener("loadend",f)),(n.cancelToken||n.signal)&&(c=_=>{g&&(i(!_||_.type?new yf(null,r,g):_),g.abort(),g=null)},n.cancelToken&&n.cancelToken.subscribe(c),n.signal&&(n.signal.aborted?c():n.signal.addEventListener("abort",c)));const y=JK(n.url);if(y&&Gi.protocols.indexOf(y)===-1){i(new at("Unsupported protocol "+y+":",at.ERR_BAD_REQUEST,r));return}g.send(a||null)})},lZ=(r,e)=>{const{length:t}=r=r?r.filter(Boolean):[];if(e||t){let i=new AbortController,n;const a=function(u){if(!n){n=!0,o();const c=u instanceof Error?u:this.reason;i.abort(c instanceof at?c:new yf(c instanceof Error?c.message:c))}};let s=e&&setTimeout(()=>{s=null,a(new at(`timeout ${e} of ms exceeded`,at.ETIMEDOUT))},e);const o=()=>{r&&(s&&clearTimeout(s),s=null,r.forEach(u=>{u.unsubscribe?u.unsubscribe(a):u.removeEventListener("abort",a)}),r=null)};r.forEach(u=>u.addEventListener("abort",a));const{signal:l}=i;return l.unsubscribe=()=>ne.asap(o),l}},uZ=function*(r,e){let t=r.byteLength;if(t{const n=cZ(r,e);let a=0,s,o=l=>{s||(s=!0,i&&i(l))};return new ReadableStream({async pull(l){try{const{done:u,value:c}=await n.next();if(u){o(),l.close();return}let h=c.byteLength;if(t){let d=a+=h;t(d)}l.enqueue(new Uint8Array(c))}catch(u){throw o(u),u}},cancel(l){return o(l),n.return()}},{highWaterMark:2})},__=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",R6=__&&typeof ReadableStream=="function",fZ=__&&(typeof TextEncoder=="function"?(r=>e=>r.encode(e))(new TextEncoder):async r=>new Uint8Array(await new Response(r).arrayBuffer())),O6=(r,...e)=>{try{return!!r(...e)}catch{return!1}},dZ=R6&&O6(()=>{let r=!1;const e=new Request(Gi.origin,{body:new ReadableStream,method:"POST",get duplex(){return r=!0,"half"}}).headers.has("Content-Type");return r&&!e}),q3=64*1024,yT=R6&&O6(()=>ne.isReadableStream(new Response("").body)),O0={stream:yT&&(r=>r.body)};__&&(r=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!O0[e]&&(O0[e]=ne.isFunction(r[e])?t=>t[e]():(t,i)=>{throw new at(`Response type '${e}' is not supported`,at.ERR_NOT_SUPPORT,i)})})})(new Response);const pZ=async r=>{if(r==null)return 0;if(ne.isBlob(r))return r.size;if(ne.isSpecCompliantForm(r))return(await new Request(Gi.origin,{method:"POST",body:r}).arrayBuffer()).byteLength;if(ne.isArrayBufferView(r)||ne.isArrayBuffer(r))return r.byteLength;if(ne.isURLSearchParams(r)&&(r=r+""),ne.isString(r))return(await fZ(r)).byteLength},vZ=async(r,e)=>{const t=ne.toFiniteNumber(r.getContentLength());return t??pZ(e)},gZ=__&&(async r=>{let{url:e,method:t,data:i,signal:n,cancelToken:a,timeout:s,onDownloadProgress:o,onUploadProgress:l,responseType:u,headers:c,withCredentials:h="same-origin",fetchOptions:d}=k6(r);u=u?(u+"").toLowerCase():"text";let f=lZ([n,a&&a.toAbortSignal()],s),p;const v=f&&f.unsubscribe&&(()=>{f.unsubscribe()});let g;try{if(l&&dZ&&t!=="get"&&t!=="head"&&(g=await vZ(c,i))!==0){let T=new Request(e,{method:"POST",body:i,duplex:"half"}),x;if(ne.isFormData(i)&&(x=T.headers.get("content-type"))&&c.setContentType(x),T.body){const[C,D]=G3(g,R0(H3(l)));i=W3(T.body,q3,C,D)}}ne.isString(h)||(h=h?"include":"omit");const m="credentials"in Request.prototype;p=new Request(e,{...d,signal:f,method:t.toUpperCase(),headers:c.normalize().toJSON(),body:i,duplex:"half",credentials:m?h:void 0});let y=await fetch(p);const _=yT&&(u==="stream"||u==="response");if(yT&&(o||_&&v)){const T={};["status","statusText","headers"].forEach(I=>{T[I]=y[I]});const x=ne.toFiniteNumber(y.headers.get("content-length")),[C,D]=o&&G3(x,R0(H3(o),!0))||[];y=new Response(W3(y.body,q3,C,()=>{D&&D(),v&&v()}),T)}u=u||"text";let b=await O0[ne.findKey(O0,u)||"text"](y,r);return!_&&v&&v(),await new Promise((T,x)=>{M6(T,x,{data:b,headers:Hi.from(y.headers),status:y.status,statusText:y.statusText,config:r,request:p})})}catch(m){throw v&&v(),m&&m.name==="TypeError"&&/fetch/i.test(m.message)?Object.assign(new at("Network Error",at.ERR_NETWORK,r,p),{cause:m.cause||m}):at.from(m,m&&m.code,r,p)}}),_T={http:MK,xhr:oZ,fetch:gZ};ne.forEach(_T,(r,e)=>{if(r){try{Object.defineProperty(r,"name",{value:e})}catch{}Object.defineProperty(r,"adapterName",{value:e})}});const j3=r=>`- ${r}`,mZ=r=>ne.isFunction(r)||r===null||r===!1,N6={getAdapter:r=>{r=ne.isArray(r)?r:[r];const{length:e}=r;let t,i;const n={};for(let a=0;a`adapter ${o} `+(l===!1?"is not supported by the environment":"is not available in the build"));let s=e?a.length>1?`since : +`+a.map(j3).join(` +`):" "+j3(a[0]):"as no adapter specified";throw new at("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return i},adapters:_T};function n2(r){if(r.cancelToken&&r.cancelToken.throwIfRequested(),r.signal&&r.signal.aborted)throw new yf(null,r)}function X3(r){return n2(r),r.headers=Hi.from(r.headers),r.data=i2.call(r,r.transformRequest),["post","put","patch"].indexOf(r.method)!==-1&&r.headers.setContentType("application/x-www-form-urlencoded",!1),N6.getAdapter(r.adapter||Nv.adapter)(r).then(function(i){return n2(r),i.data=i2.call(r,r.transformResponse,i),i.headers=Hi.from(i.headers),i},function(i){return P6(i)||(n2(r),i&&i.response&&(i.response.data=i2.call(r,r.transformResponse,i.response),i.response.headers=Hi.from(i.response.headers))),Promise.reject(i)})}const B6="1.7.7",pC={};["object","boolean","number","function","string","symbol"].forEach((r,e)=>{pC[r]=function(i){return typeof i===r||"a"+(e<1?"n ":" ")+r}});const Y3={};pC.transitional=function(e,t,i){function n(a,s){return"[Axios v"+B6+"] Transitional option '"+a+"'"+s+(i?". "+i:"")}return(a,s,o)=>{if(e===!1)throw new at(n(s," has been removed"+(t?" in "+t:"")),at.ERR_DEPRECATED);return t&&!Y3[s]&&(Y3[s]=!0,console.warn(n(s," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(a,s,o):!0}};function yZ(r,e,t){if(typeof r!="object")throw new at("options must be an object",at.ERR_BAD_OPTION_VALUE);const i=Object.keys(r);let n=i.length;for(;n-- >0;){const a=i[n],s=e[a];if(s){const o=r[a],l=o===void 0||s(o,a,r);if(l!==!0)throw new at("option "+a+" must be "+l,at.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new at("Unknown option "+a,at.ERR_BAD_OPTION)}}const bT={assertOptions:yZ,validators:pC},so=bT.validators;class wu{constructor(e){this.defaults=e,this.interceptors={request:new V3,response:new V3}}async request(e,t){try{return await this._request(e,t)}catch(i){if(i instanceof Error){let n;Error.captureStackTrace?Error.captureStackTrace(n={}):n=new Error;const a=n.stack?n.stack.replace(/^.+\n/,""):"";try{i.stack?a&&!String(i.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(i.stack+=` +`+a):i.stack=a}catch{}}throw i}}_request(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=qu(this.defaults,t);const{transitional:i,paramsSerializer:n,headers:a}=t;i!==void 0&&bT.assertOptions(i,{silentJSONParsing:so.transitional(so.boolean),forcedJSONParsing:so.transitional(so.boolean),clarifyTimeoutError:so.transitional(so.boolean)},!1),n!=null&&(ne.isFunction(n)?t.paramsSerializer={serialize:n}:bT.assertOptions(n,{encode:so.function,serialize:so.function},!0)),t.method=(t.method||this.defaults.method||"get").toLowerCase();let s=a&&ne.merge(a.common,a[t.method]);a&&ne.forEach(["delete","get","head","post","put","patch","common"],p=>{delete a[p]}),t.headers=Hi.concat(s,a);const o=[];let l=!0;this.interceptors.request.forEach(function(v){typeof v.runWhen=="function"&&v.runWhen(t)===!1||(l=l&&v.synchronous,o.unshift(v.fulfilled,v.rejected))});const u=[];this.interceptors.response.forEach(function(v){u.push(v.fulfilled,v.rejected)});let c,h=0,d;if(!l){const p=[X3.bind(this),void 0];for(p.unshift.apply(p,o),p.push.apply(p,u),d=p.length,c=Promise.resolve(t);h{if(!i._listeners)return;let a=i._listeners.length;for(;a-- >0;)i._listeners[a](n);i._listeners=null}),this.promise.then=n=>{let a;const s=new Promise(o=>{i.subscribe(o),a=o}).then(n);return s.cancel=function(){i.unsubscribe(a)},s},e(function(a,s,o){i.reason||(i.reason=new yf(a,s,o),t(i.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=i=>{e.abort(i)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new vC(function(n){e=n}),cancel:e}}}function _Z(r){return function(t){return r.apply(null,t)}}function bZ(r){return ne.isObject(r)&&r.isAxiosError===!0}const ST={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(ST).forEach(([r,e])=>{ST[e]=r});function F6(r){const e=new wu(r),t=v6(wu.prototype.request,e);return ne.extend(t,wu.prototype,e,{allOwnKeys:!0}),ne.extend(t,e,null,{allOwnKeys:!0}),t.create=function(n){return F6(qu(r,n))},t}const Cr=F6(Nv);Cr.Axios=wu;Cr.CanceledError=yf;Cr.CancelToken=vC;Cr.isCancel=P6;Cr.VERSION=B6;Cr.toFormData=y_;Cr.AxiosError=at;Cr.Cancel=Cr.CanceledError;Cr.all=function(e){return Promise.all(e)};Cr.spread=_Z;Cr.isAxiosError=bZ;Cr.mergeConfig=qu;Cr.AxiosHeaders=Hi;Cr.formToJSON=r=>I6(ne.isHTMLForm(r)?new FormData(r):r);Cr.getAdapter=N6.getAdapter;Cr.HttpStatusCode=ST;Cr.default=Cr;window.axios=Cr;window.axios.defaults.headers.common["X-Requested-With"]="XMLHttpRequest";var N0=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Bv(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function U6(r){if(r.__esModule)return r;var e=r.default;if(typeof e=="function"){var t=function i(){return this instanceof i?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};t.prototype=e.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(r).forEach(function(i){var n=Object.getOwnPropertyDescriptor(r,i);Object.defineProperty(t,i,n.get?n:{enumerable:!0,get:function(){return r[i]}})}),t}var Gd;typeof window<"u"?Gd=window:typeof N0<"u"?Gd=N0:typeof self<"u"?Gd=self:Gd={};var b_=Gd;const H=Bv(b_),SZ={},TZ=Object.freeze(Object.defineProperty({__proto__:null,default:SZ},Symbol.toStringTag,{value:"Module"})),xZ=U6(TZ);var K3=typeof N0<"u"?N0:typeof window<"u"?window:{},wZ=xZ,Hd;typeof document<"u"?Hd=document:(Hd=K3["__GLOBAL_DOCUMENT_CACHE@4"],Hd||(Hd=K3["__GLOBAL_DOCUMENT_CACHE@4"]=wZ));var V6=Hd;const de=Bv(V6);var gC={exports:{}};function ar(){return ar=Object.assign?Object.assign.bind():function(r){for(var e=1;e=r.length?{done:!0}:{done:!1,value:r[i++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function MZ(r,e){if(r){if(typeof r=="string")return Z3(r,e);var t=Object.prototype.toString.call(r).slice(8,-1);if(t==="Object"&&r.constructor&&(t=r.constructor.name),t==="Map"||t==="Set")return Array.from(r);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Z3(r,e)}}function Z3(r,e){(e==null||e>r.length)&&(e=r.length);for(var t=0,i=new Array(e);t=400&&n.statusCode<=599){var s=a;if(t)if(BZ.TextDecoder){var o=UZ(n.headers&&n.headers["content-type"]);try{s=new TextDecoder(o).decode(a)}catch{}}else s=String.fromCharCode.apply(null,new Uint8Array(a));e({cause:s});return}e(null,a)}};function UZ(r){return r===void 0&&(r=""),r.toLowerCase().split(";").reduce(function(e,t){var i=t.split("="),n=i[0],a=i[1];return n.trim()==="charset"?a.trim():e},"utf-8")}var VZ=FZ,z6=b_,zZ=AZ,GZ=DZ,G6=kZ,HZ=NZ;dr.httpHandler=VZ;dr.requestInterceptorsStorage=new G6;dr.responseInterceptorsStorage=new G6;dr.retryManager=new HZ;/** + * @license + * slighly modified parse-headers 2.0.2 + * Copyright (c) 2014 David Björklund + * Available under the MIT license + * + */var $Z=function(e){var t={};return e&&e.trim().split(` +`).forEach(function(i){var n=i.indexOf(":"),a=i.slice(0,n).trim().toLowerCase(),s=i.slice(n+1).trim();typeof t[a]>"u"?t[a]=s:Array.isArray(t[a])?t[a].push(s):t[a]=[t[a],s]}),t};gC.exports=dr;gC.exports.default=dr;dr.XMLHttpRequest=z6.XMLHttpRequest||XZ;dr.XDomainRequest="withCredentials"in new dr.XMLHttpRequest?dr.XMLHttpRequest:z6.XDomainRequest;WZ(["get","put","post","patch","head","delete"],function(r){dr[r==="delete"?"del":r]=function(e,t,i){return t=H6(e,t,i),t.method=r.toUpperCase(),mC(t)}});function WZ(r,e){for(var t=0;t"u")throw new Error("callback argument missing");if(r.requestType&&dr.requestInterceptorsStorage.getIsEnabled()){var e={uri:r.uri||r.url,headers:r.headers||{},body:r.body,metadata:r.metadata||{},retry:r.retry,timeout:r.timeout},t=dr.requestInterceptorsStorage.execute(r.requestType,e);r.uri=t.uri,r.headers=t.headers,r.body=t.body,r.metadata=t.metadata,r.retry=t.retry,r.timeout=t.timeout}var i=!1,n=function(T,x,C){i||(i=!0,r.callback(T,x,C))};function a(){u.readyState===4&&!dr.responseInterceptorsStorage.getIsEnabled()&&setTimeout(l,0)}function s(){var b=void 0;if(u.response?b=u.response:b=u.responseText||jZ(u),m)try{b=JSON.parse(b)}catch{}return b}function o(b){if(clearTimeout(y),clearTimeout(r.retryTimeout),b instanceof Error||(b=new Error(""+(b||"Unknown XMLHttpRequest Error"))),b.statusCode=0,!h&&dr.retryManager.getIsEnabled()&&r.retry&&r.retry.shouldRetry()){r.retryTimeout=setTimeout(function(){r.retry.moveToNextAttempt(),r.xhr=u,mC(r)},r.retry.getCurrentFuzzedDelay());return}if(r.requestType&&dr.responseInterceptorsStorage.getIsEnabled()){var T={headers:_.headers||{},body:_.body,responseUrl:u.responseURL,responseType:u.responseType},x=dr.responseInterceptorsStorage.execute(r.requestType,T);_.body=x.body,_.headers=x.headers}return n(b,_)}function l(){if(!h){var b;clearTimeout(y),clearTimeout(r.retryTimeout),r.useXDR&&u.status===void 0?b=200:b=u.status===1223?204:u.status;var T=_,x=null;if(b!==0?(T={body:s(),statusCode:b,method:f,headers:{},url:d,rawRequest:u},u.getAllResponseHeaders&&(T.headers=$Z(u.getAllResponseHeaders()))):x=new Error("Internal XMLHttpRequest Error"),r.requestType&&dr.responseInterceptorsStorage.getIsEnabled()){var C={headers:T.headers||{},body:T.body,responseUrl:u.responseURL,responseType:u.responseType},D=dr.responseInterceptorsStorage.execute(r.requestType,C);T.body=D.body,T.headers=D.headers}return n(x,T,T.body)}}var u=r.xhr||null;u||(r.cors||r.useXDR?u=new dr.XDomainRequest:u=new dr.XMLHttpRequest);var c,h,d=u.url=r.uri||r.url,f=u.method=r.method||"GET",p=r.body||r.data,v=u.headers=r.headers||{},g=!!r.sync,m=!1,y,_={body:void 0,headers:{},statusCode:0,method:f,url:d,rawRequest:u};if("json"in r&&r.json!==!1&&(m=!0,v.accept||v.Accept||(v.Accept="application/json"),f!=="GET"&&f!=="HEAD"&&(v["content-type"]||v["Content-Type"]||(v["Content-Type"]="application/json"),p=JSON.stringify(r.json===!0?p:r.json))),u.onreadystatechange=a,u.onload=l,u.onerror=o,u.onprogress=function(){},u.onabort=function(){h=!0,clearTimeout(r.retryTimeout)},u.ontimeout=o,u.open(f,d,!g,r.username,r.password),g||(u.withCredentials=!!r.withCredentials),!g&&r.timeout>0&&(y=setTimeout(function(){if(!h){h=!0,u.abort("timeout");var b=new Error("XMLHttpRequest timeout");b.code="ETIMEDOUT",o(b)}},r.timeout)),u.setRequestHeader)for(c in v)v.hasOwnProperty(c)&&u.setRequestHeader(c,v[c]);else if(r.headers&&!qZ(r.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in r&&(u.responseType=r.responseType),"beforeSend"in r&&typeof r.beforeSend=="function"&&r.beforeSend(u),u.send(p||null),u}function jZ(r){try{if(r.responseType==="document")return r.responseXML;var e=r.responseXML&&r.responseXML.documentElement.nodeName==="parsererror";if(r.responseType===""&&!e)return r.responseXML}catch{}return null}function XZ(){}var YZ=gC.exports;const $6=Bv(YZ);var W6={exports:{}},Q3=V6,yC=Object.create||function(){function r(){}return function(e){if(arguments.length!==1)throw new Error("Object.create shim only accepts one parameter.");return r.prototype=e,new r}}();function on(r,e){this.name="ParsingError",this.code=r.code,this.message=e||r.message}on.prototype=yC(Error.prototype);on.prototype.constructor=on;on.Errors={BadSignature:{code:0,message:"Malformed WebVTT signature."},BadTimeStamp:{code:1,message:"Malformed time stamp."}};function _C(r){function e(i,n,a,s){return(i|0)*3600+(n|0)*60+(a|0)+(s|0)/1e3}var t=r.match(/^(\d+):(\d{1,2})(:\d{1,2})?\.(\d{3})/);return t?t[3]?e(t[1],t[2],t[3].replace(":",""),t[4]):t[1]>59?e(t[1],t[2],0,t[4]):e(0,t[1],t[2],t[4]):null}function dp(){this.values=yC(null)}dp.prototype={set:function(r,e){!this.get(r)&&e!==""&&(this.values[r]=e)},get:function(r,e,t){return t?this.has(r)?this.values[r]:e[t]:this.has(r)?this.values[r]:e},has:function(r){return r in this.values},alt:function(r,e,t){for(var i=0;i=0&&e<=100)?(this.set(r,e),!0):!1}};function $d(r,e,t,i){var n=i?r.split(i):[r];for(var a in n)if(typeof n[a]=="string"){var s=n[a].split(t);if(s.length===2){var o=s[0].trim(),l=s[1].trim();e(o,l)}}}function KZ(r,e,t){var i=r;function n(){var o=_C(r);if(o===null)throw new on(on.Errors.BadTimeStamp,"Malformed timestamp: "+i);return r=r.replace(/^[^\sa-zA-Z-]+/,""),o}function a(o,l){var u=new dp;$d(o,function(c,h){switch(c){case"region":for(var d=t.length-1;d>=0;d--)if(t[d].id===h){u.set(c,t[d].region);break}break;case"vertical":u.alt(c,h,["rl","lr"]);break;case"line":var f=h.split(","),p=f[0];u.integer(c,p),u.percent(c,p)&&u.set("snapToLines",!1),u.alt(c,p,["auto"]),f.length===2&&u.alt("lineAlign",f[1],["start","center","end"]);break;case"position":f=h.split(","),u.percent(c,f[0]),f.length===2&&u.alt("positionAlign",f[1],["start","center","end"]);break;case"size":u.percent(c,h);break;case"align":u.alt(c,h,["start","center","end","left","right"]);break}},/:/,/\s/),l.region=u.get("region",null),l.vertical=u.get("vertical","");try{l.line=u.get("line","auto")}catch{}l.lineAlign=u.get("lineAlign","start"),l.snapToLines=u.get("snapToLines",!0),l.size=u.get("size",100);try{l.align=u.get("align","center")}catch{l.align=u.get("align","middle")}try{l.position=u.get("position","auto")}catch{l.position=u.get("position",{start:0,left:0,center:50,middle:50,end:100,right:100},l.align)}l.positionAlign=u.get("positionAlign",{start:"start",left:"start",center:"center",middle:"center",end:"end",right:"end"},l.align)}function s(){r=r.replace(/^\s+/,"")}if(s(),e.startTime=n(),s(),r.substr(0,3)!=="-->")throw new on(on.Errors.BadTimeStamp,"Malformed time stamp (time stamps must be separated by '-->'): "+i);r=r.substr(3),s(),e.endTime=n(),s(),a(r,e)}var a2=Q3.createElement&&Q3.createElement("textarea"),ZZ={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},J3={white:"rgba(255,255,255,1)",lime:"rgba(0,255,0,1)",cyan:"rgba(0,255,255,1)",red:"rgba(255,0,0,1)",yellow:"rgba(255,255,0,1)",magenta:"rgba(255,0,255,1)",blue:"rgba(0,0,255,1)",black:"rgba(0,0,0,1)"},QZ={v:"title",lang:"lang"},eI={rt:"ruby"};function q6(r,e){function t(){if(!e)return null;function p(g){return e=e.substr(g.length),g}var v=e.match(/^([^<]*)(<[^>]*>?)?/);return p(v[1]?v[1]:v[2])}function i(p){return a2.innerHTML=p,p=a2.textContent,a2.textContent="",p}function n(p,v){return!eI[v.localName]||eI[v.localName]===p.localName}function a(p,v){var g=ZZ[p];if(!g)return null;var m=r.document.createElement(g),y=QZ[p];return y&&v&&(m[y]=v.trim()),m}for(var s=r.document.createElement("div"),o=s,l,u=[];(l=t())!==null;){if(l[0]==="<"){if(l[1]==="/"){u.length&&u[u.length-1]===l.substr(2).replace(">","")&&(u.pop(),o=o.parentNode);continue}var c=_C(l.substr(1,l.length-2)),h;if(c){h=r.document.createProcessingInstruction("timestamp",c),o.appendChild(h);continue}var d=l.match(/^<([^.\s/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!d||(h=a(d[1],d[3]),!h)||!n(o,h))continue;if(d[2]){var f=d[2].split(".");f.forEach(function(p){var v=/^bg_/.test(p),g=v?p.slice(3):p;if(J3.hasOwnProperty(g)){var m=v?"background-color":"color",y=J3[g];h.style[m]=y}}),h.className=f.join(" ")}u.push(d[1]),o.appendChild(h),o=h;continue}o.appendChild(r.document.createTextNode(i(l)))}return s}var tI=[[1470,1470],[1472,1472],[1475,1475],[1478,1478],[1488,1514],[1520,1524],[1544,1544],[1547,1547],[1549,1549],[1563,1563],[1566,1610],[1645,1647],[1649,1749],[1765,1766],[1774,1775],[1786,1805],[1807,1808],[1810,1839],[1869,1957],[1969,1969],[1984,2026],[2036,2037],[2042,2042],[2048,2069],[2074,2074],[2084,2084],[2088,2088],[2096,2110],[2112,2136],[2142,2142],[2208,2208],[2210,2220],[8207,8207],[64285,64285],[64287,64296],[64298,64310],[64312,64316],[64318,64318],[64320,64321],[64323,64324],[64326,64449],[64467,64829],[64848,64911],[64914,64967],[65008,65020],[65136,65140],[65142,65276],[67584,67589],[67592,67592],[67594,67637],[67639,67640],[67644,67644],[67647,67669],[67671,67679],[67840,67867],[67872,67897],[67903,67903],[67968,68023],[68030,68031],[68096,68096],[68112,68115],[68117,68119],[68121,68147],[68160,68167],[68176,68184],[68192,68223],[68352,68405],[68416,68437],[68440,68466],[68472,68479],[68608,68680],[126464,126467],[126469,126495],[126497,126498],[126500,126500],[126503,126503],[126505,126514],[126516,126519],[126521,126521],[126523,126523],[126530,126530],[126535,126535],[126537,126537],[126539,126539],[126541,126543],[126545,126546],[126548,126548],[126551,126551],[126553,126553],[126555,126555],[126557,126557],[126559,126559],[126561,126562],[126564,126564],[126567,126570],[126572,126578],[126580,126583],[126585,126588],[126590,126590],[126592,126601],[126603,126619],[126625,126627],[126629,126633],[126635,126651],[1114109,1114109]];function JZ(r){for(var e=0;e=t[0]&&r<=t[1])return!0}return!1}function eQ(r){var e=[],t="",i;if(!r||!r.childNodes)return"ltr";function n(o,l){for(var u=l.childNodes.length-1;u>=0;u--)o.push(l.childNodes[u])}function a(o){if(!o||!o.length)return null;var l=o.pop(),u=l.textContent||l.innerText;if(u){var c=u.match(/^.*(\n|\r)/);return c?(o.length=0,c[0]):u}if(l.tagName==="ruby")return a(o);if(l.childNodes)return n(o,l),a(o)}for(n(e,r);t=a(e);)for(var s=0;s=0&&r.line<=100))return r.line;if(!r.track||!r.track.textTrackList||!r.track.textTrackList.mediaElement)return-1;for(var e=r.track,t=e.textTrackList,i=0,n=0;nr.left&&this.topr.top};bi.prototype.overlapsAny=function(r){for(var e=0;e=r.top&&this.bottom<=r.bottom&&this.left>=r.left&&this.right<=r.right};bi.prototype.overlapsOppositeAxis=function(r,e){switch(e){case"+x":return this.leftr.right;case"+y":return this.topr.bottom}};bi.prototype.intersectPercentage=function(r){var e=Math.max(0,Math.min(this.right,r.right)-Math.max(this.left,r.left)),t=Math.max(0,Math.min(this.bottom,r.bottom)-Math.max(this.top,r.top)),i=e*t;return i/(this.height*this.width)};bi.prototype.toCSSCompatValues=function(r){return{top:this.top-r.top,bottom:r.bottom-this.bottom,left:this.left-r.left,right:r.right-this.right,height:this.height,width:this.width}};bi.getSimpleBoxPosition=function(r){var e=r.div?r.div.offsetHeight:r.tagName?r.offsetHeight:0,t=r.div?r.div.offsetWidth:r.tagName?r.offsetWidth:0,i=r.div?r.div.offsetTop:r.tagName?r.offsetTop:0;r=r.div?r.div.getBoundingClientRect():r.tagName?r.getBoundingClientRect():r;var n={left:r.left,right:r.right,top:r.top||i,height:r.height||e,bottom:r.bottom||i+(r.height||e),width:r.width||t};return n};function rQ(r,e,t,i){function n(g,m){for(var y,_=new bi(g),b=1,T=0;Tx&&(y=new bi(g),b=x),g=new bi(_)}return y||_}var a=new bi(e),s=e.cue,o=tQ(s),l=[];if(s.snapToLines){var u;switch(s.vertical){case"":l=["+y","-y"],u="height";break;case"rl":l=["+x","-x"],u="width";break;case"lr":l=["-x","+x"],u="width";break}var c=a.lineHeight,h=c*Math.round(o),d=t[u]+c,f=l[0];Math.abs(h)>d&&(h=h<0?-1:1,h*=Math.ceil(d/c)*c),o<0&&(h+=s.vertical===""?t.height:t.width,l=l.reverse()),a.move(f,h)}else{var p=a.lineHeight/t.height*100;switch(s.lineAlign){case"center":o-=p/2;break;case"end":o-=p;break}switch(s.vertical){case"":e.applyStyles({top:e.formatStyle(o,"%")});break;case"rl":e.applyStyles({left:e.formatStyle(o,"%")});break;case"lr":e.applyStyles({right:e.formatStyle(o,"%")});break}l=["+y","-x","+x","-y"],a=new bi(e)}var v=n(a,l);e.move(v.toCSSCompatValues(t))}function _f(){}_f.StringDecoder=function(){return{decode:function(r){if(!r)return"";if(typeof r!="string")throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(r))}}};_f.convertCueToDOMTree=function(r,e){return!r||!e?null:q6(r,e)};var iQ=.05,nQ="sans-serif",aQ="1.5%";_f.processCues=function(r,e,t){if(!r||!e||!t)return null;for(;t.firstChild;)t.removeChild(t.firstChild);var i=r.document.createElement("div");i.style.position="absolute",i.style.left="0",i.style.right="0",i.style.top="0",i.style.bottom="0",i.style.margin=aQ,t.appendChild(i);function n(c){for(var h=0;h")===-1){e.cue.id=s;continue}case"CUE":try{KZ(s,e.cue,e.regionList)}catch(c){e.reportOrThrowError(c),e.cue=null,e.state="BADCUE";continue}e.state="CUETEXT";continue;case"CUETEXT":var u=s.indexOf("-->")!==-1;if(!s||u&&(l=!0)){e.oncue&&e.oncue(e.cue),e.cue=null,e.state="ID";continue}e.cue.text&&(e.cue.text+=` +`),e.cue.text+=s.replace(/\u2028/g,` +`).replace(/u2029/g,` +`);continue;case"BADCUE":s||(e.state="ID");continue}}}catch(c){e.reportOrThrowError(c),e.state==="CUETEXT"&&e.cue&&e.oncue&&e.oncue(e.cue),e.cue=null,e.state=e.state==="INITIAL"?"BADWEBVTT":"BADCUE"}return this},flush:function(){var r=this;try{if(r.buffer+=r.decoder.decode(),(r.cue||r.state==="HEADER")&&(r.buffer+=` + +`,r.parse()),r.state==="INITIAL")throw new on(on.Errors.BadSignature)}catch(e){r.reportOrThrowError(e)}return r.onflush&&r.onflush(),this}};var sQ=_f,oQ="auto",lQ={"":1,lr:1,rl:1},uQ={start:1,center:1,end:1,left:1,right:1,auto:1,"line-left":1,"line-right":1};function cQ(r){if(typeof r!="string")return!1;var e=lQ[r.toLowerCase()];return e?r.toLowerCase():!1}function s2(r){if(typeof r!="string")return!1;var e=uQ[r.toLowerCase()];return e?r.toLowerCase():!1}function j6(r,e,t){this.hasBeenReset=!1;var i="",n=!1,a=r,s=e,o=t,l=null,u="",c=!0,h="auto",d="start",f="auto",p="auto",v=100,g="center";Object.defineProperties(this,{id:{enumerable:!0,get:function(){return i},set:function(m){i=""+m}},pauseOnExit:{enumerable:!0,get:function(){return n},set:function(m){n=!!m}},startTime:{enumerable:!0,get:function(){return a},set:function(m){if(typeof m!="number")throw new TypeError("Start time must be set to a number.");a=m,this.hasBeenReset=!0}},endTime:{enumerable:!0,get:function(){return s},set:function(m){if(typeof m!="number")throw new TypeError("End time must be set to a number.");s=m,this.hasBeenReset=!0}},text:{enumerable:!0,get:function(){return o},set:function(m){o=""+m,this.hasBeenReset=!0}},region:{enumerable:!0,get:function(){return l},set:function(m){l=m,this.hasBeenReset=!0}},vertical:{enumerable:!0,get:function(){return u},set:function(m){var y=cQ(m);if(y===!1)throw new SyntaxError("Vertical: an invalid or illegal direction string was specified.");u=y,this.hasBeenReset=!0}},snapToLines:{enumerable:!0,get:function(){return c},set:function(m){c=!!m,this.hasBeenReset=!0}},line:{enumerable:!0,get:function(){return h},set:function(m){if(typeof m!="number"&&m!==oQ)throw new SyntaxError("Line: an invalid number or illegal string was specified.");h=m,this.hasBeenReset=!0}},lineAlign:{enumerable:!0,get:function(){return d},set:function(m){var y=s2(m);y?(d=y,this.hasBeenReset=!0):console.warn("lineAlign: an invalid or illegal string was specified.")}},position:{enumerable:!0,get:function(){return f},set:function(m){if(m<0||m>100)throw new Error("Position must be between 0 and 100.");f=m,this.hasBeenReset=!0}},positionAlign:{enumerable:!0,get:function(){return p},set:function(m){var y=s2(m);y?(p=y,this.hasBeenReset=!0):console.warn("positionAlign: an invalid or illegal string was specified.")}},size:{enumerable:!0,get:function(){return v},set:function(m){if(m<0||m>100)throw new Error("Size must be between 0 and 100.");v=m,this.hasBeenReset=!0}},align:{enumerable:!0,get:function(){return g},set:function(m){var y=s2(m);if(!y)throw new SyntaxError("align: an invalid or illegal alignment string was specified.");g=y,this.hasBeenReset=!0}}}),this.displayState=void 0}j6.prototype.getCueAsHTML=function(){return WebVTT.convertCueToDOMTree(window,this.text)};var hQ=j6,fQ={"":!0,up:!0};function dQ(r){if(typeof r!="string")return!1;var e=fQ[r.toLowerCase()];return e?r.toLowerCase():!1}function nd(r){return typeof r=="number"&&r>=0&&r<=100}function pQ(){var r=100,e=3,t=0,i=100,n=0,a=100,s="";Object.defineProperties(this,{width:{enumerable:!0,get:function(){return r},set:function(o){if(!nd(o))throw new Error("Width must be between 0 and 100.");r=o}},lines:{enumerable:!0,get:function(){return e},set:function(o){if(typeof o!="number")throw new TypeError("Lines must be set to a number.");e=o}},regionAnchorY:{enumerable:!0,get:function(){return i},set:function(o){if(!nd(o))throw new Error("RegionAnchorX must be between 0 and 100.");i=o}},regionAnchorX:{enumerable:!0,get:function(){return t},set:function(o){if(!nd(o))throw new Error("RegionAnchorY must be between 0 and 100.");t=o}},viewportAnchorY:{enumerable:!0,get:function(){return a},set:function(o){if(!nd(o))throw new Error("ViewportAnchorY must be between 0 and 100.");a=o}},viewportAnchorX:{enumerable:!0,get:function(){return n},set:function(o){if(!nd(o))throw new Error("ViewportAnchorX must be between 0 and 100.");n=o}},scroll:{enumerable:!0,get:function(){return s},set:function(o){var l=dQ(o);l===!1?console.warn("Scroll: an invalid or illegal string was specified."):s=l}}})}var vQ=pQ,Fs=b_,sc=W6.exports={WebVTT:sQ,VTTCue:hQ,VTTRegion:vQ};Fs.vttjs=sc;Fs.WebVTT=sc.WebVTT;var gQ=sc.VTTCue,mQ=sc.VTTRegion,yQ=Fs.VTTCue,_Q=Fs.VTTRegion;sc.shim=function(){Fs.VTTCue=gQ,Fs.VTTRegion=mQ};sc.restore=function(){Fs.VTTCue=yQ,Fs.VTTRegion=_Q};Fs.VTTCue||sc.shim();var bQ=W6.exports;const rI=Bv(bQ);var iI="https://example.com",T_=function(e,t){if(/^[a-z]+:/i.test(t))return t;/^data:/.test(e)&&(e=H.location&&H.location.href||"");var i=/^\/\//.test(e),n=!H.location&&!/\/\//i.test(e);e=new H.URL(e,H.location||iI);var a=new URL(t,e);return n?a.href.slice(iI.length):i?a.href.slice(a.protocol.length):a.href},bC=function(){function r(){this.listeners={}}var e=r.prototype;return e.on=function(i,n){this.listeners[i]||(this.listeners[i]=[]),this.listeners[i].push(n)},e.off=function(i,n){if(!this.listeners[i])return!1;var a=this.listeners[i].indexOf(n);return this.listeners[i]=this.listeners[i].slice(0),this.listeners[i].splice(a,1),a>-1},e.trigger=function(i){var n=this.listeners[i];if(n)if(arguments.length===2)for(var a=n.length,s=0;s-1;t=this.buffer.indexOf(` +`))this.trigger("data",this.buffer.substring(0,t)),this.buffer=this.buffer.substring(t+1)}}const xQ=" ",o2=function(r){const e=/([0-9.]*)?@?([0-9.]*)?/.exec(r||""),t={};return e[1]&&(t.length=parseInt(e[1],10)),e[2]&&(t.offset=parseInt(e[2],10)),t},wQ=function(){const t="(?:"+"[^=]*"+")=(?:"+'"[^"]*"|[^,]*'+")";return new RegExp("(?:^|,)("+t+")")},fi=function(r){const e={};if(!r)return e;const t=r.split(wQ());let i=t.length,n;for(;i--;)t[i]!==""&&(n=/([^=]*)=(.*)/.exec(t[i]).slice(1),n[0]=n[0].replace(/^\s+|\s+$/g,""),n[1]=n[1].replace(/^\s+|\s+$/g,""),n[1]=n[1].replace(/^['"](.*)['"]$/g,"$1"),e[n[0]]=n[1]);return e},nI=r=>{const e=r.split("x"),t={};return e[0]&&(t.width=parseInt(e[0],10)),e[1]&&(t.height=parseInt(e[1],10)),t};class CQ extends bC{constructor(){super(),this.customParsers=[],this.tagMappers=[]}push(e){let t,i;if(e=e.trim(),e.length===0)return;if(e[0]!=="#"){this.trigger("data",{type:"uri",uri:e});return}this.tagMappers.reduce((a,s)=>{const o=s(e);return o===e?a:a.concat([o])},[e]).forEach(a=>{for(let s=0;sa),this.customParsers.push(a=>{if(e.exec(a))return this.trigger("data",{type:"custom",data:i(a),customType:t,segment:n}),!0})}addTagMapper({expression:e,map:t}){const i=n=>e.test(n)?t(n):n;this.tagMappers.push(i)}}const AQ=r=>r.toLowerCase().replace(/-(\w)/g,e=>e[1].toUpperCase()),oo=function(r){const e={};return Object.keys(r).forEach(function(t){e[AQ(t)]=r[t]}),e},l2=function(r){const{serverControl:e,targetDuration:t,partTargetDuration:i}=r;if(!e)return;const n="#EXT-X-SERVER-CONTROL",a="holdBack",s="partHoldBack",o=t&&t*3,l=i&&i*2;t&&!e.hasOwnProperty(a)&&(e[a]=o,this.trigger("info",{message:`${n} defaulting HOLD-BACK to targetDuration * 3 (${o}).`})),o&&e[a]{n.uri||!n.parts&&!n.preloadHints||(!n.map&&a&&(n.map=a),!n.key&&s&&(n.key=s),!n.timeline&&typeof h=="number"&&(n.timeline=h),this.manifest.preloadSegment=n)}),this.parseStream.on("data",function(v){let g,m;if(t.manifest.definitions){for(const y in t.manifest.definitions)if(v.uri&&(v.uri=v.uri.replace(`{$${y}}`,t.manifest.definitions[y])),v.attributes)for(const _ in v.attributes)typeof v.attributes[_]=="string"&&(v.attributes[_]=v.attributes[_].replace(`{$${y}}`,t.manifest.definitions[y]))}({tag(){({version(){v.version&&(this.manifest.version=v.version)},"allow-cache"(){this.manifest.allowCache=v.allowed,"allowed"in v||(this.trigger("info",{message:"defaulting allowCache to YES"}),this.manifest.allowCache=!0)},byterange(){const y={};"length"in v&&(n.byterange=y,y.length=v.length,"offset"in v||(v.offset=d)),"offset"in v&&(n.byterange=y,y.offset=v.offset),d=y.offset+y.length},endlist(){this.manifest.endList=!0},inf(){"mediaSequence"in this.manifest||(this.manifest.mediaSequence=0,this.trigger("info",{message:"defaulting media sequence to zero"})),"discontinuitySequence"in this.manifest||(this.manifest.discontinuitySequence=0,this.trigger("info",{message:"defaulting discontinuity sequence to zero"})),v.title&&(n.title=v.title),v.duration>0&&(n.duration=v.duration),v.duration===0&&(n.duration=.01,this.trigger("info",{message:"updating zero segment duration to a small value"})),this.manifest.segments=i},key(){if(!v.attributes){this.trigger("warn",{message:"ignoring key declaration without attribute list"});return}if(v.attributes.METHOD==="NONE"){s=null;return}if(!v.attributes.URI){this.trigger("warn",{message:"ignoring key declaration without URI"});return}if(v.attributes.KEYFORMAT==="com.apple.streamingkeydelivery"){this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.apple.fps.1_0"]={attributes:v.attributes};return}if(v.attributes.KEYFORMAT==="com.microsoft.playready"){this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.microsoft.playready"]={uri:v.attributes.URI};return}if(v.attributes.KEYFORMAT===c){if(["SAMPLE-AES","SAMPLE-AES-CTR","SAMPLE-AES-CENC"].indexOf(v.attributes.METHOD)===-1){this.trigger("warn",{message:"invalid key method provided for Widevine"});return}if(v.attributes.METHOD==="SAMPLE-AES-CENC"&&this.trigger("warn",{message:"SAMPLE-AES-CENC is deprecated, please use SAMPLE-AES-CTR instead"}),v.attributes.URI.substring(0,23)!=="data:text/plain;base64,"){this.trigger("warn",{message:"invalid key URI provided for Widevine"});return}if(!(v.attributes.KEYID&&v.attributes.KEYID.substring(0,2)==="0x")){this.trigger("warn",{message:"invalid key ID provided for Widevine"});return}this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.widevine.alpha"]={attributes:{schemeIdUri:v.attributes.KEYFORMAT,keyId:v.attributes.KEYID.substring(2)},pssh:X6(v.attributes.URI.split(",")[1])};return}v.attributes.METHOD||this.trigger("warn",{message:"defaulting key method to AES-128"}),s={method:v.attributes.METHOD||"AES-128",uri:v.attributes.URI},typeof v.attributes.IV<"u"&&(s.iv=v.attributes.IV)},"media-sequence"(){if(!isFinite(v.number)){this.trigger("warn",{message:"ignoring invalid media sequence: "+v.number});return}this.manifest.mediaSequence=v.number},"discontinuity-sequence"(){if(!isFinite(v.number)){this.trigger("warn",{message:"ignoring invalid discontinuity sequence: "+v.number});return}this.manifest.discontinuitySequence=v.number,h=v.number},"playlist-type"(){if(!/VOD|EVENT/.test(v.playlistType)){this.trigger("warn",{message:"ignoring unknown playlist type: "+v.playlist});return}this.manifest.playlistType=v.playlistType},map(){a={},v.uri&&(a.uri=v.uri),v.byterange&&(a.byterange=v.byterange),s&&(a.key=s)},"stream-inf"(){if(this.manifest.playlists=i,this.manifest.mediaGroups=this.manifest.mediaGroups||u,!v.attributes){this.trigger("warn",{message:"ignoring empty stream-inf attributes"});return}n.attributes||(n.attributes={}),ar(n.attributes,v.attributes)},media(){if(this.manifest.mediaGroups=this.manifest.mediaGroups||u,!(v.attributes&&v.attributes.TYPE&&v.attributes["GROUP-ID"]&&v.attributes.NAME)){this.trigger("warn",{message:"ignoring incomplete or missing media group"});return}const y=this.manifest.mediaGroups[v.attributes.TYPE];y[v.attributes["GROUP-ID"]]=y[v.attributes["GROUP-ID"]]||{},g=y[v.attributes["GROUP-ID"]],m={default:/yes/i.test(v.attributes.DEFAULT)},m.default?m.autoselect=!0:m.autoselect=/yes/i.test(v.attributes.AUTOSELECT),v.attributes.LANGUAGE&&(m.language=v.attributes.LANGUAGE),v.attributes.URI&&(m.uri=v.attributes.URI),v.attributes["INSTREAM-ID"]&&(m.instreamId=v.attributes["INSTREAM-ID"]),v.attributes.CHARACTERISTICS&&(m.characteristics=v.attributes.CHARACTERISTICS),v.attributes.FORCED&&(m.forced=/yes/i.test(v.attributes.FORCED)),g[v.attributes.NAME]=m},discontinuity(){h+=1,n.discontinuity=!0,this.manifest.discontinuityStarts.push(i.length)},"program-date-time"(){typeof this.manifest.dateTimeString>"u"&&(this.manifest.dateTimeString=v.dateTimeString,this.manifest.dateTimeObject=v.dateTimeObject),n.dateTimeString=v.dateTimeString,n.dateTimeObject=v.dateTimeObject;const{lastProgramDateTime:y}=this;this.lastProgramDateTime=new Date(v.dateTimeString).getTime(),y===null&&this.manifest.segments.reduceRight((_,b)=>(b.programDateTime=_-b.duration*1e3,b.programDateTime),this.lastProgramDateTime)},targetduration(){if(!isFinite(v.duration)||v.duration<0){this.trigger("warn",{message:"ignoring invalid target duration: "+v.duration});return}this.manifest.targetDuration=v.duration,l2.call(this,this.manifest)},start(){if(!v.attributes||isNaN(v.attributes["TIME-OFFSET"])){this.trigger("warn",{message:"ignoring start declaration without appropriate attribute list"});return}this.manifest.start={timeOffset:v.attributes["TIME-OFFSET"],precise:v.attributes.PRECISE}},"cue-out"(){n.cueOut=v.data},"cue-out-cont"(){n.cueOutCont=v.data},"cue-in"(){n.cueIn=v.data},skip(){this.manifest.skip=oo(v.attributes),this.warnOnMissingAttributes_("#EXT-X-SKIP",v.attributes,["SKIPPED-SEGMENTS"])},part(){o=!0;const y=this.manifest.segments.length,_=oo(v.attributes);n.parts=n.parts||[],n.parts.push(_),_.byterange&&(_.byterange.hasOwnProperty("offset")||(_.byterange.offset=f),f=_.byterange.offset+_.byterange.length);const b=n.parts.length-1;this.warnOnMissingAttributes_(`#EXT-X-PART #${b} for segment #${y}`,v.attributes,["URI","DURATION"]),this.manifest.renditionReports&&this.manifest.renditionReports.forEach((T,x)=>{T.hasOwnProperty("lastPart")||this.trigger("warn",{message:`#EXT-X-RENDITION-REPORT #${x} lacks required attribute(s): LAST-PART`})})},"server-control"(){const y=this.manifest.serverControl=oo(v.attributes);y.hasOwnProperty("canBlockReload")||(y.canBlockReload=!1,this.trigger("info",{message:"#EXT-X-SERVER-CONTROL defaulting CAN-BLOCK-RELOAD to false"})),l2.call(this,this.manifest),y.canSkipDateranges&&!y.hasOwnProperty("canSkipUntil")&&this.trigger("warn",{message:"#EXT-X-SERVER-CONTROL lacks required attribute CAN-SKIP-UNTIL which is required when CAN-SKIP-DATERANGES is set"})},"preload-hint"(){const y=this.manifest.segments.length,_=oo(v.attributes),b=_.type&&_.type==="PART";n.preloadHints=n.preloadHints||[],n.preloadHints.push(_),_.byterange&&(_.byterange.hasOwnProperty("offset")||(_.byterange.offset=b?f:0,b&&(f=_.byterange.offset+_.byterange.length)));const T=n.preloadHints.length-1;if(this.warnOnMissingAttributes_(`#EXT-X-PRELOAD-HINT #${T} for segment #${y}`,v.attributes,["TYPE","URI"]),!!_.type)for(let x=0;xx.id===_.id);this.manifest.dateRanges[T]=ar(this.manifest.dateRanges[T],_),p[_.id]=ar(p[_.id],_),this.manifest.dateRanges.pop()}},"independent-segments"(){this.manifest.independentSegments=!0},"i-frames-only"(){this.manifest.iFramesOnly=!0,this.requiredCompatibilityversion(this.manifest.version,4)},"content-steering"(){this.manifest.contentSteering=oo(v.attributes),this.warnOnMissingAttributes_("#EXT-X-CONTENT-STEERING",v.attributes,["SERVER-URI"])},define(){this.manifest.definitions=this.manifest.definitions||{};const y=(_,b)=>{if(_ in this.manifest.definitions){this.trigger("error",{message:`EXT-X-DEFINE: Duplicate name ${_}`});return}this.manifest.definitions[_]=b};if("QUERYPARAM"in v.attributes){if("NAME"in v.attributes||"IMPORT"in v.attributes){this.trigger("error",{message:"EXT-X-DEFINE: Invalid attributes"});return}const _=this.params.get(v.attributes.QUERYPARAM);if(!_){this.trigger("error",{message:`EXT-X-DEFINE: No query param ${v.attributes.QUERYPARAM}`});return}y(v.attributes.QUERYPARAM,decodeURIComponent(_));return}if("NAME"in v.attributes){if("IMPORT"in v.attributes){this.trigger("error",{message:"EXT-X-DEFINE: Invalid attributes"});return}if(!("VALUE"in v.attributes)||typeof v.attributes.VALUE!="string"){this.trigger("error",{message:`EXT-X-DEFINE: No value for ${v.attributes.NAME}`});return}y(v.attributes.NAME,v.attributes.VALUE);return}if("IMPORT"in v.attributes){if(!this.mainDefinitions[v.attributes.IMPORT]){this.trigger("error",{message:`EXT-X-DEFINE: No value ${v.attributes.IMPORT} to import, or IMPORT used on main playlist`});return}y(v.attributes.IMPORT,this.mainDefinitions[v.attributes.IMPORT]);return}this.trigger("error",{message:"EXT-X-DEFINE: No attribute"})},"i-frame-playlist"(){this.manifest.iFramePlaylists.push({attributes:v.attributes,uri:v.uri,timeline:h}),this.warnOnMissingAttributes_("#EXT-X-I-FRAME-STREAM-INF",v.attributes,["BANDWIDTH","URI"])}}[v.tagType]||l).call(t)},uri(){n.uri=v.uri,i.push(n),this.manifest.targetDuration&&!("duration"in n)&&(this.trigger("warn",{message:"defaulting segment duration to the target duration"}),n.duration=this.manifest.targetDuration),s&&(n.key=s),n.timeline=h,a&&(n.map=a),f=0,this.lastProgramDateTime!==null&&(n.programDateTime=this.lastProgramDateTime,this.lastProgramDateTime+=n.duration*1e3),n={}},comment(){},custom(){v.segment?(n.custom=n.custom||{},n.custom[v.customType]=v.data):(this.manifest.custom=this.manifest.custom||{},this.manifest.custom[v.customType]=v.data)}})[v.type].call(t)})}requiredCompatibilityversion(e,t){(eh&&(c-=h,c-=h,c-=Xr(2))}return Number(c)},FQ=function(e,t){var i={},n=i.le,a=n===void 0?!1:n;(typeof e!="bigint"&&typeof e!="number"||typeof e=="number"&&e!==e)&&(e=0),e=Xr(e);for(var s=OQ(e),o=new Uint8Array(new ArrayBuffer(s)),l=0;l=t.length&&u.call(t,function(c,h){var d=l[h]?l[h]&e[s+h]:e[s+h];return c===d})},VQ=function(e,t,i){t.forEach(function(n){for(var a in e.mediaGroups[n])for(var s in e.mediaGroups[n][a]){var o=e.mediaGroups[n][a][s];i(o,n,a,s)}})},ol={},Qs={};function zQ(r,e,t){if(t===void 0&&(t=Array.prototype),r&&typeof t.find=="function")return t.find.call(r,e);for(var i=0;i=0&&r=0){for(var n=e.length-1;i0},lookupPrefix:function(r){for(var e=this;e;){var t=e._nsMap;if(t){for(var i in t)if(Object.prototype.hasOwnProperty.call(t,i)&&t[i]===r)return i}e=e.nodeType==Vh?e.ownerDocument:e.parentNode}return null},lookupNamespaceURI:function(r){for(var e=this;e;){var t=e._nsMap;if(t&&Object.prototype.hasOwnProperty.call(t,r))return t[r];e=e.nodeType==Vh?e.ownerDocument:e.parentNode}return null},isDefaultNamespace:function(r){var e=this.lookupPrefix(r);return e==null}};function fO(r){return r=="<"&&"<"||r==">"&&">"||r=="&"&&"&"||r=='"'&&"""||"&#"+r.charCodeAt()+";"}Fv(Qi,Rt);Fv(Qi,Rt.prototype);function Wp(r,e){if(e(r))return!0;if(r=r.firstChild)do if(Wp(r,e))return!0;while(r=r.nextSibling)}function Uv(){this.ownerDocument=this}function YQ(r,e,t){r&&r._inc++;var i=t.namespaceURI;i===$p.XMLNS&&(e._nsMap[t.prefix?t.localName:""]=t.value)}function dO(r,e,t,i){r&&r._inc++;var n=t.namespaceURI;n===$p.XMLNS&&delete e._nsMap[t.prefix?t.localName:""]}function xC(r,e,t){if(r&&r._inc){r._inc++;var i=e.childNodes;if(t)i[i.length++]=t;else{for(var n=e.firstChild,a=0;n;)i[a++]=n,n=n.nextSibling;i.length=a,delete i[i.length]}}}function pO(r,e){var t=e.previousSibling,i=e.nextSibling;return t?t.nextSibling=i:r.firstChild=i,i?i.previousSibling=t:r.lastChild=t,e.parentNode=null,e.previousSibling=null,e.nextSibling=null,xC(r.ownerDocument,r),e}function KQ(r){return r&&(r.nodeType===Rt.DOCUMENT_NODE||r.nodeType===Rt.DOCUMENT_FRAGMENT_NODE||r.nodeType===Rt.ELEMENT_NODE)}function ZQ(r){return r&&(Ka(r)||wC(r)||Vs(r)||r.nodeType===Rt.DOCUMENT_FRAGMENT_NODE||r.nodeType===Rt.COMMENT_NODE||r.nodeType===Rt.PROCESSING_INSTRUCTION_NODE)}function Vs(r){return r&&r.nodeType===Rt.DOCUMENT_TYPE_NODE}function Ka(r){return r&&r.nodeType===Rt.ELEMENT_NODE}function wC(r){return r&&r.nodeType===Rt.TEXT_NODE}function hI(r,e){var t=r.childNodes||[];if(Ya(t,Ka)||Vs(e))return!1;var i=Ya(t,Vs);return!(e&&i&&t.indexOf(i)>t.indexOf(e))}function fI(r,e){var t=r.childNodes||[];function i(a){return Ka(a)&&a!==e}if(Ya(t,i))return!1;var n=Ya(t,Vs);return!(e&&n&&t.indexOf(n)>t.indexOf(e))}function QQ(r,e,t){if(!KQ(r))throw new gr(Oi,"Unexpected parent node type "+r.nodeType);if(t&&t.parentNode!==r)throw new gr(uO,"child not in parent");if(!ZQ(e)||Vs(e)&&r.nodeType!==Rt.DOCUMENT_NODE)throw new gr(Oi,"Unexpected node type "+e.nodeType+" for parent node type "+r.nodeType)}function JQ(r,e,t){var i=r.childNodes||[],n=e.childNodes||[];if(e.nodeType===Rt.DOCUMENT_FRAGMENT_NODE){var a=n.filter(Ka);if(a.length>1||Ya(n,wC))throw new gr(Oi,"More than one element or text in fragment");if(a.length===1&&!hI(r,t))throw new gr(Oi,"Element in fragment can not be inserted before doctype")}if(Ka(e)&&!hI(r,t))throw new gr(Oi,"Only one element can be added and only after doctype");if(Vs(e)){if(Ya(i,Vs))throw new gr(Oi,"Only one doctype is allowed");var s=Ya(i,Ka);if(t&&i.indexOf(s)1||Ya(n,wC))throw new gr(Oi,"More than one element or text in fragment");if(a.length===1&&!fI(r,t))throw new gr(Oi,"Element in fragment can not be inserted before doctype")}if(Ka(e)&&!fI(r,t))throw new gr(Oi,"Only one element can be added and only after doctype");if(Vs(e)){let l=function(u){return Vs(u)&&u!==t};var o=l;if(Ya(i,l))throw new gr(Oi,"Only one doctype is allowed");var s=Ya(i,Ka);if(t&&i.indexOf(s)0&&Wp(t.documentElement,function(n){if(n!==t&&n.nodeType===da){var a=n.getAttribute("class");if(a){var s=r===a;if(!s){var o=oI(a);s=e.every(qQ(o))}s&&i.push(n)}}}),i})},createElement:function(r){var e=new ju;e.ownerDocument=this,e.nodeName=r,e.tagName=r,e.localName=r,e.childNodes=new Ms;var t=e.attributes=new U0;return t._ownerElement=e,e},createDocumentFragment:function(){var r=new w_;return r.ownerDocument=this,r.childNodes=new Ms,r},createTextNode:function(r){var e=new CC;return e.ownerDocument=this,e.appendData(r),e},createComment:function(r){var e=new AC;return e.ownerDocument=this,e.appendData(r),e},createCDATASection:function(r){var e=new DC;return e.ownerDocument=this,e.appendData(r),e},createProcessingInstruction:function(r,e){var t=new IC;return t.ownerDocument=this,t.tagName=t.nodeName=t.target=r,t.nodeValue=t.data=e,t},createAttribute:function(r){var e=new z0;return e.ownerDocument=this,e.name=r,e.nodeName=r,e.localName=r,e.specified=!0,e},createEntityReference:function(r){var e=new EC;return e.ownerDocument=this,e.nodeName=r,e},createElementNS:function(r,e){var t=new ju,i=e.split(":"),n=t.attributes=new U0;return t.childNodes=new Ms,t.ownerDocument=this,t.nodeName=e,t.tagName=e,t.namespaceURI=r,i.length==2?(t.prefix=i[0],t.localName=i[1]):t.localName=e,n._ownerElement=t,t},createAttributeNS:function(r,e){var t=new z0,i=e.split(":");return t.ownerDocument=this,t.nodeName=e,t.name=e,t.namespaceURI=r,t.specified=!0,i.length==2?(t.prefix=i[0],t.localName=i[1]):t.localName=e,t}};Zi(Uv,Rt);function ju(){this._nsMap={}}ju.prototype={nodeType:da,hasAttribute:function(r){return this.getAttributeNode(r)!=null},getAttribute:function(r){var e=this.getAttributeNode(r);return e&&e.value||""},getAttributeNode:function(r){return this.attributes.getNamedItem(r)},setAttribute:function(r,e){var t=this.ownerDocument.createAttribute(r);t.value=t.nodeValue=""+e,this.setAttributeNode(t)},removeAttribute:function(r){var e=this.getAttributeNode(r);e&&this.removeAttributeNode(e)},appendChild:function(r){return r.nodeType===Us?this.insertBefore(r,null):eJ(this,r)},setAttributeNode:function(r){return this.attributes.setNamedItem(r)},setAttributeNodeNS:function(r){return this.attributes.setNamedItemNS(r)},removeAttributeNode:function(r){return this.attributes.removeNamedItem(r.nodeName)},removeAttributeNS:function(r,e){var t=this.getAttributeNodeNS(r,e);t&&this.removeAttributeNode(t)},hasAttributeNS:function(r,e){return this.getAttributeNodeNS(r,e)!=null},getAttributeNS:function(r,e){var t=this.getAttributeNodeNS(r,e);return t&&t.value||""},setAttributeNS:function(r,e,t){var i=this.ownerDocument.createAttributeNS(r,e);i.value=i.nodeValue=""+t,this.setAttributeNode(i)},getAttributeNodeNS:function(r,e){return this.attributes.getNamedItemNS(r,e)},getElementsByTagName:function(r){return new zh(this,function(e){var t=[];return Wp(e,function(i){i!==e&&i.nodeType==da&&(r==="*"||i.tagName==r)&&t.push(i)}),t})},getElementsByTagNameNS:function(r,e){return new zh(this,function(t){var i=[];return Wp(t,function(n){n!==t&&n.nodeType===da&&(r==="*"||n.namespaceURI===r)&&(e==="*"||n.localName==e)&&i.push(n)}),i})}};Uv.prototype.getElementsByTagName=ju.prototype.getElementsByTagName;Uv.prototype.getElementsByTagNameNS=ju.prototype.getElementsByTagNameNS;Zi(ju,Rt);function z0(){}z0.prototype.nodeType=Vh;Zi(z0,Rt);function Vv(){}Vv.prototype={data:"",substringData:function(r,e){return this.data.substring(r,r+e)},appendData:function(r){r=this.data+r,this.nodeValue=this.data=r,this.length=r.length},insertData:function(r,e){this.replaceData(r,0,e)},appendChild:function(r){throw new Error(Hr[Oi])},deleteData:function(r,e){this.replaceData(r,e,"")},replaceData:function(r,e,t){var i=this.data.substring(0,r),n=this.data.substring(r+e);t=i+t+n,this.nodeValue=this.data=t,this.length=t.length}};Zi(Vv,Rt);function CC(){}CC.prototype={nodeName:"#text",nodeType:F0,splitText:function(r){var e=this.data,t=e.substring(r);e=e.substring(0,r),this.data=this.nodeValue=e,this.length=e.length;var i=this.ownerDocument.createTextNode(t);return this.parentNode&&this.parentNode.insertBefore(i,this.nextSibling),i}};Zi(CC,Vv);function AC(){}AC.prototype={nodeName:"#comment",nodeType:sO};Zi(AC,Vv);function DC(){}DC.prototype={nodeName:"#cdata-section",nodeType:iO};Zi(DC,Vv);function x_(){}x_.prototype.nodeType=lO;Zi(x_,Rt);function gO(){}gO.prototype.nodeType=XQ;Zi(gO,Rt);function mO(){}mO.prototype.nodeType=jQ;Zi(mO,Rt);function EC(){}EC.prototype.nodeType=nO;Zi(EC,Rt);function w_(){}w_.prototype.nodeName="#document-fragment";w_.prototype.nodeType=Us;Zi(w_,Rt);function IC(){}IC.prototype.nodeType=aO;Zi(IC,Rt);function yO(){}yO.prototype.serializeToString=function(r,e,t){return _O.call(r,e,t)};Rt.prototype.toString=_O;function _O(r,e){var t=[],i=this.nodeType==9&&this.documentElement||this,n=i.prefix,a=i.namespaceURI;if(a&&n==null){var n=i.lookupPrefix(a);if(n==null)var s=[{namespace:a,prefix:null}]}return uh(this,t,r,e,s),t.join("")}function dI(r,e,t){var i=r.prefix||"",n=r.namespaceURI;if(!n||i==="xml"&&n===$p.XML||n===$p.XMLNS)return!1;for(var a=t.length;a--;){var s=t[a];if(s.prefix===i)return s.namespace!==n}return!0}function c2(r,e,t){r.push(" ",e,'="',t.replace(/[<>&"\t\n\r]/g,fO),'"')}function uh(r,e,t,i,n){if(n||(n=[]),i)if(r=i(r),r){if(typeof r=="string"){e.push(r);return}}else return;switch(r.nodeType){case da:var a=r.attributes,s=a.length,m=r.firstChild,o=r.tagName;t=$p.isHTML(r.namespaceURI)||t;var l=o;if(!t&&!r.prefix&&r.namespaceURI){for(var u,c=0;c=0;h--){var d=n[h];if(d.prefix===""&&d.namespace===r.namespaceURI){u=d.namespace;break}}if(u!==r.namespaceURI)for(var h=n.length-1;h>=0;h--){var d=n[h];if(d.namespace===r.namespaceURI){d.prefix&&(l=d.prefix+":"+o);break}}}e.push("<",l);for(var f=0;f"),t&&/^script$/i.test(o))for(;m;)m.data?e.push(m.data):uh(m,e,t,i,n.slice()),m=m.nextSibling;else for(;m;)uh(m,e,t,i,n.slice()),m=m.nextSibling;e.push("")}else e.push("/>");return;case oO:case Us:for(var m=r.firstChild;m;)uh(m,e,t,i,n.slice()),m=m.nextSibling;return;case Vh:return c2(e,r.name,r.value);case F0:return e.push(r.data.replace(/[<&>]/g,fO));case iO:return e.push("");case sO:return e.push("");case lO:var y=r.publicId,_=r.systemId;if(e.push("");else if(_&&_!=".")e.push(" SYSTEM ",_,">");else{var b=r.internalSubset;b&&e.push(" [",b,"]"),e.push(">")}return;case aO:return e.push("");case nO:return e.push("&",r.nodeName,";");default:e.push("??",r.nodeName)}}function bO(r,e,t){var i;switch(e.nodeType){case da:i=e.cloneNode(!1),i.ownerDocument=r;case Us:break;case Vh:t=!0;break}if(i||(i=e.cloneNode(!1)),i.ownerDocument=r,i.parentNode=null,t)for(var n=e.firstChild;n;)i.appendChild(bO(r,n,t)),n=n.nextSibling;return i}function xT(r,e,t){var i=new e.constructor;for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var a=e[n];typeof a!="object"&&a!=i[n]&&(i[n]=a)}switch(e.childNodes&&(i.childNodes=new Ms),i.ownerDocument=r,i.nodeType){case da:var s=e.attributes,o=i.attributes=new U0,l=s.length;o._ownerElement=i;for(var u=0;u",lt:"<",quot:'"'}),r.HTML_ENTITIES=e({Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"⁡",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",AMP:"&",amp:"&",And:"⩓",and:"∧",andand:"⩕",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsd:"∡",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",ap:"≈",apacir:"⩯",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"⁡",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",Barwed:"⌆",barwed:"⌅",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",Because:"∵",because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxDL:"╗",boxDl:"╖",boxdL:"╕",boxdl:"┐",boxDR:"╔",boxDr:"╓",boxdR:"╒",boxdr:"┌",boxH:"═",boxh:"─",boxHD:"╦",boxHd:"╤",boxhD:"╥",boxhd:"┬",boxHU:"╩",boxHu:"╧",boxhU:"╨",boxhu:"┴",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxUL:"╝",boxUl:"╜",boxuL:"╛",boxul:"┘",boxUR:"╚",boxUr:"╙",boxuR:"╘",boxur:"└",boxV:"║",boxv:"│",boxVH:"╬",boxVh:"╫",boxvH:"╪",boxvh:"┼",boxVL:"╣",boxVl:"╢",boxvL:"╡",boxvl:"┤",boxVR:"╠",boxVr:"╟",boxvR:"╞",boxvr:"├",bprime:"‵",Breve:"˘",breve:"˘",brvbar:"¦",Bscr:"ℬ",bscr:"𝒷",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsol:"\\",bsolb:"⧅",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",Cap:"⋒",cap:"∩",capand:"⩄",capbrcup:"⩉",capcap:"⩋",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",CenterDot:"·",centerdot:"·",Cfr:"ℭ",cfr:"𝔠",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",cir:"○",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",Colon:"∷",colon:":",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",Conint:"∯",conint:"∮",ContourIntegral:"∮",Copf:"ℂ",copf:"𝕔",coprod:"∐",Coproduct:"∐",COPY:"©",copy:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",Cross:"⨯",cross:"✗",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",Cup:"⋓",cup:"∪",cupbrcap:"⩈",CupCap:"≍",cupcap:"⩆",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",Dagger:"‡",dagger:"†",daleth:"ℸ",Darr:"↡",dArr:"⇓",darr:"↓",dash:"‐",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",DD:"ⅅ",dd:"ⅆ",ddagger:"‡",ddarr:"⇊",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",Diamond:"⋄",diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrow:"↓",Downarrow:"⇓",downarrow:"↓",DownArrowBar:"⤓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVector:"↽",DownLeftVectorBar:"⥖",DownRightTeeVector:"⥟",DownRightVector:"⇁",DownRightVectorBar:"⥗",DownTee:"⊤",DownTeeArrow:"↧",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",ecir:"≖",Ecirc:"Ê",ecirc:"ê",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",eDot:"≑",edot:"ė",ee:"ⅇ",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp:" ",emsp13:" ",emsp14:" ",ENG:"Ŋ",eng:"ŋ",ensp:" ",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",Escr:"ℰ",escr:"ℯ",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",ExponentialE:"ⅇ",exponentiale:"ⅇ",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",Ffr:"𝔉",ffr:"𝔣",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",ForAll:"∀",forall:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",Fscr:"ℱ",fscr:"𝒻",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",gE:"≧",ge:"≥",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",ges:"⩾",gescc:"⪩",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",Gg:"⋙",gg:"≫",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gl:"≷",gla:"⪥",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gnE:"≩",gne:"⪈",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"ℊ",gsim:"≳",gsime:"⪎",gsiml:"⪐",Gt:"≫",GT:">",gt:">",gtcc:"⪧",gtcir:"⩺",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",HARDcy:"Ъ",hardcy:"ъ",hArr:"⇔",harr:"↔",harrcir:"⥈",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",Hfr:"ℌ",hfr:"𝔥",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",Hopf:"ℍ",hopf:"𝕙",horbar:"―",HorizontalLine:"─",Hscr:"ℋ",hscr:"𝒽",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",Iacute:"Í",iacute:"í",ic:"⁣",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",Ifr:"ℑ",ifr:"𝔦",Igrave:"Ì",igrave:"ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"IJ",ijlig:"ij",Im:"ℑ",Imacr:"Ī",imacr:"ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",imof:"⊷",imped:"Ƶ",Implies:"⇒",in:"∈",incare:"℅",infin:"∞",infintie:"⧝",inodot:"ı",Int:"∬",int:"∫",intcal:"⊺",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"⁣",InvisibleTimes:"⁢",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",Iscr:"ℐ",iscr:"𝒾",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"⁢",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"ℒ",Lambda:"Λ",lambda:"λ",Lang:"⟪",lang:"⟨",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",Larr:"↞",lArr:"⇐",larr:"←",larrb:"⇤",larrbfs:"⤟",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",lat:"⪫",lAtail:"⤛",latail:"⤙",late:"⪭",lates:"⪭︀",lBarr:"⤎",lbarr:"⤌",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",lE:"≦",le:"≤",LeftAngleBracket:"⟨",LeftArrow:"←",Leftarrow:"⇐",leftarrow:"←",LeftArrowBar:"⇤",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVector:"⇃",LeftDownVectorBar:"⥙",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrow:"↔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTee:"⊣",LeftTeeArrow:"↤",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangle:"⊲",LeftTriangleBar:"⧏",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVector:"↿",LeftUpVectorBar:"⥘",LeftVector:"↼",LeftVectorBar:"⥒",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",les:"⩽",lescc:"⪨",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",Ll:"⋘",ll:"≪",llarr:"⇇",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoust:"⎰",lmoustache:"⎰",lnap:"⪉",lnapprox:"⪉",lnE:"≨",lne:"⪇",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftarrow:"⟵",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longleftrightarrow:"⟷",longmapsto:"⟼",LongRightArrow:"⟶",Longrightarrow:"⟹",longrightarrow:"⟶",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"‎",lrtri:"⊿",lsaquo:"‹",Lscr:"ℒ",lscr:"𝓁",Lsh:"↰",lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",Lstrok:"Ł",lstrok:"ł",Lt:"≪",LT:"<",lt:"<",ltcc:"⪦",ltcir:"⩹",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",mid:"∣",midast:"*",midcir:"⫰",middot:"·",minus:"−",minusb:"⊟",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",Mscr:"ℳ",mscr:"𝓂",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natur:"♮",natural:"♮",naturals:"ℕ",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"–",ne:"≠",nearhk:"⤤",neArr:"⇗",nearr:"↗",nearrow:"↗",nedot:"≐̸",NegativeMediumSpace:"​",NegativeThickSpace:"​",NegativeThinSpace:"​",NegativeVeryThinSpace:"​",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:` +`,nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nhArr:"⇎",nharr:"↮",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlArr:"⇍",nlarr:"↚",nldr:"‥",nlE:"≦̸",nle:"≰",nLeftarrow:"⇍",nleftarrow:"↚",nLeftrightarrow:"⇎",nleftrightarrow:"↮",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"⁠",NonBreakingSpace:" ",Nopf:"ℕ",nopf:"𝕟",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangle:"⋪",NotLeftTriangleBar:"⧏̸",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangle:"⋫",NotRightTriangleBar:"⧐̸",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",npar:"∦",nparallel:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",npre:"⪯̸",nprec:"⊀",npreceq:"⪯̸",nrArr:"⇏",nrarr:"↛",nrarrc:"⤳̸",nrarrw:"↝̸",nRightarrow:"⇏",nrightarrow:"↛",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nVDash:"⊯",nVdash:"⊮",nvDash:"⊭",nvdash:"⊬",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwArr:"⇖",nwarr:"↖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",ocir:"⊚",Ocirc:"Ô",ocirc:"ô",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",Or:"⩔",or:"∨",orarr:"↻",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"ℴ",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",Otimes:"⨷",otimes:"⊗",otimesas:"⨶",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",par:"∥",para:"¶",parallel:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plus:"+",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",Popf:"ℙ",popf:"𝕡",pound:"£",Pr:"⪻",pr:"≺",prap:"⪷",prcue:"≼",prE:"⪳",pre:"⪯",prec:"≺",precapprox:"⪷",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",precsim:"≾",Prime:"″",prime:"′",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportion:"∷",Proportional:"∝",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:" ",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",Qopf:"ℚ",qopf:"𝕢",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",QUOT:'"',quot:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",Rang:"⟫",rang:"⟩",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",Rarr:"↠",rArr:"⇒",rarr:"→",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",rAtail:"⤜",ratail:"⤚",ratio:"∶",rationals:"ℚ",RBarr:"⤐",rBarr:"⤏",rbarr:"⤍",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",Re:"ℜ",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",rect:"▭",REG:"®",reg:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",Rfr:"ℜ",rfr:"𝔯",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩",RightArrow:"→",Rightarrow:"⇒",rightarrow:"→",RightArrowBar:"⇥",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVector:"⇂",RightDownVectorBar:"⥕",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTee:"⊢",RightTeeArrow:"↦",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangle:"⊳",RightTriangleBar:"⧐",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVector:"↾",RightUpVectorBar:"⥔",RightVector:"⇀",RightVectorBar:"⥓",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"‏",rmoust:"⎱",rmoustache:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",Ropf:"ℝ",ropf:"𝕣",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",Rscr:"ℛ",rscr:"𝓇",Rsh:"↱",rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"‚",Sc:"⪼",sc:"≻",scap:"⪸",Scaron:"Š",scaron:"š",sccue:"≽",scE:"⪴",sce:"⪰",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdot:"⋅",sdotb:"⊡",sdote:"⩦",searhk:"⤥",seArr:"⇘",searr:"↘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",sol:"/",solb:"⧄",solbar:"⌿",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",squ:"□",Square:"□",square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",Sub:"⋐",sub:"⊂",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",Subset:"⋐",subset:"⊂",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succ:"≻",succapprox:"⪸",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",Sum:"∑",sum:"∑",sung:"♪",Sup:"⋑",sup:"⊃",sup1:"¹",sup2:"²",sup3:"³",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",Supset:"⋑",supset:"⊃",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swArr:"⇙",swarr:"↙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:" ",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",Therefore:"∴",therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:"  ",thinsp:" ",ThinSpace:" ",thkap:"≈",thksim:"∼",THORN:"Þ",thorn:"þ",Tilde:"∼",tilde:"˜",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",times:"×",timesb:"⊠",timesbar:"⨱",timesd:"⨰",tint:"∭",toea:"⤨",top:"⊤",topbot:"⌶",topcir:"⫱",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",TRADE:"™",trade:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",Uarr:"↟",uArr:"⇑",uarr:"↑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrow:"↑",Uparrow:"⇑",uparrow:"↑",UpArrowBar:"⤒",UpArrowDownArrow:"⇅",UpDownArrow:"↕",Updownarrow:"⇕",updownarrow:"↕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",Upsi:"ϒ",upsi:"υ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTee:"⊥",UpTeeArrow:"↥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",vArr:"⇕",varr:"↕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",Vbar:"⫫",vBar:"⫨",vBarv:"⫩",Vcy:"В",vcy:"в",VDash:"⊫",Vdash:"⊩",vDash:"⊨",vdash:"⊢",Vdashl:"⫦",Vee:"⋁",vee:"∨",veebar:"⊻",veeeq:"≚",vellip:"⋮",Verbar:"‖",verbar:"|",Vert:"‖",vert:"|",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",Wedge:"⋀",wedge:"∧",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xhArr:"⟺",xharr:"⟷",Xi:"Ξ",xi:"ξ",xlArr:"⟸",xlarr:"⟵",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrArr:"⟹",xrarr:"⟶",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",Yuml:"Ÿ",yuml:"ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"ℨ",ZeroWidthSpace:"​",Zeta:"Ζ",zeta:"ζ",Zfr:"ℨ",zfr:"𝔷",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",Zopf:"ℤ",zopf:"𝕫",Zscr:"𝒵",zscr:"𝓏",zwj:"‍",zwnj:"‌"}),r.entityMap=r.HTML_ENTITIES})(TO);var PC={},qp=Qs.NAMESPACE,wT=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,pI=new RegExp("[\\-\\.0-9"+wT.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"),vI=new RegExp("^"+wT.source+pI.source+"*(?::"+wT.source+pI.source+"*)?$"),ad=0,lo=1,wc=2,sd=3,Cc=4,Ac=5,od=6,Ug=7;function Gh(r,e){this.message=r,this.locator=e,Error.captureStackTrace&&Error.captureStackTrace(this,Gh)}Gh.prototype=new Error;Gh.prototype.name=Gh.name;function xO(){}xO.prototype={parse:function(r,e,t){var i=this.domBuilder;i.startDocument(),wO(e,e={}),tJ(r,e,t,i,this.errorHandler),i.endDocument()}};function tJ(r,e,t,i,n){function a(U){if(U>65535){U-=65536;var $=55296+(U>>10),q=56320+(U&1023);return String.fromCharCode($,q)}else return String.fromCharCode(U)}function s(U){var $=U.slice(1,-1);return Object.hasOwnProperty.call(t,$)?t[$]:$.charAt(0)==="#"?a(parseInt($.substr(1).replace("x","0x"))):(n.error("entity not found:"+U),U)}function o(U){if(U>v){var $=r.substring(v,U).replace(/&#?\w+;/g,s);d&&l(v),i.characters($,0,U-v),v=U}}function l(U,$){for(;U>=c&&($=h.exec(r));)u=$.index,c=u+$[0].length,d.lineNumber++;d.columnNumber=U-u+1}for(var u=0,c=0,h=/.*(?:\r\n?|\n)|.*$/g,d=i.locator,f=[{currentNSMap:e}],p={},v=0;;){try{var g=r.indexOf("<",v);if(g<0){if(!r.substr(v).match(/^\s*$/)){var m=i.doc,y=m.createTextNode(r.substr(v));m.appendChild(y),i.currentElement=y}return}switch(g>v&&o(g),r.charAt(g+1)){case"/":var L=r.indexOf(">",g+3),_=r.substring(g+2,L).replace(/[ \t\n\r]+$/g,""),b=f.pop();L<0?(_=r.substring(g+2).replace(/[\s<].*/,""),n.error("end tag name: "+_+" is not complete:"+b.tagName),L=g+1+_.length):_.match(/\sv?v=L:o(Math.max(g,v)+1)}}function gI(r,e){return e.lineNumber=r.lineNumber,e.columnNumber=r.columnNumber,e}function rJ(r,e,t,i,n,a){function s(d,f,p){t.attributeNames.hasOwnProperty(d)&&a.fatalError("Attribute "+d+" redefined"),t.addValue(d,f.replace(/[\t\n\r]/g," ").replace(/&#?\w+;/g,n),p)}for(var o,l,u=++e,c=ad;;){var h=r.charAt(u);switch(h){case"=":if(c===lo)o=r.slice(e,u),c=sd;else if(c===wc)c=sd;else throw new Error("attribute equal must after attrName");break;case"'":case'"':if(c===sd||c===lo)if(c===lo&&(a.warning('attribute value must after "="'),o=r.slice(e,u)),e=u+1,u=r.indexOf(h,e),u>0)l=r.slice(e,u),s(o,l,e-1),c=Ac;else throw new Error("attribute value no end '"+h+"' match");else if(c==Cc)l=r.slice(e,u),s(o,l,e),a.warning('attribute "'+o+'" missed start quot('+h+")!!"),e=u+1,c=Ac;else throw new Error('attribute value must after "="');break;case"/":switch(c){case ad:t.setTagName(r.slice(e,u));case Ac:case od:case Ug:c=Ug,t.closed=!0;case Cc:case lo:break;case wc:t.closed=!0;break;default:throw new Error("attribute invalid close char('/')")}break;case"":return a.error("unexpected end of input"),c==ad&&t.setTagName(r.slice(e,u)),u;case">":switch(c){case ad:t.setTagName(r.slice(e,u));case Ac:case od:case Ug:break;case Cc:case lo:l=r.slice(e,u),l.slice(-1)==="/"&&(t.closed=!0,l=l.slice(0,-1));case wc:c===wc&&(l=o),c==Cc?(a.warning('attribute "'+l+'" missed quot(")!'),s(o,l,e)):((!qp.isHTML(i[""])||!l.match(/^(?:disabled|checked|selected)$/i))&&a.warning('attribute "'+l+'" missed value!! "'+l+'" instead!!'),s(l,l,e));break;case sd:throw new Error("attribute value missed!!")}return u;case"€":h=" ";default:if(h<=" ")switch(c){case ad:t.setTagName(r.slice(e,u)),c=od;break;case lo:o=r.slice(e,u),c=wc;break;case Cc:var l=r.slice(e,u);a.warning('attribute "'+l+'" missed quot(")!!'),s(o,l,e);case Ac:c=od;break}else switch(c){case wc:t.tagName,(!qp.isHTML(i[""])||!o.match(/^(?:disabled|checked|selected)$/i))&&a.warning('attribute "'+o+'" missed value!! "'+o+'" instead2!!'),s(o,o,e),e=u,c=lo;break;case Ac:a.warning('attribute space is required"'+o+'"!!');case od:c=lo,e=u;break;case sd:c=Cc,e=u;break;case Ug:throw new Error("elements closed character '/' and '>' must be connected to")}}u++}}function mI(r,e,t){for(var i=r.tagName,n=null,h=r.length;h--;){var a=r[h],s=a.qName,o=a.value,d=s.indexOf(":");if(d>0)var l=a.prefix=s.slice(0,d),u=s.slice(d+1),c=l==="xmlns"&&u;else u=s,l=null,c=s==="xmlns"&&"";a.localName=u,c!==!1&&(n==null&&(n={},wO(t,t={})),t[c]=n[c]=o,a.uri=qp.XMLNS,e.startPrefixMapping(c,o))}for(var h=r.length;h--;){a=r[h];var l=a.prefix;l&&(l==="xml"&&(a.uri=qp.XML),l!=="xmlns"&&(a.uri=t[l||""]))}var d=i.indexOf(":");d>0?(l=r.prefix=i.slice(0,d),u=r.localName=i.slice(d+1)):(l=null,u=r.localName=i);var f=r.uri=t[l||""];if(e.startElement(f,u,i,r),r.closed){if(e.endElement(f,u,i),n)for(l in n)Object.prototype.hasOwnProperty.call(n,l)&&e.endPrefixMapping(l)}else return r.currentNSMap=t,r.localNSMap=n,!0}function iJ(r,e,t,i,n){if(/^(?:script|textarea)$/i.test(t)){var a=r.indexOf("",e),s=r.substring(e+1,a);if(/[&<]/.test(s))return/^script$/i.test(t)?(n.characters(s,0,s.length),a):(s=s.replace(/&#?\w+;/g,i),n.characters(s,0,s.length),a)}return e+1}function nJ(r,e,t,i){var n=i[t];return n==null&&(n=r.lastIndexOf(""),n",e+4);return a>e?(t.comment(r,e+4,a-e-4),a+3):(i.error("Unclosed comment"),-1)}else return-1;default:if(r.substr(e+3,6)=="CDATA["){var a=r.indexOf("]]>",e+9);return t.startCDATA(),t.characters(r,e+9,a-e-9),t.endCDATA(),a+3}var s=oJ(r,e),o=s.length;if(o>1&&/!doctype/i.test(s[0][0])){var l=s[1][0],u=!1,c=!1;o>3&&(/^public$/i.test(s[2][0])?(u=s[3][0],c=o>4&&s[4][0]):/^system$/i.test(s[2][0])&&(c=s[3][0]));var h=s[o-1];return t.startDTD(l,u,c),t.endDTD(),h.index+h[0].length}}return-1}function sJ(r,e,t){var i=r.indexOf("?>",e);if(i){var n=r.substring(e,i).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);return n?(n[0].length,t.processingInstruction(n[1],n[2]),i+2):-1}return-1}function CO(){this.attributeNames={}}CO.prototype={setTagName:function(r){if(!vI.test(r))throw new Error("invalid tagName:"+r);this.tagName=r},addValue:function(r,e,t){if(!vI.test(r))throw new Error("invalid attribute:"+r);this.attributeNames[r]=this.length,this[this.length++]={qName:r,value:e,offset:t}},length:0,getLocalName:function(r){return this[r].localName},getLocator:function(r){return this[r].locator},getQName:function(r){return this[r].qName},getURI:function(r){return this[r].uri},getValue:function(r){return this[r].value}};function oJ(r,e){var t,i=[],n=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;for(n.lastIndex=e,n.exec(r);t=n.exec(r);)if(i.push(t),t[1])return i}PC.XMLReader=xO;PC.ParseError=Gh;var lJ=Qs,uJ=ol,yI=TO,AO=PC,cJ=uJ.DOMImplementation,_I=lJ.NAMESPACE,hJ=AO.ParseError,fJ=AO.XMLReader;function DO(r){return r.replace(/\r[\n\u0085]/g,` +`).replace(/[\r\u0085\u2028]/g,` +`)}function EO(r){this.options=r||{locator:{}}}EO.prototype.parseFromString=function(r,e){var t=this.options,i=new fJ,n=t.domBuilder||new zv,a=t.errorHandler,s=t.locator,o=t.xmlns||{},l=/\/x?html?$/.test(e),u=l?yI.HTML_ENTITIES:yI.XML_ENTITIES;s&&n.setDocumentLocator(s),i.errorHandler=dJ(a,n,s),i.domBuilder=t.domBuilder||n,l&&(o[""]=_I.HTML),o.xml=o.xml||_I.XML;var c=t.normalizeLineEndings||DO;return r&&typeof r=="string"?i.parse(c(r),o,u):i.errorHandler.error("invalid doc source"),n.doc};function dJ(r,e,t){if(!r){if(e instanceof zv)return e;r=e}var i={},n=r instanceof Function;t=t||{};function a(s){var o=r[s];!o&&n&&(o=r.length==2?function(l){r(s,l)}:r),i[s]=o&&function(l){o("[xmldom "+s+"] "+l+CT(t))}||function(){}}return a("warning"),a("error"),a("fatalError"),i}function zv(){this.cdata=!1}function Dc(r,e){e.lineNumber=r.lineNumber,e.columnNumber=r.columnNumber}zv.prototype={startDocument:function(){this.doc=new cJ().createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(r,e,t,i){var n=this.doc,a=n.createElementNS(r,t||e),s=i.length;Vg(this,a),this.currentElement=a,this.locator&&Dc(this.locator,a);for(var o=0;o=e+t||e?new java.lang.String(r,e,t)+"":r}"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(r){zv.prototype[r]=function(){return null}});function Vg(r,e){r.currentElement?r.currentElement.appendChild(e):r.doc.appendChild(e)}C_.__DOMHandler=zv;C_.normalizeLineEndings=DO;C_.DOMParser=EO;var pJ=C_.DOMParser;/*! @name mpd-parser @version 1.3.1 @license Apache-2.0 */const SI=r=>!!r&&typeof r=="object",zr=(...r)=>r.reduce((e,t)=>(typeof t!="object"||Object.keys(t).forEach(i=>{Array.isArray(e[i])&&Array.isArray(t[i])?e[i]=e[i].concat(t[i]):SI(e[i])&&SI(t[i])?e[i]=zr(e[i],t[i]):e[i]=t[i]}),e),{}),IO=r=>Object.keys(r).map(e=>r[e]),vJ=(r,e)=>{const t=[];for(let i=r;ir.reduce((e,t)=>e.concat(t),[]),PO=r=>{if(!r.length)return[];const e=[];for(let t=0;tr.reduce((t,i,n)=>(i[e]&&t.push(n),t),[]),mJ=(r,e)=>IO(r.reduce((t,i)=>(i.forEach(n=>{t[e(n)]=n}),t),{}));var $h={INVALID_NUMBER_OF_PERIOD:"INVALID_NUMBER_OF_PERIOD",INVALID_NUMBER_OF_CONTENT_STEERING:"INVALID_NUMBER_OF_CONTENT_STEERING",DASH_EMPTY_MANIFEST:"DASH_EMPTY_MANIFEST",DASH_INVALID_XML:"DASH_INVALID_XML",NO_BASE_URL:"NO_BASE_URL",MISSING_SEGMENT_INFORMATION:"MISSING_SEGMENT_INFORMATION",SEGMENT_TIME_UNSPECIFIED:"SEGMENT_TIME_UNSPECIFIED",UNSUPPORTED_UTC_TIMING_SCHEME:"UNSUPPORTED_UTC_TIMING_SCHEME"};const jp=({baseUrl:r="",source:e="",range:t="",indexRange:i=""})=>{const n={uri:e,resolvedUri:T_(r||"",e)};if(t||i){const s=(t||i).split("-");let o=H.BigInt?H.BigInt(s[0]):parseInt(s[0],10),l=H.BigInt?H.BigInt(s[1]):parseInt(s[1],10);o{let e;return typeof r.offset=="bigint"||typeof r.length=="bigint"?e=H.BigInt(r.offset)+H.BigInt(r.length)-H.BigInt(1):e=r.offset+r.length-1,`${r.offset}-${e}`},TI=r=>(r&&typeof r!="number"&&(r=parseInt(r,10)),isNaN(r)?null:r),_J={static(r){const{duration:e,timescale:t=1,sourceDuration:i,periodDuration:n}=r,a=TI(r.endNumber),s=e/t;return typeof a=="number"?{start:0,end:a}:typeof n=="number"?{start:0,end:n/s}:{start:0,end:i/s}},dynamic(r){const{NOW:e,clientOffset:t,availabilityStartTime:i,timescale:n=1,duration:a,periodStart:s=0,minimumUpdatePeriod:o=0,timeShiftBufferDepth:l=1/0}=r,u=TI(r.endNumber),c=(e+t)/1e3,h=i+s,f=c+o-h,p=Math.ceil(f*n/a),v=Math.floor((c-h-l)*n/a),g=Math.floor((c-h)*n/a);return{start:Math.max(0,v),end:typeof u=="number"?u:Math.min(p,g)}}},bJ=r=>e=>{const{duration:t,timescale:i=1,periodStart:n,startNumber:a=1}=r;return{number:a+e,duration:t/i,timeline:n,time:e*t}},MC=r=>{const{type:e,duration:t,timescale:i=1,periodDuration:n,sourceDuration:a}=r,{start:s,end:o}=_J[e](r),l=vJ(s,o).map(bJ(r));if(e==="static"){const u=l.length-1,c=typeof n=="number"?n:a;l[u].duration=c-t/i*u}return l},MO=r=>{const{baseUrl:e,initialization:t={},sourceDuration:i,indexRange:n="",periodStart:a,presentationTime:s,number:o=0,duration:l}=r;if(!e)throw new Error($h.NO_BASE_URL);const u=jp({baseUrl:e,source:t.sourceURL,range:t.range}),c=jp({baseUrl:e,source:e,indexRange:n});if(c.map=u,l){const h=MC(r);h.length&&(c.duration=h[0].duration,c.timeline=h[0].timeline)}else i&&(c.duration=i,c.timeline=a);return c.presentationTime=s||a,c.number=o,[c]},LC=(r,e,t)=>{const i=r.sidx.map?r.sidx.map:null,n=r.sidx.duration,a=r.timeline||0,s=r.sidx.byterange,o=s.offset+s.length,l=e.timescale,u=e.references.filter(g=>g.referenceType!==1),c=[],h=r.endList?"static":"dynamic",d=r.sidx.timeline;let f=d,p=r.mediaSequence||0,v;typeof e.firstOffset=="bigint"?v=H.BigInt(o)+e.firstOffset:v=o+e.firstOffset;for(let g=0;gmJ(r,({timeline:e})=>e).sort((e,t)=>e.timeline>t.timeline?1:-1),xJ=(r,e)=>{for(let t=0;t{let e=[];return VQ(r,SJ,(t,i,n,a)=>{e=e.concat(t.playlists||[])}),e},wI=({playlist:r,mediaSequence:e})=>{r.mediaSequence=e,r.segments.forEach((t,i)=>{t.number=r.mediaSequence+i})},wJ=({oldPlaylists:r,newPlaylists:e,timelineStarts:t})=>{e.forEach(i=>{i.discontinuitySequence=t.findIndex(function({timeline:l}){return l===i.timeline});const n=xJ(r,i.attributes.NAME);if(!n||i.sidx)return;const a=i.segments[0],s=n.segments.findIndex(function(l){return Math.abs(l.presentationTime-a.presentationTime)n.timeline||n.segments.length&&i.timeline>n.segments[n.segments.length-1].timeline)&&i.discontinuitySequence--;return}n.segments[s].discontinuity&&!a.discontinuity&&(a.discontinuity=!0,i.discontinuityStarts.unshift(0),i.discontinuitySequence--),wI({playlist:i,mediaSequence:n.segments[s].number})})},CJ=({oldManifest:r,newManifest:e})=>{const t=r.playlists.concat(xI(r)),i=e.playlists.concat(xI(e));return e.timelineStarts=LO([r.timelineStarts,e.timelineStarts]),wJ({oldPlaylists:t,newPlaylists:i,timelineStarts:e.timelineStarts}),e},A_=r=>r&&r.uri+"-"+yJ(r.byterange),h2=r=>{const e=r.reduce(function(i,n){return i[n.attributes.baseUrl]||(i[n.attributes.baseUrl]=[]),i[n.attributes.baseUrl].push(n),i},{});let t=[];return Object.values(e).forEach(i=>{const n=IO(i.reduce((a,s)=>{const o=s.attributes.id+(s.attributes.lang||"");return a[o]?(s.segments&&(s.segments[0]&&(s.segments[0].discontinuity=!0),a[o].segments.push(...s.segments)),s.attributes.contentProtection&&(a[o].attributes.contentProtection=s.attributes.contentProtection)):(a[o]=s,a[o].attributes.timelineStarts=[]),a[o].attributes.timelineStarts.push({start:s.attributes.periodStart,timeline:s.attributes.periodStart}),a},{}));t=t.concat(n)}),t.map(i=>(i.discontinuityStarts=gJ(i.segments||[],"discontinuity"),i))},kC=(r,e)=>{const t=A_(r.sidx),i=t&&e[t]&&e[t].sidx;return i&&LC(r,i,r.sidx.resolvedUri),r},AJ=(r,e={})=>{if(!Object.keys(e).length)return r;for(const t in r)r[t]=kC(r[t],e);return r},DJ=({attributes:r,segments:e,sidx:t,mediaSequence:i,discontinuitySequence:n,discontinuityStarts:a},s)=>{const o={attributes:{NAME:r.id,BANDWIDTH:r.bandwidth,CODECS:r.codecs,"PROGRAM-ID":1},uri:"",endList:r.type==="static",timeline:r.periodStart,resolvedUri:r.baseUrl||"",targetDuration:r.duration,discontinuitySequence:n,discontinuityStarts:a,timelineStarts:r.timelineStarts,mediaSequence:i,segments:e};return r.contentProtection&&(o.contentProtection=r.contentProtection),r.serviceLocation&&(o.attributes.serviceLocation=r.serviceLocation),t&&(o.sidx=t),s&&(o.attributes.AUDIO="audio",o.attributes.SUBTITLES="subs"),o},EJ=({attributes:r,segments:e,mediaSequence:t,discontinuityStarts:i,discontinuitySequence:n})=>{typeof e>"u"&&(e=[{uri:r.baseUrl,timeline:r.periodStart,resolvedUri:r.baseUrl||"",duration:r.sourceDuration,number:0}],r.duration=r.sourceDuration);const a={NAME:r.id,BANDWIDTH:r.bandwidth,"PROGRAM-ID":1};r.codecs&&(a.CODECS=r.codecs);const s={attributes:a,uri:"",endList:r.type==="static",timeline:r.periodStart,resolvedUri:r.baseUrl||"",targetDuration:r.duration,timelineStarts:r.timelineStarts,discontinuityStarts:i,discontinuitySequence:n,mediaSequence:t,segments:e};return r.serviceLocation&&(s.attributes.serviceLocation=r.serviceLocation),s},IJ=(r,e={},t=!1)=>{let i;const n=r.reduce((a,s)=>{const o=s.attributes.role&&s.attributes.role.value||"",l=s.attributes.lang||"";let u=s.attributes.label||"main";if(l&&!s.attributes.label){const h=o?` (${o})`:"";u=`${s.attributes.lang}${h}`}a[u]||(a[u]={language:l,autoselect:!0,default:o==="main",playlists:[],uri:""});const c=kC(DJ(s,t),e);return a[u].playlists.push(c),typeof i>"u"&&o==="main"&&(i=s,i.default=!0),a},{});if(!i){const a=Object.keys(n)[0];n[a].default=!0}return n},PJ=(r,e={})=>r.reduce((t,i)=>{const n=i.attributes.label||i.attributes.lang||"text",a=i.attributes.lang||"und";return t[n]||(t[n]={language:a,default:!1,autoselect:!1,playlists:[],uri:""}),t[n].playlists.push(kC(EJ(i),e)),t},{}),MJ=r=>r.reduce((e,t)=>(t&&t.forEach(i=>{const{channel:n,language:a}=i;e[a]={autoselect:!1,default:!1,instreamId:n,language:a},i.hasOwnProperty("aspectRatio")&&(e[a].aspectRatio=i.aspectRatio),i.hasOwnProperty("easyReader")&&(e[a].easyReader=i.easyReader),i.hasOwnProperty("3D")&&(e[a]["3D"]=i["3D"])}),e),{}),LJ=({attributes:r,segments:e,sidx:t,discontinuityStarts:i})=>{const n={attributes:{NAME:r.id,AUDIO:"audio",SUBTITLES:"subs",RESOLUTION:{width:r.width,height:r.height},CODECS:r.codecs,BANDWIDTH:r.bandwidth,"PROGRAM-ID":1},uri:"",endList:r.type==="static",timeline:r.periodStart,resolvedUri:r.baseUrl||"",targetDuration:r.duration,discontinuityStarts:i,timelineStarts:r.timelineStarts,segments:e};return r.frameRate&&(n.attributes["FRAME-RATE"]=r.frameRate),r.contentProtection&&(n.contentProtection=r.contentProtection),r.serviceLocation&&(n.attributes.serviceLocation=r.serviceLocation),t&&(n.sidx=t),n},kJ=({attributes:r})=>r.mimeType==="video/mp4"||r.mimeType==="video/webm"||r.contentType==="video",RJ=({attributes:r})=>r.mimeType==="audio/mp4"||r.mimeType==="audio/webm"||r.contentType==="audio",OJ=({attributes:r})=>r.mimeType==="text/vtt"||r.contentType==="text",NJ=(r,e)=>{r.forEach(t=>{t.mediaSequence=0,t.discontinuitySequence=e.findIndex(function({timeline:i}){return i===t.timeline}),t.segments&&t.segments.forEach((i,n)=>{i.number=n})})},CI=r=>r?Object.keys(r).reduce((e,t)=>{const i=r[t];return e.concat(i.playlists)},[]):[],BJ=({dashPlaylists:r,locations:e,contentSteering:t,sidxMapping:i={},previousManifest:n,eventStream:a})=>{if(!r.length)return{};const{sourceDuration:s,type:o,suggestedPresentationDelay:l,minimumUpdatePeriod:u}=r[0].attributes,c=h2(r.filter(kJ)).map(LJ),h=h2(r.filter(RJ)),d=h2(r.filter(OJ)),f=r.map(b=>b.attributes.captionServices).filter(Boolean),p={allowCache:!0,discontinuityStarts:[],segments:[],endList:!0,mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:"",duration:s,playlists:AJ(c,i)};u>=0&&(p.minimumUpdatePeriod=u*1e3),e&&(p.locations=e),t&&(p.contentSteering=t),o==="dynamic"&&(p.suggestedPresentationDelay=l),a&&a.length>0&&(p.eventStream=a);const v=p.playlists.length===0,g=h.length?IJ(h,i,v):null,m=d.length?PJ(d,i):null,y=c.concat(CI(g),CI(m)),_=y.map(({timelineStarts:b})=>b);return p.timelineStarts=LO(_),NJ(y,p.timelineStarts),g&&(p.mediaGroups.AUDIO.audio=g),m&&(p.mediaGroups.SUBTITLES.subs=m),f.length&&(p.mediaGroups["CLOSED-CAPTIONS"].cc=MJ(f)),n?CJ({oldManifest:n,newManifest:p}):p},FJ=(r,e,t)=>{const{NOW:i,clientOffset:n,availabilityStartTime:a,timescale:s=1,periodStart:o=0,minimumUpdatePeriod:l=0}=r,u=(i+n)/1e3,c=a+o,d=u+l-c;return Math.ceil((d*s-e)/t)},kO=(r,e)=>{const{type:t,minimumUpdatePeriod:i=0,media:n="",sourceDuration:a,timescale:s=1,startNumber:o=1,periodStart:l}=r,u=[];let c=-1;for(let h=0;hc&&(c=v);let g;if(p<0){const _=h+1;_===e.length?t==="dynamic"&&i>0&&n.indexOf("$Number$")>0?g=FJ(r,c,f):g=(a*s-c)/f:g=(e[_].t-c)/f}else g=p+1;const m=o+u.length+g;let y=o+u.length;for(;y(e,t,i,n)=>{if(e==="$$")return"$";if(typeof r[t]>"u")return e;const a=""+r[t];return t==="RepresentationID"||(i?n=parseInt(n,10):n=1,a.length>=n)?a:`${new Array(n-a.length+1).join("0")}${a}`},AI=(r,e)=>r.replace(UJ,VJ(e)),zJ=(r,e)=>!r.duration&&!e?[{number:r.startNumber||1,duration:r.sourceDuration,time:0,timeline:r.periodStart}]:r.duration?MC(r):kO(r,e),GJ=(r,e)=>{const t={RepresentationID:r.id,Bandwidth:r.bandwidth||0},{initialization:i={sourceURL:"",range:""}}=r,n=jp({baseUrl:r.baseUrl,source:AI(i.sourceURL,t),range:i.range});return zJ(r,e).map(s=>{t.Number=s.number,t.Time=s.time;const o=AI(r.media||"",t),l=r.timescale||1,u=r.presentationTimeOffset||0,c=r.periodStart+(s.time-u)/l;return{uri:o,timeline:s.timeline,duration:s.duration,resolvedUri:T_(r.baseUrl||"",o),map:n,number:s.number,presentationTime:c}})},HJ=(r,e)=>{const{baseUrl:t,initialization:i={}}=r,n=jp({baseUrl:t,source:i.sourceURL,range:i.range}),a=jp({baseUrl:t,source:e.media,range:e.mediaRange});return a.map=n,a},$J=(r,e)=>{const{duration:t,segmentUrls:i=[],periodStart:n}=r;if(!t&&!e||t&&e)throw new Error($h.SEGMENT_TIME_UNSPECIFIED);const a=i.map(l=>HJ(r,l));let s;return t&&(s=MC(r)),e&&(s=kO(r,e)),s.map((l,u)=>{if(a[u]){const c=a[u],h=r.timescale||1,d=r.presentationTimeOffset||0;return c.timeline=l.timeline,c.duration=l.duration,c.number=l.number,c.presentationTime=n+(l.time-d)/h,c}}).filter(l=>l)},WJ=({attributes:r,segmentInfo:e})=>{let t,i;e.template?(i=GJ,t=zr(r,e.template)):e.base?(i=MO,t=zr(r,e.base)):e.list&&(i=$J,t=zr(r,e.list));const n={attributes:r};if(!i)return n;const a=i(t,e.segmentTimeline);if(t.duration){const{duration:s,timescale:o=1}=t;t.duration=s/o}else a.length?t.duration=a.reduce((s,o)=>Math.max(s,Math.ceil(o.duration)),0):t.duration=0;return n.attributes=t,n.segments=a,e.base&&t.indexRange&&(n.sidx=a[0],n.segments=[]),n},qJ=r=>r.map(WJ),jt=(r,e)=>PO(r.childNodes).filter(({tagName:t})=>t===e),Gv=r=>r.textContent.trim(),jJ=r=>parseFloat(r.split("/").reduce((e,t)=>e/t)),Ec=r=>{const o=/P(?:(\d*)Y)?(?:(\d*)M)?(?:(\d*)D)?(?:T(?:(\d*)H)?(?:(\d*)M)?(?:([\d.]*)S)?)?/.exec(r);if(!o)return 0;const[l,u,c,h,d,f]=o.slice(1);return parseFloat(l||0)*31536e3+parseFloat(u||0)*2592e3+parseFloat(c||0)*86400+parseFloat(h||0)*3600+parseFloat(d||0)*60+parseFloat(f||0)},XJ=r=>(/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/.test(r)&&(r+="Z"),Date.parse(r)),DI={mediaPresentationDuration(r){return Ec(r)},availabilityStartTime(r){return XJ(r)/1e3},minimumUpdatePeriod(r){return Ec(r)},suggestedPresentationDelay(r){return Ec(r)},type(r){return r},timeShiftBufferDepth(r){return Ec(r)},start(r){return Ec(r)},width(r){return parseInt(r,10)},height(r){return parseInt(r,10)},bandwidth(r){return parseInt(r,10)},frameRate(r){return jJ(r)},startNumber(r){return parseInt(r,10)},timescale(r){return parseInt(r,10)},presentationTimeOffset(r){return parseInt(r,10)},duration(r){const e=parseInt(r,10);return isNaN(e)?Ec(r):e},d(r){return parseInt(r,10)},t(r){return parseInt(r,10)},r(r){return parseInt(r,10)},presentationTime(r){return parseInt(r,10)},DEFAULT(r){return r}},Tr=r=>r&&r.attributes?PO(r.attributes).reduce((e,t)=>{const i=DI[t.name]||DI.DEFAULT;return e[t.name]=i(t.value),e},{}):{},YJ={"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:f239e769-efa3-4850-9c16-a903c6932efb":"com.adobe.primetime","urn:mpeg:dash:mp4protection:2011":"mp4protection"},D_=(r,e)=>e.length?Hh(r.map(function(t){return e.map(function(i){const n=Gv(i),a=T_(t.baseUrl,n),s=zr(Tr(i),{baseUrl:a});return a!==n&&!s.serviceLocation&&t.serviceLocation&&(s.serviceLocation=t.serviceLocation),s})})):r,RC=r=>{const e=jt(r,"SegmentTemplate")[0],t=jt(r,"SegmentList")[0],i=t&&jt(t,"SegmentURL").map(h=>zr({tag:"SegmentURL"},Tr(h))),n=jt(r,"SegmentBase")[0],a=t||e,s=a&&jt(a,"SegmentTimeline")[0],o=t||n||e,l=o&&jt(o,"Initialization")[0],u=e&&Tr(e);u&&l?u.initialization=l&&Tr(l):u&&u.initialization&&(u.initialization={sourceURL:u.initialization});const c={template:u,segmentTimeline:s&&jt(s,"S").map(h=>Tr(h)),list:t&&zr(Tr(t),{segmentUrls:i,initialization:Tr(l)}),base:n&&zr(Tr(n),{initialization:Tr(l)})};return Object.keys(c).forEach(h=>{c[h]||delete c[h]}),c},KJ=(r,e,t)=>i=>{const n=jt(i,"BaseURL"),a=D_(e,n),s=zr(r,Tr(i)),o=RC(i);return a.map(l=>({segmentInfo:zr(t,o),attributes:zr(s,l)}))},ZJ=r=>r.reduce((e,t)=>{const i=Tr(t);i.schemeIdUri&&(i.schemeIdUri=i.schemeIdUri.toLowerCase());const n=YJ[i.schemeIdUri];if(n){e[n]={attributes:i};const a=jt(t,"cenc:pssh")[0];if(a){const s=Gv(a);e[n].pssh=s&&X6(s)}}return e},{}),QJ=r=>{if(r.schemeIdUri==="urn:scte:dash:cc:cea-608:2015")return(typeof r.value!="string"?[]:r.value.split(";")).map(t=>{let i,n;return n=t,/^CC\d=/.test(t)?[i,n]=t.split("="):/^CC\d$/.test(t)&&(i=t),{channel:i,language:n}});if(r.schemeIdUri==="urn:scte:dash:cc:cea-708:2015")return(typeof r.value!="string"?[]:r.value.split(";")).map(t=>{const i={channel:void 0,language:void 0,aspectRatio:1,easyReader:0,"3D":0};if(/=/.test(t)){const[n,a=""]=t.split("=");i.channel=n,i.language=t,a.split(",").forEach(s=>{const[o,l]=s.split(":");o==="lang"?i.language=l:o==="er"?i.easyReader=Number(l):o==="war"?i.aspectRatio=Number(l):o==="3D"&&(i["3D"]=Number(l))})}else i.language=t;return i.channel&&(i.channel="SERVICE"+i.channel),i})},JJ=r=>Hh(jt(r.node,"EventStream").map(e=>{const t=Tr(e),i=t.schemeIdUri;return jt(e,"Event").map(n=>{const a=Tr(n),s=a.presentationTime||0,o=t.timescale||1,l=a.duration||0,u=s/o+r.attributes.start;return{schemeIdUri:i,value:t.value,id:a.id,start:u,end:u+l/o,messageData:Gv(n)||a.messageData,contentEncoding:t.contentEncoding,presentationTimeOffset:t.presentationTimeOffset||0}})})),eee=(r,e,t)=>i=>{const n=Tr(i),a=D_(e,jt(i,"BaseURL")),s=jt(i,"Role")[0],o={role:Tr(s)};let l=zr(r,n,o);const u=jt(i,"Accessibility")[0],c=QJ(Tr(u));c&&(l=zr(l,{captionServices:c}));const h=jt(i,"Label")[0];if(h&&h.childNodes.length){const g=h.childNodes[0].nodeValue.trim();l=zr(l,{label:g})}const d=ZJ(jt(i,"ContentProtection"));Object.keys(d).length&&(l=zr(l,{contentProtection:d}));const f=RC(i),p=jt(i,"Representation"),v=zr(t,f);return Hh(p.map(KJ(l,a,v)))},tee=(r,e)=>(t,i)=>{const n=D_(e,jt(t.node,"BaseURL")),a=zr(r,{periodStart:t.attributes.start});typeof t.attributes.duration=="number"&&(a.periodDuration=t.attributes.duration);const s=jt(t.node,"AdaptationSet"),o=RC(t.node);return Hh(s.map(eee(a,n,o)))},ree=(r,e)=>{if(r.length>1&&e({type:"warn",message:"The MPD manifest should contain no more than one ContentSteering tag"}),!r.length)return null;const t=zr({serverURL:Gv(r[0])},Tr(r[0]));return t.queryBeforeStart=t.queryBeforeStart==="true",t},iee=({attributes:r,priorPeriodAttributes:e,mpdType:t})=>typeof r.start=="number"?r.start:e&&typeof e.start=="number"&&typeof e.duration=="number"?e.start+e.duration:!e&&t==="static"?0:null,nee=(r,e={})=>{const{manifestUri:t="",NOW:i=Date.now(),clientOffset:n=0,eventHandler:a=function(){}}=e,s=jt(r,"Period");if(!s.length)throw new Error($h.INVALID_NUMBER_OF_PERIOD);const o=jt(r,"Location"),l=Tr(r),u=D_([{baseUrl:t}],jt(r,"BaseURL")),c=jt(r,"ContentSteering");l.type=l.type||"static",l.sourceDuration=l.mediaPresentationDuration||0,l.NOW=i,l.clientOffset=n,o.length&&(l.locations=o.map(Gv));const h=[];return s.forEach((d,f)=>{const p=Tr(d),v=h[f-1];p.start=iee({attributes:p,priorPeriodAttributes:v?v.attributes:null,mpdType:l.type}),h.push({node:d,attributes:p})}),{locations:l.locations,contentSteeringInfo:ree(c,a),representationInfo:Hh(h.map(tee(l,u))),eventStream:Hh(h.map(JJ))}},RO=r=>{if(r==="")throw new Error($h.DASH_EMPTY_MANIFEST);const e=new pJ;let t,i;try{t=e.parseFromString(r,"application/xml"),i=t&&t.documentElement.tagName==="MPD"?t.documentElement:null}catch{}if(!i||i&&i.getElementsByTagName("parsererror").length>0)throw new Error($h.DASH_INVALID_XML);return i},aee=r=>{const e=jt(r,"UTCTiming")[0];if(!e)return null;const t=Tr(e);switch(t.schemeIdUri){case"urn:mpeg:dash:utc:http-head:2014":case"urn:mpeg:dash:utc:http-head:2012":t.method="HEAD";break;case"urn:mpeg:dash:utc:http-xsdate:2014":case"urn:mpeg:dash:utc:http-iso:2014":case"urn:mpeg:dash:utc:http-xsdate:2012":case"urn:mpeg:dash:utc:http-iso:2012":t.method="GET";break;case"urn:mpeg:dash:utc:direct:2014":case"urn:mpeg:dash:utc:direct:2012":t.method="DIRECT",t.value=Date.parse(t.value);break;case"urn:mpeg:dash:utc:http-ntp:2014":case"urn:mpeg:dash:utc:ntp:2014":case"urn:mpeg:dash:utc:sntp:2014":default:throw new Error($h.UNSUPPORTED_UTC_TIMING_SCHEME)}return t},see=(r,e={})=>{const t=nee(RO(r),e),i=qJ(t.representationInfo);return BJ({dashPlaylists:i,locations:t.locations,contentSteering:t.contentSteeringInfo,sidxMapping:e.sidxMapping,previousManifest:e.previousManifest,eventStream:t.eventStream})},oee=r=>aee(RO(r));var OO=Math.pow(2,32),lee=function(r){var e=new DataView(r.buffer,r.byteOffset,r.byteLength),t;return e.getBigUint64?(t=e.getBigUint64(0),t0;i+=12,n--)t.references.push({referenceType:(r[i]&128)>>>7,referencedSize:e.getUint32(i)&2147483647,subsegmentDuration:e.getUint32(i+4),startsWithSap:!!(r[i+8]&128),sapType:(r[i+8]&112)>>>4,sapDeltaTime:e.getUint32(i+8)&268435455});return t},hee=cee;const fee=Bv(hee);var dee=$e([73,68,51]),pee=function(e,t){t===void 0&&(t=0),e=$e(e);var i=e[t+5],n=e[t+6]<<21|e[t+7]<<14|e[t+8]<<7|e[t+9],a=(i&16)>>4;return a?n+20:n+10},Wd=function r(e,t){return t===void 0&&(t=0),e=$e(e),e.length-t<10||!qt(e,dee,{offset:t})?t:(t+=pee(e,t),r(e,t))},II=function(e){return typeof e=="string"?J6(e):e},vee=function(e){return Array.isArray(e)?e.map(function(t){return II(t)}):[II(e)]},gee=function r(e,t,i){i===void 0&&(i=!1),t=vee(t),e=$e(e);var n=[];if(!t.length)return n;for(var a=0;a>>0,o=e.subarray(a+4,a+8);if(s===0)break;var l=a+s;if(l>e.length){if(i)break;l=e.length}var u=e.subarray(a+8,l);qt(o,t[0])&&(t.length===1?n.push(u):n.push.apply(n,r(u,t.slice(1),i))),a=l}return n},zg={EBML:$e([26,69,223,163]),DocType:$e([66,130]),Segment:$e([24,83,128,103]),SegmentInfo:$e([21,73,169,102]),Tracks:$e([22,84,174,107]),Track:$e([174]),TrackNumber:$e([215]),DefaultDuration:$e([35,227,131]),TrackEntry:$e([174]),TrackType:$e([131]),FlagDefault:$e([136]),CodecID:$e([134]),CodecPrivate:$e([99,162]),VideoTrack:$e([224]),AudioTrack:$e([225]),Cluster:$e([31,67,182,117]),Timestamp:$e([231]),TimestampScale:$e([42,215,177]),BlockGroup:$e([160]),BlockDuration:$e([155]),Block:$e([161]),SimpleBlock:$e([163])},AT=[128,64,32,16,8,4,2,1],mee=function(e){for(var t=1,i=0;i=t.length)return t.length;var n=G0(t,i,!1);if(qt(e.bytes,n.bytes))return i;var a=G0(t,i+n.length);return r(e,t,i+a.length+a.value+n.length)},MI=function r(e,t){t=yee(t),e=$e(e);var i=[];if(!t.length)return i;for(var n=0;ne.length?e.length:o+s.value,u=e.subarray(o,l);qt(t[0],a.bytes)&&(t.length===1?i.push(u):i=i.concat(r(u,t.slice(1))));var c=a.length+s.length+u.length;n+=c}return i},bee=$e([0,0,0,1]),See=$e([0,0,1]),Tee=$e([0,0,3]),xee=function(e){for(var t=[],i=1;i>1&63),i.indexOf(u)!==-1&&(s=a+l),a+=l+(t==="h264"?1:2)}return e.subarray(0,0)},wee=function(e,t,i){return NO(e,"h264",t,i)},Cee=function(e,t,i){return NO(e,"h265",t,i)},di={webm:$e([119,101,98,109]),matroska:$e([109,97,116,114,111,115,107,97]),flac:$e([102,76,97,67]),ogg:$e([79,103,103,83]),ac3:$e([11,119]),riff:$e([82,73,70,70]),avi:$e([65,86,73]),wav:$e([87,65,86,69]),"3gp":$e([102,116,121,112,51,103]),mp4:$e([102,116,121,112]),fmp4:$e([115,116,121,112]),mov:$e([102,116,121,112,113,116]),moov:$e([109,111,111,118]),moof:$e([109,111,111,102])},Wh={aac:function(e){var t=Wd(e);return qt(e,[255,16],{offset:t,mask:[255,22]})},mp3:function(e){var t=Wd(e);return qt(e,[255,2],{offset:t,mask:[255,6]})},webm:function(e){var t=MI(e,[zg.EBML,zg.DocType])[0];return qt(t,di.webm)},mkv:function(e){var t=MI(e,[zg.EBML,zg.DocType])[0];return qt(t,di.matroska)},mp4:function(e){if(Wh["3gp"](e)||Wh.mov(e))return!1;if(qt(e,di.mp4,{offset:4})||qt(e,di.fmp4,{offset:4})||qt(e,di.moof,{offset:4})||qt(e,di.moov,{offset:4}))return!0},mov:function(e){return qt(e,di.mov,{offset:4})},"3gp":function(e){return qt(e,di["3gp"],{offset:4})},ac3:function(e){var t=Wd(e);return qt(e,di.ac3,{offset:t})},ts:function(e){if(e.length<189&&e.length>=1)return e[0]===71;for(var t=0;t+1880},NC=9e4,BC,FC,E_,UC,BO,FO,UO;BC=function(r){return r*NC};FC=function(r,e){return r*e};E_=function(r){return r/NC};UC=function(r,e){return r/e};BO=function(r,e){return BC(UC(r,e))};FO=function(r,e){return FC(E_(r),e)};UO=function(r,e,t){return E_(t?r:r-e)};var du={ONE_SECOND_IN_TS:NC,secondsToVideoTs:BC,secondsToAudioTs:FC,videoTsToSeconds:E_,audioTsToSeconds:UC,audioTsToVideoTs:BO,videoTsToAudioTs:FO,metadataTsToSeconds:UO};/** + * @license + * Video.js 8.18.1 + * Copyright Brightcove, Inc. + * Available under Apache License Version 2.0 + * + * + * Includes vtt.js + * Available under Apache License Version 2.0 + * + */var ET="8.18.1";const Cs={},Yo=function(r,e){return Cs[r]=Cs[r]||[],e&&(Cs[r]=Cs[r].concat(e)),Cs[r]},Eee=function(r,e){Yo(r,e)},VO=function(r,e){const t=Yo(r).indexOf(e);return t<=-1?!1:(Cs[r]=Cs[r].slice(),Cs[r].splice(t,1),!0)},Iee=function(r,e){Yo(r,[].concat(e).map(t=>{const i=(...n)=>(VO(r,i),t(...n));return i}))},H0={prefixed:!0},n0=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror","fullscreen"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror","-webkit-full-screen"]],LI=n0[0];let qd;for(let r=0;r(i,n,a)=>{const s=e.levels[n],o=new RegExp(`^(${s})$`);let l=r;if(i!=="log"&&a.unshift(i.toUpperCase()+":"),t&&(l=`%c${r}`,a.unshift(t)),a.unshift(l+":"),Ri){Ri.push([].concat(a));const c=Ri.length-1e3;Ri.splice(0,c>0?c:0)}if(!H.console)return;let u=H.console[i];!u&&i==="debug"&&(u=H.console.info||H.console.log),!(!u||!s||!o.test(i))&&u[Array.isArray(a)?"apply":"call"](H.console,a)};function IT(r,e=":",t=""){let i="info",n;function a(...s){n("log",i,s)}return n=Pee(r,a,t),a.createLogger=(s,o,l)=>{const u=o!==void 0?o:e,c=l!==void 0?l:t,h=`${r} ${u} ${s}`;return IT(h,u,c)},a.createNewLogger=(s,o,l)=>IT(s,o,l),a.levels={all:"debug|log|warn|error",off:"",debug:"debug|log|warn|error",info:"log|warn|error",warn:"warn|error",error:"error",DEFAULT:i},a.level=s=>{if(typeof s=="string"){if(!a.levels.hasOwnProperty(s))throw new Error(`"${s}" in not a valid log level`);i=s}return i},a.history=()=>Ri?[].concat(Ri):[],a.history.filter=s=>(Ri||[]).filter(o=>new RegExp(`.*${s}.*`).test(o[0])),a.history.clear=()=>{Ri&&(Ri.length=0)},a.history.disable=()=>{Ri!==null&&(Ri.length=0,Ri=null)},a.history.enable=()=>{Ri===null&&(Ri=[])},a.error=(...s)=>n("error",i,s),a.warn=(...s)=>n("warn",i,s),a.debug=(...s)=>n("debug",i,s),a}const pt=IT("VIDEOJS"),zO=pt.createLogger,Mee=Object.prototype.toString,GO=function(r){return es(r)?Object.keys(r):[]};function bh(r,e){GO(r).forEach(t=>e(r[t],t))}function HO(r,e,t=0){return GO(r).reduce((i,n)=>e(i,r[n],n),t)}function es(r){return!!r&&typeof r=="object"}function qh(r){return es(r)&&Mee.call(r)==="[object Object]"&&r.constructor===Object}function Ut(...r){const e={};return r.forEach(t=>{t&&bh(t,(i,n)=>{if(!qh(i)){e[n]=i;return}qh(e[n])||(e[n]={}),e[n]=Ut(e[n],i)})}),e}function $O(r={}){const e=[];for(const t in r)if(r.hasOwnProperty(t)){const i=r[t];e.push(i)}return e}function I_(r,e,t,i=!0){const n=s=>Object.defineProperty(r,e,{value:s,enumerable:!0,writable:!0}),a={configurable:!0,enumerable:!0,get(){const s=t();return n(s),s}};return i&&(a.set=n),Object.defineProperty(r,e,a)}var Lee=Object.freeze({__proto__:null,each:bh,reduce:HO,isObject:es,isPlain:qh,merge:Ut,values:$O,defineLazyProperty:I_});let VC=!1,WO=null,ts=!1,qO,jO=!1,Sh=!1,Th=!1,rs=!1,zC=null,P_=null;const kee=!!(H.cast&&H.cast.framework&&H.cast.framework.CastReceiverContext);let XO=null,$0=!1,M_=!1,W0=!1,L_=!1,q0=!1,j0=!1,X0=!1;const Xp=!!(bf()&&("ontouchstart"in H||H.navigator.maxTouchPoints||H.DocumentTouch&&H.document instanceof H.DocumentTouch)),uo=H.navigator&&H.navigator.userAgentData;uo&&uo.platform&&uo.brands&&(ts=uo.platform==="Android",Sh=!!uo.brands.find(r=>r.brand==="Microsoft Edge"),Th=!!uo.brands.find(r=>r.brand==="Chromium"),rs=!Sh&&Th,zC=P_=(uo.brands.find(r=>r.brand==="Chromium")||{}).version||null,M_=uo.platform==="Windows");if(!Th){const r=H.navigator&&H.navigator.userAgent||"";VC=/iPod/i.test(r),WO=function(){const e=r.match(/OS (\d+)_/i);return e&&e[1]?e[1]:null}(),ts=/Android/i.test(r),qO=function(){const e=r.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!e)return null;const t=e[1]&&parseFloat(e[1]),i=e[2]&&parseFloat(e[2]);return t&&i?parseFloat(e[1]+"."+e[2]):t||null}(),jO=/Firefox/i.test(r),Sh=/Edg/i.test(r),Th=/Chrome/i.test(r)||/CriOS/i.test(r),rs=!Sh&&Th,zC=P_=function(){const e=r.match(/(Chrome|CriOS)\/(\d+)/);return e&&e[2]?parseFloat(e[2]):null}(),XO=function(){const e=/MSIE\s(\d+)\.\d/.exec(r);let t=e&&parseFloat(e[1]);return!t&&/Trident\/7.0/i.test(r)&&/rv:11.0/.test(r)&&(t=11),t}(),q0=/Tizen/i.test(r),j0=/Web0S/i.test(r),X0=q0||j0,$0=/Safari/i.test(r)&&!rs&&!ts&&!Sh&&!X0,M_=/Windows/i.test(r),W0=/iPad/i.test(r)||$0&&Xp&&!/iPhone/i.test(r),L_=/iPhone/i.test(r)&&!W0}const xi=L_||W0||VC,k_=($0||xi)&&!rs;var YO=Object.freeze({__proto__:null,get IS_IPOD(){return VC},get IOS_VERSION(){return WO},get IS_ANDROID(){return ts},get ANDROID_VERSION(){return qO},get IS_FIREFOX(){return jO},get IS_EDGE(){return Sh},get IS_CHROMIUM(){return Th},get IS_CHROME(){return rs},get CHROMIUM_VERSION(){return zC},get CHROME_VERSION(){return P_},IS_CHROMECAST_RECEIVER:kee,get IE_VERSION(){return XO},get IS_SAFARI(){return $0},get IS_WINDOWS(){return M_},get IS_IPAD(){return W0},get IS_IPHONE(){return L_},get IS_TIZEN(){return q0},get IS_WEBOS(){return j0},get IS_SMART_TV(){return X0},TOUCH_ENABLED:Xp,IS_IOS:xi,IS_ANY_SAFARI:k_});function kI(r){return typeof r=="string"&&!!r.trim()}function Ree(r){if(r.indexOf(" ")>=0)throw new Error("class has illegal whitespace characters")}function bf(){return de===H.document}function Sf(r){return es(r)&&r.nodeType===1}function KO(){try{return H.parent!==H.self}catch{return!0}}function ZO(r){return function(e,t){if(!kI(e))return de[r](null);kI(t)&&(t=de.querySelector(t));const i=Sf(t)?t:de;return i[r]&&i[r](e)}}function Ke(r="div",e={},t={},i){const n=de.createElement(r);return Object.getOwnPropertyNames(e).forEach(function(a){const s=e[a];a==="textContent"?ll(n,s):(n[a]!==s||a==="tabIndex")&&(n[a]=s)}),Object.getOwnPropertyNames(t).forEach(function(a){n.setAttribute(a,t[a])}),i&&GC(n,i),n}function ll(r,e){return typeof r.textContent>"u"?r.innerText=e:r.textContent=e,r}function PT(r,e){e.firstChild?e.insertBefore(r,e.firstChild):e.appendChild(r)}function vp(r,e){return Ree(e),r.classList.contains(e)}function Au(r,...e){return r.classList.add(...e.reduce((t,i)=>t.concat(i.split(/\s+/)),[])),r}function R_(r,...e){return r?(r.classList.remove(...e.reduce((t,i)=>t.concat(i.split(/\s+/)),[])),r):(pt.warn("removeClass was called with an element that doesn't exist"),null)}function QO(r,e,t){return typeof t=="function"&&(t=t(r,e)),typeof t!="boolean"&&(t=void 0),e.split(/\s+/).forEach(i=>r.classList.toggle(i,t)),r}function JO(r,e){Object.getOwnPropertyNames(e).forEach(function(t){const i=e[t];i===null||typeof i>"u"||i===!1?r.removeAttribute(t):r.setAttribute(t,i===!0?"":i)})}function Co(r){const e={},t=["autoplay","controls","playsinline","loop","muted","default","defaultMuted"];if(r&&r.attributes&&r.attributes.length>0){const i=r.attributes;for(let n=i.length-1;n>=0;n--){const a=i[n].name;let s=i[n].value;t.includes(a)&&(s=s!==null),e[a]=s}}return e}function e7(r,e){return r.getAttribute(e)}function jh(r,e,t){r.setAttribute(e,t)}function O_(r,e){r.removeAttribute(e)}function t7(){de.body.focus(),de.onselectstart=function(){return!1}}function r7(){de.onselectstart=function(){return!0}}function Xh(r){if(r&&r.getBoundingClientRect&&r.parentNode){const e=r.getBoundingClientRect(),t={};return["bottom","height","left","right","top","width"].forEach(i=>{e[i]!==void 0&&(t[i]=e[i])}),t.height||(t.height=parseFloat(Yh(r,"height"))),t.width||(t.width=parseFloat(Yh(r,"width"))),t}}function Yp(r){if(!r||r&&!r.offsetParent)return{left:0,top:0,width:0,height:0};const e=r.offsetWidth,t=r.offsetHeight;let i=0,n=0;for(;r.offsetParent&&r!==de[H0.fullscreenElement];)i+=r.offsetLeft,n+=r.offsetTop,r=r.offsetParent;return{left:i,top:n,width:e,height:t}}function N_(r,e){const t={x:0,y:0};if(xi){let c=r;for(;c&&c.nodeName.toLowerCase()!=="html";){const h=Yh(c,"transform");if(/^matrix/.test(h)){const d=h.slice(7,-1).split(/,\s/).map(Number);t.x+=d[4],t.y+=d[5]}else if(/^matrix3d/.test(h)){const d=h.slice(9,-1).split(/,\s/).map(Number);t.x+=d[12],t.y+=d[13]}if(c.assignedSlot&&c.assignedSlot.parentElement&&H.WebKitCSSMatrix){const d=H.getComputedStyle(c.assignedSlot.parentElement).transform,f=new H.WebKitCSSMatrix(d);t.x+=f.m41,t.y+=f.m42}c=c.parentNode||c.host}}const i={},n=Yp(e.target),a=Yp(r),s=a.width,o=a.height;let l=e.offsetY-(a.top-n.top),u=e.offsetX-(a.left-n.left);return e.changedTouches&&(u=e.changedTouches[0].pageX-a.left,l=e.changedTouches[0].pageY+a.top,xi&&(u-=t.x,l-=t.y)),i.y=1-Math.max(0,Math.min(1,l/o)),i.x=Math.max(0,Math.min(1,u/s)),i}function i7(r){return es(r)&&r.nodeType===3}function B_(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}function n7(r){return typeof r=="function"&&(r=r()),(Array.isArray(r)?r:[r]).map(e=>{if(typeof e=="function"&&(e=e()),Sf(e)||i7(e))return e;if(typeof e=="string"&&/\S/.test(e))return de.createTextNode(e)}).filter(e=>e)}function GC(r,e){return n7(e).forEach(t=>r.appendChild(t)),r}function a7(r,e){return GC(B_(r),e)}function Kp(r){return r.button===void 0&&r.buttons===void 0||r.button===0&&r.buttons===void 0||r.type==="mouseup"&&r.button===0&&r.buttons===0||r.type==="mousedown"&&r.button===0&&r.buttons===0?!0:!(r.button!==0||r.buttons!==1)}const Ko=ZO("querySelector"),s7=ZO("querySelectorAll");function Yh(r,e){if(!r||!e)return"";if(typeof H.getComputedStyle=="function"){let t;try{t=H.getComputedStyle(r)}catch{return""}return t?t.getPropertyValue(e)||t[e]:""}return""}function o7(r){[...de.styleSheets].forEach(e=>{try{const t=[...e.cssRules].map(n=>n.cssText).join(""),i=de.createElement("style");i.textContent=t,r.document.head.appendChild(i)}catch{const i=de.createElement("link");i.rel="stylesheet",i.type=e.type,i.media=e.media.mediaText,i.href=e.href,r.document.head.appendChild(i)}})}var l7=Object.freeze({__proto__:null,isReal:bf,isEl:Sf,isInFrame:KO,createEl:Ke,textContent:ll,prependTo:PT,hasClass:vp,addClass:Au,removeClass:R_,toggleClass:QO,setAttributes:JO,getAttributes:Co,getAttribute:e7,setAttribute:jh,removeAttribute:O_,blockTextSelection:t7,unblockTextSelection:r7,getBoundingClientRect:Xh,findPosition:Yp,getPointerPosition:N_,isTextNode:i7,emptyEl:B_,normalizeContent:n7,appendContent:GC,insertContent:a7,isSingleLeftClick:Kp,$:Ko,$$:s7,computedStyle:Yh,copyStyleSheetsToWindow:o7});let u7=!1,MT;const Oee=function(){if(MT.options.autoSetup===!1)return;const r=Array.prototype.slice.call(de.getElementsByTagName("video")),e=Array.prototype.slice.call(de.getElementsByTagName("audio")),t=Array.prototype.slice.call(de.getElementsByTagName("video-js")),i=r.concat(e,t);if(i&&i.length>0)for(let n=0,a=i.length;n-1&&(n={passive:!0}),r.addEventListener(e,i.dispatcher,n)}else r.attachEvent&&r.attachEvent("on"+e,i.dispatcher)}function ni(r,e,t){if(!Si.has(r))return;const i=Si.get(r);if(!i.handlers)return;if(Array.isArray(e))return HC(ni,r,e,t);const n=function(s,o){i.handlers[o]=[],RI(s,o)};if(e===void 0){for(const s in i.handlers)Object.prototype.hasOwnProperty.call(i.handlers||{},s)&&n(r,s);return}const a=i.handlers[e];if(a){if(!t){n(r,e);return}if(t.guid)for(let s=0;s=e&&(r(...n),t=a)}},f7=function(r,e,t,i=H){let n;const a=()=>{i.clearTimeout(n),n=null},s=function(){const o=this,l=arguments;let u=function(){n=null,u=null,t||r.apply(o,l)};!n&&t&&r.apply(o,l),i.clearTimeout(n),n=i.setTimeout(u,e)};return s.cancel=a,s};var zee=Object.freeze({__proto__:null,UPDATE_REFRESH_INTERVAL:jn,bind_:Ht,throttle:is,debounce:f7});let ld;class _n{on(e,t){const i=this.addEventListener;this.addEventListener=()=>{},yn(this,e,t),this.addEventListener=i}off(e,t){ni(this,e,t)}one(e,t){const i=this.addEventListener;this.addEventListener=()=>{},U_(this,e,t),this.addEventListener=i}any(e,t){const i=this.addEventListener;this.addEventListener=()=>{},$C(this,e,t),this.addEventListener=i}trigger(e){const t=e.type||e;typeof e=="string"&&(e={type:t}),e=F_(e),this.allowedEvents_[t]&&this["on"+t]&&this["on"+t](e),Tf(this,e)}queueTrigger(e){ld||(ld=new Map);const t=e.type||e;let i=ld.get(this);i||(i=new Map,ld.set(this,i));const n=i.get(t);i.delete(t),H.clearTimeout(n);const a=H.setTimeout(()=>{i.delete(t),i.size===0&&(i=null,ld.delete(this)),this.trigger(e)},0);i.set(t,a)}}_n.prototype.allowedEvents_={};_n.prototype.addEventListener=_n.prototype.on;_n.prototype.removeEventListener=_n.prototype.off;_n.prototype.dispatchEvent=_n.prototype.trigger;const V_=r=>typeof r.name=="function"?r.name():typeof r.name=="string"?r.name:r.name_?r.name_:r.constructor&&r.constructor.name?r.constructor.name:typeof r,Ls=r=>r instanceof _n||!!r.eventBusEl_&&["on","one","off","trigger"].every(e=>typeof r[e]=="function"),Gee=(r,e)=>{Ls(r)?e():(r.eventedCallbacks||(r.eventedCallbacks=[]),r.eventedCallbacks.push(e))},RT=r=>typeof r=="string"&&/\S/.test(r)||Array.isArray(r)&&!!r.length,Y0=(r,e,t)=>{if(!r||!r.nodeName&&!Ls(r))throw new Error(`Invalid target for ${V_(e)}#${t}; must be a DOM node or evented object.`)},d7=(r,e,t)=>{if(!RT(r))throw new Error(`Invalid event type for ${V_(e)}#${t}; must be a non-empty string or array.`)},p7=(r,e,t)=>{if(typeof r!="function")throw new Error(`Invalid listener for ${V_(e)}#${t}; must be a function.`)},f2=(r,e,t)=>{const i=e.length<3||e[0]===r||e[0]===r.eventBusEl_;let n,a,s;return i?(n=r.eventBusEl_,e.length>=3&&e.shift(),[a,s]=e):(n=e[0],a=e[1],s=e[2]),Y0(n,r,t),d7(a,r,t),p7(s,r,t),s=Ht(r,s),{isTargetingSelf:i,target:n,type:a,listener:s}},Tl=(r,e,t,i)=>{Y0(r,r,e),r.nodeName?Vee[e](r,t,i):r[e](t,i)},Hee={on(...r){const{isTargetingSelf:e,target:t,type:i,listener:n}=f2(this,r,"on");if(Tl(t,"on",i,n),!e){const a=()=>this.off(t,i,n);a.guid=n.guid;const s=()=>this.off("dispose",a);s.guid=n.guid,Tl(this,"on","dispose",a),Tl(t,"on","dispose",s)}},one(...r){const{isTargetingSelf:e,target:t,type:i,listener:n}=f2(this,r,"one");if(e)Tl(t,"one",i,n);else{const a=(...s)=>{this.off(t,i,a),n.apply(null,s)};a.guid=n.guid,Tl(t,"one",i,a)}},any(...r){const{isTargetingSelf:e,target:t,type:i,listener:n}=f2(this,r,"any");if(e)Tl(t,"any",i,n);else{const a=(...s)=>{this.off(t,i,a),n.apply(null,s)};a.guid=n.guid,Tl(t,"any",i,a)}},off(r,e,t){if(!r||RT(r))ni(this.eventBusEl_,r,e);else{const i=r,n=e;Y0(i,this,"off"),d7(n,this,"off"),p7(t,this,"off"),t=Ht(this,t),this.off("dispose",t),i.nodeName?(ni(i,n,t),ni(i,"dispose",t)):Ls(i)&&(i.off(n,t),i.off("dispose",t))}},trigger(r,e){Y0(this.eventBusEl_,this,"trigger");const t=r&&typeof r!="string"?r.type:r;if(!RT(t))throw new Error(`Invalid event type for ${V_(this)}#trigger; must be a non-empty string or object with a type key that has a non-empty value.`);return Tf(this.eventBusEl_,r,e)}};function WC(r,e={}){const{eventBusKey:t}=e;if(t){if(!r[t].nodeName)throw new Error(`The eventBusKey "${t}" does not refer to an element.`);r.eventBusEl_=r[t]}else r.eventBusEl_=Ke("span",{className:"vjs-event-bus"});return Object.assign(r,Hee),r.eventedCallbacks&&r.eventedCallbacks.forEach(i=>{i()}),r.on("dispose",()=>{r.off(),[r,r.el_,r.eventBusEl_].forEach(function(i){i&&Si.has(i)&&Si.delete(i)}),H.setTimeout(()=>{r.eventBusEl_=null},0)}),r}const $ee={state:{},setState(r){typeof r=="function"&&(r=r());let e;return bh(r,(t,i)=>{this.state[i]!==t&&(e=e||{},e[i]={from:this.state[i],to:t}),this.state[i]=t}),e&&Ls(this)&&this.trigger({changes:e,type:"statechanged"}),e}};function v7(r,e){return Object.assign(r,$ee),r.state=Object.assign({},r.state,e),typeof r.handleStateChanged=="function"&&Ls(r)&&r.on("statechanged",r.handleStateChanged),r}const gp=function(r){return typeof r!="string"?r:r.replace(/./,e=>e.toLowerCase())},nr=function(r){return typeof r!="string"?r:r.replace(/./,e=>e.toUpperCase())},g7=function(r,e){return nr(r)===nr(e)};var Wee=Object.freeze({__proto__:null,toLowerCase:gp,toTitleCase:nr,titleCaseEquals:g7});class ae{constructor(e,t,i){if(!e&&this.play?this.player_=e=this:this.player_=e,this.isDisposed_=!1,this.parentComponent_=null,this.options_=Ut({},this.options_),t=this.options_=Ut(this.options_,t),this.id_=t.id||t.el&&t.el.id,!this.id_){const n=e&&e.id&&e.id()||"no_player";this.id_=`${n}_component_${qn()}`}this.name_=t.name||null,t.el?this.el_=t.el:t.createEl!==!1&&(this.el_=this.createEl()),t.className&&this.el_&&t.className.split(" ").forEach(n=>this.addClass(n)),["on","off","one","any","trigger"].forEach(n=>{this[n]=void 0}),t.evented!==!1&&(WC(this,{eventBusKey:this.el_?"el_":null}),this.handleLanguagechange=this.handleLanguagechange.bind(this),this.on(this.player_,"languagechange",this.handleLanguagechange)),v7(this,this.constructor.defaultState),this.children_=[],this.childIndex_={},this.childNameIndex_={},this.setTimeoutIds_=new Set,this.setIntervalIds_=new Set,this.rafIds_=new Set,this.namedRafs_=new Map,this.clearingTimersOnDispose_=!1,t.initChildren!==!1&&this.initChildren(),this.ready(i),t.reportTouchActivity!==!1&&this.enableTouchActivity()}dispose(e={}){if(!this.isDisposed_){if(this.readyQueue_&&(this.readyQueue_.length=0),this.trigger({type:"dispose",bubbles:!1}),this.isDisposed_=!0,this.children_)for(let t=this.children_.length-1;t>=0;t--)this.children_[t].dispose&&this.children_[t].dispose();this.children_=null,this.childIndex_=null,this.childNameIndex_=null,this.parentComponent_=null,this.el_&&(this.el_.parentNode&&(e.restoreEl?this.el_.parentNode.replaceChild(e.restoreEl,this.el_):this.el_.parentNode.removeChild(this.el_)),this.el_=null),this.player_=null}}isDisposed(){return!!this.isDisposed_}player(){return this.player_}options(e){return e?(this.options_=Ut(this.options_,e),this.options_):this.options_}el(){return this.el_}createEl(e,t,i){return Ke(e,t,i)}localize(e,t,i=e){const n=this.player_.language&&this.player_.language(),a=this.player_.languages&&this.player_.languages(),s=a&&a[n],o=n&&n.split("-")[0],l=a&&a[o];let u=i;return s&&s[e]?u=s[e]:l&&l[e]&&(u=l[e]),t&&(u=u.replace(/\{(\d+)\}/g,function(c,h){const d=t[h-1];let f=d;return typeof d>"u"&&(f=c),f})),u}handleLanguagechange(){}contentEl(){return this.contentEl_||this.el_}id(){return this.id_}name(){return this.name_}children(){return this.children_}getChildById(e){return this.childIndex_[e]}getChild(e){if(e)return this.childNameIndex_[e]}getDescendant(...e){e=e.reduce((i,n)=>i.concat(n),[]);let t=this;for(let i=0;i=0;n--)if(this.children_[n]===e){t=!0,this.children_.splice(n,1);break}if(!t)return;e.parentComponent_=null,this.childIndex_[e.id()]=null,this.childNameIndex_[nr(e.name())]=null,this.childNameIndex_[gp(e.name())]=null;const i=e.el();i&&i.parentNode===this.contentEl()&&this.contentEl().removeChild(e.el())}initChildren(){const e=this.options_.children;if(e){const t=this.options_,i=s=>{const o=s.name;let l=s.opts;if(t[o]!==void 0&&(l=t[o]),l===!1)return;l===!0&&(l={}),l.playerOptions=this.options_.playerOptions;const u=this.addChild(o,l);u&&(this[o]=u)};let n;const a=ae.getComponent("Tech");Array.isArray(e)?n=e:n=Object.keys(e),n.concat(Object.keys(this.options_).filter(function(s){return!n.some(function(o){return typeof o=="string"?s===o:s===o.name})})).map(s=>{let o,l;return typeof s=="string"?(o=s,l=e[o]||this.options_[o]||{}):(o=s.name,l=s),{name:o,opts:l}}).filter(s=>{const o=ae.getComponent(s.opts.componentClass||nr(s.name));return o&&!a.isTech(o)}).forEach(i)}}buildCSSClass(){return""}ready(e,t=!1){if(e){if(!this.isReady_){this.readyQueue_=this.readyQueue_||[],this.readyQueue_.push(e);return}t?e.call(this):this.setTimeout(e,1)}}triggerReady(){this.isReady_=!0,this.setTimeout(function(){const e=this.readyQueue_;this.readyQueue_=[],e&&e.length>0&&e.forEach(function(t){t.call(this)},this),this.trigger("ready")},1)}$(e,t){return Ko(e,t||this.contentEl())}$$(e,t){return s7(e,t||this.contentEl())}hasClass(e){return vp(this.el_,e)}addClass(...e){Au(this.el_,...e)}removeClass(...e){R_(this.el_,...e)}toggleClass(e,t){QO(this.el_,e,t)}show(){this.removeClass("vjs-hidden")}hide(){this.addClass("vjs-hidden")}lockShowing(){this.addClass("vjs-lock-showing")}unlockShowing(){this.removeClass("vjs-lock-showing")}getAttribute(e){return e7(this.el_,e)}setAttribute(e,t){jh(this.el_,e,t)}removeAttribute(e){O_(this.el_,e)}width(e,t){return this.dimension("width",e,t)}height(e,t){return this.dimension("height",e,t)}dimensions(e,t){this.width(e,!0),this.height(t)}dimension(e,t,i){if(t!==void 0){(t===null||t!==t)&&(t=0),(""+t).indexOf("%")!==-1||(""+t).indexOf("px")!==-1?this.el_.style[e]=t:t==="auto"?this.el_.style[e]="":this.el_.style[e]=t+"px",i||this.trigger("componentresize");return}if(!this.el_)return 0;const n=this.el_.style[e],a=n.indexOf("px");return parseInt(a!==-1?n.slice(0,a):this.el_["offset"+nr(e)],10)}currentDimension(e){let t=0;if(e!=="width"&&e!=="height")throw new Error("currentDimension only accepts width or height value");if(t=Yh(this.el_,e),t=parseFloat(t),t===0||isNaN(t)){const i=`offset${nr(e)}`;t=this.el_[i]}return t}currentDimensions(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}}currentWidth(){return this.currentDimension("width")}currentHeight(){return this.currentDimension("height")}getPositions(){const e=this.el_.getBoundingClientRect(),t={x:e.x,y:e.y,width:e.width,height:e.height,top:e.top,right:e.right,bottom:e.bottom,left:e.left},i={x:e.left+e.width/2,y:e.top+e.height/2,width:0,height:0,top:e.top+e.height/2,right:e.left+e.width/2,bottom:e.top+e.height/2,left:e.left+e.width/2};return{boundingClientRect:t,center:i}}focus(){this.el_.focus()}blur(){this.el_.blur()}handleKeyDown(e){this.player_&&(e.key!=="Tab"&&!(this.player_.options_.playerOptions.spatialNavigation&&this.player_.options_.playerOptions.spatialNavigation.enabled)&&e.stopPropagation(),this.player_.handleKeyDown(e))}handleKeyPress(e){this.handleKeyDown(e)}emitTapEvents(){let e=0,t=null;const i=10,n=200;let a;this.on("touchstart",function(o){o.touches.length===1&&(t={pageX:o.touches[0].pageX,pageY:o.touches[0].pageY},e=H.performance.now(),a=!0)}),this.on("touchmove",function(o){if(o.touches.length>1)a=!1;else if(t){const l=o.touches[0].pageX-t.pageX,u=o.touches[0].pageY-t.pageY;Math.sqrt(l*l+u*u)>i&&(a=!1)}});const s=function(){a=!1};this.on("touchleave",s),this.on("touchcancel",s),this.on("touchend",function(o){t=null,a===!0&&H.performance.now()-e{this.setTimeoutIds_.has(i)&&this.setTimeoutIds_.delete(i),e()},t),this.setTimeoutIds_.add(i),i}clearTimeout(e){return this.setTimeoutIds_.has(e)&&(this.setTimeoutIds_.delete(e),H.clearTimeout(e)),e}setInterval(e,t){e=Ht(this,e),this.clearTimersOnDispose_();const i=H.setInterval(e,t);return this.setIntervalIds_.add(i),i}clearInterval(e){return this.setIntervalIds_.has(e)&&(this.setIntervalIds_.delete(e),H.clearInterval(e)),e}requestAnimationFrame(e){this.clearTimersOnDispose_();var t;return e=Ht(this,e),t=H.requestAnimationFrame(()=>{this.rafIds_.has(t)&&this.rafIds_.delete(t),e()}),this.rafIds_.add(t),t}requestNamedAnimationFrame(e,t){this.namedRafs_.has(e)&&this.cancelNamedAnimationFrame(e),this.clearTimersOnDispose_(),t=Ht(this,t);const i=this.requestAnimationFrame(()=>{t(),this.namedRafs_.has(e)&&this.namedRafs_.delete(e)});return this.namedRafs_.set(e,i),e}cancelNamedAnimationFrame(e){this.namedRafs_.has(e)&&(this.cancelAnimationFrame(this.namedRafs_.get(e)),this.namedRafs_.delete(e))}cancelAnimationFrame(e){return this.rafIds_.has(e)&&(this.rafIds_.delete(e),H.cancelAnimationFrame(e)),e}clearTimersOnDispose_(){this.clearingTimersOnDispose_||(this.clearingTimersOnDispose_=!0,this.one("dispose",()=>{[["namedRafs_","cancelNamedAnimationFrame"],["rafIds_","cancelAnimationFrame"],["setTimeoutIds_","clearTimeout"],["setIntervalIds_","clearInterval"]].forEach(([e,t])=>{this[e].forEach((i,n)=>this[t](n))}),this.clearingTimersOnDispose_=!1}))}getIsDisabled(){return!!this.el_.disabled}getIsExpresslyInert(){return this.el_.inert&&!this.el_.ownerDocument.documentElement.inert}getIsFocusable(e){return(e||this.el_).tabIndex>=0&&!(this.getIsDisabled()||this.getIsExpresslyInert())}getIsAvailableToBeFocused(e){function t(a){const s=H.getComputedStyle(a,null),o=s.getPropertyValue("visibility");return s.getPropertyValue("display")!=="none"&&!["hidden","collapse"].includes(o)}function i(a){return!(!t(a.parentElement)||!t(a)||a.style.opacity==="0"||H.getComputedStyle(a).height==="0px"||H.getComputedStyle(a).width==="0px")}function n(a){if(a.offsetWidth+a.offsetHeight+a.getBoundingClientRect().height+a.getBoundingClientRect().width===0)return!1;const s={x:a.getBoundingClientRect().left+a.offsetWidth/2,y:a.getBoundingClientRect().top+a.offsetHeight/2};if(s.x<0||s.x>(de.documentElement.clientWidth||H.innerWidth)||s.y<0||s.y>(de.documentElement.clientHeight||H.innerHeight))return!1;let o=de.elementFromPoint(s.x,s.y);for(;o;){if(o===a)return!0;if(o.parentNode)o=o.parentNode;else return!1}}return e||(e=this.el()),!!(n(e)&&i(e)&&(!e.parentElement||e.tabIndex>=0))}static registerComponent(e,t){if(typeof e!="string"||!e)throw new Error(`Illegal component name, "${e}"; must be a non-empty string.`);const i=ae.getComponent("Tech"),n=i&&i.isTech(t),a=ae===t||ae.prototype.isPrototypeOf(t.prototype);if(n||!a){let o;throw n?o="techs must be registered using Tech.registerTech()":o="must be a Component subclass",new Error(`Illegal component, "${e}"; ${o}.`)}e=nr(e),ae.components_||(ae.components_={});const s=ae.getComponent("Player");if(e==="Player"&&s&&s.players){const o=s.players,l=Object.keys(o);if(o&&l.length>0&&l.map(u=>o[u]).every(Boolean))throw new Error("Can not register Player component after player has been created.")}return ae.components_[e]=t,ae.components_[gp(e)]=t,t}static getComponent(e){if(!(!e||!ae.components_))return ae.components_[e]}}ae.registerComponent("Component",ae);function qee(r,e,t){if(typeof e!="number"||e<0||e>t)throw new Error(`Failed to execute '${r}' on 'TimeRanges': The index provided (${e}) is non-numeric or out of bounds (0-${t}).`)}function OI(r,e,t,i){return qee(r,i,t.length-1),t[i][e]}function d2(r){let e;return r===void 0||r.length===0?e={length:0,start(){throw new Error("This TimeRanges object is empty")},end(){throw new Error("This TimeRanges object is empty")}}:e={length:r.length,start:OI.bind(null,"start",0,r),end:OI.bind(null,"end",1,r)},H.Symbol&&H.Symbol.iterator&&(e[H.Symbol.iterator]=()=>(r||[]).values()),e}function pa(r,e){return Array.isArray(r)?d2(r):r===void 0||e===void 0?d2():d2([[r,e]])}const m7=function(r,e){r=r<0?0:r;let t=Math.floor(r%60),i=Math.floor(r/60%60),n=Math.floor(r/3600);const a=Math.floor(e/60%60),s=Math.floor(e/3600);return(isNaN(r)||r===1/0)&&(n=i=t="-"),n=n>0||s>0?n+":":"",i=((n||a>=10)&&i<10?"0"+i:i)+":",t=t<10?"0"+t:t,n+i+t};let qC=m7;function y7(r){qC=r}function _7(){qC=m7}function Xu(r,e=r){return qC(r,e)}var jee=Object.freeze({__proto__:null,createTimeRanges:pa,createTimeRange:pa,setFormatTime:y7,resetFormatTime:_7,formatTime:Xu});function b7(r,e){let t=0,i,n;if(!e)return 0;(!r||!r.length)&&(r=pa(0,0));for(let a=0;ae&&(n=e),t+=n-i;return t/e}function tr(r){if(r instanceof tr)return r;typeof r=="number"?this.code=r:typeof r=="string"?this.message=r:es(r)&&(typeof r.code=="number"&&(this.code=r.code),Object.assign(this,r)),this.message||(this.message=tr.defaultMessages[this.code]||"")}tr.prototype.code=0;tr.prototype.message="";tr.prototype.status=null;tr.prototype.metadata=null;tr.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"];tr.defaultMessages={1:"You aborted the media playback",2:"A network error caused the media download to fail part-way.",3:"The media playback was aborted due to a corruption problem or because the media used features your browser did not support.",4:"The media could not be loaded, either because the server or network failed or because the format is not supported.",5:"The media is encrypted and we do not have the keys to decrypt it."};tr.MEDIA_ERR_CUSTOM=0;tr.prototype.MEDIA_ERR_CUSTOM=0;tr.MEDIA_ERR_ABORTED=1;tr.prototype.MEDIA_ERR_ABORTED=1;tr.MEDIA_ERR_NETWORK=2;tr.prototype.MEDIA_ERR_NETWORK=2;tr.MEDIA_ERR_DECODE=3;tr.prototype.MEDIA_ERR_DECODE=3;tr.MEDIA_ERR_SRC_NOT_SUPPORTED=4;tr.prototype.MEDIA_ERR_SRC_NOT_SUPPORTED=4;tr.MEDIA_ERR_ENCRYPTED=5;tr.prototype.MEDIA_ERR_ENCRYPTED=5;function mp(r){return r!=null&&typeof r.then=="function"}function Va(r){mp(r)&&r.then(null,e=>{})}const OT=function(r){return["kind","label","language","id","inBandMetadataTrackDispatchType","mode","src"].reduce((t,i,n)=>(r[i]&&(t[i]=r[i]),t),{cues:r.cues&&Array.prototype.map.call(r.cues,function(t){return{startTime:t.startTime,endTime:t.endTime,text:t.text,id:t.id}})})},Xee=function(r){const e=r.$$("track"),t=Array.prototype.map.call(e,n=>n.track);return Array.prototype.map.call(e,function(n){const a=OT(n.track);return n.src&&(a.src=n.src),a}).concat(Array.prototype.filter.call(r.textTracks(),function(n){return t.indexOf(n)===-1}).map(OT))},Yee=function(r,e){return r.forEach(function(t){const i=e.addRemoteTextTrack(t).track;!t.src&&t.cues&&t.cues.forEach(n=>i.addCue(n))}),e.textTracks()};var NI={textTracksToJson:Xee,jsonToTextTracks:Yee,trackToJson_:OT};const p2="vjs-modal-dialog";class xf extends ae{constructor(e,t){super(e,t),this.handleKeyDown_=i=>this.handleKeyDown(i),this.close_=i=>this.close(i),this.opened_=this.hasBeenOpened_=this.hasBeenFilled_=!1,this.closeable(!this.options_.uncloseable),this.content(this.options_.content),this.contentEl_=Ke("div",{className:`${p2}-content`},{role:"document"}),this.descEl_=Ke("p",{className:`${p2}-description vjs-control-text`,id:this.el().getAttribute("aria-describedby")}),ll(this.descEl_,this.description()),this.el_.appendChild(this.descEl_),this.el_.appendChild(this.contentEl_)}createEl(){return super.createEl("div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-describedby":`${this.id()}_description`,"aria-hidden":"true","aria-label":this.label(),role:"dialog","aria-live":"polite"})}dispose(){this.contentEl_=null,this.descEl_=null,this.previouslyActiveEl_=null,super.dispose()}buildCSSClass(){return`${p2} vjs-hidden ${super.buildCSSClass()}`}label(){return this.localize(this.options_.label||"Modal Window")}description(){let e=this.options_.description||this.localize("This is a modal window.");return this.closeable()&&(e+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),e}open(){if(this.opened_){this.options_.fillAlways&&this.fill();return}const e=this.player();this.trigger("beforemodalopen"),this.opened_=!0,(this.options_.fillAlways||!this.hasBeenOpened_&&!this.hasBeenFilled_)&&this.fill(),this.wasPlaying_=!e.paused(),this.options_.pauseOnOpen&&this.wasPlaying_&&e.pause(),this.on("keydown",this.handleKeyDown_),this.hadControls_=e.controls(),e.controls(!1),this.show(),this.conditionalFocus_(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.hasBeenOpened_=!0}opened(e){return typeof e=="boolean"&&this[e?"open":"close"](),this.opened_}close(){if(!this.opened_)return;const e=this.player();this.trigger("beforemodalclose"),this.opened_=!1,this.wasPlaying_&&this.options_.pauseOnOpen&&e.play(),this.off("keydown",this.handleKeyDown_),this.hadControls_&&e.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger({type:"modalclose",bubbles:!0}),this.conditionalBlur_(),this.options_.temporary&&this.dispose()}closeable(e){if(typeof e=="boolean"){const t=this.closeable_=!!e;let i=this.getChild("closeButton");if(t&&!i){const n=this.contentEl_;this.contentEl_=this.el_,i=this.addChild("closeButton",{controlText:"Close Modal Dialog"}),this.contentEl_=n,this.on(i,"close",this.close_)}!t&&i&&(this.off(i,"close",this.close_),this.removeChild(i),i.dispose())}return this.closeable_}fill(){this.fillWith(this.content())}fillWith(e){const t=this.contentEl(),i=t.parentNode,n=t.nextSibling;this.trigger("beforemodalfill"),this.hasBeenFilled_=!0,i.removeChild(t),this.empty(),a7(t,e),this.trigger("modalfill"),n?i.insertBefore(t,n):i.appendChild(t);const a=this.getChild("closeButton");a&&i.appendChild(a.el_),this.trigger("aftermodalfill")}empty(){this.trigger("beforemodalempty"),B_(this.contentEl()),this.trigger("modalempty")}content(e){return typeof e<"u"&&(this.content_=e),this.content_}conditionalFocus_(){const e=de.activeElement,t=this.player_.el_;this.previouslyActiveEl_=null,(t.contains(e)||t===e)&&(this.previouslyActiveEl_=e,this.focus())}conditionalBlur_(){this.previouslyActiveEl_&&(this.previouslyActiveEl_.focus(),this.previouslyActiveEl_=null)}handleKeyDown(e){if(this.trigger({type:"modalKeydown",originalEvent:e,target:this,bubbles:!0}),e.stopPropagation(),e.key==="Escape"&&this.closeable()){e.preventDefault(),this.close();return}if(e.key!=="Tab")return;const t=this.focusableEls_(),i=this.el_.querySelector(":focus");let n;for(let a=0;a(t instanceof H.HTMLAnchorElement||t instanceof H.HTMLAreaElement)&&t.hasAttribute("href")||(t instanceof H.HTMLInputElement||t instanceof H.HTMLSelectElement||t instanceof H.HTMLTextAreaElement||t instanceof H.HTMLButtonElement)&&!t.hasAttribute("disabled")||t instanceof H.HTMLIFrameElement||t instanceof H.HTMLObjectElement||t instanceof H.HTMLEmbedElement||t.hasAttribute("tabindex")&&t.getAttribute("tabindex")!==-1||t.hasAttribute("contenteditable"))}}xf.prototype.options_={pauseOnOpen:!0,temporary:!0};ae.registerComponent("ModalDialog",xf);class Kh extends _n{constructor(e=[]){super(),this.tracks_=[],Object.defineProperty(this,"length",{get(){return this.tracks_.length}});for(let t=0;t{this.trigger({track:e,type:"labelchange",target:this})},Ls(e)&&e.addEventListener("labelchange",e.labelchange_)}removeTrack(e){let t;for(let i=0,n=this.length;i=0;t--)if(e[t].enabled){v2(e,e[t]);break}super(e),this.changing_=!1}addTrack(e){e.enabled&&v2(this,e),super.addTrack(e),e.addEventListener&&(e.enabledChange_=()=>{this.changing_||(this.changing_=!0,v2(this,e),this.changing_=!1,this.trigger("change"))},e.addEventListener("enabledchange",e.enabledChange_))}removeTrack(e){super.removeTrack(e),e.removeEventListener&&e.enabledChange_&&(e.removeEventListener("enabledchange",e.enabledChange_),e.enabledChange_=null)}}const g2=function(r,e){for(let t=0;t=0;t--)if(e[t].selected){g2(e,e[t]);break}super(e),this.changing_=!1,Object.defineProperty(this,"selectedIndex",{get(){for(let t=0;t{this.changing_||(this.changing_=!0,g2(this,e),this.changing_=!1,this.trigger("change"))},e.addEventListener("selectedchange",e.selectedChange_))}removeTrack(e){super.removeTrack(e),e.removeEventListener&&e.selectedChange_&&(e.removeEventListener("selectedchange",e.selectedChange_),e.selectedChange_=null)}}class S7 extends Kh{addTrack(e){super.addTrack(e),this.queueChange_||(this.queueChange_=()=>this.queueTrigger("change")),this.triggerSelectedlanguagechange||(this.triggerSelectedlanguagechange_=()=>this.trigger("selectedlanguagechange")),e.addEventListener("modechange",this.queueChange_),["metadata","chapters"].indexOf(e.kind)===-1&&e.addEventListener("modechange",this.triggerSelectedlanguagechange_)}removeTrack(e){super.removeTrack(e),e.removeEventListener&&(this.queueChange_&&e.removeEventListener("modechange",this.queueChange_),this.selectedlanguagechange_&&e.removeEventListener("modechange",this.triggerSelectedlanguagechange_))}}class Qee{constructor(e=[]){this.trackElements_=[],Object.defineProperty(this,"length",{get(){return this.trackElements_.length}});for(let t=0,i=e.length;t0&&(H.console&&H.console.groupCollapsed&&H.console.groupCollapsed(`Text Track parsing errors for ${e.src}`),i.forEach(n=>pt.error(n)),H.console&&H.console.groupEnd&&H.console.groupEnd()),t.flush()},UI=function(r,e){const t={uri:r},i=z_(r);i&&(t.cors=i);const n=e.tech_.crossOrigin()==="use-credentials";n&&(t.withCredentials=n),$6(t,Ht(this,function(a,s,o){if(a)return pt.error(a,s);e.loaded_=!0,typeof H.WebVTT!="function"?e.tech_&&e.tech_.any(["vttjsloaded","vttjserror"],l=>{if(l.type==="vttjserror"){pt.error(`vttjs failed to load, stopping trying to process ${e.src}`);return}return FI(o,e)}):FI(o,e)}))};class Hv extends jC{constructor(e={}){if(!e.tech)throw new Error("A tech was not provided.");const t=Ut(e,{kind:tte[e.kind]||"subtitles",language:e.language||e.srclang||""});let i=BI[t.mode]||"disabled";const n=t.default;(t.kind==="metadata"||t.kind==="chapters")&&(i="hidden"),super(t),this.tech_=t.tech,this.cues_=[],this.activeCues_=[],this.preload_=this.tech_.preloadTextTracks!==!1;const a=new K0(this.cues_),s=new K0(this.activeCues_);let o=!1;this.timeupdateHandler=Ht(this,function(u={}){if(!this.tech_.isDisposed()){if(!this.tech_.isReady_){u.type!=="timeupdate"&&(this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler));return}this.activeCues=this.activeCues,o&&(this.trigger("cuechange"),o=!1),u.type!=="timeupdate"&&(this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler))}});const l=()=>{this.stopTracking()};this.tech_.one("dispose",l),i!=="disabled"&&this.startTracking(),Object.defineProperties(this,{default:{get(){return n},set(){}},mode:{get(){return i},set(u){BI[u]&&i!==u&&(i=u,!this.preload_&&i!=="disabled"&&this.cues.length===0&&UI(this.src,this),this.stopTracking(),i!=="disabled"&&this.startTracking(),this.trigger("modechange"))}},cues:{get(){return this.loaded_?a:null},set(){}},activeCues:{get(){if(!this.loaded_)return null;if(this.cues.length===0)return s;const u=this.tech_.currentTime(),c=[];for(let h=0,d=this.cues.length;h=u&&c.push(f)}if(o=!1,c.length!==this.activeCues_.length)o=!0;else for(let h=0;h{t=zs.LOADED,this.trigger({type:"load",target:this})})}}zs.prototype.allowedEvents_={load:"load"};zs.NONE=0;zs.LOADING=1;zs.LOADED=2;zs.ERROR=3;const Hn={audio:{ListClass:Kee,TrackClass:x7,capitalName:"Audio"},video:{ListClass:Zee,TrackClass:w7,capitalName:"Video"},text:{ListClass:S7,TrackClass:Hv,capitalName:"Text"}};Object.keys(Hn).forEach(function(r){Hn[r].getterName=`${r}Tracks`,Hn[r].privateName=`${r}Tracks_`});const Zh={remoteText:{ListClass:S7,TrackClass:Hv,capitalName:"RemoteText",getterName:"remoteTextTracks",privateName:"remoteTextTracks_"},remoteTextEl:{ListClass:Qee,TrackClass:zs,capitalName:"RemoteTextTrackEls",getterName:"remoteTextTrackEls",privateName:"remoteTextTrackEls_"}},_i=Object.assign({},Hn,Zh);Zh.names=Object.keys(Zh);Hn.names=Object.keys(Hn);_i.names=[].concat(Zh.names).concat(Hn.names);function ite(r,e,t,i,n={}){const a=r.textTracks();n.kind=e,t&&(n.label=t),i&&(n.language=i),n.tech=r;const s=new _i.text.TrackClass(n);return a.addTrack(s),s}class it extends ae{constructor(e={},t=function(){}){e.reportTouchActivity=!1,super(null,e,t),this.onDurationChange_=i=>this.onDurationChange(i),this.trackProgress_=i=>this.trackProgress(i),this.trackCurrentTime_=i=>this.trackCurrentTime(i),this.stopTrackingCurrentTime_=i=>this.stopTrackingCurrentTime(i),this.disposeSourceHandler_=i=>this.disposeSourceHandler(i),this.queuedHanders_=new Set,this.hasStarted_=!1,this.on("playing",function(){this.hasStarted_=!0}),this.on("loadstart",function(){this.hasStarted_=!1}),_i.names.forEach(i=>{const n=_i[i];e&&e[n.getterName]&&(this[n.privateName]=e[n.getterName])}),this.featuresProgressEvents||this.manualProgressOn(),this.featuresTimeupdateEvents||this.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach(i=>{e[`native${i}Tracks`]===!1&&(this[`featuresNative${i}Tracks`]=!1)}),e.nativeCaptions===!1||e.nativeTextTracks===!1?this.featuresNativeTextTracks=!1:(e.nativeCaptions===!0||e.nativeTextTracks===!0)&&(this.featuresNativeTextTracks=!0),this.featuresNativeTextTracks||this.emulateTextTracks(),this.preloadTextTracks=e.preloadTextTracks!==!1,this.autoRemoteTextTracks_=new _i.text.ListClass,this.initTrackListeners(),e.nativeControlsForTouch||this.emitTapEvents(),this.constructor&&(this.name_=this.constructor.name||"Unknown Tech")}triggerSourceset(e){this.isReady_||this.one("ready",()=>this.setTimeout(()=>this.triggerSourceset(e),1)),this.trigger({src:e,type:"sourceset"})}manualProgressOn(){this.on("durationchange",this.onDurationChange_),this.manualProgress=!0,this.one("ready",this.trackProgress_)}manualProgressOff(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange_)}trackProgress(e){this.stopTrackingProgress(),this.progressInterval=this.setInterval(Ht(this,function(){const t=this.bufferedPercent();this.bufferedPercent_!==t&&this.trigger("progress"),this.bufferedPercent_=t,t===1&&this.stopTrackingProgress()}),500)}onDurationChange(e){this.duration_=this.duration()}buffered(){return pa(0,0)}bufferedPercent(){return b7(this.buffered(),this.duration_)}stopTrackingProgress(){this.clearInterval(this.progressInterval)}manualTimeUpdatesOn(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime_),this.on("pause",this.stopTrackingCurrentTime_)}manualTimeUpdatesOff(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime_),this.off("pause",this.stopTrackingCurrentTime_)}trackCurrentTime(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval(function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},250)}stopTrackingCurrentTime(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}dispose(){this.clearTracks(Hn.names),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),super.dispose()}clearTracks(e){e=[].concat(e),e.forEach(t=>{const i=this[`${t}Tracks`]()||[];let n=i.length;for(;n--;){const a=i[n];t==="text"&&this.removeRemoteTextTrack(a),i.removeTrack(a)}})}cleanupAutoTextTracks(){const e=this.autoRemoteTextTracks_||[];let t=e.length;for(;t--;){const i=e[t];this.removeRemoteTextTrack(i)}}reset(){}crossOrigin(){}setCrossOrigin(){}error(e){return e!==void 0&&(this.error_=new tr(e),this.trigger("error")),this.error_}played(){return this.hasStarted_?pa(0,0):pa()}play(){}setScrubbing(e){}scrubbing(){}setCurrentTime(e){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}initTrackListeners(){Hn.names.forEach(e=>{const t=Hn[e],i=()=>{this.trigger(`${e}trackchange`)},n=this[t.getterName]();n.addEventListener("removetrack",i),n.addEventListener("addtrack",i),this.on("dispose",()=>{n.removeEventListener("removetrack",i),n.removeEventListener("addtrack",i)})})}addWebVttScript_(){if(!H.WebVTT)if(de.body.contains(this.el())){if(!this.options_["vtt.js"]&&qh(rI)&&Object.keys(rI).length>0){this.trigger("vttjsloaded");return}const e=de.createElement("script");e.src=this.options_["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.14.1/vtt.min.js",e.onload=()=>{this.trigger("vttjsloaded")},e.onerror=()=>{this.trigger("vttjserror")},this.on("dispose",()=>{e.onload=null,e.onerror=null}),H.WebVTT=!0,this.el().parentNode.appendChild(e)}else this.ready(this.addWebVttScript_)}emulateTextTracks(){const e=this.textTracks(),t=this.remoteTextTracks(),i=o=>e.addTrack(o.track),n=o=>e.removeTrack(o.track);t.on("addtrack",i),t.on("removetrack",n),this.addWebVttScript_();const a=()=>this.trigger("texttrackchange"),s=()=>{a();for(let o=0;othis.autoRemoteTextTracks_.addTrack(i.track)),i}removeRemoteTextTrack(e){const t=this.remoteTextTrackEls().getTrackElementByTrack_(e);this.remoteTextTrackEls().removeTrackElement_(t),this.remoteTextTracks().removeTrack(e),this.autoRemoteTextTracks_.removeTrack(e)}getVideoPlaybackQuality(){return{}}requestPictureInPicture(){return Promise.reject()}disablePictureInPicture(){return!0}setDisablePictureInPicture(){}requestVideoFrameCallback(e){const t=qn();return!this.isReady_||this.paused()?(this.queuedHanders_.add(t),this.one("playing",()=>{this.queuedHanders_.has(t)&&(this.queuedHanders_.delete(t),e())})):this.requestNamedAnimationFrame(t,e),t}cancelVideoFrameCallback(e){this.queuedHanders_.has(e)?this.queuedHanders_.delete(e):this.cancelNamedAnimationFrame(e)}setPoster(){}playsinline(){}setPlaysinline(){}overrideNativeAudioTracks(e){}overrideNativeVideoTracks(e){}canPlayType(e){return""}static canPlayType(e){return""}static canPlaySource(e,t){return it.canPlayType(e.type)}static isTech(e){return e.prototype instanceof it||e instanceof it||e===it}static registerTech(e,t){if(it.techs_||(it.techs_={}),!it.isTech(t))throw new Error(`Tech ${e} must be a Tech`);if(!it.canPlayType)throw new Error("Techs must have a static canPlayType method on them");if(!it.canPlaySource)throw new Error("Techs must have a static canPlaySource method on them");return e=nr(e),it.techs_[e]=t,it.techs_[gp(e)]=t,e!=="Tech"&&it.defaultTechOrder_.push(e),t}static getTech(e){if(e){if(it.techs_&&it.techs_[e])return it.techs_[e];if(e=nr(e),H&&H.videojs&&H.videojs[e])return pt.warn(`The ${e} tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)`),H.videojs[e]}}}_i.names.forEach(function(r){const e=_i[r];it.prototype[e.getterName]=function(){return this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName]}});it.prototype.featuresVolumeControl=!0;it.prototype.featuresMuteControl=!0;it.prototype.featuresFullscreenResize=!1;it.prototype.featuresPlaybackRate=!1;it.prototype.featuresProgressEvents=!1;it.prototype.featuresSourceset=!1;it.prototype.featuresTimeupdateEvents=!1;it.prototype.featuresNativeTextTracks=!1;it.prototype.featuresVideoFrameCallback=!1;it.withSourceHandlers=function(r){r.registerSourceHandler=function(t,i){let n=r.sourceHandlers;n||(n=r.sourceHandlers=[]),i===void 0&&(i=n.length),n.splice(i,0,t)},r.canPlayType=function(t){const i=r.sourceHandlers||[];let n;for(let a=0;aZl(e,Du[e.type],t,r),1)}function ste(r,e){r.forEach(t=>t.setTech&&t.setTech(e))}function ote(r,e,t){return r.reduceRight(KC(t),e[t]())}function lte(r,e,t,i){return e[t](r.reduce(KC(t),i))}function VI(r,e,t,i=null){const n="call"+nr(t),a=r.reduce(KC(n),i),s=a===Q0,o=s?null:e[t](a);return hte(r,t,o,s),o}const ute={buffered:1,currentTime:1,duration:1,muted:1,played:1,paused:1,seekable:1,volume:1,ended:1},cte={setCurrentTime:1,setMuted:1,setVolume:1},zI={play:1,pause:1};function KC(r){return(e,t)=>e===Q0?Q0:t[r]?t[r](e):e}function hte(r,e,t,i){for(let n=r.length-1;n>=0;n--){const a=r[n];a[e]&&a[e](i,t)}}function fte(r){Z0.hasOwnProperty(r.id())&&delete Z0[r.id()]}function dte(r,e){const t=Z0[r.id()];let i=null;if(t==null)return i=e(r),Z0[r.id()]=[[e,i]],i;for(let n=0;n{if(!e)return"";if(r.cache_.source.src===e&&r.cache_.source.type)return r.cache_.source.type;const t=r.cache_.sources.filter(n=>n.src===e);if(t.length)return t[0].type;const i=r.$$("source");for(let n=0;n + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +`;const HI=q0?10009:j0?461:8,Ic={codes:{play:415,pause:19,ff:417,rw:412,back:HI},names:{415:"play",19:"pause",417:"ff",412:"rw",[HI]:"back"},isEventKey(r,e){return e=e.toLowerCase(),!!(this.names[r.keyCode]&&this.names[r.keyCode]===e)},getEventName(r){if(this.names[r.keyCode])return this.names[r.keyCode];if(this.codes[r.code]){const e=this.codes[r.code];return this.names[e]}return null}},$I=5;class mte extends _n{constructor(e){super(),this.player_=e,this.focusableComponents=[],this.isListening_=!1,this.isPaused_=!1,this.onKeyDown_=this.onKeyDown_.bind(this),this.lastFocusedComponent_=null}start(){this.isListening_||(this.player_.on("keydown",this.onKeyDown_),this.player_.on("modalKeydown",this.onKeyDown_),this.player_.on("loadedmetadata",()=>{this.focus(this.updateFocusableComponents()[0])}),this.player_.on("modalclose",()=>{this.refocusComponent()}),this.player_.on("focusin",this.handlePlayerFocus_.bind(this)),this.player_.on("focusout",this.handlePlayerBlur_.bind(this)),this.isListening_=!0,this.player_.errorDisplay&&this.player_.errorDisplay.on("aftermodalfill",()=>{this.updateFocusableComponents(),this.focusableComponents.length&&(this.focusableComponents.length>1?this.focusableComponents[1].focus():this.focusableComponents[0].focus())}))}stop(){this.player_.off("keydown",this.onKeyDown_),this.isListening_=!1}onKeyDown_(e){const t=e.originalEvent?e.originalEvent:e;if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].includes(t.key)){if(this.isPaused_)return;t.preventDefault();const i=t.key.substring(5).toLowerCase();this.move(i)}else if(Ic.isEventKey(t,"play")||Ic.isEventKey(t,"pause")||Ic.isEventKey(t,"ff")||Ic.isEventKey(t,"rw")){t.preventDefault();const i=Ic.getEventName(t);this.performMediaAction_(i)}else Ic.isEventKey(t,"Back")&&e.target&&typeof e.target.closeable=="function"&&e.target.closeable()&&(t.preventDefault(),e.target.close())}performMediaAction_(e){if(this.player_)switch(e){case"play":this.player_.paused()&&this.player_.play();break;case"pause":this.player_.paused()||this.player_.pause();break;case"ff":this.userSeek_(this.player_.currentTime()+$I);break;case"rw":this.userSeek_(this.player_.currentTime()-$I);break}}userSeek_(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&this.player_.liveTracker.nextSeekedFromUser(),this.player_.currentTime(e)}pause(){this.isPaused_=!0}resume(){this.isPaused_=!1}handlePlayerBlur_(e){const t=e.relatedTarget;let i=null;const n=this.getCurrentComponent(e.target);t&&(i=!!t.closest(".video-js"),t.classList.contains("vjs-text-track-settings")&&!this.isPaused_&&this.searchForTrackSelect_()),(!e.currentTarget.contains(e.relatedTarget)&&!i||!t)&&(n&&n.name()==="CloseButton"?this.refocusComponent():(this.pause(),n&&n.el()&&(this.lastFocusedComponent_=n)))}handlePlayerFocus_(){this.getCurrentComponent()&&this.getCurrentComponent().getIsFocusable()&&this.resume()}updateFocusableComponents(){const e=this.player_,t=[];function i(n){for(const a of n)a.hasOwnProperty("el_")&&a.getIsFocusable()&&a.getIsAvailableToBeFocused(a.el())&&t.push(a),a.hasOwnProperty("children_")&&a.children_.length>0&&i(a.children_)}return e.children_.forEach(n=>{if(n.hasOwnProperty("el_"))if(n.getIsFocusable&&n.getIsAvailableToBeFocused&&n.getIsFocusable()&&n.getIsAvailableToBeFocused(n.el())){t.push(n);return}else n.hasOwnProperty("children_")&&n.children_.length>0?i(n.children_):n.hasOwnProperty("items")&&n.items.length>0?i(n.items):this.findSuitableDOMChild(n)&&t.push(n);if(n.name_==="ErrorDisplay"&&n.opened_){const a=n.el_.querySelector(".vjs-errors-ok-button-container");a&&a.querySelectorAll("button").forEach((o,l)=>{t.push({name:()=>"ModalButton"+(l+1),el:()=>o,getPositions:()=>{const u=o.getBoundingClientRect(),c={x:u.x,y:u.y,width:u.width,height:u.height,top:u.top,right:u.right,bottom:u.bottom,left:u.left},h={x:u.left+u.width/2,y:u.top+u.height/2,width:0,height:0,top:u.top+u.height/2,right:u.left+u.width/2,bottom:u.top+u.height/2,left:u.left+u.width/2};return{boundingClientRect:c,center:h}},getIsAvailableToBeFocused:()=>!0,getIsFocusable:u=>!0,focus:()=>o.focus()})})}}),this.focusableComponents=t,this.focusableComponents}findSuitableDOMChild(e){function t(i){if(e.getIsFocusable(i)&&e.getIsAvailableToBeFocused(i))return i;for(let n=0;n0&&(this.focusableComponents=[],this.trigger({type:"focusableComponentsChanged",focusableComponents:this.focusableComponents}))}move(e){const t=this.getCurrentComponent();if(!t)return;const i=t.getPositions(),n=this.focusableComponents.filter(s=>s!==t&&this.isInDirection_(i.boundingClientRect,s.getPositions().boundingClientRect,e)),a=this.findBestCandidate_(i.center,n,e);a?this.focus(a):this.trigger({type:"endOfFocusableComponents",direction:e,focusedComponent:t})}findBestCandidate_(e,t,i){let n=1/0,a=null;for(const s of t){const o=s.getPositions().center,l=this.calculateDistance_(e,o,i);l=e.right;case"left":return t.right<=e.left;case"down":return t.top>=e.bottom;case"up":return t.bottom<=e.top;default:return!1}}refocusComponent(){if(this.lastFocusedComponent_){this.player_.userActive()||this.player_.userActive(!0),this.updateFocusableComponents();for(let e=0;ethis.handleMouseOver(i),this.handleMouseOut_=i=>this.handleMouseOut(i),this.handleClick_=i=>this.handleClick(i),this.handleKeyDown_=i=>this.handleKeyDown(i),this.emitTapEvents(),this.enable()}createEl(e="div",t={},i={}){t=Object.assign({className:this.buildCSSClass(),tabIndex:0},t),e==="button"&&pt.error(`Creating a ClickableComponent with an HTML element of ${e} is not supported; use a Button instead.`),i=Object.assign({role:"button"},i),this.tabIndex_=t.tabIndex;const n=Ke(e,t,i);return this.player_.options_.experimentalSvgIcons||n.appendChild(Ke("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),this.createControlTextEl(n),n}dispose(){this.controlTextEl_=null,super.dispose()}createControlTextEl(e){return this.controlTextEl_=Ke("span",{className:"vjs-control-text"},{"aria-live":"polite"}),e&&e.appendChild(this.controlTextEl_),this.controlText(this.controlText_,e),this.controlTextEl_}controlText(e,t=this.el()){if(e===void 0)return this.controlText_||"Need Text";const i=this.localize(e);this.controlText_=e,ll(this.controlTextEl_,i),!this.nonIconControl&&!this.player_.options_.noUITitleAttributes&&t.setAttribute("title",i)}buildCSSClass(){return`vjs-control vjs-button ${super.buildCSSClass()}`}enable(){this.enabled_||(this.enabled_=!0,this.removeClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","false"),typeof this.tabIndex_<"u"&&this.el_.setAttribute("tabIndex",this.tabIndex_),this.on(["tap","click"],this.handleClick_),this.on("keydown",this.handleKeyDown_))}disable(){this.enabled_=!1,this.addClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","true"),typeof this.tabIndex_<"u"&&this.el_.removeAttribute("tabIndex"),this.off("mouseover",this.handleMouseOver_),this.off("mouseout",this.handleMouseOut_),this.off(["tap","click"],this.handleClick_),this.off("keydown",this.handleKeyDown_)}handleLanguagechange(){this.controlText(this.controlText_)}handleClick(e){this.options_.clickHandler&&this.options_.clickHandler.call(this,arguments)}handleKeyDown(e){e.key===" "||e.key==="Enter"?(e.preventDefault(),e.stopPropagation(),this.trigger("click")):super.handleKeyDown(e)}}ae.registerComponent("ClickableComponent",G_);class NT extends G_{constructor(e,t){super(e,t),this.update(),this.update_=i=>this.update(i),e.on("posterchange",this.update_)}dispose(){this.player().off("posterchange",this.update_),super.dispose()}createEl(){return Ke("div",{className:"vjs-poster"})}crossOrigin(e){if(typeof e>"u")return this.$("img")?this.$("img").crossOrigin:this.player_.tech_&&this.player_.tech_.isReady_?this.player_.crossOrigin():this.player_.options_.crossOrigin||this.player_.options_.crossorigin||null;if(e!==null&&e!=="anonymous"&&e!=="use-credentials"){this.player_.log.warn(`crossOrigin must be null, "anonymous" or "use-credentials", given "${e}"`);return}this.$("img")&&(this.$("img").crossOrigin=e)}update(e){const t=this.player().poster();this.setSrc(t),t?this.show():this.hide()}setSrc(e){if(!e){this.el_.textContent="";return}this.$("img")||this.el_.appendChild(Ke("picture",{className:"vjs-poster",tabIndex:-1},{},Ke("img",{loading:"lazy",crossOrigin:this.crossOrigin()},{alt:""}))),this.$("img").src=e}handleClick(e){this.player_.controls()&&(this.player_.tech(!0)&&this.player_.tech(!0).focus(),this.player_.paused()?Va(this.player_.play()):this.player_.pause())}}NT.prototype.crossorigin=NT.prototype.crossOrigin;ae.registerComponent("PosterImage",NT);const xn="#222",WI="#ccc",_te={monospace:"monospace",sansSerif:"sans-serif",serif:"serif",monospaceSansSerif:'"Andale Mono", "Lucida Console", monospace',monospaceSerif:'"Courier New", monospace',proportionalSansSerif:"sans-serif",proportionalSerif:"serif",casual:'"Comic Sans MS", Impact, fantasy',script:'"Monotype Corsiva", cursive',smallcaps:'"Andale Mono", "Lucida Console", monospace, sans-serif'};function m2(r,e){let t;if(r.length===4)t=r[1]+r[1]+r[2]+r[2]+r[3]+r[3];else if(r.length===7)t=r.slice(1);else throw new Error("Invalid color code provided, "+r+"; must be formatted as e.g. #f0e or #f604e2.");return"rgba("+parseInt(t.slice(0,2),16)+","+parseInt(t.slice(2,4),16)+","+parseInt(t.slice(4,6),16)+","+e+")"}function Ca(r,e,t){try{r.style[e]=t}catch{return}}function qI(r){return r?`${r}px`:""}class bte extends ae{constructor(e,t,i){super(e,t,i);const n=s=>this.updateDisplay(s),a=s=>{this.updateDisplayOverlay(),this.updateDisplay(s)};e.on("loadstart",s=>this.toggleDisplay(s)),e.on("texttrackchange",n),e.on("loadedmetadata",s=>{this.updateDisplayOverlay(),this.preselectTrack(s)}),e.ready(Ht(this,function(){if(e.tech_&&e.tech_.featuresNativeTextTracks){this.hide();return}e.on("fullscreenchange",a),e.on("playerresize",a);const s=H.screen.orientation||H,o=H.screen.orientation?"change":"orientationchange";s.addEventListener(o,a),e.on("dispose",()=>s.removeEventListener(o,a));const l=this.options_.playerOptions.tracks||[];for(let u=0;u0&&o.forEach(c=>{if(c.style.inset){const h=c.style.inset.split(" ");h.length===3&&Object.assign(c.style,{top:h[0],right:h[1],bottom:h[2],left:"unset"})}})}}updateDisplayOverlay(){if(!this.player_.videoHeight()||!H.CSS.supports("inset-inline: 10px"))return;const e=this.player_.currentWidth(),t=this.player_.currentHeight(),i=e/t,n=this.player_.videoWidth()/this.player_.videoHeight();let a=0,s=0;Math.abs(i-n)>.1&&(i>n?a=Math.round((e-t*n)/2):s=Math.round((t-e/n)/2)),Ca(this.el_,"insetInline",qI(a)),Ca(this.el_,"insetBlock",qI(s))}updateDisplayState(e){const t=this.player_.textTrackSettings.getValues(),i=e.activeCues;let n=i.length;for(;n--;){const a=i[n];if(!a)continue;const s=a.displayState;if(t.color&&(s.firstChild.style.color=t.color),t.textOpacity&&Ca(s.firstChild,"color",m2(t.color||"#fff",t.textOpacity)),t.backgroundColor&&(s.firstChild.style.backgroundColor=t.backgroundColor),t.backgroundOpacity&&Ca(s.firstChild,"backgroundColor",m2(t.backgroundColor||"#000",t.backgroundOpacity)),t.windowColor&&(t.windowOpacity?Ca(s,"backgroundColor",m2(t.windowColor,t.windowOpacity)):s.style.backgroundColor=t.windowColor),t.edgeStyle&&(t.edgeStyle==="dropshadow"?s.firstChild.style.textShadow=`2px 2px 3px ${xn}, 2px 2px 4px ${xn}, 2px 2px 5px ${xn}`:t.edgeStyle==="raised"?s.firstChild.style.textShadow=`1px 1px ${xn}, 2px 2px ${xn}, 3px 3px ${xn}`:t.edgeStyle==="depressed"?s.firstChild.style.textShadow=`1px 1px ${WI}, 0 1px ${WI}, -1px -1px ${xn}, 0 -1px ${xn}`:t.edgeStyle==="uniform"&&(s.firstChild.style.textShadow=`0 0 4px ${xn}, 0 0 4px ${xn}, 0 0 4px ${xn}, 0 0 4px ${xn}`)),t.fontPercent&&t.fontPercent!==1){const o=H.parseFloat(s.style.fontSize);s.style.fontSize=o*t.fontPercent+"px",s.style.height="auto",s.style.top="auto"}t.fontFamily&&t.fontFamily!=="default"&&(t.fontFamily==="small-caps"?s.firstChild.style.fontVariant="small-caps":s.firstChild.style.fontFamily=_te[t.fontFamily])}}updateForTrack(e){if(Array.isArray(e)||(e=[e]),typeof H.WebVTT!="function"||e.every(i=>!i.activeCues))return;const t=[];for(let i=0;ithis.handleMouseDown(i))}buildCSSClass(){return"vjs-big-play-button"}handleClick(e){const t=this.player_.play();if(this.mouseused_&&"clientX"in e&&"clientY"in e){Va(t),this.player_.tech(!0)&&this.player_.tech(!0).focus();return}const i=this.player_.getChild("controlBar"),n=i&&i.getChild("playToggle");if(!n){this.player_.tech(!0).focus();return}const a=()=>n.focus();mp(t)?t.then(a,()=>{}):this.setTimeout(a,1)}handleKeyDown(e){this.mouseused_=!1,super.handleKeyDown(e)}handleMouseDown(e){this.mouseused_=!0}}A7.prototype.controlText_="Play Video";ae.registerComponent("BigPlayButton",A7);class Tte extends ai{constructor(e,t){super(e,t),this.setIcon("cancel"),this.controlText(t&&t.controlText||this.localize("Close"))}buildCSSClass(){return`vjs-close-button ${super.buildCSSClass()}`}handleClick(e){this.trigger({type:"close",bubbles:!1})}handleKeyDown(e){e.key==="Escape"?(e.preventDefault(),e.stopPropagation(),this.trigger("click")):super.handleKeyDown(e)}}ae.registerComponent("CloseButton",Tte);class D7 extends ai{constructor(e,t={}){super(e,t),t.replay=t.replay===void 0||t.replay,this.setIcon("play"),this.on(e,"play",i=>this.handlePlay(i)),this.on(e,"pause",i=>this.handlePause(i)),t.replay&&this.on(e,"ended",i=>this.handleEnded(i))}buildCSSClass(){return`vjs-play-control ${super.buildCSSClass()}`}handleClick(e){this.player_.paused()?Va(this.player_.play()):this.player_.pause()}handleSeeked(e){this.removeClass("vjs-ended"),this.player_.paused()?this.handlePause(e):this.handlePlay(e)}handlePlay(e){this.removeClass("vjs-ended","vjs-paused"),this.addClass("vjs-playing"),this.setIcon("pause"),this.controlText("Pause")}handlePause(e){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.setIcon("play"),this.controlText("Play")}handleEnded(e){this.removeClass("vjs-playing"),this.addClass("vjs-ended"),this.setIcon("replay"),this.controlText("Replay"),this.one(this.player_,"seeked",t=>this.handleSeeked(t))}}D7.prototype.controlText_="Play";ae.registerComponent("PlayToggle",D7);class wf extends ae{constructor(e,t){super(e,t),this.on(e,["timeupdate","ended","seeking"],i=>this.update(i)),this.updateTextNode_()}createEl(){const e=this.buildCSSClass(),t=super.createEl("div",{className:`${e} vjs-time-control vjs-control`}),i=Ke("span",{className:"vjs-control-text",textContent:`${this.localize(this.labelText_)} `},{role:"presentation"});return t.appendChild(i),this.contentEl_=Ke("span",{className:`${e}-display`},{role:"presentation"}),t.appendChild(this.contentEl_),t}dispose(){this.contentEl_=null,this.textNode_=null,super.dispose()}update(e){!this.player_.options_.enableSmoothSeeking&&e.type==="seeking"||this.updateContent(e)}updateTextNode_(e=0){e=Xu(e),this.formattedTime_!==e&&(this.formattedTime_=e,this.requestNamedAnimationFrame("TimeDisplay#updateTextNode_",()=>{if(!this.contentEl_)return;let t=this.textNode_;t&&this.contentEl_.firstChild!==t&&(t=null,pt.warn("TimeDisplay#updateTextnode_: Prevented replacement of text node element since it was no longer a child of this node. Appending a new node instead.")),this.textNode_=de.createTextNode(this.formattedTime_),this.textNode_&&(t?this.contentEl_.replaceChild(this.textNode_,t):this.contentEl_.appendChild(this.textNode_))}))}updateContent(e){}}wf.prototype.labelText_="Time";wf.prototype.controlText_="Time";ae.registerComponent("TimeDisplay",wf);class ZC extends wf{buildCSSClass(){return"vjs-current-time"}updateContent(e){let t;this.player_.ended()?t=this.player_.duration():t=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime(),this.updateTextNode_(t)}}ZC.prototype.labelText_="Current Time";ZC.prototype.controlText_="Current Time";ae.registerComponent("CurrentTimeDisplay",ZC);class QC extends wf{constructor(e,t){super(e,t);const i=n=>this.updateContent(n);this.on(e,"durationchange",i),this.on(e,"loadstart",i),this.on(e,"loadedmetadata",i)}buildCSSClass(){return"vjs-duration"}updateContent(e){const t=this.player_.duration();this.updateTextNode_(t)}}QC.prototype.labelText_="Duration";QC.prototype.controlText_="Duration";ae.registerComponent("DurationDisplay",QC);class xte extends ae{createEl(){const e=super.createEl("div",{className:"vjs-time-control vjs-time-divider"},{"aria-hidden":!0}),t=super.createEl("div"),i=super.createEl("span",{textContent:"/"});return t.appendChild(i),e.appendChild(t),e}}ae.registerComponent("TimeDivider",xte);class JC extends wf{constructor(e,t){super(e,t),this.on(e,"durationchange",i=>this.updateContent(i))}buildCSSClass(){return"vjs-remaining-time"}createEl(){const e=super.createEl();return this.options_.displayNegative!==!1&&e.insertBefore(Ke("span",{},{"aria-hidden":!0},"-"),this.contentEl_),e}updateContent(e){if(typeof this.player_.duration()!="number")return;let t;this.player_.ended()?t=0:this.player_.remainingTimeDisplay?t=this.player_.remainingTimeDisplay():t=this.player_.remainingTime(),this.updateTextNode_(t)}}JC.prototype.labelText_="Remaining Time";JC.prototype.controlText_="Remaining Time";ae.registerComponent("RemainingTimeDisplay",JC);class wte extends ae{constructor(e,t){super(e,t),this.updateShowing(),this.on(this.player(),"durationchange",i=>this.updateShowing(i))}createEl(){const e=super.createEl("div",{className:"vjs-live-control vjs-control"});return this.contentEl_=Ke("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.contentEl_.appendChild(Ke("span",{className:"vjs-control-text",textContent:`${this.localize("Stream Type")} `})),this.contentEl_.appendChild(de.createTextNode(this.localize("LIVE"))),e.appendChild(this.contentEl_),e}dispose(){this.contentEl_=null,super.dispose()}updateShowing(e){this.player().duration()===1/0?this.show():this.hide()}}ae.registerComponent("LiveDisplay",wte);class E7 extends ai{constructor(e,t){super(e,t),this.updateLiveEdgeStatus(),this.player_.liveTracker&&(this.updateLiveEdgeStatusHandler_=i=>this.updateLiveEdgeStatus(i),this.on(this.player_.liveTracker,"liveedgechange",this.updateLiveEdgeStatusHandler_))}createEl(){const e=super.createEl("button",{className:"vjs-seek-to-live-control vjs-control"});return this.setIcon("circle",e),this.textEl_=Ke("span",{className:"vjs-seek-to-live-text",textContent:this.localize("LIVE")},{"aria-hidden":"true"}),e.appendChild(this.textEl_),e}updateLiveEdgeStatus(){!this.player_.liveTracker||this.player_.liveTracker.atLiveEdge()?(this.setAttribute("aria-disabled",!0),this.addClass("vjs-at-live-edge"),this.controlText("Seek to live, currently playing live")):(this.setAttribute("aria-disabled",!1),this.removeClass("vjs-at-live-edge"),this.controlText("Seek to live, currently behind live"))}handleClick(){this.player_.liveTracker.seekToLiveEdge()}dispose(){this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.updateLiveEdgeStatusHandler_),this.textEl_=null,super.dispose()}}E7.prototype.controlText_="Seek to live, currently playing live";ae.registerComponent("SeekToLive",E7);function $v(r,e,t){return r=Number(r),Math.min(t,Math.max(e,isNaN(r)?e:r))}var Cte=Object.freeze({__proto__:null,clamp:$v});class eA extends ae{constructor(e,t){super(e,t),this.handleMouseDown_=i=>this.handleMouseDown(i),this.handleMouseUp_=i=>this.handleMouseUp(i),this.handleKeyDown_=i=>this.handleKeyDown(i),this.handleClick_=i=>this.handleClick(i),this.handleMouseMove_=i=>this.handleMouseMove(i),this.update_=i=>this.update(i),this.bar=this.getChild(this.options_.barName),this.vertical(!!this.options_.vertical),this.enable()}enabled(){return this.enabled_}enable(){this.enabled()||(this.on("mousedown",this.handleMouseDown_),this.on("touchstart",this.handleMouseDown_),this.on("keydown",this.handleKeyDown_),this.on("click",this.handleClick_),this.on(this.player_,"controlsvisible",this.update),this.playerEvent&&this.on(this.player_,this.playerEvent,this.update),this.removeClass("disabled"),this.setAttribute("tabindex",0),this.enabled_=!0)}disable(){if(!this.enabled())return;const e=this.bar.el_.ownerDocument;this.off("mousedown",this.handleMouseDown_),this.off("touchstart",this.handleMouseDown_),this.off("keydown",this.handleKeyDown_),this.off("click",this.handleClick_),this.off(this.player_,"controlsvisible",this.update_),this.off(e,"mousemove",this.handleMouseMove_),this.off(e,"mouseup",this.handleMouseUp_),this.off(e,"touchmove",this.handleMouseMove_),this.off(e,"touchend",this.handleMouseUp_),this.removeAttribute("tabindex"),this.addClass("disabled"),this.playerEvent&&this.off(this.player_,this.playerEvent,this.update),this.enabled_=!1}createEl(e,t={},i={}){return t.className=t.className+" vjs-slider",t=Object.assign({tabIndex:0},t),i=Object.assign({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100},i),super.createEl(e,t,i)}handleMouseDown(e){const t=this.bar.el_.ownerDocument;e.type==="mousedown"&&e.preventDefault(),e.type==="touchstart"&&!rs&&e.preventDefault(),t7(),this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(t,"mousemove",this.handleMouseMove_),this.on(t,"mouseup",this.handleMouseUp_),this.on(t,"touchmove",this.handleMouseMove_),this.on(t,"touchend",this.handleMouseUp_),this.handleMouseMove(e,!0)}handleMouseMove(e){}handleMouseUp(e){const t=this.bar.el_.ownerDocument;r7(),this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(t,"mousemove",this.handleMouseMove_),this.off(t,"mouseup",this.handleMouseUp_),this.off(t,"touchmove",this.handleMouseMove_),this.off(t,"touchend",this.handleMouseUp_),this.update()}update(){if(!this.el_||!this.bar)return;const e=this.getProgress();return e===this.progress_||(this.progress_=e,this.requestNamedAnimationFrame("Slider#update",()=>{const t=this.vertical()?"height":"width";this.bar.el().style[t]=(e*100).toFixed(2)+"%"})),e}getProgress(){return Number($v(this.getPercent(),0,1).toFixed(4))}calculateDistance(e){const t=N_(this.el_,e);return this.vertical()?t.y:t.x}handleKeyDown(e){const t=this.options_.playerOptions.spatialNavigation,i=t&&t.enabled,n=t&&t.horizontalSeek;i?n&&e.key==="ArrowLeft"||!n&&e.key==="ArrowDown"?(e.preventDefault(),e.stopPropagation(),this.stepBack()):n&&e.key==="ArrowRight"||!n&&e.key==="ArrowUp"?(e.preventDefault(),e.stopPropagation(),this.stepForward()):super.handleKeyDown(e):e.key==="ArrowLeft"||e.key==="ArrowDown"?(e.preventDefault(),e.stopPropagation(),this.stepBack()):e.key==="ArrowUp"||e.key==="ArrowRight"?(e.preventDefault(),e.stopPropagation(),this.stepForward()):super.handleKeyDown(e)}handleClick(e){e.stopPropagation(),e.preventDefault()}vertical(e){if(e===void 0)return this.vertical_||!1;this.vertical_=!!e,this.vertical_?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal")}}ae.registerComponent("Slider",eA);const y2=(r,e)=>$v(r/e*100,0,100).toFixed(2)+"%";class Ate extends ae{constructor(e,t){super(e,t),this.partEls_=[],this.on(e,"progress",i=>this.update(i))}createEl(){const e=super.createEl("div",{className:"vjs-load-progress"}),t=Ke("span",{className:"vjs-control-text"}),i=Ke("span",{textContent:this.localize("Loaded")}),n=de.createTextNode(": ");return this.percentageEl_=Ke("span",{className:"vjs-control-text-loaded-percentage",textContent:"0%"}),e.appendChild(t),t.appendChild(i),t.appendChild(n),t.appendChild(this.percentageEl_),e}dispose(){this.partEls_=null,this.percentageEl_=null,super.dispose()}update(e){this.requestNamedAnimationFrame("LoadProgressBar#update",()=>{const t=this.player_.liveTracker,i=this.player_.buffered(),n=t&&t.isLive()?t.seekableEnd():this.player_.duration(),a=this.player_.bufferedEnd(),s=this.partEls_,o=y2(a,n);this.percent_!==o&&(this.el_.style.width=o,ll(this.percentageEl_,o),this.percent_=o);for(let l=0;li.length;l--)this.el_.removeChild(s[l-1]);s.length=i.length})}}ae.registerComponent("LoadProgressBar",Ate);class Dte extends ae{constructor(e,t){super(e,t),this.update=is(Ht(this,this.update),jn)}createEl(){return super.createEl("div",{className:"vjs-time-tooltip"},{"aria-hidden":"true"})}update(e,t,i){const n=Yp(this.el_),a=Xh(this.player_.el()),s=e.width*t;if(!a||!n)return;let o=e.left-a.left+s,l=e.width-s+(a.right-e.right);l||(l=e.width-s,o=s);let u=n.width/2;on.width&&(u=n.width),u=Math.round(u),this.el_.style.right=`-${u}px`,this.write(i)}write(e){ll(this.el_,e)}updateTime(e,t,i,n){this.requestNamedAnimationFrame("TimeTooltip#updateTime",()=>{let a;const s=this.player_.duration();if(this.player_.liveTracker&&this.player_.liveTracker.isLive()){const o=this.player_.liveTracker.liveWindow(),l=o-t*o;a=(l<1?"":"-")+Xu(l,o)}else a=Xu(i,s);this.update(e,t,a),n&&n()})}}ae.registerComponent("TimeTooltip",Dte);class tA extends ae{constructor(e,t){super(e,t),this.setIcon("circle"),this.update=is(Ht(this,this.update),jn)}createEl(){return super.createEl("div",{className:"vjs-play-progress vjs-slider-bar"},{"aria-hidden":"true"})}update(e,t){const i=this.getChild("timeTooltip");if(!i)return;const n=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();i.updateTime(e,t,n)}}tA.prototype.options_={children:[]};!xi&&!ts&&tA.prototype.options_.children.push("timeTooltip");ae.registerComponent("PlayProgressBar",tA);class I7 extends ae{constructor(e,t){super(e,t),this.update=is(Ht(this,this.update),jn)}createEl(){return super.createEl("div",{className:"vjs-mouse-display"})}update(e,t){const i=t*this.player_.duration();this.getChild("timeTooltip").updateTime(e,t,i,()=>{this.el_.style.left=`${e.width*t}px`})}}I7.prototype.options_={children:["timeTooltip"]};ae.registerComponent("MouseTimeDisplay",I7);const Hg=5,jI=12;class rA extends eA{constructor(e,t){super(e,t),this.setEventHandlers_()}setEventHandlers_(){this.update_=Ht(this,this.update),this.update=is(this.update_,jn),this.on(this.player_,["durationchange","timeupdate"],this.update),this.on(this.player_,["ended"],this.update_),this.player_.liveTracker&&this.on(this.player_.liveTracker,"liveedgechange",this.update),this.updateInterval=null,this.enableIntervalHandler_=e=>this.enableInterval_(e),this.disableIntervalHandler_=e=>this.disableInterval_(e),this.on(this.player_,["playing"],this.enableIntervalHandler_),this.on(this.player_,["ended","pause","waiting"],this.disableIntervalHandler_),"hidden"in de&&"visibilityState"in de&&this.on(de,"visibilitychange",this.toggleVisibility_)}toggleVisibility_(e){de.visibilityState==="hidden"?(this.cancelNamedAnimationFrame("SeekBar#update"),this.cancelNamedAnimationFrame("Slider#update"),this.disableInterval_(e)):(!this.player_.ended()&&!this.player_.paused()&&this.enableInterval_(),this.update())}enableInterval_(){this.updateInterval||(this.updateInterval=this.setInterval(this.update,jn))}disableInterval_(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&e&&e.type!=="ended"||this.updateInterval&&(this.clearInterval(this.updateInterval),this.updateInterval=null)}createEl(){return super.createEl("div",{className:"vjs-progress-holder"},{"aria-label":this.localize("Progress Bar")})}update(e){if(de.visibilityState==="hidden")return;const t=super.update();return this.requestNamedAnimationFrame("SeekBar#update",()=>{const i=this.player_.ended()?this.player_.duration():this.getCurrentTime_(),n=this.player_.liveTracker;let a=this.player_.duration();n&&n.isLive()&&(a=this.player_.liveTracker.liveCurrentTime()),this.percent_!==t&&(this.el_.setAttribute("aria-valuenow",(t*100).toFixed(2)),this.percent_=t),(this.currentTime_!==i||this.duration_!==a)&&(this.el_.setAttribute("aria-valuetext",this.localize("progress bar timing: currentTime={1} duration={2}",[Xu(i,a),Xu(a,a)],"{1} of {2}")),this.currentTime_=i,this.duration_=a),this.bar&&this.bar.update(Xh(this.el()),this.getProgress())}),t}userSeek_(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&this.player_.liveTracker.nextSeekedFromUser(),this.player_.currentTime(e)}getCurrentTime_(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()}getPercent(){const e=this.getCurrentTime_();let t;const i=this.player_.liveTracker;return i&&i.isLive()?(t=(e-i.seekableStart())/i.liveWindow(),i.atLiveEdge()&&(t=1)):t=e/this.player_.duration(),t}handleMouseDown(e){Kp(e)&&(e.stopPropagation(),this.videoWasPlaying=!this.player_.paused(),this.player_.pause(),super.handleMouseDown(e))}handleMouseMove(e,t=!1){if(!Kp(e)||isNaN(this.player_.duration()))return;!t&&!this.player_.scrubbing()&&this.player_.scrubbing(!0);let i;const n=this.calculateDistance(e),a=this.player_.liveTracker;if(!a||!a.isLive())i=n*this.player_.duration(),i===this.player_.duration()&&(i=i-.1);else{if(n>=.99){a.seekToLiveEdge();return}const s=a.seekableStart(),o=a.liveCurrentTime();if(i=s+n*a.liveWindow(),i>=o&&(i=o),i<=s&&(i=s+.1),i===1/0)return}this.userSeek_(i),this.player_.options_.enableSmoothSeeking&&this.update()}enable(){super.enable();const e=this.getChild("mouseTimeDisplay");e&&e.show()}disable(){super.disable();const e=this.getChild("mouseTimeDisplay");e&&e.hide()}handleMouseUp(e){super.handleMouseUp(e),e&&e.stopPropagation(),this.player_.scrubbing(!1),this.player_.trigger({type:"timeupdate",target:this,manuallyTriggered:!0}),this.videoWasPlaying?Va(this.player_.play()):this.update_()}stepForward(){this.userSeek_(this.player_.currentTime()+Hg)}stepBack(){this.userSeek_(this.player_.currentTime()-Hg)}handleAction(e){this.player_.paused()?this.player_.play():this.player_.pause()}handleKeyDown(e){const t=this.player_.liveTracker;if(e.key===" "||e.key==="Enter")e.preventDefault(),e.stopPropagation(),this.handleAction(e);else if(e.key==="Home")e.preventDefault(),e.stopPropagation(),this.userSeek_(0);else if(e.key==="End")e.preventDefault(),e.stopPropagation(),t&&t.isLive()?this.userSeek_(t.liveCurrentTime()):this.userSeek_(this.player_.duration());else if(/^[0-9]$/.test(e.key)){e.preventDefault(),e.stopPropagation();const i=parseInt(e.key,10)*.1;t&&t.isLive()?this.userSeek_(t.seekableStart()+t.liveWindow()*i):this.userSeek_(this.player_.duration()*i)}else e.key==="PageDown"?(e.preventDefault(),e.stopPropagation(),this.userSeek_(this.player_.currentTime()-Hg*jI)):e.key==="PageUp"?(e.preventDefault(),e.stopPropagation(),this.userSeek_(this.player_.currentTime()+Hg*jI)):super.handleKeyDown(e)}dispose(){this.disableInterval_(),this.off(this.player_,["durationchange","timeupdate"],this.update),this.off(this.player_,["ended"],this.update_),this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.update),this.off(this.player_,["playing"],this.enableIntervalHandler_),this.off(this.player_,["ended","pause","waiting"],this.disableIntervalHandler_),"hidden"in de&&"visibilityState"in de&&this.off(de,"visibilitychange",this.toggleVisibility_),super.dispose()}}rA.prototype.options_={children:["loadProgressBar","playProgressBar"],barName:"playProgressBar"};!xi&&!ts&&rA.prototype.options_.children.splice(1,0,"mouseTimeDisplay");ae.registerComponent("SeekBar",rA);class P7 extends ae{constructor(e,t){super(e,t),this.handleMouseMove=is(Ht(this,this.handleMouseMove),jn),this.throttledHandleMouseSeek=is(Ht(this,this.handleMouseSeek),jn),this.handleMouseUpHandler_=i=>this.handleMouseUp(i),this.handleMouseDownHandler_=i=>this.handleMouseDown(i),this.enable()}createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(e){const t=this.getChild("seekBar");if(!t)return;const i=t.getChild("playProgressBar"),n=t.getChild("mouseTimeDisplay");if(!i&&!n)return;const a=t.el(),s=Yp(a);let o=N_(a,e).x;o=$v(o,0,1),n&&n.update(s,o),i&&i.update(s,t.getProgress())}handleMouseSeek(e){const t=this.getChild("seekBar");t&&t.handleMouseMove(e)}enabled(){return this.enabled_}disable(){if(this.children().forEach(e=>e.disable&&e.disable()),!!this.enabled()&&(this.off(["mousedown","touchstart"],this.handleMouseDownHandler_),this.off(this.el_,"mousemove",this.handleMouseMove),this.removeListenersAddedOnMousedownAndTouchstart(),this.addClass("disabled"),this.enabled_=!1,this.player_.scrubbing())){const e=this.getChild("seekBar");this.player_.scrubbing(!1),e.videoWasPlaying&&Va(this.player_.play())}}enable(){this.children().forEach(e=>e.enable&&e.enable()),!this.enabled()&&(this.on(["mousedown","touchstart"],this.handleMouseDownHandler_),this.on(this.el_,"mousemove",this.handleMouseMove),this.removeClass("disabled"),this.enabled_=!0)}removeListenersAddedOnMousedownAndTouchstart(){const e=this.el_.ownerDocument;this.off(e,"mousemove",this.throttledHandleMouseSeek),this.off(e,"touchmove",this.throttledHandleMouseSeek),this.off(e,"mouseup",this.handleMouseUpHandler_),this.off(e,"touchend",this.handleMouseUpHandler_)}handleMouseDown(e){const t=this.el_.ownerDocument,i=this.getChild("seekBar");i&&i.handleMouseDown(e),this.on(t,"mousemove",this.throttledHandleMouseSeek),this.on(t,"touchmove",this.throttledHandleMouseSeek),this.on(t,"mouseup",this.handleMouseUpHandler_),this.on(t,"touchend",this.handleMouseUpHandler_)}handleMouseUp(e){const t=this.getChild("seekBar");t&&t.handleMouseUp(e),this.removeListenersAddedOnMousedownAndTouchstart()}}P7.prototype.options_={children:["seekBar"]};ae.registerComponent("ProgressControl",P7);class M7 extends ai{constructor(e,t){super(e,t),this.setIcon("picture-in-picture-enter"),this.on(e,["enterpictureinpicture","leavepictureinpicture"],i=>this.handlePictureInPictureChange(i)),this.on(e,["disablepictureinpicturechanged","loadedmetadata"],i=>this.handlePictureInPictureEnabledChange(i)),this.on(e,["loadedmetadata","audioonlymodechange","audiopostermodechange"],()=>this.handlePictureInPictureAudioModeChange()),this.disable()}buildCSSClass(){return`vjs-picture-in-picture-control vjs-hidden ${super.buildCSSClass()}`}handlePictureInPictureAudioModeChange(){if(!(this.player_.currentType().substring(0,5)==="audio"||this.player_.audioPosterMode()||this.player_.audioOnlyMode())){this.show();return}this.player_.isInPictureInPicture()&&this.player_.exitPictureInPicture(),this.hide()}handlePictureInPictureEnabledChange(){de.pictureInPictureEnabled&&this.player_.disablePictureInPicture()===!1||this.player_.options_.enableDocumentPictureInPicture&&"documentPictureInPicture"in H?this.enable():this.disable()}handlePictureInPictureChange(e){this.player_.isInPictureInPicture()?(this.setIcon("picture-in-picture-exit"),this.controlText("Exit Picture-in-Picture")):(this.setIcon("picture-in-picture-enter"),this.controlText("Picture-in-Picture")),this.handlePictureInPictureEnabledChange()}handleClick(e){this.player_.isInPictureInPicture()?this.player_.exitPictureInPicture():this.player_.requestPictureInPicture()}show(){typeof de.exitPictureInPicture=="function"&&super.show()}}M7.prototype.controlText_="Picture-in-Picture";ae.registerComponent("PictureInPictureToggle",M7);class L7 extends ai{constructor(e,t){super(e,t),this.setIcon("fullscreen-enter"),this.on(e,"fullscreenchange",i=>this.handleFullscreenChange(i)),de[e.fsApi_.fullscreenEnabled]===!1&&this.disable()}buildCSSClass(){return`vjs-fullscreen-control ${super.buildCSSClass()}`}handleFullscreenChange(e){this.player_.isFullscreen()?(this.controlText("Exit Fullscreen"),this.setIcon("fullscreen-exit")):(this.controlText("Fullscreen"),this.setIcon("fullscreen-enter"))}handleClick(e){this.player_.isFullscreen()?this.player_.exitFullscreen():this.player_.requestFullscreen()}}L7.prototype.controlText_="Fullscreen";ae.registerComponent("FullscreenToggle",L7);const Ete=function(r,e){e.tech_&&!e.tech_.featuresVolumeControl&&r.addClass("vjs-hidden"),r.on(e,"loadstart",function(){e.tech_.featuresVolumeControl?r.removeClass("vjs-hidden"):r.addClass("vjs-hidden")})};class Ite extends ae{createEl(){const e=super.createEl("div",{className:"vjs-volume-level"});return this.setIcon("circle",e),e.appendChild(super.createEl("span",{className:"vjs-control-text"})),e}}ae.registerComponent("VolumeLevel",Ite);class Pte extends ae{constructor(e,t){super(e,t),this.update=is(Ht(this,this.update),jn)}createEl(){return super.createEl("div",{className:"vjs-volume-tooltip"},{"aria-hidden":"true"})}update(e,t,i,n){if(!i){const a=Xh(this.el_),s=Xh(this.player_.el()),o=e.width*t;if(!s||!a)return;const l=e.left-s.left+o,u=e.width-o+(s.right-e.right);let c=a.width/2;la.width&&(c=a.width),this.el_.style.right=`-${c}px`}this.write(`${n}%`)}write(e){ll(this.el_,e)}updateVolume(e,t,i,n,a){this.requestNamedAnimationFrame("VolumeLevelTooltip#updateVolume",()=>{this.update(e,t,i,n.toFixed(0)),a&&a()})}}ae.registerComponent("VolumeLevelTooltip",Pte);class k7 extends ae{constructor(e,t){super(e,t),this.update=is(Ht(this,this.update),jn)}createEl(){return super.createEl("div",{className:"vjs-mouse-display"})}update(e,t,i){const n=100*t;this.getChild("volumeLevelTooltip").updateVolume(e,t,i,n,()=>{i?this.el_.style.bottom=`${e.height*t}px`:this.el_.style.left=`${e.width*t}px`})}}k7.prototype.options_={children:["volumeLevelTooltip"]};ae.registerComponent("MouseVolumeLevelDisplay",k7);class H_ extends eA{constructor(e,t){super(e,t),this.on("slideractive",i=>this.updateLastVolume_(i)),this.on(e,"volumechange",i=>this.updateARIAAttributes(i)),e.ready(()=>this.updateARIAAttributes())}createEl(){return super.createEl("div",{className:"vjs-volume-bar vjs-slider-bar"},{"aria-label":this.localize("Volume Level"),"aria-live":"polite"})}handleMouseDown(e){Kp(e)&&super.handleMouseDown(e)}handleMouseMove(e){const t=this.getChild("mouseVolumeLevelDisplay");if(t){const i=this.el(),n=Xh(i),a=this.vertical();let s=N_(i,e);s=a?s.y:s.x,s=$v(s,0,1),t.update(n,s,a)}Kp(e)&&(this.checkMuted(),this.player_.volume(this.calculateDistance(e)))}checkMuted(){this.player_.muted()&&this.player_.muted(!1)}getPercent(){return this.player_.muted()?0:this.player_.volume()}stepForward(){this.checkMuted(),this.player_.volume(this.player_.volume()+.1)}stepBack(){this.checkMuted(),this.player_.volume(this.player_.volume()-.1)}updateARIAAttributes(e){const t=this.player_.muted()?0:this.volumeAsPercentage_();this.el_.setAttribute("aria-valuenow",t),this.el_.setAttribute("aria-valuetext",t+"%")}volumeAsPercentage_(){return Math.round(this.player_.volume()*100)}updateLastVolume_(){const e=this.player_.volume();this.one("sliderinactive",()=>{this.player_.volume()===0&&this.player_.lastVolume_(e)})}}H_.prototype.options_={children:["volumeLevel"],barName:"volumeLevel"};!xi&&!ts&&H_.prototype.options_.children.splice(0,0,"mouseVolumeLevelDisplay");H_.prototype.playerEvent="volumechange";ae.registerComponent("VolumeBar",H_);class R7 extends ae{constructor(e,t={}){t.vertical=t.vertical||!1,(typeof t.volumeBar>"u"||qh(t.volumeBar))&&(t.volumeBar=t.volumeBar||{},t.volumeBar.vertical=t.vertical),super(e,t),Ete(this,e),this.throttledHandleMouseMove=is(Ht(this,this.handleMouseMove),jn),this.handleMouseUpHandler_=i=>this.handleMouseUp(i),this.on("mousedown",i=>this.handleMouseDown(i)),this.on("touchstart",i=>this.handleMouseDown(i)),this.on("mousemove",i=>this.handleMouseMove(i)),this.on(this.volumeBar,["focus","slideractive"],()=>{this.volumeBar.addClass("vjs-slider-active"),this.addClass("vjs-slider-active"),this.trigger("slideractive")}),this.on(this.volumeBar,["blur","sliderinactive"],()=>{this.volumeBar.removeClass("vjs-slider-active"),this.removeClass("vjs-slider-active"),this.trigger("sliderinactive")})}createEl(){let e="vjs-volume-horizontal";return this.options_.vertical&&(e="vjs-volume-vertical"),super.createEl("div",{className:`vjs-volume-control vjs-control ${e}`})}handleMouseDown(e){const t=this.el_.ownerDocument;this.on(t,"mousemove",this.throttledHandleMouseMove),this.on(t,"touchmove",this.throttledHandleMouseMove),this.on(t,"mouseup",this.handleMouseUpHandler_),this.on(t,"touchend",this.handleMouseUpHandler_)}handleMouseUp(e){const t=this.el_.ownerDocument;this.off(t,"mousemove",this.throttledHandleMouseMove),this.off(t,"touchmove",this.throttledHandleMouseMove),this.off(t,"mouseup",this.handleMouseUpHandler_),this.off(t,"touchend",this.handleMouseUpHandler_)}handleMouseMove(e){this.volumeBar.handleMouseMove(e)}}R7.prototype.options_={children:["volumeBar"]};ae.registerComponent("VolumeControl",R7);const Mte=function(r,e){e.tech_&&!e.tech_.featuresMuteControl&&r.addClass("vjs-hidden"),r.on(e,"loadstart",function(){e.tech_.featuresMuteControl?r.removeClass("vjs-hidden"):r.addClass("vjs-hidden")})};class O7 extends ai{constructor(e,t){super(e,t),Mte(this,e),this.on(e,["loadstart","volumechange"],i=>this.update(i))}buildCSSClass(){return`vjs-mute-control ${super.buildCSSClass()}`}handleClick(e){const t=this.player_.volume(),i=this.player_.lastVolume_();if(t===0){const n=i<.1?.1:i;this.player_.volume(n),this.player_.muted(!1)}else this.player_.muted(!this.player_.muted())}update(e){this.updateIcon_(),this.updateControlText_()}updateIcon_(){const e=this.player_.volume();let t=3;this.setIcon("volume-high"),xi&&this.player_.tech_&&this.player_.tech_.el_&&this.player_.muted(this.player_.tech_.el_.muted),e===0||this.player_.muted()?(this.setIcon("volume-mute"),t=0):e<.33?(this.setIcon("volume-low"),t=1):e<.67&&(this.setIcon("volume-medium"),t=2),R_(this.el_,[0,1,2,3].reduce((i,n)=>i+`${n?" ":""}vjs-vol-${n}`,"")),Au(this.el_,`vjs-vol-${t}`)}updateControlText_(){const t=this.player_.muted()||this.player_.volume()===0?"Unmute":"Mute";this.controlText()!==t&&this.controlText(t)}}O7.prototype.controlText_="Mute";ae.registerComponent("MuteToggle",O7);class N7 extends ae{constructor(e,t={}){typeof t.inline<"u"?t.inline=t.inline:t.inline=!0,(typeof t.volumeControl>"u"||qh(t.volumeControl))&&(t.volumeControl=t.volumeControl||{},t.volumeControl.vertical=!t.inline),super(e,t),this.handleKeyPressHandler_=i=>this.handleKeyPress(i),this.on(e,["loadstart"],i=>this.volumePanelState_(i)),this.on(this.muteToggle,"keyup",i=>this.handleKeyPress(i)),this.on(this.volumeControl,"keyup",i=>this.handleVolumeControlKeyUp(i)),this.on("keydown",i=>this.handleKeyPress(i)),this.on("mouseover",i=>this.handleMouseOver(i)),this.on("mouseout",i=>this.handleMouseOut(i)),this.on(this.volumeControl,["slideractive"],this.sliderActive_),this.on(this.volumeControl,["sliderinactive"],this.sliderInactive_)}sliderActive_(){this.addClass("vjs-slider-active")}sliderInactive_(){this.removeClass("vjs-slider-active")}volumePanelState_(){this.volumeControl.hasClass("vjs-hidden")&&this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-hidden"),this.volumeControl.hasClass("vjs-hidden")&&!this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-mute-toggle-only")}createEl(){let e="vjs-volume-panel-horizontal";return this.options_.inline||(e="vjs-volume-panel-vertical"),super.createEl("div",{className:`vjs-volume-panel vjs-control ${e}`})}dispose(){this.handleMouseOut(),super.dispose()}handleVolumeControlKeyUp(e){e.key==="Escape"&&this.muteToggle.focus()}handleMouseOver(e){this.addClass("vjs-hover"),yn(de,"keyup",this.handleKeyPressHandler_)}handleMouseOut(e){this.removeClass("vjs-hover"),ni(de,"keyup",this.handleKeyPressHandler_)}handleKeyPress(e){e.key==="Escape"&&this.handleMouseOut()}}N7.prototype.options_={children:["muteToggle","volumeControl"]};ae.registerComponent("VolumePanel",N7);class B7 extends ai{constructor(e,t){super(e,t),this.validOptions=[5,10,30],this.skipTime=this.getSkipForwardTime(),this.skipTime&&this.validOptions.includes(this.skipTime)?(this.setIcon(`forward-${this.skipTime}`),this.controlText(this.localize("Skip forward {1} seconds",[this.skipTime.toLocaleString(e.language())])),this.show()):this.hide()}getSkipForwardTime(){const e=this.options_.playerOptions;return e.controlBar&&e.controlBar.skipButtons&&e.controlBar.skipButtons.forward}buildCSSClass(){return`vjs-skip-forward-${this.getSkipForwardTime()} ${super.buildCSSClass()}`}handleClick(e){if(isNaN(this.player_.duration()))return;const t=this.player_.currentTime(),i=this.player_.liveTracker,n=i&&i.isLive()?i.seekableEnd():this.player_.duration();let a;t+this.skipTime<=n?a=t+this.skipTime:a=n,this.player_.currentTime(a)}handleLanguagechange(){this.controlText(this.localize("Skip forward {1} seconds",[this.skipTime]))}}B7.prototype.controlText_="Skip Forward";ae.registerComponent("SkipForward",B7);class F7 extends ai{constructor(e,t){super(e,t),this.validOptions=[5,10,30],this.skipTime=this.getSkipBackwardTime(),this.skipTime&&this.validOptions.includes(this.skipTime)?(this.setIcon(`replay-${this.skipTime}`),this.controlText(this.localize("Skip backward {1} seconds",[this.skipTime.toLocaleString(e.language())])),this.show()):this.hide()}getSkipBackwardTime(){const e=this.options_.playerOptions;return e.controlBar&&e.controlBar.skipButtons&&e.controlBar.skipButtons.backward}buildCSSClass(){return`vjs-skip-backward-${this.getSkipBackwardTime()} ${super.buildCSSClass()}`}handleClick(e){const t=this.player_.currentTime(),i=this.player_.liveTracker,n=i&&i.isLive()&&i.seekableStart();let a;n&&t-this.skipTime<=n?a=n:t>=this.skipTime?a=t-this.skipTime:a=0,this.player_.currentTime(a)}handleLanguagechange(){this.controlText(this.localize("Skip backward {1} seconds",[this.skipTime]))}}F7.prototype.controlText_="Skip Backward";ae.registerComponent("SkipBackward",F7);class U7 extends ae{constructor(e,t){super(e,t),t&&(this.menuButton_=t.menuButton),this.focusedChild_=-1,this.on("keydown",i=>this.handleKeyDown(i)),this.boundHandleBlur_=i=>this.handleBlur(i),this.boundHandleTapClick_=i=>this.handleTapClick(i)}addEventListenerForItem(e){e instanceof ae&&(this.on(e,"blur",this.boundHandleBlur_),this.on(e,["tap","click"],this.boundHandleTapClick_))}removeEventListenerForItem(e){e instanceof ae&&(this.off(e,"blur",this.boundHandleBlur_),this.off(e,["tap","click"],this.boundHandleTapClick_))}removeChild(e){typeof e=="string"&&(e=this.getChild(e)),this.removeEventListenerForItem(e),super.removeChild(e)}addItem(e){const t=this.addChild(e);t&&this.addEventListenerForItem(t)}createEl(){const e=this.options_.contentElType||"ul";this.contentEl_=Ke(e,{className:"vjs-menu-content"}),this.contentEl_.setAttribute("role","menu");const t=super.createEl("div",{append:this.contentEl_,className:"vjs-menu"});return t.appendChild(this.contentEl_),yn(t,"click",function(i){i.preventDefault(),i.stopImmediatePropagation()}),t}dispose(){this.contentEl_=null,this.boundHandleBlur_=null,this.boundHandleTapClick_=null,super.dispose()}handleBlur(e){const t=e.relatedTarget||de.activeElement;if(!this.children().some(i=>i.el()===t)){const i=this.menuButton_;i&&i.buttonPressed_&&t!==i.el().firstChild&&i.unpressButton()}}handleTapClick(e){if(this.menuButton_){this.menuButton_.unpressButton();const t=this.children();if(!Array.isArray(t))return;const i=t.filter(n=>n.el()===e.target)[0];if(!i)return;i.name()!=="CaptionSettingsMenuItem"&&this.menuButton_.focus()}}handleKeyDown(e){e.key==="ArrowLeft"||e.key==="ArrowDown"?(e.preventDefault(),e.stopPropagation(),this.stepForward()):(e.key==="ArrowRight"||e.key==="ArrowUp")&&(e.preventDefault(),e.stopPropagation(),this.stepBack())}stepForward(){let e=0;this.focusedChild_!==void 0&&(e=this.focusedChild_+1),this.focus(e)}stepBack(){let e=0;this.focusedChild_!==void 0&&(e=this.focusedChild_-1),this.focus(e)}focus(e=0){const t=this.children().slice();t.length&&t[0].hasClass("vjs-menu-title")&&t.shift(),t.length>0&&(e<0?e=0:e>=t.length&&(e=t.length-1),this.focusedChild_=e,t[e].el_.focus())}}ae.registerComponent("Menu",U7);class iA extends ae{constructor(e,t={}){super(e,t),this.menuButton_=new ai(e,t),this.menuButton_.controlText(this.controlText_),this.menuButton_.el_.setAttribute("aria-haspopup","true");const i=ai.prototype.buildCSSClass();this.menuButton_.el_.className=this.buildCSSClass()+" "+i,this.menuButton_.removeClass("vjs-control"),this.addChild(this.menuButton_),this.update(),this.enabled_=!0;const n=a=>this.handleClick(a);this.handleMenuKeyUp_=a=>this.handleMenuKeyUp(a),this.on(this.menuButton_,"tap",n),this.on(this.menuButton_,"click",n),this.on(this.menuButton_,"keydown",a=>this.handleKeyDown(a)),this.on(this.menuButton_,"mouseenter",()=>{this.addClass("vjs-hover"),this.menu.show(),yn(de,"keyup",this.handleMenuKeyUp_)}),this.on("mouseleave",a=>this.handleMouseLeave(a)),this.on("keydown",a=>this.handleSubmenuKeyDown(a))}update(){const e=this.createMenu();this.menu&&(this.menu.dispose(),this.removeChild(this.menu)),this.menu=e,this.addChild(e),this.buttonPressed_=!1,this.menuButton_.el_.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.hideThreshold_?(this.hide(),this.menu.contentEl_.removeAttribute("role")):(this.show(),this.menu.contentEl_.setAttribute("role","menu"))}createMenu(){const e=new U7(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){const t=Ke("li",{className:"vjs-menu-title",textContent:nr(this.options_.title),tabIndex:-1}),i=new ae(this.player_,{el:t});e.addItem(i)}if(this.items=this.createItems(),this.items)for(let t=0;t{this.handleTracksChange.apply(this,o)},s=(...o)=>{this.handleSelectedLanguageChange.apply(this,o)};if(e.on(["loadstart","texttrackchange"],a),n.addEventListener("change",a),n.addEventListener("selectedlanguagechange",s),this.on("dispose",function(){e.off(["loadstart","texttrackchange"],a),n.removeEventListener("change",a),n.removeEventListener("selectedlanguagechange",s)}),n.onchange===void 0){let o;this.on(["tap","click"],function(){if(typeof H.Event!="object")try{o=new H.Event("change")}catch{}o||(o=de.createEvent("Event"),o.initEvent("change",!0,!0)),n.dispatchEvent(o)})}this.handleTracksChange()}handleClick(e){const t=this.track,i=this.player_.textTracks();if(super.handleClick(e),!!i)for(let n=0;n-1&&s.mode==="showing"){i=!1;break}}i!==this.isSelected_&&this.selected(i)}handleSelectedLanguageChange(e){const t=this.player().textTracks();let i=!0;for(let n=0,a=t.length;n-1&&s.mode==="showing"){i=!1;break}}i&&(this.player_.cache_.selectedLanguage={enabled:!1})}handleLanguagechange(){this.$(".vjs-menu-item-text").textContent=this.player_.localize(this.options_.label),super.handleLanguagechange()}}ae.registerComponent("OffTextTrackMenuItem",V7);class Cf extends nA{constructor(e,t={}){t.tracks=e.textTracks(),super(e,t)}createItems(e=[],t=qv){let i;this.label_&&(i=`${this.label_} off`),e.push(new V7(this.player_,{kinds:this.kinds_,kind:this.kind_,label:i})),this.hideThreshold_+=1;const n=this.player_.textTracks();Array.isArray(this.kinds_)||(this.kinds_=[this.kind_]);for(let a=0;a-1){const o=new t(this.player_,{track:s,kinds:this.kinds_,kind:this.kind_,selectable:!0,multiSelectable:!1});o.addClass(`vjs-${s.kind}-menu-item`),e.push(o)}}return e}}ae.registerComponent("TextTrackButton",Cf);class z7 extends Wv{constructor(e,t){const i=t.track,n=t.cue,a=e.currentTime();t.selectable=!0,t.multiSelectable=!1,t.label=n.text,t.selected=n.startTime<=a&&a{this.items.forEach(n=>{n.selected(this.track_.activeCues[0]===n.cue)})}}buildCSSClass(){return`vjs-chapters-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-chapters-button ${super.buildWrapperCSSClass()}`}update(e){if(e&&e.track&&e.track.kind!=="chapters")return;const t=this.findChaptersTrack();t!==this.track_?(this.setTrack(t),super.update()):(!this.items||t&&t.cues&&t.cues.length!==this.items.length)&&super.update()}setTrack(e){if(this.track_!==e){if(this.updateHandler_||(this.updateHandler_=this.update.bind(this)),this.track_){const t=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);t&&t.removeEventListener("load",this.updateHandler_),this.track_.removeEventListener("cuechange",this.selectCurrentItem_),this.track_=null}if(this.track_=e,this.track_){this.track_.mode="hidden";const t=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);t&&t.addEventListener("load",this.updateHandler_),this.track_.addEventListener("cuechange",this.selectCurrentItem_)}}}findChaptersTrack(){const e=this.player_.textTracks()||[];for(let t=e.length-1;t>=0;t--){const i=e[t];if(i.kind===this.kind_)return i}}getMenuCaption(){return this.track_&&this.track_.label?this.track_.label:this.localize(nr(this.kind_))}createMenu(){return this.options_.title=this.getMenuCaption(),super.createMenu()}createItems(){const e=[];if(!this.track_)return e;const t=this.track_.cues;if(!t)return e;for(let i=0,n=t.length;i-1&&(this.label_="captions",this.setIcon("captions")),this.menuButton_.controlText(nr(this.label_))}buildCSSClass(){return`vjs-subs-caps-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-subs-caps-button ${super.buildWrapperCSSClass()}`}createItems(){let e=[];return!(this.player().tech_&&this.player().tech_.featuresNativeTextTracks)&&this.player().getChild("textTrackSettings")&&(e.push(new lA(this.player_,{kind:this.label_})),this.hideThreshold_+=1),e=super.createItems(e,G7),e}}cA.prototype.kinds_=["captions","subtitles"];cA.prototype.controlText_="Subtitles";ae.registerComponent("SubsCapsButton",cA);class H7 extends Wv{constructor(e,t){const i=t.track,n=e.audioTracks();t.label=i.label||i.language||"Unknown",t.selected=i.enabled,super(e,t),this.track=i,this.addClass(`vjs-${i.kind}-menu-item`);const a=(...s)=>{this.handleTracksChange.apply(this,s)};n.addEventListener("change",a),this.on("dispose",()=>{n.removeEventListener("change",a)})}createEl(e,t,i){const n=super.createEl(e,t,i),a=n.querySelector(".vjs-menu-item-text");return["main-desc","descriptions"].indexOf(this.options_.track.kind)>=0&&(a.appendChild(Ke("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),a.appendChild(Ke("span",{className:"vjs-control-text",textContent:" "+this.localize("Descriptions")}))),n}handleClick(e){if(super.handleClick(e),this.track.enabled=!0,this.player_.tech_.featuresNativeAudioTracks){const t=this.player_.audioTracks();for(let i=0;ithis.update(a))}handleClick(e){super.handleClick(),this.player().playbackRate(this.rate)}update(e){this.selected(this.player().playbackRate()===this.rate)}}hA.prototype.contentElType="button";ae.registerComponent("PlaybackRateMenuItem",hA);class W7 extends iA{constructor(e,t){super(e,t),this.menuButton_.el_.setAttribute("aria-describedby",this.labelElId_),this.updateVisibility(),this.updateLabel(),this.on(e,"loadstart",i=>this.updateVisibility(i)),this.on(e,"ratechange",i=>this.updateLabel(i)),this.on(e,"playbackrateschange",i=>this.handlePlaybackRateschange(i))}createEl(){const e=super.createEl();return this.labelElId_="vjs-playback-rate-value-label-"+this.id_,this.labelEl_=Ke("div",{className:"vjs-playback-rate-value",id:this.labelElId_,textContent:"1x"}),e.appendChild(this.labelEl_),e}dispose(){this.labelEl_=null,super.dispose()}buildCSSClass(){return`vjs-playback-rate ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-playback-rate ${super.buildWrapperCSSClass()}`}createItems(){const e=this.playbackRates(),t=[];for(let i=e.length-1;i>=0;i--)t.push(new hA(this.player(),{rate:e[i]+"x"}));return t}handlePlaybackRateschange(e){this.update()}playbackRates(){const e=this.player();return e.playbackRates&&e.playbackRates()||[]}playbackRateSupported(){return this.player().tech_&&this.player().tech_.featuresPlaybackRate&&this.playbackRates()&&this.playbackRates().length>0}updateVisibility(e){this.playbackRateSupported()?this.removeClass("vjs-hidden"):this.addClass("vjs-hidden")}updateLabel(e){this.playbackRateSupported()&&(this.labelEl_.textContent=this.player().playbackRate()+"x")}}W7.prototype.controlText_="Playback Rate";ae.registerComponent("PlaybackRateMenuButton",W7);class q7 extends ae{buildCSSClass(){return`vjs-spacer ${super.buildCSSClass()}`}createEl(e="div",t={},i={}){return t.className||(t.className=this.buildCSSClass()),super.createEl(e,t,i)}}ae.registerComponent("Spacer",q7);class Lte extends q7{buildCSSClass(){return`vjs-custom-control-spacer ${super.buildCSSClass()}`}createEl(){return super.createEl("div",{className:this.buildCSSClass(),textContent:" "})}}ae.registerComponent("CustomControlSpacer",Lte);class j7 extends ae{createEl(){return super.createEl("div",{className:"vjs-control-bar",dir:"ltr"})}}j7.prototype.options_={children:["playToggle","skipBackward","skipForward","volumePanel","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","seekToLive","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subsCapsButton","audioTrackButton","pictureInPictureToggle","fullscreenToggle"]};ae.registerComponent("ControlBar",j7);class X7 extends xf{constructor(e,t){super(e,t),this.on(e,"error",i=>{this.open(i)})}buildCSSClass(){return`vjs-error-display ${super.buildCSSClass()}`}content(){const e=this.player().error();return e?this.localize(e.message):""}}X7.prototype.options_=Object.assign({},xf.prototype.options_,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0});ae.registerComponent("ErrorDisplay",X7);class Y7 extends ae{constructor(e,t={}){super(e,t),this.el_.setAttribute("aria-labelledby",this.selectLabelledbyIds)}createEl(){return this.selectLabelledbyIds=[this.options_.legendId,this.options_.labelId].join(" ").trim(),Ke("select",{id:this.options_.id},{},this.options_.SelectOptions.map(t=>{const i=(this.options_.labelId?this.options_.labelId:`vjs-track-option-${qn()}`)+"-"+t[1].replace(/\W+/g,""),n=Ke("option",{id:i,value:this.localize(t[0]),textContent:t[1]});return n.setAttribute("aria-labelledby",`${this.selectLabelledbyIds} ${i}`),n}))}}ae.registerComponent("TextTrackSelect",Y7);class Eu extends ae{constructor(e,t={}){super(e,t);const i=Ke("legend",{textContent:this.localize(this.options_.legendText),id:this.options_.legendId});this.el().appendChild(i);const n=this.options_.selects;for(const a of n){const s=this.options_.selectConfigs[a],o=s.className,l=s.id.replace("%s",this.options_.id_);let u=null;const c=`vjs_select_${qn()}`;if(this.options_.type==="colors"){u=Ke("span",{className:o});const d=Ke("label",{id:l,className:"vjs-label",textContent:s.label});d.setAttribute("for",c),u.appendChild(d)}const h=new Y7(e,{SelectOptions:s.options,legendId:this.options_.legendId,id:c,labelId:l});this.addChild(h),this.options_.type==="colors"&&(u.appendChild(h.el()),this.el().appendChild(u))}}createEl(){return Ke("fieldset",{className:this.options_.className})}}ae.registerComponent("TextTrackFieldset",Eu);class K7 extends ae{constructor(e,t={}){super(e,t);const i=this.options_.textTrackComponentid,n=new Eu(e,{id_:i,legendId:`captions-text-legend-${i}`,legendText:this.localize("Text"),className:"vjs-fg vjs-track-setting",selects:this.options_.fieldSets[0],selectConfigs:this.options_.selectConfigs,type:"colors"});this.addChild(n);const a=new Eu(e,{id_:i,legendId:`captions-background-${i}`,legendText:this.localize("Text Background"),className:"vjs-bg vjs-track-setting",selects:this.options_.fieldSets[1],selectConfigs:this.options_.selectConfigs,type:"colors"});this.addChild(a);const s=new Eu(e,{id_:i,legendId:`captions-window-${i}`,legendText:this.localize("Caption Area Background"),className:"vjs-window vjs-track-setting",selects:this.options_.fieldSets[2],selectConfigs:this.options_.selectConfigs,type:"colors"});this.addChild(s)}createEl(){return Ke("div",{className:"vjs-track-settings-colors"})}}ae.registerComponent("TextTrackSettingsColors",K7);class Z7 extends ae{constructor(e,t={}){super(e,t);const i=this.options_.textTrackComponentid,n=new Eu(e,{id_:i,legendId:`captions-font-size-${i}`,legendText:"Font Size",className:"vjs-font-percent vjs-track-setting",selects:this.options_.fieldSets[0],selectConfigs:this.options_.selectConfigs,type:"font"});this.addChild(n);const a=new Eu(e,{id_:i,legendId:`captions-edge-style-${i}`,legendText:this.localize("Text Edge Style"),className:"vjs-edge-style vjs-track-setting",selects:this.options_.fieldSets[1],selectConfigs:this.options_.selectConfigs,type:"font"});this.addChild(a);const s=new Eu(e,{id_:i,legendId:`captions-font-family-${i}`,legendText:this.localize("Font Family"),className:"vjs-font-family vjs-track-setting",selects:this.options_.fieldSets[2],selectConfigs:this.options_.selectConfigs,type:"font"});this.addChild(s)}createEl(){return Ke("div",{className:"vjs-track-settings-font"})}}ae.registerComponent("TextTrackSettingsFont",Z7);class Q7 extends ae{constructor(e,t={}){super(e,t);const i=this.localize("restore all settings to the default values"),n=new ai(e,{controlText:i,className:"vjs-default-button"});n.el().classList.remove("vjs-control","vjs-button"),n.el().textContent=this.localize("Reset"),this.addChild(n);const a=new ai(e,{controlText:i,className:"vjs-done-button"});a.el().classList.remove("vjs-control","vjs-button"),a.el().textContent=this.localize("Done"),this.addChild(a)}createEl(){return Ke("div",{className:"vjs-track-settings-controls"})}}ae.registerComponent("TrackSettingsControls",Q7);const _2="vjs-text-track-settings",XI=["#000","Black"],YI=["#00F","Blue"],KI=["#0FF","Cyan"],ZI=["#0F0","Green"],QI=["#F0F","Magenta"],JI=["#F00","Red"],e4=["#FFF","White"],t4=["#FF0","Yellow"],b2=["1","Opaque"],S2=["0.5","Semi-Transparent"],r4=["0","Transparent"],Ao={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[XI,e4,JI,ZI,YI,t4,QI,KI],className:"vjs-bg-color"},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Opacity",options:[b2,S2,r4],className:"vjs-bg-opacity vjs-opacity"},color:{selector:".vjs-text-color > select",id:"captions-foreground-color-%s",label:"Color",options:[e4,XI,JI,ZI,YI,t4,QI,KI],className:"vjs-text-color"},edgeStyle:{selector:".vjs-edge-style > select",id:"",label:"Text Edge Style",options:[["none","None"],["raised","Raised"],["depressed","Depressed"],["uniform","Uniform"],["dropshadow","Drop shadow"]]},fontFamily:{selector:".vjs-font-family > select",id:"",label:"Font Family",options:[["proportionalSansSerif","Proportional Sans-Serif"],["monospaceSansSerif","Monospace Sans-Serif"],["proportionalSerif","Proportional Serif"],["monospaceSerif","Monospace Serif"],["casual","Casual"],["script","Script"],["small-caps","Small Caps"]]},fontPercent:{selector:".vjs-font-percent > select",id:"",label:"Font Size",options:[["0.50","50%"],["0.75","75%"],["1.00","100%"],["1.25","125%"],["1.50","150%"],["1.75","175%"],["2.00","200%"],["3.00","300%"],["4.00","400%"]],default:2,parser:r=>r==="1.00"?null:Number(r)},textOpacity:{selector:".vjs-text-opacity > select",id:"captions-foreground-opacity-%s",label:"Opacity",options:[b2,S2],className:"vjs-text-opacity vjs-opacity"},windowColor:{selector:".vjs-window-color > select",id:"captions-window-color-%s",label:"Color",className:"vjs-window-color"},windowOpacity:{selector:".vjs-window-opacity > select",id:"captions-window-opacity-%s",label:"Opacity",options:[r4,S2,b2],className:"vjs-window-opacity vjs-opacity"}};Ao.windowColor.options=Ao.backgroundColor.options;function J7(r,e){if(e&&(r=e(r)),r&&r!=="none")return r}function kte(r,e){const t=r.options[r.options.selectedIndex].value;return J7(t,e)}function Rte(r,e,t){if(e){for(let i=0;i{this.saveSettings(),this.close()}),this.on(this.$(".vjs-default-button"),["click","tap"],()=>{this.setDefaults(),this.updateDisplay()}),bh(Ao,e=>{this.on(this.$(e.selector),"change",this.updateDisplay)})}dispose(){this.endDialog=null,super.dispose()}label(){return this.localize("Caption Settings Dialog")}description(){return this.localize("Beginning of dialog window. Escape will cancel and close the window.")}buildCSSClass(){return super.buildCSSClass()+" vjs-text-track-settings"}getValues(){return HO(Ao,(e,t,i)=>{const n=kte(this.$(t.selector),t.parser);return n!==void 0&&(e[i]=n),e},{})}setValues(e){bh(Ao,(t,i)=>{Rte(this.$(t.selector),e[i],t.parser)})}setDefaults(){bh(Ao,e=>{const t=e.hasOwnProperty("default")?e.default:0;this.$(e.selector).selectedIndex=t})}restoreSettings(){let e;try{e=JSON.parse(H.localStorage.getItem(_2))}catch(t){pt.warn(t)}e&&this.setValues(e)}saveSettings(){if(!this.options_.persistTextTrackSettings)return;const e=this.getValues();try{Object.keys(e).length?H.localStorage.setItem(_2,JSON.stringify(e)):H.localStorage.removeItem(_2)}catch(t){pt.warn(t)}}updateDisplay(){const e=this.player_.getChild("textTrackDisplay");e&&e.updateDisplay()}handleLanguagechange(){this.fill(),this.renderModalComponents(this.player_),this.bindFunctionsToSelectsAndButtons()}}ae.registerComponent("TextTrackSettings",Ote);class Nte extends ae{constructor(e,t){let i=t.ResizeObserver||H.ResizeObserver;t.ResizeObserver===null&&(i=!1);const n=Ut({createEl:!i,reportTouchActivity:!1},t);super(e,n),this.ResizeObserver=t.ResizeObserver||H.ResizeObserver,this.loadListener_=null,this.resizeObserver_=null,this.debouncedHandler_=f7(()=>{this.resizeHandler()},100,!1,this),i?(this.resizeObserver_=new this.ResizeObserver(this.debouncedHandler_),this.resizeObserver_.observe(e.el())):(this.loadListener_=()=>{if(!this.el_||!this.el_.contentWindow)return;const a=this.debouncedHandler_;let s=this.unloadListener_=function(){ni(this,"resize",a),ni(this,"unload",s),s=null};yn(this.el_.contentWindow,"unload",s),yn(this.el_.contentWindow,"resize",a)},this.one("load",this.loadListener_))}createEl(){return super.createEl("iframe",{className:"vjs-resize-manager",tabIndex:-1,title:this.localize("No content")},{"aria-hidden":"true"})}resizeHandler(){!this.player_||!this.player_.trigger||this.player_.trigger("playerresize")}dispose(){this.debouncedHandler_&&this.debouncedHandler_.cancel(),this.resizeObserver_&&(this.player_.el()&&this.resizeObserver_.unobserve(this.player_.el()),this.resizeObserver_.disconnect()),this.loadListener_&&this.off("load",this.loadListener_),this.el_&&this.el_.contentWindow&&this.unloadListener_&&this.unloadListener_.call(this.el_.contentWindow),this.ResizeObserver=null,this.resizeObserver=null,this.debouncedHandler_=null,this.loadListener_=null,super.dispose()}}ae.registerComponent("ResizeManager",Nte);const Bte={trackingThreshold:20,liveTolerance:15};class Fte extends ae{constructor(e,t){const i=Ut(Bte,t,{createEl:!1});super(e,i),this.trackLiveHandler_=()=>this.trackLive_(),this.handlePlay_=n=>this.handlePlay(n),this.handleFirstTimeupdate_=n=>this.handleFirstTimeupdate(n),this.handleSeeked_=n=>this.handleSeeked(n),this.seekToLiveEdge_=n=>this.seekToLiveEdge(n),this.reset_(),this.on(this.player_,"durationchange",n=>this.handleDurationchange(n)),this.on(this.player_,"canplay",()=>this.toggleTracking())}trackLive_(){const e=this.player_.seekable();if(!e||!e.length)return;const t=Number(H.performance.now().toFixed(4)),i=this.lastTime_===-1?0:(t-this.lastTime_)/1e3;this.lastTime_=t,this.pastSeekEnd_=this.pastSeekEnd()+i;const n=this.liveCurrentTime(),a=this.player_.currentTime();let s=this.player_.paused()||this.seekedBehindLive_||Math.abs(n-a)>this.options_.liveTolerance;(!this.timeupdateSeen_||n===1/0)&&(s=!1),s!==this.behindLiveEdge_&&(this.behindLiveEdge_=s,this.trigger("liveedgechange"))}handleDurationchange(){this.toggleTracking()}toggleTracking(){this.player_.duration()===1/0&&this.liveWindow()>=this.options_.trackingThreshold?(this.player_.options_.liveui&&this.player_.addClass("vjs-liveui"),this.startTracking()):(this.player_.removeClass("vjs-liveui"),this.stopTracking())}startTracking(){this.isTracking()||(this.timeupdateSeen_||(this.timeupdateSeen_=this.player_.hasStarted()),this.trackingInterval_=this.setInterval(this.trackLiveHandler_,jn),this.trackLive_(),this.on(this.player_,["play","pause"],this.trackLiveHandler_),this.timeupdateSeen_?this.on(this.player_,"seeked",this.handleSeeked_):(this.one(this.player_,"play",this.handlePlay_),this.one(this.player_,"timeupdate",this.handleFirstTimeupdate_)))}handleFirstTimeupdate(){this.timeupdateSeen_=!0,this.on(this.player_,"seeked",this.handleSeeked_)}handleSeeked(){const e=Math.abs(this.liveCurrentTime()-this.player_.currentTime());this.seekedBehindLive_=this.nextSeekedFromUser_&&e>2,this.nextSeekedFromUser_=!1,this.trackLive_()}handlePlay(){this.one(this.player_,"timeupdate",this.seekToLiveEdge_)}reset_(){this.lastTime_=-1,this.pastSeekEnd_=0,this.lastSeekEnd_=-1,this.behindLiveEdge_=!0,this.timeupdateSeen_=!1,this.seekedBehindLive_=!1,this.nextSeekedFromUser_=!1,this.clearInterval(this.trackingInterval_),this.trackingInterval_=null,this.off(this.player_,["play","pause"],this.trackLiveHandler_),this.off(this.player_,"seeked",this.handleSeeked_),this.off(this.player_,"play",this.handlePlay_),this.off(this.player_,"timeupdate",this.handleFirstTimeupdate_),this.off(this.player_,"timeupdate",this.seekToLiveEdge_)}nextSeekedFromUser(){this.nextSeekedFromUser_=!0}stopTracking(){this.isTracking()&&(this.reset_(),this.trigger("liveedgechange"))}seekableEnd(){const e=this.player_.seekable(),t=[];let i=e?e.length:0;for(;i--;)t.push(e.end(i));return t.length?t.sort()[t.length-1]:1/0}seekableStart(){const e=this.player_.seekable(),t=[];let i=e?e.length:0;for(;i--;)t.push(e.start(i));return t.length?t.sort()[0]:0}liveWindow(){const e=this.liveCurrentTime();return e===1/0?0:e-this.seekableStart()}isLive(){return this.isTracking()}atLiveEdge(){return!this.behindLiveEdge()}liveCurrentTime(){return this.pastSeekEnd()+this.seekableEnd()}pastSeekEnd(){const e=this.seekableEnd();return this.lastSeekEnd_!==-1&&e!==this.lastSeekEnd_&&(this.pastSeekEnd_=0),this.lastSeekEnd_=e,this.pastSeekEnd_}behindLiveEdge(){return this.behindLiveEdge_}isTracking(){return typeof this.trackingInterval_=="number"}seekToLiveEdge(){this.seekedBehindLive_=!1,!this.atLiveEdge()&&(this.nextSeekedFromUser_=!1,this.player_.currentTime(this.liveCurrentTime()))}dispose(){this.stopTracking(),super.dispose()}}ae.registerComponent("LiveTracker",Fte);class Ute extends ae{constructor(e,t){super(e,t),this.on("statechanged",i=>this.updateDom_()),this.updateDom_()}createEl(){return this.els={title:Ke("div",{className:"vjs-title-bar-title",id:`vjs-title-bar-title-${qn()}`}),description:Ke("div",{className:"vjs-title-bar-description",id:`vjs-title-bar-description-${qn()}`})},Ke("div",{className:"vjs-title-bar"},{},$O(this.els))}updateDom_(){const e=this.player_.tech_,t=e&&e.el_,i={title:"aria-labelledby",description:"aria-describedby"};["title","description"].forEach(n=>{const a=this.state[n],s=this.els[n],o=i[n];B_(s),a&&ll(s,a),t&&(t.removeAttribute(o),a&&t.setAttribute(o,s.id))}),this.state.title||this.state.description?this.show():this.hide()}update(e){this.setState(e)}dispose(){const e=this.player_.tech_,t=e&&e.el_;t&&(t.removeAttribute("aria-labelledby"),t.removeAttribute("aria-describedby")),super.dispose(),this.els=null}}ae.registerComponent("TitleBar",Ute);const Vte={initialDisplay:4e3,position:[],takeFocus:!1};class zte extends ai{constructor(e,t){t=Ut(Vte,t),super(e,t),this.controlText(t.controlText),this.hide(),this.on(this.player_,["useractive","userinactive"],i=>{this.removeClass("force-display")})}buildCSSClass(){return`vjs-transient-button focus-visible ${this.options_.position.map(e=>`vjs-${e}`).join(" ")}`}createEl(){const e=Ke("button",{},{type:"button",class:this.buildCSSClass()},Ke("span"));return this.controlTextEl_=e.querySelector("span"),e}show(){super.show(),this.addClass("force-display"),this.options_.takeFocus&&this.el().focus({preventScroll:!0}),this.forceDisplayTimeout=this.player_.setTimeout(()=>{this.removeClass("force-display")},this.options_.initialDisplay)}hide(){this.removeClass("force-display"),super.hide()}dispose(){this.player_.clearTimeout(this.forceDisplayTimeout),super.dispose()}}ae.registerComponent("TransientButton",zte);const BT=r=>{const e=r.el();if(e.hasAttribute("src"))return r.triggerSourceset(e.src),!0;const t=r.$$("source"),i=[];let n="";if(!t.length)return!1;for(let a=0;a{let t={};for(let i=0;ie9([r.el(),H.HTMLMediaElement.prototype,H.Element.prototype,Gte],"innerHTML"),i4=function(r){const e=r.el();if(e.resetSourceWatch_)return;const t={},i=Hte(r),n=a=>(...s)=>{const o=a.apply(e,s);return BT(r),o};["append","appendChild","insertAdjacentHTML"].forEach(a=>{e[a]&&(t[a]=e[a],e[a]=n(t[a]))}),Object.defineProperty(e,"innerHTML",Ut(i,{set:n(i.set)})),e.resetSourceWatch_=()=>{e.resetSourceWatch_=null,Object.keys(t).forEach(a=>{e[a]=t[a]}),Object.defineProperty(e,"innerHTML",i)},r.one("sourceset",e.resetSourceWatch_)},$te=Object.defineProperty({},"src",{get(){return this.hasAttribute("src")?T7(H.Element.prototype.getAttribute.call(this,"src")):""},set(r){return H.Element.prototype.setAttribute.call(this,"src",r),r}}),Wte=r=>e9([r.el(),H.HTMLMediaElement.prototype,$te],"src"),qte=function(r){if(!r.featuresSourceset)return;const e=r.el();if(e.resetSourceset_)return;const t=Wte(r),i=e.setAttribute,n=e.load;Object.defineProperty(e,"src",Ut(t,{set:a=>{const s=t.set.call(e,a);return r.triggerSourceset(e.src),s}})),e.setAttribute=(a,s)=>{const o=i.call(e,a,s);return/src/i.test(a)&&r.triggerSourceset(e.src),o},e.load=()=>{const a=n.call(e);return BT(r)||(r.triggerSourceset(""),i4(r)),a},e.currentSrc?r.triggerSourceset(e.currentSrc):BT(r)||i4(r),e.resetSourceset_=()=>{e.resetSourceset_=null,e.load=n,e.setAttribute=i,Object.defineProperty(e,"src",t),e.resetSourceWatch_&&e.resetSourceWatch_()}};class xe extends it{constructor(e,t){super(e,t);const i=e.source;let n=!1;if(this.featuresVideoFrameCallback=this.featuresVideoFrameCallback&&this.el_.tagName==="VIDEO",i&&(this.el_.currentSrc!==i.src||e.tag&&e.tag.initNetworkState_===3)?this.setSource(i):this.handleLateInit_(this.el_),e.enableSourceset&&this.setupSourcesetHandling_(),this.isScrubbing_=!1,this.el_.hasChildNodes()){const a=this.el_.childNodes;let s=a.length;const o=[];for(;s--;){const l=a[s];l.nodeName.toLowerCase()==="track"&&(this.featuresNativeTextTracks?(this.remoteTextTrackEls().addTrackElement_(l),this.remoteTextTracks().addTrack(l.track),this.textTracks().addTrack(l.track),!n&&!this.el_.hasAttribute("crossorigin")&&z_(l.src)&&(n=!0)):o.push(l))}for(let l=0;l{t=[];for(let a=0;ae.removeEventListener("change",i));const n=()=>{for(let a=0;a{e.removeEventListener("change",i),e.removeEventListener("change",n),e.addEventListener("change",n)}),this.on("webkitendfullscreen",()=>{e.removeEventListener("change",i),e.addEventListener("change",i),e.removeEventListener("change",n)})}overrideNative_(e,t){if(t!==this[`featuresNative${e}Tracks`])return;const i=e.toLowerCase();this[`${i}TracksListeners_`]&&Object.keys(this[`${i}TracksListeners_`]).forEach(n=>{this.el()[`${i}Tracks`].removeEventListener(n,this[`${i}TracksListeners_`][n])}),this[`featuresNative${e}Tracks`]=!t,this[`${i}TracksListeners_`]=null,this.proxyNativeTracksForType_(i)}overrideNativeAudioTracks(e){this.overrideNative_("Audio",e)}overrideNativeVideoTracks(e){this.overrideNative_("Video",e)}proxyNativeTracksForType_(e){const t=Hn[e],i=this.el()[t.getterName],n=this[t.getterName]();if(!this[`featuresNative${t.capitalName}Tracks`]||!i||!i.addEventListener)return;const a={change:o=>{const l={type:"change",target:n,currentTarget:n,srcElement:n};n.trigger(l),e==="text"&&this[Zh.remoteText.getterName]().trigger(l)},addtrack(o){n.addTrack(o.track)},removetrack(o){n.removeTrack(o.track)}},s=function(){const o=[];for(let l=0;l{const l=a[o];i.addEventListener(o,l),this.on("dispose",u=>i.removeEventListener(o,l))}),this.on("loadstart",s),this.on("dispose",o=>this.off("loadstart",s))}proxyNativeTracks_(){Hn.names.forEach(e=>{this.proxyNativeTracksForType_(e)})}createEl(){let e=this.options_.tag;if(!e||!(this.options_.playerElIngest||this.movingMediaElementInDOM)){if(e){const i=e.cloneNode(!0);e.parentNode&&e.parentNode.insertBefore(i,e),xe.disposeMediaElement(e),e=i}else{e=de.createElement("video");const i=this.options_.tag&&Co(this.options_.tag),n=Ut({},i);(!Xp||this.options_.nativeControlsForTouch!==!0)&&delete n.controls,JO(e,Object.assign(n,{id:this.options_.techId,class:"vjs-tech"}))}e.playerId=this.options_.playerId}typeof this.options_.preload<"u"&&jh(e,"preload",this.options_.preload),this.options_.disablePictureInPicture!==void 0&&(e.disablePictureInPicture=this.options_.disablePictureInPicture);const t=["loop","muted","playsinline","autoplay"];for(let i=0;i=2&&t.push("loadeddata"),e.readyState>=3&&t.push("canplay"),e.readyState>=4&&t.push("canplaythrough"),this.ready(function(){t.forEach(function(i){this.trigger(i)},this)})}setScrubbing(e){this.isScrubbing_=e}scrubbing(){return this.isScrubbing_}setCurrentTime(e){try{this.isScrubbing_&&this.el_.fastSeek&&k_?this.el_.fastSeek(e):this.el_.currentTime=e}catch(t){pt(t,"Video is not ready. (Video.js)")}}duration(){if(this.el_.duration===1/0&&ts&&rs&&this.el_.currentTime===0){const e=()=>{this.el_.currentTime>0&&(this.el_.duration===1/0&&this.trigger("durationchange"),this.off("timeupdate",e))};return this.on("timeupdate",e),NaN}return this.el_.duration||NaN}width(){return this.el_.offsetWidth}height(){return this.el_.offsetHeight}proxyWebkitFullscreen_(){if(!("webkitDisplayingFullscreen"in this.el_))return;const e=function(){this.trigger("fullscreenchange",{isFullscreen:!1}),this.el_.controls&&!this.options_.nativeControlsForTouch&&this.controls()&&(this.el_.controls=!1)},t=function(){"webkitPresentationMode"in this.el_&&this.el_.webkitPresentationMode!=="picture-in-picture"&&(this.one("webkitendfullscreen",e),this.trigger("fullscreenchange",{isFullscreen:!0,nativeIOSFullscreen:!0}))};this.on("webkitbeginfullscreen",t),this.on("dispose",()=>{this.off("webkitbeginfullscreen",t),this.off("webkitendfullscreen",e)})}supportsFullScreen(){return typeof this.el_.webkitEnterFullScreen=="function"}enterFullScreen(){const e=this.el_;if(e.paused&&e.networkState<=e.HAVE_METADATA)Va(this.el_.play()),this.setTimeout(function(){e.pause();try{e.webkitEnterFullScreen()}catch(t){this.trigger("fullscreenerror",t)}},0);else try{e.webkitEnterFullScreen()}catch(t){this.trigger("fullscreenerror",t)}}exitFullScreen(){if(!this.el_.webkitDisplayingFullscreen){this.trigger("fullscreenerror",new Error("The video is not fullscreen"));return}this.el_.webkitExitFullScreen()}requestPictureInPicture(){return this.el_.requestPictureInPicture()}requestVideoFrameCallback(e){return this.featuresVideoFrameCallback&&!this.el_.webkitKeys?this.el_.requestVideoFrameCallback(e):super.requestVideoFrameCallback(e)}cancelVideoFrameCallback(e){this.featuresVideoFrameCallback&&!this.el_.webkitKeys?this.el_.cancelVideoFrameCallback(e):super.cancelVideoFrameCallback(e)}src(e){if(e===void 0)return this.el_.src;this.setSrc(e)}reset(){xe.resetMediaElement(this.el_)}currentSrc(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc}setControls(e){this.el_.controls=!!e}addTextTrack(e,t,i){return this.featuresNativeTextTracks?this.el_.addTextTrack(e,t,i):super.addTextTrack(e,t,i)}createRemoteTextTrack(e){if(!this.featuresNativeTextTracks)return super.createRemoteTextTrack(e);const t=de.createElement("track");return e.kind&&(t.kind=e.kind),e.label&&(t.label=e.label),(e.language||e.srclang)&&(t.srclang=e.language||e.srclang),e.default&&(t.default=e.default),e.id&&(t.id=e.id),e.src&&(t.src=e.src),t}addRemoteTextTrack(e,t){const i=super.addRemoteTextTrack(e,t);return this.featuresNativeTextTracks&&this.el().appendChild(i),i}removeRemoteTextTrack(e){if(super.removeRemoteTextTrack(e),this.featuresNativeTextTracks){const t=this.$$("track");let i=t.length;for(;i--;)(e===t[i]||e===t[i].track)&&this.el().removeChild(t[i])}}getVideoPlaybackQuality(){if(typeof this.el().getVideoPlaybackQuality=="function")return this.el().getVideoPlaybackQuality();const e={};return typeof this.el().webkitDroppedFrameCount<"u"&&typeof this.el().webkitDecodedFrameCount<"u"&&(e.droppedVideoFrames=this.el().webkitDroppedFrameCount,e.totalVideoFrames=this.el().webkitDecodedFrameCount),H.performance&&(e.creationTime=H.performance.now()),e}}I_(xe,"TEST_VID",function(){if(!bf())return;const r=de.createElement("video"),e=de.createElement("track");return e.kind="captions",e.srclang="en",e.label="English",r.appendChild(e),r});xe.isSupported=function(){try{xe.TEST_VID.volume=.5}catch{return!1}return!!(xe.TEST_VID&&xe.TEST_VID.canPlayType)};xe.canPlayType=function(r){return xe.TEST_VID.canPlayType(r)};xe.canPlaySource=function(r,e){return xe.canPlayType(r.type)};xe.canControlVolume=function(){try{const r=xe.TEST_VID.volume;xe.TEST_VID.volume=r/2+.1;const e=r!==xe.TEST_VID.volume;return e&&xi?(H.setTimeout(()=>{xe&&xe.prototype&&(xe.prototype.featuresVolumeControl=r!==xe.TEST_VID.volume)}),!1):e}catch{return!1}};xe.canMuteVolume=function(){try{const r=xe.TEST_VID.muted;return xe.TEST_VID.muted=!r,xe.TEST_VID.muted?jh(xe.TEST_VID,"muted","muted"):O_(xe.TEST_VID,"muted","muted"),r!==xe.TEST_VID.muted}catch{return!1}};xe.canControlPlaybackRate=function(){if(ts&&rs&&P_<58)return!1;try{const r=xe.TEST_VID.playbackRate;return xe.TEST_VID.playbackRate=r/2+.1,r!==xe.TEST_VID.playbackRate}catch{return!1}};xe.canOverrideAttributes=function(){try{const r=()=>{};Object.defineProperty(de.createElement("video"),"src",{get:r,set:r}),Object.defineProperty(de.createElement("audio"),"src",{get:r,set:r}),Object.defineProperty(de.createElement("video"),"innerHTML",{get:r,set:r}),Object.defineProperty(de.createElement("audio"),"innerHTML",{get:r,set:r})}catch{return!1}return!0};xe.supportsNativeTextTracks=function(){return k_||xi&&rs};xe.supportsNativeVideoTracks=function(){return!!(xe.TEST_VID&&xe.TEST_VID.videoTracks)};xe.supportsNativeAudioTracks=function(){return!!(xe.TEST_VID&&xe.TEST_VID.audioTracks)};xe.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","resize","volumechange"];[["featuresMuteControl","canMuteVolume"],["featuresPlaybackRate","canControlPlaybackRate"],["featuresSourceset","canOverrideAttributes"],["featuresNativeTextTracks","supportsNativeTextTracks"],["featuresNativeVideoTracks","supportsNativeVideoTracks"],["featuresNativeAudioTracks","supportsNativeAudioTracks"]].forEach(function([r,e]){I_(xe.prototype,r,()=>xe[e](),!0)});xe.prototype.featuresVolumeControl=xe.canControlVolume();xe.prototype.movingMediaElementInDOM=!xi;xe.prototype.featuresFullscreenResize=!0;xe.prototype.featuresProgressEvents=!0;xe.prototype.featuresTimeupdateEvents=!0;xe.prototype.featuresVideoFrameCallback=!!(xe.TEST_VID&&xe.TEST_VID.requestVideoFrameCallback);xe.disposeMediaElement=function(r){if(r){for(r.parentNode&&r.parentNode.removeChild(r);r.hasChildNodes();)r.removeChild(r.firstChild);r.removeAttribute("src"),typeof r.load=="function"&&function(){try{r.load()}catch{}}()}};xe.resetMediaElement=function(r){if(!r)return;const e=r.querySelectorAll("source");let t=e.length;for(;t--;)r.removeChild(e[t]);r.removeAttribute("src"),typeof r.load=="function"&&function(){try{r.load()}catch{}}()};["muted","defaultMuted","autoplay","controls","loop","playsinline"].forEach(function(r){xe.prototype[r]=function(){return this.el_[r]||this.el_.hasAttribute(r)}});["muted","defaultMuted","autoplay","loop","playsinline"].forEach(function(r){xe.prototype["set"+nr(r)]=function(e){this.el_[r]=e,e?this.el_.setAttribute(r,r):this.el_.removeAttribute(r)}});["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","defaultPlaybackRate","disablePictureInPicture","played","networkState","readyState","videoWidth","videoHeight","crossOrigin"].forEach(function(r){xe.prototype[r]=function(){return this.el_[r]}});["volume","src","poster","preload","playbackRate","defaultPlaybackRate","disablePictureInPicture","crossOrigin"].forEach(function(r){xe.prototype["set"+nr(r)]=function(e){this.el_[r]=e}});["pause","load","play"].forEach(function(r){xe.prototype[r]=function(){return this.el_[r]()}});it.withSourceHandlers(xe);xe.nativeSourceHandler={};xe.nativeSourceHandler.canPlayType=function(r){try{return xe.TEST_VID.canPlayType(r)}catch{return""}};xe.nativeSourceHandler.canHandleSource=function(r,e){if(r.type)return xe.nativeSourceHandler.canPlayType(r.type);if(r.src){const t=YC(r.src);return xe.nativeSourceHandler.canPlayType(`video/${t}`)}return""};xe.nativeSourceHandler.handleSource=function(r,e,t){e.setSrc(r.src)};xe.nativeSourceHandler.dispose=function(){};xe.registerSourceHandler(xe.nativeSourceHandler);it.registerTech("Html5",xe);const t9=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","resize","volumechange","texttrackchange"],T2={canplay:"CanPlay",canplaythrough:"CanPlayThrough",playing:"Playing",seeked:"Seeked"},FT=["tiny","xsmall","small","medium","large","xlarge","huge"],a0={};FT.forEach(r=>{const e=r.charAt(0)==="x"?`x-${r.substring(1)}`:r;a0[r]=`vjs-layout-${e}`});const jte={tiny:210,xsmall:320,small:425,medium:768,large:1440,xlarge:2560,huge:1/0};let Lr=class rh extends ae{constructor(e,t,i){if(e.id=e.id||t.id||`vjs_video_${qn()}`,t=Object.assign(rh.getTagSettings(e),t),t.initChildren=!1,t.createEl=!1,t.evented=!1,t.reportTouchActivity=!1,!t.language){const s=e.closest("[lang]");s&&(t.language=s.getAttribute("lang"))}if(super(null,t,i),this.boundDocumentFullscreenChange_=s=>this.documentFullscreenChange_(s),this.boundFullWindowOnEscKey_=s=>this.fullWindowOnEscKey(s),this.boundUpdateStyleEl_=s=>this.updateStyleEl_(s),this.boundApplyInitTime_=s=>this.applyInitTime_(s),this.boundUpdateCurrentBreakpoint_=s=>this.updateCurrentBreakpoint_(s),this.boundHandleTechClick_=s=>this.handleTechClick_(s),this.boundHandleTechDoubleClick_=s=>this.handleTechDoubleClick_(s),this.boundHandleTechTouchStart_=s=>this.handleTechTouchStart_(s),this.boundHandleTechTouchMove_=s=>this.handleTechTouchMove_(s),this.boundHandleTechTouchEnd_=s=>this.handleTechTouchEnd_(s),this.boundHandleTechTap_=s=>this.handleTechTap_(s),this.boundUpdatePlayerHeightOnAudioOnlyMode_=s=>this.updatePlayerHeightOnAudioOnlyMode_(s),this.isFullscreen_=!1,this.log=zO(this.id_),this.fsApi_=H0,this.isPosterFromTech_=!1,this.queuedCallbacks_=[],this.isReady_=!1,this.hasStarted_=!1,this.userActive_=!1,this.debugEnabled_=!1,this.audioOnlyMode_=!1,this.audioPosterMode_=!1,this.audioOnlyCache_={controlBarHeight:null,playerHeight:null,hiddenChildren:[]},!this.options_||!this.options_.techOrder||!this.options_.techOrder.length)throw new Error("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(this.tag=e,this.tagAttributes=e&&Co(e),this.language(this.options_.language),t.languages){const s={};Object.getOwnPropertyNames(t.languages).forEach(function(o){s[o.toLowerCase()]=t.languages[o]}),this.languages_=s}else this.languages_=rh.prototype.options_.languages;this.resetCache_(),this.poster_=t.poster||"",this.controls_=!!t.controls,e.controls=!1,e.removeAttribute("controls"),this.changingSrc_=!1,this.playCallbacks_=[],this.playTerminatedQueue_=[],e.hasAttribute("autoplay")?this.autoplay(!0):this.autoplay(this.options_.autoplay),t.plugins&&Object.keys(t.plugins).forEach(s=>{if(typeof this[s]!="function")throw new Error(`plugin "${s}" does not exist`)}),this.scrubbing_=!1,this.el_=this.createEl(),WC(this,{eventBusKey:"el_"}),this.fsApi_.requestFullscreen&&(yn(de,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),this.on(this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_)),this.fluid_&&this.on(["playerreset","resize"],this.boundUpdateStyleEl_);const n=Ut(this.options_);if(t.plugins&&Object.keys(t.plugins).forEach(s=>{this[s](t.plugins[s])}),t.debug&&this.debug(!0),this.options_.playerOptions=n,this.middleware_=[],this.playbackRates(t.playbackRates),t.experimentalSvgIcons){const o=new H.DOMParser().parseFromString(gte,"image/svg+xml");if(o.querySelector("parsererror"))pt.warn("Failed to load SVG Icons. Falling back to Font Icons."),this.options_.experimentalSvgIcons=null;else{const u=o.documentElement;u.style.display="none",this.el_.appendChild(u),this.addClass("vjs-svg-icons-enabled")}}this.initChildren(),this.isAudio(e.nodeName.toLowerCase()==="audio"),this.controls()?this.addClass("vjs-controls-enabled"):this.addClass("vjs-controls-disabled"),this.el_.setAttribute("role","region"),this.isAudio()?this.el_.setAttribute("aria-label",this.localize("Audio Player")):this.el_.setAttribute("aria-label",this.localize("Video Player")),this.isAudio()&&this.addClass("vjs-audio"),t.spatialNavigation&&t.spatialNavigation.enabled&&(this.spatialNavigation=new mte(this),this.addClass("vjs-spatial-navigation-enabled")),Xp&&this.addClass("vjs-touch-enabled"),xi||this.addClass("vjs-workinghover"),rh.players[this.id_]=this;const a=ET.split(".")[0];this.addClass(`vjs-v${a}`),this.userActive(!0),this.reportUserActivity(),this.one("play",s=>this.listenForUserActivity_(s)),this.on("keydown",s=>this.handleKeyDown(s)),this.on("languagechange",s=>this.handleLanguagechange(s)),this.breakpoints(this.options_.breakpoints),this.responsive(this.options_.responsive),this.on("ready",()=>{this.audioPosterMode(this.options_.audioPosterMode),this.audioOnlyMode(this.options_.audioOnlyMode)})}dispose(){this.trigger("dispose"),this.off("dispose"),ni(de,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),ni(de,"keydown",this.boundFullWindowOnEscKey_),this.styleEl_&&this.styleEl_.parentNode&&(this.styleEl_.parentNode.removeChild(this.styleEl_),this.styleEl_=null),rh.players[this.id_]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.el_&&this.el_.player&&(this.el_.player=null),this.tech_&&(this.tech_.dispose(),this.isPosterFromTech_=!1,this.poster_=""),this.playerElIngest_&&(this.playerElIngest_=null),this.tag&&(this.tag=null),fte(this),_i.names.forEach(e=>{const t=_i[e],i=this[t.getterName]();i&&i.off&&i.off()}),super.dispose({restoreEl:this.options_.restoreEl})}createEl(){let e=this.tag,t,i=this.playerElIngest_=e.parentNode&&e.parentNode.hasAttribute&&e.parentNode.hasAttribute("data-vjs-player");const n=this.tag.tagName.toLowerCase()==="video-js";i?t=this.el_=e.parentNode:n||(t=this.el_=super.createEl("div"));const a=Co(e);if(n){for(t=this.el_=e,e=this.tag=de.createElement("video");t.children.length;)e.appendChild(t.firstChild);vp(t,"video-js")||Au(t,"video-js"),t.appendChild(e),i=this.playerElIngest_=t,Object.keys(t).forEach(l=>{try{e[l]=t[l]}catch{}})}e.setAttribute("tabindex","-1"),a.tabindex="-1",rs&&M_&&(e.setAttribute("role","application"),a.role="application"),e.removeAttribute("width"),e.removeAttribute("height"),"width"in a&&delete a.width,"height"in a&&delete a.height,Object.getOwnPropertyNames(a).forEach(function(l){n&&l==="class"||t.setAttribute(l,a[l]),n&&e.setAttribute(l,a[l])}),e.playerId=e.id,e.id+="_html5_api",e.className="vjs-tech",e.player=t.player=this,this.addClass("vjs-paused");const s=["IS_SMART_TV","IS_TIZEN","IS_WEBOS","IS_ANDROID","IS_IPAD","IS_IPHONE","IS_CHROMECAST_RECEIVER"].filter(l=>YO[l]).map(l=>"vjs-device-"+l.substring(3).toLowerCase().replace(/\_/g,"-"));if(this.addClass(...s),H.VIDEOJS_NO_DYNAMIC_STYLE!==!0){this.styleEl_=c7("vjs-styles-dimensions");const l=Ko(".vjs-styles-defaults"),u=Ko("head");u.insertBefore(this.styleEl_,l?l.nextSibling:u.firstChild)}this.fill_=!1,this.fluid_=!1,this.width(this.options_.width),this.height(this.options_.height),this.fill(this.options_.fill),this.fluid(this.options_.fluid),this.aspectRatio(this.options_.aspectRatio),this.crossOrigin(this.options_.crossOrigin||this.options_.crossorigin);const o=e.getElementsByTagName("a");for(let l=0;l"u")return this.techGet_("crossOrigin");if(e!==null&&e!=="anonymous"&&e!=="use-credentials"){pt.warn(`crossOrigin must be null, "anonymous" or "use-credentials", given "${e}"`);return}this.techCall_("setCrossOrigin",e),this.posterImage&&this.posterImage.crossOrigin(e)}width(e){return this.dimension("width",e)}height(e){return this.dimension("height",e)}dimension(e,t){const i=e+"_";if(t===void 0)return this[i]||0;if(t===""||t==="auto"){this[i]=void 0,this.updateStyleEl_();return}const n=parseFloat(t);if(isNaN(n)){pt.error(`Improper value "${t}" supplied for for ${e}`);return}this[i]=n,this.updateStyleEl_()}fluid(e){if(e===void 0)return!!this.fluid_;this.fluid_=!!e,Ls(this)&&this.off(["playerreset","resize"],this.boundUpdateStyleEl_),e?(this.addClass("vjs-fluid"),this.fill(!1),Gee(this,()=>{this.on(["playerreset","resize"],this.boundUpdateStyleEl_)})):this.removeClass("vjs-fluid"),this.updateStyleEl_()}fill(e){if(e===void 0)return!!this.fill_;this.fill_=!!e,e?(this.addClass("vjs-fill"),this.fluid(!1)):this.removeClass("vjs-fill")}aspectRatio(e){if(e===void 0)return this.aspectRatio_;if(!/^\d+\:\d+$/.test(e))throw new Error("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.aspectRatio_=e,this.fluid(!0),this.updateStyleEl_()}updateStyleEl_(){if(H.VIDEOJS_NO_DYNAMIC_STYLE===!0){const o=typeof this.width_=="number"?this.width_:this.options_.width,l=typeof this.height_=="number"?this.height_:this.options_.height,u=this.tech_&&this.tech_.el();u&&(o>=0&&(u.width=o),l>=0&&(u.height=l));return}let e,t,i,n;this.aspectRatio_!==void 0&&this.aspectRatio_!=="auto"?i=this.aspectRatio_:this.videoWidth()>0?i=this.videoWidth()+":"+this.videoHeight():i="16:9";const a=i.split(":"),s=a[1]/a[0];this.width_!==void 0?e=this.width_:this.height_!==void 0?e=this.height_/s:e=this.videoWidth()||300,this.height_!==void 0?t=this.height_:t=e*s,/^[^a-zA-Z]/.test(this.id())?n="dimensions-"+this.id():n=this.id()+"-dimensions",this.addClass(n),h7(this.styleEl_,` + .${n} { + width: ${e}px; + height: ${t}px; + } + + .${n}.vjs-fluid:not(.vjs-audio-only-mode) { + padding-top: ${s*100}%; + } + `)}loadTech_(e,t){this.tech_&&this.unloadTech_();const i=nr(e),n=e.charAt(0).toLowerCase()+e.slice(1);i!=="Html5"&&this.tag&&(it.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.techName_=i,this.isReady_=!1;let a=this.autoplay();(typeof this.autoplay()=="string"||this.autoplay()===!0&&this.options_.normalizeAutoplay)&&(a=!1);const s={source:t,autoplay:a,nativeControlsForTouch:this.options_.nativeControlsForTouch,playerId:this.id(),techId:`${this.id()}_${n}_api`,playsinline:this.options_.playsinline,preload:this.options_.preload,loop:this.options_.loop,disablePictureInPicture:this.options_.disablePictureInPicture,muted:this.options_.muted,poster:this.poster(),language:this.language(),playerElIngest:this.playerElIngest_||!1,"vtt.js":this.options_["vtt.js"],canOverridePoster:!!this.options_.techCanOverridePoster,enableSourceset:this.options_.enableSourceset};_i.names.forEach(l=>{const u=_i[l];s[u.getterName]=this[u.privateName]}),Object.assign(s,this.options_[i]),Object.assign(s,this.options_[n]),Object.assign(s,this.options_[e.toLowerCase()]),this.tag&&(s.tag=this.tag),t&&t.src===this.cache_.src&&this.cache_.currentTime>0&&(s.startTime=this.cache_.currentTime);const o=it.getTech(e);if(!o)throw new Error(`No Tech named '${i}' exists! '${i}' should be registered using videojs.registerTech()'`);this.tech_=new o(s),this.tech_.ready(Ht(this,this.handleTechReady_),!0),NI.jsonToTextTracks(this.textTracksJson_||[],this.tech_),t9.forEach(l=>{this.on(this.tech_,l,u=>this[`handleTech${nr(l)}_`](u))}),Object.keys(T2).forEach(l=>{this.on(this.tech_,l,u=>{if(this.tech_.playbackRate()===0&&this.tech_.seeking()){this.queuedCallbacks_.push({callback:this[`handleTech${T2[l]}_`].bind(this),event:u});return}this[`handleTech${T2[l]}_`](u)})}),this.on(this.tech_,"loadstart",l=>this.handleTechLoadStart_(l)),this.on(this.tech_,"sourceset",l=>this.handleTechSourceset_(l)),this.on(this.tech_,"waiting",l=>this.handleTechWaiting_(l)),this.on(this.tech_,"ended",l=>this.handleTechEnded_(l)),this.on(this.tech_,"seeking",l=>this.handleTechSeeking_(l)),this.on(this.tech_,"play",l=>this.handleTechPlay_(l)),this.on(this.tech_,"pause",l=>this.handleTechPause_(l)),this.on(this.tech_,"durationchange",l=>this.handleTechDurationChange_(l)),this.on(this.tech_,"fullscreenchange",(l,u)=>this.handleTechFullscreenChange_(l,u)),this.on(this.tech_,"fullscreenerror",(l,u)=>this.handleTechFullscreenError_(l,u)),this.on(this.tech_,"enterpictureinpicture",l=>this.handleTechEnterPictureInPicture_(l)),this.on(this.tech_,"leavepictureinpicture",l=>this.handleTechLeavePictureInPicture_(l)),this.on(this.tech_,"error",l=>this.handleTechError_(l)),this.on(this.tech_,"posterchange",l=>this.handleTechPosterChange_(l)),this.on(this.tech_,"textdata",l=>this.handleTechTextData_(l)),this.on(this.tech_,"ratechange",l=>this.handleTechRateChange_(l)),this.on(this.tech_,"loadedmetadata",this.boundUpdateStyleEl_),this.usingNativeControls(this.techGet_("controls")),this.controls()&&!this.usingNativeControls()&&this.addTechControlsListeners_(),this.tech_.el().parentNode!==this.el()&&(i!=="Html5"||!this.tag)&&PT(this.tech_.el(),this.el()),this.tag&&(this.tag.player=null,this.tag=null)}unloadTech_(){_i.names.forEach(e=>{const t=_i[e];this[t.privateName]=this[t.getterName]()}),this.textTracksJson_=NI.textTracksToJson(this.tech_),this.isReady_=!1,this.tech_.dispose(),this.tech_=!1,this.isPosterFromTech_&&(this.poster_="",this.trigger("posterchange")),this.isPosterFromTech_=!1}tech(e){return e===void 0&&pt.warn(`Using the tech directly can be dangerous. I hope you know what you're doing. +See https://github.com/videojs/video.js/issues/2617 for more info. +`),this.tech_}version(){return{"video.js":ET}}addTechControlsListeners_(){this.removeTechControlsListeners_(),this.on(this.tech_,"click",this.boundHandleTechClick_),this.on(this.tech_,"dblclick",this.boundHandleTechDoubleClick_),this.on(this.tech_,"touchstart",this.boundHandleTechTouchStart_),this.on(this.tech_,"touchmove",this.boundHandleTechTouchMove_),this.on(this.tech_,"touchend",this.boundHandleTechTouchEnd_),this.on(this.tech_,"tap",this.boundHandleTechTap_)}removeTechControlsListeners_(){this.off(this.tech_,"tap",this.boundHandleTechTap_),this.off(this.tech_,"touchstart",this.boundHandleTechTouchStart_),this.off(this.tech_,"touchmove",this.boundHandleTechTouchMove_),this.off(this.tech_,"touchend",this.boundHandleTechTouchEnd_),this.off(this.tech_,"click",this.boundHandleTechClick_),this.off(this.tech_,"dblclick",this.boundHandleTechDoubleClick_)}handleTechReady_(){this.triggerReady(),this.cache_.volume&&this.techCall_("setVolume",this.cache_.volume),this.handleTechPosterChange_(),this.handleTechDurationChange_()}handleTechLoadStart_(){this.removeClass("vjs-ended","vjs-seeking"),this.error(null),this.handleTechDurationChange_(),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):this.trigger("loadstart"),this.manualAutoplay_(this.autoplay()===!0&&this.options_.normalizeAutoplay?"play":this.autoplay())}manualAutoplay_(e){if(!this.tech_||typeof e!="string")return;const t=()=>{const n=this.muted();this.muted(!0);const a=()=>{this.muted(n)};this.playTerminatedQueue_.push(a);const s=this.play();if(mp(s))return s.catch(o=>{throw a(),new Error(`Rejection at manualAutoplay. Restoring muted value. ${o||""}`)})};let i;if(e==="any"&&!this.muted()?(i=this.play(),mp(i)&&(i=i.catch(t))):e==="muted"&&!this.muted()?i=t():i=this.play(),!!mp(i))return i.then(()=>{this.trigger({type:"autoplay-success",autoplay:e})}).catch(()=>{this.trigger({type:"autoplay-failure",autoplay:e})})}updateSourceCaches_(e=""){let t=e,i="";typeof t!="string"&&(t=e.src,i=e.type),this.cache_.source=this.cache_.source||{},this.cache_.sources=this.cache_.sources||[],t&&!i&&(i=vte(this,t)),this.cache_.source=Ut({},e,{src:t,type:i});const n=this.cache_.sources.filter(l=>l.src&&l.src===t),a=[],s=this.$$("source"),o=[];for(let l=0;lthis.updateSourceCaches_(a);const i=this.currentSource().src,n=e.src;i&&!/^blob:/.test(i)&&/^blob:/.test(n)&&(!this.lastSource_||this.lastSource_.tech!==n&&this.lastSource_.player!==i)&&(t=()=>{}),t(n),e.src||this.tech_.any(["sourceset","loadstart"],a=>{if(a.type==="sourceset")return;const s=this.techGet_("currentSrc");this.lastSource_.tech=s,this.updateSourceCaches_(s)})}this.lastSource_={player:this.currentSource().src,tech:e.src},this.trigger({src:e.src,type:"sourceset"})}hasStarted(e){if(e===void 0)return this.hasStarted_;e!==this.hasStarted_&&(this.hasStarted_=e,this.hasStarted_?this.addClass("vjs-has-started"):this.removeClass("vjs-has-started"))}handleTechPlay_(){this.removeClass("vjs-ended","vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")}handleTechRateChange_(){this.tech_.playbackRate()>0&&this.cache_.lastPlaybackRate===0&&(this.queuedCallbacks_.forEach(e=>e.callback(e.event)),this.queuedCallbacks_=[]),this.cache_.lastPlaybackRate=this.tech_.playbackRate(),this.trigger("ratechange")}handleTechWaiting_(){this.addClass("vjs-waiting"),this.trigger("waiting");const e=this.currentTime(),t=()=>{e!==this.currentTime()&&(this.removeClass("vjs-waiting"),this.off("timeupdate",t))};this.on("timeupdate",t)}handleTechCanPlay_(){this.removeClass("vjs-waiting"),this.trigger("canplay")}handleTechCanPlayThrough_(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")}handleTechPlaying_(){this.removeClass("vjs-waiting"),this.trigger("playing")}handleTechSeeking_(){this.addClass("vjs-seeking"),this.trigger("seeking")}handleTechSeeked_(){this.removeClass("vjs-seeking","vjs-ended"),this.trigger("seeked")}handleTechPause_(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")}handleTechEnded_(){this.addClass("vjs-ended"),this.removeClass("vjs-waiting"),this.options_.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")}handleTechDurationChange_(){this.duration(this.techGet_("duration"))}handleTechClick_(e){this.controls_&&(this.options_===void 0||this.options_.userActions===void 0||this.options_.userActions.click===void 0||this.options_.userActions.click!==!1)&&(this.options_!==void 0&&this.options_.userActions!==void 0&&typeof this.options_.userActions.click=="function"?this.options_.userActions.click.call(this,e):this.paused()?Va(this.play()):this.pause())}handleTechDoubleClick_(e){if(!this.controls_)return;Array.prototype.some.call(this.$$(".vjs-control-bar, .vjs-modal-dialog"),i=>i.contains(e.target))||(this.options_===void 0||this.options_.userActions===void 0||this.options_.userActions.doubleClick===void 0||this.options_.userActions.doubleClick!==!1)&&(this.options_!==void 0&&this.options_.userActions!==void 0&&typeof this.options_.userActions.doubleClick=="function"?this.options_.userActions.doubleClick.call(this,e):this.isFullscreen()?this.exitFullscreen():this.requestFullscreen())}handleTechTap_(){this.userActive(!this.userActive())}handleTechTouchStart_(){this.userWasActive=this.userActive()}handleTechTouchMove_(){this.userWasActive&&this.reportUserActivity()}handleTechTouchEnd_(e){e.cancelable&&e.preventDefault()}toggleFullscreenClass_(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")}documentFullscreenChange_(e){const t=e.target.player;if(t&&t!==this)return;const i=this.el();let n=de[this.fsApi_.fullscreenElement]===i;!n&&i.matches&&(n=i.matches(":"+this.fsApi_.fullscreen)),this.isFullscreen(n)}handleTechFullscreenChange_(e,t){t&&(t.nativeIOSFullscreen&&(this.addClass("vjs-ios-native-fs"),this.tech_.one("webkitendfullscreen",()=>{this.removeClass("vjs-ios-native-fs")})),this.isFullscreen(t.isFullscreen))}handleTechFullscreenError_(e,t){this.trigger("fullscreenerror",t)}togglePictureInPictureClass_(){this.isInPictureInPicture()?this.addClass("vjs-picture-in-picture"):this.removeClass("vjs-picture-in-picture")}handleTechEnterPictureInPicture_(e){this.isInPictureInPicture(!0)}handleTechLeavePictureInPicture_(e){this.isInPictureInPicture(!1)}handleTechError_(){const e=this.tech_.error();e&&this.error(e)}handleTechTextData_(){let e=null;arguments.length>1&&(e=arguments[1]),this.trigger("textdata",e)}getCache(){return this.cache_}resetCache_(){this.cache_={currentTime:0,initTime:0,inactivityTimeout:this.options_.inactivityTimeout,duration:NaN,lastVolume:1,lastPlaybackRate:this.defaultPlaybackRate(),media:null,src:"",source:{},sources:[],playbackRates:[],volume:1}}techCall_(e,t){this.ready(function(){if(e in cte)return lte(this.middleware_,this.tech_,e,t);if(e in zI)return VI(this.middleware_,this.tech_,e,t);try{this.tech_&&this.tech_[e](t)}catch(i){throw pt(i),i}},!0)}techGet_(e){if(!(!this.tech_||!this.tech_.isReady_)){if(e in ute)return ote(this.middleware_,this.tech_,e);if(e in zI)return VI(this.middleware_,this.tech_,e);try{return this.tech_[e]()}catch(t){throw this.tech_[e]===void 0?(pt(`Video.js: ${e} method not defined for ${this.techName_} playback technology.`,t),t):t.name==="TypeError"?(pt(`Video.js: ${e} unavailable on ${this.techName_} playback technology element.`,t),this.tech_.isReady_=!1,t):(pt(t),t)}}}play(){return new Promise(e=>{this.play_(e)})}play_(e=Va){this.playCallbacks_.push(e);const t=!!(!this.changingSrc_&&(this.src()||this.currentSrc())),i=!!(k_||xi);if(this.waitToPlay_&&(this.off(["ready","loadstart"],this.waitToPlay_),this.waitToPlay_=null),!this.isReady_||!t){this.waitToPlay_=s=>{this.play_()},this.one(["ready","loadstart"],this.waitToPlay_),!t&&i&&this.load();return}const n=this.techGet_("play");i&&this.hasClass("vjs-ended")&&this.resetProgressBar_(),n===null?this.runPlayTerminatedQueue_():this.runPlayCallbacks_(n)}runPlayTerminatedQueue_(){const e=this.playTerminatedQueue_.slice(0);this.playTerminatedQueue_=[],e.forEach(function(t){t()})}runPlayCallbacks_(e){const t=this.playCallbacks_.slice(0);this.playCallbacks_=[],this.playTerminatedQueue_=[],t.forEach(function(i){i(e)})}pause(){this.techCall_("pause")}paused(){return this.techGet_("paused")!==!1}played(){return this.techGet_("played")||pa(0,0)}scrubbing(e){if(typeof e>"u")return this.scrubbing_;this.scrubbing_=!!e,this.techCall_("setScrubbing",this.scrubbing_),e?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing")}currentTime(e){if(e===void 0)return this.cache_.currentTime=this.techGet_("currentTime")||0,this.cache_.currentTime;if(e<0&&(e=0),!this.isReady_||this.changingSrc_||!this.tech_||!this.tech_.isReady_){this.cache_.initTime=e,this.off("canplay",this.boundApplyInitTime_),this.one("canplay",this.boundApplyInitTime_);return}this.techCall_("setCurrentTime",e),this.cache_.initTime=0,isFinite(e)&&(this.cache_.currentTime=Number(e))}applyInitTime_(){this.currentTime(this.cache_.initTime)}duration(e){if(e===void 0)return this.cache_.duration!==void 0?this.cache_.duration:NaN;e=parseFloat(e),e<0&&(e=1/0),e!==this.cache_.duration&&(this.cache_.duration=e,e===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),isNaN(e)||this.trigger("durationchange"))}remainingTime(){return this.duration()-this.currentTime()}remainingTimeDisplay(){return Math.floor(this.duration())-Math.floor(this.currentTime())}buffered(){let e=this.techGet_("buffered");return(!e||!e.length)&&(e=pa(0,0)),e}seekable(){let e=this.techGet_("seekable");return(!e||!e.length)&&(e=pa(0,0)),e}seeking(){return this.techGet_("seeking")}ended(){return this.techGet_("ended")}networkState(){return this.techGet_("networkState")}readyState(){return this.techGet_("readyState")}bufferedPercent(){return b7(this.buffered(),this.duration())}bufferedEnd(){const e=this.buffered(),t=this.duration();let i=e.end(e.length-1);return i>t&&(i=t),i}volume(e){let t;if(e!==void 0){t=Math.max(0,Math.min(1,e)),this.cache_.volume=t,this.techCall_("setVolume",t),t>0&&this.lastVolume_(t);return}return t=parseFloat(this.techGet_("volume")),isNaN(t)?1:t}muted(e){if(e!==void 0){this.techCall_("setMuted",e);return}return this.techGet_("muted")||!1}defaultMuted(e){return e!==void 0&&this.techCall_("setDefaultMuted",e),this.techGet_("defaultMuted")||!1}lastVolume_(e){if(e!==void 0&&e!==0){this.cache_.lastVolume=e;return}return this.cache_.lastVolume}supportsFullScreen(){return this.techGet_("supportsFullScreen")||!1}isFullscreen(e){if(e!==void 0){const t=this.isFullscreen_;this.isFullscreen_=!!e,this.isFullscreen_!==t&&this.fsApi_.prefixed&&this.trigger("fullscreenchange"),this.toggleFullscreenClass_();return}return this.isFullscreen_}requestFullscreen(e){this.isInPictureInPicture()&&this.exitPictureInPicture();const t=this;return new Promise((i,n)=>{function a(){t.off("fullscreenerror",o),t.off("fullscreenchange",s)}function s(){a(),i()}function o(u,c){a(),n(c)}t.one("fullscreenchange",s),t.one("fullscreenerror",o);const l=t.requestFullscreenHelper_(e);l&&(l.then(a,a),l.then(i,n))})}requestFullscreenHelper_(e){let t;if(this.fsApi_.prefixed||(t=this.options_.fullscreen&&this.options_.fullscreen.options||{},e!==void 0&&(t=e)),this.fsApi_.requestFullscreen){const i=this.el_[this.fsApi_.requestFullscreen](t);return i&&i.then(()=>this.isFullscreen(!0),()=>this.isFullscreen(!1)),i}else this.tech_.supportsFullScreen()&&!this.options_.preferFullWindow?this.techCall_("enterFullScreen"):this.enterFullWindow()}exitFullscreen(){const e=this;return new Promise((t,i)=>{function n(){e.off("fullscreenerror",s),e.off("fullscreenchange",a)}function a(){n(),t()}function s(l,u){n(),i(u)}e.one("fullscreenchange",a),e.one("fullscreenerror",s);const o=e.exitFullscreenHelper_();o&&(o.then(n,n),o.then(t,i))})}exitFullscreenHelper_(){if(this.fsApi_.requestFullscreen){const e=de[this.fsApi_.exitFullscreen]();return e&&Va(e.then(()=>this.isFullscreen(!1))),e}else this.tech_.supportsFullScreen()&&!this.options_.preferFullWindow?this.techCall_("exitFullScreen"):this.exitFullWindow()}enterFullWindow(){this.isFullscreen(!0),this.isFullWindow=!0,this.docOrigOverflow=de.documentElement.style.overflow,yn(de,"keydown",this.boundFullWindowOnEscKey_),de.documentElement.style.overflow="hidden",Au(de.body,"vjs-full-window"),this.trigger("enterFullWindow")}fullWindowOnEscKey(e){e.key==="Escape"&&this.isFullscreen()===!0&&(this.isFullWindow?this.exitFullWindow():this.exitFullscreen())}exitFullWindow(){this.isFullscreen(!1),this.isFullWindow=!1,ni(de,"keydown",this.boundFullWindowOnEscKey_),de.documentElement.style.overflow=this.docOrigOverflow,R_(de.body,"vjs-full-window"),this.trigger("exitFullWindow")}disablePictureInPicture(e){if(e===void 0)return this.techGet_("disablePictureInPicture");this.techCall_("setDisablePictureInPicture",e),this.options_.disablePictureInPicture=e,this.trigger("disablepictureinpicturechanged")}isInPictureInPicture(e){if(e!==void 0){this.isInPictureInPicture_=!!e,this.togglePictureInPictureClass_();return}return!!this.isInPictureInPicture_}requestPictureInPicture(){if(this.options_.enableDocumentPictureInPicture&&H.documentPictureInPicture){const e=de.createElement(this.el().tagName);return e.classList=this.el().classList,e.classList.add("vjs-pip-container"),this.posterImage&&e.appendChild(this.posterImage.el().cloneNode(!0)),this.titleBar&&e.appendChild(this.titleBar.el().cloneNode(!0)),e.appendChild(Ke("p",{className:"vjs-pip-text"},{},this.localize("Playing in picture-in-picture"))),H.documentPictureInPicture.requestWindow({width:this.videoWidth(),height:this.videoHeight()}).then(t=>(o7(t),this.el_.parentNode.insertBefore(e,this.el_),t.document.body.appendChild(this.el_),t.document.body.classList.add("vjs-pip-window"),this.player_.isInPictureInPicture(!0),this.player_.trigger({type:"enterpictureinpicture",pipWindow:t}),t.addEventListener("pagehide",i=>{const n=i.target.querySelector(".video-js");e.parentNode.replaceChild(n,e),this.player_.isInPictureInPicture(!1),this.player_.trigger("leavepictureinpicture")}),t))}return"pictureInPictureEnabled"in de&&this.disablePictureInPicture()===!1?this.techGet_("requestPictureInPicture"):Promise.reject("No PiP mode is available")}exitPictureInPicture(){if(H.documentPictureInPicture&&H.documentPictureInPicture.window)return H.documentPictureInPicture.window.close(),Promise.resolve();if("pictureInPictureEnabled"in de)return de.exitPictureInPicture()}handleKeyDown(e){const{userActions:t}=this.options_;!t||!t.hotkeys||(n=>{const a=n.tagName.toLowerCase();if(n.isContentEditable)return!0;const s=["button","checkbox","hidden","radio","reset","submit"];return a==="input"?s.indexOf(n.type)===-1:["textarea"].indexOf(a)!==-1})(this.el_.ownerDocument.activeElement)||(typeof t.hotkeys=="function"?t.hotkeys.call(this,e):this.handleHotkeys(e))}handleHotkeys(e){const t=this.options_.userActions?this.options_.userActions.hotkeys:{},{fullscreenKey:i=s=>e.key.toLowerCase()==="f",muteKey:n=s=>e.key.toLowerCase()==="m",playPauseKey:a=s=>e.key.toLowerCase()==="k"||e.key.toLowerCase()===" "}=t;if(i.call(this,e)){e.preventDefault(),e.stopPropagation();const s=ae.getComponent("FullscreenToggle");de[this.fsApi_.fullscreenEnabled]!==!1&&s.prototype.handleClick.call(this,e)}else n.call(this,e)?(e.preventDefault(),e.stopPropagation(),ae.getComponent("MuteToggle").prototype.handleClick.call(this,e)):a.call(this,e)&&(e.preventDefault(),e.stopPropagation(),ae.getComponent("PlayToggle").prototype.handleClick.call(this,e))}canPlayType(e){let t;for(let i=0,n=this.options_.techOrder;i[o,it.getTech(o)]).filter(([o,l])=>l?l.isSupported():(pt.error(`The "${o}" tech is undefined. Skipped browser support check for that tech.`),!1)),i=function(o,l,u){let c;return o.some(h=>l.some(d=>{if(c=u(h,d),c)return!0})),c};let n;const a=o=>(l,u)=>o(u,l),s=([o,l],u)=>{if(l.canPlaySource(u,this.options_[o.toLowerCase()]))return{source:u,tech:o}};return this.options_.sourceOrder?n=i(e,t,a(s)):n=i(t,e,s),n||!1}handleSrc_(e,t){if(typeof e>"u")return this.cache_.src||"";this.resetRetryOnError_&&this.resetRetryOnError_();const i=C7(e);if(!i.length){this.setTimeout(function(){this.error({code:4,message:this.options_.notSupportedMessage})},0);return}if(this.changingSrc_=!0,t||(this.cache_.sources=i),this.updateSourceCaches_(i[0]),ate(this,i[0],(n,a)=>{if(this.middleware_=a,t||(this.cache_.sources=i),this.updateSourceCaches_(n),this.src_(n)){if(i.length>1)return this.handleSrc_(i.slice(1));this.changingSrc_=!1,this.setTimeout(function(){this.error({code:4,message:this.options_.notSupportedMessage})},0),this.triggerReady();return}ste(a,this.tech_)}),i.length>1){const n=()=>{this.error(null),this.handleSrc_(i.slice(1),!0)},a=()=>{this.off("error",n)};this.one("error",n),this.one("playing",a),this.resetRetryOnError_=()=>{this.off("error",n),this.off("playing",a)}}}src(e){return this.handleSrc_(e,!1)}src_(e){const t=this.selectSource([e]);return t?g7(t.tech,this.techName_)?(this.ready(function(){this.tech_.constructor.prototype.hasOwnProperty("setSource")?this.techCall_("setSource",e):this.techCall_("src",e.src),this.changingSrc_=!1},!0),!1):(this.changingSrc_=!0,this.loadTech_(t.tech,t.source),this.tech_.ready(()=>{this.changingSrc_=!1}),!1):!0}load(){if(this.tech_&&this.tech_.vhs){this.src(this.currentSource());return}this.techCall_("load")}reset(){if(this.paused())this.doReset_();else{const e=this.play();Va(e.then(()=>this.doReset_()))}}doReset_(){this.tech_&&this.tech_.clearTracks("text"),this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.resetCache_(),this.poster(""),this.loadTech_(this.options_.techOrder[0],null),this.techCall_("reset"),this.resetControlBarUI_(),this.error(null),this.titleBar&&this.titleBar.update({title:void 0,description:void 0}),Ls(this)&&this.trigger("playerreset")}resetControlBarUI_(){this.resetProgressBar_(),this.resetPlaybackRate_(),this.resetVolumeBar_()}resetProgressBar_(){this.currentTime(0);const{currentTimeDisplay:e,durationDisplay:t,progressControl:i,remainingTimeDisplay:n}=this.controlBar||{},{seekBar:a}=i||{};e&&e.updateContent(),t&&t.updateContent(),n&&n.updateContent(),a&&(a.update(),a.loadProgressBar&&a.loadProgressBar.update())}resetPlaybackRate_(){this.playbackRate(this.defaultPlaybackRate()),this.handleTechRateChange_()}resetVolumeBar_(){this.volume(1),this.trigger("volumechange")}currentSources(){const e=this.currentSource(),t=[];return Object.keys(e).length!==0&&t.push(e),this.cache_.sources||t}currentSource(){return this.cache_.source||{}}currentSrc(){return this.currentSource()&&this.currentSource().src||""}currentType(){return this.currentSource()&&this.currentSource().type||""}preload(e){if(e!==void 0){this.techCall_("setPreload",e),this.options_.preload=e;return}return this.techGet_("preload")}autoplay(e){if(e===void 0)return this.options_.autoplay||!1;let t;typeof e=="string"&&/(any|play|muted)/.test(e)||e===!0&&this.options_.normalizeAutoplay?(this.options_.autoplay=e,this.manualAutoplay_(typeof e=="string"?e:"play"),t=!1):e?this.options_.autoplay=!0:this.options_.autoplay=!1,t=typeof t>"u"?this.options_.autoplay:t,this.tech_&&this.techCall_("setAutoplay",t)}playsinline(e){return e!==void 0&&(this.techCall_("setPlaysinline",e),this.options_.playsinline=e),this.techGet_("playsinline")}loop(e){if(e!==void 0){this.techCall_("setLoop",e),this.options_.loop=e;return}return this.techGet_("loop")}poster(e){if(e===void 0)return this.poster_;e||(e=""),e!==this.poster_&&(this.poster_=e,this.techCall_("setPoster",e),this.isPosterFromTech_=!1,this.trigger("posterchange"))}handleTechPosterChange_(){if((!this.poster_||this.options_.techCanOverridePoster)&&this.tech_&&this.tech_.poster){const e=this.tech_.poster()||"";e!==this.poster_&&(this.poster_=e,this.isPosterFromTech_=!0,this.trigger("posterchange"))}}controls(e){if(e===void 0)return!!this.controls_;e=!!e,this.controls_!==e&&(this.controls_=e,this.usingNativeControls()&&this.techCall_("setControls",e),this.controls_?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.addTechControlsListeners_()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.removeTechControlsListeners_()))}usingNativeControls(e){if(e===void 0)return!!this.usingNativeControls_;e=!!e,this.usingNativeControls_!==e&&(this.usingNativeControls_=e,this.usingNativeControls_?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols")))}error(e){if(e===void 0)return this.error_||null;if(Yo("beforeerror").forEach(t=>{const i=t(this,e);if(!(es(i)&&!Array.isArray(i)||typeof i=="string"||typeof i=="number"||i===null)){this.log.error("please return a value that MediaError expects in beforeerror hooks");return}e=i}),this.options_.suppressNotSupportedError&&e&&e.code===4){const t=function(){this.error(e)};this.options_.suppressNotSupportedError=!1,this.any(["click","touchstart"],t),this.one("loadstart",function(){this.off(["click","touchstart"],t)});return}if(e===null){this.error_=null,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close();return}this.error_=new tr(e),this.addClass("vjs-error"),pt.error(`(CODE:${this.error_.code} ${tr.errorTypes[this.error_.code]})`,this.error_.message,this.error_),this.trigger("error"),Yo("error").forEach(t=>t(this,this.error_))}reportUserActivity(e){this.userActivity_=!0}userActive(e){if(e===void 0)return this.userActive_;if(e=!!e,e!==this.userActive_){if(this.userActive_=e,this.userActive_){this.userActivity_=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive");return}this.tech_&&this.tech_.one("mousemove",function(t){t.stopPropagation(),t.preventDefault()}),this.userActivity_=!1,this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive")}}listenForUserActivity_(){let e,t,i;const n=Ht(this,this.reportUserActivity),a=function(h){(h.screenX!==t||h.screenY!==i)&&(t=h.screenX,i=h.screenY,n())},s=function(){n(),this.clearInterval(e),e=this.setInterval(n,250)},o=function(h){n(),this.clearInterval(e)};this.on("mousedown",s),this.on("mousemove",a),this.on("mouseup",o),this.on("mouseleave",o);const l=this.getChild("controlBar");l&&!xi&&!ts&&(l.on("mouseenter",function(h){this.player().options_.inactivityTimeout!==0&&(this.player().cache_.inactivityTimeout=this.player().options_.inactivityTimeout),this.player().options_.inactivityTimeout=0}),l.on("mouseleave",function(h){this.player().options_.inactivityTimeout=this.player().cache_.inactivityTimeout})),this.on("keydown",n),this.on("keyup",n);let u;const c=function(){if(!this.userActivity_)return;this.userActivity_=!1,this.userActive(!0),this.clearTimeout(u);const h=this.options_.inactivityTimeout;h<=0||(u=this.setTimeout(function(){this.userActivity_||this.userActive(!1)},h))};this.setInterval(c,250)}playbackRate(e){if(e!==void 0){this.techCall_("setPlaybackRate",e);return}return this.tech_&&this.tech_.featuresPlaybackRate?this.cache_.lastPlaybackRate||this.techGet_("playbackRate"):1}defaultPlaybackRate(e){return e!==void 0?this.techCall_("setDefaultPlaybackRate",e):this.tech_&&this.tech_.featuresPlaybackRate?this.techGet_("defaultPlaybackRate"):1}isAudio(e){if(e!==void 0){this.isAudio_=!!e;return}return!!this.isAudio_}updatePlayerHeightOnAudioOnlyMode_(){const e=this.getChild("ControlBar");!e||this.audioOnlyCache_.controlBarHeight===e.currentHeight()||(this.audioOnlyCache_.controlBarHeight=e.currentHeight(),this.height(this.audioOnlyCache_.controlBarHeight))}enableAudioOnlyUI_(){this.addClass("vjs-audio-only-mode");const e=this.children(),t=this.getChild("ControlBar"),i=t&&t.currentHeight();e.forEach(n=>{n!==t&&n.el_&&!n.hasClass("vjs-hidden")&&(n.hide(),this.audioOnlyCache_.hiddenChildren.push(n))}),this.audioOnlyCache_.playerHeight=this.currentHeight(),this.audioOnlyCache_.controlBarHeight=i,this.on("playerresize",this.boundUpdatePlayerHeightOnAudioOnlyMode_),this.height(i),this.trigger("audioonlymodechange")}disableAudioOnlyUI_(){this.removeClass("vjs-audio-only-mode"),this.off("playerresize",this.boundUpdatePlayerHeightOnAudioOnlyMode_),this.audioOnlyCache_.hiddenChildren.forEach(e=>e.show()),this.height(this.audioOnlyCache_.playerHeight),this.trigger("audioonlymodechange")}audioOnlyMode(e){if(typeof e!="boolean"||e===this.audioOnlyMode_)return this.audioOnlyMode_;if(this.audioOnlyMode_=e,e){const t=[];return this.isInPictureInPicture()&&t.push(this.exitPictureInPicture()),this.isFullscreen()&&t.push(this.exitFullscreen()),this.audioPosterMode()&&t.push(this.audioPosterMode(!1)),Promise.all(t).then(()=>this.enableAudioOnlyUI_())}return Promise.resolve().then(()=>this.disableAudioOnlyUI_())}enablePosterModeUI_(){(this.tech_&&this.tech_).hide(),this.addClass("vjs-audio-poster-mode"),this.trigger("audiopostermodechange")}disablePosterModeUI_(){(this.tech_&&this.tech_).show(),this.removeClass("vjs-audio-poster-mode"),this.trigger("audiopostermodechange")}audioPosterMode(e){return typeof e!="boolean"||e===this.audioPosterMode_?this.audioPosterMode_:(this.audioPosterMode_=e,e?this.audioOnlyMode()?this.audioOnlyMode(!1).then(()=>{this.enablePosterModeUI_()}):Promise.resolve().then(()=>{this.enablePosterModeUI_()}):Promise.resolve().then(()=>{this.disablePosterModeUI_()}))}addTextTrack(e,t,i){if(this.tech_)return this.tech_.addTextTrack(e,t,i)}addRemoteTextTrack(e,t){if(this.tech_)return this.tech_.addRemoteTextTrack(e,t)}removeRemoteTextTrack(e={}){let{track:t}=e;if(t||(t=e),this.tech_)return this.tech_.removeRemoteTextTrack(t)}getVideoPlaybackQuality(){return this.techGet_("getVideoPlaybackQuality")}videoWidth(){return this.tech_&&this.tech_.videoWidth&&this.tech_.videoWidth()||0}videoHeight(){return this.tech_&&this.tech_.videoHeight&&this.tech_.videoHeight()||0}language(e){if(e===void 0)return this.language_;this.language_!==String(e).toLowerCase()&&(this.language_=String(e).toLowerCase(),Ls(this)&&this.trigger("languagechange"))}languages(){return Ut(rh.prototype.options_.languages,this.languages_)}toJSON(){const e=Ut(this.options_),t=e.tracks;e.tracks=[];for(let i=0;i{this.removeChild(i)}),i.open(),i}updateCurrentBreakpoint_(){if(!this.responsive())return;const e=this.currentBreakpoint(),t=this.currentWidth();for(let i=0;ithis.addRemoteTextTrack(h,!1)),this.titleBar&&this.titleBar.update({title:c,description:s||n||""}),this.ready(t)}getMedia(){if(!this.cache_.media){const e=this.poster(),t=this.currentSources(),i=Array.prototype.map.call(this.remoteTextTracks(),a=>({kind:a.kind,label:a.label,language:a.language,src:a.src})),n={src:t,textTracks:i};return e&&(n.poster=e,n.artwork=[{src:n.poster,type:J0(n.poster)}]),n}return Ut(this.cache_.media)}static getTagSettings(e){const t={sources:[],tracks:[]},i=Co(e),n=i["data-setup"];if(vp(e,"vjs-fill")&&(i.fill=!0),vp(e,"vjs-fluid")&&(i.fluid=!0),n!==null)try{Object.assign(i,JSON.parse(n||"{}"))}catch(a){pt.error("data-setup",a)}if(Object.assign(t,i),e.hasChildNodes()){const a=e.childNodes;for(let s=0,o=a.length;stypeof t=="number")&&(this.cache_.playbackRates=e,this.trigger("playbackrateschange"))}};_i.names.forEach(function(r){const e=_i[r];Lr.prototype[e.getterName]=function(){return this.tech_?this.tech_[e.getterName]():(this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName])}});Lr.prototype.crossorigin=Lr.prototype.crossOrigin;Lr.players={};const ud=H.navigator;Lr.prototype.options_={techOrder:it.defaultTechOrder_,html5:{},enableSourceset:!0,inactivityTimeout:2e3,playbackRates:[],liveui:!1,children:["mediaLoader","posterImage","titleBar","textTrackDisplay","loadingSpinner","bigPlayButton","liveTracker","controlBar","errorDisplay","textTrackSettings","resizeManager"],language:ud&&(ud.languages&&ud.languages[0]||ud.userLanguage||ud.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",normalizeAutoplay:!1,fullscreen:{options:{navigationUI:"hide"}},breakpoints:{},responsive:!1,audioOnlyMode:!1,audioPosterMode:!1,spatialNavigation:{enabled:!1,horizontalSeek:!1},enableSmoothSeeking:!1};t9.forEach(function(r){Lr.prototype[`handleTech${nr(r)}_`]=function(){return this.trigger(r)}});ae.registerComponent("Player",Lr);const ey="plugin",xh="activePlugins_",ch={},ty=r=>ch.hasOwnProperty(r),s0=r=>ty(r)?ch[r]:void 0,r9=(r,e)=>{r[xh]=r[xh]||{},r[xh][e]=!0},ry=(r,e,t)=>{const i=(t?"before":"")+"pluginsetup";r.trigger(i,e),r.trigger(i+":"+e.name,e)},Xte=function(r,e){const t=function(){ry(this,{name:r,plugin:e,instance:null},!0);const i=e.apply(this,arguments);return r9(this,r),ry(this,{name:r,plugin:e,instance:i}),i};return Object.keys(e).forEach(function(i){t[i]=e[i]}),t},n4=(r,e)=>(e.prototype.name=r,function(...t){ry(this,{name:r,plugin:e,instance:null},!0);const i=new e(this,...t);return this[r]=()=>i,ry(this,i.getEventHash()),i});class $i{constructor(e){if(this.constructor===$i)throw new Error("Plugin must be sub-classed; not directly instantiated.");this.player=e,this.log||(this.log=this.player.log.createLogger(this.name)),WC(this),delete this.trigger,v7(this,this.constructor.defaultState),r9(e,this.name),this.dispose=this.dispose.bind(this),e.on("dispose",this.dispose)}version(){return this.constructor.VERSION}getEventHash(e={}){return e.name=this.name,e.plugin=this.constructor,e.instance=this,e}trigger(e,t={}){return Tf(this.eventBusEl_,e,this.getEventHash(t))}handleStateChanged(e){}dispose(){const{name:e,player:t}=this;this.trigger("dispose"),this.off(),t.off("dispose",this.dispose),t[xh][e]=!1,this.player=this.state=null,t[e]=n4(e,ch[e])}static isBasic(e){const t=typeof e=="string"?s0(e):e;return typeof t=="function"&&!$i.prototype.isPrototypeOf(t.prototype)}static registerPlugin(e,t){if(typeof e!="string")throw new Error(`Illegal plugin name, "${e}", must be a string, was ${typeof e}.`);if(ty(e))pt.warn(`A plugin named "${e}" already exists. You may want to avoid re-registering plugins!`);else if(Lr.prototype.hasOwnProperty(e))throw new Error(`Illegal plugin name, "${e}", cannot share a name with an existing player method!`);if(typeof t!="function")throw new Error(`Illegal plugin for "${e}", must be a function, was ${typeof t}.`);return ch[e]=t,e!==ey&&($i.isBasic(t)?Lr.prototype[e]=Xte(e,t):Lr.prototype[e]=n4(e,t)),t}static deregisterPlugin(e){if(e===ey)throw new Error("Cannot de-register base plugin.");ty(e)&&(delete ch[e],delete Lr.prototype[e])}static getPlugins(e=Object.keys(ch)){let t;return e.forEach(i=>{const n=s0(i);n&&(t=t||{},t[i]=n)}),t}static getPluginVersion(e){const t=s0(e);return t&&t.VERSION||""}}$i.getPlugin=s0;$i.BASE_PLUGIN_NAME=ey;$i.registerPlugin(ey,$i);Lr.prototype.usingPlugin=function(r){return!!this[xh]&&this[xh][r]===!0};Lr.prototype.hasPlugin=function(r){return!!ty(r)};function Yte(r,e){let t=!1;return function(...i){return t||pt.warn(r),t=!0,e.apply(this,i)}}function Sa(r,e,t,i){return Yte(`${e} is deprecated and will be removed in ${r}.0; please use ${t} instead.`,i)}var Kte={NetworkBadStatus:"networkbadstatus",NetworkRequestFailed:"networkrequestfailed",NetworkRequestAborted:"networkrequestaborted",NetworkRequestTimeout:"networkrequesttimeout",NetworkBodyParserFailed:"networkbodyparserfailed",StreamingHlsPlaylistParserError:"streaminghlsplaylistparsererror",StreamingDashManifestParserError:"streamingdashmanifestparsererror",StreamingContentSteeringParserError:"streamingcontentsteeringparsererror",StreamingVttParserError:"streamingvttparsererror",StreamingFailedToSelectNextSegment:"streamingfailedtoselectnextsegment",StreamingFailedToDecryptSegment:"streamingfailedtodecryptsegment",StreamingFailedToTransmuxSegment:"streamingfailedtotransmuxsegment",StreamingFailedToAppendSegment:"streamingfailedtoappendsegment",StreamingCodecsChangeError:"streamingcodecschangeerror"};const i9=r=>r.indexOf("#")===0?r.slice(1):r;function K(r,e,t){let i=K.getPlayer(r);if(i)return e&&pt.warn(`Player "${r}" is already initialised. Options will not be applied.`),t&&i.ready(t),i;const n=typeof r=="string"?Ko("#"+i9(r)):r;if(!Sf(n))throw new TypeError("The element or ID supplied is not valid. (videojs)");const s=("getRootNode"in n?n.getRootNode()instanceof H.ShadowRoot:!1)?n.getRootNode():n.ownerDocument.body;(!n.ownerDocument.defaultView||!s.contains(n))&&pt.warn("The element supplied is not included in the DOM"),e=e||{},e.restoreEl===!0&&(e.restoreEl=(n.parentNode&&n.parentNode.hasAttribute&&n.parentNode.hasAttribute("data-vjs-player")?n.parentNode:n).cloneNode(!0)),Yo("beforesetup").forEach(l=>{const u=l(n,Ut(e));if(!es(u)||Array.isArray(u)){pt.error("please return an object in beforesetup hooks");return}e=Ut(e,u)});const o=ae.getComponent("Player");return i=new o(n,e,t),Yo("setup").forEach(l=>l(i)),i}K.hooks_=Cs;K.hooks=Yo;K.hook=Eee;K.hookOnce=Iee;K.removeHook=VO;if(H.VIDEOJS_NO_DYNAMIC_STYLE!==!0&&bf()){let r=Ko(".vjs-styles-defaults");if(!r){r=c7("vjs-styles-defaults");const e=Ko("head");e&&e.insertBefore(r,e.firstChild),h7(r,` + .video-js { + width: 300px; + height: 150px; + } + + .vjs-fluid:not(.vjs-audio-only-mode) { + padding-top: 56.25% + } + `)}}LT(1,K);K.VERSION=ET;K.options=Lr.prototype.options_;K.getPlayers=()=>Lr.players;K.getPlayer=r=>{const e=Lr.players;let t;if(typeof r=="string"){const i=i9(r),n=e[i];if(n)return n;t=Ko("#"+i)}else t=r;if(Sf(t)){const{player:i,playerId:n}=t;if(i||e[n])return i||e[n]}};K.getAllPlayers=()=>Object.keys(Lr.players).map(r=>Lr.players[r]).filter(Boolean);K.players=Lr.players;K.getComponent=ae.getComponent;K.registerComponent=(r,e)=>(it.isTech(e)&&pt.warn(`The ${r} tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)`),ae.registerComponent.call(ae,r,e));K.getTech=it.getTech;K.registerTech=it.registerTech;K.use=nte;Object.defineProperty(K,"middleware",{value:{},writeable:!1,enumerable:!0});Object.defineProperty(K.middleware,"TERMINATOR",{value:Q0,writeable:!1,enumerable:!0});K.browser=YO;K.obj=Lee;K.mergeOptions=Sa(9,"videojs.mergeOptions","videojs.obj.merge",Ut);K.defineLazyProperty=Sa(9,"videojs.defineLazyProperty","videojs.obj.defineLazyProperty",I_);K.bind=Sa(9,"videojs.bind","native Function.prototype.bind",Ht);K.registerPlugin=$i.registerPlugin;K.deregisterPlugin=$i.deregisterPlugin;K.plugin=(r,e)=>(pt.warn("videojs.plugin() is deprecated; use videojs.registerPlugin() instead"),$i.registerPlugin(r,e));K.getPlugins=$i.getPlugins;K.getPlugin=$i.getPlugin;K.getPluginVersion=$i.getPluginVersion;K.addLanguage=function(r,e){return r=(""+r).toLowerCase(),K.options.languages=Ut(K.options.languages,{[r]:e}),K.options.languages[r]};K.log=pt;K.createLogger=zO;K.time=jee;K.createTimeRange=Sa(9,"videojs.createTimeRange","videojs.time.createTimeRanges",pa);K.createTimeRanges=Sa(9,"videojs.createTimeRanges","videojs.time.createTimeRanges",pa);K.formatTime=Sa(9,"videojs.formatTime","videojs.time.formatTime",Xu);K.setFormatTime=Sa(9,"videojs.setFormatTime","videojs.time.setFormatTime",y7);K.resetFormatTime=Sa(9,"videojs.resetFormatTime","videojs.time.resetFormatTime",_7);K.parseUrl=Sa(9,"videojs.parseUrl","videojs.url.parseUrl",XC);K.isCrossOrigin=Sa(9,"videojs.isCrossOrigin","videojs.url.isCrossOrigin",z_);K.EventTarget=_n;K.any=$C;K.on=yn;K.one=U_;K.off=ni;K.trigger=Tf;K.xhr=$6;K.TextTrack=Hv;K.AudioTrack=x7;K.VideoTrack=w7;["isEl","isTextNode","createEl","hasClass","addClass","removeClass","toggleClass","setAttributes","getAttributes","emptyEl","appendContent","insertContent"].forEach(r=>{K[r]=function(){return pt.warn(`videojs.${r}() is deprecated; use videojs.dom.${r}() instead`),l7[r].apply(null,arguments)}});K.computedStyle=Sa(9,"videojs.computedStyle","videojs.dom.computedStyle",Yh);K.dom=l7;K.fn=zee;K.num=Cte;K.str=Wee;K.url=rte;K.Error=Kte;/*! @name videojs-contrib-quality-levels @version 4.1.0 @license Apache-2.0 */class Zte{constructor(e){let t=this;return t.id=e.id,t.label=t.id,t.width=e.width,t.height=e.height,t.bitrate=e.bandwidth,t.frameRate=e.frameRate,t.enabled_=e.enabled,Object.defineProperty(t,"enabled",{get(){return t.enabled_()},set(i){t.enabled_(i)}}),t}}class iy extends K.EventTarget{constructor(){super();let e=this;return e.levels_=[],e.selectedIndex_=-1,Object.defineProperty(e,"selectedIndex",{get(){return e.selectedIndex_}}),Object.defineProperty(e,"length",{get(){return e.levels_.length}}),e[Symbol.iterator]=()=>e.levels_.values(),e}addQualityLevel(e){let t=this.getQualityLevelById(e.id);if(t)return t;const i=this.levels_.length;return t=new Zte(e),""+i in this||Object.defineProperty(this,i,{get(){return this.levels_[i]}}),this.levels_.push(t),this.trigger({qualityLevel:t,type:"addqualitylevel"}),t}removeQualityLevel(e){let t=null;for(let i=0,n=this.length;ii&&this.selectedIndex_--;break}return t&&this.trigger({qualityLevel:e,type:"removequalitylevel"}),t}getQualityLevelById(e){for(let t=0,i=this.length;ti,r.qualityLevels.VERSION=n9,i},a9=function(r){return Qte(this,K.obj.merge({},r))};K.registerPlugin("qualityLevels",a9);a9.VERSION=n9;/*! @name @videojs/http-streaming @version 3.14.2 @license Apache-2.0 */const Ni=T_,ny=(r,e)=>e&&e.responseURL&&r!==e.responseURL?e.responseURL:r,Kn=r=>K.log.debug?K.log.debug.bind(K,"VHS:",`${r} >`):function(){};function It(...r){const e=K.obj||K;return(e.merge||e.mergeOptions).apply(e,r)}function Kr(...r){const e=K.time||K;return(e.createTimeRanges||e.createTimeRanges).apply(e,r)}function Jte(r){if(r.length===0)return"Buffered Ranges are empty";let e=`Buffered Ranges: +`;for(let t=0;t ${n}. Duration (${n-i}) +`}return e}const za=1/30,Ga=za*3,s9=function(r,e){const t=[];let i;if(r&&r.length)for(i=0;i=e})},$g=function(r,e){return s9(r,function(t){return t-za>=e})},ere=function(r){if(r.length<2)return Kr();const e=[];for(let t=1;t{const e=[];if(!r||!r.length)return"";for(let t=0;t "+r.end(t));return e.join(", ")},rre=function(r,e,t=1){return((r.length?r.end(r.length-1):0)-e)/t},pu=r=>{const e=[];for(let t=0;ta)){if(e>n&&e<=a){t+=a-e;continue}t+=a-n}}return t},dA=(r,e)=>{if(!e.preload)return e.duration;let t=0;return(e.parts||[]).forEach(function(i){t+=i.duration}),(e.preloadHints||[]).forEach(function(i){i.type==="PART"&&(t+=r.partTargetDuration)}),t},UT=r=>(r.segments||[]).reduce((e,t,i)=>(t.parts?t.parts.forEach(function(n,a){e.push({duration:n.duration,segmentIndex:i,partIndex:a,part:n,segment:t})}):e.push({duration:t.duration,segmentIndex:i,partIndex:null,segment:t,part:null}),e),[]),l9=r=>{const e=r.segments&&r.segments.length&&r.segments[r.segments.length-1];return e&&e.parts||[]},u9=({preloadSegment:r})=>{if(!r)return;const{parts:e,preloadHints:t}=r;let i=(t||[]).reduce((n,a)=>n+(a.type==="PART"?1:0),0);return i+=e&&e.length?e.length:0,i},c9=(r,e)=>{if(e.endList)return 0;if(r&&r.suggestedPresentationDelay)return r.suggestedPresentationDelay;const t=l9(e).length>0;return t&&e.serverControl&&e.serverControl.partHoldBack?e.serverControl.partHoldBack:t&&e.partTargetDuration?e.partTargetDuration*3:e.serverControl&&e.serverControl.holdBack?e.serverControl.holdBack:e.targetDuration?e.targetDuration*3:0},nre=function(r,e){let t=0,i=e-r.mediaSequence,n=r.segments[i];if(n){if(typeof n.start<"u")return{result:n.start,precise:!0};if(typeof n.end<"u")return{result:n.end-n.duration,precise:!0}}for(;i--;){if(n=r.segments[i],typeof n.end<"u")return{result:t+n.end,precise:!0};if(t+=dA(r,n),typeof n.start<"u")return{result:t+n.start,precise:!0}}return{result:t,precise:!1}},are=function(r,e){let t=0,i,n=e-r.mediaSequence;for(;n"u"&&(e=r.mediaSequence+r.segments.length),e"u"){if(r.totalDuration)return r.totalDuration;if(!r.endList)return H.Infinity}return h9(r,e,t)},yp=function({defaultDuration:r,durationList:e,startIndex:t,endIndex:i}){let n=0;if(t>i&&([t,i]=[i,t]),t<0){for(let a=t;a0)for(let u=l-1;u>=0;u--){const c=o[u];if(s+=c.duration,a){if(s<0)continue}else if(s+za<=0)continue;return{partIndex:c.partIndex,segmentIndex:c.segmentIndex,startTime:n-yp({defaultDuration:r.targetDuration,durationList:o,startIndex:l,endIndex:u})}}return{partIndex:o[0]&&o[0].partIndex||null,segmentIndex:o[0]&&o[0].segmentIndex||0,startTime:e}}if(l<0){for(let u=l;u<0;u++)if(s-=r.targetDuration,s<0)return{partIndex:o[0]&&o[0].partIndex||null,segmentIndex:o[0]&&o[0].segmentIndex||0,startTime:e};l=0}for(let u=l;uza,d=s===0,f=h&&s+za>=0;if(!((d||f)&&u!==o.length-1)){if(a){if(s>0)continue}else if(s-za>=0)continue;return{partIndex:c.partIndex,segmentIndex:c.segmentIndex,startTime:n+yp({defaultDuration:r.targetDuration,durationList:o,startIndex:l,endIndex:u})}}}return{segmentIndex:o[o.length-1].segmentIndex,partIndex:o[o.length-1].partIndex,startTime:e}},p9=function(r){return r.excludeUntil&&r.excludeUntil>Date.now()},pA=function(r){return r.excludeUntil&&r.excludeUntil===1/0},$_=function(r){const e=p9(r);return!r.disabled&&!e},lre=function(r){return r.disabled},ure=function(r){for(let e=0;e{if(r.playlists.length===1)return!0;const t=e.attributes.BANDWIDTH||Number.MAX_VALUE;return r.playlists.filter(i=>$_(i)?(i.attributes.BANDWIDTH||0)!r&&!e||!r&&e||r&&!e?!1:!!(r===e||r.id&&e.id&&r.id===e.id||r.resolvedUri&&e.resolvedUri&&r.resolvedUri===e.resolvedUri||r.uri&&e.uri&&r.uri===e.uri),a4=function(r,e){const t=r&&r.mediaGroups&&r.mediaGroups.AUDIO||{};let i=!1;for(const n in t){for(const a in t[n])if(i=e(t[n][a]),i)break;if(i)break}return!!i},jv=r=>{if(!r||!r.playlists||!r.playlists.length)return a4(r,t=>t.playlists&&t.playlists.length||t.uri);for(let e=0;eK6(a))||a4(r,a=>vA(t,a))))return!1}return!0};var Vi={liveEdgeDelay:c9,duration:f9,seekable:sre,getMediaInfoForTime:ore,isEnabled:$_,isDisabled:lre,isExcluded:p9,isIncompatible:pA,playlistEnd:d9,isAes:ure,hasAttribute:v9,estimateSegmentRequestTime:cre,isLowestEnabledRendition:VT,isAudioOnly:jv,playlistMatch:vA,segmentDurationWithParts:dA};const{log:g9}=K,wh=(r,e)=>`${r}-${e}`,m9=(r,e,t)=>`placeholder-uri-${r}-${e}-${t}`,hre=({onwarn:r,oninfo:e,manifestString:t,customTagParsers:i=[],customTagMappers:n=[],llhls:a})=>{const s=new DQ;r&&s.on("warn",r),e&&s.on("info",e),i.forEach(u=>s.addParser(u)),n.forEach(u=>s.addTagMapper(u)),s.push(t),s.end();const o=s.manifest;if(a||(["preloadSegment","skip","serverControl","renditionReports","partInf","partTargetDuration"].forEach(function(u){o.hasOwnProperty(u)&&delete o[u]}),o.segments&&o.segments.forEach(function(u){["parts","preloadHints"].forEach(function(c){u.hasOwnProperty(c)&&delete u[c]})})),!o.targetDuration){let u=10;o.segments&&o.segments.length&&(u=o.segments.reduce((c,h)=>Math.max(c,h.duration),0)),r&&r({message:`manifest has no targetDuration defaulting to ${u}`}),o.targetDuration=u}const l=l9(o);if(l.length&&!o.partTargetDuration){const u=l.reduce((c,h)=>Math.max(c,h.duration),0);r&&(r({message:`manifest has no partTargetDuration defaulting to ${u}`}),g9.error("LL-HLS manifest has parts but lacks required #EXT-X-PART-INF:PART-TARGET value. See https://datatracker.ietf.org/doc/html/draft-pantos-hls-rfc8216bis-09#section-4.4.3.7. Playback is not guaranteed.")),o.partTargetDuration=u}return o},Af=(r,e)=>{r.mediaGroups&&["AUDIO","SUBTITLES"].forEach(t=>{if(r.mediaGroups[t])for(const i in r.mediaGroups[t])for(const n in r.mediaGroups[t][i]){const a=r.mediaGroups[t][i][n];e(a,t,i,n)}})},y9=({playlist:r,uri:e,id:t})=>{r.id=t,r.playlistErrors_=0,e&&(r.uri=e),r.attributes=r.attributes||{}},fre=r=>{let e=r.playlists.length;for(;e--;){const t=r.playlists[e];y9({playlist:t,id:wh(e,t.uri)}),t.resolvedUri=Ni(r.uri,t.uri),r.playlists[t.id]=t,r.playlists[t.uri]=t,t.attributes.BANDWIDTH||g9.warn("Invalid playlist STREAM-INF detected. Missing BANDWIDTH attribute.")}},dre=r=>{Af(r,e=>{e.uri&&(e.resolvedUri=Ni(r.uri,e.uri))})},pre=(r,e)=>{const t=wh(0,e),i={mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:H.location.href,resolvedUri:H.location.href,playlists:[{uri:e,id:t,resolvedUri:e,attributes:{}}]};return i.playlists[t]=i.playlists[0],i.playlists[e]=i.playlists[0],i},_9=(r,e,t=m9)=>{r.uri=e;for(let n=0;n{if(!n.playlists||!n.playlists.length){if(i&&a==="AUDIO"&&!n.uri)for(let l=0;l(n.set(a.id,a),n),new Map)}processDateRange(e){this.pendingDateRanges_.delete(e.id),this.processedDateRanges_.set(e.id,e)}getDateRangesToProcess(){if(this.offset_===null)return[];const e={},t=[];this.pendingDateRanges_.forEach((i,n)=>{if(!this.processedDateRanges_.has(n)&&(i.startTime=i.startDate.getTime()/1e3-this.offset_,i.processDateRange=()=>this.processDateRange(i),t.push(i),!!i.class))if(e[i.class]){const a=e[i.class].push(i);i.classListIndex=a-1}else e[i.class]=[i],i.classListIndex=0});for(const i of t){const n=e[i.class]||[];i.endDate?i.endTime=i.endDate.getTime()/1e3-this.offset_:i.endOnNext&&n[i.classListIndex+1]?i.endTime=n[i.classListIndex+1].startTime:i.duration?i.endTime=i.startTime+i.duration:i.plannedDuration?i.endTime=i.startTime+i.plannedDuration:i.endTime=i.startTime}return t}trimProcessedDateRanges_(e){new Map(this.processedDateRanges_).forEach((i,n)=>{i.startDate.getTime(){const n=e.status<200||e.status>299,a=e.status>=400&&e.status<=499,s={uri:e.uri,requestType:r},o=n&&!a||i;if(t&&a)s.error=ar({},t),s.errorType=K.Error.NetworkRequestFailed;else if(e.aborted)s.errorType=K.Error.NetworkRequestAborted;else if(e.timedout)s.erroType=K.Error.NetworkRequestTimeout;else if(o){const l=i?K.Error.NetworkBodyParserFailed:K.Error.NetworkBadStatus;s.errorType=l,s.status=e.status,s.headers=e.headers}return s},{EventTarget:vre}=K,gre=(r,e)=>{if(e.endList||!e.serverControl)return r;const t={};if(e.serverControl.canBlockReload){const{preloadSegment:i}=e;let n=e.mediaSequence+e.segments.length;if(i){const a=i.parts||[],s=u9(e)-1;s>-1&&s!==a.length-1&&(t._HLS_part=s),(s>-1||a.length)&&n--}t._HLS_msn=n}if(e.serverControl&&e.serverControl.canSkipUntil&&(t._HLS_skip=e.serverControl.canSkipDateranges?"v2":"YES"),Object.keys(t).length){const i=new H.URL(r);["_HLS_skip","_HLS_msn","_HLS_part"].forEach(function(n){t.hasOwnProperty(n)&&i.searchParams.set(n,t[n])}),r=i.toString()}return r},mre=(r,e)=>{if(!r)return e;const t=It(r,e);if(r.preloadHints&&!e.preloadHints&&delete t.preloadHints,r.parts&&!e.parts)delete t.parts;else if(r.parts&&e.parts)for(let i=0;i{const i=r.slice(),n=e.slice();t=t||0;const a=[];let s;for(let o=0;o{!r.resolvedUri&&r.uri&&(r.resolvedUri=Ni(e,r.uri)),r.key&&!r.key.resolvedUri&&(r.key.resolvedUri=Ni(e,r.key.uri)),r.map&&!r.map.resolvedUri&&(r.map.resolvedUri=Ni(e,r.map.uri)),r.map&&r.map.key&&!r.map.key.resolvedUri&&(r.map.key.resolvedUri=Ni(e,r.map.key.uri)),r.parts&&r.parts.length&&r.parts.forEach(t=>{t.resolvedUri||(t.resolvedUri=Ni(e,t.uri))}),r.preloadHints&&r.preloadHints.length&&r.preloadHints.forEach(t=>{t.resolvedUri||(t.resolvedUri=Ni(e,t.uri))})},T9=function(r){const e=r.segments||[],t=r.preloadSegment;if(t&&t.parts&&t.parts.length){if(t.preloadHints){for(let i=0;ir===e||r.segments&&e.segments&&r.segments.length===e.segments.length&&r.endList===e.endList&&r.mediaSequence===e.mediaSequence&&r.preloadSegment===e.preloadSegment,zT=(r,e,t=x9)=>{const i=It(r,{}),n=i.playlists[e.id];if(!n||t(n,e))return null;e.segments=T9(e);const a=It(n,e);if(a.preloadSegment&&!e.preloadSegment&&delete a.preloadSegment,n.segments){if(e.skip){e.segments=e.segments||[];for(let s=0;s{S9(s,a.resolvedUri)});for(let s=0;s{if(s.playlists)for(let c=0;c{const t=r.segments||[],i=t[t.length-1],n=i&&i.parts&&i.parts[i.parts.length-1],a=n&&n.duration||i&&i.duration;return e&&a?a*1e3:(r.partTargetDuration||r.targetDuration||10)*500},o4=(r,e,t)=>{if(!r)return;const i=[];return r.forEach(n=>{if(!n.attributes)return;const{BANDWIDTH:a,RESOLUTION:s,CODECS:o}=n.attributes;i.push({id:n.id,bandwidth:a,resolution:s,codecs:o})}),{type:e,isLive:t,renditions:i}};class fh extends vre{constructor(e,t,i={}){if(super(),!e)throw new Error("A non-empty playlist URL or object is required");this.logger_=Kn("PlaylistLoader");const{withCredentials:n=!1}=i;this.src=e,this.vhs_=t,this.withCredentials=n,this.addDateRangesToTextTrack_=i.addDateRangesToTextTrack;const a=t.options_;this.customTagParsers=a&&a.customTagParsers||[],this.customTagMappers=a&&a.customTagMappers||[],this.llhls=a&&a.llhls,this.dateRangesStorage_=new s4,this.state="HAVE_NOTHING",this.handleMediaupdatetimeout_=this.handleMediaupdatetimeout_.bind(this),this.on("mediaupdatetimeout",this.handleMediaupdatetimeout_),this.on("loadedplaylist",this.handleLoadedPlaylist_.bind(this))}handleLoadedPlaylist_(){const e=this.media();if(!e)return;this.dateRangesStorage_.setOffset(e.segments),this.dateRangesStorage_.setPendingDateRanges(e.dateRanges);const t=this.dateRangesStorage_.getDateRangesToProcess();!t.length||!this.addDateRangesToTextTrack_||this.addDateRangesToTextTrack_(t)}handleMediaupdatetimeout_(){if(this.state!=="HAVE_METADATA")return;const e=this.media();let t=Ni(this.main.uri,e.uri);this.llhls&&(t=gre(t,e)),this.state="HAVE_CURRENT_METADATA",this.request=this.vhs_.xhr({uri:t,withCredentials:this.withCredentials,requestType:"hls-playlist"},(i,n)=>{if(this.request){if(i)return this.playlistRequestError(this.request,this.media(),"HAVE_METADATA");this.haveMetadata({playlistString:this.request.responseText,url:this.media().uri,id:this.media().id})}})}playlistRequestError(e,t,i){const{uri:n,id:a}=t;this.request=null,i&&(this.state=i),this.error={playlist:this.main.playlists[a],status:e.status,message:`HLS playlist request error at URL: ${n}.`,responseText:e.responseText,code:e.status>=500?4:2,metadata:Iu({requestType:e.requestType,request:e,error:e.error})},this.trigger("error")}parseManifest_({url:e,manifestString:t}){try{return hre({onwarn:({message:i})=>this.logger_(`m3u8-parser warn for ${e}: ${i}`),oninfo:({message:i})=>this.logger_(`m3u8-parser info for ${e}: ${i}`),manifestString:t,customTagParsers:this.customTagParsers,customTagMappers:this.customTagMappers,llhls:this.llhls})}catch(i){this.error=i,this.error.metadata={errorType:K.Error.StreamingHlsPlaylistParserError,error:i}}}haveMetadata({playlistString:e,playlistObject:t,url:i,id:n}){this.request=null,this.state="HAVE_METADATA";const a={playlistInfo:{type:"media",uri:i}};this.trigger({type:"playlistparsestart",metadata:a});const s=t||this.parseManifest_({url:i,manifestString:e});s.lastRequest=Date.now(),y9({playlist:s,uri:i,id:n});const o=zT(this.main,s);this.targetDuration=s.partTargetDuration||s.targetDuration,this.pendingMedia_=null,o?(this.main=o,this.media_=this.main.playlists[n]):this.trigger("playlistunchanged"),this.updateMediaUpdateTimeout_(GT(this.media(),!!o)),a.parsedPlaylist=o4(this.main.playlists,a.playlistInfo.type,!this.media_.endList),this.trigger({type:"playlistparsecomplete",metadata:a}),this.trigger("loadedplaylist")}dispose(){this.trigger("dispose"),this.stopRequest(),H.clearTimeout(this.mediaUpdateTimeout),H.clearTimeout(this.finalRenditionTimeout),this.dateRangesStorage_=new s4,this.off()}stopRequest(){if(this.request){const e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}}media(e,t){if(!e)return this.media_;if(this.state==="HAVE_NOTHING")throw new Error("Cannot switch media playlist from "+this.state);if(typeof e=="string"){if(!this.main.playlists[e])throw new Error("Unknown playlist URI: "+e);e=this.main.playlists[e]}if(H.clearTimeout(this.finalRenditionTimeout),t){const o=(e.partTargetDuration||e.targetDuration)/2*1e3||5e3;this.finalRenditionTimeout=H.setTimeout(this.media.bind(this,e,!1),o);return}const i=this.state,n=!this.media_||e.id!==this.media_.id,a=this.main.playlists[e.id];if(a&&a.endList||e.endList&&e.segments.length){this.request&&(this.request.onreadystatechange=null,this.request.abort(),this.request=null),this.state="HAVE_METADATA",this.media_=e,n&&(this.trigger("mediachanging"),i==="HAVE_MAIN_MANIFEST"?this.trigger("loadedmetadata"):this.trigger("mediachange"));return}if(this.updateMediaUpdateTimeout_(GT(e,!0)),!n)return;if(this.state="SWITCHING_MEDIA",this.request){if(e.resolvedUri===this.request.url)return;this.request.onreadystatechange=null,this.request.abort(),this.request=null}this.media_&&this.trigger("mediachanging"),this.pendingMedia_=e;const s={playlistInfo:{type:"media",uri:e.uri}};this.trigger({type:"playlistrequeststart",metadata:s}),this.request=this.vhs_.xhr({uri:e.resolvedUri,withCredentials:this.withCredentials,requestType:"hls-playlist"},(o,l)=>{if(this.request){if(e.lastRequest=Date.now(),e.resolvedUri=ny(e.resolvedUri,l),o)return this.playlistRequestError(this.request,e,i);this.trigger({type:"playlistrequestcomplete",metadata:s}),this.haveMetadata({playlistString:l.responseText,url:e.uri,id:e.id}),i==="HAVE_MAIN_MANIFEST"?this.trigger("loadedmetadata"):this.trigger("mediachange")}})}pause(){this.mediaUpdateTimeout&&(H.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),this.stopRequest(),this.state==="HAVE_NOTHING"&&(this.started=!1),this.state==="SWITCHING_MEDIA"?this.media_?this.state="HAVE_METADATA":this.state="HAVE_MAIN_MANIFEST":this.state==="HAVE_CURRENT_METADATA"&&(this.state="HAVE_METADATA")}load(e){this.mediaUpdateTimeout&&(H.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null);const t=this.media();if(e){const i=t?(t.partTargetDuration||t.targetDuration)/2*1e3:5e3;this.mediaUpdateTimeout=H.setTimeout(()=>{this.mediaUpdateTimeout=null,this.load()},i);return}if(!this.started){this.start();return}t&&!t.endList?this.trigger("mediaupdatetimeout"):this.trigger("loadedplaylist")}updateMediaUpdateTimeout_(e){this.mediaUpdateTimeout&&(H.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),!(!this.media()||this.media().endList)&&(this.mediaUpdateTimeout=H.setTimeout(()=>{this.mediaUpdateTimeout=null,this.trigger("mediaupdatetimeout"),this.updateMediaUpdateTimeout_(e)},e))}start(){if(this.started=!0,typeof this.src=="object"){this.src.uri||(this.src.uri=H.location.href),this.src.resolvedUri=this.src.uri,setTimeout(()=>{this.setupInitialPlaylist(this.src)},0);return}const e={playlistInfo:{type:"multivariant",uri:this.src}};this.trigger({type:"playlistrequeststart",metadata:e}),this.request=this.vhs_.xhr({uri:this.src,withCredentials:this.withCredentials,requestType:"hls-playlist"},(t,i)=>{if(!this.request)return;if(this.request=null,t)return this.error={status:i.status,message:`HLS playlist request error at URL: ${this.src}.`,responseText:i.responseText,code:2,metadata:Iu({requestType:i.requestType,request:i,error:t})},this.state==="HAVE_NOTHING"&&(this.started=!1),this.trigger("error");this.trigger({type:"playlistrequestcomplete",metadata:e}),this.src=ny(this.src,i),this.trigger({type:"playlistparsestart",metadata:e});const n=this.parseManifest_({manifestString:i.responseText,url:this.src});e.parsedPlaylist=o4(n.playlists,e.playlistInfo.type,!1),this.trigger({type:"playlistparsecomplete",metadata:e}),this.setupInitialPlaylist(n)})}srcUri(){return typeof this.src=="string"?this.src:this.src.uri}setupInitialPlaylist(e){if(this.state="HAVE_MAIN_MANIFEST",e.playlists){this.main=e,_9(this.main,this.srcUri()),e.playlists.forEach(i=>{i.segments=T9(i),i.segments.forEach(n=>{S9(n,i.resolvedUri)})}),this.trigger("loadedplaylist"),this.request||this.media(this.main.playlists[0]);return}const t=this.srcUri()||H.location.href;this.main=pre(e,t),this.haveMetadata({playlistObject:e,url:t,id:this.main.playlists[0].id}),this.trigger("loadedmetadata")}updateOrDeleteClone(e,t){const i=this.main,n=e.ID;let a=i.playlists.length;for(;a--;){const s=i.playlists[a];if(s.attributes["PATHWAY-ID"]===n){const o=s.resolvedUri,l=s.id;if(t){const u=this.createCloneURI_(s.resolvedUri,e),c=wh(n,u),h=this.createCloneAttributes_(n,s.attributes),d=this.createClonePlaylist_(s,c,e,h);i.playlists[a]=d,i.playlists[c]=d,i.playlists[u]=d}else i.playlists.splice(a,1);delete i.playlists[l],delete i.playlists[o]}}this.updateOrDeleteCloneMedia(e,t)}updateOrDeleteCloneMedia(e,t){const i=this.main,n=e.ID;["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(a=>{if(!(!i.mediaGroups[a]||!i.mediaGroups[a][n])){for(const s in i.mediaGroups[a])if(s===n){for(const o in i.mediaGroups[a][s])i.mediaGroups[a][s][o].playlists.forEach((u,c)=>{const h=i.playlists[u.id],d=h.id,f=h.resolvedUri;delete i.playlists[d],delete i.playlists[f]});delete i.mediaGroups[a][s]}}}),t&&this.createClonedMediaGroups_(e)}addClonePathway(e,t={}){const i=this.main,n=i.playlists.length,a=this.createCloneURI_(t.resolvedUri,e),s=wh(e.ID,a),o=this.createCloneAttributes_(e.ID,t.attributes),l=this.createClonePlaylist_(t,s,e,o);i.playlists[n]=l,i.playlists[s]=l,i.playlists[a]=l,this.createClonedMediaGroups_(e)}createClonedMediaGroups_(e){const t=e.ID,i=e["BASE-ID"],n=this.main;["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(a=>{if(!(!n.mediaGroups[a]||n.mediaGroups[a][t]))for(const s in n.mediaGroups[a]){if(s===i)n.mediaGroups[a][t]={};else continue;for(const o in n.mediaGroups[a][s]){const l=n.mediaGroups[a][s][o];n.mediaGroups[a][t][o]=ar({},l);const u=n.mediaGroups[a][t][o],c=this.createCloneURI_(l.resolvedUri,e);u.resolvedUri=c,u.uri=c,u.playlists=[],l.playlists.forEach((h,d)=>{const f=n.playlists[h.id],p=m9(a,t,o),v=wh(t,p);if(f&&!n.playlists[v]){const g=this.createClonePlaylist_(f,v,e),m=g.resolvedUri;n.playlists[v]=g,n.playlists[m]=g}u.playlists[d]=this.createClonePlaylist_(h,v,e)})}}})}createClonePlaylist_(e,t,i,n){const a=this.createCloneURI_(e.resolvedUri,i),s={resolvedUri:a,uri:a,id:t};return e.segments&&(s.segments=[]),n&&(s.attributes=n),It(e,s)}createCloneURI_(e,t){const i=new URL(e);i.hostname=t["URI-REPLACEMENT"].HOST;const n=t["URI-REPLACEMENT"].PARAMS;for(const a of Object.keys(n))i.searchParams.set(a,n[a]);return i.href}createCloneAttributes_(e,t){const i={"PATHWAY-ID":e};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(n=>{t[n]&&(i[n]=e)}),i}getKeyIdSet(e){if(e.contentProtection){const t=new Set;for(const i in e.contentProtection){const n=e.contentProtection[i].attributes.keyId;n&&t.add(n.toLowerCase())}return t}}}const HT=function(r,e,t,i){const n=r.responseType==="arraybuffer"?r.response:r.responseText;!e&&n&&(r.responseTime=Date.now(),r.roundTripTime=r.responseTime-r.requestTime,r.bytesReceived=n.byteLength||n.length,r.bandwidth||(r.bandwidth=Math.floor(r.bytesReceived/r.roundTripTime*8*1e3))),t.headers&&(r.responseHeaders=t.headers),e&&e.code==="ETIMEDOUT"&&(r.timedout=!0),!e&&!r.aborted&&t.statusCode!==200&&t.statusCode!==206&&t.statusCode!==0&&(e=new Error("XHR Failed with a response of: "+(r&&(n||r.responseText)))),i(e,r)},_re=(r,e)=>{if(!r||!r.size)return;let t=e;return r.forEach(i=>{t=i(t)}),t},bre=(r,e,t,i)=>{!r||!r.size||r.forEach(n=>{n(e,t,i)})},w9=function(){const r=function e(t,i){t=It({timeout:45e3},t);const n=e.beforeRequest||K.Vhs.xhr.beforeRequest,a=e._requestCallbackSet||K.Vhs.xhr._requestCallbackSet||new Set,s=e._responseCallbackSet||K.Vhs.xhr._responseCallbackSet;n&&typeof n=="function"&&(K.log.warn("beforeRequest is deprecated, use onRequest instead."),a.add(n));const o=K.Vhs.xhr.original===!0?K.xhr:K.Vhs.xhr,l=_re(a,t);a.delete(n);const u=o(l||t,function(h,d){return bre(s,u,h,d),HT(u,h,d,i)}),c=u.abort;return u.abort=function(){return u.aborted=!0,c.apply(u,arguments)},u.uri=t.uri,u.requestType=t.requestType,u.requestTime=Date.now(),u};return r.original=!0,r},Sre=function(r){let e;const t=r.offset;return typeof r.offset=="bigint"||typeof r.length=="bigint"?e=H.BigInt(r.offset)+H.BigInt(r.length)-H.BigInt(1):e=r.offset+r.length-1,"bytes="+t+"-"+e},$T=function(r){const e={};return r.byterange&&(e.Range=Sre(r.byterange)),e},Tre=function(r,e){return r.start(e)+"-"+r.end(e)},xre=function(r,e){const t=r.toString(16);return"00".substring(0,2-t.length)+t+(e%2?" ":"")},wre=function(r){return r>=32&&r<126?String.fromCharCode(r):"."},C9=function(r){const e={};return Object.keys(r).forEach(t=>{const i=r[t];Q6(i)?e[t]={bytes:i.buffer,byteOffset:i.byteOffset,byteLength:i.byteLength}:e[t]=i}),e},ay=function(r){const e=r.byterange||{length:1/0,offset:0};return[e.length,e.offset,r.resolvedUri].join(",")},A9=function(r){return r.resolvedUri},D9=r=>{const e=Array.prototype.slice.call(r),t=16;let i="",n,a;for(let s=0;sD9(r),Are=r=>{let e="",t;for(t=0;t{if(!e.dateTimeObject)return null;const t=e.videoTimingInfo.transmuxerPrependedSeconds,n=e.videoTimingInfo.transmuxedPresentationStart+t,a=r-n;return new Date(e.dateTimeObject.getTime()+a*1e3)},Ire=r=>r.transmuxedPresentationEnd-r.transmuxedPresentationStart-r.transmuxerPrependedSeconds,Pre=(r,e)=>{let t;try{t=new Date(r)}catch{return null}if(!e||!e.segments||e.segments.length===0)return null;let i=e.segments[0];if(to?null:(t>new Date(a)&&(i=n),{segment:i,estimatedStart:i.videoTimingInfo?i.videoTimingInfo.transmuxedPresentationStart:Vi.duration(e,e.mediaSequence+e.segments.indexOf(i)),type:i.videoTimingInfo?"accurate":"estimate"})},Mre=(r,e)=>{if(!e||!e.segments||e.segments.length===0)return null;let t=0,i;for(let a=0;at){if(r>t+n.duration*E9)return null;i=n}return{segment:i,estimatedStart:i.videoTimingInfo?i.videoTimingInfo.transmuxedPresentationStart:t-i.duration,type:i.videoTimingInfo?"accurate":"estimate"}},Lre=(r,e)=>{let t,i;try{t=new Date(r),i=new Date(e)}catch{}const n=t.getTime();return(i.getTime()-n)/1e3},kre=r=>{if(!r.segments||r.segments.length===0)return!1;for(let e=0;e{if(!t)throw new Error("getProgramTime: callback must be provided");if(!r||e===void 0)return t({message:"getProgramTime: playlist and time must be provided"});const i=Mre(e,r);if(!i)return t({message:"valid programTime was not found"});if(i.type==="estimate")return t({message:"Accurate programTime could not be determined. Please seek to e.seekTime and try again",seekTime:i.estimatedStart});const n={mediaSeconds:e},a=Ere(e,i.segment);return a&&(n.programDateTime=a.toISOString()),t(null,n)},I9=({programTime:r,playlist:e,retryCount:t=2,seekTo:i,pauseAfterSeek:n=!0,tech:a,callback:s})=>{if(!s)throw new Error("seekToProgramTime: callback must be provided");if(typeof r>"u"||!e||!i)return s({message:"seekToProgramTime: programTime, seekTo and playlist must be provided"});if(!e.endList&&!a.hasStarted_)return s({message:"player must be playing a live stream to start buffering"});if(!kre(e))return s({message:"programDateTime tags must be provided in the manifest "+e.resolvedUri});const o=Pre(r,e);if(!o)return s({message:`${r} was not found in the stream`});const l=o.segment,u=Lre(l.dateTimeObject,r);if(o.type==="estimate"){if(t===0)return s({message:`${r} is not buffered yet. Try again`});i(o.estimatedStart+u),a.one("seeked",()=>{I9({programTime:r,playlist:e,retryCount:t-1,seekTo:i,pauseAfterSeek:n,tech:a,callback:s})});return}const c=l.start+u,h=()=>s(null,a.currentTime());a.one("seeked",h),n&&a.pause(),i(c)},w2=(r,e)=>{if(r.readyState===4)return e()},Ore=(r,e,t,i)=>{let n=[],a,s=!1;const o=function(h,d,f,p){return d.abort(),s=!0,t(h,d,f,p)},l=function(h,d){if(s)return;if(h)return h.metadata=Iu({requestType:i,request:d,error:h}),o(h,d,"",n);const f=d.responseText.substring(n&&n.byteLength||0,d.responseText.length);if(n=UQ(n,J6(f,!0)),a=a||Wd(n),n.length<10||a&&n.lengtho(h,d,"",n));const p=OC(n);return p==="ts"&&n.length<188?w2(d,()=>o(h,d,"",n)):!p&&n.length<376?w2(d,()=>o(h,d,"",n)):o(null,d,p,n)},c=e({uri:r,beforeSend(h){h.overrideMimeType("text/plain; charset=x-user-defined"),h.addEventListener("progress",function({total:d,loaded:f}){return HT(h,null,{statusCode:h.status},l)})}},function(h,d){return HT(c,h,d,l)});return c},{EventTarget:Nre}=K,l4=function(r,e){if(!x9(r,e)||r.sidx&&e.sidx&&(r.sidx.offset!==e.sidx.offset||r.sidx.length!==e.sidx.length))return!1;if(!r.sidx&&e.sidx||r.sidx&&!e.sidx||r.segments&&!e.segments||!r.segments&&e.segments)return!1;if(!r.segments&&!e.segments)return!0;for(let t=0;t{const n=i.attributes.NAME||t;return`placeholder-uri-${r}-${e}-${n}`},Fre=({mainXml:r,srcUrl:e,clientOffset:t,sidxMapping:i,previousManifest:n})=>{const a=see(r,{manifestUri:e,clientOffset:t,sidxMapping:i,previousManifest:n});return _9(a,e,Bre),a},Ure=(r,e)=>{Af(r,(t,i,n,a)=>{(!e.mediaGroups[i][n]||!(a in e.mediaGroups[i][n]))&&delete r.mediaGroups[i][n][a]})},Vre=(r,e,t)=>{let i=!0,n=It(r,{duration:e.duration,minimumUpdatePeriod:e.minimumUpdatePeriod,timelineStarts:e.timelineStarts});for(let a=0;a{if(a.playlists&&a.playlists.length){const u=a.playlists[0].id,c=zT(n,a.playlists[0],l4);c&&(n=c,l in n.mediaGroups[s][o]||(n.mediaGroups[s][o][l]=a),n.mediaGroups[s][o][l].playlists[0]=n.playlists[u],i=!1)}}),Ure(n,e),e.minimumUpdatePeriod!==r.minimumUpdatePeriod&&(i=!1),i?null:n},zre=(r,e)=>(!r.map&&!e.map||!!(r.map&&e.map&&r.map.byterange.offset===e.map.byterange.offset&&r.map.byterange.length===e.map.byterange.length))&&r.uri===e.uri&&r.byterange.offset===e.byterange.offset&&r.byterange.length===e.byterange.length,u4=(r,e)=>{const t={};for(const i in r){const a=r[i].sidx;if(a){const s=A_(a);if(!e[s])break;const o=e[s].sidxInfo;zre(o,a)&&(t[s]=e[s])}}return t},Gre=(r,e)=>{let i=u4(r.playlists,e);return Af(r,(n,a,s,o)=>{if(n.playlists&&n.playlists.length){const l=n.playlists;i=It(i,u4(l,e))}}),i};class WT extends Nre{constructor(e,t,i={},n){super(),this.mainPlaylistLoader_=n||this,n||(this.isMain_=!0);const{withCredentials:a=!1}=i;if(this.vhs_=t,this.withCredentials=a,this.addMetadataToTextTrack=i.addMetadataToTextTrack,!e)throw new Error("A non-empty playlist URL or object is required");this.on("minimumUpdatePeriod",()=>{this.refreshXml_()}),this.on("mediaupdatetimeout",()=>{this.refreshMedia_(this.media().id)}),this.state="HAVE_NOTHING",this.loadedPlaylists_={},this.logger_=Kn("DashPlaylistLoader"),this.isMain_?(this.mainPlaylistLoader_.srcUrl=e,this.mainPlaylistLoader_.sidxMapping_={}):this.childPlaylist_=e}requestErrored_(e,t,i){if(!this.request)return!0;if(this.request=null,e)return this.error=typeof e=="object"&&!(e instanceof Error)?e:{status:t.status,message:"DASH request error at URL: "+t.uri,response:t.response,code:2,metadata:e.metadata},i&&(this.state=i),this.trigger("error"),!0}addSidxSegments_(e,t,i){const n=e.sidx&&A_(e.sidx);if(!e.sidx||!n||this.mainPlaylistLoader_.sidxMapping_[n]){this.mediaRequest_=H.setTimeout(()=>i(!1),0);return}const a=ny(e.sidx.resolvedUri),s=(l,u)=>{if(this.requestErrored_(l,u,t))return;const c=this.mainPlaylistLoader_.sidxMapping_,{requestType:h}=u;let d;try{d=fee($e(u.response).subarray(8))}catch(f){f.metadata=Iu({requestType:h,request:u,parseFailure:!0}),this.requestErrored_(f,u,t);return}return c[n]={sidxInfo:e.sidx,sidx:d},LC(e,d,e.sidx.resolvedUri),i(!0)},o="dash-sidx";this.request=Ore(a,this.vhs_.xhr,(l,u,c,h)=>{if(l)return s(l,u);if(!c||c!=="mp4"){const p=c||"unknown";return s({status:u.status,message:`Unsupported ${p} container type for sidx segment at URL: ${a}`,response:"",playlist:e,internal:!0,playlistExclusionDuration:1/0,code:2},u)}const{offset:d,length:f}=e.sidx.byterange;if(h.length>=f+d)return s(l,{response:h.subarray(d,d+f),status:u.status,uri:u.uri});this.request=this.vhs_.xhr({uri:a,responseType:"arraybuffer",requestType:"dash-sidx",headers:$T({byterange:e.sidx.byterange})},s)},o)}dispose(){this.trigger("dispose"),this.stopRequest(),this.loadedPlaylists_={},H.clearTimeout(this.minimumUpdatePeriodTimeout_),H.clearTimeout(this.mediaRequest_),H.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.mediaRequest_=null,this.minimumUpdatePeriodTimeout_=null,this.mainPlaylistLoader_.createMupOnMedia_&&(this.off("loadedmetadata",this.mainPlaylistLoader_.createMupOnMedia_),this.mainPlaylistLoader_.createMupOnMedia_=null),this.off()}hasPendingRequest(){return this.request||this.mediaRequest_}stopRequest(){if(this.request){const e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}}media(e){if(!e)return this.media_;if(this.state==="HAVE_NOTHING")throw new Error("Cannot switch media playlist from "+this.state);const t=this.state;if(typeof e=="string"){if(!this.mainPlaylistLoader_.main.playlists[e])throw new Error("Unknown playlist URI: "+e);e=this.mainPlaylistLoader_.main.playlists[e]}const i=!this.media_||e.id!==this.media_.id;if(i&&this.loadedPlaylists_[e.id]&&this.loadedPlaylists_[e.id].endList){this.state="HAVE_METADATA",this.media_=e,i&&(this.trigger("mediachanging"),this.trigger("mediachange"));return}i&&(this.media_&&this.trigger("mediachanging"),this.addSidxSegments_(e,t,n=>{this.haveMetadata({startingState:t,playlist:e})}))}haveMetadata({startingState:e,playlist:t}){this.state="HAVE_METADATA",this.loadedPlaylists_[t.id]=t,this.mediaRequest_=null,this.refreshMedia_(t.id),e==="HAVE_MAIN_MANIFEST"?this.trigger("loadedmetadata"):this.trigger("mediachange")}pause(){this.mainPlaylistLoader_.createMupOnMedia_&&(this.off("loadedmetadata",this.mainPlaylistLoader_.createMupOnMedia_),this.mainPlaylistLoader_.createMupOnMedia_=null),this.stopRequest(),H.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.isMain_&&(H.clearTimeout(this.mainPlaylistLoader_.minimumUpdatePeriodTimeout_),this.mainPlaylistLoader_.minimumUpdatePeriodTimeout_=null),this.state==="HAVE_NOTHING"&&(this.started=!1)}load(e){H.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null;const t=this.media();if(e){const i=t?t.targetDuration/2*1e3:5e3;this.mediaUpdateTimeout=H.setTimeout(()=>this.load(),i);return}if(!this.started){this.start();return}t&&!t.endList?(this.isMain_&&!this.minimumUpdatePeriodTimeout_&&(this.trigger("minimumUpdatePeriod"),this.updateMinimumUpdatePeriodTimeout_()),this.trigger("mediaupdatetimeout")):this.trigger("loadedplaylist")}start(){if(this.started=!0,!this.isMain_){this.mediaRequest_=H.setTimeout(()=>this.haveMain_(),0);return}this.requestMain_((e,t)=>{this.haveMain_(),!this.hasPendingRequest()&&!this.media_&&this.media(this.mainPlaylistLoader_.main.playlists[0])})}requestMain_(e){const t={manifestInfo:{uri:this.mainPlaylistLoader_.srcUrl}};this.trigger({type:"manifestrequeststart",metadata:t}),this.request=this.vhs_.xhr({uri:this.mainPlaylistLoader_.srcUrl,withCredentials:this.withCredentials,requestType:"dash-manifest"},(i,n)=>{if(i){const{requestType:s}=n;i.metadata=Iu({requestType:s,request:n,error:i})}if(this.requestErrored_(i,n)){this.state==="HAVE_NOTHING"&&(this.started=!1);return}this.trigger({type:"manifestrequestcomplete",metadata:t});const a=n.responseText!==this.mainPlaylistLoader_.mainXml_;if(this.mainPlaylistLoader_.mainXml_=n.responseText,n.responseHeaders&&n.responseHeaders.date?this.mainLoaded_=Date.parse(n.responseHeaders.date):this.mainLoaded_=Date.now(),this.mainPlaylistLoader_.srcUrl=ny(this.mainPlaylistLoader_.srcUrl,n),a){this.handleMain_(),this.syncClientServerClock_(()=>e(n,a));return}return e(n,a)})}syncClientServerClock_(e){const t=oee(this.mainPlaylistLoader_.mainXml_);if(t===null)return this.mainPlaylistLoader_.clientOffset_=this.mainLoaded_-Date.now(),e();if(t.method==="DIRECT")return this.mainPlaylistLoader_.clientOffset_=t.value-Date.now(),e();this.request=this.vhs_.xhr({uri:Ni(this.mainPlaylistLoader_.srcUrl,t.value),method:t.method,withCredentials:this.withCredentials,requestType:"dash-clock-sync"},(i,n)=>{if(!this.request)return;if(i){const{requestType:s}=n;return this.error.metadata=Iu({requestType:s,request:n,error:i}),this.mainPlaylistLoader_.clientOffset_=this.mainLoaded_-Date.now(),e()}let a;t.method==="HEAD"?!n.responseHeaders||!n.responseHeaders.date?a=this.mainLoaded_:a=Date.parse(n.responseHeaders.date):a=Date.parse(n.responseText),this.mainPlaylistLoader_.clientOffset_=a-Date.now(),e()})}haveMain_(){this.state="HAVE_MAIN_MANIFEST",this.isMain_?this.trigger("loadedplaylist"):this.media_||this.media(this.childPlaylist_)}handleMain_(){this.mediaRequest_=null;const e=this.mainPlaylistLoader_.main,t={manifestInfo:{uri:this.mainPlaylistLoader_.srcUrl}};this.trigger({type:"manifestparsestart",metadata:t});let i;try{i=Fre({mainXml:this.mainPlaylistLoader_.mainXml_,srcUrl:this.mainPlaylistLoader_.srcUrl,clientOffset:this.mainPlaylistLoader_.clientOffset_,sidxMapping:this.mainPlaylistLoader_.sidxMapping_,previousManifest:e})}catch(a){this.error=a,this.error.metadata={errorType:K.Error.StreamingDashManifestParserError,error:a},this.trigger("error")}e&&(i=Vre(e,i,this.mainPlaylistLoader_.sidxMapping_)),this.mainPlaylistLoader_.main=i||e;const n=this.mainPlaylistLoader_.main.locations&&this.mainPlaylistLoader_.main.locations[0];if(n&&n!==this.mainPlaylistLoader_.srcUrl&&(this.mainPlaylistLoader_.srcUrl=n),(!e||i&&i.minimumUpdatePeriod!==e.minimumUpdatePeriod)&&this.updateMinimumUpdatePeriodTimeout_(),this.addEventStreamToMetadataTrack_(i),i){const{duration:a,endList:s}=i,o=[];i.playlists.forEach(u=>{o.push({id:u.id,bandwidth:u.attributes.BANDWIDTH,resolution:u.attributes.RESOLUTION,codecs:u.attributes.CODECS})});const l={duration:a,isLive:!s,renditions:o};t.parsedManifest=l,this.trigger({type:"manifestparsecomplete",metadata:t})}return!!i}updateMinimumUpdatePeriodTimeout_(){const e=this.mainPlaylistLoader_;e.createMupOnMedia_&&(e.off("loadedmetadata",e.createMupOnMedia_),e.createMupOnMedia_=null),e.minimumUpdatePeriodTimeout_&&(H.clearTimeout(e.minimumUpdatePeriodTimeout_),e.minimumUpdatePeriodTimeout_=null);let t=e.main&&e.main.minimumUpdatePeriod;if(t===0&&(e.media()?t=e.media().targetDuration*1e3:(e.createMupOnMedia_=e.updateMinimumUpdatePeriodTimeout_,e.one("loadedmetadata",e.createMupOnMedia_))),typeof t!="number"||t<=0){t<0&&this.logger_(`found invalid minimumUpdatePeriod of ${t}, not setting a timeout`);return}this.createMUPTimeout_(t)}createMUPTimeout_(e){const t=this.mainPlaylistLoader_;t.minimumUpdatePeriodTimeout_=H.setTimeout(()=>{t.minimumUpdatePeriodTimeout_=null,t.trigger("minimumUpdatePeriod"),t.createMUPTimeout_(e)},e)}refreshXml_(){this.requestMain_((e,t)=>{t&&(this.media_&&(this.media_=this.mainPlaylistLoader_.main.playlists[this.media_.id]),this.mainPlaylistLoader_.sidxMapping_=Gre(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.sidxMapping_),this.addSidxSegments_(this.media(),this.state,i=>{this.refreshMedia_(this.media().id)}))})}refreshMedia_(e){if(!e)throw new Error("refreshMedia_ must take a media id");this.media_&&this.isMain_&&this.handleMain_();const t=this.mainPlaylistLoader_.main.playlists,i=!this.media_||this.media_!==t[e];if(i?this.media_=t[e]:this.trigger("playlistunchanged"),!this.mediaUpdateTimeout){const n=()=>{this.media().endList||(this.mediaUpdateTimeout=H.setTimeout(()=>{this.trigger("mediaupdatetimeout"),n()},GT(this.media(),!!i)))};n()}this.trigger("loadedplaylist")}addEventStreamToMetadataTrack_(e){if(e&&this.mainPlaylistLoader_.main.eventStream){const t=this.mainPlaylistLoader_.main.eventStream.map(i=>({cueTime:i.start,frames:[{data:i.messageData}]}));this.addMetadataToTextTrack("EventStream",t,this.mainPlaylistLoader_.main.duration)}}getKeyIdSet(e){if(e.contentProtection){const t=new Set;for(const i in e.contentProtection){const n=e.contentProtection[i].attributes["cenc:default_KID"];n&&t.add(n.replace(/-/g,"").toLowerCase())}return t}}}var Fr={GOAL_BUFFER_LENGTH:30,MAX_GOAL_BUFFER_LENGTH:60,BACK_BUFFER_LENGTH:30,GOAL_BUFFER_LENGTH_RATE:1,INITIAL_BANDWIDTH:4194304,BANDWIDTH_VARIANCE:1.2,BUFFER_LOW_WATER_LINE:0,MAX_BUFFER_LOW_WATER_LINE:30,EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:16,BUFFER_LOW_WATER_LINE_RATE:1,BUFFER_HIGH_WATER_LINE:30};const Hre=r=>{const e=new Uint8Array(new ArrayBuffer(r.length));for(let t=0;t-1):!1},this.trigger=function(w){var E,A,P,k;if(E=S[w],!!E)if(arguments.length===2)for(P=E.length,A=0;A"u")){for(S in O)O.hasOwnProperty(S)&&(O[S]=[S.charCodeAt(0),S.charCodeAt(1),S.charCodeAt(2),S.charCodeAt(3)]);B=new Uint8Array([105,115,111,109]),U=new Uint8Array([97,118,99,49]),F=new Uint8Array([0,0,0,1]),$=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),q=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),Z={video:$,audio:q},se=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),Q=new Uint8Array([0,0,0,0,0,0,0,0]),he=new Uint8Array([0,0,0,0,0,0,0,0]),ue=he,Ie=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),Oe=he,te=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}})(),o=function(S){var w=[],E=0,A,P,k;for(A=1;A>>1,S.samplingfrequencyindex<<7|S.channelcount<<3,6,1,2]))},c=function(){return o(O.ftyp,B,F,B,U)},x=function(S){return o(O.hdlr,Z[S])},h=function(S){return o(O.mdat,S)},T=function(S){var w=new Uint8Array([0,0,0,0,0,0,0,2,0,0,0,3,0,1,95,144,S.duration>>>24&255,S.duration>>>16&255,S.duration>>>8&255,S.duration&255,85,196,0,0]);return S.samplerate&&(w[12]=S.samplerate>>>24&255,w[13]=S.samplerate>>>16&255,w[14]=S.samplerate>>>8&255,w[15]=S.samplerate&255),o(O.mdhd,w)},b=function(S){return o(O.mdia,T(S),x(S.type),f(S))},d=function(S){return o(O.mfhd,new Uint8Array([0,0,0,0,(S&4278190080)>>24,(S&16711680)>>16,(S&65280)>>8,S&255]))},f=function(S){return o(O.minf,S.type==="video"?o(O.vmhd,te):o(O.smhd,Q),l(),D(S))},p=function(S,w){for(var E=[],A=w.length;A--;)E[A]=M(w[A]);return o.apply(null,[O.moof,d(S)].concat(E))},v=function(S){for(var w=S.length,E=[];w--;)E[w]=y(S[w]);return o.apply(null,[O.moov,m(4294967295)].concat(E).concat(g(S)))},g=function(S){for(var w=S.length,E=[];w--;)E[w]=L(S[w]);return o.apply(null,[O.mvex].concat(E))},m=function(S){var w=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,2,0,1,95,144,(S&4278190080)>>24,(S&16711680)>>16,(S&65280)>>8,S&255,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return o(O.mvhd,w)},C=function(S){var w=S.samples||[],E=new Uint8Array(4+w.length),A,P;for(P=0;P>>8),k.push(A[z].byteLength&255),k=k.concat(Array.prototype.slice.call(A[z]));for(z=0;z>>8),V.push(P[z].byteLength&255),V=V.concat(Array.prototype.slice.call(P[z]));if(G=[O.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,(E.width&65280)>>8,E.width&255,(E.height&65280)>>8,E.height&255,0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),o(O.avcC,new Uint8Array([1,E.profileIdc,E.profileCompatibility,E.levelIdc,255].concat([A.length],k,[P.length],V))),o(O.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192]))],E.sarRatio){var W=E.sarRatio[0],Y=E.sarRatio[1];G.push(o(O.pasp,new Uint8Array([(W&4278190080)>>24,(W&16711680)>>16,(W&65280)>>8,W&255,(Y&4278190080)>>24,(Y&16711680)>>16,(Y&65280)>>8,Y&255])))}return o.apply(null,G)},w=function(E){return o(O.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,(E.channelcount&65280)>>8,E.channelcount&255,(E.samplesize&65280)>>8,E.samplesize&255,0,0,0,0,(E.samplerate&65280)>>8,E.samplerate&255,0,0]),u(E))}}(),_=function(S){var w=new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,(S.id&4278190080)>>24,(S.id&16711680)>>16,(S.id&65280)>>8,S.id&255,0,0,0,0,(S.duration&4278190080)>>24,(S.duration&16711680)>>16,(S.duration&65280)>>8,S.duration&255,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,(S.width&65280)>>8,S.width&255,0,0,(S.height&65280)>>8,S.height&255,0,0]);return o(O.tkhd,w)},M=function(S){var w,E,A,P,k,V,z;return w=o(O.tfhd,new Uint8Array([0,0,0,58,(S.id&4278190080)>>24,(S.id&16711680)>>16,(S.id&65280)>>8,S.id&255,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0])),V=Math.floor(S.baseMediaDecodeTime/s),z=Math.floor(S.baseMediaDecodeTime%s),E=o(O.tfdt,new Uint8Array([1,0,0,0,V>>>24&255,V>>>16&255,V>>>8&255,V&255,z>>>24&255,z>>>16&255,z>>>8&255,z&255])),k=92,S.type==="audio"?(A=N(S,k),o(O.traf,w,E,A)):(P=C(S),A=N(S,P.length+k),o(O.traf,w,E,A,P))},y=function(S){return S.duration=S.duration||4294967295,o(O.trak,_(S),b(S))},L=function(S){var w=new Uint8Array([0,0,0,0,(S.id&4278190080)>>24,(S.id&16711680)>>16,(S.id&65280)>>8,S.id&255,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return S.type!=="video"&&(w[w.length-1]=0),o(O.trex,w)},function(){var S,w,E;E=function(A,P){var k=0,V=0,z=0,G=0;return A.length&&(A[0].duration!==void 0&&(k=1),A[0].size!==void 0&&(V=2),A[0].flags!==void 0&&(z=4),A[0].compositionTimeOffset!==void 0&&(G=8)),[0,0,k|V|z|G,1,(A.length&4278190080)>>>24,(A.length&16711680)>>>16,(A.length&65280)>>>8,A.length&255,(P&4278190080)>>>24,(P&16711680)>>>16,(P&65280)>>>8,P&255]},w=function(A,P){var k,V,z,G,W,Y;for(G=A.samples||[],P+=20+16*G.length,z=E(G,P),V=new Uint8Array(z.length+G.length*16),V.set(z),k=z.length,Y=0;Y>>24,V[k++]=(W.duration&16711680)>>>16,V[k++]=(W.duration&65280)>>>8,V[k++]=W.duration&255,V[k++]=(W.size&4278190080)>>>24,V[k++]=(W.size&16711680)>>>16,V[k++]=(W.size&65280)>>>8,V[k++]=W.size&255,V[k++]=W.flags.isLeading<<2|W.flags.dependsOn,V[k++]=W.flags.isDependedOn<<6|W.flags.hasRedundancy<<4|W.flags.paddingValue<<1|W.flags.isNonSyncSample,V[k++]=W.flags.degradationPriority&61440,V[k++]=W.flags.degradationPriority&15,V[k++]=(W.compositionTimeOffset&4278190080)>>>24,V[k++]=(W.compositionTimeOffset&16711680)>>>16,V[k++]=(W.compositionTimeOffset&65280)>>>8,V[k++]=W.compositionTimeOffset&255;return o(O.trun,V)},S=function(A,P){var k,V,z,G,W,Y;for(G=A.samples||[],P+=20+8*G.length,z=E(G,P),k=new Uint8Array(z.length+G.length*8),k.set(z),V=z.length,Y=0;Y>>24,k[V++]=(W.duration&16711680)>>>16,k[V++]=(W.duration&65280)>>>8,k[V++]=W.duration&255,k[V++]=(W.size&4278190080)>>>24,k[V++]=(W.size&16711680)>>>16,k[V++]=(W.size&65280)>>>8,k[V++]=W.size&255;return o(O.trun,k)},N=function(A,P){return A.type==="audio"?S(A,P):w(A,P)}}();var Fe={ftyp:c,mdat:h,moof:p,moov:v,initSegment:function(S){var w=c(),E=v(S),A;return A=new Uint8Array(w.byteLength+E.byteLength),A.set(w),A.set(E,w.byteLength),A}},me=function(S){var w,E,A=[],P=[];for(P.byteLength=0,P.nalCount=0,P.duration=0,A.byteLength=0,w=0;w1&&(w=S.shift(),S.byteLength-=w.byteLength,S.nalCount-=w.nalCount,S[0][0].dts=w.dts,S[0][0].pts=w.pts,S[0][0].duration+=w.duration),S},ye=function(){return{size:0,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0,degradationPriority:0,isNonSyncSample:1}}},Me=function(S,w){var E=ye();return E.dataOffset=w,E.compositionTimeOffset=S.pts-S.dts,E.duration=S.duration,E.size=4*S.length,E.size+=S.byteLength,S.keyFrame&&(E.flags.dependsOn=2,E.flags.isNonSyncSample=0),E},_t=function(S,w){var E,A,P,k,V,z=w||0,G=[];for(E=0;Edl.ONE_SECOND_IN_TS/2))){for(W=$f()[S.samplerate],W||(W=w[0].data),Y=0;Y=E?S:(w.minSegmentDts=1/0,S.filter(function(A){return A.dts>=E?(w.minSegmentDts=Math.min(w.minSegmentDts,A.dts),w.minSegmentPts=w.minSegmentDts,!0):!1}))},vl=function(S){var w,E,A=[];for(w=0;w=this.virtualRowCount&&typeof this.beforeRowOverflow=="function"&&this.beforeRowOverflow(S),this.rows.length>0&&(this.rows.push(""),this.rowIdx++);this.rows.length>this.virtualRowCount;)this.rows.shift(),this.rowIdx--},Dr.prototype.isEmpty=function(){return this.rows.length===0?!0:this.rows.length===1?this.rows[0]==="":!1},Dr.prototype.addText=function(S){this.rows[this.rowIdx]+=S},Dr.prototype.backspace=function(){if(!this.isEmpty()){var S=this.rows[this.rowIdx];this.rows[this.rowIdx]=S.substr(0,S.length-1)}};var qr=function(S,w,E){this.serviceNum=S,this.text="",this.currentWindow=new Dr(-1),this.windows=[],this.stream=E,typeof w=="string"&&this.createTextDecoder(w)};qr.prototype.init=function(S,w){this.startPts=S;for(var E=0;E<8;E++)this.windows[E]=new Dr(E),typeof w=="function"&&(this.windows[E].beforeRowOverflow=w)},qr.prototype.setCurrentWindow=function(S){this.currentWindow=this.windows[S]},qr.prototype.createTextDecoder=function(S){if(typeof TextDecoder>"u")this.stream.trigger("log",{level:"warn",message:"The `encoding` option is unsupported without TextDecoder support"});else try{this.textDecoder_=new TextDecoder(S)}catch(w){this.stream.trigger("log",{level:"warn",message:"TextDecoder could not be created with "+S+" encoding. "+w})}};var ft=function(S){S=S||{},ft.prototype.init.call(this);var w=this,E=S.captionServices||{},A={},P;Object.keys(E).forEach(k=>{P=E[k],/^SERVICE/.test(k)&&(A[k]=P.encoding)}),this.serviceEncodings=A,this.current708Packet=null,this.services={},this.push=function(k){k.type===3?(w.new708Packet(),w.add708Bytes(k)):(w.current708Packet===null&&w.new708Packet(),w.add708Bytes(k))}};ft.prototype=new Ne,ft.prototype.new708Packet=function(){this.current708Packet!==null&&this.push708Packet(),this.current708Packet={data:[],ptsVals:[]}},ft.prototype.add708Bytes=function(S){var w=S.ccData,E=w>>>8,A=w&255;this.current708Packet.ptsVals.push(S.pts),this.current708Packet.data.push(E),this.current708Packet.data.push(A)},ft.prototype.push708Packet=function(){var S=this.current708Packet,w=S.data,E=null,A=null,P=0,k=w[P++];for(S.seq=k>>6,S.sizeCode=k&63;P>5,A=k&31,E===7&&A>0&&(k=w[P++],E=k),this.pushServiceBlock(E,P,A),A>0&&(P+=A-1)},ft.prototype.pushServiceBlock=function(S,w,E){var A,P=w,k=this.current708Packet.data,V=this.services[S];for(V||(V=this.initService(S,P));P("0"+(je&255).toString(16)).slice(-2)).join("")}if(P?(ee=[z,G],S++):ee=[z],w.textDecoder_&&!A)Y=w.textDecoder_.decode(new Uint8Array(ee));else if(P){const le=Te(ee);Y=String.fromCharCode(parseInt(le,16))}else Y=Kt(V|z);return W.pendingNewLine&&!W.isEmpty()&&W.newLine(this.getPts(S)),W.pendingNewLine=!1,W.addText(Y),S},ft.prototype.multiByteCharacter=function(S,w){var E=this.current708Packet.data,A=E[S+1],P=E[S+2];return ur(A)&&ur(P)&&(S=this.handleText(++S,w,{isMultiByte:!0})),S},ft.prototype.setCurrentWindow=function(S,w){var E=this.current708Packet.data,A=E[S],P=A&7;return w.setCurrentWindow(P),S},ft.prototype.defineWindow=function(S,w){var E=this.current708Packet.data,A=E[S],P=A&7;w.setCurrentWindow(P);var k=w.currentWindow;return A=E[++S],k.visible=(A&32)>>5,k.rowLock=(A&16)>>4,k.columnLock=(A&8)>>3,k.priority=A&7,A=E[++S],k.relativePositioning=(A&128)>>7,k.anchorVertical=A&127,A=E[++S],k.anchorHorizontal=A,A=E[++S],k.anchorPoint=(A&240)>>4,k.rowCount=A&15,A=E[++S],k.columnCount=A&63,A=E[++S],k.windowStyle=(A&56)>>3,k.penStyle=A&7,k.virtualRowCount=k.rowCount+1,S},ft.prototype.setWindowAttributes=function(S,w){var E=this.current708Packet.data,A=E[S],P=w.currentWindow.winAttr;return A=E[++S],P.fillOpacity=(A&192)>>6,P.fillRed=(A&48)>>4,P.fillGreen=(A&12)>>2,P.fillBlue=A&3,A=E[++S],P.borderType=(A&192)>>6,P.borderRed=(A&48)>>4,P.borderGreen=(A&12)>>2,P.borderBlue=A&3,A=E[++S],P.borderType+=(A&128)>>5,P.wordWrap=(A&64)>>6,P.printDirection=(A&48)>>4,P.scrollDirection=(A&12)>>2,P.justify=A&3,A=E[++S],P.effectSpeed=(A&240)>>4,P.effectDirection=(A&12)>>2,P.displayEffect=A&3,S},ft.prototype.flushDisplayed=function(S,w){for(var E=[],A=0;A<8;A++)w.windows[A].visible&&!w.windows[A].isEmpty()&&E.push(w.windows[A].getText());w.endPts=S,w.text=E.join(` + +`),this.pushCaption(w),w.startPts=S},ft.prototype.pushCaption=function(S){S.text!==""&&(this.trigger("data",{startPts:S.startPts,endPts:S.endPts,text:S.text,stream:"cc708_"+S.serviceNum}),S.text="",S.startPts=S.endPts)},ft.prototype.displayWindows=function(S,w){var E=this.current708Packet.data,A=E[++S],P=this.getPts(S);this.flushDisplayed(P,w);for(var k=0;k<8;k++)A&1<>4,P.offset=(A&12)>>2,P.penSize=A&3,A=E[++S],P.italics=(A&128)>>7,P.underline=(A&64)>>6,P.edgeType=(A&56)>>3,P.fontStyle=A&7,S},ft.prototype.setPenColor=function(S,w){var E=this.current708Packet.data,A=E[S],P=w.currentWindow.penColor;return A=E[++S],P.fgOpacity=(A&192)>>6,P.fgRed=(A&48)>>4,P.fgGreen=(A&12)>>2,P.fgBlue=A&3,A=E[++S],P.bgOpacity=(A&192)>>6,P.bgRed=(A&48)>>4,P.bgGreen=(A&12)>>2,P.bgBlue=A&3,A=E[++S],P.edgeRed=(A&48)>>4,P.edgeGreen=(A&12)>>2,P.edgeBlue=A&3,S},ft.prototype.setPenLocation=function(S,w){var E=this.current708Packet.data,A=E[S],P=w.currentWindow.penLoc;return w.currentWindow.pendingNewLine=!0,A=E[++S],P.row=A&15,A=E[++S],P.column=A&63,S},ft.prototype.reset=function(S,w){var E=this.getPts(S);return this.flushDisplayed(E,w),this.initService(w.serviceNum,S)};var Er={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,304:174,305:176,306:189,307:191,308:8482,309:162,310:163,311:9834,312:224,313:160,314:232,315:226,316:234,317:238,318:244,319:251,544:193,545:201,546:211,547:218,548:220,549:252,550:8216,551:161,552:42,553:39,554:8212,555:169,556:8480,557:8226,558:8220,559:8221,560:192,561:194,562:199,563:200,564:202,565:203,566:235,567:206,568:207,569:239,570:212,571:217,572:249,573:219,574:171,575:187,800:195,801:227,802:205,803:204,804:236,805:210,806:242,807:213,808:245,809:123,810:125,811:92,812:94,813:95,814:124,815:126,816:196,817:228,818:214,819:246,820:223,821:165,822:164,823:9474,824:197,825:229,826:216,827:248,828:9484,829:9488,830:9492,831:9496},zt=function(S){return S===null?"":(S=Er[S]||S,String.fromCharCode(S))},no=14,tn=[4352,4384,4608,4640,5376,5408,5632,5664,5888,5920,4096,4864,4896,5120,5152],ml=function(){for(var S=[],w=no+1;w--;)S.push({text:"",indent:0,offset:0});return S},Wt=function(S,w){Wt.prototype.init.call(this),this.field_=S||0,this.dataChannel_=w||0,this.name_="CC"+((this.field_<<1|this.dataChannel_)+1),this.setConstants(),this.reset(),this.push=function(E){var A,P,k,V,z;if(A=E.ccData&32639,A===this.lastControlCode_){this.lastControlCode_=null;return}if((A&61440)===4096?this.lastControlCode_=A:A!==this.PADDING_&&(this.lastControlCode_=null),k=A>>>8,V=A&255,A!==this.PADDING_)if(A===this.RESUME_CAPTION_LOADING_)this.mode_="popOn";else if(A===this.END_OF_CAPTION_)this.mode_="popOn",this.clearFormatting(E.pts),this.flushDisplayed(E.pts),P=this.displayed_,this.displayed_=this.nonDisplayed_,this.nonDisplayed_=P,this.startPts_=E.pts;else if(A===this.ROLL_UP_2_ROWS_)this.rollUpRows_=2,this.setRollUp(E.pts);else if(A===this.ROLL_UP_3_ROWS_)this.rollUpRows_=3,this.setRollUp(E.pts);else if(A===this.ROLL_UP_4_ROWS_)this.rollUpRows_=4,this.setRollUp(E.pts);else if(A===this.CARRIAGE_RETURN_)this.clearFormatting(E.pts),this.flushDisplayed(E.pts),this.shiftRowsUp_(),this.startPts_=E.pts;else if(A===this.BACKSPACE_)this.mode_==="popOn"?this.nonDisplayed_[this.row_].text=this.nonDisplayed_[this.row_].text.slice(0,-1):this.displayed_[this.row_].text=this.displayed_[this.row_].text.slice(0,-1);else if(A===this.ERASE_DISPLAYED_MEMORY_)this.flushDisplayed(E.pts),this.displayed_=ml();else if(A===this.ERASE_NON_DISPLAYED_MEMORY_)this.nonDisplayed_=ml();else if(A===this.RESUME_DIRECT_CAPTIONING_)this.mode_!=="paintOn"&&(this.flushDisplayed(E.pts),this.displayed_=ml()),this.mode_="paintOn",this.startPts_=E.pts;else if(this.isSpecialCharacter(k,V))k=(k&3)<<8,z=zt(k|V),this[this.mode_](E.pts,z),this.column_++;else if(this.isExtCharacter(k,V))this.mode_==="popOn"?this.nonDisplayed_[this.row_].text=this.nonDisplayed_[this.row_].text.slice(0,-1):this.displayed_[this.row_].text=this.displayed_[this.row_].text.slice(0,-1),k=(k&3)<<8,z=zt(k|V),this[this.mode_](E.pts,z),this.column_++;else if(this.isMidRowCode(k,V))this.clearFormatting(E.pts),this[this.mode_](E.pts," "),this.column_++,(V&14)===14&&this.addFormatting(E.pts,["i"]),(V&1)===1&&this.addFormatting(E.pts,["u"]);else if(this.isOffsetControlCode(k,V)){const W=V&3;this.nonDisplayed_[this.row_].offset=W,this.column_+=W}else if(this.isPAC(k,V)){var G=tn.indexOf(A&7968);if(this.mode_==="rollUp"&&(G-this.rollUpRows_+1<0&&(G=this.rollUpRows_-1),this.setRollUp(E.pts,G)),G!==this.row_&&G>=0&&G<=14&&(this.clearFormatting(E.pts),this.row_=G),V&1&&this.formatting_.indexOf("u")===-1&&this.addFormatting(E.pts,["u"]),(A&16)===16){const W=(A&14)>>1;this.column_=W*4,this.nonDisplayed_[this.row_].indent+=W}this.isColorPAC(V)&&(V&14)===14&&this.addFormatting(E.pts,["i"])}else this.isNormalChar(k)&&(V===0&&(V=null),z=zt(k),z+=zt(V),this[this.mode_](E.pts,z),this.column_+=z.length)}};Wt.prototype=new Ne,Wt.prototype.flushDisplayed=function(S){const w=A=>{this.trigger("log",{level:"warn",message:"Skipping a malformed 608 caption at index "+A+"."})},E=[];this.displayed_.forEach((A,P)=>{if(A&&A.text&&A.text.length){try{A.text=A.text.trim()}catch{w(P)}A.text.length&&E.push({text:A.text,line:P+1,position:10+Math.min(70,A.indent*10)+A.offset*2.5})}else A==null&&w(P)}),E.length&&this.trigger("data",{startPts:this.startPts_,endPts:S,content:E,stream:this.name_})},Wt.prototype.reset=function(){this.mode_="popOn",this.topRow_=0,this.startPts_=0,this.displayed_=ml(),this.nonDisplayed_=ml(),this.lastControlCode_=null,this.column_=0,this.row_=no,this.rollUpRows_=2,this.formatting_=[]},Wt.prototype.setConstants=function(){this.dataChannel_===0?(this.BASE_=16,this.EXT_=17,this.CONTROL_=(20|this.field_)<<8,this.OFFSET_=23):this.dataChannel_===1&&(this.BASE_=24,this.EXT_=25,this.CONTROL_=(28|this.field_)<<8,this.OFFSET_=31),this.PADDING_=0,this.RESUME_CAPTION_LOADING_=this.CONTROL_|32,this.END_OF_CAPTION_=this.CONTROL_|47,this.ROLL_UP_2_ROWS_=this.CONTROL_|37,this.ROLL_UP_3_ROWS_=this.CONTROL_|38,this.ROLL_UP_4_ROWS_=this.CONTROL_|39,this.CARRIAGE_RETURN_=this.CONTROL_|45,this.RESUME_DIRECT_CAPTIONING_=this.CONTROL_|41,this.BACKSPACE_=this.CONTROL_|33,this.ERASE_DISPLAYED_MEMORY_=this.CONTROL_|44,this.ERASE_NON_DISPLAYED_MEMORY_=this.CONTROL_|46},Wt.prototype.isSpecialCharacter=function(S,w){return S===this.EXT_&&w>=48&&w<=63},Wt.prototype.isExtCharacter=function(S,w){return(S===this.EXT_+1||S===this.EXT_+2)&&w>=32&&w<=63},Wt.prototype.isMidRowCode=function(S,w){return S===this.EXT_&&w>=32&&w<=47},Wt.prototype.isOffsetControlCode=function(S,w){return S===this.OFFSET_&&w>=33&&w<=35},Wt.prototype.isPAC=function(S,w){return S>=this.BASE_&&S=64&&w<=127},Wt.prototype.isColorPAC=function(S){return S>=64&&S<=79||S>=96&&S<=127},Wt.prototype.isNormalChar=function(S){return S>=32&&S<=127},Wt.prototype.setRollUp=function(S,w){if(this.mode_!=="rollUp"&&(this.row_=no,this.mode_="rollUp",this.flushDisplayed(S),this.nonDisplayed_=ml(),this.displayed_=ml()),w!==void 0&&w!==this.row_)for(var E=0;E"},"");this[this.mode_](S,E)},Wt.prototype.clearFormatting=function(S){if(this.formatting_.length){var w=this.formatting_.reverse().reduce(function(E,A){return E+""},"");this.formatting_=[],this[this.mode_](S,w)}},Wt.prototype.popOn=function(S,w){var E=this.nonDisplayed_[this.row_].text;E+=w,this.nonDisplayed_[this.row_].text=E},Wt.prototype.rollUp=function(S,w){var E=this.displayed_[this.row_].text;E+=w,this.displayed_[this.row_].text=E},Wt.prototype.shiftRowsUp_=function(){var S;for(S=0;Sw&&(E=-1);Math.abs(w-S)>pX;)S+=E*dX;return S},U1=function(S){var w,E;U1.prototype.init.call(this),this.type_=S||YE,this.push=function(A){if(A.type==="metadata"){this.trigger("data",A);return}this.type_!==YE&&A.type!==this.type_||(E===void 0&&(E=A.dts),A.dts=F1(A.dts,E),A.pts=F1(A.pts,E),w=A.dts,this.trigger("data",A))},this.flush=function(){E=w,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.discontinuity=function(){E=void 0,w=void 0},this.reset=function(){this.discontinuity(),this.trigger("reset")}};U1.prototype=new fX;var KE={TimestampRolloverStream:U1,handleRollover:F1},vX=(S,w,E)=>{if(!S)return-1;for(var A=E;A";S.data[0]===xg.Utf8&&(E=Tg(S.data,0,w),!(E<0)&&(S.mimeType=qf(S.data,w,E),w=E+1,S.pictureType=S.data[w],w++,A=Tg(S.data,0,w),!(A<0)&&(S.description=Wf(S.data,w,A),w=A+1,S.mimeType===P?S.url=qf(S.data,w,S.data.length):S.pictureData=S.data.subarray(w,S.data.length))))},"T*":function(S){S.data[0]===xg.Utf8&&(S.value=Wf(S.data,1,S.data.length).replace(/\0*$/,""),S.values=S.value.split("\0"))},TXXX:function(S){var w;S.data[0]===xg.Utf8&&(w=Tg(S.data,0,1),w!==-1&&(S.description=Wf(S.data,1,w),S.value=Wf(S.data,w+1,S.data.length).replace(/\0*$/,""),S.data=S.value))},"W*":function(S){S.url=qf(S.data,0,S.data.length).replace(/\0.*$/,"")},WXXX:function(S){var w;S.data[0]===xg.Utf8&&(w=Tg(S.data,0,1),w!==-1&&(S.description=Wf(S.data,1,w),S.url=qf(S.data,w+1,S.data.length).replace(/\0.*$/,"")))},PRIV:function(S){var w;for(w=0;w>>2;je*=4,je+=le[7]&3,Y.timeStamp=je,z.pts===void 0&&z.dts===void 0&&(z.pts=Y.timeStamp,z.dts=Y.timeStamp),this.trigger("timestamp",Y)}z.frames.push(Y),G+=10,G+=W}while(G>>4>1&&(V+=P[V]+1),k.pid===0)k.type="pat",S(P.subarray(V),k),this.trigger("data",k);else if(k.pid===this.pmtPid)for(k.type="pmt",S(P.subarray(V),k),this.trigger("data",k);this.packetsWaitingForPmt.length;)this.processPes_.apply(this,this.packetsWaitingForPmt.shift());else this.programMapTable===void 0?this.packetsWaitingForPmt.push([P,V,k]):this.processPes_(P,V,k)},this.processPes_=function(P,k,V){V.pid===this.programMapTable.video?V.streamType=ea.H264_STREAM_TYPE:V.pid===this.programMapTable.audio?V.streamType=ea.ADTS_STREAM_TYPE:V.streamType=this.programMapTable["timed-metadata"][V.pid],V.type="pes",V.data=P.subarray(k),this.trigger("data",V)}},Yf.prototype=new V1,Yf.STREAM_TYPES={h264:27,adts:15},Ag=function(){var S=this,w=!1,E={data:[],size:0},A={data:[],size:0},P={data:[],size:0},k,V=function(G,W){var Y;const ee=G[0]<<16|G[1]<<8|G[2];W.data=new Uint8Array,ee===1&&(W.packetLength=6+(G[4]<<8|G[5]),W.dataAlignmentIndicator=(G[6]&4)!==0,Y=G[7],Y&192&&(W.pts=(G[9]&14)<<27|(G[10]&255)<<20|(G[11]&254)<<12|(G[12]&255)<<5|(G[13]&254)>>>3,W.pts*=4,W.pts+=(G[13]&6)>>>1,W.dts=W.pts,Y&64&&(W.dts=(G[14]&14)<<27|(G[15]&255)<<20|(G[16]&254)<<12|(G[17]&255)<<5|(G[18]&254)>>>3,W.dts*=4,W.dts+=(G[18]&6)>>>1)),W.data=G.subarray(9+G[8]))},z=function(G,W,Y){var ee=new Uint8Array(G.size),Te={type:W},le=0,je=0,Je=!1,Ir;if(!(!G.data.length||G.size<9)){for(Te.trackId=G.data[0].pid,le=0;le>5,G=((w[P+6]&3)+1)*1024,W=G*wX/e3[(w[P+2]&60)>>>2],w.byteLength-P>>6&3)+1,channelcount:(w[P+2]&1)<<2|(w[P+3]&192)>>>6,samplerate:e3[(w[P+2]&60)>>>2],samplingfrequencyindex:(w[P+2]&60)>>>2,samplesize:16,data:w.subarray(P+7+V,P+k)}),E++,P+=k}typeof Y=="number"&&(this.skipWarn_(Y,P),Y=null),w=w.subarray(P)}},this.flush=function(){E=0,this.trigger("done")},this.reset=function(){w=void 0,this.trigger("reset")},this.endTimeline=function(){w=void 0,this.trigger("endedtimeline")}},Dg.prototype=new xX;var CX=Dg,t3;t3=function(S){var w=S.byteLength,E=0,A=0;this.length=function(){return 8*w},this.bitsAvailable=function(){return 8*w+A},this.loadWord=function(){var P=S.byteLength-w,k=new Uint8Array(4),V=Math.min(4,w);if(V===0)throw new Error("no bytes available");k.set(S.subarray(P,P+V)),E=new DataView(k.buffer).getUint32(0),A=V*8,w-=V},this.skipBits=function(P){var k;A>P?(E<<=P,A-=P):(P-=A,k=Math.floor(P/8),P-=k*8,w-=k,this.loadWord(),E<<=P,A-=P)},this.readBits=function(P){var k=Math.min(A,P),V=E>>>32-k;return A-=k,A>0?E<<=k:w>0&&this.loadWord(),k=P-k,k>0?V<>>P)return E<<=P,A-=P,P;return this.loadWord(),P+this.skipLeadingZeros()},this.skipUnsignedExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.skipExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.readUnsignedExpGolomb=function(){var P=this.skipLeadingZeros();return this.readBits(P+1)-1},this.readExpGolomb=function(){var P=this.readUnsignedExpGolomb();return 1&P?1+P>>>1:-1*(P>>>1)},this.readBoolean=function(){return this.readBits(1)===1},this.readUnsignedByte=function(){return this.readBits(8)},this.loadWord()};var AX=t3,r3=t,DX=AX,Eg,Kf,i3;Kf=function(){var S=0,w,E;Kf.prototype.init.call(this),this.push=function(A){var P;E?(P=new Uint8Array(E.byteLength+A.data.byteLength),P.set(E),P.set(A.data,E.byteLength),E=P):E=A.data;for(var k=E.byteLength;S3&&this.trigger("data",E.subarray(S+3)),E=null,S=0,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")}},Kf.prototype=new r3,i3={100:!0,110:!0,122:!0,244:!0,44:!0,83:!0,86:!0,118:!0,128:!0,138:!0,139:!0,134:!0},Eg=function(){var S=new Kf,w,E,A,P,k,V,z;Eg.prototype.init.call(this),w=this,this.push=function(G){G.type==="video"&&(E=G.trackId,A=G.pts,P=G.dts,S.push(G))},S.on("data",function(G){var W={trackId:E,pts:A,dts:P,data:G,nalUnitTypeCode:G[0]&31};switch(W.nalUnitTypeCode){case 5:W.nalUnitType="slice_layer_without_partitioning_rbsp_idr";break;case 6:W.nalUnitType="sei_rbsp",W.escapedRBSP=k(G.subarray(1));break;case 7:W.nalUnitType="seq_parameter_set_rbsp",W.escapedRBSP=k(G.subarray(1)),W.config=V(W.escapedRBSP);break;case 8:W.nalUnitType="pic_parameter_set_rbsp";break;case 9:W.nalUnitType="access_unit_delimiter_rbsp";break}w.trigger("data",W)}),S.on("done",function(){w.trigger("done")}),S.on("partialdone",function(){w.trigger("partialdone")}),S.on("reset",function(){w.trigger("reset")}),S.on("endedtimeline",function(){w.trigger("endedtimeline")}),this.flush=function(){S.flush()},this.partialFlush=function(){S.partialFlush()},this.reset=function(){S.reset()},this.endTimeline=function(){S.endTimeline()},z=function(G,W){var Y=8,ee=8,Te,le;for(Te=0;Te>4;return E=E>=0?E:0,P?E+20:E+10},a3=function(S,w){return S.length-w<10||S[w]!==73||S[w+1]!==68||S[w+2]!==51?w:(w+=n3(S,w),a3(S,w))},PX=function(S){var w=a3(S,0);return S.length>=w+2&&(S[w]&255)===255&&(S[w+1]&240)===240&&(S[w+1]&22)===16},s3=function(S){return S[0]<<21|S[1]<<14|S[2]<<7|S[3]},MX=function(S,w,E){var A,P="";for(A=w;A>5,A=S[w+4]<<3,P=S[w+3]&6144;return P|A|E},RX=function(S,w){return S[w]===73&&S[w+1]===68&&S[w+2]===51?"timed-metadata":S[w]&!0&&(S[w+1]&240)===240?"audio":null},OX=function(S){for(var w=0;w+5>>2]}return null},NX=function(S){var w,E,A,P;w=10,S[5]&64&&(w+=4,w+=s3(S.subarray(10,14)));do{if(E=s3(S.subarray(w+4,w+8)),E<1)return null;if(P=String.fromCharCode(S[w],S[w+1],S[w+2],S[w+3]),P==="PRIV"){A=S.subarray(w+10,w+E+10);for(var k=0;k>>2;return G*=4,G+=z[7]&3,G}break}}w+=10,w+=E}while(w=3;){if(S[P]===73&&S[P+1]===68&&S[P+2]===51){if(S.length-P<10||(A=o3.parseId3TagSize(S,P),P+A>S.length))break;V={type:"timed-metadata",data:S.subarray(P,P+A)},this.trigger("data",V),P+=A;continue}else if((S[P]&255)===255&&(S[P+1]&240)===240){if(S.length-P<7||(A=o3.parseAdtsSize(S,P),P+A>S.length))break;z={type:"audio",data:S.subarray(P,P+A),pts:w,dts:w},this.trigger("data",z),P+=A;continue}P++}k=S.length-P,k>0?S=S.subarray(P):S=new Uint8Array},this.reset=function(){S=new Uint8Array,this.trigger("reset")},this.endTimeline=function(){S=new Uint8Array,this.trigger("endedtimeline")}},Ig.prototype=new BX;var FX=Ig,UX=["audioobjecttype","channelcount","samplerate","samplingfrequencyindex","samplesize"],VX=UX,zX=["width","height","profileIdc","levelIdc","profileCompatibility","sarRatio"],GX=zX,Pg=t,Zf=Fe,Qf=wt,Mg=gl,ta=Ve,ps=TX,Lg=Nt,l3=CX,HX=EX.H264Stream,$X=FX,WX=$1.isLikelyAacData,qX=Nt.ONE_SECOND_IN_TS,W1=VX,q1=GX,Jf,Sc,kg,yl,jX=function(S,w){w.stream=S,this.trigger("log",w)},u3=function(S,w){for(var E=Object.keys(w),A=0;A=-W&&ee<=G&&(!Te||Y>ee)&&(Te=je,Y=ee)));return Te?Te.gop:null},this.alignGopsAtStart_=function(z){var G,W,Y,ee,Te,le,je,Je;for(Te=z.byteLength,le=z.nalCount,je=z.duration,G=W=0;GY.pts){G++;continue}W++,Te-=ee.byteLength,le-=ee.nalCount,je-=ee.duration}return W===0?z:W===z.length?null:(Je=z.slice(W),Je.byteLength=Te,Je.duration=je,Je.nalCount=le,Je.pts=Je[0].pts,Je.dts=Je[0].dts,Je)},this.alignGopsAtEnd_=function(z){var G,W,Y,ee,Te,le;for(G=P.length-1,W=z.length-1,Te=null,le=!1;G>=0&&W>=0;){if(Y=P[G],ee=z[W],Y.pts===ee.pts){le=!0;break}if(Y.pts>ee.pts){G--;continue}G===P.length-1&&(Te=W),W--}if(!le&&Te===null)return null;var je;if(le?je=W:je=Te,je===0)return z;var Je=z.slice(je),Ir=Je.reduce(function(Tn,bl){return Tn.byteLength+=bl.byteLength,Tn.duration+=bl.duration,Tn.nalCount+=bl.nalCount,Tn},{byteLength:0,duration:0,nalCount:0});return Je.byteLength=Ir.byteLength,Je.duration=Ir.duration,Je.nalCount=Ir.nalCount,Je.pts=Je[0].pts,Je.dts=Je[0].dts,Je},this.alignGopsWith=function(z){P=z}},Jf.prototype=new Pg,yl=function(S,w){this.numberOfTracks=0,this.metadataStream=w,S=S||{},typeof S.remux<"u"?this.remuxTracks=!!S.remux:this.remuxTracks=!0,typeof S.keepOriginalTimestamps=="boolean"?this.keepOriginalTimestamps=S.keepOriginalTimestamps:this.keepOriginalTimestamps=!1,this.pendingTracks=[],this.videoTrack=null,this.pendingBoxes=[],this.pendingCaptions=[],this.pendingMetadata=[],this.pendingBytes=0,this.emittedTracks=0,yl.prototype.init.call(this),this.push=function(E){if(E.content||E.text)return this.pendingCaptions.push(E);if(E.frames)return this.pendingMetadata.push(E);this.pendingTracks.push(E.track),this.pendingBytes+=E.boxes.byteLength,E.track.type==="video"&&(this.videoTrack=E.track,this.pendingBoxes.push(E.boxes)),E.track.type==="audio"&&(this.audioTrack=E.track,this.pendingBoxes.unshift(E.boxes))}},yl.prototype=new Pg,yl.prototype.flush=function(S){var w=0,E={captions:[],captionStreams:{},metadata:[],info:{}},A,P,k,V=0,z;if(this.pendingTracks.length=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0);return}}if(this.videoTrack?(V=this.videoTrack.timelineStartInfo.pts,q1.forEach(function(G){E.info[G]=this.videoTrack[G]},this)):this.audioTrack&&(V=this.audioTrack.timelineStartInfo.pts,W1.forEach(function(G){E.info[G]=this.audioTrack[G]},this)),this.videoTrack||this.audioTrack){for(this.pendingTracks.length===1?E.type=this.pendingTracks[0].type:E.type="combined",this.emittedTracks+=this.pendingTracks.length,k=Zf.initSegment(this.pendingTracks),E.initSegment=new Uint8Array(k.byteLength),E.initSegment.set(k),E.data=new Uint8Array(this.pendingBytes),z=0;z=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0)},yl.prototype.setRemux=function(S){this.remuxTracks=S},kg=function(S){var w=this,E=!0,A,P;kg.prototype.init.call(this),S=S||{},this.baseMediaDecodeTime=S.baseMediaDecodeTime||0,this.transmuxPipeline_={},this.setupAacPipeline=function(){var k={};this.transmuxPipeline_=k,k.type="aac",k.metadataStream=new ps.MetadataStream,k.aacStream=new $X,k.audioTimestampRolloverStream=new ps.TimestampRolloverStream("audio"),k.timedMetadataTimestampRolloverStream=new ps.TimestampRolloverStream("timed-metadata"),k.adtsStream=new l3,k.coalesceStream=new yl(S,k.metadataStream),k.headOfPipeline=k.aacStream,k.aacStream.pipe(k.audioTimestampRolloverStream).pipe(k.adtsStream),k.aacStream.pipe(k.timedMetadataTimestampRolloverStream).pipe(k.metadataStream).pipe(k.coalesceStream),k.metadataStream.on("timestamp",function(V){k.aacStream.setTimestamp(V.timeStamp)}),k.aacStream.on("data",function(V){V.type!=="timed-metadata"&&V.type!=="audio"||k.audioSegmentStream||(P=P||{timelineStartInfo:{baseMediaDecodeTime:w.baseMediaDecodeTime},codec:"adts",type:"audio"},k.coalesceStream.numberOfTracks++,k.audioSegmentStream=new Sc(P,S),k.audioSegmentStream.on("log",w.getLogTrigger_("audioSegmentStream")),k.audioSegmentStream.on("timingInfo",w.trigger.bind(w,"audioTimingInfo")),k.adtsStream.pipe(k.audioSegmentStream).pipe(k.coalesceStream),w.trigger("trackinfo",{hasAudio:!!P,hasVideo:!!A}))}),k.coalesceStream.on("data",this.trigger.bind(this,"data")),k.coalesceStream.on("done",this.trigger.bind(this,"done")),u3(this,k)},this.setupTsPipeline=function(){var k={};this.transmuxPipeline_=k,k.type="ts",k.metadataStream=new ps.MetadataStream,k.packetStream=new ps.TransportPacketStream,k.parseStream=new ps.TransportParseStream,k.elementaryStream=new ps.ElementaryStream,k.timestampRolloverStream=new ps.TimestampRolloverStream,k.adtsStream=new l3,k.h264Stream=new HX,k.captionStream=new ps.CaptionStream(S),k.coalesceStream=new yl(S,k.metadataStream),k.headOfPipeline=k.packetStream,k.packetStream.pipe(k.parseStream).pipe(k.elementaryStream).pipe(k.timestampRolloverStream),k.timestampRolloverStream.pipe(k.h264Stream),k.timestampRolloverStream.pipe(k.adtsStream),k.timestampRolloverStream.pipe(k.metadataStream).pipe(k.coalesceStream),k.h264Stream.pipe(k.captionStream).pipe(k.coalesceStream),k.elementaryStream.on("data",function(V){var z;if(V.type==="metadata"){for(z=V.tracks.length;z--;)!A&&V.tracks[z].type==="video"?(A=V.tracks[z],A.timelineStartInfo.baseMediaDecodeTime=w.baseMediaDecodeTime):!P&&V.tracks[z].type==="audio"&&(P=V.tracks[z],P.timelineStartInfo.baseMediaDecodeTime=w.baseMediaDecodeTime);A&&!k.videoSegmentStream&&(k.coalesceStream.numberOfTracks++,k.videoSegmentStream=new Jf(A,S),k.videoSegmentStream.on("log",w.getLogTrigger_("videoSegmentStream")),k.videoSegmentStream.on("timelineStartInfo",function(G){P&&!S.keepOriginalTimestamps&&(P.timelineStartInfo=G,k.audioSegmentStream.setEarliestDts(G.dts-w.baseMediaDecodeTime))}),k.videoSegmentStream.on("processedGopsInfo",w.trigger.bind(w,"gopInfo")),k.videoSegmentStream.on("segmentTimingInfo",w.trigger.bind(w,"videoSegmentTimingInfo")),k.videoSegmentStream.on("baseMediaDecodeTime",function(G){P&&k.audioSegmentStream.setVideoBaseMediaDecodeTime(G)}),k.videoSegmentStream.on("timingInfo",w.trigger.bind(w,"videoTimingInfo")),k.h264Stream.pipe(k.videoSegmentStream).pipe(k.coalesceStream)),P&&!k.audioSegmentStream&&(k.coalesceStream.numberOfTracks++,k.audioSegmentStream=new Sc(P,S),k.audioSegmentStream.on("log",w.getLogTrigger_("audioSegmentStream")),k.audioSegmentStream.on("timingInfo",w.trigger.bind(w,"audioTimingInfo")),k.audioSegmentStream.on("segmentTimingInfo",w.trigger.bind(w,"audioSegmentTimingInfo")),k.adtsStream.pipe(k.audioSegmentStream).pipe(k.coalesceStream)),w.trigger("trackinfo",{hasAudio:!!P,hasVideo:!!A})}}),k.coalesceStream.on("data",this.trigger.bind(this,"data")),k.coalesceStream.on("id3Frame",function(V){V.dispatchType=k.metadataStream.dispatchType,w.trigger("id3Frame",V)}),k.coalesceStream.on("caption",this.trigger.bind(this,"caption")),k.coalesceStream.on("done",this.trigger.bind(this,"done")),u3(this,k)},this.setBaseMediaDecodeTime=function(k){var V=this.transmuxPipeline_;S.keepOriginalTimestamps||(this.baseMediaDecodeTime=k),P&&(P.timelineStartInfo.dts=void 0,P.timelineStartInfo.pts=void 0,ta.clearDtsInfo(P),V.audioTimestampRolloverStream&&V.audioTimestampRolloverStream.discontinuity()),A&&(V.videoSegmentStream&&(V.videoSegmentStream.gopCache_=[]),A.timelineStartInfo.dts=void 0,A.timelineStartInfo.pts=void 0,ta.clearDtsInfo(A),V.captionStream.reset()),V.timestampRolloverStream&&V.timestampRolloverStream.discontinuity()},this.setAudioAppendStart=function(k){P&&this.transmuxPipeline_.audioSegmentStream.setAudioAppendStart(k)},this.setRemux=function(k){var V=this.transmuxPipeline_;S.remux=k,V&&V.coalesceStream&&V.coalesceStream.setRemux(k)},this.alignGopsWith=function(k){A&&this.transmuxPipeline_.videoSegmentStream&&this.transmuxPipeline_.videoSegmentStream.alignGopsWith(k)},this.getLogTrigger_=function(k){var V=this;return function(z){z.stream=k,V.trigger("log",z)}},this.push=function(k){if(E){var V=WX(k);V&&this.transmuxPipeline_.type!=="aac"?this.setupAacPipeline():!V&&this.transmuxPipeline_.type!=="ts"&&this.setupTsPipeline(),E=!1}this.transmuxPipeline_.headOfPipeline.push(k)},this.flush=function(){E=!0,this.transmuxPipeline_.headOfPipeline.flush()},this.endTimeline=function(){this.transmuxPipeline_.headOfPipeline.endTimeline()},this.reset=function(){this.transmuxPipeline_.headOfPipeline&&this.transmuxPipeline_.headOfPipeline.reset()},this.resetCaptions=function(){this.transmuxPipeline_.captionStream&&this.transmuxPipeline_.captionStream.reset()}},kg.prototype=new Pg;var XX={Transmuxer:kg,VideoSegmentStream:Jf,AudioSegmentStream:Sc,AUDIO_PROPERTIES:W1,VIDEO_PROPERTIES:q1,generateSegmentTimingInfo:j1},YX=function(S){return S>>>0},KX=function(S){return("00"+S.toString(16)).slice(-2)},Rg={toUnsigned:YX,toHexString:KX},ZX=function(S){var w="";return w+=String.fromCharCode(S[0]),w+=String.fromCharCode(S[1]),w+=String.fromCharCode(S[2]),w+=String.fromCharCode(S[3]),w},h3=ZX,QX=Rg.toUnsigned,JX=h3,f3=function(S,w){var E=[],A,P,k,V,z;if(!w.length)return null;for(A=0;A1?A+P:S.byteLength,k===w[0]&&(w.length===1?E.push(S.subarray(A+8,V)):(z=f3(S.subarray(A+8,V),w.slice(1)),z.length&&(E=E.concat(z)))),A=V;return E},d3=f3,eY=Rg.toUnsigned,tY=a.getUint64,rY=function(S){var w={version:S[0],flags:new Uint8Array(S.subarray(1,4))};return w.version===1?w.baseMediaDecodeTime=tY(S.subarray(4)):w.baseMediaDecodeTime=eY(S[4]<<24|S[5]<<16|S[6]<<8|S[7]),w},p3=rY,iY=function(S){return{isLeading:(S[0]&12)>>>2,dependsOn:S[0]&3,isDependedOn:(S[1]&192)>>>6,hasRedundancy:(S[1]&48)>>>4,paddingValue:(S[1]&14)>>>1,isNonSyncSample:S[1]&1,degradationPriority:S[2]<<8|S[3]}},nY=iY,v3=nY,aY=function(S){var w={version:S[0],flags:new Uint8Array(S.subarray(1,4)),samples:[]},E=new DataView(S.buffer,S.byteOffset,S.byteLength),A=w.flags[2]&1,P=w.flags[2]&4,k=w.flags[1]&1,V=w.flags[1]&2,z=w.flags[1]&4,G=w.flags[1]&8,W=E.getUint32(4),Y=8,ee;for(A&&(w.dataOffset=E.getInt32(Y),Y+=4),P&&W&&(ee={flags:v3(S.subarray(Y,Y+4))},Y+=4,k&&(ee.duration=E.getUint32(Y),Y+=4),V&&(ee.size=E.getUint32(Y),Y+=4),G&&(w.version===1?ee.compositionTimeOffset=E.getInt32(Y):ee.compositionTimeOffset=E.getUint32(Y),Y+=4),w.samples.push(ee),W--);W--;)ee={},k&&(ee.duration=E.getUint32(Y),Y+=4),V&&(ee.size=E.getUint32(Y),Y+=4),z&&(ee.flags=v3(S.subarray(Y,Y+4)),Y+=4),G&&(w.version===1?ee.compositionTimeOffset=E.getInt32(Y):ee.compositionTimeOffset=E.getUint32(Y),Y+=4),w.samples.push(ee);return w},g3=aY,sY=function(S){var w=new DataView(S.buffer,S.byteOffset,S.byteLength),E={version:S[0],flags:new Uint8Array(S.subarray(1,4)),trackId:w.getUint32(4)},A=E.flags[2]&1,P=E.flags[2]&2,k=E.flags[2]&8,V=E.flags[2]&16,z=E.flags[2]&32,G=E.flags[0]&65536,W=E.flags[0]&131072,Y;return Y=8,A&&(Y+=4,E.baseDataOffset=w.getUint32(12),Y+=4),P&&(E.sampleDescriptionIndex=w.getUint32(Y),Y+=4),k&&(E.defaultSampleDuration=w.getUint32(Y),Y+=4),V&&(E.defaultSampleSize=w.getUint32(Y),Y+=4),z&&(E.defaultSampleFlags=w.getUint32(Y)),G&&(E.durationIsEmpty=!0),!A&&W&&(E.baseDataOffsetIsMoof=!0),E},m3=sY,ed;typeof window<"u"?ed=window:typeof r<"u"?ed=r:typeof self<"u"?ed=self:ed={};var y3=ed,oY=nt.discardEmulationPreventionBytes,lY=XE.CaptionStream,td=d3,uY=p3,cY=g3,hY=m3,_3=y3,fY=function(S,w){for(var E=S,A=0;A0?uY(Te[0]).baseMediaDecodeTime:0,je=td(G,["trun"]),Je,Ir;w===ee&&je.length>0&&(Je=pY(je,le,Y),Ir=dY(z,Je,ee),P[ee]||(P[ee]={seiNals:[],logs:[]}),P[ee].seiNals=P[ee].seiNals.concat(Ir.seiNals),P[ee].logs=P[ee].logs.concat(Ir.logs))}),P},gY=function(S,w,E){var A;if(w===null)return null;A=vY(S,w);var P=A[w]||{};return{seiNals:P.seiNals,logs:P.logs,timescale:E}},mY=function(){var S=!1,w,E,A,P,k,V;this.isInitialized=function(){return S},this.init=function(z){w=new lY,S=!0,V=z?z.isPartial:!1,w.on("data",function(G){G.startTime=G.startPts/P,G.endTime=G.endPts/P,k.captions.push(G),k.captionStreams[G.stream]=!0}),w.on("log",function(G){k.logs.push(G)})},this.isNewInit=function(z,G){return z&&z.length===0||G&&typeof G=="object"&&Object.keys(G).length===0?!1:A!==z[0]||P!==G[A]},this.parse=function(z,G,W){var Y;if(this.isInitialized()){if(!G||!W)return null;if(this.isNewInit(G,W))A=G[0],P=W[A];else if(A===null||!P)return E.push(z),null}else return null;for(;E.length>0;){var ee=E.shift();this.parse(ee,G,W)}return Y=gY(z,A,P),Y&&Y.logs&&(k.logs=k.logs.concat(Y.logs)),Y===null||!Y.seiNals?k.logs.length?{logs:k.logs,captions:[],captionStreams:[]}:null:(this.pushNals(Y.seiNals),this.flushStream(),k)},this.pushNals=function(z){if(!this.isInitialized()||!z||z.length===0)return null;z.forEach(function(G){w.push(G)})},this.flushStream=function(){if(!this.isInitialized())return null;V?w.partialFlush():w.flush()},this.clearParsedCaptions=function(){k.captions=[],k.captionStreams={},k.logs=[]},this.resetCaptionStream=function(){if(!this.isInitialized())return null;w.reset()},this.clearAllCaptions=function(){this.clearParsedCaptions(),this.resetCaptionStream()},this.reset=function(){E=[],A=null,P=null,k?this.clearParsedCaptions():k={captions:[],captionStreams:{},logs:[]},this.resetCaptionStream()},this.reset()},yY=mY,_Y=function(S){for(var w=0,E=String.fromCharCode(S[w]),A="";E!=="\0";)A+=E,w++,E=String.fromCharCode(S[w]);return A+=E,A},bY={uint8ToCString:_Y},Og=bY.uint8ToCString,SY=a.getUint64,TY=function(S){var w=4,E=S[0],A,P,k,V,z,G,W,Y;if(E===0){A=Og(S.subarray(w)),w+=A.length,P=Og(S.subarray(w)),w+=P.length;var ee=new DataView(S.buffer);k=ee.getUint32(w),w+=4,z=ee.getUint32(w),w+=4,G=ee.getUint32(w),w+=4,W=ee.getUint32(w),w+=4}else if(E===1){var ee=new DataView(S.buffer);k=ee.getUint32(w),w+=4,V=SY(S.subarray(w)),w+=8,G=ee.getUint32(w),w+=4,W=ee.getUint32(w),w+=4,A=Og(S.subarray(w)),w+=A.length,P=Og(S.subarray(w)),w+=P.length}Y=new Uint8Array(S.subarray(w,S.byteLength));var Te={scheme_id_uri:A,value:P,timescale:k||1,presentation_time:V,presentation_time_delta:z,event_duration:G,id:W,message_data:Y};return wY(E,Te)?Te:void 0},xY=function(S,w,E,A){return S||S===0?S/w:A+E/w},wY=function(S,w){var E=w.scheme_id_uri!=="\0",A=S===0&&b3(w.presentation_time_delta)&&E,P=S===1&&b3(w.presentation_time)&&E;return!(S>1)&&A||P},b3=function(S){return S!==void 0||S!==null},CY={parseEmsgBox:TY,scaleTime:xY},Ng=Rg.toUnsigned,rd=Rg.toHexString,cr=d3,Tc=h3,X1=CY,AY=m3,DY=g3,EY=p3,IY=a.getUint64,S3,T3,x3,w3,C3,Y1,A3,K1=y3,PY=QE.parseId3Frames;S3=function(S){var w={},E=cr(S,["moov","trak"]);return E.reduce(function(A,P){var k,V,z,G,W;return k=cr(P,["tkhd"])[0],!k||(V=k[0],z=V===0?12:20,G=Ng(k[z]<<24|k[z+1]<<16|k[z+2]<<8|k[z+3]),W=cr(P,["mdia","mdhd"])[0],!W)?null:(V=W[0],z=V===0?12:20,A[G]=Ng(W[z]<<24|W[z+1]<<16|W[z+2]<<8|W[z+3]),A)},w)},T3=function(S,w){var E;E=cr(w,["moof","traf"]);var A=E.reduce(function(P,k){var V=cr(k,["tfhd"])[0],z=Ng(V[4]<<24|V[5]<<16|V[6]<<8|V[7]),G=S[z]||9e4,W=cr(k,["tfdt"])[0],Y=new DataView(W.buffer,W.byteOffset,W.byteLength),ee;W[0]===1?ee=IY(W.subarray(4,12)):ee=Y.getUint32(4);let Te;return typeof ee=="bigint"?Te=ee/K1.BigInt(G):typeof ee=="number"&&!isNaN(ee)&&(Te=ee/G),Te11?(P.codec+=".",P.codec+=rd(le[9]),P.codec+=rd(le[10]),P.codec+=rd(le[11])):P.codec="avc1.4d400d"):/^mp4[a,v]$/i.test(P.codec)?(le=Te.subarray(28),je=Tc(le.subarray(4,8)),je==="esds"&&le.length>20&&le[19]!==0?(P.codec+="."+rd(le[19]),P.codec+="."+rd(le[20]>>>2&63).replace(/^0/,"")):P.codec="mp4a.40.2"):P.codec=P.codec.toLowerCase())}var Je=cr(A,["mdia","mdhd"])[0];Je&&(P.timescale=Y1(Je)),E.push(P)}),E},A3=function(S,w=0){var E=cr(S,["emsg"]);return E.map(A=>{var P=X1.parseEmsgBox(new Uint8Array(A)),k=PY(P.message_data);return{cueTime:X1.scaleTime(P.presentation_time,P.timescale,P.presentation_time_delta,w),duration:X1.scaleTime(P.event_duration,P.timescale),frames:k}})};var Z1={findBox:cr,parseType:Tc,timescale:S3,startTime:T3,compositionStartTime:x3,videoTrackIds:w3,tracks:C3,getTimescaleFromMediaHeader:Y1,getEmsgID3:A3},Q1=Sg,D3=function(S){var w=S[1]&31;return w<<=8,w|=S[2],w},Bg=function(S){return!!(S[1]&64)},Fg=function(S){var w=0;return(S[3]&48)>>>4>1&&(w+=S[4]+1),w},MY=function(S,w){var E=D3(S);return E===0?"pat":E===w?"pmt":w?"pes":null},LY=function(S){var w=Bg(S),E=4+Fg(S);return w&&(E+=S[E]+1),(S[E+10]&31)<<8|S[E+11]},kY=function(S){var w={},E=Bg(S),A=4+Fg(S);if(E&&(A+=S[A]+1),!!(S[A+5]&1)){var P,k,V;P=(S[A+1]&15)<<8|S[A+2],k=3+P-4,V=(S[A+10]&15)<<8|S[A+11];for(var z=12+V;z=S.byteLength)return null;var A=null,P;return P=S[E+7],P&192&&(A={},A.pts=(S[E+9]&14)<<27|(S[E+10]&255)<<20|(S[E+11]&254)<<12|(S[E+12]&255)<<5|(S[E+13]&254)>>>3,A.pts*=4,A.pts+=(S[E+13]&6)>>>1,A.dts=A.pts,P&64&&(A.dts=(S[E+14]&14)<<27|(S[E+15]&255)<<20|(S[E+16]&254)<<12|(S[E+17]&255)<<5|(S[E+18]&254)>>>3,A.dts*=4,A.dts+=(S[E+18]&6)>>>1)),A},J1=function(S){switch(S){case 5:return"slice_layer_without_partitioning_rbsp_idr";case 6:return"sei_rbsp";case 7:return"seq_parameter_set_rbsp";case 8:return"pic_parameter_set_rbsp";case 9:return"access_unit_delimiter_rbsp";default:return null}},NY=function(S){for(var w=4+Fg(S),E=S.subarray(w),A=0,P=0,k=!1,V;P3&&(V=J1(E[P+3]&31),V==="slice_layer_without_partitioning_rbsp_idr"&&(k=!0)),k},BY={parseType:MY,parsePat:LY,parsePmt:kY,parsePayloadUnitStartIndicator:Bg,parsePesType:RY,parsePesTime:OY,videoPacketContainsKeyFrame:NY},E3=Sg,xc=KE.handleRollover,Mt={};Mt.ts=BY,Mt.aac=$1;var _l=Nt.ONE_SECOND_IN_TS,hi=188,wa=71,FY=function(S,w){for(var E=0,A=hi,P,k;A=0;){if(S[A]===wa&&(S[P]===wa||P===S.byteLength)){switch(k=S.subarray(A,P),V=Mt.ts.parseType(k,w.pid),V){case"pes":z=Mt.ts.parsePesType(k,w.table),G=Mt.ts.parsePayloadUnitStartIndicator(k),z==="audio"&&G&&(W=Mt.ts.parsePesTime(k),W&&(W.type="audio",E.audio.push(W),Y=!0));break}if(Y)break;A-=hi,P-=hi;continue}A--,P--}},UY=function(S,w,E){for(var A=0,P=hi,k,V,z,G,W,Y,ee,Te,le=!1,je={data:[],size:0};P=0;){if(S[A]===wa&&S[P]===wa){switch(k=S.subarray(A,P),V=Mt.ts.parseType(k,w.pid),V){case"pes":z=Mt.ts.parsePesType(k,w.table),G=Mt.ts.parsePayloadUnitStartIndicator(k),z==="video"&&G&&(W=Mt.ts.parsePesTime(k),W&&(W.type="video",E.video.push(W),le=!0));break}if(le)break;A-=hi,P-=hi;continue}A--,P--}},VY=function(S,w){if(S.audio&&S.audio.length){var E=w;(typeof E>"u"||isNaN(E))&&(E=S.audio[0].dts),S.audio.forEach(function(k){k.dts=xc(k.dts,E),k.pts=xc(k.pts,E),k.dtsTime=k.dts/_l,k.ptsTime=k.pts/_l})}if(S.video&&S.video.length){var A=w;if((typeof A>"u"||isNaN(A))&&(A=S.video[0].dts),S.video.forEach(function(k){k.dts=xc(k.dts,A),k.pts=xc(k.pts,A),k.dtsTime=k.dts/_l,k.ptsTime=k.pts/_l}),S.firstKeyFrame){var P=S.firstKeyFrame;P.dts=xc(P.dts,A),P.pts=xc(P.pts,A),P.dtsTime=P.dts/_l,P.ptsTime=P.pts/_l}}},zY=function(S){for(var w=!1,E=0,A=null,P=null,k=0,V=0,z;S.length-V>=3;){var G=Mt.aac.parseType(S,V);switch(G){case"timed-metadata":if(S.length-V<10){w=!0;break}if(k=Mt.aac.parseId3TagSize(S,V),k>S.length){w=!0;break}P===null&&(z=S.subarray(V,V+k),P=Mt.aac.parseAacTimestamp(z)),V+=k;break;case"audio":if(S.length-V<7){w=!0;break}if(k=Mt.aac.parseAdtsSize(S,V),k>S.length){w=!0;break}A===null&&(z=S.subarray(V,V+k),A=Mt.aac.parseSampleRate(z)),E++,V+=k;break;default:V++;break}if(w)return null}if(A===null||P===null)return null;var W=_l/A,Y={audio:[{type:"audio",dts:P,pts:P},{type:"audio",dts:P+E*1024*W,pts:P+E*1024*W}]};return Y},GY=function(S){var w={pid:null,table:null},E={};FY(S,w);for(var A in w.table)if(w.table.hasOwnProperty(A)){var P=w.table[A];switch(P){case E3.H264_STREAM_TYPE:E.video=[],UY(S,w,E),E.video.length===0&&delete E.video;break;case E3.ADTS_STREAM_TYPE:E.audio=[],I3(S,w,E),E.audio.length===0&&delete E.audio;break}}return E},HY=function(S,w){var E=Mt.aac.isLikelyAacData(S),A;return E?A=zY(S):A=GY(S),!A||!A.audio&&!A.video?null:(VY(A,w),A)},$Y={inspect:HY,parseAudioPes_:I3};const WY=function(S,w){w.on("data",function(E){const A=E.initSegment;E.initSegment={data:A.buffer,byteOffset:A.byteOffset,byteLength:A.byteLength};const P=E.data;E.data=P.buffer,S.postMessage({action:"data",segment:E,byteOffset:P.byteOffset,byteLength:P.byteLength},[E.data])}),w.on("done",function(E){S.postMessage({action:"done"})}),w.on("gopInfo",function(E){S.postMessage({action:"gopInfo",gopInfo:E})}),w.on("videoSegmentTimingInfo",function(E){const A={start:{decode:Nt.videoTsToSeconds(E.start.dts),presentation:Nt.videoTsToSeconds(E.start.pts)},end:{decode:Nt.videoTsToSeconds(E.end.dts),presentation:Nt.videoTsToSeconds(E.end.pts)},baseMediaDecodeTime:Nt.videoTsToSeconds(E.baseMediaDecodeTime)};E.prependedContentDuration&&(A.prependedContentDuration=Nt.videoTsToSeconds(E.prependedContentDuration)),S.postMessage({action:"videoSegmentTimingInfo",videoSegmentTimingInfo:A})}),w.on("audioSegmentTimingInfo",function(E){const A={start:{decode:Nt.videoTsToSeconds(E.start.dts),presentation:Nt.videoTsToSeconds(E.start.pts)},end:{decode:Nt.videoTsToSeconds(E.end.dts),presentation:Nt.videoTsToSeconds(E.end.pts)},baseMediaDecodeTime:Nt.videoTsToSeconds(E.baseMediaDecodeTime)};E.prependedContentDuration&&(A.prependedContentDuration=Nt.videoTsToSeconds(E.prependedContentDuration)),S.postMessage({action:"audioSegmentTimingInfo",audioSegmentTimingInfo:A})}),w.on("id3Frame",function(E){S.postMessage({action:"id3Frame",id3Frame:E})}),w.on("caption",function(E){S.postMessage({action:"caption",caption:E})}),w.on("trackinfo",function(E){S.postMessage({action:"trackinfo",trackInfo:E})}),w.on("audioTimingInfo",function(E){S.postMessage({action:"audioTimingInfo",audioTimingInfo:{start:Nt.videoTsToSeconds(E.start),end:Nt.videoTsToSeconds(E.end)}})}),w.on("videoTimingInfo",function(E){S.postMessage({action:"videoTimingInfo",videoTimingInfo:{start:Nt.videoTsToSeconds(E.start),end:Nt.videoTsToSeconds(E.end)}})}),w.on("log",function(E){S.postMessage({action:"log",log:E})})};class P3{constructor(w,E){this.options=E||{},this.self=w,this.init()}init(){this.transmuxer&&this.transmuxer.dispose(),this.transmuxer=new XX.Transmuxer(this.options),WY(this.self,this.transmuxer)}pushMp4Captions(w){this.captionParser||(this.captionParser=new yY,this.captionParser.init());const E=new Uint8Array(w.data,w.byteOffset,w.byteLength),A=this.captionParser.parse(E,w.trackIds,w.timescales);this.self.postMessage({action:"mp4Captions",captions:A&&A.captions||[],logs:A&&A.logs||[],data:E.buffer},[E.buffer])}probeMp4StartTime({timescales:w,data:E}){const A=Z1.startTime(w,E);this.self.postMessage({action:"probeMp4StartTime",startTime:A,data:E},[E.buffer])}probeMp4Tracks({data:w}){const E=Z1.tracks(w);this.self.postMessage({action:"probeMp4Tracks",tracks:E,data:w},[w.buffer])}probeEmsgID3({data:w,offset:E}){const A=Z1.getEmsgID3(w,E);this.self.postMessage({action:"probeEmsgID3",id3Frames:A,emsgData:w},[w.buffer])}probeTs({data:w,baseStartTime:E}){const A=typeof E=="number"&&!isNaN(E)?E*Nt.ONE_SECOND_IN_TS:void 0,P=$Y.inspect(w,A);let k=null;P&&(k={hasVideo:P.video&&P.video.length===2||!1,hasAudio:P.audio&&P.audio.length===2||!1},k.hasVideo&&(k.videoStart=P.video[0].ptsTime),k.hasAudio&&(k.audioStart=P.audio[0].ptsTime)),this.self.postMessage({action:"probeTs",result:k,data:w},[w.buffer])}clearAllMp4Captions(){this.captionParser&&this.captionParser.clearAllCaptions()}clearParsedMp4Captions(){this.captionParser&&this.captionParser.clearParsedCaptions()}push(w){const E=new Uint8Array(w.data,w.byteOffset,w.byteLength);this.transmuxer.push(E)}reset(){this.transmuxer.reset()}setTimestampOffset(w){const E=w.timestampOffset||0;this.transmuxer.setBaseMediaDecodeTime(Math.round(Nt.secondsToVideoTs(E)))}setAudioAppendStart(w){this.transmuxer.setAudioAppendStart(Math.ceil(Nt.secondsToVideoTs(w.appendStart)))}setRemux(w){this.transmuxer.setRemux(w.remux)}flush(w){this.transmuxer.flush(),self.postMessage({action:"done",type:"transmuxed"})}endTimeline(){this.transmuxer.endTimeline(),self.postMessage({action:"endedtimeline",type:"transmuxed"})}alignGopsWith(w){this.transmuxer.alignGopsWith(w.gopsToAlignWith.slice())}}self.onmessage=function(S){if(S.data.action==="init"&&S.data.options){this.messageHandlers=new P3(self,S.data.options);return}this.messageHandlers||(this.messageHandlers=new P3(self)),S.data&&S.data.action&&S.data.action!=="init"&&this.messageHandlers[S.data.action]&&this.messageHandlers[S.data.action](S.data)}}));var qre=M9(Wre);const jre=(r,e,t)=>{const{type:i,initSegment:n,captions:a,captionStreams:s,metadata:o,videoFrameDtsTime:l,videoFramePtsTime:u}=r.data.segment;e.buffer.push({captions:a,captionStreams:s,metadata:o});const c=r.data.segment.boxes||{data:r.data.segment.data},h={type:i,data:new Uint8Array(c.data,c.data.byteOffset,c.data.byteLength),initSegment:new Uint8Array(n.data,n.byteOffset,n.byteLength)};typeof l<"u"&&(h.videoFrameDtsTime=l),typeof u<"u"&&(h.videoFramePtsTime=u),t(h)},Xre=({transmuxedData:r,callback:e})=>{r.buffer=[],e(r)},Yre=(r,e)=>{e.gopInfo=r.data.gopInfo},R9=r=>{const{transmuxer:e,bytes:t,audioAppendStart:i,gopsToAlignWith:n,remux:a,onData:s,onTrackInfo:o,onAudioTimingInfo:l,onVideoTimingInfo:u,onVideoSegmentTimingInfo:c,onAudioSegmentTimingInfo:h,onId3:d,onCaptions:f,onDone:p,onEndedTimeline:v,onTransmuxerLog:g,isEndOfTimeline:m,segment:y,triggerSegmentEventFn:_}=r,b={buffer:[]};let T=m;const x=D=>{e.currentTransmux===r&&(D.data.action==="data"&&jre(D,b,s),D.data.action==="trackinfo"&&o(D.data.trackInfo),D.data.action==="gopInfo"&&Yre(D,b),D.data.action==="audioTimingInfo"&&l(D.data.audioTimingInfo),D.data.action==="videoTimingInfo"&&u(D.data.videoTimingInfo),D.data.action==="videoSegmentTimingInfo"&&c(D.data.videoSegmentTimingInfo),D.data.action==="audioSegmentTimingInfo"&&h(D.data.audioSegmentTimingInfo),D.data.action==="id3Frame"&&d([D.data.id3Frame],D.data.id3Frame.dispatchType),D.data.action==="caption"&&f(D.data.caption),D.data.action==="endedtimeline"&&(T=!1,v()),D.data.action==="log"&&g(D.data.log),D.data.type==="transmuxed"&&(T||(e.onmessage=null,Xre({transmuxedData:b,callback:p}),O9(e))))},C=()=>{const D={message:"Received an error message from the transmuxer worker",metadata:{errorType:K.Error.StreamingFailedToTransmuxSegment,segmentInfo:au({segment:y})}};p(null,D)};if(e.onmessage=x,e.onerror=C,i&&e.postMessage({action:"setAudioAppendStart",appendStart:i}),Array.isArray(n)&&e.postMessage({action:"alignGopsWith",gopsToAlignWith:n}),typeof a<"u"&&e.postMessage({action:"setRemux",remux:a}),t.byteLength){const D=t instanceof ArrayBuffer?t:t.buffer,I=t instanceof ArrayBuffer?0:t.byteOffset;_({type:"segmenttransmuxingstart",segment:y}),e.postMessage({action:"push",data:D,byteOffset:I,byteLength:t.byteLength},[D])}m&&e.postMessage({action:"endTimeline"}),e.postMessage({action:"flush"})},O9=r=>{r.currentTransmux=null,r.transmuxQueue.length&&(r.currentTransmux=r.transmuxQueue.shift(),typeof r.currentTransmux=="function"?r.currentTransmux():R9(r.currentTransmux))},c4=(r,e)=>{r.postMessage({action:e}),O9(r)},N9=(r,e)=>{if(!e.currentTransmux){e.currentTransmux=r,c4(e,r);return}e.transmuxQueue.push(c4.bind(null,e,r))},Kre=r=>{N9("reset",r)},Zre=r=>{N9("endTimeline",r)},B9=r=>{if(!r.transmuxer.currentTransmux){r.transmuxer.currentTransmux=r,R9(r);return}r.transmuxer.transmuxQueue.push(r)},Qre=r=>{const e=new qre;e.currentTransmux=null,e.transmuxQueue=[];const t=e.terminate;return e.terminate=()=>(e.currentTransmux=null,e.transmuxQueue.length=0,t.call(e)),e.postMessage({action:"init",options:r}),e};var C2={reset:Kre,endTimeline:Zre,transmux:B9,createTransmuxer:Qre};const _p=function(r){const e=r.transmuxer,t=r.endAction||r.action,i=r.callback,n=ar({},r,{endAction:null,transmuxer:null,callback:null}),a=s=>{s.data.action===t&&(e.removeEventListener("message",a),s.data.data&&(s.data.data=new Uint8Array(s.data.data,r.byteOffset||0,r.byteLength||s.data.data.byteLength),r.data&&(r.data=s.data.data)),i(s.data))};if(e.addEventListener("message",a),r.data){const s=r.data instanceof ArrayBuffer;n.byteOffset=s?0:r.data.byteOffset,n.byteLength=r.data.byteLength;const o=[s?r.data:r.data.buffer];e.postMessage(n,o)}else e.postMessage(n)},Ha={FAILURE:2,TIMEOUT:-101,ABORTED:-102},qT=r=>{r.forEach(e=>{e.abort()})},Jre=r=>({bandwidth:r.bandwidth,bytesReceived:r.bytesReceived||0,roundTripTime:r.roundTripTime||0}),eie=r=>{const e=r.target,i={bandwidth:1/0,bytesReceived:0,roundTripTime:Date.now()-e.requestTime||0};return i.bytesReceived=r.loaded,i.bandwidth=Math.floor(i.bytesReceived/i.roundTripTime*8*1e3),i},gA=(r,e)=>{const{requestType:t}=e,i=Iu({requestType:t,request:e,error:r});return e.timedout?{status:e.status,message:"HLS request timed-out at URL: "+e.uri,code:Ha.TIMEOUT,xhr:e,metadata:i}:e.aborted?{status:e.status,message:"HLS request aborted at URL: "+e.uri,code:Ha.ABORTED,xhr:e,metadata:i}:r?{status:e.status,message:"HLS request errored at URL: "+e.uri,code:Ha.FAILURE,xhr:e,metadata:i}:e.responseType==="arraybuffer"&&e.response.byteLength===0?{status:e.status,message:"Empty HLS response at URL: "+e.uri,code:Ha.FAILURE,xhr:e,metadata:i}:null},h4=(r,e,t,i)=>(n,a)=>{const s=a.response,o=gA(n,a);if(o)return t(o,r);if(s.byteLength!==16)return t({status:a.status,message:"Invalid HLS key at URL: "+a.uri,code:Ha.FAILURE,xhr:a},r);const l=new DataView(s),u=new Uint32Array([l.getUint32(0),l.getUint32(4),l.getUint32(8),l.getUint32(12)]);for(let h=0;h{const t=OC(r.map.bytes);if(t!=="mp4"){const i=r.map.resolvedUri||r.map.uri,n=t||"unknown";return e({internal:!0,message:`Found unsupported ${n} container for initialization segment at URL: ${i}`,code:Ha.FAILURE,metadata:{mediaType:n}})}_p({action:"probeMp4Tracks",data:r.map.bytes,transmuxer:r.transmuxer,callback:({tracks:i,data:n})=>(r.map.bytes=n,i.forEach(function(a){r.map.tracks=r.map.tracks||{},!r.map.tracks[a.type]&&(r.map.tracks[a.type]=a,typeof a.id=="number"&&a.timescale&&(r.map.timescales=r.map.timescales||{},r.map.timescales[a.id]=a.timescale))}),e(null))})},tie=({segment:r,finishProcessingFn:e,triggerSegmentEventFn:t})=>(i,n)=>{const a=gA(i,n);if(a)return e(a,r);const s=new Uint8Array(n.response);if(t({type:"segmentloaded",segment:r}),r.map.key)return r.map.encryptedBytes=s,e(null,r);r.map.bytes=s,F9(r,function(o){if(o)return o.xhr=n,o.status=n.status,e(o,r);e(null,r)})},rie=({segment:r,finishProcessingFn:e,responseType:t,triggerSegmentEventFn:i})=>(n,a)=>{const s=gA(n,a);if(s)return e(s,r);i({type:"segmentloaded",segment:r});const o=t==="arraybuffer"||!a.responseText?a.response:Hre(a.responseText.substring(r.lastReachedChar||0));return r.stats=Jre(a),r.key?r.encryptedBytes=new Uint8Array(o):r.bytes=new Uint8Array(o),e(null,r)},iie=({segment:r,bytes:e,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c,doneFn:h,onTransmuxerLog:d,triggerSegmentEventFn:f})=>{const p=r.map&&r.map.tracks||{},v=!!(p.audio&&p.video);let g=i.bind(null,r,"audio","start");const m=i.bind(null,r,"audio","end");let y=i.bind(null,r,"video","start");const _=i.bind(null,r,"video","end"),b=()=>B9({bytes:e,transmuxer:r.transmuxer,audioAppendStart:r.audioAppendStart,gopsToAlignWith:r.gopsToAlignWith,remux:v,onData:T=>{T.type=T.type==="combined"?"video":T.type,c(r,T)},onTrackInfo:T=>{t&&(v&&(T.isMuxed=!0),t(r,T))},onAudioTimingInfo:T=>{g&&typeof T.start<"u"&&(g(T.start),g=null),m&&typeof T.end<"u"&&m(T.end)},onVideoTimingInfo:T=>{y&&typeof T.start<"u"&&(y(T.start),y=null),_&&typeof T.end<"u"&&_(T.end)},onVideoSegmentTimingInfo:T=>{const x={pts:{start:T.start.presentation,end:T.end.presentation},dts:{start:T.start.decode,end:T.end.decode}};f({type:"segmenttransmuxingtiminginfoavailable",segment:r,timingInfo:x}),n(T)},onAudioSegmentTimingInfo:T=>{const x={pts:{start:T.start.pts,end:T.end.pts},dts:{start:T.start.dts,end:T.end.dts}};f({type:"segmenttransmuxingtiminginfoavailable",segment:r,timingInfo:x}),a(T)},onId3:(T,x)=>{s(r,T,x)},onCaptions:T=>{o(r,[T])},isEndOfTimeline:l,onEndedTimeline:()=>{u()},onTransmuxerLog:d,onDone:(T,x)=>{h&&(T.type=T.type==="combined"?"video":T.type,f({type:"segmenttransmuxingcomplete",segment:r}),h(x,r,T))},segment:r,triggerSegmentEventFn:f});_p({action:"probeTs",transmuxer:r.transmuxer,data:e,baseStartTime:r.baseStartTime,callback:T=>{r.bytes=e=T.data;const x=T.result;x&&(t(r,{hasAudio:x.hasAudio,hasVideo:x.hasVideo,isMuxed:v}),t=null),b()}})},U9=({segment:r,bytes:e,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c,doneFn:h,onTransmuxerLog:d,triggerSegmentEventFn:f})=>{let p=new Uint8Array(e);if(Dee(p)){r.isFmp4=!0;const{tracks:v}=r.map,g={isFmp4:!0,hasVideo:!!v.video,hasAudio:!!v.audio};v.audio&&v.audio.codec&&v.audio.codec!=="enca"&&(g.audioCodec=v.audio.codec),v.video&&v.video.codec&&v.video.codec!=="encv"&&(g.videoCodec=v.video.codec),v.video&&v.audio&&(g.isMuxed=!0),t(r,g);const m=(y,_)=>{c(r,{data:p,type:g.hasAudio&&!g.isMuxed?"audio":"video"}),_&&_.length&&s(r,_),y&&y.length&&o(r,y),h(null,r,{})};_p({action:"probeMp4StartTime",timescales:r.map.timescales,data:p,transmuxer:r.transmuxer,callback:({data:y,startTime:_})=>{e=y.buffer,r.bytes=p=y,g.hasAudio&&!g.isMuxed&&i(r,"audio","start",_),g.hasVideo&&i(r,"video","start",_),_p({action:"probeEmsgID3",data:p,transmuxer:r.transmuxer,offset:_,callback:({emsgData:b,id3Frames:T})=>{if(e=b.buffer,r.bytes=p=b,!v.video||!b.byteLength||!r.transmuxer){m(void 0,T);return}_p({action:"pushMp4Captions",endAction:"mp4Captions",transmuxer:r.transmuxer,data:p,timescales:r.map.timescales,trackIds:[v.video.id],callback:x=>{e=x.data.buffer,r.bytes=p=x.data,x.logs.forEach(function(C){d(It(C,{stream:"mp4CaptionParser"}))}),m(x.captions,T)}})}})}});return}if(!r.transmuxer){h(null,r,{});return}if(typeof r.container>"u"&&(r.container=OC(p)),r.container!=="ts"&&r.container!=="aac"){t(r,{hasAudio:!1,hasVideo:!1}),h(null,r,{});return}iie({segment:r,bytes:e,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c,doneFn:h,onTransmuxerLog:d,triggerSegmentEventFn:f})},V9=function({id:r,key:e,encryptedBytes:t,decryptionWorker:i,segment:n,doneFn:a},s){const o=u=>{if(u.data.source===r){i.removeEventListener("message",o);const c=u.data.decrypted;s(new Uint8Array(c.bytes,c.byteOffset,c.byteLength))}};i.onerror=()=>{const u="An error occurred in the decryption worker",c=au({segment:n}),h={message:u,metadata:{error:new Error(u),errorType:K.Error.StreamingFailedToDecryptSegment,segmentInfo:c,keyInfo:{uri:n.key.resolvedUri||n.map.key.resolvedUri}}};a(h,n)},i.addEventListener("message",o);let l;e.bytes.slice?l=e.bytes.slice():l=new Uint32Array(Array.prototype.slice.call(e.bytes)),i.postMessage(C9({source:r,encrypted:t,key:l,iv:e.iv}),[t.buffer,l.buffer])},nie=({decryptionWorker:r,segment:e,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c,doneFn:h,onTransmuxerLog:d,triggerSegmentEventFn:f})=>{f({type:"segmentdecryptionstart"}),V9({id:e.requestId,key:e.key,encryptedBytes:e.encryptedBytes,decryptionWorker:r,segment:e,doneFn:h},p=>{e.bytes=p,f({type:"segmentdecryptioncomplete",segment:e}),U9({segment:e,bytes:e.bytes,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c,doneFn:h,onTransmuxerLog:d,triggerSegmentEventFn:f})})},aie=({activeXhrs:r,decryptionWorker:e,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c,doneFn:h,onTransmuxerLog:d,triggerSegmentEventFn:f})=>{let p=0,v=!1;return(g,m)=>{if(!v){if(g)return v=!0,qT(r),h(g,m);if(p+=1,p===r.length){const y=function(){if(m.encryptedBytes)return nie({decryptionWorker:e,segment:m,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c,doneFn:h,onTransmuxerLog:d,triggerSegmentEventFn:f});U9({segment:m,bytes:m.bytes,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c,doneFn:h,onTransmuxerLog:d,triggerSegmentEventFn:f})};if(m.endOfAllRequests=Date.now(),m.map&&m.map.encryptedBytes&&!m.map.bytes)return f({type:"segmentdecryptionstart",segment:m}),V9({decryptionWorker:e,id:m.requestId+"-init",encryptedBytes:m.map.encryptedBytes,key:m.map.key,segment:m,doneFn:h},_=>{m.map.bytes=_,f({type:"segmentdecryptioncomplete",segment:m}),F9(m,b=>{if(b)return qT(r),h(b,m);y()})});y()}}}},sie=({loadendState:r,abortFn:e})=>t=>{t.target.aborted&&e&&!r.calledAbortFn&&(e(),r.calledAbortFn=!0)},oie=({segment:r,progressFn:e,trackInfoFn:t,timingInfoFn:i,videoSegmentTimingInfoFn:n,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:o,isEndOfTimeline:l,endedTimelineFn:u,dataFn:c})=>h=>{if(!h.target.aborted)return r.stats=It(r.stats,eie(h)),!r.stats.firstBytesReceivedAt&&r.stats.bytesReceived&&(r.stats.firstBytesReceivedAt=Date.now()),e(h,r)},lie=({xhr:r,xhrOptions:e,decryptionWorker:t,segment:i,abortFn:n,progressFn:a,trackInfoFn:s,timingInfoFn:o,videoSegmentTimingInfoFn:l,audioSegmentTimingInfoFn:u,id3Fn:c,captionsFn:h,isEndOfTimeline:d,endedTimelineFn:f,dataFn:p,doneFn:v,onTransmuxerLog:g,triggerSegmentEventFn:m})=>{const y=[],_=aie({activeXhrs:y,decryptionWorker:t,trackInfoFn:s,timingInfoFn:o,videoSegmentTimingInfoFn:l,audioSegmentTimingInfoFn:u,id3Fn:c,captionsFn:h,isEndOfTimeline:d,endedTimelineFn:f,dataFn:p,doneFn:v,onTransmuxerLog:g,triggerSegmentEventFn:m});if(i.key&&!i.key.bytes){const D=[i.key];i.map&&!i.map.bytes&&i.map.key&&i.map.key.resolvedUri===i.key.resolvedUri&&D.push(i.map.key);const I=It(e,{uri:i.key.resolvedUri,responseType:"arraybuffer",requestType:"segment-key"}),M=h4(i,D,_,m),L={uri:i.key.resolvedUri};m({type:"segmentkeyloadstart",segment:i,keyInfo:L});const N=r(I,M);y.push(N)}if(i.map&&!i.map.bytes){if(i.map.key&&(!i.key||i.key.resolvedUri!==i.map.key.resolvedUri)){const N=It(e,{uri:i.map.key.resolvedUri,responseType:"arraybuffer",requestType:"segment-key"}),O=h4(i,[i.map.key],_,m),B={uri:i.map.key.resolvedUri};m({type:"segmentkeyloadstart",segment:i,keyInfo:B});const F=r(N,O);y.push(F)}const I=It(e,{uri:i.map.resolvedUri,responseType:"arraybuffer",headers:$T(i.map),requestType:"segment-media-initialization"}),M=tie({segment:i,finishProcessingFn:_,triggerSegmentEventFn:m});m({type:"segmentloadstart",segment:i});const L=r(I,M);y.push(L)}const b=It(e,{uri:i.part&&i.part.resolvedUri||i.resolvedUri,responseType:"arraybuffer",headers:$T(i),requestType:"segment"}),T=rie({segment:i,finishProcessingFn:_,responseType:b.responseType,triggerSegmentEventFn:m});m({type:"segmentloadstart",segment:i});const x=r(b,T);x.addEventListener("progress",oie({segment:i,progressFn:a,trackInfoFn:s,timingInfoFn:o,videoSegmentTimingInfoFn:l,audioSegmentTimingInfoFn:u,id3Fn:c,captionsFn:h,isEndOfTimeline:d,endedTimelineFn:f,dataFn:p})),y.push(x);const C={};return y.forEach(D=>{D.addEventListener("loadend",sie({loadendState:C,abortFn:n}))}),()=>qT(y)},uie=Kn("CodecUtils"),cie=function(r){const e=r.attributes||{};if(e.CODECS)return ka(e.CODECS)},z9=(r,e)=>{const t=e.attributes||{};return r&&r.mediaGroups&&r.mediaGroups.AUDIO&&t.AUDIO&&r.mediaGroups.AUDIO[t.AUDIO]},hie=(r,e)=>{if(!z9(r,e))return!0;const t=e.attributes||{},i=r.mediaGroups.AUDIO[t.AUDIO];for(const n in i)if(!i[n].uri&&!i[n].playlists)return!0;return!1},sy=function(r){const e={};return r.forEach(({mediaType:t,type:i,details:n})=>{e[t]=e[t]||[],e[t].push(Y6(`${i}${n}`))}),Object.keys(e).forEach(function(t){if(e[t].length>1){uie(`multiple ${t} codecs found as attributes: ${e[t].join(", ")}. Setting playlist codecs to null so that we wait for mux.js to probe segments for real codecs.`),e[t]=null;return}e[t]=e[t][0]}),e},f4=function(r){let e=0;return r.audio&&e++,r.video&&e++,e},bp=function(r,e){const t=e.attributes||{},i=sy(cie(e)||[]);if(z9(r,e)&&!i.audio&&!hie(r,e)){const n=sy(IQ(r,t.AUDIO)||[]);n.audio&&(i.audio=n.audio)}return i},Wg=Kn("PlaylistSelector"),d4=function(r){if(!r||!r.playlist)return;const e=r.playlist;return JSON.stringify({id:e.id,bandwidth:r.bandwidth,width:r.width,height:r.height,codecs:e.attributes&&e.attributes.CODECS||""})},oy=function(r,e){if(!r)return"";const t=H.getComputedStyle(r);return t?t[e]:""},Ch=function(r,e){const t=r.slice();r.sort(function(i,n){const a=e(i,n);return a===0?t.indexOf(i)-t.indexOf(n):a})},mA=function(r,e){let t,i;return r.attributes.BANDWIDTH&&(t=r.attributes.BANDWIDTH),t=t||H.Number.MAX_VALUE,e.attributes.BANDWIDTH&&(i=e.attributes.BANDWIDTH),i=i||H.Number.MAX_VALUE,t-i},fie=function(r,e){let t,i;return r.attributes.RESOLUTION&&r.attributes.RESOLUTION.width&&(t=r.attributes.RESOLUTION.width),t=t||H.Number.MAX_VALUE,e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width&&(i=e.attributes.RESOLUTION.width),i=i||H.Number.MAX_VALUE,t===i&&r.attributes.BANDWIDTH&&e.attributes.BANDWIDTH?r.attributes.BANDWIDTH-e.attributes.BANDWIDTH:t-i};let G9=function(r,e,t,i,n,a){if(!r)return;const s={bandwidth:e,width:t,height:i,limitRenditionByPlayerDimensions:n};let o=r.playlists;Vi.isAudioOnly(r)&&(o=a.getAudioTrackPlaylists_(),s.audioOnly=!0);let l=o.map(T=>{let x;const C=T.attributes&&T.attributes.RESOLUTION&&T.attributes.RESOLUTION.width,D=T.attributes&&T.attributes.RESOLUTION&&T.attributes.RESOLUTION.height;return x=T.attributes&&T.attributes.BANDWIDTH,x=x||H.Number.MAX_VALUE,{bandwidth:x,width:C,height:D,playlist:T}});Ch(l,(T,x)=>T.bandwidth-x.bandwidth),l=l.filter(T=>!Vi.isIncompatible(T.playlist));let u=l.filter(T=>Vi.isEnabled(T.playlist));u.length||(u=l.filter(T=>!Vi.isDisabled(T.playlist)));const c=u.filter(T=>T.bandwidth*Fr.BANDWIDTH_VARIANCET.bandwidth===h.bandwidth)[0];if(n===!1){const T=d||u[0]||l[0];if(T&&T.playlist){let x="sortedPlaylistReps";return d&&(x="bandwidthBestRep"),u[0]&&(x="enabledPlaylistReps"),Wg(`choosing ${d4(T)} using ${x} with options`,s),T.playlist}return Wg("could not choose a playlist with options",s),null}const f=c.filter(T=>T.width&&T.height);Ch(f,(T,x)=>T.width-x.width);const p=f.filter(T=>T.width===t&&T.height===i);h=p[p.length-1];const v=p.filter(T=>T.bandwidth===h.bandwidth)[0];let g,m,y;v||(g=f.filter(T=>T.width>t||T.height>i),m=g.filter(T=>T.width===g[0].width&&T.height===g[0].height),h=m[m.length-1],y=m.filter(T=>T.bandwidth===h.bandwidth)[0]);let _;if(a.leastPixelDiffSelector){const T=f.map(x=>(x.pixelDiff=Math.abs(x.width-t)+Math.abs(x.height-i),x));Ch(T,(x,C)=>x.pixelDiff===C.pixelDiff?C.bandwidth-x.bandwidth:x.pixelDiff-C.pixelDiff),_=T[0]}const b=_||y||v||d||u[0]||l[0];if(b&&b.playlist){let T="sortedPlaylistReps";return _?T="leastPixelDiffRep":y?T="resolutionPlusOneRep":v?T="resolutionBestRep":d?T="bandwidthBestRep":u[0]&&(T="enabledPlaylistReps"),Wg(`choosing ${d4(b)} using ${T} with options`,s),b.playlist}return Wg("could not choose a playlist with options",s),null};const p4=function(){let r=this.useDevicePixelRatio&&H.devicePixelRatio||1;return isNaN(this.customPixelRatio)||(r=this.customPixelRatio),G9(this.playlists.main,this.systemBandwidth,parseInt(oy(this.tech_.el(),"width"),10)*r,parseInt(oy(this.tech_.el(),"height"),10)*r,this.limitRenditionByPlayerDimensions,this.playlistController_)},die=function(r){let e=-1,t=-1;if(r<0||r>1)throw new Error("Moving average bandwidth decay must be between 0 and 1.");return function(){let i=this.useDevicePixelRatio&&H.devicePixelRatio||1;return isNaN(this.customPixelRatio)||(i=this.customPixelRatio),e<0&&(e=this.systemBandwidth,t=this.systemBandwidth),this.systemBandwidth>0&&this.systemBandwidth!==t&&(e=r*this.systemBandwidth+(1-r)*e,t=this.systemBandwidth),G9(this.playlists.main,e,parseInt(oy(this.tech_.el(),"width"),10)*i,parseInt(oy(this.tech_.el(),"height"),10)*i,this.limitRenditionByPlayerDimensions,this.playlistController_)}},pie=function(r){const{main:e,currentTime:t,bandwidth:i,duration:n,segmentDuration:a,timeUntilRebuffer:s,currentTimeline:o,syncController:l}=r,u=e.playlists.filter(p=>!Vi.isIncompatible(p));let c=u.filter(Vi.isEnabled);c.length||(c=u.filter(p=>!Vi.isDisabled(p)));const d=c.filter(Vi.hasAttribute.bind(null,"BANDWIDTH")).map(p=>{const g=l.getSyncPoint(p,n,o,t)?1:2,y=Vi.estimateSegmentRequestTime(a,i,p)*g-s;return{playlist:p,rebufferingImpact:y}}),f=d.filter(p=>p.rebufferingImpact<=0);return Ch(f,(p,v)=>mA(v.playlist,p.playlist)),f.length?f[0]:(Ch(d,(p,v)=>p.rebufferingImpact-v.rebufferingImpact),d[0]||null)},vie=function(){const r=this.playlists.main.playlists.filter(Vi.isEnabled);return Ch(r,(t,i)=>mA(t,i)),r.filter(t=>!!bp(this.playlists.main,t).video)[0]||null},gie=r=>{let e=0,t;return r.bytes&&(t=new Uint8Array(r.bytes),r.segments.forEach(i=>{t.set(i,e),e+=i.byteLength})),t};function H9(r){try{return new URL(r).pathname.split("/").slice(-2).join("/")}catch{return""}}const mie=function(r,e,t){if(!r[t]){e.trigger({type:"usage",name:"vhs-608"});let i=t;/^cc708_/.test(t)&&(i="SERVICE"+t.split("_")[1]);const n=e.textTracks().getTrackById(i);if(n)r[t]=n;else{const a=e.options_.vhs&&e.options_.vhs.captionServices||{};let s=t,o=t,l=!1;const u=a[i];u&&(s=u.label,o=u.language,l=u.default),r[t]=e.addRemoteTextTrack({kind:"captions",id:i,default:l,label:s,language:o},!1).track}}},yie=function({inbandTextTracks:r,captionArray:e,timestampOffset:t}){if(!e)return;const i=H.WebKitDataCue||H.VTTCue;e.forEach(n=>{const a=n.stream;n.content?n.content.forEach(s=>{const o=new i(n.startTime+t,n.endTime+t,s.text);o.line=s.line,o.align="left",o.position=s.position,o.positionAlign="line-left",r[a].addCue(o)}):r[a].addCue(new i(n.startTime+t,n.endTime+t,n.text))})},_ie=function(r){Object.defineProperties(r.frame,{id:{get(){return K.log.warn("cue.frame.id is deprecated. Use cue.value.key instead."),r.value.key}},value:{get(){return K.log.warn("cue.frame.value is deprecated. Use cue.value.data instead."),r.value.data}},privateData:{get(){return K.log.warn("cue.frame.privateData is deprecated. Use cue.value.data instead."),r.value.data}}})},bie=({inbandTextTracks:r,metadataArray:e,timestampOffset:t,videoDuration:i})=>{if(!e)return;const n=H.WebKitDataCue||H.VTTCue,a=r.metadataTrack_;if(!a||(e.forEach(c=>{const h=c.cueTime+t;typeof h!="number"||H.isNaN(h)||h<0||!(h<1/0)||!c.frames||!c.frames.length||c.frames.forEach(d=>{const f=new n(h,h,d.value||d.url||d.data||"");f.frame=d,f.value=d,_ie(f),a.addCue(f)})}),!a.cues||!a.cues.length))return;const s=a.cues,o=[];for(let c=0;c{const d=c[h.startTime]||[];return d.push(h),c[h.startTime]=d,c},{}),u=Object.keys(l).sort((c,h)=>Number(c)-Number(h));u.forEach((c,h)=>{const d=l[c],f=isFinite(i)?i:c,p=Number(u[h+1])||f;d.forEach(v=>{v.endTime=p})})},Sie={id:"ID",class:"CLASS",startDate:"START-DATE",duration:"DURATION",endDate:"END-DATE",endOnNext:"END-ON-NEXT",plannedDuration:"PLANNED-DURATION",scte35Out:"SCTE35-OUT",scte35In:"SCTE35-IN"},Tie=new Set(["id","class","startDate","duration","endDate","endOnNext","startTime","endTime","processDateRange"]),xie=({inbandTextTracks:r,dateRanges:e})=>{const t=r.metadataTrack_;if(!t)return;const i=H.WebKitDataCue||H.VTTCue;e.forEach(n=>{for(const a of Object.keys(n)){if(Tie.has(a))continue;const s=new i(n.startTime,n.endTime,"");s.id=n.id,s.type="com.apple.quicktime.HLS",s.value={key:Sie[a],data:n[a]},(a==="scte35Out"||a==="scte35In")&&(s.value.data=new Uint8Array(s.value.data.match(/[\da-f]{2}/gi)).buffer),t.addCue(s)}n.processDateRange()})},v4=(r,e,t)=>{r.metadataTrack_||(r.metadataTrack_=t.addRemoteTextTrack({kind:"metadata",label:"Timed Metadata"},!1).track,K.browser.IS_ANY_SAFARI||(r.metadataTrack_.inBandMetadataTrackDispatchType=e))},jd=function(r,e,t){let i,n;if(t&&t.cues)for(i=t.cues.length;i--;)n=t.cues[i],n.startTime>=r&&n.endTime<=e&&t.removeCue(n)},wie=function(r){const e=r.cues;if(!e)return;const t={};for(let i=e.length-1;i>=0;i--){const n=e[i],a=`${n.startTime}-${n.endTime}-${n.text}`;t[a]?r.removeCue(n):t[a]=n}},Cie=(r,e,t)=>{if(typeof e>"u"||e===null||!r.length)return[];const i=Math.ceil((e-t+3)*du.ONE_SECOND_IN_TS);let n;for(n=0;ni);n++);return r.slice(n)},Aie=(r,e,t)=>{if(!e.length)return r;if(t)return e.slice();const i=e[0].pts;let n=0;for(n;n=i);n++);return r.slice(0,n).concat(e)},Die=(r,e,t,i)=>{const n=Math.ceil((e-i)*du.ONE_SECOND_IN_TS),a=Math.ceil((t-i)*du.ONE_SECOND_IN_TS),s=r.slice();let o=r.length;for(;o--&&!(r[o].pts<=a););if(o===-1)return s;let l=o+1;for(;l--&&!(r[l].pts<=n););return l=Math.max(l,0),s.splice(l,o-l+1),s},Eie=function(r,e){if(!r&&!e||!r&&e||r&&!e)return!1;if(r===e)return!0;const t=Object.keys(r).sort(),i=Object.keys(e).sort();if(t.length!==i.length)return!1;for(let n=0;nt))return a}return i.length===0?0:i[i.length-1]},cd=1,Pie=500,g4=r=>typeof r=="number"&&isFinite(r),qg=1/60,Mie=(r,e,t)=>r!=="main"||!e||!t?null:!t.hasAudio&&!t.hasVideo?"Neither audio nor video found in segment.":e.hasVideo&&!t.hasVideo?"Only audio found in segment when we expected video. We can't switch to audio only from a stream that had video. To get rid of this message, please add codec information to the manifest.":!e.hasVideo&&t.hasVideo?"Video found in segment when we expected only audio. We can't switch to a stream with video from an audio only stream. To get rid of this message, please add codec information to the manifest.":null,Lie=(r,e,t)=>{let i=e-Fr.BACK_BUFFER_LENGTH;r.length&&(i=Math.max(i,r.start(0)));const n=e-t;return Math.min(n,i)},Pc=r=>{const{startOfSegment:e,duration:t,segment:i,part:n,playlist:{mediaSequence:a,id:s,segments:o=[]},mediaIndex:l,partIndex:u,timeline:c}=r,h=o.length-1;let d="mediaIndex/partIndex increment";r.getMediaInfoForTime?d=`getMediaInfoForTime (${r.getMediaInfoForTime})`:r.isSyncRequest&&(d="getSyncSegmentCandidate (isSyncRequest)"),r.independent&&(d+=` with independent ${r.independent}`);const f=typeof u=="number",p=r.segment.uri?"segment":"pre-segment",v=f?u9({preloadSegment:i})-1:0;return`${p} [${a+l}/${a+h}]`+(f?` part [${u}/${v}]`:"")+` segment start/end [${i.start} => ${i.end}]`+(f?` part start/end [${n.start} => ${n.end}]`:"")+` startOfSegment [${e}] duration [${t}] timeline [${c}] selected by [${d}] playlist [${s}]`},m4=r=>`${r}TimingInfo`,kie=({segmentTimeline:r,currentTimeline:e,startOfSegment:t,buffered:i,overrideCheck:n})=>!n&&r===e?null:r{if(e===t)return!1;if(i==="audio"){const a=r.lastTimelineChange({type:"main"});return!a||a.to!==t}if(i==="main"&&n){const a=r.pendingTimelineChange({type:"audio"});return!(a&&a.to===t)}return!1},Rie=r=>{if(!r)return!1;const e=r.pendingTimelineChange({type:"audio"}),t=r.pendingTimelineChange({type:"main"}),i=e&&t,n=i&&e.to!==t.to;return!!(i&&e.from!==-1&&t.from!==-1&&n)},Oie=r=>{r&&(r.pause(),r.resetEverything(),r.load())},Nie=r=>{const e=r.timelineChangeController_.pendingTimelineChange({type:"audio"}),t=r.timelineChangeController_.pendingTimelineChange({type:"main"});return e&&t&&e.to{const e=r.pendingSegment_;if(!e)return;if(jT({timelineChangeController:r.timelineChangeController_,currentTimeline:r.currentTimeline_,segmentTimeline:e.timeline,loaderType:r.loaderType_,audioDisabled:r.audioDisabled_})&&Rie(r.timelineChangeController_)){if(Nie(r)){r.timelineChangeController_.trigger("audioTimelineBehind");return}Oie(r)}},Bie=r=>{let e=0;return["video","audio"].forEach(function(t){const i=r[`${t}TimingInfo`];if(!i)return;const{start:n,end:a}=i;let s;typeof n=="bigint"||typeof a=="bigint"?s=H.BigInt(a)-H.BigInt(n):typeof n=="number"&&typeof a=="number"&&(s=a-n),typeof s<"u"&&s>e&&(e=s)}),typeof e=="bigint"&&er?Math.round(r)>e+za:!1,Fie=(r,e)=>{if(e!=="hls")return null;const t=Bie({audioTimingInfo:r.audioTimingInfo,videoTimingInfo:r.videoTimingInfo});if(!t)return null;const i=r.playlist.targetDuration,n=y4({segmentDuration:t,maxDuration:i*2}),a=y4({segmentDuration:t,maxDuration:i}),s=`Segment with index ${r.mediaIndex} from playlist ${r.playlist.id} has a duration of ${t} when the reported duration is ${r.duration} and the target duration is ${i}. For HLS content, a duration in excess of the target duration may result in playback issues. See the HLS specification section on EXT-X-TARGETDURATION for more details: https://tools.ietf.org/html/draft-pantos-http-live-streaming-23#section-4.3.3.1`;return n||a?{severity:n?"warn":"info",message:s}:null},au=({type:r,segment:e})=>{if(!e)return;const t=!!(e.key||e.map&&e.map.ke),i=!!(e.map&&!e.map.bytes),n=e.startOfSegment===void 0?e.start:e.startOfSegment;return{type:r||e.type,uri:e.resolvedUri||e.uri,start:n,duration:e.duration,isEncrypted:t,isMediaInitialization:i}};class XT extends K.EventTarget{constructor(e,t={}){if(super(),!e)throw new TypeError("Initialization settings are required");if(typeof e.currentTime!="function")throw new TypeError("No currentTime getter specified");if(!e.mediaSource)throw new TypeError("No MediaSource specified");this.bandwidth=e.bandwidth,this.throughput={rate:0,count:0},this.roundTrip=NaN,this.resetStats_(),this.mediaIndex=null,this.partIndex=null,this.hasPlayed_=e.hasPlayed,this.currentTime_=e.currentTime,this.seekable_=e.seekable,this.seeking_=e.seeking,this.duration_=e.duration,this.mediaSource_=e.mediaSource,this.vhs_=e.vhs,this.loaderType_=e.loaderType,this.currentMediaInfo_=void 0,this.startingMediaInfo_=void 0,this.segmentMetadataTrack_=e.segmentMetadataTrack,this.goalBufferLength_=e.goalBufferLength,this.sourceType_=e.sourceType,this.sourceUpdater_=e.sourceUpdater,this.inbandTextTracks_=e.inbandTextTracks,this.state_="INIT",this.timelineChangeController_=e.timelineChangeController,this.shouldSaveSegmentTimingInfo_=!0,this.parse708captions_=e.parse708captions,this.useDtsForTimestampOffset_=e.useDtsForTimestampOffset,this.captionServices_=e.captionServices,this.exactManifestTimings=e.exactManifestTimings,this.addMetadataToTextTrack=e.addMetadataToTextTrack,this.checkBufferTimeout_=null,this.error_=void 0,this.currentTimeline_=-1,this.shouldForceTimestampOffsetAfterResync_=!1,this.pendingSegment_=null,this.xhrOptions_=null,this.pendingSegments_=[],this.audioDisabled_=!1,this.isPendingTimestampOffset_=!1,this.gopBuffer_=[],this.timeMapping_=0,this.safeAppend_=!1,this.appendInitSegment_={audio:!0,video:!0},this.playlistOfLastInitSegment_={audio:null,video:null},this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_={id3:[],caption:[]},this.waitingOnRemove_=!1,this.quotaExceededErrorRetryTimeout_=null,this.activeInitSegmentId_=null,this.initSegments_={},this.cacheEncryptionKeys_=e.cacheEncryptionKeys,this.keyCache_={},this.decrypter_=e.decrypter,this.syncController_=e.syncController,this.syncPoint_={segmentIndex:0,time:0},this.transmuxer_=this.createTransmuxer_(),this.triggerSyncInfoUpdate_=()=>this.trigger("syncinfoupdate"),this.syncController_.on("syncinfoupdate",this.triggerSyncInfoUpdate_),this.mediaSource_.addEventListener("sourceopen",()=>{this.isEndOfStream_()||(this.ended_=!1)}),this.fetchAtBuffer_=!1,this.logger_=Kn(`SegmentLoader[${this.loaderType_}]`),Object.defineProperty(this,"state",{get(){return this.state_},set(i){i!==this.state_&&(this.logger_(`${this.state_} -> ${i}`),this.state_=i,this.trigger("statechange"))}}),this.sourceUpdater_.on("ready",()=>{this.hasEnoughInfoToAppend_()?this.processCallQueue_():co(this)}),this.sourceUpdater_.on("codecschange",i=>{this.trigger(ar({type:"codecschange"},i))}),this.loaderType_==="main"&&this.timelineChangeController_.on("pendingtimelinechange",()=>{this.hasEnoughInfoToAppend_()?this.processCallQueue_():co(this)}),this.loaderType_==="audio"&&this.timelineChangeController_.on("timelinechange",i=>{this.trigger(ar({type:"timelinechange"},i)),this.hasEnoughInfoToLoad_()?this.processLoadQueue_():co(this),this.hasEnoughInfoToAppend_()?this.processCallQueue_():co(this)})}get mediaSequenceSync_(){return this.syncController_.getMediaSequenceSync(this.loaderType_)}createTransmuxer_(){return C2.createTransmuxer({remux:!1,alignGopsAtEnd:this.safeAppend_,keepOriginalTimestamps:!0,parse708captions:this.parse708captions_,captionServices:this.captionServices_})}resetStats_(){this.mediaBytesTransferred=0,this.mediaRequests=0,this.mediaRequestsAborted=0,this.mediaRequestsTimedout=0,this.mediaRequestsErrored=0,this.mediaTransferDuration=0,this.mediaSecondsLoaded=0,this.mediaAppends=0}dispose(){this.trigger("dispose"),this.state="DISPOSED",this.pause(),this.abort_(),this.transmuxer_&&this.transmuxer_.terminate(),this.resetStats_(),this.checkBufferTimeout_&&H.clearTimeout(this.checkBufferTimeout_),this.syncController_&&this.triggerSyncInfoUpdate_&&this.syncController_.off("syncinfoupdate",this.triggerSyncInfoUpdate_),this.off()}setAudio(e){this.audioDisabled_=!e,e?this.appendInitSegment_.audio=!0:this.sourceUpdater_.removeAudio(0,this.duration_())}abort(){if(this.state!=="WAITING"){this.pendingSegment_&&(this.pendingSegment_=null);return}this.abort_(),this.state="READY",this.paused()||this.monitorBuffer_()}abort_(){this.pendingSegment_&&this.pendingSegment_.abortRequests&&this.pendingSegment_.abortRequests(),this.pendingSegment_=null,this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_.id3=[],this.metadataQueue_.caption=[],this.timelineChangeController_.clearPendingTimelineChange(this.loaderType_),this.waitingOnRemove_=!1,H.clearTimeout(this.quotaExceededErrorRetryTimeout_),this.quotaExceededErrorRetryTimeout_=null}checkForAbort_(e){return this.state==="APPENDING"&&!this.pendingSegment_?(this.state="READY",!0):!this.pendingSegment_||this.pendingSegment_.requestId!==e}error(e){return typeof e<"u"&&(this.logger_("error occurred:",e),this.error_=e),this.pendingSegment_=null,this.error_}endOfStream(){this.ended_=!0,this.transmuxer_&&C2.reset(this.transmuxer_),this.gopBuffer_.length=0,this.pause(),this.trigger("ended")}buffered_(){const e=this.getMediaInfo_();if(!this.sourceUpdater_||!e)return Kr();if(this.loaderType_==="main"){const{hasAudio:t,hasVideo:i,isMuxed:n}=e;if(i&&t&&!this.audioDisabled_&&!n)return this.sourceUpdater_.buffered();if(i)return this.sourceUpdater_.videoBuffered()}return this.sourceUpdater_.audioBuffered()}initSegmentForMap(e,t=!1){if(!e)return null;const i=ay(e);let n=this.initSegments_[i];return t&&!n&&e.bytes&&(this.initSegments_[i]=n={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:e.bytes,tracks:e.tracks,timescales:e.timescales}),n||e}segmentKey(e,t=!1){if(!e)return null;const i=A9(e);let n=this.keyCache_[i];this.cacheEncryptionKeys_&&t&&!n&&e.bytes&&(this.keyCache_[i]=n={resolvedUri:e.resolvedUri,bytes:e.bytes});const a={resolvedUri:(n||e).resolvedUri};return n&&(a.bytes=n.bytes),a}couldBeginLoading_(){return this.playlist_&&!this.paused()}load(){if(this.monitorBuffer_(),!!this.playlist_){if(this.state==="INIT"&&this.couldBeginLoading_())return this.init_();!this.couldBeginLoading_()||this.state!=="READY"&&this.state!=="INIT"||(this.state="READY")}}init_(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()}playlist(e,t={}){if(!e)return;const i=this.playlist_,n=this.pendingSegment_;this.playlist_=e,this.xhrOptions_=t,this.state==="INIT"&&(e.syncInfo={mediaSequence:e.mediaSequence,time:0},this.loaderType_==="main"&&this.syncController_.setDateTimeMappingForStart(e));let a=null;if(i&&(i.id?a=i.id:i.uri&&(a=i.uri)),this.logger_(`playlist update [${a} => ${e.id||e.uri}]`),this.mediaSequenceSync_&&(this.mediaSequenceSync_.update(e,this.currentTime_()),this.logger_(`Playlist update: +currentTime: ${this.currentTime_()} +bufferedEnd: ${x2(this.buffered_())} +`,this.mediaSequenceSync_.diagnostics)),this.trigger("syncinfoupdate"),this.state==="INIT"&&this.couldBeginLoading_())return this.init_();if(!i||i.uri!==e.uri){this.mediaIndex!==null&&(!e.endList&&typeof e.partTargetDuration=="number"?this.resetLoader():this.resyncLoader()),this.currentMediaInfo_=void 0,this.trigger("playlistupdate");return}const s=e.mediaSequence-i.mediaSequence;if(this.logger_(`live window shift [${s}]`),this.mediaIndex!==null)if(this.mediaIndex-=s,this.mediaIndex<0)this.mediaIndex=null,this.partIndex=null;else{const o=this.playlist_.segments[this.mediaIndex];if(this.partIndex&&(!o.parts||!o.parts.length||!o.parts[this.partIndex])){const l=this.mediaIndex;this.logger_(`currently processing part (index ${this.partIndex}) no longer exists.`),this.resetLoader(),this.mediaIndex=l}}n&&(n.mediaIndex-=s,n.mediaIndex<0?(n.mediaIndex=null,n.partIndex=null):(n.mediaIndex>=0&&(n.segment=e.segments[n.mediaIndex]),n.partIndex>=0&&n.segment.parts&&(n.part=n.segment.parts[n.partIndex]))),this.syncController_.saveExpiredSegmentInfo(i,e)}pause(){this.checkBufferTimeout_&&(H.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=null)}paused(){return this.checkBufferTimeout_===null}resetEverything(e){this.ended_=!1,this.activeInitSegmentId_=null,this.appendInitSegment_={audio:!0,video:!0},this.resetLoader(),this.remove(0,1/0,e),this.transmuxer_&&(this.transmuxer_.postMessage({action:"clearAllMp4Captions"}),this.transmuxer_.postMessage({action:"reset"}))}resetLoader(){this.fetchAtBuffer_=!1,this.mediaSequenceSync_&&this.mediaSequenceSync_.resetAppendedStatus(),this.resyncLoader()}resyncLoader(){this.transmuxer_&&C2.reset(this.transmuxer_),this.mediaIndex=null,this.partIndex=null,this.syncPoint_=null,this.isPendingTimestampOffset_=!1;const e=this.currentMediaInfo_&&this.currentMediaInfo_.isFmp4;this.sourceType_==="hls"&&!e&&(this.shouldForceTimestampOffsetAfterResync_=!0),this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_.id3=[],this.metadataQueue_.caption=[],this.abort(),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})}remove(e,t,i=()=>{},n=!1){if(t===1/0&&(t=this.duration_()),t<=e){this.logger_("skipping remove because end ${end} is <= start ${start}");return}if(!this.sourceUpdater_||!this.getMediaInfo_()){this.logger_("skipping remove because no source updater or starting media info");return}let a=1;const s=()=>{a--,a===0&&i()};(n||!this.audioDisabled_)&&(a++,this.sourceUpdater_.removeAudio(e,t,s)),(n||this.loaderType_==="main")&&(this.gopBuffer_=Die(this.gopBuffer_,e,t,this.timeMapping_),a++,this.sourceUpdater_.removeVideo(e,t,s));for(const o in this.inbandTextTracks_)jd(e,t,this.inbandTextTracks_[o]);jd(e,t,this.segmentMetadataTrack_),s()}monitorBuffer_(){this.checkBufferTimeout_&&H.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=H.setTimeout(this.monitorBufferTick_.bind(this),1)}monitorBufferTick_(){this.state==="READY"&&this.fillBuffer_(),this.checkBufferTimeout_&&H.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=H.setTimeout(this.monitorBufferTick_.bind(this),Pie)}fillBuffer_(){if(this.sourceUpdater_.updating())return;const e=this.chooseNextRequest_();if(!e)return;const t={segmentInfo:au({type:this.loaderType_,segment:e})};this.trigger({type:"segmentselected",metadata:t}),typeof e.timestampOffset=="number"&&(this.isPendingTimestampOffset_=!1,this.timelineChangeController_.pendingTimelineChange({type:this.loaderType_,from:this.currentTimeline_,to:e.timeline})),this.loadSegment_(e)}isEndOfStream_(e=this.mediaIndex,t=this.playlist_,i=this.partIndex){if(!t||!this.mediaSource_)return!1;const n=typeof e=="number"&&t.segments[e],a=e+1===t.segments.length,s=!n||!n.parts||i+1===n.parts.length;return t.endList&&this.mediaSource_.readyState==="open"&&a&&s}chooseNextRequest_(){const e=this.buffered_(),t=x2(e)||0,i=fA(e,this.currentTime_()),n=!this.hasPlayed_()&&i>=1,a=i>=this.goalBufferLength_(),s=this.playlist_.segments;if(!s.length||n||a)return null;this.syncPoint_=this.syncPoint_||this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_(),this.loaderType_);const o={partIndex:null,mediaIndex:null,startOfSegment:null,playlist:this.playlist_,isSyncRequest:!this.syncPoint_};if(o.isSyncRequest)o.mediaIndex=Iie(this.currentTimeline_,s,t),this.logger_(`choose next request. Can not find sync point. Fallback to media Index: ${o.mediaIndex}`);else if(this.mediaIndex!==null){const d=s[this.mediaIndex],f=typeof this.partIndex=="number"?this.partIndex:-1;o.startOfSegment=d.end?d.end:t,d.parts&&d.parts[f+1]?(o.mediaIndex=this.mediaIndex,o.partIndex=f+1):o.mediaIndex=this.mediaIndex+1}else{let d,f,p;const v=this.fetchAtBuffer_?t:this.currentTime_();if(this.mediaSequenceSync_&&this.logger_(`chooseNextRequest_ request after Quality Switch: +For TargetTime: ${v}. +CurrentTime: ${this.currentTime_()} +BufferedEnd: ${t} +Fetch At Buffer: ${this.fetchAtBuffer_} +`,this.mediaSequenceSync_.diagnostics),this.mediaSequenceSync_&&this.mediaSequenceSync_.isReliable){const g=this.getSyncInfoFromMediaSequenceSync_(v);if(!g){const m="No sync info found while using media sequence sync";return this.error({message:m,metadata:{errorType:K.Error.StreamingFailedToSelectNextSegment,error:new Error(m)}}),this.logger_("chooseNextRequest_ - no sync info found using media sequence sync"),null}this.logger_(`chooseNextRequest_ mediaSequence syncInfo (${g.start} --> ${g.end})`),d=g.segmentIndex,f=g.partIndex,p=g.start}else{this.logger_("chooseNextRequest_ - fallback to a regular segment selection algorithm, based on a syncPoint.");const g=Vi.getMediaInfoForTime({exactManifestTimings:this.exactManifestTimings,playlist:this.playlist_,currentTime:v,startingPartIndex:this.syncPoint_.partIndex,startingSegmentIndex:this.syncPoint_.segmentIndex,startTime:this.syncPoint_.time});d=g.segmentIndex,f=g.partIndex,p=g.startTime}o.getMediaInfoForTime=this.fetchAtBuffer_?`bufferedEnd ${v}`:`currentTime ${v}`,o.mediaIndex=d,o.startOfSegment=p,o.partIndex=f,this.logger_(`choose next request. Playlist switched and we have a sync point. Media Index: ${o.mediaIndex} `)}const l=s[o.mediaIndex];let u=l&&typeof o.partIndex=="number"&&l.parts&&l.parts[o.partIndex];if(!l||typeof o.partIndex=="number"&&!u)return null;typeof o.partIndex!="number"&&l.parts&&(o.partIndex=0,u=l.parts[0]);const c=this.vhs_.playlists&&this.vhs_.playlists.main&&this.vhs_.playlists.main.independentSegments||this.playlist_.independentSegments;if(!i&&u&&!c&&!u.independent)if(o.partIndex===0){const d=s[o.mediaIndex-1],f=d.parts&&d.parts.length&&d.parts[d.parts.length-1];f&&f.independent&&(o.mediaIndex-=1,o.partIndex=d.parts.length-1,o.independent="previous segment")}else l.parts[o.partIndex-1].independent&&(o.partIndex-=1,o.independent="previous part");const h=this.mediaSource_&&this.mediaSource_.readyState==="ended";return o.mediaIndex>=s.length-1&&h&&!this.seeking_()?null:(this.shouldForceTimestampOffsetAfterResync_&&(this.shouldForceTimestampOffsetAfterResync_=!1,o.forceTimestampOffset=!0,this.logger_("choose next request. Force timestamp offset after loader resync")),this.generateSegmentInfo_(o))}getSyncInfoFromMediaSequenceSync_(e){if(!this.mediaSequenceSync_)return null;const t=Math.max(e,this.mediaSequenceSync_.start);e!==t&&this.logger_(`getSyncInfoFromMediaSequenceSync_. Pulled target time from ${e} to ${t}`);const i=this.mediaSequenceSync_.getSyncInfoForTime(t);if(!i)return null;if(!i.isAppended)return i;const n=this.mediaSequenceSync_.getSyncInfoForTime(i.end);return n?(n.isAppended&&this.logger_("getSyncInfoFromMediaSequenceSync_: We encounter unexpected scenario where next media sequence sync info is also appended!"),n):null}generateSegmentInfo_(e){const{independent:t,playlist:i,mediaIndex:n,startOfSegment:a,isSyncRequest:s,partIndex:o,forceTimestampOffset:l,getMediaInfoForTime:u}=e,c=i.segments[n],h=typeof o=="number"&&c.parts[o],d={requestId:"segment-loader-"+Math.random(),uri:h&&h.resolvedUri||c.resolvedUri,mediaIndex:n,partIndex:h?o:null,isSyncRequest:s,startOfSegment:a,playlist:i,bytes:null,encryptedBytes:null,timestampOffset:null,timeline:c.timeline,duration:h&&h.duration||c.duration,segment:c,part:h,byteLength:0,transmuxer:this.transmuxer_,getMediaInfoForTime:u,independent:t},f=typeof l<"u"?l:this.isPendingTimestampOffset_;d.timestampOffset=this.timestampOffsetForSegment_({segmentTimeline:c.timeline,currentTimeline:this.currentTimeline_,startOfSegment:a,buffered:this.buffered_(),overrideCheck:f});const p=x2(this.sourceUpdater_.audioBuffered());return typeof p=="number"&&(d.audioAppendStart=p-this.sourceUpdater_.audioTimestampOffset()),this.sourceUpdater_.videoBuffered().length&&(d.gopsToAlignWith=Cie(this.gopBuffer_,this.currentTime_()-this.sourceUpdater_.videoTimestampOffset(),this.timeMapping_)),d}timestampOffsetForSegment_(e){return kie(e)}earlyAbortWhenNeeded_(e){if(this.vhs_.tech_.paused()||!this.xhrOptions_.timeout||!this.playlist_.attributes.BANDWIDTH||Date.now()-(e.firstBytesReceivedAt||Date.now())<1e3)return;const t=this.currentTime_(),i=e.bandwidth,n=this.pendingSegment_.duration,a=Vi.estimateSegmentRequestTime(n,i,this.playlist_,e.bytesReceived),s=rre(this.buffered_(),t,this.vhs_.tech_.playbackRate())-1;if(a<=s)return;const o=pie({main:this.vhs_.playlists.main,currentTime:t,bandwidth:i,duration:this.duration_(),segmentDuration:n,timeUntilRebuffer:s,currentTimeline:this.currentTimeline_,syncController:this.syncController_});if(!o)return;const u=a-s-o.rebufferingImpact;let c=.5;s<=za&&(c=1),!(!o.playlist||o.playlist.uri===this.playlist_.uri||u{a[s.stream]=a[s.stream]||{startTime:1/0,captions:[],endTime:0};const o=a[s.stream];o.startTime=Math.min(o.startTime,s.startTime+n),o.endTime=Math.max(o.endTime,s.endTime+n),o.captions.push(s)}),Object.keys(a).forEach(s=>{const{startTime:o,endTime:l,captions:u}=a[s],c=this.inbandTextTracks_;this.logger_(`adding cues from ${o} -> ${l} for ${s}`),mie(c,this.vhs_.tech_,s),jd(o,l,c[s]),yie({captionArray:u,inbandTextTracks:c,timestampOffset:n})}),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})}handleId3_(e,t,i){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;if(!this.pendingSegment_.hasAppendedData_){this.metadataQueue_.id3.push(this.handleId3_.bind(this,e,t,i));return}this.addMetadataToTextTrack(i,t,this.duration_())}processMetadataQueue_(){this.metadataQueue_.id3.forEach(e=>e()),this.metadataQueue_.caption.forEach(e=>e()),this.metadataQueue_.id3=[],this.metadataQueue_.caption=[]}processCallQueue_(){const e=this.callQueue_;this.callQueue_=[],e.forEach(t=>t())}processLoadQueue_(){const e=this.loadQueue_;this.loadQueue_=[],e.forEach(t=>t())}hasEnoughInfoToLoad_(){if(this.loaderType_!=="audio")return!0;const e=this.pendingSegment_;return e?this.getCurrentMediaInfo_()?!jT({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:e.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}):!0:!1}getCurrentMediaInfo_(e=this.pendingSegment_){return e&&e.trackInfo||this.currentMediaInfo_}getMediaInfo_(e=this.pendingSegment_){return this.getCurrentMediaInfo_(e)||this.startingMediaInfo_}getPendingSegmentPlaylist(){return this.pendingSegment_?this.pendingSegment_.playlist:null}hasEnoughInfoToAppend_(){if(!this.sourceUpdater_.ready()||this.waitingOnRemove_||this.quotaExceededErrorRetryTimeout_)return!1;const e=this.pendingSegment_,t=this.getCurrentMediaInfo_();if(!e||!t)return!1;const{hasAudio:i,hasVideo:n,isMuxed:a}=t;return!(n&&!e.videoTimingInfo||i&&!this.audioDisabled_&&!a&&!e.audioTimingInfo||jT({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:e.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}))}handleData_(e,t){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;if(this.callQueue_.length||!this.hasEnoughInfoToAppend_()){co(this),this.callQueue_.push(this.handleData_.bind(this,e,t));return}const i=this.pendingSegment_;if(this.setTimeMapping_(i.timeline),this.updateMediaSecondsLoaded_(i.part||i.segment),this.mediaSource_.readyState!=="closed"){if(e.map&&(e.map=this.initSegmentForMap(e.map,!0),i.segment.map=e.map),e.key&&this.segmentKey(e.key,!0),i.isFmp4=e.isFmp4,i.timingInfo=i.timingInfo||{},i.isFmp4)this.trigger("fmp4"),i.timingInfo.start=i[m4(t.type)].start;else{const n=this.getCurrentMediaInfo_(),a=this.loaderType_==="main"&&n&&n.hasVideo;let s;a&&(s=i.videoTimingInfo.start),i.timingInfo.start=this.trueSegmentStart_({currentStart:i.timingInfo.start,playlist:i.playlist,mediaIndex:i.mediaIndex,currentVideoTimestampOffset:this.sourceUpdater_.videoTimestampOffset(),useVideoTimingInfo:a,firstVideoFrameTimeForData:s,videoTimingInfo:i.videoTimingInfo,audioTimingInfo:i.audioTimingInfo})}if(this.updateAppendInitSegmentStatus(i,t.type),this.updateSourceBufferTimestampOffset_(i),i.isSyncRequest){this.updateTimingInfoEnd_(i),this.syncController_.saveSegmentTimingInfo({segmentInfo:i,shouldSaveTimelineMapping:this.loaderType_==="main"});const n=this.chooseNextRequest_();if(n.mediaIndex!==i.mediaIndex||n.partIndex!==i.partIndex){this.logger_("sync segment was incorrect, not appending");return}this.logger_("sync segment was correct, appending")}i.hasAppendedData_=!0,this.processMetadataQueue_(),this.appendData_(i,t)}}updateAppendInitSegmentStatus(e,t){this.loaderType_==="main"&&typeof e.timestampOffset=="number"&&!e.changedTimestampOffset&&(this.appendInitSegment_={audio:!0,video:!0}),this.playlistOfLastInitSegment_[t]!==e.playlist&&(this.appendInitSegment_[t]=!0)}getInitSegmentAndUpdateState_({type:e,initSegment:t,map:i,playlist:n}){if(i){const a=ay(i);if(this.activeInitSegmentId_===a)return null;t=this.initSegmentForMap(i,!0).bytes,this.activeInitSegmentId_=a}return t&&this.appendInitSegment_[e]?(this.playlistOfLastInitSegment_[e]=n,this.appendInitSegment_[e]=!1,this.activeInitSegmentId_=null,t):null}handleQuotaExceededError_({segmentInfo:e,type:t,bytes:i},n){const a=this.sourceUpdater_.audioBuffered(),s=this.sourceUpdater_.videoBuffered();a.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the audio buffer: "+pu(a).join(", ")),s.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the video buffer: "+pu(s).join(", "));const o=a.length?a.start(0):0,l=a.length?a.end(a.length-1):0,u=s.length?s.start(0):0,c=s.length?s.end(s.length-1):0;if(l-o<=cd&&c-u<=cd){this.logger_(`On QUOTA_EXCEEDED_ERR, single segment too large to append to buffer, triggering an error. Appended byte length: ${i.byteLength}, audio buffer: ${pu(a).join(", ")}, video buffer: ${pu(s).join(", ")}, `),this.error({message:"Quota exceeded error with append of a single segment of content",excludeUntil:1/0}),this.trigger("error");return}this.waitingOnRemove_=!0,this.callQueue_.push(this.appendToSourceBuffer_.bind(this,{segmentInfo:e,type:t,bytes:i}));const d=this.currentTime_()-cd;this.logger_(`On QUOTA_EXCEEDED_ERR, removing audio/video from 0 to ${d}`),this.remove(0,d,()=>{this.logger_(`On QUOTA_EXCEEDED_ERR, retrying append in ${cd}s`),this.waitingOnRemove_=!1,this.quotaExceededErrorRetryTimeout_=H.setTimeout(()=>{this.logger_("On QUOTA_EXCEEDED_ERR, re-processing call queue"),this.quotaExceededErrorRetryTimeout_=null,this.processCallQueue_()},cd*1e3)},!0)}handleAppendError_({segmentInfo:e,type:t,bytes:i},n){if(n){if(n.code===b9){this.handleQuotaExceededError_({segmentInfo:e,type:t,bytes:i});return}this.logger_("Received non QUOTA_EXCEEDED_ERR on append",n),this.error({message:`${t} append of ${i.length}b failed for segment #${e.mediaIndex} in playlist ${e.playlist.id}`,metadata:{errorType:K.Error.StreamingFailedToAppendSegment}}),this.trigger("appenderror")}}appendToSourceBuffer_({segmentInfo:e,type:t,initSegment:i,data:n,bytes:a}){if(!a){const o=[n];let l=n.byteLength;i&&(o.unshift(i),l+=i.byteLength),a=gie({bytes:l,segments:o})}const s={segmentInfo:au({type:this.loaderType_,segment:e})};this.trigger({type:"segmentappendstart",metadata:s}),this.sourceUpdater_.appendBuffer({segmentInfo:e,type:t,bytes:a},this.handleAppendError_.bind(this,{segmentInfo:e,type:t,bytes:a}))}handleSegmentTimingInfo_(e,t,i){if(!this.pendingSegment_||t!==this.pendingSegment_.requestId)return;const n=this.pendingSegment_.segment,a=`${e}TimingInfo`;n[a]||(n[a]={}),n[a].transmuxerPrependedSeconds=i.prependedContentDuration||0,n[a].transmuxedPresentationStart=i.start.presentation,n[a].transmuxedDecodeStart=i.start.decode,n[a].transmuxedPresentationEnd=i.end.presentation,n[a].transmuxedDecodeEnd=i.end.decode,n[a].baseMediaDecodeTime=i.baseMediaDecodeTime}appendData_(e,t){const{type:i,data:n}=t;if(!n||!n.byteLength||i==="audio"&&this.audioDisabled_)return;const a=this.getInitSegmentAndUpdateState_({type:i,initSegment:t.initSegment,playlist:e.playlist,map:e.isFmp4?e.segment.map:null});this.appendToSourceBuffer_({segmentInfo:e,type:i,initSegment:a,data:n})}loadSegment_(e){if(this.state="WAITING",this.pendingSegment_=e,this.trimBackBuffer_(e),typeof e.timestampOffset=="number"&&this.transmuxer_&&this.transmuxer_.postMessage({action:"clearAllMp4Captions"}),!this.hasEnoughInfoToLoad_()){co(this),this.loadQueue_.push(()=>{const t=ar({},e,{forceTimestampOffset:!0});ar(e,this.generateSegmentInfo_(t)),this.isPendingTimestampOffset_=!1,this.updateTransmuxerAndRequestSegment_(e)});return}this.updateTransmuxerAndRequestSegment_(e)}updateTransmuxerAndRequestSegment_(e){this.shouldUpdateTransmuxerTimestampOffset_(e.timestampOffset)&&(this.gopBuffer_.length=0,e.gopsToAlignWith=[],this.timeMapping_=0,this.transmuxer_.postMessage({action:"reset"}),this.transmuxer_.postMessage({action:"setTimestampOffset",timestampOffset:e.timestampOffset}));const t=this.createSimplifiedSegmentObj_(e),i=this.isEndOfStream_(e.mediaIndex,e.playlist,e.partIndex),n=this.mediaIndex!==null,a=e.timeline!==this.currentTimeline_&&e.timeline>0,s=i||n&&a;this.logger_(`Requesting +${H9(e.uri)} +${Pc(e)}`),t.map&&!t.map.bytes&&(this.logger_("going to request init segment."),this.appendInitSegment_={video:!0,audio:!0}),e.abortRequests=lie({xhr:this.vhs_.xhr,xhrOptions:this.xhrOptions_,decryptionWorker:this.decrypter_,segment:t,abortFn:this.handleAbort_.bind(this,e),progressFn:this.handleProgress_.bind(this),trackInfoFn:this.handleTrackInfo_.bind(this),timingInfoFn:this.handleTimingInfo_.bind(this),videoSegmentTimingInfoFn:this.handleSegmentTimingInfo_.bind(this,"video",e.requestId),audioSegmentTimingInfoFn:this.handleSegmentTimingInfo_.bind(this,"audio",e.requestId),captionsFn:this.handleCaptions_.bind(this),isEndOfTimeline:s,endedTimelineFn:()=>{this.logger_("received endedtimeline callback")},id3Fn:this.handleId3_.bind(this),dataFn:this.handleData_.bind(this),doneFn:this.segmentRequestFinished_.bind(this),onTransmuxerLog:({message:o,level:l,stream:u})=>{this.logger_(`${Pc(e)} logged from transmuxer stream ${u} as a ${l}: ${o}`)},triggerSegmentEventFn:({type:o,segment:l,keyInfo:u,trackInfo:c,timingInfo:h})=>{const f={segmentInfo:au({segment:l})};u&&(f.keyInfo=u),c&&(f.trackInfo=c),h&&(f.timingInfo=h),this.trigger({type:o,metadata:f})}})}trimBackBuffer_(e){const t=Lie(this.seekable_(),this.currentTime_(),this.playlist_.targetDuration||10);t>0&&this.remove(0,t)}createSimplifiedSegmentObj_(e){const t=e.segment,i=e.part,n=e.segment.key||e.segment.map&&e.segment.map.key,a=e.segment.map&&!e.segment.map.bytes,s={resolvedUri:i?i.resolvedUri:t.resolvedUri,byterange:i?i.byterange:t.byterange,requestId:e.requestId,transmuxer:e.transmuxer,audioAppendStart:e.audioAppendStart,gopsToAlignWith:e.gopsToAlignWith,part:e.part,type:this.loaderType_,start:e.startOfSegment,duration:e.duration,isEncrypted:n,isMediaInitialization:a},o=e.playlist.segments[e.mediaIndex-1];if(o&&o.timeline===t.timeline&&(o.videoTimingInfo?s.baseStartTime=o.videoTimingInfo.transmuxedDecodeEnd:o.audioTimingInfo&&(s.baseStartTime=o.audioTimingInfo.transmuxedDecodeEnd)),t.key){const l=t.key.iv||new Uint32Array([0,0,0,e.mediaIndex+e.playlist.mediaSequence]);s.key=this.segmentKey(t.key),s.key.iv=l}return t.map&&(s.map=this.initSegmentForMap(t.map)),s}saveTransferStats_(e){this.mediaRequests+=1,e&&(this.mediaBytesTransferred+=e.bytesReceived,this.mediaTransferDuration+=e.roundTripTime)}saveBandwidthRelatedStats_(e,t){if(this.pendingSegment_.byteLength=t.bytesReceived,e"u"||u.end!==n+a?n:o.start}waitForAppendsToComplete_(e){const t=this.getCurrentMediaInfo_(e);if(!t){this.error({message:"No starting media returned, likely due to an unsupported media format.",playlistExclusionDuration:1/0}),this.trigger("error");return}const{hasAudio:i,hasVideo:n,isMuxed:a}=t,s=this.loaderType_==="main"&&n,o=!this.audioDisabled_&&i&&!a;if(e.waitingOnAppends=0,!e.hasAppendedData_){!e.timingInfo&&typeof e.timestampOffset=="number"&&(this.isPendingTimestampOffset_=!0),e.timingInfo={start:0},e.waitingOnAppends++,this.isPendingTimestampOffset_||(this.updateSourceBufferTimestampOffset_(e),this.processMetadataQueue_()),this.checkAppendsDone_(e);return}s&&e.waitingOnAppends++,o&&e.waitingOnAppends++,s&&this.sourceUpdater_.videoQueueCallback(this.checkAppendsDone_.bind(this,e)),o&&this.sourceUpdater_.audioQueueCallback(this.checkAppendsDone_.bind(this,e))}checkAppendsDone_(e){this.checkForAbort_(e.requestId)||(e.waitingOnAppends--,e.waitingOnAppends===0&&this.handleAppendsDone_())}checkForIllegalMediaSwitch(e){const t=Mie(this.loaderType_,this.getCurrentMediaInfo_(),e);return t?(this.error({message:t,playlistExclusionDuration:1/0}),this.trigger("error"),!0):!1}updateSourceBufferTimestampOffset_(e){if(e.timestampOffset===null||typeof e.timingInfo.start!="number"||e.changedTimestampOffset||this.loaderType_!=="main")return;let t=!1;e.timestampOffset-=this.getSegmentStartTimeForTimestampOffsetCalculation_({videoTimingInfo:e.segment.videoTimingInfo,audioTimingInfo:e.segment.audioTimingInfo,timingInfo:e.timingInfo}),e.changedTimestampOffset=!0,e.timestampOffset!==this.sourceUpdater_.videoTimestampOffset()&&(this.sourceUpdater_.videoTimestampOffset(e.timestampOffset),t=!0),e.timestampOffset!==this.sourceUpdater_.audioTimestampOffset()&&(this.sourceUpdater_.audioTimestampOffset(e.timestampOffset),t=!0),t&&this.trigger("timestampoffset")}getSegmentStartTimeForTimestampOffsetCalculation_({videoTimingInfo:e,audioTimingInfo:t,timingInfo:i}){return this.useDtsForTimestampOffset_?e&&typeof e.transmuxedDecodeStart=="number"?e.transmuxedDecodeStart:t&&typeof t.transmuxedDecodeStart=="number"?t.transmuxedDecodeStart:i.start:i.start}updateTimingInfoEnd_(e){e.timingInfo=e.timingInfo||{};const t=this.getMediaInfo_(),n=this.loaderType_==="main"&&t&&t.hasVideo&&e.videoTimingInfo?e.videoTimingInfo:e.audioTimingInfo;n&&(e.timingInfo.end=typeof n.end=="number"?n.end:n.start+e.duration)}handleAppendsDone_(){if(this.pendingSegment_){const l={segmentInfo:au({type:this.loaderType_,segment:this.pendingSegment_})};this.trigger({type:"appendsdone",metadata:l})}if(!this.pendingSegment_){this.state="READY",this.paused()||this.monitorBuffer_();return}const e=this.pendingSegment_;e.part&&e.part.syncInfo?e.part.syncInfo.markAppended():e.segment.syncInfo&&e.segment.syncInfo.markAppended(),this.updateTimingInfoEnd_(e),this.shouldSaveSegmentTimingInfo_&&this.syncController_.saveSegmentTimingInfo({segmentInfo:e,shouldSaveTimelineMapping:this.loaderType_==="main"});const t=Fie(e,this.sourceType_);if(t&&(t.severity==="warn"?K.log.warn(t.message):this.logger_(t.message)),this.recordThroughput_(e),this.pendingSegment_=null,this.state="READY",e.isSyncRequest&&(this.trigger("syncinfoupdate"),!e.hasAppendedData_)){this.logger_(`Throwing away un-appended sync request ${Pc(e)}`);return}this.logger_(`Appended ${Pc(e)}`),this.addSegmentMetadataCue_(e),this.fetchAtBuffer_=!0,this.currentTimeline_!==e.timeline&&(this.timelineChangeController_.lastTimelineChange({type:this.loaderType_,from:this.currentTimeline_,to:e.timeline}),this.loaderType_==="main"&&!this.audioDisabled_&&this.timelineChangeController_.lastTimelineChange({type:"audio",from:this.currentTimeline_,to:e.timeline})),this.currentTimeline_=e.timeline,this.trigger("syncinfoupdate");const i=e.segment,n=e.part,a=i.end&&this.currentTime_()-i.end>e.playlist.targetDuration*3,s=n&&n.end&&this.currentTime_()-n.end>e.playlist.partTargetDuration*3;if(a||s){this.logger_(`bad ${a?"segment":"part"} ${Pc(e)}`),this.resetEverything();return}this.mediaIndex!==null&&this.trigger("bandwidthupdate"),this.trigger("progress"),this.mediaIndex=e.mediaIndex,this.partIndex=e.partIndex,this.isEndOfStream_(e.mediaIndex,e.playlist,e.partIndex)&&this.endOfStream(),this.trigger("appended"),e.hasAppendedData_&&this.mediaAppends++,this.paused()||this.monitorBuffer_()}recordThroughput_(e){if(e.duratione.toUpperCase())},Uie=["video","audio"],YT=(r,e)=>{const t=e[`${r}Buffer`];return t&&t.updating||e.queuePending[r]},Vie=(r,e)=>{for(let t=0;t{if(e.queue.length===0)return;let t=0,i=e.queue[t];if(i.type==="mediaSource"){!e.updating()&&e.mediaSource.readyState!=="closed"&&(e.queue.shift(),i.action(e),i.doneFn&&i.doneFn(),Ah("audio",e),Ah("video",e));return}if(r!=="mediaSource"&&!(!e.ready()||e.mediaSource.readyState==="closed"||YT(r,e))){if(i.type!==r){if(t=Vie(r,e.queue),t===null)return;i=e.queue[t]}if(e.queue.splice(t,1),e.queuePending[r]=i,i.action(r,e),!i.doneFn){e.queuePending[r]=null,Ah(r,e);return}}},W9=(r,e)=>{const t=e[`${r}Buffer`],i=$9(r);t&&(t.removeEventListener("updateend",e[`on${i}UpdateEnd_`]),t.removeEventListener("error",e[`on${i}Error_`]),e.codecs[r]=null,e[`${r}Buffer`]=null)},Na=(r,e)=>r&&e&&Array.prototype.indexOf.call(r.sourceBuffers,e)!==-1,rn={appendBuffer:(r,e,t)=>(i,n)=>{const a=n[`${i}Buffer`];if(Na(n.mediaSource,a)){n.logger_(`Appending segment ${e.mediaIndex}'s ${r.length} bytes to ${i}Buffer`);try{a.appendBuffer(r)}catch(s){n.logger_(`Error with code ${s.code} `+(s.code===b9?"(QUOTA_EXCEEDED_ERR) ":"")+`when appending segment ${e.mediaIndex} to ${i}Buffer`),n.queuePending[i]=null,t(s)}}},remove:(r,e)=>(t,i)=>{const n=i[`${t}Buffer`];if(Na(i.mediaSource,n)){i.logger_(`Removing ${r} to ${e} from ${t}Buffer`);try{n.remove(r,e)}catch{i.logger_(`Remove ${r} to ${e} from ${t}Buffer failed`)}}},timestampOffset:r=>(e,t)=>{const i=t[`${e}Buffer`];Na(t.mediaSource,i)&&(t.logger_(`Setting ${e}timestampOffset to ${r}`),i.timestampOffset=r)},callback:r=>(e,t)=>{r()},endOfStream:r=>e=>{if(e.mediaSource.readyState==="open"){e.logger_(`Calling mediaSource endOfStream(${r||""})`);try{e.mediaSource.endOfStream(r)}catch(t){K.log.warn("Failed to call media source endOfStream",t)}}},duration:r=>e=>{e.logger_(`Setting mediaSource duration to ${r}`);try{e.mediaSource.duration=r}catch(t){K.log.warn("Failed to set media source duration",t)}},abort:()=>(r,e)=>{if(e.mediaSource.readyState!=="open")return;const t=e[`${r}Buffer`];if(Na(e.mediaSource,t)){e.logger_(`calling abort on ${r}Buffer`);try{t.abort()}catch(i){K.log.warn(`Failed to abort on ${r}Buffer`,i)}}},addSourceBuffer:(r,e)=>t=>{const i=$9(r),n=Uh(e);t.logger_(`Adding ${r}Buffer with codec ${e} to mediaSource`);const a=t.mediaSource.addSourceBuffer(n);a.addEventListener("updateend",t[`on${i}UpdateEnd_`]),a.addEventListener("error",t[`on${i}Error_`]),t.codecs[r]=e,t[`${r}Buffer`]=a},removeSourceBuffer:r=>e=>{const t=e[`${r}Buffer`];if(W9(r,e),!!Na(e.mediaSource,t)){e.logger_(`Removing ${r}Buffer with codec ${e.codecs[r]} from mediaSource`);try{e.mediaSource.removeSourceBuffer(t)}catch(i){K.log.warn(`Failed to removeSourceBuffer ${r}Buffer`,i)}}},changeType:r=>(e,t)=>{const i=t[`${e}Buffer`],n=Uh(r);if(!Na(t.mediaSource,i))return;const a=r.substring(0,r.indexOf(".")),s=t.codecs[e];if(s.substring(0,s.indexOf("."))===a)return;const l={codecsChangeInfo:{from:s,to:r}};t.trigger({type:"codecschange",metadata:l}),t.logger_(`changing ${e}Buffer codec from ${s} to ${r}`);try{i.changeType(n),t.codecs[e]=r}catch(u){l.errorType=K.Error.StreamingCodecsChangeError,l.error=u,u.metadata=l,t.error_=u,t.trigger("error"),K.log.warn(`Failed to changeType on ${e}Buffer`,u)}}},nn=({type:r,sourceUpdater:e,action:t,doneFn:i,name:n})=>{e.queue.push({type:r,action:t,doneFn:i,name:n}),Ah(r,e)},_4=(r,e)=>t=>{const i=e[`${r}Buffered`](),n=Jte(i);if(e.logger_(`received "updateend" event for ${r} Source Buffer: `,n),e.queuePending[r]){const a=e.queuePending[r].doneFn;e.queuePending[r]=null,a&&a(e[`${r}Error_`])}Ah(r,e)};class q9 extends K.EventTarget{constructor(e){super(),this.mediaSource=e,this.sourceopenListener_=()=>Ah("mediaSource",this),this.mediaSource.addEventListener("sourceopen",this.sourceopenListener_),this.logger_=Kn("SourceUpdater"),this.audioTimestampOffset_=0,this.videoTimestampOffset_=0,this.queue=[],this.queuePending={audio:null,video:null},this.delayedAudioAppendQueue_=[],this.videoAppendQueued_=!1,this.codecs={},this.onVideoUpdateEnd_=_4("video",this),this.onAudioUpdateEnd_=_4("audio",this),this.onVideoError_=t=>{this.videoError_=t},this.onAudioError_=t=>{this.audioError_=t},this.createdSourceBuffers_=!1,this.initializedEme_=!1,this.triggeredReady_=!1}initializedEme(){this.initializedEme_=!0,this.triggerReady()}hasCreatedSourceBuffers(){return this.createdSourceBuffers_}hasInitializedAnyEme(){return this.initializedEme_}ready(){return this.hasCreatedSourceBuffers()&&this.hasInitializedAnyEme()}createSourceBuffers(e){this.hasCreatedSourceBuffers()||(this.addOrChangeSourceBuffers(e),this.createdSourceBuffers_=!0,this.trigger("createdsourcebuffers"),this.triggerReady())}triggerReady(){this.ready()&&!this.triggeredReady_&&(this.triggeredReady_=!0,this.trigger("ready"))}addSourceBuffer(e,t){nn({type:"mediaSource",sourceUpdater:this,action:rn.addSourceBuffer(e,t),name:"addSourceBuffer"})}abort(e){nn({type:e,sourceUpdater:this,action:rn.abort(e),name:"abort"})}removeSourceBuffer(e){if(!this.canRemoveSourceBuffer()){K.log.error("removeSourceBuffer is not supported!");return}nn({type:"mediaSource",sourceUpdater:this,action:rn.removeSourceBuffer(e),name:"removeSourceBuffer"})}canRemoveSourceBuffer(){return!K.browser.IS_FIREFOX&&H.MediaSource&&H.MediaSource.prototype&&typeof H.MediaSource.prototype.removeSourceBuffer=="function"}static canChangeType(){return H.SourceBuffer&&H.SourceBuffer.prototype&&typeof H.SourceBuffer.prototype.changeType=="function"}canChangeType(){return this.constructor.canChangeType()}changeType(e,t){if(!this.canChangeType()){K.log.error("changeType is not supported!");return}nn({type:e,sourceUpdater:this,action:rn.changeType(t),name:"changeType"})}addOrChangeSourceBuffers(e){if(!e||typeof e!="object"||Object.keys(e).length===0)throw new Error("Cannot addOrChangeSourceBuffers to undefined codecs");Object.keys(e).forEach(t=>{const i=e[t];if(!this.hasCreatedSourceBuffers())return this.addSourceBuffer(t,i);this.canChangeType()&&this.changeType(t,i)})}appendBuffer(e,t){const{segmentInfo:i,type:n,bytes:a}=e;if(this.processedAppend_=!0,n==="audio"&&this.videoBuffer&&!this.videoAppendQueued_){this.delayedAudioAppendQueue_.push([e,t]),this.logger_(`delayed audio append of ${a.length} until video append`);return}const s=t;if(nn({type:n,sourceUpdater:this,action:rn.appendBuffer(a,i||{mediaIndex:-1},s),doneFn:t,name:"appendBuffer"}),n==="video"){if(this.videoAppendQueued_=!0,!this.delayedAudioAppendQueue_.length)return;const o=this.delayedAudioAppendQueue_.slice();this.logger_(`queuing delayed audio ${o.length} appendBuffers`),this.delayedAudioAppendQueue_.length=0,o.forEach(l=>{this.appendBuffer.apply(this,l)})}}audioBuffered(){return Na(this.mediaSource,this.audioBuffer)&&this.audioBuffer.buffered?this.audioBuffer.buffered:Kr()}videoBuffered(){return Na(this.mediaSource,this.videoBuffer)&&this.videoBuffer.buffered?this.videoBuffer.buffered:Kr()}buffered(){const e=Na(this.mediaSource,this.videoBuffer)?this.videoBuffer:null,t=Na(this.mediaSource,this.audioBuffer)?this.audioBuffer:null;return t&&!e?this.audioBuffered():e&&!t?this.videoBuffered():tre(this.audioBuffered(),this.videoBuffered())}setDuration(e,t=As){nn({type:"mediaSource",sourceUpdater:this,action:rn.duration(e),name:"duration",doneFn:t})}endOfStream(e=null,t=As){typeof e!="string"&&(e=void 0),nn({type:"mediaSource",sourceUpdater:this,action:rn.endOfStream(e),name:"endOfStream",doneFn:t})}removeAudio(e,t,i=As){if(!this.audioBuffered().length||this.audioBuffered().end(0)===0){i();return}nn({type:"audio",sourceUpdater:this,action:rn.remove(e,t),doneFn:i,name:"remove"})}removeVideo(e,t,i=As){if(!this.videoBuffered().length||this.videoBuffered().end(0)===0){i();return}nn({type:"video",sourceUpdater:this,action:rn.remove(e,t),doneFn:i,name:"remove"})}updating(){return!!(YT("audio",this)||YT("video",this))}audioTimestampOffset(e){return typeof e<"u"&&this.audioBuffer&&this.audioTimestampOffset_!==e&&(nn({type:"audio",sourceUpdater:this,action:rn.timestampOffset(e),name:"timestampOffset"}),this.audioTimestampOffset_=e),this.audioTimestampOffset_}videoTimestampOffset(e){return typeof e<"u"&&this.videoBuffer&&this.videoTimestampOffset_!==e&&(nn({type:"video",sourceUpdater:this,action:rn.timestampOffset(e),name:"timestampOffset"}),this.videoTimestampOffset_=e),this.videoTimestampOffset_}audioQueueCallback(e){this.audioBuffer&&nn({type:"audio",sourceUpdater:this,action:rn.callback(e),name:"callback"})}videoQueueCallback(e){this.videoBuffer&&nn({type:"video",sourceUpdater:this,action:rn.callback(e),name:"callback"})}dispose(){this.trigger("dispose"),Uie.forEach(e=>{this.abort(e),this.canRemoveSourceBuffer()?this.removeSourceBuffer(e):this[`${e}QueueCallback`](()=>W9(e,this))}),this.videoAppendQueued_=!1,this.delayedAudioAppendQueue_.length=0,this.sourceopenListener_&&this.mediaSource.removeEventListener("sourceopen",this.sourceopenListener_),this.off()}}const b4=r=>decodeURIComponent(escape(String.fromCharCode.apply(null,r))),zie=r=>{const e=new Uint8Array(r);return Array.from(e).map(t=>t.toString(16).padStart(2,"0")).join("")},S4=new Uint8Array(` + +`.split("").map(r=>r.charCodeAt(0)));class Gie extends Error{constructor(){super("Trying to parse received VTT cues, but there is no WebVTT. Make sure vtt.js is loaded.")}}class Hie extends XT{constructor(e,t={}){super(e,t),this.mediaSource_=null,this.subtitlesTrack_=null,this.featuresNativeTextTracks_=e.featuresNativeTextTracks,this.loadVttJs=e.loadVttJs,this.shouldSaveSegmentTimingInfo_=!1}createTransmuxer_(){return null}buffered_(){if(!this.subtitlesTrack_||!this.subtitlesTrack_.cues||!this.subtitlesTrack_.cues.length)return Kr();const e=this.subtitlesTrack_.cues,t=e[0].startTime,i=e[e.length-1].startTime;return Kr([[t,i]])}initSegmentForMap(e,t=!1){if(!e)return null;const i=ay(e);let n=this.initSegments_[i];if(t&&!n&&e.bytes){const a=S4.byteLength+e.bytes.byteLength,s=new Uint8Array(a);s.set(e.bytes),s.set(S4,e.bytes.byteLength),this.initSegments_[i]=n={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:s}}return n||e}couldBeginLoading_(){return this.playlist_&&this.subtitlesTrack_&&!this.paused()}init_(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()}track(e){return typeof e>"u"?this.subtitlesTrack_:(this.subtitlesTrack_=e,this.state==="INIT"&&this.couldBeginLoading_()&&this.init_(),this.subtitlesTrack_)}remove(e,t){jd(e,t,this.subtitlesTrack_)}fillBuffer_(){const e=this.chooseNextRequest_();if(e){if(this.syncController_.timestampOffsetForTimeline(e.timeline)===null){const t=()=>{this.state="READY",this.paused()||this.monitorBuffer_()};this.syncController_.one("timestampoffset",t),this.state="WAITING_ON_TIMELINE";return}this.loadSegment_(e)}}timestampOffsetForSegment_(){return null}chooseNextRequest_(){return this.skipEmptySegments_(super.chooseNextRequest_())}skipEmptySegments_(e){for(;e&&e.segment.empty;){if(e.mediaIndex+1>=e.playlist.segments.length){e=null;break}e=this.generateSegmentInfo_({playlist:e.playlist,mediaIndex:e.mediaIndex+1,startOfSegment:e.startOfSegment+e.duration,isSyncRequest:e.isSyncRequest})}return e}stopForError(e){this.error(e),this.state="READY",this.pause(),this.trigger("error")}segmentRequestFinished_(e,t,i){if(!this.subtitlesTrack_){this.state="READY";return}if(this.saveTransferStats_(t.stats),!this.pendingSegment_){this.state="READY",this.mediaRequestsAborted+=1;return}if(e){e.code===Ha.TIMEOUT&&this.handleTimeout_(),e.code===Ha.ABORTED?this.mediaRequestsAborted+=1:this.mediaRequestsErrored+=1,this.stopForError(e);return}const n=this.pendingSegment_;this.saveBandwidthRelatedStats_(n.duration,t.stats),t.key&&this.segmentKey(t.key,!0),this.state="APPENDING",this.trigger("appending");const a=n.segment;if(a.map&&(a.map.bytes=t.map.bytes),n.bytes=t.bytes,typeof H.WebVTT!="function"&&typeof this.loadVttJs=="function"){this.state="WAITING_ON_VTTJS",this.loadVttJs().then(()=>this.segmentRequestFinished_(e,t,i),()=>this.stopForError({message:"Error loading vtt.js"}));return}a.requested=!0;try{this.parseVTTCues_(n)}catch(s){this.stopForError({message:s.message,metadata:{errorType:K.Error.StreamingVttParserError,error:s}});return}if(this.updateTimeMapping_(n,this.syncController_.timelines[n.timeline],this.playlist_),n.cues.length?n.timingInfo={start:n.cues[0].startTime,end:n.cues[n.cues.length-1].endTime}:n.timingInfo={start:n.startOfSegment,end:n.startOfSegment+n.duration},n.isSyncRequest){this.trigger("syncinfoupdate"),this.pendingSegment_=null,this.state="READY";return}n.byteLength=n.bytes.byteLength,this.mediaSecondsLoaded+=a.duration,n.cues.forEach(s=>{this.subtitlesTrack_.addCue(this.featuresNativeTextTracks_?new H.VTTCue(s.startTime,s.endTime,s.text):s)}),wie(this.subtitlesTrack_),this.handleAppendsDone_()}handleData_(){}updateTimingInfoEnd_(){}parseVTTCues_(e){let t,i=!1;if(typeof H.WebVTT!="function")throw new Gie;typeof H.TextDecoder=="function"?t=new H.TextDecoder("utf8"):(t=H.WebVTT.StringDecoder(),i=!0);const n=new H.WebVTT.Parser(H,H.vttjs,t);if(e.cues=[],e.timestampmap={MPEGTS:0,LOCAL:0},n.oncue=e.cues.push.bind(e.cues),n.ontimestampmap=s=>{e.timestampmap=s},n.onparsingerror=s=>{K.log.warn("Error encountered when parsing cues: "+s.message)},e.segment.map){let s=e.segment.map.bytes;i&&(s=b4(s)),n.parse(s)}let a=e.bytes;i&&(a=b4(a)),n.parse(a),n.flush()}updateTimeMapping_(e,t,i){const n=e.segment;if(!t)return;if(!e.cues.length){n.empty=!0;return}const{MPEGTS:a,LOCAL:s}=e.timestampmap,l=a/du.ONE_SECOND_IN_TS-s+t.mapping;if(e.cues.forEach(u=>{const c=u.endTime-u.startTime,h=this.handleRollover_(u.startTime+l,t.time);u.startTime=Math.max(h,0),u.endTime=Math.max(h+c,0)}),!i.syncInfo){const u=e.cues[0].startTime,c=e.cues[e.cues.length-1].startTime;i.syncInfo={mediaSequence:i.mediaSequence+e.mediaIndex,time:Math.min(u,c-n.duration)}}}handleRollover_(e,t){if(t===null)return e;let i=e*du.ONE_SECOND_IN_TS;const n=t*du.ONE_SECOND_IN_TS;let a;for(n4294967296;)i+=a;return i/du.ONE_SECOND_IN_TS}}const $ie=function(r,e){const t=r.cues;for(let i=0;i=n.adStartTime&&e<=n.adEndTime)return n}return null},Wie=function(r,e,t=0){if(!r.segments)return;let i=t,n;for(let a=0;a=this.start&&e0}resetAppendStatus(){this.segmentSyncInfo_.resetAppendedStatus(),this.partsSyncInfo_.forEach(e=>e.resetAppendedStatus())}}class j9{constructor(){this.storage_=new Map,this.diagnostics_="",this.isReliable_=!1,this.start_=-1/0,this.end_=1/0}get start(){return this.start_}get end(){return this.end_}get diagnostics(){return this.diagnostics_}get isReliable(){return this.isReliable_}resetAppendedStatus(){this.storage_.forEach(e=>e.resetAppendStatus())}update(e,t){const{mediaSequence:i,segments:n}=e;if(this.isReliable_=this.isReliablePlaylist_(i,n),!!this.isReliable_)return this.updateStorage_(n,i,this.calculateBaseTime_(i,t))}getSyncInfoForTime(e){for(const{segmentSyncInfo:t,partsSyncInfo:i}of this.storage_.values())if(i.length){for(const n of i)if(n.isInRange(e))return n}else if(t.isInRange(e))return t;return null}getSyncInfoForMediaSequence(e){return this.storage_.get(e)}updateStorage_(e,t,i){const n=new Map;let a=` +`,s=i,o=t;this.start_=s,e.forEach((l,u)=>{const c=this.storage_.get(o),h=s,d=h+l.duration,f=!!(c&&c.segmentSyncInfo&&c.segmentSyncInfo.isAppended),p=new T4({start:h,end:d,appended:f,segmentIndex:u});l.syncInfo=p;let v=s;const g=(l.parts||[]).map((m,y)=>{const _=v,b=v+m.duration,T=!!(c&&c.partsSyncInfo&&c.partsSyncInfo[y]&&c.partsSyncInfo[y].isAppended),x=new T4({start:_,end:b,appended:T,segmentIndex:u,partIndex:y});return v=b,a+=`Media Sequence: ${o}.${y} | Range: ${_} --> ${b} | Appended: ${T} +`,m.syncInfo=x,x});n.set(o,new qie(p,g)),a+=`${H9(l.resolvedUri)} | Media Sequence: ${o} | Range: ${h} --> ${d} | Appended: ${f} +`,o++,s=d}),this.end_=s,this.storage_=n,this.diagnostics_=a}calculateBaseTime_(e,t){return this.storage_.size?this.storage_.has(e)?this.storage_.get(e).segmentSyncInfo.start:t:0}isReliablePlaylist_(e,t){return e!=null&&Array.isArray(t)&&t.length}}class x4 extends j9{constructor(e){super(),this.parent_=e}calculateBaseTime_(e,t){if(!this.storage_.size){const i=this.parent_.getSyncInfoForMediaSequence(e);return i?i.segmentSyncInfo.start:0}return super.calculateBaseTime_(e,t)}}const jie=86400,A2=[{name:"VOD",run:(r,e,t,i,n)=>t!==1/0?{time:0,segmentIndex:0,partIndex:null}:null},{name:"MediaSequence",run:(r,e,t,i,n,a)=>{const s=r.getMediaSequenceSync(a);if(!s||!s.isReliable)return null;const o=s.getSyncInfoForTime(n);return o?{time:o.start,partIndex:o.partIndex,segmentIndex:o.segmentIndex}:null}},{name:"ProgramDateTime",run:(r,e,t,i,n)=>{if(!Object.keys(r.timelineToDatetimeMappings).length)return null;let a=null,s=null;const o=UT(e);n=n||0;for(let l=0;l{let a=null,s=null;n=n||0;const o=UT(e);for(let l=0;l=f)&&(s=f,a={time:d,segmentIndex:c.segmentIndex,partIndex:c.partIndex})}}return a}},{name:"Discontinuity",run:(r,e,t,i,n)=>{let a=null;if(n=n||0,e.discontinuityStarts&&e.discontinuityStarts.length){let s=null;for(let o=0;o=h)&&(s=h,a={time:c.time,segmentIndex:l,partIndex:null})}}}return a}},{name:"Playlist",run:(r,e,t,i,n)=>e.syncInfo?{time:e.syncInfo.time,segmentIndex:e.syncInfo.mediaSequence-e.mediaSequence,partIndex:null}:null}];class Xie extends K.EventTarget{constructor(e={}){super(),this.timelines=[],this.discontinuities=[],this.timelineToDatetimeMappings={};const t=new j9,i=new x4(t),n=new x4(t);this.mediaSequenceStorage_={main:t,audio:i,vtt:n},this.logger_=Kn("SyncController")}getMediaSequenceSync(e){return this.mediaSequenceStorage_[e]||null}getSyncPoint(e,t,i,n,a){if(t!==1/0)return A2.find(({name:l})=>l==="VOD").run(this,e,t);const s=this.runStrategies_(e,t,i,n,a);if(!s.length)return null;for(const o of s){const{syncPoint:l,strategy:u}=o,{segmentIndex:c,time:h}=l;if(c<0)continue;const d=e.segments[c],f=h,p=f+d.duration;if(this.logger_(`Strategy: ${u}. Current time: ${n}. selected segment: ${c}. Time: [${f} -> ${p}]}`),n>=f&&n0&&(n.time*=-1),Math.abs(n.time+yp({defaultDuration:e.targetDuration,durationList:e.segments,startIndex:n.segmentIndex,endIndex:0}))}runStrategies_(e,t,i,n,a){const s=[];for(let o=0;ojie){K.log.warn(`Not saving expired segment info. Media sequence gap ${i} is too large.`);return}for(let n=i-1;n>=0;n--){const a=e.segments[n];if(a&&typeof a.start<"u"){t.syncInfo={mediaSequence:e.mediaSequence+n,time:a.start},this.logger_(`playlist refresh sync: [time:${t.syncInfo.time}, mediaSequence: ${t.syncInfo.mediaSequence}]`),this.trigger("syncinfoupdate");break}}}setDateTimeMappingForStart(e){if(this.timelineToDatetimeMappings={},e.segments&&e.segments.length&&e.segments[0].dateTimeObject){const t=e.segments[0],i=t.dateTimeObject.getTime()/1e3;this.timelineToDatetimeMappings[t.timeline]=-i}}saveSegmentTimingInfo({segmentInfo:e,shouldSaveTimelineMapping:t}){const i=this.calculateSegmentTimeMapping_(e,e.timingInfo,t),n=e.segment;i&&(this.saveDiscontinuitySyncInfo_(e),e.playlist.syncInfo||(e.playlist.syncInfo={mediaSequence:e.playlist.mediaSequence+e.mediaIndex,time:n.start}));const a=n.dateTimeObject;n.discontinuity&&t&&a&&(this.timelineToDatetimeMappings[n.timeline]=-(a.getTime()/1e3))}timestampOffsetForTimeline(e){return typeof this.timelines[e]>"u"?null:this.timelines[e].time}mappingForTimeline(e){return typeof this.timelines[e]>"u"?null:this.timelines[e].mapping}calculateSegmentTimeMapping_(e,t,i){const n=e.segment,a=e.part;let s=this.timelines[e.timeline],o,l;if(typeof e.timestampOffset=="number")s={time:e.startOfSegment,mapping:e.startOfSegment-t.start},i&&(this.timelines[e.timeline]=s,this.trigger("timestampoffset"),this.logger_(`time mapping for timeline ${e.timeline}: [time: ${s.time}] [mapping: ${s.mapping}]`)),o=e.startOfSegment,l=t.end+s.mapping;else if(s)o=t.start+s.mapping,l=t.end+s.mapping;else return!1;return a&&(a.start=o,a.end=l),(!n.start||ol){let u;o<0?u=i.start-yp({defaultDuration:t.targetDuration,durationList:t.segments,startIndex:e.mediaIndex,endIndex:a}):u=i.end+yp({defaultDuration:t.targetDuration,durationList:t.segments,startIndex:e.mediaIndex+1,endIndex:a}),this.discontinuities[s]={time:u,accuracy:l}}}}dispose(){this.trigger("dispose"),this.off()}}class Yie extends K.EventTarget{constructor(){super(),this.pendingTimelineChanges_={},this.lastTimelineChanges_={}}clearPendingTimelineChange(e){this.pendingTimelineChanges_[e]=null,this.trigger("pendingtimelinechange")}pendingTimelineChange({type:e,from:t,to:i}){return typeof t=="number"&&typeof i=="number"&&(this.pendingTimelineChanges_[e]={type:e,from:t,to:i},this.trigger("pendingtimelinechange")),this.pendingTimelineChanges_[e]}lastTimelineChange({type:e,from:t,to:i}){if(typeof t=="number"&&typeof i=="number"){this.lastTimelineChanges_[e]={type:e,from:t,to:i},delete this.pendingTimelineChanges_[e];const n={timelineChangeInfo:{from:t,to:i}};this.trigger({type:"timelinechange",metadata:n})}return this.lastTimelineChanges_[e]}dispose(){this.trigger("dispose"),this.pendingTimelineChanges_={},this.lastTimelineChanges_={},this.off()}}const Kie=L9(k9(function(){var r=function(){function v(){this.listeners={}}var g=v.prototype;return g.on=function(y,_){this.listeners[y]||(this.listeners[y]=[]),this.listeners[y].push(_)},g.off=function(y,_){if(!this.listeners[y])return!1;var b=this.listeners[y].indexOf(_);return this.listeners[y]=this.listeners[y].slice(0),this.listeners[y].splice(b,1),b>-1},g.trigger=function(y){var _=this.listeners[y];if(_)if(arguments.length===2)for(var b=_.length,T=0;T>7)*283)^b]=b;for(T=x=0;!y[T];T^=I||1,x=D[x]||1)for(N=x^x<<1^x<<2^x<<3^x<<4,N=N>>8^N&255^99,y[T]=N,_[N]=T,L=C[M=C[I=C[T]]],B=L*16843009^M*65537^I*257^T*16843008,O=C[N]*257^N*16843008,b=0;b<4;b++)g[b][T]=O=O<<24^O>>>8,m[b][N]=B=B<<24^B>>>8;for(b=0;b<5;b++)g[b]=g[b].slice(0),m[b]=m[b].slice(0);return v};let i=null;class n{constructor(g){i||(i=t()),this._tables=[[i[0][0].slice(),i[0][1].slice(),i[0][2].slice(),i[0][3].slice(),i[0][4].slice()],[i[1][0].slice(),i[1][1].slice(),i[1][2].slice(),i[1][3].slice(),i[1][4].slice()]];let m,y,_;const b=this._tables[0][4],T=this._tables[1],x=g.length;let C=1;if(x!==4&&x!==6&&x!==8)throw new Error("Invalid aes key size");const D=g.slice(0),I=[];for(this._key=[D,I],m=x;m<4*x+28;m++)_=D[m-1],(m%x===0||x===8&&m%x===4)&&(_=b[_>>>24]<<24^b[_>>16&255]<<16^b[_>>8&255]<<8^b[_&255],m%x===0&&(_=_<<8^_>>>24^C<<24,C=C<<1^(C>>7)*283)),D[m]=D[m-x]^_;for(y=0;m;y++,m--)_=D[y&3?m:m-4],m<=4||y<4?I[y]=_:I[y]=T[0][b[_>>>24]]^T[1][b[_>>16&255]]^T[2][b[_>>8&255]]^T[3][b[_&255]]}decrypt(g,m,y,_,b,T){const x=this._key[1];let C=g^x[0],D=_^x[1],I=y^x[2],M=m^x[3],L,N,O;const B=x.length/4-2;let F,U=4;const $=this._tables[1],q=$[0],Z=$[1],te=$[2],Q=$[3],se=$[4];for(F=0;F>>24]^Z[D>>16&255]^te[I>>8&255]^Q[M&255]^x[U],N=q[D>>>24]^Z[I>>16&255]^te[M>>8&255]^Q[C&255]^x[U+1],O=q[I>>>24]^Z[M>>16&255]^te[C>>8&255]^Q[D&255]^x[U+2],M=q[M>>>24]^Z[C>>16&255]^te[D>>8&255]^Q[I&255]^x[U+3],U+=4,C=L,D=N,I=O;for(F=0;F<4;F++)b[(3&-F)+T]=se[C>>>24]<<24^se[D>>16&255]<<16^se[I>>8&255]<<8^se[M&255]^x[U++],L=C,C=D,D=I,I=M,M=L}}class a extends r{constructor(){super(r),this.jobs=[],this.delay=1,this.timeout_=null}processJob_(){this.jobs.shift()(),this.jobs.length?this.timeout_=setTimeout(this.processJob_.bind(this),this.delay):this.timeout_=null}push(g){this.jobs.push(g),this.timeout_||(this.timeout_=setTimeout(this.processJob_.bind(this),this.delay))}}const s=function(v){return v<<24|(v&65280)<<8|(v&16711680)>>8|v>>>24},o=function(v,g,m){const y=new Int32Array(v.buffer,v.byteOffset,v.byteLength>>2),_=new n(Array.prototype.slice.call(g)),b=new Uint8Array(v.byteLength),T=new Int32Array(b.buffer);let x,C,D,I,M,L,N,O,B;for(x=m[0],C=m[1],D=m[2],I=m[3],B=0;B{const y=v[m];d(y)?g[m]={bytes:y.buffer,byteOffset:y.byteOffset,byteLength:y.byteLength}:g[m]=y}),g};self.onmessage=function(v){const g=v.data,m=new Uint8Array(g.encrypted.bytes,g.encrypted.byteOffset,g.encrypted.byteLength),y=new Uint32Array(g.key.bytes,g.key.byteOffset,g.key.byteLength/4),_=new Uint32Array(g.iv.bytes,g.iv.byteOffset,g.iv.byteLength/4);new l(m,y,_,function(b,T){self.postMessage(p({source:g.source,decrypted:T}),[T.buffer])})}}));var Zie=M9(Kie);const Qie=r=>{let e=r.default?"main":"alternative";return r.characteristics&&r.characteristics.indexOf("public.accessibility.describes-video")>=0&&(e="main-desc"),e},X9=(r,e)=>{r.abort(),r.pause(),e&&e.activePlaylistLoader&&(e.activePlaylistLoader.pause(),e.activePlaylistLoader=null)},KT=(r,e)=>{e.activePlaylistLoader=r,r.load()},Jie=(r,e)=>()=>{const{segmentLoaders:{[r]:t,main:i},mediaTypes:{[r]:n}}=e,a=n.activeTrack(),s=n.getActiveGroup(),o=n.activePlaylistLoader,l=n.lastGroup_;if(!(s&&l&&s.id===l.id)&&(n.lastGroup_=s,n.lastTrack_=a,X9(t,n),!(!s||s.isMainPlaylist))){if(!s.playlistLoader){o&&i.resetEverything();return}t.resyncLoader(),KT(s.playlistLoader,n)}},ene=(r,e)=>()=>{const{segmentLoaders:{[r]:t},mediaTypes:{[r]:i}}=e;i.lastGroup_=null,t.abort(),t.pause()},tne=(r,e)=>()=>{const{mainPlaylistLoader:t,segmentLoaders:{[r]:i,main:n},mediaTypes:{[r]:a}}=e,s=a.activeTrack(),o=a.getActiveGroup(),l=a.activePlaylistLoader,u=a.lastTrack_;if(!(u&&s&&u.id===s.id)&&(a.lastGroup_=o,a.lastTrack_=s,X9(i,a),!!o)){if(o.isMainPlaylist){if(!s||!u||s.id===u.id)return;const c=e.vhs.playlistController_,h=c.selectPlaylist();if(c.media()===h)return;a.logger_(`track change. Switching main audio from ${u.id} to ${s.id}`),t.pause(),n.resetEverything(),c.fastQualityChange_(h);return}if(r==="AUDIO"){if(!o.playlistLoader){n.setAudio(!0),n.resetEverything();return}i.setAudio(!0),n.setAudio(!1)}if(l===o.playlistLoader){KT(o.playlistLoader,a);return}i.track&&i.track(s),i.resetEverything(),KT(o.playlistLoader,a)}},ly={AUDIO:(r,e)=>()=>{const{mediaTypes:{[r]:t},excludePlaylist:i}=e,n=t.activeTrack(),a=t.activeGroup(),s=(a.filter(l=>l.default)[0]||a[0]).id,o=t.tracks[s];if(n===o){i({error:{message:"Problem encountered loading the default audio track."}});return}K.log.warn("Problem encountered loading the alternate audio track.Switching back to default.");for(const l in t.tracks)t.tracks[l].enabled=t.tracks[l]===o;t.onTrackChanged()},SUBTITLES:(r,e)=>()=>{const{mediaTypes:{[r]:t}}=e;K.log.warn("Problem encountered loading the subtitle track.Disabling subtitle track.");const i=t.activeTrack();i&&(i.mode="disabled"),t.onTrackChanged()}},w4={AUDIO:(r,e,t)=>{if(!e)return;const{tech:i,requestOptions:n,segmentLoaders:{[r]:a}}=t;e.on("loadedmetadata",()=>{const s=e.media();a.playlist(s,n),(!i.paused()||s.endList&&i.preload()!=="none")&&a.load()}),e.on("loadedplaylist",()=>{a.playlist(e.media(),n),i.paused()||a.load()}),e.on("error",ly[r](r,t))},SUBTITLES:(r,e,t)=>{const{tech:i,requestOptions:n,segmentLoaders:{[r]:a},mediaTypes:{[r]:s}}=t;e.on("loadedmetadata",()=>{const o=e.media();a.playlist(o,n),a.track(s.activeTrack()),(!i.paused()||o.endList&&i.preload()!=="none")&&a.load()}),e.on("loadedplaylist",()=>{a.playlist(e.media(),n),i.paused()||a.load()}),e.on("error",ly[r](r,t))}},rne={AUDIO:(r,e)=>{const{vhs:t,sourceType:i,segmentLoaders:{[r]:n},requestOptions:a,main:{mediaGroups:s},mediaTypes:{[r]:{groups:o,tracks:l,logger_:u}},mainPlaylistLoader:c}=e,h=jv(c.main);(!s[r]||Object.keys(s[r]).length===0)&&(s[r]={main:{default:{default:!0}}},h&&(s[r].main.default.playlists=c.main.playlists));for(const d in s[r]){o[d]||(o[d]=[]);for(const f in s[r][d]){let p=s[r][d][f],v;if(h?(u(`AUDIO group '${d}' label '${f}' is a main playlist`),p.isMainPlaylist=!0,v=null):i==="vhs-json"&&p.playlists?v=new fh(p.playlists[0],t,a):p.resolvedUri?v=new fh(p.resolvedUri,t,a):p.playlists&&i==="dash"?v=new WT(p.playlists[0],t,a,c):v=null,p=It({id:f,playlistLoader:v},p),w4[r](r,p.playlistLoader,e),o[d].push(p),typeof l[f]>"u"){const g=new K.AudioTrack({id:f,kind:Qie(p),enabled:!1,language:p.language,default:p.default,label:f});l[f]=g}}}n.on("error",ly[r](r,e))},SUBTITLES:(r,e)=>{const{tech:t,vhs:i,sourceType:n,segmentLoaders:{[r]:a},requestOptions:s,main:{mediaGroups:o},mediaTypes:{[r]:{groups:l,tracks:u}},mainPlaylistLoader:c}=e;for(const h in o[r]){l[h]||(l[h]=[]);for(const d in o[r][h]){if(!i.options_.useForcedSubtitles&&o[r][h][d].forced)continue;let f=o[r][h][d],p;if(n==="hls")p=new fh(f.resolvedUri,i,s);else if(n==="dash"){if(!f.playlists.filter(g=>g.excludeUntil!==1/0).length)return;p=new WT(f.playlists[0],i,s,c)}else n==="vhs-json"&&(p=new fh(f.playlists?f.playlists[0]:f.resolvedUri,i,s));if(f=It({id:d,playlistLoader:p},f),w4[r](r,f.playlistLoader,e),l[h].push(f),typeof u[d]>"u"){const v=t.addRemoteTextTrack({id:d,kind:"subtitles",default:f.default&&f.autoselect,language:f.language,label:d},!1).track;u[d]=v}}}a.on("error",ly[r](r,e))},"CLOSED-CAPTIONS":(r,e)=>{const{tech:t,main:{mediaGroups:i},mediaTypes:{[r]:{groups:n,tracks:a}}}=e;for(const s in i[r]){n[s]||(n[s]=[]);for(const o in i[r][s]){const l=i[r][s][o];if(!/^(?:CC|SERVICE)/.test(l.instreamId))continue;const u=t.options_.vhs&&t.options_.vhs.captionServices||{};let c={label:o,language:l.language,instreamId:l.instreamId,default:l.default&&l.autoselect};if(u[c.instreamId]&&(c=It(c,u[c.instreamId])),c.default===void 0&&delete c.default,n[s].push(It({id:o},l)),typeof a[o]>"u"){const h=t.addRemoteTextTrack({id:c.instreamId,kind:"captions",default:c.default,language:c.language,label:c.label},!1).track;a[o]=h}}}}},Y9=(r,e)=>{for(let t=0;tt=>{const{mainPlaylistLoader:i,mediaTypes:{[r]:{groups:n}}}=e,a=i.media();if(!a)return null;let s=null;a.attributes[r]&&(s=n[a.attributes[r]]);const o=Object.keys(n);if(!s)if(r==="AUDIO"&&o.length>1&&jv(e.main))for(let l=0;l"u"?s:t===null||!s?null:s.filter(l=>l.id===t.id)[0]||null},nne={AUDIO:(r,e)=>()=>{const{mediaTypes:{[r]:{tracks:t}}}=e;for(const i in t)if(t[i].enabled)return t[i];return null},SUBTITLES:(r,e)=>()=>{const{mediaTypes:{[r]:{tracks:t}}}=e;for(const i in t)if(t[i].mode==="showing"||t[i].mode==="hidden")return t[i];return null}},ane=(r,{mediaTypes:e})=>()=>{const t=e[r].activeTrack();return t?e[r].activeGroup(t):null},sne=r=>{["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(u=>{rne[u](u,r)});const{mediaTypes:e,mainPlaylistLoader:t,tech:i,vhs:n,segmentLoaders:{["AUDIO"]:a,main:s}}=r;["AUDIO","SUBTITLES"].forEach(u=>{e[u].activeGroup=ine(u,r),e[u].activeTrack=nne[u](u,r),e[u].onGroupChanged=Jie(u,r),e[u].onGroupChanging=ene(u,r),e[u].onTrackChanged=tne(u,r),e[u].getActiveGroup=ane(u,r)});const o=e.AUDIO.activeGroup();if(o){const u=(o.filter(h=>h.default)[0]||o[0]).id;e.AUDIO.tracks[u].enabled=!0,e.AUDIO.onGroupChanged(),e.AUDIO.onTrackChanged(),e.AUDIO.getActiveGroup().playlistLoader?(s.setAudio(!1),a.setAudio(!0)):s.setAudio(!0)}t.on("mediachange",()=>{["AUDIO","SUBTITLES"].forEach(u=>e[u].onGroupChanged())}),t.on("mediachanging",()=>{["AUDIO","SUBTITLES"].forEach(u=>e[u].onGroupChanging())});const l=()=>{e.AUDIO.onTrackChanged(),i.trigger({type:"usage",name:"vhs-audio-change"})};i.audioTracks().addEventListener("change",l),i.remoteTextTracks().addEventListener("change",e.SUBTITLES.onTrackChanged),n.on("dispose",()=>{i.audioTracks().removeEventListener("change",l),i.remoteTextTracks().removeEventListener("change",e.SUBTITLES.onTrackChanged)}),i.clearTracks("audio");for(const u in e.AUDIO.tracks)i.audioTracks().addTrack(e.AUDIO.tracks[u])},one=()=>{const r={};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(e=>{r[e]={groups:{},tracks:{},activePlaylistLoader:null,activeGroup:As,activeTrack:As,getActiveGroup:As,onGroupChanged:As,onTrackChanged:As,lastTrack_:null,logger_:Kn(`MediaGroups[${e}]`)}}),r};class C4{constructor(){this.priority_=[],this.pathwayClones_=new Map}set version(e){e===1&&(this.version_=e)}set ttl(e){this.ttl_=e||300}set reloadUri(e){e&&(this.reloadUri_=Ni(this.reloadUri_,e))}set priority(e){e&&e.length&&(this.priority_=e)}set pathwayClones(e){e&&e.length&&(this.pathwayClones_=new Map(e.map(t=>[t.ID,t])))}get version(){return this.version_}get ttl(){return this.ttl_}get reloadUri(){return this.reloadUri_}get priority(){return this.priority_}get pathwayClones(){return this.pathwayClones_}}class lne extends K.EventTarget{constructor(e,t){super(),this.currentPathway=null,this.defaultPathway=null,this.queryBeforeStart=!1,this.availablePathways_=new Set,this.steeringManifest=new C4,this.proxyServerUrl_=null,this.manifestType_=null,this.ttlTimeout_=null,this.request_=null,this.currentPathwayClones=new Map,this.nextPathwayClones=new Map,this.excludedSteeringManifestURLs=new Set,this.logger_=Kn("Content Steering"),this.xhr_=e,this.getBandwidth_=t}assignTagProperties(e,t){this.manifestType_=t.serverUri?"HLS":"DASH";const i=t.serverUri||t.serverURL;if(!i){this.logger_(`steering manifest URL is ${i}, cannot request steering manifest.`),this.trigger("error");return}if(i.startsWith("data:")){this.decodeDataUriManifest_(i.substring(i.indexOf(",")+1));return}this.steeringManifest.reloadUri=Ni(e,i),this.defaultPathway=t.pathwayId||t.defaultServiceLocation,this.queryBeforeStart=t.queryBeforeStart,this.proxyServerUrl_=t.proxyServerURL,this.defaultPathway&&!this.queryBeforeStart&&this.trigger("content-steering")}requestSteeringManifest(e){const t=this.steeringManifest.reloadUri;if(!t)return;const i=e?t:this.getRequestURI(t);if(!i){this.logger_("No valid content steering manifest URIs. Stopping content steering."),this.trigger("error"),this.dispose();return}const n={contentSteeringInfo:{uri:i}};this.trigger({type:"contentsteeringloadstart",metadata:n}),this.request_=this.xhr_({uri:i,requestType:"content-steering-manifest"},(a,s)=>{if(a){if(s.status===410){this.logger_(`manifest request 410 ${a}.`),this.logger_(`There will be no more content steering requests to ${i} this session.`),this.excludedSteeringManifestURLs.add(i);return}if(s.status===429){const u=s.responseHeaders["retry-after"];this.logger_(`manifest request 429 ${a}.`),this.logger_(`content steering will retry in ${u} seconds.`),this.startTTLTimeout_(parseInt(u,10));return}this.logger_(`manifest failed to load ${a}.`),this.startTTLTimeout_();return}this.trigger({type:"contentsteeringloadcomplete",metadata:n});let o;try{o=JSON.parse(this.request_.responseText)}catch(u){const c={errorType:K.Error.StreamingContentSteeringParserError,error:u};this.trigger({type:"error",metadata:c})}this.assignSteeringProperties_(o);const l={contentSteeringInfo:n.contentSteeringInfo,contentSteeringManifest:{version:this.steeringManifest.version,reloadUri:this.steeringManifest.reloadUri,priority:this.steeringManifest.priority}};this.trigger({type:"contentsteeringparsed",metadata:l}),this.startTTLTimeout_()})}setProxyServerUrl_(e){const t=new H.URL(e),i=new H.URL(this.proxyServerUrl_);return i.searchParams.set("url",encodeURI(t.toString())),this.setSteeringParams_(i.toString())}decodeDataUriManifest_(e){const t=JSON.parse(H.atob(e));this.assignSteeringProperties_(t)}setSteeringParams_(e){const t=new H.URL(e),i=this.getPathway(),n=this.getBandwidth_();if(i){const a=`_${this.manifestType_}_pathway`;t.searchParams.set(a,i)}if(n){const a=`_${this.manifestType_}_throughput`;t.searchParams.set(a,n)}return t.toString()}assignSteeringProperties_(e){if(this.steeringManifest.version=e.VERSION,!this.steeringManifest.version){this.logger_(`manifest version is ${e.VERSION}, which is not supported.`),this.trigger("error");return}this.steeringManifest.ttl=e.TTL,this.steeringManifest.reloadUri=e["RELOAD-URI"],this.steeringManifest.priority=e["PATHWAY-PRIORITY"]||e["SERVICE-LOCATION-PRIORITY"],this.steeringManifest.pathwayClones=e["PATHWAY-CLONES"],this.nextPathwayClones=this.steeringManifest.pathwayClones,this.availablePathways_.size||(this.logger_("There are no available pathways for content steering. Ending content steering."),this.trigger("error"),this.dispose());const i=(n=>{for(const a of n)if(this.availablePathways_.has(a))return a;return[...this.availablePathways_][0]})(this.steeringManifest.priority);this.currentPathway!==i&&(this.currentPathway=i,this.trigger("content-steering"))}getPathway(){return this.currentPathway||this.defaultPathway}getRequestURI(e){if(!e)return null;const t=n=>this.excludedSteeringManifestURLs.has(n);if(this.proxyServerUrl_){const n=this.setProxyServerUrl_(e);if(!t(n))return n}const i=this.setSteeringParams_(e);return t(i)?null:i}startTTLTimeout_(e=this.steeringManifest.ttl){const t=e*1e3;this.ttlTimeout_=H.setTimeout(()=>{this.requestSteeringManifest()},t)}clearTTLTimeout_(){H.clearTimeout(this.ttlTimeout_),this.ttlTimeout_=null}abort(){this.request_&&this.request_.abort(),this.request_=null}dispose(){this.off("content-steering"),this.off("error"),this.abort(),this.clearTTLTimeout_(),this.currentPathway=null,this.defaultPathway=null,this.queryBeforeStart=null,this.proxyServerUrl_=null,this.manifestType_=null,this.ttlTimeout_=null,this.request_=null,this.excludedSteeringManifestURLs=new Set,this.availablePathways_=new Set,this.steeringManifest=new C4}addAvailablePathway(e){e&&this.availablePathways_.add(e)}clearAvailablePathways(){this.availablePathways_.clear()}excludePathway(e){return this.availablePathways_.delete(e)}didDASHTagChange(e,t){return!t&&this.steeringManifest.reloadUri||t&&(Ni(e,t.serverURL)!==this.steeringManifest.reloadUri||t.defaultServiceLocation!==this.defaultPathway||t.queryBeforeStart!==this.queryBeforeStart||t.proxyServerURL!==this.proxyServerUrl_)}getAvailablePathways(){return this.availablePathways_}}const une=10;let vs;const cne=["mediaRequests","mediaRequestsAborted","mediaRequestsTimedout","mediaRequestsErrored","mediaTransferDuration","mediaBytesTransferred","mediaAppends"],hne=function(r){return this.audioSegmentLoader_[r]+this.mainSegmentLoader_[r]},fne=function({currentPlaylist:r,buffered:e,currentTime:t,nextPlaylist:i,bufferLowWaterLine:n,bufferHighWaterLine:a,duration:s,bufferBasedABR:o,log:l}){if(!i)return K.log.warn("We received no playlist to switch to. Please check your stream."),!1;const u=`allowing switch ${r&&r.id||"null"} -> ${i.id}`;if(!r)return l(`${u} as current playlist is not set`),!0;if(i.id===r.id)return!1;const c=!!hh(e,t).length;if(!r.endList)return!c&&typeof r.partTargetDuration=="number"?(l(`not ${u} as current playlist is live llhls, but currentTime isn't in buffered.`),!1):(l(`${u} as current playlist is live`),!0);const h=fA(e,t),d=o?Fr.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:Fr.MAX_BUFFER_LOW_WATER_LINE;if(sp)&&h>=n){let v=`${u} as forwardBuffer >= bufferLowWaterLine (${h} >= ${n})`;return o&&(v+=` and next bandwidth > current bandwidth (${f} > ${p})`),l(v),!0}return l(`not ${u} as no switching criteria met`),!1};class dne extends K.EventTarget{constructor(e){super();const{src:t,withCredentials:i,tech:n,bandwidth:a,externVhs:s,useCueTags:o,playlistExclusionDuration:l,enableLowInitialPlaylist:u,sourceType:c,cacheEncryptionKeys:h,bufferBasedABR:d,leastPixelDiffSelector:f,captionServices:p,experimentalUseMMS:v}=e;if(!t)throw new Error("A non-empty playlist URL or JSON manifest string is required");let{maxPlaylistRetries:g}=e;(g===null||typeof g>"u")&&(g=1/0),vs=s,this.bufferBasedABR=!!d,this.leastPixelDiffSelector=!!f,this.withCredentials=i,this.tech_=n,this.vhs_=n.vhs,this.player_=e.player_,this.sourceType_=c,this.useCueTags_=o,this.playlistExclusionDuration=l,this.maxPlaylistRetries=g,this.enableLowInitialPlaylist=u,this.useCueTags_&&(this.cueTagsTrack_=this.tech_.addTextTrack("metadata","ad-cues"),this.cueTagsTrack_.inBandMetadataTrackDispatchType=""),this.requestOptions_={withCredentials:i,maxPlaylistRetries:g,timeout:null},this.on("error",this.pauseLoading),this.mediaTypes_=one(),v&&H.ManagedMediaSource?(this.tech_.el_.disableRemotePlayback=!0,this.mediaSource=new H.ManagedMediaSource,K.log("Using ManagedMediaSource")):H.MediaSource&&(this.mediaSource=new H.MediaSource),this.handleDurationChange_=this.handleDurationChange_.bind(this),this.handleSourceOpen_=this.handleSourceOpen_.bind(this),this.handleSourceEnded_=this.handleSourceEnded_.bind(this),this.mediaSource.addEventListener("durationchange",this.handleDurationChange_),this.mediaSource.addEventListener("sourceopen",this.handleSourceOpen_),this.mediaSource.addEventListener("sourceended",this.handleSourceEnded_),this.seekable_=Kr(),this.hasPlayed_=!1,this.syncController_=new Xie(e),this.segmentMetadataTrack_=n.addRemoteTextTrack({kind:"metadata",label:"segment-metadata"},!1).track,this.decrypter_=new Zie,this.sourceUpdater_=new q9(this.mediaSource),this.inbandTextTracks_={},this.timelineChangeController_=new Yie,this.keyStatusMap_=new Map;const m={vhs:this.vhs_,parse708captions:e.parse708captions,useDtsForTimestampOffset:e.useDtsForTimestampOffset,captionServices:p,mediaSource:this.mediaSource,currentTime:this.tech_.currentTime.bind(this.tech_),seekable:()=>this.seekable(),seeking:()=>this.tech_.seeking(),duration:()=>this.duration(),hasPlayed:()=>this.hasPlayed_,goalBufferLength:()=>this.goalBufferLength(),bandwidth:a,syncController:this.syncController_,decrypter:this.decrypter_,sourceType:this.sourceType_,inbandTextTracks:this.inbandTextTracks_,cacheEncryptionKeys:h,sourceUpdater:this.sourceUpdater_,timelineChangeController:this.timelineChangeController_,exactManifestTimings:e.exactManifestTimings,addMetadataToTextTrack:this.addMetadataToTextTrack.bind(this)};this.mainPlaylistLoader_=this.sourceType_==="dash"?new WT(t,this.vhs_,It(this.requestOptions_,{addMetadataToTextTrack:this.addMetadataToTextTrack.bind(this)})):new fh(t,this.vhs_,It(this.requestOptions_,{addDateRangesToTextTrack:this.addDateRangesToTextTrack_.bind(this)})),this.setupMainPlaylistLoaderListeners_(),this.mainSegmentLoader_=new XT(It(m,{segmentMetadataTrack:this.segmentMetadataTrack_,loaderType:"main"}),e),this.audioSegmentLoader_=new XT(It(m,{loaderType:"audio"}),e),this.subtitleSegmentLoader_=new Hie(It(m,{loaderType:"vtt",featuresNativeTextTracks:this.tech_.featuresNativeTextTracks,loadVttJs:()=>new Promise((b,T)=>{function x(){n.off("vttjserror",C),b()}function C(){n.off("vttjsloaded",x),T()}n.one("vttjsloaded",x),n.one("vttjserror",C),n.addWebVttScript_()})}),e);const y=()=>this.mainSegmentLoader_.bandwidth;this.contentSteeringController_=new lne(this.vhs_.xhr,y),this.setupSegmentLoaderListeners_(),this.bufferBasedABR&&(this.mainPlaylistLoader_.one("loadedplaylist",()=>this.startABRTimer_()),this.tech_.on("pause",()=>this.stopABRTimer_()),this.tech_.on("play",()=>this.startABRTimer_())),cne.forEach(b=>{this[b+"_"]=hne.bind(this,b)}),this.logger_=Kn("pc"),this.triggeredFmp4Usage=!1,this.tech_.preload()==="none"?(this.loadOnPlay_=()=>{this.loadOnPlay_=null,this.mainPlaylistLoader_.load()},this.tech_.one("play",this.loadOnPlay_)):this.mainPlaylistLoader_.load(),this.timeToLoadedData__=-1,this.mainAppendsToLoadedData__=-1,this.audioAppendsToLoadedData__=-1;const _=this.tech_.preload()==="none"?"play":"loadstart";this.tech_.one(_,()=>{const b=Date.now();this.tech_.one("loadeddata",()=>{this.timeToLoadedData__=Date.now()-b,this.mainAppendsToLoadedData__=this.mainSegmentLoader_.mediaAppends,this.audioAppendsToLoadedData__=this.audioSegmentLoader_.mediaAppends})})}mainAppendsToLoadedData_(){return this.mainAppendsToLoadedData__}audioAppendsToLoadedData_(){return this.audioAppendsToLoadedData__}appendsToLoadedData_(){const e=this.mainAppendsToLoadedData_(),t=this.audioAppendsToLoadedData_();return e===-1||t===-1?-1:e+t}timeToLoadedData_(){return this.timeToLoadedData__}checkABR_(e="abr"){const t=this.selectPlaylist();t&&this.shouldSwitchToMedia_(t)&&this.switchMedia_(t,e)}switchMedia_(e,t,i){const n=this.media(),a=n&&(n.id||n.uri),s=e&&(e.id||e.uri);if(a&&a!==s){this.logger_(`switch media ${a} -> ${s} from ${t}`);const o={renditionInfo:{id:s,bandwidth:e.attributes.BANDWIDTH,resolution:e.attributes.RESOLUTION,codecs:e.attributes.CODECS},cause:t};this.trigger({type:"renditionselected",metadata:o}),this.tech_.trigger({type:"usage",name:`vhs-rendition-change-${t}`})}this.mainPlaylistLoader_.media(e,i)}switchMediaForDASHContentSteering_(){["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(e=>{const t=this.mediaTypes_[e],i=t?t.activeGroup():null,n=this.contentSteeringController_.getPathway();if(i&&n){const s=(i.length?i[0].playlists:i.playlists).filter(o=>o.attributes.serviceLocation===n);s.length&&this.mediaTypes_[e].activePlaylistLoader.media(s[0])}})}startABRTimer_(){this.stopABRTimer_(),this.abrTimer_=H.setInterval(()=>this.checkABR_(),250)}stopABRTimer_(){this.tech_.scrubbing&&this.tech_.scrubbing()||(H.clearInterval(this.abrTimer_),this.abrTimer_=null)}getAudioTrackPlaylists_(){const e=this.main(),t=e&&e.playlists||[];if(!e||!e.mediaGroups||!e.mediaGroups.AUDIO)return t;const i=e.mediaGroups.AUDIO,n=Object.keys(i);let a;if(Object.keys(this.mediaTypes_.AUDIO.groups).length)a=this.mediaTypes_.AUDIO.activeTrack();else{const o=i.main||n.length&&i[n[0]];for(const l in o)if(o[l].default){a={label:l};break}}if(!a)return t;const s=[];for(const o in i)if(i[o][a.label]){const l=i[o][a.label];if(l.playlists&&l.playlists.length)s.push.apply(s,l.playlists);else if(l.uri)s.push(l);else if(e.playlists.length)for(let u=0;u{const t=this.mainPlaylistLoader_.media(),i=t.targetDuration*1.5*1e3;VT(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.media())?this.requestOptions_.timeout=0:this.requestOptions_.timeout=i,t.endList&&this.tech_.preload()!=="none"&&(this.mainSegmentLoader_.playlist(t,this.requestOptions_),this.mainSegmentLoader_.load()),sne({sourceType:this.sourceType_,segmentLoaders:{AUDIO:this.audioSegmentLoader_,SUBTITLES:this.subtitleSegmentLoader_,main:this.mainSegmentLoader_},tech:this.tech_,requestOptions:this.requestOptions_,mainPlaylistLoader:this.mainPlaylistLoader_,vhs:this.vhs_,main:this.main(),mediaTypes:this.mediaTypes_,excludePlaylist:this.excludePlaylist.bind(this)}),this.triggerPresenceUsage_(this.main(),t),this.setupFirstPlay(),!this.mediaTypes_.AUDIO.activePlaylistLoader||this.mediaTypes_.AUDIO.activePlaylistLoader.media()?this.trigger("selectedinitialmedia"):this.mediaTypes_.AUDIO.activePlaylistLoader.one("loadedmetadata",()=>{this.trigger("selectedinitialmedia")})}),this.mainPlaylistLoader_.on("loadedplaylist",()=>{this.loadOnPlay_&&this.tech_.off("play",this.loadOnPlay_);let t=this.mainPlaylistLoader_.media();if(!t){this.attachContentSteeringListeners_(),this.initContentSteeringController_(),this.excludeUnsupportedVariants_();let i;if(this.enableLowInitialPlaylist&&(i=this.selectInitialPlaylist()),i||(i=this.selectPlaylist()),!i||!this.shouldSwitchToMedia_(i)||(this.initialMedia_=i,this.switchMedia_(this.initialMedia_,"initial"),!(this.sourceType_==="vhs-json"&&this.initialMedia_.segments)))return;t=this.initialMedia_}this.handleUpdatedMediaPlaylist(t)}),this.mainPlaylistLoader_.on("error",()=>{const t=this.mainPlaylistLoader_.error;this.excludePlaylist({playlistToExclude:t.playlist,error:t})}),this.mainPlaylistLoader_.on("mediachanging",()=>{this.mainSegmentLoader_.abort(),this.mainSegmentLoader_.pause()}),this.mainPlaylistLoader_.on("mediachange",()=>{const t=this.mainPlaylistLoader_.media(),i=t.targetDuration*1.5*1e3;VT(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.media())?this.requestOptions_.timeout=0:this.requestOptions_.timeout=i,this.sourceType_==="dash"&&this.mainPlaylistLoader_.load(),this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.playlist(t,this.requestOptions_),this.waitingForFastQualityPlaylistReceived_?this.runFastQualitySwitch_():this.mainSegmentLoader_.load(),this.tech_.trigger({type:"mediachange",bubbles:!0})}),this.mainPlaylistLoader_.on("playlistunchanged",()=>{const t=this.mainPlaylistLoader_.media();if(t.lastExcludeReason_==="playlist-unchanged")return;this.stuckAtPlaylistEnd_(t)&&(this.excludePlaylist({error:{message:"Playlist no longer updating.",reason:"playlist-unchanged"}}),this.tech_.trigger("playliststuck"))}),this.mainPlaylistLoader_.on("renditiondisabled",()=>{this.tech_.trigger({type:"usage",name:"vhs-rendition-disabled"})}),this.mainPlaylistLoader_.on("renditionenabled",()=>{this.tech_.trigger({type:"usage",name:"vhs-rendition-enabled"})}),["manifestrequeststart","manifestrequestcomplete","manifestparsestart","manifestparsecomplete","playlistrequeststart","playlistrequestcomplete","playlistparsestart","playlistparsecomplete","renditiondisabled","renditionenabled"].forEach(t=>{this.mainPlaylistLoader_.on(t,i=>{this.player_.trigger(ar({},i))})})}handleUpdatedMediaPlaylist(e){this.useCueTags_&&this.updateAdCues_(e),this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.playlist(e,this.requestOptions_),this.waitingForFastQualityPlaylistReceived_&&this.runFastQualitySwitch_(),this.updateDuration(!e.endList),this.tech_.paused()||(this.mainSegmentLoader_.load(),this.audioSegmentLoader_&&this.audioSegmentLoader_.load())}triggerPresenceUsage_(e,t){const i=e.mediaGroups||{};let n=!0;const a=Object.keys(i.AUDIO);for(const s in i.AUDIO)for(const o in i.AUDIO[s])i.AUDIO[s][o].uri||(n=!1);n&&this.tech_.trigger({type:"usage",name:"vhs-demuxed"}),Object.keys(i.SUBTITLES).length&&this.tech_.trigger({type:"usage",name:"vhs-webvtt"}),vs.Playlist.isAes(t)&&this.tech_.trigger({type:"usage",name:"vhs-aes"}),a.length&&Object.keys(i.AUDIO[a[0]]).length>1&&this.tech_.trigger({type:"usage",name:"vhs-alternate-audio"}),this.useCueTags_&&this.tech_.trigger({type:"usage",name:"vhs-playlist-cue-tags"})}shouldSwitchToMedia_(e){const t=this.mainPlaylistLoader_.media()||this.mainPlaylistLoader_.pendingMedia_,i=this.tech_.currentTime(),n=this.bufferLowWaterLine(),a=this.bufferHighWaterLine(),s=this.tech_.buffered();return fne({buffered:s,currentTime:i,currentPlaylist:t,nextPlaylist:e,bufferLowWaterLine:n,bufferHighWaterLine:a,duration:this.duration(),bufferBasedABR:this.bufferBasedABR,log:this.logger_})}setupSegmentLoaderListeners_(){this.mainSegmentLoader_.on("bandwidthupdate",()=>{this.checkABR_("bandwidthupdate"),this.tech_.trigger("bandwidthupdate")}),this.mainSegmentLoader_.on("timeout",()=>{this.bufferBasedABR&&this.mainSegmentLoader_.load()}),this.bufferBasedABR||this.mainSegmentLoader_.on("progress",()=>{this.trigger("progress")}),this.mainSegmentLoader_.on("error",()=>{const i=this.mainSegmentLoader_.error();this.excludePlaylist({playlistToExclude:i.playlist,error:i})}),this.mainSegmentLoader_.on("appenderror",()=>{this.error=this.mainSegmentLoader_.error_,this.trigger("error")}),this.mainSegmentLoader_.on("syncinfoupdate",()=>{this.onSyncInfoUpdate_()}),this.mainSegmentLoader_.on("timestampoffset",()=>{this.tech_.trigger({type:"usage",name:"vhs-timestamp-offset"})}),this.audioSegmentLoader_.on("syncinfoupdate",()=>{this.onSyncInfoUpdate_()}),this.audioSegmentLoader_.on("appenderror",()=>{this.error=this.audioSegmentLoader_.error_,this.trigger("error")}),this.mainSegmentLoader_.on("ended",()=>{this.logger_("main segment loader ended"),this.onEndOfStream()}),this.timelineChangeController_.on("audioTimelineBehind",()=>{const i=this.audioSegmentLoader_.pendingSegment_;if(!i||!i.segment||!i.segment.syncInfo)return;const n=i.segment.syncInfo.end+.01;this.tech_.setCurrentTime(n)}),this.mainSegmentLoader_.on("earlyabort",i=>{this.bufferBasedABR||(this.delegateLoaders_("all",["abort"]),this.excludePlaylist({error:{message:"Aborted early because there isn't enough bandwidth to complete the request without rebuffering."},playlistExclusionDuration:une}))});const e=()=>{if(!this.sourceUpdater_.hasCreatedSourceBuffers())return this.tryToCreateSourceBuffers_();const i=this.getCodecsOrExclude_();i&&this.sourceUpdater_.addOrChangeSourceBuffers(i)};this.mainSegmentLoader_.on("trackinfo",e),this.audioSegmentLoader_.on("trackinfo",e),this.mainSegmentLoader_.on("fmp4",()=>{this.triggeredFmp4Usage||(this.tech_.trigger({type:"usage",name:"vhs-fmp4"}),this.triggeredFmp4Usage=!0)}),this.audioSegmentLoader_.on("fmp4",()=>{this.triggeredFmp4Usage||(this.tech_.trigger({type:"usage",name:"vhs-fmp4"}),this.triggeredFmp4Usage=!0)}),this.audioSegmentLoader_.on("ended",()=>{this.logger_("audioSegmentLoader ended"),this.onEndOfStream()}),["segmentselected","segmentloadstart","segmentloaded","segmentkeyloadstart","segmentkeyloadcomplete","segmentdecryptionstart","segmentdecryptioncomplete","segmenttransmuxingstart","segmenttransmuxingcomplete","segmenttransmuxingtrackinfoavailable","segmenttransmuxingtiminginfoavailable","segmentappendstart","appendsdone","bandwidthupdated","timelinechange","codecschange"].forEach(i=>{this.mainSegmentLoader_.on(i,n=>{this.player_.trigger(ar({},n))}),this.audioSegmentLoader_.on(i,n=>{this.player_.trigger(ar({},n))}),this.subtitleSegmentLoader_.on(i,n=>{this.player_.trigger(ar({},n))})})}mediaSecondsLoaded_(){return Math.max(this.audioSegmentLoader_.mediaSecondsLoaded+this.mainSegmentLoader_.mediaSecondsLoaded)}load(){this.mainSegmentLoader_.load(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.load(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.load()}fastQualityChange_(e=this.selectPlaylist()){if(e&&e===this.mainPlaylistLoader_.media()){this.logger_("skipping fastQualityChange because new media is same as old");return}this.switchMedia_(e,"fast-quality"),this.waitingForFastQualityPlaylistReceived_=!0}runFastQualitySwitch_(){this.waitingForFastQualityPlaylistReceived_=!1,this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.resetEverything(()=>{this.mainSegmentLoader_.load()})}play(){if(this.setupFirstPlay())return;this.tech_.ended()&&this.tech_.setCurrentTime(0),this.hasPlayed_&&this.load();const e=this.tech_.seekable();if(this.tech_.duration()===1/0&&this.tech_.currentTime(){})}this.trigger("sourceopen")}handleSourceEnded_(){if(!this.inbandTextTracks_.metadataTrack_)return;const e=this.inbandTextTracks_.metadataTrack_.cues;if(!e||!e.length)return;const t=this.duration();e[e.length-1].endTime=isNaN(t)||Math.abs(t)===1/0?Number.MAX_VALUE:t}handleDurationChange_(){this.tech_.trigger("durationchange")}onEndOfStream(){let e=this.mainSegmentLoader_.ended_;if(this.mediaTypes_.AUDIO.activePlaylistLoader){const t=this.mainSegmentLoader_.getCurrentMediaInfo_();!t||t.hasVideo?e=e&&this.audioSegmentLoader_.ended_:e=this.audioSegmentLoader_.ended_}e&&(this.stopABRTimer_(),this.sourceUpdater_.endOfStream())}stuckAtPlaylistEnd_(e){if(!this.seekable().length)return!1;const i=this.syncController_.getExpiredTime(e,this.duration());if(i===null)return!1;const n=vs.Playlist.playlistEnd(e,i),a=this.tech_.currentTime(),s=this.tech_.buffered();if(!s.length)return n-a<=Ga;const o=s.end(s.length-1);return o-a<=Ga&&n-o<=Ga}excludePlaylist({playlistToExclude:e=this.mainPlaylistLoader_.media(),error:t={},playlistExclusionDuration:i}){if(e=e||this.mainPlaylistLoader_.media(),i=i||t.playlistExclusionDuration||this.playlistExclusionDuration,!e){this.error=t,this.mediaSource.readyState!=="open"?this.trigger("error"):this.sourceUpdater_.endOfStream("network");return}e.playlistErrors_++;const n=this.mainPlaylistLoader_.main.playlists,a=n.filter($_),s=a.length===1&&a[0]===e;if(n.length===1&&i!==1/0)return K.log.warn(`Problem encountered with playlist ${e.id}. Trying again since it is the only playlist.`),this.tech_.trigger("retryplaylist"),this.mainPlaylistLoader_.load(s);if(s){if(this.main().contentSteering){const p=this.pathwayAttribute_(e),v=this.contentSteeringController_.steeringManifest.ttl*1e3;this.contentSteeringController_.excludePathway(p),this.excludeThenChangePathway_(),setTimeout(()=>{this.contentSteeringController_.addAvailablePathway(p)},v);return}let f=!1;n.forEach(p=>{if(p===e)return;const v=p.excludeUntil;typeof v<"u"&&v!==1/0&&(f=!0,delete p.excludeUntil)}),f&&(K.log.warn("Removing other playlists from the exclusion list because the last rendition is about to be excluded."),this.tech_.trigger("retryplaylist"))}let o;e.playlistErrors_>this.maxPlaylistRetries?o=1/0:o=Date.now()+i*1e3,e.excludeUntil=o,t.reason&&(e.lastExcludeReason_=t.reason),this.tech_.trigger("excludeplaylist"),this.tech_.trigger({type:"usage",name:"vhs-rendition-excluded"});const l=this.selectPlaylist();if(!l){this.error="Playback cannot continue. No available working or supported playlists.",this.trigger("error");return}const u=t.internal?this.logger_:K.log.warn,c=t.message?" "+t.message:"";u(`${t.internal?"Internal problem":"Problem"} encountered with playlist ${e.id}.${c} Switching to playlist ${l.id}.`),l.attributes.AUDIO!==e.attributes.AUDIO&&this.delegateLoaders_("audio",["abort","pause"]),l.attributes.SUBTITLES!==e.attributes.SUBTITLES&&this.delegateLoaders_("subtitle",["abort","pause"]),this.delegateLoaders_("main",["abort","pause"]);const h=l.targetDuration/2*1e3||5*1e3,d=typeof l.lastRequest=="number"&&Date.now()-l.lastRequest<=h;return this.switchMedia_(l,"exclude",s||d)}pauseLoading(){this.delegateLoaders_("all",["abort","pause"]),this.stopABRTimer_()}delegateLoaders_(e,t){const i=[],n=e==="all";(n||e==="main")&&i.push(this.mainPlaylistLoader_);const a=[];(n||e==="audio")&&a.push("AUDIO"),(n||e==="subtitle")&&(a.push("CLOSED-CAPTIONS"),a.push("SUBTITLES")),a.forEach(s=>{const o=this.mediaTypes_[s]&&this.mediaTypes_[s].activePlaylistLoader;o&&i.push(o)}),["main","audio","subtitle"].forEach(s=>{const o=this[`${s}SegmentLoader_`];o&&(e===s||e==="all")&&i.push(o)}),i.forEach(s=>t.forEach(o=>{typeof s[o]=="function"&&s[o]()}))}setCurrentTime(e){const t=hh(this.tech_.buffered(),e);if(!(this.mainPlaylistLoader_&&this.mainPlaylistLoader_.media())||!this.mainPlaylistLoader_.media().segments)return 0;if(t&&t.length)return e;this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.resetEverything(),this.mediaTypes_.AUDIO.activePlaylistLoader&&(this.audioSegmentLoader_.pause(),this.audioSegmentLoader_.resetEverything()),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&(this.subtitleSegmentLoader_.pause(),this.subtitleSegmentLoader_.resetEverything()),this.load()}duration(){if(!this.mainPlaylistLoader_)return 0;const e=this.mainPlaylistLoader_.media();return e?e.endList?this.mediaSource?this.mediaSource.duration:vs.Playlist.duration(e):1/0:0}seekable(){return this.seekable_}onSyncInfoUpdate_(){let e;if(!this.mainPlaylistLoader_)return;let t=this.mainPlaylistLoader_.media();if(!t)return;let i=this.syncController_.getExpiredTime(t,this.duration());if(i===null)return;const n=this.mainPlaylistLoader_.main,a=vs.Playlist.seekable(t,i,vs.Playlist.liveEdgeDelay(n,t));if(a.length===0||this.mediaTypes_.AUDIO.activePlaylistLoader&&(t=this.mediaTypes_.AUDIO.activePlaylistLoader.media(),i=this.syncController_.getExpiredTime(t,this.duration()),i===null||(e=vs.Playlist.seekable(t,i,vs.Playlist.liveEdgeDelay(n,t)),e.length===0)))return;let s,o;if(this.seekable_&&this.seekable_.length&&(s=this.seekable_.end(0),o=this.seekable_.start(0)),e?e.start(0)>a.end(0)||a.start(0)>e.end(0)?this.seekable_=a:this.seekable_=Kr([[e.start(0)>a.start(0)?e.start(0):a.start(0),e.end(0)0&&(i=Math.max(i,t.end(t.length-1))),this.mediaSource.duration!==i&&this.sourceUpdater_.setDuration(i)}dispose(){this.trigger("dispose"),this.decrypter_.terminate(),this.mainPlaylistLoader_.dispose(),this.mainSegmentLoader_.dispose(),this.contentSteeringController_.dispose(),this.keyStatusMap_.clear(),this.loadOnPlay_&&this.tech_.off("play",this.loadOnPlay_),["AUDIO","SUBTITLES"].forEach(e=>{const t=this.mediaTypes_[e].groups;for(const i in t)t[i].forEach(n=>{n.playlistLoader&&n.playlistLoader.dispose()})}),this.audioSegmentLoader_.dispose(),this.subtitleSegmentLoader_.dispose(),this.sourceUpdater_.dispose(),this.timelineChangeController_.dispose(),this.stopABRTimer_(),this.updateDuration_&&this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.mediaSource.removeEventListener("durationchange",this.handleDurationChange_),this.mediaSource.removeEventListener("sourceopen",this.handleSourceOpen_),this.mediaSource.removeEventListener("sourceended",this.handleSourceEnded_),this.off()}main(){return this.mainPlaylistLoader_.main}media(){return this.mainPlaylistLoader_.media()||this.initialMedia_}areMediaTypesKnown_(){const e=!!this.mediaTypes_.AUDIO.activePlaylistLoader,t=!!this.mainSegmentLoader_.getCurrentMediaInfo_(),i=e?!!this.audioSegmentLoader_.getCurrentMediaInfo_():!0;return!(!t||!i)}getCodecsOrExclude_(){const e={main:this.mainSegmentLoader_.getCurrentMediaInfo_()||{},audio:this.audioSegmentLoader_.getCurrentMediaInfo_()||{}},t=this.mainSegmentLoader_.getPendingSegmentPlaylist()||this.media();e.video=e.main;const i=bp(this.main(),t),n={},a=!!this.mediaTypes_.AUDIO.activePlaylistLoader;if(e.main.hasVideo&&(n.video=i.video||e.main.videoCodec||MQ),e.main.isMuxed&&(n.video+=`,${i.audio||e.main.audioCodec||sI}`),(e.main.hasAudio&&!e.main.isMuxed||e.audio.hasAudio||a)&&(n.audio=i.audio||e.main.audioCodec||e.audio.audioCodec||sI,e.audio.isFmp4=e.main.hasAudio&&!e.main.isMuxed?e.main.isFmp4:e.audio.isFmp4),!n.audio&&!n.video){this.excludePlaylist({playlistToExclude:t,error:{message:"Could not determine codecs for playlist."},playlistExclusionDuration:1/0});return}const s=(u,c)=>u?pp(c):u2(c),o={};let l;if(["video","audio"].forEach(function(u){if(n.hasOwnProperty(u)&&!s(e[u].isFmp4,n[u])){const c=e[u].isFmp4?"browser":"muxer";o[c]=o[c]||[],o[c].push(n[u]),u==="audio"&&(l=c)}}),a&&l&&t.attributes.AUDIO){const u=t.attributes.AUDIO;this.main().playlists.forEach(c=>{(c.attributes&&c.attributes.AUDIO)===u&&c!==t&&(c.excludeUntil=1/0)}),this.logger_(`excluding audio group ${u} as ${l} does not support codec(s): "${n.audio}"`)}if(Object.keys(o).length){const u=Object.keys(o).reduce((c,h)=>(c&&(c+=", "),c+=`${h} does not support codec(s): "${o[h].join(",")}"`,c),"")+".";this.excludePlaylist({playlistToExclude:t,error:{internal:!0,message:u},playlistExclusionDuration:1/0});return}if(this.sourceUpdater_.hasCreatedSourceBuffers()&&!this.sourceUpdater_.canChangeType()){const u=[];if(["video","audio"].forEach(c=>{const h=(ka(this.sourceUpdater_.codecs[c]||"")[0]||{}).type,d=(ka(n[c]||"")[0]||{}).type;h&&d&&h.toLowerCase()!==d.toLowerCase()&&u.push(`"${this.sourceUpdater_.codecs[c]}" -> "${n[c]}"`)}),u.length){this.excludePlaylist({playlistToExclude:t,error:{message:`Codec switching not supported: ${u.join(", ")}.`,internal:!0},playlistExclusionDuration:1/0});return}}return n}tryToCreateSourceBuffers_(){if(this.mediaSource.readyState!=="open"||this.sourceUpdater_.hasCreatedSourceBuffers()||!this.areMediaTypesKnown_())return;const e=this.getCodecsOrExclude_();if(!e)return;this.sourceUpdater_.createSourceBuffers(e);const t=[e.video,e.audio].filter(Boolean).join(",");this.excludeIncompatibleVariants_(t)}excludeUnsupportedVariants_(){const e=this.main().playlists,t=[];Object.keys(e).forEach(i=>{const n=e[i];if(t.indexOf(n.id)!==-1)return;t.push(n.id);const a=bp(this.main,n),s=[];a.audio&&!u2(a.audio)&&!pp(a.audio)&&s.push(`audio codec ${a.audio}`),a.video&&!u2(a.video)&&!pp(a.video)&&s.push(`video codec ${a.video}`),a.text&&a.text==="stpp.ttml.im1t"&&s.push(`text codec ${a.text}`),s.length&&(n.excludeUntil=1/0,this.logger_(`excluding ${n.id} for unsupported: ${s.join(", ")}`))})}excludeIncompatibleVariants_(e){const t=[],i=this.main().playlists,n=sy(ka(e)),a=f4(n),s=n.video&&ka(n.video)[0]||null,o=n.audio&&ka(n.audio)[0]||null;Object.keys(i).forEach(l=>{const u=i[l];if(t.indexOf(u.id)!==-1||u.excludeUntil===1/0)return;t.push(u.id);const c=[],h=bp(this.mainPlaylistLoader_.main,u),d=f4(h);if(!(!h.audio&&!h.video)){if(d!==a&&c.push(`codec count "${d}" !== "${a}"`),!this.sourceUpdater_.canChangeType()){const f=h.video&&ka(h.video)[0]||null,p=h.audio&&ka(h.audio)[0]||null;f&&s&&f.type.toLowerCase()!==s.type.toLowerCase()&&c.push(`video codec "${f.type}" !== "${s.type}"`),p&&o&&p.type.toLowerCase()!==o.type.toLowerCase()&&c.push(`audio codec "${p.type}" !== "${o.type}"`)}c.length&&(u.excludeUntil=1/0,this.logger_(`excluding ${u.id}: ${c.join(" && ")}`))}})}updateAdCues_(e){let t=0;const i=this.seekable();i.length&&(t=i.start(0)),Wie(e,this.cueTagsTrack_,t)}goalBufferLength(){const e=this.tech_.currentTime(),t=Fr.GOAL_BUFFER_LENGTH,i=Fr.GOAL_BUFFER_LENGTH_RATE,n=Math.max(t,Fr.MAX_GOAL_BUFFER_LENGTH);return Math.min(t+e*i,n)}bufferLowWaterLine(){const e=this.tech_.currentTime(),t=Fr.BUFFER_LOW_WATER_LINE,i=Fr.BUFFER_LOW_WATER_LINE_RATE,n=Math.max(t,Fr.MAX_BUFFER_LOW_WATER_LINE),a=Math.max(t,Fr.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE);return Math.min(t+e*i,this.bufferBasedABR?a:n)}bufferHighWaterLine(){return Fr.BUFFER_HIGH_WATER_LINE}addDateRangesToTextTrack_(e){v4(this.inbandTextTracks_,"com.apple.streaming",this.tech_),xie({inbandTextTracks:this.inbandTextTracks_,dateRanges:e})}addMetadataToTextTrack(e,t,i){const n=this.sourceUpdater_.videoBuffer?this.sourceUpdater_.videoTimestampOffset():this.sourceUpdater_.audioTimestampOffset();v4(this.inbandTextTracks_,e,this.tech_),bie({inbandTextTracks:this.inbandTextTracks_,metadataArray:t,timestampOffset:n,videoDuration:i})}pathwayAttribute_(e){return e.attributes["PATHWAY-ID"]||e.attributes.serviceLocation}initContentSteeringController_(){const e=this.main();if(e.contentSteering){for(const t of e.playlists)this.contentSteeringController_.addAvailablePathway(this.pathwayAttribute_(t));if(this.contentSteeringController_.assignTagProperties(e.uri,e.contentSteering),this.contentSteeringController_.queryBeforeStart){this.contentSteeringController_.requestSteeringManifest(!0);return}this.tech_.one("canplay",()=>{this.contentSteeringController_.requestSteeringManifest()})}}resetContentSteeringController_(){this.contentSteeringController_.clearAvailablePathways(),this.contentSteeringController_.dispose(),this.initContentSteeringController_()}attachContentSteeringListeners_(){this.contentSteeringController_.on("content-steering",this.excludeThenChangePathway_.bind(this)),["contentsteeringloadstart","contentsteeringloadcomplete","contentsteeringparsed"].forEach(t=>{this.contentSteeringController_.on(t,i=>{this.trigger(ar({},i))})}),this.sourceType_==="dash"&&this.mainPlaylistLoader_.on("loadedplaylist",()=>{const t=this.main();(this.contentSteeringController_.didDASHTagChange(t.uri,t.contentSteering)||(()=>{const a=this.contentSteeringController_.getAvailablePathways(),s=[];for(const o of t.playlists){const l=o.attributes.serviceLocation;if(l&&(s.push(l),!a.has(l)))return!0}return!!(!s.length&&a.size)})())&&this.resetContentSteeringController_()})}excludeThenChangePathway_(){const e=this.contentSteeringController_.getPathway();if(!e)return;this.handlePathwayClones_();const i=this.main().playlists,n=new Set;let a=!1;Object.keys(i).forEach(s=>{const o=i[s],l=this.pathwayAttribute_(o),u=l&&e!==l;o.excludeUntil===1/0&&o.lastExcludeReason_==="content-steering"&&!u&&(delete o.excludeUntil,delete o.lastExcludeReason_,a=!0);const h=!o.excludeUntil&&o.excludeUntil!==1/0;!n.has(o.id)&&u&&h&&(n.add(o.id),o.excludeUntil=1/0,o.lastExcludeReason_="content-steering",this.logger_(`excluding ${o.id} for ${o.lastExcludeReason_}`))}),this.contentSteeringController_.manifestType_==="DASH"&&Object.keys(this.mediaTypes_).forEach(s=>{const o=this.mediaTypes_[s];if(o.activePlaylistLoader){const l=o.activePlaylistLoader.media_;l&&l.attributes.serviceLocation!==e&&(a=!0)}}),a&&this.changeSegmentPathway_()}handlePathwayClones_(){const t=this.main().playlists,i=this.contentSteeringController_.currentPathwayClones,n=this.contentSteeringController_.nextPathwayClones;if(i&&i.size||n&&n.size){for(const[s,o]of i.entries())n.get(s)||(this.mainPlaylistLoader_.updateOrDeleteClone(o),this.contentSteeringController_.excludePathway(s));for(const[s,o]of n.entries()){const l=i.get(s);if(!l){t.filter(c=>c.attributes["PATHWAY-ID"]===o["BASE-ID"]).forEach(c=>{this.mainPlaylistLoader_.addClonePathway(o,c)}),this.contentSteeringController_.addAvailablePathway(s);continue}this.equalPathwayClones_(l,o)||(this.mainPlaylistLoader_.updateOrDeleteClone(o,!0),this.contentSteeringController_.addAvailablePathway(s))}this.contentSteeringController_.currentPathwayClones=new Map(JSON.parse(JSON.stringify([...n])))}}equalPathwayClones_(e,t){if(e["BASE-ID"]!==t["BASE-ID"]||e.ID!==t.ID||e["URI-REPLACEMENT"].HOST!==t["URI-REPLACEMENT"].HOST)return!1;const i=e["URI-REPLACEMENT"].PARAMS,n=t["URI-REPLACEMENT"].PARAMS;for(const a in i)if(i[a]!==n[a])return!1;for(const a in n)if(i[a]!==n[a])return!1;return!0}changeSegmentPathway_(){const e=this.selectPlaylist();this.pauseLoading(),this.contentSteeringController_.manifestType_==="DASH"&&this.switchMediaForDASHContentSteering_(),this.switchMedia_(e,"content-steering")}excludeNonUsablePlaylistsByKeyId_(){if(!this.mainPlaylistLoader_||!this.mainPlaylistLoader_.main)return;let e=0;const t="non-usable";this.mainPlaylistLoader_.main.playlists.forEach(i=>{const n=this.mainPlaylistLoader_.getKeyIdSet(i);!n||!n.size||n.forEach(a=>{const s="usable",o=this.keyStatusMap_.has(a)&&this.keyStatusMap_.get(a)===s,l=i.lastExcludeReason_===t&&i.excludeUntil===1/0;o?o&&l&&(delete i.excludeUntil,delete i.lastExcludeReason_,this.logger_(`enabling playlist ${i.id} because key ID ${a} is ${s}`)):(i.excludeUntil!==1/0&&i.lastExcludeReason_!==t&&(i.excludeUntil=1/0,i.lastExcludeReason_=t,this.logger_(`excluding playlist ${i.id} because the key ID ${a} doesn't exist in the keyStatusMap or is not ${s}`)),e++)})}),e>=this.mainPlaylistLoader_.main.playlists.length&&this.mainPlaylistLoader_.main.playlists.forEach(i=>{const n=i&&i.attributes&&i.attributes.RESOLUTION&&i.attributes.RESOLUTION.height<720,a=i.excludeUntil===1/0&&i.lastExcludeReason_===t;n&&a&&(delete i.excludeUntil,K.log.warn(`enabling non-HD playlist ${i.id} because all playlists were excluded due to ${t} key IDs`))})}addKeyStatus_(e,t){const a=(typeof e=="string"?e:zie(e)).slice(0,32).toLowerCase();this.logger_(`KeyStatus '${t}' with key ID ${a} added to the keyStatusMap`),this.keyStatusMap_.set(a,t)}updatePlaylistByKeyStatus(e,t){this.addKeyStatus_(e,t),this.waitingForFastQualityPlaylistReceived_||this.excludeNonUsableThenChangePlaylist_(),this.mainPlaylistLoader_.off("loadedplaylist",this.excludeNonUsableThenChangePlaylist_.bind(this)),this.mainPlaylistLoader_.on("loadedplaylist",this.excludeNonUsableThenChangePlaylist_.bind(this))}excludeNonUsableThenChangePlaylist_(){this.excludeNonUsablePlaylistsByKeyId_(),this.fastQualityChange_()}}const pne=(r,e,t)=>i=>{const n=r.main.playlists[e],a=pA(n),s=$_(n);if(typeof i>"u")return s;i?delete n.disabled:n.disabled=!0;const o={renditionInfo:{id:e,bandwidth:n.attributes.BANDWIDTH,resolution:n.attributes.RESOLUTION,codecs:n.attributes.CODECS},cause:"fast-quality"};return i!==s&&!a&&(t(n),i?r.trigger({type:"renditionenabled",metadata:o}):r.trigger({type:"renditiondisabled",metadata:o})),i};class vne{constructor(e,t,i){const{playlistController_:n}=e,a=n.fastQualityChange_.bind(n);if(t.attributes){const s=t.attributes.RESOLUTION;this.width=s&&s.width,this.height=s&&s.height,this.bandwidth=t.attributes.BANDWIDTH,this.frameRate=t.attributes["FRAME-RATE"]}this.codecs=bp(n.main(),t),this.playlist=t,this.id=i,this.enabled=pne(e.playlists,t.id,a)}}const gne=function(r){r.representations=()=>{const e=r.playlistController_.main(),t=jv(e)?r.playlistController_.getAudioTrackPlaylists_():e.playlists;return t?t.filter(i=>!pA(i)).map((i,n)=>new vne(r,i,i.id)):[]}},A4=["seeking","seeked","pause","playing","error"];class mne extends K.EventTarget{constructor(e){super(),this.playlistController_=e.playlistController,this.tech_=e.tech,this.seekable=e.seekable,this.allowSeeksWithinUnsafeLiveWindow=e.allowSeeksWithinUnsafeLiveWindow,this.liveRangeSafeTimeDelta=e.liveRangeSafeTimeDelta,this.media=e.media,this.playedRanges_=[],this.consecutiveUpdates=0,this.lastRecordedTime=null,this.checkCurrentTimeTimeout_=null,this.logger_=Kn("PlaybackWatcher"),this.logger_("initialize");const t=()=>this.monitorCurrentTime_(),i=()=>this.monitorCurrentTime_(),n=()=>this.techWaiting_(),a=()=>this.resetTimeUpdate_(),s=this.playlistController_,o=["main","subtitle","audio"],l={};o.forEach(c=>{l[c]={reset:()=>this.resetSegmentDownloads_(c),updateend:()=>this.checkSegmentDownloads_(c)},s[`${c}SegmentLoader_`].on("appendsdone",l[c].updateend),s[`${c}SegmentLoader_`].on("playlistupdate",l[c].reset),this.tech_.on(["seeked","seeking"],l[c].reset)});const u=c=>{["main","audio"].forEach(h=>{s[`${h}SegmentLoader_`][c]("appended",this.seekingAppendCheck_)})};this.seekingAppendCheck_=()=>{this.fixesBadSeeks_()&&(this.consecutiveUpdates=0,this.lastRecordedTime=this.tech_.currentTime(),u("off"))},this.clearSeekingAppendCheck_=()=>u("off"),this.watchForBadSeeking_=()=>{this.clearSeekingAppendCheck_(),u("on")},this.tech_.on("seeked",this.clearSeekingAppendCheck_),this.tech_.on("seeking",this.watchForBadSeeking_),this.tech_.on("waiting",n),this.tech_.on(A4,a),this.tech_.on("canplay",i),this.tech_.one("play",t),this.dispose=()=>{this.clearSeekingAppendCheck_(),this.logger_("dispose"),this.tech_.off("waiting",n),this.tech_.off(A4,a),this.tech_.off("canplay",i),this.tech_.off("play",t),this.tech_.off("seeking",this.watchForBadSeeking_),this.tech_.off("seeked",this.clearSeekingAppendCheck_),o.forEach(c=>{s[`${c}SegmentLoader_`].off("appendsdone",l[c].updateend),s[`${c}SegmentLoader_`].off("playlistupdate",l[c].reset),this.tech_.off(["seeked","seeking"],l[c].reset)}),this.checkCurrentTimeTimeout_&&H.clearTimeout(this.checkCurrentTimeTimeout_),this.resetTimeUpdate_()}}monitorCurrentTime_(){this.checkCurrentTime_(),this.checkCurrentTimeTimeout_&&H.clearTimeout(this.checkCurrentTimeTimeout_),this.checkCurrentTimeTimeout_=H.setTimeout(this.monitorCurrentTime_.bind(this),250)}resetSegmentDownloads_(e){const t=this.playlistController_[`${e}SegmentLoader_`];this[`${e}StalledDownloads_`]>0&&this.logger_(`resetting possible stalled download count for ${e} loader`),this[`${e}StalledDownloads_`]=0,this[`${e}Buffered_`]=t.buffered_()}checkSegmentDownloads_(e){const t=this.playlistController_,i=t[`${e}SegmentLoader_`],n=i.buffered_(),a=ire(this[`${e}Buffered_`],n);if(this[`${e}Buffered_`]=n,a){const s={bufferedRanges:n};t.trigger({type:"bufferedrangeschanged",metadata:s}),this.resetSegmentDownloads_(e);return}this[`${e}StalledDownloads_`]++,this.logger_(`found #${this[`${e}StalledDownloads_`]} ${e} appends that did not increase buffer (possible stalled download)`,{playlistId:i.playlist_&&i.playlist_.id,buffered:pu(n)}),!(this[`${e}StalledDownloads_`]<10)&&(this.logger_(`${e} loader stalled download exclusion`),this.resetSegmentDownloads_(e),this.tech_.trigger({type:"usage",name:`vhs-${e}-download-exclusion`}),e!=="subtitle"&&t.excludePlaylist({error:{message:`Excessive ${e} segment downloading detected.`},playlistExclusionDuration:1/0}))}checkCurrentTime_(){if(this.tech_.paused()||this.tech_.seeking())return;const e=this.tech_.currentTime(),t=this.tech_.buffered();if(this.lastRecordedTime===e&&(!t.length||e+Ga>=t.end(t.length-1)))return this.techWaiting_();if(this.consecutiveUpdates>=5&&e===this.lastRecordedTime)this.consecutiveUpdates++,this.waiting_();else if(e===this.lastRecordedTime)this.consecutiveUpdates++;else{this.playedRanges_.push(Kr([this.lastRecordedTime,e]));const i={playedRanges:this.playedRanges_};this.playlistController_.trigger({type:"playedrangeschanged",metadata:i}),this.consecutiveUpdates=0,this.lastRecordedTime=e}}resetTimeUpdate_(){this.consecutiveUpdates=0}fixesBadSeeks_(){if(!this.tech_.seeking())return!1;const t=this.seekable(),i=this.tech_.currentTime(),n=this.afterSeekableWindow_(t,i,this.media(),this.allowSeeksWithinUnsafeLiveWindow);let a;if(n&&(a=t.end(t.length-1)),this.beforeSeekableWindow_(t,i)){const p=t.start(0);a=p+(p===t.end(0)?0:Ga)}if(typeof a<"u")return this.logger_(`Trying to seek outside of seekable at time ${i} with seekable range ${o9(t)}. Seeking to ${a}.`),this.tech_.setCurrentTime(a),!0;const s=this.playlistController_.sourceUpdater_,o=this.tech_.buffered(),l=s.audioBuffer?s.audioBuffered():null,u=s.videoBuffer?s.videoBuffered():null,c=this.media(),h=c.partTargetDuration?c.partTargetDuration:(c.targetDuration-za)*2,d=[l,u];for(let p=0;p ${i.end(0)}]. Attempting to resume playback by seeking to the current time.`),this.tech_.trigger({type:"usage",name:"vhs-unknown-waiting"});return}}techWaiting_(){const e=this.seekable(),t=this.tech_.currentTime();if(this.tech_.seeking())return!0;if(this.beforeSeekableWindow_(e,t)){const o=e.end(e.length-1);return this.logger_(`Fell out of live window at time ${t}. Seeking to live point (seekable end) ${o}`),this.resetTimeUpdate_(),this.tech_.setCurrentTime(o),this.tech_.trigger({type:"usage",name:"vhs-live-resync"}),!0}const i=this.tech_.vhs.playlistController_.sourceUpdater_,n=this.tech_.buffered();if(this.videoUnderflow_({audioBuffered:i.audioBuffered(),videoBuffered:i.videoBuffered(),currentTime:t}))return this.resetTimeUpdate_(),this.tech_.setCurrentTime(t),this.tech_.trigger({type:"usage",name:"vhs-video-underflow"}),!0;const s=$g(n,t);return s.length>0?(this.logger_(`Stopped at ${t} and seeking to ${s.start(0)}`),this.resetTimeUpdate_(),this.skipTheGap_(t),!0):!1}afterSeekableWindow_(e,t,i,n=!1){if(!e.length)return!1;let a=e.end(e.length-1)+Ga;const s=!i.endList,o=typeof i.partTargetDuration=="number";return s&&(o||n)&&(a=e.end(e.length-1)+i.targetDuration*3),t>a}beforeSeekableWindow_(e,t){return!!(e.length&&e.start(0)>0&&t2)return{start:a,end:s}}return null}}const yne={errorInterval:30,getSource(r){const t=this.tech({IWillNotUseThisInPlugins:!0}).currentSource_||this.currentSource();return r(t)}},K9=function(r,e){let t=0,i=0;const n=It(yne,e);r.ready(()=>{r.trigger({type:"usage",name:"vhs-error-reload-initialized"})});const a=function(){i&&r.currentTime(i)},s=function(c){c!=null&&(i=r.duration()!==1/0&&r.currentTime()||0,r.one("loadedmetadata",a),r.src(c),r.trigger({type:"usage",name:"vhs-error-reload"}),r.play())},o=function(){if(Date.now()-t{Object.defineProperty(Jt,r,{get(){return K.log.warn(`using Vhs.${r} is UNSAFE be sure you know what you are doing`),Fr[r]},set(e){if(K.log.warn(`using Vhs.${r} is UNSAFE be sure you know what you are doing`),typeof e!="number"||e<0){K.log.warn(`value of Vhs.${r} must be greater than or equal to 0`);return}Fr[r]=e}})});const Q9="videojs-vhs",J9=function(r,e){const t=e.media();let i=-1;for(let n=0;n{r.addQualityLevel(t)}),J9(r,e.playlists)};Jt.canPlaySource=function(){return K.log.warn("VHS is no longer a tech. Please remove it from your player's techOrder.")};const Cne=(r,e,t)=>{if(!r)return r;let i={};e&&e.attributes&&e.attributes.CODECS&&(i=sy(ka(e.attributes.CODECS))),t&&t.attributes&&t.attributes.CODECS&&(i.audio=t.attributes.CODECS);const n=Uh(i.video),a=Uh(i.audio),s={};for(const o in r)s[o]={},a&&(s[o].audioContentType=a),n&&(s[o].videoContentType=n),e.contentProtection&&e.contentProtection[o]&&e.contentProtection[o].pssh&&(s[o].pssh=e.contentProtection[o].pssh),typeof r[o]=="string"&&(s[o].url=r[o]);return It(r,s)},Ane=(r,e)=>r.reduce((t,i)=>{if(!i.contentProtection)return t;const n=e.reduce((a,s)=>{const o=i.contentProtection[s];return o&&o.pssh&&(a[s]={pssh:o.pssh}),a},{});return Object.keys(n).length&&t.push(n),t},[]),Dne=({player:r,sourceKeySystems:e,audioMedia:t,mainPlaylists:i})=>{if(!r.eme.initializeMediaKeys)return Promise.resolve();const n=t?i.concat([t]):i,a=Ane(n,Object.keys(e)),s=[],o=[];return a.forEach(l=>{o.push(new Promise((u,c)=>{r.tech_.one("keysessioncreated",u)})),s.push(new Promise((u,c)=>{r.eme.initializeMediaKeys({keySystems:l},h=>{if(h){c(h);return}u()})}))}),Promise.race([Promise.all(s),Promise.race(o)])},Ene=({player:r,sourceKeySystems:e,media:t,audioMedia:i})=>{const n=Cne(e,t,i);return n?(r.currentSource().keySystems=n,n&&!r.eme?(K.log.warn("DRM encrypted source cannot be decrypted without a DRM plugin"),!1):!0):!1},eN=()=>{if(!H.localStorage)return null;const r=H.localStorage.getItem(Q9);if(!r)return null;try{return JSON.parse(r)}catch{return null}},Ine=r=>{if(!H.localStorage)return!1;let e=eN();e=e?It(e,r):r;try{H.localStorage.setItem(Q9,JSON.stringify(e))}catch{return!1}return e},Pne=r=>r.toLowerCase().indexOf("data:application/vnd.videojs.vhs+json,")===0?JSON.parse(r.substring(r.indexOf(",")+1)):r,tN=(r,e)=>{r._requestCallbackSet||(r._requestCallbackSet=new Set),r._requestCallbackSet.add(e)},rN=(r,e)=>{r._responseCallbackSet||(r._responseCallbackSet=new Set),r._responseCallbackSet.add(e)},iN=(r,e)=>{r._requestCallbackSet&&(r._requestCallbackSet.delete(e),r._requestCallbackSet.size||delete r._requestCallbackSet)},nN=(r,e)=>{r._responseCallbackSet&&(r._responseCallbackSet.delete(e),r._responseCallbackSet.size||delete r._responseCallbackSet)};Jt.supportsNativeHls=function(){if(!de||!de.createElement)return!1;const r=de.createElement("video");return K.getTech("Html5").isSupported()?["application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","application/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"].some(function(t){return/maybe|probably/i.test(r.canPlayType(t))}):!1}();Jt.supportsNativeDash=function(){return!de||!de.createElement||!K.getTech("Html5").isSupported()?!1:/maybe|probably/i.test(de.createElement("video").canPlayType("application/dash+xml"))}();Jt.supportsTypeNatively=r=>r==="hls"?Jt.supportsNativeHls:r==="dash"?Jt.supportsNativeDash:!1;Jt.isSupported=function(){return K.log.warn("VHS is no longer a tech. Please remove it from your player's techOrder.")};Jt.xhr.onRequest=function(r){tN(Jt.xhr,r)};Jt.xhr.onResponse=function(r){rN(Jt.xhr,r)};Jt.xhr.offRequest=function(r){iN(Jt.xhr,r)};Jt.xhr.offResponse=function(r){nN(Jt.xhr,r)};const Mne=K.getComponent("Component");class aN extends Mne{constructor(e,t,i){if(super(t,i.vhs),typeof i.initialBandwidth=="number"&&(this.options_.bandwidth=i.initialBandwidth),this.logger_=Kn("VhsHandler"),t.options_&&t.options_.playerId){const n=K.getPlayer(t.options_.playerId);this.player_=n}if(this.tech_=t,this.source_=e,this.stats={},this.ignoreNextSeekingEvent_=!1,this.setOptions_(),this.options_.overrideNative&&t.overrideNativeAudioTracks&&t.overrideNativeVideoTracks)t.overrideNativeAudioTracks(!0),t.overrideNativeVideoTracks(!0);else if(this.options_.overrideNative&&(t.featuresNativeVideoTracks||t.featuresNativeAudioTracks))throw new Error("Overriding native VHS requires emulated tracks. See https://git.io/vMpjB");this.on(de,["fullscreenchange","webkitfullscreenchange","mozfullscreenchange","MSFullscreenChange"],n=>{const a=de.fullscreenElement||de.webkitFullscreenElement||de.mozFullScreenElement||de.msFullscreenElement;a&&a.contains(this.tech_.el())?this.playlistController_.fastQualityChange_():this.playlistController_.checkABR_()}),this.on(this.tech_,"seeking",function(){if(this.ignoreNextSeekingEvent_){this.ignoreNextSeekingEvent_=!1;return}this.setCurrentTime(this.tech_.currentTime())}),this.on(this.tech_,"error",function(){this.tech_.error()&&this.playlistController_&&this.playlistController_.pauseLoading()}),this.on(this.tech_,"play",this.play)}setOptions_(e={}){if(this.options_=It(this.options_,e),this.options_.withCredentials=this.options_.withCredentials||!1,this.options_.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions!==!1,this.options_.useDevicePixelRatio=this.options_.useDevicePixelRatio||!1,this.options_.useBandwidthFromLocalStorage=typeof this.source_.useBandwidthFromLocalStorage<"u"?this.source_.useBandwidthFromLocalStorage:this.options_.useBandwidthFromLocalStorage||!1,this.options_.useForcedSubtitles=this.options_.useForcedSubtitles||!1,this.options_.useNetworkInformationApi=this.options_.useNetworkInformationApi||!1,this.options_.useDtsForTimestampOffset=this.options_.useDtsForTimestampOffset||!1,this.options_.customTagParsers=this.options_.customTagParsers||[],this.options_.customTagMappers=this.options_.customTagMappers||[],this.options_.cacheEncryptionKeys=this.options_.cacheEncryptionKeys||!1,this.options_.llhls=this.options_.llhls!==!1,this.options_.bufferBasedABR=this.options_.bufferBasedABR||!1,typeof this.options_.playlistExclusionDuration!="number"&&(this.options_.playlistExclusionDuration=60),typeof this.options_.bandwidth!="number"&&this.options_.useBandwidthFromLocalStorage){const i=eN();i&&i.bandwidth&&(this.options_.bandwidth=i.bandwidth,this.tech_.trigger({type:"usage",name:"vhs-bandwidth-from-local-storage"})),i&&i.throughput&&(this.options_.throughput=i.throughput,this.tech_.trigger({type:"usage",name:"vhs-throughput-from-local-storage"}))}typeof this.options_.bandwidth!="number"&&(this.options_.bandwidth=Fr.INITIAL_BANDWIDTH),this.options_.enableLowInitialPlaylist=this.options_.enableLowInitialPlaylist&&this.options_.bandwidth===Fr.INITIAL_BANDWIDTH,["withCredentials","useDevicePixelRatio","customPixelRatio","limitRenditionByPlayerDimensions","bandwidth","customTagParsers","customTagMappers","cacheEncryptionKeys","playlistSelector","initialPlaylistSelector","bufferBasedABR","liveRangeSafeTimeDelta","llhls","useForcedSubtitles","useNetworkInformationApi","useDtsForTimestampOffset","exactManifestTimings","leastPixelDiffSelector"].forEach(i=>{typeof this.source_[i]<"u"&&(this.options_[i]=this.source_[i])}),this.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions,this.useDevicePixelRatio=this.options_.useDevicePixelRatio;const t=this.options_.customPixelRatio;typeof t=="number"&&t>=0&&(this.customPixelRatio=t)}setOptions(e={}){this.setOptions_(e)}src(e,t){if(!e)return;this.setOptions_(),this.options_.src=Pne(this.source_.src),this.options_.tech=this.tech_,this.options_.externVhs=Jt,this.options_.sourceType=Z6(t),this.options_.seekTo=a=>{this.tech_.setCurrentTime(a)},this.options_.player_=this.player_,this.playlistController_=new dne(this.options_);const i=It({liveRangeSafeTimeDelta:Ga},this.options_,{seekable:()=>this.seekable(),media:()=>this.playlistController_.media(),playlistController:this.playlistController_});this.playbackWatcher_=new mne(i),this.attachStreamingEventListeners_(),this.playlistController_.on("error",()=>{const a=K.players[this.tech_.options_.playerId];let s=this.playlistController_.error;typeof s=="object"&&!s.code?s.code=3:typeof s=="string"&&(s={message:s,code:3}),a.error(s)});const n=this.options_.bufferBasedABR?Jt.movingAverageBandwidthSelector(.55):Jt.STANDARD_PLAYLIST_SELECTOR;this.playlistController_.selectPlaylist=this.selectPlaylist?this.selectPlaylist.bind(this):n.bind(this),this.playlistController_.selectInitialPlaylist=Jt.INITIAL_PLAYLIST_SELECTOR.bind(this),this.playlists=this.playlistController_.mainPlaylistLoader_,this.mediaSource=this.playlistController_.mediaSource,Object.defineProperties(this,{selectPlaylist:{get(){return this.playlistController_.selectPlaylist},set(a){this.playlistController_.selectPlaylist=a.bind(this)}},throughput:{get(){return this.playlistController_.mainSegmentLoader_.throughput.rate},set(a){this.playlistController_.mainSegmentLoader_.throughput.rate=a,this.playlistController_.mainSegmentLoader_.throughput.count=1}},bandwidth:{get(){let a=this.playlistController_.mainSegmentLoader_.bandwidth;const s=H.navigator.connection||H.navigator.mozConnection||H.navigator.webkitConnection,o=1e7;if(this.options_.useNetworkInformationApi&&s){const l=s.downlink*1e3*1e3;l>=o&&a>=o?a=Math.max(a,l):a=l}return a},set(a){this.playlistController_.mainSegmentLoader_.bandwidth=a,this.playlistController_.mainSegmentLoader_.throughput={rate:0,count:0}}},systemBandwidth:{get(){const a=1/(this.bandwidth||1);let s;return this.throughput>0?s=1/this.throughput:s=0,Math.floor(1/(a+s))},set(){K.log.error('The "systemBandwidth" property is read-only')}}}),this.options_.bandwidth&&(this.bandwidth=this.options_.bandwidth),this.options_.throughput&&(this.throughput=this.options_.throughput),Object.defineProperties(this.stats,{bandwidth:{get:()=>this.bandwidth||0,enumerable:!0},mediaRequests:{get:()=>this.playlistController_.mediaRequests_()||0,enumerable:!0},mediaRequestsAborted:{get:()=>this.playlistController_.mediaRequestsAborted_()||0,enumerable:!0},mediaRequestsTimedout:{get:()=>this.playlistController_.mediaRequestsTimedout_()||0,enumerable:!0},mediaRequestsErrored:{get:()=>this.playlistController_.mediaRequestsErrored_()||0,enumerable:!0},mediaTransferDuration:{get:()=>this.playlistController_.mediaTransferDuration_()||0,enumerable:!0},mediaBytesTransferred:{get:()=>this.playlistController_.mediaBytesTransferred_()||0,enumerable:!0},mediaSecondsLoaded:{get:()=>this.playlistController_.mediaSecondsLoaded_()||0,enumerable:!0},mediaAppends:{get:()=>this.playlistController_.mediaAppends_()||0,enumerable:!0},mainAppendsToLoadedData:{get:()=>this.playlistController_.mainAppendsToLoadedData_()||0,enumerable:!0},audioAppendsToLoadedData:{get:()=>this.playlistController_.audioAppendsToLoadedData_()||0,enumerable:!0},appendsToLoadedData:{get:()=>this.playlistController_.appendsToLoadedData_()||0,enumerable:!0},timeToLoadedData:{get:()=>this.playlistController_.timeToLoadedData_()||0,enumerable:!0},buffered:{get:()=>pu(this.tech_.buffered()),enumerable:!0},currentTime:{get:()=>this.tech_.currentTime(),enumerable:!0},currentSource:{get:()=>this.tech_.currentSource_,enumerable:!0},currentTech:{get:()=>this.tech_.name_,enumerable:!0},duration:{get:()=>this.tech_.duration(),enumerable:!0},main:{get:()=>this.playlists.main,enumerable:!0},playerDimensions:{get:()=>this.tech_.currentDimensions(),enumerable:!0},seekable:{get:()=>pu(this.tech_.seekable()),enumerable:!0},timestamp:{get:()=>Date.now(),enumerable:!0},videoPlaybackQuality:{get:()=>this.tech_.getVideoPlaybackQuality(),enumerable:!0}}),this.tech_.one("canplay",this.playlistController_.setupFirstPlay.bind(this.playlistController_)),this.tech_.on("bandwidthupdate",()=>{this.options_.useBandwidthFromLocalStorage&&Ine({bandwidth:this.bandwidth,throughput:Math.round(this.throughput)})}),this.playlistController_.on("selectedinitialmedia",()=>{gne(this)}),this.playlistController_.sourceUpdater_.on("createdsourcebuffers",()=>{this.setupEme_()}),this.on(this.playlistController_,"progress",function(){this.tech_.trigger("progress")}),this.on(this.playlistController_,"firstplay",function(){this.ignoreNextSeekingEvent_=!0}),this.setupQualityLevels_(),this.tech_.el()&&(this.mediaSourceUrl_=H.URL.createObjectURL(this.playlistController_.mediaSource),this.tech_.src(this.mediaSourceUrl_))}createKeySessions_(){const e=this.playlistController_.mediaTypes_.AUDIO.activePlaylistLoader;this.logger_("waiting for EME key session creation"),Dne({player:this.player_,sourceKeySystems:this.source_.keySystems,audioMedia:e&&e.media(),mainPlaylists:this.playlists.main.playlists}).then(()=>{this.logger_("created EME key session"),this.playlistController_.sourceUpdater_.initializedEme()}).catch(t=>{this.logger_("error while creating EME key session",t),this.player_.error({message:"Failed to initialize media keys for EME",code:3})})}handleWaitingForKey_(){this.logger_("waitingforkey fired, attempting to create any new key sessions"),this.createKeySessions_()}setupEme_(){const e=this.playlistController_.mediaTypes_.AUDIO.activePlaylistLoader,t=Ene({player:this.player_,sourceKeySystems:this.source_.keySystems,media:this.playlists.media(),audioMedia:e&&e.media()});if(this.player_.tech_.on("keystatuschange",i=>{this.playlistController_.updatePlaylistByKeyStatus(i.keyId,i.status)}),this.handleWaitingForKey_=this.handleWaitingForKey_.bind(this),this.player_.tech_.on("waitingforkey",this.handleWaitingForKey_),!t){this.playlistController_.sourceUpdater_.initializedEme();return}this.createKeySessions_()}setupQualityLevels_(){const e=K.players[this.tech_.options_.playerId];!e||!e.qualityLevels||this.qualityLevels_||(this.qualityLevels_=e.qualityLevels(),this.playlistController_.on("selectedinitialmedia",()=>{wne(this.qualityLevels_,this)}),this.playlists.on("mediachange",()=>{J9(this.qualityLevels_,this.playlists)}))}static version(){return{"@videojs/http-streaming":Z9,"mux.js":bne,"mpd-parser":Sne,"m3u8-parser":Tne,"aes-decrypter":xne}}version(){return this.constructor.version()}canChangeType(){return q9.canChangeType()}play(){this.playlistController_.play()}setCurrentTime(e){this.playlistController_.setCurrentTime(e)}duration(){return this.playlistController_.duration()}seekable(){return this.playlistController_.seekable()}dispose(){this.playbackWatcher_&&this.playbackWatcher_.dispose(),this.playlistController_&&this.playlistController_.dispose(),this.qualityLevels_&&this.qualityLevels_.dispose(),this.tech_&&this.tech_.vhs&&delete this.tech_.vhs,this.mediaSourceUrl_&&H.URL.revokeObjectURL&&(H.URL.revokeObjectURL(this.mediaSourceUrl_),this.mediaSourceUrl_=null),this.tech_&&this.tech_.off("waitingforkey",this.handleWaitingForKey_),super.dispose()}convertToProgramTime(e,t){return Rre({playlist:this.playlistController_.media(),time:e,callback:t})}seekToProgramTime(e,t,i=!0,n=2){return I9({programTime:e,playlist:this.playlistController_.media(),retryCount:n,pauseAfterSeek:i,seekTo:this.options_.seekTo,tech:this.options_.tech,callback:t})}setupXhrHooks_(){this.xhr.onRequest=e=>{tN(this.xhr,e)},this.xhr.onResponse=e=>{rN(this.xhr,e)},this.xhr.offRequest=e=>{iN(this.xhr,e)},this.xhr.offResponse=e=>{nN(this.xhr,e)},this.player_.trigger("xhr-hooks-ready")}attachStreamingEventListeners_(){const e=["seekablerangeschanged","bufferedrangeschanged","contentsteeringloadstart","contentsteeringloadcomplete","contentsteeringparsed"],t=["gapjumped","playedrangeschanged"];e.forEach(i=>{this.playlistController_.on(i,n=>{this.player_.trigger(ar({},n))})}),t.forEach(i=>{this.playbackWatcher_.on(i,n=>{this.player_.trigger(ar({},n))})})}}const uy={name:"videojs-http-streaming",VERSION:Z9,canHandleSource(r,e={}){const t=It(K.options,e);return!t.vhs.experimentalUseMMS&&!pp("avc1.4d400d,mp4a.40.2",!1)?!1:uy.canPlayType(r.type,t)},handleSource(r,e,t={}){const i=It(K.options,t);return e.vhs=new aN(r,e,i),e.vhs.xhr=w9(),e.vhs.setupXhrHooks_(),e.vhs.src(r.src,r.type),e.vhs},canPlayType(r,e){const t=Z6(r);if(!t)return"";const i=uy.getOverrideNative(e);return!Jt.supportsTypeNatively(t)||i?"maybe":""},getOverrideNative(r={}){const{vhs:e={}}=r,t=!(K.browser.IS_ANY_SAFARI||K.browser.IS_IOS),{overrideNative:i=t}=e;return i}},Lne=()=>pp("avc1.4d400d,mp4a.40.2",!0);Lne()&&K.getTech("Html5").registerSourceHandler(uy,0);K.VhsHandler=aN;K.VhsSourceHandler=uy;K.Vhs=Jt;K.use||K.registerComponent("Vhs",Jt);K.options.vhs=K.options.vhs||{};(!K.getPlugin||!K.getPlugin("reloadSourceOnError"))&&K.registerPlugin("reloadSourceOnError",_ne);/*! @name videojs-contrib-eme @version 3.11.2 @license Apache-2.0 */function cy(){return cy=Object.assign||function(r){for(var e=1;e=400&&n.statusCode<=599){var s=a;t&&(s=String.fromCharCode.apply(null,new Uint8Array(a))),e({cause:s});return}e(null,a)}});var Bne=function(e){var t=String.fromCharCode.apply(null,new Uint16Array(e)),i=new H.DOMParser().parseFromString(t,"application/xml"),n=i.getElementsByTagName("HttpHeaders")[0],a={};if(n)for(var s=n.getElementsByTagName("name"),o=n.getElementsByTagName("value"),l=0;l"u"){i.mediaKeysObject=null,i.pendingSessionData=[];var h,d;c=new Promise(function(f,p){if(i.keySystem=s.keySystem,d=E4(s.keySystem,o.keySystems[s.keySystem]),!d.getCertificate){f(s);return}d.getCertificate(o,function(v,g){if(v){p(v);return}h=g,f()})}).then(function(){return s.createMediaKeys()}).then(function(f){return zne({player:t,video:i,certificate:h,createdMediaKeys:f})}).catch(function(f){return f?Promise.reject(f):Promise.reject("Failed to create and initialize a MediaKeys object")})}return c.then(function(){var f=E4(i.keySystem,o.keySystems[i.keySystem]),p=f.getLicense;return Vne({player:t,video:i,initDataType:n,initData:a,options:o,getLicense:i.keySystem?$ne(p,u):null,removeSession:l,eventBus:u})})},_A="com.apple.fps.1_0",qne=function(e){var t=e.initData,i=e.id,n=e.cert;typeof i=="string"&&(i=kne(i));var a=0,s=new ArrayBuffer(t.byteLength+4+i.byteLength+4+n.byteLength),o=new DataView(s),l=new Uint8Array(s,a,t.byteLength);l.set(t),a+=t.byteLength,o.setUint32(a,i.byteLength,!0),a+=4;var u=new Uint16Array(s,a,i.length);u.set(i),a+=u.byteLength,o.setUint32(a,n.byteLength,!0),a+=4;var c=new Uint8Array(s,a,n.byteLength);return c.set(n),new Uint8Array(s,0,s.byteLength)},jne=function(e){var t=e.video,i=e.contentId,n=e.initData,a=e.cert,s=e.options,o=e.getLicense,l=e.eventBus;return new Promise(function(u,c){if(!t.webkitKeys)try{t.webkitSetMediaKeys(new H.WebKitMediaKeys(_A))}catch{c("Could not create MediaKeys");return}var h;try{h=t.webkitKeys.createSession("video/mp4",qne({id:i,initData:n,cert:a}))}catch{c("Could not create key session");return}l.trigger("keysessioncreated"),h.contentId=i,h.addEventListener("webkitkeymessage",function(d){o(s,i,d.message,function(f,p){if(l&&l.trigger("licenserequestattempted"),f){c(f);return}h.update(new Uint8Array(p))})}),h.addEventListener("webkitkeyadded",function(){u()}),h.addEventListener("webkitkeyerror",function(){var d=h.error;c("KeySession error: code "+d.code+", systemCode "+d.systemCode)})})},Xne=function(e){return function(t,i){var n=W_(t.emeHeaders,e.certificateHeaders);K.xhr({uri:e.certificateUri,responseType:"arraybuffer",headers:n},Qh(function(a,s){if(a){i(a);return}i(null,new Uint8Array(s))}))}},Yne=function(e,t){return One(Rne(t))},Kne=function(e){return function(t,i,n,a){var s=W_({"Content-type":"application/octet-stream"},t.emeHeaders,e.licenseHeaders);K.xhr({uri:e.licenseUri,method:"POST",responseType:"arraybuffer",body:n,headers:s},Qh(a,!0))}},Zne=function(e){var t=e.video,i=e.initData,n=e.options,a=e.eventBus,s=n.keySystems[_A],o=s.getCertificate||Xne(s),l=s.getContentId||Yne,u=s.getLicense||Kne(s);return new Promise(function(c,h){o(n,function(d,f){if(d){h(d);return}c(f)})}).then(function(c){return jne({video:t,cert:c,initData:i,getLicense:u,options:n,contentId:l(n,i),eventBus:a})})},dh="com.microsoft.playready",Qne=function(e,t,i,n){var a=e.keySystems[dh];if(typeof a.getKey=="function"){a.getKey(e,i.destinationURL,i.message.buffer,function(o,l){if(o){n.trigger({message:"Unable to get key: "+o,target:t,type:"mskeyerror"});return}t.update(l)});return}typeof a=="string"?a={url:a}:typeof a=="boolean"&&(a={}),a.url||(a.url=i.destinationURL);var s=function(l,u){if(n&&n.trigger("licenserequestattempted"),l){n.trigger({message:"Unable to request key from url: "+a.url,target:t,type:"mskeyerror"});return}t.update(new Uint8Array(u))};a.getLicense?a.getLicense(e,i.message.buffer,s):sN(a,i.message.buffer,e,s)},Jne=function(e,t,i,n){var a=e.msKeys.createSession("video/mp4",t);if(!a)throw new Error("Could not create key session.");n.trigger("keysessioncreated"),a.addEventListener("mskeymessage",function(s){Qne(i,a,s,n)}),a.addEventListener("mskeyerror",function(s){n.trigger({message:"Unexpected key error from key session with "+("code: "+a.error.code+" and systemCode: "+a.error.systemCode),target:a,type:"mskeyerror"})}),a.addEventListener("mskeyadded",function(){n.trigger({target:a,type:"mskeyadded"})})},eae=function(r){var e=r.video,t=r.initData,i=r.options,n=r.eventBus;e.msKeys&&delete e.msKeys;try{e.msSetMediaKeys(new H.MSMediaKeys(dh))}catch(a){throw new Error("Unable to create media keys for PlayReady key system. Error: "+a.message)}Jne(e,t,i,n)},tae="3.11.2",rae=function(e,t){for(var i=0;i=0)&&(t[n]=r[n]);return t}function M4(r,e){if(r==null)return{};var t=cae(r,e),i,n;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(r);for(n=0;n=0)&&Object.prototype.propertyIsEnumerable.call(r,i)&&(t[i]=r[i])}return t}var hae="1.12.1";const fae=K.getComponent("player");class dae extends fae{constructor(e,t,i){t=K.obj.merge(t,{plugins:{eme:!0}}),super(e,t,i)}audioTrack(e){const t=Array.from(this.player().audioTracks());if(!e)return t.find(s=>s.enabled);const{kind:i,language:n}=e,a=t.find(s=>s.language===n&&s.kind===i)||t.find(s=>s.language===n);return a&&(a.enabled=!0),a}bufferedRanges(){const e=[];for(let t=0;t!["chapters","metadata"].includes(s.kind));if(!e)return t.find(s=>s.mode==="showing");t.forEach(s=>s.mode="disabled");const{kind:i,language:n}=e;return t.find(s=>(s.language===n&&s.kind===i&&(s.mode="showing"),s.mode==="showing"))||t.find(s=>(s.language===n&&(s.mode="showing"),s.mode==="showing"))}}K.registerComponent("player",dae);const sr=K;sr.VERSION={pillarbox:hae,videojs:K.VERSION,[K.VhsSourceHandler.name]:K.VhsSourceHandler.VERSION,eme:K.getPlugin("eme").VERSION};sr.options.enableSmoothSeeking=!0;sr.options.fill=!0;sr.options.html5={vhs:{useForcedSubtitles:!0}};sr.options.liveTracker={trackingThreshold:120,liveTolerance:15};sr.options.liveui=!0;sr.options.playsinline=!0;sr.options.responsive=!0;sr.options.trackers={};class L4{constructor(e="il.srgssr.ch"){this.setIlHost(e)}setIlHost(e){this.baseUrl=`${e}/integrationlayer/2.1/`}handleRequest(e){var t=this;return function(){var i=ih(function*(n){const a=typeof e=="function"?e(n):t.mediaCompositionUrlHandler(n),s=yield fetch(a);if(!s.ok)throw s;return yield s.json()});return function(n){return i.apply(this,arguments)}}()}mediaCompositionUrlHandler(e){return`https://${this.baseUrl}mediaComposition/byUrn/${e}?onlyChapters=true&vector=portalplay`}}const Mc={WIDTH_240:"240",WIDTH_320:"320",WIDTH_480:"480",WIDTH_960:"960",WIDTH_1920:"1920"},Xg={JPG:"jpg",WEBP:"webp",PNG:"png"},pae="https://il.srgssr.ch/images/";let vae=class{static scale({url:e,width:t=Mc.WIDTH_960,format:i=Xg.JPG}={},n=pae){if(!e)return;const a=new URL(n);return a.searchParams.set("imageUrl",e),a.searchParams.set("format",i),a.searchParams.set("width",t),decodeURIComponent(a.href)}static get JPG(){return Xg.JPG}static get PNG(){return Xg.PNG}static get WEBP(){return Xg.WEBP}static get WIDTH_240(){return Mc.WIDTH_240}static get WIDTH_320(){return Mc.WIDTH_320}static get WIDTH_480(){return Mc.WIDTH_480}static get WIDTH_960(){return Mc.WIDTH_960}static get WIDTH_1920(){return Mc.WIDTH_1920}};const gae={WIDEVINE:"com.widevine.alpha",FAIRPLAY:"com.apple.fps.1_0",PLAYREADY:"com.microsoft.playready"};class Zp{static buildKeySystems(e=[]){const t={};return e.forEach(i=>{const n=Zp.vendors[i.type];if(Zp.vendors.FAIRPLAY===n){const{certificateUrl:a,licenseUrl:s}=i;t[n]={certificateUri:a,licenseUri:s}}else t[n]=i.licenseUrl}),{keySystems:t}}static hasDrm(e){return e.some(({drmList:t})=>t&&t.length>0)}static get vendors(){return gae}}const Yg={AKAMAI:"AKAMAI",NONE:"NONE"};class Pu{static aclPath(e){const t=e.pathname;return`${t.substring(0,t.lastIndexOf("/")+1)}*`}static get AKAMAI(){return Yg.AKAMAI}static hasToken(e){return e.some(t=>Pu.isAkamai(t.tokenType))}static isAkamai(e){return Yg.AKAMAI===e}static isNone(e){return Yg.NONE===e}static get NONE(){return Yg.NONE}static tokenize(e,t){const i=new URL(`${e.url}`),n=Pu.aclPath(i),a=`${t}${encodeURIComponent(n)}`;return fetch(a).then(s=>s.ok?s.json():Promise.reject({status:s.status,statusText:s.statusText})).then(({token:{authparams:s}})=>(new URLSearchParams(s).forEach((l,u)=>i.searchParams.set(u,l)),Object.assign({},e,{url:i.toString()}))).catch(s=>Promise.reject(s))}static tokenizeSources(e,t="https://tp.srgssr.ch/akahd/token?acl="){const i=[];return e.forEach(n=>{const a=Pu.tokenize(n,t);i.push(a)}),Promise.all(i).then(n=>n).catch(n=>Promise.reject(n))}}const k4="emptied",R4="ended",O4="loadeddata",N4="loadstart",D2="pause",mae="play",E2="playing",B4="ratechange",F4="seeking",I2="timeupdate",U4="waiting";class su{constructor(e,{debug:t=!1,environment:i="prod",playerVersion:n="none",tagCommanderScriptURL:a="//colibri-js.akamaized.net/penguin/tc_SRGGD_11.js"}={}){this.isDebugEnabled=t,this.elapsedPlaybackTime=0,this.environment=i,this.hasStarted=!1,this.heartBeatIntervalId=void 0,this.initialized=!1,this.isSeeking=!1,this.isWaiting=!1,this.mediaSession=0,this.pendingQueue=[],this.pendingTagCommanderReload=!1,this.player=e,this.playerVersion=n,this.srcMediaData=void 0,this.startPlaybackSession=0,this.tagCommanderScriptURL=a,this.trackedCurrentTime=0,this.uptimeIntervalId=void 0,this.initScript(),this.initListeners()}beforeunload(){this.notify("stop")}clearTimers(){clearInterval(this.heartBeatIntervalId),clearInterval(this.uptimeIntervalId),clearTimeout(this.uptimeTimeoutId)}currentTime(){return Math.round(this.trackedCurrentTime)}debug(e){if(e===void 0)return this.isDebugEnabled||this.player.debug();this.isDebugEnabled=!!e}destroy(){this.clearTimers(),window.tc_vars||(window.tc_vars={}),this.elapsedPlaybackTime=0,this.hasStarted=!1,this.heartBeatIntervalId=void 0,this.initialized=!1,this.isWaiting=!1,this.mediaSession=0,this.pendingQueue=[],this.srcMediaData=void 0,this.startPlaybackSession=0,this.trackedCurrentTime=0,this.uptimeIntervalId=void 0}dispose(){this.beforeunload(),this.clearTimers(),window.removeEventListener("beforeunload",this.beforeunloadListener),this.player.off(k4,this.emptiedListener),this.player.off(R4,this.endedListener),this.player.off(N4,this.loadstartListener),this.player.off(O4,this.loadeddataListener),this.player.off(E2,this.playListener),this.player.off(D2,this.pauseListener),this.player.off(B4,this.rateChangeListener),this.player.off(F4,this.seekingListener),this.player.off(I2,this.timeUpdateListener),this.player.off(U4,this.waitingListener)}emptied(){this.player.ended()||this.notify("stop")}ended(){this.notify("eof"),this.mediaSession=0,this.clearTimers()}flush(){this.isTrackerDisabled()||(this.pendingTagCommanderReload&&window.tC&&(window.tC.container.reload(),this.pendingTagCommanderReload=!1),window.tc_events_11&&this.pendingQueue.length>0&&(this.pendingQueue.forEach(e=>{window.tc_events_11(this.player.el(),e.action,e.labels)}),this.pendingQueue=[]))}getCurrentAudioTrack(){const e=Array.from(this.player.audioTracks()).find(i=>i.enabled);let t="und";return e&&e.language&&(t=e.language),e?t.toUpperCase():""}getCurrentTextTrack(){const e=this.player.textTrack();let t="und";return e&&e.language&&(t=e.language),e?t.toUpperCase():""}getDvrWindowPosition(){const{liveTracker:e}=this.player,t=this.currentTime()-e.seekableStart()|0,i=e.liveWindow()-t;return i<0||i===1/0?0:i*1e3}getDvrWindowSize(){const e=this.player.liveTracker.liveWindow()===1/0,t=this.player.liveTracker.liveWindow()*1e3;return e?0:t}getElapsedPlaybackTime(){return this.startPlaybackSession?this.getElapsedPlayingTime():this.elapsedPlaybackTime}getElapsedPlayingTime(){const e=su.now()-this.startPlaybackSession|0;return this.elapsedPlaybackTime+e}getEventLabels(e){const t={event_id:e,event_timestamp:su.now(),media_dvr_window_length:0,media_dvr_window_offset:0,media_is_dvr:!1,media_is_live:!1,media_mute:this.player.muted()?"1":"0",media_playback_rate:this.player.playbackRate(),media_position:this.currentTime(),media_quality:this.srcMediaData.mediaData.quality,media_subtitles_on:this.isTextTrackEnabled(),media_volume:(this.player.volume()*100).toFixed(0),navigation_environment:this.environment};return this.isAudioTrackEnabled()&&(t.media_audio_track=this.getCurrentAudioTrack()),this.isTextTrackEnabled()&&(t.media_subtitle_selection=this.getCurrentTextTrack()),this.isMediaOnDemand()||(t.media_is_live=!0,t.media_position=this.getElapsedPlaybackTime()),this.isMediaDvr()&&(t.media_dvr_window_offset=this.getDvrWindowPosition()|0,t.media_dvr_window_length=this.getDvrWindowSize()|0,t.media_is_dvr=!0,t.media_timeshift=[mae,D2].includes(e)?this.timeShifted():0),t}getInternalLabels(){const e={media_bu_distributer:this.srcMediaData.mediaData.vendor,media_chromecast_selected:!!this.player.tech(!0).isCasting,media_embedding_url:document.referrer,media_player_display:"default",media_player_name:"pillarbox-web",media_player_version:this.playerVersion,media_url:this.srcMediaData.src},t=this.srcMediaData.mediaData.analyticsMetadata||{};window.tc_vars=Object.assign({},window.tc_vars,e,t)}heartBeat(){this.heartBeatIntervalId=setInterval(()=>{this.player.paused()||this.notify("pos")},3e4)}initCallbacks(){this.beforeunloadListener=this.beforeunload.bind(this),this.emptiedListener=this.emptied.bind(this),this.endedListener=this.ended.bind(this),this.loadstartListener=this.loadstart.bind(this),this.loadeddataListener=this.loadeddata.bind(this),this.playListener=this.play.bind(this),this.pauseListener=this.pause.bind(this),this.rateChangeListener=this.rateChange.bind(this),this.seekingListener=this.seeking.bind(this),this.timeUpdateListener=this.timeUpdate.bind(this),this.waitingListener=this.waiting.bind(this)}initListeners(){this.initCallbacks(),window.addEventListener("beforeunload",this.beforeunloadListener),this.player.on(k4,this.emptiedListener),this.player.on(R4,this.endedListener),this.player.on(N4,this.loadstartListener),this.player.on(O4,this.loadeddataListener),this.player.on(E2,this.playListener),this.player.on(D2,this.pauseListener),this.player.on(B4,this.rateChangeListener),this.player.on(F4,this.seekingListener),this.player.on(I2,this.timeUpdateListener),this.player.on(U4,this.waitingListener),this.player.one("dispose",this.dispose.bind(this))}initScript(){const e="tc_script__11";if(!document.querySelector(`#${e}`)){const t=document.createElement("script"),i=this.tagCommanderScriptURL;t.defer=!0,t.id=e,t.src=i,t.type="text/javascript",t.onload=n=>{this.flush()},document.body.appendChild(t)}}isAudioTrackEnabled(){return!!this.getCurrentAudioTrack()}isMediaDvr(){const{trackingThreshold:e}=this.player.liveTracker.options();return!this.isMediaOnDemand()&&ethis.player.liveTracker.liveWindow()}isMediaOnDemand(){return Number.isFinite(this.player.duration())}isTextTrackEnabled(){return!!this.getCurrentTextTrack()}isTrackerDisabled(){return!this.srcMediaData||!this.srcMediaData.mediaData?!0:Array.isArray(this.srcMediaData.disableTrackers)?!!this.srcMediaData.disableTrackers.find(e=>e.toLowerCase()===su.name.toLowerCase()):!!this.srcMediaData.disableTrackers}loadstart(){this.destroy(),this.updateSrcMediaData(this.player.currentSource()),!this.isTrackerDisabled()&&(this.getInternalLabels(),this.reloadTagCommanderContainer(),this.notify("buffer_start"),this.hasStarted=!1)}loadeddata(){this.notify("init"),this.initialized=!0,this.notify("buffer_stop")}log(e,t,i="log"){this.debug()&&console[i](`SRGAnalytics:${e}`,t,window.tc_vars)}notify(e,t){if(this.isTrackerDisabled())return;try{this.flush()}catch(n){this.log(e,n,"error")}const i=Object.assign({},this.getEventLabels(e),t);this.log(e,i);try{window.tc_events_11?window.tc_events_11(this.player.el(),e,i):this.pendingQueue.push({action:e,labels:i})}catch(n){this.log(e,n,"error")}}static now(){return(Date.now()/1e3).toFixed(0)}play(){this.hasStarted||(this.hasStarted=!0),!this.startPlaybackSession&&!this.isMediaOnDemand()&&(this.startPlaybackSession=su.now()),this.mediaSession===0&&(this.mediaSession=su.now(),this.heartBeat(),this.uptime()),this.timeUpdate(),this.notify("play"),this.isSeeking&&(this.isSeeking=!1)}pause(){if(this.isMediaOnDemand()||(this.elapsedPlaybackTime=this.getElapsedPlayingTime(),this.startPlaybackSession=0),!this.player.seeking()&&!this.isMediaLive()&&this.player.currentTime(){!this.player.paused()&&!this.isMediaOnDemand()&&this.notify("uptime")};this.uptimeTimeoutId=setTimeout(()=>{e(),this.uptimeIntervalId=setInterval(()=>{e()},6e4)},3e4)}waiting(){if(!this.initialized||this.isWaiting)return;const e=()=>{this.isWaiting=!1,this.notify("buffer_stop")};this.isWaiting=!0,this.notify("buffer_start"),sr.browser.IS_ANY_SAFARI?this.player.one(I2,e):this.player.one(E2,e)}}class yae{findChapterByUrn(e){if(this.chapterList){const[t]=this.chapterList.filter(i=>i.urn===e);return t}}findMainSegment(){if(!this.segmentUrn)return;const e=this.getMainSegments(),[t]=e.filter(i=>i.urn===this.segmentUrn);return t}findResourceListByUrn(e){const t=this.findChapterByUrn(e);if(t)return t.resourceList||[]}getChapters(){const e="AUDIO";return this.getMainChapter().mediaType===e?[]:this.chapterList.filter(({mediaType:t})=>t!==e)}getFilteredExternalSubtitles(){const{subtitleList:e}=this.getMainChapter(),[{subtitleInformationList:t}={}]=this.getResourceList().filter(({subtitleInformationList:a})=>a),i=e&&!t;if(!e)return[];const n=e.filter(a=>a.format!=="TTML");return i?n:n.filter(a=>!t.find(o=>o.locale===a.locale&&a.type===o.type))}getMainBlockReason(){const e=this.getMainChapter();if(!e)return;let{blockReason:t}=e;return!t&&new Datee.blockReason)}getMainChapter(){return this.mainChapter||(this.mainChapter=this.findChapterByUrn(this.chapterUrn)),!this.mainChapter&&this.chapterList&&this.chapterList.length>0&&([this.mainChapter]=this.chapterList),this.mainChapter}getMainChapterImageUrl(){const e=this.getMainChapter();if(!(!e||!e.imageUrl))return e.imageUrl}getMainResources(){const e=this.getResourceList();if(!(!e||!e.length))return e.map(t=>({analyticsData:this.getMergedAnalyticsData(t.analyticsData),analyticsMetadata:this.getMergedAnalyticsMetadata(t.analyticsMetadata),blockReason:this.getMainChapter().blockReason,blockedSegments:this.getMainBlockedSegments(),imageUrl:this.getMainChapterImageUrl(),chapters:this.getChapters(),drmList:t.drmList,dvr:t.dvr,eventData:this.getMainChapter().eventData,id:this.getMainChapter().id,imageCopyright:this.getMainChapter().imageCopyright,intervals:this.getMainTimeIntervals(),live:t.live,mediaType:this.getMainChapter().mediaType,mimeType:t.mimeType,presentation:t.presentation,quality:t.quality,streaming:t.streaming,streamOffset:t.streamOffset,subtitles:this.getFilteredExternalSubtitles(),title:this.getMainChapter().title,tokenType:t.tokenType,url:t.url,urn:this.chapterUrn,vendor:this.getMainChapter().vendor}))}getMainSegments(){const e=this.getMainChapter();return!this.mainSegments&&e&&e.segmentList&&(this.mainSegments=e.segmentList),this.mainSegments||[]}getMainTimeIntervals(){const{timeIntervalList:e=[]}=this.getMainChapter()||{};return e}getMainValidFromDate(){const e=this.getMainChapter();if(!e)return new Date(0);const{validFrom:t}=e;if(t)return new Date(t)}getMergedAnalyticsData(e){return Yr(Yr(Yr({},this.analyticsData),this.getMainChapter().analyticsData),e)}getMergedAnalyticsMetadata(e){return Yr(Yr(Yr({},this.analyticsMetadata),this.getMainChapter().analyticsMetadata),e)}getResourceList(){const{resourceList:e}=this.getMainChapter();return e||[]}}var hN="Wiedergabe",fN="Pause",dN="Erneut abspielen",pN="Dauer",vN="LIVE",gN="Geladen",mN="Status",yN="Vollbild",_N="Stumm schalten",bN="Ton einschalten",SN="Untertitel",TN="Untertitel",xN="Kapitel",wN="Schließen",CN="Beschreibungen",AN="Schrift",DN="Weiß",EN="Schwarz",IN="Rot",PN="Grün",MN="Blau",LN="Gelb",kN="Magenta",RN="Türkis",ON="Hintergrund",NN="Fenster",BN="Durchsichtig",FN="Undurchsichtig",UN="Kein",VN="Erhoben",zN="Gedrückt",GN="Uniform",HN="Zwanglos",$N="Schreibschrift",WN="Zurücksetzen",qN="Fertig",jN="Farbe",XN="Deckkraft",_ae={Play:hN,Pause:fN,Replay:dN,"Current Time":"Aktueller Zeitpunkt",Duration:pN,"Remaining Time":"Verbleibende Zeit","Stream Type":"Streamtyp",LIVE:vN,Loaded:gN,Progress:mN,Fullscreen:yN,"Exit Fullscreen":"Vollbildmodus beenden",Mute:_N,Unmute:bN,"Playback Rate":"Wiedergabegeschwindigkeit",Subtitles:SN,"subtitles off":"Untertitel aus",Captions:TN,"captions off":"Untertitel aus",Chapters:xN,"You aborted the media playback":"Sie haben die Videowiedergabe abgebrochen.","A network error caused the media download to fail part-way.":"Der Videodownload ist aufgrund eines Netzwerkfehlers fehlgeschlagen.","The media could not be loaded, either because the server or network failed or because the format is not supported.":"Das Video konnte nicht geladen werden, da entweder ein Server- oder Netzwerkfehler auftrat oder das Format nicht unterstützt wird.","The media playback was aborted due to a corruption problem or because the media used features your browser did not support.":"Die Videowiedergabe wurde entweder wegen eines Problems mit einem beschädigten Video oder wegen verwendeten Funktionen, die vom Browser nicht unterstützt werden, abgebrochen.","No compatible source was found for this media.":"Für dieses Video wurde keine kompatible Quelle gefunden.","Play Video":"Video abspielen",Close:wN,"Modal Window":"Modales Fenster","This is a modal window":"Dies ist ein modales Fenster","This modal can be closed by pressing the Escape key or activating the close button.":'Durch Drücken der Esc-Taste bzw. Betätigung der Schaltfläche "Schließen" wird dieses modale Fenster geschlossen.',", opens captions settings dialog":", öffnet Einstellungen für Untertitel",", opens subtitles settings dialog":", öffnet Einstellungen für Untertitel",", selected":", ausgewählt","captions settings":"Untertiteleinstellungen","subtitles settings":"Untertiteleinstellungen","descriptions settings":"Einstellungen für Beschreibungen","Close Modal Dialog":"Modales Fenster schließen",Descriptions:CN,"descriptions off":"Beschreibungen aus","The media is encrypted and we do not have the keys to decrypt it.":"Die Entschlüsselungsschlüssel für den verschlüsselten Medieninhalt sind nicht verfügbar.",", opens descriptions settings dialog":", öffnet Einstellungen für Beschreibungen","Audio Track":"Tonspur",Text:AN,White:DN,Black:EN,Red:IN,Green:PN,Blue:MN,Yellow:LN,Magenta:kN,Cyan:RN,Background:ON,Window:NN,Transparent:BN,"Semi-Transparent":"Halbdurchsichtig",Opaque:FN,"Font Size":"Schriftgröße","Text Edge Style":"Textkantenstil",None:UN,Raised:VN,Depressed:zN,Uniform:GN,"Drop shadow":"Schlagschatten","Font Family":"Schriftfamilie","Proportional Sans-Serif":"Proportionale Sans-Serif","Monospace Sans-Serif":"Monospace Sans-Serif","Proportional Serif":"Proportionale Serif","Monospace Serif":"Monospace Serif",Casual:HN,Script:$N,"Small Caps":"Small-Caps",Reset:WN,"restore all settings to the default values":"Alle Einstellungen auf die Standardwerte zurücksetzen",Done:qN,"Caption Settings Dialog":"Einstellungsdialog für Untertitel","Beginning of dialog window. Escape will cancel and close the window.":"Anfang des Dialogfensters. Esc bricht ab und schließt das Fenster.","End of dialog window.":"Ende des Dialogfensters.","Audio Player":"Audio-Player","Video Player":"Video-Player","Progress Bar":"Fortschrittsbalken","progress bar timing: currentTime={1} duration={2}":"{1} von {2}","Volume Level":"Lautstärke","{1} is loading.":"{1} wird geladen.","Seek to live, currently behind live":"Zur Live-Übertragung wechseln. Aktuell wird es nicht live abgespielt.","Seek to live, currently playing live":"Zur Live-Übertragung wechseln. Es wird aktuell live abgespielt.","Exit Picture-in-Picture":"Bild-im-Bild-Modus beenden","Picture-in-Picture":"Bild-im-Bild-Modus","No content":"Kein Inhalt",Color:jN,Opacity:XN,"Text Background":"Texthintergrund","Caption Area Background":"Hintergrund des Untertitelbereichs","Playing in Picture-in-Picture":"Wird im Bild-im-Bild-Modus wiedergegeben","Skip forward {1} seconds":"{1} Sekunden vorwärts","Skip backward {1} seconds":"{1} Sekunden zurück"},bae=Object.freeze({__proto__:null,Background:ON,Black:EN,Blue:MN,Captions:TN,Casual:HN,Chapters:xN,Close:wN,Color:jN,Cyan:RN,Depressed:zN,Descriptions:CN,Done:qN,Duration:pN,Fullscreen:yN,Green:PN,LIVE:vN,Loaded:gN,Magenta:kN,Mute:_N,None:UN,Opacity:XN,Opaque:FN,Pause:fN,Play:hN,Progress:mN,Raised:VN,Red:IN,Replay:dN,Reset:WN,Script:$N,Subtitles:SN,Text:AN,Transparent:BN,Uniform:GN,Unmute:bN,White:DN,Window:NN,Yellow:LN,default:_ae}),YN="Aus Gründen des Jugendschutzes steht dieser Inhalt nur zwischen 20:00 und 06:00 Uhr zur Verfügung.",KN="Aus Gründen des Jugendschutzes steht dieser Inhalt nur zwischen 23:00 und 05:00 Uhr zur Verfügung.",ZN="Die Werbung wurde übersprungen.",QN="Dieser Inhalt ist nicht mehr verfügbar.",JN="Dieser Inhalt ist ausserhalb der Schweiz nicht verfügbar.",eB="Dieser Inhalt ist aus rechtlichen Gründen nicht verfügbar.",tB="Dieser Inhalt ist noch nicht verfügbar. Bitte probieren Sie es später noch einmal.",rB="Dieser Inhalt ist nicht verfügbar.",Sae={AGERATING12:YN,AGERATING18:KN,COMMERCIAL:ZN,ENDDATE:QN,GEOBLOCK:JN,LEGAL:eB,STARTDATE:tB,UNKNOWN:rB},Tae=Object.freeze({__proto__:null,AGERATING12:YN,AGERATING18:KN,COMMERCIAL:ZN,ENDDATE:QN,GEOBLOCK:JN,LEGAL:eB,STARTDATE:tB,UNKNOWN:rB,default:Sae});sr.addLanguage("de",Yr(Yr({},bae),Tae));var iB="Play",nB="Pause",aB="Replay",sB="Duration",oB="LIVE",lB="Loaded",uB="Progress",cB="Fullscreen",hB="Mute",fB="Unmute",dB="Subtitles",pB="Captions",vB="Chapters",gB="Descriptions",mB="Close",yB="Text",_B="White",bB="Black",SB="Red",TB="Green",xB="Blue",wB="Yellow",CB="Magenta",AB="Cyan",DB="Background",EB="Window",IB="Transparent",PB="Opaque",MB="None",LB="Raised",kB="Depressed",RB="Uniform",OB="Casual",NB="Script",BB="Reset",FB="Done",UB="Color",VB="Opacity",xae={"Audio Player":"Audio Player","Video Player":"Video Player",Play:iB,Pause:nB,Replay:aB,"Current Time":"Current Time",Duration:sB,"Remaining Time":"Remaining Time","Stream Type":"Stream Type",LIVE:oB,"Seek to live, currently behind live":"Seek to live, currently behind live","Seek to live, currently playing live":"Seek to live, currently playing live",Loaded:lB,Progress:uB,"Progress Bar":"Progress Bar","progress bar timing: currentTime={1} duration={2}":"{1} of {2}",Fullscreen:cB,"Exit Fullscreen":"Exit Fullscreen",Mute:hB,Unmute:fB,"Playback Rate":"Playback Rate",Subtitles:dB,"subtitles off":"subtitles off",Captions:pB,"captions off":"captions off",Chapters:vB,Descriptions:gB,"descriptions off":"descriptions off","Audio Track":"Audio Track","Volume Level":"Volume Level","You aborted the media playback":"You aborted the media playback","A network error caused the media download to fail part-way.":"A network error caused the media download to fail part-way.","The media could not be loaded, either because the server or network failed or because the format is not supported.":"The media could not be loaded, either because the server or network failed or because the format is not supported.","The media playback was aborted due to a corruption problem or because the media used features your browser did not support.":"The media playback was aborted due to a corruption problem or because the media used features your browser did not support.","No compatible source was found for this media.":"No compatible source was found for this media.","The media is encrypted and we do not have the keys to decrypt it.":"The media is encrypted and we do not have the keys to decrypt it.","Play Video":"Play Video",Close:mB,"Close Modal Dialog":"Close Modal Dialog","Modal Window":"Modal Window","This is a modal window":"This is a modal window","This modal can be closed by pressing the Escape key or activating the close button.":"This modal can be closed by pressing the Escape key or activating the close button.",", opens captions settings dialog":", opens captions settings dialog",", opens subtitles settings dialog":", opens subtitles settings dialog",", opens descriptions settings dialog":", opens descriptions settings dialog",", selected":", selected","captions settings":"captions settings","subtitles settings":"subtitles settings","descriptions settings":"descriptions settings",Text:yB,White:_B,Black:bB,Red:SB,Green:TB,Blue:xB,Yellow:wB,Magenta:CB,Cyan:AB,Background:DB,Window:EB,Transparent:IB,"Semi-Transparent":"Semi-Transparent",Opaque:PB,"Font Size":"Font Size","Text Edge Style":"Text Edge Style",None:MB,Raised:LB,Depressed:kB,Uniform:RB,"Drop shadow":"Drop shadow","Font Family":"Font Family","Proportional Sans-Serif":"Proportional Sans-Serif","Monospace Sans-Serif":"Monospace Sans-Serif","Proportional Serif":"Proportional Serif","Monospace Serif":"Monospace Serif",Casual:OB,Script:NB,"Small Caps":"Small Caps",Reset:BB,"restore all settings to the default values":"restore all settings to the default values",Done:FB,"Caption Settings Dialog":"Caption Settings Dialog","Beginning of dialog window. Escape will cancel and close the window.":"Beginning of dialog window. Escape will cancel and close the window.","End of dialog window.":"End of dialog window.","{1} is loading.":"{1} is loading.","Exit Picture-in-Picture":"Exit Picture-in-Picture","Picture-in-Picture":"Picture-in-Picture","No content":"No content",Color:UB,Opacity:VB,"Text Background":"Text Background","Caption Area Background":"Caption Area Background","Playing in Picture-in-Picture":"Playing in Picture-in-Picture","Skip backward {1} seconds":"Skip backward {1} seconds","Skip forward {1} seconds":"Skip forward {1} seconds"},wae=Object.freeze({__proto__:null,Background:DB,Black:bB,Blue:xB,Captions:pB,Casual:OB,Chapters:vB,Close:mB,Color:UB,Cyan:AB,Depressed:kB,Descriptions:gB,Done:FB,Duration:sB,Fullscreen:cB,Green:TB,LIVE:oB,Loaded:lB,Magenta:CB,Mute:hB,None:MB,Opacity:VB,Opaque:PB,Pause:nB,Play:iB,Progress:uB,Raised:LB,Red:SB,Replay:aB,Reset:BB,Script:NB,Subtitles:dB,Text:yB,Transparent:IB,Uniform:RB,Unmute:fB,White:_B,Window:EB,Yellow:wB,default:xae}),zB="To protect children this content is only available between 8PM and 6AM.",GB="To protect children this content is only available between 10PM and 5AM.",HB="This commercial content is not available.",$B="This content is not available anymore.",WB="This content is not available outside Switzerland.",qB="This content is not available due to legal restrictions.",jB="This content is not available yet.",XB="This content is not available.",Cae={AGERATING12:zB,AGERATING18:GB,COMMERCIAL:HB,ENDDATE:$B,GEOBLOCK:WB,LEGAL:qB,STARTDATE:jB,UNKNOWN:XB},Aae=Object.freeze({__proto__:null,AGERATING12:zB,AGERATING18:GB,COMMERCIAL:HB,ENDDATE:$B,GEOBLOCK:WB,LEGAL:qB,STARTDATE:jB,UNKNOWN:XB,default:Cae});sr.addLanguage("en",Yr(Yr({},wae),Aae));var YB="Lecture",KB="Pause",ZB="Revoir",QB="Durée",JB="EN DIRECT",eF="Chargé",tF="Progression",rF="Plein écran",iF="Mettre en sourdine",nF="Activer le son",aF="Sous-titres",sF="Sous-titres transcrits",oF="Chapitres",lF="Descriptions",uF="Fermer",cF="Texte",hF="Blanc",fF="Noir",dF="Rouge",pF="Vert",vF="Bleu",gF="Jaune",mF="Magenta",yF="Cyan",_F="Arrière-plan",bF="Fenêtre",SF="Transparent",TF="Opaque",xF="Aucun",wF="Élevé",CF="Enfoncé",AF="Uniforme",DF="Manuscrite",EF="Scripte",IF="Réinitialiser",PF="Terminé",MF="Couleur",LF="Opacité",Dae={"Audio Player":"Lecteur audio","Video Player":"Lecteur vidéo",Play:YB,Pause:KB,Replay:ZB,"Current Time":"Temps actuel",Duration:QB,"Remaining Time":"Temps restant","Stream Type":"Type de flux",LIVE:JB,"Seek to live, currently behind live":"Rechercher le direct, actuellement après le direct","Seek to live, currently playing live":"Rechercher le direct, le direct actuellement en cours de lecture",Loaded:eF,Progress:tF,"Progress Bar":"Barre de progression","progress bar timing: currentTime={1} duration={2}":"{1} de {2}",Fullscreen:rF,"Exit Fullscreen":"Fenêtré",Mute:iF,Unmute:nF,"Playback Rate":"Vitesse de lecture",Subtitles:aF,"subtitles off":"Sous-titres désactivés",Captions:sF,"captions off":"Sous-titres transcrits désactivés",Chapters:oF,Descriptions:lF,"descriptions off":"descriptions désactivées","Audio Track":"Piste audio","Volume Level":"Niveau de volume","You aborted the media playback":"Vous avez interrompu la lecture de la vidéo.","A network error caused the media download to fail part-way.":"Une erreur de réseau a interrompu le téléchargement de la vidéo.","The media could not be loaded, either because the server or network failed or because the format is not supported.":"Cette vidéo n'a pas pu être chargée, soit parce que le serveur ou le réseau a échoué ou parce que le format n'est pas reconnu.","The media playback was aborted due to a corruption problem or because the media used features your browser did not support.":"La lecture de la vidéo a été interrompue à cause d'un problème de corruption ou parce que la vidéo utilise des fonctionnalités non prises en charge par votre navigateur.","No compatible source was found for this media.":"Aucune source compatible n'a été trouvée pour cette vidéo.","The media is encrypted and we do not have the keys to decrypt it.":"Le média est chiffré et nous n'avons pas les clés pour le déchiffrer.","Play Video":"Lire la vidéo",Close:uF,"Close Modal Dialog":"Fermer la boîte de dialogue modale","Modal Window":"Fenêtre modale","This is a modal window":"Ceci est une fenêtre modale","This modal can be closed by pressing the Escape key or activating the close button.":"Ce modal peut être fermé en appuyant sur la touche Échap ou activer le bouton de fermeture.",", opens captions settings dialog":", ouvrir les paramètres des sous-titres transcrits",", opens subtitles settings dialog":", ouvrir les paramètres des sous-titres",", opens descriptions settings dialog":", ouvrir les paramètres des descriptions",", selected":", sélectionné","captions settings":"Paramètres des sous-titres transcrits","subtitles settings":"Paramètres des sous-titres","descriptions settings":"Paramètres des descriptions",Text:cF,White:hF,Black:fF,Red:dF,Green:pF,Blue:vF,Yellow:gF,Magenta:mF,Cyan:yF,Background:_F,Window:bF,Transparent:SF,"Semi-Transparent":"Semi-transparent",Opaque:TF,"Font Size":"Taille des caractères","Text Edge Style":"Style des contours du texte",None:xF,Raised:wF,Depressed:CF,Uniform:AF,"Drop shadow":"Ombre portée","Font Family":"Famille de polices","Proportional Sans-Serif":"Polices à chasse variable sans empattement (Proportional Sans-Serif)","Monospace Sans-Serif":"Polices à chasse fixe sans empattement (Monospace Sans-Serif)","Proportional Serif":"Polices à chasse variable avec empattement (Proportional Serif)","Monospace Serif":"Polices à chasse fixe avec empattement (Monospace Serif)",Casual:DF,Script:EF,"Small Caps":"Petites capitales",Reset:IF,"restore all settings to the default values":"Restaurer tous les paramètres aux valeurs par défaut",Done:PF,"Caption Settings Dialog":"Boîte de dialogue des paramètres des sous-titres transcrits","Beginning of dialog window. Escape will cancel and close the window.":"Début de la fenêtre de dialogue. La touche d'échappement annulera et fermera la fenêtre.","End of dialog window.":"Fin de la fenêtre de dialogue.","Exit Picture-in-Picture":"Quitter le mode image dans l'image","Picture-in-Picture":"Image dans l'image","{1} is loading.":"{1} en cours de chargement.","No content":"Aucun contenu",Color:MF,Opacity:LF,"Text Background":"Arrière-plan du texte","Caption Area Background":"Arrière-plan de la zone de sous-titre","Skip backward {1} seconds":"Reculer de {1} secondes","Skip forward {1} seconds":"Avancer de {1} secondes"},Eae=Object.freeze({__proto__:null,Background:_F,Black:fF,Blue:vF,Captions:sF,Casual:DF,Chapters:oF,Close:uF,Color:MF,Cyan:yF,Depressed:CF,Descriptions:lF,Done:PF,Duration:QB,Fullscreen:rF,Green:pF,LIVE:JB,Loaded:eF,Magenta:mF,Mute:iF,None:xF,Opacity:LF,Opaque:TF,Pause:KB,Play:YB,Progress:tF,Raised:wF,Red:dF,Replay:ZB,Reset:IF,Script:EF,Subtitles:aF,Text:cF,Transparent:SF,Uniform:AF,Unmute:nF,White:hF,Window:bF,Yellow:gF,default:Dae}),kF="Pour protéger les enfants, ce contenu est accessible entre 20h et 6h.",RF="Pour protéger les enfants, ce contenu est accessible entre 23h et 5h.",OF="Ce contenu n'est actuellement pas disponible.",NF="Ce contenu n'est plus disponible.",BF="La RTS ne dispose pas des droits de diffusion en dehors de la Suisse.",FF="Pour des raisons juridiques, ce contenu n'est pas disponible.",UF="Ce contenu n'est pas encore disponible. Veuillez réessayer plus tard.",VF="Ce contenu n'est actuellement pas disponible.",Iae={AGERATING12:kF,AGERATING18:RF,COMMERCIAL:OF,ENDDATE:NF,GEOBLOCK:BF,LEGAL:FF,STARTDATE:UF,UNKNOWN:VF},Pae=Object.freeze({__proto__:null,AGERATING12:kF,AGERATING18:RF,COMMERCIAL:OF,ENDDATE:NF,GEOBLOCK:BF,LEGAL:FF,STARTDATE:UF,UNKNOWN:VF,default:Iae});sr.addLanguage("fr",Yr(Yr({},Eae),Pae));var zF="Play",GF="Pausa",HF="Replay",$F="Durata",WF="LIVE",qF="Caricato",jF="Stato",XF="Schermo intero",YF="Disattiva l’audio",KF="Attiva l’audio",ZF="Sottotitoli",QF="Sottotitoli non udenti",JF="Capitolo",eU="Descrizioni",tU="Chiudi",rU="Testo",iU="Bianco",nU="Nero",aU="Rosso",sU="Verde",oU="Blu",lU="Giallo",uU="Magenta",cU="Ciano",hU="Sfondo",fU="Finestra",dU="Trasparente",pU="Opaco",vU="Nessuno",gU="Uniforme",mU="Reinizializza",yU="Fatto",_U="Colore",bU="Opacità",Mae={"Audio Player":"Lettore audio","Video Player":"Lettore video",Play:zF,Pause:GF,Replay:HF,"Current Time":"Orario attuale",Duration:$F,"Remaining Time":"Tempo rimanente","Stream Type":"Tipo di streaming",LIVE:WF,Loaded:qF,Progress:jF,"Progress Bar":"Barra di avanzamento","progress bar timing: currentTime={1} duration={2}":"{1} di {2}",Fullscreen:XF,"Exit Fullscreen":"Chiudi Schermo intero",Mute:YF,Unmute:KF,"Playback Rate":"Velocità di riproduzione",Subtitles:ZF,"subtitles off":"Senza sottotitoli",Captions:QF,"captions off":"Senza sottotitoli non udenti",Chapters:JF,Descriptions:eU,"descriptions off":"Descrizioni disattivate","Audio Track":"Traccia audio","Volume Level":"Livello del volume","You aborted the media playback":"La riproduzione del contenuto multimediale è stata interrotta.","A network error caused the media download to fail part-way.":"Il download del contenuto multimediale è stato interrotto a causa di un problema rete.","The media could not be loaded, either because the server or network failed or because the format is not supported.":"Il contenuto multimediale non può essere caricato a causa di un errore nel server o nella rete o perché il formato non viene supportato.","The media playback was aborted due to a corruption problem or because the media used features your browser did not support.":"La riproduzione del contenuto multimediale è stata interrotta a causa di un file danneggiato o per l’utilizzo di impostazioni non supportate dal browser.","No compatible source was found for this media.":"Non ci sono fonti compatibili per questo contenuto multimediale.","The media is encrypted and we do not have the keys to decrypt it.":"Il contenuto multimediale è criptato e non disponiamo delle chiavi per decifrarlo.","Play Video":"Riproduci il video",Close:tU,"Close Modal Dialog":"Chiudi la finestra di dialogo","Modal Window":"Finestra di dialogo","This is a modal window":"Questa è una finestra di dialogo","This modal can be closed by pressing the Escape key or activating the close button.":"Questa finestra di dialogo può essere chiusa premendo sul tasto Esc o attivando il pulsante di chiusura.",", opens captions settings dialog":", aprire i parametri della trascrizione dei sottotitoli",", opens subtitles settings dialog":", aprire i parametri dei sottotitoli",", opens descriptions settings dialog":", aprire i parametri delle descrizioni",", selected":", selezionato","captions settings":"Parametri sottotitoli non udenti","subtitles settings":"Parametri sottotitoli","descriptions settings":"Parametri descrizioni",Text:rU,White:iU,Black:nU,Red:aU,Green:sU,Blue:oU,Yellow:lU,Magenta:uU,Cyan:cU,Background:hU,Window:fU,Transparent:dU,"Semi-Transparent":"Semi-Trasparente",Opaque:pU,"Font Size":"Dimensione dei caratteri","Text Edge Style":"Stile dei bordi del testo",None:vU,Uniform:gU,"Drop shadow":"Ombra","Font Family":"Carattere","Proportional Sans-Serif":"Sans-Serif proporzionale","Monospace Sans-Serif":"Sans-Serif monospaziato","Proportional Serif":"Serif proporzionale","Monospace Serif":"Serif monospaziato","Small Caps":"Maiuscoletto",Reset:mU,"restore all settings to the default values":"Ripristina i valori predefiniti per tutti i parametri",Done:yU,"Caption Settings Dialog":"Finestra di dialogo dei parametri della trascrizione dei sottotitoli","Beginning of dialog window. Escape will cancel and close the window.":"Inizio della finestra di dialogo. Il tasto Esc annullerà l’operazione e chiuderà la finestra.","End of dialog window.":"Fine della finestra di dialogo.","{1} is loading.":"{1} in fase di caricamento.","Exit Picture-in-Picture":"Esci dalla modalità Picture-in-Picture","Picture-in-Picture":"Picture-in-Picture",Color:_U,Opacity:bU,"Text Background":"Sfondo testo","Caption Area Background":"Sfondo area sottotitoli","Skip forward {1} seconds":"Avanti {1} secondi","Skip backward {1} seconds":"Indietro {1} secondi"},Lae=Object.freeze({__proto__:null,Background:hU,Black:nU,Blue:oU,Captions:QF,Chapters:JF,Close:tU,Color:_U,Cyan:cU,Descriptions:eU,Done:yU,Duration:$F,Fullscreen:XF,Green:sU,LIVE:WF,Loaded:qF,Magenta:uU,Mute:YF,None:vU,Opacity:bU,Opaque:pU,Pause:GF,Play:zF,Progress:jF,Red:aU,Replay:HF,Reset:mU,Subtitles:ZF,Text:rU,Transparent:dU,Uniform:gU,Unmute:KF,White:iU,Window:fU,Yellow:lU,default:Mae}),SU="Per proteggere i bambini, questo media è disponibile solo fra le 20 e le 6.",TU="Per proteggere i bambini, questo media è disponibile solo fra le 23 le 5.",xU="Questo contenuto commerciale non è disponibile.",wU="Questo media non è più disponibile.",CU="Questo media non è disponibile fuori dalla Svizzera.",AU="Il contenuto non è fruibile a causa di restrizioni legali.",DU="Il contenuto non è ancora disponibile. Per cortesia prova più tardi.",EU="Questo media non è disponibile.",kae={AGERATING12:SU,AGERATING18:TU,COMMERCIAL:xU,ENDDATE:wU,GEOBLOCK:CU,LEGAL:AU,STARTDATE:DU,UNKNOWN:EU},Rae=Object.freeze({__proto__:null,AGERATING12:SU,AGERATING18:TU,COMMERCIAL:xU,ENDDATE:wU,GEOBLOCK:CU,LEGAL:AU,STARTDATE:DU,UNKNOWN:EU,default:kae});sr.addLanguage("it",Yr(Yr({},Lae),Rae));var IU="Laschar ir",PU="Pausa",MU="Mussar danovamain",LU="Durada",kU="LIVE",RU="Chargià",OU="Progress",NU="Entir visur",BU="Senza tun",FU="Cun tun",UU="Suttitels",VU="Suttitels",zU="Chapitels",GU="Descripziuns",HU="Serrar",$U="Text",WU="Alv",qU="Nair",jU="Cotschn",XU="Verd",YU="Blau",KU="Mellen",ZU="Magenta",QU="Cyan",JU="Fund",eV="Fanestra",tV="Transparent",rV="Betg transparent",iV="Nagin",nV="Auzà",aV="Sbassà",sV="Uniform",oV="Sumbriva",lV="Casual",uV="Script",cV="Da nov",hV="Fatg",fV="Per proteger uffants, è quest cuntegn disponibel mo tranter las 20.00 e las 06.00.",dV="Per proteger uffants, è quest cuntegn disponibel mo tranter las 23.00 e las 05.00.",pV="Quest medium commerzial n'è betg disponibel.",vV="Quest cuntegn n'è betg pli disponibel.",gV="Quest cuntegn n'è betg disponibel ordaifer la Svizra.",mV="Quest cuntegn n'è betg disponibel perquai ch'el è scadì.",yV="Quest cuntegn n'è betg anc disponibel. Empruvai pli tard.",_V="Quest cuntegn n'è betg disponibel.",Oae={"Audio Player":"Audio-Player","Video Player":"Video-Player",Play:IU,Pause:PU,Replay:MU,"Current Time":"Temp actual",Duration:LU,"Remaining Time":"Temp restant","Stream Type":"Tip dal stream",LIVE:kU,Loaded:RU,Progress:OU,"Progress Bar":"Bar da progessiun","progress bar timing: currentTime={1} duration={2}":"{1} da {2}",Fullscreen:NU,"Non-Fullscreen":"Betg entir visur",Mute:BU,Unmute:FU,"Playback Rate":"Tempo ",Subtitles:UU,"subtitles off":"senza suttitels",Captions:VU,"captions off":"senza suttitels",Chapters:zU,Descriptions:GU,"descriptions off":"senza descripziuns","Audio Track":"Piese audio","Volume Level":"Nivel dal volumen","You aborted the media playback":"Vus avais interrut il vdieo","A network error caused the media download to fail part-way.":"In sbagl en la rait ha impedì il download","The media could not be loaded, either because the server or network failed or because the format is not supported.":"Il video n'è betg chargià - ubain per in sbagl da server / da la rait, ubain ch'il format n'è betg cumpatibel.","The media playback was aborted due to a corruption problem or because the media used features your browser did not support.":"Il video è interrut: Ubain ch'il video è donnegià, ubain che funcziuns n'èn betg cumpatiblas.","No compatible source was found for this media.":"Chattà nagina funtauna cumpatibla per quest video.","The media is encrypted and we do not have the keys to decrypt it.":"Il video è codifitgà da moda nunenconuschenta.","Play Video":"Aviar video",Close:HU,"Close Modal Dialog":"Serrar la fanestra modala","Modal Window":"Fanestra modala","This is a modal window":"Quai è ina fanestra modala","This modal can be closed by pressing the Escape key or activating the close button.":'Questa fanestra modala pudais serrar cun la tasta "Escape" ubain cun il buttun.',", opens captions settings dialog":", avra opziuns per ils suttitels",", opens subtitles settings dialog":", avra opziuns per ils suttitels",", opens descriptions settings dialog":", avra opziuns per la descripziun",", selected":", selecziunà","captions settings":"opziuns per ils suttitels","subtitles settings":"opziuns per ils suttitels","descriptions settings":"opziuns per la descripziun",Text:$U,White:WU,Black:qU,Red:jU,Green:XU,Blue:YU,Yellow:KU,Magenta:ZU,Cyan:QU,Background:JU,Window:eV,Transparent:tV,"Semi-Transparent":"Mez transparent",Opaque:rV,"Font Size":"Grandezza dal text","Text Edge Style":"Stil dal text",None:iV,Raised:nV,Depressed:aV,Uniform:sV,Dropshadow:oV,"Font Family":"Scrittira","Proportional Sans-Serif":"Proportionale Sans-Serif","Monospace Sans-Serif":"Monospace Sans-Serif","Proportional Serif":"Proportionale Serif","Monospace Serif":"Monospace Serif",Casual:lV,Script:uV,"Small Caps":"Bustabs pitschens",Reset:cV,"restore all settings to the default values":"Enavos tar las opziuns da standard",Done:hV,"Caption Settings Dialog":"Opziuns per suttitels","Beginning of dialog window. Escape will cancel and close the window.":"Entschatta da la fanestra da dialog. Escape stizza e serra la fanestra.","End of dialog window.":"Fin da la fanestra da dialog.",AGERATING12:fV,AGERATING18:dV,COMMERCIAL:pV,ENDDATE:vV,GEOBLOCK:gV,LEGAL:mV,STARTDATE:yV,UNKNOWN:_V},Nae=Object.freeze({__proto__:null,AGERATING12:fV,AGERATING18:dV,Background:JU,Black:qU,Blue:YU,COMMERCIAL:pV,Captions:VU,Casual:lV,Chapters:zU,Close:HU,Cyan:QU,Depressed:aV,Descriptions:GU,Done:hV,Dropshadow:oV,Duration:LU,ENDDATE:vV,Fullscreen:NU,GEOBLOCK:gV,Green:XU,LEGAL:mV,LIVE:kU,Loaded:RU,Magenta:ZU,Mute:BU,None:iV,Opaque:rV,Pause:PU,Play:IU,Progress:OU,Raised:nV,Red:jU,Replay:MU,Reset:cV,STARTDATE:yV,Script:uV,Subtitles:UU,Text:$U,Transparent:tV,UNKNOWN:_V,Uniform:sV,Unmute:FU,White:WU,Window:eV,Yellow:KU,default:Oae});sr.addLanguage("rm",Yr({},Nae));const Bae=["url","mimeType","keySystems"],Fae=["src"];class dt{static addBlockedSegments(e,t=[]){const i="srgssr-blocked-segments",n=e.textTracks().getTrackById(i);if(n&&e.textTracks().removeTrack(n),!Array.isArray(t)||!t.length)return;const a=t.filter(s=>s.blockReason);a.length&&dt.createTextTrack(e,i).then(s=>{a.forEach(o=>{dt.addTextTrackCue(s,o)}),e.textTracks().addTrack(s)})}static addRemoteTextTracks(e,t=[]){Array.isArray(t)&&t.forEach(({type:i,language:n,locale:a,url:s})=>{e.addRemoteTextTrack({kind:i==="SDH"?"captions":"subtitles",label:n,language:a,src:s})})}static addTextTrackCue(e,t){const i=(Number.isFinite(t.markIn)?t.markIn:t.fullLengthMarkIn)/1e3,n=(Number.isFinite(t.markOut)?t.markOut:t.fullLengthMarkOut)/1e3;e.addCue(new VTTCue(i,n,JSON.stringify(t)))}static addTextTracks(e,{mediaData:t}){dt.addRemoteTextTracks(e,t.subtitles),dt.addChapters(e,t.urn,t.chapters),dt.addBlockedSegments(e,t.blockedSegments),dt.addIntervals(e,t.intervals)}static addChapters(e,t,i=[]){const n="srgssr-chapters",a=e.textTracks().getTrackById(n);a&&e.textTracks().removeTrack(a),!(!Array.isArray(i)||!i.length)&&dt.createTextTrack(e,n).then(s=>{i.forEach(o=>{t===o.fullLengthUrn&&dt.addTextTrackCue(s,o)}),e.textTracks().addTrack(s)})}static addIntervals(e,t=[]){const i="srgssr-intervals",n=e.textTracks().getTrackById(i);n&&e.textTracks().removeTrack(n),!(!Array.isArray(t)||!t.length)&&dt.createTextTrack(e,i).then(a=>{t.forEach(s=>{dt.addTextTrackCue(a,s)}),e.textTracks().addTrack(a)})}static blockingReason(e,t){if(!t.mediaData.blockReason)return;const i=e.localize(t.mediaData.blockReason);return dt.error(e,{code:MediaError.MEDIA_ERR_ABORTED,message:i,metadata:{errorType:t.mediaData.blockReason,src:t}}),!0}static composeAkamaiResources(e=[]){return ih(function*(){return Pu.hasToken(e)?Pu.tokenizeSources(e):Promise.resolve(e)})()}static composeKeySystemsResources(e=[]){return Zp.hasDrm(e),e.map(t=>Yr(Yr({},t),Zp.buildKeySystems(t.drmList)))}static composeMainResources(e){return dt.composeAkamaiResources(dt.composeKeySystemsResources(dt.filterIncompatibleResources(e.getMainResources())))}static composeSrcMediaData({mediaData:e,disableTrackers:t},i){const n=sr.obj.merge(i,e),{url:a,mimeType:s,keySystems:o}=n,l=M4(n,Bae);return{src:a,type:s,keySystems:o,disableTrackers:t,mediaData:l}}static createTextTrack(e,t){return new Promise(i=>{setTimeout(()=>{i(new sr.TextTrack({id:t,kind:"metadata",label:t,tech:e.tech(!0)}))},100)})}static cuechangeEventProxy(e){e.textTracks().on("addtrack",({track:t})=>{["srgssr-chapters","srgssr-intervals"].includes(t.id)&&t.on("cuechange",()=>{const[i]=Array.from(t.activeCues),n=t.id.includes("srgssr-chapters")?"srgssr/chapter":"srgssr/interval";e.trigger({type:n,data:i})})})}static dataProvider(e){if(!e.options().srgOptions.dataProvider){const{dataProviderHost:t,dataProviderUrlHandler:i}=e.options().srgOptions,a=new L4(t).handleRequest(i);e.options({srgOptions:{dataProvider:a}})}return e.options().srgOptions.dataProvider}static dataProviderError(e,t){if(!t)return;const i=t.statusText?t.statusText:t.message;return dt.error(e,{code:0,message:e.localize("UNKNOWN"),metadata:{errorType:"UNKNOWN",urn:e.src(),status:t.status,statusText:i,url:t.url}}),!0}static error(e,{code:t,message:i,metadata:n}){e.error(null),e.error({code:t,message:i,metadata:n})}static filterIncompatibleResources(e=[]){return e.filter(t=>!["RTMP","HDS"].includes(t.streaming))}static getBlockedSegment(e){const i=e.textTracks().getTrackById("srgssr-blocked-segments");if(!i)return;const[n]=Array.from(i.activeCues);return n}static getBlockedSegmentByTime(e,t){const i=dt.getBlockedSegment(e);return i&&t>=i.startTime&&tn===t)||e[0]}static getSrcMediaObj(e,t){return ih(function*(){const{src:i}=t,n=M4(t,Fae),a=yield dt.getMediaComposition(i,dt.dataProvider(e)),s=yield dt.composeMainResources(a),o=dt.getMediaData(s);return dt.composeSrcMediaData(n,o)})()}static handleCurrentTime(e,t){const i=dt.getBlockedSegmentByTime(e,t);if(!i||!Number.isFinite(i.endTime))return t;const n=i.endTime+.1;return e.trigger({type:"srgssr/blocked-segment",data:i}),e.currentTime(n),n}static handleSetCurrentTime(e,t){const{endTime:i}=dt.getBlockedSegmentByTime(e,t)||{};return Number.isFinite(i)?i:t}static handleSetSource(e,t,i){return ih(function*(){try{const n=yield dt.getSrcMediaObj(e,t);return dt.srgAnalytics(e),dt.updateTitleBar(e,n),dt.updatePoster(e,n),dt.blockingReason(e,n)?void 0:(dt.addTextTracks(e,n),i(null,n))}catch(n){return dt.dataProviderError(e,n)?void 0:i(n)}})()}static srgAnalytics(e){if(e.options().trackers.srgAnalytics!==!1&&!e.options().trackers.srgAnalytics){const t=new su(e,{debug:e.debug(),playerVersion:sr.VERSION.pillarbox,tagCommanderScriptURL:e.options().srgOptions.tagCommanderScriptURL});e.options({trackers:{srgAnalytics:t}})}}static updatePoster(e,t,i=vae){e.poster(i.scale({url:t.mediaData.imageUrl}))}static updateTitleBar(e,t){e.titleBar&&e.titleBar.update({title:t.mediaData.vendor,description:t.mediaData.title})}static middleware(e){return dt.cuechangeEventProxy(e),{currentTime:t=>dt.handleCurrentTime(e,t),setCurrentTime:t=>dt.handleSetCurrentTime(e,t),setSource:function(){var t=ih(function*(i,n){return dt.handleSetSource(e,i,n)});return function(n,a){return t.apply(this,arguments)}}()}}}sr.use("srgssr/urn",dt.middleware);sr.options.srgOptions={dataProvider:void 0,dataProviderHost:void 0,dataProviderUrlHandler:void 0,tagCommanderScriptURL:void 0};function bs(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function bV(r,e){r.prototype=Object.create(e.prototype),r.prototype.constructor=r,r.__proto__=e}/*! + * GSAP 3.12.5 + * https://gsap.com + * + * @license Copyright 2008-2024, GreenSock. All rights reserved. + * Subject to the terms at https://gsap.com/standard-license or for + * Club GSAP members, the agreement issued with that membership. + * @author: Jack Doyle, jack@greensock.com +*/var pn={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},Jh={duration:.5,overwrite:!1,delay:0},bA,si,Xt,Vn=1e8,Gt=1/Vn,ZT=Math.PI*2,Uae=ZT/4,Vae=0,SV=Math.sqrt,zae=Math.cos,Gae=Math.sin,$r=function(e){return typeof e=="string"},or=function(e){return typeof e=="function"},Gs=function(e){return typeof e=="number"},SA=function(e){return typeof e>"u"},ns=function(e){return typeof e=="object"},Wi=function(e){return e!==!1},TA=function(){return typeof window<"u"},Kg=function(e){return or(e)||$r(e)},TV=typeof ArrayBuffer=="function"&&ArrayBuffer.isView||function(){},oi=Array.isArray,QT=/(?:-?\.?\d|\.)+/gi,xV=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,ph=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,P2=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,wV=/[+-]=-?[.\d]+/,CV=/[^,'"\[\]\s]+/gi,Hae=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,Zt,Ra,JT,xA,bn={},hy={},AV,DV=function(e){return(hy=Yu(e,bn))&&Yi},wA=function(e,t){return console.warn("Invalid property",e,"set to",t,"Missing plugin? gsap.registerPlugin()")},Qp=function(e,t){return!t&&console.warn(e)},EV=function(e,t){return e&&(bn[e]=t)&&hy&&(hy[e]=t)||bn},Jp=function(){return 0},$ae={suppressEvents:!0,isStart:!0,kill:!1},o0={suppressEvents:!0,kill:!1},Wae={suppressEvents:!0},CA={},Ho=[],ex={},IV,sn={},M2={},V4=30,l0=[],AA="",DA=function(e){var t=e[0],i,n;if(ns(t)||or(t)||(e=[e]),!(i=(t._gsap||{}).harness)){for(n=l0.length;n--&&!l0[n].targetTest(t););i=l0[n]}for(n=e.length;n--;)e[n]&&(e[n]._gsap||(e[n]._gsap=new JV(e[n],i)))||e.splice(n,1);return e},Mu=function(e){return e._gsap||DA(zn(e))[0]._gsap},PV=function(e,t,i){return(i=e[t])&&or(i)?e[t]():SA(i)&&e.getAttribute&&e.getAttribute(t)||i},qi=function(e,t){return(e=e.split(",")).forEach(t)||e},vr=function(e){return Math.round(e*1e5)/1e5||0},Vr=function(e){return Math.round(e*1e7)/1e7||0},Dh=function(e,t){var i=t.charAt(0),n=parseFloat(t.substr(2));return e=parseFloat(e),i==="+"?e+n:i==="-"?e-n:i==="*"?e*n:e/n},qae=function(e,t){for(var i=t.length,n=0;e.indexOf(t[n])<0&&++no;)s=s._prev;return s?(t._next=s._next,s._next=t):(t._next=e[i],e[i]=t),t._next?t._next._prev=t:e[n]=t,t._prev=s,t.parent=t._dp=e,t},q_=function(e,t,i,n){i===void 0&&(i="_first"),n===void 0&&(n="_last");var a=t._prev,s=t._next;a?a._next=s:e[i]===t&&(e[i]=s),s?s._prev=a:e[n]===t&&(e[n]=a),t._next=t._prev=t.parent=null},Zo=function(e,t){e.parent&&(!t||e.parent.autoRemoveChildren)&&e.parent.remove&&e.parent.remove(e),e._act=0},Lu=function(e,t){if(e&&(!t||t._end>e._dur||t._start<0))for(var i=e;i;)i._dirty=1,i=i.parent;return e},Yae=function(e){for(var t=e.parent;t&&t.parent;)t._dirty=1,t.totalDuration(),t=t.parent;return e},tx=function(e,t,i,n){return e._startAt&&(si?e._startAt.revert(o0):e.vars.immediateRender&&!e.vars.autoRevert||e._startAt.render(t,!0,n))},Kae=function r(e){return!e||e._ts&&r(e.parent)},G4=function(e){return e._repeat?ef(e._tTime,e=e.duration()+e._rDelay)*e:0},ef=function(e,t){var i=Math.floor(e/=t);return e&&i===e?i-1:i},py=function(e,t){return(e-t._start)*t._ts+(t._ts>=0?0:t._dirty?t.totalDuration():t._tDur)},j_=function(e){return e._end=Vr(e._start+(e._tDur/Math.abs(e._ts||e._rts||Gt)||0))},X_=function(e,t){var i=e._dp;return i&&i.smoothChildTiming&&e._ts&&(e._start=Vr(i._time-(e._ts>0?t/e._ts:((e._dirty?e.totalDuration():e._tDur)-t)/-e._ts)),j_(e),i._dirty||Lu(i,e)),e},OV=function(e,t){var i;if((t._time||!t._dur&&t._initted||t._startGt)&&t.render(i,!0)),Lu(e,t)._dp&&e._initted&&e._time>=e._dur&&e._ts){if(e._dur=0&&i.totalTime(i._tTime),i=i._dp;e._zTime=-Gt}},Ba=function(e,t,i,n){return t.parent&&Zo(t),t._start=Vr((Gs(i)?i:i||e!==Zt?Mn(e,i,t):e._time)+t._delay),t._end=Vr(t._start+(t.totalDuration()/Math.abs(t.timeScale())||0)),RV(e,t,"_first","_last",e._sort?"_start":0),rx(t)||(e._recent=t),n||OV(e,t),e._ts<0&&X_(e,e._tTime),e},NV=function(e,t){return(bn.ScrollTrigger||wA("scrollTrigger",t))&&bn.ScrollTrigger.create(t,e)},BV=function(e,t,i,n,a){if(IA(e,t,a),!e._initted)return 1;if(!i&&e._pt&&!si&&(e._dur&&e.vars.lazy!==!1||!e._dur&&e.vars.lazy)&&IV!==ln.frame)return Ho.push(e),e._lazy=[a,n],1},Zae=function r(e){var t=e.parent;return t&&t._ts&&t._initted&&!t._lock&&(t.rawTime()<0||r(t))},rx=function(e){var t=e.data;return t==="isFromStart"||t==="isStart"},Qae=function(e,t,i,n){var a=e.ratio,s=t<0||!t&&(!e._start&&Zae(e)&&!(!e._initted&&rx(e))||(e._ts<0||e._dp._ts<0)&&!rx(e))?0:1,o=e._rDelay,l=0,u,c,h;if(o&&e._repeat&&(l=Xv(0,e._tDur,t),c=ef(l,o),e._yoyo&&c&1&&(s=1-s),c!==ef(e._tTime,o)&&(a=1-s,e.vars.repeatRefresh&&e._initted&&e.invalidate())),s!==a||si||n||e._zTime===Gt||!t&&e._zTime){if(!e._initted&&BV(e,t,n,i,l))return;for(h=e._zTime,e._zTime=t||(i?Gt:0),i||(i=t&&!h),e.ratio=s,e._from&&(s=1-s),e._time=0,e._tTime=l,u=e._pt;u;)u.r(s,u.d),u=u._next;t<0&&tx(e,t,i,!0),e._onUpdate&&!i&&hn(e,"onUpdate"),l&&e._repeat&&!i&&e.parent&&hn(e,"onRepeat"),(t>=e._tDur||t<0)&&e.ratio===s&&(s&&Zo(e,1),!i&&!si&&(hn(e,s?"onComplete":"onReverseComplete",!0),e._prom&&e._prom()))}else e._zTime||(e._zTime=t)},Jae=function(e,t,i){var n;if(i>t)for(n=e._first;n&&n._start<=i;){if(n.data==="isPause"&&n._start>t)return n;n=n._next}else for(n=e._last;n&&n._start>=i;){if(n.data==="isPause"&&n._start0&&!n&&X_(e,e._tTime=e._tDur*o),e.parent&&j_(e),i||Lu(e.parent,e),e},H4=function(e){return e instanceof Ti?Lu(e):tf(e,e._dur)},ese={_start:0,endTime:Jp,totalDuration:Jp},Mn=function r(e,t,i){var n=e.labels,a=e._recent||ese,s=e.duration()>=Vn?a.endTime(!1):e._dur,o,l,u;return $r(t)&&(isNaN(t)||t in n)?(l=t.charAt(0),u=t.substr(-1)==="%",o=t.indexOf("="),l==="<"||l===">"?(o>=0&&(t=t.replace(/=/,"")),(l==="<"?a._start:a.endTime(a._repeat>=0))+(parseFloat(t.substr(1))||0)*(u?(o<0?a:i).totalDuration()/100:1)):o<0?(t in n||(n[t]=s),n[t]):(l=parseFloat(t.charAt(o-1)+t.substr(o+1)),u&&i&&(l=l/100*(oi(i)?i[0]:i).totalDuration()),o>1?r(e,t.substr(0,o-1),i)+l:s+l)):t==null?s:+t},Tp=function(e,t,i){var n=Gs(t[1]),a=(n?2:1)+(e<2?0:1),s=t[a],o,l;if(n&&(s.duration=t[1]),s.parent=i,e){for(o=s,l=i;l&&!("immediateRender"in o);)o=l.vars.defaults||{},l=Wi(l.vars.inherit)&&l.parent;s.immediateRender=Wi(o.immediateRender),e<2?s.runBackwards=1:s.startAt=t[a-1]}return new xr(t[0],s,t[a+1])},ul=function(e,t){return e||e===0?t(e):t},Xv=function(e,t,i){return it?t:i},ii=function(e,t){return!$r(e)||!(t=Hae.exec(e))?"":t[1]},tse=function(e,t,i){return ul(i,function(n){return Xv(e,t,n)})},ix=[].slice,FV=function(e,t){return e&&ns(e)&&"length"in e&&(!t&&!e.length||e.length-1 in e&&ns(e[0]))&&!e.nodeType&&e!==Ra},rse=function(e,t,i){return i===void 0&&(i=[]),e.forEach(function(n){var a;return $r(n)&&!t||FV(n,1)?(a=i).push.apply(a,zn(n)):i.push(n)})||i},zn=function(e,t,i){return Xt&&!t&&Xt.selector?Xt.selector(e):$r(e)&&!i&&(JT||!rf())?ix.call((t||xA).querySelectorAll(e),0):oi(e)?rse(e,i):FV(e)?ix.call(e,0):e?[e]:[]},nx=function(e){return e=zn(e)[0]||Qp("Invalid scope")||{},function(t){var i=e.current||e.nativeElement||e;return zn(t,i.querySelectorAll?i:i===e?Qp("Invalid scope")||xA.createElement("div"):e)}},UV=function(e){return e.sort(function(){return .5-Math.random()})},VV=function(e){if(or(e))return e;var t=ns(e)?e:{each:e},i=ku(t.ease),n=t.from||0,a=parseFloat(t.base)||0,s={},o=n>0&&n<1,l=isNaN(n)||o,u=t.axis,c=n,h=n;return $r(n)?c=h={center:.5,edges:.5,end:1}[n]||0:!o&&l&&(c=n[0],h=n[1]),function(d,f,p){var v=(p||t).length,g=s[v],m,y,_,b,T,x,C,D,I;if(!g){if(I=t.grid==="auto"?0:(t.grid||[1,Vn])[1],!I){for(C=-Vn;C<(C=p[I++].getBoundingClientRect().left)&&IC&&(C=T),Tv?v-1:u?u==="y"?v/I:I:Math.max(I,v/I))||0)*(n==="edges"?-1:1),g.b=v<0?a-v:a,g.u=ii(t.amount||t.each)||0,i=i&&v<0?KV(i):i}return v=(g[d]-g.min)/g.max||0,Vr(g.b+(i?i(v):v)*g.v)+g.u}},ax=function(e){var t=Math.pow(10,((e+"").split(".")[1]||"").length);return function(i){var n=Vr(Math.round(parseFloat(i)/e)*e*t);return(n-n%1)/t+(Gs(i)?0:ii(i))}},zV=function(e,t){var i=oi(e),n,a;return!i&&ns(e)&&(n=i=e.radius||Vn,e.values?(e=zn(e.values),(a=!Gs(e[0]))&&(n*=n)):e=ax(e.increment)),ul(t,i?or(e)?function(s){return a=e(s),Math.abs(a-s)<=n?a:s}:function(s){for(var o=parseFloat(a?s.x:s),l=parseFloat(a?s.y:0),u=Vn,c=0,h=e.length,d,f;h--;)a?(d=e[h].x-o,f=e[h].y-l,d=d*d+f*f):d=Math.abs(e[h]-o),dn?a-s:s)})},ev=function(e){for(var t=0,i="",n,a,s,o;~(n=e.indexOf("random(",t));)s=e.indexOf(")",n),o=e.charAt(n+7)==="[",a=e.substr(n+7,s-n-7).match(o?CV:QT),i+=e.substr(t,n-t)+GV(o?a:+a[0],o?0:+a[1],+a[2]||1e-5),t=s+1;return i+e.substr(t,e.length-t)},$V=function(e,t,i,n,a){var s=t-e,o=n-i;return ul(a,function(l){return i+((l-e)/s*o||0)})},lse=function r(e,t,i,n){var a=isNaN(e+t)?0:function(f){return(1-f)*e+f*t};if(!a){var s=$r(e),o={},l,u,c,h,d;if(i===!0&&(n=1)&&(i=null),s)e={p:e},t={p:t};else if(oi(e)&&!oi(t)){for(c=[],h=e.length,d=h-2,u=1;u(o=Math.abs(o))&&(l=s,a=o);return l},hn=function(e,t,i){var n=e.vars,a=n[t],s=Xt,o=e._ctx,l,u,c;if(a)return l=n[t+"Params"],u=n.callbackScope||e,i&&Ho.length&&fy(),o&&(Xt=o),c=l?a.apply(u,l):a.call(u),Xt=s,c},Yd=function(e){return Zo(e),e.scrollTrigger&&e.scrollTrigger.kill(!!si),e.progress()<1&&hn(e,"onInterrupt"),e},vh,WV=[],qV=function(e){if(e)if(e=!e.name&&e.default||e,TA()||e.headless){var t=e.name,i=or(e),n=t&&!i&&e.init?function(){this._props=[]}:e,a={init:Jp,render:LA,add:EA,kill:wse,modifier:xse,rawVars:0},s={targetTest:0,get:0,getSetter:MA,aliases:{},register:0};if(rf(),e!==n){if(sn[t])return;Xn(n,Xn(dy(e,a),s)),Yu(n.prototype,Yu(a,dy(e,s))),sn[n.prop=t]=n,e.targetTest&&(l0.push(n),CA[t]=1),t=(t==="css"?"CSS":t.charAt(0).toUpperCase()+t.substr(1))+"Plugin"}EV(t,n),e.register&&e.register(Yi,n,ji)}else WV.push(e)},Bt=255,Kd={aqua:[0,Bt,Bt],lime:[0,Bt,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,Bt],navy:[0,0,128],white:[Bt,Bt,Bt],olive:[128,128,0],yellow:[Bt,Bt,0],orange:[Bt,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[Bt,0,0],pink:[Bt,192,203],cyan:[0,Bt,Bt],transparent:[Bt,Bt,Bt,0]},L2=function(e,t,i){return e+=e<0?1:e>1?-1:0,(e*6<1?t+(i-t)*e*6:e<.5?i:e*3<2?t+(i-t)*(2/3-e)*6:t)*Bt+.5|0},jV=function(e,t,i){var n=e?Gs(e)?[e>>16,e>>8&Bt,e&Bt]:0:Kd.black,a,s,o,l,u,c,h,d,f,p;if(!n){if(e.substr(-1)===","&&(e=e.substr(0,e.length-1)),Kd[e])n=Kd[e];else if(e.charAt(0)==="#"){if(e.length<6&&(a=e.charAt(1),s=e.charAt(2),o=e.charAt(3),e="#"+a+a+s+s+o+o+(e.length===5?e.charAt(4)+e.charAt(4):"")),e.length===9)return n=parseInt(e.substr(1,6),16),[n>>16,n>>8&Bt,n&Bt,parseInt(e.substr(7),16)/255];e=parseInt(e.substr(1),16),n=[e>>16,e>>8&Bt,e&Bt]}else if(e.substr(0,3)==="hsl"){if(n=p=e.match(QT),!t)l=+n[0]%360/360,u=+n[1]/100,c=+n[2]/100,s=c<=.5?c*(u+1):c+u-c*u,a=c*2-s,n.length>3&&(n[3]*=1),n[0]=L2(l+1/3,a,s),n[1]=L2(l,a,s),n[2]=L2(l-1/3,a,s);else if(~e.indexOf("="))return n=e.match(xV),i&&n.length<4&&(n[3]=1),n}else n=e.match(QT)||Kd.transparent;n=n.map(Number)}return t&&!p&&(a=n[0]/Bt,s=n[1]/Bt,o=n[2]/Bt,h=Math.max(a,s,o),d=Math.min(a,s,o),c=(h+d)/2,h===d?l=u=0:(f=h-d,u=c>.5?f/(2-h-d):f/(h+d),l=h===a?(s-o)/f+(se||m<0)&&(i+=m-t),n+=m,T=n-i,_=T-s,(_>0||y)&&(x=++h.frame,d=T-h.time*1e3,h.time=T=T/1e3,s+=_+(_>=a?4:a-_),b=1),y||(l=u(v)),b)for(f=0;f=m&&f--},_listeners:o},h}(),rf=function(){return!tv&&ln.wake()},mt={},cse=/^[\d.\-M][\d.\-,\s]/,hse=/["']/g,fse=function(e){for(var t={},i=e.substr(1,e.length-3).split(":"),n=i[0],a=1,s=i.length,o,l,u;a1&&i.config?i.config.apply(null,~e.indexOf("{")?[fse(t[1])]:dse(e).split(",").map(LV)):mt._CE&&cse.test(e)?mt._CE("",e):i},KV=function(e){return function(t){return 1-e(1-t)}},ZV=function r(e,t){for(var i=e._first,n;i;)i instanceof Ti?r(i,t):i.vars.yoyoEase&&(!i._yoyo||!i._repeat)&&i._yoyo!==t&&(i.timeline?r(i.timeline,t):(n=i._ease,i._ease=i._yEase,i._yEase=n,i._yoyo=t)),i=i._next},ku=function(e,t){return e&&(or(e)?e:mt[e]||pse(e))||t},oc=function(e,t,i,n){i===void 0&&(i=function(l){return 1-t(1-l)}),n===void 0&&(n=function(l){return l<.5?t(l*2)/2:1-t((1-l)*2)/2});var a={easeIn:t,easeOut:i,easeInOut:n},s;return qi(e,function(o){mt[o]=bn[o]=a,mt[s=o.toLowerCase()]=i;for(var l in a)mt[s+(l==="easeIn"?".in":l==="easeOut"?".out":".inOut")]=mt[o+"."+l]=a[l]}),a},QV=function(e){return function(t){return t<.5?(1-e(1-t*2))/2:.5+e((t-.5)*2)/2}},k2=function r(e,t,i){var n=t>=1?t:1,a=(i||(e?.3:.45))/(t<1?t:1),s=a/ZT*(Math.asin(1/n)||0),o=function(c){return c===1?1:n*Math.pow(2,-10*c)*Gae((c-s)*a)+1},l=e==="out"?o:e==="in"?function(u){return 1-o(1-u)}:QV(o);return a=ZT/a,l.config=function(u,c){return r(e,u,c)},l},R2=function r(e,t){t===void 0&&(t=1.70158);var i=function(s){return s?--s*s*((t+1)*s+t)+1:0},n=e==="out"?i:e==="in"?function(a){return 1-i(1-a)}:QV(i);return n.config=function(a){return r(e,a)},n};qi("Linear,Quad,Cubic,Quart,Quint,Strong",function(r,e){var t=e<5?e+1:e;oc(r+",Power"+(t-1),e?function(i){return Math.pow(i,t)}:function(i){return i},function(i){return 1-Math.pow(1-i,t)},function(i){return i<.5?Math.pow(i*2,t)/2:1-Math.pow((1-i)*2,t)/2})});mt.Linear.easeNone=mt.none=mt.Linear.easeIn;oc("Elastic",k2("in"),k2("out"),k2());(function(r,e){var t=1/e,i=2*t,n=2.5*t,a=function(o){return o0?i+(i+this._rDelay)*this._repeat:i):this.totalDuration()&&this._dur},e.totalDuration=function(i){return arguments.length?(this._dirty=0,tf(this,this._repeat<0?i:(i-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},e.totalTime=function(i,n){if(rf(),!arguments.length)return this._tTime;var a=this._dp;if(a&&a.smoothChildTiming&&this._ts){for(X_(this,i),!a._dp||a.parent||OV(a,this);a&&a.parent;)a.parent._time!==a._start+(a._ts>=0?a._tTime/a._ts:(a.totalDuration()-a._tTime)/-a._ts)&&a.totalTime(a._tTime,!0),a=a.parent;!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&i0||!this._tDur&&!i)&&Ba(this._dp,this,this._start-this._delay)}return(this._tTime!==i||!this._dur&&!n||this._initted&&Math.abs(this._zTime)===Gt||!i&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=i),MV(this,i,n)),this},e.time=function(i,n){return arguments.length?this.totalTime(Math.min(this.totalDuration(),i+G4(this))%(this._dur+this._rDelay)||(i?this._dur:0),n):this._time},e.totalProgress=function(i,n){return arguments.length?this.totalTime(this.totalDuration()*i,n):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.rawTime()>0?1:0},e.progress=function(i,n){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&!(this.iteration()&1)?1-i:i)+G4(this),n):this.duration()?Math.min(1,this._time/this._dur):this.rawTime()>0?1:0},e.iteration=function(i,n){var a=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(i-1)*a,n):this._repeat?ef(this._tTime,a)+1:1},e.timeScale=function(i,n){if(!arguments.length)return this._rts===-Gt?0:this._rts;if(this._rts===i)return this;var a=this.parent&&this._ts?py(this.parent._time,this):this._tTime;return this._rts=+i||0,this._ts=this._ps||i===-Gt?0:this._rts,this.totalTime(Xv(-Math.abs(this._delay),this._tDur,a),n!==!1),j_(this),Yae(this)},e.paused=function(i){return arguments.length?(this._ps!==i&&(this._ps=i,i?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(rf(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,this.progress()===1&&Math.abs(this._zTime)!==Gt&&(this._tTime-=Gt)))),this):this._ps},e.startTime=function(i){if(arguments.length){this._start=i;var n=this.parent||this._dp;return n&&(n._sort||!this.parent)&&Ba(n,this,i-this._delay),this}return this._start},e.endTime=function(i){return this._start+(Wi(i)?this.totalDuration():this.duration())/Math.abs(this._ts||1)},e.rawTime=function(i){var n=this.parent||this._dp;return n?i&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):this._ts?py(n.rawTime(i),this):this._tTime:this._tTime},e.revert=function(i){i===void 0&&(i=Wae);var n=si;return si=i,(this._initted||this._startAt)&&(this.timeline&&this.timeline.revert(i),this.totalTime(-.01,i.suppressEvents)),this.data!=="nested"&&i.kill!==!1&&this.kill(),si=n,this},e.globalTime=function(i){for(var n=this,a=arguments.length?i:n.rawTime();n;)a=n._start+a/(Math.abs(n._ts)||1),n=n._dp;return!this.parent&&this._sat?this._sat.globalTime(i):a},e.repeat=function(i){return arguments.length?(this._repeat=i===1/0?-2:i,H4(this)):this._repeat===-2?1/0:this._repeat},e.repeatDelay=function(i){if(arguments.length){var n=this._time;return this._rDelay=i,H4(this),n?this.time(n):this}return this._rDelay},e.yoyo=function(i){return arguments.length?(this._yoyo=i,this):this._yoyo},e.seek=function(i,n){return this.totalTime(Mn(this,i),Wi(n))},e.restart=function(i,n){return this.play().totalTime(i?-this._delay:0,Wi(n))},e.play=function(i,n){return i!=null&&this.seek(i,n),this.reversed(!1).paused(!1)},e.reverse=function(i,n){return i!=null&&this.seek(i||this.totalDuration(),n),this.reversed(!0).paused(!1)},e.pause=function(i,n){return i!=null&&this.seek(i,n),this.paused(!0)},e.resume=function(){return this.paused(!1)},e.reversed=function(i){return arguments.length?(!!i!==this.reversed()&&this.timeScale(-this._rts||(i?-Gt:0)),this):this._rts<0},e.invalidate=function(){return this._initted=this._act=0,this._zTime=-Gt,this},e.isActive=function(){var i=this.parent||this._dp,n=this._start,a;return!!(!i||this._ts&&this._initted&&i.isActive()&&(a=i.rawTime(!0))>=n&&a1?(n?(s[i]=n,a&&(s[i+"Params"]=a),i==="onUpdate"&&(this._onUpdate=n)):delete s[i],this):s[i]},e.then=function(i){var n=this;return new Promise(function(a){var s=or(i)?i:kV,o=function(){var u=n.then;n.then=null,or(s)&&(s=s(n))&&(s.then||s===n)&&(n.then=u),a(s),n.then=u};n._initted&&n.totalProgress()===1&&n._ts>=0||!n._tTime&&n._ts<0?o():n._prom=o})},e.kill=function(){Yd(this)},r}();Xn(rv.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:!1,parent:null,_initted:!1,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-Gt,_prom:0,_ps:!1,_rts:1});var Ti=function(r){bV(e,r);function e(i,n){var a;return i===void 0&&(i={}),a=r.call(this,i)||this,a.labels={},a.smoothChildTiming=!!i.smoothChildTiming,a.autoRemoveChildren=!!i.autoRemoveChildren,a._sort=Wi(i.sortChildren),Zt&&Ba(i.parent||Zt,bs(a),n),i.reversed&&a.reverse(),i.paused&&a.paused(!0),i.scrollTrigger&&NV(bs(a),i.scrollTrigger),a}var t=e.prototype;return t.to=function(n,a,s){return Tp(0,arguments,this),this},t.from=function(n,a,s){return Tp(1,arguments,this),this},t.fromTo=function(n,a,s,o){return Tp(2,arguments,this),this},t.set=function(n,a,s){return a.duration=0,a.parent=this,Sp(a).repeatDelay||(a.repeat=0),a.immediateRender=!!a.immediateRender,new xr(n,a,Mn(this,s),1),this},t.call=function(n,a,s){return Ba(this,xr.delayedCall(0,n,a),s)},t.staggerTo=function(n,a,s,o,l,u,c){return s.duration=a,s.stagger=s.stagger||o,s.onComplete=u,s.onCompleteParams=c,s.parent=this,new xr(n,s,Mn(this,l)),this},t.staggerFrom=function(n,a,s,o,l,u,c){return s.runBackwards=1,Sp(s).immediateRender=Wi(s.immediateRender),this.staggerTo(n,a,s,o,l,u,c)},t.staggerFromTo=function(n,a,s,o,l,u,c,h){return o.startAt=s,Sp(o).immediateRender=Wi(o.immediateRender),this.staggerTo(n,a,o,l,u,c,h)},t.render=function(n,a,s){var o=this._time,l=this._dirty?this.totalDuration():this._tDur,u=this._dur,c=n<=0?0:Vr(n),h=this._zTime<0!=n<0&&(this._initted||!u),d,f,p,v,g,m,y,_,b,T,x,C;if(this!==Zt&&c>l&&n>=0&&(c=l),c!==this._tTime||s||h){if(o!==this._time&&u&&(c+=this._time-o,n+=this._time-o),d=c,b=this._start,_=this._ts,m=!_,h&&(u||(o=this._zTime),(n||!a)&&(this._zTime=n)),this._repeat){if(x=this._yoyo,g=u+this._rDelay,this._repeat<-1&&n<0)return this.totalTime(g*100+n,a,s);if(d=Vr(c%g),c===l?(v=this._repeat,d=u):(v=~~(c/g),v&&v===c/g&&(d=u,v--),d>u&&(d=u)),T=ef(this._tTime,g),!o&&this._tTime&&T!==v&&this._tTime-T*g-this._dur<=0&&(T=v),x&&v&1&&(d=u-d,C=1),v!==T&&!this._lock){var D=x&&T&1,I=D===(x&&v&1);if(v=o&&n>=0)for(f=this._first;f;){if(p=f._next,(f._act||d>=f._start)&&f._ts&&y!==f){if(f.parent!==this)return this.render(n,a,s);if(f.render(f._ts>0?(d-f._start)*f._ts:(f._dirty?f.totalDuration():f._tDur)+(d-f._start)*f._ts,a,s),d!==this._time||!this._ts&&!m){y=0,p&&(c+=this._zTime=-Gt);break}}f=p}else{f=this._last;for(var M=n<0?n:d;f;){if(p=f._prev,(f._act||M<=f._end)&&f._ts&&y!==f){if(f.parent!==this)return this.render(n,a,s);if(f.render(f._ts>0?(M-f._start)*f._ts:(f._dirty?f.totalDuration():f._tDur)+(M-f._start)*f._ts,a,s||si&&(f._initted||f._startAt)),d!==this._time||!this._ts&&!m){y=0,p&&(c+=this._zTime=M?-Gt:Gt);break}}f=p}}if(y&&!a&&(this.pause(),y.render(d>=o?0:-Gt)._zTime=d>=o?1:-1,this._ts))return this._start=b,j_(this),this.render(n,a,s);this._onUpdate&&!a&&hn(this,"onUpdate",!0),(c===l&&this._tTime>=this.totalDuration()||!c&&o)&&(b===this._start||Math.abs(_)!==Math.abs(this._ts))&&(this._lock||((n||!u)&&(c===l&&this._ts>0||!c&&this._ts<0)&&Zo(this,1),!a&&!(n<0&&!o)&&(c||o||!l)&&(hn(this,c===l&&n>=0?"onComplete":"onReverseComplete",!0),this._prom&&!(c0)&&this._prom())))}return this},t.add=function(n,a){var s=this;if(Gs(a)||(a=Mn(this,a,n)),!(n instanceof rv)){if(oi(n))return n.forEach(function(o){return s.add(o,a)}),this;if($r(n))return this.addLabel(n,a);if(or(n))n=xr.delayedCall(0,n);else return this}return this!==n?Ba(this,n,a):this},t.getChildren=function(n,a,s,o){n===void 0&&(n=!0),a===void 0&&(a=!0),s===void 0&&(s=!0),o===void 0&&(o=-Vn);for(var l=[],u=this._first;u;)u._start>=o&&(u instanceof xr?a&&l.push(u):(s&&l.push(u),n&&l.push.apply(l,u.getChildren(!0,a,s)))),u=u._next;return l},t.getById=function(n){for(var a=this.getChildren(1,1,1),s=a.length;s--;)if(a[s].vars.id===n)return a[s]},t.remove=function(n){return $r(n)?this.removeLabel(n):or(n)?this.killTweensOf(n):(q_(this,n),n===this._recent&&(this._recent=this._last),Lu(this))},t.totalTime=function(n,a){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=Vr(ln.time-(this._ts>0?n/this._ts:(this.totalDuration()-n)/-this._ts))),r.prototype.totalTime.call(this,n,a),this._forcing=0,this):this._tTime},t.addLabel=function(n,a){return this.labels[n]=Mn(this,a),this},t.removeLabel=function(n){return delete this.labels[n],this},t.addPause=function(n,a,s){var o=xr.delayedCall(0,a||Jp,s);return o.data="isPause",this._hasPause=1,Ba(this,o,Mn(this,n))},t.removePause=function(n){var a=this._first;for(n=Mn(this,n);a;)a._start===n&&a.data==="isPause"&&Zo(a),a=a._next},t.killTweensOf=function(n,a,s){for(var o=this.getTweensOf(n,s),l=o.length;l--;)Po!==o[l]&&o[l].kill(n,a);return this},t.getTweensOf=function(n,a){for(var s=[],o=zn(n),l=this._first,u=Gs(a),c;l;)l instanceof xr?qae(l._targets,o)&&(u?(!Po||l._initted&&l._ts)&&l.globalTime(0)<=a&&l.globalTime(l.totalDuration())>a:!a||l.isActive())&&s.push(l):(c=l.getTweensOf(o,a)).length&&s.push.apply(s,c),l=l._next;return s},t.tweenTo=function(n,a){a=a||{};var s=this,o=Mn(s,n),l=a,u=l.startAt,c=l.onStart,h=l.onStartParams,d=l.immediateRender,f,p=xr.to(s,Xn({ease:a.ease||"none",lazy:!1,immediateRender:!1,time:o,overwrite:"auto",duration:a.duration||Math.abs((o-(u&&"time"in u?u.time:s._time))/s.timeScale())||Gt,onStart:function(){if(s.pause(),!f){var g=a.duration||Math.abs((o-(u&&"time"in u?u.time:s._time))/s.timeScale());p._dur!==g&&tf(p,g,0,1).render(p._time,!0,!0),f=1}c&&c.apply(p,h||[])}},a));return d?p.render(0):p},t.tweenFromTo=function(n,a,s){return this.tweenTo(a,Xn({startAt:{time:Mn(this,n)}},s))},t.recent=function(){return this._recent},t.nextLabel=function(n){return n===void 0&&(n=this._time),$4(this,Mn(this,n))},t.previousLabel=function(n){return n===void 0&&(n=this._time),$4(this,Mn(this,n),1)},t.currentLabel=function(n){return arguments.length?this.seek(n,!0):this.previousLabel(this._time+Gt)},t.shiftChildren=function(n,a,s){s===void 0&&(s=0);for(var o=this._first,l=this.labels,u;o;)o._start>=s&&(o._start+=n,o._end+=n),o=o._next;if(a)for(u in l)l[u]>=s&&(l[u]+=n);return Lu(this)},t.invalidate=function(n){var a=this._first;for(this._lock=0;a;)a.invalidate(n),a=a._next;return r.prototype.invalidate.call(this,n)},t.clear=function(n){n===void 0&&(n=!0);for(var a=this._first,s;a;)s=a._next,this.remove(a),a=s;return this._dp&&(this._time=this._tTime=this._pTime=0),n&&(this.labels={}),Lu(this)},t.totalDuration=function(n){var a=0,s=this,o=s._last,l=Vn,u,c,h;if(arguments.length)return s.timeScale((s._repeat<0?s.duration():s.totalDuration())/(s.reversed()?-n:n));if(s._dirty){for(h=s.parent;o;)u=o._prev,o._dirty&&o.totalDuration(),c=o._start,c>l&&s._sort&&o._ts&&!s._lock?(s._lock=1,Ba(s,o,c-o._delay,1)._lock=0):l=c,c<0&&o._ts&&(a-=c,(!h&&!s._dp||h&&h.smoothChildTiming)&&(s._start+=c/s._ts,s._time-=c,s._tTime-=c),s.shiftChildren(-c,!1,-1/0),l=0),o._end>a&&o._ts&&(a=o._end),o=u;tf(s,s===Zt&&s._time>a?s._time:a,1,1),s._dirty=0}return s._tDur},e.updateRoot=function(n){if(Zt._ts&&(MV(Zt,py(n,Zt)),IV=ln.frame),ln.frame>=V4){V4+=pn.autoSleep||120;var a=Zt._first;if((!a||!a._ts)&&pn.autoSleep&&ln._listeners.length<2){for(;a&&!a._ts;)a=a._next;a||ln.sleep()}}},e}(rv);Xn(Ti.prototype,{_lock:0,_hasPause:0,_forcing:0});var vse=function(e,t,i,n,a,s,o){var l=new ji(this._pt,e,t,0,1,az,null,a),u=0,c=0,h,d,f,p,v,g,m,y;for(l.b=i,l.e=n,i+="",n+="",(m=~n.indexOf("random("))&&(n=ev(n)),s&&(y=[i,n],s(y,e,t),i=y[0],n=y[1]),d=i.match(P2)||[];h=P2.exec(n);)p=h[0],v=n.substring(u,h.index),f?f=(f+1)%5:v.substr(-5)==="rgba("&&(f=1),p!==d[c++]&&(g=parseFloat(d[c-1])||0,l._pt={_next:l._pt,p:v||c===1?v:",",s:g,c:p.charAt(1)==="="?Dh(g,p)-g:parseFloat(p)-g,m:f&&f<4?Math.round:0},u=P2.lastIndex);return l.c=u")}),b.duration();else{x={};for(D in p)D==="ease"||D==="easeEach"||_se(D,p[D],x,p.easeEach);for(D in x)for(O=x[D].sort(function(U,$){return U.t-$.t}),N=0,T=0;Tl-Gt&&!c?l:nu&&(d=u)),m=this._yoyo&&p&1,m&&(b=this._yEase,d=u-d),g=ef(this._tTime,v),d===o&&!s&&this._initted&&p===g)return this._tTime=h,this;p!==g&&(_&&this._yEase&&ZV(_,m),this.vars.repeatRefresh&&!m&&!this._lock&&this._time!==v&&this._initted&&(this._lock=s=1,this.render(Vr(v*p),!0).invalidate()._lock=0))}if(!this._initted){if(BV(this,c?n:d,s,a,h))return this._tTime=0,this;if(o!==this._time&&!(s&&this.vars.repeatRefresh&&p!==g))return this;if(u!==this._dur)return this.render(n,a,s)}if(this._tTime=h,this._time=d,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=y=(b||this._ease)(d/u),this._from&&(this.ratio=y=1-y),d&&!o&&!a&&!p&&(hn(this,"onStart"),this._tTime!==h))return this;for(f=this._pt;f;)f.r(y,f.d),f=f._next;_&&_.render(n<0?n:_._dur*_._ease(d/this._dur),a,s)||this._startAt&&(this._zTime=n),this._onUpdate&&!a&&(c&&tx(this,n,a,s),hn(this,"onUpdate")),this._repeat&&p!==g&&this.vars.onRepeat&&!a&&this.parent&&hn(this,"onRepeat"),(h===this._tDur||!h)&&this._tTime===h&&(c&&!this._onUpdate&&tx(this,n,!0,!0),(n||!u)&&(h===this._tDur&&this._ts>0||!h&&this._ts<0)&&Zo(this,1),!a&&!(c&&!o)&&(h||o||m)&&(hn(this,h===l?"onComplete":"onReverseComplete",!0),this._prom&&!(h0)&&this._prom()))}return this},t.targets=function(){return this._targets},t.invalidate=function(n){return(!n||!this.vars.runBackwards)&&(this._startAt=0),this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(n),r.prototype.invalidate.call(this,n)},t.resetTo=function(n,a,s,o,l){tv||ln.wake(),this._ts||this.play();var u=Math.min(this._dur,(this._dp._time-this._start)*this._ts),c;return this._initted||IA(this,u),c=this._ease(u/this._dur),mse(this,n,a,s,o,c,u,l)?this.resetTo(n,a,s,o,1):(X_(this,0),this.parent||RV(this._dp,this,"_first","_last",this._dp._sort?"_start":0),this.render(0))},t.kill=function(n,a){if(a===void 0&&(a="all"),!n&&(!a||a==="all"))return this._lazy=this._pt=0,this.parent?Yd(this):this;if(this.timeline){var s=this.timeline.totalDuration();return this.timeline.killTweensOf(n,a,Po&&Po.vars.overwrite!==!0)._first||Yd(this),this.parent&&s!==this.timeline.totalDuration()&&tf(this,this._dur*this.timeline._tDur/s,0,1),this}var o=this._targets,l=n?zn(n):o,u=this._ptLookup,c=this._pt,h,d,f,p,v,g,m;if((!a||a==="all")&&Xae(o,l))return a==="all"&&(this._pt=0),Yd(this);for(h=this._op=this._op||[],a!=="all"&&($r(a)&&(v={},qi(a,function(y){return v[y]=1}),a=v),a=yse(o,a)),m=o.length;m--;)if(~l.indexOf(o[m])){d=u[m],a==="all"?(h[m]=a,p=d,f={}):(f=h[m]=h[m]||{},p=a);for(v in p)g=d&&d[v],g&&((!("kill"in g.d)||g.d.kill(v)===!0)&&q_(this,g,"_pt"),delete d[v]),f!=="all"&&(f[v]=1)}return this._initted&&!this._pt&&c&&Yd(this),this},e.to=function(n,a){return new e(n,a,arguments[2])},e.from=function(n,a){return Tp(1,arguments)},e.delayedCall=function(n,a,s,o){return new e(a,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:n,onComplete:a,onReverseComplete:a,onCompleteParams:s,onReverseCompleteParams:s,callbackScope:o})},e.fromTo=function(n,a,s){return Tp(2,arguments)},e.set=function(n,a){return a.duration=0,a.repeatDelay||(a.repeat=0),new e(n,a)},e.killTweensOf=function(n,a,s){return Zt.killTweensOf(n,a,s)},e}(rv);Xn(xr.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0});qi("staggerTo,staggerFrom,staggerFromTo",function(r){xr[r]=function(){var e=new Ti,t=ix.call(arguments,0);return t.splice(r==="staggerFromTo"?5:4,0,0),e[r].apply(e,t)}});var PA=function(e,t,i){return e[t]=i},iz=function(e,t,i){return e[t](i)},bse=function(e,t,i,n){return e[t](n.fp,i)},Sse=function(e,t,i){return e.setAttribute(t,i)},MA=function(e,t){return or(e[t])?iz:SA(e[t])&&e.setAttribute?Sse:PA},nz=function(e,t){return t.set(t.t,t.p,Math.round((t.s+t.c*e)*1e6)/1e6,t)},Tse=function(e,t){return t.set(t.t,t.p,!!(t.s+t.c*e),t)},az=function(e,t){var i=t._pt,n="";if(!e&&t.b)n=t.b;else if(e===1&&t.e)n=t.e;else{for(;i;)n=i.p+(i.m?i.m(i.s+i.c*e):Math.round((i.s+i.c*e)*1e4)/1e4)+n,i=i._next;n+=t.c}t.set(t.t,t.p,n,t)},LA=function(e,t){for(var i=t._pt;i;)i.r(e,i.d),i=i._next},xse=function(e,t,i,n){for(var a=this._pt,s;a;)s=a._next,a.p===n&&a.modifier(e,t,i),a=s},wse=function(e){for(var t=this._pt,i,n;t;)n=t._next,t.p===e&&!t.op||t.op===e?q_(this,t,"_pt"):t.dep||(i=1),t=n;return!i},Cse=function(e,t,i,n){n.mSet(e,t,n.m.call(n.tween,i,n.mt),n)},sz=function(e){for(var t=e._pt,i,n,a,s;t;){for(i=t._next,n=a;n&&n.pr>t.pr;)n=n._next;(t._prev=n?n._prev:s)?t._prev._next=t:a=t,(t._next=n)?n._prev=t:s=t,t=i}e._pt=a},ji=function(){function r(t,i,n,a,s,o,l,u,c){this.t=i,this.s=a,this.c=s,this.p=n,this.r=o||nz,this.d=l||this,this.set=u||PA,this.pr=c||0,this._next=t,t&&(t._prev=this)}var e=r.prototype;return e.modifier=function(i,n,a){this.mSet=this.mSet||this.set,this.set=Cse,this.m=i,this.mt=a,this.tween=n},r}();qi(AA+"parent,duration,ease,delay,overwrite,runBackwards,startAt,yoyo,immediateRender,repeat,repeatDelay,data,paused,reversed,lazy,callbackScope,stringFilter,id,yoyoEase,stagger,inherit,repeatRefresh,keyframes,autoRevert,scrollTrigger",function(r){return CA[r]=1});bn.TweenMax=bn.TweenLite=xr;bn.TimelineLite=bn.TimelineMax=Ti;Zt=new Ti({sortChildren:!1,defaults:Jh,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0});pn.stringFilter=YV;var Ru=[],u0={},Ase=[],q4=0,Dse=0,O2=function(e){return(u0[e]||Ase).map(function(t){return t()})},ox=function(){var e=Date.now(),t=[];e-q4>2&&(O2("matchMediaInit"),Ru.forEach(function(i){var n=i.queries,a=i.conditions,s,o,l,u;for(o in n)s=Ra.matchMedia(n[o]).matches,s&&(l=1),s!==a[o]&&(a[o]=s,u=1);u&&(i.revert(),l&&t.push(i))}),O2("matchMediaRevert"),t.forEach(function(i){return i.onMatch(i,function(n){return i.add(null,n)})}),q4=e,O2("matchMedia"))},oz=function(){function r(t,i){this.selector=i&&nx(i),this.data=[],this._r=[],this.isReverted=!1,this.id=Dse++,t&&this.add(t)}var e=r.prototype;return e.add=function(i,n,a){or(i)&&(a=n,n=i,i=or);var s=this,o=function(){var u=Xt,c=s.selector,h;return u&&u!==s&&u.data.push(s),a&&(s.selector=nx(a)),Xt=s,h=n.apply(s,arguments),or(h)&&s._r.push(h),Xt=u,s.selector=c,s.isReverted=!1,h};return s.last=o,i===or?o(s,function(l){return s.add(null,l)}):i?s[i]=o:o},e.ignore=function(i){var n=Xt;Xt=null,i(this),Xt=n},e.getTweens=function(){var i=[];return this.data.forEach(function(n){return n instanceof r?i.push.apply(i,n.getTweens()):n instanceof xr&&!(n.parent&&n.parent.data==="nested")&&i.push(n)}),i},e.clear=function(){this._r.length=this.data.length=0},e.kill=function(i,n){var a=this;if(i?function(){for(var o=a.getTweens(),l=a.data.length,u;l--;)u=a.data[l],u.data==="isFlip"&&(u.revert(),u.getChildren(!0,!0,!1).forEach(function(c){return o.splice(o.indexOf(c),1)}));for(o.map(function(c){return{g:c._dur||c._delay||c._sat&&!c._sat.vars.immediateRender?c.globalTime(0):-1/0,t:c}}).sort(function(c,h){return h.g-c.g||-1/0}).forEach(function(c){return c.t.revert(i)}),l=a.data.length;l--;)u=a.data[l],u instanceof Ti?u.data!=="nested"&&(u.scrollTrigger&&u.scrollTrigger.revert(),u.kill()):!(u instanceof xr)&&u.revert&&u.revert(i);a._r.forEach(function(c){return c(i,a)}),a.isReverted=!0}():this.data.forEach(function(o){return o.kill&&o.kill()}),this.clear(),n)for(var s=Ru.length;s--;)Ru[s].id===this.id&&Ru.splice(s,1)},e.revert=function(i){this.kill(i||{})},r}(),Ese=function(){function r(t){this.contexts=[],this.scope=t,Xt&&Xt.data.push(this)}var e=r.prototype;return e.add=function(i,n,a){ns(i)||(i={matches:i});var s=new oz(0,a||this.scope),o=s.conditions={},l,u,c;Xt&&!s.selector&&(s.selector=Xt.selector),this.contexts.push(s),n=s.add("onMatch",n),s.queries=i;for(u in i)u==="all"?c=1:(l=Ra.matchMedia(i[u]),l&&(Ru.indexOf(s)<0&&Ru.push(s),(o[u]=l.matches)&&(c=1),l.addListener?l.addListener(ox):l.addEventListener("change",ox)));return c&&n(s,function(h){return s.add(null,h)}),this},e.revert=function(i){this.kill(i||{})},e.kill=function(i){this.contexts.forEach(function(n){return n.kill(i,!0)})},r}(),vy={registerPlugin:function(){for(var e=arguments.length,t=new Array(e),i=0;i1){var n=e.map(function(c){return Yi.quickSetter(c,t,i)}),a=n.length;return function(c){for(var h=a;h--;)n[h](c)}}e=e[0]||{};var s=sn[t],o=Mu(e),l=o.harness&&(o.harness.aliases||{})[t]||t,u=s?function(c){var h=new s;vh._pt=0,h.init(e,i?c+i:c,vh,0,[e]),h.render(1,h),vh._pt&&LA(1,vh)}:o.set(e,l);return s?u:function(c){return u(e,l,i?c+i:c,o,1)}},quickTo:function(e,t,i){var n,a=Yi.to(e,Yu((n={},n[t]="+=0.1",n.paused=!0,n),i||{})),s=function(l,u,c){return a.resetTo(t,l,u,c)};return s.tween=a,s},isTweening:function(e){return Zt.getTweensOf(e,!0).length>0},defaults:function(e){return e&&e.ease&&(e.ease=ku(e.ease,Jh.ease)),z4(Jh,e||{})},config:function(e){return z4(pn,e||{})},registerEffect:function(e){var t=e.name,i=e.effect,n=e.plugins,a=e.defaults,s=e.extendTimeline;(n||"").split(",").forEach(function(o){return o&&!sn[o]&&!bn[o]&&Qp(t+" effect requires "+o+" plugin.")}),M2[t]=function(o,l,u){return i(zn(o),Xn(l||{},a),u)},s&&(Ti.prototype[t]=function(o,l,u){return this.add(M2[t](o,ns(l)?l:(u=l)&&{},this),u)})},registerEase:function(e,t){mt[e]=ku(t)},parseEase:function(e,t){return arguments.length?ku(e,t):mt},getById:function(e){return Zt.getById(e)},exportRoot:function(e,t){e===void 0&&(e={});var i=new Ti(e),n,a;for(i.smoothChildTiming=Wi(e.smoothChildTiming),Zt.remove(i),i._dp=0,i._time=i._tTime=Zt._time,n=Zt._first;n;)a=n._next,(t||!(!n._dur&&n instanceof xr&&n.vars.onComplete===n._targets[0]))&&Ba(i,n,n._start-n._delay),n=a;return Ba(Zt,i,0),i},context:function(e,t){return e?new oz(e,t):Xt},matchMedia:function(e){return new Ese(e)},matchMediaRefresh:function(){return Ru.forEach(function(e){var t=e.conditions,i,n;for(n in t)t[n]&&(t[n]=!1,i=1);i&&e.revert()})||ox()},addEventListener:function(e,t){var i=u0[e]||(u0[e]=[]);~i.indexOf(t)||i.push(t)},removeEventListener:function(e,t){var i=u0[e],n=i&&i.indexOf(t);n>=0&&i.splice(n,1)},utils:{wrap:sse,wrapYoyo:ose,distribute:VV,random:GV,snap:zV,normalize:ase,getUnit:ii,clamp:tse,splitColor:jV,toArray:zn,selector:nx,mapRange:$V,pipe:ise,unitize:nse,interpolate:lse,shuffle:UV},install:DV,effects:M2,ticker:ln,updateRoot:Ti.updateRoot,plugins:sn,globalTimeline:Zt,core:{PropTween:ji,globals:EV,Tween:xr,Timeline:Ti,Animation:rv,getCache:Mu,_removeLinkedListItem:q_,reverting:function(){return si},context:function(e){return e&&Xt&&(Xt.data.push(e),e._ctx=Xt),Xt},suppressOverwrites:function(e){return bA=e}}};qi("to,from,fromTo,delayedCall,set,killTweensOf",function(r){return vy[r]=xr[r]});ln.add(Ti.updateRoot);vh=vy.to({},{duration:0});var Ise=function(e,t){for(var i=e._pt;i&&i.p!==t&&i.op!==t&&i.fp!==t;)i=i._next;return i},Pse=function(e,t){var i=e._targets,n,a,s;for(n in t)for(a=i.length;a--;)s=e._ptLookup[a][n],s&&(s=s.d)&&(s._pt&&(s=Ise(s,n)),s&&s.modifier&&s.modifier(t[n],e,i[a],n))},N2=function(e,t){return{name:e,rawVars:1,init:function(n,a,s){s._onInit=function(o){var l,u;if($r(a)&&(l={},qi(a,function(c){return l[c]=1}),a=l),t){l={};for(u in a)l[u]=t(a[u]);a=l}Pse(o,a)}}}},Yi=vy.registerPlugin({name:"attr",init:function(e,t,i,n,a){var s,o,l;this.tween=i;for(s in t)l=e.getAttribute(s)||"",o=this.add(e,"setAttribute",(l||0)+"",t[s],n,a,0,0,s),o.op=s,o.b=l,this._props.push(s)},render:function(e,t){for(var i=t._pt;i;)si?i.set(i.t,i.p,i.b,i):i.r(e,i.d),i=i._next}},{name:"endArray",init:function(e,t){for(var i=t.length;i--;)this.add(e,i,e[i]||0,t[i],0,0,0,0,0,1)}},N2("roundProps",ax),N2("modifiers"),N2("snap",zV))||vy;xr.version=Ti.version=Yi.version="3.12.5";AV=1;TA()&&rf();mt.Power0;mt.Power1;mt.Power2;mt.Power3;mt.Power4;mt.Linear;mt.Quad;mt.Cubic;mt.Quart;mt.Quint;mt.Strong;mt.Elastic;mt.Back;mt.SteppedEase;mt.Bounce;mt.Sine;mt.Expo;mt.Circ;/*! + * CSSPlugin 3.12.5 + * https://gsap.com + * + * Copyright 2008-2024, GreenSock. All rights reserved. + * Subject to the terms at https://gsap.com/standard-license or for + * Club GSAP members, the agreement issued with that membership. + * @author: Jack Doyle, jack@greensock.com +*/var j4,Mo,Eh,kA,vu,X4,RA,Mse=function(){return typeof window<"u"},Hs={},Ql=180/Math.PI,Ih=Math.PI/180,Lc=Math.atan2,Y4=1e8,OA=/([A-Z])/g,Lse=/(left|right|width|margin|padding|x)/i,kse=/[\s,\(]\S/,$a={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},lx=function(e,t){return t.set(t.t,t.p,Math.round((t.s+t.c*e)*1e4)/1e4+t.u,t)},Rse=function(e,t){return t.set(t.t,t.p,e===1?t.e:Math.round((t.s+t.c*e)*1e4)/1e4+t.u,t)},Ose=function(e,t){return t.set(t.t,t.p,e?Math.round((t.s+t.c*e)*1e4)/1e4+t.u:t.b,t)},Nse=function(e,t){var i=t.s+t.c*e;t.set(t.t,t.p,~~(i+(i<0?-.5:.5))+t.u,t)},lz=function(e,t){return t.set(t.t,t.p,e?t.e:t.b,t)},uz=function(e,t){return t.set(t.t,t.p,e!==1?t.b:t.e,t)},Bse=function(e,t,i){return e.style[t]=i},Fse=function(e,t,i){return e.style.setProperty(t,i)},Use=function(e,t,i){return e._gsap[t]=i},Vse=function(e,t,i){return e._gsap.scaleX=e._gsap.scaleY=i},zse=function(e,t,i,n,a){var s=e._gsap;s.scaleX=s.scaleY=i,s.renderTransform(a,s)},Gse=function(e,t,i,n,a){var s=e._gsap;s[t]=i,s.renderTransform(a,s)},Qt="transform",Xi=Qt+"Origin",Hse=function r(e,t){var i=this,n=this.target,a=n.style,s=n._gsap;if(e in Hs&&a){if(this.tfm=this.tfm||{},e!=="transform")e=$a[e]||e,~e.indexOf(",")?e.split(",").forEach(function(o){return i.tfm[o]=xs(n,o)}):this.tfm[e]=s.x?s[e]:xs(n,e),e===Xi&&(this.tfm.zOrigin=s.zOrigin);else return $a.transform.split(",").forEach(function(o){return r.call(i,o,t)});if(this.props.indexOf(Qt)>=0)return;s.svg&&(this.svgo=n.getAttribute("data-svg-origin"),this.props.push(Xi,t,"")),e=Qt}(a||t)&&this.props.push(e,t,a[e])},cz=function(e){e.translate&&(e.removeProperty("translate"),e.removeProperty("scale"),e.removeProperty("rotate"))},$se=function(){var e=this.props,t=this.target,i=t.style,n=t._gsap,a,s;for(a=0;a=0?K4[s]:"")+e},cx=function(){Mse()&&window.document&&(j4=window,Mo=j4.document,Eh=Mo.documentElement,vu=ux("div")||{style:{}},ux("div"),Qt=nf(Qt),Xi=Qt+"Origin",vu.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",fz=!!nf("perspective"),RA=Yi.core.reverting,kA=1)},B2=function r(e){var t=ux("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),i=this.parentNode,n=this.nextSibling,a=this.style.cssText,s;if(Eh.appendChild(t),t.appendChild(this),this.style.display="block",e)try{s=this.getBBox(),this._gsapBBox=this.getBBox,this.getBBox=r}catch{}else this._gsapBBox&&(s=this._gsapBBox());return i&&(n?i.insertBefore(this,n):i.appendChild(this)),Eh.removeChild(t),this.style.cssText=a,s},Z4=function(e,t){for(var i=t.length;i--;)if(e.hasAttribute(t[i]))return e.getAttribute(t[i])},dz=function(e){var t;try{t=e.getBBox()}catch{t=B2.call(e,!0)}return t&&(t.width||t.height)||e.getBBox===B2||(t=B2.call(e,!0)),t&&!t.width&&!t.x&&!t.y?{x:+Z4(e,["x","cx","x1"])||0,y:+Z4(e,["y","cy","y1"])||0,width:0,height:0}:t},pz=function(e){return!!(e.getCTM&&(!e.parentNode||e.ownerSVGElement)&&dz(e))},Ku=function(e,t){if(t){var i=e.style,n;t in Hs&&t!==Xi&&(t=Qt),i.removeProperty?(n=t.substr(0,2),(n==="ms"||t.substr(0,6)==="webkit")&&(t="-"+t),i.removeProperty(n==="--"?t:t.replace(OA,"-$1").toLowerCase())):i.removeAttribute(t)}},Lo=function(e,t,i,n,a,s){var o=new ji(e._pt,t,i,0,1,s?uz:lz);return e._pt=o,o.b=n,o.e=a,e._props.push(i),o},Q4={deg:1,rad:1,turn:1},Wse={grid:1,flex:1},Qo=function r(e,t,i,n){var a=parseFloat(i)||0,s=(i+"").trim().substr((a+"").length)||"px",o=vu.style,l=Lse.test(t),u=e.tagName.toLowerCase()==="svg",c=(u?"client":"offset")+(l?"Width":"Height"),h=100,d=n==="px",f=n==="%",p,v,g,m;if(n===s||!a||Q4[n]||Q4[s])return a;if(s!=="px"&&!d&&(a=r(e,t,i,"px")),m=e.getCTM&&pz(e),(f||s==="%")&&(Hs[t]||~t.indexOf("adius")))return p=m?e.getBBox()[l?"width":"height"]:e[c],vr(f?a/p*h:a/100*p);if(o[l?"width":"height"]=h+(d?s:n),v=~t.indexOf("adius")||n==="em"&&e.appendChild&&!u?e:e.parentNode,m&&(v=(e.ownerSVGElement||{}).parentNode),(!v||v===Mo||!v.appendChild)&&(v=Mo.body),g=v._gsap,g&&f&&g.width&&l&&g.time===ln.time&&!g.uncache)return vr(a/g.width*h);if(f&&(t==="height"||t==="width")){var y=e.style[t];e.style[t]=h+n,p=e[c],y?e.style[t]=y:Ku(e,t)}else(f||s==="%")&&!Wse[Za(v,"display")]&&(o.position=Za(e,"position")),v===e&&(o.position="static"),v.appendChild(vu),p=vu[c],v.removeChild(vu),o.position="absolute";return l&&f&&(g=Mu(v),g.time=ln.time,g.width=v[c]),vr(d?p*a/h:p&&a?h/p*a:0)},xs=function(e,t,i,n){var a;return kA||cx(),t in $a&&t!=="transform"&&(t=$a[t],~t.indexOf(",")&&(t=t.split(",")[0])),Hs[t]&&t!=="transform"?(a=nv(e,n),a=t!=="transformOrigin"?a[t]:a.svg?a.origin:my(Za(e,Xi))+" "+a.zOrigin+"px"):(a=e.style[t],(!a||a==="auto"||n||~(a+"").indexOf("calc("))&&(a=gy[t]&&gy[t](e,t,i)||Za(e,t)||PV(e,t)||(t==="opacity"?1:0))),i&&!~(a+"").trim().indexOf(" ")?Qo(e,t,a,i)+i:a},qse=function(e,t,i,n){if(!i||i==="none"){var a=nf(t,e,1),s=a&&Za(e,a,1);s&&s!==i?(t=a,i=s):t==="borderColor"&&(i=Za(e,"borderTopColor"))}var o=new ji(this._pt,e.style,t,0,1,az),l=0,u=0,c,h,d,f,p,v,g,m,y,_,b,T;if(o.b=i,o.e=n,i+="",n+="",n==="auto"&&(v=e.style[t],e.style[t]=n,n=Za(e,t)||n,v?e.style[t]=v:Ku(e,t)),c=[i,n],YV(c),i=c[0],n=c[1],d=i.match(ph)||[],T=n.match(ph)||[],T.length){for(;h=ph.exec(n);)g=h[0],y=n.substring(l,h.index),p?p=(p+1)%5:(y.substr(-5)==="rgba("||y.substr(-5)==="hsla(")&&(p=1),g!==(v=d[u++]||"")&&(f=parseFloat(v)||0,b=v.substr((f+"").length),g.charAt(1)==="="&&(g=Dh(f,g)+b),m=parseFloat(g),_=g.substr((m+"").length),l=ph.lastIndex-_.length,_||(_=_||pn.units[t]||b,l===n.length&&(n+=_,o.e+=_)),b!==_&&(f=Qo(e,t,v,_)||0),o._pt={_next:o._pt,p:y||u===1?y:",",s:f,c:m-f,m:p&&p<4||t==="zIndex"?Math.round:0});o.c=l-1;)o=a[u],Hs[o]&&(l=1,o=o==="transformOrigin"?Xi:Qt),Ku(i,o);l&&(Ku(i,Qt),s&&(s.svg&&i.removeAttribute("transform"),nv(i,1),s.uncache=1,cz(n)))}},gy={clearProps:function(e,t,i,n,a){if(a.data!=="isFromStart"){var s=e._pt=new ji(e._pt,t,i,0,0,Xse);return s.u=n,s.pr=-10,s.tween=a,e._props.push(i),1}}},iv=[1,0,0,1,0,0],vz={},gz=function(e){return e==="matrix(1, 0, 0, 1, 0, 0)"||e==="none"||!e},eP=function(e){var t=Za(e,Qt);return gz(t)?iv:t.substr(7).match(xV).map(vr)},NA=function(e,t){var i=e._gsap||Mu(e),n=e.style,a=eP(e),s,o,l,u;return i.svg&&e.getAttribute("transform")?(l=e.transform.baseVal.consolidate().matrix,a=[l.a,l.b,l.c,l.d,l.e,l.f],a.join(",")==="1,0,0,1,0,0"?iv:a):(a===iv&&!e.offsetParent&&e!==Eh&&!i.svg&&(l=n.display,n.display="block",s=e.parentNode,(!s||!e.offsetParent)&&(u=1,o=e.nextElementSibling,Eh.appendChild(e)),a=eP(e),l?n.display=l:Ku(e,"display"),u&&(o?s.insertBefore(e,o):s?s.appendChild(e):Eh.removeChild(e))),t&&a.length>6?[a[0],a[1],a[4],a[5],a[12],a[13]]:a)},hx=function(e,t,i,n,a,s){var o=e._gsap,l=a||NA(e,!0),u=o.xOrigin||0,c=o.yOrigin||0,h=o.xOffset||0,d=o.yOffset||0,f=l[0],p=l[1],v=l[2],g=l[3],m=l[4],y=l[5],_=t.split(" "),b=parseFloat(_[0])||0,T=parseFloat(_[1])||0,x,C,D,I;i?l!==iv&&(C=f*g-p*v)&&(D=b*(g/C)+T*(-v/C)+(v*y-g*m)/C,I=b*(-p/C)+T*(f/C)-(f*y-p*m)/C,b=D,T=I):(x=dz(e),b=x.x+(~_[0].indexOf("%")?b/100*x.width:b),T=x.y+(~(_[1]||_[0]).indexOf("%")?T/100*x.height:T)),n||n!==!1&&o.smooth?(m=b-u,y=T-c,o.xOffset=h+(m*f+y*v)-m,o.yOffset=d+(m*p+y*g)-y):o.xOffset=o.yOffset=0,o.xOrigin=b,o.yOrigin=T,o.smooth=!!n,o.origin=t,o.originIsAbsolute=!!i,e.style[Xi]="0px 0px",s&&(Lo(s,o,"xOrigin",u,b),Lo(s,o,"yOrigin",c,T),Lo(s,o,"xOffset",h,o.xOffset),Lo(s,o,"yOffset",d,o.yOffset)),e.setAttribute("data-svg-origin",b+" "+T)},nv=function(e,t){var i=e._gsap||new JV(e);if("x"in i&&!t&&!i.uncache)return i;var n=e.style,a=i.scaleX<0,s="px",o="deg",l=getComputedStyle(e),u=Za(e,Xi)||"0",c,h,d,f,p,v,g,m,y,_,b,T,x,C,D,I,M,L,N,O,B,F,U,$,q,Z,te,Q,se,he,ue,Ie;return c=h=d=v=g=m=y=_=b=0,f=p=1,i.svg=!!(e.getCTM&&pz(e)),l.translate&&((l.translate!=="none"||l.scale!=="none"||l.rotate!=="none")&&(n[Qt]=(l.translate!=="none"?"translate3d("+(l.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+(l.rotate!=="none"?"rotate("+l.rotate+") ":"")+(l.scale!=="none"?"scale("+l.scale.split(" ").join(",")+") ":"")+(l[Qt]!=="none"?l[Qt]:"")),n.scale=n.rotate=n.translate="none"),C=NA(e,i.svg),i.svg&&(i.uncache?(q=e.getBBox(),u=i.xOrigin-q.x+"px "+(i.yOrigin-q.y)+"px",$=""):$=!t&&e.getAttribute("data-svg-origin"),hx(e,$||u,!!$||i.originIsAbsolute,i.smooth!==!1,C)),T=i.xOrigin||0,x=i.yOrigin||0,C!==iv&&(L=C[0],N=C[1],O=C[2],B=C[3],c=F=C[4],h=U=C[5],C.length===6?(f=Math.sqrt(L*L+N*N),p=Math.sqrt(B*B+O*O),v=L||N?Lc(N,L)*Ql:0,y=O||B?Lc(O,B)*Ql+v:0,y&&(p*=Math.abs(Math.cos(y*Ih))),i.svg&&(c-=T-(T*L+x*O),h-=x-(T*N+x*B))):(Ie=C[6],he=C[7],te=C[8],Q=C[9],se=C[10],ue=C[11],c=C[12],h=C[13],d=C[14],D=Lc(Ie,se),g=D*Ql,D&&(I=Math.cos(-D),M=Math.sin(-D),$=F*I+te*M,q=U*I+Q*M,Z=Ie*I+se*M,te=F*-M+te*I,Q=U*-M+Q*I,se=Ie*-M+se*I,ue=he*-M+ue*I,F=$,U=q,Ie=Z),D=Lc(-O,se),m=D*Ql,D&&(I=Math.cos(-D),M=Math.sin(-D),$=L*I-te*M,q=N*I-Q*M,Z=O*I-se*M,ue=B*M+ue*I,L=$,N=q,O=Z),D=Lc(N,L),v=D*Ql,D&&(I=Math.cos(D),M=Math.sin(D),$=L*I+N*M,q=F*I+U*M,N=N*I-L*M,U=U*I-F*M,L=$,F=q),g&&Math.abs(g)+Math.abs(v)>359.9&&(g=v=0,m=180-m),f=vr(Math.sqrt(L*L+N*N+O*O)),p=vr(Math.sqrt(U*U+Ie*Ie)),D=Lc(F,U),y=Math.abs(D)>2e-4?D*Ql:0,b=ue?1/(ue<0?-ue:ue):0),i.svg&&($=e.getAttribute("transform"),i.forceCSS=e.setAttribute("transform","")||!gz(Za(e,Qt)),$&&e.setAttribute("transform",$))),Math.abs(y)>90&&Math.abs(y)<270&&(a?(f*=-1,y+=v<=0?180:-180,v+=v<=0?180:-180):(p*=-1,y+=y<=0?180:-180)),t=t||i.uncache,i.x=c-((i.xPercent=c&&(!t&&i.xPercent||(Math.round(e.offsetWidth/2)===Math.round(-c)?-50:0)))?e.offsetWidth*i.xPercent/100:0)+s,i.y=h-((i.yPercent=h&&(!t&&i.yPercent||(Math.round(e.offsetHeight/2)===Math.round(-h)?-50:0)))?e.offsetHeight*i.yPercent/100:0)+s,i.z=d+s,i.scaleX=vr(f),i.scaleY=vr(p),i.rotation=vr(v)+o,i.rotationX=vr(g)+o,i.rotationY=vr(m)+o,i.skewX=y+o,i.skewY=_+o,i.transformPerspective=b+s,(i.zOrigin=parseFloat(u.split(" ")[2])||!t&&i.zOrigin||0)&&(n[Xi]=my(u)),i.xOffset=i.yOffset=0,i.force3D=pn.force3D,i.renderTransform=i.svg?Kse:fz?mz:Yse,i.uncache=0,i},my=function(e){return(e=e.split(" "))[0]+" "+e[1]},F2=function(e,t,i){var n=ii(t);return vr(parseFloat(t)+parseFloat(Qo(e,"x",i+"px",n)))+n},Yse=function(e,t){t.z="0px",t.rotationY=t.rotationX="0deg",t.force3D=0,mz(e,t)},xl="0deg",hd="0px",wl=") ",mz=function(e,t){var i=t||this,n=i.xPercent,a=i.yPercent,s=i.x,o=i.y,l=i.z,u=i.rotation,c=i.rotationY,h=i.rotationX,d=i.skewX,f=i.skewY,p=i.scaleX,v=i.scaleY,g=i.transformPerspective,m=i.force3D,y=i.target,_=i.zOrigin,b="",T=m==="auto"&&e&&e!==1||m===!0;if(_&&(h!==xl||c!==xl)){var x=parseFloat(c)*Ih,C=Math.sin(x),D=Math.cos(x),I;x=parseFloat(h)*Ih,I=Math.cos(x),s=F2(y,s,C*I*-_),o=F2(y,o,-Math.sin(x)*-_),l=F2(y,l,D*I*-_+_)}g!==hd&&(b+="perspective("+g+wl),(n||a)&&(b+="translate("+n+"%, "+a+"%) "),(T||s!==hd||o!==hd||l!==hd)&&(b+=l!==hd||T?"translate3d("+s+", "+o+", "+l+") ":"translate("+s+", "+o+wl),u!==xl&&(b+="rotate("+u+wl),c!==xl&&(b+="rotateY("+c+wl),h!==xl&&(b+="rotateX("+h+wl),(d!==xl||f!==xl)&&(b+="skew("+d+", "+f+wl),(p!==1||v!==1)&&(b+="scale("+p+", "+v+wl),y.style[Qt]=b||"translate(0, 0)"},Kse=function(e,t){var i=t||this,n=i.xPercent,a=i.yPercent,s=i.x,o=i.y,l=i.rotation,u=i.skewX,c=i.skewY,h=i.scaleX,d=i.scaleY,f=i.target,p=i.xOrigin,v=i.yOrigin,g=i.xOffset,m=i.yOffset,y=i.forceCSS,_=parseFloat(s),b=parseFloat(o),T,x,C,D,I;l=parseFloat(l),u=parseFloat(u),c=parseFloat(c),c&&(c=parseFloat(c),u+=c,l+=c),l||u?(l*=Ih,u*=Ih,T=Math.cos(l)*h,x=Math.sin(l)*h,C=Math.sin(l-u)*-d,D=Math.cos(l-u)*d,u&&(c*=Ih,I=Math.tan(u-c),I=Math.sqrt(1+I*I),C*=I,D*=I,c&&(I=Math.tan(c),I=Math.sqrt(1+I*I),T*=I,x*=I)),T=vr(T),x=vr(x),C=vr(C),D=vr(D)):(T=h,D=d,x=C=0),(_&&!~(s+"").indexOf("px")||b&&!~(o+"").indexOf("px"))&&(_=Qo(f,"x",s,"px"),b=Qo(f,"y",o,"px")),(p||v||g||m)&&(_=vr(_+p-(p*T+v*C)+g),b=vr(b+v-(p*x+v*D)+m)),(n||a)&&(I=f.getBBox(),_=vr(_+n/100*I.width),b=vr(b+a/100*I.height)),I="matrix("+T+","+x+","+C+","+D+","+_+","+b+")",f.setAttribute("transform",I),y&&(f.style[Qt]=I)},Zse=function(e,t,i,n,a){var s=360,o=$r(a),l=parseFloat(a)*(o&&~a.indexOf("rad")?Ql:1),u=l-n,c=n+u+"deg",h,d;return o&&(h=a.split("_")[1],h==="short"&&(u%=s,u!==u%(s/2)&&(u+=u<0?s:-s)),h==="cw"&&u<0?u=(u+s*Y4)%s-~~(u/s)*s:h==="ccw"&&u>0&&(u=(u-s*Y4)%s-~~(u/s)*s)),e._pt=d=new ji(e._pt,t,i,n,u,Rse),d.e=c,d.u="deg",e._props.push(i),d},tP=function(e,t){for(var i in t)e[i]=t[i];return e},Qse=function(e,t,i){var n=tP({},i._gsap),a="perspective,force3D,transformOrigin,svgOrigin",s=i.style,o,l,u,c,h,d,f,p;n.svg?(u=i.getAttribute("transform"),i.setAttribute("transform",""),s[Qt]=t,o=nv(i,1),Ku(i,Qt),i.setAttribute("transform",u)):(u=getComputedStyle(i)[Qt],s[Qt]=t,o=nv(i,1),s[Qt]=u);for(l in Hs)u=n[l],c=o[l],u!==c&&a.indexOf(l)<0&&(f=ii(u),p=ii(c),h=f!==p?Qo(i,l,u,p):parseFloat(u),d=parseFloat(c),e._pt=new ji(e._pt,o,l,h,d-h,lx),e._pt.u=p||0,e._props.push(l));tP(o,n)};qi("padding,margin,Width,Radius",function(r,e){var t="Top",i="Right",n="Bottom",a="Left",s=(e<3?[t,i,n,a]:[t+a,t+i,n+i,n+a]).map(function(o){return e<2?r+o:"border"+o+r});gy[e>1?"border"+r:r]=function(o,l,u,c,h){var d,f;if(arguments.length<4)return d=s.map(function(p){return xs(o,p,u)}),f=d.join(" "),f.split(d[0]).length===5?d[0]:f;d=(c+"").split(" "),f={},s.forEach(function(p,v){return f[p]=d[v]=d[v]||d[(v-1)/2|0]}),o.init(l,f,h)}});var yz={name:"css",register:cx,targetTest:function(e){return e.style&&e.nodeType},init:function(e,t,i,n,a){var s=this._props,o=e.style,l=i.vars.startAt,u,c,h,d,f,p,v,g,m,y,_,b,T,x,C,D;kA||cx(),this.styles=this.styles||hz(e),D=this.styles.props,this.tween=i;for(v in t)if(v!=="autoRound"&&(c=t[v],!(sn[v]&&ez(v,t,i,n,e,a)))){if(f=typeof c,p=gy[v],f==="function"&&(c=c.call(i,n,e,a),f=typeof c),f==="string"&&~c.indexOf("random(")&&(c=ev(c)),p)p(this,e,v,c,i)&&(C=1);else if(v.substr(0,2)==="--")u=(getComputedStyle(e).getPropertyValue(v)+"").trim(),c+="",$o.lastIndex=0,$o.test(u)||(g=ii(u),m=ii(c)),m?g!==m&&(u=Qo(e,v,u,m)+m):g&&(c+=g),this.add(o,"setProperty",u,c,n,a,0,0,v),s.push(v),D.push(v,0,o[v]);else if(f!=="undefined"){if(l&&v in l?(u=typeof l[v]=="function"?l[v].call(i,n,e,a):l[v],$r(u)&&~u.indexOf("random(")&&(u=ev(u)),ii(u+"")||u==="auto"||(u+=pn.units[v]||ii(xs(e,v))||""),(u+"").charAt(1)==="="&&(u=xs(e,v))):u=xs(e,v),d=parseFloat(u),y=f==="string"&&c.charAt(1)==="="&&c.substr(0,2),y&&(c=c.substr(2)),h=parseFloat(c),v in $a&&(v==="autoAlpha"&&(d===1&&xs(e,"visibility")==="hidden"&&h&&(d=0),D.push("visibility",0,o.visibility),Lo(this,o,"visibility",d?"inherit":"hidden",h?"inherit":"hidden",!h)),v!=="scale"&&v!=="transform"&&(v=$a[v],~v.indexOf(",")&&(v=v.split(",")[0]))),_=v in Hs,_){if(this.styles.save(v),b||(T=e._gsap,T.renderTransform&&!t.parseTransform||nv(e,t.parseTransform),x=t.smoothOrigin!==!1&&T.smooth,b=this._pt=new ji(this._pt,o,Qt,0,1,T.renderTransform,T,0,-1),b.dep=1),v==="scale")this._pt=new ji(this._pt,T,"scaleY",T.scaleY,(y?Dh(T.scaleY,y+h):h)-T.scaleY||0,lx),this._pt.u=0,s.push("scaleY",v),v+="X";else if(v==="transformOrigin"){D.push(Xi,0,o[Xi]),c=jse(c),T.svg?hx(e,c,0,x,0,this):(m=parseFloat(c.split(" ")[2])||0,m!==T.zOrigin&&Lo(this,T,"zOrigin",T.zOrigin,m),Lo(this,o,v,my(u),my(c)));continue}else if(v==="svgOrigin"){hx(e,c,1,x,0,this);continue}else if(v in vz){Zse(this,T,v,d,y?Dh(d,y+c):c);continue}else if(v==="smoothOrigin"){Lo(this,T,"smooth",T.smooth,c);continue}else if(v==="force3D"){T[v]=c;continue}else if(v==="transform"){Qse(this,c,e);continue}}else v in o||(v=nf(v)||v);if(_||(h||h===0)&&(d||d===0)&&!kse.test(c)&&v in o)g=(u+"").substr((d+"").length),h||(h=0),m=ii(c)||(v in pn.units?pn.units[v]:g),g!==m&&(d=Qo(e,v,u,m)),this._pt=new ji(this._pt,_?T:o,v,d,(y?Dh(d,y+h):h)-d,!_&&(m==="px"||v==="zIndex")&&t.autoRound!==!1?Nse:lx),this._pt.u=m||0,g!==m&&m!=="%"&&(this._pt.b=u,this._pt.r=Ose);else if(v in o)qse.call(this,e,v,u,y?y+c:c);else if(v in e)this.add(e,v,u||e[v],y?y+c:c,n,a);else if(v!=="parseTransform"){wA(v,c);continue}_||(v in o?D.push(v,0,o[v]):D.push(v,1,u||e[v])),s.push(v)}}C&&sz(this)},render:function(e,t){if(t.tween._time||!RA())for(var i=t._pt;i;)i.r(e,i.d),i=i._next;else t.styles.revert()},get:xs,aliases:$a,getSetter:function(e,t,i){var n=$a[t];return n&&n.indexOf(",")<0&&(t=n),t in Hs&&t!==Xi&&(e._gsap.x||xs(e,"x"))?i&&X4===i?t==="scale"?Vse:Use:(X4=i||{})&&(t==="scale"?zse:Gse):e.style&&!SA(e.style[t])?Bse:~t.indexOf("-")?Fse:MA(e,t)},core:{_removeProperty:Ku,_getMatrix:NA}};Yi.utils.checkPrefix=nf;Yi.core.getStyleSaver=hz;(function(r,e,t,i){var n=qi(r+","+e+","+t,function(a){Hs[a]=1});qi(e,function(a){pn.units[a]="deg",vz[a]=1}),$a[n[13]]=r+","+e,qi(i,function(a){var s=a.split(":");$a[s[1]]=n[s[0]]})})("x,y,z,scale,scaleX,scaleY,xPercent,yPercent","rotation,rotationX,rotationY,skewX,skewY","transform,transformOrigin,svgOrigin,force3D,smoothOrigin,transformPerspective","0:translateX,1:translateY,2:translateZ,8:rotate,8:rotationZ,8:rotateZ,9:rotateX,10:rotateY");qi("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",function(r){pn.units[r]="px"});Yi.registerPlugin(yz);var BA=Yi.registerPlugin(yz)||Yi;BA.core.Tween;/*! + * matrix 3.12.5 + * https://gsap.com + * + * Copyright 2008-2024, GreenSock. All rights reserved. + * Subject to the terms at https://gsap.com/standard-license or for + * Club GSAP members, the agreement issued with that membership. + * @author: Jack Doyle, jack@greensock.com +*/var Ds,Ou,FA,Y_,Zd,c0,yy,wp,ca="transform",fx=ca+"Origin",_z,bz=function(e){var t=e.ownerDocument||e;for(!(ca in e.style)&&("msTransform"in e.style)&&(ca="msTransform",fx=ca+"Origin");t.parentNode&&(t=t.parentNode););if(Ou=window,yy=new Zu,t){Ds=t,FA=t.documentElement,Y_=t.body,wp=Ds.createElementNS("http://www.w3.org/2000/svg","g"),wp.style.transform="none";var i=t.createElement("div"),n=t.createElement("div"),a=t&&(t.body||t.firstElementChild);a&&a.appendChild&&(a.appendChild(i),i.appendChild(n),i.setAttribute("style","position:static;transform:translate3d(0,0,1px)"),_z=n.offsetParent!==i,a.removeChild(i))}return t},Jse=function(e){for(var t,i;e&&e!==Y_;)i=e._gsap,i&&i.uncache&&i.get(e,"x"),i&&!i.scaleX&&!i.scaleY&&i.renderTransform&&(i.scaleX=i.scaleY=1e-4,i.renderTransform(1,i),t?t.push(i):t=[i]),e=e.parentNode;return t},Sz=[],Tz=[],eoe=function(){return Ou.pageYOffset||Ds.scrollTop||FA.scrollTop||Y_.scrollTop||0},toe=function(){return Ou.pageXOffset||Ds.scrollLeft||FA.scrollLeft||Y_.scrollLeft||0},UA=function(e){return e.ownerSVGElement||((e.tagName+"").toLowerCase()==="svg"?e:null)},roe=function r(e){if(Ou.getComputedStyle(e).position==="fixed")return!0;if(e=e.parentNode,e&&e.nodeType===1)return r(e)},U2=function r(e,t){if(e.parentNode&&(Ds||bz(e))){var i=UA(e),n=i?i.getAttribute("xmlns")||"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",a=i?t?"rect":"g":"div",s=t!==2?0:100,o=t===3?100:0,l="position:absolute;display:block;pointer-events:none;margin:0;padding:0;",u=Ds.createElementNS?Ds.createElementNS(n.replace(/^https/,"http"),a):Ds.createElement(a);return t&&(i?(c0||(c0=r(e)),u.setAttribute("width",.01),u.setAttribute("height",.01),u.setAttribute("transform","translate("+s+","+o+")"),c0.appendChild(u)):(Zd||(Zd=r(e),Zd.style.cssText=l),u.style.cssText=l+"width:0.1px;height:0.1px;top:"+o+"px;left:"+s+"px",Zd.appendChild(u))),u}throw"Need document and parent."},ioe=function(e){for(var t=new Zu,i=0;i1?ioe(l):l.getItem(0).matrix:yy,c=l.a*u.x+l.c*u.y,h=l.b*u.x+l.d*u.y):(l=new Zu,c=h=0),(n?i:s).appendChild(o),o.setAttribute("transform","matrix("+l.a+","+l.b+","+l.c+","+l.d+","+(l.e+c)+","+(l.f+h)+")");else{if(c=h=0,_z)for(l=e.offsetParent,u=e;u&&(u=u.parentNode)&&u!==l&&u.parentNode;)(Ou.getComputedStyle(u)[ca]+"").length>4&&(c=u.offsetLeft,h=u.offsetTop,u=0);if(d=Ou.getComputedStyle(e),d.position!=="absolute"&&d.position!=="fixed")for(l=e.offsetParent;s&&s!==l;)c+=s.scrollLeft||0,h+=s.scrollTop||0,s=s.parentNode;u=o.style,u.top=e.offsetTop-h+"px",u.left=e.offsetLeft-c+"px",u[ca]=d[ca],u[fx]=d[fx],u.position=d.position==="fixed"?"fixed":"absolute",e.parentNode.appendChild(o)}return o},V2=function(e,t,i,n,a,s,o){return e.a=t,e.b=i,e.c=n,e.d=a,e.e=s,e.f=o,e},Zu=function(){function r(t,i,n,a,s,o){t===void 0&&(t=1),i===void 0&&(i=0),n===void 0&&(n=0),a===void 0&&(a=1),s===void 0&&(s=0),o===void 0&&(o=0),V2(this,t,i,n,a,s,o)}var e=r.prototype;return e.inverse=function(){var i=this.a,n=this.b,a=this.c,s=this.d,o=this.e,l=this.f,u=i*s-n*a||1e-10;return V2(this,s/u,-n/u,-a/u,i/u,(a*l-s*o)/u,-(i*l-n*o)/u)},e.multiply=function(i){var n=this.a,a=this.b,s=this.c,o=this.d,l=this.e,u=this.f,c=i.a,h=i.c,d=i.b,f=i.d,p=i.e,v=i.f;return V2(this,c*n+d*s,c*a+d*o,h*n+f*s,h*a+f*o,l+p*n+v*s,u+p*a+v*o)},e.clone=function(){return new r(this.a,this.b,this.c,this.d,this.e,this.f)},e.equals=function(i){var n=this.a,a=this.b,s=this.c,o=this.d,l=this.e,u=this.f;return n===i.a&&a===i.b&&s===i.c&&o===i.d&&l===i.e&&u===i.f},e.apply=function(i,n){n===void 0&&(n={});var a=i.x,s=i.y,o=this.a,l=this.b,u=this.c,c=this.d,h=this.e,d=this.f;return n.x=a*o+s*u+h||0,n.y=a*l+s*c+d||0,n},r}();function ou(r,e,t,i){if(!r||!r.parentNode||(Ds||bz(r)).documentElement===r)return new Zu;var n=Jse(r),a=UA(r),s=a?Sz:Tz,o=aoe(r),l=s[0].getBoundingClientRect(),u=s[1].getBoundingClientRect(),c=s[2].getBoundingClientRect(),h=o.parentNode,d=roe(r),f=new Zu((u.left-l.left)/100,(u.top-l.top)/100,(c.left-l.left)/100,(c.top-l.top)/100,l.left+(d?0:toe()),l.top+(d?0:eoe()));if(h.removeChild(o),n)for(l=n.length;l--;)u=n[l],u.scaleX=u.scaleY=0,u.renderTransform(1,u);return e?f.inverse():f}function rP(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function soe(r,e){r.prototype=Object.create(e.prototype),r.prototype.constructor=r,r.__proto__=e}var gt,Ft,un,va,Es,z2,ws,dx,Qd,ko,xz,px,av,VA,Jd,na,ep,h0,wz,vx,_y=0,Cz=function(){return typeof window<"u"},Az=function(){return gt||Cz()&&(gt=window.gsap)&>.registerPlugin&>},Do=function(e){return typeof e=="function"},Cp=function(e){return typeof e=="object"},ua=function(e){return typeof e>"u"},f0=function(){return!1},Ap="transform",gx="transformOrigin",ho=function(e){return Math.round(e*1e4)/1e4},fd=Array.isArray,Zg=function(e,t){var i=un.createElementNS?un.createElementNS("http://www.w3.org/1999/xhtml".replace(/^https/,"http"),e):un.createElement(e);return i.style?i:un.createElement(e)},iP=180/Math.PI,Cl=1e20,ooe=new Zu,fo=Date.now||function(){return new Date().getTime()},Nu=[],Ph={},loe=0,uoe=/^(?:a|input|textarea|button|select)$/i,nP=0,kc={},_s={},Dz=function(e,t){var i={},n;for(n in e)i[n]=t?e[n]*t:e[n];return i},coe=function(e,t){for(var i in t)i in e||(e[i]=t[i]);return e},aP=function r(e,t){for(var i=e.length,n;i--;)t?e[i].style.touchAction=t:e[i].style.removeProperty("touch-action"),n=e[i].children,n&&n.length&&r(n,t)},Ez=function(){return Nu.forEach(function(e){return e()})},hoe=function(e){Nu.push(e),Nu.length===1&>.ticker.add(Ez)},sP=function(){return!Nu.length&>.ticker.remove(Ez)},oP=function(e){for(var t=Nu.length;t--;)Nu[t]===e&&Nu.splice(t,1);gt.to(sP,{overwrite:!0,delay:15,duration:0,onComplete:sP,data:"_draggable"})},foe=function(e,t){for(var i in t)i in e||(e[i]=t[i]);return e},Pr=function(e,t,i,n){if(e.addEventListener){var a=av[t];n=n||(xz?{passive:!1}:null),e.addEventListener(a||t,i,n),a&&t!==a&&e.addEventListener(t,i,n)}},Sr=function(e,t,i,n){if(e.removeEventListener){var a=av[t];e.removeEventListener(a||t,i,n),a&&t!==a&&e.removeEventListener(t,i,n)}},wn=function(e){e.preventDefault&&e.preventDefault(),e.preventManipulation&&e.preventManipulation()},doe=function(e,t){for(var i=e.length;i--;)if(e[i].identifier===t)return!0},poe=function r(e){VA=e.touches&&_y2||C<-2)&&!x){u=e.scrollLeft,gt.killTweensOf(this,{left:1,scrollLeft:1}),this.left(-u),t.onKill&&t.onKill();return}T=-T,T<0?(o=T-.5|0,T=0):T>f?(o=T-f|0,T=f):o=0,(o||D)&&(this._skip||(n[Ap]=_+-o+"px,"+-s+b),o+d>=0&&(n.paddingRight=o+d+"px")),e.scrollLeft=T|0,u=e.scrollLeft},this.top=function(T,x){if(!arguments.length)return-(e.scrollTop+s);var C=e.scrollTop-l,D=s;if((C>2||C<-2)&&!x){l=e.scrollTop,gt.killTweensOf(this,{top:1,scrollTop:1}),this.top(-l),t.onKill&&t.onKill();return}T=-T,T<0?(s=T-.5|0,T=0):T>p?(s=T-p|0,T=p):s=0,(s||D)&&(this._skip||(n[Ap]=_+-o+"px,"+-s+b)),e.scrollTop=T|0,l=e.scrollTop},this.maxScrollTop=function(){return p},this.maxScrollLeft=function(){return f},this.disable=function(){for(a=i.firstChild;a;)y=a.nextSibling,e.appendChild(a),a=y;e===i.parentNode&&e.removeChild(i)},this.enable=function(){if(a=e.firstChild,a!==i){for(;a;)y=a.nextSibling,i.appendChild(a),a=y;e.appendChild(i),this.calibrate()}},this.calibrate=function(T){var x=e.clientWidth===v,C,D,I;l=e.scrollTop,u=e.scrollLeft,!(x&&e.clientHeight===g&&i.offsetHeight===m&&c===e.scrollWidth&&h===e.scrollHeight&&!T)&&((s||o)&&(D=this.left(),I=this.top(),this.left(-e.scrollLeft),this.top(-e.scrollTop)),C=sv(e),(!x||T)&&(n.display="block",n.width="auto",n.paddingRight="0px",d=Math.max(0,e.scrollWidth-e.clientWidth),d&&(d+=parseFloat(C.paddingLeft)+(mx?parseFloat(C.paddingRight):0))),n.display="inline-block",n.position="relative",n.overflow="visible",n.verticalAlign="top",n.boxSizing="content-box",n.width="100%",n.paddingRight=d+"px",mx&&(n.paddingBottom=C.paddingBottom),v=e.clientWidth,g=e.clientHeight,c=e.scrollWidth,h=e.scrollHeight,f=e.scrollWidth-v,p=e.scrollHeight-g,m=i.offsetHeight,n.display="block",(D||I)&&(this.left(D),this.top(I)))},this.content=i,this.element=e,this._skip=!1,this.enable()},W2=function(e){if(Cz()&&document.body){var t=window&&window.navigator;Ft=window,un=document,va=un.documentElement,Es=un.body,z2=Zg("div"),h0=!!window.PointerEvent,ws=Zg("div"),ws.style.cssText="visibility:hidden;height:1px;top:-1px;pointer-events:none;position:relative;clear:both;cursor:grab",ep=ws.style.cursor==="grab"?"grab":"move",Jd=t&&t.userAgent.toLowerCase().indexOf("android")!==-1,px="ontouchstart"in va&&"orientation"in Ft||t&&(t.MaxTouchPoints>0||t.msMaxTouchPoints>0),mx=function(){var i=Zg("div"),n=Zg("div"),a=n.style,s=Es,o;return a.display="inline-block",a.position="relative",i.style.cssText="width:90px;height:40px;padding:10px;overflow:auto;visibility:hidden",i.appendChild(n),s.appendChild(i),o=n.offsetHeight+18>i.scrollHeight,s.removeChild(i),o}(),av=function(i){for(var n=i.split(","),a=("onpointerdown"in z2?"pointerdown,pointermove,pointerup,pointercancel":"onmspointerdown"in z2?"MSPointerDown,MSPointerMove,MSPointerUp,MSPointerCancel":i).split(","),s={},o=4;--o>-1;)s[n[o]]=a[o],s[a[o]]=n[o];try{va.addEventListener("test",null,Object.defineProperty({},"passive",{get:function(){xz=1}}))}catch{}return s}("touchstart,touchmove,touchend,touchcancel"),Pr(un,"touchcancel",f0),Pr(Ft,"touchmove",f0),Es&&Es.addEventListener("touchstart",f0),Pr(un,"contextmenu",function(){for(var i in Ph)Ph[i].isPressed&&Ph[i].endDrag()}),gt=dx=Az()}gt?(na=gt.plugins.inertia,wz=gt.core.context||function(){},Qd=gt.utils.checkPrefix,Ap=Qd(Ap),gx=Qd(gx),ko=gt.utils.toArray,vx=gt.core.getStyleSaver,Iz=!!Qd("perspective")):e&&console.warn("Please gsap.registerPlugin(Draggable)")},_oe=function(){function r(t){this._listeners={},this.target=t||this}var e=r.prototype;return e.addEventListener=function(i,n){var a=this._listeners[i]||(this._listeners[i]=[]);~a.indexOf(n)||a.push(n)},e.removeEventListener=function(i,n){var a=this._listeners[i],s=a&&a.indexOf(n);s>=0&&a.splice(s,1)},e.dispatchEvent=function(i){var n=this,a;return(this._listeners[i]||[]).forEach(function(s){return s.call(n,{type:i,target:n.target})===!1&&(a=!1)}),a},r}(),Qu=function(r){soe(e,r);function e(t,i){var n;n=r.call(this)||this,dx||W2(1),t=ko(t)[0],n.styles=vx&&vx(t,"transform,left,top"),na||(na=gt.plugins.inertia),n.vars=i=Dz(i||{}),n.target=t,n.x=n.y=n.rotation=0,n.dragResistance=parseFloat(i.dragResistance)||0,n.edgeResistance=isNaN(i.edgeResistance)?1:parseFloat(i.edgeResistance)||0,n.lockAxis=i.lockAxis,n.autoScroll=i.autoScroll||0,n.lockedAxis=null,n.allowEventDefault=!!i.allowEventDefault,gt.getProperty(t,"x");var a=(i.type||"x,y").toLowerCase(),s=~a.indexOf("x")||~a.indexOf("y"),o=a.indexOf("rotation")!==-1,l=o?"rotation":s?"x":"left",u=s?"y":"top",c=!!(~a.indexOf("x")||~a.indexOf("left")||a==="scroll"),h=!!(~a.indexOf("y")||~a.indexOf("top")||a==="scroll"),d=i.minimumMovement||2,f=rP(n),p=ko(i.trigger||i.handle||t),v={},g=0,m=!1,y=i.autoScrollMarginTop||40,_=i.autoScrollMarginRight||40,b=i.autoScrollMarginBottom||40,T=i.autoScrollMarginLeft||40,x=i.clickableTest||goe,C=0,D=t._gsap||gt.core.getCache(t),I=moe(t),M=function(X,fe){return parseFloat(D.get(t,X,fe))},L=t.ownerDocument||un,N,O,B,F,U,$,q,Z,te,Q,se,he,ue,Ie,Oe,Fe,me,ze,Pe,ye,Me,_t,Re,Ge,Pt,wt,At,rr,ht,Ji,br,ro,io,gc=function(X){return wn(X),X.stopImmediatePropagation&&X.stopImmediatePropagation(),!1},Mi=function Ve(X){if(f.autoScroll&&f.isDragging&&(m||me)){var fe=t,re=f.autoScroll*15,ve,Se,Ae,nt,Ne,St,Ye,Dt;for(m=!1,_s.scrollTop=Ft.pageYOffset!=null?Ft.pageYOffset:L.documentElement.scrollTop!=null?L.documentElement.scrollTop:L.body.scrollTop,_s.scrollLeft=Ft.pageXOffset!=null?Ft.pageXOffset:L.documentElement.scrollLeft!=null?L.documentElement.scrollLeft:L.body.scrollLeft,nt=f.pointerX-_s.scrollLeft,Ne=f.pointerY-_s.scrollTop;fe&&!Se;)Se=af(fe.parentNode),ve=Se?_s:fe.parentNode,Ae=Se?{bottom:Math.max(va.clientHeight,Ft.innerHeight||0),right:Math.max(va.clientWidth,Ft.innerWidth||0),left:0,top:0}:ve.getBoundingClientRect(),St=Ye=0,h&&(Dt=ve._gsMaxScrollY-ve.scrollTop,Dt<0?Ye=Dt:Ne>Ae.bottom-b&&Dt?(m=!0,Ye=Math.min(Dt,re*(1-Math.max(0,Ae.bottom-Ne)/b)|0)):NeAe.right-_&&Dt?(m=!0,St=Math.min(Dt,re*(1-Math.max(0,Ae.right-nt)/_)|0)):ntre?re+(Se-re)*Ae:Se-1;)St=X[Ae],Ye=St-Se,Ye<0&&(Ye=-Ye),Ye=fe&&St<=re&&(nt=Ae,Ne=Ye);return X[nt]}:isNaN(X)?function(Se){return Se}:function(){return X*ve}},mg=function(X,fe,re,ve,Se,Ae,nt){return Ae=Ae&&Aere?re+(Ye-re)*St:YeSe?Se+(Dt-Se)*St:DtAe&&(Ne.x=Ye,Ne.y=Dt)),Ne}:fd(X)?function(Ne){for(var St=X.length,Ye=0,Dt=Cl,Kt,ur,Dr,qr;--St>-1;)Dr=X[St],Kt=Dr.x-Ne.x,ur=Dr.y-Ne.y,qr=Kt*Kt+ur*ur,qrQ&&(f.minX=Q,f.maxX=Q=se,se=f.minX),ue>he&&(f.minY=he,f.maxY=he=ue,ue=f.minY),o&&(f.minRotation=se,f.maxRotation=Q),q=!0),i.liveSnap&&(re=i.liveSnap===!0?i.snap||{}:i.liveSnap,ve=fd(re)||Do(re),o?(Pe=fl(ve?re:re.rotation,se,Q,1),ye=null):re.points?Me=mg(ve?re:re.points,se,Q,ue,he,re.radius,O?-1:1):(c&&(Pe=fl(ve?re:re.x||re.left||re.scrollLeft,se,Q,O?-1:1)),h&&(ye=fl(ve?re:re.y||re.top||re.scrollTop,ue,he,O?-1:1))))},yg=function(){f.isThrowing=!1,fr(f,"throwcomplete","onThrowComplete")},Nt=function(){f.isThrowing=!1},$f=function(X,fe){var re,ve,Se,Ae;X&&na?(X===!0&&(re=i.snap||i.liveSnap||{},ve=fd(re)||Do(re),X={resistance:(i.throwResistance||i.resistance||1e3)/(o?10:1)},o?X.rotation=$2(f,ve?re:re.rotation,Q,se,1,fe):(c&&(X[l]=$2(f,ve?re:re.points||re.x||re.left,Q,se,O?-1:1,fe||f.lockedAxis==="x")),h&&(X[u]=$2(f,ve?re:re.points||re.y||re.top,he,ue,O?-1:1,fe||f.lockedAxis==="y")),(re.points||fd(re)&&Cp(re[0]))&&(X.linkedProps=l+","+u,X.radius=re.radius))),f.isThrowing=!0,Ae=isNaN(i.overshootTolerance)?i.edgeResistance===1?0:1-f.edgeResistance+.2:i.overshootTolerance,X.duration||(X.duration={max:Math.max(i.minDuration||0,"maxDuration"in i?i.maxDuration:2),min:isNaN(i.minDuration)?Ae===0||Cp(X)&&X.resistance>1e3?0:.5:i.minDuration,overshoot:Ae}),f.tween=Se=gt.to(O||t,{inertia:X,data:"_draggable",inherit:!1,onComplete:yg,onInterrupt:Nt,onUpdate:i.fastMode?fr:Sn,onUpdateParams:i.fastMode?[f,"onthrowupdate","onThrowUpdate"]:re&&re.radius?[!1,!0]:[]}),i.fastMode||(O&&(O._skip=!0),Se.render(1e9,!0,!0),Sn(!0,!0),f.endX=f.x,f.endY=f.y,o&&(f.endRotation=f.x),Se.play(0),Sn(!0,!0),O&&(O._skip=!1))):q&&f.applyBounds()},dl=function(X){var fe=Ge,re;Ge=ou(t.parentNode,!0),X&&f.isPressed&&!Ge.equals(fe||new Zu)&&(re=fe.inverse().apply({x:B,y:F}),Ge.apply(re,re),B=re.x,F=re.y),Ge.equals(ooe)&&(Ge=null)},yc=function(){var X=1-f.edgeResistance,fe=I?Lh(L):0,re=I?Mh(L):0,ve,Se,Ae;s&&(D.x=M(l,"px")+"px",D.y=M(u,"px")+"px",D.renderTransform()),dl(!1),Cn.x=f.pointerX-fe,Cn.y=f.pointerY-re,Ge&&Ge.apply(Cn,Cn),B=Cn.x,F=Cn.y,me&&(gl(f.pointerX,f.pointerY),Mi(!0)),ro=ou(t),O?(mc(),$=O.top(),U=O.left()):(pl()?(Sn(!0,!0),mc()):f.applyBounds(),o?(ve=t.ownerSVGElement?[D.xOrigin-t.getBBox().x,D.yOrigin-t.getBBox().y]:(sv(t)[gx]||"0 0").split(" "),Fe=f.rotationOrigin=ou(t).apply({x:parseFloat(ve[0])||0,y:parseFloat(ve[1])||0}),Sn(!0,!0),Se=f.pointerX-Fe.x-fe,Ae=Fe.y-f.pointerY+re,U=f.x,$=f.y=Math.atan2(Ae,Se)*iP):($=M(u,"px"),U=M(l,"px"))),q&&X&&(U>Q?U=Q+(U-Q)/X:Uhe?$=he+($-he)/X:$2)?!1:c?"y":"x",br=!wt&&!f.allowEventDefault,br&&(wn(X),Pr(Ft,"touchforcechange",wn)),X.changedTouches?(X=Ie=X.changedTouches[0],Oe=X.identifier):X.pointerId?Oe=X.pointerId:Ie=Oe=null,_y++,hoe(Mi),F=f.pointerY=X.pageY,B=f.pointerX=X.pageX,fr(f,"pressInit","onPressInit"),(wt||f.autoScroll)&&G2(t.parentNode),t.parentNode&&f.autoScroll&&!O&&!o&&t.parentNode._gsMaxScrollX&&!ws.parentNode&&!t.getBBox&&(ws.style.width=t.parentNode.scrollWidth+"px",t.parentNode.appendChild(ws)),yc(),f.tween&&f.tween.kill(),f.isThrowing=!1,gt.killTweensOf(O||t,v,!0),O&>.killTweensOf(t,{scrollTo:1},!0),f.tween=f.lockedAxis=null,(i.zIndexBoost||!o&&!O&&i.zIndexBoost!==!1)&&(t.style.zIndex=e.zIndex++),f.isPressed=!0,Z=!!(i.onDrag||f._listeners.drag),te=!!(i.onMove||f._listeners.move),i.cursor!==!1||i.activeCursor)for(re=p.length;--re>-1;)gt.set(p[re],{cursor:i.activeCursor||i.cursor||(ep==="grab"?"grabbing":ep)});fr(f,"press","onPress")},ds=function(X){var fe=X,re,ve,Se,Ae,nt,Ne;if(!N||VA||!f.isPressed||!X){br&&X&&N&&wn(X);return}if(f.pointerEvent=X,re=X.changedTouches,re){if(X=re[0],X!==Ie&&X.identifier!==Oe){for(Ae=re.length;--Ae>-1&&(X=re[Ae]).identifier!==Oe&&X.target!==t;);if(Ae<0)return}}else if(X.pointerId&&Oe&&X.pointerId!==Oe)return;if(Re&&wt&&!At&&(Cn.x=X.pageX-(I?Lh(L):0),Cn.y=X.pageY-(I?Mh(L):0),Ge&&Ge.apply(Cn,Cn),ve=Cn.x,Se=Cn.y,nt=Math.abs(ve-B),Ne=Math.abs(Se-F),(nt!==Ne&&(nt>d||Ne>d)||Jd&&wt===At)&&(At=nt>Ne&&c?"x":"y",wt&&At!==wt&&Pr(Ft,"touchforcechange",wn),f.vars.lockAxisOnTouchScroll!==!1&&c&&h&&(f.lockedAxis=At==="x"?"y":"x",Do(f.vars.onLockAxis)&&f.vars.onLockAxis.call(f,fe)),Jd&&wt===At))){en(fe);return}!f.allowEventDefault&&(!wt||At&&wt!==At)&&fe.cancelable!==!1?(wn(fe),br=!0):br&&(br=!1),f.autoScroll&&(m=!0),gl(X.pageX,X.pageY,te)},gl=function(X,fe,re){var ve=1-f.dragResistance,Se=1-f.edgeResistance,Ae=f.pointerX,nt=f.pointerY,Ne=$,St=f.x,Ye=f.y,Dt=f.endX,Kt=f.endY,ur=f.endRotation,Dr=me,qr,ft,Er,zt,no,tn;f.pointerX=X,f.pointerY=fe,I&&(X-=Lh(L),fe-=Mh(L)),o?(zt=Math.atan2(Fe.y-fe,X-Fe.x)*iP,no=f.y-zt,no>180?($-=360,f.y=zt):no<-180&&($+=360,f.y=zt),f.x!==U||Math.abs($-zt)>d?(f.y=zt,Er=U+($-zt)*ve):Er=U):(Ge&&(tn=X*Ge.a+fe*Ge.c+Ge.e,fe=X*Ge.b+fe*Ge.d+Ge.f,X=tn),ft=fe-F,qr=X-B,ft-d&&(ft=0),qr-d&&(qr=0),(f.lockAxis||f.lockedAxis)&&(qr||ft)&&(tn=f.lockedAxis,tn||(f.lockedAxis=tn=c&&Math.abs(qr)>Math.abs(ft)?"y":h?"x":null,tn&&Do(f.vars.onLockAxis)&&f.vars.onLockAxis.call(f,f.pointerEvent)),tn==="y"?ft=0:tn==="x"&&(qr=0)),Er=ho(U+qr*ve),zt=ho($+ft*ve)),(Pe||ye||Me)&&(f.x!==Er||f.y!==zt&&!o)&&(Me&&(kc.x=Er,kc.y=zt,tn=Me(kc),Er=ho(tn.x),zt=ho(tn.y)),Pe&&(Er=ho(Pe(Er))),ye&&(zt=ho(ye(zt)))),q&&(Er>Q?Er=Q+Math.round((Er-Q)*Se):Erhe?zt=Math.round(he+(zt-he)*Se):zt2),Ae=gt.delayedCall(.001,B1),nt,Ne,St,Ye,Dt;if(Re?(Sr(Re,"touchend",Ve),Sr(Re,"touchmove",ds),Sr(Re,"touchcancel",Ve),Sr(L,"touchstart",lP)):Sr(L,"mousemove",ds),Sr(Ft,"touchforcechange",wn),(!h0||!Re)&&(Sr(L,"mouseup",Ve),X&&X.target&&Sr(X.target,"mouseup",Ve)),me=!1,ve&&(g=nP=fo(),f.isDragging=!1),oP(Mi),_t&&!Se){X&&(Sr(X.target,"change",Ve),f.pointerEvent=re),Qg(p,!1),fr(f,"release","onRelease"),fr(f,"click","onClick"),_t=!1;return}for(Ne=p.length;--Ne>-1;)H2(p[Ne],"cursor",i.cursor||(i.cursor!==!1?ep:null));if(_y--,X){if(nt=X.changedTouches,nt&&(X=nt[0],X!==Ie&&X.identifier!==Oe)){for(Ne=nt.length;--Ne>-1&&(X=nt[Ne]).identifier!==Oe&&X.target!==t;);if(Ne<0&&!fe)return}f.pointerEvent=re,f.pointerX=X.pageX,f.pointerY=X.pageY}return Se&&re?(wn(re),br=!0,fr(f,"release","onRelease")):re&&!ve?(br=!1,Pt&&(i.snap||i.bounds)&&$f(i.inertia||i.throwProps),fr(f,"release","onRelease"),(!Jd||re.type!=="touchmove")&&re.type.indexOf("cancel")===-1&&(fr(f,"click","onClick"),fo()-C<300&&fr(f,"doubleclick","onDoubleClick"),Ye=re.target||t,C=fo(),Dt=function(){C!==ht&&f.enabled()&&!f.isPressed&&!re.defaultPrevented&&(Ye.click?Ye.click():L.createEvent&&(St=L.createEvent("MouseEvents"),St.initMouseEvent("click",!0,!0,Ft,1,f.pointerEvent.screenX,f.pointerEvent.screenY,f.pointerX,f.pointerY,!1,!1,!1,!1,0,null),Ye.dispatchEvent(St)))},!Jd&&!re.defaultPrevented&>.delayedCall(.05,Dt))):($f(i.inertia||i.throwProps),!f.allowEventDefault&&re&&(i.dragClickables!==!1||!x.call(f,re.target))&&ve&&(!wt||At&&wt===At)&&re.cancelable!==!1?(br=!0,wn(re)):br=!1,fr(f,"release","onRelease")),pl()&&Ae.duration(f.tween.duration()),ve&&fr(f,"dragend","onDragEnd"),!0},_c=function(X){if(X&&f.isDragging&&!O){var fe=X.target||t.parentNode,re=fe.scrollLeft-fe._gsScrollX,ve=fe.scrollTop-fe._gsScrollY;(re||ve)&&(Ge?(B-=re*Ge.a+ve*Ge.c,F-=ve*Ge.d+re*Ge.b):(B-=re,F-=ve),fe._gsScrollX+=re,fe._gsScrollY+=ve,gl(f.pointerX,f.pointerY))}},_g=function(X){var fe=fo(),re=fe-C<100,ve=fe-g<50,Se=re&&ht===C,Ae=f.pointerEvent&&f.pointerEvent.defaultPrevented,nt=re&&Ji===C,Ne=X.isTrusted||X.isTrusted==null&&re&&Se;if((Se||ve&&f.vars.suppressClickOnDrag!==!1)&&X.stopImmediatePropagation&&X.stopImmediatePropagation(),re&&!(f.pointerEvent&&f.pointerEvent.defaultPrevented)&&(!Se||Ne&&!nt)){Ne&&Se&&(Ji=C),ht=C;return}(f.isPressed||ve||re)&&(!Ne||!X.detail||!re||Ae)&&wn(X),!re&&!ve&&!io&&(X&&X.target&&(f.pointerEvent=X),fr(f,"click","onClick"))},bg=function(X){return Ge?{x:X.x*Ge.a+X.y*Ge.c+Ge.e,y:X.x*Ge.b+X.y*Ge.d+Ge.f}:{x:X.x,y:X.y}};return ze=e.get(t),ze&&ze.kill(),n.startDrag=function(Ve,X){var fe,re,ve,Se;vl(Ve||f.pointerEvent,!0),X&&!f.hitTest(Ve||f.pointerEvent)&&(fe=Rc(Ve||f.pointerEvent),re=Rc(t),ve=bg({x:fe.left+fe.width/2,y:fe.top+fe.height/2}),Se=bg({x:re.left+re.width/2,y:re.top+re.height/2}),B-=ve.x-Se.x,F-=ve.y-Se.y),f.isDragging||(f.isDragging=io=!0,fr(f,"dragstart","onDragStart"))},n.drag=ds,n.endDrag=function(Ve){return en(Ve||f.pointerEvent,!0)},n.timeSinceDrag=function(){return f.isDragging?0:(fo()-g)/1e3},n.timeSinceClick=function(){return(fo()-C)/1e3},n.hitTest=function(Ve,X){return e.hitTest(f.target,Ve,X)},n.getDirection=function(Ve,X){var fe=Ve==="velocity"&&na?Ve:Cp(Ve)&&!o?"element":"start",re,ve,Se,Ae,nt,Ne;return fe==="element"&&(nt=Rc(f.target),Ne=Rc(Ve)),re=fe==="start"?f.x-U:fe==="velocity"?na.getVelocity(t,l):nt.left+nt.width/2-(Ne.left+Ne.width/2),o?re<0?"counter-clockwise":"clockwise":(X=X||2,ve=fe==="start"?f.y-$:fe==="velocity"?na.getVelocity(t,u):nt.top+nt.height/2-(Ne.top+Ne.height/2),Se=Math.abs(re/ve),Ae=Se<1/X?"":re<0?"left":"right",SeQ?fe=Q:fehe?re=he:reAe._gsMaxScrollY&&(Ae.scrollTop=Ae._gsMaxScrollY),c&&Ae.scrollLeft>Ae._gsMaxScrollX&&(Ae.scrollLeft=Ae._gsMaxScrollX),Se=Ae;f.isThrowing&&(ve||f.endX>Q||f.endXhe||f.endY.01||h&&Math.abs(nt-f.y)>.01&&!o)&&yc(),f.autoScroll&&(G2(t.parentNode,f.isDragging),m=f.isDragging,Mi(!0),cP(t,_c),uP(t,_c)),f},n.enable=function(Ve){var X={lazy:!0},fe,re,ve;if(i.cursor!==!1&&(X.cursor=i.cursor||ep),gt.utils.checkPrefix("touchCallout")&&(X.touchCallout="none"),Ve!=="soft"){for(aP(p,c===h?"none":i.allowNativeTouchScrolling&&t.scrollHeight===t.clientHeight==(t.scrollWidth===t.clientHeight)||i.allowEventDefault?"manipulation":c?"pan-y":"pan-x"),re=p.length;--re>-1;)ve=p[re],h0||Pr(ve,"mousedown",vl),Pr(ve,"touchstart",vl),Pr(ve,"click",_g,!0),gt.set(ve,X),ve.getBBox&&ve.ownerSVGElement&&c!==h&>.set(ve.ownerSVGElement,{touchAction:i.allowNativeTouchScrolling||i.allowEventDefault?"manipulation":c?"pan-y":"pan-x"}),i.allowContextMenu||Pr(ve,"contextmenu",gc);Qg(p,!1)}return uP(t,_c),N=!0,na&&Ve!=="soft"&&na.track(O||t,s?"x,y":o?"rotation":"top,left"),t._gsDragID=fe="d"+loe++,Ph[fe]=f,O&&(O.enable(),O.element._gsDragID=fe),(i.bounds||o)&&yc(),i.bounds&&f.applyBounds(),f},n.disable=function(Ve){for(var X=f.isDragging,fe=p.length,re;--fe>-1;)H2(p[fe],"cursor",null);if(Ve!=="soft"){for(aP(p,null),fe=p.length;--fe>-1;)re=p[fe],H2(re,"touchCallout",null),Sr(re,"mousedown",vl),Sr(re,"touchstart",vl),Sr(re,"click",_g,!0),Sr(re,"contextmenu",gc);Qg(p,!0),Re&&(Sr(Re,"touchcancel",en),Sr(Re,"touchend",en),Sr(Re,"touchmove",ds)),Sr(L,"mouseup",en),Sr(L,"mousemove",ds)}return cP(t,_c),N=!1,na&&Ve!=="soft"&&(na.untrack(O||t,s?"x,y":o?"rotation":"top,left"),f.tween&&f.tween.kill()),O&&O.disable(),oP(Mi),f.isDragging=f.isPressed=_t=!1,X&&fr(f,"dragend","onDragEnd"),f},n.enabled=function(Ve,X){return arguments.length?Ve?f.enable(X):f.disable(X):N},n.kill=function(){return f.isThrowing=!1,f.tween&&f.tween.kill(),f.disable(),gt.set(p,{clearProps:"userSelect"}),delete Ph[t._gsDragID],f},n.revert=function(){this.kill(),this.styles&&this.styles.revert()},~a.indexOf("scroll")&&(O=n.scrollProxy=new yoe(t,coe({onKill:function(){f.isPressed&&en(null)}},i)),t.style.overflowY=h&&!px?"auto":"hidden",t.style.overflowX=c&&!px?"auto":"hidden",t=O.content),o?v.rotation=1:(c&&(v[l]=1),h&&(v[u]=1)),D.force3D="force3D"in i?i.force3D:!0,wz(rP(n)),n.enable(),n}return e.register=function(i){gt=i,W2()},e.create=function(i,n){return dx||W2(!0),ko(i).map(function(a){return new e(a,n)})},e.get=function(i){return Ph[(ko(i)[0]||{})._gsDragID]},e.timeSinceDrag=function(){return(fo()-nP)/1e3},e.hitTest=function(i,n,a){if(i===n)return!1;var s=Rc(i),o=Rc(n),l=s.top,u=s.left,c=s.right,h=s.bottom,d=s.width,f=s.height,p=o.left>c||o.righth||o.bottom=d*f*a||g>=o.width*o.height*a):v.width>a&&v.height>a)},e}(_oe);foe(Qu.prototype,{pointerX:0,pointerY:0,startX:0,startY:0,deltaX:0,deltaY:0,isDragging:!1,isPressed:!1});Qu.zIndex=1e3;Qu.version="3.12.5";Az()&>.registerPlugin(Qu);/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */var yx=function(r,e){return yx=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(t[n]=i[n])},yx(r,e)};function j(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");yx(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var boe=function(){function r(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return r}(),Soe=function(){function r(){this.browser=new boe,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<"u"}return r}(),et=new Soe;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(et.wxa=!0,et.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?et.worker=!0:typeof navigator>"u"||navigator.userAgent.indexOf("Node.js")===0?(et.node=!0,et.svgSupported=!0):Toe(navigator.userAgent,et);function Toe(r,e){var t=e.browser,i=r.match(/Firefox\/([\d.]+)/),n=r.match(/MSIE\s([\d.]+)/)||r.match(/Trident\/.+?rv:(([\d.]+))/),a=r.match(/Edge?\/([\d.]+)/),s=/micromessenger/i.test(r);i&&(t.firefox=!0,t.version=i[1]),n&&(t.ie=!0,t.version=n[1]),a&&(t.edge=!0,t.version=a[1],t.newEdge=+a[1].split(".")[0]>18),s&&(t.weChat=!0),e.svgSupported=typeof SVGRect<"u",e.touchEventsSupported="ontouchstart"in window&&!t.ie&&!t.edge,e.pointerEventsSupported="onpointerdown"in window&&(t.edge||t.ie&&+t.version>=11),e.domSupported=typeof document<"u";var o=document.documentElement.style;e.transform3dSupported=(t.ie&&"transition"in o||t.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in o)&&!("OTransition"in o),e.transformSupported=e.transform3dSupported||t.ie&&+t.version>=9}var zA=12,Pz="sans-serif",Jo=zA+"px "+Pz,xoe=20,woe=100,Coe="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function Aoe(r){var e={};if(typeof JSON>"u")return e;for(var t=0;t=0)o=s*t.length;else for(var l=0;l>1)%2;o.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",i[l]+":0",n[u]+":0",i[1-l]+":auto",n[1-u]+":auto",""].join("!important;"),r.appendChild(s),t.push(s)}return t}function joe(r,e,t){for(var i=t?"invTrans":"trans",n=e[i],a=e.srcCoords,s=[],o=[],l=!0,u=0;u<4;u++){var c=r[u].getBoundingClientRect(),h=2*u,d=c.left,f=c.top;s.push(d,f),l=l&&a&&d===a[h]&&f===a[h+1],o.push(r[u].offsetLeft,r[u].offsetTop)}return l&&n?n:(e.srcCoords=s,e[i]=t?gP(o,s):gP(s,o))}function Bz(r){return r.nodeName.toUpperCase()==="CANVAS"}var Xoe=/([&<>"'])/g,Yoe={"&":"&","<":"<",">":">",'"':""","'":"'"};function Bi(r){return r==null?"":(r+"").replace(Xoe,function(e,t){return Yoe[t]})}var Koe=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,j2=[],Zoe=et.browser.firefox&&+et.browser.version.split(".")[0]<39;function Ax(r,e,t,i){return t=t||{},i?yP(r,e,t):Zoe&&e.layerX!=null&&e.layerX!==e.offsetX?(t.zrX=e.layerX,t.zrY=e.layerY):e.offsetX!=null?(t.zrX=e.offsetX,t.zrY=e.offsetY):yP(r,e,t),t}function yP(r,e,t){if(et.domSupported&&r.getBoundingClientRect){var i=e.clientX,n=e.clientY;if(Bz(r)){var a=r.getBoundingClientRect();t.zrX=i-a.left,t.zrY=n-a.top;return}else if(Cx(j2,r,i,n)){t.zrX=j2[0],t.zrY=j2[1];return}}t.zrX=t.zrY=0}function XA(r){return r||window.event}function Ln(r,e,t){if(e=XA(e),e.zrX!=null)return e;var i=e.type,n=i&&i.indexOf("touch")>=0;if(n){var s=i!=="touchend"?e.targetTouches[0]:e.changedTouches[0];s&&Ax(r,s,e,t)}else{Ax(r,e,e,t);var a=Qoe(e);e.zrDelta=a?a/120:-(e.detail||0)/3}var o=e.button;return e.which==null&&o!==void 0&&Koe.test(e.type)&&(e.which=o&1?1:o&2?3:o&4?2:0),e}function Qoe(r){var e=r.wheelDelta;if(e)return e;var t=r.deltaX,i=r.deltaY;if(t==null||i==null)return e;var n=Math.abs(i!==0?i:t),a=i>0?-1:i<0?1:t>0?-1:1;return 3*n*a}function Dx(r,e,t,i){r.addEventListener(e,t,i)}function Joe(r,e,t,i){r.removeEventListener(e,t,i)}var $s=function(r){r.preventDefault(),r.stopPropagation(),r.cancelBubble=!0};function _P(r){return r.which===2||r.which===3}var ele=function(){function r(){this._track=[]}return r.prototype.recognize=function(e,t,i){return this._doTrack(e,t,i),this._recognize(e)},r.prototype.clear=function(){return this._track.length=0,this},r.prototype._doTrack=function(e,t,i){var n=e.touches;if(n){for(var a={points:[],touches:[],target:t,event:e},s=0,o=n.length;s1&&i&&i.length>1){var a=bP(i)/bP(n);!isFinite(a)&&(a=1),e.pinchScale=a;var s=tle(i);return e.pinchX=s[0],e.pinchY=s[1],{type:"pinch",target:r[0].target,event:e}}}}};function vn(){return[1,0,0,1,0,0]}function J_(r){return r[0]=1,r[1]=0,r[2]=0,r[3]=1,r[4]=0,r[5]=0,r}function YA(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4],r[5]=e[5],r}function Rs(r,e,t){var i=e[0]*t[0]+e[2]*t[1],n=e[1]*t[0]+e[3]*t[1],a=e[0]*t[2]+e[2]*t[3],s=e[1]*t[2]+e[3]*t[3],o=e[0]*t[4]+e[2]*t[5]+e[4],l=e[1]*t[4]+e[3]*t[5]+e[5];return r[0]=i,r[1]=n,r[2]=a,r[3]=s,r[4]=o,r[5]=l,r}function ss(r,e,t){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4]+t[0],r[5]=e[5]+t[1],r}function uc(r,e,t,i){i===void 0&&(i=[0,0]);var n=e[0],a=e[2],s=e[4],o=e[1],l=e[3],u=e[5],c=Math.sin(t),h=Math.cos(t);return r[0]=n*h+o*c,r[1]=-n*c+o*h,r[2]=a*h+l*c,r[3]=-a*c+h*l,r[4]=h*(s-i[0])+c*(u-i[1])+i[0],r[5]=h*(u-i[1])-c*(s-i[0])+i[1],r}function KA(r,e,t){var i=t[0],n=t[1];return r[0]=e[0]*i,r[1]=e[1]*n,r[2]=e[2]*i,r[3]=e[3]*n,r[4]=e[4]*i,r[5]=e[5]*n,r}function If(r,e){var t=e[0],i=e[2],n=e[4],a=e[1],s=e[3],o=e[5],l=t*s-a*i;return l?(l=1/l,r[0]=s*l,r[1]=-a*l,r[2]=-i*l,r[3]=t*l,r[4]=(i*o-s*n)*l,r[5]=(a*n-t*o)*l,r):null}function rle(r){var e=vn();return YA(e,r),e}var He=function(){function r(e,t){this.x=e||0,this.y=t||0}return r.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},r.prototype.clone=function(){return new r(this.x,this.y)},r.prototype.set=function(e,t){return this.x=e,this.y=t,this},r.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},r.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},r.prototype.scale=function(e){this.x*=e,this.y*=e},r.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},r.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},r.prototype.dot=function(e){return this.x*e.x+this.y*e.y},r.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},r.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},r.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},r.prototype.distance=function(e){var t=this.x-e.x,i=this.y-e.y;return Math.sqrt(t*t+i*i)},r.prototype.distanceSquare=function(e){var t=this.x-e.x,i=this.y-e.y;return t*t+i*i},r.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},r.prototype.transform=function(e){if(e){var t=this.x,i=this.y;return this.x=e[0]*t+e[2]*i+e[4],this.y=e[1]*t+e[3]*i+e[5],this}},r.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},r.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},r.set=function(e,t,i){e.x=t,e.y=i},r.copy=function(e,t){e.x=t.x,e.y=t.y},r.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},r.lenSquare=function(e){return e.x*e.x+e.y*e.y},r.dot=function(e,t){return e.x*t.x+e.y*t.y},r.add=function(e,t,i){e.x=t.x+i.x,e.y=t.y+i.y},r.sub=function(e,t,i){e.x=t.x-i.x,e.y=t.y-i.y},r.scale=function(e,t,i){e.x=t.x*i,e.y=t.y*i},r.scaleAndAdd=function(e,t,i,n){e.x=t.x+i.x*n,e.y=t.y+i.y*n},r.lerp=function(e,t,i,n){var a=1-n;e.x=a*t.x+n*i.x,e.y=a*t.y+n*i.y},r}(),em=Math.min,tm=Math.max,Dl=new He,El=new He,Il=new He,Pl=new He,dd=new He,pd=new He,qe=function(){function r(e,t,i,n){i<0&&(e=e+i,i=-i),n<0&&(t=t+n,n=-n),this.x=e,this.y=t,this.width=i,this.height=n}return r.prototype.union=function(e){var t=em(e.x,this.x),i=em(e.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=tm(e.x+e.width,this.x+this.width)-t:this.width=e.width,isFinite(this.y)&&isFinite(this.height)?this.height=tm(e.y+e.height,this.y+this.height)-i:this.height=e.height,this.x=t,this.y=i},r.prototype.applyTransform=function(e){r.applyTransform(this,this,e)},r.prototype.calculateTransform=function(e){var t=this,i=e.width/t.width,n=e.height/t.height,a=vn();return ss(a,a,[-t.x,-t.y]),KA(a,a,[i,n]),ss(a,a,[e.x,e.y]),a},r.prototype.intersect=function(e,t){if(!e)return!1;e instanceof r||(e=r.create(e));var i=this,n=i.x,a=i.x+i.width,s=i.y,o=i.y+i.height,l=e.x,u=e.x+e.width,c=e.y,h=e.y+e.height,d=!(ap&&(p=_,vp&&(p=b,m=i.x&&e<=i.x+i.width&&t>=i.y&&t<=i.y+i.height},r.prototype.clone=function(){return new r(this.x,this.y,this.width,this.height)},r.prototype.copy=function(e){r.copy(this,e)},r.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},r.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},r.prototype.isZero=function(){return this.width===0||this.height===0},r.create=function(e){return new r(e.x,e.y,e.width,e.height)},r.copy=function(e,t){e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height},r.applyTransform=function(e,t,i){if(!i){e!==t&&r.copy(e,t);return}if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var n=i[0],a=i[3],s=i[4],o=i[5];e.x=t.x*n+s,e.y=t.y*a+o,e.width=t.width*n,e.height=t.height*a,e.width<0&&(e.x+=e.width,e.width=-e.width),e.height<0&&(e.y+=e.height,e.height=-e.height);return}Dl.x=Il.x=t.x,Dl.y=Pl.y=t.y,El.x=Pl.x=t.x+t.width,El.y=Il.y=t.y+t.height,Dl.transform(i),Pl.transform(i),El.transform(i),Il.transform(i),e.x=em(Dl.x,El.x,Il.x,Pl.x),e.y=em(Dl.y,El.y,Il.y,Pl.y);var l=tm(Dl.x,El.x,Il.x,Pl.x),u=tm(Dl.y,El.y,Il.y,Pl.y);e.width=l-e.x,e.height=u-e.y},r}(),Fz="silent";function ile(r,e,t){return{type:r,event:t,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:t.zrX,offsetY:t.zrY,gestureEvent:t.gestureEvent,pinchX:t.pinchX,pinchY:t.pinchY,pinchScale:t.pinchScale,wheelDelta:t.zrDelta,zrByTouch:t.zrByTouch,which:t.which,stop:nle}}function nle(){$s(this.event)}var ale=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.handler=null,t}return e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e}(Zn),vd=function(){function r(e,t){this.x=e,this.y=t}return r}(),sle=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],Y2=new qe(0,0,0,0),Uz=function(r){j(e,r);function e(t,i,n,a,s){var o=r.call(this)||this;return o._hovered=new vd(0,0),o.storage=t,o.painter=i,o.painterRoot=a,o._pointerSize=s,n=n||new ale,o.proxy=null,o.setHandlerProxy(n),o._draggingMgr=new Hoe(o),o}return e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(R(sle,function(i){t.on&&t.on(i,this[i],this)},this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var i=t.zrX,n=t.zrY,a=Vz(this,i,n),s=this._hovered,o=s.target;o&&!o.__zr&&(s=this.findHover(s.x,s.y),o=s.target);var l=this._hovered=a?new vd(i,n):this.findHover(i,n),u=l.target,c=this.proxy;c.setCursor&&c.setCursor(u?u.cursor:"default"),o&&u!==o&&this.dispatchToElement(s,"mouseout",t),this.dispatchToElement(l,"mousemove",t),u&&u!==o&&this.dispatchToElement(l,"mouseover",t)},e.prototype.mouseout=function(t){var i=t.zrEventControl;i!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",t),i!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new vd(0,0)},e.prototype.dispatch=function(t,i){var n=this[t];n&&n.call(this,i)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var i=this.proxy;i.setCursor&&i.setCursor(t)},e.prototype.dispatchToElement=function(t,i,n){t=t||{};var a=t.target;if(!(a&&a.silent)){for(var s="on"+i,o=ile(i,t,n);a&&(a[s]&&(o.cancelBubble=!!a[s].call(a,o)),a.trigger(i,o),a=a.__hostTarget?a.__hostTarget:a.parent,!o.cancelBubble););o.cancelBubble||(this.trigger(i,o),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[s]=="function"&&l[s].call(l,o),l.trigger&&l.trigger(i,o)}))}},e.prototype.findHover=function(t,i,n){var a=this.storage.getDisplayList(),s=new vd(t,i);if(SP(a,s,t,i,n),this._pointerSize&&!s.target){for(var o=[],l=this._pointerSize,u=l/2,c=new qe(t-u,i-u,l,l),h=a.length-1;h>=0;h--){var d=a[h];d!==n&&!d.ignore&&!d.ignoreCoarsePointer&&(!d.parent||!d.parent.ignoreCoarsePointer)&&(Y2.copy(d.getBoundingRect()),d.transform&&Y2.applyTransform(d.transform),Y2.intersect(c)&&o.push(d))}if(o.length)for(var f=4,p=Math.PI/12,v=Math.PI*2,g=0;g4)return;this._downPoint=null}this.dispatchToElement(a,r,e)}});function ole(r,e,t){if(r[r.rectHover?"rectContain":"contain"](e,t)){for(var i=r,n=void 0,a=!1;i;){if(i.ignoreClip&&(a=!0),!a){var s=i.getClipPath();if(s&&!s.contain(e,t))return!1}i.silent&&(n=!0);var o=i.__hostTarget;i=o||i.parent}return n?Fz:!0}return!1}function SP(r,e,t,i,n){for(var a=r.length-1;a>=0;a--){var s=r[a],o=void 0;if(s!==n&&!s.ignore&&(o=ole(s,t,i))&&(!e.topTarget&&(e.topTarget=s),o!==Fz)){e.target=s;break}}}function Vz(r,e,t){var i=r.painter;return e<0||e>i.getWidth()||t<0||t>i.getHeight()}var zz=32,gd=7;function lle(r){for(var e=0;r>=zz;)e|=r&1,r>>=1;return r+e}function TP(r,e,t,i){var n=e+1;if(n===t)return 1;if(i(r[n++],r[e])<0){for(;n=0;)n++;return n-e}function ule(r,e,t){for(t--;e>>1,n(a,r[l])<0?o=l:s=l+1;var u=i-s;switch(u){case 3:r[s+3]=r[s+2];case 2:r[s+2]=r[s+1];case 1:r[s+1]=r[s];break;default:for(;u>0;)r[s+u]=r[s+u-1],u--}r[s]=a}}function K2(r,e,t,i,n,a){var s=0,o=0,l=1;if(a(r,e[t+n])>0){for(o=i-n;l0;)s=l,l=(l<<1)+1,l<=0&&(l=o);l>o&&(l=o),s+=n,l+=n}else{for(o=n+1;lo&&(l=o);var u=s;s=n-l,l=n-u}for(s++;s>>1);a(r,e[t+c])>0?s=c+1:l=c}return l}function Z2(r,e,t,i,n,a){var s=0,o=0,l=1;if(a(r,e[t+n])<0){for(o=n+1;lo&&(l=o);var u=s;s=n-l,l=n-u}else{for(o=i-n;l=0;)s=l,l=(l<<1)+1,l<=0&&(l=o);l>o&&(l=o),s+=n,l+=n}for(s++;s>>1);a(r,e[t+c])<0?l=c:s=c+1}return l}function cle(r,e){var t=gd,i,n,a=0,s=[];i=[],n=[];function o(f,p){i[a]=f,n[a]=p,a+=1}function l(){for(;a>1;){var f=a-2;if(f>=1&&n[f-1]<=n[f]+n[f+1]||f>=2&&n[f-2]<=n[f]+n[f-1])n[f-1]n[f+1])break;c(f)}}function u(){for(;a>1;){var f=a-2;f>0&&n[f-1]=gd||C>=gd);if(D)break;T<0&&(T=0),T+=2}if(t=T,t<1&&(t=1),p===1){for(m=0;m=0;m--)r[x+m]=r[T+m];r[b]=s[_];return}for(var C=t;;){var D=0,I=0,M=!1;do if(e(s[_],r[y])<0){if(r[b--]=r[y--],D++,I=0,--p===0){M=!0;break}}else if(r[b--]=s[_--],I++,D=0,--g===1){M=!0;break}while((D|I)=0;m--)r[x+m]=r[T+m];if(p===0){M=!0;break}}if(r[b--]=s[_--],--g===1){M=!0;break}if(I=g-K2(r[y],s,0,g,g-1,e),I!==0){for(b-=I,_-=I,g-=I,x=b+1,T=_+1,m=0;m=gd||I>=gd);if(M)break;C<0&&(C=0),C+=2}if(t=C,t<1&&(t=1),g===1){for(b-=p,y-=p,x=b+1,T=y+1,m=p-1;m>=0;m--)r[x+m]=r[T+m];r[b]=s[_]}else{if(g===0)throw new Error;for(T=b-(g-1),m=0;mo&&(l=o),xP(r,t,t+l,t+a,e),a=l}s.pushRun(t,a),s.mergeRuns(),n-=a,t+=a}while(n!==0);s.forceMergeRuns()}}var cn=1,tp=2,nh=4,wP=!1;function Q2(){wP||(wP=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function CP(r,e){return r.zlevel===e.zlevel?r.z===e.z?r.z2-e.z2:r.z-e.z:r.zlevel-e.zlevel}var hle=function(){function r(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=CP}return r.prototype.traverse=function(e,t){for(var i=0;i0&&(c.__clipPaths=[]),isNaN(c.z)&&(Q2(),c.z=0),isNaN(c.z2)&&(Q2(),c.z2=0),isNaN(c.zlevel)&&(Q2(),c.zlevel=0),this._displayList[this._displayListLen++]=c}var h=e.getDecalElement&&e.getDecalElement();h&&this._updateAndAddDisplayable(h,t,i);var d=e.getTextGuideLine();d&&this._updateAndAddDisplayable(d,t,i);var f=e.getTextContent();f&&this._updateAndAddDisplayable(f,t,i)}},r.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},r.prototype.delRoot=function(e){if(e instanceof Array){for(var t=0,i=e.length;t=0&&this._roots.splice(n,1)},r.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},r.prototype.getRoots=function(){return this._roots},r.prototype.dispose=function(){this._displayList=null,this._roots=null},r}(),Ty;Ty=et.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(r){return setTimeout(r,16)};var Ep={linear:function(r){return r},quadraticIn:function(r){return r*r},quadraticOut:function(r){return r*(2-r)},quadraticInOut:function(r){return(r*=2)<1?.5*r*r:-.5*(--r*(r-2)-1)},cubicIn:function(r){return r*r*r},cubicOut:function(r){return--r*r*r+1},cubicInOut:function(r){return(r*=2)<1?.5*r*r*r:.5*((r-=2)*r*r+2)},quarticIn:function(r){return r*r*r*r},quarticOut:function(r){return 1- --r*r*r*r},quarticInOut:function(r){return(r*=2)<1?.5*r*r*r*r:-.5*((r-=2)*r*r*r-2)},quinticIn:function(r){return r*r*r*r*r},quinticOut:function(r){return--r*r*r*r*r+1},quinticInOut:function(r){return(r*=2)<1?.5*r*r*r*r*r:.5*((r-=2)*r*r*r*r+2)},sinusoidalIn:function(r){return 1-Math.cos(r*Math.PI/2)},sinusoidalOut:function(r){return Math.sin(r*Math.PI/2)},sinusoidalInOut:function(r){return .5*(1-Math.cos(Math.PI*r))},exponentialIn:function(r){return r===0?0:Math.pow(1024,r-1)},exponentialOut:function(r){return r===1?1:1-Math.pow(2,-10*r)},exponentialInOut:function(r){return r===0?0:r===1?1:(r*=2)<1?.5*Math.pow(1024,r-1):.5*(-Math.pow(2,-10*(r-1))+2)},circularIn:function(r){return 1-Math.sqrt(1-r*r)},circularOut:function(r){return Math.sqrt(1- --r*r)},circularInOut:function(r){return(r*=2)<1?-.5*(Math.sqrt(1-r*r)-1):.5*(Math.sqrt(1-(r-=2)*r)+1)},elasticIn:function(r){var e,t=.1,i=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=i/4):e=i*Math.asin(1/t)/(2*Math.PI),-(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/i)))},elasticOut:function(r){var e,t=.1,i=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=i/4):e=i*Math.asin(1/t)/(2*Math.PI),t*Math.pow(2,-10*r)*Math.sin((r-e)*(2*Math.PI)/i)+1)},elasticInOut:function(r){var e,t=.1,i=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=i/4):e=i*Math.asin(1/t)/(2*Math.PI),(r*=2)<1?-.5*(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/i)):t*Math.pow(2,-10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/i)*.5+1)},backIn:function(r){var e=1.70158;return r*r*((e+1)*r-e)},backOut:function(r){var e=1.70158;return--r*r*((e+1)*r+e)+1},backInOut:function(r){var e=2.5949095;return(r*=2)<1?.5*(r*r*((e+1)*r-e)):.5*((r-=2)*r*((e+1)*r+e)+2)},bounceIn:function(r){return 1-Ep.bounceOut(1-r)},bounceOut:function(r){return r<1/2.75?7.5625*r*r:r<2/2.75?7.5625*(r-=1.5/2.75)*r+.75:r<2.5/2.75?7.5625*(r-=2.25/2.75)*r+.9375:7.5625*(r-=2.625/2.75)*r+.984375},bounceInOut:function(r){return r<.5?Ep.bounceIn(r*2)*.5:Ep.bounceOut(r*2-1)*.5+.5}},rm=Math.pow,Wo=Math.sqrt,xy=1e-8,Gz=1e-4,AP=Wo(3),im=1/3,Fa=lc(),Nn=lc(),kh=lc();function Bo(r){return r>-xy&&rxy||r<-xy}function Mr(r,e,t,i,n){var a=1-n;return a*a*(a*r+3*n*e)+n*n*(n*i+3*a*t)}function DP(r,e,t,i,n){var a=1-n;return 3*(((e-r)*a+2*(t-e)*n)*a+(i-t)*n*n)}function wy(r,e,t,i,n,a){var s=i+3*(e-t)-r,o=3*(t-e*2+r),l=3*(e-r),u=r-n,c=o*o-3*s*l,h=o*l-9*s*u,d=l*l-3*o*u,f=0;if(Bo(c)&&Bo(h))if(Bo(o))a[0]=0;else{var p=-l/o;p>=0&&p<=1&&(a[f++]=p)}else{var v=h*h-4*c*d;if(Bo(v)){var g=h/c,p=-o/s+g,m=-g/2;p>=0&&p<=1&&(a[f++]=p),m>=0&&m<=1&&(a[f++]=m)}else if(v>0){var y=Wo(v),_=c*o+1.5*s*(-h+y),b=c*o+1.5*s*(-h-y);_<0?_=-rm(-_,im):_=rm(_,im),b<0?b=-rm(-b,im):b=rm(b,im);var p=(-o-(_+b))/(3*s);p>=0&&p<=1&&(a[f++]=p)}else{var T=(2*c*o-3*s*h)/(2*Wo(c*c*c)),x=Math.acos(T)/3,C=Wo(c),D=Math.cos(x),p=(-o-2*C*D)/(3*s),m=(-o+C*(D+AP*Math.sin(x)))/(3*s),I=(-o+C*(D-AP*Math.sin(x)))/(3*s);p>=0&&p<=1&&(a[f++]=p),m>=0&&m<=1&&(a[f++]=m),I>=0&&I<=1&&(a[f++]=I)}}return f}function $z(r,e,t,i,n){var a=6*t-12*e+6*r,s=9*e+3*i-3*r-9*t,o=3*e-3*r,l=0;if(Bo(s)){if(Hz(a)){var u=-o/a;u>=0&&u<=1&&(n[l++]=u)}}else{var c=a*a-4*s*o;if(Bo(c))n[0]=-a/(2*s);else if(c>0){var h=Wo(c),u=(-a+h)/(2*s),d=(-a-h)/(2*s);u>=0&&u<=1&&(n[l++]=u),d>=0&&d<=1&&(n[l++]=d)}}return l}function tl(r,e,t,i,n,a){var s=(e-r)*n+r,o=(t-e)*n+e,l=(i-t)*n+t,u=(o-s)*n+s,c=(l-o)*n+o,h=(c-u)*n+u;a[0]=r,a[1]=s,a[2]=u,a[3]=h,a[4]=h,a[5]=c,a[6]=l,a[7]=i}function Wz(r,e,t,i,n,a,s,o,l,u,c){var h,d=.005,f=1/0,p,v,g,m;Fa[0]=l,Fa[1]=u;for(var y=0;y<1;y+=.05)Nn[0]=Mr(r,t,n,s,y),Nn[1]=Mr(e,i,a,o,y),g=Bu(Fa,Nn),g=0&&g=0&&u<=1&&(n[l++]=u)}}else{var c=s*s-4*a*o;if(Bo(c)){var u=-s/(2*a);u>=0&&u<=1&&(n[l++]=u)}else if(c>0){var h=Wo(c),u=(-s+h)/(2*a),d=(-s-h)/(2*a);u>=0&&u<=1&&(n[l++]=u),d>=0&&d<=1&&(n[l++]=d)}}return l}function qz(r,e,t){var i=r+t-2*e;return i===0?.5:(r-e)/i}function lv(r,e,t,i,n){var a=(e-r)*i+r,s=(t-e)*i+e,o=(s-a)*i+a;n[0]=r,n[1]=a,n[2]=o,n[3]=o,n[4]=s,n[5]=t}function jz(r,e,t,i,n,a,s,o,l){var u,c=.005,h=1/0;Fa[0]=s,Fa[1]=o;for(var d=0;d<1;d+=.05){Nn[0]=Ur(r,t,n,d),Nn[1]=Ur(e,i,a,d);var f=Bu(Fa,Nn);f=0&&f=1?1:wy(0,i,a,1,l,o)&&Mr(0,n,s,1,o[0])}}}var gle=function(){function r(e){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=e.life||1e3,this._delay=e.delay||0,this.loop=e.loop||!1,this.onframe=e.onframe||lr,this.ondestroy=e.ondestroy||lr,this.onrestart=e.onrestart||lr,e.easing&&this.setEasing(e.easing)}return r.prototype.step=function(e,t){if(this._inited||(this._startTime=e+this._delay,this._inited=!0),this._paused){this._pausedTime+=t;return}var i=this._life,n=e-this._startTime-this._pausedTime,a=n/i;a<0&&(a=0),a=Math.min(a,1);var s=this.easingFunc,o=s?s(a):a;if(this.onframe(o),a===1)if(this.loop){var l=n%i;this._startTime=e-l,this._pausedTime=0,this.onrestart()}else return!0;return!1},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){this._paused=!1},r.prototype.setEasing=function(e){this.easing=e,this.easingFunc=we(e)?e:Ep[e]||ZA(e)},r}(),Xz=function(){function r(e){this.value=e}return r}(),mle=function(){function r(){this._len=0}return r.prototype.insert=function(e){var t=new Xz(e);return this.insertEntry(t),t},r.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},r.prototype.remove=function(e){var t=e.prev,i=e.next;t?t.next=i:this.head=i,i?i.prev=t:this.tail=t,e.next=e.prev=null,this._len--},r.prototype.len=function(){return this._len},r.prototype.clear=function(){this.head=this.tail=null,this._len=0},r}(),Yv=function(){function r(e){this._list=new mle,this._maxSize=10,this._map={},this._maxSize=e}return r.prototype.put=function(e,t){var i=this._list,n=this._map,a=null;if(n[e]==null){var s=i.len(),o=this._lastRemovedEntry;if(s>=this._maxSize&&s>0){var l=i.head;i.remove(l),delete n[l.key],a=l.value,this._lastRemovedEntry=l}o?o.value=t:o=new Xz(t),o.key=e,i.insertEntry(o),n[e]=o}return a},r.prototype.get=function(e){var t=this._map[e],i=this._list;if(t!=null)return t!==i.tail&&(i.remove(t),i.insertEntry(t)),t.value},r.prototype.clear=function(){this._list.clear(),this._map={}},r.prototype.len=function(){return this._list.len()},r}(),EP={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function ga(r){return r=Math.round(r),r<0?0:r>255?255:r}function yle(r){return r=Math.round(r),r<0?0:r>360?360:r}function uv(r){return r<0?0:r>1?1:r}function J2(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?ga(parseFloat(e)/100*255):ga(parseInt(e,10))}function Fu(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?uv(parseFloat(e)/100):uv(parseFloat(e))}function eb(r,e,t){return t<0?t+=1:t>1&&(t-=1),t*6<1?r+(e-r)*t*6:t*2<1?e:t*3<2?r+(e-r)*(2/3-t)*6:r}function Fo(r,e,t){return r+(e-r)*t}function Pn(r,e,t,i,n){return r[0]=e,r[1]=t,r[2]=i,r[3]=n,r}function Ix(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r}var Yz=new Yv(20),nm=null;function Nc(r,e){nm&&Ix(nm,e),nm=Yz.put(r,nm||e.slice())}function gn(r,e){if(r){e=e||[];var t=Yz.get(r);if(t)return Ix(e,t);r=r+"";var i=r.replace(/ /g,"").toLowerCase();if(i in EP)return Ix(e,EP[i]),Nc(r,e),e;var n=i.length;if(i.charAt(0)==="#"){if(n===4||n===5){var a=parseInt(i.slice(1,4),16);if(!(a>=0&&a<=4095)){Pn(e,0,0,0,1);return}return Pn(e,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,n===5?parseInt(i.slice(4),16)/15:1),Nc(r,e),e}else if(n===7||n===9){var a=parseInt(i.slice(1,7),16);if(!(a>=0&&a<=16777215)){Pn(e,0,0,0,1);return}return Pn(e,(a&16711680)>>16,(a&65280)>>8,a&255,n===9?parseInt(i.slice(7),16)/255:1),Nc(r,e),e}return}var s=i.indexOf("("),o=i.indexOf(")");if(s!==-1&&o+1===n){var l=i.substr(0,s),u=i.substr(s+1,o-(s+1)).split(","),c=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?Pn(e,+u[0],+u[1],+u[2],1):Pn(e,0,0,0,1);c=Fu(u.pop());case"rgb":if(u.length>=3)return Pn(e,J2(u[0]),J2(u[1]),J2(u[2]),u.length===3?c:Fu(u[3])),Nc(r,e),e;Pn(e,0,0,0,1);return;case"hsla":if(u.length!==4){Pn(e,0,0,0,1);return}return u[3]=Fu(u[3]),Px(u,e),Nc(r,e),e;case"hsl":if(u.length!==3){Pn(e,0,0,0,1);return}return Px(u,e),Nc(r,e),e;default:return}}Pn(e,0,0,0,1)}}function Px(r,e){var t=(parseFloat(r[0])%360+360)%360/360,i=Fu(r[1]),n=Fu(r[2]),a=n<=.5?n*(i+1):n+i-n*i,s=n*2-a;return e=e||[],Pn(e,ga(eb(s,a,t+1/3)*255),ga(eb(s,a,t)*255),ga(eb(s,a,t-1/3)*255),1),r.length===4&&(e[3]=r[3]),e}function _le(r){if(r){var e=r[0]/255,t=r[1]/255,i=r[2]/255,n=Math.min(e,t,i),a=Math.max(e,t,i),s=a-n,o=(a+n)/2,l,u;if(s===0)l=0,u=0;else{o<.5?u=s/(a+n):u=s/(2-a-n);var c=((a-e)/6+s/2)/s,h=((a-t)/6+s/2)/s,d=((a-i)/6+s/2)/s;e===a?l=d-h:t===a?l=1/3+c-d:i===a&&(l=2/3+h-c),l<0&&(l+=1),l>1&&(l-=1)}var f=[l*360,u,o];return r[3]!=null&&f.push(r[3]),f}}function Mx(r,e){var t=gn(r);if(t){for(var i=0;i<3;i++)e<0?t[i]=t[i]*(1-e)|0:t[i]=(255-t[i])*e+t[i]|0,t[i]>255?t[i]=255:t[i]<0&&(t[i]=0);return Os(t,t.length===4?"rgba":"rgb")}}function tb(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){t=t||[];var i=r*(e.length-1),n=Math.floor(i),a=Math.ceil(i),s=e[n],o=e[a],l=i-n;return t[0]=ga(Fo(s[0],o[0],l)),t[1]=ga(Fo(s[1],o[1],l)),t[2]=ga(Fo(s[2],o[2],l)),t[3]=uv(Fo(s[3],o[3],l)),t}}function ble(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){var i=r*(e.length-1),n=Math.floor(i),a=Math.ceil(i),s=gn(e[n]),o=gn(e[a]),l=i-n,u=Os([ga(Fo(s[0],o[0],l)),ga(Fo(s[1],o[1],l)),ga(Fo(s[2],o[2],l)),uv(Fo(s[3],o[3],l))],"rgba");return t?{color:u,leftIndex:n,rightIndex:a,value:i}:u}}function Ip(r,e,t,i){var n=gn(r);if(r)return n=_le(n),e!=null&&(n[0]=yle(e)),t!=null&&(n[1]=Fu(t)),i!=null&&(n[2]=Fu(i)),Os(Px(n),"rgba")}function Cy(r,e){var t=gn(r);if(t&&e!=null)return t[3]=uv(e),Os(t,"rgba")}function Os(r,e){if(!(!r||!r.length)){var t=r[0]+","+r[1]+","+r[2];return(e==="rgba"||e==="hsva"||e==="hsla")&&(t+=","+r[3]),e+"("+t+")"}}function Ay(r,e){var t=gn(r);return t?(.299*t[0]+.587*t[1]+.114*t[2])*t[3]/255+(1-t[3])*e:0}var IP=new Yv(100);function Lx(r){if(pe(r)){var e=IP.get(r);return e||(e=Mx(r,-.1),IP.put(r,e)),e}else if(Z_(r)){var t=J({},r);return t.colorStops=oe(r.colorStops,function(i){return{offset:i.offset,color:Mx(i.color,-.1)}}),t}return r}var Dy=Math.round;function cv(r){var e;if(!r||r==="transparent")r="none";else if(typeof r=="string"&&r.indexOf("rgba")>-1){var t=gn(r);t&&(r="rgb("+t[0]+","+t[1]+","+t[2]+")",e=t[3])}return{color:r,opacity:e??1}}var PP=1e-4;function Uo(r){return r-PP}function am(r){return Dy(r*1e3)/1e3}function kx(r){return Dy(r*1e4)/1e4}function Sle(r){return"matrix("+am(r[0])+","+am(r[1])+","+am(r[2])+","+am(r[3])+","+kx(r[4])+","+kx(r[5])+")"}var Tle={left:"start",right:"end",center:"middle",middle:"middle"};function xle(r,e,t){return t==="top"?r+=e/2:t==="bottom"&&(r-=e/2),r}function wle(r){return r&&(r.shadowBlur||r.shadowOffsetX||r.shadowOffsetY)}function Cle(r){var e=r.style,t=r.getGlobalScale();return[e.shadowColor,(e.shadowBlur||0).toFixed(2),(e.shadowOffsetX||0).toFixed(2),(e.shadowOffsetY||0).toFixed(2),t[0],t[1]].join(",")}function Kz(r){return r&&!!r.image}function Ale(r){return r&&!!r.svgElement}function QA(r){return Kz(r)||Ale(r)}function Zz(r){return r.type==="linear"}function Qz(r){return r.type==="radial"}function Jz(r){return r&&(r.type==="linear"||r.type==="radial")}function e1(r){return"url(#"+r+")"}function eG(r){var e=r.getGlobalScale(),t=Math.max(e[0],e[1]);return Math.max(Math.ceil(Math.log(t)/Math.log(10)),1)}function tG(r){var e=r.x||0,t=r.y||0,i=(r.rotation||0)*d0,n=Be(r.scaleX,1),a=Be(r.scaleY,1),s=r.skewX||0,o=r.skewY||0,l=[];return(e||t)&&l.push("translate("+e+"px,"+t+"px)"),i&&l.push("rotate("+i+")"),(n!==1||a!==1)&&l.push("scale("+n+","+a+")"),(s||o)&&l.push("skew("+Dy(s*d0)+"deg, "+Dy(o*d0)+"deg)"),l.join(" ")}var Dle=function(){return et.hasGlobalWindow&&we(window.btoa)?function(r){return window.btoa(unescape(encodeURIComponent(r)))}:typeof Buffer<"u"?function(r){return Buffer.from(r).toString("base64")}:function(r){return null}}(),Rx=Array.prototype.slice;function Ss(r,e,t){return(e-r)*t+r}function rb(r,e,t,i){for(var n=e.length,a=0;ai?e:r,a=Math.min(t,i),s=n[a-1]||{color:[0,0,0,0],offset:0},o=a;os;if(o)i.length=s;else for(var l=a;l=1},r.prototype.getAdditiveTrack=function(){return this._additiveTrack},r.prototype.addKeyframe=function(e,t,i){this._needsSort=!0;var n=this.keyframes,a=n.length,s=!1,o=LP,l=t;if(li(t)){var u=Mle(t);o=u,(u===1&&!ut(t[0])||u===2&&!ut(t[0][0]))&&(s=!0)}else if(ut(t)&&!ov(t))o=om;else if(pe(t))if(!isNaN(+t))o=om;else{var c=gn(t);c&&(l=c,o=rp)}else if(Z_(t)){var h=J({},l);h.colorStops=oe(t.colorStops,function(f){return{offset:f.offset,color:gn(f.color)}}),Zz(t)?o=Ox:Qz(t)&&(o=Nx),l=h}a===0?this.valType=o:(o!==this.valType||o===LP)&&(s=!0),this.discrete=this.discrete||s;var d={time:e,value:l,rawValue:t,percent:0};return i&&(d.easing=i,d.easingFunc=we(i)?i:Ep[i]||ZA(i)),n.push(d),d},r.prototype.prepare=function(e,t){var i=this.keyframes;this._needsSort&&i.sort(function(v,g){return v.time-g.time});for(var n=this.valType,a=i.length,s=i[a-1],o=this.discrete,l=lm(n),u=kP(n),c=0;c=0&&!(s[c].percent<=t);c--);c=d(c,o-2)}else{for(c=h;ct);c++);c=d(c-1,o-2)}p=s[c+1],f=s[c]}if(f&&p){this._lastFr=c,this._lastFrP=t;var g=p.percent-f.percent,m=g===0?1:d((t-f.percent)/g,1);p.easingFunc&&(m=p.easingFunc(m));var y=i?this._additiveValue:u?md:e[l];if((lm(a)||u)&&!y&&(y=this._additiveValue=[]),this.discrete)e[l]=m<1?f.rawValue:p.rawValue;else if(lm(a))a===y0?rb(y,f[n],p[n],m):Ele(y,f[n],p[n],m);else if(kP(a)){var _=f[n],b=p[n],T=a===Ox;e[l]={type:T?"linear":"radial",x:Ss(_.x,b.x,m),y:Ss(_.y,b.y,m),colorStops:oe(_.colorStops,function(C,D){var I=b.colorStops[D];return{offset:Ss(C.offset,I.offset,m),color:m0(rb([],C.color,I.color,m))}}),global:b.global},T?(e[l].x2=Ss(_.x2,b.x2,m),e[l].y2=Ss(_.y2,b.y2,m)):e[l].r=Ss(_.r,b.r,m)}else if(u)rb(y,f[n],p[n],m),i||(e[l]=m0(y));else{var x=Ss(f[n],p[n],m);i?this._additiveValue=x:e[l]=x}i&&this._addToTarget(e)}}},r.prototype._addToTarget=function(e){var t=this.valType,i=this.propName,n=this._additiveValue;t===om?e[i]=e[i]+n:t===rp?(gn(e[i],md),sm(md,md,n,1),e[i]=m0(md)):t===y0?sm(e[i],e[i],n,1):t===rG&&MP(e[i],e[i],n,1)},r}(),JA=function(){function r(e,t,i,n){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=e,this._loop=t,t&&n){$A("Can' use additive animation on looped animation.");return}this._additiveAnimators=n,this._allowDiscrete=i}return r.prototype.getMaxTime=function(){return this._maxTime},r.prototype.getDelay=function(){return this._delay},r.prototype.getLoop=function(){return this._loop},r.prototype.getTarget=function(){return this._target},r.prototype.changeTarget=function(e){this._target=e},r.prototype.when=function(e,t,i){return this.whenWithKeys(e,t,rt(t),i)},r.prototype.whenWithKeys=function(e,t,i,n){for(var a=this._tracks,s=0;s0&&l.addKeyframe(0,Pp(u),n),this._trackKeys.push(o)}l.addKeyframe(e,Pp(t[o]),n)}return this._maxTime=Math.max(this._maxTime,e),this},r.prototype.pause=function(){this._clip.pause(),this._paused=!0},r.prototype.resume=function(){this._clip.resume(),this._paused=!1},r.prototype.isPaused=function(){return!!this._paused},r.prototype.duration=function(e){return this._maxTime=e,this._force=!0,this},r.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var e=this._doneCbs;if(e)for(var t=e.length,i=0;i0)){this._started=1;for(var t=this,i=[],n=this._maxTime||0,a=0;a1){var o=s.pop();a.addKeyframe(o.time,e[n]),a.prepare(this._maxTime,a.getAdditiveTrack())}}}},r}();function gh(){return new Date().getTime()}var kle=function(r){j(e,r);function e(t){var i=r.call(this)||this;return i._running=!1,i._time=0,i._pausedTime=0,i._pauseStart=0,i._paused=!1,t=t||{},i.stage=t.stage||{},i}return e.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?(this._tail.next=t,t.prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},e.prototype.addAnimator=function(t){t.animation=this;var i=t.getClip();i&&this.addClip(i)},e.prototype.removeClip=function(t){if(t.animation){var i=t.prev,n=t.next;i?i.next=n:this._head=n,n?n.prev=i:this._tail=i,t.next=t.prev=t.animation=null}},e.prototype.removeAnimator=function(t){var i=t.getClip();i&&this.removeClip(i),t.animation=null},e.prototype.update=function(t){for(var i=gh()-this._pausedTime,n=i-this._time,a=this._head;a;){var s=a.next,o=a.step(i,n);o&&(a.ondestroy(),this.removeClip(a)),a=s}this._time=i,t||(this.trigger("frame",n),this.stage.update&&this.stage.update())},e.prototype._startLoop=function(){var t=this;this._running=!0;function i(){t._running&&(Ty(i),!t._paused&&t.update())}Ty(i)},e.prototype.start=function(){this._running||(this._time=gh(),this._pausedTime=0,this._startLoop())},e.prototype.stop=function(){this._running=!1},e.prototype.pause=function(){this._paused||(this._pauseStart=gh(),this._paused=!0)},e.prototype.resume=function(){this._paused&&(this._pausedTime+=gh()-this._pauseStart,this._paused=!1)},e.prototype.clear=function(){for(var t=this._head;t;){var i=t.next;t.prev=t.next=t.animation=null,t=i}this._head=this._tail=null},e.prototype.isFinished=function(){return this._head==null},e.prototype.animate=function(t,i){i=i||{},this.start();var n=new JA(t,i.loop);return this.addAnimator(n),n},e}(Zn),Rle=300,ib=et.domSupported,nb=function(){var r=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],e=["touchstart","touchend","touchmove"],t={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},i=oe(r,function(n){var a=n.replace("mouse","pointer");return t.hasOwnProperty(a)?a:n});return{mouse:r,touch:e,pointer:i}}(),RP={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},OP=!1;function Bx(r){var e=r.pointerType;return e==="pen"||e==="touch"}function Ole(r){r.touching=!0,r.touchTimer!=null&&(clearTimeout(r.touchTimer),r.touchTimer=null),r.touchTimer=setTimeout(function(){r.touching=!1,r.touchTimer=null},700)}function ab(r){r&&(r.zrByTouch=!0)}function Nle(r,e){return Ln(r.dom,new Ble(r,e),!0)}function iG(r,e){for(var t=e,i=!1;t&&t.nodeType!==9&&!(i=t.domBelongToZr||t!==e&&t===r.painterRoot);)t=t.parentNode;return i}var Ble=function(){function r(e,t){this.stopPropagation=lr,this.stopImmediatePropagation=lr,this.preventDefault=lr,this.type=t.type,this.target=this.currentTarget=e.dom,this.pointerType=t.pointerType,this.clientX=t.clientX,this.clientY=t.clientY}return r}(),sa={mousedown:function(r){r=Ln(this.dom,r),this.__mayPointerCapture=[r.zrX,r.zrY],this.trigger("mousedown",r)},mousemove:function(r){r=Ln(this.dom,r);var e=this.__mayPointerCapture;e&&(r.zrX!==e[0]||r.zrY!==e[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",r)},mouseup:function(r){r=Ln(this.dom,r),this.__togglePointerCapture(!1),this.trigger("mouseup",r)},mouseout:function(r){r=Ln(this.dom,r);var e=r.toElement||r.relatedTarget;iG(this,e)||(this.__pointerCapturing&&(r.zrEventControl="no_globalout"),this.trigger("mouseout",r))},wheel:function(r){OP=!0,r=Ln(this.dom,r),this.trigger("mousewheel",r)},mousewheel:function(r){OP||(r=Ln(this.dom,r),this.trigger("mousewheel",r))},touchstart:function(r){r=Ln(this.dom,r),ab(r),this.__lastTouchMoment=new Date,this.handler.processGesture(r,"start"),sa.mousemove.call(this,r),sa.mousedown.call(this,r)},touchmove:function(r){r=Ln(this.dom,r),ab(r),this.handler.processGesture(r,"change"),sa.mousemove.call(this,r)},touchend:function(r){r=Ln(this.dom,r),ab(r),this.handler.processGesture(r,"end"),sa.mouseup.call(this,r),+new Date-+this.__lastTouchMomentFP||r<-FP}var Ll=[],Bc=[],ob=vn(),lb=Math.abs,Is=function(){function r(){}return r.prototype.getLocalTransform=function(e){return r.getLocalTransform(this,e)},r.prototype.setPosition=function(e){this.x=e[0],this.y=e[1]},r.prototype.setScale=function(e){this.scaleX=e[0],this.scaleY=e[1]},r.prototype.setSkew=function(e){this.skewX=e[0],this.skewY=e[1]},r.prototype.setOrigin=function(e){this.originX=e[0],this.originY=e[1]},r.prototype.needLocalTransform=function(){return Ml(this.rotation)||Ml(this.x)||Ml(this.y)||Ml(this.scaleX-1)||Ml(this.scaleY-1)||Ml(this.skewX)||Ml(this.skewY)},r.prototype.updateTransform=function(){var e=this.parent&&this.parent.transform,t=this.needLocalTransform(),i=this.transform;if(!(t||e)){i&&(BP(i),this.invTransform=null);return}i=i||vn(),t?this.getLocalTransform(i):BP(i),e&&(t?Rs(i,e,i):YA(i,e)),this.transform=i,this._resolveGlobalScaleRatio(i)},r.prototype._resolveGlobalScaleRatio=function(e){var t=this.globalScaleRatio;if(t!=null&&t!==1){this.getGlobalScale(Ll);var i=Ll[0]<0?-1:1,n=Ll[1]<0?-1:1,a=((Ll[0]-i)*t+i)/Ll[0]||0,s=((Ll[1]-n)*t+n)/Ll[1]||0;e[0]*=a,e[1]*=a,e[2]*=s,e[3]*=s}this.invTransform=this.invTransform||vn(),If(this.invTransform,e)},r.prototype.getComputedTransform=function(){for(var e=this,t=[];e;)t.push(e),e=e.parent;for(;e=t.pop();)e.updateTransform();return this.transform},r.prototype.setLocalTransform=function(e){if(e){var t=e[0]*e[0]+e[1]*e[1],i=e[2]*e[2]+e[3]*e[3],n=Math.atan2(e[1],e[0]),a=Math.PI/2+n-Math.atan2(e[3],e[2]);i=Math.sqrt(i)*Math.cos(a),t=Math.sqrt(t),this.skewX=a,this.skewY=0,this.rotation=-n,this.x=+e[4],this.y=+e[5],this.scaleX=t,this.scaleY=i,this.originX=0,this.originY=0}},r.prototype.decomposeTransform=function(){if(this.transform){var e=this.parent,t=this.transform;e&&e.transform&&(e.invTransform=e.invTransform||vn(),Rs(Bc,e.invTransform,t),t=Bc);var i=this.originX,n=this.originY;(i||n)&&(ob[4]=i,ob[5]=n,Rs(Bc,t,ob),Bc[4]-=i,Bc[5]-=n,t=Bc),this.setLocalTransform(t)}},r.prototype.getGlobalScale=function(e){var t=this.transform;return e=e||[],t?(e[0]=Math.sqrt(t[0]*t[0]+t[1]*t[1]),e[1]=Math.sqrt(t[2]*t[2]+t[3]*t[3]),t[0]<0&&(e[0]=-e[0]),t[3]<0&&(e[1]=-e[1]),e):(e[0]=1,e[1]=1,e)},r.prototype.transformCoordToLocal=function(e,t){var i=[e,t],n=this.invTransform;return n&&Zr(i,i,n),i},r.prototype.transformCoordToGlobal=function(e,t){var i=[e,t],n=this.transform;return n&&Zr(i,i,n),i},r.prototype.getLineScale=function(){var e=this.transform;return e&&lb(e[0]-1)>1e-10&&lb(e[3]-1)>1e-10?Math.sqrt(lb(e[0]*e[3]-e[2]*e[1])):1},r.prototype.copyTransform=function(e){aG(this,e)},r.getLocalTransform=function(e,t){t=t||[];var i=e.originX||0,n=e.originY||0,a=e.scaleX,s=e.scaleY,o=e.anchorX,l=e.anchorY,u=e.rotation||0,c=e.x,h=e.y,d=e.skewX?Math.tan(e.skewX):0,f=e.skewY?Math.tan(-e.skewY):0;if(i||n||o||l){var p=i+o,v=n+l;t[4]=-p*a-d*v*s,t[5]=-v*s-f*p*a}else t[4]=t[5]=0;return t[0]=a,t[3]=s,t[1]=f*a,t[2]=d*s,u&&uc(t,t,u),t[4]+=i+c,t[5]+=n+h,t},r.initDefaultProps=function(){var e=r.prototype;e.scaleX=e.scaleY=e.globalScaleRatio=1,e.x=e.y=e.originX=e.originY=e.skewX=e.skewY=e.rotation=e.anchorX=e.anchorY=0}(),r}(),os=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function aG(r,e){for(var t=0;t=0?parseFloat(r)/100*e:parseFloat(r):r}function Iy(r,e,t){var i=e.position||"inside",n=e.distance!=null?e.distance:5,a=t.height,s=t.width,o=a/2,l=t.x,u=t.y,c="left",h="top";if(i instanceof Array)l+=ya(i[0],t.width),u+=ya(i[1],t.height),c=null,h=null;else switch(i){case"left":l-=n,u+=o,c="right",h="middle";break;case"right":l+=n+s,u+=o,h="middle";break;case"top":l+=s/2,u-=n,c="center",h="bottom";break;case"bottom":l+=s/2,u+=a+n,c="center";break;case"inside":l+=s/2,u+=o,c="center",h="middle";break;case"insideLeft":l+=n,u+=o,h="middle";break;case"insideRight":l+=s-n,u+=o,c="right",h="middle";break;case"insideTop":l+=s/2,u+=n,c="center";break;case"insideBottom":l+=s/2,u+=a-n,c="center",h="bottom";break;case"insideTopLeft":l+=n,u+=n;break;case"insideTopRight":l+=s-n,u+=n,c="right";break;case"insideBottomLeft":l+=n,u+=a-n,h="bottom";break;case"insideBottomRight":l+=s-n,u+=a-n,c="right",h="bottom";break}return r=r||{},r.x=l,r.y=u,r.align=c,r.verticalAlign=h,r}var ub="__zr_normal__",cb=os.concat(["ignore"]),Gle=as(os,function(r,e){return r[e]=!0,r},{ignore:!1}),Fc={},Hle=new qe(0,0,0,0),r1=function(){function r(e){this.id=kz(),this.animators=[],this.currentStates=[],this.states={},this._init(e)}return r.prototype._init=function(e){this.attr(e)},r.prototype.drift=function(e,t,i){switch(this.draggable){case"horizontal":t=0;break;case"vertical":e=0;break}var n=this.transform;n||(n=this.transform=[1,0,0,1,0,0]),n[4]+=e,n[5]+=t,this.decomposeTransform(),this.markRedraw()},r.prototype.beforeUpdate=function(){},r.prototype.afterUpdate=function(){},r.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},r.prototype.updateInnerText=function(e){var t=this._textContent;if(t&&(!t.ignore||e)){this.textConfig||(this.textConfig={});var i=this.textConfig,n=i.local,a=t.innerTransformable,s=void 0,o=void 0,l=!1;a.parent=n?this:null;var u=!1;if(a.copyTransform(t),i.position!=null){var c=Hle;i.layoutRect?c.copy(i.layoutRect):c.copy(this.getBoundingRect()),n||c.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(Fc,i,c):Iy(Fc,i,c),a.x=Fc.x,a.y=Fc.y,s=Fc.align,o=Fc.verticalAlign;var h=i.origin;if(h&&i.rotation!=null){var d=void 0,f=void 0;h==="center"?(d=c.width*.5,f=c.height*.5):(d=ya(h[0],c.width),f=ya(h[1],c.height)),u=!0,a.originX=-a.x+d+(n?0:c.x),a.originY=-a.y+f+(n?0:c.y)}}i.rotation!=null&&(a.rotation=i.rotation);var p=i.offset;p&&(a.x+=p[0],a.y+=p[1],u||(a.originX=-p[0],a.originY=-p[1]));var v=i.inside==null?typeof i.position=="string"&&i.position.indexOf("inside")>=0:i.inside,g=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),m=void 0,y=void 0,_=void 0;v&&this.canBeInsideText()?(m=i.insideFill,y=i.insideStroke,(m==null||m==="auto")&&(m=this.getInsideTextFill()),(y==null||y==="auto")&&(y=this.getInsideTextStroke(m),_=!0)):(m=i.outsideFill,y=i.outsideStroke,(m==null||m==="auto")&&(m=this.getOutsideFill()),(y==null||y==="auto")&&(y=this.getOutsideStroke(m),_=!0)),m=m||"#000",(m!==g.fill||y!==g.stroke||_!==g.autoStroke||s!==g.align||o!==g.verticalAlign)&&(l=!0,g.fill=m,g.stroke=y,g.autoStroke=_,g.align=s,g.verticalAlign=o,t.setDefaultTextStyle(g)),t.__dirty|=cn,l&&t.dirtyStyle(!0)}},r.prototype.canBeInsideText=function(){return!0},r.prototype.getInsideTextFill=function(){return"#fff"},r.prototype.getInsideTextStroke=function(e){return"#000"},r.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?zx:Vx},r.prototype.getOutsideStroke=function(e){var t=this.__zr&&this.__zr.getBackgroundColor(),i=typeof t=="string"&&gn(t);i||(i=[255,255,255,1]);for(var n=i[3],a=this.__zr.isDarkMode(),s=0;s<3;s++)i[s]=i[s]*n+(a?0:255)*(1-n);return i[3]=1,Os(i,"rgba")},r.prototype.traverse=function(e,t){},r.prototype.attrKV=function(e,t){e==="textConfig"?this.setTextConfig(t):e==="textContent"?this.setTextContent(t):e==="clipPath"?this.setClipPath(t):e==="extra"?(this.extra=this.extra||{},J(this.extra,t)):this[e]=t},r.prototype.hide=function(){this.ignore=!0,this.markRedraw()},r.prototype.show=function(){this.ignore=!1,this.markRedraw()},r.prototype.attr=function(e,t){if(typeof e=="string")this.attrKV(e,t);else if(De(e))for(var i=e,n=rt(i),a=0;a0},r.prototype.getState=function(e){return this.states[e]},r.prototype.ensureState=function(e){var t=this.states;return t[e]||(t[e]={}),t[e]},r.prototype.clearStates=function(e){this.useState(ub,!1,e)},r.prototype.useState=function(e,t,i,n){var a=e===ub,s=this.hasState();if(!(!s&&a)){var o=this.currentStates,l=this.stateTransition;if(!(Xe(o,e)>=0&&(t||o.length===1))){var u;if(this.stateProxy&&!a&&(u=this.stateProxy(e)),u||(u=this.states&&this.states[e]),!u&&!a){$A("State "+e+" not exists.");return}a||this.saveCurrentToNormalState(u);var c=!!(u&&u.hoverLayer||n);c&&this._toggleHoverLayerFlag(!0),this._applyStateObj(e,u,this._normalState,t,!i&&!this.__inHover&&l&&l.duration>0,l);var h=this._textContent,d=this._textGuide;return h&&h.useState(e,t,i,c),d&&d.useState(e,t,i,c),a?(this.currentStates=[],this._normalState={}):t?this.currentStates.push(e):this.currentStates=[e],this._updateAnimationTargets(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~cn),u}}},r.prototype.useStates=function(e,t,i){if(!e.length)this.clearStates();else{var n=[],a=this.currentStates,s=e.length,o=s===a.length;if(o){for(var l=0;l0,p);var v=this._textContent,g=this._textGuide;v&&v.useStates(e,t,d),g&&g.useStates(e,t,d),this._updateAnimationTargets(),this.currentStates=e.slice(),this.markRedraw(),!d&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~cn)}},r.prototype.isSilent=function(){for(var e=this.silent,t=this.parent;!e&&t;){if(t.silent){e=!0;break}t=t.parent}return e},r.prototype._updateAnimationTargets=function(){for(var e=0;e=0){var i=this.currentStates.slice();i.splice(t,1),this.useStates(i)}},r.prototype.replaceState=function(e,t,i){var n=this.currentStates.slice(),a=Xe(n,e),s=Xe(n,t)>=0;a>=0?s?n.splice(a,1):n[a]=t:i&&!s&&n.push(t),this.useStates(n)},r.prototype.toggleState=function(e,t){t?this.useState(e,!0):this.removeState(e)},r.prototype._mergeStates=function(e){for(var t={},i,n=0;n=0&&a.splice(s,1)}),this.animators.push(e),i&&i.animation.addAnimator(e),i&&i.wakeUp()},r.prototype.updateDuringAnimation=function(e){this.markRedraw()},r.prototype.stopAnimation=function(e,t){for(var i=this.animators,n=i.length,a=[],s=0;s0&&t.during&&a[0].during(function(p,v){t.during(v)});for(var d=0;d0||n.force&&!s.length){var D=void 0,I=void 0,M=void 0;if(o){I={},d&&(D={});for(var b=0;b<_;b++){var m=v[b];I[m]=t[m],d?D[m]=i[m]:t[m]=i[m]}}else if(d){M={};for(var b=0;b<_;b++){var m=v[b];M[m]=Pp(t[m]),Wle(t,i,m)}}var T=new JA(t,!1,!1,h?Tt(p,function(N){return N.targetName===e}):null);T.targetName=e,n.scope&&(T.scope=n.scope),d&&D&&T.whenWithKeys(0,D,v),M&&T.whenWithKeys(0,M,v),T.whenWithKeys(u??500,o?I:i,v).delay(c||0),r.addAnimator(T,e),s.push(T)}}var Le=function(r){j(e,r);function e(t){var i=r.call(this)||this;return i.isGroup=!0,i._children=[],i.attr(t),i}return e.prototype.childrenRef=function(){return this._children},e.prototype.children=function(){return this._children.slice()},e.prototype.childAt=function(t){return this._children[t]},e.prototype.childOfName=function(t){for(var i=this._children,n=0;n=0&&(n.splice(a,0,t),this._doAdd(t))}return this},e.prototype.replace=function(t,i){var n=Xe(this._children,t);return n>=0&&this.replaceAt(i,n),this},e.prototype.replaceAt=function(t,i){var n=this._children,a=n[i];if(t&&t!==this&&t.parent!==this&&t!==a){n[i]=t,a.parent=null;var s=this.__zr;s&&a.removeSelfFromZr(s),this._doAdd(t)}return this},e.prototype._doAdd=function(t){t.parent&&t.parent.remove(t),t.parent=this;var i=this.__zr;i&&i!==t.__zr&&t.addSelfToZr(i),i&&i.refresh()},e.prototype.remove=function(t){var i=this.__zr,n=this._children,a=Xe(n,t);return a<0?this:(n.splice(a,1),t.parent=null,i&&t.removeSelfFromZr(i),i&&i.refresh(),this)},e.prototype.removeAll=function(){for(var t=this._children,i=this.__zr,n=0;n0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},r.prototype.setSleepAfterStill=function(e){this._sleepAfterStill=e},r.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},r.prototype.refreshHover=function(){this._needsRefreshHover=!0},r.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()==="canvas"&&this.painter.refreshHover())},r.prototype.resize=function(e){this._disposed||(e=e||{},this.painter.resize(e.width,e.height),this.handler.resize())},r.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},r.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},r.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},r.prototype.setCursorStyle=function(e){this._disposed||this.handler.setCursorStyle(e)},r.prototype.findHover=function(e,t){if(!this._disposed)return this.handler.findHover(e,t)},r.prototype.on=function(e,t,i){return this._disposed||this.handler.on(e,t,i),this},r.prototype.off=function(e,t){this._disposed||this.handler.off(e,t)},r.prototype.trigger=function(e,t){this._disposed||this.handler.trigger(e,t)},r.prototype.clear=function(){if(!this._disposed){for(var e=this.storage.getRoots(),t=0;t0){if(r<=n)return s;if(r>=a)return o}else{if(r>=n)return s;if(r<=a)return o}else{if(r===n)return s;if(r===a)return o}return(r-n)/l*u+s}function ce(r,e){switch(r){case"center":case"middle":r="50%";break;case"left":case"top":r="0%";break;case"right":case"bottom":r="100%";break}return pe(r)?eue(r).match(/%$/)?parseFloat(r)/100*e:parseFloat(r):r==null?NaN:+r}function er(r,e,t){return e==null&&(e=10),e=Math.min(Math.max(0,e),lG),r=(+r).toFixed(e),t?r:+r}function Gn(r){return r.sort(function(e,t){return e-t}),r}function Wa(r){if(r=+r,isNaN(r))return 0;if(r>1e-14){for(var e=1,t=0;t<15;t++,e*=10)if(Math.round(r*e)/e===r)return t}return tue(r)}function tue(r){var e=r.toString().toLowerCase(),t=e.indexOf("e"),i=t>0?+e.slice(t+1):0,n=t>0?t:e.length,a=e.indexOf("."),s=a<0?0:n-1-a;return Math.max(0,s-i)}function uG(r,e){var t=Math.log,i=Math.LN10,n=Math.floor(t(r[1]-r[0])/i),a=Math.round(t(Math.abs(e[1]-e[0]))/i),s=Math.min(Math.max(-n+a,0),20);return isFinite(s)?s:20}function rue(r,e){var t=as(r,function(f,p){return f+(isNaN(p)?0:p)},0);if(t===0)return[];for(var i=Math.pow(10,e),n=oe(r,function(f){return(isNaN(f)?0:f)/t*i*100}),a=i*100,s=oe(n,function(f){return Math.floor(f)}),o=as(s,function(f,p){return f+p},0),l=oe(n,function(f,p){return f-s[p]});ou&&(u=l[h],c=h);++s[c],l[c]=0,++o}return oe(s,function(f){return f/i})}function iue(r,e){var t=Math.max(Wa(r),Wa(e)),i=r+e;return t>lG?i:er(i,t)}var HP=9007199254740991;function cG(r){var e=Math.PI*2;return(r%e+e)%e}function hv(r){return r>-GP&&r=10&&e++,e}function hG(r,e){var t=eD(r),i=Math.pow(10,t),n=r/i,a;return n<1.5?a=1:n<2.5?a=2:n<4?a=3:n<7?a=5:a=10,r=a*i,t>=-20?+r.toFixed(t<0?-t:0):r}function db(r,e){var t=(r.length-1)*e+1,i=Math.floor(t),n=+r[i-1],a=t-i;return a?n+a*(r[i]-n):n}function $P(r){r.sort(function(l,u){return o(l,u,0)?-1:1});for(var e=-1/0,t=1,i=0;i=0||a&&Xe(a,l)<0)){var u=i.getShallow(l,e);u!=null&&(s[r[o][0]]=u)}}return s}}var Iue=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],Pue=tc(Iue),Mue=function(){function r(){}return r.prototype.getAreaStyle=function(e,t){return Pue(this,e,t)},r}(),$x=new Yv(50);function Lue(r){if(typeof r=="string"){var e=$x.get(r);return e&&e.image}else return r}function nD(r,e,t,i,n){if(r)if(typeof r=="string"){if(e&&e.__zrImageSrc===r||!t)return e;var a=$x.get(r),s={hostEl:t,cb:i,cbPayload:n};return a?(e=a.image,!n1(e)&&a.pending.push(s)):(e=el.loadImage(r,XP,XP),e.__zrImageSrc=r,$x.put(r,e.__cachedImgObj={image:e,pending:[s]})),e}else return r;else return e}function XP(){var r=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e=s;l++)o-=s;var u=mn(t,e);return u>o&&(t="",u=0),o=r-u,n.ellipsis=t,n.ellipsisWidth=u,n.contentWidth=o,n.containerWidth=r,n}function wG(r,e){var t=e.containerWidth,i=e.font,n=e.contentWidth;if(!t)return"";var a=mn(r,i);if(a<=t)return r;for(var s=0;;s++){if(a<=n||s>=e.maxIterations){r+=e.ellipsis;break}var o=s===0?Rue(r,n,e.ascCharWidth,e.cnCharWidth):a>0?Math.floor(r.length*n/a):0;r=r.substr(0,o),a=mn(r,i)}return r===""&&(r=e.placeholder),r}function Rue(r,e,t,i){for(var n=0,a=0,s=r.length;af&&u){var p=Math.floor(f/o);h=h.slice(0,p)}if(r&&a&&c!=null)for(var v=xG(c,n,e.ellipsis,{minChar:e.truncateMinChar,placeholder:e.placeholder}),g=0;go&&vb(t,r.substring(o,u),e,s),vb(t,l[2],e,s,l[1]),o=pb.lastIndex}on){T>0?(y.tokens=y.tokens.slice(0,T),g(y,b,_),t.lines=t.lines.slice(0,m+1)):t.lines=t.lines.slice(0,m);break e}var N=C.width,O=N==null||N==="auto";if(typeof N=="string"&&N.charAt(N.length-1)==="%")x.percentWidth=N,c.push(x),x.contentWidth=mn(x.text,M);else{if(O){var B=C.backgroundColor,F=B&&B.image;F&&(F=Lue(F),n1(F)&&(x.width=Math.max(x.width,F.width*L/F.height)))}var U=p&&i!=null?i-b:null;U!=null&&U0&&p+i.accumWidth>i.width&&(c=e.split(` +`),u=!0),i.accumWidth=p}else{var v=CG(e,l,i.width,i.breakAll,i.accumWidth);i.accumWidth=v.accumWidth+f,h=v.linesWidths,c=v.lines}}else c=e.split(` +`);for(var g=0;g=32&&e<=591||e>=880&&e<=4351||e>=4608&&e<=5119||e>=7680&&e<=8303}var Vue=as(",&?/;] ".split(""),function(r,e){return r[e]=!0,r},{});function zue(r){return Uue(r)?!!Vue[r]:!0}function CG(r,e,t,i,n){for(var a=[],s=[],o="",l="",u=0,c=0,h=0;ht:n+c+f>t){c?(o||l)&&(p?(o||(o=l,l="",u=0,c=u),a.push(o),s.push(c-u),l+=d,u+=f,o="",c=u):(l&&(o+=l,l="",u=0),a.push(o),s.push(c),o=d,c=f)):p?(a.push(l),s.push(u),l=d,u=f):(a.push(d),s.push(f));continue}c+=f,p?(l+=d,u+=f):(l&&(o+=l,l="",u=0),o+=d)}return!a.length&&!o&&(o=r,l="",u=0),l&&(o+=l),o&&(a.push(o),s.push(c)),a.length===1&&(c+=n),{accumWidth:c,lines:a,linesWidths:s}}var Wx="__zr_style_"+Math.round(Math.random()*10),Uu={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},a1={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};Uu[Wx]=!0;var KP=["z","z2","invisible"],Gue=["invisible"],Yn=function(r){j(e,r);function e(t){return r.call(this,t)||this}return e.prototype._init=function(t){for(var i=rt(t),n=0;n1e-4){o[0]=r-t,o[1]=e-i,l[0]=r+t,l[1]=e+i;return}if(um[0]=_b(n)*t+r,um[1]=yb(n)*i+e,cm[0]=_b(a)*t+r,cm[1]=yb(a)*i+e,u(o,um,cm),c(l,um,cm),n=n%Rl,n<0&&(n=n+Rl),a=a%Rl,a<0&&(a=a+Rl),n>a&&!s?a+=Rl:nn&&(hm[0]=_b(f)*t+r,hm[1]=yb(f)*i+e,u(o,hm,o),c(l,hm,l))}var Et={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Ol=[],Nl=[],Aa=[],po=[],Da=[],Ea=[],bb=Math.min,Sb=Math.max,Bl=Math.cos,Fl=Math.sin,gs=Math.abs,qx=Math.PI,xo=qx*2,Tb=typeof Float32Array<"u",yd=[];function xb(r){var e=Math.round(r/qx*1e8)/1e8;return e%2*qx}function aD(r,e){var t=xb(r[0]);t<0&&(t+=xo);var i=t-r[0],n=r[1];n+=i,!e&&n-t>=xo?n=t+xo:e&&t-n>=xo?n=t-xo:!e&&t>n?n=t+(xo-xb(t-n)):e&&t0&&(this._ux=gs(i/Ey/e)||0,this._uy=gs(i/Ey/t)||0)},r.prototype.setDPR=function(e){this.dpr=e},r.prototype.setContext=function(e){this._ctx=e},r.prototype.getContext=function(){return this._ctx},r.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},r.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},r.prototype.moveTo=function(e,t){return this._drawPendingPt(),this.addData(Et.M,e,t),this._ctx&&this._ctx.moveTo(e,t),this._x0=e,this._y0=t,this._xi=e,this._yi=t,this},r.prototype.lineTo=function(e,t){var i=gs(e-this._xi),n=gs(t-this._yi),a=i>this._ux||n>this._uy;if(this.addData(Et.L,e,t),this._ctx&&a&&this._ctx.lineTo(e,t),a)this._xi=e,this._yi=t,this._pendingPtDist=0;else{var s=i*i+n*n;s>this._pendingPtDist&&(this._pendingPtX=e,this._pendingPtY=t,this._pendingPtDist=s)}return this},r.prototype.bezierCurveTo=function(e,t,i,n,a,s){return this._drawPendingPt(),this.addData(Et.C,e,t,i,n,a,s),this._ctx&&this._ctx.bezierCurveTo(e,t,i,n,a,s),this._xi=a,this._yi=s,this},r.prototype.quadraticCurveTo=function(e,t,i,n){return this._drawPendingPt(),this.addData(Et.Q,e,t,i,n),this._ctx&&this._ctx.quadraticCurveTo(e,t,i,n),this._xi=i,this._yi=n,this},r.prototype.arc=function(e,t,i,n,a,s){this._drawPendingPt(),yd[0]=n,yd[1]=a,aD(yd,s),n=yd[0],a=yd[1];var o=a-n;return this.addData(Et.A,e,t,i,i,n,o,0,s?0:1),this._ctx&&this._ctx.arc(e,t,i,n,a,s),this._xi=Bl(a)*i+e,this._yi=Fl(a)*i+t,this},r.prototype.arcTo=function(e,t,i,n,a){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(e,t,i,n,a),this},r.prototype.rect=function(e,t,i,n){return this._drawPendingPt(),this._ctx&&this._ctx.rect(e,t,i,n),this.addData(Et.R,e,t,i,n),this},r.prototype.closePath=function(){this._drawPendingPt(),this.addData(Et.Z);var e=this._ctx,t=this._x0,i=this._y0;return e&&e.closePath(),this._xi=t,this._yi=i,this},r.prototype.fill=function(e){e&&e.fill(),this.toStatic()},r.prototype.stroke=function(e){e&&e.stroke(),this.toStatic()},r.prototype.len=function(){return this._len},r.prototype.setData=function(e){var t=e.length;!(this.data&&this.data.length===t)&&Tb&&(this.data=new Float32Array(t));for(var i=0;ic.length&&(this._expandData(),c=this.data);for(var h=0;h0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},r.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var e=[],t=0;t11&&(this.data=new Float32Array(e)))}},r.prototype.getBoundingRect=function(){Aa[0]=Aa[1]=Da[0]=Da[1]=Number.MAX_VALUE,po[0]=po[1]=Ea[0]=Ea[1]=-Number.MAX_VALUE;var e=this.data,t=0,i=0,n=0,a=0,s;for(s=0;si||gs(_)>n||d===t-1)&&(v=Math.sqrt(y*y+_*_),a=g,s=m);break}case Et.C:{var b=e[d++],T=e[d++],g=e[d++],m=e[d++],x=e[d++],C=e[d++];v=fle(a,s,b,T,g,m,x,C,10),a=x,s=C;break}case Et.Q:{var b=e[d++],T=e[d++],g=e[d++],m=e[d++];v=ple(a,s,b,T,g,m,10),a=g,s=m;break}case Et.A:var D=e[d++],I=e[d++],M=e[d++],L=e[d++],N=e[d++],O=e[d++],B=O+N;d+=1,p&&(o=Bl(N)*M+D,l=Fl(N)*L+I),v=Sb(M,L)*bb(xo,Math.abs(O)),a=Bl(B)*M+D,s=Fl(B)*L+I;break;case Et.R:{o=a=e[d++],l=s=e[d++];var F=e[d++],U=e[d++];v=F*2+U*2;break}case Et.Z:{var y=o-a,_=l-s;v=Math.sqrt(y*y+_*_),a=o,s=l;break}}v>=0&&(u[h++]=v,c+=v)}return this._pathLen=c,c},r.prototype.rebuildPath=function(e,t){var i=this.data,n=this._ux,a=this._uy,s=this._len,o,l,u,c,h,d,f=t<1,p,v,g=0,m=0,y,_=0,b,T;if(!(f&&(this._pathSegLen||this._calculateLength(),p=this._pathSegLen,v=this._pathLen,y=t*v,!y)))e:for(var x=0;x0&&(e.lineTo(b,T),_=0),C){case Et.M:o=u=i[x++],l=c=i[x++],e.moveTo(u,c);break;case Et.L:{h=i[x++],d=i[x++];var I=gs(h-u),M=gs(d-c);if(I>n||M>a){if(f){var L=p[m++];if(g+L>y){var N=(y-g)/L;e.lineTo(u*(1-N)+h*N,c*(1-N)+d*N);break e}g+=L}e.lineTo(h,d),u=h,c=d,_=0}else{var O=I*I+M*M;O>_&&(b=h,T=d,_=O)}break}case Et.C:{var B=i[x++],F=i[x++],U=i[x++],$=i[x++],q=i[x++],Z=i[x++];if(f){var L=p[m++];if(g+L>y){var N=(y-g)/L;tl(u,B,U,q,N,Ol),tl(c,F,$,Z,N,Nl),e.bezierCurveTo(Ol[1],Nl[1],Ol[2],Nl[2],Ol[3],Nl[3]);break e}g+=L}e.bezierCurveTo(B,F,U,$,q,Z),u=q,c=Z;break}case Et.Q:{var B=i[x++],F=i[x++],U=i[x++],$=i[x++];if(f){var L=p[m++];if(g+L>y){var N=(y-g)/L;lv(u,B,U,N,Ol),lv(c,F,$,N,Nl),e.quadraticCurveTo(Ol[1],Nl[1],Ol[2],Nl[2]);break e}g+=L}e.quadraticCurveTo(B,F,U,$),u=U,c=$;break}case Et.A:var te=i[x++],Q=i[x++],se=i[x++],he=i[x++],ue=i[x++],Ie=i[x++],Oe=i[x++],Fe=!i[x++],me=se>he?se:he,ze=gs(se-he)>.001,Pe=ue+Ie,ye=!1;if(f){var L=p[m++];g+L>y&&(Pe=ue+Ie*(y-g)/L,ye=!0),g+=L}if(ze&&e.ellipse?e.ellipse(te,Q,se,he,Oe,ue,Pe,Fe):e.arc(te,Q,me,ue,Pe,Fe),ye)break e;D&&(o=Bl(ue)*se+te,l=Fl(ue)*he+Q),u=Bl(Pe)*se+te,c=Fl(Pe)*he+Q;break;case Et.R:o=u=i[x],l=c=i[x+1],h=i[x++],d=i[x++];var Me=i[x++],_t=i[x++];if(f){var L=p[m++];if(g+L>y){var Re=y-g;e.moveTo(h,d),e.lineTo(h+bb(Re,Me),d),Re-=Me,Re>0&&e.lineTo(h+Me,d+bb(Re,_t)),Re-=_t,Re>0&&e.lineTo(h+Sb(Me-Re,0),d+_t),Re-=Me,Re>0&&e.lineTo(h,d+Sb(_t-Re,0));break e}g+=L}e.rect(h,d,Me,_t);break;case Et.Z:if(f){var L=p[m++];if(g+L>y){var N=(y-g)/L;e.lineTo(u*(1-N)+o*N,c*(1-N)+l*N);break e}g+=L}e.closePath(),u=o,c=l}}},r.prototype.clone=function(){var e=new r,t=this.data;return e.data=t.slice?t.slice():Array.prototype.slice.call(t),e._len=this._len,e},r.CMD=Et,r.initDefaultProps=function(){var e=r.prototype;e._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,e._version=0}(),r}();function Eo(r,e,t,i,n,a,s){if(n===0)return!1;var o=n,l=0,u=r;if(s>e+o&&s>i+o||sr+o&&a>t+o||ae+h&&c>i+h&&c>a+h&&c>o+h||cr+h&&u>t+h&&u>n+h&&u>s+h||ue+u&&l>i+u&&l>a+u||lr+u&&o>t+u&&o>n+u||ot||c+un&&(n+=_d);var d=Math.atan2(l,o);return d<0&&(d+=_d),d>=i&&d<=n||d+_d>=i&&d+_d<=n}function Ts(r,e,t,i,n,a){if(a>e&&a>i||an?o:0}var vo=us.CMD,Ul=Math.PI*2,Yue=1e-4;function Kue(r,e){return Math.abs(r-e)e&&u>i&&u>a&&u>o||u1&&Zue(),f=Mr(e,i,a,o,Rn[0]),d>1&&(p=Mr(e,i,a,o,Rn[1]))),d===2?ge&&o>i&&o>a||o=0&&u<=1){for(var c=0,h=Ur(e,i,a,u),d=0;dt||o<-t)return 0;var l=Math.sqrt(t*t-o*o);mi[0]=-l,mi[1]=l;var u=Math.abs(i-n);if(u<1e-4)return 0;if(u>=Ul-1e-4){i=0,n=Ul;var c=a?1:-1;return s>=mi[0]+r&&s<=mi[1]+r?c:0}if(i>n){var h=i;i=n,n=h}i<0&&(i+=Ul,n+=Ul);for(var d=0,f=0;f<2;f++){var p=mi[f];if(p+r>s){var v=Math.atan2(o,p),c=a?1:-1;v<0&&(v=Ul+v),(v>=i&&v<=n||v+Ul>=i&&v+Ul<=n)&&(v>Math.PI/2&&v1&&(t||(o+=Ts(l,u,c,h,i,n))),g&&(l=a[p],u=a[p+1],c=l,h=u),v){case vo.M:c=a[p++],h=a[p++],l=c,u=h;break;case vo.L:if(t){if(Eo(l,u,a[p],a[p+1],e,i,n))return!0}else o+=Ts(l,u,a[p],a[p+1],i,n)||0;l=a[p++],u=a[p++];break;case vo.C:if(t){if(jue(l,u,a[p++],a[p++],a[p++],a[p++],a[p],a[p+1],e,i,n))return!0}else o+=Que(l,u,a[p++],a[p++],a[p++],a[p++],a[p],a[p+1],i,n)||0;l=a[p++],u=a[p++];break;case vo.Q:if(t){if(AG(l,u,a[p++],a[p++],a[p],a[p+1],e,i,n))return!0}else o+=Jue(l,u,a[p++],a[p++],a[p],a[p+1],i,n)||0;l=a[p++],u=a[p++];break;case vo.A:var m=a[p++],y=a[p++],_=a[p++],b=a[p++],T=a[p++],x=a[p++];p+=1;var C=!!(1-a[p++]);d=Math.cos(T)*_+m,f=Math.sin(T)*b+y,g?(c=d,h=f):o+=Ts(l,u,d,f,i,n);var D=(i-m)*b/_+m;if(t){if(Xue(m,y,b,T,T+x,C,e,D,n))return!0}else o+=ece(m,y,b,T,T+x,C,D,n);l=Math.cos(T+x)*_+m,u=Math.sin(T+x)*b+y;break;case vo.R:c=l=a[p++],h=u=a[p++];var I=a[p++],M=a[p++];if(d=c+I,f=h+M,t){if(Eo(c,h,d,h,e,i,n)||Eo(d,h,d,f,e,i,n)||Eo(d,f,c,f,e,i,n)||Eo(c,f,c,h,e,i,n))return!0}else o+=Ts(d,h,d,f,i,n),o+=Ts(c,f,c,h,i,n);break;case vo.Z:if(t){if(Eo(l,u,c,h,e,i,n))return!0}else o+=Ts(l,u,c,h,i,n);l=c,u=h;break}}return!t&&!Kue(u,h)&&(o+=Ts(l,u,c,h,i,n)||0),o!==0}function tce(r,e,t){return DG(r,0,!1,e,t)}function rce(r,e,t,i){return DG(r,e,!0,t,i)}var Py=Ce({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},Uu),ice={style:Ce({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},a1.style)},wb=os.concat(["invisible","culling","z","z2","zlevel","parent"]),Qe=function(r){j(e,r);function e(t){return r.call(this,t)||this}return e.prototype.update=function(){var t=this;r.prototype.update.call(this);var i=this.style;if(i.decal){var n=this._decalEl=this._decalEl||new e;n.buildPath===e.prototype.buildPath&&(n.buildPath=function(l){t.buildPath(l,t.shape)}),n.silent=!0;var a=n.style;for(var s in i)a[s]!==i[s]&&(a[s]=i[s]);a.fill=i.fill?i.decal:null,a.decal=null,a.shadowColor=null,i.strokeFirst&&(a.stroke=null);for(var o=0;o.5?Vx:i>.2?zle:zx}else if(t)return zx}return Vx},e.prototype.getInsideTextStroke=function(t){var i=this.style.fill;if(pe(i)){var n=this.__zr,a=!!(n&&n.isDarkMode()),s=Ay(t,0)0))},e.prototype.hasFill=function(){var t=this.style,i=t.fill;return i!=null&&i!=="none"},e.prototype.getBoundingRect=function(){var t=this._rect,i=this.style,n=!t;if(n){var a=!1;this.path||(a=!0,this.createPathProxy());var s=this.path;(a||this.__dirty&nh)&&(s.beginPath(),this.buildPath(s,this.shape,!1),this.pathUpdated()),t=s.getBoundingRect()}if(this._rect=t,this.hasStroke()&&this.path&&this.path.len()>0){var o=this._rectStroke||(this._rectStroke=t.clone());if(this.__dirty||n){o.copy(t);var l=i.strokeNoScale?this.getLineScale():1,u=i.lineWidth;if(!this.hasFill()){var c=this.strokeContainThreshold;u=Math.max(u,c??4)}l>1e-10&&(o.width+=u/l,o.height+=u/l,o.x-=u/l/2,o.y-=u/l/2)}return o}return t},e.prototype.contain=function(t,i){var n=this.transformCoordToLocal(t,i),a=this.getBoundingRect(),s=this.style;if(t=n[0],i=n[1],a.contain(t,i)){var o=this.path;if(this.hasStroke()){var l=s.lineWidth,u=s.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),rce(o,l/u,t,i)))return!0}if(this.hasFill())return tce(o,t,i)}return!1},e.prototype.dirtyShape=function(){this.__dirty|=nh,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},e.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},e.prototype.animateShape=function(t){return this.animate("shape",t)},e.prototype.updateDuringAnimation=function(t){t==="style"?this.dirtyStyle():t==="shape"?this.dirtyShape():this.markRedraw()},e.prototype.attrKV=function(t,i){t==="shape"?this.setShape(i):r.prototype.attrKV.call(this,t,i)},e.prototype.setShape=function(t,i){var n=this.shape;return n||(n=this.shape={}),typeof t=="string"?n[t]=i:J(n,t),this.dirtyShape(),this},e.prototype.shapeChanged=function(){return!!(this.__dirty&nh)},e.prototype.createStyle=function(t){return Q_(Py,t)},e.prototype._innerSaveToNormal=function(t){r.prototype._innerSaveToNormal.call(this,t);var i=this._normalState;t.shape&&!i.shape&&(i.shape=J({},this.shape))},e.prototype._applyStateObj=function(t,i,n,a,s,o){r.prototype._applyStateObj.call(this,t,i,n,a,s,o);var l=!(i&&a),u;if(i&&i.shape?s?a?u=i.shape:(u=J({},n.shape),J(u,i.shape)):(u=J({},a?this.shape:n.shape),J(u,i.shape)):l&&(u=n.shape),u)if(s){this.shape=J({},this.shape);for(var c={},h=rt(u),d=0;d0},e.prototype.hasFill=function(){var t=this.style,i=t.fill;return i!=null&&i!=="none"},e.prototype.createStyle=function(t){return Q_(nce,t)},e.prototype.setBoundingRect=function(t){this._rect=t},e.prototype.getBoundingRect=function(){var t=this.style;if(!this._rect){var i=t.text;i!=null?i+="":i="";var n=Kv(i,t.font,t.textAlign,t.textBaseline);if(n.x+=t.x||0,n.y+=t.y||0,this.hasStroke()){var a=t.lineWidth;n.x-=a/2,n.y-=a/2,n.width+=a,n.height+=a}this._rect=n}return this._rect},e.initDefaultProps=function(){var t=e.prototype;t.dirtyRectTolerance=10}(),e}(Yn);of.prototype.type="tspan";var ace=Ce({x:0,y:0},Uu),sce={style:Ce({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},a1.style)};function oce(r){return!!(r&&typeof r!="string"&&r.width&&r.height)}var Wr=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.createStyle=function(t){return Q_(ace,t)},e.prototype._getSize=function(t){var i=this.style,n=i[t];if(n!=null)return n;var a=oce(i.image)?i.image:this.__image;if(!a)return 0;var s=t==="width"?"height":"width",o=i[s];return o==null?a[t]:a[t]/a[s]*o},e.prototype.getWidth=function(){return this._getSize("width")},e.prototype.getHeight=function(){return this._getSize("height")},e.prototype.getAnimationStyleProps=function(){return sce},e.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new qe(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},e}(Yn);Wr.prototype.type="image";function lce(r,e){var t=e.x,i=e.y,n=e.width,a=e.height,s=e.r,o,l,u,c;n<0&&(t=t+n,n=-n),a<0&&(i=i+a,a=-a),typeof s=="number"?o=l=u=c=s:s instanceof Array?s.length===1?o=l=u=c=s[0]:s.length===2?(o=u=s[0],l=c=s[1]):s.length===3?(o=s[0],l=c=s[1],u=s[2]):(o=s[0],l=s[1],u=s[2],c=s[3]):o=l=u=c=0;var h;o+l>n&&(h=o+l,o*=n/h,l*=n/h),u+c>n&&(h=u+c,u*=n/h,c*=n/h),l+u>a&&(h=l+u,l*=a/h,u*=a/h),o+c>a&&(h=o+c,o*=a/h,c*=a/h),r.moveTo(t+o,i),r.lineTo(t+n-l,i),l!==0&&r.arc(t+n-l,i+l,l,-Math.PI/2,0),r.lineTo(t+n,i+a-u),u!==0&&r.arc(t+n-u,i+a-u,u,0,Math.PI/2),r.lineTo(t+c,i+a),c!==0&&r.arc(t+c,i+a-c,c,Math.PI/2,Math.PI),r.lineTo(t,i+o),o!==0&&r.arc(t+o,i+o,o,Math.PI,Math.PI*1.5)}var mh=Math.round;function EG(r,e,t){if(e){var i=e.x1,n=e.x2,a=e.y1,s=e.y2;r.x1=i,r.x2=n,r.y1=a,r.y2=s;var o=t&&t.lineWidth;return o&&(mh(i*2)===mh(n*2)&&(r.x1=r.x2=mu(i,o,!0)),mh(a*2)===mh(s*2)&&(r.y1=r.y2=mu(a,o,!0))),r}}function IG(r,e,t){if(e){var i=e.x,n=e.y,a=e.width,s=e.height;r.x=i,r.y=n,r.width=a,r.height=s;var o=t&&t.lineWidth;return o&&(r.x=mu(i,o,!0),r.y=mu(n,o,!0),r.width=Math.max(mu(i+a,o,!1)-r.x,a===0?0:1),r.height=Math.max(mu(n+s,o,!1)-r.y,s===0?0:1)),r}}function mu(r,e,t){if(!e)return r;var i=mh(r*2);return(i+mh(e))%2===0?i/2:(i+(t?1:-1))/2}var uce=function(){function r(){this.x=0,this.y=0,this.width=0,this.height=0}return r}(),cce={},st=function(r){j(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new uce},e.prototype.buildPath=function(t,i){var n,a,s,o;if(this.subPixelOptimize){var l=IG(cce,i,this.style);n=l.x,a=l.y,s=l.width,o=l.height,l.r=i.r,i=l}else n=i.x,a=i.y,s=i.width,o=i.height;i.r?lce(t,i):t.rect(n,a,s,o)},e.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},e}(Qe);st.prototype.type="rect";var t5={fill:"#000"},r5=2,hce={style:Ce({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},a1.style)},lt=function(r){j(e,r);function e(t){var i=r.call(this)||this;return i.type="text",i._children=[],i._defaultStyle=t5,i.attr(t),i}return e.prototype.childrenRef=function(){return this._children},e.prototype.update=function(){r.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var t=0;t0,N=t.width!=null&&(t.overflow==="truncate"||t.overflow==="break"||t.overflow==="breakAll"),O=s.calculatedLineHeight,B=0;B=0&&(B=x[O],B.align==="right");)this._placeToken(B,t,D,m,N,"right",_),I-=B.width,N-=B.width,O--;for(L+=(a-(L-g)-(y-N)-I)/2;M<=O;)B=x[M],this._placeToken(B,t,D,m,L+B.width/2,"center",_),L+=B.width,M++;m+=D}},e.prototype._placeToken=function(t,i,n,a,s,o,l){var u=i.rich[t.styleName]||{};u.text=t.text;var c=t.verticalAlign,h=a+n/2;c==="top"?h=a+t.height/2:c==="bottom"&&(h=a+n-t.height/2);var d=!t.isLineHolder&&Cb(u);d&&this._renderBackground(u,i,o==="right"?s-t.width:o==="center"?s-t.width/2:s,h-t.height/2,t.width,t.height);var f=!!u.backgroundColor,p=t.textPadding;p&&(s=l5(s,o,p),h-=t.height/2-p[0]-t.innerHeight/2);var v=this._getOrCreateChild(of),g=v.createStyle();v.useStyle(g);var m=this._defaultStyle,y=!1,_=0,b=o5("fill"in u?u.fill:"fill"in i?i.fill:(y=!0,m.fill)),T=s5("stroke"in u?u.stroke:"stroke"in i?i.stroke:!f&&!l&&(!m.autoStroke||y)?(_=r5,m.stroke):null),x=u.textShadowBlur>0||i.textShadowBlur>0;g.text=t.text,g.x=s,g.y=h,x&&(g.shadowBlur=u.textShadowBlur||i.textShadowBlur||0,g.shadowColor=u.textShadowColor||i.textShadowColor||"transparent",g.shadowOffsetX=u.textShadowOffsetX||i.textShadowOffsetX||0,g.shadowOffsetY=u.textShadowOffsetY||i.textShadowOffsetY||0),g.textAlign=o,g.textBaseline="middle",g.font=t.font||Jo,g.opacity=Qa(u.opacity,i.opacity,1),n5(g,u),T&&(g.lineWidth=Qa(u.lineWidth,i.lineWidth,_),g.lineDash=Be(u.lineDash,i.lineDash),g.lineDashOffset=i.lineDashOffset||0,g.stroke=T),b&&(g.fill=b);var C=t.contentWidth,D=t.contentHeight;v.setBoundingRect(new qe(ip(g.x,C,g.textAlign),ah(g.y,D,g.textBaseline),C,D))},e.prototype._renderBackground=function(t,i,n,a,s,o){var l=t.backgroundColor,u=t.borderWidth,c=t.borderColor,h=l&&l.image,d=l&&!h,f=t.borderRadius,p=this,v,g;if(d||t.lineHeight||u&&c){v=this._getOrCreateChild(st),v.useStyle(v.createStyle()),v.style.fill=null;var m=v.shape;m.x=n,m.y=a,m.width=s,m.height=o,m.r=f,v.dirtyShape()}if(d){var y=v.style;y.fill=l||null,y.fillOpacity=Be(t.fillOpacity,1)}else if(h){g=this._getOrCreateChild(Wr),g.onload=function(){p.dirtyStyle()};var _=g.style;_.image=l.image,_.x=n,_.y=a,_.width=s,_.height=o}if(u&&c){var y=v.style;y.lineWidth=u,y.stroke=c,y.strokeOpacity=Be(t.strokeOpacity,1),y.lineDash=t.borderDash,y.lineDashOffset=t.borderDashOffset||0,v.strokeContainThreshold=0,v.hasFill()&&v.hasStroke()&&(y.strokeFirst=!0,y.lineWidth*=2)}var b=(v||g).style;b.shadowBlur=t.shadowBlur||0,b.shadowColor=t.shadowColor||"transparent",b.shadowOffsetX=t.shadowOffsetX||0,b.shadowOffsetY=t.shadowOffsetY||0,b.opacity=Qa(t.opacity,i.opacity,1)},e.makeFont=function(t){var i="";return MG(t)&&(i=[t.fontStyle,t.fontWeight,PG(t.fontSize),t.fontFamily||"sans-serif"].join(" ")),i&&ha(i)||t.textFont||t.font},e}(Yn),fce={left:!0,right:1,center:1},dce={top:1,bottom:1,middle:1},i5=["fontStyle","fontWeight","fontSize","fontFamily"];function PG(r){return typeof r=="string"&&(r.indexOf("px")!==-1||r.indexOf("rem")!==-1||r.indexOf("em")!==-1)?r:isNaN(+r)?zA+"px":r+"px"}function n5(r,e){for(var t=0;t=0,a=!1;if(r instanceof Qe){var s=LG(r),o=n&&s.selectFill||s.normalFill,l=n&&s.selectStroke||s.normalStroke;if(Uc(o)||Uc(l)){i=i||{};var u=i.style||{};u.fill==="inherit"?(a=!0,i=J({},i),u=J({},u),u.fill=o):!Uc(u.fill)&&Uc(o)?(a=!0,i=J({},i),u=J({},u),u.fill=Lx(o)):!Uc(u.stroke)&&Uc(l)&&(a||(i=J({},i),u=J({},u)),u.stroke=Lx(l)),i.style=u}}if(i&&i.z2==null){a||(i=J({},i));var c=r.z2EmphasisLift;i.z2=r.z2+(c??Mf)}return i}function bce(r,e,t){if(t&&t.z2==null){t=J({},t);var i=r.z2SelectLift;t.z2=r.z2+(i??vce)}return t}function Sce(r,e,t){var i=Xe(r.currentStates,e)>=0,n=r.style.opacity,a=i?null:yce(r,["opacity"],e,{opacity:1});t=t||{};var s=t.style||{};return s.opacity==null&&(t=J({},t),s=J({opacity:i?n:a.opacity*.1},s),t.style=s),t}function Ab(r,e){var t=this.states[r];if(this.style){if(r==="emphasis")return _ce(this,r,e,t);if(r==="blur")return Sce(this,r,t);if(r==="select")return bce(this,r,t)}return t}function rc(r){r.stateProxy=Ab;var e=r.getTextContent(),t=r.getTextGuideLine();e&&(e.stateProxy=Ab),t&&(t.stateProxy=Ab)}function d5(r,e){!UG(r,e)&&!r.__highByOuter&&Js(r,kG)}function p5(r,e){!UG(r,e)&&!r.__highByOuter&&Js(r,RG)}function qs(r,e){r.__highByOuter|=1<<(e||0),Js(r,kG)}function js(r,e){!(r.__highByOuter&=~(1<<(e||0)))&&Js(r,RG)}function NG(r){Js(r,lD)}function uD(r){Js(r,OG)}function BG(r){Js(r,gce)}function FG(r){Js(r,mce)}function UG(r,e){return r.__highDownSilentOnTouch&&e.zrByTouch}function VG(r){var e=r.getModel(),t=[],i=[];e.eachComponent(function(n,a){var s=sD(a),o=n==="series",l=o?r.getViewOfSeriesModel(a):r.getViewOfComponentModel(a);!o&&i.push(l),s.isBlured&&(l.group.traverse(function(u){OG(u)}),o&&t.push(a)),s.isBlured=!1}),R(i,function(n){n&&n.toggleBlurSeries&&n.toggleBlurSeries(t,!1,e)})}function Xx(r,e,t,i){var n=i.getModel();t=t||"coordinateSystem";function a(u,c){for(var h=0;h0){var o={dataIndex:s,seriesIndex:t.seriesIndex};a!=null&&(o.dataType=a),e.push(o)}})}),e}function zu(r,e,t){yu(r,!0),Js(r,rc),Kx(r,e,t)}function Dce(r){yu(r,!1)}function Yt(r,e,t,i){i?Dce(r):zu(r,e,t)}function Kx(r,e,t){var i=ke(r);e!=null?(i.focus=e,i.blurScope=t):i.focus&&(i.focus=null)}var g5=["emphasis","blur","select"],Ece={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function Qr(r,e,t,i){t=t||"itemStyle";for(var n=0;n1&&(s*=Db(p),o*=Db(p));var v=(n===a?-1:1)*Db((s*s*(o*o)-s*s*(f*f)-o*o*(d*d))/(s*s*(f*f)+o*o*(d*d)))||0,g=v*s*f/o,m=v*-o*d/s,y=(r+t)/2+dm(h)*g-fm(h)*m,_=(e+i)/2+fm(h)*g+dm(h)*m,b=b5([1,0],[(d-g)/s,(f-m)/o]),T=[(d-g)/s,(f-m)/o],x=[(-1*d-g)/s,(-1*f-m)/o],C=b5(T,x);if(Qx(T,x)<=-1&&(C=bd),Qx(T,x)>=1&&(C=0),C<0){var D=Math.round(C/bd*1e6)/1e6;C=bd*2+D%2*bd}c.addData(u,y,_,s,o,b,C,h,a)}var Rce=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,Oce=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function Nce(r){var e=new us;if(!r)return e;var t=0,i=0,n=t,a=i,s,o=us.CMD,l=r.match(Rce);if(!l)return e;for(var u=0;uB*B+F*F&&(D=M,I=L),{cx:D,cy:I,x0:-c,y0:-h,x1:D*(n/T-1),y1:I*(n/T-1)}}function Hce(r){var e;if(ie(r)){var t=r.length;if(!t)return r;t===1?e=[r[0],r[0],0,0]:t===2?e=[r[0],r[0],r[1],r[1]]:t===3?e=r.concat(r[2]):e=r}else e=[r,r,r,r];return e}function $ce(r,e){var t,i=np(e.r,0),n=np(e.r0||0,0),a=i>0,s=n>0;if(!(!a&&!s)){if(a||(i=n,n=0),n>i){var o=i;i=n,n=o}var l=e.startAngle,u=e.endAngle;if(!(isNaN(l)||isNaN(u))){var c=e.cx,h=e.cy,d=!!e.clockwise,f=T5(u-l),p=f>Eb&&f%Eb;if(p>aa&&(f=p),!(i>aa))r.moveTo(c,h);else if(f>Eb-aa)r.moveTo(c+i*zc(l),h+i*Vl(l)),r.arc(c,h,i,l,u,!d),n>aa&&(r.moveTo(c+n*zc(u),h+n*Vl(u)),r.arc(c,h,n,u,l,d));else{var v=void 0,g=void 0,m=void 0,y=void 0,_=void 0,b=void 0,T=void 0,x=void 0,C=void 0,D=void 0,I=void 0,M=void 0,L=void 0,N=void 0,O=void 0,B=void 0,F=i*zc(l),U=i*Vl(l),$=n*zc(u),q=n*Vl(u),Z=f>aa;if(Z){var te=e.cornerRadius;te&&(t=Hce(te),v=t[0],g=t[1],m=t[2],y=t[3]);var Q=T5(i-n)/2;if(_=Ia(Q,m),b=Ia(Q,y),T=Ia(Q,v),x=Ia(Q,g),I=C=np(_,b),M=D=np(T,x),(C>aa||D>aa)&&(L=i*zc(u),N=i*Vl(u),O=n*zc(l),B=n*Vl(l),faa){var ze=Ia(m,I),Pe=Ia(y,I),ye=pm(O,B,F,U,i,ze,d),Me=pm(L,N,$,q,i,Pe,d);r.moveTo(c+ye.cx+ye.x0,h+ye.cy+ye.y0),I0&&r.arc(c+ye.cx,h+ye.cy,ze,ei(ye.y0,ye.x0),ei(ye.y1,ye.x1),!d),r.arc(c,h,i,ei(ye.cy+ye.y1,ye.cx+ye.x1),ei(Me.cy+Me.y1,Me.cx+Me.x1),!d),Pe>0&&r.arc(c+Me.cx,h+Me.cy,Pe,ei(Me.y1,Me.x1),ei(Me.y0,Me.x0),!d))}else r.moveTo(c+F,h+U),r.arc(c,h,i,l,u,!d);if(!(n>aa)||!Z)r.lineTo(c+$,h+q);else if(M>aa){var ze=Ia(v,M),Pe=Ia(g,M),ye=pm($,q,L,N,n,-Pe,d),Me=pm(F,U,O,B,n,-ze,d);r.lineTo(c+ye.cx+ye.x0,h+ye.cy+ye.y0),M0&&r.arc(c+ye.cx,h+ye.cy,Pe,ei(ye.y0,ye.x0),ei(ye.y1,ye.x1),!d),r.arc(c,h,n,ei(ye.cy+ye.y1,ye.cx+ye.x1),ei(Me.cy+Me.y1,Me.cx+Me.x1),d),ze>0&&r.arc(c+Me.cx,h+Me.cy,ze,ei(Me.y1,Me.x1),ei(Me.y0,Me.x0),!d))}else r.lineTo(c+$,h+q),r.arc(c,h,n,u,l,d)}r.closePath()}}}var Wce=function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0,this.cornerRadius=0}return r}(),Ei=function(r){j(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new Wce},e.prototype.buildPath=function(t,i){$ce(t,i)},e.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},e}(Qe);Ei.prototype.type="sector";var qce=function(){function r(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return r}(),Jv=function(r){j(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new qce},e.prototype.buildPath=function(t,i){var n=i.cx,a=i.cy,s=Math.PI*2;t.moveTo(n+i.r,a),t.arc(n,a,i.r,0,s,!1),t.moveTo(n+i.r0,a),t.arc(n,a,i.r0,0,s,!0)},e}(Qe);Jv.prototype.type="ring";function jce(r,e,t,i){var n=[],a=[],s=[],o=[],l,u,c,h;if(i){c=[1/0,1/0],h=[-1/0,-1/0];for(var d=0,f=r.length;d=2){if(i){var a=jce(n,i,t,e.smoothConstraint);r.moveTo(n[0][0],n[0][1]);for(var s=n.length,o=0;o<(t?s:s-1);o++){var l=a[o*2],u=a[o*2+1],c=n[(o+1)%s];r.bezierCurveTo(l[0],l[1],u[0],u[1],c[0],c[1])}}else{r.moveTo(n[0][0],n[0][1]);for(var o=1,h=n.length;oGl[1]){if(o=!1,a)return o;var c=Math.abs(Gl[0]-zl[1]),h=Math.abs(zl[0]-Gl[1]);Math.min(c,h)>n.len()&&(c0){var h=c.duration,d=c.delay,f=c.easing,p={duration:h,delay:d||0,easing:f,done:a,force:!!a||!!s,setToFinal:!u,scope:r,during:s};o?e.animateFrom(t,p):e.animateTo(t,p)}else e.stopAnimation(),!o&&e.attr(t),s&&s(1),a&&a()}function ct(r,e,t,i,n,a){dD("update",r,e,t,i,n,a)}function Vt(r,e,t,i,n,a){dD("enter",r,e,t,i,n,a)}function Rh(r){if(!r.__zr)return!0;for(var e=0;eMath.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function C5(r){return!r.isGroup}function ohe(r){return r.shape!=null}function rg(r,e,t){if(!r||!e)return;function i(s){var o={};return s.traverse(function(l){C5(l)&&l.anid&&(o[l.anid]=l)}),o}function n(s){var o={x:s.x,y:s.y,rotation:s.rotation};return ohe(s)&&(o.shape=J({},s.shape)),o}var a=i(r);e.traverse(function(s){if(C5(s)&&s.anid){var o=a[s.anid];if(o){var l=n(s);s.attr(n(o)),ct(s,l,t,ke(s).dataIndex)}}})}function eH(r,e){return oe(r,function(t){var i=t[0];i=ky(i,e.x),i=Ry(i,e.x+e.width);var n=t[1];return n=ky(n,e.y),n=Ry(n,e.y+e.height),[i,n]})}function lhe(r,e){var t=ky(r.x,e.x),i=Ry(r.x+r.width,e.x+e.width),n=ky(r.y,e.y),a=Ry(r.y+r.height,e.y+e.height);if(i>=t&&a>=n)return{x:t,y:n,width:i-t,height:a-n}}function ig(r,e,t){var i=J({rectHover:!0},e),n=i.style={strokeNoScale:!0};if(t=t||{x:-1,y:-1,width:2,height:2},r)return r.indexOf("image://")===0?(n.image=r.slice(8),Ce(n,t),new Wr(i)):h1(r.replace("path://",""),i,t,"center")}function ap(r,e,t,i,n){for(var a=0,s=n[n.length-1];a1)return!1;var g=Ib(f,p,c,h)/d;return!(g<0||g>1)}function Ib(r,e,t,i){return r*i-t*e}function uhe(r){return r<=1e-6&&r>=-1e-6}function kf(r){var e=r.itemTooltipOption,t=r.componentModel,i=r.itemName,n=pe(e)?{formatter:e}:e,a=t.mainType,s=t.componentIndex,o={componentType:a,name:i,$vars:["name"]};o[a+"Index"]=s;var l=r.formatterParamsExtra;l&&R(rt(l),function(c){_e(o,c)||(o[c]=l[c],o.$vars.push(c))});var u=ke(r.el);u.componentMainType=a,u.componentIndex=s,u.tooltipConfig={name:i,option:Ce({content:i,encodeHTMLContent:!0,formatterParams:o},n)}}function A5(r,e){var t;r.isGroup&&(t=e(r)),t||r.traverse(e)}function cl(r,e){if(r)if(ie(r))for(var t=0;t=0&&o.push(l)}),o}}function hl(r,e){return We(We({},r,!0),e,!0)}const She={time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}},The={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图",custom:"自定义图表",chart:"图表"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}};var Ny="ZH",gD="EN",Oh=gD,w0={},mD={},oH=et.domSupported?function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage||Oh).toUpperCase();return r.indexOf(Ny)>-1?Ny:Oh}():Oh;function lH(r,e){r=r.toUpperCase(),mD[r]=new yt(e),w0[r]=e}function xhe(r){if(pe(r)){var e=w0[r.toUpperCase()]||{};return r===Ny||r===gD?Ee(e):We(Ee(e),Ee(w0[Oh]),!1)}else return We(Ee(r),Ee(w0[Oh]),!1)}function tw(r){return mD[r]}function whe(){return mD[Oh]}lH(gD,She);lH(Ny,The);var yD=1e3,_D=yD*60,Np=_D*60,Un=Np*24,M5=Un*365,sp={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},mm="{yyyy}-{MM}-{dd}",L5={year:"{yyyy}",month:"{yyyy}-{MM}",day:mm,hour:mm+" "+sp.hour,minute:mm+" "+sp.minute,second:mm+" "+sp.second,millisecond:sp.none},Lb=["year","month","day","hour","minute","second","millisecond"],uH=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function go(r,e){return r+="","0000".substr(0,e-r.length)+r}function Nh(r){switch(r){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return r}}function Che(r){return r===Nh(r)}function Ahe(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function p1(r,e,t,i){var n=ls(r),a=n[bD(t)](),s=n[Bh(t)]()+1,o=Math.floor((s-1)/3)+1,l=n[v1(t)](),u=n["get"+(t?"UTC":"")+"Day"](),c=n[gv(t)](),h=(c-1)%12+1,d=n[g1(t)](),f=n[m1(t)](),p=n[y1(t)](),v=c>=12?"pm":"am",g=v.toUpperCase(),m=i instanceof yt?i:tw(i||oH)||whe(),y=m.getModel("time"),_=y.get("month"),b=y.get("monthAbbr"),T=y.get("dayOfWeek"),x=y.get("dayOfWeekAbbr");return(e||"").replace(/{a}/g,v+"").replace(/{A}/g,g+"").replace(/{yyyy}/g,a+"").replace(/{yy}/g,go(a%100+"",2)).replace(/{Q}/g,o+"").replace(/{MMMM}/g,_[s-1]).replace(/{MMM}/g,b[s-1]).replace(/{MM}/g,go(s,2)).replace(/{M}/g,s+"").replace(/{dd}/g,go(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,T[u]).replace(/{ee}/g,x[u]).replace(/{e}/g,u+"").replace(/{HH}/g,go(c,2)).replace(/{H}/g,c+"").replace(/{hh}/g,go(h+"",2)).replace(/{h}/g,h+"").replace(/{mm}/g,go(d,2)).replace(/{m}/g,d+"").replace(/{ss}/g,go(f,2)).replace(/{s}/g,f+"").replace(/{SSS}/g,go(p,3)).replace(/{S}/g,p+"")}function Dhe(r,e,t,i,n){var a=null;if(pe(t))a=t;else if(we(t))a=t(r.value,e,{level:r.level});else{var s=J({},sp);if(r.level>0)for(var o=0;o=0;--o)if(l[u]){a=l[u];break}a=a||s.none}if(ie(a)){var h=r.level==null?0:r.level>=0?r.level:a.length+r.level;h=Math.min(h,a.length-1),a=a[h]}}return p1(new Date(r.value),a,n,i)}function cH(r,e){var t=ls(r),i=t[Bh(e)]()+1,n=t[v1(e)](),a=t[gv(e)](),s=t[g1(e)](),o=t[m1(e)](),l=t[y1(e)](),u=l===0,c=u&&o===0,h=c&&s===0,d=h&&a===0,f=d&&n===1,p=f&&i===1;return p?"year":f?"month":d?"day":h?"hour":c?"minute":u?"second":"millisecond"}function k5(r,e,t){var i=ut(r)?ls(r):r;switch(e=e||cH(r,t),e){case"year":return i[bD(t)]();case"half-year":return i[Bh(t)]()>=6?1:0;case"quarter":return Math.floor((i[Bh(t)]()+1)/4);case"month":return i[Bh(t)]();case"day":return i[v1(t)]();case"half-day":return i[gv(t)]()/24;case"hour":return i[gv(t)]();case"minute":return i[g1(t)]();case"second":return i[m1(t)]();case"millisecond":return i[y1(t)]()}}function bD(r){return r?"getUTCFullYear":"getFullYear"}function Bh(r){return r?"getUTCMonth":"getMonth"}function v1(r){return r?"getUTCDate":"getDate"}function gv(r){return r?"getUTCHours":"getHours"}function g1(r){return r?"getUTCMinutes":"getMinutes"}function m1(r){return r?"getUTCSeconds":"getSeconds"}function y1(r){return r?"getUTCMilliseconds":"getMilliseconds"}function Ehe(r){return r?"setUTCFullYear":"setFullYear"}function hH(r){return r?"setUTCMonth":"setMonth"}function fH(r){return r?"setUTCDate":"setDate"}function dH(r){return r?"setUTCHours":"setHours"}function pH(r){return r?"setUTCMinutes":"setMinutes"}function vH(r){return r?"setUTCSeconds":"setSeconds"}function gH(r){return r?"setUTCMilliseconds":"setMilliseconds"}function mH(r){if(!fG(r))return pe(r)?r:"-";var e=(r+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function yH(r,e){return r=(r||"").toLowerCase().replace(/-(.)/g,function(t,i){return i.toUpperCase()}),e&&r&&(r=r.charAt(0).toUpperCase()+r.slice(1)),r}var Nf=jA;function rw(r,e,t){var i="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function n(c){return c&&ha(c)?c:"-"}function a(c){return!!(c!=null&&!isNaN(c)&&isFinite(c))}var s=e==="time",o=r instanceof Date;if(s||o){var l=s?ls(r):r;if(isNaN(+l)){if(o)return"-"}else return p1(l,i,t)}if(e==="ordinal")return _x(r)?n(r):ut(r)&&a(r)?r+"":"-";var u=Ws(r);return a(u)?mH(u):_x(r)?n(r):typeof r=="boolean"?r+"":"-"}var R5=["a","b","c","d","e","f","g"],kb=function(r,e){return"{"+r+(e??"")+"}"};function _H(r,e,t){ie(e)||(e=[e]);var i=e.length;if(!i)return"";for(var n=e[0].$vars||[],a=0;a':'';var s=t.markerId||"markerX";return{renderMode:a,content:"{"+s+"|} ",style:n==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:i}:{width:10,height:10,borderRadius:5,backgroundColor:i}}}function ic(r,e){return e=e||"transparent",pe(r)?r:De(r)&&r.colorStops&&(r.colorStops[0]||{}).color||e}function By(r,e){if(e==="_blank"||e==="blank"){var t=window.open();t.opener=null,t.location.href=r}else window.open(r,e)}var C0=R,bH=["left","right","top","bottom","width","height"],_u=[["width","left","right"],["height","top","bottom"]];function SD(r,e,t,i,n){var a=0,s=0;i==null&&(i=1/0),n==null&&(n=1/0);var o=0;e.eachChild(function(l,u){var c=l.getBoundingRect(),h=e.childAt(u+1),d=h&&h.getBoundingRect(),f,p;if(r==="horizontal"){var v=c.width+(d?-d.x+c.x:0);f=a+v,f>i||l.newline?(a=0,f=v,s+=o+t,o=c.height):o=Math.max(o,c.height)}else{var g=c.height+(d?-d.y+c.y:0);p=s+g,p>n||l.newline?(a+=o+t,s=0,p=g,o=c.width):o=Math.max(o,c.width)}l.newline||(l.x=a,l.y=s,l.markRedraw(),r==="horizontal"?a=f+t:s=p+t)})}var Hu=SD;Ue(SD,"vertical");Ue(SD,"horizontal");function Mhe(r,e,t){var i=e.width,n=e.height,a=ce(r.left,i),s=ce(r.top,n),o=ce(r.right,i),l=ce(r.bottom,n);return(isNaN(a)||isNaN(parseFloat(r.left)))&&(a=0),(isNaN(o)||isNaN(parseFloat(r.right)))&&(o=i),(isNaN(s)||isNaN(parseFloat(r.top)))&&(s=0),(isNaN(l)||isNaN(parseFloat(r.bottom)))&&(l=n),t=Nf(t||0),{width:Math.max(o-a-t[1]-t[3],0),height:Math.max(l-s-t[0]-t[2],0)}}function Ar(r,e,t){t=Nf(t||0);var i=e.width,n=e.height,a=ce(r.left,i),s=ce(r.top,n),o=ce(r.right,i),l=ce(r.bottom,n),u=ce(r.width,i),c=ce(r.height,n),h=t[2]+t[0],d=t[1]+t[3],f=r.aspect;switch(isNaN(u)&&(u=i-o-d-a),isNaN(c)&&(c=n-l-h-s),f!=null&&(isNaN(u)&&isNaN(c)&&(f>i/n?u=i*.8:c=n*.8),isNaN(u)&&(u=f*c),isNaN(c)&&(c=u/f)),isNaN(a)&&(a=i-o-u-d),isNaN(s)&&(s=n-l-c-h),r.left||r.right){case"center":a=i/2-u/2-t[3];break;case"right":a=i-u-d;break}switch(r.top||r.bottom){case"middle":case"center":s=n/2-c/2-t[0];break;case"bottom":s=n-c-h;break}a=a||0,s=s||0,isNaN(u)&&(u=i-d-a-(o||0)),isNaN(c)&&(c=n-h-s-(l||0));var p=new qe(a+t[3],s+t[0],u,c);return p.margin=t,p}function _1(r,e,t,i,n,a){var s=!n||!n.hv||n.hv[0],o=!n||!n.hv||n.hv[1],l=n&&n.boundingMode||"all";if(a=a||r,a.x=r.x,a.y=r.y,!s&&!o)return!1;var u;if(l==="raw")u=r.type==="group"?new qe(0,0,+e.width||0,+e.height||0):r.getBoundingRect();else if(u=r.getBoundingRect(),r.needLocalTransform()){var c=r.getLocalTransform();u=u.clone(),u.applyTransform(c)}var h=Ar(Ce({width:u.width,height:u.height},e),t,i),d=s?h.x-u.x:0,f=o?h.y-u.y:0;return l==="raw"?(a.x=d,a.y=f):(a.x+=d,a.y+=f),a===r&&r.markRedraw(),!0}function Lhe(r,e){return r[_u[e][0]]!=null||r[_u[e][1]]!=null&&r[_u[e][2]]!=null}function mv(r){var e=r.layoutMode||r.constructor.layoutMode;return De(e)?e:e?{type:e}:null}function il(r,e,t){var i=t&&t.ignoreSize;!ie(i)&&(i=[i,i]);var n=s(_u[0],0),a=s(_u[1],1);u(_u[0],r,n),u(_u[1],r,a);function s(c,h){var d={},f=0,p={},v=0,g=2;if(C0(c,function(_){p[_]=r[_]}),C0(c,function(_){o(e,_)&&(d[_]=p[_]=e[_]),l(d,_)&&f++,l(p,_)&&v++}),i[h])return l(e,c[1])?p[c[2]]=null:l(e,c[2])&&(p[c[1]]=null),p;if(v===g||!f)return p;if(f>=g)return d;for(var m=0;m=0;l--)o=We(o,n[l],!0);i.defaultOption=o}return i.defaultOption},e.prototype.getReferringComponents=function(t,i){var n=t+"Index",a=t+"Id";return Zv(this.ecModel,t,{index:this.get(n,!0),id:this.get(a,!0)},i)},e.prototype.getBoxLayoutParams=function(){var t=this;return{left:t.get("left"),top:t.get("top"),right:t.get("right"),bottom:t.get("bottom"),width:t.get("width"),height:t.get("height")}},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(t){this.option.zlevel=t},e.protoInitialize=function(){var t=e.prototype;t.type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0}(),e}(yt);TG(tt,yt);i1(tt);_he(tt);bhe(tt,Rhe);function Rhe(r){var e=[];return R(tt.getClassesByMainType(r),function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])}),e=oe(e,function(t){return qa(t).main}),r!=="dataset"&&Xe(e,"dataset")<=0&&e.unshift("dataset"),e}var TH="";typeof navigator<"u"&&(TH=navigator.platform||"");var Gc="rgba(0, 0, 0, 0.2)";const Ohe={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:Gc,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Gc,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Gc,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Gc,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Gc,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Gc,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:TH.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1};var xH=be(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),Qn="original",ui="arrayRows",Jn="objectRows",cs="keyedColumns",qo="typedArray",wH="unknown",Ja="column",Ff="row",jr={Must:1,Might:2,Not:3},CH=ot();function Nhe(r){CH(r).datasetMap=be()}function AH(r,e,t){var i={},n=xD(e);if(!n||!r)return i;var a=[],s=[],o=e.ecModel,l=CH(o).datasetMap,u=n.uid+"_"+t.seriesLayoutBy,c,h;r=r.slice(),R(r,function(v,g){var m=De(v)?v:r[g]={name:v};m.type==="ordinal"&&c==null&&(c=g,h=p(m)),i[m.name]=[]});var d=l.get(u)||l.set(u,{categoryWayDim:h,valueWayDim:0});R(r,function(v,g){var m=v.name,y=p(v);if(c==null){var _=d.valueWayDim;f(i[m],_,y),f(s,_,y),d.valueWayDim+=y}else if(c===g)f(i[m],0,y),f(a,0,y);else{var _=d.categoryWayDim;f(i[m],_,y),f(s,_,y),d.categoryWayDim+=y}});function f(v,g,m){for(var y=0;ye)return r[i];return r[t-1]}function IH(r,e,t,i,n,a,s){a=a||r;var o=e(a),l=o.paletteIdx||0,u=o.paletteNameMap=o.paletteNameMap||{};if(u.hasOwnProperty(n))return u[n];var c=s==null||!i?t:zhe(i,s);if(c=c||t,!(!c||!c.length)){var h=c[l];return n&&(u[n]=h),o.paletteIdx=(l+1)%c.length,h}}function Ghe(r,e){e(r).paletteIdx=0,e(r).paletteNameMap={}}var ym,Sd,N5,B5="\0_ec_inner",Hhe=1,CD=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t,i,n,a,s,o){a=a||{},this.option=null,this._theme=new yt(a),this._locale=new yt(s),this._optionManager=o},e.prototype.setOption=function(t,i,n){var a=V5(i);this._optionManager.setOption(t,n,a),this._resetOption(null,a)},e.prototype.resetOption=function(t,i){return this._resetOption(t,V5(i))},e.prototype._resetOption=function(t,i){var n=!1,a=this._optionManager;if(!t||t==="recreate"){var s=a.mountOption(t==="recreate");!this.option||t==="recreate"?N5(this,s):(this.restoreData(),this._mergeOption(s,i)),n=!0}if((t==="timeline"||t==="media")&&this.restoreData(),!t||t==="recreate"||t==="timeline"){var o=a.getTimelineOption(this);o&&(n=!0,this._mergeOption(o,i))}if(!t||t==="recreate"||t==="media"){var l=a.getMediaOption(this);l.length&&R(l,function(u){n=!0,this._mergeOption(u,i)},this)}return n},e.prototype.mergeOption=function(t){this._mergeOption(t,null)},e.prototype._mergeOption=function(t,i){var n=this.option,a=this._componentsMap,s=this._componentsCount,o=[],l=be(),u=i&&i.replaceMergeMainTypeMap;Nhe(this),R(t,function(h,d){h!=null&&(tt.hasClass(d)?d&&(o.push(d),l.set(d,!0)):n[d]=n[d]==null?Ee(h):We(n[d],h,!0))}),u&&u.each(function(h,d){tt.hasClass(d)&&!l.get(d)&&(o.push(d),l.set(d,!0))}),tt.topologicalTravel(o,tt.getAllClassMainTypes(),c,this);function c(h){var d=Uhe(this,h,xt(t[h])),f=a.get(h),p=f?u&&u.get(h)?"replaceMerge":"normalMerge":"replaceAll",v=mG(f,d,p);pue(v,h,tt),n[h]=null,a.set(h,null),s.set(h,0);var g=[],m=[],y=0,_;R(v,function(b,T){var x=b.existing,C=b.newOption;if(!C)x&&(x.mergeOption({},this),x.optionUpdated({},!1));else{var D=h==="series",I=tt.getClass(h,b.keyInfo.subType,!D);if(!I)return;if(h==="tooltip"){if(_)return;_=!0}if(x&&x.constructor===I)x.name=b.keyInfo.name,x.mergeOption(C,this),x.optionUpdated(C,!1);else{var M=J({componentIndex:T},b.keyInfo);x=new I(C,this,this,M),J(x,M),b.brandNew&&(x.__requireNewView=!0),x.init(C,this,this),x.optionUpdated(null,!0)}}x?(g.push(x.option),m.push(x),y++):(g.push(void 0),m.push(void 0))},this),n[h]=g,a.set(h,m),s.set(h,y),h==="series"&&ym(this)}this._seriesIndices||ym(this)},e.prototype.getOption=function(){var t=Ee(this.option);return R(t,function(i,n){if(tt.hasClass(n)){for(var a=xt(i),s=a.length,o=!1,l=s-1;l>=0;l--)a[l]&&!fv(a[l])?o=!0:(a[l]=null,!o&&s--);a.length=s,t[n]=a}}),delete t[B5],t},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(t){this._payload=t},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(t,i){var n=this._componentsMap.get(t);if(n){var a=n[i||0];if(a)return a;if(i==null){for(var s=0;s=e:t==="max"?r<=e:r===e}function Qhe(r,e){return r.join(",")===e.join(",")}var ra=R,yv=De,z5=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Ob(r){var e=r&&r.itemStyle;if(e)for(var t=0,i=z5.length;t=0;g--){var m=r[g];if(o||(p=m.data.rawIndexOf(m.stackedByDimension,f)),p>=0){var y=m.data.getByRawIndex(m.stackResultDimension,p);if(l==="all"||l==="positive"&&y>0||l==="negative"&&y<0||l==="samesign"&&d>=0&&y>0||l==="samesign"&&d<=0&&y<0){d=iue(d,y),v=y;break}}}return i[0]=d,i[1]=v,i})})}var b1=function(){function r(e){this.data=e.data||(e.sourceFormat===cs?{}:[]),this.sourceFormat=e.sourceFormat||wH,this.seriesLayoutBy=e.seriesLayoutBy||Ja,this.startIndex=e.startIndex||0,this.dimensionsDetectedCount=e.dimensionsDetectedCount,this.metaRawOption=e.metaRawOption;var t=this.dimensionsDefine=e.dimensionsDefine;if(t)for(var i=0;iv&&(v=_)}f[0]=p,f[1]=v}},n=function(){return this._data?this._data.length/this._dimSize:0};X5=(e={},e[ui+"_"+Ja]={pure:!0,appendData:a},e[ui+"_"+Ff]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},e[Jn]={pure:!0,appendData:a},e[cs]={pure:!0,appendData:function(s){var o=this._data;R(s,function(l,u){for(var c=o[u]||(o[u]=[]),h=0;h<(l||[]).length;h++)c.push(l[h])})}},e[Qn]={appendData:a},e[qo]={persistent:!1,pure:!0,appendData:function(s){this._data=s},clean:function(){this._offset+=this.count(),this._data=null}},e);function a(s){for(var o=0;o=0&&(v=s.interpolatedValue[g])}return v!=null?v+"":""})}},r.prototype.getRawValue=function(e,t){return uf(this.getData(t),e)},r.prototype.formatTooltip=function(e,t,i){},r}();function Q5(r){var e,t;return De(r)?r.type&&(t=r):e=r,{text:e,frag:t}}function Bp(r){return new vfe(r)}var vfe=function(){function r(e){e=e||{},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return r.prototype.perform=function(e){var t=this._upstream,i=e&&e.skip;if(this._dirty&&t){var n=this.context;n.data=n.outputData=t.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var a;this._plan&&!i&&(a=this._plan(this.context));var s=c(this._modBy),o=this._modDataCount||0,l=c(e&&e.modBy),u=e&&e.modDataCount||0;(s!==l||o!==u)&&(a="reset");function c(y){return!(y>=1)&&(y=1),y}var h;(this._dirty||a==="reset")&&(this._dirty=!1,h=this._doReset(i)),this._modBy=l,this._modDataCount=u;var d=e&&e.step;if(t?this._dueEnd=t._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var f=this._dueIndex,p=Math.min(d!=null?this._dueIndex+d:1/0,this._dueEnd);if(!i&&(h||f1&&i>0?o:s}};return a;function s(){return e=r?null:le},gte:function(r,e){return r>=e}},mfe=function(){function r(e,t){if(!ut(t)){var i="";vt(i)}this._opFn=VH[e],this._rvalFloat=Ws(t)}return r.prototype.evaluate=function(e){return ut(e)?this._opFn(e,this._rvalFloat):this._opFn(Ws(e),this._rvalFloat)},r}(),zH=function(){function r(e,t){var i=e==="desc";this._resultLT=i?1:-1,t==null&&(t=i?"min":"max"),this._incomparable=t==="min"?-1/0:1/0}return r.prototype.evaluate=function(e,t){var i=ut(e)?e:Ws(e),n=ut(t)?t:Ws(t),a=isNaN(i),s=isNaN(n);if(a&&(i=this._incomparable),s&&(n=this._incomparable),a&&s){var o=pe(e),l=pe(t);o&&(i=l?e:0),l&&(n=o?t:0)}return in?-this._resultLT:0},r}(),yfe=function(){function r(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=Ws(t)}return r.prototype.evaluate=function(e){var t=e===this._rval;if(!t){var i=typeof e;i!==this._rvalTypeof&&(i==="number"||this._rvalTypeof==="number")&&(t=Ws(e)===this._rvalFloat)}return this._isEQ?t:!t},r}();function _fe(r,e){return r==="eq"||r==="ne"?new yfe(r==="eq",e):_e(VH,r)?new mfe(r,e):null}var bfe=function(){function r(){}return r.prototype.getRawData=function(){throw new Error("not supported")},r.prototype.getRawDataItem=function(e){throw new Error("not supported")},r.prototype.cloneRawData=function(){},r.prototype.getDimensionInfo=function(e){},r.prototype.cloneAllDimensionInfo=function(){},r.prototype.count=function(){},r.prototype.retrieveValue=function(e,t){},r.prototype.retrieveValueFromItem=function(e,t){},r.prototype.convertValue=function(e,t){return jo(e,t)},r}();function Sfe(r,e){var t=new bfe,i=r.data,n=t.sourceFormat=r.sourceFormat,a=r.startIndex,s="";r.seriesLayoutBy!==Ja&&vt(s);var o=[],l={},u=r.dimensionsDefine;if(u)R(u,function(v,g){var m=v.name,y={index:g,name:m,displayName:v.displayName};if(o.push(y),m!=null){var _="";_e(l,m)&&vt(_),l[m]=y}});else for(var c=0;c65535?Ife:Pfe}function Hc(){return[1/0,-1/0]}function Mfe(r){var e=r.constructor;return e===Array?r.slice():new e(r)}function tM(r,e,t,i,n){var a=$H[t||"float"];if(n){var s=r[e],o=s&&s.length;if(o!==i){for(var l=new a(i),u=0;ug[1]&&(g[1]=v)}return this._rawCount=this._count=l,{start:o,end:l}},r.prototype._initDataFromProvider=function(e,t,i){for(var n=this._provider,a=this._chunks,s=this._dimensions,o=s.length,l=this._rawExtent,u=oe(s,function(y){return y.property}),c=0;cm[1]&&(m[1]=g)}}!n.persistent&&n.clean&&n.clean(),this._rawCount=this._count=t,this._extent=[]},r.prototype.count=function(){return this._count},r.prototype.get=function(e,t){if(!(t>=0&&t=0&&t=this._rawCount||e<0)return-1;if(!this._indices)return e;var t=this._indices,i=t[e];if(i!=null&&ie)a=s-1;else return s}return-1},r.prototype.indicesOfNearest=function(e,t,i){var n=this._chunks,a=n[e],s=[];if(!a)return s;i==null&&(i=1/0);for(var o=1/0,l=-1,u=0,c=0,h=this.count();c=0&&l<0)&&(o=p,l=f,u=0),f===l&&(s[u++]=c))}return s.length=u,s},r.prototype.getIndices=function(){var e,t=this._indices;if(t){var i=t.constructor,n=this._count;if(i===Array){e=new i(n);for(var a=0;a=h&&y<=d||isNaN(y))&&(l[u++]=v),v++}p=!0}else if(a===2){for(var g=f[n[0]],_=f[n[1]],b=e[n[1]][0],T=e[n[1]][1],m=0;m=h&&y<=d||isNaN(y))&&(x>=b&&x<=T||isNaN(x))&&(l[u++]=v),v++}p=!0}}if(!p)if(a===1)for(var m=0;m=h&&y<=d||isNaN(y))&&(l[u++]=C)}else for(var m=0;me[M][1])&&(D=!1)}D&&(l[u++]=t.getRawIndex(m))}return um[1]&&(m[1]=g)}}}},r.prototype.lttbDownSample=function(e,t){var i=this.clone([e],!0),n=i._chunks,a=n[e],s=this.count(),o=0,l=Math.floor(1/t),u=this.getRawIndex(0),c,h,d,f=new(xd(this._rawCount))(Math.min((Math.ceil(s/l)+2)*2,s));f[o++]=u;for(var p=1;pc&&(c=h,d=b)}L>0&&Lc-p&&(l=c-p,o.length=l);for(var v=0;vh[1]&&(h[1]=m),d[f++]=y}return a._count=f,a._indices=d,a._updateGetRawIdx(),a},r.prototype.each=function(e,t){if(this._count)for(var i=e.length,n=this._chunks,a=0,s=this.count();al&&(l=h)}return s=[o,l],this._extent[e]=s,s},r.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var i=[],n=this._chunks,a=0;a=0?this._indices[e]:-1},r.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},r.internalField=function(){function e(t,i,n,a){return jo(t[a],this._dimensions[a])}Fb={arrayRows:e,objectRows:function(t,i,n,a){return jo(t[i],this._dimensions[a])},keyedColumns:e,original:function(t,i,n,a){var s=t&&(t.value==null?t:t.value);return jo(s instanceof Array?s[a]:s,this._dimensions[a])},typedArray:function(t,i,n,a){return t[a]}}}(),r}(),WH=function(){function r(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return r.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},r.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},r.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},r.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},r.prototype._createSource=function(){this._setLocalSource([],[]);var e=this._sourceHost,t=this._getUpstreamSourceManagers(),i=!!t.length,n,a;if(_m(e)){var s=e,o=void 0,l=void 0,u=void 0;if(i){var c=t[0];c.prepareSource(),u=c.getSource(),o=u.data,l=u.sourceFormat,a=[c._getVersionSign()]}else o=s.get("data",!0),l=Ki(o)?qo:Qn,a=[];var h=this._getSourceMetaRawOption()||{},d=u&&u.metaRawOption||{},f=Be(h.seriesLayoutBy,d.seriesLayoutBy)||null,p=Be(h.sourceHeader,d.sourceHeader),v=Be(h.dimensions,d.dimensions),g=f!==d.seriesLayoutBy||!!p!=!!d.sourceHeader||v;n=g?[aw(o,{seriesLayoutBy:f,sourceHeader:p,dimensions:v},l)]:[]}else{var m=e;if(i){var y=this._applyTransform(t);n=y.sourceList,a=y.upstreamSignList}else{var _=m.get("source",!0);n=[aw(_,this._getSourceMetaRawOption(),null)],a=[]}}this._setLocalSource(n,a)},r.prototype._applyTransform=function(e){var t=this._sourceHost,i=t.get("transform",!0),n=t.get("fromTransformResult",!0);if(n!=null){var a="";e.length!==1&&iM(a)}var s,o=[],l=[];return R(e,function(u){u.prepareSource();var c=u.getSource(n||0),h="";n!=null&&!c&&iM(h),o.push(c),l.push(u._getVersionSign())}),i?s=Dfe(i,o,{datasetIndex:t.componentIndex}):n!=null&&(s=[lfe(o[0])]),{sourceList:s,upstreamSignList:l}},r.prototype._isDirty=function(){if(this._dirty)return!0;for(var e=this._getUpstreamSourceManagers(),t=0;t1||t>0&&!r.noHeader;return R(r.blocks,function(n){var a=YH(n);a>=e&&(e=a+ +(i&&(!a||ow(n)&&!n.noHeader)))}),e}return 0}function Rfe(r,e,t,i){var n=e.noHeader,a=Nfe(YH(e)),s=[],o=e.blocks||[];Ai(!o||ie(o)),o=o||[];var l=r.orderMode;if(e.sortBlocks&&l){o=o.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(_e(u,l)){var c=new zH(u[l],null);o.sort(function(p,v){return c.evaluate(p.sortParam,v.sortParam)})}else l==="seriesDesc"&&o.reverse()}R(o,function(p,v){var g=e.valueFormatter,m=XH(p)(g?J(J({},r),{valueFormatter:g}):r,p,v>0?a.html:0,i);m!=null&&s.push(m)});var h=r.renderMode==="richText"?s.join(a.richText):lw(s.join(""),n?t:a.html);if(n)return h;var d=rw(e.header,"ordinal",r.useUTC),f=jH(i,r.renderMode).nameStyle;return r.renderMode==="richText"?KH(r,d,f)+a.richText+h:lw('
'+Bi(d)+"
"+h,t)}function Ofe(r,e,t,i){var n=r.renderMode,a=e.noName,s=e.noValue,o=!e.markerType,l=e.name,u=r.useUTC,c=e.valueFormatter||r.valueFormatter||function(b){return b=ie(b)?b:[b],oe(b,function(T,x){return rw(T,ie(f)?f[x]:f,u)})};if(!(a&&s)){var h=o?"":r.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",n),d=a?"":rw(l,"ordinal",u),f=e.valueType,p=s?[]:c(e.value,e.dataIndex),v=!o||!a,g=!o&&a,m=jH(i,n),y=m.nameStyle,_=m.valueStyle;return n==="richText"?(o?"":h)+(a?"":KH(r,d,y))+(s?"":Ufe(r,p,v,g,_)):lw((o?"":h)+(a?"":Bfe(d,!o,y))+(s?"":Ffe(p,v,g,_)),t)}}function nM(r,e,t,i,n,a){if(r){var s=XH(r),o={useUTC:n,renderMode:t,orderMode:i,markupStyleCreator:e,valueFormatter:r.valueFormatter};return s(o,r,0,a)}}function Nfe(r){return{html:Lfe[r],richText:kfe[r]}}function lw(r,e){var t='
',i="margin: "+e+"px 0 0";return'
'+r+t+"
"}function Bfe(r,e,t){var i=e?"margin-left:2px":"";return''+Bi(r)+""}function Ffe(r,e,t,i){var n=t?"10px":"20px",a=e?"float:right;margin-left:"+n:"";return r=ie(r)?r:[r],''+oe(r,function(s){return Bi(s)}).join("  ")+""}function KH(r,e,t){return r.markupStyleCreator.wrapRichTextStyle(e,t)}function Ufe(r,e,t,i,n){var a=[n],s=i?10:20;return t&&a.push({padding:[0,0,0,s],align:"right"}),r.markupStyleCreator.wrapRichTextStyle(ie(e)?e.join(" "):e,a)}function ZH(r,e){var t=r.getData().getItemVisual(e,"style"),i=t[r.visualDrawType];return ic(i)}function QH(r,e){var t=r.get("padding");return t??(e==="richText"?[8,10]:10)}var Ub=function(){function r(){this.richTextStyles={},this._nextStyleNameId=dG()}return r.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},r.prototype.makeTooltipMarker=function(e,t,i){var n=i==="richText"?this._generateStyleName():null,a=Phe({color:t,type:e,renderMode:i,markerId:n});return pe(a)?a:(this.richTextStyles[n]=a.style,a.content)},r.prototype.wrapRichTextStyle=function(e,t){var i={};ie(t)?R(t,function(a){return J(i,a)}):J(i,t);var n=this._generateStyleName();return this.richTextStyles[n]=i,"{"+n+"|"+e+"}"},r}();function JH(r){var e=r.series,t=r.dataIndex,i=r.multipleSeries,n=e.getData(),a=n.mapDimensionsAll("defaultedTooltip"),s=a.length,o=e.getRawValue(t),l=ie(o),u=ZH(e,t),c,h,d,f;if(s>1||l&&!s){var p=Vfe(o,e,t,a,u);c=p.inlineValues,h=p.inlineValueTypes,d=p.blocks,f=p.inlineValues[0]}else if(s){var v=n.getDimensionInfo(a[0]);f=c=uf(n,t,a[0]),h=v.type}else f=c=l?o[0]:o;var g=tD(e),m=g&&e.name||"",y=n.getName(t),_=i?m:y;return Br("section",{header:m,noHeader:i||!g,sortParam:f,blocks:[Br("nameValue",{markerType:"item",markerColor:u,name:_,noName:!ha(_),value:c,valueType:h,dataIndex:t})].concat(d||[])})}function Vfe(r,e,t,i,n){var a=e.getData(),s=as(r,function(h,d,f){var p=a.getDimensionInfo(f);return h=h||p&&p.tooltip!==!1&&p.displayName!=null},!1),o=[],l=[],u=[];i.length?R(i,function(h){c(uf(a,t,h),h)}):R(r,c);function c(h,d){var f=a.getDimensionInfo(d);!f||f.otherDims.tooltip===!1||(s?u.push(Br("nameValue",{markerType:"subItem",markerColor:n,name:f.displayName,value:h,valueType:f.type})):(o.push(h),l.push(f.type)))}return{inlineValues:o,inlineValueTypes:l,blocks:u}}var mo=ot();function bm(r,e){return r.getName(e)||r.getId(e)}var A0="__universalTransitionEnabled",Ot=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return e.prototype.init=function(t,i,n){this.seriesIndex=this.componentIndex,this.dataTask=Bp({count:Gfe,reset:Hfe}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n);var a=mo(this).sourceManager=new WH(this);a.prepareSource();var s=this.getInitialData(t,n);sM(s,this),this.dataTask.context.data=s,mo(this).dataBeforeProcessed=s,aM(this),this._initSelectedMapFromData(s)},e.prototype.mergeDefaultAndTheme=function(t,i){var n=mv(this),a=n?Bf(t):{},s=this.subType;tt.hasClass(s)&&(s+="Series"),We(t,i.getTheme().get(this.subType)),We(t,this.getDefaultOption()),Ju(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&il(t,a,n)},e.prototype.mergeOption=function(t,i){t=We(this.option,t,!0),this.fillDataTextStyle(t.data);var n=mv(this);n&&il(this.option,t,n);var a=mo(this).sourceManager;a.dirty(),a.prepareSource();var s=this.getInitialData(t,i);sM(s,this),this.dataTask.dirty(),this.dataTask.context.data=s,mo(this).dataBeforeProcessed=s,aM(this),this._initSelectedMapFromData(s)},e.prototype.fillDataTextStyle=function(t){if(t&&!Ki(t))for(var i=["show"],n=0;nthis.getShallow("animationThreshold")&&(i=!1),!!i},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(t,i,n){var a=this.ecModel,s=wD.prototype.getColorFromPalette.call(this,t,i,n);return s||(s=a.getColorFromPalette(t,i,n)),s},e.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(t,i){this._innerSelect(this.getData(i),t)},e.prototype.unselect=function(t,i){var n=this.option.selectedMap;if(n){var a=this.option.selectedMode,s=this.getData(i);if(a==="series"||n==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var o=0;o=0&&n.push(s)}return n},e.prototype.isSelected=function(t,i){var n=this.option.selectedMap;if(!n)return!1;var a=this.getData(i);return(n==="all"||n[bm(a,t)])&&!a.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[A0])return!0;var t=this.option.universalTransition;return t?t===!0?!0:t&&t.enabled:!1},e.prototype._innerSelect=function(t,i){var n,a,s=this.option,o=s.selectedMode,l=i.length;if(!(!o||!l)){if(o==="series")s.selectedMap="all";else if(o==="multiple"){De(s.selectedMap)||(s.selectedMap={});for(var u=s.selectedMap,c=0;c0&&this._innerSelect(t,i)}},e.registerClass=function(t){return tt.registerClass(t)},e.protoInitialize=function(){var t=e.prototype;t.type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"}(),e}(tt);_r(Ot,S1);_r(Ot,wD);TG(Ot,tt);function aM(r){var e=r.name;tD(r)||(r.name=zfe(r)||e)}function zfe(r){var e=r.getRawData(),t=e.mapDimensionsAll("seriesName"),i=[];return R(t,function(n){var a=e.getDimensionInfo(n);a.displayName&&i.push(a.displayName)}),i.join(" ")}function Gfe(r){return r.model.getRawData().count()}function Hfe(r){var e=r.model;return e.setData(e.getRawData().cloneShallow()),$fe}function $fe(r,e){e.outputData&&r.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function sM(r,e){R(Sy(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(t){r.wrapMethod(t,Ue(Wfe,e))})}function Wfe(r,e){var t=uw(r);return t&&t.setOutputEnd((e||this).count()),e}function uw(r){var e=(r.ecModel||{}).scheduler,t=e&&e.getPipeline(r.uid);if(t){var i=t.currentTask;if(i){var n=i.agentStubMap;n&&(i=n.get(r.uid))}return i}}var $t=function(){function r(){this.group=new Le,this.uid=Of("viewComponent")}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,i,n){},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,i,n){},r.prototype.updateLayout=function(e,t,i,n){},r.prototype.updateVisual=function(e,t,i,n){},r.prototype.toggleBlurSeries=function(e,t,i){},r.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},r}();iD($t);i1($t);function Uf(){var r=ot();return function(e){var t=r(e),i=e.pipelineContext,n=!!t.large,a=!!t.progressiveRender,s=t.large=!!(i&&i.large),o=t.progressiveRender=!!(i&&i.progressiveRender);return(n!==s||a!==o)&&"reset"}}var e$=ot(),qfe=Uf(),Ct=function(){function r(){this.group=new Le,this.uid=Of("viewChart"),this.renderTask=Bp({plan:jfe,reset:Xfe}),this.renderTask.context={view:this}}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,i,n){},r.prototype.highlight=function(e,t,i,n){var a=e.getData(n&&n.dataType);a&&lM(a,n,"emphasis")},r.prototype.downplay=function(e,t,i,n){var a=e.getData(n&&n.dataType);a&&lM(a,n,"normal")},r.prototype.remove=function(e,t){this.group.removeAll()},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,i,n){this.render(e,t,i,n)},r.prototype.updateLayout=function(e,t,i,n){this.render(e,t,i,n)},r.prototype.updateVisual=function(e,t,i,n){this.render(e,t,i,n)},r.prototype.eachRendered=function(e){cl(this.group,e)},r.markUpdateMethod=function(e,t){e$(e).updateMethod=t},r.protoInitialize=function(){var e=r.prototype;e.type="chart"}(),r}();function oM(r,e,t){r&&pv(r)&&(e==="emphasis"?qs:js)(r,t)}function lM(r,e,t){var i=ec(r,e),n=e&&e.highlightKey!=null?Pce(e.highlightKey):null;i!=null?R(xt(i),function(a){oM(r.getItemGraphicEl(a),t,n)}):r.eachItemGraphicEl(function(a){oM(a,t,n)})}iD(Ct);i1(Ct);function jfe(r){return qfe(r.model)}function Xfe(r){var e=r.model,t=r.ecModel,i=r.api,n=r.payload,a=e.pipelineContext.progressiveRender,s=r.view,o=n&&e$(n).updateMethod,l=a?"incrementalPrepareRender":o&&s[o]?o:"render";return l!=="render"&&s[l](e,t,i,n),Yfe[l]}var Yfe={incrementalPrepareRender:{progress:function(r,e){e.view.incrementalRender(r,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(r,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},Fy="\0__throttleOriginMethod",uM="\0__throttleRate",cM="\0__throttleType";function PD(r,e,t){var i,n=0,a=0,s=null,o,l,u,c;e=e||0;function h(){a=new Date().getTime(),s=null,r.apply(l,u||[])}var d=function(){for(var f=[],p=0;p=0?h():s=setTimeout(h,-o),n=i};return d.clear=function(){s&&(clearTimeout(s),s=null)},d.debounceNextCall=function(f){c=f},d}function Vf(r,e,t,i){var n=r[e];if(n){var a=n[Fy]||n,s=n[cM],o=n[uM];if(o!==t||s!==i){if(t==null||!i)return r[e]=a;n=r[e]=PD(a,t,i==="debounce"),n[Fy]=a,n[cM]=i,n[uM]=t}return n}}function _v(r,e){var t=r[e];t&&t[Fy]&&(t.clear&&t.clear(),r[e]=t[Fy])}var hM=ot(),fM={itemStyle:tc(sH,!0),lineStyle:tc(aH,!0)},Kfe={lineStyle:"stroke",itemStyle:"fill"};function t$(r,e){var t=r.visualStyleMapper||fM[e];return t||(console.warn("Unknown style type '"+e+"'."),fM.itemStyle)}function r$(r,e){var t=r.visualDrawType||Kfe[e];return t||(console.warn("Unknown style type '"+e+"'."),"fill")}var Zfe={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData(),i=r.visualStyleAccessPath||"itemStyle",n=r.getModel(i),a=t$(r,i),s=a(n),o=n.getShallow("decal");o&&(t.setVisual("decal",o),o.dirty=!0);var l=r$(r,i),u=s[l],c=we(u)?u:null,h=s.fill==="auto"||s.stroke==="auto";if(!s[l]||c||h){var d=r.getColorFromPalette(r.name,null,e.getSeriesCount());s[l]||(s[l]=d,t.setVisual("colorFromPalette",!0)),s.fill=s.fill==="auto"||we(s.fill)?d:s.fill,s.stroke=s.stroke==="auto"||we(s.stroke)?d:s.stroke}if(t.setVisual("style",s),t.setVisual("drawType",l),!e.isSeriesFiltered(r)&&c)return t.setVisual("colorFromPalette",!1),{dataEach:function(f,p){var v=r.getDataParams(p),g=J({},s);g[l]=c(v),f.setItemVisual(p,"style",g)}}}},wd=new yt,Qfe={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!(r.ignoreStyleOnData||e.isSeriesFiltered(r))){var t=r.getData(),i=r.visualStyleAccessPath||"itemStyle",n=t$(r,i),a=t.getVisual("drawType");return{dataEach:t.hasItemOption?function(s,o){var l=s.getRawDataItem(o);if(l&&l[i]){wd.option=l[i];var u=n(wd),c=s.ensureUniqueItemVisual(o,"style");J(c,u),wd.option.decal&&(s.setItemVisual(o,"decal",wd.option.decal),wd.option.decal.dirty=!0),a in u&&s.setItemVisual(o,"colorFromPalette",!1)}}:null}}}},Jfe={performRawSeries:!0,overallReset:function(r){var e=be();r.eachSeries(function(t){var i=t.getColorBy();if(!t.isColorBySeries()){var n=t.type+"-"+i,a=e.get(n);a||(a={},e.set(n,a)),hM(t).scope=a}}),r.eachSeries(function(t){if(!(t.isColorBySeries()||r.isSeriesFiltered(t))){var i=t.getRawData(),n={},a=t.getData(),s=hM(t).scope,o=t.visualStyleAccessPath||"itemStyle",l=r$(t,o);a.each(function(u){var c=a.getRawIndex(u);n[c]=u}),i.each(function(u){var c=n[u],h=a.getItemVisual(c,"colorFromPalette");if(h){var d=a.ensureUniqueItemVisual(c,"style"),f=i.getName(u)||u+"",p=i.count();d[l]=t.getColorFromPalette(f,s,p)}})}})}},Sm=Math.PI;function ede(r,e){e=e||{},Ce(e,{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var t=new Le,i=new st({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});t.add(i);var n=new lt({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),a=new st({style:{fill:"none"},textContent:n,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});t.add(a);var s;return e.showSpinner&&(s=new c1({shape:{startAngle:-Sm/2,endAngle:-Sm/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001}),s.animateShape(!0).when(1e3,{endAngle:Sm*3/2}).start("circularInOut"),s.animateShape(!0).when(1e3,{startAngle:Sm*3/2}).delay(300).start("circularInOut"),t.add(s)),t.resize=function(){var o=n.getBoundingRect().width,l=e.showSpinner?e.spinnerRadius:0,u=(r.getWidth()-l*2-(e.showSpinner&&o?10:0)-o)/2-(e.showSpinner&&o?0:5+o/2)+(e.showSpinner?0:o/2)+(o?0:l),c=r.getHeight()/2;e.showSpinner&&s.setShape({cx:u,cy:c}),a.setShape({x:u-l,y:c-l,width:l*2,height:l*2}),i.setShape({x:0,y:0,width:r.getWidth(),height:r.getHeight()})},t.resize(),t}var i$=function(){function r(e,t,i,n){this._stageTaskMap=be(),this.ecInstance=e,this.api=t,i=this._dataProcessorHandlers=i.slice(),n=this._visualHandlers=n.slice(),this._allHandlers=i.concat(n)}return r.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(i){var n=i.overallTask;n&&n.dirty()})},r.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var i=this._pipelineMap.get(e.__pipeline.id),n=i.context,a=!t&&i.progressiveEnabled&&(!n||n.progressiveRender)&&e.__idxInPipeline>i.blockIndex,s=a?i.step:null,o=n&&n.modDataCount,l=o!=null?Math.ceil(o/s):null;return{step:s,modBy:l,modDataCount:o}}},r.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},r.prototype.updateStreamModes=function(e,t){var i=this._pipelineMap.get(e.uid),n=e.getData(),a=n.count(),s=i.progressiveEnabled&&t.incrementalPrepareRender&&a>=i.threshold,o=e.get("large")&&a>=e.get("largeThreshold"),l=e.get("progressiveChunkMode")==="mod"?a:null;e.pipelineContext=i.context={progressiveRender:s,modDataCount:l,large:o}},r.prototype.restorePipelines=function(e){var t=this,i=t._pipelineMap=be();e.eachSeries(function(n){var a=n.getProgressive(),s=n.uid;i.set(s,{id:s,head:null,tail:null,threshold:n.getProgressiveThreshold(),progressiveEnabled:a&&!(n.preventIncremental&&n.preventIncremental()),blockIndex:-1,step:Math.round(a||700),count:0}),t._pipe(n,n.dataTask)})},r.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),i=this.api;R(this._allHandlers,function(n){var a=e.get(n.uid)||e.set(n.uid,{}),s="";Ai(!(n.reset&&n.overallReset),s),n.reset&&this._createSeriesStageTask(n,a,t,i),n.overallReset&&this._createOverallStageTask(n,a,t,i)},this)},r.prototype.prepareView=function(e,t,i,n){var a=e.renderTask,s=a.context;s.model=t,s.ecModel=i,s.api=n,a.__block=!e.incrementalPrepareRender,this._pipe(t,a)},r.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},r.prototype.performVisualTasks=function(e,t,i){this._performStageTasks(this._visualHandlers,e,t,i)},r.prototype._performStageTasks=function(e,t,i,n){n=n||{};var a=!1,s=this;R(e,function(l,u){if(!(n.visualType&&n.visualType!==l.visualType)){var c=s._stageTaskMap.get(l.uid),h=c.seriesTaskMap,d=c.overallTask;if(d){var f,p=d.agentStubMap;p.each(function(g){o(n,g)&&(g.dirty(),f=!0)}),f&&d.dirty(),s.updatePayload(d,i);var v=s.getPerformArgs(d,n.block);p.each(function(g){g.perform(v)}),d.perform(v)&&(a=!0)}else h&&h.each(function(g,m){o(n,g)&&g.dirty();var y=s.getPerformArgs(g,n.block);y.skip=!l.performRawSeries&&t.isSeriesFiltered(g.context.model),s.updatePayload(g,i),g.perform(y)&&(a=!0)})}});function o(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}this.unfinished=a||this.unfinished},r.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(i){t=i.dataTask.perform()||t}),this.unfinished=t||this.unfinished},r.prototype.plan=function(){this._pipelineMap.each(function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)})},r.prototype.updatePayload=function(e,t){t!=="remain"&&(e.context.payload=t)},r.prototype._createSeriesStageTask=function(e,t,i,n){var a=this,s=t.seriesTaskMap,o=t.seriesTaskMap=be(),l=e.seriesType,u=e.getTargetSeries;e.createOnAllSeries?i.eachRawSeries(c):l?i.eachRawSeriesByType(l,c):u&&u(i,n).each(c);function c(h){var d=h.uid,f=o.set(d,s&&s.get(d)||Bp({plan:ade,reset:sde,count:lde}));f.context={model:h,ecModel:i,api:n,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:a},a._pipe(h,f)}},r.prototype._createOverallStageTask=function(e,t,i,n){var a=this,s=t.overallTask=t.overallTask||Bp({reset:tde});s.context={ecModel:i,api:n,overallReset:e.overallReset,scheduler:a};var o=s.agentStubMap,l=s.agentStubMap=be(),u=e.seriesType,c=e.getTargetSeries,h=!0,d=!1,f="";Ai(!e.createOnAllSeries,f),u?i.eachRawSeriesByType(u,p):c?c(i,n).each(p):(h=!1,R(i.getSeries(),p));function p(v){var g=v.uid,m=l.set(g,o&&o.get(g)||(d=!0,Bp({reset:rde,onDirty:nde})));m.context={model:v,overallProgress:h},m.agent=s,m.__block=h,a._pipe(v,m)}d&&s.dirty()},r.prototype._pipe=function(e,t){var i=e.uid,n=this._pipelineMap.get(i);!n.head&&(n.head=t),n.tail&&n.tail.pipe(t),n.tail=t,t.__idxInPipeline=n.count++,t.__pipeline=n},r.wrapStageHandler=function(e,t){return we(e)&&(e={overallReset:e,seriesType:ude(e)}),e.uid=Of("stageHandler"),t&&(e.visualType=t),e},r}();function tde(r){r.overallReset(r.ecModel,r.api,r.payload)}function rde(r){return r.overallProgress&&ide}function ide(){this.agent.dirty(),this.getDownstream().dirty()}function nde(){this.agent&&this.agent.dirty()}function ade(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function sde(r){r.useClearVisual&&r.data.clearAllVisual();var e=r.resetDefines=xt(r.reset(r.model,r.ecModel,r.api,r.payload));return e.length>1?oe(e,function(t,i){return n$(i)}):ode}var ode=n$(0);function n$(r){return function(e,t){var i=t.data,n=t.resetDefines[r];if(n&&n.dataEach)for(var a=e.start;a0&&f===u.length-d.length){var p=u.slice(0,f);p!=="data"&&(t.mainType=p,t[d.toLowerCase()]=l,c=!0)}}o.hasOwnProperty(u)&&(i[u]=l,c=!0),c||(n[u]=l)})}return{cptQuery:t,dataQuery:i,otherQuery:n}},r.prototype.filter=function(e,t){var i=this.eventInfo;if(!i)return!0;var n=i.targetEl,a=i.packedEvent,s=i.model,o=i.view;if(!s||!o)return!0;var l=t.cptQuery,u=t.dataQuery;return c(l,s,"mainType")&&c(l,s,"subType")&&c(l,s,"index","componentIndex")&&c(l,s,"name")&&c(l,s,"id")&&c(u,a,"name")&&c(u,a,"dataIndex")&&c(u,a,"dataType")&&(!o.filterForExposedEvent||o.filterForExposedEvent(e,t.otherQuery,n,a));function c(h,d,f,p){return h[f]==null||d[p||f]===h[f]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r}(),cw=["symbol","symbolSize","symbolRotate","symbolOffset"],gM=cw.concat(["symbolKeepAspect"]),fde={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData();if(r.legendIcon&&t.setVisual("legendIcon",r.legendIcon),!r.hasSymbolVisual)return;for(var i={},n={},a=!1,s=0;s=0&&Su(l)?l:.5;var u=r.createRadialGradient(s,o,0,s,o,l);return u}function hw(r,e,t){for(var i=e.type==="radial"?Dde(r,e,t):Ade(r,e,t),n=e.colorStops,a=0;a0)?null:r==="dashed"?[4*e,2*e]:r==="dotted"?[e]:ut(r)?[r]:ie(r)?r:null}function LD(r){var e=r.style,t=e.lineDash&&e.lineWidth>0&&Ide(e.lineDash,e.lineWidth),i=e.lineDashOffset;if(t){var n=e.strokeNoScale&&r.getLineScale?r.getLineScale():1;n&&n!==1&&(t=oe(t,function(a){return a/n}),i/=n)}return[t,i]}var Pde=new us(!0);function zy(r){var e=r.stroke;return!(e==null||e==="none"||!(r.lineWidth>0))}function mM(r){return typeof r=="string"&&r!=="none"}function Gy(r){var e=r.fill;return e!=null&&e!=="none"}function yM(r,e){if(e.fillOpacity!=null&&e.fillOpacity!==1){var t=r.globalAlpha;r.globalAlpha=e.fillOpacity*e.opacity,r.fill(),r.globalAlpha=t}else r.fill()}function _M(r,e){if(e.strokeOpacity!=null&&e.strokeOpacity!==1){var t=r.globalAlpha;r.globalAlpha=e.strokeOpacity*e.opacity,r.stroke(),r.globalAlpha=t}else r.stroke()}function fw(r,e,t){var i=nD(e.image,e.__image,t);if(n1(i)){var n=r.createPattern(i,e.repeat||"repeat");if(typeof DOMMatrix=="function"&&n&&n.setTransform){var a=new DOMMatrix;a.translateSelf(e.x||0,e.y||0),a.rotateSelf(0,0,(e.rotation||0)*d0),a.scaleSelf(e.scaleX||1,e.scaleY||1),n.setTransform(a)}return n}}function Mde(r,e,t,i){var n,a=zy(t),s=Gy(t),o=t.strokePercent,l=o<1,u=!e.path;(!e.silent||l)&&u&&e.createPathProxy();var c=e.path||Pde,h=e.__dirty;if(!i){var d=t.fill,f=t.stroke,p=s&&!!d.colorStops,v=a&&!!f.colorStops,g=s&&!!d.image,m=a&&!!f.image,y=void 0,_=void 0,b=void 0,T=void 0,x=void 0;(p||v)&&(x=e.getBoundingRect()),p&&(y=h?hw(r,d,x):e.__canvasFillGradient,e.__canvasFillGradient=y),v&&(_=h?hw(r,f,x):e.__canvasStrokeGradient,e.__canvasStrokeGradient=_),g&&(b=h||!e.__canvasFillPattern?fw(r,d,e):e.__canvasFillPattern,e.__canvasFillPattern=b),m&&(T=h||!e.__canvasStrokePattern?fw(r,f,e):e.__canvasStrokePattern,e.__canvasStrokePattern=b),p?r.fillStyle=y:g&&(b?r.fillStyle=b:s=!1),v?r.strokeStyle=_:m&&(T?r.strokeStyle=T:a=!1)}var C=e.getGlobalScale();c.setScale(C[0],C[1],e.segmentIgnoreThreshold);var D,I;r.setLineDash&&t.lineDash&&(n=LD(e),D=n[0],I=n[1]);var M=!0;(u||h&nh)&&(c.setDPR(r.dpr),l?c.setContext(null):(c.setContext(r),M=!1),c.reset(),e.buildPath(c,e.shape,i),c.toStatic(),e.pathUpdated()),M&&c.rebuildPath(r,l?o:1),D&&(r.setLineDash(D),r.lineDashOffset=I),i||(t.strokeFirst?(a&&_M(r,t),s&&yM(r,t)):(s&&yM(r,t),a&&_M(r,t))),D&&r.setLineDash([])}function Lde(r,e,t){var i=e.__image=nD(t.image,e.__image,e,e.onload);if(!(!i||!n1(i))){var n=t.x||0,a=t.y||0,s=e.getWidth(),o=e.getHeight(),l=i.width/i.height;if(s==null&&o!=null?s=o*l:o==null&&s!=null?o=s/l:s==null&&o==null&&(s=i.width,o=i.height),t.sWidth&&t.sHeight){var u=t.sx||0,c=t.sy||0;r.drawImage(i,u,c,t.sWidth,t.sHeight,n,a,s,o)}else if(t.sx&&t.sy){var u=t.sx,c=t.sy,h=s-u,d=o-c;r.drawImage(i,u,c,h,d,n,a,s,o)}else r.drawImage(i,n,a,s,o)}}function kde(r,e,t){var i,n=t.text;if(n!=null&&(n+=""),n){r.font=t.font||Jo,r.textAlign=t.textAlign,r.textBaseline=t.textBaseline;var a=void 0,s=void 0;r.setLineDash&&t.lineDash&&(i=LD(e),a=i[0],s=i[1]),a&&(r.setLineDash(a),r.lineDashOffset=s),t.strokeFirst?(zy(t)&&r.strokeText(n,t.x,t.y),Gy(t)&&r.fillText(n,t.x,t.y)):(Gy(t)&&r.fillText(n,t.x,t.y),zy(t)&&r.strokeText(n,t.x,t.y)),a&&r.setLineDash([])}}var bM=["shadowBlur","shadowOffsetX","shadowOffsetY"],SM=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function c$(r,e,t,i,n){var a=!1;if(!i&&(t=t||{},e===t))return!1;if(i||e.opacity!==t.opacity){zi(r,n),a=!0;var s=Math.max(Math.min(e.opacity,1),0);r.globalAlpha=isNaN(s)?Uu.opacity:s}(i||e.blend!==t.blend)&&(a||(zi(r,n),a=!0),r.globalCompositeOperation=e.blend||Uu.blend);for(var o=0;o0&&t.unfinished);t.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(t,i,n){if(!this[ti]){if(this._disposed){this.id;return}var a,s,o;if(De(i)&&(n=i.lazyUpdate,a=i.silent,s=i.replaceMerge,o=i.transition,i=i.notMerge),this[ti]=!0,!this._model||i){var l=new Xhe(this._api),u=this._theme,c=this._model=new CD;c.scheduler=this._scheduler,c.ssr=this._ssr,c.init(null,null,null,u,this._locale,l)}this._model.setOption(t,{replaceMerge:s},pw);var h={seriesTransition:o,optionChanged:!0};if(n)this[ki]={silent:a,updateParams:h},this[ti]=!1,this.getZr().wakeUp();else{try{Wc(this),yo.update.call(this,null,h)}catch(d){throw this[ki]=null,this[ti]=!1,d}this._ssr||this._zr.flush(),this[ki]=null,this[ti]=!1,Cd.call(this,a),Ad.call(this,a)}}},e.prototype.setTheme=function(){},e.prototype.getModel=function(){return this._model},e.prototype.getOption=function(){return this._model&&this._model.getOption()},e.prototype.getWidth=function(){return this._zr.getWidth()},e.prototype.getHeight=function(){return this._zr.getHeight()},e.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||et.hasGlobalWindow&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},e.prototype.renderToCanvas=function(t){t=t||{};var i=this._zr.painter;return i.getRenderedCanvas({backgroundColor:t.backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(t){t=t||{};var i=this._zr.painter;return i.renderToString({useViewBox:t.useViewBox})},e.prototype.getSvgDataURL=function(){if(et.svgSupported){var t=this._zr,i=t.storage.getDisplayList();return R(i,function(n){n.stopAnimation(null,!0)}),t.painter.toDataURL()}},e.prototype.getDataURL=function(t){if(this._disposed){this.id;return}t=t||{};var i=t.excludeComponents,n=this._model,a=[],s=this;R(i,function(l){n.eachComponent({mainType:l},function(u){var c=s._componentsMap[u.__viewId];c.group.ignore||(a.push(c),c.group.ignore=!0)})});var o=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return R(a,function(l){l.group.ignore=!1}),o},e.prototype.getConnectedDataURL=function(t){if(this._disposed){this.id;return}var i=t.type==="svg",n=this.group,a=Math.min,s=Math.max,o=1/0;if(NM[n]){var l=o,u=o,c=-o,h=-o,d=[],f=t&&t.pixelRatio||this.getDevicePixelRatio();R(Up,function(_,b){if(_.group===n){var T=i?_.getZr().painter.getSvgDom().innerHTML:_.renderToCanvas(Ee(t)),x=_.getDom().getBoundingClientRect();l=a(x.left,l),u=a(x.top,u),c=s(x.right,c),h=s(x.bottom,h),d.push({dom:T,left:x.left,top:x.top})}}),l*=f,u*=f,c*=f,h*=f;var p=c-l,v=h-u,g=el.createCanvas(),m=zP(g,{renderer:i?"svg":"canvas"});if(m.resize({width:p,height:v}),i){var y="";return R(d,function(_){var b=_.left-l,T=_.top-u;y+=''+_.dom+""}),m.painter.getSvgRoot().innerHTML=y,t.connectedBackgroundColor&&m.painter.setBackgroundColor(t.connectedBackgroundColor),m.refreshImmediately(),m.painter.toDataURL()}else return t.connectedBackgroundColor&&m.add(new st({shape:{x:0,y:0,width:p,height:v},style:{fill:t.connectedBackgroundColor}})),R(d,function(_){var b=new Wr({style:{x:_.left*f-l,y:_.top*f-u,image:_.dom}});m.add(b)}),m.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}else return this.getDataURL(t)},e.prototype.convertToPixel=function(t,i){return $b(this,"convertToPixel",t,i)},e.prototype.convertFromPixel=function(t,i){return $b(this,"convertFromPixel",t,i)},e.prototype.containPixel=function(t,i){if(this._disposed){this.id;return}var n=this._model,a,s=Lp(n,t);return R(s,function(o,l){l.indexOf("Models")>=0&&R(o,function(u){var c=u.coordinateSystem;if(c&&c.containPoint)a=a||!!c.containPoint(i);else if(l==="seriesModels"){var h=this._chartsMap[u.__viewId];h&&h.containPoint&&(a=a||h.containPoint(i,u))}},this)},this),!!a},e.prototype.getVisual=function(t,i){var n=this._model,a=Lp(n,t,{defaultMainType:"series"}),s=a.seriesModel,o=s.getData(),l=a.hasOwnProperty("dataIndexInside")?a.dataIndexInside:a.hasOwnProperty("dataIndex")?o.indexOfRawIndex(a.dataIndex):null;return l!=null?MD(o,l,i):ag(o,i)},e.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},e.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},e.prototype._initEvents=function(){var t=this;R(npe,function(i){var n=function(a){var s=t.getModel(),o=a.target,l,u=i==="globalout";if(u?l={}:o&&bu(o,function(p){var v=ke(p);if(v&&v.dataIndex!=null){var g=v.dataModel||s.getSeriesByIndex(v.seriesIndex);return l=g&&g.getDataParams(v.dataIndex,v.dataType,o)||{},!0}else if(v.eventData)return l=J({},v.eventData),!0},!0),l){var c=l.componentType,h=l.componentIndex;(c==="markLine"||c==="markPoint"||c==="markArea")&&(c="series",h=l.seriesIndex);var d=c&&h!=null&&s.getComponent(c,h),f=d&&t[d.mainType==="series"?"_chartsMap":"_componentsMap"][d.__viewId];l.event=a,l.type=i,t._$eventProcessor.eventInfo={targetEl:o,packedEvent:l,model:d,view:f},t.trigger(i,l)}};n.zrEventfulCallAtLast=!0,t._zr.on(i,n,t)}),R(Fp,function(i,n){t._messageCenter.on(n,function(a){this.trigger(n,a)},t)}),R(["selectchanged"],function(i){t._messageCenter.on(i,function(n){this.trigger(i,n)},t)}),pde(this._messageCenter,this,this._api)},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var t=this.getDom();t&&_G(this.getDom(),OD,"");var i=this,n=i._api,a=i._model;R(i._componentsViews,function(s){s.dispose(a,n)}),R(i._chartsViews,function(s){s.dispose(a,n)}),i._zr.dispose(),i._dom=i._model=i._chartsMap=i._componentsMap=i._chartsViews=i._componentsViews=i._scheduler=i._api=i._zr=i._throttledZrFlush=i._theme=i._coordSysMgr=i._messageCenter=null,delete Up[i.id]},e.prototype.resize=function(t){if(!this[ti]){if(this._disposed){this.id;return}this._zr.resize(t);var i=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!i){var n=i.resetOption("media"),a=t&&t.silent;this[ki]&&(a==null&&(a=this[ki].silent),n=!0,this[ki]=null),this[ti]=!0;try{n&&Wc(this),yo.update.call(this,{type:"resize",animation:J({duration:0},t&&t.animation)})}catch(s){throw this[ti]=!1,s}this[ti]=!1,Cd.call(this,a),Ad.call(this,a)}}},e.prototype.showLoading=function(t,i){if(this._disposed){this.id;return}if(De(t)&&(i=t,t=""),t=t||"default",this.hideLoading(),!!vw[t]){var n=vw[t](this._api,i),a=this._zr;this._loadingFX=n,a.add(n)}},e.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},e.prototype.makeActionFromEvent=function(t){var i=J({},t);return i.type=Fp[t.type],i},e.prototype.dispatchAction=function(t,i){if(this._disposed){this.id;return}if(De(i)||(i={silent:!!i}),!!Hy[t.type]&&this._model){if(this[ti]){this._pendingActions.push(t);return}var n=i.silent;qb.call(this,t,n);var a=i.flush;a?this._zr.flush():a!==!1&&et.browser.weChat&&this._throttledZrFlush(),Cd.call(this,n),Ad.call(this,n)}},e.prototype.updateLabelLayout=function(){oa.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(t){if(this._disposed){this.id;return}var i=t.seriesIndex,n=this.getModel(),a=n.getSeriesByIndex(i);a.appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()},e.internalField=function(){Wc=function(h){var d=h._scheduler;d.restorePipelines(h._model),d.prepareStageTasks(),Hb(h,!0),Hb(h,!1),d.plan()},Hb=function(h,d){for(var f=h._model,p=h._scheduler,v=d?h._componentsViews:h._chartsViews,g=d?h._componentsMap:h._chartsMap,m=h._zr,y=h._api,_=0;_d.get("hoverLayerThreshold")&&!et.node&&!et.worker&&d.eachSeries(function(g){if(!g.preventUsingHoverLayer){var m=h._chartsMap[g.__viewId];m.__alive&&m.eachRendered(function(y){y.states.emphasis&&(y.states.emphasis.hoverLayer=!0)})}})}function s(h,d){var f=h.get("blendMode")||null;d.eachRendered(function(p){p.isGroup||(p.style.blend=f)})}function o(h,d){if(!h.preventAutoZ){var f=h.get("z")||0,p=h.get("zlevel")||0;d.eachRendered(function(v){return l(v,f,p,-1/0),!0})}}function l(h,d,f,p){var v=h.getTextContent(),g=h.getTextGuideLine(),m=h.isGroup;if(m)for(var y=h.childrenRef(),_=0;_0?{duration:v,delay:f.get("delay"),easing:f.get("easing")}:null;d.eachRendered(function(m){if(m.states&&m.states.emphasis){if(Rh(m))return;if(m instanceof Qe&&Mce(m),m.__dirty){var y=m.prevStates;y&&m.useStates(y)}if(p){m.stateTransition=g;var _=m.getTextContent(),b=m.getTextGuideLine();_&&(_.stateTransition=g),b&&(b.stateTransition=g)}m.__dirty&&n(m)}})}RM=function(h){return new(function(d){j(f,d);function f(){return d!==null&&d.apply(this,arguments)||this}return f.prototype.getCoordinateSystems=function(){return h._coordSysMgr.getCoordinateSystems()},f.prototype.getComponentByElement=function(p){for(;p;){var v=p.__ecComponentInfo;if(v!=null)return h._model.getComponent(v.mainType,v.index);p=p.parent}},f.prototype.enterEmphasis=function(p,v){qs(p,v),An(h)},f.prototype.leaveEmphasis=function(p,v){js(p,v),An(h)},f.prototype.enterBlur=function(p){NG(p),An(h)},f.prototype.leaveBlur=function(p){uD(p),An(h)},f.prototype.enterSelect=function(p){BG(p),An(h)},f.prototype.leaveSelect=function(p){FG(p),An(h)},f.prototype.getModel=function(){return h.getModel()},f.prototype.getViewOfComponentModel=function(p){return h.getViewOfComponentModel(p)},f.prototype.getViewOfSeriesModel=function(p){return h.getViewOfSeriesModel(p)},f}(PH))(h)},C$=function(h){function d(f,p){for(var v=0;v=0)){BM.push(t);var a=i$.wrapStageHandler(t,n);a.__prio=e,a.__raw=t,r.push(a)}}function L$(r,e){vw[r]=e}function hpe(r,e,t){var i=Hde("registerMap");i&&i(r,e,t)}var fpe=Afe;fc(kD,Zfe);fc(x1,Qfe);fc(x1,Jfe);fc(kD,fde);fc(x1,dde);fc(_$,zde);P$(LH);M$(qde,sfe);L$("default",ede);hs({type:Vu,event:Vu,update:Vu},lr);hs({type:S0,event:S0,update:S0},lr);hs({type:kp,event:kp,update:kp},lr);hs({type:T0,event:T0,update:T0},lr);hs({type:Rp,event:Rp,update:Rp},lr);I$("light",cde);I$("dark",o$);var FM=[],dpe={registerPreprocessor:P$,registerProcessor:M$,registerPostInit:ope,registerPostUpdate:lpe,registerUpdateLifecycle:ND,registerAction:hs,registerCoordinateSystem:upe,registerLayout:cpe,registerVisual:fc,registerTransform:fpe,registerLoading:L$,registerMap:hpe,registerImpl:Gde,PRIORITY:tpe,ComponentModel:tt,ComponentView:$t,SeriesModel:Ot,ChartView:Ct,registerComponentModel:function(r){tt.registerClass(r)},registerComponentView:function(r){$t.registerClass(r)},registerSeriesModel:function(r){Ot.registerClass(r)},registerChartView:function(r){Ct.registerClass(r)},registerSubTypeDefaulter:function(r,e){tt.registerSubTypeDefaulter(r,e)},registerPainter:function(r,e){Zle(r,e)}};function Ze(r){if(ie(r)){R(r,function(e){Ze(e)});return}Xe(FM,r)>=0||(FM.push(r),we(r)&&(r={install:r}),r.install(dpe))}function Dd(r){return r==null?0:r.length||1}function UM(r){return r}var Xs=function(){function r(e,t,i,n,a,s){this._old=e,this._new=t,this._oldKeyGetter=i||UM,this._newKeyGetter=n||UM,this.context=a,this._diffModeMultiple=s==="multiple"}return r.prototype.add=function(e){return this._add=e,this},r.prototype.update=function(e){return this._update=e,this},r.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},r.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},r.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},r.prototype.remove=function(e){return this._remove=e,this},r.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},r.prototype._executeOneToOne=function(){var e=this._old,t=this._new,i={},n=new Array(e.length),a=new Array(t.length);this._initIndexMap(e,null,n,"_oldKeyGetter"),this._initIndexMap(t,i,a,"_newKeyGetter");for(var s=0;s1){var c=l.shift();l.length===1&&(i[o]=l[0]),this._update&&this._update(c,s)}else u===1?(i[o]=null,this._update&&this._update(l,s)):this._remove&&this._remove(s)}this._performRestAdd(a,i)},r.prototype._executeMultiple=function(){var e=this._old,t=this._new,i={},n={},a=[],s=[];this._initIndexMap(e,i,a,"_oldKeyGetter"),this._initIndexMap(t,n,s,"_newKeyGetter");for(var o=0;o1&&d===1)this._updateManyToOne&&this._updateManyToOne(c,u),n[l]=null;else if(h===1&&d>1)this._updateOneToMany&&this._updateOneToMany(c,u),n[l]=null;else if(h===1&&d===1)this._update&&this._update(c,u),n[l]=null;else if(h>1&&d>1)this._updateManyToMany&&this._updateManyToMany(c,u),n[l]=null;else if(h>1)for(var f=0;f1)for(var o=0;o30}var Ed=De,_o=oe,_pe=typeof Int32Array>"u"?Array:Int32Array,bpe="e\0\0",VM=-1,Spe=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],Tpe=["_approximateExtent"],zM,Am,Id,Pd,Yb,Dm,Kb,wi=function(){function r(e,t){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","lttbDownSample"];var i,n=!1;R$(e)?(i=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(n=!0,i=e),i=i||["x","y"];for(var a={},s=[],o={},l=!1,u={},c=0;c=t)){var i=this._store,n=i.getProvider();this._updateOrdinalMeta();var a=this._nameList,s=this._idList,o=n.getSource().sourceFormat,l=o===Qn;if(l&&!n.pure)for(var u=[],c=e;c0},r.prototype.ensureUniqueItemVisual=function(e,t){var i=this._itemVisuals,n=i[e];n||(n=i[e]={});var a=n[t];return a==null&&(a=this.getVisual(t),ie(a)?a=a.slice():Ed(a)&&(a=J({},a)),n[t]=a),a},r.prototype.setItemVisual=function(e,t,i){var n=this._itemVisuals[e]||{};this._itemVisuals[e]=n,Ed(t)?J(n,t):n[t]=i},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(e,t){Ed(e)?J(this._layout,e):this._layout[e]=t},r.prototype.getLayout=function(e){return this._layout[e]},r.prototype.getItemLayout=function(e){return this._itemLayouts[e]},r.prototype.setItemLayout=function(e,t,i){this._itemLayouts[e]=i?J(this._itemLayouts[e]||{},t):t},r.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},r.prototype.setItemGraphicEl=function(e,t){var i=this.hostModel&&this.hostModel.seriesIndex;jx(i,this.dataType,e,t),this._graphicEls[e]=t},r.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},r.prototype.eachItemGraphicEl=function(e,t){R(this._graphicEls,function(i,n){i&&e&&e.call(t,i,n)})},r.prototype.cloneShallow=function(e){return e||(e=new r(this._schema?this._schema:_o(this.dimensions,this._getDimInfo,this),this.hostModel)),Yb(e,this),e._store=this._store,e},r.prototype.wrapMethod=function(e,t){var i=this[e];we(i)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var n=i.apply(this,arguments);return t.apply(this,[n].concat(qA(arguments)))})},r.internalField=function(){zM=function(e){var t=e._invertedIndicesMap;R(t,function(i,n){var a=e._dimInfos[n],s=a.ordinalMeta,o=e._store;if(s){i=t[n]=new _pe(s.categories.length);for(var l=0;l1&&(l+="__ec__"+c),n[t]=l}}}(),r}();function sg(r,e){AD(r)||(r=DD(r)),e=e||{};var t=e.coordDimensions||[],i=e.dimensionsDefine||r.dimensionsDefine||[],n=be(),a=[],s=wpe(r,t,i,e.dimensionsCount),o=e.canOmitUnusedDimensions&&B$(s),l=i===r.dimensionsDefine,u=l?N$(r):O$(i),c=e.encodeDefine;!c&&e.encodeDefaulter&&(c=e.encodeDefaulter(r,s));for(var h=be(c),d=new HH(s),f=0;f0&&(i.name=n+(a-1)),a++,e.set(n,a)}}function wpe(r,e,t,i){var n=Math.max(r.dimensionsDetectedCount||1,e.length,t.length,i||0);return R(e,function(a){var s;De(a)&&(s=a.dimsDef)&&(n=Math.max(n,s.length))}),n}function Cpe(r,e,t){if(t||e.hasKey(r)){for(var i=0;e.hasKey(r+i);)i++;r+=i}return e.set(r,!0),r}var Ape=function(){function r(e){this.coordSysDims=[],this.axisMap=be(),this.categoryAxisMap=be(),this.coordSysName=e}return r}();function Dpe(r){var e=r.get("coordinateSystem"),t=new Ape(e),i=Epe[e];if(i)return i(r,t,t.axisMap,t.categoryAxisMap),t}var Epe={cartesian2d:function(r,e,t,i){var n=r.getReferringComponents("xAxis",mr).models[0],a=r.getReferringComponents("yAxis",mr).models[0];e.coordSysDims=["x","y"],t.set("x",n),t.set("y",a),qc(n)&&(i.set("x",n),e.firstCategoryDimIndex=0),qc(a)&&(i.set("y",a),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},singleAxis:function(r,e,t,i){var n=r.getReferringComponents("singleAxis",mr).models[0];e.coordSysDims=["single"],t.set("single",n),qc(n)&&(i.set("single",n),e.firstCategoryDimIndex=0)},polar:function(r,e,t,i){var n=r.getReferringComponents("polar",mr).models[0],a=n.findAxisModel("radiusAxis"),s=n.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],t.set("radius",a),t.set("angle",s),qc(a)&&(i.set("radius",a),e.firstCategoryDimIndex=0),qc(s)&&(i.set("angle",s),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},geo:function(r,e,t,i){e.coordSysDims=["lng","lat"]},parallel:function(r,e,t,i){var n=r.ecModel,a=n.getComponent("parallel",r.get("parallelIndex")),s=e.coordSysDims=a.dimensions.slice();R(a.parallelAxisIndex,function(o,l){var u=n.getComponent("parallelAxis",o),c=s[l];t.set(c,u),qc(u)&&(i.set(c,u),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=l))})}};function qc(r){return r.get("type")==="category"}function Ipe(r,e,t){t=t||{};var i=t.byIndex,n=t.stackedCoordDimension,a,s,o;Ppe(e)?a=e:(s=e.schema,a=s.dimensions,o=e.store);var l=!!(r&&r.get("stack")),u,c,h,d;if(R(a,function(y,_){pe(y)&&(a[_]=y={name:y}),l&&!y.isExtraCoord&&(!i&&!u&&y.ordinalMeta&&(u=y),!c&&y.type!=="ordinal"&&y.type!=="time"&&(!n||n===y.coordDim)&&(c=y))}),c&&!i&&!u&&(i=!0),c){h="__\0ecstackresult_"+r.id,d="__\0ecstackedover_"+r.id,u&&(u.createInvertedIndices=!0);var f=c.coordDim,p=c.type,v=0;R(a,function(y){y.coordDim===f&&v++});var g={name:h,coordDim:f,coordDimIndex:v,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},m={name:d,coordDim:d,coordDimIndex:v+1,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};s?(o&&(g.storeDimIndex=o.ensureCalculationDimension(d,p),m.storeDimIndex=o.ensureCalculationDimension(h,p)),s.appendCalculationDimension(g),s.appendCalculationDimension(m)):(a.push(g),a.push(m))}return{stackedDimension:c&&c.name,stackedByDimension:u&&u.name,isStackedByIndex:i,stackedOverDimension:d,stackResultDimension:h}}function Ppe(r){return!R$(r.schema)}function nl(r,e){return!!e&&e===r.getCalculationInfo("stackedDimension")}function F$(r,e){return nl(r,e)?r.getCalculationInfo("stackResultDimension"):e}function Mpe(r,e){var t=r.get("coordinateSystem"),i=ng.get(t),n;return e&&e.coordSysDims&&(n=oe(e.coordSysDims,function(a){var s={name:a},o=e.axisMap.get(a);if(o){var l=o.get("type");s.type=Wy(l)}return s})),n||(n=i&&(i.getDimensionsInfo?i.getDimensionsInfo():i.dimensions.slice())||["x","y"]),n}function Lpe(r,e,t){var i,n;return t&&R(r,function(a,s){var o=a.coordDim,l=t.categoryAxisMap.get(o);l&&(i==null&&(i=s),a.ordinalMeta=l.getOrdinalMeta(),e&&(a.createInvertedIndices=!0)),a.otherDims.itemName!=null&&(n=!0)}),!n&&i!=null&&(r[i].otherDims.itemName=0),i}function to(r,e,t){t=t||{};var i=e.getSourceManager(),n,a=!1;r?(a=!0,n=DD(r)):(n=i.getSource(),a=n.sourceFormat===Qn);var s=Dpe(e),o=Mpe(e,s),l=t.useEncodeDefaulter,u=we(l)?l:l?Ue(AH,o,e):null,c={coordDimensions:o,generateCoord:t.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!a},h=sg(n,c),d=Lpe(h.dimensions,t.createInvertedIndices,s),f=a?null:i.getSharedDataStore(h),p=Ipe(e,{schema:h,store:f}),v=new wi(h,e);v.setCalculationInfo(p);var g=d!=null&&kpe(n)?function(m,y,_,b){return b===d?_:this.defaultDimValueGetter(m,y,_,b)}:null;return v.hasItemOption=!1,v.initData(a?n:f,null,g),v}function kpe(r){if(r.sourceFormat===Qn){var e=Rpe(r.data||[]);return!ie(Pf(e))}}function Rpe(r){for(var e=0;et[1]&&(t[1]=e[1])},r.prototype.unionExtentFromData=function(e,t){this.unionExtent(e.getApproximateExtent(t))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.setExtent=function(e,t){var i=this._extent;isNaN(e)||(i[0]=e),isNaN(t)||(i[1]=t)},r.prototype.isInExtentRange=function(e){return this._extent[0]<=e&&this._extent[1]>=e},r.prototype.isBlank=function(){return this._isBlank},r.prototype.setBlank=function(e){this._isBlank=e},r}();i1(fs);var Ope=0,gw=function(){function r(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++Ope}return r.createByAxisModel=function(e){var t=e.option,i=t.data,n=i&&oe(i,Npe);return new r({categories:n,needCollect:!n,deduplication:t.dedplication!==!1})},r.prototype.getOrdinal=function(e){return this._getOrCreateMap().get(e)},r.prototype.parseAndCollect=function(e){var t,i=this._needCollect;if(!pe(e)&&!i)return e;if(i&&!this._deduplication)return t=this.categories.length,this.categories[t]=e,t;var n=this._getOrCreateMap();return t=n.get(e),t==null&&(i?(t=this.categories.length,this.categories[t]=e,n.set(e,t)):t=NaN),t},r.prototype._getOrCreateMap=function(){return this._map||(this._map=be(this.categories))},r}();function Npe(r){return De(r)&&r.value!=null?r.value:r+""}function mw(r){return r.type==="interval"||r.type==="log"}function Bpe(r,e,t,i){var n={},a=r[1]-r[0],s=n.interval=hG(a/e);t!=null&&si&&(s=n.interval=i);var o=n.intervalPrecision=U$(s),l=n.niceTickExtent=[er(Math.ceil(r[0]/s)*s,o),er(Math.floor(r[1]/s)*s,o)];return Fpe(l,r),n}function Zb(r){var e=Math.pow(10,eD(r)),t=r/e;return t?t===2?t=3:t===3?t=5:t*=2:t=1,er(t*e)}function U$(r){return Wa(r)+2}function GM(r,e,t){r[e]=Math.max(Math.min(r[e],t[1]),t[0])}function Fpe(r,e){!isFinite(r[0])&&(r[0]=e[0]),!isFinite(r[1])&&(r[1]=e[1]),GM(r,0,e),GM(r,1,e),r[0]>r[1]&&(r[0]=r[1])}function w1(r,e){return r>=e[0]&&r<=e[1]}function C1(r,e){return e[1]===e[0]?.5:(r-e[0])/(e[1]-e[0])}function A1(r,e){return r*(e[1]-e[0])+e[0]}var D1=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;i.type="ordinal";var n=i.getSetting("ordinalMeta");return n||(n=new gw({})),ie(n)&&(n=new gw({categories:oe(n,function(a){return De(a)?a.value:a})})),i._ordinalMeta=n,i._extent=i.getSetting("extent")||[0,n.categories.length-1],i}return e.prototype.parse=function(t){return t==null?NaN:pe(t)?this._ordinalMeta.getOrdinal(t):Math.round(t)},e.prototype.contain=function(t){return t=this.parse(t),w1(t,this._extent)&&this._ordinalMeta.categories[t]!=null},e.prototype.normalize=function(t){return t=this._getTickNumber(this.parse(t)),C1(t,this._extent)},e.prototype.scale=function(t){return t=Math.round(A1(t,this._extent)),this.getRawOrdinalNumber(t)},e.prototype.getTicks=function(){for(var t=[],i=this._extent,n=i[0];n<=i[1];)t.push({value:n}),n++;return t},e.prototype.getMinorTicks=function(t){},e.prototype.setSortInfo=function(t){if(t==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var i=t.ordinalNumbers,n=this._ordinalNumbersByTick=[],a=this._ticksByOrdinalNumber=[],s=0,o=this._ordinalMeta.categories.length,l=Math.min(o,i.length);s=0&&t=0&&t=t},e.prototype.getOrdinalMeta=function(){return this._ordinalMeta},e.prototype.calcNiceTicks=function(){},e.prototype.calcNiceExtent=function(){},e.type="ordinal",e}(fs);fs.registerClass(D1);var ql=er,Ys=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="interval",t._interval=0,t._intervalPrecision=2,t}return e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return w1(t,this._extent)},e.prototype.normalize=function(t){return C1(t,this._extent)},e.prototype.scale=function(t){return A1(t,this._extent)},e.prototype.setExtent=function(t,i){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(i)||(n[1]=parseFloat(i))},e.prototype.unionExtent=function(t){var i=this._extent;t[0]i[1]&&(i[1]=t[1]),this.setExtent(i[0],i[1])},e.prototype.getInterval=function(){return this._interval},e.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=U$(t)},e.prototype.getTicks=function(t){var i=this._interval,n=this._extent,a=this._niceExtent,s=this._intervalPrecision,o=[];if(!i)return o;var l=1e4;n[0]l)return[];var c=o.length?o[o.length-1].value:a[1];return n[1]>c&&(t?o.push({value:ql(c+i,s)}):o.push({value:n[1]})),o},e.prototype.getMinorTicks=function(t){for(var i=this.getTicks(!0),n=[],a=this.getExtent(),s=1;sa[0]&&f0&&(a=a===null?o:Math.min(a,o))}t[i]=a}}return t}function G$(r){var e=zpe(r),t=[];return R(r,function(i){var n=i.coordinateSystem,a=n.getBaseAxis(),s=a.getExtent(),o;if(a.type==="category")o=a.getBandWidth();else if(a.type==="value"||a.type==="time"){var l=a.dim+"_"+a.index,u=e[l],c=Math.abs(s[1]-s[0]),h=a.scale.getExtent(),d=Math.abs(h[1]-h[0]);o=u?c/d*u:c}else{var f=i.getData();o=Math.abs(s[1]-s[0])/f.count()}var p=ce(i.get("barWidth"),o),v=ce(i.get("barMaxWidth"),o),g=ce(i.get("barMinWidth")||(j$(i)?.5:1),o),m=i.get("barGap"),y=i.get("barCategoryGap");t.push({bandWidth:o,barWidth:p,barMaxWidth:v,barMinWidth:g,barGap:m,barCategoryGap:y,axisKey:UD(a),stackId:FD(i)})}),H$(t)}function H$(r){var e={};R(r,function(i,n){var a=i.axisKey,s=i.bandWidth,o=e[a]||{bandWidth:s,remainedWidth:s,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},l=o.stacks;e[a]=o;var u=i.stackId;l[u]||o.autoWidthCount++,l[u]=l[u]||{width:0,maxWidth:0};var c=i.barWidth;c&&!l[u].width&&(l[u].width=c,c=Math.min(o.remainedWidth,c),o.remainedWidth-=c);var h=i.barMaxWidth;h&&(l[u].maxWidth=h);var d=i.barMinWidth;d&&(l[u].minWidth=d);var f=i.barGap;f!=null&&(o.gap=f);var p=i.barCategoryGap;p!=null&&(o.categoryGap=p)});var t={};return R(e,function(i,n){t[n]={};var a=i.stacks,s=i.bandWidth,o=i.categoryGap;if(o==null){var l=rt(a).length;o=Math.max(35-l*4,15)+"%"}var u=ce(o,s),c=ce(i.gap,1),h=i.remainedWidth,d=i.autoWidthCount,f=(h-u)/(d+(d-1)*c);f=Math.max(f,0),R(a,function(m){var y=m.maxWidth,_=m.minWidth;if(m.width){var b=m.width;y&&(b=Math.min(b,y)),_&&(b=Math.max(b,_)),m.width=b,h-=b+c*b,d--}else{var b=f;y&&yb&&(b=_),b!==f&&(m.width=b,h-=b+c*b,d--)}}),f=(h-u)/(d+(d-1)*c),f=Math.max(f,0);var p=0,v;R(a,function(m,y){m.width||(m.width=f),v=m,p+=m.width*(1+c)}),v&&(p-=v.width*c);var g=-p/2;R(a,function(m,y){t[n][y]=t[n][y]||{bandWidth:s,offset:g,width:m.width},g+=m.width*(1+c)})}),t}function Gpe(r,e,t){if(r&&e){var i=r[UD(e)];return i!=null&&t!=null?i[FD(t)]:i}}function $$(r,e){var t=z$(r,e),i=G$(t);R(t,function(n){var a=n.getData(),s=n.coordinateSystem,o=s.getBaseAxis(),l=FD(n),u=i[UD(o)][l],c=u.offset,h=u.width;a.setLayout({bandWidth:u.bandWidth,offset:c,size:h})})}function W$(r){return{seriesType:r,plan:Uf(),reset:function(e){if(q$(e)){var t=e.getData(),i=e.coordinateSystem,n=i.getBaseAxis(),a=i.getOtherAxis(n),s=t.getDimensionIndex(t.mapDimension(a.dim)),o=t.getDimensionIndex(t.mapDimension(n.dim)),l=e.get("showBackground",!0),u=t.mapDimension(a.dim),c=t.getCalculationInfo("stackResultDimension"),h=nl(t,u)&&!!t.getCalculationInfo("stackedOnSeries"),d=a.isHorizontal(),f=Hpe(n,a),p=j$(e),v=e.get("barMinHeight")||0,g=c&&t.getDimensionIndex(c),m=t.getLayout("size"),y=t.getLayout("offset");return{progress:function(_,b){for(var T=_.count,x=p&&ja(T*3),C=p&&l&&ja(T*3),D=p&&ja(T),I=i.master.getRect(),M=d?I.width:I.height,L,N=b.getStore(),O=0;(L=_.next())!=null;){var B=N.get(h?g:s,L),F=N.get(o,L),U=f,$=void 0;h&&($=+B-N.get(s,L));var q=void 0,Z=void 0,te=void 0,Q=void 0;if(d){var se=i.dataToPoint([B,F]);if(h){var he=i.dataToPoint([$,F]);U=he[0]}q=U,Z=se[1]+y,te=se[0]-U,Q=m,Math.abs(te)0?t:1:t))}var $pe=function(r,e,t,i){for(;t>>1;r[n][1]n&&(this._approxInterval=n);var o=Em.length,l=Math.min($pe(Em,this._approxInterval,0,o),o-1);this._interval=Em[l][1],this._minLevelUnit=Em[Math.max(l-1,0)][0]},e.prototype.parse=function(t){return ut(t)?t:+ls(t)},e.prototype.contain=function(t){return w1(this.parse(t),this._extent)},e.prototype.normalize=function(t){return C1(this.parse(t),this._extent)},e.prototype.scale=function(t){return A1(t,this._extent)},e.type="time",e}(Ys),Em=[["second",yD],["minute",_D],["hour",Np],["quarter-day",Np*6],["half-day",Np*12],["day",Un*1.2],["half-week",Un*3.5],["week",Un*7],["month",Un*31],["quarter",Un*95],["half-year",M5/2],["year",M5]];function Wpe(r,e,t,i){var n=ls(e),a=ls(t),s=function(p){return k5(n,p,i)===k5(a,p,i)},o=function(){return s("year")},l=function(){return o()&&s("month")},u=function(){return l()&&s("day")},c=function(){return u()&&s("hour")},h=function(){return c()&&s("minute")},d=function(){return h()&&s("second")},f=function(){return d()&&s("millisecond")};switch(r){case"year":return o();case"month":return l();case"day":return u();case"hour":return c();case"minute":return h();case"second":return d();case"millisecond":return f()}}function qpe(r,e){return r/=Un,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function jpe(r){var e=30*Un;return r/=e,r>6?6:r>3?3:r>2?2:1}function Xpe(r){return r/=Np,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function HM(r,e){return r/=e?_D:yD,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function Ype(r){return hG(r)}function Kpe(r,e,t){var i=new Date(r);switch(Nh(e)){case"year":case"month":i[hH(t)](0);case"day":i[fH(t)](1);case"hour":i[dH(t)](0);case"minute":i[pH(t)](0);case"second":i[vH(t)](0),i[gH(t)](0)}return i.getTime()}function Zpe(r,e,t,i){var n=1e4,a=uH,s=0;function o(M,L,N,O,B,F,U){for(var $=new Date(L),q=L,Z=$[O]();q1&&F===0&&N.unshift({value:N[0].value-q})}}for(var F=0;F=i[0]&&y<=i[1]&&h++)}var _=(i[1]-i[0])/e;if(h>_*1.5&&d>_/1.5||(u.push(g),h>_||r===a[f]))break}c=[]}}}for(var b=Tt(oe(u,function(M){return Tt(M,function(L){return L.value>=i[0]&&L.value<=i[1]&&!L.notAdd})}),function(M){return M.length>0}),T=[],x=b.length-1,f=0;f0;)a*=10;var o=[er(eve(i[0]/a)*a),er(Jpe(i[1]/a)*a)];this._interval=a,this._niceExtent=o}},e.prototype.calcNiceExtent=function(t){Vp.calcNiceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return t=ia(t)/ia(this.base),w1(t,this._extent)},e.prototype.normalize=function(t){return t=ia(t)/ia(this.base),C1(t,this._extent)},e.prototype.scale=function(t){return t=A1(t,this._extent),Im(this.base,t)},e.type="log",e}(fs),X$=zD.prototype;X$.getMinorTicks=Vp.getMinorTicks;X$.getLabel=Vp.getLabel;function Pm(r,e){return Qpe(r,Wa(e))}fs.registerClass(zD);var tve=function(){function r(e,t,i){this._prepareParams(e,t,i)}return r.prototype._prepareParams=function(e,t,i){i[1]0&&l>0&&!u&&(o=0),o<0&&l<0&&!c&&(l=0));var d=this._determinedMin,f=this._determinedMax;return d!=null&&(o=d,u=!0),f!=null&&(l=f,c=!0),{min:o,max:l,minFixed:u,maxFixed:c,isBlank:h}},r.prototype.modifyDataMinMax=function(e,t){this[ive[e]]=t},r.prototype.setDeterminedMinMax=function(e,t){var i=rve[e];this[i]=t},r.prototype.freeze=function(){this.frozen=!0},r}(),rve={min:"_determinedMin",max:"_determinedMax"},ive={min:"_dataMin",max:"_dataMax"};function Y$(r,e,t){var i=r.rawExtentInfo;return i||(i=new tve(r,e,t),r.rawExtentInfo=i,i)}function Mm(r,e){return e==null?null:ov(e)?NaN:r.parse(e)}function K$(r,e){var t=r.type,i=Y$(r,e,r.getExtent()).calculate();r.setBlank(i.isBlank);var n=i.min,a=i.max,s=e.ecModel;if(s&&t==="time"){var o=z$("bar",s),l=!1;if(R(o,function(h){l=l||h.getBaseAxis()===e.axis}),l){var u=G$(o),c=nve(n,a,e,u);n=c.min,a=c.max}}return{extent:[n,a],fixMin:i.minFixed,fixMax:i.maxFixed}}function nve(r,e,t,i){var n=t.axis.getExtent(),a=n[1]-n[0],s=Gpe(i,t.axis);if(s===void 0)return{min:r,max:e};var o=1/0;R(s,function(f){o=Math.min(f.offset,o)});var l=-1/0;R(s,function(f){l=Math.max(f.offset+f.width,l)}),o=Math.abs(o),l=Math.abs(l);var u=o+l,c=e-r,h=1-(o+l)/a,d=c/h-c;return e+=d*(l/u),r-=d*(o/u),{min:r,max:e}}function hf(r,e){var t=e,i=K$(r,t),n=i.extent,a=t.get("splitNumber");r instanceof zD&&(r.base=t.get("logBase"));var s=r.type,o=t.get("interval"),l=s==="interval"||s==="time";r.setExtent(n[0],n[1]),r.calcNiceExtent({splitNumber:a,fixMin:i.fixMin,fixMax:i.fixMax,minInterval:l?t.get("minInterval"):null,maxInterval:l?t.get("maxInterval"):null}),o!=null&&r.setInterval&&r.setInterval(o)}function E1(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new D1({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:[1/0,-1/0]});case"time":return new VD({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new(fs.getClass(e)||Ys)}}function ave(r){var e=r.scale.getExtent(),t=e[0],i=e[1];return!(t>0&&i>0||t<0&&i<0)}function Gf(r){var e=r.getLabelModel().get("formatter"),t=r.type==="category"?r.scale.getExtent()[0]:null;return r.scale.type==="time"?function(i){return function(n,a){return r.scale.getFormattedLabel(n,a,i)}}(e):pe(e)?function(i){return function(n){var a=r.scale.getLabel(n),s=i.replace("{value}",a??"");return s}}(e):we(e)?function(i){return function(n,a){return t!=null&&(a=n.value-t),i(GD(r,n),a,n.level!=null?{level:n.level}:null)}}(e):function(i){return r.scale.getLabel(i)}}function GD(r,e){return r.type==="category"?r.scale.getLabel(e):e.value}function sve(r){var e=r.model,t=r.scale;if(!(!e.get(["axisLabel","show"])||t.isBlank())){var i,n,a=t.getExtent();t instanceof D1?n=t.count():(i=t.getTicks(),n=i.length);var s=r.getLabelModel(),o=Gf(r),l,u=1;n>40&&(u=Math.ceil(n/40));for(var c=0;cr[1]&&(r[1]=n[1])})}var og=function(){function r(){}return r.prototype.getNeedCrossZero=function(){var e=this.option;return!e.scale},r.prototype.getCoordSysModel=function(){},r}(),uve=1e-8;function WM(r,e){return Math.abs(r-e)n&&(i=s,n=l)}if(i)return hve(i.exterior);var u=this.getBoundingRect();return[u.x+u.width/2,u.y+u.height/2]},e.prototype.getBoundingRect=function(t){var i=this._rect;if(i&&!t)return i;var n=[1/0,1/0],a=[-1/0,-1/0],s=this.geometries;return R(s,function(o){o.type==="polygon"?qM(o.exterior,n,a,t):R(o.points,function(l){qM(l,n,a,t)})}),isFinite(n[0])&&isFinite(n[1])&&isFinite(a[0])&&isFinite(a[1])||(n[0]=n[1]=a[0]=a[1]=0),i=new qe(n[0],n[1],a[0]-n[0],a[1]-n[1]),t||(this._rect=i),i},e.prototype.contain=function(t){var i=this.getBoundingRect(),n=this.geometries;if(!i.contain(t[0],t[1]))return!1;e:for(var a=0,s=n.length;a>1^-(o&1),l=l>>1^-(l&1),o+=n,l+=a,n=o,a=l,i.push([o/t,l/t])}return i}function pve(r,e){return r=dve(r),oe(Tt(r.features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var i=t.properties,n=t.geometry,a=[];switch(n.type){case"Polygon":var s=n.coordinates;a.push(new jM(s[0],s.slice(1)));break;case"MultiPolygon":R(n.coordinates,function(l){l[0]&&a.push(new jM(l[0],l.slice(1)))});break;case"LineString":a.push(new XM([n.coordinates]));break;case"MultiLineString":a.push(new XM(n.coordinates))}var o=new J$(i[e||"name"],a,i.cp);return o.properties=i,o})}var Tv=ot();function tW(r,e){var t=oe(e,function(i){return r.scale.parse(i)});return r.type==="time"&&t.length>0&&(t.sort(),t.unshift(t[0]),t.push(t[t.length-1])),t}function vve(r){var e=r.getLabelModel().get("customValues");if(e){var t=Gf(r);return{labels:tW(r,e).map(function(i){var n={value:i};return{formattedLabel:t(n),rawLabel:r.scale.getLabel(n),tickValue:i}})}}return r.type==="category"?mve(r):_ve(r)}function gve(r,e){var t=r.getTickModel().get("customValues");return t?{ticks:tW(r,t)}:r.type==="category"?yve(r,e):{ticks:oe(r.scale.getTicks(),function(i){return i.value})}}function mve(r){var e=r.getLabelModel(),t=rW(r,e);return!e.get("show")||r.scale.isBlank()?{labels:[],labelCategoryInterval:t.labelCategoryInterval}:t}function rW(r,e){var t=iW(r,"labels"),i=HD(e),n=nW(t,i);if(n)return n;var a,s;return we(i)?a=oW(r,i):(s=i==="auto"?bve(r):i,a=sW(r,s)),aW(t,i,{labels:a,labelCategoryInterval:s})}function yve(r,e){var t=iW(r,"ticks"),i=HD(e),n=nW(t,i);if(n)return n;var a,s;if((!e.get("show")||r.scale.isBlank())&&(a=[]),we(i))a=oW(r,i,!0);else if(i==="auto"){var o=rW(r,r.getLabelModel());s=o.labelCategoryInterval,a=oe(o.labels,function(l){return l.tickValue})}else s=i,a=sW(r,s,!0);return aW(t,i,{ticks:a,tickCategoryInterval:s})}function _ve(r){var e=r.scale.getTicks(),t=Gf(r);return{labels:oe(e,function(i,n){return{level:i.level,formattedLabel:t(i,n),rawLabel:r.scale.getLabel(i),tickValue:i.value}})}}function iW(r,e){return Tv(r)[e]||(Tv(r)[e]=[])}function nW(r,e){for(var t=0;t40&&(o=Math.max(1,Math.floor(s/40)));for(var l=a[0],u=r.dataToCoord(l+1)-r.dataToCoord(l),c=Math.abs(u*Math.cos(i)),h=Math.abs(u*Math.sin(i)),d=0,f=0;l<=a[1];l+=o){var p=0,v=0,g=Kv(t({value:l}),e.font,"center","top");p=g.width*1.3,v=g.height*1.3,d=Math.max(d,p,7),f=Math.max(f,v,7)}var m=d/c,y=f/h;isNaN(m)&&(m=1/0),isNaN(y)&&(y=1/0);var _=Math.max(0,Math.floor(Math.min(m,y))),b=Tv(r.model),T=r.getExtent(),x=b.lastAutoInterval,C=b.lastTickCount;return x!=null&&C!=null&&Math.abs(x-_)<=1&&Math.abs(C-s)<=1&&x>_&&b.axisExtent0===T[0]&&b.axisExtent1===T[1]?_=x:(b.lastTickCount=s,b.lastAutoInterval=_,b.axisExtent0=T[0],b.axisExtent1=T[1]),_}function Tve(r){var e=r.getLabelModel();return{axisRotate:r.getRotate?r.getRotate():r.isHorizontal&&!r.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}function sW(r,e,t){var i=Gf(r),n=r.scale,a=n.getExtent(),s=r.getLabelModel(),o=[],l=Math.max((e||0)+1,1),u=a[0],c=n.count();u!==0&&l>1&&c/l>2&&(u=Math.round(Math.ceil(u/l)*l));var h=Z$(r),d=s.get("showMinLabel")||h,f=s.get("showMaxLabel")||h;d&&u!==a[0]&&v(a[0]);for(var p=u;p<=a[1];p+=l)v(p);f&&p-l!==a[1]&&v(a[1]);function v(g){var m={value:g};o.push(t?g:{formattedLabel:i(m),rawLabel:n.getLabel(m),tickValue:g})}return o}function oW(r,e,t){var i=r.scale,n=Gf(r),a=[];return R(i.getTicks(),function(s){var o=i.getLabel(s),l=s.value;e(s.value,o)&&a.push(t?l:{formattedLabel:n(s),rawLabel:o,tickValue:l})}),a}var YM=[0,1],xa=function(){function r(e,t,i){this.onBand=!1,this.inverse=!1,this.dim=e,this.scale=t,this._extent=i||[0,0]}return r.prototype.contain=function(e){var t=this._extent,i=Math.min(t[0],t[1]),n=Math.max(t[0],t[1]);return e>=i&&e<=n},r.prototype.containData=function(e){return this.scale.contain(e)},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.getPixelPrecision=function(e){return uG(e||this.scale.getExtent(),this._extent)},r.prototype.setExtent=function(e,t){var i=this._extent;i[0]=e,i[1]=t},r.prototype.dataToCoord=function(e,t){var i=this._extent,n=this.scale;return e=n.normalize(e),this.onBand&&n.type==="ordinal"&&(i=i.slice(),KM(i,n.count())),bt(e,YM,i,t)},r.prototype.coordToData=function(e,t){var i=this._extent,n=this.scale;this.onBand&&n.type==="ordinal"&&(i=i.slice(),KM(i,n.count()));var a=bt(e,i,YM,t);return this.scale.scale(a)},r.prototype.pointToData=function(e,t){},r.prototype.getTicksCoords=function(e){e=e||{};var t=e.tickModel||this.getTickModel(),i=gve(this,t),n=i.ticks,a=oe(n,function(o){return{coord:this.dataToCoord(this.scale.type==="ordinal"?this.scale.getRawOrdinalNumber(o):o),tickValue:o}},this),s=t.get("alignWithLabel");return xve(this,a,s,e.clamp),a},r.prototype.getMinorTicksCoords=function(){if(this.scale.type==="ordinal")return[];var e=this.model.getModel("minorTick"),t=e.get("splitNumber");t>0&&t<100||(t=5);var i=this.scale.getMinorTicks(t),n=oe(i,function(a){return oe(a,function(s){return{coord:this.dataToCoord(s),tickValue:s}},this)},this);return n},r.prototype.getViewLabels=function(){return vve(this).labels},r.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},r.prototype.getTickModel=function(){return this.model.getModel("axisTick")},r.prototype.getBandWidth=function(){var e=this._extent,t=this.scale.getExtent(),i=t[1]-t[0]+(this.onBand?1:0);i===0&&(i=1);var n=Math.abs(e[1]-e[0]);return Math.abs(n)/i},r.prototype.calculateCategoryInterval=function(){return Sve(this)},r}();function KM(r,e){var t=r[1]-r[0],i=e,n=t/i/2;r[0]+=n,r[1]-=n}function xve(r,e,t,i){var n=e.length;if(!r.onBand||t||!n)return;var a=r.getExtent(),s,o;if(n===1)e[0].coord=a[0],s=e[1]={coord:a[1]};else{var l=e[n-1].tickValue-e[0].tickValue,u=(e[n-1].coord-e[0].coord)/l;R(e,function(f){f.coord-=u/2});var c=r.scale.getExtent();o=1+c[1]-e[n-1].tickValue,s={coord:e[n-1].coord+u*o},e.push(s)}var h=a[0]>a[1];d(e[0].coord,a[0])&&(i?e[0].coord=a[0]:e.shift()),i&&d(a[0],e[0].coord)&&e.unshift({coord:a[0]}),d(a[1],s.coord)&&(i?s.coord=a[1]:e.pop()),i&&d(s.coord,a[1])&&e.push({coord:a[1]});function d(f,p){return f=er(f),p=er(p),h?f>p:fn&&(n+=Md);var f=Math.atan2(o,s);if(f<0&&(f+=Md),f>=i&&f<=n||f+Md>=i&&f+Md<=n)return l[0]=c,l[1]=h,u-t;var p=t*Math.cos(i)+r,v=t*Math.sin(i)+e,g=t*Math.cos(n)+r,m=t*Math.sin(n)+e,y=(p-s)*(p-s)+(v-o)*(v-o),_=(g-s)*(g-s)+(m-o)*(m-o);return y<_?(l[0]=p,l[1]=v,Math.sqrt(y)):(l[0]=g,l[1]=m,Math.sqrt(_))}function jy(r,e,t,i,n,a,s,o){var l=n-r,u=a-e,c=t-r,h=i-e,d=Math.sqrt(c*c+h*h);c/=d,h/=d;var f=l*c+u*h,p=f/d;o&&(p=Math.min(Math.max(p,0),1)),p*=d;var v=s[0]=r+p*c,g=s[1]=e+p*h;return Math.sqrt((v-n)*(v-n)+(g-a)*(g-a))}function lW(r,e,t,i,n,a,s){t<0&&(r=r+t,t=-t),i<0&&(e=e+i,i=-i);var o=r+t,l=e+i,u=s[0]=Math.min(Math.max(n,r),o),c=s[1]=Math.min(Math.max(a,e),l);return Math.sqrt((u-n)*(u-n)+(c-a)*(c-a))}var la=[];function Dve(r,e,t){var i=lW(e.x,e.y,e.width,e.height,r.x,r.y,la);return t.set(la[0],la[1]),i}function Eve(r,e,t){for(var i=0,n=0,a=0,s=0,o,l,u=1/0,c=e.data,h=r.x,d=r.y,f=0;f0){e=e/180*Math.PI,fa.fromArray(r[0]),Lt.fromArray(r[1]),ir.fromArray(r[2]),He.sub(Xa,fa,Lt),He.sub(Ua,ir,Lt);var t=Xa.len(),i=Ua.len();if(!(t<.001||i<.001)){Xa.scale(1/t),Ua.scale(1/i);var n=Xa.dot(Ua),a=Math.cos(e);if(a1&&He.copy(yi,ir),yi.toArray(r[1])}}}}function Ive(r,e,t){if(t<=180&&t>0){t=t/180*Math.PI,fa.fromArray(r[0]),Lt.fromArray(r[1]),ir.fromArray(r[2]),He.sub(Xa,Lt,fa),He.sub(Ua,ir,Lt);var i=Xa.len(),n=Ua.len();if(!(i<.001||n<.001)){Xa.scale(1/i),Ua.scale(1/n);var a=Xa.dot(e),s=Math.cos(t);if(a=l)He.copy(yi,ir);else{yi.scaleAndAdd(Ua,o/Math.tan(Math.PI/2-c));var h=ir.x!==Lt.x?(yi.x-Lt.x)/(ir.x-Lt.x):(yi.y-Lt.y)/(ir.y-Lt.y);if(isNaN(h))return;h<0?He.copy(yi,Lt):h>1&&He.copy(yi,ir)}yi.toArray(r[1])}}}}function eS(r,e,t,i){var n=t==="normal",a=n?r:r.ensureState(t);a.ignore=e;var s=i.get("smooth");s&&s===!0&&(s=.3),a.shape=a.shape||{},s>0&&(a.shape.smooth=s);var o=i.getModel("lineStyle").getLineStyle();n?r.useStyle(o):a.style=o}function Pve(r,e){var t=e.smooth,i=e.points;if(i)if(r.moveTo(i[0][0],i[0][1]),t>0&&i.length>=3){var n=Ro(i[0],i[1]),a=Ro(i[1],i[2]);if(!n||!a){r.lineTo(i[1][0],i[1][1]),r.lineTo(i[2][0],i[2][1]);return}var s=Math.min(n,a)*t,o=v0([],i[1],i[0],s/n),l=v0([],i[1],i[2],s/a),u=v0([],o,l,.5);r.bezierCurveTo(o[0],o[1],o[0],o[1],u[0],u[1]),r.bezierCurveTo(l[0],l[1],l[0],l[1],i[2][0],i[2][1])}else for(var c=1;c0&&a&&T(-c/s,0,s);var v=r[0],g=r[s-1],m,y;_(),m<0&&x(-m,.8),y<0&&x(y,.8),_(),b(m,y,1),b(y,m,-1),_(),m<0&&C(-m),y<0&&C(y);function _(){m=v.rect[e]-i,y=n-g.rect[e]-g.rect[t]}function b(D,I,M){if(D<0){var L=Math.min(I,-D);if(L>0){T(L*M,0,s);var N=L+D;N<0&&x(-N*M,1)}else x(-D*M,1)}}function T(D,I,M){D!==0&&(u=!0);for(var L=I;L0)for(var N=0;N0;N--){var U=M[N-1]*F;T(-U,N,s)}}}function C(D){var I=D<0?-1:1;D=Math.abs(D);for(var M=Math.ceil(D/(s-1)),L=0;L0?T(M,0,L+1):T(-M,s-L-1,s),D-=M,D<=0)return}return u}function Mve(r,e,t,i){return hW(r,"x","width",e,t,i)}function fW(r,e,t,i){return hW(r,"y","height",e,t,i)}function dW(r){var e=[];r.sort(function(v,g){return g.priority-v.priority});var t=new qe(0,0,0,0);function i(v){if(!v.ignore){var g=v.ensureState("emphasis");g.ignore==null&&(g.ignore=!1)}v.ignore=!0}for(var n=0;n=0&&i.attr(a.oldLayoutSelect),Xe(d,"emphasis")>=0&&i.attr(a.oldLayoutEmphasis)),ct(i,u,t,l)}else if(i.attr(u),!Rf(i).valueAnimation){var h=Be(i.style.opacity,1);i.style.opacity=0,Vt(i,{style:{opacity:h}},t,l)}if(a.oldLayout=u,i.states.select){var f=a.oldLayoutSelect={};Lm(f,u,km),Lm(f,i.states.select,km)}if(i.states.emphasis){var p=a.oldLayoutEmphasis={};Lm(p,u,km),Lm(p,i.states.emphasis,km)}nH(i,l,c,t,t)}if(n&&!n.ignore&&!n.invisible){var a=Rve(n),s=a.oldLayout,v={points:n.shape.points};s?(n.attr({shape:s}),ct(n,{shape:v},t)):(n.setShape(v),n.style.strokePercent=0,Vt(n,{style:{strokePercent:1}},t)),a.oldLayout=v}},r}(),rS=ot();function Nve(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,i){var n=rS(t).labelManager;n||(n=rS(t).labelManager=new Ove),n.clearLabels()}),r.registerUpdateLifecycle("series:layoutlabels",function(e,t,i){var n=rS(t).labelManager;i.updatedSeries.forEach(function(a){n.addLabelsOfSeries(t.getViewOfSeriesModel(a))}),n.updateLayoutConfig(t),n.layout(t),n.processLabelsOverall()})}var iS=Math.sin,nS=Math.cos,pW=Math.PI,Xl=Math.PI*2,Bve=180/pW,vW=function(){function r(){}return r.prototype.reset=function(e){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,e||4)},r.prototype.moveTo=function(e,t){this._add("M",e,t)},r.prototype.lineTo=function(e,t){this._add("L",e,t)},r.prototype.bezierCurveTo=function(e,t,i,n,a,s){this._add("C",e,t,i,n,a,s)},r.prototype.quadraticCurveTo=function(e,t,i,n){this._add("Q",e,t,i,n)},r.prototype.arc=function(e,t,i,n,a,s){this.ellipse(e,t,i,i,0,n,a,s)},r.prototype.ellipse=function(e,t,i,n,a,s,o,l){var u=o-s,c=!l,h=Math.abs(u),d=Uo(h-Xl)||(c?u>=Xl:-u>=Xl),f=u>0?u%Xl:u%Xl+Xl,p=!1;d?p=!0:Uo(h)?p=!1:p=f>=pW==!!c;var v=e+i*nS(s),g=t+n*iS(s);this._start&&this._add("M",v,g);var m=Math.round(a*Bve);if(d){var y=1/this._p,_=(c?1:-1)*(Xl-y);this._add("A",i,n,m,1,+c,e+i*nS(s+_),t+n*iS(s+_)),y>.01&&this._add("A",i,n,m,0,+c,v,g)}else{var b=e+i*nS(o),T=t+n*iS(o);this._add("A",i,n,m,+p,+c,b,T)}},r.prototype.rect=function(e,t,i,n){this._add("M",e,t),this._add("l",i,0),this._add("l",0,n),this._add("l",-i,0),this._add("Z")},r.prototype.closePath=function(){this._d.length>0&&this._add("Z")},r.prototype._add=function(e,t,i,n,a,s,o,l,u){for(var c=[],h=this._p,d=1;d"}function qve(r){return""}function jD(r,e){e=e||{};var t=e.newline?` +`:"";function i(n){var a=n.children,s=n.tag,o=n.attrs,l=n.text;return Wve(s,o)+(s!=="style"?Bi(l):l||"")+(a?""+t+oe(a,function(u){return i(u)}).join(t)+t:"")+qve(s)}return i(r)}function jve(r,e,t){t=t||{};var i=t.newline?` +`:"",n=" {"+i,a=i+"}",s=oe(rt(r),function(l){return l+n+oe(rt(r[l]),function(u){return u+":"+r[l][u]+";"}).join(i)+a}).join(i),o=oe(rt(e),function(l){return"@keyframes "+l+n+oe(rt(e[l]),function(u){return u+n+oe(rt(e[l][u]),function(c){var h=e[l][u][c];return c==="d"&&(h='path("'+h+'")'),c+":"+h+";"}).join(i)+a}).join(i)+a}).join(i);return!s&&!o?"":[""].join(i)}function bw(r){return{zrId:r,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssStyleCache:{},cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function eL(r,e,t,i){return Rr("svg","root",{width:r,height:e,xmlns:gW,"xmlns:xlink":mW,version:"1.1",baseProfile:"full",viewBox:i?"0 0 "+r+" "+e:!1},t)}var Xve=0;function _W(){return Xve++}var tL={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},Jl="transform-origin";function Yve(r,e,t){var i=J({},r.shape);J(i,e),r.buildPath(t,i);var n=new vW;return n.reset(eG(r)),t.rebuildPath(n,1),n.generateStr(),n.getStr()}function Kve(r,e){var t=e.originX,i=e.originY;(t||i)&&(r[Jl]=t+"px "+i+"px")}var Zve={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function bW(r,e){var t=e.zrId+"-ani-"+e.cssAnimIdx++;return e.cssAnims[t]=r,t}function Qve(r,e,t){var i=r.shape.paths,n={},a,s;if(R(i,function(l){var u=bw(t.zrId);u.animation=!0,I1(l,{},u,!0);var c=u.cssAnims,h=u.cssNodes,d=rt(c),f=d.length;if(f){s=d[f-1];var p=c[s];for(var v in p){var g=p[v];n[v]=n[v]||{d:""},n[v].d+=g.d||""}for(var m in h){var y=h[m].animation;y.indexOf(s)>=0&&(a=y)}}}),!!a){e.d=!1;var o=bW(n,t);return a.replace(s,o)}}function rL(r){return pe(r)?tL[r]?"cubic-bezier("+tL[r]+")":ZA(r)?r:"":""}function I1(r,e,t,i){var n=r.animators,a=n.length,s=[];if(r instanceof fD){var o=Qve(r,e,t);if(o)s.push(o);else if(!a)return}else if(!a)return;for(var l={},u=0;u0}).length){var Fe=bW(C,t);return Fe+" "+y[0]+" both"}}for(var g in l){var o=v(l[g]);o&&s.push(o)}if(s.length){var m=t.zrId+"-cls-"+_W();t.cssNodes["."+m]={animation:s.join(",")},e.class=m}}function Jve(r,e,t){if(!r.ignore)if(r.isSilent()){var i={"pointer-events":"none"};iL(i,e,t)}else{var n=r.states.emphasis&&r.states.emphasis.style?r.states.emphasis.style:{},a=n.fill;if(!a){var s=r.style&&r.style.fill,o=r.states.select&&r.states.select.style&&r.states.select.style.fill,l=r.currentStates.indexOf("select")>=0&&o||s;l&&(a=Lx(l))}var u=n.lineWidth;if(u){var c=!n.strokeNoScale&&r.transform?r.transform[0]:1;u=u/c}var i={cursor:"pointer"};a&&(i.fill=a),n.stroke&&(i.stroke=n.stroke),u&&(i["stroke-width"]=u),iL(i,e,t)}}function iL(r,e,t,i){var n=JSON.stringify(r),a=t.cssStyleCache[n];a||(a=t.zrId+"-cls-"+_W(),t.cssStyleCache[n]=a,t.cssNodes["."+a+":hover"]=r),e.class=e.class?e.class+" "+a:a}var xv=Math.round;function SW(r){return r&&pe(r.src)}function TW(r){return r&&we(r.toDataURL)}function XD(r,e,t,i){Gve(function(n,a){var s=n==="fill"||n==="stroke";s&&Jz(a)?wW(e,r,n,i):s&&QA(a)?CW(t,r,n,i):s&&a==="none"?r[n]="transparent":r[n]=a},e,t,!1),sge(t,r,i)}function YD(r,e){var t=Qle(e);t&&(t.each(function(i,n){i!=null&&(r[(JM+n).toLowerCase()]=i+"")}),e.isSilent()&&(r[JM+"silent"]="true"))}function nL(r){return Uo(r[0]-1)&&Uo(r[1])&&Uo(r[2])&&Uo(r[3]-1)}function ege(r){return Uo(r[4])&&Uo(r[5])}function KD(r,e,t){if(e&&!(ege(e)&&nL(e))){var i=1e4;r.transform=nL(e)?"translate("+xv(e[4]*i)/i+" "+xv(e[5]*i)/i+")":Sle(e)}}function aL(r,e,t){for(var i=r.points,n=[],a=0;a"u"){var g="Image width/height must been given explictly in svg-ssr renderer.";Ai(d,g),Ai(f,g)}else if(d==null||f==null){var m=function(M,L){if(M){var N=M.elm,O=d||L.width,B=f||L.height;M.tag==="pattern"&&(u?(B=1,O/=a.width):c&&(O=1,B/=a.height)),M.attrs.width=O,M.attrs.height=B,N&&(N.setAttribute("width",O),N.setAttribute("height",B))}},y=nD(p,null,r,function(M){l||m(x,M),m(h,M)});y&&y.width&&y.height&&(d=d||y.width,f=f||y.height)}h=Rr("image","img",{href:p,width:d,height:f}),s.width=d,s.height=f}else n.svgElement&&(h=Ee(n.svgElement),s.width=n.svgWidth,s.height=n.svgHeight);if(h){var _,b;l?_=b=1:u?(b=1,_=s.width/a.width):c?(_=1,b=s.height/a.height):s.patternUnits="userSpaceOnUse",_!=null&&!isNaN(_)&&(s.width=_),b!=null&&!isNaN(b)&&(s.height=b);var T=tG(n);T&&(s.patternTransform=T);var x=Rr("pattern","",s,[h]),C=jD(x),D=i.patternCache,I=D[C];I||(I=i.zrId+"-p"+i.patternIdx++,D[C]=I,s.id=I,x=i.defs[I]=Rr("pattern",I,s,[h])),e[t]=e1(I)}}function oge(r,e,t){var i=t.clipPathCache,n=t.defs,a=i[r.id];if(!a){a=t.zrId+"-c"+t.clipPathIdx++;var s={id:a};i[r.id]=a,n[a]=Rr("clipPath",a,s,[xW(r,t)])}e["clip-path"]=e1(a)}function lL(r){return document.createTextNode(r)}function uu(r,e,t){r.insertBefore(e,t)}function uL(r,e){r.removeChild(e)}function cL(r,e){r.appendChild(e)}function AW(r){return r.parentNode}function DW(r){return r.nextSibling}function aS(r,e){r.textContent=e}var hL=58,lge=120,uge=Rr("","");function Sw(r){return r===void 0}function Oa(r){return r!==void 0}function cge(r,e,t){for(var i={},n=e;n<=t;++n){var a=r[n].key;a!==void 0&&(i[a]=n)}return i}function lp(r,e){var t=r.key===e.key,i=r.tag===e.tag;return i&&t}function wv(r){var e,t=r.children,i=r.tag;if(Oa(i)){var n=r.elm=yW(i);if(ZD(uge,r),ie(t))for(e=0;ea?(p=t[l+1]==null?null:t[l+1].elm,EW(r,p,t,n,l)):Yy(r,e,i,a))}function sh(r,e){var t=e.elm=r.elm,i=r.children,n=e.children;r!==e&&(ZD(r,e),Sw(e.text)?Oa(i)&&Oa(n)?i!==n&&hge(t,i,n):Oa(n)?(Oa(r.text)&&aS(t,""),EW(t,null,n,0,n.length-1)):Oa(i)?Yy(t,i,0,i.length-1):Oa(r.text)&&aS(t,""):r.text!==e.text&&(Oa(i)&&Yy(t,i,0,i.length-1),aS(t,e.text)))}function fge(r,e){if(lp(r,e))sh(r,e);else{var t=r.elm,i=AW(t);wv(e),i!==null&&(uu(i,e.elm,DW(t)),Yy(i,[r],0,0))}return e}var dge=0,pge=function(){function r(e,t,i){if(this.type="svg",this.refreshHover=fL(),this.configLayer=fL(),this.storage=t,this._opts=i=J({},i),this.root=e,this._id="zr"+dge++,this._oldVNode=eL(i.width,i.height),e&&!i.ssr){var n=this._viewport=document.createElement("div");n.style.cssText="position:relative;overflow:hidden";var a=this._svgDom=this._oldVNode.elm=yW("svg");ZD(null,this._oldVNode),n.appendChild(a),e.appendChild(n)}this.resize(i.width,i.height)}return r.prototype.getType=function(){return this.type},r.prototype.getViewportRoot=function(){return this._viewport},r.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},r.prototype.getSvgDom=function(){return this._svgDom},r.prototype.refresh=function(){if(this.root){var e=this.renderToVNode({willUpdate:!0});e.attrs.style="position:absolute;left:0;top:0;user-select:none",fge(this._oldVNode,e),this._oldVNode=e}},r.prototype.renderOneToVNode=function(e){return oL(e,bw(this._id))},r.prototype.renderToVNode=function(e){e=e||{};var t=this.storage.getDisplayList(!0),i=this._width,n=this._height,a=bw(this._id);a.animation=e.animation,a.willUpdate=e.willUpdate,a.compress=e.compress,a.emphasis=e.emphasis;var s=[],o=this._bgVNode=vge(i,n,this._backgroundColor,a);o&&s.push(o);var l=e.compress?null:this._mainVNode=Rr("g","main",{},[]);this._paintList(t,a,l?l.children:s),l&&s.push(l);var u=oe(rt(a.defs),function(d){return a.defs[d]});if(u.length&&s.push(Rr("defs","defs",{},u)),e.animation){var c=jve(a.cssNodes,a.cssAnims,{newline:!0});if(c){var h=Rr("style","stl",{},[],c);s.push(h)}}return eL(i,n,s,e.useViewBox)},r.prototype.renderToString=function(e){return e=e||{},jD(this.renderToVNode({animation:Be(e.cssAnimation,!0),emphasis:Be(e.cssEmphasis,!0),willUpdate:!1,compress:!0,useViewBox:Be(e.useViewBox,!0)}),{newline:!0})},r.prototype.setBackgroundColor=function(e){this._backgroundColor=e},r.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},r.prototype._paintList=function(e,t,i){for(var n=e.length,a=[],s=0,o,l,u=0,c=0;c=0&&!(d&&l&&d[v]===l[v]);v--);for(var g=p-1;g>v;g--)s--,o=a[s-1];for(var m=v+1;m=o)}}for(var h=this.__startIndex;h15)break}}B.prevElClipPaths&&m.restore()};if(y)if(y.length===0)D=g.__endIndex;else for(var M=f.dpr,L=0;L0&&e>n[0]){for(l=0;le);l++);o=i[n[l]]}if(n.splice(l+1,0,e),i[e]=t,!t.virtual)if(o){var u=o.dom;u.nextSibling?s.insertBefore(t.dom,u.nextSibling):s.appendChild(t.dom)}else s.firstChild?s.insertBefore(t.dom,s.firstChild):s.appendChild(t.dom);t.painter||(t.painter=this)}},r.prototype.eachLayer=function(e,t){for(var i=this._zlevelList,n=0;n0?Rm:0),this._needsManuallyCompositing),c.__builtin__||$A("ZLevel "+u+" has been used by unkown layer "+c.id),c!==a&&(c.__used=!0,c.__startIndex!==l&&(c.__dirty=!0),c.__startIndex=l,c.incremental?c.__drawIndex=-1:c.__drawIndex=l,t(l),a=c),n.__dirty&cn&&!n.__inHover&&(c.__dirty=!0,c.incremental&&c.__drawIndex<0&&(c.__drawIndex=l))}t(l),this.eachBuiltinLayer(function(h,d){!h.__used&&h.getElementCount()>0&&(h.__dirty=!0,h.__startIndex=h.__endIndex=h.__drawIndex=0),h.__dirty&&h.__drawIndex<0&&(h.__drawIndex=h.__startIndex)})},r.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},r.prototype._clearLayer=function(e){e.clear()},r.prototype.setBackgroundColor=function(e){this._backgroundColor=e,R(this._layers,function(t){t.setUnpainted()})},r.prototype.configLayer=function(e,t){if(t){var i=this._layerConfig;i[e]?We(i[e],t,!0):i[e]=t;for(var n=0;n-1&&(u.style.stroke=u.style.fill,u.style.fill="#fff",u.style.lineWidth=2),i},e.type="series.line",e.dependencies=["grid","polar"],e.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},e}(Ot);function ff(r,e){var t=r.mapDimensionsAll("defaultedLabel"),i=t.length;if(i===1){var n=uf(r,e,t[0]);return n!=null?n+"":null}else if(i){for(var a=[],s=0;s=0&&i.push(e[a])}return i.join(" ")}var lg=function(r){j(e,r);function e(t,i,n,a){var s=r.call(this)||this;return s.updateData(t,i,n,a),s}return e.prototype._createSymbol=function(t,i,n,a,s){this.removeAll();var o=yr(t,-1,-1,2,2,null,s);o.attr({z2:100,culling:!0,scaleX:a[0]/2,scaleY:a[1]/2}),o.drift=xge,this._symbolType=t,this.add(o)},e.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},e.prototype.getSymbolType=function(){return this._symbolType},e.prototype.getSymbolPath=function(){return this.childAt(0)},e.prototype.highlight=function(){qs(this.childAt(0))},e.prototype.downplay=function(){js(this.childAt(0))},e.prototype.setZ=function(t,i){var n=this.childAt(0);n.zlevel=t,n.z=i},e.prototype.setDraggable=function(t,i){var n=this.childAt(0);n.draggable=t,n.cursor=!i&&t?"move":n.cursor},e.prototype.updateData=function(t,i,n,a){this.silent=!1;var s=t.getItemVisual(i,"symbol")||"circle",o=t.hostModel,l=e.getSymbolSize(t,i),u=s!==this._symbolType,c=a&&a.disableAnimation;if(u){var h=t.getItemVisual(i,"symbolKeepAspect");this._createSymbol(s,t,i,l,h)}else{var d=this.childAt(0);d.silent=!1;var f={scaleX:l[0]/2,scaleY:l[1]/2};c?d.attr(f):ct(d,f,o,i),_a(d)}if(this._updateCommon(t,i,l,n,a),u){var d=this.childAt(0);if(!c){var f={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:d.style.opacity}};d.scaleX=d.scaleY=0,d.style.opacity=0,Vt(d,f,o,i)}}c&&this.childAt(0).stopAnimation("leave")},e.prototype._updateCommon=function(t,i,n,a,s){var o=this.childAt(0),l=t.hostModel,u,c,h,d,f,p,v,g,m;if(a&&(u=a.emphasisItemStyle,c=a.blurItemStyle,h=a.selectItemStyle,d=a.focus,f=a.blurScope,v=a.labelStatesModels,g=a.hoverScale,m=a.cursorStyle,p=a.emphasisDisabled),!a||t.hasItemOption){var y=a&&a.itemModel?a.itemModel:t.getItemModel(i),_=y.getModel("emphasis");u=_.getModel("itemStyle").getItemStyle(),h=y.getModel(["select","itemStyle"]).getItemStyle(),c=y.getModel(["blur","itemStyle"]).getItemStyle(),d=_.get("focus"),f=_.get("blurScope"),p=_.get("disabled"),v=Nr(y),g=_.getShallow("scale"),m=y.getShallow("cursor")}var b=t.getItemVisual(i,"symbolRotate");o.attr("rotation",(b||0)*Math.PI/180||0);var T=hc(t.getItemVisual(i,"symbolOffset"),n);T&&(o.x=T[0],o.y=T[1]),m&&o.attr("cursor",m);var x=t.getItemVisual(i,"style"),C=x.fill;if(o instanceof Wr){var D=o.style;o.useStyle(J({image:D.image,x:D.x,y:D.y,width:D.width,height:D.height},x))}else o.__isEmptyBrush?o.useStyle(J({},x)):o.useStyle(x),o.style.decal=null,o.setColor(C,s&&s.symbolInnerColor),o.style.strokeNoScale=!0;var I=t.getItemVisual(i,"liftZ"),M=this._z2;I!=null?M==null&&(this._z2=o.z2,o.z2+=I):M!=null&&(o.z2=M,this._z2=null);var L=s&&s.useNameLabel;Jr(o,v,{labelFetcher:l,labelDataIndex:i,defaultText:N,inheritColor:C,defaultOpacity:x.opacity});function N(F){return L?t.getName(F):ff(t,F)}this._sizeX=n[0]/2,this._sizeY=n[1]/2;var O=o.ensureState("emphasis");O.style=u,o.ensureState("select").style=h,o.ensureState("blur").style=c;var B=g==null||g===!0?Math.max(1.1,3/this._sizeY):isFinite(g)&&g>0?+g:1;O.scaleX=this._sizeX*B,O.scaleY=this._sizeY*B,this.setSymbolScale(1),Yt(this,d,f,p)},e.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},e.prototype.fadeOut=function(t,i,n){var a=this.childAt(0),s=ke(this).dataIndex,o=n&&n.animation;if(this.silent=a.silent=!0,n&&n.fadeLabel){var l=a.getTextContent();l&&rl(l,{style:{opacity:0}},i,{dataIndex:s,removeOpt:o,cb:function(){a.removeTextContent()}})}else a.removeTextContent();rl(a,{style:{opacity:0},scaleX:0,scaleY:0},i,{dataIndex:s,cb:t,removeOpt:o})},e.getSymbolSize=function(t,i){return zf(t.getItemVisual(i,"symbolSize"))},e}(Le);function xge(r,e){this.parent.drift(r,e)}function oS(r,e,t,i){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(i.isIgnore&&i.isIgnore(t))&&!(i.clipShape&&!i.clipShape.contain(e[0],e[1]))&&r.getItemVisual(t,"symbol")!=="none"}function vL(r){return r!=null&&!De(r)&&(r={isIgnore:r}),r||{}}function gL(r){var e=r.hostModel,t=e.getModel("emphasis");return{emphasisItemStyle:t.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:t.get("focus"),blurScope:t.get("blurScope"),emphasisDisabled:t.get("disabled"),hoverScale:t.get("scale"),labelStatesModels:Nr(e),cursorStyle:e.get("cursor")}}var ug=function(){function r(e){this.group=new Le,this._SymbolCtor=e||lg}return r.prototype.updateData=function(e,t){this._progressiveEls=null,t=vL(t);var i=this.group,n=e.hostModel,a=this._data,s=this._SymbolCtor,o=t.disableAnimation,l=gL(e),u={disableAnimation:o},c=t.getSymbolPoint||function(h){return e.getItemLayout(h)};a||i.removeAll(),e.diff(a).add(function(h){var d=c(h);if(oS(e,d,h,t)){var f=new s(e,h,l,u);f.setPosition(d),e.setItemGraphicEl(h,f),i.add(f)}}).update(function(h,d){var f=a.getItemGraphicEl(d),p=c(h);if(!oS(e,p,h,t)){i.remove(f);return}var v=e.getItemVisual(h,"symbol")||"circle",g=f&&f.getSymbolType&&f.getSymbolType();if(!f||g&&g!==v)i.remove(f),f=new s(e,h,l,u),f.setPosition(p);else{f.updateData(e,h,l,u);var m={x:p[0],y:p[1]};o?f.attr(m):ct(f,m,n)}i.add(f),e.setItemGraphicEl(h,f)}).remove(function(h){var d=a.getItemGraphicEl(h);d&&d.fadeOut(function(){i.remove(d)},n)}).execute(),this._getSymbolPoint=c,this._data=e},r.prototype.updateLayout=function(){var e=this,t=this._data;t&&t.eachItemGraphicEl(function(i,n){var a=e._getSymbolPoint(n);i.setPosition(a),i.markRedraw()})},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=gL(e),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t,i){this._progressiveEls=[],i=vL(i);function n(l){l.isGroup||(l.incremental=!0,l.ensureState("emphasis").hoverLayer=!0)}for(var a=e.start;a0?t=i[0]:i[1]<0&&(t=i[1]),t}function MW(r,e,t,i){var n=NaN;r.stacked&&(n=t.get(t.getCalculationInfo("stackedOverDimension"),i)),isNaN(n)&&(n=r.valueStart);var a=r.baseDataOffset,s=[];return s[a]=t.get(r.baseDim,i),s[1-a]=n,e.dataToPoint(s)}function Cge(r,e){var t=[];return e.diff(r).add(function(i){t.push({cmd:"+",idx:i})}).update(function(i,n){t.push({cmd:"=",idx:n,idx1:i})}).remove(function(i){t.push({cmd:"-",idx:i})}).execute(),t}function Age(r,e,t,i,n,a,s,o){for(var l=Cge(r,e),u=[],c=[],h=[],d=[],f=[],p=[],v=[],g=PW(n,e,s),m=r.getLayout("points")||[],y=e.getLayout("points")||[],_=0;_=n||v<0)break;if($u(m,y)){if(l){v+=a;continue}break}if(v===t)r[a>0?"moveTo":"lineTo"](m,y),h=m,d=y;else{var _=m-u,b=y-c;if(_*_+b*b<.5){v+=a;continue}if(s>0){for(var T=v+a,x=e[T*2],C=e[T*2+1];x===m&&C===y&&g=i||$u(x,C))f=m,p=y;else{M=x-u,L=C-c;var B=m-u,F=x-m,U=y-c,$=C-y,q=void 0,Z=void 0;if(o==="x"){q=Math.abs(B),Z=Math.abs(F);var te=M>0?1:-1;f=m-te*q*s,p=y,N=m+te*Z*s,O=y}else if(o==="y"){q=Math.abs(U),Z=Math.abs($);var Q=L>0?1:-1;f=m,p=y-Q*q*s,N=m,O=y+Q*Z*s}else q=Math.sqrt(B*B+U*U),Z=Math.sqrt(F*F+$*$),I=Z/(Z+q),f=m-M*s*(1-I),p=y-L*s*(1-I),N=m+M*s*I,O=y+L*s*I,N=bo(N,So(x,m)),O=bo(O,So(C,y)),N=So(N,bo(x,m)),O=So(O,bo(C,y)),M=N-m,L=O-y,f=m-M*q/Z,p=y-L*q/Z,f=bo(f,So(u,m)),p=bo(p,So(c,y)),f=So(f,bo(u,m)),p=So(p,bo(c,y)),M=m-f,L=y-p,N=m+M*Z/q,O=y+L*Z/q}r.bezierCurveTo(h,d,f,p,m,y),h=N,d=O}else r.lineTo(m,y)}u=m,c=y,v+=a}return g}var LW=function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r}(),Dge=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i.type="ec-polyline",i}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new LW},e.prototype.buildPath=function(t,i){var n=i.points,a=0,s=n.length/2;if(i.connectNulls){for(;s>0&&$u(n[s*2-2],n[s*2-1]);s--);for(;a=0){var b=u?(p-l)*_+l:(f-o)*_+o;return u?[t,b]:[b,t]}o=f,l=p;break;case s.C:f=a[h++],p=a[h++],v=a[h++],g=a[h++],m=a[h++],y=a[h++];var T=u?wy(o,f,v,m,t,c):wy(l,p,g,y,t,c);if(T>0)for(var x=0;x=0){var b=u?Mr(l,p,g,y,C):Mr(o,f,v,m,C);return u?[t,b]:[b,t]}}o=m,l=y;break}}},e}(Qe),Ege=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e}(LW),kW=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i.type="ec-polygon",i}return e.prototype.getDefaultShape=function(){return new Ege},e.prototype.buildPath=function(t,i){var n=i.points,a=i.stackedOnPoints,s=0,o=n.length/2,l=i.smoothMonotone;if(i.connectNulls){for(;o>0&&$u(n[o*2-2],n[o*2-1]);o--);for(;se){a?t.push(s(a,l,e)):n&&t.push(s(n,l,0),s(n,l,e));break}else n&&(t.push(s(n,l,0)),n=null),t.push(l),a=l}return t}function Mge(r,e,t){var i=r.getVisual("visualMeta");if(!(!i||!i.length||!r.count())&&e.type==="cartesian2d"){for(var n,a,s=i.length-1;s>=0;s--){var o=r.getDimensionInfo(i[s].dimension);if(n=o&&o.coordDim,n==="x"||n==="y"){a=i[s];break}}if(a){var l=e.getAxis(n),u=oe(a.stops,function(_){return{coord:l.toGlobalCoord(l.dataToCoord(_.value)),color:_.color}}),c=u.length,h=a.outerColors.slice();c&&u[0].coord>u[c-1].coord&&(u.reverse(),h.reverse());var d=Pge(u,n==="x"?t.getWidth():t.getHeight()),f=d.length;if(!f&&c)return u[0].coord<0?h[1]?h[1]:u[c-1].color:h[0]?h[0]:u[0].color;var p=10,v=d[0].coord-p,g=d[f-1].coord+p,m=g-v;if(m<.001)return"transparent";R(d,function(_){_.offset=(_.coord-v)/m}),d.push({offset:f?d[f-1].offset:.5,color:h[1]||"transparent"}),d.unshift({offset:f?d[0].offset:.5,color:h[0]||"transparent"});var y=new tg(0,0,0,0,d,!0);return y[n]=v,y[n+"2"]=g,y}}}function Lge(r,e,t){var i=r.get("showAllSymbol"),n=i==="auto";if(!(i&&!n)){var a=t.getAxesByScale("ordinal")[0];if(a&&!(n&&kge(a,e))){var s=e.mapDimension(a.dim),o={};return R(a.getViewLabels(),function(l){var u=a.scale.getRawOrdinalNumber(l.tickValue);o[u]=1}),function(l){return!o.hasOwnProperty(e.get(s,l))}}}}function kge(r,e){var t=r.getExtent(),i=Math.abs(t[1]-t[0])/r.scale.count();isNaN(i)&&(i=0);for(var n=e.count(),a=Math.max(1,Math.round(n/5)),s=0;si)return!1;return!0}function Rge(r,e){return isNaN(r)||isNaN(e)}function Oge(r){for(var e=r.length/2;e>0&&Rge(r[e*2-2],r[e*2-1]);e--);return e-1}function SL(r,e){return[r[e*2],r[e*2+1]]}function Nge(r,e,t){for(var i=r.length/2,n=t==="x"?0:1,a,s,o=0,l=-1,u=0;u=e||a>=e&&s<=e){l=u;break}o=u,a=s}return{range:[o,l],t:(e-a)/(s-a)}}function NW(r){if(r.get(["endLabel","show"]))return!0;for(var e=0;e0&&t.get(["emphasis","lineStyle","width"])==="bolder"){var te=v.getState("emphasis").style;te.lineWidth=+v.style.lineWidth+1}ke(v).seriesIndex=t.seriesIndex,Yt(v,$,q,Z);var Q=bL(t.get("smooth")),se=t.get("smoothMonotone");if(v.setShape({smooth:Q,smoothMonotone:se,connectNulls:D}),g){var he=l.getCalculationInfo("stackedOnSeries"),ue=0;g.useStyle(Ce(c.getAreaStyle(),{fill:O,opacity:.7,lineJoin:"bevel",decal:l.getVisual("style").decal})),he&&(ue=bL(he.get("smooth"))),g.setShape({smooth:Q,stackedOnSmooth:ue,smoothMonotone:se,connectNulls:D}),Qr(g,t,"areaStyle"),ke(g).seriesIndex=t.seriesIndex,Yt(g,$,q,Z)}var Ie=function(Oe){a._changePolyState(Oe)};l.eachItemGraphicEl(function(Oe){Oe&&(Oe.onHoverStateChange=Ie)}),this._polyline.onHoverStateChange=Ie,this._data=l,this._coordSys=s,this._stackedOnPoints=x,this._points=h,this._step=L,this._valueOrigin=b,t.get("triggerLineEvent")&&(this.packEventData(t,v),g&&this.packEventData(t,g))},e.prototype.packEventData=function(t,i){ke(i).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},e.prototype.highlight=function(t,i,n,a){var s=t.getData(),o=ec(s,a);if(this._changePolyState("emphasis"),!(o instanceof Array)&&o!=null&&o>=0){var l=s.getLayout("points"),u=s.getItemGraphicEl(o);if(!u){var c=l[o*2],h=l[o*2+1];if(isNaN(c)||isNaN(h)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(c,h))return;var d=t.get("zlevel")||0,f=t.get("z")||0;u=new lg(s,o),u.x=c,u.y=h,u.setZ(d,f);var p=u.getSymbolPath().getTextContent();p&&(p.zlevel=d,p.z=f,p.z2=this._polyline.z2+1),u.__temp=!0,s.setItemGraphicEl(o,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else Ct.prototype.highlight.call(this,t,i,n,a)},e.prototype.downplay=function(t,i,n,a){var s=t.getData(),o=ec(s,a);if(this._changePolyState("normal"),o!=null&&o>=0){var l=s.getItemGraphicEl(o);l&&(l.__temp?(s.setItemGraphicEl(o,null),this.group.remove(l)):l.downplay())}else Ct.prototype.downplay.call(this,t,i,n,a)},e.prototype._changePolyState=function(t){var i=this._polygon;My(this._polyline,t),i&&My(i,t)},e.prototype._newPolyline=function(t){var i=this._polyline;return i&&this._lineGroup.remove(i),i=new Dge({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(i),this._polyline=i,i},e.prototype._newPolygon=function(t,i){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new kW({shape:{points:t,stackedOnPoints:i},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},e.prototype._initSymbolLabelAnimation=function(t,i,n){var a,s,o=i.getBaseAxis(),l=o.inverse;i.type==="cartesian2d"?(a=o.isHorizontal(),s=!1):i.type==="polar"&&(a=o.dim==="angle",s=!0);var u=t.hostModel,c=u.get("animationDuration");we(c)&&(c=c(null));var h=u.get("animationDelay")||0,d=we(h)?h(null):h;t.eachItemGraphicEl(function(f,p){var v=f;if(v){var g=[f.x,f.y],m=void 0,y=void 0,_=void 0;if(n)if(s){var b=n,T=i.pointToCoord(g);a?(m=b.startAngle,y=b.endAngle,_=-T[1]/180*Math.PI):(m=b.r0,y=b.r,_=T[0])}else{var x=n;a?(m=x.x,y=x.x+x.width,_=f.x):(m=x.y+x.height,y=x.y,_=f.y)}var C=y===m?0:(_-m)/(y-m);l&&(C=1-C);var D=we(h)?h(p):c*C+d,I=v.getSymbolPath(),M=I.getTextContent();v.attr({scaleX:0,scaleY:0}),v.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:D}),M&&M.animateFrom({style:{opacity:0}},{duration:300,delay:D}),I.disableLabelAnimation=!0}})},e.prototype._initOrUpdateEndLabel=function(t,i,n){var a=t.getModel("endLabel");if(NW(t)){var s=t.getData(),o=this._polyline,l=s.getLayout("points");if(!l){o.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||(u=this._endLabel=new lt({z2:200}),u.ignoreClip=!0,o.setTextContent(this._endLabel),o.disableLabelAnimation=!0);var c=Oge(l);c>=0&&(Jr(o,Nr(t,"endLabel"),{inheritColor:n,labelFetcher:t,labelDataIndex:c,defaultText:function(h,d,f){return f!=null?IW(s,f):ff(s,h)},enableTextSetter:!0},Bge(a,i)),o.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},e.prototype._endLabelOnDuring=function(t,i,n,a,s,o,l){var u=this._endLabel,c=this._polyline;if(u){t<1&&a.originalX==null&&(a.originalX=u.x,a.originalY=u.y);var h=n.getLayout("points"),d=n.hostModel,f=d.get("connectNulls"),p=o.get("precision"),v=o.get("distance")||0,g=l.getBaseAxis(),m=g.isHorizontal(),y=g.inverse,_=i.shape,b=y?m?_.x:_.y+_.height:m?_.x+_.width:_.y,T=(m?v:0)*(y?-1:1),x=(m?0:-v)*(y?-1:1),C=m?"x":"y",D=Nge(h,b,C),I=D.range,M=I[1]-I[0],L=void 0;if(M>=1){if(M>1&&!f){var N=SL(h,I[0]);u.attr({x:N[0]+T,y:N[1]+x}),s&&(L=d.getRawValue(I[0]))}else{var N=c.getPointOn(b,C);N&&u.attr({x:N[0]+T,y:N[1]+x});var O=d.getRawValue(I[0]),B=d.getRawValue(I[1]);s&&(L=bG(n,p,O,B,D.t))}a.lastFrameIndex=I[0]}else{var F=t===1||a.lastFrameIndex>0?I[0]:0,N=SL(h,F);s&&(L=d.getRawValue(F)),u.attr({x:N[0]+T,y:N[1]+x})}if(s){var U=Rf(u);typeof U.setLabelText=="function"&&U.setLabelText(L)}}},e.prototype._doUpdateAnimation=function(t,i,n,a,s,o,l){var u=this._polyline,c=this._polygon,h=t.hostModel,d=Age(this._data,t,this._stackedOnPoints,i,this._coordSys,n,this._valueOrigin),f=d.current,p=d.stackedOnCurrent,v=d.next,g=d.stackedOnNext;if(s&&(f=To(d.current,n,s,l),p=To(d.stackedOnCurrent,n,s,l),v=To(d.next,n,s,l),g=To(d.stackedOnNext,n,s,l)),_L(f,v)>3e3||c&&_L(p,g)>3e3){u.stopAnimation(),u.setShape({points:v}),c&&(c.stopAnimation(),c.setShape({points:v,stackedOnPoints:g}));return}u.shape.__points=d.current,u.shape.points=f;var m={shape:{points:v}};d.current!==f&&(m.shape.__points=d.next),u.stopAnimation(),ct(u,m,h),c&&(c.setShape({points:f,stackedOnPoints:p}),c.stopAnimation(),ct(c,{shape:{stackedOnPoints:g}},h),u.shape.points!==c.shape.points&&(c.shape.points=u.shape.points));for(var y=[],_=d.status,b=0;b<_.length;b++){var T=_[b].cmd;if(T==="="){var x=t.getItemGraphicEl(_[b].idx1);x&&y.push({el:x,ptIdx:b})}}u.animators&&u.animators.length&&u.animators[0].during(function(){c&&c.dirtyShape();for(var C=u.shape.__points,D=0;De&&(e=r[t]);return isFinite(e)?e:NaN},min:function(r){for(var e=1/0,t=0;te&&(e=a,t=n)}return isFinite(t)?t:NaN},nearest:function(r){return r[0]}},Vge=function(r){return Math.round(r.length/2)};function BW(r){return{seriesType:r,reset:function(e,t,i){var n=e.getData(),a=e.get("sampling"),s=e.coordinateSystem,o=n.count();if(o>10&&s.type==="cartesian2d"&&a){var l=s.getBaseAxis(),u=s.getOtherAxis(l),c=l.getExtent(),h=i.getDevicePixelRatio(),d=Math.abs(c[1]-c[0])*(h||1),f=Math.round(o/d);if(isFinite(f)&&f>1){a==="lttb"&&e.setData(n.lttbDownSample(n.mapDimension(u.dim),1/f));var p=void 0;pe(a)?p=Uge[a]:we(a)&&(p=a),p&&e.setData(n.downSample(n.mapDimension(u.dim),1/f,p,Vge))}}}}}function zge(r){r.registerChartView(Fge),r.registerSeriesModel(Tge),r.registerLayout(hg("line",!0)),r.registerVisual({seriesType:"line",reset:function(e){var t=e.getData(),i=e.getModel("lineStyle").getLineStyle();i&&!i.stroke&&(i.stroke=t.getVisual("style").fill),t.setVisual("legendLineStyle",i)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,BW("line"))}var Cv=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,i){return to(null,this,{useEncodeDefaulter:!0})},e.prototype.getMarkerPosition=function(t,i,n){var a=this.coordinateSystem;if(a&&a.clampData){var s=a.clampData(t),o=a.dataToPoint(s);if(n)R(a.getAxes(),function(d,f){if(d.type==="category"&&i!=null){var p=d.getTicksCoords(),v=d.getTickModel().get("alignWithLabel"),g=s[f],m=i[f]==="x1"||i[f]==="y1";if(m&&!v&&(g+=1),p.length<2)return;if(p.length===2){o[f]=d.toGlobalCoord(d.getExtent()[m?1:0]);return}for(var y=void 0,_=void 0,b=1,T=0;Tg){_=(x+y)/2;break}T===1&&(b=C-p[0].tickValue)}_==null&&(y?y&&(_=p[p.length-1].coord):_=p[0].coord),o[f]=d.toGlobalCoord(_)}});else{var l=this.getData(),u=l.getLayout("offset"),c=l.getLayout("size"),h=a.getBaseAxis().isHorizontal()?0:1;o[h]+=u+c/2}return o}return[NaN,NaN]},e.type="series.__base_bar__",e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},e}(Ot);Ot.registerClass(Cv);var Gge=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(){return to(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},e.prototype.getProgressive=function(){return this.get("large")?this.get("progressive"):!1},e.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),i=this.get("largeThreshold");return i>t&&(t=i),t},e.prototype.brushSelector=function(t,i,n){return n.rect(i.getItemLayout(t))},e.type="series.bar",e.dependencies=["grid","polar"],e.defaultOption=hl(Cv.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:"#212121"}},realtimeSort:!1}),e}(Cv),Hge=function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r}(),Ky=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i.type="sausage",i}return e.prototype.getDefaultShape=function(){return new Hge},e.prototype.buildPath=function(t,i){var n=i.cx,a=i.cy,s=Math.max(i.r0||0,0),o=Math.max(i.r,0),l=(o-s)*.5,u=s+l,c=i.startAngle,h=i.endAngle,d=i.clockwise,f=Math.PI*2,p=d?h-cMath.PI/2&&co)return!0;o=h}return!1},e.prototype._isOrderDifferentInView=function(t,i){for(var n=i.scale,a=n.getExtent(),s=Math.max(0,a[0]),o=Math.min(a[1],n.getOrdinalMeta().categories.length-1);s<=o;++s)if(t.ordinalNumbers[s]!==n.getRawOrdinalNumber(s))return!0},e.prototype._updateSortWithinSameData=function(t,i,n,a){if(this._isOrderChangedWithinSameData(t,i,n)){var s=this._dataSort(t,n,i);this._isOrderDifferentInView(s,n)&&(this._removeOnRenderedListener(a),a.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:s}))}},e.prototype._dispatchInitSort=function(t,i,n){var a=i.baseAxis,s=this._dataSort(t,a,function(o){return t.get(t.mapDimension(i.otherAxis.dim),o)});n.dispatchAction({type:"changeAxisOrder",componentType:a.dim+"Axis",isInitSort:!0,axisId:a.index,sortInfo:s})},e.prototype.remove=function(t,i){this._clear(this._model),this._removeOnRenderedListener(i)},e.prototype.dispose=function(t,i){this._removeOnRenderedListener(i)},e.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},e.prototype._clear=function(t){var i=this.group,n=this._data;t&&t.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl(function(a){vv(a,t,ke(a).dataIndex)})):i.removeAll(),this._data=null,this._isFirstFrame=!0},e.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},e.type="bar",e}(Ct),TL={cartesian2d:function(r,e){var t=e.width<0?-1:1,i=e.height<0?-1:1;t<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height);var n=r.x+r.width,a=r.y+r.height,s=uS(e.x,r.x),o=cS(e.x+e.width,n),l=uS(e.y,r.y),u=cS(e.y+e.height,a),c=on?o:s,e.y=h&&l>a?u:l,e.width=c?0:o-s,e.height=h?0:u-l,t<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height),c||h},polar:function(r,e){var t=e.r0<=e.r?1:-1;if(t<0){var i=e.r;e.r=e.r0,e.r0=i}var n=cS(e.r,r.r),a=uS(e.r0,r.r0);e.r=n,e.r0=a;var s=n-a<0;if(t<0){var i=e.r;e.r=e.r0,e.r0=i}return s}},xL={cartesian2d:function(r,e,t,i,n,a,s,o,l){var u=new st({shape:J({},i),z2:1});if(u.__dataIndex=t,u.name="item",a){var c=u.shape,h=n?"height":"width";c[h]=0}return u},polar:function(r,e,t,i,n,a,s,o,l){var u=!n&&l?Ky:Ei,c=new u({shape:i,z2:1});c.name="item";var h=FW(n);if(c.calculateTextPosition=$ge(h,{isRoundCap:u===Ky}),a){var d=c.shape,f=n?"r":"endAngle",p={};d[f]=n?i.r0:i.startAngle,p[f]=i[f],(o?ct:Vt)(c,{shape:p},a)}return c}};function Xge(r,e){var t=r.get("realtimeSort",!0),i=e.getBaseAxis();if(t&&i.type==="category"&&e.type==="cartesian2d")return{baseAxis:i,otherAxis:e.getOtherAxis(i)}}function wL(r,e,t,i,n,a,s,o){var l,u;a?(u={x:i.x,width:i.width},l={y:i.y,height:i.height}):(u={y:i.y,height:i.height},l={x:i.x,width:i.width}),o||(s?ct:Vt)(t,{shape:l},e,n,null);var c=e?r.baseAxis.model:null;(s?ct:Vt)(t,{shape:u},c,n)}function CL(r,e){for(var t=0;t0?1:-1,s=i.height>0?1:-1;return{x:i.x+a*n/2,y:i.y+s*n/2,width:i.width-a*n,height:i.height-s*n}},polar:function(r,e,t){var i=r.getItemLayout(e);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}}};function Zge(r){return r.startAngle!=null&&r.endAngle!=null&&r.startAngle===r.endAngle}function FW(r){return function(e){var t=e?"Arc":"Angle";return function(i){switch(i){case"start":case"insideStart":case"end":case"insideEnd":return i+t;default:return i}}}(r)}function DL(r,e,t,i,n,a,s,o){var l=e.getItemVisual(t,"style");if(o){if(!a.get("roundCap")){var c=r.shape,h=xu(i.getModel("itemStyle"),c,!0);J(c,h),r.setShape(c)}}else{var u=i.get(["itemStyle","borderRadius"])||0;r.setShape("r",u)}r.useStyle(l);var d=i.getShallow("cursor");d&&r.attr("cursor",d);var f=o?s?n.r>=n.r0?"endArc":"startArc":n.endAngle>=n.startAngle?"endAngle":"startAngle":s?n.height>=0?"bottom":"top":n.width>=0?"right":"left",p=Nr(i);Jr(r,p,{labelFetcher:a,labelDataIndex:t,defaultText:ff(a.getData(),t),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:f});var v=r.getTextContent();if(o&&v){var g=i.get(["label","position"]);r.textConfig.inside=g==="middle"?!0:null,Wge(r,g==="outside"?f:g,FW(s),i.get(["label","rotate"]))}iH(v,p,a.getRawValue(t),function(y){return IW(e,y)});var m=i.getModel(["emphasis"]);Yt(r,m.get("focus"),m.get("blurScope"),m.get("disabled")),Qr(r,i),Zge(n)&&(r.style.fill="none",r.style.stroke="none",R(r.states,function(y){y.style&&(y.style.fill=y.style.stroke="none")}))}function Qge(r,e){var t=r.get(["itemStyle","borderColor"]);if(!t||t==="none")return 0;var i=r.get(["itemStyle","borderWidth"])||0,n=isNaN(e.width)?Number.MAX_VALUE:Math.abs(e.width),a=isNaN(e.height)?Number.MAX_VALUE:Math.abs(e.height);return Math.min(i,n,a)}var Jge=function(){function r(){}return r}(),EL=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i.type="largeBar",i}return e.prototype.getDefaultShape=function(){return new Jge},e.prototype.buildPath=function(t,i){for(var n=i.points,a=this.baseDimIdx,s=1-this.baseDimIdx,o=[],l=[],u=this.barWidth,c=0;c=0?t:null},30,!1);function eme(r,e,t){for(var i=r.baseDimIdx,n=1-i,a=r.shape.points,s=r.largeDataIndices,o=[],l=[],u=r.barWidth,c=0,h=a.length/3;c=o[0]&&e<=o[0]+l[0]&&t>=o[1]&&t<=o[1]+l[1])return s[c]}return-1}function UW(r,e,t){if(dc(t,"cartesian2d")){var i=e,n=t.getArea();return{x:r?i.x:n.x,y:r?n.y:i.y,width:r?i.width:n.width,height:r?n.height:i.height}}else{var n=t.getArea(),a=e;return{cx:n.cx,cy:n.cy,r0:r?n.r0:a.r0,r:r?n.r:a.r,startAngle:r?a.startAngle:0,endAngle:r?a.endAngle:Math.PI*2}}}function tme(r,e,t){var i=r.type==="polar"?Ei:st;return new i({shape:UW(e,t,r),silent:!0,z2:0})}function rme(r){r.registerChartView(jge),r.registerSeriesModel(Gge),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,Ue($$,"bar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,W$("bar")),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,BW("bar")),r.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(e,t){var i=e.componentType||"series";t.eachComponent({mainType:i,query:e},function(n){e.sortInfo&&n.axis.setCategorySortInfo(e.sortInfo)})})}var ML=Math.PI*2,Fm=Math.PI/180;function VW(r,e){return Ar(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function zW(r,e){var t=VW(r,e),i=r.get("center"),n=r.get("radius");ie(n)||(n=[0,n]);var a=ce(t.width,e.getWidth()),s=ce(t.height,e.getHeight()),o=Math.min(a,s),l=ce(n[0],o/2),u=ce(n[1],o/2),c,h,d=r.coordinateSystem;if(d){var f=d.dataToPoint(i);c=f[0]||0,h=f[1]||0}else ie(i)||(i=[i,i]),c=ce(i[0],a)+t.x,h=ce(i[1],s)+t.y;return{cx:c,cy:h,r0:l,r:u}}function ime(r,e,t){e.eachSeriesByType(r,function(i){var n=i.getData(),a=n.mapDimension("value"),s=VW(i,t),o=zW(i,t),l=o.cx,u=o.cy,c=o.r,h=o.r0,d=-i.get("startAngle")*Fm,f=i.get("endAngle"),p=i.get("padAngle")*Fm;f=f==="auto"?d-ML:-f*Fm;var v=i.get("minAngle")*Fm,g=v+p,m=0;n.each(a,function($){!isNaN($)&&m++});var y=n.getSum(a),_=Math.PI/(y||m)*2,b=i.get("clockwise"),T=i.get("roseType"),x=i.get("stillShowZeroSum"),C=n.getDataExtent(a);C[0]=0;var D=b?1:-1,I=[d,f],M=D*p/2;aD(I,!b),d=I[0],f=I[1];var L=GW(i);L.startAngle=d,L.endAngle=f,L.clockwise=b;var N=Math.abs(f-d),O=N,B=0,F=d;if(n.setLayout({viewRect:s,r:c}),n.each(a,function($,q){var Z;if(isNaN($)){n.setItemLayout(q,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:b,cx:l,cy:u,r0:h,r:T?NaN:c});return}T!=="area"?Z=y===0&&x?_:$*_:Z=N/m,ZZ?(Q=F+D*Z/2,se=Q):(Q=F+M,se=te-M),n.setItemLayout(q,{angle:Z,startAngle:Q,endAngle:se,clockwise:b,cx:l,cy:u,r0:h,r:T?bt($,C,[h,c]):c}),F=te}),Ot?m:g,T=Math.abs(_.label.y-t);if(T>=b.maxY){var x=_.label.x-e-_.len2*n,C=i+_.len,D=Math.abs(x)r.unconstrainedWidth?null:f:null;i.setStyle("width",p)}var v=i.getBoundingRect();a.width=v.width;var g=(i.style.margin||0)+2.1;a.height=v.height+g,a.y-=(a.height-h)/2}}}function hS(r){return r.position==="center"}function sme(r){var e=r.getData(),t=[],i,n,a=!1,s=(r.get("minShowLabelAngle")||0)*nme,o=e.getLayout("viewRect"),l=e.getLayout("r"),u=o.width,c=o.x,h=o.y,d=o.height;function f(x){x.ignore=!0}function p(x){if(!x.ignore)return!0;for(var C in x.states)if(x.states[C].ignore===!1)return!0;return!1}e.each(function(x){var C=e.getItemGraphicEl(x),D=C.shape,I=C.getTextContent(),M=C.getTextGuideLine(),L=e.getItemModel(x),N=L.getModel("label"),O=N.get("position")||L.get(["emphasis","label","position"]),B=N.get("distanceToLabelLine"),F=N.get("alignTo"),U=ce(N.get("edgeDistance"),u),$=N.get("bleedMargin"),q=L.getModel("labelLine"),Z=q.get("length");Z=ce(Z,u);var te=q.get("length2");if(te=ce(te,u),Math.abs(D.endAngle-D.startAngle)0?"right":"left":se>0?"left":"right"}var Ge=Math.PI,Pt=0,wt=N.get("rotate");if(ut(wt))Pt=wt*(Ge/180);else if(O==="center")Pt=0;else if(wt==="radial"||wt===!0){var At=se<0?-Q+Ge:-Q;Pt=At}else if(wt==="tangential"&&O!=="outside"&&O!=="outer"){var rr=Math.atan2(se,he);rr<0&&(rr=Ge*2+rr);var ht=he>0;ht&&(rr=Ge+rr),Pt=rr-Ge}if(a=!!Pt,I.x=ue,I.y=Ie,I.rotation=Pt,I.setStyle({verticalAlign:"middle"}),me){I.setStyle({align:Fe});var ro=I.states.select;ro&&(ro.x+=I.x,ro.y+=I.y)}else{var Ji=I.getBoundingRect().clone();Ji.applyTransform(I.getComputedTransform());var br=(I.style.margin||0)+2.1;Ji.y-=br/2,Ji.height+=br,t.push({label:I,labelLine:M,position:O,len:Z,len2:te,minTurnAngle:q.get("minTurnAngle"),maxSurfaceAngle:q.get("maxSurfaceAngle"),surfaceNormal:new He(se,he),linePoints:Oe,textAlign:Fe,labelDistance:B,labelAlignTo:F,edgeDistance:U,bleedMargin:$,rect:Ji,unconstrainedWidth:Ji.width,labelStyleWidth:I.style.width})}C.setTextConfig({inside:me})}}),!a&&r.get("avoidLabelOverlap")&&ame(t,i,n,l,u,d,c,h);for(var v=0;v0){for(var c=s.getItemLayout(0),h=1;isNaN(c&&c.startAngle)&&h=a.r0}},e.type="pie",e}(Ct);function Hf(r,e,t){e=ie(e)&&{coordDimensions:e}||J({encodeDefine:r.getEncode()},e);var i=r.getSource(),n=sg(i,e).dimensions,a=new wi(n,r);return a.initData(i,t),a}var dg=function(){function r(e,t){this._getDataWithEncodedVisual=e,this._getRawData=t}return r.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},r.prototype.containName=function(e){var t=this._getRawData();return t.indexOfName(e)>=0},r.prototype.indexOfName=function(e){var t=this._getDataWithEncodedVisual();return t.indexOfName(e)},r.prototype.getItemVisual=function(e,t){var i=this._getDataWithEncodedVisual();return i.getItemVisual(e,t)},r}(),ume=ot(),cme=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new dg(ge(this.getData,this),ge(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.mergeOption=function(){r.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return Hf(this,{coordDimensions:["value"],encodeDefaulter:Ue(TD,this)})},e.prototype.getDataParams=function(t){var i=this.getData(),n=ume(i),a=n.seats;if(!a){var s=[];i.each(i.mapDimension("value"),function(l){s.push(l)}),a=n.seats=rue(s,i.hostModel.get("percentPrecision"))}var o=r.prototype.getDataParams.call(this,t);return o.percent=a[t]||0,o.$vars.push("percent"),o},e.prototype._defaultLabelLine=function(t){Ju(t,"labelLine",["show"]);var i=t.labelLine,n=t.emphasis.labelLine;i.show=i.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.type="series.pie",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e}(Ot);function hme(r){return{seriesType:r,reset:function(e,t){var i=e.getData();i.filterSelf(function(n){var a=i.mapDimension("value"),s=i.get(a,n);return!(ut(s)&&!isNaN(s)&&s<0)})}}}function fme(r){r.registerChartView(lme),r.registerSeriesModel(cme),u$("pie",r.registerAction),r.registerLayout(Ue(ime,"pie")),r.registerProcessor(fg("pie")),r.registerProcessor(hme("pie"))}var dme=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,i){return to(null,this,{useEncodeDefaulter:!0})},e.prototype.getProgressive=function(){var t=this.option.progressive;return t??(this.option.large?5e3:this.get("progressive"))},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t??(this.option.large?1e4:this.get("progressiveThreshold"))},e.prototype.brushSelector=function(t,i,n){return n.point(i.getItemLayout(t))},e.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},e.type="series.scatter",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:"#212121"}},universalTransition:{divideShape:"clone"}},e}(Ot),$W=4,pme=function(){function r(){}return r}(),vme=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i._off=0,i.hoverDataIdx=-1,i}return e.prototype.getDefaultShape=function(){return new pme},e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.buildPath=function(t,i){var n=i.points,a=i.size,s=this.symbolProxy,o=s.shape,l=t.getContext?t.getContext():t,u=l&&a[0]<$W,c=this.softClipShape,h;if(u){this._ctx=l;return}for(this._ctx=null,h=this._off;h=0;u--){var c=u*2,h=a[c]-o/2,d=a[c+1]-l/2;if(t>=h&&i>=d&&t<=h+o&&i<=d+l)return u}return-1},e.prototype.contain=function(t,i){var n=this.transformCoordToLocal(t,i),a=this.getBoundingRect();if(t=n[0],i=n[1],a.contain(t,i)){var s=this.hoverDataIdx=this.findDataIndex(t,i);return s>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var i=this.shape,n=i.points,a=i.size,s=a[0],o=a[1],l=1/0,u=1/0,c=-1/0,h=-1/0,d=0;d=0&&(u.dataIndex=h+(e.startIndex||0))})},r.prototype.remove=function(){this._clear()},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r}(),mme=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){var a=t.getData(),s=this._updateSymbolDraw(a,t);s.updateData(a,{clipShape:this._getClipShape(t)}),this._finished=!0},e.prototype.incrementalPrepareRender=function(t,i,n){var a=t.getData(),s=this._updateSymbolDraw(a,t);s.incrementalPrepareUpdate(a),this._finished=!1},e.prototype.incrementalRender=function(t,i,n){this._symbolDraw.incrementalUpdate(t,i.getData(),{clipShape:this._getClipShape(i)}),this._finished=t.end===i.getData().count()},e.prototype.updateTransform=function(t,i,n){var a=t.getData();if(this.group.dirty(),!this._finished||a.count()>1e4)return{update:!0};var s=hg("").reset(t,i,n);s.progress&&s.progress({start:0,end:a.count(),count:a.count()},a),this._symbolDraw.updateLayout(a)},e.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},e.prototype._getClipShape=function(t){if(t.get("clip",!0)){var i=t.coordinateSystem;return i&&i.getArea&&i.getArea(.1)}},e.prototype._updateSymbolDraw=function(t,i){var n=this._symbolDraw,a=i.pipelineContext,s=a.large;return(!n||s!==this._isLargeDraw)&&(n&&n.remove(),n=this._symbolDraw=s?new gme:new ug,this._isLargeDraw=s,this.group.removeAll()),this.group.add(n.group),n},e.prototype.remove=function(t,i){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},e.prototype.dispose=function(){},e.type="scatter",e}(Ct),yme=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.type="grid",e.dependencies=["xAxis","yAxis"],e.layoutMode="box",e.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},e}(tt),xw=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",mr).models[0]},e.type="cartesian2dAxis",e}(tt);_r(xw,og);var WW={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},_me=We({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},WW),QD=We({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},WW),bme=We({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},QD),Sme=Ce({logBase:10},QD);const qW={category:_me,value:QD,time:bme,log:Sme};var Tme={value:1,category:1,time:1,log:1};function df(r,e,t,i){R(Tme,function(n,a){var s=We(We({},qW[a],!0),i,!0),o=function(l){j(u,l);function u(){var c=l!==null&&l.apply(this,arguments)||this;return c.type=e+"Axis."+a,c}return u.prototype.mergeDefaultAndTheme=function(c,h){var d=mv(this),f=d?Bf(c):{},p=h.getTheme();We(c,p.get(a+"Axis")),We(c,this.getDefaultOption()),c.type=kL(c),d&&il(c,f,d)},u.prototype.optionUpdated=function(){var c=this.option;c.type==="category"&&(this.__ordinalMeta=gw.createByAxisModel(this))},u.prototype.getCategories=function(c){var h=this.option;if(h.type==="category")return c?h.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.type=e+"Axis."+a,u.defaultOption=s,u}(t);r.registerComponentModel(o)}),r.registerSubTypeDefaulter(e+"Axis",kL)}function kL(r){return r.type||(r.data?"category":"value")}var xme=function(){function r(e){this.type="cartesian",this._dimList=[],this._axes={},this.name=e||""}return r.prototype.getAxis=function(e){return this._axes[e]},r.prototype.getAxes=function(){return oe(this._dimList,function(e){return this._axes[e]},this)},r.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),Tt(this.getAxes(),function(t){return t.scale.type===e})},r.prototype.addAxis=function(e){var t=e.dim;this._axes[t]=e,this._dimList.push(t)},r}(),ww=["x","y"];function RL(r){return r.type==="interval"||r.type==="time"}var wme=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=ww,t}return e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,i=this.getAxis("y").scale;if(!(!RL(t)||!RL(i))){var n=t.getExtent(),a=i.getExtent(),s=this.dataToPoint([n[0],a[0]]),o=this.dataToPoint([n[1],a[1]]),l=n[1]-n[0],u=a[1]-a[0];if(!(!l||!u)){var c=(o[0]-s[0])/l,h=(o[1]-s[1])/u,d=s[0]-n[0]*c,f=s[1]-a[0]*h,p=this._transform=[c,0,0,h,d,f];this._invTransform=If([],p)}}},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},e.prototype.containPoint=function(t){var i=this.getAxis("x"),n=this.getAxis("y");return i.contain(i.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},e.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},e.prototype.containZone=function(t,i){var n=this.dataToPoint(t),a=this.dataToPoint(i),s=this.getArea(),o=new qe(n[0],n[1],a[0]-n[0],a[1]-n[1]);return s.intersect(o)},e.prototype.dataToPoint=function(t,i,n){n=n||[];var a=t[0],s=t[1];if(this._transform&&a!=null&&isFinite(a)&&s!=null&&isFinite(s))return Zr(n,t,this._transform);var o=this.getAxis("x"),l=this.getAxis("y");return n[0]=o.toGlobalCoord(o.dataToCoord(a,i)),n[1]=l.toGlobalCoord(l.dataToCoord(s,i)),n},e.prototype.clampData=function(t,i){var n=this.getAxis("x").scale,a=this.getAxis("y").scale,s=n.getExtent(),o=a.getExtent(),l=n.parse(t[0]),u=a.parse(t[1]);return i=i||[],i[0]=Math.min(Math.max(Math.min(s[0],s[1]),l),Math.max(s[0],s[1])),i[1]=Math.min(Math.max(Math.min(o[0],o[1]),u),Math.max(o[0],o[1])),i},e.prototype.pointToData=function(t,i){var n=[];if(this._invTransform)return Zr(n,t,this._invTransform);var a=this.getAxis("x"),s=this.getAxis("y");return n[0]=a.coordToData(a.toLocalCoord(t[0]),i),n[1]=s.coordToData(s.toLocalCoord(t[1]),i),n},e.prototype.getOtherAxis=function(t){return this.getAxis(t.dim==="x"?"y":"x")},e.prototype.getArea=function(t){t=t||0;var i=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),a=Math.min(i[0],i[1])-t,s=Math.min(n[0],n[1])-t,o=Math.max(i[0],i[1])-a+t,l=Math.max(n[0],n[1])-s+t;return new qe(a,s,o,l)},e}(xme),Cme=function(r){j(e,r);function e(t,i,n,a,s){var o=r.call(this,t,i,n)||this;return o.index=0,o.type=a||"value",o.position=s||"bottom",o}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.getGlobalExtent=function(t){var i=this.getExtent();return i[0]=this.toGlobalCoord(i[0]),i[1]=this.toGlobalCoord(i[1]),t&&i[0]>i[1]&&i.reverse(),i},e.prototype.pointToData=function(t,i){return this.coordToData(this.toLocalCoord(t[this.dim==="x"?0:1]),i)},e.prototype.setCategorySortInfo=function(t){if(this.type!=="category")return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},e}(xa);function Cw(r,e,t){t=t||{};var i=r.coordinateSystem,n=e.axis,a={},s=n.getAxesOnZeroOf()[0],o=n.position,l=s?"onZero":o,u=n.dim,c=i.getRect(),h=[c.x,c.x+c.width,c.y,c.y+c.height],d={left:0,right:1,top:0,bottom:1,onZero:2},f=e.get("offset")||0,p=u==="x"?[h[2]-f,h[3]+f]:[h[0]-f,h[1]+f];if(s){var v=s.toGlobalCoord(s.dataToCoord(0));p[d.onZero]=Math.max(Math.min(v,p[1]),p[0])}a.position=[u==="y"?p[d[l]]:h[0],u==="x"?p[d[l]]:h[3]],a.rotation=Math.PI/2*(u==="x"?0:1);var g={top:-1,bottom:1,left:-1,right:1};a.labelDirection=a.tickDirection=a.nameDirection=g[o],a.labelOffset=s?p[d[o]]-p[d.onZero]:0,e.get(["axisTick","inside"])&&(a.tickDirection=-a.tickDirection),Gr(t.labelInside,e.get(["axisLabel","inside"]))&&(a.labelDirection=-a.labelDirection);var m=e.get(["axisLabel","rotate"]);return a.labelRotate=l==="top"?-m:m,a.z2=1,a}function OL(r){return r.get("coordinateSystem")==="cartesian2d"}function NL(r){var e={xAxisModel:null,yAxisModel:null};return R(e,function(t,i){var n=i.replace(/Model$/,""),a=r.getReferringComponents(n,mr).models[0];e[i]=a}),e}var fS=Math.log;function jW(r,e,t){var i=Ys.prototype,n=i.getTicks.call(t),a=i.getTicks.call(t,!0),s=n.length-1,o=i.getInterval.call(t),l=K$(r,e),u=l.extent,c=l.fixMin,h=l.fixMax;if(r.type==="log"){var d=fS(r.base);u=[fS(u[0])/d,fS(u[1])/d]}r.setExtent(u[0],u[1]),r.calcNiceExtent({splitNumber:s,fixMin:c,fixMax:h});var f=i.getExtent.call(r);c&&(u[0]=f[0]),h&&(u[1]=f[1]);var p=i.getInterval.call(r),v=u[0],g=u[1];if(c&&h)p=(g-v)/s;else if(c)for(g=u[0]+p*s;gu[0]&&isFinite(v)&&isFinite(u[0]);)p=Zb(p),v=u[1]-p*s;else{var m=r.getTicks().length-1;m>s&&(p=Zb(p));var y=p*s;g=Math.ceil(u[1]/p)*p,v=er(g-y),v<0&&u[0]>=0?(v=0,g=er(y)):g>0&&u[1]<=0&&(g=0,v=-er(y))}var _=(n[0].value-a[0].value)/o,b=(n[s].value-a[s].value)/o;i.setExtent.call(r,v+p*_,g+p*b),i.setInterval.call(r,p),(_||b)&&i.setNiceExtent.call(r,v+p,g-p)}var Ame=function(){function r(e,t,i){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=ww,this._initCartesian(e,t,i),this.model=e}return r.prototype.getRect=function(){return this._rect},r.prototype.update=function(e,t){var i=this._axesMap;this._updateScale(e,this.model);function n(s){var o,l=rt(s),u=l.length;if(u){for(var c=[],h=u-1;h>=0;h--){var d=+l[h],f=s[d],p=f.model,v=f.scale;mw(v)&&p.get("alignTicks")&&p.get("interval")==null?c.push(f):(hf(v,p),mw(v)&&(o=f))}c.length&&(o||(o=c.pop(),hf(o.scale,o.model)),R(c,function(g){jW(g.scale,g.model,o.scale)}))}}n(i.x),n(i.y);var a={};R(i.x,function(s){BL(i,"y",s,a)}),R(i.y,function(s){BL(i,"x",s,a)}),this.resize(this.model,t)},r.prototype.resize=function(e,t,i){var n=e.getBoxLayoutParams(),a=!i&&e.get("containLabel"),s=Ar(n,{width:t.getWidth(),height:t.getHeight()});this._rect=s;var o=this._axesList;l(),a&&(R(o,function(u){if(!u.model.get(["axisLabel","inside"])){var c=sve(u);if(c){var h=u.isHorizontal()?"height":"width",d=u.model.get(["axisLabel","margin"]);s[h]-=c[h]+d,u.position==="top"?s.y+=c.height+d:u.position==="left"&&(s.x+=c.width+d)}}}),l()),R(this._coordsList,function(u){u.calcAffineTransform()});function l(){R(o,function(u){var c=u.isHorizontal(),h=c?[0,s.width]:[0,s.height],d=u.inverse?1:0;u.setExtent(h[d],h[1-d]),Dme(u,c?s.x:s.y)})}},r.prototype.getAxis=function(e,t){var i=this._axesMap[e];if(i!=null)return i[t||0]},r.prototype.getAxes=function(){return this._axesList.slice()},r.prototype.getCartesian=function(e,t){if(e!=null&&t!=null){var i="x"+e+"y"+t;return this._coordsMap[i]}De(e)&&(t=e.yAxisIndex,e=e.xAxisIndex);for(var n=0,a=this._coordsList;n0?"top":"bottom",a="center"):hv(n-Vo)?(s=i>0?"bottom":"top",a="center"):(s="middle",n>0&&n0?"right":"left":a=i>0?"left":"right"),{rotation:n,textAlign:a,textVerticalAlign:s}},r.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+"Index"]=e.componentIndex,t},r.isLabelSilent=function(e){var t=e.get("tooltip");return e.get("silent")||!(e.get("triggerEvent")||t&&t.show)},r}(),UL={axisLine:function(r,e,t,i){var n=e.get(["axisLine","show"]);if(n==="auto"&&r.handleAutoShown&&(n=r.handleAutoShown("axisLine")),!!n){var a=e.axis.getExtent(),s=i.transform,o=[a[0],0],l=[a[1],0],u=o[0]>l[0];s&&(Zr(o,o,s),Zr(l,l,s));var c=J({lineCap:"round"},e.getModel(["axisLine","lineStyle"]).getLineStyle()),h=new kr({shape:{x1:o[0],y1:o[1],x2:l[0],y2:l[1]},style:c,strokeContainThreshold:r.strokeContainThreshold||5,silent:!0,z2:1});lf(h.shape,h.style.lineWidth),h.anid="line",t.add(h);var d=e.get(["axisLine","symbol"]);if(d!=null){var f=e.get(["axisLine","symbolSize"]);pe(d)&&(d=[d,d]),(pe(f)||ut(f))&&(f=[f,f]);var p=hc(e.get(["axisLine","symbolOffset"])||0,f),v=f[0],g=f[1];R([{rotate:r.rotation+Math.PI/2,offset:p[0],r:0},{rotate:r.rotation-Math.PI/2,offset:p[1],r:Math.sqrt((o[0]-l[0])*(o[0]-l[0])+(o[1]-l[1])*(o[1]-l[1]))}],function(m,y){if(d[y]!=="none"&&d[y]!=null){var _=yr(d[y],-v/2,-g/2,v,g,c.stroke,!0),b=m.r+m.offset,T=u?l:o;_.attr({rotation:m.rotate,x:T[0]+b*Math.cos(r.rotation),y:T[1]-b*Math.sin(r.rotation),silent:!0,z2:11}),t.add(_)}})}}},axisTickLabel:function(r,e,t,i){var n=Pme(t,i,e,r),a=Lme(t,i,e,r);if(Ime(e,a,n),Mme(t,i,e,r.tickDirection),e.get(["axisLabel","hideOverlap"])){var s=cW(oe(a,function(o){return{label:o,priority:o.z2,defaultAttr:{ignore:o.ignore}}}));dW(s)}},axisName:function(r,e,t,i){var n=Gr(r.axisName,e.get("name"));if(n){var a=e.get("nameLocation"),s=r.nameDirection,o=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,u=e.axis.getExtent(),c=u[0]>u[1]?-1:1,h=[a==="start"?u[0]-c*l:a==="end"?u[1]+c*l:(u[0]+u[1])/2,zL(a)?r.labelOffset+s*l:0],d,f=e.get("nameRotate");f!=null&&(f=f*Vo/180);var p;zL(a)?d=Ci.innerTextLayout(r.rotation,f??r.rotation,s):(d=Eme(r.rotation,a,f||0,u),p=r.axisNameAvailableWidth,p!=null&&(p=Math.abs(p/Math.sin(d.rotation)),!isFinite(p)&&(p=null)));var v=o.getFont(),g=e.get("nameTruncate",!0)||{},m=g.ellipsis,y=Gr(r.nameTruncateMaxWidth,g.maxWidth,p),_=new lt({x:h[0],y:h[1],rotation:d.rotation,silent:Ci.isLabelSilent(e),style:kt(o,{text:n,font:v,overflow:"truncate",width:y,ellipsis:m,fill:o.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:o.get("align")||d.textAlign,verticalAlign:o.get("verticalAlign")||d.textVerticalAlign}),z2:1});if(kf({el:_,componentModel:e,itemName:n}),_.__fullText=n,_.anid="name",e.get("triggerEvent")){var b=Ci.makeAxisEventDataBase(e);b.targetType="axisName",b.name=n,ke(_).eventData=b}i.add(_),_.updateTransform(),t.add(_),_.decomposeTransform()}}};function Eme(r,e,t,i){var n=cG(t-r),a,s,o=i[0]>i[1],l=e==="start"&&!o||e!=="start"&&o;return hv(n-Vo/2)?(s=l?"bottom":"top",a="center"):hv(n-Vo*1.5)?(s=l?"top":"bottom",a="center"):(s="middle",nVo/2?a=l?"left":"right":a=l?"right":"left"),{rotation:n,textAlign:a,textVerticalAlign:s}}function Ime(r,e,t){if(!Z$(r.axis)){var i=r.get(["axisLabel","showMinLabel"]),n=r.get(["axisLabel","showMaxLabel"]);e=e||[],t=t||[];var a=e[0],s=e[1],o=e[e.length-1],l=e[e.length-2],u=t[0],c=t[1],h=t[t.length-1],d=t[t.length-2];i===!1?(Dn(a),Dn(u)):VL(a,s)&&(i?(Dn(s),Dn(c)):(Dn(a),Dn(u))),n===!1?(Dn(o),Dn(h)):VL(l,o)&&(n?(Dn(l),Dn(d)):(Dn(o),Dn(h)))}}function Dn(r){r&&(r.ignore=!0)}function VL(r,e){var t=r&&r.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(!(!t||!i)){var n=J_([]);return uc(n,n,-r.rotation),t.applyTransform(Rs([],n,r.getLocalTransform())),i.applyTransform(Rs([],n,e.getLocalTransform())),t.intersect(i)}}function zL(r){return r==="middle"||r==="center"}function XW(r,e,t,i,n){for(var a=[],s=[],o=[],l=0;l=0||r===e}function Fme(r){var e=JD(r);if(e){var t=e.axisPointerModel,i=e.axis.scale,n=t.option,a=t.get("status"),s=t.get("value");s!=null&&(s=i.parse(s));var o=Aw(t);a==null&&(n.status=o?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(s==null||s>l[1])&&(s=l[1]),s0&&!p.min?p.min=0:p.min!=null&&p.min<0&&!p.max&&(p.max=0);var v=l;p.color!=null&&(v=Ce({color:p.color},l));var g=We(Ee(p),{boundaryGap:t,splitNumber:i,scale:n,axisLine:a,axisTick:s,axisLabel:o,name:p.text,showName:u,nameLocation:"end",nameGap:h,nameTextStyle:v,triggerEvent:d},!1);if(pe(c)){var m=g.name;g.name=c.replace("{value}",m??"")}else we(c)&&(g.name=c(g.name,g));var y=new yt(g,null,this.ecModel);return _r(y,og.prototype),y.mainType="radar",y.componentIndex=this.componentIndex,y},this);this._indicatorModels=f},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:We({lineStyle:{color:"#bbb"}},Ld.axisLine),axisLabel:Um(Ld.axisLabel,!1),axisTick:Um(Ld.axisTick,!1),splitLine:Um(Ld.splitLine,!0),splitArea:Um(Ld.splitArea,!0),indicator:[]},e}(tt),Zme=["axisLine","axisTickLabel","axisName"],Qme=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){var a=this.group;a.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var i=t.coordinateSystem,n=i.getIndicatorAxes(),a=oe(n,function(s){var o=s.model.get("showName")?s.name:"",l=new Ci(s.model,{axisName:o,position:[i.cx,i.cy],rotation:s.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return l});R(a,function(s){R(Zme,s.add,s),this.group.add(s.getGroup())},this)},e.prototype._buildSplitLineAndArea=function(t){var i=t.coordinateSystem,n=i.getIndicatorAxes();if(!n.length)return;var a=t.get("shape"),s=t.getModel("splitLine"),o=t.getModel("splitArea"),l=s.getModel("lineStyle"),u=o.getModel("areaStyle"),c=s.get("show"),h=o.get("show"),d=l.get("color"),f=u.get("color"),p=ie(d)?d:[d],v=ie(f)?f:[f],g=[],m=[];function y(F,U,$){var q=$%U.length;return F[q]=F[q]||[],q}if(a==="circle")for(var _=n[0].getTicksCoords(),b=i.cx,T=i.cy,x=0;x<_.length;x++){if(c){var C=y(g,p,x);g[C].push(new eo({shape:{cx:b,cy:T,r:_[x].coord}}))}if(h&&x<_.length-1){var C=y(m,v,x);m[C].push(new Jv({shape:{cx:b,cy:T,r0:_[x].coord,r:_[x+1].coord}}))}}else for(var D,I=oe(n,function(F,U){var $=F.getTicksCoords();return D=D==null?$.length-1:Math.min($.length-1,D),oe($,function(q){return i.coordToPoint(q.coord,U)})}),M=[],x=0;x<=D;x++){for(var L=[],N=0;N3?1.4:s>1?1.2:1.1,c=a>0?u:1/u;vS(this,"zoom","zoomOnMouseWheel",t,{scale:c,originX:o,originY:l,isAvailableBehavior:null})}if(n){var h=Math.abs(a),d=(a>0?1:-1)*(h>3?.4:h>1?.15:.05);vS(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:d,originX:o,originY:l,isAvailableBehavior:null})}}},e.prototype._pinchHandler=function(t){if(!jL(this._zr,"globalPan")){var i=t.pinchScale>1?1.1:1/1.1;vS(this,"zoom",null,t,{scale:i,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})}},e}(Zn);function vS(r,e,t,i,n){r.pointerChecker&&r.pointerChecker(i,n.originX,n.originY)&&($s(i.event),eq(r,e,t,i,n))}function eq(r,e,t,i,n){n.isAvailableBehavior=ge(E0,null,t,i),r.trigger(e,n)}function E0(r,e,t){var i=t[r];return!r||i&&(!pe(i)||e.event[i+"Key"])}function tE(r,e,t){var i=r.target;i.x+=e,i.y+=t,i.dirty()}function rE(r,e,t,i){var n=r.target,a=r.zoomLimit,s=r.zoom=r.zoom||1;if(s*=e,a){var o=a.min||0,l=a.max||1/0;s=Math.max(Math.min(l,s),o)}var u=s/r.zoom;r.zoom=s,n.x-=(t-n.x)*(u-1),n.y-=(i-n.y)*(u-1),n.scaleX*=u,n.scaleY*=u,n.dirty()}var a0e={axisPointer:1,tooltip:1,brush:1};function P1(r,e,t){var i=e.getComponentByElement(r.topTarget),n=i&&i.coordinateSystem;return i&&i!==t&&!a0e.hasOwnProperty(i.mainType)&&n&&n.model!==t}function tq(r){if(pe(r)){var e=new DOMParser;r=e.parseFromString(r,"text/xml")}var t=r;for(t.nodeType===9&&(t=t.firstChild);t.nodeName.toLowerCase()!=="svg"||t.nodeType!==1;)t=t.nextSibling;return t}var gS,Zy={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},XL=rt(Zy),Qy={"alignment-baseline":"textBaseline","stop-color":"stopColor"},YL=rt(Qy),s0e=function(){function r(){this._defs={},this._root=null}return r.prototype.parse=function(e,t){t=t||{};var i=tq(e);this._defsUsePending=[];var n=new Le;this._root=n;var a=[],s=i.getAttribute("viewBox")||"",o=parseFloat(i.getAttribute("width")||t.width),l=parseFloat(i.getAttribute("height")||t.height);isNaN(o)&&(o=null),isNaN(l)&&(l=null),an(i,n,null,!0,!1);for(var u=i.firstChild;u;)this._parseNode(u,n,a,null,!1,!1),u=u.nextSibling;u0e(this._defs,this._defsUsePending),this._defsUsePending=[];var c,h;if(s){var d=M1(s);d.length>=4&&(c={x:parseFloat(d[0]||0),y:parseFloat(d[1]||0),width:parseFloat(d[2]),height:parseFloat(d[3])})}if(c&&o!=null&&l!=null&&(h=iq(c,{x:0,y:0,width:o,height:l}),!t.ignoreViewBox)){var f=n;n=new Le,n.add(f),f.scaleX=f.scaleY=h.scale,f.x=h.x,f.y=h.y}return!t.ignoreRootClip&&o!=null&&l!=null&&n.setClipPath(new st({shape:{x:0,y:0,width:o,height:l}})),{root:n,width:o,height:l,viewBoxRect:c,viewBoxTransform:h,named:a}},r.prototype._parseNode=function(e,t,i,n,a,s){var o=e.nodeName.toLowerCase(),l,u=n;if(o==="defs"&&(a=!0),o==="text"&&(s=!0),o==="defs"||o==="switch")l=t;else{if(!a){var c=gS[o];if(c&&_e(gS,o)){l=c.call(this,e,t);var h=e.getAttribute("name");if(h){var d={name:h,namedFrom:null,svgNodeTagLower:o,el:l};i.push(d),o==="g"&&(u=d)}else n&&i.push({name:n.name,namedFrom:n,svgNodeTagLower:o,el:l});t.add(l)}}var f=KL[o];if(f&&_e(KL,o)){var p=f.call(this,e),v=e.getAttribute("id");v&&(this._defs[v]=p)}}if(l&&l.isGroup)for(var g=e.firstChild;g;)g.nodeType===1?this._parseNode(g,l,i,u,a,s):g.nodeType===3&&s&&this._parseText(g,l),g=g.nextSibling},r.prototype._parseText=function(e,t){var i=new of({style:{text:e.textContent},silent:!0,x:this._textX||0,y:this._textY||0});En(t,i),an(e,i,this._defsUsePending,!1,!1),o0e(i,t);var n=i.style,a=n.fontSize;a&&a<9&&(n.fontSize=9,i.scaleX*=a/9,i.scaleY*=a/9);var s=(n.fontSize||n.fontFamily)&&[n.fontStyle,n.fontWeight,(n.fontSize||12)+"px",n.fontFamily||"sans-serif"].join(" ");n.font=s;var o=i.getBoundingRect();return this._textX+=o.width,t.add(i),i},r.internalField=function(){gS={g:function(e,t){var i=new Le;return En(t,i),an(e,i,this._defsUsePending,!1,!1),i},rect:function(e,t){var i=new st;return En(t,i),an(e,i,this._defsUsePending,!1,!1),i.setShape({x:parseFloat(e.getAttribute("x")||"0"),y:parseFloat(e.getAttribute("y")||"0"),width:parseFloat(e.getAttribute("width")||"0"),height:parseFloat(e.getAttribute("height")||"0")}),i.silent=!0,i},circle:function(e,t){var i=new eo;return En(t,i),an(e,i,this._defsUsePending,!1,!1),i.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),r:parseFloat(e.getAttribute("r")||"0")}),i.silent=!0,i},line:function(e,t){var i=new kr;return En(t,i),an(e,i,this._defsUsePending,!1,!1),i.setShape({x1:parseFloat(e.getAttribute("x1")||"0"),y1:parseFloat(e.getAttribute("y1")||"0"),x2:parseFloat(e.getAttribute("x2")||"0"),y2:parseFloat(e.getAttribute("y2")||"0")}),i.silent=!0,i},ellipse:function(e,t){var i=new u1;return En(t,i),an(e,i,this._defsUsePending,!1,!1),i.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),rx:parseFloat(e.getAttribute("rx")||"0"),ry:parseFloat(e.getAttribute("ry")||"0")}),i.silent=!0,i},polygon:function(e,t){var i=e.getAttribute("points"),n;i&&(n=JL(i));var a=new Ii({shape:{points:n||[]},silent:!0});return En(t,a),an(e,a,this._defsUsePending,!1,!1),a},polyline:function(e,t){var i=e.getAttribute("points"),n;i&&(n=JL(i));var a=new Pi({shape:{points:n||[]},silent:!0});return En(t,a),an(e,a,this._defsUsePending,!1,!1),a},image:function(e,t){var i=new Wr;return En(t,i),an(e,i,this._defsUsePending,!1,!1),i.setStyle({image:e.getAttribute("xlink:href")||e.getAttribute("href"),x:+e.getAttribute("x"),y:+e.getAttribute("y"),width:+e.getAttribute("width"),height:+e.getAttribute("height")}),i.silent=!0,i},text:function(e,t){var i=e.getAttribute("x")||"0",n=e.getAttribute("y")||"0",a=e.getAttribute("dx")||"0",s=e.getAttribute("dy")||"0";this._textX=parseFloat(i)+parseFloat(a),this._textY=parseFloat(n)+parseFloat(s);var o=new Le;return En(t,o),an(e,o,this._defsUsePending,!1,!0),o},tspan:function(e,t){var i=e.getAttribute("x"),n=e.getAttribute("y");i!=null&&(this._textX=parseFloat(i)),n!=null&&(this._textY=parseFloat(n));var a=e.getAttribute("dx")||"0",s=e.getAttribute("dy")||"0",o=new Le;return En(t,o),an(e,o,this._defsUsePending,!1,!0),this._textX+=parseFloat(a),this._textY+=parseFloat(s),o},path:function(e,t){var i=e.getAttribute("d")||"",n=WG(i);return En(t,n),an(e,n,this._defsUsePending,!1,!1),n.silent=!0,n}}}(),r}(),KL={lineargradient:function(r){var e=parseInt(r.getAttribute("x1")||"0",10),t=parseInt(r.getAttribute("y1")||"0",10),i=parseInt(r.getAttribute("x2")||"10",10),n=parseInt(r.getAttribute("y2")||"0",10),a=new tg(e,t,i,n);return ZL(r,a),QL(r,a),a},radialgradient:function(r){var e=parseInt(r.getAttribute("cx")||"0",10),t=parseInt(r.getAttribute("cy")||"0",10),i=parseInt(r.getAttribute("r")||"0",10),n=new YG(e,t,i);return ZL(r,n),QL(r,n),n}};function ZL(r,e){var t=r.getAttribute("gradientUnits");t==="userSpaceOnUse"&&(e.global=!0)}function QL(r,e){for(var t=r.firstChild;t;){if(t.nodeType===1&&t.nodeName.toLocaleLowerCase()==="stop"){var i=t.getAttribute("offset"),n=void 0;i&&i.indexOf("%")>0?n=parseInt(i,10)/100:i?n=parseFloat(i):n=0;var a={};rq(t,a,a);var s=a.stopColor||t.getAttribute("stop-color")||"#000000";e.colorStops.push({offset:n,color:s})}t=t.nextSibling}}function En(r,e){r&&r.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),Ce(e.__inheritedStyle,r.__inheritedStyle))}function JL(r){for(var e=M1(r),t=[],i=0;i0;a-=2){var s=i[a],o=i[a-1],l=M1(s);switch(n=n||vn(),o){case"translate":ss(n,n,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":KA(n,n,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":uc(n,n,-parseFloat(l[0])*mS,[parseFloat(l[1]||"0"),parseFloat(l[2]||"0")]);break;case"skewX":var u=Math.tan(parseFloat(l[0])*mS);Rs(n,[1,0,u,1,0,0],n);break;case"skewY":var c=Math.tan(parseFloat(l[0])*mS);Rs(n,[1,c,0,1,0,0],n);break;case"matrix":n[0]=parseFloat(l[0]),n[1]=parseFloat(l[1]),n[2]=parseFloat(l[2]),n[3]=parseFloat(l[3]),n[4]=parseFloat(l[4]),n[5]=parseFloat(l[5]);break}}e.setLocalTransform(n)}}var tk=/([^\s:;]+)\s*:\s*([^:;]+)/g;function rq(r,e,t){var i=r.getAttribute("style");if(i){tk.lastIndex=0;for(var n;(n=tk.exec(i))!=null;){var a=n[1],s=_e(Zy,a)?Zy[a]:null;s&&(e[s]=n[2]);var o=_e(Qy,a)?Qy[a]:null;o&&(t[o]=n[2])}}}function d0e(r,e,t){for(var i=0;i0,g={api:i,geo:l,mapOrGeoModel:e,data:o,isVisualEncodedByVisualMap:v,isGeo:s,transformInfoRaw:d};l.resourceType==="geoJSON"?this._buildGeoJSON(g):l.resourceType==="geoSVG"&&this._buildSVG(g),this._updateController(e,t,i),this._updateMapSelectHandler(e,u,i,n)},r.prototype._buildGeoJSON=function(e){var t=this._regionsGroupByName=be(),i=be(),n=this._regionsGroup,a=e.transformInfoRaw,s=e.mapOrGeoModel,o=e.data,l=e.geo.projection,u=l&&l.stream;function c(f,p){return p&&(f=p(f)),f&&[f[0]*a.scaleX+a.x,f[1]*a.scaleY+a.y]}function h(f){for(var p=[],v=!u&&l&&l.project,g=0;g=0)&&(d=n);var f=s?{normal:{align:"center",verticalAlign:"middle"}}:null;Jr(e,Nr(i),{labelFetcher:d,labelDataIndex:h,defaultText:t},f);var p=e.getTextContent();if(p&&(nq(p).ignore=p.ignore,e.textConfig&&s)){var v=e.getBoundingRect().clone();e.textConfig.layoutRect=v,e.textConfig.position=[(s[0]-v.x)/v.width*100+"%",(s[1]-v.y)/v.height*100+"%"]}e.disableLabelAnimation=!0}else e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null}function sk(r,e,t,i,n,a){r.data?r.data.setItemGraphicEl(a,e):ke(e).eventData={componentType:"geo",componentIndex:n.componentIndex,geoIndex:n.componentIndex,name:t,region:i&&i.option||{}}}function ok(r,e,t,i,n){r.data||kf({el:e,componentModel:n,itemName:t,itemTooltipOption:i.get("tooltip")})}function lk(r,e,t,i,n){e.highDownSilentOnTouch=!!n.get("selectedMode");var a=i.getModel("emphasis"),s=a.get("focus");return Yt(e,s,a.get("blurScope"),a.get("disabled")),r.isGeo&&Ice(e,n,t),s}function uk(r,e,t){var i=[],n;function a(){n=[]}function s(){n.length&&(i.push(n),n=[])}var o=e({polygonStart:a,polygonEnd:s,lineStart:a,lineEnd:s,point:function(l,u){isFinite(l)&&isFinite(u)&&n.push([l,u])},sphere:function(){}});return!t&&o.polygonStart(),R(r,function(l){o.lineStart();for(var u=0;u-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2),n},e.type="series.map",e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},e}(Ot);function k0e(r,e){var t={};return R(r,function(i){i.each(i.mapDimension("value"),function(n,a){var s="ec-"+i.getName(a);t[s]=t[s]||[],isNaN(n)||t[s].push(n)})}),r[0].map(r[0].mapDimension("value"),function(i,n){for(var a="ec-"+r[0].getName(n),s=0,o=1/0,l=-1/0,u=t[a].length,c=0;c1?(b.width=_,b.height=_/g):(b.height=_,b.width=_*g),b.y=y[1]-b.height/2,b.x=y[0]-b.width/2;else{var T=r.getBoxLayoutParams();T.aspect=g,b=Ar(T,{width:p,height:v})}this.setViewRect(b.x,b.y,b.width,b.height),this.setCenter(r.get("center"),e),this.setZoom(r.get("zoom"))}function B0e(r,e){R(e.get("geoCoord"),function(t,i){r.addGeoCoord(i,t)})}var F0e=function(){function r(){this.dimensions=sq}return r.prototype.create=function(e,t){var i=[];function n(s){return{nameProperty:s.get("nameProperty"),aspectScale:s.get("aspectScale"),projection:s.get("projection")}}e.eachComponent("geo",function(s,o){var l=s.get("map"),u=new Iw(l+o,l,J({nameMap:s.get("nameMap")},n(s)));u.zoomLimit=s.get("scaleLimit"),i.push(u),s.coordinateSystem=u,u.model=s,u.resize=dk,u.resize(s,t)}),e.eachSeries(function(s){var o=s.get("coordinateSystem");if(o==="geo"){var l=s.get("geoIndex")||0;s.coordinateSystem=i[l]}});var a={};return e.eachSeriesByType("map",function(s){if(!s.getHostGeoModel()){var o=s.getMapType();a[o]=a[o]||[],a[o].push(s)}}),R(a,function(s,o){var l=oe(s,function(c){return c.get("nameMap")}),u=new Iw(o,o,J({nameMap:WA(l)},n(s[0])));u.zoomLimit=Gr.apply(null,oe(s,function(c){return c.get("scaleLimit")})),i.push(u),u.resize=dk,u.resize(s[0],t),R(s,function(c){c.coordinateSystem=u,B0e(u,c)})}),i},r.prototype.getFilledRegions=function(e,t,i,n){for(var a=(e||[]).slice(),s=be(),o=0;o=0;s--){var o=n[s];o.hierNode={defaultAncestor:null,ancestor:o,prelim:0,modifier:0,change:0,shift:0,i:s,thread:null},t.push(o)}}function $0e(r,e){var t=r.isExpand?r.children:[],i=r.parentNode.children,n=r.hierNode.i?i[r.hierNode.i-1]:null;if(t.length){j0e(r);var a=(t[0].hierNode.prelim+t[t.length-1].hierNode.prelim)/2;n?(r.hierNode.prelim=n.hierNode.prelim+e(r,n),r.hierNode.modifier=r.hierNode.prelim-a):r.hierNode.prelim=a}else n&&(r.hierNode.prelim=n.hierNode.prelim+e(r,n));r.parentNode.hierNode.defaultAncestor=X0e(r,n,r.parentNode.hierNode.defaultAncestor||i[0],e)}function W0e(r){var e=r.hierNode.prelim+r.parentNode.hierNode.modifier;r.setLayout({x:e},!0),r.hierNode.modifier+=r.parentNode.hierNode.modifier}function vk(r){return arguments.length?r:Z0e}function up(r,e){return r-=Math.PI/2,{x:e*Math.cos(r),y:e*Math.sin(r)}}function q0e(r,e){return Ar(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function j0e(r){for(var e=r.children,t=e.length,i=0,n=0;--t>=0;){var a=e[t];a.hierNode.prelim+=i,a.hierNode.modifier+=i,n+=a.hierNode.change,i+=a.hierNode.shift+n}}function X0e(r,e,t,i){if(e){for(var n=r,a=r,s=a.parentNode.children[0],o=e,l=n.hierNode.modifier,u=a.hierNode.modifier,c=s.hierNode.modifier,h=o.hierNode.modifier;o=yS(o),a=_S(a),o&&a;){n=yS(n),s=_S(s),n.hierNode.ancestor=r;var d=o.hierNode.prelim+h-a.hierNode.prelim-u+i(o,a);d>0&&(K0e(Y0e(o,r,t),r,d),u+=d,l+=d),h+=o.hierNode.modifier,u+=a.hierNode.modifier,l+=n.hierNode.modifier,c+=s.hierNode.modifier}o&&!yS(n)&&(n.hierNode.thread=o,n.hierNode.modifier+=h-l),a&&!_S(s)&&(s.hierNode.thread=a,s.hierNode.modifier+=u-c,t=r)}return t}function yS(r){var e=r.children;return e.length&&r.isExpand?e[e.length-1]:r.hierNode.thread}function _S(r){var e=r.children;return e.length&&r.isExpand?e[0]:r.hierNode.thread}function Y0e(r,e,t){return r.hierNode.ancestor.parentNode===e.parentNode?r.hierNode.ancestor:t}function K0e(r,e,t){var i=t/(e.hierNode.i-r.hierNode.i);e.hierNode.change-=i,e.hierNode.shift+=t,e.hierNode.modifier+=t,e.hierNode.prelim+=t,r.hierNode.change+=i}function Z0e(r,e){return r.parentNode===e.parentNode?1:2}var Q0e=function(){function r(){this.parentPoint=[],this.childPoints=[]}return r}(),J0e=function(r){j(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Q0e},e.prototype.buildPath=function(t,i){var n=i.childPoints,a=n.length,s=i.parentPoint,o=n[0],l=n[a-1];if(a===1){t.moveTo(s[0],s[1]),t.lineTo(o[0],o[1]);return}var u=i.orient,c=u==="TB"||u==="BT"?0:1,h=1-c,d=ce(i.forkPosition,1),f=[];f[c]=s[c],f[h]=s[h]+(l[h]-s[h])*d,t.moveTo(s[0],s[1]),t.lineTo(f[0],f[1]),t.moveTo(o[0],o[1]),f[c]=o[c],t.lineTo(f[0],f[1]),f[c]=l[c],t.lineTo(f[0],f[1]),t.lineTo(l[0],l[1]);for(var p=1;py.x,T||(b=b-Math.PI));var C=T?"left":"right",D=o.getModel("label"),I=D.get("rotate"),M=I*(Math.PI/180),L=g.getTextContent();L&&(g.setTextConfig({position:D.get("position")||C,rotation:I==null?-b:M,origin:"center"}),L.setStyle("verticalAlign","middle"))}var N=o.get(["emphasis","focus"]),O=N==="relative"?Sy(s.getAncestorsIndices(),s.getDescendantIndices()):N==="ancestor"?s.getAncestorsIndices():N==="descendant"?s.getDescendantIndices():null;O&&(ke(t).focus=O),tye(n,s,c,t,p,f,v,i),t.__edge&&(t.onHoverStateChange=function(B){if(B!=="blur"){var F=s.parentNode&&r.getItemGraphicEl(s.parentNode.dataIndex);F&&F.hoverState===Qv||My(t.__edge,B)}})}function tye(r,e,t,i,n,a,s,o){var l=e.getModel(),u=r.get("edgeShape"),c=r.get("layout"),h=r.getOrient(),d=r.get(["lineStyle","curveness"]),f=r.get("edgeForkPosition"),p=l.getModel("lineStyle").getLineStyle(),v=i.__edge;if(u==="curve")e.parentNode&&e.parentNode!==t&&(v||(v=i.__edge=new eg({shape:Pw(c,h,d,n,n)})),ct(v,{shape:Pw(c,h,d,a,s)},r));else if(u==="polyline"&&c==="orthogonal"&&e!==t&&e.children&&e.children.length!==0&&e.isExpand===!0){for(var g=e.children,m=[],y=0;yt&&(t=n.height)}this.height=t+1},r.prototype.getNodeById=function(e){if(this.getId()===e)return this;for(var t=0,i=this.children,n=i.length;t=0&&this.hostTree.data.setItemLayout(this.dataIndex,e,t)},r.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostTree,i=t.data.getItemModel(this.dataIndex);return i.getModel(e)}},r.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},r.prototype.setVisual=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,e,t)},r.prototype.getVisual=function(e){return this.hostTree.data.getItemVisual(this.dataIndex,e)},r.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},r.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},r.prototype.getChildIndex=function(){if(this.parentNode){for(var e=this.parentNode.children,t=0;t=0){var i=t.getData().tree.root,n=r.targetNode;if(pe(n)&&(n=i.getNodeById(n)),n&&i.contains(n))return{node:n};var a=r.targetNodeId;if(a!=null&&(n=i.getNodeById(a)))return{node:n}}}function fq(r){for(var e=[];r;)r=r.parentNode,r&&e.push(r);return e.reverse()}function oE(r,e){var t=fq(r);return Xe(t,e)>=0}function L1(r,e){for(var t=[];r;){var i=r.dataIndex;t.push({name:r.name,dataIndex:i,value:e.getRawValue(i)}),r=r.parentNode}return t.reverse(),t}var cye=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.hasSymbolVisual=!0,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t){var i={name:t.name,children:t.data},n=t.leaves||{},a=new yt(n,this,this.ecModel),s=sE.createTree(i,this,o);function o(h){h.wrapMethod("getItemModel",function(d,f){var p=s.getNodeByDataIndex(f);return p&&p.children.length&&p.isExpand||(d.parentModel=a),d})}var l=0;s.eachNode("preorder",function(h){h.depth>l&&(l=h.depth)});var u=t.expandAndCollapse,c=u&&t.initialTreeDepth>=0?t.initialTreeDepth:l;return s.root.eachNode("preorder",function(h){var d=h.hostTree.data.getRawDataItem(h.dataIndex);h.isExpand=d&&d.collapsed!=null?!d.collapsed:h.depth<=c}),s.data},e.prototype.getOrient=function(){var t=this.get("orient");return t==="horizontal"?t="LR":t==="vertical"&&(t="TB"),t},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.formatTooltip=function(t,i,n){for(var a=this.getData().tree,s=a.root.children[0],o=a.getNodeByDataIndex(t),l=o.getValue(),u=o.name;o&&o!==s;)u=o.parentNode.name+"."+u,o=o.parentNode;return Br("nameValue",{name:u,value:l,noValue:isNaN(l)||l==null})},e.prototype.getDataParams=function(t){var i=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return i.treeAncestors=L1(n,this),i.collapsed=!n.isExpand,i},e.type="series.tree",e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},e}(Ot);function hye(r,e,t){for(var i=[r],n=[],a;a=i.pop();)if(n.push(a),a.isExpand){var s=a.children;if(s.length)for(var o=0;o=0;a--)t.push(n[a])}}function fye(r,e){r.eachSeriesByType("tree",function(t){dye(t,e)})}function dye(r,e){var t=q0e(r,e);r.layoutInfo=t;var i=r.get("layout"),n=0,a=0,s=null;i==="radial"?(n=2*Math.PI,a=Math.min(t.height,t.width)/2,s=vk(function(_,b){return(_.parentNode===b.parentNode?1:2)/_.depth})):(n=t.width,a=t.height,s=vk());var o=r.getData().tree.root,l=o.children[0];if(l){H0e(o),hye(l,$0e,s),o.hierNode.modifier=-l.hierNode.prelim,Rd(l,W0e);var u=l,c=l,h=l;Rd(l,function(_){var b=_.getLayout().x;bc.getLayout().x&&(c=_),_.depth>h.depth&&(h=_)});var d=u===c?1:s(u,c)/2,f=d-u.getLayout().x,p=0,v=0,g=0,m=0;if(i==="radial")p=n/(c.getLayout().x+d+f),v=a/(h.depth-1||1),Rd(l,function(_){g=(_.getLayout().x+f)*p,m=(_.depth-1)*v;var b=up(g,m);_.setLayout({x:b.x,y:b.y,rawX:g,rawY:m},!0)});else{var y=r.getOrient();y==="RL"||y==="LR"?(v=a/(c.getLayout().x+d+f),p=n/(h.depth-1||1),Rd(l,function(_){m=(_.getLayout().x+f)*v,g=y==="LR"?(_.depth-1)*p:n-(_.depth-1)*p,_.setLayout({x:g,y:m},!0)})):(y==="TB"||y==="BT")&&(p=n/(c.getLayout().x+d+f),v=a/(h.depth-1||1),Rd(l,function(_){g=(_.getLayout().x+f)*p,m=y==="TB"?(_.depth-1)*v:a-(_.depth-1)*v,_.setLayout({x:g,y:m},!0)}))}}}function pye(r){r.eachSeriesByType("tree",function(e){var t=e.getData(),i=t.tree;i.eachNode(function(n){var a=n.getModel(),s=a.getModel("itemStyle").getItemStyle(),o=t.ensureUniqueItemVisual(n.dataIndex,"style");J(o,s)})})}function vye(r){r.registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"tree",query:e},function(i){var n=e.dataIndex,a=i.getData().tree,s=a.getNodeByDataIndex(n);s.isExpand=!s.isExpand})}),r.registerAction({type:"treeRoam",event:"treeRoam",update:"none"},function(e,t,i){t.eachComponent({mainType:"series",subType:"tree",query:e},function(n){var a=n.coordinateSystem,s=nE(a,e,void 0,i);n.setCenter&&n.setCenter(s.center),n.setZoom&&n.setZoom(s.zoom)})})}function gye(r){r.registerChartView(eye),r.registerSeriesModel(cye),r.registerLayout(fye),r.registerVisual(pye),vye(r)}var bk=["treemapZoomToNode","treemapRender","treemapMove"];function mye(r){for(var e=0;e1;)a=a.parentNode;var s=nw(r.ecModel,a.name||a.dataIndex+"",i);n.setVisual("decal",s)})}var yye=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventUsingHoverLayer=!0,t}return e.prototype.getInitialData=function(t,i){var n={name:t.name,children:t.data};pq(n);var a=t.levels||[],s=this.designatedVisualItemStyle={},o=new yt({itemStyle:s},this,i);a=t.levels=_ye(a,i);var l=oe(a||[],function(h){return new yt(h,o,i)},this),u=sE.createTree(n,this,c);function c(h){h.wrapMethod("getItemModel",function(d,f){var p=u.getNodeByDataIndex(f),v=p?l[p.depth]:null;return d.parentModel=v||o,d})}return u.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.formatTooltip=function(t,i,n){var a=this.getData(),s=this.getRawValue(t),o=a.getName(t);return Br("nameValue",{name:o,value:s})},e.prototype.getDataParams=function(t){var i=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return i.treeAncestors=L1(n,this),i.treePathInfo=i.treeAncestors,i},e.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},J(this.layoutInfo,t)},e.prototype.mapIdToIndex=function(t){var i=this._idIndexMap;i||(i=this._idIndexMap=be(),this._idIndexMapCount=0);var n=i.get(t);return n==null&&i.set(t,n=this._idIndexMapCount++),n},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var i=this.getRawData().tree.root;(!t||t!==i&&!i.contains(t))&&(this._viewRoot=i)},e.prototype.enableAriaDecal=function(){dq(this)},e.type="series.treemap",e.layoutMode="box",e.defaultOption={progressive:0,left:"center",top:"middle",width:"80%",height:"80%",sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.32*.32,scaleLimit:null,roam:!0,nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",top:"bottom",emptyItemWidth:25,itemStyle:{color:"rgba(0,0,0,0.7)",textStyle:{color:"#fff"}},emphasis:{itemStyle:{color:"rgba(0,0,0,0.9)"}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},e}(Ot);function pq(r){var e=0;R(r.children,function(i){pq(i);var n=i.value;ie(n)&&(n=n[0]),e+=n});var t=r.value;ie(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),ie(r.value)?r.value[0]=t:r.value=t}function _ye(r,e){var t=xt(e.get("color")),i=xt(e.get(["aria","decal","decals"]));if(t){r=r||[];var n,a;R(r,function(o){var l=new yt(o),u=l.get("color"),c=l.get("decal");(l.get(["itemStyle","color"])||u&&u!=="none")&&(n=!0),(l.get(["itemStyle","decal"])||c&&c!=="none")&&(a=!0)});var s=r[0]||(r[0]={});return n||(s.color=t.slice()),!a&&i&&(s.decal=i.slice()),r}}var bye=8,Sk=8,bS=5,Sye=function(){function r(e){this.group=new Le,e.add(this.group)}return r.prototype.render=function(e,t,i,n){var a=e.getModel("breadcrumb"),s=this.group;if(s.removeAll(),!(!a.get("show")||!i)){var o=a.getModel("itemStyle"),l=a.getModel("emphasis"),u=o.getModel("textStyle"),c=l.getModel(["itemStyle","textStyle"]),h={pos:{left:a.get("left"),right:a.get("right"),top:a.get("top"),bottom:a.get("bottom")},box:{width:t.getWidth(),height:t.getHeight()},emptyItemWidth:a.get("emptyItemWidth"),totalWidth:0,renderList:[]};this._prepare(i,h,u),this._renderContent(e,h,o,l,u,c,n),_1(s,h.pos,h.box)}},r.prototype._prepare=function(e,t,i){for(var n=e;n;n=n.parentNode){var a=wr(n.getModel().get("name"),""),s=i.getTextRect(a),o=Math.max(s.width+bye*2,t.emptyItemWidth);t.totalWidth+=o+Sk,t.renderList.push({node:n,text:a,width:o})}},r.prototype._renderContent=function(e,t,i,n,a,s,o){for(var l=0,u=t.emptyItemWidth,c=e.get(["breadcrumb","height"]),h=Mhe(t.pos,t.box),d=t.totalWidth,f=t.renderList,p=n.getModel("itemStyle").getItemStyle(),v=f.length-1;v>=0;v--){var g=f[v],m=g.node,y=g.width,_=g.text;d>h.width&&(d-=y-u,y=u,_=null);var b=new Ii({shape:{points:Tye(l,0,y,c,v===f.length-1,v===0)},style:Ce(i.getItemStyle(),{lineJoin:"bevel"}),textContent:new lt({style:kt(a,{text:_})}),textConfig:{position:"inside"},z2:Mf*1e4,onclick:Ue(o,m)});b.disableLabelAnimation=!0,b.getTextContent().ensureState("emphasis").style=kt(s,{text:_}),b.ensureState("emphasis").style=p,Yt(b,n.get("focus"),n.get("blurScope"),n.get("disabled")),this.group.add(b),xye(b,e,m),l+=y+Sk}},r.prototype.remove=function(){this.group.removeAll()},r}();function Tye(r,e,t,i,n,a){var s=[[n?r:r-bS,e],[r+t,e],[r+t,e+i],[n?r:r-bS,e+i]];return!a&&s.splice(2,0,[r+t+bS,e+i/2]),!n&&s.push([r,e+i/2]),s}function xye(r,e,t){ke(r).eventData={componentType:"series",componentSubType:"treemap",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:t&&t.dataIndex,name:t&&t.name},treePathInfo:t&&L1(t,e)}}var wye=function(){function r(){this._storage=[],this._elExistsMap={}}return r.prototype.add=function(e,t,i,n,a){return this._elExistsMap[e.id]?!1:(this._elExistsMap[e.id]=!0,this._storage.push({el:e,target:t,duration:i,delay:n,easing:a}),!0)},r.prototype.finished=function(e){return this._finishedCallback=e,this},r.prototype.start=function(){for(var e=this,t=this._storage.length,i=function(){t--,t<=0&&(e._storage.length=0,e._elExistsMap={},e._finishedCallback&&e._finishedCallback())},n=0,a=this._storage.length;nxk||Math.abs(t.dy)>xk)){var i=this.seriesModel.getData().tree.root;if(!i)return;var n=i.getLayout();if(!n)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:n.x+t.dx,y:n.y+t.dy,width:n.width,height:n.height}})}},e.prototype._onZoom=function(t){var i=t.originX,n=t.originY,a=t.scale;if(this._state!=="animating"){var s=this.seriesModel.getData().tree.root;if(!s)return;var o=s.getLayout();if(!o)return;var l=new qe(o.x,o.y,o.width,o.height),u=null,c=this._controllerHost;u=c.zoomLimit;var h=c.zoom=c.zoom||1;if(h*=a,u){var d=u.min||0,f=u.max||1/0;h=Math.max(Math.min(f,h),d)}var p=h/c.zoom;c.zoom=h;var v=this.seriesModel.layoutInfo;i-=v.x,n-=v.y;var g=vn();ss(g,g,[-i,-n]),KA(g,g,[p,p]),ss(g,g,[i,n]),l.applyTransform(g),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:l.x,y:l.y,width:l.width,height:l.height}})}},e.prototype._initEvents=function(t){var i=this;t.on("click",function(n){if(i._state==="ready"){var a=i.seriesModel.get("nodeClick",!0);if(a){var s=i.findTarget(n.offsetX,n.offsetY);if(s){var o=s.node;if(o.getLayout().isLeafRoot)i._rootToNode(s);else if(a==="zoomToNode")i._zoomToNode(s);else if(a==="link"){var l=o.hostTree.data.getItemModel(o.dataIndex),u=l.get("link",!0),c=l.get("target",!0)||"blank";u&&By(u,c)}}}}},this)},e.prototype._renderBreadcrumb=function(t,i,n){var a=this;n||(n=t.get("leafDepth",!0)!=null?{node:t.getViewRoot()}:this.findTarget(i.getWidth()/2,i.getHeight()/2),n||(n={node:t.getData().tree.root})),(this._breadcrumb||(this._breadcrumb=new Sye(this.group))).render(t,i,n.node,function(s){a._state!=="animating"&&(oE(t.getViewRoot(),s)?a._rootToNode({node:s}):a._zoomToNode({node:s}))})},e.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=Od(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},e.prototype.dispose=function(){this._clearController()},e.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype.findTarget=function(t,i){var n,a=this.seriesModel.getViewRoot();return a.eachNode({attr:"viewChildren",order:"preorder"},function(s){var o=this._storage.background[s.getRawIndex()];if(o){var l=o.transformCoordToLocal(t,i),u=o.shape;if(u.x<=l[0]&&l[0]<=u.x+u.width&&u.y<=l[1]&&l[1]<=u.y+u.height)n={node:s,offsetX:l[0],offsetY:l[1]};else return!1}},this),n},e.type="treemap",e}(Ct);function Od(){return{nodeGroup:[],background:[],content:[]}}function Pye(r,e,t,i,n,a,s,o,l,u){if(!s)return;var c=s.getLayout(),h=r.getData(),d=s.getModel();if(h.setItemGraphicEl(s.dataIndex,null),!c||!c.isInView)return;var f=c.width,p=c.height,v=c.borderWidth,g=c.invisible,m=s.getRawIndex(),y=o&&o.getRawIndex(),_=s.viewChildren,b=c.upperHeight,T=_&&_.length,x=d.getModel("itemStyle"),C=d.getModel(["emphasis","itemStyle"]),D=d.getModel(["blur","itemStyle"]),I=d.getModel(["select","itemStyle"]),M=x.get("borderRadius")||0,L=ue("nodeGroup",Mw);if(!L)return;if(l.add(L),L.x=c.x||0,L.y=c.y||0,L.markRedraw(),Jy(L).nodeWidth=f,Jy(L).nodeHeight=p,c.isAboveViewRoot)return L;var N=ue("background",Tk,u,Dye);N&&Z(L,N,T&&c.upperLabelHeight);var O=d.getModel("emphasis"),B=O.get("focus"),F=O.get("blurScope"),U=O.get("disabled"),$=B==="ancestor"?s.getAncestorsIndices():B==="descendant"?s.getDescendantIndices():B;if(T)pv(L)&&yu(L,!1),N&&(yu(N,!U),h.setItemGraphicEl(s.dataIndex,N),Kx(N,$,F));else{var q=ue("content",Tk,u,Eye);q&&te(L,q),N.disableMorphing=!0,N&&pv(N)&&yu(N,!1),yu(L,!U),h.setItemGraphicEl(s.dataIndex,L),Kx(L,$,F)}return L;function Z(Fe,me,ze){var Pe=ke(me);if(Pe.dataIndex=s.dataIndex,Pe.seriesIndex=r.seriesIndex,me.setShape({x:0,y:0,width:f,height:p,r:M}),g)Q(me);else{me.invisible=!1;var ye=s.getVisual("style"),Me=ye.stroke,_t=Ak(x);_t.fill=Me;var Re=tu(C);Re.fill=C.get("borderColor");var Ge=tu(D);Ge.fill=D.get("borderColor");var Pt=tu(I);if(Pt.fill=I.get("borderColor"),ze){var wt=f-2*v;se(me,Me,ye.opacity,{x:v,y:0,width:wt,height:b})}else me.removeTextContent();me.setStyle(_t),me.ensureState("emphasis").style=Re,me.ensureState("blur").style=Ge,me.ensureState("select").style=Pt,rc(me)}Fe.add(me)}function te(Fe,me){var ze=ke(me);ze.dataIndex=s.dataIndex,ze.seriesIndex=r.seriesIndex;var Pe=Math.max(f-2*v,0),ye=Math.max(p-2*v,0);if(me.culling=!0,me.setShape({x:v,y:v,width:Pe,height:ye,r:M}),g)Q(me);else{me.invisible=!1;var Me=s.getVisual("style"),_t=Me.fill,Re=Ak(x);Re.fill=_t,Re.decal=Me.decal;var Ge=tu(C),Pt=tu(D),wt=tu(I);se(me,_t,Me.opacity,null),me.setStyle(Re),me.ensureState("emphasis").style=Ge,me.ensureState("blur").style=Pt,me.ensureState("select").style=wt,rc(me)}Fe.add(me)}function Q(Fe){!Fe.invisible&&a.push(Fe)}function se(Fe,me,ze,Pe){var ye=d.getModel(Pe?Ck:wk),Me=wr(d.get("name"),null),_t=ye.getShallow("show");Jr(Fe,Nr(d,Pe?Ck:wk),{defaultText:_t?Me:null,inheritColor:me,defaultOpacity:ze,labelFetcher:r,labelDataIndex:s.dataIndex});var Re=Fe.getTextContent();if(Re){var Ge=Re.style,Pt=jA(Ge.padding||0);Pe&&(Fe.setTextConfig({layoutRect:Pe}),Re.disableLabelLayout=!0),Re.beforeUpdate=function(){var At=Math.max((Pe?Pe.width:Fe.shape.width)-Pt[1]-Pt[3],0),rr=Math.max((Pe?Pe.height:Fe.shape.height)-Pt[0]-Pt[2],0);(Ge.width!==At||Ge.height!==rr)&&Re.setStyle({width:At,height:rr})},Ge.truncateMinChar=2,Ge.lineOverflow="truncate",he(Ge,Pe,c);var wt=Re.getState("emphasis");he(wt?wt.style:null,Pe,c)}}function he(Fe,me,ze){var Pe=Fe?Fe.text:null;if(!me&&ze.isLeafRoot&&Pe!=null){var ye=r.get("drillDownIcon",!0);Fe.text=ye?ye+" "+Pe:Pe}}function ue(Fe,me,ze,Pe){var ye=y!=null&&t[Fe][y],Me=n[Fe];return ye?(t[Fe][y]=null,Ie(Me,ye)):g||(ye=new me,ye instanceof Yn&&(ye.z2=Mye(ze,Pe)),Oe(Me,ye)),e[Fe][m]=ye}function Ie(Fe,me){var ze=Fe[m]={};me instanceof Mw?(ze.oldX=me.x,ze.oldY=me.y):ze.oldShape=J({},me.shape)}function Oe(Fe,me){var ze=Fe[m]={},Pe=s.parentNode,ye=me instanceof Le;if(Pe&&(!i||i.direction==="drillDown")){var Me=0,_t=0,Re=n.background[Pe.getRawIndex()];!i&&Re&&Re.oldShape&&(Me=Re.oldShape.width,_t=Re.oldShape.height),ye?(ze.oldX=0,ze.oldY=_t):ze.oldShape={x:Me,y:_t,width:0,height:0}}ze.fadein=!ye}}function Mye(r,e){return r*Aye+e}var Ev=R,Lye=De,e_=-1,Or=function(){function r(e){var t=e.mappingMethod,i=e.type,n=this.option=Ee(e);this.type=i,this.mappingMethod=t,this._normalizeData=Oye[t];var a=r.visualHandlers[i];this.applyVisual=a.applyVisual,this.getColorMapper=a.getColorMapper,this._normalizedToVisual=a._normalizedToVisual[t],t==="piecewise"?(SS(n),kye(n)):t==="category"?n.categories?Rye(n):SS(n,!0):(Ai(t!=="linear"||n.dataExtent),SS(n))}return r.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},r.prototype.getNormalizer=function(){return ge(this._normalizeData,this)},r.listVisualTypes=function(){return rt(r.visualHandlers)},r.isValidType=function(e){return r.visualHandlers.hasOwnProperty(e)},r.eachVisual=function(e,t,i){De(e)?R(e,t,i):t.call(i,e)},r.mapVisual=function(e,t,i){var n,a=ie(e)?[]:De(e)?{}:(n=!0,null);return r.eachVisual(e,function(s,o){var l=t.call(i,s,o);n?a=l:a[o]=l}),a},r.retrieveVisuals=function(e){var t={},i;return e&&Ev(r.visualHandlers,function(n,a){e.hasOwnProperty(a)&&(t[a]=e[a],i=!0)}),i?t:null},r.prepareVisualTypes=function(e){if(ie(e))e=e.slice();else if(Lye(e)){var t=[];Ev(e,function(i,n){t.push(n)}),e=t}else return[];return e.sort(function(i,n){return n==="color"&&i!=="color"&&i.indexOf("color")===0?1:-1}),e},r.dependsOn=function(e,t){return t==="color"?!!(e&&e.indexOf(t)===0):e===t},r.findPieceIndex=function(e,t,i){for(var n,a=1/0,s=0,o=t.length;s=0;a--)i[a]==null&&(delete t[e[a]],e.pop())}function SS(r,e){var t=r.visual,i=[];De(t)?Ev(t,function(a){i.push(a)}):t!=null&&i.push(t);var n={color:1,symbol:1};!e&&i.length===1&&!n.hasOwnProperty(r.type)&&(i[1]=i[0]),vq(r,i)}function zm(r){return{applyVisual:function(e,t,i){var n=this.mapValueToVisual(e);i("color",r(t("color"),n))},_normalizedToVisual:Lw([0,1])}}function Dk(r){var e=this.option.visual;return e[Math.round(bt(r,[0,1],[0,e.length-1],!0))]||{}}function Nd(r){return function(e,t,i){i(r,this.mapValueToVisual(e))}}function cp(r){var e=this.option.visual;return e[this.option.loop&&r!==e_?r%e.length:r]}function ru(){return this.option.visual[0]}function Lw(r){return{linear:function(e){return bt(e,r,this.option.visual,!0)},category:cp,piecewise:function(e,t){var i=kw.call(this,t);return i==null&&(i=bt(e,r,this.option.visual,!0)),i},fixed:ru}}function kw(r){var e=this.option,t=e.pieceList;if(e.hasSpecialVisual){var i=Or.findPieceIndex(r,t),n=t[i];if(n&&n.visual)return n.visual[this.type]}}function vq(r,e){return r.visual=e,r.type==="color"&&(r.parsedVisual=oe(e,function(t){var i=gn(t);return i||[0,0,0,1]})),e}var Oye={linear:function(r){return bt(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var e=this.option.pieceList,t=Or.findPieceIndex(r,e,!0);if(t!=null)return bt(t,[0,e.length-1],[0,1],!0)},category:function(r){var e=this.option.categories?this.option.categoryMap[r]:r;return e??e_},fixed:lr};function Gm(r,e,t){return r?e<=t:e=t.length||v===t[v.depth]){var m=zye(n,l,v,g,p,i);mq(v,m,t,i)}})}}}function Fye(r,e,t){var i=J({},e),n=t.designatedVisualItemStyle;return R(["color","colorAlpha","colorSaturation"],function(a){n[a]=e[a];var s=r.get(a);n[a]=null,s!=null&&(i[a]=s)}),i}function Ek(r){var e=TS(r,"color");if(e){var t=TS(r,"colorAlpha"),i=TS(r,"colorSaturation");return i&&(e=Ip(e,null,null,i)),t&&(e=Cy(e,t)),e}}function Uye(r,e){return e!=null?Ip(e,null,null,r):null}function TS(r,e){var t=r[e];if(t!=null&&t!=="none")return t}function Vye(r,e,t,i,n,a){if(!(!a||!a.length)){var s=xS(e,"color")||n.color!=null&&n.color!=="none"&&(xS(e,"colorAlpha")||xS(e,"colorSaturation"));if(s){var o=e.get("visualMin"),l=e.get("visualMax"),u=t.dataExtent.slice();o!=null&&ou[1]&&(u[1]=l);var c=e.get("colorMappingBy"),h={type:s.name,dataExtent:u,visual:s.range};h.type==="color"&&(c==="index"||c==="id")?(h.mappingMethod="category",h.loop=!0):h.mappingMethod="linear";var d=new Or(h);return gq(d).drColorMappingBy=c,d}}}function xS(r,e){var t=r.get(e);return ie(t)&&t.length?{name:e,range:t}:null}function zye(r,e,t,i,n,a){var s=J({},e);if(n){var o=n.type,l=o==="color"&&gq(n).drColorMappingBy,u=l==="index"?i:l==="id"?a.mapIdToIndex(t.getId()):t.getValue(r.get("visualDimension"));s[o]=n.mapValueToVisual(u)}return s}var Iv=Math.max,t_=Math.min,Ik=Gr,lE=R,yq=["itemStyle","borderWidth"],Gye=["itemStyle","gapWidth"],Hye=["upperLabel","show"],$ye=["upperLabel","height"];const Wye={seriesType:"treemap",reset:function(r,e,t,i){var n=t.getWidth(),a=t.getHeight(),s=r.option,o=Ar(r.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),l=s.size||[],u=ce(Ik(o.width,l[0]),n),c=ce(Ik(o.height,l[1]),a),h=i&&i.type,d=["treemapZoomToNode","treemapRootToNode"],f=Dv(i,d,r),p=h==="treemapRender"||h==="treemapMove"?i.rootRect:null,v=r.getViewRoot(),g=fq(v);if(h!=="treemapMove"){var m=h==="treemapZoomToNode"?Zye(r,f,v,u,c):p?[p.width,p.height]:[u,c],y=s.sort;y&&y!=="asc"&&y!=="desc"&&(y="desc");var _={squareRatio:s.squareRatio,sort:y,leafDepth:s.leafDepth};v.hostTree.clearLayouts();var b={x:0,y:0,width:m[0],height:m[1],area:m[0]*m[1]};v.setLayout(b),_q(v,_,!1,0),b=v.getLayout(),lE(g,function(x,C){var D=(g[C+1]||v).getValue();x.setLayout(J({dataExtent:[D,D],borderWidth:0,upperHeight:0},b))})}var T=r.getData().tree.root;T.setLayout(Qye(o,p,f),!0),r.setLayoutInfo(o),bq(T,new qe(-o.x,-o.y,n,a),g,v,0)}};function _q(r,e,t,i){var n,a;if(!r.isRemoved()){var s=r.getLayout();n=s.width,a=s.height;var o=r.getModel(),l=o.get(yq),u=o.get(Gye)/2,c=Sq(o),h=Math.max(l,c),d=l-u,f=h-u;r.setLayout({borderWidth:l,upperHeight:h,upperLabelHeight:c},!0),n=Iv(n-2*d,0),a=Iv(a-d-f,0);var p=n*a,v=qye(r,o,p,e,t,i);if(v.length){var g={x:d,y:f,width:n,height:a},m=t_(n,a),y=1/0,_=[];_.area=0;for(var b=0,T=v.length;b=0;l--){var u=n[i==="asc"?s-l-1:l].getValue();u/t*eo[1]&&(o[1]=u)})),{sum:i,dataExtent:o}}function Kye(r,e,t){for(var i=0,n=1/0,a=0,s=void 0,o=r.length;ai&&(i=s));var l=r.area*r.area,u=e*e*t;return l?Iv(u*i/l,l/(u*n)):1/0}function Pk(r,e,t,i,n){var a=e===t.width?0:1,s=1-a,o=["x","y"],l=["width","height"],u=t[o[a]],c=e?r.area/e:0;(n||c>t[l[s]])&&(c=t[l[s]]);for(var h=0,d=r.length;hHP&&(u=HP),a=o}ui&&(i=e);var a=i%2?i+2:i+3;n=[];for(var s=0;s0&&(T[0]=-T[0],T[1]=-T[1]);var C=b[0]<0?-1:1;if(a.__position!=="start"&&a.__position!=="end"){var D=-Math.atan2(b[1],b[0]);h[0].8?"left":d[0]<-.8?"right":"center",v=d[1]>.8?"top":d[1]<-.8?"bottom":"middle";break;case"start":a.x=-d[0]*m+c[0],a.y=-d[1]*y+c[1],p=d[0]>.8?"right":d[0]<-.8?"left":"center",v=d[1]>.8?"bottom":d[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":a.x=m*C+c[0],a.y=c[1]+I,p=b[0]<0?"right":"left",a.originX=-m*C,a.originY=-I;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":a.x=x[0],a.y=x[1]+I,p="center",a.originY=-I;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":a.x=-m*C+h[0],a.y=h[1]+I,p=b[0]>=0?"right":"left",a.originX=m*C,a.originY=-I;break}a.scaleX=a.scaleY=s,a.setStyle({verticalAlign:a.__verticalAlign||v,align:a.__align||p})}},e}(Le),dE=function(){function r(e){this.group=new Le,this._LineCtor=e||fE}return r.prototype.updateData=function(e){var t=this;this._progressiveEls=null;var i=this,n=i.group,a=i._lineData;i._lineData=e,a||n.removeAll();var s=Nk(e);e.diff(a).add(function(o){t._doAdd(e,o,s)}).update(function(o,l){t._doUpdate(a,e,l,o,s)}).remove(function(o){n.remove(a.getItemGraphicEl(o))}).execute()},r.prototype.updateLayout=function(){var e=this._lineData;e&&e.eachItemGraphicEl(function(t,i){t.updateLayout(e,i)},this)},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=Nk(e),this._lineData=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t){this._progressiveEls=[];function i(o){!o.isGroup&&!g_e(o)&&(o.incremental=!0,o.ensureState("emphasis").hoverLayer=!0)}for(var n=e.start;n0}function Nk(r){var e=r.hostModel,t=e.getModel("emphasis");return{lineStyle:e.getModel("lineStyle").getLineStyle(),emphasisLineStyle:t.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:e.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:e.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:t.get("disabled"),blurScope:t.get("blurScope"),focus:t.get("focus"),labelStatesModels:Nr(e)}}function Bk(r){return isNaN(r[0])||isNaN(r[1])}function ES(r){return r&&!Bk(r[0])&&!Bk(r[1])}var IS=[],PS=[],MS=[],Yc=Ur,LS=Bu,Fk=Math.abs;function Uk(r,e,t){for(var i=r[0],n=r[1],a=r[2],s=1/0,o,l=t*t,u=.1,c=.1;c<=.9;c+=.1){IS[0]=Yc(i[0],n[0],a[0],c),IS[1]=Yc(i[1],n[1],a[1],c);var h=Fk(LS(IS,e)-l);h=0?o=o+u:o=o-u:p>=0?o=o-u:o=o+u}return o}function kS(r,e){var t=[],i=lv,n=[[],[],[]],a=[[],[]],s=[];e/=2,r.eachEdge(function(o,l){var u=o.getLayout(),c=o.getVisual("fromSymbol"),h=o.getVisual("toSymbol");u.__original||(u.__original=[ks(u[0]),ks(u[1])],u[2]&&u.__original.push(ks(u[2])));var d=u.__original;if(u[2]!=null){if(gi(n[0],d[0]),gi(n[1],d[2]),gi(n[2],d[1]),c&&c!=="none"){var f=fp(o.node1),p=Uk(n,d[0],f*e);i(n[0][0],n[1][0],n[2][0],p,t),n[0][0]=t[3],n[1][0]=t[4],i(n[0][1],n[1][1],n[2][1],p,t),n[0][1]=t[3],n[1][1]=t[4]}if(h&&h!=="none"){var f=fp(o.node2),p=Uk(n,d[1],f*e);i(n[0][0],n[1][0],n[2][0],p,t),n[1][0]=t[1],n[2][0]=t[2],i(n[0][1],n[1][1],n[2][1],p,t),n[1][1]=t[1],n[2][1]=t[2]}gi(u[0],n[0]),gi(u[1],n[2]),gi(u[2],n[1])}else{if(gi(a[0],d[0]),gi(a[1],d[1]),gu(s,a[1],a[0]),Ef(s,s),c&&c!=="none"){var f=fp(o.node1);bx(a[0],a[0],s,f*e)}if(h&&h!=="none"){var f=fp(o.node2);bx(a[1],a[1],s,-f*e)}gi(u[0],a[0]),gi(u[1],a[1])}})}function Vk(r){return r.type==="view"}var m_e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,i){var n=new ug,a=new dE,s=this.group;this._controller=new pg(i.getZr()),this._controllerHost={target:s},s.add(n.group),s.add(a.group),this._symbolDraw=n,this._lineDraw=a,this._firstRender=!0},e.prototype.render=function(t,i,n){var a=this,s=t.coordinateSystem;this._model=t;var o=this._symbolDraw,l=this._lineDraw,u=this.group;if(Vk(s)){var c={x:s.x,y:s.y,scaleX:s.scaleX,scaleY:s.scaleY};this._firstRender?u.attr(c):ct(u,c,t)}kS(t.getGraph(),hp(t));var h=t.getData();o.updateData(h);var d=t.getEdgeData();l.updateData(d),this._updateNodeAndLinkScale(),this._updateController(t,i,n),clearTimeout(this._layoutTimeout);var f=t.forceLayout,p=t.get(["force","layoutAnimation"]);f&&this._startForceLayoutIteration(f,p);var v=t.get("layout");h.graph.eachNode(function(_){var b=_.dataIndex,T=_.getGraphicEl(),x=_.getModel();if(T){T.off("drag").off("dragend");var C=x.get("draggable");C&&T.on("drag",function(I){switch(v){case"force":f.warmUp(),!a._layouting&&a._startForceLayoutIteration(f,p),f.setFixed(b),h.setItemLayout(b,[T.x,T.y]);break;case"circular":h.setItemLayout(b,[T.x,T.y]),_.setLayout({fixed:!0},!0),hE(t,"symbolSize",_,[I.offsetX,I.offsetY]),a.updateLayout(t);break;case"none":default:h.setItemLayout(b,[T.x,T.y]),cE(t.getGraph(),t),a.updateLayout(t);break}}).on("dragend",function(){f&&f.setUnfixed(b)}),T.setDraggable(C,!!x.get("cursor"));var D=x.get(["emphasis","focus"]);D==="adjacency"&&(ke(T).focus=_.getAdjacentDataIndices())}}),h.graph.eachEdge(function(_){var b=_.getGraphicEl(),T=_.getModel().get(["emphasis","focus"]);b&&T==="adjacency"&&(ke(b).focus={edge:[_.dataIndex],node:[_.node1.dataIndex,_.node2.dataIndex]})});var g=t.get("layout")==="circular"&&t.get(["circular","rotateLabel"]),m=h.getLayout("cx"),y=h.getLayout("cy");h.graph.eachNode(function(_){Cq(_,g,m,y)}),this._firstRender=!1},e.prototype.dispose=function(){this.remove(),this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype._startForceLayoutIteration=function(t,i){var n=this;(function a(){t.step(function(s){n.updateLayout(n._model),(n._layouting=!s)&&(i?n._layoutTimeout=setTimeout(a,16):a())})})()},e.prototype._updateController=function(t,i,n){var a=this,s=this._controller,o=this._controllerHost,l=this.group;if(s.setPointerChecker(function(u,c,h){var d=l.getBoundingRect();return d.applyTransform(l.transform),d.contain(c,h)&&!P1(u,n,t)}),!Vk(t.coordinateSystem)){s.disable();return}s.enable(t.get("roam")),o.zoomLimit=t.get("scaleLimit"),o.zoom=t.coordinateSystem.getZoom(),s.off("pan").off("zoom").on("pan",function(u){tE(o,u.dx,u.dy),n.dispatchAction({seriesId:t.id,type:"graphRoam",dx:u.dx,dy:u.dy})}).on("zoom",function(u){rE(o,u.scale,u.originX,u.originY),n.dispatchAction({seriesId:t.id,type:"graphRoam",zoom:u.scale,originX:u.originX,originY:u.originY}),a._updateNodeAndLinkScale(),kS(t.getGraph(),hp(t)),a._lineDraw.updateLayout(),n.updateLabelLayout()})},e.prototype._updateNodeAndLinkScale=function(){var t=this._model,i=t.getData(),n=hp(t);i.eachItemGraphicEl(function(a,s){a&&a.setSymbolScale(n)})},e.prototype.updateLayout=function(t){kS(t.getGraph(),hp(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},e.prototype.remove=function(){clearTimeout(this._layoutTimeout),this._layouting=!1,this._layoutTimeout=null,this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},e.type="graph",e}(Ct);function Kc(r){return"_EC_"+r}var y_e=function(){function r(e){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=e||!1}return r.prototype.isDirected=function(){return this._directed},r.prototype.addNode=function(e,t){e=e==null?""+t:""+e;var i=this._nodesMap;if(!i[Kc(e)]){var n=new iu(e,t);return n.hostGraph=this,this.nodes.push(n),i[Kc(e)]=n,n}},r.prototype.getNodeByIndex=function(e){var t=this.data.getRawIndex(e);return this.nodes[t]},r.prototype.getNodeById=function(e){return this._nodesMap[Kc(e)]},r.prototype.addEdge=function(e,t,i){var n=this._nodesMap,a=this._edgesMap;if(ut(e)&&(e=this.nodes[e]),ut(t)&&(t=this.nodes[t]),e instanceof iu||(e=n[Kc(e)]),t instanceof iu||(t=n[Kc(t)]),!(!e||!t)){var s=e.id+"-"+t.id,o=new Dq(e,t,i);return o.hostGraph=this,this._directed&&(e.outEdges.push(o),t.inEdges.push(o)),e.edges.push(o),e!==t&&t.edges.push(o),this.edges.push(o),a[s]=o,o}},r.prototype.getEdgeByIndex=function(e){var t=this.edgeData.getRawIndex(e);return this.edges[t]},r.prototype.getEdge=function(e,t){e instanceof iu&&(e=e.id),t instanceof iu&&(t=t.id);var i=this._edgesMap;return this._directed?i[e+"-"+t]:i[e+"-"+t]||i[t+"-"+e]},r.prototype.eachNode=function(e,t){for(var i=this.nodes,n=i.length,a=0;a=0&&e.call(t,i[a],a)},r.prototype.eachEdge=function(e,t){for(var i=this.edges,n=i.length,a=0;a=0&&i[a].node1.dataIndex>=0&&i[a].node2.dataIndex>=0&&e.call(t,i[a],a)},r.prototype.breadthFirstTraverse=function(e,t,i,n){if(t instanceof iu||(t=this._nodesMap[Kc(t)]),!!t){for(var a=i==="out"?"outEdges":i==="in"?"inEdges":"edges",s=0;s=0&&l.node2.dataIndex>=0});for(var a=0,s=n.length;a=0&&this[r][e].setItemVisual(this.dataIndex,t,i)},getVisual:function(t){return this[r][e].getItemVisual(this.dataIndex,t)},setLayout:function(t,i){this.dataIndex>=0&&this[r][e].setItemLayout(this.dataIndex,t,i)},getLayout:function(){return this[r][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[r][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[r][e].getRawIndex(this.dataIndex)}}}_r(iu,Eq("hostGraph","data"));_r(Dq,Eq("hostGraph","edgeData"));function Iq(r,e,t,i,n){for(var a=new y_e(i),s=0;s "+d)),u++)}var f=t.get("coordinateSystem"),p;if(f==="cartesian2d"||f==="polar")p=to(r,t);else{var v=ng.get(f),g=v?v.dimensions||[]:[];Xe(g,"value")<0&&g.concat(["value"]);var m=sg(r,{coordDimensions:g,encodeDefine:t.getEncode()}).dimensions;p=new wi(m,t),p.initData(r)}var y=new wi(["value"],t);return y.initData(l,o),n&&n(p,y),cq({mainData:p,struct:a,structAttr:"graph",datas:{node:p,edge:y},datasAttr:{node:"data",edge:"edgeData"}}),a.update(),a}var __e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments);var i=this;function n(){return i._categoriesData}this.legendVisualProvider=new dg(n,n),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeDefaultAndTheme=function(t){r.prototype.mergeDefaultAndTheme.apply(this,arguments),Ju(t,"edgeLabel",["show"])},e.prototype.getInitialData=function(t,i){var n=t.edges||t.links||[],a=t.data||t.nodes||[],s=this;if(a&&n){a_e(this);var o=Iq(a,n,this,!0,l);return R(o.edges,function(u){s_e(u.node1,u.node2,this,u.dataIndex)},this),o.data}function l(u,c){u.wrapMethod("getItemModel",function(p){var v=s._categoriesModels,g=p.getShallow("category"),m=v[g];return m&&(m.parentModel=p.parentModel,p.parentModel=m),p});var h=yt.prototype.getModel;function d(p,v){var g=h.call(this,p,v);return g.resolveParentPath=f,g}c.wrapMethod("getItemModel",function(p){return p.resolveParentPath=f,p.getModel=d,p});function f(p){if(p&&(p[0]==="label"||p[1]==="label")){var v=p.slice();return p[0]==="label"?v[0]="edgeLabel":p[1]==="label"&&(v[1]="edgeLabel"),v}return p}}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.getCategoriesData=function(){return this._categoriesData},e.prototype.formatTooltip=function(t,i,n){if(n==="edge"){var a=this.getData(),s=this.getDataParams(t,n),o=a.graph.getEdgeByIndex(t),l=a.getName(o.node1.dataIndex),u=a.getName(o.node2.dataIndex),c=[];return l!=null&&c.push(l),u!=null&&c.push(u),Br("nameValue",{name:c.join(" > "),value:s.value,noValue:s.value==null})}var h=JH({series:this,dataIndex:t,multipleSeries:i});return h},e.prototype._updateCategoriesData=function(){var t=oe(this.option.categories||[],function(n){return n.value!=null?n:J({value:0},n)}),i=new wi(["value"],this);i.initData(t),this._categoriesData=i,this._categoriesModels=i.mapArray(function(n){return i.getItemModel(n)})},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.isAnimationEnabled=function(){return r.prototype.isAnimationEnabled.call(this)&&!(this.get("layout")==="force"&&this.get(["force","layoutAnimation"]))},e.type="series.graph",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(Ot),b_e={type:"graphRoam",event:"graphRoam",update:"none"};function S_e(r){r.registerChartView(m_e),r.registerSeriesModel(__e),r.registerProcessor(e_e),r.registerVisual(t_e),r.registerVisual(r_e),r.registerLayout(o_e),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,u_e),r.registerLayout(h_e),r.registerCoordinateSystem("graphView",{dimensions:vg.dimensions,create:d_e}),r.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},lr),r.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},lr),r.registerAction(b_e,function(e,t,i){t.eachComponent({mainType:"series",query:e},function(n){var a=n.coordinateSystem,s=nE(a,e,void 0,i);n.setCenter&&n.setCenter(s.center),n.setZoom&&n.setZoom(s.zoom)})})}var T_e=function(){function r(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0}return r}(),x_e=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i.type="pointer",i}return e.prototype.getDefaultShape=function(){return new T_e},e.prototype.buildPath=function(t,i){var n=Math.cos,a=Math.sin,s=i.r,o=i.width,l=i.angle,u=i.x-n(l)*o*(o>=s/3?1:2),c=i.y-a(l)*o*(o>=s/3?1:2);l=i.angle-Math.PI/2,t.moveTo(u,c),t.lineTo(i.x+n(l)*o,i.y+a(l)*o),t.lineTo(i.x+n(i.angle)*s,i.y+a(i.angle)*s),t.lineTo(i.x-n(l)*o,i.y-a(l)*o),t.lineTo(u,c)},e}(Qe);function w_e(r,e){var t=r.get("center"),i=e.getWidth(),n=e.getHeight(),a=Math.min(i,n),s=ce(t[0],e.getWidth()),o=ce(t[1],e.getHeight()),l=ce(r.get("radius"),a/2);return{cx:s,cy:o,r:l}}function $m(r,e){var t=r==null?"":r+"";return e&&(pe(e)?t=e.replace("{value}",t):we(e)&&(t=e(r))),t}var C_e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){this.group.removeAll();var a=t.get(["axisLine","lineStyle","color"]),s=w_e(t,n);this._renderMain(t,i,n,a,s),this._data=t.getData()},e.prototype.dispose=function(){},e.prototype._renderMain=function(t,i,n,a,s){var o=this.group,l=t.get("clockwise"),u=-t.get("startAngle")/180*Math.PI,c=-t.get("endAngle")/180*Math.PI,h=t.getModel("axisLine"),d=h.get("roundCap"),f=d?Ky:Ei,p=h.get("show"),v=h.getModel("lineStyle"),g=v.get("width"),m=[u,c];aD(m,!l),u=m[0],c=m[1];for(var y=c-u,_=u,b=[],T=0;p&&T=I&&(M===0?0:a[M-1][0])Math.PI/2&&(ue+=Math.PI)):he==="tangential"?ue=-D-Math.PI/2:ut(he)&&(ue=he*Math.PI/180),ue===0?h.add(new lt({style:kt(_,{text:Z,x:Q,y:se,verticalAlign:F<-.8?"top":F>.8?"bottom":"middle",align:B<-.4?"left":B>.4?"right":"center"},{inheritColor:te}),silent:!0})):h.add(new lt({style:kt(_,{text:Z,x:Q,y:se,verticalAlign:"middle",align:"center"},{inheritColor:te}),silent:!0,originX:Q,originY:se,rotation:ue}))}if(y.get("show")&&U!==b){var $=y.get("distance");$=$?$+c:c;for(var Ie=0;Ie<=T;Ie++){B=Math.cos(D),F=Math.sin(D);var Oe=new kr({shape:{x1:B*(p-$)+d,y1:F*(p-$)+f,x2:B*(p-C-$)+d,y2:F*(p-C-$)+f},silent:!0,style:N});N.stroke==="auto"&&Oe.setStyle({stroke:a((U+Ie/T)/b)}),h.add(Oe),D+=M}D-=M}else D+=I}},e.prototype._renderPointer=function(t,i,n,a,s,o,l,u,c){var h=this.group,d=this._data,f=this._progressEls,p=[],v=t.get(["pointer","show"]),g=t.getModel("progress"),m=g.get("show"),y=t.getData(),_=y.mapDimension("value"),b=+t.get("min"),T=+t.get("max"),x=[b,T],C=[o,l];function D(M,L){var N=y.getItemModel(M),O=N.getModel("pointer"),B=ce(O.get("width"),s.r),F=ce(O.get("length"),s.r),U=t.get(["pointer","icon"]),$=O.get("offsetCenter"),q=ce($[0],s.r),Z=ce($[1],s.r),te=O.get("keepAspect"),Q;return U?Q=yr(U,q-B/2,Z-F,B,F,null,te):Q=new x_e({shape:{angle:-Math.PI/2,width:B,r:F,x:q,y:Z}}),Q.rotation=-(L+Math.PI/2),Q.x=s.cx,Q.y=s.cy,Q}function I(M,L){var N=g.get("roundCap"),O=N?Ky:Ei,B=g.get("overlap"),F=B?g.get("width"):c/y.count(),U=B?s.r-F:s.r-(M+1)*F,$=B?s.r:s.r-M*F,q=new O({shape:{startAngle:o,endAngle:L,cx:s.cx,cy:s.cy,clockwise:u,r0:U,r:$}});return B&&(q.z2=T-y.get(_,M)%T),q}(m||v)&&(y.diff(d).add(function(M){var L=y.get(_,M);if(v){var N=D(M,o);Vt(N,{rotation:-((isNaN(+L)?C[0]:bt(L,x,C,!0))+Math.PI/2)},t),h.add(N),y.setItemGraphicEl(M,N)}if(m){var O=I(M,o),B=g.get("clip");Vt(O,{shape:{endAngle:bt(L,x,C,B)}},t),h.add(O),jx(t.seriesIndex,y.dataType,M,O),p[M]=O}}).update(function(M,L){var N=y.get(_,M);if(v){var O=d.getItemGraphicEl(L),B=O?O.rotation:o,F=D(M,B);F.rotation=B,ct(F,{rotation:-((isNaN(+N)?C[0]:bt(N,x,C,!0))+Math.PI/2)},t),h.add(F),y.setItemGraphicEl(M,F)}if(m){var U=f[L],$=U?U.shape.endAngle:o,q=I(M,$),Z=g.get("clip");ct(q,{shape:{endAngle:bt(N,x,C,Z)}},t),h.add(q),jx(t.seriesIndex,y.dataType,M,q),p[M]=q}}).execute(),y.each(function(M){var L=y.getItemModel(M),N=L.getModel("emphasis"),O=N.get("focus"),B=N.get("blurScope"),F=N.get("disabled");if(v){var U=y.getItemGraphicEl(M),$=y.getItemVisual(M,"style"),q=$.fill;if(U instanceof Wr){var Z=U.style;U.useStyle(J({image:Z.image,x:Z.x,y:Z.y,width:Z.width,height:Z.height},$))}else U.useStyle($),U.type!=="pointer"&&U.setColor(q);U.setStyle(L.getModel(["pointer","itemStyle"]).getItemStyle()),U.style.fill==="auto"&&U.setStyle("fill",a(bt(y.get(_,M),x,[0,1],!0))),U.z2EmphasisLift=0,Qr(U,L),Yt(U,O,B,F)}if(m){var te=p[M];te.useStyle(y.getItemVisual(M,"style")),te.setStyle(L.getModel(["progress","itemStyle"]).getItemStyle()),te.z2EmphasisLift=0,Qr(te,L),Yt(te,O,B,F)}}),this._progressEls=p)},e.prototype._renderAnchor=function(t,i){var n=t.getModel("anchor"),a=n.get("show");if(a){var s=n.get("size"),o=n.get("icon"),l=n.get("offsetCenter"),u=n.get("keepAspect"),c=yr(o,i.cx-s/2+ce(l[0],i.r),i.cy-s/2+ce(l[1],i.r),s,s,null,u);c.z2=n.get("showAbove")?1:0,c.setStyle(n.getModel("itemStyle").getItemStyle()),this.group.add(c)}},e.prototype._renderTitleAndDetail=function(t,i,n,a,s){var o=this,l=t.getData(),u=l.mapDimension("value"),c=+t.get("min"),h=+t.get("max"),d=new Le,f=[],p=[],v=t.isAnimationEnabled(),g=t.get(["pointer","showAbove"]);l.diff(this._data).add(function(m){f[m]=new lt({silent:!0}),p[m]=new lt({silent:!0})}).update(function(m,y){f[m]=o._titleEls[y],p[m]=o._detailEls[y]}).execute(),l.each(function(m){var y=l.getItemModel(m),_=l.get(u,m),b=new Le,T=a(bt(_,[c,h],[0,1],!0)),x=y.getModel("title");if(x.get("show")){var C=x.get("offsetCenter"),D=s.cx+ce(C[0],s.r),I=s.cy+ce(C[1],s.r),M=f[m];M.attr({z2:g?0:2,style:kt(x,{x:D,y:I,text:l.getName(m),align:"center",verticalAlign:"middle"},{inheritColor:T})}),b.add(M)}var L=y.getModel("detail");if(L.get("show")){var N=L.get("offsetCenter"),O=s.cx+ce(N[0],s.r),B=s.cy+ce(N[1],s.r),F=ce(L.get("width"),s.r),U=ce(L.get("height"),s.r),$=t.get(["progress","show"])?l.getItemVisual(m,"style").fill:T,M=p[m],q=L.get("formatter");M.attr({z2:g?0:2,style:kt(L,{x:O,y:B,text:$m(_,q),width:isNaN(F)?null:F,height:isNaN(U)?null:U,align:"center",verticalAlign:"middle"},{inheritColor:$})}),iH(M,{normal:L},_,function(te){return $m(te,q)}),v&&nH(M,m,l,t,{getFormattedLabel:function(te,Q,se,he,ue,Ie){return $m(Ie?Ie.interpolatedValue:_,q)}}),b.add(M)}d.add(b)}),this.group.add(d),this._titleEls=f,this._detailEls=p},e.type="gauge",e}(Ct),A_e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="itemStyle",t}return e.prototype.getInitialData=function(t,i){return Hf(this,["value"])},e.type="series.gauge",e.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},e}(Ot);function D_e(r){r.registerChartView(C_e),r.registerSeriesModel(A_e)}var E_e=["itemStyle","opacity"],I_e=function(r){j(e,r);function e(t,i){var n=r.call(this)||this,a=n,s=new Pi,o=new lt;return a.setTextContent(o),n.setTextGuideLine(s),n.updateData(t,i,!0),n}return e.prototype.updateData=function(t,i,n){var a=this,s=t.hostModel,o=t.getItemModel(i),l=t.getItemLayout(i),u=o.getModel("emphasis"),c=o.get(E_e);c=c??1,n||_a(a),a.useStyle(t.getItemVisual(i,"style")),a.style.lineJoin="round",n?(a.setShape({points:l.points}),a.style.opacity=0,Vt(a,{style:{opacity:c}},s,i)):ct(a,{style:{opacity:c},shape:{points:l.points}},s,i),Qr(a,o),this._updateLabel(t,i),Yt(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,i){var n=this,a=this.getTextGuideLine(),s=n.getTextContent(),o=t.hostModel,l=t.getItemModel(i),u=t.getItemLayout(i),c=u.label,h=t.getItemVisual(i,"style"),d=h.fill;Jr(s,Nr(l),{labelFetcher:t.hostModel,labelDataIndex:i,defaultOpacity:h.opacity,defaultText:t.getName(i)},{normal:{align:c.textAlign,verticalAlign:c.verticalAlign}}),n.setTextConfig({local:!0,inside:!!c.inside,insideStroke:d,outsideFill:d});var f=c.linePoints;a.setShape({points:f}),n.textGuideLineConfig={anchor:f?new He(f[0][0],f[0][1]):null},ct(s,{style:{x:c.x,y:c.y}},o,i),s.attr({rotation:c.rotation,originX:c.x,originY:c.y,z2:10}),$D(n,WD(l),{stroke:d})},e}(Ii),P_e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,i,n){var a=t.getData(),s=this._data,o=this.group;a.diff(s).add(function(l){var u=new I_e(a,l);a.setItemGraphicEl(l,u),o.add(u)}).update(function(l,u){var c=s.getItemGraphicEl(u);c.updateData(a,l),o.add(c),a.setItemGraphicEl(l,c)}).remove(function(l){var u=s.getItemGraphicEl(l);vv(u,t,l)}).execute(),this._data=a},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.prototype.dispose=function(){},e.type="funnel",e}(Ct),M_e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new dg(ge(this.getData,this),ge(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.getInitialData=function(t,i){return Hf(this,{coordDimensions:["value"],encodeDefaulter:Ue(TD,this)})},e.prototype._defaultLabelLine=function(t){Ju(t,"labelLine",["show"]);var i=t.labelLine,n=t.emphasis.labelLine;i.show=i.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.prototype.getDataParams=function(t){var i=this.getData(),n=r.prototype.getDataParams.call(this,t),a=i.mapDimension("value"),s=i.getSum(a);return n.percent=s?+(i.get(a,t)/s*100).toFixed(2):0,n.$vars.push("percent"),n},e.type="series.funnel",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(Ot);function L_e(r,e){return Ar(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function k_e(r,e){for(var t=r.mapDimension("value"),i=r.mapArray(t,function(l){return l}),n=[],a=e==="ascending",s=0,o=r.count();sY_e)return;var n=this._model.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]);n.behavior!=="none"&&this._dispatchExpand({axisExpandWindow:n.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(r){if(!(this._mouseDownPoint||!OS(this,"mousemove"))){var e=this._model,t=e.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]),i=t.behavior;i==="jump"&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand(i==="none"?null:{axisExpandWindow:t.axisExpandWindow,animation:i==="jump"?null:{duration:0}})}}};function OS(r,e){var t=r._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}var Q_e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){r.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var i=this.option;t&&We(i,t,!0),this._initDimensions()},e.prototype.contains=function(t,i){var n=t.get("parallelIndex");return n!=null&&i.getComponent("parallel",n)===this},e.prototype.setAxisExpand=function(t){R(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(i){t.hasOwnProperty(i)&&(this.option[i]=t[i])},this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],i=this.parallelAxisIndex=[],n=Tt(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(a){return(a.get("parallelIndex")||0)===this.componentIndex},this);R(n,function(a){t.push("dim"+a.get("dim")),i.push(a.componentIndex)})},e.type="parallel",e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e}(tt),J_e=function(r){j(e,r);function e(t,i,n,a,s){var o=r.call(this,t,i,n)||this;return o.type=a||"value",o.axisIndex=s,o}return e.prototype.isHorizontal=function(){return this.coordinateSystem.getModel().get("layout")!=="horizontal"},e}(xa);function vc(r,e,t,i,n,a){r=r||0;var s=t[1]-t[0];if(n!=null&&(n=Zc(n,[0,s])),a!=null&&(a=Math.max(a,n??0)),i==="all"){var o=Math.abs(e[1]-e[0]);o=Zc(o,[0,s]),n=a=Zc(o,[n,a]),i=0}e[0]=Zc(e[0],t),e[1]=Zc(e[1],t);var l=NS(e,i);e[i]+=r;var u=n||0,c=t.slice();l.sign<0?c[0]+=u:c[1]-=u,e[i]=Zc(e[i],c);var h;return h=NS(e,i),n!=null&&(h.sign!==l.sign||h.spana&&(e[1-i]=e[i]+h.sign*a),e}function NS(r,e){var t=r[e]-r[1-e];return{span:Math.abs(t),sign:t>0?-1:t<0?1:e?-1:1}}function Zc(r,e){return Math.min(e[1]!=null?e[1]:1/0,Math.max(e[0]!=null?e[0]:-1/0,r))}var BS=R,Mq=Math.min,Lq=Math.max,Hk=Math.floor,e1e=Math.ceil,$k=er,t1e=Math.PI,r1e=function(){function r(e,t,i){this.type="parallel",this._axesMap=be(),this._axesLayout={},this.dimensions=e.dimensions,this._model=e,this._init(e,t,i)}return r.prototype._init=function(e,t,i){var n=e.dimensions,a=e.parallelAxisIndex;BS(n,function(s,o){var l=a[o],u=t.getComponent("parallelAxis",l),c=this._axesMap.set(s,new J_e(s,E1(u),[0,0],u.get("type"),l)),h=c.type==="category";c.onBand=h&&u.get("boundaryGap"),c.inverse=u.get("inverse"),u.axis=c,c.model=u,c.coordinateSystem=u.coordinateSystem=this},this)},r.prototype.update=function(e,t){this._updateAxesFromSeries(this._model,e)},r.prototype.containPoint=function(e){var t=this._makeLayoutInfo(),i=t.axisBase,n=t.layoutBase,a=t.pixelDimIndex,s=e[1-a],o=e[a];return s>=i&&s<=i+t.axisLength&&o>=n&&o<=n+t.layoutLength},r.prototype.getModel=function(){return this._model},r.prototype._updateAxesFromSeries=function(e,t){t.eachSeries(function(i){if(e.contains(i,t)){var n=i.getData();BS(this.dimensions,function(a){var s=this._axesMap.get(a);s.scale.unionExtentFromData(n,n.mapDimension(a)),hf(s.scale,s.model)},this)}},this)},r.prototype.resize=function(e,t){this._rect=Ar(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),this._layoutAxes()},r.prototype.getRect=function(){return this._rect},r.prototype._makeLayoutInfo=function(){var e=this._model,t=this._rect,i=["x","y"],n=["width","height"],a=e.get("layout"),s=a==="horizontal"?0:1,o=t[n[s]],l=[0,o],u=this.dimensions.length,c=Wm(e.get("axisExpandWidth"),l),h=Wm(e.get("axisExpandCount")||0,[0,u]),d=e.get("axisExpandable")&&u>3&&u>h&&h>1&&c>0&&o>0,f=e.get("axisExpandWindow"),p;if(f)p=Wm(f[1]-f[0],l),f[1]=f[0]+p;else{p=Wm(c*(h-1),l);var v=e.get("axisExpandCenter")||Hk(u/2);f=[c*v-p/2],f[1]=f[0]+p}var g=(o-p)/(u-h);g<3&&(g=0);var m=[Hk($k(f[0]/c,1))+1,e1e($k(f[1]/c,1))-1],y=g/c*f[0];return{layout:a,pixelDimIndex:s,layoutBase:t[i[s]],layoutLength:o,axisBase:t[i[1-s]],axisLength:t[n[1-s]],axisExpandable:d,axisExpandWidth:c,axisCollapseWidth:g,axisExpandWindow:f,axisCount:u,winInnerIndices:m,axisExpandWindow0Pos:y}},r.prototype._layoutAxes=function(){var e=this._rect,t=this._axesMap,i=this.dimensions,n=this._makeLayoutInfo(),a=n.layout;t.each(function(s){var o=[0,n.axisLength],l=s.inverse?1:0;s.setExtent(o[l],o[1-l])}),BS(i,function(s,o){var l=(n.axisExpandable?n1e:i1e)(o,n),u={horizontal:{x:l.position,y:n.axisLength},vertical:{x:0,y:l.position}},c={horizontal:t1e/2,vertical:0},h=[u[a].x+e.x,u[a].y+e.y],d=c[a],f=vn();uc(f,f,d),ss(f,f,h),this._axesLayout[s]={position:h,rotation:d,transform:f,axisNameAvailableWidth:l.axisNameAvailableWidth,axisLabelShow:l.axisLabelShow,nameTruncateMaxWidth:l.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},r.prototype.getAxis=function(e){return this._axesMap.get(e)},r.prototype.dataToPoint=function(e,t){return this.axisCoordToPoint(this._axesMap.get(t).dataToCoord(e),t)},r.prototype.eachActiveState=function(e,t,i,n){i==null&&(i=0),n==null&&(n=e.count());var a=this._axesMap,s=this.dimensions,o=[],l=[];R(s,function(g){o.push(e.mapDimension(g)),l.push(a.get(g).model)});for(var u=this.hasAxisBrushed(),c=i;ca*(1-h[0])?(u="jump",l=o-a*(1-h[2])):(l=o-a*h[1])>=0&&(l=o-a*(1-h[1]))<=0&&(l=0),l*=t.axisExpandWidth/c,l?vc(l,n,s,"all"):u="none";else{var f=n[1]-n[0],p=s[1]*o/f;n=[Lq(0,p-f/2)],n[1]=Mq(s[1],n[0]+f),n[0]=n[1]-f}return{axisExpandWindow:n,behavior:u}},r}();function Wm(r,e){return Mq(Lq(r,e[0]),e[1])}function i1e(r,e){var t=e.layoutLength/(e.axisCount-1);return{position:t*r,axisNameAvailableWidth:t,axisLabelShow:!0}}function n1e(r,e){var t=e.layoutLength,i=e.axisExpandWidth,n=e.axisCount,a=e.axisCollapseWidth,s=e.winInnerIndices,o,l=a,u=!1,c;return r=0;n--)Gn(i[n])},e.prototype.getActiveState=function(t){var i=this.activeIntervals;if(!i.length)return"normal";if(t==null||isNaN(+t))return"inactive";if(i.length===1){var n=i[0];if(n[0]<=t&&t<=n[1])return"active"}else for(var a=0,s=i.length;au1e}function Fq(r){var e=r.length-1;return e<0&&(e=0),[r[0],r[e]]}function Uq(r,e,t,i){var n=new Le;return n.add(new st({name:"main",style:yE(t),silent:!0,draggable:!0,cursor:"move",drift:Ue(jk,r,e,n,["n","s","w","e"]),ondragend:Ue(ac,e,{isEnd:!0})})),R(i,function(a){n.add(new st({name:a.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:Ue(jk,r,e,n,a),ondragend:Ue(ac,e,{isEnd:!0})}))}),n}function Vq(r,e,t,i){var n=i.brushStyle.lineWidth||0,a=pf(n,c1e),s=t[0][0],o=t[1][0],l=s-n/2,u=o-n/2,c=t[0][1],h=t[1][1],d=c-a+n/2,f=h-a+n/2,p=c-s,v=h-o,g=p+n,m=v+n;ys(r,e,"main",s,o,p,v),i.transformable&&(ys(r,e,"w",l,u,a,m),ys(r,e,"e",d,u,a,m),ys(r,e,"n",l,u,g,a),ys(r,e,"s",l,f,g,a),ys(r,e,"nw",l,u,a,a),ys(r,e,"ne",d,u,a,a),ys(r,e,"sw",l,f,a,a),ys(r,e,"se",d,f,a,a))}function Uw(r,e){var t=e.__brushOption,i=t.transformable,n=e.childAt(0);n.useStyle(yE(t)),n.attr({silent:!i,cursor:i?"move":"default"}),R([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(a){var s=e.childOfName(a.join("")),o=a.length===1?Vw(r,a[0]):g1e(r,a);s&&s.attr({silent:!i,invisible:!i,cursor:i?f1e[o]+"-resize":null})})}function ys(r,e,t,i,n,a,s){var o=e.childOfName(t);o&&o.setShape(y1e(_E(r,e,[[i,n],[i+a,n+s]])))}function yE(r){return Ce({strokeNoScale:!0},r.brushStyle)}function zq(r,e,t,i){var n=[Mv(r,t),Mv(e,i)],a=[pf(r,t),pf(e,i)];return[[n[0],a[0]],[n[1],a[1]]]}function v1e(r){return Gu(r.group)}function Vw(r,e){var t={w:"left",e:"right",n:"top",s:"bottom"},i={left:"w",right:"e",top:"n",bottom:"s"},n=f1(t[e],v1e(r));return i[n]}function g1e(r,e){var t=[Vw(r,e[0]),Vw(r,e[1])];return(t[0]==="e"||t[0]==="w")&&t.reverse(),t.join("")}function jk(r,e,t,i,n,a){var s=t.__brushOption,o=r.toRectRange(s.range),l=Gq(e,n,a);R(i,function(u){var c=h1e[u];o[c[0]][c[1]]+=l[c[0]]}),s.range=r.fromRectRange(zq(o[0][0],o[1][0],o[0][1],o[1][1])),vE(e,t),ac(e,{isEnd:!1})}function m1e(r,e,t,i){var n=e.__brushOption.range,a=Gq(r,t,i);R(n,function(s){s[0]+=a[0],s[1]+=a[1]}),vE(r,e),ac(r,{isEnd:!1})}function Gq(r,e,t){var i=r.group,n=i.transformCoordToLocal(e,t),a=i.transformCoordToLocal(0,0);return[n[0]-a[0],n[1]-a[1]]}function _E(r,e,t){var i=Bq(r,e);return i&&i!==nc?i.clipPath(t,r._transform):Ee(t)}function y1e(r){var e=Mv(r[0][0],r[1][0]),t=Mv(r[0][1],r[1][1]),i=pf(r[0][0],r[1][0]),n=pf(r[0][1],r[1][1]);return{x:e,y:t,width:i-e,height:n-t}}function _1e(r,e,t){if(!(!r._brushType||S1e(r,e.offsetX,e.offsetY))){var i=r._zr,n=r._covers,a=mE(r,e,t);if(!r._dragging)for(var s=0;si.getWidth()||t<0||t>i.getHeight()}var R1={lineX:Kk(0),lineY:Kk(1),rect:{createCover:function(r,e){function t(i){return i}return Uq({toRectRange:t,fromRectRange:t},r,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(r){var e=Fq(r);return zq(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(r,e,t,i){Vq(r,e,t,i)},updateCommon:Uw,contain:Gw},polygon:{createCover:function(r,e){var t=new Le;return t.add(new Pi({name:"main",style:yE(e),silent:!0})),t},getCreatingRange:function(r){return r},endCreating:function(r,e){e.remove(e.childAt(0)),e.add(new Ii({name:"main",draggable:!0,drift:Ue(m1e,r,e),ondragend:Ue(ac,r,{isEnd:!0})}))},updateCoverShape:function(r,e,t,i){e.childAt(0).setShape({points:_E(r,e,t)})},updateCommon:Uw,contain:Gw}};function Kk(r){return{createCover:function(e,t){return Uq({toRectRange:function(i){var n=[i,[0,100]];return r&&n.reverse(),n},fromRectRange:function(i){return i[r]}},e,t,[[["w"],["e"]],[["n"],["s"]]][r])},getCreatingRange:function(e){var t=Fq(e),i=Mv(t[0][r],t[1][r]),n=pf(t[0][r],t[1][r]);return[i,n]},updateCoverShape:function(e,t,i,n){var a,s=Bq(e,t);if(s!==nc&&s.getLinearBrushOtherExtent)a=s.getLinearBrushOtherExtent(r);else{var o=e._zr;a=[0,[o.getWidth(),o.getHeight()][1-r]]}var l=[i,a];r&&l.reverse(),Vq(e,t,l,n)},updateCommon:Uw,contain:Gw}}function $q(r){return r=bE(r),function(e){return eH(e,r)}}function Wq(r,e){return r=bE(r),function(t){var i=e??t,n=i?r.width:r.height,a=i?r.x:r.y;return[a,a+(n||0)]}}function qq(r,e,t){var i=bE(r);return function(n,a){return i.contain(a[0],a[1])&&!P1(n,e,t)}}function bE(r){return qe.create(r)}var T1e=["axisLine","axisTickLabel","axisName"],x1e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,i){r.prototype.init.apply(this,arguments),(this._brushController=new pE(i.getZr())).on("brush",ge(this._onBrush,this))},e.prototype.render=function(t,i,n,a){if(!w1e(t,i,a)){this.axisModel=t,this.api=n,this.group.removeAll();var s=this._axisGroup;if(this._axisGroup=new Le,this.group.add(this._axisGroup),!!t.get("show")){var o=A1e(t,i),l=o.coordinateSystem,u=t.getAreaSelectStyle(),c=u.width,h=t.axis.dim,d=l.getAxisLayout(h),f=J({strokeContainThreshold:c},d),p=new Ci(t,f);R(T1e,p.add,p),this._axisGroup.add(p.getGroup()),this._refreshBrushController(f,u,t,o,c,n),rg(s,this._axisGroup,t)}}},e.prototype._refreshBrushController=function(t,i,n,a,s,o){var l=n.axis.getExtent(),u=l[1]-l[0],c=Math.min(30,Math.abs(u)*.1),h=qe.create({x:l[0],y:-s/2,width:u,height:s});h.x-=c,h.width+=2*c,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:$q(h),isTargetByCursor:qq(h,o,a),getLinearBrushOtherExtent:Wq(h,0)}]).enableBrush({brushType:"lineX",brushStyle:i,removeOnClick:!0}).updateCovers(C1e(n))},e.prototype._onBrush=function(t){var i=t.areas,n=this.axisModel,a=n.axis,s=oe(i,function(o){return[a.coordToData(o.range[0],!0),a.coordToData(o.range[1],!0)]});(!n.option.realtime===t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:n.id,intervals:s})},e.prototype.dispose=function(){this._brushController.dispose()},e.type="parallelAxis",e}($t);function w1e(r,e,t){return t&&t.type==="axisAreaSelect"&&e.findComponents({mainType:"parallelAxis",query:t})[0]===r}function C1e(r){var e=r.axis;return oe(r.activeIntervals,function(t){return{brushType:"lineX",panelId:"pl",range:[e.dataToCoord(t[0],!0),e.dataToCoord(t[1],!0)]}})}function A1e(r,e){return e.getComponent("parallel",r.get("parallelIndex"))}var D1e={type:"axisAreaSelect",event:"axisAreaSelected"};function E1e(r){r.registerAction(D1e,function(e,t){t.eachComponent({mainType:"parallelAxis",query:e},function(i){i.axis.model.setActiveIntervals(e.intervals)})}),r.registerAction("parallelAxisExpand",function(e,t){t.eachComponent({mainType:"parallel",query:e},function(i){i.setAxisExpand(e)})})}var I1e={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function jq(r){r.registerComponentView(K_e),r.registerComponentModel(Q_e),r.registerCoordinateSystem("parallel",s1e),r.registerPreprocessor(q_e),r.registerComponentModel(Bw),r.registerComponentView(x1e),df(r,"parallel",Bw,I1e),E1e(r)}function P1e(r){Ze(jq),r.registerChartView(F_e),r.registerSeriesModel(z_e),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,W_e)}var M1e=function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0}return r}(),L1e=function(r){j(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new M1e},e.prototype.buildPath=function(t,i){var n=i.extent;t.moveTo(i.x1,i.y1),t.bezierCurveTo(i.cpx1,i.cpy1,i.cpx2,i.cpy2,i.x2,i.y2),i.orient==="vertical"?(t.lineTo(i.x2+n,i.y2),t.bezierCurveTo(i.cpx2+n,i.cpy2,i.cpx1+n,i.cpy1,i.x1+n,i.y1)):(t.lineTo(i.x2,i.y2+n),t.bezierCurveTo(i.cpx2,i.cpy2+n,i.cpx1,i.cpy1+n,i.x1,i.y1+n)),t.closePath()},e.prototype.highlight=function(){qs(this)},e.prototype.downplay=function(){js(this)},e}(Qe),k1e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._focusAdjacencyDisabled=!1,t}return e.prototype.render=function(t,i,n){var a=this,s=t.getGraph(),o=this.group,l=t.layoutInfo,u=l.width,c=l.height,h=t.getData(),d=t.getData("edge"),f=t.get("orient");this._model=t,o.removeAll(),o.x=l.x,o.y=l.y,s.eachEdge(function(p){var v=new L1e,g=ke(v);g.dataIndex=p.dataIndex,g.seriesIndex=t.seriesIndex,g.dataType="edge";var m=p.getModel(),y=m.getModel("lineStyle"),_=y.get("curveness"),b=p.node1.getLayout(),T=p.node1.getModel(),x=T.get("localX"),C=T.get("localY"),D=p.node2.getLayout(),I=p.node2.getModel(),M=I.get("localX"),L=I.get("localY"),N=p.getLayout(),O,B,F,U,$,q,Z,te;v.shape.extent=Math.max(1,N.dy),v.shape.orient=f,f==="vertical"?(O=(x!=null?x*u:b.x)+N.sy,B=(C!=null?C*c:b.y)+b.dy,F=(M!=null?M*u:D.x)+N.ty,U=L!=null?L*c:D.y,$=O,q=B*(1-_)+U*_,Z=F,te=B*_+U*(1-_)):(O=(x!=null?x*u:b.x)+b.dx,B=(C!=null?C*c:b.y)+N.sy,F=M!=null?M*u:D.x,U=(L!=null?L*c:D.y)+N.ty,$=O*(1-_)+F*_,q=B,Z=O*_+F*(1-_),te=U),v.setShape({x1:O,y1:B,x2:F,y2:U,cpx1:$,cpy1:q,cpx2:Z,cpy2:te}),v.useStyle(y.getItemStyle()),Zk(v.style,f,p);var Q=""+m.get("value"),se=Nr(m,"edgeLabel");Jr(v,se,{labelFetcher:{getFormattedLabel:function(Ie,Oe,Fe,me,ze,Pe){return t.getFormattedLabel(Ie,Oe,"edge",me,Qa(ze,se.normal&&se.normal.get("formatter"),Q),Pe)}},labelDataIndex:p.dataIndex,defaultText:Q}),v.setTextConfig({position:"inside"});var he=m.getModel("emphasis");Qr(v,m,"lineStyle",function(Ie){var Oe=Ie.getItemStyle();return Zk(Oe,f,p),Oe}),o.add(v),d.setItemGraphicEl(p.dataIndex,v);var ue=he.get("focus");Yt(v,ue==="adjacency"?p.getAdjacentDataIndices():ue==="trajectory"?p.getTrajectoryDataIndices():ue,he.get("blurScope"),he.get("disabled"))}),s.eachNode(function(p){var v=p.getLayout(),g=p.getModel(),m=g.get("localX"),y=g.get("localY"),_=g.getModel("emphasis"),b=g.get(["itemStyle","borderRadius"])||0,T=new st({shape:{x:m!=null?m*u:v.x,y:y!=null?y*c:v.y,width:v.dx,height:v.dy,r:b},style:g.getModel("itemStyle").getItemStyle(),z2:10});Jr(T,Nr(g),{labelFetcher:{getFormattedLabel:function(C,D){return t.getFormattedLabel(C,D,"node")}},labelDataIndex:p.dataIndex,defaultText:p.id}),T.disableLabelAnimation=!0,T.setStyle("fill",p.getVisual("color")),T.setStyle("decal",p.getVisual("style").decal),Qr(T,g),o.add(T),h.setItemGraphicEl(p.dataIndex,T),ke(T).dataType="node";var x=_.get("focus");Yt(T,x==="adjacency"?p.getAdjacentDataIndices():x==="trajectory"?p.getTrajectoryDataIndices():x,_.get("blurScope"),_.get("disabled"))}),h.eachItemGraphicEl(function(p,v){var g=h.getItemModel(v);g.get("draggable")&&(p.drift=function(m,y){a._focusAdjacencyDisabled=!0,this.shape.x+=m,this.shape.y+=y,this.dirty(),n.dispatchAction({type:"dragNode",seriesId:t.id,dataIndex:h.getRawIndex(v),localX:this.shape.x/u,localY:this.shape.y/c})},p.ondragend=function(){a._focusAdjacencyDisabled=!1},p.draggable=!0,p.cursor="move")}),!this._data&&t.isAnimationEnabled()&&o.setClipPath(R1e(o.getBoundingRect(),t,function(){o.removeClipPath()})),this._data=t.getData()},e.prototype.dispose=function(){},e.type="sankey",e}(Ct);function Zk(r,e,t){switch(r.fill){case"source":r.fill=t.node1.getVisual("color"),r.decal=t.node1.getVisual("style").decal;break;case"target":r.fill=t.node2.getVisual("color"),r.decal=t.node2.getVisual("style").decal;break;case"gradient":var i=t.node1.getVisual("color"),n=t.node2.getVisual("color");pe(i)&&pe(n)&&(r.fill=new tg(0,0,+(e==="horizontal"),+(e==="vertical"),[{color:i,offset:0},{color:n,offset:1}]))}}function R1e(r,e,t){var i=new st({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Vt(i,{shape:{width:r.width+20}},e,t),i}var O1e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,i){var n=t.edges||t.links,a=t.data||t.nodes,s=t.levels;this.levelModels=[];for(var o=this.levelModels,l=0;l=0&&(o[s[l].depth]=new yt(s[l],this,i));if(a&&n){var u=Iq(a,n,this,!0,c);return u.data}function c(h,d){h.wrapMethod("getItemModel",function(f,p){var v=f.parentModel,g=v.getData().getItemLayout(p);if(g){var m=g.depth,y=v.levelModels[m];y&&(f.parentModel=y)}return f}),d.wrapMethod("getItemModel",function(f,p){var v=f.parentModel,g=v.getGraph().getEdgeByIndex(p),m=g.node1.getLayout();if(m){var y=m.depth,_=v.levelModels[y];_&&(f.parentModel=_)}return f})}},e.prototype.setNodePosition=function(t,i){var n=this.option.data||this.option.nodes,a=n[t];a.localX=i[0],a.localY=i[1]},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,i,n){function a(f){return isNaN(f)||f==null}if(n==="edge"){var s=this.getDataParams(t,n),o=s.data,l=s.value,u=o.source+" -- "+o.target;return Br("nameValue",{name:u,value:l,noValue:a(l)})}else{var c=this.getGraph().getNodeByIndex(t),h=c.getLayout().value,d=this.getDataParams(t,n).data.name;return Br("nameValue",{name:d!=null?d+"":null,value:h,noValue:a(h)})}},e.prototype.optionUpdated=function(){},e.prototype.getDataParams=function(t,i){var n=r.prototype.getDataParams.call(this,t,i);if(n.value==null&&i==="node"){var a=this.getGraph().getNodeByIndex(t),s=a.getLayout().value;n.value=s}return n},e.type="series.sankey",e.defaultOption={z:2,coordinateSystem:"view",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:"#314656",opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:"#212121"}},animationEasing:"linear",animationDuration:1e3},e}(Ot);function N1e(r,e){r.eachSeriesByType("sankey",function(t){var i=t.get("nodeWidth"),n=t.get("nodeGap"),a=B1e(t,e);t.layoutInfo=a;var s=a.width,o=a.height,l=t.getGraph(),u=l.nodes,c=l.edges;U1e(u);var h=Tt(u,function(v){return v.getLayout().value===0}),d=h.length!==0?0:t.get("layoutIterations"),f=t.get("orient"),p=t.get("nodeAlign");F1e(u,c,i,n,s,o,d,f,p)})}function B1e(r,e){return Ar(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function F1e(r,e,t,i,n,a,s,o,l){V1e(r,e,t,n,a,o,l),$1e(r,e,a,n,i,s,o),J1e(r,o)}function U1e(r){R(r,function(e){var t=Xo(e.outEdges,r_),i=Xo(e.inEdges,r_),n=e.getValue()||0,a=Math.max(t,i,n);e.setLayout({value:a},!0)})}function V1e(r,e,t,i,n,a,s){for(var o=[],l=[],u=[],c=[],h=0,d=0;d=0;m&&g.depth>f&&(f=g.depth),v.setLayout({depth:m?g.depth:h},!0),a==="vertical"?v.setLayout({dy:t},!0):v.setLayout({dx:t},!0);for(var y=0;yh-1?f:h-1;s&&s!=="left"&&z1e(r,s,a,C);var D=a==="vertical"?(n-t)/C:(i-t)/C;H1e(r,D,a)}function Xq(r){var e=r.hostGraph.data.getRawDataItem(r.dataIndex);return e.depth!=null&&e.depth>=0}function z1e(r,e,t,i){if(e==="right"){for(var n=[],a=r,s=0;a.length;){for(var o=0;o0;a--)l*=.99,j1e(o,l,s),FS(o,n,t,i,s),Q1e(o,l,s),FS(o,n,t,i,s)}function W1e(r,e){var t=[],i=e==="vertical"?"y":"x",n=Hx(r,function(a){return a.getLayout()[i]});return n.keys.sort(function(a,s){return a-s}),R(n.keys,function(a){t.push(n.buckets.get(a))}),t}function q1e(r,e,t,i,n,a){var s=1/0;R(r,function(o){var l=o.length,u=0;R(o,function(h){u+=h.getLayout().value});var c=a==="vertical"?(i-(l-1)*n)/u:(t-(l-1)*n)/u;c0&&(o=l.getLayout()[a]+u,n==="vertical"?l.setLayout({x:o},!0):l.setLayout({y:o},!0)),c=l.getLayout()[a]+l.getLayout()[d]+e;var p=n==="vertical"?i:t;if(u=c-e-p,u>0){o=l.getLayout()[a]-u,n==="vertical"?l.setLayout({x:o},!0):l.setLayout({y:o},!0),c=o;for(var f=h-2;f>=0;--f)l=s[f],u=l.getLayout()[a]+l.getLayout()[d]+e-c,u>0&&(o=l.getLayout()[a]-u,n==="vertical"?l.setLayout({x:o},!0):l.setLayout({y:o},!0)),c=l.getLayout()[a]}})}function j1e(r,e,t){R(r.slice().reverse(),function(i){R(i,function(n){if(n.outEdges.length){var a=Xo(n.outEdges,X1e,t)/Xo(n.outEdges,r_);if(isNaN(a)){var s=n.outEdges.length;a=s?Xo(n.outEdges,Y1e,t)/s:0}if(t==="vertical"){var o=n.getLayout().x+(a-al(n,t))*e;n.setLayout({x:o},!0)}else{var l=n.getLayout().y+(a-al(n,t))*e;n.setLayout({y:l},!0)}}})})}function X1e(r,e){return al(r.node2,e)*r.getValue()}function Y1e(r,e){return al(r.node2,e)}function K1e(r,e){return al(r.node1,e)*r.getValue()}function Z1e(r,e){return al(r.node1,e)}function al(r,e){return e==="vertical"?r.getLayout().x+r.getLayout().dx/2:r.getLayout().y+r.getLayout().dy/2}function r_(r){return r.getValue()}function Xo(r,e,t){for(var i=0,n=r.length,a=-1;++as&&(s=l)}),R(i,function(o){var l=new Or({type:"color",mappingMethod:"linear",dataExtent:[a,s],visual:e.get("color")}),u=l.mapValueToVisual(o.getLayout().value),c=o.getModel().get(["itemStyle","color"]);c!=null?(o.setVisual("color",c),o.setVisual("style",{fill:c})):(o.setVisual("color",u),o.setVisual("style",{fill:u}))})}n.length&&R(n,function(o){var l=o.getModel().get("lineStyle");o.setVisual("style",l)})})}function t2e(r){r.registerChartView(k1e),r.registerSeriesModel(O1e),r.registerLayout(N1e),r.registerVisual(e2e),r.registerAction({type:"dragNode",event:"dragnode",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"sankey",query:e},function(i){i.setNodePosition(e.dataIndex,[e.localX,e.localY])})})}var Yq=function(){function r(){}return r.prototype.getInitialData=function(e,t){var i,n=t.getComponent("xAxis",this.get("xAxisIndex")),a=t.getComponent("yAxis",this.get("yAxisIndex")),s=n.get("type"),o=a.get("type"),l;s==="category"?(e.layout="horizontal",i=n.getOrdinalMeta(),l=!0):o==="category"?(e.layout="vertical",i=a.getOrdinalMeta(),l=!0):e.layout=e.layout||"horizontal";var u=["x","y"],c=e.layout==="horizontal"?0:1,h=this._baseAxisDim=u[c],d=u[1-c],f=[n,a],p=f[c].get("type"),v=f[1-c].get("type"),g=e.data;if(g&&l){var m=[];R(g,function(b,T){var x;ie(b)?(x=b.slice(),b.unshift(T)):ie(b.value)?(x=J({},b),x.value=x.value.slice(),b.value.unshift(T)):x=b,m.push(x)}),e.data=m}var y=this.defaultValueDimensions,_=[{name:h,type:Wy(p),ordinalMeta:i,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:d,type:Wy(v),dimsDef:y.slice()}];return Hf(this,{coordDimensions:_,dimensionsCount:y.length+1,encodeDefaulter:Ue(AH,_,this)})},r.prototype.getBaseAxis=function(){var e=this._baseAxisDim;return this.ecModel.getComponent(e+"Axis",this.get(e+"AxisIndex")).axis},r}(),Kq=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],t.visualDrawType="stroke",t}return e.type="series.boxplot",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}},animationDuration:800},e}(Ot);_r(Kq,Yq,!0);var r2e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){var a=t.getData(),s=this.group,o=this._data;this._data||s.removeAll();var l=t.get("layout")==="horizontal"?1:0;a.diff(o).add(function(u){if(a.hasValue(u)){var c=a.getItemLayout(u),h=Qk(c,a,u,l,!0);a.setItemGraphicEl(u,h),s.add(h)}}).update(function(u,c){var h=o.getItemGraphicEl(c);if(!a.hasValue(u)){s.remove(h);return}var d=a.getItemLayout(u);h?(_a(h),Zq(d,h,a,u)):h=Qk(d,a,u,l),s.add(h),a.setItemGraphicEl(u,h)}).remove(function(u){var c=o.getItemGraphicEl(u);c&&s.remove(c)}).execute(),this._data=a},e.prototype.remove=function(t){var i=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl(function(a){a&&i.remove(a)})},e.type="boxplot",e}(Ct),i2e=function(){function r(){}return r}(),n2e=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i.type="boxplotBoxPath",i}return e.prototype.getDefaultShape=function(){return new i2e},e.prototype.buildPath=function(t,i){var n=i.points,a=0;for(t.moveTo(n[a][0],n[a][1]),a++;a<4;a++)t.lineTo(n[a][0],n[a][1]);for(t.closePath();av){var b=[m,_];i.push(b)}}}return{boxData:t,outliers:i}}var h2e={type:"echarts:boxplot",transform:function(e){var t=e.upstream;if(t.sourceFormat!==ui){var i="";vt(i)}var n=c2e(t.getRawData(),e.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:n.boxData},{data:n.outliers}]}};function f2e(r){r.registerSeriesModel(Kq),r.registerChartView(r2e),r.registerLayout(s2e),r.registerTransform(h2e)}var d2e=["color","borderColor"],p2e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},e.prototype.incrementalPrepareRender=function(t,i,n){this._clear(),this._updateDrawMode(t)},e.prototype.incrementalRender=function(t,i,n,a){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(t,i):this._incrementalRenderNormal(t,i)},e.prototype.eachRendered=function(t){cl(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var i=t.pipelineContext.large;(this._isLargeDraw==null||i!==this._isLargeDraw)&&(this._isLargeDraw=i,this._clear())},e.prototype._renderNormal=function(t){var i=t.getData(),n=this._data,a=this.group,s=i.getLayout("isSimpleBox"),o=t.get("clip",!0),l=t.coordinateSystem,u=l.getArea&&l.getArea();this._data||a.removeAll(),i.diff(n).add(function(c){if(i.hasValue(c)){var h=i.getItemLayout(c);if(o&&Jk(u,h))return;var d=US(h,c,!0);Vt(d,{shape:{points:h.ends}},t,c),VS(d,i,c,s),a.add(d),i.setItemGraphicEl(c,d)}}).update(function(c,h){var d=n.getItemGraphicEl(h);if(!i.hasValue(c)){a.remove(d);return}var f=i.getItemLayout(c);if(o&&Jk(u,f)){a.remove(d);return}d?(ct(d,{shape:{points:f.ends}},t,c),_a(d)):d=US(f),VS(d,i,c,s),a.add(d),i.setItemGraphicEl(c,d)}).remove(function(c){var h=n.getItemGraphicEl(c);h&&a.remove(h)}).execute(),this._data=i},e.prototype._renderLarge=function(t){this._clear(),e8(t,this.group);var i=t.get("clip",!0)?cg(t.coordinateSystem,!1,t):null;i?this.group.setClipPath(i):this.group.removeClipPath()},e.prototype._incrementalRenderNormal=function(t,i){for(var n=i.getData(),a=n.getLayout("isSimpleBox"),s;(s=t.next())!=null;){var o=n.getItemLayout(s),l=US(o);VS(l,n,s,a),l.incremental=!0,this.group.add(l),this._progressiveEls.push(l)}},e.prototype._incrementalRenderLarge=function(t,i){e8(i,this.group,this._progressiveEls,!0)},e.prototype.remove=function(t){this._clear()},e.prototype._clear=function(){this.group.removeAll(),this._data=null},e.type="candlestick",e}(Ct),v2e=function(){function r(){}return r}(),g2e=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i.type="normalCandlestickBox",i}return e.prototype.getDefaultShape=function(){return new v2e},e.prototype.buildPath=function(t,i){var n=i.points;this.__simpleBox?(t.moveTo(n[4][0],n[4][1]),t.lineTo(n[6][0],n[6][1])):(t.moveTo(n[0][0],n[0][1]),t.lineTo(n[1][0],n[1][1]),t.lineTo(n[2][0],n[2][1]),t.lineTo(n[3][0],n[3][1]),t.closePath(),t.moveTo(n[4][0],n[4][1]),t.lineTo(n[5][0],n[5][1]),t.moveTo(n[6][0],n[6][1]),t.lineTo(n[7][0],n[7][1]))},e}(Qe);function US(r,e,t){var i=r.ends;return new g2e({shape:{points:t?m2e(i,r):i},z2:100})}function Jk(r,e){for(var t=!0,i=0;i0?"borderColor":"borderColor0"])||t.get(["itemStyle",r>0?"color":"color0"]);r===0&&(n=t.get(["itemStyle","borderColorDoji"]));var a=t.getModel("itemStyle").getItemStyle(d2e);e.useStyle(a),e.style.fill=null,e.style.stroke=n}var Qq=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],t}return e.prototype.getShadowDim=function(){return"open"},e.prototype.brushSelector=function(t,i,n){var a=i.getItemLayout(t);return a&&n.rect(a.brushRect)},e.type="series.candlestick",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},e}(Ot);_r(Qq,Yq,!0);function _2e(r){!r||!ie(r.series)||R(r.series,function(e){De(e)&&e.type==="k"&&(e.type="candlestick")})}var b2e=["itemStyle","borderColor"],S2e=["itemStyle","borderColor0"],T2e=["itemStyle","borderColorDoji"],x2e=["itemStyle","color"],w2e=["itemStyle","color0"],C2e={seriesType:"candlestick",plan:Uf(),performRawSeries:!0,reset:function(r,e){function t(a,s){return s.get(a>0?x2e:w2e)}function i(a,s){return s.get(a===0?T2e:a>0?b2e:S2e)}if(!e.isSeriesFiltered(r)){var n=r.pipelineContext.large;return!n&&{progress:function(a,s){for(var o;(o=a.next())!=null;){var l=s.getItemModel(o),u=s.getItemLayout(o).sign,c=l.getItemStyle();c.fill=t(u,l),c.stroke=i(u,l)||c.fill;var h=s.ensureUniqueItemVisual(o,"style");J(h,c)}}}}}},A2e={seriesType:"candlestick",plan:Uf(),reset:function(r){var e=r.coordinateSystem,t=r.getData(),i=D2e(r,t),n=0,a=1,s=["x","y"],o=t.getDimensionIndex(t.mapDimension(s[n])),l=oe(t.mapDimensionsAll(s[a]),t.getDimensionIndex,t),u=l[0],c=l[1],h=l[2],d=l[3];if(t.setLayout({candleWidth:i,isSimpleBox:i<=1.3}),o<0||l.length<4)return;return{progress:r.pipelineContext.large?p:f};function f(v,g){for(var m,y=g.getStore();(m=v.next())!=null;){var _=y.get(o,m),b=y.get(u,m),T=y.get(c,m),x=y.get(h,m),C=y.get(d,m),D=Math.min(b,T),I=Math.max(b,T),M=$(D,_),L=$(I,_),N=$(x,_),O=$(C,_),B=[];q(B,L,0),q(B,M,1),B.push(te(O),te(L),te(N),te(M));var F=g.getItemModel(m),U=!!F.get(["itemStyle","borderColorDoji"]);g.setItemLayout(m,{sign:t8(y,m,b,T,c,U),initBaseline:b>T?L[a]:M[a],ends:B,brushRect:Z(x,C,_)})}function $(Q,se){var he=[];return he[n]=se,he[a]=Q,isNaN(se)||isNaN(Q)?[NaN,NaN]:e.dataToPoint(he)}function q(Q,se,he){var ue=se.slice(),Ie=se.slice();ue[n]=x0(ue[n]+i/2,1,!1),Ie[n]=x0(Ie[n]-i/2,1,!0),he?Q.push(ue,Ie):Q.push(Ie,ue)}function Z(Q,se,he){var ue=$(Q,he),Ie=$(se,he);return ue[n]-=i/2,Ie[n]-=i/2,{x:ue[0],y:ue[1],width:i,height:Ie[1]-ue[1]}}function te(Q){return Q[n]=x0(Q[n],1),Q}}function p(v,g){for(var m=ja(v.count*4),y=0,_,b=[],T=[],x,C=g.getStore(),D=!!r.get(["itemStyle","borderColorDoji"]);(x=v.next())!=null;){var I=C.get(o,x),M=C.get(u,x),L=C.get(c,x),N=C.get(h,x),O=C.get(d,x);if(isNaN(I)||isNaN(N)||isNaN(O)){m[y++]=NaN,y+=3;continue}m[y++]=t8(C,x,M,L,c,D),b[n]=I,b[a]=N,_=e.dataToPoint(b,null,T),m[y++]=_?_[0]:NaN,m[y++]=_?_[1]:NaN,b[a]=O,_=e.dataToPoint(b,null,T),m[y++]=_?_[1]:NaN}g.setLayout("largePoints",m)}}};function t8(r,e,t,i,n,a){var s;return t>i?s=-1:t0?r.get(n,e-1)<=i?1:-1:1,s}function D2e(r,e){var t=r.getBaseAxis(),i,n=t.type==="category"?t.getBandWidth():(i=t.getExtent(),Math.abs(i[1]-i[0])/e.count()),a=ce(Be(r.get("barMaxWidth"),n),n),s=ce(Be(r.get("barMinWidth"),1),n),o=r.get("barWidth");return o!=null?ce(o,n):Math.max(Math.min(n/2,a),s)}function E2e(r){r.registerChartView(p2e),r.registerSeriesModel(Qq),r.registerPreprocessor(_2e),r.registerVisual(C2e),r.registerLayout(A2e)}function r8(r,e){var t=e.rippleEffectColor||e.color;r.eachChild(function(i){i.attr({z:e.z,zlevel:e.zlevel,style:{stroke:e.brushType==="stroke"?t:null,fill:e.brushType==="fill"?t:null}})})}var I2e=function(r){j(e,r);function e(t,i){var n=r.call(this)||this,a=new lg(t,i),s=new Le;return n.add(a),n.add(s),n.updateData(t,i),n}return e.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},e.prototype.startEffectAnimation=function(t){for(var i=t.symbolType,n=t.color,a=t.rippleNumber,s=this.childAt(1),o=0;o0&&(o=this._getLineLength(a)/c*1e3),o!==this._period||l!==this._loop||u!==this._roundTrip){a.stopAnimation();var d=void 0;we(h)?d=h(n):d=h,a.__t>0&&(d=-o*a.__t),this._animateSymbol(a,o,d,l,u)}this._period=o,this._loop=l,this._roundTrip=u}},e.prototype._animateSymbol=function(t,i,n,a,s){if(i>0){t.__t=0;var o=this,l=t.animate("",a).when(s?i*2:i,{__t:s?2:1}).delay(n).during(function(){o._updateSymbolPosition(t)});a||l.done(function(){o.remove(t)}),l.start()}},e.prototype._getLineLength=function(t){return Ro(t.__p1,t.__cp1)+Ro(t.__cp1,t.__p2)},e.prototype._updateAnimationPoints=function(t,i){t.__p1=i[0],t.__p2=i[1],t.__cp1=i[2]||[(i[0][0]+i[1][0])/2,(i[0][1]+i[1][1])/2]},e.prototype.updateData=function(t,i,n){this.childAt(0).updateData(t,i,n),this._updateEffectSymbol(t,i)},e.prototype._updateSymbolPosition=function(t){var i=t.__p1,n=t.__p2,a=t.__cp1,s=t.__t<1?t.__t:2-t.__t,o=[t.x,t.y],l=o.slice(),u=Ur,c=Ex;o[0]=u(i[0],a[0],n[0],s),o[1]=u(i[1],a[1],n[1],s);var h=t.__t<1?c(i[0],a[0],n[0],s):c(n[0],a[0],i[0],1-s),d=t.__t<1?c(i[1],a[1],n[1],s):c(n[1],a[1],i[1],1-s);t.rotation=-Math.atan2(d,h)-Math.PI/2,(this._symbolType==="line"||this._symbolType==="rect"||this._symbolType==="roundRect")&&(t.__lastT!==void 0&&t.__lastT=0&&!(a[l]<=i);l--);l=Math.min(l,s-2)}else{for(l=o;li);l++);l=Math.min(l-1,s-2)}var c=(i-a[l])/(a[l+1]-a[l]),h=n[l],d=n[l+1];t.x=h[0]*(1-c)+c*d[0],t.y=h[1]*(1-c)+c*d[1];var f=t.__t<1?d[0]-h[0]:h[0]-d[0],p=t.__t<1?d[1]-h[1]:h[1]-d[1];t.rotation=-Math.atan2(p,f)-Math.PI/2,this._lastFrame=l,this._lastFramePercent=i,t.ignore=!1}},e}(Jq),R2e=function(){function r(){this.polyline=!1,this.curveness=0,this.segs=[]}return r}(),O2e=function(r){j(e,r);function e(t){var i=r.call(this,t)||this;return i._off=0,i.hoverDataIdx=-1,i}return e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new R2e},e.prototype.buildPath=function(t,i){var n=i.segs,a=i.curveness,s;if(i.polyline)for(s=this._off;s0){t.moveTo(n[s++],n[s++]);for(var l=1;l0){var f=(u+h)/2-(c-d)*a,p=(c+d)/2-(h-u)*a;t.quadraticCurveTo(f,p,h,d)}else t.lineTo(h,d)}this.incremental&&(this._off=s,this.notClear=!0)},e.prototype.findDataIndex=function(t,i){var n=this.shape,a=n.segs,s=n.curveness,o=this.style.lineWidth;if(n.polyline)for(var l=0,u=0;u0)for(var h=a[u++],d=a[u++],f=1;f0){var g=(h+p)/2-(d-v)*s,m=(d+v)/2-(p-h)*s;if(AG(h,d,g,m,p,v,o,t,i))return l}else if(Eo(h,d,p,v,o,t,i))return l;l++}return-1},e.prototype.contain=function(t,i){var n=this.transformCoordToLocal(t,i),a=this.getBoundingRect();if(t=n[0],i=n[1],a.contain(t,i)){var s=this.hoverDataIdx=this.findDataIndex(t,i);return s>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var i=this.shape,n=i.segs,a=1/0,s=1/0,o=-1/0,l=-1/0,u=0;u0&&(s.dataIndex=l+e.__startIndex)})},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r}(),tj={seriesType:"lines",plan:Uf(),reset:function(r){var e=r.coordinateSystem;if(e){var t=r.get("polyline"),i=r.pipelineContext.large;return{progress:function(n,a){var s=[];if(i){var o=void 0,l=n.end-n.start;if(t){for(var u=0,c=n.start;c0&&(c||u.configLayer(o,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(l/10+.9,1),0)})),s.updateData(a);var h=t.get("clip",!0)&&cg(t.coordinateSystem,!1,t);h?this.group.setClipPath(h):this.group.removeClipPath(),this._lastZlevel=o,this._finished=!0},e.prototype.incrementalPrepareRender=function(t,i,n){var a=t.getData(),s=this._updateLineDraw(a,t);s.incrementalPrepareUpdate(a),this._clearLayer(n),this._finished=!1},e.prototype.incrementalRender=function(t,i,n){this._lineDraw.incrementalUpdate(t,i.getData()),this._finished=t.end===i.getData().count()},e.prototype.eachRendered=function(t){this._lineDraw&&this._lineDraw.eachRendered(t)},e.prototype.updateTransform=function(t,i,n){var a=t.getData(),s=t.pipelineContext;if(!this._finished||s.large||s.progressiveRender)return{update:!0};var o=tj.reset(t,i,n);o.progress&&o.progress({start:0,end:a.count(),count:a.count()},a),this._lineDraw.updateLayout(),this._clearLayer(n)},e.prototype._updateLineDraw=function(t,i){var n=this._lineDraw,a=this._showEffect(i),s=!!i.get("polyline"),o=i.pipelineContext,l=o.large;return(!n||a!==this._hasEffet||s!==this._isPolyline||l!==this._isLargeDraw)&&(n&&n.remove(),n=this._lineDraw=l?new N2e:new dE(s?a?k2e:ej:a?Jq:fE),this._hasEffet=a,this._isPolyline=s,this._isLargeDraw=l),this.group.add(n.group),n},e.prototype._showEffect=function(t){return!!t.get(["effect","show"])},e.prototype._clearLayer=function(t){var i=t.getZr(),n=i.painter.getType()==="svg";!n&&this._lastZlevel!=null&&i.painter.getLayer(this._lastZlevel).clear(!0)},e.prototype.remove=function(t,i){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(i)},e.prototype.dispose=function(t,i){this.remove(t,i)},e.type="lines",e}(Ct),F2e=typeof Uint32Array>"u"?Array:Uint32Array,U2e=typeof Float64Array>"u"?Array:Float64Array;function i8(r){var e=r.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(r.data=oe(e,function(t){var i=[t[0].coord,t[1].coord],n={coords:i};return t[0].name&&(n.fromName=t[0].name),t[1].name&&(n.toName=t[1].name),WA([n,t[0],t[1]])}))}var V2e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.init=function(t){t.data=t.data||[],i8(t);var i=this._processFlatCoordsArray(t.data);this._flatCoords=i.flatCoords,this._flatCoordsOffset=i.flatCoordsOffset,i.flatCoords&&(t.data=new Float32Array(i.count)),r.prototype.init.apply(this,arguments)},e.prototype.mergeOption=function(t){if(i8(t),t.data){var i=this._processFlatCoordsArray(t.data);this._flatCoords=i.flatCoords,this._flatCoordsOffset=i.flatCoordsOffset,i.flatCoords&&(t.data=new Float32Array(i.count))}r.prototype.mergeOption.apply(this,arguments)},e.prototype.appendData=function(t){var i=this._processFlatCoordsArray(t.data);i.flatCoords&&(this._flatCoords?(this._flatCoords=Sy(this._flatCoords,i.flatCoords),this._flatCoordsOffset=Sy(this._flatCoordsOffset,i.flatCoordsOffset)):(this._flatCoords=i.flatCoords,this._flatCoordsOffset=i.flatCoordsOffset),t.data=new Float32Array(i.count)),this.getRawData().appendData(t.data)},e.prototype._getCoordsFromItemModel=function(t){var i=this.getData().getItemModel(t),n=i.option instanceof Array?i.option:i.getShallow("coords");return n},e.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[t*2+1]:this._getCoordsFromItemModel(t).length},e.prototype.getLineCoords=function(t,i){if(this._flatCoordsOffset){for(var n=this._flatCoordsOffset[t*2],a=this._flatCoordsOffset[t*2+1],s=0;s ")})},e.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},e.prototype.getProgressive=function(){var t=this.option.progressive;return t??(this.option.large?1e4:this.get("progressive"))},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t??(this.option.large?2e4:this.get("progressiveThreshold"))},e.prototype.getZLevelKey=function(){var t=this.getModel("effect"),i=t.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:t.get("show")&&i>0?i+"":""},e.type="series.lines",e.dependencies=["grid","polar","geo","calendar"],e.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},e}(Ot);function qm(r){return r instanceof Array||(r=[r,r]),r}var z2e={seriesType:"lines",reset:function(r){var e=qm(r.get("symbol")),t=qm(r.get("symbolSize")),i=r.getData();i.setVisual("fromSymbol",e&&e[0]),i.setVisual("toSymbol",e&&e[1]),i.setVisual("fromSymbolSize",t&&t[0]),i.setVisual("toSymbolSize",t&&t[1]);function n(a,s){var o=a.getItemModel(s),l=qm(o.getShallow("symbol",!0)),u=qm(o.getShallow("symbolSize",!0));l[0]&&a.setItemVisual(s,"fromSymbol",l[0]),l[1]&&a.setItemVisual(s,"toSymbol",l[1]),u[0]&&a.setItemVisual(s,"fromSymbolSize",u[0]),u[1]&&a.setItemVisual(s,"toSymbolSize",u[1])}return{dataEach:i.hasItemOption?n:null}}};function G2e(r){r.registerChartView(B2e),r.registerSeriesModel(V2e),r.registerLayout(tj),r.registerVisual(z2e)}var H2e=256,$2e=function(){function r(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var e=el.createCanvas();this.canvas=e}return r.prototype.update=function(e,t,i,n,a,s){var o=this._getBrush(),l=this._getGradient(a,"inRange"),u=this._getGradient(a,"outOfRange"),c=this.pointSize+this.blurSize,h=this.canvas,d=h.getContext("2d"),f=e.length;h.width=t,h.height=i;for(var p=0;p0){var N=s(_)?l:u;_>0&&(_=_*M+D),T[x++]=N[L],T[x++]=N[L+1],T[x++]=N[L+2],T[x++]=N[L+3]*_*256}else x+=4}return d.putImageData(b,0,0),h},r.prototype._getBrush=function(){var e=this._brushCanvas||(this._brushCanvas=el.createCanvas()),t=this.pointSize+this.blurSize,i=t*2;e.width=i,e.height=i;var n=e.getContext("2d");return n.clearRect(0,0,i,i),n.shadowOffsetX=i,n.shadowBlur=this.blurSize,n.shadowColor="#000",n.beginPath(),n.arc(-t,t,this.pointSize,0,Math.PI*2,!0),n.closePath(),n.fill(),e},r.prototype._getGradient=function(e,t){for(var i=this._gradientPixels,n=i[t]||(i[t]=new Uint8ClampedArray(256*4)),a=[0,0,0,0],s=0,o=0;o<256;o++)e[t](o/255,!0,a),n[s++]=a[0],n[s++]=a[1],n[s++]=a[2],n[s++]=a[3];return n},r}();function W2e(r,e,t){var i=r[1]-r[0];e=oe(e,function(s){return{interval:[(s.interval[0]-r[0])/i,(s.interval[1]-r[0])/i]}});var n=e.length,a=0;return function(s){var o;for(o=a;o=0;o--){var l=e[o].interval;if(l[0]<=s&&s<=l[1]){a=o;break}}return o>=0&&o=e[0]&&i<=e[1]}}function n8(r){var e=r.dimensions;return e[0]==="lng"&&e[1]==="lat"}var j2e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){var a;i.eachComponent("visualMap",function(o){o.eachTargetSeries(function(l){l===t&&(a=o)})}),this._progressiveEls=null,this.group.removeAll();var s=t.coordinateSystem;s.type==="cartesian2d"||s.type==="calendar"?this._renderOnCartesianAndCalendar(t,n,0,t.getData().count()):n8(s)&&this._renderOnGeo(s,t,a,n)},e.prototype.incrementalPrepareRender=function(t,i,n){this.group.removeAll()},e.prototype.incrementalRender=function(t,i,n,a){var s=i.coordinateSystem;s&&(n8(s)?this.render(i,n,a):(this._progressiveEls=[],this._renderOnCartesianAndCalendar(i,a,t.start,t.end,!0)))},e.prototype.eachRendered=function(t){cl(this._progressiveEls||this.group,t)},e.prototype._renderOnCartesianAndCalendar=function(t,i,n,a,s){var o=t.coordinateSystem,l=dc(o,"cartesian2d"),u,c,h,d;if(l){var f=o.getAxis("x"),p=o.getAxis("y");u=f.getBandWidth()+.5,c=p.getBandWidth()+.5,h=f.scale.getExtent(),d=p.scale.getExtent()}for(var v=this.group,g=t.getData(),m=t.getModel(["emphasis","itemStyle"]).getItemStyle(),y=t.getModel(["blur","itemStyle"]).getItemStyle(),_=t.getModel(["select","itemStyle"]).getItemStyle(),b=t.get(["itemStyle","borderRadius"]),T=Nr(t),x=t.getModel("emphasis"),C=x.get("focus"),D=x.get("blurScope"),I=x.get("disabled"),M=l?[g.mapDimension("x"),g.mapDimension("y"),g.mapDimension("value")]:[g.mapDimension("time"),g.mapDimension("value")],L=n;Lh[1]||Fd[1])continue;var U=o.dataToPoint([B,F]);N=new st({shape:{x:U[0]-u/2,y:U[1]-c/2,width:u,height:c},style:O})}else{if(isNaN(g.get(M[1],L)))continue;N=new st({z2:1,shape:o.dataToRect([g.get(M[0],L)]).contentShape,style:O})}if(g.hasItemOption){var $=g.getItemModel(L),q=$.getModel("emphasis");m=q.getModel("itemStyle").getItemStyle(),y=$.getModel(["blur","itemStyle"]).getItemStyle(),_=$.getModel(["select","itemStyle"]).getItemStyle(),b=$.get(["itemStyle","borderRadius"]),C=q.get("focus"),D=q.get("blurScope"),I=q.get("disabled"),T=Nr($)}N.shape.r=b;var Z=t.getRawValue(L),te="-";Z&&Z[2]!=null&&(te=Z[2]+""),Jr(N,T,{labelFetcher:t,labelDataIndex:L,defaultOpacity:O.opacity,defaultText:te}),N.ensureState("emphasis").style=m,N.ensureState("blur").style=y,N.ensureState("select").style=_,Yt(N,C,D,I),N.incremental=s,s&&(N.states.emphasis.hoverLayer=!0),v.add(N),g.setItemGraphicEl(L,N),this._progressiveEls&&this._progressiveEls.push(N)}},e.prototype._renderOnGeo=function(t,i,n,a){var s=n.targetVisuals.inRange,o=n.targetVisuals.outOfRange,l=i.getData(),u=this._hmLayer||this._hmLayer||new $2e;u.blurSize=i.get("blurSize"),u.pointSize=i.get("pointSize"),u.minOpacity=i.get("minOpacity"),u.maxOpacity=i.get("maxOpacity");var c=t.getViewRect().clone(),h=t.getRoamTransform();c.applyTransform(h);var d=Math.max(c.x,0),f=Math.max(c.y,0),p=Math.min(c.width+c.x,a.getWidth()),v=Math.min(c.height+c.y,a.getHeight()),g=p-d,m=v-f,y=[l.mapDimension("lng"),l.mapDimension("lat"),l.mapDimension("value")],_=l.mapArray(y,function(C,D,I){var M=t.dataToPoint([C,D]);return M[0]-=d,M[1]-=f,M.push(I),M}),b=n.getExtent(),T=n.type==="visualMap.continuous"?q2e(b,n.option.range):W2e(b,n.getPieceList(),n.option.selected);u.update(_,g,m,s.color.getNormalizer(),{inRange:s.color.getColorMapper(),outOfRange:o.color.getColorMapper()},T);var x=new Wr({style:{width:g,height:m,x:d,y:f,image:u.canvas},silent:!0});this.group.add(x)},e.type="heatmap",e}(Ct),X2e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,i){return to(null,this,{generateCoord:"value"})},e.prototype.preventIncremental=function(){var t=ng.get(this.get("coordinateSystem"));if(t&&t.dimensions)return t.dimensions[0]==="lng"&&t.dimensions[1]==="lat"},e.type="series.heatmap",e.dependencies=["grid","geo","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:"#212121"}}},e}(Ot);function Y2e(r){r.registerChartView(j2e),r.registerSeriesModel(X2e)}var K2e=["itemStyle","borderWidth"],a8=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],HS=new eo,Z2e=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){var a=this.group,s=t.getData(),o=this._data,l=t.coordinateSystem,u=l.getBaseAxis(),c=u.isHorizontal(),h=l.master.getRect(),d={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:t,coordSys:l,coordSysExtent:[[h.x,h.x+h.width],[h.y,h.y+h.height]],isHorizontal:c,valueDim:a8[+c],categoryDim:a8[1-+c]};s.diff(o).add(function(p){if(s.hasValue(p)){var v=o8(s,p),g=s8(s,p,v,d),m=l8(s,d,g);s.setItemGraphicEl(p,m),a.add(m),c8(m,d,g)}}).update(function(p,v){var g=o.getItemGraphicEl(v);if(!s.hasValue(p)){a.remove(g);return}var m=o8(s,p),y=s8(s,p,m,d),_=oj(s,y);g&&_!==g.__pictorialShapeStr&&(a.remove(g),s.setItemGraphicEl(p,null),g=null),g?nbe(g,d,y):g=l8(s,d,y,!0),s.setItemGraphicEl(p,g),g.__pictorialSymbolMeta=y,a.add(g),c8(g,d,y)}).remove(function(p){var v=o.getItemGraphicEl(p);v&&u8(o,p,v.__pictorialSymbolMeta.animationModel,v)}).execute();var f=t.get("clip",!0)?cg(t.coordinateSystem,!1,t):null;return f?a.setClipPath(f):a.removeClipPath(),this._data=s,this.group},e.prototype.remove=function(t,i){var n=this.group,a=this._data;t.get("animation")?a&&a.eachItemGraphicEl(function(s){u8(a,ke(s).dataIndex,t,s)}):n.removeAll()},e.type="pictorialBar",e}(Ct);function s8(r,e,t,i){var n=r.getItemLayout(e),a=t.get("symbolRepeat"),s=t.get("symbolClip"),o=t.get("symbolPosition")||"start",l=t.get("symbolRotate"),u=(l||0)*Math.PI/180||0,c=t.get("symbolPatternSize")||2,h=t.isAnimationEnabled(),d={dataIndex:e,layout:n,itemModel:t,symbolType:r.getItemVisual(e,"symbol")||"circle",style:r.getItemVisual(e,"style"),symbolClip:s,symbolRepeat:a,symbolRepeatDirection:t.get("symbolRepeatDirection"),symbolPatternSize:c,rotation:u,animationModel:h?t:null,hoverScale:h&&t.get(["emphasis","scale"]),z2:t.getShallow("z",!0)||0};Q2e(t,a,n,i,d),J2e(r,e,n,a,s,d.boundingLength,d.pxSign,c,i,d),ebe(t,d.symbolScale,u,i,d);var f=d.symbolSize,p=hc(t.get("symbolOffset"),f);return tbe(t,f,n,a,s,p,o,d.valueLineWidth,d.boundingLength,d.repeatCutLength,i,d),d}function Q2e(r,e,t,i,n){var a=i.valueDim,s=r.get("symbolBoundingData"),o=i.coordSys.getOtherAxis(i.coordSys.getBaseAxis()),l=o.toGlobalCoord(o.dataToCoord(0)),u=1-+(t[a.wh]<=0),c;if(ie(s)){var h=[$S(o,s[0])-l,$S(o,s[1])-l];h[1]0?1:-1}function $S(r,e){return r.toGlobalCoord(r.dataToCoord(r.scale.parse(e)))}function J2e(r,e,t,i,n,a,s,o,l,u){var c=l.valueDim,h=l.categoryDim,d=Math.abs(t[h.wh]),f=r.getItemVisual(e,"symbolSize"),p;ie(f)?p=f.slice():f==null?p=["100%","100%"]:p=[f,f],p[h.index]=ce(p[h.index],d),p[c.index]=ce(p[c.index],i?d:Math.abs(a)),u.symbolSize=p;var v=u.symbolScale=[p[0]/o,p[1]/o];v[c.index]*=(l.isHorizontal?-1:1)*s}function ebe(r,e,t,i,n){var a=r.get(K2e)||0;a&&(HS.attr({scaleX:e[0],scaleY:e[1],rotation:t}),HS.updateTransform(),a/=HS.getLineScale(),a*=e[i.valueDim.index]),n.valueLineWidth=a||0}function tbe(r,e,t,i,n,a,s,o,l,u,c,h){var d=c.categoryDim,f=c.valueDim,p=h.pxSign,v=Math.max(e[f.index]+o,0),g=v;if(i){var m=Math.abs(l),y=Gr(r.get("symbolMargin"),"15%")+"",_=!1;y.lastIndexOf("!")===y.length-1&&(_=!0,y=y.slice(0,y.length-1));var b=ce(y,e[f.index]),T=Math.max(v+b*2,0),x=_?0:b*2,C=fG(i),D=C?i:h8((m+x)/T),I=m-D*v;b=I/2/(_?D:Math.max(D-1,1)),T=v+b*2,x=_?0:b*2,!C&&i!=="fixed"&&(D=u?h8((Math.abs(u)+x)/T):0),g=D*T-x,h.repeatTimes=D,h.symbolMargin=b}var M=p*(g/2),L=h.pathPosition=[];L[d.index]=t[d.wh]/2,L[f.index]=s==="start"?M:s==="end"?l-M:l/2,a&&(L[0]+=a[0],L[1]+=a[1]);var N=h.bundlePosition=[];N[d.index]=t[d.xy],N[f.index]=t[f.xy];var O=h.barRectShape=J({},t);O[f.wh]=p*Math.max(Math.abs(t[f.wh]),Math.abs(L[f.index]+M)),O[d.wh]=t[d.wh];var B=h.clipShape={};B[d.xy]=-t[d.xy],B[d.wh]=c.ecSize[d.wh],B[f.xy]=0,B[f.wh]=t[f.wh]}function rj(r){var e=r.symbolPatternSize,t=yr(r.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),t.type!=="image"&&t.setStyle({strokeNoScale:!0}),t}function ij(r,e,t,i){var n=r.__pictorialBundle,a=t.symbolSize,s=t.valueLineWidth,o=t.pathPosition,l=e.valueDim,u=t.repeatTimes||0,c=0,h=a[e.valueDim.index]+s+t.symbolMargin*2;for(SE(r,function(v){v.__pictorialAnimationIndex=c,v.__pictorialRepeatTimes=u,c0:m<0)&&(y=u-1-v),g[l.index]=h*(y-u/2+.5)+o[l.index],{x:g[0],y:g[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation}}}function nj(r,e,t,i){var n=r.__pictorialBundle,a=r.__pictorialMainPath;a?Fh(a,null,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation},t,i):(a=r.__pictorialMainPath=rj(t),n.add(a),Fh(a,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:0,scaleY:0,rotation:t.rotation},{scaleX:t.symbolScale[0],scaleY:t.symbolScale[1]},t,i))}function aj(r,e,t){var i=J({},e.barRectShape),n=r.__pictorialBarRect;n?Fh(n,null,{shape:i},e,t):(n=r.__pictorialBarRect=new st({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),n.disableMorphing=!0,r.add(n))}function sj(r,e,t,i){if(t.symbolClip){var n=r.__pictorialClipPath,a=J({},t.clipShape),s=e.valueDim,o=t.animationModel,l=t.dataIndex;if(n)ct(n,{shape:a},o,l);else{a[s.wh]=0,n=new st({shape:a}),r.__pictorialBundle.setClipPath(n),r.__pictorialClipPath=n;var u={};u[s.wh]=t.clipShape[s.wh],cc[i?"updateProps":"initProps"](n,{shape:u},o,l)}}}function o8(r,e){var t=r.getItemModel(e);return t.getAnimationDelayParams=rbe,t.isAnimationEnabled=ibe,t}function rbe(r){return{index:r.__pictorialAnimationIndex,count:r.__pictorialRepeatTimes}}function ibe(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function l8(r,e,t,i){var n=new Le,a=new Le;return n.add(a),n.__pictorialBundle=a,a.x=t.bundlePosition[0],a.y=t.bundlePosition[1],t.symbolRepeat?ij(n,e,t):nj(n,e,t),aj(n,t,i),sj(n,e,t,i),n.__pictorialShapeStr=oj(r,t),n.__pictorialSymbolMeta=t,n}function nbe(r,e,t){var i=t.animationModel,n=t.dataIndex,a=r.__pictorialBundle;ct(a,{x:t.bundlePosition[0],y:t.bundlePosition[1]},i,n),t.symbolRepeat?ij(r,e,t,!0):nj(r,e,t,!0),aj(r,t,!0),sj(r,e,t,!0)}function u8(r,e,t,i){var n=i.__pictorialBarRect;n&&n.removeTextContent();var a=[];SE(i,function(s){a.push(s)}),i.__pictorialMainPath&&a.push(i.__pictorialMainPath),i.__pictorialClipPath&&(t=null),R(a,function(s){rl(s,{scaleX:0,scaleY:0},t,e,function(){i.parent&&i.parent.remove(i)})}),r.setItemGraphicEl(e,null)}function oj(r,e){return[r.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function SE(r,e,t){R(r.__pictorialBundle.children(),function(i){i!==r.__pictorialBarRect&&e.call(t,i)})}function Fh(r,e,t,i,n,a){e&&r.attr(e),i.symbolClip&&!n?t&&r.attr(t):t&&cc[n?"updateProps":"initProps"](r,t,i.animationModel,i.dataIndex,a)}function c8(r,e,t){var i=t.dataIndex,n=t.itemModel,a=n.getModel("emphasis"),s=a.getModel("itemStyle").getItemStyle(),o=n.getModel(["blur","itemStyle"]).getItemStyle(),l=n.getModel(["select","itemStyle"]).getItemStyle(),u=n.getShallow("cursor"),c=a.get("focus"),h=a.get("blurScope"),d=a.get("scale");SE(r,function(v){if(v instanceof Wr){var g=v.style;v.useStyle(J({image:g.image,x:g.x,y:g.y,width:g.width,height:g.height},t.style))}else v.useStyle(t.style);var m=v.ensureState("emphasis");m.style=s,d&&(m.scaleX=v.scaleX*1.1,m.scaleY=v.scaleY*1.1),v.ensureState("blur").style=o,v.ensureState("select").style=l,u&&(v.cursor=u),v.z2=t.z2});var f=e.valueDim.posDesc[+(t.boundingLength>0)],p=r.__pictorialBarRect;p.ignoreClip=!0,Jr(p,Nr(n),{labelFetcher:e.seriesModel,labelDataIndex:i,defaultText:ff(e.seriesModel.getData(),i),inheritColor:t.style.fill,defaultOpacity:t.style.opacity,defaultOutsidePosition:f}),Yt(r,c,h,a.get("disabled"))}function h8(r){var e=Math.round(r);return Math.abs(r-e)<1e-4?e:Math.ceil(r)}var abe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}return e.prototype.getInitialData=function(t){return t.stack=null,r.prototype.getInitialData.apply(this,arguments)},e.type="series.pictorialBar",e.dependencies=["grid"],e.defaultOption=hl(Cv.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",clip:!1,progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),e}(Cv);function sbe(r){r.registerChartView(Z2e),r.registerSeriesModel(abe),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,Ue($$,"pictorialBar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,W$("pictorialBar"))}var obe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._layers=[],t}return e.prototype.render=function(t,i,n){var a=t.getData(),s=this,o=this.group,l=t.getLayerSeries(),u=a.getLayout("layoutInfo"),c=u.rect,h=u.boundaryGap;o.x=0,o.y=c.y+h[0];function d(g){return g.name}var f=new Xs(this._layersSeries||[],l,d,d),p=[];f.add(ge(v,this,"add")).update(ge(v,this,"update")).remove(ge(v,this,"remove")).execute();function v(g,m,y){var _=s._layers;if(g==="remove"){o.remove(_[m]);return}for(var b=[],T=[],x,C=l[m].indices,D=0;Da&&(a=o),i.push(o)}for(var u=0;ua&&(a=h)}return{y0:n,max:a}}function fbe(r){r.registerChartView(obe),r.registerSeriesModel(ube),r.registerLayout(cbe),r.registerProcessor(fg("themeRiver"))}var dbe=2,pbe=4,d8=function(r){j(e,r);function e(t,i,n,a){var s=r.call(this)||this;s.z2=dbe,s.textConfig={inside:!0},ke(s).seriesIndex=i.seriesIndex;var o=new lt({z2:pbe,silent:t.getModel().get(["label","silent"])});return s.setTextContent(o),s.updateData(!0,t,i,n,a),s}return e.prototype.updateData=function(t,i,n,a,s){this.node=i,i.piece=this,n=n||this._seriesModel,a=a||this._ecModel;var o=this;ke(o).dataIndex=i.dataIndex;var l=i.getModel(),u=l.getModel("emphasis"),c=i.getLayout(),h=J({},c);h.label=null;var d=i.getVisual("style");d.lineJoin="bevel";var f=i.getVisual("decal");f&&(d.decal=cf(f,s));var p=xu(l.getModel("itemStyle"),h,!0);J(h,p),R(Di,function(y){var _=o.ensureState(y),b=l.getModel([y,"itemStyle"]);_.style=b.getItemStyle();var T=xu(b,h);T&&(_.shape=T)}),t?(o.setShape(h),o.shape.r=c.r0,Vt(o,{shape:{r:c.r}},n,i.dataIndex)):(ct(o,{shape:h},n),_a(o)),o.useStyle(d),this._updateLabel(n);var v=l.getShallow("cursor");v&&o.attr("cursor",v),this._seriesModel=n||this._seriesModel,this._ecModel=a||this._ecModel;var g=u.get("focus"),m=g==="ancestor"?i.getAncestorsIndices():g==="descendant"?i.getDescendantIndices():g;Yt(this,m,u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t){var i=this,n=this.node.getModel(),a=n.getModel("label"),s=this.node.getLayout(),o=s.endAngle-s.startAngle,l=(s.startAngle+s.endAngle)/2,u=Math.cos(l),c=Math.sin(l),h=this,d=h.getTextContent(),f=this.node.dataIndex,p=a.get("minAngle")/180*Math.PI,v=a.get("show")&&!(p!=null&&Math.abs(o)B&&!hv(U-B)&&U0?(s.virtualPiece?s.virtualPiece.updateData(!1,y,t,i,n):(s.virtualPiece=new d8(y,t,i,n),c.add(s.virtualPiece)),_.piece.off("click"),s.virtualPiece.on("click",function(b){s._rootToNode(_.parentNode)})):s.virtualPiece&&(c.remove(s.virtualPiece),s.virtualPiece=null)}},e.prototype._initEvents=function(){var t=this;this.group.off("click"),this.group.on("click",function(i){var n=!1,a=t.seriesModel.getViewRoot();a.eachNode(function(s){if(!n&&s.piece&&s.piece===i.target){var o=s.getModel().get("nodeClick");if(o==="rootToNode")t._rootToNode(s);else if(o==="link"){var l=s.getModel(),u=l.get("link");if(u){var c=l.get("target",!0)||"_blank";By(u,c)}}n=!0}})})},e.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:Hw,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},e.prototype.containPoint=function(t,i){var n=i.getData(),a=n.getItemLayout(0);if(a){var s=t[0]-a.cx,o=t[1]-a.cy,l=Math.sqrt(s*s+o*o);return l<=a.r&&l>=a.r0}},e.type="sunburst",e}(Ct),ybe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t,i){var n={name:t.name,children:t.data};lj(n);var a=this._levelModels=oe(t.levels||[],function(l){return new yt(l,this,i)},this),s=sE.createTree(n,this,o);function o(l){l.wrapMethod("getItemModel",function(u,c){var h=s.getNodeByDataIndex(c),d=a[h.depth];return d&&(u.parentModel=d),u})}return s.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.getDataParams=function(t){var i=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return i.treePathInfo=L1(n,this),i},e.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var i=this.getRawData().tree.root;(!t||t!==i&&!i.contains(t))&&(this._viewRoot=i)},e.prototype.enableAriaDecal=function(){dq(this)},e.type="series.sunburst",e.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},e}(Ot);function lj(r){var e=0;R(r.children,function(i){lj(i);var n=i.value;ie(n)&&(n=n[0]),e+=n});var t=r.value;ie(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),ie(r.value)?r.value[0]=t:r.value=t}var v8=Math.PI/180;function _be(r,e,t){e.eachSeriesByType(r,function(i){var n=i.get("center"),a=i.get("radius");ie(a)||(a=[0,a]),ie(n)||(n=[n,n]);var s=t.getWidth(),o=t.getHeight(),l=Math.min(s,o),u=ce(n[0],s),c=ce(n[1],o),h=ce(a[0],l/2),d=ce(a[1],l/2),f=-i.get("startAngle")*v8,p=i.get("minAngle")*v8,v=i.getData().tree.root,g=i.getViewRoot(),m=g.depth,y=i.get("sort");y!=null&&uj(g,y);var _=0;R(g.children,function(U){!isNaN(U.getValue())&&_++});var b=g.getValue(),T=Math.PI/(b||_)*2,x=g.depth>0,C=g.height-(x?-1:1),D=(d-h)/(C||1),I=i.get("clockwise"),M=i.get("stillShowZeroSum"),L=I?1:-1,N=function(U,$){if(U){var q=$;if(U!==v){var Z=U.getValue(),te=b===0&&M?T:Z*T;te1;)s=s.parentNode;var o=n.getColorFromPalette(s.name||s.dataIndex+"",e);return i.depth>1&&pe(o)&&(o=Mx(o,(i.depth-1)/(a-1)*.5)),o}r.eachSeriesByType("sunburst",function(i){var n=i.getData(),a=n.tree;a.eachNode(function(s){var o=s.getModel(),l=o.getModel("itemStyle").getItemStyle();l.fill||(l.fill=t(s,i,a.root.height));var u=n.ensureUniqueItemVisual(s.dataIndex,"style");J(u,l)})})}function Tbe(r){r.registerChartView(mbe),r.registerSeriesModel(ybe),r.registerLayout(Ue(_be,"sunburst")),r.registerProcessor(Ue(fg,"sunburst")),r.registerVisual(Sbe),gbe(r)}var g8={color:"fill",borderColor:"stroke"},xbe={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},Ns=ot(),wbe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},e.prototype.getInitialData=function(t,i){return to(null,this)},e.prototype.getDataParams=function(t,i,n){var a=r.prototype.getDataParams.call(this,t,i);return n&&(a.info=Ns(n).info),a},e.type="series.custom",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},e}(Ot);function Cbe(r,e){return e=e||[0,0],oe(["x","y"],function(t,i){var n=this.getAxis(t),a=e[i],s=r[i]/2;return n.type==="category"?n.getBandWidth():Math.abs(n.dataToCoord(a-s)-n.dataToCoord(a+s))},this)}function Abe(r){var e=r.master.getRect();return{coordSys:{type:"cartesian2d",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:ge(Cbe,r)}}}function Dbe(r,e){return e=e||[0,0],oe([0,1],function(t){var i=e[t],n=r[t]/2,a=[],s=[];return a[t]=i-n,s[t]=i+n,a[1-t]=s[1-t]=e[1-t],Math.abs(this.dataToPoint(a)[t]-this.dataToPoint(s)[t])},this)}function Ebe(r){var e=r.getBoundingRect();return{coordSys:{type:"geo",x:e.x,y:e.y,width:e.width,height:e.height,zoom:r.getZoom()},api:{coord:function(t){return r.dataToPoint(t)},size:ge(Dbe,r)}}}function Ibe(r,e){var t=this.getAxis(),i=e instanceof Array?e[0]:e,n=(r instanceof Array?r[0]:r)/2;return t.type==="category"?t.getBandWidth():Math.abs(t.dataToCoord(i-n)-t.dataToCoord(i+n))}function Pbe(r){var e=r.getRect();return{coordSys:{type:"singleAxis",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:ge(Ibe,r)}}}function Mbe(r,e){return e=e||[0,0],oe(["Radius","Angle"],function(t,i){var n="get"+t+"Axis",a=this[n](),s=e[i],o=r[i]/2,l=a.type==="category"?a.getBandWidth():Math.abs(a.dataToCoord(s-o)-a.dataToCoord(s+o));return t==="Angle"&&(l=l*Math.PI/180),l},this)}function Lbe(r){var e=r.getRadiusAxis(),t=r.getAngleAxis(),i=e.getExtent();return i[0]>i[1]&&i.reverse(),{coordSys:{type:"polar",cx:r.cx,cy:r.cy,r:i[1],r0:i[0]},api:{coord:function(n){var a=e.dataToRadius(n[0]),s=t.dataToAngle(n[1]),o=r.coordToPoint([a,s]);return o.push(a,s*Math.PI/180),o},size:ge(Mbe,r)}}}function kbe(r){var e=r.getRect(),t=r.getRangeInfo();return{coordSys:{type:"calendar",x:e.x,y:e.y,width:e.width,height:e.height,cellWidth:r.getCellWidth(),cellHeight:r.getCellHeight(),rangeInfo:{start:t.start,end:t.end,weeks:t.weeks,dayCount:t.allDay}},api:{coord:function(i,n){return r.dataToPoint(i,n)}}}}function cj(r,e,t,i){return r&&(r.legacy||r.legacy!==!1&&!t&&!i&&e!=="tspan"&&(e==="text"||_e(r,"text")))}function hj(r,e,t){var i=r,n,a,s;if(e==="text")s=i;else{s={},_e(i,"text")&&(s.text=i.text),_e(i,"rich")&&(s.rich=i.rich),_e(i,"textFill")&&(s.fill=i.textFill),_e(i,"textStroke")&&(s.stroke=i.textStroke),_e(i,"fontFamily")&&(s.fontFamily=i.fontFamily),_e(i,"fontSize")&&(s.fontSize=i.fontSize),_e(i,"fontStyle")&&(s.fontStyle=i.fontStyle),_e(i,"fontWeight")&&(s.fontWeight=i.fontWeight),a={type:"text",style:s,silent:!0},n={};var o=_e(i,"textPosition");t?n.position=o?i.textPosition:"inside":o&&(n.position=i.textPosition),_e(i,"textPosition")&&(n.position=i.textPosition),_e(i,"textOffset")&&(n.offset=i.textOffset),_e(i,"textRotation")&&(n.rotation=i.textRotation),_e(i,"textDistance")&&(n.distance=i.textDistance)}return m8(s,r),R(s.rich,function(l){m8(l,l)}),{textConfig:n,textContent:a}}function m8(r,e){e&&(e.font=e.textFont||e.font,_e(e,"textStrokeWidth")&&(r.lineWidth=e.textStrokeWidth),_e(e,"textAlign")&&(r.align=e.textAlign),_e(e,"textVerticalAlign")&&(r.verticalAlign=e.textVerticalAlign),_e(e,"textLineHeight")&&(r.lineHeight=e.textLineHeight),_e(e,"textWidth")&&(r.width=e.textWidth),_e(e,"textHeight")&&(r.height=e.textHeight),_e(e,"textBackgroundColor")&&(r.backgroundColor=e.textBackgroundColor),_e(e,"textPadding")&&(r.padding=e.textPadding),_e(e,"textBorderColor")&&(r.borderColor=e.textBorderColor),_e(e,"textBorderWidth")&&(r.borderWidth=e.textBorderWidth),_e(e,"textBorderRadius")&&(r.borderRadius=e.textBorderRadius),_e(e,"textBoxShadowColor")&&(r.shadowColor=e.textBoxShadowColor),_e(e,"textBoxShadowBlur")&&(r.shadowBlur=e.textBoxShadowBlur),_e(e,"textBoxShadowOffsetX")&&(r.shadowOffsetX=e.textBoxShadowOffsetX),_e(e,"textBoxShadowOffsetY")&&(r.shadowOffsetY=e.textBoxShadowOffsetY))}function y8(r,e,t){var i=r;i.textPosition=i.textPosition||t.position||"inside",t.offset!=null&&(i.textOffset=t.offset),t.rotation!=null&&(i.textRotation=t.rotation),t.distance!=null&&(i.textDistance=t.distance);var n=i.textPosition.indexOf("inside")>=0,a=r.fill||"#000";_8(i,e);var s=i.textFill==null;return n?s&&(i.textFill=t.insideFill||"#fff",!i.textStroke&&t.insideStroke&&(i.textStroke=t.insideStroke),!i.textStroke&&(i.textStroke=a),i.textStrokeWidth==null&&(i.textStrokeWidth=2)):(s&&(i.textFill=r.fill||t.outsideFill||"#000"),!i.textStroke&&t.outsideStroke&&(i.textStroke=t.outsideStroke)),i.text=e.text,i.rich=e.rich,R(e.rich,function(o){_8(o,o)}),i}function _8(r,e){e&&(_e(e,"fill")&&(r.textFill=e.fill),_e(e,"stroke")&&(r.textStroke=e.fill),_e(e,"lineWidth")&&(r.textStrokeWidth=e.lineWidth),_e(e,"font")&&(r.font=e.font),_e(e,"fontStyle")&&(r.fontStyle=e.fontStyle),_e(e,"fontWeight")&&(r.fontWeight=e.fontWeight),_e(e,"fontSize")&&(r.fontSize=e.fontSize),_e(e,"fontFamily")&&(r.fontFamily=e.fontFamily),_e(e,"align")&&(r.textAlign=e.align),_e(e,"verticalAlign")&&(r.textVerticalAlign=e.verticalAlign),_e(e,"lineHeight")&&(r.textLineHeight=e.lineHeight),_e(e,"width")&&(r.textWidth=e.width),_e(e,"height")&&(r.textHeight=e.height),_e(e,"backgroundColor")&&(r.textBackgroundColor=e.backgroundColor),_e(e,"padding")&&(r.textPadding=e.padding),_e(e,"borderColor")&&(r.textBorderColor=e.borderColor),_e(e,"borderWidth")&&(r.textBorderWidth=e.borderWidth),_e(e,"borderRadius")&&(r.textBorderRadius=e.borderRadius),_e(e,"shadowColor")&&(r.textBoxShadowColor=e.shadowColor),_e(e,"shadowBlur")&&(r.textBoxShadowBlur=e.shadowBlur),_e(e,"shadowOffsetX")&&(r.textBoxShadowOffsetX=e.shadowOffsetX),_e(e,"shadowOffsetY")&&(r.textBoxShadowOffsetY=e.shadowOffsetY),_e(e,"textShadowColor")&&(r.textShadowColor=e.textShadowColor),_e(e,"textShadowBlur")&&(r.textShadowBlur=e.textShadowBlur),_e(e,"textShadowOffsetX")&&(r.textShadowOffsetX=e.textShadowOffsetX),_e(e,"textShadowOffsetY")&&(r.textShadowOffsetY=e.textShadowOffsetY))}var fj={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},b8=rt(fj);as(os,function(r,e){return r[e]=1,r},{});os.join(", ");var i_=["","style","shape","extra"],vf=ot();function TE(r,e,t,i,n){var a=r+"Animation",s=Lf(r,i,n)||{},o=vf(e).userDuring;return s.duration>0&&(s.during=o?ge(Fbe,{el:e,userDuring:o}):null,s.setToFinal=!0,s.scope=r),J(s,t[a]),s}function I0(r,e,t,i){i=i||{};var n=i.dataIndex,a=i.isInit,s=i.clearStyle,o=t.isAnimationEnabled(),l=vf(r),u=e.style;l.userDuring=e.during;var c={},h={};if(Vbe(r,e,h),T8("shape",e,h),T8("extra",e,h),!a&&o&&(Ube(r,e,c),S8("shape",r,e,c),S8("extra",r,e,c),zbe(r,e,u,c)),h.style=u,Rbe(r,h,s),Nbe(r,e),o)if(a){var d={};R(i_,function(p){var v=p?e[p]:e;v&&v.enterFrom&&(p&&(d[p]=d[p]||{}),J(p?d[p]:d,v.enterFrom))});var f=TE("enter",r,e,t,n);f.duration>0&&r.animateFrom(d,f)}else Obe(r,e,n||0,t,c);dj(r,e),u?r.dirty():r.markRedraw()}function dj(r,e){for(var t=vf(r).leaveToProps,i=0;i0&&r.animateFrom(n,a)}}function Nbe(r,e){_e(e,"silent")&&(r.silent=e.silent),_e(e,"ignore")&&(r.ignore=e.ignore),r instanceof Yn&&_e(e,"invisible")&&(r.invisible=e.invisible),r instanceof Qe&&_e(e,"autoBatch")&&(r.autoBatch=e.autoBatch)}var Ma={},Bbe={setTransform:function(r,e){return Ma.el[r]=e,this},getTransform:function(r){return Ma.el[r]},setShape:function(r,e){var t=Ma.el,i=t.shape||(t.shape={});return i[r]=e,t.dirtyShape&&t.dirtyShape(),this},getShape:function(r){var e=Ma.el.shape;if(e)return e[r]},setStyle:function(r,e){var t=Ma.el,i=t.style;return i&&(i[r]=e,t.dirtyStyle&&t.dirtyStyle()),this},getStyle:function(r){var e=Ma.el.style;if(e)return e[r]},setExtra:function(r,e){var t=Ma.el.extra||(Ma.el.extra={});return t[r]=e,this},getExtra:function(r){var e=Ma.el.extra;if(e)return e[r]}};function Fbe(){var r=this,e=r.el;if(e){var t=vf(e).userDuring,i=r.userDuring;if(t!==i){r.el=r.userDuring=null;return}Ma.el=e,i(Bbe)}}function S8(r,e,t,i){var n=t[r];if(n){var a=e[r],s;if(a){var o=t.transition,l=n.transition;if(l)if(!s&&(s=i[r]={}),Wu(l))J(s,a);else for(var u=xt(l),c=0;c=0){!s&&(s=i[r]={});for(var f=rt(a),c=0;c=0)){var d=r.getAnimationStyleProps(),f=d?d.style:null;if(f){!a&&(a=i.style={});for(var p=rt(t),u=0;u=0?e.getStore().get($,F):void 0}var q=e.get(U.name,F),Z=U&&U.ordinalMeta;return Z?Z.categories[q]:q}function x(B,F){F==null&&(F=u);var U=e.getItemVisual(F,"style"),$=U&&U.fill,q=U&&U.opacity,Z=y(F,zo).getItemStyle();$!=null&&(Z.fill=$),q!=null&&(Z.opacity=q);var te={inheritColor:pe($)?$:"#000"},Q=_(F,zo),se=kt(Q,null,te,!1,!0);se.text=Q.getShallow("show")?Be(r.getFormattedLabel(F,zo),ff(e,F)):null;var he=Oy(Q,te,!1);return I(B,Z),Z=y8(Z,se,he),B&&D(Z,B),Z.legacy=!0,Z}function C(B,F){F==null&&(F=u);var U=y(F,Bs).getItemStyle(),$=_(F,Bs),q=kt($,null,null,!0,!0);q.text=$.getShallow("show")?Qa(r.getFormattedLabel(F,Bs),r.getFormattedLabel(F,zo),ff(e,F)):null;var Z=Oy($,null,!0);return I(B,U),U=y8(U,q,Z),B&&D(U,B),U.legacy=!0,U}function D(B,F){for(var U in F)_e(F,U)&&(B[U]=F[U])}function I(B,F){B&&(B.textFill&&(F.textFill=B.textFill),B.textPosition&&(F.textPosition=B.textPosition))}function M(B,F){if(F==null&&(F=u),_e(g8,B)){var U=e.getItemVisual(F,"style");return U?U[g8[B]]:null}if(_e(xbe,B))return e.getItemVisual(F,B)}function L(B){if(a.type==="cartesian2d"){var F=a.getBaseAxis();return Vpe(Ce({axis:F},B))}}function N(){return t.getCurrentSeriesIndices()}function O(B){return vD(B,t)}}function Zbe(r){var e={};return R(r.dimensions,function(t){var i=r.getDimensionInfo(t);if(!i.isExtraCoord){var n=i.coordDim,a=e[n]=e[n]||[];a[i.coordDimIndex]=r.getDimensionIndex(t)}}),e}function XS(r,e,t,i,n,a,s){if(!i){a.remove(e);return}var o=DE(r,e,t,i,n,a);return o&&s.setItemGraphicEl(t,o),o&&Yt(o,i.focus,i.blurScope,i.emphasisDisabled),o}function DE(r,e,t,i,n,a){var s=-1,o=e;e&&mj(e,i,n)&&(s=Xe(a.childrenRef(),e),e=null);var l=!e,u=e;u?u.clearStates():(u=CE(i),o&&jbe(o,u)),i.morph===!1?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),In.normal.cfg=In.normal.conOpt=In.emphasis.cfg=In.emphasis.conOpt=In.blur.cfg=In.blur.conOpt=In.select.cfg=In.select.conOpt=null,In.isLegacy=!1,Jbe(u,t,i,n,l,In),Qbe(u,t,i,n,l),AE(r,u,t,i,In,n,l),_e(i,"info")&&(Ns(u).info=i.info);for(var c=0;c=0?a.replaceAt(u,s):a.add(u),u}function mj(r,e,t){var i=Ns(r),n=e.type,a=e.shape,s=e.style;return t.isUniversalTransitionEnabled()||n!=null&&n!==i.customGraphicType||n==="path"&&nSe(a)&&yj(a)!==i.customPathData||n==="image"&&_e(s,"image")&&s.image!==i.customImagePath}function Qbe(r,e,t,i,n){var a=t.clipPath;if(a===!1)r&&r.getClipPath()&&r.removeClipPath();else if(a){var s=r.getClipPath();s&&mj(s,a,i)&&(s=null),s||(s=CE(a),r.setClipPath(s)),AE(null,s,e,a,null,i,n)}}function Jbe(r,e,t,i,n,a){if(!r.isGroup){w8(t,null,a),w8(t,Bs,a);var s=a.normal.conOpt,o=a.emphasis.conOpt,l=a.blur.conOpt,u=a.select.conOpt;if(s!=null||o!=null||u!=null||l!=null){var c=r.getTextContent();if(s===!1)c&&r.removeTextContent();else{s=a.normal.conOpt=s||{type:"text"},c?c.clearStates():(c=CE(s),r.setTextContent(c)),AE(null,c,e,s,null,i,n);for(var h=s&&s.style,d=0;d=c;f--){var p=e.childAt(f);tSe(e,p,n)}}}function tSe(r,e,t){e&&O1(e,Ns(r).option,t)}function rSe(r){new Xs(r.oldChildren,r.newChildren,C8,C8,r).add(A8).update(A8).remove(iSe).execute()}function C8(r,e){var t=r&&r.name;return t??Wbe+e}function A8(r,e){var t=this.context,i=r!=null?t.newChildren[r]:null,n=e!=null?t.oldChildren[e]:null;DE(t.api,n,t.dataIndex,i,t.seriesModel,t.group)}function iSe(r){var e=this.context,t=e.oldChildren[r];t&&O1(t,Ns(t).option,e.seriesModel)}function yj(r){return r&&(r.pathData||r.d)}function nSe(r){return r&&(_e(r,"pathData")||_e(r,"d"))}function aSe(r){r.registerChartView(Xbe),r.registerSeriesModel(wbe)}var cu=ot(),D8=Ee,YS=ge,IE=function(){function r(){this._dragging=!1,this.animationThreshold=15}return r.prototype.render=function(e,t,i,n){var a=t.get("value"),s=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=i,!(!n&&this._lastValue===a&&this._lastStatus===s)){this._lastValue=a,this._lastStatus=s;var o=this._group,l=this._handle;if(!s||s==="hide"){o&&o.hide(),l&&l.hide();return}o&&o.show(),l&&l.show();var u={};this.makeElOption(u,a,e,t,i);var c=u.graphicKey;c!==this._lastGraphicKey&&this.clear(i),this._lastGraphicKey=c;var h=this._moveAnimation=this.determineAnimation(e,t);if(!o)o=this._group=new Le,this.createPointerEl(o,u,e,t),this.createLabelEl(o,u,e,t),i.getZr().add(o);else{var d=Ue(E8,t,h);this.updatePointerEl(o,u,d),this.updateLabelEl(o,u,d,t)}P8(o,t,!0),this._renderHandle(a)}},r.prototype.remove=function(e){this.clear(e)},r.prototype.dispose=function(e){this.clear(e)},r.prototype.determineAnimation=function(e,t){var i=t.get("animation"),n=e.axis,a=n.type==="category",s=t.get("snap");if(!s&&!a)return!1;if(i==="auto"||i==null){var o=this.animationThreshold;if(a&&n.getBandWidth()>o)return!0;if(s){var l=JD(e).seriesDataCount,u=n.getExtent();return Math.abs(u[0]-u[1])/l>o}return!1}return i===!0},r.prototype.makeElOption=function(e,t,i,n,a){},r.prototype.createPointerEl=function(e,t,i,n){var a=t.pointer;if(a){var s=cu(e).pointerEl=new cc[a.type](D8(t.pointer));e.add(s)}},r.prototype.createLabelEl=function(e,t,i,n){if(t.label){var a=cu(e).labelEl=new lt(D8(t.label));e.add(a),I8(a,n)}},r.prototype.updatePointerEl=function(e,t,i){var n=cu(e).pointerEl;n&&t.pointer&&(n.setStyle(t.pointer.style),i(n,{shape:t.pointer.shape}))},r.prototype.updateLabelEl=function(e,t,i,n){var a=cu(e).labelEl;a&&(a.setStyle(t.label.style),i(a,{x:t.label.x,y:t.label.y}),I8(a,n))},r.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var t=this._axisPointerModel,i=this._api.getZr(),n=this._handle,a=t.getModel("handle"),s=t.get("status");if(!a.get("show")||!s||s==="hide"){n&&i.remove(n),this._handle=null;return}var o;this._handle||(o=!0,n=this._handle=ig(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){$s(u.event)},onmousedown:YS(this._onHandleDragMove,this,0,0),drift:YS(this._onHandleDragMove,this),ondragend:YS(this._onHandleDragEnd,this)}),i.add(n)),P8(n,t,!1),n.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=a.get("size");ie(l)||(l=[l,l]),n.scaleX=l[0]/2,n.scaleY=l[1]/2,Vf(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,o)}},r.prototype._moveHandleToValue=function(e,t){E8(this._axisPointerModel,!t&&this._moveAnimation,this._handle,KS(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},r.prototype._onHandleDragMove=function(e,t){var i=this._handle;if(i){this._dragging=!0;var n=this.updateHandleTransform(KS(i),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=n,i.stopAnimation(),i.attr(KS(n)),cu(i).lastProp=null,this._doDispatchAxisPointer()}},r.prototype._doDispatchAxisPointer=function(){var e=this._handle;if(e){var t=this._payloadInfo,i=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:i.axis.dim,axisIndex:i.componentIndex}]})}},r.prototype._onHandleDragEnd=function(){this._dragging=!1;var e=this._handle;if(e){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"})}},r.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),i=this._group,n=this._handle;t&&i&&(this._lastGraphicKey=null,i&&t.remove(i),n&&t.remove(n),this._group=null,this._handle=null,this._payloadInfo=null),_v(this,"_doDispatchAxisPointer")},r.prototype.doClear=function(){},r.prototype.buildLabel=function(e,t,i){return i=i||0,{x:e[i],y:e[1-i],width:t[i],height:t[1-i]}},r}();function E8(r,e,t,i){_j(cu(t).lastProp,i)||(cu(t).lastProp=i,e?ct(t,i,r):(t.stopAnimation(),t.attr(i)))}function _j(r,e){if(De(r)&&De(e)){var t=!0;return R(e,function(i,n){t=t&&_j(r[n],i)}),!!t}else return r===e}function I8(r,e){r[e.get(["label","show"])?"show":"hide"]()}function KS(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function P8(r,e,t){var i=e.get("z"),n=e.get("zlevel");r&&r.traverse(function(a){a.type!=="group"&&(i!=null&&(a.z=i),n!=null&&(a.zlevel=n),a.silent=t)})}function PE(r){var e=r.get("type"),t=r.getModel(e+"Style"),i;return e==="line"?(i=t.getLineStyle(),i.fill=null):e==="shadow"&&(i=t.getAreaStyle(),i.stroke=null),i}function bj(r,e,t,i,n){var a=t.get("value"),s=Sj(a,e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),o=t.getModel("label"),l=Nf(o.get("padding")||0),u=o.getFont(),c=Kv(s,u),h=n.position,d=c.width+l[1]+l[3],f=c.height+l[0]+l[2],p=n.align;p==="right"&&(h[0]-=d),p==="center"&&(h[0]-=d/2);var v=n.verticalAlign;v==="bottom"&&(h[1]-=f),v==="middle"&&(h[1]-=f/2),sSe(h,d,f,i);var g=o.get("backgroundColor");(!g||g==="auto")&&(g=e.get(["axisLine","lineStyle","color"])),r.label={x:h[0],y:h[1],style:kt(o,{text:s,font:u,fill:o.getTextColor(),padding:l,backgroundColor:g}),z2:10}}function sSe(r,e,t,i){var n=i.getWidth(),a=i.getHeight();r[0]=Math.min(r[0]+e,n)-e,r[1]=Math.min(r[1]+t,a)-t,r[0]=Math.max(r[0],0),r[1]=Math.max(r[1],0)}function Sj(r,e,t,i,n){r=e.scale.parse(r);var a=e.scale.getLabel({value:r},{precision:n.precision}),s=n.formatter;if(s){var o={value:GD(e,{value:r}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};R(i,function(l){var u=t.getSeriesByIndex(l.seriesIndex),c=l.dataIndexInside,h=u&&u.getDataParams(c);h&&o.seriesData.push(h)}),pe(s)?a=s.replace("{value}",a):we(s)&&(a=s(o))}return a}function ME(r,e,t){var i=vn();return uc(i,i,t.rotation),ss(i,i,t.position),ma([r.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],i)}function Tj(r,e,t,i,n,a){var s=Ci.innerTextLayout(t.rotation,0,t.labelDirection);t.labelMargin=n.get(["label","margin"]),bj(e,i,n,a,{position:ME(i.axis,r,t),align:s.textAlign,verticalAlign:s.textVerticalAlign})}function LE(r,e,t){return t=t||0,{x1:r[t],y1:r[1-t],x2:e[t],y2:e[1-t]}}function xj(r,e,t){return t=t||0,{x:r[t],y:r[1-t],width:e[t],height:e[1-t]}}function M8(r,e,t,i,n,a){return{cx:r,cy:e,r0:t,r:i,startAngle:n,endAngle:a,clockwise:!0}}var oSe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,i,n,a,s){var o=n.axis,l=o.grid,u=a.get("type"),c=L8(l,o).getOtherAxis(o).getGlobalExtent(),h=o.toGlobalCoord(o.dataToCoord(i,!0));if(u&&u!=="none"){var d=PE(a),f=lSe[u](o,h,c);f.style=d,t.graphicKey=f.type,t.pointer=f}var p=Cw(l.model,n);Tj(i,t,p,n,a,s)},e.prototype.getHandleTransform=function(t,i,n){var a=Cw(i.axis.grid.model,i,{labelInside:!1});a.labelMargin=n.get(["handle","margin"]);var s=ME(i.axis,t,a);return{x:s[0],y:s[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,i,n,a){var s=n.axis,o=s.grid,l=s.getGlobalExtent(!0),u=L8(o,s).getOtherAxis(s).getGlobalExtent(),c=s.dim==="x"?0:1,h=[t.x,t.y];h[c]+=i[c],h[c]=Math.min(l[1],h[c]),h[c]=Math.max(l[0],h[c]);var d=(u[1]+u[0])/2,f=[d,d];f[c]=h[c];var p=[{verticalAlign:"middle"},{align:"center"}];return{x:h[0],y:h[1],rotation:t.rotation,cursorPoint:f,tooltipOption:p[c]}},e}(IE);function L8(r,e){var t={};return t[e.dim+"AxisIndex"]=e.index,r.getCartesian(t)}var lSe={line:function(r,e,t){var i=LE([e,t[0]],[e,t[1]],k8(r));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(r,e,t){var i=Math.max(1,r.getBandWidth()),n=t[1]-t[0];return{type:"Rect",shape:xj([e-i/2,t[0]],[i,n],k8(r))}}};function k8(r){return r.dim==="x"?0:1}var uSe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},e}(tt),Ps=ot(),cSe=R;function wj(r,e,t){if(!et.node){var i=e.getZr();Ps(i).records||(Ps(i).records={}),hSe(i,e);var n=Ps(i).records[r]||(Ps(i).records[r]={});n.handler=t}}function hSe(r,e){if(Ps(r).initialized)return;Ps(r).initialized=!0,t("click",Ue(R8,"click")),t("mousemove",Ue(R8,"mousemove")),t("globalout",dSe);function t(i,n){r.on(i,function(a){var s=pSe(e);cSe(Ps(r).records,function(o){o&&n(o,a,s.dispatchAction)}),fSe(s.pendings,e)})}}function fSe(r,e){var t=r.showTip.length,i=r.hideTip.length,n;t?n=r.showTip[t-1]:i&&(n=r.hideTip[i-1]),n&&(n.dispatchAction=null,e.dispatchAction(n))}function dSe(r,e,t){r.handler("leave",null,t)}function R8(r,e,t,i){e.handler(r,t,i)}function pSe(r){var e={showTip:[],hideTip:[]},t=function(i){var n=e[i.type];n?n.push(i):(i.dispatchAction=t,r.dispatchAction(i))};return{dispatchAction:t,pendings:e}}function qw(r,e){if(!et.node){var t=e.getZr(),i=(Ps(t).records||{})[r];i&&(Ps(t).records[r]=null)}}var vSe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){var a=i.getComponent("tooltip"),s=t.get("triggerOn")||a&&a.get("triggerOn")||"mousemove|click";wj("axisPointer",n,function(o,l,u){s!=="none"&&(o==="leave"||s.indexOf(o)>=0)&&u({type:"updateAxisPointer",currTrigger:o,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(t,i){qw("axisPointer",i)},e.prototype.dispose=function(t,i){qw("axisPointer",i)},e.type="axisPointer",e}($t);function Cj(r,e){var t=[],i=r.seriesIndex,n;if(i==null||!(n=e.getSeriesByIndex(i)))return{point:[]};var a=n.getData(),s=ec(a,r);if(s==null||s<0||ie(s))return{point:[]};var o=a.getItemGraphicEl(s),l=n.coordinateSystem;if(n.getTooltipPosition)t=n.getTooltipPosition(s)||[];else if(l&&l.dataToPoint)if(r.isStacked){var u=l.getBaseAxis(),c=l.getOtherAxis(u),h=c.dim,d=u.dim,f=h==="x"||h==="radius"?1:0,p=a.mapDimension(d),v=[];v[f]=a.get(p,s),v[1-f]=a.get(a.getCalculationInfo("stackResultDimension"),s),t=l.dataToPoint(v)||[]}else t=l.dataToPoint(a.getValues(oe(l.dimensions,function(m){return a.mapDimension(m)}),s))||[];else if(o){var g=o.getBoundingRect().clone();g.applyTransform(o.transform),t=[g.x+g.width/2,g.y+g.height/2]}return{point:t,el:o}}var O8=ot();function gSe(r,e,t){var i=r.currTrigger,n=[r.x,r.y],a=r,s=r.dispatchAction||ge(t.dispatchAction,t),o=e.getComponent("axisPointer").coordSysAxesInfo;if(o){P0(n)&&(n=Cj({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},e).point);var l=P0(n),u=a.axesInfo,c=o.axesInfo,h=i==="leave"||P0(n),d={},f={},p={list:[],map:{}},v={showPointer:Ue(ySe,f),showTooltip:Ue(_Se,p)};R(o.coordSysMap,function(m,y){var _=l||m.containPoint(n);R(o.coordSysAxesInfo[y],function(b,T){var x=b.axis,C=xSe(u,b);if(!h&&_&&(!u||C)){var D=C&&C.value;D==null&&!l&&(D=x.pointToData(n)),D!=null&&N8(b,D,v,!1,d)}})});var g={};return R(c,function(m,y){var _=m.linkGroup;_&&!f[y]&&R(_.axesInfo,function(b,T){var x=f[T];if(b!==m&&x){var C=x.value;_.mapper&&(C=m.axis.scale.parse(_.mapper(C,B8(b),B8(m)))),g[m.key]=C}})}),R(g,function(m,y){N8(c[y],m,v,!0,d)}),bSe(f,c,d),SSe(p,n,r,s),TSe(c,s,t),d}}function N8(r,e,t,i,n){var a=r.axis;if(!(a.scale.isBlank()||!a.containData(e))){if(!r.involveSeries){t.showPointer(r,e);return}var s=mSe(e,r),o=s.payloadBatch,l=s.snapToValue;o[0]&&n.seriesIndex==null&&J(n,o[0]),!i&&r.snap&&a.containData(l)&&l!=null&&(e=l),t.showPointer(r,e,o),t.showTooltip(r,s,l)}}function mSe(r,e){var t=e.axis,i=t.dim,n=r,a=[],s=Number.MAX_VALUE,o=-1;return R(e.seriesModels,function(l,u){var c=l.getData().mapDimensionsAll(i),h,d;if(l.getAxisTooltipData){var f=l.getAxisTooltipData(c,r,t);d=f.dataIndices,h=f.nestestValue}else{if(d=l.getData().indicesOfNearest(c[0],r,t.type==="category"?.5:null),!d.length)return;h=l.getData().get(c[0],d[0])}if(!(h==null||!isFinite(h))){var p=r-h,v=Math.abs(p);v<=s&&((v=0&&o<0)&&(s=v,o=p,n=h,a.length=0),R(d,function(g){a.push({seriesIndex:l.seriesIndex,dataIndexInside:g,dataIndex:l.getData().getRawIndex(g)})}))}}),{payloadBatch:a,snapToValue:n}}function ySe(r,e,t,i){r[e.key]={value:t,payloadBatch:i}}function _Se(r,e,t,i){var n=t.payloadBatch,a=e.axis,s=a.model,o=e.axisPointerModel;if(!(!e.triggerTooltip||!n.length)){var l=e.coordSys.model,u=Av(l),c=r.map[u];c||(c=r.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},r.list.push(c)),c.dataByAxis.push({axisDim:a.dim,axisIndex:s.componentIndex,axisType:s.type,axisId:s.id,value:i,valueLabelOpt:{precision:o.get(["label","precision"]),formatter:o.get(["label","formatter"])},seriesDataIndices:n.slice()})}}function bSe(r,e,t){var i=t.axesInfo=[];R(e,function(n,a){var s=n.axisPointerModel.option,o=r[a];o?(!n.useHandle&&(s.status="show"),s.value=o.value,s.seriesDataIndices=(o.payloadBatch||[]).slice()):!n.useHandle&&(s.status="hide"),s.status==="show"&&i.push({axisDim:n.axis.dim,axisIndex:n.axis.model.componentIndex,value:s.value})})}function SSe(r,e,t,i){if(P0(e)||!r.list.length){i({type:"hideTip"});return}var n=((r.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:t.tooltipOption,position:t.position,dataIndexInside:n.dataIndexInside,dataIndex:n.dataIndex,seriesIndex:n.seriesIndex,dataByCoordSys:r.list})}function TSe(r,e,t){var i=t.getZr(),n="axisPointerLastHighlights",a=O8(i)[n]||{},s=O8(i)[n]={};R(r,function(u,c){var h=u.axisPointerModel.option;h.status==="show"&&u.triggerEmphasis&&R(h.seriesDataIndices,function(d){var f=d.seriesIndex+" | "+d.dataIndex;s[f]=d})});var o=[],l=[];R(a,function(u,c){!s[c]&&l.push(u)}),R(s,function(u,c){!a[c]&&o.push(u)}),l.length&&t.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),o.length&&t.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:o})}function xSe(r,e){for(var t=0;t<(r||[]).length;t++){var i=r[t];if(e.axis.dim===i.axisDim&&e.axis.model.componentIndex===i.axisIndex)return i}}function B8(r){var e=r.axis.model,t={},i=t.axisDim=r.axis.dim;return t.axisIndex=t[i+"AxisIndex"]=e.componentIndex,t.axisName=t[i+"AxisName"]=e.name,t.axisId=t[i+"AxisId"]=e.id,t}function P0(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function gg(r){pc.registerAxisPointerClass("CartesianAxisPointer",oSe),r.registerComponentModel(uSe),r.registerComponentView(vSe),r.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!ie(t)&&(e.axisPointer.link=[t])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=kme(e,t)}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},gSe)}function wSe(r){Ze(JW),Ze(gg)}var CSe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,i,n,a,s){var o=n.axis;o.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=o.polar,u=l.getOtherAxis(o),c=u.getExtent(),h=o.dataToCoord(i),d=a.get("type");if(d&&d!=="none"){var f=PE(a),p=DSe[d](o,l,h,c);p.style=f,t.graphicKey=p.type,t.pointer=p}var v=a.get(["label","margin"]),g=ASe(i,n,a,l,v);bj(t,n,a,s,g)},e}(IE);function ASe(r,e,t,i,n){var a=e.axis,s=a.dataToCoord(r),o=i.getAngleAxis().getExtent()[0];o=o/180*Math.PI;var l=i.getRadiusAxis().getExtent(),u,c,h;if(a.dim==="radius"){var d=vn();uc(d,d,o),ss(d,d,[i.cx,i.cy]),u=ma([s,-n],d);var f=e.getModel("axisLabel").get("rotate")||0,p=Ci.innerTextLayout(o,f*Math.PI/180,-1);c=p.textAlign,h=p.textVerticalAlign}else{var v=l[1];u=i.coordToPoint([v+n,s]);var g=i.cx,m=i.cy;c=Math.abs(u[0]-g)/v<.3?"center":u[0]>g?"left":"right",h=Math.abs(u[1]-m)/v<.3?"middle":u[1]>m?"top":"bottom"}return{position:u,align:c,verticalAlign:h}}var DSe={line:function(r,e,t,i){return r.dim==="angle"?{type:"Line",shape:LE(e.coordToPoint([i[0],t]),e.coordToPoint([i[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(r,e,t,i){var n=Math.max(1,r.getBandWidth()),a=Math.PI/180;return r.dim==="angle"?{type:"Sector",shape:M8(e.cx,e.cy,i[0],i[1],(-t-n/2)*a,(-t+n/2)*a)}:{type:"Sector",shape:M8(e.cx,e.cy,t-n/2,t+n/2,0,Math.PI*2)}}},ESe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.findAxisModel=function(t){var i,n=this.ecModel;return n.eachComponent(t,function(a){a.getCoordSysModel()===this&&(i=a)},this),i},e.type="polar",e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e}(tt),kE=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",mr).models[0]},e.type="polarAxis",e}(tt);_r(kE,og);var ISe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e}(kE),PSe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e}(kE),RE=function(r){j(e,r);function e(t,i){return r.call(this,"radius",t,i)||this}return e.prototype.pointToData=function(t,i){return this.polar.pointToData(t,i)[this.dim==="radius"?0:1]},e}(xa);RE.prototype.dataToRadius=xa.prototype.dataToCoord;RE.prototype.radiusToData=xa.prototype.coordToData;var MSe=ot(),OE=function(r){j(e,r);function e(t,i){return r.call(this,"angle",t,i||[0,360])||this}return e.prototype.pointToData=function(t,i){return this.polar.pointToData(t,i)[this.dim==="radius"?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,i=t.getLabelModel(),n=t.scale,a=n.getExtent(),s=n.count();if(a[1]-a[0]<1)return 0;var o=a[0],l=t.dataToCoord(o+1)-t.dataToCoord(o),u=Math.abs(l),c=Kv(o==null?"":o+"",i.getFont(),"center","top"),h=Math.max(c.height,7),d=h/u;isNaN(d)&&(d=1/0);var f=Math.max(0,Math.floor(d)),p=MSe(t.model),v=p.lastAutoInterval,g=p.lastTickCount;return v!=null&&g!=null&&Math.abs(v-f)<=1&&Math.abs(g-s)<=1&&v>f?f=v:(p.lastTickCount=s,p.lastAutoInterval=f),f},e}(xa);OE.prototype.dataToAngle=xa.prototype.dataToCoord;OE.prototype.angleToData=xa.prototype.coordToData;var Aj=["radius","angle"],LSe=function(){function r(e){this.dimensions=Aj,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new RE,this._angleAxis=new OE,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return r.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},r.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},r.prototype.getAxis=function(e){var t="_"+e+"Axis";return this[t]},r.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},r.prototype.getAxesByScale=function(e){var t=[],i=this._angleAxis,n=this._radiusAxis;return i.scale.type===e&&t.push(i),n.scale.type===e&&t.push(n),t},r.prototype.getAngleAxis=function(){return this._angleAxis},r.prototype.getRadiusAxis=function(){return this._radiusAxis},r.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},r.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},r.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},r.prototype.dataToPoint=function(e,t){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)])},r.prototype.pointToData=function(e,t){var i=this.pointToCoord(e);return[this._radiusAxis.radiusToData(i[0],t),this._angleAxis.angleToData(i[1],t)]},r.prototype.pointToCoord=function(e){var t=e[0]-this.cx,i=e[1]-this.cy,n=this.getAngleAxis(),a=n.getExtent(),s=Math.min(a[0],a[1]),o=Math.max(a[0],a[1]);n.inverse?s=o-360:o=s+360;var l=Math.sqrt(t*t+i*i);t/=l,i/=l;for(var u=Math.atan2(-i,t)/Math.PI*180,c=uo;)u+=c*360;return[l,u]},r.prototype.coordToPoint=function(e){var t=e[0],i=e[1]/180*Math.PI,n=Math.cos(i)*t+this.cx,a=-Math.sin(i)*t+this.cy;return[n,a]},r.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis(),i=t.getExtent().slice();i[0]>i[1]&&i.reverse();var n=e.getExtent(),a=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:i[0],r:i[1],startAngle:-n[0]*a,endAngle:-n[1]*a,clockwise:e.inverse,contain:function(s,o){var l=s-this.cx,u=o-this.cy,c=l*l+u*u-1e-4,h=this.r,d=this.r0;return c<=h*h&&c>=d*d}}},r.prototype.convertToPixel=function(e,t,i){var n=F8(t);return n===this?this.dataToPoint(i):null},r.prototype.convertFromPixel=function(e,t,i){var n=F8(t);return n===this?this.pointToData(i):null},r}();function F8(r){var e=r.seriesModel,t=r.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function kSe(r,e,t){var i=e.get("center"),n=t.getWidth(),a=t.getHeight();r.cx=ce(i[0],n),r.cy=ce(i[1],a);var s=r.getRadiusAxis(),o=Math.min(n,a)/2,l=e.get("radius");l==null?l=[0,"100%"]:ie(l)||(l=[0,l]);var u=[ce(l[0],o),ce(l[1],o)];s.inverse?s.setExtent(u[1],u[0]):s.setExtent(u[0],u[1])}function RSe(r,e){var t=this,i=t.getAngleAxis(),n=t.getRadiusAxis();if(i.scale.setExtent(1/0,-1/0),n.scale.setExtent(1/0,-1/0),r.eachSeries(function(o){if(o.coordinateSystem===t){var l=o.getData();R(qy(l,"radius"),function(u){n.scale.unionExtentFromData(l,u)}),R(qy(l,"angle"),function(u){i.scale.unionExtentFromData(l,u)})}}),hf(i.scale,i.model),hf(n.scale,n.model),i.type==="category"&&!i.onBand){var a=i.getExtent(),s=360/i.scale.count();i.inverse?a[1]+=s:a[1]-=s,i.setExtent(a[0],a[1])}}function OSe(r){return r.mainType==="angleAxis"}function U8(r,e){var t;if(r.type=e.get("type"),r.scale=E1(e),r.onBand=e.get("boundaryGap")&&r.type==="category",r.inverse=e.get("inverse"),OSe(e)){r.inverse=r.inverse!==e.get("clockwise");var i=e.get("startAngle"),n=(t=e.get("endAngle"))!==null&&t!==void 0?t:i+(r.inverse?-360:360);r.setExtent(i,n)}e.axis=r,r.model=e}var NSe={dimensions:Aj,create:function(r,e){var t=[];return r.eachComponent("polar",function(i,n){var a=new LSe(n+"");a.update=RSe;var s=a.getRadiusAxis(),o=a.getAngleAxis(),l=i.findAxisModel("radiusAxis"),u=i.findAxisModel("angleAxis");U8(s,l),U8(o,u),kSe(a,i,e),t.push(a),i.coordinateSystem=a,a.model=i}),r.eachSeries(function(i){if(i.get("coordinateSystem")==="polar"){var n=i.getReferringComponents("polar",mr).models[0];i.coordinateSystem=n.coordinateSystem}}),t}},BSe=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function jm(r,e,t){e[1]>e[0]&&(e=e.slice().reverse());var i=r.coordToPoint([e[0],t]),n=r.coordToPoint([e[1],t]);return{x1:i[0],y1:i[1],x2:n[0],y2:n[1]}}function Xm(r){var e=r.getRadiusAxis();return e.inverse?0:1}function V8(r){var e=r[0],t=r[r.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&r.pop()}var FSe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,i){if(this.group.removeAll(),!!t.get("show")){var n=t.axis,a=n.polar,s=a.getRadiusAxis().getExtent(),o=n.getTicksCoords(),l=n.getMinorTicksCoords(),u=oe(n.getViewLabels(),function(c){c=Ee(c);var h=n.scale,d=h.type==="ordinal"?h.getRawOrdinalNumber(c.tickValue):c.tickValue;return c.coord=n.dataToCoord(d),c});V8(u),V8(o),R(BSe,function(c){t.get([c,"show"])&&(!n.scale.isBlank()||c==="axisLine")&&USe[c](this.group,t,a,o,l,s,u)},this)}},e.type="angleAxis",e}(pc),USe={axisLine:function(r,e,t,i,n,a){var s=e.getModel(["axisLine","lineStyle"]),o=t.getAngleAxis(),l=Math.PI/180,u=o.getExtent(),c=Xm(t),h=c?0:1,d,f=Math.abs(u[1]-u[0])===360?"Circle":"Arc";a[h]===0?d=new cc[f]({shape:{cx:t.cx,cy:t.cy,r:a[c],startAngle:-u[0]*l,endAngle:-u[1]*l,clockwise:o.inverse},style:s.getLineStyle(),z2:1,silent:!0}):d=new Jv({shape:{cx:t.cx,cy:t.cy,r:a[c],r0:a[h]},style:s.getLineStyle(),z2:1,silent:!0}),d.style.fill=null,r.add(d)},axisTick:function(r,e,t,i,n,a){var s=e.getModel("axisTick"),o=(s.get("inside")?-1:1)*s.get("length"),l=a[Xm(t)],u=oe(i,function(c){return new kr({shape:jm(t,[l,l+o],c.coord)})});r.add(Fn(u,{style:Ce(s.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(r,e,t,i,n,a){if(n.length){for(var s=e.getModel("axisTick"),o=e.getModel("minorTick"),l=(s.get("inside")?-1:1)*o.get("length"),u=a[Xm(t)],c=[],h=0;hm?"left":"right",b=Math.abs(g[1]-y)/v<.3?"middle":g[1]>y?"top":"bottom";if(o&&o[p]){var T=o[p];De(T)&&T.textStyle&&(f=new yt(T.textStyle,l,l.ecModel))}var x=new lt({silent:Ci.isLabelSilent(e),style:kt(f,{x:g[0],y:g[1],fill:f.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:h.formattedLabel,align:_,verticalAlign:b})});if(r.add(x),c){var C=Ci.makeAxisEventDataBase(e);C.targetType="axisLabel",C.value=h.rawLabel,ke(x).eventData=C}},this)},splitLine:function(r,e,t,i,n,a){var s=e.getModel("splitLine"),o=s.getModel("lineStyle"),l=o.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],h=0;h=0?"p":"n",F=I;T&&(i[c][O]||(i[c][O]={p:I,n:I}),F=i[c][O][B]);var U=void 0,$=void 0,q=void 0,Z=void 0;if(p.dim==="radius"){var te=p.dataToCoord(N)-I,Q=l.dataToCoord(O);Math.abs(te)=Z})}}})}function qSe(r){var e={};R(r,function(i,n){var a=i.getData(),s=i.coordinateSystem,o=s.getBaseAxis(),l=Ej(s,o),u=o.getExtent(),c=o.type==="category"?o.getBandWidth():Math.abs(u[1]-u[0])/a.count(),h=e[l]||{bandWidth:c,remainedWidth:c,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},d=h.stacks;e[l]=h;var f=Dj(i);d[f]||h.autoWidthCount++,d[f]=d[f]||{width:0,maxWidth:0};var p=ce(i.get("barWidth"),c),v=ce(i.get("barMaxWidth"),c),g=i.get("barGap"),m=i.get("barCategoryGap");p&&!d[f].width&&(p=Math.min(h.remainedWidth,p),d[f].width=p,h.remainedWidth-=p),v&&(d[f].maxWidth=v),g!=null&&(h.gap=g),m!=null&&(h.categoryGap=m)});var t={};return R(e,function(i,n){t[n]={};var a=i.stacks,s=i.bandWidth,o=ce(i.categoryGap,s),l=ce(i.gap,1),u=i.remainedWidth,c=i.autoWidthCount,h=(u-o)/(c+(c-1)*l);h=Math.max(h,0),R(a,function(v,g){var m=v.maxWidth;m&&m=t.y&&e[1]<=t.y+t.height:i.contain(i.toLocalCoord(e[1]))&&e[0]>=t.y&&e[0]<=t.y+t.height},r.prototype.pointToData=function(e){var t=this.getAxis();return[t.coordToData(t.toLocalCoord(e[t.orient==="horizontal"?0:1]))]},r.prototype.dataToPoint=function(e){var t=this.getAxis(),i=this.getRect(),n=[],a=t.orient==="horizontal"?0:1;return e instanceof Array&&(e=e[0]),n[a]=t.toGlobalCoord(t.dataToCoord(+e)),n[1-a]=a===0?i.y+i.height/2:i.x+i.width/2,n},r.prototype.convertToPixel=function(e,t,i){var n=z8(t);return n===this?this.dataToPoint(i):null},r.prototype.convertFromPixel=function(e,t,i){var n=z8(t);return n===this?this.pointToData(i):null},r}();function z8(r){var e=r.seriesModel,t=r.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function iTe(r,e){var t=[];return r.eachComponent("singleAxis",function(i,n){var a=new rTe(i,r,e);a.name="single_"+n,a.resize(i,e),i.coordinateSystem=a,t.push(a)}),r.eachSeries(function(i){if(i.get("coordinateSystem")==="singleAxis"){var n=i.getReferringComponents("singleAxis",mr).models[0];i.coordinateSystem=n&&n.coordinateSystem}}),t}var nTe={create:iTe,dimensions:Ij},G8=["x","y"],aTe=["width","height"],sTe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,i,n,a,s){var o=n.axis,l=o.coordinateSystem,u=ZS(l,1-s_(o)),c=l.dataToPoint(i)[0],h=a.get("type");if(h&&h!=="none"){var d=PE(a),f=oTe[h](o,c,u);f.style=d,t.graphicKey=f.type,t.pointer=f}var p=jw(n);Tj(i,t,p,n,a,s)},e.prototype.getHandleTransform=function(t,i,n){var a=jw(i,{labelInside:!1});a.labelMargin=n.get(["handle","margin"]);var s=ME(i.axis,t,a);return{x:s[0],y:s[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,i,n,a){var s=n.axis,o=s.coordinateSystem,l=s_(s),u=ZS(o,l),c=[t.x,t.y];c[l]+=i[l],c[l]=Math.min(u[1],c[l]),c[l]=Math.max(u[0],c[l]);var h=ZS(o,1-l),d=(h[1]+h[0])/2,f=[d,d];return f[l]=c[l],{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:f,tooltipOption:{verticalAlign:"middle"}}},e}(IE),oTe={line:function(r,e,t){var i=LE([e,t[0]],[e,t[1]],s_(r));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(r,e,t){var i=r.getBandWidth(),n=t[1]-t[0];return{type:"Rect",shape:xj([e-i/2,t[0]],[i,n],s_(r))}}};function s_(r){return r.isHorizontal()?0:1}function ZS(r,e){var t=r.getRect();return[t[G8[e]],t[G8[e]]+t[aTe[e]]]}var lTe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="single",e}($t);function uTe(r){Ze(gg),pc.registerAxisPointerClass("SingleAxisPointer",sTe),r.registerComponentView(lTe),r.registerComponentView(JSe),r.registerComponentModel(M0),df(r,"single",M0,M0.defaultOption),r.registerCoordinateSystem("single",nTe)}var cTe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,i,n){var a=Bf(t);r.prototype.init.apply(this,arguments),H8(t,a)},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),H8(this.option,t)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e}(tt);function H8(r,e){var t=r.cellSize,i;ie(t)?i=t:i=r.cellSize=[t,t],i.length===1&&(i[1]=i[0]);var n=oe([0,1],function(a){return Lhe(e,a)&&(i[a]="auto"),i[a]!=null&&i[a]!=="auto"});il(r,e,{type:"box",ignoreSize:n})}var hTe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){var a=this.group;a.removeAll();var s=t.coordinateSystem,o=s.getRangeInfo(),l=s.getOrient(),u=i.getLocaleModel();this._renderDayRect(t,o,a),this._renderLines(t,o,l,a),this._renderYearText(t,o,l,a),this._renderMonthText(t,u,l,a),this._renderWeekText(t,u,o,l,a)},e.prototype._renderDayRect=function(t,i,n){for(var a=t.coordinateSystem,s=t.getModel("itemStyle").getItemStyle(),o=a.getCellWidth(),l=a.getCellHeight(),u=i.start.time;u<=i.end.time;u=a.getNextNDay(u,1).time){var c=a.dataToRect([u],!1).tl,h=new st({shape:{x:c[0],y:c[1],width:o,height:l},cursor:"default",style:s});n.add(h)}},e.prototype._renderLines=function(t,i,n,a){var s=this,o=t.coordinateSystem,l=t.getModel(["splitLine","lineStyle"]).getLineStyle(),u=t.get(["splitLine","show"]),c=l.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var h=i.start,d=0;h.time<=i.end.time;d++){p(h.formatedDate),d===0&&(h=o.getDateInfo(i.start.y+"-"+i.start.m));var f=h.date;f.setMonth(f.getMonth()+1),h=o.getDateInfo(f)}p(o.getNextNDay(i.end.time,1).formatedDate);function p(v){s._firstDayOfMonth.push(o.getDateInfo(v)),s._firstDayPoints.push(o.dataToRect([v],!1).tl);var g=s._getLinePointsOfOneWeek(t,v,n);s._tlpoints.push(g[0]),s._blpoints.push(g[g.length-1]),u&&s._drawSplitline(g,l,a)}u&&this._drawSplitline(s._getEdgesPoints(s._tlpoints,c,n),l,a),u&&this._drawSplitline(s._getEdgesPoints(s._blpoints,c,n),l,a)},e.prototype._getEdgesPoints=function(t,i,n){var a=[t[0].slice(),t[t.length-1].slice()],s=n==="horizontal"?0:1;return a[0][s]=a[0][s]-i/2,a[1][s]=a[1][s]+i/2,a},e.prototype._drawSplitline=function(t,i,n){var a=new Pi({z2:20,shape:{points:t},style:i});n.add(a)},e.prototype._getLinePointsOfOneWeek=function(t,i,n){for(var a=t.coordinateSystem,s=a.getDateInfo(i),o=[],l=0;l<7;l++){var u=a.getNextNDay(s.time,l),c=a.dataToRect([u.time],!1);o[2*u.day]=c.tl,o[2*u.day+1]=c[n==="horizontal"?"bl":"tr"]}return o},e.prototype._formatterLabel=function(t,i){return pe(t)&&t?Ihe(t,i):we(t)?t(i):i.nameMap},e.prototype._yearTextPositionControl=function(t,i,n,a,s){var o=i[0],l=i[1],u=["center","bottom"];a==="bottom"?(l+=s,u=["center","top"]):a==="left"?o-=s:a==="right"?(o+=s,u=["center","top"]):l-=s;var c=0;return(a==="left"||a==="right")&&(c=Math.PI/2),{rotation:c,x:o,y:l,style:{align:u[0],verticalAlign:u[1]}}},e.prototype._renderYearText=function(t,i,n,a){var s=t.getModel("yearLabel");if(s.get("show")){var o=s.get("margin"),l=s.get("position");l||(l=n!=="horizontal"?"top":"left");var u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],c=(u[0][0]+u[1][0])/2,h=(u[0][1]+u[1][1])/2,d=n==="horizontal"?0:1,f={top:[c,u[d][1]],bottom:[c,u[1-d][1]],left:[u[1-d][0],h],right:[u[d][0],h]},p=i.start.y;+i.end.y>+i.start.y&&(p=p+"-"+i.end.y);var v=s.get("formatter"),g={start:i.start.y,end:i.end.y,nameMap:p},m=this._formatterLabel(v,g),y=new lt({z2:30,style:kt(s,{text:m})});y.attr(this._yearTextPositionControl(y,f[l],n,l,o)),a.add(y)}},e.prototype._monthTextPositionControl=function(t,i,n,a,s){var o="left",l="top",u=t[0],c=t[1];return n==="horizontal"?(c=c+s,i&&(o="center"),a==="start"&&(l="bottom")):(u=u+s,i&&(l="middle"),a==="start"&&(o="right")),{x:u,y:c,align:o,verticalAlign:l}},e.prototype._renderMonthText=function(t,i,n,a){var s=t.getModel("monthLabel");if(s.get("show")){var o=s.get("nameMap"),l=s.get("margin"),u=s.get("position"),c=s.get("align"),h=[this._tlpoints,this._blpoints];(!o||pe(o))&&(o&&(i=tw(o)||i),o=i.get(["time","monthAbbr"])||[]);var d=u==="start"?0:1,f=n==="horizontal"?0:1;l=u==="start"?-l:l;for(var p=c==="center",v=0;v=n.start.time&&i.timeo.end.time&&t.reverse(),t},r.prototype._getRangeInfo=function(e){var t=[this.getDateInfo(e[0]),this.getDateInfo(e[1])],i;t[0].time>t[1].time&&(i=!0,t.reverse());var n=Math.floor(t[1].time/QS)-Math.floor(t[0].time/QS)+1,a=new Date(t[0].time),s=a.getDate(),o=t[1].date.getDate();a.setDate(s+n-1);var l=a.getDate();if(l!==o)for(var u=a.getTime()-t[1].time>0?1:-1;(l=a.getDate())!==o&&(a.getTime()-t[1].time)*u>0;)n-=u,a.setDate(l-u);var c=Math.floor((n+t[0].day+6)/7),h=i?-c+1:c-1;return i&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:n,weeks:c,nthWeek:h,fweek:t[0].day,lweek:t[1].day}},r.prototype._getDateByWeeksAndDay=function(e,t,i){var n=this._getRangeInfo(i);if(e>n.weeks||e===0&&tn.lweek)return null;var a=(e-1)*7-n.fweek+t,s=new Date(n.start.time);return s.setDate(+n.start.d+a),this.getDateInfo(s)},r.create=function(e,t){var i=[];return e.eachComponent("calendar",function(n){var a=new r(n);i.push(a),n.coordinateSystem=a}),e.eachSeries(function(n){n.get("coordinateSystem")==="calendar"&&(n.coordinateSystem=i[n.get("calendarIndex")||0])}),i},r.dimensions=["time","value"],r}();function $8(r){var e=r.calendarModel,t=r.seriesModel,i=e?e.coordinateSystem:t?t.coordinateSystem:null;return i}function dTe(r){r.registerComponentModel(cTe),r.registerComponentView(hTe),r.registerCoordinateSystem("calendar",fTe)}function pTe(r,e){var t=r.existing;if(e.id=r.keyInfo.id,!e.type&&t&&(e.type=t.type),e.parentId==null){var i=e.parentOption;i?e.parentId=i.id:t&&(e.parentId=t.parentId)}e.parentOption=null}function W8(r,e){var t;return R(e,function(i){r[i]!=null&&r[i]!=="auto"&&(t=!0)}),t}function vTe(r,e,t){var i=J({},t),n=r[e],a=t.$action||"merge";a==="merge"?n?(We(n,i,!0),il(n,i,{ignoreSize:!0}),SH(t,n),Ym(t,n),Ym(t,n,"shape"),Ym(t,n,"style"),Ym(t,n,"extra"),t.clipPath=n.clipPath):r[e]=i:a==="replace"?r[e]=i:a==="remove"&&n&&(r[e]=null)}var Pj=["transition","enterFrom","leaveTo"],gTe=Pj.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function Ym(r,e,t){if(t&&(!r[t]&&e[t]&&(r[t]={}),r=r[t],e=e[t]),!(!r||!e))for(var i=t?Pj:gTe,n=0;n=0;c--){var h=n[c],d=wr(h.id,null),f=d!=null?s.get(d):null;if(f){var p=f.parent,m=On(p),y=p===a?{width:o,height:l}:{width:m.width,height:m.height},_={},b=_1(f,h,y,null,{hv:h.hv,boundingMode:h.bounding},_);if(!On(f).isNew&&b){for(var T=h.transition,x={},C=0;C=0)?x[D]=I:f[D]=I}ct(f,x,t,0)}else f.attr(_)}}},e.prototype._clear=function(){var t=this,i=this._elMap;i.each(function(n){L0(n,On(n).option,i,t._lastGraphicModel)}),this._elMap=be()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e}($t);function Xw(r){var e=_e(q8,r)?q8[r]:pD(r),t=new e({});return On(t).type=r,t}function j8(r,e,t,i){var n=Xw(t);return e.add(n),i.set(r,n),On(n).id=r,On(n).isNew=!0,n}function L0(r,e,t,i){var n=r&&r.parent;n&&(r.type==="group"&&r.traverse(function(a){L0(a,e,t,i)}),O1(r,e,i),t.removeKey(On(r).id))}function X8(r,e,t,i){r.isGroup||R([["cursor",Yn.prototype.cursor],["zlevel",i||0],["z",t||0],["z2",0]],function(n){var a=n[0];_e(e,a)?r[a]=Be(e[a],n[1]):r[a]==null&&(r[a]=n[1])}),R(rt(e),function(n){if(n.indexOf("on")===0){var a=e[n];r[n]=we(a)?a:null}}),_e(e,"draggable")&&(r.draggable=e.draggable),e.name!=null&&(r.name=e.name),e.id!=null&&(r.id=e.id)}function bTe(r){return r=J({},r),R(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(bH),function(e){delete r[e]}),r}function STe(r,e,t){var i=ke(r).eventData;!r.silent&&!r.ignore&&!i&&(i=ke(r).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:r.name}),i&&(i.info=t.info)}function TTe(r){r.registerComponentModel(yTe),r.registerComponentView(_Te),r.registerPreprocessor(function(e){var t=e.graphic;ie(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var Y8=["x","y","radius","angle","single"],xTe=["cartesian2d","polar","singleAxis"];function wTe(r){var e=r.get("coordinateSystem");return Xe(xTe,e)>=0}function Go(r){return r+"Axis"}function CTe(r,e){var t=be(),i=[],n=be();r.eachComponent({mainType:"dataZoom",query:e},function(c){n.get(c.uid)||o(c)});var a;do a=!1,r.eachComponent("dataZoom",s);while(a);function s(c){!n.get(c.uid)&&l(c)&&(o(c),a=!0)}function o(c){n.set(c.uid,!0),i.push(c),u(c)}function l(c){var h=!1;return c.eachTargetAxis(function(d,f){var p=t.get(d);p&&p[f]&&(h=!0)}),h}function u(c){c.eachTargetAxis(function(h,d){(t.get(h)||t.set(h,[]))[d]=!0})}return i}function Mj(r){var e=r.ecModel,t={infoList:[],infoMap:be()};return r.eachTargetAxis(function(i,n){var a=e.getComponent(Go(i),n);if(a){var s=a.getCoordSysModel();if(s){var o=s.uid,l=t.infoMap.get(o);l||(l={model:s,axisModels:[]},t.infoList.push(l),t.infoMap.set(o,l)),l.axisModels.push(a)}}}),t}var JS=function(){function r(){this.indexList=[],this.indexMap=[]}return r.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},r}(),Lv=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}return e.prototype.init=function(t,i,n){var a=K8(t);this.settledOption=a,this.mergeDefaultAndTheme(t,n),this._doInit(a)},e.prototype.mergeOption=function(t){var i=K8(t);We(this.option,t,!0),We(this.settledOption,i,!0),this._doInit(i)},e.prototype._doInit=function(t){var i=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var n=this.settledOption;R([["start","startValue"],["end","endValue"]],function(a,s){this._rangePropMode[s]==="value"&&(i[a[0]]=n[a[0]]=null)},this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),i=this._targetAxisInfoMap=be(),n=this._fillSpecifiedTargetAxis(i);n?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(i,this._orient)),this._noTarget=!0,i.each(function(a){a.indexList.length&&(this._noTarget=!1)},this)},e.prototype._fillSpecifiedTargetAxis=function(t){var i=!1;return R(Y8,function(n){var a=this.getReferringComponents(Go(n),yue);if(a.specified){i=!0;var s=new JS;R(a.models,function(o){s.add(o.componentIndex)}),t.set(n,s)}},this),i},e.prototype._fillAutoTargetAxisByOrient=function(t,i){var n=this.ecModel,a=!0;if(a){var s=i==="vertical"?"y":"x",o=n.findComponents({mainType:s+"Axis"});l(o,s)}if(a){var o=n.findComponents({mainType:"singleAxis",filter:function(c){return c.get("orient",!0)===i}});l(o,"single")}function l(u,c){var h=u[0];if(h){var d=new JS;if(d.add(h.componentIndex),t.set(c,d),a=!1,c==="x"||c==="y"){var f=h.getReferringComponents("grid",mr).models[0];f&&R(u,function(p){h.componentIndex!==p.componentIndex&&f===p.getReferringComponents("grid",mr).models[0]&&d.add(p.componentIndex)})}}}a&&R(Y8,function(u){if(a){var c=n.findComponents({mainType:Go(u),filter:function(d){return d.get("type",!0)==="category"}});if(c[0]){var h=new JS;h.add(c[0].componentIndex),t.set(u,h),a=!1}}},this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis(function(i){!t&&(t=i)},this),t==="y"?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var i=this.ecModel.option;this.option.throttle=i.animation&&i.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var i=this._rangePropMode,n=this.get("rangeMode");R([["start","startValue"],["end","endValue"]],function(a,s){var o=t[a[0]]!=null,l=t[a[1]]!=null;o&&!l?i[s]="percent":!o&&l?i[s]="value":n?i[s]=n[s]:o&&(i[s]="percent")})},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis(function(i,n){t==null&&(t=this.ecModel.getComponent(Go(i),n))},this),t},e.prototype.eachTargetAxis=function(t,i){this._targetAxisInfoMap.each(function(n,a){R(n.indexList,function(s){t.call(i,a,s)})})},e.prototype.getAxisProxy=function(t,i){var n=this.getAxisModel(t,i);if(n)return n.__dzAxisProxy},e.prototype.getAxisModel=function(t,i){var n=this._targetAxisInfoMap.get(t);if(n&&n.indexMap[i])return this.ecModel.getComponent(Go(t),i)},e.prototype.setRawRange=function(t){var i=this.option,n=this.settledOption;R([["start","startValue"],["end","endValue"]],function(a){(t[a[0]]!=null||t[a[1]]!=null)&&(i[a[0]]=n[a[0]]=t[a[0]],i[a[1]]=n[a[1]]=t[a[1]])},this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var i=this.option;R(["start","startValue","end","endValue"],function(n){i[n]=t[n]})},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},e.prototype.getValueRange=function(t,i){if(t==null&&i==null){var n=this.findRepresentativeAxisProxy();if(n)return n.getDataValueWindow()}else return this.getAxisProxy(t,i).getDataValueWindow()},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return t.__dzAxisProxy;for(var i,n=this._targetAxisInfoMap.keys(),a=0;as[1];if(_&&!b&&!T)return!0;_&&(g=!0),b&&(p=!0),T&&(v=!0)}return g&&p&&v})}else oh(c,function(f){if(a==="empty")l.setData(u=u.map(f,function(v){return o(v)?v:NaN}));else{var p={};p[f]=s,u.selectRange(p)}});oh(c,function(f){u.setApproximateExtent(s,f)})}});function o(l){return l>=s[0]&&l<=s[1]}},r.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,i=this._dataExtent;oh(["min","max"],function(n){var a=t.get(n+"Span"),s=t.get(n+"ValueSpan");s!=null&&(s=this.getAxisModel().axis.scale.parse(s)),s!=null?a=bt(i[0]+s,i,[0,100],!0):a!=null&&(s=bt(a,[0,100],i,!0)-i[0]),e[n+"Span"]=a,e[n+"ValueSpan"]=s},this)},r.prototype._setAxisModel=function(){var e=this.getAxisModel(),t=this._percentWindow,i=this._valueWindow;if(t){var n=uG(i,[0,500]);n=Math.min(n,20);var a=e.axis.scale.rawExtentInfo;t[0]!==0&&a.setDeterminedMinMax("min",+i[0].toFixed(n)),t[1]!==100&&a.setDeterminedMinMax("max",+i[1].toFixed(n)),a.freeze()}},r}();function ITe(r,e,t){var i=[1/0,-1/0];oh(t,function(s){lve(i,s.getData(),e)});var n=r.getAxisModel(),a=Y$(n.axis.scale,n,i).calculate();return[a.min,a.max]}var PTe={getTargetSeries:function(r){function e(n){r.eachComponent("dataZoom",function(a){a.eachTargetAxis(function(s,o){var l=r.getComponent(Go(s),o);n(s,o,l,a)})})}e(function(n,a,s,o){s.__dzAxisProxy=null});var t=[];e(function(n,a,s,o){s.__dzAxisProxy||(s.__dzAxisProxy=new ETe(n,a,o,r),t.push(s.__dzAxisProxy))});var i=be();return R(t,function(n){R(n.getTargetSeriesModels(),function(a){i.set(a.uid,a)})}),i},overallReset:function(r,e){r.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(i,n){t.getAxisProxy(i,n).reset(t)}),t.eachTargetAxis(function(i,n){t.getAxisProxy(i,n).filterData(t,e)})}),r.eachComponent("dataZoom",function(t){var i=t.findRepresentativeAxisProxy();if(i){var n=i.getDataPercentWindow(),a=i.getDataValueWindow();t.setCalculatedRange({start:n[0],end:n[1],startValue:a[0],endValue:a[1]})}})}};function MTe(r){r.registerAction("dataZoom",function(e,t){var i=CTe(t,e);R(i,function(n){n.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var Q8=!1;function BE(r){Q8||(Q8=!0,r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,PTe),MTe(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function LTe(r){r.registerComponentModel(ATe),r.registerComponentView(DTe),BE(r)}var Bn=function(){function r(){}return r}(),Lj={};function lh(r,e){Lj[r]=e}function kj(r){return Lj[r]}var kTe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){r.prototype.optionUpdated.apply(this,arguments);var t=this.ecModel;R(this.option.feature,function(i,n){var a=kj(n);a&&(a.getDefaultOption&&(a.defaultOption=a.getDefaultOption(t)),We(i,a.defaultOption))})},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1,position:"bottom"}},e}(tt);function RTe(r,e,t){var i=e.getBoxLayoutParams(),n=e.get("padding"),a={width:t.getWidth(),height:t.getHeight()},s=Ar(i,a,n);Hu(e.get("orient"),r,e.get("itemGap"),s.width,s.height),_1(r,i,a,n)}function Rj(r,e){var t=Nf(e.get("padding")),i=e.getItemStyle(["color","opacity"]);return i.fill=e.get("backgroundColor"),r=new st({shape:{x:r.x-t[3],y:r.y-t[0],width:r.width+t[1]+t[3],height:r.height+t[0]+t[2],r:e.get("borderRadius")},style:i,silent:!0,z2:-1}),r}var OTe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,i,n,a){var s=this.group;if(s.removeAll(),!t.get("show"))return;var o=+t.get("itemSize"),l=t.get("orient")==="vertical",u=t.get("feature")||{},c=this._features||(this._features={}),h=[];R(u,function(p,v){h.push(v)}),new Xs(this._featureNames||[],h).add(d).update(d).remove(Ue(d,null)).execute(),this._featureNames=h;function d(p,v){var g=h[p],m=h[v],y=u[g],_=new yt(y,t,t.ecModel),b;if(a&&a.newTitle!=null&&a.featureName===g&&(y.title=a.newTitle),g&&!m){if(NTe(g))b={onclick:_.option.onclick,featureName:g};else{var T=kj(g);if(!T)return;b=new T}c[g]=b}else if(b=c[m],!b)return;b.uid=Of("toolbox-feature"),b.model=_,b.ecModel=i,b.api=n;var x=b instanceof Bn;if(!g&&m){x&&b.dispose&&b.dispose(i,n);return}if(!_.get("show")||x&&b.unusable){x&&b.remove&&b.remove(i,n);return}f(_,b,g),_.setIconStatus=function(C,D){var I=this.option,M=this.iconPaths;I.iconStatus=I.iconStatus||{},I.iconStatus[C]=D,M[C]&&(D==="emphasis"?qs:js)(M[C])},b instanceof Bn&&b.render&&b.render(_,i,n,a)}function f(p,v,g){var m=p.getModel("iconStyle"),y=p.getModel(["emphasis","iconStyle"]),_=v instanceof Bn&&v.getIcons?v.getIcons():p.get("icon"),b=p.get("title")||{},T,x;pe(_)?(T={},T[g]=_):T=_,pe(b)?(x={},x[g]=b):x=b;var C=p.iconPaths={};R(T,function(D,I){var M=ig(D,{},{x:-o/2,y:-o/2,width:o,height:o});M.setStyle(m.getItemStyle());var L=M.ensureState("emphasis");L.style=y.getItemStyle();var N=new lt({style:{text:x[I],align:y.get("textAlign"),borderRadius:y.get("textBorderRadius"),padding:y.get("textPadding"),fill:null,font:vD({fontStyle:y.get("textFontStyle"),fontFamily:y.get("textFontFamily"),fontSize:y.get("textFontSize"),fontWeight:y.get("textFontWeight")},i)},ignore:!0});M.setTextContent(N),kf({el:M,componentModel:t,itemName:I,formatterParamsExtra:{title:x[I]}}),M.__title=x[I],M.on("mouseover",function(){var O=y.getItemStyle(),B=l?t.get("right")==null&&t.get("left")!=="right"?"right":"left":t.get("bottom")==null&&t.get("top")!=="bottom"?"bottom":"top";N.setStyle({fill:y.get("textFill")||O.fill||O.stroke||"#000",backgroundColor:y.get("textBackgroundColor")}),M.setTextConfig({position:y.get("textPosition")||B}),N.ignore=!t.get("showTitle"),n.enterEmphasis(this)}).on("mouseout",function(){p.get(["iconStatus",I])!=="emphasis"&&n.leaveEmphasis(this),N.hide()}),(p.get(["iconStatus",I])==="emphasis"?qs:js)(M),s.add(M),M.on("click",ge(v.onclick,v,i,n,I)),C[I]=M})}RTe(s,t,n),s.add(Rj(s.getBoundingRect(),t)),l||s.eachChild(function(p){var v=p.__title,g=p.ensureState("emphasis"),m=g.textConfig||(g.textConfig={}),y=p.getTextContent(),_=y&&y.ensureState("emphasis");if(_&&!we(_)&&v){var b=_.style||(_.style={}),T=Kv(v,lt.makeFont(b)),x=p.x+s.x,C=p.y+s.y+o,D=!1;C+T.height>n.getHeight()&&(m.position="top",D=!0);var I=D?-5-T.height:o+10;x+T.width/2>n.getWidth()?(m.position=["100%",I],b.align="right"):x-T.width/2<0&&(m.position=[0,I],b.align="left")}})},e.prototype.updateView=function(t,i,n,a){R(this._features,function(s){s instanceof Bn&&s.updateView&&s.updateView(s.model,i,n,a)})},e.prototype.remove=function(t,i){R(this._features,function(n){n instanceof Bn&&n.remove&&n.remove(t,i)}),this.group.removeAll()},e.prototype.dispose=function(t,i){R(this._features,function(n){n instanceof Bn&&n.dispose&&n.dispose(t,i)})},e.type="toolbox",e}($t);function NTe(r){return r.indexOf("my")===0}var BTe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,i){var n=this.model,a=n.get("name")||t.get("title.0.text")||"echarts",s=i.getZr().painter.getType()==="svg",o=s?"svg":n.get("type",!0)||"png",l=i.getConnectedDataURL({type:o,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",connectedBackgroundColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")}),u=et.browser;if(typeof MouseEvent=="function"&&(u.newEdge||!u.ie&&!u.edge)){var c=document.createElement("a");c.download=a+"."+o,c.target="_blank",c.href=l;var h=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});c.dispatchEvent(h)}else if(window.navigator.msSaveOrOpenBlob||s){var d=l.split(","),f=d[0].indexOf("base64")>-1,p=s?decodeURIComponent(d[1]):d[1];f&&(p=window.atob(p));var v=a+"."+o;if(window.navigator.msSaveOrOpenBlob){for(var g=p.length,m=new Uint8Array(g);g--;)m[g]=p.charCodeAt(g);var y=new Blob([m]);window.navigator.msSaveOrOpenBlob(y,v)}else{var _=document.createElement("iframe");document.body.appendChild(_);var b=_.contentWindow,T=b.document;T.open("image/svg+xml","replace"),T.write(p),T.close(),b.focus(),T.execCommand("SaveAs",!0,v),document.body.removeChild(_)}}else{var x=n.get("lang"),C='',D=window.open();D.document.write(C),D.document.title=a}},e.getDefaultOption=function(t){var i={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return i},e}(Bn),J8="__ec_magicType_stack__",FTe=[["line","bar"],["stack"]],UTe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getIcons=function(){var t=this.model,i=t.get("icon"),n={};return R(t.get("type"),function(a){i[a]&&(n[a]=i[a])}),n},e.getDefaultOption=function(t){var i={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}};return i},e.prototype.onclick=function(t,i,n){var a=this.model,s=a.get(["seriesIndex",n]);if(eR[n]){var o={series:[]},l=function(h){var d=h.subType,f=h.id,p=eR[n](d,f,h,a);p&&(Ce(p,h.option),o.series.push(p));var v=h.coordinateSystem;if(v&&v.type==="cartesian2d"&&(n==="line"||n==="bar")){var g=v.getAxesByScale("ordinal")[0];if(g){var m=g.dim,y=m+"Axis",_=h.getReferringComponents(y,mr).models[0],b=_.componentIndex;o[y]=o[y]||[];for(var T=0;T<=b;T++)o[y][b]=o[y][b]||{};o[y][b].boundaryGap=n==="bar"}}};R(FTe,function(h){Xe(h,n)>=0&&R(h,function(d){a.setIconStatus(d,"normal")})}),a.setIconStatus(n,"emphasis"),t.eachComponent({mainType:"series",query:s==null?null:{seriesIndex:s}},l);var u,c=n;n==="stack"&&(u=We({stack:a.option.title.tiled,tiled:a.option.title.stack},a.option.title),a.get(["iconStatus",n])!=="emphasis"&&(c="tiled")),i.dispatchAction({type:"changeMagicType",currentType:c,newOption:o,newTitle:u,featureName:"magicType"})}},e}(Bn),eR={line:function(r,e,t,i){if(r==="bar")return We({id:e,type:"line",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},i.get(["option","line"])||{},!0)},bar:function(r,e,t,i){if(r==="line")return We({id:e,type:"bar",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},i.get(["option","bar"])||{},!0)},stack:function(r,e,t,i){var n=t.get("stack")===J8;if(r==="line"||r==="bar")return i.setIconStatus("stack",n?"normal":"emphasis"),We({id:e,stack:n?"":J8},i.get(["option","stack"])||{},!0)}};hs({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(r,e){e.mergeOption(r.newOption)});var N1=new Array(60).join("-"),gf=" ";function VTe(r){var e={},t=[],i=[];return r.eachRawSeries(function(n){var a=n.coordinateSystem;if(a&&(a.type==="cartesian2d"||a.type==="polar")){var s=a.getBaseAxis();if(s.type==="category"){var o=s.dim+"_"+s.index;e[o]||(e[o]={categoryAxis:s,valueAxis:a.getOtherAxis(s),series:[]},i.push({axisDim:s.dim,axisIndex:s.index})),e[o].series.push(n)}else t.push(n)}else t.push(n)}),{seriesGroupByCategoryAxis:e,other:t,meta:i}}function zTe(r){var e=[];return R(r,function(t,i){var n=t.categoryAxis,a=t.valueAxis,s=a.dim,o=[" "].concat(oe(t.series,function(f){return f.name})),l=[n.model.getCategories()];R(t.series,function(f){var p=f.getRawData();l.push(f.getRawData().mapArray(p.mapDimension(s),function(v){return v}))});for(var u=[o.join(gf)],c=0;c=0)return!0}var Yw=new RegExp("["+gf+"]+","g");function WTe(r){for(var e=r.split(/\n+/g),t=o_(e.shift()).split(Yw),i=[],n=oe(t,function(l){return{name:l,data:[]}}),a=0;a=0;a--){var s=t[a];if(s[n])break}if(a<0){var o=r.queryComponents({mainType:"dataZoom",subType:"select",id:n})[0];if(o){var l=o.getPercentRange();t[0][n]={dataZoomId:n,start:l[0],end:l[1]}}}}),t.push(e)}function ZTe(r){var e=FE(r),t=e[e.length-1];e.length>1&&e.pop();var i={};return Oj(t,function(n,a){for(var s=e.length-1;s>=0;s--)if(n=e[s][a],n){i[a]=n;break}}),i}function QTe(r){Nj(r).snapshots=null}function JTe(r){return FE(r).length}function FE(r){var e=Nj(r);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var exe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,i){QTe(t),i.dispatchAction({type:"restore",from:this.uid})},e.getDefaultOption=function(t){var i={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:t.getLocaleModel().get(["toolbox","restore","title"])};return i},e}(Bn);hs({type:"restore",event:"restore",update:"prepareAndUpdate"},function(r,e){e.resetOption("recreate")});var txe=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],UE=function(){function r(e,t,i){var n=this;this._targetInfoList=[];var a=tR(t,e);R(rxe,function(s,o){(!i||!i.include||Xe(i.include,o)>=0)&&s(a,n._targetInfoList)})}return r.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(i,n,a){if((i.coordRanges||(i.coordRanges=[])).push(n),!i.coordRange){i.coordRange=n;var s=eT[i.brushType](0,a,n);i.__rangeOffset={offset:aR[i.brushType](s.values,i.range,[1,1]),xyMinMax:s.xyMinMax}}}),e},r.prototype.matchOutputRanges=function(e,t,i){R(e,function(n){var a=this.findTargetInfo(n,t);a&&a!==!0&&R(a.coordSyses,function(s){var o=eT[n.brushType](1,s,n.range,!0);i(n,o.values,s,t)})},this)},r.prototype.setInputRanges=function(e,t){R(e,function(i){var n=this.findTargetInfo(i,t);if(i.range=i.range||[],n&&n!==!0){i.panelId=n.panelId;var a=eT[i.brushType](0,n.coordSys,i.coordRange),s=i.__rangeOffset;i.range=s?aR[i.brushType](a.values,s.offset,ixe(a.xyMinMax,s.xyMinMax)):a.values}},this)},r.prototype.makePanelOpts=function(e,t){return oe(this._targetInfoList,function(i){var n=i.getPanelRect();return{panelId:i.panelId,defaultBrushType:t?t(i):null,clipPath:$q(n),isTargetByCursor:qq(n,e,i.coordSysModel),getLinearBrushOtherExtent:Wq(n)}})},r.prototype.controlSeries=function(e,t,i){var n=this.findTargetInfo(e,i);return n===!0||n&&Xe(n.coordSyses,t.coordinateSystem)>=0},r.prototype.findTargetInfo=function(e,t){for(var i=this._targetInfoList,n=tR(t,e),a=0;ar[1]&&r.reverse(),r}function tR(r,e){return Lp(r,e,{includeMainTypes:txe})}var rxe={grid:function(r,e){var t=r.xAxisModels,i=r.yAxisModels,n=r.gridModels,a=be(),s={},o={};!t&&!i&&!n||(R(t,function(l){var u=l.axis.grid.model;a.set(u.id,u),s[u.id]=!0}),R(i,function(l){var u=l.axis.grid.model;a.set(u.id,u),o[u.id]=!0}),R(n,function(l){a.set(l.id,l),s[l.id]=!0,o[l.id]=!0}),a.each(function(l){var u=l.coordinateSystem,c=[];R(u.getCartesians(),function(h,d){(Xe(t,h.getAxis("x").model)>=0||Xe(i,h.getAxis("y").model)>=0)&&c.push(h)}),e.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:c[0],coordSyses:c,getPanelRect:iR.grid,xAxisDeclared:s[l.id],yAxisDeclared:o[l.id]})}))},geo:function(r,e){R(r.geoModels,function(t){var i=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:i,coordSyses:[i],getPanelRect:iR.geo})})}},rR=[function(r,e){var t=r.xAxisModel,i=r.yAxisModel,n=r.gridModel;return!n&&t&&(n=t.axis.grid.model),!n&&i&&(n=i.axis.grid.model),n&&n===e.gridModel},function(r,e){var t=r.geoModel;return t&&t===e.geoModel}],iR={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var r=this.coordSys,e=r.getBoundingRect().clone();return e.applyTransform(Gu(r)),e}},eT={lineX:Ue(nR,0),lineY:Ue(nR,1),rect:function(r,e,t,i){var n=r?e.pointToData([t[0][0],t[1][0]],i):e.dataToPoint([t[0][0],t[1][0]],i),a=r?e.pointToData([t[0][1],t[1][1]],i):e.dataToPoint([t[0][1],t[1][1]],i),s=[Kw([n[0],a[0]]),Kw([n[1],a[1]])];return{values:s,xyMinMax:s}},polygon:function(r,e,t,i){var n=[[1/0,-1/0],[1/0,-1/0]],a=oe(t,function(s){var o=r?e.pointToData(s,i):e.dataToPoint(s,i);return n[0][0]=Math.min(n[0][0],o[0]),n[1][0]=Math.min(n[1][0],o[1]),n[0][1]=Math.max(n[0][1],o[0]),n[1][1]=Math.max(n[1][1],o[1]),o});return{values:a,xyMinMax:n}}};function nR(r,e,t,i){var n=t.getAxis(["x","y"][r]),a=Kw(oe([0,1],function(o){return e?n.coordToData(n.toLocalCoord(i[o]),!0):n.toGlobalCoord(n.dataToCoord(i[o]))})),s=[];return s[r]=a,s[1-r]=[NaN,NaN],{values:a,xyMinMax:s}}var aR={lineX:Ue(sR,0),lineY:Ue(sR,1),rect:function(r,e,t){return[[r[0][0]-t[0]*e[0][0],r[0][1]-t[0]*e[0][1]],[r[1][0]-t[1]*e[1][0],r[1][1]-t[1]*e[1][1]]]},polygon:function(r,e,t){return oe(r,function(i,n){return[i[0]-t[0]*e[n][0],i[1]-t[1]*e[n][1]]})}};function sR(r,e,t,i){return[e[0]-i[r]*t[0],e[1]-i[r]*t[1]]}function ixe(r,e){var t=oR(r),i=oR(e),n=[t[0]/i[0],t[1]/i[1]];return isNaN(n[0])&&(n[0]=1),isNaN(n[1])&&(n[1]=1),n}function oR(r){return r?[r[0][1]-r[0][0],r[1][1]-r[1][0]]:[NaN,NaN]}var Zw=R,nxe=due("toolbox-dataZoom_"),axe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,i,n,a){this._brushController||(this._brushController=new pE(n.getZr()),this._brushController.on("brush",ge(this._onBrush,this)).mount()),lxe(t,i,this,a,n),oxe(t,i)},e.prototype.onclick=function(t,i,n){sxe[n].call(this)},e.prototype.remove=function(t,i){this._brushController&&this._brushController.unmount()},e.prototype.dispose=function(t,i){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var i=t.areas;if(!t.isEnd||!i.length)return;var n={},a=this.ecModel;this._brushController.updateCovers([]);var s=new UE(VE(this.model),a,{include:["grid"]});s.matchOutputRanges(i,a,function(u,c,h){if(h.type==="cartesian2d"){var d=u.brushType;d==="rect"?(o("x",h,c[0]),o("y",h,c[1])):o({lineX:"x",lineY:"y"}[d],h,c)}}),KTe(a,n),this._dispatchZoomAction(n);function o(u,c,h){var d=c.getAxis(u),f=d.model,p=l(u,f,a),v=p.findRepresentativeAxisProxy(f).getMinMaxSpan();(v.minValueSpan!=null||v.maxValueSpan!=null)&&(h=vc(0,h.slice(),d.scale.getExtent(),0,v.minValueSpan,v.maxValueSpan)),p&&(n[p.id]={dataZoomId:p.id,startValue:h[0],endValue:h[1]})}function l(u,c,h){var d;return h.eachComponent({mainType:"dataZoom",subType:"select"},function(f){var p=f.getAxisModel(u,c.componentIndex);p&&(d=f)}),d}},e.prototype._dispatchZoomAction=function(t){var i=[];Zw(t,function(n,a){i.push(Ee(n))}),i.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:i})},e.getDefaultOption=function(t){var i={show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}};return i},e}(Bn),sxe={zoom:function(){var r=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:r})},back:function(){this._dispatchZoomAction(ZTe(this.ecModel))}};function VE(r){var e={xAxisIndex:r.get("xAxisIndex",!0),yAxisIndex:r.get("yAxisIndex",!0),xAxisId:r.get("xAxisId",!0),yAxisId:r.get("yAxisId",!0)};return e.xAxisIndex==null&&e.xAxisId==null&&(e.xAxisIndex="all"),e.yAxisIndex==null&&e.yAxisId==null&&(e.yAxisIndex="all"),e}function oxe(r,e){r.setIconStatus("back",JTe(e)>1?"emphasis":"normal")}function lxe(r,e,t,i,n){var a=t._isZoomActive;i&&i.type==="takeGlobalCursor"&&(a=i.key==="dataZoomSelect"?i.dataZoomSelectActive:!1),t._isZoomActive=a,r.setIconStatus("zoom",a?"emphasis":"normal");var s=new UE(VE(r),e,{include:["grid"]}),o=s.makePanelOpts(n,function(l){return l.xAxisDeclared&&!l.yAxisDeclared?"lineX":!l.xAxisDeclared&&l.yAxisDeclared?"lineY":"rect"});t._brushController.setPanels(o).enableBrush(a&&o.length?{brushType:"auto",brushStyle:r.getModel("brushStyle").getItemStyle()}:!1)}Fhe("dataZoom",function(r){var e=r.getComponent("toolbox",0),t=["feature","dataZoom"];if(!e||e.get(t)==null)return;var i=e.getModel(t),n=[],a=VE(i),s=Lp(r,a);Zw(s.xAxisModels,function(l){return o(l,"xAxis","xAxisIndex")}),Zw(s.yAxisModels,function(l){return o(l,"yAxis","yAxisIndex")});function o(l,u,c){var h=l.componentIndex,d={type:"select",$fromToolbox:!0,filterMode:i.get("filterMode",!0)||"filter",id:nxe+u+h};d[c]=h,n.push(d)}return n});function uxe(r){r.registerComponentModel(kTe),r.registerComponentView(OTe),lh("saveAsImage",BTe),lh("magicType",UTe),lh("dataView",XTe),lh("dataZoom",axe),lh("restore",exe),Ze(LTe)}var cxe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},e}(tt);function Bj(r){var e=r.get("confine");return e!=null?!!e:r.get("renderMode")==="richText"}function Fj(r){if(et.domSupported){for(var e=document.documentElement.style,t=0,i=r.length;t-1?(o+="top:50%",l+="translateY(-50%) rotate("+(u=a==="left"?-225:-45)+"deg)"):(o+="left:50%",l+="translateX(-50%) rotate("+(u=a==="top"?225:45)+"deg)");var c=u*Math.PI/180,h=s+n,d=h*Math.abs(Math.cos(c))+h*Math.abs(Math.sin(c)),f=Math.round(((d-Math.SQRT2*n)/2+Math.SQRT2*n-(d-h)/2)*100)/100;o+=";"+a+":-"+f+"px";var p=e+" solid "+n+"px;",v=["position:absolute;width:"+s+"px;height:"+s+"px;z-index:-1;",o+";"+l+";","border-bottom:"+p,"border-right:"+p,"background-color:"+i+";"];return'
'}function mxe(r,e){var t="cubic-bezier(0.23,1,0.32,1)",i=" "+r/2+"s "+t,n="opacity"+i+",visibility"+i;return e||(i=" "+r+"s "+t,n+=et.transformSupported?","+zE+i:",left"+i+",top"+i),dxe+":"+n}function lR(r,e,t){var i=r.toFixed(0)+"px",n=e.toFixed(0)+"px";if(!et.transformSupported)return t?"top:"+n+";left:"+i+";":[["top",n],["left",i]];var a=et.transform3dSupported,s="translate"+(a?"3d":"")+"("+i+","+n+(a?",0":"")+")";return t?"top:0;left:0;"+zE+":"+s+";":[["top",0],["left",0],[Uj,s]]}function yxe(r){var e=[],t=r.get("fontSize"),i=r.getTextColor();i&&e.push("color:"+i),e.push("font:"+r.getFont()),t&&e.push("line-height:"+Math.round(t*3/2)+"px");var n=r.get("textShadowColor"),a=r.get("textShadowBlur")||0,s=r.get("textShadowOffsetX")||0,o=r.get("textShadowOffsetY")||0;return n&&a&&e.push("text-shadow:"+s+"px "+o+"px "+a+"px "+n),R(["decoration","align"],function(l){var u=r.get(l);u&&e.push("text-"+l+":"+u)}),e.join(";")}function _xe(r,e,t){var i=[],n=r.get("transitionDuration"),a=r.get("backgroundColor"),s=r.get("shadowBlur"),o=r.get("shadowColor"),l=r.get("shadowOffsetX"),u=r.get("shadowOffsetY"),c=r.getModel("textStyle"),h=QH(r,"html"),d=l+"px "+u+"px "+s+"px "+o;return i.push("box-shadow:"+d),e&&n&&i.push(mxe(n,t)),a&&i.push("background-color:"+a),R(["width","color","radius"],function(f){var p="border-"+f,v=yH(p),g=r.get(v);g!=null&&i.push(p+":"+g+(f==="color"?"":"px"))}),i.push(yxe(c)),h!=null&&i.push("padding:"+Nf(h).join("px ")+"px"),i.join(";")+";"}function uR(r,e,t,i,n){var a=e&&e.painter;if(t){var s=a&&a.getViewportRoot();s&&Woe(r,s,t,i,n)}else{r[0]=i,r[1]=n;var o=a&&a.getViewportRootOffset();o&&(r[0]+=o.offsetLeft,r[1]+=o.offsetTop)}r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var bxe=function(){function r(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,et.wxa)return null;var i=document.createElement("div");i.domBelongToZr=!0,this.el=i;var n=this._zr=e.getZr(),a=t.appendTo,s=a&&(pe(a)?document.querySelector(a):sf(a)?a:we(a)&&a(e.getDom()));uR(this._styleCoord,n,s,e.getWidth()/2,e.getHeight()/2),(s||e.getDom()).appendChild(i),this._api=e,this._container=s;var o=this;i.onmouseenter=function(){o._enterable&&(clearTimeout(o._hideTimeout),o._show=!0),o._inContent=!0},i.onmousemove=function(l){if(l=l||window.event,!o._enterable){var u=n.handler,c=n.painter.getViewportRoot();Ln(c,l,!0),u.dispatch("mousemove",l)}},i.onmouseleave=function(){o._inContent=!1,o._enterable&&o._show&&o.hideLater(o._hideDelay)}}return r.prototype.update=function(e){if(!this._container){var t=this._api.getDom(),i=fxe(t,"position"),n=t.style;n.position!=="absolute"&&i!=="absolute"&&(n.position="relative")}var a=e.get("alwaysShowContent");a&&this._moveIfResized(),this._alwaysShowContent=a,this.el.className=e.get("className")||""},r.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var i=this.el,n=i.style,a=this._styleCoord;i.innerHTML?n.cssText=pxe+_xe(e,!this._firstShow,this._longHide)+lR(a[0],a[1],!0)+("border-color:"+ic(t)+";")+(e.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):n.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},r.prototype.setContent=function(e,t,i,n,a){var s=this.el;if(e==null){s.innerHTML="";return}var o="";if(pe(a)&&i.get("trigger")==="item"&&!Bj(i)&&(o=gxe(i,n,a)),pe(e))s.innerHTML=e+o;else if(e){s.innerHTML="",ie(e)||(e=[e]);for(var l=0;l=0?this._tryShow(a,s):n==="leave"&&this._hide(s))},this))},e.prototype._keepShow=function(){var t=this._tooltipModel,i=this._ecModel,n=this._api,a=t.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&a!=="none"&&a!=="click"){var s=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!n.isDisposed()&&s.manuallyShowTip(t,i,n,{x:s._lastX,y:s._lastY,dataByCoordSys:s._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(t,i,n,a){if(!(a.from===this.uid||et.node||!n.getDom())){var s=fR(a,n);this._ticket="";var o=a.dataByCoordSys,l=Dxe(a,i,n);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:a.position,positionDefault:"bottom"},s)}else if(a.tooltip&&a.x!=null&&a.y!=null){var c=Txe;c.x=a.x,c.y=a.y,c.update(),ke(c).tooltipConfig={name:null,option:a.tooltip},this._tryShow({offsetX:a.x,offsetY:a.y,target:c},s)}else if(o)this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,dataByCoordSys:o,tooltipOption:a.tooltipOption},s);else if(a.seriesIndex!=null){if(this._manuallyAxisShowTip(t,i,n,a))return;var h=Cj(a,i),d=h.point[0],f=h.point[1];d!=null&&f!=null&&this._tryShow({offsetX:d,offsetY:f,target:h.el,position:a.position,positionDefault:"bottom"},s)}else a.x!=null&&a.y!=null&&(n.dispatchAction({type:"updateAxisPointer",x:a.x,y:a.y}),this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,target:n.getZr().findHover(a.x,a.y).target},s))}},e.prototype.manuallyHideTip=function(t,i,n,a){var s=this._tooltipContent;this._tooltipModel&&s.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,a.from!==this.uid&&this._hide(fR(a,n))},e.prototype._manuallyAxisShowTip=function(t,i,n,a){var s=a.seriesIndex,o=a.dataIndex,l=i.getComponent("axisPointer").coordSysAxesInfo;if(!(s==null||o==null||l==null)){var u=i.getSeriesByIndex(s);if(u){var c=u.getData(),h=Bd([c.getItemModel(o),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(h.get("trigger")==="axis")return n.dispatchAction({type:"updateAxisPointer",seriesIndex:s,dataIndex:o,position:a.position}),!0}}},e.prototype._tryShow=function(t,i){var n=t.target,a=this._tooltipModel;if(a){this._lastX=t.offsetX,this._lastY=t.offsetY;var s=t.dataByCoordSys;if(s&&s.length)this._showAxisTooltip(s,t);else if(n){var o=ke(n);if(o.ssrType==="legend")return;this._lastDataByCoordSys=null;var l,u;bu(n,function(c){if(ke(c).dataIndex!=null)return l=c,!0;if(ke(c).tooltipConfig!=null)return u=c,!0},!0),l?this._showSeriesItemTooltip(t,l,i):u?this._showComponentItemTooltip(t,u,i):this._hide(i)}else this._lastDataByCoordSys=null,this._hide(i)}},e.prototype._showOrMove=function(t,i){var n=t.get("showDelay");i=ge(i,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(i,n):i()},e.prototype._showAxisTooltip=function(t,i){var n=this._ecModel,a=this._tooltipModel,s=[i.offsetX,i.offsetY],o=Bd([i.tooltipOption],a),l=this._renderMode,u=[],c=Br("section",{blocks:[],noHeader:!0}),h=[],d=new Ub;R(t,function(y){R(y.dataByAxis,function(_){var b=n.getComponent(_.axisDim+"Axis",_.axisIndex),T=_.value;if(!(!b||T==null)){var x=Sj(T,b.axis,n,_.seriesDataIndices,_.valueLabelOpt),C=Br("section",{header:x,noHeader:!ha(x),sortBlocks:!0,blocks:[]});c.blocks.push(C),R(_.seriesDataIndices,function(D){var I=n.getSeriesByIndex(D.seriesIndex),M=D.dataIndexInside,L=I.getDataParams(M);if(!(L.dataIndex<0)){L.axisDim=_.axisDim,L.axisIndex=_.axisIndex,L.axisType=_.axisType,L.axisId=_.axisId,L.axisValue=GD(b.axis,{value:T}),L.axisValueLabel=x,L.marker=d.makeTooltipMarker("item",ic(L.color),l);var N=Q5(I.formatTooltip(M,!0,null)),O=N.frag;if(O){var B=Bd([I],a).get("valueFormatter");C.blocks.push(B?J({valueFormatter:B},O):O)}N.text&&h.push(N.text),u.push(L)}})}})}),c.blocks.reverse(),h.reverse();var f=i.position,p=o.get("order"),v=nM(c,d,l,p,n.get("useUTC"),o.get("textStyle"));v&&h.unshift(v);var g=l==="richText"?` + +`:"
",m=h.join(g);this._showOrMove(o,function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(o,f,s[0],s[1],this._tooltipContent,u):this._showTooltipContent(o,m,u,Math.random()+"",s[0],s[1],f,null,d)})},e.prototype._showSeriesItemTooltip=function(t,i,n){var a=this._ecModel,s=ke(i),o=s.seriesIndex,l=a.getSeriesByIndex(o),u=s.dataModel||l,c=s.dataIndex,h=s.dataType,d=u.getData(h),f=this._renderMode,p=t.positionDefault,v=Bd([d.getItemModel(c),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,p?{position:p}:null),g=v.get("trigger");if(!(g!=null&&g!=="item")){var m=u.getDataParams(c,h),y=new Ub;m.marker=y.makeTooltipMarker("item",ic(m.color),f);var _=Q5(u.formatTooltip(c,!1,h)),b=v.get("order"),T=v.get("valueFormatter"),x=_.frag,C=x?nM(T?J({valueFormatter:T},x):x,y,f,b,a.get("useUTC"),v.get("textStyle")):_.text,D="item_"+u.name+"_"+c;this._showOrMove(v,function(){this._showTooltipContent(v,C,m,D,t.offsetX,t.offsetY,t.position,t.target,y)}),n({type:"showTip",dataIndexInside:c,dataIndex:d.getRawIndex(c),seriesIndex:o,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,i,n){var a=this._renderMode==="html",s=ke(i),o=s.tooltipConfig,l=o.option||{},u=l.encodeHTMLContent;if(pe(l)){var c=l;l={content:c,formatter:c},u=!0}u&&a&&l.content&&(l=Ee(l),l.content=Bi(l.content));var h=[l],d=this._ecModel.getComponent(s.componentMainType,s.componentIndex);d&&h.push(d),h.push({formatter:l.content});var f=t.positionDefault,p=Bd(h,this._tooltipModel,f?{position:f}:null),v=p.get("content"),g=Math.random()+"",m=new Ub;this._showOrMove(p,function(){var y=Ee(p.get("formatterParams")||{});this._showTooltipContent(p,v,y,g,t.offsetX,t.offsetY,t.position,i,m)}),n({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,i,n,a,s,o,l,u,c){if(this._ticket="",!(!t.get("showContent")||!t.get("show"))){var h=this._tooltipContent;h.setEnterable(t.get("enterable"));var d=t.get("formatter");l=l||t.get("position");var f=i,p=this._getNearestPoint([s,o],n,t.get("trigger"),t.get("borderColor")),v=p.color;if(d)if(pe(d)){var g=t.ecModel.get("useUTC"),m=ie(n)?n[0]:n,y=m&&m.axisType&&m.axisType.indexOf("time")>=0;f=d,y&&(f=p1(m.axisValue,f,g)),f=_H(f,n,!0)}else if(we(d)){var _=ge(function(b,T){b===this._ticket&&(h.setContent(T,c,t,v,l),this._updatePosition(t,l,s,o,h,n,u))},this);this._ticket=a,f=d(n,a,_)}else f=d;h.setContent(f,c,t,v,l),h.show(t,v),this._updatePosition(t,l,s,o,h,n,u)}},e.prototype._getNearestPoint=function(t,i,n,a){if(n==="axis"||ie(i))return{color:a||(this._renderMode==="html"?"#fff":"none")};if(!ie(i))return{color:a||i.color||i.borderColor}},e.prototype._updatePosition=function(t,i,n,a,s,o,l){var u=this._api.getWidth(),c=this._api.getHeight();i=i||t.get("position");var h=s.getSize(),d=t.get("align"),f=t.get("verticalAlign"),p=l&&l.getBoundingRect().clone();if(l&&p.applyTransform(l.transform),we(i)&&(i=i([n,a],o,s.el,p,{viewSize:[u,c],contentSize:h.slice()})),ie(i))n=ce(i[0],u),a=ce(i[1],c);else if(De(i)){var v=i;v.width=h[0],v.height=h[1];var g=Ar(v,{width:u,height:c});n=g.x,a=g.y,d=null,f=null}else if(pe(i)&&l){var m=Axe(i,p,h,t.get("borderWidth"));n=m[0],a=m[1]}else{var m=wxe(n,a,s,u,c,d?null:20,f?null:20);n=m[0],a=m[1]}if(d&&(n-=dR(d)?h[0]/2:d==="right"?h[0]:0),f&&(a-=dR(f)?h[1]/2:f==="bottom"?h[1]:0),Bj(t)){var m=Cxe(n,a,s,u,c);n=m[0],a=m[1]}s.moveTo(n,a)},e.prototype._updateContentNotChangedOnAxis=function(t,i){var n=this._lastDataByCoordSys,a=this._cbParamsList,s=!!n&&n.length===t.length;return s&&R(n,function(o,l){var u=o.dataByAxis||[],c=t[l]||{},h=c.dataByAxis||[];s=s&&u.length===h.length,s&&R(u,function(d,f){var p=h[f]||{},v=d.seriesDataIndices||[],g=p.seriesDataIndices||[];s=s&&d.value===p.value&&d.axisType===p.axisType&&d.axisId===p.axisId&&v.length===g.length,s&&R(v,function(m,y){var _=g[y];s=s&&m.seriesIndex===_.seriesIndex&&m.dataIndex===_.dataIndex}),a&&R(d.seriesDataIndices,function(m){var y=m.seriesIndex,_=i[y],b=a[y];_&&b&&b.data!==_.data&&(s=!1)})})}),this._lastDataByCoordSys=t,this._cbParamsList=i,!!s},e.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,i){et.node||!i.getDom()||(_v(this,"_updatePosition"),this._tooltipContent.dispose(),qw("itemTooltip",i))},e.type="tooltip",e}($t);function Bd(r,e,t){var i=e.ecModel,n;t?(n=new yt(t,i,i),n=new yt(e.option,n,i)):n=e;for(var a=r.length-1;a>=0;a--){var s=r[a];s&&(s instanceof yt&&(s=s.get("tooltip",!0)),pe(s)&&(s={formatter:s}),s&&(n=new yt(s,n,i)))}return n}function fR(r,e){return r.dispatchAction||ge(e.dispatchAction,e)}function wxe(r,e,t,i,n,a,s){var o=t.getSize(),l=o[0],u=o[1];return a!=null&&(r+l+a+2>i?r-=l+a:r+=a),s!=null&&(e+u+s>n?e-=u+s:e+=s),[r,e]}function Cxe(r,e,t,i,n){var a=t.getSize(),s=a[0],o=a[1];return r=Math.min(r+s,i)-s,e=Math.min(e+o,n)-o,r=Math.max(r,0),e=Math.max(e,0),[r,e]}function Axe(r,e,t,i){var n=t[0],a=t[1],s=Math.ceil(Math.SQRT2*i)+8,o=0,l=0,u=e.width,c=e.height;switch(r){case"inside":o=e.x+u/2-n/2,l=e.y+c/2-a/2;break;case"top":o=e.x+u/2-n/2,l=e.y-a-s;break;case"bottom":o=e.x+u/2-n/2,l=e.y+c+s;break;case"left":o=e.x-n-s,l=e.y+c/2-a/2;break;case"right":o=e.x+u+s,l=e.y+c/2-a/2}return[o,l]}function dR(r){return r==="center"||r==="middle"}function Dxe(r,e,t){var i=rD(r).queryOptionMap,n=i.keys()[0];if(!(!n||n==="series")){var a=Zv(e,n,i.get(n),{useDefault:!1,enableAll:!1,enableNone:!1}),s=a.models[0];if(s){var o=t.getViewOfComponentModel(s),l;if(o.group.traverse(function(u){var c=ke(u).tooltipConfig;if(c&&c.name===r.name)return l=u,!0}),l)return{componentMainType:n,componentIndex:s.componentIndex,el:l}}}}function Exe(r){Ze(gg),r.registerComponentModel(cxe),r.registerComponentView(xxe),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},lr),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},lr)}var Ixe=["rect","polygon","keep","clear"];function Pxe(r,e){var t=xt(r?r.brush:[]);if(t.length){var i=[];R(t,function(l){var u=l.hasOwnProperty("toolbox")?l.toolbox:[];u instanceof Array&&(i=i.concat(u))});var n=r&&r.toolbox;ie(n)&&(n=n[0]),n||(n={feature:{}},r.toolbox=[n]);var a=n.feature||(n.feature={}),s=a.brush||(a.brush={}),o=s.type||(s.type=[]);o.push.apply(o,i),Mxe(o),e&&!o.length&&o.push.apply(o,Ixe)}}function Mxe(r){var e={};R(r,function(t){e[t]=1}),r.length=0,R(e,function(t,i){r.push(i)})}var pR=R;function vR(r){if(r){for(var e in r)if(r.hasOwnProperty(e))return!0}}function Qw(r,e,t){var i={};return pR(e,function(a){var s=i[a]=n();pR(r[a],function(o,l){if(Or.isValidType(l)){var u={type:l,visual:o};t&&t(u,a),s[l]=new Or(u),l==="opacity"&&(u=Ee(u),u.type="colorAlpha",s.__hidden.__alphaForOpacity=new Or(u))}})}),i;function n(){var a=function(){};a.prototype.__hidden=a.prototype;var s=new a;return s}}function zj(r,e,t){var i;R(t,function(n){e.hasOwnProperty(n)&&vR(e[n])&&(i=!0)}),i&&R(t,function(n){e.hasOwnProperty(n)&&vR(e[n])?r[n]=Ee(e[n]):delete r[n]})}function Lxe(r,e,t,i,n,a){var s={};R(r,function(h){var d=Or.prepareVisualTypes(e[h]);s[h]=d});var o;function l(h){return MD(t,o,h)}function u(h,d){l$(t,o,h,d)}t.each(c);function c(h,d){o=h;var f=t.getRawDataItem(o);if(!(f&&f.visualMap===!1))for(var p=i.call(n,h),v=e[p],g=s[p],m=0,y=g.length;me[0][1]&&(e[0][1]=a[0]),a[1]e[1][1]&&(e[1][1]=a[1])}return e&&bR(e)}};function bR(r){return new qe(r[0][0],r[1][0],r[0][1]-r[0][0],r[1][1]-r[1][0])}var Vxe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,i){this.ecModel=t,this.api=i,this.model,(this._brushController=new pE(i.getZr())).on("brush",ge(this._onBrush,this)).mount()},e.prototype.render=function(t,i,n,a){this.model=t,this._updateController(t,i,n,a)},e.prototype.updateTransform=function(t,i,n,a){Gj(i),this._updateController(t,i,n,a)},e.prototype.updateVisual=function(t,i,n,a){this.updateTransform(t,i,n,a)},e.prototype.updateView=function(t,i,n,a){this._updateController(t,i,n,a)},e.prototype._updateController=function(t,i,n,a){(!a||a.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(n)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var i=this.model.id,n=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:i,areas:Ee(n),$from:i}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:i,areas:Ee(n),$from:i})},e.type="brush",e}($t),zxe="#ddd",Gxe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.areas=[],t.brushOption={},t}return e.prototype.optionUpdated=function(t,i){var n=this.option;!i&&zj(n,t,["inBrush","outOfBrush"]);var a=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:zxe},a.hasOwnProperty("liftZ")||(a.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=oe(t,function(i){return SR(this.option,i)},this))},e.prototype.setBrushOption=function(t){this.brushOption=SR(this.option,t),this.brushType=this.brushOption.brushType},e.type="brush",e.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],e.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(210,219,238,0.3)",borderColor:"#D2DBEE"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},e}(tt);function SR(r,e){return We({brushType:r.brushType,brushMode:r.brushMode,transformable:r.transformable,brushStyle:new yt(r.brushStyle).getItemStyle(),removeOnClick:r.removeOnClick,z:r.z},e,!0)}var Hxe=["rect","polygon","lineX","lineY","keep","clear"],$xe=function(r){j(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,i,n){var a,s,o;i.eachComponent({mainType:"brush"},function(l){a=l.brushType,s=l.brushOption.brushMode||"single",o=o||!!l.areas.length}),this._brushType=a,this._brushMode=s,R(t.get("type",!0),function(l){t.setIconStatus(l,(l==="keep"?s==="multiple":l==="clear"?o:l===a)?"emphasis":"normal")})},e.prototype.updateView=function(t,i,n){this.render(t,i,n)},e.prototype.getIcons=function(){var t=this.model,i=t.get("icon",!0),n={};return R(t.get("type",!0),function(a){i[a]&&(n[a]=i[a])}),n},e.prototype.onclick=function(t,i,n){var a=this._brushType,s=this._brushMode;n==="clear"?(i.dispatchAction({type:"axisAreaSelect",intervals:[]}),i.dispatchAction({type:"brush",command:"clear",areas:[]})):i.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:n==="keep"?a:a===n?!1:n,brushMode:n==="keep"?s==="multiple"?"single":"multiple":s}})},e.getDefaultOption=function(t){var i={show:!0,type:Hxe.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])};return i},e}(Bn);function Wxe(r){r.registerComponentView(Vxe),r.registerComponentModel(Gxe),r.registerPreprocessor(Pxe),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,Oxe),r.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(i){i.setAreas(e.areas)})}),r.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},lr),r.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},lr),lh("brush",$xe)}var qxe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.type="title",e.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:"#464646"},subtextStyle:{fontSize:12,color:"#6E7079"}},e}(tt),jxe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,i,n){if(this.group.removeAll(),!!t.get("show")){var a=this.group,s=t.getModel("textStyle"),o=t.getModel("subtextStyle"),l=t.get("textAlign"),u=Be(t.get("textBaseline"),t.get("textVerticalAlign")),c=new lt({style:kt(s,{text:t.get("text"),fill:s.getTextColor()},{disableBox:!0}),z2:10}),h=c.getBoundingRect(),d=t.get("subtext"),f=new lt({style:kt(o,{text:d,fill:o.getTextColor(),y:h.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),p=t.get("link"),v=t.get("sublink"),g=t.get("triggerEvent",!0);c.silent=!p&&!g,f.silent=!v&&!g,p&&c.on("click",function(){By(p,"_"+t.get("target"))}),v&&f.on("click",function(){By(v,"_"+t.get("subtarget"))}),ke(c).eventData=ke(f).eventData=g?{componentType:"title",componentIndex:t.componentIndex}:null,a.add(c),d&&a.add(f);var m=a.getBoundingRect(),y=t.getBoxLayoutParams();y.width=m.width,y.height=m.height;var _=Ar(y,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));l||(l=t.get("left")||t.get("right"),l==="middle"&&(l="center"),l==="right"?_.x+=_.width:l==="center"&&(_.x+=_.width/2)),u||(u=t.get("top")||t.get("bottom"),u==="center"&&(u="middle"),u==="bottom"?_.y+=_.height:u==="middle"&&(_.y+=_.height/2),u=u||"top"),a.x=_.x,a.y=_.y,a.markRedraw();var b={align:l,verticalAlign:u};c.setStyle(b),f.setStyle(b),m=a.getBoundingRect();var T=_.margin,x=t.getItemStyle(["color","opacity"]);x.fill=t.get("backgroundColor");var C=new st({shape:{x:m.x-T[3],y:m.y-T[0],width:m.width+T[1]+T[3],height:m.height+T[0]+T[2],r:t.get("borderRadius")},style:x,subPixelOptimize:!0,silent:!0});a.add(C)}},e.type="title",e}($t);function Xxe(r){r.registerComponentModel(qxe),r.registerComponentView(jxe)}var TR=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode="box",t}return e.prototype.init=function(t,i,n){this.mergeDefaultAndTheme(t,n),this._initData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){t==null&&(t=this.option.currentIndex);var i=this._data.count();this.option.loop?t=(t%i+i)%i:(t>=i&&(t=i-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t=this.option,i=t.data||[],n=t.axisType,a=this._names=[],s;n==="category"?(s=[],R(i,function(u,c){var h=wr(Pf(u),""),d;De(u)?(d=Ee(u),d.value=c):d=c,s.push(d),a.push(h)})):s=i;var o={category:"ordinal",time:"time",value:"number"}[n]||"number",l=this._data=new wi([{name:"value",type:o}],this);l.initData(s,a)},e.prototype.getData=function(){return this._data},e.prototype.getCategories=function(){if(this.get("axisType")==="category")return this._names.slice()},e.type="timeline",e.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},e}(tt),Hj=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline.slider",e.defaultOption=hl(TR.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),e}(TR);_r(Hj,S1.prototype);var Yxe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e}($t),Kxe=function(r){j(e,r);function e(t,i,n,a){var s=r.call(this,t,i,n)||this;return s.type=a||"value",s}return e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},e}(xa),rT=Math.PI,xR=ot(),Zxe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,i){this.api=i},e.prototype.render=function(t,i,n){if(this.model=t,this.api=n,this.ecModel=i,this.group.removeAll(),t.get("show",!0)){var a=this._layout(t,n),s=this._createGroup("_mainGroup"),o=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(a,t);t.formatTooltip=function(u){var c=l.scale.getLabel({value:u});return Br("nameValue",{noName:!0,value:c})},R(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](a,s,l,t)},this),this._renderAxisLabel(a,o,l,t),this._position(a,t)}this._doPlayStop(),this._updateTicksStatus()},e.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},e.prototype.dispose=function(){this._clearTimer()},e.prototype._layout=function(t,i){var n=t.get(["label","position"]),a=t.get("orient"),s=Jxe(t,i),o;n==null||n==="auto"?o=a==="horizontal"?s.y+s.height/2=0||o==="+"?"left":"right"},u={horizontal:o>=0||o==="+"?"top":"bottom",vertical:"middle"},c={horizontal:0,vertical:rT/2},h=a==="vertical"?s.height:s.width,d=t.getModel("controlStyle"),f=d.get("show",!0),p=f?d.get("itemSize"):0,v=f?d.get("itemGap"):0,g=p+v,m=t.get(["label","rotate"])||0;m=m*rT/180;var y,_,b,T=d.get("position",!0),x=f&&d.get("showPlayBtn",!0),C=f&&d.get("showPrevBtn",!0),D=f&&d.get("showNextBtn",!0),I=0,M=h;T==="left"||T==="bottom"?(x&&(y=[0,0],I+=g),C&&(_=[I,0],I+=g),D&&(b=[M-p,0],M-=g)):(x&&(y=[M-p,0],M-=g),C&&(_=[0,0],I+=g),D&&(b=[M-p,0],M-=g));var L=[I,M];return t.get("inverse")&&L.reverse(),{viewRect:s,mainLength:h,orient:a,rotation:c[a],labelRotation:m,labelPosOpt:o,labelAlign:t.get(["label","align"])||l[a],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||u[a],playPosition:y,prevBtnPosition:_,nextBtnPosition:b,axisExtent:L,controlSize:p,controlGap:v}},e.prototype._position=function(t,i){var n=this._mainGroup,a=this._labelGroup,s=t.viewRect;if(t.orient==="vertical"){var o=vn(),l=s.x,u=s.y+s.height;ss(o,o,[-l,-u]),uc(o,o,-rT/2),ss(o,o,[l,u]),s=s.clone(),s.applyTransform(o)}var c=y(s),h=y(n.getBoundingRect()),d=y(a.getBoundingRect()),f=[n.x,n.y],p=[a.x,a.y];p[0]=f[0]=c[0][0];var v=t.labelPosOpt;if(v==null||pe(v)){var g=v==="+"?0:1;_(f,h,c,1,g),_(p,d,c,1,1-g)}else{var g=v>=0?0:1;_(f,h,c,1,g),p[1]=f[1]+v}n.setPosition(f),a.setPosition(p),n.rotation=a.rotation=t.rotation,m(n),m(a);function m(b){b.originX=c[0][0]-b.x,b.originY=c[1][0]-b.y}function y(b){return[[b.x,b.x+b.width],[b.y,b.y+b.height]]}function _(b,T,x,C,D){b[C]+=x[C][D]-T[C][D]}},e.prototype._createAxis=function(t,i){var n=i.getData(),a=i.get("axisType"),s=Qxe(i,a);s.getTicks=function(){return n.mapArray(["value"],function(u){return{value:u}})};var o=n.getDataExtent("value");s.setExtent(o[0],o[1]),s.calcNiceTicks();var l=new Kxe("value",s,t.axisExtent,a);return l.model=i,l},e.prototype._createGroup=function(t){var i=this[t]=new Le;return this.group.add(i),i},e.prototype._renderAxisLine=function(t,i,n,a){var s=n.getExtent();if(a.get(["lineStyle","show"])){var o=new kr({shape:{x1:s[0],y1:0,x2:s[1],y2:0},style:J({lineCap:"round"},a.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});i.add(o);var l=this._progressLine=new kr({shape:{x1:s[0],x2:this._currentPointer?this._currentPointer.x:s[0],y1:0,y2:0},style:Ce({lineCap:"round",lineWidth:o.style.lineWidth},a.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});i.add(l)}},e.prototype._renderAxisTick=function(t,i,n,a){var s=this,o=a.getData(),l=n.scale.getTicks();this._tickSymbols=[],R(l,function(u){var c=n.dataToCoord(u.value),h=o.getItemModel(u.value),d=h.getModel("itemStyle"),f=h.getModel(["emphasis","itemStyle"]),p=h.getModel(["progress","itemStyle"]),v={x:c,y:0,onclick:ge(s._changeTimeline,s,u.value)},g=wR(h,d,i,v);g.ensureState("emphasis").style=f.getItemStyle(),g.ensureState("progress").style=p.getItemStyle(),zu(g);var m=ke(g);h.get("tooltip")?(m.dataIndex=u.value,m.dataModel=a):m.dataIndex=m.dataModel=null,s._tickSymbols.push(g)})},e.prototype._renderAxisLabel=function(t,i,n,a){var s=this,o=n.getLabelModel();if(o.get("show")){var l=a.getData(),u=n.getViewLabels();this._tickLabels=[],R(u,function(c){var h=c.tickValue,d=l.getItemModel(h),f=d.getModel("label"),p=d.getModel(["emphasis","label"]),v=d.getModel(["progress","label"]),g=n.dataToCoord(c.tickValue),m=new lt({x:g,y:0,rotation:t.labelRotation-t.rotation,onclick:ge(s._changeTimeline,s,h),silent:!1,style:kt(f,{text:c.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});m.ensureState("emphasis").style=kt(p),m.ensureState("progress").style=kt(v),i.add(m),zu(m),xR(m).dataIndex=h,s._tickLabels.push(m)})}},e.prototype._renderControl=function(t,i,n,a){var s=t.controlSize,o=t.rotation,l=a.getModel("controlStyle").getItemStyle(),u=a.getModel(["emphasis","controlStyle"]).getItemStyle(),c=a.getPlayState(),h=a.get("inverse",!0);d(t.nextBtnPosition,"next",ge(this._changeTimeline,this,h?"-":"+")),d(t.prevBtnPosition,"prev",ge(this._changeTimeline,this,h?"+":"-")),d(t.playPosition,c?"stop":"play",ge(this._handlePlayClick,this,!c),!0);function d(f,p,v,g){if(f){var m=ya(Be(a.get(["controlStyle",p+"BtnSize"]),s),s),y=[0,-m/2,m,m],_=ewe(a,p+"Icon",y,{x:f[0],y:f[1],originX:s/2,originY:0,rotation:g?-o:0,rectHover:!0,style:l,onclick:v});_.ensureState("emphasis").style=u,i.add(_),zu(_)}}},e.prototype._renderCurrentPointer=function(t,i,n,a){var s=a.getData(),o=a.getCurrentIndex(),l=s.getItemModel(o).getModel("checkpointStyle"),u=this,c={onCreate:function(h){h.draggable=!0,h.drift=ge(u._handlePointerDrag,u),h.ondragend=ge(u._handlePointerDragend,u),CR(h,u._progressLine,o,n,a,!0)},onUpdate:function(h){CR(h,u._progressLine,o,n,a)}};this._currentPointer=wR(l,l,this._mainGroup,{},this._currentPointer,c)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,i,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,i){var n=this._toAxisCoord(t)[0],a=this._axis,s=Gn(a.getExtent().slice());n>s[1]&&(n=s[1]),n=0&&(s[a]=+s[a].toFixed(d)),[s,h]}var iT={min:Ue(Qm,"min"),max:Ue(Qm,"max"),average:Ue(Qm,"average"),median:Ue(Qm,"median")};function kv(r,e){if(e){var t=r.getData(),i=r.coordinateSystem,n=i&&i.dimensions;if(!swe(e)&&!ie(e.coord)&&ie(n)){var a=$j(e,t,i,r);if(e=Ee(e),e.type&&iT[e.type]&&a.baseAxis&&a.valueAxis){var s=Xe(n,a.baseAxis.dim),o=Xe(n,a.valueAxis.dim),l=iT[e.type](t,a.baseDataDim,a.valueDataDim,s,o);e.coord=l[0],e.value=l[1]}else e.coord=[e.xAxis!=null?e.xAxis:e.radiusAxis,e.yAxis!=null?e.yAxis:e.angleAxis]}if(e.coord==null||!ie(n))e.coord=[];else for(var u=e.coord,c=0;c<2;c++)iT[u[c]]&&(u[c]=HE(t,t.mapDimension(n[c]),u[c]));return e}}function $j(r,e,t,i){var n={};return r.valueIndex!=null||r.valueDim!=null?(n.valueDataDim=r.valueIndex!=null?e.getDimension(r.valueIndex):r.valueDim,n.valueAxis=t.getAxis(owe(i,n.valueDataDim)),n.baseAxis=t.getOtherAxis(n.valueAxis),n.baseDataDim=e.mapDimension(n.baseAxis.dim)):(n.baseAxis=i.getBaseAxis(),n.valueAxis=t.getOtherAxis(n.baseAxis),n.baseDataDim=e.mapDimension(n.baseAxis.dim),n.valueDataDim=e.mapDimension(n.valueAxis.dim)),n}function owe(r,e){var t=r.getData().getDimensionInfo(e);return t&&t.coordDim}function Rv(r,e){return r&&r.containData&&e.coord&&!eC(e)?r.containData(e.coord):!0}function lwe(r,e,t){return r&&r.containZone&&e.coord&&t.coord&&!eC(e)&&!eC(t)?r.containZone(e.coord,t.coord):!0}function Wj(r,e){return r?function(t,i,n,a){var s=a<2?t.coord&&t.coord[a]:t.value;return jo(s,e[a])}:function(t,i,n,a){return jo(t.value,e[a])}}function HE(r,e,t){if(t==="average"){var i=0,n=0;return r.each(e,function(a,s){isNaN(a)||(i+=a,n++)}),i/n}else return t==="median"?r.getMedian(e):r.getDataExtent(e)[t==="max"?1:0]}var nT=ot(),$E=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this.markerGroupMap=be()},e.prototype.render=function(t,i,n){var a=this,s=this.markerGroupMap;s.each(function(o){nT(o).keep=!1}),i.eachSeries(function(o){var l=Zs.getMarkerModelFromSeries(o,a.type);l&&a.renderSeries(o,l,i,n)}),s.each(function(o){!nT(o).keep&&a.group.remove(o.group)})},e.prototype.markKeep=function(t){nT(t).keep=!0},e.prototype.toggleBlurSeries=function(t,i){var n=this;R(t,function(a){var s=Zs.getMarkerModelFromSeries(a,n.type);if(s){var o=s.getData();o.eachItemGraphicEl(function(l){l&&(i?NG(l):uD(l))})}})},e.type="marker",e}($t);function DR(r,e,t){var i=e.coordinateSystem;r.each(function(n){var a=r.getItemModel(n),s,o=ce(a.get("x"),t.getWidth()),l=ce(a.get("y"),t.getHeight());if(!isNaN(o)&&!isNaN(l))s=[o,l];else if(e.getMarkerPosition)s=e.getMarkerPosition(r.getValues(r.dimensions,n));else if(i){var u=r.get(i.dimensions[0],n),c=r.get(i.dimensions[1],n);s=i.dataToPoint([u,c])}isNaN(o)||(s[0]=o),isNaN(l)||(s[1]=l),r.setItemLayout(n,s)})}var uwe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,i,n){i.eachSeries(function(a){var s=Zs.getMarkerModelFromSeries(a,"markPoint");s&&(DR(s.getData(),a,n),this.markerGroupMap.get(a.id).updateLayout())},this)},e.prototype.renderSeries=function(t,i,n,a){var s=t.coordinateSystem,o=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(o)||u.set(o,new ug),h=cwe(s,t,i);i.setData(h),DR(i.getData(),t,a),h.each(function(d){var f=h.getItemModel(d),p=f.getShallow("symbol"),v=f.getShallow("symbolSize"),g=f.getShallow("symbolRotate"),m=f.getShallow("symbolOffset"),y=f.getShallow("symbolKeepAspect");if(we(p)||we(v)||we(g)||we(m)){var _=i.getRawValue(d),b=i.getDataParams(d);we(p)&&(p=p(_,b)),we(v)&&(v=v(_,b)),we(g)&&(g=g(_,b)),we(m)&&(m=m(_,b))}var T=f.getModel("itemStyle").getItemStyle(),x=ag(l,"color");T.fill||(T.fill=x),h.setItemVisual(d,{symbol:p,symbolSize:v,symbolRotate:g,symbolOffset:m,symbolKeepAspect:y,style:T})}),c.updateData(h),this.group.add(c.group),h.eachItemGraphicEl(function(d){d.traverse(function(f){ke(f).dataModel=i})}),this.markKeep(c),c.group.silent=i.get("silent")||t.get("silent")},e.type="markPoint",e}($E);function cwe(r,e,t){var i;r?i=oe(r&&r.dimensions,function(o){var l=e.getData().getDimensionInfo(e.getData().mapDimension(o))||{};return J(J({},l),{name:o,ordinalMeta:null})}):i=[{name:"value",type:"float"}];var n=new wi(i,t),a=oe(t.get("data"),Ue(kv,e));r&&(a=Tt(a,Ue(Rv,r)));var s=Wj(!!r,i);return n.initData(a,null,s),n}function hwe(r){r.registerComponentModel(awe),r.registerComponentView(uwe),r.registerPreprocessor(function(e){GE(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}var fwe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,i,n){return new e(t,i,n)},e.type="markLine",e.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},e}(Zs),Jm=ot(),dwe=function(r,e,t,i){var n=r.getData(),a;if(ie(i))a=i;else{var s=i.type;if(s==="min"||s==="max"||s==="average"||s==="median"||i.xAxis!=null||i.yAxis!=null){var o=void 0,l=void 0;if(i.yAxis!=null||i.xAxis!=null)o=e.getAxis(i.yAxis!=null?"y":"x"),l=Gr(i.yAxis,i.xAxis);else{var u=$j(i,n,e,r);o=u.valueAxis;var c=F$(n,u.valueDataDim);l=HE(n,c,s)}var h=o.dim==="x"?0:1,d=1-h,f=Ee(i),p={coord:[]};f.type=null,f.coord=[],f.coord[d]=-1/0,p.coord[d]=1/0;var v=t.get("precision");v>=0&&ut(l)&&(l=+l.toFixed(Math.min(v,20))),f.coord[h]=p.coord[h]=l,a=[f,p,{type:s,valueIndex:i.valueIndex,value:l}]}else a=[]}var g=[kv(r,a[0]),kv(r,a[1]),J({},a[2])];return g[2].type=g[2].type||null,We(g[2],g[0]),We(g[2],g[1]),g};function l_(r){return!isNaN(r)&&!isFinite(r)}function ER(r,e,t,i){var n=1-r,a=i.dimensions[r];return l_(e[n])&&l_(t[n])&&e[r]===t[r]&&i.getAxis(a).containData(e[r])}function pwe(r,e){if(r.type==="cartesian2d"){var t=e[0].coord,i=e[1].coord;if(t&&i&&(ER(1,t,i,r)||ER(0,t,i,r)))return!0}return Rv(r,e[0])&&Rv(r,e[1])}function aT(r,e,t,i,n){var a=i.coordinateSystem,s=r.getItemModel(e),o,l=ce(s.get("x"),n.getWidth()),u=ce(s.get("y"),n.getHeight());if(!isNaN(l)&&!isNaN(u))o=[l,u];else{if(i.getMarkerPosition)o=i.getMarkerPosition(r.getValues(r.dimensions,e));else{var c=a.dimensions,h=r.get(c[0],e),d=r.get(c[1],e);o=a.dataToPoint([h,d])}if(dc(a,"cartesian2d")){var f=a.getAxis("x"),p=a.getAxis("y"),c=a.dimensions;l_(r.get(c[0],e))?o[0]=f.toGlobalCoord(f.getExtent()[t?0:1]):l_(r.get(c[1],e))&&(o[1]=p.toGlobalCoord(p.getExtent()[t?0:1]))}isNaN(l)||(o[0]=l),isNaN(u)||(o[1]=u)}r.setItemLayout(e,o)}var vwe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,i,n){i.eachSeries(function(a){var s=Zs.getMarkerModelFromSeries(a,"markLine");if(s){var o=s.getData(),l=Jm(s).from,u=Jm(s).to;l.each(function(c){aT(l,c,!0,a,n),aT(u,c,!1,a,n)}),o.each(function(c){o.setItemLayout(c,[l.getItemLayout(c),u.getItemLayout(c)])}),this.markerGroupMap.get(a.id).updateLayout()}},this)},e.prototype.renderSeries=function(t,i,n,a){var s=t.coordinateSystem,o=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(o)||u.set(o,new dE);this.group.add(c.group);var h=gwe(s,t,i),d=h.from,f=h.to,p=h.line;Jm(i).from=d,Jm(i).to=f,i.setData(p);var v=i.get("symbol"),g=i.get("symbolSize"),m=i.get("symbolRotate"),y=i.get("symbolOffset");ie(v)||(v=[v,v]),ie(g)||(g=[g,g]),ie(m)||(m=[m,m]),ie(y)||(y=[y,y]),h.from.each(function(b){_(d,b,!0),_(f,b,!1)}),p.each(function(b){var T=p.getItemModel(b).getModel("lineStyle").getLineStyle();p.setItemLayout(b,[d.getItemLayout(b),f.getItemLayout(b)]),T.stroke==null&&(T.stroke=d.getItemVisual(b,"style").fill),p.setItemVisual(b,{fromSymbolKeepAspect:d.getItemVisual(b,"symbolKeepAspect"),fromSymbolOffset:d.getItemVisual(b,"symbolOffset"),fromSymbolRotate:d.getItemVisual(b,"symbolRotate"),fromSymbolSize:d.getItemVisual(b,"symbolSize"),fromSymbol:d.getItemVisual(b,"symbol"),toSymbolKeepAspect:f.getItemVisual(b,"symbolKeepAspect"),toSymbolOffset:f.getItemVisual(b,"symbolOffset"),toSymbolRotate:f.getItemVisual(b,"symbolRotate"),toSymbolSize:f.getItemVisual(b,"symbolSize"),toSymbol:f.getItemVisual(b,"symbol"),style:T})}),c.updateData(p),h.line.eachItemGraphicEl(function(b){ke(b).dataModel=i,b.traverse(function(T){ke(T).dataModel=i})});function _(b,T,x){var C=b.getItemModel(T);aT(b,T,x,t,a);var D=C.getModel("itemStyle").getItemStyle();D.fill==null&&(D.fill=ag(l,"color")),b.setItemVisual(T,{symbolKeepAspect:C.get("symbolKeepAspect"),symbolOffset:Be(C.get("symbolOffset",!0),y[x?0:1]),symbolRotate:Be(C.get("symbolRotate",!0),m[x?0:1]),symbolSize:Be(C.get("symbolSize"),g[x?0:1]),symbol:Be(C.get("symbol",!0),v[x?0:1]),style:D})}this.markKeep(c),c.group.silent=i.get("silent")||t.get("silent")},e.type="markLine",e}($E);function gwe(r,e,t){var i;r?i=oe(r&&r.dimensions,function(u){var c=e.getData().getDimensionInfo(e.getData().mapDimension(u))||{};return J(J({},c),{name:u,ordinalMeta:null})}):i=[{name:"value",type:"float"}];var n=new wi(i,t),a=new wi(i,t),s=new wi([],t),o=oe(t.get("data"),Ue(dwe,e,r,t));r&&(o=Tt(o,Ue(pwe,r)));var l=Wj(!!r,i);return n.initData(oe(o,function(u){return u[0]}),null,l),a.initData(oe(o,function(u){return u[1]}),null,l),s.initData(oe(o,function(u){return u[2]})),s.hasItemOption=!0,{from:n,to:a,line:s}}function mwe(r){r.registerComponentModel(fwe),r.registerComponentView(vwe),r.registerPreprocessor(function(e){GE(e.series,"markLine")&&(e.markLine=e.markLine||{})})}var ywe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,i,n){return new e(t,i,n)},e.type="markArea",e.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},e}(Zs),e0=ot(),_we=function(r,e,t,i){var n=i[0],a=i[1];if(!(!n||!a)){var s=kv(r,n),o=kv(r,a),l=s.coord,u=o.coord;l[0]=Gr(l[0],-1/0),l[1]=Gr(l[1],-1/0),u[0]=Gr(u[0],1/0),u[1]=Gr(u[1],1/0);var c=WA([{},s,o]);return c.coord=[s.coord,o.coord],c.x0=s.x,c.y0=s.y,c.x1=o.x,c.y1=o.y,c}};function u_(r){return!isNaN(r)&&!isFinite(r)}function IR(r,e,t,i){var n=1-r;return u_(e[n])&&u_(t[n])}function bwe(r,e){var t=e.coord[0],i=e.coord[1],n={coord:t,x:e.x0,y:e.y0},a={coord:i,x:e.x1,y:e.y1};return dc(r,"cartesian2d")?t&&i&&(IR(1,t,i)||IR(0,t,i))?!0:lwe(r,n,a):Rv(r,n)||Rv(r,a)}function PR(r,e,t,i,n){var a=i.coordinateSystem,s=r.getItemModel(e),o,l=ce(s.get(t[0]),n.getWidth()),u=ce(s.get(t[1]),n.getHeight());if(!isNaN(l)&&!isNaN(u))o=[l,u];else{if(i.getMarkerPosition){var c=r.getValues(["x0","y0"],e),h=r.getValues(["x1","y1"],e),d=a.clampData(c),f=a.clampData(h),p=[];t[0]==="x0"?p[0]=d[0]>f[0]?h[0]:c[0]:p[0]=d[0]>f[0]?c[0]:h[0],t[1]==="y0"?p[1]=d[1]>f[1]?h[1]:c[1]:p[1]=d[1]>f[1]?c[1]:h[1],o=i.getMarkerPosition(p,t,!0)}else{var v=r.get(t[0],e),g=r.get(t[1],e),m=[v,g];a.clampData&&a.clampData(m,m),o=a.dataToPoint(m,!0)}if(dc(a,"cartesian2d")){var y=a.getAxis("x"),_=a.getAxis("y"),v=r.get(t[0],e),g=r.get(t[1],e);u_(v)?o[0]=y.toGlobalCoord(y.getExtent()[t[0]==="x0"?0:1]):u_(g)&&(o[1]=_.toGlobalCoord(_.getExtent()[t[1]==="y0"?0:1]))}isNaN(l)||(o[0]=l),isNaN(u)||(o[1]=u)}return o}var MR=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],Swe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,i,n){i.eachSeries(function(a){var s=Zs.getMarkerModelFromSeries(a,"markArea");if(s){var o=s.getData();o.each(function(l){var u=oe(MR,function(h){return PR(o,l,h,a,n)});o.setItemLayout(l,u);var c=o.getItemGraphicEl(l);c.setShape("points",u)})}},this)},e.prototype.renderSeries=function(t,i,n,a){var s=t.coordinateSystem,o=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(o)||u.set(o,{group:new Le});this.group.add(c.group),this.markKeep(c);var h=Twe(s,t,i);i.setData(h),h.each(function(d){var f=oe(MR,function(D){return PR(h,d,D,t,a)}),p=s.getAxis("x").scale,v=s.getAxis("y").scale,g=p.getExtent(),m=v.getExtent(),y=[p.parse(h.get("x0",d)),p.parse(h.get("x1",d))],_=[v.parse(h.get("y0",d)),v.parse(h.get("y1",d))];Gn(y),Gn(_);var b=!(g[0]>y[1]||g[1]_[1]||m[1]<_[0]),T=!b;h.setItemLayout(d,{points:f,allClipped:T});var x=h.getItemModel(d).getModel("itemStyle").getItemStyle(),C=ag(l,"color");x.fill||(x.fill=C,pe(x.fill)&&(x.fill=Cy(x.fill,.4))),x.stroke||(x.stroke=C),h.setItemVisual(d,"style",x)}),h.diff(e0(c).data).add(function(d){var f=h.getItemLayout(d);if(!f.allClipped){var p=new Ii({shape:{points:f.points}});h.setItemGraphicEl(d,p),c.group.add(p)}}).update(function(d,f){var p=e0(c).data.getItemGraphicEl(f),v=h.getItemLayout(d);v.allClipped?p&&c.group.remove(p):(p?ct(p,{shape:{points:v.points}},i,d):p=new Ii({shape:{points:v.points}}),h.setItemGraphicEl(d,p),c.group.add(p))}).remove(function(d){var f=e0(c).data.getItemGraphicEl(d);c.group.remove(f)}).execute(),h.eachItemGraphicEl(function(d,f){var p=h.getItemModel(f),v=h.getItemVisual(f,"style");d.useStyle(h.getItemVisual(f,"style")),Jr(d,Nr(p),{labelFetcher:i,labelDataIndex:f,defaultText:h.getName(f)||"",inheritColor:pe(v.fill)?Cy(v.fill,1):"#000"}),Qr(d,p),Yt(d,null,null,p.get(["emphasis","disabled"])),ke(d).dataModel=i}),e0(c).data=h,c.group.silent=i.get("silent")||t.get("silent")},e.type="markArea",e}($E);function Twe(r,e,t){var i,n,a=["x0","y0","x1","y1"];if(r){var s=oe(r&&r.dimensions,function(u){var c=e.getData(),h=c.getDimensionInfo(c.mapDimension(u))||{};return J(J({},h),{name:u,ordinalMeta:null})});n=oe(a,function(u,c){return{name:u,type:s[c%2].type}}),i=new wi(n,t)}else n=[{name:"value",type:"float"}],i=new wi(n,t);var o=oe(t.get("data"),Ue(_we,e,r,t));r&&(o=Tt(o,Ue(bwe,r)));var l=r?function(u,c,h,d){var f=u.coord[Math.floor(d/2)][d%2];return jo(f,n[d])}:function(u,c,h,d){return jo(u.value,n[d])};return i.initData(o,null,l),i.hasItemOption=!0,i}function xwe(r){r.registerComponentModel(ywe),r.registerComponentView(Swe),r.registerPreprocessor(function(e){GE(e.series,"markArea")&&(e.markArea=e.markArea||{})})}var wwe=function(r,e){if(e==="all")return{type:"all",title:r.getLocaleModel().get(["legend","selector","all"])};if(e==="inverse")return{type:"inverse",title:r.getLocaleModel().get(["legend","selector","inverse"])}},tC=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.prototype.init=function(t,i,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{},this._updateSelector(t)},e.prototype.mergeOption=function(t,i){r.prototype.mergeOption.call(this,t,i),this._updateSelector(t)},e.prototype._updateSelector=function(t){var i=t.selector,n=this.ecModel;i===!0&&(i=t.selector=["all","inverse"]),ie(i)&&R(i,function(a,s){pe(a)&&(a={type:a}),i[s]=We(a,wwe(n,a.type))})},e.prototype.optionUpdated=function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&this.get("selectedMode")==="single"){for(var i=!1,n=0;n=0},e.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},e}(tt),Qc=Ue,rC=R,t0=Le,qj=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!1,t}return e.prototype.init=function(){this.group.add(this._contentGroup=new t0),this.group.add(this._selectorGroup=new t0),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,i,n){var a=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!t.get("show",!0)){var s=t.get("align"),o=t.get("orient");(!s||s==="auto")&&(s=t.get("left")==="right"&&o==="vertical"?"right":"left");var l=t.get("selector",!0),u=t.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=o==="horizontal"?"end":"start"),this.renderInner(s,t,i,n,l,o,u);var c=t.getBoxLayoutParams(),h={width:n.getWidth(),height:n.getHeight()},d=t.get("padding"),f=Ar(c,h,d),p=this.layoutInner(t,s,f,a,l,u),v=Ar(Ce({width:p.width,height:p.height},c),h,d);this.group.x=v.x-p.x,this.group.y=v.y-p.y,this.group.markRedraw(),this.group.add(this._backgroundEl=Rj(p,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,i,n,a,s,o,l){var u=this.getContentGroup(),c=be(),h=i.get("selectedMode"),d=[];n.eachRawSeries(function(f){!f.get("legendHoverLink")&&d.push(f.id)}),rC(i.getData(),function(f,p){var v=f.get("name");if(!this.newlineDisabled&&(v===""||v===` +`)){var g=new t0;g.newline=!0,u.add(g);return}var m=n.getSeriesByName(v)[0];if(!c.get(v))if(m){var y=m.getData(),_=y.getVisual("legendLineStyle")||{},b=y.getVisual("legendIcon"),T=y.getVisual("style"),x=this._createItem(m,v,p,f,i,t,_,T,b,h,a);x.on("click",Qc(LR,v,null,a,d)).on("mouseover",Qc(iC,m.name,null,a,d)).on("mouseout",Qc(nC,m.name,null,a,d)),n.ssr&&x.eachChild(function(C){var D=ke(C);D.seriesIndex=m.seriesIndex,D.dataIndex=p,D.ssrType="legend"}),c.set(v,!0)}else n.eachRawSeries(function(C){if(!c.get(v)&&C.legendVisualProvider){var D=C.legendVisualProvider;if(!D.containName(v))return;var I=D.indexOfName(v),M=D.getItemVisual(I,"style"),L=D.getItemVisual(I,"legendIcon"),N=gn(M.fill);N&&N[3]===0&&(N[3]=.2,M=J(J({},M),{fill:Os(N,"rgba")}));var O=this._createItem(C,v,p,f,i,t,{},M,L,h,a);O.on("click",Qc(LR,null,v,a,d)).on("mouseover",Qc(iC,null,v,a,d)).on("mouseout",Qc(nC,null,v,a,d)),n.ssr&&O.eachChild(function(B){var F=ke(B);F.seriesIndex=C.seriesIndex,F.dataIndex=p,F.ssrType="legend"}),c.set(v,!0)}},this)},this),s&&this._createSelector(s,i,a,o,l)},e.prototype._createSelector=function(t,i,n,a,s){var o=this.getSelectorGroup();rC(t,function(u){var c=u.type,h=new lt({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:c==="all"?"legendAllSelect":"legendInverseSelect"})}});o.add(h);var d=i.getModel("selectorLabel"),f=i.getModel(["emphasis","selectorLabel"]);Jr(h,{normal:d,emphasis:f},{defaultText:u.title}),zu(h)})},e.prototype._createItem=function(t,i,n,a,s,o,l,u,c,h,d){var f=t.visualDrawType,p=s.get("itemWidth"),v=s.get("itemHeight"),g=s.isSelected(i),m=a.get("symbolRotate"),y=a.get("symbolKeepAspect"),_=a.get("icon");c=_||c||"roundRect";var b=Cwe(c,a,l,u,f,g,d),T=new t0,x=a.getModel("textStyle");if(we(t.getLegendIcon)&&(!_||_==="inherit"))T.add(t.getLegendIcon({itemWidth:p,itemHeight:v,icon:c,iconRotate:m,itemStyle:b.itemStyle,lineStyle:b.lineStyle,symbolKeepAspect:y}));else{var C=_==="inherit"&&t.getData().getVisual("symbol")?m==="inherit"?t.getData().getVisual("symbolRotate"):m:0;T.add(Awe({itemWidth:p,itemHeight:v,icon:c,iconRotate:C,itemStyle:b.itemStyle,lineStyle:b.lineStyle,symbolKeepAspect:y}))}var D=o==="left"?p+5:-5,I=o,M=s.get("formatter"),L=i;pe(M)&&M?L=M.replace("{name}",i??""):we(M)&&(L=M(i));var N=g?x.getTextColor():a.get("inactiveColor");T.add(new lt({style:kt(x,{text:L,x:D,y:v/2,fill:N,align:I,verticalAlign:"middle"},{inheritColor:N})}));var O=new st({shape:T.getBoundingRect(),style:{fill:"transparent"}}),B=a.getModel("tooltip");return B.get("show")&&kf({el:O,componentModel:s,itemName:i,itemTooltipOption:B.option}),T.add(O),T.eachChild(function(F){F.silent=!0}),O.silent=!h,this.getContentGroup().add(T),zu(T),T.__legendDataIndex=n,T},e.prototype.layoutInner=function(t,i,n,a,s,o){var l=this.getContentGroup(),u=this.getSelectorGroup();Hu(t.get("orient"),l,t.get("itemGap"),n.width,n.height);var c=l.getBoundingRect(),h=[-c.x,-c.y];if(u.markRedraw(),l.markRedraw(),s){Hu("horizontal",u,t.get("selectorItemGap",!0));var d=u.getBoundingRect(),f=[-d.x,-d.y],p=t.get("selectorButtonGap",!0),v=t.getOrient().index,g=v===0?"width":"height",m=v===0?"height":"width",y=v===0?"y":"x";o==="end"?f[v]+=c[g]+p:h[v]+=d[g]+p,f[1-v]+=c[m]/2-d[m]/2,u.x=f[0],u.y=f[1],l.x=h[0],l.y=h[1];var _={x:0,y:0};return _[g]=c[g]+p+d[g],_[m]=Math.max(c[m],d[m]),_[y]=Math.min(0,d[y]+f[1-v]),_}else return l.x=h[0],l.y=h[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e}($t);function Cwe(r,e,t,i,n,a,s){function o(g,m){g.lineWidth==="auto"&&(g.lineWidth=m.lineWidth>0?2:0),rC(g,function(y,_){g[_]==="inherit"&&(g[_]=m[_])})}var l=e.getModel("itemStyle"),u=l.getItemStyle(),c=r.lastIndexOf("empty",0)===0?"fill":"stroke",h=l.getShallow("decal");u.decal=!h||h==="inherit"?i.decal:cf(h,s),u.fill==="inherit"&&(u.fill=i[n]),u.stroke==="inherit"&&(u.stroke=i[c]),u.opacity==="inherit"&&(u.opacity=(n==="fill"?i:t).opacity),o(u,i);var d=e.getModel("lineStyle"),f=d.getLineStyle();if(o(f,t),u.fill==="auto"&&(u.fill=i.fill),u.stroke==="auto"&&(u.stroke=i.fill),f.stroke==="auto"&&(f.stroke=i.fill),!a){var p=e.get("inactiveBorderWidth"),v=u[c];u.lineWidth=p==="auto"?i.lineWidth>0&&v?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),f.stroke=d.get("inactiveColor"),f.lineWidth=d.get("inactiveWidth")}return{itemStyle:u,lineStyle:f}}function Awe(r){var e=r.icon||"roundRect",t=yr(e,0,0,r.itemWidth,r.itemHeight,r.itemStyle.fill,r.symbolKeepAspect);return t.setStyle(r.itemStyle),t.rotation=(r.iconRotate||0)*Math.PI/180,t.setOrigin([r.itemWidth/2,r.itemHeight/2]),e.indexOf("empty")>-1&&(t.style.stroke=t.style.fill,t.style.fill="#fff",t.style.lineWidth=2),t}function LR(r,e,t,i){nC(r,e,t,i),t.dispatchAction({type:"legendToggleSelect",name:r??e}),iC(r,e,t,i)}function jj(r){for(var e=r.getZr().storage.getDisplayList(),t,i=0,n=e.length;in[s],g=[-f.x,-f.y];i||(g[a]=c[u]);var m=[0,0],y=[-p.x,-p.y],_=Be(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(v){var b=t.get("pageButtonPosition",!0);b==="end"?y[a]+=n[s]-p[s]:m[a]+=p[s]+_}y[1-a]+=f[o]/2-p[o]/2,c.setPosition(g),h.setPosition(m),d.setPosition(y);var T={x:0,y:0};if(T[s]=v?n[s]:f[s],T[o]=Math.max(f[o],p[o]),T[l]=Math.min(0,p[l]+y[1-a]),h.__rectSize=n[s],v){var x={x:0,y:0};x[s]=Math.max(n[s]-p[s]-_,0),x[o]=T[o],h.setClipPath(new st({shape:x})),h.__rectSize=x[s]}else d.eachChild(function(D){D.attr({invisible:!0,silent:!0})});var C=this._getPageInfo(t);return C.pageIndex!=null&&ct(c,{x:C.contentPosition[0],y:C.contentPosition[1]},v?t:null),this._updatePageInfoView(t,C),T},e.prototype._pageGo=function(t,i,n){var a=this._getPageInfo(i)[t];a!=null&&n.dispatchAction({type:"legendScroll",scrollDataIndex:a,legendId:i.id})},e.prototype._updatePageInfoView=function(t,i){var n=this._controllerGroup;R(["pagePrev","pageNext"],function(c){var h=c+"DataIndex",d=i[h]!=null,f=n.childOfName(c);f&&(f.setStyle("fill",d?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),f.cursor=d?"pointer":"default")});var a=n.childOfName("pageText"),s=t.get("pageFormatter"),o=i.pageIndex,l=o!=null?o+1:0,u=i.pageCount;a&&s&&a.setStyle("text",pe(s)?s.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):s({current:l,total:u}))},e.prototype._getPageInfo=function(t){var i=t.get("scrollDataIndex",!0),n=this.getContentGroup(),a=this._containerGroup.__rectSize,s=t.getOrient().index,o=sT[s],l=oT[s],u=this._findTargetItemIndex(i),c=n.children(),h=c[u],d=c.length,f=d?1:0,p={contentPosition:[n.x,n.y],pageCount:f,pageIndex:f-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!h)return p;var v=b(h);p.contentPosition[s]=-v.s;for(var g=u+1,m=v,y=v,_=null;g<=d;++g)_=b(c[g]),(!_&&y.e>m.s+a||_&&!T(_,m.s))&&(y.i>m.i?m=y:m=_,m&&(p.pageNextDataIndex==null&&(p.pageNextDataIndex=m.i),++p.pageCount)),y=_;for(var g=u-1,m=v,y=v,_=null;g>=-1;--g)_=b(c[g]),(!_||!T(y,_.s))&&m.i=C&&x.s<=C+a}},e.prototype._findTargetItemIndex=function(t){if(!this._showController)return 0;var i,n=this.getContentGroup(),a;return n.eachChild(function(s,o){var l=s.__legendDataIndex;a==null&&l!=null&&(a=o),l===t&&(i=o)}),i??a},e.type="legend.scroll",e}(qj);function Mwe(r){r.registerAction("legendScroll","legendscroll",function(e,t){var i=e.scrollDataIndex;i!=null&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},function(n){n.setScrollDataIndex(i)})})}function Lwe(r){Ze(Xj),r.registerComponentModel(Iwe),r.registerComponentView(Pwe),Mwe(r)}function kwe(r){Ze(Xj),Ze(Lwe)}var Rwe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.inside",e.defaultOption=hl(Lv.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e}(Lv),WE=ot();function Owe(r,e,t){WE(r).coordSysRecordMap.each(function(i){var n=i.dataZoomInfoMap.get(e.uid);n&&(n.getRange=t)})}function Nwe(r,e){for(var t=WE(r).coordSysRecordMap,i=t.keys(),n=0;ni[t+e]&&(e=o),n=n&&s.get("preventDefaultMouseMove",!0)}),{controlType:e,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!n}}}function zwe(r){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,function(e,t){var i=WE(t),n=i.coordSysRecordMap||(i.coordSysRecordMap=be());n.each(function(a){a.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(a){var s=Mj(a);R(s.infoList,function(o){var l=o.model.uid,u=n.get(l)||n.set(l,Bwe(t,o.model)),c=u.dataZoomInfoMap||(u.dataZoomInfoMap=be());c.set(a.uid,{dzReferCoordSysInfo:o,model:a,getRange:null})})}),n.each(function(a){var s=a.controller,o,l=a.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(o=l.get(u))}if(!o){Yj(n,a);return}var c=Vwe(l);s.enable(c.controlType,c.opt),s.setPointerChecker(a.containsPoint),Vf(a,"dispatchAction",o.model.get("throttle",!0),"fixRate")})})}var Gwe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return e.prototype.render=function(t,i,n){if(r.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),Owe(n,t,{pan:ge(lT.pan,this),zoom:ge(lT.zoom,this),scrollMove:ge(lT.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){Nwe(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e}(NE),lT={zoom:function(r,e,t,i){var n=this.range,a=n.slice(),s=r.axisModels[0];if(s){var o=uT[e](null,[i.originX,i.originY],s,t,r),l=(o.signal>0?o.pixelStart+o.pixelLength-o.pixel:o.pixel-o.pixelStart)/o.pixelLength*(a[1]-a[0])+a[0],u=Math.max(1/i.scale,0);a[0]=(a[0]-l)*u+l,a[1]=(a[1]-l)*u+l;var c=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(vc(0,a,[0,100],0,c.minSpan,c.maxSpan),this.range=a,n[0]!==a[0]||n[1]!==a[1])return a}},pan:OR(function(r,e,t,i,n,a){var s=uT[i]([a.oldX,a.oldY],[a.newX,a.newY],e,n,t);return s.signal*(r[1]-r[0])*s.pixel/s.pixelLength}),scrollMove:OR(function(r,e,t,i,n,a){var s=uT[i]([0,0],[a.scrollDelta,a.scrollDelta],e,n,t);return s.signal*(r[1]-r[0])*a.scrollDelta})};function OR(r){return function(e,t,i,n){var a=this.range,s=a.slice(),o=e.axisModels[0];if(o){var l=r(s,o,e,t,i,n);if(vc(l,s,[0,100],"all"),this.range=s,a[0]!==s[0]||a[1]!==s[1])return s}}}var uT={grid:function(r,e,t,i,n){var a=t.axis,s={},o=n.model.coordinateSystem.getRect();return r=r||[0,0],a.dim==="x"?(s.pixel=e[0]-r[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=e[1]-r[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s},polar:function(r,e,t,i,n){var a=t.axis,s={},o=n.model.coordinateSystem,l=o.getRadiusAxis().getExtent(),u=o.getAngleAxis().getExtent();return r=r?o.pointToCoord(r):[0,0],e=o.pointToCoord(e),t.mainType==="radiusAxis"?(s.pixel=e[0]-r[0],s.pixelLength=l[1]-l[0],s.pixelStart=l[0],s.signal=a.inverse?1:-1):(s.pixel=e[1]-r[1],s.pixelLength=u[1]-u[0],s.pixelStart=u[0],s.signal=a.inverse?-1:1),s},singleAxis:function(r,e,t,i,n){var a=t.axis,s=n.model.coordinateSystem.getRect(),o={};return r=r||[0,0],a.orient==="horizontal"?(o.pixel=e[0]-r[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o}};function Kj(r){BE(r),r.registerComponentModel(Rwe),r.registerComponentView(Gwe),zwe(r)}var Hwe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=hl(Lv.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),e}(Lv),Vd=st,NR=7,$we=1,cT=30,Wwe=7,zd="horizontal",BR="vertical",qwe=5,jwe=["line","bar","candlestick","scatter"],Xwe={easing:"cubicOut",duration:100,delay:0},Ywe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._displayables={},t}return e.prototype.init=function(t,i){this.api=i,this._onBrush=ge(this._onBrush,this),this._onBrushEnd=ge(this._onBrushEnd,this)},e.prototype.render=function(t,i,n,a){if(r.prototype.render.apply(this,arguments),Vf(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),t.get("show")===!1){this.group.removeAll();return}if(t.noTarget()){this._clear(),this.group.removeAll();return}(!a||a.type!=="dataZoom"||a.from!==this.uid)&&this._buildView(),this._updateView()},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){_v(this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},e.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var i=this._displayables.sliderGroup=new Le;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(i),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,i=this.api,n=t.get("brushSelect"),a=n?Wwe:0,s=this._findCoordRect(),o={width:i.getWidth(),height:i.getHeight()},l=this._orient===zd?{right:o.width-s.x-s.width,top:o.height-cT-NR-a,width:s.width,height:cT}:{right:NR,top:s.y,width:cT,height:s.height},u=Bf(t.option);R(["right","top","width","height"],function(h){u[h]==="ph"&&(u[h]=l[h])});var c=Ar(u,o);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===BR&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,i=this._location,n=this._orient,a=this.dataZoomModel.getFirstTargetAxisModel(),s=a&&a.get("inverse"),o=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;o.attr(n===zd&&!s?{scaleY:l?1:-1,scaleX:1}:n===zd&&s?{scaleY:l?1:-1,scaleX:-1}:n===BR&&!s?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=t.getBoundingRect([o]);t.x=i.x-u.x,t.y=i.y-u.y,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,i=this._size,n=this._displayables.sliderGroup,a=t.get("brushSelect");n.add(new Vd({silent:!0,shape:{x:0,y:0,width:i[0],height:i[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var s=new Vd({shape:{x:0,y:0,width:i[0],height:i[1]},style:{fill:"transparent"},z2:0,onclick:ge(this._onClickPanel,this)}),o=this.api.getZr();a?(s.on("mousedown",this._onBrushStart,this),s.cursor="crosshair",o.on("mousemove",this._onBrush),o.on("mouseup",this._onBrushEnd)):(o.off("mousemove",this._onBrush),o.off("mouseup",this._onBrushEnd)),n.add(s)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!t)return;var i=this._size,n=this._shadowSize||[],a=t.series,s=a.getRawData(),o=a.getShadowDim&&a.getShadowDim(),l=o&&s.getDimensionInfo(o)?a.getShadowDim():t.otherDim;if(l==null)return;var u=this._shadowPolygonPts,c=this._shadowPolylinePts;if(s!==this._shadowData||l!==this._shadowDim||i[0]!==n[0]||i[1]!==n[1]){var h=s.getDataExtent(l),d=(h[1]-h[0])*.3;h=[h[0]-d,h[1]+d];var f=[0,i[1]],p=[0,i[0]],v=[[i[0],0],[0,0]],g=[],m=p[1]/(s.count()-1),y=0,_=Math.round(s.count()/i[0]),b;s.each([l],function(I,M){if(_>0&&M%_){y+=m;return}var L=I==null||isNaN(I)||I==="",N=L?0:bt(I,h,f,!0);L&&!b&&M?(v.push([v[v.length-1][0],0]),g.push([g[g.length-1][0],0])):!L&&b&&(v.push([y,0]),g.push([y,0])),v.push([y,N]),g.push([y,N]),y+=m,b=L}),u=this._shadowPolygonPts=v,c=this._shadowPolylinePts=g}this._shadowData=s,this._shadowDim=l,this._shadowSize=[i[0],i[1]];var T=this.dataZoomModel;function x(I){var M=T.getModel(I?"selectedDataBackground":"dataBackground"),L=new Le,N=new Ii({shape:{points:u},segmentIgnoreThreshold:1,style:M.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),O=new Pi({shape:{points:c},segmentIgnoreThreshold:1,style:M.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return L.add(N),L.add(O),L}for(var C=0;C<3;C++){var D=x(C===1);this._displayables.sliderGroup.add(D),this._displayables.dataShadowSegs.push(D)}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,i=t.get("showDataShadow");if(i!==!1){var n,a=this.ecModel;return t.eachTargetAxis(function(s,o){var l=t.getAxisProxy(s,o).getTargetSeriesModels();R(l,function(u){if(!n&&!(i!==!0&&Xe(jwe,u.get("type"))<0)){var c=a.getComponent(Go(s),o).axis,h=Kwe(s),d,f=u.coordinateSystem;h!=null&&f.getOtherAxis&&(d=f.getOtherAxis(c).inverse),h=u.getData().mapDimension(h),n={thisAxis:c,series:u,thisDim:s,otherDim:h,otherAxisInverse:d}}},this)},this),n}},e.prototype._renderHandle=function(){var t=this.group,i=this._displayables,n=i.handles=[null,null],a=i.handleLabels=[null,null],s=this._displayables.sliderGroup,o=this._size,l=this.dataZoomModel,u=this.api,c=l.get("borderRadius")||0,h=l.get("brushSelect"),d=i.filler=new Vd({silent:h,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});s.add(d),s.add(new Vd({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:o[0],height:o[1],r:c},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:$we,fill:"rgba(0,0,0,0)"}})),R([0,1],function(_){var b=l.get("handleIcon");!Vy[b]&&b.indexOf("path://")<0&&b.indexOf("image://")<0&&(b="path://"+b);var T=yr(b,-1,0,2,2,null,!0);T.attr({cursor:FR(this._orient),draggable:!0,drift:ge(this._onDragMove,this,_),ondragend:ge(this._onDragEnd,this),onmouseover:ge(this._showDataInfo,this,!0),onmouseout:ge(this._showDataInfo,this,!1),z2:5});var x=T.getBoundingRect(),C=l.get("handleSize");this._handleHeight=ce(C,this._size[1]),this._handleWidth=x.width/x.height*this._handleHeight,T.setStyle(l.getModel("handleStyle").getItemStyle()),T.style.strokeNoScale=!0,T.rectHover=!0,T.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),zu(T);var D=l.get("handleColor");D!=null&&(T.style.fill=D),s.add(n[_]=T);var I=l.getModel("textStyle");t.add(a[_]=new lt({silent:!0,invisible:!0,style:kt(I,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:I.getTextColor(),font:I.getFont()}),z2:10}))},this);var f=d;if(h){var p=ce(l.get("moveHandleSize"),o[1]),v=i.moveHandle=new st({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:o[1]-.5,height:p}}),g=p*.8,m=i.moveHandleIcon=yr(l.get("moveHandleIcon"),-g/2,-g/2,g,g,"#fff",!0);m.silent=!0,m.y=o[1]+p/2-.5,v.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var y=Math.min(o[1]/2,Math.max(p,10));f=i.moveZone=new st({invisible:!0,shape:{y:o[1]-y,height:p+y}}),f.on("mouseover",function(){u.enterEmphasis(v)}).on("mouseout",function(){u.leaveEmphasis(v)}),s.add(v),s.add(m),s.add(f)}f.attr({draggable:!0,cursor:FR(this._orient),drift:ge(this._onDragMove,this,"all"),ondragstart:ge(this._showDataInfo,this,!0),ondragend:ge(this._onDragEnd,this),onmouseover:ge(this._showDataInfo,this,!0),onmouseout:ge(this._showDataInfo,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),i=this._getViewExtent();this._handleEnds=[bt(t[0],[0,100],i,!0),bt(t[1],[0,100],i,!0)]},e.prototype._updateInterval=function(t,i){var n=this.dataZoomModel,a=this._handleEnds,s=this._getViewExtent(),o=n.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];vc(i,a,s,n.get("zoomLock")?"all":t,o.minSpan!=null?bt(o.minSpan,l,s,!0):null,o.maxSpan!=null?bt(o.maxSpan,l,s,!0):null);var u=this._range,c=this._range=Gn([bt(a[0],s,l,!0),bt(a[1],s,l,!0)]);return!u||u[0]!==c[0]||u[1]!==c[1]},e.prototype._updateView=function(t){var i=this._displayables,n=this._handleEnds,a=Gn(n.slice()),s=this._size;R([0,1],function(f){var p=i.handles[f],v=this._handleHeight;p.attr({scaleX:v/2,scaleY:v/2,x:n[f]+(f?-1:1),y:s[1]/2-v/2})},this),i.filler.setShape({x:a[0],y:0,width:a[1]-a[0],height:s[1]});var o={x:a[0],width:a[1]-a[0]};i.moveHandle&&(i.moveHandle.setShape(o),i.moveZone.setShape(o),i.moveZone.getBoundingRect(),i.moveHandleIcon&&i.moveHandleIcon.attr("x",o.x+o.width/2));for(var l=i.dataShadowSegs,u=[0,a[0],a[1],s[0]],c=0;ci[0]||n[1]<0||n[1]>i[1])){var a=this._handleEnds,s=(a[0]+a[1])/2,o=this._updateInterval("all",n[0]-s);this._updateView(),o&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var i=t.offsetX,n=t.offsetY;this._brushStart=new He(i,n),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(this._brushing){var i=this._displayables.brushRect;if(this._brushing=!1,!!i){i.attr("ignore",!0);var n=i.shape,a=+new Date;if(!(a-this._brushStartTime<200&&Math.abs(n.width)<5)){var s=this._getViewExtent(),o=[0,100];this._range=Gn([bt(n.x,s,o,!0),bt(n.x+n.width,s,o,!0)]),this._handleEnds=[n.x,n.x+n.width],this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&($s(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,i){var n=this._displayables,a=this.dataZoomModel,s=n.brushRect;s||(s=n.brushRect=new Vd({silent:!0,style:a.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(s)),s.attr("ignore",!1);var o=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(t,i),c=l.transformCoordToLocal(o.x,o.y),h=this._size;u[0]=Math.max(Math.min(h[0],u[0]),0),s.setShape({x:c[0],y:0,width:u[0]-c[0],height:h[1]})},e.prototype._dispatchZoomAction=function(t){var i=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?Xwe:null,start:i[0],end:i[1]})},e.prototype._findCoordRect=function(){var t,i=Mj(this.dataZoomModel).infoList;if(!t&&i.length){var n=i[0].model.coordinateSystem;t=n.getRect&&n.getRect()}if(!t){var a=this.api.getWidth(),s=this.api.getHeight();t={x:a*.2,y:s*.2,width:a*.6,height:s*.6}}return t},e.type="dataZoom.slider",e}(NE);function Kwe(r){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[r]}function FR(r){return r==="vertical"?"ns-resize":"ew-resize"}function Zj(r){r.registerComponentModel(Hwe),r.registerComponentView(Ywe),BE(r)}function Zwe(r){Ze(Kj),Ze(Zj)}var Qj={get:function(r,e,t){var i=Ee((Qwe[r]||{})[e]);return t&&ie(i)?i[i.length-1]:i}},Qwe={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}},UR=Or.mapVisual,Jwe=Or.eachVisual,eCe=ie,VR=R,tCe=Gn,rCe=bt,c_=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.stateList=["inRange","outOfRange"],t.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],t.layoutMode={type:"box",ignoreSize:!0},t.dataBound=[-1/0,1/0],t.targetVisuals={},t.controllerVisuals={},t}return e.prototype.init=function(t,i,n){this.mergeDefaultAndTheme(t,n)},e.prototype.optionUpdated=function(t,i){var n=this.option;!i&&zj(n,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var i=this.stateList;t=ge(t,this),this.controllerVisuals=Qw(this.option.controller,i,t),this.targetVisuals=Qw(this.option.target,i,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesIndex,i=[];return t==null||t==="all"?this.ecModel.eachSeries(function(n,a){i.push(a)}):i=xt(t),i},e.prototype.eachTargetSeries=function(t,i){R(this.getTargetSeriesIndices(),function(n){var a=this.ecModel.getSeriesByIndex(n);a&&t.call(i,a)},this)},e.prototype.isTargetSeries=function(t){var i=!1;return this.eachTargetSeries(function(n){n===t&&(i=!0)}),i},e.prototype.formatValueText=function(t,i,n){var a=this.option,s=a.precision,o=this.dataBound,l=a.formatter,u;n=n||["<",">"],ie(t)&&(t=t.slice(),u=!0);var c=i?t:u?[h(t[0]),h(t[1])]:h(t);if(pe(l))return l.replace("{value}",u?c[0]:c).replace("{value2}",u?c[1]:c);if(we(l))return u?l(t[0],t[1]):l(t);if(u)return t[0]===o[0]?n[0]+" "+c[1]:t[1]===o[1]?n[1]+" "+c[0]:c[0]+" - "+c[1];return c;function h(d){return d===o[0]?"min":d===o[1]?"max":(+d).toFixed(Math.min(s,20))}},e.prototype.resetExtent=function(){var t=this.option,i=tCe([t.min,t.max]);this._dataExtent=i},e.prototype.getDataDimensionIndex=function(t){var i=this.option.dimension;if(i!=null)return t.getDimensionIndex(i);for(var n=t.dimensions,a=n.length-1;a>=0;a--){var s=n[a],o=t.getDimensionInfo(s);if(!o.isCalculationCoord)return o.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,i=this.option,n={inRange:i.inRange,outOfRange:i.outOfRange},a=i.target||(i.target={}),s=i.controller||(i.controller={});We(a,n),We(s,n);var o=this.isCategory();l.call(this,a),l.call(this,s),u.call(this,a,"inRange","outOfRange"),c.call(this,s);function l(h){eCe(i.color)&&!h.inRange&&(h.inRange={color:i.color.slice().reverse()}),h.inRange=h.inRange||{color:t.get("gradientColor")}}function u(h,d,f){var p=h[d],v=h[f];p&&!v&&(v=h[f]={},VR(p,function(g,m){if(Or.isValidType(m)){var y=Qj.get(m,"inactive",o);y!=null&&(v[m]=y,m==="color"&&!v.hasOwnProperty("opacity")&&!v.hasOwnProperty("colorAlpha")&&(v.opacity=[0,0]))}}))}function c(h){var d=(h.inRange||{}).symbol||(h.outOfRange||{}).symbol,f=(h.inRange||{}).symbolSize||(h.outOfRange||{}).symbolSize,p=this.get("inactiveColor"),v=this.getItemSymbol(),g=v||"roundRect";VR(this.stateList,function(m){var y=this.itemSize,_=h[m];_||(_=h[m]={color:o?p:[p]}),_.symbol==null&&(_.symbol=d&&Ee(d)||(o?g:[g])),_.symbolSize==null&&(_.symbolSize=f&&Ee(f)||(o?y[0]:[y[0],y[0]])),_.symbol=UR(_.symbol,function(x){return x==="none"?g:x});var b=_.symbolSize;if(b!=null){var T=-1/0;Jwe(b,function(x){x>T&&(T=x)}),_.symbolSize=UR(b,function(x){return rCe(x,[0,T],[0,y[0]],!0)})}},this)}},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.defaultOption={show:!0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},e}(tt),zR=[20,140],iCe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(t,i){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(n){n.mappingMethod="linear",n.dataExtent=this.getExtent()}),this._resetRange()},e.prototype.resetItemSize=function(){r.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=zR[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=zR[1])},e.prototype._resetRange=function(){var t=this.getExtent(),i=this.option.range;!i||i.auto?(t.auto=1,this.option.range=t):ie(i)&&(i[0]>i[1]&&i.reverse(),i[0]=Math.max(i[0],t[0]),i[1]=Math.min(i[1],t[1]))},e.prototype.completeVisualOption=function(){r.prototype.completeVisualOption.apply(this,arguments),R(this.stateList,function(t){var i=this.option.controller[t].symbolSize;i&&i[0]!==i[1]&&(i[0]=i[1]/3)},this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),i=Gn((this.get("range")||[]).slice());return i[0]>t[1]&&(i[0]=t[1]),i[1]>t[1]&&(i[1]=t[1]),i[0]=n[1]||t<=i[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var i=[];return this.eachTargetSeries(function(n){var a=[],s=n.getData();s.each(this.getDataDimensionIndex(s),function(o,l){t[0]<=o&&o<=t[1]&&a.push(l)},this),i.push({seriesId:n.id,dataIndex:a})},this),i},e.prototype.getVisualMeta=function(t){var i=GR(this,"outOfRange",this.getExtent()),n=GR(this,"inRange",this.option.range.slice()),a=[];function s(f,p){a.push({value:f,color:t(f,p)})}for(var o=0,l=0,u=n.length,c=i.length;lt[1])break;a.push({color:this.getControllerVisual(l,"color",i),offset:o/n})}return a.push({color:this.getControllerVisual(t[1],"color",i),offset:1}),a},e.prototype._createBarPoints=function(t,i){var n=this.visualMapModel.itemSize;return[[n[0]-i[0],t[0]],[n[0],t[0]],[n[0],t[1]],[n[0]-i[1],t[1]]]},e.prototype._createBarGroup=function(t){var i=this._orient,n=this.visualMapModel.get("inverse");return new Le(i==="horizontal"&&!n?{scaleX:t==="bottom"?1:-1,rotation:Math.PI/2}:i==="horizontal"&&n?{scaleX:t==="bottom"?-1:1,rotation:-Math.PI/2}:i==="vertical"&&!n?{scaleX:t==="left"?1:-1,scaleY:-1}:{scaleX:t==="left"?1:-1})},e.prototype._updateHandle=function(t,i){if(this._useHandle){var n=this._shapes,a=this.visualMapModel,s=n.handleThumbs,o=n.handleLabels,l=a.itemSize,u=a.getExtent();nCe([0,1],function(c){var h=s[c];h.setStyle("fill",i.handlesColor[c]),h.y=t[c];var d=La(t[c],[0,l[1]],u,!0),f=this.getControllerVisual(d,"symbolSize");h.scaleX=h.scaleY=f/l[0],h.x=l[0]-f/2;var p=ma(n.handleLabelPoints[c],Gu(h,this.group));o[c].setStyle({x:p[0],y:p[1],text:a.formatValueText(this._dataInterval[c]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",n.mainGroup):"center"})},this)}},e.prototype._showIndicator=function(t,i,n,a){var s=this.visualMapModel,o=s.getExtent(),l=s.itemSize,u=[0,l[1]],c=this._shapes,h=c.indicator;if(h){h.attr("invisible",!1);var d={convertOpacityToAlpha:!0},f=this.getControllerVisual(t,"color",d),p=this.getControllerVisual(t,"symbolSize"),v=La(t,o,u,!0),g=l[0]-p/2,m={x:h.x,y:h.y};h.y=v,h.x=g;var y=ma(c.indicatorLabelPoint,Gu(h,this.group)),_=c.indicatorLabel;_.attr("invisible",!1);var b=this._applyTransform("left",c.mainGroup),T=this._orient,x=T==="horizontal";_.setStyle({text:(n||"")+s.formatValueText(i),verticalAlign:x?b:"middle",align:x?"center":b});var C={x:g,y:v,style:{fill:f}},D={style:{x:y[0],y:y[1]}};if(s.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var I={duration:100,easing:"cubicInOut",additive:!0};h.x=m.x,h.y=m.y,h.animateTo(C,I),_.animateTo(D,I)}else h.attr(C),_.attr(D);this._firstShowIndicator=!1;var M=this._shapes.handleLabels;if(M)for(var L=0;Ls[1]&&(h[1]=1/0),i&&(h[0]===-1/0?this._showIndicator(c,h[1],"< ",l):h[1]===1/0?this._showIndicator(c,h[0],"> ",l):this._showIndicator(c,c,"≈ ",l));var d=this._hoverLinkDataIndices,f=[];(i||qR(n))&&(f=this._hoverLinkDataIndices=n.findTargetDataIndices(h));var p=gue(d,f);this._dispatchHighDown("downplay",k0(p[0],n)),this._dispatchHighDown("highlight",k0(p[1],n))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var i;if(bu(t.target,function(l){var u=ke(l);if(u.dataIndex!=null)return i=u,!0},!0),!!i){var n=this.ecModel.getSeriesByIndex(i.seriesIndex),a=this.visualMapModel;if(a.isTargetSeries(n)){var s=n.getData(i.dataType),o=s.getStore().get(a.getDataDimensionIndex(s),i.dataIndex);isNaN(o)||this._showIndicator(o,o)}}},e.prototype._hideIndicator=function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0);var i=this._shapes.handleLabels;if(i)for(var n=0;n=0&&(a.dimension=s,i.push(a))}}),r.getData().setVisual("visualMeta",i)}}];function fCe(r,e,t,i){for(var n=e.targetVisuals[i],a=Or.prepareVisualTypes(n),s={color:ag(r.getData(),"color")},o=0,l=a.length;o0:e.splitNumber>0)||e.calculable)?"continuous":"piecewise"}),r.registerAction(uCe,cCe),R(hCe,function(e){r.registerVisual(r.PRIORITY.VISUAL.COMPONENT,e)}),r.registerPreprocessor(dCe))}function rX(r){r.registerComponentModel(iCe),r.registerComponentView(oCe),tX(r)}var pCe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._pieceList=[],t}return e.prototype.optionUpdated=function(t,i){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var n=this._mode=this._determineMode();this._pieceList=[],vCe[this._mode].call(this,this._pieceList),this._resetSelected(t,i);var a=this.option.categories;this.resetVisual(function(s,o){n==="categories"?(s.mappingMethod="category",s.categories=Ee(a)):(s.dataExtent=this.getExtent(),s.mappingMethod="piecewise",s.pieceList=oe(this._pieceList,function(l){return l=Ee(l),o!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,i={},n=Or.listVisualTypes(),a=this.isCategory();R(t.pieces,function(o){R(n,function(l){o.hasOwnProperty(l)&&(i[l]=1)})}),R(i,function(o,l){var u=!1;R(this.stateList,function(c){u=u||s(t,c,l)||s(t.target,c,l)},this),!u&&R(this.stateList,function(c){(t[c]||(t[c]={}))[l]=Qj.get(l,c==="inRange"?"active":"inactive",a)})},this);function s(o,l,u){return o&&o[l]&&o[l].hasOwnProperty(u)}r.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,i){var n=this.option,a=this._pieceList,s=(i?n:t).selected||{};if(n.selected=s,R(a,function(l,u){var c=this.getSelectedMapKey(l);s.hasOwnProperty(c)||(s[c]=!0)},this),n.selectedMode==="single"){var o=!1;R(a,function(l,u){var c=this.getSelectedMapKey(l);s[c]&&(o?s[c]=!1:o=!0)},this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return this._mode==="categories"?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=Ee(t)},e.prototype.getValueState=function(t){var i=Or.findPieceIndex(t,this._pieceList);return i!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[i])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var i=[],n=this._pieceList;return this.eachTargetSeries(function(a){var s=[],o=a.getData();o.each(this.getDataDimensionIndex(o),function(l,u){var c=Or.findPieceIndex(l,n);c===t&&s.push(u)},this),i.push({seriesId:a.id,dataIndex:s})},this),i},e.prototype.getRepresentValue=function(t){var i;if(this.isCategory())i=t.value;else if(t.value!=null)i=t.value;else{var n=t.interval||[];i=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return i},e.prototype.getVisualMeta=function(t){if(this.isCategory())return;var i=[],n=["",""],a=this;function s(c,h){var d=a.getRepresentValue({interval:c});h||(h=a.getValueState(d));var f=t(d,h);c[0]===-1/0?n[0]=f:c[1]===1/0?n[1]=f:i.push({value:c[0],color:f},{value:c[1],color:f})}var o=this._pieceList.slice();if(!o.length)o.push({interval:[-1/0,1/0]});else{var l=o[0].interval[0];l!==-1/0&&o.unshift({interval:[-1/0,l]}),l=o[o.length-1].interval[1],l!==1/0&&o.push({interval:[l,1/0]})}var u=-1/0;return R(o,function(c){var h=c.interval;h&&(h[0]>u&&s([u,h[0]],"outOfRange"),s(h.slice()),u=h[1])},this),{stops:i,outerColors:n}},e.type="visualMap.piecewise",e.defaultOption=hl(c_.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),e}(c_),vCe={splitNumber:function(r){var e=this.option,t=Math.min(e.precision,20),i=this.getExtent(),n=e.splitNumber;n=Math.max(parseInt(n,10),1),e.splitNumber=n;for(var a=(i[1]-i[0])/n;+a.toFixed(t)!==a&&t<5;)t++;e.precision=t,a=+a.toFixed(t),e.minOpen&&r.push({interval:[-1/0,i[0]],close:[0,0]});for(var s=0,o=i[0];s","≥"][i[0]]];t.text=t.text||this.formatValueText(t.value!=null?t.value:t.interval,!1,n)},this)}};function KR(r,e){var t=r.inverse;(r.orient==="vertical"?!t:t)&&e.reverse()}var gCe=function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.doRender=function(){var t=this.group;t.removeAll();var i=this.visualMapModel,n=i.get("textGap"),a=i.textStyleModel,s=a.getFont(),o=a.getTextColor(),l=this._getItemAlign(),u=i.itemSize,c=this._getViewData(),h=c.endsText,d=Gr(i.get("showLabel",!0),!h);h&&this._renderEndsText(t,h[0],u,d,l),R(c.viewPieceList,function(f){var p=f.piece,v=new Le;v.onclick=ge(this._onItemClick,this,p),this._enableHoverLink(v,f.indexInModelPieceList);var g=i.getRepresentValue(p);if(this._createItemSymbol(v,g,[0,0,u[0],u[1]]),d){var m=this.visualMapModel.getValueState(g);v.add(new lt({style:{x:l==="right"?-n:u[0]+n,y:u[1]/2,text:p.text,verticalAlign:"middle",align:l,font:s,fill:o,opacity:m==="outOfRange"?.5:1}}))}t.add(v)},this),h&&this._renderEndsText(t,h[1],u,d,l),Hu(i.get("orient"),t,i.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,i){var n=this;t.on("mouseover",function(){return a("highlight")}).on("mouseout",function(){return a("downplay")});var a=function(s){var o=n.visualMapModel;o.option.hoverLink&&n.api.dispatchAction({type:s,batch:k0(o.findTargetDataIndices(i),o)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,i=t.option;if(i.orient==="vertical")return eX(t,this.api,t.itemSize);var n=i.align;return(!n||n==="auto")&&(n="left"),n},e.prototype._renderEndsText=function(t,i,n,a,s){if(i){var o=new Le,l=this.visualMapModel.textStyleModel;o.add(new lt({style:kt(l,{x:a?s==="right"?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:a?s:"center",text:i})})),t.add(o)}},e.prototype._getViewData=function(){var t=this.visualMapModel,i=oe(t.getPieceList(),function(o,l){return{piece:o,indexInModelPieceList:l}}),n=t.get("text"),a=t.get("orient"),s=t.get("inverse");return(a==="horizontal"?s:!s)?i.reverse():n&&(n=n.slice().reverse()),{viewPieceList:i,endsText:n}},e.prototype._createItemSymbol=function(t,i,n){t.add(yr(this.getControllerVisual(i,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(i,"color")))},e.prototype._onItemClick=function(t){var i=this.visualMapModel,n=i.option,a=n.selectedMode;if(a){var s=Ee(n.selected),o=i.getSelectedMapKey(t);a==="single"||a===!0?(s[o]=!0,R(s,function(l,u){s[u]=u===o})):s[o]=!s[o],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:s})}},e.type="visualMap.piecewise",e}(Jj);function iX(r){r.registerComponentModel(pCe),r.registerComponentView(gCe),tX(r)}function mCe(r){Ze(rX),Ze(iX)}var yCe={label:{enabled:!0},decal:{show:!1}},ZR=ot(),_Ce={};function bCe(r,e){var t=r.getModel("aria");if(!t.get("enabled"))return;var i=Ee(yCe);We(i.label,r.getLocaleModel().get("aria"),!1),We(t.option,i,!1),n(),a();function n(){var u=t.getModel("decal"),c=u.get("show");if(c){var h=be();r.eachSeries(function(d){if(!d.isColorBySeries()){var f=h.get(d.type);f||(f={},h.set(d.type,f)),ZR(d).scope=f}}),r.eachRawSeries(function(d){if(r.isSeriesFiltered(d))return;if(we(d.enableAriaDecal)){d.enableAriaDecal();return}var f=d.getData();if(d.isColorBySeries()){var y=nw(d.ecModel,d.name,_Ce,r.getSeriesCount()),_=f.getVisual("decal");f.setVisual("decal",b(_,y))}else{var p=d.getRawData(),v={},g=ZR(d).scope;f.each(function(T){var x=f.getRawIndex(T);v[x]=T});var m=p.count();p.each(function(T){var x=v[T],C=p.getName(T)||T+"",D=nw(d.ecModel,C,g,m),I=f.getItemVisual(x,"decal");f.setItemVisual(x,"decal",b(I,D))})}function b(T,x){var C=T?J(J({},x),T):x;return C.dirty=!0,C}})}}function a(){var u=e.getZr().dom;if(u){var c=r.getLocaleModel().get("aria"),h=t.getModel("label");if(h.option=Ce(h.option,c),!!h.get("enabled")){if(h.get("description")){u.setAttribute("aria-label",h.get("description"));return}var d=r.getSeriesCount(),f=h.get(["data","maxCount"])||10,p=h.get(["series","maxCount"])||10,v=Math.min(d,p),g;if(!(d<1)){var m=o();if(m){var y=h.get(["general","withTitle"]);g=s(y,{title:m})}else g=h.get(["general","withoutTitle"]);var _=[],b=d>1?h.get(["series","multiple","prefix"]):h.get(["series","single","prefix"]);g+=s(b,{seriesCount:d}),r.eachSeries(function(D,I){if(I1?h.get(["series","multiple",N]):h.get(["series","single",N]),M=s(M,{seriesId:D.seriesIndex,seriesName:D.get("name"),seriesType:l(D.subType)});var O=D.getData();if(O.count()>f){var B=h.get(["data","partialData"]);M+=s(B,{displayCnt:f})}else M+=h.get(["data","allData"]);for(var F=h.get(["data","separator","middle"]),U=h.get(["data","separator","end"]),$=[],q=0;q":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},xCe=function(){function r(e){var t=this._condVal=pe(e)?new RegExp(e):Noe(e)?e:null;if(t==null){var i="";vt(i)}}return r.prototype.evaluate=function(e){var t=typeof e;return pe(t)?this._condVal.test(e):ut(t)?this._condVal.test(e+""):!1},r}(),wCe=function(){function r(){}return r.prototype.evaluate=function(){return this.value},r}(),CCe=function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t2&&i.push(n),n=[O,B]}function c(O,B,F,U){_h(O,F)&&_h(B,U)||n.push(O,B,F,U,F,U)}function h(O,B,F,U,$,q){var Z=Math.abs(B-O),te=Math.tan(Z/4)*4/3,Q=BD:L2&&i.push(n),i}function sC(r,e,t,i,n,a,s,o,l,u){if(_h(r,t)&&_h(e,i)&&_h(n,s)&&_h(a,o)){l.push(s,o);return}var c=2/u,h=c*c,d=s-r,f=o-e,p=Math.sqrt(d*d+f*f);d/=p,f/=p;var v=t-r,g=i-e,m=n-s,y=a-o,_=v*v+g*g,b=m*m+y*y;if(_=0&&D=0){l.push(s,o);return}var I=[],M=[];tl(r,t,n,s,.5,I),tl(e,i,a,o,.5,M),sC(I[0],M[0],I[1],M[1],I[2],M[2],I[3],M[3],l,u),sC(I[4],M[4],I[5],M[5],I[6],M[6],I[7],M[7],l,u)}function UCe(r,e){var t=aC(r),i=[];e=e||1;for(var n=0;n0)for(var u=0;uMath.abs(u),h=aX([l,u],c?0:1,e),d=(c?o:u)/h.length,f=0;fn,s=aX([i,n],a?0:1,e),o=a?"width":"height",l=a?"height":"width",u=a?"x":"y",c=a?"y":"x",h=r[o]/s.length,d=0;d1?null:new He(v*l+r,v*u+e)}function GCe(r,e,t){var i=new He;He.sub(i,t,e),i.normalize();var n=new He;He.sub(n,r,e);var a=n.dot(i);return a}function eh(r,e){var t=r[r.length-1];t&&t[0]===e[0]&&t[1]===e[1]||r.push(e)}function HCe(r,e,t){for(var i=r.length,n=[],a=0;as?(u.x=c.x=o+a/2,u.y=l,c.y=l+s):(u.y=c.y=l+s/2,u.x=o,c.x=o+a),HCe(e,u,c)}function h_(r,e,t,i){if(t===1)i.push(e);else{var n=Math.floor(t/2),a=r(e);h_(r,a[0],n,i),h_(r,a[1],t-n,i)}return i}function $Ce(r,e){for(var t=[],i=0;i0;u/=2){var c=0,h=0;(r&u)>0&&(c=1),(e&u)>0&&(h=1),o+=u*u*(3*c^h),h===0&&(c===1&&(r=u-1-r,e=u-1-e),l=r,r=e,e=l)}return o}function p_(r){var e=1/0,t=1/0,i=-1/0,n=-1/0,a=oe(r,function(o){var l=o.getBoundingRect(),u=o.getComputedTransform(),c=l.x+l.width/2+(u?u[4]:0),h=l.y+l.height/2+(u?u[5]:0);return e=Math.min(c,e),t=Math.min(h,t),i=Math.max(c,i),n=Math.max(h,n),[c,h]}),s=oe(a,function(o,l){return{cp:o,z:JCe(o[0],o[1],e,t,i,n),path:r[l]}});return s.sort(function(o,l){return o.z-l.z}).map(function(o){return o.path})}function lX(r){return jCe(r.path,r.count)}function oC(){return{fromIndividuals:[],toIndividuals:[],count:0}}function eAe(r,e,t){var i=[];function n(T){for(var x=0;x=0;n--)if(!t[n].many.length){var l=t[o].many;if(l.length<=1)if(o)o=0;else return t;var a=l.length,u=Math.ceil(a/2);t[n].many=l.slice(u,a),t[o].many=l.slice(0,u),o++}return t}var rAe={clone:function(r){for(var e=[],t=1-Math.pow(1-r.path.style.opacity,1/r.count),i=0;i0))return;var o=i.getModel("universalTransition").get("delay"),l=Object.assign({setToFinal:!0},s),u,c;s6(r)&&(u=r,c=e),s6(e)&&(u=e,c=r);function h(m,y,_,b,T){var x=m.many,C=m.one;if(x.length===1&&!T){var D=y?x[0]:C,I=y?C:x[0];if(f_(D))h({many:[D],one:I},!0,_,b,!0);else{var M=o?Ce({delay:o(_,b)},l):l;jE(D,I,M),a(D,I,D,I,M)}}else for(var L=Ce({dividePath:rAe[t],individualDelay:o&&function($,q,Z,te){return o($+_,b)}},l),N=y?eAe(x,C,L):tAe(C,x,L),O=N.fromIndividuals,B=N.toIndividuals,F=O.length,U=0;Ue.length,f=u?o6(c,u):o6(d?e:r,[d?r:e]),p=0,v=0;vuX))for(var a=i.getIndices(),s=0;s0&&x.group.traverse(function(D){D instanceof Qe&&!D.animators.length&&D.animateFrom({style:{opacity:0}},C)})})}function f6(r){var e=r.getModel("universalTransition").get("seriesKey");return e||r.id}function d6(r){return ie(r)?r.sort().join(","):r}function Io(r){if(r.hostModel)return r.hostModel.getModel("universalTransition").get("divideShape")}function uAe(r,e){var t=be(),i=be(),n=be();return R(r.oldSeries,function(a,s){var o=r.oldDataGroupIds[s],l=r.oldData[s],u=f6(a),c=d6(u);i.set(c,{dataGroupId:o,data:l}),ie(u)&&R(u,function(h){n.set(h,{key:c,dataGroupId:o,data:l})})}),R(e.updatedSeries,function(a){if(a.isUniversalTransitionEnabled()&&a.isAnimationEnabled()){var s=a.get("dataGroupId"),o=a.getData(),l=f6(a),u=d6(l),c=i.get(u);if(c)t.set(u,{oldSeries:[{dataGroupId:c.dataGroupId,divide:Io(c.data),data:c.data}],newSeries:[{dataGroupId:s,divide:Io(o),data:o}]});else if(ie(l)){var h=[];R(l,function(p){var v=i.get(p);v.data&&h.push({dataGroupId:v.dataGroupId,divide:Io(v.data),data:v.data})}),h.length&&t.set(u,{oldSeries:h,newSeries:[{dataGroupId:s,data:o,divide:Io(o)}]})}else{var d=n.get(l);if(d){var f=t.get(d.key);f||(f={oldSeries:[{dataGroupId:d.dataGroupId,data:d.data,divide:Io(d.data)}],newSeries:[]},t.set(d.key,f)),f.newSeries.push({dataGroupId:s,data:o,divide:Io(o)})}}}}),t}function p6(r,e){for(var t=0;t=0&&n.push({dataGroupId:e.oldDataGroupIds[o],data:e.oldData[o],divide:Io(e.oldData[o]),groupIdDim:s.dimension})}),R(xt(r.to),function(s){var o=p6(t.updatedSeries,s);if(o>=0){var l=t.updatedSeries[o].getData();a.push({dataGroupId:e.oldDataGroupIds[o],data:l,divide:Io(l),groupIdDim:s.dimension})}}),n.length>0&&a.length>0&&cX(n,a,i)}function hAe(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,i){R(xt(i.seriesTransition),function(n){R(xt(n.to),function(a){for(var s=i.updatedSeries,o=0;o{r.addEventListener("click",e=>{let t=e.target.getAttribute("id");document.querySelectorAll(".panel").forEach(n=>{n.getAttribute("id")===t+"_panel"?n.hidden=!1:n.hidden=!0})})});var dAe=document.querySelectorAll(".track")[0].querySelector(".track-viz"),pAe=E$(dAe),lC;lC={grid:{top:0,bottom:0,right:0,left:0},xAxis:{type:"time",data:[0,4.722,7.537,10.364,14.103,16.898,20.082,23.652,35.462,37.952,40.222,43.132,46.902,51.041,54.442,57.302,60.062,62.712,65.822,69.333,72.013,76.602,79.521,83.082,86.825,90.42,93.734,97.512,100.594,106.371,108.752,111.292,114.304,116.902,119.991,123.851,128.193,131.702,135.749,137.851,140.301,142.471,145.302,147.432,151.712,155.272,160.093,163.942,181.852,185.292,190.261,192.501,194.804,199.245,204.112,206.952,209.419,211.475,213.641,215.743,217.881,220.243,222.712,224.802,226.811,229.191,231.891,234.182,236.784,238.934,242.421,245.101,247.711,249.982,252.841,254.962,257.612,260.432,263.971,266.403,270.611,273.072,275.331,278.43,281.71,284.661,287.514,290.011,292.362,298.051,301.111,303.341,306.641,308.722,310.732,312.802,315.101,319.461,323.131,325.662,328.103,330.957,334.924,338.411,342.032,345.231,348.711,352.072,354.371,357.061,359.215,361.412,363.651,367.013,369.491,373.865,377.531,381.251,384.065,386.921,389.416,393.051,395.471,398.834,402.411,404.381,407.361,409.241,411.181,413.371,415.241,417.214,419.211,421.821,424.042,426.111,429.101,431.023,435.403,438.06,440.226,445.161,449.621,452.181,457.771,459.812,461.811,463.67,465.541,468.161,470.31,472.721,474.711,476.631,478.851,482.063,484.901,487.172,490.38,493.571,496.286,498.781,501.751,504.306,507.31,509.721,512.14,514.418,516.64,518.851,521.933,524.77,533.221,535.731,538.801,541.343,543.639,545.841,547.9,552.421,556.634,560.531,563.322,566.131,568.681,570.999,573.061,575.11,577.251,579.44,582.641,585.471,587.721,591.171,595.69,597.68,600.091,602.151,604.241,606.703,608.819,611.362,614.006,617.37,620.253,622.401,624.901,627.1,629.27,631.67,636.532,639.203,645.751,647.96,651.123,655.021,657.51,659.681,662.41,666.29,673.334,675.893,678.791,681.385,684.82,688.894,690.97,692.971,694.951,697.23,700.88,703.98,706.88,709.81,713.181,716.62,718.797,719.81,723.76,726.23,728.681,732.198,736.42,738.67,740.76,743.42,745.66,748.789,750.59,752.57,754.27,756.11,758.14,762.302,766.11,768.43,770.49,772.79,776.637,779.56,782.87,786.691,788.81,791.568,794.34,796.6,798.71,801.15,803.3,806.081,808.2,810.95,813.512,815.432,817.322,819.243,821.162,823.23,825.33,827.49,829.636,831.79,834.09,837.439,840.77,843.17,846.2,850.45,852.987,855.47,857.631,859.91,862.03,864.81,867.67,869.891,873.052,876.169,879.803,883.35,886.17,888.46,893.982,896.029,897.99,900.17,902.74,905.96,908.301,910.299,912.3,914.15,916.12,918.19,921.35,924.03,927.799,930.96,933.01,935.23,938.17,940.85,943.339,946.039,948.36,950.343,952.4,954.47,956.352,958.27,960.232,962.277,964.309,966.449,969.66,972.132,974.27,976.56,980.619,983.261,986.05,988.126,990.457,993.85,996.479,1003.59,1006.67,1011.57,1017.14,1026.48,1030.659,1033.729,1036.742,1039.15,1046.311,1050.299,1052.589,1054.699,1057.86,1062.432,1066.021,1066.919,1071.629,1073.97,1076.113,1078.29,1080.79,1087.61,1090.369,1093.009,1095.12,1097.271,1099.561,1102.279,1105.989,1108.219,1111.209,1114.09,1116.659,1123.399,1127.01,1129.282,1133.727,1139.129,1143.399,1146.8,1149.72,1153.409,1158.269,1161.99,1165.441,1168.88,1172.129,1174.269,1176.342,1181.039,1182.94,1185.4,1188.689,1192.001,1195.349,1198.309,1200.469,1202.759,1206.017,1208.21,1210.919,1213.309,1215.269,1217.359,1219.96,1225.251,1233.285,1244.31,1246.269,1248.339,1250.889,1253.302,1256.739,1260.139,1262.72,1266.869,1269.27,1273.149,1275.339,1278.591,1284.859,1287.19,1289.464,1292.142,1294.338,1296.449,1298.529,1300.969,1303.789,1305.829,1307.879,1309.739,1312.548,1314.829,1316.909,1319.75,1321.922,1324.629,1327.35,1329.478,1331.866,1334.669,1337.899,1341.539,1347.718,1350.609,1353.279,1356.219,1359.479,1362.5,1364.568,1367.09,1369.127,1371.249,1374.201,1376.4,1378.472,1380.828,1383.678,1385.878,1388.619,1391.119,1393.579,1395.699,1397.93,1400.146,1403.959,1406.769,1409.329,1411.825,1414.868,1417.159,1420.298,1423.549,1425.839,1430.471,1434.088,1436.439,1438.598,1440.684,1442.879,1445.069,1447.811,1450.759,1454.058,1458.018,1461.269,1465.209,1469.358,1475.548,1481.431,1483.449,1490.328,1494.199,1502.978,1505.388,1510.068,1513.519,1517.529,1521.258,1523.538,1527.398,1531.253,1534.089,1538.458,1540.588,1545.83,1548.048,1552.13,1555.088,1558.478,1560.548,1563.038,1565.109,1567.169,1569.259,1571.278,1573.748,1575.838,1577.72,1579.649,1581.746,1584.019,1586.191,1588.469,1591.73,1595.128,1598.788,1600.999,1603.143,1605.327,1610.178,1612.428,1617.501,1621.319,1625.978,1628.508,1631.504,1634.528,1637.501,1641.02,1643.52,1645.648,1648.818,1652.458,1654.608,1658.159,1660.688,1662.82,1664.908,1668.988,1672.738,1677.887,1680.598,1682.469,1684.518,1686.825,1688.839,1691.449,1693.898,1696.431,1700.217,1702.608,1705.048,1707.42,1709.798,1712.467,1714.868,1717.257,1720.408,1723.109,1726.37,1730.927,1733.358,1736.188,1738.888,1740.943,1743.782,1746.058,1753.83,1762.849,1765.817,1771.408,1773.548,1777.068,1779.695,1782.757,1787.458,1789.77,1795.598,1797.948,1800.937,1803.918,1808.048,1812.548,1818.438,1821.328,1823.628,1826.02,1828.568,1831.128,1835.427,1838.127,1840.698,1844.968,1854.107,1857.247,1859.437,1861.518,1863.732,1868.859,1870.997,1875.137,1878.678,1882.848,1887.117,1892.744,1896.688,1902.978,1907.019,1909.107,1912.977,1917.788,1920.259,1923.607,1927.639,1931.307,1934.948,1939.277,1943.959,1951.548,1956.827,1960.609,1963.037,1965.167,1967.888,1970.508,1973.228,1976.427,1978.469,1980.762,1982.892,1986.928,1989.309,1992.427,1996.329,1998.829,2001.987,2005.332,2009.046,2012.067,2014.359,2016.471,2019.897,2023.347,2025.678,2027.737,2029.847,2034.297,2036.387,2038.877,2043.167,2049.197,2051.708,2054.28,2056.428,2058.967,2061.976,2066.206,2068.496,2072.757,2075.087,2078.867,2081.417,2083.844,2086.777,2088.897,2091.429,2093.637,2095.815,2098.617,2101.257,2106.217,2108.707,2111.287,2114.349,2117.247,2120.287,2124.067,2127.577,2131.81,2134.449,2138.717,2140.858,2143.087,2145.325,2147.387,2150.097,2152.176,2154.673,2157.437,2160.377,2163.167,2165.836,2168.398,2171.391,2176.107,2179.477,2182.06,2188.856,2194.167,2197.336,2201.836,2209.366,2214.637,2216.819,2219.057,2222.026,2226.688,2229.597,2232.528,2234.647,2237.976,2241.836,2244.217,2248.247,2251.137,2254.977,2258.689,2263.809,2265.937,2268.357,2270.546,2272.727,2274.987,2277.518,2279.757,2284.657,2287.447,2290.736,2295.659,2300.777,2305.586,2312.266,2319.407,2323.146,2325.856,2328.796,2331.749,2334.267,2337.621,2340.966,2343.146,2345.382,2348.156,2351.028,2353.957,2356.259,2358.312,2360.321,2362.246,2364.176,2366.106,2368.456,2370.566,2373.187,2375.308,2385.677,2388.326,2391.187,2393.296,2395.976,2398.966,2401.786,2407,2409.817,2412.105,2414.835,2418.116,2420.511,2422.666,2425.99,2430.826,2434.016,2436.266,2439.767,2443.237,2447.666,2450.786,2452.996,2455.477,2459.247,2462.167,2464.376,2467.856,2471.116,2474.247,2476.376,2479.26,2482.126,2485.226,2488.59,2490.656,2493.607,2497.635,2499.748,2501.886,2505.866,2508.646,2513.976,2518.196,2520.216,2523.436,2526.686,2529.517,2532.127,2534.766,2536.856,2538.946,2541.377,2544.186,2547.336,2552.106,2554.315,2558.816,2562.216,2564.278,2567.497,2569.415,2571.616,2574.296,2578.068,2580.056,2582.146,2584.116,2586.138,2588.156,2590.716,2592.849,2595.296,2597.458,2599.936,2602.396,2605.466,2607.606,2609.761,2612.256,2614.656,2617.586,2622.055,2624.558,2627.106,2629.219,2631.366,2634.066,2636.322,2638.485,2641.423,2643.515,2645.716,2647.823,2649.946,2652.226,2654.316,2656.355,2658.636,2662.526,2665.906,2667.956,2670.446,2672.545,2674.485,2676.435,2678.666,2680.644,2682.676,2684.917,2686.856,2689.006,2692.715,2695.706,2698.022,2700.256,2703.266,2705.436,2722.916,2725.395,2727.927,2730.066,2733.286,2736.207,2740.061,2744.825,2750.455,2753.216,2756.276,2759.126,2761.315,2764.365,2769.475,2772.325,2774.516,2778.127,2780.365,2783.145,2785.547,2788.276,2790.475,2792.685,2794.687,2797.877,2799.982,2803.625,2808.426,2810.191,2812.354,2816.715,2820.167,2824.346,2828.296,2831.375,2834.661,2837.966,2855.295,2858.64,2860.745,2862.871,2864.977,2867.185,2869.525,2872.155,2874.815,2877.077,2879.341,2882.356,2884.525,2887.225,2890.335,2893.347,2896.626,2899.045,2901.985,2908.769,2911.075,2914.215,2916.516,2918.635,2921.265,2924.696,2927.515,2929.945,2933.906,2938.546,2941.942,2946.566,2949.955,2952.318,2955.355,2957.515,2960.715,2965.795,2968.475,2970.625,2973.026,2978.155,2980.005,2982.085,2984.126,2986.136,2988.565,2990.515,2992.986,2994.965,2997.145,3001.285,3003.895,3006.484,3008.875,3011.455,3014.015,3015.8,3018.125,3020.163,3022.105,3024.434,3026.545,3028.604,3030.685,3033.145,3035.395,3039.605,3043.215,3045.475,3048.725,3052.535,3055.345,3059.354,3061.546,3064.624,3068.324,3071.226,3074.315,3077.704,3080.646,3084.245,3087.586,3093.344,3096.276,3098.345,3100.435,3102.585,3105.995,3108.035,3111.434,3113.799,3116.645,3118.785,3121.865,3124.405,3128.394,3131.196,3136.895,3139.225,3141.725,3146.884,3149.092,3152.004,3154.065,3156.117,3158.17,3162.035,3165.674,3168.494,3170.944,3173.675,3176.325,3179.275,3182.594,3185.005,3187.425,3189.987,3192.266,3194.345,3197.734,3200.024,3202.764,3204.885,3206.894,3209.284,3211.195,3213.365,3215.254,3217.605,3219.94,3221.994,3224.044,3226.047,3228.555,3231.031,3237.895,3242.186,3244.367,3247.015,3249.205,3251.424,3255.019,3259.834,3264.019,3269.019,3272.654,3274.782,3277.194,3280.114,3287.354,3289.944,3295.134,3299.295,3301.765,3304.564,3307.096,3309.876,3313.424,3316.854,3321.944,3324.287,3330.159,3332.736,3335.176,3337.534,3340.894,3346.262,3348.534,3350.587,3352.679,3355.013,3357.004,3360.524,3362.644,3365.574,3369.785,3374.484,3376.534,3378.742,3381.795,3384.614,3386.804,3388.829,3390.804,3392.764,3395.261,3397.364,3399.414,3402.104,3405.894,3408.004,3410.354,3412.614,3414.724,3416.829,3419.474,3423.444,3425.673,3427.865,3431.124,3433.754,3436.322,3438.4,3440.424,3442.767,3444.958,3447.074,3449.183,3451.884,3454.054,3455.984,3459.416,3461.674,3464.285,3466.323,3468.444,3470.624,3473.624,3477.233,3480.518,3482.734,3485.454,3489.944,3492.164,3494.983,3498.462,3501.073,3503.774,3506.804,3509.954,3512.105,3514.297,3516.304,3518.236,3520.174,3522.176,3524.185,3526.851,3528.994,3532.434,3534.465,3536.524,3538.9,3542.014,3545.704,3548.593,3551.671,3556.944,3559.044,3562.824,3565.319,3568.213,3570.275,3572.634,3574.804,3578.025,3581.923,3584.914,3588.403,3592.974,3596.236,3598.374,3600.573,3603.14,3605.793,3607.926,3610.404,3614.107,3620.113,3622.183,3625.104,3627.734,3630.601,3635.413,3637.6,3640.217,3644.526,3646.903,3649.093,3651.823,3655.263,3657.404,3659.604,3663.043,3666.686,3671.413,3674.043,3678.814,3683.045,3685.754,3688.303,3690.453,3693.304,3696.744,3699.823,3703.654,3706.383,3709.823,3713.633,3716.493,3719.298,3721.614,3724.115,3726.35,3728.504,3730.918,3733.384,3735.428,3737.954,3739.813,3742.043,3744.084,3746.014,3748.673,3750.893,3756.054,3758.232,3761.473,3767.693,3770.033,3773.064,3775.593,3778.403,3780.813,3783.163,3785.474,3788.693,3791.194,3793.643,3796.933,3799.143,3801.033,3803.053,3805.036,3807.355,3810.847,3814.103,3816.383,3819.973,3822.963,3826.156,3829.123,3831.323,3833.303,3835.363,3837.385,3840.433,3842.624,3844.963,3847.313,3851.69,3853.906,3856.043,3858.115,3860.513,3862.662,3864.794,3867.193,3869.282,3871.293,3873.703,3877.073,3879.262,3881.304,3883.492,3885.793,3887.683,3889.783,3892.129,3894.363,3896.882,3899.512,3901.394,3903.463,3905.905,3908.325,3912.1,3915.243,3920.232,3922.443,3924.753,3926.883,3928.908,3931.114,3933.137,3935.451,3937.633,3940.073,3942.582,3945.803,3948.723,3951.812,3954.722,3957.012,3962.123,3967.082,3969.532,3971.643,3973.752,3975.872,3977.823,3979.741,3981.843,3983.743,3985.742,3987.792,3990.143,3992.363,3996.513,3998.923,4001.254,4004.142,4007.802,4010.022,4013.863,4016.164,4018.466,4022.034,4024.992,4027.455,4029.983,4032.173,4034.873,4037.072,4039.912,4041.382,4046.65,4048.852,4051.061,4055.412,4058.712,4061.103,4065.413,4069.303,4077.843,4081.982,4085.743,4087.843,4090.472,4092.712,4095.963,4099.523,4102.613,4105.174,4107.834,4110.542,4115.033,4118.39,4122.885,4125.394,4128.511,4131.462,4135.693,4137.957,4140.193,4142.532,4145.001,4148.232,4151.301,4155.131,4157.923,4160.027,4162.256,4164.562,4167.542,4172.122,4174.282,4177.522,4179.892,4183.582,4188.631,4191.131,4195.782,4198.012,4200.732,4202.912,4205.185,4207.242,4209.356,4211.421,4214.052,4216.182,4218.542,4221.113,4224.424,4226.682,4229.971,4235.592,4238.602,4240.743,4242.822,4245.063,4249.153,4253.016,4255.407,4257.732,4259.852,4262.562,4264.812,4268.282,4271.342,4274.362,4279.512,4284.012,4286.252,4288.592,4291.163,4293.794,4295.934,4298.182,4300.961,4306.692,4309.132,4312.732,4317.283,4320.041,4322.351,4324.905,4328.532,4333.891,4336.082,4338.603,4341.891,4346.95,4349.392,4351.452,4353.291,4355.544,4357.645,4360.022,4363.552,4368.382,4370.821,4373.711,4376.041,4378.112,4380.162,4382.394,4384.972,4387.871,4392.442,4395.131,4400.423,4401.482],axisLabel:{show:!1},axisLine:{show:!1},axisTick:{show:!1}},yAxis:{type:"value",axisLabel:{inside:!1}},series:[{data:[0,5,17,28,37,46,50,55,59,62,68,72,82,87,93,97,105,109,115,122,127,136,142,148,155,164,169,177,184,192,194,198,208,215,223,229,240,249,258,264,274,281,288,293,301,307,315,323,329,342,352,358,363,374,384,395,402,406,412,416,423,429,435,444,450,457,465,473,476,479,488,492,499,505,513,515,525,533,541,547,555,563,569,578,583,588,594,602,605,613,623,629,635,641,648,656,666,674,681,690,699,708,717,725,733,736,742,752,756,764,768,775,780,785,792,800,809,815,824,829,836,846,853,864,872,875,882,889,892,903,909,916,921,932,940,945,958,961,970,977,984,992,997,1004,1014,1021,1028,1037,1040,1047,1055,1063,1067,1074,1084,1093,1102,1107,1113,1118,1129,1134,1141,1146,1157,1161,1166,1174,1179,1185,1192,1197,1206,1212,1220,1228,1233,1241,1246,1259,1271,1279,1285,1293,1294,1304,1310,1315,1323,1334,1342,1350,1355,1365,1372,1375,1383,1392,1398,1408,1413,1420,1427,1437,1447,1452,1462,1468,1475,1480,1492,1496,1501,1507,1518,1530,1535,1539,1548,1554,1567,1570,1579,1585,1597,1606,1610,1618,1623,1626,1633,1643,1649,1656,1663,1673,1679,1684,1693,1699,1704,1715,1718,1729,1735,1744,1750,1758,1764,1768,1777,1785,1792,1803,1815,1820,1827,1835,1842,1853,1859,1869,1874,1885,1892,1896,1904,1913,1919,1930,1935,1948,1956,1960,1967,1976,1983,1992,1995,2006,2011,2016,2024,2035,2041,2047,2056,2061,2068,2077,2082,2090,2093,2104,2113,2116,2127,2134,2140,2149,2155,2163,2170,2176,2185,2191,2199,2209,2216,2221,2227,2232,2237,2245,2255,2261,2267,2274,2282,2287,2295,2304,2311,2322,2332,2337,2344,2348,2354,2362,2369,2377,2381,2391,2404,2411,2419,2426,2433,2444,2456,2461,2468,2476,2479,2484,2487,2496,2507,2516,2523,2528,2539,2545,2550,2557,2567,2572,2581,2588,2594,2601,2606,2613,2618,2624,2630,2639,2646,2653,2656,2661,2667,2672,2682,2685,2695,2705,2710,2717,2726,2728,2736,2741,2747,2755,2760,2769,2775,2782,2790,2792,2802,2807,2817,2824,2827,2833,2839,2843,2852,2862,2866,2875,2887,2892,2901,2907,2912,2921,2931,2936,2944,2949,2957,2961,2969,2974,2984,2991,2997,3004,3012,3020,3026,3037,3048,3055,3061,3067,3074,3079,3084,3093,3107,3110,3118,3124,3135,3141,3147,3157,3161,3169,3178,3186,3195,3202,3208,3220,3231,3236,3244,3257,3266,3277,3284,3294,3299,3304,3315,3323,3328,3338,3348,3353,3364,3372,3378,3384,3390,3399,3409,3417,3425,3436,3444,3451,3461,3469,3476,3480,3490,3496,3501,3510,3518,3521,3529,3537,3545,3553,3564,3570,3578,3585,3592,3596,3606,3614,3622,3631,3639,3647,3654,3665,3670,3681,3688,3694,3705,3711,3721,3728,3733,3743,3749,3751,3763,3767,3774,3781,3785,3794,3801,3805,3809,3813,3821,3830,3839,3849,3854,3864,3867,3875,3880,3889,3895,3903,3909,3922,3926,3933,3945,3956,3964,3973,3978,3987,3997,4004,4009,4018,4024,4034,4045,4053,4061,4066,4074,4080,4087,4092,4103,4112,4115,4122,4128,4137,4141,4153,4160,4164,4172,4181,4188,4195,4202,4211,4222,4233,4238,4247,4253,4256,4259,4270,4282,4288,4296,4304,4317,4327,4331,4338,4344,4350,4357,4363,4368,4371,4383,4392,4400,4406,4416,4422,4432,4440,4451,4458,4467,4471,4478,4485,4493,4496,4508,4512,4519,4529,4534,4540,4549,4556,4559,4566,4573,4578,4589,4596,4604,4611,4620,4630,4642,4651,4660,4662,4669,4675,4680,4686,4692,4696,4703,4708,4717,4720,4729,4741,4749,4759,4764,4771,4779,4788,4790,4795,4804,4811,4814,4822,4832,4836,4845,4853,4862,4870,4877,4882,4889,4891,4901,4908,4918,4927,4933,4940,4949,4953,4960,4968,4973,4982,4992,5e3,5006,5014,5020,5030,5034,5042,5053,5064,5070,5080,5088,5094,5099,5106,5112,5122,5125,5132,5135,5144,5149,5155,5161,5170,5182,5188,5193,5207,5213,5223,5230,5240,5252,5255,5264,5270,5276,5284,5292,5297,5306,5311,5317,5322,5324,5333,5341,5351,5359,5368,5374,5380,5387,5391,5395,5407,5409,5415,5423,5433,5441,5448,5460,5465,5470,5473,5477,5482,5492,5497,5503,5513,5523,5530,5541,5549,5553,5562,5566,5574,5579,5587,5593,5602,5611,5621,5629,5636,5644,5650,5658,5667,5679,5686,5690,5699,5708,5714,5723,5732,5741,5749,5755,5762,5774,5784,5791,5798,5807,5813,5822,5827,5838,5845,5848,5855,5863,5869,5877,5880,5884,5892,5900,5904,5909,5920,5925,5933,5943,5947,5956,5968,5974,5977,5984,5989,5994,6002,6011,6018,6025,6028,6039,6048,6053,6059,6065,6075,6082,6089,6094,6099,6104,6111,6117,6127,6132,6140,6148,6156,6163,6171,6174,6179,6186,6194,6203,6213,6220,6227,6232,6239,6248,6254,6262,6270,6275,6283,6291,6295,6304,6311,6318,6324,6332,6344,6352,6362,6370,6377,6384,6393,6400,6408,6418,6424,6431,6439,6443,6451,6455,6463,6470,6472,6475,6485,6492,6501,6511,6520,6528,6543,6549,6557,6566,6573,6581,6593,6599,6604,6611,6614,6622,6632,6644,6648,6657,6662,6673,6678,6686,6695,6699,6710,6717,6731,6738,6747,6752,6761,6771,6780,6788,6792,6801,6805,6812,6820,6830,6835,6843,6848,6859,6864,6875,6884,6894,6901,6905,6913,6923,6931,6942,6947,6952,6957,6966,6973,6980,6989,6995,7004,7014,7019,7026,7033,7039,7047,7051,7059,7064,7073,7077,7085,7094,7100,7108,7117,7124,7135,7140,7149,7161,7169,7174,7180,7185,7195,7203,7210,7215,7222,7232,7239,7247,7255,7265,7272,7281,7290,7294,7304,7309,7315,7322,7327,7337,7347,7354,7362,7369,7377,7384,7391,7403,7412,7416,7420,7424,7431,7437,7446,7451,7457,7465,7472,7479,7487,7496,7502,7512,7521,7534,7539,7548,7555,7558,7564,7572,7584,7588,7593,7601,7613,7626,7629,7638,7646,7655,7660,7664,7670,7676,7685,7692,7696,7707,7714,7723,7729,7740,7749,7756,7762,7771,7779,7786,7797,7806,7813,7819,7825,7830,7836,7844,7853,7860,7867,7869,7876,7881,7889,7896,7906,7915,7919,7925,7929,7934,7938,7945,7952,7955,7963,7968,7975,7979,7987,7997,8003,8009,8015,8019,8023,8033,8037,8045,8057,8064,8069,8076,8083,8094,8098,8106,8116,8121,8129,8131,8135,8145,8150,8152,8159,8167,8175,8181,8189,8199,8207,8211,8220,8226,8235,8240,8248,8259,8268,8276,8284,8291,8299,8302,8312,8318,8325,8330,8336,8346,8354,8362,8372,8377,8384,8396,8402,8411,8418,8429,8432,8437,8450,8456,8466,8471,8479,8485,8494,8500,8511,8517,8529,8534,8542,8547,8561,8571,8581,8587,8600,8604,8613,8619,8629,8632,8642,8651,8661,8669,8675,8686,8698,8709,8711,8716,8723,8727,8733,8740,8751,8762,8766,8777,8782,8785,8788,8795,8801,8807,8812,8822,8828,8833,8839,8846,8850,8857,8867,8877,8885,8891,8901,8907,8914,8923,8934,8940,8952,8959,8965,8971,8980,8985,8993,9005,9013,9017,9026,9037,9043,9055,9061,9071,9076,9083,9095,9100,9110,9113,9123,9130,9133,9142,9146,9153,9159,9163,9169,9177,9186,9194,9206,9213,9219,9223,9231,9239,9250,9259,9267,9272,9283,9289,9297,9308,9312,9316,9321,9330,9338,9344,9351,9358,9362,9367,9372,9378,9385,9390,9398,9402,9410,9417,9426,9430,9437,9443,9452,9457,9465,9470,9476,9486,9496,9498,9504,9512,9517,9526,9533,9541,9548,9556,9566,9571,9580,9587,9595,9602,9607,9614,9622,9629,9639,9651,9659,9664,9674,9682,9688,9694,9696,9699,9705,9711,9716,9722,9730,9739,9749,9758,9766,9772,9782,9791,9794,9805,9809,9817,9826,9832,9840,9850,9857,9866,9872,9877,9881,9888,9893,9900,9908,9918,9927,9937,9949,9960,9970,9976,9981,9992,9995,10002,10013,10024,10032,10037,10050,10060,10068,10079,10087,10093,10098,10104,10111,10116,10126,10134,10141,10151,10160,10165,10171,10176,10185,10197,10206,10214,10224,10233,10239,10248,10256,10267,10272,10278,10283,10291,10298,10306,10313,10324,10325,10335,10341,10351,10355,10366,10378,10388,10394,10397,10403,10412,10420,10425,10434,10442,10454,10463,10472,10477,10483,10493,10505,10516,10528,10530,10542,10549,10557,10569,10580,10585,10593,10602,10610,10616,10622,10634,10640,10648,10652,10662,10673,10683,10688,10692,10700,10704,10714,10725,10730,10741,10748,10758,10763,10770,10774,10781,10794,10803,10813,10826,10827],type:"line",lineStyle:{color:"#fff"}}]};lC&&pAe.setOption(lC);var vAe=document.querySelectorAll(".track")[1].querySelector(".track-viz"),gAe=E$(vAe),uC;uC={grid:{top:0,bottom:0,right:0,left:0},xAxis:{type:"category",data:[5.364,8.178,11.005,14.745,17.539,33.363,36.103,38.593,40.863,43.773,47.543,55.084,57.943,60.704,63.353,69.975,72.654,77.243,83.725,87.466,91.062,94.375,98.152,103.323,107.013,111.933,120.634,132.343,136.39,140.943,141.707,148.073,155.913,160.735,185.933,188.09699999999998,193.142,195.445,197.345,204.753,210.06,216.384,218.522,220.884,229.833,239.574,243.062,245.743,255.603,258.253,267.045,273.712,279.072,282.351,285.302,290.652,301.752,307.284,311.374,313.443,315.743,317.602,320.102,323.772,326.304,331.599,335.565,339.053,342.672,345.873,349.352,357.703,370.133,374.506,381.893,387.562,393.692,396.112,403.052,405.522,409.882,411.822,414.012,415.882,419.852,424.682,426.753,438.702,440.867,452.822,455.29650000000004,460.454,462.453,466.183,468.802,473.362,475.352,482.704,485.543,491.022,494.212,496.928,502.392,510.362,515.059,517.28,519.491,522.575,533.862,539.442,540.3924999999999,544.281,548.542,553.063,561.172,566.771,569.322,570.1605,571.64,573.702,575.751,577.893,583.282,586.113,588.364,591.812,598.322,600.731,602.793,607.344,612.002,614.647,618.012,620.893,623.042,629.911,637.173,646.393,648.601,649.8620000000001,655.662,663.051,673.975,676.535,682.026,689.535,693.612,697.871,704.622,707.522,710.452,719.438,726.871,729.322,732.839,737.061,739.311,741.401,749.414,753.211,754.912,756.751,762.944,769.071,771.131,773.431,780.201,787.331,792.209,801.792,806.722,808.849,811.591,814.153,816.074,819.883,825.971,830.277,832.432,838.08,843.811,851.092,853.629,856.111,860.551,868.311,870.545,876.811,880.444,883.991,886.811,889.102,898.631,900.812,906.602,908.943,910.941,911.6205,912.942,914.791,921.992,924.672,931.601,935.871,938.811,939.8305,941.492,943.98,946.681,949.001,955.111,958.911,962.918,974.911,986.691,988.767,997.122,1007.312,1012.211,1017.78,1031.3,1039.791,1050.94,1063.073,1066.662,1074.615,1076.753,1078.931,1088.25,1091.011,1093.652,1100.202,1108.86,1111.853,1114.731,1117.3,1124.041,1129.923,1139.771,1147.442,1150.361,1154.05,1158.91,1166.082,1169.52,1172.77,1176.983,1183.581,1186.041,1189.33,1192.642,1195.991,1198.949,1201.11,1206.657,1211.56,1215.91,1216.6345000000001,1218.001,1222.59,1223.9205,1225.894,1240.893,1242.6015,1244.951,1246.91,1251.529,1257.379,1260.78,1267.51,1269.911,1273.79,1275.98,1279.232,1285.5,1290.106,1294.98,1299.17,1304.43,1317.55,1320.392,1327.991,1330.12,1335.31,1338.54,1348.36,1351.25,1353.92,1360.12,1363.141,1367.73,1371.89,1374.842,1377.041,1379.113,1381.47,1384.32,1389.264,1391.76,1394.22,1398.572,1400.788,1404.6,1407.41,1409.97,1412.467,1415.51,1417.799,1426.48,1434.729,1437.079,1439.239,1443.52,1448.453,1451.399,1454.7,1458.66,1461.91,1469.999,1482.072,1487.31,1490.97,1494.84,1503.619,1514.16,1518.17,1521.899,1524.18,1531.89,1534.732,1539.099,1541.231,1546.471,1548.69,1559.119,1563.68,1567.809,1571.919,1574.389,1576.479,1580.29,1582.388,1584.66,1585.1703333333335,1585.6806666666666,1589.11,1601.639,1603.783,1618.141,1626.619,1632.146,1633.337,1638.141,1641.661,1644.161,1655.25,1658.8,1661.33,1669.629,1673.38,1678.529,1685.16,1689.48,1692.09,1697.071,1700.857,1705.689,1708.06,1713.111,1715.51,1717.899,1721.049,1723.75,1727.011,1733.999,1741.584,1744.423,1751.07,1760.05,1763.49,1772.049,1774.189,1780.336,1781.5465,1783.4,1785.429,1790.411,1796.239,1801.579,1813.189,1819.079,1821.97,1824.269,1826.661,1829.208,1831.77,1836.068,1838.768,1841.339,1851.83,1854.749,1857.889,1864.374,1866.6165,1869.503,1871.639,1879.319,1883.49,1887.758,1893.385,1897.335,1909.749,1920.9,1928.28,1939.918,1965.809,1971.149,1973.869,1981.403,1989.951,1996.969,1999.47,2002.628,2005.975,2009.692,2012.708,2015,2020.539,2026.319,2034.938,2037.028,2043.809,2049.838,2052.349,2059.609,2062.618,2066.848,2069.138,2070.9475,2073.397,2079.507,2084.485,2087.418,2092.069,2094.279,2096.458,2099.261,2101.898,2104.0575,2109.348,2114.99,2117.888,2120.928,2128.219,2135.091,2139.359,2143.728,2145.966,2152.818,2158.078,2161.019,2163.808,2166.48,2172.032,2176.748,2180.118,2182.702,2202.478,2215.278,2217.46,2222.668,2230.243,2235.288,2238.618,2248.888,2251.779,2259.329,2264.45,2268.998,2271.188,2275.627,2278.158,2280.398,2285.298,2288.089,2301.418,2323.787,2329.438,2332.39,2341.607,2343.787,2344.5845,2346.023,2348.798,2354.598,2360.962,2362.888,2364.817,2369.097,2373.828,2375.948,2386.318,2391.829,2392.5625,2393.937,2396.618,2399.607,2400.6965,2402.427,2410.458,2418.757,2423.307,2431.467,2436.907,2440.406,2448.307,2451.429,2456.118,2459.89,2465.017,2468.497,2471.757,2474.889,2482.767,2489.231,2494.247,2495.941,2506.507,2520.857,2524.077,2525.3815000000004,2530.157,2535.407,2537.497,2539.588,2542.017,2544.828,2546.082,2552.747,2554.957,2562.856,2565.529,2572.257,2574.937,2580.697,2582.792,2586.778,2588.797,2591.356,2598.1,2600.579,2606.107,2608.247,2610.397,2615.296,2618.229,2620.142,2627.747,2629.861,2632.008,2634.708,2636.964,2642.065,2644.157,2646.357,2647.09,2648.464,2650.587,2652.867,2656.996,2663.167,2671.088,2673.187,2677.075,2679.306,2683.318,2684.1175000000003,2693.356,2698.663,2703.908,2719.508,2726.036,2730.706,2733.926,2736.848,2740.703,2745.466,2753.857,2755.0665,2759.767,2765.006,2778.768,2788.917,2793.327,2795.327,2800.623,2809.067,2812.994,2817.356,2820.808,2824.987,2828.937,2832.016,2835.302,2852.569,2855.937,2859.281,2861.387,2863.512,2870.167,2872.797,2875.456,2877.717,2882.997,2893.988,2897.266,2899.686,2914.857,2919.276,2928.156,2930.586,2942.585,2966.436,2969.116,2982.727,2984.767,2989.206,2993.627,2997.786,3007.126,3009.516,3020.807,3022.747,3025.076,3027.186,3031.326,3036.037,3043.855,3046.115,3047.42,3053.176,3059.996,3062.188,3065.267,3071.866,3088.227,3096.918,3098.987,3103.229,3112.075,3125.048,3129.036,3131.836,3139.864,3140.7945,3147.526,3152.646,3154.706,3158.811,3166.316,3176.966,3183.235,3188.065,3189.026,3198.377,3203.405,3207.536,3209.924,3214.006,3214.63,3215.896,3220.581,3222.635,3224.685,3226.687,3229.196,3231.668,3238.536,3247.656,3252.065,3260.475,3269.654,3273.295,3277.836,3280.756,3287.995,3290.585,3305.205,3317.496,3324.93,3335.818,3341.535,3346.903,3353.32,3355.656,3357.645,3361.165,3363.285,3370.428,3372.456,3377.175,3382.437,3385.257,3389.47,3391.446,3395.902,3400.056,3406.535,3408.645,3413.255,3415.365,3420.116,3424.085,3424.879,3426.315,3434.395,3435.3585000000003,3439.041,3441.065,3443.409,3447.715,3452.525,3454.696,3466.963,3469.085,3477.874,3481.158,3490.585,3495.624,3501.714,3510.595,3512.747,3514.937,3516.945,3518.876,3520.814,3522.817,3527.493,3529.635,3533.074,3537.164,3549.234,3559.685,3563.466,3568.854,3570.916,3573.275,3578.667,3582.565,3589.045,3596.876,3599.015,3603.781,3611.045,3620.755,3622.825,3623.9645,3625.744,3628.378,3636.054,3636.827,3640.86,3645.166,3647.545,3648.319,3649.735,3652.47,3655.904,3660.246,3663.685,3672.054,3674.686,3683.685,3686.396,3691.096,3693.945,3697.388,3700.465,3704.295,3707.026,3719.939,3724.759,3729.145,3731.56,3734.024,3736.073,3742.685,3744.726,3746.655,3751.534,3756.695,3758.873,3768.334,3776.233,3779.044,3783.804,3786.497,3791.836,3797.574,3805.676,3807.995,3811.488,3814.744,3817.024,3823.605,3826.796,3829.764,3831.964,3843.266,3844.1145,3845.604,3847.955,3849.8225,3852.332,3854.547,3861.154,3874.343,3877.714,3879.904,3881.949,3882.7205000000004,3890.424,3892.774,3900.154,3902.035,3904.104,3906.546,3908.966,3920.874,3923.084,3925.394,3929.545,3938.273,3940.713,3946.444,3949.364,3952.453,3962.764,3970.173,3972.284,3974.394,3976.514,3978.464,3982.484,3988.433,3989.288,3990.784,3993.004,3999.566,4001.897,4010.663,4014.504,4016.806,4019.104,4022.675,4025.634,4030.623,4035.516,4037.713,4042.023,4049.498,4056.053,4059.353,4061.744,4066.054,4069.944,4078.484,4082.624,4086.384,4088.486,4093.353,4096.604,4100.163,4103.254,4104.214,4105.816,4111.183,4115.674,4119.031,4129.153,4132.103,4143.171,4145.642,4155.774,4165.203,4174.923,4178.162,4180.533,4196.423,4203.553,4207.883,4212.063,4213.0575,4214.693,4216.823,4219.183,4220.148,4225.065,4230.613,4239.243,4241.383,4243.463,4245.704,4249.793,4253.653,4256.048,4256.889999999999,4260.494,4265.453,4271.984,4275.003,4280.157,4284.653,4286.893,4291.804,4296.575,4298.823,4301.603,4309.773,4313.373,4320.683,4322.991,4329.173,4336.722,4342.533,4350.032,4353.933,4356.185,4358.287,4360.664,4369.023,4371.462,4374.352,4376.685,4378.753,4388.512,4393.083,4401.064]},yAxis:{type:"value"},series:[{data:["0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","1","1","1","0","0","0","0","-1","0","0","-1","0","-1","0","0","0","0","0","0","0","-1","0","0","-1","0","0","0","-1","0","0","0","0","0","0","0","0","0","1","0","-1","-1","0","0","0","-1","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","-1","-1","1","0","0","0","0","0","0","0","0","0","0","0","1","0","-1","0","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","-1","0","0","0","0","0","0","0","-1","0","0","0","-1","0","0","0","0","-1","0","0","1","0","0","0","0","0","0","0","0","-1","0","0","0","-1","0","-1","0","0","-1","0","0","0","0","-1","0","0","-1","-1","-1","0","0","0","-1","0","0","0","0","-1","0","0","0","0","1","0","0","-1","0","0","0","1","1","0","0","0","0","1","0","-1","0","0","0","-1","-1","-1","1","0","0","0","0","0","0","0","0","1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","1","0","-1","0","0","-1","0","0","-1","0","0","0","0","0","0","-1","-1","0","0","0","0","0","0","-1","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","-1","0","0","0","0","0","1","0","0","0","-1","-1","0","0","0","0","0","0","0","-1","0","-1","0","0","-1","0","0","-1","0","0","0","-1","0","-1","1","0","0","0","0","0","0","-1","0","0","-1","0","1","-1","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","-1","0","0","1","0","0","0","0","0","0","0","0","0","0","0","0","1","-1","-1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","1","-1","0","0","0","-1","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","-1","0","-1","-1","0","0","-1","0","0","0","-1","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","1","0","0","0","0","0","0","-1","-1","-1","0","-1","0","0","0","0","-1","0","0","-1","1","0","0","0","0","0","0","0","-1","0","0","-1","0","-1","0","0","-1","0","0","0","0","-1","0","0","0","0","-1","-1","0","0","0","0","0","0","-1","1","0","0","0","-1","0","0","1","0","0","0","-1","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","1","-1","0","0","0","0","0","0","0","0","0","0","0","0","0","-1","1","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","-1","-1","0","0","0","0","0","1","1","0","0","0","0","0","0","0","-1","-1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","-1","1","0","0","0","-1","0","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","0","1","0","0","0","0","0","0","1","0","0","0","0","0","-1","-1","0","0","0","0","-1","0","0","0","1","0","1","0","-1","-1","0","0","1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","1","0","1","0","1","0","0","-1","0","-1","0","-1","0","0","0","0","0","0","-1","0","0","-1","0","0","0","-1","-1","0","1","0","-1","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","0","0","0","0","1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","-1","0","-1","0","-1","0","0","0","0","0","-1","-1","-1","-1","1","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","0","1","0","-1","0","0","0","0","0","0","-1","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","1","0","0","0","0","0","0","0","0","0","0","0","0","0","1","-1","0","0","0","0","1","0","1","1","0","0","0","0","0","0","0","-1","-1","1","-1","0","1","0","-1","0","0","0","0","0","0","-1","0","0","0","0","0","0","0","0","1","-1","0","1","0","0","-1","1","0","-1","0"],type:"line"}]};uC&&gAe.setOption(uC);const hX=document.getElementById("video");BA.registerPlugin(Qu);const Wn=new sr("my-player",{controls:!1,muted:!0,srgOptions:{liveui:!1}});Wn.src({src:hX.getAttribute("data-urn"),type:"srgssr/urn"});const mAe=document.getElementById("timeline-bar-ctrl");hX.addEventListener("click",r=>{Wn.paused()?Wn.play():Wn.pause(),bAe()});const yAe=document.getElementById("transcript"),_Ae=yAe.querySelectorAll("[data-start]");_Ae.forEach(r=>{r.addEventListener("click",e=>{Wn.currentTime(e.target.getAttribute("data-start")),Wn.play()})});const cC={timelineIndicatorIsDragged:!1};function bAe(){let e=Wn.duration()/10,t="00:00:00";for(let i=1;i<=10;i++)t+=`${secondsToTimecode(i*e)}`;document.querySelector("#timeline-bar").insertAdjacentHTML("beforeend",t),console.log(t)}function SAe(r){return Wn.duration()/document.getElementById("timeline-bar").offsetWidth*r}Wn.on("timeupdate",r=>{if(!cC.timelineIndicatorIsDragged){let e=document.getElementById("timeline-bar").offsetWidth/Wn.duration()*Wn.currentTime();mAe.style.transform=`translate3d(${e}px, 0px, 0px)`}});document.addEventListener("DOMContentLoaded",r=>{BA.registerPlugin(Qu),Qu.create("#timeline-bar-ctrl",{type:"x",bounds:document.getElementById("timeline-bar"),onDragStart:function(){cC.timelineIndicatorIsDragged=!0},onDragEnd:function(){Wn.currentTime(SAe(this.x)),cC.timelineIndicatorIsDragged=!1}})}); diff --git a/VANA-php/public/build/assets/app-Brxm-Dry.css b/VANA-php/public/build/assets/app-Brxm-Dry.css new file mode 100644 index 0000000..b0b0a92 --- /dev/null +++ b/VANA-php/public/build/assets/app-Brxm-Dry.css @@ -0,0 +1 @@ +*,*:before,*:after{box-sizing:border-box}:root{--c1: #F2F2F2;--c2: #D9D9D9;--c3: #737373;--c4: #404040;--c5: #0D0D0D}html{-moz-text-size-adjust:none;-webkit-text-size-adjust:none;-webkit-font-smoothing:antialiased;text-size-adjust:none}*{margin:0}ul[role=list],ol[role=list]{list-style:none}body{min-height:100vh;line-height:1.5;padding:1.5em;font-family:sans-serif;background:var(--c4);color:var(--c1)}img,picture,video,canvas,svg{display:block;max-width:100%}input,button,textarea,select{font:inherit}h1,h2,h3,h4,button,input,label{line-height:1.1}fieldset{display:block;border:none;padding:0;margin:0}h1,h2,h3,h4{text-wrap:balance}a:not([class]){text-decoration-skip-ink:auto;color:currentColor}input,button,textarea,select{font-family:inherit;font-size:inherit}textarea:not([rows]){min-height:10em}:target{scroll-margin-block:5ex}dl{display:grid;grid-template-areas:"title desc";gap:.5em 1em}dt{font-weight:600}.visually-hidden{position:absolute;left:-10000px;top:auto;width:1px;height:1px;overflow:hidden}.tablist{height:100%;display:grid;grid-template:"tablist" "panel";grid-template-rows:2.5em 1fr}.controls{background:var(--c5)}.control{display:inline-block}.control label{display:inline-grid;justify-items:center;align-items:center;padding:.5em 1em;height:2.5em;color:var(--c1)}input[type=radio]:checked+label{background:var(--c3)}a:focus,input:focus,input[type=radio]:focus+label{outline:2px dotted;outline-offset:2px}input[type=radio]+label:hover{cursor:pointer;text-decoration:underline}.panel{background:var(--c3);padding:1em;height:calc(50vh - 4em);overflow-y:scroll}#tablist_panel_transcript_panel font{display:block;color:#fff!important}#transcript{padding:0;list-style:none}#transcript a{cursor:pointer}#transcript li{display:flex}#transcript li>div{margin-right:1em}.vjs-title-bar{display:none!important}main{width:100%;height:calc(100vh - 3em);display:grid;grid-template-areas:"video tabs" "timeline timeline";grid-template-columns:repeat(2,1fr);grid-template-rows:1fr 50%;gap:1em}#video{grid-area:video}#tabs{grid-area:tabs}#timeline{grid-area:timeline;position:relative;background:var(--c3)}#timeline-bar{height:2em;margin-left:20em;background:#aaa;display:flex;justify-content:space-between}#timeline-bar>span{display:inline-flex;align-items:center}#timeline-bar-ctrl{display:inline-block;background:#000;width:.1875em;height:100%;position:absolute}#timeline-bar-ctrl:before{content:"";width:2em;height:2em;border-radius:50%;transform:translate3d(-50%,0,0);background:#000;position:absolute}#tracks{height:calc(100% - 2em);overflow-y:scroll}.track{width:100%;min-height:15em;display:grid;grid-template:100% / 20em 1fr}.track+.track{border-top:1px solid var(--c1)}.track-ctrl{padding:1em;background:var(--c3)}.track-viz{background:var(--c3)} diff --git a/VANA-php/public/build/assets/pillarbox-CCcjZzR7.css b/VANA-php/public/build/assets/pillarbox-CCcjZzR7.css new file mode 100644 index 0000000..604d10b --- /dev/null +++ b/VANA-php/public/build/assets/pillarbox-CCcjZzR7.css @@ -0,0 +1 @@ +.vjs-svg-icon{display:inline-block;background-repeat:no-repeat;background-position:center;fill:currentColor;height:1.8em;width:1.8em}.vjs-svg-icon:before{content:none!important}.vjs-svg-icon:hover,.vjs-control:focus .vjs-svg-icon{filter:drop-shadow(0 0 .25em #fff)}.vjs-modal-dialog .vjs-modal-dialog-content,.video-js .vjs-modal-dialog,.pillarbox-js .vjs-modal-dialog,.vjs-button>.vjs-icon-placeholder:before,.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{position:absolute;top:0;left:0;width:100%;height:100%}.vjs-button>.vjs-icon-placeholder:before,.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{text-align:center}@font-face{font-family:VideoJS;src:url(data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAABUgAAsAAAAAItAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADsAAABUIIslek9TLzIAAAFEAAAAPgAAAFZRiV33Y21hcAAAAYQAAAEJAAAD5p42+VxnbHlmAAACkAAADwwAABdk9R/WHmhlYWQAABGcAAAAKwAAADYn8kSnaGhlYQAAEcgAAAAdAAAAJA+RCL1obXR4AAAR6AAAABMAAAC8Q44AAGxvY2EAABH8AAAAYAAAAGB7SIHGbWF4cAAAElwAAAAfAAAAIAFAAI9uYW1lAAASfAAAASUAAAIK1cf1oHBvc3QAABOkAAABfAAAAnXdFqh1eJxjYGRgYOBiMGCwY2BycfMJYeDLSSzJY5BiYGGAAJA8MpsxJzM9kYEDxgPKsYBpDiBmg4gCACY7BUgAeJxjYGR7xDiBgZWBgaWQ5RkDA8MvCM0cwxDOeI6BgYmBlZkBKwhIc01hcPjI+FGPHcRdyA4RZgQRADbZCycAAHic7dPXbcMwAEXRK1vuvffem749XAbKV3bjBA6fXsaIgMMLEWoQJaAEFKNnlELyQ4K27zib5PNF6vl8yld+TKr5kH0+cUw0xv00Hwvx2DResUyFKrV4XoMmLdp06NKjz4AhI8ZMmDJjzoIlK9Zs2LJjz4EjJ85cuHLjziPe/0UWL17mf2tqKLz/9jK9f8tXpGCoRdPKhtS0RqFkWvVQNtSKoVYNtWaoddPXEBqG2jQ9XWgZattQO4baNdSeofYNdWCoQ0MdGerYUCeGOjXUmaHODXVhqEtDXRnq2lA3hro11J2h7g31YKhHQz0Z6tlQL4Z6NdSbod4N9WGoT9MfHF6GmhnZLxyDcRMAAAB4nJ1YC1gUV5auc6urCmxEGrq6VRD6ATQP5dHPKK8GRIyoKApoEBUDAiGzGmdUfKNRM4qLZrUZdGKcGN/GZJKd0SyOWTbfbmZ2NxqzM5IxRtNZd78vwYlJdtREoO7sudVNq6PmmxmKqrqPU+eee173P80Bh39Cu9DOEY4DHZBK3i20D/QRLcfxbE5sEVtwLpZzclw4ibFIkSCJUcZ4MBpMnnzwuKNsGWBL5i3qy6kO2dVpvUpKbkAP9fq62rdeGJ+TM/7C1nbIutfuWrWk5ci4zMxxR1qW/N+9JsmCGXj9VKWhFx/6tr/nz78INDm2C9yPF/fDcxLuyKxLBZ1ZBz2QTi+RSkiH5RrDQJ/GgGQadX9m0YSURs7GpSG905Zsk41uj14yul1OtieZ7QUk5GRG/YiS7PYYPSAZNRed9sq3+bOpz00rKb7pe/ZEZvbALxZAHT3AFoH8GXP3rt67QFn40kt8W13FjLTDb48c+fSi5/7h0P4dL5yz7DPtbmgmYxfQA9RL2+EOfTcvdp+1vmuBpvOll1As1S6ak0IvJzC7sKWJFtJgBd2uWcg+0Zyg7dzQfhcjXRgXGZRf5/a4A58IDU777Nl252AUk4m2ByRRjqTNqIDCEJeAnU3iCFwrkrNwXEzg4yFevBwypzxkcX+AIfk3VEKl3XmWbT8788SzvpvFJaiOezL6QyuSr9VNf97csNu0z3LuhR0wATUxZAfVBwVOy+nQFhxYdWaXlXe4HC4zWGWzzsrLDtmhI9pOWOHv7PTT7XybH1Z0+v2d5Abd3kmG+TsH23CS/KwTxx/JkzEwx6jcQOUc42LLwHJ/J93uZ9ygh3HuZGwqsY9dWDHQ58dxNqyqKRQTYdxwTubiOSs3FiMDkq0WSZQgCT0GBDOg2lxOAd1FlPVGs4AKBAcYHHaP2wPkHaivmLF5zYqnIZrvcHx5gN4k/6tchNW1DtdgNL2KrxEkS/kfnIHoVnp1VjmjpTf5r0lTzLj0mdS28tX+XGorU364eMPmnWVl8J36nlKGw3CZhjEiuMw8h8mKvhGD+4/lElBWjAhLJMg6fTw4zPZ8cOmcGQBm2Qxml1nAm13CpYGq1JKUlJJUzQn1PTAO0mgv6VMMpA/DuRfSWEu4lDIxdbAtdWIKvnn2Vk766CWfz9fpY0sH/UpdP50rfszaVpdVRmvIejEdLMk45s4Bu0EWHjeOySmFyZSiMahvZdNSn29peoI/YexYfKQTLeurTXXwEVLeSfInTWHkkMaeUx7sBvOCSTSj3AlcKjfueyS36tCrXDlgRtF0etFq9jhc1kfKuBT/OwMr0F4UUTTh1AN0g20+H/ScPcsIEsYu9d/zN5PmjprPtNwI1ZZcDK6iC97Mcjp2y2aX36f+QbpGHrgRuHlXJ+Zf6PFRL2uQSp8vxHeF2IoRb8Rd2rhMzsNxSRmEuKK4JFnkojhMcx6jzqHzGMGFcW+MhBj0bhf6cowN+45I4LHvwT6fteu7M42wGRI/pxcg6/MZdEvt1U1XaulHFXuLmqov/MukvRVL35/b3ODM1+4aPjtzeK7zmUkV2h3DN54HaQ9GzJvxHRb6Ks2gB81fwqraT+A7GvZJrRLRofU6G0urNL+zFw3v0FaVDFxsKEZW56F31r6ip6vOL+FCObBPuIMRiXld9RaMdLzRIOGhPey2T9vA/35DmZPK9IWaT9d/WgOGMieYqJ/dzjLIhZU118gbysxrNUGefxD6UO/hyNNllpFTOIbx32kSFQctnweV5PxTMHLjRqiAN+fQE9gL+Xy5WB6MOS4GJJuYbDUHhcKDhHGRbLzOpjsjdM1+iwAZLGeieehACX2hhI7SjK/ZUTNrvVje31TxJiFBGYViWFkCn9PMeX9fS6qVbzfCj4fOCTzDnuWy2c4xA7mdNkA3RS9FH2VeqzdCBlixxbzXjvkHU1I8BOYFb1pZvPIHSSIj4svT8xpzcxtXN+ZKyjdDvbz08niiF3PqV9Tn5NST8vg48MTaY8E5xqSSIsWoWHo+LtAzxdH/GDUyp37CBEYfso04F/NlMTcDJUTpECLY0HFGQHImE8xsEUdgnrQlixIvGhJA1BvxpDHGxEMBYFeNOHcBJlSjwe2JcSfbBEsGOPPBHg/6SBBOCsLLw0SpUxod0Z1bFMfLkbQ3UiZxEyd0Dx8t+SRBu18Q9msFbI4e3p1THEfkSEh7kEJ5orR10qTWDvbgPWn5aWvCYyOAjwgXyjJi34uMjo58L25cmRAeQZWI2PA1QQLsPESAH8WGFwZZ4SPoR73BHPzIPMJj9AreBzKUmrH4todT18ANvi1oc3YGjUT/0j+ExUwq8PI9BLaCQIpvewwYu2evAG/Vo/5avPdY7o+BemLLXw3y+AdkzP9bpIxB1wm5EYq8fesHbPEPtm6HrHvtx4jcGPR8fDDpkZBefIjB46QnlUNRltv4Z/pO/J6dxEjhYAtmoMeq+GozvUVvNYOW3m6GCIhoprcfr97B8AcIQYsfD8ljUvGNjvkrpj0ETA48ZMIxCeqsRIsQALE0gi2GB+glSOfbOjW3GSBM9yPq8/rpJXrJDz0BPxV6xdN4uiCGDQed3WhgFkBUZEFsmeyyBpzXrm7UGTBZG8Lh5aubFufk5eUsbrrFGr7McYdbltxa0nKYqRKbQjvikXYkTGM0f2xuyM3Ly21oXnWfvf6I1BmZwfh7EWWIYsg2nHhsDhOnczhJcmI6eBAmy3jZ3RiJmKQR/JA99FcwsfaVbNDDyi1rL9NPj9hfo61wjM6BjzOLijLpeTgk/pL+ip6tfYWupzeOgPny2tcUu9J/9mhxJlgyi985NFRbvCVewXUNXLJaW0RxZqtRYtnfYdcYomXQWdnJHQA3jiEEkeTQWcWxdDP9IvvVWvo2TK553XEMEq+s69/QDU1Q7p0zxwsm9qS379whr8NI2PJqLUyGyfNeX3eFfnJU2U+uHR9cVV1IqgurqwuV44XVp0h2qN55X5XJwtk59yP0IZuHrqBOBIuIYhkcoT6Kx79Pu2HS/IPZIMOqLWs/pteOOk4NPgEb6QAIdAPsyZk5Mwd+wVaHMexJv719W7xCu2l37UG6lvYdBcvHa08p89741zd63phTRGqL5ggo6SlvdbWXzCqsPq78NnSu7wnKy2HNZbVoRCI7UJEOyRj+sPE002tOOY7Qa5fXboFWkLNeqYUSZRocp9XwSUZxcQZ9Hw6LV2pOoVmvHQEDbGIENEG5i6bLgMSM4n8+FNLTtAds99DaWEvgcf4o5SyYe9x+kF6/tGoTPAdRmS/XQIEy//QxKC2oqioAI3tS5auvxCtzT6y6RK8fhChYcwCJaMJhxc0vqSxQ/qmgsrKAlBZUHlauheTpvd9uj5DnLzJct6qfq5fXbYHVIGcfrIVJihbaVLu1wW7Vbs8zK0A8e9Jvb91S9cVMjPrazD6gpfeZTXzYbCFMcppVRsGMpp55OWgx1/3JeAxW1Y7AORgM/m3rWrsdLkQVmEVSU16cX/e7uvkvpqRiQsG06XJ0t64Tf+l0nG1dt025gyOIZlvq5u9KSU1N2TW/rsWnnMRPyTDkctbhvIcNvYIXWyLzdwYLoYesUbaQG4iK2cWO2gdpeUYLqDD0MUTOPhDIGnZEs58yArR86FznuWEsU4YDi2x26dA4klkn8Qa6vhk2QUfX4Jxm/ngX9r7ogn1dmlmwqZmuhxtdg9XN/DEcUgqb+9hMyNansfaQET2mcROCmGEMVqxm5u+h6kN2MOwgqykV2wH9yQG9DvVFU38Pogaf4FVuE62KI/oJ02RDdWW2w5dqQwU/8+N1q1DlvsL863u61KLE7x/o8w0VJQM/Y/SQ3unIrqxueEa1BqT5VFNsO7p39/UC771a77RowpaKe9nvJQIT1Pog5LGx8XblBKmCNGTf3xMogAQvPnz9PYKX/08sVDTG1OKUlOLUgS/UaZtm1NAaYTsl7i9ZQ+L6O4Rl0OGa577LuWvc+C+x96/vYh0lLBuM+7XwI/dTLtdT7v4d6rRTWDnku0IBrqFnZ5bVIqKP8lasJlithWnaLhTsr8qFJBulF/70p4undou36HeTJ5+jv1fCybeQ8nH3+Xv6aENczmOFlab+hqMDg1rLOt12A+tiUFrYDwQ6c3RUJp601nzegTNX6WlYAI2zSUV945F6zU56ZmZVQaWspWcIADxJ9GmljQUnL2p2Dpr5T8H+5KJFu+vqBq8qvyHRzStLHPEO5SPYCV9nZe0yZT2RcH0oHvegSzNEJ0oGWU8iQWM12dgPEugngVceGIwZgPFp0BiT1a0a3R5Rcot7ihfA1J/20v96jX7zmTX9s583H0kwx6WnLd09cXrR9LGroOa9sHNbdyz8wcKk5lqhaVFJZNwmqtw884MXNdvJujpBa3xzuSaZH9sxa06Z7x+HJSduPbdYHv/DgmEhfbehvlmGN7JUkcG78GDM12CeyFFTPNqVeNxC1gzjz+c2nVo63Xxs8rKJWXoBJM0tmEbfGm4qzpoOH3xpzQfyxLzW1gnE9NHo6tol1eMEic4ZVPrjnVi0kqAe2sQ2bgqupScaq8WGlUWgWHI51SKJl/UYT6zccNsCSkBtiVZLsiefuFSDYT3Fi8Zk7EUnmjTRYtsFeuDDJS05MW79M3mr3mla+d8dzac31KTPmBYfFiYSUef48PhPjm9ryZsSGZZkdNvzq0Y9rdNcwDq5Dg5C3QW+7UN64IKptvS3tvHbvu5c9pv1Exau21rc9LIpwpQwUjTq8576yeVDz5+4WZ1nXT43wV60rPLJbDp/UksNrP3iQ2SA63Pst058gOYDbhRnRUw8l/sRt4HbxPzO4WYpInCpuVgSbVh6JXuwnnJngKTTCwaPWmG5Xbhpm1U0Yt3FyBGpGYemPM77p2TD904JjgJ2QFpFLeYpGx8X15Qx1Zk31p5ki9ZLUuXE0lmuJlcakJMVLeFS1iIvrB8drY0aloilakqCZwzwRORtxlgwxS4IThggJd4TDxoiaAIT80fFPGrCPPru+puFn504P/ybr4ihA/6dKASLshEJic7xE8tmzu3KzA7TABBe8y5fNbWo3ilQn/SuFKM16b2l5bOeayqfGhYmhIulU+fVNDdWVv4NMzX10MBHyPR5uhWUu8D9P1VnIMt4nGNgZGBgAOJ/1bf64vltvjJwszOAwAOlmqvINEc/WJyDgQlEAQA+dgnjAHicY2BkYGBnAAGOPgaG//85+hkYGVCBPgBGJwNkAAAAeJxjYGBgYB/EmKMPtxwAhg4B0gAAAAAAAA4AaAB+AMwA4AECAUIBbAGYAe4CLgKKAtAC/ANiA4wDqAPgBDAEsATaBQgFWgXABggGLgZwBqwG9gdOB4oH0ggqCHAIhgicCMgJJAlWCYgJrAnyCkAKdgrkC7J4nGNgZGBg0GdoZmBnAAEmIOYCQgaG/2A+AwAaqwHQAHicXZBNaoNAGIZfE5PQCKFQ2lUps2oXBfOzzAESyDKBQJdGR2NQR3QSSE/QE/QEPUUPUHqsvsrXjTMw83zPvPMNCuAWP3DQDAejdm1GjzwS7pMmwi75XngAD4/CQ/oX4TFe4Qt7uMMbOzjuDc0EmXCP/C7cJ38Iu+RP4QEe8CU8pP8WHmOPX2EPz87TPo202ey2OjlnQSXV/6arOjWFmvszMWtd6CqwOlKHq6ovycLaWMWVydXKFFZnmVFlZU46tP7R2nI5ncbi/dDkfDtFBA2DDXbYkhKc+V0Bqs5Zt9JM1HQGBRTm/EezTmZNKtpcAMs9Yu6AK9caF76zoLWIWcfMGOSkVduvSWechqZsz040Ib2PY3urxBJTzriT95lipz+TN1fmAAAAeJxtkXlT2zAQxf1C4thJAwRajt4HRy8VMwwfSJHXsQZZcnUQ+PYoTtwpM+wf2t9brWZ2n5JBsol58nJcYYAdDDFCijEy5JhgileYYRd72MccBzjEa7zBEY5xglO8xTu8xwd8xCd8xhd8xTec4RwXuMR3/MBP/MJvMPzBFYpk2Cr+OF0fTEgrFI1aHhxN740KDbEmeJpsWZlVj40s+45aLuv9KijlhCXSjLQnu/d/4UH6sWul1mRzFxZeekUuE7z10mg3qMtM1FGQddPSrLQyvJR6OaukItYXDp6pCJrmz0umqkau5pZ2hFmm7m+ImG5W2t0kZoJXUtPhVnYTbbdOBdeCVGqpJe7XKTqSbRK7zbdwXfR0U+SVsStuS3Y76em6+Ic3xYiHUppc04Nn0lMzay3dSxNcp8auDlWlaCi48yetFD7Y9USsx87G45cuop1ZxQUtjLnL4j53FO0a+5X08UXqQ7NQNo92R0XOz7sxWEnxN2TneJI8Acttu4Q=) format("woff");font-weight:400;font-style:normal}.vjs-icon-play,.video-js .vjs-play-control .vjs-icon-placeholder,.pillarbox-js .vjs-play-control .vjs-icon-placeholder,.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-play:before,.video-js .vjs-play-control .vjs-icon-placeholder:before,.pillarbox-js .vjs-play-control .vjs-icon-placeholder:before,.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{content:""}.vjs-icon-play-circle{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-play-circle:before{content:""}.vjs-icon-pause,.video-js .vjs-play-control.vjs-playing .vjs-icon-placeholder,.pillarbox-js .vjs-play-control.vjs-playing .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-pause:before,.video-js .vjs-play-control.vjs-playing .vjs-icon-placeholder:before,.pillarbox-js .vjs-play-control.vjs-playing .vjs-icon-placeholder:before{content:""}.vjs-icon-volume-mute,.video-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder,.pillarbox-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-volume-mute:before,.video-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder:before,.pillarbox-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder:before{content:""}.vjs-icon-volume-low,.video-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder,.pillarbox-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-volume-low:before,.video-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder:before,.pillarbox-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder:before{content:""}.vjs-icon-volume-mid,.video-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder,.pillarbox-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-volume-mid:before,.video-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder:before,.pillarbox-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder:before{content:""}.vjs-icon-volume-high,.video-js .vjs-mute-control .vjs-icon-placeholder,.pillarbox-js .vjs-mute-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-volume-high:before,.video-js .vjs-mute-control .vjs-icon-placeholder:before,.pillarbox-js .vjs-mute-control .vjs-icon-placeholder:before{content:""}.vjs-icon-fullscreen-enter,.video-js .vjs-fullscreen-control .vjs-icon-placeholder,.pillarbox-js .vjs-fullscreen-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-fullscreen-enter:before,.video-js .vjs-fullscreen-control .vjs-icon-placeholder:before,.pillarbox-js .vjs-fullscreen-control .vjs-icon-placeholder:before{content:""}.vjs-icon-fullscreen-exit,.video-js.vjs-fullscreen .vjs-fullscreen-control .vjs-icon-placeholder,.vjs-fullscreen.pillarbox-js .vjs-fullscreen-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-fullscreen-exit:before,.video-js.vjs-fullscreen .vjs-fullscreen-control .vjs-icon-placeholder:before,.vjs-fullscreen.pillarbox-js .vjs-fullscreen-control .vjs-icon-placeholder:before{content:""}.vjs-icon-spinner{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-spinner:before{content:""}.vjs-icon-subtitles,.video-js .vjs-subs-caps-button .vjs-icon-placeholder,.pillarbox-js .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-GB) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-IE) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-AU) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-NZ) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js .vjs-subtitles-button .vjs-icon-placeholder,.pillarbox-js .vjs-subtitles-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-subtitles:before,.video-js .vjs-subs-caps-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-GB) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-IE) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-AU) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-NZ) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js .vjs-subtitles-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-subtitles-button .vjs-icon-placeholder:before{content:""}.vjs-icon-captions,.video-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder,.pillarbox-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder,.pillarbox-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js .vjs-captions-button .vjs-icon-placeholder,.pillarbox-js .vjs-captions-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-captions:before,.video-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder:before,.pillarbox-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder:before,.pillarbox-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js .vjs-captions-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-captions-button .vjs-icon-placeholder:before{content:""}.vjs-icon-hd{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-hd:before{content:""}.vjs-icon-chapters,.video-js .vjs-chapters-button .vjs-icon-placeholder,.pillarbox-js .vjs-chapters-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-chapters:before,.video-js .vjs-chapters-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-chapters-button .vjs-icon-placeholder:before{content:""}.vjs-icon-downloading{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-downloading:before{content:""}.vjs-icon-file-download{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-file-download:before{content:""}.vjs-icon-file-download-done{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-file-download-done:before{content:""}.vjs-icon-file-download-off{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-file-download-off:before{content:""}.vjs-icon-share{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-share:before{content:""}.vjs-icon-cog{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-cog:before{content:""}.vjs-icon-square{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-square:before{content:""}.vjs-icon-circle,.vjs-seek-to-live-control .vjs-icon-placeholder,.video-js .vjs-volume-level,.pillarbox-js .vjs-volume-level,.video-js .vjs-play-progress,.pillarbox-js .vjs-play-progress{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-circle:before,.vjs-seek-to-live-control .vjs-icon-placeholder:before,.video-js .vjs-volume-level:before,.pillarbox-js .vjs-volume-level:before,.video-js .vjs-play-progress:before,.pillarbox-js .vjs-play-progress:before{content:""}.vjs-icon-circle-outline{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-circle-outline:before{content:""}.vjs-icon-circle-inner-circle{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-circle-inner-circle:before{content:""}.vjs-icon-cancel,.video-js .vjs-control.vjs-close-button .vjs-icon-placeholder,.pillarbox-js .vjs-control.vjs-close-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-cancel:before,.video-js .vjs-control.vjs-close-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-control.vjs-close-button .vjs-icon-placeholder:before{content:""}.vjs-icon-repeat{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-repeat:before{content:""}.vjs-icon-replay,.video-js .vjs-play-control.vjs-ended .vjs-icon-placeholder,.pillarbox-js .vjs-play-control.vjs-ended .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-replay:before,.video-js .vjs-play-control.vjs-ended .vjs-icon-placeholder:before,.pillarbox-js .vjs-play-control.vjs-ended .vjs-icon-placeholder:before{content:""}.vjs-icon-replay-5,.video-js .vjs-skip-backward-5 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-backward-5 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-replay-5:before,.video-js .vjs-skip-backward-5 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-backward-5 .vjs-icon-placeholder:before{content:""}.vjs-icon-replay-10,.video-js .vjs-skip-backward-10 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-backward-10 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-replay-10:before,.video-js .vjs-skip-backward-10 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-backward-10 .vjs-icon-placeholder:before{content:""}.vjs-icon-replay-30,.video-js .vjs-skip-backward-30 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-backward-30 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-replay-30:before,.video-js .vjs-skip-backward-30 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-backward-30 .vjs-icon-placeholder:before{content:""}.vjs-icon-forward-5,.video-js .vjs-skip-forward-5 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-forward-5 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-forward-5:before,.video-js .vjs-skip-forward-5 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-forward-5 .vjs-icon-placeholder:before{content:""}.vjs-icon-forward-10,.video-js .vjs-skip-forward-10 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-forward-10 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-forward-10:before,.video-js .vjs-skip-forward-10 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-forward-10 .vjs-icon-placeholder:before{content:""}.vjs-icon-forward-30,.video-js .vjs-skip-forward-30 .vjs-icon-placeholder,.pillarbox-js .vjs-skip-forward-30 .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-forward-30:before,.video-js .vjs-skip-forward-30 .vjs-icon-placeholder:before,.pillarbox-js .vjs-skip-forward-30 .vjs-icon-placeholder:before{content:""}.vjs-icon-audio,.video-js .vjs-audio-button .vjs-icon-placeholder,.pillarbox-js .vjs-audio-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-audio:before,.video-js .vjs-audio-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-audio-button .vjs-icon-placeholder:before{content:""}.vjs-icon-next-item{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-next-item:before{content:""}.vjs-icon-previous-item{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-previous-item:before{content:""}.vjs-icon-shuffle{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-shuffle:before{content:""}.vjs-icon-cast{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-cast:before{content:""}.vjs-icon-picture-in-picture-enter,.video-js .vjs-picture-in-picture-control .vjs-icon-placeholder,.pillarbox-js .vjs-picture-in-picture-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-picture-in-picture-enter:before,.video-js .vjs-picture-in-picture-control .vjs-icon-placeholder:before,.pillarbox-js .vjs-picture-in-picture-control .vjs-icon-placeholder:before{content:""}.vjs-icon-picture-in-picture-exit,.video-js.vjs-picture-in-picture .vjs-picture-in-picture-control .vjs-icon-placeholder,.vjs-picture-in-picture.pillarbox-js .vjs-picture-in-picture-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-picture-in-picture-exit:before,.video-js.vjs-picture-in-picture .vjs-picture-in-picture-control .vjs-icon-placeholder:before,.vjs-picture-in-picture.pillarbox-js .vjs-picture-in-picture-control .vjs-icon-placeholder:before{content:""}.vjs-icon-facebook{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-facebook:before{content:""}.vjs-icon-linkedin{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-linkedin:before{content:""}.vjs-icon-twitter{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-twitter:before{content:""}.vjs-icon-tumblr{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-tumblr:before{content:""}.vjs-icon-pinterest{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-pinterest:before{content:""}.vjs-icon-audio-description,.video-js .vjs-descriptions-button .vjs-icon-placeholder,.pillarbox-js .vjs-descriptions-button .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-audio-description:before,.video-js .vjs-descriptions-button .vjs-icon-placeholder:before,.pillarbox-js .vjs-descriptions-button .vjs-icon-placeholder:before{content:""}.video-js,.pillarbox-js{display:inline-block;vertical-align:top;box-sizing:border-box;color:#fff;background-color:#000;position:relative;padding:0;font-size:10px;line-height:1;font-weight:400;font-style:normal;font-family:Arial,Helvetica,sans-serif;word-break:initial}.video-js:-moz-full-screen,.pillarbox-js:-moz-full-screen{position:absolute}.video-js:-webkit-full-screen,.pillarbox-js:-webkit-full-screen{width:100%!important;height:100%!important}.video-js[tabindex="-1"],[tabindex="-1"].pillarbox-js{outline:none}.video-js *,.pillarbox-js *,.video-js *:before,.pillarbox-js *:before,.video-js *:after,.pillarbox-js *:after{box-sizing:inherit}.video-js ul,.pillarbox-js ul{font-family:inherit;font-size:inherit;line-height:inherit;list-style-position:outside;margin:0}.video-js.vjs-fluid,.vjs-fluid.pillarbox-js,.video-js.vjs-16-9,.vjs-16-9.pillarbox-js,.video-js.vjs-4-3,.vjs-4-3.pillarbox-js,.video-js.vjs-9-16,.vjs-9-16.pillarbox-js,.video-js.vjs-1-1,.vjs-1-1.pillarbox-js{width:100%;max-width:100%}.video-js.vjs-fluid:not(.vjs-audio-only-mode),.vjs-fluid.pillarbox-js:not(.vjs-audio-only-mode),.video-js.vjs-16-9:not(.vjs-audio-only-mode),.vjs-16-9.pillarbox-js:not(.vjs-audio-only-mode),.video-js.vjs-4-3:not(.vjs-audio-only-mode),.vjs-4-3.pillarbox-js:not(.vjs-audio-only-mode),.video-js.vjs-9-16:not(.vjs-audio-only-mode),.vjs-9-16.pillarbox-js:not(.vjs-audio-only-mode),.video-js.vjs-1-1:not(.vjs-audio-only-mode),.vjs-1-1.pillarbox-js:not(.vjs-audio-only-mode){height:0}.video-js.vjs-16-9:not(.vjs-audio-only-mode),.vjs-16-9.pillarbox-js:not(.vjs-audio-only-mode){padding-top:56.25%}.video-js.vjs-4-3:not(.vjs-audio-only-mode),.vjs-4-3.pillarbox-js:not(.vjs-audio-only-mode){padding-top:75%}.video-js.vjs-9-16:not(.vjs-audio-only-mode),.vjs-9-16.pillarbox-js:not(.vjs-audio-only-mode){padding-top:177.7777777778%}.video-js.vjs-1-1:not(.vjs-audio-only-mode),.vjs-1-1.pillarbox-js:not(.vjs-audio-only-mode){padding-top:100%}.video-js.vjs-fill:not(.vjs-audio-only-mode),.vjs-fill.pillarbox-js:not(.vjs-audio-only-mode){width:100%;height:100%}.video-js .vjs-tech,.pillarbox-js .vjs-tech{position:absolute;top:0;left:0;width:100%;height:100%}.video-js.vjs-audio-only-mode .vjs-tech,.vjs-audio-only-mode.pillarbox-js .vjs-tech{display:none}body.vjs-full-window,body.vjs-pip-window{padding:0;margin:0;height:100%}.vjs-full-window .video-js.vjs-fullscreen,.vjs-full-window .vjs-fullscreen.pillarbox-js,body.vjs-pip-window .video-js,body.vjs-pip-window .pillarbox-js{position:fixed;overflow:hidden;z-index:1000;left:0;top:0;bottom:0;right:0}.video-js.vjs-fullscreen:not(.vjs-ios-native-fs),.vjs-fullscreen.pillarbox-js:not(.vjs-ios-native-fs),body.vjs-pip-window .video-js,body.vjs-pip-window .pillarbox-js{width:100%!important;height:100%!important;padding-top:0!important;display:block}.video-js.vjs-fullscreen.vjs-user-inactive,.vjs-fullscreen.vjs-user-inactive.pillarbox-js{cursor:none}.vjs-pip-container .vjs-pip-text{position:absolute;bottom:10%;font-size:2em;background-color:#000000b3;padding:.5em;text-align:center;width:100%}.vjs-layout-tiny.vjs-pip-container .vjs-pip-text,.vjs-layout-x-small.vjs-pip-container .vjs-pip-text,.vjs-layout-small.vjs-pip-container .vjs-pip-text{bottom:0;font-size:1.4em}.vjs-hidden{display:none!important}.vjs-disabled{opacity:.5;cursor:default}.video-js .vjs-offscreen,.pillarbox-js .vjs-offscreen{height:1px;left:-9999px;position:absolute;top:0;width:1px}.vjs-lock-showing{display:block!important;opacity:1!important;visibility:visible!important}.vjs-no-js{padding:20px;color:#fff;background-color:#000;font-size:18px;font-family:Arial,Helvetica,sans-serif;text-align:center;width:300px;height:150px;margin:0 auto}.vjs-no-js a,.vjs-no-js a:visited{color:#66a8cc}.video-js .vjs-big-play-button,.pillarbox-js .vjs-big-play-button{font-size:3em;line-height:1.5em;height:1.63332em;width:3em;display:block;position:absolute;top:50%;left:50%;padding:0;margin-top:-.81666em;margin-left:-1.5em;cursor:pointer;opacity:1;border:.06666em solid #fff;background-color:#2b333f;background-color:#2b333fb3;border-radius:.3em;transition:all .4s}.vjs-big-play-button .vjs-svg-icon{width:1em;height:1em;position:absolute;top:50%;left:50%;line-height:1;transform:translate(-50%,-50%)}.video-js:hover .vjs-big-play-button,.pillarbox-js:hover .vjs-big-play-button,.video-js .vjs-big-play-button:focus,.pillarbox-js .vjs-big-play-button:focus{border-color:#fff;background-color:#73859f;background-color:#73859f80;transition:all 0s}.vjs-controls-disabled .vjs-big-play-button,.vjs-has-started .vjs-big-play-button,.vjs-using-native-controls .vjs-big-play-button,.vjs-error .vjs-big-play-button{display:none}.vjs-has-started.vjs-paused.vjs-show-big-play-button-on-pause:not(.vjs-seeking,.vjs-scrubbing,.vjs-error) .vjs-big-play-button{display:block}.video-js button,.pillarbox-js button{background:none;border:none;color:inherit;display:inline-block;font-size:inherit;line-height:inherit;text-transform:none;text-decoration:none;transition:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}.vjs-control .vjs-button{width:100%;height:100%}.video-js .vjs-control.vjs-close-button,.pillarbox-js .vjs-control.vjs-close-button{cursor:pointer;height:3em;position:absolute;right:0;top:.5em;z-index:2}.video-js .vjs-modal-dialog,.pillarbox-js .vjs-modal-dialog{background:#000c;background:linear-gradient(180deg,#000c,#fff0);overflow:auto}.video-js .vjs-modal-dialog>*,.pillarbox-js .vjs-modal-dialog>*{box-sizing:border-box}.vjs-modal-dialog .vjs-modal-dialog-content{font-size:1.2em;line-height:1.5;padding:20px 24px;z-index:1}.vjs-menu-button{cursor:pointer}.vjs-menu-button.vjs-disabled{cursor:default}.vjs-workinghover .vjs-menu-button.vjs-disabled:hover .vjs-menu{display:none}.vjs-menu .vjs-menu-content{display:block;padding:0;margin:0;font-family:Arial,Helvetica,sans-serif;overflow:auto}.vjs-menu .vjs-menu-content>*{box-sizing:border-box}.vjs-scrubbing .vjs-control.vjs-menu-button:hover .vjs-menu{display:none}.vjs-menu li{display:flex;justify-content:center;list-style:none;margin:0;padding:.2em 0;line-height:1.4em;font-size:1.2em;text-align:center;text-transform:lowercase}.vjs-menu li.vjs-menu-item:focus,.vjs-menu li.vjs-menu-item:hover,.js-focus-visible .vjs-menu li.vjs-menu-item:hover{background-color:#73859f;background-color:#73859f80}.vjs-menu li.vjs-selected,.vjs-menu li.vjs-selected:focus,.vjs-menu li.vjs-selected:hover,.js-focus-visible .vjs-menu li.vjs-selected:hover{background-color:#fff;color:#2b333f}.vjs-menu li.vjs-selected .vjs-svg-icon,.vjs-menu li.vjs-selected:focus .vjs-svg-icon,.vjs-menu li.vjs-selected:hover .vjs-svg-icon,.js-focus-visible .vjs-menu li.vjs-selected:hover .vjs-svg-icon{fill:#000}.video-js .vjs-menu *:not(.vjs-selected):focus:not(:focus-visible),.pillarbox-js .vjs-menu *:not(.vjs-selected):focus:not(:focus-visible),.js-focus-visible .vjs-menu *:not(.vjs-selected):focus:not(.focus-visible){background:none}.vjs-menu li.vjs-menu-title{text-align:center;text-transform:uppercase;font-size:1em;line-height:2em;padding:0;margin:0 0 .3em;font-weight:700;cursor:default}.vjs-menu-button-popup .vjs-menu{display:none;position:absolute;bottom:0;width:10em;left:-3em;height:0em;margin-bottom:1.5em;border-top-color:#2b333fb3}.vjs-pip-window .vjs-menu-button-popup .vjs-menu{left:unset;right:1em}.vjs-menu-button-popup .vjs-menu .vjs-menu-content{background-color:#2b333f;background-color:#2b333fb3;position:absolute;width:100%;bottom:1.5em;max-height:15em}.vjs-layout-tiny .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-x-small .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:5em}.vjs-layout-small .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:10em}.vjs-layout-medium .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:14em}.vjs-layout-large .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-x-large .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-huge .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:25em}.vjs-workinghover .vjs-menu-button-popup.vjs-hover .vjs-menu,.vjs-menu-button-popup .vjs-menu.vjs-lock-showing{display:block}.video-js .vjs-menu-button-inline,.pillarbox-js .vjs-menu-button-inline{transition:all .4s;overflow:hidden}.video-js .vjs-menu-button-inline:before,.pillarbox-js .vjs-menu-button-inline:before{width:2.222222222em}.video-js .vjs-menu-button-inline:hover,.pillarbox-js .vjs-menu-button-inline:hover,.video-js .vjs-menu-button-inline:focus,.pillarbox-js .vjs-menu-button-inline:focus,.video-js .vjs-menu-button-inline.vjs-slider-active,.pillarbox-js .vjs-menu-button-inline.vjs-slider-active{width:12em}.vjs-menu-button-inline .vjs-menu{opacity:0;height:100%;width:auto;position:absolute;left:4em;top:0;padding:0;margin:0;transition:all .4s}.vjs-menu-button-inline:hover .vjs-menu,.vjs-menu-button-inline:focus .vjs-menu,.vjs-menu-button-inline.vjs-slider-active .vjs-menu{display:block;opacity:1}.vjs-menu-button-inline .vjs-menu-content{width:auto;height:100%;margin:0;overflow:hidden}.video-js .vjs-control-bar,.pillarbox-js .vjs-control-bar{display:none;width:100%;position:absolute;bottom:0;left:0;right:0;height:3em;background-color:#2b333f;background-color:#2b333fb3}.video-js:not(.vjs-controls-disabled,.vjs-using-native-controls,.vjs-error) .vjs-control-bar.vjs-lock-showing,.pillarbox-js:not(.vjs-controls-disabled,.vjs-using-native-controls,.vjs-error) .vjs-control-bar.vjs-lock-showing{display:flex!important}.vjs-has-started .vjs-control-bar,.vjs-audio-only-mode .vjs-control-bar{display:flex;visibility:visible;opacity:1;transition:visibility .1s,opacity .1s}.vjs-has-started.vjs-user-inactive.vjs-playing .vjs-control-bar{visibility:visible;opacity:0;pointer-events:none;transition:visibility 1s,opacity 1s}.vjs-controls-disabled .vjs-control-bar,.vjs-using-native-controls .vjs-control-bar,.vjs-error .vjs-control-bar{display:none!important}.vjs-audio.vjs-has-started.vjs-user-inactive.vjs-playing .vjs-control-bar,.vjs-audio-only-mode.vjs-has-started.vjs-user-inactive.vjs-playing .vjs-control-bar{opacity:1;visibility:visible;pointer-events:auto}.video-js .vjs-control,.pillarbox-js .vjs-control{position:relative;text-align:center;margin:0;padding:0;height:100%;width:4em;flex:none}.video-js .vjs-control.vjs-visible-text,.pillarbox-js .vjs-control.vjs-visible-text{width:auto;padding-left:1em;padding-right:1em}.vjs-button>.vjs-icon-placeholder:before{font-size:1.8em;line-height:1.67}.vjs-button>.vjs-icon-placeholder{display:block}.vjs-button>.vjs-svg-icon{display:inline-block}.video-js .vjs-control:focus:before,.pillarbox-js .vjs-control:focus:before,.video-js .vjs-control:hover:before,.pillarbox-js .vjs-control:hover:before,.video-js .vjs-control:focus,.pillarbox-js .vjs-control:focus{text-shadow:0em 0em 1em white}.video-js *:not(.vjs-visible-text)>.vjs-control-text,.pillarbox-js *:not(.vjs-visible-text)>.vjs-control-text{border:0;clip:rect(0 0 0 0);height:1px;overflow:hidden;padding:0;position:absolute;width:1px}.video-js .vjs-custom-control-spacer,.pillarbox-js .vjs-custom-control-spacer{display:none}.video-js .vjs-progress-control,.pillarbox-js .vjs-progress-control{cursor:pointer;flex:auto;display:flex;align-items:center;min-width:4em;touch-action:none}.video-js .vjs-progress-control.disabled,.pillarbox-js .vjs-progress-control.disabled{cursor:default}.vjs-live .vjs-progress-control{display:none}.vjs-liveui .vjs-progress-control{display:flex;align-items:center}.video-js .vjs-progress-holder,.pillarbox-js .vjs-progress-holder{flex:auto;transition:all .2s;height:.3em}.video-js .vjs-progress-control .vjs-progress-holder,.pillarbox-js .vjs-progress-control .vjs-progress-holder{margin:0 10px}.video-js .vjs-progress-control:hover .vjs-progress-holder,.pillarbox-js .vjs-progress-control:hover .vjs-progress-holder{font-size:1.6666666667em}.video-js .vjs-progress-control:hover .vjs-progress-holder.disabled,.pillarbox-js .vjs-progress-control:hover .vjs-progress-holder.disabled{font-size:1em}.video-js .vjs-progress-holder .vjs-play-progress,.pillarbox-js .vjs-progress-holder .vjs-play-progress,.video-js .vjs-progress-holder .vjs-load-progress,.pillarbox-js .vjs-progress-holder .vjs-load-progress,.video-js .vjs-progress-holder .vjs-load-progress div,.pillarbox-js .vjs-progress-holder .vjs-load-progress div{position:absolute;display:block;height:100%;margin:0;padding:0;width:0}.video-js .vjs-play-progress,.pillarbox-js .vjs-play-progress{background-color:#fff}.video-js .vjs-play-progress:before,.pillarbox-js .vjs-play-progress:before{font-size:.9em;position:absolute;right:-.5em;line-height:.35em;z-index:1}.vjs-svg-icons-enabled .vjs-play-progress:before{content:none!important}.vjs-play-progress .vjs-svg-icon{position:absolute;top:-.35em;right:-.4em;width:.9em;height:.9em;pointer-events:none;line-height:.15em;z-index:1}.video-js .vjs-load-progress,.pillarbox-js .vjs-load-progress{background:#73859f80}.video-js .vjs-load-progress div,.pillarbox-js .vjs-load-progress div{background:#73859fbf}.video-js .vjs-time-tooltip,.pillarbox-js .vjs-time-tooltip{background-color:#fff;background-color:#fffc;border-radius:.3em;color:#000;float:right;font-family:Arial,Helvetica,sans-serif;font-size:1em;padding:6px 8px 8px;pointer-events:none;position:absolute;top:-3.4em;visibility:hidden;z-index:1}.video-js .vjs-progress-holder:focus .vjs-time-tooltip,.pillarbox-js .vjs-progress-holder:focus .vjs-time-tooltip{display:none}.video-js .vjs-progress-control:hover .vjs-time-tooltip,.pillarbox-js .vjs-progress-control:hover .vjs-time-tooltip,.video-js .vjs-progress-control:hover .vjs-progress-holder:focus .vjs-time-tooltip{display:block;font-size:.6em;visibility:visible}.video-js .vjs-progress-control.disabled:hover .vjs-time-tooltip,.pillarbox-js .vjs-progress-control.disabled:hover .vjs-time-tooltip{font-size:1em}.video-js .vjs-progress-control .vjs-mouse-display,.pillarbox-js .vjs-progress-control .vjs-mouse-display{display:none;position:absolute;width:1px;height:100%;background-color:#000;z-index:1}.video-js .vjs-progress-control:hover .vjs-mouse-display,.pillarbox-js .vjs-progress-control:hover .vjs-mouse-display{display:block}.video-js.vjs-user-inactive .vjs-progress-control .vjs-mouse-display,.vjs-user-inactive.pillarbox-js .vjs-progress-control .vjs-mouse-display{visibility:hidden;opacity:0;transition:visibility 1s,opacity 1s}.vjs-mouse-display .vjs-time-tooltip{color:#fff;background-color:#000;background-color:#000c}.video-js .vjs-slider,.pillarbox-js .vjs-slider{position:relative;cursor:pointer;padding:0;margin:0 .45em;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;background-color:#73859f;background-color:#73859f80}.video-js .vjs-slider.disabled,.pillarbox-js .vjs-slider.disabled{cursor:default}.video-js .vjs-slider:focus,.pillarbox-js .vjs-slider:focus{text-shadow:0em 0em 1em white;box-shadow:0 0 1em #fff}.video-js .vjs-mute-control,.pillarbox-js .vjs-mute-control{cursor:pointer;flex:none}.video-js .vjs-volume-control,.pillarbox-js .vjs-volume-control{cursor:pointer;margin-right:1em;display:flex}.video-js .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-control.vjs-volume-horizontal{width:5em}.video-js .vjs-volume-panel .vjs-volume-control,.pillarbox-js .vjs-volume-panel .vjs-volume-control{visibility:visible;opacity:0;width:1px;height:1px;margin-left:-1px}.video-js .vjs-volume-panel,.pillarbox-js .vjs-volume-panel{transition:width 1s}.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control,.pillarbox-js .vjs-volume-panel.vjs-hover .vjs-volume-control,.video-js .vjs-volume-panel:active .vjs-volume-control,.pillarbox-js .vjs-volume-panel:active .vjs-volume-control,.video-js .vjs-volume-panel:focus .vjs-volume-control,.pillarbox-js .vjs-volume-panel:focus .vjs-volume-control,.video-js .vjs-volume-panel .vjs-volume-control:active,.pillarbox-js .vjs-volume-panel .vjs-volume-control:active,.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active{visibility:visible;opacity:1;position:relative;transition:visibility .1s,opacity .1s,height .1s,width .1s,left 0s,top 0s}.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-horizontal,.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-horizontal{width:5em;height:3em;margin-right:0}.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-vertical,.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-vertical{left:-3.5em;transition:left 0s}.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.video-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active{width:10em;transition:width .1s}.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-mute-toggle-only,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-mute-toggle-only{width:4em}.video-js .vjs-volume-panel .vjs-volume-control.vjs-volume-vertical,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-volume-vertical{height:8em;width:3em;left:-3000em;transition:visibility 1s,opacity 1s,height 1s 1s,width 1s 1s,left 1s 1s,top 1s 1s}.video-js .vjs-volume-panel .vjs-volume-control.vjs-volume-horizontal,.pillarbox-js .vjs-volume-panel .vjs-volume-control.vjs-volume-horizontal{transition:visibility 1s,opacity 1s,height 1s 1s,width 1s,left 1s 1s,top 1s 1s}.video-js .vjs-volume-panel,.pillarbox-js .vjs-volume-panel{display:flex}.video-js .vjs-volume-bar,.pillarbox-js .vjs-volume-bar{margin:1.35em .45em}.vjs-volume-bar.vjs-slider-horizontal{width:5em;height:.3em}.vjs-volume-bar.vjs-slider-vertical{width:.3em;height:5em;margin:1.35em auto}.video-js .vjs-volume-level,.pillarbox-js .vjs-volume-level{position:absolute;bottom:0;left:0;background-color:#fff}.video-js .vjs-volume-level:before,.pillarbox-js .vjs-volume-level:before{position:absolute;font-size:.9em;z-index:1}.vjs-slider-vertical .vjs-volume-level{width:.3em}.vjs-slider-vertical .vjs-volume-level:before{top:-.5em;left:-.3em;z-index:1}.vjs-svg-icons-enabled .vjs-volume-level:before{content:none}.vjs-volume-level .vjs-svg-icon{position:absolute;width:.9em;height:.9em;pointer-events:none;z-index:1}.vjs-slider-horizontal .vjs-volume-level{height:.3em}.vjs-slider-horizontal .vjs-volume-level:before{line-height:.35em;right:-.5em}.vjs-slider-horizontal .vjs-volume-level .vjs-svg-icon{right:-.3em;transform:translateY(-50%)}.vjs-slider-vertical .vjs-volume-level .vjs-svg-icon{top:-.55em;transform:translate(-50%)}.video-js .vjs-volume-panel.vjs-volume-panel-vertical,.pillarbox-js .vjs-volume-panel.vjs-volume-panel-vertical{width:4em}.vjs-volume-bar.vjs-slider-vertical .vjs-volume-level{height:100%}.vjs-volume-bar.vjs-slider-horizontal .vjs-volume-level{width:100%}.video-js .vjs-volume-vertical,.pillarbox-js .vjs-volume-vertical{width:3em;height:8em;bottom:8em;background-color:#2b333f;background-color:#2b333fb3}.video-js .vjs-volume-horizontal .vjs-menu,.pillarbox-js .vjs-volume-horizontal .vjs-menu{left:-2em}.video-js .vjs-volume-tooltip,.pillarbox-js .vjs-volume-tooltip{background-color:#fff;background-color:#fffc;border-radius:.3em;color:#000;float:right;font-family:Arial,Helvetica,sans-serif;font-size:1em;padding:6px 8px 8px;pointer-events:none;position:absolute;top:-3.4em;visibility:hidden;z-index:1}.video-js .vjs-volume-control:hover .vjs-volume-tooltip,.pillarbox-js .vjs-volume-control:hover .vjs-volume-tooltip,.video-js .vjs-volume-control:hover .vjs-progress-holder:focus .vjs-volume-tooltip{display:block;font-size:1em;visibility:visible}.video-js .vjs-volume-vertical:hover .vjs-volume-tooltip,.pillarbox-js .vjs-volume-vertical:hover .vjs-volume-tooltip,.video-js .vjs-volume-vertical:hover .vjs-progress-holder:focus .vjs-volume-tooltip{left:1em;top:-12px}.video-js .vjs-volume-control.disabled:hover .vjs-volume-tooltip,.pillarbox-js .vjs-volume-control.disabled:hover .vjs-volume-tooltip{font-size:1em}.video-js .vjs-volume-control .vjs-mouse-display,.pillarbox-js .vjs-volume-control .vjs-mouse-display{display:none;position:absolute;width:100%;height:1px;background-color:#000;z-index:1}.video-js .vjs-volume-horizontal .vjs-mouse-display,.pillarbox-js .vjs-volume-horizontal .vjs-mouse-display{width:1px;height:100%}.video-js .vjs-volume-control:hover .vjs-mouse-display,.pillarbox-js .vjs-volume-control:hover .vjs-mouse-display{display:block}.video-js.vjs-user-inactive .vjs-volume-control .vjs-mouse-display,.vjs-user-inactive.pillarbox-js .vjs-volume-control .vjs-mouse-display{visibility:hidden;opacity:0;transition:visibility 1s,opacity 1s}.vjs-mouse-display .vjs-volume-tooltip{color:#fff;background-color:#000;background-color:#000c}.vjs-poster{display:inline-block;vertical-align:middle;cursor:pointer;margin:0;padding:0;position:absolute;top:0;right:0;bottom:0;left:0;height:100%}.vjs-has-started .vjs-poster,.vjs-using-native-controls .vjs-poster{display:none}.vjs-audio.vjs-has-started .vjs-poster,.vjs-has-started.vjs-audio-poster-mode .vjs-poster,.vjs-pip-container.vjs-has-started .vjs-poster{display:block}.vjs-poster img{width:100%;height:100%;-o-object-fit:contain;object-fit:contain}.video-js .vjs-live-control,.pillarbox-js .vjs-live-control{display:flex;align-items:flex-start;flex:auto;font-size:1em;line-height:3em}.video-js:not(.vjs-live) .vjs-live-control,.pillarbox-js:not(.vjs-live) .vjs-live-control,.video-js.vjs-liveui .vjs-live-control,.vjs-liveui.pillarbox-js .vjs-live-control{display:none}.video-js .vjs-seek-to-live-control,.pillarbox-js .vjs-seek-to-live-control{align-items:center;cursor:pointer;flex:none;display:inline-flex;height:100%;padding-left:.5em;padding-right:.5em;font-size:1em;line-height:3em;width:auto;min-width:4em}.video-js.vjs-live:not(.vjs-liveui) .vjs-seek-to-live-control,.vjs-live.pillarbox-js:not(.vjs-liveui) .vjs-seek-to-live-control,.video-js:not(.vjs-live) .vjs-seek-to-live-control,.pillarbox-js:not(.vjs-live) .vjs-seek-to-live-control{display:none}.vjs-seek-to-live-control.vjs-control.vjs-at-live-edge{cursor:auto}.vjs-seek-to-live-control .vjs-icon-placeholder{margin-right:.5em;color:#888}.vjs-svg-icons-enabled .vjs-seek-to-live-control{line-height:0}.vjs-seek-to-live-control .vjs-svg-icon{width:1em;height:1em;pointer-events:none;fill:#888}.vjs-seek-to-live-control.vjs-control.vjs-at-live-edge .vjs-icon-placeholder{color:red}.vjs-seek-to-live-control.vjs-control.vjs-at-live-edge .vjs-svg-icon{fill:red}.video-js .vjs-time-control,.pillarbox-js .vjs-time-control{flex:none;font-size:1em;line-height:3em;min-width:2em;width:auto;padding-left:1em;padding-right:1em}.vjs-live .vjs-time-control,.vjs-live .vjs-time-divider,.video-js .vjs-current-time,.pillarbox-js .vjs-current-time,.video-js .vjs-duration,.pillarbox-js .vjs-duration{display:none}.vjs-time-divider{display:none;line-height:3em}.video-js .vjs-play-control,.pillarbox-js .vjs-play-control{cursor:pointer}.video-js .vjs-play-control .vjs-icon-placeholder,.pillarbox-js .vjs-play-control .vjs-icon-placeholder{flex:none}.vjs-text-track-display{position:absolute;bottom:3em;left:0;right:0;top:0;pointer-events:none}.vjs-error .vjs-text-track-display{display:none}.video-js.vjs-controls-disabled .vjs-text-track-display,.vjs-controls-disabled.pillarbox-js .vjs-text-track-display,.video-js.vjs-user-inactive.vjs-playing .vjs-text-track-display,.vjs-user-inactive.vjs-playing.pillarbox-js .vjs-text-track-display{bottom:1em}.video-js .vjs-text-track,.pillarbox-js .vjs-text-track{font-size:1.4em;text-align:center;margin-bottom:.1em}.vjs-subtitles{color:#fff}.vjs-captions{color:#fc6}.vjs-tt-cue{display:block}video::-webkit-media-text-track-display{transform:translateY(-3em)}.video-js.vjs-controls-disabled video::-webkit-media-text-track-display,.vjs-controls-disabled.pillarbox-js video::-webkit-media-text-track-display,.video-js.vjs-user-inactive.vjs-playing video::-webkit-media-text-track-display,.vjs-user-inactive.vjs-playing.pillarbox-js video::-webkit-media-text-track-display{transform:translateY(-1.5em)}.video-js .vjs-picture-in-picture-control,.pillarbox-js .vjs-picture-in-picture-control{cursor:pointer;flex:none}.video-js.vjs-audio-only-mode .vjs-picture-in-picture-control,.vjs-audio-only-mode.pillarbox-js .vjs-picture-in-picture-control,.vjs-pip-window .vjs-picture-in-picture-control{display:none}.video-js .vjs-fullscreen-control,.pillarbox-js .vjs-fullscreen-control{cursor:pointer;flex:none}.video-js.vjs-audio-only-mode .vjs-fullscreen-control,.vjs-audio-only-mode.pillarbox-js .vjs-fullscreen-control,.vjs-pip-window .vjs-fullscreen-control{display:none}.vjs-playback-rate>.vjs-menu-button,.vjs-playback-rate .vjs-playback-rate-value{position:absolute;top:0;left:0;width:100%;height:100%}.vjs-playback-rate .vjs-playback-rate-value{pointer-events:none;font-size:1.5em;line-height:2;text-align:center}.vjs-playback-rate .vjs-menu{width:4em;left:0}.vjs-error .vjs-error-display .vjs-modal-dialog-content{font-size:1.4em;text-align:center}.vjs-loading-spinner{display:none;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);opacity:.85;text-align:left;border:.6em solid rgba(43,51,63,.7);box-sizing:border-box;background-clip:padding-box;width:5em;height:5em;border-radius:50%;visibility:hidden}.vjs-seeking .vjs-loading-spinner,.vjs-waiting .vjs-loading-spinner{display:flex;justify-content:center;align-items:center;animation:vjs-spinner-show 0s linear .3s forwards}.vjs-error .vjs-loading-spinner{display:none}.vjs-loading-spinner:before,.vjs-loading-spinner:after{content:"";position:absolute;box-sizing:inherit;width:inherit;height:inherit;border-radius:inherit;opacity:1;border:inherit;border-color:transparent;border-top-color:#fff}.vjs-seeking .vjs-loading-spinner:before,.vjs-seeking .vjs-loading-spinner:after,.vjs-waiting .vjs-loading-spinner:before,.vjs-waiting .vjs-loading-spinner:after{animation:vjs-spinner-spin 1.1s cubic-bezier(.6,.2,0,.8) infinite,vjs-spinner-fade 1.1s linear infinite}.vjs-seeking .vjs-loading-spinner:before,.vjs-waiting .vjs-loading-spinner:before{border-top-color:#fff}.vjs-seeking .vjs-loading-spinner:after,.vjs-waiting .vjs-loading-spinner:after{border-top-color:#fff;animation-delay:.44s}@keyframes vjs-spinner-show{to{visibility:visible}}@keyframes vjs-spinner-spin{to{transform:rotate(360deg)}}@keyframes vjs-spinner-fade{0%{border-top-color:#73859f}20%{border-top-color:#73859f}35%{border-top-color:#fff}60%{border-top-color:#73859f}to{border-top-color:#73859f}}.video-js.vjs-audio-only-mode .vjs-captions-button,.vjs-audio-only-mode.pillarbox-js .vjs-captions-button{display:none}.vjs-chapters-button .vjs-menu ul{width:24em}.video-js.vjs-audio-only-mode .vjs-descriptions-button,.vjs-audio-only-mode.pillarbox-js .vjs-descriptions-button{display:none}.vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-svg-icon{width:1.5em;height:1.5em}.video-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder,.pillarbox-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder{vertical-align:middle;display:inline-block;margin-bottom:-.1em}.video-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before,.pillarbox-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before{font-family:VideoJS;content:"";font-size:1.5em;line-height:inherit}.video-js.vjs-audio-only-mode .vjs-subs-caps-button,.vjs-audio-only-mode.pillarbox-js .vjs-subs-caps-button{display:none}.video-js .vjs-audio-button+.vjs-menu .vjs-description-menu-item .vjs-menu-item-text .vjs-icon-placeholder,.pillarbox-js .vjs-audio-button+.vjs-menu .vjs-description-menu-item .vjs-menu-item-text .vjs-icon-placeholder,.video-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder,.pillarbox-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder{vertical-align:middle;display:inline-block;margin-bottom:-.1em}.video-js .vjs-audio-button+.vjs-menu .vjs-description-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before,.pillarbox-js .vjs-audio-button+.vjs-menu .vjs-description-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before,.video-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before,.pillarbox-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before{font-family:VideoJS;content:" ";font-size:1.5em;line-height:inherit}.video-js.vjs-layout-small .vjs-current-time,.vjs-layout-small.pillarbox-js .vjs-current-time,.video-js.vjs-layout-small .vjs-time-divider,.vjs-layout-small.pillarbox-js .vjs-time-divider,.video-js.vjs-layout-small .vjs-duration,.vjs-layout-small.pillarbox-js .vjs-duration,.video-js.vjs-layout-small .vjs-remaining-time,.vjs-layout-small.pillarbox-js .vjs-remaining-time,.video-js.vjs-layout-small .vjs-playback-rate,.vjs-layout-small.pillarbox-js .vjs-playback-rate,.video-js.vjs-layout-small .vjs-volume-control,.vjs-layout-small.pillarbox-js .vjs-volume-control,.video-js.vjs-layout-x-small .vjs-current-time,.vjs-layout-x-small.pillarbox-js .vjs-current-time,.video-js.vjs-layout-x-small .vjs-time-divider,.vjs-layout-x-small.pillarbox-js .vjs-time-divider,.video-js.vjs-layout-x-small .vjs-duration,.vjs-layout-x-small.pillarbox-js .vjs-duration,.video-js.vjs-layout-x-small .vjs-remaining-time,.vjs-layout-x-small.pillarbox-js .vjs-remaining-time,.video-js.vjs-layout-x-small .vjs-playback-rate,.vjs-layout-x-small.pillarbox-js .vjs-playback-rate,.video-js.vjs-layout-x-small .vjs-volume-control,.vjs-layout-x-small.pillarbox-js .vjs-volume-control,.video-js.vjs-layout-tiny .vjs-current-time,.vjs-layout-tiny.pillarbox-js .vjs-current-time,.video-js.vjs-layout-tiny .vjs-time-divider,.vjs-layout-tiny.pillarbox-js .vjs-time-divider,.video-js.vjs-layout-tiny .vjs-duration,.vjs-layout-tiny.pillarbox-js .vjs-duration,.video-js.vjs-layout-tiny .vjs-remaining-time,.vjs-layout-tiny.pillarbox-js .vjs-remaining-time,.video-js.vjs-layout-tiny .vjs-playback-rate,.vjs-layout-tiny.pillarbox-js .vjs-playback-rate,.video-js.vjs-layout-tiny .vjs-volume-control,.vjs-layout-tiny.pillarbox-js .vjs-volume-control{display:none}.video-js.vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.vjs-layout-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.video-js.vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal:active,.vjs-layout-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js.vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.vjs-layout-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js.vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.vjs-layout-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.video-js.vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.vjs-layout-x-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.video-js.vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal:active,.vjs-layout-x-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js.vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.vjs-layout-x-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js.vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.vjs-layout-x-small.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.video-js.vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.vjs-layout-tiny.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.video-js.vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal:active,.vjs-layout-tiny.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js.vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.vjs-layout-tiny.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js.vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.vjs-layout-tiny.pillarbox-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover{width:auto;width:initial}.video-js.vjs-layout-x-small .vjs-progress-control,.vjs-layout-x-small.pillarbox-js .vjs-progress-control,.video-js.vjs-layout-tiny .vjs-progress-control,.vjs-layout-tiny.pillarbox-js .vjs-progress-control{display:none}.video-js.vjs-layout-x-small .vjs-custom-control-spacer,.vjs-layout-x-small.pillarbox-js .vjs-custom-control-spacer{flex:auto;display:block}.vjs-modal-dialog.vjs-text-track-settings{background-color:#2b333f;background-color:#2b333fbf;color:#fff;height:70%}.vjs-error .vjs-text-track-settings{display:none}.vjs-text-track-settings .vjs-modal-dialog-content{display:table}.vjs-text-track-settings .vjs-track-settings-colors,.vjs-text-track-settings .vjs-track-settings-font,.vjs-text-track-settings .vjs-track-settings-controls{display:table-cell}.vjs-text-track-settings .vjs-track-settings-controls{text-align:right;vertical-align:bottom}@supports (display: grid){.vjs-text-track-settings .vjs-modal-dialog-content{display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr;padding:20px 24px 0}.vjs-track-settings-controls .vjs-default-button{margin-bottom:20px}.vjs-text-track-settings .vjs-track-settings-controls{grid-column:1/-1}.vjs-layout-small .vjs-text-track-settings .vjs-modal-dialog-content,.vjs-layout-x-small .vjs-text-track-settings .vjs-modal-dialog-content,.vjs-layout-tiny .vjs-text-track-settings .vjs-modal-dialog-content{grid-template-columns:1fr}}.vjs-text-track-settings select{font-size:inherit}.vjs-track-setting>select{margin-right:1em;margin-bottom:.5em}.vjs-text-track-settings fieldset{margin:10px;border:none}.vjs-text-track-settings fieldset span{display:inline-block;padding:0 .6em .8em}.vjs-text-track-settings fieldset span>select{max-width:7.3em}.vjs-text-track-settings legend{color:#fff;font-weight:700;font-size:1.2em}.vjs-text-track-settings .vjs-label{margin:0 .5em .5em 0}.vjs-track-settings-controls button:focus,.vjs-track-settings-controls button:active{outline-style:solid;outline-width:medium;background-image:linear-gradient(0deg,#fff 88%,#73859f)}.vjs-track-settings-controls button:hover{color:#2b333fbf}.vjs-track-settings-controls button{background-color:#fff;background-image:linear-gradient(-180deg,#fff 88%,#73859f);color:#2b333f;cursor:pointer;border-radius:2px}.vjs-track-settings-controls .vjs-default-button{margin-right:1em}.vjs-title-bar{background:#000000e6;background:linear-gradient(180deg,#000000e6,#000000b3 60%,#0000);font-size:1.2em;line-height:1.5;transition:opacity .1s;padding:.666em 1.333em 4em;pointer-events:none;position:absolute;top:0;width:100%}.vjs-error .vjs-title-bar{display:none}.vjs-title-bar-title,.vjs-title-bar-description{margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.vjs-title-bar-title{font-weight:700;margin-bottom:.333em}.vjs-playing.vjs-user-inactive .vjs-title-bar{opacity:0;transition:opacity 1s}.video-js .vjs-skip-forward-5,.pillarbox-js .vjs-skip-forward-5,.video-js .vjs-skip-forward-10,.pillarbox-js .vjs-skip-forward-10,.video-js .vjs-skip-forward-30,.pillarbox-js .vjs-skip-forward-30,.video-js .vjs-skip-backward-5,.pillarbox-js .vjs-skip-backward-5,.video-js .vjs-skip-backward-10,.pillarbox-js .vjs-skip-backward-10,.video-js .vjs-skip-backward-30,.pillarbox-js .vjs-skip-backward-30{cursor:pointer}@media print{.video-js>*:not(.vjs-tech):not(.vjs-poster),.pillarbox-js>*:not(.vjs-tech):not(.vjs-poster){visibility:hidden}}.vjs-resize-manager{position:absolute;top:0;left:0;width:100%;height:100%;border:none;z-index:-1000}.js-focus-visible .video-js *:focus:not(.focus-visible),.js-focus-visible .pillarbox-js *:focus:not(.focus-visible){outline:none}.video-js *:focus:not(:focus-visible),.pillarbox-js *:focus:not(:focus-visible){outline:none}.pillarbox-js:hover .vjs-big-play-button{background-color:#16161688;transition:background-color .25s ease}.pillarbox-js .vjs-big-play-button{width:2em;height:2em;margin:0;font-size:2.25em;background:#0000;border:.1em solid #fff;border-radius:50%;transform:translate(-50%,-50%);transition:background-color .25s ease}.pillarbox-js .vjs-big-play-button .vjs-icon-placeholder:before{position:initial;display:flex;align-items:center;justify-content:center;font-size:1.75em}.pillarbox-js .vjs-modal-dialog.vjs-text-track-settings{top:50%;left:50%;max-width:25em;max-height:50em;background:#161616f2;border-radius:.5em;box-shadow:2px 2px 3px #0005;transform:translate(-50%,-50%);overscroll-behavior:contain}.pillarbox-js .vjs-text-track-settings .vjs-modal-dialog-content{display:flex;flex-direction:column;padding:1em 1.5em 0}.pillarbox-js .vjs-text-track-settings legend{font-size:1em}.pillarbox-js .vjs-text-track-settings fieldset span{padding-inline:0}.pillarbox-js .vjs-text-track-settings fieldset{display:flex;margin:0 0 1em;padding:0}.pillarbox-js.video-js .vjs-text-track-settings select,.pillarbox-js .vjs-text-track-settings select{margin:.25em 0 0;padding:.5em;color:#fff;background:#3f3f3f;border:none;-webkit-appearance:auto;-moz-appearance:auto;appearance:auto}.pillarbox-js.video-js .vjs-text-track-settings select:focus-within,.pillarbox-js .vjs-text-track-settings select:focus-within{outline:solid}.pillarbox-js .vjs-track-settings-controls{display:flex;flex-direction:row;gap:1em;justify-content:end}.pillarbox-js .vjs-track-settings-controls button{margin-block:1em;padding:.25em .5em;color:#fff;background:#3f3f3f}.pillarbox-js .vjs-track-settings-controls button:hover{background:#5c5c5c}.pillarbox-js .vjs-track-settings-controls .vjs-default-button{margin-right:0}.pillarbox-js .vjs-control{height:3em}.pillarbox-js:not(.vjs-audio-only-mode) .vjs-control-bar{align-items:flex-end;height:6em;padding-inline:1em;background:linear-gradient(#000,#0000 0%,#000000b3)}.pillarbox-js.vjs-audio-only-mode .vjs-control-bar{background-color:#1e232c}.pillarbox-js:not(.vjs-audio-only-mode) .vjs-custom-control-spacer{display:block;flex:auto}.pillarbox-js .vjs-error-display .vjs-modal-dialog-content{display:flex;align-items:center;justify-content:center}.pillarbox-js.vjs-layout-tiny{font-size:8px}.pillarbox-js.vjs-layout-x-small{font-size:10px}.pillarbox-js.vjs-layout-small{font-size:12px}.pillarbox-js.vjs-layout-medium{font-size:14px}.pillarbox-js.vjs-layout-large{font-size:16px}.pillarbox-js.vjs-layout-x-large{font-size:18px}.pillarbox-js.vjs-layout-huge{font-size:20px}.pillarbox-js:not(.vjs-layout-tiny,.vjs-layout-x-small,.vjs-live) .vjs-time-divider,.pillarbox-js:not(.vjs-layout-tiny,.vjs-layout-x-small,.vjs-live) .vjs-current-time,.pillarbox-js:not(.vjs-layout-tiny,.vjs-layout-x-small,.vjs-live) .vjs-duration{display:block;padding:0;font-weight:700}.pillarbox-js.vjs-layout-tiny .vjs-progress-control,.pillarbox-js.vjs-layout-x-small .vjs-progress-control{display:flex}.pillarbox-js.vjs-layout-x-small.vjs-audio-only-mode .vjs-custom-control-spacer{display:none}.pillarbox-js .vjs-loading-spinner{border:.25em solid rgba(0,0,0,0)}.pillarbox-js .vjs-loading-spinner{display:flex;align-items:center;justify-content:center}@keyframes vjs-spinner-fade{0%{border-top-color:#333}20%{border-top-color:#333}35%{border-top-color:#fff}60%{border-top-color:#333}to{border-top-color:#333}}.pillarbox-js .vjs-menu .vjs-menu-item{border-radius:.25em}.pillarbox-js .vjs-menu .vjs-menu-item:not(.vjs-selected):focus,.pillarbox-js .vjs-menu .vjs-menu-item:not(.vjs-selected):hover{background-color:#3f3f3f}.pillarbox-js .vjs-menu .vjs-menu-item.vjs-texttrack-settings:focus,.pillarbox-js .vjs-menu .vjs-menu-item.vjs-texttrack-settings:hover{background-color:#0000}.pillarbox-js .vjs-menu .vjs-menu-item .vjs-selected{color:#222;background-color:#fff;pointer-events:none}.pillarbox-js .vjs-menu-button-popup.vjs-hover .vjs-menu{display:none}.pillarbox-js .vjs-menu-button-popup .vjs-menu{right:0;bottom:0;left:unset;width:100%;margin:0}.pillarbox-js .vjs-menu-button-popup .vjs-menu .vjs-menu-content{right:50%;bottom:5em;display:grid;gap:.25em;min-width:13em;padding:1em .5em;background:#161616f2;border-radius:.5em;transform:translate(50%);overscroll-behavior:contain}.pillarbox-js .vjs-slider{background-color:#ffffff4d;border-radius:1em}.pillarbox-js .vjs-text-track-display{top:0;right:0;bottom:4em;left:0}.pillarbox-js .vjs-current-time{margin-left:1em}.pillarbox-js .vjs-time-divider{min-width:1em;text-align:center}.pillarbox-js .vjs-remaining-time{display:none}.pillarbox-js.vjs-audio-only-mode .vjs-current-time,.pillarbox-js.vjs-audio-only-mode .vjs-time-divider,.pillarbox-js.vjs-audio-only-mode .vjs-duration{order:1}.pillarbox-js.vjs-audio-only-mode .vjs-duration{margin-right:1em}.pillarbox-js .vjs-title-bar{padding-bottom:2em;background:linear-gradient(rgba(0,0,0,.6) 0%,transparent 100%)}.pillarbox-js:not(.vjs-audio-only-mode) .vjs-progress-control{position:absolute;bottom:3em;width:calc(100% - 2em);height:1em}.pillarbox-js .vjs-progress-holder{margin:0}.pillarbox-js .vjs-load-progress{background:#ffffff4d;border-radius:1em}.pillarbox-js .vjs-load-progress div{background:#0000}.pillarbox-js.vjs-scrubbing .vjs-play-progress .vjs-time-tooltip,.pillarbox-js.vjs-seeking .vjs-play-progress .vjs-time-tooltip{display:none}.pillarbox-js .vjs-play-progress{color:#af001e;background:#af001e;border-radius:1em}.pillarbox-js .vjs-play-progress:before{font-size:0px;text-shadow:0px 0px 1px #000}.pillarbox-js .vjs-progress-control:hover .vjs-play-progress:before{font-size:.9em}.pillarbox-js .vjs-progress-control:hover .vjs-time-tooltip{right:0%!important;transform:translate(50%)}.pillarbox-js .vjs-progress-holder:focus-visible .vjs-play-progress:before{font-size:.9em}.pillarbox-js .vjs-time-tooltip,.pillarbox-js .vjs-mouse-display .vjs-time-tooltip{top:-3em;padding:.4em;color:#fff;font-weight:700;text-shadow:1px 1px 3px #000,1px 1px 2px #000;background-color:#0000}.pillarbox-js .vjs-volume-level{border-radius:1em}.pillarbox-js .vjs-volume-tooltip{top:-2em;padding:.4em;font-weight:700;text-shadow:1px 1px 3px #000;background-color:#0000} diff --git a/VANA-php/public/build/manifest.json b/VANA-php/public/build/manifest.json new file mode 100644 index 0000000..12146d2 --- /dev/null +++ b/VANA-php/public/build/manifest.json @@ -0,0 +1,18 @@ +{ + "node_modules/@srgssr/pillarbox-web/dist/pillarbox.min.css": { + "file": "assets/pillarbox-CCcjZzR7.css", + "src": "node_modules/@srgssr/pillarbox-web/dist/pillarbox.min.css", + "isEntry": true + }, + "resources/css/app.css": { + "file": "assets/app-Brxm-Dry.css", + "src": "resources/css/app.css", + "isEntry": true + }, + "resources/js/app.js": { + "file": "assets/app-Bj0O7PhW.js", + "name": "app", + "src": "resources/js/app.js", + "isEntry": true + } +} \ No newline at end of file diff --git a/database.sqlite b/database.sqlite index ebf03b0f8ca5a2a9d61cacd9f1a1666a9a24a550..618c0b1d87ee9fa52bc9799a6bc35ab5bd3ae20e 100644 GIT binary patch delta 408 zcma)$%Ps?99L49GnQAe7I_`H73k#vzy6v>?8YGRjNGhk*YE{&&5tK{*6MTo(wd#Vl_C3FGM1i94%vNyc*vWG_(OhIS9p0YG~stUe7P(z6A6R@<5S+@ zc+x)@U(%=d=GmBT?2St;_ikfXJ7yM<-wOPR-x^Bhf_Jt_LH6HE>Tg*;(OUKIQF!dMK0znW&{%V-7Ubt$JWERV<{+Z^>UhADr?!T68{f2D&>>x0LNRS9J z!9>U-mh_6_gC7mD$@c_|j zQ+S6Q!cM`)A_3jvX`bTaPKwH;C5y6sC5tz_jv`5NmE`uv+nX=zv-++0e0(pFxTSK- zr268?mGcX8uCHbKFg~09JqB9b%7>G0R}KPew34)@loI#r!=FCK0dYti5iO!k L91|zRDbe`{7~Dvx