/*! 
   *
    __  __      _            _       _              _                       
   |  \/  | ___| |_ __ _  __| | __ _| |_ __ _ _ __ | | __ _ _   _  ___ _ __ 
   | |\/| |/ _ \ __/ _` |/ _` |/ _` | __/ _` | '_ \| |/ _` | | | |/ _ \ '__|
   | |  | |  __/ || (_| | (_| | (_| | || (_| | |_) | | (_| | |_| |  __/ |   
   |_|  |_|\___|\__\__,_|\__,_|\__,_|\__\__,_| .__/|_|\__,_|\__, |\___|_|   
                                             |_|            |___/         
   
   *  Copyright 2010-2024 Institut de Recherche et d'Innovation 
   *  contributor(s) : Karim Hamidou, Samuel Huron, Raphael Velt, Thibaut Cavalie, Yves-Marie Haussonne, Nicolas Durand, Olivier Aubert
   *   
   *  contact@iri.centrepompidou.fr
   *  http://www.iri.centrepompidou.fr 
   *   
   *  This software is a computer program whose purpose is to show and add annotations on a video .
   *  This software is governed by the CeCILL-C license under French law and
   *  abiding by the rules of distribution of free software. You can  use, 
   *  modify and/ or redistribute the software under the terms of the CeCILL-C
   *  license as circulated by CEA, CNRS and INRIA at the following URL
   *  "http://www.cecill.info". 
   *  
   *  The fact that you are presently reading this means that you have had
   *  knowledge of the CeCILL-C license and that you accept its terms.
   *  metadataplayer - version 0.1.1
  */
(function(t,e){typeof exports=="object"&&typeof module<"u"?module.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self,t.MetadataPlayer=e())})(this,function(){"use strict";var $m=Object.defineProperty;var Lm=(t,e,n)=>e in t?$m(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n;var Fi=(t,e,n)=>Lm(t,typeof e!="symbol"?e+"":e,n);const style={},global$1=globalThis||void 0||self;var commonjsGlobal$1=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function getDefaultExportFromCjs$1(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function getAugmentedNamespace(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var n=function o(){return this instanceof o?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};n.prototype=e.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(t).forEach(function(o){var u=Object.getOwnPropertyDescriptor(t,o);Object.defineProperty(n,o,u.get?u:{enumerable:!0,get:function(){return t[o]}})}),n}var jquery={exports:{}};/*!
 * jQuery JavaScript Library v3.7.1
 * https://jquery.com/
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license
 * https://jquery.org/license
 *
 * Date: 2023-08-28T13:37Z
 */(function(t){(function(e,n){t.exports=e.document?n(e,!0):function(o){if(!o.document)throw new Error("jQuery requires a window with a document");return n(o)}})(typeof window<"u"?window:commonjsGlobal$1,function(e,n){var o=[],u=Object.getPrototypeOf,l=o.slice,m=o.flat?function(X){return o.flat.call(X)}:function(X){return o.concat.apply([],X)},y=o.push,E=o.indexOf,C={},k=C.toString,A=C.hasOwnProperty,D=A.toString,P=D.call(Object),R={},B=function(ae){return typeof ae=="function"&&typeof ae.nodeType!="number"&&typeof ae.item!="function"},F=function(ae){return ae!=null&&ae===ae.window},j=e.document,N={type:!0,src:!0,nonce:!0,noModule:!0};function Y(X,ae,Te){Te=Te||j;var Pe,ze,He=Te.createElement("script");if(He.text=X,ae)for(Pe in N)ze=ae[Pe]||ae.getAttribute&&ae.getAttribute(Pe),ze&&He.setAttribute(Pe,ze);Te.head.appendChild(He).parentNode.removeChild(He)}function J(X){return X==null?X+"":typeof X=="object"||typeof X=="function"?C[k.call(X)]||"object":typeof X}var ie="3.7.1",ue=/HTML$/i,Q=function(X,ae){return new Q.fn.init(X,ae)};Q.fn=Q.prototype={jquery:ie,constructor:Q,length:0,toArray:function(){return l.call(this)},get:function(X){return X==null?l.call(this):X<0?this[X+this.length]:this[X]},pushStack:function(X){var ae=Q.merge(this.constructor(),X);return ae.prevObject=this,ae},each:function(X){return Q.each(this,X)},map:function(X){return this.pushStack(Q.map(this,function(ae,Te){return X.call(ae,Te,ae)}))},slice:function(){return this.pushStack(l.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(Q.grep(this,function(X,ae){return(ae+1)%2}))},odd:function(){return this.pushStack(Q.grep(this,function(X,ae){return ae%2}))},eq:function(X){var ae=this.length,Te=+X+(X<0?ae:0);return this.pushStack(Te>=0&&Te<ae?[this[Te]]:[])},end:function(){return this.prevObject||this.constructor()},push:y,sort:o.sort,splice:o.splice},Q.extend=Q.fn.extend=function(){var X,ae,Te,Pe,ze,He,Ze=arguments[0]||{},It=1,St=arguments.length,Kt=!1;for(typeof Ze=="boolean"&&(Kt=Ze,Ze=arguments[It]||{},It++),typeof Ze!="object"&&!B(Ze)&&(Ze={}),It===St&&(Ze=this,It--);It<St;It++)if((X=arguments[It])!=null)for(ae in X)Pe=X[ae],!(ae==="__proto__"||Ze===Pe)&&(Kt&&Pe&&(Q.isPlainObject(Pe)||(ze=Array.isArray(Pe)))?(Te=Ze[ae],ze&&!Array.isArray(Te)?He=[]:!ze&&!Q.isPlainObject(Te)?He={}:He=Te,ze=!1,Ze[ae]=Q.extend(Kt,He,Pe)):Pe!==void 0&&(Ze[ae]=Pe));return Ze},Q.extend({expando:"jQuery"+(ie+Math.random()).replace(/\D/g,""),isReady:!0,error:function(X){throw new Error(X)},noop:function(){},isPlainObject:function(X){var ae,Te;return!X||k.call(X)!=="[object Object]"?!1:(ae=u(X),ae?(Te=A.call(ae,"constructor")&&ae.constructor,typeof Te=="function"&&D.call(Te)===P):!0)},isEmptyObject:function(X){var ae;for(ae in X)return!1;return!0},globalEval:function(X,ae,Te){Y(X,{nonce:ae&&ae.nonce},Te)},each:function(X,ae){var Te,Pe=0;if(ce(X))for(Te=X.length;Pe<Te&&ae.call(X[Pe],Pe,X[Pe])!==!1;Pe++);else for(Pe in X)if(ae.call(X[Pe],Pe,X[Pe])===!1)break;return X},text:function(X){var ae,Te="",Pe=0,ze=X.nodeType;if(!ze)for(;ae=X[Pe++];)Te+=Q.text(ae);return ze===1||ze===11?X.textContent:ze===9?X.documentElement.textContent:ze===3||ze===4?X.nodeValue:Te},makeArray:function(X,ae){var Te=ae||[];return X!=null&&(ce(Object(X))?Q.merge(Te,typeof X=="string"?[X]:X):y.call(Te,X)),Te},inArray:function(X,ae,Te){return ae==null?-1:E.call(ae,X,Te)},isXMLDoc:function(X){var ae=X&&X.namespaceURI,Te=X&&(X.ownerDocument||X).documentElement;return!ue.test(ae||Te&&Te.nodeName||"HTML")},merge:function(X,ae){for(var Te=+ae.length,Pe=0,ze=X.length;Pe<Te;Pe++)X[ze++]=ae[Pe];return X.length=ze,X},grep:function(X,ae,Te){for(var Pe,ze=[],He=0,Ze=X.length,It=!Te;He<Ze;He++)Pe=!ae(X[He],He),Pe!==It&&ze.push(X[He]);return ze},map:function(X,ae,Te){var Pe,ze,He=0,Ze=[];if(ce(X))for(Pe=X.length;He<Pe;He++)ze=ae(X[He],He,Te),ze!=null&&Ze.push(ze);else for(He in X)ze=ae(X[He],He,Te),ze!=null&&Ze.push(ze);return m(Ze)},guid:1,support:R}),typeof Symbol=="function"&&(Q.fn[Symbol.iterator]=o[Symbol.iterator]),Q.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(X,ae){C["[object "+ae+"]"]=ae.toLowerCase()});function ce(X){var ae=!!X&&"length"in X&&X.length,Te=J(X);return B(X)||F(X)?!1:Te==="array"||ae===0||typeof ae=="number"&&ae>0&&ae-1 in X}function he(X,ae){return X.nodeName&&X.nodeName.toLowerCase()===ae.toLowerCase()}var ke=o.pop,L=o.sort,d=o.splice,v="[\\x20\\t\\r\\n\\f]",w=new RegExp("^"+v+"+|((?:^|[^\\\\])(?:\\\\.)*)"+v+"+$","g");Q.contains=function(X,ae){var Te=ae&&ae.parentNode;return X===Te||!!(Te&&Te.nodeType===1&&(X.contains?X.contains(Te):X.compareDocumentPosition&&X.compareDocumentPosition(Te)&16))};var c=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g;function p(X,ae){return ae?X==="\0"?"�":X.slice(0,-1)+"\\"+X.charCodeAt(X.length-1).toString(16)+" ":"\\"+X}Q.escapeSelector=function(X){return(X+"").replace(c,p)};var x=j,S=y;(function(){var X,ae,Te,Pe,ze,He=S,Ze,It,St,Kt,di,bi=Q.expando,ri=0,Ni=0,Ki=da(),yr=da(),fr=da(),jr=da(),Or=function(_t,Ht){return _t===Ht&&(ze=!0),0},Qr="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",Cn="(?:\\\\[\\da-fA-F]{1,6}"+v+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",Tr="\\["+v+"*("+Cn+")(?:"+v+"*([*^$|!~]?=)"+v+`*(?:'((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)"|(`+Cn+"))|)"+v+"*\\]",$n=":("+Cn+`)(?:\\((('((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)")|((?:\\\\.|[^\\\\()[\\]]|`+Tr+")*)|.*)\\)|)",Sr=new RegExp(v+"+","g"),Lr=new RegExp("^"+v+"*,"+v+"*"),wa=new RegExp("^"+v+"*([>+~]|"+v+")"+v+"*"),La=new RegExp(v+"|>"),rn=new RegExp($n),ra=new RegExp("^"+Cn+"$"),un={ID:new RegExp("^#("+Cn+")"),CLASS:new RegExp("^\\.("+Cn+")"),TAG:new RegExp("^("+Cn+"|[*])"),ATTR:new RegExp("^"+Tr),PSEUDO:new RegExp("^"+$n),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+v+"*(even|odd|(([+-]|)(\\d*)n|)"+v+"*(?:([+-]|)"+v+"*(\\d+)|))"+v+"*\\)|)","i"),bool:new RegExp("^(?:"+Qr+")$","i"),needsContext:new RegExp("^"+v+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+v+"*((?:-\\d)?\\d*)"+v+"*\\)|)(?=[^-]|$)","i")},Ln=/^(?:input|select|textarea|button)$/i,Vn=/^h\d$/i,Jr=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ha=/[+~]/,Bn=new RegExp("\\\\[\\da-fA-F]{1,6}"+v+"?|\\\\([^\\r\\n\\f])","g"),An=function(_t,Ht){var ti="0x"+_t.slice(1)-65536;return Ht||(ti<0?String.fromCharCode(ti+65536):String.fromCharCode(ti>>10|55296,ti&1023|56320))},ln=function(){Wn()},Ba=aa(function(_t){return _t.disabled===!0&&he(_t,"fieldset")},{dir:"parentNode",next:"legend"});function Sa(){try{return Ze.activeElement}catch{}}try{He.apply(o=l.call(x.childNodes),x.childNodes),o[x.childNodes.length].nodeType}catch{He={apply:function(Ht,ti){S.apply(Ht,l.call(ti))},call:function(Ht){S.apply(Ht,l.call(arguments,1))}}}function Ir(_t,Ht,ti,ui){var mt,Nt,Bt,_i,Mi,Yi,Xi,Ui=Ht&&Ht.ownerDocument,gr=Ht?Ht.nodeType:9;if(ti=ti||[],typeof _t!="string"||!_t||gr!==1&&gr!==9&&gr!==11)return ti;if(!ui&&(Wn(Ht),Ht=Ht||Ze,St)){if(gr!==11&&(Mi=Jr.exec(_t)))if(mt=Mi[1]){if(gr===9)if(Bt=Ht.getElementById(mt)){if(Bt.id===mt)return He.call(ti,Bt),ti}else return ti;else if(Ui&&(Bt=Ui.getElementById(mt))&&Ir.contains(Ht,Bt)&&Bt.id===mt)return He.call(ti,Bt),ti}else{if(Mi[2])return He.apply(ti,Ht.getElementsByTagName(_t)),ti;if((mt=Mi[3])&&Ht.getElementsByClassName)return He.apply(ti,Ht.getElementsByClassName(mt)),ti}if(!jr[_t+" "]&&(!Kt||!Kt.test(_t))){if(Xi=_t,Ui=Ht,gr===1&&(La.test(_t)||wa.test(_t))){for(Ui=ha.test(_t)&&Ga(Ht.parentNode)||Ht,(Ui!=Ht||!R.scope)&&((_i=Ht.getAttribute("id"))?_i=Q.escapeSelector(_i):Ht.setAttribute("id",_i=bi)),Yi=ma(_t),Nt=Yi.length;Nt--;)Yi[Nt]=(_i?"#"+_i:":scope")+" "+xn(Yi[Nt]);Xi=Yi.join(",")}try{return He.apply(ti,Ui.querySelectorAll(Xi)),ti}catch{jr(_t,!0)}finally{_i===bi&&Ht.removeAttribute("id")}}}return ss(_t.replace(w,"$1"),Ht,ti,ui)}function da(){var _t=[];function Ht(ti,ui){return _t.push(ti+" ")>ae.cacheLength&&delete Ht[_t.shift()],Ht[ti+" "]=ui}return Ht}function _n(_t){return _t[bi]=!0,_t}function na(_t){var Ht=Ze.createElement("fieldset");try{return!!_t(Ht)}catch{return!1}finally{Ht.parentNode&&Ht.parentNode.removeChild(Ht),Ht=null}}function gs(_t){return function(Ht){return he(Ht,"input")&&Ht.type===_t}}function ns(_t){return function(Ht){return(he(Ht,"input")||he(Ht,"button"))&&Ht.type===_t}}function pa(_t){return function(Ht){return"form"in Ht?Ht.parentNode&&Ht.disabled===!1?"label"in Ht?"label"in Ht.parentNode?Ht.parentNode.disabled===_t:Ht.disabled===_t:Ht.isDisabled===_t||Ht.isDisabled!==!_t&&Ba(Ht)===_t:Ht.disabled===_t:"label"in Ht?Ht.disabled===_t:!1}}function cn(_t){return _n(function(Ht){return Ht=+Ht,_n(function(ti,ui){for(var mt,Nt=_t([],ti.length,Ht),Bt=Nt.length;Bt--;)ti[mt=Nt[Bt]]&&(ti[mt]=!(ui[mt]=ti[mt]))})})}function Ga(_t){return _t&&typeof _t.getElementsByTagName<"u"&&_t}function Wn(_t){var Ht,ti=_t?_t.ownerDocument||_t:x;return ti==Ze||ti.nodeType!==9||!ti.documentElement||(Ze=ti,It=Ze.documentElement,St=!Q.isXMLDoc(Ze),di=It.matches||It.webkitMatchesSelector||It.msMatchesSelector,It.msMatchesSelector&&x!=Ze&&(Ht=Ze.defaultView)&&Ht.top!==Ht&&Ht.addEventListener("unload",ln),R.getById=na(function(ui){return It.appendChild(ui).id=Q.expando,!Ze.getElementsByName||!Ze.getElementsByName(Q.expando).length}),R.disconnectedMatch=na(function(ui){return di.call(ui,"*")}),R.scope=na(function(){return Ze.querySelectorAll(":scope")}),R.cssHas=na(function(){try{return Ze.querySelector(":has(*,:jqfake)"),!1}catch{return!0}}),R.getById?(ae.filter.ID=function(ui){var mt=ui.replace(Bn,An);return function(Nt){return Nt.getAttribute("id")===mt}},ae.find.ID=function(ui,mt){if(typeof mt.getElementById<"u"&&St){var Nt=mt.getElementById(ui);return Nt?[Nt]:[]}}):(ae.filter.ID=function(ui){var mt=ui.replace(Bn,An);return function(Nt){var Bt=typeof Nt.getAttributeNode<"u"&&Nt.getAttributeNode("id");return Bt&&Bt.value===mt}},ae.find.ID=function(ui,mt){if(typeof mt.getElementById<"u"&&St){var Nt,Bt,_i,Mi=mt.getElementById(ui);if(Mi){if(Nt=Mi.getAttributeNode("id"),Nt&&Nt.value===ui)return[Mi];for(_i=mt.getElementsByName(ui),Bt=0;Mi=_i[Bt++];)if(Nt=Mi.getAttributeNode("id"),Nt&&Nt.value===ui)return[Mi]}return[]}}),ae.find.TAG=function(ui,mt){return typeof mt.getElementsByTagName<"u"?mt.getElementsByTagName(ui):mt.querySelectorAll(ui)},ae.find.CLASS=function(ui,mt){if(typeof mt.getElementsByClassName<"u"&&St)return mt.getElementsByClassName(ui)},Kt=[],na(function(ui){var mt;It.appendChild(ui).innerHTML="<a id='"+bi+"' href='' disabled='disabled'></a><select id='"+bi+"-\r\\' disabled='disabled'><option selected=''></option></select>",ui.querySelectorAll("[selected]").length||Kt.push("\\["+v+"*(?:value|"+Qr+")"),ui.querySelectorAll("[id~="+bi+"-]").length||Kt.push("~="),ui.querySelectorAll("a#"+bi+"+*").length||Kt.push(".#.+[+~]"),ui.querySelectorAll(":checked").length||Kt.push(":checked"),mt=Ze.createElement("input"),mt.setAttribute("type","hidden"),ui.appendChild(mt).setAttribute("name","D"),It.appendChild(ui).disabled=!0,ui.querySelectorAll(":disabled").length!==2&&Kt.push(":enabled",":disabled"),mt=Ze.createElement("input"),mt.setAttribute("name",""),ui.appendChild(mt),ui.querySelectorAll("[name='']").length||Kt.push("\\["+v+"*name"+v+"*="+v+`*(?:''|"")`)}),R.cssHas||Kt.push(":has"),Kt=Kt.length&&new RegExp(Kt.join("|")),Or=function(ui,mt){if(ui===mt)return ze=!0,0;var Nt=!ui.compareDocumentPosition-!mt.compareDocumentPosition;return Nt||(Nt=(ui.ownerDocument||ui)==(mt.ownerDocument||mt)?ui.compareDocumentPosition(mt):1,Nt&1||!R.sortDetached&&mt.compareDocumentPosition(ui)===Nt?ui===Ze||ui.ownerDocument==x&&Ir.contains(x,ui)?-1:mt===Ze||mt.ownerDocument==x&&Ir.contains(x,mt)?1:Pe?E.call(Pe,ui)-E.call(Pe,mt):0:Nt&4?-1:1)}),Ze}Ir.matches=function(_t,Ht){return Ir(_t,null,null,Ht)},Ir.matchesSelector=function(_t,Ht){if(Wn(_t),St&&!jr[Ht+" "]&&(!Kt||!Kt.test(Ht)))try{var ti=di.call(_t,Ht);if(ti||R.disconnectedMatch||_t.document&&_t.document.nodeType!==11)return ti}catch{jr(Ht,!0)}return Ir(Ht,Ze,null,[_t]).length>0},Ir.contains=function(_t,Ht){return(_t.ownerDocument||_t)!=Ze&&Wn(_t),Q.contains(_t,Ht)},Ir.attr=function(_t,Ht){(_t.ownerDocument||_t)!=Ze&&Wn(_t);var ti=ae.attrHandle[Ht.toLowerCase()],ui=ti&&A.call(ae.attrHandle,Ht.toLowerCase())?ti(_t,Ht,!St):void 0;return ui!==void 0?ui:_t.getAttribute(Ht)},Ir.error=function(_t){throw new Error("Syntax error, unrecognized expression: "+_t)},Q.uniqueSort=function(_t){var Ht,ti=[],ui=0,mt=0;if(ze=!R.sortStable,Pe=!R.sortStable&&l.call(_t,0),L.call(_t,Or),ze){for(;Ht=_t[mt++];)Ht===_t[mt]&&(ui=ti.push(mt));for(;ui--;)d.call(_t,ti[ui],1)}return Pe=null,_t},Q.fn.uniqueSort=function(){return this.pushStack(Q.uniqueSort(l.apply(this)))},ae=Q.expr={cacheLength:50,createPseudo:_n,match:un,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(_t){return _t[1]=_t[1].replace(Bn,An),_t[3]=(_t[3]||_t[4]||_t[5]||"").replace(Bn,An),_t[2]==="~="&&(_t[3]=" "+_t[3]+" "),_t.slice(0,4)},CHILD:function(_t){return _t[1]=_t[1].toLowerCase(),_t[1].slice(0,3)==="nth"?(_t[3]||Ir.error(_t[0]),_t[4]=+(_t[4]?_t[5]+(_t[6]||1):2*(_t[3]==="even"||_t[3]==="odd")),_t[5]=+(_t[7]+_t[8]||_t[3]==="odd")):_t[3]&&Ir.error(_t[0]),_t},PSEUDO:function(_t){var Ht,ti=!_t[6]&&_t[2];return un.CHILD.test(_t[0])?null:(_t[3]?_t[2]=_t[4]||_t[5]||"":ti&&rn.test(ti)&&(Ht=ma(ti,!0))&&(Ht=ti.indexOf(")",ti.length-Ht)-ti.length)&&(_t[0]=_t[0].slice(0,Ht),_t[2]=ti.slice(0,Ht)),_t.slice(0,3))}},filter:{TAG:function(_t){var Ht=_t.replace(Bn,An).toLowerCase();return _t==="*"?function(){return!0}:function(ti){return he(ti,Ht)}},CLASS:function(_t){var Ht=Ki[_t+" "];return Ht||(Ht=new RegExp("(^|"+v+")"+_t+"("+v+"|$)"))&&Ki(_t,function(ti){return Ht.test(typeof ti.className=="string"&&ti.className||typeof ti.getAttribute<"u"&&ti.getAttribute("class")||"")})},ATTR:function(_t,Ht,ti){return function(ui){var mt=Ir.attr(ui,_t);return mt==null?Ht==="!=":Ht?(mt+="",Ht==="="?mt===ti:Ht==="!="?mt!==ti:Ht==="^="?ti&&mt.indexOf(ti)===0:Ht==="*="?ti&&mt.indexOf(ti)>-1:Ht==="$="?ti&&mt.slice(-ti.length)===ti:Ht==="~="?(" "+mt.replace(Sr," ")+" ").indexOf(ti)>-1:Ht==="|="?mt===ti||mt.slice(0,ti.length+1)===ti+"-":!1):!0}},CHILD:function(_t,Ht,ti,ui,mt){var Nt=_t.slice(0,3)!=="nth",Bt=_t.slice(-4)!=="last",_i=Ht==="of-type";return ui===1&&mt===0?function(Mi){return!!Mi.parentNode}:function(Mi,Yi,Xi){var Ui,gr,ar,Er,Hr,Yr=Nt!==Bt?"nextSibling":"previousSibling",Vr=Mi.parentNode,nn=_i&&Mi.nodeName.toLowerCase(),Mn=!Xi&&!_i,vr=!1;if(Vr){if(Nt){for(;Yr;){for(ar=Mi;ar=ar[Yr];)if(_i?he(ar,nn):ar.nodeType===1)return!1;Hr=Yr=_t==="only"&&!Hr&&"nextSibling"}return!0}if(Hr=[Bt?Vr.firstChild:Vr.lastChild],Bt&&Mn){for(gr=Vr[bi]||(Vr[bi]={}),Ui=gr[_t]||[],Er=Ui[0]===ri&&Ui[1],vr=Er&&Ui[2],ar=Er&&Vr.childNodes[Er];ar=++Er&&ar&&ar[Yr]||(vr=Er=0)||Hr.pop();)if(ar.nodeType===1&&++vr&&ar===Mi){gr[_t]=[ri,Er,vr];break}}else if(Mn&&(gr=Mi[bi]||(Mi[bi]={}),Ui=gr[_t]||[],Er=Ui[0]===ri&&Ui[1],vr=Er),vr===!1)for(;(ar=++Er&&ar&&ar[Yr]||(vr=Er=0)||Hr.pop())&&!((_i?he(ar,nn):ar.nodeType===1)&&++vr&&(Mn&&(gr=ar[bi]||(ar[bi]={}),gr[_t]=[ri,vr]),ar===Mi)););return vr-=mt,vr===ui||vr%ui===0&&vr/ui>=0}}},PSEUDO:function(_t,Ht){var ti,ui=ae.pseudos[_t]||ae.setFilters[_t.toLowerCase()]||Ir.error("unsupported pseudo: "+_t);return ui[bi]?ui(Ht):ui.length>1?(ti=[_t,_t,"",Ht],ae.setFilters.hasOwnProperty(_t.toLowerCase())?_n(function(mt,Nt){for(var Bt,_i=ui(mt,Ht),Mi=_i.length;Mi--;)Bt=E.call(mt,_i[Mi]),mt[Bt]=!(Nt[Bt]=_i[Mi])}):function(mt){return ui(mt,0,ti)}):ui}},pseudos:{not:_n(function(_t){var Ht=[],ti=[],ui=Ka(_t.replace(w,"$1"));return ui[bi]?_n(function(mt,Nt,Bt,_i){for(var Mi,Yi=ui(mt,null,_i,[]),Xi=mt.length;Xi--;)(Mi=Yi[Xi])&&(mt[Xi]=!(Nt[Xi]=Mi))}):function(mt,Nt,Bt){return Ht[0]=mt,ui(Ht,null,Bt,ti),Ht[0]=null,!ti.pop()}}),has:_n(function(_t){return function(Ht){return Ir(_t,Ht).length>0}}),contains:_n(function(_t){return _t=_t.replace(Bn,An),function(Ht){return(Ht.textContent||Q.text(Ht)).indexOf(_t)>-1}}),lang:_n(function(_t){return ra.test(_t||"")||Ir.error("unsupported lang: "+_t),_t=_t.replace(Bn,An).toLowerCase(),function(Ht){var ti;do if(ti=St?Ht.lang:Ht.getAttribute("xml:lang")||Ht.getAttribute("lang"))return ti=ti.toLowerCase(),ti===_t||ti.indexOf(_t+"-")===0;while((Ht=Ht.parentNode)&&Ht.nodeType===1);return!1}}),target:function(_t){var Ht=e.location&&e.location.hash;return Ht&&Ht.slice(1)===_t.id},root:function(_t){return _t===It},focus:function(_t){return _t===Sa()&&Ze.hasFocus()&&!!(_t.type||_t.href||~_t.tabIndex)},enabled:pa(!1),disabled:pa(!0),checked:function(_t){return he(_t,"input")&&!!_t.checked||he(_t,"option")&&!!_t.selected},selected:function(_t){return _t.parentNode&&_t.parentNode.selectedIndex,_t.selected===!0},empty:function(_t){for(_t=_t.firstChild;_t;_t=_t.nextSibling)if(_t.nodeType<6)return!1;return!0},parent:function(_t){return!ae.pseudos.empty(_t)},header:function(_t){return Vn.test(_t.nodeName)},input:function(_t){return Ln.test(_t.nodeName)},button:function(_t){return he(_t,"input")&&_t.type==="button"||he(_t,"button")},text:function(_t){var Ht;return he(_t,"input")&&_t.type==="text"&&((Ht=_t.getAttribute("type"))==null||Ht.toLowerCase()==="text")},first:cn(function(){return[0]}),last:cn(function(_t,Ht){return[Ht-1]}),eq:cn(function(_t,Ht,ti){return[ti<0?ti+Ht:ti]}),even:cn(function(_t,Ht){for(var ti=0;ti<Ht;ti+=2)_t.push(ti);return _t}),odd:cn(function(_t,Ht){for(var ti=1;ti<Ht;ti+=2)_t.push(ti);return _t}),lt:cn(function(_t,Ht,ti){var ui;for(ti<0?ui=ti+Ht:ti>Ht?ui=Ht:ui=ti;--ui>=0;)_t.push(ui);return _t}),gt:cn(function(_t,Ht,ti){for(var ui=ti<0?ti+Ht:ti;++ui<Ht;)_t.push(ui);return _t})}},ae.pseudos.nth=ae.pseudos.eq;for(X in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})ae.pseudos[X]=gs(X);for(X in{submit:!0,reset:!0})ae.pseudos[X]=ns(X);function Gn(){}Gn.prototype=ae.filters=ae.pseudos,ae.setFilters=new Gn;function ma(_t,Ht){var ti,ui,mt,Nt,Bt,_i,Mi,Yi=yr[_t+" "];if(Yi)return Ht?0:Yi.slice(0);for(Bt=_t,_i=[],Mi=ae.preFilter;Bt;){(!ti||(ui=Lr.exec(Bt)))&&(ui&&(Bt=Bt.slice(ui[0].length)||Bt),_i.push(mt=[])),ti=!1,(ui=wa.exec(Bt))&&(ti=ui.shift(),mt.push({value:ti,type:ui[0].replace(w," ")}),Bt=Bt.slice(ti.length));for(Nt in ae.filter)(ui=un[Nt].exec(Bt))&&(!Mi[Nt]||(ui=Mi[Nt](ui)))&&(ti=ui.shift(),mt.push({value:ti,type:Nt,matches:ui}),Bt=Bt.slice(ti.length));if(!ti)break}return Ht?Bt.length:Bt?Ir.error(_t):yr(_t,_i).slice(0)}function xn(_t){for(var Ht=0,ti=_t.length,ui="";Ht<ti;Ht++)ui+=_t[Ht].value;return ui}function aa(_t,Ht,ti){var ui=Ht.dir,mt=Ht.next,Nt=mt||ui,Bt=ti&&Nt==="parentNode",_i=Ni++;return Ht.first?function(Mi,Yi,Xi){for(;Mi=Mi[ui];)if(Mi.nodeType===1||Bt)return _t(Mi,Yi,Xi);return!1}:function(Mi,Yi,Xi){var Ui,gr,ar=[ri,_i];if(Xi){for(;Mi=Mi[ui];)if((Mi.nodeType===1||Bt)&&_t(Mi,Yi,Xi))return!0}else for(;Mi=Mi[ui];)if(Mi.nodeType===1||Bt)if(gr=Mi[bi]||(Mi[bi]={}),mt&&he(Mi,mt))Mi=Mi[ui]||Mi;else{if((Ui=gr[Nt])&&Ui[0]===ri&&Ui[1]===_i)return ar[2]=Ui[2];if(gr[Nt]=ar,ar[2]=_t(Mi,Yi,Xi))return!0}return!1}}function Oa(_t){return _t.length>1?function(Ht,ti,ui){for(var mt=_t.length;mt--;)if(!_t[mt](Ht,ti,ui))return!1;return!0}:_t[0]}function vs(_t,Ht,ti){for(var ui=0,mt=Ht.length;ui<mt;ui++)Ir(_t,Ht[ui],ti);return ti}function ja(_t,Ht,ti,ui,mt){for(var Nt,Bt=[],_i=0,Mi=_t.length,Yi=Ht!=null;_i<Mi;_i++)(Nt=_t[_i])&&(!ti||ti(Nt,ui,mt))&&(Bt.push(Nt),Yi&&Ht.push(_i));return Bt}function Kn(_t,Ht,ti,ui,mt,Nt){return ui&&!ui[bi]&&(ui=Kn(ui)),mt&&!mt[bi]&&(mt=Kn(mt,Nt)),_n(function(Bt,_i,Mi,Yi){var Xi,Ui,gr,ar,Er=[],Hr=[],Yr=_i.length,Vr=Bt||vs(Ht||"*",Mi.nodeType?[Mi]:Mi,[]),nn=_t&&(Bt||!Ht)?ja(Vr,Er,_t,Mi,Yi):Vr;if(ti?(ar=mt||(Bt?_t:Yr||ui)?[]:_i,ti(nn,ar,Mi,Yi)):ar=nn,ui)for(Xi=ja(ar,Hr),ui(Xi,[],Mi,Yi),Ui=Xi.length;Ui--;)(gr=Xi[Ui])&&(ar[Hr[Ui]]=!(nn[Hr[Ui]]=gr));if(Bt){if(mt||_t){if(mt){for(Xi=[],Ui=ar.length;Ui--;)(gr=ar[Ui])&&Xi.push(nn[Ui]=gr);mt(null,ar=[],Xi,Yi)}for(Ui=ar.length;Ui--;)(gr=ar[Ui])&&(Xi=mt?E.call(Bt,gr):Er[Ui])>-1&&(Bt[Xi]=!(_i[Xi]=gr))}}else ar=ja(ar===_i?ar.splice(Yr,ar.length):ar),mt?mt(null,_i,ar,Yi):He.apply(_i,ar)})}function fn(_t){for(var Ht,ti,ui,mt=_t.length,Nt=ae.relative[_t[0].type],Bt=Nt||ae.relative[" "],_i=Nt?1:0,Mi=aa(function(Ui){return Ui===Ht},Bt,!0),Yi=aa(function(Ui){return E.call(Ht,Ui)>-1},Bt,!0),Xi=[function(Ui,gr,ar){var Er=!Nt&&(ar||gr!=Te)||((Ht=gr).nodeType?Mi(Ui,gr,ar):Yi(Ui,gr,ar));return Ht=null,Er}];_i<mt;_i++)if(ti=ae.relative[_t[_i].type])Xi=[aa(Oa(Xi),ti)];else{if(ti=ae.filter[_t[_i].type].apply(null,_t[_i].matches),ti[bi]){for(ui=++_i;ui<mt&&!ae.relative[_t[ui].type];ui++);return Kn(_i>1&&Oa(Xi),_i>1&&xn(_t.slice(0,_i-1).concat({value:_t[_i-2].type===" "?"*":""})).replace(w,"$1"),ti,_i<ui&&fn(_t.slice(_i,ui)),ui<mt&&fn(_t=_t.slice(ui)),ui<mt&&xn(_t))}Xi.push(ti)}return Oa(Xi)}function as(_t,Ht){var ti=Ht.length>0,ui=_t.length>0,mt=function(Nt,Bt,_i,Mi,Yi){var Xi,Ui,gr,ar=0,Er="0",Hr=Nt&&[],Yr=[],Vr=Te,nn=Nt||ui&&ae.find.TAG("*",Yi),Mn=ri+=Vr==null?1:Math.random()||.1,vr=nn.length;for(Yi&&(Te=Bt==Ze||Bt||Yi);Er!==vr&&(Xi=nn[Er])!=null;Er++){if(ui&&Xi){for(Ui=0,!Bt&&Xi.ownerDocument!=Ze&&(Wn(Xi),_i=!St);gr=_t[Ui++];)if(gr(Xi,Bt||Ze,_i)){He.call(Mi,Xi);break}Yi&&(ri=Mn)}ti&&((Xi=!gr&&Xi)&&ar--,Nt&&Hr.push(Xi))}if(ar+=Er,ti&&Er!==ar){for(Ui=0;gr=Ht[Ui++];)gr(Hr,Yr,Bt,_i);if(Nt){if(ar>0)for(;Er--;)Hr[Er]||Yr[Er]||(Yr[Er]=ke.call(Mi));Yr=ja(Yr)}He.apply(Mi,Yr),Yi&&!Nt&&Yr.length>0&&ar+Ht.length>1&&Q.uniqueSort(Mi)}return Yi&&(ri=Mn,Te=Vr),Hr};return ti?_n(mt):mt}function Ka(_t,Ht){var ti,ui=[],mt=[],Nt=fr[_t+" "];if(!Nt){for(Ht||(Ht=ma(_t)),ti=Ht.length;ti--;)Nt=fn(Ht[ti]),Nt[bi]?ui.push(Nt):mt.push(Nt);Nt=fr(_t,as(mt,ui)),Nt.selector=_t}return Nt}function ss(_t,Ht,ti,ui){var mt,Nt,Bt,_i,Mi,Yi=typeof _t=="function"&&_t,Xi=!ui&&ma(_t=Yi.selector||_t);if(ti=ti||[],Xi.length===1){if(Nt=Xi[0]=Xi[0].slice(0),Nt.length>2&&(Bt=Nt[0]).type==="ID"&&Ht.nodeType===9&&St&&ae.relative[Nt[1].type]){if(Ht=(ae.find.ID(Bt.matches[0].replace(Bn,An),Ht)||[])[0],Ht)Yi&&(Ht=Ht.parentNode);else return ti;_t=_t.slice(Nt.shift().value.length)}for(mt=un.needsContext.test(_t)?0:Nt.length;mt--&&(Bt=Nt[mt],!ae.relative[_i=Bt.type]);)if((Mi=ae.find[_i])&&(ui=Mi(Bt.matches[0].replace(Bn,An),ha.test(Nt[0].type)&&Ga(Ht.parentNode)||Ht))){if(Nt.splice(mt,1),_t=ui.length&&xn(Nt),!_t)return He.apply(ti,ui),ti;break}}return(Yi||Ka(_t,Xi))(ui,Ht,!St,ti,!Ht||ha.test(_t)&&Ga(Ht.parentNode)||Ht),ti}R.sortStable=bi.split("").sort(Or).join("")===bi,Wn(),R.sortDetached=na(function(_t){return _t.compareDocumentPosition(Ze.createElement("fieldset"))&1}),Q.find=Ir,Q.expr[":"]=Q.expr.pseudos,Q.unique=Q.uniqueSort,Ir.compile=Ka,Ir.select=ss,Ir.setDocument=Wn,Ir.tokenize=ma,Ir.escape=Q.escapeSelector,Ir.getText=Q.text,Ir.isXML=Q.isXMLDoc,Ir.selectors=Q.expr,Ir.support=Q.support,Ir.uniqueSort=Q.uniqueSort})();var b=function(X,ae,Te){for(var Pe=[],ze=Te!==void 0;(X=X[ae])&&X.nodeType!==9;)if(X.nodeType===1){if(ze&&Q(X).is(Te))break;Pe.push(X)}return Pe},h=function(X,ae){for(var Te=[];X;X=X.nextSibling)X.nodeType===1&&X!==ae&&Te.push(X);return Te},T=Q.expr.match.needsContext,M=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function O(X,ae,Te){return B(ae)?Q.grep(X,function(Pe,ze){return!!ae.call(Pe,ze,Pe)!==Te}):ae.nodeType?Q.grep(X,function(Pe){return Pe===ae!==Te}):typeof ae!="string"?Q.grep(X,function(Pe){return E.call(ae,Pe)>-1!==Te}):Q.filter(ae,X,Te)}Q.filter=function(X,ae,Te){var Pe=ae[0];return Te&&(X=":not("+X+")"),ae.length===1&&Pe.nodeType===1?Q.find.matchesSelector(Pe,X)?[Pe]:[]:Q.find.matches(X,Q.grep(ae,function(ze){return ze.nodeType===1}))},Q.fn.extend({find:function(X){var ae,Te,Pe=this.length,ze=this;if(typeof X!="string")return this.pushStack(Q(X).filter(function(){for(ae=0;ae<Pe;ae++)if(Q.contains(ze[ae],this))return!0}));for(Te=this.pushStack([]),ae=0;ae<Pe;ae++)Q.find(X,ze[ae],Te);return Pe>1?Q.uniqueSort(Te):Te},filter:function(X){return this.pushStack(O(this,X||[],!1))},not:function(X){return this.pushStack(O(this,X||[],!0))},is:function(X){return!!O(this,typeof X=="string"&&T.test(X)?Q(X):X||[],!1).length}});var V,ee=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/,Z=Q.fn.init=function(X,ae,Te){var Pe,ze;if(!X)return this;if(Te=Te||V,typeof X=="string")if(X[0]==="<"&&X[X.length-1]===">"&&X.length>=3?Pe=[null,X,null]:Pe=ee.exec(X),Pe&&(Pe[1]||!ae))if(Pe[1]){if(ae=ae instanceof Q?ae[0]:ae,Q.merge(this,Q.parseHTML(Pe[1],ae&&ae.nodeType?ae.ownerDocument||ae:j,!0)),M.test(Pe[1])&&Q.isPlainObject(ae))for(Pe in ae)B(this[Pe])?this[Pe](ae[Pe]):this.attr(Pe,ae[Pe]);return this}else return ze=j.getElementById(Pe[2]),ze&&(this[0]=ze,this.length=1),this;else return!ae||ae.jquery?(ae||Te).find(X):this.constructor(ae).find(X);else{if(X.nodeType)return this[0]=X,this.length=1,this;if(B(X))return Te.ready!==void 0?Te.ready(X):X(Q)}return Q.makeArray(X,this)};Z.prototype=Q.fn,V=Q(j);var U=/^(?:parents|prev(?:Until|All))/,z={children:!0,contents:!0,next:!0,prev:!0};Q.fn.extend({has:function(X){var ae=Q(X,this),Te=ae.length;return this.filter(function(){for(var Pe=0;Pe<Te;Pe++)if(Q.contains(this,ae[Pe]))return!0})},closest:function(X,ae){var Te,Pe=0,ze=this.length,He=[],Ze=typeof X!="string"&&Q(X);if(!T.test(X)){for(;Pe<ze;Pe++)for(Te=this[Pe];Te&&Te!==ae;Te=Te.parentNode)if(Te.nodeType<11&&(Ze?Ze.index(Te)>-1:Te.nodeType===1&&Q.find.matchesSelector(Te,X))){He.push(Te);break}}return this.pushStack(He.length>1?Q.uniqueSort(He):He)},index:function(X){return X?typeof X=="string"?E.call(Q(X),this[0]):E.call(this,X.jquery?X[0]:X):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(X,ae){return this.pushStack(Q.uniqueSort(Q.merge(this.get(),Q(X,ae))))},addBack:function(X){return this.add(X==null?this.prevObject:this.prevObject.filter(X))}});function ne(X,ae){for(;(X=X[ae])&&X.nodeType!==1;);return X}Q.each({parent:function(X){var ae=X.parentNode;return ae&&ae.nodeType!==11?ae:null},parents:function(X){return b(X,"parentNode")},parentsUntil:function(X,ae,Te){return b(X,"parentNode",Te)},next:function(X){return ne(X,"nextSibling")},prev:function(X){return ne(X,"previousSibling")},nextAll:function(X){return b(X,"nextSibling")},prevAll:function(X){return b(X,"previousSibling")},nextUntil:function(X,ae,Te){return b(X,"nextSibling",Te)},prevUntil:function(X,ae,Te){return b(X,"previousSibling",Te)},siblings:function(X){return h((X.parentNode||{}).firstChild,X)},children:function(X){return h(X.firstChild)},contents:function(X){return X.contentDocument!=null&&u(X.contentDocument)?X.contentDocument:(he(X,"template")&&(X=X.content||X),Q.merge([],X.childNodes))}},function(X,ae){Q.fn[X]=function(Te,Pe){var ze=Q.map(this,ae,Te);return X.slice(-5)!=="Until"&&(Pe=Te),Pe&&typeof Pe=="string"&&(ze=Q.filter(Pe,ze)),this.length>1&&(z[X]||Q.uniqueSort(ze),U.test(X)&&ze.reverse()),this.pushStack(ze)}});var fe=/[^\x20\t\r\n\f]+/g;function me(X){var ae={};return Q.each(X.match(fe)||[],function(Te,Pe){ae[Pe]=!0}),ae}Q.Callbacks=function(X){X=typeof X=="string"?me(X):Q.extend({},X);var ae,Te,Pe,ze,He=[],Ze=[],It=-1,St=function(){for(ze=ze||X.once,Pe=ae=!0;Ze.length;It=-1)for(Te=Ze.shift();++It<He.length;)He[It].apply(Te[0],Te[1])===!1&&X.stopOnFalse&&(It=He.length,Te=!1);X.memory||(Te=!1),ae=!1,ze&&(Te?He=[]:He="")},Kt={add:function(){return He&&(Te&&!ae&&(It=He.length-1,Ze.push(Te)),function di(bi){Q.each(bi,function(ri,Ni){B(Ni)?(!X.unique||!Kt.has(Ni))&&He.push(Ni):Ni&&Ni.length&&J(Ni)!=="string"&&di(Ni)})}(arguments),Te&&!ae&&St()),this},remove:function(){return Q.each(arguments,function(di,bi){for(var ri;(ri=Q.inArray(bi,He,ri))>-1;)He.splice(ri,1),ri<=It&&It--}),this},has:function(di){return di?Q.inArray(di,He)>-1:He.length>0},empty:function(){return He&&(He=[]),this},disable:function(){return ze=Ze=[],He=Te="",this},disabled:function(){return!He},lock:function(){return ze=Ze=[],!Te&&!ae&&(He=Te=""),this},locked:function(){return!!ze},fireWith:function(di,bi){return ze||(bi=bi||[],bi=[di,bi.slice?bi.slice():bi],Ze.push(bi),ae||St()),this},fire:function(){return Kt.fireWith(this,arguments),this},fired:function(){return!!Pe}};return Kt};function de(X){return X}function je(X){throw X}function lt(X,ae,Te,Pe){var ze;try{X&&B(ze=X.promise)?ze.call(X).done(ae).fail(Te):X&&B(ze=X.then)?ze.call(X,ae,Te):ae.apply(void 0,[X].slice(Pe))}catch(He){Te.apply(void 0,[He])}}Q.extend({Deferred:function(X){var ae=[["notify","progress",Q.Callbacks("memory"),Q.Callbacks("memory"),2],["resolve","done",Q.Callbacks("once memory"),Q.Callbacks("once memory"),0,"resolved"],["reject","fail",Q.Callbacks("once memory"),Q.Callbacks("once memory"),1,"rejected"]],Te="pending",Pe={state:function(){return Te},always:function(){return ze.done(arguments).fail(arguments),this},catch:function(He){return Pe.then(null,He)},pipe:function(){var He=arguments;return Q.Deferred(function(Ze){Q.each(ae,function(It,St){var Kt=B(He[St[4]])&&He[St[4]];ze[St[1]](function(){var di=Kt&&Kt.apply(this,arguments);di&&B(di.promise)?di.promise().progress(Ze.notify).done(Ze.resolve).fail(Ze.reject):Ze[St[0]+"With"](this,Kt?[di]:arguments)})}),He=null}).promise()},then:function(He,Ze,It){var St=0;function Kt(di,bi,ri,Ni){return function(){var Ki=this,yr=arguments,fr=function(){var Or,Qr;if(!(di<St)){if(Or=ri.apply(Ki,yr),Or===bi.promise())throw new TypeError("Thenable self-resolution");Qr=Or&&(typeof Or=="object"||typeof Or=="function")&&Or.then,B(Qr)?Ni?Qr.call(Or,Kt(St,bi,de,Ni),Kt(St,bi,je,Ni)):(St++,Qr.call(Or,Kt(St,bi,de,Ni),Kt(St,bi,je,Ni),Kt(St,bi,de,bi.notifyWith))):(ri!==de&&(Ki=void 0,yr=[Or]),(Ni||bi.resolveWith)(Ki,yr))}},jr=Ni?fr:function(){try{fr()}catch(Or){Q.Deferred.exceptionHook&&Q.Deferred.exceptionHook(Or,jr.error),di+1>=St&&(ri!==je&&(Ki=void 0,yr=[Or]),bi.rejectWith(Ki,yr))}};di?jr():(Q.Deferred.getErrorHook?jr.error=Q.Deferred.getErrorHook():Q.Deferred.getStackHook&&(jr.error=Q.Deferred.getStackHook()),e.setTimeout(jr))}}return Q.Deferred(function(di){ae[0][3].add(Kt(0,di,B(It)?It:de,di.notifyWith)),ae[1][3].add(Kt(0,di,B(He)?He:de)),ae[2][3].add(Kt(0,di,B(Ze)?Ze:je))}).promise()},promise:function(He){return He!=null?Q.extend(He,Pe):Pe}},ze={};return Q.each(ae,function(He,Ze){var It=Ze[2],St=Ze[5];Pe[Ze[1]]=It.add,St&&It.add(function(){Te=St},ae[3-He][2].disable,ae[3-He][3].disable,ae[0][2].lock,ae[0][3].lock),It.add(Ze[3].fire),ze[Ze[0]]=function(){return ze[Ze[0]+"With"](this===ze?void 0:this,arguments),this},ze[Ze[0]+"With"]=It.fireWith}),Pe.promise(ze),X&&X.call(ze,ze),ze},when:function(X){var ae=arguments.length,Te=ae,Pe=Array(Te),ze=l.call(arguments),He=Q.Deferred(),Ze=function(It){return function(St){Pe[It]=this,ze[It]=arguments.length>1?l.call(arguments):St,--ae||He.resolveWith(Pe,ze)}};if(ae<=1&&(lt(X,He.done(Ze(Te)).resolve,He.reject,!ae),He.state()==="pending"||B(ze[Te]&&ze[Te].then)))return He.then();for(;Te--;)lt(ze[Te],Ze(Te),He.reject);return He.promise()}});var it=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;Q.Deferred.exceptionHook=function(X,ae){e.console&&e.console.warn&&X&&it.test(X.name)&&e.console.warn("jQuery.Deferred exception: "+X.message,X.stack,ae)},Q.readyException=function(X){e.setTimeout(function(){throw X})};var ot=Q.Deferred();Q.fn.ready=function(X){return ot.then(X).catch(function(ae){Q.readyException(ae)}),this},Q.extend({isReady:!1,readyWait:1,ready:function(X){(X===!0?--Q.readyWait:Q.isReady)||(Q.isReady=!0,!(X!==!0&&--Q.readyWait>0)&&ot.resolveWith(j,[Q]))}}),Q.ready.then=ot.then;function Ct(){j.removeEventListener("DOMContentLoaded",Ct),e.removeEventListener("load",Ct),Q.ready()}j.readyState==="complete"||j.readyState!=="loading"&&!j.documentElement.doScroll?e.setTimeout(Q.ready):(j.addEventListener("DOMContentLoaded",Ct),e.addEventListener("load",Ct));var nt=function(X,ae,Te,Pe,ze,He,Ze){var It=0,St=X.length,Kt=Te==null;if(J(Te)==="object"){ze=!0;for(It in Te)nt(X,ae,It,Te[It],!0,He,Ze)}else if(Pe!==void 0&&(ze=!0,B(Pe)||(Ze=!0),Kt&&(Ze?(ae.call(X,Pe),ae=null):(Kt=ae,ae=function(di,bi,ri){return Kt.call(Q(di),ri)})),ae))for(;It<St;It++)ae(X[It],Te,Ze?Pe:Pe.call(X[It],It,ae(X[It],Te)));return ze?X:Kt?ae.call(X):St?ae(X[0],Te):He},Je=/^-ms-/,tt=/-([a-z])/g;function rt(X,ae){return ae.toUpperCase()}function ht(X){return X.replace(Je,"ms-").replace(tt,rt)}var Ot=function(X){return X.nodeType===1||X.nodeType===9||!+X.nodeType};function Ve(){this.expando=Q.expando+Ve.uid++}Ve.uid=1,Ve.prototype={cache:function(X){var ae=X[this.expando];return ae||(ae={},Ot(X)&&(X.nodeType?X[this.expando]=ae:Object.defineProperty(X,this.expando,{value:ae,configurable:!0}))),ae},set:function(X,ae,Te){var Pe,ze=this.cache(X);if(typeof ae=="string")ze[ht(ae)]=Te;else for(Pe in ae)ze[ht(Pe)]=ae[Pe];return ze},get:function(X,ae){return ae===void 0?this.cache(X):X[this.expando]&&X[this.expando][ht(ae)]},access:function(X,ae,Te){return ae===void 0||ae&&typeof ae=="string"&&Te===void 0?this.get(X,ae):(this.set(X,ae,Te),Te!==void 0?Te:ae)},remove:function(X,ae){var Te,Pe=X[this.expando];if(Pe!==void 0){if(ae!==void 0)for(Array.isArray(ae)?ae=ae.map(ht):(ae=ht(ae),ae=ae in Pe?[ae]:ae.match(fe)||[]),Te=ae.length;Te--;)delete Pe[ae[Te]];(ae===void 0||Q.isEmptyObject(Pe))&&(X.nodeType?X[this.expando]=void 0:delete X[this.expando])}},hasData:function(X){var ae=X[this.expando];return ae!==void 0&&!Q.isEmptyObject(ae)}};var We=new Ve,Gt=new Ve,wt=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Et=/[A-Z]/g;function Yt(X){return X==="true"?!0:X==="false"?!1:X==="null"?null:X===+X+""?+X:wt.test(X)?JSON.parse(X):X}function Ce(X,ae,Te){var Pe;if(Te===void 0&&X.nodeType===1)if(Pe="data-"+ae.replace(Et,"-$&").toLowerCase(),Te=X.getAttribute(Pe),typeof Te=="string"){try{Te=Yt(Te)}catch{}Gt.set(X,ae,Te)}else Te=void 0;return Te}Q.extend({hasData:function(X){return Gt.hasData(X)||We.hasData(X)},data:function(X,ae,Te){return Gt.access(X,ae,Te)},removeData:function(X,ae){Gt.remove(X,ae)},_data:function(X,ae,Te){return We.access(X,ae,Te)},_removeData:function(X,ae){We.remove(X,ae)}}),Q.fn.extend({data:function(X,ae){var Te,Pe,ze,He=this[0],Ze=He&&He.attributes;if(X===void 0){if(this.length&&(ze=Gt.get(He),He.nodeType===1&&!We.get(He,"hasDataAttrs"))){for(Te=Ze.length;Te--;)Ze[Te]&&(Pe=Ze[Te].name,Pe.indexOf("data-")===0&&(Pe=ht(Pe.slice(5)),Ce(He,Pe,ze[Pe])));We.set(He,"hasDataAttrs",!0)}return ze}return typeof X=="object"?this.each(function(){Gt.set(this,X)}):nt(this,function(It){var St;if(He&&It===void 0)return St=Gt.get(He,X),St!==void 0||(St=Ce(He,X),St!==void 0)?St:void 0;this.each(function(){Gt.set(this,X,It)})},null,ae,arguments.length>1,null,!0)},removeData:function(X){return this.each(function(){Gt.remove(this,X)})}}),Q.extend({queue:function(X,ae,Te){var Pe;if(X)return ae=(ae||"fx")+"queue",Pe=We.get(X,ae),Te&&(!Pe||Array.isArray(Te)?Pe=We.access(X,ae,Q.makeArray(Te)):Pe.push(Te)),Pe||[]},dequeue:function(X,ae){ae=ae||"fx";var Te=Q.queue(X,ae),Pe=Te.length,ze=Te.shift(),He=Q._queueHooks(X,ae),Ze=function(){Q.dequeue(X,ae)};ze==="inprogress"&&(ze=Te.shift(),Pe--),ze&&(ae==="fx"&&Te.unshift("inprogress"),delete He.stop,ze.call(X,Ze,He)),!Pe&&He&&He.empty.fire()},_queueHooks:function(X,ae){var Te=ae+"queueHooks";return We.get(X,Te)||We.access(X,Te,{empty:Q.Callbacks("once memory").add(function(){We.remove(X,[ae+"queue",Te])})})}}),Q.fn.extend({queue:function(X,ae){var Te=2;return typeof X!="string"&&(ae=X,X="fx",Te--),arguments.length<Te?Q.queue(this[0],X):ae===void 0?this:this.each(function(){var Pe=Q.queue(this,X,ae);Q._queueHooks(this,X),X==="fx"&&Pe[0]!=="inprogress"&&Q.dequeue(this,X)})},dequeue:function(X){return this.each(function(){Q.dequeue(this,X)})},clearQueue:function(X){return this.queue(X||"fx",[])},promise:function(X,ae){var Te,Pe=1,ze=Q.Deferred(),He=this,Ze=this.length,It=function(){--Pe||ze.resolveWith(He,[He])};for(typeof X!="string"&&(ae=X,X=void 0),X=X||"fx";Ze--;)Te=We.get(He[Ze],X+"queueHooks"),Te&&Te.empty&&(Pe++,Te.empty.add(It));return It(),ze.promise(ae)}});var te=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,ye=new RegExp("^(?:([+-])=|)("+te+")([a-z%]*)$","i"),Le=["Top","Right","Bottom","Left"],Ue=j.documentElement,Qe=function(X){return Q.contains(X.ownerDocument,X)},Ke={composed:!0};Ue.getRootNode&&(Qe=function(X){return Q.contains(X.ownerDocument,X)||X.getRootNode(Ke)===X.ownerDocument});var De=function(X,ae){return X=ae||X,X.style.display==="none"||X.style.display===""&&Qe(X)&&Q.css(X,"display")==="none"};function Vt(X,ae,Te,Pe){var ze,He,Ze=20,It=Pe?function(){return Pe.cur()}:function(){return Q.css(X,ae,"")},St=It(),Kt=Te&&Te[3]||(Q.cssNumber[ae]?"":"px"),di=X.nodeType&&(Q.cssNumber[ae]||Kt!=="px"&&+St)&&ye.exec(Q.css(X,ae));if(di&&di[3]!==Kt){for(St=St/2,Kt=Kt||di[3],di=+St||1;Ze--;)Q.style(X,ae,di+Kt),(1-He)*(1-(He=It()/St||.5))<=0&&(Ze=0),di=di/He;di=di*2,Q.style(X,ae,di+Kt),Te=Te||[]}return Te&&(di=+di||+St||0,ze=Te[1]?di+(Te[1]+1)*Te[2]:+Te[2],Pe&&(Pe.unit=Kt,Pe.start=di,Pe.end=ze)),ze}var At={};function ve(X){var ae,Te=X.ownerDocument,Pe=X.nodeName,ze=At[Pe];return ze||(ae=Te.body.appendChild(Te.createElement(Pe)),ze=Q.css(ae,"display"),ae.parentNode.removeChild(ae),ze==="none"&&(ze="block"),At[Pe]=ze,ze)}function Pt(X,ae){for(var Te,Pe,ze=[],He=0,Ze=X.length;He<Ze;He++)Pe=X[He],Pe.style&&(Te=Pe.style.display,ae?(Te==="none"&&(ze[He]=We.get(Pe,"display")||null,ze[He]||(Pe.style.display="")),Pe.style.display===""&&De(Pe)&&(ze[He]=ve(Pe))):Te!=="none"&&(ze[He]="none",We.set(Pe,"display",Te)));for(He=0;He<Ze;He++)ze[He]!=null&&(X[He].style.display=ze[He]);return X}Q.fn.extend({show:function(){return Pt(this,!0)},hide:function(){return Pt(this)},toggle:function(X){return typeof X=="boolean"?X?this.show():this.hide():this.each(function(){De(this)?Q(this).show():Q(this).hide()})}});var pt=/^(?:checkbox|radio)$/i,Ne=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,vt=/^$|^module$|\/(?:java|ecma)script/i;(function(){var X=j.createDocumentFragment(),ae=X.appendChild(j.createElement("div")),Te=j.createElement("input");Te.setAttribute("type","radio"),Te.setAttribute("checked","checked"),Te.setAttribute("name","t"),ae.appendChild(Te),R.checkClone=ae.cloneNode(!0).cloneNode(!0).lastChild.checked,ae.innerHTML="<textarea>x</textarea>",R.noCloneChecked=!!ae.cloneNode(!0).lastChild.defaultValue,ae.innerHTML="<option></option>",R.option=!!ae.lastChild})();var ut={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ut.tbody=ut.tfoot=ut.colgroup=ut.caption=ut.thead,ut.th=ut.td,R.option||(ut.optgroup=ut.option=[1,"<select multiple='multiple'>","</select>"]);function $t(X,ae){var Te;return typeof X.getElementsByTagName<"u"?Te=X.getElementsByTagName(ae||"*"):typeof X.querySelectorAll<"u"?Te=X.querySelectorAll(ae||"*"):Te=[],ae===void 0||ae&&he(X,ae)?Q.merge([X],Te):Te}function fi(X,ae){for(var Te=0,Pe=X.length;Te<Pe;Te++)We.set(X[Te],"globalEval",!ae||We.get(ae[Te],"globalEval"))}var kt=/<|&#?\w+;/;function Wt(X,ae,Te,Pe,ze){for(var He,Ze,It,St,Kt,di,bi=ae.createDocumentFragment(),ri=[],Ni=0,Ki=X.length;Ni<Ki;Ni++)if(He=X[Ni],He||He===0)if(J(He)==="object")Q.merge(ri,He.nodeType?[He]:He);else if(!kt.test(He))ri.push(ae.createTextNode(He));else{for(Ze=Ze||bi.appendChild(ae.createElement("div")),It=(Ne.exec(He)||["",""])[1].toLowerCase(),St=ut[It]||ut._default,Ze.innerHTML=St[1]+Q.htmlPrefilter(He)+St[2],di=St[0];di--;)Ze=Ze.lastChild;Q.merge(ri,Ze.childNodes),Ze=bi.firstChild,Ze.textContent=""}for(bi.textContent="",Ni=0;He=ri[Ni++];){if(Pe&&Q.inArray(He,Pe)>-1){ze&&ze.push(He);continue}if(Kt=Qe(He),Ze=$t(bi.appendChild(He),"script"),Kt&&fi(Ze),Te)for(di=0;He=Ze[di++];)vt.test(He.type||"")&&Te.push(He)}return bi}var Zi=/^([^.]*)(?:\.(.+)|)/;function Ut(){return!0}function Xt(){return!1}function Be(X,ae,Te,Pe,ze,He){var Ze,It;if(typeof ae=="object"){typeof Te!="string"&&(Pe=Pe||Te,Te=void 0);for(It in ae)Be(X,It,Te,Pe,ae[It],He);return X}if(Pe==null&&ze==null?(ze=Te,Pe=Te=void 0):ze==null&&(typeof Te=="string"?(ze=Pe,Pe=void 0):(ze=Pe,Pe=Te,Te=void 0)),ze===!1)ze=Xt;else if(!ze)return X;return He===1&&(Ze=ze,ze=function(St){return Q().off(St),Ze.apply(this,arguments)},ze.guid=Ze.guid||(Ze.guid=Q.guid++)),X.each(function(){Q.event.add(this,ae,ze,Pe,Te)})}Q.event={global:{},add:function(X,ae,Te,Pe,ze){var He,Ze,It,St,Kt,di,bi,ri,Ni,Ki,yr,fr=We.get(X);if(Ot(X))for(Te.handler&&(He=Te,Te=He.handler,ze=He.selector),ze&&Q.find.matchesSelector(Ue,ze),Te.guid||(Te.guid=Q.guid++),(St=fr.events)||(St=fr.events=Object.create(null)),(Ze=fr.handle)||(Ze=fr.handle=function(jr){return typeof Q<"u"&&Q.event.triggered!==jr.type?Q.event.dispatch.apply(X,arguments):void 0}),ae=(ae||"").match(fe)||[""],Kt=ae.length;Kt--;)It=Zi.exec(ae[Kt])||[],Ni=yr=It[1],Ki=(It[2]||"").split(".").sort(),Ni&&(bi=Q.event.special[Ni]||{},Ni=(ze?bi.delegateType:bi.bindType)||Ni,bi=Q.event.special[Ni]||{},di=Q.extend({type:Ni,origType:yr,data:Pe,handler:Te,guid:Te.guid,selector:ze,needsContext:ze&&Q.expr.match.needsContext.test(ze),namespace:Ki.join(".")},He),(ri=St[Ni])||(ri=St[Ni]=[],ri.delegateCount=0,(!bi.setup||bi.setup.call(X,Pe,Ki,Ze)===!1)&&X.addEventListener&&X.addEventListener(Ni,Ze)),bi.add&&(bi.add.call(X,di),di.handler.guid||(di.handler.guid=Te.guid)),ze?ri.splice(ri.delegateCount++,0,di):ri.push(di),Q.event.global[Ni]=!0)},remove:function(X,ae,Te,Pe,ze){var He,Ze,It,St,Kt,di,bi,ri,Ni,Ki,yr,fr=We.hasData(X)&&We.get(X);if(!(!fr||!(St=fr.events))){for(ae=(ae||"").match(fe)||[""],Kt=ae.length;Kt--;){if(It=Zi.exec(ae[Kt])||[],Ni=yr=It[1],Ki=(It[2]||"").split(".").sort(),!Ni){for(Ni in St)Q.event.remove(X,Ni+ae[Kt],Te,Pe,!0);continue}for(bi=Q.event.special[Ni]||{},Ni=(Pe?bi.delegateType:bi.bindType)||Ni,ri=St[Ni]||[],It=It[2]&&new RegExp("(^|\\.)"+Ki.join("\\.(?:.*\\.|)")+"(\\.|$)"),Ze=He=ri.length;He--;)di=ri[He],(ze||yr===di.origType)&&(!Te||Te.guid===di.guid)&&(!It||It.test(di.namespace))&&(!Pe||Pe===di.selector||Pe==="**"&&di.selector)&&(ri.splice(He,1),di.selector&&ri.delegateCount--,bi.remove&&bi.remove.call(X,di));Ze&&!ri.length&&((!bi.teardown||bi.teardown.call(X,Ki,fr.handle)===!1)&&Q.removeEvent(X,Ni,fr.handle),delete St[Ni])}Q.isEmptyObject(St)&&We.remove(X,"handle events")}},dispatch:function(X){var ae,Te,Pe,ze,He,Ze,It=new Array(arguments.length),St=Q.event.fix(X),Kt=(We.get(this,"events")||Object.create(null))[St.type]||[],di=Q.event.special[St.type]||{};for(It[0]=St,ae=1;ae<arguments.length;ae++)It[ae]=arguments[ae];if(St.delegateTarget=this,!(di.preDispatch&&di.preDispatch.call(this,St)===!1)){for(Ze=Q.event.handlers.call(this,St,Kt),ae=0;(ze=Ze[ae++])&&!St.isPropagationStopped();)for(St.currentTarget=ze.elem,Te=0;(He=ze.handlers[Te++])&&!St.isImmediatePropagationStopped();)(!St.rnamespace||He.namespace===!1||St.rnamespace.test(He.namespace))&&(St.handleObj=He,St.data=He.data,Pe=((Q.event.special[He.origType]||{}).handle||He.handler).apply(ze.elem,It),Pe!==void 0&&(St.result=Pe)===!1&&(St.preventDefault(),St.stopPropagation()));return di.postDispatch&&di.postDispatch.call(this,St),St.result}},handlers:function(X,ae){var Te,Pe,ze,He,Ze,It=[],St=ae.delegateCount,Kt=X.target;if(St&&Kt.nodeType&&!(X.type==="click"&&X.button>=1)){for(;Kt!==this;Kt=Kt.parentNode||this)if(Kt.nodeType===1&&!(X.type==="click"&&Kt.disabled===!0)){for(He=[],Ze={},Te=0;Te<St;Te++)Pe=ae[Te],ze=Pe.selector+" ",Ze[ze]===void 0&&(Ze[ze]=Pe.needsContext?Q(ze,this).index(Kt)>-1:Q.find(ze,this,null,[Kt]).length),Ze[ze]&&He.push(Pe);He.length&&It.push({elem:Kt,handlers:He})}}return Kt=this,St<ae.length&&It.push({elem:Kt,handlers:ae.slice(St)}),It},addProp:function(X,ae){Object.defineProperty(Q.Event.prototype,X,{enumerable:!0,configurable:!0,get:B(ae)?function(){if(this.originalEvent)return ae(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[X]},set:function(Te){Object.defineProperty(this,X,{enumerable:!0,configurable:!0,writable:!0,value:Te})}})},fix:function(X){return X[Q.expando]?X:new Q.Event(X)},special:{load:{noBubble:!0},click:{setup:function(X){var ae=this||X;return pt.test(ae.type)&&ae.click&&he(ae,"input")&&be(ae,"click",!0),!1},trigger:function(X){var ae=this||X;return pt.test(ae.type)&&ae.click&&he(ae,"input")&&be(ae,"click"),!0},_default:function(X){var ae=X.target;return pt.test(ae.type)&&ae.click&&he(ae,"input")&&We.get(ae,"click")||he(ae,"a")}},beforeunload:{postDispatch:function(X){X.result!==void 0&&X.originalEvent&&(X.originalEvent.returnValue=X.result)}}}};function be(X,ae,Te){if(!Te){We.get(X,ae)===void 0&&Q.event.add(X,ae,Ut);return}We.set(X,ae,!1),Q.event.add(X,ae,{namespace:!1,handler:function(Pe){var ze,He=We.get(this,ae);if(Pe.isTrigger&1&&this[ae]){if(He)(Q.event.special[ae]||{}).delegateType&&Pe.stopPropagation();else if(He=l.call(arguments),We.set(this,ae,He),this[ae](),ze=We.get(this,ae),We.set(this,ae,!1),He!==ze)return Pe.stopImmediatePropagation(),Pe.preventDefault(),ze}else He&&(We.set(this,ae,Q.event.trigger(He[0],He.slice(1),this)),Pe.stopPropagation(),Pe.isImmediatePropagationStopped=Ut)}})}Q.removeEvent=function(X,ae,Te){X.removeEventListener&&X.removeEventListener(ae,Te)},Q.Event=function(X,ae){if(!(this instanceof Q.Event))return new Q.Event(X,ae);X&&X.type?(this.originalEvent=X,this.type=X.type,this.isDefaultPrevented=X.defaultPrevented||X.defaultPrevented===void 0&&X.returnValue===!1?Ut:Xt,this.target=X.target&&X.target.nodeType===3?X.target.parentNode:X.target,this.currentTarget=X.currentTarget,this.relatedTarget=X.relatedTarget):this.type=X,ae&&Q.extend(this,ae),this.timeStamp=X&&X.timeStamp||Date.now(),this[Q.expando]=!0},Q.Event.prototype={constructor:Q.Event,isDefaultPrevented:Xt,isPropagationStopped:Xt,isImmediatePropagationStopped:Xt,isSimulated:!1,preventDefault:function(){var X=this.originalEvent;this.isDefaultPrevented=Ut,X&&!this.isSimulated&&X.preventDefault()},stopPropagation:function(){var X=this.originalEvent;this.isPropagationStopped=Ut,X&&!this.isSimulated&&X.stopPropagation()},stopImmediatePropagation:function(){var X=this.originalEvent;this.isImmediatePropagationStopped=Ut,X&&!this.isSimulated&&X.stopImmediatePropagation(),this.stopPropagation()}},Q.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:!0},Q.event.addProp),Q.each({focus:"focusin",blur:"focusout"},function(X,ae){function Te(Pe){if(j.documentMode){var ze=We.get(this,"handle"),He=Q.event.fix(Pe);He.type=Pe.type==="focusin"?"focus":"blur",He.isSimulated=!0,ze(Pe),He.target===He.currentTarget&&ze(He)}else Q.event.simulate(ae,Pe.target,Q.event.fix(Pe))}Q.event.special[X]={setup:function(){var Pe;if(be(this,X,!0),j.documentMode)Pe=We.get(this,ae),Pe||this.addEventListener(ae,Te),We.set(this,ae,(Pe||0)+1);else return!1},trigger:function(){return be(this,X),!0},teardown:function(){var Pe;if(j.documentMode)Pe=We.get(this,ae)-1,Pe?We.set(this,ae,Pe):(this.removeEventListener(ae,Te),We.remove(this,ae));else return!1},_default:function(Pe){return We.get(Pe.target,X)},delegateType:ae},Q.event.special[ae]={setup:function(){var Pe=this.ownerDocument||this.document||this,ze=j.documentMode?this:Pe,He=We.get(ze,ae);He||(j.documentMode?this.addEventListener(ae,Te):Pe.addEventListener(X,Te,!0)),We.set(ze,ae,(He||0)+1)},teardown:function(){var Pe=this.ownerDocument||this.document||this,ze=j.documentMode?this:Pe,He=We.get(ze,ae)-1;He?We.set(ze,ae,He):(j.documentMode?this.removeEventListener(ae,Te):Pe.removeEventListener(X,Te,!0),We.remove(ze,ae))}}}),Q.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(X,ae){Q.event.special[X]={delegateType:ae,bindType:ae,handle:function(Te){var Pe,ze=this,He=Te.relatedTarget,Ze=Te.handleObj;return(!He||He!==ze&&!Q.contains(ze,He))&&(Te.type=Ze.origType,Pe=Ze.handler.apply(this,arguments),Te.type=ae),Pe}}}),Q.fn.extend({on:function(X,ae,Te,Pe){return Be(this,X,ae,Te,Pe)},one:function(X,ae,Te,Pe){return Be(this,X,ae,Te,Pe,1)},off:function(X,ae,Te){var Pe,ze;if(X&&X.preventDefault&&X.handleObj)return Pe=X.handleObj,Q(X.delegateTarget).off(Pe.namespace?Pe.origType+"."+Pe.namespace:Pe.origType,Pe.selector,Pe.handler),this;if(typeof X=="object"){for(ze in X)this.off(ze,ae,X[ze]);return this}return(ae===!1||typeof ae=="function")&&(Te=ae,ae=void 0),Te===!1&&(Te=Xt),this.each(function(){Q.event.remove(this,X,Te,ae)})}});var ge=/<script|<style|<link/i,oe=/checked\s*(?:[^=]|=\s*.checked.)/i,Ae=/^\s*<!\[CDATA\[|\]\]>\s*$/g;function qe(X,ae){return he(X,"table")&&he(ae.nodeType!==11?ae:ae.firstChild,"tr")&&Q(X).children("tbody")[0]||X}function bt(X){return X.type=(X.getAttribute("type")!==null)+"/"+X.type,X}function at(X){return(X.type||"").slice(0,5)==="true/"?X.type=X.type.slice(5):X.removeAttribute("type"),X}function gt(X,ae){var Te,Pe,ze,He,Ze,It,St;if(ae.nodeType===1){if(We.hasData(X)&&(He=We.get(X),St=He.events,St)){We.remove(ae,"handle events");for(ze in St)for(Te=0,Pe=St[ze].length;Te<Pe;Te++)Q.event.add(ae,ze,St[ze][Te])}Gt.hasData(X)&&(Ze=Gt.access(X),It=Q.extend({},Ze),Gt.set(ae,It))}}function ei(X,ae){var Te=ae.nodeName.toLowerCase();Te==="input"&&pt.test(X.type)?ae.checked=X.checked:(Te==="input"||Te==="textarea")&&(ae.defaultValue=X.defaultValue)}function ii(X,ae,Te,Pe){ae=m(ae);var ze,He,Ze,It,St,Kt,di=0,bi=X.length,ri=bi-1,Ni=ae[0],Ki=B(Ni);if(Ki||bi>1&&typeof Ni=="string"&&!R.checkClone&&oe.test(Ni))return X.each(function(yr){var fr=X.eq(yr);Ki&&(ae[0]=Ni.call(this,yr,fr.html())),ii(fr,ae,Te,Pe)});if(bi&&(ze=Wt(ae,X[0].ownerDocument,!1,X,Pe),He=ze.firstChild,ze.childNodes.length===1&&(ze=He),He||Pe)){for(Ze=Q.map($t(ze,"script"),bt),It=Ze.length;di<bi;di++)St=ze,di!==ri&&(St=Q.clone(St,!0,!0),It&&Q.merge(Ze,$t(St,"script"))),Te.call(X[di],St,di);if(It)for(Kt=Ze[Ze.length-1].ownerDocument,Q.map(Ze,at),di=0;di<It;di++)St=Ze[di],vt.test(St.type||"")&&!We.access(St,"globalEval")&&Q.contains(Kt,St)&&(St.src&&(St.type||"").toLowerCase()!=="module"?Q._evalUrl&&!St.noModule&&Q._evalUrl(St.src,{nonce:St.nonce||St.getAttribute("nonce")},Kt):Y(St.textContent.replace(Ae,""),St,Kt))}return X}function Bi(X,ae,Te){for(var Pe,ze=ae?Q.filter(ae,X):X,He=0;(Pe=ze[He])!=null;He++)!Te&&Pe.nodeType===1&&Q.cleanData($t(Pe)),Pe.parentNode&&(Te&&Qe(Pe)&&fi($t(Pe,"script")),Pe.parentNode.removeChild(Pe));return X}Q.extend({htmlPrefilter:function(X){return X},clone:function(X,ae,Te){var Pe,ze,He,Ze,It=X.cloneNode(!0),St=Qe(X);if(!R.noCloneChecked&&(X.nodeType===1||X.nodeType===11)&&!Q.isXMLDoc(X))for(Ze=$t(It),He=$t(X),Pe=0,ze=He.length;Pe<ze;Pe++)ei(He[Pe],Ze[Pe]);if(ae)if(Te)for(He=He||$t(X),Ze=Ze||$t(It),Pe=0,ze=He.length;Pe<ze;Pe++)gt(He[Pe],Ze[Pe]);else gt(X,It);return Ze=$t(It,"script"),Ze.length>0&&fi(Ze,!St&&$t(X,"script")),It},cleanData:function(X){for(var ae,Te,Pe,ze=Q.event.special,He=0;(Te=X[He])!==void 0;He++)if(Ot(Te)){if(ae=Te[We.expando]){if(ae.events)for(Pe in ae.events)ze[Pe]?Q.event.remove(Te,Pe):Q.removeEvent(Te,Pe,ae.handle);Te[We.expando]=void 0}Te[Gt.expando]&&(Te[Gt.expando]=void 0)}}}),Q.fn.extend({detach:function(X){return Bi(this,X,!0)},remove:function(X){return Bi(this,X)},text:function(X){return nt(this,function(ae){return ae===void 0?Q.text(this):this.empty().each(function(){(this.nodeType===1||this.nodeType===11||this.nodeType===9)&&(this.textContent=ae)})},null,X,arguments.length)},append:function(){return ii(this,arguments,function(X){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var ae=qe(this,X);ae.appendChild(X)}})},prepend:function(){return ii(this,arguments,function(X){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var ae=qe(this,X);ae.insertBefore(X,ae.firstChild)}})},before:function(){return ii(this,arguments,function(X){this.parentNode&&this.parentNode.insertBefore(X,this)})},after:function(){return ii(this,arguments,function(X){this.parentNode&&this.parentNode.insertBefore(X,this.nextSibling)})},empty:function(){for(var X,ae=0;(X=this[ae])!=null;ae++)X.nodeType===1&&(Q.cleanData($t(X,!1)),X.textContent="");return this},clone:function(X,ae){return X=X??!1,ae=ae??X,this.map(function(){return Q.clone(this,X,ae)})},html:function(X){return nt(this,function(ae){var Te=this[0]||{},Pe=0,ze=this.length;if(ae===void 0&&Te.nodeType===1)return Te.innerHTML;if(typeof ae=="string"&&!ge.test(ae)&&!ut[(Ne.exec(ae)||["",""])[1].toLowerCase()]){ae=Q.htmlPrefilter(ae);try{for(;Pe<ze;Pe++)Te=this[Pe]||{},Te.nodeType===1&&(Q.cleanData($t(Te,!1)),Te.innerHTML=ae);Te=0}catch{}}Te&&this.empty().append(ae)},null,X,arguments.length)},replaceWith:function(){var X=[];return ii(this,arguments,function(ae){var Te=this.parentNode;Q.inArray(this,X)<0&&(Q.cleanData($t(this)),Te&&Te.replaceChild(ae,this))},X)}}),Q.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(X,ae){Q.fn[X]=function(Te){for(var Pe,ze=[],He=Q(Te),Ze=He.length-1,It=0;It<=Ze;It++)Pe=It===Ze?this:this.clone(!0),Q(He[It])[ae](Pe),y.apply(ze,Pe.get());return this.pushStack(ze)}});var hi=new RegExp("^("+te+")(?!px)[a-z%]+$","i"),Di=/^--/,ni=function(X){var ae=X.ownerDocument.defaultView;return(!ae||!ae.opener)&&(ae=e),ae.getComputedStyle(X)},pi=function(X,ae,Te){var Pe,ze,He={};for(ze in ae)He[ze]=X.style[ze],X.style[ze]=ae[ze];Pe=Te.call(X);for(ze in ae)X.style[ze]=He[ze];return Pe},Ii=new RegExp(Le.join("|"),"i");(function(){function X(){if(Kt){St.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",Kt.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",Ue.appendChild(St).appendChild(Kt);var di=e.getComputedStyle(Kt);Te=di.top!=="1%",It=ae(di.marginLeft)===12,Kt.style.right="60%",He=ae(di.right)===36,Pe=ae(di.width)===36,Kt.style.position="absolute",ze=ae(Kt.offsetWidth/3)===12,Ue.removeChild(St),Kt=null}}function ae(di){return Math.round(parseFloat(di))}var Te,Pe,ze,He,Ze,It,St=j.createElement("div"),Kt=j.createElement("div");Kt.style&&(Kt.style.backgroundClip="content-box",Kt.cloneNode(!0).style.backgroundClip="",R.clearCloneStyle=Kt.style.backgroundClip==="content-box",Q.extend(R,{boxSizingReliable:function(){return X(),Pe},pixelBoxStyles:function(){return X(),He},pixelPosition:function(){return X(),Te},reliableMarginLeft:function(){return X(),It},scrollboxSize:function(){return X(),ze},reliableTrDimensions:function(){var di,bi,ri,Ni;return Ze==null&&(di=j.createElement("table"),bi=j.createElement("tr"),ri=j.createElement("div"),di.style.cssText="position:absolute;left:-11111px;border-collapse:separate",bi.style.cssText="box-sizing:content-box;border:1px solid",bi.style.height="1px",ri.style.height="9px",ri.style.display="block",Ue.appendChild(di).appendChild(bi).appendChild(ri),Ni=e.getComputedStyle(bi),Ze=parseInt(Ni.height,10)+parseInt(Ni.borderTopWidth,10)+parseInt(Ni.borderBottomWidth,10)===bi.offsetHeight,Ue.removeChild(di)),Ze}}))})();function Ci(X,ae,Te){var Pe,ze,He,Ze,It=Di.test(ae),St=X.style;return Te=Te||ni(X),Te&&(Ze=Te.getPropertyValue(ae)||Te[ae],It&&Ze&&(Ze=Ze.replace(w,"$1")||void 0),Ze===""&&!Qe(X)&&(Ze=Q.style(X,ae)),!R.pixelBoxStyles()&&hi.test(Ze)&&Ii.test(ae)&&(Pe=St.width,ze=St.minWidth,He=St.maxWidth,St.minWidth=St.maxWidth=St.width=Ze,Ze=Te.width,St.width=Pe,St.minWidth=ze,St.maxWidth=He)),Ze!==void 0?Ze+"":Ze}function zi(X,ae){return{get:function(){if(X()){delete this.get;return}return(this.get=ae).apply(this,arguments)}}}var qi=["Webkit","Moz","ms"],Ai=j.createElement("div").style,Oi={};function ki(X){for(var ae=X[0].toUpperCase()+X.slice(1),Te=qi.length;Te--;)if(X=qi[Te]+ae,X in Ai)return X}function Ti(X){var ae=Q.cssProps[X]||Oi[X];return ae||(X in Ai?X:Oi[X]=ki(X)||X)}var wi=/^(none|table(?!-c[ea]).+)/,oi={position:"absolute",visibility:"hidden",display:"block"},zt={letterSpacing:"0",fontWeight:"400"};function Qt(X,ae,Te){var Pe=ye.exec(ae);return Pe?Math.max(0,Pe[2]-(Te||0))+(Pe[3]||"px"):ae}function Si(X,ae,Te,Pe,ze,He){var Ze=ae==="width"?1:0,It=0,St=0,Kt=0;if(Te===(Pe?"border":"content"))return 0;for(;Ze<4;Ze+=2)Te==="margin"&&(Kt+=Q.css(X,Te+Le[Ze],!0,ze)),Pe?(Te==="content"&&(St-=Q.css(X,"padding"+Le[Ze],!0,ze)),Te!=="margin"&&(St-=Q.css(X,"border"+Le[Ze]+"Width",!0,ze))):(St+=Q.css(X,"padding"+Le[Ze],!0,ze),Te!=="padding"?St+=Q.css(X,"border"+Le[Ze]+"Width",!0,ze):It+=Q.css(X,"border"+Le[Ze]+"Width",!0,ze));return!Pe&&He>=0&&(St+=Math.max(0,Math.ceil(X["offset"+ae[0].toUpperCase()+ae.slice(1)]-He-St-It-.5))||0),St+Kt}function mi(X,ae,Te){var Pe=ni(X),ze=!R.boxSizingReliable()||Te,He=ze&&Q.css(X,"boxSizing",!1,Pe)==="border-box",Ze=He,It=Ci(X,ae,Pe),St="offset"+ae[0].toUpperCase()+ae.slice(1);if(hi.test(It)){if(!Te)return It;It="auto"}return(!R.boxSizingReliable()&&He||!R.reliableTrDimensions()&&he(X,"tr")||It==="auto"||!parseFloat(It)&&Q.css(X,"display",!1,Pe)==="inline")&&X.getClientRects().length&&(He=Q.css(X,"boxSizing",!1,Pe)==="border-box",Ze=St in X,Ze&&(It=X[St])),It=parseFloat(It)||0,It+Si(X,ae,Te||(He?"border":"content"),Ze,Pe,It)+"px"}Q.extend({cssHooks:{opacity:{get:function(X,ae){if(ae){var Te=Ci(X,"opacity");return Te===""?"1":Te}}}},cssNumber:{animationIterationCount:!0,aspectRatio:!0,borderImageSlice:!0,columnCount:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,scale:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeMiterlimit:!0,strokeOpacity:!0},cssProps:{},style:function(X,ae,Te,Pe){if(!(!X||X.nodeType===3||X.nodeType===8||!X.style)){var ze,He,Ze,It=ht(ae),St=Di.test(ae),Kt=X.style;if(St||(ae=Ti(It)),Ze=Q.cssHooks[ae]||Q.cssHooks[It],Te!==void 0){if(He=typeof Te,He==="string"&&(ze=ye.exec(Te))&&ze[1]&&(Te=Vt(X,ae,ze),He="number"),Te==null||Te!==Te)return;He==="number"&&!St&&(Te+=ze&&ze[3]||(Q.cssNumber[It]?"":"px")),!R.clearCloneStyle&&Te===""&&ae.indexOf("background")===0&&(Kt[ae]="inherit"),(!Ze||!("set"in Ze)||(Te=Ze.set(X,Te,Pe))!==void 0)&&(St?Kt.setProperty(ae,Te):Kt[ae]=Te)}else return Ze&&"get"in Ze&&(ze=Ze.get(X,!1,Pe))!==void 0?ze:Kt[ae]}},css:function(X,ae,Te,Pe){var ze,He,Ze,It=ht(ae),St=Di.test(ae);return St||(ae=Ti(It)),Ze=Q.cssHooks[ae]||Q.cssHooks[It],Ze&&"get"in Ze&&(ze=Ze.get(X,!0,Te)),ze===void 0&&(ze=Ci(X,ae,Pe)),ze==="normal"&&ae in zt&&(ze=zt[ae]),Te===""||Te?(He=parseFloat(ze),Te===!0||isFinite(He)?He||0:ze):ze}}),Q.each(["height","width"],function(X,ae){Q.cssHooks[ae]={get:function(Te,Pe,ze){if(Pe)return wi.test(Q.css(Te,"display"))&&(!Te.getClientRects().length||!Te.getBoundingClientRect().width)?pi(Te,oi,function(){return mi(Te,ae,ze)}):mi(Te,ae,ze)},set:function(Te,Pe,ze){var He,Ze=ni(Te),It=!R.scrollboxSize()&&Ze.position==="absolute",St=It||ze,Kt=St&&Q.css(Te,"boxSizing",!1,Ze)==="border-box",di=ze?Si(Te,ae,ze,Kt,Ze):0;return Kt&&It&&(di-=Math.ceil(Te["offset"+ae[0].toUpperCase()+ae.slice(1)]-parseFloat(Ze[ae])-Si(Te,ae,"border",!1,Ze)-.5)),di&&(He=ye.exec(Pe))&&(He[3]||"px")!=="px"&&(Te.style[ae]=Pe,Pe=Q.css(Te,ae)),Qt(Te,Pe,di)}}}),Q.cssHooks.marginLeft=zi(R.reliableMarginLeft,function(X,ae){if(ae)return(parseFloat(Ci(X,"marginLeft"))||X.getBoundingClientRect().left-pi(X,{marginLeft:0},function(){return X.getBoundingClientRect().left}))+"px"}),Q.each({margin:"",padding:"",border:"Width"},function(X,ae){Q.cssHooks[X+ae]={expand:function(Te){for(var Pe=0,ze={},He=typeof Te=="string"?Te.split(" "):[Te];Pe<4;Pe++)ze[X+Le[Pe]+ae]=He[Pe]||He[Pe-2]||He[0];return ze}},X!=="margin"&&(Q.cssHooks[X+ae].set=Qt)}),Q.fn.extend({css:function(X,ae){return nt(this,function(Te,Pe,ze){var He,Ze,It={},St=0;if(Array.isArray(Pe)){for(He=ni(Te),Ze=Pe.length;St<Ze;St++)It[Pe[St]]=Q.css(Te,Pe[St],!1,He);return It}return ze!==void 0?Q.style(Te,Pe,ze):Q.css(Te,Pe)},X,ae,arguments.length>1)}});function ai(X,ae,Te,Pe,ze){return new ai.prototype.init(X,ae,Te,Pe,ze)}Q.Tween=ai,ai.prototype={constructor:ai,init:function(X,ae,Te,Pe,ze,He){this.elem=X,this.prop=Te,this.easing=ze||Q.easing._default,this.options=ae,this.start=this.now=this.cur(),this.end=Pe,this.unit=He||(Q.cssNumber[Te]?"":"px")},cur:function(){var X=ai.propHooks[this.prop];return X&&X.get?X.get(this):ai.propHooks._default.get(this)},run:function(X){var ae,Te=ai.propHooks[this.prop];return this.options.duration?this.pos=ae=Q.easing[this.easing](X,this.options.duration*X,0,1,this.options.duration):this.pos=ae=X,this.now=(this.end-this.start)*ae+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),Te&&Te.set?Te.set(this):ai.propHooks._default.set(this),this}},ai.prototype.init.prototype=ai.prototype,ai.propHooks={_default:{get:function(X){var ae;return X.elem.nodeType!==1||X.elem[X.prop]!=null&&X.elem.style[X.prop]==null?X.elem[X.prop]:(ae=Q.css(X.elem,X.prop,""),!ae||ae==="auto"?0:ae)},set:function(X){Q.fx.step[X.prop]?Q.fx.step[X.prop](X):X.elem.nodeType===1&&(Q.cssHooks[X.prop]||X.elem.style[Ti(X.prop)]!=null)?Q.style(X.elem,X.prop,X.now+X.unit):X.elem[X.prop]=X.now}}},ai.propHooks.scrollTop=ai.propHooks.scrollLeft={set:function(X){X.elem.nodeType&&X.elem.parentNode&&(X.elem[X.prop]=X.now)}},Q.easing={linear:function(X){return X},swing:function(X){return .5-Math.cos(X*Math.PI)/2},_default:"swing"},Q.fx=ai.prototype.init,Q.fx.step={};var gi,Hi,or=/^(?:toggle|show|hide)$/,nr=/queueHooks$/;function Gi(){Hi&&(j.hidden===!1&&e.requestAnimationFrame?e.requestAnimationFrame(Gi):e.setTimeout(Gi,Q.fx.interval),Q.fx.tick())}function Mt(){return e.setTimeout(function(){gi=void 0}),gi=Date.now()}function er(X,ae){var Te,Pe=0,ze={height:X};for(ae=ae?1:0;Pe<4;Pe+=2-ae)Te=Le[Pe],ze["margin"+Te]=ze["padding"+Te]=X;return ae&&(ze.opacity=ze.width=X),ze}function tr(X,ae,Te){for(var Pe,ze=(we.tweeners[ae]||[]).concat(we.tweeners["*"]),He=0,Ze=ze.length;He<Ze;He++)if(Pe=ze[He].call(Te,ae,X))return Pe}function br(X,ae,Te){var Pe,ze,He,Ze,It,St,Kt,di,bi="width"in ae||"height"in ae,ri=this,Ni={},Ki=X.style,yr=X.nodeType&&De(X),fr=We.get(X,"fxshow");Te.queue||(Ze=Q._queueHooks(X,"fx"),Ze.unqueued==null&&(Ze.unqueued=0,It=Ze.empty.fire,Ze.empty.fire=function(){Ze.unqueued||It()}),Ze.unqueued++,ri.always(function(){ri.always(function(){Ze.unqueued--,Q.queue(X,"fx").length||Ze.empty.fire()})}));for(Pe in ae)if(ze=ae[Pe],or.test(ze)){if(delete ae[Pe],He=He||ze==="toggle",ze===(yr?"hide":"show"))if(ze==="show"&&fr&&fr[Pe]!==void 0)yr=!0;else continue;Ni[Pe]=fr&&fr[Pe]||Q.style(X,Pe)}if(St=!Q.isEmptyObject(ae),!(!St&&Q.isEmptyObject(Ni))){bi&&X.nodeType===1&&(Te.overflow=[Ki.overflow,Ki.overflowX,Ki.overflowY],Kt=fr&&fr.display,Kt==null&&(Kt=We.get(X,"display")),di=Q.css(X,"display"),di==="none"&&(Kt?di=Kt:(Pt([X],!0),Kt=X.style.display||Kt,di=Q.css(X,"display"),Pt([X]))),(di==="inline"||di==="inline-block"&&Kt!=null)&&Q.css(X,"float")==="none"&&(St||(ri.done(function(){Ki.display=Kt}),Kt==null&&(di=Ki.display,Kt=di==="none"?"":di)),Ki.display="inline-block")),Te.overflow&&(Ki.overflow="hidden",ri.always(function(){Ki.overflow=Te.overflow[0],Ki.overflowX=Te.overflow[1],Ki.overflowY=Te.overflow[2]})),St=!1;for(Pe in Ni)St||(fr?"hidden"in fr&&(yr=fr.hidden):fr=We.access(X,"fxshow",{display:Kt}),He&&(fr.hidden=!yr),yr&&Pt([X],!0),ri.done(function(){yr||Pt([X]),We.remove(X,"fxshow");for(Pe in Ni)Q.style(X,Pe,Ni[Pe])})),St=tr(yr?fr[Pe]:0,Pe,ri),Pe in fr||(fr[Pe]=St.start,yr&&(St.end=St.start,St.start=0))}}function le(X,ae){var Te,Pe,ze,He,Ze;for(Te in X)if(Pe=ht(Te),ze=ae[Pe],He=X[Te],Array.isArray(He)&&(ze=He[1],He=X[Te]=He[0]),Te!==Pe&&(X[Pe]=He,delete X[Te]),Ze=Q.cssHooks[Pe],Ze&&"expand"in Ze){He=Ze.expand(He),delete X[Pe];for(Te in He)Te in X||(X[Te]=He[Te],ae[Te]=ze)}else ae[Pe]=ze}function we(X,ae,Te){var Pe,ze,He=0,Ze=we.prefilters.length,It=Q.Deferred().always(function(){delete St.elem}),St=function(){if(ze)return!1;for(var bi=gi||Mt(),ri=Math.max(0,Kt.startTime+Kt.duration-bi),Ni=ri/Kt.duration||0,Ki=1-Ni,yr=0,fr=Kt.tweens.length;yr<fr;yr++)Kt.tweens[yr].run(Ki);return It.notifyWith(X,[Kt,Ki,ri]),Ki<1&&fr?ri:(fr||It.notifyWith(X,[Kt,1,0]),It.resolveWith(X,[Kt]),!1)},Kt=It.promise({elem:X,props:Q.extend({},ae),opts:Q.extend(!0,{specialEasing:{},easing:Q.easing._default},Te),originalProperties:ae,originalOptions:Te,startTime:gi||Mt(),duration:Te.duration,tweens:[],createTween:function(bi,ri){var Ni=Q.Tween(X,Kt.opts,bi,ri,Kt.opts.specialEasing[bi]||Kt.opts.easing);return Kt.tweens.push(Ni),Ni},stop:function(bi){var ri=0,Ni=bi?Kt.tweens.length:0;if(ze)return this;for(ze=!0;ri<Ni;ri++)Kt.tweens[ri].run(1);return bi?(It.notifyWith(X,[Kt,1,0]),It.resolveWith(X,[Kt,bi])):It.rejectWith(X,[Kt,bi]),this}}),di=Kt.props;for(le(di,Kt.opts.specialEasing);He<Ze;He++)if(Pe=we.prefilters[He].call(Kt,X,di,Kt.opts),Pe)return B(Pe.stop)&&(Q._queueHooks(Kt.elem,Kt.opts.queue).stop=Pe.stop.bind(Pe)),Pe;return Q.map(di,tr,Kt),B(Kt.opts.start)&&Kt.opts.start.call(X,Kt),Kt.progress(Kt.opts.progress).done(Kt.opts.done,Kt.opts.complete).fail(Kt.opts.fail).always(Kt.opts.always),Q.fx.timer(Q.extend(St,{elem:X,anim:Kt,queue:Kt.opts.queue})),Kt}Q.Animation=Q.extend(we,{tweeners:{"*":[function(X,ae){var Te=this.createTween(X,ae);return Vt(Te.elem,X,ye.exec(ae),Te),Te}]},tweener:function(X,ae){B(X)?(ae=X,X=["*"]):X=X.match(fe);for(var Te,Pe=0,ze=X.length;Pe<ze;Pe++)Te=X[Pe],we.tweeners[Te]=we.tweeners[Te]||[],we.tweeners[Te].unshift(ae)},prefilters:[br],prefilter:function(X,ae){ae?we.prefilters.unshift(X):we.prefilters.push(X)}}),Q.speed=function(X,ae,Te){var Pe=X&&typeof X=="object"?Q.extend({},X):{complete:Te||!Te&&ae||B(X)&&X,duration:X,easing:Te&&ae||ae&&!B(ae)&&ae};return Q.fx.off?Pe.duration=0:typeof Pe.duration!="number"&&(Pe.duration in Q.fx.speeds?Pe.duration=Q.fx.speeds[Pe.duration]:Pe.duration=Q.fx.speeds._default),(Pe.queue==null||Pe.queue===!0)&&(Pe.queue="fx"),Pe.old=Pe.complete,Pe.complete=function(){B(Pe.old)&&Pe.old.call(this),Pe.queue&&Q.dequeue(this,Pe.queue)},Pe},Q.fn.extend({fadeTo:function(X,ae,Te,Pe){return this.filter(De).css("opacity",0).show().end().animate({opacity:ae},X,Te,Pe)},animate:function(X,ae,Te,Pe){var ze=Q.isEmptyObject(X),He=Q.speed(ae,Te,Pe),Ze=function(){var It=we(this,Q.extend({},X),He);(ze||We.get(this,"finish"))&&It.stop(!0)};return Ze.finish=Ze,ze||He.queue===!1?this.each(Ze):this.queue(He.queue,Ze)},stop:function(X,ae,Te){var Pe=function(ze){var He=ze.stop;delete ze.stop,He(Te)};return typeof X!="string"&&(Te=ae,ae=X,X=void 0),ae&&this.queue(X||"fx",[]),this.each(function(){var ze=!0,He=X!=null&&X+"queueHooks",Ze=Q.timers,It=We.get(this);if(He)It[He]&&It[He].stop&&Pe(It[He]);else for(He in It)It[He]&&It[He].stop&&nr.test(He)&&Pe(It[He]);for(He=Ze.length;He--;)Ze[He].elem===this&&(X==null||Ze[He].queue===X)&&(Ze[He].anim.stop(Te),ze=!1,Ze.splice(He,1));(ze||!Te)&&Q.dequeue(this,X)})},finish:function(X){return X!==!1&&(X=X||"fx"),this.each(function(){var ae,Te=We.get(this),Pe=Te[X+"queue"],ze=Te[X+"queueHooks"],He=Q.timers,Ze=Pe?Pe.length:0;for(Te.finish=!0,Q.queue(this,X,[]),ze&&ze.stop&&ze.stop.call(this,!0),ae=He.length;ae--;)He[ae].elem===this&&He[ae].queue===X&&(He[ae].anim.stop(!0),He.splice(ae,1));for(ae=0;ae<Ze;ae++)Pe[ae]&&Pe[ae].finish&&Pe[ae].finish.call(this);delete Te.finish})}}),Q.each(["toggle","show","hide"],function(X,ae){var Te=Q.fn[ae];Q.fn[ae]=function(Pe,ze,He){return Pe==null||typeof Pe=="boolean"?Te.apply(this,arguments):this.animate(er(ae,!0),Pe,ze,He)}}),Q.each({slideDown:er("show"),slideUp:er("hide"),slideToggle:er("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(X,ae){Q.fn[X]=function(Te,Pe,ze){return this.animate(ae,Te,Pe,ze)}}),Q.timers=[],Q.fx.tick=function(){var X,ae=0,Te=Q.timers;for(gi=Date.now();ae<Te.length;ae++)X=Te[ae],!X()&&Te[ae]===X&&Te.splice(ae--,1);Te.length||Q.fx.stop(),gi=void 0},Q.fx.timer=function(X){Q.timers.push(X),Q.fx.start()},Q.fx.interval=13,Q.fx.start=function(){Hi||(Hi=!0,Gi())},Q.fx.stop=function(){Hi=null},Q.fx.speeds={slow:600,fast:200,_default:400},Q.fn.delay=function(X,ae){return X=Q.fx&&Q.fx.speeds[X]||X,ae=ae||"fx",this.queue(ae,function(Te,Pe){var ze=e.setTimeout(Te,X);Pe.stop=function(){e.clearTimeout(ze)}})},function(){var X=j.createElement("input"),ae=j.createElement("select"),Te=ae.appendChild(j.createElement("option"));X.type="checkbox",R.checkOn=X.value!=="",R.optSelected=Te.selected,X=j.createElement("input"),X.value="t",X.type="radio",R.radioValue=X.value==="t"}();var $e,Oe=Q.expr.attrHandle;Q.fn.extend({attr:function(X,ae){return nt(this,Q.attr,X,ae,arguments.length>1)},removeAttr:function(X){return this.each(function(){Q.removeAttr(this,X)})}}),Q.extend({attr:function(X,ae,Te){var Pe,ze,He=X.nodeType;if(!(He===3||He===8||He===2)){if(typeof X.getAttribute>"u")return Q.prop(X,ae,Te);if((He!==1||!Q.isXMLDoc(X))&&(ze=Q.attrHooks[ae.toLowerCase()]||(Q.expr.match.bool.test(ae)?$e:void 0)),Te!==void 0){if(Te===null){Q.removeAttr(X,ae);return}return ze&&"set"in ze&&(Pe=ze.set(X,Te,ae))!==void 0?Pe:(X.setAttribute(ae,Te+""),Te)}return ze&&"get"in ze&&(Pe=ze.get(X,ae))!==null?Pe:(Pe=Q.find.attr(X,ae),Pe??void 0)}},attrHooks:{type:{set:function(X,ae){if(!R.radioValue&&ae==="radio"&&he(X,"input")){var Te=X.value;return X.setAttribute("type",ae),Te&&(X.value=Te),ae}}}},removeAttr:function(X,ae){var Te,Pe=0,ze=ae&&ae.match(fe);if(ze&&X.nodeType===1)for(;Te=ze[Pe++];)X.removeAttribute(Te)}}),$e={set:function(X,ae,Te){return ae===!1?Q.removeAttr(X,Te):X.setAttribute(Te,Te),Te}},Q.each(Q.expr.match.bool.source.match(/\w+/g),function(X,ae){var Te=Oe[ae]||Q.find.attr;Oe[ae]=function(Pe,ze,He){var Ze,It,St=ze.toLowerCase();return He||(It=Oe[St],Oe[St]=Ze,Ze=Te(Pe,ze,He)!=null?St:null,Oe[St]=It),Ze}});var Ge=/^(?:input|select|textarea|button)$/i,st=/^(?:a|area)$/i;Q.fn.extend({prop:function(X,ae){return nt(this,Q.prop,X,ae,arguments.length>1)},removeProp:function(X){return this.each(function(){delete this[Q.propFix[X]||X]})}}),Q.extend({prop:function(X,ae,Te){var Pe,ze,He=X.nodeType;if(!(He===3||He===8||He===2))return(He!==1||!Q.isXMLDoc(X))&&(ae=Q.propFix[ae]||ae,ze=Q.propHooks[ae]),Te!==void 0?ze&&"set"in ze&&(Pe=ze.set(X,Te,ae))!==void 0?Pe:X[ae]=Te:ze&&"get"in ze&&(Pe=ze.get(X,ae))!==null?Pe:X[ae]},propHooks:{tabIndex:{get:function(X){var ae=Q.find.attr(X,"tabindex");return ae?parseInt(ae,10):Ge.test(X.nodeName)||st.test(X.nodeName)&&X.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),R.optSelected||(Q.propHooks.selected={get:function(X){var ae=X.parentNode;return ae&&ae.parentNode&&ae.parentNode.selectedIndex,null},set:function(X){var ae=X.parentNode;ae&&(ae.selectedIndex,ae.parentNode&&ae.parentNode.selectedIndex)}}),Q.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){Q.propFix[this.toLowerCase()]=this});function xe(X){var ae=X.match(fe)||[];return ae.join(" ")}function Ee(X){return X.getAttribute&&X.getAttribute("class")||""}function Ie(X){return Array.isArray(X)?X:typeof X=="string"?X.match(fe)||[]:[]}Q.fn.extend({addClass:function(X){var ae,Te,Pe,ze,He,Ze;return B(X)?this.each(function(It){Q(this).addClass(X.call(this,It,Ee(this)))}):(ae=Ie(X),ae.length?this.each(function(){if(Pe=Ee(this),Te=this.nodeType===1&&" "+xe(Pe)+" ",Te){for(He=0;He<ae.length;He++)ze=ae[He],Te.indexOf(" "+ze+" ")<0&&(Te+=ze+" ");Ze=xe(Te),Pe!==Ze&&this.setAttribute("class",Ze)}}):this)},removeClass:function(X){var ae,Te,Pe,ze,He,Ze;return B(X)?this.each(function(It){Q(this).removeClass(X.call(this,It,Ee(this)))}):arguments.length?(ae=Ie(X),ae.length?this.each(function(){if(Pe=Ee(this),Te=this.nodeType===1&&" "+xe(Pe)+" ",Te){for(He=0;He<ae.length;He++)for(ze=ae[He];Te.indexOf(" "+ze+" ")>-1;)Te=Te.replace(" "+ze+" "," ");Ze=xe(Te),Pe!==Ze&&this.setAttribute("class",Ze)}}):this):this.attr("class","")},toggleClass:function(X,ae){var Te,Pe,ze,He,Ze=typeof X,It=Ze==="string"||Array.isArray(X);return B(X)?this.each(function(St){Q(this).toggleClass(X.call(this,St,Ee(this),ae),ae)}):typeof ae=="boolean"&&It?ae?this.addClass(X):this.removeClass(X):(Te=Ie(X),this.each(function(){if(It)for(He=Q(this),ze=0;ze<Te.length;ze++)Pe=Te[ze],He.hasClass(Pe)?He.removeClass(Pe):He.addClass(Pe);else(X===void 0||Ze==="boolean")&&(Pe=Ee(this),Pe&&We.set(this,"__className__",Pe),this.setAttribute&&this.setAttribute("class",Pe||X===!1?"":We.get(this,"__className__")||""))}))},hasClass:function(X){var ae,Te,Pe=0;for(ae=" "+X+" ";Te=this[Pe++];)if(Te.nodeType===1&&(" "+xe(Ee(Te))+" ").indexOf(ae)>-1)return!0;return!1}});var Xe=/\r/g;Q.fn.extend({val:function(X){var ae,Te,Pe,ze=this[0];return arguments.length?(Pe=B(X),this.each(function(He){var Ze;this.nodeType===1&&(Pe?Ze=X.call(this,He,Q(this).val()):Ze=X,Ze==null?Ze="":typeof Ze=="number"?Ze+="":Array.isArray(Ze)&&(Ze=Q.map(Ze,function(It){return It==null?"":It+""})),ae=Q.valHooks[this.type]||Q.valHooks[this.nodeName.toLowerCase()],(!ae||!("set"in ae)||ae.set(this,Ze,"value")===void 0)&&(this.value=Ze))})):ze?(ae=Q.valHooks[ze.type]||Q.valHooks[ze.nodeName.toLowerCase()],ae&&"get"in ae&&(Te=ae.get(ze,"value"))!==void 0?Te:(Te=ze.value,typeof Te=="string"?Te.replace(Xe,""):Te??"")):void 0}}),Q.extend({valHooks:{option:{get:function(X){var ae=Q.find.attr(X,"value");return ae??xe(Q.text(X))}},select:{get:function(X){var ae,Te,Pe,ze=X.options,He=X.selectedIndex,Ze=X.type==="select-one",It=Ze?null:[],St=Ze?He+1:ze.length;for(He<0?Pe=St:Pe=Ze?He:0;Pe<St;Pe++)if(Te=ze[Pe],(Te.selected||Pe===He)&&!Te.disabled&&(!Te.parentNode.disabled||!he(Te.parentNode,"optgroup"))){if(ae=Q(Te).val(),Ze)return ae;It.push(ae)}return It},set:function(X,ae){for(var Te,Pe,ze=X.options,He=Q.makeArray(ae),Ze=ze.length;Ze--;)Pe=ze[Ze],(Pe.selected=Q.inArray(Q.valHooks.option.get(Pe),He)>-1)&&(Te=!0);return Te||(X.selectedIndex=-1),He}}}}),Q.each(["radio","checkbox"],function(){Q.valHooks[this]={set:function(X,ae){if(Array.isArray(ae))return X.checked=Q.inArray(Q(X).val(),ae)>-1}},R.checkOn||(Q.valHooks[this].get=function(X){return X.getAttribute("value")===null?"on":X.value})});var xt=e.location,Lt={guid:Date.now()},Ft=/\?/;Q.parseXML=function(X){var ae,Te;if(!X||typeof X!="string")return null;try{ae=new e.DOMParser().parseFromString(X,"text/xml")}catch{}return Te=ae&&ae.getElementsByTagName("parsererror")[0],(!ae||Te)&&Q.error("Invalid XML: "+(Te?Q.map(Te.childNodes,function(Pe){return Pe.textContent}).join(`
`):X)),ae};var jt=/^(?:focusinfocus|focusoutblur)$/,si=function(X){X.stopPropagation()};Q.extend(Q.event,{trigger:function(X,ae,Te,Pe){var ze,He,Ze,It,St,Kt,di,bi,ri=[Te||j],Ni=A.call(X,"type")?X.type:X,Ki=A.call(X,"namespace")?X.namespace.split("."):[];if(He=bi=Ze=Te=Te||j,!(Te.nodeType===3||Te.nodeType===8)&&!jt.test(Ni+Q.event.triggered)&&(Ni.indexOf(".")>-1&&(Ki=Ni.split("."),Ni=Ki.shift(),Ki.sort()),St=Ni.indexOf(":")<0&&"on"+Ni,X=X[Q.expando]?X:new Q.Event(Ni,typeof X=="object"&&X),X.isTrigger=Pe?2:3,X.namespace=Ki.join("."),X.rnamespace=X.namespace?new RegExp("(^|\\.)"+Ki.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,X.result=void 0,X.target||(X.target=Te),ae=ae==null?[X]:Q.makeArray(ae,[X]),di=Q.event.special[Ni]||{},!(!Pe&&di.trigger&&di.trigger.apply(Te,ae)===!1))){if(!Pe&&!di.noBubble&&!F(Te)){for(It=di.delegateType||Ni,jt.test(It+Ni)||(He=He.parentNode);He;He=He.parentNode)ri.push(He),Ze=He;Ze===(Te.ownerDocument||j)&&ri.push(Ze.defaultView||Ze.parentWindow||e)}for(ze=0;(He=ri[ze++])&&!X.isPropagationStopped();)bi=He,X.type=ze>1?It:di.bindType||Ni,Kt=(We.get(He,"events")||Object.create(null))[X.type]&&We.get(He,"handle"),Kt&&Kt.apply(He,ae),Kt=St&&He[St],Kt&&Kt.apply&&Ot(He)&&(X.result=Kt.apply(He,ae),X.result===!1&&X.preventDefault());return X.type=Ni,!Pe&&!X.isDefaultPrevented()&&(!di._default||di._default.apply(ri.pop(),ae)===!1)&&Ot(Te)&&St&&B(Te[Ni])&&!F(Te)&&(Ze=Te[St],Ze&&(Te[St]=null),Q.event.triggered=Ni,X.isPropagationStopped()&&bi.addEventListener(Ni,si),Te[Ni](),X.isPropagationStopped()&&bi.removeEventListener(Ni,si),Q.event.triggered=void 0,Ze&&(Te[St]=Ze)),X.result}},simulate:function(X,ae,Te){var Pe=Q.extend(new Q.Event,Te,{type:X,isSimulated:!0});Q.event.trigger(Pe,null,ae)}}),Q.fn.extend({trigger:function(X,ae){return this.each(function(){Q.event.trigger(X,ae,this)})},triggerHandler:function(X,ae){var Te=this[0];if(Te)return Q.event.trigger(X,ae,Te,!0)}});var yi=/\[\]$/,vi=/\r?\n/g,li=/^(?:submit|button|image|reset|file)$/i,Vi=/^(?:input|select|textarea|keygen)/i;function Ei(X,ae,Te,Pe){var ze;if(Array.isArray(ae))Q.each(ae,function(He,Ze){Te||yi.test(X)?Pe(X,Ze):Ei(X+"["+(typeof Ze=="object"&&Ze!=null?He:"")+"]",Ze,Te,Pe)});else if(!Te&&J(ae)==="object")for(ze in ae)Ei(X+"["+ze+"]",ae[ze],Te,Pe);else Pe(X,ae)}Q.param=function(X,ae){var Te,Pe=[],ze=function(He,Ze){var It=B(Ze)?Ze():Ze;Pe[Pe.length]=encodeURIComponent(He)+"="+encodeURIComponent(It??"")};if(X==null)return"";if(Array.isArray(X)||X.jquery&&!Q.isPlainObject(X))Q.each(X,function(){ze(this.name,this.value)});else for(Te in X)Ei(Te,X[Te],ae,ze);return Pe.join("&")},Q.fn.extend({serialize:function(){return Q.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var X=Q.prop(this,"elements");return X?Q.makeArray(X):this}).filter(function(){var X=this.type;return this.name&&!Q(this).is(":disabled")&&Vi.test(this.nodeName)&&!li.test(X)&&(this.checked||!pt.test(X))}).map(function(X,ae){var Te=Q(this).val();return Te==null?null:Array.isArray(Te)?Q.map(Te,function(Pe){return{name:ae.name,value:Pe.replace(vi,`\r
`)}}):{name:ae.name,value:Te.replace(vi,`\r
`)}}).get()}});var $i=/%20/g,xi=/#.*$/,ir=/([?&])_=[^&]*/,Ji=/^(.*?):[ \t]*([^\r\n]*)$/mg,ur=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,zn=/^(?:GET|HEAD)$/,Un=/^\/\//,_r={},xr={},En="*/".concat("*"),kn=j.createElement("a");kn.href=xt.href;function ia(X){return function(ae,Te){typeof ae!="string"&&(Te=ae,ae="*");var Pe,ze=0,He=ae.toLowerCase().match(fe)||[];if(B(Te))for(;Pe=He[ze++];)Pe[0]==="+"?(Pe=Pe.slice(1)||"*",(X[Pe]=X[Pe]||[]).unshift(Te)):(X[Pe]=X[Pe]||[]).push(Te)}}function pn(X,ae,Te,Pe){var ze={},He=X===xr;function Ze(It){var St;return ze[It]=!0,Q.each(X[It]||[],function(Kt,di){var bi=di(ae,Te,Pe);if(typeof bi=="string"&&!He&&!ze[bi])return ae.dataTypes.unshift(bi),Ze(bi),!1;if(He)return!(St=bi)}),St}return Ze(ae.dataTypes[0])||!ze["*"]&&Ze("*")}function yn(X,ae){var Te,Pe,ze=Q.ajaxSettings.flatOptions||{};for(Te in ae)ae[Te]!==void 0&&((ze[Te]?X:Pe||(Pe={}))[Te]=ae[Te]);return Pe&&Q.extend(!0,X,Pe),X}function ca(X,ae,Te){for(var Pe,ze,He,Ze,It=X.contents,St=X.dataTypes;St[0]==="*";)St.shift(),Pe===void 0&&(Pe=X.mimeType||ae.getResponseHeader("Content-Type"));if(Pe){for(ze in It)if(It[ze]&&It[ze].test(Pe)){St.unshift(ze);break}}if(St[0]in Te)He=St[0];else{for(ze in Te){if(!St[0]||X.converters[ze+" "+St[0]]){He=ze;break}Ze||(Ze=ze)}He=He||Ze}if(He)return He!==St[0]&&St.unshift(He),Te[He]}function _a(X,ae,Te,Pe){var ze,He,Ze,It,St,Kt={},di=X.dataTypes.slice();if(di[1])for(Ze in X.converters)Kt[Ze.toLowerCase()]=X.converters[Ze];for(He=di.shift();He;)if(X.responseFields[He]&&(Te[X.responseFields[He]]=ae),!St&&Pe&&X.dataFilter&&(ae=X.dataFilter(ae,X.dataType)),St=He,He=di.shift(),He){if(He==="*")He=St;else if(St!=="*"&&St!==He){if(Ze=Kt[St+" "+He]||Kt["* "+He],!Ze){for(ze in Kt)if(It=ze.split(" "),It[1]===He&&(Ze=Kt[St+" "+It[0]]||Kt["* "+It[0]],Ze)){Ze===!0?Ze=Kt[ze]:Kt[ze]!==!0&&(He=It[0],di.unshift(It[1]));break}}if(Ze!==!0)if(Ze&&X.throws)ae=Ze(ae);else try{ae=Ze(ae)}catch(bi){return{state:"parsererror",error:Ze?bi:"No conversion from "+St+" to "+He}}}}return{state:"success",data:ae}}Q.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:xt.href,type:"GET",isLocal:ur.test(xt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":En,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":Q.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(X,ae){return ae?yn(yn(X,Q.ajaxSettings),ae):yn(Q.ajaxSettings,X)},ajaxPrefilter:ia(_r),ajaxTransport:ia(xr),ajax:function(X,ae){typeof X=="object"&&(ae=X,X=void 0),ae=ae||{};var Te,Pe,ze,He,Ze,It,St,Kt,di,bi,ri=Q.ajaxSetup({},ae),Ni=ri.context||ri,Ki=ri.context&&(Ni.nodeType||Ni.jquery)?Q(Ni):Q.event,yr=Q.Deferred(),fr=Q.Callbacks("once memory"),jr=ri.statusCode||{},Or={},Qr={},Cn="canceled",Tr={readyState:0,getResponseHeader:function(Sr){var Lr;if(St){if(!He)for(He={};Lr=Ji.exec(ze);)He[Lr[1].toLowerCase()+" "]=(He[Lr[1].toLowerCase()+" "]||[]).concat(Lr[2]);Lr=He[Sr.toLowerCase()+" "]}return Lr==null?null:Lr.join(", ")},getAllResponseHeaders:function(){return St?ze:null},setRequestHeader:function(Sr,Lr){return St==null&&(Sr=Qr[Sr.toLowerCase()]=Qr[Sr.toLowerCase()]||Sr,Or[Sr]=Lr),this},overrideMimeType:function(Sr){return St==null&&(ri.mimeType=Sr),this},statusCode:function(Sr){var Lr;if(Sr)if(St)Tr.always(Sr[Tr.status]);else for(Lr in Sr)jr[Lr]=[jr[Lr],Sr[Lr]];return this},abort:function(Sr){var Lr=Sr||Cn;return Te&&Te.abort(Lr),$n(0,Lr),this}};if(yr.promise(Tr),ri.url=((X||ri.url||xt.href)+"").replace(Un,xt.protocol+"//"),ri.type=ae.method||ae.type||ri.method||ri.type,ri.dataTypes=(ri.dataType||"*").toLowerCase().match(fe)||[""],ri.crossDomain==null){It=j.createElement("a");try{It.href=ri.url,It.href=It.href,ri.crossDomain=kn.protocol+"//"+kn.host!=It.protocol+"//"+It.host}catch{ri.crossDomain=!0}}if(ri.data&&ri.processData&&typeof ri.data!="string"&&(ri.data=Q.param(ri.data,ri.traditional)),pn(_r,ri,ae,Tr),St)return Tr;Kt=Q.event&&ri.global,Kt&&Q.active++===0&&Q.event.trigger("ajaxStart"),ri.type=ri.type.toUpperCase(),ri.hasContent=!zn.test(ri.type),Pe=ri.url.replace(xi,""),ri.hasContent?ri.data&&ri.processData&&(ri.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&(ri.data=ri.data.replace($i,"+")):(bi=ri.url.slice(Pe.length),ri.data&&(ri.processData||typeof ri.data=="string")&&(Pe+=(Ft.test(Pe)?"&":"?")+ri.data,delete ri.data),ri.cache===!1&&(Pe=Pe.replace(ir,"$1"),bi=(Ft.test(Pe)?"&":"?")+"_="+Lt.guid+++bi),ri.url=Pe+bi),ri.ifModified&&(Q.lastModified[Pe]&&Tr.setRequestHeader("If-Modified-Since",Q.lastModified[Pe]),Q.etag[Pe]&&Tr.setRequestHeader("If-None-Match",Q.etag[Pe])),(ri.data&&ri.hasContent&&ri.contentType!==!1||ae.contentType)&&Tr.setRequestHeader("Content-Type",ri.contentType),Tr.setRequestHeader("Accept",ri.dataTypes[0]&&ri.accepts[ri.dataTypes[0]]?ri.accepts[ri.dataTypes[0]]+(ri.dataTypes[0]!=="*"?", "+En+"; q=0.01":""):ri.accepts["*"]);for(di in ri.headers)Tr.setRequestHeader(di,ri.headers[di]);if(ri.beforeSend&&(ri.beforeSend.call(Ni,Tr,ri)===!1||St))return Tr.abort();if(Cn="abort",fr.add(ri.complete),Tr.done(ri.success),Tr.fail(ri.error),Te=pn(xr,ri,ae,Tr),!Te)$n(-1,"No Transport");else{if(Tr.readyState=1,Kt&&Ki.trigger("ajaxSend",[Tr,ri]),St)return Tr;ri.async&&ri.timeout>0&&(Ze=e.setTimeout(function(){Tr.abort("timeout")},ri.timeout));try{St=!1,Te.send(Or,$n)}catch(Sr){if(St)throw Sr;$n(-1,Sr)}}function $n(Sr,Lr,wa,La){var rn,ra,un,Ln,Vn,Jr=Lr;St||(St=!0,Ze&&e.clearTimeout(Ze),Te=void 0,ze=La||"",Tr.readyState=Sr>0?4:0,rn=Sr>=200&&Sr<300||Sr===304,wa&&(Ln=ca(ri,Tr,wa)),!rn&&Q.inArray("script",ri.dataTypes)>-1&&Q.inArray("json",ri.dataTypes)<0&&(ri.converters["text script"]=function(){}),Ln=_a(ri,Ln,Tr,rn),rn?(ri.ifModified&&(Vn=Tr.getResponseHeader("Last-Modified"),Vn&&(Q.lastModified[Pe]=Vn),Vn=Tr.getResponseHeader("etag"),Vn&&(Q.etag[Pe]=Vn)),Sr===204||ri.type==="HEAD"?Jr="nocontent":Sr===304?Jr="notmodified":(Jr=Ln.state,ra=Ln.data,un=Ln.error,rn=!un)):(un=Jr,(Sr||!Jr)&&(Jr="error",Sr<0&&(Sr=0))),Tr.status=Sr,Tr.statusText=(Lr||Jr)+"",rn?yr.resolveWith(Ni,[ra,Jr,Tr]):yr.rejectWith(Ni,[Tr,Jr,un]),Tr.statusCode(jr),jr=void 0,Kt&&Ki.trigger(rn?"ajaxSuccess":"ajaxError",[Tr,ri,rn?ra:un]),fr.fireWith(Ni,[Tr,Jr]),Kt&&(Ki.trigger("ajaxComplete",[Tr,ri]),--Q.active||Q.event.trigger("ajaxStop")))}return Tr},getJSON:function(X,ae,Te){return Q.get(X,ae,Te,"json")},getScript:function(X,ae){return Q.get(X,void 0,ae,"script")}}),Q.each(["get","post"],function(X,ae){Q[ae]=function(Te,Pe,ze,He){return B(Pe)&&(He=He||ze,ze=Pe,Pe=void 0),Q.ajax(Q.extend({url:Te,type:ae,dataType:He,data:Pe,success:ze},Q.isPlainObject(Te)&&Te))}}),Q.ajaxPrefilter(function(X){var ae;for(ae in X.headers)ae.toLowerCase()==="content-type"&&(X.contentType=X.headers[ae]||"")}),Q._evalUrl=function(X,ae,Te){return Q.ajax({url:X,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(Pe){Q.globalEval(Pe,ae,Te)}})},Q.fn.extend({wrapAll:function(X){var ae;return this[0]&&(B(X)&&(X=X.call(this[0])),ae=Q(X,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&ae.insertBefore(this[0]),ae.map(function(){for(var Te=this;Te.firstElementChild;)Te=Te.firstElementChild;return Te}).append(this)),this},wrapInner:function(X){return B(X)?this.each(function(ae){Q(this).wrapInner(X.call(this,ae))}):this.each(function(){var ae=Q(this),Te=ae.contents();Te.length?Te.wrapAll(X):ae.append(X)})},wrap:function(X){var ae=B(X);return this.each(function(Te){Q(this).wrapAll(ae?X.call(this,Te):X)})},unwrap:function(X){return this.parent(X).not("body").each(function(){Q(this).replaceWith(this.childNodes)}),this}}),Q.expr.pseudos.hidden=function(X){return!Q.expr.pseudos.visible(X)},Q.expr.pseudos.visible=function(X){return!!(X.offsetWidth||X.offsetHeight||X.getClientRects().length)},Q.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch{}};var fa={0:200,1223:204},$r=Q.ajaxSettings.xhr();R.cors=!!$r&&"withCredentials"in $r,R.ajax=$r=!!$r,Q.ajaxTransport(function(X){var ae,Te;if(R.cors||$r&&!X.crossDomain)return{send:function(Pe,ze){var He,Ze=X.xhr();if(Ze.open(X.type,X.url,X.async,X.username,X.password),X.xhrFields)for(He in X.xhrFields)Ze[He]=X.xhrFields[He];X.mimeType&&Ze.overrideMimeType&&Ze.overrideMimeType(X.mimeType),!X.crossDomain&&!Pe["X-Requested-With"]&&(Pe["X-Requested-With"]="XMLHttpRequest");for(He in Pe)Ze.setRequestHeader(He,Pe[He]);ae=function(It){return function(){ae&&(ae=Te=Ze.onload=Ze.onerror=Ze.onabort=Ze.ontimeout=Ze.onreadystatechange=null,It==="abort"?Ze.abort():It==="error"?typeof Ze.status!="number"?ze(0,"error"):ze(Ze.status,Ze.statusText):ze(fa[Ze.status]||Ze.status,Ze.statusText,(Ze.responseType||"text")!=="text"||typeof Ze.responseText!="string"?{binary:Ze.response}:{text:Ze.responseText},Ze.getAllResponseHeaders()))}},Ze.onload=ae(),Te=Ze.onerror=Ze.ontimeout=ae("error"),Ze.onabort!==void 0?Ze.onabort=Te:Ze.onreadystatechange=function(){Ze.readyState===4&&e.setTimeout(function(){ae&&Te()})},ae=ae("abort");try{Ze.send(X.hasContent&&X.data||null)}catch(It){if(ae)throw It}},abort:function(){ae&&ae()}}}),Q.ajaxPrefilter(function(X){X.crossDomain&&(X.contents.script=!1)}),Q.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(X){return Q.globalEval(X),X}}}),Q.ajaxPrefilter("script",function(X){X.cache===void 0&&(X.cache=!1),X.crossDomain&&(X.type="GET")}),Q.ajaxTransport("script",function(X){if(X.crossDomain||X.scriptAttrs){var ae,Te;return{send:function(Pe,ze){ae=Q("<script>").attr(X.scriptAttrs||{}).prop({charset:X.scriptCharset,src:X.url}).on("load error",Te=function(He){ae.remove(),Te=null,He&&ze(He.type==="error"?404:200,He.type)}),j.head.appendChild(ae[0])},abort:function(){Te&&Te()}}}});var Hn=[],Zr=/(=)\?(?=&|$)|\?\?/;Q.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var X=Hn.pop()||Q.expando+"_"+Lt.guid++;return this[X]=!0,X}}),Q.ajaxPrefilter("json jsonp",function(X,ae,Te){var Pe,ze,He,Ze=X.jsonp!==!1&&(Zr.test(X.url)?"url":typeof X.data=="string"&&(X.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&Zr.test(X.data)&&"data");if(Ze||X.dataTypes[0]==="jsonp")return Pe=X.jsonpCallback=B(X.jsonpCallback)?X.jsonpCallback():X.jsonpCallback,Ze?X[Ze]=X[Ze].replace(Zr,"$1"+Pe):X.jsonp!==!1&&(X.url+=(Ft.test(X.url)?"&":"?")+X.jsonp+"="+Pe),X.converters["script json"]=function(){return He||Q.error(Pe+" was not called"),He[0]},X.dataTypes[0]="json",ze=e[Pe],e[Pe]=function(){He=arguments},Te.always(function(){ze===void 0?Q(e).removeProp(Pe):e[Pe]=ze,X[Pe]&&(X.jsonpCallback=ae.jsonpCallback,Hn.push(Pe)),He&&B(ze)&&ze(He[0]),He=ze=void 0}),"script"}),R.createHTMLDocument=function(){var X=j.implementation.createHTMLDocument("").body;return X.innerHTML="<form></form><form></form>",X.childNodes.length===2}(),Q.parseHTML=function(X,ae,Te){if(typeof X!="string")return[];typeof ae=="boolean"&&(Te=ae,ae=!1);var Pe,ze,He;return ae||(R.createHTMLDocument?(ae=j.implementation.createHTMLDocument(""),Pe=ae.createElement("base"),Pe.href=j.location.href,ae.head.appendChild(Pe)):ae=j),ze=M.exec(X),He=!Te&&[],ze?[ae.createElement(ze[1])]:(ze=Wt([X],ae,He),He&&He.length&&Q(He).remove(),Q.merge([],ze.childNodes))},Q.fn.load=function(X,ae,Te){var Pe,ze,He,Ze=this,It=X.indexOf(" ");return It>-1&&(Pe=xe(X.slice(It)),X=X.slice(0,It)),B(ae)?(Te=ae,ae=void 0):ae&&typeof ae=="object"&&(ze="POST"),Ze.length>0&&Q.ajax({url:X,type:ze||"GET",dataType:"html",data:ae}).done(function(St){He=arguments,Ze.html(Pe?Q("<div>").append(Q.parseHTML(St)).find(Pe):St)}).always(Te&&function(St,Kt){Ze.each(function(){Te.apply(this,He||[St.responseText,Kt,St])})}),this},Q.expr.pseudos.animated=function(X){return Q.grep(Q.timers,function(ae){return X===ae.elem}).length},Q.offset={setOffset:function(X,ae,Te){var Pe,ze,He,Ze,It,St,Kt,di=Q.css(X,"position"),bi=Q(X),ri={};di==="static"&&(X.style.position="relative"),It=bi.offset(),He=Q.css(X,"top"),St=Q.css(X,"left"),Kt=(di==="absolute"||di==="fixed")&&(He+St).indexOf("auto")>-1,Kt?(Pe=bi.position(),Ze=Pe.top,ze=Pe.left):(Ze=parseFloat(He)||0,ze=parseFloat(St)||0),B(ae)&&(ae=ae.call(X,Te,Q.extend({},It))),ae.top!=null&&(ri.top=ae.top-It.top+Ze),ae.left!=null&&(ri.left=ae.left-It.left+ze),"using"in ae?ae.using.call(X,ri):bi.css(ri)}},Q.fn.extend({offset:function(X){if(arguments.length)return X===void 0?this:this.each(function(ze){Q.offset.setOffset(this,X,ze)});var ae,Te,Pe=this[0];if(Pe)return Pe.getClientRects().length?(ae=Pe.getBoundingClientRect(),Te=Pe.ownerDocument.defaultView,{top:ae.top+Te.pageYOffset,left:ae.left+Te.pageXOffset}):{top:0,left:0}},position:function(){if(this[0]){var X,ae,Te,Pe=this[0],ze={top:0,left:0};if(Q.css(Pe,"position")==="fixed")ae=Pe.getBoundingClientRect();else{for(ae=this.offset(),Te=Pe.ownerDocument,X=Pe.offsetParent||Te.documentElement;X&&(X===Te.body||X===Te.documentElement)&&Q.css(X,"position")==="static";)X=X.parentNode;X&&X!==Pe&&X.nodeType===1&&(ze=Q(X).offset(),ze.top+=Q.css(X,"borderTopWidth",!0),ze.left+=Q.css(X,"borderLeftWidth",!0))}return{top:ae.top-ze.top-Q.css(Pe,"marginTop",!0),left:ae.left-ze.left-Q.css(Pe,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var X=this.offsetParent;X&&Q.css(X,"position")==="static";)X=X.offsetParent;return X||Ue})}}),Q.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(X,ae){var Te=ae==="pageYOffset";Q.fn[X]=function(Pe){return nt(this,function(ze,He,Ze){var It;if(F(ze)?It=ze:ze.nodeType===9&&(It=ze.defaultView),Ze===void 0)return It?It[ae]:ze[He];It?It.scrollTo(Te?It.pageXOffset:Ze,Te?Ze:It.pageYOffset):ze[He]=Ze},X,Pe,arguments.length)}}),Q.each(["top","left"],function(X,ae){Q.cssHooks[ae]=zi(R.pixelPosition,function(Te,Pe){if(Pe)return Pe=Ci(Te,ae),hi.test(Pe)?Q(Te).position()[ae]+"px":Pe})}),Q.each({Height:"height",Width:"width"},function(X,ae){Q.each({padding:"inner"+X,content:ae,"":"outer"+X},function(Te,Pe){Q.fn[Pe]=function(ze,He){var Ze=arguments.length&&(Te||typeof ze!="boolean"),It=Te||(ze===!0||He===!0?"margin":"border");return nt(this,function(St,Kt,di){var bi;return F(St)?Pe.indexOf("outer")===0?St["inner"+X]:St.document.documentElement["client"+X]:St.nodeType===9?(bi=St.documentElement,Math.max(St.body["scroll"+X],bi["scroll"+X],St.body["offset"+X],bi["offset"+X],bi["client"+X])):di===void 0?Q.css(St,Kt,It):Q.style(St,Kt,di,It)},ae,Ze?ze:void 0,Ze)}})}),Q.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(X,ae){Q.fn[ae]=function(Te){return this.on(ae,Te)}}),Q.fn.extend({bind:function(X,ae,Te){return this.on(X,null,ae,Te)},unbind:function(X,ae){return this.off(X,null,ae)},delegate:function(X,ae,Te,Pe){return this.on(ae,X,Te,Pe)},undelegate:function(X,ae,Te){return arguments.length===1?this.off(X,"**"):this.off(ae,X||"**",Te)},hover:function(X,ae){return this.on("mouseenter",X).on("mouseleave",ae||X)}}),Q.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(X,ae){Q.fn[ae]=function(Te,Pe){return arguments.length>0?this.on(ae,null,Te,Pe):this.trigger(ae)}});var xa=/^[\s\uFEFF\xA0]+|([^\s\uFEFF\xA0])[\s\uFEFF\xA0]+$/g;Q.proxy=function(X,ae){var Te,Pe,ze;if(typeof ae=="string"&&(Te=X[ae],ae=X,X=Te),!!B(X))return Pe=l.call(arguments,2),ze=function(){return X.apply(ae||this,Pe.concat(l.call(arguments)))},ze.guid=X.guid=X.guid||Q.guid++,ze},Q.holdReady=function(X){X?Q.readyWait++:Q.ready(!0)},Q.isArray=Array.isArray,Q.parseJSON=JSON.parse,Q.nodeName=he,Q.isFunction=B,Q.isWindow=F,Q.camelCase=ht,Q.type=J,Q.now=Date.now,Q.isNumeric=function(X){var ae=Q.type(X);return(ae==="number"||ae==="string")&&!isNaN(X-parseFloat(X))},Q.trim=function(X){return X==null?"":(X+"").replace(xa,"$1")};var mn=e.jQuery,tn=e.$;return Q.noConflict=function(X){return e.$===Q&&(e.$=tn),X&&e.jQuery===Q&&(e.jQuery=mn),Q},typeof n>"u"&&(e.jQuery=e.$=Q),Q})})(jquery);var jqueryExports=jquery.exports;const jQuery=getDefaultExportFromCjs$1(jqueryExports);/*! jQuery UI - v1.14.0 - 2024-08-05
* https://jqueryui.com
* Includes: widget.js, position.js, data.js, disable-selection.js, effect.js, effects/effect-blind.js, effects/effect-bounce.js, effects/effect-clip.js, effects/effect-drop.js, effects/effect-explode.js, effects/effect-fade.js, effects/effect-fold.js, effects/effect-highlight.js, effects/effect-puff.js, effects/effect-pulsate.js, effects/effect-scale.js, effects/effect-shake.js, effects/effect-size.js, effects/effect-slide.js, effects/effect-transfer.js, focusable.js, form-reset-mixin.js, jquery-patch.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/datepicker.js, widgets/dialog.js, widgets/draggable.js, widgets/droppable.js, widgets/menu.js, widgets/mouse.js, widgets/progressbar.js, widgets/resizable.js, widgets/selectable.js, widgets/selectmenu.js, widgets/slider.js, widgets/sortable.js, widgets/spinner.js, widgets/tabs.js, widgets/tooltip.js
* Copyright OpenJS Foundation and other contributors; Licensed MIT */(function(t){typeof define=="function"&&define.amd?define(["jquery"],t):t(jQuery)})(function(t){t.ui=t.ui||{},t.ui.version="1.14.0";/*!
 * jQuery UI Widget 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */var e=0,n=Array.prototype.hasOwnProperty,o=Array.prototype.slice;t.cleanData=function(c){return function(p){var x,S,b;for(b=0;(S=p[b])!=null;b++)x=t._data(S,"events"),x&&x.remove&&t(S).triggerHandler("remove");c(p)}}(t.cleanData),t.widget=function(c,p,x){var S,b,h,T={},M=c.split(".")[0];c=c.split(".")[1];var O=M+"-"+c;return x||(x=p,p=t.Widget),Array.isArray(x)&&(x=t.extend.apply(null,[{}].concat(x))),t.expr.pseudos[O.toLowerCase()]=function(V){return!!t.data(V,O)},t[M]=t[M]||{},S=t[M][c],b=t[M][c]=function(V,ee){if(!this||!this._createWidget)return new b(V,ee);arguments.length&&this._createWidget(V,ee)},t.extend(b,S,{version:x.version,_proto:t.extend({},x),_childConstructors:[]}),h=new p,h.options=t.widget.extend({},h.options),t.each(x,function(V,ee){if(typeof ee!="function"){T[V]=ee;return}T[V]=function(){function Z(){return p.prototype[V].apply(this,arguments)}function U(z){return p.prototype[V].apply(this,z)}return function(){var z=this._super,ne=this._superApply,fe;return this._super=Z,this._superApply=U,fe=ee.apply(this,arguments),this._super=z,this._superApply=ne,fe}}()}),b.prototype=t.widget.extend(h,{widgetEventPrefix:S&&h.widgetEventPrefix||c},T,{constructor:b,namespace:M,widgetName:c,widgetFullName:O}),S?(t.each(S._childConstructors,function(V,ee){var Z=ee.prototype;t.widget(Z.namespace+"."+Z.widgetName,b,ee._proto)}),delete S._childConstructors):p._childConstructors.push(b),t.widget.bridge(c,b),b},t.widget.extend=function(c){for(var p=o.call(arguments,1),x=0,S=p.length,b,h;x<S;x++)for(b in p[x])h=p[x][b],n.call(p[x],b)&&h!==void 0&&(t.isPlainObject(h)?c[b]=t.isPlainObject(c[b])?t.widget.extend({},c[b],h):t.widget.extend({},h):c[b]=h);return c},t.widget.bridge=function(c,p){var x=p.prototype.widgetFullName||c;t.fn[c]=function(S){var b=typeof S=="string",h=o.call(arguments,1),T=this;return b?!this.length&&S==="instance"?T=void 0:this.each(function(){var M,O=t.data(this,x);if(S==="instance")return T=O,!1;if(!O)return t.error("cannot call methods on "+c+" prior to initialization; attempted to call method '"+S+"'");if(typeof O[S]!="function"||S.charAt(0)==="_")return t.error("no such method '"+S+"' for "+c+" widget instance");if(M=O[S].apply(O,h),M!==O&&M!==void 0)return T=M&&M.jquery?T.pushStack(M.get()):M,!1}):(h.length&&(S=t.widget.extend.apply(null,[S].concat(h))),this.each(function(){var M=t.data(this,x);M?(M.option(S||{}),M._init&&M._init()):t.data(this,x,new p(S,this))})),T}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{classes:{},disabled:!1,create:null},_createWidget:function(c,p){p=t(p||this.defaultElement||this)[0],this.element=t(p),this.uuid=e++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},p!==this&&(t.data(p,this.widgetFullName,this),this._on(!0,this.element,{remove:function(x){x.target===p&&this.destroy()}}),this.document=t(p.style?p.ownerDocument:p.document||p),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),c),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var c=this;this._destroy(),t.each(this.classesElementLookup,function(p,x){c._removeClass(x,p)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(c,p){var x=c,S,b,h;if(arguments.length===0)return t.widget.extend({},this.options);if(typeof c=="string")if(x={},S=c.split("."),c=S.shift(),S.length){for(b=x[c]=t.widget.extend({},this.options[c]),h=0;h<S.length-1;h++)b[S[h]]=b[S[h]]||{},b=b[S[h]];if(c=S.pop(),arguments.length===1)return b[c]===void 0?null:b[c];b[c]=p}else{if(arguments.length===1)return this.options[c]===void 0?null:this.options[c];x[c]=p}return this._setOptions(x),this},_setOptions:function(c){var p;for(p in c)this._setOption(p,c[p]);return this},_setOption:function(c,p){return c==="classes"&&this._setOptionClasses(p),this.options[c]=p,c==="disabled"&&this._setOptionDisabled(p),this},_setOptionClasses:function(c){var p,x,S;for(p in c)S=this.classesElementLookup[p],!(c[p]===this.options.classes[p]||!S||!S.length)&&(x=t(S.get()),this._removeClass(S,p),x.addClass(this._classes({element:x,keys:p,classes:c,add:!0})))},_setOptionDisabled:function(c){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!c),c&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(c){var p=[],x=this;c=t.extend({element:this.element,classes:this.options.classes||{}},c);function S(){var h=[];c.element.each(function(T,M){var O=t.map(x.classesElementLookup,function(V){return V}).some(function(V){return V.is(M)});O||h.push(M)}),x._on(t(h),{remove:"_untrackClassesElement"})}function b(h,T){var M,O;for(O=0;O<h.length;O++)M=x.classesElementLookup[h[O]]||t(),c.add?(S(),M=t(t.uniqueSort(M.get().concat(c.element.get())))):M=t(M.not(c.element).get()),x.classesElementLookup[h[O]]=M,p.push(h[O]),T&&c.classes[h[O]]&&p.push(c.classes[h[O]])}return c.keys&&b(c.keys.match(/\S+/g)||[],!0),c.extra&&b(c.extra.match(/\S+/g)||[]),p.join(" ")},_untrackClassesElement:function(c){var p=this;t.each(p.classesElementLookup,function(x,S){t.inArray(c.target,S)!==-1&&(p.classesElementLookup[x]=t(S.not(c.target).get()))}),this._off(t(c.target))},_removeClass:function(c,p,x){return this._toggleClass(c,p,x,!1)},_addClass:function(c,p,x){return this._toggleClass(c,p,x,!0)},_toggleClass:function(c,p,x,S){S=typeof S=="boolean"?S:x;var b=typeof c=="string"||c===null,h={extra:b?p:x,keys:b?c:p,element:b?this.element:c,add:S};return h.element.toggleClass(this._classes(h),S),this},_on:function(c,p,x){var S,b=this;typeof c!="boolean"&&(x=p,p=c,c=!1),x?(p=S=t(p),this.bindings=this.bindings.add(p)):(x=p,p=this.element,S=this.widget()),t.each(x,function(h,T){function M(){if(!(!c&&(b.options.disabled===!0||t(this).hasClass("ui-state-disabled"))))return(typeof T=="string"?b[T]:T).apply(b,arguments)}typeof T!="string"&&(M.guid=T.guid=T.guid||M.guid||t.guid++);var O=h.match(/^([\w:-]*)\s*(.*)$/),V=O[1]+b.eventNamespace,ee=O[2];ee?S.on(V,ee,M):p.on(V,M)})},_off:function(c,p){p=(p||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,c.off(p),this.bindings=t(this.bindings.not(c).get()),this.focusable=t(this.focusable.not(c).get()),this.hoverable=t(this.hoverable.not(c).get())},_delay:function(c,p){function x(){return(typeof c=="string"?S[c]:c).apply(S,arguments)}var S=this;return setTimeout(x,p||0)},_hoverable:function(c){this.hoverable=this.hoverable.add(c),this._on(c,{mouseenter:function(p){this._addClass(t(p.currentTarget),null,"ui-state-hover")},mouseleave:function(p){this._removeClass(t(p.currentTarget),null,"ui-state-hover")}})},_focusable:function(c){this.focusable=this.focusable.add(c),this._on(c,{focusin:function(p){this._addClass(t(p.currentTarget),null,"ui-state-focus")},focusout:function(p){this._removeClass(t(p.currentTarget),null,"ui-state-focus")}})},_trigger:function(c,p,x){var S,b,h=this.options[c];if(x=x||{},p=t.Event(p),p.type=(c===this.widgetEventPrefix?c:this.widgetEventPrefix+c).toLowerCase(),p.target=this.element[0],b=p.originalEvent,b)for(S in b)S in p||(p[S]=b[S]);return this.element.trigger(p,x),!(typeof h=="function"&&h.apply(this.element[0],[p].concat(x))===!1||p.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(c,p){t.Widget.prototype["_"+c]=function(x,S,b){typeof S=="string"&&(S={effect:S});var h,T=S?S===!0||typeof S=="number"?p:S.effect||p:c;S=S||{},typeof S=="number"?S={duration:S}:S===!0&&(S={}),h=!t.isEmptyObject(S),S.complete=b,S.delay&&x.delay(S.delay),h&&t.effects&&t.effects.effect[T]?x[c](S):T!==c&&x[T]?x[T](S.duration,S.easing,b):x.queue(function(M){t(this)[c](),b&&b.call(x[0]),M()})}}),t.widget;/*!
 * jQuery UI Position 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 *
 * https://api.jqueryui.com/position/
 */(function(){var c,p=Math.max,x=Math.abs,S=/left|center|right/,b=/top|center|bottom/,h=/[\+\-]\d+(\.[\d]+)?%?/,T=/^\w+/,M=/%$/,O=t.fn.position;function V(z,ne,fe){return[parseFloat(z[0])*(M.test(z[0])?ne/100:1),parseFloat(z[1])*(M.test(z[1])?fe/100:1)]}function ee(z,ne){return parseInt(t.css(z,ne),10)||0}function Z(z){return z!=null&&z===z.window}function U(z){var ne=z[0];return ne.nodeType===9?{width:z.width(),height:z.height(),offset:{top:0,left:0}}:Z(ne)?{width:z.width(),height:z.height(),offset:{top:z.scrollTop(),left:z.scrollLeft()}}:ne.preventDefault?{width:0,height:0,offset:{top:ne.pageY,left:ne.pageX}}:{width:z.outerWidth(),height:z.outerHeight(),offset:z.offset()}}t.position={scrollbarWidth:function(){if(c!==void 0)return c;var z,ne,fe=t("<div style='display:block;position:absolute;width:200px;height:200px;overflow:hidden;'><div style='height:300px;width:auto;'></div></div>"),me=fe.children()[0];return t("body").append(fe),z=me.offsetWidth,fe.css("overflow","scroll"),ne=me.offsetWidth,z===ne&&(ne=fe[0].clientWidth),fe.remove(),c=z-ne},getScrollInfo:function(z){var ne=z.isWindow||z.isDocument?"":z.element.css("overflow-x"),fe=z.isWindow||z.isDocument?"":z.element.css("overflow-y"),me=ne==="scroll"||ne==="auto"&&z.width<z.element[0].scrollWidth,de=fe==="scroll"||fe==="auto"&&z.height<z.element[0].scrollHeight;return{width:de?t.position.scrollbarWidth():0,height:me?t.position.scrollbarWidth():0}},getWithinInfo:function(z){var ne=t(z||window),fe=Z(ne[0]),me=!!ne[0]&&ne[0].nodeType===9,de=!fe&&!me;return{element:ne,isWindow:fe,isDocument:me,offset:de?t(z).offset():{left:0,top:0},scrollLeft:ne.scrollLeft(),scrollTop:ne.scrollTop(),width:ne.outerWidth(),height:ne.outerHeight()}}},t.fn.position=function(z){if(!z||!z.of)return O.apply(this,arguments);z=t.extend({},z);var ne,fe,me,de,je,lt,it=typeof z.of=="string"?t(document).find(z.of):t(z.of),ot=t.position.getWithinInfo(z.within),Ct=t.position.getScrollInfo(ot),nt=(z.collision||"flip").split(" "),Je={};return lt=U(it),it[0].preventDefault&&(z.at="left top"),fe=lt.width,me=lt.height,de=lt.offset,je=t.extend({},de),t.each(["my","at"],function(){var tt=(z[this]||"").split(" "),rt,ht;tt.length===1&&(tt=S.test(tt[0])?tt.concat(["center"]):b.test(tt[0])?["center"].concat(tt):["center","center"]),tt[0]=S.test(tt[0])?tt[0]:"center",tt[1]=b.test(tt[1])?tt[1]:"center",rt=h.exec(tt[0]),ht=h.exec(tt[1]),Je[this]=[rt?rt[0]:0,ht?ht[0]:0],z[this]=[T.exec(tt[0])[0],T.exec(tt[1])[0]]}),nt.length===1&&(nt[1]=nt[0]),z.at[0]==="right"?je.left+=fe:z.at[0]==="center"&&(je.left+=fe/2),z.at[1]==="bottom"?je.top+=me:z.at[1]==="center"&&(je.top+=me/2),ne=V(Je.at,fe,me),je.left+=ne[0],je.top+=ne[1],this.each(function(){var tt,rt,ht=t(this),Ot=ht.outerWidth(),Ve=ht.outerHeight(),We=ee(this,"marginLeft"),Gt=ee(this,"marginTop"),wt=Ot+We+ee(this,"marginRight")+Ct.width,Et=Ve+Gt+ee(this,"marginBottom")+Ct.height,Yt=t.extend({},je),Ce=V(Je.my,ht.outerWidth(),ht.outerHeight());z.my[0]==="right"?Yt.left-=Ot:z.my[0]==="center"&&(Yt.left-=Ot/2),z.my[1]==="bottom"?Yt.top-=Ve:z.my[1]==="center"&&(Yt.top-=Ve/2),Yt.left+=Ce[0],Yt.top+=Ce[1],tt={marginLeft:We,marginTop:Gt},t.each(["left","top"],function(te,ye){t.ui.position[nt[te]]&&t.ui.position[nt[te]][ye](Yt,{targetWidth:fe,targetHeight:me,elemWidth:Ot,elemHeight:Ve,collisionPosition:tt,collisionWidth:wt,collisionHeight:Et,offset:[ne[0]+Ce[0],ne[1]+Ce[1]],my:z.my,at:z.at,within:ot,elem:ht})}),z.using&&(rt=function(te){var ye=de.left-Yt.left,Le=ye+fe-Ot,Ue=de.top-Yt.top,Qe=Ue+me-Ve,Ke={target:{element:it,left:de.left,top:de.top,width:fe,height:me},element:{element:ht,left:Yt.left,top:Yt.top,width:Ot,height:Ve},horizontal:Le<0?"left":ye>0?"right":"center",vertical:Qe<0?"top":Ue>0?"bottom":"middle"};fe<Ot&&x(ye+Le)<fe&&(Ke.horizontal="center"),me<Ve&&x(Ue+Qe)<me&&(Ke.vertical="middle"),p(x(ye),x(Le))>p(x(Ue),x(Qe))?Ke.important="horizontal":Ke.important="vertical",z.using.call(this,te,Ke)}),ht.offset(t.extend(Yt,{using:rt}))})},t.ui.position={fit:{left:function(z,ne){var fe=ne.within,me=fe.isWindow?fe.scrollLeft:fe.offset.left,de=fe.width,je=z.left-ne.collisionPosition.marginLeft,lt=me-je,it=je+ne.collisionWidth-de-me,ot;ne.collisionWidth>de?lt>0&&it<=0?(ot=z.left+lt+ne.collisionWidth-de-me,z.left+=lt-ot):it>0&&lt<=0?z.left=me:lt>it?z.left=me+de-ne.collisionWidth:z.left=me:lt>0?z.left+=lt:it>0?z.left-=it:z.left=p(z.left-je,z.left)},top:function(z,ne){var fe=ne.within,me=fe.isWindow?fe.scrollTop:fe.offset.top,de=ne.within.height,je=z.top-ne.collisionPosition.marginTop,lt=me-je,it=je+ne.collisionHeight-de-me,ot;ne.collisionHeight>de?lt>0&&it<=0?(ot=z.top+lt+ne.collisionHeight-de-me,z.top+=lt-ot):it>0&&lt<=0?z.top=me:lt>it?z.top=me+de-ne.collisionHeight:z.top=me:lt>0?z.top+=lt:it>0?z.top-=it:z.top=p(z.top-je,z.top)}},flip:{left:function(z,ne){var fe=ne.within,me=fe.offset.left+fe.scrollLeft,de=fe.width,je=fe.isWindow?fe.scrollLeft:fe.offset.left,lt=z.left-ne.collisionPosition.marginLeft,it=lt-je,ot=lt+ne.collisionWidth-de-je,Ct=ne.my[0]==="left"?-ne.elemWidth:ne.my[0]==="right"?ne.elemWidth:0,nt=ne.at[0]==="left"?ne.targetWidth:ne.at[0]==="right"?-ne.targetWidth:0,Je=-2*ne.offset[0],tt,rt;it<0?(tt=z.left+Ct+nt+Je+ne.collisionWidth-de-me,(tt<0||tt<x(it))&&(z.left+=Ct+nt+Je)):ot>0&&(rt=z.left-ne.collisionPosition.marginLeft+Ct+nt+Je-je,(rt>0||x(rt)<ot)&&(z.left+=Ct+nt+Je))},top:function(z,ne){var fe=ne.within,me=fe.offset.top+fe.scrollTop,de=fe.height,je=fe.isWindow?fe.scrollTop:fe.offset.top,lt=z.top-ne.collisionPosition.marginTop,it=lt-je,ot=lt+ne.collisionHeight-de-je,Ct=ne.my[1]==="top",nt=Ct?-ne.elemHeight:ne.my[1]==="bottom"?ne.elemHeight:0,Je=ne.at[1]==="top"?ne.targetHeight:ne.at[1]==="bottom"?-ne.targetHeight:0,tt=-2*ne.offset[1],rt,ht;it<0?(ht=z.top+nt+Je+tt+ne.collisionHeight-de-me,(ht<0||ht<x(it))&&(z.top+=nt+Je+tt)):ot>0&&(rt=z.top-ne.collisionPosition.marginTop+nt+Je+tt-je,(rt>0||x(rt)<ot)&&(z.top+=nt+Je+tt))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}})(),t.ui.position;/*!
 * jQuery UI :data 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.extend(t.expr.pseudos,{data:t.expr.createPseudo(function(c){return function(p){return!!t.data(p,c)}})});/*!
 * jQuery UI Disable Selection 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.fn.extend({disableSelection:function(){var c="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(c+".ui-disableSelection",function(p){p.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}});var u=t;/*!
 * jQuery Color Animations v3.0.0
 * https://github.com/jquery/jquery-color
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 *
 * Date: Wed May 15 16:49:44 2024 +0200
 */var l="backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor",m={},y=m.toString,E=/^([\-+])=\s*(\d+\.?\d*)/,C=[{re:/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(c){return[c[1],c[2],c[3],c[4]]}},{re:/rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(c){return[c[1]*2.55,c[2]*2.55,c[3]*2.55,c[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})?/,parse:function(c){return[parseInt(c[1],16),parseInt(c[2],16),parseInt(c[3],16),c[4]?(parseInt(c[4],16)/255).toFixed(2):1]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])([a-f0-9])?/,parse:function(c){return[parseInt(c[1]+c[1],16),parseInt(c[2]+c[2],16),parseInt(c[3]+c[3],16),c[4]?(parseInt(c[4]+c[4],16)/255).toFixed(2):1]}},{re:/hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,space:"hsla",parse:function(c){return[c[1],c[2]/100,c[3]/100,c[4]]}}],k=u.Color=function(c,p,x,S){return new u.Color.fn.parse(c,p,x,S)},A={rgba:{props:{red:{idx:0,type:"byte"},green:{idx:1,type:"byte"},blue:{idx:2,type:"byte"}}},hsla:{props:{hue:{idx:0,type:"degrees"},saturation:{idx:1,type:"percent"},lightness:{idx:2,type:"percent"}}}},D={byte:{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},P,R=u.each;R(A,function(c,p){p.cache="_"+c,p.props.alpha={idx:3,type:"percent",def:1}}),u.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(c,p){m["[object "+p+"]"]=p.toLowerCase()});function B(c){return c==null?c+"":typeof c=="object"?m[y.call(c)]||"object":typeof c}function F(c,p,x){var S=D[p.type]||{};return c==null?x||!p.def?null:p.def:(c=S.floor?~~c:parseFloat(c),S.mod?(c+S.mod)%S.mod:Math.min(S.max,Math.max(0,c)))}function j(c){var p=k(),x=p._rgba=[];return c=c.toLowerCase(),R(C,function(S,b){var h,T=b.re.exec(c),M=T&&b.parse(T),O=b.space||"rgba";if(M)return h=p[O](M),p[A[O].cache]=h[A[O].cache],x=p._rgba=h._rgba,!1}),x.length?(x.join()==="0,0,0,0"&&u.extend(x,P.transparent),p):P[c]}k.fn=u.extend(k.prototype,{parse:function(c,p,x,S){if(c===void 0)return this._rgba=[null,null,null,null],this;(c.jquery||c.nodeType)&&(c=u(c).css(p),p=void 0);var b=this,h=B(c),T=this._rgba=[];if(p!==void 0&&(c=[c,p,x,S],h="array"),h==="string")return this.parse(j(c)||P._default);if(h==="array")return R(A.rgba.props,function(M,O){T[O.idx]=F(c[O.idx],O)}),this;if(h==="object")return c instanceof k?R(A,function(M,O){c[O.cache]&&(b[O.cache]=c[O.cache].slice())}):R(A,function(M,O){var V=O.cache;R(O.props,function(ee,Z){if(!b[V]&&O.to){if(ee==="alpha"||c[ee]==null)return;b[V]=O.to(b._rgba)}b[V][Z.idx]=F(c[ee],Z,!0)}),b[V]&&u.inArray(null,b[V].slice(0,3))<0&&(b[V][3]==null&&(b[V][3]=1),O.from&&(b._rgba=O.from(b[V])))}),this},is:function(c){var p=k(c),x=!0,S=this;return R(A,function(b,h){var T,M=p[h.cache];return M&&(T=S[h.cache]||h.to&&h.to(S._rgba)||[],R(h.props,function(O,V){if(M[V.idx]!=null)return x=M[V.idx]===T[V.idx],x})),x}),x},_space:function(){var c=[],p=this;return R(A,function(x,S){p[S.cache]&&c.push(x)}),c.pop()},transition:function(c,p){var x=k(c),S=x._space(),b=A[S],h=this.alpha()===0?k("transparent"):this,T=h[b.cache]||b.to(h._rgba),M=T.slice();return x=x[b.cache],R(b.props,function(O,V){var ee=V.idx,Z=T[ee],U=x[ee],z=D[V.type]||{};U!==null&&(Z===null?M[ee]=U:(z.mod&&(U-Z>z.mod/2?Z+=z.mod:Z-U>z.mod/2&&(Z-=z.mod)),M[ee]=F((U-Z)*p+Z,V)))}),this[S](M)},blend:function(c){if(this._rgba[3]===1)return this;var p=this._rgba.slice(),x=p.pop(),S=k(c)._rgba;return k(u.map(p,function(b,h){return(1-x)*S[h]+x*b}))},toRgbaString:function(){var c="rgba(",p=u.map(this._rgba,function(x,S){return x??(S>2?1:0)});return p[3]===1&&(p.pop(),c="rgb("),c+p.join(", ")+")"},toHslaString:function(){var c="hsla(",p=u.map(this.hsla(),function(x,S){return x==null&&(x=S>2?1:0),S&&S<3&&(x=Math.round(x*100)+"%"),x});return p[3]===1&&(p.pop(),c="hsl("),c+p.join(", ")+")"},toHexString:function(c){var p=this._rgba.slice(),x=p.pop();return c&&p.push(~~(x*255)),"#"+u.map(p,function(S){return("0"+(S||0).toString(16)).substr(-2)}).join("")},toString:function(){return this.toRgbaString()}}),k.fn.parse.prototype=k.fn;function N(c,p,x){return x=(x+1)%1,x*6<1?c+(p-c)*x*6:x*2<1?p:x*3<2?c+(p-c)*(2/3-x)*6:c}A.hsla.to=function(c){if(c[0]==null||c[1]==null||c[2]==null)return[null,null,null,c[3]];var p=c[0]/255,x=c[1]/255,S=c[2]/255,b=c[3],h=Math.max(p,x,S),T=Math.min(p,x,S),M=h-T,O=h+T,V=O*.5,ee,Z;return T===h?ee=0:p===h?ee=60*(x-S)/M+360:x===h?ee=60*(S-p)/M+120:ee=60*(p-x)/M+240,M===0?Z=0:V<=.5?Z=M/O:Z=M/(2-O),[Math.round(ee)%360,Z,V,b??1]},A.hsla.from=function(c){if(c[0]==null||c[1]==null||c[2]==null)return[null,null,null,c[3]];var p=c[0]/360,x=c[1],S=c[2],b=c[3],h=S<=.5?S*(1+x):S+x-S*x,T=2*S-h;return[Math.round(N(T,h,p+1/3)*255),Math.round(N(T,h,p)*255),Math.round(N(T,h,p-1/3)*255),b]},R(A,function(c,p){var x=p.props,S=p.cache,b=p.to,h=p.from;k.fn[c]=function(T){if(b&&!this[S]&&(this[S]=b(this._rgba)),T===void 0)return this[S].slice();var M,O=B(T),V=O==="array"||O==="object"?T:arguments,ee=this[S].slice();return R(x,function(Z,U){var z=V[O==="object"?Z:U.idx];z==null&&(z=ee[U.idx]),ee[U.idx]=F(z,U)}),h?(M=k(h(ee)),M[S]=ee,M):k(ee)},R(x,function(T,M){k.fn[T]||(k.fn[T]=function(O){var V,ee,Z,U,z=B(O);return T==="alpha"?U=this._hsla?"hsla":"rgba":U=c,V=this[U](),ee=V[M.idx],z==="undefined"?ee:(z==="function"&&(O=O.call(this,ee),z=B(O)),O==null&&M.empty?this:(z==="string"&&(Z=E.exec(O),Z&&(O=ee+parseFloat(Z[2])*(Z[1]==="+"?1:-1))),V[M.idx]=O,this[U](V)))})})}),k.hook=function(c){var p=c.split(" ");R(p,function(x,S){u.cssHooks[S]={set:function(b,h){var T;h!=="transparent"&&(B(h)!=="string"||(T=j(h)))&&(h=k(T||h),h=h.toRgbaString()),b.style[S]=h}},u.fx.step[S]=function(b){b.colorInit||(b.start=k(b.elem,S),b.end=k(b.end),b.colorInit=!0),u.cssHooks[S].set(b.elem,b.start.transition(b.end,b.pos))}})},k.hook(l),u.cssHooks.borderColor={expand:function(c){var p={};return R(["Top","Right","Bottom","Left"],function(x,S){p["border"+S+"Color"]=c}),p}},P=u.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"};/*!
 * jQuery UI Effects 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */var Y="ui-effects-",J="ui-effects-style",ie="ui-effects-animated";t.effects={effect:{}},function(){var c=["add","remove","toggle"],p={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};t.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(h,T){t.fx.step[T]=function(M){(M.end!=="none"&&!M.setAttr||M.pos===1&&!M.setAttr)&&(u.style(M.elem,T,M.end),M.setAttr=!0)}});function x(h){return h.replace(/-([\da-z])/gi,function(T,M){return M.toUpperCase()})}function S(h){var T,M,O=h.ownerDocument.defaultView.getComputedStyle(h),V={};for(M=O.length;M--;)T=O[M],typeof O[T]=="string"&&(V[x(T)]=O[T]);return V}function b(h,T){var M={},O,V;for(O in T)V=T[O],h[O]!==V&&(p[O]||(t.fx.step[O]||!isNaN(parseFloat(V)))&&(M[O]=V));return M}t.effects.animateClass=function(h,T,M,O){var V=t.speed(T,M,O);return this.queue(function(){var ee=t(this),Z=ee.attr("class")||"",U,z=V.children?ee.find("*").addBack():ee;z=z.map(function(){var ne=t(this);return{el:ne,start:S(this)}}),U=function(){t.each(c,function(ne,fe){h[fe]&&ee[fe+"Class"](h[fe])})},U(),z=z.map(function(){return this.end=S(this.el[0]),this.diff=b(this.start,this.end),this}),ee.attr("class",Z),z=z.map(function(){var ne=this,fe=t.Deferred(),me=t.extend({},V,{queue:!1,complete:function(){fe.resolve(ne)}});return this.el.animate(this.diff,me),fe.promise()}),t.when.apply(t,z.get()).done(function(){U(),t.each(arguments,function(){var ne=this.el;t.each(this.diff,function(fe){ne.css(fe,"")})}),V.complete.call(ee[0])})})},t.fn.extend({addClass:function(h){return function(T,M,O,V){return M?t.effects.animateClass.call(this,{add:T},M,O,V):h.apply(this,arguments)}}(t.fn.addClass),removeClass:function(h){return function(T,M,O,V){return arguments.length>1?t.effects.animateClass.call(this,{remove:T},M,O,V):h.apply(this,arguments)}}(t.fn.removeClass),toggleClass:function(h){return function(T,M,O,V,ee){return typeof M=="boolean"||M===void 0?O?t.effects.animateClass.call(this,M?{add:T}:{remove:T},O,V,ee):h.apply(this,arguments):t.effects.animateClass.call(this,{toggle:T},M,O,V)}}(t.fn.toggleClass),switchClass:function(h,T,M,O,V){return t.effects.animateClass.call(this,{add:T,remove:h},M,O,V)}})}(),function(){t.expr&&t.expr.pseudos&&t.expr.pseudos.animated&&(t.expr.pseudos.animated=function(S){return function(b){return!!t(b).data(ie)||S(b)}}(t.expr.pseudos.animated)),t.uiBackCompat===!0&&t.extend(t.effects,{save:function(S,b){for(var h=0,T=b.length;h<T;h++)b[h]!==null&&S.data(Y+b[h],S[0].style[b[h]])},restore:function(S,b){for(var h,T=0,M=b.length;T<M;T++)b[T]!==null&&(h=S.data(Y+b[T]),S.css(b[T],h))},setMode:function(S,b){return b==="toggle"&&(b=S.is(":hidden")?"show":"hide"),b},createWrapper:function(S){if(S.parent().is(".ui-effects-wrapper"))return S.parent();var b={width:S.outerWidth(!0),height:S.outerHeight(!0),float:S.css("float")},h=t("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),T={width:S.width(),height:S.height()},M=document.activeElement;try{M.id}catch{M=document.body}return S.wrap(h),(S[0]===M||t.contains(S[0],M))&&t(M).trigger("focus"),h=S.parent(),S.css("position")==="static"?(h.css({position:"relative"}),S.css({position:"relative"})):(t.extend(b,{position:S.css("position"),zIndex:S.css("z-index")}),t.each(["top","left","bottom","right"],function(O,V){b[V]=S.css(V),isNaN(parseInt(b[V],10))&&(b[V]="auto")}),S.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),S.css(T),h.css(b).show()},removeWrapper:function(S){var b=document.activeElement;return S.parent().is(".ui-effects-wrapper")&&(S.parent().replaceWith(S),(S[0]===b||t.contains(S[0],b))&&t(b).trigger("focus")),S}}),t.extend(t.effects,{version:"1.14.0",define:function(S,b,h){return h||(h=b,b="effect"),t.effects.effect[S]=h,t.effects.effect[S].mode=b,h},scaledDimensions:function(S,b,h){if(b===0)return{height:0,width:0,outerHeight:0,outerWidth:0};var T=h!=="horizontal"?(b||100)/100:1,M=h!=="vertical"?(b||100)/100:1;return{height:S.height()*M,width:S.width()*T,outerHeight:S.outerHeight()*M,outerWidth:S.outerWidth()*T}},clipToBox:function(S){return{width:S.clip.right-S.clip.left,height:S.clip.bottom-S.clip.top,left:S.clip.left,top:S.clip.top}},unshift:function(S,b,h){var T=S.queue();b>1&&T.splice.apply(T,[1,0].concat(T.splice(b,h))),S.dequeue()},saveStyle:function(S){S.data(J,S[0].style.cssText)},restoreStyle:function(S){S[0].style.cssText=S.data(J)||"",S.removeData(J)},mode:function(S,b){var h=S.is(":hidden");return b==="toggle"&&(b=h?"show":"hide"),(h?b==="hide":b==="show")&&(b="none"),b},getBaseline:function(S,b){var h,T;switch(S[0]){case"top":h=0;break;case"middle":h=.5;break;case"bottom":h=1;break;default:h=S[0]/b.height}switch(S[1]){case"left":T=0;break;case"center":T=.5;break;case"right":T=1;break;default:T=S[1]/b.width}return{x:T,y:h}},createPlaceholder:function(S){var b,h=S.css("position"),T=S.position();return S.css({marginTop:S.css("marginTop"),marginBottom:S.css("marginBottom"),marginLeft:S.css("marginLeft"),marginRight:S.css("marginRight")}).outerWidth(S.outerWidth()).outerHeight(S.outerHeight()),/^(static|relative)/.test(h)&&(h="absolute",b=t("<"+S[0].nodeName+">").insertAfter(S).css({display:/^(inline|ruby)/.test(S.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:S.css("marginTop"),marginBottom:S.css("marginBottom"),marginLeft:S.css("marginLeft"),marginRight:S.css("marginRight"),float:S.css("float")}).outerWidth(S.outerWidth()).outerHeight(S.outerHeight()).addClass("ui-effects-placeholder"),S.data(Y+"placeholder",b)),S.css({position:h,left:T.left,top:T.top}),b},removePlaceholder:function(S){var b=Y+"placeholder",h=S.data(b);h&&(h.remove(),S.removeData(b))},cleanUp:function(S){t.effects.restoreStyle(S),t.effects.removePlaceholder(S)},setTransition:function(S,b,h,T){return T=T||{},t.each(b,function(M,O){var V=S.cssUnit(O);V[0]>0&&(T[O]=V[0]*h+V[1])}),T}});function c(S,b,h,T){return t.isPlainObject(S)&&(b=S,S=S.effect),S={effect:S},b==null&&(b={}),typeof b=="function"&&(T=b,h=null,b={}),(typeof b=="number"||t.fx.speeds[b])&&(T=h,h=b,b={}),typeof h=="function"&&(T=h,h=null),b&&t.extend(S,b),h=h||b.duration,S.duration=t.fx.off?0:typeof h=="number"?h:h in t.fx.speeds?t.fx.speeds[h]:t.fx.speeds._default,S.complete=T||b.complete,S}function p(S){return!!(!S||typeof S=="number"||t.fx.speeds[S]||typeof S=="string"&&!t.effects.effect[S]||typeof S=="function"||typeof S=="object"&&!S.effect)}t.fn.extend({effect:function(){var S=c.apply(this,arguments),b=t.effects.effect[S.effect],h=b.mode,T=S.queue,M=T||"fx",O=S.complete,V=S.mode,ee=[],Z=function(z){var ne=t(this),fe=t.effects.mode(ne,V)||h;ne.data(ie,!0),ee.push(fe),h&&(fe==="show"||fe===h&&fe==="hide")&&ne.show(),(!h||fe!=="none")&&t.effects.saveStyle(ne),typeof z=="function"&&z()};if(t.fx.off||!b)return V?this[V](S.duration,O):this.each(function(){O&&O.call(this)});function U(z){var ne=t(this);function fe(){ne.removeData(ie),t.effects.cleanUp(ne),S.mode==="hide"&&ne.hide(),me()}function me(){typeof O=="function"&&O.call(ne[0]),typeof z=="function"&&z()}S.mode=ee.shift(),t.uiBackCompat===!0&&!h?(ne.is(":hidden")?V==="hide":V==="show")?(ne[V](),me()):b.call(ne[0],S,me):S.mode==="none"?(ne[V](),me()):b.call(ne[0],S,fe)}return T===!1?this.each(Z).each(U):this.queue(M,Z).queue(M,U)},show:function(S){return function(b){if(p(b))return S.apply(this,arguments);var h=c.apply(this,arguments);return h.mode="show",this.effect.call(this,h)}}(t.fn.show),hide:function(S){return function(b){if(p(b))return S.apply(this,arguments);var h=c.apply(this,arguments);return h.mode="hide",this.effect.call(this,h)}}(t.fn.hide),toggle:function(S){return function(b){if(p(b)||typeof b=="boolean")return S.apply(this,arguments);var h=c.apply(this,arguments);return h.mode="toggle",this.effect.call(this,h)}}(t.fn.toggle),cssUnit:function(S){var b=this.css(S),h=[];return t.each(["em","px","%","pt"],function(T,M){b.indexOf(M)>0&&(h=[parseFloat(b),M])}),h},cssClip:function(S){return S?this.css("clip","rect("+S.top+"px "+S.right+"px "+S.bottom+"px "+S.left+"px)"):x(this.css("clip"),this)},transfer:function(S,b){var h=t(this),T=t(S.to),M=T.css("position")==="fixed",O=t("body"),V=M?O.scrollTop():0,ee=M?O.scrollLeft():0,Z=T.offset(),U={top:Z.top-V,left:Z.left-ee,height:T.innerHeight(),width:T.innerWidth()},z=h.offset(),ne=t("<div class='ui-effects-transfer'></div>");ne.appendTo("body").addClass(S.className).css({top:z.top-V,left:z.left-ee,height:h.innerHeight(),width:h.innerWidth(),position:M?"fixed":"absolute"}).animate(U,S.duration,S.easing,function(){ne.remove(),typeof b=="function"&&b()})}});function x(S,b){var h=b.outerWidth(),T=b.outerHeight(),M=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/,O=M.exec(S)||["",0,h,T,0];return{top:parseFloat(O[1])||0,right:O[2]==="auto"?h:parseFloat(O[2]),bottom:O[3]==="auto"?T:parseFloat(O[3]),left:parseFloat(O[4])||0}}t.fx.step.clip=function(S){S.clipInit||(S.start=t(S.elem).cssClip(),typeof S.end=="string"&&(S.end=x(S.end,S.elem)),S.clipInit=!0),t(S.elem).cssClip({top:S.pos*(S.end.top-S.start.top)+S.start.top,right:S.pos*(S.end.right-S.start.right)+S.start.right,bottom:S.pos*(S.end.bottom-S.start.bottom)+S.start.bottom,left:S.pos*(S.end.left-S.start.left)+S.start.left})}}(),function(){var c={};t.each(["Quad","Cubic","Quart","Quint","Expo"],function(p,x){c[x]=function(S){return Math.pow(S,p+2)}}),t.extend(c,{Sine:function(p){return 1-Math.cos(p*Math.PI/2)},Circ:function(p){return 1-Math.sqrt(1-p*p)},Elastic:function(p){return p===0||p===1?p:-Math.pow(2,8*(p-1))*Math.sin(((p-1)*80-7.5)*Math.PI/15)},Back:function(p){return p*p*(3*p-2)},Bounce:function(p){for(var x,S=4;p<((x=Math.pow(2,--S))-1)/11;);return 1/Math.pow(4,3-S)-7.5625*Math.pow((x*3-2)/22-p,2)}}),t.each(c,function(p,x){t.easing["easeIn"+p]=x,t.easing["easeOut"+p]=function(S){return 1-x(1-S)},t.easing["easeInOut"+p]=function(S){return S<.5?x(S*2)/2:1-x(S*-2+2)/2}})}(),t.effects;/*!
 * jQuery UI Effects Blind 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("blind","hide",function(c,p){var x={up:["bottom","top"],vertical:["bottom","top"],down:["top","bottom"],left:["right","left"],horizontal:["right","left"],right:["left","right"]},S=t(this),b=c.direction||"up",h=S.cssClip(),T={clip:t.extend({},h)},M=t.effects.createPlaceholder(S);T.clip[x[b][0]]=T.clip[x[b][1]],c.mode==="show"&&(S.cssClip(T.clip),M&&M.css(t.effects.clipToBox(T)),T.clip=h),M&&M.animate(t.effects.clipToBox(T),c.duration,c.easing),S.animate(T,{queue:!1,duration:c.duration,easing:c.easing,complete:p})});/*!
 * jQuery UI Effects Bounce 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("bounce",function(c,p){var x,S,b,h=t(this),T=c.mode,M=T==="hide",O=T==="show",V=c.direction||"up",ee=c.distance,Z=c.times||5,U=Z*2+(O||M?1:0),z=c.duration/U,ne=c.easing,fe=V==="up"||V==="down"?"top":"left",me=V==="up"||V==="left",de=0,je=h.queue().length;for(t.effects.createPlaceholder(h),b=h.css(fe),ee||(ee=h[fe==="top"?"outerHeight":"outerWidth"]()/3),O&&(S={opacity:1},S[fe]=b,h.css("opacity",0).css(fe,me?-ee*2:ee*2).animate(S,z,ne)),M&&(ee=ee/Math.pow(2,Z-1)),S={},S[fe]=b;de<Z;de++)x={},x[fe]=(me?"-=":"+=")+ee,h.animate(x,z,ne).animate(S,z,ne),ee=M?ee*2:ee/2;M&&(x={opacity:0},x[fe]=(me?"-=":"+=")+ee,h.animate(x,z,ne)),h.queue(p),t.effects.unshift(h,je,U+1)});/*!
 * jQuery UI Effects Clip 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("clip","hide",function(c,p){var x,S={},b=t(this),h=c.direction||"vertical",T=h==="both",M=T||h==="horizontal",O=T||h==="vertical";x=b.cssClip(),S.clip={top:O?(x.bottom-x.top)/2:x.top,right:M?(x.right-x.left)/2:x.right,bottom:O?(x.bottom-x.top)/2:x.bottom,left:M?(x.right-x.left)/2:x.left},t.effects.createPlaceholder(b),c.mode==="show"&&(b.cssClip(S.clip),S.clip=x),b.animate(S,{queue:!1,duration:c.duration,easing:c.easing,complete:p})});/*!
 * jQuery UI Effects Drop 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("drop","hide",function(c,p){var x,S=t(this),b=c.mode,h=b==="show",T=c.direction||"left",M=T==="up"||T==="down"?"top":"left",O=T==="up"||T==="left"?"-=":"+=",V=O==="+="?"-=":"+=",ee={opacity:0};t.effects.createPlaceholder(S),x=c.distance||S[M==="top"?"outerHeight":"outerWidth"](!0)/2,ee[M]=O+x,h&&(S.css(ee),ee[M]=V+x,ee.opacity=1),S.animate(ee,{queue:!1,duration:c.duration,easing:c.easing,complete:p})});/*!
 * jQuery UI Effects Explode 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("explode","hide",function(c,p){var x,S,b,h,T,M,O=c.pieces?Math.round(Math.sqrt(c.pieces)):3,V=O,ee=t(this),Z=c.mode,U=Z==="show",z=ee.show().css("visibility","hidden").offset(),ne=Math.ceil(ee.outerWidth()/V),fe=Math.ceil(ee.outerHeight()/O),me=[];function de(){me.push(this),me.length===O*V&&je()}for(x=0;x<O;x++)for(h=z.top+x*fe,M=x-(O-1)/2,S=0;S<V;S++)b=z.left+S*ne,T=S-(V-1)/2,ee.clone().appendTo("body").wrap("<div></div>").css({position:"absolute",visibility:"visible",left:-S*ne,top:-x*fe}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:ne,height:fe,left:b+(U?T*ne:0),top:h+(U?M*fe:0),opacity:U?0:1}).animate({left:b+(U?0:T*ne),top:h+(U?0:M*fe),opacity:U?1:0},c.duration||500,c.easing,de);function je(){ee.css({visibility:"visible"}),t(me).remove(),p()}});/*!
 * jQuery UI Effects Fade 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("fade","toggle",function(c,p){var x=c.mode==="show";t(this).css("opacity",x?0:1).animate({opacity:x?1:0},{queue:!1,duration:c.duration,easing:c.easing,complete:p})});/*!
 * jQuery UI Effects Fold 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("fold","hide",function(c,p){var x=t(this),S=c.mode,b=S==="show",h=S==="hide",T=c.size||15,M=/([0-9]+)%/.exec(T),O=!!c.horizFirst,V=O?["right","bottom"]:["bottom","right"],ee=c.duration/2,Z=t.effects.createPlaceholder(x),U=x.cssClip(),z={clip:t.extend({},U)},ne={clip:t.extend({},U)},fe=[U[V[0]],U[V[1]]],me=x.queue().length;M&&(T=parseInt(M[1],10)/100*fe[h?0:1]),z.clip[V[0]]=T,ne.clip[V[0]]=T,ne.clip[V[1]]=0,b&&(x.cssClip(ne.clip),Z&&Z.css(t.effects.clipToBox(ne)),ne.clip=U),x.queue(function(de){Z&&Z.animate(t.effects.clipToBox(z),ee,c.easing).animate(t.effects.clipToBox(ne),ee,c.easing),de()}).animate(z,ee,c.easing).animate(ne,ee,c.easing).queue(p),t.effects.unshift(x,me,4)});/*!
 * jQuery UI Effects Highlight 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("highlight","show",function(c,p){var x=t(this),S={backgroundColor:x.css("backgroundColor")};c.mode==="hide"&&(S.opacity=0),t.effects.saveStyle(x),x.css({backgroundImage:"none",backgroundColor:c.color||"#ffff99"}).animate(S,{queue:!1,duration:c.duration,easing:c.easing,complete:p})});/*!
 * jQuery UI Effects Size 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("size",function(c,p){var x,S,b,h=t(this),T=["fontSize"],M=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],O=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],V=c.mode,ee=V!=="effect",Z=c.scale||"both",U=c.origin||["middle","center"],z=h.css("position"),ne=h.position(),fe=t.effects.scaledDimensions(h),me=c.from||fe,de=c.to||t.effects.scaledDimensions(h,0);t.effects.createPlaceholder(h),V==="show"&&(b=me,me=de,de=b),S={from:{y:me.height/fe.height,x:me.width/fe.width},to:{y:de.height/fe.height,x:de.width/fe.width}},(Z==="box"||Z==="both")&&(S.from.y!==S.to.y&&(me=t.effects.setTransition(h,M,S.from.y,me),de=t.effects.setTransition(h,M,S.to.y,de)),S.from.x!==S.to.x&&(me=t.effects.setTransition(h,O,S.from.x,me),de=t.effects.setTransition(h,O,S.to.x,de))),(Z==="content"||Z==="both")&&S.from.y!==S.to.y&&(me=t.effects.setTransition(h,T,S.from.y,me),de=t.effects.setTransition(h,T,S.to.y,de)),U&&(x=t.effects.getBaseline(U,fe),me.top=(fe.outerHeight-me.outerHeight)*x.y+ne.top,me.left=(fe.outerWidth-me.outerWidth)*x.x+ne.left,de.top=(fe.outerHeight-de.outerHeight)*x.y+ne.top,de.left=(fe.outerWidth-de.outerWidth)*x.x+ne.left),delete me.outerHeight,delete me.outerWidth,h.css(me),(Z==="content"||Z==="both")&&(M=M.concat(["marginTop","marginBottom"]).concat(T),O=O.concat(["marginLeft","marginRight"]),h.find("*[width]").each(function(){var je=t(this),lt=t.effects.scaledDimensions(je),it={height:lt.height*S.from.y,width:lt.width*S.from.x,outerHeight:lt.outerHeight*S.from.y,outerWidth:lt.outerWidth*S.from.x},ot={height:lt.height*S.to.y,width:lt.width*S.to.x,outerHeight:lt.height*S.to.y,outerWidth:lt.width*S.to.x};S.from.y!==S.to.y&&(it=t.effects.setTransition(je,M,S.from.y,it),ot=t.effects.setTransition(je,M,S.to.y,ot)),S.from.x!==S.to.x&&(it=t.effects.setTransition(je,O,S.from.x,it),ot=t.effects.setTransition(je,O,S.to.x,ot)),ee&&t.effects.saveStyle(je),je.css(it),je.animate(ot,c.duration,c.easing,function(){ee&&t.effects.restoreStyle(je)})})),h.animate(de,{queue:!1,duration:c.duration,easing:c.easing,complete:function(){var je=h.offset();de.opacity===0&&h.css("opacity",me.opacity),ee||(h.css("position",z==="static"?"relative":z).offset(je),t.effects.saveStyle(h)),p()}})});/*!
 * jQuery UI Effects Scale 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("scale",function(c,p){var x=t(this),S=c.mode,b=parseInt(c.percent,10)||(parseInt(c.percent,10)===0||S!=="effect"?0:100),h=t.extend(!0,{from:t.effects.scaledDimensions(x),to:t.effects.scaledDimensions(x,b,c.direction||"both"),origin:c.origin||["middle","center"]},c);c.fade&&(h.from.opacity=1,h.to.opacity=0),t.effects.effect.size.call(this,h,p)});/*!
 * jQuery UI Effects Puff 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("puff","hide",function(c,p){var x=t.extend(!0,{},c,{fade:!0,percent:parseInt(c.percent,10)||150});t.effects.effect.scale.call(this,x,p)});/*!
 * jQuery UI Effects Pulsate 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("pulsate","show",function(c,p){var x=t(this),S=c.mode,b=S==="show",h=S==="hide",T=b||h,M=(c.times||5)*2+(T?1:0),O=c.duration/M,V=0,ee=1,Z=x.queue().length;for((b||!x.is(":visible"))&&(x.css("opacity",0).show(),V=1);ee<M;ee++)x.animate({opacity:V},O,c.easing),V=1-V;x.animate({opacity:V},O,c.easing),x.queue(p),t.effects.unshift(x,Z,M+1)});/*!
 * jQuery UI Effects Shake 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("shake",function(c,p){var x=1,S=t(this),b=c.direction||"left",h=c.distance||20,T=c.times||3,M=T*2+1,O=Math.round(c.duration/M),V=b==="up"||b==="down"?"top":"left",ee=b==="up"||b==="left",Z={},U={},z={},ne=S.queue().length;for(t.effects.createPlaceholder(S),Z[V]=(ee?"-=":"+=")+h,U[V]=(ee?"+=":"-=")+h*2,z[V]=(ee?"-=":"+=")+h*2,S.animate(Z,O,c.easing);x<T;x++)S.animate(U,O,c.easing).animate(z,O,c.easing);S.animate(U,O,c.easing).animate(Z,O/2,c.easing).queue(p),t.effects.unshift(S,ne,M+1)});/*!
 * jQuery UI Effects Slide 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.effects.define("slide","show",function(c,p){var x,S,b=t(this),h={up:["bottom","top"],down:["top","bottom"],left:["right","left"],right:["left","right"]},T=c.mode,M=c.direction||"left",O=M==="up"||M==="down"?"top":"left",V=M==="up"||M==="left",ee=c.distance||b[O==="top"?"outerHeight":"outerWidth"](!0),Z={};t.effects.createPlaceholder(b),x=b.cssClip(),S=b.position()[O],Z[O]=(V?-1:1)*ee+S,Z.clip=b.cssClip(),Z.clip[h[M][1]]=Z.clip[h[M][0]],T==="show"&&(b.cssClip(Z.clip),b.css(O,Z[O]),Z.clip=x,Z[O]=S),b.animate(Z,{queue:!1,duration:c.duration,easing:c.easing,complete:p})}),t.uiBackCompat===!0&&t.effects.define("transfer",function(c,p){t(this).transfer(c,p)});/*!
 * jQuery UI Focusable 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.ui.focusable=function(c,p){var x,S,b,h,T,M=c.nodeName.toLowerCase();return M==="area"?(x=c.parentNode,S=x.name,!c.href||!S||x.nodeName.toLowerCase()!=="map"?!1:(b=t("img[usemap='#"+S+"']"),b.length>0&&b.is(":visible"))):(/^(input|select|textarea|button|object)$/.test(M)?(h=!c.disabled,h&&(T=t(c).closest("fieldset")[0],T&&(h=!T.disabled))):M==="a"?h=c.href||p:h=p,h&&t(c).is(":visible")&&t(c).css("visibility")==="visible")},t.extend(t.expr.pseudos,{focusable:function(c){return t.ui.focusable(c,t.attr(c,"tabindex")!=null)}}),t.ui.focusable;/*!
 * jQuery UI Form Reset Mixin 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.ui.formResetMixin={_formResetHandler:function(){var c=t(this);setTimeout(function(){var p=c.data("ui-form-reset-instances");t.each(p,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=t(this.element.prop("form")),!!this.form.length){var c=this.form.data("ui-form-reset-instances")||[];c.length||this.form.on("reset.ui-form-reset",this._formResetHandler),c.push(this),this.form.data("ui-form-reset-instances",c)}},_unbindFormResetHandler:function(){if(this.form.length){var c=this.form.data("ui-form-reset-instances");c.splice(t.inArray(this,c),1),c.length?this.form.data("ui-form-reset-instances",c):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}};/*!
 * jQuery UI Legacy jQuery Core patches 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 *
 */t.escapeSelector||(t.escapeSelector=function(c){return CSS.escape(c+"")}),(!t.fn.even||!t.fn.odd)&&t.fn.extend({even:function(){return this.filter(function(c){return c%2===0})},odd:function(){return this.filter(function(c){return c%2===1})}});/*!
 * jQuery UI Keycode 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38};/*!
 * jQuery UI Labels 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.fn.labels=function(){var c,p,x,S,b;return this.length?this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(S=this.eq(0).parents("label"),x=this.attr("id"),x&&(c=this.eq(0).parents().last(),b=c.add(c.length?c.siblings():this.siblings()),p="label[for='"+CSS.escape(x)+"']",S=S.add(b.find(p).addBack(p))),this.pushStack(S)):this.pushStack([])};/*!
 * jQuery UI Scroll Parent 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.fn.scrollParent=function(c){var p=this.css("position"),x=p==="absolute",S=c?/(auto|scroll|hidden)/:/(auto|scroll)/,b=this.parents().filter(function(){var h=t(this);return x&&h.css("position")==="static"?!1:S.test(h.css("overflow")+h.css("overflow-y")+h.css("overflow-x"))}).eq(0);return p==="fixed"||!b.length?t(this[0].ownerDocument||document):b};/*!
 * jQuery UI Tabbable 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.extend(t.expr.pseudos,{tabbable:function(c){var p=t.attr(c,"tabindex"),x=p!=null;return(!x||p>=0)&&t.ui.focusable(c,x)}});/*!
 * jQuery UI Unique ID 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.fn.extend({uniqueId:function(){var c=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++c)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}});/*!
 * jQuery UI Accordion 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.accordion",{version:"1.14.0",options:{active:0,animate:{},classes:{"ui-accordion-header":"ui-corner-top","ui-accordion-header-collapsed":"ui-corner-all","ui-accordion-content":"ui-corner-bottom"},collapsible:!1,event:"click",header:function(c){return c.find("> li > :first-child").add(c.find("> :not(li)").filter(function(p){return p%2===0}))},heightStyle:"auto",icons:{activeHeader:"ui-icon-triangle-1-s",header:"ui-icon-triangle-1-e"},activate:null,beforeActivate:null},hideProps:{borderTopWidth:"hide",borderBottomWidth:"hide",paddingTop:"hide",paddingBottom:"hide",height:"hide"},showProps:{borderTopWidth:"show",borderBottomWidth:"show",paddingTop:"show",paddingBottom:"show",height:"show"},_create:function(){var c=this.options;this.prevShow=this.prevHide=t(),this._addClass("ui-accordion","ui-widget ui-helper-reset"),this.element.attr("role","tablist"),!c.collapsible&&(c.active===!1||c.active==null)&&(c.active=0),this._processPanels(),c.active<0&&(c.active+=this.headers.length),this._refresh()},_getCreateEventData:function(){return{header:this.active,panel:this.active.length?this.active.next():t()}},_createIcons:function(){var c,p,x=this.options.icons;x&&(c=t("<span>"),this._addClass(c,"ui-accordion-header-icon","ui-icon "+x.header),c.prependTo(this.headers),p=this.active.children(".ui-accordion-header-icon"),this._removeClass(p,x.header)._addClass(p,null,x.activeHeader)._addClass(this.headers,"ui-accordion-icons"))},_destroyIcons:function(){this._removeClass(this.headers,"ui-accordion-icons"),this.headers.children(".ui-accordion-header-icon").remove()},_destroy:function(){var c;this.element.removeAttr("role"),this.headers.removeAttr("role aria-expanded aria-selected aria-controls tabIndex").removeUniqueId(),this._destroyIcons(),c=this.headers.next().css("display","").removeAttr("role aria-hidden aria-labelledby").removeUniqueId(),this.options.heightStyle!=="content"&&c.css("height","")},_setOption:function(c,p){if(c==="active"){this._activate(p);return}c==="event"&&(this.options.event&&this._off(this.headers,this.options.event),this._setupEvents(p)),this._super(c,p),c==="collapsible"&&!p&&this.options.active===!1&&this._activate(0),c==="icons"&&(this._destroyIcons(),p&&this._createIcons())},_setOptionDisabled:function(c){this._super(c),this.element.attr("aria-disabled",c),this._toggleClass(null,"ui-state-disabled",!!c)},_keydown:function(c){if(!(c.altKey||c.ctrlKey)){var p=t.ui.keyCode,x=this.headers.length,S=this.headers.index(c.target),b=!1;switch(c.keyCode){case p.RIGHT:case p.DOWN:b=this.headers[(S+1)%x];break;case p.LEFT:case p.UP:b=this.headers[(S-1+x)%x];break;case p.SPACE:case p.ENTER:this._eventHandler(c);break;case p.HOME:b=this.headers[0];break;case p.END:b=this.headers[x-1];break}b&&(t(c.target).attr("tabIndex",-1),t(b).attr("tabIndex",0),t(b).trigger("focus"),c.preventDefault())}},_panelKeyDown:function(c){c.keyCode===t.ui.keyCode.UP&&c.ctrlKey&&t(c.currentTarget).prev().trigger("focus")},refresh:function(){var c=this.options;this._processPanels(),c.active===!1&&c.collapsible===!0||!this.headers.length?(c.active=!1,this.active=t()):c.active===!1?this._activate(0):this.active.length&&!t.contains(this.element[0],this.active[0])?this.headers.length===this.headers.find(".ui-state-disabled").length?(c.active=!1,this.active=t()):this._activate(Math.max(0,c.active-1)):c.active=this.headers.index(this.active),this._destroyIcons(),this._refresh()},_processPanels:function(){var c=this.headers,p=this.panels;typeof this.options.header=="function"?this.headers=this.options.header(this.element):this.headers=this.element.find(this.options.header),this._addClass(this.headers,"ui-accordion-header ui-accordion-header-collapsed","ui-state-default"),this.panels=this.headers.next().filter(":not(.ui-accordion-content-active)").hide(),this._addClass(this.panels,"ui-accordion-content","ui-helper-reset ui-widget-content"),p&&(this._off(c.not(this.headers)),this._off(p.not(this.panels)))},_refresh:function(){var c,p=this.options,x=p.heightStyle,S=this.element.parent();this.active=this._findActive(p.active),this._addClass(this.active,"ui-accordion-header-active","ui-state-active")._removeClass(this.active,"ui-accordion-header-collapsed"),this._addClass(this.active.next(),"ui-accordion-content-active"),this.active.next().show(),this.headers.attr("role","tab").each(function(){var b=t(this),h=b.uniqueId().attr("id"),T=b.next(),M=T.uniqueId().attr("id");b.attr("aria-controls",M),T.attr("aria-labelledby",h)}).next().attr("role","tabpanel"),this.headers.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}).next().attr({"aria-hidden":"true"}).hide(),this.active.length?this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}).next().attr({"aria-hidden":"false"}):this.headers.eq(0).attr("tabIndex",0),this._createIcons(),this._setupEvents(p.event),x==="fill"?(c=S.height(),this.element.siblings(":visible").each(function(){var b=t(this),h=b.css("position");h==="absolute"||h==="fixed"||(c-=b.outerHeight(!0))}),this.headers.each(function(){c-=t(this).outerHeight(!0)}),this.headers.next().each(function(){t(this).height(Math.max(0,c-t(this).innerHeight()+t(this).height()))}).css("overflow","auto")):x==="auto"&&(c=0,this.headers.next().each(function(){var b=t(this).is(":visible");b||t(this).show(),c=Math.max(c,t(this).css("height","").height()),b||t(this).hide()}).height(c))},_activate:function(c){var p=this._findActive(c)[0];p!==this.active[0]&&(p=p||this.active[0],this._eventHandler({target:p,currentTarget:p,preventDefault:t.noop}))},_findActive:function(c){return typeof c=="number"?this.headers.eq(c):t()},_setupEvents:function(c){var p={keydown:"_keydown"};c&&t.each(c.split(" "),function(x,S){p[S]="_eventHandler"}),this._off(this.headers.add(this.headers.next())),this._on(this.headers,p),this._on(this.headers.next(),{keydown:"_panelKeyDown"}),this._hoverable(this.headers),this._focusable(this.headers)},_eventHandler:function(c){var p,x,S=this.options,b=this.active,h=t(c.currentTarget),T=h[0]===b[0],M=T&&S.collapsible,O=M?t():h.next(),V=b.next(),ee={oldHeader:b,oldPanel:V,newHeader:M?t():h,newPanel:O};c.preventDefault(),!(T&&!S.collapsible||this._trigger("beforeActivate",c,ee)===!1)&&(S.active=M?!1:this.headers.index(h),this.active=T?t():h,this._toggle(ee),this._removeClass(b,"ui-accordion-header-active","ui-state-active"),S.icons&&(p=b.children(".ui-accordion-header-icon"),this._removeClass(p,null,S.icons.activeHeader)._addClass(p,null,S.icons.header)),T||(this._removeClass(h,"ui-accordion-header-collapsed")._addClass(h,"ui-accordion-header-active","ui-state-active"),S.icons&&(x=h.children(".ui-accordion-header-icon"),this._removeClass(x,null,S.icons.header)._addClass(x,null,S.icons.activeHeader)),this._addClass(h.next(),"ui-accordion-content-active")))},_toggle:function(c){var p=c.newPanel,x=this.prevShow.length?this.prevShow:c.oldPanel;this.prevShow.add(this.prevHide).stop(!0,!0),this.prevShow=p,this.prevHide=x,this.options.animate?this._animate(p,x,c):(x.hide(),p.show(),this._toggleComplete(c)),x.attr({"aria-hidden":"true"}),x.prev().attr({"aria-selected":"false","aria-expanded":"false"}),p.length&&x.length?x.prev().attr({tabIndex:-1,"aria-expanded":"false"}):p.length&&this.headers.filter(function(){return parseInt(t(this).attr("tabIndex"),10)===0}).attr("tabIndex",-1),p.attr("aria-hidden","false").prev().attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_animate:function(c,p,x){var S,b,h,T=this,M=0,O=c.css("box-sizing"),V=c.length&&(!p.length||c.index()<p.index()),ee=this.options.animate||{},Z=V&&ee.down||ee,U=function(){T._toggleComplete(x)};if(typeof Z=="number"&&(h=Z),typeof Z=="string"&&(b=Z),b=b||Z.easing||ee.easing,h=h||Z.duration||ee.duration,!p.length)return c.animate(this.showProps,h,b,U);if(!c.length)return p.animate(this.hideProps,h,b,U);S=c.show().outerHeight(),p.animate(this.hideProps,{duration:h,easing:b,step:function(z,ne){ne.now=Math.round(z)}}),c.hide().animate(this.showProps,{duration:h,easing:b,complete:U,step:function(z,ne){ne.now=Math.round(z),ne.prop!=="height"?O==="content-box"&&(M+=ne.now):T.options.heightStyle!=="content"&&(ne.now=Math.round(S-p.outerHeight()-M),M=0)}})},_toggleComplete:function(c){var p=c.oldPanel,x=p.prev();this._removeClass(p,"ui-accordion-content-active"),this._removeClass(x,"ui-accordion-header-active")._addClass(x,"ui-accordion-header-collapsed"),this._trigger("activate",null,c)}});/*!
 * jQuery UI Menu 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.menu",{version:"1.14.0",defaultElement:"<ul>",delay:300,options:{icons:{submenu:"ui-icon-caret-1-e"},items:"> *",menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element,this.mouseHandled=!1,this.lastMousePosition={x:null,y:null},this.element.uniqueId().attr({role:this.options.role,tabIndex:0}),this._addClass("ui-menu","ui-widget ui-widget-content"),this._on({"mousedown .ui-menu-item":function(c){c.preventDefault(),this._activateItem(c)},"click .ui-menu-item":function(c){var p=t(c.target),x=t(this.document[0].activeElement);!this.mouseHandled&&p.not(".ui-state-disabled").length&&(this.select(c),c.isPropagationStopped()||(this.mouseHandled=!0),p.has(".ui-menu").length?this.expand(c):!this.element.is(":focus")&&x.closest(".ui-menu").length&&(this.element.trigger("focus",[!0]),this.active&&this.active.parents(".ui-menu").length===1&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":"_activateItem","mousemove .ui-menu-item":"_activateItem",mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(c,p){var x=this.active||this._menuItems().first();p||this.focus(c,x)},blur:function(c){this._delay(function(){var p=!t.contains(this.element[0],this.document[0].activeElement);p&&this.collapseAll(c)})},keydown:"_keydown"}),this.refresh(),this._on(this.document,{click:function(c){this._closeOnDocumentClick(c)&&this.collapseAll(c,!0),this.mouseHandled=!1}})},_activateItem:function(c){if(!this.previousFilter&&!(c.clientX===this.lastMousePosition.x&&c.clientY===this.lastMousePosition.y)){this.lastMousePosition={x:c.clientX,y:c.clientY};var p=t(c.target).closest(".ui-menu-item"),x=t(c.currentTarget);p[0]===x[0]&&(x.is(".ui-state-active")||(this._removeClass(x.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(c,x)))}},_destroy:function(){var c=this.element.find(".ui-menu-item").removeAttr("role aria-disabled"),p=c.children(".ui-menu-item-wrapper").removeUniqueId().removeAttr("tabIndex role aria-haspopup");this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeAttr("role aria-labelledby aria-expanded aria-hidden aria-disabled tabIndex").removeUniqueId().show(),p.children().each(function(){var x=t(this);x.data("ui-menu-submenu-caret")&&x.remove()})},_keydown:function(c){var p,x,S,b,h=!0;switch(c.keyCode){case t.ui.keyCode.PAGE_UP:this.previousPage(c);break;case t.ui.keyCode.PAGE_DOWN:this.nextPage(c);break;case t.ui.keyCode.HOME:this._move("first","first",c);break;case t.ui.keyCode.END:this._move("last","last",c);break;case t.ui.keyCode.UP:this.previous(c);break;case t.ui.keyCode.DOWN:this.next(c);break;case t.ui.keyCode.LEFT:this.collapse(c);break;case t.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(c);break;case t.ui.keyCode.ENTER:case t.ui.keyCode.SPACE:this._activate(c);break;case t.ui.keyCode.ESCAPE:this.collapse(c);break;default:h=!1,x=this.previousFilter||"",b=!1,S=c.keyCode>=96&&c.keyCode<=105?(c.keyCode-96).toString():String.fromCharCode(c.keyCode),clearTimeout(this.filterTimer),S===x?b=!0:S=x+S,p=this._filterMenuItems(S),p=b&&p.index(this.active.next())!==-1?this.active.nextAll(".ui-menu-item"):p,p.length||(S=String.fromCharCode(c.keyCode),p=this._filterMenuItems(S)),p.length?(this.focus(c,p),this.previousFilter=S,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter}h&&c.preventDefault()},_activate:function(c){this.active&&!this.active.is(".ui-state-disabled")&&(this.active.children("[aria-haspopup='true']").length?this.expand(c):this.select(c))},refresh:function(){var c,p,x,S,b,h=this,T=this.options.icons.submenu,M=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,!!this.element.find(".ui-icon").length),x=M.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var O=t(this),V=O.prev(),ee=t("<span>").data("ui-menu-submenu-caret",!0);h._addClass(ee,"ui-menu-icon","ui-icon "+T),V.attr("aria-haspopup","true").prepend(ee),O.attr("aria-labelledby",V.attr("id"))}),this._addClass(x,"ui-menu","ui-widget ui-widget-content ui-front"),c=M.add(this.element),p=c.find(this.options.items),p.not(".ui-menu-item").each(function(){var O=t(this);h._isDivider(O)&&h._addClass(O,"ui-menu-divider","ui-widget-content")}),S=p.not(".ui-menu-item, .ui-menu-divider"),b=S.children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()}),this._addClass(S,"ui-menu-item")._addClass(b,"ui-menu-item-wrapper"),p.filter(".ui-state-disabled").attr("aria-disabled","true"),this.active&&!t.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(c,p){if(c==="icons"){var x=this.element.find(".ui-menu-icon");this._removeClass(x,null,this.options.icons.submenu)._addClass(x,null,p.submenu)}this._super(c,p)},_setOptionDisabled:function(c){this._super(c),this.element.attr("aria-disabled",String(c)),this._toggleClass(null,"ui-state-disabled",!!c)},focus:function(c,p){var x,S,b;this.blur(c,c&&c.type==="focus"),this._scrollIntoView(p),this.active=p.first(),S=this.active.children(".ui-menu-item-wrapper"),this._addClass(S,null,"ui-state-active"),this.options.role&&this.element.attr("aria-activedescendant",S.attr("id")),b=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper"),this._addClass(b,null,"ui-state-active"),c&&c.type==="keydown"?this._close():this.timer=this._delay(function(){this._close()},this.delay),x=p.children(".ui-menu"),x.length&&c&&/^mouse/.test(c.type)&&this._startOpening(x),this.activeMenu=p.parent(),this._trigger("focus",c,{item:p})},_scrollIntoView:function(c){var p,x,S,b,h,T;this._hasScroll()&&(p=parseFloat(t.css(this.activeMenu[0],"borderTopWidth"))||0,x=parseFloat(t.css(this.activeMenu[0],"paddingTop"))||0,S=c.offset().top-this.activeMenu.offset().top-p-x,b=this.activeMenu.scrollTop(),h=this.activeMenu.height(),T=c.outerHeight(),S<0?this.activeMenu.scrollTop(b+S):S+T>h&&this.activeMenu.scrollTop(b+S-h+T))},blur:function(c,p){p||clearTimeout(this.timer),this.active&&(this._removeClass(this.active.children(".ui-menu-item-wrapper"),null,"ui-state-active"),this._trigger("blur",c,{item:this.active}),this.active=null)},_startOpening:function(c){clearTimeout(this.timer),c.attr("aria-hidden")==="true"&&(this.timer=this._delay(function(){this._close(),this._open(c)},this.delay))},_open:function(c){var p=t.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(".ui-menu").not(c.parents(".ui-menu")).hide().attr("aria-hidden","true"),c.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(p)},collapseAll:function(c,p){clearTimeout(this.timer),this.timer=this._delay(function(){var x=p?this.element:t(c&&c.target).closest(this.element.find(".ui-menu"));x.length||(x=this.element),this._close(x),this.blur(c),this._removeClass(x.find(".ui-state-active"),null,"ui-state-active"),this.activeMenu=x},p?0:this.delay)},_close:function(c){c||(c=this.active?this.active.parent():this.element),c.find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false")},_closeOnDocumentClick:function(c){return!t(c.target).closest(".ui-menu").length},_isDivider:function(c){return!/[^\-\u2014\u2013\s]/.test(c.text())},collapse:function(c){var p=this.active&&this.active.parent().closest(".ui-menu-item",this.element);p&&p.length&&(this._close(),this.focus(c,p))},expand:function(c){var p=this.active&&this._menuItems(this.active.children(".ui-menu")).first();p&&p.length&&(this._open(p.parent()),this._delay(function(){this.focus(c,p)}))},next:function(c){this._move("next","first",c)},previous:function(c){this._move("prev","last",c)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_menuItems:function(c){return(c||this.element).find(this.options.items).filter(".ui-menu-item")},_move:function(c,p,x){var S;this.active&&(c==="first"||c==="last"?S=this.active[c==="first"?"prevAll":"nextAll"](".ui-menu-item").last():S=this.active[c+"All"](".ui-menu-item").first()),(!S||!S.length||!this.active)&&(S=this._menuItems(this.activeMenu)[p]()),this.focus(x,S)},nextPage:function(c){var p,x,S;if(!this.active){this.next(c);return}this.isLastItem()||(this._hasScroll()?(x=this.active.offset().top,S=this.element.innerHeight(),t.fn.jquery.indexOf("3.2.")===0&&(S+=this.element[0].offsetHeight-this.element.outerHeight()),this.active.nextAll(".ui-menu-item").each(function(){return p=t(this),p.offset().top-x-S<0}),this.focus(c,p)):this.focus(c,this._menuItems(this.activeMenu)[this.active?"last":"first"]()))},previousPage:function(c){var p,x,S;if(!this.active){this.next(c);return}this.isFirstItem()||(this._hasScroll()?(x=this.active.offset().top,S=this.element.innerHeight(),t.fn.jquery.indexOf("3.2.")===0&&(S+=this.element[0].offsetHeight-this.element.outerHeight()),this.active.prevAll(".ui-menu-item").each(function(){return p=t(this),p.offset().top-x+S>0}),this.focus(c,p)):this.focus(c,this._menuItems(this.activeMenu).first()))},_hasScroll:function(){return this.element.outerHeight()<this.element.prop("scrollHeight")},select:function(c){this.active=this.active||t(c.target).closest(".ui-menu-item");var p={item:this.active};this.active.has(".ui-menu").length||this.collapseAll(c,!0),this._trigger("select",c,p)},_filterMenuItems:function(c){var p=c.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&"),x=new RegExp("^"+p,"i");return this.activeMenu.find(this.options.items).filter(".ui-menu-item").filter(function(){return x.test(String.prototype.trim.call(t(this).children(".ui-menu-item-wrapper").text()))})}});/*!
 * jQuery UI Autocomplete 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.autocomplete",{version:"1.14.0",defaultElement:"<input>",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,liveRegionTimer:null,_create:function(){var c,p,x,S=this.element[0].nodeName.toLowerCase(),b=S==="textarea",h=S==="input";this.isMultiLine=b||!h&&this.element.prop("contentEditable")==="true",this.valueMethod=this.element[b||h?"val":"text"],this.isNewMenu=!0,this._addClass("ui-autocomplete-input"),this.element.attr("autocomplete","off"),this._on(this.element,{keydown:function(T){if(this.element.prop("readOnly")){c=!0,x=!0,p=!0;return}c=!1,x=!1,p=!1;var M=t.ui.keyCode;switch(T.keyCode){case M.PAGE_UP:c=!0,this._move("previousPage",T);break;case M.PAGE_DOWN:c=!0,this._move("nextPage",T);break;case M.UP:c=!0,this._keyEvent("previous",T);break;case M.DOWN:c=!0,this._keyEvent("next",T);break;case M.ENTER:this.menu.active&&(c=!0,T.preventDefault(),this.menu.select(T));break;case M.TAB:this.menu.active&&this.menu.select(T);break;case M.ESCAPE:this.menu.element.is(":visible")&&(this.isMultiLine||this._value(this.term),this.close(T),T.preventDefault());break;default:p=!0,this._searchTimeout(T);break}},keypress:function(T){if(c){c=!1,(!this.isMultiLine||this.menu.element.is(":visible"))&&T.preventDefault();return}if(!p){var M=t.ui.keyCode;switch(T.keyCode){case M.PAGE_UP:this._move("previousPage",T);break;case M.PAGE_DOWN:this._move("nextPage",T);break;case M.UP:this._keyEvent("previous",T);break;case M.DOWN:this._keyEvent("next",T);break}}},input:function(T){if(x){x=!1,T.preventDefault();return}this._searchTimeout(T)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(T){clearTimeout(this.searching),this.close(T),this._change(T)}}),this._initSource(),this.menu=t("<ul>").appendTo(this._appendTo()).menu({role:null}).hide().menu("instance"),this._addClass(this.menu.element,"ui-autocomplete","ui-front"),this._on(this.menu.element,{mousedown:function(T){T.preventDefault()},menufocus:function(T,M){var O,V;if(this.isNewMenu&&(this.isNewMenu=!1,T.originalEvent&&/^mouse/.test(T.originalEvent.type))){this.menu.blur(),this.document.one("mousemove",function(){t(T.target).trigger(T.originalEvent)});return}V=M.item.data("ui-autocomplete-item"),this._trigger("focus",T,{item:V})!==!1&&T.originalEvent&&/^key/.test(T.originalEvent.type)&&this._value(V.value),O=M.item.attr("aria-label")||V.value,O&&String.prototype.trim.call(O).length&&(clearTimeout(this.liveRegionTimer),this.liveRegionTimer=this._delay(function(){this.liveRegion.html(t("<div>").text(O))},100))},menuselect:function(T,M){var O=M.item.data("ui-autocomplete-item"),V=this.previous;this.element[0]!==this.document[0].activeElement&&(this.element.trigger("focus"),this.previous=V),this._trigger("select",T,{item:O})!==!1&&this._value(O.value),this.term=this._value(),this.close(T),this.selectedItem=O}}),this.liveRegion=t("<div>",{role:"status","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body),this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible"),this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_destroy:function(){clearTimeout(this.searching),this.element.removeAttr("autocomplete"),this.menu.element.remove(),this.liveRegion.remove()},_setOption:function(c,p){this._super(c,p),c==="source"&&this._initSource(),c==="appendTo"&&this.menu.element.appendTo(this._appendTo()),c==="disabled"&&p&&this.xhr&&this.xhr.abort()},_isEventTargetInWidget:function(c){var p=this.menu.element[0];return c.target===this.element[0]||c.target===p||t.contains(p,c.target)},_closeOnClickOutside:function(c){this._isEventTargetInWidget(c)||this.close()},_appendTo:function(){var c=this.options.appendTo;return c&&(c=c.jquery||c.nodeType?t(c):this.document.find(c).eq(0)),(!c||!c[0])&&(c=this.element.closest(".ui-front, dialog")),c.length||(c=this.document[0].body),c},_initSource:function(){var c,p,x=this;Array.isArray(this.options.source)?(c=this.options.source,this.source=function(S,b){b(t.ui.autocomplete.filter(c,S.term))}):typeof this.options.source=="string"?(p=this.options.source,this.source=function(S,b){x.xhr&&x.xhr.abort(),x.xhr=t.ajax({url:p,data:S,dataType:"json",success:function(h){b(h)},error:function(){b([])}})}):this.source=this.options.source},_searchTimeout:function(c){clearTimeout(this.searching),this.searching=this._delay(function(){var p=this.term===this._value(),x=this.menu.element.is(":visible"),S=c.altKey||c.ctrlKey||c.metaKey||c.shiftKey;(!p||p&&!x&&!S)&&(this.selectedItem=null,this.search(null,c))},this.options.delay)},search:function(c,p){if(c=c??this._value(),this.term=this._value(),c.length<this.options.minLength)return this.close(p);if(this._trigger("search",p)!==!1)return this._search(c)},_search:function(c){this.pending++,this._addClass("ui-autocomplete-loading"),this.cancelSearch=!1,this.source({term:c},this._response())},_response:function(){var c=++this.requestIndex;return(function(p){c===this.requestIndex&&this.__response(p),this.pending--,this.pending||this._removeClass("ui-autocomplete-loading")}).bind(this)},__response:function(c){c&&(c=this._normalize(c)),this._trigger("response",null,{content:c}),!this.options.disabled&&c&&c.length&&!this.cancelSearch?(this._suggest(c),this._trigger("open")):this._close()},close:function(c){this.cancelSearch=!0,this._close(c)},_close:function(c){this._off(this.document,"mousedown"),this.menu.element.is(":visible")&&(this.menu.element.hide(),this.menu.blur(),this.isNewMenu=!0,this._trigger("close",c))},_change:function(c){this.previous!==this._value()&&this._trigger("change",c,{item:this.selectedItem})},_normalize:function(c){return c.length&&c[0].label&&c[0].value?c:t.map(c,function(p){return typeof p=="string"?{label:p,value:p}:t.extend({},p,{label:p.label||p.value,value:p.value||p.label})})},_suggest:function(c){var p=this.menu.element.empty();this._renderMenu(p,c),this.isNewMenu=!0,this.menu.refresh(),p.show(),this._resizeMenu(),p.position(t.extend({of:this.element},this.options.position)),this.options.autoFocus&&this.menu.next(),this._on(this.document,{mousedown:"_closeOnClickOutside"})},_resizeMenu:function(){var c=this.menu.element;c.outerWidth(Math.max(c.width("").outerWidth()+1,this.element.outerWidth()))},_renderMenu:function(c,p){var x=this;t.each(p,function(S,b){x._renderItemData(c,b)})},_renderItemData:function(c,p){return this._renderItem(c,p).data("ui-autocomplete-item",p)},_renderItem:function(c,p){return t("<li>").append(t("<div>").text(p.label)).appendTo(c)},_move:function(c,p){if(!this.menu.element.is(":visible")){this.search(null,p);return}if(this.menu.isFirstItem()&&/^previous/.test(c)||this.menu.isLastItem()&&/^next/.test(c)){this.isMultiLine||this._value(this.term),this.menu.blur();return}this.menu[c](p)},widget:function(){return this.menu.element},_value:function(){return this.valueMethod.apply(this.element,arguments)},_keyEvent:function(c,p){(!this.isMultiLine||this.menu.element.is(":visible"))&&(this._move(c,p),p.preventDefault())}}),t.extend(t.ui.autocomplete,{escapeRegex:function(c){return c.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")},filter:function(c,p){var x=new RegExp(t.ui.autocomplete.escapeRegex(p),"i");return t.grep(c,function(S){return x.test(S.label||S.value||S)})}}),t.widget("ui.autocomplete",t.ui.autocomplete,{options:{messages:{noResults:"No search results.",results:function(c){return c+(c>1?" results are":" result is")+" available, use up and down arrow keys to navigate."}}},__response:function(c){var p;this._superApply(arguments),!(this.options.disabled||this.cancelSearch)&&(c&&c.length?p=this.options.messages.results(c.length):p=this.options.messages.noResults,clearTimeout(this.liveRegionTimer),this.liveRegionTimer=this._delay(function(){this.liveRegion.html(t("<div>").text(p))},100))}}),t.ui.autocomplete;/*!
 * jQuery UI Controlgroup 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */var ue=/ui-corner-([a-z]){2,6}/g;t.widget("ui.controlgroup",{version:"1.14.0",defaultElement:"<div>",options:{direction:"horizontal",disabled:null,onlyVisible:!0,items:{button:"input[type=button], input[type=submit], input[type=reset], button, a",controlgroupLabel:".ui-controlgroup-label",checkboxradio:"input[type='checkbox'], input[type='radio']",selectmenu:"select",spinner:".ui-spinner-input"}},_create:function(){this._enhance()},_enhance:function(){this.element.attr("role","toolbar"),this.refresh()},_destroy:function(){this._callChildMethod("destroy"),this.childWidgets.removeData("ui-controlgroup-data"),this.element.removeAttr("role"),this.options.items.controlgroupLabel&&this.element.find(this.options.items.controlgroupLabel).find(".ui-controlgroup-label-contents").contents().unwrap()},_initWidgets:function(){var c=this,p=[];t.each(this.options.items,function(x,S){var b,h={};if(S){if(x==="controlgroupLabel"){b=c.element.find(S),b.each(function(){var T=t(this);T.children(".ui-controlgroup-label-contents").length||T.contents().wrapAll("<span class='ui-controlgroup-label-contents'></span>")}),c._addClass(b,null,"ui-widget ui-widget-content ui-state-default"),p=p.concat(b.get());return}t.fn[x]&&(c["_"+x+"Options"]?h=c["_"+x+"Options"]("middle"):h={classes:{}},c.element.find(S).each(function(){var T=t(this),M=T[x]("instance"),O=t.widget.extend({},h);if(!(x==="button"&&T.parent(".ui-spinner").length)){M||(M=T[x]()[x]("instance")),M&&(O.classes=c._resolveClassesValues(O.classes,M)),T[x](O);var V=T[x]("widget");t.data(V[0],"ui-controlgroup-data",M||T[x]("instance")),p.push(V[0])}}))}}),this.childWidgets=t(t.uniqueSort(p)),this._addClass(this.childWidgets,"ui-controlgroup-item")},_callChildMethod:function(c){this.childWidgets.each(function(){var p=t(this),x=p.data("ui-controlgroup-data");x&&x[c]&&x[c]()})},_updateCornerClass:function(c,p){var x="ui-corner-top ui-corner-bottom ui-corner-left ui-corner-right ui-corner-all",S=this._buildSimpleOptions(p,"label").classes.label;this._removeClass(c,null,x),this._addClass(c,null,S)},_buildSimpleOptions:function(c,p){var x=this.options.direction==="vertical",S={classes:{}};return S.classes[p]={middle:"",first:"ui-corner-"+(x?"top":"left"),last:"ui-corner-"+(x?"bottom":"right"),only:"ui-corner-all"}[c],S},_spinnerOptions:function(c){var p=this._buildSimpleOptions(c,"ui-spinner");return p.classes["ui-spinner-up"]="",p.classes["ui-spinner-down"]="",p},_buttonOptions:function(c){return this._buildSimpleOptions(c,"ui-button")},_checkboxradioOptions:function(c){return this._buildSimpleOptions(c,"ui-checkboxradio-label")},_selectmenuOptions:function(c){var p=this.options.direction==="vertical";return{width:p?"auto":!1,classes:{middle:{"ui-selectmenu-button-open":"","ui-selectmenu-button-closed":""},first:{"ui-selectmenu-button-open":"ui-corner-"+(p?"top":"tl"),"ui-selectmenu-button-closed":"ui-corner-"+(p?"top":"left")},last:{"ui-selectmenu-button-open":p?"":"ui-corner-tr","ui-selectmenu-button-closed":"ui-corner-"+(p?"bottom":"right")},only:{"ui-selectmenu-button-open":"ui-corner-top","ui-selectmenu-button-closed":"ui-corner-all"}}[c]}},_resolveClassesValues:function(c,p){var x={};return t.each(c,function(S){var b=p.options.classes[S]||"";b=String.prototype.trim.call(b.replace(ue,"")),x[S]=(b+" "+c[S]).replace(/\s+/g," ")}),x},_setOption:function(c,p){if(c==="direction"&&this._removeClass("ui-controlgroup-"+this.options.direction),this._super(c,p),c==="disabled"){this._callChildMethod(p?"disable":"enable");return}this.refresh()},refresh:function(){var c,p=this;this._addClass("ui-controlgroup ui-controlgroup-"+this.options.direction),this.options.direction==="horizontal"&&this._addClass(null,"ui-helper-clearfix"),this._initWidgets(),c=this.childWidgets,this.options.onlyVisible&&(c=c.filter(":visible")),c.length&&(t.each(["first","last"],function(x,S){var b=c[S]().data("ui-controlgroup-data");if(b&&p["_"+b.widgetName+"Options"]){var h=p["_"+b.widgetName+"Options"](c.length===1?"only":S);h.classes=p._resolveClassesValues(h.classes,b),b.element[b.widgetName](h)}else p._updateCornerClass(c[S](),S)}),this._callChildMethod("refresh"))}});/*!
 * jQuery UI Checkboxradio 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.checkboxradio",[t.ui.formResetMixin,{version:"1.14.0",options:{disabled:null,label:null,icon:!0,classes:{"ui-checkboxradio-label":"ui-corner-all","ui-checkboxradio-icon":"ui-corner-all"}},_getCreateOptions:function(){var c,p,x,S=this._super()||{};return this._readType(),p=this.element.labels(),this.label=t(p[p.length-1]),this.label.length||t.error("No label found for checkboxradio widget"),this.originalLabel="",x=this.label.contents().not(this.element[0]),x.length&&(this.originalLabel+=x.clone().wrapAll("<div></div>").parent().html()),this.originalLabel&&(S.label=this.originalLabel),c=this.element[0].disabled,c!=null&&(S.disabled=c),S},_create:function(){var c=this.element[0].checked;this._bindFormResetHandler(),this.options.disabled==null&&(this.options.disabled=this.element[0].disabled),this._setOption("disabled",this.options.disabled),this._addClass("ui-checkboxradio","ui-helper-hidden-accessible"),this._addClass(this.label,"ui-checkboxradio-label","ui-button ui-widget"),this.type==="radio"&&this._addClass(this.label,"ui-checkboxradio-radio-label"),this.options.label&&this.options.label!==this.originalLabel?this._updateLabel():this.originalLabel&&(this.options.label=this.originalLabel),this._enhance(),c&&this._addClass(this.label,"ui-checkboxradio-checked","ui-state-active"),this._on({change:"_toggleClasses",focus:function(){this._addClass(this.label,null,"ui-state-focus ui-visual-focus")},blur:function(){this._removeClass(this.label,null,"ui-state-focus ui-visual-focus")}})},_readType:function(){var c=this.element[0].nodeName.toLowerCase();this.type=this.element[0].type,(c!=="input"||!/radio|checkbox/.test(this.type))&&t.error("Can't create checkboxradio on element.nodeName="+c+" and element.type="+this.type)},_enhance:function(){this._updateIcon(this.element[0].checked)},widget:function(){return this.label},_getRadioGroup:function(){var c,p=this.element[0].name,x="input[name='"+CSS.escape(p)+"']";return p?(this.form.length?c=t(this.form[0].elements).filter(x):c=t(x).filter(function(){return t(t(this).prop("form")).length===0}),c.not(this.element)):t([])},_toggleClasses:function(){var c=this.element[0].checked;this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",c),this.options.icon&&this.type==="checkbox"&&this._toggleClass(this.icon,null,"ui-icon-check ui-state-checked",c)._toggleClass(this.icon,null,"ui-icon-blank",!c),this.type==="radio"&&this._getRadioGroup().each(function(){var p=t(this).checkboxradio("instance");p&&p._removeClass(p.label,"ui-checkboxradio-checked","ui-state-active")})},_destroy:function(){this._unbindFormResetHandler(),this.icon&&(this.icon.remove(),this.iconSpace.remove())},_setOption:function(c,p){if(!(c==="label"&&!p)){if(this._super(c,p),c==="disabled"){this._toggleClass(this.label,null,"ui-state-disabled",p),this.element[0].disabled=p;return}this.refresh()}},_updateIcon:function(c){var p="ui-icon ui-icon-background ";this.options.icon?(this.icon||(this.icon=t("<span>"),this.iconSpace=t("<span> </span>"),this._addClass(this.iconSpace,"ui-checkboxradio-icon-space")),this.type==="checkbox"?(p+=c?"ui-icon-check ui-state-checked":"ui-icon-blank",this._removeClass(this.icon,null,c?"ui-icon-blank":"ui-icon-check")):p+="ui-icon-blank",this._addClass(this.icon,"ui-checkboxradio-icon",p),c||this._removeClass(this.icon,null,"ui-icon-check ui-state-checked"),this.icon.prependTo(this.label).after(this.iconSpace)):this.icon!==void 0&&(this.icon.remove(),this.iconSpace.remove(),delete this.icon)},_updateLabel:function(){var c=this.label.contents().not(this.element[0]);this.icon&&(c=c.not(this.icon[0])),this.iconSpace&&(c=c.not(this.iconSpace[0])),c.remove(),this.label.append(this.options.label)},refresh:function(){var c=this.element[0].checked,p=this.element[0].disabled;this._updateIcon(c),this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",c),this.options.label!==null&&this._updateLabel(),p!==this.options.disabled&&this._setOptions({disabled:p})}}]),t.ui.checkboxradio;/*!
 * jQuery UI Button 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.button",{version:"1.14.0",defaultElement:"<button>",options:{classes:{"ui-button":"ui-corner-all"},disabled:null,icon:null,iconPosition:"beginning",label:null,showLabel:!0},_getCreateOptions:function(){var c,p=this._super()||{};return this.isInput=this.element.is("input"),c=this.element[0].disabled,c!=null&&(p.disabled=c),this.originalLabel=this.isInput?this.element.val():this.element.html(),this.originalLabel&&(p.label=this.originalLabel),p},_create:function(){!this.option.showLabel&!this.options.icon&&(this.options.showLabel=!0),this.options.disabled==null&&(this.options.disabled=this.element[0].disabled||!1),this.hasTitle=!!this.element.attr("title"),this.options.label&&this.options.label!==this.originalLabel&&(this.isInput?this.element.val(this.options.label):this.element.html(this.options.label)),this._addClass("ui-button","ui-widget"),this._setOption("disabled",this.options.disabled),this._enhance(),this.element.is("a")&&this._on({keyup:function(c){c.keyCode===t.ui.keyCode.SPACE&&(c.preventDefault(),this.element[0].click?this.element[0].click():this.element.trigger("click"))}})},_enhance:function(){this.element.is("button")||this.element.attr("role","button"),this.options.icon&&(this._updateIcon("icon",this.options.icon),this._updateTooltip())},_updateTooltip:function(){this.title=this.element.attr("title"),!this.options.showLabel&&!this.title&&this.element.attr("title",this.options.label)},_updateIcon:function(c,p){var x=c!=="iconPosition",S=x?this.options.iconPosition:p,b=S==="top"||S==="bottom";this.icon?x&&this._removeClass(this.icon,null,this.options.icon):(this.icon=t("<span>"),this._addClass(this.icon,"ui-button-icon","ui-icon"),this.options.showLabel||this._addClass("ui-button-icon-only")),x&&this._addClass(this.icon,null,p),this._attachIcon(S),b?(this._addClass(this.icon,null,"ui-widget-icon-block"),this.iconSpace&&this.iconSpace.remove()):(this.iconSpace||(this.iconSpace=t("<span> </span>"),this._addClass(this.iconSpace,"ui-button-icon-space")),this._removeClass(this.icon,null,"ui-wiget-icon-block"),this._attachIconSpace(S))},_destroy:function(){this.element.removeAttr("role"),this.icon&&this.icon.remove(),this.iconSpace&&this.iconSpace.remove(),this.hasTitle||this.element.removeAttr("title")},_attachIconSpace:function(c){this.icon[/^(?:end|bottom)/.test(c)?"before":"after"](this.iconSpace)},_attachIcon:function(c){this.element[/^(?:end|bottom)/.test(c)?"append":"prepend"](this.icon)},_setOptions:function(c){var p=c.showLabel===void 0?this.options.showLabel:c.showLabel,x=c.icon===void 0?this.options.icon:c.icon;!p&&!x&&(c.showLabel=!0),this._super(c)},_setOption:function(c,p){c==="icon"&&(p?this._updateIcon(c,p):this.icon&&(this.icon.remove(),this.iconSpace&&this.iconSpace.remove())),c==="iconPosition"&&this._updateIcon(c,p),c==="showLabel"&&(this._toggleClass("ui-button-icon-only",null,!p),this._updateTooltip()),c==="label"&&(this.isInput?this.element.val(p):(this.element.html(p),this.icon&&(this._attachIcon(this.options.iconPosition),this._attachIconSpace(this.options.iconPosition)))),this._super(c,p),c==="disabled"&&(this._toggleClass(null,"ui-state-disabled",p),this.element[0].disabled=p,p&&this.element.trigger("blur"))},refresh:function(){var c=this.element.is("input, button")?this.element[0].disabled:this.element.hasClass("ui-button-disabled");c!==this.options.disabled&&this._setOptions({disabled:c}),this._updateTooltip()}}),t.uiBackCompat===!0&&(t.widget("ui.button",t.ui.button,{options:{text:!0,icons:{primary:null,secondary:null}},_create:function(){this.options.showLabel&&!this.options.text&&(this.options.showLabel=this.options.text),!this.options.showLabel&&this.options.text&&(this.options.text=this.options.showLabel),!this.options.icon&&(this.options.icons.primary||this.options.icons.secondary)?this.options.icons.primary?this.options.icon=this.options.icons.primary:(this.options.icon=this.options.icons.secondary,this.options.iconPosition="end"):this.options.icon&&(this.options.icons.primary=this.options.icon),this._super()},_setOption:function(c,p){if(c==="text"){this._super("showLabel",p);return}c==="showLabel"&&(this.options.text=p),c==="icon"&&(this.options.icons.primary=p),c==="icons"&&(p.primary?(this._super("icon",p.primary),this._super("iconPosition","beginning")):p.secondary&&(this._super("icon",p.secondary),this._super("iconPosition","end"))),this._superApply(arguments)}}),t.fn.button=function(c){return function(p){var x=typeof p=="string",S=Array.prototype.slice.call(arguments,1),b=this;return x?!this.length&&p==="instance"?b=void 0:this.each(function(){var h,T=t(this).attr("type"),M=T!=="checkbox"&&T!=="radio"?"button":"checkboxradio",O=t.data(this,"ui-"+M);if(p==="instance")return b=O,!1;if(!O)return t.error("cannot call methods on button prior to initialization; attempted to call method '"+p+"'");if(typeof O[p]!="function"||p.charAt(0)==="_")return t.error("no such method '"+p+"' for button widget instance");if(h=O[p].apply(O,S),h!==O&&h!==void 0)return b=h&&h.jquery?b.pushStack(h.get()):h,!1}):(S.length&&(p=t.widget.extend.apply(null,[p].concat(S))),this.each(function(){var h=t(this).attr("type"),T=h!=="checkbox"&&h!=="radio"?"button":"checkboxradio",M=t.data(this,"ui-"+T);if(M)M.option(p||{}),M._init&&M._init();else{if(T==="button"){c.call(t(this),p);return}t(this).checkboxradio(t.extend({icon:!1},p))}})),b}}(t.fn.button),t.fn.buttonset=function(){return t.ui.controlgroup||t.error("Controlgroup widget missing"),arguments[0]==="option"&&arguments[1]==="items"&&arguments[2]?this.controlgroup.apply(this,[arguments[0],"items.button",arguments[2]]):arguments[0]==="option"&&arguments[1]==="items"?this.controlgroup.apply(this,[arguments[0],"items.button"]):(typeof arguments[0]=="object"&&arguments[0].items&&(arguments[0].items={button:arguments[0].items}),this.controlgroup.apply(this,arguments))}),t.ui.button;/*!
 * jQuery UI Datepicker 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.extend(t.ui,{datepicker:{version:"1.14.0"}});var Q;function ce(c){for(var p,x;c.length&&c[0]!==document;){if(p=c.css("position"),(p==="absolute"||p==="relative"||p==="fixed")&&(x=parseInt(c.css("zIndex"),10),!isNaN(x)&&x!==0))return x;c=c.parent()}return 0}function he(){this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId="ui-datepicker-div",this._inlineClass="ui-datepicker-inline",this._appendClass="ui-datepicker-append",this._triggerClass="ui-datepicker-trigger",this._dialogClass="ui-datepicker-dialog",this._disableClass="ui-datepicker-disabled",this._unselectableClass="ui-datepicker-unselectable",this._currentClass="ui-datepicker-current-day",this._dayOverClass="ui-datepicker-days-cell-over",this.regional=[],this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:"",selectMonthLabel:"Select month",selectYearLabel:"Select year"},this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,onUpdateDatepicker:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},t.extend(this._defaults,this.regional[""]),this.regional.en=t.extend(!0,{},this.regional[""]),this.regional["en-US"]=t.extend(!0,{},this.regional.en),this.dpDiv=ke(t("<div id='"+this._mainDivId+"' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>"))}t.extend(he.prototype,{markerClassName:"hasDatepicker",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(c){return d(this._defaults,c||{}),this},_attachDatepicker:function(c,p){var x,S,b;x=c.nodeName.toLowerCase(),S=x==="div"||x==="span",c.id||(this.uuid+=1,c.id="dp"+this.uuid),b=this._newInst(t(c),S),b.settings=t.extend({},p||{}),x==="input"?this._connectDatepicker(c,b):S&&this._inlineDatepicker(c,b)},_newInst:function(c,p){var x=c[0].id.replace(/([^A-Za-z0-9_\-])/g,"\\\\$1");return{id:x,input:c,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:p,dpDiv:p?ke(t("<div class='"+this._inlineClass+" ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>")):this.dpDiv}},_connectDatepicker:function(c,p){var x=t(c);p.append=t([]),p.trigger=t([]),!x.hasClass(this.markerClassName)&&(this._attachments(x,p),x.addClass(this.markerClassName).on("keydown",this._doKeyDown).on("keypress",this._doKeyPress).on("keyup",this._doKeyUp),this._autoSize(p),t.data(c,"datepicker",p),p.settings.disabled&&this._disableDatepicker(c))},_attachments:function(c,p){var x,S,b,h=this._get(p,"appendText"),T=this._get(p,"isRTL");p.append&&p.append.remove(),h&&(p.append=t("<span>").addClass(this._appendClass).text(h),c[T?"before":"after"](p.append)),c.off("focus",this._showDatepicker),p.trigger&&p.trigger.remove(),x=this._get(p,"showOn"),(x==="focus"||x==="both")&&c.on("focus",this._showDatepicker),(x==="button"||x==="both")&&(S=this._get(p,"buttonText"),b=this._get(p,"buttonImage"),this._get(p,"buttonImageOnly")?p.trigger=t("<img>").addClass(this._triggerClass).attr({src:b,alt:S,title:S}):(p.trigger=t("<button type='button'>").addClass(this._triggerClass),b?p.trigger.html(t("<img>").attr({src:b,alt:S,title:S})):p.trigger.text(S)),c[T?"before":"after"](p.trigger),p.trigger.on("click",function(){return t.datepicker._datepickerShowing&&t.datepicker._lastInput===c[0]?t.datepicker._hideDatepicker():(t.datepicker._datepickerShowing&&t.datepicker._lastInput!==c[0]&&t.datepicker._hideDatepicker(),t.datepicker._showDatepicker(c[0])),!1}))},_autoSize:function(c){if(this._get(c,"autoSize")&&!c.inline){var p,x,S,b,h=new Date(2009,11,20),T=this._get(c,"dateFormat");T.match(/[DM]/)&&(p=function(M){for(x=0,S=0,b=0;b<M.length;b++)M[b].length>x&&(x=M[b].length,S=b);return S},h.setMonth(p(this._get(c,T.match(/MM/)?"monthNames":"monthNamesShort"))),h.setDate(p(this._get(c,T.match(/DD/)?"dayNames":"dayNamesShort"))+20-h.getDay())),c.input.attr("size",this._formatDate(c,h).length)}},_inlineDatepicker:function(c,p){var x=t(c);x.hasClass(this.markerClassName)||(x.addClass(this.markerClassName).append(p.dpDiv),t.data(c,"datepicker",p),this._setDate(p,this._getDefaultDate(p),!0),this._updateDatepicker(p),this._updateAlternate(p),p.settings.disabled&&this._disableDatepicker(c),p.dpDiv.css("display","block"))},_dialogDatepicker:function(c,p,x,S,b){var h,T,M,O,V,ee=this._dialogInst;return ee||(this.uuid+=1,h="dp"+this.uuid,this._dialogInput=t("<input type='text' id='"+h+"' style='position: absolute; top: -100px; width: 0px;'/>"),this._dialogInput.on("keydown",this._doKeyDown),t("body").append(this._dialogInput),ee=this._dialogInst=this._newInst(this._dialogInput,!1),ee.settings={},t.data(this._dialogInput[0],"datepicker",ee)),d(ee.settings,S||{}),p=p&&p.constructor===Date?this._formatDate(ee,p):p,this._dialogInput.val(p),this._pos=b?b.length?b:[b.pageX,b.pageY]:null,this._pos||(T=document.documentElement.clientWidth,M=document.documentElement.clientHeight,O=document.documentElement.scrollLeft||document.body.scrollLeft,V=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[T/2-100+O,M/2-150+V]),this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),ee.settings.onSelect=x,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),t.blockUI&&t.blockUI(this.dpDiv),t.data(this._dialogInput[0],"datepicker",ee),this},_destroyDatepicker:function(c){var p,x=t(c),S=t.data(c,"datepicker");x.hasClass(this.markerClassName)&&(p=c.nodeName.toLowerCase(),t.removeData(c,"datepicker"),p==="input"?(S.append.remove(),S.trigger.remove(),x.removeClass(this.markerClassName).off("focus",this._showDatepicker).off("keydown",this._doKeyDown).off("keypress",this._doKeyPress).off("keyup",this._doKeyUp)):(p==="div"||p==="span")&&x.removeClass(this.markerClassName).empty(),t.datepicker._hideDatepicker(),Q===S&&(Q=null,this._curInst=null))},_enableDatepicker:function(c){var p,x,S=t(c),b=t.data(c,"datepicker");S.hasClass(this.markerClassName)&&(p=c.nodeName.toLowerCase(),p==="input"?(c.disabled=!1,b.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""})):(p==="div"||p==="span")&&(x=S.children("."+this._inlineClass),x.children().removeClass("ui-state-disabled"),x.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!1)),this._disabledInputs=t.map(this._disabledInputs,function(h){return h===c?null:h}))},_disableDatepicker:function(c){var p,x,S=t(c),b=t.data(c,"datepicker");S.hasClass(this.markerClassName)&&(p=c.nodeName.toLowerCase(),p==="input"?(c.disabled=!0,b.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"})):(p==="div"||p==="span")&&(x=S.children("."+this._inlineClass),x.children().addClass("ui-state-disabled"),x.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!0)),this._disabledInputs=t.map(this._disabledInputs,function(h){return h===c?null:h}),this._disabledInputs[this._disabledInputs.length]=c)},_isDisabledDatepicker:function(c){if(!c)return!1;for(var p=0;p<this._disabledInputs.length;p++)if(this._disabledInputs[p]===c)return!0;return!1},_getInst:function(c){try{return t.data(c,"datepicker")}catch{throw"Missing instance data for this datepicker"}},_optionDatepicker:function(c,p,x){var S,b,h,T,M=this._getInst(c);if(arguments.length===2&&typeof p=="string")return p==="defaults"?t.extend({},t.datepicker._defaults):M?p==="all"?t.extend({},M.settings):this._get(M,p):null;S=p||{},typeof p=="string"&&(S={},S[p]=x),M&&(this._curInst===M&&this._hideDatepicker(),b=this._getDateDatepicker(c,!0),h=this._getMinMaxDate(M,"min"),T=this._getMinMaxDate(M,"max"),d(M.settings,S),h!==null&&S.dateFormat!==void 0&&S.minDate===void 0&&(M.settings.minDate=this._formatDate(M,h)),T!==null&&S.dateFormat!==void 0&&S.maxDate===void 0&&(M.settings.maxDate=this._formatDate(M,T)),"disabled"in S&&(S.disabled?this._disableDatepicker(c):this._enableDatepicker(c)),this._attachments(t(c),M),this._autoSize(M),this._setDate(M,b),this._updateAlternate(M),this._updateDatepicker(M))},_changeDatepicker:function(c,p,x){this._optionDatepicker(c,p,x)},_refreshDatepicker:function(c){var p=this._getInst(c);p&&this._updateDatepicker(p)},_setDateDatepicker:function(c,p){var x=this._getInst(c);x&&(this._setDate(x,p),this._updateDatepicker(x),this._updateAlternate(x))},_getDateDatepicker:function(c,p){var x=this._getInst(c);return x&&!x.inline&&this._setDateFromField(x,p),x?this._getDate(x):null},_doKeyDown:function(c){var p,x,S,b=t.datepicker._getInst(c.target),h=!0,T=b.dpDiv.is(".ui-datepicker-rtl");if(b._keyEvent=!0,t.datepicker._datepickerShowing)switch(c.keyCode){case 9:t.datepicker._hideDatepicker(),h=!1;break;case 13:return S=t("td."+t.datepicker._dayOverClass+":not(."+t.datepicker._currentClass+")",b.dpDiv),S[0]&&t.datepicker._selectDay(c.target,b.selectedMonth,b.selectedYear,S[0]),p=t.datepicker._get(b,"onSelect"),p?(x=t.datepicker._formatDate(b),p.apply(b.input?b.input[0]:null,[x,b])):t.datepicker._hideDatepicker(),!1;case 27:t.datepicker._hideDatepicker();break;case 33:t.datepicker._adjustDate(c.target,c.ctrlKey?-t.datepicker._get(b,"stepBigMonths"):-t.datepicker._get(b,"stepMonths"),"M");break;case 34:t.datepicker._adjustDate(c.target,c.ctrlKey?+t.datepicker._get(b,"stepBigMonths"):+t.datepicker._get(b,"stepMonths"),"M");break;case 35:(c.ctrlKey||c.metaKey)&&t.datepicker._clearDate(c.target),h=c.ctrlKey||c.metaKey;break;case 36:(c.ctrlKey||c.metaKey)&&t.datepicker._gotoToday(c.target),h=c.ctrlKey||c.metaKey;break;case 37:(c.ctrlKey||c.metaKey)&&t.datepicker._adjustDate(c.target,T?1:-1,"D"),h=c.ctrlKey||c.metaKey,c.originalEvent.altKey&&t.datepicker._adjustDate(c.target,c.ctrlKey?-t.datepicker._get(b,"stepBigMonths"):-t.datepicker._get(b,"stepMonths"),"M");break;case 38:(c.ctrlKey||c.metaKey)&&t.datepicker._adjustDate(c.target,-7,"D"),h=c.ctrlKey||c.metaKey;break;case 39:(c.ctrlKey||c.metaKey)&&t.datepicker._adjustDate(c.target,T?-1:1,"D"),h=c.ctrlKey||c.metaKey,c.originalEvent.altKey&&t.datepicker._adjustDate(c.target,c.ctrlKey?+t.datepicker._get(b,"stepBigMonths"):+t.datepicker._get(b,"stepMonths"),"M");break;case 40:(c.ctrlKey||c.metaKey)&&t.datepicker._adjustDate(c.target,7,"D"),h=c.ctrlKey||c.metaKey;break;default:h=!1}else c.keyCode===36&&c.ctrlKey?t.datepicker._showDatepicker(this):h=!1;h&&(c.preventDefault(),c.stopPropagation())},_doKeyPress:function(c){var p,x,S=t.datepicker._getInst(c.target);if(t.datepicker._get(S,"constrainInput"))return p=t.datepicker._possibleChars(t.datepicker._get(S,"dateFormat")),x=String.fromCharCode(c.charCode==null?c.keyCode:c.charCode),c.ctrlKey||c.metaKey||x<" "||!p||p.indexOf(x)>-1},_doKeyUp:function(c){var p,x=t.datepicker._getInst(c.target);if(x.input.val()!==x.lastVal)try{p=t.datepicker.parseDate(t.datepicker._get(x,"dateFormat"),x.input?x.input.val():null,t.datepicker._getFormatConfig(x)),p&&(t.datepicker._setDateFromField(x),t.datepicker._updateAlternate(x),t.datepicker._updateDatepicker(x))}catch{}return!0},_showDatepicker:function(c){if(c=c.target||c,c.nodeName.toLowerCase()!=="input"&&(c=t("input",c.parentNode)[0]),!(t.datepicker._isDisabledDatepicker(c)||t.datepicker._lastInput===c)){var p,x,S,b,h,T,M;p=t.datepicker._getInst(c),t.datepicker._curInst&&t.datepicker._curInst!==p&&(t.datepicker._curInst.dpDiv.stop(!0,!0),p&&t.datepicker._datepickerShowing&&t.datepicker._hideDatepicker(t.datepicker._curInst.input[0])),x=t.datepicker._get(p,"beforeShow"),S=x?x.apply(c,[c,p]):{},S!==!1&&(d(p.settings,S),p.lastVal=null,t.datepicker._lastInput=c,t.datepicker._setDateFromField(p),t.datepicker._inDialog&&(c.value=""),t.datepicker._pos||(t.datepicker._pos=t.datepicker._findPos(c),t.datepicker._pos[1]+=c.offsetHeight),b=!1,t(c).parents().each(function(){return b|=t(this).css("position")==="fixed",!b}),h={left:t.datepicker._pos[0],top:t.datepicker._pos[1]},t.datepicker._pos=null,p.dpDiv.empty(),p.dpDiv.css({position:"absolute",display:"block",top:"-1000px"}),t.datepicker._updateDatepicker(p),h=t.datepicker._checkOffset(p,h,b),p.dpDiv.css({position:t.datepicker._inDialog&&t.blockUI?"static":b?"fixed":"absolute",display:"none",left:h.left+"px",top:h.top+"px"}),p.inline||(T=t.datepicker._get(p,"showAnim"),M=t.datepicker._get(p,"duration"),p.dpDiv.css("z-index",ce(t(c))+1),t.datepicker._datepickerShowing=!0,t.effects&&t.effects.effect[T]?p.dpDiv.show(T,t.datepicker._get(p,"showOptions"),M):p.dpDiv[T||"show"](T?M:null),t.datepicker._shouldFocusInput(p)&&p.input.trigger("focus"),t.datepicker._curInst=p))}},_updateDatepicker:function(c){this.maxRows=4,Q=c,c.dpDiv.empty().append(this._generateHTML(c)),this._attachHandlers(c);var p,x=this._getNumberOfMonths(c),S=x[1],b=17,h=c.dpDiv.find("."+this._dayOverClass+" a"),T=t.datepicker._get(c,"onUpdateDatepicker");h.length>0&&L.apply(h.get(0)),c.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width(""),S>1&&c.dpDiv.addClass("ui-datepicker-multi-"+S).css("width",b*S+"em"),c.dpDiv[(x[0]!==1||x[1]!==1?"add":"remove")+"Class"]("ui-datepicker-multi"),c.dpDiv[(this._get(c,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl"),c===t.datepicker._curInst&&t.datepicker._datepickerShowing&&t.datepicker._shouldFocusInput(c)&&c.input.trigger("focus"),c.yearshtml&&(p=c.yearshtml,setTimeout(function(){p===c.yearshtml&&c.yearshtml&&c.dpDiv.find("select.ui-datepicker-year").first().replaceWith(c.yearshtml),p=c.yearshtml=null},0)),T&&T.apply(c.input?c.input[0]:null,[c])},_shouldFocusInput:function(c){return c.input&&c.input.is(":visible")&&!c.input.is(":disabled")},_checkOffset:function(c,p,x){var S=c.dpDiv.outerWidth(),b=c.dpDiv.outerHeight(),h=c.input?c.input.outerWidth():0,T=c.input?c.input.outerHeight():0,M=document.documentElement.clientWidth+(x?0:t(document).scrollLeft()),O=document.documentElement.clientHeight+(x?0:t(document).scrollTop());return p.left-=this._get(c,"isRTL")?S-h:0,p.left-=x&&p.left===c.input.offset().left?t(document).scrollLeft():0,p.top-=x&&p.top===c.input.offset().top+T?t(document).scrollTop():0,p.left-=Math.min(p.left,p.left+S>M&&M>S?Math.abs(p.left+S-M):0),p.top-=Math.min(p.top,p.top+b>O&&O>b?Math.abs(b+T):0),p},_findPos:function(c){for(var p,x=this._getInst(c),S=this._get(x,"isRTL");c&&(c.type==="hidden"||c.nodeType!==1||t.expr.pseudos.hidden(c));)c=c[S?"previousSibling":"nextSibling"];return p=t(c).offset(),[p.left,p.top]},_hideDatepicker:function(c){var p,x,S,b,h=this._curInst;!h||c&&h!==t.data(c,"datepicker")||this._datepickerShowing&&(p=this._get(h,"showAnim"),x=this._get(h,"duration"),S=function(){t.datepicker._tidyDialog(h)},t.effects&&t.effects.effect[p]?h.dpDiv.hide(p,t.datepicker._get(h,"showOptions"),x,S):h.dpDiv[p==="slideDown"?"slideUp":p==="fadeIn"?"fadeOut":"hide"](p?x:null,S),p||S(),this._datepickerShowing=!1,b=this._get(h,"onClose"),b&&b.apply(h.input?h.input[0]:null,[h.input?h.input.val():"",h]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:"absolute",left:"0",top:"-100px"}),t.blockUI&&(t.unblockUI(),t("body").append(this.dpDiv))),this._inDialog=!1)},_tidyDialog:function(c){c.dpDiv.removeClass(this._dialogClass).off(".ui-datepicker-calendar")},_checkExternalClick:function(c){if(t.datepicker._curInst){var p=t(c.target),x=t.datepicker._getInst(p[0]);(p[0].id!==t.datepicker._mainDivId&&p.parents("#"+t.datepicker._mainDivId).length===0&&!p.hasClass(t.datepicker.markerClassName)&&!p.closest("."+t.datepicker._triggerClass).length&&t.datepicker._datepickerShowing&&!(t.datepicker._inDialog&&t.blockUI)||p.hasClass(t.datepicker.markerClassName)&&t.datepicker._curInst!==x)&&t.datepicker._hideDatepicker()}},_adjustDate:function(c,p,x){var S=t(c),b=this._getInst(S[0]);this._isDisabledDatepicker(S[0])||(this._adjustInstDate(b,p,x),this._updateDatepicker(b))},_gotoToday:function(c){var p,x=t(c),S=this._getInst(x[0]);this._get(S,"gotoCurrent")&&S.currentDay?(S.selectedDay=S.currentDay,S.drawMonth=S.selectedMonth=S.currentMonth,S.drawYear=S.selectedYear=S.currentYear):(p=new Date,S.selectedDay=p.getDate(),S.drawMonth=S.selectedMonth=p.getMonth(),S.drawYear=S.selectedYear=p.getFullYear()),this._notifyChange(S),this._adjustDate(x)},_selectMonthYear:function(c,p,x){var S=t(c),b=this._getInst(S[0]);b["selected"+(x==="M"?"Month":"Year")]=b["draw"+(x==="M"?"Month":"Year")]=parseInt(p.options[p.selectedIndex].value,10),this._notifyChange(b),this._adjustDate(S)},_selectDay:function(c,p,x,S){var b,h=t(c);t(S).hasClass(this._unselectableClass)||this._isDisabledDatepicker(h[0])||(b=this._getInst(h[0]),b.selectedDay=b.currentDay=parseInt(t("a",S).attr("data-date")),b.selectedMonth=b.currentMonth=p,b.selectedYear=b.currentYear=x,this._selectDate(c,this._formatDate(b,b.currentDay,b.currentMonth,b.currentYear)))},_clearDate:function(c){var p=t(c);this._selectDate(p,"")},_selectDate:function(c,p){var x,S=t(c),b=this._getInst(S[0]);p=p??this._formatDate(b),b.input&&b.input.val(p),this._updateAlternate(b),x=this._get(b,"onSelect"),x?x.apply(b.input?b.input[0]:null,[p,b]):b.input&&b.input.trigger("change"),b.inline?this._updateDatepicker(b):(this._hideDatepicker(),this._lastInput=b.input[0],typeof b.input[0]!="object"&&b.input.trigger("focus"),this._lastInput=null)},_updateAlternate:function(c){var p,x,S,b=this._get(c,"altField");b&&(p=this._get(c,"altFormat")||this._get(c,"dateFormat"),x=this._getDate(c),S=this.formatDate(p,x,this._getFormatConfig(c)),t(document).find(b).val(S))},noWeekends:function(c){var p=c.getDay();return[p>0&&p<6,""]},iso8601Week:function(c){var p,x=new Date(c.getTime());return x.setDate(x.getDate()+4-(x.getDay()||7)),p=x.getTime(),x.setMonth(0),x.setDate(1),Math.floor(Math.round((p-x)/864e5)/7)+1},parseDate:function(c,p,x){if(c==null||p==null)throw"Invalid arguments";if(p=typeof p=="object"?p.toString():p+"",p==="")return null;var S,b,h,T=0,M=(x?x.shortYearCutoff:null)||this._defaults.shortYearCutoff,O=typeof M!="string"?M:new Date().getFullYear()%100+parseInt(M,10),V=(x?x.dayNamesShort:null)||this._defaults.dayNamesShort,ee=(x?x.dayNames:null)||this._defaults.dayNames,Z=(x?x.monthNamesShort:null)||this._defaults.monthNamesShort,U=(x?x.monthNames:null)||this._defaults.monthNames,z=-1,ne=-1,fe=-1,me=-1,de=!1,je,lt=function(nt){var Je=S+1<c.length&&c.charAt(S+1)===nt;return Je&&S++,Je},it=function(nt){var Je=lt(nt),tt=nt==="@"?14:nt==="!"?20:nt==="y"&&Je?4:nt==="o"?3:2,rt=nt==="y"?tt:1,ht=new RegExp("^\\d{"+rt+","+tt+"}"),Ot=p.substring(T).match(ht);if(!Ot)throw"Missing number at position "+T;return T+=Ot[0].length,parseInt(Ot[0],10)},ot=function(nt,Je,tt){var rt=-1,ht=t.map(lt(nt)?tt:Je,function(Ot,Ve){return[[Ve,Ot]]}).sort(function(Ot,Ve){return-(Ot[1].length-Ve[1].length)});if(t.each(ht,function(Ot,Ve){var We=Ve[1];if(p.substr(T,We.length).toLowerCase()===We.toLowerCase())return rt=Ve[0],T+=We.length,!1}),rt!==-1)return rt+1;throw"Unknown name at position "+T},Ct=function(){if(p.charAt(T)!==c.charAt(S))throw"Unexpected literal at position "+T;T++};for(S=0;S<c.length;S++)if(de)c.charAt(S)==="'"&&!lt("'")?de=!1:Ct();else switch(c.charAt(S)){case"d":fe=it("d");break;case"D":ot("D",V,ee);break;case"o":me=it("o");break;case"m":ne=it("m");break;case"M":ne=ot("M",Z,U);break;case"y":z=it("y");break;case"@":je=new Date(it("@")),z=je.getFullYear(),ne=je.getMonth()+1,fe=je.getDate();break;case"!":je=new Date((it("!")-this._ticksTo1970)/1e4),z=je.getFullYear(),ne=je.getMonth()+1,fe=je.getDate();break;case"'":lt("'")?Ct():de=!0;break;default:Ct()}if(T<p.length&&(h=p.substr(T),!/^\s+/.test(h)))throw"Extra/unparsed characters found in date: "+h;if(z===-1?z=new Date().getFullYear():z<100&&(z+=new Date().getFullYear()-new Date().getFullYear()%100+(z<=O?0:-100)),me>-1){ne=1,fe=me;do{if(b=this._getDaysInMonth(z,ne-1),fe<=b)break;ne++,fe-=b}while(!0)}if(je=this._daylightSavingAdjust(new Date(z,ne-1,fe)),je.getFullYear()!==z||je.getMonth()+1!==ne||je.getDate()!==fe)throw"Invalid date";return je},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TICKS:"!",TIMESTAMP:"@",W3C:"yy-mm-dd",_ticksTo1970:(1969*365+Math.floor(1970/4)-Math.floor(1970/100)+Math.floor(1970/400))*24*60*60*1e7,formatDate:function(c,p,x){if(!p)return"";var S,b=(x?x.dayNamesShort:null)||this._defaults.dayNamesShort,h=(x?x.dayNames:null)||this._defaults.dayNames,T=(x?x.monthNamesShort:null)||this._defaults.monthNamesShort,M=(x?x.monthNames:null)||this._defaults.monthNames,O=function(z){var ne=S+1<c.length&&c.charAt(S+1)===z;return ne&&S++,ne},V=function(z,ne,fe){var me=""+ne;if(O(z))for(;me.length<fe;)me="0"+me;return me},ee=function(z,ne,fe,me){return O(z)?me[ne]:fe[ne]},Z="",U=!1;if(p)for(S=0;S<c.length;S++)if(U)c.charAt(S)==="'"&&!O("'")?U=!1:Z+=c.charAt(S);else switch(c.charAt(S)){case"d":Z+=V("d",p.getDate(),2);break;case"D":Z+=ee("D",p.getDay(),b,h);break;case"o":Z+=V("o",Math.round((new Date(p.getFullYear(),p.getMonth(),p.getDate()).getTime()-new Date(p.getFullYear(),0,0).getTime())/864e5),3);break;case"m":Z+=V("m",p.getMonth()+1,2);break;case"M":Z+=ee("M",p.getMonth(),T,M);break;case"y":Z+=O("y")?p.getFullYear():(p.getFullYear()%100<10?"0":"")+p.getFullYear()%100;break;case"@":Z+=p.getTime();break;case"!":Z+=p.getTime()*1e4+this._ticksTo1970;break;case"'":O("'")?Z+="'":U=!0;break;default:Z+=c.charAt(S)}return Z},_possibleChars:function(c){var p,x="",S=!1,b=function(h){var T=p+1<c.length&&c.charAt(p+1)===h;return T&&p++,T};for(p=0;p<c.length;p++)if(S)c.charAt(p)==="'"&&!b("'")?S=!1:x+=c.charAt(p);else switch(c.charAt(p)){case"d":case"m":case"y":case"@":x+="0123456789";break;case"D":case"M":return null;case"'":b("'")?x+="'":S=!0;break;default:x+=c.charAt(p)}return x},_get:function(c,p){return c.settings[p]!==void 0?c.settings[p]:this._defaults[p]},_setDateFromField:function(c,p){if(c.input.val()!==c.lastVal){var x=this._get(c,"dateFormat"),S=c.lastVal=c.input?c.input.val():null,b=this._getDefaultDate(c),h=b,T=this._getFormatConfig(c);try{h=this.parseDate(x,S,T)||b}catch{S=p?"":S}c.selectedDay=h.getDate(),c.drawMonth=c.selectedMonth=h.getMonth(),c.drawYear=c.selectedYear=h.getFullYear(),c.currentDay=S?h.getDate():0,c.currentMonth=S?h.getMonth():0,c.currentYear=S?h.getFullYear():0,this._adjustInstDate(c)}},_getDefaultDate:function(c){return this._restrictMinMax(c,this._determineDate(c,this._get(c,"defaultDate"),new Date))},_determineDate:function(c,p,x){var S=function(T){var M=new Date;return M.setDate(M.getDate()+T),M},b=function(T){try{return t.datepicker.parseDate(t.datepicker._get(c,"dateFormat"),T,t.datepicker._getFormatConfig(c))}catch{}for(var M=(T.toLowerCase().match(/^c/)?t.datepicker._getDate(c):null)||new Date,O=M.getFullYear(),V=M.getMonth(),ee=M.getDate(),Z=/([+\-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,U=Z.exec(T);U;){switch(U[2]||"d"){case"d":case"D":ee+=parseInt(U[1],10);break;case"w":case"W":ee+=parseInt(U[1],10)*7;break;case"m":case"M":V+=parseInt(U[1],10),ee=Math.min(ee,t.datepicker._getDaysInMonth(O,V));break;case"y":case"Y":O+=parseInt(U[1],10),ee=Math.min(ee,t.datepicker._getDaysInMonth(O,V));break}U=Z.exec(T)}return new Date(O,V,ee)},h=p==null||p===""?x:typeof p=="string"?b(p):typeof p=="number"?isNaN(p)?x:S(p):new Date(p.getTime());return h=h&&h.toString()==="Invalid Date"?x:h,h&&(h.setHours(0),h.setMinutes(0),h.setSeconds(0),h.setMilliseconds(0)),this._daylightSavingAdjust(h)},_daylightSavingAdjust:function(c){return c?(c.setHours(c.getHours()>12?c.getHours()+2:0),c):null},_setDate:function(c,p,x){var S=!p,b=c.selectedMonth,h=c.selectedYear,T=this._restrictMinMax(c,this._determineDate(c,p,new Date));c.selectedDay=c.currentDay=T.getDate(),c.drawMonth=c.selectedMonth=c.currentMonth=T.getMonth(),c.drawYear=c.selectedYear=c.currentYear=T.getFullYear(),(b!==c.selectedMonth||h!==c.selectedYear)&&!x&&this._notifyChange(c),this._adjustInstDate(c),c.input&&c.input.val(S?"":this._formatDate(c))},_getDate:function(c){var p=!c.currentYear||c.input&&c.input.val()===""?null:this._daylightSavingAdjust(new Date(c.currentYear,c.currentMonth,c.currentDay));return p},_attachHandlers:function(c){var p=this._get(c,"stepMonths"),x="#"+c.id.replace(/\\\\/g,"\\");c.dpDiv.find("[data-handler]").map(function(){var S={prev:function(){t.datepicker._adjustDate(x,-p,"M")},next:function(){t.datepicker._adjustDate(x,+p,"M")},hide:function(){t.datepicker._hideDatepicker()},today:function(){t.datepicker._gotoToday(x)},selectDay:function(){return t.datepicker._selectDay(x,+this.getAttribute("data-month"),+this.getAttribute("data-year"),this),!1},selectMonth:function(){return t.datepicker._selectMonthYear(x,this,"M"),!1},selectYear:function(){return t.datepicker._selectMonthYear(x,this,"Y"),!1}};t(this).on(this.getAttribute("data-event"),S[this.getAttribute("data-handler")])})},_generateHTML:function(c){var p,x,S,b,h,T,M,O,V,ee,Z,U,z,ne,fe,me,de,je,lt,it,ot,Ct,nt,Je,tt,rt,ht,Ot,Ve,We,Gt,wt,Et,Yt,Ce,te,ye,Le,Ue,Qe=new Date,Ke=this._daylightSavingAdjust(new Date(Qe.getFullYear(),Qe.getMonth(),Qe.getDate())),De=this._get(c,"isRTL"),Vt=this._get(c,"showButtonPanel"),At=this._get(c,"hideIfNoPrevNext"),ve=this._get(c,"navigationAsDateFormat"),Pt=this._getNumberOfMonths(c),pt=this._get(c,"showCurrentAtPos"),Ne=this._get(c,"stepMonths"),vt=Pt[0]!==1||Pt[1]!==1,ut=this._daylightSavingAdjust(c.currentDay?new Date(c.currentYear,c.currentMonth,c.currentDay):new Date(9999,9,9)),$t=this._getMinMaxDate(c,"min"),fi=this._getMinMaxDate(c,"max"),kt=c.drawMonth-pt,Wt=c.drawYear;if(kt<0&&(kt+=12,Wt--),fi)for(p=this._daylightSavingAdjust(new Date(fi.getFullYear(),fi.getMonth()-Pt[0]*Pt[1]+1,fi.getDate())),p=$t&&p<$t?$t:p;this._daylightSavingAdjust(new Date(Wt,kt,1))>p;)kt--,kt<0&&(kt=11,Wt--);for(c.drawMonth=kt,c.drawYear=Wt,x=this._get(c,"prevText"),x=ve?this.formatDate(x,this._daylightSavingAdjust(new Date(Wt,kt-Ne,1)),this._getFormatConfig(c)):x,this._canAdjustMonth(c,-1,Wt,kt)?S=t("<a>").attr({class:"ui-datepicker-prev ui-corner-all","data-handler":"prev","data-event":"click",title:x}).append(t("<span>").addClass("ui-icon ui-icon-circle-triangle-"+(De?"e":"w")).text(x))[0].outerHTML:At?S="":S=t("<a>").attr({class:"ui-datepicker-prev ui-corner-all ui-state-disabled",title:x}).append(t("<span>").addClass("ui-icon ui-icon-circle-triangle-"+(De?"e":"w")).text(x))[0].outerHTML,b=this._get(c,"nextText"),b=ve?this.formatDate(b,this._daylightSavingAdjust(new Date(Wt,kt+Ne,1)),this._getFormatConfig(c)):b,this._canAdjustMonth(c,1,Wt,kt)?h=t("<a>").attr({class:"ui-datepicker-next ui-corner-all","data-handler":"next","data-event":"click",title:b}).append(t("<span>").addClass("ui-icon ui-icon-circle-triangle-"+(De?"w":"e")).text(b))[0].outerHTML:At?h="":h=t("<a>").attr({class:"ui-datepicker-next ui-corner-all ui-state-disabled",title:b}).append(t("<span>").attr("class","ui-icon ui-icon-circle-triangle-"+(De?"w":"e")).text(b))[0].outerHTML,T=this._get(c,"currentText"),M=this._get(c,"gotoCurrent")&&c.currentDay?ut:Ke,T=ve?this.formatDate(T,M,this._getFormatConfig(c)):T,O="",c.inline||(O=t("<button>").attr({type:"button",class:"ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all","data-handler":"hide","data-event":"click"}).text(this._get(c,"closeText"))[0].outerHTML),V="",Vt&&(V=t("<div class='ui-datepicker-buttonpane ui-widget-content'>").append(De?O:"").append(this._isInRange(c,M)?t("<button>").attr({type:"button",class:"ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all","data-handler":"today","data-event":"click"}).text(T):"").append(De?"":O)[0].outerHTML),ee=parseInt(this._get(c,"firstDay"),10),ee=isNaN(ee)?0:ee,Z=this._get(c,"showWeek"),U=this._get(c,"dayNames"),z=this._get(c,"dayNamesMin"),ne=this._get(c,"monthNames"),fe=this._get(c,"monthNamesShort"),me=this._get(c,"beforeShowDay"),de=this._get(c,"showOtherMonths"),je=this._get(c,"selectOtherMonths"),lt=this._getDefaultDate(c),it="",Ct=0;Ct<Pt[0];Ct++){for(nt="",this.maxRows=4,Je=0;Je<Pt[1];Je++){if(tt=this._daylightSavingAdjust(new Date(Wt,kt,c.selectedDay)),rt=" ui-corner-all",ht="",vt){if(ht+="<div class='ui-datepicker-group",Pt[1]>1)switch(Je){case 0:ht+=" ui-datepicker-group-first",rt=" ui-corner-"+(De?"right":"left");break;case Pt[1]-1:ht+=" ui-datepicker-group-last",rt=" ui-corner-"+(De?"left":"right");break;default:ht+=" ui-datepicker-group-middle",rt="";break}ht+="'>"}for(ht+="<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix"+rt+"'>"+(/all|left/.test(rt)&&Ct===0?De?h:S:"")+(/all|right/.test(rt)&&Ct===0?De?S:h:"")+this._generateMonthYearHeader(c,kt,Wt,$t,fi,Ct>0||Je>0,ne,fe)+"</div><table class='ui-datepicker-calendar'><thead><tr>",Ot=Z?"<th class='ui-datepicker-week-col'>"+this._get(c,"weekHeader")+"</th>":"",ot=0;ot<7;ot++)Ve=(ot+ee)%7,Ot+="<th scope='col'"+((ot+ee+6)%7>=5?" class='ui-datepicker-week-end'":"")+"><span title='"+U[Ve]+"'>"+z[Ve]+"</span></th>";for(ht+=Ot+"</tr></thead><tbody>",We=this._getDaysInMonth(Wt,kt),Wt===c.selectedYear&&kt===c.selectedMonth&&(c.selectedDay=Math.min(c.selectedDay,We)),Gt=(this._getFirstDayOfMonth(Wt,kt)-ee+7)%7,wt=Math.ceil((Gt+We)/7),Et=vt&&this.maxRows>wt?this.maxRows:wt,this.maxRows=Et,Yt=this._daylightSavingAdjust(new Date(Wt,kt,1-Gt)),Ce=0;Ce<Et;Ce++){for(ht+="<tr>",te=Z?"<td class='ui-datepicker-week-col'>"+this._get(c,"calculateWeek")(Yt)+"</td>":"",ot=0;ot<7;ot++)ye=me?me.apply(c.input?c.input[0]:null,[Yt]):[!0,""],Le=Yt.getMonth()!==kt,Ue=Le&&!je||!ye[0]||$t&&Yt<$t||fi&&Yt>fi,te+="<td class='"+((ot+ee+6)%7>=5?" ui-datepicker-week-end":"")+(Le?" ui-datepicker-other-month":"")+(Yt.getTime()===tt.getTime()&&kt===c.selectedMonth&&c._keyEvent||lt.getTime()===Yt.getTime()&&lt.getTime()===tt.getTime()?" "+this._dayOverClass:"")+(Ue?" "+this._unselectableClass+" ui-state-disabled":"")+(Le&&!de?"":" "+ye[1]+(Yt.getTime()===ut.getTime()?" "+this._currentClass:"")+(Yt.getTime()===Ke.getTime()?" ui-datepicker-today":""))+"'"+((!Le||de)&&ye[2]?" title='"+ye[2].replace(/'/g,"&#39;")+"'":"")+(Ue?"":" data-handler='selectDay' data-event='click' data-month='"+Yt.getMonth()+"' data-year='"+Yt.getFullYear()+"'")+">"+(Le&&!de?"&#xa0;":Ue?"<span class='ui-state-default'>"+Yt.getDate()+"</span>":"<a class='ui-state-default"+(Yt.getTime()===Ke.getTime()?" ui-state-highlight":"")+(Yt.getTime()===ut.getTime()?" ui-state-active":"")+(Le?" ui-priority-secondary":"")+"' href='#' aria-current='"+(Yt.getTime()===ut.getTime()?"true":"false")+"' data-date='"+Yt.getDate()+"'>"+Yt.getDate()+"</a>")+"</td>",Yt.setDate(Yt.getDate()+1),Yt=this._daylightSavingAdjust(Yt);ht+=te+"</tr>"}kt++,kt>11&&(kt=0,Wt++),ht+="</tbody></table>"+(vt?"</div>"+(Pt[0]>0&&Je===Pt[1]-1?"<div class='ui-datepicker-row-break'></div>":""):""),nt+=ht}it+=nt}return it+=V,c._keyEvent=!1,it},_generateMonthYearHeader:function(c,p,x,S,b,h,T,M){var O,V,ee,Z,U,z,ne,fe,me=this._get(c,"changeMonth"),de=this._get(c,"changeYear"),je=this._get(c,"showMonthAfterYear"),lt=this._get(c,"selectMonthLabel"),it=this._get(c,"selectYearLabel"),ot="<div class='ui-datepicker-title'>",Ct="";if(h||!me)Ct+="<span class='ui-datepicker-month'>"+T[p]+"</span>";else{for(O=S&&S.getFullYear()===x,V=b&&b.getFullYear()===x,Ct+="<select class='ui-datepicker-month' aria-label='"+lt+"' data-handler='selectMonth' data-event='change'>",ee=0;ee<12;ee++)(!O||ee>=S.getMonth())&&(!V||ee<=b.getMonth())&&(Ct+="<option value='"+ee+"'"+(ee===p?" selected='selected'":"")+">"+M[ee]+"</option>");Ct+="</select>"}if(je||(ot+=Ct+(h||!(me&&de)?"&#xa0;":"")),!c.yearshtml)if(c.yearshtml="",h||!de)ot+="<span class='ui-datepicker-year'>"+x+"</span>";else{for(Z=this._get(c,"yearRange").split(":"),U=new Date().getFullYear(),z=function(nt){var Je=nt.match(/c[+\-].*/)?x+parseInt(nt.substring(1),10):nt.match(/[+\-].*/)?U+parseInt(nt,10):parseInt(nt,10);return isNaN(Je)?U:Je},ne=z(Z[0]),fe=Math.max(ne,z(Z[1]||"")),ne=S?Math.max(ne,S.getFullYear()):ne,fe=b?Math.min(fe,b.getFullYear()):fe,c.yearshtml+="<select class='ui-datepicker-year' aria-label='"+it+"' data-handler='selectYear' data-event='change'>";ne<=fe;ne++)c.yearshtml+="<option value='"+ne+"'"+(ne===x?" selected='selected'":"")+">"+ne+"</option>";c.yearshtml+="</select>",ot+=c.yearshtml,c.yearshtml=null}return ot+=this._get(c,"yearSuffix"),je&&(ot+=(h||!(me&&de)?"&#xa0;":"")+Ct),ot+="</div>",ot},_adjustInstDate:function(c,p,x){var S=c.selectedYear+(x==="Y"?p:0),b=c.selectedMonth+(x==="M"?p:0),h=Math.min(c.selectedDay,this._getDaysInMonth(S,b))+(x==="D"?p:0),T=this._restrictMinMax(c,this._daylightSavingAdjust(new Date(S,b,h)));c.selectedDay=T.getDate(),c.drawMonth=c.selectedMonth=T.getMonth(),c.drawYear=c.selectedYear=T.getFullYear(),(x==="M"||x==="Y")&&this._notifyChange(c)},_restrictMinMax:function(c,p){var x=this._getMinMaxDate(c,"min"),S=this._getMinMaxDate(c,"max"),b=x&&p<x?x:p;return S&&b>S?S:b},_notifyChange:function(c){var p=this._get(c,"onChangeMonthYear");p&&p.apply(c.input?c.input[0]:null,[c.selectedYear,c.selectedMonth+1,c])},_getNumberOfMonths:function(c){var p=this._get(c,"numberOfMonths");return p==null?[1,1]:typeof p=="number"?[1,p]:p},_getMinMaxDate:function(c,p){return this._determineDate(c,this._get(c,p+"Date"),null)},_getDaysInMonth:function(c,p){return 32-this._daylightSavingAdjust(new Date(c,p,32)).getDate()},_getFirstDayOfMonth:function(c,p){return new Date(c,p,1).getDay()},_canAdjustMonth:function(c,p,x,S){var b=this._getNumberOfMonths(c),h=this._daylightSavingAdjust(new Date(x,S+(p<0?p:b[0]*b[1]),1));return p<0&&h.setDate(this._getDaysInMonth(h.getFullYear(),h.getMonth())),this._isInRange(c,h)},_isInRange:function(c,p){var x,S,b=this._getMinMaxDate(c,"min"),h=this._getMinMaxDate(c,"max"),T=null,M=null,O=this._get(c,"yearRange");return O&&(x=O.split(":"),S=new Date().getFullYear(),T=parseInt(x[0],10),M=parseInt(x[1],10),x[0].match(/[+\-].*/)&&(T+=S),x[1].match(/[+\-].*/)&&(M+=S)),(!b||p.getTime()>=b.getTime())&&(!h||p.getTime()<=h.getTime())&&(!T||p.getFullYear()>=T)&&(!M||p.getFullYear()<=M)},_getFormatConfig:function(c){var p=this._get(c,"shortYearCutoff");return p=typeof p!="string"?p:new Date().getFullYear()%100+parseInt(p,10),{shortYearCutoff:p,dayNamesShort:this._get(c,"dayNamesShort"),dayNames:this._get(c,"dayNames"),monthNamesShort:this._get(c,"monthNamesShort"),monthNames:this._get(c,"monthNames")}},_formatDate:function(c,p,x,S){p||(c.currentDay=c.selectedDay,c.currentMonth=c.selectedMonth,c.currentYear=c.selectedYear);var b=p?typeof p=="object"?p:this._daylightSavingAdjust(new Date(S,x,p)):this._daylightSavingAdjust(new Date(c.currentYear,c.currentMonth,c.currentDay));return this.formatDate(this._get(c,"dateFormat"),b,this._getFormatConfig(c))}});function ke(c){var p="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return c.on("mouseout",p,function(){t(this).removeClass("ui-state-hover"),this.className.indexOf("ui-datepicker-prev")!==-1&&t(this).removeClass("ui-datepicker-prev-hover"),this.className.indexOf("ui-datepicker-next")!==-1&&t(this).removeClass("ui-datepicker-next-hover")}).on("mouseover",p,L)}function L(){t.datepicker._isDisabledDatepicker(Q.inline?Q.dpDiv.parent()[0]:Q.input[0])||(t(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),t(this).addClass("ui-state-hover"),this.className.indexOf("ui-datepicker-prev")!==-1&&t(this).addClass("ui-datepicker-prev-hover"),this.className.indexOf("ui-datepicker-next")!==-1&&t(this).addClass("ui-datepicker-next-hover"))}function d(c,p){t.extend(c,p);for(var x in p)p[x]==null&&(c[x]=p[x]);return c}t.fn.datepicker=function(c){if(!this.length)return this;t.datepicker.initialized||(t(document).on("mousedown",t.datepicker._checkExternalClick),t.datepicker.initialized=!0),t("#"+t.datepicker._mainDivId).length===0&&t("body").append(t.datepicker.dpDiv);var p=Array.prototype.slice.call(arguments,1);return typeof c=="string"&&(c==="isDisabled"||c==="getDate"||c==="widget")?t.datepicker["_"+c+"Datepicker"].apply(t.datepicker,[this[0]].concat(p)):c==="option"&&arguments.length===2&&typeof arguments[1]=="string"?t.datepicker["_"+c+"Datepicker"].apply(t.datepicker,[this[0]].concat(p)):this.each(function(){typeof c=="string"?t.datepicker["_"+c+"Datepicker"].apply(t.datepicker,[this].concat(p)):t.datepicker._attachDatepicker(this,c)})},t.datepicker=new he,t.datepicker.initialized=!1,t.datepicker.uuid=new Date().getTime(),t.datepicker.version="1.14.0",t.datepicker;/*!
 * jQuery UI Mouse 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */var v=!1;t(document).on("mouseup",function(){v=!1}),t.widget("ui.mouse",{version:"1.14.0",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var c=this;this.element.on("mousedown."+this.widgetName,function(p){return c._mouseDown(p)}).on("click."+this.widgetName,function(p){if(t.data(p.target,c.widgetName+".preventClickEvent")===!0)return t.removeData(p.target,c.widgetName+".preventClickEvent"),p.stopImmediatePropagation(),!1}),this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName),this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(c){if(!v){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(c),this._mouseDownEvent=c;var p=this,x=c.which===1,S=typeof this.options.cancel=="string"?t(c.target).closest(this.options.cancel).length:!1;return!x||S||!this._mouseCapture(c)?!0:(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){p.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(c)&&this._mouseDelayMet(c)&&(this._mouseStarted=this._mouseStart(c)!==!1,!this._mouseStarted)?(c.preventDefault(),!0):(t.data(c.target,this.widgetName+".preventClickEvent")===!0&&t.removeData(c.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(b){return p._mouseMove(b)},this._mouseUpDelegate=function(b){return p._mouseUp(b)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),c.preventDefault(),v=!0,!0))}},_mouseMove:function(c){if(this._mouseMoved&&!c.which){if(c.originalEvent.altKey||c.originalEvent.ctrlKey||c.originalEvent.metaKey||c.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(c)}return(c.which||c.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(c),c.preventDefault()):(this._mouseDistanceMet(c)&&this._mouseDelayMet(c)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,c)!==!1,this._mouseStarted?this._mouseDrag(c):this._mouseUp(c)),!this._mouseStarted)},_mouseUp:function(c){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,c.target===this._mouseDownEvent.target&&t.data(c.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(c)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,v=!1,c.preventDefault()},_mouseDistanceMet:function(c){return Math.max(Math.abs(this._mouseDownEvent.pageX-c.pageX),Math.abs(this._mouseDownEvent.pageY-c.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),t.ui.plugin={add:function(c,p,x){var S,b=t.ui[c].prototype;for(S in x)b.plugins[S]=b.plugins[S]||[],b.plugins[S].push([p,x[S]])},call:function(c,p,x,S){var b,h=c.plugins[p];if(h&&!(!S&&(!c.element[0].parentNode||c.element[0].parentNode.nodeType===11)))for(b=0;b<h.length;b++)c.options[h[b][0]]&&h[b][1].apply(c.element,x)}};/*!
 * jQuery UI Draggable 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.draggable",t.ui.mouse,{version:"1.14.0",widgetEventPrefix:"drag",options:{addClasses:!0,appendTo:"parent",axis:!1,connectToSortable:!1,containment:!1,cursor:"auto",cursorAt:!1,grid:!1,handle:!1,helper:"original",iframeFix:!1,opacity:!1,refreshPositions:!1,revert:!1,revertDuration:500,scope:"default",scroll:!0,scrollSensitivity:20,scrollSpeed:20,snap:!1,snapMode:"both",snapTolerance:20,stack:!1,zIndex:!1,drag:null,start:null,stop:null},_create:function(){this.options.helper==="original"&&this._setPositionRelative(),this.options.addClasses&&this._addClass("ui-draggable"),this._setHandleClassName(),this._mouseInit()},_setOption:function(c,p){this._super(c,p),c==="handle"&&(this._removeHandleClassName(),this._setHandleClassName())},_destroy:function(){if((this.helper||this.element).is(".ui-draggable-dragging")){this.destroyOnClear=!0;return}this._removeHandleClassName(),this._mouseDestroy()},_mouseCapture:function(c){var p=this.options;return this.helper||p.disabled||t(c.target).closest(".ui-resizable-handle").length>0||(this.handle=this._getHandle(c),!this.handle)?!1:(this._blurActiveElement(c),this._blockFrames(p.iframeFix===!0?"iframe":p.iframeFix),!0)},_blockFrames:function(c){this.iframeBlocks=this.document.find(c).map(function(){var p=t(this);return t("<div>").css("position","absolute").appendTo(p.parent()).outerWidth(p.outerWidth()).outerHeight(p.outerHeight()).offset(p.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_blurActiveElement:function(c){var p=this.document[0].activeElement,x=t(c.target);x.closest(p).length||t(p).trigger("blur")},_mouseStart:function(c){var p=this.options;return this.helper=this._createHelper(c),this._addClass(this.helper,"ui-draggable-dragging"),this._cacheHelperProportions(),t.ui.ddmanager&&(t.ui.ddmanager.current=this),this._cacheMargins(),this.cssPosition=this.helper.css("position"),this.scrollParent=this.helper.scrollParent(!0),this.offsetParent=this.helper.offsetParent(),this.hasFixedAncestor=this.helper.parents().filter(function(){return t(this).css("position")==="fixed"}).length>0,this.positionAbs=this.element.offset(),this._refreshOffsets(c),this.originalPosition=this.position=this._generatePosition(c,!1),this.originalPageX=c.pageX,this.originalPageY=c.pageY,p.cursorAt&&this._adjustOffsetFromHelper(p.cursorAt),this._setContainment(),this._trigger("start",c)===!1?(this._clear(),!1):(this._cacheHelperProportions(),t.ui.ddmanager&&!p.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,c),this._mouseDrag(c,!0),t.ui.ddmanager&&t.ui.ddmanager.dragStart(this,c),!0)},_refreshOffsets:function(c){this.offset={top:this.positionAbs.top-this.margins.top,left:this.positionAbs.left-this.margins.left,scroll:!1,parent:this._getParentOffset(),relative:this._getRelativeOffset()},this.offset.click={left:c.pageX-this.offset.left,top:c.pageY-this.offset.top}},_mouseDrag:function(c,p){if(this.hasFixedAncestor&&(this.offset.parent=this._getParentOffset()),this.position=this._generatePosition(c,!0),this.positionAbs=this._convertPositionTo("absolute"),!p){var x=this._uiHash();if(this._trigger("drag",c,x)===!1)return this._mouseUp(new t.Event("mouseup",c)),!1;this.position=x.position}return this.helper[0].style.left=this.position.left+"px",this.helper[0].style.top=this.position.top+"px",t.ui.ddmanager&&t.ui.ddmanager.drag(this,c),!1},_mouseStop:function(c){var p=this,x=!1;return t.ui.ddmanager&&!this.options.dropBehaviour&&(x=t.ui.ddmanager.drop(this,c)),this.dropped&&(x=this.dropped,this.dropped=!1),this.options.revert==="invalid"&&!x||this.options.revert==="valid"&&x||this.options.revert===!0||typeof this.options.revert=="function"&&this.options.revert.call(this.element,x)?t(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){p._trigger("stop",c)!==!1&&p._clear()}):this._trigger("stop",c)!==!1&&this._clear(),!1},_mouseUp:function(c){return this._unblockFrames(),t.ui.ddmanager&&t.ui.ddmanager.dragStop(this,c),this.handleElement.is(c.target)&&this.element.trigger("focus"),t.ui.mouse.prototype._mouseUp.call(this,c)},cancel:function(){return this.helper.is(".ui-draggable-dragging")?this._mouseUp(new t.Event("mouseup",{target:this.element[0]})):this._clear(),this},_getHandle:function(c){return this.options.handle?!!t(c.target).closest(this.element.find(this.options.handle)).length:!0},_setHandleClassName:function(){this.handleElement=this.options.handle?this.element.find(this.options.handle):this.element,this._addClass(this.handleElement,"ui-draggable-handle")},_removeHandleClassName:function(){this._removeClass(this.handleElement,"ui-draggable-handle")},_createHelper:function(c){var p=this.options,x=typeof p.helper=="function",S=x?t(p.helper.apply(this.element[0],[c])):p.helper==="clone"?this.element.clone().removeAttr("id"):this.element;return S.parents("body").length||S.appendTo(p.appendTo==="parent"?this.element[0].parentNode:p.appendTo),x&&S[0]===this.element[0]&&this._setPositionRelative(),S[0]!==this.element[0]&&!/(fixed|absolute)/.test(S.css("position"))&&S.css("position","absolute"),S},_setPositionRelative:function(){/^(?:r|a|f)/.test(this.element.css("position"))||(this.element[0].style.position="relative")},_adjustOffsetFromHelper:function(c){typeof c=="string"&&(c=c.split(" ")),Array.isArray(c)&&(c={left:+c[0],top:+c[1]||0}),"left"in c&&(this.offset.click.left=c.left+this.margins.left),"right"in c&&(this.offset.click.left=this.helperProportions.width-c.right+this.margins.left),"top"in c&&(this.offset.click.top=c.top+this.margins.top),"bottom"in c&&(this.offset.click.top=this.helperProportions.height-c.bottom+this.margins.top)},_isRootNode:function(c){return/(html|body)/i.test(c.tagName)||c===this.document[0]},_getParentOffset:function(){var c=this.offsetParent.offset(),p=this.document[0];return this.cssPosition==="absolute"&&this.scrollParent[0]!==p&&t.contains(this.scrollParent[0],this.offsetParent[0])&&(c.left+=this.scrollParent.scrollLeft(),c.top+=this.scrollParent.scrollTop()),this._isRootNode(this.offsetParent[0])&&(c={top:0,left:0}),{top:c.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:c.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if(this.cssPosition!=="relative")return{top:0,left:0};var c=this.element.position(),p=this._isRootNode(this.scrollParent[0]);return{top:c.top-(parseInt(this.helper.css("top"),10)||0)+(p?0:this.scrollParent.scrollTop()),left:c.left-(parseInt(this.helper.css("left"),10)||0)+(p?0:this.scrollParent.scrollLeft())}},_cacheMargins:function(){this.margins={left:parseInt(this.element.css("marginLeft"),10)||0,top:parseInt(this.element.css("marginTop"),10)||0,right:parseInt(this.element.css("marginRight"),10)||0,bottom:parseInt(this.element.css("marginBottom"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var c,p,x,S=this.options,b=this.document[0];if(this.relativeContainer=null,!S.containment){this.containment=null;return}if(S.containment==="window"){this.containment=[t(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,t(window).scrollTop()-this.offset.relative.top-this.offset.parent.top,t(window).scrollLeft()+t(window).width()-this.helperProportions.width-this.margins.left,t(window).scrollTop()+(t(window).height()||b.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top];return}if(S.containment==="document"){this.containment=[0,0,t(b).width()-this.helperProportions.width-this.margins.left,(t(b).height()||b.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top];return}if(S.containment.constructor===Array){this.containment=S.containment;return}S.containment==="parent"&&(S.containment=this.helper[0].parentNode),p=t(S.containment),x=p[0],x&&(c=/(scroll|auto)/.test(p.css("overflow")),this.containment=[(parseInt(p.css("borderLeftWidth"),10)||0)+(parseInt(p.css("paddingLeft"),10)||0),(parseInt(p.css("borderTopWidth"),10)||0)+(parseInt(p.css("paddingTop"),10)||0),(c?Math.max(x.scrollWidth,x.offsetWidth):x.offsetWidth)-(parseInt(p.css("borderRightWidth"),10)||0)-(parseInt(p.css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(c?Math.max(x.scrollHeight,x.offsetHeight):x.offsetHeight)-(parseInt(p.css("borderBottomWidth"),10)||0)-(parseInt(p.css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom],this.relativeContainer=p)},_convertPositionTo:function(c,p){p||(p=this.position);var x=c==="absolute"?1:-1,S=this._isRootNode(this.scrollParent[0]);return{top:p.top+this.offset.relative.top*x+this.offset.parent.top*x-(this.cssPosition==="fixed"?-this.offset.scroll.top:S?0:this.offset.scroll.top)*x,left:p.left+this.offset.relative.left*x+this.offset.parent.left*x-(this.cssPosition==="fixed"?-this.offset.scroll.left:S?0:this.offset.scroll.left)*x}},_generatePosition:function(c,p){var x,S,b,h,T=this.options,M=this._isRootNode(this.scrollParent[0]),O=c.pageX,V=c.pageY;return(!M||!this.offset.scroll)&&(this.offset.scroll={top:this.scrollParent.scrollTop(),left:this.scrollParent.scrollLeft()}),p&&(this.containment&&(this.relativeContainer?(S=this.relativeContainer.offset(),x=[this.containment[0]+S.left,this.containment[1]+S.top,this.containment[2]+S.left,this.containment[3]+S.top]):x=this.containment,c.pageX-this.offset.click.left<x[0]&&(O=x[0]+this.offset.click.left),c.pageY-this.offset.click.top<x[1]&&(V=x[1]+this.offset.click.top),c.pageX-this.offset.click.left>x[2]&&(O=x[2]+this.offset.click.left),c.pageY-this.offset.click.top>x[3]&&(V=x[3]+this.offset.click.top)),T.grid&&(b=T.grid[1]?this.originalPageY+Math.round((V-this.originalPageY)/T.grid[1])*T.grid[1]:this.originalPageY,V=x?b-this.offset.click.top>=x[1]||b-this.offset.click.top>x[3]?b:b-this.offset.click.top>=x[1]?b-T.grid[1]:b+T.grid[1]:b,h=T.grid[0]?this.originalPageX+Math.round((O-this.originalPageX)/T.grid[0])*T.grid[0]:this.originalPageX,O=x?h-this.offset.click.left>=x[0]||h-this.offset.click.left>x[2]?h:h-this.offset.click.left>=x[0]?h-T.grid[0]:h+T.grid[0]:h),T.axis==="y"&&(O=this.originalPageX),T.axis==="x"&&(V=this.originalPageY)),{top:V-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+(this.cssPosition==="fixed"?-this.offset.scroll.top:M?0:this.offset.scroll.top),left:O-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+(this.cssPosition==="fixed"?-this.offset.scroll.left:M?0:this.offset.scroll.left)}},_clear:function(){this._removeClass(this.helper,"ui-draggable-dragging"),this.helper[0]!==this.element[0]&&!this.cancelHelperRemoval&&this.helper.remove(),this.helper=null,this.cancelHelperRemoval=!1,this.destroyOnClear&&this.destroy()},_trigger:function(c,p,x){return x=x||this._uiHash(),t.ui.plugin.call(this,c,[p,x,this],!0),/^(drag|start|stop)/.test(c)&&(this.positionAbs=this._convertPositionTo("absolute"),x.offset=this.positionAbs),t.Widget.prototype._trigger.call(this,c,p,x)},plugins:{},_uiHash:function(){return{helper:this.helper,position:this.position,originalPosition:this.originalPosition,offset:this.positionAbs}}}),t.ui.plugin.add("draggable","connectToSortable",{start:function(c,p,x){var S=t.extend({},p,{item:x.element});x.sortables=[],t(x.options.connectToSortable).each(function(){var b=t(this).sortable("instance");b&&!b.options.disabled&&(x.sortables.push(b),b.refreshPositions(),b._trigger("activate",c,S))})},stop:function(c,p,x){var S=t.extend({},p,{item:x.element});x.cancelHelperRemoval=!1,t.each(x.sortables,function(){var b=this;b.isOver?(b.isOver=0,x.cancelHelperRemoval=!0,b.cancelHelperRemoval=!1,b._storedCSS={position:b.placeholder.css("position"),top:b.placeholder.css("top"),left:b.placeholder.css("left")},b._mouseStop(c),b.options.helper=b.options._helper):(b.cancelHelperRemoval=!0,b._trigger("deactivate",c,S))})},drag:function(c,p,x){t.each(x.sortables,function(){var S=!1,b=this;b.positionAbs=x.positionAbs,b.helperProportions=x.helperProportions,b.offset.click=x.offset.click,b._intersectsWith(b.containerCache)&&(S=!0,t.each(x.sortables,function(){return this.positionAbs=x.positionAbs,this.helperProportions=x.helperProportions,this.offset.click=x.offset.click,this!==b&&this._intersectsWith(this.containerCache)&&t.contains(b.element[0],this.element[0])&&(S=!1),S})),S?(b.isOver||(b.isOver=1,x._parent=p.helper.parent(),b.currentItem=p.helper.appendTo(b.element).data("ui-sortable-item",!0),b.options._helper=b.options.helper,b.options.helper=function(){return p.helper[0]},c.target=b.currentItem[0],b._mouseCapture(c,!0),b._mouseStart(c,!0,!0),b.offset.click.top=x.offset.click.top,b.offset.click.left=x.offset.click.left,b.offset.parent.left-=x.offset.parent.left-b.offset.parent.left,b.offset.parent.top-=x.offset.parent.top-b.offset.parent.top,x._trigger("toSortable",c),x.dropped=b.element,t.each(x.sortables,function(){this.refreshPositions()}),x.currentItem=x.element,b.fromOutside=x),b.currentItem&&(b._mouseDrag(c),p.position=b.position)):b.isOver&&(b.isOver=0,b.cancelHelperRemoval=!0,b.options._revert=b.options.revert,b.options.revert=!1,b._trigger("out",c,b._uiHash(b)),b._mouseStop(c,!0),b.options.revert=b.options._revert,b.options.helper=b.options._helper,b.placeholder&&b.placeholder.remove(),p.helper.appendTo(x._parent),x._refreshOffsets(c),p.position=x._generatePosition(c,!0),x._trigger("fromSortable",c),x.dropped=!1,t.each(x.sortables,function(){this.refreshPositions()}))})}}),t.ui.plugin.add("draggable","cursor",{start:function(c,p,x){var S=t("body"),b=x.options;S.css("cursor")&&(b._cursor=S.css("cursor")),S.css("cursor",b.cursor)},stop:function(c,p,x){var S=x.options;S._cursor&&t("body").css("cursor",S._cursor)}}),t.ui.plugin.add("draggable","opacity",{start:function(c,p,x){var S=t(p.helper),b=x.options;S.css("opacity")&&(b._opacity=S.css("opacity")),S.css("opacity",b.opacity)},stop:function(c,p,x){var S=x.options;S._opacity&&t(p.helper).css("opacity",S._opacity)}}),t.ui.plugin.add("draggable","scroll",{start:function(c,p,x){x.scrollParentNotHidden||(x.scrollParentNotHidden=x.helper.scrollParent(!1)),x.scrollParentNotHidden[0]!==x.document[0]&&x.scrollParentNotHidden[0].tagName!=="HTML"&&(x.overflowOffset=x.scrollParentNotHidden.offset())},drag:function(c,p,x){var S=x.options,b=!1,h=x.scrollParentNotHidden[0],T=x.document[0];h!==T&&h.tagName!=="HTML"?((!S.axis||S.axis!=="x")&&(x.overflowOffset.top+h.offsetHeight-c.pageY<S.scrollSensitivity?h.scrollTop=b=h.scrollTop+S.scrollSpeed:c.pageY-x.overflowOffset.top<S.scrollSensitivity&&(h.scrollTop=b=h.scrollTop-S.scrollSpeed)),(!S.axis||S.axis!=="y")&&(x.overflowOffset.left+h.offsetWidth-c.pageX<S.scrollSensitivity?h.scrollLeft=b=h.scrollLeft+S.scrollSpeed:c.pageX-x.overflowOffset.left<S.scrollSensitivity&&(h.scrollLeft=b=h.scrollLeft-S.scrollSpeed))):((!S.axis||S.axis!=="x")&&(c.pageY-t(T).scrollTop()<S.scrollSensitivity?b=t(T).scrollTop(t(T).scrollTop()-S.scrollSpeed):t(window).height()-(c.pageY-t(T).scrollTop())<S.scrollSensitivity&&(b=t(T).scrollTop(t(T).scrollTop()+S.scrollSpeed))),(!S.axis||S.axis!=="y")&&(c.pageX-t(T).scrollLeft()<S.scrollSensitivity?b=t(T).scrollLeft(t(T).scrollLeft()-S.scrollSpeed):t(window).width()-(c.pageX-t(T).scrollLeft())<S.scrollSensitivity&&(b=t(T).scrollLeft(t(T).scrollLeft()+S.scrollSpeed)))),b!==!1&&t.ui.ddmanager&&!S.dropBehaviour&&t.ui.ddmanager.prepareOffsets(x,c)}}),t.ui.plugin.add("draggable","snap",{start:function(c,p,x){var S=x.options;x.snapElements=[],t(S.snap.constructor!==String?S.snap.items||":data(ui-draggable)":S.snap).each(function(){var b=t(this),h=b.offset();this!==x.element[0]&&x.snapElements.push({item:this,width:b.outerWidth(),height:b.outerHeight(),top:h.top,left:h.left})})},drag:function(c,p,x){var S,b,h,T,M,O,V,ee,Z,U,z=x.options,ne=z.snapTolerance,fe=p.offset.left,me=fe+x.helperProportions.width,de=p.offset.top,je=de+x.helperProportions.height;for(Z=x.snapElements.length-1;Z>=0;Z--){if(M=x.snapElements[Z].left-x.margins.left,O=M+x.snapElements[Z].width,V=x.snapElements[Z].top-x.margins.top,ee=V+x.snapElements[Z].height,me<M-ne||fe>O+ne||je<V-ne||de>ee+ne||!t.contains(x.snapElements[Z].item.ownerDocument,x.snapElements[Z].item)){x.snapElements[Z].snapping&&x.options.snap.release&&x.options.snap.release.call(x.element,c,t.extend(x._uiHash(),{snapItem:x.snapElements[Z].item})),x.snapElements[Z].snapping=!1;continue}z.snapMode!=="inner"&&(S=Math.abs(V-je)<=ne,b=Math.abs(ee-de)<=ne,h=Math.abs(M-me)<=ne,T=Math.abs(O-fe)<=ne,S&&(p.position.top=x._convertPositionTo("relative",{top:V-x.helperProportions.height,left:0}).top),b&&(p.position.top=x._convertPositionTo("relative",{top:ee,left:0}).top),h&&(p.position.left=x._convertPositionTo("relative",{top:0,left:M-x.helperProportions.width}).left),T&&(p.position.left=x._convertPositionTo("relative",{top:0,left:O}).left)),U=S||b||h||T,z.snapMode!=="outer"&&(S=Math.abs(V-de)<=ne,b=Math.abs(ee-je)<=ne,h=Math.abs(M-fe)<=ne,T=Math.abs(O-me)<=ne,S&&(p.position.top=x._convertPositionTo("relative",{top:V,left:0}).top),b&&(p.position.top=x._convertPositionTo("relative",{top:ee-x.helperProportions.height,left:0}).top),h&&(p.position.left=x._convertPositionTo("relative",{top:0,left:M}).left),T&&(p.position.left=x._convertPositionTo("relative",{top:0,left:O-x.helperProportions.width}).left)),!x.snapElements[Z].snapping&&(S||b||h||T||U)&&x.options.snap.snap&&x.options.snap.snap.call(x.element,c,t.extend(x._uiHash(),{snapItem:x.snapElements[Z].item})),x.snapElements[Z].snapping=S||b||h||T||U}}}),t.ui.plugin.add("draggable","stack",{start:function(c,p,x){var S,b=x.options,h=t.makeArray(t(b.stack)).sort(function(T,M){return(parseInt(t(T).css("zIndex"),10)||0)-(parseInt(t(M).css("zIndex"),10)||0)});h.length&&(S=parseInt(t(h[0]).css("zIndex"),10)||0,t(h).each(function(T){t(this).css("zIndex",S+T)}),this.css("zIndex",S+h.length))}}),t.ui.plugin.add("draggable","zIndex",{start:function(c,p,x){var S=t(p.helper),b=x.options;S.css("zIndex")&&(b._zIndex=S.css("zIndex")),S.css("zIndex",b.zIndex)},stop:function(c,p,x){var S=x.options;S._zIndex&&t(p.helper).css("zIndex",S._zIndex)}}),t.ui.draggable;/*!
 * jQuery UI Resizable 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.resizable",t.ui.mouse,{version:"1.14.0",widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,classes:{"ui-resizable-se":"ui-icon ui-icon-gripsmall-diagonal-se"},containment:!1,ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_num:function(c){return parseFloat(c)||0},_isNumber:function(c){return!isNaN(parseFloat(c))},_hasScroll:function(c,p){if(t(c).css("overflow")==="hidden")return!1;var x=p&&p==="left"?"scrollLeft":"scrollTop",S=!1;if(c[x]>0)return!0;try{c[x]=1,S=c[x]>0,c[x]=0}catch{}return S},_create:function(){var c,p=this.options,x=this;this._addClass("ui-resizable"),t.extend(this,{_aspectRatio:!!p.aspectRatio,aspectRatio:p.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:p.helper||p.ghost||p.animate?p.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)&&(this.element.wrap(t("<div class='ui-wrapper'></div>").css({overflow:"hidden",position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,c={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(c),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this._proportionallyResize()),this._setupHandles(),p.autoHide&&t(this.element).on("mouseenter",function(){p.disabled||(x._removeClass("ui-resizable-autohide"),x._handles.show())}).on("mouseleave",function(){p.disabled||x.resizing||(x._addClass("ui-resizable-autohide"),x._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy(),this._addedHandles.remove();var c,p=function(x){t(x).removeData("resizable").removeData("ui-resizable").off(".resizable")};return this.elementIsWrapper&&(p(this.element),c=this.element,this.originalElement.css({position:c.css("position"),width:c.outerWidth(),height:c.outerHeight(),top:c.css("top"),left:c.css("left")}).insertAfter(c),c.remove()),this.originalElement.css("resize",this.originalResizeStyle),p(this.originalElement),this},_setOption:function(c,p){switch(this._super(c,p),c){case"handles":this._removeHandles(),this._setupHandles();break;case"aspectRatio":this._aspectRatio=!!p;break}},_setupHandles:function(){var c=this.options,p,x,S,b,h,T=this;if(this.handles=c.handles||(t(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=t(),this._addedHandles=t(),this.handles.constructor===String)for(this.handles==="all"&&(this.handles="n,e,s,w,se,sw,ne,nw"),S=this.handles.split(","),this.handles={},x=0;x<S.length;x++)p=String.prototype.trim.call(S[x]),b="ui-resizable-"+p,h=t("<div>"),this._addClass(h,"ui-resizable-handle "+b),h.css({zIndex:c.zIndex}),this.handles[p]=".ui-resizable-"+p,this.element.children(this.handles[p]).length||(this.element.append(h),this._addedHandles=this._addedHandles.add(h));this._renderAxis=function(M){var O,V,ee,Z;M=M||this.element;for(O in this.handles)this.handles[O].constructor===String?this.handles[O]=this.element.children(this.handles[O]).first().show():(this.handles[O].jquery||this.handles[O].nodeType)&&(this.handles[O]=t(this.handles[O]),this._on(this.handles[O],{mousedown:T._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(V=t(this.handles[O],this.element),Z=/sw|ne|nw|se|n|s/.test(O)?V.outerHeight():V.outerWidth(),ee=["padding",/ne|nw|n/.test(O)?"Top":/se|sw|s/.test(O)?"Bottom":/^e$/.test(O)?"Right":"Left"].join(""),M.css(ee,Z),this._proportionallyResize()),this._handles=this._handles.add(this.handles[O])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){T.resizing||(this.className&&(h=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),T.axis=h&&h[1]?h[1]:"se")}),c.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._addedHandles.remove()},_mouseCapture:function(c){var p,x,S=!1;for(p in this.handles)x=t(this.handles[p])[0],(x===c.target||t.contains(x,c.target))&&(S=!0);return!this.options.disabled&&S},_mouseStart:function(c){var p,x,S,b=this.options,h=this.element;return this.resizing=!0,this._renderProxy(),p=this._num(this.helper.css("left")),x=this._num(this.helper.css("top")),b.containment&&(p+=t(b.containment).scrollLeft()||0,x+=t(b.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:p,top:x},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:h.width(),height:h.height()},this.originalSize=this._helper?{width:h.outerWidth(),height:h.outerHeight()}:{width:h.width(),height:h.height()},this.sizeDiff={width:h.outerWidth()-h.width(),height:h.outerHeight()-h.height()},this.originalPosition={left:p,top:x},this.originalMousePosition={left:c.pageX,top:c.pageY},this.aspectRatio=typeof b.aspectRatio=="number"?b.aspectRatio:this.originalSize.width/this.originalSize.height||1,S=t(".ui-resizable-"+this.axis).css("cursor"),t("body").css("cursor",S==="auto"?this.axis+"-resize":S),this._addClass("ui-resizable-resizing"),this._propagate("start",c),!0},_mouseDrag:function(c){var p,x,S=this.originalMousePosition,b=this.axis,h=c.pageX-S.left||0,T=c.pageY-S.top||0,M=this._change[b];return this._updatePrevProperties(),M&&(p=M.apply(this,[c,h,T]),this._updateVirtualBoundaries(c.shiftKey),(this._aspectRatio||c.shiftKey)&&(p=this._updateRatio(p,c)),p=this._respectSize(p,c),this._updateCache(p),this._propagate("resize",c),x=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),t.isEmptyObject(x)||(this._updatePrevProperties(),this._trigger("resize",c,this.ui()),this._applyChanges())),!1},_mouseStop:function(c){this.resizing=!1;var p,x,S,b,h,T,M,O=this.options,V=this;return this._helper&&(p=this._proportionallyResizeElements,x=p.length&&/textarea/i.test(p[0].nodeName),S=x&&this._hasScroll(p[0],"left")?0:V.sizeDiff.height,b=x?0:V.sizeDiff.width,h={width:V.helper.width()-b,height:V.helper.height()-S},T=parseFloat(V.element.css("left"))+(V.position.left-V.originalPosition.left)||null,M=parseFloat(V.element.css("top"))+(V.position.top-V.originalPosition.top)||null,O.animate||this.element.css(t.extend(h,{top:M,left:T})),V.helper.height(V.size.height),V.helper.width(V.size.width),this._helper&&!O.animate&&this._proportionallyResize()),t("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",c),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var c={};return this.position.top!==this.prevPosition.top&&(c.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(c.left=this.position.left+"px"),this.helper.css(c),this.size.width!==this.prevSize.width&&(c.width=this.size.width+"px",this.helper.width(c.width)),this.size.height!==this.prevSize.height&&(c.height=this.size.height+"px",this.helper.height(c.height)),c},_updateVirtualBoundaries:function(c){var p,x,S,b,h,T=this.options;h={minWidth:this._isNumber(T.minWidth)?T.minWidth:0,maxWidth:this._isNumber(T.maxWidth)?T.maxWidth:1/0,minHeight:this._isNumber(T.minHeight)?T.minHeight:0,maxHeight:this._isNumber(T.maxHeight)?T.maxHeight:1/0},(this._aspectRatio||c)&&(p=h.minHeight*this.aspectRatio,S=h.minWidth/this.aspectRatio,x=h.maxHeight*this.aspectRatio,b=h.maxWidth/this.aspectRatio,p>h.minWidth&&(h.minWidth=p),S>h.minHeight&&(h.minHeight=S),x<h.maxWidth&&(h.maxWidth=x),b<h.maxHeight&&(h.maxHeight=b)),this._vBoundaries=h},_updateCache:function(c){this.offset=this.helper.offset(),this._isNumber(c.left)&&(this.position.left=c.left),this._isNumber(c.top)&&(this.position.top=c.top),this._isNumber(c.height)&&(this.size.height=c.height),this._isNumber(c.width)&&(this.size.width=c.width)},_updateRatio:function(c){var p=this.position,x=this.size,S=this.axis;return this._isNumber(c.height)?c.width=c.height*this.aspectRatio:this._isNumber(c.width)&&(c.height=c.width/this.aspectRatio),S==="sw"&&(c.left=p.left+(x.width-c.width),c.top=null),S==="nw"&&(c.top=p.top+(x.height-c.height),c.left=p.left+(x.width-c.width)),c},_respectSize:function(c){var p=this._vBoundaries,x=this.axis,S=this._isNumber(c.width)&&p.maxWidth&&p.maxWidth<c.width,b=this._isNumber(c.height)&&p.maxHeight&&p.maxHeight<c.height,h=this._isNumber(c.width)&&p.minWidth&&p.minWidth>c.width,T=this._isNumber(c.height)&&p.minHeight&&p.minHeight>c.height,M=this.originalPosition.left+this.originalSize.width,O=this.originalPosition.top+this.originalSize.height,V=/sw|nw|w/.test(x),ee=/nw|ne|n/.test(x);return h&&(c.width=p.minWidth),T&&(c.height=p.minHeight),S&&(c.width=p.maxWidth),b&&(c.height=p.maxHeight),h&&V&&(c.left=M-p.minWidth),S&&V&&(c.left=M-p.maxWidth),T&&ee&&(c.top=O-p.minHeight),b&&ee&&(c.top=O-p.maxHeight),!c.width&&!c.height&&!c.left&&c.top?c.top=null:!c.width&&!c.height&&!c.top&&c.left&&(c.left=null),c},_getPaddingPlusBorderDimensions:function(c){for(var p=0,x=[],S=[c.css("borderTopWidth"),c.css("borderRightWidth"),c.css("borderBottomWidth"),c.css("borderLeftWidth")],b=[c.css("paddingTop"),c.css("paddingRight"),c.css("paddingBottom"),c.css("paddingLeft")];p<4;p++)x[p]=parseFloat(S[p])||0,x[p]+=parseFloat(b[p])||0;return{height:x[0]+x[2],width:x[1]+x[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var c,p=0,x=this.helper||this.element;p<this._proportionallyResizeElements.length;p++)c=this._proportionallyResizeElements[p],this.outerDimensions||(this.outerDimensions=this._getPaddingPlusBorderDimensions(c)),c.css({height:x.height()-this.outerDimensions.height||0,width:x.width()-this.outerDimensions.width||0})},_renderProxy:function(){var c=this.element,p=this.options;this.elementOffset=c.offset(),this._helper?(this.helper=this.helper||t("<div></div>").css({overflow:"hidden"}),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++p.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element},_change:{e:function(c,p){return{width:this.originalSize.width+p}},w:function(c,p){var x=this.originalSize,S=this.originalPosition;return{left:S.left+p,width:x.width-p}},n:function(c,p,x){var S=this.originalSize,b=this.originalPosition;return{top:b.top+x,height:S.height-x}},s:function(c,p,x){return{height:this.originalSize.height+x}},se:function(c,p,x){return t.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[c,p,x]))},sw:function(c,p,x){return t.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[c,p,x]))},ne:function(c,p,x){return t.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[c,p,x]))},nw:function(c,p,x){return t.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[c,p,x]))}},_propagate:function(c,p){t.ui.plugin.call(this,c,[p,this.ui()]),c!=="resize"&&this._trigger(c,p,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),t.ui.plugin.add("resizable","animate",{stop:function(c){var p=t(this).resizable("instance"),x=p.options,S=p._proportionallyResizeElements,b=S.length&&/textarea/i.test(S[0].nodeName),h=b&&p._hasScroll(S[0],"left")?0:p.sizeDiff.height,T=b?0:p.sizeDiff.width,M={width:p.size.width-T,height:p.size.height-h},O=parseFloat(p.element.css("left"))+(p.position.left-p.originalPosition.left)||null,V=parseFloat(p.element.css("top"))+(p.position.top-p.originalPosition.top)||null;p.element.animate(t.extend(M,V&&O?{top:V,left:O}:{}),{duration:x.animateDuration,easing:x.animateEasing,step:function(){var ee={width:parseFloat(p.element.css("width")),height:parseFloat(p.element.css("height")),top:parseFloat(p.element.css("top")),left:parseFloat(p.element.css("left"))};S&&S.length&&t(S[0]).css({width:ee.width,height:ee.height}),p._updateCache(ee),p._propagate("resize",c)}})}}),t.ui.plugin.add("resizable","containment",{start:function(){var c,p,x,S,b,h,T,M=t(this).resizable("instance"),O=M.options,V=M.element,ee=O.containment,Z=ee instanceof t?ee.get(0):/parent/.test(ee)?V.parent().get(0):ee;Z&&(M.containerElement=t(Z),/document/.test(ee)||ee===document?(M.containerOffset={left:0,top:0},M.containerPosition={left:0,top:0},M.parentData={element:t(document),left:0,top:0,width:t(document).width(),height:t(document).height()||document.body.parentNode.scrollHeight}):(c=t(Z),p=[],t(["Top","Right","Left","Bottom"]).each(function(U,z){p[U]=M._num(c.css("padding"+z))}),M.containerOffset=c.offset(),M.containerPosition=c.position(),M.containerSize={height:c.innerHeight()-p[3],width:c.innerWidth()-p[1]},x=M.containerOffset,S=M.containerSize.height,b=M.containerSize.width,h=M._hasScroll(Z,"left")?Z.scrollWidth:b,T=M._hasScroll(Z)?Z.scrollHeight:S,M.parentData={element:Z,left:x.left,top:x.top,width:h,height:T}))},resize:function(c){var p,x,S,b,h=t(this).resizable("instance"),T=h.options,M=h.containerOffset,O=h.position,V=h._aspectRatio||c.shiftKey,ee={top:0,left:0},Z=h.containerElement,U=!0;Z[0]!==document&&/static/.test(Z.css("position"))&&(ee=M),O.left<(h._helper?M.left:0)&&(h.size.width=h.size.width+(h._helper?h.position.left-M.left:h.position.left-ee.left),V&&(h.size.height=h.size.width/h.aspectRatio,U=!1),h.position.left=T.helper?M.left:0),O.top<(h._helper?M.top:0)&&(h.size.height=h.size.height+(h._helper?h.position.top-M.top:h.position.top),V&&(h.size.width=h.size.height*h.aspectRatio,U=!1),h.position.top=h._helper?M.top:0),S=h.containerElement.get(0)===h.element.parent().get(0),b=/relative|absolute/.test(h.containerElement.css("position")),S&&b?(h.offset.left=h.parentData.left+h.position.left,h.offset.top=h.parentData.top+h.position.top):(h.offset.left=h.element.offset().left,h.offset.top=h.element.offset().top),p=Math.abs(h.sizeDiff.width+(h._helper?h.offset.left-ee.left:h.offset.left-M.left)),x=Math.abs(h.sizeDiff.height+(h._helper?h.offset.top-ee.top:h.offset.top-M.top)),p+h.size.width>=h.parentData.width&&(h.size.width=h.parentData.width-p,V&&(h.size.height=h.size.width/h.aspectRatio,U=!1)),x+h.size.height>=h.parentData.height&&(h.size.height=h.parentData.height-x,V&&(h.size.width=h.size.height*h.aspectRatio,U=!1)),U||(h.position.left=h.prevPosition.left,h.position.top=h.prevPosition.top,h.size.width=h.prevSize.width,h.size.height=h.prevSize.height)},stop:function(){var c=t(this).resizable("instance"),p=c.options,x=c.containerOffset,S=c.containerPosition,b=c.containerElement,h=t(c.helper),T=h.offset(),M=h.outerWidth()-c.sizeDiff.width,O=h.outerHeight()-c.sizeDiff.height;c._helper&&!p.animate&&/relative/.test(b.css("position"))&&t(this).css({left:T.left-S.left-x.left,width:M,height:O}),c._helper&&!p.animate&&/static/.test(b.css("position"))&&t(this).css({left:T.left-S.left-x.left,width:M,height:O})}}),t.ui.plugin.add("resizable","alsoResize",{start:function(){var c=t(this).resizable("instance"),p=c.options;t(p.alsoResize).each(function(){var x=t(this);x.data("ui-resizable-alsoresize",{width:parseFloat(x.css("width")),height:parseFloat(x.css("height")),left:parseFloat(x.css("left")),top:parseFloat(x.css("top"))})})},resize:function(c,p){var x=t(this).resizable("instance"),S=x.options,b=x.originalSize,h=x.originalPosition,T={height:x.size.height-b.height||0,width:x.size.width-b.width||0,top:x.position.top-h.top||0,left:x.position.left-h.left||0};t(S.alsoResize).each(function(){var M=t(this),O=t(this).data("ui-resizable-alsoresize"),V={},ee=M.parents(p.originalElement[0]).length?["width","height"]:["width","height","top","left"];t.each(ee,function(Z,U){var z=(O[U]||0)+(T[U]||0);z&&z>=0&&(V[U]=z||null)}),M.css(V)})},stop:function(){t(this).removeData("ui-resizable-alsoresize")}}),t.ui.plugin.add("resizable","ghost",{start:function(){var c=t(this).resizable("instance"),p=c.size;c.ghost=c.originalElement.clone(),c.ghost.css({opacity:.25,display:"block",position:"relative",height:p.height,width:p.width,margin:0,left:0,top:0}),c._addClass(c.ghost,"ui-resizable-ghost"),t.uiBackCompat===!0&&typeof c.options.ghost=="string"&&c.ghost.addClass(this.options.ghost),c.ghost.appendTo(c.helper)},resize:function(){var c=t(this).resizable("instance");c.ghost&&c.ghost.css({position:"relative",height:c.size.height,width:c.size.width})},stop:function(){var c=t(this).resizable("instance");c.ghost&&c.helper&&c.helper.get(0).removeChild(c.ghost.get(0))}}),t.ui.plugin.add("resizable","grid",{resize:function(){var c,p=t(this).resizable("instance"),x=p.options,S=p.size,b=p.originalSize,h=p.originalPosition,T=p.axis,M=typeof x.grid=="number"?[x.grid,x.grid]:x.grid,O=M[0]||1,V=M[1]||1,ee=Math.round((S.width-b.width)/O)*O,Z=Math.round((S.height-b.height)/V)*V,U=b.width+ee,z=b.height+Z,ne=x.maxWidth&&x.maxWidth<U,fe=x.maxHeight&&x.maxHeight<z,me=x.minWidth&&x.minWidth>U,de=x.minHeight&&x.minHeight>z;x.grid=M,me&&(U+=O),de&&(z+=V),ne&&(U-=O),fe&&(z-=V),/^(se|s|e)$/.test(T)?(p.size.width=U,p.size.height=z):/^(ne)$/.test(T)?(p.size.width=U,p.size.height=z,p.position.top=h.top-Z):/^(sw)$/.test(T)?(p.size.width=U,p.size.height=z,p.position.left=h.left-ee):((z-V<=0||U-O<=0)&&(c=p._getPaddingPlusBorderDimensions(this)),z-V>0?(p.size.height=z,p.position.top=h.top-Z):(z=V-c.height,p.size.height=z,p.position.top=h.top+b.height-z),U-O>0?(p.size.width=U,p.position.left=h.left-ee):(U=O-c.width,p.size.width=U,p.position.left=h.left+b.width-U))}}),t.ui.resizable;/*!
 * jQuery UI Dialog 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.dialog",{version:"1.14.0",options:{appendTo:"body",autoOpen:!0,buttons:[],classes:{"ui-dialog":"ui-corner-all","ui-dialog-titlebar":"ui-corner-all"},closeOnEscape:!0,closeText:"Close",draggable:!0,hide:null,height:"auto",maxHeight:null,maxWidth:null,minHeight:150,minWidth:150,modal:!1,position:{my:"center",at:"center",of:window,collision:"fit",using:function(c){var p=t(this).css(c).offset().top;p<0&&t(this).css("top",c.top-p)}},resizable:!0,show:null,title:null,width:300,beforeClose:null,close:null,drag:null,dragStart:null,dragStop:null,focus:null,open:null,resize:null,resizeStart:null,resizeStop:null},sizeRelatedOptions:{buttons:!0,height:!0,maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0,width:!0},resizableRelatedOptions:{maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0},_create:function(){this.originalCss={display:this.element[0].style.display,width:this.element[0].style.width,minHeight:this.element[0].style.minHeight,maxHeight:this.element[0].style.maxHeight,height:this.element[0].style.height},this.originalPosition={parent:this.element.parent(),index:this.element.parent().children().index(this.element)},this.originalTitle=this.element.attr("title"),this.options.title==null&&this.originalTitle!=null&&(this.options.title=this.originalTitle),this.options.disabled&&(this.options.disabled=!1),this._createWrapper(),this.element.show().removeAttr("title").appendTo(this.uiDialog),this._addClass("ui-dialog-content","ui-widget-content"),this._createTitlebar(),this._createButtonPane(),this.options.draggable&&t.fn.draggable&&this._makeDraggable(),this.options.resizable&&t.fn.resizable&&this._makeResizable(),this._isOpen=!1,this._trackFocus()},_init:function(){this.options.autoOpen&&this.open()},_appendTo:function(){var c=this.options.appendTo;return c&&(c.jquery||c.nodeType)?t(c):this.document.find(c||"body").eq(0)},_destroy:function(){var c,p=this.originalPosition;this._untrackInstance(),this._destroyOverlay(),this.element.removeUniqueId().css(this.originalCss).detach(),this.uiDialog.remove(),this.originalTitle&&this.element.attr("title",this.originalTitle),c=p.parent.children().eq(p.index),c.length&&c[0]!==this.element[0]?c.before(this.element):p.parent.append(this.element)},widget:function(){return this.uiDialog},disable:t.noop,enable:t.noop,close:function(c){var p=this;!this._isOpen||this._trigger("beforeClose",c)===!1||(this._isOpen=!1,this._focusedElement=null,this._destroyOverlay(),this._untrackInstance(),this.opener.filter(":focusable").trigger("focus").length||t(this.document[0].activeElement).trigger("blur"),this._hide(this.uiDialog,this.options.hide,function(){p._trigger("close",c)}))},isOpen:function(){return this._isOpen},moveToTop:function(){this._moveToTop()},_moveToTop:function(c,p){var x=!1,S=this.uiDialog.siblings(".ui-front:visible").map(function(){return+t(this).css("z-index")}).get(),b=Math.max.apply(null,S);return b>=+this.uiDialog.css("z-index")&&(this.uiDialog.css("z-index",b+1),x=!0),x&&!p&&this._trigger("focus",c),x},open:function(){var c=this;if(this._isOpen){this._moveToTop()&&this._focusTabbable();return}this._isOpen=!0,this.opener=t(this.document[0].activeElement),this._size(),this._position(),this._createOverlay(),this._moveToTop(null,!0),this.overlay&&this.overlay.css("z-index",this.uiDialog.css("z-index")-1),this._show(this.uiDialog,this.options.show,function(){c._focusTabbable(),c._trigger("focus")}),this._makeFocusTarget(),this._trigger("open")},_focusTabbable:function(){var c=this._focusedElement;c||(c=this.element.find("[autofocus]")),c.length||(c=this.element.find(":tabbable")),c.length||(c=this.uiDialogButtonPane.find(":tabbable")),c.length||(c=this.uiDialogTitlebarClose.filter(":tabbable")),c.length||(c=this.uiDialog),c.eq(0).trigger("focus")},_restoreTabbableFocus:function(){var c=this.document[0].activeElement,p=this.uiDialog[0]===c||t.contains(this.uiDialog[0],c);p||this._focusTabbable()},_keepFocus:function(c){c.preventDefault(),this._restoreTabbableFocus()},_createWrapper:function(){this.uiDialog=t("<div>").hide().attr({tabIndex:-1,role:"dialog","aria-modal":this.options.modal?"true":null}).appendTo(this._appendTo()),this._addClass(this.uiDialog,"ui-dialog","ui-widget ui-widget-content ui-front"),this._on(this.uiDialog,{keydown:function(c){if(this.options.closeOnEscape&&!c.isDefaultPrevented()&&c.keyCode&&c.keyCode===t.ui.keyCode.ESCAPE){c.preventDefault(),this.close(c);return}if(!(c.keyCode!==t.ui.keyCode.TAB||c.isDefaultPrevented())){var p=this.uiDialog.find(":tabbable"),x=p.first(),S=p.last();(c.target===S[0]||c.target===this.uiDialog[0])&&!c.shiftKey?(this._delay(function(){x.trigger("focus")}),c.preventDefault()):(c.target===x[0]||c.target===this.uiDialog[0])&&c.shiftKey&&(this._delay(function(){S.trigger("focus")}),c.preventDefault())}},mousedown:function(c){this._moveToTop(c)&&this._focusTabbable()}}),this.element.find("[aria-describedby]").length||this.uiDialog.attr({"aria-describedby":this.element.uniqueId().attr("id")})},_createTitlebar:function(){var c;this.uiDialogTitlebar=t("<div>"),this._addClass(this.uiDialogTitlebar,"ui-dialog-titlebar","ui-widget-header ui-helper-clearfix"),this._on(this.uiDialogTitlebar,{mousedown:function(p){t(p.target).closest(".ui-dialog-titlebar-close")||this.uiDialog.trigger("focus")}}),this.uiDialogTitlebarClose=t("<button type='button'></button>").button({label:t("<a>").text(this.options.closeText).html(),icon:"ui-icon-closethick",showLabel:!1}).appendTo(this.uiDialogTitlebar),this._addClass(this.uiDialogTitlebarClose,"ui-dialog-titlebar-close"),this._on(this.uiDialogTitlebarClose,{click:function(p){p.preventDefault(),this.close(p)}}),c=t("<span>").uniqueId().prependTo(this.uiDialogTitlebar),this._addClass(c,"ui-dialog-title"),this._title(c),this.uiDialogTitlebar.prependTo(this.uiDialog),this.uiDialog.attr({"aria-labelledby":c.attr("id")})},_title:function(c){this.options.title?c.text(this.options.title):c.html("&#160;")},_createButtonPane:function(){this.uiDialogButtonPane=t("<div>"),this._addClass(this.uiDialogButtonPane,"ui-dialog-buttonpane","ui-widget-content ui-helper-clearfix"),this.uiButtonSet=t("<div>").appendTo(this.uiDialogButtonPane),this._addClass(this.uiButtonSet,"ui-dialog-buttonset"),this._createButtons()},_createButtons:function(){var c=this,p=this.options.buttons;if(this.uiDialogButtonPane.remove(),this.uiButtonSet.empty(),t.isEmptyObject(p)||Array.isArray(p)&&!p.length){this._removeClass(this.uiDialog,"ui-dialog-buttons");return}t.each(p,function(x,S){var b,h;S=typeof S=="function"?{click:S,text:x}:S,S=t.extend({type:"button"},S),b=S.click,h={icon:S.icon,iconPosition:S.iconPosition,showLabel:S.showLabel,icons:S.icons,text:S.text},delete S.click,delete S.icon,delete S.iconPosition,delete S.showLabel,delete S.icons,typeof S.text=="boolean"&&delete S.text,t("<button></button>",S).button(h).appendTo(c.uiButtonSet).on("click",function(){b.apply(c.element[0],arguments)})}),this._addClass(this.uiDialog,"ui-dialog-buttons"),this.uiDialogButtonPane.appendTo(this.uiDialog)},_makeDraggable:function(){var c=this,p=this.options;function x(S){return{position:S.position,offset:S.offset}}this.uiDialog.draggable({cancel:".ui-dialog-content, .ui-dialog-titlebar-close",handle:".ui-dialog-titlebar",containment:"document",start:function(S,b){c._addClass(t(this),"ui-dialog-dragging"),c._blockFrames(),c._trigger("dragStart",S,x(b))},drag:function(S,b){c._trigger("drag",S,x(b))},stop:function(S,b){var h=b.offset.left-c.document.scrollLeft(),T=b.offset.top-c.document.scrollTop();p.position={my:"left top",at:"left"+(h>=0?"+":"")+h+" top"+(T>=0?"+":"")+T,of:c.window},c._removeClass(t(this),"ui-dialog-dragging"),c._unblockFrames(),c._trigger("dragStop",S,x(b))}})},_makeResizable:function(){var c=this,p=this.options,x=p.resizable,S=this.uiDialog.css("position"),b=typeof x=="string"?x:"n,e,s,w,se,sw,ne,nw";function h(T){return{originalPosition:T.originalPosition,originalSize:T.originalSize,position:T.position,size:T.size}}this.uiDialog.resizable({cancel:".ui-dialog-content",containment:"document",alsoResize:this.element,maxWidth:p.maxWidth,maxHeight:p.maxHeight,minWidth:p.minWidth,minHeight:this._minHeight(),handles:b,start:function(T,M){c._addClass(t(this),"ui-dialog-resizing"),c._blockFrames(),c._trigger("resizeStart",T,h(M))},resize:function(T,M){c._trigger("resize",T,h(M))},stop:function(T,M){var O=c.uiDialog.offset(),V=O.left-c.document.scrollLeft(),ee=O.top-c.document.scrollTop();p.height=c.uiDialog.height(),p.width=c.uiDialog.width(),p.position={my:"left top",at:"left"+(V>=0?"+":"")+V+" top"+(ee>=0?"+":"")+ee,of:c.window},c._removeClass(t(this),"ui-dialog-resizing"),c._unblockFrames(),c._trigger("resizeStop",T,h(M))}}).css("position",S)},_trackFocus:function(){this._on(this.widget(),{focusin:function(c){this._makeFocusTarget(),this._focusedElement=t(c.target)}})},_makeFocusTarget:function(){this._untrackInstance(),this._trackingInstances().unshift(this)},_untrackInstance:function(){var c=this._trackingInstances(),p=t.inArray(this,c);p!==-1&&c.splice(p,1)},_trackingInstances:function(){var c=this.document.data("ui-dialog-instances");return c||(c=[],this.document.data("ui-dialog-instances",c)),c},_minHeight:function(){var c=this.options;return c.height==="auto"?c.minHeight:Math.min(c.minHeight,c.height)},_position:function(){var c=this.uiDialog.is(":visible");c||this.uiDialog.show(),this.uiDialog.position(this.options.position),c||this.uiDialog.hide()},_setOptions:function(c){var p=this,x=!1,S={};t.each(c,function(b,h){p._setOption(b,h),b in p.sizeRelatedOptions&&(x=!0),b in p.resizableRelatedOptions&&(S[b]=h)}),x&&(this._size(),this._position()),this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option",S)},_setOption:function(c,p){var x,S,b=this.uiDialog;c!=="disabled"&&(this._super(c,p),c==="appendTo"&&this.uiDialog.appendTo(this._appendTo()),c==="buttons"&&this._createButtons(),c==="closeText"&&this.uiDialogTitlebarClose.button({label:t("<a>").text(""+this.options.closeText).html()}),c==="draggable"&&(x=b.is(":data(ui-draggable)"),x&&!p&&b.draggable("destroy"),!x&&p&&this._makeDraggable()),c==="position"&&this._position(),c==="resizable"&&(S=b.is(":data(ui-resizable)"),S&&!p&&b.resizable("destroy"),S&&typeof p=="string"&&b.resizable("option","handles",p),!S&&p!==!1&&this._makeResizable()),c==="title"&&this._title(this.uiDialogTitlebar.find(".ui-dialog-title")),c==="modal"&&b.attr("aria-modal",p?"true":null))},_size:function(){var c,p,x,S=this.options;this.element.show().css({width:"auto",minHeight:0,maxHeight:"none",height:0}),S.minWidth>S.width&&(S.width=S.minWidth),c=this.uiDialog.css({height:"auto",width:S.width}).outerHeight(),p=Math.max(0,S.minHeight-c),x=typeof S.maxHeight=="number"?Math.max(0,S.maxHeight-c):"none",S.height==="auto"?this.element.css({minHeight:p,maxHeight:x,height:"auto"}):this.element.height(Math.max(0,S.height-c)),this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option","minHeight",this._minHeight())},_blockFrames:function(){this.iframeBlocks=this.document.find("iframe").map(function(){var c=t(this);return t("<div>").css({position:"absolute",width:c.outerWidth(),height:c.outerHeight()}).appendTo(c.parent()).offset(c.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_allowInteraction:function(c){return t(c.target).closest(".ui-dialog").length?!0:!!t(c.target).closest(".ui-datepicker").length},_createOverlay:function(){if(this.options.modal){var c=!0;this._delay(function(){c=!1}),this.document.data("ui-dialog-overlays")||this.document.on("focusin.ui-dialog",(function(p){if(!c){var x=this._trackingInstances()[0];x._allowInteraction(p)||(p.preventDefault(),x._focusTabbable())}}).bind(this)),this.overlay=t("<div>").appendTo(this._appendTo()),this._addClass(this.overlay,null,"ui-widget-overlay ui-front"),this._on(this.overlay,{mousedown:"_keepFocus"}),this.document.data("ui-dialog-overlays",(this.document.data("ui-dialog-overlays")||0)+1)}},_destroyOverlay:function(){if(this.options.modal&&this.overlay){var c=this.document.data("ui-dialog-overlays")-1;c?this.document.data("ui-dialog-overlays",c):(this.document.off("focusin.ui-dialog"),this.document.removeData("ui-dialog-overlays")),this.overlay.remove(),this.overlay=null}}}),t.uiBackCompat===!0&&t.widget("ui.dialog",t.ui.dialog,{options:{dialogClass:""},_createWrapper:function(){this._super(),this.uiDialog.addClass(this.options.dialogClass)},_setOption:function(c,p){c==="dialogClass"&&this.uiDialog.removeClass(this.options.dialogClass).addClass(p),this._superApply(arguments)}}),t.ui.dialog;/*!
 * jQuery UI Droppable 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.droppable",{version:"1.14.0",widgetEventPrefix:"drop",options:{accept:"*",addClasses:!0,greedy:!1,scope:"default",tolerance:"intersect",activate:null,deactivate:null,drop:null,out:null,over:null},_create:function(){var c,p=this.options,x=p.accept;this.isover=!1,this.isout=!0,this.accept=typeof x=="function"?x:function(S){return S.is(x)},this.proportions=function(){if(arguments.length)c=arguments[0];else return c||(c={width:this.element[0].offsetWidth,height:this.element[0].offsetHeight})},this._addToManager(p.scope),p.addClasses&&this._addClass("ui-droppable")},_addToManager:function(c){t.ui.ddmanager.droppables[c]=t.ui.ddmanager.droppables[c]||[],t.ui.ddmanager.droppables[c].push(this)},_splice:function(c){for(var p=0;p<c.length;p++)c[p]===this&&c.splice(p,1)},_destroy:function(){var c=t.ui.ddmanager.droppables[this.options.scope];this._splice(c)},_setOption:function(c,p){if(c==="accept")this.accept=typeof p=="function"?p:function(S){return S.is(p)};else if(c==="scope"){var x=t.ui.ddmanager.droppables[this.options.scope];this._splice(x),this._addToManager(p)}this._super(c,p)},_activate:function(c){var p=t.ui.ddmanager.current;this._addActiveClass(),p&&this._trigger("activate",c,this.ui(p))},_deactivate:function(c){var p=t.ui.ddmanager.current;this._removeActiveClass(),p&&this._trigger("deactivate",c,this.ui(p))},_over:function(c){var p=t.ui.ddmanager.current;!p||(p.currentItem||p.element)[0]===this.element[0]||this.accept.call(this.element[0],p.currentItem||p.element)&&(this._addHoverClass(),this._trigger("over",c,this.ui(p)))},_out:function(c){var p=t.ui.ddmanager.current;!p||(p.currentItem||p.element)[0]===this.element[0]||this.accept.call(this.element[0],p.currentItem||p.element)&&(this._removeHoverClass(),this._trigger("out",c,this.ui(p)))},_drop:function(c,p){var x=p||t.ui.ddmanager.current,S=!1;return!x||(x.currentItem||x.element)[0]===this.element[0]||(this.element.find(":data(ui-droppable)").not(".ui-draggable-dragging").each(function(){var b=t(this).droppable("instance");if(b.options.greedy&&!b.options.disabled&&b.options.scope===x.options.scope&&b.accept.call(b.element[0],x.currentItem||x.element)&&t.ui.intersect(x,t.extend(b,{offset:b.element.offset()}),b.options.tolerance,c))return S=!0,!1}),S)?!1:this.accept.call(this.element[0],x.currentItem||x.element)?(this._removeActiveClass(),this._removeHoverClass(),this._trigger("drop",c,this.ui(x)),this.element):!1},ui:function(c){return{draggable:c.currentItem||c.element,helper:c.helper,position:c.position,offset:c.positionAbs}},_addHoverClass:function(){this._addClass("ui-droppable-hover")},_removeHoverClass:function(){this._removeClass("ui-droppable-hover")},_addActiveClass:function(){this._addClass("ui-droppable-active")},_removeActiveClass:function(){this._removeClass("ui-droppable-active")}}),t.ui.intersect=function(){function c(p,x,S){return p>=x&&p<x+S}return function(p,x,S,b){if(!x.offset)return!1;var h=(p.positionAbs||p.position.absolute).left+p.margins.left,T=(p.positionAbs||p.position.absolute).top+p.margins.top,M=h+p.helperProportions.width,O=T+p.helperProportions.height,V=x.offset.left,ee=x.offset.top,Z=V+x.proportions().width,U=ee+x.proportions().height;switch(S){case"fit":return V<=h&&M<=Z&&ee<=T&&O<=U;case"intersect":return V<h+p.helperProportions.width/2&&M-p.helperProportions.width/2<Z&&ee<T+p.helperProportions.height/2&&O-p.helperProportions.height/2<U;case"pointer":return c(b.pageY,ee,x.proportions().height)&&c(b.pageX,V,x.proportions().width);case"touch":return(T>=ee&&T<=U||O>=ee&&O<=U||T<ee&&O>U)&&(h>=V&&h<=Z||M>=V&&M<=Z||h<V&&M>Z);default:return!1}}}(),t.ui.ddmanager={current:null,droppables:{default:[]},prepareOffsets:function(c,p){var x,S,b=t.ui.ddmanager.droppables[c.options.scope]||[],h=p?p.type:null,T=(c.currentItem||c.element).find(":data(ui-droppable)").addBack();e:for(x=0;x<b.length;x++)if(!(b[x].options.disabled||c&&!b[x].accept.call(b[x].element[0],c.currentItem||c.element))){for(S=0;S<T.length;S++)if(T[S]===b[x].element[0]){b[x].proportions().height=0;continue e}b[x].visible=b[x].element.css("display")!=="none",b[x].visible&&(h==="mousedown"&&b[x]._activate.call(b[x],p),b[x].offset=b[x].element.offset(),b[x].proportions({width:b[x].element[0].offsetWidth,height:b[x].element[0].offsetHeight}))}},drop:function(c,p){var x=!1;return t.each((t.ui.ddmanager.droppables[c.options.scope]||[]).slice(),function(){this.options&&(!this.options.disabled&&this.visible&&t.ui.intersect(c,this,this.options.tolerance,p)&&(x=this._drop.call(this,p)||x),!this.options.disabled&&this.visible&&this.accept.call(this.element[0],c.currentItem||c.element)&&(this.isout=!0,this.isover=!1,this._deactivate.call(this,p)))}),x},dragStart:function(c,p){c.element.parentsUntil("body").on("scroll.droppable",function(){c.options.refreshPositions||t.ui.ddmanager.prepareOffsets(c,p)})},drag:function(c,p){c.options.refreshPositions&&t.ui.ddmanager.prepareOffsets(c,p),t.each(t.ui.ddmanager.droppables[c.options.scope]||[],function(){if(!(this.options.disabled||this.greedyChild||!this.visible)){var x,S,b,h=t.ui.intersect(c,this,this.options.tolerance,p),T=!h&&this.isover?"isout":h&&!this.isover?"isover":null;T&&(this.options.greedy&&(S=this.options.scope,b=this.element.parents(":data(ui-droppable)").filter(function(){return t(this).droppable("instance").options.scope===S}),b.length&&(x=t(b[0]).droppable("instance"),x.greedyChild=T==="isover")),x&&T==="isover"&&(x.isover=!1,x.isout=!0,x._out.call(x,p)),this[T]=!0,this[T==="isout"?"isover":"isout"]=!1,this[T==="isover"?"_over":"_out"].call(this,p),x&&T==="isout"&&(x.isout=!1,x.isover=!0,x._over.call(x,p)))}})},dragStop:function(c,p){c.element.parentsUntil("body").off("scroll.droppable"),c.options.refreshPositions||t.ui.ddmanager.prepareOffsets(c,p)}},t.uiBackCompat===!0&&t.widget("ui.droppable",t.ui.droppable,{options:{hoverClass:!1,activeClass:!1},_addActiveClass:function(){this._super(),this.options.activeClass&&this.element.addClass(this.options.activeClass)},_removeActiveClass:function(){this._super(),this.options.activeClass&&this.element.removeClass(this.options.activeClass)},_addHoverClass:function(){this._super(),this.options.hoverClass&&this.element.addClass(this.options.hoverClass)},_removeHoverClass:function(){this._super(),this.options.hoverClass&&this.element.removeClass(this.options.hoverClass)}}),t.ui.droppable;/*!
 * jQuery UI Progressbar 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.progressbar",{version:"1.14.0",options:{classes:{"ui-progressbar":"ui-corner-all","ui-progressbar-value":"ui-corner-left","ui-progressbar-complete":"ui-corner-right"},max:100,value:0,change:null,complete:null},min:0,_create:function(){this.oldValue=this.options.value=this._constrainedValue(),this.element.attr({role:"progressbar","aria-valuemin":this.min}),this._addClass("ui-progressbar","ui-widget ui-widget-content"),this.valueDiv=t("<div>").appendTo(this.element),this._addClass(this.valueDiv,"ui-progressbar-value","ui-widget-header"),this._refreshValue()},_destroy:function(){this.element.removeAttr("role aria-valuemin aria-valuemax aria-valuenow"),this.valueDiv.remove()},value:function(c){if(c===void 0)return this.options.value;this.options.value=this._constrainedValue(c),this._refreshValue()},_constrainedValue:function(c){return c===void 0&&(c=this.options.value),this.indeterminate=c===!1,typeof c!="number"&&(c=0),this.indeterminate?!1:Math.min(this.options.max,Math.max(this.min,c))},_setOptions:function(c){var p=c.value;delete c.value,this._super(c),this.options.value=this._constrainedValue(p),this._refreshValue()},_setOption:function(c,p){c==="max"&&(p=Math.max(this.min,p)),this._super(c,p)},_setOptionDisabled:function(c){this._super(c),this.element.attr("aria-disabled",c),this._toggleClass(null,"ui-state-disabled",!!c)},_percentage:function(){return this.indeterminate?100:100*(this.options.value-this.min)/(this.options.max-this.min)},_refreshValue:function(){var c=this.options.value,p=this._percentage();this.valueDiv.toggle(this.indeterminate||c>this.min).width(p.toFixed(0)+"%"),this._toggleClass(this.valueDiv,"ui-progressbar-complete",null,c===this.options.max)._toggleClass("ui-progressbar-indeterminate",null,this.indeterminate),this.indeterminate?(this.element.removeAttr("aria-valuenow"),this.overlayDiv||(this.overlayDiv=t("<div>").appendTo(this.valueDiv),this._addClass(this.overlayDiv,"ui-progressbar-overlay"))):(this.element.attr({"aria-valuemax":this.options.max,"aria-valuenow":c}),this.overlayDiv&&(this.overlayDiv.remove(),this.overlayDiv=null)),this.oldValue!==c&&(this.oldValue=c,this._trigger("change")),c===this.options.max&&this._trigger("complete")}});/*!
 * jQuery UI Selectable 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.selectable",t.ui.mouse,{version:"1.14.0",options:{appendTo:"body",autoRefresh:!0,distance:0,filter:"*",tolerance:"touch",selected:null,selecting:null,start:null,stop:null,unselected:null,unselecting:null},_create:function(){var c=this;this._addClass("ui-selectable"),this.dragged=!1,this.refresh=function(){c.elementPos=t(c.element[0]).offset(),c.selectees=t(c.options.filter,c.element[0]),c._addClass(c.selectees,"ui-selectee"),c.selectees.each(function(){var p=t(this),x=p.offset(),S={left:x.left-c.elementPos.left,top:x.top-c.elementPos.top};t.data(this,"selectable-item",{element:this,$element:p,left:S.left,top:S.top,right:S.left+p.outerWidth(),bottom:S.top+p.outerHeight(),startselected:!1,selected:p.hasClass("ui-selected"),selecting:p.hasClass("ui-selecting"),unselecting:p.hasClass("ui-unselecting")})})},this.refresh(),this._mouseInit(),this.helper=t("<div>"),this._addClass(this.helper,"ui-selectable-helper")},_destroy:function(){this.selectees.removeData("selectable-item"),this._mouseDestroy()},_mouseStart:function(c){var p=this,x=this.options;this.opos=[c.pageX,c.pageY],this.elementPos=t(this.element[0]).offset(),!this.options.disabled&&(this.selectees=t(x.filter,this.element[0]),this._trigger("start",c),t(x.appendTo).append(this.helper),this.helper.css({left:c.pageX,top:c.pageY,width:0,height:0}),x.autoRefresh&&this.refresh(),this.selectees.filter(".ui-selected").each(function(){var S=t.data(this,"selectable-item");S.startselected=!0,!c.metaKey&&!c.ctrlKey&&(p._removeClass(S.$element,"ui-selected"),S.selected=!1,p._addClass(S.$element,"ui-unselecting"),S.unselecting=!0,p._trigger("unselecting",c,{unselecting:S.element}))}),t(c.target).parents().addBack().each(function(){var S,b=t.data(this,"selectable-item");if(b)return S=!c.metaKey&&!c.ctrlKey||!b.$element.hasClass("ui-selected"),p._removeClass(b.$element,S?"ui-unselecting":"ui-selected")._addClass(b.$element,S?"ui-selecting":"ui-unselecting"),b.unselecting=!S,b.selecting=S,b.selected=S,S?p._trigger("selecting",c,{selecting:b.element}):p._trigger("unselecting",c,{unselecting:b.element}),!1}))},_mouseDrag:function(c){if(this.dragged=!0,!this.options.disabled){var p,x=this,S=this.options,b=this.opos[0],h=this.opos[1],T=c.pageX,M=c.pageY;return b>T&&(p=T,T=b,b=p),h>M&&(p=M,M=h,h=p),this.helper.css({left:b,top:h,width:T-b,height:M-h}),this.selectees.each(function(){var O=t.data(this,"selectable-item"),V=!1,ee={};!O||O.element===x.element[0]||(ee.left=O.left+x.elementPos.left,ee.right=O.right+x.elementPos.left,ee.top=O.top+x.elementPos.top,ee.bottom=O.bottom+x.elementPos.top,S.tolerance==="touch"?V=!(ee.left>T||ee.right<b||ee.top>M||ee.bottom<h):S.tolerance==="fit"&&(V=ee.left>b&&ee.right<T&&ee.top>h&&ee.bottom<M),V?(O.selected&&(x._removeClass(O.$element,"ui-selected"),O.selected=!1),O.unselecting&&(x._removeClass(O.$element,"ui-unselecting"),O.unselecting=!1),O.selecting||(x._addClass(O.$element,"ui-selecting"),O.selecting=!0,x._trigger("selecting",c,{selecting:O.element}))):(O.selecting&&((c.metaKey||c.ctrlKey)&&O.startselected?(x._removeClass(O.$element,"ui-selecting"),O.selecting=!1,x._addClass(O.$element,"ui-selected"),O.selected=!0):(x._removeClass(O.$element,"ui-selecting"),O.selecting=!1,O.startselected&&(x._addClass(O.$element,"ui-unselecting"),O.unselecting=!0),x._trigger("unselecting",c,{unselecting:O.element}))),O.selected&&!c.metaKey&&!c.ctrlKey&&!O.startselected&&(x._removeClass(O.$element,"ui-selected"),O.selected=!1,x._addClass(O.$element,"ui-unselecting"),O.unselecting=!0,x._trigger("unselecting",c,{unselecting:O.element}))))}),!1}},_mouseStop:function(c){var p=this;return this.dragged=!1,t(".ui-unselecting",this.element[0]).each(function(){var x=t.data(this,"selectable-item");p._removeClass(x.$element,"ui-unselecting"),x.unselecting=!1,x.startselected=!1,p._trigger("unselected",c,{unselected:x.element})}),t(".ui-selecting",this.element[0]).each(function(){var x=t.data(this,"selectable-item");p._removeClass(x.$element,"ui-selecting")._addClass(x.$element,"ui-selected"),x.selecting=!1,x.selected=!0,x.startselected=!0,p._trigger("selected",c,{selected:x.element})}),this._trigger("stop",c),this.helper.remove(),!1}});/*!
 * jQuery UI Selectmenu 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.selectmenu",[t.ui.formResetMixin,{version:"1.14.0",defaultElement:"<select>",options:{appendTo:null,classes:{"ui-selectmenu-button-open":"ui-corner-top","ui-selectmenu-button-closed":"ui-corner-all"},disabled:null,icons:{button:"ui-icon-triangle-1-s"},position:{my:"left top",at:"left bottom",collision:"none"},width:!1,change:null,close:null,focus:null,open:null,select:null},_create:function(){var c=this.element.uniqueId().attr("id");this.ids={element:c,button:c+"-button",menu:c+"-menu"},this._drawButton(),this._drawMenu(),this._bindFormResetHandler(),this._rendered=!1,this.menuItems=t()},_drawButton:function(){var c,p=this,x=this._parseOption(this.element.find("option:selected"),this.element[0].selectedIndex);this.labels=this.element.labels().attr("for",this.ids.button),this._on(this.labels,{click:function(S){this.button.trigger("focus"),S.preventDefault()}}),this.element.hide(),this.button=t("<span>",{tabindex:this.options.disabled?-1:0,id:this.ids.button,role:"combobox","aria-expanded":"false","aria-autocomplete":"list","aria-owns":this.ids.menu,"aria-haspopup":"true",title:this.element.attr("title")}).insertAfter(this.element),this._addClass(this.button,"ui-selectmenu-button ui-selectmenu-button-closed","ui-button ui-widget"),c=t("<span>").appendTo(this.button),this._addClass(c,"ui-selectmenu-icon","ui-icon "+this.options.icons.button),this.buttonItem=this._renderButtonItem(x).appendTo(this.button),this.options.width!==!1&&this._resizeButton(),this._on(this.button,this._buttonEvents),this.button.one("focusin",function(){p._rendered||p._refreshMenu()})},_drawMenu:function(){var c=this;this.menu=t("<ul>",{"aria-hidden":"true","aria-labelledby":this.ids.button,id:this.ids.menu}),this.menuWrap=t("<div>").append(this.menu),this._addClass(this.menuWrap,"ui-selectmenu-menu","ui-front"),this.menuWrap.appendTo(this._appendTo()),this.menuInstance=this.menu.menu({classes:{"ui-menu":"ui-corner-bottom"},role:"listbox",select:function(p,x){p.preventDefault(),c._select(x.item.data("ui-selectmenu-item"),p)},focus:function(p,x){var S=x.item.data("ui-selectmenu-item");c.focusIndex!=null&&S.index!==c.focusIndex&&(c._trigger("focus",p,{item:S}),c.isOpen||c._select(S,p)),c.focusIndex=S.index,c.button.attr("aria-activedescendant",c.menuItems.eq(S.index).attr("id"))}}).menu("instance"),this.menuInstance._off(this.menu,"mouseleave"),this.menuInstance._closeOnDocumentClick=function(){return!1},this.menuInstance._isDivider=function(){return!1}},refresh:function(){this._refreshMenu(),this.buttonItem.replaceWith(this.buttonItem=this._renderButtonItem(this._getSelectedItem().data("ui-selectmenu-item")||{})),this.options.width===null&&this._resizeButton()},_refreshMenu:function(){var c,p=this.element.find("option");this.menu.empty(),this._parseOptions(p),this._renderMenu(this.menu,this.items),this.menuInstance.refresh(),this.menuItems=this.menu.find("li").not(".ui-selectmenu-optgroup").find(".ui-menu-item-wrapper"),this._rendered=!0,p.length&&(c=this._getSelectedItem(),this.menuInstance.focus(null,c),this._setAria(c.data("ui-selectmenu-item")),this._setOption("disabled",this.element.prop("disabled")))},open:function(c){this.options.disabled||(this._rendered?(this._removeClass(this.menu.find(".ui-state-active"),null,"ui-state-active"),this.menuInstance.focus(null,this._getSelectedItem())):this._refreshMenu(),this.menuItems.length&&(this.isOpen=!0,this._toggleAttr(),this._resizeMenu(),this._position(),this._on(this.document,this._documentClick),this._trigger("open",c)))},_position:function(){this.menuWrap.position(t.extend({of:this.button},this.options.position))},close:function(c){this.isOpen&&(this.isOpen=!1,this._toggleAttr(),this.range=null,this._off(this.document),this._trigger("close",c))},widget:function(){return this.button},menuWidget:function(){return this.menu},_renderButtonItem:function(c){var p=t("<span>");return this._setText(p,c.label),this._addClass(p,"ui-selectmenu-text"),p},_renderMenu:function(c,p){var x=this,S="";t.each(p,function(b,h){var T;h.optgroup!==S&&(T=t("<li>",{text:h.optgroup}),x._addClass(T,"ui-selectmenu-optgroup","ui-menu-divider"+(h.element.parent("optgroup").prop("disabled")?" ui-state-disabled":"")),T.appendTo(c),S=h.optgroup),x._renderItemData(c,h)})},_renderItemData:function(c,p){return this._renderItem(c,p).data("ui-selectmenu-item",p)},_renderItem:function(c,p){var x=t("<li>"),S=t("<div>",{title:p.element.attr("title")});return p.disabled&&this._addClass(x,null,"ui-state-disabled"),p.hidden?x.prop("hidden",!0):this._setText(S,p.label),x.append(S).appendTo(c)},_setText:function(c,p){p?c.text(p):c.html("&#160;")},_move:function(c,p){var x,S,b=".ui-menu-item";this.isOpen?x=this.menuItems.eq(this.focusIndex).parent("li"):(x=this.menuItems.eq(this.element[0].selectedIndex).parent("li"),b+=":not(.ui-state-disabled)"),c==="first"||c==="last"?S=x[c==="first"?"prevAll":"nextAll"](b).eq(-1):S=x[c+"All"](b).eq(0),S.length&&this.menuInstance.focus(p,S)},_getSelectedItem:function(){return this.menuItems.eq(this.element[0].selectedIndex).parent("li")},_toggle:function(c){this[this.isOpen?"close":"open"](c)},_setSelection:function(){var c;this.range&&(c=window.getSelection(),c.removeAllRanges(),c.addRange(this.range))},_documentClick:{mousedown:function(c){this.isOpen&&(t(c.target).closest(".ui-selectmenu-menu, #"+CSS.escape(this.ids.button)).length||this.close(c))}},_buttonEvents:{mousedown:function(){var c=window.getSelection();c.rangeCount&&(this.range=c.getRangeAt(0))},click:function(c){this._setSelection(),this._toggle(c)},keydown:function(c){var p=!0;switch(c.keyCode){case t.ui.keyCode.TAB:case t.ui.keyCode.ESCAPE:this.close(c),p=!1;break;case t.ui.keyCode.ENTER:this.isOpen&&this._selectFocusedItem(c);break;case t.ui.keyCode.UP:c.altKey?this._toggle(c):this._move("prev",c);break;case t.ui.keyCode.DOWN:c.altKey?this._toggle(c):this._move("next",c);break;case t.ui.keyCode.SPACE:this.isOpen?this._selectFocusedItem(c):this._toggle(c);break;case t.ui.keyCode.LEFT:this._move("prev",c);break;case t.ui.keyCode.RIGHT:this._move("next",c);break;case t.ui.keyCode.HOME:case t.ui.keyCode.PAGE_UP:this._move("first",c);break;case t.ui.keyCode.END:case t.ui.keyCode.PAGE_DOWN:this._move("last",c);break;default:this.menu.trigger(c),p=!1}p&&c.preventDefault()}},_selectFocusedItem:function(c){var p=this.menuItems.eq(this.focusIndex).parent("li");p.hasClass("ui-state-disabled")||this._select(p.data("ui-selectmenu-item"),c)},_select:function(c,p){var x=this.element[0].selectedIndex;this.element[0].selectedIndex=c.index,this.buttonItem.replaceWith(this.buttonItem=this._renderButtonItem(c)),this._setAria(c),this._trigger("select",p,{item:c}),c.index!==x&&this._trigger("change",p,{item:c}),this.close(p)},_setAria:function(c){var p=this.menuItems.eq(c.index).attr("id");this.button.attr({"aria-labelledby":p,"aria-activedescendant":p}),this.menu.attr("aria-activedescendant",p)},_setOption:function(c,p){if(c==="icons"){var x=this.button.find("span.ui-icon");this._removeClass(x,null,this.options.icons.button)._addClass(x,null,p.button)}this._super(c,p),c==="appendTo"&&this.menuWrap.appendTo(this._appendTo()),c==="width"&&this._resizeButton()},_setOptionDisabled:function(c){this._super(c),this.menuInstance.option("disabled",c),this.button.attr("aria-disabled",c),this._toggleClass(this.button,null,"ui-state-disabled",c),this.element.prop("disabled",c),c?(this.button.attr("tabindex",-1),this.close()):this.button.attr("tabindex",0)},_appendTo:function(){var c=this.options.appendTo;return c&&(c=c.jquery||c.nodeType?t(c):this.document.find(c).eq(0)),(!c||!c[0])&&(c=this.element.closest(".ui-front, dialog")),c.length||(c=this.document[0].body),c},_toggleAttr:function(){this.button.attr("aria-expanded",this.isOpen),this._removeClass(this.button,"ui-selectmenu-button-"+(this.isOpen?"closed":"open"))._addClass(this.button,"ui-selectmenu-button-"+(this.isOpen?"open":"closed"))._toggleClass(this.menuWrap,"ui-selectmenu-open",null,this.isOpen),this.menu.attr("aria-hidden",!this.isOpen)},_resizeButton:function(){var c=this.options.width;if(c===!1){this.button.css("width","");return}c===null&&(c=this.element.show().outerWidth(),this.element.hide()),this.button.outerWidth(c)},_resizeMenu:function(){this.menu.outerWidth(Math.max(this.button.outerWidth(),this.menu.width("").outerWidth()))},_getCreateOptions:function(){var c=this._super();return c.disabled=this.element.prop("disabled"),c},_parseOptions:function(c){var p=this,x=[];c.each(function(S,b){x.push(p._parseOption(t(b),S))}),this.items=x},_parseOption:function(c,p){var x=c.parent("optgroup");return{element:c,index:p,value:c.val(),label:c.text(),hidden:x.prop("hidden")||c.prop("hidden"),optgroup:x.attr("label")||"",disabled:x.prop("disabled")||c.prop("disabled")}},_destroy:function(){this._unbindFormResetHandler(),this.menuWrap.remove(),this.button.remove(),this.element.show(),this.element.removeUniqueId(),this.labels.attr("for",this.ids.element)}}]);/*!
 * jQuery UI Slider 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.slider",t.ui.mouse,{version:"1.14.0",widgetEventPrefix:"slide",options:{animate:!1,classes:{"ui-slider":"ui-corner-all","ui-slider-handle":"ui-corner-all","ui-slider-range":"ui-corner-all ui-widget-header"},distance:0,max:100,min:0,orientation:"horizontal",range:!1,step:1,value:0,values:null,change:null,slide:null,start:null,stop:null},numPages:5,_create:function(){this._keySliding=!1,this._mouseSliding=!1,this._animateOff=!0,this._handleIndex=null,this._detectOrientation(),this._mouseInit(),this._calculateNewMax(),this._addClass("ui-slider ui-slider-"+this.orientation,"ui-widget ui-widget-content"),this._refresh(),this._animateOff=!1},_refresh:function(){this._createRange(),this._createHandles(),this._setupEvents(),this._refreshValue()},_createHandles:function(){var c,p,x=this.options,S=this.element.find(".ui-slider-handle"),b="<span tabindex='0'></span>",h=[];for(p=x.values&&x.values.length||1,S.length>p&&(S.slice(p).remove(),S=S.slice(0,p)),c=S.length;c<p;c++)h.push(b);this.handles=S.add(t(h.join("")).appendTo(this.element)),this._addClass(this.handles,"ui-slider-handle","ui-state-default"),this.handle=this.handles.eq(0),this.handles.each(function(T){t(this).data("ui-slider-handle-index",T).attr("tabIndex",0)})},_createRange:function(){var c=this.options;c.range?(c.range===!0&&(c.values?c.values.length&&c.values.length!==2?c.values=[c.values[0],c.values[0]]:Array.isArray(c.values)&&(c.values=c.values.slice(0)):c.values=[this._valueMin(),this._valueMin()]),!this.range||!this.range.length?(this.range=t("<div>").appendTo(this.element),this._addClass(this.range,"ui-slider-range")):(this._removeClass(this.range,"ui-slider-range-min ui-slider-range-max"),this.range.css({left:"",bottom:""})),(c.range==="min"||c.range==="max")&&this._addClass(this.range,"ui-slider-range-"+c.range)):(this.range&&this.range.remove(),this.range=null)},_setupEvents:function(){this._off(this.handles),this._on(this.handles,this._handleEvents),this._hoverable(this.handles),this._focusable(this.handles)},_destroy:function(){this.handles.remove(),this.range&&this.range.remove(),this._mouseDestroy()},_mouseCapture:function(c){var p,x,S,b,h,T,M,O,V=this,ee=this.options;return ee.disabled||(this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()},this.elementOffset=this.element.offset(),p={x:c.pageX,y:c.pageY},x=this._normValueFromMouse(p),S=this._valueMax()-this._valueMin()+1,this.handles.each(function(Z){var U=Math.abs(x-V.values(Z));(S>U||S===U&&(Z===V._lastChangedValue||V.values(Z)===ee.min))&&(S=U,b=t(this),h=Z)}),T=this._start(c,h),T===!1)?!1:(this._mouseSliding=!0,this._handleIndex=h,this._addClass(b,null,"ui-state-active"),b.trigger("focus"),M=b.offset(),O=!t(c.target).parents().addBack().is(".ui-slider-handle"),this._clickOffset=O?{left:0,top:0}:{left:c.pageX-M.left-b.width()/2,top:c.pageY-M.top-b.height()/2-(parseInt(b.css("borderTopWidth"),10)||0)-(parseInt(b.css("borderBottomWidth"),10)||0)+(parseInt(b.css("marginTop"),10)||0)},this.handles.hasClass("ui-state-hover")||this._slide(c,h,x),this._animateOff=!0,!0)},_mouseStart:function(){return!0},_mouseDrag:function(c){var p={x:c.pageX,y:c.pageY},x=this._normValueFromMouse(p);return this._slide(c,this._handleIndex,x),!1},_mouseStop:function(c){return this._removeClass(this.handles,null,"ui-state-active"),this._mouseSliding=!1,this._stop(c,this._handleIndex),this._change(c,this._handleIndex),this._handleIndex=null,this._clickOffset=null,this._animateOff=!1,!1},_detectOrientation:function(){this.orientation=this.options.orientation==="vertical"?"vertical":"horizontal"},_normValueFromMouse:function(c){var p,x,S,b,h;return this.orientation==="horizontal"?(p=this.elementSize.width,x=c.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)):(p=this.elementSize.height,x=c.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0)),S=x/p,S>1&&(S=1),S<0&&(S=0),this.orientation==="vertical"&&(S=1-S),b=this._valueMax()-this._valueMin(),h=this._valueMin()+S*b,this._trimAlignValue(h)},_uiHash:function(c,p,x){var S={handle:this.handles[c],handleIndex:c,value:p!==void 0?p:this.value()};return this._hasMultipleValues()&&(S.value=p!==void 0?p:this.values(c),S.values=x||this.values()),S},_hasMultipleValues:function(){return this.options.values&&this.options.values.length},_start:function(c,p){return this._trigger("start",c,this._uiHash(p))},_slide:function(c,p,x){var S,b,h=this.value(),T=this.values();this._hasMultipleValues()&&(b=this.values(p?0:1),h=this.values(p),this.options.values.length===2&&this.options.range===!0&&(x=p===0?Math.min(b,x):Math.max(b,x)),T[p]=x),x!==h&&(S=this._trigger("slide",c,this._uiHash(p,x,T)),S!==!1&&(this._hasMultipleValues()?this.values(p,x):this.value(x)))},_stop:function(c,p){this._trigger("stop",c,this._uiHash(p))},_change:function(c,p){!this._keySliding&&!this._mouseSliding&&(this._lastChangedValue=p,this._trigger("change",c,this._uiHash(p)))},value:function(c){if(arguments.length){this.options.value=this._trimAlignValue(c),this._refreshValue(),this._change(null,0);return}return this._value()},values:function(c,p){var x,S,b;if(arguments.length>1){this.options.values[c]=this._trimAlignValue(p),this._refreshValue(),this._change(null,c);return}if(arguments.length)if(Array.isArray(arguments[0])){for(x=this.options.values,S=arguments[0],b=0;b<x.length;b+=1)x[b]=this._trimAlignValue(S[b]),this._change(null,b);this._refreshValue()}else return this._hasMultipleValues()?this._values(c):this.value();else return this._values()},_setOption:function(c,p){var x,S=0;switch(c==="range"&&this.options.range===!0&&(p==="min"?(this.options.value=this._values(0),this.options.values=null):p==="max"&&(this.options.value=this._values(this.options.values.length-1),this.options.values=null)),Array.isArray(this.options.values)&&(S=this.options.values.length),this._super(c,p),c){case"orientation":this._detectOrientation(),this._removeClass("ui-slider-horizontal ui-slider-vertical")._addClass("ui-slider-"+this.orientation),this._refreshValue(),this.options.range&&this._refreshRange(p),this.handles.css(p==="horizontal"?"bottom":"left","");break;case"value":this._animateOff=!0,this._refreshValue(),this._change(null,0),this._animateOff=!1;break;case"values":for(this._animateOff=!0,this._refreshValue(),x=S-1;x>=0;x--)this._change(null,x);this._animateOff=!1;break;case"step":case"min":case"max":this._animateOff=!0,this._calculateNewMax(),this._refreshValue(),this._animateOff=!1;break;case"range":this._animateOff=!0,this._refresh(),this._animateOff=!1;break}},_setOptionDisabled:function(c){this._super(c),this._toggleClass(null,"ui-state-disabled",!!c)},_value:function(){var c=this.options.value;return c=this._trimAlignValue(c),c},_values:function(c){var p,x,S;if(arguments.length)return p=this.options.values[c],p=this._trimAlignValue(p),p;if(this._hasMultipleValues()){for(x=this.options.values.slice(),S=0;S<x.length;S+=1)x[S]=this._trimAlignValue(x[S]);return x}else return[]},_trimAlignValue:function(c){if(c<=this._valueMin())return this._valueMin();if(c>=this._valueMax())return this._valueMax();var p=this.options.step>0?this.options.step:1,x=(c-this._valueMin())%p,S=c-x;return Math.abs(x)*2>=p&&(S+=x>0?p:-p),parseFloat(S.toFixed(5))},_calculateNewMax:function(){var c=this.options.max,p=this._valueMin(),x=this.options.step,S=Math.round((c-p)/x)*x;c=S+p,c>this.options.max&&(c-=x),this.max=parseFloat(c.toFixed(this._precision()))},_precision:function(){var c=this._precisionOf(this.options.step);return this.options.min!==null&&(c=Math.max(c,this._precisionOf(this.options.min))),c},_precisionOf:function(c){var p=c.toString(),x=p.indexOf(".");return x===-1?0:p.length-x-1},_valueMin:function(){return this.options.min},_valueMax:function(){return this.max},_refreshRange:function(c){c==="vertical"&&this.range.css({width:"",left:""}),c==="horizontal"&&this.range.css({height:"",bottom:""})},_refreshValue:function(){var c,p,x,S,b,h=this.options.range,T=this.options,M=this,O=this._animateOff?!1:T.animate,V={};this._hasMultipleValues()?this.handles.each(function(ee){p=(M.values(ee)-M._valueMin())/(M._valueMax()-M._valueMin())*100,V[M.orientation==="horizontal"?"left":"bottom"]=p+"%",t(this).stop(1,1)[O?"animate":"css"](V,T.animate),M.options.range===!0&&(M.orientation==="horizontal"?(ee===0&&M.range.stop(1,1)[O?"animate":"css"]({left:p+"%"},T.animate),ee===1&&M.range[O?"animate":"css"]({width:p-c+"%"},{queue:!1,duration:T.animate})):(ee===0&&M.range.stop(1,1)[O?"animate":"css"]({bottom:p+"%"},T.animate),ee===1&&M.range[O?"animate":"css"]({height:p-c+"%"},{queue:!1,duration:T.animate}))),c=p}):(x=this.value(),S=this._valueMin(),b=this._valueMax(),p=b!==S?(x-S)/(b-S)*100:0,V[this.orientation==="horizontal"?"left":"bottom"]=p+"%",this.handle.stop(1,1)[O?"animate":"css"](V,T.animate),h==="min"&&this.orientation==="horizontal"&&this.range.stop(1,1)[O?"animate":"css"]({width:p+"%"},T.animate),h==="max"&&this.orientation==="horizontal"&&this.range.stop(1,1)[O?"animate":"css"]({width:100-p+"%"},T.animate),h==="min"&&this.orientation==="vertical"&&this.range.stop(1,1)[O?"animate":"css"]({height:p+"%"},T.animate),h==="max"&&this.orientation==="vertical"&&this.range.stop(1,1)[O?"animate":"css"]({height:100-p+"%"},T.animate))},_handleEvents:{keydown:function(c){var p,x,S,b,h=t(c.target).data("ui-slider-handle-index");switch(c.keyCode){case t.ui.keyCode.HOME:case t.ui.keyCode.END:case t.ui.keyCode.PAGE_UP:case t.ui.keyCode.PAGE_DOWN:case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(c.preventDefault(),!this._keySliding&&(this._keySliding=!0,this._addClass(t(c.target),null,"ui-state-active"),p=this._start(c,h),p===!1))return;break}switch(b=this.options.step,this._hasMultipleValues()?x=S=this.values(h):x=S=this.value(),c.keyCode){case t.ui.keyCode.HOME:S=this._valueMin();break;case t.ui.keyCode.END:S=this._valueMax();break;case t.ui.keyCode.PAGE_UP:S=this._trimAlignValue(x+(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.PAGE_DOWN:S=this._trimAlignValue(x-(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:if(x===this._valueMax())return;S=this._trimAlignValue(x+b);break;case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(x===this._valueMin())return;S=this._trimAlignValue(x-b);break}this._slide(c,h,S)},keyup:function(c){var p=t(c.target).data("ui-slider-handle-index");this._keySliding&&(this._keySliding=!1,this._stop(c,p),this._change(c,p),this._removeClass(t(c.target),null,"ui-state-active"))}}});/*!
 * jQuery UI Sortable 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.sortable",t.ui.mouse,{version:"1.14.0",widgetEventPrefix:"sort",ready:!1,options:{appendTo:"parent",axis:!1,connectWith:!1,containment:!1,cursor:"auto",cursorAt:!1,dropOnEmpty:!0,forcePlaceholderSize:!1,forceHelperSize:!1,grid:!1,handle:!1,helper:"original",items:"> *",opacity:!1,placeholder:!1,revert:!1,scroll:!0,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1e3,activate:null,beforeStop:null,change:null,deactivate:null,out:null,over:null,receive:null,remove:null,sort:null,start:null,stop:null,update:null},_isOverAxis:function(c,p,x){return c>=p&&c<p+x},_isFloating:function(c){return/left|right/.test(c.css("float"))||/inline|table-cell/.test(c.css("display"))},_create:function(){this.containerCache={},this._addClass("ui-sortable"),this.refresh(),this.offset=this.element.offset(),this._mouseInit(),this._setHandleClassName(),this.ready=!0},_setOption:function(c,p){this._super(c,p),c==="handle"&&this._setHandleClassName()},_setHandleClassName:function(){var c=this;this._removeClass(this.element.find(".ui-sortable-handle"),"ui-sortable-handle"),t.each(this.items,function(){c._addClass(this.instance.options.handle?this.item.find(this.instance.options.handle):this.item,"ui-sortable-handle")})},_destroy:function(){this._mouseDestroy();for(var c=this.items.length-1;c>=0;c--)this.items[c].item.removeData(this.widgetName+"-item");return this},_mouseCapture:function(c,p){var x=null,S=!1,b=this;return this.reverting||this.options.disabled||this.options.type==="static"||(this._refreshItems(c),t(c.target).parents().each(function(){if(t.data(this,b.widgetName+"-item")===b)return x=t(this),!1}),t.data(c.target,b.widgetName+"-item")===b&&(x=t(c.target)),!x)||this.options.handle&&!p&&(t(this.options.handle,x).find("*").addBack().each(function(){this===c.target&&(S=!0)}),!S)?!1:(this.currentItem=x,this._removeCurrentsFromItems(),!0)},_mouseStart:function(c,p,x){var S,b,h=this.options;if(this.currentContainer=this,this.refreshPositions(),this.appendTo=t(h.appendTo!=="parent"?h.appendTo:this.currentItem.parent()),this.helper=this._createHelper(c),this._cacheHelperProportions(),this._cacheMargins(),this.offset=this.currentItem.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},t.extend(this.offset,{click:{left:c.pageX-this.offset.left,top:c.pageY-this.offset.top},relative:this._getRelativeOffset()}),this.helper.css("position","absolute"),this.cssPosition=this.helper.css("position"),h.cursorAt&&this._adjustOffsetFromHelper(h.cursorAt),this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]},this.helper[0]!==this.currentItem[0]&&this.currentItem.hide(),this._createPlaceholder(),this.scrollParent=this.placeholder.scrollParent(),t.extend(this.offset,{parent:this._getParentOffset()}),h.containment&&this._setContainment(),h.cursor&&h.cursor!=="auto"&&(b=this.document.find("body"),this._storedStylesheet=t("<style>*{ cursor: "+h.cursor+" !important; }</style>").appendTo(b)),h.zIndex&&(this.helper.css("zIndex")&&(this._storedZIndex=this.helper.css("zIndex")),this.helper.css("zIndex",h.zIndex)),h.opacity&&(this.helper.css("opacity")&&(this._storedOpacity=this.helper.css("opacity")),this.helper.css("opacity",h.opacity)),this.scrollParent[0]!==this.document[0]&&this.scrollParent[0].tagName!=="HTML"&&(this.overflowOffset=this.scrollParent.offset()),this._trigger("start",c,this._uiHash()),this._preserveHelperProportions||this._cacheHelperProportions(),!x)for(S=this.containers.length-1;S>=0;S--)this.containers[S]._trigger("activate",c,this._uiHash(this));return t.ui.ddmanager&&(t.ui.ddmanager.current=this),t.ui.ddmanager&&!h.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,c),this.dragging=!0,this._addClass(this.helper,"ui-sortable-helper"),this.helper.parent().is(this.appendTo)||(this.helper.detach().appendTo(this.appendTo),this.offset.parent=this._getParentOffset()),this.position=this.originalPosition=this._generatePosition(c),this.originalPageX=c.pageX,this.originalPageY=c.pageY,this.lastPositionAbs=this.positionAbs=this._convertPositionTo("absolute"),this._mouseDrag(c),!0},_scroll:function(c){var p=this.options,x=!1;return this.scrollParent[0]!==this.document[0]&&this.scrollParent[0].tagName!=="HTML"?(this.overflowOffset.top+this.scrollParent[0].offsetHeight-c.pageY<p.scrollSensitivity?this.scrollParent[0].scrollTop=x=this.scrollParent[0].scrollTop+p.scrollSpeed:c.pageY-this.overflowOffset.top<p.scrollSensitivity&&(this.scrollParent[0].scrollTop=x=this.scrollParent[0].scrollTop-p.scrollSpeed),this.overflowOffset.left+this.scrollParent[0].offsetWidth-c.pageX<p.scrollSensitivity?this.scrollParent[0].scrollLeft=x=this.scrollParent[0].scrollLeft+p.scrollSpeed:c.pageX-this.overflowOffset.left<p.scrollSensitivity&&(this.scrollParent[0].scrollLeft=x=this.scrollParent[0].scrollLeft-p.scrollSpeed)):(c.pageY-this.document.scrollTop()<p.scrollSensitivity?x=this.document.scrollTop(this.document.scrollTop()-p.scrollSpeed):this.window.height()-(c.pageY-this.document.scrollTop())<p.scrollSensitivity&&(x=this.document.scrollTop(this.document.scrollTop()+p.scrollSpeed)),c.pageX-this.document.scrollLeft()<p.scrollSensitivity?x=this.document.scrollLeft(this.document.scrollLeft()-p.scrollSpeed):this.window.width()-(c.pageX-this.document.scrollLeft())<p.scrollSensitivity&&(x=this.document.scrollLeft(this.document.scrollLeft()+p.scrollSpeed))),x},_mouseDrag:function(c){var p,x,S,b,h=this.options;for(this.position=this._generatePosition(c),this.positionAbs=this._convertPositionTo("absolute"),(!this.options.axis||this.options.axis!=="y")&&(this.helper[0].style.left=this.position.left+"px"),(!this.options.axis||this.options.axis!=="x")&&(this.helper[0].style.top=this.position.top+"px"),h.scroll&&this._scroll(c)!==!1&&(this._refreshItemPositions(!0),t.ui.ddmanager&&!h.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,c)),this.dragDirection={vertical:this._getDragVerticalDirection(),horizontal:this._getDragHorizontalDirection()},p=this.items.length-1;p>=0;p--)if(x=this.items[p],S=x.item[0],b=this._intersectsWithPointer(x),!!b&&x.instance===this.currentContainer&&S!==this.currentItem[0]&&this.placeholder[b===1?"next":"prev"]()[0]!==S&&!t.contains(this.placeholder[0],S)&&(this.options.type!=="semi-dynamic"||!t.contains(this.element[0],S))){if(this.direction=b===1?"down":"up",this.options.tolerance==="pointer"||this._intersectsWithSides(x))this._rearrange(c,x);else break;this._trigger("change",c,this._uiHash());break}return this._contactContainers(c),t.ui.ddmanager&&t.ui.ddmanager.drag(this,c),this._trigger("sort",c,this._uiHash()),this.lastPositionAbs=this.positionAbs,!1},_mouseStop:function(c,p){if(c){if(t.ui.ddmanager&&!this.options.dropBehaviour&&t.ui.ddmanager.drop(this,c),this.options.revert){var x=this,S=this.placeholder.offset(),b=this.options.axis,h={};(!b||b==="x")&&(h.left=S.left-this.offset.parent.left-this.margins.left+(this.offsetParent[0]===this.document[0].body?0:this.offsetParent[0].scrollLeft)),(!b||b==="y")&&(h.top=S.top-this.offset.parent.top-this.margins.top+(this.offsetParent[0]===this.document[0].body?0:this.offsetParent[0].scrollTop)),this.reverting=!0,t(this.helper).animate(h,parseInt(this.options.revert,10)||500,function(){x._clear(c)})}else this._clear(c,p);return!1}},cancel:function(){if(this.dragging){this._mouseUp(new t.Event("mouseup",{target:null})),this.options.helper==="original"?(this.currentItem.css(this._storedCSS),this._removeClass(this.currentItem,"ui-sortable-helper")):this.currentItem.show();for(var c=this.containers.length-1;c>=0;c--)this.containers[c]._trigger("deactivate",null,this._uiHash(this)),this.containers[c].containerCache.over&&(this.containers[c]._trigger("out",null,this._uiHash(this)),this.containers[c].containerCache.over=0)}return this.placeholder&&(this.placeholder[0].parentNode&&this.placeholder[0].parentNode.removeChild(this.placeholder[0]),this.options.helper!=="original"&&this.helper&&this.helper[0].parentNode&&this.helper.remove(),t.extend(this,{helper:null,dragging:!1,reverting:!1,_noFinalSort:null}),this.domPosition.prev?t(this.domPosition.prev).after(this.currentItem):t(this.domPosition.parent).prepend(this.currentItem)),this},serialize:function(c){var p=this._getItemsAsjQuery(c&&c.connected),x=[];return c=c||{},t(p).each(function(){var S=(t(c.item||this).attr(c.attribute||"id")||"").match(c.expression||/(.+)[\-=_](.+)/);S&&x.push((c.key||S[1]+"[]")+"="+(c.key&&c.expression?S[1]:S[2]))}),!x.length&&c.key&&x.push(c.key+"="),x.join("&")},toArray:function(c){var p=this._getItemsAsjQuery(c&&c.connected),x=[];return c=c||{},p.each(function(){x.push(t(c.item||this).attr(c.attribute||"id")||"")}),x},_intersectsWith:function(c){var p=this.positionAbs.left,x=p+this.helperProportions.width,S=this.positionAbs.top,b=S+this.helperProportions.height,h=c.left,T=h+c.width,M=c.top,O=M+c.height,V=this.offset.click.top,ee=this.offset.click.left,Z=this.options.axis==="x"||S+V>M&&S+V<O,U=this.options.axis==="y"||p+ee>h&&p+ee<T,z=Z&&U;return this.options.tolerance==="pointer"||this.options.forcePointerForContainers||this.options.tolerance!=="pointer"&&this.helperProportions[this.floating?"width":"height"]>c[this.floating?"width":"height"]?z:h<p+this.helperProportions.width/2&&x-this.helperProportions.width/2<T&&M<S+this.helperProportions.height/2&&b-this.helperProportions.height/2<O},_intersectsWithPointer:function(c){var p,x,S=this.options.axis==="x"||this._isOverAxis(this.positionAbs.top+this.offset.click.top,c.top,c.height),b=this.options.axis==="y"||this._isOverAxis(this.positionAbs.left+this.offset.click.left,c.left,c.width),h=S&&b;return h?(p=this.dragDirection.vertical,x=this.dragDirection.horizontal,this.floating?x==="right"||p==="down"?2:1:p&&(p==="down"?2:1)):!1},_intersectsWithSides:function(c){var p=this._isOverAxis(this.positionAbs.top+this.offset.click.top,c.top+c.height/2,c.height),x=this._isOverAxis(this.positionAbs.left+this.offset.click.left,c.left+c.width/2,c.width),S=this.dragDirection.vertical,b=this.dragDirection.horizontal;return this.floating&&b?b==="right"&&x||b==="left"&&!x:S&&(S==="down"&&p||S==="up"&&!p)},_getDragVerticalDirection:function(){var c=this.positionAbs.top-this.lastPositionAbs.top;return c!==0&&(c>0?"down":"up")},_getDragHorizontalDirection:function(){var c=this.positionAbs.left-this.lastPositionAbs.left;return c!==0&&(c>0?"right":"left")},refresh:function(c){return this._refreshItems(c),this._setHandleClassName(),this.refreshPositions(),this},_connectWith:function(){var c=this.options;return c.connectWith.constructor===String?[c.connectWith]:c.connectWith},_getItemsAsjQuery:function(c){var p,x,S,b,h=[],T=[],M=this._connectWith();if(M&&c)for(p=M.length-1;p>=0;p--)for(S=t(M[p],this.document[0]),x=S.length-1;x>=0;x--)b=t.data(S[x],this.widgetFullName),b&&b!==this&&!b.options.disabled&&T.push([typeof b.options.items=="function"?b.options.items.call(b.element):t(b.options.items,b.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),b]);T.push([typeof this.options.items=="function"?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):t(this.options.items,this.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),this]);function O(){h.push(this)}for(p=T.length-1;p>=0;p--)T[p][0].each(O);return t(h)},_removeCurrentsFromItems:function(){var c=this.currentItem.find(":data("+this.widgetName+"-item)");this.items=t.grep(this.items,function(p){for(var x=0;x<c.length;x++)if(c[x]===p.item[0])return!1;return!0})},_refreshItems:function(c){this.items=[],this.containers=[this];var p,x,S,b,h,T,M,O,V=this.items,ee=[[typeof this.options.items=="function"?this.options.items.call(this.element[0],c,{item:this.currentItem}):t(this.options.items,this.element),this]],Z=this._connectWith();if(Z&&this.ready)for(p=Z.length-1;p>=0;p--)for(S=t(Z[p],this.document[0]),x=S.length-1;x>=0;x--)b=t.data(S[x],this.widgetFullName),b&&b!==this&&!b.options.disabled&&(ee.push([typeof b.options.items=="function"?b.options.items.call(b.element[0],c,{item:this.currentItem}):t(b.options.items,b.element),b]),this.containers.push(b));for(p=ee.length-1;p>=0;p--)for(h=ee[p][1],T=ee[p][0],x=0,O=T.length;x<O;x++)M=t(T[x]),M.data(this.widgetName+"-item",h),V.push({item:M,instance:h,width:0,height:0,left:0,top:0})},_refreshItemPositions:function(c){var p,x,S,b;for(p=this.items.length-1;p>=0;p--)x=this.items[p],!(this.currentContainer&&x.instance!==this.currentContainer&&x.item[0]!==this.currentItem[0])&&(S=this.options.toleranceElement?t(this.options.toleranceElement,x.item):x.item,c||(x.width=S.outerWidth(),x.height=S.outerHeight()),b=S.offset(),x.left=b.left,x.top=b.top)},refreshPositions:function(c){this.floating=this.items.length?this.options.axis==="x"||this._isFloating(this.items[0].item):!1,this.offsetParent&&this.helper&&(this.offset.parent=this._getParentOffset()),this._refreshItemPositions(c);var p,x;if(this.options.custom&&this.options.custom.refreshContainers)this.options.custom.refreshContainers.call(this);else for(p=this.containers.length-1;p>=0;p--)x=this.containers[p].element.offset(),this.containers[p].containerCache.left=x.left,this.containers[p].containerCache.top=x.top,this.containers[p].containerCache.width=this.containers[p].element.outerWidth(),this.containers[p].containerCache.height=this.containers[p].element.outerHeight();return this},_createPlaceholder:function(c){c=c||this;var p,x,S=c.options;(!S.placeholder||S.placeholder.constructor===String)&&(p=S.placeholder,x=c.currentItem[0].nodeName.toLowerCase(),S.placeholder={element:function(){var b=t("<"+x+">",c.document[0]);return c._addClass(b,"ui-sortable-placeholder",p||c.currentItem[0].className)._removeClass(b,"ui-sortable-helper"),x==="tbody"?c._createTrPlaceholder(c.currentItem.find("tr").eq(0),t("<tr>",c.document[0]).appendTo(b)):x==="tr"?c._createTrPlaceholder(c.currentItem,b):x==="img"&&b.attr("src",c.currentItem.attr("src")),p||b.css("visibility","hidden"),b},update:function(b,h){p&&!S.forcePlaceholderSize||((!h.height()||S.forcePlaceholderSize&&(x==="tbody"||x==="tr"))&&h.height(c.currentItem.innerHeight()-parseInt(c.currentItem.css("paddingTop")||0,10)-parseInt(c.currentItem.css("paddingBottom")||0,10)),h.width()||h.width(c.currentItem.innerWidth()-parseInt(c.currentItem.css("paddingLeft")||0,10)-parseInt(c.currentItem.css("paddingRight")||0,10)))}}),c.placeholder=t(S.placeholder.element.call(c.element,c.currentItem)),c.currentItem.after(c.placeholder),S.placeholder.update(c,c.placeholder)},_createTrPlaceholder:function(c,p){var x=this;c.children().each(function(){t("<td>&#160;</td>",x.document[0]).attr("colspan",t(this).attr("colspan")||1).appendTo(p)})},_contactContainers:function(c){var p,x,S,b,h,T,M,O,V,ee,Z=null,U=null;for(p=this.containers.length-1;p>=0;p--)if(!t.contains(this.currentItem[0],this.containers[p].element[0]))if(this._intersectsWith(this.containers[p].containerCache)){if(Z&&t.contains(this.containers[p].element[0],Z.element[0]))continue;Z=this.containers[p],U=p}else this.containers[p].containerCache.over&&(this.containers[p]._trigger("out",c,this._uiHash(this)),this.containers[p].containerCache.over=0);if(Z)if(this.containers.length===1)this.containers[U].containerCache.over||(this.containers[U]._trigger("over",c,this._uiHash(this)),this.containers[U].containerCache.over=1);else{for(S=1e4,b=null,V=Z.floating||this._isFloating(this.currentItem),h=V?"left":"top",T=V?"width":"height",ee=V?"pageX":"pageY",x=this.items.length-1;x>=0;x--)t.contains(this.containers[U].element[0],this.items[x].item[0])&&this.items[x].item[0]!==this.currentItem[0]&&(M=this.items[x].item.offset()[h],O=!1,c[ee]-M>this.items[x][T]/2&&(O=!0),Math.abs(c[ee]-M)<S&&(S=Math.abs(c[ee]-M),b=this.items[x],this.direction=O?"up":"down"));if(!b&&!this.options.dropOnEmpty)return;if(this.currentContainer===this.containers[U]){this.currentContainer.containerCache.over||(this.containers[U]._trigger("over",c,this._uiHash()),this.currentContainer.containerCache.over=1);return}b?this._rearrange(c,b,null,!0):this._rearrange(c,null,this.containers[U].element,!0),this._trigger("change",c,this._uiHash()),this.containers[U]._trigger("change",c,this._uiHash(this)),this.currentContainer=this.containers[U],this.options.placeholder.update(this.currentContainer,this.placeholder),this.scrollParent=this.placeholder.scrollParent(),this.scrollParent[0]!==this.document[0]&&this.scrollParent[0].tagName!=="HTML"&&(this.overflowOffset=this.scrollParent.offset()),this.containers[U]._trigger("over",c,this._uiHash(this)),this.containers[U].containerCache.over=1}},_createHelper:function(c){var p=this.options,x=typeof p.helper=="function"?t(p.helper.apply(this.element[0],[c,this.currentItem])):p.helper==="clone"?this.currentItem.clone():this.currentItem;return x.parents("body").length||this.appendTo[0].appendChild(x[0]),x[0]===this.currentItem[0]&&(this._storedCSS={width:this.currentItem[0].style.width,height:this.currentItem[0].style.height,position:this.currentItem.css("position"),top:this.currentItem.css("top"),left:this.currentItem.css("left")}),(!x[0].style.width||p.forceHelperSize)&&x.width(this.currentItem.width()),(!x[0].style.height||p.forceHelperSize)&&x.height(this.currentItem.height()),x},_adjustOffsetFromHelper:function(c){typeof c=="string"&&(c=c.split(" ")),Array.isArray(c)&&(c={left:+c[0],top:+c[1]||0}),"left"in c&&(this.offset.click.left=c.left+this.margins.left),"right"in c&&(this.offset.click.left=this.helperProportions.width-c.right+this.margins.left),"top"in c&&(this.offset.click.top=c.top+this.margins.top),"bottom"in c&&(this.offset.click.top=this.helperProportions.height-c.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var c=this.offsetParent.offset();return this.cssPosition==="absolute"&&this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0])&&(c.left+=this.scrollParent.scrollLeft(),c.top+=this.scrollParent.scrollTop()),this.offsetParent[0]===this.document[0].body&&(c={top:0,left:0}),{top:c.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:c.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if(this.cssPosition==="relative"){var c=this.currentItem.position();return{top:c.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:c.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}else return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.currentItem.css("marginLeft"),10)||0,top:parseInt(this.currentItem.css("marginTop"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var c,p,x,S=this.options;S.containment==="parent"&&(S.containment=this.helper[0].parentNode),(S.containment==="document"||S.containment==="window")&&(this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,S.containment==="document"?this.document.width():this.window.width()-this.helperProportions.width-this.margins.left,(S.containment==="document"?this.document.height()||document.body.parentNode.scrollHeight:this.window.height()||this.document[0].body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]),/^(document|window|parent)$/.test(S.containment)||(c=t(S.containment)[0],p=t(S.containment).offset(),x=t(c).css("overflow")!=="hidden",this.containment=[p.left+(parseInt(t(c).css("borderLeftWidth"),10)||0)+(parseInt(t(c).css("paddingLeft"),10)||0)-this.margins.left,p.top+(parseInt(t(c).css("borderTopWidth"),10)||0)+(parseInt(t(c).css("paddingTop"),10)||0)-this.margins.top,p.left+(x?Math.max(c.scrollWidth,c.offsetWidth):c.offsetWidth)-(parseInt(t(c).css("borderLeftWidth"),10)||0)-(parseInt(t(c).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left,p.top+(x?Math.max(c.scrollHeight,c.offsetHeight):c.offsetHeight)-(parseInt(t(c).css("borderTopWidth"),10)||0)-(parseInt(t(c).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top])},_convertPositionTo:function(c,p){p||(p=this.position);var x=c==="absolute"?1:-1,S=this.cssPosition==="absolute"&&!(this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0]))?this.offsetParent:this.scrollParent,b=/(html|body)/i.test(S[0].tagName);return{top:p.top+this.offset.relative.top*x+this.offset.parent.top*x-(this.cssPosition==="fixed"?-this.scrollParent.scrollTop():b?0:S.scrollTop())*x,left:p.left+this.offset.relative.left*x+this.offset.parent.left*x-(this.cssPosition==="fixed"?-this.scrollParent.scrollLeft():b?0:S.scrollLeft())*x}},_generatePosition:function(c){var p,x,S=this.options,b=c.pageX,h=c.pageY,T=this.cssPosition==="absolute"&&!(this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0]))?this.offsetParent:this.scrollParent,M=/(html|body)/i.test(T[0].tagName);return this.cssPosition==="relative"&&!(this.scrollParent[0]!==this.document[0]&&this.scrollParent[0]!==this.offsetParent[0])&&(this.offset.relative=this._getRelativeOffset()),this.originalPosition&&(this.containment&&(c.pageX-this.offset.click.left<this.containment[0]&&(b=this.containment[0]+this.offset.click.left),c.pageY-this.offset.click.top<this.containment[1]&&(h=this.containment[1]+this.offset.click.top),c.pageX-this.offset.click.left>this.containment[2]&&(b=this.containment[2]+this.offset.click.left),c.pageY-this.offset.click.top>this.containment[3]&&(h=this.containment[3]+this.offset.click.top)),S.grid&&(p=this.originalPageY+Math.round((h-this.originalPageY)/S.grid[1])*S.grid[1],h=this.containment?p-this.offset.click.top>=this.containment[1]&&p-this.offset.click.top<=this.containment[3]?p:p-this.offset.click.top>=this.containment[1]?p-S.grid[1]:p+S.grid[1]:p,x=this.originalPageX+Math.round((b-this.originalPageX)/S.grid[0])*S.grid[0],b=this.containment?x-this.offset.click.left>=this.containment[0]&&x-this.offset.click.left<=this.containment[2]?x:x-this.offset.click.left>=this.containment[0]?x-S.grid[0]:x+S.grid[0]:x)),{top:h-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+(this.cssPosition==="fixed"?-this.scrollParent.scrollTop():M?0:T.scrollTop()),left:b-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+(this.cssPosition==="fixed"?-this.scrollParent.scrollLeft():M?0:T.scrollLeft())}},_rearrange:function(c,p,x,S){x?x[0].appendChild(this.placeholder[0]):p.item[0].parentNode.insertBefore(this.placeholder[0],this.direction==="down"?p.item[0]:p.item[0].nextSibling),this.counter=this.counter?++this.counter:1;var b=this.counter;this._delay(function(){b===this.counter&&this.refreshPositions(!S)})},_clear:function(c,p){this.reverting=!1;var x,S=[];if(!this._noFinalSort&&this.currentItem.parent().length&&this.placeholder.before(this.currentItem),this._noFinalSort=null,this.helper[0]===this.currentItem[0]){for(x in this._storedCSS)(this._storedCSS[x]==="auto"||this._storedCSS[x]==="static")&&(this._storedCSS[x]="");this.currentItem.css(this._storedCSS),this._removeClass(this.currentItem,"ui-sortable-helper")}else this.currentItem.show();this.fromOutside&&!p&&S.push(function(h){this._trigger("receive",h,this._uiHash(this.fromOutside))}),(this.fromOutside||this.domPosition.prev!==this.currentItem.prev().not(".ui-sortable-helper")[0]||this.domPosition.parent!==this.currentItem.parent()[0])&&!p&&S.push(function(h){this._trigger("update",h,this._uiHash())}),this!==this.currentContainer&&(p||(S.push(function(h){this._trigger("remove",h,this._uiHash())}),S.push((function(h){return function(T){h._trigger("receive",T,this._uiHash(this))}}).call(this,this.currentContainer)),S.push((function(h){return function(T){h._trigger("update",T,this._uiHash(this))}}).call(this,this.currentContainer))));function b(h,T,M){return function(O){M._trigger(h,O,T._uiHash(T))}}for(x=this.containers.length-1;x>=0;x--)p||S.push(b("deactivate",this,this.containers[x])),this.containers[x].containerCache.over&&(S.push(b("out",this,this.containers[x])),this.containers[x].containerCache.over=0);if(this._storedStylesheet&&(this._storedStylesheet.remove(),this._storedStylesheet=null),this._storedOpacity&&this.helper.css("opacity",this._storedOpacity),this._storedZIndex&&this.helper.css("zIndex",this._storedZIndex==="auto"?"":this._storedZIndex),this.dragging=!1,p||this._trigger("beforeStop",c,this._uiHash()),this.placeholder[0].parentNode.removeChild(this.placeholder[0]),this.cancelHelperRemoval||(this.helper[0]!==this.currentItem[0]&&this.helper.remove(),this.helper=null),!p){for(x=0;x<S.length;x++)S[x].call(this,c);this._trigger("stop",c,this._uiHash())}return this.fromOutside=!1,!this.cancelHelperRemoval},_trigger:function(){t.Widget.prototype._trigger.apply(this,arguments)===!1&&this.cancel()},_uiHash:function(c){var p=c||this;return{helper:p.helper,placeholder:p.placeholder||t([]),position:p.position,originalPosition:p.originalPosition,offset:p.positionAbs,item:p.currentItem,sender:c?c.element:null}}});/*!
 * jQuery UI Spinner 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */function w(c){return function(){var p=this.element.val();c.apply(this,arguments),this._refresh(),p!==this.element.val()&&this._trigger("change")}}t.widget("ui.spinner",{version:"1.14.0",defaultElement:"<input>",widgetEventPrefix:"spin",options:{classes:{"ui-spinner":"ui-corner-all","ui-spinner-down":"ui-corner-br","ui-spinner-up":"ui-corner-tr"},culture:null,icons:{down:"ui-icon-triangle-1-s",up:"ui-icon-triangle-1-n"},incremental:!0,max:null,min:null,numberFormat:null,page:10,step:1,change:null,spin:null,start:null,stop:null},_create:function(){this._setOption("max",this.options.max),this._setOption("min",this.options.min),this._setOption("step",this.options.step),this.value()!==""&&this._value(this.element.val(),!0),this._draw(),this._on(this._events),this._refresh(),this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_getCreateOptions:function(){var c=this._super(),p=this.element;return t.each(["min","max","step"],function(x,S){var b=p.attr(S);b!=null&&b.length&&(c[S]=b)}),c},_events:{keydown:function(c){this._start(c)&&this._keydown(c)&&c.preventDefault()},keyup:"_stop",focus:function(){this.previous=this.element.val()},blur:function(c){this._stop(),this._refresh(),this.previous!==this.element.val()&&this._trigger("change",c)},mousewheel:function(c,p){var x=this.document[0].activeElement,S=this.element[0]===x;if(!(!S||!p)){if(!this.spinning&&!this._start(c))return!1;this._spin((p>0?1:-1)*this.options.step,c),clearTimeout(this.mousewheelTimer),this.mousewheelTimer=this._delay(function(){this.spinning&&this._stop(c)},100),c.preventDefault()}},"mousedown .ui-spinner-button":function(c){var p;p=this.element[0]===this.document[0].activeElement?this.previous:this.element.val();function x(){var S=this.element[0]===this.document[0].activeElement;S||(this.element.trigger("focus"),this.previous=p)}c.preventDefault(),x.call(this),this._start(c)!==!1&&this._repeat(null,t(c.currentTarget).hasClass("ui-spinner-up")?1:-1,c)},"mouseup .ui-spinner-button":"_stop","mouseenter .ui-spinner-button":function(c){if(t(c.currentTarget).hasClass("ui-state-active")){if(this._start(c)===!1)return!1;this._repeat(null,t(c.currentTarget).hasClass("ui-spinner-up")?1:-1,c)}},"mouseleave .ui-spinner-button":"_stop"},_enhance:function(){this.uiSpinner=this.element.attr("autocomplete","off").wrap("<span>").parent().append("<a></a><a></a>")},_draw:function(){this._enhance(),this._addClass(this.uiSpinner,"ui-spinner","ui-widget ui-widget-content"),this._addClass("ui-spinner-input"),this.element.attr("role","spinbutton"),this.buttons=this.uiSpinner.children("a").attr("tabIndex",-1).attr("aria-hidden",!0).button({classes:{"ui-button":""}}),this._removeClass(this.buttons,"ui-corner-all"),this._addClass(this.buttons.first(),"ui-spinner-button ui-spinner-up"),this._addClass(this.buttons.last(),"ui-spinner-button ui-spinner-down"),this.buttons.first().button({icon:this.options.icons.up,showLabel:!1}),this.buttons.last().button({icon:this.options.icons.down,showLabel:!1}),this.buttons.height()>Math.ceil(this.uiSpinner.height()*.5)&&this.uiSpinner.height()>0&&this.uiSpinner.height(this.uiSpinner.height())},_keydown:function(c){var p=this.options,x=t.ui.keyCode;switch(c.keyCode){case x.UP:return this._repeat(null,1,c),!0;case x.DOWN:return this._repeat(null,-1,c),!0;case x.PAGE_UP:return this._repeat(null,p.page,c),!0;case x.PAGE_DOWN:return this._repeat(null,-p.page,c),!0}return!1},_start:function(c){return!this.spinning&&this._trigger("start",c)===!1?!1:(this.counter||(this.counter=1),this.spinning=!0,!0)},_repeat:function(c,p,x){c=c||500,clearTimeout(this.timer),this.timer=this._delay(function(){this._repeat(40,p,x)},c),this._spin(p*this.options.step,x)},_spin:function(c,p){var x=this.value()||0;this.counter||(this.counter=1),x=this._adjustValue(x+c*this._increment(this.counter)),(!this.spinning||this._trigger("spin",p,{value:x})!==!1)&&(this._value(x),this.counter++)},_increment:function(c){var p=this.options.incremental;return p?typeof p=="function"?p(c):Math.floor(c*c*c/5e4-c*c/500+17*c/200+1):1},_precision:function(){var c=this._precisionOf(this.options.step);return this.options.min!==null&&(c=Math.max(c,this._precisionOf(this.options.min))),c},_precisionOf:function(c){var p=c.toString(),x=p.indexOf(".");return x===-1?0:p.length-x-1},_adjustValue:function(c){var p,x,S=this.options;return p=S.min!==null?S.min:0,x=c-p,x=Math.round(x/S.step)*S.step,c=p+x,c=parseFloat(c.toFixed(this._precision())),S.max!==null&&c>S.max?S.max:S.min!==null&&c<S.min?S.min:c},_stop:function(c){this.spinning&&(clearTimeout(this.timer),clearTimeout(this.mousewheelTimer),this.counter=0,this.spinning=!1,this._trigger("stop",c))},_setOption:function(c,p){var x,S,b;if(c==="culture"||c==="numberFormat"){x=this._parse(this.element.val()),this.options[c]=p,this.element.val(this._format(x));return}(c==="max"||c==="min"||c==="step")&&typeof p=="string"&&(p=this._parse(p)),c==="icons"&&(S=this.buttons.first().find(".ui-icon"),this._removeClass(S,null,this.options.icons.up),this._addClass(S,null,p.up),b=this.buttons.last().find(".ui-icon"),this._removeClass(b,null,this.options.icons.down),this._addClass(b,null,p.down)),this._super(c,p)},_setOptionDisabled:function(c){this._super(c),this._toggleClass(this.uiSpinner,null,"ui-state-disabled",!!c),this.element.prop("disabled",!!c),this.buttons.button(c?"disable":"enable")},_setOptions:w(function(c){this._super(c)}),_parse:function(c){return typeof c=="string"&&c!==""&&(c=window.Globalize&&this.options.numberFormat?Globalize.parseFloat(c,10,this.options.culture):+c),c===""||isNaN(c)?null:c},_format:function(c){return c===""?"":window.Globalize&&this.options.numberFormat?Globalize.format(c,this.options.numberFormat,this.options.culture):c},_refresh:function(){this.element.attr({"aria-valuemin":this.options.min,"aria-valuemax":this.options.max,"aria-valuenow":this._parse(this.element.val())})},isValid:function(){var c=this.value();return c===null?!1:c===this._adjustValue(c)},_value:function(c,p){var x;c!==""&&(x=this._parse(c),x!==null&&(p||(x=this._adjustValue(x)),c=this._format(x))),this.element.val(c),this._refresh()},_destroy:function(){this.element.prop("disabled",!1).removeAttr("autocomplete role aria-valuemin aria-valuemax aria-valuenow"),this.uiSpinner.replaceWith(this.element)},stepUp:w(function(c){this._stepUp(c)}),_stepUp:function(c){this._start()&&(this._spin((c||1)*this.options.step),this._stop())},stepDown:w(function(c){this._stepDown(c)}),_stepDown:function(c){this._start()&&(this._spin((c||1)*-this.options.step),this._stop())},pageUp:w(function(c){this._stepUp((c||1)*this.options.page)}),pageDown:w(function(c){this._stepDown((c||1)*this.options.page)}),value:function(c){if(!arguments.length)return this._parse(this.element.val());w(this._value).call(this,c)},widget:function(){return this.uiSpinner}}),t.uiBackCompat===!0&&t.widget("ui.spinner",t.ui.spinner,{_enhance:function(){this.uiSpinner=this.element.attr("autocomplete","off").wrap(this._uiSpinnerHtml()).parent().append(this._buttonHtml())},_uiSpinnerHtml:function(){return"<span>"},_buttonHtml:function(){return"<a></a><a></a>"}}),t.ui.spinner;/*!
 * jQuery UI Tabs 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.tabs",{version:"1.14.0",delay:300,options:{active:null,classes:{"ui-tabs":"ui-corner-all","ui-tabs-nav":"ui-corner-all","ui-tabs-panel":"ui-corner-bottom","ui-tabs-tab":"ui-corner-top"},collapsible:!1,event:"click",heightStyle:"content",hide:null,show:null,activate:null,beforeActivate:null,beforeLoad:null,load:null},_isLocal:function(){var c=/#.*$/;return function(p){var x,S;x=p.href.replace(c,""),S=location.href.replace(c,"");try{x=decodeURIComponent(x)}catch{}try{S=decodeURIComponent(S)}catch{}return p.hash.length>1&&x===S}}(),_create:function(){var c=this,p=this.options;this.running=!1,this._addClass("ui-tabs","ui-widget ui-widget-content"),this._toggleClass("ui-tabs-collapsible",null,p.collapsible),this._processTabs(),p.active=this._initialActive(),Array.isArray(p.disabled)&&(p.disabled=t.uniqueSort(p.disabled.concat(t.map(this.tabs.filter(".ui-state-disabled"),function(x){return c.tabs.index(x)}))).sort()),this.options.active!==!1&&this.anchors.length?this.active=this._findActive(p.active):this.active=t(),this._refresh(),this.active.length&&this.load(p.active)},_initialActive:function(){var c=this.options.active,p=this.options.collapsible,x=location.hash.substring(1);return c===null&&(x&&this.tabs.each(function(S,b){if(t(b).attr("aria-controls")===x)return c=S,!1}),c===null&&(c=this.tabs.index(this.tabs.filter(".ui-tabs-active"))),(c===null||c===-1)&&(c=this.tabs.length?0:!1)),c!==!1&&(c=this.tabs.index(this.tabs.eq(c)),c===-1&&(c=p?!1:0)),!p&&c===!1&&this.anchors.length&&(c=0),c},_getCreateEventData:function(){return{tab:this.active,panel:this.active.length?this._getPanelForTab(this.active):t()}},_tabKeydown:function(c){var p=t(this.document[0].activeElement).closest("li"),x=this.tabs.index(p),S=!0;if(!this._handlePageNav(c)){switch(c.keyCode){case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:x++;break;case t.ui.keyCode.UP:case t.ui.keyCode.LEFT:S=!1,x--;break;case t.ui.keyCode.END:x=this.anchors.length-1;break;case t.ui.keyCode.HOME:x=0;break;case t.ui.keyCode.SPACE:c.preventDefault(),clearTimeout(this.activating),this._activate(x);return;case t.ui.keyCode.ENTER:c.preventDefault(),clearTimeout(this.activating),this._activate(x===this.options.active?!1:x);return;default:return}c.preventDefault(),clearTimeout(this.activating),x=this._focusNextTab(x,S),!c.ctrlKey&&!c.metaKey&&(p.attr("aria-selected","false"),this.tabs.eq(x).attr("aria-selected","true"),this.activating=this._delay(function(){this.option("active",x)},this.delay))}},_panelKeydown:function(c){this._handlePageNav(c)||c.ctrlKey&&c.keyCode===t.ui.keyCode.UP&&(c.preventDefault(),this.active.trigger("focus"))},_handlePageNav:function(c){if(c.altKey&&c.keyCode===t.ui.keyCode.PAGE_UP)return this._activate(this._focusNextTab(this.options.active-1,!1)),!0;if(c.altKey&&c.keyCode===t.ui.keyCode.PAGE_DOWN)return this._activate(this._focusNextTab(this.options.active+1,!0)),!0},_findNextTab:function(c,p){var x=this.tabs.length-1;function S(){return c>x&&(c=0),c<0&&(c=x),c}for(;t.inArray(S(),this.options.disabled)!==-1;)c=p?c+1:c-1;return c},_focusNextTab:function(c,p){return c=this._findNextTab(c,p),this.tabs.eq(c).trigger("focus"),c},_setOption:function(c,p){if(c==="active"){this._activate(p);return}this._super(c,p),c==="collapsible"&&(this._toggleClass("ui-tabs-collapsible",null,p),!p&&this.options.active===!1&&this._activate(0)),c==="event"&&this._setupEvents(p),c==="heightStyle"&&this._setupHeightStyle(p)},_sanitizeSelector:function(c){return c?c.replace(/[!"$%&'()*+,.\/:;<=>?@\[\]\^`{|}~]/g,"\\$&"):""},refresh:function(){var c=this.options,p=this.tablist.children(":has(a[href])");c.disabled=t.map(p.filter(".ui-state-disabled"),function(x){return p.index(x)}),this._processTabs(),c.active===!1||!this.anchors.length?(c.active=!1,this.active=t()):this.active.length&&!t.contains(this.tablist[0],this.active[0])?this.tabs.length===c.disabled.length?(c.active=!1,this.active=t()):this._activate(this._findNextTab(Math.max(0,c.active-1),!1)):c.active=this.tabs.index(this.active),this._refresh()},_refresh:function(){this._setOptionDisabled(this.options.disabled),this._setupEvents(this.options.event),this._setupHeightStyle(this.options.heightStyle),this.tabs.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}),this.panels.not(this._getPanelForTab(this.active)).hide().attr({"aria-hidden":"true"}),this.active.length?(this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}),this._addClass(this.active,"ui-tabs-active","ui-state-active"),this._getPanelForTab(this.active).show().attr({"aria-hidden":"false"})):this.tabs.eq(0).attr("tabIndex",0)},_processTabs:function(){var c=this,p=this.tabs,x=this.anchors,S=this.panels;this.tablist=this._getList().attr("role","tablist"),this._addClass(this.tablist,"ui-tabs-nav","ui-helper-reset ui-helper-clearfix ui-widget-header"),this.tablist.on("mousedown"+this.eventNamespace,"> li",function(b){t(this).is(".ui-state-disabled")&&b.preventDefault()}),this.tabs=this.tablist.find("> li:has(a[href])").attr({role:"tab",tabIndex:-1}),this._addClass(this.tabs,"ui-tabs-tab","ui-state-default"),this.anchors=this.tabs.map(function(){return t("a",this)[0]}).attr({tabIndex:-1}),this._addClass(this.anchors,"ui-tabs-anchor"),this.panels=t(),this.anchors.each(function(b,h){var T,M,O,V=t(h).uniqueId().attr("id"),ee=t(h).closest("li"),Z=ee.attr("aria-controls");c._isLocal(h)?(T=h.hash,O=T.substring(1),M=c.element.find(c._sanitizeSelector(T))):(O=ee.attr("aria-controls")||t({}).uniqueId()[0].id,T="#"+O,M=c.element.find(T),M.length||(M=c._createPanel(O),M.insertAfter(c.panels[b-1]||c.tablist)),M.attr("aria-live","polite")),M.length&&(c.panels=c.panels.add(M)),Z&&ee.data("ui-tabs-aria-controls",Z),ee.attr({"aria-controls":O,"aria-labelledby":V}),M.attr("aria-labelledby",V)}),this.panels.attr("role","tabpanel"),this._addClass(this.panels,"ui-tabs-panel","ui-widget-content"),p&&(this._off(p.not(this.tabs)),this._off(x.not(this.anchors)),this._off(S.not(this.panels)))},_getList:function(){return this.tablist||this.element.find("ol, ul").eq(0)},_createPanel:function(c){return t("<div>").attr("id",c).data("ui-tabs-destroy",!0)},_setOptionDisabled:function(c){var p,x,S;for(Array.isArray(c)&&(c.length?c.length===this.anchors.length&&(c=!0):c=!1),S=0;x=this.tabs[S];S++)p=t(x),c===!0||t.inArray(S,c)!==-1?(p.attr("aria-disabled","true"),this._addClass(p,null,"ui-state-disabled")):(p.removeAttr("aria-disabled"),this._removeClass(p,null,"ui-state-disabled"));this.options.disabled=c,this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,c===!0)},_setupEvents:function(c){var p={};c&&t.each(c.split(" "),function(x,S){p[S]="_eventHandler"}),this._off(this.anchors.add(this.tabs).add(this.panels)),this._on(!0,this.anchors,{click:function(x){x.preventDefault()}}),this._on(this.anchors,p),this._on(this.tabs,{keydown:"_tabKeydown"}),this._on(this.panels,{keydown:"_panelKeydown"}),this._focusable(this.tabs),this._hoverable(this.tabs)},_setupHeightStyle:function(c){var p,x=this.element.parent();c==="fill"?(p=x.height(),p-=this.element.outerHeight()-this.element.height(),this.element.siblings(":visible").each(function(){var S=t(this),b=S.css("position");b==="absolute"||b==="fixed"||(p-=S.outerHeight(!0))}),this.element.children().not(this.panels).each(function(){p-=t(this).outerHeight(!0)}),this.panels.each(function(){t(this).height(Math.max(0,p-t(this).innerHeight()+t(this).height()))}).css("overflow","auto")):c==="auto"&&(p=0,this.panels.each(function(){p=Math.max(p,t(this).height("").height())}).height(p))},_eventHandler:function(c){var p=this.options,x=this.active,S=t(c.currentTarget),b=S.closest("li"),h=b[0]===x[0],T=h&&p.collapsible,M=T?t():this._getPanelForTab(b),O=x.length?this._getPanelForTab(x):t(),V={oldTab:x,oldPanel:O,newTab:T?t():b,newPanel:M};c.preventDefault(),!(b.hasClass("ui-state-disabled")||b.hasClass("ui-tabs-loading")||this.running||h&&!p.collapsible||this._trigger("beforeActivate",c,V)===!1)&&(p.active=T?!1:this.tabs.index(b),this.active=h?t():b,this.xhr&&this.xhr.abort(),!O.length&&!M.length&&t.error("jQuery UI Tabs: Mismatching fragment identifier."),M.length&&this.load(this.tabs.index(b),c),this._toggle(c,V))},_toggle:function(c,p){var x=this,S=p.newPanel,b=p.oldPanel;this.running=!0;function h(){x.running=!1,x._trigger("activate",c,p)}function T(){x._addClass(p.newTab.closest("li"),"ui-tabs-active","ui-state-active"),S.length&&x.options.show?x._show(S,x.options.show,h):(S.show(),h())}b.length&&this.options.hide?this._hide(b,this.options.hide,function(){x._removeClass(p.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),T()}):(this._removeClass(p.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),b.hide(),T()),b.attr("aria-hidden","true"),p.oldTab.attr({"aria-selected":"false","aria-expanded":"false"}),S.length&&b.length?p.oldTab.attr("tabIndex",-1):S.length&&this.tabs.filter(function(){return t(this).attr("tabIndex")===0}).attr("tabIndex",-1),S.attr("aria-hidden","false"),p.newTab.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_activate:function(c){var p,x=this._findActive(c);x[0]!==this.active[0]&&(x.length||(x=this.active),p=x.find(".ui-tabs-anchor")[0],this._eventHandler({target:p,currentTarget:p,preventDefault:t.noop}))},_findActive:function(c){return c===!1?t():this.tabs.eq(c)},_getIndex:function(c){return typeof c=="string"&&(c=this.anchors.index(this.anchors.filter("[href$='"+CSS.escape(c)+"']"))),c},_destroy:function(){this.xhr&&this.xhr.abort(),this.tablist.removeAttr("role").off(this.eventNamespace),this.anchors.removeAttr("role tabIndex").removeUniqueId(),this.tabs.add(this.panels).each(function(){t.data(this,"ui-tabs-destroy")?t(this).remove():t(this).removeAttr("role tabIndex aria-live aria-busy aria-selected aria-labelledby aria-hidden aria-expanded")}),this.tabs.each(function(){var c=t(this),p=c.data("ui-tabs-aria-controls");p?c.attr("aria-controls",p).removeData("ui-tabs-aria-controls"):c.removeAttr("aria-controls")}),this.panels.show(),this.options.heightStyle!=="content"&&this.panels.css("height","")},enable:function(c){var p=this.options.disabled;p!==!1&&(c===void 0?p=!1:(c=this._getIndex(c),Array.isArray(p)?p=t.map(p,function(x){return x!==c?x:null}):p=t.map(this.tabs,function(x,S){return S!==c?S:null})),this._setOptionDisabled(p))},disable:function(c){var p=this.options.disabled;if(p!==!0){if(c===void 0)p=!0;else{if(c=this._getIndex(c),t.inArray(c,p)!==-1)return;Array.isArray(p)?p=t.merge([c],p).sort():p=[c]}this._setOptionDisabled(p)}},load:function(c,p){c=this._getIndex(c);var x=this,S=this.tabs.eq(c),b=S.find(".ui-tabs-anchor"),h=this._getPanelForTab(S),T={tab:S,panel:h},M=function(O,V){V==="abort"&&x.panels.stop(!1,!0),x._removeClass(S,"ui-tabs-loading"),h.removeAttr("aria-busy"),O===x.xhr&&delete x.xhr};this._isLocal(b[0])||(this.xhr=t.ajax(this._ajaxSettings(b,p,T)),this.xhr.statusText!=="canceled"&&(this._addClass(S,"ui-tabs-loading"),h.attr("aria-busy","true"),this.xhr.done(function(O,V,ee){h.html(O),x._trigger("load",p,T),M(ee,V)}).fail(function(O,V){M(O,V)})))},_ajaxSettings:function(c,p,x){var S=this;return{url:c.attr("href"),beforeSend:function(b,h){return S._trigger("beforeLoad",p,t.extend({jqXHR:b,ajaxSettings:h},x))}}},_getPanelForTab:function(c){var p=t(c).attr("aria-controls");return this.element.find(this._sanitizeSelector("#"+p))}}),t.uiBackCompat===!0&&t.widget("ui.tabs",t.ui.tabs,{_processTabs:function(){this._superApply(arguments),this._addClass(this.tabs,"ui-tab")}}),t.ui.tabs;/*!
 * jQuery UI Tooltip 1.14.0
 * https://jqueryui.com
 *
 * Copyright OpenJS Foundation and other contributors
 * Released under the MIT license.
 * https://jquery.org/license
 */t.widget("ui.tooltip",{version:"1.14.0",options:{classes:{"ui-tooltip":"ui-corner-all ui-widget-shadow"},content:function(){var c=t(this).attr("title");return t("<a>").text(c).html()},hide:!0,items:"[title]:not([disabled])",position:{my:"left top+15",at:"left bottom",collision:"flipfit flip"},show:!0,track:!1,close:null,open:null},_addDescribedBy:function(c,p){var x=(c.attr("aria-describedby")||"").split(/\s+/);x.push(p),c.data("ui-tooltip-id",p).attr("aria-describedby",String.prototype.trim.call(x.join(" ")))},_removeDescribedBy:function(c){var p=c.data("ui-tooltip-id"),x=(c.attr("aria-describedby")||"").split(/\s+/),S=t.inArray(p,x);S!==-1&&x.splice(S,1),c.removeData("ui-tooltip-id"),x=String.prototype.trim.call(x.join(" ")),x?c.attr("aria-describedby",x):c.removeAttr("aria-describedby")},_create:function(){this._on({mouseover:"open",focusin:"open"}),this.tooltips={},this.parents={},this.liveRegion=t("<div>").attr({role:"log","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body),this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible"),this.disabledTitles=t([])},_setOption:function(c,p){var x=this;this._super(c,p),c==="content"&&t.each(this.tooltips,function(S,b){x._updateContent(b.element)})},_setOptionDisabled:function(c){this[c?"_disable":"_enable"]()},_disable:function(){var c=this;t.each(this.tooltips,function(p,x){var S=t.Event("blur");S.target=S.currentTarget=x.element[0],c.close(S,!0)}),this.disabledTitles=this.disabledTitles.add(this.element.find(this.options.items).addBack().filter(function(){var p=t(this);if(p.is("[title]"))return p.data("ui-tooltip-title",p.attr("title")).removeAttr("title")}))},_enable:function(){this.disabledTitles.each(function(){var c=t(this);c.data("ui-tooltip-title")&&c.attr("title",c.data("ui-tooltip-title"))}),this.disabledTitles=t([])},open:function(c){var p=this,x=t(c?c.target:this.element).closest(this.options.items);!x.length||x.data("ui-tooltip-id")||(x.attr("title")&&x.data("ui-tooltip-title",x.attr("title")),x.data("ui-tooltip-open",!0),c&&c.type==="mouseover"&&x.parents().each(function(){var S=t(this),b;S.data("ui-tooltip-open")&&(b=t.Event("blur"),b.target=b.currentTarget=this,p.close(b,!0)),S.attr("title")&&(S.uniqueId(),p.parents[this.id]={element:this,title:S.attr("title")},S.attr("title",""))}),this._registerCloseHandlers(c,x),this._updateContent(x,c))},_updateContent:function(c,p){var x,S=this.options.content,b=this,h=p?p.type:null;if(typeof S=="string"||S.nodeType||S.jquery)return this._open(p,c,S);x=S.call(c[0],function(T){c.data("ui-tooltip-open")&&(p&&(p.type=h),b._open(p,c,T))}),x&&this._open(p,c,x)},_open:function(c,p,x){var S,b,h,T,M=t.extend({},this.options.position);if(!x)return;if(S=this._find(p),S){S.tooltip.find(".ui-tooltip-content").html(x);return}p.is("[title]")&&(c&&c.type==="mouseover"?p.attr("title",""):p.removeAttr("title")),S=this._tooltip(p),b=S.tooltip,this._addDescribedBy(p,b.attr("id")),b.find(".ui-tooltip-content").html(x),this.liveRegion.children().hide(),T=t("<div>").html(b.find(".ui-tooltip-content").html()),T.removeAttr("name").find("[name]").removeAttr("name"),T.removeAttr("id").find("[id]").removeAttr("id"),T.appendTo(this.liveRegion);function O(V){M.of=V,!b.is(":hidden")&&b.position(M)}this.options.track&&c&&/^mouse/.test(c.type)?(this._on(this.document,{mousemove:O}),O(c)):b.position(t.extend({of:p},this.options.position)),b.hide(),this._show(b,this.options.show),this.options.track&&this.options.show&&this.options.show.delay&&(h=this.delayedShow=setInterval(function(){b.is(":visible")&&(O(M.of),clearInterval(h))},13)),this._trigger("open",c,{tooltip:b})},_registerCloseHandlers:function(c,p){var x={keyup:function(S){if(S.keyCode===t.ui.keyCode.ESCAPE){var b=t.Event(S);b.currentTarget=p[0],this.close(b,!0)}}};p[0]!==this.element[0]&&(x.remove=function(){var S=this._find(p);S&&this._removeTooltip(S.tooltip)}),(!c||c.type==="mouseover")&&(x.mouseleave="close"),(!c||c.type==="focusin")&&(x.focusout="close"),this._on(!0,p,x)},close:function(c){var p,x=this,S=t(c?c.currentTarget:this.element),b=this._find(S);if(!b){S.removeData("ui-tooltip-open");return}p=b.tooltip,!b.closing&&(clearInterval(this.delayedShow),S.data("ui-tooltip-title")&&!S.attr("title")&&S.attr("title",S.data("ui-tooltip-title")),this._removeDescribedBy(S),b.hiding=!0,p.stop(!0),this._hide(p,this.options.hide,function(){x._removeTooltip(t(this))}),S.removeData("ui-tooltip-open"),this._off(S,"mouseleave focusout keyup"),S[0]!==this.element[0]&&this._off(S,"remove"),this._off(this.document,"mousemove"),c&&c.type==="mouseleave"&&t.each(this.parents,function(h,T){t(T.element).attr("title",T.title),delete x.parents[h]}),b.closing=!0,this._trigger("close",c,{tooltip:p}),b.hiding||(b.closing=!1))},_tooltip:function(c){var p=t("<div>").attr("role","tooltip"),x=t("<div>").appendTo(p),S=p.uniqueId().attr("id");return this._addClass(x,"ui-tooltip-content"),this._addClass(p,"ui-tooltip","ui-widget ui-widget-content"),p.appendTo(this._appendTo(c)),this.tooltips[S]={element:c,tooltip:p}},_find:function(c){var p=c.data("ui-tooltip-id");return p?this.tooltips[p]:null},_removeTooltip:function(c){clearInterval(this.delayedShow),c.remove(),delete this.tooltips[c.attr("id")]},_appendTo:function(c){var p=c.closest(".ui-front, dialog");return p.length||(p=this.document[0].body),p},_destroy:function(){var c=this;t.each(this.tooltips,function(p,x){var S=t.Event("blur"),b=x.element;S.target=S.currentTarget=b[0],c.close(S,!0),t("#"+p).remove(),b.data("ui-tooltip-title")&&(b.attr("title")||b.attr("title",b.data("ui-tooltip-title")),b.removeData("ui-tooltip-title"))}),this.liveRegion.remove()}}),t.uiBackCompat===!0&&t.widget("ui.tooltip",t.ui.tooltip,{options:{tooltipClass:null},_tooltip:function(){var c=this._superApply(arguments);return this.options.tooltipClass&&c.tooltip.addClass(this.options.tooltipClass),c}}),t.ui.tooltip});var lodash={exports:{}};/**
 * @license
 * Lodash <https://lodash.com/>
 * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
 * Released under MIT license <https://lodash.com/license>
 * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
 * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
 */lodash.exports,function(t,e){(function(){var n,o="4.17.21",u=200,l="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",m="Expected a function",y="Invalid `variable` option passed into `_.template`",E="__lodash_hash_undefined__",C=500,k="__lodash_placeholder__",A=1,D=2,P=4,R=1,B=2,F=1,j=2,N=4,Y=8,J=16,ie=32,ue=64,Q=128,ce=256,he=512,ke=30,L="...",d=800,v=16,w=1,c=2,p=3,x=1/0,S=9007199254740991,b=17976931348623157e292,h=NaN,T=4294967295,M=T-1,O=T>>>1,V=[["ary",Q],["bind",F],["bindKey",j],["curry",Y],["curryRight",J],["flip",he],["partial",ie],["partialRight",ue],["rearg",ce]],ee="[object Arguments]",Z="[object Array]",U="[object AsyncFunction]",z="[object Boolean]",ne="[object Date]",fe="[object DOMException]",me="[object Error]",de="[object Function]",je="[object GeneratorFunction]",lt="[object Map]",it="[object Number]",ot="[object Null]",Ct="[object Object]",nt="[object Promise]",Je="[object Proxy]",tt="[object RegExp]",rt="[object Set]",ht="[object String]",Ot="[object Symbol]",Ve="[object Undefined]",We="[object WeakMap]",Gt="[object WeakSet]",wt="[object ArrayBuffer]",Et="[object DataView]",Yt="[object Float32Array]",Ce="[object Float64Array]",te="[object Int8Array]",ye="[object Int16Array]",Le="[object Int32Array]",Ue="[object Uint8Array]",Qe="[object Uint8ClampedArray]",Ke="[object Uint16Array]",De="[object Uint32Array]",Vt=/\b__p \+= '';/g,At=/\b(__p \+=) '' \+/g,ve=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Pt=/&(?:amp|lt|gt|quot|#39);/g,pt=/[&<>"']/g,Ne=RegExp(Pt.source),vt=RegExp(pt.source),ut=/<%-([\s\S]+?)%>/g,$t=/<%([\s\S]+?)%>/g,fi=/<%=([\s\S]+?)%>/g,kt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Wt=/^\w*$/,Zi=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ut=/[\\^$.*+?()[\]{}|]/g,Xt=RegExp(Ut.source),Be=/^\s+/,be=/\s/,ge=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,oe=/\{\n\/\* \[wrapped with (.+)\] \*/,Ae=/,? & /,qe=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,bt=/[()=,{}\[\]\/\s]/,at=/\\(\\)?/g,gt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ei=/\w*$/,ii=/^[-+]0x[0-9a-f]+$/i,Bi=/^0b[01]+$/i,hi=/^\[object .+?Constructor\]$/,Di=/^0o[0-7]+$/i,ni=/^(?:0|[1-9]\d*)$/,pi=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Ii=/($^)/,Ci=/['\n\r\u2028\u2029\\]/g,zi="\\ud800-\\udfff",qi="\\u0300-\\u036f",Ai="\\ufe20-\\ufe2f",Oi="\\u20d0-\\u20ff",ki=qi+Ai+Oi,Ti="\\u2700-\\u27bf",wi="a-z\\xdf-\\xf6\\xf8-\\xff",oi="\\xac\\xb1\\xd7\\xf7",zt="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Qt="\\u2000-\\u206f",Si=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",mi="A-Z\\xc0-\\xd6\\xd8-\\xde",ai="\\ufe0e\\ufe0f",gi=oi+zt+Qt+Si,Hi="['’]",or="["+zi+"]",nr="["+gi+"]",Gi="["+ki+"]",Mt="\\d+",er="["+Ti+"]",tr="["+wi+"]",br="[^"+zi+gi+Mt+Ti+wi+mi+"]",le="\\ud83c[\\udffb-\\udfff]",we="(?:"+Gi+"|"+le+")",$e="[^"+zi+"]",Oe="(?:\\ud83c[\\udde6-\\uddff]){2}",Ge="[\\ud800-\\udbff][\\udc00-\\udfff]",st="["+mi+"]",xe="\\u200d",Ee="(?:"+tr+"|"+br+")",Ie="(?:"+st+"|"+br+")",Xe="(?:"+Hi+"(?:d|ll|m|re|s|t|ve))?",xt="(?:"+Hi+"(?:D|LL|M|RE|S|T|VE))?",Lt=we+"?",Ft="["+ai+"]?",jt="(?:"+xe+"(?:"+[$e,Oe,Ge].join("|")+")"+Ft+Lt+")*",si="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",yi="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",vi=Ft+Lt+jt,li="(?:"+[er,Oe,Ge].join("|")+")"+vi,Vi="(?:"+[$e+Gi+"?",Gi,Oe,Ge,or].join("|")+")",Ei=RegExp(Hi,"g"),$i=RegExp(Gi,"g"),xi=RegExp(le+"(?="+le+")|"+Vi+vi,"g"),ir=RegExp([st+"?"+tr+"+"+Xe+"(?="+[nr,st,"$"].join("|")+")",Ie+"+"+xt+"(?="+[nr,st+Ee,"$"].join("|")+")",st+"?"+Ee+"+"+Xe,st+"+"+xt,yi,si,Mt,li].join("|"),"g"),Ji=RegExp("["+xe+zi+ki+ai+"]"),ur=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,zn=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Un=-1,_r={};_r[Yt]=_r[Ce]=_r[te]=_r[ye]=_r[Le]=_r[Ue]=_r[Qe]=_r[Ke]=_r[De]=!0,_r[ee]=_r[Z]=_r[wt]=_r[z]=_r[Et]=_r[ne]=_r[me]=_r[de]=_r[lt]=_r[it]=_r[Ct]=_r[tt]=_r[rt]=_r[ht]=_r[We]=!1;var xr={};xr[ee]=xr[Z]=xr[wt]=xr[Et]=xr[z]=xr[ne]=xr[Yt]=xr[Ce]=xr[te]=xr[ye]=xr[Le]=xr[lt]=xr[it]=xr[Ct]=xr[tt]=xr[rt]=xr[ht]=xr[Ot]=xr[Ue]=xr[Qe]=xr[Ke]=xr[De]=!0,xr[me]=xr[de]=xr[We]=!1;var En={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",Ĳ:"IJ",ĳ:"ij",Œ:"Oe",œ:"oe",ŉ:"'n",ſ:"s"},kn={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},ia={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},pn={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},yn=parseFloat,ca=parseInt,_a=typeof commonjsGlobal$1=="object"&&commonjsGlobal$1&&commonjsGlobal$1.Object===Object&&commonjsGlobal$1,fa=typeof self=="object"&&self&&self.Object===Object&&self,$r=_a||fa||Function("return this")(),Hn=e&&!e.nodeType&&e,Zr=Hn&&!0&&t&&!t.nodeType&&t,xa=Zr&&Zr.exports===Hn,mn=xa&&_a.process,tn=function(){try{var mt=Zr&&Zr.require&&Zr.require("util").types;return mt||mn&&mn.binding&&mn.binding("util")}catch{}}(),X=tn&&tn.isArrayBuffer,ae=tn&&tn.isDate,Te=tn&&tn.isMap,Pe=tn&&tn.isRegExp,ze=tn&&tn.isSet,He=tn&&tn.isTypedArray;function Ze(mt,Nt,Bt){switch(Bt.length){case 0:return mt.call(Nt);case 1:return mt.call(Nt,Bt[0]);case 2:return mt.call(Nt,Bt[0],Bt[1]);case 3:return mt.call(Nt,Bt[0],Bt[1],Bt[2])}return mt.apply(Nt,Bt)}function It(mt,Nt,Bt,_i){for(var Mi=-1,Yi=mt==null?0:mt.length;++Mi<Yi;){var Xi=mt[Mi];Nt(_i,Xi,Bt(Xi),mt)}return _i}function St(mt,Nt){for(var Bt=-1,_i=mt==null?0:mt.length;++Bt<_i&&Nt(mt[Bt],Bt,mt)!==!1;);return mt}function Kt(mt,Nt){for(var Bt=mt==null?0:mt.length;Bt--&&Nt(mt[Bt],Bt,mt)!==!1;);return mt}function di(mt,Nt){for(var Bt=-1,_i=mt==null?0:mt.length;++Bt<_i;)if(!Nt(mt[Bt],Bt,mt))return!1;return!0}function bi(mt,Nt){for(var Bt=-1,_i=mt==null?0:mt.length,Mi=0,Yi=[];++Bt<_i;){var Xi=mt[Bt];Nt(Xi,Bt,mt)&&(Yi[Mi++]=Xi)}return Yi}function ri(mt,Nt){var Bt=mt==null?0:mt.length;return!!Bt&&Lr(mt,Nt,0)>-1}function Ni(mt,Nt,Bt){for(var _i=-1,Mi=mt==null?0:mt.length;++_i<Mi;)if(Bt(Nt,mt[_i]))return!0;return!1}function Ki(mt,Nt){for(var Bt=-1,_i=mt==null?0:mt.length,Mi=Array(_i);++Bt<_i;)Mi[Bt]=Nt(mt[Bt],Bt,mt);return Mi}function yr(mt,Nt){for(var Bt=-1,_i=Nt.length,Mi=mt.length;++Bt<_i;)mt[Mi+Bt]=Nt[Bt];return mt}function fr(mt,Nt,Bt,_i){var Mi=-1,Yi=mt==null?0:mt.length;for(_i&&Yi&&(Bt=mt[++Mi]);++Mi<Yi;)Bt=Nt(Bt,mt[Mi],Mi,mt);return Bt}function jr(mt,Nt,Bt,_i){var Mi=mt==null?0:mt.length;for(_i&&Mi&&(Bt=mt[--Mi]);Mi--;)Bt=Nt(Bt,mt[Mi],Mi,mt);return Bt}function Or(mt,Nt){for(var Bt=-1,_i=mt==null?0:mt.length;++Bt<_i;)if(Nt(mt[Bt],Bt,mt))return!0;return!1}var Qr=ra("length");function Cn(mt){return mt.split("")}function Tr(mt){return mt.match(qe)||[]}function $n(mt,Nt,Bt){var _i;return Bt(mt,function(Mi,Yi,Xi){if(Nt(Mi,Yi,Xi))return _i=Yi,!1}),_i}function Sr(mt,Nt,Bt,_i){for(var Mi=mt.length,Yi=Bt+(_i?1:-1);_i?Yi--:++Yi<Mi;)if(Nt(mt[Yi],Yi,mt))return Yi;return-1}function Lr(mt,Nt,Bt){return Nt===Nt?vs(mt,Nt,Bt):Sr(mt,La,Bt)}function wa(mt,Nt,Bt,_i){for(var Mi=Bt-1,Yi=mt.length;++Mi<Yi;)if(_i(mt[Mi],Nt))return Mi;return-1}function La(mt){return mt!==mt}function rn(mt,Nt){var Bt=mt==null?0:mt.length;return Bt?Jr(mt,Nt)/Bt:h}function ra(mt){return function(Nt){return Nt==null?n:Nt[mt]}}function un(mt){return function(Nt){return mt==null?n:mt[Nt]}}function Ln(mt,Nt,Bt,_i,Mi){return Mi(mt,function(Yi,Xi,Ui){Bt=_i?(_i=!1,Yi):Nt(Bt,Yi,Xi,Ui)}),Bt}function Vn(mt,Nt){var Bt=mt.length;for(mt.sort(Nt);Bt--;)mt[Bt]=mt[Bt].value;return mt}function Jr(mt,Nt){for(var Bt,_i=-1,Mi=mt.length;++_i<Mi;){var Yi=Nt(mt[_i]);Yi!==n&&(Bt=Bt===n?Yi:Bt+Yi)}return Bt}function ha(mt,Nt){for(var Bt=-1,_i=Array(mt);++Bt<mt;)_i[Bt]=Nt(Bt);return _i}function Bn(mt,Nt){return Ki(Nt,function(Bt){return[Bt,mt[Bt]]})}function An(mt){return mt&&mt.slice(0,as(mt)+1).replace(Be,"")}function ln(mt){return function(Nt){return mt(Nt)}}function Ba(mt,Nt){return Ki(Nt,function(Bt){return mt[Bt]})}function Sa(mt,Nt){return mt.has(Nt)}function Ir(mt,Nt){for(var Bt=-1,_i=mt.length;++Bt<_i&&Lr(Nt,mt[Bt],0)>-1;);return Bt}function da(mt,Nt){for(var Bt=mt.length;Bt--&&Lr(Nt,mt[Bt],0)>-1;);return Bt}function _n(mt,Nt){for(var Bt=mt.length,_i=0;Bt--;)mt[Bt]===Nt&&++_i;return _i}var na=un(En),gs=un(kn);function ns(mt){return"\\"+pn[mt]}function pa(mt,Nt){return mt==null?n:mt[Nt]}function cn(mt){return Ji.test(mt)}function Ga(mt){return ur.test(mt)}function Wn(mt){for(var Nt,Bt=[];!(Nt=mt.next()).done;)Bt.push(Nt.value);return Bt}function Gn(mt){var Nt=-1,Bt=Array(mt.size);return mt.forEach(function(_i,Mi){Bt[++Nt]=[Mi,_i]}),Bt}function ma(mt,Nt){return function(Bt){return mt(Nt(Bt))}}function xn(mt,Nt){for(var Bt=-1,_i=mt.length,Mi=0,Yi=[];++Bt<_i;){var Xi=mt[Bt];(Xi===Nt||Xi===k)&&(mt[Bt]=k,Yi[Mi++]=Bt)}return Yi}function aa(mt){var Nt=-1,Bt=Array(mt.size);return mt.forEach(function(_i){Bt[++Nt]=_i}),Bt}function Oa(mt){var Nt=-1,Bt=Array(mt.size);return mt.forEach(function(_i){Bt[++Nt]=[_i,_i]}),Bt}function vs(mt,Nt,Bt){for(var _i=Bt-1,Mi=mt.length;++_i<Mi;)if(mt[_i]===Nt)return _i;return-1}function ja(mt,Nt,Bt){for(var _i=Bt+1;_i--;)if(mt[_i]===Nt)return _i;return _i}function Kn(mt){return cn(mt)?ss(mt):Qr(mt)}function fn(mt){return cn(mt)?_t(mt):Cn(mt)}function as(mt){for(var Nt=mt.length;Nt--&&be.test(mt.charAt(Nt)););return Nt}var Ka=un(ia);function ss(mt){for(var Nt=xi.lastIndex=0;xi.test(mt);)++Nt;return Nt}function _t(mt){return mt.match(xi)||[]}function Ht(mt){return mt.match(ir)||[]}var ti=function mt(Nt){Nt=Nt==null?$r:ui.defaults($r.Object(),Nt,ui.pick($r,zn));var Bt=Nt.Array,_i=Nt.Date,Mi=Nt.Error,Yi=Nt.Function,Xi=Nt.Math,Ui=Nt.Object,gr=Nt.RegExp,ar=Nt.String,Er=Nt.TypeError,Hr=Bt.prototype,Yr=Yi.prototype,Vr=Ui.prototype,nn=Nt["__core-js_shared__"],Mn=Yr.toString,vr=Vr.hasOwnProperty,Ps=0,ys=function(){var I=/[^.]+$/.exec(nn&&nn.keys&&nn.keys.IE_PROTO||"");return I?"Symbol(src)_1."+I:""}(),Fa=Vr.toString,Ds=Mn.call(Ui),bs=$r._,co=gr("^"+Mn.call(vr).replace(Ut,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Na=xa?Nt.Buffer:n,Qn=Nt.Symbol,Qa=Nt.Uint8Array,Ya=Na?Na.allocUnsafe:n,Ta=ma(Ui.getPrototypeOf,Ui),Is=Ui.create,Rs=Vr.propertyIsEnumerable,os=Hr.splice,$s=Qn?Qn.isConcatSpreadable:n,Xa=Qn?Qn.iterator:n,sa=Qn?Qn.toStringTag:n,us=function(){try{var I=ts(Ui,"defineProperty");return I({},"",{}),I}catch{}}(),fo=Nt.clearTimeout!==$r.clearTimeout&&Nt.clearTimeout,Ls=_i&&_i.now!==$r.Date.now&&_i.now,qa=Nt.setTimeout!==$r.setTimeout&&Nt.setTimeout,Rr=Xi.ceil,Yn=Xi.floor,en=Ui.getOwnPropertySymbols,Xn=Na?Na.isBuffer:n,Bs=Nt.isFinite,Os=Hr.join,ho=ma(Ui.keys,Ui),Wr=Xi.max,an=Xi.min,po=_i.now,mo=Nt.parseInt,js=Xi.random,go=Hr.reverse,ls=ts(Nt,"DataView"),re=ts(Nt,"Map"),pe=ts(Nt,"Promise"),Se=ts(Nt,"Set"),_e=ts(Nt,"WeakMap"),Me=ts(Ui,"create"),Fe=_e&&new _e,dt={},yt=is(ls),Tt=is(re),Rt=is(pe),Zt=is(Se),ci=is(_e),Wi=Qn?Qn.prototype:n,Pi=Wi?Wi.valueOf:n,lr=Wi?Wi.toString:n;function et(I){if(Ur(I)&&!wr(I)&&!(I instanceof Ar)){if(I instanceof Xr)return I;if(vr.call(I,"__wrapped__"))return ul(I)}return new Xr(I)}var Fr=function(){function I(){}return function(H){if(!qr(H))return{};if(Is)return Is(H);I.prototype=H;var se=new I;return I.prototype=n,se}}();function hn(){}function Xr(I,H){this.__wrapped__=I,this.__actions__=[],this.__chain__=!!H,this.__index__=0,this.__values__=n}et.templateSettings={escape:ut,evaluate:$t,interpolate:fi,variable:"",imports:{_:et}},et.prototype=hn.prototype,et.prototype.constructor=et,Xr.prototype=Fr(hn.prototype),Xr.prototype.constructor=Xr;function Ar(I){this.__wrapped__=I,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=T,this.__views__=[]}function Fs(){var I=new Ar(this.__wrapped__);return I.__actions__=Pn(this.__actions__),I.__dir__=this.__dir__,I.__filtered__=this.__filtered__,I.__iteratees__=Pn(this.__iteratees__),I.__takeCount__=this.__takeCount__,I.__views__=Pn(this.__views__),I}function Ns(){if(this.__filtered__){var I=new Ar(this);I.__dir__=-1,I.__filtered__=!0}else I=this.clone(),I.__dir__*=-1;return I}function _s(){var I=this.__wrapped__.value(),H=this.__dir__,se=wr(I),Re=H<0,Ye=se?I.length:0,ct=ef(0,Ye,this.__views__),Dt=ct.start,qt=ct.end,Jt=qt-Dt,Ri=Re?qt:Dt-1,Li=this.__iteratees__,ji=Li.length,Qi=0,rr=an(Jt,this.__takeCount__);if(!se||!Re&&Ye==Jt&&rr==Jt)return Pu(I,this.__actions__);var dr=[];e:for(;Jt--&&Qi<rr;){Ri+=H;for(var Cr=-1,pr=I[Ri];++Cr<ji;){var Pr=Li[Cr],Dr=Pr.iteratee,Nn=Pr.type,Tn=Dr(pr);if(Nn==c)pr=Tn;else if(!Tn){if(Nn==w)continue e;break e}}dr[Qi++]=pr}return dr}Ar.prototype=Fr(hn.prototype),Ar.prototype.constructor=Ar;function ga(I){var H=-1,se=I==null?0:I.length;for(this.clear();++H<se;){var Re=I[H];this.set(Re[0],Re[1])}}function Nr(){this.__data__=Me?Me(null):{},this.size=0}function qs(I){var H=this.has(I)&&delete this.__data__[I];return this.size-=H?1:0,H}function Ea(I){var H=this.__data__;if(Me){var se=H[I];return se===E?n:se}return vr.call(H,I)?H[I]:n}function Vl(I){var H=this.__data__;return Me?H[I]!==n:vr.call(H,I)}function Wl(I,H){var se=this.__data__;return this.size+=this.has(I)?0:1,se[I]=Me&&H===n?E:H,this}ga.prototype.clear=Nr,ga.prototype.delete=qs,ga.prototype.get=Ea,ga.prototype.has=Vl,ga.prototype.set=Wl;function ka(I){var H=-1,se=I==null?0:I.length;for(this.clear();++H<se;){var Re=I[H];this.set(Re[0],Re[1])}}function Gl(){this.__data__=[],this.size=0}function Kl(I){var H=this.__data__,se=zs(H,I);if(se<0)return!1;var Re=H.length-1;return se==Re?H.pop():os.call(H,se,1),--this.size,!0}function Ql(I){var H=this.__data__,se=zs(H,I);return se<0?n:H[se][1]}function Yl(I){return zs(this.__data__,I)>-1}function Xl(I,H){var se=this.__data__,Re=zs(se,I);return Re<0?(++this.size,se.push([I,H])):se[Re][1]=H,this}ka.prototype.clear=Gl,ka.prototype.delete=Kl,ka.prototype.get=Ql,ka.prototype.has=Yl,ka.prototype.set=Xl;function Ca(I){var H=-1,se=I==null?0:I.length;for(this.clear();++H<se;){var Re=I[H];this.set(Re[0],Re[1])}}function Zl(){this.size=0,this.__data__={hash:new ga,map:new(re||ka),string:new ga}}function Jl(I){var H=eo(this,I).delete(I);return this.size-=H?1:0,H}function tc(I){return eo(this,I).get(I)}function ic(I){return eo(this,I).has(I)}function rc(I,H){var se=eo(this,I),Re=se.size;return se.set(I,H),this.size+=se.size==Re?0:1,this}Ca.prototype.clear=Zl,Ca.prototype.delete=Jl,Ca.prototype.get=tc,Ca.prototype.has=ic,Ca.prototype.set=rc;function Za(I){var H=-1,se=I==null?0:I.length;for(this.__data__=new Ca;++H<se;)this.add(I[H])}function nc(I){return this.__data__.set(I,E),this}function ac(I){return this.__data__.has(I)}Za.prototype.add=Za.prototype.push=nc,Za.prototype.has=ac;function oa(I){var H=this.__data__=new ka(I);this.size=H.size}function sc(){this.__data__=new ka,this.size=0}function oc(I){var H=this.__data__,se=H.delete(I);return this.size=H.size,se}function uc(I){return this.__data__.get(I)}function lc(I){return this.__data__.has(I)}function cc(I,H){var se=this.__data__;if(se instanceof ka){var Re=se.__data__;if(!re||Re.length<u-1)return Re.push([I,H]),this.size=++se.size,this;se=this.__data__=new Ca(Re)}return se.set(I,H),this.size=se.size,this}oa.prototype.clear=sc,oa.prototype.delete=oc,oa.prototype.get=uc,oa.prototype.has=lc,oa.prototype.set=cc;function ou(I,H){var se=wr(I),Re=!se&&rs(I),Ye=!se&&!Re&&Wa(I),ct=!se&&!Re&&!Ye&&ds(I),Dt=se||Re||Ye||ct,qt=Dt?ha(I.length,ar):[],Jt=qt.length;for(var Ri in I)(H||vr.call(I,Ri))&&!(Dt&&(Ri=="length"||Ye&&(Ri=="offset"||Ri=="parent")||ct&&(Ri=="buffer"||Ri=="byteLength"||Ri=="byteOffset")||Da(Ri,Jt)))&&qt.push(Ri);return qt}function uu(I){var H=I.length;return H?I[Co(0,H-1)]:n}function fc(I,H){return to(Pn(I),Ja(H,0,I.length))}function hc(I){return to(Pn(I))}function vo(I,H,se){(se!==n&&!ua(I[H],se)||se===n&&!(H in I))&&Aa(I,H,se)}function xs(I,H,se){var Re=I[H];(!(vr.call(I,H)&&ua(Re,se))||se===n&&!(H in I))&&Aa(I,H,se)}function zs(I,H){for(var se=I.length;se--;)if(ua(I[se][0],H))return se;return-1}function dc(I,H,se,Re){return za(I,function(Ye,ct,Dt){H(Re,Ye,se(Ye),Dt)}),Re}function lu(I,H){return I&&ya(H,sn(H),I)}function pc(I,H){return I&&ya(H,In(H),I)}function Aa(I,H,se){H=="__proto__"&&us?us(I,H,{configurable:!0,enumerable:!0,value:se,writable:!0}):I[H]=se}function yo(I,H){for(var se=-1,Re=H.length,Ye=Bt(Re),ct=I==null;++se<Re;)Ye[se]=ct?n:Zo(I,H[se]);return Ye}function Ja(I,H,se){return I===I&&(se!==n&&(I=I<=se?I:se),H!==n&&(I=I>=H?I:H)),I}function Zn(I,H,se,Re,Ye,ct){var Dt,qt=H&A,Jt=H&D,Ri=H&P;if(se&&(Dt=Ye?se(I,Re,Ye,ct):se(I)),Dt!==n)return Dt;if(!qr(I))return I;var Li=wr(I);if(Li){if(Dt=rf(I),!qt)return Pn(I,Dt)}else{var ji=gn(I),Qi=ji==de||ji==je;if(Wa(I))return Ru(I,qt);if(ji==Ct||ji==ee||Qi&&!Ye){if(Dt=Jt||Qi?{}:Zu(I),!qt)return Jt?Vc(I,pc(Dt,I)):Hc(I,lu(Dt,I))}else{if(!xr[ji])return Ye?I:{};Dt=nf(I,ji,qt)}}ct||(ct=new oa);var rr=ct.get(I);if(rr)return rr;ct.set(I,Dt),Ml(I)?I.forEach(function(pr){Dt.add(Zn(pr,H,se,pr,I,ct))}):Cl(I)&&I.forEach(function(pr,Pr){Dt.set(Pr,Zn(pr,H,se,Pr,I,ct))});var dr=Ri?Jt?jo:Oo:Jt?In:sn,Cr=Li?n:dr(I);return St(Cr||I,function(pr,Pr){Cr&&(Pr=pr,pr=I[Pr]),xs(Dt,Pr,Zn(pr,H,se,Pr,I,ct))}),Dt}function mc(I){var H=sn(I);return function(se){return cu(se,I,H)}}function cu(I,H,se){var Re=se.length;if(I==null)return!Re;for(I=Ui(I);Re--;){var Ye=se[Re],ct=H[Ye],Dt=I[Ye];if(Dt===n&&!(Ye in I)||!ct(Dt))return!1}return!0}function fu(I,H,se){if(typeof I!="function")throw new Er(m);return As(function(){I.apply(n,se)},H)}function ws(I,H,se,Re){var Ye=-1,ct=ri,Dt=!0,qt=I.length,Jt=[],Ri=H.length;if(!qt)return Jt;se&&(H=Ki(H,ln(se))),Re?(ct=Ni,Dt=!1):H.length>=u&&(ct=Sa,Dt=!1,H=new Za(H));e:for(;++Ye<qt;){var Li=I[Ye],ji=se==null?Li:se(Li);if(Li=Re||Li!==0?Li:0,Dt&&ji===ji){for(var Qi=Ri;Qi--;)if(H[Qi]===ji)continue e;Jt.push(Li)}else ct(H,ji,Re)||Jt.push(Li)}return Jt}var za=ju(va),hu=ju(_o,!0);function gc(I,H){var se=!0;return za(I,function(Re,Ye,ct){return se=!!H(Re,Ye,ct),se}),se}function Us(I,H,se){for(var Re=-1,Ye=I.length;++Re<Ye;){var ct=I[Re],Dt=H(ct);if(Dt!=null&&(qt===n?Dt===Dt&&!jn(Dt):se(Dt,qt)))var qt=Dt,Jt=ct}return Jt}function vc(I,H,se,Re){var Ye=I.length;for(se=kr(se),se<0&&(se=-se>Ye?0:Ye+se),Re=Re===n||Re>Ye?Ye:kr(Re),Re<0&&(Re+=Ye),Re=se>Re?0:Dl(Re);se<Re;)I[se++]=H;return I}function du(I,H){var se=[];return za(I,function(Re,Ye,ct){H(Re,Ye,ct)&&se.push(Re)}),se}function dn(I,H,se,Re,Ye){var ct=-1,Dt=I.length;for(se||(se=sf),Ye||(Ye=[]);++ct<Dt;){var qt=I[ct];H>0&&se(qt)?H>1?dn(qt,H-1,se,Re,Ye):yr(Ye,qt):Re||(Ye[Ye.length]=qt)}return Ye}var bo=Fu(),pu=Fu(!0);function va(I,H){return I&&bo(I,H,sn)}function _o(I,H){return I&&pu(I,H,sn)}function Hs(I,H){return bi(H,function(se){return Ia(I[se])})}function es(I,H){H=Ha(H,I);for(var se=0,Re=H.length;I!=null&&se<Re;)I=I[ba(H[se++])];return se&&se==Re?I:n}function mu(I,H,se){var Re=H(I);return wr(I)?Re:yr(Re,se(I))}function wn(I){return I==null?I===n?Ve:ot:sa&&sa in Ui(I)?Jc(I):df(I)}function xo(I,H){return I>H}function yc(I,H){return I!=null&&vr.call(I,H)}function bc(I,H){return I!=null&&H in Ui(I)}function _c(I,H,se){return I>=an(H,se)&&I<Wr(H,se)}function wo(I,H,se){for(var Re=se?Ni:ri,Ye=I[0].length,ct=I.length,Dt=ct,qt=Bt(ct),Jt=1/0,Ri=[];Dt--;){var Li=I[Dt];Dt&&H&&(Li=Ki(Li,ln(H))),Jt=an(Li.length,Jt),qt[Dt]=!se&&(H||Ye>=120&&Li.length>=120)?new Za(Dt&&Li):n}Li=I[0];var ji=-1,Qi=qt[0];e:for(;++ji<Ye&&Ri.length<Jt;){var rr=Li[ji],dr=H?H(rr):rr;if(rr=se||rr!==0?rr:0,!(Qi?Sa(Qi,dr):Re(Ri,dr,se))){for(Dt=ct;--Dt;){var Cr=qt[Dt];if(!(Cr?Sa(Cr,dr):Re(I[Dt],dr,se)))continue e}Qi&&Qi.push(dr),Ri.push(rr)}}return Ri}function xc(I,H,se,Re){return va(I,function(Ye,ct,Dt){H(Re,se(Ye),ct,Dt)}),Re}function Ss(I,H,se){H=Ha(H,I),I=il(I,H);var Re=I==null?I:I[ba(ea(H))];return Re==null?n:Ze(Re,I,se)}function gu(I){return Ur(I)&&wn(I)==ee}function wc(I){return Ur(I)&&wn(I)==wt}function Sc(I){return Ur(I)&&wn(I)==ne}function Ts(I,H,se,Re,Ye){return I===H?!0:I==null||H==null||!Ur(I)&&!Ur(H)?I!==I&&H!==H:Tc(I,H,se,Re,Ts,Ye)}function Tc(I,H,se,Re,Ye,ct){var Dt=wr(I),qt=wr(H),Jt=Dt?Z:gn(I),Ri=qt?Z:gn(H);Jt=Jt==ee?Ct:Jt,Ri=Ri==ee?Ct:Ri;var Li=Jt==Ct,ji=Ri==Ct,Qi=Jt==Ri;if(Qi&&Wa(I)){if(!Wa(H))return!1;Dt=!0,Li=!1}if(Qi&&!Li)return ct||(ct=new oa),Dt||ds(I)?Qu(I,H,se,Re,Ye,ct):Xc(I,H,Jt,se,Re,Ye,ct);if(!(se&R)){var rr=Li&&vr.call(I,"__wrapped__"),dr=ji&&vr.call(H,"__wrapped__");if(rr||dr){var Cr=rr?I.value():I,pr=dr?H.value():H;return ct||(ct=new oa),Ye(Cr,pr,se,Re,ct)}}return Qi?(ct||(ct=new oa),Zc(I,H,se,Re,Ye,ct)):!1}function Ec(I){return Ur(I)&&gn(I)==lt}function So(I,H,se,Re){var Ye=se.length,ct=Ye,Dt=!Re;if(I==null)return!ct;for(I=Ui(I);Ye--;){var qt=se[Ye];if(Dt&&qt[2]?qt[1]!==I[qt[0]]:!(qt[0]in I))return!1}for(;++Ye<ct;){qt=se[Ye];var Jt=qt[0],Ri=I[Jt],Li=qt[1];if(Dt&&qt[2]){if(Ri===n&&!(Jt in I))return!1}else{var ji=new oa;if(Re)var Qi=Re(Ri,Li,Jt,I,H,ji);if(!(Qi===n?Ts(Li,Ri,R|B,Re,ji):Qi))return!1}}return!0}function vu(I){if(!qr(I)||uf(I))return!1;var H=Ia(I)?co:hi;return H.test(is(I))}function kc(I){return Ur(I)&&wn(I)==tt}function Cc(I){return Ur(I)&&gn(I)==rt}function Ac(I){return Ur(I)&&oo(I.length)&&!!_r[wn(I)]}function yu(I){return typeof I=="function"?I:I==null?Rn:typeof I=="object"?wr(I)?xu(I[0],I[1]):_u(I):Ul(I)}function To(I){if(!Cs(I))return ho(I);var H=[];for(var se in Ui(I))vr.call(I,se)&&se!="constructor"&&H.push(se);return H}function Mc(I){if(!qr(I))return hf(I);var H=Cs(I),se=[];for(var Re in I)Re=="constructor"&&(H||!vr.call(I,Re))||se.push(Re);return se}function Eo(I,H){return I<H}function bu(I,H){var se=-1,Re=Dn(I)?Bt(I.length):[];return za(I,function(Ye,ct,Dt){Re[++se]=H(Ye,ct,Dt)}),Re}function _u(I){var H=No(I);return H.length==1&&H[0][2]?el(H[0][0],H[0][1]):function(se){return se===I||So(se,I,H)}}function xu(I,H){return zo(I)&&Ju(H)?el(ba(I),H):function(se){var Re=Zo(se,I);return Re===n&&Re===H?Jo(se,I):Ts(H,Re,R|B)}}function Vs(I,H,se,Re,Ye){I!==H&&bo(H,function(ct,Dt){if(Ye||(Ye=new oa),qr(ct))Pc(I,H,Dt,se,Vs,Re,Ye);else{var qt=Re?Re(Ho(I,Dt),ct,Dt+"",I,H,Ye):n;qt===n&&(qt=ct),vo(I,Dt,qt)}},In)}function Pc(I,H,se,Re,Ye,ct,Dt){var qt=Ho(I,se),Jt=Ho(H,se),Ri=Dt.get(Jt);if(Ri){vo(I,se,Ri);return}var Li=ct?ct(qt,Jt,se+"",I,H,Dt):n,ji=Li===n;if(ji){var Qi=wr(Jt),rr=!Qi&&Wa(Jt),dr=!Qi&&!rr&&ds(Jt);Li=Jt,Qi||rr||dr?wr(qt)?Li=qt:Gr(qt)?Li=Pn(qt):rr?(ji=!1,Li=Ru(Jt,!0)):dr?(ji=!1,Li=$u(Jt,!0)):Li=[]:Ms(Jt)||rs(Jt)?(Li=qt,rs(qt)?Li=Il(qt):(!qr(qt)||Ia(qt))&&(Li=Zu(Jt))):ji=!1}ji&&(Dt.set(Jt,Li),Ye(Li,Jt,Re,ct,Dt),Dt.delete(Jt)),vo(I,se,Li)}function wu(I,H){var se=I.length;if(se)return H+=H<0?se:0,Da(H,se)?I[H]:n}function Su(I,H,se){H.length?H=Ki(H,function(ct){return wr(ct)?function(Dt){return es(Dt,ct.length===1?ct[0]:ct)}:ct}):H=[Rn];var Re=-1;H=Ki(H,ln(cr()));var Ye=bu(I,function(ct,Dt,qt){var Jt=Ki(H,function(Ri){return Ri(ct)});return{criteria:Jt,index:++Re,value:ct}});return Vn(Ye,function(ct,Dt){return Uc(ct,Dt,se)})}function Dc(I,H){return Tu(I,H,function(se,Re){return Jo(I,Re)})}function Tu(I,H,se){for(var Re=-1,Ye=H.length,ct={};++Re<Ye;){var Dt=H[Re],qt=es(I,Dt);se(qt,Dt)&&Es(ct,Ha(Dt,I),qt)}return ct}function Ic(I){return function(H){return es(H,I)}}function ko(I,H,se,Re){var Ye=Re?wa:Lr,ct=-1,Dt=H.length,qt=I;for(I===H&&(H=Pn(H)),se&&(qt=Ki(I,ln(se)));++ct<Dt;)for(var Jt=0,Ri=H[ct],Li=se?se(Ri):Ri;(Jt=Ye(qt,Li,Jt,Re))>-1;)qt!==I&&os.call(qt,Jt,1),os.call(I,Jt,1);return I}function Eu(I,H){for(var se=I?H.length:0,Re=se-1;se--;){var Ye=H[se];if(se==Re||Ye!==ct){var ct=Ye;Da(Ye)?os.call(I,Ye,1):Po(I,Ye)}}return I}function Co(I,H){return I+Yn(js()*(H-I+1))}function Rc(I,H,se,Re){for(var Ye=-1,ct=Wr(Rr((H-I)/(se||1)),0),Dt=Bt(ct);ct--;)Dt[Re?ct:++Ye]=I,I+=se;return Dt}function Ao(I,H){var se="";if(!I||H<1||H>S)return se;do H%2&&(se+=I),H=Yn(H/2),H&&(I+=I);while(H);return se}function Mr(I,H){return Vo(tl(I,H,Rn),I+"")}function $c(I){return uu(ps(I))}function Lc(I,H){var se=ps(I);return to(se,Ja(H,0,se.length))}function Es(I,H,se,Re){if(!qr(I))return I;H=Ha(H,I);for(var Ye=-1,ct=H.length,Dt=ct-1,qt=I;qt!=null&&++Ye<ct;){var Jt=ba(H[Ye]),Ri=se;if(Jt==="__proto__"||Jt==="constructor"||Jt==="prototype")return I;if(Ye!=Dt){var Li=qt[Jt];Ri=Re?Re(Li,Jt,qt):n,Ri===n&&(Ri=qr(Li)?Li:Da(H[Ye+1])?[]:{})}xs(qt,Jt,Ri),qt=qt[Jt]}return I}var ku=Fe?function(I,H){return Fe.set(I,H),I}:Rn,Bc=us?function(I,H){return us(I,"toString",{configurable:!0,enumerable:!1,value:tu(H),writable:!0})}:Rn;function Oc(I){return to(ps(I))}function Jn(I,H,se){var Re=-1,Ye=I.length;H<0&&(H=-H>Ye?0:Ye+H),se=se>Ye?Ye:se,se<0&&(se+=Ye),Ye=H>se?0:se-H>>>0,H>>>=0;for(var ct=Bt(Ye);++Re<Ye;)ct[Re]=I[Re+H];return ct}function jc(I,H){var se;return za(I,function(Re,Ye,ct){return se=H(Re,Ye,ct),!se}),!!se}function Ws(I,H,se){var Re=0,Ye=I==null?Re:I.length;if(typeof H=="number"&&H===H&&Ye<=O){for(;Re<Ye;){var ct=Re+Ye>>>1,Dt=I[ct];Dt!==null&&!jn(Dt)&&(se?Dt<=H:Dt<H)?Re=ct+1:Ye=ct}return Ye}return Mo(I,H,Rn,se)}function Mo(I,H,se,Re){var Ye=0,ct=I==null?0:I.length;if(ct===0)return 0;H=se(H);for(var Dt=H!==H,qt=H===null,Jt=jn(H),Ri=H===n;Ye<ct;){var Li=Yn((Ye+ct)/2),ji=se(I[Li]),Qi=ji!==n,rr=ji===null,dr=ji===ji,Cr=jn(ji);if(Dt)var pr=Re||dr;else Ri?pr=dr&&(Re||Qi):qt?pr=dr&&Qi&&(Re||!rr):Jt?pr=dr&&Qi&&!rr&&(Re||!Cr):rr||Cr?pr=!1:pr=Re?ji<=H:ji<H;pr?Ye=Li+1:ct=Li}return an(ct,M)}function Cu(I,H){for(var se=-1,Re=I.length,Ye=0,ct=[];++se<Re;){var Dt=I[se],qt=H?H(Dt):Dt;if(!se||!ua(qt,Jt)){var Jt=qt;ct[Ye++]=Dt===0?0:Dt}}return ct}function Au(I){return typeof I=="number"?I:jn(I)?h:+I}function On(I){if(typeof I=="string")return I;if(wr(I))return Ki(I,On)+"";if(jn(I))return lr?lr.call(I):"";var H=I+"";return H=="0"&&1/I==-x?"-0":H}function Ua(I,H,se){var Re=-1,Ye=ri,ct=I.length,Dt=!0,qt=[],Jt=qt;if(se)Dt=!1,Ye=Ni;else if(ct>=u){var Ri=H?null:Qc(I);if(Ri)return aa(Ri);Dt=!1,Ye=Sa,Jt=new Za}else Jt=H?[]:qt;e:for(;++Re<ct;){var Li=I[Re],ji=H?H(Li):Li;if(Li=se||Li!==0?Li:0,Dt&&ji===ji){for(var Qi=Jt.length;Qi--;)if(Jt[Qi]===ji)continue e;H&&Jt.push(ji),qt.push(Li)}else Ye(Jt,ji,se)||(Jt!==qt&&Jt.push(ji),qt.push(Li))}return qt}function Po(I,H){return H=Ha(H,I),I=il(I,H),I==null||delete I[ba(ea(H))]}function Mu(I,H,se,Re){return Es(I,H,se(es(I,H)),Re)}function Gs(I,H,se,Re){for(var Ye=I.length,ct=Re?Ye:-1;(Re?ct--:++ct<Ye)&&H(I[ct],ct,I););return se?Jn(I,Re?0:ct,Re?ct+1:Ye):Jn(I,Re?ct+1:0,Re?Ye:ct)}function Pu(I,H){var se=I;return se instanceof Ar&&(se=se.value()),fr(H,function(Re,Ye){return Ye.func.apply(Ye.thisArg,yr([Re],Ye.args))},se)}function Do(I,H,se){var Re=I.length;if(Re<2)return Re?Ua(I[0]):[];for(var Ye=-1,ct=Bt(Re);++Ye<Re;)for(var Dt=I[Ye],qt=-1;++qt<Re;)qt!=Ye&&(ct[Ye]=ws(ct[Ye]||Dt,I[qt],H,se));return Ua(dn(ct,1),H,se)}function Du(I,H,se){for(var Re=-1,Ye=I.length,ct=H.length,Dt={};++Re<Ye;){var qt=Re<ct?H[Re]:n;se(Dt,I[Re],qt)}return Dt}function Io(I){return Gr(I)?I:[]}function Ro(I){return typeof I=="function"?I:Rn}function Ha(I,H){return wr(I)?I:zo(I,H)?[I]:ol(Br(I))}var Fc=Mr;function Va(I,H,se){var Re=I.length;return se=se===n?Re:se,!H&&se>=Re?I:Jn(I,H,se)}var Iu=fo||function(I){return $r.clearTimeout(I)};function Ru(I,H){if(H)return I.slice();var se=I.length,Re=Ya?Ya(se):new I.constructor(se);return I.copy(Re),Re}function $o(I){var H=new I.constructor(I.byteLength);return new Qa(H).set(new Qa(I)),H}function Nc(I,H){var se=H?$o(I.buffer):I.buffer;return new I.constructor(se,I.byteOffset,I.byteLength)}function qc(I){var H=new I.constructor(I.source,ei.exec(I));return H.lastIndex=I.lastIndex,H}function zc(I){return Pi?Ui(Pi.call(I)):{}}function $u(I,H){var se=H?$o(I.buffer):I.buffer;return new I.constructor(se,I.byteOffset,I.length)}function Lu(I,H){if(I!==H){var se=I!==n,Re=I===null,Ye=I===I,ct=jn(I),Dt=H!==n,qt=H===null,Jt=H===H,Ri=jn(H);if(!qt&&!Ri&&!ct&&I>H||ct&&Dt&&Jt&&!qt&&!Ri||Re&&Dt&&Jt||!se&&Jt||!Ye)return 1;if(!Re&&!ct&&!Ri&&I<H||Ri&&se&&Ye&&!Re&&!ct||qt&&se&&Ye||!Dt&&Ye||!Jt)return-1}return 0}function Uc(I,H,se){for(var Re=-1,Ye=I.criteria,ct=H.criteria,Dt=Ye.length,qt=se.length;++Re<Dt;){var Jt=Lu(Ye[Re],ct[Re]);if(Jt){if(Re>=qt)return Jt;var Ri=se[Re];return Jt*(Ri=="desc"?-1:1)}}return I.index-H.index}function Bu(I,H,se,Re){for(var Ye=-1,ct=I.length,Dt=se.length,qt=-1,Jt=H.length,Ri=Wr(ct-Dt,0),Li=Bt(Jt+Ri),ji=!Re;++qt<Jt;)Li[qt]=H[qt];for(;++Ye<Dt;)(ji||Ye<ct)&&(Li[se[Ye]]=I[Ye]);for(;Ri--;)Li[qt++]=I[Ye++];return Li}function Ou(I,H,se,Re){for(var Ye=-1,ct=I.length,Dt=-1,qt=se.length,Jt=-1,Ri=H.length,Li=Wr(ct-qt,0),ji=Bt(Li+Ri),Qi=!Re;++Ye<Li;)ji[Ye]=I[Ye];for(var rr=Ye;++Jt<Ri;)ji[rr+Jt]=H[Jt];for(;++Dt<qt;)(Qi||Ye<ct)&&(ji[rr+se[Dt]]=I[Ye++]);return ji}function Pn(I,H){var se=-1,Re=I.length;for(H||(H=Bt(Re));++se<Re;)H[se]=I[se];return H}function ya(I,H,se,Re){var Ye=!se;se||(se={});for(var ct=-1,Dt=H.length;++ct<Dt;){var qt=H[ct],Jt=Re?Re(se[qt],I[qt],qt,se,I):n;Jt===n&&(Jt=I[qt]),Ye?Aa(se,qt,Jt):xs(se,qt,Jt)}return se}function Hc(I,H){return ya(I,qo(I),H)}function Vc(I,H){return ya(I,Yu(I),H)}function Ks(I,H){return function(se,Re){var Ye=wr(se)?It:dc,ct=H?H():{};return Ye(se,I,cr(Re,2),ct)}}function cs(I){return Mr(function(H,se){var Re=-1,Ye=se.length,ct=Ye>1?se[Ye-1]:n,Dt=Ye>2?se[2]:n;for(ct=I.length>3&&typeof ct=="function"?(Ye--,ct):n,Dt&&Sn(se[0],se[1],Dt)&&(ct=Ye<3?n:ct,Ye=1),H=Ui(H);++Re<Ye;){var qt=se[Re];qt&&I(H,qt,Re,ct)}return H})}function ju(I,H){return function(se,Re){if(se==null)return se;if(!Dn(se))return I(se,Re);for(var Ye=se.length,ct=H?Ye:-1,Dt=Ui(se);(H?ct--:++ct<Ye)&&Re(Dt[ct],ct,Dt)!==!1;);return se}}function Fu(I){return function(H,se,Re){for(var Ye=-1,ct=Ui(H),Dt=Re(H),qt=Dt.length;qt--;){var Jt=Dt[I?qt:++Ye];if(se(ct[Jt],Jt,ct)===!1)break}return H}}function Wc(I,H,se){var Re=H&F,Ye=ks(I);function ct(){var Dt=this&&this!==$r&&this instanceof ct?Ye:I;return Dt.apply(Re?se:this,arguments)}return ct}function Nu(I){return function(H){H=Br(H);var se=cn(H)?fn(H):n,Re=se?se[0]:H.charAt(0),Ye=se?Va(se,1).join(""):H.slice(1);return Re[I]()+Ye}}function fs(I){return function(H){return fr(Nl(Fl(H).replace(Ei,"")),I,"")}}function ks(I){return function(){var H=arguments;switch(H.length){case 0:return new I;case 1:return new I(H[0]);case 2:return new I(H[0],H[1]);case 3:return new I(H[0],H[1],H[2]);case 4:return new I(H[0],H[1],H[2],H[3]);case 5:return new I(H[0],H[1],H[2],H[3],H[4]);case 6:return new I(H[0],H[1],H[2],H[3],H[4],H[5]);case 7:return new I(H[0],H[1],H[2],H[3],H[4],H[5],H[6])}var se=Fr(I.prototype),Re=I.apply(se,H);return qr(Re)?Re:se}}function Gc(I,H,se){var Re=ks(I);function Ye(){for(var ct=arguments.length,Dt=Bt(ct),qt=ct,Jt=hs(Ye);qt--;)Dt[qt]=arguments[qt];var Ri=ct<3&&Dt[0]!==Jt&&Dt[ct-1]!==Jt?[]:xn(Dt,Jt);if(ct-=Ri.length,ct<se)return Vu(I,H,Qs,Ye.placeholder,n,Dt,Ri,n,n,se-ct);var Li=this&&this!==$r&&this instanceof Ye?Re:I;return Ze(Li,this,Dt)}return Ye}function qu(I){return function(H,se,Re){var Ye=Ui(H);if(!Dn(H)){var ct=cr(se,3);H=sn(H),se=function(qt){return ct(Ye[qt],qt,Ye)}}var Dt=I(H,se,Re);return Dt>-1?Ye[ct?H[Dt]:Dt]:n}}function zu(I){return Pa(function(H){var se=H.length,Re=se,Ye=Xr.prototype.thru;for(I&&H.reverse();Re--;){var ct=H[Re];if(typeof ct!="function")throw new Er(m);if(Ye&&!Dt&&Js(ct)=="wrapper")var Dt=new Xr([],!0)}for(Re=Dt?Re:se;++Re<se;){ct=H[Re];var qt=Js(ct),Jt=qt=="wrapper"?Fo(ct):n;Jt&&Uo(Jt[0])&&Jt[1]==(Q|Y|ie|ce)&&!Jt[4].length&&Jt[9]==1?Dt=Dt[Js(Jt[0])].apply(Dt,Jt[3]):Dt=ct.length==1&&Uo(ct)?Dt[qt]():Dt.thru(ct)}return function(){var Ri=arguments,Li=Ri[0];if(Dt&&Ri.length==1&&wr(Li))return Dt.plant(Li).value();for(var ji=0,Qi=se?H[ji].apply(this,Ri):Li;++ji<se;)Qi=H[ji].call(this,Qi);return Qi}})}function Qs(I,H,se,Re,Ye,ct,Dt,qt,Jt,Ri){var Li=H&Q,ji=H&F,Qi=H&j,rr=H&(Y|J),dr=H&he,Cr=Qi?n:ks(I);function pr(){for(var Pr=arguments.length,Dr=Bt(Pr),Nn=Pr;Nn--;)Dr[Nn]=arguments[Nn];if(rr)var Tn=hs(pr),qn=_n(Dr,Tn);if(Re&&(Dr=Bu(Dr,Re,Ye,rr)),ct&&(Dr=Ou(Dr,ct,Dt,rr)),Pr-=qn,rr&&Pr<Ri){var Kr=xn(Dr,Tn);return Vu(I,H,Qs,pr.placeholder,se,Dr,Kr,qt,Jt,Ri-Pr)}var la=ji?se:this,$a=Qi?la[I]:I;return Pr=Dr.length,qt?Dr=pf(Dr,qt):dr&&Pr>1&&Dr.reverse(),Li&&Jt<Pr&&(Dr.length=Jt),this&&this!==$r&&this instanceof pr&&($a=Cr||ks($a)),$a.apply(la,Dr)}return pr}function Uu(I,H){return function(se,Re){return xc(se,I,H(Re),{})}}function Ys(I,H){return function(se,Re){var Ye;if(se===n&&Re===n)return H;if(se!==n&&(Ye=se),Re!==n){if(Ye===n)return Re;typeof se=="string"||typeof Re=="string"?(se=On(se),Re=On(Re)):(se=Au(se),Re=Au(Re)),Ye=I(se,Re)}return Ye}}function Lo(I){return Pa(function(H){return H=Ki(H,ln(cr())),Mr(function(se){var Re=this;return I(H,function(Ye){return Ze(Ye,Re,se)})})})}function Xs(I,H){H=H===n?" ":On(H);var se=H.length;if(se<2)return se?Ao(H,I):H;var Re=Ao(H,Rr(I/Kn(H)));return cn(H)?Va(fn(Re),0,I).join(""):Re.slice(0,I)}function Kc(I,H,se,Re){var Ye=H&F,ct=ks(I);function Dt(){for(var qt=-1,Jt=arguments.length,Ri=-1,Li=Re.length,ji=Bt(Li+Jt),Qi=this&&this!==$r&&this instanceof Dt?ct:I;++Ri<Li;)ji[Ri]=Re[Ri];for(;Jt--;)ji[Ri++]=arguments[++qt];return Ze(Qi,Ye?se:this,ji)}return Dt}function Hu(I){return function(H,se,Re){return Re&&typeof Re!="number"&&Sn(H,se,Re)&&(se=Re=n),H=Ra(H),se===n?(se=H,H=0):se=Ra(se),Re=Re===n?H<se?1:-1:Ra(Re),Rc(H,se,Re,I)}}function Zs(I){return function(H,se){return typeof H=="string"&&typeof se=="string"||(H=ta(H),se=ta(se)),I(H,se)}}function Vu(I,H,se,Re,Ye,ct,Dt,qt,Jt,Ri){var Li=H&Y,ji=Li?Dt:n,Qi=Li?n:Dt,rr=Li?ct:n,dr=Li?n:ct;H|=Li?ie:ue,H&=~(Li?ue:ie),H&N||(H&=~(F|j));var Cr=[I,H,Ye,rr,ji,dr,Qi,qt,Jt,Ri],pr=se.apply(n,Cr);return Uo(I)&&rl(pr,Cr),pr.placeholder=Re,nl(pr,I,H)}function Bo(I){var H=Xi[I];return function(se,Re){if(se=ta(se),Re=Re==null?0:an(kr(Re),292),Re&&Bs(se)){var Ye=(Br(se)+"e").split("e"),ct=H(Ye[0]+"e"+(+Ye[1]+Re));return Ye=(Br(ct)+"e").split("e"),+(Ye[0]+"e"+(+Ye[1]-Re))}return H(se)}}var Qc=Se&&1/aa(new Se([,-0]))[1]==x?function(I){return new Se(I)}:nu;function Wu(I){return function(H){var se=gn(H);return se==lt?Gn(H):se==rt?Oa(H):Bn(H,I(H))}}function Ma(I,H,se,Re,Ye,ct,Dt,qt){var Jt=H&j;if(!Jt&&typeof I!="function")throw new Er(m);var Ri=Re?Re.length:0;if(Ri||(H&=~(ie|ue),Re=Ye=n),Dt=Dt===n?Dt:Wr(kr(Dt),0),qt=qt===n?qt:kr(qt),Ri-=Ye?Ye.length:0,H&ue){var Li=Re,ji=Ye;Re=Ye=n}var Qi=Jt?n:Fo(I),rr=[I,H,se,Re,Ye,Li,ji,ct,Dt,qt];if(Qi&&ff(rr,Qi),I=rr[0],H=rr[1],se=rr[2],Re=rr[3],Ye=rr[4],qt=rr[9]=rr[9]===n?Jt?0:I.length:Wr(rr[9]-Ri,0),!qt&&H&(Y|J)&&(H&=~(Y|J)),!H||H==F)var dr=Wc(I,H,se);else H==Y||H==J?dr=Gc(I,H,qt):(H==ie||H==(F|ie))&&!Ye.length?dr=Kc(I,H,se,Re):dr=Qs.apply(n,rr);var Cr=Qi?ku:rl;return nl(Cr(dr,rr),I,H)}function Gu(I,H,se,Re){return I===n||ua(I,Vr[se])&&!vr.call(Re,se)?H:I}function Ku(I,H,se,Re,Ye,ct){return qr(I)&&qr(H)&&(ct.set(H,I),Vs(I,H,n,Ku,ct),ct.delete(H)),I}function Yc(I){return Ms(I)?n:I}function Qu(I,H,se,Re,Ye,ct){var Dt=se&R,qt=I.length,Jt=H.length;if(qt!=Jt&&!(Dt&&Jt>qt))return!1;var Ri=ct.get(I),Li=ct.get(H);if(Ri&&Li)return Ri==H&&Li==I;var ji=-1,Qi=!0,rr=se&B?new Za:n;for(ct.set(I,H),ct.set(H,I);++ji<qt;){var dr=I[ji],Cr=H[ji];if(Re)var pr=Dt?Re(Cr,dr,ji,H,I,ct):Re(dr,Cr,ji,I,H,ct);if(pr!==n){if(pr)continue;Qi=!1;break}if(rr){if(!Or(H,function(Pr,Dr){if(!Sa(rr,Dr)&&(dr===Pr||Ye(dr,Pr,se,Re,ct)))return rr.push(Dr)})){Qi=!1;break}}else if(!(dr===Cr||Ye(dr,Cr,se,Re,ct))){Qi=!1;break}}return ct.delete(I),ct.delete(H),Qi}function Xc(I,H,se,Re,Ye,ct,Dt){switch(se){case Et:if(I.byteLength!=H.byteLength||I.byteOffset!=H.byteOffset)return!1;I=I.buffer,H=H.buffer;case wt:return!(I.byteLength!=H.byteLength||!ct(new Qa(I),new Qa(H)));case z:case ne:case it:return ua(+I,+H);case me:return I.name==H.name&&I.message==H.message;case tt:case ht:return I==H+"";case lt:var qt=Gn;case rt:var Jt=Re&R;if(qt||(qt=aa),I.size!=H.size&&!Jt)return!1;var Ri=Dt.get(I);if(Ri)return Ri==H;Re|=B,Dt.set(I,H);var Li=Qu(qt(I),qt(H),Re,Ye,ct,Dt);return Dt.delete(I),Li;case Ot:if(Pi)return Pi.call(I)==Pi.call(H)}return!1}function Zc(I,H,se,Re,Ye,ct){var Dt=se&R,qt=Oo(I),Jt=qt.length,Ri=Oo(H),Li=Ri.length;if(Jt!=Li&&!Dt)return!1;for(var ji=Jt;ji--;){var Qi=qt[ji];if(!(Dt?Qi in H:vr.call(H,Qi)))return!1}var rr=ct.get(I),dr=ct.get(H);if(rr&&dr)return rr==H&&dr==I;var Cr=!0;ct.set(I,H),ct.set(H,I);for(var pr=Dt;++ji<Jt;){Qi=qt[ji];var Pr=I[Qi],Dr=H[Qi];if(Re)var Nn=Dt?Re(Dr,Pr,Qi,H,I,ct):Re(Pr,Dr,Qi,I,H,ct);if(!(Nn===n?Pr===Dr||Ye(Pr,Dr,se,Re,ct):Nn)){Cr=!1;break}pr||(pr=Qi=="constructor")}if(Cr&&!pr){var Tn=I.constructor,qn=H.constructor;Tn!=qn&&"constructor"in I&&"constructor"in H&&!(typeof Tn=="function"&&Tn instanceof Tn&&typeof qn=="function"&&qn instanceof qn)&&(Cr=!1)}return ct.delete(I),ct.delete(H),Cr}function Pa(I){return Vo(tl(I,n,fl),I+"")}function Oo(I){return mu(I,sn,qo)}function jo(I){return mu(I,In,Yu)}var Fo=Fe?function(I){return Fe.get(I)}:nu;function Js(I){for(var H=I.name+"",se=dt[H],Re=vr.call(dt,H)?se.length:0;Re--;){var Ye=se[Re],ct=Ye.func;if(ct==null||ct==I)return Ye.name}return H}function hs(I){var H=vr.call(et,"placeholder")?et:I;return H.placeholder}function cr(){var I=et.iteratee||iu;return I=I===iu?yu:I,arguments.length?I(arguments[0],arguments[1]):I}function eo(I,H){var se=I.__data__;return of(H)?se[typeof H=="string"?"string":"hash"]:se.map}function No(I){for(var H=sn(I),se=H.length;se--;){var Re=H[se],Ye=I[Re];H[se]=[Re,Ye,Ju(Ye)]}return H}function ts(I,H){var se=pa(I,H);return vu(se)?se:n}function Jc(I){var H=vr.call(I,sa),se=I[sa];try{I[sa]=n;var Re=!0}catch{}var Ye=Fa.call(I);return Re&&(H?I[sa]=se:delete I[sa]),Ye}var qo=en?function(I){return I==null?[]:(I=Ui(I),bi(en(I),function(H){return Rs.call(I,H)}))}:au,Yu=en?function(I){for(var H=[];I;)yr(H,qo(I)),I=Ta(I);return H}:au,gn=wn;(ls&&gn(new ls(new ArrayBuffer(1)))!=Et||re&&gn(new re)!=lt||pe&&gn(pe.resolve())!=nt||Se&&gn(new Se)!=rt||_e&&gn(new _e)!=We)&&(gn=function(I){var H=wn(I),se=H==Ct?I.constructor:n,Re=se?is(se):"";if(Re)switch(Re){case yt:return Et;case Tt:return lt;case Rt:return nt;case Zt:return rt;case ci:return We}return H});function ef(I,H,se){for(var Re=-1,Ye=se.length;++Re<Ye;){var ct=se[Re],Dt=ct.size;switch(ct.type){case"drop":I+=Dt;break;case"dropRight":H-=Dt;break;case"take":H=an(H,I+Dt);break;case"takeRight":I=Wr(I,H-Dt);break}}return{start:I,end:H}}function tf(I){var H=I.match(oe);return H?H[1].split(Ae):[]}function Xu(I,H,se){H=Ha(H,I);for(var Re=-1,Ye=H.length,ct=!1;++Re<Ye;){var Dt=ba(H[Re]);if(!(ct=I!=null&&se(I,Dt)))break;I=I[Dt]}return ct||++Re!=Ye?ct:(Ye=I==null?0:I.length,!!Ye&&oo(Ye)&&Da(Dt,Ye)&&(wr(I)||rs(I)))}function rf(I){var H=I.length,se=new I.constructor(H);return H&&typeof I[0]=="string"&&vr.call(I,"index")&&(se.index=I.index,se.input=I.input),se}function Zu(I){return typeof I.constructor=="function"&&!Cs(I)?Fr(Ta(I)):{}}function nf(I,H,se){var Re=I.constructor;switch(H){case wt:return $o(I);case z:case ne:return new Re(+I);case Et:return Nc(I,se);case Yt:case Ce:case te:case ye:case Le:case Ue:case Qe:case Ke:case De:return $u(I,se);case lt:return new Re;case it:case ht:return new Re(I);case tt:return qc(I);case rt:return new Re;case Ot:return zc(I)}}function af(I,H){var se=H.length;if(!se)return I;var Re=se-1;return H[Re]=(se>1?"& ":"")+H[Re],H=H.join(se>2?", ":" "),I.replace(ge,`{
/* [wrapped with `+H+`] */
`)}function sf(I){return wr(I)||rs(I)||!!($s&&I&&I[$s])}function Da(I,H){var se=typeof I;return H=H??S,!!H&&(se=="number"||se!="symbol"&&ni.test(I))&&I>-1&&I%1==0&&I<H}function Sn(I,H,se){if(!qr(se))return!1;var Re=typeof H;return(Re=="number"?Dn(se)&&Da(H,se.length):Re=="string"&&H in se)?ua(se[H],I):!1}function zo(I,H){if(wr(I))return!1;var se=typeof I;return se=="number"||se=="symbol"||se=="boolean"||I==null||jn(I)?!0:Wt.test(I)||!kt.test(I)||H!=null&&I in Ui(H)}function of(I){var H=typeof I;return H=="string"||H=="number"||H=="symbol"||H=="boolean"?I!=="__proto__":I===null}function Uo(I){var H=Js(I),se=et[H];if(typeof se!="function"||!(H in Ar.prototype))return!1;if(I===se)return!0;var Re=Fo(se);return!!Re&&I===Re[0]}function uf(I){return!!ys&&ys in I}var lf=nn?Ia:su;function Cs(I){var H=I&&I.constructor,se=typeof H=="function"&&H.prototype||Vr;return I===se}function Ju(I){return I===I&&!qr(I)}function el(I,H){return function(se){return se==null?!1:se[I]===H&&(H!==n||I in Ui(se))}}function cf(I){var H=ao(I,function(Re){return se.size===C&&se.clear(),Re}),se=H.cache;return H}function ff(I,H){var se=I[1],Re=H[1],Ye=se|Re,ct=Ye<(F|j|Q),Dt=Re==Q&&se==Y||Re==Q&&se==ce&&I[7].length<=H[8]||Re==(Q|ce)&&H[7].length<=H[8]&&se==Y;if(!(ct||Dt))return I;Re&F&&(I[2]=H[2],Ye|=se&F?0:N);var qt=H[3];if(qt){var Jt=I[3];I[3]=Jt?Bu(Jt,qt,H[4]):qt,I[4]=Jt?xn(I[3],k):H[4]}return qt=H[5],qt&&(Jt=I[5],I[5]=Jt?Ou(Jt,qt,H[6]):qt,I[6]=Jt?xn(I[5],k):H[6]),qt=H[7],qt&&(I[7]=qt),Re&Q&&(I[8]=I[8]==null?H[8]:an(I[8],H[8])),I[9]==null&&(I[9]=H[9]),I[0]=H[0],I[1]=Ye,I}function hf(I){var H=[];if(I!=null)for(var se in Ui(I))H.push(se);return H}function df(I){return Fa.call(I)}function tl(I,H,se){return H=Wr(H===n?I.length-1:H,0),function(){for(var Re=arguments,Ye=-1,ct=Wr(Re.length-H,0),Dt=Bt(ct);++Ye<ct;)Dt[Ye]=Re[H+Ye];Ye=-1;for(var qt=Bt(H+1);++Ye<H;)qt[Ye]=Re[Ye];return qt[H]=se(Dt),Ze(I,this,qt)}}function il(I,H){return H.length<2?I:es(I,Jn(H,0,-1))}function pf(I,H){for(var se=I.length,Re=an(H.length,se),Ye=Pn(I);Re--;){var ct=H[Re];I[Re]=Da(ct,se)?Ye[ct]:n}return I}function Ho(I,H){if(!(H==="constructor"&&typeof I[H]=="function")&&H!="__proto__")return I[H]}var rl=al(ku),As=qa||function(I,H){return $r.setTimeout(I,H)},Vo=al(Bc);function nl(I,H,se){var Re=H+"";return Vo(I,af(Re,mf(tf(Re),se)))}function al(I){var H=0,se=0;return function(){var Re=po(),Ye=v-(Re-se);if(se=Re,Ye>0){if(++H>=d)return arguments[0]}else H=0;return I.apply(n,arguments)}}function to(I,H){var se=-1,Re=I.length,Ye=Re-1;for(H=H===n?Re:H;++se<H;){var ct=Co(se,Ye),Dt=I[ct];I[ct]=I[se],I[se]=Dt}return I.length=H,I}var ol=cf(function(I){var H=[];return I.charCodeAt(0)===46&&H.push(""),I.replace(Zi,function(se,Re,Ye,ct){H.push(Ye?ct.replace(at,"$1"):Re||se)}),H});function ba(I){if(typeof I=="string"||jn(I))return I;var H=I+"";return H=="0"&&1/I==-x?"-0":H}function is(I){if(I!=null){try{return Mn.call(I)}catch{}try{return I+""}catch{}}return""}function mf(I,H){return St(V,function(se){var Re="_."+se[0];H&se[1]&&!ri(I,Re)&&I.push(Re)}),I.sort()}function ul(I){if(I instanceof Ar)return I.clone();var H=new Xr(I.__wrapped__,I.__chain__);return H.__actions__=Pn(I.__actions__),H.__index__=I.__index__,H.__values__=I.__values__,H}function gf(I,H,se){(se?Sn(I,H,se):H===n)?H=1:H=Wr(kr(H),0);var Re=I==null?0:I.length;if(!Re||H<1)return[];for(var Ye=0,ct=0,Dt=Bt(Rr(Re/H));Ye<Re;)Dt[ct++]=Jn(I,Ye,Ye+=H);return Dt}function vf(I){for(var H=-1,se=I==null?0:I.length,Re=0,Ye=[];++H<se;){var ct=I[H];ct&&(Ye[Re++]=ct)}return Ye}function yf(){var I=arguments.length;if(!I)return[];for(var H=Bt(I-1),se=arguments[0],Re=I;Re--;)H[Re-1]=arguments[Re];return yr(wr(se)?Pn(se):[se],dn(H,1))}var bf=Mr(function(I,H){return Gr(I)?ws(I,dn(H,1,Gr,!0)):[]}),_f=Mr(function(I,H){var se=ea(H);return Gr(se)&&(se=n),Gr(I)?ws(I,dn(H,1,Gr,!0),cr(se,2)):[]}),xf=Mr(function(I,H){var se=ea(H);return Gr(se)&&(se=n),Gr(I)?ws(I,dn(H,1,Gr,!0),n,se):[]});function wf(I,H,se){var Re=I==null?0:I.length;return Re?(H=se||H===n?1:kr(H),Jn(I,H<0?0:H,Re)):[]}function Sf(I,H,se){var Re=I==null?0:I.length;return Re?(H=se||H===n?1:kr(H),H=Re-H,Jn(I,0,H<0?0:H)):[]}function Tf(I,H){return I&&I.length?Gs(I,cr(H,3),!0,!0):[]}function Ef(I,H){return I&&I.length?Gs(I,cr(H,3),!0):[]}function kf(I,H,se,Re){var Ye=I==null?0:I.length;return Ye?(se&&typeof se!="number"&&Sn(I,H,se)&&(se=0,Re=Ye),vc(I,H,se,Re)):[]}function ll(I,H,se){var Re=I==null?0:I.length;if(!Re)return-1;var Ye=se==null?0:kr(se);return Ye<0&&(Ye=Wr(Re+Ye,0)),Sr(I,cr(H,3),Ye)}function cl(I,H,se){var Re=I==null?0:I.length;if(!Re)return-1;var Ye=Re-1;return se!==n&&(Ye=kr(se),Ye=se<0?Wr(Re+Ye,0):an(Ye,Re-1)),Sr(I,cr(H,3),Ye,!0)}function fl(I){var H=I==null?0:I.length;return H?dn(I,1):[]}function Cf(I){var H=I==null?0:I.length;return H?dn(I,x):[]}function Af(I,H){var se=I==null?0:I.length;return se?(H=H===n?1:kr(H),dn(I,H)):[]}function Mf(I){for(var H=-1,se=I==null?0:I.length,Re={};++H<se;){var Ye=I[H];Re[Ye[0]]=Ye[1]}return Re}function dl(I){return I&&I.length?I[0]:n}function Pf(I,H,se){var Re=I==null?0:I.length;if(!Re)return-1;var Ye=se==null?0:kr(se);return Ye<0&&(Ye=Wr(Re+Ye,0)),Lr(I,H,Ye)}function Df(I){var H=I==null?0:I.length;return H?Jn(I,0,-1):[]}var If=Mr(function(I){var H=Ki(I,Io);return H.length&&H[0]===I[0]?wo(H):[]}),Rf=Mr(function(I){var H=ea(I),se=Ki(I,Io);return H===ea(se)?H=n:se.pop(),se.length&&se[0]===I[0]?wo(se,cr(H,2)):[]}),$f=Mr(function(I){var H=ea(I),se=Ki(I,Io);return H=typeof H=="function"?H:n,H&&se.pop(),se.length&&se[0]===I[0]?wo(se,n,H):[]});function Lf(I,H){return I==null?"":Os.call(I,H)}function ea(I){var H=I==null?0:I.length;return H?I[H-1]:n}function Bf(I,H,se){var Re=I==null?0:I.length;if(!Re)return-1;var Ye=Re;return se!==n&&(Ye=kr(se),Ye=Ye<0?Wr(Re+Ye,0):an(Ye,Re-1)),H===H?ja(I,H,Ye):Sr(I,La,Ye,!0)}function Of(I,H){return I&&I.length?wu(I,kr(H)):n}var jf=Mr(pl);function pl(I,H){return I&&I.length&&H&&H.length?ko(I,H):I}function Ff(I,H,se){return I&&I.length&&H&&H.length?ko(I,H,cr(se,2)):I}function Nf(I,H,se){return I&&I.length&&H&&H.length?ko(I,H,n,se):I}var qf=Pa(function(I,H){var se=I==null?0:I.length,Re=yo(I,H);return Eu(I,Ki(H,function(Ye){return Da(Ye,se)?+Ye:Ye}).sort(Lu)),Re});function zf(I,H){var se=[];if(!(I&&I.length))return se;var Re=-1,Ye=[],ct=I.length;for(H=cr(H,3);++Re<ct;){var Dt=I[Re];H(Dt,Re,I)&&(se.push(Dt),Ye.push(Re))}return Eu(I,Ye),se}function Wo(I){return I==null?I:go.call(I)}function Uf(I,H,se){var Re=I==null?0:I.length;return Re?(se&&typeof se!="number"&&Sn(I,H,se)?(H=0,se=Re):(H=H==null?0:kr(H),se=se===n?Re:kr(se)),Jn(I,H,se)):[]}function Hf(I,H){return Ws(I,H)}function Vf(I,H,se){return Mo(I,H,cr(se,2))}function Wf(I,H){var se=I==null?0:I.length;if(se){var Re=Ws(I,H);if(Re<se&&ua(I[Re],H))return Re}return-1}function Gf(I,H){return Ws(I,H,!0)}function Kf(I,H,se){return Mo(I,H,cr(se,2),!0)}function Qf(I,H){var se=I==null?0:I.length;if(se){var Re=Ws(I,H,!0)-1;if(ua(I[Re],H))return Re}return-1}function Yf(I){return I&&I.length?Cu(I):[]}function Xf(I,H){return I&&I.length?Cu(I,cr(H,2)):[]}function Zf(I){var H=I==null?0:I.length;return H?Jn(I,1,H):[]}function Jf(I,H,se){return I&&I.length?(H=se||H===n?1:kr(H),Jn(I,0,H<0?0:H)):[]}function eh(I,H,se){var Re=I==null?0:I.length;return Re?(H=se||H===n?1:kr(H),H=Re-H,Jn(I,H<0?0:H,Re)):[]}function th(I,H){return I&&I.length?Gs(I,cr(H,3),!1,!0):[]}function ih(I,H){return I&&I.length?Gs(I,cr(H,3)):[]}var nh=Mr(function(I){return Ua(dn(I,1,Gr,!0))}),ah=Mr(function(I){var H=ea(I);return Gr(H)&&(H=n),Ua(dn(I,1,Gr,!0),cr(H,2))}),oh=Mr(function(I){var H=ea(I);return H=typeof H=="function"?H:n,Ua(dn(I,1,Gr,!0),n,H)});function uh(I){return I&&I.length?Ua(I):[]}function lh(I,H){return I&&I.length?Ua(I,cr(H,2)):[]}function fh(I,H){return H=typeof H=="function"?H:n,I&&I.length?Ua(I,n,H):[]}function Go(I){if(!(I&&I.length))return[];var H=0;return I=bi(I,function(se){if(Gr(se))return H=Wr(se.length,H),!0}),ha(H,function(se){return Ki(I,ra(se))})}function ml(I,H){if(!(I&&I.length))return[];var se=Go(I);return H==null?se:Ki(se,function(Re){return Ze(H,n,Re)})}var hh=Mr(function(I,H){return Gr(I)?ws(I,H):[]}),ph=Mr(function(I){return Do(bi(I,Gr))}),mh=Mr(function(I){var H=ea(I);return Gr(H)&&(H=n),Do(bi(I,Gr),cr(H,2))}),gh=Mr(function(I){var H=ea(I);return H=typeof H=="function"?H:n,Do(bi(I,Gr),n,H)}),vh=Mr(Go);function yh(I,H){return Du(I||[],H||[],xs)}function bh(I,H){return Du(I||[],H||[],Es)}var _h=Mr(function(I){var H=I.length,se=H>1?I[H-1]:n;return se=typeof se=="function"?(I.pop(),se):n,ml(I,se)});function gl(I){var H=et(I);return H.__chain__=!0,H}function xh(I,H){return H(I),I}function io(I,H){return H(I)}var wh=Pa(function(I){var H=I.length,se=H?I[0]:0,Re=this.__wrapped__,Ye=function(ct){return yo(ct,I)};return H>1||this.__actions__.length||!(Re instanceof Ar)||!Da(se)?this.thru(Ye):(Re=Re.slice(se,+se+(H?1:0)),Re.__actions__.push({func:io,args:[Ye],thisArg:n}),new Xr(Re,this.__chain__).thru(function(ct){return H&&!ct.length&&ct.push(n),ct}))});function Sh(){return gl(this)}function Th(){return new Xr(this.value(),this.__chain__)}function Eh(){this.__values__===n&&(this.__values__=Pl(this.value()));var I=this.__index__>=this.__values__.length,H=I?n:this.__values__[this.__index__++];return{done:I,value:H}}function kh(){return this}function Ah(I){for(var H,se=this;se instanceof hn;){var Re=ul(se);Re.__index__=0,Re.__values__=n,H?Ye.__wrapped__=Re:H=Re;var Ye=Re;se=se.__wrapped__}return Ye.__wrapped__=I,H}function Mh(){var I=this.__wrapped__;if(I instanceof Ar){var H=I;return this.__actions__.length&&(H=new Ar(this)),H=H.reverse(),H.__actions__.push({func:io,args:[Wo],thisArg:n}),new Xr(H,this.__chain__)}return this.thru(Wo)}function Ph(){return Pu(this.__wrapped__,this.__actions__)}var Dh=Ks(function(I,H,se){vr.call(I,se)?++I[se]:Aa(I,se,1)});function Ih(I,H,se){var Re=wr(I)?di:gc;return se&&Sn(I,H,se)&&(H=n),Re(I,cr(H,3))}function Rh(I,H){var se=wr(I)?bi:du;return se(I,cr(H,3))}var $h=qu(ll),Lh=qu(cl);function Bh(I,H){return dn(ro(I,H),1)}function Oh(I,H){return dn(ro(I,H),x)}function jh(I,H,se){return se=se===n?1:kr(se),dn(ro(I,H),se)}function vl(I,H){var se=wr(I)?St:za;return se(I,cr(H,3))}function yl(I,H){var se=wr(I)?Kt:hu;return se(I,cr(H,3))}var Fh=Ks(function(I,H,se){vr.call(I,se)?I[se].push(H):Aa(I,se,[H])});function Nh(I,H,se,Re){I=Dn(I)?I:ps(I),se=se&&!Re?kr(se):0;var Ye=I.length;return se<0&&(se=Wr(Ye+se,0)),uo(I)?se<=Ye&&I.indexOf(H,se)>-1:!!Ye&&Lr(I,H,se)>-1}var qh=Mr(function(I,H,se){var Re=-1,Ye=typeof H=="function",ct=Dn(I)?Bt(I.length):[];return za(I,function(Dt){ct[++Re]=Ye?Ze(H,Dt,se):Ss(Dt,H,se)}),ct}),zh=Ks(function(I,H,se){Aa(I,se,H)});function ro(I,H){var se=wr(I)?Ki:bu;return se(I,cr(H,3))}function Uh(I,H,se,Re){return I==null?[]:(wr(H)||(H=H==null?[]:[H]),se=Re?n:se,wr(se)||(se=se==null?[]:[se]),Su(I,H,se))}var Hh=Ks(function(I,H,se){I[se?0:1].push(H)},function(){return[[],[]]});function Vh(I,H,se){var Re=wr(I)?fr:Ln,Ye=arguments.length<3;return Re(I,cr(H,4),se,Ye,za)}function Wh(I,H,se){var Re=wr(I)?jr:Ln,Ye=arguments.length<3;return Re(I,cr(H,4),se,Ye,hu)}function Gh(I,H){var se=wr(I)?bi:du;return se(I,so(cr(H,3)))}function Qh(I){var H=wr(I)?uu:$c;return H(I)}function Yh(I,H,se){(se?Sn(I,H,se):H===n)?H=1:H=kr(H);var Re=wr(I)?fc:Lc;return Re(I,H)}function Xh(I){var H=wr(I)?hc:Oc;return H(I)}function Zh(I){if(I==null)return 0;if(Dn(I))return uo(I)?Kn(I):I.length;var H=gn(I);return H==lt||H==rt?I.size:To(I).length}function Jh(I,H,se){var Re=wr(I)?Or:jc;return se&&Sn(I,H,se)&&(H=n),Re(I,cr(H,3))}var ed=Mr(function(I,H){if(I==null)return[];var se=H.length;return se>1&&Sn(I,H[0],H[1])?H=[]:se>2&&Sn(H[0],H[1],H[2])&&(H=[H[0]]),Su(I,dn(H,1),[])}),no=Ls||function(){return $r.Date.now()};function td(I,H){if(typeof H!="function")throw new Er(m);return I=kr(I),function(){if(--I<1)return H.apply(this,arguments)}}function bl(I,H,se){return H=se?n:H,H=I&&H==null?I.length:H,Ma(I,Q,n,n,n,n,H)}function _l(I,H){var se;if(typeof H!="function")throw new Er(m);return I=kr(I),function(){return--I>0&&(se=H.apply(this,arguments)),I<=1&&(H=n),se}}var Ko=Mr(function(I,H,se){var Re=F;if(se.length){var Ye=xn(se,hs(Ko));Re|=ie}return Ma(I,Re,H,se,Ye)}),xl=Mr(function(I,H,se){var Re=F|j;if(se.length){var Ye=xn(se,hs(xl));Re|=ie}return Ma(H,Re,I,se,Ye)});function wl(I,H,se){H=se?n:H;var Re=Ma(I,Y,n,n,n,n,n,H);return Re.placeholder=wl.placeholder,Re}function Sl(I,H,se){H=se?n:H;var Re=Ma(I,J,n,n,n,n,n,H);return Re.placeholder=Sl.placeholder,Re}function Tl(I,H,se){var Re,Ye,ct,Dt,qt,Jt,Ri=0,Li=!1,ji=!1,Qi=!0;if(typeof I!="function")throw new Er(m);H=ta(H)||0,qr(se)&&(Li=!!se.leading,ji="maxWait"in se,ct=ji?Wr(ta(se.maxWait)||0,H):ct,Qi="trailing"in se?!!se.trailing:Qi);function rr(Kr){var la=Re,$a=Ye;return Re=Ye=n,Ri=Kr,Dt=I.apply($a,la),Dt}function dr(Kr){return Ri=Kr,qt=As(Pr,H),Li?rr(Kr):Dt}function Cr(Kr){var la=Kr-Jt,$a=Kr-Ri,Hl=H-la;return ji?an(Hl,ct-$a):Hl}function pr(Kr){var la=Kr-Jt,$a=Kr-Ri;return Jt===n||la>=H||la<0||ji&&$a>=ct}function Pr(){var Kr=no();if(pr(Kr))return Dr(Kr);qt=As(Pr,Cr(Kr))}function Dr(Kr){return qt=n,Qi&&Re?rr(Kr):(Re=Ye=n,Dt)}function Nn(){qt!==n&&Iu(qt),Ri=0,Re=Jt=Ye=qt=n}function Tn(){return qt===n?Dt:Dr(no())}function qn(){var Kr=no(),la=pr(Kr);if(Re=arguments,Ye=this,Jt=Kr,la){if(qt===n)return dr(Jt);if(ji)return Iu(qt),qt=As(Pr,H),rr(Jt)}return qt===n&&(qt=As(Pr,H)),Dt}return qn.cancel=Nn,qn.flush=Tn,qn}var id=Mr(function(I,H){return fu(I,1,H)}),rd=Mr(function(I,H,se){return fu(I,ta(H)||0,se)});function nd(I){return Ma(I,he)}function ao(I,H){if(typeof I!="function"||H!=null&&typeof H!="function")throw new Er(m);var se=function(){var Re=arguments,Ye=H?H.apply(this,Re):Re[0],ct=se.cache;if(ct.has(Ye))return ct.get(Ye);var Dt=I.apply(this,Re);return se.cache=ct.set(Ye,Dt)||ct,Dt};return se.cache=new(ao.Cache||Ca),se}ao.Cache=Ca;function so(I){if(typeof I!="function")throw new Er(m);return function(){var H=arguments;switch(H.length){case 0:return!I.call(this);case 1:return!I.call(this,H[0]);case 2:return!I.call(this,H[0],H[1]);case 3:return!I.call(this,H[0],H[1],H[2])}return!I.apply(this,H)}}function ad(I){return _l(2,I)}var sd=Fc(function(I,H){H=H.length==1&&wr(H[0])?Ki(H[0],ln(cr())):Ki(dn(H,1),ln(cr()));var se=H.length;return Mr(function(Re){for(var Ye=-1,ct=an(Re.length,se);++Ye<ct;)Re[Ye]=H[Ye].call(this,Re[Ye]);return Ze(I,this,Re)})}),Qo=Mr(function(I,H){var se=xn(H,hs(Qo));return Ma(I,ie,n,H,se)}),El=Mr(function(I,H){var se=xn(H,hs(El));return Ma(I,ue,n,H,se)}),od=Pa(function(I,H){return Ma(I,ce,n,n,n,H)});function ud(I,H){if(typeof I!="function")throw new Er(m);return H=H===n?H:kr(H),Mr(I,H)}function ld(I,H){if(typeof I!="function")throw new Er(m);return H=H==null?0:Wr(kr(H),0),Mr(function(se){var Re=se[H],Ye=Va(se,0,H);return Re&&yr(Ye,Re),Ze(I,this,Ye)})}function cd(I,H,se){var Re=!0,Ye=!0;if(typeof I!="function")throw new Er(m);return qr(se)&&(Re="leading"in se?!!se.leading:Re,Ye="trailing"in se?!!se.trailing:Ye),Tl(I,H,{leading:Re,maxWait:H,trailing:Ye})}function fd(I){return bl(I,1)}function hd(I,H){return Qo(Ro(H),I)}function dd(){if(!arguments.length)return[];var I=arguments[0];return wr(I)?I:[I]}function pd(I){return Zn(I,P)}function md(I,H){return H=typeof H=="function"?H:n,Zn(I,P,H)}function gd(I){return Zn(I,A|P)}function vd(I,H){return H=typeof H=="function"?H:n,Zn(I,A|P,H)}function yd(I,H){return H==null||cu(I,H,sn(H))}function ua(I,H){return I===H||I!==I&&H!==H}var bd=Zs(xo),_d=Zs(function(I,H){return I>=H}),rs=gu(function(){return arguments}())?gu:function(I){return Ur(I)&&vr.call(I,"callee")&&!Rs.call(I,"callee")},wr=Bt.isArray,xd=X?ln(X):wc;function Dn(I){return I!=null&&oo(I.length)&&!Ia(I)}function Gr(I){return Ur(I)&&Dn(I)}function wd(I){return I===!0||I===!1||Ur(I)&&wn(I)==z}var Wa=Xn||su,Sd=ae?ln(ae):Sc;function Td(I){return Ur(I)&&I.nodeType===1&&!Ms(I)}function Ed(I){if(I==null)return!0;if(Dn(I)&&(wr(I)||typeof I=="string"||typeof I.splice=="function"||Wa(I)||ds(I)||rs(I)))return!I.length;var H=gn(I);if(H==lt||H==rt)return!I.size;if(Cs(I))return!To(I).length;for(var se in I)if(vr.call(I,se))return!1;return!0}function kd(I,H){return Ts(I,H)}function Cd(I,H,se){se=typeof se=="function"?se:n;var Re=se?se(I,H):n;return Re===n?Ts(I,H,n,se):!!Re}function Yo(I){if(!Ur(I))return!1;var H=wn(I);return H==me||H==fe||typeof I.message=="string"&&typeof I.name=="string"&&!Ms(I)}function Ad(I){return typeof I=="number"&&Bs(I)}function Ia(I){if(!qr(I))return!1;var H=wn(I);return H==de||H==je||H==U||H==Je}function kl(I){return typeof I=="number"&&I==kr(I)}function oo(I){return typeof I=="number"&&I>-1&&I%1==0&&I<=S}function qr(I){var H=typeof I;return I!=null&&(H=="object"||H=="function")}function Ur(I){return I!=null&&typeof I=="object"}var Cl=Te?ln(Te):Ec;function Md(I,H){return I===H||So(I,H,No(H))}function Pd(I,H,se){return se=typeof se=="function"?se:n,So(I,H,No(H),se)}function Dd(I){return Al(I)&&I!=+I}function Id(I){if(lf(I))throw new Mi(l);return vu(I)}function Rd(I){return I===null}function $d(I){return I==null}function Al(I){return typeof I=="number"||Ur(I)&&wn(I)==it}function Ms(I){if(!Ur(I)||wn(I)!=Ct)return!1;var H=Ta(I);if(H===null)return!0;var se=vr.call(H,"constructor")&&H.constructor;return typeof se=="function"&&se instanceof se&&Mn.call(se)==Ds}var Xo=Pe?ln(Pe):kc;function Ld(I){return kl(I)&&I>=-S&&I<=S}var Ml=ze?ln(ze):Cc;function uo(I){return typeof I=="string"||!wr(I)&&Ur(I)&&wn(I)==ht}function jn(I){return typeof I=="symbol"||Ur(I)&&wn(I)==Ot}var ds=He?ln(He):Ac;function Bd(I){return I===n}function Od(I){return Ur(I)&&gn(I)==We}function jd(I){return Ur(I)&&wn(I)==Gt}var Fd=Zs(Eo),Nd=Zs(function(I,H){return I<=H});function Pl(I){if(!I)return[];if(Dn(I))return uo(I)?fn(I):Pn(I);if(Xa&&I[Xa])return Wn(I[Xa]());var H=gn(I),se=H==lt?Gn:H==rt?aa:ps;return se(I)}function Ra(I){if(!I)return I===0?I:0;if(I=ta(I),I===x||I===-x){var H=I<0?-1:1;return H*b}return I===I?I:0}function kr(I){var H=Ra(I),se=H%1;return H===H?se?H-se:H:0}function Dl(I){return I?Ja(kr(I),0,T):0}function ta(I){if(typeof I=="number")return I;if(jn(I))return h;if(qr(I)){var H=typeof I.valueOf=="function"?I.valueOf():I;I=qr(H)?H+"":H}if(typeof I!="string")return I===0?I:+I;I=An(I);var se=Bi.test(I);return se||Di.test(I)?ca(I.slice(2),se?2:8):ii.test(I)?h:+I}function Il(I){return ya(I,In(I))}function qd(I){return I?Ja(kr(I),-S,S):I===0?I:0}function Br(I){return I==null?"":On(I)}var zd=cs(function(I,H){if(Cs(H)||Dn(H)){ya(H,sn(H),I);return}for(var se in H)vr.call(H,se)&&xs(I,se,H[se])}),Rl=cs(function(I,H){ya(H,In(H),I)}),lo=cs(function(I,H,se,Re){ya(H,In(H),I,Re)}),Ud=cs(function(I,H,se,Re){ya(H,sn(H),I,Re)}),Hd=Pa(yo);function Vd(I,H){var se=Fr(I);return H==null?se:lu(se,H)}var Wd=Mr(function(I,H){I=Ui(I);var se=-1,Re=H.length,Ye=Re>2?H[2]:n;for(Ye&&Sn(H[0],H[1],Ye)&&(Re=1);++se<Re;)for(var ct=H[se],Dt=In(ct),qt=-1,Jt=Dt.length;++qt<Jt;){var Ri=Dt[qt],Li=I[Ri];(Li===n||ua(Li,Vr[Ri])&&!vr.call(I,Ri))&&(I[Ri]=ct[Ri])}return I}),Gd=Mr(function(I){return I.push(n,Ku),Ze($l,n,I)});function Kd(I,H){return $n(I,cr(H,3),va)}function Qd(I,H){return $n(I,cr(H,3),_o)}function Yd(I,H){return I==null?I:bo(I,cr(H,3),In)}function Xd(I,H){return I==null?I:pu(I,cr(H,3),In)}function Zd(I,H){return I&&va(I,cr(H,3))}function Jd(I,H){return I&&_o(I,cr(H,3))}function ep(I){return I==null?[]:Hs(I,sn(I))}function tp(I){return I==null?[]:Hs(I,In(I))}function Zo(I,H,se){var Re=I==null?n:es(I,H);return Re===n?se:Re}function ip(I,H){return I!=null&&Xu(I,H,yc)}function Jo(I,H){return I!=null&&Xu(I,H,bc)}var rp=Uu(function(I,H,se){H!=null&&typeof H.toString!="function"&&(H=Fa.call(H)),I[H]=se},tu(Rn)),np=Uu(function(I,H,se){H!=null&&typeof H.toString!="function"&&(H=Fa.call(H)),vr.call(I,H)?I[H].push(se):I[H]=[se]},cr),ap=Mr(Ss);function sn(I){return Dn(I)?ou(I):To(I)}function In(I){return Dn(I)?ou(I,!0):Mc(I)}function sp(I,H){var se={};return H=cr(H,3),va(I,function(Re,Ye,ct){Aa(se,H(Re,Ye,ct),Re)}),se}function op(I,H){var se={};return H=cr(H,3),va(I,function(Re,Ye,ct){Aa(se,Ye,H(Re,Ye,ct))}),se}var up=cs(function(I,H,se){Vs(I,H,se)}),$l=cs(function(I,H,se,Re){Vs(I,H,se,Re)}),lp=Pa(function(I,H){var se={};if(I==null)return se;var Re=!1;H=Ki(H,function(ct){return ct=Ha(ct,I),Re||(Re=ct.length>1),ct}),ya(I,jo(I),se),Re&&(se=Zn(se,A|D|P,Yc));for(var Ye=H.length;Ye--;)Po(se,H[Ye]);return se});function cp(I,H){return Ll(I,so(cr(H)))}var fp=Pa(function(I,H){return I==null?{}:Dc(I,H)});function Ll(I,H){if(I==null)return{};var se=Ki(jo(I),function(Re){return[Re]});return H=cr(H),Tu(I,se,function(Re,Ye){return H(Re,Ye[0])})}function hp(I,H,se){H=Ha(H,I);var Re=-1,Ye=H.length;for(Ye||(Ye=1,I=n);++Re<Ye;){var ct=I==null?n:I[ba(H[Re])];ct===n&&(Re=Ye,ct=se),I=Ia(ct)?ct.call(I):ct}return I}function dp(I,H,se){return I==null?I:Es(I,H,se)}function pp(I,H,se,Re){return Re=typeof Re=="function"?Re:n,I==null?I:Es(I,H,se,Re)}var Bl=Wu(sn),Ol=Wu(In);function mp(I,H,se){var Re=wr(I),Ye=Re||Wa(I)||ds(I);if(H=cr(H,4),se==null){var ct=I&&I.constructor;Ye?se=Re?new ct:[]:qr(I)?se=Ia(ct)?Fr(Ta(I)):{}:se={}}return(Ye?St:va)(I,function(Dt,qt,Jt){return H(se,Dt,qt,Jt)}),se}function gp(I,H){return I==null?!0:Po(I,H)}function vp(I,H,se){return I==null?I:Mu(I,H,Ro(se))}function yp(I,H,se,Re){return Re=typeof Re=="function"?Re:n,I==null?I:Mu(I,H,Ro(se),Re)}function ps(I){return I==null?[]:Ba(I,sn(I))}function bp(I){return I==null?[]:Ba(I,In(I))}function _p(I,H,se){return se===n&&(se=H,H=n),se!==n&&(se=ta(se),se=se===se?se:0),H!==n&&(H=ta(H),H=H===H?H:0),Ja(ta(I),H,se)}function xp(I,H,se){return H=Ra(H),se===n?(se=H,H=0):se=Ra(se),I=ta(I),_c(I,H,se)}function wp(I,H,se){if(se&&typeof se!="boolean"&&Sn(I,H,se)&&(H=se=n),se===n&&(typeof H=="boolean"?(se=H,H=n):typeof I=="boolean"&&(se=I,I=n)),I===n&&H===n?(I=0,H=1):(I=Ra(I),H===n?(H=I,I=0):H=Ra(H)),I>H){var Re=I;I=H,H=Re}if(se||I%1||H%1){var Ye=js();return an(I+Ye*(H-I+yn("1e-"+((Ye+"").length-1))),H)}return Co(I,H)}var Sp=fs(function(I,H,se){return H=H.toLowerCase(),I+(se?jl(H):H)});function jl(I){return eu(Br(I).toLowerCase())}function Fl(I){return I=Br(I),I&&I.replace(pi,na).replace($i,"")}function Tp(I,H,se){I=Br(I),H=On(H);var Re=I.length;se=se===n?Re:Ja(kr(se),0,Re);var Ye=se;return se-=H.length,se>=0&&I.slice(se,Ye)==H}function Ep(I){return I=Br(I),I&&vt.test(I)?I.replace(pt,gs):I}function kp(I){return I=Br(I),I&&Xt.test(I)?I.replace(Ut,"\\$&"):I}var Cp=fs(function(I,H,se){return I+(se?"-":"")+H.toLowerCase()}),Ap=fs(function(I,H,se){return I+(se?" ":"")+H.toLowerCase()}),Mp=Nu("toLowerCase");function Pp(I,H,se){I=Br(I),H=kr(H);var Re=H?Kn(I):0;if(!H||Re>=H)return I;var Ye=(H-Re)/2;return Xs(Yn(Ye),se)+I+Xs(Rr(Ye),se)}function Dp(I,H,se){I=Br(I),H=kr(H);var Re=H?Kn(I):0;return H&&Re<H?I+Xs(H-Re,se):I}function Ip(I,H,se){I=Br(I),H=kr(H);var Re=H?Kn(I):0;return H&&Re<H?Xs(H-Re,se)+I:I}function Rp(I,H,se){return se||H==null?H=0:H&&(H=+H),mo(Br(I).replace(Be,""),H||0)}function $p(I,H,se){return(se?Sn(I,H,se):H===n)?H=1:H=kr(H),Ao(Br(I),H)}function Lp(){var I=arguments,H=Br(I[0]);return I.length<3?H:H.replace(I[1],I[2])}var Bp=fs(function(I,H,se){return I+(se?"_":"")+H.toLowerCase()});function Op(I,H,se){return se&&typeof se!="number"&&Sn(I,H,se)&&(H=se=n),se=se===n?T:se>>>0,se?(I=Br(I),I&&(typeof H=="string"||H!=null&&!Xo(H))&&(H=On(H),!H&&cn(I))?Va(fn(I),0,se):I.split(H,se)):[]}var jp=fs(function(I,H,se){return I+(se?" ":"")+eu(H)});function Fp(I,H,se){return I=Br(I),se=se==null?0:Ja(kr(se),0,I.length),H=On(H),I.slice(se,se+H.length)==H}function Np(I,H,se){var Re=et.templateSettings;se&&Sn(I,H,se)&&(H=n),I=Br(I),H=lo({},H,Re,Gu);var Ye=lo({},H.imports,Re.imports,Gu),ct=sn(Ye),Dt=Ba(Ye,ct),qt,Jt,Ri=0,Li=H.interpolate||Ii,ji="__p += '",Qi=gr((H.escape||Ii).source+"|"+Li.source+"|"+(Li===fi?gt:Ii).source+"|"+(H.evaluate||Ii).source+"|$","g"),rr="//# sourceURL="+(vr.call(H,"sourceURL")?(H.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Un+"]")+`
`;I.replace(Qi,function(pr,Pr,Dr,Nn,Tn,qn){return Dr||(Dr=Nn),ji+=I.slice(Ri,qn).replace(Ci,ns),Pr&&(qt=!0,ji+=`' +
__e(`+Pr+`) +
'`),Tn&&(Jt=!0,ji+=`';
`+Tn+`;
__p += '`),Dr&&(ji+=`' +
((__t = (`+Dr+`)) == null ? '' : __t) +
'`),Ri=qn+pr.length,pr}),ji+=`';
`;var dr=vr.call(H,"variable")&&H.variable;if(!dr)ji=`with (obj) {
`+ji+`
}
`;else if(bt.test(dr))throw new Mi(y);ji=(Jt?ji.replace(Vt,""):ji).replace(At,"$1").replace(ve,"$1;"),ji="function("+(dr||"obj")+`) {
`+(dr?"":`obj || (obj = {});
`)+"var __t, __p = ''"+(qt?", __e = _.escape":"")+(Jt?`, __j = Array.prototype.join;
function print() { __p += __j.call(arguments, '') }
`:`;
`)+ji+`return __p
}`;var Cr=ql(function(){return Yi(ct,rr+"return "+ji).apply(n,Dt)});if(Cr.source=ji,Yo(Cr))throw Cr;return Cr}function qp(I){return Br(I).toLowerCase()}function zp(I){return Br(I).toUpperCase()}function Up(I,H,se){if(I=Br(I),I&&(se||H===n))return An(I);if(!I||!(H=On(H)))return I;var Re=fn(I),Ye=fn(H),ct=Ir(Re,Ye),Dt=da(Re,Ye)+1;return Va(Re,ct,Dt).join("")}function Hp(I,H,se){if(I=Br(I),I&&(se||H===n))return I.slice(0,as(I)+1);if(!I||!(H=On(H)))return I;var Re=fn(I),Ye=da(Re,fn(H))+1;return Va(Re,0,Ye).join("")}function Vp(I,H,se){if(I=Br(I),I&&(se||H===n))return I.replace(Be,"");if(!I||!(H=On(H)))return I;var Re=fn(I),Ye=Ir(Re,fn(H));return Va(Re,Ye).join("")}function Wp(I,H){var se=ke,Re=L;if(qr(H)){var Ye="separator"in H?H.separator:Ye;se="length"in H?kr(H.length):se,Re="omission"in H?On(H.omission):Re}I=Br(I);var ct=I.length;if(cn(I)){var Dt=fn(I);ct=Dt.length}if(se>=ct)return I;var qt=se-Kn(Re);if(qt<1)return Re;var Jt=Dt?Va(Dt,0,qt).join(""):I.slice(0,qt);if(Ye===n)return Jt+Re;if(Dt&&(qt+=Jt.length-qt),Xo(Ye)){if(I.slice(qt).search(Ye)){var Ri,Li=Jt;for(Ye.global||(Ye=gr(Ye.source,Br(ei.exec(Ye))+"g")),Ye.lastIndex=0;Ri=Ye.exec(Li);)var ji=Ri.index;Jt=Jt.slice(0,ji===n?qt:ji)}}else if(I.indexOf(On(Ye),qt)!=qt){var Qi=Jt.lastIndexOf(Ye);Qi>-1&&(Jt=Jt.slice(0,Qi))}return Jt+Re}function Gp(I){return I=Br(I),I&&Ne.test(I)?I.replace(Pt,Ka):I}var Kp=fs(function(I,H,se){return I+(se?" ":"")+H.toUpperCase()}),eu=Nu("toUpperCase");function Nl(I,H,se){return I=Br(I),H=se?n:H,H===n?Ga(I)?Ht(I):Tr(I):I.match(H)||[]}var ql=Mr(function(I,H){try{return Ze(I,n,H)}catch(se){return Yo(se)?se:new Mi(se)}}),Qp=Pa(function(I,H){return St(H,function(se){se=ba(se),Aa(I,se,Ko(I[se],I))}),I});function Yp(I){var H=I==null?0:I.length,se=cr();return I=H?Ki(I,function(Re){if(typeof Re[1]!="function")throw new Er(m);return[se(Re[0]),Re[1]]}):[],Mr(function(Re){for(var Ye=-1;++Ye<H;){var ct=I[Ye];if(Ze(ct[0],this,Re))return Ze(ct[1],this,Re)}})}function Xp(I){return mc(Zn(I,A))}function tu(I){return function(){return I}}function Zp(I,H){return I==null||I!==I?H:I}var Jp=zu(),em=zu(!0);function Rn(I){return I}function iu(I){return yu(typeof I=="function"?I:Zn(I,A))}function tm(I){return _u(Zn(I,A))}function im(I,H){return xu(I,Zn(H,A))}var rm=Mr(function(I,H){return function(se){return Ss(se,I,H)}}),nm=Mr(function(I,H){return function(se){return Ss(I,se,H)}});function ru(I,H,se){var Re=sn(H),Ye=Hs(H,Re);se==null&&!(qr(H)&&(Ye.length||!Re.length))&&(se=H,H=I,I=this,Ye=Hs(H,sn(H)));var ct=!(qr(se)&&"chain"in se)||!!se.chain,Dt=Ia(I);return St(Ye,function(qt){var Jt=H[qt];I[qt]=Jt,Dt&&(I.prototype[qt]=function(){var Ri=this.__chain__;if(ct||Ri){var Li=I(this.__wrapped__),ji=Li.__actions__=Pn(this.__actions__);return ji.push({func:Jt,args:arguments,thisArg:I}),Li.__chain__=Ri,Li}return Jt.apply(I,yr([this.value()],arguments))})}),I}function am(){return $r._===this&&($r._=bs),this}function nu(){}function sm(I){return I=kr(I),Mr(function(H){return wu(H,I)})}var om=Lo(Ki),um=Lo(di),lm=Lo(Or);function Ul(I){return zo(I)?ra(ba(I)):Ic(I)}function cm(I){return function(H){return I==null?n:es(I,H)}}var fm=Hu(),hm=Hu(!0);function au(){return[]}function su(){return!1}function dm(){return{}}function pm(){return""}function mm(){return!0}function gm(I,H){if(I=kr(I),I<1||I>S)return[];var se=T,Re=an(I,T);H=cr(H),I-=T;for(var Ye=ha(Re,H);++se<I;)H(se);return Ye}function vm(I){return wr(I)?Ki(I,ba):jn(I)?[I]:Pn(ol(Br(I)))}function ym(I){var H=++Ps;return Br(I)+H}var bm=Ys(function(I,H){return I+H},0),_m=Bo("ceil"),xm=Ys(function(I,H){return I/H},1),wm=Bo("floor");function Sm(I){return I&&I.length?Us(I,Rn,xo):n}function Tm(I,H){return I&&I.length?Us(I,cr(H,2),xo):n}function Em(I){return rn(I,Rn)}function km(I,H){return rn(I,cr(H,2))}function Cm(I){return I&&I.length?Us(I,Rn,Eo):n}function Am(I,H){return I&&I.length?Us(I,cr(H,2),Eo):n}var Mm=Ys(function(I,H){return I*H},1),Pm=Bo("round"),Dm=Ys(function(I,H){return I-H},0);function Im(I){return I&&I.length?Jr(I,Rn):0}function Rm(I,H){return I&&I.length?Jr(I,cr(H,2)):0}return et.after=td,et.ary=bl,et.assign=zd,et.assignIn=Rl,et.assignInWith=lo,et.assignWith=Ud,et.at=Hd,et.before=_l,et.bind=Ko,et.bindAll=Qp,et.bindKey=xl,et.castArray=dd,et.chain=gl,et.chunk=gf,et.compact=vf,et.concat=yf,et.cond=Yp,et.conforms=Xp,et.constant=tu,et.countBy=Dh,et.create=Vd,et.curry=wl,et.curryRight=Sl,et.debounce=Tl,et.defaults=Wd,et.defaultsDeep=Gd,et.defer=id,et.delay=rd,et.difference=bf,et.differenceBy=_f,et.differenceWith=xf,et.drop=wf,et.dropRight=Sf,et.dropRightWhile=Tf,et.dropWhile=Ef,et.fill=kf,et.filter=Rh,et.flatMap=Bh,et.flatMapDeep=Oh,et.flatMapDepth=jh,et.flatten=fl,et.flattenDeep=Cf,et.flattenDepth=Af,et.flip=nd,et.flow=Jp,et.flowRight=em,et.fromPairs=Mf,et.functions=ep,et.functionsIn=tp,et.groupBy=Fh,et.initial=Df,et.intersection=If,et.intersectionBy=Rf,et.intersectionWith=$f,et.invert=rp,et.invertBy=np,et.invokeMap=qh,et.iteratee=iu,et.keyBy=zh,et.keys=sn,et.keysIn=In,et.map=ro,et.mapKeys=sp,et.mapValues=op,et.matches=tm,et.matchesProperty=im,et.memoize=ao,et.merge=up,et.mergeWith=$l,et.method=rm,et.methodOf=nm,et.mixin=ru,et.negate=so,et.nthArg=sm,et.omit=lp,et.omitBy=cp,et.once=ad,et.orderBy=Uh,et.over=om,et.overArgs=sd,et.overEvery=um,et.overSome=lm,et.partial=Qo,et.partialRight=El,et.partition=Hh,et.pick=fp,et.pickBy=Ll,et.property=Ul,et.propertyOf=cm,et.pull=jf,et.pullAll=pl,et.pullAllBy=Ff,et.pullAllWith=Nf,et.pullAt=qf,et.range=fm,et.rangeRight=hm,et.rearg=od,et.reject=Gh,et.remove=zf,et.rest=ud,et.reverse=Wo,et.sampleSize=Yh,et.set=dp,et.setWith=pp,et.shuffle=Xh,et.slice=Uf,et.sortBy=ed,et.sortedUniq=Yf,et.sortedUniqBy=Xf,et.split=Op,et.spread=ld,et.tail=Zf,et.take=Jf,et.takeRight=eh,et.takeRightWhile=th,et.takeWhile=ih,et.tap=xh,et.throttle=cd,et.thru=io,et.toArray=Pl,et.toPairs=Bl,et.toPairsIn=Ol,et.toPath=vm,et.toPlainObject=Il,et.transform=mp,et.unary=fd,et.union=nh,et.unionBy=ah,et.unionWith=oh,et.uniq=uh,et.uniqBy=lh,et.uniqWith=fh,et.unset=gp,et.unzip=Go,et.unzipWith=ml,et.update=vp,et.updateWith=yp,et.values=ps,et.valuesIn=bp,et.without=hh,et.words=Nl,et.wrap=hd,et.xor=ph,et.xorBy=mh,et.xorWith=gh,et.zip=vh,et.zipObject=yh,et.zipObjectDeep=bh,et.zipWith=_h,et.entries=Bl,et.entriesIn=Ol,et.extend=Rl,et.extendWith=lo,ru(et,et),et.add=bm,et.attempt=ql,et.camelCase=Sp,et.capitalize=jl,et.ceil=_m,et.clamp=_p,et.clone=pd,et.cloneDeep=gd,et.cloneDeepWith=vd,et.cloneWith=md,et.conformsTo=yd,et.deburr=Fl,et.defaultTo=Zp,et.divide=xm,et.endsWith=Tp,et.eq=ua,et.escape=Ep,et.escapeRegExp=kp,et.every=Ih,et.find=$h,et.findIndex=ll,et.findKey=Kd,et.findLast=Lh,et.findLastIndex=cl,et.findLastKey=Qd,et.floor=wm,et.forEach=vl,et.forEachRight=yl,et.forIn=Yd,et.forInRight=Xd,et.forOwn=Zd,et.forOwnRight=Jd,et.get=Zo,et.gt=bd,et.gte=_d,et.has=ip,et.hasIn=Jo,et.head=dl,et.identity=Rn,et.includes=Nh,et.indexOf=Pf,et.inRange=xp,et.invoke=ap,et.isArguments=rs,et.isArray=wr,et.isArrayBuffer=xd,et.isArrayLike=Dn,et.isArrayLikeObject=Gr,et.isBoolean=wd,et.isBuffer=Wa,et.isDate=Sd,et.isElement=Td,et.isEmpty=Ed,et.isEqual=kd,et.isEqualWith=Cd,et.isError=Yo,et.isFinite=Ad,et.isFunction=Ia,et.isInteger=kl,et.isLength=oo,et.isMap=Cl,et.isMatch=Md,et.isMatchWith=Pd,et.isNaN=Dd,et.isNative=Id,et.isNil=$d,et.isNull=Rd,et.isNumber=Al,et.isObject=qr,et.isObjectLike=Ur,et.isPlainObject=Ms,et.isRegExp=Xo,et.isSafeInteger=Ld,et.isSet=Ml,et.isString=uo,et.isSymbol=jn,et.isTypedArray=ds,et.isUndefined=Bd,et.isWeakMap=Od,et.isWeakSet=jd,et.join=Lf,et.kebabCase=Cp,et.last=ea,et.lastIndexOf=Bf,et.lowerCase=Ap,et.lowerFirst=Mp,et.lt=Fd,et.lte=Nd,et.max=Sm,et.maxBy=Tm,et.mean=Em,et.meanBy=km,et.min=Cm,et.minBy=Am,et.stubArray=au,et.stubFalse=su,et.stubObject=dm,et.stubString=pm,et.stubTrue=mm,et.multiply=Mm,et.nth=Of,et.noConflict=am,et.noop=nu,et.now=no,et.pad=Pp,et.padEnd=Dp,et.padStart=Ip,et.parseInt=Rp,et.random=wp,et.reduce=Vh,et.reduceRight=Wh,et.repeat=$p,et.replace=Lp,et.result=hp,et.round=Pm,et.runInContext=mt,et.sample=Qh,et.size=Zh,et.snakeCase=Bp,et.some=Jh,et.sortedIndex=Hf,et.sortedIndexBy=Vf,et.sortedIndexOf=Wf,et.sortedLastIndex=Gf,et.sortedLastIndexBy=Kf,et.sortedLastIndexOf=Qf,et.startCase=jp,et.startsWith=Fp,et.subtract=Dm,et.sum=Im,et.sumBy=Rm,et.template=Np,et.times=gm,et.toFinite=Ra,et.toInteger=kr,et.toLength=Dl,et.toLower=qp,et.toNumber=ta,et.toSafeInteger=qd,et.toString=Br,et.toUpper=zp,et.trim=Up,et.trimEnd=Hp,et.trimStart=Vp,et.truncate=Wp,et.unescape=Gp,et.uniqueId=ym,et.upperCase=Kp,et.upperFirst=eu,et.each=vl,et.eachRight=yl,et.first=dl,ru(et,function(){var I={};return va(et,function(H,se){vr.call(et.prototype,se)||(I[se]=H)}),I}(),{chain:!1}),et.VERSION=o,St(["bind","bindKey","curry","curryRight","partial","partialRight"],function(I){et[I].placeholder=et}),St(["drop","take"],function(I,H){Ar.prototype[I]=function(se){se=se===n?1:Wr(kr(se),0);var Re=this.__filtered__&&!H?new Ar(this):this.clone();return Re.__filtered__?Re.__takeCount__=an(se,Re.__takeCount__):Re.__views__.push({size:an(se,T),type:I+(Re.__dir__<0?"Right":"")}),Re},Ar.prototype[I+"Right"]=function(se){return this.reverse()[I](se).reverse()}}),St(["filter","map","takeWhile"],function(I,H){var se=H+1,Re=se==w||se==p;Ar.prototype[I]=function(Ye){var ct=this.clone();return ct.__iteratees__.push({iteratee:cr(Ye,3),type:se}),ct.__filtered__=ct.__filtered__||Re,ct}}),St(["head","last"],function(I,H){var se="take"+(H?"Right":"");Ar.prototype[I]=function(){return this[se](1).value()[0]}}),St(["initial","tail"],function(I,H){var se="drop"+(H?"":"Right");Ar.prototype[I]=function(){return this.__filtered__?new Ar(this):this[se](1)}}),Ar.prototype.compact=function(){return this.filter(Rn)},Ar.prototype.find=function(I){return this.filter(I).head()},Ar.prototype.findLast=function(I){return this.reverse().find(I)},Ar.prototype.invokeMap=Mr(function(I,H){return typeof I=="function"?new Ar(this):this.map(function(se){return Ss(se,I,H)})}),Ar.prototype.reject=function(I){return this.filter(so(cr(I)))},Ar.prototype.slice=function(I,H){I=kr(I);var se=this;return se.__filtered__&&(I>0||H<0)?new Ar(se):(I<0?se=se.takeRight(-I):I&&(se=se.drop(I)),H!==n&&(H=kr(H),se=H<0?se.dropRight(-H):se.take(H-I)),se)},Ar.prototype.takeRightWhile=function(I){return this.reverse().takeWhile(I).reverse()},Ar.prototype.toArray=function(){return this.take(T)},va(Ar.prototype,function(I,H){var se=/^(?:filter|find|map|reject)|While$/.test(H),Re=/^(?:head|last)$/.test(H),Ye=et[Re?"take"+(H=="last"?"Right":""):H],ct=Re||/^find/.test(H);Ye&&(et.prototype[H]=function(){var Dt=this.__wrapped__,qt=Re?[1]:arguments,Jt=Dt instanceof Ar,Ri=qt[0],Li=Jt||wr(Dt),ji=function(Pr){var Dr=Ye.apply(et,yr([Pr],qt));return Re&&Qi?Dr[0]:Dr};Li&&se&&typeof Ri=="function"&&Ri.length!=1&&(Jt=Li=!1);var Qi=this.__chain__,rr=!!this.__actions__.length,dr=ct&&!Qi,Cr=Jt&&!rr;if(!ct&&Li){Dt=Cr?Dt:new Ar(this);var pr=I.apply(Dt,qt);return pr.__actions__.push({func:io,args:[ji],thisArg:n}),new Xr(pr,Qi)}return dr&&Cr?I.apply(this,qt):(pr=this.thru(ji),dr?Re?pr.value()[0]:pr.value():pr)})}),St(["pop","push","shift","sort","splice","unshift"],function(I){var H=Hr[I],se=/^(?:push|sort|unshift)$/.test(I)?"tap":"thru",Re=/^(?:pop|shift)$/.test(I);et.prototype[I]=function(){var Ye=arguments;if(Re&&!this.__chain__){var ct=this.value();return H.apply(wr(ct)?ct:[],Ye)}return this[se](function(Dt){return H.apply(wr(Dt)?Dt:[],Ye)})}}),va(Ar.prototype,function(I,H){var se=et[H];if(se){var Re=se.name+"";vr.call(dt,Re)||(dt[Re]=[]),dt[Re].push({name:H,func:se})}}),dt[Qs(n,j).name]=[{name:"wrapper",func:n}],Ar.prototype.clone=Fs,Ar.prototype.reverse=Ns,Ar.prototype.value=_s,et.prototype.at=wh,et.prototype.chain=Sh,et.prototype.commit=Th,et.prototype.next=Eh,et.prototype.plant=Ah,et.prototype.reverse=Mh,et.prototype.toJSON=et.prototype.valueOf=et.prototype.value=Ph,et.prototype.first=et.prototype.head,Xa&&(et.prototype[Xa]=kh),et},ui=ti();Zr?((Zr.exports=ui)._=ui,Hn._=ui):$r._=ui}).call(commonjsGlobal$1)}(lodash,lodash.exports);var lodashExports=lodash.exports;const _$1=getDefaultExportFromCjs$1(lodashExports);window.$=jqueryExports.$,window.jQuery=jqueryExports.jQuery,global$1.$=jqueryExports.$,global$1.jQuery=jqueryExports.jQuery;const __APP_VERSION__="",APP_VERSION=__APP_VERSION__,IriSP$1={VERSION:APP_VERSION,jQuery:jqueryExports.jQuery,libFiles:{locations:{}}};window.IriSP=IriSP$1;const Model=function(t){function e(v,w,c){c=c||10;for(var p=w.toString(c);p.length<v;)p="0"+p;return p}function n(v){return e(v,Math.floor(Math.random()*Math.pow(16,v)),16)}var o=n(8)+"-"+n(4)+"-",u=Math.floor(Math.random()*65536),l=["[aáàâä]","[cç]","[eéèêë]","[iíìîï]","[oóòôö]","[uùûü]"],m=["̀","́","̂","̃","̧","｛","｝","（","）","［","］","【","】","、","・","‥","。","「","」","『","』","〜","：","！","？","　",","," ",";","(",")",".","*","+","\\","?","|","{","}","[","]","^","#","/"],y={},E=y._SOURCE_STATUS_EMPTY=0,C=y._SOURCE_STATUS_WAITING=1,k=y._SOURCE_STATUS_READY=2,A=y.extendPrototype=function(v,w){var c=w.prototype,p=v.prototype;for(var x in c)c.hasOwnProperty(x)&&(p[x]=c[x])},D=y.getUID=function(){return o+e(4,++u%65536,16)+"-"+n(4)+"-"+n(6)+n(6)};y.isLocalURL=function(v){var w=v.match(/^(\w+:)\/\/([^/]+)/);return w?w[1]===document.location.protocol&&w[2]===document.location.host:!0};var P=y.regexpFromTextOrArray=function(v,p,x){var p=p||!1,x=x||!1;function S(T){return T.replace(/([\\\*\+\?\|\{\[\}\]\(\)\^\$\.\#\/])/gm,"\\$1")}var b=typeof v=="string"?S(v):_$1(v).map(S).join("|"),h="im";return p||(b="("+b+")",h+="g"),x&&(b="^"+b+"$"),new RegExp(b,h)},R=y.fullTextRegexps=function(v){for(var w="[\\"+m.join("\\")+"]",c=new RegExp(w,"gm"),p=v.toLowerCase().replace(c,""),x=_$1(l).map(function(T){return new RegExp(T)}),S="",b=0;b<p.length;b++){b&&(S+=w+"*");var h=p[b];_$1(l).each(function(T,M){h=h.replace(x[M],T)}),S+=h}return"("+S+")"};y.isoToDate=function(v){var w="([0-9]{4})(-([0-9]{2})(-([0-9]{2})(T([0-9]{2}):([0-9]{2})(:([0-9]{2})(.([0-9]+))?)?(Z|(([-+])([0-9]{2}):([0-9]{2})))?)?)?)?",c=v.match(new RegExp(w)),p=0,x=new Date(c[1],0,1);c[3]&&x.setMonth(c[3]-1),c[5]&&x.setDate(c[5]),c[7]&&x.setHours(c[7]),c[8]&&x.setMinutes(c[8]),c[10]&&x.setSeconds(c[10]),c[12]&&x.setMilliseconds(+("0."+c[12])*1e3),c[14]&&(p=Number(c[16])*60+Number(c[17]),p*=c[15]=="-"?1:-1),p-=x.getTimezoneOffset();const S=Number(x)+p*60*1e3;var b=new Date;return b.setTime(Number(S)),b},y.dateToIso=function(v){var w=v?new Date(v):new Date;return w.getUTCFullYear()+"-"+e(2,w.getUTCMonth()+1)+"-"+e(2,w.getUTCDate())+"T"+e(2,w.getUTCHours())+":"+e(2,w.getUTCMinutes())+":"+e(2,w.getUTCSeconds())+"Z"};var B=y.List=function(v){if(Array.call(this),this.directory=v,this.idIndex=[],this.__events={},typeof v>"u")throw console.trace(),"Error : new List(directory): directory is undefined";var w=this;this.on("clear-search",function(){w.searching=!1,w.regexp=void 0,w.forEach(function(c){c.found=void 0}),w.trigger("search-cleared")})};B.prototype=new Array,B.prototype.hasId=function(v){return _$1(this.idIndex).includes(v)},typeof Array.prototype.forEach>"u"&&(B.prototype.forEach=function(v){var w=this;_$1(this).forEach(function(c,p){v(c,p,w)})}),typeof Array.prototype.map>"u"&&(B.prototype.map=function(v){var w=this;return _$1(this).map(function(c,p){return v(c,p,w)})}),B.prototype.pluck=function(v){return this.map(function(w){return w[v]})},B.prototype.filter=function(v){var w=this,c=new B(this.directory);return c.addElements(_$1(this).filter(function(p,x){return v(p,x,w)})),c},B.prototype.slice=function(v,w){var c=new B(this.directory);return c.addElements(Array.prototype.slice.call(this,v,w)),c},B.prototype.splice=function(v,w){var c=new B(this.directory);return c.addElements(Array.prototype.splice.call(this,v,w)),this.idIndex.splice(v,w),c},B.prototype.sortBy=function(v){var w=this,c=new B(this.directory);return c.addElements(_$1(this).sortBy(function(p,x){return v(p,x,w)})),c},B.prototype.searchByTitle=function(v,c){var c=c||!1,p=P(v,!0,c);return this.filter(function(x){return p.test(x.title)})},B.prototype.searchByDescription=function(v,c){var c=c||!1,p=P(v,!0,c);return this.filter(function(x){return p.test(x.description)})},B.prototype.searchByTextFields=function(v,c){var c=c||!1,p=P(v,!0,c);return this.filter(function(x){var S=(x.keywords||x.getTagTexts()||[]).join(", ");return p.test(x.description)||p.test(x.title)||p.test(S)})},B.prototype.search=function(v){if(!v)return this.trigger("clear-search"),this;this.searching=!0,this.trigger("search",v);var w=R(v),c=new RegExp(w,"im");this.regexp=new RegExp(w,"gim");var p=this.filter(function(x,S){var b=c.test(x.title),h=c.test(x.description),T=!!(b||h);return x.found=T,x.trigger(T?"found":"not-found"),T});return this.trigger(p.length?"found":"not-found",p),p},B.prototype.searchByTags=function(v){if(!v)return this.trigger("clear-search"),this;this.searching=!0,this.trigger("search",v);var w=R(v),c=new RegExp(w,"im");this.regexp=new RegExp(w,"gim");var p=this.filter(function(x,S){var b=c.test(x.getTagTexts());return x.found=b,x.trigger(b?"found":"not-found"),b});return this.trigger(p.length?"found":"not-found",p),p},B.prototype.getTitles=function(){return this.map(function(v){return v.title})},B.prototype.addId=function(v){var w=this.directory.getElement(v);!this.hasId(v)&&typeof w<"u"&&(this.idIndex.push(v),Array.prototype.push.call(this,w))},B.prototype.push=function(v){if(!(typeof v>"u")){var w=_$1(this.idIndex).indexOf(v.id);w===-1?(this.idIndex.push(v.id),Array.prototype.push.call(this,v)):this[w]=v}},B.prototype.addIds=function(v){v.length;var w=this;_$1(v).forEach(function(c){w.addId(c)})},B.prototype.addElements=function(v){var w=this;_$1(v).forEach(function(c){w.push(c)})},B.prototype.removeId=function(v,c){var c=c||!1,p=_$1(this.idIndex).indexOf(v);p!==-1&&this.splice(p,1),c&&delete this.directory.elements[v]},B.prototype.removeElement=function(v,w){this.removeId(v.id)},B.prototype.removeIds=function(v,w){var c=this;_$1(v).forEach(function(p){c.removeId(p)})},B.prototype.removeElements=function(v,w){var c=this;_$1(v).forEach(function(p){c.removeElement(p)})},B.prototype.on=function(v,w){typeof this.__events[v]>"u"&&(this.__events[v]=[]),this.__events[v].push(w)},B.prototype.off=function(v,w){typeof this.__events[v]<"u"&&(this.__events[v]=t._(this.__events[v]).reject(function(c){return c===w}))},B.prototype.trigger=function(v,w){var c=this;_$1(this.__events[v]).each(function(p){p.call(c,w)})};var F=y.Time=function(v){this.milliseconds=0,this.setMilliseconds(v)};F.prototype.setMilliseconds=function(v){var w=this.milliseconds;switch(typeof v){case"string":this.milliseconds=parseInt(v);break;case"number":this.milliseconds=Math.floor(v);break;case"object":this.milliseconds=parseInt(v.valueOf());break;default:this.milliseconds=0}this.milliseconds===NaN&&(this.milliseconds=w)},F.prototype.setSeconds=function(v){this.milliseconds=1e3*v},F.prototype.getSeconds=function(){return this.milliseconds/1e3},F.prototype.getHMS=function(){var v=Math.abs(Math.floor(this.getSeconds()));return{hours:Math.floor(v/3600),minutes:Math.floor(v/60)%60,seconds:v%60,milliseconds:this.milliseconds%1e3}},F.prototype.add=function(v){this.milliseconds+=new F(v).milliseconds},F.prototype.valueOf=function(){return this.milliseconds},F.prototype.toString=function(v){var w=this.getHMS(),c="";return w.hours&&(c+=w.hours+":"),c+=e(2,w.minutes)+":"+e(2,w.seconds),v&&(c+="."+Math.floor(w.milliseconds/100)),c};var j=y.Reference=function(v,w){this.source=v,this.id=w,typeof w=="object"?this.isList=!0:this.isList=!1,this.refresh()};j.prototype.refresh=function(){this.isList?(this.contents=new B(this.source.directory),this.contents.addIds(this.id)):this.contents=this.source.getElement(this.id)},j.prototype.getContents=function(){return(typeof this.contents>"u"||this.isList&&this.contents.length!=this.id.length)&&this.refresh(),this.contents},j.prototype.isOrHasId=function(v){return this.isList?_$1(this.id).indexOf(v)!==-1:this.id==v};var N=y.Element=function(v,w){this.elementType="element",this.title="",this.description="",this.__events={},!(typeof w>"u")&&((typeof v>"u"||!v)&&(v=D()),this.id=v,this.source=w,w!==this&&this.source.directory.addElement(this))};N.prototype.toString=function(){return this.elementType+(this.elementType!=="element"?", id="+this.id+', title="'+this.title+'"':"")},N.prototype.setReference=function(v,w){this[v]=new j(this.source,w)},N.prototype.getReference=function(v){if(typeof this[v]<"u")return this[v].getContents()},N.prototype.getRelated=function(v,w){w=typeof w<"u"&&w;var c=this;return this.source.getList(v,w).filter(function(p){var x=p[c.elementType];return x&&x.isOrHasId(c.id)})},N.prototype.on=function(v,w){typeof this.__events[v]>"u"&&(this.__events[v]=[]),this.__events[v].push(w)},N.prototype.off=function(v,w){typeof this.__events[v]<"u"&&(this.__events[v]=_$1(this.__events[v]).reject(function(c){return c===w}))},N.prototype.trigger=function(v,w){var c=this;_$1(this.__events[v]).each(function(p){p.call(c,w)})};var Y=y.Playable=function(v,w){if(N.call(this,v,w),!(typeof w>"u")){this.elementType="playable",this.currentTime=new F,this.volume=.5,this.paused=!0,this.muted=!1,this.timeRange=!1,this.loadedMetadata=!1;var c=this;this.on("play",function(){c.paused=!1}),this.on("pause",function(){c.paused=!0}),this.on("timeupdate",function(p){c.currentTime=p,c.getAnnotations().filter(function(x){return(x.end<=p||x.begin>p)&&x.playing}).forEach(function(x){x.playing=!1,x.trigger("leave"),c.trigger("leave-annotation",x)}),c.getAnnotations().filter(function(x){return x.begin<=p&&x.end>p&&!x.playing}).forEach(function(x){x.playing=!0,x.trigger("enter"),c.trigger("enter-annotation",x)}),c.getTimeRange()&&(c.getTimeRange()[0]>p&&(c.pause(),c.setCurrentTime(c.getTimeRange()[0])),c.getTimeRange()[1]<p&&(c.pause(),c.setCurrentTime(c.getTimeRange()[1])))}),this.on("loadedmetadata",function(){c.loadedMetadata=!0})}};A(Y,N),Y.prototype.getCurrentTime=function(){return this.currentTime},Y.prototype.getVolume=function(){return this.volume},Y.prototype.getPaused=function(){return this.paused},Y.prototype.getMuted=function(){return this.muted},Y.prototype.getTimeRange=function(){return this.timeRange},Y.prototype.setCurrentTime=function(v){this.trigger("setcurrenttime",v)},Y.prototype.setVolume=function(v){this.trigger("setvolume",v)},Y.prototype.setMuted=function(v){this.trigger("setmuted",v)},Y.prototype.setTimeRange=function(v,w){if(v<w&&v>=0&&w>0)return this.trigger("settimerange",[v,w])},Y.prototype.resetTimeRange=function(){return this.trigger("resettimerange")},Y.prototype.play=function(){this.trigger("setplay")},Y.prototype.pause=function(){this.trigger("setpause")},Y.prototype.show=function(){},Y.prototype.hide=function(){};var J=y.Media=function(v,w){Y.call(this,v,w),this.elementType="media",this.duration=new F,this.video=""};A(J,Y);var J=y.Media=function(v,w){Y.call(this,v,w),this.elementType="media",this.duration=new F,this.video=""};A(J,Y),J.prototype.setDuration=function(v){this.duration.setMilliseconds(v)},J.prototype.getAnnotations=function(){return this.getRelated("annotation")},J.prototype.getAnnotationsByTypeTitle=function(v){var w=this.source.getAnnotationTypes().searchByTitle(v).pluck("id");return w.length?this.getAnnotations().filter(function(c){return _$1(w).indexOf(c.getAnnotationType().id)!==-1}):new B(this.source.directory)};var ie=y.Tag=function(v,w){N.call(this,v,w),this.elementType="tag"};A(ie,N),ie.prototype.getAnnotations=function(){return this.getRelated("annotation")};var ue=y.AnnotationType=function(v,w){N.call(this,v,w),this.elementType="annotationType"};A(ue,N),ue.prototype.getAnnotations=function(){return this.getRelated("annotation")};var Q=y.Annotation=function(v,w){N.call(this,v,w),this.elementType="annotation",this.begin=new F,this.end=new F,this.tag=new j(w,[]),this.playing=!1;var c=this;this.on("click",function(){c.getMedia().setCurrentTime(c.begin)})};A(Q,N),Q.prototype.setBeginEnd=function(v,w){v=Math.max(0,v),w=Math.max(0,w),w<v&&(w=v),this.begin.setMilliseconds(v),this.end.setMilliseconds(w),this.trigger("change-begin"),this.trigger("change-end")},Q.prototype.setBegin=function(v){this.begin.setMilliseconds(Math.max(0,v)),this.trigger("change-begin"),this.end<this.begin&&this.setEnd(this.begin)},Q.prototype.setEnd=function(v){this.end.setMilliseconds(Math.min(v,this.getMedia().duration.milliseconds)),this.trigger("change-end"),this.end<this.begin&&this.setBegin(this.end)},Q.prototype.setDuration=function(v){this.setEnd(v+this.begin.milliseconds)},Q.prototype.setMedia=function(v){this.setReference("media",v)},Q.prototype.getMedia=function(){return this.getReference("media")},Q.prototype.setAnnotationType=function(v){this.setReference("annotationType",v)},Q.prototype.getAnnotationType=function(){return this.getReference("annotationType")},Q.prototype.setTags=function(v){this.setReference("tag",v)},Q.prototype.getTags=function(){return this.getReference("tag")},Q.prototype.getTagTexts=function(){return this.getTags().getTitles()},Q.prototype.getDuration=function(){return new F(this.end.milliseconds-this.begin.milliseconds)};var ce=y.MashedAnnotation=function(v,w){N.call(this,v.id+"_"+w.id,w.source),this.elementType="mashedAnnotation",this.annotation=w,this.begin=new F,this.end=new F,this.duration=new F,this.title=this.annotation.title,this.description=this.annotation.description,this.color=this.annotation.color;var c=this;this.on("click",function(){v.setCurrentTime(c.begin)}),this.on("enter",function(){c.annotation.trigger("enter")}),this.on("leave",function(){c.annotation.trigger("leave")})};A(ce,N),ce.prototype.getMedia=function(){return this.annotation.getReference("media")},ce.prototype.getAnnotationType=function(){return this.annotation.getReference("annotationType")},ce.prototype.getTags=function(){return this.annotation.getReference("tag")},ce.prototype.getTagTexts=function(){return this.annotation.getTags().getTitles()},ce.prototype.getDuration=function(){return this.annotation.getDuration()},ce.prototype.setBegin=function(v){this.begin.setMilliseconds(v),this.duration.setMilliseconds(this.annotation.getDuration()),this.end.setMilliseconds(v+this.duration)};var he=y.Mashup=function(v,w){Y.call(this,v,w),this.elementType="mashup",this.duration=new F,this.segments=new B(w.directory),this.loaded=!1;var c=this;this._updateTimes=function(){c.updateTimes(),c.trigger("change")},this.on("add",this._updateTimes),this.on("remove",this._updateTimes)};A(he,Y),he.prototype.updateTimes=function(){var v=0;this.segments.forEach(function(w){w.setBegin(v),v=w.end}),this.duration.setMilliseconds(v)},he.prototype.addAnnotation=function(v,p){var c=new ce(this,v),p=p||!1;this.segments.push(c),v.on("change-begin",this._updateTimes),v.on("change-end",this._updateTimes),p||this.trigger("add")},he.prototype.addAnnotationById=function(v,p){var c=this.source.getElement(v),p=p||!1;typeof c<"u"&&this.addAnnotation(c,p)},he.prototype.addAnnotations=function(v){var w=this;_$1(v).forEach(function(c){w.addAnnotation(c,!0)}),this.trigger("add")},he.prototype.addAnnotationsById=function(v){var w=this;_$1(v).forEach(function(c){w.addAnnotationById(c,!0)}),this.trigger("add")},he.prototype.removeAnnotation=function(v,c){var c=c||!1;v.off("change-begin",this._updateTimes),v.off("change-end",this._updateTimes),this.segments.removeId(this.id+"_"+v.id),c||this.trigger("remove")},he.prototype.removeAnnotationById=function(v,c){var c=c||!1,p=this.source.getElement(v);p&&this.removeAnnotation(p,c),c||this.trigger("remove")},he.prototype.setAnnotations=function(v){for(;this.segments.length;)this.removeAnnotation(this.segments[0].annotation,!0);this.addAnnotations(v)},he.prototype.setAnnotationsById=function(v){for(;this.segments.length;)this.removeAnnotation(this.segments[0].annotation,!0);this.addAnnotationsById(v)},he.prototype.hasAnnotation=function(v){return!!_$1(this.segments).find(function(w){return w.annotation===v})},he.prototype.getAnnotation=function(v){return _$1(this.segments).find(function(w){return w.annotation===v})},he.prototype.getAnnotationById=function(v){return _$1(this.segments).find(function(w){return w.annotation.id===v})},he.prototype.getAnnotations=function(){return this.segments},he.prototype.getOriginalAnnotations=function(){var v=new B(this.source.directory);return this.segments.forEach(function(w){v.push(w.annotation)}),v},he.prototype.getMedias=function(){var v=new B(this.source.directory);return this.segments.forEach(function(w){v.push(w.getMedia())}),v},he.prototype.getAnnotationsByTypeTitle=function(v){var w=this.source.getAnnotationTypes().searchByTitle(v).pluck("id");return w.length?this.getAnnotations().filter(function(c){return _$1(w).indexOf(c.getAnnotationType().id)!==-1}):new B(this.source.directory)},he.prototype.getAnnotationAtTime=function(v){var w=this.segments.filter(function(c){return c.begin<=v&&c.end>v});if(w.length)return w[0]},he.prototype.getMediaAtTime=function(v){var w=this.getAnnotationAtTime(v);if(typeof w<"u")return w.getMedia()};var ke=y.Source=function(v){if(N.call(this,!1,this),this.status=E,this.elementType="source",typeof v<"u"){var w=this;_$1(v).forEach(function(c,p){w[p]=c}),this.callbackQueue=[],this.contents={},this.get()}};A(ke,N),ke.prototype.addList=function(v,w){typeof this.contents[v]>"u"&&(this.contents[v]=new B(this.directory)),this.contents[v].addElements(w)},ke.prototype.getList=function(v,w){return w=typeof w<"u"&&w,w?this.directory.getGlobalList().filter(function(c){return c.elementType===v}):(typeof this.contents[v]>"u"&&(this.contents[v]=new B(this.directory)),this.contents[v])},ke.prototype.forEach=function(v){var w=this;_$1(this.contents).forEach(function(c,p){v.call(w,c,p)})},ke.prototype.getElement=function(v){return this.directory.getElement(v)},ke.prototype.get=function(){this.status=C,this.handleCallbacks()},ke.prototype.deferCallback=function(v){var w=this;_$1.defer(function(){v.call(w)})},ke.prototype.handleCallbacks=function(){for(this.status=k;this.callbackQueue.length;)this.deferCallback(this.callbackQueue.splice(0,1)[0])},ke.prototype.onLoad=function(v){this.status===k?this.deferCallback(v):this.callbackQueue.push(v)},ke.prototype.serialize=function(){return this.serializer.serialize(this)},ke.prototype.deSerialize=function(v){this.serializer.deSerialize(v,this)},ke.prototype.getAnnotations=function(v){return v=typeof v<"u"&&v,this.getList("annotation",v)},ke.prototype.getMedias=function(v){return v=typeof v<"u"&&v,this.getList("media",v)},ke.prototype.getTags=function(v){return v=typeof v<"u"&&v,this.getList("tag",v)},ke.prototype.getMashups=function(v){return v=typeof v<"u"&&v,this.getList("mashup",v)},ke.prototype.getAnnotationTypes=function(v){return v=typeof v<"u"&&v,this.getList("annotationType",v)},ke.prototype.getAnnotationsByTypeTitle=function(v,w){w=typeof w<"u"&&w;var c=new B(this.directory),p=this.getAnnotationTypes(w).searchByTitle(v);return p.forEach(function(x){c.addElements(x.getAnnotations(w))}),c},ke.prototype.getDuration=function(){var v=this.currentMedia;if(typeof v<"u")return this.currentMedia.duration},ke.prototype.getCurrentMedia=function(v){if(typeof this.currentMedia>"u")if(v.is_mashup){var w=this.getMashups();w.length&&(this.currentMedia=w[0])}else{var c=this.getMedias();c.length&&(this.currentMedia=c[0])}return this.currentMedia},ke.prototype.merge=function(v){var w=this;v.forEach(function(c,p){w.getList(p).addElements(c)})};var L=y.RemoteSource=function(v){ke.call(this,v)};A(L,ke),L.prototype.get=function(){this.status=C;var v=this,w=this.url_params||{},c=this.dataType||"json";w.format=c,jQuery.ajax({url:this.url,dataType:c,data:w,traditional:!0,success:function(p){v.deSerialize(p),v.handleCallbacks()}})};var d=y.Directory=function(){this.remoteSources={},this.elements={}};return d.prototype.remoteSource=function(v){if(typeof v!="object"||typeof v.url>"u")throw"Error : Directory.remoteSource(configuration): configuration.url is undefined";var w=_$1({directory:this}).extend(v);w.url_params=w.url_params||{};var c=w.url+"?"+jQuery.param(w.url_params);return typeof this.remoteSources[c]>"u"&&(this.remoteSources[c]=new L(w)),this.remoteSources[c]},d.prototype.newLocalSource=function(v){var w=_$1({directory:this}).extend(v),c=new ke(w);return c},d.prototype.getElement=function(v){return this.elements[v]},d.prototype.addElement=function(v){this.elements[v.id]=v},d.prototype.getGlobalList=function(){var v=new B(this);return v.addIds(_$1(this.elements).keys()),v},y},htmlPlayer=function(t,e,n){var o=n||{},u=o.video||t.video;typeof o.url_transform=="function"&&(u=o.url_transform(u));var l=jQuery("<video>");if(l.attr({width:o.width||void 0,height:o.height||void 0,controls:o.controls||void 0,autoplay:o.autostart||o.autoplay||void 0}),typeof u=="string")l.attr("src",u);else for(var m=0;m<u.length;m++){var y=jQuery("<source>");y.attr({src:u[m].src,type:u[m].type}),l.append(y)}if(o.subtitle){var E=jQuery("<track>");E.attr({label:"Subtitles",kind:"subtitles",srclang:"fr",src:o.subtitle,default:""}),l.append(E)}e.html(l);var C=l[0];t.on("setcurrenttime",function(A){try{C.currentTime=A/1e3}catch{}}),t.on("setvolume",function(A){t.volume=A;try{C.volume=A}catch{}}),t.on("setmuted",function(A){t.muted=A;try{C.muted=A}catch{}}),t.on("settimerange",function(A){t.timeRange=A;try{(t.getCurrentTime()>A[0]||t.getCurrentTime()<A)&&(C.currentTime=A[0]/1e3)}catch{}}),t.on("resettimerange",function(){t.timeRange=!1}),t.on("setplay",function(){try{C.play()}catch{}}),t.on("setpause",function(){try{C.pause()}catch{}});function k(){t.muted=C.muted,t.volume=C.volume}l.on("loadedmetadata",function(){k(),t.trigger("loadedmetadata"),t.trigger("volumechange")}),l.on("timeupdate",function(){t.trigger("timeupdate",new IriSP.Model.Time(1e3*C.currentTime))}),l.on("volumechange",function(){k(),t.trigger("volumechange")}),l.on("play",function(){t.trigger("play")}),l.on("pause",function(){t.trigger("pause")}),l.on("seeking",function(){t.trigger("seeking")}),l.on("seeked",function(){t.trigger("seeked")}),l.on("click",function(){C.paused?t.play():t.pause()})};function utils$s(t){return{jqEscape:function(e){return e.replace(/(:|\.)/g,"\\$1")},textFieldHtml:function(e,n,o){var u=[],l=[],m=e.replace(/(^\s+|\s+$)/g,"");function y(R,B,F){for(;;){var j=R.exec(m);if(!j)break;var N=R.lastIndex,Y=j.index;u.push({start:Y,end:N,startHtml:typeof B=="function"?B(j):B,endHtml:typeof F=="function"?F(j):F}),l.push(Y),l.push(N)}}n&&y(n,'<span class="Ldt-Highlight">',"</span>"),y(/(https?:\/\/)?[\w\d\-]+\.[\w\d\-]+\S+/gm,function(R){return'<a href="'+(R[1]?"":"http://")+R[0]+'" target="_blank">'},"</a>"),y(/@([\d\w]{1,15})/gm,function(R){return'<a href="http://twitter.com/'+R[1]+'" target="_blank">'},"</a>"),y(/\*[^*]+\*/gm,"<b>","</b>"),y(/[\n\r]+/gm,"","<br />"),_$1(o).each(function(R){y.apply(null,R)}),l=_$1(l).chain().uniq().sortBy(function(R){return parseInt(R)}).value();for(var E="",C=0,k=0;k<l.length;k++){var A=l[k];E+=m.substring(C,A);for(var D=u.length-1;D>=0;D--){var P=u[D];P.start<A&&P.end>=A&&(E+=P.endHtml)}for(var D=0;D<u.length;D++){var P=u[D];P.start<=A&&P.end>A&&(E+=P.startHtml)}C=A}return E+=m.substring(C),E},log:function(){typeof console<"u"&&typeof t.logging<"u"&&t.logging&&console.log.apply(console,arguments)},attachDndData:function(e,n){e.attr("draggable","true").on("dragstart",function(o){var u=typeof n=="function"?n.call(this):n;try{u.html===void 0&&u.uri&&u.text&&(u.html='<a href="'+u.uri+'">'+u.text+"</a>"),_$1(u).each(function(l,m){l&&m!="text"&&m!="html"&&o.originalEvent.dataTransfer.setData("text/x-iri-"+m,l)}),u.uri&&u.text&&(o.originalEvent.dataTransfer.setData("text/x-moz-url",u.uri+`
`+u.text.replace(`
`," ")),o.originalEvent.dataTransfer.setData("text/plain",u.text+" "+u.uri)),u.html!==void 0&&o.originalEvent.dataTransfer.setData("text/html",u.html),u.text!==void 0&&!u.uri&&o.originalEvent.dataTransfer.setData("text/plain",u.text)}catch{o.originalEvent.dataTransfer.setData("Text",JSON.stringify(u))}})},FakeClass:function(e){var n=this,o=function(){};_$1(e).each(function(u){n[u]=o})},timestamp2ms:function(e){for(var n=e.split(":").reverse();n.length<3;)n.push("0");return 1e3*(3600*parseInt(n[2],10)+60*parseInt(n[1],10)+parseInt(n[0],10))},setFullScreen:function(e,n){n?e.requestFullscreen?e.requestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.webkitRequestFullscreen?e.webkitRequestFullscreen():e.msRequestFullscreen&&e.msRequestFullscreen():document.exitFullscreen?document.exitFullscreen():document.msExitFullscreen?document.msExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitExitFullscreen&&document.webkitExitFullscreen()},isFullscreen:function(){return document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement},getFullscreenElement:function(){return document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement||void 0},getFullscreenEventname:function(){return document.exitFullscreen&&"fullscreenchange"||document.webkitExitFullscreen&&"webkitfullscreenchange"||document.mozExitFullScreen&&"mozfullscreenchange"||document.msExitFullscreen&&"msfullscreenchange"||""}}}const iFrameUpdater=function(t){var e=document.getElementById(t),n=!1,o=function(){n=!0,window.setTimeout(function(){n=!1},1e3),e.contentWindow.postMessage(document.location.hash,"*")};window.onhashchange=o,window.addEventListener("message",function(u){/^#/.test(u.data)&&!n&&(typeof window.history<"u"&&typeof window.history.replaceState<"u"?window.history.replaceState({},"",u.data):document.location.hash=u.data)}),window.setTimeout(o,2e3)},content=function(t){return{deSerialize:function(e,n){var o=new t.Model.List(n.directory);function u(l,m){var y=new t.Model.Media(l.iri_id,n);y.video=l.media_url,y.title=l.title,y.description=l.description,y.setDuration(l.duration),y.thumbnail=l.image,y.color=t.vizcolors[m%t.vizcolors.length],y.keywords=l.tags,o.push(y)}typeof e.objects<"u"?_$1(e.objects).each(u):u(e,0),n.addList("media",o)}}},ldt_annotate=function(t){return{serializeAnnotation:function(e,n){var o=e.getAnnotationType();return{id:e.id,begin:e.begin.milliseconds,end:e.end.milliseconds,content:{data:e.content?e.content.data||{}:{},description:e.description,title:e.title,audio:e.audio},id:e.id?e.id:"",tags:e.getTagTexts(),media:e.getMedia().id,project:e.project_id,type_title:o.title,type:typeof o.dont_send_id<"u"&&o.dont_send_id?"":o.id,meta:{created:e.created,creator:e.creator,modified:e.modified,contributor:e.contributor}}},deserializeAnnotation:function(e,n){var o=new t.Model.Annotation(e.id,n);o.description=e.content.description||"",o.title=e.content.title||"",o.creator=e.meta.creator||"",o.created=new Date(e.meta.created),o.setMedia(e.media,n);var u=n.getElement(e.type);u||(u=new t.Model.AnnotationType(e.type,n),u.title=e.type_title,n.getAnnotationTypes().push(u)),o.setAnnotationType(u.id);var l=_$1(e.tags).map(function(m){var y=n.getTags(!0).searchByTitle(m,!0);if(y.length)var E=y[0];else E=new t.Model.Tag(m.replace(/\W/g,"_"),n),E.title=m,n.getTags().push(E);return E.id});o.setTags(l),o.setBeginEnd(e.begin,e.end),typeof e.content.audio<"u"&&e.content.audio.href&&(o.audio=e.content.audio),e.content.data&&(o.content={data:e.content.data}),n.getAnnotations().push(o)},serialize:function(e){return JSON.stringify(this.serializeAnnotation(e.getAnnotations()[0],e))},deSerialize:function(e,n){typeof e=="string"&&(e=JSON.parse(e)),n.addList("tag",new t.Model.List(n.directory)),n.addList("annotationType",new t.Model.List(n.directory)),n.addList("annotation",new t.Model.List(n.directory)),this.deserializeAnnotation(e,n)}}},ldt_localstorage=function(t){return{serializeAnnotation:function(e,n){var o=e.getAnnotationType();return{id:e.id,begin:e.begin.milliseconds,end:e.end.milliseconds,content:{data:e.content?e.content.data||{}:{},description:e.description,title:e.title,audio:e.audio},tags:e.getTagTexts(),media:e.getMedia().id,type_title:o.title,type:typeof o.dont_send_id<"u"&&o.dont_send_id?"":o.id,meta:{created:e.created,creator:e.creator,modified:e.modified,contributor:e.contributor}}},deserializeAnnotation:function(e,n){var o=new t.Model.Annotation(e.id,n);o.description=e.content.description||"",o.title=e.content.title||"",o.creator=e.meta.creator||"",o.created=new Date(e.meta.created),o.contributor=e.meta.contributor||"",o.modified=new Date(e.meta.modified),o.setMedia(e.media,n);var u=n.getElement(e.type);u||(u=new t.Model.AnnotationType(e.type,n),u.title=e.type_title,n.getAnnotationTypes().push(u)),o.setAnnotationType(u.id);var l=_$1(e.tags).map(function(m){var y=n.getTags(!0).searchByTitle(m,!0);if(y.length)var E=y[0];else E=new t.Model.Tag(m.replace(/\W/g,"_"),n),E.title=m,n.getTags().push(E);return E.id});o.setTags(l),o.setBeginEnd(e.begin,e.end),typeof e.content.audio<"u"&&e.content.audio.href&&(o.audio=e.content.audio),e.content.data&&(o.content={data:e.content.data}),n.getAnnotations().push(o)},serialize:function(e){var n=this;return JSON.stringify(e.getAnnotations().map(function(o){return n.serializeAnnotation(o,e)}))},deSerialize:function(e,n){var o=this;typeof e=="string"&&(e=JSON.parse(e)),n.addList("tag",new t.Model.List(n.directory)),n.addList("annotationType",new t.Model.List(n.directory)),n.addList("annotation",new t.Model.List(n.directory)),e.map(function(u){o.deserializeAnnotation(u,n)})}}},ldt=function(t){return{types:{media:{serialized_name:"medias",deserializer:function(e,n){var o=new t.Model.Media(e.id,n);return o.video=typeof e.url<"u"?e.url:typeof e.href<"u"?e.href:null,typeof e.meta.item<"u"&&e.meta.item.name==="streamer"&&(o.streamer=e.meta.item.value),o.title=e.meta["dc:title"],o.description=e.meta["dc:description"],o.setDuration(e.meta["dc:duration"]),o.url=e.meta.url,typeof e.meta.img<"u"&&e.meta.img.src!=="undefined"&&(o.thumbnail=e.meta.img.src),o},serializer:function(e,n,o){var u={id:e.id,url:e.video,meta:{"dc:title":e.title||"","dc:description":e.description||"","dc:created":t.Model.dateToIso(e.created||n.created),"dc:modified":t.Model.dateToIso(e.modified||n.modified),"dc:creator":e.creator||n.creator,"dc:contributor":e.contributor||n.contributor||e.creator||n.creator,"dc:duration":e.duration.milliseconds}};o.medias.push(u);var l={id:t.Model.getUID(),meta:{"dc:title":e.title||"","dc:description":e.description||"","dc:created":t.Model.dateToIso(e.created||n.created),"dc:modified":t.Model.dateToIso(e.modified||n.modified),"dc:creator":e.creator||n.creator,"dc:contributor":e.contributor||n.contributor||e.creator||n.creator,"id-ref":e.id},items:n.getAnnotationTypes().filter(function(m){switch(typeof m.media){case"object":return m.media===e;case"string":return m.media===e.id;default:var y=m.getAnnotations();if(y){for(var E=0;E<y.length;E++)if(y[E].getMedia()===e)return!0}}return!1}).map(function(m){return{"id-ref":m.id}})};o.lists.push(l),o.views[0].contents.push(e.id)}},tag:{serialized_name:"tags",deserializer:function(e,n){var o=new t.Model.Tag(e.id,n);return o.title=e.meta["dc:title"],o},serializer:function(e,n,o){if(!(n.regenerateTags&&!e.regenerated)){var u={id:e.id,meta:{"dc:title":e.title||"","dc:description":e.description||"","dc:created":t.Model.dateToIso(e.created||n.created),"dc:modified":t.Model.dateToIso(e.modified||n.modified),"dc:creator":e.creator||n.creator,"dc:contributor":e.contributor||n.contributor||e.creator||n.creator}};o.tags.push(u)}}},annotationType:{serialized_name:"annotation-types",deserializer:function(e,n){var o=new t.Model.AnnotationType(e.id,n);return o.title=e["dc:title"],o.description=e["dc:description"],o},serializer:function(e,n,o){var u={id:e.id,"dc:title":e.title||"","dc:description":e.description||"","dc:created":t.Model.dateToIso(e.created||n.created),"dc:modified":t.Model.dateToIso(e.modified||n.modified),"dc:creator":e.creator||n.creator,"dc:contributor":e.contributor||n.contributor||e.creator||n.creator};o["annotation-types"].push(u),o.views[0].annotation_types.push(e.id)}},annotation:{serialized_name:"annotations",deserializer:function(e,n){var o=new t.Model.Annotation(e.id,n);if(o.title=e.content.title||"",o.description=e.content.description||"",typeof e.content.img<"u"&&e.content.img.src!=="undefined"&&(o.thumbnail=e.content.img.src),o.created=t.Model.isoToDate(e.created?e.created:e.meta?e.meta["dc:created"]:""),typeof e.color<"u"){for(var u=parseInt(e.color).toString(16);u.length<6;)u="0"+u;o.color="#"+u}return o.content=e.content,o.setMedia(e.media),o.setAnnotationType(e.meta["id-ref"]),o.setTags(_$1(e.tags).map("id-ref")),o.keywords=o.getTagTexts(),o.setBegin(e.begin),o.setEnd(e.end),o.creator=e.meta["dc:creator"]||"",o.project=e.meta.project||"",typeof e.meta["dc:source"]<"u"&&typeof e.meta["dc:source"].content<"u"&&(o.source=JSON.parse(e.meta["dc:source"].content)),typeof e.content.audio<"u"&&e.content.audio.href&&(o.audio=e.content.audio),o},serializer:function(e,n,o){var u=parseInt(e.color.replace(/^#/,""),16).toString(),l={id:e.id,begin:e.begin.milliseconds,end:e.end.milliseconds,content:_$1.defaults({},{title:e.title,description:e.description,audio:e.audio,img:{src:e.thumbnail}},e.content,{title:"",description:""}),color:u,media:e.media.id,meta:{"id-ref":e.getAnnotationType().id,"dc:created":t.Model.dateToIso(e.created||n.created),"dc:modified":t.Model.dateToIso(e.modified||n.modified),"dc:creator":e.creator||n.creator,"dc:contributor":e.contributor||n.contributor||e.creator||n.creator}};n.regenerateTags?l.tags=_$1(e.keywords).map(function(m){return{"id-ref":n.__keywords[m.toLowerCase()].id}}):l.tags=_$1(e.tag.id).map(function(m){return{"id-ref":m}}),l.content.title=e.title||l.content.title||"",o.annotations.push(l)}},mashup:{serialized_name:"lists",deserializer:function(e,n){if(!(typeof e.meta!="object"||typeof e.meta.listtype!="string"||e.meta.listtype!=="mashup")){var o=new t.Model.Mashup(e.id,n);return o.title=e.meta["dc:title"],o.description=e.meta["dc:description"],o.creator=e.meta["dc:creator"],o.setAnnotationsById(e.items),o}},serializer:function(e,n,o){var u={meta:{"dc:title":e.title||"","dc:description":e.description||"","dc:created":t.Model.dateToIso(e.created||n.created),"dc:modified":t.Model.dateToIso(e.modified||n.modified),"dc:creator":e.creator||n.creator,"dc:contributor":e.contributor||n.contributor||e.creator||n.creator,listtype:"mashup"},items:e.segments.map(function(l){return l.annotation.id}),id:e.id};o.lists.push(u)}}},serialize:function(e){var n={meta:{"dc:creator":e.creator,"dc:contributor":e.contributor||e.creator,"dc:created":t.Model.dateToIso(e.created),"dc:modified":t.Model.dateToIso(e.modified),"dc:title":e.title||"","dc:description":e.description||"",id:e.projectId||e.id},views:[{id:t.Model.getUID(),contents:[],annotation_types:[]}],lists:[],"annotation-types":[],medias:[],tags:[],annotations:[]},o=this;return e.regenerateTags&&(e.__keywords={},e.getAnnotations().forEach(function(u){_$1(u.keywords).each(function(l){var m=l.toLowerCase();typeof e.__keywords[m]>"u"&&(e.__keywords[m]={id:t.Model.getUID(),title:l,regenerated:!0})})}),_$1(e.__keywords).each(function(u){o.types.tag.serializer(u,e,n)})),e.forEach(function(u,l){typeof o.types[l]<"u"&&u.forEach(function(m){o.types[l].serializer(m,e,n)})}),JSON.stringify(n)},deSerialize:function(e,n){typeof e!="object"||e===null||(_$1(this.types).forEach(function(o,u){var l=e[o.serialized_name],m=new t.Model.List(n.directory);if(typeof l<"u"&&l!==null)if(l.hasOwnProperty("length"))for(var y=l.length,E=0;E<y;E++){var C=o.deserializer(l[E],n);typeof C<"u"&&C&&m.push(C)}else{var C=o.deserializer(l,n);typeof C<"u"&&C&&m.push(C)}n.addList(u,m)}),typeof e.meta<"u"&&(n.projectId=e.meta.id,n.title=e.meta["dc:title"]||e.meta.title||"",n.description=e.meta["dc:description"]||e.meta.description||"",n.creator=e.meta["dc:creator"]||e.meta.creator||"",n.contributor=e.meta["dc:contributor"]||e.meta.contributor||n.creator,n.created=t.Model.isoToDate(e.meta["dc:created"]||e.meta.created)),typeof e.meta<"u"&&typeof e.meta.main_media<"u"&&typeof e.meta.main_media["id-ref"]<"u"&&(n.currentMedia=n.getElement(e.meta.main_media["id-ref"])))}}},segmentapi=function(t){return{deSerialize:function(e,n){var o=new t.Model.List(n.directory),u=new t.Model.List(n.directory);n.addList("media",u);function l(m){var y=new t.Model.Annotation(m.element_id,n),E=n.getElement(m.iri_id);E||(E=new t.Model.Media(m.iri_id,n),n.getMedias().push(E)),y.setMedia(m.iri_id),y.title=m.title,y.description=m.abstract,y.begin=new t.Model.Time(m.start_ts),y.end=new t.Model.Time(m.start_ts+m.duration),y.keywords=m.tags?m.tags.split(","):[],y.project_id=m.project_id,o.push(y)}typeof e.objects<"u"?_$1(e.objects).each(l):l(e),n.addList("annotation",o)}}},serializers=function(t){return{content:content(t),ldt_annotate:ldt_annotate(t),ldt_localstorage:ldt_localstorage(t),ldt:ldt(t),segmentapi:segmentapi(t)}};var Youtube={exports:{}},win;typeof window<"u"?win=window:typeof commonjsGlobal$1<"u"?win=commonjsGlobal$1:typeof self<"u"?win=self:win={};var window_1=win;const window$1$1=getDefaultExportFromCjs$1(window_1),__viteBrowserExternal={},__viteBrowserExternal$1=Object.freeze(Object.defineProperty({__proto__:null,default:__viteBrowserExternal},Symbol.toStringTag,{value:"Module"})),require$$0$6=getAugmentedNamespace(__viteBrowserExternal$1);var topLevel=typeof commonjsGlobal$1<"u"?commonjsGlobal$1:typeof window<"u"?window:{},minDoc=require$$0$6,doccy;typeof document<"u"?doccy=document:(doccy=topLevel["__GLOBAL_DOCUMENT_CACHE@4"],doccy||(doccy=topLevel["__GLOBAL_DOCUMENT_CACHE@4"]=minDoc));var document_1=doccy;const document$1$1=getDefaultExportFromCjs$1(document_1);var lib$6={exports:{}};function _extends$2(){return _extends$2=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var o in n)({}).hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},_extends$2.apply(null,arguments)}const _extends$3=Object.freeze(Object.defineProperty({__proto__:null,get default(){return _extends$2}},Symbol.toStringTag,{value:"Module"})),require$$1$6=getAugmentedNamespace(_extends$3);var isFunction_1=isFunction$3,toString$2=Object.prototype.toString;function isFunction$3(t){if(!t)return!1;var e=toString$2.call(t);return e==="[object Function]"||typeof t=="function"&&e!=="[object RegExp]"||typeof window<"u"&&(t===window.setTimeout||t===window.alert||t===window.confirm||t===window.prompt)}function _createForOfIteratorHelperLoose(t,e){var n=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n)return(n=n.call(t)).next.bind(n);if(Array.isArray(t)||(n=_unsupportedIterableToArray(t))||e){n&&(t=n);var o=0;return function(){return o>=t.length?{done:!0}:{done:!1,value:t[o++]}}}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 _unsupportedIterableToArray(t,e){if(t){if(typeof t=="string")return _arrayLikeToArray(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(t,e)}}function _arrayLikeToArray(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,o=new Array(e);n<e;n++)o[n]=t[n];return o}var InterceptorsStorage$1=function(){function t(){this.typeToInterceptorsMap_=new Map,this.enabled_=!1}var e=t.prototype;return e.getIsEnabled=function(){return this.enabled_},e.enable=function(){this.enabled_=!0},e.disable=function(){this.enabled_=!1},e.reset=function(){this.typeToInterceptorsMap_=new Map,this.enabled_=!1},e.addInterceptor=function(o,u){this.typeToInterceptorsMap_.has(o)||this.typeToInterceptorsMap_.set(o,new Set);var l=this.typeToInterceptorsMap_.get(o);return l.has(u)?!1:(l.add(u),!0)},e.removeInterceptor=function(o,u){var l=this.typeToInterceptorsMap_.get(o);return l&&l.has(u)?(l.delete(u),!0):!1},e.clearInterceptorsByType=function(o){var u=this.typeToInterceptorsMap_.get(o);return u?(this.typeToInterceptorsMap_.delete(o),this.typeToInterceptorsMap_.set(o,new Set),!0):!1},e.clear=function(){return this.typeToInterceptorsMap_.size?(this.typeToInterceptorsMap_=new Map,!0):!1},e.getForType=function(o){return this.typeToInterceptorsMap_.get(o)||new Set},e.execute=function(o,u){for(var l=this.getForType(o),m=_createForOfIteratorHelperLoose(l),y;!(y=m()).done;){var E=y.value;try{u=E(u)}catch{}}return u},t}(),interceptors=InterceptorsStorage$1,RetryManager$1=function(){function t(){this.maxAttempts_=1,this.delayFactor_=.1,this.fuzzFactor_=.1,this.initialDelay_=1e3,this.enabled_=!1}var e=t.prototype;return e.getIsEnabled=function(){return this.enabled_},e.enable=function(){this.enabled_=!0},e.disable=function(){this.enabled_=!1},e.reset=function(){this.maxAttempts_=1,this.delayFactor_=.1,this.fuzzFactor_=.1,this.initialDelay_=1e3,this.enabled_=!1},e.getMaxAttempts=function(){return this.maxAttempts_},e.setMaxAttempts=function(o){this.maxAttempts_=o},e.getDelayFactor=function(){return this.delayFactor_},e.setDelayFactor=function(o){this.delayFactor_=o},e.getFuzzFactor=function(){return this.fuzzFactor_},e.setFuzzFactor=function(o){this.fuzzFactor_=o},e.getInitialDelay=function(){return this.initialDelay_},e.setInitialDelay=function(o){this.initialDelay_=o},e.createRetry=function(o){var u=o===void 0?{}:o,l=u.maxAttempts,m=u.delayFactor,y=u.fuzzFactor,E=u.initialDelay;return new Retry({maxAttempts:l||this.maxAttempts_,delayFactor:m||this.delayFactor_,fuzzFactor:y||this.fuzzFactor_,initialDelay:E||this.initialDelay_})},t}(),Retry=function(){function t(n){this.maxAttempts_=n.maxAttempts,this.delayFactor_=n.delayFactor,this.fuzzFactor_=n.fuzzFactor,this.currentDelay_=n.initialDelay,this.currentAttempt_=1}var e=t.prototype;return e.moveToNextAttempt=function(){this.currentAttempt_++;var o=this.currentDelay_*this.delayFactor_;this.currentDelay_=this.currentDelay_+o},e.shouldRetry=function(){return this.currentAttempt_<this.maxAttempts_},e.getCurrentDelay=function(){return this.currentDelay_},e.getCurrentMinPossibleDelay=function(){return(1-this.fuzzFactor_)*this.currentDelay_},e.getCurrentMaxPossibleDelay=function(){return(1+this.fuzzFactor_)*this.currentDelay_},e.getCurrentFuzzedDelay=function(){var o=this.getCurrentMinPossibleDelay(),u=this.getCurrentMaxPossibleDelay();return o+Math.random()*(u-o)},t}(),retry=RetryManager$1,window$3=window_1,httpResponseHandler=function(e,n){return n===void 0&&(n=!1),function(o,u,l){if(o){e(o);return}if(u.statusCode>=400&&u.statusCode<=599){var m=l;if(n)if(window$3.TextDecoder){var y=getCharset(u.headers&&u.headers["content-type"]);try{m=new TextDecoder(y).decode(l)}catch{}}else m=String.fromCharCode.apply(null,new Uint8Array(l));e({cause:m});return}e(null,l)}};function getCharset(t){return t===void 0&&(t=""),t.toLowerCase().split(";").reduce(function(e,n){var o=n.split("="),u=o[0],l=o[1];return u.trim()==="charset"?l.trim():e},"utf-8")}var httpHandler=httpResponseHandler,window$2=window_1,_extends$1=require$$1$6,isFunction$2=isFunction_1,InterceptorsStorage=interceptors,RetryManager=retry;createXHR.httpHandler=httpHandler,createXHR.requestInterceptorsStorage=new InterceptorsStorage,createXHR.responseInterceptorsStorage=new InterceptorsStorage,createXHR.retryManager=new RetryManager;/**
 * @license
 * slighly modified parse-headers 2.0.2 <https://github.com/kesla/parse-headers/>
 * Copyright (c) 2014 David Björklund
 * Available under the MIT license
 * <https://github.com/kesla/parse-headers/blob/master/LICENCE>
 */var parseHeaders=function(e){var n={};return e&&e.trim().split(`
`).forEach(function(o){var u=o.indexOf(":"),l=o.slice(0,u).trim().toLowerCase(),m=o.slice(u+1).trim();typeof n[l]>"u"?n[l]=m:Array.isArray(n[l])?n[l].push(m):n[l]=[n[l],m]}),n};lib$6.exports=createXHR,lib$6.exports.default=createXHR,createXHR.XMLHttpRequest=window$2.XMLHttpRequest||noop$2,createXHR.XDomainRequest="withCredentials"in new createXHR.XMLHttpRequest?createXHR.XMLHttpRequest:window$2.XDomainRequest,forEachArray$1(["get","put","post","patch","head","delete"],function(t){createXHR[t==="delete"?"del":t]=function(e,n,o){return n=initParams$1(e,n,o),n.method=t.toUpperCase(),_createXHR(n)}});function forEachArray$1(t,e){for(var n=0;n<t.length;n++)e(t[n])}function isEmpty(t){for(var e in t)if(t.hasOwnProperty(e))return!1;return!0}function initParams$1(t,e,n){var o=t;return isFunction$2(e)?(n=e,typeof t=="string"&&(o={uri:t})):o=_extends$1({},e,{uri:t}),o.callback=n,o}function createXHR(t,e,n){return e=initParams$1(t,e,n),_createXHR(e)}function _createXHR(t){if(typeof t.callback>"u")throw new Error("callback argument missing");if(t.requestType&&createXHR.requestInterceptorsStorage.getIsEnabled()){var e={uri:t.uri||t.url,headers:t.headers||{},body:t.body,metadata:t.metadata||{},retry:t.retry,timeout:t.timeout},n=createXHR.requestInterceptorsStorage.execute(t.requestType,e);t.uri=n.uri,t.headers=n.headers,t.body=n.body,t.metadata=n.metadata,t.retry=n.retry,t.timeout=n.timeout}var o=!1,u=function(ie,ue,Q){o||(o=!0,t.callback(ie,ue,Q))};function l(){C.readyState===4&&!createXHR.responseInterceptorsStorage.getIsEnabled()&&setTimeout(E,0)}function m(){var J=void 0;if(C.response?J=C.response:J=C.responseText||getXml(C),j)try{J=JSON.parse(J)}catch{}return J}function y(J){if(clearTimeout(N),clearTimeout(t.retryTimeout),J instanceof Error||(J=new Error(""+(J||"Unknown XMLHttpRequest Error"))),J.statusCode=0,!A&&createXHR.retryManager.getIsEnabled()&&t.retry&&t.retry.shouldRetry()){t.retryTimeout=setTimeout(function(){t.retry.moveToNextAttempt(),t.xhr=C,_createXHR(t)},t.retry.getCurrentFuzzedDelay());return}if(t.requestType&&createXHR.responseInterceptorsStorage.getIsEnabled()){var ie={headers:Y.headers||{},body:Y.body,responseUrl:C.responseURL,responseType:C.responseType},ue=createXHR.responseInterceptorsStorage.execute(t.requestType,ie);Y.body=ue.body,Y.headers=ue.headers}return u(J,Y)}function E(){if(!A){var J;clearTimeout(N),clearTimeout(t.retryTimeout),t.useXDR&&C.status===void 0?J=200:J=C.status===1223?204:C.status;var ie=Y,ue=null;if(J!==0?(ie={body:m(),statusCode:J,method:P,headers:{},url:D,rawRequest:C},C.getAllResponseHeaders&&(ie.headers=parseHeaders(C.getAllResponseHeaders()))):ue=new Error("Internal XMLHttpRequest Error"),t.requestType&&createXHR.responseInterceptorsStorage.getIsEnabled()){var Q={headers:ie.headers||{},body:ie.body,responseUrl:C.responseURL,responseType:C.responseType},ce=createXHR.responseInterceptorsStorage.execute(t.requestType,Q);ie.body=ce.body,ie.headers=ce.headers}return u(ue,ie,ie.body)}}var C=t.xhr||null;C||(t.cors||t.useXDR?C=new createXHR.XDomainRequest:C=new createXHR.XMLHttpRequest);var k,A,D=C.url=t.uri||t.url,P=C.method=t.method||"GET",R=t.body||t.data,B=C.headers=t.headers||{},F=!!t.sync,j=!1,N,Y={body:void 0,headers:{},statusCode:0,method:P,url:D,rawRequest:C};if("json"in t&&t.json!==!1&&(j=!0,B.accept||B.Accept||(B.Accept="application/json"),P!=="GET"&&P!=="HEAD"&&(B["content-type"]||B["Content-Type"]||(B["Content-Type"]="application/json"),R=JSON.stringify(t.json===!0?R:t.json))),C.onreadystatechange=l,C.onload=E,C.onerror=y,C.onprogress=function(){},C.onabort=function(){A=!0,clearTimeout(t.retryTimeout)},C.ontimeout=y,C.open(P,D,!F,t.username,t.password),F||(C.withCredentials=!!t.withCredentials),!F&&t.timeout>0&&(N=setTimeout(function(){if(!A){A=!0,C.abort("timeout");var J=new Error("XMLHttpRequest timeout");J.code="ETIMEDOUT",y(J)}},t.timeout)),C.setRequestHeader)for(k in B)B.hasOwnProperty(k)&&C.setRequestHeader(k,B[k]);else if(t.headers&&!isEmpty(t.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in t&&(C.responseType=t.responseType),"beforeSend"in t&&typeof t.beforeSend=="function"&&t.beforeSend(C),C.send(R||null),C}function getXml(t){try{if(t.responseType==="document")return t.responseXML;var e=t.responseXML&&t.responseXML.documentElement.nodeName==="parsererror";if(t.responseType===""&&!e)return t.responseXML}catch{}return null}function noop$2(){}var libExports=lib$6.exports;const XHR=getDefaultExportFromCjs$1(libExports);var browserIndex={exports:{}},document$1=document_1,_objCreate=Object.create||function(){function t(){}return function(e){if(arguments.length!==1)throw new Error("Object.create shim only accepts one parameter.");return t.prototype=e,new t}}();function ParsingError(t,e){this.name="ParsingError",this.code=t.code,this.message=e||t.message}ParsingError.prototype=_objCreate(Error.prototype),ParsingError.prototype.constructor=ParsingError,ParsingError.Errors={BadSignature:{code:0,message:"Malformed WebVTT signature."},BadTimeStamp:{code:1,message:"Malformed time stamp."}};function parseTimeStamp(t){function e(o,u,l,m){return(o|0)*3600+(u|0)*60+(l|0)+(m|0)/1e3}var n=t.match(/^(\d+):(\d{1,2})(:\d{1,2})?\.(\d{3})/);return n?n[3]?e(n[1],n[2],n[3].replace(":",""),n[4]):n[1]>59?e(n[1],n[2],0,n[4]):e(0,n[1],n[2],n[4]):null}function Settings(){this.values=_objCreate(null)}Settings.prototype={set:function(t,e){!this.get(t)&&e!==""&&(this.values[t]=e)},get:function(t,e,n){return n?this.has(t)?this.values[t]:e[n]:this.has(t)?this.values[t]:e},has:function(t){return t in this.values},alt:function(t,e,n){for(var o=0;o<n.length;++o)if(e===n[o]){this.set(t,e);break}},integer:function(t,e){/^-?\d+$/.test(e)&&this.set(t,parseInt(e,10))},percent:function(t,e){return e.match(/^([\d]{1,3})(\.[\d]*)?%$/)&&(e=parseFloat(e),e>=0&&e<=100)?(this.set(t,e),!0):!1}};function parseOptions(t,e,n,o){var u=o?t.split(o):[t];for(var l in u)if(typeof u[l]=="string"){var m=u[l].split(n);if(m.length===2){var y=m[0].trim(),E=m[1].trim();e(y,E)}}}function parseCue(t,e,n){var o=t;function u(){var y=parseTimeStamp(t);if(y===null)throw new ParsingError(ParsingError.Errors.BadTimeStamp,"Malformed timestamp: "+o);return t=t.replace(/^[^\sa-zA-Z-]+/,""),y}function l(y,E){var C=new Settings;parseOptions(y,function(k,A){switch(k){case"region":for(var D=n.length-1;D>=0;D--)if(n[D].id===A){C.set(k,n[D].region);break}break;case"vertical":C.alt(k,A,["rl","lr"]);break;case"line":var P=A.split(","),R=P[0];C.integer(k,R),C.percent(k,R)&&C.set("snapToLines",!1),C.alt(k,R,["auto"]),P.length===2&&C.alt("lineAlign",P[1],["start","center","end"]);break;case"position":P=A.split(","),C.percent(k,P[0]),P.length===2&&C.alt("positionAlign",P[1],["start","center","end"]);break;case"size":C.percent(k,A);break;case"align":C.alt(k,A,["start","center","end","left","right"]);break}},/:/,/\s/),E.region=C.get("region",null),E.vertical=C.get("vertical","");try{E.line=C.get("line","auto")}catch{}E.lineAlign=C.get("lineAlign","start"),E.snapToLines=C.get("snapToLines",!0),E.size=C.get("size",100);try{E.align=C.get("align","center")}catch{E.align=C.get("align","middle")}try{E.position=C.get("position","auto")}catch{E.position=C.get("position",{start:0,left:0,center:50,middle:50,end:100,right:100},E.align)}E.positionAlign=C.get("positionAlign",{start:"start",left:"start",center:"center",middle:"center",end:"end",right:"end"},E.align)}function m(){t=t.replace(/^\s+/,"")}if(m(),e.startTime=u(),m(),t.substr(0,3)!=="-->")throw new ParsingError(ParsingError.Errors.BadTimeStamp,"Malformed time stamp (time stamps must be separated by '-->'): "+o);t=t.substr(3),m(),e.endTime=u(),m(),l(t,e)}var TEXTAREA_ELEMENT=document$1.createElement&&document$1.createElement("textarea"),TAG_NAME={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},DEFAULT_COLOR_CLASS={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)"},TAG_ANNOTATION={v:"title",lang:"lang"},NEEDS_PARENT={rt:"ruby"};function parseContent(t,e){function n(){if(!e)return null;function R(F){return e=e.substr(F.length),F}var B=e.match(/^([^<]*)(<[^>]*>?)?/);return R(B[1]?B[1]:B[2])}function o(R){return TEXTAREA_ELEMENT.innerHTML=R,R=TEXTAREA_ELEMENT.textContent,TEXTAREA_ELEMENT.textContent="",R}function u(R,B){return!NEEDS_PARENT[B.localName]||NEEDS_PARENT[B.localName]===R.localName}function l(R,B){var F=TAG_NAME[R];if(!F)return null;var j=t.document.createElement(F),N=TAG_ANNOTATION[R];return N&&B&&(j[N]=B.trim()),j}for(var m=t.document.createElement("div"),y=m,E,C=[];(E=n())!==null;){if(E[0]==="<"){if(E[1]==="/"){C.length&&C[C.length-1]===E.substr(2).replace(">","")&&(C.pop(),y=y.parentNode);continue}var k=parseTimeStamp(E.substr(1,E.length-2)),A;if(k){A=t.document.createProcessingInstruction("timestamp",k),y.appendChild(A);continue}var D=E.match(/^<([^.\s/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!D||(A=l(D[1],D[3]),!A)||!u(y,A))continue;if(D[2]){var P=D[2].split(".");P.forEach(function(R){var B=/^bg_/.test(R),F=B?R.slice(3):R;if(DEFAULT_COLOR_CLASS.hasOwnProperty(F)){var j=B?"background-color":"color",N=DEFAULT_COLOR_CLASS[F];A.style[j]=N}}),A.className=P.join(" ")}C.push(D[1]),y.appendChild(A),y=A;continue}y.appendChild(t.document.createTextNode(o(E)))}return m}var strongRTLRanges=[[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 isStrongRTLChar(t){for(var e=0;e<strongRTLRanges.length;e++){var n=strongRTLRanges[e];if(t>=n[0]&&t<=n[1])return!0}return!1}function determineBidi(t){var e=[],n="",o;if(!t||!t.childNodes)return"ltr";function u(y,E){for(var C=E.childNodes.length-1;C>=0;C--)y.push(E.childNodes[C])}function l(y){if(!y||!y.length)return null;var E=y.pop(),C=E.textContent||E.innerText;if(C){var k=C.match(/^.*(\n|\r)/);return k?(y.length=0,k[0]):C}if(E.tagName==="ruby")return l(y);if(E.childNodes)return u(y,E),l(y)}for(u(e,t);n=l(e);)for(var m=0;m<n.length;m++)if(o=n.charCodeAt(m),isStrongRTLChar(o))return"rtl";return"ltr"}function computeLinePos(t){if(typeof t.line=="number"&&(t.snapToLines||t.line>=0&&t.line<=100))return t.line;if(!t.track||!t.track.textTrackList||!t.track.textTrackList.mediaElement)return-1;for(var e=t.track,n=e.textTrackList,o=0,u=0;u<n.length&&n[u]!==e;u++)n[u].mode==="showing"&&o++;return++o*-1}function StyleBox(){}StyleBox.prototype.applyStyles=function(t,e){e=e||this.div;for(var n in t)t.hasOwnProperty(n)&&(e.style[n]=t[n])},StyleBox.prototype.formatStyle=function(t,e){return t===0?0:t+e};function CueStyleBox(t,e,n){StyleBox.call(this),this.cue=e,this.cueDiv=parseContent(t,e.text);var o={color:"rgba(255, 255, 255, 1)",backgroundColor:"rgba(0, 0, 0, 0.8)",position:"relative",left:0,right:0,top:0,bottom:0,display:"inline",writingMode:e.vertical===""?"horizontal-tb":e.vertical==="lr"?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext"};this.applyStyles(o,this.cueDiv),this.div=t.document.createElement("div"),o={direction:determineBidi(this.cueDiv),writingMode:e.vertical===""?"horizontal-tb":e.vertical==="lr"?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext",textAlign:e.align==="middle"?"center":e.align,font:n.font,whiteSpace:"pre-line",position:"absolute"},this.applyStyles(o),this.div.appendChild(this.cueDiv);var u=0;switch(e.positionAlign){case"start":case"line-left":u=e.position;break;case"center":u=e.position-e.size/2;break;case"end":case"line-right":u=e.position-e.size;break}e.vertical===""?this.applyStyles({left:this.formatStyle(u,"%"),width:this.formatStyle(e.size,"%")}):this.applyStyles({top:this.formatStyle(u,"%"),height:this.formatStyle(e.size,"%")}),this.move=function(l){this.applyStyles({top:this.formatStyle(l.top,"px"),bottom:this.formatStyle(l.bottom,"px"),left:this.formatStyle(l.left,"px"),right:this.formatStyle(l.right,"px"),height:this.formatStyle(l.height,"px"),width:this.formatStyle(l.width,"px")})}}CueStyleBox.prototype=_objCreate(StyleBox.prototype),CueStyleBox.prototype.constructor=CueStyleBox;function BoxPosition(t){var e,n,o,u;if(t.div){n=t.div.offsetHeight,o=t.div.offsetWidth,u=t.div.offsetTop;var l=(l=t.div.childNodes)&&(l=l[0])&&l.getClientRects&&l.getClientRects();t=t.div.getBoundingClientRect(),e=l?Math.max(l[0]&&l[0].height||0,t.height/l.length):0}this.left=t.left,this.right=t.right,this.top=t.top||u,this.height=t.height||n,this.bottom=t.bottom||u+(t.height||n),this.width=t.width||o,this.lineHeight=e!==void 0?e:t.lineHeight}BoxPosition.prototype.move=function(t,e){switch(e=e!==void 0?e:this.lineHeight,t){case"+x":this.left+=e,this.right+=e;break;case"-x":this.left-=e,this.right-=e;break;case"+y":this.top+=e,this.bottom+=e;break;case"-y":this.top-=e,this.bottom-=e;break}},BoxPosition.prototype.overlaps=function(t){return this.left<t.right&&this.right>t.left&&this.top<t.bottom&&this.bottom>t.top},BoxPosition.prototype.overlapsAny=function(t){for(var e=0;e<t.length;e++)if(this.overlaps(t[e]))return!0;return!1},BoxPosition.prototype.within=function(t){return this.top>=t.top&&this.bottom<=t.bottom&&this.left>=t.left&&this.right<=t.right},BoxPosition.prototype.overlapsOppositeAxis=function(t,e){switch(e){case"+x":return this.left<t.left;case"-x":return this.right>t.right;case"+y":return this.top<t.top;case"-y":return this.bottom>t.bottom}},BoxPosition.prototype.intersectPercentage=function(t){var e=Math.max(0,Math.min(this.right,t.right)-Math.max(this.left,t.left)),n=Math.max(0,Math.min(this.bottom,t.bottom)-Math.max(this.top,t.top)),o=e*n;return o/(this.height*this.width)},BoxPosition.prototype.toCSSCompatValues=function(t){return{top:this.top-t.top,bottom:t.bottom-this.bottom,left:this.left-t.left,right:t.right-this.right,height:this.height,width:this.width}},BoxPosition.getSimpleBoxPosition=function(t){var e=t.div?t.div.offsetHeight:t.tagName?t.offsetHeight:0,n=t.div?t.div.offsetWidth:t.tagName?t.offsetWidth:0,o=t.div?t.div.offsetTop:t.tagName?t.offsetTop:0;t=t.div?t.div.getBoundingClientRect():t.tagName?t.getBoundingClientRect():t;var u={left:t.left,right:t.right,top:t.top||o,height:t.height||e,bottom:t.bottom||o+(t.height||e),width:t.width||n};return u};function moveBoxToLinePosition(t,e,n,o){function u(F,j){for(var N,Y=new BoxPosition(F),J=1,ie=0;ie<j.length;ie++){for(;F.overlapsOppositeAxis(n,j[ie])||F.within(n)&&F.overlapsAny(o);)F.move(j[ie]);if(F.within(n))return F;var ue=F.intersectPercentage(n);J>ue&&(N=new BoxPosition(F),J=ue),F=new BoxPosition(Y)}return N||Y}var l=new BoxPosition(e),m=e.cue,y=computeLinePos(m),E=[];if(m.snapToLines){var C;switch(m.vertical){case"":E=["+y","-y"],C="height";break;case"rl":E=["+x","-x"],C="width";break;case"lr":E=["-x","+x"],C="width";break}var k=l.lineHeight,A=k*Math.round(y),D=n[C]+k,P=E[0];Math.abs(A)>D&&(A=A<0?-1:1,A*=Math.ceil(D/k)*k),y<0&&(A+=m.vertical===""?n.height:n.width,E=E.reverse()),l.move(P,A)}else{var R=l.lineHeight/n.height*100;switch(m.lineAlign){case"center":y-=R/2;break;case"end":y-=R;break}switch(m.vertical){case"":e.applyStyles({top:e.formatStyle(y,"%")});break;case"rl":e.applyStyles({left:e.formatStyle(y,"%")});break;case"lr":e.applyStyles({right:e.formatStyle(y,"%")});break}E=["+y","-x","+x","-y"],l=new BoxPosition(e)}var B=u(l,E);e.move(B.toCSSCompatValues(n))}function WebVTT$1(){}WebVTT$1.StringDecoder=function(){return{decode:function(t){if(!t)return"";if(typeof t!="string")throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(t))}}},WebVTT$1.convertCueToDOMTree=function(t,e){return!t||!e?null:parseContent(t,e)};var FONT_SIZE_PERCENT=.05,FONT_STYLE="sans-serif",CUE_BACKGROUND_PADDING="1.5%";WebVTT$1.processCues=function(t,e,n){if(!t||!e||!n)return null;for(;n.firstChild;)n.removeChild(n.firstChild);var o=t.document.createElement("div");o.style.position="absolute",o.style.left="0",o.style.right="0",o.style.top="0",o.style.bottom="0",o.style.margin=CUE_BACKGROUND_PADDING,n.appendChild(o);function u(k){for(var A=0;A<k.length;A++)if(k[A].hasBeenReset||!k[A].displayState)return!0;return!1}if(!u(e)){for(var l=0;l<e.length;l++)o.appendChild(e[l].displayState);return}var m=[],y=BoxPosition.getSimpleBoxPosition(o),E=Math.round(y.height*FONT_SIZE_PERCENT*100)/100,C={font:E+"px "+FONT_STYLE};(function(){for(var k,A,D=0;D<e.length;D++)A=e[D],k=new CueStyleBox(t,A,C),o.appendChild(k.div),moveBoxToLinePosition(t,k,y,m),A.displayState=k.div,m.push(BoxPosition.getSimpleBoxPosition(k))})()},WebVTT$1.Parser=function(t,e,n){n||(n=e,e={}),e||(e={}),this.window=t,this.vttjs=e,this.state="INITIAL",this.buffer="",this.decoder=n||new TextDecoder("utf8"),this.regionList=[]},WebVTT$1.Parser.prototype={reportOrThrowError:function(t){if(t instanceof ParsingError)this.onparsingerror&&this.onparsingerror(t);else throw t},parse:function(t){var e=this;t&&(e.buffer+=e.decoder.decode(t,{stream:!0}));function n(){for(var k=e.buffer,A=0;A<k.length&&k[A]!=="\r"&&k[A]!==`
`;)++A;var D=k.substr(0,A);return k[A]==="\r"&&++A,k[A]===`
`&&++A,e.buffer=k.substr(A),D}function o(k){var A=new Settings;if(parseOptions(k,function(P,R){switch(P){case"id":A.set(P,R);break;case"width":A.percent(P,R);break;case"lines":A.integer(P,R);break;case"regionanchor":case"viewportanchor":var B=R.split(",");if(B.length!==2)break;var F=new Settings;if(F.percent("x",B[0]),F.percent("y",B[1]),!F.has("x")||!F.has("y"))break;A.set(P+"X",F.get("x")),A.set(P+"Y",F.get("y"));break;case"scroll":A.alt(P,R,["up"]);break}},/=/,/\s/),A.has("id")){var D=new(e.vttjs.VTTRegion||e.window.VTTRegion);D.width=A.get("width",100),D.lines=A.get("lines",3),D.regionAnchorX=A.get("regionanchorX",0),D.regionAnchorY=A.get("regionanchorY",100),D.viewportAnchorX=A.get("viewportanchorX",0),D.viewportAnchorY=A.get("viewportanchorY",100),D.scroll=A.get("scroll",""),e.onregion&&e.onregion(D),e.regionList.push({id:A.get("id"),region:D})}}function u(k){var A=new Settings;parseOptions(k,function(D,P){switch(D){case"MPEGT":A.integer(D+"S",P);break;case"LOCA":A.set(D+"L",parseTimeStamp(P));break}},/[^\d]:/,/,/),e.ontimestampmap&&e.ontimestampmap({MPEGTS:A.get("MPEGTS"),LOCAL:A.get("LOCAL")})}function l(k){k.match(/X-TIMESTAMP-MAP/)?parseOptions(k,function(A,D){switch(A){case"X-TIMESTAMP-MAP":u(D);break}},/=/):parseOptions(k,function(A,D){switch(A){case"Region":o(D);break}},/:/)}try{var m;if(e.state==="INITIAL"){if(!/\r\n|\n/.test(e.buffer))return this;m=n();var y=m.match(/^WEBVTT([ \t].*)?$/);if(!y||!y[0])throw new ParsingError(ParsingError.Errors.BadSignature);e.state="HEADER"}for(var E=!1;e.buffer;){if(!/\r\n|\n/.test(e.buffer))return this;switch(E?E=!1:m=n(),e.state){case"HEADER":/:/.test(m)?l(m):m||(e.state="ID");continue;case"NOTE":m||(e.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(m)){e.state="NOTE";break}if(!m)continue;e.cue=new(e.vttjs.VTTCue||e.window.VTTCue)(0,0,"");try{e.cue.align="center"}catch{e.cue.align="middle"}if(e.state="CUE",m.indexOf("-->")===-1){e.cue.id=m;continue}case"CUE":try{parseCue(m,e.cue,e.regionList)}catch(k){e.reportOrThrowError(k),e.cue=null,e.state="BADCUE";continue}e.state="CUETEXT";continue;case"CUETEXT":var C=m.indexOf("-->")!==-1;if(!m||C&&(E=!0)){e.oncue&&e.oncue(e.cue),e.cue=null,e.state="ID";continue}e.cue.text&&(e.cue.text+=`
`),e.cue.text+=m.replace(/\u2028/g,`
`).replace(/u2029/g,`
`);continue;case"BADCUE":m||(e.state="ID");continue}}}catch(k){e.reportOrThrowError(k),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 t=this;try{if(t.buffer+=t.decoder.decode(),(t.cue||t.state==="HEADER")&&(t.buffer+=`

`,t.parse()),t.state==="INITIAL")throw new ParsingError(ParsingError.Errors.BadSignature)}catch(e){t.reportOrThrowError(e)}return t.onflush&&t.onflush(),this}};var vtt$1=WebVTT$1,autoKeyword="auto",directionSetting={"":1,lr:1,rl:1},alignSetting={start:1,center:1,end:1,left:1,right:1,auto:1,"line-left":1,"line-right":1};function findDirectionSetting(t){if(typeof t!="string")return!1;var e=directionSetting[t.toLowerCase()];return e?t.toLowerCase():!1}function findAlignSetting(t){if(typeof t!="string")return!1;var e=alignSetting[t.toLowerCase()];return e?t.toLowerCase():!1}function VTTCue(t,e,n){this.hasBeenReset=!1;var o="",u=!1,l=t,m=e,y=n,E=null,C="",k=!0,A="auto",D="start",P="auto",R="auto",B=100,F="center";Object.defineProperties(this,{id:{enumerable:!0,get:function(){return o},set:function(j){o=""+j}},pauseOnExit:{enumerable:!0,get:function(){return u},set:function(j){u=!!j}},startTime:{enumerable:!0,get:function(){return l},set:function(j){if(typeof j!="number")throw new TypeError("Start time must be set to a number.");l=j,this.hasBeenReset=!0}},endTime:{enumerable:!0,get:function(){return m},set:function(j){if(typeof j!="number")throw new TypeError("End time must be set to a number.");m=j,this.hasBeenReset=!0}},text:{enumerable:!0,get:function(){return y},set:function(j){y=""+j,this.hasBeenReset=!0}},region:{enumerable:!0,get:function(){return E},set:function(j){E=j,this.hasBeenReset=!0}},vertical:{enumerable:!0,get:function(){return C},set:function(j){var N=findDirectionSetting(j);if(N===!1)throw new SyntaxError("Vertical: an invalid or illegal direction string was specified.");C=N,this.hasBeenReset=!0}},snapToLines:{enumerable:!0,get:function(){return k},set:function(j){k=!!j,this.hasBeenReset=!0}},line:{enumerable:!0,get:function(){return A},set:function(j){if(typeof j!="number"&&j!==autoKeyword)throw new SyntaxError("Line: an invalid number or illegal string was specified.");A=j,this.hasBeenReset=!0}},lineAlign:{enumerable:!0,get:function(){return D},set:function(j){var N=findAlignSetting(j);N?(D=N,this.hasBeenReset=!0):console.warn("lineAlign: an invalid or illegal string was specified.")}},position:{enumerable:!0,get:function(){return P},set:function(j){if(j<0||j>100)throw new Error("Position must be between 0 and 100.");P=j,this.hasBeenReset=!0}},positionAlign:{enumerable:!0,get:function(){return R},set:function(j){var N=findAlignSetting(j);N?(R=N,this.hasBeenReset=!0):console.warn("positionAlign: an invalid or illegal string was specified.")}},size:{enumerable:!0,get:function(){return B},set:function(j){if(j<0||j>100)throw new Error("Size must be between 0 and 100.");B=j,this.hasBeenReset=!0}},align:{enumerable:!0,get:function(){return F},set:function(j){var N=findAlignSetting(j);if(!N)throw new SyntaxError("align: an invalid or illegal alignment string was specified.");F=N,this.hasBeenReset=!0}}}),this.displayState=void 0}VTTCue.prototype.getCueAsHTML=function(){return WebVTT.convertCueToDOMTree(window,this.text)};var vttcue=VTTCue,scrollSetting={"":!0,up:!0};function findScrollSetting(t){if(typeof t!="string")return!1;var e=scrollSetting[t.toLowerCase()];return e?t.toLowerCase():!1}function isValidPercentValue(t){return typeof t=="number"&&t>=0&&t<=100}function VTTRegion(){var t=100,e=3,n=0,o=100,u=0,l=100,m="";Object.defineProperties(this,{width:{enumerable:!0,get:function(){return t},set:function(y){if(!isValidPercentValue(y))throw new Error("Width must be between 0 and 100.");t=y}},lines:{enumerable:!0,get:function(){return e},set:function(y){if(typeof y!="number")throw new TypeError("Lines must be set to a number.");e=y}},regionAnchorY:{enumerable:!0,get:function(){return o},set:function(y){if(!isValidPercentValue(y))throw new Error("RegionAnchorX must be between 0 and 100.");o=y}},regionAnchorX:{enumerable:!0,get:function(){return n},set:function(y){if(!isValidPercentValue(y))throw new Error("RegionAnchorY must be between 0 and 100.");n=y}},viewportAnchorY:{enumerable:!0,get:function(){return l},set:function(y){if(!isValidPercentValue(y))throw new Error("ViewportAnchorY must be between 0 and 100.");l=y}},viewportAnchorX:{enumerable:!0,get:function(){return u},set:function(y){if(!isValidPercentValue(y))throw new Error("ViewportAnchorX must be between 0 and 100.");u=y}},scroll:{enumerable:!0,get:function(){return m},set:function(y){var E=findScrollSetting(y);E===!1?console.warn("Scroll: an invalid or illegal string was specified."):m=E}}})}var vttregion=VTTRegion,window$1=window_1,vttjs=browserIndex.exports={WebVTT:vtt$1,VTTCue:vttcue,VTTRegion:vttregion};window$1.vttjs=vttjs,window$1.WebVTT=vttjs.WebVTT;var cueShim=vttjs.VTTCue,regionShim=vttjs.VTTRegion,nativeVTTCue=window$1.VTTCue,nativeVTTRegion=window$1.VTTRegion;vttjs.shim=function(){window$1.VTTCue=cueShim,window$1.VTTRegion=regionShim},vttjs.restore=function(){window$1.VTTCue=nativeVTTCue,window$1.VTTRegion=nativeVTTRegion},window$1.VTTCue||vttjs.shim();var browserIndexExports=browserIndex.exports;const vtt=getDefaultExportFromCjs$1(browserIndexExports);var DEFAULT_LOCATION="https://example.com",resolveUrl$1=function(e,n){if(/^[a-z]+:/i.test(n))return n;/^data:/.test(e)&&(e=window$1$1.location&&window$1$1.location.href||"");var o=/^\/\//.test(e),u=!window$1$1.location&&!/\/\//i.test(e);e=new window$1$1.URL(e,window$1$1.location||DEFAULT_LOCATION);var l=new URL(n,e);return u?l.href.slice(DEFAULT_LOCATION.length):o?l.href.slice(l.protocol.length):l.href},Stream=function(){function t(){this.listeners={}}var e=t.prototype;return e.on=function(o,u){this.listeners[o]||(this.listeners[o]=[]),this.listeners[o].push(u)},e.off=function(o,u){if(!this.listeners[o])return!1;var l=this.listeners[o].indexOf(u);return this.listeners[o]=this.listeners[o].slice(0),this.listeners[o].splice(l,1),l>-1},e.trigger=function(o){var u=this.listeners[o];if(u)if(arguments.length===2)for(var l=u.length,m=0;m<l;++m)u[m].call(this,arguments[1]);else for(var y=Array.prototype.slice.call(arguments,1),E=u.length,C=0;C<E;++C)u[C].apply(this,y)},e.dispose=function(){this.listeners={}},e.pipe=function(o){this.on("data",function(u){o.push(u)})},t}(),buffer$1={},base64Js={};base64Js.byteLength=byteLength,base64Js.toByteArray=toByteArray,base64Js.fromByteArray=fromByteArray;for(var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;revLookup[45]=62,revLookup[95]=63;function getLens(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=t.indexOf("=");n===-1&&(n=e);var o=n===e?0:4-n%4;return[n,o]}function byteLength(t){var e=getLens(t),n=e[0],o=e[1];return(n+o)*3/4-o}function _byteLength(t,e,n){return(e+n)*3/4-n}function toByteArray(t){var e,n=getLens(t),o=n[0],u=n[1],l=new Arr(_byteLength(t,o,u)),m=0,y=u>0?o-4:o,E;for(E=0;E<y;E+=4)e=revLookup[t.charCodeAt(E)]<<18|revLookup[t.charCodeAt(E+1)]<<12|revLookup[t.charCodeAt(E+2)]<<6|revLookup[t.charCodeAt(E+3)],l[m++]=e>>16&255,l[m++]=e>>8&255,l[m++]=e&255;return u===2&&(e=revLookup[t.charCodeAt(E)]<<2|revLookup[t.charCodeAt(E+1)]>>4,l[m++]=e&255),u===1&&(e=revLookup[t.charCodeAt(E)]<<10|revLookup[t.charCodeAt(E+1)]<<4|revLookup[t.charCodeAt(E+2)]>>2,l[m++]=e>>8&255,l[m++]=e&255),l}function tripletToBase64(t){return lookup[t>>18&63]+lookup[t>>12&63]+lookup[t>>6&63]+lookup[t&63]}function encodeChunk(t,e,n){for(var o,u=[],l=e;l<n;l+=3)o=(t[l]<<16&16711680)+(t[l+1]<<8&65280)+(t[l+2]&255),u.push(tripletToBase64(o));return u.join("")}function fromByteArray(t){for(var e,n=t.length,o=n%3,u=[],l=16383,m=0,y=n-o;m<y;m+=l)u.push(encodeChunk(t,m,m+l>y?y:m+l));return o===1?(e=t[n-1],u.push(lookup[e>>2]+lookup[e<<4&63]+"==")):o===2&&(e=(t[n-2]<<8)+t[n-1],u.push(lookup[e>>10]+lookup[e>>4&63]+lookup[e<<2&63]+"=")),u.join("")}var ieee754={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */ieee754.read=function(t,e,n,o,u){var l,m,y=u*8-o-1,E=(1<<y)-1,C=E>>1,k=-7,A=n?u-1:0,D=n?-1:1,P=t[e+A];for(A+=D,l=P&(1<<-k)-1,P>>=-k,k+=y;k>0;l=l*256+t[e+A],A+=D,k-=8);for(m=l&(1<<-k)-1,l>>=-k,k+=o;k>0;m=m*256+t[e+A],A+=D,k-=8);if(l===0)l=1-C;else{if(l===E)return m?NaN:(P?-1:1)*(1/0);m=m+Math.pow(2,o),l=l-C}return(P?-1:1)*m*Math.pow(2,l-o)},ieee754.write=function(t,e,n,o,u,l){var m,y,E,C=l*8-u-1,k=(1<<C)-1,A=k>>1,D=u===23?Math.pow(2,-24)-Math.pow(2,-77):0,P=o?0:l-1,R=o?1:-1,B=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(y=isNaN(e)?1:0,m=k):(m=Math.floor(Math.log(e)/Math.LN2),e*(E=Math.pow(2,-m))<1&&(m--,E*=2),m+A>=1?e+=D/E:e+=D*Math.pow(2,1-A),e*E>=2&&(m++,E/=2),m+A>=k?(y=0,m=k):m+A>=1?(y=(e*E-1)*Math.pow(2,u),m=m+A):(y=e*Math.pow(2,A-1)*Math.pow(2,u),m=0));u>=8;t[n+P]=y&255,P+=R,y/=256,u-=8);for(m=m<<u|y,C+=u;C>0;t[n+P]=m&255,P+=R,m/=256,C-=8);t[n+P-R]|=B*128};/*!
 * The buffer module from node.js, for the browser.
 *
 * @author   Feross Aboukhadijeh <https://feross.org>
 * @license  MIT
 */(function(t){const e=base64Js,n=ieee754,o=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=k,t.SlowBuffer=ie,t.INSPECT_MAX_BYTES=50;const u=2147483647;t.kMaxLength=u;const{Uint8Array:l,ArrayBuffer:m,SharedArrayBuffer:y}=globalThis;k.TYPED_ARRAY_SUPPORT=E(),!k.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function E(){try{const Ce=new l(1),te={foo:function(){return 42}};return Object.setPrototypeOf(te,l.prototype),Object.setPrototypeOf(Ce,te),Ce.foo()===42}catch{return!1}}Object.defineProperty(k.prototype,"parent",{enumerable:!0,get:function(){if(k.isBuffer(this))return this.buffer}}),Object.defineProperty(k.prototype,"offset",{enumerable:!0,get:function(){if(k.isBuffer(this))return this.byteOffset}});function C(Ce){if(Ce>u)throw new RangeError('The value "'+Ce+'" is invalid for option "size"');const te=new l(Ce);return Object.setPrototypeOf(te,k.prototype),te}function k(Ce,te,ye){if(typeof Ce=="number"){if(typeof te=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return R(Ce)}return A(Ce,te,ye)}k.poolSize=8192;function A(Ce,te,ye){if(typeof Ce=="string")return B(Ce,te);if(m.isView(Ce))return j(Ce);if(Ce==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof Ce);if(We(Ce,m)||Ce&&We(Ce.buffer,m)||typeof y<"u"&&(We(Ce,y)||Ce&&We(Ce.buffer,y)))return N(Ce,te,ye);if(typeof Ce=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const Le=Ce.valueOf&&Ce.valueOf();if(Le!=null&&Le!==Ce)return k.from(Le,te,ye);const Ue=Y(Ce);if(Ue)return Ue;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof Ce[Symbol.toPrimitive]=="function")return k.from(Ce[Symbol.toPrimitive]("string"),te,ye);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof Ce)}k.from=function(Ce,te,ye){return A(Ce,te,ye)},Object.setPrototypeOf(k.prototype,l.prototype),Object.setPrototypeOf(k,l);function D(Ce){if(typeof Ce!="number")throw new TypeError('"size" argument must be of type number');if(Ce<0)throw new RangeError('The value "'+Ce+'" is invalid for option "size"')}function P(Ce,te,ye){return D(Ce),Ce<=0?C(Ce):te!==void 0?typeof ye=="string"?C(Ce).fill(te,ye):C(Ce).fill(te):C(Ce)}k.alloc=function(Ce,te,ye){return P(Ce,te,ye)};function R(Ce){return D(Ce),C(Ce<0?0:J(Ce)|0)}k.allocUnsafe=function(Ce){return R(Ce)},k.allocUnsafeSlow=function(Ce){return R(Ce)};function B(Ce,te){if((typeof te!="string"||te==="")&&(te="utf8"),!k.isEncoding(te))throw new TypeError("Unknown encoding: "+te);const ye=ue(Ce,te)|0;let Le=C(ye);const Ue=Le.write(Ce,te);return Ue!==ye&&(Le=Le.slice(0,Ue)),Le}function F(Ce){const te=Ce.length<0?0:J(Ce.length)|0,ye=C(te);for(let Le=0;Le<te;Le+=1)ye[Le]=Ce[Le]&255;return ye}function j(Ce){if(We(Ce,l)){const te=new l(Ce);return N(te.buffer,te.byteOffset,te.byteLength)}return F(Ce)}function N(Ce,te,ye){if(te<0||Ce.byteLength<te)throw new RangeError('"offset" is outside of buffer bounds');if(Ce.byteLength<te+(ye||0))throw new RangeError('"length" is outside of buffer bounds');let Le;return te===void 0&&ye===void 0?Le=new l(Ce):ye===void 0?Le=new l(Ce,te):Le=new l(Ce,te,ye),Object.setPrototypeOf(Le,k.prototype),Le}function Y(Ce){if(k.isBuffer(Ce)){const te=J(Ce.length)|0,ye=C(te);return ye.length===0||Ce.copy(ye,0,0,te),ye}if(Ce.length!==void 0)return typeof Ce.length!="number"||Gt(Ce.length)?C(0):F(Ce);if(Ce.type==="Buffer"&&Array.isArray(Ce.data))return F(Ce.data)}function J(Ce){if(Ce>=u)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+u.toString(16)+" bytes");return Ce|0}function ie(Ce){return+Ce!=Ce&&(Ce=0),k.alloc(+Ce)}k.isBuffer=function(te){return te!=null&&te._isBuffer===!0&&te!==k.prototype},k.compare=function(te,ye){if(We(te,l)&&(te=k.from(te,te.offset,te.byteLength)),We(ye,l)&&(ye=k.from(ye,ye.offset,ye.byteLength)),!k.isBuffer(te)||!k.isBuffer(ye))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(te===ye)return 0;let Le=te.length,Ue=ye.length;for(let Qe=0,Ke=Math.min(Le,Ue);Qe<Ke;++Qe)if(te[Qe]!==ye[Qe]){Le=te[Qe],Ue=ye[Qe];break}return Le<Ue?-1:Ue<Le?1:0},k.isEncoding=function(te){switch(String(te).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},k.concat=function(te,ye){if(!Array.isArray(te))throw new TypeError('"list" argument must be an Array of Buffers');if(te.length===0)return k.alloc(0);let Le;if(ye===void 0)for(ye=0,Le=0;Le<te.length;++Le)ye+=te[Le].length;const Ue=k.allocUnsafe(ye);let Qe=0;for(Le=0;Le<te.length;++Le){let Ke=te[Le];if(We(Ke,l))Qe+Ke.length>Ue.length?(k.isBuffer(Ke)||(Ke=k.from(Ke)),Ke.copy(Ue,Qe)):l.prototype.set.call(Ue,Ke,Qe);else if(k.isBuffer(Ke))Ke.copy(Ue,Qe);else throw new TypeError('"list" argument must be an Array of Buffers');Qe+=Ke.length}return Ue};function ue(Ce,te){if(k.isBuffer(Ce))return Ce.length;if(m.isView(Ce)||We(Ce,m))return Ce.byteLength;if(typeof Ce!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof Ce);const ye=Ce.length,Le=arguments.length>2&&arguments[2]===!0;if(!Le&&ye===0)return 0;let Ue=!1;for(;;)switch(te){case"ascii":case"latin1":case"binary":return ye;case"utf8":case"utf-8":return tt(Ce).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ye*2;case"hex":return ye>>>1;case"base64":return Ot(Ce).length;default:if(Ue)return Le?-1:tt(Ce).length;te=(""+te).toLowerCase(),Ue=!0}}k.byteLength=ue;function Q(Ce,te,ye){let Le=!1;if((te===void 0||te<0)&&(te=0),te>this.length||((ye===void 0||ye>this.length)&&(ye=this.length),ye<=0)||(ye>>>=0,te>>>=0,ye<=te))return"";for(Ce||(Ce="utf8");;)switch(Ce){case"hex":return M(this,te,ye);case"utf8":case"utf-8":return x(this,te,ye);case"ascii":return h(this,te,ye);case"latin1":case"binary":return T(this,te,ye);case"base64":return p(this,te,ye);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,te,ye);default:if(Le)throw new TypeError("Unknown encoding: "+Ce);Ce=(Ce+"").toLowerCase(),Le=!0}}k.prototype._isBuffer=!0;function ce(Ce,te,ye){const Le=Ce[te];Ce[te]=Ce[ye],Ce[ye]=Le}k.prototype.swap16=function(){const te=this.length;if(te%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let ye=0;ye<te;ye+=2)ce(this,ye,ye+1);return this},k.prototype.swap32=function(){const te=this.length;if(te%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let ye=0;ye<te;ye+=4)ce(this,ye,ye+3),ce(this,ye+1,ye+2);return this},k.prototype.swap64=function(){const te=this.length;if(te%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let ye=0;ye<te;ye+=8)ce(this,ye,ye+7),ce(this,ye+1,ye+6),ce(this,ye+2,ye+5),ce(this,ye+3,ye+4);return this},k.prototype.toString=function(){const te=this.length;return te===0?"":arguments.length===0?x(this,0,te):Q.apply(this,arguments)},k.prototype.toLocaleString=k.prototype.toString,k.prototype.equals=function(te){if(!k.isBuffer(te))throw new TypeError("Argument must be a Buffer");return this===te?!0:k.compare(this,te)===0},k.prototype.inspect=function(){let te="";const ye=t.INSPECT_MAX_BYTES;return te=this.toString("hex",0,ye).replace(/(.{2})/g,"$1 ").trim(),this.length>ye&&(te+=" ... "),"<Buffer "+te+">"},o&&(k.prototype[o]=k.prototype.inspect),k.prototype.compare=function(te,ye,Le,Ue,Qe){if(We(te,l)&&(te=k.from(te,te.offset,te.byteLength)),!k.isBuffer(te))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof te);if(ye===void 0&&(ye=0),Le===void 0&&(Le=te?te.length:0),Ue===void 0&&(Ue=0),Qe===void 0&&(Qe=this.length),ye<0||Le>te.length||Ue<0||Qe>this.length)throw new RangeError("out of range index");if(Ue>=Qe&&ye>=Le)return 0;if(Ue>=Qe)return-1;if(ye>=Le)return 1;if(ye>>>=0,Le>>>=0,Ue>>>=0,Qe>>>=0,this===te)return 0;let Ke=Qe-Ue,De=Le-ye;const Vt=Math.min(Ke,De),At=this.slice(Ue,Qe),ve=te.slice(ye,Le);for(let Pt=0;Pt<Vt;++Pt)if(At[Pt]!==ve[Pt]){Ke=At[Pt],De=ve[Pt];break}return Ke<De?-1:De<Ke?1:0};function he(Ce,te,ye,Le,Ue){if(Ce.length===0)return-1;if(typeof ye=="string"?(Le=ye,ye=0):ye>2147483647?ye=2147483647:ye<-2147483648&&(ye=-2147483648),ye=+ye,Gt(ye)&&(ye=Ue?0:Ce.length-1),ye<0&&(ye=Ce.length+ye),ye>=Ce.length){if(Ue)return-1;ye=Ce.length-1}else if(ye<0)if(Ue)ye=0;else return-1;if(typeof te=="string"&&(te=k.from(te,Le)),k.isBuffer(te))return te.length===0?-1:ke(Ce,te,ye,Le,Ue);if(typeof te=="number")return te=te&255,typeof l.prototype.indexOf=="function"?Ue?l.prototype.indexOf.call(Ce,te,ye):l.prototype.lastIndexOf.call(Ce,te,ye):ke(Ce,[te],ye,Le,Ue);throw new TypeError("val must be string, number or Buffer")}function ke(Ce,te,ye,Le,Ue){let Qe=1,Ke=Ce.length,De=te.length;if(Le!==void 0&&(Le=String(Le).toLowerCase(),Le==="ucs2"||Le==="ucs-2"||Le==="utf16le"||Le==="utf-16le")){if(Ce.length<2||te.length<2)return-1;Qe=2,Ke/=2,De/=2,ye/=2}function Vt(ve,Pt){return Qe===1?ve[Pt]:ve.readUInt16BE(Pt*Qe)}let At;if(Ue){let ve=-1;for(At=ye;At<Ke;At++)if(Vt(Ce,At)===Vt(te,ve===-1?0:At-ve)){if(ve===-1&&(ve=At),At-ve+1===De)return ve*Qe}else ve!==-1&&(At-=At-ve),ve=-1}else for(ye+De>Ke&&(ye=Ke-De),At=ye;At>=0;At--){let ve=!0;for(let Pt=0;Pt<De;Pt++)if(Vt(Ce,At+Pt)!==Vt(te,Pt)){ve=!1;break}if(ve)return At}return-1}k.prototype.includes=function(te,ye,Le){return this.indexOf(te,ye,Le)!==-1},k.prototype.indexOf=function(te,ye,Le){return he(this,te,ye,Le,!0)},k.prototype.lastIndexOf=function(te,ye,Le){return he(this,te,ye,Le,!1)};function L(Ce,te,ye,Le){ye=Number(ye)||0;const Ue=Ce.length-ye;Le?(Le=Number(Le),Le>Ue&&(Le=Ue)):Le=Ue;const Qe=te.length;Le>Qe/2&&(Le=Qe/2);let Ke;for(Ke=0;Ke<Le;++Ke){const De=parseInt(te.substr(Ke*2,2),16);if(Gt(De))return Ke;Ce[ye+Ke]=De}return Ke}function d(Ce,te,ye,Le){return Ve(tt(te,Ce.length-ye),Ce,ye,Le)}function v(Ce,te,ye,Le){return Ve(rt(te),Ce,ye,Le)}function w(Ce,te,ye,Le){return Ve(Ot(te),Ce,ye,Le)}function c(Ce,te,ye,Le){return Ve(ht(te,Ce.length-ye),Ce,ye,Le)}k.prototype.write=function(te,ye,Le,Ue){if(ye===void 0)Ue="utf8",Le=this.length,ye=0;else if(Le===void 0&&typeof ye=="string")Ue=ye,Le=this.length,ye=0;else if(isFinite(ye))ye=ye>>>0,isFinite(Le)?(Le=Le>>>0,Ue===void 0&&(Ue="utf8")):(Ue=Le,Le=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const Qe=this.length-ye;if((Le===void 0||Le>Qe)&&(Le=Qe),te.length>0&&(Le<0||ye<0)||ye>this.length)throw new RangeError("Attempt to write outside buffer bounds");Ue||(Ue="utf8");let Ke=!1;for(;;)switch(Ue){case"hex":return L(this,te,ye,Le);case"utf8":case"utf-8":return d(this,te,ye,Le);case"ascii":case"latin1":case"binary":return v(this,te,ye,Le);case"base64":return w(this,te,ye,Le);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return c(this,te,ye,Le);default:if(Ke)throw new TypeError("Unknown encoding: "+Ue);Ue=(""+Ue).toLowerCase(),Ke=!0}},k.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function p(Ce,te,ye){return te===0&&ye===Ce.length?e.fromByteArray(Ce):e.fromByteArray(Ce.slice(te,ye))}function x(Ce,te,ye){ye=Math.min(Ce.length,ye);const Le=[];let Ue=te;for(;Ue<ye;){const Qe=Ce[Ue];let Ke=null,De=Qe>239?4:Qe>223?3:Qe>191?2:1;if(Ue+De<=ye){let Vt,At,ve,Pt;switch(De){case 1:Qe<128&&(Ke=Qe);break;case 2:Vt=Ce[Ue+1],(Vt&192)===128&&(Pt=(Qe&31)<<6|Vt&63,Pt>127&&(Ke=Pt));break;case 3:Vt=Ce[Ue+1],At=Ce[Ue+2],(Vt&192)===128&&(At&192)===128&&(Pt=(Qe&15)<<12|(Vt&63)<<6|At&63,Pt>2047&&(Pt<55296||Pt>57343)&&(Ke=Pt));break;case 4:Vt=Ce[Ue+1],At=Ce[Ue+2],ve=Ce[Ue+3],(Vt&192)===128&&(At&192)===128&&(ve&192)===128&&(Pt=(Qe&15)<<18|(Vt&63)<<12|(At&63)<<6|ve&63,Pt>65535&&Pt<1114112&&(Ke=Pt))}}Ke===null?(Ke=65533,De=1):Ke>65535&&(Ke-=65536,Le.push(Ke>>>10&1023|55296),Ke=56320|Ke&1023),Le.push(Ke),Ue+=De}return b(Le)}const S=4096;function b(Ce){const te=Ce.length;if(te<=S)return String.fromCharCode.apply(String,Ce);let ye="",Le=0;for(;Le<te;)ye+=String.fromCharCode.apply(String,Ce.slice(Le,Le+=S));return ye}function h(Ce,te,ye){let Le="";ye=Math.min(Ce.length,ye);for(let Ue=te;Ue<ye;++Ue)Le+=String.fromCharCode(Ce[Ue]&127);return Le}function T(Ce,te,ye){let Le="";ye=Math.min(Ce.length,ye);for(let Ue=te;Ue<ye;++Ue)Le+=String.fromCharCode(Ce[Ue]);return Le}function M(Ce,te,ye){const Le=Ce.length;(!te||te<0)&&(te=0),(!ye||ye<0||ye>Le)&&(ye=Le);let Ue="";for(let Qe=te;Qe<ye;++Qe)Ue+=wt[Ce[Qe]];return Ue}function O(Ce,te,ye){const Le=Ce.slice(te,ye);let Ue="";for(let Qe=0;Qe<Le.length-1;Qe+=2)Ue+=String.fromCharCode(Le[Qe]+Le[Qe+1]*256);return Ue}k.prototype.slice=function(te,ye){const Le=this.length;te=~~te,ye=ye===void 0?Le:~~ye,te<0?(te+=Le,te<0&&(te=0)):te>Le&&(te=Le),ye<0?(ye+=Le,ye<0&&(ye=0)):ye>Le&&(ye=Le),ye<te&&(ye=te);const Ue=this.subarray(te,ye);return Object.setPrototypeOf(Ue,k.prototype),Ue};function V(Ce,te,ye){if(Ce%1!==0||Ce<0)throw new RangeError("offset is not uint");if(Ce+te>ye)throw new RangeError("Trying to access beyond buffer length")}k.prototype.readUintLE=k.prototype.readUIntLE=function(te,ye,Le){te=te>>>0,ye=ye>>>0,Le||V(te,ye,this.length);let Ue=this[te],Qe=1,Ke=0;for(;++Ke<ye&&(Qe*=256);)Ue+=this[te+Ke]*Qe;return Ue},k.prototype.readUintBE=k.prototype.readUIntBE=function(te,ye,Le){te=te>>>0,ye=ye>>>0,Le||V(te,ye,this.length);let Ue=this[te+--ye],Qe=1;for(;ye>0&&(Qe*=256);)Ue+=this[te+--ye]*Qe;return Ue},k.prototype.readUint8=k.prototype.readUInt8=function(te,ye){return te=te>>>0,ye||V(te,1,this.length),this[te]},k.prototype.readUint16LE=k.prototype.readUInt16LE=function(te,ye){return te=te>>>0,ye||V(te,2,this.length),this[te]|this[te+1]<<8},k.prototype.readUint16BE=k.prototype.readUInt16BE=function(te,ye){return te=te>>>0,ye||V(te,2,this.length),this[te]<<8|this[te+1]},k.prototype.readUint32LE=k.prototype.readUInt32LE=function(te,ye){return te=te>>>0,ye||V(te,4,this.length),(this[te]|this[te+1]<<8|this[te+2]<<16)+this[te+3]*16777216},k.prototype.readUint32BE=k.prototype.readUInt32BE=function(te,ye){return te=te>>>0,ye||V(te,4,this.length),this[te]*16777216+(this[te+1]<<16|this[te+2]<<8|this[te+3])},k.prototype.readBigUInt64LE=Et(function(te){te=te>>>0,ot(te,"offset");const ye=this[te],Le=this[te+7];(ye===void 0||Le===void 0)&&Ct(te,this.length-8);const Ue=ye+this[++te]*2**8+this[++te]*2**16+this[++te]*2**24,Qe=this[++te]+this[++te]*2**8+this[++te]*2**16+Le*2**24;return BigInt(Ue)+(BigInt(Qe)<<BigInt(32))}),k.prototype.readBigUInt64BE=Et(function(te){te=te>>>0,ot(te,"offset");const ye=this[te],Le=this[te+7];(ye===void 0||Le===void 0)&&Ct(te,this.length-8);const Ue=ye*2**24+this[++te]*2**16+this[++te]*2**8+this[++te],Qe=this[++te]*2**24+this[++te]*2**16+this[++te]*2**8+Le;return(BigInt(Ue)<<BigInt(32))+BigInt(Qe)}),k.prototype.readIntLE=function(te,ye,Le){te=te>>>0,ye=ye>>>0,Le||V(te,ye,this.length);let Ue=this[te],Qe=1,Ke=0;for(;++Ke<ye&&(Qe*=256);)Ue+=this[te+Ke]*Qe;return Qe*=128,Ue>=Qe&&(Ue-=Math.pow(2,8*ye)),Ue},k.prototype.readIntBE=function(te,ye,Le){te=te>>>0,ye=ye>>>0,Le||V(te,ye,this.length);let Ue=ye,Qe=1,Ke=this[te+--Ue];for(;Ue>0&&(Qe*=256);)Ke+=this[te+--Ue]*Qe;return Qe*=128,Ke>=Qe&&(Ke-=Math.pow(2,8*ye)),Ke},k.prototype.readInt8=function(te,ye){return te=te>>>0,ye||V(te,1,this.length),this[te]&128?(255-this[te]+1)*-1:this[te]},k.prototype.readInt16LE=function(te,ye){te=te>>>0,ye||V(te,2,this.length);const Le=this[te]|this[te+1]<<8;return Le&32768?Le|4294901760:Le},k.prototype.readInt16BE=function(te,ye){te=te>>>0,ye||V(te,2,this.length);const Le=this[te+1]|this[te]<<8;return Le&32768?Le|4294901760:Le},k.prototype.readInt32LE=function(te,ye){return te=te>>>0,ye||V(te,4,this.length),this[te]|this[te+1]<<8|this[te+2]<<16|this[te+3]<<24},k.prototype.readInt32BE=function(te,ye){return te=te>>>0,ye||V(te,4,this.length),this[te]<<24|this[te+1]<<16|this[te+2]<<8|this[te+3]},k.prototype.readBigInt64LE=Et(function(te){te=te>>>0,ot(te,"offset");const ye=this[te],Le=this[te+7];(ye===void 0||Le===void 0)&&Ct(te,this.length-8);const Ue=this[te+4]+this[te+5]*2**8+this[te+6]*2**16+(Le<<24);return(BigInt(Ue)<<BigInt(32))+BigInt(ye+this[++te]*2**8+this[++te]*2**16+this[++te]*2**24)}),k.prototype.readBigInt64BE=Et(function(te){te=te>>>0,ot(te,"offset");const ye=this[te],Le=this[te+7];(ye===void 0||Le===void 0)&&Ct(te,this.length-8);const Ue=(ye<<24)+this[++te]*2**16+this[++te]*2**8+this[++te];return(BigInt(Ue)<<BigInt(32))+BigInt(this[++te]*2**24+this[++te]*2**16+this[++te]*2**8+Le)}),k.prototype.readFloatLE=function(te,ye){return te=te>>>0,ye||V(te,4,this.length),n.read(this,te,!0,23,4)},k.prototype.readFloatBE=function(te,ye){return te=te>>>0,ye||V(te,4,this.length),n.read(this,te,!1,23,4)},k.prototype.readDoubleLE=function(te,ye){return te=te>>>0,ye||V(te,8,this.length),n.read(this,te,!0,52,8)},k.prototype.readDoubleBE=function(te,ye){return te=te>>>0,ye||V(te,8,this.length),n.read(this,te,!1,52,8)};function ee(Ce,te,ye,Le,Ue,Qe){if(!k.isBuffer(Ce))throw new TypeError('"buffer" argument must be a Buffer instance');if(te>Ue||te<Qe)throw new RangeError('"value" argument is out of bounds');if(ye+Le>Ce.length)throw new RangeError("Index out of range")}k.prototype.writeUintLE=k.prototype.writeUIntLE=function(te,ye,Le,Ue){if(te=+te,ye=ye>>>0,Le=Le>>>0,!Ue){const De=Math.pow(2,8*Le)-1;ee(this,te,ye,Le,De,0)}let Qe=1,Ke=0;for(this[ye]=te&255;++Ke<Le&&(Qe*=256);)this[ye+Ke]=te/Qe&255;return ye+Le},k.prototype.writeUintBE=k.prototype.writeUIntBE=function(te,ye,Le,Ue){if(te=+te,ye=ye>>>0,Le=Le>>>0,!Ue){const De=Math.pow(2,8*Le)-1;ee(this,te,ye,Le,De,0)}let Qe=Le-1,Ke=1;for(this[ye+Qe]=te&255;--Qe>=0&&(Ke*=256);)this[ye+Qe]=te/Ke&255;return ye+Le},k.prototype.writeUint8=k.prototype.writeUInt8=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,1,255,0),this[ye]=te&255,ye+1},k.prototype.writeUint16LE=k.prototype.writeUInt16LE=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,2,65535,0),this[ye]=te&255,this[ye+1]=te>>>8,ye+2},k.prototype.writeUint16BE=k.prototype.writeUInt16BE=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,2,65535,0),this[ye]=te>>>8,this[ye+1]=te&255,ye+2},k.prototype.writeUint32LE=k.prototype.writeUInt32LE=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,4,4294967295,0),this[ye+3]=te>>>24,this[ye+2]=te>>>16,this[ye+1]=te>>>8,this[ye]=te&255,ye+4},k.prototype.writeUint32BE=k.prototype.writeUInt32BE=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,4,4294967295,0),this[ye]=te>>>24,this[ye+1]=te>>>16,this[ye+2]=te>>>8,this[ye+3]=te&255,ye+4};function Z(Ce,te,ye,Le,Ue){it(te,Le,Ue,Ce,ye,7);let Qe=Number(te&BigInt(4294967295));Ce[ye++]=Qe,Qe=Qe>>8,Ce[ye++]=Qe,Qe=Qe>>8,Ce[ye++]=Qe,Qe=Qe>>8,Ce[ye++]=Qe;let Ke=Number(te>>BigInt(32)&BigInt(4294967295));return Ce[ye++]=Ke,Ke=Ke>>8,Ce[ye++]=Ke,Ke=Ke>>8,Ce[ye++]=Ke,Ke=Ke>>8,Ce[ye++]=Ke,ye}function U(Ce,te,ye,Le,Ue){it(te,Le,Ue,Ce,ye,7);let Qe=Number(te&BigInt(4294967295));Ce[ye+7]=Qe,Qe=Qe>>8,Ce[ye+6]=Qe,Qe=Qe>>8,Ce[ye+5]=Qe,Qe=Qe>>8,Ce[ye+4]=Qe;let Ke=Number(te>>BigInt(32)&BigInt(4294967295));return Ce[ye+3]=Ke,Ke=Ke>>8,Ce[ye+2]=Ke,Ke=Ke>>8,Ce[ye+1]=Ke,Ke=Ke>>8,Ce[ye]=Ke,ye+8}k.prototype.writeBigUInt64LE=Et(function(te,ye=0){return Z(this,te,ye,BigInt(0),BigInt("0xffffffffffffffff"))}),k.prototype.writeBigUInt64BE=Et(function(te,ye=0){return U(this,te,ye,BigInt(0),BigInt("0xffffffffffffffff"))}),k.prototype.writeIntLE=function(te,ye,Le,Ue){if(te=+te,ye=ye>>>0,!Ue){const Vt=Math.pow(2,8*Le-1);ee(this,te,ye,Le,Vt-1,-Vt)}let Qe=0,Ke=1,De=0;for(this[ye]=te&255;++Qe<Le&&(Ke*=256);)te<0&&De===0&&this[ye+Qe-1]!==0&&(De=1),this[ye+Qe]=(te/Ke>>0)-De&255;return ye+Le},k.prototype.writeIntBE=function(te,ye,Le,Ue){if(te=+te,ye=ye>>>0,!Ue){const Vt=Math.pow(2,8*Le-1);ee(this,te,ye,Le,Vt-1,-Vt)}let Qe=Le-1,Ke=1,De=0;for(this[ye+Qe]=te&255;--Qe>=0&&(Ke*=256);)te<0&&De===0&&this[ye+Qe+1]!==0&&(De=1),this[ye+Qe]=(te/Ke>>0)-De&255;return ye+Le},k.prototype.writeInt8=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,1,127,-128),te<0&&(te=255+te+1),this[ye]=te&255,ye+1},k.prototype.writeInt16LE=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,2,32767,-32768),this[ye]=te&255,this[ye+1]=te>>>8,ye+2},k.prototype.writeInt16BE=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,2,32767,-32768),this[ye]=te>>>8,this[ye+1]=te&255,ye+2},k.prototype.writeInt32LE=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,4,2147483647,-2147483648),this[ye]=te&255,this[ye+1]=te>>>8,this[ye+2]=te>>>16,this[ye+3]=te>>>24,ye+4},k.prototype.writeInt32BE=function(te,ye,Le){return te=+te,ye=ye>>>0,Le||ee(this,te,ye,4,2147483647,-2147483648),te<0&&(te=4294967295+te+1),this[ye]=te>>>24,this[ye+1]=te>>>16,this[ye+2]=te>>>8,this[ye+3]=te&255,ye+4},k.prototype.writeBigInt64LE=Et(function(te,ye=0){return Z(this,te,ye,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),k.prototype.writeBigInt64BE=Et(function(te,ye=0){return U(this,te,ye,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function z(Ce,te,ye,Le,Ue,Qe){if(ye+Le>Ce.length)throw new RangeError("Index out of range");if(ye<0)throw new RangeError("Index out of range")}function ne(Ce,te,ye,Le,Ue){return te=+te,ye=ye>>>0,Ue||z(Ce,te,ye,4),n.write(Ce,te,ye,Le,23,4),ye+4}k.prototype.writeFloatLE=function(te,ye,Le){return ne(this,te,ye,!0,Le)},k.prototype.writeFloatBE=function(te,ye,Le){return ne(this,te,ye,!1,Le)};function fe(Ce,te,ye,Le,Ue){return te=+te,ye=ye>>>0,Ue||z(Ce,te,ye,8),n.write(Ce,te,ye,Le,52,8),ye+8}k.prototype.writeDoubleLE=function(te,ye,Le){return fe(this,te,ye,!0,Le)},k.prototype.writeDoubleBE=function(te,ye,Le){return fe(this,te,ye,!1,Le)},k.prototype.copy=function(te,ye,Le,Ue){if(!k.isBuffer(te))throw new TypeError("argument should be a Buffer");if(Le||(Le=0),!Ue&&Ue!==0&&(Ue=this.length),ye>=te.length&&(ye=te.length),ye||(ye=0),Ue>0&&Ue<Le&&(Ue=Le),Ue===Le||te.length===0||this.length===0)return 0;if(ye<0)throw new RangeError("targetStart out of bounds");if(Le<0||Le>=this.length)throw new RangeError("Index out of range");if(Ue<0)throw new RangeError("sourceEnd out of bounds");Ue>this.length&&(Ue=this.length),te.length-ye<Ue-Le&&(Ue=te.length-ye+Le);const Qe=Ue-Le;return this===te&&typeof l.prototype.copyWithin=="function"?this.copyWithin(ye,Le,Ue):l.prototype.set.call(te,this.subarray(Le,Ue),ye),Qe},k.prototype.fill=function(te,ye,Le,Ue){if(typeof te=="string"){if(typeof ye=="string"?(Ue=ye,ye=0,Le=this.length):typeof Le=="string"&&(Ue=Le,Le=this.length),Ue!==void 0&&typeof Ue!="string")throw new TypeError("encoding must be a string");if(typeof Ue=="string"&&!k.isEncoding(Ue))throw new TypeError("Unknown encoding: "+Ue);if(te.length===1){const Ke=te.charCodeAt(0);(Ue==="utf8"&&Ke<128||Ue==="latin1")&&(te=Ke)}}else typeof te=="number"?te=te&255:typeof te=="boolean"&&(te=Number(te));if(ye<0||this.length<ye||this.length<Le)throw new RangeError("Out of range index");if(Le<=ye)return this;ye=ye>>>0,Le=Le===void 0?this.length:Le>>>0,te||(te=0);let Qe;if(typeof te=="number")for(Qe=ye;Qe<Le;++Qe)this[Qe]=te;else{const Ke=k.isBuffer(te)?te:k.from(te,Ue),De=Ke.length;if(De===0)throw new TypeError('The value "'+te+'" is invalid for argument "value"');for(Qe=0;Qe<Le-ye;++Qe)this[Qe+ye]=Ke[Qe%De]}return this};const me={};function de(Ce,te,ye){me[Ce]=class extends ye{constructor(){super(),Object.defineProperty(this,"message",{value:te.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${Ce}]`,this.stack,delete this.name}get code(){return Ce}set code(Ue){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:Ue,writable:!0})}toString(){return`${this.name} [${Ce}]: ${this.message}`}}}de("ERR_BUFFER_OUT_OF_BOUNDS",function(Ce){return Ce?`${Ce} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),de("ERR_INVALID_ARG_TYPE",function(Ce,te){return`The "${Ce}" argument must be of type number. Received type ${typeof te}`},TypeError),de("ERR_OUT_OF_RANGE",function(Ce,te,ye){let Le=`The value of "${Ce}" is out of range.`,Ue=ye;return Number.isInteger(ye)&&Math.abs(ye)>2**32?Ue=je(String(ye)):typeof ye=="bigint"&&(Ue=String(ye),(ye>BigInt(2)**BigInt(32)||ye<-(BigInt(2)**BigInt(32)))&&(Ue=je(Ue)),Ue+="n"),Le+=` It must be ${te}. Received ${Ue}`,Le},RangeError);function je(Ce){let te="",ye=Ce.length;const Le=Ce[0]==="-"?1:0;for(;ye>=Le+4;ye-=3)te=`_${Ce.slice(ye-3,ye)}${te}`;return`${Ce.slice(0,ye)}${te}`}function lt(Ce,te,ye){ot(te,"offset"),(Ce[te]===void 0||Ce[te+ye]===void 0)&&Ct(te,Ce.length-(ye+1))}function it(Ce,te,ye,Le,Ue,Qe){if(Ce>ye||Ce<te){const Ke=typeof te=="bigint"?"n":"";let De;throw te===0||te===BigInt(0)?De=`>= 0${Ke} and < 2${Ke} ** ${(Qe+1)*8}${Ke}`:De=`>= -(2${Ke} ** ${(Qe+1)*8-1}${Ke}) and < 2 ** ${(Qe+1)*8-1}${Ke}`,new me.ERR_OUT_OF_RANGE("value",De,Ce)}lt(Le,Ue,Qe)}function ot(Ce,te){if(typeof Ce!="number")throw new me.ERR_INVALID_ARG_TYPE(te,"number",Ce)}function Ct(Ce,te,ye){throw Math.floor(Ce)!==Ce?(ot(Ce,ye),new me.ERR_OUT_OF_RANGE("offset","an integer",Ce)):te<0?new me.ERR_BUFFER_OUT_OF_BOUNDS:new me.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${te}`,Ce)}const nt=/[^+/0-9A-Za-z-_]/g;function Je(Ce){if(Ce=Ce.split("=")[0],Ce=Ce.trim().replace(nt,""),Ce.length<2)return"";for(;Ce.length%4!==0;)Ce=Ce+"=";return Ce}function tt(Ce,te){te=te||1/0;let ye;const Le=Ce.length;let Ue=null;const Qe=[];for(let Ke=0;Ke<Le;++Ke){if(ye=Ce.charCodeAt(Ke),ye>55295&&ye<57344){if(!Ue){if(ye>56319){(te-=3)>-1&&Qe.push(239,191,189);continue}else if(Ke+1===Le){(te-=3)>-1&&Qe.push(239,191,189);continue}Ue=ye;continue}if(ye<56320){(te-=3)>-1&&Qe.push(239,191,189),Ue=ye;continue}ye=(Ue-55296<<10|ye-56320)+65536}else Ue&&(te-=3)>-1&&Qe.push(239,191,189);if(Ue=null,ye<128){if((te-=1)<0)break;Qe.push(ye)}else if(ye<2048){if((te-=2)<0)break;Qe.push(ye>>6|192,ye&63|128)}else if(ye<65536){if((te-=3)<0)break;Qe.push(ye>>12|224,ye>>6&63|128,ye&63|128)}else if(ye<1114112){if((te-=4)<0)break;Qe.push(ye>>18|240,ye>>12&63|128,ye>>6&63|128,ye&63|128)}else throw new Error("Invalid code point")}return Qe}function rt(Ce){const te=[];for(let ye=0;ye<Ce.length;++ye)te.push(Ce.charCodeAt(ye)&255);return te}function ht(Ce,te){let ye,Le,Ue;const Qe=[];for(let Ke=0;Ke<Ce.length&&!((te-=2)<0);++Ke)ye=Ce.charCodeAt(Ke),Le=ye>>8,Ue=ye%256,Qe.push(Ue),Qe.push(Le);return Qe}function Ot(Ce){return e.toByteArray(Je(Ce))}function Ve(Ce,te,ye,Le){let Ue;for(Ue=0;Ue<Le&&!(Ue+ye>=te.length||Ue>=Ce.length);++Ue)te[Ue+ye]=Ce[Ue];return Ue}function We(Ce,te){return Ce instanceof te||Ce!=null&&Ce.constructor!=null&&Ce.constructor.name!=null&&Ce.constructor.name===te.name}function Gt(Ce){return Ce!==Ce}const wt=function(){const Ce="0123456789abcdef",te=new Array(256);for(let ye=0;ye<16;++ye){const Le=ye*16;for(let Ue=0;Ue<16;++Ue)te[Le+Ue]=Ce[ye]+Ce[Ue]}return te}();function Et(Ce){return typeof BigInt>"u"?Yt:Ce}function Yt(){throw new Error("BigInt not supported")}})(buffer$1);const Buffer$C=buffer$1.Buffer,Blob$1=buffer$1.Blob,BlobOptions=buffer$1.BlobOptions,Buffer$1$1=buffer$1.Buffer,File=buffer$1.File,FileOptions=buffer$1.FileOptions,INSPECT_MAX_BYTES=buffer$1.INSPECT_MAX_BYTES,SlowBuffer=buffer$1.SlowBuffer,TranscodeEncoding=buffer$1.TranscodeEncoding,atob$1=buffer$1.atob,btoa$1=buffer$1.btoa,constants$2=buffer$1.constants,isAscii=buffer$1.isAscii,isUtf8=buffer$1.isUtf8,kMaxLength=buffer$1.kMaxLength,kStringMaxLength=buffer$1.kStringMaxLength,resolveObjectURL=buffer$1.resolveObjectURL,transcode=buffer$1.transcode,dist=Object.freeze(Object.defineProperty({__proto__:null,Blob:Blob$1,BlobOptions,Buffer:Buffer$1$1,File,FileOptions,INSPECT_MAX_BYTES,SlowBuffer,TranscodeEncoding,atob:atob$1,btoa:btoa$1,constants:constants$2,default:Buffer$C,isAscii,isUtf8,kMaxLength,kStringMaxLength,resolveObjectURL,transcode},Symbol.toStringTag,{value:"Module"}));var atob=function(e){return window$1$1.atob?window$1$1.atob(e):Buffer$C.from(e,"base64").toString("binary")};function decodeB64ToUint8Array(t){for(var e=atob(t),n=new Uint8Array(e.length),o=0;o<e.length;o++)n[o]=e.charCodeAt(o);return n}/*! @name m3u8-parser @version 7.2.0 @license Apache-2.0 */class LineStream extends Stream{constructor(){super(),this.buffer=""}push(e){let n;for(this.buffer+=e,n=this.buffer.indexOf(`
`);n>-1;n=this.buffer.indexOf(`
`))this.trigger("data",this.buffer.substring(0,n)),this.buffer=this.buffer.substring(n+1)}}const TAB="	",parseByterange=function(t){const e=/([0-9.]*)?@?([0-9.]*)?/.exec(t||""),n={};return e[1]&&(n.length=parseInt(e[1],10)),e[2]&&(n.offset=parseInt(e[2],10)),n},attributeSeparator=function(){const n="(?:"+"[^=]*"+")=(?:"+'"[^"]*"|[^,]*'+")";return new RegExp("(?:^|,)("+n+")")},parseAttributes$1=function(t){const e={};if(!t)return e;const n=t.split(attributeSeparator());let o=n.length,u;for(;o--;)n[o]!==""&&(u=/([^=]*)=(.*)/.exec(n[o]).slice(1),u[0]=u[0].replace(/^\s+|\s+$/g,""),u[1]=u[1].replace(/^\s+|\s+$/g,""),u[1]=u[1].replace(/^['"](.*)['"]$/g,"$1"),e[u[0]]=u[1]);return e},parseResolution=t=>{const e=t.split("x"),n={};return e[0]&&(n.width=parseInt(e[0],10)),e[1]&&(n.height=parseInt(e[1],10)),n};class ParseStream extends Stream{constructor(){super(),this.customParsers=[],this.tagMappers=[]}push(e){let n,o;if(e=e.trim(),e.length===0)return;if(e[0]!=="#"){this.trigger("data",{type:"uri",uri:e});return}this.tagMappers.reduce((l,m)=>{const y=m(e);return y===e?l:l.concat([y])},[e]).forEach(l=>{for(let m=0;m<this.customParsers.length;m++)if(this.customParsers[m].call(this,l))return;if(l.indexOf("#EXT")!==0){this.trigger("data",{type:"comment",text:l.slice(1)});return}if(l=l.replace("\r",""),n=/^#EXTM3U/.exec(l),n){this.trigger("data",{type:"tag",tagType:"m3u"});return}if(n=/^#EXTINF:([0-9\.]*)?,?(.*)?$/.exec(l),n){o={type:"tag",tagType:"inf"},n[1]&&(o.duration=parseFloat(n[1])),n[2]&&(o.title=n[2]),this.trigger("data",o);return}if(n=/^#EXT-X-TARGETDURATION:([0-9.]*)?/.exec(l),n){o={type:"tag",tagType:"targetduration"},n[1]&&(o.duration=parseInt(n[1],10)),this.trigger("data",o);return}if(n=/^#EXT-X-VERSION:([0-9.]*)?/.exec(l),n){o={type:"tag",tagType:"version"},n[1]&&(o.version=parseInt(n[1],10)),this.trigger("data",o);return}if(n=/^#EXT-X-MEDIA-SEQUENCE:(\-?[0-9.]*)?/.exec(l),n){o={type:"tag",tagType:"media-sequence"},n[1]&&(o.number=parseInt(n[1],10)),this.trigger("data",o);return}if(n=/^#EXT-X-DISCONTINUITY-SEQUENCE:(\-?[0-9.]*)?/.exec(l),n){o={type:"tag",tagType:"discontinuity-sequence"},n[1]&&(o.number=parseInt(n[1],10)),this.trigger("data",o);return}if(n=/^#EXT-X-PLAYLIST-TYPE:(.*)?$/.exec(l),n){o={type:"tag",tagType:"playlist-type"},n[1]&&(o.playlistType=n[1]),this.trigger("data",o);return}if(n=/^#EXT-X-BYTERANGE:(.*)?$/.exec(l),n){o=_extends$2(parseByterange(n[1]),{type:"tag",tagType:"byterange"}),this.trigger("data",o);return}if(n=/^#EXT-X-ALLOW-CACHE:(YES|NO)?/.exec(l),n){o={type:"tag",tagType:"allow-cache"},n[1]&&(o.allowed=!/NO/.test(n[1])),this.trigger("data",o);return}if(n=/^#EXT-X-MAP:(.*)$/.exec(l),n){if(o={type:"tag",tagType:"map"},n[1]){const m=parseAttributes$1(n[1]);m.URI&&(o.uri=m.URI),m.BYTERANGE&&(o.byterange=parseByterange(m.BYTERANGE))}this.trigger("data",o);return}if(n=/^#EXT-X-STREAM-INF:(.*)$/.exec(l),n){o={type:"tag",tagType:"stream-inf"},n[1]&&(o.attributes=parseAttributes$1(n[1]),o.attributes.RESOLUTION&&(o.attributes.RESOLUTION=parseResolution(o.attributes.RESOLUTION)),o.attributes.BANDWIDTH&&(o.attributes.BANDWIDTH=parseInt(o.attributes.BANDWIDTH,10)),o.attributes["FRAME-RATE"]&&(o.attributes["FRAME-RATE"]=parseFloat(o.attributes["FRAME-RATE"])),o.attributes["PROGRAM-ID"]&&(o.attributes["PROGRAM-ID"]=parseInt(o.attributes["PROGRAM-ID"],10))),this.trigger("data",o);return}if(n=/^#EXT-X-MEDIA:(.*)$/.exec(l),n){o={type:"tag",tagType:"media"},n[1]&&(o.attributes=parseAttributes$1(n[1])),this.trigger("data",o);return}if(n=/^#EXT-X-ENDLIST/.exec(l),n){this.trigger("data",{type:"tag",tagType:"endlist"});return}if(n=/^#EXT-X-DISCONTINUITY/.exec(l),n){this.trigger("data",{type:"tag",tagType:"discontinuity"});return}if(n=/^#EXT-X-PROGRAM-DATE-TIME:(.*)$/.exec(l),n){o={type:"tag",tagType:"program-date-time"},n[1]&&(o.dateTimeString=n[1],o.dateTimeObject=new Date(n[1])),this.trigger("data",o);return}if(n=/^#EXT-X-KEY:(.*)$/.exec(l),n){o={type:"tag",tagType:"key"},n[1]&&(o.attributes=parseAttributes$1(n[1]),o.attributes.IV&&(o.attributes.IV.substring(0,2).toLowerCase()==="0x"&&(o.attributes.IV=o.attributes.IV.substring(2)),o.attributes.IV=o.attributes.IV.match(/.{8}/g),o.attributes.IV[0]=parseInt(o.attributes.IV[0],16),o.attributes.IV[1]=parseInt(o.attributes.IV[1],16),o.attributes.IV[2]=parseInt(o.attributes.IV[2],16),o.attributes.IV[3]=parseInt(o.attributes.IV[3],16),o.attributes.IV=new Uint32Array(o.attributes.IV))),this.trigger("data",o);return}if(n=/^#EXT-X-START:(.*)$/.exec(l),n){o={type:"tag",tagType:"start"},n[1]&&(o.attributes=parseAttributes$1(n[1]),o.attributes["TIME-OFFSET"]=parseFloat(o.attributes["TIME-OFFSET"]),o.attributes.PRECISE=/YES/.test(o.attributes.PRECISE)),this.trigger("data",o);return}if(n=/^#EXT-X-CUE-OUT-CONT:(.*)?$/.exec(l),n){o={type:"tag",tagType:"cue-out-cont"},n[1]?o.data=n[1]:o.data="",this.trigger("data",o);return}if(n=/^#EXT-X-CUE-OUT:(.*)?$/.exec(l),n){o={type:"tag",tagType:"cue-out"},n[1]?o.data=n[1]:o.data="",this.trigger("data",o);return}if(n=/^#EXT-X-CUE-IN:?(.*)?$/.exec(l),n){o={type:"tag",tagType:"cue-in"},n[1]?o.data=n[1]:o.data="",this.trigger("data",o);return}if(n=/^#EXT-X-SKIP:(.*)$/.exec(l),n&&n[1]){o={type:"tag",tagType:"skip"},o.attributes=parseAttributes$1(n[1]),o.attributes.hasOwnProperty("SKIPPED-SEGMENTS")&&(o.attributes["SKIPPED-SEGMENTS"]=parseInt(o.attributes["SKIPPED-SEGMENTS"],10)),o.attributes.hasOwnProperty("RECENTLY-REMOVED-DATERANGES")&&(o.attributes["RECENTLY-REMOVED-DATERANGES"]=o.attributes["RECENTLY-REMOVED-DATERANGES"].split(TAB)),this.trigger("data",o);return}if(n=/^#EXT-X-PART:(.*)$/.exec(l),n&&n[1]){o={type:"tag",tagType:"part"},o.attributes=parseAttributes$1(n[1]),["DURATION"].forEach(function(m){o.attributes.hasOwnProperty(m)&&(o.attributes[m]=parseFloat(o.attributes[m]))}),["INDEPENDENT","GAP"].forEach(function(m){o.attributes.hasOwnProperty(m)&&(o.attributes[m]=/YES/.test(o.attributes[m]))}),o.attributes.hasOwnProperty("BYTERANGE")&&(o.attributes.byterange=parseByterange(o.attributes.BYTERANGE)),this.trigger("data",o);return}if(n=/^#EXT-X-SERVER-CONTROL:(.*)$/.exec(l),n&&n[1]){o={type:"tag",tagType:"server-control"},o.attributes=parseAttributes$1(n[1]),["CAN-SKIP-UNTIL","PART-HOLD-BACK","HOLD-BACK"].forEach(function(m){o.attributes.hasOwnProperty(m)&&(o.attributes[m]=parseFloat(o.attributes[m]))}),["CAN-SKIP-DATERANGES","CAN-BLOCK-RELOAD"].forEach(function(m){o.attributes.hasOwnProperty(m)&&(o.attributes[m]=/YES/.test(o.attributes[m]))}),this.trigger("data",o);return}if(n=/^#EXT-X-PART-INF:(.*)$/.exec(l),n&&n[1]){o={type:"tag",tagType:"part-inf"},o.attributes=parseAttributes$1(n[1]),["PART-TARGET"].forEach(function(m){o.attributes.hasOwnProperty(m)&&(o.attributes[m]=parseFloat(o.attributes[m]))}),this.trigger("data",o);return}if(n=/^#EXT-X-PRELOAD-HINT:(.*)$/.exec(l),n&&n[1]){o={type:"tag",tagType:"preload-hint"},o.attributes=parseAttributes$1(n[1]),["BYTERANGE-START","BYTERANGE-LENGTH"].forEach(function(m){if(o.attributes.hasOwnProperty(m)){o.attributes[m]=parseInt(o.attributes[m],10);const y=m==="BYTERANGE-LENGTH"?"length":"offset";o.attributes.byterange=o.attributes.byterange||{},o.attributes.byterange[y]=o.attributes[m],delete o.attributes[m]}}),this.trigger("data",o);return}if(n=/^#EXT-X-RENDITION-REPORT:(.*)$/.exec(l),n&&n[1]){o={type:"tag",tagType:"rendition-report"},o.attributes=parseAttributes$1(n[1]),["LAST-MSN","LAST-PART"].forEach(function(m){o.attributes.hasOwnProperty(m)&&(o.attributes[m]=parseInt(o.attributes[m],10))}),this.trigger("data",o);return}if(n=/^#EXT-X-DATERANGE:(.*)$/.exec(l),n&&n[1]){o={type:"tag",tagType:"daterange"},o.attributes=parseAttributes$1(n[1]),["ID","CLASS"].forEach(function(y){o.attributes.hasOwnProperty(y)&&(o.attributes[y]=String(o.attributes[y]))}),["START-DATE","END-DATE"].forEach(function(y){o.attributes.hasOwnProperty(y)&&(o.attributes[y]=new Date(o.attributes[y]))}),["DURATION","PLANNED-DURATION"].forEach(function(y){o.attributes.hasOwnProperty(y)&&(o.attributes[y]=parseFloat(o.attributes[y]))}),["END-ON-NEXT"].forEach(function(y){o.attributes.hasOwnProperty(y)&&(o.attributes[y]=/YES/i.test(o.attributes[y]))}),["SCTE35-CMD"," SCTE35-OUT","SCTE35-IN"].forEach(function(y){o.attributes.hasOwnProperty(y)&&(o.attributes[y]=o.attributes[y].toString(16))});const m=/^X-([A-Z]+-)+[A-Z]+$/;for(const y in o.attributes){if(!m.test(y))continue;const E=/[0-9A-Fa-f]{6}/g.test(o.attributes[y]),C=/^\d+(\.\d+)?$/.test(o.attributes[y]);o.attributes[y]=E?o.attributes[y].toString(16):C?parseFloat(o.attributes[y]):String(o.attributes[y])}this.trigger("data",o);return}if(n=/^#EXT-X-INDEPENDENT-SEGMENTS/.exec(l),n){this.trigger("data",{type:"tag",tagType:"independent-segments"});return}if(n=/^#EXT-X-I-FRAMES-ONLY/.exec(l),n){this.trigger("data",{type:"tag",tagType:"i-frames-only"});return}if(n=/^#EXT-X-CONTENT-STEERING:(.*)$/.exec(l),n){o={type:"tag",tagType:"content-steering"},o.attributes=parseAttributes$1(n[1]),this.trigger("data",o);return}if(n=/^#EXT-X-I-FRAME-STREAM-INF:(.*)$/.exec(l),n){o={type:"tag",tagType:"i-frame-playlist"},o.attributes=parseAttributes$1(n[1]),o.attributes.URI&&(o.uri=o.attributes.URI),o.attributes.BANDWIDTH&&(o.attributes.BANDWIDTH=parseInt(o.attributes.BANDWIDTH,10)),o.attributes.RESOLUTION&&(o.attributes.RESOLUTION=parseResolution(o.attributes.RESOLUTION)),o.attributes["AVERAGE-BANDWIDTH"]&&(o.attributes["AVERAGE-BANDWIDTH"]=parseInt(o.attributes["AVERAGE-BANDWIDTH"],10)),o.attributes["FRAME-RATE"]&&(o.attributes["FRAME-RATE"]=parseFloat(o.attributes["FRAME-RATE"])),this.trigger("data",o);return}if(n=/^#EXT-X-DEFINE:(.*)$/.exec(l),n){o={type:"tag",tagType:"define"},o.attributes=parseAttributes$1(n[1]),this.trigger("data",o);return}this.trigger("data",{type:"tag",data:l.slice(4)})})}addParser({expression:e,customType:n,dataParser:o,segment:u}){typeof o!="function"&&(o=l=>l),this.customParsers.push(l=>{if(e.exec(l))return this.trigger("data",{type:"custom",data:o(l),customType:n,segment:u}),!0})}addTagMapper({expression:e,map:n}){const o=u=>e.test(u)?n(u):u;this.tagMappers.push(o)}}const camelCase=t=>t.toLowerCase().replace(/-(\w)/g,e=>e[1].toUpperCase()),camelCaseKeys=function(t){const e={};return Object.keys(t).forEach(function(n){e[camelCase(n)]=t[n]}),e},setHoldBack=function(t){const{serverControl:e,targetDuration:n,partTargetDuration:o}=t;if(!e)return;const u="#EXT-X-SERVER-CONTROL",l="holdBack",m="partHoldBack",y=n&&n*3,E=o&&o*2;n&&!e.hasOwnProperty(l)&&(e[l]=y,this.trigger("info",{message:`${u} defaulting HOLD-BACK to targetDuration * 3 (${y}).`})),y&&e[l]<y&&(this.trigger("warn",{message:`${u} clamping HOLD-BACK (${e[l]}) to targetDuration * 3 (${y})`}),e[l]=y),o&&!e.hasOwnProperty(m)&&(e[m]=o*3,this.trigger("info",{message:`${u} defaulting PART-HOLD-BACK to partTargetDuration * 3 (${e[m]}).`})),o&&e[m]<E&&(this.trigger("warn",{message:`${u} clamping PART-HOLD-BACK (${e[m]}) to partTargetDuration * 2 (${E}).`}),e[m]=E)};class Parser extends Stream{constructor(e={}){super(),this.lineStream=new LineStream,this.parseStream=new ParseStream,this.lineStream.pipe(this.parseStream),this.mainDefinitions=e.mainDefinitions||{},this.params=new URL(e.uri,"https://a.com").searchParams,this.lastProgramDateTime=null;const n=this,o=[];let u={},l,m,y=!1;const E=function(){},C={AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},k="urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed";let A=0;this.manifest={allowCache:!0,discontinuityStarts:[],dateRanges:[],iFramePlaylists:[],segments:[]};let D=0,P=0;const R={};this.on("end",()=>{u.uri||!u.parts&&!u.preloadHints||(!u.map&&l&&(u.map=l),!u.key&&m&&(u.key=m),!u.timeline&&typeof A=="number"&&(u.timeline=A),this.manifest.preloadSegment=u)}),this.parseStream.on("data",function(B){let F,j;if(n.manifest.definitions){for(const N in n.manifest.definitions)if(B.uri&&(B.uri=B.uri.replace(`{$${N}}`,n.manifest.definitions[N])),B.attributes)for(const Y in B.attributes)typeof B.attributes[Y]=="string"&&(B.attributes[Y]=B.attributes[Y].replace(`{$${N}}`,n.manifest.definitions[N]))}({tag(){({version(){B.version&&(this.manifest.version=B.version)},"allow-cache"(){this.manifest.allowCache=B.allowed,"allowed"in B||(this.trigger("info",{message:"defaulting allowCache to YES"}),this.manifest.allowCache=!0)},byterange(){const N={};"length"in B&&(u.byterange=N,N.length=B.length,"offset"in B||(B.offset=D)),"offset"in B&&(u.byterange=N,N.offset=B.offset),D=N.offset+N.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"})),B.title&&(u.title=B.title),B.duration>0&&(u.duration=B.duration),B.duration===0&&(u.duration=.01,this.trigger("info",{message:"updating zero segment duration to a small value"})),this.manifest.segments=o},key(){if(!B.attributes){this.trigger("warn",{message:"ignoring key declaration without attribute list"});return}if(B.attributes.METHOD==="NONE"){m=null;return}if(!B.attributes.URI){this.trigger("warn",{message:"ignoring key declaration without URI"});return}if(B.attributes.KEYFORMAT==="com.apple.streamingkeydelivery"){this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.apple.fps.1_0"]={attributes:B.attributes};return}if(B.attributes.KEYFORMAT==="com.microsoft.playready"){this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.microsoft.playready"]={uri:B.attributes.URI};return}if(B.attributes.KEYFORMAT===k){if(["SAMPLE-AES","SAMPLE-AES-CTR","SAMPLE-AES-CENC"].indexOf(B.attributes.METHOD)===-1){this.trigger("warn",{message:"invalid key method provided for Widevine"});return}if(B.attributes.METHOD==="SAMPLE-AES-CENC"&&this.trigger("warn",{message:"SAMPLE-AES-CENC is deprecated, please use SAMPLE-AES-CTR instead"}),B.attributes.URI.substring(0,23)!=="data:text/plain;base64,"){this.trigger("warn",{message:"invalid key URI provided for Widevine"});return}if(!(B.attributes.KEYID&&B.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:B.attributes.KEYFORMAT,keyId:B.attributes.KEYID.substring(2)},pssh:decodeB64ToUint8Array(B.attributes.URI.split(",")[1])};return}B.attributes.METHOD||this.trigger("warn",{message:"defaulting key method to AES-128"}),m={method:B.attributes.METHOD||"AES-128",uri:B.attributes.URI},typeof B.attributes.IV<"u"&&(m.iv=B.attributes.IV)},"media-sequence"(){if(!isFinite(B.number)){this.trigger("warn",{message:"ignoring invalid media sequence: "+B.number});return}this.manifest.mediaSequence=B.number},"discontinuity-sequence"(){if(!isFinite(B.number)){this.trigger("warn",{message:"ignoring invalid discontinuity sequence: "+B.number});return}this.manifest.discontinuitySequence=B.number,A=B.number},"playlist-type"(){if(!/VOD|EVENT/.test(B.playlistType)){this.trigger("warn",{message:"ignoring unknown playlist type: "+B.playlist});return}this.manifest.playlistType=B.playlistType},map(){l={},B.uri&&(l.uri=B.uri),B.byterange&&(l.byterange=B.byterange),m&&(l.key=m)},"stream-inf"(){if(this.manifest.playlists=o,this.manifest.mediaGroups=this.manifest.mediaGroups||C,!B.attributes){this.trigger("warn",{message:"ignoring empty stream-inf attributes"});return}u.attributes||(u.attributes={}),_extends$2(u.attributes,B.attributes)},media(){if(this.manifest.mediaGroups=this.manifest.mediaGroups||C,!(B.attributes&&B.attributes.TYPE&&B.attributes["GROUP-ID"]&&B.attributes.NAME)){this.trigger("warn",{message:"ignoring incomplete or missing media group"});return}const N=this.manifest.mediaGroups[B.attributes.TYPE];N[B.attributes["GROUP-ID"]]=N[B.attributes["GROUP-ID"]]||{},F=N[B.attributes["GROUP-ID"]],j={default:/yes/i.test(B.attributes.DEFAULT)},j.default?j.autoselect=!0:j.autoselect=/yes/i.test(B.attributes.AUTOSELECT),B.attributes.LANGUAGE&&(j.language=B.attributes.LANGUAGE),B.attributes.URI&&(j.uri=B.attributes.URI),B.attributes["INSTREAM-ID"]&&(j.instreamId=B.attributes["INSTREAM-ID"]),B.attributes.CHARACTERISTICS&&(j.characteristics=B.attributes.CHARACTERISTICS),B.attributes.FORCED&&(j.forced=/yes/i.test(B.attributes.FORCED)),F[B.attributes.NAME]=j},discontinuity(){A+=1,u.discontinuity=!0,this.manifest.discontinuityStarts.push(o.length)},"program-date-time"(){typeof this.manifest.dateTimeString>"u"&&(this.manifest.dateTimeString=B.dateTimeString,this.manifest.dateTimeObject=B.dateTimeObject),u.dateTimeString=B.dateTimeString,u.dateTimeObject=B.dateTimeObject;const{lastProgramDateTime:N}=this;this.lastProgramDateTime=new Date(B.dateTimeString).getTime(),N===null&&this.manifest.segments.reduceRight((Y,J)=>(J.programDateTime=Y-J.duration*1e3,J.programDateTime),this.lastProgramDateTime)},targetduration(){if(!isFinite(B.duration)||B.duration<0){this.trigger("warn",{message:"ignoring invalid target duration: "+B.duration});return}this.manifest.targetDuration=B.duration,setHoldBack.call(this,this.manifest)},start(){if(!B.attributes||isNaN(B.attributes["TIME-OFFSET"])){this.trigger("warn",{message:"ignoring start declaration without appropriate attribute list"});return}this.manifest.start={timeOffset:B.attributes["TIME-OFFSET"],precise:B.attributes.PRECISE}},"cue-out"(){u.cueOut=B.data},"cue-out-cont"(){u.cueOutCont=B.data},"cue-in"(){u.cueIn=B.data},skip(){this.manifest.skip=camelCaseKeys(B.attributes),this.warnOnMissingAttributes_("#EXT-X-SKIP",B.attributes,["SKIPPED-SEGMENTS"])},part(){y=!0;const N=this.manifest.segments.length,Y=camelCaseKeys(B.attributes);u.parts=u.parts||[],u.parts.push(Y),Y.byterange&&(Y.byterange.hasOwnProperty("offset")||(Y.byterange.offset=P),P=Y.byterange.offset+Y.byterange.length);const J=u.parts.length-1;this.warnOnMissingAttributes_(`#EXT-X-PART #${J} for segment #${N}`,B.attributes,["URI","DURATION"]),this.manifest.renditionReports&&this.manifest.renditionReports.forEach((ie,ue)=>{ie.hasOwnProperty("lastPart")||this.trigger("warn",{message:`#EXT-X-RENDITION-REPORT #${ue} lacks required attribute(s): LAST-PART`})})},"server-control"(){const N=this.manifest.serverControl=camelCaseKeys(B.attributes);N.hasOwnProperty("canBlockReload")||(N.canBlockReload=!1,this.trigger("info",{message:"#EXT-X-SERVER-CONTROL defaulting CAN-BLOCK-RELOAD to false"})),setHoldBack.call(this,this.manifest),N.canSkipDateranges&&!N.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 N=this.manifest.segments.length,Y=camelCaseKeys(B.attributes),J=Y.type&&Y.type==="PART";u.preloadHints=u.preloadHints||[],u.preloadHints.push(Y),Y.byterange&&(Y.byterange.hasOwnProperty("offset")||(Y.byterange.offset=J?P:0,J&&(P=Y.byterange.offset+Y.byterange.length)));const ie=u.preloadHints.length-1;if(this.warnOnMissingAttributes_(`#EXT-X-PRELOAD-HINT #${ie} for segment #${N}`,B.attributes,["TYPE","URI"]),!!Y.type)for(let ue=0;ue<u.preloadHints.length-1;ue++){const Q=u.preloadHints[ue];Q.type&&Q.type===Y.type&&this.trigger("warn",{message:`#EXT-X-PRELOAD-HINT #${ie} for segment #${N} has the same TYPE ${Y.type} as preload hint #${ue}`})}},"rendition-report"(){const N=camelCaseKeys(B.attributes);this.manifest.renditionReports=this.manifest.renditionReports||[],this.manifest.renditionReports.push(N);const Y=this.manifest.renditionReports.length-1,J=["LAST-MSN","URI"];y&&J.push("LAST-PART"),this.warnOnMissingAttributes_(`#EXT-X-RENDITION-REPORT #${Y}`,B.attributes,J)},"part-inf"(){this.manifest.partInf=camelCaseKeys(B.attributes),this.warnOnMissingAttributes_("#EXT-X-PART-INF",B.attributes,["PART-TARGET"]),this.manifest.partInf.partTarget&&(this.manifest.partTargetDuration=this.manifest.partInf.partTarget),setHoldBack.call(this,this.manifest)},daterange(){this.manifest.dateRanges.push(camelCaseKeys(B.attributes));const N=this.manifest.dateRanges.length-1;this.warnOnMissingAttributes_(`#EXT-X-DATERANGE #${N}`,B.attributes,["ID","START-DATE"]);const Y=this.manifest.dateRanges[N];Y.endDate&&Y.startDate&&new Date(Y.endDate)<new Date(Y.startDate)&&this.trigger("warn",{message:"EXT-X-DATERANGE END-DATE must be equal to or later than the value of the START-DATE"}),Y.duration&&Y.duration<0&&this.trigger("warn",{message:"EXT-X-DATERANGE DURATION must not be negative"}),Y.plannedDuration&&Y.plannedDuration<0&&this.trigger("warn",{message:"EXT-X-DATERANGE PLANNED-DURATION must not be negative"});const J=!!Y.endOnNext;if(J&&!Y.class&&this.trigger("warn",{message:"EXT-X-DATERANGE with an END-ON-NEXT=YES attribute must have a CLASS attribute"}),J&&(Y.duration||Y.endDate)&&this.trigger("warn",{message:"EXT-X-DATERANGE with an END-ON-NEXT=YES attribute must not contain DURATION or END-DATE attributes"}),Y.duration&&Y.endDate){const ue=Y.startDate.getTime()+Y.duration*1e3;this.manifest.dateRanges[N].endDate=new Date(ue)}if(!R[Y.id])R[Y.id]=Y;else{for(const ue in R[Y.id])if(Y[ue]&&JSON.stringify(R[Y.id][ue])!==JSON.stringify(Y[ue])){this.trigger("warn",{message:"EXT-X-DATERANGE tags with the same ID in a playlist must have the same attributes values"});break}const ie=this.manifest.dateRanges.findIndex(ue=>ue.id===Y.id);this.manifest.dateRanges[ie]=_extends$2(this.manifest.dateRanges[ie],Y),R[Y.id]=_extends$2(R[Y.id],Y),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=camelCaseKeys(B.attributes),this.warnOnMissingAttributes_("#EXT-X-CONTENT-STEERING",B.attributes,["SERVER-URI"])},define(){this.manifest.definitions=this.manifest.definitions||{};const N=(Y,J)=>{if(Y in this.manifest.definitions){this.trigger("error",{message:`EXT-X-DEFINE: Duplicate name ${Y}`});return}this.manifest.definitions[Y]=J};if("QUERYPARAM"in B.attributes){if("NAME"in B.attributes||"IMPORT"in B.attributes){this.trigger("error",{message:"EXT-X-DEFINE: Invalid attributes"});return}const Y=this.params.get(B.attributes.QUERYPARAM);if(!Y){this.trigger("error",{message:`EXT-X-DEFINE: No query param ${B.attributes.QUERYPARAM}`});return}N(B.attributes.QUERYPARAM,decodeURIComponent(Y));return}if("NAME"in B.attributes){if("IMPORT"in B.attributes){this.trigger("error",{message:"EXT-X-DEFINE: Invalid attributes"});return}if(!("VALUE"in B.attributes)||typeof B.attributes.VALUE!="string"){this.trigger("error",{message:`EXT-X-DEFINE: No value for ${B.attributes.NAME}`});return}N(B.attributes.NAME,B.attributes.VALUE);return}if("IMPORT"in B.attributes){if(!this.mainDefinitions[B.attributes.IMPORT]){this.trigger("error",{message:`EXT-X-DEFINE: No value ${B.attributes.IMPORT} to import, or IMPORT used on main playlist`});return}N(B.attributes.IMPORT,this.mainDefinitions[B.attributes.IMPORT]);return}this.trigger("error",{message:"EXT-X-DEFINE: No attribute"})},"i-frame-playlist"(){this.manifest.iFramePlaylists.push({attributes:B.attributes,uri:B.uri,timeline:A}),this.warnOnMissingAttributes_("#EXT-X-I-FRAME-STREAM-INF",B.attributes,["BANDWIDTH","URI"])}}[B.tagType]||E).call(n)},uri(){u.uri=B.uri,o.push(u),this.manifest.targetDuration&&!("duration"in u)&&(this.trigger("warn",{message:"defaulting segment duration to the target duration"}),u.duration=this.manifest.targetDuration),m&&(u.key=m),u.timeline=A,l&&(u.map=l),P=0,this.lastProgramDateTime!==null&&(u.programDateTime=this.lastProgramDateTime,this.lastProgramDateTime+=u.duration*1e3),u={}},comment(){},custom(){B.segment?(u.custom=u.custom||{},u.custom[B.customType]=B.data):(this.manifest.custom=this.manifest.custom||{},this.manifest.custom[B.customType]=B.data)}})[B.type].call(n)})}requiredCompatibilityversion(e,n){(e<n||!e)&&this.trigger("warn",{message:`manifest must be at least version ${n}`})}warnOnMissingAttributes_(e,n,o){const u=[];o.forEach(function(l){n.hasOwnProperty(l)||u.push(l)}),u.length&&this.trigger("warn",{message:`${e} lacks required attribute(s): ${u.join(", ")}`})}push(e){this.lineStream.push(e)}end(){this.lineStream.push(`
`),this.manifest.dateRanges.length&&this.lastProgramDateTime===null&&this.trigger("warn",{message:"A playlist with EXT-X-DATERANGE tag must contain atleast one EXT-X-PROGRAM-DATE-TIME tag"}),this.lastProgramDateTime=null,this.trigger("end")}addParser(e){this.parseStream.addParser(e)}addTagMapper(e){this.parseStream.addTagMapper(e)}}var regexs={mp4:/^(av0?1|avc0?[1234]|vp0?9|flac|opus|mp3|mp4a|mp4v|stpp.ttml.im1t)/,webm:/^(vp0?[89]|av0?1|opus|vorbis)/,ogg:/^(vp0?[89]|theora|flac|opus|vorbis)/,video:/^(av0?1|avc0?[1234]|vp0?[89]|hvc1|hev1|theora|mp4v)/,audio:/^(mp4a|flac|vorbis|opus|ac-[34]|ec-3|alac|mp3|speex|aac)/,text:/^(stpp.ttml.im1t)/,muxerVideo:/^(avc0?1)/,muxerAudio:/^(mp4a)/,muxerText:/a^/},mediaTypes=["video","audio","text"],upperMediaTypes=["Video","Audio","Text"],translateLegacyCodec=function(e){return e&&e.replace(/avc1\.(\d+)\.(\d+)/i,function(n,o,u){var l=("00"+Number(o).toString(16)).slice(-2),m=("00"+Number(u).toString(16)).slice(-2);return"avc1."+l+"00"+m})},parseCodecs=function(e){e===void 0&&(e="");var n=e.split(","),o=[];return n.forEach(function(u){u=u.trim();var l;mediaTypes.forEach(function(m){var y=regexs[m].exec(u.toLowerCase());if(!(!y||y.length<=1)){l=m;var E=u.substring(0,y[1].length),C=u.replace(E,"");o.push({type:E,details:C,mediaType:m})}}),l||o.push({type:u,details:"",mediaType:"unknown"})}),o},codecsFromDefault=function(e,n){if(!e.mediaGroups.AUDIO||!n)return null;var o=e.mediaGroups.AUDIO[n];if(!o)return null;for(var u in o){var l=o[u];if(l.default&&l.playlists)return parseCodecs(l.playlists[0].attributes.CODECS)}return null},isAudioCodec=function(e){return e===void 0&&(e=""),regexs.audio.test(e.trim().toLowerCase())},isTextCodec=function(e){return e===void 0&&(e=""),regexs.text.test(e.trim().toLowerCase())},getMimeForCodec=function(e){if(!(!e||typeof e!="string")){var n=e.toLowerCase().split(",").map(function(l){return translateLegacyCodec(l.trim())}),o="video";n.length===1&&isAudioCodec(n[0])?o="audio":n.length===1&&isTextCodec(n[0])&&(o="application");var u="mp4";return n.every(function(l){return regexs.mp4.test(l)})?u="mp4":n.every(function(l){return regexs.webm.test(l)})?u="webm":n.every(function(l){return regexs.ogg.test(l)})&&(u="ogg"),o+"/"+u+';codecs="'+e+'"'}},browserSupportsCodec=function(e,n){return e===void 0&&(e=""),n===void 0&&(n=!1),window$1$1.MediaSource&&window$1$1.MediaSource.isTypeSupported&&window$1$1.MediaSource.isTypeSupported(getMimeForCodec(e))||n&&window$1$1.ManagedMediaSource&&window$1$1.ManagedMediaSource.isTypeSupported&&window$1$1.ManagedMediaSource.isTypeSupported(getMimeForCodec(e))||!1},muxerSupportsCodec=function(e){return e===void 0&&(e=""),e.toLowerCase().split(",").every(function(n){n=n.trim();for(var o=0;o<upperMediaTypes.length;o++){var u=upperMediaTypes[o];if(regexs["muxer"+u].test(n))return!0}return!1})},DEFAULT_AUDIO_CODEC="mp4a.40.2",DEFAULT_VIDEO_CODEC="avc1.4d400d",MPEGURL_REGEX=/^(audio|video|application)\/(x-|vnd\.apple\.)?mpegurl/i,DASH_REGEX=/^application\/dash\+xml/i,simpleTypeFromSourceType=function(e){return MPEGURL_REGEX.test(e)?"hls":DASH_REGEX.test(e)?"dash":e==="application/vnd.videojs.vhs+json"?"vhs-json":null},countBits=function(e){return e.toString(2).length},countBytes=function(e){return Math.ceil(countBits(e)/8)},isArrayBufferView=function(e){return ArrayBuffer.isView==="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer},isTypedArray$1=function(e){return isArrayBufferView(e)},toUint8=function(e){return e instanceof Uint8Array?e:(!Array.isArray(e)&&!isTypedArray$1(e)&&!(e instanceof ArrayBuffer)&&(typeof e!="number"||typeof e=="number"&&e!==e?e=0:e=[e]),new Uint8Array(e&&e.buffer||e,e&&e.byteOffset||0,e&&e.byteLength||0))},BigInt$1=window$1$1.BigInt||Number,BYTE_TABLE=[BigInt$1("0x1"),BigInt$1("0x100"),BigInt$1("0x10000"),BigInt$1("0x1000000"),BigInt$1("0x100000000"),BigInt$1("0x10000000000"),BigInt$1("0x1000000000000"),BigInt$1("0x100000000000000"),BigInt$1("0x10000000000000000")];(function(){var t=new Uint16Array([65484]),e=new Uint8Array(t.buffer,t.byteOffset,t.byteLength);return e[0]===255?"big":e[0]===204?"little":"unknown"})();var bytesToNumber=function(e,n){var o=n===void 0?{}:n,u=o.signed,l=u===void 0?!1:u,m=o.le,y=m===void 0?!1:m;e=toUint8(e);var E=y?"reduce":"reduceRight",C=e[E]?e[E]:Array.prototype[E],k=C.call(e,function(D,P,R){var B=y?R:Math.abs(R+1-e.length);return D+BigInt$1(P)*BYTE_TABLE[B]},BigInt$1(0));if(l){var A=BYTE_TABLE[e.length]/BigInt$1(2)-BigInt$1(1);k=BigInt$1(k),k>A&&(k-=A,k-=A,k-=BigInt$1(2))}return Number(k)},numberToBytes=function(e,n){var o={},u=o.le,l=u===void 0?!1:u;(typeof e!="bigint"&&typeof e!="number"||typeof e=="number"&&e!==e)&&(e=0),e=BigInt$1(e);for(var m=countBytes(e),y=new Uint8Array(new ArrayBuffer(m)),E=0;E<m;E++){var C=l?E:Math.abs(E+1-y.length);y[C]=Number(e/BYTE_TABLE[E]&BigInt$1(255)),e<0&&(y[C]=Math.abs(~y[C]),y[C]-=E===0?1:2)}return y},stringToBytes=function(e,n){if(typeof e!="string"&&e&&typeof e.toString=="function"&&(e=e.toString()),typeof e!="string")return new Uint8Array;n||(e=unescape(encodeURIComponent(e)));for(var o=new Uint8Array(e.length),u=0;u<e.length;u++)o[u]=e.charCodeAt(u);return o},concatTypedArrays=function(){for(var e=arguments.length,n=new Array(e),o=0;o<e;o++)n[o]=arguments[o];if(n=n.filter(function(y){return y&&(y.byteLength||y.length)&&typeof y!="string"}),n.length<=1)return toUint8(n[0]);var u=n.reduce(function(y,E,C){return y+(E.byteLength||E.length)},0),l=new Uint8Array(u),m=0;return n.forEach(function(y){y=toUint8(y),l.set(y,m),m+=y.byteLength}),l},bytesMatch=function(e,n,o){var u=o===void 0?{}:o,l=u.offset,m=l===void 0?0:l,y=u.mask,E=y===void 0?[]:y;e=toUint8(e),n=toUint8(n);var C=n.every?n.every:Array.prototype.every;return n.length&&e.length-m>=n.length&&C.call(n,function(k,A){var D=E[A]?E[A]&e[m+A]:e[m+A];return k===D})},forEachMediaGroup$1=function(e,n,o){n.forEach(function(u){for(var l in e.mediaGroups[u])for(var m in e.mediaGroups[u][l]){var y=e.mediaGroups[u][l][m];o(y,u,l,m)}})},dom$1={},conventions$2={};function find$1(t,e,n){if(n===void 0&&(n=Array.prototype),t&&typeof n.find=="function")return n.find.call(t,e);for(var o=0;o<t.length;o++)if(Object.prototype.hasOwnProperty.call(t,o)){var u=t[o];if(e.call(void 0,u,o,t))return u}}function freeze(t,e){return e===void 0&&(e=Object),e&&typeof e.freeze=="function"?e.freeze(t):t}function assign(t,e){if(t===null||typeof t!="object")throw new TypeError("target is not an object");for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}var MIME_TYPE=freeze({HTML:"text/html",isHTML:function(t){return t===MIME_TYPE.HTML},XML_APPLICATION:"application/xml",XML_TEXT:"text/xml",XML_XHTML_APPLICATION:"application/xhtml+xml",XML_SVG_IMAGE:"image/svg+xml"}),NAMESPACE$3=freeze({HTML:"http://www.w3.org/1999/xhtml",isHTML:function(t){return t===NAMESPACE$3.HTML},SVG:"http://www.w3.org/2000/svg",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/"});conventions$2.assign=assign,conventions$2.find=find$1,conventions$2.freeze=freeze,conventions$2.MIME_TYPE=MIME_TYPE,conventions$2.NAMESPACE=NAMESPACE$3;var conventions$1=conventions$2,find=conventions$1.find,NAMESPACE$2=conventions$1.NAMESPACE;function notEmptyString(t){return t!==""}function splitOnASCIIWhitespace(t){return t?t.split(/[\t\n\f\r ]+/).filter(notEmptyString):[]}function orderedSetReducer(t,e){return t.hasOwnProperty(e)||(t[e]=!0),t}function toOrderedSet(t){if(!t)return[];var e=splitOnASCIIWhitespace(t);return Object.keys(e.reduce(orderedSetReducer,{}))}function arrayIncludes(t){return function(e){return t&&t.indexOf(e)!==-1}}function copy$1(t,e){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}function _extends(t,e){var n=t.prototype;if(!(n instanceof e)){let o=function(){};o.prototype=e.prototype,o=new o,copy$1(n,o),t.prototype=n=o}n.constructor!=t&&(typeof t!="function"&&console.error("unknown Class:"+t),n.constructor=t)}var NodeType={},ELEMENT_NODE=NodeType.ELEMENT_NODE=1,ATTRIBUTE_NODE=NodeType.ATTRIBUTE_NODE=2,TEXT_NODE=NodeType.TEXT_NODE=3,CDATA_SECTION_NODE=NodeType.CDATA_SECTION_NODE=4,ENTITY_REFERENCE_NODE=NodeType.ENTITY_REFERENCE_NODE=5,ENTITY_NODE=NodeType.ENTITY_NODE=6,PROCESSING_INSTRUCTION_NODE=NodeType.PROCESSING_INSTRUCTION_NODE=7,COMMENT_NODE=NodeType.COMMENT_NODE=8,DOCUMENT_NODE=NodeType.DOCUMENT_NODE=9,DOCUMENT_TYPE_NODE=NodeType.DOCUMENT_TYPE_NODE=10,DOCUMENT_FRAGMENT_NODE=NodeType.DOCUMENT_FRAGMENT_NODE=11,NOTATION_NODE=NodeType.NOTATION_NODE=12,ExceptionCode={},ExceptionMessage={};ExceptionCode.INDEX_SIZE_ERR=(ExceptionMessage[1]="Index size error",1),ExceptionCode.DOMSTRING_SIZE_ERR=(ExceptionMessage[2]="DOMString size error",2);var HIERARCHY_REQUEST_ERR=ExceptionCode.HIERARCHY_REQUEST_ERR=(ExceptionMessage[3]="Hierarchy request error",3);ExceptionCode.WRONG_DOCUMENT_ERR=(ExceptionMessage[4]="Wrong document",4),ExceptionCode.INVALID_CHARACTER_ERR=(ExceptionMessage[5]="Invalid character",5),ExceptionCode.NO_DATA_ALLOWED_ERR=(ExceptionMessage[6]="No data allowed",6),ExceptionCode.NO_MODIFICATION_ALLOWED_ERR=(ExceptionMessage[7]="No modification allowed",7);var NOT_FOUND_ERR=ExceptionCode.NOT_FOUND_ERR=(ExceptionMessage[8]="Not found",8);ExceptionCode.NOT_SUPPORTED_ERR=(ExceptionMessage[9]="Not supported",9);var INUSE_ATTRIBUTE_ERR=ExceptionCode.INUSE_ATTRIBUTE_ERR=(ExceptionMessage[10]="Attribute in use",10);ExceptionCode.INVALID_STATE_ERR=(ExceptionMessage[11]="Invalid state",11),ExceptionCode.SYNTAX_ERR=(ExceptionMessage[12]="Syntax error",12),ExceptionCode.INVALID_MODIFICATION_ERR=(ExceptionMessage[13]="Invalid modification",13),ExceptionCode.NAMESPACE_ERR=(ExceptionMessage[14]="Invalid namespace",14),ExceptionCode.INVALID_ACCESS_ERR=(ExceptionMessage[15]="Invalid access",15);function DOMException(t,e){if(e instanceof Error)var n=e;else n=this,Error.call(this,ExceptionMessage[t]),this.message=ExceptionMessage[t],Error.captureStackTrace&&Error.captureStackTrace(this,DOMException);return n.code=t,e&&(this.message=this.message+": "+e),n}DOMException.prototype=Error.prototype,copy$1(ExceptionCode,DOMException);function NodeList(){}NodeList.prototype={length:0,item:function(t){return t>=0&&t<this.length?this[t]:null},toString:function(t,e){for(var n=[],o=0;o<this.length;o++)serializeToString(this[o],n,t,e);return n.join("")},filter:function(t){return Array.prototype.filter.call(this,t)},indexOf:function(t){return Array.prototype.indexOf.call(this,t)}};function LiveNodeList(t,e){this._node=t,this._refresh=e,_updateLiveList(this)}function _updateLiveList(t){var e=t._node._inc||t._node.ownerDocument._inc;if(t._inc!==e){var n=t._refresh(t._node);if(__set__(t,"length",n.length),!t.$$length||n.length<t.$$length)for(var o=n.length;o in t;o++)Object.prototype.hasOwnProperty.call(t,o)&&delete t[o];copy$1(n,t),t._inc=e}}LiveNodeList.prototype.item=function(t){return _updateLiveList(this),this[t]||null},_extends(LiveNodeList,NodeList);function NamedNodeMap(){}function _findNodeIndex(t,e){for(var n=t.length;n--;)if(t[n]===e)return n}function _addNamedNode(t,e,n,o){if(o?e[_findNodeIndex(e,o)]=n:e[e.length++]=n,t){n.ownerElement=t;var u=t.ownerDocument;u&&(o&&_onRemoveAttribute(u,t,o),_onAddAttribute(u,t,n))}}function _removeNamedNode(t,e,n){var o=_findNodeIndex(e,n);if(o>=0){for(var u=e.length-1;o<u;)e[o]=e[++o];if(e.length=u,t){var l=t.ownerDocument;l&&(_onRemoveAttribute(l,t,n),n.ownerElement=null)}}else throw new DOMException(NOT_FOUND_ERR,new Error(t.tagName+"@"+n))}NamedNodeMap.prototype={length:0,item:NodeList.prototype.item,getNamedItem:function(t){for(var e=this.length;e--;){var n=this[e];if(n.nodeName==t)return n}},setNamedItem:function(t){var e=t.ownerElement;if(e&&e!=this._ownerElement)throw new DOMException(INUSE_ATTRIBUTE_ERR);var n=this.getNamedItem(t.nodeName);return _addNamedNode(this._ownerElement,this,t,n),n},setNamedItemNS:function(t){var e=t.ownerElement,n;if(e&&e!=this._ownerElement)throw new DOMException(INUSE_ATTRIBUTE_ERR);return n=this.getNamedItemNS(t.namespaceURI,t.localName),_addNamedNode(this._ownerElement,this,t,n),n},removeNamedItem:function(t){var e=this.getNamedItem(t);return _removeNamedNode(this._ownerElement,this,e),e},removeNamedItemNS:function(t,e){var n=this.getNamedItemNS(t,e);return _removeNamedNode(this._ownerElement,this,n),n},getNamedItemNS:function(t,e){for(var n=this.length;n--;){var o=this[n];if(o.localName==e&&o.namespaceURI==t)return o}return null}};function DOMImplementation$1(){}DOMImplementation$1.prototype={hasFeature:function(t,e){return!0},createDocument:function(t,e,n){var o=new Document;if(o.implementation=this,o.childNodes=new NodeList,o.doctype=n||null,n&&o.appendChild(n),e){var u=o.createElementNS(t,e);o.appendChild(u)}return o},createDocumentType:function(t,e,n){var o=new DocumentType;return o.name=t,o.nodeName=t,o.publicId=e||"",o.systemId=n||"",o}};function Node(){}Node.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(t,e){return _insertBefore(this,t,e)},replaceChild:function(t,e){_insertBefore(this,t,e,assertPreReplacementValidityInDocument),e&&this.removeChild(e)},removeChild:function(t){return _removeChild(this,t)},appendChild:function(t){return this.insertBefore(t,null)},hasChildNodes:function(){return this.firstChild!=null},cloneNode:function(t){return cloneNode(this.ownerDocument||this,this,t)},normalize:function(){for(var t=this.firstChild;t;){var e=t.nextSibling;e&&e.nodeType==TEXT_NODE&&t.nodeType==TEXT_NODE?(this.removeChild(e),t.appendData(e.data)):(t.normalize(),t=e)}},isSupported:function(t,e){return this.ownerDocument.implementation.hasFeature(t,e)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(t){for(var e=this;e;){var n=e._nsMap;if(n){for(var o in n)if(Object.prototype.hasOwnProperty.call(n,o)&&n[o]===t)return o}e=e.nodeType==ATTRIBUTE_NODE?e.ownerDocument:e.parentNode}return null},lookupNamespaceURI:function(t){for(var e=this;e;){var n=e._nsMap;if(n&&Object.prototype.hasOwnProperty.call(n,t))return n[t];e=e.nodeType==ATTRIBUTE_NODE?e.ownerDocument:e.parentNode}return null},isDefaultNamespace:function(t){var e=this.lookupPrefix(t);return e==null}};function _xmlEncoder(t){return t=="<"&&"&lt;"||t==">"&&"&gt;"||t=="&"&&"&amp;"||t=='"'&&"&quot;"||"&#"+t.charCodeAt()+";"}copy$1(NodeType,Node),copy$1(NodeType,Node.prototype);function _visitNode(t,e){if(e(t))return!0;if(t=t.firstChild)do if(_visitNode(t,e))return!0;while(t=t.nextSibling)}function Document(){this.ownerDocument=this}function _onAddAttribute(t,e,n){t&&t._inc++;var o=n.namespaceURI;o===NAMESPACE$2.XMLNS&&(e._nsMap[n.prefix?n.localName:""]=n.value)}function _onRemoveAttribute(t,e,n,o){t&&t._inc++;var u=n.namespaceURI;u===NAMESPACE$2.XMLNS&&delete e._nsMap[n.prefix?n.localName:""]}function _onUpdateChild(t,e,n){if(t&&t._inc){t._inc++;var o=e.childNodes;if(n)o[o.length++]=n;else{for(var u=e.firstChild,l=0;u;)o[l++]=u,u=u.nextSibling;o.length=l,delete o[o.length]}}}function _removeChild(t,e){var n=e.previousSibling,o=e.nextSibling;return n?n.nextSibling=o:t.firstChild=o,o?o.previousSibling=n:t.lastChild=n,e.parentNode=null,e.previousSibling=null,e.nextSibling=null,_onUpdateChild(t.ownerDocument,t),e}function hasValidParentNodeType(t){return t&&(t.nodeType===Node.DOCUMENT_NODE||t.nodeType===Node.DOCUMENT_FRAGMENT_NODE||t.nodeType===Node.ELEMENT_NODE)}function hasInsertableNodeType(t){return t&&(isElementNode(t)||isTextNode$1(t)||isDocTypeNode(t)||t.nodeType===Node.DOCUMENT_FRAGMENT_NODE||t.nodeType===Node.COMMENT_NODE||t.nodeType===Node.PROCESSING_INSTRUCTION_NODE)}function isDocTypeNode(t){return t&&t.nodeType===Node.DOCUMENT_TYPE_NODE}function isElementNode(t){return t&&t.nodeType===Node.ELEMENT_NODE}function isTextNode$1(t){return t&&t.nodeType===Node.TEXT_NODE}function isElementInsertionPossible(t,e){var n=t.childNodes||[];if(find(n,isElementNode)||isDocTypeNode(e))return!1;var o=find(n,isDocTypeNode);return!(e&&o&&n.indexOf(o)>n.indexOf(e))}function isElementReplacementPossible(t,e){var n=t.childNodes||[];function o(l){return isElementNode(l)&&l!==e}if(find(n,o))return!1;var u=find(n,isDocTypeNode);return!(e&&u&&n.indexOf(u)>n.indexOf(e))}function assertPreInsertionValidity1to5(t,e,n){if(!hasValidParentNodeType(t))throw new DOMException(HIERARCHY_REQUEST_ERR,"Unexpected parent node type "+t.nodeType);if(n&&n.parentNode!==t)throw new DOMException(NOT_FOUND_ERR,"child not in parent");if(!hasInsertableNodeType(e)||isDocTypeNode(e)&&t.nodeType!==Node.DOCUMENT_NODE)throw new DOMException(HIERARCHY_REQUEST_ERR,"Unexpected node type "+e.nodeType+" for parent node type "+t.nodeType)}function assertPreInsertionValidityInDocument(t,e,n){var o=t.childNodes||[],u=e.childNodes||[];if(e.nodeType===Node.DOCUMENT_FRAGMENT_NODE){var l=u.filter(isElementNode);if(l.length>1||find(u,isTextNode$1))throw new DOMException(HIERARCHY_REQUEST_ERR,"More than one element or text in fragment");if(l.length===1&&!isElementInsertionPossible(t,n))throw new DOMException(HIERARCHY_REQUEST_ERR,"Element in fragment can not be inserted before doctype")}if(isElementNode(e)&&!isElementInsertionPossible(t,n))throw new DOMException(HIERARCHY_REQUEST_ERR,"Only one element can be added and only after doctype");if(isDocTypeNode(e)){if(find(o,isDocTypeNode))throw new DOMException(HIERARCHY_REQUEST_ERR,"Only one doctype is allowed");var m=find(o,isElementNode);if(n&&o.indexOf(m)<o.indexOf(n))throw new DOMException(HIERARCHY_REQUEST_ERR,"Doctype can only be inserted before an element");if(!n&&m)throw new DOMException(HIERARCHY_REQUEST_ERR,"Doctype can not be appended since element is present")}}function assertPreReplacementValidityInDocument(t,e,n){var o=t.childNodes||[],u=e.childNodes||[];if(e.nodeType===Node.DOCUMENT_FRAGMENT_NODE){var l=u.filter(isElementNode);if(l.length>1||find(u,isTextNode$1))throw new DOMException(HIERARCHY_REQUEST_ERR,"More than one element or text in fragment");if(l.length===1&&!isElementReplacementPossible(t,n))throw new DOMException(HIERARCHY_REQUEST_ERR,"Element in fragment can not be inserted before doctype")}if(isElementNode(e)&&!isElementReplacementPossible(t,n))throw new DOMException(HIERARCHY_REQUEST_ERR,"Only one element can be added and only after doctype");if(isDocTypeNode(e)){if(find(o,function(E){return isDocTypeNode(E)&&E!==n}))throw new DOMException(HIERARCHY_REQUEST_ERR,"Only one doctype is allowed");var m=find(o,isElementNode);if(n&&o.indexOf(m)<o.indexOf(n))throw new DOMException(HIERARCHY_REQUEST_ERR,"Doctype can only be inserted before an element")}}function _insertBefore(t,e,n,o){assertPreInsertionValidity1to5(t,e,n),t.nodeType===Node.DOCUMENT_NODE&&(o||assertPreInsertionValidityInDocument)(t,e,n);var u=e.parentNode;if(u&&u.removeChild(e),e.nodeType===DOCUMENT_FRAGMENT_NODE){var l=e.firstChild;if(l==null)return e;var m=e.lastChild}else l=m=e;var y=n?n.previousSibling:t.lastChild;l.previousSibling=y,m.nextSibling=n,y?y.nextSibling=l:t.firstChild=l,n==null?t.lastChild=m:n.previousSibling=m;do l.parentNode=t;while(l!==m&&(l=l.nextSibling));return _onUpdateChild(t.ownerDocument||t,t),e.nodeType==DOCUMENT_FRAGMENT_NODE&&(e.firstChild=e.lastChild=null),e}function _appendSingleChild(t,e){return e.parentNode&&e.parentNode.removeChild(e),e.parentNode=t,e.previousSibling=t.lastChild,e.nextSibling=null,e.previousSibling?e.previousSibling.nextSibling=e:t.firstChild=e,t.lastChild=e,_onUpdateChild(t.ownerDocument,t,e),e}Document.prototype={nodeName:"#document",nodeType:DOCUMENT_NODE,doctype:null,documentElement:null,_inc:1,insertBefore:function(t,e){if(t.nodeType==DOCUMENT_FRAGMENT_NODE){for(var n=t.firstChild;n;){var o=n.nextSibling;this.insertBefore(n,e),n=o}return t}return _insertBefore(this,t,e),t.ownerDocument=this,this.documentElement===null&&t.nodeType===ELEMENT_NODE&&(this.documentElement=t),t},removeChild:function(t){return this.documentElement==t&&(this.documentElement=null),_removeChild(this,t)},replaceChild:function(t,e){_insertBefore(this,t,e,assertPreReplacementValidityInDocument),t.ownerDocument=this,e&&this.removeChild(e),isElementNode(t)&&(this.documentElement=t)},importNode:function(t,e){return importNode(this,t,e)},getElementById:function(t){var e=null;return _visitNode(this.documentElement,function(n){if(n.nodeType==ELEMENT_NODE&&n.getAttribute("id")==t)return e=n,!0}),e},getElementsByClassName:function(t){var e=toOrderedSet(t);return new LiveNodeList(this,function(n){var o=[];return e.length>0&&_visitNode(n.documentElement,function(u){if(u!==n&&u.nodeType===ELEMENT_NODE){var l=u.getAttribute("class");if(l){var m=t===l;if(!m){var y=toOrderedSet(l);m=e.every(arrayIncludes(y))}m&&o.push(u)}}}),o})},createElement:function(t){var e=new Element;e.ownerDocument=this,e.nodeName=t,e.tagName=t,e.localName=t,e.childNodes=new NodeList;var n=e.attributes=new NamedNodeMap;return n._ownerElement=e,e},createDocumentFragment:function(){var t=new DocumentFragment;return t.ownerDocument=this,t.childNodes=new NodeList,t},createTextNode:function(t){var e=new Text;return e.ownerDocument=this,e.appendData(t),e},createComment:function(t){var e=new Comment;return e.ownerDocument=this,e.appendData(t),e},createCDATASection:function(t){var e=new CDATASection;return e.ownerDocument=this,e.appendData(t),e},createProcessingInstruction:function(t,e){var n=new ProcessingInstruction;return n.ownerDocument=this,n.tagName=n.nodeName=n.target=t,n.nodeValue=n.data=e,n},createAttribute:function(t){var e=new Attr;return e.ownerDocument=this,e.name=t,e.nodeName=t,e.localName=t,e.specified=!0,e},createEntityReference:function(t){var e=new EntityReference;return e.ownerDocument=this,e.nodeName=t,e},createElementNS:function(t,e){var n=new Element,o=e.split(":"),u=n.attributes=new NamedNodeMap;return n.childNodes=new NodeList,n.ownerDocument=this,n.nodeName=e,n.tagName=e,n.namespaceURI=t,o.length==2?(n.prefix=o[0],n.localName=o[1]):n.localName=e,u._ownerElement=n,n},createAttributeNS:function(t,e){var n=new Attr,o=e.split(":");return n.ownerDocument=this,n.nodeName=e,n.name=e,n.namespaceURI=t,n.specified=!0,o.length==2?(n.prefix=o[0],n.localName=o[1]):n.localName=e,n}},_extends(Document,Node);function Element(){this._nsMap={}}Element.prototype={nodeType:ELEMENT_NODE,hasAttribute:function(t){return this.getAttributeNode(t)!=null},getAttribute:function(t){var e=this.getAttributeNode(t);return e&&e.value||""},getAttributeNode:function(t){return this.attributes.getNamedItem(t)},setAttribute:function(t,e){var n=this.ownerDocument.createAttribute(t);n.value=n.nodeValue=""+e,this.setAttributeNode(n)},removeAttribute:function(t){var e=this.getAttributeNode(t);e&&this.removeAttributeNode(e)},appendChild:function(t){return t.nodeType===DOCUMENT_FRAGMENT_NODE?this.insertBefore(t,null):_appendSingleChild(this,t)},setAttributeNode:function(t){return this.attributes.setNamedItem(t)},setAttributeNodeNS:function(t){return this.attributes.setNamedItemNS(t)},removeAttributeNode:function(t){return this.attributes.removeNamedItem(t.nodeName)},removeAttributeNS:function(t,e){var n=this.getAttributeNodeNS(t,e);n&&this.removeAttributeNode(n)},hasAttributeNS:function(t,e){return this.getAttributeNodeNS(t,e)!=null},getAttributeNS:function(t,e){var n=this.getAttributeNodeNS(t,e);return n&&n.value||""},setAttributeNS:function(t,e,n){var o=this.ownerDocument.createAttributeNS(t,e);o.value=o.nodeValue=""+n,this.setAttributeNode(o)},getAttributeNodeNS:function(t,e){return this.attributes.getNamedItemNS(t,e)},getElementsByTagName:function(t){return new LiveNodeList(this,function(e){var n=[];return _visitNode(e,function(o){o!==e&&o.nodeType==ELEMENT_NODE&&(t==="*"||o.tagName==t)&&n.push(o)}),n})},getElementsByTagNameNS:function(t,e){return new LiveNodeList(this,function(n){var o=[];return _visitNode(n,function(u){u!==n&&u.nodeType===ELEMENT_NODE&&(t==="*"||u.namespaceURI===t)&&(e==="*"||u.localName==e)&&o.push(u)}),o})}},Document.prototype.getElementsByTagName=Element.prototype.getElementsByTagName,Document.prototype.getElementsByTagNameNS=Element.prototype.getElementsByTagNameNS,_extends(Element,Node);function Attr(){}Attr.prototype.nodeType=ATTRIBUTE_NODE,_extends(Attr,Node);function CharacterData(){}CharacterData.prototype={data:"",substringData:function(t,e){return this.data.substring(t,t+e)},appendData:function(t){t=this.data+t,this.nodeValue=this.data=t,this.length=t.length},insertData:function(t,e){this.replaceData(t,0,e)},appendChild:function(t){throw new Error(ExceptionMessage[HIERARCHY_REQUEST_ERR])},deleteData:function(t,e){this.replaceData(t,e,"")},replaceData:function(t,e,n){var o=this.data.substring(0,t),u=this.data.substring(t+e);n=o+n+u,this.nodeValue=this.data=n,this.length=n.length}},_extends(CharacterData,Node);function Text(){}Text.prototype={nodeName:"#text",nodeType:TEXT_NODE,splitText:function(t){var e=this.data,n=e.substring(t);e=e.substring(0,t),this.data=this.nodeValue=e,this.length=e.length;var o=this.ownerDocument.createTextNode(n);return this.parentNode&&this.parentNode.insertBefore(o,this.nextSibling),o}},_extends(Text,CharacterData);function Comment(){}Comment.prototype={nodeName:"#comment",nodeType:COMMENT_NODE},_extends(Comment,CharacterData);function CDATASection(){}CDATASection.prototype={nodeName:"#cdata-section",nodeType:CDATA_SECTION_NODE},_extends(CDATASection,CharacterData);function DocumentType(){}DocumentType.prototype.nodeType=DOCUMENT_TYPE_NODE,_extends(DocumentType,Node);function Notation(){}Notation.prototype.nodeType=NOTATION_NODE,_extends(Notation,Node);function Entity(){}Entity.prototype.nodeType=ENTITY_NODE,_extends(Entity,Node);function EntityReference(){}EntityReference.prototype.nodeType=ENTITY_REFERENCE_NODE,_extends(EntityReference,Node);function DocumentFragment(){}DocumentFragment.prototype.nodeName="#document-fragment",DocumentFragment.prototype.nodeType=DOCUMENT_FRAGMENT_NODE,_extends(DocumentFragment,Node);function ProcessingInstruction(){}ProcessingInstruction.prototype.nodeType=PROCESSING_INSTRUCTION_NODE,_extends(ProcessingInstruction,Node);function XMLSerializer(){}XMLSerializer.prototype.serializeToString=function(t,e,n){return nodeSerializeToString.call(t,e,n)},Node.prototype.toString=nodeSerializeToString;function nodeSerializeToString(t,e){var n=[],o=this.nodeType==9&&this.documentElement||this,u=o.prefix,l=o.namespaceURI;if(l&&u==null){var u=o.lookupPrefix(l);if(u==null)var m=[{namespace:l,prefix:null}]}return serializeToString(this,n,t,e,m),n.join("")}function needNamespaceDefine(t,e,n){var o=t.prefix||"",u=t.namespaceURI;if(!u||o==="xml"&&u===NAMESPACE$2.XML||u===NAMESPACE$2.XMLNS)return!1;for(var l=n.length;l--;){var m=n[l];if(m.prefix===o)return m.namespace!==u}return!0}function addSerializedAttribute(t,e,n){t.push(" ",e,'="',n.replace(/[<>&"\t\n\r]/g,_xmlEncoder),'"')}function serializeToString(t,e,n,o,u){if(u||(u=[]),o)if(t=o(t),t){if(typeof t=="string"){e.push(t);return}}else return;switch(t.nodeType){case ELEMENT_NODE:var l=t.attributes,m=l.length,j=t.firstChild,y=t.tagName;n=NAMESPACE$2.isHTML(t.namespaceURI)||n;var E=y;if(!n&&!t.prefix&&t.namespaceURI){for(var C,k=0;k<l.length;k++)if(l.item(k).name==="xmlns"){C=l.item(k).value;break}if(!C)for(var A=u.length-1;A>=0;A--){var D=u[A];if(D.prefix===""&&D.namespace===t.namespaceURI){C=D.namespace;break}}if(C!==t.namespaceURI)for(var A=u.length-1;A>=0;A--){var D=u[A];if(D.namespace===t.namespaceURI){D.prefix&&(E=D.prefix+":"+y);break}}}e.push("<",E);for(var P=0;P<m;P++){var R=l.item(P);R.prefix=="xmlns"?u.push({prefix:R.localName,namespace:R.value}):R.nodeName=="xmlns"&&u.push({prefix:"",namespace:R.value})}for(var P=0;P<m;P++){var R=l.item(P);if(needNamespaceDefine(R,n,u)){var B=R.prefix||"",F=R.namespaceURI;addSerializedAttribute(e,B?"xmlns:"+B:"xmlns",F),u.push({prefix:B,namespace:F})}serializeToString(R,e,n,o,u)}if(y===E&&needNamespaceDefine(t,n,u)){var B=t.prefix||"",F=t.namespaceURI;addSerializedAttribute(e,B?"xmlns:"+B:"xmlns",F),u.push({prefix:B,namespace:F})}if(j||n&&!/^(?:meta|link|img|br|hr|input)$/i.test(y)){if(e.push(">"),n&&/^script$/i.test(y))for(;j;)j.data?e.push(j.data):serializeToString(j,e,n,o,u.slice()),j=j.nextSibling;else for(;j;)serializeToString(j,e,n,o,u.slice()),j=j.nextSibling;e.push("</",E,">")}else e.push("/>");return;case DOCUMENT_NODE:case DOCUMENT_FRAGMENT_NODE:for(var j=t.firstChild;j;)serializeToString(j,e,n,o,u.slice()),j=j.nextSibling;return;case ATTRIBUTE_NODE:return addSerializedAttribute(e,t.name,t.value);case TEXT_NODE:return e.push(t.data.replace(/[<&>]/g,_xmlEncoder));case CDATA_SECTION_NODE:return e.push("<![CDATA[",t.data,"]]>");case COMMENT_NODE:return e.push("<!--",t.data,"-->");case DOCUMENT_TYPE_NODE:var N=t.publicId,Y=t.systemId;if(e.push("<!DOCTYPE ",t.name),N)e.push(" PUBLIC ",N),Y&&Y!="."&&e.push(" ",Y),e.push(">");else if(Y&&Y!=".")e.push(" SYSTEM ",Y,">");else{var J=t.internalSubset;J&&e.push(" [",J,"]"),e.push(">")}return;case PROCESSING_INSTRUCTION_NODE:return e.push("<?",t.target," ",t.data,"?>");case ENTITY_REFERENCE_NODE:return e.push("&",t.nodeName,";");default:e.push("??",t.nodeName)}}function importNode(t,e,n){var o;switch(e.nodeType){case ELEMENT_NODE:o=e.cloneNode(!1),o.ownerDocument=t;case DOCUMENT_FRAGMENT_NODE:break;case ATTRIBUTE_NODE:n=!0;break}if(o||(o=e.cloneNode(!1)),o.ownerDocument=t,o.parentNode=null,n)for(var u=e.firstChild;u;)o.appendChild(importNode(t,u,n)),u=u.nextSibling;return o}function cloneNode(t,e,n){var o=new e.constructor;for(var u in e)if(Object.prototype.hasOwnProperty.call(e,u)){var l=e[u];typeof l!="object"&&l!=o[u]&&(o[u]=l)}switch(e.childNodes&&(o.childNodes=new NodeList),o.ownerDocument=t,o.nodeType){case ELEMENT_NODE:var m=e.attributes,y=o.attributes=new NamedNodeMap,E=m.length;y._ownerElement=o;for(var C=0;C<E;C++)o.setAttributeNode(cloneNode(t,m.item(C),!0));break;case ATTRIBUTE_NODE:n=!0}if(n)for(var k=e.firstChild;k;)o.appendChild(cloneNode(t,k,n)),k=k.nextSibling;return o}function __set__(t,e,n){t[e]=n}try{if(Object.defineProperty){let t=function(e){switch(e.nodeType){case ELEMENT_NODE:case DOCUMENT_FRAGMENT_NODE:var n=[];for(e=e.firstChild;e;)e.nodeType!==7&&e.nodeType!==8&&n.push(t(e)),e=e.nextSibling;return n.join("");default:return e.nodeValue}};Object.defineProperty(LiveNodeList.prototype,"length",{get:function(){return _updateLiveList(this),this.$$length}}),Object.defineProperty(Node.prototype,"textContent",{get:function(){return t(this)},set:function(e){switch(this.nodeType){case ELEMENT_NODE:case DOCUMENT_FRAGMENT_NODE:for(;this.firstChild;)this.removeChild(this.firstChild);(e||String(e))&&this.appendChild(this.ownerDocument.createTextNode(e));break;default:this.data=e,this.value=e,this.nodeValue=e}}}),__set__=function(e,n,o){e["$$"+n]=o}}}catch(t){}dom$1.DocumentType=DocumentType,dom$1.DOMException=DOMException,dom$1.DOMImplementation=DOMImplementation$1,dom$1.Element=Element,dom$1.Node=Node,dom$1.NodeList=NodeList,dom$1.XMLSerializer=XMLSerializer;var domParser={},entities$1={};(function(t){var e=conventions$2.freeze;t.XML_ENTITIES=e({amp:"&",apos:"'",gt:">",lt:"<",quot:'"'}),t.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:"ﬃ",fflig:"ﬀ",ffllig:"ﬄ",Ffr:"𝔉",ffr:"𝔣",filig:"ﬁ",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"ﬂ",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:"Ĳ",ijlig:"ĳ",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:"ŉ",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:"‌"}),t.entityMap=t.HTML_ENTITIES})(entities$1);var sax$1={},NAMESPACE$1=conventions$2.NAMESPACE,nameStartChar=/[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]/,nameChar=new RegExp("[\\-\\.0-9"+nameStartChar.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"),tagNamePattern=new RegExp("^"+nameStartChar.source+nameChar.source+"*(?::"+nameStartChar.source+nameChar.source+"*)?$"),S_TAG=0,S_ATTR=1,S_ATTR_SPACE=2,S_EQ=3,S_ATTR_NOQUOT_VALUE=4,S_ATTR_END=5,S_TAG_SPACE=6,S_TAG_CLOSE=7;function ParseError$1(t,e){this.message=t,this.locator=e,Error.captureStackTrace&&Error.captureStackTrace(this,ParseError$1)}ParseError$1.prototype=new Error,ParseError$1.prototype.name=ParseError$1.name;function XMLReader$1(){}XMLReader$1.prototype={parse:function(t,e,n){var o=this.domBuilder;o.startDocument(),_copy(e,e={}),parse$5(t,e,n,o,this.errorHandler),o.endDocument()}};function parse$5(t,e,n,o,u){function l(p){if(p>65535){p-=65536;var x=55296+(p>>10),S=56320+(p&1023);return String.fromCharCode(x,S)}else return String.fromCharCode(p)}function m(p){var x=p.slice(1,-1);return Object.hasOwnProperty.call(n,x)?n[x]:x.charAt(0)==="#"?l(parseInt(x.substr(1).replace("x","0x"))):(u.error("entity not found:"+p),p)}function y(p){if(p>B){var x=t.substring(B,p).replace(/&#?\w+;/g,m);D&&E(B),o.characters(x,0,p-B),B=p}}function E(p,x){for(;p>=k&&(x=A.exec(t));)C=x.index,k=C+x[0].length,D.lineNumber++;D.columnNumber=p-C+1}for(var C=0,k=0,A=/.*(?:\r\n?|\n)|.*$/g,D=o.locator,P=[{currentNSMap:e}],R={},B=0;;){try{var F=t.indexOf("<",B);if(F<0){if(!t.substr(B).match(/^\s*$/)){var j=o.doc,N=j.createTextNode(t.substr(B));j.appendChild(N),o.currentElement=N}return}switch(F>B&&y(F),t.charAt(F+1)){case"/":var L=t.indexOf(">",F+3),Y=t.substring(F+2,L).replace(/[ \t\n\r]+$/g,""),J=P.pop();L<0?(Y=t.substring(F+2).replace(/[\s<].*/,""),u.error("end tag name: "+Y+" is not complete:"+J.tagName),L=F+1+Y.length):Y.match(/\s</)&&(Y=Y.replace(/[\s<].*/,""),u.error("end tag name: "+Y+" maybe not complete"),L=F+1+Y.length);var ie=J.localNSMap,ue=J.tagName==Y,Q=ue||J.tagName&&J.tagName.toLowerCase()==Y.toLowerCase();if(Q){if(o.endElement(J.uri,J.localName,Y),ie)for(var ce in ie)Object.prototype.hasOwnProperty.call(ie,ce)&&o.endPrefixMapping(ce);ue||u.fatalError("end tag name: "+Y+" is not match the current start tagName:"+J.tagName)}else P.push(J);L++;break;case"?":D&&E(F),L=parseInstruction(t,F,o);break;case"!":D&&E(F),L=parseDCC(t,F,o,u);break;default:D&&E(F);var he=new ElementAttributes,ke=P[P.length-1].currentNSMap,L=parseElementStartPart(t,F,he,ke,m,u),d=he.length;if(!he.closed&&fixSelfClosed(t,L,he.tagName,R)&&(he.closed=!0,n.nbsp||u.warning("unclosed xml attribute")),D&&d){for(var v=copyLocator(D,{}),w=0;w<d;w++){var c=he[w];E(c.offset),c.locator=copyLocator(D,{})}o.locator=v,appendElement$1(he,o,ke)&&P.push(he),o.locator=D}else appendElement$1(he,o,ke)&&P.push(he);NAMESPACE$1.isHTML(he.uri)&&!he.closed?L=parseHtmlSpecialContent(t,L,he.tagName,m,o):L++}}catch(p){if(p instanceof ParseError$1)throw p;u.error("element parse error: "+p),L=-1}L>B?B=L:y(Math.max(F,B)+1)}}function copyLocator(t,e){return e.lineNumber=t.lineNumber,e.columnNumber=t.columnNumber,e}function parseElementStartPart(t,e,n,o,u,l){function m(D,P,R){n.attributeNames.hasOwnProperty(D)&&l.fatalError("Attribute "+D+" redefined"),n.addValue(D,P.replace(/[\t\n\r]/g," ").replace(/&#?\w+;/g,u),R)}for(var y,E,C=++e,k=S_TAG;;){var A=t.charAt(C);switch(A){case"=":if(k===S_ATTR)y=t.slice(e,C),k=S_EQ;else if(k===S_ATTR_SPACE)k=S_EQ;else throw new Error("attribute equal must after attrName");break;case"'":case'"':if(k===S_EQ||k===S_ATTR)if(k===S_ATTR&&(l.warning('attribute value must after "="'),y=t.slice(e,C)),e=C+1,C=t.indexOf(A,e),C>0)E=t.slice(e,C),m(y,E,e-1),k=S_ATTR_END;else throw new Error("attribute value no end '"+A+"' match");else if(k==S_ATTR_NOQUOT_VALUE)E=t.slice(e,C),m(y,E,e),l.warning('attribute "'+y+'" missed start quot('+A+")!!"),e=C+1,k=S_ATTR_END;else throw new Error('attribute value must after "="');break;case"/":switch(k){case S_TAG:n.setTagName(t.slice(e,C));case S_ATTR_END:case S_TAG_SPACE:case S_TAG_CLOSE:k=S_TAG_CLOSE,n.closed=!0;case S_ATTR_NOQUOT_VALUE:case S_ATTR:break;case S_ATTR_SPACE:n.closed=!0;break;default:throw new Error("attribute invalid close char('/')")}break;case"":return l.error("unexpected end of input"),k==S_TAG&&n.setTagName(t.slice(e,C)),C;case">":switch(k){case S_TAG:n.setTagName(t.slice(e,C));case S_ATTR_END:case S_TAG_SPACE:case S_TAG_CLOSE:break;case S_ATTR_NOQUOT_VALUE:case S_ATTR:E=t.slice(e,C),E.slice(-1)==="/"&&(n.closed=!0,E=E.slice(0,-1));case S_ATTR_SPACE:k===S_ATTR_SPACE&&(E=y),k==S_ATTR_NOQUOT_VALUE?(l.warning('attribute "'+E+'" missed quot(")!'),m(y,E,e)):((!NAMESPACE$1.isHTML(o[""])||!E.match(/^(?:disabled|checked|selected)$/i))&&l.warning('attribute "'+E+'" missed value!! "'+E+'" instead!!'),m(E,E,e));break;case S_EQ:throw new Error("attribute value missed!!")}return C;case"":A=" ";default:if(A<=" ")switch(k){case S_TAG:n.setTagName(t.slice(e,C)),k=S_TAG_SPACE;break;case S_ATTR:y=t.slice(e,C),k=S_ATTR_SPACE;break;case S_ATTR_NOQUOT_VALUE:var E=t.slice(e,C);l.warning('attribute "'+E+'" missed quot(")!!'),m(y,E,e);case S_ATTR_END:k=S_TAG_SPACE;break}else switch(k){case S_ATTR_SPACE:n.tagName,(!NAMESPACE$1.isHTML(o[""])||!y.match(/^(?:disabled|checked|selected)$/i))&&l.warning('attribute "'+y+'" missed value!! "'+y+'" instead2!!'),m(y,y,e),e=C,k=S_ATTR;break;case S_ATTR_END:l.warning('attribute space is required"'+y+'"!!');case S_TAG_SPACE:k=S_ATTR,e=C;break;case S_EQ:k=S_ATTR_NOQUOT_VALUE,e=C;break;case S_TAG_CLOSE:throw new Error("elements closed character '/' and '>' must be connected to")}}C++}}function appendElement$1(t,e,n){for(var o=t.tagName,u=null,A=t.length;A--;){var l=t[A],m=l.qName,y=l.value,D=m.indexOf(":");if(D>0)var E=l.prefix=m.slice(0,D),C=m.slice(D+1),k=E==="xmlns"&&C;else C=m,E=null,k=m==="xmlns"&&"";l.localName=C,k!==!1&&(u==null&&(u={},_copy(n,n={})),n[k]=u[k]=y,l.uri=NAMESPACE$1.XMLNS,e.startPrefixMapping(k,y))}for(var A=t.length;A--;){l=t[A];var E=l.prefix;E&&(E==="xml"&&(l.uri=NAMESPACE$1.XML),E!=="xmlns"&&(l.uri=n[E||""]))}var D=o.indexOf(":");D>0?(E=t.prefix=o.slice(0,D),C=t.localName=o.slice(D+1)):(E=null,C=t.localName=o);var P=t.uri=n[E||""];if(e.startElement(P,C,o,t),t.closed){if(e.endElement(P,C,o),u)for(E in u)Object.prototype.hasOwnProperty.call(u,E)&&e.endPrefixMapping(E)}else return t.currentNSMap=n,t.localNSMap=u,!0}function parseHtmlSpecialContent(t,e,n,o,u){if(/^(?:script|textarea)$/i.test(n)){var l=t.indexOf("</"+n+">",e),m=t.substring(e+1,l);if(/[&<]/.test(m))return/^script$/i.test(n)?(u.characters(m,0,m.length),l):(m=m.replace(/&#?\w+;/g,o),u.characters(m,0,m.length),l)}return e+1}function fixSelfClosed(t,e,n,o){var u=o[n];return u==null&&(u=t.lastIndexOf("</"+n+">"),u<e&&(u=t.lastIndexOf("</"+n)),o[n]=u),u<e}function _copy(t,e){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}function parseDCC(t,e,n,o){var u=t.charAt(e+2);switch(u){case"-":if(t.charAt(e+3)==="-"){var l=t.indexOf("-->",e+4);return l>e?(n.comment(t,e+4,l-e-4),l+3):(o.error("Unclosed comment"),-1)}else return-1;default:if(t.substr(e+3,6)=="CDATA["){var l=t.indexOf("]]>",e+9);return n.startCDATA(),n.characters(t,e+9,l-e-9),n.endCDATA(),l+3}var m=split(t,e),y=m.length;if(y>1&&/!doctype/i.test(m[0][0])){var E=m[1][0],C=!1,k=!1;y>3&&(/^public$/i.test(m[2][0])?(C=m[3][0],k=y>4&&m[4][0]):/^system$/i.test(m[2][0])&&(k=m[3][0]));var A=m[y-1];return n.startDTD(E,C,k),n.endDTD(),A.index+A[0].length}}return-1}function parseInstruction(t,e,n){var o=t.indexOf("?>",e);if(o){var u=t.substring(e,o).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);return u?(u[0].length,n.processingInstruction(u[1],u[2]),o+2):-1}return-1}function ElementAttributes(){this.attributeNames={}}ElementAttributes.prototype={setTagName:function(t){if(!tagNamePattern.test(t))throw new Error("invalid tagName:"+t);this.tagName=t},addValue:function(t,e,n){if(!tagNamePattern.test(t))throw new Error("invalid attribute:"+t);this.attributeNames[t]=this.length,this[this.length++]={qName:t,value:e,offset:n}},length:0,getLocalName:function(t){return this[t].localName},getLocator:function(t){return this[t].locator},getQName:function(t){return this[t].qName},getURI:function(t){return this[t].uri},getValue:function(t){return this[t].value}};function split(t,e){var n,o=[],u=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;for(u.lastIndex=e,u.exec(t);n=u.exec(t);)if(o.push(n),n[1])return o}sax$1.XMLReader=XMLReader$1,sax$1.ParseError=ParseError$1;var conventions=conventions$2,dom=dom$1,entities=entities$1,sax=sax$1,DOMImplementation=dom.DOMImplementation,NAMESPACE=conventions.NAMESPACE,ParseError=sax.ParseError,XMLReader=sax.XMLReader;function normalizeLineEndings(t){return t.replace(/\r[\n\u0085]/g,`
`).replace(/[\r\u0085\u2028]/g,`
`)}function DOMParser$1(t){this.options=t||{locator:{}}}DOMParser$1.prototype.parseFromString=function(t,e){var n=this.options,o=new XMLReader,u=n.domBuilder||new DOMHandler,l=n.errorHandler,m=n.locator,y=n.xmlns||{},E=/\/x?html?$/.test(e),C=E?entities.HTML_ENTITIES:entities.XML_ENTITIES;m&&u.setDocumentLocator(m),o.errorHandler=buildErrorHandler(l,u,m),o.domBuilder=n.domBuilder||u,E&&(y[""]=NAMESPACE.HTML),y.xml=y.xml||NAMESPACE.XML;var k=n.normalizeLineEndings||normalizeLineEndings;return t&&typeof t=="string"?o.parse(k(t),y,C):o.errorHandler.error("invalid doc source"),u.doc};function buildErrorHandler(t,e,n){if(!t){if(e instanceof DOMHandler)return e;t=e}var o={},u=t instanceof Function;n=n||{};function l(m){var y=t[m];!y&&u&&(y=t.length==2?function(E){t(m,E)}:t),o[m]=y&&function(E){y("[xmldom "+m+"]	"+E+_locator(n))}||function(){}}return l("warning"),l("error"),l("fatalError"),o}function DOMHandler(){this.cdata=!1}function position(t,e){e.lineNumber=t.lineNumber,e.columnNumber=t.columnNumber}DOMHandler.prototype={startDocument:function(){this.doc=new DOMImplementation().createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(t,e,n,o){var u=this.doc,l=u.createElementNS(t,n||e),m=o.length;appendElement(this,l),this.currentElement=l,this.locator&&position(this.locator,l);for(var y=0;y<m;y++){var t=o.getURI(y),E=o.getValue(y),n=o.getQName(y),C=u.createAttributeNS(t,n);this.locator&&position(o.getLocator(y),C),C.value=C.nodeValue=E,l.setAttributeNode(C)}},endElement:function(t,e,n){var o=this.currentElement;o.tagName,this.currentElement=o.parentNode},startPrefixMapping:function(t,e){},endPrefixMapping:function(t){},processingInstruction:function(t,e){var n=this.doc.createProcessingInstruction(t,e);this.locator&&position(this.locator,n),appendElement(this,n)},ignorableWhitespace:function(t,e,n){},characters:function(t,e,n){if(t=_toString.apply(this,arguments),t){if(this.cdata)var o=this.doc.createCDATASection(t);else var o=this.doc.createTextNode(t);this.currentElement?this.currentElement.appendChild(o):/^\s*$/.test(t)&&this.doc.appendChild(o),this.locator&&position(this.locator,o)}},skippedEntity:function(t){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(t){(this.locator=t)&&(t.lineNumber=0)},comment:function(t,e,n){t=_toString.apply(this,arguments);var o=this.doc.createComment(t);this.locator&&position(this.locator,o),appendElement(this,o)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(t,e,n){var o=this.doc.implementation;if(o&&o.createDocumentType){var u=o.createDocumentType(t,e,n);this.locator&&position(this.locator,u),appendElement(this,u),this.doc.doctype=u}},warning:function(t){console.warn("[xmldom warning]	"+t,_locator(this.locator))},error:function(t){console.error("[xmldom error]	"+t,_locator(this.locator))},fatalError:function(t){throw new ParseError(t,this.locator)}};function _locator(t){if(t)return`
@`+(t.systemId||"")+"#[line:"+t.lineNumber+",col:"+t.columnNumber+"]"}function _toString(t,e,n){return typeof t=="string"?t.substr(e,n):t.length>=e+n||e?new java.lang.String(t,e,n)+"":t}"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(t){DOMHandler.prototype[t]=function(){return null}});function appendElement(t,e){t.currentElement?t.currentElement.appendChild(e):t.doc.appendChild(e)}domParser.__DOMHandler=DOMHandler,domParser.normalizeLineEndings=normalizeLineEndings,domParser.DOMParser=DOMParser$1;var DOMParser=domParser.DOMParser;/*! @name mpd-parser @version 1.3.1 @license Apache-2.0 */const isObject$2=t=>!!t&&typeof t=="object",merge$2=(...t)=>t.reduce((e,n)=>(typeof n!="object"||Object.keys(n).forEach(o=>{Array.isArray(e[o])&&Array.isArray(n[o])?e[o]=e[o].concat(n[o]):isObject$2(e[o])&&isObject$2(n[o])?e[o]=merge$2(e[o],n[o]):e[o]=n[o]}),e),{}),values$1=t=>Object.keys(t).map(e=>t[e]),range$1=(t,e)=>{const n=[];for(let o=t;o<e;o++)n.push(o);return n},flatten=t=>t.reduce((e,n)=>e.concat(n),[]),from=t=>{if(!t.length)return[];const e=[];for(let n=0;n<t.length;n++)e.push(t[n]);return e},findIndexes=(t,e)=>t.reduce((n,o,u)=>(o[e]&&n.push(u),n),[]),union=(t,e)=>values$1(t.reduce((n,o)=>(o.forEach(u=>{n[e(u)]=u}),n),{}));var errors$3={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 urlTypeToSegment=({baseUrl:t="",source:e="",range:n="",indexRange:o=""})=>{const u={uri:e,resolvedUri:resolveUrl$1(t||"",e)};if(n||o){const m=(n||o).split("-");let y=window$1$1.BigInt?window$1$1.BigInt(m[0]):parseInt(m[0],10),E=window$1$1.BigInt?window$1$1.BigInt(m[1]):parseInt(m[1],10);y<Number.MAX_SAFE_INTEGER&&typeof y=="bigint"&&(y=Number(y)),E<Number.MAX_SAFE_INTEGER&&typeof E=="bigint"&&(E=Number(E));let C;typeof E=="bigint"||typeof y=="bigint"?C=window$1$1.BigInt(E)-window$1$1.BigInt(y)+window$1$1.BigInt(1):C=E-y+1,typeof C=="bigint"&&C<Number.MAX_SAFE_INTEGER&&(C=Number(C)),u.byterange={length:C,offset:y}}return u},byteRangeToString=t=>{let e;return typeof t.offset=="bigint"||typeof t.length=="bigint"?e=window$1$1.BigInt(t.offset)+window$1$1.BigInt(t.length)-window$1$1.BigInt(1):e=t.offset+t.length-1,`${t.offset}-${e}`},parseEndNumber=t=>(t&&typeof t!="number"&&(t=parseInt(t,10)),isNaN(t)?null:t),segmentRange={static(t){const{duration:e,timescale:n=1,sourceDuration:o,periodDuration:u}=t,l=parseEndNumber(t.endNumber),m=e/n;return typeof l=="number"?{start:0,end:l}:typeof u=="number"?{start:0,end:u/m}:{start:0,end:o/m}},dynamic(t){const{NOW:e,clientOffset:n,availabilityStartTime:o,timescale:u=1,duration:l,periodStart:m=0,minimumUpdatePeriod:y=0,timeShiftBufferDepth:E=1/0}=t,C=parseEndNumber(t.endNumber),k=(e+n)/1e3,A=o+m,P=k+y-A,R=Math.ceil(P*u/l),B=Math.floor((k-A-E)*u/l),F=Math.floor((k-A)*u/l);return{start:Math.max(0,B),end:typeof C=="number"?C:Math.min(R,F)}}},toSegments=t=>e=>{const{duration:n,timescale:o=1,periodStart:u,startNumber:l=1}=t;return{number:l+e,duration:n/o,timeline:u,time:e*n}},parseByDuration=t=>{const{type:e,duration:n,timescale:o=1,periodDuration:u,sourceDuration:l}=t,{start:m,end:y}=segmentRange[e](t),E=range$1(m,y).map(toSegments(t));if(e==="static"){const C=E.length-1,k=typeof u=="number"?u:l;E[C].duration=k-n/o*C}return E},segmentsFromBase=t=>{const{baseUrl:e,initialization:n={},sourceDuration:o,indexRange:u="",periodStart:l,presentationTime:m,number:y=0,duration:E}=t;if(!e)throw new Error(errors$3.NO_BASE_URL);const C=urlTypeToSegment({baseUrl:e,source:n.sourceURL,range:n.range}),k=urlTypeToSegment({baseUrl:e,source:e,indexRange:u});if(k.map=C,E){const A=parseByDuration(t);A.length&&(k.duration=A[0].duration,k.timeline=A[0].timeline)}else o&&(k.duration=o,k.timeline=l);return k.presentationTime=m||l,k.number=y,[k]},addSidxSegmentsToPlaylist$1=(t,e,n)=>{const o=t.sidx.map?t.sidx.map:null,u=t.sidx.duration,l=t.timeline||0,m=t.sidx.byterange,y=m.offset+m.length,E=e.timescale,C=e.references.filter(F=>F.referenceType!==1),k=[],A=t.endList?"static":"dynamic",D=t.sidx.timeline;let P=D,R=t.mediaSequence||0,B;typeof e.firstOffset=="bigint"?B=window$1$1.BigInt(y)+e.firstOffset:B=y+e.firstOffset;for(let F=0;F<C.length;F++){const j=e.references[F],N=j.referencedSize,Y=j.subsegmentDuration;let J;typeof B=="bigint"?J=B+window$1$1.BigInt(N)-window$1$1.BigInt(1):J=B+N-1;const ie=`${B}-${J}`,Q=segmentsFromBase({baseUrl:n,timescale:E,timeline:l,periodStart:D,presentationTime:P,number:R,duration:Y,sourceDuration:u,indexRange:ie,type:A})[0];o&&(Q.map=o),k.push(Q),typeof B=="bigint"?B+=window$1$1.BigInt(N):B+=N,P+=Y/E,R++}return t.segments=k,t},SUPPORTED_MEDIA_TYPES=["AUDIO","SUBTITLES"],TIME_FUDGE=1/60,getUniqueTimelineStarts=t=>union(t,({timeline:e})=>e).sort((e,n)=>e.timeline>n.timeline?1:-1),findPlaylistWithName=(t,e)=>{for(let n=0;n<t.length;n++)if(t[n].attributes.NAME===e)return t[n];return null},getMediaGroupPlaylists=t=>{let e=[];return forEachMediaGroup$1(t,SUPPORTED_MEDIA_TYPES,(n,o,u,l)=>{e=e.concat(n.playlists||[])}),e},updateMediaSequenceForPlaylist=({playlist:t,mediaSequence:e})=>{t.mediaSequence=e,t.segments.forEach((n,o)=>{n.number=t.mediaSequence+o})},updateSequenceNumbers=({oldPlaylists:t,newPlaylists:e,timelineStarts:n})=>{e.forEach(o=>{o.discontinuitySequence=n.findIndex(function({timeline:E}){return E===o.timeline});const u=findPlaylistWithName(t,o.attributes.NAME);if(!u||o.sidx)return;const l=o.segments[0],m=u.segments.findIndex(function(E){return Math.abs(E.presentationTime-l.presentationTime)<TIME_FUDGE});if(m===-1){updateMediaSequenceForPlaylist({playlist:o,mediaSequence:u.mediaSequence+u.segments.length}),o.segments[0].discontinuity=!0,o.discontinuityStarts.unshift(0),(!u.segments.length&&o.timeline>u.timeline||u.segments.length&&o.timeline>u.segments[u.segments.length-1].timeline)&&o.discontinuitySequence--;return}u.segments[m].discontinuity&&!l.discontinuity&&(l.discontinuity=!0,o.discontinuityStarts.unshift(0),o.discontinuitySequence--),updateMediaSequenceForPlaylist({playlist:o,mediaSequence:u.segments[m].number})})},positionManifestOnTimeline=({oldManifest:t,newManifest:e})=>{const n=t.playlists.concat(getMediaGroupPlaylists(t)),o=e.playlists.concat(getMediaGroupPlaylists(e));return e.timelineStarts=getUniqueTimelineStarts([t.timelineStarts,e.timelineStarts]),updateSequenceNumbers({oldPlaylists:n,newPlaylists:o,timelineStarts:e.timelineStarts}),e},generateSidxKey=t=>t&&t.uri+"-"+byteRangeToString(t.byterange),mergeDiscontiguousPlaylists=t=>{const e=t.reduce(function(o,u){return o[u.attributes.baseUrl]||(o[u.attributes.baseUrl]=[]),o[u.attributes.baseUrl].push(u),o},{});let n=[];return Object.values(e).forEach(o=>{const u=values$1(o.reduce((l,m)=>{const y=m.attributes.id+(m.attributes.lang||"");return l[y]?(m.segments&&(m.segments[0]&&(m.segments[0].discontinuity=!0),l[y].segments.push(...m.segments)),m.attributes.contentProtection&&(l[y].attributes.contentProtection=m.attributes.contentProtection)):(l[y]=m,l[y].attributes.timelineStarts=[]),l[y].attributes.timelineStarts.push({start:m.attributes.periodStart,timeline:m.attributes.periodStart}),l},{}));n=n.concat(u)}),n.map(o=>(o.discontinuityStarts=findIndexes(o.segments||[],"discontinuity"),o))},addSidxSegmentsToPlaylist=(t,e)=>{const n=generateSidxKey(t.sidx),o=n&&e[n]&&e[n].sidx;return o&&addSidxSegmentsToPlaylist$1(t,o,t.sidx.resolvedUri),t},addSidxSegmentsToPlaylists=(t,e={})=>{if(!Object.keys(e).length)return t;for(const n in t)t[n]=addSidxSegmentsToPlaylist(t[n],e);return t},formatAudioPlaylist=({attributes:t,segments:e,sidx:n,mediaSequence:o,discontinuitySequence:u,discontinuityStarts:l},m)=>{const y={attributes:{NAME:t.id,BANDWIDTH:t.bandwidth,CODECS:t.codecs,"PROGRAM-ID":1},uri:"",endList:t.type==="static",timeline:t.periodStart,resolvedUri:t.baseUrl||"",targetDuration:t.duration,discontinuitySequence:u,discontinuityStarts:l,timelineStarts:t.timelineStarts,mediaSequence:o,segments:e};return t.contentProtection&&(y.contentProtection=t.contentProtection),t.serviceLocation&&(y.attributes.serviceLocation=t.serviceLocation),n&&(y.sidx=n),m&&(y.attributes.AUDIO="audio",y.attributes.SUBTITLES="subs"),y},formatVttPlaylist=({attributes:t,segments:e,mediaSequence:n,discontinuityStarts:o,discontinuitySequence:u})=>{typeof e>"u"&&(e=[{uri:t.baseUrl,timeline:t.periodStart,resolvedUri:t.baseUrl||"",duration:t.sourceDuration,number:0}],t.duration=t.sourceDuration);const l={NAME:t.id,BANDWIDTH:t.bandwidth,"PROGRAM-ID":1};t.codecs&&(l.CODECS=t.codecs);const m={attributes:l,uri:"",endList:t.type==="static",timeline:t.periodStart,resolvedUri:t.baseUrl||"",targetDuration:t.duration,timelineStarts:t.timelineStarts,discontinuityStarts:o,discontinuitySequence:u,mediaSequence:n,segments:e};return t.serviceLocation&&(m.attributes.serviceLocation=t.serviceLocation),m},organizeAudioPlaylists=(t,e={},n=!1)=>{let o;const u=t.reduce((l,m)=>{const y=m.attributes.role&&m.attributes.role.value||"",E=m.attributes.lang||"";let C=m.attributes.label||"main";if(E&&!m.attributes.label){const A=y?` (${y})`:"";C=`${m.attributes.lang}${A}`}l[C]||(l[C]={language:E,autoselect:!0,default:y==="main",playlists:[],uri:""});const k=addSidxSegmentsToPlaylist(formatAudioPlaylist(m,n),e);return l[C].playlists.push(k),typeof o>"u"&&y==="main"&&(o=m,o.default=!0),l},{});if(!o){const l=Object.keys(u)[0];u[l].default=!0}return u},organizeVttPlaylists=(t,e={})=>t.reduce((n,o)=>{const u=o.attributes.label||o.attributes.lang||"text",l=o.attributes.lang||"und";return n[u]||(n[u]={language:l,default:!1,autoselect:!1,playlists:[],uri:""}),n[u].playlists.push(addSidxSegmentsToPlaylist(formatVttPlaylist(o),e)),n},{}),organizeCaptionServices=t=>t.reduce((e,n)=>(n&&n.forEach(o=>{const{channel:u,language:l}=o;e[l]={autoselect:!1,default:!1,instreamId:u,language:l},o.hasOwnProperty("aspectRatio")&&(e[l].aspectRatio=o.aspectRatio),o.hasOwnProperty("easyReader")&&(e[l].easyReader=o.easyReader),o.hasOwnProperty("3D")&&(e[l]["3D"]=o["3D"])}),e),{}),formatVideoPlaylist=({attributes:t,segments:e,sidx:n,discontinuityStarts:o})=>{const u={attributes:{NAME:t.id,AUDIO:"audio",SUBTITLES:"subs",RESOLUTION:{width:t.width,height:t.height},CODECS:t.codecs,BANDWIDTH:t.bandwidth,"PROGRAM-ID":1},uri:"",endList:t.type==="static",timeline:t.periodStart,resolvedUri:t.baseUrl||"",targetDuration:t.duration,discontinuityStarts:o,timelineStarts:t.timelineStarts,segments:e};return t.frameRate&&(u.attributes["FRAME-RATE"]=t.frameRate),t.contentProtection&&(u.contentProtection=t.contentProtection),t.serviceLocation&&(u.attributes.serviceLocation=t.serviceLocation),n&&(u.sidx=n),u},videoOnly=({attributes:t})=>t.mimeType==="video/mp4"||t.mimeType==="video/webm"||t.contentType==="video",audioOnly=({attributes:t})=>t.mimeType==="audio/mp4"||t.mimeType==="audio/webm"||t.contentType==="audio",vttOnly=({attributes:t})=>t.mimeType==="text/vtt"||t.contentType==="text",addMediaSequenceValues=(t,e)=>{t.forEach(n=>{n.mediaSequence=0,n.discontinuitySequence=e.findIndex(function({timeline:o}){return o===n.timeline}),n.segments&&n.segments.forEach((o,u)=>{o.number=u})})},flattenMediaGroupPlaylists=t=>t?Object.keys(t).reduce((e,n)=>{const o=t[n];return e.concat(o.playlists)},[]):[],toM3u8=({dashPlaylists:t,locations:e,contentSteering:n,sidxMapping:o={},previousManifest:u,eventStream:l})=>{if(!t.length)return{};const{sourceDuration:m,type:y,suggestedPresentationDelay:E,minimumUpdatePeriod:C}=t[0].attributes,k=mergeDiscontiguousPlaylists(t.filter(videoOnly)).map(formatVideoPlaylist),A=mergeDiscontiguousPlaylists(t.filter(audioOnly)),D=mergeDiscontiguousPlaylists(t.filter(vttOnly)),P=t.map(J=>J.attributes.captionServices).filter(Boolean),R={allowCache:!0,discontinuityStarts:[],segments:[],endList:!0,mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:"",duration:m,playlists:addSidxSegmentsToPlaylists(k,o)};C>=0&&(R.minimumUpdatePeriod=C*1e3),e&&(R.locations=e),n&&(R.contentSteering=n),y==="dynamic"&&(R.suggestedPresentationDelay=E),l&&l.length>0&&(R.eventStream=l);const B=R.playlists.length===0,F=A.length?organizeAudioPlaylists(A,o,B):null,j=D.length?organizeVttPlaylists(D,o):null,N=k.concat(flattenMediaGroupPlaylists(F),flattenMediaGroupPlaylists(j)),Y=N.map(({timelineStarts:J})=>J);return R.timelineStarts=getUniqueTimelineStarts(Y),addMediaSequenceValues(N,R.timelineStarts),F&&(R.mediaGroups.AUDIO.audio=F),j&&(R.mediaGroups.SUBTITLES.subs=j),P.length&&(R.mediaGroups["CLOSED-CAPTIONS"].cc=organizeCaptionServices(P)),u?positionManifestOnTimeline({oldManifest:u,newManifest:R}):R},getLiveRValue=(t,e,n)=>{const{NOW:o,clientOffset:u,availabilityStartTime:l,timescale:m=1,periodStart:y=0,minimumUpdatePeriod:E=0}=t,C=(o+u)/1e3,k=l+y,D=C+E-k;return Math.ceil((D*m-e)/n)},parseByTimeline=(t,e)=>{const{type:n,minimumUpdatePeriod:o=0,media:u="",sourceDuration:l,timescale:m=1,startNumber:y=1,periodStart:E}=t,C=[];let k=-1;for(let A=0;A<e.length;A++){const D=e[A],P=D.d,R=D.r||0,B=D.t||0;k<0&&(k=B),B&&B>k&&(k=B);let F;if(R<0){const Y=A+1;Y===e.length?n==="dynamic"&&o>0&&u.indexOf("$Number$")>0?F=getLiveRValue(t,k,P):F=(l*m-k)/P:F=(e[Y].t-k)/P}else F=R+1;const j=y+C.length+F;let N=y+C.length;for(;N<j;)C.push({number:N,duration:P/m,time:k,timeline:E}),k+=P,N++}return C},identifierPattern=/\$([A-z]*)(?:(%0)([0-9]+)d)?\$/g,identifierReplacement=t=>(e,n,o,u)=>{if(e==="$$")return"$";if(typeof t[n]>"u")return e;const l=""+t[n];return n==="RepresentationID"||(o?u=parseInt(u,10):u=1,l.length>=u)?l:`${new Array(u-l.length+1).join("0")}${l}`},constructTemplateUrl=(t,e)=>t.replace(identifierPattern,identifierReplacement(e)),parseTemplateInfo=(t,e)=>!t.duration&&!e?[{number:t.startNumber||1,duration:t.sourceDuration,time:0,timeline:t.periodStart}]:t.duration?parseByDuration(t):parseByTimeline(t,e),segmentsFromTemplate=(t,e)=>{const n={RepresentationID:t.id,Bandwidth:t.bandwidth||0},{initialization:o={sourceURL:"",range:""}}=t,u=urlTypeToSegment({baseUrl:t.baseUrl,source:constructTemplateUrl(o.sourceURL,n),range:o.range});return parseTemplateInfo(t,e).map(m=>{n.Number=m.number,n.Time=m.time;const y=constructTemplateUrl(t.media||"",n),E=t.timescale||1,C=t.presentationTimeOffset||0,k=t.periodStart+(m.time-C)/E;return{uri:y,timeline:m.timeline,duration:m.duration,resolvedUri:resolveUrl$1(t.baseUrl||"",y),map:u,number:m.number,presentationTime:k}})},SegmentURLToSegmentObject=(t,e)=>{const{baseUrl:n,initialization:o={}}=t,u=urlTypeToSegment({baseUrl:n,source:o.sourceURL,range:o.range}),l=urlTypeToSegment({baseUrl:n,source:e.media,range:e.mediaRange});return l.map=u,l},segmentsFromList=(t,e)=>{const{duration:n,segmentUrls:o=[],periodStart:u}=t;if(!n&&!e||n&&e)throw new Error(errors$3.SEGMENT_TIME_UNSPECIFIED);const l=o.map(E=>SegmentURLToSegmentObject(t,E));let m;return n&&(m=parseByDuration(t)),e&&(m=parseByTimeline(t,e)),m.map((E,C)=>{if(l[C]){const k=l[C],A=t.timescale||1,D=t.presentationTimeOffset||0;return k.timeline=E.timeline,k.duration=E.duration,k.number=E.number,k.presentationTime=u+(E.time-D)/A,k}}).filter(E=>E)},generateSegments=({attributes:t,segmentInfo:e})=>{let n,o;e.template?(o=segmentsFromTemplate,n=merge$2(t,e.template)):e.base?(o=segmentsFromBase,n=merge$2(t,e.base)):e.list&&(o=segmentsFromList,n=merge$2(t,e.list));const u={attributes:t};if(!o)return u;const l=o(n,e.segmentTimeline);if(n.duration){const{duration:m,timescale:y=1}=n;n.duration=m/y}else l.length?n.duration=l.reduce((m,y)=>Math.max(m,Math.ceil(y.duration)),0):n.duration=0;return u.attributes=n,u.segments=l,e.base&&n.indexRange&&(u.sidx=l[0],u.segments=[]),u},toPlaylists=t=>t.map(generateSegments),findChildren=(t,e)=>from(t.childNodes).filter(({tagName:n})=>n===e),getContent=t=>t.textContent.trim(),parseDivisionValue=t=>parseFloat(t.split("/").reduce((e,n)=>e/n)),parseDuration=t=>{const y=/P(?:(\d*)Y)?(?:(\d*)M)?(?:(\d*)D)?(?:T(?:(\d*)H)?(?:(\d*)M)?(?:([\d.]*)S)?)?/.exec(t);if(!y)return 0;const[E,C,k,A,D,P]=y.slice(1);return parseFloat(E||0)*31536e3+parseFloat(C||0)*2592e3+parseFloat(k||0)*86400+parseFloat(A||0)*3600+parseFloat(D||0)*60+parseFloat(P||0)},parseDate$1=t=>(/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/.test(t)&&(t+="Z"),Date.parse(t)),parsers={mediaPresentationDuration(t){return parseDuration(t)},availabilityStartTime(t){return parseDate$1(t)/1e3},minimumUpdatePeriod(t){return parseDuration(t)},suggestedPresentationDelay(t){return parseDuration(t)},type(t){return t},timeShiftBufferDepth(t){return parseDuration(t)},start(t){return parseDuration(t)},width(t){return parseInt(t,10)},height(t){return parseInt(t,10)},bandwidth(t){return parseInt(t,10)},frameRate(t){return parseDivisionValue(t)},startNumber(t){return parseInt(t,10)},timescale(t){return parseInt(t,10)},presentationTimeOffset(t){return parseInt(t,10)},duration(t){const e=parseInt(t,10);return isNaN(e)?parseDuration(t):e},d(t){return parseInt(t,10)},t(t){return parseInt(t,10)},r(t){return parseInt(t,10)},presentationTime(t){return parseInt(t,10)},DEFAULT(t){return t}},parseAttributes=t=>t&&t.attributes?from(t.attributes).reduce((e,n)=>{const o=parsers[n.name]||parsers.DEFAULT;return e[n.name]=o(n.value),e},{}):{},keySystemsMap={"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"},buildBaseUrls=(t,e)=>e.length?flatten(t.map(function(n){return e.map(function(o){const u=getContent(o),l=resolveUrl$1(n.baseUrl,u),m=merge$2(parseAttributes(o),{baseUrl:l});return l!==u&&!m.serviceLocation&&n.serviceLocation&&(m.serviceLocation=n.serviceLocation),m})})):t,getSegmentInformation=t=>{const e=findChildren(t,"SegmentTemplate")[0],n=findChildren(t,"SegmentList")[0],o=n&&findChildren(n,"SegmentURL").map(A=>merge$2({tag:"SegmentURL"},parseAttributes(A))),u=findChildren(t,"SegmentBase")[0],l=n||e,m=l&&findChildren(l,"SegmentTimeline")[0],y=n||u||e,E=y&&findChildren(y,"Initialization")[0],C=e&&parseAttributes(e);C&&E?C.initialization=E&&parseAttributes(E):C&&C.initialization&&(C.initialization={sourceURL:C.initialization});const k={template:C,segmentTimeline:m&&findChildren(m,"S").map(A=>parseAttributes(A)),list:n&&merge$2(parseAttributes(n),{segmentUrls:o,initialization:parseAttributes(E)}),base:u&&merge$2(parseAttributes(u),{initialization:parseAttributes(E)})};return Object.keys(k).forEach(A=>{k[A]||delete k[A]}),k},inheritBaseUrls=(t,e,n)=>o=>{const u=findChildren(o,"BaseURL"),l=buildBaseUrls(e,u),m=merge$2(t,parseAttributes(o)),y=getSegmentInformation(o);return l.map(E=>({segmentInfo:merge$2(n,y),attributes:merge$2(m,E)}))},generateKeySystemInformation=t=>t.reduce((e,n)=>{const o=parseAttributes(n);o.schemeIdUri&&(o.schemeIdUri=o.schemeIdUri.toLowerCase());const u=keySystemsMap[o.schemeIdUri];if(u){e[u]={attributes:o};const l=findChildren(n,"cenc:pssh")[0];if(l){const m=getContent(l);e[u].pssh=m&&decodeB64ToUint8Array(m)}}return e},{}),parseCaptionServiceMetadata=t=>{if(t.schemeIdUri==="urn:scte:dash:cc:cea-608:2015")return(typeof t.value!="string"?[]:t.value.split(";")).map(n=>{let o,u;return u=n,/^CC\d=/.test(n)?[o,u]=n.split("="):/^CC\d$/.test(n)&&(o=n),{channel:o,language:u}});if(t.schemeIdUri==="urn:scte:dash:cc:cea-708:2015")return(typeof t.value!="string"?[]:t.value.split(";")).map(n=>{const o={channel:void 0,language:void 0,aspectRatio:1,easyReader:0,"3D":0};if(/=/.test(n)){const[u,l=""]=n.split("=");o.channel=u,o.language=n,l.split(",").forEach(m=>{const[y,E]=m.split(":");y==="lang"?o.language=E:y==="er"?o.easyReader=Number(E):y==="war"?o.aspectRatio=Number(E):y==="3D"&&(o["3D"]=Number(E))})}else o.language=n;return o.channel&&(o.channel="SERVICE"+o.channel),o})},toEventStream=t=>flatten(findChildren(t.node,"EventStream").map(e=>{const n=parseAttributes(e),o=n.schemeIdUri;return findChildren(e,"Event").map(u=>{const l=parseAttributes(u),m=l.presentationTime||0,y=n.timescale||1,E=l.duration||0,C=m/y+t.attributes.start;return{schemeIdUri:o,value:n.value,id:l.id,start:C,end:C+E/y,messageData:getContent(u)||l.messageData,contentEncoding:n.contentEncoding,presentationTimeOffset:n.presentationTimeOffset||0}})})),toRepresentations=(t,e,n)=>o=>{const u=parseAttributes(o),l=buildBaseUrls(e,findChildren(o,"BaseURL")),m=findChildren(o,"Role")[0],y={role:parseAttributes(m)};let E=merge$2(t,u,y);const C=findChildren(o,"Accessibility")[0],k=parseCaptionServiceMetadata(parseAttributes(C));k&&(E=merge$2(E,{captionServices:k}));const A=findChildren(o,"Label")[0];if(A&&A.childNodes.length){const F=A.childNodes[0].nodeValue.trim();E=merge$2(E,{label:F})}const D=generateKeySystemInformation(findChildren(o,"ContentProtection"));Object.keys(D).length&&(E=merge$2(E,{contentProtection:D}));const P=getSegmentInformation(o),R=findChildren(o,"Representation"),B=merge$2(n,P);return flatten(R.map(inheritBaseUrls(E,l,B)))},toAdaptationSets=(t,e)=>(n,o)=>{const u=buildBaseUrls(e,findChildren(n.node,"BaseURL")),l=merge$2(t,{periodStart:n.attributes.start});typeof n.attributes.duration=="number"&&(l.periodDuration=n.attributes.duration);const m=findChildren(n.node,"AdaptationSet"),y=getSegmentInformation(n.node);return flatten(m.map(toRepresentations(l,u,y)))},generateContentSteeringInformation=(t,e)=>{if(t.length>1&&e({type:"warn",message:"The MPD manifest should contain no more than one ContentSteering tag"}),!t.length)return null;const n=merge$2({serverURL:getContent(t[0])},parseAttributes(t[0]));return n.queryBeforeStart=n.queryBeforeStart==="true",n},getPeriodStart=({attributes:t,priorPeriodAttributes:e,mpdType:n})=>typeof t.start=="number"?t.start:e&&typeof e.start=="number"&&typeof e.duration=="number"?e.start+e.duration:!e&&n==="static"?0:null,inheritAttributes=(t,e={})=>{const{manifestUri:n="",NOW:o=Date.now(),clientOffset:u=0,eventHandler:l=function(){}}=e,m=findChildren(t,"Period");if(!m.length)throw new Error(errors$3.INVALID_NUMBER_OF_PERIOD);const y=findChildren(t,"Location"),E=parseAttributes(t),C=buildBaseUrls([{baseUrl:n}],findChildren(t,"BaseURL")),k=findChildren(t,"ContentSteering");E.type=E.type||"static",E.sourceDuration=E.mediaPresentationDuration||0,E.NOW=o,E.clientOffset=u,y.length&&(E.locations=y.map(getContent));const A=[];return m.forEach((D,P)=>{const R=parseAttributes(D),B=A[P-1];R.start=getPeriodStart({attributes:R,priorPeriodAttributes:B?B.attributes:null,mpdType:E.type}),A.push({node:D,attributes:R})}),{locations:E.locations,contentSteeringInfo:generateContentSteeringInformation(k,l),representationInfo:flatten(A.map(toAdaptationSets(E,C))),eventStream:flatten(A.map(toEventStream))}},stringToMpdXml=t=>{if(t==="")throw new Error(errors$3.DASH_EMPTY_MANIFEST);const e=new DOMParser;let n,o;try{n=e.parseFromString(t,"application/xml"),o=n&&n.documentElement.tagName==="MPD"?n.documentElement:null}catch{}if(!o||o&&o.getElementsByTagName("parsererror").length>0)throw new Error(errors$3.DASH_INVALID_XML);return o},parseUTCTimingScheme=t=>{const e=findChildren(t,"UTCTiming")[0];if(!e)return null;const n=parseAttributes(e);switch(n.schemeIdUri){case"urn:mpeg:dash:utc:http-head:2014":case"urn:mpeg:dash:utc:http-head:2012":n.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":n.method="GET";break;case"urn:mpeg:dash:utc:direct:2014":case"urn:mpeg:dash:utc:direct:2012":n.method="DIRECT",n.value=Date.parse(n.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(errors$3.UNSUPPORTED_UTC_TIMING_SCHEME)}return n},parse$4=(t,e={})=>{const n=inheritAttributes(stringToMpdXml(t),e),o=toPlaylists(n.representationInfo);return toM3u8({dashPlaylists:o,locations:n.locations,contentSteering:n.contentSteeringInfo,sidxMapping:e.sidxMapping,previousManifest:e.previousManifest,eventStream:n.eventStream})},parseUTCTiming=t=>parseUTCTimingScheme(stringToMpdXml(t));var MAX_UINT32$1=Math.pow(2,32),getUint64$1=function(t){var e=new DataView(t.buffer,t.byteOffset,t.byteLength),n;return e.getBigUint64?(n=e.getBigUint64(0),n<Number.MAX_SAFE_INTEGER?Number(n):n):e.getUint32(0)*MAX_UINT32$1+e.getUint32(4)},numbers={getUint64:getUint64$1,MAX_UINT32:MAX_UINT32$1},getUint64=numbers.getUint64,parseSidx=function(t){var e=new DataView(t.buffer,t.byteOffset,t.byteLength),n={version:t[0],flags:new Uint8Array(t.subarray(1,4)),references:[],referenceId:e.getUint32(4),timescale:e.getUint32(8)},o=12;n.version===0?(n.earliestPresentationTime=e.getUint32(o),n.firstOffset=e.getUint32(o+4),o+=8):(n.earliestPresentationTime=getUint64(t.subarray(o)),n.firstOffset=getUint64(t.subarray(o+8)),o+=16),o+=2;var u=e.getUint16(o);for(o+=2;u>0;o+=12,u--)n.references.push({referenceType:(t[o]&128)>>>7,referencedSize:e.getUint32(o)&2147483647,subsegmentDuration:e.getUint32(o+4),startsWithSap:!!(t[o+8]&128),sapType:(t[o+8]&112)>>>4,sapDeltaTime:e.getUint32(o+8)&268435455});return n},parseSidx_1=parseSidx;const parseSidx$1=getDefaultExportFromCjs$1(parseSidx_1);var ID3=toUint8([73,68,51]),getId3Size=function(e,n){n===void 0&&(n=0),e=toUint8(e);var o=e[n+5],u=e[n+6]<<21|e[n+7]<<14|e[n+8]<<7|e[n+9],l=(o&16)>>4;return l?u+20:u+10},getId3Offset=function t(e,n){return n===void 0&&(n=0),e=toUint8(e),e.length-n<10||!bytesMatch(e,ID3,{offset:n})?n:(n+=getId3Size(e,n),t(e,n))},normalizePath$1=function(e){return typeof e=="string"?stringToBytes(e):e},normalizePaths$1=function(e){return Array.isArray(e)?e.map(function(n){return normalizePath$1(n)}):[normalizePath$1(e)]},findBox=function t(e,n,o){o===void 0&&(o=!1),n=normalizePaths$1(n),e=toUint8(e);var u=[];if(!n.length)return u;for(var l=0;l<e.length;){var m=(e[l]<<24|e[l+1]<<16|e[l+2]<<8|e[l+3])>>>0,y=e.subarray(l+4,l+8);if(m===0)break;var E=l+m;if(E>e.length){if(o)break;E=e.length}var C=e.subarray(l+8,E);bytesMatch(y,n[0])&&(n.length===1?u.push(C):u.push.apply(u,t(C,n.slice(1),o))),l=E}return u},EBML_TAGS={EBML:toUint8([26,69,223,163]),DocType:toUint8([66,130]),Segment:toUint8([24,83,128,103]),SegmentInfo:toUint8([21,73,169,102]),Tracks:toUint8([22,84,174,107]),Track:toUint8([174]),TrackNumber:toUint8([215]),DefaultDuration:toUint8([35,227,131]),TrackEntry:toUint8([174]),TrackType:toUint8([131]),FlagDefault:toUint8([136]),CodecID:toUint8([134]),CodecPrivate:toUint8([99,162]),VideoTrack:toUint8([224]),AudioTrack:toUint8([225]),Cluster:toUint8([31,67,182,117]),Timestamp:toUint8([231]),TimestampScale:toUint8([42,215,177]),BlockGroup:toUint8([160]),BlockDuration:toUint8([155]),Block:toUint8([161]),SimpleBlock:toUint8([163])},LENGTH_TABLE=[128,64,32,16,8,4,2,1],getLength$1=function(e){for(var n=1,o=0;o<LENGTH_TABLE.length&&!(e&LENGTH_TABLE[o]);o++)n++;return n},getvint=function(e,n,o,u){o===void 0&&(o=!0),u===void 0&&(u=!1);var l=getLength$1(e[n]),m=e.subarray(n,n+l);return o&&(m=Array.prototype.slice.call(e,n,n+l),m[0]^=LENGTH_TABLE[l-1]),{length:l,value:bytesToNumber(m,{signed:u}),bytes:m}},normalizePath=function t(e){return typeof e=="string"?e.match(/.{1,2}/g).map(function(n){return t(n)}):typeof e=="number"?numberToBytes(e):e},normalizePaths=function(e){return Array.isArray(e)?e.map(function(n){return normalizePath(n)}):[normalizePath(e)]},getInfinityDataSize=function t(e,n,o){if(o>=n.length)return n.length;var u=getvint(n,o,!1);if(bytesMatch(e.bytes,u.bytes))return o;var l=getvint(n,o+u.length);return t(e,n,o+l.length+l.value+u.length)},findEbml=function t(e,n){n=normalizePaths(n),e=toUint8(e);var o=[];if(!n.length)return o;for(var u=0;u<e.length;){var l=getvint(e,u,!1),m=getvint(e,u+l.length),y=u+l.length+m.length;m.value===127&&(m.value=getInfinityDataSize(l,e,y),m.value!==e.length&&(m.value-=y));var E=y+m.value>e.length?e.length:y+m.value,C=e.subarray(y,E);bytesMatch(n[0],l.bytes)&&(n.length===1?o.push(C):o=o.concat(t(C,n.slice(1))));var k=l.length+m.length+C.length;u+=k}return o},NAL_TYPE_ONE=toUint8([0,0,0,1]),NAL_TYPE_TWO=toUint8([0,0,1]),EMULATION_PREVENTION=toUint8([0,0,3]),discardEmulationPreventionBytes=function(e){for(var n=[],o=1;o<e.length-2;)bytesMatch(e.subarray(o,o+3),EMULATION_PREVENTION)&&(n.push(o+2),o++),o++;if(n.length===0)return e;var u=e.length-n.length,l=new Uint8Array(u),m=0;for(o=0;o<u;m++,o++)m===n[0]&&(m++,n.shift()),l[o]=e[m];return l},findNal=function(e,n,o,u){e=toUint8(e),o=[].concat(o);for(var l=0,m,y=0;l<e.length&&(y<u||m);){var E=void 0;if(bytesMatch(e.subarray(l),NAL_TYPE_ONE)?E=4:bytesMatch(e.subarray(l),NAL_TYPE_TWO)&&(E=3),!E){l++;continue}if(y++,m)return discardEmulationPreventionBytes(e.subarray(m,l));var C=void 0;n==="h264"?C=e[l+E]&31:n==="h265"&&(C=e[l+E]>>1&63),o.indexOf(C)!==-1&&(m=l+E),l+=E+(n==="h264"?1:2)}return e.subarray(0,0)},findH264Nal=function(e,n,o){return findNal(e,"h264",n,o)},findH265Nal=function(e,n,o){return findNal(e,"h265",n,o)},CONSTANTS={webm:toUint8([119,101,98,109]),matroska:toUint8([109,97,116,114,111,115,107,97]),flac:toUint8([102,76,97,67]),ogg:toUint8([79,103,103,83]),ac3:toUint8([11,119]),riff:toUint8([82,73,70,70]),avi:toUint8([65,86,73]),wav:toUint8([87,65,86,69]),"3gp":toUint8([102,116,121,112,51,103]),mp4:toUint8([102,116,121,112]),fmp4:toUint8([115,116,121,112]),mov:toUint8([102,116,121,112,113,116]),moov:toUint8([109,111,111,118]),moof:toUint8([109,111,111,102])},_isLikely={aac:function(e){var n=getId3Offset(e);return bytesMatch(e,[255,16],{offset:n,mask:[255,22]})},mp3:function(e){var n=getId3Offset(e);return bytesMatch(e,[255,2],{offset:n,mask:[255,6]})},webm:function(e){var n=findEbml(e,[EBML_TAGS.EBML,EBML_TAGS.DocType])[0];return bytesMatch(n,CONSTANTS.webm)},mkv:function(e){var n=findEbml(e,[EBML_TAGS.EBML,EBML_TAGS.DocType])[0];return bytesMatch(n,CONSTANTS.matroska)},mp4:function(e){if(_isLikely["3gp"](e)||_isLikely.mov(e))return!1;if(bytesMatch(e,CONSTANTS.mp4,{offset:4})||bytesMatch(e,CONSTANTS.fmp4,{offset:4})||bytesMatch(e,CONSTANTS.moof,{offset:4})||bytesMatch(e,CONSTANTS.moov,{offset:4}))return!0},mov:function(e){return bytesMatch(e,CONSTANTS.mov,{offset:4})},"3gp":function(e){return bytesMatch(e,CONSTANTS["3gp"],{offset:4})},ac3:function(e){var n=getId3Offset(e);return bytesMatch(e,CONSTANTS.ac3,{offset:n})},ts:function(e){if(e.length<189&&e.length>=1)return e[0]===71;for(var n=0;n+188<e.length&&n<188;){if(e[n]===71&&e[n+188]===71)return!0;n+=1}return!1},flac:function(e){var n=getId3Offset(e);return bytesMatch(e,CONSTANTS.flac,{offset:n})},ogg:function(e){return bytesMatch(e,CONSTANTS.ogg)},avi:function(e){return bytesMatch(e,CONSTANTS.riff)&&bytesMatch(e,CONSTANTS.avi,{offset:8})},wav:function(e){return bytesMatch(e,CONSTANTS.riff)&&bytesMatch(e,CONSTANTS.wav,{offset:8})},h264:function(e){return findH264Nal(e,7,3).length},h265:function(e){return findH265Nal(e,[32,33],3).length}},isLikelyTypes=Object.keys(_isLikely).filter(function(t){return t!=="ts"&&t!=="h264"&&t!=="h265"}).concat(["ts","h264","h265"]);isLikelyTypes.forEach(function(t){var e=_isLikely[t];_isLikely[t]=function(n){return e(toUint8(n))}});var isLikely=_isLikely,detectContainerForBytes=function(e){e=toUint8(e);for(var n=0;n<isLikelyTypes.length;n++){var o=isLikelyTypes[n];if(isLikely[o](e))return o}return""},isLikelyFmp4MediaSegment=function(e){return findBox(e,["moof"]).length>0},ONE_SECOND_IN_TS=9e4,secondsToVideoTs,secondsToAudioTs,videoTsToSeconds,audioTsToSeconds,audioTsToVideoTs,videoTsToAudioTs,metadataTsToSeconds;secondsToVideoTs=function(t){return t*ONE_SECOND_IN_TS},secondsToAudioTs=function(t,e){return t*e},videoTsToSeconds=function(t){return t/ONE_SECOND_IN_TS},audioTsToSeconds=function(t,e){return t/e},audioTsToVideoTs=function(t,e){return secondsToVideoTs(audioTsToSeconds(t,e))},videoTsToAudioTs=function(t,e){return secondsToAudioTs(videoTsToSeconds(t),e)},metadataTsToSeconds=function(t,e,n){return videoTsToSeconds(n?t:t-e)};var clock={ONE_SECOND_IN_TS,secondsToVideoTs,secondsToAudioTs,videoTsToSeconds,audioTsToSeconds,audioTsToVideoTs,videoTsToAudioTs,metadataTsToSeconds},version$6="8.18.1";const hooks_={},hooks=function(t,e){return hooks_[t]=hooks_[t]||[],e&&(hooks_[t]=hooks_[t].concat(e)),hooks_[t]},hook=function(t,e){hooks(t,e)},removeHook=function(t,e){const n=hooks(t).indexOf(e);return n<=-1?!1:(hooks_[t]=hooks_[t].slice(),hooks_[t].splice(n,1),!0)},hookOnce=function(t,e){hooks(t,[].concat(e).map(n=>{const o=(...u)=>(removeHook(t,o),n(...u));return o}))},FullscreenApi={prefixed:!0},apiMap=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror","fullscreen"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror","-webkit-full-screen"]],specApi=apiMap[0];let browserApi;for(let t=0;t<apiMap.length;t++)if(apiMap[t][1]in document$1$1){browserApi=apiMap[t];break}if(browserApi){for(let t=0;t<browserApi.length;t++)FullscreenApi[specApi[t]]=browserApi[t];FullscreenApi.prefixed=browserApi[0]!==specApi[0]}let history=[];const LogByTypeFactory=(t,e,n)=>(o,u,l)=>{const m=e.levels[u],y=new RegExp(`^(${m})$`);let E=t;if(o!=="log"&&l.unshift(o.toUpperCase()+":"),n&&(E=`%c${t}`,l.unshift(n)),l.unshift(E+":"),history){history.push([].concat(l));const k=history.length-1e3;history.splice(0,k>0?k:0)}if(!window$1$1.console)return;let C=window$1$1.console[o];!C&&o==="debug"&&(C=window$1$1.console.info||window$1$1.console.log),!(!C||!m||!y.test(o))&&C[Array.isArray(l)?"apply":"call"](window$1$1.console,l)};function createLogger$1(t,e=":",n=""){let o="info",u;function l(...m){u("log",o,m)}return u=LogByTypeFactory(t,l,n),l.createLogger=(m,y,E)=>{const C=y!==void 0?y:e,k=E!==void 0?E:n,A=`${t} ${C} ${m}`;return createLogger$1(A,C,k)},l.createNewLogger=(m,y,E)=>createLogger$1(m,y,E),l.levels={all:"debug|log|warn|error",off:"",debug:"debug|log|warn|error",info:"log|warn|error",warn:"warn|error",error:"error",DEFAULT:o},l.level=m=>{if(typeof m=="string"){if(!l.levels.hasOwnProperty(m))throw new Error(`"${m}" in not a valid log level`);o=m}return o},l.history=()=>history?[].concat(history):[],l.history.filter=m=>(history||[]).filter(y=>new RegExp(`.*${m}.*`).test(y[0])),l.history.clear=()=>{history&&(history.length=0)},l.history.disable=()=>{history!==null&&(history.length=0,history=null)},l.history.enable=()=>{history===null&&(history=[])},l.error=(...m)=>u("error",o,m),l.warn=(...m)=>u("warn",o,m),l.debug=(...m)=>u("debug",o,m),l}const log$1=createLogger$1("VIDEOJS"),createLogger=log$1.createLogger,toString$1=Object.prototype.toString,keys=function(t){return isObject$1(t)?Object.keys(t):[]};function each(t,e){keys(t).forEach(n=>e(t[n],n))}function reduce(t,e,n=0){return keys(t).reduce((o,u)=>e(o,t[u],u),n)}function isObject$1(t){return!!t&&typeof t=="object"}function isPlain(t){return isObject$1(t)&&toString$1.call(t)==="[object Object]"&&t.constructor===Object}function merge$1(...t){const e={};return t.forEach(n=>{n&&each(n,(o,u)=>{if(!isPlain(o)){e[u]=o;return}isPlain(e[u])||(e[u]={}),e[u]=merge$1(e[u],o)})}),e}function values(t={}){const e=[];for(const n in t)if(t.hasOwnProperty(n)){const o=t[n];e.push(o)}return e}function defineLazyProperty(t,e,n,o=!0){const u=m=>Object.defineProperty(t,e,{value:m,enumerable:!0,writable:!0}),l={configurable:!0,enumerable:!0,get(){const m=n();return u(m),m}};return o&&(l.set=u),Object.defineProperty(t,e,l)}var Obj=Object.freeze({__proto__:null,each,reduce,isObject:isObject$1,isPlain,merge:merge$1,values,defineLazyProperty});let IS_IPOD=!1,IOS_VERSION=null,IS_ANDROID=!1,ANDROID_VERSION,IS_FIREFOX=!1,IS_EDGE=!1,IS_CHROMIUM=!1,IS_CHROME=!1,CHROMIUM_VERSION=null,CHROME_VERSION=null;const IS_CHROMECAST_RECEIVER=!!(window$1$1.cast&&window$1$1.cast.framework&&window$1$1.cast.framework.CastReceiverContext);let IE_VERSION=null,IS_SAFARI=!1,IS_WINDOWS=!1,IS_IPAD=!1,IS_IPHONE=!1,IS_TIZEN=!1,IS_WEBOS=!1,IS_SMART_TV=!1;const TOUCH_ENABLED=!!(isReal()&&("ontouchstart"in window$1$1||window$1$1.navigator.maxTouchPoints||window$1$1.DocumentTouch&&window$1$1.document instanceof window$1$1.DocumentTouch)),UAD=window$1$1.navigator&&window$1$1.navigator.userAgentData;if(UAD&&UAD.platform&&UAD.brands&&(IS_ANDROID=UAD.platform==="Android",IS_EDGE=!!UAD.brands.find(t=>t.brand==="Microsoft Edge"),IS_CHROMIUM=!!UAD.brands.find(t=>t.brand==="Chromium"),IS_CHROME=!IS_EDGE&&IS_CHROMIUM,CHROMIUM_VERSION=CHROME_VERSION=(UAD.brands.find(t=>t.brand==="Chromium")||{}).version||null,IS_WINDOWS=UAD.platform==="Windows"),!IS_CHROMIUM){const t=window$1$1.navigator&&window$1$1.navigator.userAgent||"";IS_IPOD=/iPod/i.test(t),IOS_VERSION=function(){const e=t.match(/OS (\d+)_/i);return e&&e[1]?e[1]:null}(),IS_ANDROID=/Android/i.test(t),ANDROID_VERSION=function(){const e=t.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!e)return null;const n=e[1]&&parseFloat(e[1]),o=e[2]&&parseFloat(e[2]);return n&&o?parseFloat(e[1]+"."+e[2]):n||null}(),IS_FIREFOX=/Firefox/i.test(t),IS_EDGE=/Edg/i.test(t),IS_CHROMIUM=/Chrome/i.test(t)||/CriOS/i.test(t),IS_CHROME=!IS_EDGE&&IS_CHROMIUM,CHROMIUM_VERSION=CHROME_VERSION=function(){const e=t.match(/(Chrome|CriOS)\/(\d+)/);return e&&e[2]?parseFloat(e[2]):null}(),IE_VERSION=function(){const e=/MSIE\s(\d+)\.\d/.exec(t);let n=e&&parseFloat(e[1]);return!n&&/Trident\/7.0/i.test(t)&&/rv:11.0/.test(t)&&(n=11),n}(),IS_TIZEN=/Tizen/i.test(t),IS_WEBOS=/Web0S/i.test(t),IS_SMART_TV=IS_TIZEN||IS_WEBOS,IS_SAFARI=/Safari/i.test(t)&&!IS_CHROME&&!IS_ANDROID&&!IS_EDGE&&!IS_SMART_TV,IS_WINDOWS=/Windows/i.test(t),IS_IPAD=/iPad/i.test(t)||IS_SAFARI&&TOUCH_ENABLED&&!/iPhone/i.test(t),IS_IPHONE=/iPhone/i.test(t)&&!IS_IPAD}const IS_IOS=IS_IPHONE||IS_IPAD||IS_IPOD,IS_ANY_SAFARI=(IS_SAFARI||IS_IOS)&&!IS_CHROME;var browser$f=Object.freeze({__proto__:null,get IS_IPOD(){return IS_IPOD},get IOS_VERSION(){return IOS_VERSION},get IS_ANDROID(){return IS_ANDROID},get ANDROID_VERSION(){return ANDROID_VERSION},get IS_FIREFOX(){return IS_FIREFOX},get IS_EDGE(){return IS_EDGE},get IS_CHROMIUM(){return IS_CHROMIUM},get IS_CHROME(){return IS_CHROME},get CHROMIUM_VERSION(){return CHROMIUM_VERSION},get CHROME_VERSION(){return CHROME_VERSION},IS_CHROMECAST_RECEIVER,get IE_VERSION(){return IE_VERSION},get IS_SAFARI(){return IS_SAFARI},get IS_WINDOWS(){return IS_WINDOWS},get IS_IPAD(){return IS_IPAD},get IS_IPHONE(){return IS_IPHONE},get IS_TIZEN(){return IS_TIZEN},get IS_WEBOS(){return IS_WEBOS},get IS_SMART_TV(){return IS_SMART_TV},TOUCH_ENABLED,IS_IOS,IS_ANY_SAFARI});function isNonBlankString(t){return typeof t=="string"&&!!t.trim()}function throwIfWhitespace(t){if(t.indexOf(" ")>=0)throw new Error("class has illegal whitespace characters")}function isReal(){return document$1$1===window$1$1.document}function isEl(t){return isObject$1(t)&&t.nodeType===1}function isInFrame(){try{return window$1$1.parent!==window$1$1.self}catch{return!0}}function createQuerier(t){return function(e,n){if(!isNonBlankString(e))return document$1$1[t](null);isNonBlankString(n)&&(n=document$1$1.querySelector(n));const o=isEl(n)?n:document$1$1;return o[t]&&o[t](e)}}function createEl(t="div",e={},n={},o){const u=document$1$1.createElement(t);return Object.getOwnPropertyNames(e).forEach(function(l){const m=e[l];l==="textContent"?textContent(u,m):(u[l]!==m||l==="tabIndex")&&(u[l]=m)}),Object.getOwnPropertyNames(n).forEach(function(l){u.setAttribute(l,n[l])}),o&&appendContent(u,o),u}function textContent(t,e){return typeof t.textContent>"u"?t.innerText=e:t.textContent=e,t}function prependTo(t,e){e.firstChild?e.insertBefore(t,e.firstChild):e.appendChild(t)}function hasClass(t,e){return throwIfWhitespace(e),t.classList.contains(e)}function addClass(t,...e){return t.classList.add(...e.reduce((n,o)=>n.concat(o.split(/\s+/)),[])),t}function removeClass(t,...e){return t?(t.classList.remove(...e.reduce((n,o)=>n.concat(o.split(/\s+/)),[])),t):(log$1.warn("removeClass was called with an element that doesn't exist"),null)}function toggleClass(t,e,n){return typeof n=="function"&&(n=n(t,e)),typeof n!="boolean"&&(n=void 0),e.split(/\s+/).forEach(o=>t.classList.toggle(o,n)),t}function setAttributes(t,e){Object.getOwnPropertyNames(e).forEach(function(n){const o=e[n];o===null||typeof o>"u"||o===!1?t.removeAttribute(n):t.setAttribute(n,o===!0?"":o)})}function getAttributes(t){const e={},n=["autoplay","controls","playsinline","loop","muted","default","defaultMuted"];if(t&&t.attributes&&t.attributes.length>0){const o=t.attributes;for(let u=o.length-1;u>=0;u--){const l=o[u].name;let m=o[u].value;n.includes(l)&&(m=m!==null),e[l]=m}}return e}function getAttribute(t,e){return t.getAttribute(e)}function setAttribute(t,e,n){t.setAttribute(e,n)}function removeAttribute(t,e){t.removeAttribute(e)}function blockTextSelection(){document$1$1.body.focus(),document$1$1.onselectstart=function(){return!1}}function unblockTextSelection(){document$1$1.onselectstart=function(){return!0}}function getBoundingClientRect(t){if(t&&t.getBoundingClientRect&&t.parentNode){const e=t.getBoundingClientRect(),n={};return["bottom","height","left","right","top","width"].forEach(o=>{e[o]!==void 0&&(n[o]=e[o])}),n.height||(n.height=parseFloat(computedStyle(t,"height"))),n.width||(n.width=parseFloat(computedStyle(t,"width"))),n}}function findPosition(t){if(!t||t&&!t.offsetParent)return{left:0,top:0,width:0,height:0};const e=t.offsetWidth,n=t.offsetHeight;let o=0,u=0;for(;t.offsetParent&&t!==document$1$1[FullscreenApi.fullscreenElement];)o+=t.offsetLeft,u+=t.offsetTop,t=t.offsetParent;return{left:o,top:u,width:e,height:n}}function getPointerPosition(t,e){const n={x:0,y:0};if(IS_IOS){let k=t;for(;k&&k.nodeName.toLowerCase()!=="html";){const A=computedStyle(k,"transform");if(/^matrix/.test(A)){const D=A.slice(7,-1).split(/,\s/).map(Number);n.x+=D[4],n.y+=D[5]}else if(/^matrix3d/.test(A)){const D=A.slice(9,-1).split(/,\s/).map(Number);n.x+=D[12],n.y+=D[13]}if(k.assignedSlot&&k.assignedSlot.parentElement&&window$1$1.WebKitCSSMatrix){const D=window$1$1.getComputedStyle(k.assignedSlot.parentElement).transform,P=new window$1$1.WebKitCSSMatrix(D);n.x+=P.m41,n.y+=P.m42}k=k.parentNode||k.host}}const o={},u=findPosition(e.target),l=findPosition(t),m=l.width,y=l.height;let E=e.offsetY-(l.top-u.top),C=e.offsetX-(l.left-u.left);return e.changedTouches&&(C=e.changedTouches[0].pageX-l.left,E=e.changedTouches[0].pageY+l.top,IS_IOS&&(C-=n.x,E-=n.y)),o.y=1-Math.max(0,Math.min(1,E/y)),o.x=Math.max(0,Math.min(1,C/m)),o}function isTextNode(t){return isObject$1(t)&&t.nodeType===3}function emptyEl(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function normalizeContent(t){return typeof t=="function"&&(t=t()),(Array.isArray(t)?t:[t]).map(e=>{if(typeof e=="function"&&(e=e()),isEl(e)||isTextNode(e))return e;if(typeof e=="string"&&/\S/.test(e))return document$1$1.createTextNode(e)}).filter(e=>e)}function appendContent(t,e){return normalizeContent(e).forEach(n=>t.appendChild(n)),t}function insertContent(t,e){return appendContent(emptyEl(t),e)}function isSingleLeftClick(t){return t.button===void 0&&t.buttons===void 0||t.button===0&&t.buttons===void 0||t.type==="mouseup"&&t.button===0&&t.buttons===0||t.type==="mousedown"&&t.button===0&&t.buttons===0?!0:!(t.button!==0||t.buttons!==1)}const $=createQuerier("querySelector"),$$=createQuerier("querySelectorAll");function computedStyle(t,e){if(!t||!e)return"";if(typeof window$1$1.getComputedStyle=="function"){let n;try{n=window$1$1.getComputedStyle(t)}catch{return""}return n?n.getPropertyValue(e)||n[e]:""}return""}function copyStyleSheetsToWindow(t){[...document$1$1.styleSheets].forEach(e=>{try{const n=[...e.cssRules].map(u=>u.cssText).join(""),o=document$1$1.createElement("style");o.textContent=n,t.document.head.appendChild(o)}catch{const o=document$1$1.createElement("link");o.rel="stylesheet",o.type=e.type,o.media=e.media.mediaText,o.href=e.href,t.document.head.appendChild(o)}})}var Dom=Object.freeze({__proto__:null,isReal,isEl,isInFrame,createEl,textContent,prependTo,hasClass,addClass,removeClass,toggleClass,setAttributes,getAttributes,getAttribute,setAttribute,removeAttribute,blockTextSelection,unblockTextSelection,getBoundingClientRect,findPosition,getPointerPosition,isTextNode,emptyEl,normalizeContent,appendContent,insertContent,isSingleLeftClick,$,$$,computedStyle,copyStyleSheetsToWindow});let _windowLoaded=!1,videojs$1;const autoSetup=function(){if(videojs$1.options.autoSetup===!1)return;const t=Array.prototype.slice.call(document$1$1.getElementsByTagName("video")),e=Array.prototype.slice.call(document$1$1.getElementsByTagName("audio")),n=Array.prototype.slice.call(document$1$1.getElementsByTagName("video-js")),o=t.concat(e,n);if(o&&o.length>0)for(let u=0,l=o.length;u<l;u++){const m=o[u];if(m&&m.getAttribute)m.player===void 0&&m.getAttribute("data-setup")!==null&&videojs$1(m);else{autoSetupTimeout(1);break}}else _windowLoaded||autoSetupTimeout(1)};function autoSetupTimeout(t,e){isReal()&&(e&&(videojs$1=e),window$1$1.setTimeout(autoSetup,t))}function setWindowLoaded(){_windowLoaded=!0,window$1$1.removeEventListener("load",setWindowLoaded)}isReal()&&(document$1$1.readyState==="complete"?setWindowLoaded():window$1$1.addEventListener("load",setWindowLoaded));const createStyleElement=function(t){const e=document$1$1.createElement("style");return e.className=t,e},setTextContent=function(t,e){t.styleSheet?t.styleSheet.cssText=e:t.textContent=e};var DomData=new WeakMap;const _initialGuid=3;let _guid=_initialGuid;function newGUID(){return _guid++}function _cleanUpEvents(t,e){if(!DomData.has(t))return;const n=DomData.get(t);n.handlers[e].length===0&&(delete n.handlers[e],t.removeEventListener?t.removeEventListener(e,n.dispatcher,!1):t.detachEvent&&t.detachEvent("on"+e,n.dispatcher)),Object.getOwnPropertyNames(n.handlers).length<=0&&(delete n.handlers,delete n.dispatcher,delete n.disabled),Object.getOwnPropertyNames(n).length===0&&DomData.delete(t)}function _handleMultipleEvents(t,e,n,o){n.forEach(function(u){t(e,u,o)})}function fixEvent(t){if(t.fixed_)return t;function e(){return!0}function n(){return!1}if(!t||!t.isPropagationStopped||!t.isImmediatePropagationStopped){const o=t||window$1$1.event;t={};const u=["layerX","layerY","keyLocation","path","webkitMovementX","webkitMovementY","mozPressure","mozInputSource"];for(const l in o)u.includes(l)||l==="returnValue"&&o.preventDefault||(t[l]=o[l]);if(t.target||(t.target=t.srcElement||document$1$1),t.relatedTarget||(t.relatedTarget=t.fromElement===t.target?t.toElement:t.fromElement),t.preventDefault=function(){o.preventDefault&&o.preventDefault(),t.returnValue=!1,o.returnValue=!1,t.defaultPrevented=!0},t.defaultPrevented=!1,t.stopPropagation=function(){o.stopPropagation&&o.stopPropagation(),t.cancelBubble=!0,o.cancelBubble=!0,t.isPropagationStopped=e},t.isPropagationStopped=n,t.stopImmediatePropagation=function(){o.stopImmediatePropagation&&o.stopImmediatePropagation(),t.isImmediatePropagationStopped=e,t.stopPropagation()},t.isImmediatePropagationStopped=n,t.clientX!==null&&t.clientX!==void 0){const l=document$1$1.documentElement,m=document$1$1.body;t.pageX=t.clientX+(l&&l.scrollLeft||m&&m.scrollLeft||0)-(l&&l.clientLeft||m&&m.clientLeft||0),t.pageY=t.clientY+(l&&l.scrollTop||m&&m.scrollTop||0)-(l&&l.clientTop||m&&m.clientTop||0)}t.which=t.charCode||t.keyCode,t.button!==null&&t.button!==void 0&&(t.button=t.button&1?0:t.button&4?1:t.button&2?2:0)}return t.fixed_=!0,t}let _supportsPassive;const supportsPassive=function(){if(typeof _supportsPassive!="boolean"){_supportsPassive=!1;try{const t=Object.defineProperty({},"passive",{get(){_supportsPassive=!0}});window$1$1.addEventListener("test",null,t),window$1$1.removeEventListener("test",null,t)}catch{}}return _supportsPassive},passiveEvents=["touchstart","touchmove"];function on(t,e,n){if(Array.isArray(e))return _handleMultipleEvents(on,t,e,n);DomData.has(t)||DomData.set(t,{});const o=DomData.get(t);if(o.handlers||(o.handlers={}),o.handlers[e]||(o.handlers[e]=[]),n.guid||(n.guid=newGUID()),o.handlers[e].push(n),o.dispatcher||(o.disabled=!1,o.dispatcher=function(u,l){if(o.disabled)return;u=fixEvent(u);const m=o.handlers[u.type];if(m){const y=m.slice(0);for(let E=0,C=y.length;E<C&&!u.isImmediatePropagationStopped();E++)try{y[E].call(t,u,l)}catch(k){log$1.error(k)}}}),o.handlers[e].length===1)if(t.addEventListener){let u=!1;supportsPassive()&&passiveEvents.indexOf(e)>-1&&(u={passive:!0}),t.addEventListener(e,o.dispatcher,u)}else t.attachEvent&&t.attachEvent("on"+e,o.dispatcher)}function off(t,e,n){if(!DomData.has(t))return;const o=DomData.get(t);if(!o.handlers)return;if(Array.isArray(e))return _handleMultipleEvents(off,t,e,n);const u=function(m,y){o.handlers[y]=[],_cleanUpEvents(m,y)};if(e===void 0){for(const m in o.handlers)Object.prototype.hasOwnProperty.call(o.handlers||{},m)&&u(t,m);return}const l=o.handlers[e];if(l){if(!n){u(t,e);return}if(n.guid)for(let m=0;m<l.length;m++)l[m].guid===n.guid&&l.splice(m--,1);_cleanUpEvents(t,e)}}function trigger(t,e,n){const o=DomData.has(t)?DomData.get(t):{},u=t.parentNode||t.ownerDocument;if(typeof e=="string"?e={type:e,target:t}:e.target||(e.target=t),e=fixEvent(e),o.dispatcher&&o.dispatcher.call(t,e,n),u&&!e.isPropagationStopped()&&e.bubbles===!0)trigger.call(null,u,e,n);else if(!u&&!e.defaultPrevented&&e.target&&e.target[e.type]){DomData.has(e.target)||DomData.set(e.target,{});const l=DomData.get(e.target);e.target[e.type]&&(l.disabled=!0,typeof e.target[e.type]=="function"&&e.target[e.type](),l.disabled=!1)}return!e.defaultPrevented}function one(t,e,n){if(Array.isArray(e))return _handleMultipleEvents(one,t,e,n);const o=function(){off(t,e,o),n.apply(this,arguments)};o.guid=n.guid=n.guid||newGUID(),on(t,e,o)}function any(t,e,n){const o=function(){off(t,e,o),n.apply(this,arguments)};o.guid=n.guid=n.guid||newGUID(),on(t,e,o)}var Events=Object.freeze({__proto__:null,fixEvent,on,off,trigger,one,any});const UPDATE_REFRESH_INTERVAL=30,bind_=function(t,e,n){e.guid||(e.guid=newGUID());const o=e.bind(t);return o.guid=n?n+"_"+e.guid:e.guid,o},throttle=function(t,e){let n=window$1$1.performance.now();return function(...u){const l=window$1$1.performance.now();l-n>=e&&(t(...u),n=l)}},debounce=function(t,e,n,o=window$1$1){let u;const l=()=>{o.clearTimeout(u),u=null},m=function(){const y=this,E=arguments;let C=function(){u=null,C=null,n||t.apply(y,E)};!u&&n&&t.apply(y,E),o.clearTimeout(u),u=o.setTimeout(C,e)};return m.cancel=l,m};var Fn=Object.freeze({__proto__:null,UPDATE_REFRESH_INTERVAL,bind_,throttle,debounce});let EVENT_MAP;class EventTarget$2{on(e,n){const o=this.addEventListener;this.addEventListener=()=>{},on(this,e,n),this.addEventListener=o}off(e,n){off(this,e,n)}one(e,n){const o=this.addEventListener;this.addEventListener=()=>{},one(this,e,n),this.addEventListener=o}any(e,n){const o=this.addEventListener;this.addEventListener=()=>{},any(this,e,n),this.addEventListener=o}trigger(e){const n=e.type||e;typeof e=="string"&&(e={type:n}),e=fixEvent(e),this.allowedEvents_[n]&&this["on"+n]&&this["on"+n](e),trigger(this,e)}queueTrigger(e){EVENT_MAP||(EVENT_MAP=new Map);const n=e.type||e;let o=EVENT_MAP.get(this);o||(o=new Map,EVENT_MAP.set(this,o));const u=o.get(n);o.delete(n),window$1$1.clearTimeout(u);const l=window$1$1.setTimeout(()=>{o.delete(n),o.size===0&&(o=null,EVENT_MAP.delete(this)),this.trigger(e)},0);o.set(n,l)}}EventTarget$2.prototype.allowedEvents_={},EventTarget$2.prototype.addEventListener=EventTarget$2.prototype.on,EventTarget$2.prototype.removeEventListener=EventTarget$2.prototype.off,EventTarget$2.prototype.dispatchEvent=EventTarget$2.prototype.trigger;const objName=t=>typeof t.name=="function"?t.name():typeof t.name=="string"?t.name:t.name_?t.name_:t.constructor&&t.constructor.name?t.constructor.name:typeof t,isEvented=t=>t instanceof EventTarget$2||!!t.eventBusEl_&&["on","one","off","trigger"].every(e=>typeof t[e]=="function"),addEventedCallback=(t,e)=>{isEvented(t)?e():(t.eventedCallbacks||(t.eventedCallbacks=[]),t.eventedCallbacks.push(e))},isValidEventType=t=>typeof t=="string"&&/\S/.test(t)||Array.isArray(t)&&!!t.length,validateTarget=(t,e,n)=>{if(!t||!t.nodeName&&!isEvented(t))throw new Error(`Invalid target for ${objName(e)}#${n}; must be a DOM node or evented object.`)},validateEventType=(t,e,n)=>{if(!isValidEventType(t))throw new Error(`Invalid event type for ${objName(e)}#${n}; must be a non-empty string or array.`)},validateListener=(t,e,n)=>{if(typeof t!="function")throw new Error(`Invalid listener for ${objName(e)}#${n}; must be a function.`)},normalizeListenArgs=(t,e,n)=>{const o=e.length<3||e[0]===t||e[0]===t.eventBusEl_;let u,l,m;return o?(u=t.eventBusEl_,e.length>=3&&e.shift(),[l,m]=e):(u=e[0],l=e[1],m=e[2]),validateTarget(u,t,n),validateEventType(l,t,n),validateListener(m,t,n),m=bind_(t,m),{isTargetingSelf:o,target:u,type:l,listener:m}},listen=(t,e,n,o)=>{validateTarget(t,t,e),t.nodeName?Events[e](t,n,o):t[e](n,o)},EventedMixin={on(...t){const{isTargetingSelf:e,target:n,type:o,listener:u}=normalizeListenArgs(this,t,"on");if(listen(n,"on",o,u),!e){const l=()=>this.off(n,o,u);l.guid=u.guid;const m=()=>this.off("dispose",l);m.guid=u.guid,listen(this,"on","dispose",l),listen(n,"on","dispose",m)}},one(...t){const{isTargetingSelf:e,target:n,type:o,listener:u}=normalizeListenArgs(this,t,"one");if(e)listen(n,"one",o,u);else{const l=(...m)=>{this.off(n,o,l),u.apply(null,m)};l.guid=u.guid,listen(n,"one",o,l)}},any(...t){const{isTargetingSelf:e,target:n,type:o,listener:u}=normalizeListenArgs(this,t,"any");if(e)listen(n,"any",o,u);else{const l=(...m)=>{this.off(n,o,l),u.apply(null,m)};l.guid=u.guid,listen(n,"any",o,l)}},off(t,e,n){if(!t||isValidEventType(t))off(this.eventBusEl_,t,e);else{const o=t,u=e;validateTarget(o,this,"off"),validateEventType(u,this,"off"),validateListener(n,this,"off"),n=bind_(this,n),this.off("dispose",n),o.nodeName?(off(o,u,n),off(o,"dispose",n)):isEvented(o)&&(o.off(u,n),o.off("dispose",n))}},trigger(t,e){validateTarget(this.eventBusEl_,this,"trigger");const n=t&&typeof t!="string"?t.type:t;if(!isValidEventType(n))throw new Error(`Invalid event type for ${objName(this)}#trigger; must be a non-empty string or object with a type key that has a non-empty value.`);return trigger(this.eventBusEl_,t,e)}};function evented(t,e={}){const{eventBusKey:n}=e;if(n){if(!t[n].nodeName)throw new Error(`The eventBusKey "${n}" does not refer to an element.`);t.eventBusEl_=t[n]}else t.eventBusEl_=createEl("span",{className:"vjs-event-bus"});return Object.assign(t,EventedMixin),t.eventedCallbacks&&t.eventedCallbacks.forEach(o=>{o()}),t.on("dispose",()=>{t.off(),[t,t.el_,t.eventBusEl_].forEach(function(o){o&&DomData.has(o)&&DomData.delete(o)}),window$1$1.setTimeout(()=>{t.eventBusEl_=null},0)}),t}const StatefulMixin={state:{},setState(t){typeof t=="function"&&(t=t());let e;return each(t,(n,o)=>{this.state[o]!==n&&(e=e||{},e[o]={from:this.state[o],to:n}),this.state[o]=n}),e&&isEvented(this)&&this.trigger({changes:e,type:"statechanged"}),e}};function stateful(t,e){return Object.assign(t,StatefulMixin),t.state=Object.assign({},t.state,e),typeof t.handleStateChanged=="function"&&isEvented(t)&&t.on("statechanged",t.handleStateChanged),t}const toLowerCase=function(t){return typeof t!="string"?t:t.replace(/./,e=>e.toLowerCase())},toTitleCase$1=function(t){return typeof t!="string"?t:t.replace(/./,e=>e.toUpperCase())},titleCaseEquals=function(t,e){return toTitleCase$1(t)===toTitleCase$1(e)};var Str=Object.freeze({__proto__:null,toLowerCase,toTitleCase:toTitleCase$1,titleCaseEquals});class Component$1{constructor(e,n,o){if(!e&&this.play?this.player_=e=this:this.player_=e,this.isDisposed_=!1,this.parentComponent_=null,this.options_=merge$1({},this.options_),n=this.options_=merge$1(this.options_,n),this.id_=n.id||n.el&&n.el.id,!this.id_){const u=e&&e.id&&e.id()||"no_player";this.id_=`${u}_component_${newGUID()}`}this.name_=n.name||null,n.el?this.el_=n.el:n.createEl!==!1&&(this.el_=this.createEl()),n.className&&this.el_&&n.className.split(" ").forEach(u=>this.addClass(u)),["on","off","one","any","trigger"].forEach(u=>{this[u]=void 0}),n.evented!==!1&&(evented(this,{eventBusKey:this.el_?"el_":null}),this.handleLanguagechange=this.handleLanguagechange.bind(this),this.on(this.player_,"languagechange",this.handleLanguagechange)),stateful(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,n.initChildren!==!1&&this.initChildren(),this.ready(o),n.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 n=this.children_.length-1;n>=0;n--)this.children_[n].dispose&&this.children_[n].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_=merge$1(this.options_,e),this.options_):this.options_}el(){return this.el_}createEl(e,n,o){return createEl(e,n,o)}localize(e,n,o=e){const u=this.player_.language&&this.player_.language(),l=this.player_.languages&&this.player_.languages(),m=l&&l[u],y=u&&u.split("-")[0],E=l&&l[y];let C=o;return m&&m[e]?C=m[e]:E&&E[e]&&(C=E[e]),n&&(C=C.replace(/\{(\d+)\}/g,function(k,A){const D=n[A-1];let P=D;return typeof D>"u"&&(P=k),P})),C}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((o,u)=>o.concat(u),[]);let n=this;for(let o=0;o<e.length;o++)if(n=n.getChild(e[o]),!n||!n.getChild)return;return n}setIcon(e,n=this.el()){if(!this.player_.options_.experimentalSvgIcons)return;const o="http://www.w3.org/2000/svg",u=createEl("span",{className:"vjs-icon-placeholder vjs-svg-icon"},{"aria-hidden":"true"}),l=document$1$1.createElementNS(o,"svg");l.setAttributeNS(null,"viewBox","0 0 512 512");const m=document$1$1.createElementNS(o,"use");return l.appendChild(m),m.setAttributeNS(null,"href",`#vjs-icon-${e}`),u.appendChild(l),this.iconIsSet_?n.replaceChild(u,n.querySelector(".vjs-icon-placeholder")):n.appendChild(u),this.iconIsSet_=!0,u}addChild(e,n={},o=this.children_.length){let u,l;if(typeof e=="string"){l=toTitleCase$1(e);const m=n.componentClass||l;n.name=l;const y=Component$1.getComponent(m);if(!y)throw new Error(`Component ${m} does not exist`);if(typeof y!="function")return null;u=new y(this.player_||this,n)}else u=e;if(u.parentComponent_&&u.parentComponent_.removeChild(u),this.children_.splice(o,0,u),u.parentComponent_=this,typeof u.id=="function"&&(this.childIndex_[u.id()]=u),l=l||u.name&&toTitleCase$1(u.name()),l&&(this.childNameIndex_[l]=u,this.childNameIndex_[toLowerCase(l)]=u),typeof u.el=="function"&&u.el()){let m=null;this.children_[o+1]&&(this.children_[o+1].el_?m=this.children_[o+1].el_:isEl(this.children_[o+1])&&(m=this.children_[o+1])),this.contentEl().insertBefore(u.el(),m)}return u}removeChild(e){if(typeof e=="string"&&(e=this.getChild(e)),!e||!this.children_)return;let n=!1;for(let u=this.children_.length-1;u>=0;u--)if(this.children_[u]===e){n=!0,this.children_.splice(u,1);break}if(!n)return;e.parentComponent_=null,this.childIndex_[e.id()]=null,this.childNameIndex_[toTitleCase$1(e.name())]=null,this.childNameIndex_[toLowerCase(e.name())]=null;const o=e.el();o&&o.parentNode===this.contentEl()&&this.contentEl().removeChild(e.el())}initChildren(){const e=this.options_.children;if(e){const n=this.options_,o=m=>{const y=m.name;let E=m.opts;if(n[y]!==void 0&&(E=n[y]),E===!1)return;E===!0&&(E={}),E.playerOptions=this.options_.playerOptions;const C=this.addChild(y,E);C&&(this[y]=C)};let u;const l=Component$1.getComponent("Tech");Array.isArray(e)?u=e:u=Object.keys(e),u.concat(Object.keys(this.options_).filter(function(m){return!u.some(function(y){return typeof y=="string"?m===y:m===y.name})})).map(m=>{let y,E;return typeof m=="string"?(y=m,E=e[y]||this.options_[y]||{}):(y=m.name,E=m),{name:y,opts:E}}).filter(m=>{const y=Component$1.getComponent(m.opts.componentClass||toTitleCase$1(m.name));return y&&!l.isTech(y)}).forEach(o)}}buildCSSClass(){return""}ready(e,n=!1){if(e){if(!this.isReady_){this.readyQueue_=this.readyQueue_||[],this.readyQueue_.push(e);return}n?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(n){n.call(this)},this),this.trigger("ready")},1)}$(e,n){return $(e,n||this.contentEl())}$$(e,n){return $$(e,n||this.contentEl())}hasClass(e){return hasClass(this.el_,e)}addClass(...e){addClass(this.el_,...e)}removeClass(...e){removeClass(this.el_,...e)}toggleClass(e,n){toggleClass(this.el_,e,n)}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 getAttribute(this.el_,e)}setAttribute(e,n){setAttribute(this.el_,e,n)}removeAttribute(e){removeAttribute(this.el_,e)}width(e,n){return this.dimension("width",e,n)}height(e,n){return this.dimension("height",e,n)}dimensions(e,n){this.width(e,!0),this.height(n)}dimension(e,n,o){if(n!==void 0){(n===null||n!==n)&&(n=0),(""+n).indexOf("%")!==-1||(""+n).indexOf("px")!==-1?this.el_.style[e]=n:n==="auto"?this.el_.style[e]="":this.el_.style[e]=n+"px",o||this.trigger("componentresize");return}if(!this.el_)return 0;const u=this.el_.style[e],l=u.indexOf("px");return parseInt(l!==-1?u.slice(0,l):this.el_["offset"+toTitleCase$1(e)],10)}currentDimension(e){let n=0;if(e!=="width"&&e!=="height")throw new Error("currentDimension only accepts width or height value");if(n=computedStyle(this.el_,e),n=parseFloat(n),n===0||isNaN(n)){const o=`offset${toTitleCase$1(e)}`;n=this.el_[o]}return n}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(),n={x:e.x,y:e.y,width:e.width,height:e.height,top:e.top,right:e.right,bottom:e.bottom,left:e.left},o={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:n,center:o}}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,n=null;const o=10,u=200;let l;this.on("touchstart",function(y){y.touches.length===1&&(n={pageX:y.touches[0].pageX,pageY:y.touches[0].pageY},e=window$1$1.performance.now(),l=!0)}),this.on("touchmove",function(y){if(y.touches.length>1)l=!1;else if(n){const E=y.touches[0].pageX-n.pageX,C=y.touches[0].pageY-n.pageY;Math.sqrt(E*E+C*C)>o&&(l=!1)}});const m=function(){l=!1};this.on("touchleave",m),this.on("touchcancel",m),this.on("touchend",function(y){n=null,l===!0&&window$1$1.performance.now()-e<u&&(y.preventDefault(),this.trigger("tap"))})}enableTouchActivity(){if(!this.player()||!this.player().reportUserActivity)return;const e=bind_(this.player(),this.player().reportUserActivity);let n;this.on("touchstart",function(){e(),this.clearInterval(n),n=this.setInterval(e,250)});const o=function(u){e(),this.clearInterval(n)};this.on("touchmove",e),this.on("touchend",o),this.on("touchcancel",o)}setTimeout(e,n){var o;return e=bind_(this,e),this.clearTimersOnDispose_(),o=window$1$1.setTimeout(()=>{this.setTimeoutIds_.has(o)&&this.setTimeoutIds_.delete(o),e()},n),this.setTimeoutIds_.add(o),o}clearTimeout(e){return this.setTimeoutIds_.has(e)&&(this.setTimeoutIds_.delete(e),window$1$1.clearTimeout(e)),e}setInterval(e,n){e=bind_(this,e),this.clearTimersOnDispose_();const o=window$1$1.setInterval(e,n);return this.setIntervalIds_.add(o),o}clearInterval(e){return this.setIntervalIds_.has(e)&&(this.setIntervalIds_.delete(e),window$1$1.clearInterval(e)),e}requestAnimationFrame(e){this.clearTimersOnDispose_();var n;return e=bind_(this,e),n=window$1$1.requestAnimationFrame(()=>{this.rafIds_.has(n)&&this.rafIds_.delete(n),e()}),this.rafIds_.add(n),n}requestNamedAnimationFrame(e,n){this.namedRafs_.has(e)&&this.cancelNamedAnimationFrame(e),this.clearTimersOnDispose_(),n=bind_(this,n);const o=this.requestAnimationFrame(()=>{n(),this.namedRafs_.has(e)&&this.namedRafs_.delete(e)});return this.namedRafs_.set(e,o),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),window$1$1.cancelAnimationFrame(e)),e}clearTimersOnDispose_(){this.clearingTimersOnDispose_||(this.clearingTimersOnDispose_=!0,this.one("dispose",()=>{[["namedRafs_","cancelNamedAnimationFrame"],["rafIds_","cancelAnimationFrame"],["setTimeoutIds_","clearTimeout"],["setIntervalIds_","clearInterval"]].forEach(([e,n])=>{this[e].forEach((o,u)=>this[n](u))}),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 n(l){const m=window$1$1.getComputedStyle(l,null),y=m.getPropertyValue("visibility");return m.getPropertyValue("display")!=="none"&&!["hidden","collapse"].includes(y)}function o(l){return!(!n(l.parentElement)||!n(l)||l.style.opacity==="0"||window$1$1.getComputedStyle(l).height==="0px"||window$1$1.getComputedStyle(l).width==="0px")}function u(l){if(l.offsetWidth+l.offsetHeight+l.getBoundingClientRect().height+l.getBoundingClientRect().width===0)return!1;const m={x:l.getBoundingClientRect().left+l.offsetWidth/2,y:l.getBoundingClientRect().top+l.offsetHeight/2};if(m.x<0||m.x>(document$1$1.documentElement.clientWidth||window$1$1.innerWidth)||m.y<0||m.y>(document$1$1.documentElement.clientHeight||window$1$1.innerHeight))return!1;let y=document$1$1.elementFromPoint(m.x,m.y);for(;y;){if(y===l)return!0;if(y.parentNode)y=y.parentNode;else return!1}}return e||(e=this.el()),!!(u(e)&&o(e)&&(!e.parentElement||e.tabIndex>=0))}static registerComponent(e,n){if(typeof e!="string"||!e)throw new Error(`Illegal component name, "${e}"; must be a non-empty string.`);const o=Component$1.getComponent("Tech"),u=o&&o.isTech(n),l=Component$1===n||Component$1.prototype.isPrototypeOf(n.prototype);if(u||!l){let y;throw u?y="techs must be registered using Tech.registerTech()":y="must be a Component subclass",new Error(`Illegal component, "${e}"; ${y}.`)}e=toTitleCase$1(e),Component$1.components_||(Component$1.components_={});const m=Component$1.getComponent("Player");if(e==="Player"&&m&&m.players){const y=m.players,E=Object.keys(y);if(y&&E.length>0&&E.map(C=>y[C]).every(Boolean))throw new Error("Can not register Player component after player has been created.")}return Component$1.components_[e]=n,Component$1.components_[toLowerCase(e)]=n,n}static getComponent(e){if(!(!e||!Component$1.components_))return Component$1.components_[e]}}Component$1.registerComponent("Component",Component$1);function rangeCheck(t,e,n){if(typeof e!="number"||e<0||e>n)throw new Error(`Failed to execute '${t}' on 'TimeRanges': The index provided (${e}) is non-numeric or out of bounds (0-${n}).`)}function getRange(t,e,n,o){return rangeCheck(t,o,n.length-1),n[o][e]}function createTimeRangesObj(t){let e;return t===void 0||t.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:t.length,start:getRange.bind(null,"start",0,t),end:getRange.bind(null,"end",1,t)},window$1$1.Symbol&&window$1$1.Symbol.iterator&&(e[window$1$1.Symbol.iterator]=()=>(t||[]).values()),e}function createTimeRanges$1(t,e){return Array.isArray(t)?createTimeRangesObj(t):t===void 0||e===void 0?createTimeRangesObj():createTimeRangesObj([[t,e]])}const defaultImplementation=function(t,e){t=t<0?0:t;let n=Math.floor(t%60),o=Math.floor(t/60%60),u=Math.floor(t/3600);const l=Math.floor(e/60%60),m=Math.floor(e/3600);return(isNaN(t)||t===1/0)&&(u=o=n="-"),u=u>0||m>0?u+":":"",o=((u||l>=10)&&o<10?"0"+o:o)+":",n=n<10?"0"+n:n,u+o+n};let implementation$6=defaultImplementation;function setFormatTime(t){implementation$6=t}function resetFormatTime(){implementation$6=defaultImplementation}function formatTime(t,e=t){return implementation$6(t,e)}var Time$1=Object.freeze({__proto__:null,createTimeRanges:createTimeRanges$1,createTimeRange:createTimeRanges$1,setFormatTime,resetFormatTime,formatTime});function bufferedPercent(t,e){let n=0,o,u;if(!e)return 0;(!t||!t.length)&&(t=createTimeRanges$1(0,0));for(let l=0;l<t.length;l++)o=t.start(l),u=t.end(l),u>e&&(u=e),n+=u-o;return n/e}function MediaError(t){if(t instanceof MediaError)return t;typeof t=="number"?this.code=t:typeof t=="string"?this.message=t:isObject$1(t)&&(typeof t.code=="number"&&(this.code=t.code),Object.assign(this,t)),this.message||(this.message=MediaError.defaultMessages[this.code]||"")}MediaError.prototype.code=0,MediaError.prototype.message="",MediaError.prototype.status=null,MediaError.prototype.metadata=null,MediaError.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],MediaError.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."},MediaError.MEDIA_ERR_CUSTOM=0,MediaError.prototype.MEDIA_ERR_CUSTOM=0,MediaError.MEDIA_ERR_ABORTED=1,MediaError.prototype.MEDIA_ERR_ABORTED=1,MediaError.MEDIA_ERR_NETWORK=2,MediaError.prototype.MEDIA_ERR_NETWORK=2,MediaError.MEDIA_ERR_DECODE=3,MediaError.prototype.MEDIA_ERR_DECODE=3,MediaError.MEDIA_ERR_SRC_NOT_SUPPORTED=4,MediaError.prototype.MEDIA_ERR_SRC_NOT_SUPPORTED=4,MediaError.MEDIA_ERR_ENCRYPTED=5,MediaError.prototype.MEDIA_ERR_ENCRYPTED=5;function isPromise(t){return t!=null&&typeof t.then=="function"}function silencePromise(t){isPromise(t)&&t.then(null,e=>{})}const trackToJson_=function(t){return["kind","label","language","id","inBandMetadataTrackDispatchType","mode","src"].reduce((n,o,u)=>(t[o]&&(n[o]=t[o]),n),{cues:t.cues&&Array.prototype.map.call(t.cues,function(n){return{startTime:n.startTime,endTime:n.endTime,text:n.text,id:n.id}})})},textTracksToJson=function(t){const e=t.$$("track"),n=Array.prototype.map.call(e,u=>u.track);return Array.prototype.map.call(e,function(u){const l=trackToJson_(u.track);return u.src&&(l.src=u.src),l}).concat(Array.prototype.filter.call(t.textTracks(),function(u){return n.indexOf(u)===-1}).map(trackToJson_))},jsonToTextTracks=function(t,e){return t.forEach(function(n){const o=e.addRemoteTextTrack(n).track;!n.src&&n.cues&&n.cues.forEach(u=>o.addCue(u))}),e.textTracks()};var textTrackConverter={textTracksToJson,jsonToTextTracks,trackToJson_};const MODAL_CLASS_NAME="vjs-modal-dialog";class ModalDialog extends Component$1{constructor(e,n){super(e,n),this.handleKeyDown_=o=>this.handleKeyDown(o),this.close_=o=>this.close(o),this.opened_=this.hasBeenOpened_=this.hasBeenFilled_=!1,this.closeable(!this.options_.uncloseable),this.content(this.options_.content),this.contentEl_=createEl("div",{className:`${MODAL_CLASS_NAME}-content`},{role:"document"}),this.descEl_=createEl("p",{className:`${MODAL_CLASS_NAME}-description vjs-control-text`,id:this.el().getAttribute("aria-describedby")}),textContent(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`${MODAL_CLASS_NAME} 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 n=this.closeable_=!!e;let o=this.getChild("closeButton");if(n&&!o){const u=this.contentEl_;this.contentEl_=this.el_,o=this.addChild("closeButton",{controlText:"Close Modal Dialog"}),this.contentEl_=u,this.on(o,"close",this.close_)}!n&&o&&(this.off(o,"close",this.close_),this.removeChild(o),o.dispose())}return this.closeable_}fill(){this.fillWith(this.content())}fillWith(e){const n=this.contentEl(),o=n.parentNode,u=n.nextSibling;this.trigger("beforemodalfill"),this.hasBeenFilled_=!0,o.removeChild(n),this.empty(),insertContent(n,e),this.trigger("modalfill"),u?o.insertBefore(n,u):o.appendChild(n);const l=this.getChild("closeButton");l&&o.appendChild(l.el_),this.trigger("aftermodalfill")}empty(){this.trigger("beforemodalempty"),emptyEl(this.contentEl()),this.trigger("modalempty")}content(e){return typeof e<"u"&&(this.content_=e),this.content_}conditionalFocus_(){const e=document$1$1.activeElement,n=this.player_.el_;this.previouslyActiveEl_=null,(n.contains(e)||n===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 n=this.focusableEls_(),o=this.el_.querySelector(":focus");let u;for(let l=0;l<n.length;l++)if(o===n[l]){u=l;break}document$1$1.activeElement===this.el_&&(u=0),e.shiftKey&&u===0?(n[n.length-1].focus(),e.preventDefault()):!e.shiftKey&&u===n.length-1&&(n[0].focus(),e.preventDefault())}focusableEls_(){const e=this.el_.querySelectorAll("*");return Array.prototype.filter.call(e,n=>(n instanceof window$1$1.HTMLAnchorElement||n instanceof window$1$1.HTMLAreaElement)&&n.hasAttribute("href")||(n instanceof window$1$1.HTMLInputElement||n instanceof window$1$1.HTMLSelectElement||n instanceof window$1$1.HTMLTextAreaElement||n instanceof window$1$1.HTMLButtonElement)&&!n.hasAttribute("disabled")||n instanceof window$1$1.HTMLIFrameElement||n instanceof window$1$1.HTMLObjectElement||n instanceof window$1$1.HTMLEmbedElement||n.hasAttribute("tabindex")&&n.getAttribute("tabindex")!==-1||n.hasAttribute("contenteditable"))}}ModalDialog.prototype.options_={pauseOnOpen:!0,temporary:!0},Component$1.registerComponent("ModalDialog",ModalDialog);class TrackList extends EventTarget$2{constructor(e=[]){super(),this.tracks_=[],Object.defineProperty(this,"length",{get(){return this.tracks_.length}});for(let n=0;n<e.length;n++)this.addTrack(e[n])}addTrack(e){const n=this.tracks_.length;""+n in this||Object.defineProperty(this,n,{get(){return this.tracks_[n]}}),this.tracks_.indexOf(e)===-1&&(this.tracks_.push(e),this.trigger({track:e,type:"addtrack",target:this})),e.labelchange_=()=>{this.trigger({track:e,type:"labelchange",target:this})},isEvented(e)&&e.addEventListener("labelchange",e.labelchange_)}removeTrack(e){let n;for(let o=0,u=this.length;o<u;o++)if(this[o]===e){n=this[o],n.off&&n.off(),this.tracks_.splice(o,1);break}n&&this.trigger({track:n,type:"removetrack",target:this})}getTrackById(e){let n=null;for(let o=0,u=this.length;o<u;o++){const l=this[o];if(l.id===e){n=l;break}}return n}}TrackList.prototype.allowedEvents_={change:"change",addtrack:"addtrack",removetrack:"removetrack",labelchange:"labelchange"};for(const t in TrackList.prototype.allowedEvents_)TrackList.prototype["on"+t]=null;const disableOthers$1=function(t,e){for(let n=0;n<t.length;n++)!Object.keys(t[n]).length||e.id===t[n].id||(t[n].enabled=!1)};class AudioTrackList extends TrackList{constructor(e=[]){for(let n=e.length-1;n>=0;n--)if(e[n].enabled){disableOthers$1(e,e[n]);break}super(e),this.changing_=!1}addTrack(e){e.enabled&&disableOthers$1(this,e),super.addTrack(e),e.addEventListener&&(e.enabledChange_=()=>{this.changing_||(this.changing_=!0,disableOthers$1(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 disableOthers=function(t,e){for(let n=0;n<t.length;n++)!Object.keys(t[n]).length||e.id===t[n].id||(t[n].selected=!1)};class VideoTrackList extends TrackList{constructor(e=[]){for(let n=e.length-1;n>=0;n--)if(e[n].selected){disableOthers(e,e[n]);break}super(e),this.changing_=!1,Object.defineProperty(this,"selectedIndex",{get(){for(let n=0;n<this.length;n++)if(this[n].selected)return n;return-1},set(){}})}addTrack(e){e.selected&&disableOthers(this,e),super.addTrack(e),e.addEventListener&&(e.selectedChange_=()=>{this.changing_||(this.changing_=!0,disableOthers(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 TextTrackList extends TrackList{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 HtmlTrackElementList{constructor(e=[]){this.trackElements_=[],Object.defineProperty(this,"length",{get(){return this.trackElements_.length}});for(let n=0,o=e.length;n<o;n++)this.addTrackElement_(e[n])}addTrackElement_(e){const n=this.trackElements_.length;""+n in this||Object.defineProperty(this,n,{get(){return this.trackElements_[n]}}),this.trackElements_.indexOf(e)===-1&&this.trackElements_.push(e)}getTrackElementByTrack_(e){let n;for(let o=0,u=this.trackElements_.length;o<u;o++)if(e===this.trackElements_[o].track){n=this.trackElements_[o];break}return n}removeTrackElement_(e){for(let n=0,o=this.trackElements_.length;n<o;n++)if(e===this.trackElements_[n]){this.trackElements_[n].track&&typeof this.trackElements_[n].track.off=="function"&&this.trackElements_[n].track.off(),typeof this.trackElements_[n].off=="function"&&this.trackElements_[n].off(),this.trackElements_.splice(n,1);break}}}class TextTrackCueList{constructor(e){TextTrackCueList.prototype.setCues_.call(this,e),Object.defineProperty(this,"length",{get(){return this.length_}})}setCues_(e){const n=this.length||0;let o=0;const u=e.length;this.cues_=e,this.length_=e.length;const l=function(m){""+m in this||Object.defineProperty(this,""+m,{get(){return this.cues_[m]}})};if(n<u)for(o=n;o<u;o++)l.call(this,o)}getCueById(e){let n=null;for(let o=0,u=this.length;o<u;o++){const l=this[o];if(l.id===e){n=l;break}}return n}}const VideoTrackKind={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},AudioTrackKind={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},TextTrackKind={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},TextTrackMode={disabled:"disabled",hidden:"hidden",showing:"showing"};class Track extends EventTarget$2{constructor(e={}){super();const n={id:e.id||"vjs_track_"+newGUID(),kind:e.kind||"",language:e.language||""};let o=e.label||"";for(const u in n)Object.defineProperty(this,u,{get(){return n[u]},set(){}});Object.defineProperty(this,"label",{get(){return o},set(u){u!==o&&(o=u,this.trigger("labelchange"))}})}}const parseUrl=function(t){return new URL(t,document$1$1.baseURI)},getAbsoluteURL=function(t){return new URL(t,document$1$1.baseURI).href},getFileExtension=function(t){if(typeof t=="string"){const n=/^(\/?)([\s\S]*?)((?:\.{1,2}|[^\/]+?)(\.([^\.\/\?]+)))(?:[\/]*|[\?].*)$/.exec(t);if(n)return n.pop().toLowerCase()}return""},isCrossOrigin=function(t,e=window$1$1.location){return parseUrl(t).origin!==e.origin};var Url$1=Object.freeze({__proto__:null,parseUrl,getAbsoluteURL,getFileExtension,isCrossOrigin});const parseCues=function(t,e){const n=new window$1$1.WebVTT.Parser(window$1$1,window$1$1.vttjs,window$1$1.WebVTT.StringDecoder()),o=[];n.oncue=function(u){e.addCue(u)},n.onparsingerror=function(u){o.push(u)},n.onflush=function(){e.trigger({type:"loadeddata",target:e})},n.parse(t),o.length>0&&(window$1$1.console&&window$1$1.console.groupCollapsed&&window$1$1.console.groupCollapsed(`Text Track parsing errors for ${e.src}`),o.forEach(u=>log$1.error(u)),window$1$1.console&&window$1$1.console.groupEnd&&window$1$1.console.groupEnd()),n.flush()},loadTrack=function(t,e){const n={uri:t},o=isCrossOrigin(t);o&&(n.cors=o);const u=e.tech_.crossOrigin()==="use-credentials";u&&(n.withCredentials=u),XHR(n,bind_(this,function(l,m,y){if(l)return log$1.error(l,m);e.loaded_=!0,typeof window$1$1.WebVTT!="function"?e.tech_&&e.tech_.any(["vttjsloaded","vttjserror"],E=>{if(E.type==="vttjserror"){log$1.error(`vttjs failed to load, stopping trying to process ${e.src}`);return}return parseCues(y,e)}):parseCues(y,e)}))};class TextTrack extends Track{constructor(e={}){if(!e.tech)throw new Error("A tech was not provided.");const n=merge$1(e,{kind:TextTrackKind[e.kind]||"subtitles",language:e.language||e.srclang||""});let o=TextTrackMode[n.mode]||"disabled";const u=n.default;(n.kind==="metadata"||n.kind==="chapters")&&(o="hidden"),super(n),this.tech_=n.tech,this.cues_=[],this.activeCues_=[],this.preload_=this.tech_.preloadTextTracks!==!1;const l=new TextTrackCueList(this.cues_),m=new TextTrackCueList(this.activeCues_);let y=!1;this.timeupdateHandler=bind_(this,function(C={}){if(!this.tech_.isDisposed()){if(!this.tech_.isReady_){C.type!=="timeupdate"&&(this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler));return}this.activeCues=this.activeCues,y&&(this.trigger("cuechange"),y=!1),C.type!=="timeupdate"&&(this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler))}});const E=()=>{this.stopTracking()};this.tech_.one("dispose",E),o!=="disabled"&&this.startTracking(),Object.defineProperties(this,{default:{get(){return u},set(){}},mode:{get(){return o},set(C){TextTrackMode[C]&&o!==C&&(o=C,!this.preload_&&o!=="disabled"&&this.cues.length===0&&loadTrack(this.src,this),this.stopTracking(),o!=="disabled"&&this.startTracking(),this.trigger("modechange"))}},cues:{get(){return this.loaded_?l:null},set(){}},activeCues:{get(){if(!this.loaded_)return null;if(this.cues.length===0)return m;const C=this.tech_.currentTime(),k=[];for(let A=0,D=this.cues.length;A<D;A++){const P=this.cues[A];P.startTime<=C&&P.endTime>=C&&k.push(P)}if(y=!1,k.length!==this.activeCues_.length)y=!0;else for(let A=0;A<k.length;A++)this.activeCues_.indexOf(k[A])===-1&&(y=!0);return this.activeCues_=k,m.setCues_(this.activeCues_),m},set(){}}}),n.src?(this.src=n.src,this.preload_||(this.loaded_=!0),(this.preload_||n.kind!=="subtitles"&&n.kind!=="captions")&&loadTrack(this.src,this)):this.loaded_=!0}startTracking(){this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler),this.tech_.on("timeupdate",this.timeupdateHandler)}stopTracking(){this.rvf_&&(this.tech_.cancelVideoFrameCallback(this.rvf_),this.rvf_=void 0),this.tech_.off("timeupdate",this.timeupdateHandler)}addCue(e){let n=e;if(!("getCueAsHTML"in n)){n=new window$1$1.vttjs.VTTCue(e.startTime,e.endTime,e.text);for(const u in e)u in n||(n[u]=e[u]);n.id=e.id,n.originalCue_=e}const o=this.tech_.textTracks();for(let u=0;u<o.length;u++)o[u]!==this&&o[u].removeCue(n);this.cues_.push(n),this.cues.setCues_(this.cues_)}removeCue(e){let n=this.cues_.length;for(;n--;){const o=this.cues_[n];if(o===e||o.originalCue_&&o.originalCue_===e){this.cues_.splice(n,1),this.cues.setCues_(this.cues_);break}}}}TextTrack.prototype.allowedEvents_={cuechange:"cuechange"};class AudioTrack extends Track{constructor(e={}){const n=merge$1(e,{kind:AudioTrackKind[e.kind]||""});super(n);let o=!1;Object.defineProperty(this,"enabled",{get(){return o},set(u){typeof u!="boolean"||u===o||(o=u,this.trigger("enabledchange"))}}),n.enabled&&(this.enabled=n.enabled),this.loaded_=!0}}class VideoTrack extends Track{constructor(e={}){const n=merge$1(e,{kind:VideoTrackKind[e.kind]||""});super(n);let o=!1;Object.defineProperty(this,"selected",{get(){return o},set(u){typeof u!="boolean"||u===o||(o=u,this.trigger("selectedchange"))}}),n.selected&&(this.selected=n.selected)}}class HTMLTrackElement extends EventTarget$2{constructor(e={}){super();let n;const o=new TextTrack(e);this.kind=o.kind,this.src=o.src,this.srclang=o.language,this.label=o.label,this.default=o.default,Object.defineProperties(this,{readyState:{get(){return n}},track:{get(){return o}}}),n=HTMLTrackElement.NONE,o.addEventListener("loadeddata",()=>{n=HTMLTrackElement.LOADED,this.trigger({type:"load",target:this})})}}HTMLTrackElement.prototype.allowedEvents_={load:"load"},HTMLTrackElement.NONE=0,HTMLTrackElement.LOADING=1,HTMLTrackElement.LOADED=2,HTMLTrackElement.ERROR=3;const NORMAL={audio:{ListClass:AudioTrackList,TrackClass:AudioTrack,capitalName:"Audio"},video:{ListClass:VideoTrackList,TrackClass:VideoTrack,capitalName:"Video"},text:{ListClass:TextTrackList,TrackClass:TextTrack,capitalName:"Text"}};Object.keys(NORMAL).forEach(function(t){NORMAL[t].getterName=`${t}Tracks`,NORMAL[t].privateName=`${t}Tracks_`});const REMOTE={remoteText:{ListClass:TextTrackList,TrackClass:TextTrack,capitalName:"RemoteText",getterName:"remoteTextTracks",privateName:"remoteTextTracks_"},remoteTextEl:{ListClass:HtmlTrackElementList,TrackClass:HTMLTrackElement,capitalName:"RemoteTextTrackEls",getterName:"remoteTextTrackEls",privateName:"remoteTextTrackEls_"}},ALL=Object.assign({},NORMAL,REMOTE);REMOTE.names=Object.keys(REMOTE),NORMAL.names=Object.keys(NORMAL),ALL.names=[].concat(REMOTE.names).concat(NORMAL.names);function createTrackHelper(t,e,n,o,u={}){const l=t.textTracks();u.kind=e,n&&(u.label=n),o&&(u.language=o),u.tech=t;const m=new ALL.text.TrackClass(u);return l.addTrack(m),m}let Tech$1=class vn extends Component$1{constructor(e={},n=function(){}){e.reportTouchActivity=!1,super(null,e,n),this.onDurationChange_=o=>this.onDurationChange(o),this.trackProgress_=o=>this.trackProgress(o),this.trackCurrentTime_=o=>this.trackCurrentTime(o),this.stopTrackingCurrentTime_=o=>this.stopTrackingCurrentTime(o),this.disposeSourceHandler_=o=>this.disposeSourceHandler(o),this.queuedHanders_=new Set,this.hasStarted_=!1,this.on("playing",function(){this.hasStarted_=!0}),this.on("loadstart",function(){this.hasStarted_=!1}),ALL.names.forEach(o=>{const u=ALL[o];e&&e[u.getterName]&&(this[u.privateName]=e[u.getterName])}),this.featuresProgressEvents||this.manualProgressOn(),this.featuresTimeupdateEvents||this.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach(o=>{e[`native${o}Tracks`]===!1&&(this[`featuresNative${o}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 ALL.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(bind_(this,function(){const n=this.bufferedPercent();this.bufferedPercent_!==n&&this.trigger("progress"),this.bufferedPercent_=n,n===1&&this.stopTrackingProgress()}),500)}onDurationChange(e){this.duration_=this.duration()}buffered(){return createTimeRanges$1(0,0)}bufferedPercent(){return bufferedPercent(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(NORMAL.names),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),super.dispose()}clearTracks(e){e=[].concat(e),e.forEach(n=>{const o=this[`${n}Tracks`]()||[];let u=o.length;for(;u--;){const l=o[u];n==="text"&&this.removeRemoteTextTrack(l),o.removeTrack(l)}})}cleanupAutoTextTracks(){const e=this.autoRemoteTextTracks_||[];let n=e.length;for(;n--;){const o=e[n];this.removeRemoteTextTrack(o)}}reset(){}crossOrigin(){}setCrossOrigin(){}error(e){return e!==void 0&&(this.error_=new MediaError(e),this.trigger("error")),this.error_}played(){return this.hasStarted_?createTimeRanges$1(0,0):createTimeRanges$1()}play(){}setScrubbing(e){}scrubbing(){}setCurrentTime(e){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}initTrackListeners(){NORMAL.names.forEach(e=>{const n=NORMAL[e],o=()=>{this.trigger(`${e}trackchange`)},u=this[n.getterName]();u.addEventListener("removetrack",o),u.addEventListener("addtrack",o),this.on("dispose",()=>{u.removeEventListener("removetrack",o),u.removeEventListener("addtrack",o)})})}addWebVttScript_(){if(!window$1$1.WebVTT)if(document$1$1.body.contains(this.el())){if(!this.options_["vtt.js"]&&isPlain(vtt)&&Object.keys(vtt).length>0){this.trigger("vttjsloaded");return}const e=document$1$1.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}),window$1$1.WebVTT=!0,this.el().parentNode.appendChild(e)}else this.ready(this.addWebVttScript_)}emulateTextTracks(){const e=this.textTracks(),n=this.remoteTextTracks(),o=y=>e.addTrack(y.track),u=y=>e.removeTrack(y.track);n.on("addtrack",o),n.on("removetrack",u),this.addWebVttScript_();const l=()=>this.trigger("texttrackchange"),m=()=>{l();for(let y=0;y<e.length;y++){const E=e[y];E.removeEventListener("cuechange",l),E.mode==="showing"&&E.addEventListener("cuechange",l)}};m(),e.addEventListener("change",m),e.addEventListener("addtrack",m),e.addEventListener("removetrack",m),this.on("dispose",function(){n.off("addtrack",o),n.off("removetrack",u),e.removeEventListener("change",m),e.removeEventListener("addtrack",m),e.removeEventListener("removetrack",m);for(let y=0;y<e.length;y++)e[y].removeEventListener("cuechange",l)})}addTextTrack(e,n,o){if(!e)throw new Error("TextTrack kind is required but was not provided");return createTrackHelper(this,e,n,o)}createRemoteTextTrack(e){const n=merge$1(e,{tech:this});return new REMOTE.remoteTextEl.TrackClass(n)}addRemoteTextTrack(e={},n){const o=this.createRemoteTextTrack(e);return typeof n!="boolean"&&(n=!1),this.remoteTextTrackEls().addTrackElement_(o),this.remoteTextTracks().addTrack(o.track),n===!1&&this.ready(()=>this.autoRemoteTextTracks_.addTrack(o.track)),o}removeRemoteTextTrack(e){const n=this.remoteTextTrackEls().getTrackElementByTrack_(e);this.remoteTextTrackEls().removeTrackElement_(n),this.remoteTextTracks().removeTrack(e),this.autoRemoteTextTracks_.removeTrack(e)}getVideoPlaybackQuality(){return{}}requestPictureInPicture(){return Promise.reject()}disablePictureInPicture(){return!0}setDisablePictureInPicture(){}requestVideoFrameCallback(e){const n=newGUID();return!this.isReady_||this.paused()?(this.queuedHanders_.add(n),this.one("playing",()=>{this.queuedHanders_.has(n)&&(this.queuedHanders_.delete(n),e())})):this.requestNamedAnimationFrame(n,e),n}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,n){return vn.canPlayType(e.type)}static isTech(e){return e.prototype instanceof vn||e instanceof vn||e===vn}static registerTech(e,n){if(vn.techs_||(vn.techs_={}),!vn.isTech(n))throw new Error(`Tech ${e} must be a Tech`);if(!vn.canPlayType)throw new Error("Techs must have a static canPlayType method on them");if(!vn.canPlaySource)throw new Error("Techs must have a static canPlaySource method on them");return e=toTitleCase$1(e),vn.techs_[e]=n,vn.techs_[toLowerCase(e)]=n,e!=="Tech"&&vn.defaultTechOrder_.push(e),n}static getTech(e){if(e){if(vn.techs_&&vn.techs_[e])return vn.techs_[e];if(e=toTitleCase$1(e),window$1$1&&window$1$1.videojs&&window$1$1.videojs[e])return log$1.warn(`The ${e} tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)`),window$1$1.videojs[e]}}};ALL.names.forEach(function(t){const e=ALL[t];Tech$1.prototype[e.getterName]=function(){return this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName]}}),Tech$1.prototype.featuresVolumeControl=!0,Tech$1.prototype.featuresMuteControl=!0,Tech$1.prototype.featuresFullscreenResize=!1,Tech$1.prototype.featuresPlaybackRate=!1,Tech$1.prototype.featuresProgressEvents=!1,Tech$1.prototype.featuresSourceset=!1,Tech$1.prototype.featuresTimeupdateEvents=!1,Tech$1.prototype.featuresNativeTextTracks=!1,Tech$1.prototype.featuresVideoFrameCallback=!1,Tech$1.withSourceHandlers=function(t){t.registerSourceHandler=function(n,o){let u=t.sourceHandlers;u||(u=t.sourceHandlers=[]),o===void 0&&(o=u.length),u.splice(o,0,n)},t.canPlayType=function(n){const o=t.sourceHandlers||[];let u;for(let l=0;l<o.length;l++)if(u=o[l].canPlayType(n),u)return u;return""},t.selectSourceHandler=function(n,o){const u=t.sourceHandlers||[];let l;for(let m=0;m<u.length;m++)if(l=u[m].canHandleSource(n,o),l)return u[m];return null},t.canPlaySource=function(n,o){const u=t.selectSourceHandler(n,o);return u?u.canHandleSource(n,o):""},["seekable","seeking","duration"].forEach(function(n){const o=this[n];typeof o=="function"&&(this[n]=function(){return this.sourceHandler_&&this.sourceHandler_[n]?this.sourceHandler_[n].apply(this.sourceHandler_,arguments):o.apply(this,arguments)})},t.prototype),t.prototype.setSource=function(n){let o=t.selectSourceHandler(n,this.options_);o||(t.nativeSourceHandler?o=t.nativeSourceHandler:log$1.error("No source handler found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler_),o!==t.nativeSourceHandler&&(this.currentSource_=n),this.sourceHandler_=o.handleSource(n,this,this.options_),this.one("dispose",this.disposeSourceHandler_)},t.prototype.disposeSourceHandler=function(){this.currentSource_&&(this.clearTracks(["audio","video"]),this.currentSource_=null),this.cleanupAutoTextTracks(),this.sourceHandler_&&(this.sourceHandler_.dispose&&this.sourceHandler_.dispose(),this.sourceHandler_=null)}},Component$1.registerComponent("Tech",Tech$1),Tech$1.registerTech("Tech",Tech$1),Tech$1.defaultTechOrder_=[];const middlewares={},middlewareInstances={},TERMINATOR={};function use(t,e){middlewares[t]=middlewares[t]||[],middlewares[t].push(e)}function setSource(t,e,n){t.setTimeout(()=>setSourceHelper(e,middlewares[e.type],n,t),1)}function setTech(t,e){t.forEach(n=>n.setTech&&n.setTech(e))}function get(t,e,n){return t.reduceRight(middlewareIterator(n),e[n]())}function set(t,e,n,o){return e[n](t.reduce(middlewareIterator(n),o))}function mediate(t,e,n,o=null){const u="call"+toTitleCase$1(n),l=t.reduce(middlewareIterator(u),o),m=l===TERMINATOR,y=m?null:e[n](l);return executeRight(t,n,y,m),y}const allowedGetters={buffered:1,currentTime:1,duration:1,muted:1,played:1,paused:1,seekable:1,volume:1,ended:1},allowedSetters={setCurrentTime:1,setMuted:1,setVolume:1},allowedMediators={play:1,pause:1};function middlewareIterator(t){return(e,n)=>e===TERMINATOR?TERMINATOR:n[t]?n[t](e):e}function executeRight(t,e,n,o){for(let u=t.length-1;u>=0;u--){const l=t[u];l[e]&&l[e](o,n)}}function clearCacheForPlayer(t){middlewareInstances.hasOwnProperty(t.id())&&delete middlewareInstances[t.id()]}function getOrCreateFactory(t,e){const n=middlewareInstances[t.id()];let o=null;if(n==null)return o=e(t),middlewareInstances[t.id()]=[[e,o]],o;for(let u=0;u<n.length;u++){const[l,m]=n[u];l===e&&(o=m)}return o===null&&(o=e(t),n.push([e,o])),o}function setSourceHelper(t={},e=[],n,o,u=[],l=!1){const[m,...y]=e;if(typeof m=="string")setSourceHelper(t,middlewares[m],n,o,u,l);else if(m){const E=getOrCreateFactory(o,m);if(!E.setSource)return u.push(E),setSourceHelper(t,y,n,o,u,l);E.setSource(Object.assign({},t),function(C,k){if(C)return setSourceHelper(t,y,n,o,u,l);u.push(E),setSourceHelper(k,t.type===k.type?y:middlewares[k.type],n,o,u,l)})}else y.length?setSourceHelper(t,y,n,o,u,l):l?n(t,u):setSourceHelper(t,middlewares["*"],n,o,u,!0)}const MimetypesKind={opus:"video/ogg",ogv:"video/ogg",mp4:"video/mp4",mov:"video/mp4",m4v:"video/mp4",mkv:"video/x-matroska",m4a:"audio/mp4",mp3:"audio/mpeg",aac:"audio/aac",caf:"audio/x-caf",flac:"audio/flac",oga:"audio/ogg",wav:"audio/wav",m3u8:"application/x-mpegURL",mpd:"application/dash+xml",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",png:"image/png",svg:"image/svg+xml",webp:"image/webp"},getMimetype=function(t=""){const e=getFileExtension(t);return MimetypesKind[e.toLowerCase()]||""},findMimetype=(t,e)=>{if(!e)return"";if(t.cache_.source.src===e&&t.cache_.source.type)return t.cache_.source.type;const n=t.cache_.sources.filter(u=>u.src===e);if(n.length)return n[0].type;const o=t.$$("source");for(let u=0;u<o.length;u++){const l=o[u];if(l.type&&l.src&&l.src===e)return l.type}return getMimetype(e)},filterSource=function(t){if(Array.isArray(t)){let e=[];t.forEach(function(n){n=filterSource(n),Array.isArray(n)?e=e.concat(n):isObject$1(n)&&e.push(n)}),t=e}else typeof t=="string"&&t.trim()?t=[fixSource({src:t})]:isObject$1(t)&&typeof t.src=="string"&&t.src&&t.src.trim()?t=[fixSource(t)]:t=[];return t};function fixSource(t){if(!t.type){const e=getMimetype(t.src);e&&(t.type=e)}return t}var icons=`<svg xmlns="http://www.w3.org/2000/svg">
  <defs>
    <symbol viewBox="0 0 48 48" id="vjs-icon-play">
      <path d="M16 10v28l22-14z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-pause">
      <path d="M12 38h8V10h-8v28zm16-28v28h8V10h-8z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-audio">
      <path d="M24 2C14.06 2 6 10.06 6 20v14c0 3.31 2.69 6 6 6h6V24h-8v-4c0-7.73 6.27-14 14-14s14 6.27 14 14v4h-8v16h6c3.31 0 6-2.69 6-6V20c0-9.94-8.06-18-18-18z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-captions">
      <path d="M38 8H10c-2.21 0-4 1.79-4 4v24c0 2.21 1.79 4 4 4h28c2.21 0 4-1.79 4-4V12c0-2.21-1.79-4-4-4zM22 22h-3v-1h-4v6h4v-1h3v2a2 2 0 0 1-2 2h-6a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v2zm14 0h-3v-1h-4v6h4v-1h3v2a2 2 0 0 1-2 2h-6a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v2z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-subtitles">
      <path d="M40 8H8c-2.21 0-4 1.79-4 4v24c0 2.21 1.79 4 4 4h32c2.21 0 4-1.79 4-4V12c0-2.21-1.79-4-4-4zM8 24h8v4H8v-4zm20 12H8v-4h20v4zm12 0h-8v-4h8v4zm0-8H20v-4h20v4z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-fullscreen-enter">
      <path d="M14 28h-4v10h10v-4h-6v-6zm-4-8h4v-6h6v-4H10v10zm24 14h-6v4h10V28h-4v6zm-6-24v4h6v6h4V10H28z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-fullscreen-exit">
      <path d="M10 32h6v6h4V28H10v4zm6-16h-6v4h10V10h-4v6zm12 22h4v-6h6v-4H28v10zm4-22v-6h-4v10h10v-4h-6z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-play-circle">
      <path d="M20 33l12-9-12-9v18zm4-29C12.95 4 4 12.95 4 24s8.95 20 20 20 20-8.95 20-20S35.05 4 24 4zm0 36c-8.82 0-16-7.18-16-16S15.18 8 24 8s16 7.18 16 16-7.18 16-16 16z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-volume-mute">
      <path d="M33 24c0-3.53-2.04-6.58-5-8.05v4.42l4.91 4.91c.06-.42.09-.85.09-1.28zm5 0c0 1.88-.41 3.65-1.08 5.28l3.03 3.03C41.25 29.82 42 27 42 24c0-8.56-5.99-15.72-14-17.54v4.13c5.78 1.72 10 7.07 10 13.41zM8.55 6L6 8.55 15.45 18H6v12h8l10 10V26.55l8.51 8.51c-1.34 1.03-2.85 1.86-4.51 2.36v4.13a17.94 17.94 0 0 0 7.37-3.62L39.45 42 42 39.45l-18-18L8.55 6zM24 8l-4.18 4.18L24 16.36V8z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-volume-low">
      <path d="M14 18v12h8l10 10V8L22 18h-8z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-volume-medium">
      <path d="M37 24c0-3.53-2.04-6.58-5-8.05v16.11c2.96-1.48 5-4.53 5-8.06zm-27-6v12h8l10 10V8L18 18h-8z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-volume-high">
      <path d="M6 18v12h8l10 10V8L14 18H6zm27 6c0-3.53-2.04-6.58-5-8.05v16.11c2.96-1.48 5-4.53 5-8.06zM28 6.46v4.13c5.78 1.72 10 7.07 10 13.41s-4.22 11.69-10 13.41v4.13c8.01-1.82 14-8.97 14-17.54S36.01 8.28 28 6.46z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-spinner">
      <path d="M18.8 21l9.53-16.51C26.94 4.18 25.49 4 24 4c-4.8 0-9.19 1.69-12.64 4.51l7.33 12.69.11-.2zm24.28-3c-1.84-5.85-6.3-10.52-11.99-12.68L23.77 18h19.31zm.52 2H28.62l.58 1 9.53 16.5C41.99 33.94 44 29.21 44 24c0-1.37-.14-2.71-.4-4zm-26.53 4l-7.8-13.5C6.01 14.06 4 18.79 4 24c0 1.37.14 2.71.4 4h14.98l-2.31-4zM4.92 30c1.84 5.85 6.3 10.52 11.99 12.68L24.23 30H4.92zm22.54 0l-7.8 13.51c1.4.31 2.85.49 4.34.49 4.8 0 9.19-1.69 12.64-4.51L29.31 26.8 27.46 30z"></path>
    </symbol>
    <symbol viewBox="0 0 24 24" id="vjs-icon-hd">
      <path d="M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-8 12H9.5v-2h-2v2H6V9h1.5v2.5h2V9H11v6zm2-6h4c.55 0 1 .45 1 1v4c0 .55-.45 1-1 1h-4V9zm1.5 4.5h2v-3h-2v3z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-chapters">
      <path d="M6 26h4v-4H6v4zm0 8h4v-4H6v4zm0-16h4v-4H6v4zm8 8h28v-4H14v4zm0 8h28v-4H14v4zm0-20v4h28v-4H14z"></path>
    </symbol>
    <symbol viewBox="0 0 40 40" id="vjs-icon-downloading">
      <path d="M18.208 36.875q-3.208-.292-5.979-1.729-2.771-1.438-4.812-3.729-2.042-2.292-3.188-5.229-1.146-2.938-1.146-6.23 0-6.583 4.334-11.416 4.333-4.834 10.833-5.5v3.166q-5.167.75-8.583 4.646Q6.25 14.75 6.25 19.958q0 5.209 3.396 9.104 3.396 3.896 8.562 4.646zM20 28.417L11.542 20l2.083-2.083 4.917 4.916v-11.25h2.916v11.25l4.875-4.916L28.417 20zm1.792 8.458v-3.167q1.833-.25 3.541-.958 1.709-.708 3.167-1.875l2.333 2.292q-1.958 1.583-4.25 2.541-2.291.959-4.791 1.167zm6.791-27.792q-1.541-1.125-3.25-1.854-1.708-.729-3.541-1.021V3.042q2.5.25 4.77 1.208 2.271.958 4.271 2.5zm4.584 21.584l-2.25-2.25q1.166-1.5 1.854-3.209.687-1.708.937-3.541h3.209q-.292 2.5-1.229 4.791-.938 2.292-2.521 4.209zm.541-12.417q-.291-1.833-.958-3.562-.667-1.73-1.833-3.188l2.375-2.208q1.541 1.916 2.458 4.208.917 2.292 1.167 4.75z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-file-download">
      <path d="M10.8 40.55q-1.35 0-2.375-1T7.4 37.15v-7.7h3.4v7.7h26.35v-7.7h3.4v7.7q0 1.4-1 2.4t-2.4 1zM24 32.1L13.9 22.05l2.45-2.45 5.95 5.95V7.15h3.4v18.4l5.95-5.95 2.45 2.45z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-file-download-done">
      <path d="M9.8 40.5v-3.45h28.4v3.45zm9.2-9.05L7.4 19.85l2.45-2.35L19 26.65l19.2-19.2 2.4 2.4z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-file-download-off">
      <path d="M4.9 4.75L43.25 43.1 41 45.3l-4.75-4.75q-.05.05-.075.025-.025-.025-.075-.025H10.8q-1.35 0-2.375-1T7.4 37.15v-7.7h3.4v7.7h22.05l-7-7-1.85 1.8L13.9 21.9l1.85-1.85L2.7 7zm26.75 14.7l2.45 2.45-3.75 3.8-2.45-2.5zM25.7 7.15V21.1l-3.4-3.45V7.15z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-share">
      <path d="M36 32.17c-1.52 0-2.89.59-3.93 1.54L17.82 25.4c.11-.45.18-.92.18-1.4s-.07-.95-.18-1.4l14.1-8.23c1.07 1 2.5 1.62 4.08 1.62 3.31 0 6-2.69 6-6s-2.69-6-6-6-6 2.69-6 6c0 .48.07.95.18 1.4l-14.1 8.23c-1.07-1-2.5-1.62-4.08-1.62-3.31 0-6 2.69-6 6s2.69 6 6 6c1.58 0 3.01-.62 4.08-1.62l14.25 8.31c-.1.42-.16.86-.16 1.31A5.83 5.83 0 1 0 36 32.17z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-cog">
      <path d="M38.86 25.95c.08-.64.14-1.29.14-1.95s-.06-1.31-.14-1.95l4.23-3.31c.38-.3.49-.84.24-1.28l-4-6.93c-.25-.43-.77-.61-1.22-.43l-4.98 2.01c-1.03-.79-2.16-1.46-3.38-1.97L29 4.84c-.09-.47-.5-.84-1-.84h-8c-.5 0-.91.37-.99.84l-.75 5.3a14.8 14.8 0 0 0-3.38 1.97L9.9 10.1a1 1 0 0 0-1.22.43l-4 6.93c-.25.43-.14.97.24 1.28l4.22 3.31C9.06 22.69 9 23.34 9 24s.06 1.31.14 1.95l-4.22 3.31c-.38.3-.49.84-.24 1.28l4 6.93c.25.43.77.61 1.22.43l4.98-2.01c1.03.79 2.16 1.46 3.38 1.97l.75 5.3c.08.47.49.84.99.84h8c.5 0 .91-.37.99-.84l.75-5.3a14.8 14.8 0 0 0 3.38-1.97l4.98 2.01a1 1 0 0 0 1.22-.43l4-6.93c.25-.43.14-.97-.24-1.28l-4.22-3.31zM24 31c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-square">
      <path d="M36 8H12c-2.21 0-4 1.79-4 4v24c0 2.21 1.79 4 4 4h24c2.21 0 4-1.79 4-4V12c0-2.21-1.79-4-4-4zm0 28H12V12h24v24z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-circle">
      <circle cx="24" cy="24" r="20"></circle>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-circle-outline">
      <path d="M24 4C12.95 4 4 12.95 4 24s8.95 20 20 20 20-8.95 20-20S35.05 4 24 4zm0 36c-8.82 0-16-7.18-16-16S15.18 8 24 8s16 7.18 16 16-7.18 16-16 16z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-circle-inner-circle">
      <path d="M24 4C12.97 4 4 12.97 4 24s8.97 20 20 20 20-8.97 20-20S35.03 4 24 4zm0 36c-8.82 0-16-7.18-16-16S15.18 8 24 8s16 7.18 16 16-7.18 16-16 16zm6-16c0 3.31-2.69 6-6 6s-6-2.69-6-6 2.69-6 6-6 6 2.69 6 6z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-cancel">
      <path d="M24 4C12.95 4 4 12.95 4 24s8.95 20 20 20 20-8.95 20-20S35.05 4 24 4zm10 27.17L31.17 34 24 26.83 16.83 34 14 31.17 21.17 24 14 16.83 16.83 14 24 21.17 31.17 14 34 16.83 26.83 24 34 31.17z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-replay">
      <path d="M24 10V2L14 12l10 10v-8c6.63 0 12 5.37 12 12s-5.37 12-12 12-12-5.37-12-12H8c0 8.84 7.16 16 16 16s16-7.16 16-16-7.16-16-16-16z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-repeat">
      <path d="M14 14h20v6l8-8-8-8v6H10v12h4v-8zm20 20H14v-6l-8 8 8 8v-6h24V26h-4v8z"></path>
    </symbol>
    <symbol viewBox="0 96 48 48" id="vjs-icon-replay-5">
      <path d="M17.689 98l-8.697 8.696 8.697 8.697 2.486-2.485-4.32-4.319h1.302c4.93 0 9.071 1.722 12.424 5.165 3.352 3.443 5.029 7.638 5.029 12.584h3.55c0-2.958-.553-5.73-1.658-8.313-1.104-2.583-2.622-4.841-4.555-6.774-1.932-1.932-4.19-3.45-6.773-4.555-2.584-1.104-5.355-1.657-8.313-1.657H15.5l4.615-4.615zm-8.08 21.659v13.861h11.357v5.008H9.609V143h12.7c.834 0 1.55-.298 2.146-.894.596-.597.895-1.31.895-2.145v-7.781c0-.835-.299-1.55-.895-2.147a2.929 2.929 0 0 0-2.147-.894h-8.227v-5.096H25.35v-4.384z"></path>
    </symbol>
    <symbol viewBox="0 96 48 48" id="vjs-icon-replay-10">
      <path d="M42.315 125.63c0-4.997-1.694-9.235-5.08-12.713-3.388-3.479-7.571-5.218-12.552-5.218h-1.315l4.363 4.363-2.51 2.51-8.787-8.786L25.221 97l2.45 2.45-4.662 4.663h1.375c2.988 0 5.788.557 8.397 1.673 2.61 1.116 4.892 2.65 6.844 4.602 1.953 1.953 3.487 4.234 4.602 6.844 1.116 2.61 1.674 5.41 1.674 8.398zM8.183 142v-19.657H3.176V117.8h9.643V142zm13.63 0c-1.156 0-2.127-.393-2.912-1.178-.778-.778-1.168-1.746-1.168-2.902v-16.04c0-1.156.393-2.127 1.178-2.912.779-.779 1.746-1.168 2.902-1.168h7.696c1.156 0 2.126.392 2.911 1.177.779.78 1.168 1.747 1.168 2.903v16.04c0 1.156-.392 2.127-1.177 2.912-.779.779-1.746 1.168-2.902 1.168zm.556-4.636h6.583v-15.02H22.37z"></path>
    </symbol>
    <symbol viewBox="0 96 48 48" id="vjs-icon-replay-30">
      <path d="M26.047 97l-8.733 8.732 8.733 8.733 2.496-2.494-4.336-4.338h1.307c4.95 0 9.108 1.73 12.474 5.187 3.367 3.458 5.051 7.668 5.051 12.635h3.565c0-2.97-.556-5.751-1.665-8.346-1.109-2.594-2.633-4.862-4.574-6.802-1.94-1.941-4.208-3.466-6.803-4.575-2.594-1.109-5.375-1.664-8.345-1.664H23.85l4.634-4.634zM2.555 117.531v4.688h10.297v5.25H5.873v4.687h6.979v5.156H2.555V142H13.36c1.061 0 1.95-.395 2.668-1.186.718-.79 1.076-1.772 1.076-2.94v-16.218c0-1.168-.358-2.149-1.076-2.94-.717-.79-1.607-1.185-2.668-1.185zm22.482.14c-1.149 0-2.11.39-2.885 1.165-.78.78-1.172 1.744-1.172 2.893v15.943c0 1.149.388 2.11 1.163 2.885.78.78 1.745 1.172 2.894 1.172h7.649c1.148 0 2.11-.388 2.884-1.163.78-.78 1.17-1.745 1.17-2.894v-15.943c0-1.15-.386-2.111-1.16-2.885-.78-.78-1.746-1.172-2.894-1.172zm.553 4.518h6.545v14.93H25.59z"></path>
    </symbol>
    <symbol viewBox="0 96 48 48" id="vjs-icon-forward-5">
      <path d="M29.508 97l-2.431 2.43 4.625 4.625h-1.364c-2.965 0-5.742.554-8.332 1.66-2.589 1.107-4.851 2.629-6.788 4.566-1.937 1.937-3.458 4.2-4.565 6.788-1.107 2.59-1.66 5.367-1.66 8.331h3.557c0-4.957 1.68-9.16 5.04-12.611 3.36-3.45 7.51-5.177 12.451-5.177h1.304l-4.326 4.33 2.49 2.49 8.715-8.716zm-9.783 21.61v13.89h11.382v5.018H19.725V142h12.727a2.93 2.93 0 0 0 2.15-.896 2.93 2.93 0 0 0 .896-2.15v-7.798c0-.837-.299-1.554-.896-2.152a2.93 2.93 0 0 0-2.15-.896h-8.245V123h11.29v-4.392z"></path>
    </symbol>
    <symbol viewBox="0 96 48 48" id="vjs-icon-forward-10">
      <path d="M23.119 97l-2.386 2.383 4.538 4.538h-1.339c-2.908 0-5.633.543-8.173 1.63-2.54 1.085-4.76 2.577-6.66 4.478-1.9 1.9-3.392 4.12-4.478 6.66-1.085 2.54-1.629 5.264-1.629 8.172h3.49c0-4.863 1.648-8.986 4.944-12.372 3.297-3.385 7.368-5.078 12.216-5.078h1.279l-4.245 4.247 2.443 2.442 8.55-8.55zm-9.52 21.45v4.42h4.871V142h4.513v-23.55zm18.136 0c-1.125 0-2.066.377-2.824 1.135-.764.764-1.148 1.709-1.148 2.834v15.612c0 1.124.38 2.066 1.139 2.824.764.764 1.708 1.145 2.833 1.145h7.489c1.125 0 2.066-.378 2.824-1.136.764-.764 1.145-1.709 1.145-2.833v-15.612c0-1.125-.378-2.067-1.136-2.825-.764-.764-1.708-1.145-2.833-1.145zm.54 4.42h6.408v14.617h-6.407z"></path>
    </symbol>
    <symbol viewBox="0 96 48 48" id="vjs-icon-forward-30">
      <path d="M25.549 97l-2.437 2.434 4.634 4.635H26.38c-2.97 0-5.753.555-8.347 1.664-2.594 1.109-4.861 2.633-6.802 4.574-1.94 1.94-3.465 4.207-4.574 6.802-1.109 2.594-1.664 5.377-1.664 8.347h3.565c0-4.967 1.683-9.178 5.05-12.636 3.366-3.458 7.525-5.187 12.475-5.187h1.307l-4.335 4.338 2.495 2.494 8.732-8.732zm-11.553 20.53v4.689h10.297v5.249h-6.978v4.688h6.978v5.156H13.996V142h10.808c1.06 0 1.948-.395 2.666-1.186.718-.79 1.077-1.771 1.077-2.94v-16.217c0-1.169-.36-2.15-1.077-2.94-.718-.79-1.605-1.186-2.666-1.186zm21.174.168c-1.149 0-2.11.389-2.884 1.163-.78.78-1.172 1.745-1.172 2.894v15.942c0 1.15.388 2.11 1.162 2.885.78.78 1.745 1.17 2.894 1.17h7.649c1.149 0 2.11-.386 2.885-1.16.78-.78 1.17-1.746 1.17-2.895v-15.942c0-1.15-.387-2.11-1.161-2.885-.78-.78-1.745-1.172-2.894-1.172zm.552 4.516h6.542v14.931h-6.542z"></path>
    </symbol>
    <symbol viewBox="0 0 512 512" id="vjs-icon-audio-description">
      <g fill-rule="evenodd"><path d="M227.29 381.351V162.993c50.38-1.017 89.108-3.028 117.631 17.126 27.374 19.342 48.734 56.965 44.89 105.325-4.067 51.155-41.335 94.139-89.776 98.475-24.085 2.155-71.972 0-71.972 0s-.84-1.352-.773-2.568m48.755-54.804c31.43 1.26 53.208-16.633 56.495-45.386 4.403-38.51-21.188-63.552-58.041-60.796v103.612c-.036 1.466.575 2.22 1.546 2.57"></path><path d="M383.78 381.328c13.336 3.71 17.387-11.06 23.215-21.408 12.722-22.571 22.294-51.594 22.445-84.774.221-47.594-18.343-82.517-35.6-106.182h-8.51c-.587 3.874 2.226 7.315 3.865 10.276 13.166 23.762 25.367 56.553 25.54 94.194.2 43.176-14.162 79.278-30.955 107.894"></path><path d="M425.154 381.328c13.336 3.71 17.384-11.061 23.215-21.408 12.721-22.571 22.291-51.594 22.445-84.774.221-47.594-18.343-82.517-35.6-106.182h-8.511c-.586 3.874 2.226 7.315 3.866 10.276 13.166 23.762 25.367 56.553 25.54 94.194.2 43.176-14.162 79.278-30.955 107.894"></path><path d="M466.26 381.328c13.337 3.71 17.385-11.061 23.216-21.408 12.722-22.571 22.292-51.594 22.445-84.774.221-47.594-18.343-82.517-35.6-106.182h-8.51c-.587 3.874 2.225 7.315 3.865 10.276 13.166 23.762 25.367 56.553 25.54 94.194.2 43.176-14.162 79.278-30.955 107.894M4.477 383.005H72.58l18.573-28.484 64.169-.135s.065 19.413.065 28.62h48.756V160.307h-58.816c-5.653 9.537-140.85 222.697-140.85 222.697zm152.667-145.282v71.158l-40.453-.27 40.453-70.888z"></path></g>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-next-item">
      <path d="M12 36l17-12-17-12v24zm20-24v24h4V12h-4z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-previous-item">
      <path d="M12 12h4v24h-4zm7 12l17 12V12z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-shuffle">
      <path d="M21.17 18.34L10.83 8 8 10.83l10.34 10.34 2.83-2.83zM29 8l4.09 4.09L8 37.17 10.83 40l25.09-25.09L40 19V8H29zm.66 18.83l-2.83 2.83 6.26 6.26L29 40h11V29l-4.09 4.09-6.25-6.26z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-cast">
      <path d="M42 6H6c-2.21 0-4 1.79-4 4v6h4v-6h36v28H28v4h14c2.21 0 4-1.79 4-4V10c0-2.21-1.79-4-4-4zM2 36v6h6c0-3.31-2.69-6-6-6zm0-8v4c5.52 0 10 4.48 10 10h4c0-7.73-6.27-14-14-14zm0-8v4c9.94 0 18 8.06 18 18h4c0-12.15-9.85-22-22-22z"></path>
    </symbol>
    <symbol viewBox="0 0 48 48" id="vjs-icon-picture-in-picture-enter">
      <path d="M38 22H22v11.99h16V22zm8 16V9.96C46 7.76 44.2 6 42 6H6C3.8 6 2 7.76 2 9.96V38c0 2.2 1.8 4 4 4h36c2.2 0 4-1.8 4-4zm-4 .04H6V9.94h36v28.1z"></path>
    </symbol>
    <symbol viewBox="0 0 22 18" id="vjs-icon-picture-in-picture-exit">
      <path d="M18 4H4v10h14V4zm4 12V1.98C22 .88 21.1 0 20 0H2C.9 0 0 .88 0 1.98V16c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2zm-2 .02H2V1.97h18v14.05z"></path>
      <path fill="none" d="M-1-3h24v24H-1z"></path>
    </symbol>
    <symbol viewBox="0 0 1792 1792" id="vjs-icon-facebook">
      <path d="M1343 12v264h-157q-86 0-116 36t-30 108v189h293l-39 296h-254v759H734V905H479V609h255V391q0-186 104-288.5T1115 0q147 0 228 12z"></path>
    </symbol>
    <symbol viewBox="0 0 1792 1792" id="vjs-icon-linkedin">
      <path d="M477 625v991H147V625h330zm21-306q1 73-50.5 122T312 490h-2q-82 0-132-49t-50-122q0-74 51.5-122.5T314 148t133 48.5T498 319zm1166 729v568h-329v-530q0-105-40.5-164.5T1168 862q-63 0-105.5 34.5T999 982q-11 30-11 81v553H659q2-399 2-647t-1-296l-1-48h329v144h-2q20-32 41-56t56.5-52 87-43.5T1285 602q171 0 275 113.5t104 332.5z"></path>
    </symbol>
    <symbol viewBox="0 0 1200 1227" id="vjs-icon-twitter">
      <path d="M714.163 519.284L1160.89 0H1055.03L667.137 450.887L357.328 0H0L468.492 681.821L0 1226.37H105.866L515.491 750.218L842.672 1226.37H1200L714.137 519.284H714.163ZM569.165 687.828L521.697 619.934L144.011 79.6944H306.615L611.412 515.685L658.88 583.579L1055.08 1150.3H892.476L569.165 687.854V687.828Z"/>
    </symbol>
    <symbol viewBox="0 0 1792 1792" id="vjs-icon-tumblr">
      <path d="M1328 1329l80 237q-23 35-111 66t-177 32q-104 2-190.5-26T787 1564t-95-106-55.5-120-16.5-118V676H452V461q72-26 129-69.5t91-90 58-102 34-99T779 12q1-5 4.5-8.5T791 0h244v424h333v252h-334v518q0 30 6.5 56t22.5 52.5 49.5 41.5 81.5 14q78-2 134-29z"></path>
    </symbol>
    <symbol viewBox="0 0 1792 1792" id="vjs-icon-pinterest">
      <path d="M1664 896q0 209-103 385.5T1281.5 1561 896 1664q-111 0-218-32 59-93 78-164 9-34 54-211 20 39 73 67.5t114 28.5q121 0 216-68.5t147-188.5 52-270q0-114-59.5-214T1180 449t-255-63q-105 0-196 29t-154.5 77-109 110.5-67 129.5T377 866q0 104 40 183t117 111q30 12 38-20 2-7 8-31t8-30q6-23-11-43-51-61-51-151 0-151 104.5-259.5T904 517q151 0 235.5 82t84.5 213q0 170-68.5 289T980 1220q-61 0-98-43.5T859 1072q8-35 26.5-93.5t30-103T927 800q0-50-27-83t-77-33q-62 0-105 57t-43 142q0 73 25 122l-99 418q-17 70-13 177-206-91-333-281T128 896q0-209 103-385.5T510.5 231 896 128t385.5 103T1561 510.5 1664 896z"></path>
    </symbol>
  </defs>
</svg>`;const backKeyCode=IS_TIZEN?10009:IS_WEBOS?461:8,SpatialNavKeyCodes={codes:{play:415,pause:19,ff:417,rw:412,back:backKeyCode},names:{415:"play",19:"pause",417:"ff",412:"rw",[backKeyCode]:"back"},isEventKey(t,e){return e=e.toLowerCase(),!!(this.names[t.keyCode]&&this.names[t.keyCode]===e)},getEventName(t){if(this.names[t.keyCode])return this.names[t.keyCode];if(this.codes[t.code]){const e=this.codes[t.code];return this.names[e]}return null}},STEP_SECONDS$1=5;class SpatialNavigation extends EventTarget$2{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 n=e.originalEvent?e.originalEvent:e;if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].includes(n.key)){if(this.isPaused_)return;n.preventDefault();const o=n.key.substring(5).toLowerCase();this.move(o)}else if(SpatialNavKeyCodes.isEventKey(n,"play")||SpatialNavKeyCodes.isEventKey(n,"pause")||SpatialNavKeyCodes.isEventKey(n,"ff")||SpatialNavKeyCodes.isEventKey(n,"rw")){n.preventDefault();const o=SpatialNavKeyCodes.getEventName(n);this.performMediaAction_(o)}else SpatialNavKeyCodes.isEventKey(n,"Back")&&e.target&&typeof e.target.closeable=="function"&&e.target.closeable()&&(n.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()+STEP_SECONDS$1);break;case"rw":this.userSeek_(this.player_.currentTime()-STEP_SECONDS$1);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 n=e.relatedTarget;let o=null;const u=this.getCurrentComponent(e.target);n&&(o=!!n.closest(".video-js"),n.classList.contains("vjs-text-track-settings")&&!this.isPaused_&&this.searchForTrackSelect_()),(!e.currentTarget.contains(e.relatedTarget)&&!o||!n)&&(u&&u.name()==="CloseButton"?this.refocusComponent():(this.pause(),u&&u.el()&&(this.lastFocusedComponent_=u)))}handlePlayerFocus_(){this.getCurrentComponent()&&this.getCurrentComponent().getIsFocusable()&&this.resume()}updateFocusableComponents(){const e=this.player_,n=[];function o(u){for(const l of u)l.hasOwnProperty("el_")&&l.getIsFocusable()&&l.getIsAvailableToBeFocused(l.el())&&n.push(l),l.hasOwnProperty("children_")&&l.children_.length>0&&o(l.children_)}return e.children_.forEach(u=>{if(u.hasOwnProperty("el_"))if(u.getIsFocusable&&u.getIsAvailableToBeFocused&&u.getIsFocusable()&&u.getIsAvailableToBeFocused(u.el())){n.push(u);return}else u.hasOwnProperty("children_")&&u.children_.length>0?o(u.children_):u.hasOwnProperty("items")&&u.items.length>0?o(u.items):this.findSuitableDOMChild(u)&&n.push(u);if(u.name_==="ErrorDisplay"&&u.opened_){const l=u.el_.querySelector(".vjs-errors-ok-button-container");l&&l.querySelectorAll("button").forEach((y,E)=>{n.push({name:()=>"ModalButton"+(E+1),el:()=>y,getPositions:()=>{const C=y.getBoundingClientRect(),k={x:C.x,y:C.y,width:C.width,height:C.height,top:C.top,right:C.right,bottom:C.bottom,left:C.left},A={x:C.left+C.width/2,y:C.top+C.height/2,width:0,height:0,top:C.top+C.height/2,right:C.left+C.width/2,bottom:C.top+C.height/2,left:C.left+C.width/2};return{boundingClientRect:k,center:A}},getIsAvailableToBeFocused:()=>!0,getIsFocusable:C=>!0,focus:()=>y.focus()})})}}),this.focusableComponents=n,this.focusableComponents}findSuitableDOMChild(e){function n(o){if(e.getIsFocusable(o)&&e.getIsAvailableToBeFocused(o))return o;for(let u=0;u<o.children.length;u++){const l=o.children[u],m=n(l);if(m)return m}return null}return e.el()?n(e.el()):null}getCurrentComponent(e){this.updateFocusableComponents();const n=e||document.activeElement;if(this.focusableComponents.length){for(const o of this.focusableComponents)if(o.el()===n)return o}}add(e){const n=[...this.focusableComponents];e.hasOwnProperty("el_")&&e.getIsFocusable()&&e.getIsAvailableToBeFocused(e.el())&&n.push(e),this.focusableComponents=n,this.trigger({type:"focusableComponentsChanged",focusableComponents:this.focusableComponents})}remove(e){for(let n=0;n<this.focusableComponents.length;n++)if(this.focusableComponents[n].name()===e.name()){this.focusableComponents.splice(n,1),this.trigger({type:"focusableComponentsChanged",focusableComponents:this.focusableComponents});return}}clear(){this.focusableComponents.length>0&&(this.focusableComponents=[],this.trigger({type:"focusableComponentsChanged",focusableComponents:this.focusableComponents}))}move(e){const n=this.getCurrentComponent();if(!n)return;const o=n.getPositions(),u=this.focusableComponents.filter(m=>m!==n&&this.isInDirection_(o.boundingClientRect,m.getPositions().boundingClientRect,e)),l=this.findBestCandidate_(o.center,u,e);l?this.focus(l):this.trigger({type:"endOfFocusableComponents",direction:e,focusedComponent:n})}findBestCandidate_(e,n,o){let u=1/0,l=null;for(const m of n){const y=m.getPositions().center,E=this.calculateDistance_(e,y,o);E<u&&(u=E,l=m)}return l}isInDirection_(e,n,o){switch(o){case"right":return n.left>=e.right;case"left":return n.right<=e.left;case"down":return n.top>=e.bottom;case"up":return n.bottom<=e.top;default:return!1}}refocusComponent(){if(this.lastFocusedComponent_){this.player_.userActive()||this.player_.userActive(!0),this.updateFocusableComponents();for(let e=0;e<this.focusableComponents.length;e++)if(this.focusableComponents[e].name()===this.lastFocusedComponent_.name()){this.focus(this.focusableComponents[e]);return}}else this.focus(this.updateFocusableComponents()[0])}focus(e){typeof e=="object"&&(e.getIsAvailableToBeFocused(e.el())?e.focus():this.findSuitableDOMChild(e)&&this.findSuitableDOMChild(e).focus())}calculateDistance_(e,n,o){const u=Math.abs(e.x-n.x),l=Math.abs(e.y-n.y);let m;switch(o){case"right":case"left":m=u+l*100;break;case"up":m=l*2+u*.5;break;case"down":m=l*5+u;break;default:m=u+l}return m}searchForTrackSelect_(){const e=this;for(const n of e.updateFocusableComponents())if(n.constructor.name==="TextTrackSelect"){e.focus(n);break}}}class MediaLoader extends Component$1{constructor(e,n,o){const u=merge$1({createEl:!1},n);if(super(e,u,o),!n.playerOptions.sources||n.playerOptions.sources.length===0)for(let l=0,m=n.playerOptions.techOrder;l<m.length;l++){const y=toTitleCase$1(m[l]);let E=Tech$1.getTech(y);if(y||(E=Component$1.getComponent(y)),E&&E.isSupported()){e.loadTech_(y);break}}else e.src(n.playerOptions.sources)}}Component$1.registerComponent("MediaLoader",MediaLoader);class ClickableComponent extends Component$1{constructor(e,n){super(e,n),this.options_.controlText&&this.controlText(this.options_.controlText),this.handleMouseOver_=o=>this.handleMouseOver(o),this.handleMouseOut_=o=>this.handleMouseOut(o),this.handleClick_=o=>this.handleClick(o),this.handleKeyDown_=o=>this.handleKeyDown(o),this.emitTapEvents(),this.enable()}createEl(e="div",n={},o={}){n=Object.assign({className:this.buildCSSClass(),tabIndex:0},n),e==="button"&&log$1.error(`Creating a ClickableComponent with an HTML element of ${e} is not supported; use a Button instead.`),o=Object.assign({role:"button"},o),this.tabIndex_=n.tabIndex;const u=createEl(e,n,o);return this.player_.options_.experimentalSvgIcons||u.appendChild(createEl("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),this.createControlTextEl(u),u}dispose(){this.controlTextEl_=null,super.dispose()}createControlTextEl(e){return this.controlTextEl_=createEl("span",{className:"vjs-control-text"},{"aria-live":"polite"}),e&&e.appendChild(this.controlTextEl_),this.controlText(this.controlText_,e),this.controlTextEl_}controlText(e,n=this.el()){if(e===void 0)return this.controlText_||"Need Text";const o=this.localize(e);this.controlText_=e,textContent(this.controlTextEl_,o),!this.nonIconControl&&!this.player_.options_.noUITitleAttributes&&n.setAttribute("title",o)}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)}}Component$1.registerComponent("ClickableComponent",ClickableComponent);class PosterImage extends ClickableComponent{constructor(e,n){super(e,n),this.update(),this.update_=o=>this.update(o),e.on("posterchange",this.update_)}dispose(){this.player().off("posterchange",this.update_),super.dispose()}createEl(){return createEl("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 n=this.player().poster();this.setSrc(n),n?this.show():this.hide()}setSrc(e){if(!e){this.el_.textContent="";return}this.$("img")||this.el_.appendChild(createEl("picture",{className:"vjs-poster",tabIndex:-1},{},createEl("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()?silencePromise(this.player_.play()):this.player_.pause())}}PosterImage.prototype.crossorigin=PosterImage.prototype.crossOrigin,Component$1.registerComponent("PosterImage",PosterImage);const darkGray="#222",lightGray="#ccc",fontMap={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 constructColor(t,e){let n;if(t.length===4)n=t[1]+t[1]+t[2]+t[2]+t[3]+t[3];else if(t.length===7)n=t.slice(1);else throw new Error("Invalid color code provided, "+t+"; must be formatted as e.g. #f0e or #f604e2.");return"rgba("+parseInt(n.slice(0,2),16)+","+parseInt(n.slice(2,4),16)+","+parseInt(n.slice(4,6),16)+","+e+")"}function tryUpdateStyle(t,e,n){try{t.style[e]=n}catch{return}}function getCSSPositionValue(t){return t?`${t}px`:""}class TextTrackDisplay extends Component$1{constructor(e,n,o){super(e,n,o);const u=m=>this.updateDisplay(m),l=m=>{this.updateDisplayOverlay(),this.updateDisplay(m)};e.on("loadstart",m=>this.toggleDisplay(m)),e.on("texttrackchange",u),e.on("loadedmetadata",m=>{this.updateDisplayOverlay(),this.preselectTrack(m)}),e.ready(bind_(this,function(){if(e.tech_&&e.tech_.featuresNativeTextTracks){this.hide();return}e.on("fullscreenchange",l),e.on("playerresize",l);const m=window$1$1.screen.orientation||window$1$1,y=window$1$1.screen.orientation?"change":"orientationchange";m.addEventListener(y,l),e.on("dispose",()=>m.removeEventListener(y,l));const E=this.options_.playerOptions.tracks||[];for(let C=0;C<E.length;C++)this.player_.addRemoteTextTrack(E[C],!0);this.preselectTrack()}))}preselectTrack(){const e={captions:1,subtitles:1},n=this.player_.textTracks(),o=this.player_.cache_.selectedLanguage;let u,l,m;for(let y=0;y<n.length;y++){const E=n[y];o&&o.enabled&&o.language&&o.language===E.language&&E.kind in e?E.kind===o.kind?m=E:m||(m=E):o&&!o.enabled?(m=null,u=null,l=null):E.default&&(E.kind==="descriptions"&&!u?u=E:E.kind in e&&!l&&(l=E))}m?m.mode="showing":l?l.mode="showing":u&&(u.mode="showing")}toggleDisplay(){this.player_.tech_&&this.player_.tech_.featuresNativeTextTracks?this.hide():this.show()}createEl(){return super.createEl("div",{className:"vjs-text-track-display"},{translate:"yes","aria-live":"off","aria-atomic":"true"})}clearDisplay(){typeof window$1$1.WebVTT=="function"&&window$1$1.WebVTT.processCues(window$1$1,[],this.el_)}updateDisplay(){const e=this.player_.textTracks(),n=this.options_.allowMultipleShowingTracks;if(this.clearDisplay(),n){const m=[];for(let y=0;y<e.length;++y){const E=e[y];E.mode==="showing"&&m.push(E)}this.updateForTrack(m);return}let o=null,u=null,l=e.length;for(;l--;){const m=e[l];m.mode==="showing"&&(m.kind==="descriptions"?o=m:u=m)}if(u?(this.getAttribute("aria-live")!=="off"&&this.setAttribute("aria-live","off"),this.updateForTrack(u)):o&&(this.getAttribute("aria-live")!=="assertive"&&this.setAttribute("aria-live","assertive"),this.updateForTrack(o)),!window$1$1.CSS.supports("inset","10px")){const m=this.el_,y=m.querySelectorAll(".vjs-text-track-cue"),E=this.player_.controlBar.el_.getBoundingClientRect().height,C=this.player_.el_.getBoundingClientRect().height;m.style="",tryUpdateStyle(m,"position","relative"),tryUpdateStyle(m,"height",C-E+"px"),tryUpdateStyle(m,"top","unset"),IS_SMART_TV?tryUpdateStyle(m,"bottom",C+"px"):tryUpdateStyle(m,"bottom","0px"),y.length>0&&y.forEach(k=>{if(k.style.inset){const A=k.style.inset.split(" ");A.length===3&&Object.assign(k.style,{top:A[0],right:A[1],bottom:A[2],left:"unset"})}})}}updateDisplayOverlay(){if(!this.player_.videoHeight()||!window$1$1.CSS.supports("inset-inline: 10px"))return;const e=this.player_.currentWidth(),n=this.player_.currentHeight(),o=e/n,u=this.player_.videoWidth()/this.player_.videoHeight();let l=0,m=0;Math.abs(o-u)>.1&&(o>u?l=Math.round((e-n*u)/2):m=Math.round((n-e/u)/2)),tryUpdateStyle(this.el_,"insetInline",getCSSPositionValue(l)),tryUpdateStyle(this.el_,"insetBlock",getCSSPositionValue(m))}updateDisplayState(e){const n=this.player_.textTrackSettings.getValues(),o=e.activeCues;let u=o.length;for(;u--;){const l=o[u];if(!l)continue;const m=l.displayState;if(n.color&&(m.firstChild.style.color=n.color),n.textOpacity&&tryUpdateStyle(m.firstChild,"color",constructColor(n.color||"#fff",n.textOpacity)),n.backgroundColor&&(m.firstChild.style.backgroundColor=n.backgroundColor),n.backgroundOpacity&&tryUpdateStyle(m.firstChild,"backgroundColor",constructColor(n.backgroundColor||"#000",n.backgroundOpacity)),n.windowColor&&(n.windowOpacity?tryUpdateStyle(m,"backgroundColor",constructColor(n.windowColor,n.windowOpacity)):m.style.backgroundColor=n.windowColor),n.edgeStyle&&(n.edgeStyle==="dropshadow"?m.firstChild.style.textShadow=`2px 2px 3px ${darkGray}, 2px 2px 4px ${darkGray}, 2px 2px 5px ${darkGray}`:n.edgeStyle==="raised"?m.firstChild.style.textShadow=`1px 1px ${darkGray}, 2px 2px ${darkGray}, 3px 3px ${darkGray}`:n.edgeStyle==="depressed"?m.firstChild.style.textShadow=`1px 1px ${lightGray}, 0 1px ${lightGray}, -1px -1px ${darkGray}, 0 -1px ${darkGray}`:n.edgeStyle==="uniform"&&(m.firstChild.style.textShadow=`0 0 4px ${darkGray}, 0 0 4px ${darkGray}, 0 0 4px ${darkGray}, 0 0 4px ${darkGray}`)),n.fontPercent&&n.fontPercent!==1){const y=window$1$1.parseFloat(m.style.fontSize);m.style.fontSize=y*n.fontPercent+"px",m.style.height="auto",m.style.top="auto"}n.fontFamily&&n.fontFamily!=="default"&&(n.fontFamily==="small-caps"?m.firstChild.style.fontVariant="small-caps":m.firstChild.style.fontFamily=fontMap[n.fontFamily])}}updateForTrack(e){if(Array.isArray(e)||(e=[e]),typeof window$1$1.WebVTT!="function"||e.every(o=>!o.activeCues))return;const n=[];for(let o=0;o<e.length;++o){const u=e[o];for(let l=0;l<u.activeCues.length;++l)n.push(u.activeCues[l])}window$1$1.WebVTT.processCues(window$1$1,n,this.el_);for(let o=0;o<e.length;++o){const u=e[o];for(let l=0;l<u.activeCues.length;++l){const m=u.activeCues[l].displayState;addClass(m,"vjs-text-track-cue","vjs-text-track-cue-"+(u.language?u.language:o)),u.language&&setAttribute(m,"lang",u.language)}this.player_.textTrackSettings&&this.updateDisplayState(u)}}}Component$1.registerComponent("TextTrackDisplay",TextTrackDisplay);class LoadingSpinner extends Component$1{createEl(){const e=this.player_.isAudio(),n=this.localize(e?"Audio Player":"Video Player"),o=createEl("span",{className:"vjs-control-text",textContent:this.localize("{1} is loading.",[n])}),u=super.createEl("div",{className:"vjs-loading-spinner",dir:"ltr"});return u.appendChild(o),u}handleLanguagechange(){this.$(".vjs-control-text").textContent=this.localize("{1} is loading.",[this.player_.isAudio()?"Audio Player":"Video Player"])}}Component$1.registerComponent("LoadingSpinner",LoadingSpinner);class Button extends ClickableComponent{createEl(e,n={},o={}){e="button",n=Object.assign({className:this.buildCSSClass()},n),o=Object.assign({type:"button"},o);const u=createEl(e,n,o);return this.player_.options_.experimentalSvgIcons||u.appendChild(createEl("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),this.createControlTextEl(u),u}addChild(e,n={}){const o=this.constructor.name;return log$1.warn(`Adding an actionable (user controllable) child to a Button (${o}) is not supported; use a ClickableComponent instead.`),Component$1.prototype.addChild.call(this,e,n)}enable(){super.enable(),this.el_.removeAttribute("disabled")}disable(){super.disable(),this.el_.setAttribute("disabled","disabled")}handleKeyDown(e){if(e.key===" "||e.key==="Enter"){e.stopPropagation();return}super.handleKeyDown(e)}}Component$1.registerComponent("Button",Button);class BigPlayButton extends Button{constructor(e,n){super(e,n),this.mouseused_=!1,this.setIcon("play"),this.on("mousedown",o=>this.handleMouseDown(o))}buildCSSClass(){return"vjs-big-play-button"}handleClick(e){const n=this.player_.play();if(this.mouseused_&&"clientX"in e&&"clientY"in e){silencePromise(n),this.player_.tech(!0)&&this.player_.tech(!0).focus();return}const o=this.player_.getChild("controlBar"),u=o&&o.getChild("playToggle");if(!u){this.player_.tech(!0).focus();return}const l=()=>u.focus();isPromise(n)?n.then(l,()=>{}):this.setTimeout(l,1)}handleKeyDown(e){this.mouseused_=!1,super.handleKeyDown(e)}handleMouseDown(e){this.mouseused_=!0}}BigPlayButton.prototype.controlText_="Play Video",Component$1.registerComponent("BigPlayButton",BigPlayButton);class CloseButton extends Button{constructor(e,n){super(e,n),this.setIcon("cancel"),this.controlText(n&&n.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)}}Component$1.registerComponent("CloseButton",CloseButton);class PlayToggle extends Button{constructor(e,n={}){super(e,n),n.replay=n.replay===void 0||n.replay,this.setIcon("play"),this.on(e,"play",o=>this.handlePlay(o)),this.on(e,"pause",o=>this.handlePause(o)),n.replay&&this.on(e,"ended",o=>this.handleEnded(o))}buildCSSClass(){return`vjs-play-control ${super.buildCSSClass()}`}handleClick(e){this.player_.paused()?silencePromise(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",n=>this.handleSeeked(n))}}PlayToggle.prototype.controlText_="Play",Component$1.registerComponent("PlayToggle",PlayToggle);class TimeDisplay extends Component$1{constructor(e,n){super(e,n),this.on(e,["timeupdate","ended","seeking"],o=>this.update(o)),this.updateTextNode_()}createEl(){const e=this.buildCSSClass(),n=super.createEl("div",{className:`${e} vjs-time-control vjs-control`}),o=createEl("span",{className:"vjs-control-text",textContent:`${this.localize(this.labelText_)} `},{role:"presentation"});return n.appendChild(o),this.contentEl_=createEl("span",{className:`${e}-display`},{role:"presentation"}),n.appendChild(this.contentEl_),n}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=formatTime(e),this.formattedTime_!==e&&(this.formattedTime_=e,this.requestNamedAnimationFrame("TimeDisplay#updateTextNode_",()=>{if(!this.contentEl_)return;let n=this.textNode_;n&&this.contentEl_.firstChild!==n&&(n=null,log$1.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_=document$1$1.createTextNode(this.formattedTime_),this.textNode_&&(n?this.contentEl_.replaceChild(this.textNode_,n):this.contentEl_.appendChild(this.textNode_))}))}updateContent(e){}}TimeDisplay.prototype.labelText_="Time",TimeDisplay.prototype.controlText_="Time",Component$1.registerComponent("TimeDisplay",TimeDisplay);class CurrentTimeDisplay extends TimeDisplay{buildCSSClass(){return"vjs-current-time"}updateContent(e){let n;this.player_.ended()?n=this.player_.duration():n=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime(),this.updateTextNode_(n)}}CurrentTimeDisplay.prototype.labelText_="Current Time",CurrentTimeDisplay.prototype.controlText_="Current Time",Component$1.registerComponent("CurrentTimeDisplay",CurrentTimeDisplay);class DurationDisplay extends TimeDisplay{constructor(e,n){super(e,n);const o=u=>this.updateContent(u);this.on(e,"durationchange",o),this.on(e,"loadstart",o),this.on(e,"loadedmetadata",o)}buildCSSClass(){return"vjs-duration"}updateContent(e){const n=this.player_.duration();this.updateTextNode_(n)}}DurationDisplay.prototype.labelText_="Duration",DurationDisplay.prototype.controlText_="Duration",Component$1.registerComponent("DurationDisplay",DurationDisplay);class TimeDivider extends Component$1{createEl(){const e=super.createEl("div",{className:"vjs-time-control vjs-time-divider"},{"aria-hidden":!0}),n=super.createEl("div"),o=super.createEl("span",{textContent:"/"});return n.appendChild(o),e.appendChild(n),e}}Component$1.registerComponent("TimeDivider",TimeDivider);class RemainingTimeDisplay extends TimeDisplay{constructor(e,n){super(e,n),this.on(e,"durationchange",o=>this.updateContent(o))}buildCSSClass(){return"vjs-remaining-time"}createEl(){const e=super.createEl();return this.options_.displayNegative!==!1&&e.insertBefore(createEl("span",{},{"aria-hidden":!0},"-"),this.contentEl_),e}updateContent(e){if(typeof this.player_.duration()!="number")return;let n;this.player_.ended()?n=0:this.player_.remainingTimeDisplay?n=this.player_.remainingTimeDisplay():n=this.player_.remainingTime(),this.updateTextNode_(n)}}RemainingTimeDisplay.prototype.labelText_="Remaining Time",RemainingTimeDisplay.prototype.controlText_="Remaining Time",Component$1.registerComponent("RemainingTimeDisplay",RemainingTimeDisplay);class LiveDisplay extends Component$1{constructor(e,n){super(e,n),this.updateShowing(),this.on(this.player(),"durationchange",o=>this.updateShowing(o))}createEl(){const e=super.createEl("div",{className:"vjs-live-control vjs-control"});return this.contentEl_=createEl("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.contentEl_.appendChild(createEl("span",{className:"vjs-control-text",textContent:`${this.localize("Stream Type")} `})),this.contentEl_.appendChild(document$1$1.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()}}Component$1.registerComponent("LiveDisplay",LiveDisplay);class SeekToLive extends Button{constructor(e,n){super(e,n),this.updateLiveEdgeStatus(),this.player_.liveTracker&&(this.updateLiveEdgeStatusHandler_=o=>this.updateLiveEdgeStatus(o),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_=createEl("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()}}SeekToLive.prototype.controlText_="Seek to live, currently playing live",Component$1.registerComponent("SeekToLive",SeekToLive);function clamp(t,e,n){return t=Number(t),Math.min(n,Math.max(e,isNaN(t)?e:t))}var Num=Object.freeze({__proto__:null,clamp});let Slider$1=class extends Component$1{constructor(e,n){super(e,n),this.handleMouseDown_=o=>this.handleMouseDown(o),this.handleMouseUp_=o=>this.handleMouseUp(o),this.handleKeyDown_=o=>this.handleKeyDown(o),this.handleClick_=o=>this.handleClick(o),this.handleMouseMove_=o=>this.handleMouseMove(o),this.update_=o=>this.update(o),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,n={},o={}){return n.className=n.className+" vjs-slider",n=Object.assign({tabIndex:0},n),o=Object.assign({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100},o),super.createEl(e,n,o)}handleMouseDown(e){const n=this.bar.el_.ownerDocument;e.type==="mousedown"&&e.preventDefault(),e.type==="touchstart"&&!IS_CHROME&&e.preventDefault(),blockTextSelection(),this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(n,"mousemove",this.handleMouseMove_),this.on(n,"mouseup",this.handleMouseUp_),this.on(n,"touchmove",this.handleMouseMove_),this.on(n,"touchend",this.handleMouseUp_),this.handleMouseMove(e,!0)}handleMouseMove(e){}handleMouseUp(e){const n=this.bar.el_.ownerDocument;unblockTextSelection(),this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(n,"mousemove",this.handleMouseMove_),this.off(n,"mouseup",this.handleMouseUp_),this.off(n,"touchmove",this.handleMouseMove_),this.off(n,"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 n=this.vertical()?"height":"width";this.bar.el().style[n]=(e*100).toFixed(2)+"%"})),e}getProgress(){return Number(clamp(this.getPercent(),0,1).toFixed(4))}calculateDistance(e){const n=getPointerPosition(this.el_,e);return this.vertical()?n.y:n.x}handleKeyDown(e){const n=this.options_.playerOptions.spatialNavigation,o=n&&n.enabled,u=n&&n.horizontalSeek;o?u&&e.key==="ArrowLeft"||!u&&e.key==="ArrowDown"?(e.preventDefault(),e.stopPropagation(),this.stepBack()):u&&e.key==="ArrowRight"||!u&&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")}};Component$1.registerComponent("Slider",Slider$1);const percentify=(t,e)=>clamp(t/e*100,0,100).toFixed(2)+"%";class LoadProgressBar extends Component$1{constructor(e,n){super(e,n),this.partEls_=[],this.on(e,"progress",o=>this.update(o))}createEl(){const e=super.createEl("div",{className:"vjs-load-progress"}),n=createEl("span",{className:"vjs-control-text"}),o=createEl("span",{textContent:this.localize("Loaded")}),u=document$1$1.createTextNode(": ");return this.percentageEl_=createEl("span",{className:"vjs-control-text-loaded-percentage",textContent:"0%"}),e.appendChild(n),n.appendChild(o),n.appendChild(u),n.appendChild(this.percentageEl_),e}dispose(){this.partEls_=null,this.percentageEl_=null,super.dispose()}update(e){this.requestNamedAnimationFrame("LoadProgressBar#update",()=>{const n=this.player_.liveTracker,o=this.player_.buffered(),u=n&&n.isLive()?n.seekableEnd():this.player_.duration(),l=this.player_.bufferedEnd(),m=this.partEls_,y=percentify(l,u);this.percent_!==y&&(this.el_.style.width=y,textContent(this.percentageEl_,y),this.percent_=y);for(let E=0;E<o.length;E++){const C=o.start(E),k=o.end(E);let A=m[E];A||(A=this.el_.appendChild(createEl()),m[E]=A),!(A.dataset.start===C&&A.dataset.end===k)&&(A.dataset.start=C,A.dataset.end=k,A.style.left=percentify(C,l),A.style.width=percentify(k-C,l))}for(let E=m.length;E>o.length;E--)this.el_.removeChild(m[E-1]);m.length=o.length})}}Component$1.registerComponent("LoadProgressBar",LoadProgressBar);class TimeTooltip extends Component$1{constructor(e,n){super(e,n),this.update=throttle(bind_(this,this.update),UPDATE_REFRESH_INTERVAL)}createEl(){return super.createEl("div",{className:"vjs-time-tooltip"},{"aria-hidden":"true"})}update(e,n,o){const u=findPosition(this.el_),l=getBoundingClientRect(this.player_.el()),m=e.width*n;if(!l||!u)return;let y=e.left-l.left+m,E=e.width-m+(l.right-e.right);E||(E=e.width-m,y=m);let C=u.width/2;y<C?C+=C-y:E<C&&(C=E),C<0?C=0:C>u.width&&(C=u.width),C=Math.round(C),this.el_.style.right=`-${C}px`,this.write(o)}write(e){textContent(this.el_,e)}updateTime(e,n,o,u){this.requestNamedAnimationFrame("TimeTooltip#updateTime",()=>{let l;const m=this.player_.duration();if(this.player_.liveTracker&&this.player_.liveTracker.isLive()){const y=this.player_.liveTracker.liveWindow(),E=y-n*y;l=(E<1?"":"-")+formatTime(E,y)}else l=formatTime(o,m);this.update(e,n,l),u&&u()})}}Component$1.registerComponent("TimeTooltip",TimeTooltip);class PlayProgressBar extends Component$1{constructor(e,n){super(e,n),this.setIcon("circle"),this.update=throttle(bind_(this,this.update),UPDATE_REFRESH_INTERVAL)}createEl(){return super.createEl("div",{className:"vjs-play-progress vjs-slider-bar"},{"aria-hidden":"true"})}update(e,n){const o=this.getChild("timeTooltip");if(!o)return;const u=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();o.updateTime(e,n,u)}}PlayProgressBar.prototype.options_={children:[]},!IS_IOS&&!IS_ANDROID&&PlayProgressBar.prototype.options_.children.push("timeTooltip"),Component$1.registerComponent("PlayProgressBar",PlayProgressBar);class MouseTimeDisplay extends Component$1{constructor(e,n){super(e,n),this.update=throttle(bind_(this,this.update),UPDATE_REFRESH_INTERVAL)}createEl(){return super.createEl("div",{className:"vjs-mouse-display"})}update(e,n){const o=n*this.player_.duration();this.getChild("timeTooltip").updateTime(e,n,o,()=>{this.el_.style.left=`${e.width*n}px`})}}MouseTimeDisplay.prototype.options_={children:["timeTooltip"]},Component$1.registerComponent("MouseTimeDisplay",MouseTimeDisplay);const STEP_SECONDS=5,PAGE_KEY_MULTIPLIER=12;class SeekBar extends Slider$1{constructor(e,n){super(e,n),this.setEventHandlers_()}setEventHandlers_(){this.update_=bind_(this,this.update),this.update=throttle(this.update_,UPDATE_REFRESH_INTERVAL),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 document$1$1&&"visibilityState"in document$1$1&&this.on(document$1$1,"visibilitychange",this.toggleVisibility_)}toggleVisibility_(e){document$1$1.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,UPDATE_REFRESH_INTERVAL))}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(document$1$1.visibilityState==="hidden")return;const n=super.update();return this.requestNamedAnimationFrame("SeekBar#update",()=>{const o=this.player_.ended()?this.player_.duration():this.getCurrentTime_(),u=this.player_.liveTracker;let l=this.player_.duration();u&&u.isLive()&&(l=this.player_.liveTracker.liveCurrentTime()),this.percent_!==n&&(this.el_.setAttribute("aria-valuenow",(n*100).toFixed(2)),this.percent_=n),(this.currentTime_!==o||this.duration_!==l)&&(this.el_.setAttribute("aria-valuetext",this.localize("progress bar timing: currentTime={1} duration={2}",[formatTime(o,l),formatTime(l,l)],"{1} of {2}")),this.currentTime_=o,this.duration_=l),this.bar&&this.bar.update(getBoundingClientRect(this.el()),this.getProgress())}),n}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 n;const o=this.player_.liveTracker;return o&&o.isLive()?(n=(e-o.seekableStart())/o.liveWindow(),o.atLiveEdge()&&(n=1)):n=e/this.player_.duration(),n}handleMouseDown(e){isSingleLeftClick(e)&&(e.stopPropagation(),this.videoWasPlaying=!this.player_.paused(),this.player_.pause(),super.handleMouseDown(e))}handleMouseMove(e,n=!1){if(!isSingleLeftClick(e)||isNaN(this.player_.duration()))return;!n&&!this.player_.scrubbing()&&this.player_.scrubbing(!0);let o;const u=this.calculateDistance(e),l=this.player_.liveTracker;if(!l||!l.isLive())o=u*this.player_.duration(),o===this.player_.duration()&&(o=o-.1);else{if(u>=.99){l.seekToLiveEdge();return}const m=l.seekableStart(),y=l.liveCurrentTime();if(o=m+u*l.liveWindow(),o>=y&&(o=y),o<=m&&(o=m+.1),o===1/0)return}this.userSeek_(o),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?silencePromise(this.player_.play()):this.update_()}stepForward(){this.userSeek_(this.player_.currentTime()+STEP_SECONDS)}stepBack(){this.userSeek_(this.player_.currentTime()-STEP_SECONDS)}handleAction(e){this.player_.paused()?this.player_.play():this.player_.pause()}handleKeyDown(e){const n=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(),n&&n.isLive()?this.userSeek_(n.liveCurrentTime()):this.userSeek_(this.player_.duration());else if(/^[0-9]$/.test(e.key)){e.preventDefault(),e.stopPropagation();const o=parseInt(e.key,10)*.1;n&&n.isLive()?this.userSeek_(n.seekableStart()+n.liveWindow()*o):this.userSeek_(this.player_.duration()*o)}else e.key==="PageDown"?(e.preventDefault(),e.stopPropagation(),this.userSeek_(this.player_.currentTime()-STEP_SECONDS*PAGE_KEY_MULTIPLIER)):e.key==="PageUp"?(e.preventDefault(),e.stopPropagation(),this.userSeek_(this.player_.currentTime()+STEP_SECONDS*PAGE_KEY_MULTIPLIER)):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 document$1$1&&"visibilityState"in document$1$1&&this.off(document$1$1,"visibilitychange",this.toggleVisibility_),super.dispose()}}SeekBar.prototype.options_={children:["loadProgressBar","playProgressBar"],barName:"playProgressBar"},!IS_IOS&&!IS_ANDROID&&SeekBar.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),Component$1.registerComponent("SeekBar",SeekBar);class ProgressControl extends Component$1{constructor(e,n){super(e,n),this.handleMouseMove=throttle(bind_(this,this.handleMouseMove),UPDATE_REFRESH_INTERVAL),this.throttledHandleMouseSeek=throttle(bind_(this,this.handleMouseSeek),UPDATE_REFRESH_INTERVAL),this.handleMouseUpHandler_=o=>this.handleMouseUp(o),this.handleMouseDownHandler_=o=>this.handleMouseDown(o),this.enable()}createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(e){const n=this.getChild("seekBar");if(!n)return;const o=n.getChild("playProgressBar"),u=n.getChild("mouseTimeDisplay");if(!o&&!u)return;const l=n.el(),m=findPosition(l);let y=getPointerPosition(l,e).x;y=clamp(y,0,1),u&&u.update(m,y),o&&o.update(m,n.getProgress())}handleMouseSeek(e){const n=this.getChild("seekBar");n&&n.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&&silencePromise(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 n=this.el_.ownerDocument,o=this.getChild("seekBar");o&&o.handleMouseDown(e),this.on(n,"mousemove",this.throttledHandleMouseSeek),this.on(n,"touchmove",this.throttledHandleMouseSeek),this.on(n,"mouseup",this.handleMouseUpHandler_),this.on(n,"touchend",this.handleMouseUpHandler_)}handleMouseUp(e){const n=this.getChild("seekBar");n&&n.handleMouseUp(e),this.removeListenersAddedOnMousedownAndTouchstart()}}ProgressControl.prototype.options_={children:["seekBar"]},Component$1.registerComponent("ProgressControl",ProgressControl);class PictureInPictureToggle extends Button{constructor(e,n){super(e,n),this.setIcon("picture-in-picture-enter"),this.on(e,["enterpictureinpicture","leavepictureinpicture"],o=>this.handlePictureInPictureChange(o)),this.on(e,["disablepictureinpicturechanged","loadedmetadata"],o=>this.handlePictureInPictureEnabledChange(o)),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(){document$1$1.pictureInPictureEnabled&&this.player_.disablePictureInPicture()===!1||this.player_.options_.enableDocumentPictureInPicture&&"documentPictureInPicture"in window$1$1?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 document$1$1.exitPictureInPicture=="function"&&super.show()}}PictureInPictureToggle.prototype.controlText_="Picture-in-Picture",Component$1.registerComponent("PictureInPictureToggle",PictureInPictureToggle);class FullscreenToggle extends Button{constructor(e,n){super(e,n),this.setIcon("fullscreen-enter"),this.on(e,"fullscreenchange",o=>this.handleFullscreenChange(o)),document$1$1[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()}}FullscreenToggle.prototype.controlText_="Fullscreen",Component$1.registerComponent("FullscreenToggle",FullscreenToggle);const checkVolumeSupport=function(t,e){e.tech_&&!e.tech_.featuresVolumeControl&&t.addClass("vjs-hidden"),t.on(e,"loadstart",function(){e.tech_.featuresVolumeControl?t.removeClass("vjs-hidden"):t.addClass("vjs-hidden")})};class VolumeLevel extends Component$1{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}}Component$1.registerComponent("VolumeLevel",VolumeLevel);class VolumeLevelTooltip extends Component$1{constructor(e,n){super(e,n),this.update=throttle(bind_(this,this.update),UPDATE_REFRESH_INTERVAL)}createEl(){return super.createEl("div",{className:"vjs-volume-tooltip"},{"aria-hidden":"true"})}update(e,n,o,u){if(!o){const l=getBoundingClientRect(this.el_),m=getBoundingClientRect(this.player_.el()),y=e.width*n;if(!m||!l)return;const E=e.left-m.left+y,C=e.width-y+(m.right-e.right);let k=l.width/2;E<k?k+=k-E:C<k&&(k=C),k<0?k=0:k>l.width&&(k=l.width),this.el_.style.right=`-${k}px`}this.write(`${u}%`)}write(e){textContent(this.el_,e)}updateVolume(e,n,o,u,l){this.requestNamedAnimationFrame("VolumeLevelTooltip#updateVolume",()=>{this.update(e,n,o,u.toFixed(0)),l&&l()})}}Component$1.registerComponent("VolumeLevelTooltip",VolumeLevelTooltip);class MouseVolumeLevelDisplay extends Component$1{constructor(e,n){super(e,n),this.update=throttle(bind_(this,this.update),UPDATE_REFRESH_INTERVAL)}createEl(){return super.createEl("div",{className:"vjs-mouse-display"})}update(e,n,o){const u=100*n;this.getChild("volumeLevelTooltip").updateVolume(e,n,o,u,()=>{o?this.el_.style.bottom=`${e.height*n}px`:this.el_.style.left=`${e.width*n}px`})}}MouseVolumeLevelDisplay.prototype.options_={children:["volumeLevelTooltip"]},Component$1.registerComponent("MouseVolumeLevelDisplay",MouseVolumeLevelDisplay);class VolumeBar extends Slider$1{constructor(e,n){super(e,n),this.on("slideractive",o=>this.updateLastVolume_(o)),this.on(e,"volumechange",o=>this.updateARIAAttributes(o)),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){isSingleLeftClick(e)&&super.handleMouseDown(e)}handleMouseMove(e){const n=this.getChild("mouseVolumeLevelDisplay");if(n){const o=this.el(),u=getBoundingClientRect(o),l=this.vertical();let m=getPointerPosition(o,e);m=l?m.y:m.x,m=clamp(m,0,1),n.update(u,m,l)}isSingleLeftClick(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 n=this.player_.muted()?0:this.volumeAsPercentage_();this.el_.setAttribute("aria-valuenow",n),this.el_.setAttribute("aria-valuetext",n+"%")}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)})}}VolumeBar.prototype.options_={children:["volumeLevel"],barName:"volumeLevel"},!IS_IOS&&!IS_ANDROID&&VolumeBar.prototype.options_.children.splice(0,0,"mouseVolumeLevelDisplay"),VolumeBar.prototype.playerEvent="volumechange",Component$1.registerComponent("VolumeBar",VolumeBar);class VolumeControl extends Component$1{constructor(e,n={}){n.vertical=n.vertical||!1,(typeof n.volumeBar>"u"||isPlain(n.volumeBar))&&(n.volumeBar=n.volumeBar||{},n.volumeBar.vertical=n.vertical),super(e,n),checkVolumeSupport(this,e),this.throttledHandleMouseMove=throttle(bind_(this,this.handleMouseMove),UPDATE_REFRESH_INTERVAL),this.handleMouseUpHandler_=o=>this.handleMouseUp(o),this.on("mousedown",o=>this.handleMouseDown(o)),this.on("touchstart",o=>this.handleMouseDown(o)),this.on("mousemove",o=>this.handleMouseMove(o)),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 n=this.el_.ownerDocument;this.on(n,"mousemove",this.throttledHandleMouseMove),this.on(n,"touchmove",this.throttledHandleMouseMove),this.on(n,"mouseup",this.handleMouseUpHandler_),this.on(n,"touchend",this.handleMouseUpHandler_)}handleMouseUp(e){const n=this.el_.ownerDocument;this.off(n,"mousemove",this.throttledHandleMouseMove),this.off(n,"touchmove",this.throttledHandleMouseMove),this.off(n,"mouseup",this.handleMouseUpHandler_),this.off(n,"touchend",this.handleMouseUpHandler_)}handleMouseMove(e){this.volumeBar.handleMouseMove(e)}}VolumeControl.prototype.options_={children:["volumeBar"]},Component$1.registerComponent("VolumeControl",VolumeControl);const checkMuteSupport=function(t,e){e.tech_&&!e.tech_.featuresMuteControl&&t.addClass("vjs-hidden"),t.on(e,"loadstart",function(){e.tech_.featuresMuteControl?t.removeClass("vjs-hidden"):t.addClass("vjs-hidden")})};class MuteToggle extends Button{constructor(e,n){super(e,n),checkMuteSupport(this,e),this.on(e,["loadstart","volumechange"],o=>this.update(o))}buildCSSClass(){return`vjs-mute-control ${super.buildCSSClass()}`}handleClick(e){const n=this.player_.volume(),o=this.player_.lastVolume_();if(n===0){const u=o<.1?.1:o;this.player_.volume(u),this.player_.muted(!1)}else this.player_.muted(!this.player_.muted())}update(e){this.updateIcon_(),this.updateControlText_()}updateIcon_(){const e=this.player_.volume();let n=3;this.setIcon("volume-high"),IS_IOS&&this.player_.tech_&&this.player_.tech_.el_&&this.player_.muted(this.player_.tech_.el_.muted),e===0||this.player_.muted()?(this.setIcon("volume-mute"),n=0):e<.33?(this.setIcon("volume-low"),n=1):e<.67&&(this.setIcon("volume-medium"),n=2),removeClass(this.el_,[0,1,2,3].reduce((o,u)=>o+`${u?" ":""}vjs-vol-${u}`,"")),addClass(this.el_,`vjs-vol-${n}`)}updateControlText_(){const n=this.player_.muted()||this.player_.volume()===0?"Unmute":"Mute";this.controlText()!==n&&this.controlText(n)}}MuteToggle.prototype.controlText_="Mute",Component$1.registerComponent("MuteToggle",MuteToggle);class VolumePanel extends Component$1{constructor(e,n={}){typeof n.inline<"u"?n.inline=n.inline:n.inline=!0,(typeof n.volumeControl>"u"||isPlain(n.volumeControl))&&(n.volumeControl=n.volumeControl||{},n.volumeControl.vertical=!n.inline),super(e,n),this.handleKeyPressHandler_=o=>this.handleKeyPress(o),this.on(e,["loadstart"],o=>this.volumePanelState_(o)),this.on(this.muteToggle,"keyup",o=>this.handleKeyPress(o)),this.on(this.volumeControl,"keyup",o=>this.handleVolumeControlKeyUp(o)),this.on("keydown",o=>this.handleKeyPress(o)),this.on("mouseover",o=>this.handleMouseOver(o)),this.on("mouseout",o=>this.handleMouseOut(o)),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"),on(document$1$1,"keyup",this.handleKeyPressHandler_)}handleMouseOut(e){this.removeClass("vjs-hover"),off(document$1$1,"keyup",this.handleKeyPressHandler_)}handleKeyPress(e){e.key==="Escape"&&this.handleMouseOut()}}VolumePanel.prototype.options_={children:["muteToggle","volumeControl"]},Component$1.registerComponent("VolumePanel",VolumePanel);class SkipForward extends Button{constructor(e,n){super(e,n),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 n=this.player_.currentTime(),o=this.player_.liveTracker,u=o&&o.isLive()?o.seekableEnd():this.player_.duration();let l;n+this.skipTime<=u?l=n+this.skipTime:l=u,this.player_.currentTime(l)}handleLanguagechange(){this.controlText(this.localize("Skip forward {1} seconds",[this.skipTime]))}}SkipForward.prototype.controlText_="Skip Forward",Component$1.registerComponent("SkipForward",SkipForward);class SkipBackward extends Button{constructor(e,n){super(e,n),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 n=this.player_.currentTime(),o=this.player_.liveTracker,u=o&&o.isLive()&&o.seekableStart();let l;u&&n-this.skipTime<=u?l=u:n>=this.skipTime?l=n-this.skipTime:l=0,this.player_.currentTime(l)}handleLanguagechange(){this.controlText(this.localize("Skip backward {1} seconds",[this.skipTime]))}}SkipBackward.prototype.controlText_="Skip Backward",Component$1.registerComponent("SkipBackward",SkipBackward);class Menu extends Component$1{constructor(e,n){super(e,n),n&&(this.menuButton_=n.menuButton),this.focusedChild_=-1,this.on("keydown",o=>this.handleKeyDown(o)),this.boundHandleBlur_=o=>this.handleBlur(o),this.boundHandleTapClick_=o=>this.handleTapClick(o)}addEventListenerForItem(e){e instanceof Component$1&&(this.on(e,"blur",this.boundHandleBlur_),this.on(e,["tap","click"],this.boundHandleTapClick_))}removeEventListenerForItem(e){e instanceof Component$1&&(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 n=this.addChild(e);n&&this.addEventListenerForItem(n)}createEl(){const e=this.options_.contentElType||"ul";this.contentEl_=createEl(e,{className:"vjs-menu-content"}),this.contentEl_.setAttribute("role","menu");const n=super.createEl("div",{append:this.contentEl_,className:"vjs-menu"});return n.appendChild(this.contentEl_),on(n,"click",function(o){o.preventDefault(),o.stopImmediatePropagation()}),n}dispose(){this.contentEl_=null,this.boundHandleBlur_=null,this.boundHandleTapClick_=null,super.dispose()}handleBlur(e){const n=e.relatedTarget||document$1$1.activeElement;if(!this.children().some(o=>o.el()===n)){const o=this.menuButton_;o&&o.buttonPressed_&&n!==o.el().firstChild&&o.unpressButton()}}handleTapClick(e){if(this.menuButton_){this.menuButton_.unpressButton();const n=this.children();if(!Array.isArray(n))return;const o=n.filter(u=>u.el()===e.target)[0];if(!o)return;o.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 n=this.children().slice();n.length&&n[0].hasClass("vjs-menu-title")&&n.shift(),n.length>0&&(e<0?e=0:e>=n.length&&(e=n.length-1),this.focusedChild_=e,n[e].el_.focus())}}Component$1.registerComponent("Menu",Menu);class MenuButton extends Component$1{constructor(e,n={}){super(e,n),this.menuButton_=new Button(e,n),this.menuButton_.controlText(this.controlText_),this.menuButton_.el_.setAttribute("aria-haspopup","true");const o=Button.prototype.buildCSSClass();this.menuButton_.el_.className=this.buildCSSClass()+" "+o,this.menuButton_.removeClass("vjs-control"),this.addChild(this.menuButton_),this.update(),this.enabled_=!0;const u=l=>this.handleClick(l);this.handleMenuKeyUp_=l=>this.handleMenuKeyUp(l),this.on(this.menuButton_,"tap",u),this.on(this.menuButton_,"click",u),this.on(this.menuButton_,"keydown",l=>this.handleKeyDown(l)),this.on(this.menuButton_,"mouseenter",()=>{this.addClass("vjs-hover"),this.menu.show(),on(document$1$1,"keyup",this.handleMenuKeyUp_)}),this.on("mouseleave",l=>this.handleMouseLeave(l)),this.on("keydown",l=>this.handleSubmenuKeyDown(l))}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 Menu(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){const n=createEl("li",{className:"vjs-menu-title",textContent:toTitleCase$1(this.options_.title),tabIndex:-1}),o=new Component$1(this.player_,{el:n});e.addItem(o)}if(this.items=this.createItems(),this.items)for(let n=0;n<this.items.length;n++)e.addItem(this.items[n]);return e}createItems(){}createEl(){return super.createEl("div",{className:this.buildWrapperCSSClass()},{})}setIcon(e){super.setIcon(e,this.menuButton_.el_)}buildWrapperCSSClass(){let e="vjs-menu-button";this.options_.inline===!0?e+="-inline":e+="-popup";const n=Button.prototype.buildCSSClass();return`vjs-menu-button ${e} ${n} ${super.buildCSSClass()}`}buildCSSClass(){let e="vjs-menu-button";return this.options_.inline===!0?e+="-inline":e+="-popup",`vjs-menu-button ${e} ${super.buildCSSClass()}`}controlText(e,n=this.menuButton_.el()){return this.menuButton_.controlText(e,n)}dispose(){this.handleMouseLeave(),super.dispose()}handleClick(e){this.buttonPressed_?this.unpressButton():this.pressButton()}handleMouseLeave(e){this.removeClass("vjs-hover"),off(document$1$1,"keyup",this.handleMenuKeyUp_)}focus(){this.menuButton_.focus()}blur(){this.menuButton_.blur()}handleKeyDown(e){e.key==="Esc"||e.key==="Tab"?(this.buttonPressed_&&this.unpressButton(),!e.key==="Tab"&&(e.preventDefault(),this.menuButton_.focus())):(e.key==="Up"||e.key==="Down"&&!(this.player_.options_.playerOptions.spatialNavigation&&this.player_.options_.playerOptions.spatialNavigation.enabled))&&(this.buttonPressed_||(e.preventDefault(),this.pressButton()))}handleMenuKeyUp(e){(e.key==="Esc"||e.key==="Tab")&&this.removeClass("vjs-hover")}handleSubmenuKeyPress(e){this.handleSubmenuKeyDown(e)}handleSubmenuKeyDown(e){(e.key==="Esc"||e.key==="Tab")&&(this.buttonPressed_&&this.unpressButton(),!e.key==="Tab"&&(e.preventDefault(),this.menuButton_.focus()))}pressButton(){if(this.enabled_){if(this.buttonPressed_=!0,this.menu.show(),this.menu.lockShowing(),this.menuButton_.el_.setAttribute("aria-expanded","true"),IS_IOS&&isInFrame())return;this.menu.focus()}}unpressButton(){this.enabled_&&(this.buttonPressed_=!1,this.menu.unlockShowing(),this.menu.hide(),this.menuButton_.el_.setAttribute("aria-expanded","false"))}disable(){this.unpressButton(),this.enabled_=!1,this.addClass("vjs-disabled"),this.menuButton_.disable()}enable(){this.enabled_=!0,this.removeClass("vjs-disabled"),this.menuButton_.enable()}}Component$1.registerComponent("MenuButton",MenuButton);class TrackButton extends MenuButton{constructor(e,n){const o=n.tracks;if(super(e,n),this.items.length<=1&&this.hide(),!o)return;const u=bind_(this,this.update);o.addEventListener("removetrack",u),o.addEventListener("addtrack",u),o.addEventListener("labelchange",u),this.player_.on("ready",u),this.player_.on("dispose",function(){o.removeEventListener("removetrack",u),o.removeEventListener("addtrack",u),o.removeEventListener("labelchange",u)})}}Component$1.registerComponent("TrackButton",TrackButton);class MenuItem extends ClickableComponent{constructor(e,n){super(e,n),this.selectable=n.selectable,this.isSelected_=n.selected||!1,this.multiSelectable=n.multiSelectable,this.selected(this.isSelected_),this.selectable?this.multiSelectable?this.el_.setAttribute("role","menuitemcheckbox"):this.el_.setAttribute("role","menuitemradio"):this.el_.setAttribute("role","menuitem")}createEl(e,n,o){this.nonIconControl=!0;const u=super.createEl("li",Object.assign({className:"vjs-menu-item",tabIndex:-1},n),o),l=createEl("span",{className:"vjs-menu-item-text",textContent:this.localize(this.options_.label)});return this.player_.options_.experimentalSvgIcons?u.appendChild(l):u.replaceChild(l,u.querySelector(".vjs-icon-placeholder")),u}handleKeyDown(e){["Tab","Escape","ArrowUp","ArrowLeft","ArrowRight","ArrowDown"].includes(e.key)||super.handleKeyDown(e)}handleClick(e){this.selected(!0)}selected(e){this.selectable&&(e?(this.addClass("vjs-selected"),this.el_.setAttribute("aria-checked","true"),this.controlText(", selected"),this.isSelected_=!0):(this.removeClass("vjs-selected"),this.el_.setAttribute("aria-checked","false"),this.controlText(""),this.isSelected_=!1))}}Component$1.registerComponent("MenuItem",MenuItem);class TextTrackMenuItem extends MenuItem{constructor(e,n){const o=n.track,u=e.textTracks();n.label=o.label||o.language||"Unknown",n.selected=o.mode==="showing",super(e,n),this.track=o,this.kinds=(n.kinds||[n.kind||this.track.kind]).filter(Boolean);const l=(...y)=>{this.handleTracksChange.apply(this,y)},m=(...y)=>{this.handleSelectedLanguageChange.apply(this,y)};if(e.on(["loadstart","texttrackchange"],l),u.addEventListener("change",l),u.addEventListener("selectedlanguagechange",m),this.on("dispose",function(){e.off(["loadstart","texttrackchange"],l),u.removeEventListener("change",l),u.removeEventListener("selectedlanguagechange",m)}),u.onchange===void 0){let y;this.on(["tap","click"],function(){if(typeof window$1$1.Event!="object")try{y=new window$1$1.Event("change")}catch{}y||(y=document$1$1.createEvent("Event"),y.initEvent("change",!0,!0)),u.dispatchEvent(y)})}this.handleTracksChange()}handleClick(e){const n=this.track,o=this.player_.textTracks();if(super.handleClick(e),!!o)for(let u=0;u<o.length;u++){const l=o[u];this.kinds.indexOf(l.kind)!==-1&&(l===n?l.mode!=="showing"&&(l.mode="showing"):l.mode!=="disabled"&&(l.mode="disabled"))}}handleTracksChange(e){const n=this.track.mode==="showing";n!==this.isSelected_&&this.selected(n)}handleSelectedLanguageChange(e){if(this.track.mode==="showing"){const n=this.player_.cache_.selectedLanguage;if(n&&n.enabled&&n.language===this.track.language&&n.kind!==this.track.kind)return;this.player_.cache_.selectedLanguage={enabled:!0,language:this.track.language,kind:this.track.kind}}}dispose(){this.track=null,super.dispose()}}Component$1.registerComponent("TextTrackMenuItem",TextTrackMenuItem);class OffTextTrackMenuItem extends TextTrackMenuItem{constructor(e,n){n.track={player:e,kind:n.kind,kinds:n.kinds,default:!1,mode:"disabled"},n.kinds||(n.kinds=[n.kind]),n.label?n.track.label=n.label:n.track.label=n.kinds.join(" and ")+" off",n.selectable=!0,n.multiSelectable=!1,super(e,n)}handleTracksChange(e){const n=this.player().textTracks();let o=!0;for(let u=0,l=n.length;u<l;u++){const m=n[u];if(this.options_.kinds.indexOf(m.kind)>-1&&m.mode==="showing"){o=!1;break}}o!==this.isSelected_&&this.selected(o)}handleSelectedLanguageChange(e){const n=this.player().textTracks();let o=!0;for(let u=0,l=n.length;u<l;u++){const m=n[u];if(["captions","descriptions","subtitles"].indexOf(m.kind)>-1&&m.mode==="showing"){o=!1;break}}o&&(this.player_.cache_.selectedLanguage={enabled:!1})}handleLanguagechange(){this.$(".vjs-menu-item-text").textContent=this.player_.localize(this.options_.label),super.handleLanguagechange()}}Component$1.registerComponent("OffTextTrackMenuItem",OffTextTrackMenuItem);class TextTrackButton extends TrackButton{constructor(e,n={}){n.tracks=e.textTracks(),super(e,n)}createItems(e=[],n=TextTrackMenuItem){let o;this.label_&&(o=`${this.label_} off`),e.push(new OffTextTrackMenuItem(this.player_,{kinds:this.kinds_,kind:this.kind_,label:o})),this.hideThreshold_+=1;const u=this.player_.textTracks();Array.isArray(this.kinds_)||(this.kinds_=[this.kind_]);for(let l=0;l<u.length;l++){const m=u[l];if(this.kinds_.indexOf(m.kind)>-1){const y=new n(this.player_,{track:m,kinds:this.kinds_,kind:this.kind_,selectable:!0,multiSelectable:!1});y.addClass(`vjs-${m.kind}-menu-item`),e.push(y)}}return e}}Component$1.registerComponent("TextTrackButton",TextTrackButton);class ChaptersTrackMenuItem extends MenuItem{constructor(e,n){const o=n.track,u=n.cue,l=e.currentTime();n.selectable=!0,n.multiSelectable=!1,n.label=u.text,n.selected=u.startTime<=l&&l<u.endTime,super(e,n),this.track=o,this.cue=u}handleClick(e){super.handleClick(),this.player_.currentTime(this.cue.startTime)}}Component$1.registerComponent("ChaptersTrackMenuItem",ChaptersTrackMenuItem);class ChaptersButton extends TextTrackButton{constructor(e,n,o){super(e,n,o),this.setIcon("chapters"),this.selectCurrentItem_=()=>{this.items.forEach(u=>{u.selected(this.track_.activeCues[0]===u.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 n=this.findChaptersTrack();n!==this.track_?(this.setTrack(n),super.update()):(!this.items||n&&n.cues&&n.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 n=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);n&&n.removeEventListener("load",this.updateHandler_),this.track_.removeEventListener("cuechange",this.selectCurrentItem_),this.track_=null}if(this.track_=e,this.track_){this.track_.mode="hidden";const n=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);n&&n.addEventListener("load",this.updateHandler_),this.track_.addEventListener("cuechange",this.selectCurrentItem_)}}}findChaptersTrack(){const e=this.player_.textTracks()||[];for(let n=e.length-1;n>=0;n--){const o=e[n];if(o.kind===this.kind_)return o}}getMenuCaption(){return this.track_&&this.track_.label?this.track_.label:this.localize(toTitleCase$1(this.kind_))}createMenu(){return this.options_.title=this.getMenuCaption(),super.createMenu()}createItems(){const e=[];if(!this.track_)return e;const n=this.track_.cues;if(!n)return e;for(let o=0,u=n.length;o<u;o++){const l=n[o],m=new ChaptersTrackMenuItem(this.player_,{track:this.track_,cue:l});e.push(m)}return e}}ChaptersButton.prototype.kind_="chapters",ChaptersButton.prototype.controlText_="Chapters",Component$1.registerComponent("ChaptersButton",ChaptersButton);class DescriptionsButton extends TextTrackButton{constructor(e,n,o){super(e,n,o),this.setIcon("audio-description");const u=e.textTracks(),l=bind_(this,this.handleTracksChange);u.addEventListener("change",l),this.on("dispose",function(){u.removeEventListener("change",l)})}handleTracksChange(e){const n=this.player().textTracks();let o=!1;for(let u=0,l=n.length;u<l;u++){const m=n[u];if(m.kind!==this.kind_&&m.mode==="showing"){o=!0;break}}o?this.disable():this.enable()}buildCSSClass(){return`vjs-descriptions-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-descriptions-button ${super.buildWrapperCSSClass()}`}}DescriptionsButton.prototype.kind_="descriptions",DescriptionsButton.prototype.controlText_="Descriptions",Component$1.registerComponent("DescriptionsButton",DescriptionsButton);class SubtitlesButton extends TextTrackButton{constructor(e,n,o){super(e,n,o),this.setIcon("subtitles")}buildCSSClass(){return`vjs-subtitles-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-subtitles-button ${super.buildWrapperCSSClass()}`}}SubtitlesButton.prototype.kind_="subtitles",SubtitlesButton.prototype.controlText_="Subtitles",Component$1.registerComponent("SubtitlesButton",SubtitlesButton);class CaptionSettingsMenuItem extends TextTrackMenuItem{constructor(e,n){n.track={player:e,kind:n.kind,label:n.kind+" settings",selectable:!1,default:!1,mode:"disabled"},n.selectable=!1,n.name="CaptionSettingsMenuItem",super(e,n),this.addClass("vjs-texttrack-settings"),this.controlText(", opens "+n.kind+" settings dialog")}handleClick(e){this.player().getChild("textTrackSettings").open()}handleLanguagechange(){this.$(".vjs-menu-item-text").textContent=this.player_.localize(this.options_.kind+" settings"),super.handleLanguagechange()}}Component$1.registerComponent("CaptionSettingsMenuItem",CaptionSettingsMenuItem);class CaptionsButton extends TextTrackButton{constructor(e,n,o){super(e,n,o),this.setIcon("captions")}buildCSSClass(){return`vjs-captions-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-captions-button ${super.buildWrapperCSSClass()}`}createItems(){const e=[];return!(this.player().tech_&&this.player().tech_.featuresNativeTextTracks)&&this.player().getChild("textTrackSettings")&&(e.push(new CaptionSettingsMenuItem(this.player_,{kind:this.kind_})),this.hideThreshold_+=1),super.createItems(e)}}CaptionsButton.prototype.kind_="captions",CaptionsButton.prototype.controlText_="Captions",Component$1.registerComponent("CaptionsButton",CaptionsButton);class SubsCapsMenuItem extends TextTrackMenuItem{createEl(e,n,o){const u=super.createEl(e,n,o),l=u.querySelector(".vjs-menu-item-text");return this.options_.track.kind==="captions"&&(this.player_.options_.experimentalSvgIcons?this.setIcon("captions",u):l.appendChild(createEl("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),l.appendChild(createEl("span",{className:"vjs-control-text",textContent:` ${this.localize("Captions")}`}))),u}}Component$1.registerComponent("SubsCapsMenuItem",SubsCapsMenuItem);class SubsCapsButton extends TextTrackButton{constructor(e,n={}){super(e,n),this.label_="subtitles",this.setIcon("subtitles"),["en","en-us","en-ca","fr-ca"].indexOf(this.player_.language_)>-1&&(this.label_="captions",this.setIcon("captions")),this.menuButton_.controlText(toTitleCase$1(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 CaptionSettingsMenuItem(this.player_,{kind:this.label_})),this.hideThreshold_+=1),e=super.createItems(e,SubsCapsMenuItem),e}}SubsCapsButton.prototype.kinds_=["captions","subtitles"],SubsCapsButton.prototype.controlText_="Subtitles",Component$1.registerComponent("SubsCapsButton",SubsCapsButton);class AudioTrackMenuItem extends MenuItem{constructor(e,n){const o=n.track,u=e.audioTracks();n.label=o.label||o.language||"Unknown",n.selected=o.enabled,super(e,n),this.track=o,this.addClass(`vjs-${o.kind}-menu-item`);const l=(...m)=>{this.handleTracksChange.apply(this,m)};u.addEventListener("change",l),this.on("dispose",()=>{u.removeEventListener("change",l)})}createEl(e,n,o){const u=super.createEl(e,n,o),l=u.querySelector(".vjs-menu-item-text");return["main-desc","descriptions"].indexOf(this.options_.track.kind)>=0&&(l.appendChild(createEl("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),l.appendChild(createEl("span",{className:"vjs-control-text",textContent:" "+this.localize("Descriptions")}))),u}handleClick(e){if(super.handleClick(e),this.track.enabled=!0,this.player_.tech_.featuresNativeAudioTracks){const n=this.player_.audioTracks();for(let o=0;o<n.length;o++){const u=n[o];u!==this.track&&(u.enabled=u===this.track)}}}handleTracksChange(e){this.selected(this.track.enabled)}}Component$1.registerComponent("AudioTrackMenuItem",AudioTrackMenuItem);class AudioTrackButton extends TrackButton{constructor(e,n={}){n.tracks=e.audioTracks(),super(e,n),this.setIcon("audio")}buildCSSClass(){return`vjs-audio-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-audio-button ${super.buildWrapperCSSClass()}`}createItems(e=[]){this.hideThreshold_=1;const n=this.player_.audioTracks();for(let o=0;o<n.length;o++){const u=n[o];e.push(new AudioTrackMenuItem(this.player_,{track:u,selectable:!0,multiSelectable:!1}))}return e}}AudioTrackButton.prototype.controlText_="Audio Track",Component$1.registerComponent("AudioTrackButton",AudioTrackButton);class PlaybackRateMenuItem extends MenuItem{constructor(e,n){const o=n.rate,u=parseFloat(o,10);n.label=o,n.selected=u===e.playbackRate(),n.selectable=!0,n.multiSelectable=!1,super(e,n),this.label=o,this.rate=u,this.on(e,"ratechange",l=>this.update(l))}handleClick(e){super.handleClick(),this.player().playbackRate(this.rate)}update(e){this.selected(this.player().playbackRate()===this.rate)}}PlaybackRateMenuItem.prototype.contentElType="button",Component$1.registerComponent("PlaybackRateMenuItem",PlaybackRateMenuItem);class PlaybackRateMenuButton extends MenuButton{constructor(e,n){super(e,n),this.menuButton_.el_.setAttribute("aria-describedby",this.labelElId_),this.updateVisibility(),this.updateLabel(),this.on(e,"loadstart",o=>this.updateVisibility(o)),this.on(e,"ratechange",o=>this.updateLabel(o)),this.on(e,"playbackrateschange",o=>this.handlePlaybackRateschange(o))}createEl(){const e=super.createEl();return this.labelElId_="vjs-playback-rate-value-label-"+this.id_,this.labelEl_=createEl("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(),n=[];for(let o=e.length-1;o>=0;o--)n.push(new PlaybackRateMenuItem(this.player(),{rate:e[o]+"x"}));return n}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")}}PlaybackRateMenuButton.prototype.controlText_="Playback Rate",Component$1.registerComponent("PlaybackRateMenuButton",PlaybackRateMenuButton);class Spacer extends Component$1{buildCSSClass(){return`vjs-spacer ${super.buildCSSClass()}`}createEl(e="div",n={},o={}){return n.className||(n.className=this.buildCSSClass()),super.createEl(e,n,o)}}Component$1.registerComponent("Spacer",Spacer);class CustomControlSpacer extends Spacer{buildCSSClass(){return`vjs-custom-control-spacer ${super.buildCSSClass()}`}createEl(){return super.createEl("div",{className:this.buildCSSClass(),textContent:" "})}}Component$1.registerComponent("CustomControlSpacer",CustomControlSpacer);class ControlBar extends Component$1{createEl(){return super.createEl("div",{className:"vjs-control-bar",dir:"ltr"})}}ControlBar.prototype.options_={children:["playToggle","skipBackward","skipForward","volumePanel","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","seekToLive","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subsCapsButton","audioTrackButton","pictureInPictureToggle","fullscreenToggle"]},Component$1.registerComponent("ControlBar",ControlBar);class ErrorDisplay extends ModalDialog{constructor(e,n){super(e,n),this.on(e,"error",o=>{this.open(o)})}buildCSSClass(){return`vjs-error-display ${super.buildCSSClass()}`}content(){const e=this.player().error();return e?this.localize(e.message):""}}ErrorDisplay.prototype.options_=Object.assign({},ModalDialog.prototype.options_,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),Component$1.registerComponent("ErrorDisplay",ErrorDisplay);class TextTrackSelect extends Component$1{constructor(e,n={}){super(e,n),this.el_.setAttribute("aria-labelledby",this.selectLabelledbyIds)}createEl(){return this.selectLabelledbyIds=[this.options_.legendId,this.options_.labelId].join(" ").trim(),createEl("select",{id:this.options_.id},{},this.options_.SelectOptions.map(n=>{const o=(this.options_.labelId?this.options_.labelId:`vjs-track-option-${newGUID()}`)+"-"+n[1].replace(/\W+/g,""),u=createEl("option",{id:o,value:this.localize(n[0]),textContent:n[1]});return u.setAttribute("aria-labelledby",`${this.selectLabelledbyIds} ${o}`),u}))}}Component$1.registerComponent("TextTrackSelect",TextTrackSelect);class TextTrackFieldset extends Component$1{constructor(e,n={}){super(e,n);const o=createEl("legend",{textContent:this.localize(this.options_.legendText),id:this.options_.legendId});this.el().appendChild(o);const u=this.options_.selects;for(const l of u){const m=this.options_.selectConfigs[l],y=m.className,E=m.id.replace("%s",this.options_.id_);let C=null;const k=`vjs_select_${newGUID()}`;if(this.options_.type==="colors"){C=createEl("span",{className:y});const D=createEl("label",{id:E,className:"vjs-label",textContent:m.label});D.setAttribute("for",k),C.appendChild(D)}const A=new TextTrackSelect(e,{SelectOptions:m.options,legendId:this.options_.legendId,id:k,labelId:E});this.addChild(A),this.options_.type==="colors"&&(C.appendChild(A.el()),this.el().appendChild(C))}}createEl(){return createEl("fieldset",{className:this.options_.className})}}Component$1.registerComponent("TextTrackFieldset",TextTrackFieldset);class TextTrackSettingsColors extends Component$1{constructor(e,n={}){super(e,n);const o=this.options_.textTrackComponentid,u=new TextTrackFieldset(e,{id_:o,legendId:`captions-text-legend-${o}`,legendText:this.localize("Text"),className:"vjs-fg vjs-track-setting",selects:this.options_.fieldSets[0],selectConfigs:this.options_.selectConfigs,type:"colors"});this.addChild(u);const l=new TextTrackFieldset(e,{id_:o,legendId:`captions-background-${o}`,legendText:this.localize("Text Background"),className:"vjs-bg vjs-track-setting",selects:this.options_.fieldSets[1],selectConfigs:this.options_.selectConfigs,type:"colors"});this.addChild(l);const m=new TextTrackFieldset(e,{id_:o,legendId:`captions-window-${o}`,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(m)}createEl(){return createEl("div",{className:"vjs-track-settings-colors"})}}Component$1.registerComponent("TextTrackSettingsColors",TextTrackSettingsColors);class TextTrackSettingsFont extends Component$1{constructor(e,n={}){super(e,n);const o=this.options_.textTrackComponentid,u=new TextTrackFieldset(e,{id_:o,legendId:`captions-font-size-${o}`,legendText:"Font Size",className:"vjs-font-percent vjs-track-setting",selects:this.options_.fieldSets[0],selectConfigs:this.options_.selectConfigs,type:"font"});this.addChild(u);const l=new TextTrackFieldset(e,{id_:o,legendId:`captions-edge-style-${o}`,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(l);const m=new TextTrackFieldset(e,{id_:o,legendId:`captions-font-family-${o}`,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(m)}createEl(){return createEl("div",{className:"vjs-track-settings-font"})}}Component$1.registerComponent("TextTrackSettingsFont",TextTrackSettingsFont);class TrackSettingsControls extends Component$1{constructor(e,n={}){super(e,n);const o=this.localize("restore all settings to the default values"),u=new Button(e,{controlText:o,className:"vjs-default-button"});u.el().classList.remove("vjs-control","vjs-button"),u.el().textContent=this.localize("Reset"),this.addChild(u);const l=new Button(e,{controlText:o,className:"vjs-done-button"});l.el().classList.remove("vjs-control","vjs-button"),l.el().textContent=this.localize("Done"),this.addChild(l)}createEl(){return createEl("div",{className:"vjs-track-settings-controls"})}}Component$1.registerComponent("TrackSettingsControls",TrackSettingsControls);const LOCAL_STORAGE_KEY$1="vjs-text-track-settings",COLOR_BLACK=["#000","Black"],COLOR_BLUE=["#00F","Blue"],COLOR_CYAN=["#0FF","Cyan"],COLOR_GREEN=["#0F0","Green"],COLOR_MAGENTA=["#F0F","Magenta"],COLOR_RED=["#F00","Red"],COLOR_WHITE=["#FFF","White"],COLOR_YELLOW=["#FF0","Yellow"],OPACITY_OPAQUE=["1","Opaque"],OPACITY_SEMI=["0.5","Semi-Transparent"],OPACITY_TRANS=["0","Transparent"],selectConfigs={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[COLOR_BLACK,COLOR_WHITE,COLOR_RED,COLOR_GREEN,COLOR_BLUE,COLOR_YELLOW,COLOR_MAGENTA,COLOR_CYAN],className:"vjs-bg-color"},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Opacity",options:[OPACITY_OPAQUE,OPACITY_SEMI,OPACITY_TRANS],className:"vjs-bg-opacity vjs-opacity"},color:{selector:".vjs-text-color > select",id:"captions-foreground-color-%s",label:"Color",options:[COLOR_WHITE,COLOR_BLACK,COLOR_RED,COLOR_GREEN,COLOR_BLUE,COLOR_YELLOW,COLOR_MAGENTA,COLOR_CYAN],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:t=>t==="1.00"?null:Number(t)},textOpacity:{selector:".vjs-text-opacity > select",id:"captions-foreground-opacity-%s",label:"Opacity",options:[OPACITY_OPAQUE,OPACITY_SEMI],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:[OPACITY_TRANS,OPACITY_SEMI,OPACITY_OPAQUE],className:"vjs-window-opacity vjs-opacity"}};selectConfigs.windowColor.options=selectConfigs.backgroundColor.options;function parseOptionValue(t,e){if(e&&(t=e(t)),t&&t!=="none")return t}function getSelectedOptionValue(t,e){const n=t.options[t.options.selectedIndex].value;return parseOptionValue(n,e)}function setSelectedOption(t,e,n){if(e){for(let o=0;o<t.options.length;o++)if(parseOptionValue(t.options[o].value,n)===e){t.selectedIndex=o;break}}}class TextTrackSettings extends ModalDialog{constructor(e,n){n.temporary=!1,super(e,n),this.updateDisplay=this.updateDisplay.bind(this),this.fill(),this.hasBeenOpened_=this.hasBeenFilled_=!0,this.renderModalComponents(e),this.endDialog=createEl("p",{className:"vjs-control-text",textContent:this.localize("End of dialog window.")}),this.el().appendChild(this.endDialog),this.setDefaults(),n.persistTextTrackSettings===void 0&&(this.options_.persistTextTrackSettings=this.options_.playerOptions.persistTextTrackSettings),this.bindFunctionsToSelectsAndButtons(),this.options_.persistTextTrackSettings&&this.restoreSettings()}renderModalComponents(e){const n=new TextTrackSettingsColors(e,{textTrackComponentid:this.id_,selectConfigs,fieldSets:[["color","textOpacity"],["backgroundColor","backgroundOpacity"],["windowColor","windowOpacity"]]});this.addChild(n);const o=new TextTrackSettingsFont(e,{textTrackComponentid:this.id_,selectConfigs,fieldSets:[["fontPercent"],["edgeStyle"],["fontFamily"]]});this.addChild(o);const u=new TrackSettingsControls(e);this.addChild(u)}bindFunctionsToSelectsAndButtons(){this.on(this.$(".vjs-done-button"),["click","tap"],()=>{this.saveSettings(),this.close()}),this.on(this.$(".vjs-default-button"),["click","tap"],()=>{this.setDefaults(),this.updateDisplay()}),each(selectConfigs,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 reduce(selectConfigs,(e,n,o)=>{const u=getSelectedOptionValue(this.$(n.selector),n.parser);return u!==void 0&&(e[o]=u),e},{})}setValues(e){each(selectConfigs,(n,o)=>{setSelectedOption(this.$(n.selector),e[o],n.parser)})}setDefaults(){each(selectConfigs,e=>{const n=e.hasOwnProperty("default")?e.default:0;this.$(e.selector).selectedIndex=n})}restoreSettings(){let e;try{e=JSON.parse(window$1$1.localStorage.getItem(LOCAL_STORAGE_KEY$1))}catch(n){log$1.warn(n)}e&&this.setValues(e)}saveSettings(){if(!this.options_.persistTextTrackSettings)return;const e=this.getValues();try{Object.keys(e).length?window$1$1.localStorage.setItem(LOCAL_STORAGE_KEY$1,JSON.stringify(e)):window$1$1.localStorage.removeItem(LOCAL_STORAGE_KEY$1)}catch(n){log$1.warn(n)}}updateDisplay(){const e=this.player_.getChild("textTrackDisplay");e&&e.updateDisplay()}handleLanguagechange(){this.fill(),this.renderModalComponents(this.player_),this.bindFunctionsToSelectsAndButtons()}}Component$1.registerComponent("TextTrackSettings",TextTrackSettings);class ResizeManager extends Component$1{constructor(e,n){let o=n.ResizeObserver||window$1$1.ResizeObserver;n.ResizeObserver===null&&(o=!1);const u=merge$1({createEl:!o,reportTouchActivity:!1},n);super(e,u),this.ResizeObserver=n.ResizeObserver||window$1$1.ResizeObserver,this.loadListener_=null,this.resizeObserver_=null,this.debouncedHandler_=debounce(()=>{this.resizeHandler()},100,!1,this),o?(this.resizeObserver_=new this.ResizeObserver(this.debouncedHandler_),this.resizeObserver_.observe(e.el())):(this.loadListener_=()=>{if(!this.el_||!this.el_.contentWindow)return;const l=this.debouncedHandler_;let m=this.unloadListener_=function(){off(this,"resize",l),off(this,"unload",m),m=null};on(this.el_.contentWindow,"unload",m),on(this.el_.contentWindow,"resize",l)},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()}}Component$1.registerComponent("ResizeManager",ResizeManager);const defaults$1={trackingThreshold:20,liveTolerance:15};class LiveTracker extends Component$1{constructor(e,n){const o=merge$1(defaults$1,n,{createEl:!1});super(e,o),this.trackLiveHandler_=()=>this.trackLive_(),this.handlePlay_=u=>this.handlePlay(u),this.handleFirstTimeupdate_=u=>this.handleFirstTimeupdate(u),this.handleSeeked_=u=>this.handleSeeked(u),this.seekToLiveEdge_=u=>this.seekToLiveEdge(u),this.reset_(),this.on(this.player_,"durationchange",u=>this.handleDurationchange(u)),this.on(this.player_,"canplay",()=>this.toggleTracking())}trackLive_(){const e=this.player_.seekable();if(!e||!e.length)return;const n=Number(window$1$1.performance.now().toFixed(4)),o=this.lastTime_===-1?0:(n-this.lastTime_)/1e3;this.lastTime_=n,this.pastSeekEnd_=this.pastSeekEnd()+o;const u=this.liveCurrentTime(),l=this.player_.currentTime();let m=this.player_.paused()||this.seekedBehindLive_||Math.abs(u-l)>this.options_.liveTolerance;(!this.timeupdateSeen_||u===1/0)&&(m=!1),m!==this.behindLiveEdge_&&(this.behindLiveEdge_=m,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_,UPDATE_REFRESH_INTERVAL),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(),n=[];let o=e?e.length:0;for(;o--;)n.push(e.end(o));return n.length?n.sort()[n.length-1]:1/0}seekableStart(){const e=this.player_.seekable(),n=[];let o=e?e.length:0;for(;o--;)n.push(e.start(o));return n.length?n.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()}}Component$1.registerComponent("LiveTracker",LiveTracker);class TitleBar extends Component$1{constructor(e,n){super(e,n),this.on("statechanged",o=>this.updateDom_()),this.updateDom_()}createEl(){return this.els={title:createEl("div",{className:"vjs-title-bar-title",id:`vjs-title-bar-title-${newGUID()}`}),description:createEl("div",{className:"vjs-title-bar-description",id:`vjs-title-bar-description-${newGUID()}`})},createEl("div",{className:"vjs-title-bar"},{},values(this.els))}updateDom_(){const e=this.player_.tech_,n=e&&e.el_,o={title:"aria-labelledby",description:"aria-describedby"};["title","description"].forEach(u=>{const l=this.state[u],m=this.els[u],y=o[u];emptyEl(m),l&&textContent(m,l),n&&(n.removeAttribute(y),l&&n.setAttribute(y,m.id))}),this.state.title||this.state.description?this.show():this.hide()}update(e){this.setState(e)}dispose(){const e=this.player_.tech_,n=e&&e.el_;n&&(n.removeAttribute("aria-labelledby"),n.removeAttribute("aria-describedby")),super.dispose(),this.els=null}}Component$1.registerComponent("TitleBar",TitleBar);const defaults$2={initialDisplay:4e3,position:[],takeFocus:!1};class TransientButton extends Button{constructor(e,n){n=merge$1(defaults$2,n),super(e,n),this.controlText(n.controlText),this.hide(),this.on(this.player_,["useractive","userinactive"],o=>{this.removeClass("force-display")})}buildCSSClass(){return`vjs-transient-button focus-visible ${this.options_.position.map(e=>`vjs-${e}`).join(" ")}`}createEl(){const e=createEl("button",{},{type:"button",class:this.buildCSSClass()},createEl("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()}}Component$1.registerComponent("TransientButton",TransientButton);const sourcesetLoad=t=>{const e=t.el();if(e.hasAttribute("src"))return t.triggerSourceset(e.src),!0;const n=t.$$("source"),o=[];let u="";if(!n.length)return!1;for(let l=0;l<n.length;l++){const m=n[l].src;m&&o.indexOf(m)===-1&&o.push(m)}return o.length?(o.length===1&&(u=o[0]),t.triggerSourceset(u),!0):!1},innerHTMLDescriptorPolyfill=Object.defineProperty({},"innerHTML",{get(){return this.cloneNode(!0).innerHTML},set(t){const e=document$1$1.createElement(this.nodeName.toLowerCase());e.innerHTML=t;const n=document$1$1.createDocumentFragment();for(;e.childNodes.length;)n.appendChild(e.childNodes[0]);return this.innerText="",window$1$1.Element.prototype.appendChild.call(this,n),this.innerHTML}}),getDescriptor=(t,e)=>{let n={};for(let o=0;o<t.length&&(n=Object.getOwnPropertyDescriptor(t[o],e),!(n&&n.set&&n.get));o++);return n.enumerable=!0,n.configurable=!0,n},getInnerHTMLDescriptor=t=>getDescriptor([t.el(),window$1$1.HTMLMediaElement.prototype,window$1$1.Element.prototype,innerHTMLDescriptorPolyfill],"innerHTML"),firstSourceWatch=function(t){const e=t.el();if(e.resetSourceWatch_)return;const n={},o=getInnerHTMLDescriptor(t),u=l=>(...m)=>{const y=l.apply(e,m);return sourcesetLoad(t),y};["append","appendChild","insertAdjacentHTML"].forEach(l=>{e[l]&&(n[l]=e[l],e[l]=u(n[l]))}),Object.defineProperty(e,"innerHTML",merge$1(o,{set:u(o.set)})),e.resetSourceWatch_=()=>{e.resetSourceWatch_=null,Object.keys(n).forEach(l=>{e[l]=n[l]}),Object.defineProperty(e,"innerHTML",o)},t.one("sourceset",e.resetSourceWatch_)},srcDescriptorPolyfill=Object.defineProperty({},"src",{get(){return this.hasAttribute("src")?getAbsoluteURL(window$1$1.Element.prototype.getAttribute.call(this,"src")):""},set(t){return window$1$1.Element.prototype.setAttribute.call(this,"src",t),t}}),getSrcDescriptor=t=>getDescriptor([t.el(),window$1$1.HTMLMediaElement.prototype,srcDescriptorPolyfill],"src"),setupSourceset=function(t){if(!t.featuresSourceset)return;const e=t.el();if(e.resetSourceset_)return;const n=getSrcDescriptor(t),o=e.setAttribute,u=e.load;Object.defineProperty(e,"src",merge$1(n,{set:l=>{const m=n.set.call(e,l);return t.triggerSourceset(e.src),m}})),e.setAttribute=(l,m)=>{const y=o.call(e,l,m);return/src/i.test(l)&&t.triggerSourceset(e.src),y},e.load=()=>{const l=u.call(e);return sourcesetLoad(t)||(t.triggerSourceset(""),firstSourceWatch(t)),l},e.currentSrc?t.triggerSourceset(e.currentSrc):sourcesetLoad(t)||firstSourceWatch(t),e.resetSourceset_=()=>{e.resetSourceset_=null,e.load=u,e.setAttribute=o,Object.defineProperty(e,"src",n),e.resetSourceWatch_&&e.resetSourceWatch_()}};class Html5 extends Tech$1{constructor(e,n){super(e,n);const o=e.source;let u=!1;if(this.featuresVideoFrameCallback=this.featuresVideoFrameCallback&&this.el_.tagName==="VIDEO",o&&(this.el_.currentSrc!==o.src||e.tag&&e.tag.initNetworkState_===3)?this.setSource(o):this.handleLateInit_(this.el_),e.enableSourceset&&this.setupSourcesetHandling_(),this.isScrubbing_=!1,this.el_.hasChildNodes()){const l=this.el_.childNodes;let m=l.length;const y=[];for(;m--;){const E=l[m];E.nodeName.toLowerCase()==="track"&&(this.featuresNativeTextTracks?(this.remoteTextTrackEls().addTrackElement_(E),this.remoteTextTracks().addTrack(E.track),this.textTracks().addTrack(E.track),!u&&!this.el_.hasAttribute("crossorigin")&&isCrossOrigin(E.src)&&(u=!0)):y.push(E))}for(let E=0;E<y.length;E++)this.el_.removeChild(y[E])}this.proxyNativeTracks_(),this.featuresNativeTextTracks&&u&&log$1.warn(`Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.
This may prevent text tracks from loading.`),this.restoreMetadataTracksInIOSNativePlayer_(),(TOUCH_ENABLED||IS_IPHONE)&&e.nativeControlsForTouch===!0&&this.setControls(!0),this.proxyWebkitFullscreen_(),this.triggerReady()}dispose(){this.el_&&this.el_.resetSourceset_&&this.el_.resetSourceset_(),Html5.disposeMediaElement(this.el_),this.options_=null,super.dispose()}setupSourcesetHandling_(){setupSourceset(this)}restoreMetadataTracksInIOSNativePlayer_(){const e=this.textTracks();let n;const o=()=>{n=[];for(let l=0;l<e.length;l++){const m=e[l];m.kind==="metadata"&&n.push({track:m,storedMode:m.mode})}};o(),e.addEventListener("change",o),this.on("dispose",()=>e.removeEventListener("change",o));const u=()=>{for(let l=0;l<n.length;l++){const m=n[l];m.track.mode==="disabled"&&m.track.mode!==m.storedMode&&(m.track.mode=m.storedMode)}e.removeEventListener("change",u)};this.on("webkitbeginfullscreen",()=>{e.removeEventListener("change",o),e.removeEventListener("change",u),e.addEventListener("change",u)}),this.on("webkitendfullscreen",()=>{e.removeEventListener("change",o),e.addEventListener("change",o),e.removeEventListener("change",u)})}overrideNative_(e,n){if(n!==this[`featuresNative${e}Tracks`])return;const o=e.toLowerCase();this[`${o}TracksListeners_`]&&Object.keys(this[`${o}TracksListeners_`]).forEach(u=>{this.el()[`${o}Tracks`].removeEventListener(u,this[`${o}TracksListeners_`][u])}),this[`featuresNative${e}Tracks`]=!n,this[`${o}TracksListeners_`]=null,this.proxyNativeTracksForType_(o)}overrideNativeAudioTracks(e){this.overrideNative_("Audio",e)}overrideNativeVideoTracks(e){this.overrideNative_("Video",e)}proxyNativeTracksForType_(e){const n=NORMAL[e],o=this.el()[n.getterName],u=this[n.getterName]();if(!this[`featuresNative${n.capitalName}Tracks`]||!o||!o.addEventListener)return;const l={change:y=>{const E={type:"change",target:u,currentTarget:u,srcElement:u};u.trigger(E),e==="text"&&this[REMOTE.remoteText.getterName]().trigger(E)},addtrack(y){u.addTrack(y.track)},removetrack(y){u.removeTrack(y.track)}},m=function(){const y=[];for(let E=0;E<u.length;E++){let C=!1;for(let k=0;k<o.length;k++)if(o[k]===u[E]){C=!0;break}C||y.push(u[E])}for(;y.length;)u.removeTrack(y.shift())};this[n.getterName+"Listeners_"]=l,Object.keys(l).forEach(y=>{const E=l[y];o.addEventListener(y,E),this.on("dispose",C=>o.removeEventListener(y,E))}),this.on("loadstart",m),this.on("dispose",y=>this.off("loadstart",m))}proxyNativeTracks_(){NORMAL.names.forEach(e=>{this.proxyNativeTracksForType_(e)})}createEl(){let e=this.options_.tag;if(!e||!(this.options_.playerElIngest||this.movingMediaElementInDOM)){if(e){const o=e.cloneNode(!0);e.parentNode&&e.parentNode.insertBefore(o,e),Html5.disposeMediaElement(e),e=o}else{e=document$1$1.createElement("video");const o=this.options_.tag&&getAttributes(this.options_.tag),u=merge$1({},o);(!TOUCH_ENABLED||this.options_.nativeControlsForTouch!==!0)&&delete u.controls,setAttributes(e,Object.assign(u,{id:this.options_.techId,class:"vjs-tech"}))}e.playerId=this.options_.playerId}typeof this.options_.preload<"u"&&setAttribute(e,"preload",this.options_.preload),this.options_.disablePictureInPicture!==void 0&&(e.disablePictureInPicture=this.options_.disablePictureInPicture);const n=["loop","muted","playsinline","autoplay"];for(let o=0;o<n.length;o++){const u=n[o],l=this.options_[u];typeof l<"u"&&(l?setAttribute(e,u,u):removeAttribute(e,u),e[u]=l)}return e}handleLateInit_(e){if(e.networkState===0||e.networkState===3)return;if(e.readyState===0){let o=!1;const u=function(){o=!0};this.on("loadstart",u);const l=function(){o||this.trigger("loadstart")};this.on("loadedmetadata",l),this.ready(function(){this.off("loadstart",u),this.off("loadedmetadata",l),o||this.trigger("loadstart")});return}const n=["loadstart"];n.push("loadedmetadata"),e.readyState>=2&&n.push("loadeddata"),e.readyState>=3&&n.push("canplay"),e.readyState>=4&&n.push("canplaythrough"),this.ready(function(){n.forEach(function(o){this.trigger(o)},this)})}setScrubbing(e){this.isScrubbing_=e}scrubbing(){return this.isScrubbing_}setCurrentTime(e){try{this.isScrubbing_&&this.el_.fastSeek&&IS_ANY_SAFARI?this.el_.fastSeek(e):this.el_.currentTime=e}catch(n){log$1(n,"Video is not ready. (Video.js)")}}duration(){if(this.el_.duration===1/0&&IS_ANDROID&&IS_CHROME&&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)},n=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",n),this.on("dispose",()=>{this.off("webkitbeginfullscreen",n),this.off("webkitendfullscreen",e)})}supportsFullScreen(){return typeof this.el_.webkitEnterFullScreen=="function"}enterFullScreen(){const e=this.el_;if(e.paused&&e.networkState<=e.HAVE_METADATA)silencePromise(this.el_.play()),this.setTimeout(function(){e.pause();try{e.webkitEnterFullScreen()}catch(n){this.trigger("fullscreenerror",n)}},0);else try{e.webkitEnterFullScreen()}catch(n){this.trigger("fullscreenerror",n)}}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(){Html5.resetMediaElement(this.el_)}currentSrc(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc}setControls(e){this.el_.controls=!!e}addTextTrack(e,n,o){return this.featuresNativeTextTracks?this.el_.addTextTrack(e,n,o):super.addTextTrack(e,n,o)}createRemoteTextTrack(e){if(!this.featuresNativeTextTracks)return super.createRemoteTextTrack(e);const n=document$1$1.createElement("track");return e.kind&&(n.kind=e.kind),e.label&&(n.label=e.label),(e.language||e.srclang)&&(n.srclang=e.language||e.srclang),e.default&&(n.default=e.default),e.id&&(n.id=e.id),e.src&&(n.src=e.src),n}addRemoteTextTrack(e,n){const o=super.addRemoteTextTrack(e,n);return this.featuresNativeTextTracks&&this.el().appendChild(o),o}removeRemoteTextTrack(e){if(super.removeRemoteTextTrack(e),this.featuresNativeTextTracks){const n=this.$$("track");let o=n.length;for(;o--;)(e===n[o]||e===n[o].track)&&this.el().removeChild(n[o])}}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),window$1$1.performance&&(e.creationTime=window$1$1.performance.now()),e}}defineLazyProperty(Html5,"TEST_VID",function(){if(!isReal())return;const t=document$1$1.createElement("video"),e=document$1$1.createElement("track");return e.kind="captions",e.srclang="en",e.label="English",t.appendChild(e),t}),Html5.isSupported=function(){try{Html5.TEST_VID.volume=.5}catch{return!1}return!!(Html5.TEST_VID&&Html5.TEST_VID.canPlayType)},Html5.canPlayType=function(t){return Html5.TEST_VID.canPlayType(t)},Html5.canPlaySource=function(t,e){return Html5.canPlayType(t.type)},Html5.canControlVolume=function(){try{const t=Html5.TEST_VID.volume;Html5.TEST_VID.volume=t/2+.1;const e=t!==Html5.TEST_VID.volume;return e&&IS_IOS?(window$1$1.setTimeout(()=>{Html5&&Html5.prototype&&(Html5.prototype.featuresVolumeControl=t!==Html5.TEST_VID.volume)}),!1):e}catch{return!1}},Html5.canMuteVolume=function(){try{const t=Html5.TEST_VID.muted;return Html5.TEST_VID.muted=!t,Html5.TEST_VID.muted?setAttribute(Html5.TEST_VID,"muted","muted"):removeAttribute(Html5.TEST_VID,"muted","muted"),t!==Html5.TEST_VID.muted}catch{return!1}},Html5.canControlPlaybackRate=function(){if(IS_ANDROID&&IS_CHROME&&CHROME_VERSION<58)return!1;try{const t=Html5.TEST_VID.playbackRate;return Html5.TEST_VID.playbackRate=t/2+.1,t!==Html5.TEST_VID.playbackRate}catch{return!1}},Html5.canOverrideAttributes=function(){try{const t=()=>{};Object.defineProperty(document$1$1.createElement("video"),"src",{get:t,set:t}),Object.defineProperty(document$1$1.createElement("audio"),"src",{get:t,set:t}),Object.defineProperty(document$1$1.createElement("video"),"innerHTML",{get:t,set:t}),Object.defineProperty(document$1$1.createElement("audio"),"innerHTML",{get:t,set:t})}catch{return!1}return!0},Html5.supportsNativeTextTracks=function(){return IS_ANY_SAFARI||IS_IOS&&IS_CHROME},Html5.supportsNativeVideoTracks=function(){return!!(Html5.TEST_VID&&Html5.TEST_VID.videoTracks)},Html5.supportsNativeAudioTracks=function(){return!!(Html5.TEST_VID&&Html5.TEST_VID.audioTracks)},Html5.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([t,e]){defineLazyProperty(Html5.prototype,t,()=>Html5[e](),!0)}),Html5.prototype.featuresVolumeControl=Html5.canControlVolume(),Html5.prototype.movingMediaElementInDOM=!IS_IOS,Html5.prototype.featuresFullscreenResize=!0,Html5.prototype.featuresProgressEvents=!0,Html5.prototype.featuresTimeupdateEvents=!0,Html5.prototype.featuresVideoFrameCallback=!!(Html5.TEST_VID&&Html5.TEST_VID.requestVideoFrameCallback),Html5.disposeMediaElement=function(t){if(t){for(t.parentNode&&t.parentNode.removeChild(t);t.hasChildNodes();)t.removeChild(t.firstChild);t.removeAttribute("src"),typeof t.load=="function"&&function(){try{t.load()}catch{}}()}},Html5.resetMediaElement=function(t){if(!t)return;const e=t.querySelectorAll("source");let n=e.length;for(;n--;)t.removeChild(e[n]);t.removeAttribute("src"),typeof t.load=="function"&&function(){try{t.load()}catch{}}()},["muted","defaultMuted","autoplay","controls","loop","playsinline"].forEach(function(t){Html5.prototype[t]=function(){return this.el_[t]||this.el_.hasAttribute(t)}}),["muted","defaultMuted","autoplay","loop","playsinline"].forEach(function(t){Html5.prototype["set"+toTitleCase$1(t)]=function(e){this.el_[t]=e,e?this.el_.setAttribute(t,t):this.el_.removeAttribute(t)}}),["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","defaultPlaybackRate","disablePictureInPicture","played","networkState","readyState","videoWidth","videoHeight","crossOrigin"].forEach(function(t){Html5.prototype[t]=function(){return this.el_[t]}}),["volume","src","poster","preload","playbackRate","defaultPlaybackRate","disablePictureInPicture","crossOrigin"].forEach(function(t){Html5.prototype["set"+toTitleCase$1(t)]=function(e){this.el_[t]=e}}),["pause","load","play"].forEach(function(t){Html5.prototype[t]=function(){return this.el_[t]()}}),Tech$1.withSourceHandlers(Html5),Html5.nativeSourceHandler={},Html5.nativeSourceHandler.canPlayType=function(t){try{return Html5.TEST_VID.canPlayType(t)}catch{return""}},Html5.nativeSourceHandler.canHandleSource=function(t,e){if(t.type)return Html5.nativeSourceHandler.canPlayType(t.type);if(t.src){const n=getFileExtension(t.src);return Html5.nativeSourceHandler.canPlayType(`video/${n}`)}return""},Html5.nativeSourceHandler.handleSource=function(t,e,n){e.setSrc(t.src)},Html5.nativeSourceHandler.dispose=function(){},Html5.registerSourceHandler(Html5.nativeSourceHandler),Tech$1.registerTech("Html5",Html5);const TECH_EVENTS_RETRIGGER=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","resize","volumechange","texttrackchange"],TECH_EVENTS_QUEUE={canplay:"CanPlay",canplaythrough:"CanPlayThrough",playing:"Playing",seeked:"Seeked"},BREAKPOINT_ORDER=["tiny","xsmall","small","medium","large","xlarge","huge"],BREAKPOINT_CLASSES={};BREAKPOINT_ORDER.forEach(t=>{const e=t.charAt(0)==="x"?`x-${t.substring(1)}`:t;BREAKPOINT_CLASSES[t]=`vjs-layout-${e}`});const DEFAULT_BREAKPOINTS={tiny:210,xsmall:320,small:425,medium:768,large:1440,xlarge:2560,huge:1/0};let Player$1=class ms extends Component$1{constructor(e,n,o){if(e.id=e.id||n.id||`vjs_video_${newGUID()}`,n=Object.assign(ms.getTagSettings(e),n),n.initChildren=!1,n.createEl=!1,n.evented=!1,n.reportTouchActivity=!1,!n.language){const m=e.closest("[lang]");m&&(n.language=m.getAttribute("lang"))}if(super(null,n,o),this.boundDocumentFullscreenChange_=m=>this.documentFullscreenChange_(m),this.boundFullWindowOnEscKey_=m=>this.fullWindowOnEscKey(m),this.boundUpdateStyleEl_=m=>this.updateStyleEl_(m),this.boundApplyInitTime_=m=>this.applyInitTime_(m),this.boundUpdateCurrentBreakpoint_=m=>this.updateCurrentBreakpoint_(m),this.boundHandleTechClick_=m=>this.handleTechClick_(m),this.boundHandleTechDoubleClick_=m=>this.handleTechDoubleClick_(m),this.boundHandleTechTouchStart_=m=>this.handleTechTouchStart_(m),this.boundHandleTechTouchMove_=m=>this.handleTechTouchMove_(m),this.boundHandleTechTouchEnd_=m=>this.handleTechTouchEnd_(m),this.boundHandleTechTap_=m=>this.handleTechTap_(m),this.boundUpdatePlayerHeightOnAudioOnlyMode_=m=>this.updatePlayerHeightOnAudioOnlyMode_(m),this.isFullscreen_=!1,this.log=createLogger(this.id_),this.fsApi_=FullscreenApi,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&&getAttributes(e),this.language(this.options_.language),n.languages){const m={};Object.getOwnPropertyNames(n.languages).forEach(function(y){m[y.toLowerCase()]=n.languages[y]}),this.languages_=m}else this.languages_=ms.prototype.options_.languages;this.resetCache_(),this.poster_=n.poster||"",this.controls_=!!n.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),n.plugins&&Object.keys(n.plugins).forEach(m=>{if(typeof this[m]!="function")throw new Error(`plugin "${m}" does not exist`)}),this.scrubbing_=!1,this.el_=this.createEl(),evented(this,{eventBusKey:"el_"}),this.fsApi_.requestFullscreen&&(on(document$1$1,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),this.on(this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_)),this.fluid_&&this.on(["playerreset","resize"],this.boundUpdateStyleEl_);const u=merge$1(this.options_);if(n.plugins&&Object.keys(n.plugins).forEach(m=>{this[m](n.plugins[m])}),n.debug&&this.debug(!0),this.options_.playerOptions=u,this.middleware_=[],this.playbackRates(n.playbackRates),n.experimentalSvgIcons){const y=new window$1$1.DOMParser().parseFromString(icons,"image/svg+xml");if(y.querySelector("parsererror"))log$1.warn("Failed to load SVG Icons. Falling back to Font Icons."),this.options_.experimentalSvgIcons=null;else{const C=y.documentElement;C.style.display="none",this.el_.appendChild(C),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"),n.spatialNavigation&&n.spatialNavigation.enabled&&(this.spatialNavigation=new SpatialNavigation(this),this.addClass("vjs-spatial-navigation-enabled")),TOUCH_ENABLED&&this.addClass("vjs-touch-enabled"),IS_IOS||this.addClass("vjs-workinghover"),ms.players[this.id_]=this;const l=version$6.split(".")[0];this.addClass(`vjs-v${l}`),this.userActive(!0),this.reportUserActivity(),this.one("play",m=>this.listenForUserActivity_(m)),this.on("keydown",m=>this.handleKeyDown(m)),this.on("languagechange",m=>this.handleLanguagechange(m)),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"),off(document$1$1,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),off(document$1$1,"keydown",this.boundFullWindowOnEscKey_),this.styleEl_&&this.styleEl_.parentNode&&(this.styleEl_.parentNode.removeChild(this.styleEl_),this.styleEl_=null),ms.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),clearCacheForPlayer(this),ALL.names.forEach(e=>{const n=ALL[e],o=this[n.getterName]();o&&o.off&&o.off()}),super.dispose({restoreEl:this.options_.restoreEl})}createEl(){let e=this.tag,n,o=this.playerElIngest_=e.parentNode&&e.parentNode.hasAttribute&&e.parentNode.hasAttribute("data-vjs-player");const u=this.tag.tagName.toLowerCase()==="video-js";o?n=this.el_=e.parentNode:u||(n=this.el_=super.createEl("div"));const l=getAttributes(e);if(u){for(n=this.el_=e,e=this.tag=document$1$1.createElement("video");n.children.length;)e.appendChild(n.firstChild);hasClass(n,"video-js")||addClass(n,"video-js"),n.appendChild(e),o=this.playerElIngest_=n,Object.keys(n).forEach(E=>{try{e[E]=n[E]}catch{}})}e.setAttribute("tabindex","-1"),l.tabindex="-1",IS_CHROME&&IS_WINDOWS&&(e.setAttribute("role","application"),l.role="application"),e.removeAttribute("width"),e.removeAttribute("height"),"width"in l&&delete l.width,"height"in l&&delete l.height,Object.getOwnPropertyNames(l).forEach(function(E){u&&E==="class"||n.setAttribute(E,l[E]),u&&e.setAttribute(E,l[E])}),e.playerId=e.id,e.id+="_html5_api",e.className="vjs-tech",e.player=n.player=this,this.addClass("vjs-paused");const m=["IS_SMART_TV","IS_TIZEN","IS_WEBOS","IS_ANDROID","IS_IPAD","IS_IPHONE","IS_CHROMECAST_RECEIVER"].filter(E=>browser$f[E]).map(E=>"vjs-device-"+E.substring(3).toLowerCase().replace(/\_/g,"-"));if(this.addClass(...m),window$1$1.VIDEOJS_NO_DYNAMIC_STYLE!==!0){this.styleEl_=createStyleElement("vjs-styles-dimensions");const E=$(".vjs-styles-defaults"),C=$("head");C.insertBefore(this.styleEl_,E?E.nextSibling:C.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 y=e.getElementsByTagName("a");for(let E=0;E<y.length;E++){const C=y.item(E);addClass(C,"vjs-hidden"),C.setAttribute("hidden","hidden")}return e.initNetworkState_=e.networkState,e.parentNode&&!o&&e.parentNode.insertBefore(n,e),prependTo(e,n),this.children_.unshift(e),this.el_.setAttribute("lang",this.language_),this.el_.setAttribute("translate","no"),this.el_=n,n}crossOrigin(e){if(typeof e>"u")return this.techGet_("crossOrigin");if(e!==null&&e!=="anonymous"&&e!=="use-credentials"){log$1.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,n){const o=e+"_";if(n===void 0)return this[o]||0;if(n===""||n==="auto"){this[o]=void 0,this.updateStyleEl_();return}const u=parseFloat(n);if(isNaN(u)){log$1.error(`Improper value "${n}" supplied for for ${e}`);return}this[o]=u,this.updateStyleEl_()}fluid(e){if(e===void 0)return!!this.fluid_;this.fluid_=!!e,isEvented(this)&&this.off(["playerreset","resize"],this.boundUpdateStyleEl_),e?(this.addClass("vjs-fluid"),this.fill(!1),addEventedCallback(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(window$1$1.VIDEOJS_NO_DYNAMIC_STYLE===!0){const y=typeof this.width_=="number"?this.width_:this.options_.width,E=typeof this.height_=="number"?this.height_:this.options_.height,C=this.tech_&&this.tech_.el();C&&(y>=0&&(C.width=y),E>=0&&(C.height=E));return}let e,n,o,u;this.aspectRatio_!==void 0&&this.aspectRatio_!=="auto"?o=this.aspectRatio_:this.videoWidth()>0?o=this.videoWidth()+":"+this.videoHeight():o="16:9";const l=o.split(":"),m=l[1]/l[0];this.width_!==void 0?e=this.width_:this.height_!==void 0?e=this.height_/m:e=this.videoWidth()||300,this.height_!==void 0?n=this.height_:n=e*m,/^[^a-zA-Z]/.test(this.id())?u="dimensions-"+this.id():u=this.id()+"-dimensions",this.addClass(u),setTextContent(this.styleEl_,`
      .${u} {
        width: ${e}px;
        height: ${n}px;
      }

      .${u}.vjs-fluid:not(.vjs-audio-only-mode) {
        padding-top: ${m*100}%;
      }
    `)}loadTech_(e,n){this.tech_&&this.unloadTech_();const o=toTitleCase$1(e),u=e.charAt(0).toLowerCase()+e.slice(1);o!=="Html5"&&this.tag&&(Tech$1.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.techName_=o,this.isReady_=!1;let l=this.autoplay();(typeof this.autoplay()=="string"||this.autoplay()===!0&&this.options_.normalizeAutoplay)&&(l=!1);const m={source:n,autoplay:l,nativeControlsForTouch:this.options_.nativeControlsForTouch,playerId:this.id(),techId:`${this.id()}_${u}_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};ALL.names.forEach(E=>{const C=ALL[E];m[C.getterName]=this[C.privateName]}),Object.assign(m,this.options_[o]),Object.assign(m,this.options_[u]),Object.assign(m,this.options_[e.toLowerCase()]),this.tag&&(m.tag=this.tag),n&&n.src===this.cache_.src&&this.cache_.currentTime>0&&(m.startTime=this.cache_.currentTime);const y=Tech$1.getTech(e);if(!y)throw new Error(`No Tech named '${o}' exists! '${o}' should be registered using videojs.registerTech()'`);this.tech_=new y(m),this.tech_.ready(bind_(this,this.handleTechReady_),!0),textTrackConverter.jsonToTextTracks(this.textTracksJson_||[],this.tech_),TECH_EVENTS_RETRIGGER.forEach(E=>{this.on(this.tech_,E,C=>this[`handleTech${toTitleCase$1(E)}_`](C))}),Object.keys(TECH_EVENTS_QUEUE).forEach(E=>{this.on(this.tech_,E,C=>{if(this.tech_.playbackRate()===0&&this.tech_.seeking()){this.queuedCallbacks_.push({callback:this[`handleTech${TECH_EVENTS_QUEUE[E]}_`].bind(this),event:C});return}this[`handleTech${TECH_EVENTS_QUEUE[E]}_`](C)})}),this.on(this.tech_,"loadstart",E=>this.handleTechLoadStart_(E)),this.on(this.tech_,"sourceset",E=>this.handleTechSourceset_(E)),this.on(this.tech_,"waiting",E=>this.handleTechWaiting_(E)),this.on(this.tech_,"ended",E=>this.handleTechEnded_(E)),this.on(this.tech_,"seeking",E=>this.handleTechSeeking_(E)),this.on(this.tech_,"play",E=>this.handleTechPlay_(E)),this.on(this.tech_,"pause",E=>this.handleTechPause_(E)),this.on(this.tech_,"durationchange",E=>this.handleTechDurationChange_(E)),this.on(this.tech_,"fullscreenchange",(E,C)=>this.handleTechFullscreenChange_(E,C)),this.on(this.tech_,"fullscreenerror",(E,C)=>this.handleTechFullscreenError_(E,C)),this.on(this.tech_,"enterpictureinpicture",E=>this.handleTechEnterPictureInPicture_(E)),this.on(this.tech_,"leavepictureinpicture",E=>this.handleTechLeavePictureInPicture_(E)),this.on(this.tech_,"error",E=>this.handleTechError_(E)),this.on(this.tech_,"posterchange",E=>this.handleTechPosterChange_(E)),this.on(this.tech_,"textdata",E=>this.handleTechTextData_(E)),this.on(this.tech_,"ratechange",E=>this.handleTechRateChange_(E)),this.on(this.tech_,"loadedmetadata",this.boundUpdateStyleEl_),this.usingNativeControls(this.techGet_("controls")),this.controls()&&!this.usingNativeControls()&&this.addTechControlsListeners_(),this.tech_.el().parentNode!==this.el()&&(o!=="Html5"||!this.tag)&&prependTo(this.tech_.el(),this.el()),this.tag&&(this.tag.player=null,this.tag=null)}unloadTech_(){ALL.names.forEach(e=>{const n=ALL[e];this[n.privateName]=this[n.getterName]()}),this.textTracksJson_=textTrackConverter.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&&log$1.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":version$6}}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 n=()=>{const u=this.muted();this.muted(!0);const l=()=>{this.muted(u)};this.playTerminatedQueue_.push(l);const m=this.play();if(isPromise(m))return m.catch(y=>{throw l(),new Error(`Rejection at manualAutoplay. Restoring muted value. ${y||""}`)})};let o;if(e==="any"&&!this.muted()?(o=this.play(),isPromise(o)&&(o=o.catch(n))):e==="muted"&&!this.muted()?o=n():o=this.play(),!!isPromise(o))return o.then(()=>{this.trigger({type:"autoplay-success",autoplay:e})}).catch(()=>{this.trigger({type:"autoplay-failure",autoplay:e})})}updateSourceCaches_(e=""){let n=e,o="";typeof n!="string"&&(n=e.src,o=e.type),this.cache_.source=this.cache_.source||{},this.cache_.sources=this.cache_.sources||[],n&&!o&&(o=findMimetype(this,n)),this.cache_.source=merge$1({},e,{src:n,type:o});const u=this.cache_.sources.filter(E=>E.src&&E.src===n),l=[],m=this.$$("source"),y=[];for(let E=0;E<m.length;E++){const C=getAttributes(m[E]);l.push(C),C.src&&C.src===n&&y.push(C.src)}y.length&&!u.length?this.cache_.sources=l:u.length||(this.cache_.sources=[this.cache_.source]),this.cache_.src=n}handleTechSourceset_(e){if(!this.changingSrc_){let n=l=>this.updateSourceCaches_(l);const o=this.currentSource().src,u=e.src;o&&!/^blob:/.test(o)&&/^blob:/.test(u)&&(!this.lastSource_||this.lastSource_.tech!==u&&this.lastSource_.player!==o)&&(n=()=>{}),n(u),e.src||this.tech_.any(["sourceset","loadstart"],l=>{if(l.type==="sourceset")return;const m=this.techGet_("currentSrc");this.lastSource_.tech=m,this.updateSourceCaches_(m)})}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(),n=()=>{e!==this.currentTime()&&(this.removeClass("vjs-waiting"),this.off("timeupdate",n))};this.on("timeupdate",n)}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()?silencePromise(this.play()):this.pause())}handleTechDoubleClick_(e){if(!this.controls_)return;Array.prototype.some.call(this.$$(".vjs-control-bar, .vjs-modal-dialog"),o=>o.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 n=e.target.player;if(n&&n!==this)return;const o=this.el();let u=document$1$1[this.fsApi_.fullscreenElement]===o;!u&&o.matches&&(u=o.matches(":"+this.fsApi_.fullscreen)),this.isFullscreen(u)}handleTechFullscreenChange_(e,n){n&&(n.nativeIOSFullscreen&&(this.addClass("vjs-ios-native-fs"),this.tech_.one("webkitendfullscreen",()=>{this.removeClass("vjs-ios-native-fs")})),this.isFullscreen(n.isFullscreen))}handleTechFullscreenError_(e,n){this.trigger("fullscreenerror",n)}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,n){this.ready(function(){if(e in allowedSetters)return set(this.middleware_,this.tech_,e,n);if(e in allowedMediators)return mediate(this.middleware_,this.tech_,e,n);try{this.tech_&&this.tech_[e](n)}catch(o){throw log$1(o),o}},!0)}techGet_(e){if(!(!this.tech_||!this.tech_.isReady_)){if(e in allowedGetters)return get(this.middleware_,this.tech_,e);if(e in allowedMediators)return mediate(this.middleware_,this.tech_,e);try{return this.tech_[e]()}catch(n){throw this.tech_[e]===void 0?(log$1(`Video.js: ${e} method not defined for ${this.techName_} playback technology.`,n),n):n.name==="TypeError"?(log$1(`Video.js: ${e} unavailable on ${this.techName_} playback technology element.`,n),this.tech_.isReady_=!1,n):(log$1(n),n)}}}play(){return new Promise(e=>{this.play_(e)})}play_(e=silencePromise){this.playCallbacks_.push(e);const n=!!(!this.changingSrc_&&(this.src()||this.currentSrc())),o=!!(IS_ANY_SAFARI||IS_IOS);if(this.waitToPlay_&&(this.off(["ready","loadstart"],this.waitToPlay_),this.waitToPlay_=null),!this.isReady_||!n){this.waitToPlay_=m=>{this.play_()},this.one(["ready","loadstart"],this.waitToPlay_),!n&&o&&this.load();return}const u=this.techGet_("play");o&&this.hasClass("vjs-ended")&&this.resetProgressBar_(),u===null?this.runPlayTerminatedQueue_():this.runPlayCallbacks_(u)}runPlayTerminatedQueue_(){const e=this.playTerminatedQueue_.slice(0);this.playTerminatedQueue_=[],e.forEach(function(n){n()})}runPlayCallbacks_(e){const n=this.playCallbacks_.slice(0);this.playCallbacks_=[],this.playTerminatedQueue_=[],n.forEach(function(o){o(e)})}pause(){this.techCall_("pause")}paused(){return this.techGet_("paused")!==!1}played(){return this.techGet_("played")||createTimeRanges$1(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=createTimeRanges$1(0,0)),e}seekable(){let e=this.techGet_("seekable");return(!e||!e.length)&&(e=createTimeRanges$1(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 bufferedPercent(this.buffered(),this.duration())}bufferedEnd(){const e=this.buffered(),n=this.duration();let o=e.end(e.length-1);return o>n&&(o=n),o}volume(e){let n;if(e!==void 0){n=Math.max(0,Math.min(1,e)),this.cache_.volume=n,this.techCall_("setVolume",n),n>0&&this.lastVolume_(n);return}return n=parseFloat(this.techGet_("volume")),isNaN(n)?1:n}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 n=this.isFullscreen_;this.isFullscreen_=!!e,this.isFullscreen_!==n&&this.fsApi_.prefixed&&this.trigger("fullscreenchange"),this.toggleFullscreenClass_();return}return this.isFullscreen_}requestFullscreen(e){this.isInPictureInPicture()&&this.exitPictureInPicture();const n=this;return new Promise((o,u)=>{function l(){n.off("fullscreenerror",y),n.off("fullscreenchange",m)}function m(){l(),o()}function y(C,k){l(),u(k)}n.one("fullscreenchange",m),n.one("fullscreenerror",y);const E=n.requestFullscreenHelper_(e);E&&(E.then(l,l),E.then(o,u))})}requestFullscreenHelper_(e){let n;if(this.fsApi_.prefixed||(n=this.options_.fullscreen&&this.options_.fullscreen.options||{},e!==void 0&&(n=e)),this.fsApi_.requestFullscreen){const o=this.el_[this.fsApi_.requestFullscreen](n);return o&&o.then(()=>this.isFullscreen(!0),()=>this.isFullscreen(!1)),o}else this.tech_.supportsFullScreen()&&!this.options_.preferFullWindow?this.techCall_("enterFullScreen"):this.enterFullWindow()}exitFullscreen(){const e=this;return new Promise((n,o)=>{function u(){e.off("fullscreenerror",m),e.off("fullscreenchange",l)}function l(){u(),n()}function m(E,C){u(),o(C)}e.one("fullscreenchange",l),e.one("fullscreenerror",m);const y=e.exitFullscreenHelper_();y&&(y.then(u,u),y.then(n,o))})}exitFullscreenHelper_(){if(this.fsApi_.requestFullscreen){const e=document$1$1[this.fsApi_.exitFullscreen]();return e&&silencePromise(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=document$1$1.documentElement.style.overflow,on(document$1$1,"keydown",this.boundFullWindowOnEscKey_),document$1$1.documentElement.style.overflow="hidden",addClass(document$1$1.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,off(document$1$1,"keydown",this.boundFullWindowOnEscKey_),document$1$1.documentElement.style.overflow=this.docOrigOverflow,removeClass(document$1$1.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&&window$1$1.documentPictureInPicture){const e=document$1$1.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(createEl("p",{className:"vjs-pip-text"},{},this.localize("Playing in picture-in-picture"))),window$1$1.documentPictureInPicture.requestWindow({width:this.videoWidth(),height:this.videoHeight()}).then(n=>(copyStyleSheetsToWindow(n),this.el_.parentNode.insertBefore(e,this.el_),n.document.body.appendChild(this.el_),n.document.body.classList.add("vjs-pip-window"),this.player_.isInPictureInPicture(!0),this.player_.trigger({type:"enterpictureinpicture",pipWindow:n}),n.addEventListener("pagehide",o=>{const u=o.target.querySelector(".video-js");e.parentNode.replaceChild(u,e),this.player_.isInPictureInPicture(!1),this.player_.trigger("leavepictureinpicture")}),n))}return"pictureInPictureEnabled"in document$1$1&&this.disablePictureInPicture()===!1?this.techGet_("requestPictureInPicture"):Promise.reject("No PiP mode is available")}exitPictureInPicture(){if(window$1$1.documentPictureInPicture&&window$1$1.documentPictureInPicture.window)return window$1$1.documentPictureInPicture.window.close(),Promise.resolve();if("pictureInPictureEnabled"in document$1$1)return document$1$1.exitPictureInPicture()}handleKeyDown(e){const{userActions:n}=this.options_;!n||!n.hotkeys||(u=>{const l=u.tagName.toLowerCase();if(u.isContentEditable)return!0;const m=["button","checkbox","hidden","radio","reset","submit"];return l==="input"?m.indexOf(u.type)===-1:["textarea"].indexOf(l)!==-1})(this.el_.ownerDocument.activeElement)||(typeof n.hotkeys=="function"?n.hotkeys.call(this,e):this.handleHotkeys(e))}handleHotkeys(e){const n=this.options_.userActions?this.options_.userActions.hotkeys:{},{fullscreenKey:o=m=>e.key.toLowerCase()==="f",muteKey:u=m=>e.key.toLowerCase()==="m",playPauseKey:l=m=>e.key.toLowerCase()==="k"||e.key.toLowerCase()===" "}=n;if(o.call(this,e)){e.preventDefault(),e.stopPropagation();const m=Component$1.getComponent("FullscreenToggle");document$1$1[this.fsApi_.fullscreenEnabled]!==!1&&m.prototype.handleClick.call(this,e)}else u.call(this,e)?(e.preventDefault(),e.stopPropagation(),Component$1.getComponent("MuteToggle").prototype.handleClick.call(this,e)):l.call(this,e)&&(e.preventDefault(),e.stopPropagation(),Component$1.getComponent("PlayToggle").prototype.handleClick.call(this,e))}canPlayType(e){let n;for(let o=0,u=this.options_.techOrder;o<u.length;o++){const l=u[o];let m=Tech$1.getTech(l);if(m||(m=Component$1.getComponent(l)),!m){log$1.error(`The "${l}" tech is undefined. Skipped browser support check for that tech.`);continue}if(m.isSupported()&&(n=m.canPlayType(e),n))return n}return""}selectSource(e){const n=this.options_.techOrder.map(y=>[y,Tech$1.getTech(y)]).filter(([y,E])=>E?E.isSupported():(log$1.error(`The "${y}" tech is undefined. Skipped browser support check for that tech.`),!1)),o=function(y,E,C){let k;return y.some(A=>E.some(D=>{if(k=C(A,D),k)return!0})),k};let u;const l=y=>(E,C)=>y(C,E),m=([y,E],C)=>{if(E.canPlaySource(C,this.options_[y.toLowerCase()]))return{source:C,tech:y}};return this.options_.sourceOrder?u=o(e,n,l(m)):u=o(n,e,m),u||!1}handleSrc_(e,n){if(typeof e>"u")return this.cache_.src||"";this.resetRetryOnError_&&this.resetRetryOnError_();const o=filterSource(e);if(!o.length){this.setTimeout(function(){this.error({code:4,message:this.options_.notSupportedMessage})},0);return}if(this.changingSrc_=!0,n||(this.cache_.sources=o),this.updateSourceCaches_(o[0]),setSource(this,o[0],(u,l)=>{if(this.middleware_=l,n||(this.cache_.sources=o),this.updateSourceCaches_(u),this.src_(u)){if(o.length>1)return this.handleSrc_(o.slice(1));this.changingSrc_=!1,this.setTimeout(function(){this.error({code:4,message:this.options_.notSupportedMessage})},0),this.triggerReady();return}setTech(l,this.tech_)}),o.length>1){const u=()=>{this.error(null),this.handleSrc_(o.slice(1),!0)},l=()=>{this.off("error",u)};this.one("error",u),this.one("playing",l),this.resetRetryOnError_=()=>{this.off("error",u),this.off("playing",l)}}}src(e){return this.handleSrc_(e,!1)}src_(e){const n=this.selectSource([e]);return n?titleCaseEquals(n.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_(n.tech,n.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();silencePromise(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}),isEvented(this)&&this.trigger("playerreset")}resetControlBarUI_(){this.resetProgressBar_(),this.resetPlaybackRate_(),this.resetVolumeBar_()}resetProgressBar_(){this.currentTime(0);const{currentTimeDisplay:e,durationDisplay:n,progressControl:o,remainingTimeDisplay:u}=this.controlBar||{},{seekBar:l}=o||{};e&&e.updateContent(),n&&n.updateContent(),u&&u.updateContent(),l&&(l.update(),l.loadProgressBar&&l.loadProgressBar.update())}resetPlaybackRate_(){this.playbackRate(this.defaultPlaybackRate()),this.handleTechRateChange_()}resetVolumeBar_(){this.volume(1),this.trigger("volumechange")}currentSources(){const e=this.currentSource(),n=[];return Object.keys(e).length!==0&&n.push(e),this.cache_.sources||n}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 n;typeof e=="string"&&/(any|play|muted)/.test(e)||e===!0&&this.options_.normalizeAutoplay?(this.options_.autoplay=e,this.manualAutoplay_(typeof e=="string"?e:"play"),n=!1):e?this.options_.autoplay=!0:this.options_.autoplay=!1,n=typeof n>"u"?this.options_.autoplay:n,this.tech_&&this.techCall_("setAutoplay",n)}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(hooks("beforeerror").forEach(n=>{const o=n(this,e);if(!(isObject$1(o)&&!Array.isArray(o)||typeof o=="string"||typeof o=="number"||o===null)){this.log.error("please return a value that MediaError expects in beforeerror hooks");return}e=o}),this.options_.suppressNotSupportedError&&e&&e.code===4){const n=function(){this.error(e)};this.options_.suppressNotSupportedError=!1,this.any(["click","touchstart"],n),this.one("loadstart",function(){this.off(["click","touchstart"],n)});return}if(e===null){this.error_=null,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close();return}this.error_=new MediaError(e),this.addClass("vjs-error"),log$1.error(`(CODE:${this.error_.code} ${MediaError.errorTypes[this.error_.code]})`,this.error_.message,this.error_),this.trigger("error"),hooks("error").forEach(n=>n(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(n){n.stopPropagation(),n.preventDefault()}),this.userActivity_=!1,this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive")}}listenForUserActivity_(){let e,n,o;const u=bind_(this,this.reportUserActivity),l=function(A){(A.screenX!==n||A.screenY!==o)&&(n=A.screenX,o=A.screenY,u())},m=function(){u(),this.clearInterval(e),e=this.setInterval(u,250)},y=function(A){u(),this.clearInterval(e)};this.on("mousedown",m),this.on("mousemove",l),this.on("mouseup",y),this.on("mouseleave",y);const E=this.getChild("controlBar");E&&!IS_IOS&&!IS_ANDROID&&(E.on("mouseenter",function(A){this.player().options_.inactivityTimeout!==0&&(this.player().cache_.inactivityTimeout=this.player().options_.inactivityTimeout),this.player().options_.inactivityTimeout=0}),E.on("mouseleave",function(A){this.player().options_.inactivityTimeout=this.player().cache_.inactivityTimeout})),this.on("keydown",u),this.on("keyup",u);let C;const k=function(){if(!this.userActivity_)return;this.userActivity_=!1,this.userActive(!0),this.clearTimeout(C);const A=this.options_.inactivityTimeout;A<=0||(C=this.setTimeout(function(){this.userActivity_||this.userActive(!1)},A))};this.setInterval(k,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(),n=this.getChild("ControlBar"),o=n&&n.currentHeight();e.forEach(u=>{u!==n&&u.el_&&!u.hasClass("vjs-hidden")&&(u.hide(),this.audioOnlyCache_.hiddenChildren.push(u))}),this.audioOnlyCache_.playerHeight=this.currentHeight(),this.audioOnlyCache_.controlBarHeight=o,this.on("playerresize",this.boundUpdatePlayerHeightOnAudioOnlyMode_),this.height(o),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 n=[];return this.isInPictureInPicture()&&n.push(this.exitPictureInPicture()),this.isFullscreen()&&n.push(this.exitFullscreen()),this.audioPosterMode()&&n.push(this.audioPosterMode(!1)),Promise.all(n).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,n,o){if(this.tech_)return this.tech_.addTextTrack(e,n,o)}addRemoteTextTrack(e,n){if(this.tech_)return this.tech_.addRemoteTextTrack(e,n)}removeRemoteTextTrack(e={}){let{track:n}=e;if(n||(n=e),this.tech_)return this.tech_.removeRemoteTextTrack(n)}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(),isEvented(this)&&this.trigger("languagechange"))}languages(){return merge$1(ms.prototype.options_.languages,this.languages_)}toJSON(){const e=merge$1(this.options_),n=e.tracks;e.tracks=[];for(let o=0;o<n.length;o++){let u=n[o];u=merge$1(u),u.player=void 0,e.tracks[o]=u}return e}createModal(e,n){n=n||{},n.content=e||"";const o=new ModalDialog(this,n);return this.addChild(o),o.on("dispose",()=>{this.removeChild(o)}),o.open(),o}updateCurrentBreakpoint_(){if(!this.responsive())return;const e=this.currentBreakpoint(),n=this.currentWidth();for(let o=0;o<BREAKPOINT_ORDER.length;o++){const u=BREAKPOINT_ORDER[o],l=this.breakpoints_[u];if(n<=l){if(e===u)return;e&&this.removeClass(BREAKPOINT_CLASSES[e]),this.addClass(BREAKPOINT_CLASSES[u]),this.breakpoint_=u;break}}}removeCurrentBreakpoint_(){const e=this.currentBreakpointClass();this.breakpoint_="",e&&this.removeClass(e)}breakpoints(e){return e===void 0?Object.assign(this.breakpoints_):(this.breakpoint_="",this.breakpoints_=Object.assign({},DEFAULT_BREAKPOINTS,e),this.updateCurrentBreakpoint_(),Object.assign(this.breakpoints_))}responsive(e){if(e===void 0)return this.responsive_;e=!!e;const n=this.responsive_;if(e!==n)return this.responsive_=e,e?(this.on("playerresize",this.boundUpdateCurrentBreakpoint_),this.updateCurrentBreakpoint_()):(this.off("playerresize",this.boundUpdateCurrentBreakpoint_),this.removeCurrentBreakpoint_()),e}currentBreakpoint(){return this.breakpoint_}currentBreakpointClass(){return BREAKPOINT_CLASSES[this.breakpoint_]||""}loadMedia(e,n){if(!e||typeof e!="object")return;const o=this.crossOrigin();this.reset(),this.cache_.media=merge$1(e);const{artist:u,artwork:l,description:m,poster:y,src:E,textTracks:C,title:k}=this.cache_.media;!l&&y&&(this.cache_.media.artwork=[{src:y,type:getMimetype(y)}]),o&&this.crossOrigin(o),E&&this.src(E),y&&this.poster(y),Array.isArray(C)&&C.forEach(A=>this.addRemoteTextTrack(A,!1)),this.titleBar&&this.titleBar.update({title:k,description:m||u||""}),this.ready(n)}getMedia(){if(!this.cache_.media){const e=this.poster(),n=this.currentSources(),o=Array.prototype.map.call(this.remoteTextTracks(),l=>({kind:l.kind,label:l.label,language:l.language,src:l.src})),u={src:n,textTracks:o};return e&&(u.poster=e,u.artwork=[{src:u.poster,type:getMimetype(u.poster)}]),u}return merge$1(this.cache_.media)}static getTagSettings(e){const n={sources:[],tracks:[]},o=getAttributes(e),u=o["data-setup"];if(hasClass(e,"vjs-fill")&&(o.fill=!0),hasClass(e,"vjs-fluid")&&(o.fluid=!0),u!==null)try{Object.assign(o,JSON.parse(u||"{}"))}catch(l){log$1.error("data-setup",l)}if(Object.assign(n,o),e.hasChildNodes()){const l=e.childNodes;for(let m=0,y=l.length;m<y;m++){const E=l[m],C=E.nodeName.toLowerCase();C==="source"?n.sources.push(getAttributes(E)):C==="track"&&n.tracks.push(getAttributes(E))}}return n}debug(e){if(e===void 0)return this.debugEnabled_;e?(this.trigger("debugon"),this.previousLogLevel_=this.log.level,this.log.level("debug"),this.debugEnabled_=!0):(this.trigger("debugoff"),this.log.level(this.previousLogLevel_),this.previousLogLevel_=void 0,this.debugEnabled_=!1)}playbackRates(e){if(e===void 0)return this.cache_.playbackRates;Array.isArray(e)&&e.every(n=>typeof n=="number")&&(this.cache_.playbackRates=e,this.trigger("playbackrateschange"))}};ALL.names.forEach(function(t){const e=ALL[t];Player$1.prototype[e.getterName]=function(){return this.tech_?this.tech_[e.getterName]():(this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName])}}),Player$1.prototype.crossorigin=Player$1.prototype.crossOrigin,Player$1.players={};const navigator$1=window$1$1.navigator;Player$1.prototype.options_={techOrder:Tech$1.defaultTechOrder_,html5:{},enableSourceset:!0,inactivityTimeout:2e3,playbackRates:[],liveui:!1,children:["mediaLoader","posterImage","titleBar","textTrackDisplay","loadingSpinner","bigPlayButton","liveTracker","controlBar","errorDisplay","textTrackSettings","resizeManager"],language:navigator$1&&(navigator$1.languages&&navigator$1.languages[0]||navigator$1.userLanguage||navigator$1.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},TECH_EVENTS_RETRIGGER.forEach(function(t){Player$1.prototype[`handleTech${toTitleCase$1(t)}_`]=function(){return this.trigger(t)}}),Component$1.registerComponent("Player",Player$1);const BASE_PLUGIN_NAME="plugin",PLUGIN_CACHE_KEY="activePlugins_",pluginStorage={},pluginExists=t=>pluginStorage.hasOwnProperty(t),getPlugin=t=>pluginExists(t)?pluginStorage[t]:void 0,markPluginAsActive=(t,e)=>{t[PLUGIN_CACHE_KEY]=t[PLUGIN_CACHE_KEY]||{},t[PLUGIN_CACHE_KEY][e]=!0},triggerSetupEvent=(t,e,n)=>{const o=(n?"before":"")+"pluginsetup";t.trigger(o,e),t.trigger(o+":"+e.name,e)},createBasicPlugin=function(t,e){const n=function(){triggerSetupEvent(this,{name:t,plugin:e,instance:null},!0);const o=e.apply(this,arguments);return markPluginAsActive(this,t),triggerSetupEvent(this,{name:t,plugin:e,instance:o}),o};return Object.keys(e).forEach(function(o){n[o]=e[o]}),n},createPluginFactory=(t,e)=>(e.prototype.name=t,function(...n){triggerSetupEvent(this,{name:t,plugin:e,instance:null},!0);const o=new e(this,...n);return this[t]=()=>o,triggerSetupEvent(this,o.getEventHash()),o});class Plugin{constructor(e){if(this.constructor===Plugin)throw new Error("Plugin must be sub-classed; not directly instantiated.");this.player=e,this.log||(this.log=this.player.log.createLogger(this.name)),evented(this),delete this.trigger,stateful(this,this.constructor.defaultState),markPluginAsActive(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,n={}){return trigger(this.eventBusEl_,e,this.getEventHash(n))}handleStateChanged(e){}dispose(){const{name:e,player:n}=this;this.trigger("dispose"),this.off(),n.off("dispose",this.dispose),n[PLUGIN_CACHE_KEY][e]=!1,this.player=this.state=null,n[e]=createPluginFactory(e,pluginStorage[e])}static isBasic(e){const n=typeof e=="string"?getPlugin(e):e;return typeof n=="function"&&!Plugin.prototype.isPrototypeOf(n.prototype)}static registerPlugin(e,n){if(typeof e!="string")throw new Error(`Illegal plugin name, "${e}", must be a string, was ${typeof e}.`);if(pluginExists(e))log$1.warn(`A plugin named "${e}" already exists. You may want to avoid re-registering plugins!`);else if(Player$1.prototype.hasOwnProperty(e))throw new Error(`Illegal plugin name, "${e}", cannot share a name with an existing player method!`);if(typeof n!="function")throw new Error(`Illegal plugin for "${e}", must be a function, was ${typeof n}.`);return pluginStorage[e]=n,e!==BASE_PLUGIN_NAME&&(Plugin.isBasic(n)?Player$1.prototype[e]=createBasicPlugin(e,n):Player$1.prototype[e]=createPluginFactory(e,n)),n}static deregisterPlugin(e){if(e===BASE_PLUGIN_NAME)throw new Error("Cannot de-register base plugin.");pluginExists(e)&&(delete pluginStorage[e],delete Player$1.prototype[e])}static getPlugins(e=Object.keys(pluginStorage)){let n;return e.forEach(o=>{const u=getPlugin(o);u&&(n=n||{},n[o]=u)}),n}static getPluginVersion(e){const n=getPlugin(e);return n&&n.VERSION||""}}Plugin.getPlugin=getPlugin,Plugin.BASE_PLUGIN_NAME=BASE_PLUGIN_NAME,Plugin.registerPlugin(BASE_PLUGIN_NAME,Plugin),Player$1.prototype.usingPlugin=function(t){return!!this[PLUGIN_CACHE_KEY]&&this[PLUGIN_CACHE_KEY][t]===!0},Player$1.prototype.hasPlugin=function(t){return!!pluginExists(t)};function deprecate(t,e){let n=!1;return function(...o){return n||log$1.warn(t),n=!0,e.apply(this,o)}}function deprecateForMajor(t,e,n,o){return deprecate(`${e} is deprecated and will be removed in ${t}.0; please use ${n} instead.`,o)}var VjsErrors={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 normalizeId=t=>t.indexOf("#")===0?t.slice(1):t;function videojs(t,e,n){let o=videojs.getPlayer(t);if(o)return e&&log$1.warn(`Player "${t}" is already initialised. Options will not be applied.`),n&&o.ready(n),o;const u=typeof t=="string"?$("#"+normalizeId(t)):t;if(!isEl(u))throw new TypeError("The element or ID supplied is not valid. (videojs)");const m=("getRootNode"in u?u.getRootNode()instanceof window$1$1.ShadowRoot:!1)?u.getRootNode():u.ownerDocument.body;(!u.ownerDocument.defaultView||!m.contains(u))&&log$1.warn("The element supplied is not included in the DOM"),e=e||{},e.restoreEl===!0&&(e.restoreEl=(u.parentNode&&u.parentNode.hasAttribute&&u.parentNode.hasAttribute("data-vjs-player")?u.parentNode:u).cloneNode(!0)),hooks("beforesetup").forEach(E=>{const C=E(u,merge$1(e));if(!isObject$1(C)||Array.isArray(C)){log$1.error("please return an object in beforesetup hooks");return}e=merge$1(e,C)});const y=Component$1.getComponent("Player");return o=new y(u,e,n),hooks("setup").forEach(E=>E(o)),o}if(videojs.hooks_=hooks_,videojs.hooks=hooks,videojs.hook=hook,videojs.hookOnce=hookOnce,videojs.removeHook=removeHook,window$1$1.VIDEOJS_NO_DYNAMIC_STYLE!==!0&&isReal()){let t=$(".vjs-styles-defaults");if(!t){t=createStyleElement("vjs-styles-defaults");const e=$("head");e&&e.insertBefore(t,e.firstChild),setTextContent(t,`
      .video-js {
        width: 300px;
        height: 150px;
      }

      .vjs-fluid:not(.vjs-audio-only-mode) {
        padding-top: 56.25%
      }
    `)}}autoSetupTimeout(1,videojs),videojs.VERSION=version$6,videojs.options=Player$1.prototype.options_,videojs.getPlayers=()=>Player$1.players,videojs.getPlayer=t=>{const e=Player$1.players;let n;if(typeof t=="string"){const o=normalizeId(t),u=e[o];if(u)return u;n=$("#"+o)}else n=t;if(isEl(n)){const{player:o,playerId:u}=n;if(o||e[u])return o||e[u]}},videojs.getAllPlayers=()=>Object.keys(Player$1.players).map(t=>Player$1.players[t]).filter(Boolean),videojs.players=Player$1.players,videojs.getComponent=Component$1.getComponent,videojs.registerComponent=(t,e)=>(Tech$1.isTech(e)&&log$1.warn(`The ${t} tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)`),Component$1.registerComponent.call(Component$1,t,e)),videojs.getTech=Tech$1.getTech,videojs.registerTech=Tech$1.registerTech,videojs.use=use,Object.defineProperty(videojs,"middleware",{value:{},writeable:!1,enumerable:!0}),Object.defineProperty(videojs.middleware,"TERMINATOR",{value:TERMINATOR,writeable:!1,enumerable:!0}),videojs.browser=browser$f,videojs.obj=Obj,videojs.mergeOptions=deprecateForMajor(9,"videojs.mergeOptions","videojs.obj.merge",merge$1),videojs.defineLazyProperty=deprecateForMajor(9,"videojs.defineLazyProperty","videojs.obj.defineLazyProperty",defineLazyProperty),videojs.bind=deprecateForMajor(9,"videojs.bind","native Function.prototype.bind",bind_),videojs.registerPlugin=Plugin.registerPlugin,videojs.deregisterPlugin=Plugin.deregisterPlugin,videojs.plugin=(t,e)=>(log$1.warn("videojs.plugin() is deprecated; use videojs.registerPlugin() instead"),Plugin.registerPlugin(t,e)),videojs.getPlugins=Plugin.getPlugins,videojs.getPlugin=Plugin.getPlugin,videojs.getPluginVersion=Plugin.getPluginVersion,videojs.addLanguage=function(t,e){return t=(""+t).toLowerCase(),videojs.options.languages=merge$1(videojs.options.languages,{[t]:e}),videojs.options.languages[t]},videojs.log=log$1,videojs.createLogger=createLogger,videojs.time=Time$1,videojs.createTimeRange=deprecateForMajor(9,"videojs.createTimeRange","videojs.time.createTimeRanges",createTimeRanges$1),videojs.createTimeRanges=deprecateForMajor(9,"videojs.createTimeRanges","videojs.time.createTimeRanges",createTimeRanges$1),videojs.formatTime=deprecateForMajor(9,"videojs.formatTime","videojs.time.formatTime",formatTime),videojs.setFormatTime=deprecateForMajor(9,"videojs.setFormatTime","videojs.time.setFormatTime",setFormatTime),videojs.resetFormatTime=deprecateForMajor(9,"videojs.resetFormatTime","videojs.time.resetFormatTime",resetFormatTime),videojs.parseUrl=deprecateForMajor(9,"videojs.parseUrl","videojs.url.parseUrl",parseUrl),videojs.isCrossOrigin=deprecateForMajor(9,"videojs.isCrossOrigin","videojs.url.isCrossOrigin",isCrossOrigin),videojs.EventTarget=EventTarget$2,videojs.any=any,videojs.on=on,videojs.one=one,videojs.off=off,videojs.trigger=trigger,videojs.xhr=XHR,videojs.TextTrack=TextTrack,videojs.AudioTrack=AudioTrack,videojs.VideoTrack=VideoTrack,["isEl","isTextNode","createEl","hasClass","addClass","removeClass","toggleClass","setAttributes","getAttributes","emptyEl","appendContent","insertContent"].forEach(t=>{videojs[t]=function(){return log$1.warn(`videojs.${t}() is deprecated; use videojs.dom.${t}() instead`),Dom[t].apply(null,arguments)}}),videojs.computedStyle=deprecateForMajor(9,"videojs.computedStyle","videojs.dom.computedStyle",computedStyle),videojs.dom=Dom,videojs.fn=Fn,videojs.num=Num,videojs.str=Str,videojs.url=Url$1,videojs.Error=VjsErrors;/*! @name videojs-contrib-quality-levels @version 4.1.0 @license Apache-2.0 */class QualityLevel{constructor(e){let n=this;return n.id=e.id,n.label=n.id,n.width=e.width,n.height=e.height,n.bitrate=e.bandwidth,n.frameRate=e.frameRate,n.enabled_=e.enabled,Object.defineProperty(n,"enabled",{get(){return n.enabled_()},set(o){n.enabled_(o)}}),n}}class QualityLevelList extends videojs.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 n=this.getQualityLevelById(e.id);if(n)return n;const o=this.levels_.length;return n=new QualityLevel(e),""+o in this||Object.defineProperty(this,o,{get(){return this.levels_[o]}}),this.levels_.push(n),this.trigger({qualityLevel:n,type:"addqualitylevel"}),n}removeQualityLevel(e){let n=null;for(let o=0,u=this.length;o<u;o++)if(this[o]===e){n=this.levels_.splice(o,1)[0],this.selectedIndex_===o?this.selectedIndex_=-1:this.selectedIndex_>o&&this.selectedIndex_--;break}return n&&this.trigger({qualityLevel:e,type:"removequalitylevel"}),n}getQualityLevelById(e){for(let n=0,o=this.length;n<o;n++){const u=this[n];if(u.id===e)return u}return null}dispose(){this.selectedIndex_=-1,this.levels_.length=0}}QualityLevelList.prototype.allowedEvents_={change:"change",addqualitylevel:"addqualitylevel",removequalitylevel:"removequalitylevel"};for(const t in QualityLevelList.prototype.allowedEvents_)QualityLevelList.prototype["on"+t]=null;var version$5="4.1.0";const initPlugin$1=function(t,e){const n=t.qualityLevels,o=new QualityLevelList,u=function(){o.dispose(),t.qualityLevels=n,t.off("dispose",u)};return t.on("dispose",u),t.qualityLevels=()=>o,t.qualityLevels.VERSION=version$5,o},qualityLevels=function(t){return initPlugin$1(this,videojs.obj.merge({},t))};videojs.registerPlugin("qualityLevels",qualityLevels),qualityLevels.VERSION=version$5;/*! @name @videojs/http-streaming @version 3.14.2 @license Apache-2.0 */const resolveUrl=resolveUrl$1,resolveManifestRedirect=(t,e)=>e&&e.responseURL&&t!==e.responseURL?e.responseURL:t,logger=t=>videojs.log.debug?videojs.log.debug.bind(videojs,"VHS:",`${t} >`):function(){};function merge(...t){const e=videojs.obj||videojs;return(e.merge||e.mergeOptions).apply(e,t)}function createTimeRanges(...t){const e=videojs.time||videojs;return(e.createTimeRanges||e.createTimeRanges).apply(e,t)}function bufferedRangesToString(t){if(t.length===0)return"Buffered Ranges are empty";let e=`Buffered Ranges: 
`;for(let n=0;n<t.length;n++){const o=t.start(n),u=t.end(n);e+=`${o} --> ${u}. Duration (${u-o})
`}return e}const TIME_FUDGE_FACTOR=1/30,SAFE_TIME_DELTA=TIME_FUDGE_FACTOR*3,filterRanges=function(t,e){const n=[];let o;if(t&&t.length)for(o=0;o<t.length;o++)e(t.start(o),t.end(o))&&n.push([t.start(o),t.end(o)]);return createTimeRanges(n)},findRange=function(t,e){return filterRanges(t,function(n,o){return n-SAFE_TIME_DELTA<=e&&o+SAFE_TIME_DELTA>=e})},findNextRange=function(t,e){return filterRanges(t,function(n){return n-TIME_FUDGE_FACTOR>=e})},findGaps=function(t){if(t.length<2)return createTimeRanges();const e=[];for(let n=1;n<t.length;n++){const o=t.end(n-1),u=t.start(n);e.push([o,u])}return createTimeRanges(e)},bufferIntersection=function(t,e){let n=null,o=null,u=0;const l=[],m=[];if(!t||!t.length||!e||!e.length)return createTimeRanges();let y=t.length;for(;y--;)l.push({time:t.start(y),type:"start"}),l.push({time:t.end(y),type:"end"});for(y=e.length;y--;)l.push({time:e.start(y),type:"start"}),l.push({time:e.end(y),type:"end"});for(l.sort(function(E,C){return E.time-C.time}),y=0;y<l.length;y++)l[y].type==="start"?(u++,u===2&&(n=l[y].time)):l[y].type==="end"&&(u--,u===1&&(o=l[y].time)),n!==null&&o!==null&&(m.push([n,o]),n=null,o=null);return createTimeRanges(m)},printableRange=t=>{const e=[];if(!t||!t.length)return"";for(let n=0;n<t.length;n++)e.push(t.start(n)+" => "+t.end(n));return e.join(", ")},timeUntilRebuffer=function(t,e,n=1){return((t.length?t.end(t.length-1):0)-e)/n},timeRangesToArray=t=>{const e=[];for(let n=0;n<t.length;n++)e.push({start:t.start(n),end:t.end(n)});return e},isRangeDifferent=function(t,e){if(t===e)return!1;if(!t&&e||!e&&t||t.length!==e.length)return!0;for(let n=0;n<t.length;n++)if(t.start(n)!==e.start(n)||t.end(n)!==e.end(n))return!0;return!1},lastBufferedEnd=function(t){if(!(!t||!t.length||!t.end))return t.end(t.length-1)},timeAheadOf=function(t,e){let n=0;if(!t||!t.length)return n;for(let o=0;o<t.length;o++){const u=t.start(o),l=t.end(o);if(!(e>l)){if(e>u&&e<=l){n+=l-e;continue}n+=l-u}}return n},segmentDurationWithParts=(t,e)=>{if(!e.preload)return e.duration;let n=0;return(e.parts||[]).forEach(function(o){n+=o.duration}),(e.preloadHints||[]).forEach(function(o){o.type==="PART"&&(n+=t.partTargetDuration)}),n},getPartsAndSegments=t=>(t.segments||[]).reduce((e,n,o)=>(n.parts?n.parts.forEach(function(u,l){e.push({duration:u.duration,segmentIndex:o,partIndex:l,part:u,segment:n})}):e.push({duration:n.duration,segmentIndex:o,partIndex:null,segment:n,part:null}),e),[]),getLastParts=t=>{const e=t.segments&&t.segments.length&&t.segments[t.segments.length-1];return e&&e.parts||[]},getKnownPartCount=({preloadSegment:t})=>{if(!t)return;const{parts:e,preloadHints:n}=t;let o=(n||[]).reduce((u,l)=>u+(l.type==="PART"?1:0),0);return o+=e&&e.length?e.length:0,o},liveEdgeDelay=(t,e)=>{if(e.endList)return 0;if(t&&t.suggestedPresentationDelay)return t.suggestedPresentationDelay;const n=getLastParts(e).length>0;return n&&e.serverControl&&e.serverControl.partHoldBack?e.serverControl.partHoldBack:n&&e.partTargetDuration?e.partTargetDuration*3:e.serverControl&&e.serverControl.holdBack?e.serverControl.holdBack:e.targetDuration?e.targetDuration*3:0},backwardDuration=function(t,e){let n=0,o=e-t.mediaSequence,u=t.segments[o];if(u){if(typeof u.start<"u")return{result:u.start,precise:!0};if(typeof u.end<"u")return{result:u.end-u.duration,precise:!0}}for(;o--;){if(u=t.segments[o],typeof u.end<"u")return{result:n+u.end,precise:!0};if(n+=segmentDurationWithParts(t,u),typeof u.start<"u")return{result:n+u.start,precise:!0}}return{result:n,precise:!1}},forwardDuration=function(t,e){let n=0,o,u=e-t.mediaSequence;for(;u<t.segments.length;u++){if(o=t.segments[u],typeof o.start<"u")return{result:o.start-n,precise:!0};if(n+=segmentDurationWithParts(t,o),typeof o.end<"u")return{result:o.end-n,precise:!0}}return{result:-1,precise:!1}},intervalDuration=function(t,e,n){if(typeof e>"u"&&(e=t.mediaSequence+t.segments.length),e<t.mediaSequence)return 0;const o=backwardDuration(t,e);if(o.precise)return o.result;const u=forwardDuration(t,e);return u.precise?u.result:o.result+n},duration=function(t,e,n){if(!t)return 0;if(typeof n!="number"&&(n=0),typeof e>"u"){if(t.totalDuration)return t.totalDuration;if(!t.endList)return window$1$1.Infinity}return intervalDuration(t,e,n)},sumDurations=function({defaultDuration:t,durationList:e,startIndex:n,endIndex:o}){let u=0;if(n>o&&([n,o]=[o,n]),n<0){for(let l=n;l<Math.min(0,o);l++)u+=t;n=0}for(let l=n;l<o;l++)u+=e[l].duration;return u},playlistEnd=function(t,e,n,o){if(!t||!t.segments)return null;if(t.endList)return duration(t);if(e===null)return null;e=e||0;let u=intervalDuration(t,t.mediaSequence+t.segments.length,e);return n&&(o=typeof o=="number"?o:liveEdgeDelay(null,t),u-=o),Math.max(0,u)},seekable=function(t,e,n){const u=e||0;let l=playlistEnd(t,e,!0,n);return l===null?createTimeRanges():(l<u&&(l=u),createTimeRanges(u,l))},getMediaInfoForTime=function({playlist:t,currentTime:e,startingSegmentIndex:n,startingPartIndex:o,startTime:u,exactManifestTimings:l}){let m=e-u;const y=getPartsAndSegments(t);let E=0;for(let C=0;C<y.length;C++){const k=y[C];if(n===k.segmentIndex&&!(typeof o=="number"&&typeof k.partIndex=="number"&&o!==k.partIndex)){E=C;break}}if(m<0){if(E>0)for(let C=E-1;C>=0;C--){const k=y[C];if(m+=k.duration,l){if(m<0)continue}else if(m+TIME_FUDGE_FACTOR<=0)continue;return{partIndex:k.partIndex,segmentIndex:k.segmentIndex,startTime:u-sumDurations({defaultDuration:t.targetDuration,durationList:y,startIndex:E,endIndex:C})}}return{partIndex:y[0]&&y[0].partIndex||null,segmentIndex:y[0]&&y[0].segmentIndex||0,startTime:e}}if(E<0){for(let C=E;C<0;C++)if(m-=t.targetDuration,m<0)return{partIndex:y[0]&&y[0].partIndex||null,segmentIndex:y[0]&&y[0].segmentIndex||0,startTime:e};E=0}for(let C=E;C<y.length;C++){const k=y[C];m-=k.duration;const A=k.duration>TIME_FUDGE_FACTOR,D=m===0,P=A&&m+TIME_FUDGE_FACTOR>=0;if(!((D||P)&&C!==y.length-1)){if(l){if(m>0)continue}else if(m-TIME_FUDGE_FACTOR>=0)continue;return{partIndex:k.partIndex,segmentIndex:k.segmentIndex,startTime:u+sumDurations({defaultDuration:t.targetDuration,durationList:y,startIndex:E,endIndex:C})}}}return{segmentIndex:y[y.length-1].segmentIndex,partIndex:y[y.length-1].partIndex,startTime:e}},isExcluded=function(t){return t.excludeUntil&&t.excludeUntil>Date.now()},isIncompatible=function(t){return t.excludeUntil&&t.excludeUntil===1/0},isEnabled=function(t){const e=isExcluded(t);return!t.disabled&&!e},isDisabled=function(t){return t.disabled},isAes=function(t){for(let e=0;e<t.segments.length;e++)if(t.segments[e].key)return!0;return!1},hasAttribute=function(t,e){return e.attributes&&e.attributes[t]},estimateSegmentRequestTime=function(t,e,n,o=0){return hasAttribute("BANDWIDTH",n)?(t*n.attributes.BANDWIDTH-o*8)/e:NaN},isLowestEnabledRendition=(t,e)=>{if(t.playlists.length===1)return!0;const n=e.attributes.BANDWIDTH||Number.MAX_VALUE;return t.playlists.filter(o=>isEnabled(o)?(o.attributes.BANDWIDTH||0)<n:!1).length===0},playlistMatch=(t,e)=>!t&&!e||!t&&e||t&&!e?!1:!!(t===e||t.id&&e.id&&t.id===e.id||t.resolvedUri&&e.resolvedUri&&t.resolvedUri===e.resolvedUri||t.uri&&e.uri&&t.uri===e.uri),someAudioVariant=function(t,e){const n=t&&t.mediaGroups&&t.mediaGroups.AUDIO||{};let o=!1;for(const u in n){for(const l in n[u])if(o=e(n[u][l]),o)break;if(o)break}return!!o},isAudioOnly=t=>{if(!t||!t.playlists||!t.playlists.length)return someAudioVariant(t,n=>n.playlists&&n.playlists.length||n.uri);for(let e=0;e<t.playlists.length;e++){const n=t.playlists[e],o=n.attributes&&n.attributes.CODECS;if(!(o&&o.split(",").every(l=>isAudioCodec(l))||someAudioVariant(t,l=>playlistMatch(n,l))))return!1}return!0};var Playlist={liveEdgeDelay,duration,seekable,getMediaInfoForTime,isEnabled,isDisabled,isExcluded,isIncompatible,playlistEnd,isAes,hasAttribute,estimateSegmentRequestTime,isLowestEnabledRendition,isAudioOnly,playlistMatch,segmentDurationWithParts};const{log}=videojs,createPlaylistID=(t,e)=>`${t}-${e}`,groupID=(t,e,n)=>`placeholder-uri-${t}-${e}-${n}`,parseManifest=({onwarn:t,oninfo:e,manifestString:n,customTagParsers:o=[],customTagMappers:u=[],llhls:l})=>{const m=new Parser;t&&m.on("warn",t),e&&m.on("info",e),o.forEach(C=>m.addParser(C)),u.forEach(C=>m.addTagMapper(C)),m.push(n),m.end();const y=m.manifest;if(l||(["preloadSegment","skip","serverControl","renditionReports","partInf","partTargetDuration"].forEach(function(C){y.hasOwnProperty(C)&&delete y[C]}),y.segments&&y.segments.forEach(function(C){["parts","preloadHints"].forEach(function(k){C.hasOwnProperty(k)&&delete C[k]})})),!y.targetDuration){let C=10;y.segments&&y.segments.length&&(C=y.segments.reduce((k,A)=>Math.max(k,A.duration),0)),t&&t({message:`manifest has no targetDuration defaulting to ${C}`}),y.targetDuration=C}const E=getLastParts(y);if(E.length&&!y.partTargetDuration){const C=E.reduce((k,A)=>Math.max(k,A.duration),0);t&&(t({message:`manifest has no partTargetDuration defaulting to ${C}`}),log.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.")),y.partTargetDuration=C}return y},forEachMediaGroup=(t,e)=>{t.mediaGroups&&["AUDIO","SUBTITLES"].forEach(n=>{if(t.mediaGroups[n])for(const o in t.mediaGroups[n])for(const u in t.mediaGroups[n][o]){const l=t.mediaGroups[n][o][u];e(l,n,o,u)}})},setupMediaPlaylist=({playlist:t,uri:e,id:n})=>{t.id=n,t.playlistErrors_=0,e&&(t.uri=e),t.attributes=t.attributes||{}},setupMediaPlaylists=t=>{let e=t.playlists.length;for(;e--;){const n=t.playlists[e];setupMediaPlaylist({playlist:n,id:createPlaylistID(e,n.uri)}),n.resolvedUri=resolveUrl(t.uri,n.uri),t.playlists[n.id]=n,t.playlists[n.uri]=n,n.attributes.BANDWIDTH||log.warn("Invalid playlist STREAM-INF detected. Missing BANDWIDTH attribute.")}},resolveMediaGroupUris=t=>{forEachMediaGroup(t,e=>{e.uri&&(e.resolvedUri=resolveUrl(t.uri,e.uri))})},mainForMedia=(t,e)=>{const n=createPlaylistID(0,e),o={mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:window$1$1.location.href,resolvedUri:window$1$1.location.href,playlists:[{uri:e,id:n,resolvedUri:e,attributes:{}}]};return o.playlists[n]=o.playlists[0],o.playlists[e]=o.playlists[0],o},addPropertiesToMain=(t,e,n=groupID)=>{t.uri=e;for(let u=0;u<t.playlists.length;u++)if(!t.playlists[u].uri){const l=`placeholder-uri-${u}`;t.playlists[u].uri=l}const o=isAudioOnly(t);forEachMediaGroup(t,(u,l,m,y)=>{if(!u.playlists||!u.playlists.length){if(o&&l==="AUDIO"&&!u.uri)for(let E=0;E<t.playlists.length;E++){const C=t.playlists[E];if(C.attributes&&C.attributes.AUDIO&&C.attributes.AUDIO===m)return}u.playlists=[_extends$2({},u)]}u.playlists.forEach(function(E,C){const k=n(l,m,y,E),A=createPlaylistID(C,k);E.uri?E.resolvedUri=E.resolvedUri||resolveUrl(t.uri,E.uri):(E.uri=C===0?k:A,E.resolvedUri=E.uri),E.id=E.id||A,E.attributes=E.attributes||{},t.playlists[E.id]=E,t.playlists[E.uri]=E})}),setupMediaPlaylists(t),resolveMediaGroupUris(t)};class DateRangesStorage{constructor(){this.offset_=null,this.pendingDateRanges_=new Map,this.processedDateRanges_=new Map}setOffset(e=[]){if(this.offset_!==null||!e.length)return;const[n]=e;n.programDateTime!==void 0&&(this.offset_=n.programDateTime/1e3)}setPendingDateRanges(e=[]){if(!e.length)return;const[n]=e,o=n.startDate.getTime();this.trimProcessedDateRanges_(o),this.pendingDateRanges_=e.reduce((u,l)=>(u.set(l.id,l),u),new Map)}processDateRange(e){this.pendingDateRanges_.delete(e.id),this.processedDateRanges_.set(e.id,e)}getDateRangesToProcess(){if(this.offset_===null)return[];const e={},n=[];this.pendingDateRanges_.forEach((o,u)=>{if(!this.processedDateRanges_.has(u)&&(o.startTime=o.startDate.getTime()/1e3-this.offset_,o.processDateRange=()=>this.processDateRange(o),n.push(o),!!o.class))if(e[o.class]){const l=e[o.class].push(o);o.classListIndex=l-1}else e[o.class]=[o],o.classListIndex=0});for(const o of n){const u=e[o.class]||[];o.endDate?o.endTime=o.endDate.getTime()/1e3-this.offset_:o.endOnNext&&u[o.classListIndex+1]?o.endTime=u[o.classListIndex+1].startTime:o.duration?o.endTime=o.startTime+o.duration:o.plannedDuration?o.endTime=o.startTime+o.plannedDuration:o.endTime=o.startTime}return n}trimProcessedDateRanges_(e){new Map(this.processedDateRanges_).forEach((o,u)=>{o.startDate.getTime()<e&&this.processedDateRanges_.delete(u)})}}const QUOTA_EXCEEDED_ERR=22,getStreamingNetworkErrorMetadata=({requestType:t,request:e,error:n,parseFailure:o})=>{const u=e.status<200||e.status>299,l=e.status>=400&&e.status<=499,m={uri:e.uri,requestType:t},y=u&&!l||o;if(n&&l)m.error=_extends$2({},n),m.errorType=videojs.Error.NetworkRequestFailed;else if(e.aborted)m.errorType=videojs.Error.NetworkRequestAborted;else if(e.timedout)m.erroType=videojs.Error.NetworkRequestTimeout;else if(y){const E=o?videojs.Error.NetworkBodyParserFailed:videojs.Error.NetworkBadStatus;m.errorType=E,m.status=e.status,m.headers=e.headers}return m},{EventTarget:EventTarget$1}=videojs,addLLHLSQueryDirectives=(t,e)=>{if(e.endList||!e.serverControl)return t;const n={};if(e.serverControl.canBlockReload){const{preloadSegment:o}=e;let u=e.mediaSequence+e.segments.length;if(o){const l=o.parts||[],m=getKnownPartCount(e)-1;m>-1&&m!==l.length-1&&(n._HLS_part=m),(m>-1||l.length)&&u--}n._HLS_msn=u}if(e.serverControl&&e.serverControl.canSkipUntil&&(n._HLS_skip=e.serverControl.canSkipDateranges?"v2":"YES"),Object.keys(n).length){const o=new window$1$1.URL(t);["_HLS_skip","_HLS_msn","_HLS_part"].forEach(function(u){n.hasOwnProperty(u)&&o.searchParams.set(u,n[u])}),t=o.toString()}return t},updateSegment=(t,e)=>{if(!t)return e;const n=merge(t,e);if(t.preloadHints&&!e.preloadHints&&delete n.preloadHints,t.parts&&!e.parts)delete n.parts;else if(t.parts&&e.parts)for(let o=0;o<e.parts.length;o++)t.parts&&t.parts[o]&&(n.parts[o]=merge(t.parts[o],e.parts[o]));return!t.skipped&&e.skipped&&(n.skipped=!1),t.preload&&!e.preload&&(n.preload=!1),n},updateSegments=(t,e,n)=>{const o=t.slice(),u=e.slice();n=n||0;const l=[];let m;for(let y=0;y<u.length;y++){const E=o[y+n],C=u[y];E?(m=E.map||m,l.push(updateSegment(E,C))):(m&&!C.map&&(C.map=m),l.push(C))}return l},resolveSegmentUris=(t,e)=>{!t.resolvedUri&&t.uri&&(t.resolvedUri=resolveUrl(e,t.uri)),t.key&&!t.key.resolvedUri&&(t.key.resolvedUri=resolveUrl(e,t.key.uri)),t.map&&!t.map.resolvedUri&&(t.map.resolvedUri=resolveUrl(e,t.map.uri)),t.map&&t.map.key&&!t.map.key.resolvedUri&&(t.map.key.resolvedUri=resolveUrl(e,t.map.key.uri)),t.parts&&t.parts.length&&t.parts.forEach(n=>{n.resolvedUri||(n.resolvedUri=resolveUrl(e,n.uri))}),t.preloadHints&&t.preloadHints.length&&t.preloadHints.forEach(n=>{n.resolvedUri||(n.resolvedUri=resolveUrl(e,n.uri))})},getAllSegments=function(t){const e=t.segments||[],n=t.preloadSegment;if(n&&n.parts&&n.parts.length){if(n.preloadHints){for(let o=0;o<n.preloadHints.length;o++)if(n.preloadHints[o].type==="MAP")return e}n.duration=t.targetDuration,n.preload=!0,e.push(n)}return e},isPlaylistUnchanged=(t,e)=>t===e||t.segments&&e.segments&&t.segments.length===e.segments.length&&t.endList===e.endList&&t.mediaSequence===e.mediaSequence&&t.preloadSegment===e.preloadSegment,updateMain$1=(t,e,n=isPlaylistUnchanged)=>{const o=merge(t,{}),u=o.playlists[e.id];if(!u||n(u,e))return null;e.segments=getAllSegments(e);const l=merge(u,e);if(l.preloadSegment&&!e.preloadSegment&&delete l.preloadSegment,u.segments){if(e.skip){e.segments=e.segments||[];for(let m=0;m<e.skip.skippedSegments;m++)e.segments.unshift({skipped:!0})}l.segments=updateSegments(u.segments,e.segments,e.mediaSequence-u.mediaSequence)}l.segments.forEach(m=>{resolveSegmentUris(m,l.resolvedUri)});for(let m=0;m<o.playlists.length;m++)o.playlists[m].id===e.id&&(o.playlists[m]=l);return o.playlists[e.id]=l,o.playlists[e.uri]=l,forEachMediaGroup(t,(m,y,E,C)=>{if(m.playlists)for(let k=0;k<m.playlists.length;k++)e.id===m.playlists[k].id&&(m.playlists[k]=l)}),o},refreshDelay=(t,e)=>{const n=t.segments||[],o=n[n.length-1],u=o&&o.parts&&o.parts[o.parts.length-1],l=u&&u.duration||o&&o.duration;return e&&l?l*1e3:(t.partTargetDuration||t.targetDuration||10)*500},playlistMetadataPayload=(t,e,n)=>{if(!t)return;const o=[];return t.forEach(u=>{if(!u.attributes)return;const{BANDWIDTH:l,RESOLUTION:m,CODECS:y}=u.attributes;o.push({id:u.id,bandwidth:l,resolution:m,codecs:y})}),{type:e,isLive:n,renditions:o}};class PlaylistLoader extends EventTarget$1{constructor(e,n,o={}){if(super(),!e)throw new Error("A non-empty playlist URL or object is required");this.logger_=logger("PlaylistLoader");const{withCredentials:u=!1}=o;this.src=e,this.vhs_=n,this.withCredentials=u,this.addDateRangesToTextTrack_=o.addDateRangesToTextTrack;const l=n.options_;this.customTagParsers=l&&l.customTagParsers||[],this.customTagMappers=l&&l.customTagMappers||[],this.llhls=l&&l.llhls,this.dateRangesStorage_=new DateRangesStorage,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 n=this.dateRangesStorage_.getDateRangesToProcess();!n.length||!this.addDateRangesToTextTrack_||this.addDateRangesToTextTrack_(n)}handleMediaupdatetimeout_(){if(this.state!=="HAVE_METADATA")return;const e=this.media();let n=resolveUrl(this.main.uri,e.uri);this.llhls&&(n=addLLHLSQueryDirectives(n,e)),this.state="HAVE_CURRENT_METADATA",this.request=this.vhs_.xhr({uri:n,withCredentials:this.withCredentials,requestType:"hls-playlist"},(o,u)=>{if(this.request){if(o)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,n,o){const{uri:u,id:l}=n;this.request=null,o&&(this.state=o),this.error={playlist:this.main.playlists[l],status:e.status,message:`HLS playlist request error at URL: ${u}.`,responseText:e.responseText,code:e.status>=500?4:2,metadata:getStreamingNetworkErrorMetadata({requestType:e.requestType,request:e,error:e.error})},this.trigger("error")}parseManifest_({url:e,manifestString:n}){try{return parseManifest({onwarn:({message:o})=>this.logger_(`m3u8-parser warn for ${e}: ${o}`),oninfo:({message:o})=>this.logger_(`m3u8-parser info for ${e}: ${o}`),manifestString:n,customTagParsers:this.customTagParsers,customTagMappers:this.customTagMappers,llhls:this.llhls})}catch(o){this.error=o,this.error.metadata={errorType:videojs.Error.StreamingHlsPlaylistParserError,error:o}}}haveMetadata({playlistString:e,playlistObject:n,url:o,id:u}){this.request=null,this.state="HAVE_METADATA";const l={playlistInfo:{type:"media",uri:o}};this.trigger({type:"playlistparsestart",metadata:l});const m=n||this.parseManifest_({url:o,manifestString:e});m.lastRequest=Date.now(),setupMediaPlaylist({playlist:m,uri:o,id:u});const y=updateMain$1(this.main,m);this.targetDuration=m.partTargetDuration||m.targetDuration,this.pendingMedia_=null,y?(this.main=y,this.media_=this.main.playlists[u]):this.trigger("playlistunchanged"),this.updateMediaUpdateTimeout_(refreshDelay(this.media(),!!y)),l.parsedPlaylist=playlistMetadataPayload(this.main.playlists,l.playlistInfo.type,!this.media_.endList),this.trigger({type:"playlistparsecomplete",metadata:l}),this.trigger("loadedplaylist")}dispose(){this.trigger("dispose"),this.stopRequest(),window$1$1.clearTimeout(this.mediaUpdateTimeout),window$1$1.clearTimeout(this.finalRenditionTimeout),this.dateRangesStorage_=new DateRangesStorage,this.off()}stopRequest(){if(this.request){const e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}}media(e,n){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(window$1$1.clearTimeout(this.finalRenditionTimeout),n){const y=(e.partTargetDuration||e.targetDuration)/2*1e3||5e3;this.finalRenditionTimeout=window$1$1.setTimeout(this.media.bind(this,e,!1),y);return}const o=this.state,u=!this.media_||e.id!==this.media_.id,l=this.main.playlists[e.id];if(l&&l.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,u&&(this.trigger("mediachanging"),o==="HAVE_MAIN_MANIFEST"?this.trigger("loadedmetadata"):this.trigger("mediachange"));return}if(this.updateMediaUpdateTimeout_(refreshDelay(e,!0)),!u)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 m={playlistInfo:{type:"media",uri:e.uri}};this.trigger({type:"playlistrequeststart",metadata:m}),this.request=this.vhs_.xhr({uri:e.resolvedUri,withCredentials:this.withCredentials,requestType:"hls-playlist"},(y,E)=>{if(this.request){if(e.lastRequest=Date.now(),e.resolvedUri=resolveManifestRedirect(e.resolvedUri,E),y)return this.playlistRequestError(this.request,e,o);this.trigger({type:"playlistrequestcomplete",metadata:m}),this.haveMetadata({playlistString:E.responseText,url:e.uri,id:e.id}),o==="HAVE_MAIN_MANIFEST"?this.trigger("loadedmetadata"):this.trigger("mediachange")}})}pause(){this.mediaUpdateTimeout&&(window$1$1.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&&(window$1$1.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null);const n=this.media();if(e){const o=n?(n.partTargetDuration||n.targetDuration)/2*1e3:5e3;this.mediaUpdateTimeout=window$1$1.setTimeout(()=>{this.mediaUpdateTimeout=null,this.load()},o);return}if(!this.started){this.start();return}n&&!n.endList?this.trigger("mediaupdatetimeout"):this.trigger("loadedplaylist")}updateMediaUpdateTimeout_(e){this.mediaUpdateTimeout&&(window$1$1.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),!(!this.media()||this.media().endList)&&(this.mediaUpdateTimeout=window$1$1.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=window$1$1.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"},(n,o)=>{if(!this.request)return;if(this.request=null,n)return this.error={status:o.status,message:`HLS playlist request error at URL: ${this.src}.`,responseText:o.responseText,code:2,metadata:getStreamingNetworkErrorMetadata({requestType:o.requestType,request:o,error:n})},this.state==="HAVE_NOTHING"&&(this.started=!1),this.trigger("error");this.trigger({type:"playlistrequestcomplete",metadata:e}),this.src=resolveManifestRedirect(this.src,o),this.trigger({type:"playlistparsestart",metadata:e});const u=this.parseManifest_({manifestString:o.responseText,url:this.src});e.parsedPlaylist=playlistMetadataPayload(u.playlists,e.playlistInfo.type,!1),this.trigger({type:"playlistparsecomplete",metadata:e}),this.setupInitialPlaylist(u)})}srcUri(){return typeof this.src=="string"?this.src:this.src.uri}setupInitialPlaylist(e){if(this.state="HAVE_MAIN_MANIFEST",e.playlists){this.main=e,addPropertiesToMain(this.main,this.srcUri()),e.playlists.forEach(o=>{o.segments=getAllSegments(o),o.segments.forEach(u=>{resolveSegmentUris(u,o.resolvedUri)})}),this.trigger("loadedplaylist"),this.request||this.media(this.main.playlists[0]);return}const n=this.srcUri()||window$1$1.location.href;this.main=mainForMedia(e,n),this.haveMetadata({playlistObject:e,url:n,id:this.main.playlists[0].id}),this.trigger("loadedmetadata")}updateOrDeleteClone(e,n){const o=this.main,u=e.ID;let l=o.playlists.length;for(;l--;){const m=o.playlists[l];if(m.attributes["PATHWAY-ID"]===u){const y=m.resolvedUri,E=m.id;if(n){const C=this.createCloneURI_(m.resolvedUri,e),k=createPlaylistID(u,C),A=this.createCloneAttributes_(u,m.attributes),D=this.createClonePlaylist_(m,k,e,A);o.playlists[l]=D,o.playlists[k]=D,o.playlists[C]=D}else o.playlists.splice(l,1);delete o.playlists[E],delete o.playlists[y]}}this.updateOrDeleteCloneMedia(e,n)}updateOrDeleteCloneMedia(e,n){const o=this.main,u=e.ID;["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(l=>{if(!(!o.mediaGroups[l]||!o.mediaGroups[l][u])){for(const m in o.mediaGroups[l])if(m===u){for(const y in o.mediaGroups[l][m])o.mediaGroups[l][m][y].playlists.forEach((C,k)=>{const A=o.playlists[C.id],D=A.id,P=A.resolvedUri;delete o.playlists[D],delete o.playlists[P]});delete o.mediaGroups[l][m]}}}),n&&this.createClonedMediaGroups_(e)}addClonePathway(e,n={}){const o=this.main,u=o.playlists.length,l=this.createCloneURI_(n.resolvedUri,e),m=createPlaylistID(e.ID,l),y=this.createCloneAttributes_(e.ID,n.attributes),E=this.createClonePlaylist_(n,m,e,y);o.playlists[u]=E,o.playlists[m]=E,o.playlists[l]=E,this.createClonedMediaGroups_(e)}createClonedMediaGroups_(e){const n=e.ID,o=e["BASE-ID"],u=this.main;["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(l=>{if(!(!u.mediaGroups[l]||u.mediaGroups[l][n]))for(const m in u.mediaGroups[l]){if(m===o)u.mediaGroups[l][n]={};else continue;for(const y in u.mediaGroups[l][m]){const E=u.mediaGroups[l][m][y];u.mediaGroups[l][n][y]=_extends$2({},E);const C=u.mediaGroups[l][n][y],k=this.createCloneURI_(E.resolvedUri,e);C.resolvedUri=k,C.uri=k,C.playlists=[],E.playlists.forEach((A,D)=>{const P=u.playlists[A.id],R=groupID(l,n,y),B=createPlaylistID(n,R);if(P&&!u.playlists[B]){const F=this.createClonePlaylist_(P,B,e),j=F.resolvedUri;u.playlists[B]=F,u.playlists[j]=F}C.playlists[D]=this.createClonePlaylist_(A,B,e)})}}})}createClonePlaylist_(e,n,o,u){const l=this.createCloneURI_(e.resolvedUri,o),m={resolvedUri:l,uri:l,id:n};return e.segments&&(m.segments=[]),u&&(m.attributes=u),merge(e,m)}createCloneURI_(e,n){const o=new URL(e);o.hostname=n["URI-REPLACEMENT"].HOST;const u=n["URI-REPLACEMENT"].PARAMS;for(const l of Object.keys(u))o.searchParams.set(l,u[l]);return o.href}createCloneAttributes_(e,n){const o={"PATHWAY-ID":e};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(u=>{n[u]&&(o[u]=e)}),o}getKeyIdSet(e){if(e.contentProtection){const n=new Set;for(const o in e.contentProtection){const u=e.contentProtection[o].attributes.keyId;u&&n.add(u.toLowerCase())}return n}}}const callbackWrapper=function(t,e,n,o){const u=t.responseType==="arraybuffer"?t.response:t.responseText;!e&&u&&(t.responseTime=Date.now(),t.roundTripTime=t.responseTime-t.requestTime,t.bytesReceived=u.byteLength||u.length,t.bandwidth||(t.bandwidth=Math.floor(t.bytesReceived/t.roundTripTime*8*1e3))),n.headers&&(t.responseHeaders=n.headers),e&&e.code==="ETIMEDOUT"&&(t.timedout=!0),!e&&!t.aborted&&n.statusCode!==200&&n.statusCode!==206&&n.statusCode!==0&&(e=new Error("XHR Failed with a response of: "+(t&&(u||t.responseText)))),o(e,t)},callAllRequestHooks=(t,e)=>{if(!t||!t.size)return;let n=e;return t.forEach(o=>{n=o(n)}),n},callAllResponseHooks=(t,e,n,o)=>{!t||!t.size||t.forEach(u=>{u(e,n,o)})},xhrFactory=function(){const t=function e(n,o){n=merge({timeout:45e3},n);const u=e.beforeRequest||videojs.Vhs.xhr.beforeRequest,l=e._requestCallbackSet||videojs.Vhs.xhr._requestCallbackSet||new Set,m=e._responseCallbackSet||videojs.Vhs.xhr._responseCallbackSet;u&&typeof u=="function"&&(videojs.log.warn("beforeRequest is deprecated, use onRequest instead."),l.add(u));const y=videojs.Vhs.xhr.original===!0?videojs.xhr:videojs.Vhs.xhr,E=callAllRequestHooks(l,n);l.delete(u);const C=y(E||n,function(A,D){return callAllResponseHooks(m,C,A,D),callbackWrapper(C,A,D,o)}),k=C.abort;return C.abort=function(){return C.aborted=!0,k.apply(C,arguments)},C.uri=n.uri,C.requestType=n.requestType,C.requestTime=Date.now(),C};return t.original=!0,t},byterangeStr=function(t){let e;const n=t.offset;return typeof t.offset=="bigint"||typeof t.length=="bigint"?e=window$1$1.BigInt(t.offset)+window$1$1.BigInt(t.length)-window$1$1.BigInt(1):e=t.offset+t.length-1,"bytes="+n+"-"+e},segmentXhrHeaders=function(t){const e={};return t.byterange&&(e.Range=byterangeStr(t.byterange)),e},textRange=function(t,e){return t.start(e)+"-"+t.end(e)},formatHexString=function(t,e){const n=t.toString(16);return"00".substring(0,2-n.length)+n+(e%2?" ":"")},formatAsciiString=function(t){return t>=32&&t<126?String.fromCharCode(t):"."},createTransferableMessage=function(t){const e={};return Object.keys(t).forEach(n=>{const o=t[n];isArrayBufferView(o)?e[n]={bytes:o.buffer,byteOffset:o.byteOffset,byteLength:o.byteLength}:e[n]=o}),e},initSegmentId=function(t){const e=t.byterange||{length:1/0,offset:0};return[e.length,e.offset,t.resolvedUri].join(",")},segmentKeyId=function(t){return t.resolvedUri},hexDump=t=>{const e=Array.prototype.slice.call(t),n=16;let o="",u,l;for(let m=0;m<e.length/n;m++)u=e.slice(m*n,m*n+n).map(formatHexString).join(""),l=e.slice(m*n,m*n+n).map(formatAsciiString).join(""),o+=u+" "+l+`
`;return o},tagDump=({bytes:t})=>hexDump(t),textRanges=t=>{let e="",n;for(n=0;n<t.length;n++)e+=textRange(t,n)+" ";return e};var utils$r=Object.freeze({__proto__:null,createTransferableMessage,initSegmentId,segmentKeyId,hexDump,tagDump,textRanges});const SEGMENT_END_FUDGE_PERCENT=.25,playerTimeToProgramTime=(t,e)=>{if(!e.dateTimeObject)return null;const n=e.videoTimingInfo.transmuxerPrependedSeconds,u=e.videoTimingInfo.transmuxedPresentationStart+n,l=t-u;return new Date(e.dateTimeObject.getTime()+l*1e3)},originalSegmentVideoDuration=t=>t.transmuxedPresentationEnd-t.transmuxedPresentationStart-t.transmuxerPrependedSeconds,findSegmentForProgramTime=(t,e)=>{let n;try{n=new Date(t)}catch{return null}if(!e||!e.segments||e.segments.length===0)return null;let o=e.segments[0];if(n<new Date(o.dateTimeObject))return null;for(let E=0;E<e.segments.length-1;E++){o=e.segments[E];const C=new Date(e.segments[E+1].dateTimeObject);if(n<C)break}const u=e.segments[e.segments.length-1],l=u.dateTimeObject,m=u.videoTimingInfo?originalSegmentVideoDuration(u.videoTimingInfo):u.duration+u.duration*SEGMENT_END_FUDGE_PERCENT,y=new Date(l.getTime()+m*1e3);return n>y?null:(n>new Date(l)&&(o=u),{segment:o,estimatedStart:o.videoTimingInfo?o.videoTimingInfo.transmuxedPresentationStart:Playlist.duration(e,e.mediaSequence+e.segments.indexOf(o)),type:o.videoTimingInfo?"accurate":"estimate"})},findSegmentForPlayerTime=(t,e)=>{if(!e||!e.segments||e.segments.length===0)return null;let n=0,o;for(let l=0;l<e.segments.length&&(o=e.segments[l],n=o.videoTimingInfo?o.videoTimingInfo.transmuxedPresentationEnd:n+o.duration,!(t<=n));l++);const u=e.segments[e.segments.length-1];if(u.videoTimingInfo&&u.videoTimingInfo.transmuxedPresentationEnd<t)return null;if(t>n){if(t>n+u.duration*SEGMENT_END_FUDGE_PERCENT)return null;o=u}return{segment:o,estimatedStart:o.videoTimingInfo?o.videoTimingInfo.transmuxedPresentationStart:n-o.duration,type:o.videoTimingInfo?"accurate":"estimate"}},getOffsetFromTimestamp=(t,e)=>{let n,o;try{n=new Date(t),o=new Date(e)}catch{}const u=n.getTime();return(o.getTime()-u)/1e3},verifyProgramDateTimeTags=t=>{if(!t.segments||t.segments.length===0)return!1;for(let e=0;e<t.segments.length;e++)if(!t.segments[e].dateTimeObject)return!1;return!0},getProgramTime=({playlist:t,time:e=void 0,callback:n})=>{if(!n)throw new Error("getProgramTime: callback must be provided");if(!t||e===void 0)return n({message:"getProgramTime: playlist and time must be provided"});const o=findSegmentForPlayerTime(e,t);if(!o)return n({message:"valid programTime was not found"});if(o.type==="estimate")return n({message:"Accurate programTime could not be determined. Please seek to e.seekTime and try again",seekTime:o.estimatedStart});const u={mediaSeconds:e},l=playerTimeToProgramTime(e,o.segment);return l&&(u.programDateTime=l.toISOString()),n(null,u)},seekToProgramTime=({programTime:t,playlist:e,retryCount:n=2,seekTo:o,pauseAfterSeek:u=!0,tech:l,callback:m})=>{if(!m)throw new Error("seekToProgramTime: callback must be provided");if(typeof t>"u"||!e||!o)return m({message:"seekToProgramTime: programTime, seekTo and playlist must be provided"});if(!e.endList&&!l.hasStarted_)return m({message:"player must be playing a live stream to start buffering"});if(!verifyProgramDateTimeTags(e))return m({message:"programDateTime tags must be provided in the manifest "+e.resolvedUri});const y=findSegmentForProgramTime(t,e);if(!y)return m({message:`${t} was not found in the stream`});const E=y.segment,C=getOffsetFromTimestamp(E.dateTimeObject,t);if(y.type==="estimate"){if(n===0)return m({message:`${t} is not buffered yet. Try again`});o(y.estimatedStart+C),l.one("seeked",()=>{seekToProgramTime({programTime:t,playlist:e,retryCount:n-1,seekTo:o,pauseAfterSeek:u,tech:l,callback:m})});return}const k=E.start+C,A=()=>m(null,l.currentTime());l.one("seeked",A),u&&l.pause(),o(k)},callbackOnCompleted=(t,e)=>{if(t.readyState===4)return e()},containerRequest=(t,e,n,o)=>{let u=[],l,m=!1;const y=function(A,D,P,R){return D.abort(),m=!0,n(A,D,P,R)},E=function(A,D){if(m)return;if(A)return A.metadata=getStreamingNetworkErrorMetadata({requestType:o,request:D,error:A}),y(A,D,"",u);const P=D.responseText.substring(u&&u.byteLength||0,D.responseText.length);if(u=concatTypedArrays(u,stringToBytes(P,!0)),l=l||getId3Offset(u),u.length<10||l&&u.length<l+2)return callbackOnCompleted(D,()=>y(A,D,"",u));const R=detectContainerForBytes(u);return R==="ts"&&u.length<188?callbackOnCompleted(D,()=>y(A,D,"",u)):!R&&u.length<376?callbackOnCompleted(D,()=>y(A,D,"",u)):y(null,D,R,u)},k=e({uri:t,beforeSend(A){A.overrideMimeType("text/plain; charset=x-user-defined"),A.addEventListener("progress",function({total:D,loaded:P}){return callbackWrapper(A,null,{statusCode:A.status},E)})}},function(A,D){return callbackWrapper(k,A,D,E)});return k},{EventTarget:EventTarget$3}=videojs,dashPlaylistUnchanged=function(t,e){if(!isPlaylistUnchanged(t,e)||t.sidx&&e.sidx&&(t.sidx.offset!==e.sidx.offset||t.sidx.length!==e.sidx.length))return!1;if(!t.sidx&&e.sidx||t.sidx&&!e.sidx||t.segments&&!e.segments||!t.segments&&e.segments)return!1;if(!t.segments&&!e.segments)return!0;for(let n=0;n<t.segments.length;n++){const o=t.segments[n],u=e.segments[n];if(o.uri!==u.uri)return!1;if(!o.byterange&&!u.byterange)continue;const l=o.byterange,m=u.byterange;if(l&&!m||!l&&m||l.offset!==m.offset||l.length!==m.length)return!1}return!0},dashGroupId=(t,e,n,o)=>{const u=o.attributes.NAME||n;return`placeholder-uri-${t}-${e}-${u}`},parseMainXml=({mainXml:t,srcUrl:e,clientOffset:n,sidxMapping:o,previousManifest:u})=>{const l=parse$4(t,{manifestUri:e,clientOffset:n,sidxMapping:o,previousManifest:u});return addPropertiesToMain(l,e,dashGroupId),l},removeOldMediaGroupLabels=(t,e)=>{forEachMediaGroup(t,(n,o,u,l)=>{(!e.mediaGroups[o][u]||!(l in e.mediaGroups[o][u]))&&delete t.mediaGroups[o][u][l]})},updateMain=(t,e,n)=>{let o=!0,u=merge(t,{duration:e.duration,minimumUpdatePeriod:e.minimumUpdatePeriod,timelineStarts:e.timelineStarts});for(let l=0;l<e.playlists.length;l++){const m=e.playlists[l];if(m.sidx){const E=generateSidxKey(m.sidx);n&&n[E]&&n[E].sidx&&addSidxSegmentsToPlaylist$1(m,n[E].sidx,m.sidx.resolvedUri)}const y=updateMain$1(u,m,dashPlaylistUnchanged);y&&(u=y,o=!1)}return forEachMediaGroup(e,(l,m,y,E)=>{if(l.playlists&&l.playlists.length){const C=l.playlists[0].id,k=updateMain$1(u,l.playlists[0],dashPlaylistUnchanged);k&&(u=k,E in u.mediaGroups[m][y]||(u.mediaGroups[m][y][E]=l),u.mediaGroups[m][y][E].playlists[0]=u.playlists[C],o=!1)}}),removeOldMediaGroupLabels(u,e),e.minimumUpdatePeriod!==t.minimumUpdatePeriod&&(o=!1),o?null:u},equivalentSidx=(t,e)=>(!t.map&&!e.map||!!(t.map&&e.map&&t.map.byterange.offset===e.map.byterange.offset&&t.map.byterange.length===e.map.byterange.length))&&t.uri===e.uri&&t.byterange.offset===e.byterange.offset&&t.byterange.length===e.byterange.length,compareSidxEntry=(t,e)=>{const n={};for(const o in t){const l=t[o].sidx;if(l){const m=generateSidxKey(l);if(!e[m])break;const y=e[m].sidxInfo;equivalentSidx(y,l)&&(n[m]=e[m])}}return n},filterChangedSidxMappings=(t,e)=>{let o=compareSidxEntry(t.playlists,e);return forEachMediaGroup(t,(u,l,m,y)=>{if(u.playlists&&u.playlists.length){const E=u.playlists;o=merge(o,compareSidxEntry(E,e))}}),o};class DashPlaylistLoader extends EventTarget$3{constructor(e,n,o={},u){super(),this.mainPlaylistLoader_=u||this,u||(this.isMain_=!0);const{withCredentials:l=!1}=o;if(this.vhs_=n,this.withCredentials=l,this.addMetadataToTextTrack=o.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_=logger("DashPlaylistLoader"),this.isMain_?(this.mainPlaylistLoader_.srcUrl=e,this.mainPlaylistLoader_.sidxMapping_={}):this.childPlaylist_=e}requestErrored_(e,n,o){if(!this.request)return!0;if(this.request=null,e)return this.error=typeof e=="object"&&!(e instanceof Error)?e:{status:n.status,message:"DASH request error at URL: "+n.uri,response:n.response,code:2,metadata:e.metadata},o&&(this.state=o),this.trigger("error"),!0}addSidxSegments_(e,n,o){const u=e.sidx&&generateSidxKey(e.sidx);if(!e.sidx||!u||this.mainPlaylistLoader_.sidxMapping_[u]){this.mediaRequest_=window$1$1.setTimeout(()=>o(!1),0);return}const l=resolveManifestRedirect(e.sidx.resolvedUri),m=(E,C)=>{if(this.requestErrored_(E,C,n))return;const k=this.mainPlaylistLoader_.sidxMapping_,{requestType:A}=C;let D;try{D=parseSidx$1(toUint8(C.response).subarray(8))}catch(P){P.metadata=getStreamingNetworkErrorMetadata({requestType:A,request:C,parseFailure:!0}),this.requestErrored_(P,C,n);return}return k[u]={sidxInfo:e.sidx,sidx:D},addSidxSegmentsToPlaylist$1(e,D,e.sidx.resolvedUri),o(!0)},y="dash-sidx";this.request=containerRequest(l,this.vhs_.xhr,(E,C,k,A)=>{if(E)return m(E,C);if(!k||k!=="mp4"){const R=k||"unknown";return m({status:C.status,message:`Unsupported ${R} container type for sidx segment at URL: ${l}`,response:"",playlist:e,internal:!0,playlistExclusionDuration:1/0,code:2},C)}const{offset:D,length:P}=e.sidx.byterange;if(A.length>=P+D)return m(E,{response:A.subarray(D,D+P),status:C.status,uri:C.uri});this.request=this.vhs_.xhr({uri:l,responseType:"arraybuffer",requestType:"dash-sidx",headers:segmentXhrHeaders({byterange:e.sidx.byterange})},m)},y)}dispose(){this.trigger("dispose"),this.stopRequest(),this.loadedPlaylists_={},window$1$1.clearTimeout(this.minimumUpdatePeriodTimeout_),window$1$1.clearTimeout(this.mediaRequest_),window$1$1.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 n=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 o=!this.media_||e.id!==this.media_.id;if(o&&this.loadedPlaylists_[e.id]&&this.loadedPlaylists_[e.id].endList){this.state="HAVE_METADATA",this.media_=e,o&&(this.trigger("mediachanging"),this.trigger("mediachange"));return}o&&(this.media_&&this.trigger("mediachanging"),this.addSidxSegments_(e,n,u=>{this.haveMetadata({startingState:n,playlist:e})}))}haveMetadata({startingState:e,playlist:n}){this.state="HAVE_METADATA",this.loadedPlaylists_[n.id]=n,this.mediaRequest_=null,this.refreshMedia_(n.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(),window$1$1.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.isMain_&&(window$1$1.clearTimeout(this.mainPlaylistLoader_.minimumUpdatePeriodTimeout_),this.mainPlaylistLoader_.minimumUpdatePeriodTimeout_=null),this.state==="HAVE_NOTHING"&&(this.started=!1)}load(e){window$1$1.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null;const n=this.media();if(e){const o=n?n.targetDuration/2*1e3:5e3;this.mediaUpdateTimeout=window$1$1.setTimeout(()=>this.load(),o);return}if(!this.started){this.start();return}n&&!n.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_=window$1$1.setTimeout(()=>this.haveMain_(),0);return}this.requestMain_((e,n)=>{this.haveMain_(),!this.hasPendingRequest()&&!this.media_&&this.media(this.mainPlaylistLoader_.main.playlists[0])})}requestMain_(e){const n={manifestInfo:{uri:this.mainPlaylistLoader_.srcUrl}};this.trigger({type:"manifestrequeststart",metadata:n}),this.request=this.vhs_.xhr({uri:this.mainPlaylistLoader_.srcUrl,withCredentials:this.withCredentials,requestType:"dash-manifest"},(o,u)=>{if(o){const{requestType:m}=u;o.metadata=getStreamingNetworkErrorMetadata({requestType:m,request:u,error:o})}if(this.requestErrored_(o,u)){this.state==="HAVE_NOTHING"&&(this.started=!1);return}this.trigger({type:"manifestrequestcomplete",metadata:n});const l=u.responseText!==this.mainPlaylistLoader_.mainXml_;if(this.mainPlaylistLoader_.mainXml_=u.responseText,u.responseHeaders&&u.responseHeaders.date?this.mainLoaded_=Date.parse(u.responseHeaders.date):this.mainLoaded_=Date.now(),this.mainPlaylistLoader_.srcUrl=resolveManifestRedirect(this.mainPlaylistLoader_.srcUrl,u),l){this.handleMain_(),this.syncClientServerClock_(()=>e(u,l));return}return e(u,l)})}syncClientServerClock_(e){const n=parseUTCTiming(this.mainPlaylistLoader_.mainXml_);if(n===null)return this.mainPlaylistLoader_.clientOffset_=this.mainLoaded_-Date.now(),e();if(n.method==="DIRECT")return this.mainPlaylistLoader_.clientOffset_=n.value-Date.now(),e();this.request=this.vhs_.xhr({uri:resolveUrl(this.mainPlaylistLoader_.srcUrl,n.value),method:n.method,withCredentials:this.withCredentials,requestType:"dash-clock-sync"},(o,u)=>{if(!this.request)return;if(o){const{requestType:m}=u;return this.error.metadata=getStreamingNetworkErrorMetadata({requestType:m,request:u,error:o}),this.mainPlaylistLoader_.clientOffset_=this.mainLoaded_-Date.now(),e()}let l;n.method==="HEAD"?!u.responseHeaders||!u.responseHeaders.date?l=this.mainLoaded_:l=Date.parse(u.responseHeaders.date):l=Date.parse(u.responseText),this.mainPlaylistLoader_.clientOffset_=l-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,n={manifestInfo:{uri:this.mainPlaylistLoader_.srcUrl}};this.trigger({type:"manifestparsestart",metadata:n});let o;try{o=parseMainXml({mainXml:this.mainPlaylistLoader_.mainXml_,srcUrl:this.mainPlaylistLoader_.srcUrl,clientOffset:this.mainPlaylistLoader_.clientOffset_,sidxMapping:this.mainPlaylistLoader_.sidxMapping_,previousManifest:e})}catch(l){this.error=l,this.error.metadata={errorType:videojs.Error.StreamingDashManifestParserError,error:l},this.trigger("error")}e&&(o=updateMain(e,o,this.mainPlaylistLoader_.sidxMapping_)),this.mainPlaylistLoader_.main=o||e;const u=this.mainPlaylistLoader_.main.locations&&this.mainPlaylistLoader_.main.locations[0];if(u&&u!==this.mainPlaylistLoader_.srcUrl&&(this.mainPlaylistLoader_.srcUrl=u),(!e||o&&o.minimumUpdatePeriod!==e.minimumUpdatePeriod)&&this.updateMinimumUpdatePeriodTimeout_(),this.addEventStreamToMetadataTrack_(o),o){const{duration:l,endList:m}=o,y=[];o.playlists.forEach(C=>{y.push({id:C.id,bandwidth:C.attributes.BANDWIDTH,resolution:C.attributes.RESOLUTION,codecs:C.attributes.CODECS})});const E={duration:l,isLive:!m,renditions:y};n.parsedManifest=E,this.trigger({type:"manifestparsecomplete",metadata:n})}return!!o}updateMinimumUpdatePeriodTimeout_(){const e=this.mainPlaylistLoader_;e.createMupOnMedia_&&(e.off("loadedmetadata",e.createMupOnMedia_),e.createMupOnMedia_=null),e.minimumUpdatePeriodTimeout_&&(window$1$1.clearTimeout(e.minimumUpdatePeriodTimeout_),e.minimumUpdatePeriodTimeout_=null);let n=e.main&&e.main.minimumUpdatePeriod;if(n===0&&(e.media()?n=e.media().targetDuration*1e3:(e.createMupOnMedia_=e.updateMinimumUpdatePeriodTimeout_,e.one("loadedmetadata",e.createMupOnMedia_))),typeof n!="number"||n<=0){n<0&&this.logger_(`found invalid minimumUpdatePeriod of ${n}, not setting a timeout`);return}this.createMUPTimeout_(n)}createMUPTimeout_(e){const n=this.mainPlaylistLoader_;n.minimumUpdatePeriodTimeout_=window$1$1.setTimeout(()=>{n.minimumUpdatePeriodTimeout_=null,n.trigger("minimumUpdatePeriod"),n.createMUPTimeout_(e)},e)}refreshXml_(){this.requestMain_((e,n)=>{n&&(this.media_&&(this.media_=this.mainPlaylistLoader_.main.playlists[this.media_.id]),this.mainPlaylistLoader_.sidxMapping_=filterChangedSidxMappings(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.sidxMapping_),this.addSidxSegments_(this.media(),this.state,o=>{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 n=this.mainPlaylistLoader_.main.playlists,o=!this.media_||this.media_!==n[e];if(o?this.media_=n[e]:this.trigger("playlistunchanged"),!this.mediaUpdateTimeout){const u=()=>{this.media().endList||(this.mediaUpdateTimeout=window$1$1.setTimeout(()=>{this.trigger("mediaupdatetimeout"),u()},refreshDelay(this.media(),!!o)))};u()}this.trigger("loadedplaylist")}addEventStreamToMetadataTrack_(e){if(e&&this.mainPlaylistLoader_.main.eventStream){const n=this.mainPlaylistLoader_.main.eventStream.map(o=>({cueTime:o.start,frames:[{data:o.messageData}]}));this.addMetadataToTextTrack("EventStream",n,this.mainPlaylistLoader_.main.duration)}}getKeyIdSet(e){if(e.contentProtection){const n=new Set;for(const o in e.contentProtection){const u=e.contentProtection[o].attributes["cenc:default_KID"];u&&n.add(u.replace(/-/g,"").toLowerCase())}return n}}}var Config={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 stringToArrayBuffer=t=>{const e=new Uint8Array(new ArrayBuffer(t.length));for(let n=0;n<t.length;n++)e[n]=t.charCodeAt(n);return e.buffer},browserWorkerPolyFill=function(t){return t.on=t.addEventListener,t.off=t.removeEventListener,t},createObjectURL=function(t){try{return URL.createObjectURL(new Blob([t],{type:"application/javascript"}))}catch{const n=new BlobBuilder;return n.append(t),URL.createObjectURL(n.getBlob())}},factory=function(t){return function(){const e=createObjectURL(t),n=browserWorkerPolyFill(new Worker(e));n.objURL=e;const o=n.terminate;return n.on=n.addEventListener,n.off=n.removeEventListener,n.terminate=function(){return URL.revokeObjectURL(e),o.call(this)},n}},transform=function(t){return`var browserWorkerPolyFill = ${browserWorkerPolyFill.toString()};
browserWorkerPolyFill(self);
`+t},getWorkerString=function(t){return t.toString().replace(/^function.+?{/,"").slice(0,-1)},workerCode$1=transform(getWorkerString(function(){var t=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global$1<"u"?global$1:typeof self<"u"?self:{},e=function(){this.init=function(){var re={};this.on=function(pe,Se){re[pe]||(re[pe]=[]),re[pe]=re[pe].concat(Se)},this.off=function(pe,Se){var _e;return re[pe]?(_e=re[pe].indexOf(Se),re[pe]=re[pe].slice(),re[pe].splice(_e,1),_e>-1):!1},this.trigger=function(pe){var Se,_e,Me,Fe;if(Se=re[pe],!!Se)if(arguments.length===2)for(Me=Se.length,_e=0;_e<Me;++_e)Se[_e].call(this,arguments[1]);else{for(Fe=[],_e=arguments.length,_e=1;_e<arguments.length;++_e)Fe.push(arguments[_e]);for(Me=Se.length,_e=0;_e<Me;++_e)Se[_e].apply(this,Fe)}},this.dispose=function(){re={}}}};e.prototype.pipe=function(re){return this.on("data",function(pe){re.push(pe)}),this.on("done",function(pe){re.flush(pe)}),this.on("partialdone",function(pe){re.partialFlush(pe)}),this.on("endedtimeline",function(pe){re.endTimeline(pe)}),this.on("reset",function(pe){re.reset(pe)}),re},e.prototype.push=function(re){this.trigger("data",re)},e.prototype.flush=function(re){this.trigger("done",re)},e.prototype.partialFlush=function(re){this.trigger("partialdone",re)},e.prototype.endTimeline=function(re){this.trigger("endedtimeline",re)},e.prototype.reset=function(re){this.trigger("reset",re)};var n=e,o=Math.pow(2,32),u=function(re){var pe=new DataView(re.buffer,re.byteOffset,re.byteLength),Se;return pe.getBigUint64?(Se=pe.getBigUint64(0),Se<Number.MAX_SAFE_INTEGER?Number(Se):Se):pe.getUint32(0)*o+pe.getUint32(4)},l={getUint64:u,MAX_UINT32:o},m=l.MAX_UINT32,y,E,C,k,A,D,P,R,B,F,j,N,Y,J,ie,ue,Q,ce,he,ke,L,d,v,w,c,p,x,S,b,h,T,M,O,V,ee,Z;(function(){var re;if(v={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],pasp:[],sdtp:[],smhd:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],styp:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[]},!(typeof Uint8Array>"u")){for(re in v)v.hasOwnProperty(re)&&(v[re]=[re.charCodeAt(0),re.charCodeAt(1),re.charCodeAt(2),re.charCodeAt(3)]);w=new Uint8Array([105,115,111,109]),p=new Uint8Array([97,118,99,49]),c=new Uint8Array([0,0,0,1]),x=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]),S=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]),b={video:x,audio:S},M=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),T=new Uint8Array([0,0,0,0,0,0,0,0]),O=new Uint8Array([0,0,0,0,0,0,0,0]),V=O,ee=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),Z=O,h=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}})(),y=function(re){var pe=[],Se=0,_e,Me,Fe;for(_e=1;_e<arguments.length;_e++)pe.push(arguments[_e]);for(_e=pe.length;_e--;)Se+=pe[_e].byteLength;for(Me=new Uint8Array(Se+8),Fe=new DataView(Me.buffer,Me.byteOffset,Me.byteLength),Fe.setUint32(0,Me.byteLength),Me.set(re,4),_e=0,Se=8;_e<pe.length;_e++)Me.set(pe[_e],Se),Se+=pe[_e].byteLength;return Me},E=function(){return y(v.dinf,y(v.dref,M))},C=function(re){return y(v.esds,new Uint8Array([0,0,0,0,3,25,0,0,0,4,17,64,21,0,6,0,0,0,218,192,0,0,218,192,5,2,re.audioobjecttype<<3|re.samplingfrequencyindex>>>1,re.samplingfrequencyindex<<7|re.channelcount<<3,6,1,2]))},k=function(){return y(v.ftyp,w,c,w,p)},ue=function(re){return y(v.hdlr,b[re])},A=function(re){return y(v.mdat,re)},ie=function(re){var pe=new Uint8Array([0,0,0,0,0,0,0,2,0,0,0,3,0,1,95,144,re.duration>>>24&255,re.duration>>>16&255,re.duration>>>8&255,re.duration&255,85,196,0,0]);return re.samplerate&&(pe[12]=re.samplerate>>>24&255,pe[13]=re.samplerate>>>16&255,pe[14]=re.samplerate>>>8&255,pe[15]=re.samplerate&255),y(v.mdhd,pe)},J=function(re){return y(v.mdia,ie(re),ue(re.type),P(re))},D=function(re){return y(v.mfhd,new Uint8Array([0,0,0,0,(re&4278190080)>>24,(re&16711680)>>16,(re&65280)>>8,re&255]))},P=function(re){return y(v.minf,re.type==="video"?y(v.vmhd,h):y(v.smhd,T),E(),ce(re))},R=function(re,pe){for(var Se=[],_e=pe.length;_e--;)Se[_e]=ke(pe[_e]);return y.apply(null,[v.moof,D(re)].concat(Se))},B=function(re){for(var pe=re.length,Se=[];pe--;)Se[pe]=N(re[pe]);return y.apply(null,[v.moov,j(4294967295)].concat(Se).concat(F(re)))},F=function(re){for(var pe=re.length,Se=[];pe--;)Se[pe]=L(re[pe]);return y.apply(null,[v.mvex].concat(Se))},j=function(re){var pe=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,2,0,1,95,144,(re&4278190080)>>24,(re&16711680)>>16,(re&65280)>>8,re&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 y(v.mvhd,pe)},Q=function(re){var pe=re.samples||[],Se=new Uint8Array(4+pe.length),_e,Me;for(Me=0;Me<pe.length;Me++)_e=pe[Me].flags,Se[Me+4]=_e.dependsOn<<4|_e.isDependedOn<<2|_e.hasRedundancy;return y(v.sdtp,Se)},ce=function(re){return y(v.stbl,he(re),y(v.stts,Z),y(v.stsc,V),y(v.stsz,ee),y(v.stco,O))},function(){var re,pe;he=function(Se){return y(v.stsd,new Uint8Array([0,0,0,0,0,0,0,1]),Se.type==="video"?re(Se):pe(Se))},re=function(Se){var _e=Se.sps||[],Me=Se.pps||[],Fe=[],dt=[],yt,Tt;for(yt=0;yt<_e.length;yt++)Fe.push((_e[yt].byteLength&65280)>>>8),Fe.push(_e[yt].byteLength&255),Fe=Fe.concat(Array.prototype.slice.call(_e[yt]));for(yt=0;yt<Me.length;yt++)dt.push((Me[yt].byteLength&65280)>>>8),dt.push(Me[yt].byteLength&255),dt=dt.concat(Array.prototype.slice.call(Me[yt]));if(Tt=[v.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,(Se.width&65280)>>8,Se.width&255,(Se.height&65280)>>8,Se.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]),y(v.avcC,new Uint8Array([1,Se.profileIdc,Se.profileCompatibility,Se.levelIdc,255].concat([_e.length],Fe,[Me.length],dt))),y(v.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192]))],Se.sarRatio){var Rt=Se.sarRatio[0],Zt=Se.sarRatio[1];Tt.push(y(v.pasp,new Uint8Array([(Rt&4278190080)>>24,(Rt&16711680)>>16,(Rt&65280)>>8,Rt&255,(Zt&4278190080)>>24,(Zt&16711680)>>16,(Zt&65280)>>8,Zt&255])))}return y.apply(null,Tt)},pe=function(Se){return y(v.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,(Se.channelcount&65280)>>8,Se.channelcount&255,(Se.samplesize&65280)>>8,Se.samplesize&255,0,0,0,0,(Se.samplerate&65280)>>8,Se.samplerate&255,0,0]),C(Se))}}(),Y=function(re){var pe=new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,(re.id&4278190080)>>24,(re.id&16711680)>>16,(re.id&65280)>>8,re.id&255,0,0,0,0,(re.duration&4278190080)>>24,(re.duration&16711680)>>16,(re.duration&65280)>>8,re.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,(re.width&65280)>>8,re.width&255,0,0,(re.height&65280)>>8,re.height&255,0,0]);return y(v.tkhd,pe)},ke=function(re){var pe,Se,_e,Me,Fe,dt,yt;return pe=y(v.tfhd,new Uint8Array([0,0,0,58,(re.id&4278190080)>>24,(re.id&16711680)>>16,(re.id&65280)>>8,re.id&255,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0])),dt=Math.floor(re.baseMediaDecodeTime/m),yt=Math.floor(re.baseMediaDecodeTime%m),Se=y(v.tfdt,new Uint8Array([1,0,0,0,dt>>>24&255,dt>>>16&255,dt>>>8&255,dt&255,yt>>>24&255,yt>>>16&255,yt>>>8&255,yt&255])),Fe=92,re.type==="audio"?(_e=d(re,Fe),y(v.traf,pe,Se,_e)):(Me=Q(re),_e=d(re,Me.length+Fe),y(v.traf,pe,Se,_e,Me))},N=function(re){return re.duration=re.duration||4294967295,y(v.trak,Y(re),J(re))},L=function(re){var pe=new Uint8Array([0,0,0,0,(re.id&4278190080)>>24,(re.id&16711680)>>16,(re.id&65280)>>8,re.id&255,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return re.type!=="video"&&(pe[pe.length-1]=0),y(v.trex,pe)},function(){var re,pe,Se;Se=function(_e,Me){var Fe=0,dt=0,yt=0,Tt=0;return _e.length&&(_e[0].duration!==void 0&&(Fe=1),_e[0].size!==void 0&&(dt=2),_e[0].flags!==void 0&&(yt=4),_e[0].compositionTimeOffset!==void 0&&(Tt=8)),[0,0,Fe|dt|yt|Tt,1,(_e.length&4278190080)>>>24,(_e.length&16711680)>>>16,(_e.length&65280)>>>8,_e.length&255,(Me&4278190080)>>>24,(Me&16711680)>>>16,(Me&65280)>>>8,Me&255]},pe=function(_e,Me){var Fe,dt,yt,Tt,Rt,Zt;for(Tt=_e.samples||[],Me+=20+16*Tt.length,yt=Se(Tt,Me),dt=new Uint8Array(yt.length+Tt.length*16),dt.set(yt),Fe=yt.length,Zt=0;Zt<Tt.length;Zt++)Rt=Tt[Zt],dt[Fe++]=(Rt.duration&4278190080)>>>24,dt[Fe++]=(Rt.duration&16711680)>>>16,dt[Fe++]=(Rt.duration&65280)>>>8,dt[Fe++]=Rt.duration&255,dt[Fe++]=(Rt.size&4278190080)>>>24,dt[Fe++]=(Rt.size&16711680)>>>16,dt[Fe++]=(Rt.size&65280)>>>8,dt[Fe++]=Rt.size&255,dt[Fe++]=Rt.flags.isLeading<<2|Rt.flags.dependsOn,dt[Fe++]=Rt.flags.isDependedOn<<6|Rt.flags.hasRedundancy<<4|Rt.flags.paddingValue<<1|Rt.flags.isNonSyncSample,dt[Fe++]=Rt.flags.degradationPriority&61440,dt[Fe++]=Rt.flags.degradationPriority&15,dt[Fe++]=(Rt.compositionTimeOffset&4278190080)>>>24,dt[Fe++]=(Rt.compositionTimeOffset&16711680)>>>16,dt[Fe++]=(Rt.compositionTimeOffset&65280)>>>8,dt[Fe++]=Rt.compositionTimeOffset&255;return y(v.trun,dt)},re=function(_e,Me){var Fe,dt,yt,Tt,Rt,Zt;for(Tt=_e.samples||[],Me+=20+8*Tt.length,yt=Se(Tt,Me),Fe=new Uint8Array(yt.length+Tt.length*8),Fe.set(yt),dt=yt.length,Zt=0;Zt<Tt.length;Zt++)Rt=Tt[Zt],Fe[dt++]=(Rt.duration&4278190080)>>>24,Fe[dt++]=(Rt.duration&16711680)>>>16,Fe[dt++]=(Rt.duration&65280)>>>8,Fe[dt++]=Rt.duration&255,Fe[dt++]=(Rt.size&4278190080)>>>24,Fe[dt++]=(Rt.size&16711680)>>>16,Fe[dt++]=(Rt.size&65280)>>>8,Fe[dt++]=Rt.size&255;return y(v.trun,Fe)},d=function(_e,Me){return _e.type==="audio"?re(_e,Me):pe(_e,Me)}}();var U={ftyp:k,mdat:A,moof:R,moov:B,initSegment:function(re){var pe=k(),Se=B(re),_e;return _e=new Uint8Array(pe.byteLength+Se.byteLength),_e.set(pe),_e.set(Se,pe.byteLength),_e}},z=function(re){var pe,Se,_e=[],Me=[];for(Me.byteLength=0,Me.nalCount=0,Me.duration=0,_e.byteLength=0,pe=0;pe<re.length;pe++)Se=re[pe],Se.nalUnitType==="access_unit_delimiter_rbsp"?(_e.length&&(_e.duration=Se.dts-_e.dts,Me.byteLength+=_e.byteLength,Me.nalCount+=_e.length,Me.duration+=_e.duration,Me.push(_e)),_e=[Se],_e.byteLength=Se.data.byteLength,_e.pts=Se.pts,_e.dts=Se.dts):(Se.nalUnitType==="slice_layer_without_partitioning_rbsp_idr"&&(_e.keyFrame=!0),_e.duration=Se.dts-_e.dts,_e.byteLength+=Se.data.byteLength,_e.push(Se));return Me.length&&(!_e.duration||_e.duration<=0)&&(_e.duration=Me[Me.length-1].duration),Me.byteLength+=_e.byteLength,Me.nalCount+=_e.length,Me.duration+=_e.duration,Me.push(_e),Me},ne=function(re){var pe,Se,_e=[],Me=[];for(_e.byteLength=0,_e.nalCount=0,_e.duration=0,_e.pts=re[0].pts,_e.dts=re[0].dts,Me.byteLength=0,Me.nalCount=0,Me.duration=0,Me.pts=re[0].pts,Me.dts=re[0].dts,pe=0;pe<re.length;pe++)Se=re[pe],Se.keyFrame?(_e.length&&(Me.push(_e),Me.byteLength+=_e.byteLength,Me.nalCount+=_e.nalCount,Me.duration+=_e.duration),_e=[Se],_e.nalCount=Se.length,_e.byteLength=Se.byteLength,_e.pts=Se.pts,_e.dts=Se.dts,_e.duration=Se.duration):(_e.duration+=Se.duration,_e.nalCount+=Se.length,_e.byteLength+=Se.byteLength,_e.push(Se));return Me.length&&_e.duration<=0&&(_e.duration=Me[Me.length-1].duration),Me.byteLength+=_e.byteLength,Me.nalCount+=_e.nalCount,Me.duration+=_e.duration,Me.push(_e),Me},fe=function(re){var pe;return!re[0][0].keyFrame&&re.length>1&&(pe=re.shift(),re.byteLength-=pe.byteLength,re.nalCount-=pe.nalCount,re[0][0].dts=pe.dts,re[0][0].pts=pe.pts,re[0][0].duration+=pe.duration),re},me=function(){return{size:0,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0,degradationPriority:0,isNonSyncSample:1}}},de=function(re,pe){var Se=me();return Se.dataOffset=pe,Se.compositionTimeOffset=re.pts-re.dts,Se.duration=re.duration,Se.size=4*re.length,Se.size+=re.byteLength,re.keyFrame&&(Se.flags.dependsOn=2,Se.flags.isNonSyncSample=0),Se},je=function(re,pe){var Se,_e,Me,Fe,dt,yt=pe||0,Tt=[];for(Se=0;Se<re.length;Se++)for(Fe=re[Se],_e=0;_e<Fe.length;_e++)dt=Fe[_e],Me=de(dt,yt),yt+=Me.size,Tt.push(Me);return Tt},lt=function(re){var pe,Se,_e,Me,Fe,dt,yt=0,Tt=re.byteLength,Rt=re.nalCount,Zt=Tt+4*Rt,ci=new Uint8Array(Zt),Wi=new DataView(ci.buffer);for(pe=0;pe<re.length;pe++)for(Me=re[pe],Se=0;Se<Me.length;Se++)for(Fe=Me[Se],_e=0;_e<Fe.length;_e++)dt=Fe[_e],Wi.setUint32(yt,dt.data.byteLength),yt+=4,ci.set(dt.data,yt),yt+=dt.data.byteLength;return ci},it=function(re,pe){var Se,_e=pe||0,Me=[];return Se=de(re,_e),Me.push(Se),Me},ot=function(re){var pe,Se,_e=0,Me=re.byteLength,Fe=re.length,dt=Me+4*Fe,yt=new Uint8Array(dt),Tt=new DataView(yt.buffer);for(pe=0;pe<re.length;pe++)Se=re[pe],Tt.setUint32(_e,Se.data.byteLength),_e+=4,yt.set(Se.data,_e),_e+=Se.data.byteLength;return yt},Ct={groupNalsIntoFrames:z,groupFramesIntoGops:ne,extendFirstKeyFrame:fe,generateSampleTable:je,concatenateNalData:lt,generateSampleTableForFrame:it,concatenateNalDataForFrame:ot},nt=[33,16,5,32,164,27],Je=[33,65,108,84,1,2,4,8,168,2,4,8,17,191,252],tt=function(re){for(var pe=[];re--;)pe.push(0);return pe},rt=function(re){return Object.keys(re).reduce(function(pe,Se){return pe[Se]=new Uint8Array(re[Se].reduce(function(_e,Me){return _e.concat(Me)},[])),pe},{})},ht,Ot=function(){if(!ht){var re={96e3:[nt,[227,64],tt(154),[56]],88200:[nt,[231],tt(170),[56]],64e3:[nt,[248,192],tt(240),[56]],48e3:[nt,[255,192],tt(268),[55,148,128],tt(54),[112]],44100:[nt,[255,192],tt(268),[55,163,128],tt(84),[112]],32e3:[nt,[255,192],tt(268),[55,234],tt(226),[112]],24e3:[nt,[255,192],tt(268),[55,255,128],tt(268),[111,112],tt(126),[224]],16e3:[nt,[255,192],tt(268),[55,255,128],tt(268),[111,255],tt(269),[223,108],tt(195),[1,192]],12e3:[Je,tt(268),[3,127,248],tt(268),[6,255,240],tt(268),[13,255,224],tt(268),[27,253,128],tt(259),[56]],11025:[Je,tt(268),[3,127,248],tt(268),[6,255,240],tt(268),[13,255,224],tt(268),[27,255,192],tt(268),[55,175,128],tt(108),[112]],8e3:[Je,tt(268),[3,121,16],tt(47),[7]]};ht=rt(re)}return ht},Ve=9e4,We,Gt,wt,Et,Yt,Ce,te;We=function(re){return re*Ve},Gt=function(re,pe){return re*pe},wt=function(re){return re/Ve},Et=function(re,pe){return re/pe},Yt=function(re,pe){return We(Et(re,pe))},Ce=function(re,pe){return Gt(wt(re),pe)},te=function(re,pe,Se){return wt(Se?re:re-pe)};var ye={ONE_SECOND_IN_TS:Ve,secondsToVideoTs:We,secondsToAudioTs:Gt,videoTsToSeconds:wt,audioTsToSeconds:Et,audioTsToVideoTs:Yt,videoTsToAudioTs:Ce,metadataTsToSeconds:te},Le=Ot,Ue=ye,Qe=function(re){var pe,Se,_e=0;for(pe=0;pe<re.length;pe++)Se=re[pe],_e+=Se.data.byteLength;return _e},Ke=function(re,pe,Se,_e){var Me,Fe=0,dt=0,yt=0,Tt=0,Rt,Zt,ci;if(pe.length&&(Me=Ue.audioTsToVideoTs(re.baseMediaDecodeTime,re.samplerate),Fe=Math.ceil(Ue.ONE_SECOND_IN_TS/(re.samplerate/1024)),Se&&_e&&(dt=Me-Math.max(Se,_e),yt=Math.floor(dt/Fe),Tt=yt*Fe),!(yt<1||Tt>Ue.ONE_SECOND_IN_TS/2))){for(Rt=Le()[re.samplerate],Rt||(Rt=pe[0].data),Zt=0;Zt<yt;Zt++)ci=pe[0],pe.splice(0,0,{data:Rt,dts:ci.dts-Fe,pts:ci.pts-Fe});return re.baseMediaDecodeTime-=Math.floor(Ue.videoTsToAudioTs(Tt,re.samplerate)),Tt}},De=function(re,pe,Se){return pe.minSegmentDts>=Se?re:(pe.minSegmentDts=1/0,re.filter(function(_e){return _e.dts>=Se?(pe.minSegmentDts=Math.min(pe.minSegmentDts,_e.dts),pe.minSegmentPts=pe.minSegmentDts,!0):!1}))},Vt=function(re){var pe,Se,_e=[];for(pe=0;pe<re.length;pe++)Se=re[pe],_e.push({size:Se.data.byteLength,duration:1024});return _e},At=function(re){var pe,Se,_e=0,Me=new Uint8Array(Qe(re));for(pe=0;pe<re.length;pe++)Se=re[pe],Me.set(Se.data,_e),_e+=Se.data.byteLength;return Me},ve={prefixWithSilence:Ke,trimAdtsFramesByEarliestDts:De,generateSampleTable:Vt,concatenateFrameData:At},Pt=ye.ONE_SECOND_IN_TS,pt=function(re,pe){typeof pe.pts=="number"&&(re.timelineStartInfo.pts===void 0&&(re.timelineStartInfo.pts=pe.pts),re.minSegmentPts===void 0?re.minSegmentPts=pe.pts:re.minSegmentPts=Math.min(re.minSegmentPts,pe.pts),re.maxSegmentPts===void 0?re.maxSegmentPts=pe.pts:re.maxSegmentPts=Math.max(re.maxSegmentPts,pe.pts)),typeof pe.dts=="number"&&(re.timelineStartInfo.dts===void 0&&(re.timelineStartInfo.dts=pe.dts),re.minSegmentDts===void 0?re.minSegmentDts=pe.dts:re.minSegmentDts=Math.min(re.minSegmentDts,pe.dts),re.maxSegmentDts===void 0?re.maxSegmentDts=pe.dts:re.maxSegmentDts=Math.max(re.maxSegmentDts,pe.dts))},Ne=function(re){delete re.minSegmentDts,delete re.maxSegmentDts,delete re.minSegmentPts,delete re.maxSegmentPts},vt=function(re,pe){var Se,_e,Me=re.minSegmentDts;return pe||(Me-=re.timelineStartInfo.dts),Se=re.timelineStartInfo.baseMediaDecodeTime,Se+=Me,Se=Math.max(0,Se),re.type==="audio"&&(_e=re.samplerate/Pt,Se*=_e,Se=Math.floor(Se)),Se},ut={clearDtsInfo:Ne,calculateTrackBaseMediaDecodeTime:vt,collectDtsInfo:pt},$t=4,fi=128,kt=function(re){for(var pe=0,Se={payloadType:-1,payloadSize:0},_e=0,Me=0;pe<re.byteLength&&re[pe]!==fi;){for(;re[pe]===255;)_e+=255,pe++;for(_e+=re[pe++];re[pe]===255;)Me+=255,pe++;if(Me+=re[pe++],!Se.payload&&_e===$t){var Fe=String.fromCharCode(re[pe+3],re[pe+4],re[pe+5],re[pe+6]);if(Fe==="GA94"){Se.payloadType=_e,Se.payloadSize=Me,Se.payload=re.subarray(pe,pe+Me);break}else Se.payload=void 0}pe+=Me,_e=0,Me=0}return Se},Wt=function(re){return re.payload[0]!==181||(re.payload[1]<<8|re.payload[2])!==49||String.fromCharCode(re.payload[3],re.payload[4],re.payload[5],re.payload[6])!=="GA94"||re.payload[7]!==3?null:re.payload.subarray(8,re.payload.length-1)},Zi=function(re,pe){var Se=[],_e,Me,Fe,dt;if(!(pe[0]&64))return Se;for(Me=pe[0]&31,_e=0;_e<Me;_e++)Fe=_e*3,dt={type:pe[Fe+2]&3,pts:re},pe[Fe+2]&4&&(dt.ccData=pe[Fe+3]<<8|pe[Fe+4],Se.push(dt));return Se},Ut=function(re){for(var pe=re.byteLength,Se=[],_e=1,Me,Fe;_e<pe-2;)re[_e]===0&&re[_e+1]===0&&re[_e+2]===3?(Se.push(_e+2),_e+=2):_e++;if(Se.length===0)return re;Me=pe-Se.length,Fe=new Uint8Array(Me);var dt=0;for(_e=0;_e<Me;dt++,_e++)dt===Se[0]&&(dt++,Se.shift()),Fe[_e]=re[dt];return Fe},Xt={parseSei:kt,parseUserData:Wt,parseCaptionPackets:Zi,discardEmulationPreventionBytes:Ut,USER_DATA_REGISTERED_ITU_T_T35:$t},Be=n,be=Xt,ge=function(re){re=re||{},ge.prototype.init.call(this),this.parse708captions_=typeof re.parse708captions=="boolean"?re.parse708captions:!0,this.captionPackets_=[],this.ccStreams_=[new ni(0,0),new ni(0,1),new ni(1,0),new ni(1,1)],this.parse708captions_&&(this.cc708Stream_=new gt({captionServices:re.captionServices})),this.reset(),this.ccStreams_.forEach(function(pe){pe.on("data",this.trigger.bind(this,"data")),pe.on("partialdone",this.trigger.bind(this,"partialdone")),pe.on("done",this.trigger.bind(this,"done"))},this),this.parse708captions_&&(this.cc708Stream_.on("data",this.trigger.bind(this,"data")),this.cc708Stream_.on("partialdone",this.trigger.bind(this,"partialdone")),this.cc708Stream_.on("done",this.trigger.bind(this,"done")))};ge.prototype=new Be,ge.prototype.push=function(re){var pe,Se,_e;if(re.nalUnitType==="sei_rbsp"&&(pe=be.parseSei(re.escapedRBSP),!!pe.payload&&pe.payloadType===be.USER_DATA_REGISTERED_ITU_T_T35&&(Se=be.parseUserData(pe),!!Se))){if(re.dts<this.latestDts_){this.ignoreNextEqualDts_=!0;return}else if(re.dts===this.latestDts_&&this.ignoreNextEqualDts_){this.numSameDts_--,this.numSameDts_||(this.ignoreNextEqualDts_=!1);return}_e=be.parseCaptionPackets(re.pts,Se),this.captionPackets_=this.captionPackets_.concat(_e),this.latestDts_!==re.dts&&(this.numSameDts_=0),this.numSameDts_++,this.latestDts_=re.dts}},ge.prototype.flushCCStreams=function(re){this.ccStreams_.forEach(function(pe){return re==="flush"?pe.flush():pe.partialFlush()},this)},ge.prototype.flushStream=function(re){if(!this.captionPackets_.length){this.flushCCStreams(re);return}this.captionPackets_.forEach(function(pe,Se){pe.presortIndex=Se}),this.captionPackets_.sort(function(pe,Se){return pe.pts===Se.pts?pe.presortIndex-Se.presortIndex:pe.pts-Se.pts}),this.captionPackets_.forEach(function(pe){pe.type<2?this.dispatchCea608Packet(pe):this.dispatchCea708Packet(pe)},this),this.captionPackets_.length=0,this.flushCCStreams(re)},ge.prototype.flush=function(){return this.flushStream("flush")},ge.prototype.partialFlush=function(){return this.flushStream("partialFlush")},ge.prototype.reset=function(){this.latestDts_=null,this.ignoreNextEqualDts_=!1,this.numSameDts_=0,this.activeCea608Channel_=[null,null],this.ccStreams_.forEach(function(re){re.reset()})},ge.prototype.dispatchCea608Packet=function(re){this.setsTextOrXDSActive(re)?this.activeCea608Channel_[re.type]=null:this.setsChannel1Active(re)?this.activeCea608Channel_[re.type]=0:this.setsChannel2Active(re)&&(this.activeCea608Channel_[re.type]=1),this.activeCea608Channel_[re.type]!==null&&this.ccStreams_[(re.type<<1)+this.activeCea608Channel_[re.type]].push(re)},ge.prototype.setsChannel1Active=function(re){return(re.ccData&30720)===4096},ge.prototype.setsChannel2Active=function(re){return(re.ccData&30720)===6144},ge.prototype.setsTextOrXDSActive=function(re){return(re.ccData&28928)===256||(re.ccData&30974)===4138||(re.ccData&30974)===6186},ge.prototype.dispatchCea708Packet=function(re){this.parse708captions_&&this.cc708Stream_.push(re)};var oe={127:9834,4128:32,4129:160,4133:8230,4138:352,4140:338,4144:9608,4145:8216,4146:8217,4147:8220,4148:8221,4149:8226,4153:8482,4154:353,4156:339,4157:8480,4159:376,4214:8539,4215:8540,4216:8541,4217:8542,4218:9168,4219:9124,4220:9123,4221:9135,4222:9126,4223:9121,4256:12600},Ae=function(re){var pe=oe[re]||re;return re&4096&&re===pe?"":String.fromCharCode(pe)},qe=function(re){return 32<=re&&re<=127||160<=re&&re<=255},bt=function(re){this.windowNum=re,this.reset()};bt.prototype.reset=function(){this.clearText(),this.pendingNewLine=!1,this.winAttr={},this.penAttr={},this.penLoc={},this.penColor={},this.visible=0,this.rowLock=0,this.columnLock=0,this.priority=0,this.relativePositioning=0,this.anchorVertical=0,this.anchorHorizontal=0,this.anchorPoint=0,this.rowCount=1,this.virtualRowCount=this.rowCount+1,this.columnCount=41,this.windowStyle=0,this.penStyle=0},bt.prototype.getText=function(){return this.rows.join(`
`)},bt.prototype.clearText=function(){this.rows=[""],this.rowIdx=0},bt.prototype.newLine=function(re){for(this.rows.length>=this.virtualRowCount&&typeof this.beforeRowOverflow=="function"&&this.beforeRowOverflow(re),this.rows.length>0&&(this.rows.push(""),this.rowIdx++);this.rows.length>this.virtualRowCount;)this.rows.shift(),this.rowIdx--},bt.prototype.isEmpty=function(){return this.rows.length===0?!0:this.rows.length===1?this.rows[0]==="":!1},bt.prototype.addText=function(re){this.rows[this.rowIdx]+=re},bt.prototype.backspace=function(){if(!this.isEmpty()){var re=this.rows[this.rowIdx];this.rows[this.rowIdx]=re.substr(0,re.length-1)}};var at=function(re,pe,Se){this.serviceNum=re,this.text="",this.currentWindow=new bt(-1),this.windows=[],this.stream=Se,typeof pe=="string"&&this.createTextDecoder(pe)};at.prototype.init=function(re,pe){this.startPts=re;for(var Se=0;Se<8;Se++)this.windows[Se]=new bt(Se),typeof pe=="function"&&(this.windows[Se].beforeRowOverflow=pe)},at.prototype.setCurrentWindow=function(re){this.currentWindow=this.windows[re]},at.prototype.createTextDecoder=function(re){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(re)}catch(pe){this.stream.trigger("log",{level:"warn",message:"TextDecoder could not be created with "+re+" encoding. "+pe})}};var gt=function(re){re=re||{},gt.prototype.init.call(this);var pe=this,Se=re.captionServices||{},_e={},Me;Object.keys(Se).forEach(Fe=>{Me=Se[Fe],/^SERVICE/.test(Fe)&&(_e[Fe]=Me.encoding)}),this.serviceEncodings=_e,this.current708Packet=null,this.services={},this.push=function(Fe){Fe.type===3?(pe.new708Packet(),pe.add708Bytes(Fe)):(pe.current708Packet===null&&pe.new708Packet(),pe.add708Bytes(Fe))}};gt.prototype=new Be,gt.prototype.new708Packet=function(){this.current708Packet!==null&&this.push708Packet(),this.current708Packet={data:[],ptsVals:[]}},gt.prototype.add708Bytes=function(re){var pe=re.ccData,Se=pe>>>8,_e=pe&255;this.current708Packet.ptsVals.push(re.pts),this.current708Packet.data.push(Se),this.current708Packet.data.push(_e)},gt.prototype.push708Packet=function(){var re=this.current708Packet,pe=re.data,Se=null,_e=null,Me=0,Fe=pe[Me++];for(re.seq=Fe>>6,re.sizeCode=Fe&63;Me<pe.length;Me++)Fe=pe[Me++],Se=Fe>>5,_e=Fe&31,Se===7&&_e>0&&(Fe=pe[Me++],Se=Fe),this.pushServiceBlock(Se,Me,_e),_e>0&&(Me+=_e-1)},gt.prototype.pushServiceBlock=function(re,pe,Se){var _e,Me=pe,Fe=this.current708Packet.data,dt=this.services[re];for(dt||(dt=this.initService(re,Me));Me<pe+Se&&Me<Fe.length;Me++)_e=Fe[Me],qe(_e)?Me=this.handleText(Me,dt):_e===24?Me=this.multiByteCharacter(Me,dt):_e===16?Me=this.extendedCommands(Me,dt):128<=_e&&_e<=135?Me=this.setCurrentWindow(Me,dt):152<=_e&&_e<=159?Me=this.defineWindow(Me,dt):_e===136?Me=this.clearWindows(Me,dt):_e===140?Me=this.deleteWindows(Me,dt):_e===137?Me=this.displayWindows(Me,dt):_e===138?Me=this.hideWindows(Me,dt):_e===139?Me=this.toggleWindows(Me,dt):_e===151?Me=this.setWindowAttributes(Me,dt):_e===144?Me=this.setPenAttributes(Me,dt):_e===145?Me=this.setPenColor(Me,dt):_e===146?Me=this.setPenLocation(Me,dt):_e===143?dt=this.reset(Me,dt):_e===8?dt.currentWindow.backspace():_e===12?dt.currentWindow.clearText():_e===13?dt.currentWindow.pendingNewLine=!0:_e===14?dt.currentWindow.clearText():_e===141&&Me++},gt.prototype.extendedCommands=function(re,pe){var Se=this.current708Packet.data,_e=Se[++re];return qe(_e)&&(re=this.handleText(re,pe,{isExtended:!0})),re},gt.prototype.getPts=function(re){return this.current708Packet.ptsVals[Math.floor(re/2)]},gt.prototype.initService=function(re,pe){var _e="SERVICE"+re,Se=this,_e,Me;return _e in this.serviceEncodings&&(Me=this.serviceEncodings[_e]),this.services[re]=new at(re,Me,Se),this.services[re].init(this.getPts(pe),function(Fe){Se.flushDisplayed(Fe,Se.services[re])}),this.services[re]},gt.prototype.handleText=function(re,pe,Se){var _e=Se&&Se.isExtended,Me=Se&&Se.isMultiByte,Fe=this.current708Packet.data,dt=_e?4096:0,yt=Fe[re],Tt=Fe[re+1],Rt=pe.currentWindow,Zt,ci;function Wi(Pi){return Pi.map(lr=>("0"+(lr&255).toString(16)).slice(-2)).join("")}if(Me?(ci=[yt,Tt],re++):ci=[yt],pe.textDecoder_&&!_e)Zt=pe.textDecoder_.decode(new Uint8Array(ci));else if(Me){const Pi=Wi(ci);Zt=String.fromCharCode(parseInt(Pi,16))}else Zt=Ae(dt|yt);return Rt.pendingNewLine&&!Rt.isEmpty()&&Rt.newLine(this.getPts(re)),Rt.pendingNewLine=!1,Rt.addText(Zt),re},gt.prototype.multiByteCharacter=function(re,pe){var Se=this.current708Packet.data,_e=Se[re+1],Me=Se[re+2];return qe(_e)&&qe(Me)&&(re=this.handleText(++re,pe,{isMultiByte:!0})),re},gt.prototype.setCurrentWindow=function(re,pe){var Se=this.current708Packet.data,_e=Se[re],Me=_e&7;return pe.setCurrentWindow(Me),re},gt.prototype.defineWindow=function(re,pe){var Se=this.current708Packet.data,_e=Se[re],Me=_e&7;pe.setCurrentWindow(Me);var Fe=pe.currentWindow;return _e=Se[++re],Fe.visible=(_e&32)>>5,Fe.rowLock=(_e&16)>>4,Fe.columnLock=(_e&8)>>3,Fe.priority=_e&7,_e=Se[++re],Fe.relativePositioning=(_e&128)>>7,Fe.anchorVertical=_e&127,_e=Se[++re],Fe.anchorHorizontal=_e,_e=Se[++re],Fe.anchorPoint=(_e&240)>>4,Fe.rowCount=_e&15,_e=Se[++re],Fe.columnCount=_e&63,_e=Se[++re],Fe.windowStyle=(_e&56)>>3,Fe.penStyle=_e&7,Fe.virtualRowCount=Fe.rowCount+1,re},gt.prototype.setWindowAttributes=function(re,pe){var Se=this.current708Packet.data,_e=Se[re],Me=pe.currentWindow.winAttr;return _e=Se[++re],Me.fillOpacity=(_e&192)>>6,Me.fillRed=(_e&48)>>4,Me.fillGreen=(_e&12)>>2,Me.fillBlue=_e&3,_e=Se[++re],Me.borderType=(_e&192)>>6,Me.borderRed=(_e&48)>>4,Me.borderGreen=(_e&12)>>2,Me.borderBlue=_e&3,_e=Se[++re],Me.borderType+=(_e&128)>>5,Me.wordWrap=(_e&64)>>6,Me.printDirection=(_e&48)>>4,Me.scrollDirection=(_e&12)>>2,Me.justify=_e&3,_e=Se[++re],Me.effectSpeed=(_e&240)>>4,Me.effectDirection=(_e&12)>>2,Me.displayEffect=_e&3,re},gt.prototype.flushDisplayed=function(re,pe){for(var Se=[],_e=0;_e<8;_e++)pe.windows[_e].visible&&!pe.windows[_e].isEmpty()&&Se.push(pe.windows[_e].getText());pe.endPts=re,pe.text=Se.join(`

`),this.pushCaption(pe),pe.startPts=re},gt.prototype.pushCaption=function(re){re.text!==""&&(this.trigger("data",{startPts:re.startPts,endPts:re.endPts,text:re.text,stream:"cc708_"+re.serviceNum}),re.text="",re.startPts=re.endPts)},gt.prototype.displayWindows=function(re,pe){var Se=this.current708Packet.data,_e=Se[++re],Me=this.getPts(re);this.flushDisplayed(Me,pe);for(var Fe=0;Fe<8;Fe++)_e&1<<Fe&&(pe.windows[Fe].visible=1);return re},gt.prototype.hideWindows=function(re,pe){var Se=this.current708Packet.data,_e=Se[++re],Me=this.getPts(re);this.flushDisplayed(Me,pe);for(var Fe=0;Fe<8;Fe++)_e&1<<Fe&&(pe.windows[Fe].visible=0);return re},gt.prototype.toggleWindows=function(re,pe){var Se=this.current708Packet.data,_e=Se[++re],Me=this.getPts(re);this.flushDisplayed(Me,pe);for(var Fe=0;Fe<8;Fe++)_e&1<<Fe&&(pe.windows[Fe].visible^=1);return re},gt.prototype.clearWindows=function(re,pe){var Se=this.current708Packet.data,_e=Se[++re],Me=this.getPts(re);this.flushDisplayed(Me,pe);for(var Fe=0;Fe<8;Fe++)_e&1<<Fe&&pe.windows[Fe].clearText();return re},gt.prototype.deleteWindows=function(re,pe){var Se=this.current708Packet.data,_e=Se[++re],Me=this.getPts(re);this.flushDisplayed(Me,pe);for(var Fe=0;Fe<8;Fe++)_e&1<<Fe&&pe.windows[Fe].reset();return re},gt.prototype.setPenAttributes=function(re,pe){var Se=this.current708Packet.data,_e=Se[re],Me=pe.currentWindow.penAttr;return _e=Se[++re],Me.textTag=(_e&240)>>4,Me.offset=(_e&12)>>2,Me.penSize=_e&3,_e=Se[++re],Me.italics=(_e&128)>>7,Me.underline=(_e&64)>>6,Me.edgeType=(_e&56)>>3,Me.fontStyle=_e&7,re},gt.prototype.setPenColor=function(re,pe){var Se=this.current708Packet.data,_e=Se[re],Me=pe.currentWindow.penColor;return _e=Se[++re],Me.fgOpacity=(_e&192)>>6,Me.fgRed=(_e&48)>>4,Me.fgGreen=(_e&12)>>2,Me.fgBlue=_e&3,_e=Se[++re],Me.bgOpacity=(_e&192)>>6,Me.bgRed=(_e&48)>>4,Me.bgGreen=(_e&12)>>2,Me.bgBlue=_e&3,_e=Se[++re],Me.edgeRed=(_e&48)>>4,Me.edgeGreen=(_e&12)>>2,Me.edgeBlue=_e&3,re},gt.prototype.setPenLocation=function(re,pe){var Se=this.current708Packet.data,_e=Se[re],Me=pe.currentWindow.penLoc;return pe.currentWindow.pendingNewLine=!0,_e=Se[++re],Me.row=_e&15,_e=Se[++re],Me.column=_e&63,re},gt.prototype.reset=function(re,pe){var Se=this.getPts(re);return this.flushDisplayed(Se,pe),this.initService(pe.serviceNum,re)};var ei={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},ii=function(re){return re===null?"":(re=ei[re]||re,String.fromCharCode(re))},Bi=14,hi=[4352,4384,4608,4640,5376,5408,5632,5664,5888,5920,4096,4864,4896,5120,5152],Di=function(){for(var re=[],pe=Bi+1;pe--;)re.push({text:"",indent:0,offset:0});return re},ni=function(re,pe){ni.prototype.init.call(this),this.field_=re||0,this.dataChannel_=pe||0,this.name_="CC"+((this.field_<<1|this.dataChannel_)+1),this.setConstants(),this.reset(),this.push=function(Se){var _e,Me,Fe,dt,yt;if(_e=Se.ccData&32639,_e===this.lastControlCode_){this.lastControlCode_=null;return}if((_e&61440)===4096?this.lastControlCode_=_e:_e!==this.PADDING_&&(this.lastControlCode_=null),Fe=_e>>>8,dt=_e&255,_e!==this.PADDING_)if(_e===this.RESUME_CAPTION_LOADING_)this.mode_="popOn";else if(_e===this.END_OF_CAPTION_)this.mode_="popOn",this.clearFormatting(Se.pts),this.flushDisplayed(Se.pts),Me=this.displayed_,this.displayed_=this.nonDisplayed_,this.nonDisplayed_=Me,this.startPts_=Se.pts;else if(_e===this.ROLL_UP_2_ROWS_)this.rollUpRows_=2,this.setRollUp(Se.pts);else if(_e===this.ROLL_UP_3_ROWS_)this.rollUpRows_=3,this.setRollUp(Se.pts);else if(_e===this.ROLL_UP_4_ROWS_)this.rollUpRows_=4,this.setRollUp(Se.pts);else if(_e===this.CARRIAGE_RETURN_)this.clearFormatting(Se.pts),this.flushDisplayed(Se.pts),this.shiftRowsUp_(),this.startPts_=Se.pts;else if(_e===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(_e===this.ERASE_DISPLAYED_MEMORY_)this.flushDisplayed(Se.pts),this.displayed_=Di();else if(_e===this.ERASE_NON_DISPLAYED_MEMORY_)this.nonDisplayed_=Di();else if(_e===this.RESUME_DIRECT_CAPTIONING_)this.mode_!=="paintOn"&&(this.flushDisplayed(Se.pts),this.displayed_=Di()),this.mode_="paintOn",this.startPts_=Se.pts;else if(this.isSpecialCharacter(Fe,dt))Fe=(Fe&3)<<8,yt=ii(Fe|dt),this[this.mode_](Se.pts,yt),this.column_++;else if(this.isExtCharacter(Fe,dt))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),Fe=(Fe&3)<<8,yt=ii(Fe|dt),this[this.mode_](Se.pts,yt),this.column_++;else if(this.isMidRowCode(Fe,dt))this.clearFormatting(Se.pts),this[this.mode_](Se.pts," "),this.column_++,(dt&14)===14&&this.addFormatting(Se.pts,["i"]),(dt&1)===1&&this.addFormatting(Se.pts,["u"]);else if(this.isOffsetControlCode(Fe,dt)){const Rt=dt&3;this.nonDisplayed_[this.row_].offset=Rt,this.column_+=Rt}else if(this.isPAC(Fe,dt)){var Tt=hi.indexOf(_e&7968);if(this.mode_==="rollUp"&&(Tt-this.rollUpRows_+1<0&&(Tt=this.rollUpRows_-1),this.setRollUp(Se.pts,Tt)),Tt!==this.row_&&Tt>=0&&Tt<=14&&(this.clearFormatting(Se.pts),this.row_=Tt),dt&1&&this.formatting_.indexOf("u")===-1&&this.addFormatting(Se.pts,["u"]),(_e&16)===16){const Rt=(_e&14)>>1;this.column_=Rt*4,this.nonDisplayed_[this.row_].indent+=Rt}this.isColorPAC(dt)&&(dt&14)===14&&this.addFormatting(Se.pts,["i"])}else this.isNormalChar(Fe)&&(dt===0&&(dt=null),yt=ii(Fe),yt+=ii(dt),this[this.mode_](Se.pts,yt),this.column_+=yt.length)}};ni.prototype=new Be,ni.prototype.flushDisplayed=function(re){const pe=_e=>{this.trigger("log",{level:"warn",message:"Skipping a malformed 608 caption at index "+_e+"."})},Se=[];this.displayed_.forEach((_e,Me)=>{if(_e&&_e.text&&_e.text.length){try{_e.text=_e.text.trim()}catch{pe(Me)}_e.text.length&&Se.push({text:_e.text,line:Me+1,position:10+Math.min(70,_e.indent*10)+_e.offset*2.5})}else _e==null&&pe(Me)}),Se.length&&this.trigger("data",{startPts:this.startPts_,endPts:re,content:Se,stream:this.name_})},ni.prototype.reset=function(){this.mode_="popOn",this.topRow_=0,this.startPts_=0,this.displayed_=Di(),this.nonDisplayed_=Di(),this.lastControlCode_=null,this.column_=0,this.row_=Bi,this.rollUpRows_=2,this.formatting_=[]},ni.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},ni.prototype.isSpecialCharacter=function(re,pe){return re===this.EXT_&&pe>=48&&pe<=63},ni.prototype.isExtCharacter=function(re,pe){return(re===this.EXT_+1||re===this.EXT_+2)&&pe>=32&&pe<=63},ni.prototype.isMidRowCode=function(re,pe){return re===this.EXT_&&pe>=32&&pe<=47},ni.prototype.isOffsetControlCode=function(re,pe){return re===this.OFFSET_&&pe>=33&&pe<=35},ni.prototype.isPAC=function(re,pe){return re>=this.BASE_&&re<this.BASE_+8&&pe>=64&&pe<=127},ni.prototype.isColorPAC=function(re){return re>=64&&re<=79||re>=96&&re<=127},ni.prototype.isNormalChar=function(re){return re>=32&&re<=127},ni.prototype.setRollUp=function(re,pe){if(this.mode_!=="rollUp"&&(this.row_=Bi,this.mode_="rollUp",this.flushDisplayed(re),this.nonDisplayed_=Di(),this.displayed_=Di()),pe!==void 0&&pe!==this.row_)for(var Se=0;Se<this.rollUpRows_;Se++)this.displayed_[pe-Se]=this.displayed_[this.row_-Se],this.displayed_[this.row_-Se]={text:"",indent:0,offset:0};pe===void 0&&(pe=this.row_),this.topRow_=pe-this.rollUpRows_+1},ni.prototype.addFormatting=function(re,pe){this.formatting_=this.formatting_.concat(pe);var Se=pe.reduce(function(_e,Me){return _e+"<"+Me+">"},"");this[this.mode_](re,Se)},ni.prototype.clearFormatting=function(re){if(this.formatting_.length){var pe=this.formatting_.reverse().reduce(function(Se,_e){return Se+"</"+_e+">"},"");this.formatting_=[],this[this.mode_](re,pe)}},ni.prototype.popOn=function(re,pe){var Se=this.nonDisplayed_[this.row_].text;Se+=pe,this.nonDisplayed_[this.row_].text=Se},ni.prototype.rollUp=function(re,pe){var Se=this.displayed_[this.row_].text;Se+=pe,this.displayed_[this.row_].text=Se},ni.prototype.shiftRowsUp_=function(){var re;for(re=0;re<this.topRow_;re++)this.displayed_[re]={text:"",indent:0,offset:0};for(re=this.row_+1;re<Bi+1;re++)this.displayed_[re]={text:"",indent:0,offset:0};for(re=this.topRow_;re<this.row_;re++)this.displayed_[re]=this.displayed_[re+1];this.displayed_[this.row_]={text:"",indent:0,offset:0}},ni.prototype.paintOn=function(re,pe){var Se=this.displayed_[this.row_].text;Se+=pe,this.displayed_[this.row_].text=Se};var pi={CaptionStream:ge,Cea608Stream:ni,Cea708Stream:gt},Ii={H264_STREAM_TYPE:27,ADTS_STREAM_TYPE:15,METADATA_STREAM_TYPE:21},Ci=n,zi=8589934592,qi=4294967296,Ai="shared",Oi=function(re,pe){var Se=1;for(re>pe&&(Se=-1);Math.abs(pe-re)>qi;)re+=Se*zi;return re},ki=function(re){var pe,Se;ki.prototype.init.call(this),this.type_=re||Ai,this.push=function(_e){if(_e.type==="metadata"){this.trigger("data",_e);return}this.type_!==Ai&&_e.type!==this.type_||(Se===void 0&&(Se=_e.dts),_e.dts=Oi(_e.dts,Se),_e.pts=Oi(_e.pts,Se),pe=_e.dts,this.trigger("data",_e))},this.flush=function(){Se=pe,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.discontinuity=function(){Se=void 0,pe=void 0},this.reset=function(){this.discontinuity(),this.trigger("reset")}};ki.prototype=new Ci;var Ti={TimestampRolloverStream:ki,handleRollover:Oi},wi=(re,pe,Se)=>{if(!re)return-1;for(var _e=Se;_e<re.length;_e++)if(re[_e]===pe)return _e;return-1},oi={typedArrayIndexOf:wi},zt=oi.typedArrayIndexOf,Qt={Iso88591:0,Utf16:1,Utf16be:2,Utf8:3},Si=function(re,pe,Se){var _e,Me="";for(_e=pe;_e<Se;_e++)Me+="%"+("00"+re[_e].toString(16)).slice(-2);return Me},mi=function(re,pe,Se){return decodeURIComponent(Si(re,pe,Se))},ai=function(re,pe,Se){return unescape(Si(re,pe,Se))},gi=function(re){return re[0]<<21|re[1]<<14|re[2]<<7|re[3]},Hi={APIC:function(re){var pe=1,Se,_e,Me="-->";re.data[0]===Qt.Utf8&&(Se=zt(re.data,0,pe),!(Se<0)&&(re.mimeType=ai(re.data,pe,Se),pe=Se+1,re.pictureType=re.data[pe],pe++,_e=zt(re.data,0,pe),!(_e<0)&&(re.description=mi(re.data,pe,_e),pe=_e+1,re.mimeType===Me?re.url=ai(re.data,pe,re.data.length):re.pictureData=re.data.subarray(pe,re.data.length))))},"T*":function(re){re.data[0]===Qt.Utf8&&(re.value=mi(re.data,1,re.data.length).replace(/\0*$/,""),re.values=re.value.split("\0"))},TXXX:function(re){var pe;re.data[0]===Qt.Utf8&&(pe=zt(re.data,0,1),pe!==-1&&(re.description=mi(re.data,1,pe),re.value=mi(re.data,pe+1,re.data.length).replace(/\0*$/,""),re.data=re.value))},"W*":function(re){re.url=ai(re.data,0,re.data.length).replace(/\0.*$/,"")},WXXX:function(re){var pe;re.data[0]===Qt.Utf8&&(pe=zt(re.data,0,1),pe!==-1&&(re.description=mi(re.data,1,pe),re.url=ai(re.data,pe+1,re.data.length).replace(/\0.*$/,"")))},PRIV:function(re){var pe;for(pe=0;pe<re.data.length;pe++)if(re.data[pe]===0){re.owner=ai(re.data,0,pe);break}re.privateData=re.data.subarray(pe+1),re.data=re.privateData}},or=function(re){var pe,Se,_e=10,Me=0,Fe=[];if(!(re.length<10||re[0]!==73||re[1]!==68||re[2]!==51)){Me=gi(re.subarray(6,10)),Me+=10;var dt=re[5]&64;dt&&(_e+=4,_e+=gi(re.subarray(10,14)),Me-=gi(re.subarray(16,20)));do{if(pe=gi(re.subarray(_e+4,_e+8)),pe<1)break;Se=String.fromCharCode(re[_e],re[_e+1],re[_e+2],re[_e+3]);var yt={id:Se,data:re.subarray(_e+10,_e+pe+10)};yt.key=yt.id,Hi[yt.id]?Hi[yt.id](yt):yt.id[0]==="T"?Hi["T*"](yt):yt.id[0]==="W"&&Hi["W*"](yt),Fe.push(yt),_e+=10,_e+=pe}while(_e<Me);return Fe}},nr={parseId3Frames:or,parseSyncSafeInteger:gi,frameParsers:Hi},Gi=n,Mt=Ii,er=nr,tr;tr=function(re){var pe={descriptor:re&&re.descriptor},Se=0,_e=[],Me=0,Fe;if(tr.prototype.init.call(this),this.dispatchType=Mt.METADATA_STREAM_TYPE.toString(16),pe.descriptor)for(Fe=0;Fe<pe.descriptor.length;Fe++)this.dispatchType+=("00"+pe.descriptor[Fe].toString(16)).slice(-2);this.push=function(dt){var yt,Tt,Rt,Zt,ci,Wi;if(dt.type==="timed-metadata"){if(dt.dataAlignmentIndicator&&(Me=0,_e.length=0),_e.length===0&&(dt.data.length<10||dt.data[0]!==73||dt.data[1]!==68||dt.data[2]!==51)){this.trigger("log",{level:"warn",message:"Skipping unrecognized metadata packet"});return}if(_e.push(dt),Me+=dt.data.byteLength,_e.length===1&&(Se=er.parseSyncSafeInteger(dt.data.subarray(6,10)),Se+=10),!(Me<Se)){for(yt={data:new Uint8Array(Se),frames:[],pts:_e[0].pts,dts:_e[0].dts},ci=0;ci<Se;)yt.data.set(_e[0].data.subarray(0,Se-ci),ci),ci+=_e[0].data.byteLength,Me-=_e[0].data.byteLength,_e.shift();Tt=10,yt.data[5]&64&&(Tt+=4,Tt+=er.parseSyncSafeInteger(yt.data.subarray(10,14)),Se-=er.parseSyncSafeInteger(yt.data.subarray(16,20)));do{if(Rt=er.parseSyncSafeInteger(yt.data.subarray(Tt+4,Tt+8)),Rt<1){this.trigger("log",{level:"warn",message:"Malformed ID3 frame encountered. Skipping remaining metadata parsing."});break}if(Wi=String.fromCharCode(yt.data[Tt],yt.data[Tt+1],yt.data[Tt+2],yt.data[Tt+3]),Zt={id:Wi,data:yt.data.subarray(Tt+10,Tt+Rt+10)},Zt.key=Zt.id,er.frameParsers[Zt.id]?er.frameParsers[Zt.id](Zt):Zt.id[0]==="T"?er.frameParsers["T*"](Zt):Zt.id[0]==="W"&&er.frameParsers["W*"](Zt),Zt.owner==="com.apple.streaming.transportStreamTimestamp"){var Pi=Zt.data,lr=(Pi[3]&1)<<30|Pi[4]<<22|Pi[5]<<14|Pi[6]<<6|Pi[7]>>>2;lr*=4,lr+=Pi[7]&3,Zt.timeStamp=lr,yt.pts===void 0&&yt.dts===void 0&&(yt.pts=Zt.timeStamp,yt.dts=Zt.timeStamp),this.trigger("timestamp",Zt)}yt.frames.push(Zt),Tt+=10,Tt+=Rt}while(Tt<Se);this.trigger("data",yt)}}}},tr.prototype=new Gi;var br=tr,le=n,we=pi,$e=Ii,Oe=Ti.TimestampRolloverStream,Ge,st,xe,Ee=188,Ie=71;Ge=function(){var re=new Uint8Array(Ee),pe=0;Ge.prototype.init.call(this),this.push=function(Se){var _e=0,Me=Ee,Fe;for(pe?(Fe=new Uint8Array(Se.byteLength+pe),Fe.set(re.subarray(0,pe)),Fe.set(Se,pe),pe=0):Fe=Se;Me<Fe.byteLength;){if(Fe[_e]===Ie&&Fe[Me]===Ie){this.trigger("data",Fe.subarray(_e,Me)),_e+=Ee,Me+=Ee;continue}_e++,Me++}_e<Fe.byteLength&&(re.set(Fe.subarray(_e),0),pe=Fe.byteLength-_e)},this.flush=function(){pe===Ee&&re[0]===Ie&&(this.trigger("data",re),pe=0),this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.reset=function(){pe=0,this.trigger("reset")}},Ge.prototype=new le,st=function(){var re,pe,Se,_e;st.prototype.init.call(this),_e=this,this.packetsWaitingForPmt=[],this.programMapTable=void 0,re=function(Me,Fe){var dt=0;Fe.payloadUnitStartIndicator&&(dt+=Me[dt]+1),Fe.type==="pat"?pe(Me.subarray(dt),Fe):Se(Me.subarray(dt),Fe)},pe=function(Me,Fe){Fe.section_number=Me[7],Fe.last_section_number=Me[8],_e.pmtPid=(Me[10]&31)<<8|Me[11],Fe.pmtPid=_e.pmtPid},Se=function(Me,Fe){var dt,yt,Tt,Rt;if(Me[5]&1){for(_e.programMapTable={video:null,audio:null,"timed-metadata":{}},dt=(Me[1]&15)<<8|Me[2],yt=3+dt-4,Tt=(Me[10]&15)<<8|Me[11],Rt=12+Tt;Rt<yt;){var Zt=Me[Rt],ci=(Me[Rt+1]&31)<<8|Me[Rt+2];Zt===$e.H264_STREAM_TYPE&&_e.programMapTable.video===null?_e.programMapTable.video=ci:Zt===$e.ADTS_STREAM_TYPE&&_e.programMapTable.audio===null?_e.programMapTable.audio=ci:Zt===$e.METADATA_STREAM_TYPE&&(_e.programMapTable["timed-metadata"][ci]=Zt),Rt+=((Me[Rt+3]&15)<<8|Me[Rt+4])+5}Fe.programMapTable=_e.programMapTable}},this.push=function(Me){var Fe={},dt=4;if(Fe.payloadUnitStartIndicator=!!(Me[1]&64),Fe.pid=Me[1]&31,Fe.pid<<=8,Fe.pid|=Me[2],(Me[3]&48)>>>4>1&&(dt+=Me[dt]+1),Fe.pid===0)Fe.type="pat",re(Me.subarray(dt),Fe),this.trigger("data",Fe);else if(Fe.pid===this.pmtPid)for(Fe.type="pmt",re(Me.subarray(dt),Fe),this.trigger("data",Fe);this.packetsWaitingForPmt.length;)this.processPes_.apply(this,this.packetsWaitingForPmt.shift());else this.programMapTable===void 0?this.packetsWaitingForPmt.push([Me,dt,Fe]):this.processPes_(Me,dt,Fe)},this.processPes_=function(Me,Fe,dt){dt.pid===this.programMapTable.video?dt.streamType=$e.H264_STREAM_TYPE:dt.pid===this.programMapTable.audio?dt.streamType=$e.ADTS_STREAM_TYPE:dt.streamType=this.programMapTable["timed-metadata"][dt.pid],dt.type="pes",dt.data=Me.subarray(Fe),this.trigger("data",dt)}},st.prototype=new le,st.STREAM_TYPES={h264:27,adts:15},xe=function(){var re=this,pe=!1,Se={data:[],size:0},_e={data:[],size:0},Me={data:[],size:0},Fe,dt=function(Tt,Rt){var Zt;const ci=Tt[0]<<16|Tt[1]<<8|Tt[2];Rt.data=new Uint8Array,ci===1&&(Rt.packetLength=6+(Tt[4]<<8|Tt[5]),Rt.dataAlignmentIndicator=(Tt[6]&4)!==0,Zt=Tt[7],Zt&192&&(Rt.pts=(Tt[9]&14)<<27|(Tt[10]&255)<<20|(Tt[11]&254)<<12|(Tt[12]&255)<<5|(Tt[13]&254)>>>3,Rt.pts*=4,Rt.pts+=(Tt[13]&6)>>>1,Rt.dts=Rt.pts,Zt&64&&(Rt.dts=(Tt[14]&14)<<27|(Tt[15]&255)<<20|(Tt[16]&254)<<12|(Tt[17]&255)<<5|(Tt[18]&254)>>>3,Rt.dts*=4,Rt.dts+=(Tt[18]&6)>>>1)),Rt.data=Tt.subarray(9+Tt[8]))},yt=function(Tt,Rt,Zt){var ci=new Uint8Array(Tt.size),Wi={type:Rt},Pi=0,lr=0,et=!1,Fr;if(!(!Tt.data.length||Tt.size<9)){for(Wi.trackId=Tt.data[0].pid,Pi=0;Pi<Tt.data.length;Pi++)Fr=Tt.data[Pi],ci.set(Fr.data,lr),lr+=Fr.data.byteLength;dt(ci,Wi),et=Rt==="video"||Wi.packetLength<=Tt.size,(Zt||et)&&(Tt.size=0,Tt.data.length=0),et&&re.trigger("data",Wi)}};xe.prototype.init.call(this),this.push=function(Tt){({pat:function(){},pes:function(){var Rt,Zt;switch(Tt.streamType){case $e.H264_STREAM_TYPE:Rt=Se,Zt="video";break;case $e.ADTS_STREAM_TYPE:Rt=_e,Zt="audio";break;case $e.METADATA_STREAM_TYPE:Rt=Me,Zt="timed-metadata";break;default:return}Tt.payloadUnitStartIndicator&&yt(Rt,Zt,!0),Rt.data.push(Tt),Rt.size+=Tt.data.byteLength},pmt:function(){var Rt={type:"metadata",tracks:[]};Fe=Tt.programMapTable,Fe.video!==null&&Rt.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+Fe.video,codec:"avc",type:"video"}),Fe.audio!==null&&Rt.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+Fe.audio,codec:"adts",type:"audio"}),pe=!0,re.trigger("data",Rt)}})[Tt.type]()},this.reset=function(){Se.size=0,Se.data.length=0,_e.size=0,_e.data.length=0,this.trigger("reset")},this.flushStreams_=function(){yt(Se,"video"),yt(_e,"audio"),yt(Me,"timed-metadata")},this.flush=function(){if(!pe&&Fe){var Tt={type:"metadata",tracks:[]};Fe.video!==null&&Tt.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+Fe.video,codec:"avc",type:"video"}),Fe.audio!==null&&Tt.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+Fe.audio,codec:"adts",type:"audio"}),re.trigger("data",Tt)}pe=!1,this.flushStreams_(),this.trigger("done")}},xe.prototype=new le;var Xe={PAT_PID:0,MP2T_PACKET_LENGTH:Ee,TransportPacketStream:Ge,TransportParseStream:st,ElementaryStream:xe,TimestampRolloverStream:Oe,CaptionStream:we.CaptionStream,Cea608Stream:we.Cea608Stream,Cea708Stream:we.Cea708Stream,MetadataStream:br};for(var xt in $e)$e.hasOwnProperty(xt)&&(Xe[xt]=$e[xt]);var Lt=Xe,Ft=n,jt=ye.ONE_SECOND_IN_TS,si,yi=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];si=function(re){var pe,Se=0;si.prototype.init.call(this),this.skipWarn_=function(_e,Me){this.trigger("log",{level:"warn",message:`adts skiping bytes ${_e} to ${Me} in frame ${Se} outside syncword`})},this.push=function(_e){var Me=0,Fe,dt,yt,Tt,Rt;if(re||(Se=0),_e.type==="audio"){pe&&pe.length?(yt=pe,pe=new Uint8Array(yt.byteLength+_e.data.byteLength),pe.set(yt),pe.set(_e.data,yt.byteLength)):pe=_e.data;for(var Zt;Me+7<pe.length;){if(pe[Me]!==255||(pe[Me+1]&246)!==240){typeof Zt!="number"&&(Zt=Me),Me++;continue}if(typeof Zt=="number"&&(this.skipWarn_(Zt,Me),Zt=null),dt=(~pe[Me+1]&1)*2,Fe=(pe[Me+3]&3)<<11|pe[Me+4]<<3|(pe[Me+5]&224)>>5,Tt=((pe[Me+6]&3)+1)*1024,Rt=Tt*jt/yi[(pe[Me+2]&60)>>>2],pe.byteLength-Me<Fe)break;this.trigger("data",{pts:_e.pts+Se*Rt,dts:_e.dts+Se*Rt,sampleCount:Tt,audioobjecttype:(pe[Me+2]>>>6&3)+1,channelcount:(pe[Me+2]&1)<<2|(pe[Me+3]&192)>>>6,samplerate:yi[(pe[Me+2]&60)>>>2],samplingfrequencyindex:(pe[Me+2]&60)>>>2,samplesize:16,data:pe.subarray(Me+7+dt,Me+Fe)}),Se++,Me+=Fe}typeof Zt=="number"&&(this.skipWarn_(Zt,Me),Zt=null),pe=pe.subarray(Me)}},this.flush=function(){Se=0,this.trigger("done")},this.reset=function(){pe=void 0,this.trigger("reset")},this.endTimeline=function(){pe=void 0,this.trigger("endedtimeline")}},si.prototype=new Ft;var vi=si,li;li=function(re){var pe=re.byteLength,Se=0,_e=0;this.length=function(){return 8*pe},this.bitsAvailable=function(){return 8*pe+_e},this.loadWord=function(){var Me=re.byteLength-pe,Fe=new Uint8Array(4),dt=Math.min(4,pe);if(dt===0)throw new Error("no bytes available");Fe.set(re.subarray(Me,Me+dt)),Se=new DataView(Fe.buffer).getUint32(0),_e=dt*8,pe-=dt},this.skipBits=function(Me){var Fe;_e>Me?(Se<<=Me,_e-=Me):(Me-=_e,Fe=Math.floor(Me/8),Me-=Fe*8,pe-=Fe,this.loadWord(),Se<<=Me,_e-=Me)},this.readBits=function(Me){var Fe=Math.min(_e,Me),dt=Se>>>32-Fe;return _e-=Fe,_e>0?Se<<=Fe:pe>0&&this.loadWord(),Fe=Me-Fe,Fe>0?dt<<Fe|this.readBits(Fe):dt},this.skipLeadingZeros=function(){var Me;for(Me=0;Me<_e;++Me)if(Se&2147483648>>>Me)return Se<<=Me,_e-=Me,Me;return this.loadWord(),Me+this.skipLeadingZeros()},this.skipUnsignedExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.skipExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.readUnsignedExpGolomb=function(){var Me=this.skipLeadingZeros();return this.readBits(Me+1)-1},this.readExpGolomb=function(){var Me=this.readUnsignedExpGolomb();return 1&Me?1+Me>>>1:-1*(Me>>>1)},this.readBoolean=function(){return this.readBits(1)===1},this.readUnsignedByte=function(){return this.readBits(8)},this.loadWord()};var Vi=li,Ei=n,$i=Vi,xi,ir,Ji;ir=function(){var re=0,pe,Se;ir.prototype.init.call(this),this.push=function(_e){var Me;Se?(Me=new Uint8Array(Se.byteLength+_e.data.byteLength),Me.set(Se),Me.set(_e.data,Se.byteLength),Se=Me):Se=_e.data;for(var Fe=Se.byteLength;re<Fe-3;re++)if(Se[re+2]===1){pe=re+5;break}for(;pe<Fe;)switch(Se[pe]){case 0:if(Se[pe-1]!==0){pe+=2;break}else if(Se[pe-2]!==0){pe++;break}re+3!==pe-2&&this.trigger("data",Se.subarray(re+3,pe-2));do pe++;while(Se[pe]!==1&&pe<Fe);re=pe-2,pe+=3;break;case 1:if(Se[pe-1]!==0||Se[pe-2]!==0){pe+=3;break}this.trigger("data",Se.subarray(re+3,pe-2)),re=pe-2,pe+=3;break;default:pe+=3;break}Se=Se.subarray(re),pe-=re,re=0},this.reset=function(){Se=null,re=0,this.trigger("reset")},this.flush=function(){Se&&Se.byteLength>3&&this.trigger("data",Se.subarray(re+3)),Se=null,re=0,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")}},ir.prototype=new Ei,Ji={100:!0,110:!0,122:!0,244:!0,44:!0,83:!0,86:!0,118:!0,128:!0,138:!0,139:!0,134:!0},xi=function(){var re=new ir,pe,Se,_e,Me,Fe,dt,yt;xi.prototype.init.call(this),pe=this,this.push=function(Tt){Tt.type==="video"&&(Se=Tt.trackId,_e=Tt.pts,Me=Tt.dts,re.push(Tt))},re.on("data",function(Tt){var Rt={trackId:Se,pts:_e,dts:Me,data:Tt,nalUnitTypeCode:Tt[0]&31};switch(Rt.nalUnitTypeCode){case 5:Rt.nalUnitType="slice_layer_without_partitioning_rbsp_idr";break;case 6:Rt.nalUnitType="sei_rbsp",Rt.escapedRBSP=Fe(Tt.subarray(1));break;case 7:Rt.nalUnitType="seq_parameter_set_rbsp",Rt.escapedRBSP=Fe(Tt.subarray(1)),Rt.config=dt(Rt.escapedRBSP);break;case 8:Rt.nalUnitType="pic_parameter_set_rbsp";break;case 9:Rt.nalUnitType="access_unit_delimiter_rbsp";break}pe.trigger("data",Rt)}),re.on("done",function(){pe.trigger("done")}),re.on("partialdone",function(){pe.trigger("partialdone")}),re.on("reset",function(){pe.trigger("reset")}),re.on("endedtimeline",function(){pe.trigger("endedtimeline")}),this.flush=function(){re.flush()},this.partialFlush=function(){re.partialFlush()},this.reset=function(){re.reset()},this.endTimeline=function(){re.endTimeline()},yt=function(Tt,Rt){var Zt=8,ci=8,Wi,Pi;for(Wi=0;Wi<Tt;Wi++)ci!==0&&(Pi=Rt.readExpGolomb(),ci=(Zt+Pi+256)%256),Zt=ci===0?Zt:ci},Fe=function(Tt){for(var Rt=Tt.byteLength,Zt=[],ci=1,Wi,Pi;ci<Rt-2;)Tt[ci]===0&&Tt[ci+1]===0&&Tt[ci+2]===3?(Zt.push(ci+2),ci+=2):ci++;if(Zt.length===0)return Tt;Wi=Rt-Zt.length,Pi=new Uint8Array(Wi);var lr=0;for(ci=0;ci<Wi;lr++,ci++)lr===Zt[0]&&(lr++,Zt.shift()),Pi[ci]=Tt[lr];return Pi},dt=function(Tt){var Rt=0,Zt=0,ci=0,Wi=0,Pi,lr,et,Fr,hn,Xr,Ar,Fs,Ns,_s,ga,Nr=[1,1],qs,Ea;if(Pi=new $i(Tt),lr=Pi.readUnsignedByte(),Fr=Pi.readUnsignedByte(),et=Pi.readUnsignedByte(),Pi.skipUnsignedExpGolomb(),Ji[lr]&&(hn=Pi.readUnsignedExpGolomb(),hn===3&&Pi.skipBits(1),Pi.skipUnsignedExpGolomb(),Pi.skipUnsignedExpGolomb(),Pi.skipBits(1),Pi.readBoolean()))for(ga=hn!==3?8:12,Ea=0;Ea<ga;Ea++)Pi.readBoolean()&&(Ea<6?yt(16,Pi):yt(64,Pi));if(Pi.skipUnsignedExpGolomb(),Xr=Pi.readUnsignedExpGolomb(),Xr===0)Pi.readUnsignedExpGolomb();else if(Xr===1)for(Pi.skipBits(1),Pi.skipExpGolomb(),Pi.skipExpGolomb(),Ar=Pi.readUnsignedExpGolomb(),Ea=0;Ea<Ar;Ea++)Pi.skipExpGolomb();if(Pi.skipUnsignedExpGolomb(),Pi.skipBits(1),Fs=Pi.readUnsignedExpGolomb(),Ns=Pi.readUnsignedExpGolomb(),_s=Pi.readBits(1),_s===0&&Pi.skipBits(1),Pi.skipBits(1),Pi.readBoolean()&&(Rt=Pi.readUnsignedExpGolomb(),Zt=Pi.readUnsignedExpGolomb(),ci=Pi.readUnsignedExpGolomb(),Wi=Pi.readUnsignedExpGolomb()),Pi.readBoolean()&&Pi.readBoolean()){switch(qs=Pi.readUnsignedByte(),qs){case 1:Nr=[1,1];break;case 2:Nr=[12,11];break;case 3:Nr=[10,11];break;case 4:Nr=[16,11];break;case 5:Nr=[40,33];break;case 6:Nr=[24,11];break;case 7:Nr=[20,11];break;case 8:Nr=[32,11];break;case 9:Nr=[80,33];break;case 10:Nr=[18,11];break;case 11:Nr=[15,11];break;case 12:Nr=[64,33];break;case 13:Nr=[160,99];break;case 14:Nr=[4,3];break;case 15:Nr=[3,2];break;case 16:Nr=[2,1];break;case 255:{Nr=[Pi.readUnsignedByte()<<8|Pi.readUnsignedByte(),Pi.readUnsignedByte()<<8|Pi.readUnsignedByte()];break}}Nr&&Nr[0]/Nr[1]}return{profileIdc:lr,levelIdc:et,profileCompatibility:Fr,width:(Fs+1)*16-Rt*2-Zt*2,height:(2-_s)*(Ns+1)*16-ci*2-Wi*2,sarRatio:Nr}}},xi.prototype=new Ei;var ur={H264Stream:xi,NalByteStream:ir},zn=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],Un=function(re,pe){var Se=re[pe+6]<<21|re[pe+7]<<14|re[pe+8]<<7|re[pe+9],_e=re[pe+5],Me=(_e&16)>>4;return Se=Se>=0?Se:0,Me?Se+20:Se+10},_r=function(re,pe){return re.length-pe<10||re[pe]!==73||re[pe+1]!==68||re[pe+2]!==51?pe:(pe+=Un(re,pe),_r(re,pe))},xr=function(re){var pe=_r(re,0);return re.length>=pe+2&&(re[pe]&255)===255&&(re[pe+1]&240)===240&&(re[pe+1]&22)===16},En=function(re){return re[0]<<21|re[1]<<14|re[2]<<7|re[3]},kn=function(re,pe,Se){var _e,Me="";for(_e=pe;_e<Se;_e++)Me+="%"+("00"+re[_e].toString(16)).slice(-2);return Me},ia=function(re,pe,Se){return unescape(kn(re,pe,Se))},pn=function(re,pe){var Se=(re[pe+5]&224)>>5,_e=re[pe+4]<<3,Me=re[pe+3]&6144;return Me|_e|Se},yn=function(re,pe){return re[pe]===73&&re[pe+1]===68&&re[pe+2]===51?"timed-metadata":re[pe]&!0&&(re[pe+1]&240)===240?"audio":null},ca=function(re){for(var pe=0;pe+5<re.length;){if(re[pe]!==255||(re[pe+1]&246)!==240){pe++;continue}return zn[(re[pe+2]&60)>>>2]}return null},_a=function(re){var pe,Se,_e,Me;pe=10,re[5]&64&&(pe+=4,pe+=En(re.subarray(10,14)));do{if(Se=En(re.subarray(pe+4,pe+8)),Se<1)return null;if(Me=String.fromCharCode(re[pe],re[pe+1],re[pe+2],re[pe+3]),Me==="PRIV"){_e=re.subarray(pe+10,pe+Se+10);for(var Fe=0;Fe<_e.byteLength;Fe++)if(_e[Fe]===0){var dt=ia(_e,0,Fe);if(dt==="com.apple.streaming.transportStreamTimestamp"){var yt=_e.subarray(Fe+1),Tt=(yt[3]&1)<<30|yt[4]<<22|yt[5]<<14|yt[6]<<6|yt[7]>>>2;return Tt*=4,Tt+=yt[7]&3,Tt}break}}pe+=10,pe+=Se}while(pe<re.byteLength);return null},fa={isLikelyAacData:xr,parseId3TagSize:Un,parseAdtsSize:pn,parseType:yn,parseSampleRate:ca,parseAacTimestamp:_a},$r=n,Hn=fa,Zr;Zr=function(){var re=new Uint8Array,pe=0;Zr.prototype.init.call(this),this.setTimestamp=function(Se){pe=Se},this.push=function(Se){var _e=0,Me=0,Fe,dt,yt,Tt;for(re.length?(Tt=re.length,re=new Uint8Array(Se.byteLength+Tt),re.set(re.subarray(0,Tt)),re.set(Se,Tt)):re=Se;re.length-Me>=3;){if(re[Me]===73&&re[Me+1]===68&&re[Me+2]===51){if(re.length-Me<10||(_e=Hn.parseId3TagSize(re,Me),Me+_e>re.length))break;dt={type:"timed-metadata",data:re.subarray(Me,Me+_e)},this.trigger("data",dt),Me+=_e;continue}else if((re[Me]&255)===255&&(re[Me+1]&240)===240){if(re.length-Me<7||(_e=Hn.parseAdtsSize(re,Me),Me+_e>re.length))break;yt={type:"audio",data:re.subarray(Me,Me+_e),pts:pe,dts:pe},this.trigger("data",yt),Me+=_e;continue}Me++}Fe=re.length-Me,Fe>0?re=re.subarray(Me):re=new Uint8Array},this.reset=function(){re=new Uint8Array,this.trigger("reset")},this.endTimeline=function(){re=new Uint8Array,this.trigger("endedtimeline")}},Zr.prototype=new $r;var xa=Zr,mn=["audioobjecttype","channelcount","samplerate","samplingfrequencyindex","samplesize"],tn=mn,X=["width","height","profileIdc","levelIdc","profileCompatibility","sarRatio"],ae=X,Te=n,Pe=U,ze=Ct,He=ve,Ze=ut,It=Lt,St=ye,Kt=vi,di=ur.H264Stream,bi=xa,ri=fa.isLikelyAacData,Ni=ye.ONE_SECOND_IN_TS,Ki=tn,yr=ae,fr,jr,Or,Qr,Cn=function(re,pe){pe.stream=re,this.trigger("log",pe)},Tr=function(re,pe){for(var Se=Object.keys(pe),_e=0;_e<Se.length;_e++){var Me=Se[_e];Me==="headOfPipeline"||!pe[Me].on||pe[Me].on("log",Cn.bind(re,Me))}},$n=function(re,pe){var Se;if(re.length!==pe.length)return!1;for(Se=0;Se<re.length;Se++)if(re[Se]!==pe[Se])return!1;return!0},Sr=function(re,pe,Se,_e,Me,Fe){var dt=Se-pe,yt=_e-pe,Tt=Me-Se;return{start:{dts:re,pts:re+dt},end:{dts:re+yt,pts:re+Tt},prependedContentDuration:Fe,baseMediaDecodeTime:re}};jr=function(re,pe){var Se=[],_e,Me=0,Fe=0,dt=1/0;pe=pe||{},_e=pe.firstSequenceNumber||0,jr.prototype.init.call(this),this.push=function(yt){Ze.collectDtsInfo(re,yt),re&&Ki.forEach(function(Tt){re[Tt]=yt[Tt]}),Se.push(yt)},this.setEarliestDts=function(yt){Me=yt},this.setVideoBaseMediaDecodeTime=function(yt){dt=yt},this.setAudioAppendStart=function(yt){Fe=yt},this.flush=function(){var yt,Tt,Rt,Zt,ci,Wi,Pi;if(Se.length===0){this.trigger("done","AudioSegmentStream");return}yt=He.trimAdtsFramesByEarliestDts(Se,re,Me),re.baseMediaDecodeTime=Ze.calculateTrackBaseMediaDecodeTime(re,pe.keepOriginalTimestamps),Pi=He.prefixWithSilence(re,yt,Fe,dt),re.samples=He.generateSampleTable(yt),Rt=Pe.mdat(He.concatenateFrameData(yt)),Se=[],Tt=Pe.moof(_e,[re]),Zt=new Uint8Array(Tt.byteLength+Rt.byteLength),_e++,Zt.set(Tt),Zt.set(Rt,Tt.byteLength),Ze.clearDtsInfo(re),ci=Math.ceil(Ni*1024/re.samplerate),yt.length&&(Wi=yt.length*ci,this.trigger("segmentTimingInfo",Sr(St.audioTsToVideoTs(re.baseMediaDecodeTime,re.samplerate),yt[0].dts,yt[0].pts,yt[0].dts+Wi,yt[0].pts+Wi,Pi||0)),this.trigger("timingInfo",{start:yt[0].pts,end:yt[0].pts+Wi})),this.trigger("data",{track:re,boxes:Zt}),this.trigger("done","AudioSegmentStream")},this.reset=function(){Ze.clearDtsInfo(re),Se=[],this.trigger("reset")}},jr.prototype=new Te,fr=function(re,pe){var Se,_e=[],Me=[],Fe,dt;pe=pe||{},Se=pe.firstSequenceNumber||0,fr.prototype.init.call(this),delete re.minPTS,this.gopCache_=[],this.push=function(yt){Ze.collectDtsInfo(re,yt),yt.nalUnitType==="seq_parameter_set_rbsp"&&!Fe&&(Fe=yt.config,re.sps=[yt.data],yr.forEach(function(Tt){re[Tt]=Fe[Tt]},this)),yt.nalUnitType==="pic_parameter_set_rbsp"&&!dt&&(dt=yt.data,re.pps=[yt.data]),_e.push(yt)},this.flush=function(){for(var yt,Tt,Rt,Zt,ci,Wi,Pi=0,lr,et;_e.length&&_e[0].nalUnitType!=="access_unit_delimiter_rbsp";)_e.shift();if(_e.length===0){this.resetStream_(),this.trigger("done","VideoSegmentStream");return}if(yt=ze.groupNalsIntoFrames(_e),Rt=ze.groupFramesIntoGops(yt),Rt[0][0].keyFrame||(Tt=this.getGopForFusion_(_e[0],re),Tt?(Pi=Tt.duration,Rt.unshift(Tt),Rt.byteLength+=Tt.byteLength,Rt.nalCount+=Tt.nalCount,Rt.pts=Tt.pts,Rt.dts=Tt.dts,Rt.duration+=Tt.duration):Rt=ze.extendFirstKeyFrame(Rt)),Me.length){var Fr;if(pe.alignGopsAtEnd?Fr=this.alignGopsAtEnd_(Rt):Fr=this.alignGopsAtStart_(Rt),!Fr){this.gopCache_.unshift({gop:Rt.pop(),pps:re.pps,sps:re.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),_e=[],this.resetStream_(),this.trigger("done","VideoSegmentStream");return}Ze.clearDtsInfo(re),Rt=Fr}Ze.collectDtsInfo(re,Rt),re.samples=ze.generateSampleTable(Rt),ci=Pe.mdat(ze.concatenateNalData(Rt)),re.baseMediaDecodeTime=Ze.calculateTrackBaseMediaDecodeTime(re,pe.keepOriginalTimestamps),this.trigger("processedGopsInfo",Rt.map(function(hn){return{pts:hn.pts,dts:hn.dts,byteLength:hn.byteLength}})),lr=Rt[0],et=Rt[Rt.length-1],this.trigger("segmentTimingInfo",Sr(re.baseMediaDecodeTime,lr.dts,lr.pts,et.dts+et.duration,et.pts+et.duration,Pi)),this.trigger("timingInfo",{start:Rt[0].pts,end:Rt[Rt.length-1].pts+Rt[Rt.length-1].duration}),this.gopCache_.unshift({gop:Rt.pop(),pps:re.pps,sps:re.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),_e=[],this.trigger("baseMediaDecodeTime",re.baseMediaDecodeTime),this.trigger("timelineStartInfo",re.timelineStartInfo),Zt=Pe.moof(Se,[re]),Wi=new Uint8Array(Zt.byteLength+ci.byteLength),Se++,Wi.set(Zt),Wi.set(ci,Zt.byteLength),this.trigger("data",{track:re,boxes:Wi}),this.resetStream_(),this.trigger("done","VideoSegmentStream")},this.reset=function(){this.resetStream_(),_e=[],this.gopCache_.length=0,Me.length=0,this.trigger("reset")},this.resetStream_=function(){Ze.clearDtsInfo(re),Fe=void 0,dt=void 0},this.getGopForFusion_=function(yt){var Tt=45e3,Rt=1e4,Zt=1/0,ci,Wi,Pi,lr,et;for(et=0;et<this.gopCache_.length;et++)lr=this.gopCache_[et],Pi=lr.gop,!(!(re.pps&&$n(re.pps[0],lr.pps[0]))||!(re.sps&&$n(re.sps[0],lr.sps[0])))&&(Pi.dts<re.timelineStartInfo.dts||(ci=yt.dts-Pi.dts-Pi.duration,ci>=-Rt&&ci<=Tt&&(!Wi||Zt>ci)&&(Wi=lr,Zt=ci)));return Wi?Wi.gop:null},this.alignGopsAtStart_=function(yt){var Tt,Rt,Zt,ci,Wi,Pi,lr,et;for(Wi=yt.byteLength,Pi=yt.nalCount,lr=yt.duration,Tt=Rt=0;Tt<Me.length&&Rt<yt.length&&(Zt=Me[Tt],ci=yt[Rt],Zt.pts!==ci.pts);){if(ci.pts>Zt.pts){Tt++;continue}Rt++,Wi-=ci.byteLength,Pi-=ci.nalCount,lr-=ci.duration}return Rt===0?yt:Rt===yt.length?null:(et=yt.slice(Rt),et.byteLength=Wi,et.duration=lr,et.nalCount=Pi,et.pts=et[0].pts,et.dts=et[0].dts,et)},this.alignGopsAtEnd_=function(yt){var Tt,Rt,Zt,ci,Wi,Pi;for(Tt=Me.length-1,Rt=yt.length-1,Wi=null,Pi=!1;Tt>=0&&Rt>=0;){if(Zt=Me[Tt],ci=yt[Rt],Zt.pts===ci.pts){Pi=!0;break}if(Zt.pts>ci.pts){Tt--;continue}Tt===Me.length-1&&(Wi=Rt),Rt--}if(!Pi&&Wi===null)return null;var lr;if(Pi?lr=Rt:lr=Wi,lr===0)return yt;var et=yt.slice(lr),Fr=et.reduce(function(hn,Xr){return hn.byteLength+=Xr.byteLength,hn.duration+=Xr.duration,hn.nalCount+=Xr.nalCount,hn},{byteLength:0,duration:0,nalCount:0});return et.byteLength=Fr.byteLength,et.duration=Fr.duration,et.nalCount=Fr.nalCount,et.pts=et[0].pts,et.dts=et[0].dts,et},this.alignGopsWith=function(yt){Me=yt}},fr.prototype=new Te,Qr=function(re,pe){this.numberOfTracks=0,this.metadataStream=pe,re=re||{},typeof re.remux<"u"?this.remuxTracks=!!re.remux:this.remuxTracks=!0,typeof re.keepOriginalTimestamps=="boolean"?this.keepOriginalTimestamps=re.keepOriginalTimestamps:this.keepOriginalTimestamps=!1,this.pendingTracks=[],this.videoTrack=null,this.pendingBoxes=[],this.pendingCaptions=[],this.pendingMetadata=[],this.pendingBytes=0,this.emittedTracks=0,Qr.prototype.init.call(this),this.push=function(Se){if(Se.content||Se.text)return this.pendingCaptions.push(Se);if(Se.frames)return this.pendingMetadata.push(Se);this.pendingTracks.push(Se.track),this.pendingBytes+=Se.boxes.byteLength,Se.track.type==="video"&&(this.videoTrack=Se.track,this.pendingBoxes.push(Se.boxes)),Se.track.type==="audio"&&(this.audioTrack=Se.track,this.pendingBoxes.unshift(Se.boxes))}},Qr.prototype=new Te,Qr.prototype.flush=function(re){var pe=0,Se={captions:[],captionStreams:{},metadata:[],info:{}},_e,Me,Fe,dt=0,yt;if(this.pendingTracks.length<this.numberOfTracks){if(re!=="VideoSegmentStream"&&re!=="AudioSegmentStream")return;if(this.remuxTracks)return;if(this.pendingTracks.length===0){this.emittedTracks++,this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0);return}}if(this.videoTrack?(dt=this.videoTrack.timelineStartInfo.pts,yr.forEach(function(Tt){Se.info[Tt]=this.videoTrack[Tt]},this)):this.audioTrack&&(dt=this.audioTrack.timelineStartInfo.pts,Ki.forEach(function(Tt){Se.info[Tt]=this.audioTrack[Tt]},this)),this.videoTrack||this.audioTrack){for(this.pendingTracks.length===1?Se.type=this.pendingTracks[0].type:Se.type="combined",this.emittedTracks+=this.pendingTracks.length,Fe=Pe.initSegment(this.pendingTracks),Se.initSegment=new Uint8Array(Fe.byteLength),Se.initSegment.set(Fe),Se.data=new Uint8Array(this.pendingBytes),yt=0;yt<this.pendingBoxes.length;yt++)Se.data.set(this.pendingBoxes[yt],pe),pe+=this.pendingBoxes[yt].byteLength;for(yt=0;yt<this.pendingCaptions.length;yt++)_e=this.pendingCaptions[yt],_e.startTime=St.metadataTsToSeconds(_e.startPts,dt,this.keepOriginalTimestamps),_e.endTime=St.metadataTsToSeconds(_e.endPts,dt,this.keepOriginalTimestamps),Se.captionStreams[_e.stream]=!0,Se.captions.push(_e);for(yt=0;yt<this.pendingMetadata.length;yt++)Me=this.pendingMetadata[yt],Me.cueTime=St.metadataTsToSeconds(Me.pts,dt,this.keepOriginalTimestamps),Se.metadata.push(Me);for(Se.metadata.dispatchType=this.metadataStream.dispatchType,this.pendingTracks.length=0,this.videoTrack=null,this.pendingBoxes.length=0,this.pendingCaptions.length=0,this.pendingBytes=0,this.pendingMetadata.length=0,this.trigger("data",Se),yt=0;yt<Se.captions.length;yt++)_e=Se.captions[yt],this.trigger("caption",_e);for(yt=0;yt<Se.metadata.length;yt++)Me=Se.metadata[yt],this.trigger("id3Frame",Me)}this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0)},Qr.prototype.setRemux=function(re){this.remuxTracks=re},Or=function(re){var pe=this,Se=!0,_e,Me;Or.prototype.init.call(this),re=re||{},this.baseMediaDecodeTime=re.baseMediaDecodeTime||0,this.transmuxPipeline_={},this.setupAacPipeline=function(){var Fe={};this.transmuxPipeline_=Fe,Fe.type="aac",Fe.metadataStream=new It.MetadataStream,Fe.aacStream=new bi,Fe.audioTimestampRolloverStream=new It.TimestampRolloverStream("audio"),Fe.timedMetadataTimestampRolloverStream=new It.TimestampRolloverStream("timed-metadata"),Fe.adtsStream=new Kt,Fe.coalesceStream=new Qr(re,Fe.metadataStream),Fe.headOfPipeline=Fe.aacStream,Fe.aacStream.pipe(Fe.audioTimestampRolloverStream).pipe(Fe.adtsStream),Fe.aacStream.pipe(Fe.timedMetadataTimestampRolloverStream).pipe(Fe.metadataStream).pipe(Fe.coalesceStream),Fe.metadataStream.on("timestamp",function(dt){Fe.aacStream.setTimestamp(dt.timeStamp)}),Fe.aacStream.on("data",function(dt){dt.type!=="timed-metadata"&&dt.type!=="audio"||Fe.audioSegmentStream||(Me=Me||{timelineStartInfo:{baseMediaDecodeTime:pe.baseMediaDecodeTime},codec:"adts",type:"audio"},Fe.coalesceStream.numberOfTracks++,Fe.audioSegmentStream=new jr(Me,re),Fe.audioSegmentStream.on("log",pe.getLogTrigger_("audioSegmentStream")),Fe.audioSegmentStream.on("timingInfo",pe.trigger.bind(pe,"audioTimingInfo")),Fe.adtsStream.pipe(Fe.audioSegmentStream).pipe(Fe.coalesceStream),pe.trigger("trackinfo",{hasAudio:!!Me,hasVideo:!!_e}))}),Fe.coalesceStream.on("data",this.trigger.bind(this,"data")),Fe.coalesceStream.on("done",this.trigger.bind(this,"done")),Tr(this,Fe)},this.setupTsPipeline=function(){var Fe={};this.transmuxPipeline_=Fe,Fe.type="ts",Fe.metadataStream=new It.MetadataStream,Fe.packetStream=new It.TransportPacketStream,Fe.parseStream=new It.TransportParseStream,Fe.elementaryStream=new It.ElementaryStream,Fe.timestampRolloverStream=new It.TimestampRolloverStream,Fe.adtsStream=new Kt,Fe.h264Stream=new di,Fe.captionStream=new It.CaptionStream(re),Fe.coalesceStream=new Qr(re,Fe.metadataStream),Fe.headOfPipeline=Fe.packetStream,Fe.packetStream.pipe(Fe.parseStream).pipe(Fe.elementaryStream).pipe(Fe.timestampRolloverStream),Fe.timestampRolloverStream.pipe(Fe.h264Stream),Fe.timestampRolloverStream.pipe(Fe.adtsStream),Fe.timestampRolloverStream.pipe(Fe.metadataStream).pipe(Fe.coalesceStream),Fe.h264Stream.pipe(Fe.captionStream).pipe(Fe.coalesceStream),Fe.elementaryStream.on("data",function(dt){var yt;if(dt.type==="metadata"){for(yt=dt.tracks.length;yt--;)!_e&&dt.tracks[yt].type==="video"?(_e=dt.tracks[yt],_e.timelineStartInfo.baseMediaDecodeTime=pe.baseMediaDecodeTime):!Me&&dt.tracks[yt].type==="audio"&&(Me=dt.tracks[yt],Me.timelineStartInfo.baseMediaDecodeTime=pe.baseMediaDecodeTime);_e&&!Fe.videoSegmentStream&&(Fe.coalesceStream.numberOfTracks++,Fe.videoSegmentStream=new fr(_e,re),Fe.videoSegmentStream.on("log",pe.getLogTrigger_("videoSegmentStream")),Fe.videoSegmentStream.on("timelineStartInfo",function(Tt){Me&&!re.keepOriginalTimestamps&&(Me.timelineStartInfo=Tt,Fe.audioSegmentStream.setEarliestDts(Tt.dts-pe.baseMediaDecodeTime))}),Fe.videoSegmentStream.on("processedGopsInfo",pe.trigger.bind(pe,"gopInfo")),Fe.videoSegmentStream.on("segmentTimingInfo",pe.trigger.bind(pe,"videoSegmentTimingInfo")),Fe.videoSegmentStream.on("baseMediaDecodeTime",function(Tt){Me&&Fe.audioSegmentStream.setVideoBaseMediaDecodeTime(Tt)}),Fe.videoSegmentStream.on("timingInfo",pe.trigger.bind(pe,"videoTimingInfo")),Fe.h264Stream.pipe(Fe.videoSegmentStream).pipe(Fe.coalesceStream)),Me&&!Fe.audioSegmentStream&&(Fe.coalesceStream.numberOfTracks++,Fe.audioSegmentStream=new jr(Me,re),Fe.audioSegmentStream.on("log",pe.getLogTrigger_("audioSegmentStream")),Fe.audioSegmentStream.on("timingInfo",pe.trigger.bind(pe,"audioTimingInfo")),Fe.audioSegmentStream.on("segmentTimingInfo",pe.trigger.bind(pe,"audioSegmentTimingInfo")),Fe.adtsStream.pipe(Fe.audioSegmentStream).pipe(Fe.coalesceStream)),pe.trigger("trackinfo",{hasAudio:!!Me,hasVideo:!!_e})}}),Fe.coalesceStream.on("data",this.trigger.bind(this,"data")),Fe.coalesceStream.on("id3Frame",function(dt){dt.dispatchType=Fe.metadataStream.dispatchType,pe.trigger("id3Frame",dt)}),Fe.coalesceStream.on("caption",this.trigger.bind(this,"caption")),Fe.coalesceStream.on("done",this.trigger.bind(this,"done")),Tr(this,Fe)},this.setBaseMediaDecodeTime=function(Fe){var dt=this.transmuxPipeline_;re.keepOriginalTimestamps||(this.baseMediaDecodeTime=Fe),Me&&(Me.timelineStartInfo.dts=void 0,Me.timelineStartInfo.pts=void 0,Ze.clearDtsInfo(Me),dt.audioTimestampRolloverStream&&dt.audioTimestampRolloverStream.discontinuity()),_e&&(dt.videoSegmentStream&&(dt.videoSegmentStream.gopCache_=[]),_e.timelineStartInfo.dts=void 0,_e.timelineStartInfo.pts=void 0,Ze.clearDtsInfo(_e),dt.captionStream.reset()),dt.timestampRolloverStream&&dt.timestampRolloverStream.discontinuity()},this.setAudioAppendStart=function(Fe){Me&&this.transmuxPipeline_.audioSegmentStream.setAudioAppendStart(Fe)},this.setRemux=function(Fe){var dt=this.transmuxPipeline_;re.remux=Fe,dt&&dt.coalesceStream&&dt.coalesceStream.setRemux(Fe)},this.alignGopsWith=function(Fe){_e&&this.transmuxPipeline_.videoSegmentStream&&this.transmuxPipeline_.videoSegmentStream.alignGopsWith(Fe)},this.getLogTrigger_=function(Fe){var dt=this;return function(yt){yt.stream=Fe,dt.trigger("log",yt)}},this.push=function(Fe){if(Se){var dt=ri(Fe);dt&&this.transmuxPipeline_.type!=="aac"?this.setupAacPipeline():!dt&&this.transmuxPipeline_.type!=="ts"&&this.setupTsPipeline(),Se=!1}this.transmuxPipeline_.headOfPipeline.push(Fe)},this.flush=function(){Se=!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()}},Or.prototype=new Te;var Lr={Transmuxer:Or,VideoSegmentStream:fr,AudioSegmentStream:jr,AUDIO_PROPERTIES:Ki,VIDEO_PROPERTIES:yr,generateSegmentTimingInfo:Sr},wa=function(re){return re>>>0},La=function(re){return("00"+re.toString(16)).slice(-2)},rn={toUnsigned:wa,toHexString:La},ra=function(re){var pe="";return pe+=String.fromCharCode(re[0]),pe+=String.fromCharCode(re[1]),pe+=String.fromCharCode(re[2]),pe+=String.fromCharCode(re[3]),pe},un=ra,Ln=rn.toUnsigned,Vn=un,Jr=function(re,pe){var Se=[],_e,Me,Fe,dt,yt;if(!pe.length)return null;for(_e=0;_e<re.byteLength;)Me=Ln(re[_e]<<24|re[_e+1]<<16|re[_e+2]<<8|re[_e+3]),Fe=Vn(re.subarray(_e+4,_e+8)),dt=Me>1?_e+Me:re.byteLength,Fe===pe[0]&&(pe.length===1?Se.push(re.subarray(_e+8,dt)):(yt=Jr(re.subarray(_e+8,dt),pe.slice(1)),yt.length&&(Se=Se.concat(yt)))),_e=dt;return Se},ha=Jr,Bn=rn.toUnsigned,An=l.getUint64,ln=function(re){var pe={version:re[0],flags:new Uint8Array(re.subarray(1,4))};return pe.version===1?pe.baseMediaDecodeTime=An(re.subarray(4)):pe.baseMediaDecodeTime=Bn(re[4]<<24|re[5]<<16|re[6]<<8|re[7]),pe},Ba=ln,Sa=function(re){return{isLeading:(re[0]&12)>>>2,dependsOn:re[0]&3,isDependedOn:(re[1]&192)>>>6,hasRedundancy:(re[1]&48)>>>4,paddingValue:(re[1]&14)>>>1,isNonSyncSample:re[1]&1,degradationPriority:re[2]<<8|re[3]}},Ir=Sa,da=Ir,_n=function(re){var pe={version:re[0],flags:new Uint8Array(re.subarray(1,4)),samples:[]},Se=new DataView(re.buffer,re.byteOffset,re.byteLength),_e=pe.flags[2]&1,Me=pe.flags[2]&4,Fe=pe.flags[1]&1,dt=pe.flags[1]&2,yt=pe.flags[1]&4,Tt=pe.flags[1]&8,Rt=Se.getUint32(4),Zt=8,ci;for(_e&&(pe.dataOffset=Se.getInt32(Zt),Zt+=4),Me&&Rt&&(ci={flags:da(re.subarray(Zt,Zt+4))},Zt+=4,Fe&&(ci.duration=Se.getUint32(Zt),Zt+=4),dt&&(ci.size=Se.getUint32(Zt),Zt+=4),Tt&&(pe.version===1?ci.compositionTimeOffset=Se.getInt32(Zt):ci.compositionTimeOffset=Se.getUint32(Zt),Zt+=4),pe.samples.push(ci),Rt--);Rt--;)ci={},Fe&&(ci.duration=Se.getUint32(Zt),Zt+=4),dt&&(ci.size=Se.getUint32(Zt),Zt+=4),yt&&(ci.flags=da(re.subarray(Zt,Zt+4)),Zt+=4),Tt&&(pe.version===1?ci.compositionTimeOffset=Se.getInt32(Zt):ci.compositionTimeOffset=Se.getUint32(Zt),Zt+=4),pe.samples.push(ci);return pe},na=_n,gs=function(re){var pe=new DataView(re.buffer,re.byteOffset,re.byteLength),Se={version:re[0],flags:new Uint8Array(re.subarray(1,4)),trackId:pe.getUint32(4)},_e=Se.flags[2]&1,Me=Se.flags[2]&2,Fe=Se.flags[2]&8,dt=Se.flags[2]&16,yt=Se.flags[2]&32,Tt=Se.flags[0]&65536,Rt=Se.flags[0]&131072,Zt;return Zt=8,_e&&(Zt+=4,Se.baseDataOffset=pe.getUint32(12),Zt+=4),Me&&(Se.sampleDescriptionIndex=pe.getUint32(Zt),Zt+=4),Fe&&(Se.defaultSampleDuration=pe.getUint32(Zt),Zt+=4),dt&&(Se.defaultSampleSize=pe.getUint32(Zt),Zt+=4),yt&&(Se.defaultSampleFlags=pe.getUint32(Zt)),Tt&&(Se.durationIsEmpty=!0),!_e&&Rt&&(Se.baseDataOffsetIsMoof=!0),Se},ns=gs,pa;typeof window<"u"?pa=window:typeof t<"u"?pa=t:typeof self<"u"?pa=self:pa={};var cn=pa,Ga=Xt.discardEmulationPreventionBytes,Wn=pi.CaptionStream,Gn=ha,ma=Ba,xn=na,aa=ns,Oa=cn,vs=function(re,pe){for(var Se=re,_e=0;_e<pe.length;_e++){var Me=pe[_e];if(Se<Me.size)return Me;Se-=Me.size}return null},ja=function(re,pe,Se){var _e=new DataView(re.buffer,re.byteOffset,re.byteLength),Me={logs:[],seiNals:[]},Fe,dt,yt,Tt;for(dt=0;dt+4<re.length;dt+=yt)if(yt=_e.getUint32(dt),dt+=4,!(yt<=0))switch(re[dt]&31){case 6:var Rt=re.subarray(dt+1,dt+1+yt),Zt=vs(dt,pe);if(Fe={nalUnitType:"sei_rbsp",size:yt,data:Rt,escapedRBSP:Ga(Rt),trackId:Se},Zt)Fe.pts=Zt.pts,Fe.dts=Zt.dts,Tt=Zt;else if(Tt)Fe.pts=Tt.pts,Fe.dts=Tt.dts;else{Me.logs.push({level:"warn",message:"We've encountered a nal unit without data at "+dt+" for trackId "+Se+". See mux.js#223."});break}Me.seiNals.push(Fe);break}return Me},Kn=function(re,pe,Se){var _e=pe,Me=Se.defaultSampleDuration||0,Fe=Se.defaultSampleSize||0,dt=Se.trackId,yt=[];return re.forEach(function(Tt){var Rt=xn(Tt),Zt=Rt.samples;Zt.forEach(function(ci){ci.duration===void 0&&(ci.duration=Me),ci.size===void 0&&(ci.size=Fe),ci.trackId=dt,ci.dts=_e,ci.compositionTimeOffset===void 0&&(ci.compositionTimeOffset=0),typeof _e=="bigint"?(ci.pts=_e+Oa.BigInt(ci.compositionTimeOffset),_e+=Oa.BigInt(ci.duration)):(ci.pts=_e+ci.compositionTimeOffset,_e+=ci.duration)}),yt=yt.concat(Zt)}),yt},fn=function(re,pe){var Se=Gn(re,["moof","traf"]),_e=Gn(re,["mdat"]),Me={},Fe=[];return _e.forEach(function(dt,yt){var Tt=Se[yt];Fe.push({mdat:dt,traf:Tt})}),Fe.forEach(function(dt){var yt=dt.mdat,Tt=dt.traf,Rt=Gn(Tt,["tfhd"]),Zt=aa(Rt[0]),ci=Zt.trackId,Wi=Gn(Tt,["tfdt"]),Pi=Wi.length>0?ma(Wi[0]).baseMediaDecodeTime:0,lr=Gn(Tt,["trun"]),et,Fr;pe===ci&&lr.length>0&&(et=Kn(lr,Pi,Zt),Fr=ja(yt,et,ci),Me[ci]||(Me[ci]={seiNals:[],logs:[]}),Me[ci].seiNals=Me[ci].seiNals.concat(Fr.seiNals),Me[ci].logs=Me[ci].logs.concat(Fr.logs))}),Me},as=function(re,pe,Se){var _e;if(pe===null)return null;_e=fn(re,pe);var Me=_e[pe]||{};return{seiNals:Me.seiNals,logs:Me.logs,timescale:Se}},Ka=function(){var re=!1,pe,Se,_e,Me,Fe,dt;this.isInitialized=function(){return re},this.init=function(yt){pe=new Wn,re=!0,dt=yt?yt.isPartial:!1,pe.on("data",function(Tt){Tt.startTime=Tt.startPts/Me,Tt.endTime=Tt.endPts/Me,Fe.captions.push(Tt),Fe.captionStreams[Tt.stream]=!0}),pe.on("log",function(Tt){Fe.logs.push(Tt)})},this.isNewInit=function(yt,Tt){return yt&&yt.length===0||Tt&&typeof Tt=="object"&&Object.keys(Tt).length===0?!1:_e!==yt[0]||Me!==Tt[_e]},this.parse=function(yt,Tt,Rt){var Zt;if(this.isInitialized()){if(!Tt||!Rt)return null;if(this.isNewInit(Tt,Rt))_e=Tt[0],Me=Rt[_e];else if(_e===null||!Me)return Se.push(yt),null}else return null;for(;Se.length>0;){var ci=Se.shift();this.parse(ci,Tt,Rt)}return Zt=as(yt,_e,Me),Zt&&Zt.logs&&(Fe.logs=Fe.logs.concat(Zt.logs)),Zt===null||!Zt.seiNals?Fe.logs.length?{logs:Fe.logs,captions:[],captionStreams:[]}:null:(this.pushNals(Zt.seiNals),this.flushStream(),Fe)},this.pushNals=function(yt){if(!this.isInitialized()||!yt||yt.length===0)return null;yt.forEach(function(Tt){pe.push(Tt)})},this.flushStream=function(){if(!this.isInitialized())return null;dt?pe.partialFlush():pe.flush()},this.clearParsedCaptions=function(){Fe.captions=[],Fe.captionStreams={},Fe.logs=[]},this.resetCaptionStream=function(){if(!this.isInitialized())return null;pe.reset()},this.clearAllCaptions=function(){this.clearParsedCaptions(),this.resetCaptionStream()},this.reset=function(){Se=[],_e=null,Me=null,Fe?this.clearParsedCaptions():Fe={captions:[],captionStreams:{},logs:[]},this.resetCaptionStream()},this.reset()},ss=Ka,_t=function(re){for(var pe=0,Se=String.fromCharCode(re[pe]),_e="";Se!=="\0";)_e+=Se,pe++,Se=String.fromCharCode(re[pe]);return _e+=Se,_e},Ht={uint8ToCString:_t},ti=Ht.uint8ToCString,ui=l.getUint64,mt=function(re){var pe=4,Se=re[0],_e,Me,Fe,dt,yt,Tt,Rt,Zt;if(Se===0){_e=ti(re.subarray(pe)),pe+=_e.length,Me=ti(re.subarray(pe)),pe+=Me.length;var ci=new DataView(re.buffer);Fe=ci.getUint32(pe),pe+=4,yt=ci.getUint32(pe),pe+=4,Tt=ci.getUint32(pe),pe+=4,Rt=ci.getUint32(pe),pe+=4}else if(Se===1){var ci=new DataView(re.buffer);Fe=ci.getUint32(pe),pe+=4,dt=ui(re.subarray(pe)),pe+=8,Tt=ci.getUint32(pe),pe+=4,Rt=ci.getUint32(pe),pe+=4,_e=ti(re.subarray(pe)),pe+=_e.length,Me=ti(re.subarray(pe)),pe+=Me.length}Zt=new Uint8Array(re.subarray(pe,re.byteLength));var Wi={scheme_id_uri:_e,value:Me,timescale:Fe||1,presentation_time:dt,presentation_time_delta:yt,event_duration:Tt,id:Rt,message_data:Zt};return Bt(Se,Wi)?Wi:void 0},Nt=function(re,pe,Se,_e){return re||re===0?re/pe:_e+Se/pe},Bt=function(re,pe){var Se=pe.scheme_id_uri!=="\0",_e=re===0&&_i(pe.presentation_time_delta)&&Se,Me=re===1&&_i(pe.presentation_time)&&Se;return!(re>1)&&_e||Me},_i=function(re){return re!==void 0||re!==null},Mi={parseEmsgBox:mt,scaleTime:Nt},Yi=rn.toUnsigned,Xi=rn.toHexString,Ui=ha,gr=un,ar=Mi,Er=ns,Hr=na,Yr=Ba,Vr=l.getUint64,nn,Mn,vr,Ps,ys,Fa,Ds,bs=cn,co=nr.parseId3Frames;nn=function(re){var pe={},Se=Ui(re,["moov","trak"]);return Se.reduce(function(_e,Me){var Fe,dt,yt,Tt,Rt;return Fe=Ui(Me,["tkhd"])[0],!Fe||(dt=Fe[0],yt=dt===0?12:20,Tt=Yi(Fe[yt]<<24|Fe[yt+1]<<16|Fe[yt+2]<<8|Fe[yt+3]),Rt=Ui(Me,["mdia","mdhd"])[0],!Rt)?null:(dt=Rt[0],yt=dt===0?12:20,_e[Tt]=Yi(Rt[yt]<<24|Rt[yt+1]<<16|Rt[yt+2]<<8|Rt[yt+3]),_e)},pe)},Mn=function(re,pe){var Se;Se=Ui(pe,["moof","traf"]);var _e=Se.reduce(function(Me,Fe){var dt=Ui(Fe,["tfhd"])[0],yt=Yi(dt[4]<<24|dt[5]<<16|dt[6]<<8|dt[7]),Tt=re[yt]||9e4,Rt=Ui(Fe,["tfdt"])[0],Zt=new DataView(Rt.buffer,Rt.byteOffset,Rt.byteLength),ci;Rt[0]===1?ci=Vr(Rt.subarray(4,12)):ci=Zt.getUint32(4);let Wi;return typeof ci=="bigint"?Wi=ci/bs.BigInt(Tt):typeof ci=="number"&&!isNaN(ci)&&(Wi=ci/Tt),Wi<Number.MAX_SAFE_INTEGER&&(Wi=Number(Wi)),Wi<Me&&(Me=Wi),Me},1/0);return typeof _e=="bigint"||isFinite(_e)?_e:0},vr=function(re,pe){var Se=Ui(pe,["moof","traf"]),_e=0,Me=0,Fe;if(Se&&Se.length){var dt=Ui(Se[0],["tfhd"])[0],yt=Ui(Se[0],["trun"])[0],Tt=Ui(Se[0],["tfdt"])[0];if(dt){var Rt=Er(dt);Fe=Rt.trackId}if(Tt){var Zt=Yr(Tt);_e=Zt.baseMediaDecodeTime}if(yt){var ci=Hr(yt);ci.samples&&ci.samples.length&&(Me=ci.samples[0].compositionTimeOffset||0)}}var Wi=re[Fe]||9e4;typeof _e=="bigint"&&(Me=bs.BigInt(Me),Wi=bs.BigInt(Wi));var Pi=(_e+Me)/Wi;return typeof Pi=="bigint"&&Pi<Number.MAX_SAFE_INTEGER&&(Pi=Number(Pi)),Pi},Ps=function(re){var pe=Ui(re,["moov","trak"]),Se=[];return pe.forEach(function(_e){var Me=Ui(_e,["mdia","hdlr"]),Fe=Ui(_e,["tkhd"]);Me.forEach(function(dt,yt){var Tt=gr(dt.subarray(8,12)),Rt=Fe[yt],Zt,ci,Wi;Tt==="vide"&&(Zt=new DataView(Rt.buffer,Rt.byteOffset,Rt.byteLength),ci=Zt.getUint8(0),Wi=ci===0?Zt.getUint32(12):Zt.getUint32(20),Se.push(Wi))})}),Se},Fa=function(re){var pe=re[0],Se=pe===0?12:20;return Yi(re[Se]<<24|re[Se+1]<<16|re[Se+2]<<8|re[Se+3])},ys=function(re){var pe=Ui(re,["moov","trak"]),Se=[];return pe.forEach(function(_e){var Me={},Fe=Ui(_e,["tkhd"])[0],dt,yt;Fe&&(dt=new DataView(Fe.buffer,Fe.byteOffset,Fe.byteLength),yt=dt.getUint8(0),Me.id=yt===0?dt.getUint32(12):dt.getUint32(20));var Tt=Ui(_e,["mdia","hdlr"])[0];if(Tt){var Rt=gr(Tt.subarray(8,12));Rt==="vide"?Me.type="video":Rt==="soun"?Me.type="audio":Me.type=Rt}var Zt=Ui(_e,["mdia","minf","stbl","stsd"])[0];if(Zt){var ci=Zt.subarray(8);Me.codec=gr(ci.subarray(4,8));var Wi=Ui(ci,[Me.codec])[0],Pi,lr;Wi&&(/^[asm]vc[1-9]$/i.test(Me.codec)?(Pi=Wi.subarray(78),lr=gr(Pi.subarray(4,8)),lr==="avcC"&&Pi.length>11?(Me.codec+=".",Me.codec+=Xi(Pi[9]),Me.codec+=Xi(Pi[10]),Me.codec+=Xi(Pi[11])):Me.codec="avc1.4d400d"):/^mp4[a,v]$/i.test(Me.codec)?(Pi=Wi.subarray(28),lr=gr(Pi.subarray(4,8)),lr==="esds"&&Pi.length>20&&Pi[19]!==0?(Me.codec+="."+Xi(Pi[19]),Me.codec+="."+Xi(Pi[20]>>>2&63).replace(/^0/,"")):Me.codec="mp4a.40.2"):Me.codec=Me.codec.toLowerCase())}var et=Ui(_e,["mdia","mdhd"])[0];et&&(Me.timescale=Fa(et)),Se.push(Me)}),Se},Ds=function(re,pe=0){var Se=Ui(re,["emsg"]);return Se.map(_e=>{var Me=ar.parseEmsgBox(new Uint8Array(_e)),Fe=co(Me.message_data);return{cueTime:ar.scaleTime(Me.presentation_time,Me.timescale,Me.presentation_time_delta,pe),duration:ar.scaleTime(Me.event_duration,Me.timescale),frames:Fe}})};var Na={findBox:Ui,parseType:gr,timescale:nn,startTime:Mn,compositionStartTime:vr,videoTrackIds:Ps,tracks:ys,getTimescaleFromMediaHeader:Fa,getEmsgID3:Ds},Qn=Ii,Qa=function(re){var pe=re[1]&31;return pe<<=8,pe|=re[2],pe},Ya=function(re){return!!(re[1]&64)},Ta=function(re){var pe=0;return(re[3]&48)>>>4>1&&(pe+=re[4]+1),pe},Is=function(re,pe){var Se=Qa(re);return Se===0?"pat":Se===pe?"pmt":pe?"pes":null},Rs=function(re){var pe=Ya(re),Se=4+Ta(re);return pe&&(Se+=re[Se]+1),(re[Se+10]&31)<<8|re[Se+11]},os=function(re){var pe={},Se=Ya(re),_e=4+Ta(re);if(Se&&(_e+=re[_e]+1),!!(re[_e+5]&1)){var Me,Fe,dt;Me=(re[_e+1]&15)<<8|re[_e+2],Fe=3+Me-4,dt=(re[_e+10]&15)<<8|re[_e+11];for(var yt=12+dt;yt<Fe;){var Tt=_e+yt;pe[(re[Tt+1]&31)<<8|re[Tt+2]]=re[Tt],yt+=((re[Tt+3]&15)<<8|re[Tt+4])+5}return pe}},$s=function(re,pe){var Se=Qa(re),_e=pe[Se];switch(_e){case Qn.H264_STREAM_TYPE:return"video";case Qn.ADTS_STREAM_TYPE:return"audio";case Qn.METADATA_STREAM_TYPE:return"timed-metadata";default:return null}},Xa=function(re){var pe=Ya(re);if(!pe)return null;var Se=4+Ta(re);if(Se>=re.byteLength)return null;var _e=null,Me;return Me=re[Se+7],Me&192&&(_e={},_e.pts=(re[Se+9]&14)<<27|(re[Se+10]&255)<<20|(re[Se+11]&254)<<12|(re[Se+12]&255)<<5|(re[Se+13]&254)>>>3,_e.pts*=4,_e.pts+=(re[Se+13]&6)>>>1,_e.dts=_e.pts,Me&64&&(_e.dts=(re[Se+14]&14)<<27|(re[Se+15]&255)<<20|(re[Se+16]&254)<<12|(re[Se+17]&255)<<5|(re[Se+18]&254)>>>3,_e.dts*=4,_e.dts+=(re[Se+18]&6)>>>1)),_e},sa=function(re){switch(re){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}},us=function(re){for(var pe=4+Ta(re),Se=re.subarray(pe),_e=0,Me=0,Fe=!1,dt;Me<Se.byteLength-3;Me++)if(Se[Me+2]===1){_e=Me+5;break}for(;_e<Se.byteLength;)switch(Se[_e]){case 0:if(Se[_e-1]!==0){_e+=2;break}else if(Se[_e-2]!==0){_e++;break}Me+3!==_e-2&&(dt=sa(Se[Me+3]&31),dt==="slice_layer_without_partitioning_rbsp_idr"&&(Fe=!0));do _e++;while(Se[_e]!==1&&_e<Se.length);Me=_e-2,_e+=3;break;case 1:if(Se[_e-1]!==0||Se[_e-2]!==0){_e+=3;break}dt=sa(Se[Me+3]&31),dt==="slice_layer_without_partitioning_rbsp_idr"&&(Fe=!0),Me=_e-2,_e+=3;break;default:_e+=3;break}return Se=Se.subarray(Me),_e-=Me,Me=0,Se&&Se.byteLength>3&&(dt=sa(Se[Me+3]&31),dt==="slice_layer_without_partitioning_rbsp_idr"&&(Fe=!0)),Fe},fo={parseType:Is,parsePat:Rs,parsePmt:os,parsePayloadUnitStartIndicator:Ya,parsePesType:$s,parsePesTime:Xa,videoPacketContainsKeyFrame:us},Ls=Ii,qa=Ti.handleRollover,Rr={};Rr.ts=fo,Rr.aac=fa;var Yn=ye.ONE_SECOND_IN_TS,en=188,Xn=71,Bs=function(re,pe){for(var Se=0,_e=en,Me,Fe;_e<re.byteLength;){if(re[Se]===Xn&&re[_e]===Xn){switch(Me=re.subarray(Se,_e),Fe=Rr.ts.parseType(Me,pe.pid),Fe){case"pat":pe.pid=Rr.ts.parsePat(Me);break;case"pmt":var dt=Rr.ts.parsePmt(Me);pe.table=pe.table||{},Object.keys(dt).forEach(function(yt){pe.table[yt]=dt[yt]});break}Se+=en,_e+=en;continue}Se++,_e++}},Os=function(re,pe,Se){for(var _e=0,Me=en,Fe,dt,yt,Tt,Rt,Zt=!1;Me<=re.byteLength;){if(re[_e]===Xn&&(re[Me]===Xn||Me===re.byteLength)){switch(Fe=re.subarray(_e,Me),dt=Rr.ts.parseType(Fe,pe.pid),dt){case"pes":yt=Rr.ts.parsePesType(Fe,pe.table),Tt=Rr.ts.parsePayloadUnitStartIndicator(Fe),yt==="audio"&&Tt&&(Rt=Rr.ts.parsePesTime(Fe),Rt&&(Rt.type="audio",Se.audio.push(Rt),Zt=!0));break}if(Zt)break;_e+=en,Me+=en;continue}_e++,Me++}for(Me=re.byteLength,_e=Me-en,Zt=!1;_e>=0;){if(re[_e]===Xn&&(re[Me]===Xn||Me===re.byteLength)){switch(Fe=re.subarray(_e,Me),dt=Rr.ts.parseType(Fe,pe.pid),dt){case"pes":yt=Rr.ts.parsePesType(Fe,pe.table),Tt=Rr.ts.parsePayloadUnitStartIndicator(Fe),yt==="audio"&&Tt&&(Rt=Rr.ts.parsePesTime(Fe),Rt&&(Rt.type="audio",Se.audio.push(Rt),Zt=!0));break}if(Zt)break;_e-=en,Me-=en;continue}_e--,Me--}},ho=function(re,pe,Se){for(var _e=0,Me=en,Fe,dt,yt,Tt,Rt,Zt,ci,Wi,Pi=!1,lr={data:[],size:0};Me<re.byteLength;){if(re[_e]===Xn&&re[Me]===Xn){switch(Fe=re.subarray(_e,Me),dt=Rr.ts.parseType(Fe,pe.pid),dt){case"pes":if(yt=Rr.ts.parsePesType(Fe,pe.table),Tt=Rr.ts.parsePayloadUnitStartIndicator(Fe),yt==="video"&&(Tt&&!Pi&&(Rt=Rr.ts.parsePesTime(Fe),Rt&&(Rt.type="video",Se.video.push(Rt),Pi=!0)),!Se.firstKeyFrame)){if(Tt&&lr.size!==0){for(Zt=new Uint8Array(lr.size),ci=0;lr.data.length;)Wi=lr.data.shift(),Zt.set(Wi,ci),ci+=Wi.byteLength;if(Rr.ts.videoPacketContainsKeyFrame(Zt)){var et=Rr.ts.parsePesTime(Zt);et?(Se.firstKeyFrame=et,Se.firstKeyFrame.type="video"):console.warn("Failed to extract PTS/DTS from PES at first keyframe. This could be an unusual TS segment, or else mux.js did not parse your TS segment correctly. If you know your TS segments do contain PTS/DTS on keyframes please file a bug report! You can try ffprobe to double check for yourself.")}lr.size=0}lr.data.push(Fe),lr.size+=Fe.byteLength}break}if(Pi&&Se.firstKeyFrame)break;_e+=en,Me+=en;continue}_e++,Me++}for(Me=re.byteLength,_e=Me-en,Pi=!1;_e>=0;){if(re[_e]===Xn&&re[Me]===Xn){switch(Fe=re.subarray(_e,Me),dt=Rr.ts.parseType(Fe,pe.pid),dt){case"pes":yt=Rr.ts.parsePesType(Fe,pe.table),Tt=Rr.ts.parsePayloadUnitStartIndicator(Fe),yt==="video"&&Tt&&(Rt=Rr.ts.parsePesTime(Fe),Rt&&(Rt.type="video",Se.video.push(Rt),Pi=!0));break}if(Pi)break;_e-=en,Me-=en;continue}_e--,Me--}},Wr=function(re,pe){if(re.audio&&re.audio.length){var Se=pe;(typeof Se>"u"||isNaN(Se))&&(Se=re.audio[0].dts),re.audio.forEach(function(Fe){Fe.dts=qa(Fe.dts,Se),Fe.pts=qa(Fe.pts,Se),Fe.dtsTime=Fe.dts/Yn,Fe.ptsTime=Fe.pts/Yn})}if(re.video&&re.video.length){var _e=pe;if((typeof _e>"u"||isNaN(_e))&&(_e=re.video[0].dts),re.video.forEach(function(Fe){Fe.dts=qa(Fe.dts,_e),Fe.pts=qa(Fe.pts,_e),Fe.dtsTime=Fe.dts/Yn,Fe.ptsTime=Fe.pts/Yn}),re.firstKeyFrame){var Me=re.firstKeyFrame;Me.dts=qa(Me.dts,_e),Me.pts=qa(Me.pts,_e),Me.dtsTime=Me.dts/Yn,Me.ptsTime=Me.pts/Yn}}},an=function(re){for(var pe=!1,Se=0,_e=null,Me=null,Fe=0,dt=0,yt;re.length-dt>=3;){var Tt=Rr.aac.parseType(re,dt);switch(Tt){case"timed-metadata":if(re.length-dt<10){pe=!0;break}if(Fe=Rr.aac.parseId3TagSize(re,dt),Fe>re.length){pe=!0;break}Me===null&&(yt=re.subarray(dt,dt+Fe),Me=Rr.aac.parseAacTimestamp(yt)),dt+=Fe;break;case"audio":if(re.length-dt<7){pe=!0;break}if(Fe=Rr.aac.parseAdtsSize(re,dt),Fe>re.length){pe=!0;break}_e===null&&(yt=re.subarray(dt,dt+Fe),_e=Rr.aac.parseSampleRate(yt)),Se++,dt+=Fe;break;default:dt++;break}if(pe)return null}if(_e===null||Me===null)return null;var Rt=Yn/_e,Zt={audio:[{type:"audio",dts:Me,pts:Me},{type:"audio",dts:Me+Se*1024*Rt,pts:Me+Se*1024*Rt}]};return Zt},po=function(re){var pe={pid:null,table:null},Se={};Bs(re,pe);for(var _e in pe.table)if(pe.table.hasOwnProperty(_e)){var Me=pe.table[_e];switch(Me){case Ls.H264_STREAM_TYPE:Se.video=[],ho(re,pe,Se),Se.video.length===0&&delete Se.video;break;case Ls.ADTS_STREAM_TYPE:Se.audio=[],Os(re,pe,Se),Se.audio.length===0&&delete Se.audio;break}}return Se},mo=function(re,pe){var Se=Rr.aac.isLikelyAacData(re),_e;return Se?_e=an(re):_e=po(re),!_e||!_e.audio&&!_e.video?null:(Wr(_e,pe),_e)},js={inspect:mo,parseAudioPes_:Os};const go=function(re,pe){pe.on("data",function(Se){const _e=Se.initSegment;Se.initSegment={data:_e.buffer,byteOffset:_e.byteOffset,byteLength:_e.byteLength};const Me=Se.data;Se.data=Me.buffer,re.postMessage({action:"data",segment:Se,byteOffset:Me.byteOffset,byteLength:Me.byteLength},[Se.data])}),pe.on("done",function(Se){re.postMessage({action:"done"})}),pe.on("gopInfo",function(Se){re.postMessage({action:"gopInfo",gopInfo:Se})}),pe.on("videoSegmentTimingInfo",function(Se){const _e={start:{decode:ye.videoTsToSeconds(Se.start.dts),presentation:ye.videoTsToSeconds(Se.start.pts)},end:{decode:ye.videoTsToSeconds(Se.end.dts),presentation:ye.videoTsToSeconds(Se.end.pts)},baseMediaDecodeTime:ye.videoTsToSeconds(Se.baseMediaDecodeTime)};Se.prependedContentDuration&&(_e.prependedContentDuration=ye.videoTsToSeconds(Se.prependedContentDuration)),re.postMessage({action:"videoSegmentTimingInfo",videoSegmentTimingInfo:_e})}),pe.on("audioSegmentTimingInfo",function(Se){const _e={start:{decode:ye.videoTsToSeconds(Se.start.dts),presentation:ye.videoTsToSeconds(Se.start.pts)},end:{decode:ye.videoTsToSeconds(Se.end.dts),presentation:ye.videoTsToSeconds(Se.end.pts)},baseMediaDecodeTime:ye.videoTsToSeconds(Se.baseMediaDecodeTime)};Se.prependedContentDuration&&(_e.prependedContentDuration=ye.videoTsToSeconds(Se.prependedContentDuration)),re.postMessage({action:"audioSegmentTimingInfo",audioSegmentTimingInfo:_e})}),pe.on("id3Frame",function(Se){re.postMessage({action:"id3Frame",id3Frame:Se})}),pe.on("caption",function(Se){re.postMessage({action:"caption",caption:Se})}),pe.on("trackinfo",function(Se){re.postMessage({action:"trackinfo",trackInfo:Se})}),pe.on("audioTimingInfo",function(Se){re.postMessage({action:"audioTimingInfo",audioTimingInfo:{start:ye.videoTsToSeconds(Se.start),end:ye.videoTsToSeconds(Se.end)}})}),pe.on("videoTimingInfo",function(Se){re.postMessage({action:"videoTimingInfo",videoTimingInfo:{start:ye.videoTsToSeconds(Se.start),end:ye.videoTsToSeconds(Se.end)}})}),pe.on("log",function(Se){re.postMessage({action:"log",log:Se})})};class ls{constructor(pe,Se){this.options=Se||{},this.self=pe,this.init()}init(){this.transmuxer&&this.transmuxer.dispose(),this.transmuxer=new Lr.Transmuxer(this.options),go(this.self,this.transmuxer)}pushMp4Captions(pe){this.captionParser||(this.captionParser=new ss,this.captionParser.init());const Se=new Uint8Array(pe.data,pe.byteOffset,pe.byteLength),_e=this.captionParser.parse(Se,pe.trackIds,pe.timescales);this.self.postMessage({action:"mp4Captions",captions:_e&&_e.captions||[],logs:_e&&_e.logs||[],data:Se.buffer},[Se.buffer])}probeMp4StartTime({timescales:pe,data:Se}){const _e=Na.startTime(pe,Se);this.self.postMessage({action:"probeMp4StartTime",startTime:_e,data:Se},[Se.buffer])}probeMp4Tracks({data:pe}){const Se=Na.tracks(pe);this.self.postMessage({action:"probeMp4Tracks",tracks:Se,data:pe},[pe.buffer])}probeEmsgID3({data:pe,offset:Se}){const _e=Na.getEmsgID3(pe,Se);this.self.postMessage({action:"probeEmsgID3",id3Frames:_e,emsgData:pe},[pe.buffer])}probeTs({data:pe,baseStartTime:Se}){const _e=typeof Se=="number"&&!isNaN(Se)?Se*ye.ONE_SECOND_IN_TS:void 0,Me=js.inspect(pe,_e);let Fe=null;Me&&(Fe={hasVideo:Me.video&&Me.video.length===2||!1,hasAudio:Me.audio&&Me.audio.length===2||!1},Fe.hasVideo&&(Fe.videoStart=Me.video[0].ptsTime),Fe.hasAudio&&(Fe.audioStart=Me.audio[0].ptsTime)),this.self.postMessage({action:"probeTs",result:Fe,data:pe},[pe.buffer])}clearAllMp4Captions(){this.captionParser&&this.captionParser.clearAllCaptions()}clearParsedMp4Captions(){this.captionParser&&this.captionParser.clearParsedCaptions()}push(pe){const Se=new Uint8Array(pe.data,pe.byteOffset,pe.byteLength);this.transmuxer.push(Se)}reset(){this.transmuxer.reset()}setTimestampOffset(pe){const Se=pe.timestampOffset||0;this.transmuxer.setBaseMediaDecodeTime(Math.round(ye.secondsToVideoTs(Se)))}setAudioAppendStart(pe){this.transmuxer.setAudioAppendStart(Math.ceil(ye.secondsToVideoTs(pe.appendStart)))}setRemux(pe){this.transmuxer.setRemux(pe.remux)}flush(pe){this.transmuxer.flush(),self.postMessage({action:"done",type:"transmuxed"})}endTimeline(){this.transmuxer.endTimeline(),self.postMessage({action:"endedtimeline",type:"transmuxed"})}alignGopsWith(pe){this.transmuxer.alignGopsWith(pe.gopsToAlignWith.slice())}}self.onmessage=function(re){if(re.data.action==="init"&&re.data.options){this.messageHandlers=new ls(self,re.data.options);return}this.messageHandlers||(this.messageHandlers=new ls(self)),re.data&&re.data.action&&re.data.action!=="init"&&this.messageHandlers[re.data.action]&&this.messageHandlers[re.data.action](re.data)}}));var TransmuxWorker=factory(workerCode$1);const handleData_=(t,e,n)=>{const{type:o,initSegment:u,captions:l,captionStreams:m,metadata:y,videoFrameDtsTime:E,videoFramePtsTime:C}=t.data.segment;e.buffer.push({captions:l,captionStreams:m,metadata:y});const k=t.data.segment.boxes||{data:t.data.segment.data},A={type:o,data:new Uint8Array(k.data,k.data.byteOffset,k.data.byteLength),initSegment:new Uint8Array(u.data,u.byteOffset,u.byteLength)};typeof E<"u"&&(A.videoFrameDtsTime=E),typeof C<"u"&&(A.videoFramePtsTime=C),n(A)},handleDone_=({transmuxedData:t,callback:e})=>{t.buffer=[],e(t)},handleGopInfo_=(t,e)=>{e.gopInfo=t.data.gopInfo},processTransmux=t=>{const{transmuxer:e,bytes:n,audioAppendStart:o,gopsToAlignWith:u,remux:l,onData:m,onTrackInfo:y,onAudioTimingInfo:E,onVideoTimingInfo:C,onVideoSegmentTimingInfo:k,onAudioSegmentTimingInfo:A,onId3:D,onCaptions:P,onDone:R,onEndedTimeline:B,onTransmuxerLog:F,isEndOfTimeline:j,segment:N,triggerSegmentEventFn:Y}=t,J={buffer:[]};let ie=j;const ue=ce=>{e.currentTransmux===t&&(ce.data.action==="data"&&handleData_(ce,J,m),ce.data.action==="trackinfo"&&y(ce.data.trackInfo),ce.data.action==="gopInfo"&&handleGopInfo_(ce,J),ce.data.action==="audioTimingInfo"&&E(ce.data.audioTimingInfo),ce.data.action==="videoTimingInfo"&&C(ce.data.videoTimingInfo),ce.data.action==="videoSegmentTimingInfo"&&k(ce.data.videoSegmentTimingInfo),ce.data.action==="audioSegmentTimingInfo"&&A(ce.data.audioSegmentTimingInfo),ce.data.action==="id3Frame"&&D([ce.data.id3Frame],ce.data.id3Frame.dispatchType),ce.data.action==="caption"&&P(ce.data.caption),ce.data.action==="endedtimeline"&&(ie=!1,B()),ce.data.action==="log"&&F(ce.data.log),ce.data.type==="transmuxed"&&(ie||(e.onmessage=null,handleDone_({transmuxedData:J,callback:R}),dequeue(e))))},Q=()=>{const ce={message:"Received an error message from the transmuxer worker",metadata:{errorType:videojs.Error.StreamingFailedToTransmuxSegment,segmentInfo:segmentInfoPayload({segment:N})}};R(null,ce)};if(e.onmessage=ue,e.onerror=Q,o&&e.postMessage({action:"setAudioAppendStart",appendStart:o}),Array.isArray(u)&&e.postMessage({action:"alignGopsWith",gopsToAlignWith:u}),typeof l<"u"&&e.postMessage({action:"setRemux",remux:l}),n.byteLength){const ce=n instanceof ArrayBuffer?n:n.buffer,he=n instanceof ArrayBuffer?0:n.byteOffset;Y({type:"segmenttransmuxingstart",segment:N}),e.postMessage({action:"push",data:ce,byteOffset:he,byteLength:n.byteLength},[ce])}j&&e.postMessage({action:"endTimeline"}),e.postMessage({action:"flush"})},dequeue=t=>{t.currentTransmux=null,t.transmuxQueue.length&&(t.currentTransmux=t.transmuxQueue.shift(),typeof t.currentTransmux=="function"?t.currentTransmux():processTransmux(t.currentTransmux))},processAction=(t,e)=>{t.postMessage({action:e}),dequeue(t)},enqueueAction=(t,e)=>{if(!e.currentTransmux){e.currentTransmux=t,processAction(e,t);return}e.transmuxQueue.push(processAction.bind(null,e,t))},reset=t=>{enqueueAction("reset",t)},endTimeline=t=>{enqueueAction("endTimeline",t)},transmux=t=>{if(!t.transmuxer.currentTransmux){t.transmuxer.currentTransmux=t,processTransmux(t);return}t.transmuxer.transmuxQueue.push(t)},createTransmuxer=t=>{const e=new TransmuxWorker;e.currentTransmux=null,e.transmuxQueue=[];const n=e.terminate;return e.terminate=()=>(e.currentTransmux=null,e.transmuxQueue.length=0,n.call(e)),e.postMessage({action:"init",options:t}),e};var segmentTransmuxer={reset,endTimeline,transmux,createTransmuxer};const workerCallback=function(t){const e=t.transmuxer,n=t.endAction||t.action,o=t.callback,u=_extends$2({},t,{endAction:null,transmuxer:null,callback:null}),l=m=>{m.data.action===n&&(e.removeEventListener("message",l),m.data.data&&(m.data.data=new Uint8Array(m.data.data,t.byteOffset||0,t.byteLength||m.data.data.byteLength),t.data&&(t.data=m.data.data)),o(m.data))};if(e.addEventListener("message",l),t.data){const m=t.data instanceof ArrayBuffer;u.byteOffset=m?0:t.data.byteOffset,u.byteLength=t.data.byteLength;const y=[m?t.data:t.data.buffer];e.postMessage(u,y)}else e.postMessage(u)},REQUEST_ERRORS={FAILURE:2,TIMEOUT:-101,ABORTED:-102},abortAll=t=>{t.forEach(e=>{e.abort()})},getRequestStats=t=>({bandwidth:t.bandwidth,bytesReceived:t.bytesReceived||0,roundTripTime:t.roundTripTime||0}),getProgressStats=t=>{const e=t.target,o={bandwidth:1/0,bytesReceived:0,roundTripTime:Date.now()-e.requestTime||0};return o.bytesReceived=t.loaded,o.bandwidth=Math.floor(o.bytesReceived/o.roundTripTime*8*1e3),o},handleErrors=(t,e)=>{const{requestType:n}=e,o=getStreamingNetworkErrorMetadata({requestType:n,request:e,error:t});return e.timedout?{status:e.status,message:"HLS request timed-out at URL: "+e.uri,code:REQUEST_ERRORS.TIMEOUT,xhr:e,metadata:o}:e.aborted?{status:e.status,message:"HLS request aborted at URL: "+e.uri,code:REQUEST_ERRORS.ABORTED,xhr:e,metadata:o}:t?{status:e.status,message:"HLS request errored at URL: "+e.uri,code:REQUEST_ERRORS.FAILURE,xhr:e,metadata:o}:e.responseType==="arraybuffer"&&e.response.byteLength===0?{status:e.status,message:"Empty HLS response at URL: "+e.uri,code:REQUEST_ERRORS.FAILURE,xhr:e,metadata:o}:null},handleKeyResponse=(t,e,n,o)=>(u,l)=>{const m=l.response,y=handleErrors(u,l);if(y)return n(y,t);if(m.byteLength!==16)return n({status:l.status,message:"Invalid HLS key at URL: "+l.uri,code:REQUEST_ERRORS.FAILURE,xhr:l},t);const E=new DataView(m),C=new Uint32Array([E.getUint32(0),E.getUint32(4),E.getUint32(8),E.getUint32(12)]);for(let A=0;A<e.length;A++)e[A].bytes=C;const k={uri:l.uri};return o({type:"segmentkeyloadcomplete",segment:t,keyInfo:k}),n(null,t)},parseInitSegment=(t,e)=>{const n=detectContainerForBytes(t.map.bytes);if(n!=="mp4"){const o=t.map.resolvedUri||t.map.uri,u=n||"unknown";return e({internal:!0,message:`Found unsupported ${u} container for initialization segment at URL: ${o}`,code:REQUEST_ERRORS.FAILURE,metadata:{mediaType:u}})}workerCallback({action:"probeMp4Tracks",data:t.map.bytes,transmuxer:t.transmuxer,callback:({tracks:o,data:u})=>(t.map.bytes=u,o.forEach(function(l){t.map.tracks=t.map.tracks||{},!t.map.tracks[l.type]&&(t.map.tracks[l.type]=l,typeof l.id=="number"&&l.timescale&&(t.map.timescales=t.map.timescales||{},t.map.timescales[l.id]=l.timescale))}),e(null))})},handleInitSegmentResponse=({segment:t,finishProcessingFn:e,triggerSegmentEventFn:n})=>(o,u)=>{const l=handleErrors(o,u);if(l)return e(l,t);const m=new Uint8Array(u.response);if(n({type:"segmentloaded",segment:t}),t.map.key)return t.map.encryptedBytes=m,e(null,t);t.map.bytes=m,parseInitSegment(t,function(y){if(y)return y.xhr=u,y.status=u.status,e(y,t);e(null,t)})},handleSegmentResponse=({segment:t,finishProcessingFn:e,responseType:n,triggerSegmentEventFn:o})=>(u,l)=>{const m=handleErrors(u,l);if(m)return e(m,t);o({type:"segmentloaded",segment:t});const y=n==="arraybuffer"||!l.responseText?l.response:stringToArrayBuffer(l.responseText.substring(t.lastReachedChar||0));return t.stats=getRequestStats(l),t.key?t.encryptedBytes=new Uint8Array(y):t.bytes=new Uint8Array(y),e(null,t)},transmuxAndNotify=({segment:t,bytes:e,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k,doneFn:A,onTransmuxerLog:D,triggerSegmentEventFn:P})=>{const R=t.map&&t.map.tracks||{},B=!!(R.audio&&R.video);let F=o.bind(null,t,"audio","start");const j=o.bind(null,t,"audio","end");let N=o.bind(null,t,"video","start");const Y=o.bind(null,t,"video","end"),J=()=>transmux({bytes:e,transmuxer:t.transmuxer,audioAppendStart:t.audioAppendStart,gopsToAlignWith:t.gopsToAlignWith,remux:B,onData:ie=>{ie.type=ie.type==="combined"?"video":ie.type,k(t,ie)},onTrackInfo:ie=>{n&&(B&&(ie.isMuxed=!0),n(t,ie))},onAudioTimingInfo:ie=>{F&&typeof ie.start<"u"&&(F(ie.start),F=null),j&&typeof ie.end<"u"&&j(ie.end)},onVideoTimingInfo:ie=>{N&&typeof ie.start<"u"&&(N(ie.start),N=null),Y&&typeof ie.end<"u"&&Y(ie.end)},onVideoSegmentTimingInfo:ie=>{const ue={pts:{start:ie.start.presentation,end:ie.end.presentation},dts:{start:ie.start.decode,end:ie.end.decode}};P({type:"segmenttransmuxingtiminginfoavailable",segment:t,timingInfo:ue}),u(ie)},onAudioSegmentTimingInfo:ie=>{const ue={pts:{start:ie.start.pts,end:ie.end.pts},dts:{start:ie.start.dts,end:ie.end.dts}};P({type:"segmenttransmuxingtiminginfoavailable",segment:t,timingInfo:ue}),l(ie)},onId3:(ie,ue)=>{m(t,ie,ue)},onCaptions:ie=>{y(t,[ie])},isEndOfTimeline:E,onEndedTimeline:()=>{C()},onTransmuxerLog:D,onDone:(ie,ue)=>{A&&(ie.type=ie.type==="combined"?"video":ie.type,P({type:"segmenttransmuxingcomplete",segment:t}),A(ue,t,ie))},segment:t,triggerSegmentEventFn:P});workerCallback({action:"probeTs",transmuxer:t.transmuxer,data:e,baseStartTime:t.baseStartTime,callback:ie=>{t.bytes=e=ie.data;const ue=ie.result;ue&&(n(t,{hasAudio:ue.hasAudio,hasVideo:ue.hasVideo,isMuxed:B}),n=null),J()}})},handleSegmentBytes=({segment:t,bytes:e,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k,doneFn:A,onTransmuxerLog:D,triggerSegmentEventFn:P})=>{let R=new Uint8Array(e);if(isLikelyFmp4MediaSegment(R)){t.isFmp4=!0;const{tracks:B}=t.map,F={isFmp4:!0,hasVideo:!!B.video,hasAudio:!!B.audio};B.audio&&B.audio.codec&&B.audio.codec!=="enca"&&(F.audioCodec=B.audio.codec),B.video&&B.video.codec&&B.video.codec!=="encv"&&(F.videoCodec=B.video.codec),B.video&&B.audio&&(F.isMuxed=!0),n(t,F);const j=(N,Y)=>{k(t,{data:R,type:F.hasAudio&&!F.isMuxed?"audio":"video"}),Y&&Y.length&&m(t,Y),N&&N.length&&y(t,N),A(null,t,{})};workerCallback({action:"probeMp4StartTime",timescales:t.map.timescales,data:R,transmuxer:t.transmuxer,callback:({data:N,startTime:Y})=>{e=N.buffer,t.bytes=R=N,F.hasAudio&&!F.isMuxed&&o(t,"audio","start",Y),F.hasVideo&&o(t,"video","start",Y),workerCallback({action:"probeEmsgID3",data:R,transmuxer:t.transmuxer,offset:Y,callback:({emsgData:J,id3Frames:ie})=>{if(e=J.buffer,t.bytes=R=J,!B.video||!J.byteLength||!t.transmuxer){j(void 0,ie);return}workerCallback({action:"pushMp4Captions",endAction:"mp4Captions",transmuxer:t.transmuxer,data:R,timescales:t.map.timescales,trackIds:[B.video.id],callback:ue=>{e=ue.data.buffer,t.bytes=R=ue.data,ue.logs.forEach(function(Q){D(merge(Q,{stream:"mp4CaptionParser"}))}),j(ue.captions,ie)}})}})}});return}if(!t.transmuxer){A(null,t,{});return}if(typeof t.container>"u"&&(t.container=detectContainerForBytes(R)),t.container!=="ts"&&t.container!=="aac"){n(t,{hasAudio:!1,hasVideo:!1}),A(null,t,{});return}transmuxAndNotify({segment:t,bytes:e,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k,doneFn:A,onTransmuxerLog:D,triggerSegmentEventFn:P})},decrypt$1=function({id:t,key:e,encryptedBytes:n,decryptionWorker:o,segment:u,doneFn:l},m){const y=C=>{if(C.data.source===t){o.removeEventListener("message",y);const k=C.data.decrypted;m(new Uint8Array(k.bytes,k.byteOffset,k.byteLength))}};o.onerror=()=>{const C="An error occurred in the decryption worker",k=segmentInfoPayload({segment:u}),A={message:C,metadata:{error:new Error(C),errorType:videojs.Error.StreamingFailedToDecryptSegment,segmentInfo:k,keyInfo:{uri:u.key.resolvedUri||u.map.key.resolvedUri}}};l(A,u)},o.addEventListener("message",y);let E;e.bytes.slice?E=e.bytes.slice():E=new Uint32Array(Array.prototype.slice.call(e.bytes)),o.postMessage(createTransferableMessage({source:t,encrypted:n,key:E,iv:e.iv}),[n.buffer,E.buffer])},decryptSegment=({decryptionWorker:t,segment:e,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k,doneFn:A,onTransmuxerLog:D,triggerSegmentEventFn:P})=>{P({type:"segmentdecryptionstart"}),decrypt$1({id:e.requestId,key:e.key,encryptedBytes:e.encryptedBytes,decryptionWorker:t,segment:e,doneFn:A},R=>{e.bytes=R,P({type:"segmentdecryptioncomplete",segment:e}),handleSegmentBytes({segment:e,bytes:e.bytes,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k,doneFn:A,onTransmuxerLog:D,triggerSegmentEventFn:P})})},waitForCompletion=({activeXhrs:t,decryptionWorker:e,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k,doneFn:A,onTransmuxerLog:D,triggerSegmentEventFn:P})=>{let R=0,B=!1;return(F,j)=>{if(!B){if(F)return B=!0,abortAll(t),A(F,j);if(R+=1,R===t.length){const N=function(){if(j.encryptedBytes)return decryptSegment({decryptionWorker:e,segment:j,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k,doneFn:A,onTransmuxerLog:D,triggerSegmentEventFn:P});handleSegmentBytes({segment:j,bytes:j.bytes,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k,doneFn:A,onTransmuxerLog:D,triggerSegmentEventFn:P})};if(j.endOfAllRequests=Date.now(),j.map&&j.map.encryptedBytes&&!j.map.bytes)return P({type:"segmentdecryptionstart",segment:j}),decrypt$1({decryptionWorker:e,id:j.requestId+"-init",encryptedBytes:j.map.encryptedBytes,key:j.map.key,segment:j,doneFn:A},Y=>{j.map.bytes=Y,P({type:"segmentdecryptioncomplete",segment:j}),parseInitSegment(j,J=>{if(J)return abortAll(t),A(J,j);N()})});N()}}}},handleLoadEnd=({loadendState:t,abortFn:e})=>n=>{n.target.aborted&&e&&!t.calledAbortFn&&(e(),t.calledAbortFn=!0)},handleProgress=({segment:t,progressFn:e,trackInfoFn:n,timingInfoFn:o,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:m,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:C,dataFn:k})=>A=>{if(!A.target.aborted)return t.stats=merge(t.stats,getProgressStats(A)),!t.stats.firstBytesReceivedAt&&t.stats.bytesReceived&&(t.stats.firstBytesReceivedAt=Date.now()),e(A,t)},mediaSegmentRequest=({xhr:t,xhrOptions:e,decryptionWorker:n,segment:o,abortFn:u,progressFn:l,trackInfoFn:m,timingInfoFn:y,videoSegmentTimingInfoFn:E,audioSegmentTimingInfoFn:C,id3Fn:k,captionsFn:A,isEndOfTimeline:D,endedTimelineFn:P,dataFn:R,doneFn:B,onTransmuxerLog:F,triggerSegmentEventFn:j})=>{const N=[],Y=waitForCompletion({activeXhrs:N,decryptionWorker:n,trackInfoFn:m,timingInfoFn:y,videoSegmentTimingInfoFn:E,audioSegmentTimingInfoFn:C,id3Fn:k,captionsFn:A,isEndOfTimeline:D,endedTimelineFn:P,dataFn:R,doneFn:B,onTransmuxerLog:F,triggerSegmentEventFn:j});if(o.key&&!o.key.bytes){const ce=[o.key];o.map&&!o.map.bytes&&o.map.key&&o.map.key.resolvedUri===o.key.resolvedUri&&ce.push(o.map.key);const he=merge(e,{uri:o.key.resolvedUri,responseType:"arraybuffer",requestType:"segment-key"}),ke=handleKeyResponse(o,ce,Y,j),L={uri:o.key.resolvedUri};j({type:"segmentkeyloadstart",segment:o,keyInfo:L});const d=t(he,ke);N.push(d)}if(o.map&&!o.map.bytes){if(o.map.key&&(!o.key||o.key.resolvedUri!==o.map.key.resolvedUri)){const d=merge(e,{uri:o.map.key.resolvedUri,responseType:"arraybuffer",requestType:"segment-key"}),v=handleKeyResponse(o,[o.map.key],Y,j),w={uri:o.map.key.resolvedUri};j({type:"segmentkeyloadstart",segment:o,keyInfo:w});const c=t(d,v);N.push(c)}const he=merge(e,{uri:o.map.resolvedUri,responseType:"arraybuffer",headers:segmentXhrHeaders(o.map),requestType:"segment-media-initialization"}),ke=handleInitSegmentResponse({segment:o,finishProcessingFn:Y,triggerSegmentEventFn:j});j({type:"segmentloadstart",segment:o});const L=t(he,ke);N.push(L)}const J=merge(e,{uri:o.part&&o.part.resolvedUri||o.resolvedUri,responseType:"arraybuffer",headers:segmentXhrHeaders(o),requestType:"segment"}),ie=handleSegmentResponse({segment:o,finishProcessingFn:Y,responseType:J.responseType,triggerSegmentEventFn:j});j({type:"segmentloadstart",segment:o});const ue=t(J,ie);ue.addEventListener("progress",handleProgress({segment:o,progressFn:l,trackInfoFn:m,timingInfoFn:y,videoSegmentTimingInfoFn:E,audioSegmentTimingInfoFn:C,id3Fn:k,captionsFn:A,isEndOfTimeline:D,endedTimelineFn:P,dataFn:R})),N.push(ue);const Q={};return N.forEach(ce=>{ce.addEventListener("loadend",handleLoadEnd({loadendState:Q,abortFn:u}))}),()=>abortAll(N)},logFn$1=logger("CodecUtils"),getCodecs=function(t){const e=t.attributes||{};if(e.CODECS)return parseCodecs(e.CODECS)},isMaat=(t,e)=>{const n=e.attributes||{};return t&&t.mediaGroups&&t.mediaGroups.AUDIO&&n.AUDIO&&t.mediaGroups.AUDIO[n.AUDIO]},isMuxed=(t,e)=>{if(!isMaat(t,e))return!0;const n=e.attributes||{},o=t.mediaGroups.AUDIO[n.AUDIO];for(const u in o)if(!o[u].uri&&!o[u].playlists)return!0;return!1},unwrapCodecList=function(t){const e={};return t.forEach(({mediaType:n,type:o,details:u})=>{e[n]=e[n]||[],e[n].push(translateLegacyCodec(`${o}${u}`))}),Object.keys(e).forEach(function(n){if(e[n].length>1){logFn$1(`multiple ${n} codecs found as attributes: ${e[n].join(", ")}. Setting playlist codecs to null so that we wait for mux.js to probe segments for real codecs.`),e[n]=null;return}e[n]=e[n][0]}),e},codecCount=function(t){let e=0;return t.audio&&e++,t.video&&e++,e},codecsForPlaylist=function(t,e){const n=e.attributes||{},o=unwrapCodecList(getCodecs(e)||[]);if(isMaat(t,e)&&!o.audio&&!isMuxed(t,e)){const u=unwrapCodecList(codecsFromDefault(t,n.AUDIO)||[]);u.audio&&(o.audio=u.audio)}return o},logFn=logger("PlaylistSelector"),representationToString=function(t){if(!t||!t.playlist)return;const e=t.playlist;return JSON.stringify({id:e.id,bandwidth:t.bandwidth,width:t.width,height:t.height,codecs:e.attributes&&e.attributes.CODECS||""})},safeGetComputedStyle=function(t,e){if(!t)return"";const n=window$1$1.getComputedStyle(t);return n?n[e]:""},stableSort=function(t,e){const n=t.slice();t.sort(function(o,u){const l=e(o,u);return l===0?n.indexOf(o)-n.indexOf(u):l})},comparePlaylistBandwidth=function(t,e){let n,o;return t.attributes.BANDWIDTH&&(n=t.attributes.BANDWIDTH),n=n||window$1$1.Number.MAX_VALUE,e.attributes.BANDWIDTH&&(o=e.attributes.BANDWIDTH),o=o||window$1$1.Number.MAX_VALUE,n-o},comparePlaylistResolution=function(t,e){let n,o;return t.attributes.RESOLUTION&&t.attributes.RESOLUTION.width&&(n=t.attributes.RESOLUTION.width),n=n||window$1$1.Number.MAX_VALUE,e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width&&(o=e.attributes.RESOLUTION.width),o=o||window$1$1.Number.MAX_VALUE,n===o&&t.attributes.BANDWIDTH&&e.attributes.BANDWIDTH?t.attributes.BANDWIDTH-e.attributes.BANDWIDTH:n-o};let simpleSelector=function(t,e,n,o,u,l){if(!t)return;const m={bandwidth:e,width:n,height:o,limitRenditionByPlayerDimensions:u};let y=t.playlists;Playlist.isAudioOnly(t)&&(y=l.getAudioTrackPlaylists_(),m.audioOnly=!0);let E=y.map(ie=>{let ue;const Q=ie.attributes&&ie.attributes.RESOLUTION&&ie.attributes.RESOLUTION.width,ce=ie.attributes&&ie.attributes.RESOLUTION&&ie.attributes.RESOLUTION.height;return ue=ie.attributes&&ie.attributes.BANDWIDTH,ue=ue||window$1$1.Number.MAX_VALUE,{bandwidth:ue,width:Q,height:ce,playlist:ie}});stableSort(E,(ie,ue)=>ie.bandwidth-ue.bandwidth),E=E.filter(ie=>!Playlist.isIncompatible(ie.playlist));let C=E.filter(ie=>Playlist.isEnabled(ie.playlist));C.length||(C=E.filter(ie=>!Playlist.isDisabled(ie.playlist)));const k=C.filter(ie=>ie.bandwidth*Config.BANDWIDTH_VARIANCE<e);let A=k[k.length-1];const D=k.filter(ie=>ie.bandwidth===A.bandwidth)[0];if(u===!1){const ie=D||C[0]||E[0];if(ie&&ie.playlist){let ue="sortedPlaylistReps";return D&&(ue="bandwidthBestRep"),C[0]&&(ue="enabledPlaylistReps"),logFn(`choosing ${representationToString(ie)} using ${ue} with options`,m),ie.playlist}return logFn("could not choose a playlist with options",m),null}const P=k.filter(ie=>ie.width&&ie.height);stableSort(P,(ie,ue)=>ie.width-ue.width);const R=P.filter(ie=>ie.width===n&&ie.height===o);A=R[R.length-1];const B=R.filter(ie=>ie.bandwidth===A.bandwidth)[0];let F,j,N;B||(F=P.filter(ie=>ie.width>n||ie.height>o),j=F.filter(ie=>ie.width===F[0].width&&ie.height===F[0].height),A=j[j.length-1],N=j.filter(ie=>ie.bandwidth===A.bandwidth)[0]);let Y;if(l.leastPixelDiffSelector){const ie=P.map(ue=>(ue.pixelDiff=Math.abs(ue.width-n)+Math.abs(ue.height-o),ue));stableSort(ie,(ue,Q)=>ue.pixelDiff===Q.pixelDiff?Q.bandwidth-ue.bandwidth:ue.pixelDiff-Q.pixelDiff),Y=ie[0]}const J=Y||N||B||D||C[0]||E[0];if(J&&J.playlist){let ie="sortedPlaylistReps";return Y?ie="leastPixelDiffRep":N?ie="resolutionPlusOneRep":B?ie="resolutionBestRep":D?ie="bandwidthBestRep":C[0]&&(ie="enabledPlaylistReps"),logFn(`choosing ${representationToString(J)} using ${ie} with options`,m),J.playlist}return logFn("could not choose a playlist with options",m),null};const lastBandwidthSelector=function(){let t=this.useDevicePixelRatio&&window$1$1.devicePixelRatio||1;return isNaN(this.customPixelRatio)||(t=this.customPixelRatio),simpleSelector(this.playlists.main,this.systemBandwidth,parseInt(safeGetComputedStyle(this.tech_.el(),"width"),10)*t,parseInt(safeGetComputedStyle(this.tech_.el(),"height"),10)*t,this.limitRenditionByPlayerDimensions,this.playlistController_)},movingAverageBandwidthSelector=function(t){let e=-1,n=-1;if(t<0||t>1)throw new Error("Moving average bandwidth decay must be between 0 and 1.");return function(){let o=this.useDevicePixelRatio&&window$1$1.devicePixelRatio||1;return isNaN(this.customPixelRatio)||(o=this.customPixelRatio),e<0&&(e=this.systemBandwidth,n=this.systemBandwidth),this.systemBandwidth>0&&this.systemBandwidth!==n&&(e=t*this.systemBandwidth+(1-t)*e,n=this.systemBandwidth),simpleSelector(this.playlists.main,e,parseInt(safeGetComputedStyle(this.tech_.el(),"width"),10)*o,parseInt(safeGetComputedStyle(this.tech_.el(),"height"),10)*o,this.limitRenditionByPlayerDimensions,this.playlistController_)}},minRebufferMaxBandwidthSelector=function(t){const{main:e,currentTime:n,bandwidth:o,duration:u,segmentDuration:l,timeUntilRebuffer:m,currentTimeline:y,syncController:E}=t,C=e.playlists.filter(R=>!Playlist.isIncompatible(R));let k=C.filter(Playlist.isEnabled);k.length||(k=C.filter(R=>!Playlist.isDisabled(R)));const D=k.filter(Playlist.hasAttribute.bind(null,"BANDWIDTH")).map(R=>{const F=E.getSyncPoint(R,u,y,n)?1:2,N=Playlist.estimateSegmentRequestTime(l,o,R)*F-m;return{playlist:R,rebufferingImpact:N}}),P=D.filter(R=>R.rebufferingImpact<=0);return stableSort(P,(R,B)=>comparePlaylistBandwidth(B.playlist,R.playlist)),P.length?P[0]:(stableSort(D,(R,B)=>R.rebufferingImpact-B.rebufferingImpact),D[0]||null)},lowestBitrateCompatibleVariantSelector=function(){const t=this.playlists.main.playlists.filter(Playlist.isEnabled);return stableSort(t,(n,o)=>comparePlaylistBandwidth(n,o)),t.filter(n=>!!codecsForPlaylist(this.playlists.main,n).video)[0]||null},concatSegments=t=>{let e=0,n;return t.bytes&&(n=new Uint8Array(t.bytes),t.segments.forEach(o=>{n.set(o,e),e+=o.byteLength})),n};function compactSegmentUrlDescription(t){try{return new URL(t).pathname.split("/").slice(-2).join("/")}catch{return""}}const createCaptionsTrackIfNotExists=function(t,e,n){if(!t[n]){e.trigger({type:"usage",name:"vhs-608"});let o=n;/^cc708_/.test(n)&&(o="SERVICE"+n.split("_")[1]);const u=e.textTracks().getTrackById(o);if(u)t[n]=u;else{const l=e.options_.vhs&&e.options_.vhs.captionServices||{};let m=n,y=n,E=!1;const C=l[o];C&&(m=C.label,y=C.language,E=C.default),t[n]=e.addRemoteTextTrack({kind:"captions",id:o,default:E,label:m,language:y},!1).track}}},addCaptionData=function({inbandTextTracks:t,captionArray:e,timestampOffset:n}){if(!e)return;const o=window$1$1.WebKitDataCue||window$1$1.VTTCue;e.forEach(u=>{const l=u.stream;u.content?u.content.forEach(m=>{const y=new o(u.startTime+n,u.endTime+n,m.text);y.line=m.line,y.align="left",y.position=m.position,y.positionAlign="line-left",t[l].addCue(y)}):t[l].addCue(new o(u.startTime+n,u.endTime+n,u.text))})},deprecateOldCue=function(t){Object.defineProperties(t.frame,{id:{get(){return videojs.log.warn("cue.frame.id is deprecated. Use cue.value.key instead."),t.value.key}},value:{get(){return videojs.log.warn("cue.frame.value is deprecated. Use cue.value.data instead."),t.value.data}},privateData:{get(){return videojs.log.warn("cue.frame.privateData is deprecated. Use cue.value.data instead."),t.value.data}}})},addMetadata=({inbandTextTracks:t,metadataArray:e,timestampOffset:n,videoDuration:o})=>{if(!e)return;const u=window$1$1.WebKitDataCue||window$1$1.VTTCue,l=t.metadataTrack_;if(!l||(e.forEach(k=>{const A=k.cueTime+n;typeof A!="number"||window$1$1.isNaN(A)||A<0||!(A<1/0)||!k.frames||!k.frames.length||k.frames.forEach(D=>{const P=new u(A,A,D.value||D.url||D.data||"");P.frame=D,P.value=D,deprecateOldCue(P),l.addCue(P)})}),!l.cues||!l.cues.length))return;const m=l.cues,y=[];for(let k=0;k<m.length;k++)m[k]&&y.push(m[k]);const E=y.reduce((k,A)=>{const D=k[A.startTime]||[];return D.push(A),k[A.startTime]=D,k},{}),C=Object.keys(E).sort((k,A)=>Number(k)-Number(A));C.forEach((k,A)=>{const D=E[k],P=isFinite(o)?o:k,R=Number(C[A+1])||P;D.forEach(B=>{B.endTime=R})})},dateRangeAttr={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"},dateRangeKeysToOmit=new Set(["id","class","startDate","duration","endDate","endOnNext","startTime","endTime","processDateRange"]),addDateRangeMetadata=({inbandTextTracks:t,dateRanges:e})=>{const n=t.metadataTrack_;if(!n)return;const o=window$1$1.WebKitDataCue||window$1$1.VTTCue;e.forEach(u=>{for(const l of Object.keys(u)){if(dateRangeKeysToOmit.has(l))continue;const m=new o(u.startTime,u.endTime,"");m.id=u.id,m.type="com.apple.quicktime.HLS",m.value={key:dateRangeAttr[l],data:u[l]},(l==="scte35Out"||l==="scte35In")&&(m.value.data=new Uint8Array(m.value.data.match(/[\da-f]{2}/gi)).buffer),n.addCue(m)}u.processDateRange()})},createMetadataTrackIfNotExists=(t,e,n)=>{t.metadataTrack_||(t.metadataTrack_=n.addRemoteTextTrack({kind:"metadata",label:"Timed Metadata"},!1).track,videojs.browser.IS_ANY_SAFARI||(t.metadataTrack_.inBandMetadataTrackDispatchType=e))},removeCuesFromTrack=function(t,e,n){let o,u;if(n&&n.cues)for(o=n.cues.length;o--;)u=n.cues[o],u.startTime>=t&&u.endTime<=e&&n.removeCue(u)},removeDuplicateCuesFromTrack=function(t){const e=t.cues;if(!e)return;const n={};for(let o=e.length-1;o>=0;o--){const u=e[o],l=`${u.startTime}-${u.endTime}-${u.text}`;n[l]?t.removeCue(u):n[l]=u}},gopsSafeToAlignWith=(t,e,n)=>{if(typeof e>"u"||e===null||!t.length)return[];const o=Math.ceil((e-n+3)*clock.ONE_SECOND_IN_TS);let u;for(u=0;u<t.length&&!(t[u].pts>o);u++);return t.slice(u)},updateGopBuffer=(t,e,n)=>{if(!e.length)return t;if(n)return e.slice();const o=e[0].pts;let u=0;for(u;u<t.length&&!(t[u].pts>=o);u++);return t.slice(0,u).concat(e)},removeGopBuffer=(t,e,n,o)=>{const u=Math.ceil((e-o)*clock.ONE_SECOND_IN_TS),l=Math.ceil((n-o)*clock.ONE_SECOND_IN_TS),m=t.slice();let y=t.length;for(;y--&&!(t[y].pts<=l););if(y===-1)return m;let E=y+1;for(;E--&&!(t[E].pts<=u););return E=Math.max(E,0),m.splice(E,y-E+1),m},shallowEqual=function(t,e){if(!t&&!e||!t&&e||t&&!e)return!1;if(t===e)return!0;const n=Object.keys(t).sort(),o=Object.keys(e).sort();if(n.length!==o.length)return!1;for(let u=0;u<n.length;u++){const l=n[u];if(l!==o[u]||t[l]!==e[l])return!1}return!0},getSyncSegmentCandidate=function(t,e,n){e=e||[];const o=[];let u=0;for(let l=0;l<e.length;l++){const m=e[l];if(t===m.timeline&&(o.push(l),u+=m.duration,u>n))return l}return o.length===0?0:o[o.length-1]},MIN_BACK_BUFFER=1,CHECK_BUFFER_DELAY=500,finite=t=>typeof t=="number"&&isFinite(t),MIN_SEGMENT_DURATION_TO_SAVE_STATS=1/60,illegalMediaSwitch=(t,e,n)=>t!=="main"||!e||!n?null:!n.hasAudio&&!n.hasVideo?"Neither audio nor video found in segment.":e.hasVideo&&!n.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&&n.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,safeBackBufferTrimTime=(t,e,n)=>{let o=e-Config.BACK_BUFFER_LENGTH;t.length&&(o=Math.max(o,t.start(0)));const u=e-n;return Math.min(u,o)},segmentInfoString=t=>{const{startOfSegment:e,duration:n,segment:o,part:u,playlist:{mediaSequence:l,id:m,segments:y=[]},mediaIndex:E,partIndex:C,timeline:k}=t,A=y.length-1;let D="mediaIndex/partIndex increment";t.getMediaInfoForTime?D=`getMediaInfoForTime (${t.getMediaInfoForTime})`:t.isSyncRequest&&(D="getSyncSegmentCandidate (isSyncRequest)"),t.independent&&(D+=` with independent ${t.independent}`);const P=typeof C=="number",R=t.segment.uri?"segment":"pre-segment",B=P?getKnownPartCount({preloadSegment:o})-1:0;return`${R} [${l+E}/${l+A}]`+(P?` part [${C}/${B}]`:"")+` segment start/end [${o.start} => ${o.end}]`+(P?` part start/end [${u.start} => ${u.end}]`:"")+` startOfSegment [${e}] duration [${n}] timeline [${k}] selected by [${D}] playlist [${m}]`},timingInfoPropertyForMedia=t=>`${t}TimingInfo`,timestampOffsetForSegment=({segmentTimeline:t,currentTimeline:e,startOfSegment:n,buffered:o,overrideCheck:u})=>!u&&t===e?null:t<e?n:o.length?o.end(o.length-1):n,shouldWaitForTimelineChange=({timelineChangeController:t,currentTimeline:e,segmentTimeline:n,loaderType:o,audioDisabled:u})=>{if(e===n)return!1;if(o==="audio"){const l=t.lastTimelineChange({type:"main"});return!l||l.to!==n}if(o==="main"&&u){const l=t.pendingTimelineChange({type:"audio"});return!(l&&l.to===n)}return!1},shouldFixBadTimelineChanges=t=>{if(!t)return!1;const e=t.pendingTimelineChange({type:"audio"}),n=t.pendingTimelineChange({type:"main"}),o=e&&n,u=o&&e.to!==n.to;return!!(o&&e.from!==-1&&n.from!==-1&&u)},fixBadTimelineChange=t=>{t&&(t.pause(),t.resetEverything(),t.load())},isAudioTimelineBehind=t=>{const e=t.timelineChangeController_.pendingTimelineChange({type:"audio"}),n=t.timelineChangeController_.pendingTimelineChange({type:"main"});return e&&n&&e.to<n.to},checkAndFixTimelines=t=>{const e=t.pendingSegment_;if(!e)return;if(shouldWaitForTimelineChange({timelineChangeController:t.timelineChangeController_,currentTimeline:t.currentTimeline_,segmentTimeline:e.timeline,loaderType:t.loaderType_,audioDisabled:t.audioDisabled_})&&shouldFixBadTimelineChanges(t.timelineChangeController_)){if(isAudioTimelineBehind(t)){t.timelineChangeController_.trigger("audioTimelineBehind");return}fixBadTimelineChange(t)}},mediaDuration=t=>{let e=0;return["video","audio"].forEach(function(n){const o=t[`${n}TimingInfo`];if(!o)return;const{start:u,end:l}=o;let m;typeof u=="bigint"||typeof l=="bigint"?m=window$1$1.BigInt(l)-window$1$1.BigInt(u):typeof u=="number"&&typeof l=="number"&&(m=l-u),typeof m<"u"&&m>e&&(e=m)}),typeof e=="bigint"&&e<Number.MAX_SAFE_INTEGER&&(e=Number(e)),e},segmentTooLong=({segmentDuration:t,maxDuration:e})=>t?Math.round(t)>e+TIME_FUDGE_FACTOR:!1,getTroublesomeSegmentDurationMessage=(t,e)=>{if(e!=="hls")return null;const n=mediaDuration({audioTimingInfo:t.audioTimingInfo,videoTimingInfo:t.videoTimingInfo});if(!n)return null;const o=t.playlist.targetDuration,u=segmentTooLong({segmentDuration:n,maxDuration:o*2}),l=segmentTooLong({segmentDuration:n,maxDuration:o}),m=`Segment with index ${t.mediaIndex} from playlist ${t.playlist.id} has a duration of ${n} when the reported duration is ${t.duration} and the target duration is ${o}. 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 u||l?{severity:u?"warn":"info",message:m}:null},segmentInfoPayload=({type:t,segment:e})=>{if(!e)return;const n=!!(e.key||e.map&&e.map.ke),o=!!(e.map&&!e.map.bytes),u=e.startOfSegment===void 0?e.start:e.startOfSegment;return{type:t||e.type,uri:e.resolvedUri||e.uri,start:u,duration:e.duration,isEncrypted:n,isMediaInitialization:o}};class SegmentLoader extends videojs.EventTarget{constructor(e,n={}){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_=logger(`SegmentLoader[${this.loaderType_}]`),Object.defineProperty(this,"state",{get(){return this.state_},set(o){o!==this.state_&&(this.logger_(`${this.state_} -> ${o}`),this.state_=o,this.trigger("statechange"))}}),this.sourceUpdater_.on("ready",()=>{this.hasEnoughInfoToAppend_()?this.processCallQueue_():checkAndFixTimelines(this)}),this.sourceUpdater_.on("codecschange",o=>{this.trigger(_extends$2({type:"codecschange"},o))}),this.loaderType_==="main"&&this.timelineChangeController_.on("pendingtimelinechange",()=>{this.hasEnoughInfoToAppend_()?this.processCallQueue_():checkAndFixTimelines(this)}),this.loaderType_==="audio"&&this.timelineChangeController_.on("timelinechange",o=>{this.trigger(_extends$2({type:"timelinechange"},o)),this.hasEnoughInfoToLoad_()?this.processLoadQueue_():checkAndFixTimelines(this),this.hasEnoughInfoToAppend_()?this.processCallQueue_():checkAndFixTimelines(this)})}get mediaSequenceSync_(){return this.syncController_.getMediaSequenceSync(this.loaderType_)}createTransmuxer_(){return segmentTransmuxer.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_&&window$1$1.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,window$1$1.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_&&segmentTransmuxer.reset(this.transmuxer_),this.gopBuffer_.length=0,this.pause(),this.trigger("ended")}buffered_(){const e=this.getMediaInfo_();if(!this.sourceUpdater_||!e)return createTimeRanges();if(this.loaderType_==="main"){const{hasAudio:n,hasVideo:o,isMuxed:u}=e;if(o&&n&&!this.audioDisabled_&&!u)return this.sourceUpdater_.buffered();if(o)return this.sourceUpdater_.videoBuffered()}return this.sourceUpdater_.audioBuffered()}initSegmentForMap(e,n=!1){if(!e)return null;const o=initSegmentId(e);let u=this.initSegments_[o];return n&&!u&&e.bytes&&(this.initSegments_[o]=u={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:e.bytes,tracks:e.tracks,timescales:e.timescales}),u||e}segmentKey(e,n=!1){if(!e)return null;const o=segmentKeyId(e);let u=this.keyCache_[o];this.cacheEncryptionKeys_&&n&&!u&&e.bytes&&(this.keyCache_[o]=u={resolvedUri:e.resolvedUri,bytes:e.bytes});const l={resolvedUri:(u||e).resolvedUri};return u&&(l.bytes=u.bytes),l}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,n={}){if(!e)return;const o=this.playlist_,u=this.pendingSegment_;this.playlist_=e,this.xhrOptions_=n,this.state==="INIT"&&(e.syncInfo={mediaSequence:e.mediaSequence,time:0},this.loaderType_==="main"&&this.syncController_.setDateTimeMappingForStart(e));let l=null;if(o&&(o.id?l=o.id:o.uri&&(l=o.uri)),this.logger_(`playlist update [${l} => ${e.id||e.uri}]`),this.mediaSequenceSync_&&(this.mediaSequenceSync_.update(e,this.currentTime_()),this.logger_(`Playlist update:
currentTime: ${this.currentTime_()}
bufferedEnd: ${lastBufferedEnd(this.buffered_())}
`,this.mediaSequenceSync_.diagnostics)),this.trigger("syncinfoupdate"),this.state==="INIT"&&this.couldBeginLoading_())return this.init_();if(!o||o.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 m=e.mediaSequence-o.mediaSequence;if(this.logger_(`live window shift [${m}]`),this.mediaIndex!==null)if(this.mediaIndex-=m,this.mediaIndex<0)this.mediaIndex=null,this.partIndex=null;else{const y=this.playlist_.segments[this.mediaIndex];if(this.partIndex&&(!y.parts||!y.parts.length||!y.parts[this.partIndex])){const E=this.mediaIndex;this.logger_(`currently processing part (index ${this.partIndex}) no longer exists.`),this.resetLoader(),this.mediaIndex=E}}u&&(u.mediaIndex-=m,u.mediaIndex<0?(u.mediaIndex=null,u.partIndex=null):(u.mediaIndex>=0&&(u.segment=e.segments[u.mediaIndex]),u.partIndex>=0&&u.segment.parts&&(u.part=u.segment.parts[u.partIndex]))),this.syncController_.saveExpiredSegmentInfo(o,e)}pause(){this.checkBufferTimeout_&&(window$1$1.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_&&segmentTransmuxer.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,n,o=()=>{},u=!1){if(n===1/0&&(n=this.duration_()),n<=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 l=1;const m=()=>{l--,l===0&&o()};(u||!this.audioDisabled_)&&(l++,this.sourceUpdater_.removeAudio(e,n,m)),(u||this.loaderType_==="main")&&(this.gopBuffer_=removeGopBuffer(this.gopBuffer_,e,n,this.timeMapping_),l++,this.sourceUpdater_.removeVideo(e,n,m));for(const y in this.inbandTextTracks_)removeCuesFromTrack(e,n,this.inbandTextTracks_[y]);removeCuesFromTrack(e,n,this.segmentMetadataTrack_),m()}monitorBuffer_(){this.checkBufferTimeout_&&window$1$1.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=window$1$1.setTimeout(this.monitorBufferTick_.bind(this),1)}monitorBufferTick_(){this.state==="READY"&&this.fillBuffer_(),this.checkBufferTimeout_&&window$1$1.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=window$1$1.setTimeout(this.monitorBufferTick_.bind(this),CHECK_BUFFER_DELAY)}fillBuffer_(){if(this.sourceUpdater_.updating())return;const e=this.chooseNextRequest_();if(!e)return;const n={segmentInfo:segmentInfoPayload({type:this.loaderType_,segment:e})};this.trigger({type:"segmentselected",metadata:n}),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,n=this.playlist_,o=this.partIndex){if(!n||!this.mediaSource_)return!1;const u=typeof e=="number"&&n.segments[e],l=e+1===n.segments.length,m=!u||!u.parts||o+1===u.parts.length;return n.endList&&this.mediaSource_.readyState==="open"&&l&&m}chooseNextRequest_(){const e=this.buffered_(),n=lastBufferedEnd(e)||0,o=timeAheadOf(e,this.currentTime_()),u=!this.hasPlayed_()&&o>=1,l=o>=this.goalBufferLength_(),m=this.playlist_.segments;if(!m.length||u||l)return null;this.syncPoint_=this.syncPoint_||this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_(),this.loaderType_);const y={partIndex:null,mediaIndex:null,startOfSegment:null,playlist:this.playlist_,isSyncRequest:!this.syncPoint_};if(y.isSyncRequest)y.mediaIndex=getSyncSegmentCandidate(this.currentTimeline_,m,n),this.logger_(`choose next request. Can not find sync point. Fallback to media Index: ${y.mediaIndex}`);else if(this.mediaIndex!==null){const D=m[this.mediaIndex],P=typeof this.partIndex=="number"?this.partIndex:-1;y.startOfSegment=D.end?D.end:n,D.parts&&D.parts[P+1]?(y.mediaIndex=this.mediaIndex,y.partIndex=P+1):y.mediaIndex=this.mediaIndex+1}else{let D,P,R;const B=this.fetchAtBuffer_?n:this.currentTime_();if(this.mediaSequenceSync_&&this.logger_(`chooseNextRequest_ request after Quality Switch:
For TargetTime: ${B}.
CurrentTime: ${this.currentTime_()}
BufferedEnd: ${n}
Fetch At Buffer: ${this.fetchAtBuffer_}
`,this.mediaSequenceSync_.diagnostics),this.mediaSequenceSync_&&this.mediaSequenceSync_.isReliable){const F=this.getSyncInfoFromMediaSequenceSync_(B);if(!F){const j="No sync info found while using media sequence sync";return this.error({message:j,metadata:{errorType:videojs.Error.StreamingFailedToSelectNextSegment,error:new Error(j)}}),this.logger_("chooseNextRequest_ - no sync info found using media sequence sync"),null}this.logger_(`chooseNextRequest_ mediaSequence syncInfo (${F.start} --> ${F.end})`),D=F.segmentIndex,P=F.partIndex,R=F.start}else{this.logger_("chooseNextRequest_ - fallback to a regular segment selection algorithm, based on a syncPoint.");const F=Playlist.getMediaInfoForTime({exactManifestTimings:this.exactManifestTimings,playlist:this.playlist_,currentTime:B,startingPartIndex:this.syncPoint_.partIndex,startingSegmentIndex:this.syncPoint_.segmentIndex,startTime:this.syncPoint_.time});D=F.segmentIndex,P=F.partIndex,R=F.startTime}y.getMediaInfoForTime=this.fetchAtBuffer_?`bufferedEnd ${B}`:`currentTime ${B}`,y.mediaIndex=D,y.startOfSegment=R,y.partIndex=P,this.logger_(`choose next request. Playlist switched and we have a sync point. Media Index: ${y.mediaIndex} `)}const E=m[y.mediaIndex];let C=E&&typeof y.partIndex=="number"&&E.parts&&E.parts[y.partIndex];if(!E||typeof y.partIndex=="number"&&!C)return null;typeof y.partIndex!="number"&&E.parts&&(y.partIndex=0,C=E.parts[0]);const k=this.vhs_.playlists&&this.vhs_.playlists.main&&this.vhs_.playlists.main.independentSegments||this.playlist_.independentSegments;if(!o&&C&&!k&&!C.independent)if(y.partIndex===0){const D=m[y.mediaIndex-1],P=D.parts&&D.parts.length&&D.parts[D.parts.length-1];P&&P.independent&&(y.mediaIndex-=1,y.partIndex=D.parts.length-1,y.independent="previous segment")}else E.parts[y.partIndex-1].independent&&(y.partIndex-=1,y.independent="previous part");const A=this.mediaSource_&&this.mediaSource_.readyState==="ended";return y.mediaIndex>=m.length-1&&A&&!this.seeking_()?null:(this.shouldForceTimestampOffsetAfterResync_&&(this.shouldForceTimestampOffsetAfterResync_=!1,y.forceTimestampOffset=!0,this.logger_("choose next request. Force timestamp offset after loader resync")),this.generateSegmentInfo_(y))}getSyncInfoFromMediaSequenceSync_(e){if(!this.mediaSequenceSync_)return null;const n=Math.max(e,this.mediaSequenceSync_.start);e!==n&&this.logger_(`getSyncInfoFromMediaSequenceSync_. Pulled target time from ${e} to ${n}`);const o=this.mediaSequenceSync_.getSyncInfoForTime(n);if(!o)return null;if(!o.isAppended)return o;const u=this.mediaSequenceSync_.getSyncInfoForTime(o.end);return u?(u.isAppended&&this.logger_("getSyncInfoFromMediaSequenceSync_: We encounter unexpected scenario where next media sequence sync info is also appended!"),u):null}generateSegmentInfo_(e){const{independent:n,playlist:o,mediaIndex:u,startOfSegment:l,isSyncRequest:m,partIndex:y,forceTimestampOffset:E,getMediaInfoForTime:C}=e,k=o.segments[u],A=typeof y=="number"&&k.parts[y],D={requestId:"segment-loader-"+Math.random(),uri:A&&A.resolvedUri||k.resolvedUri,mediaIndex:u,partIndex:A?y:null,isSyncRequest:m,startOfSegment:l,playlist:o,bytes:null,encryptedBytes:null,timestampOffset:null,timeline:k.timeline,duration:A&&A.duration||k.duration,segment:k,part:A,byteLength:0,transmuxer:this.transmuxer_,getMediaInfoForTime:C,independent:n},P=typeof E<"u"?E:this.isPendingTimestampOffset_;D.timestampOffset=this.timestampOffsetForSegment_({segmentTimeline:k.timeline,currentTimeline:this.currentTimeline_,startOfSegment:l,buffered:this.buffered_(),overrideCheck:P});const R=lastBufferedEnd(this.sourceUpdater_.audioBuffered());return typeof R=="number"&&(D.audioAppendStart=R-this.sourceUpdater_.audioTimestampOffset()),this.sourceUpdater_.videoBuffered().length&&(D.gopsToAlignWith=gopsSafeToAlignWith(this.gopBuffer_,this.currentTime_()-this.sourceUpdater_.videoTimestampOffset(),this.timeMapping_)),D}timestampOffsetForSegment_(e){return timestampOffsetForSegment(e)}earlyAbortWhenNeeded_(e){if(this.vhs_.tech_.paused()||!this.xhrOptions_.timeout||!this.playlist_.attributes.BANDWIDTH||Date.now()-(e.firstBytesReceivedAt||Date.now())<1e3)return;const n=this.currentTime_(),o=e.bandwidth,u=this.pendingSegment_.duration,l=Playlist.estimateSegmentRequestTime(u,o,this.playlist_,e.bytesReceived),m=timeUntilRebuffer(this.buffered_(),n,this.vhs_.tech_.playbackRate())-1;if(l<=m)return;const y=minRebufferMaxBandwidthSelector({main:this.vhs_.playlists.main,currentTime:n,bandwidth:o,duration:this.duration_(),segmentDuration:u,timeUntilRebuffer:m,currentTimeline:this.currentTimeline_,syncController:this.syncController_});if(!y)return;const C=l-m-y.rebufferingImpact;let k=.5;m<=TIME_FUDGE_FACTOR&&(k=1),!(!y.playlist||y.playlist.uri===this.playlist_.uri||C<k)&&(this.bandwidth=y.playlist.attributes.BANDWIDTH*Config.BANDWIDTH_VARIANCE+1,this.trigger("earlyabort"))}handleAbort_(e){this.logger_(`Aborting ${segmentInfoString(e)}`),this.mediaRequestsAborted+=1}handleProgress_(e,n){this.earlyAbortWhenNeeded_(n.stats),!this.checkForAbort_(n.requestId)&&this.trigger("progress")}handleTrackInfo_(e,n){const{hasAudio:o,hasVideo:u}=n,l={segmentInfo:segmentInfoPayload({type:this.loaderType_,segment:e}),trackInfo:{hasAudio:o,hasVideo:u}};this.trigger({type:"segmenttransmuxingtrackinfoavailable",metadata:l}),this.earlyAbortWhenNeeded_(e.stats),!this.checkForAbort_(e.requestId)&&(this.checkForIllegalMediaSwitch(n)||(n=n||{},shallowEqual(this.currentMediaInfo_,n)||(this.appendInitSegment_={audio:!0,video:!0},this.startingMediaInfo_=n,this.currentMediaInfo_=n,this.logger_("trackinfo update",n),this.trigger("trackinfo")),!this.checkForAbort_(e.requestId)&&(this.pendingSegment_.trackInfo=n,this.hasEnoughInfoToAppend_()?this.processCallQueue_():checkAndFixTimelines(this))))}handleTimingInfo_(e,n,o,u){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;const l=this.pendingSegment_,m=timingInfoPropertyForMedia(n);l[m]=l[m]||{},l[m][o]=u,this.logger_(`timinginfo: ${n} - ${o} - ${u}`),this.hasEnoughInfoToAppend_()?this.processCallQueue_():checkAndFixTimelines(this)}handleCaptions_(e,n){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;if(n.length===0){this.logger_("SegmentLoader received no captions from a caption event");return}if(!this.pendingSegment_.hasAppendedData_){this.metadataQueue_.caption.push(this.handleCaptions_.bind(this,e,n));return}const u=this.sourceUpdater_.videoTimestampOffset()===null?this.sourceUpdater_.audioTimestampOffset():this.sourceUpdater_.videoTimestampOffset(),l={};n.forEach(m=>{l[m.stream]=l[m.stream]||{startTime:1/0,captions:[],endTime:0};const y=l[m.stream];y.startTime=Math.min(y.startTime,m.startTime+u),y.endTime=Math.max(y.endTime,m.endTime+u),y.captions.push(m)}),Object.keys(l).forEach(m=>{const{startTime:y,endTime:E,captions:C}=l[m],k=this.inbandTextTracks_;this.logger_(`adding cues from ${y} -> ${E} for ${m}`),createCaptionsTrackIfNotExists(k,this.vhs_.tech_,m),removeCuesFromTrack(y,E,k[m]),addCaptionData({captionArray:C,inbandTextTracks:k,timestampOffset:u})}),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})}handleId3_(e,n,o){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;if(!this.pendingSegment_.hasAppendedData_){this.metadataQueue_.id3.push(this.handleId3_.bind(this,e,n,o));return}this.addMetadataToTextTrack(o,n,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(n=>n())}processLoadQueue_(){const e=this.loadQueue_;this.loadQueue_=[],e.forEach(n=>n())}hasEnoughInfoToLoad_(){if(this.loaderType_!=="audio")return!0;const e=this.pendingSegment_;return e?this.getCurrentMediaInfo_()?!shouldWaitForTimelineChange({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_,n=this.getCurrentMediaInfo_();if(!e||!n)return!1;const{hasAudio:o,hasVideo:u,isMuxed:l}=n;return!(u&&!e.videoTimingInfo||o&&!this.audioDisabled_&&!l&&!e.audioTimingInfo||shouldWaitForTimelineChange({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:e.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}))}handleData_(e,n){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;if(this.callQueue_.length||!this.hasEnoughInfoToAppend_()){checkAndFixTimelines(this),this.callQueue_.push(this.handleData_.bind(this,e,n));return}const o=this.pendingSegment_;if(this.setTimeMapping_(o.timeline),this.updateMediaSecondsLoaded_(o.part||o.segment),this.mediaSource_.readyState!=="closed"){if(e.map&&(e.map=this.initSegmentForMap(e.map,!0),o.segment.map=e.map),e.key&&this.segmentKey(e.key,!0),o.isFmp4=e.isFmp4,o.timingInfo=o.timingInfo||{},o.isFmp4)this.trigger("fmp4"),o.timingInfo.start=o[timingInfoPropertyForMedia(n.type)].start;else{const u=this.getCurrentMediaInfo_(),l=this.loaderType_==="main"&&u&&u.hasVideo;let m;l&&(m=o.videoTimingInfo.start),o.timingInfo.start=this.trueSegmentStart_({currentStart:o.timingInfo.start,playlist:o.playlist,mediaIndex:o.mediaIndex,currentVideoTimestampOffset:this.sourceUpdater_.videoTimestampOffset(),useVideoTimingInfo:l,firstVideoFrameTimeForData:m,videoTimingInfo:o.videoTimingInfo,audioTimingInfo:o.audioTimingInfo})}if(this.updateAppendInitSegmentStatus(o,n.type),this.updateSourceBufferTimestampOffset_(o),o.isSyncRequest){this.updateTimingInfoEnd_(o),this.syncController_.saveSegmentTimingInfo({segmentInfo:o,shouldSaveTimelineMapping:this.loaderType_==="main"});const u=this.chooseNextRequest_();if(u.mediaIndex!==o.mediaIndex||u.partIndex!==o.partIndex){this.logger_("sync segment was incorrect, not appending");return}this.logger_("sync segment was correct, appending")}o.hasAppendedData_=!0,this.processMetadataQueue_(),this.appendData_(o,n)}}updateAppendInitSegmentStatus(e,n){this.loaderType_==="main"&&typeof e.timestampOffset=="number"&&!e.changedTimestampOffset&&(this.appendInitSegment_={audio:!0,video:!0}),this.playlistOfLastInitSegment_[n]!==e.playlist&&(this.appendInitSegment_[n]=!0)}getInitSegmentAndUpdateState_({type:e,initSegment:n,map:o,playlist:u}){if(o){const l=initSegmentId(o);if(this.activeInitSegmentId_===l)return null;n=this.initSegmentForMap(o,!0).bytes,this.activeInitSegmentId_=l}return n&&this.appendInitSegment_[e]?(this.playlistOfLastInitSegment_[e]=u,this.appendInitSegment_[e]=!1,this.activeInitSegmentId_=null,n):null}handleQuotaExceededError_({segmentInfo:e,type:n,bytes:o},u){const l=this.sourceUpdater_.audioBuffered(),m=this.sourceUpdater_.videoBuffered();l.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the audio buffer: "+timeRangesToArray(l).join(", ")),m.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the video buffer: "+timeRangesToArray(m).join(", "));const y=l.length?l.start(0):0,E=l.length?l.end(l.length-1):0,C=m.length?m.start(0):0,k=m.length?m.end(m.length-1):0;if(E-y<=MIN_BACK_BUFFER&&k-C<=MIN_BACK_BUFFER){this.logger_(`On QUOTA_EXCEEDED_ERR, single segment too large to append to buffer, triggering an error. Appended byte length: ${o.byteLength}, audio buffer: ${timeRangesToArray(l).join(", ")}, video buffer: ${timeRangesToArray(m).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:n,bytes:o}));const D=this.currentTime_()-MIN_BACK_BUFFER;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 ${MIN_BACK_BUFFER}s`),this.waitingOnRemove_=!1,this.quotaExceededErrorRetryTimeout_=window$1$1.setTimeout(()=>{this.logger_("On QUOTA_EXCEEDED_ERR, re-processing call queue"),this.quotaExceededErrorRetryTimeout_=null,this.processCallQueue_()},MIN_BACK_BUFFER*1e3)},!0)}handleAppendError_({segmentInfo:e,type:n,bytes:o},u){if(u){if(u.code===QUOTA_EXCEEDED_ERR){this.handleQuotaExceededError_({segmentInfo:e,type:n,bytes:o});return}this.logger_("Received non QUOTA_EXCEEDED_ERR on append",u),this.error({message:`${n} append of ${o.length}b failed for segment #${e.mediaIndex} in playlist ${e.playlist.id}`,metadata:{errorType:videojs.Error.StreamingFailedToAppendSegment}}),this.trigger("appenderror")}}appendToSourceBuffer_({segmentInfo:e,type:n,initSegment:o,data:u,bytes:l}){if(!l){const y=[u];let E=u.byteLength;o&&(y.unshift(o),E+=o.byteLength),l=concatSegments({bytes:E,segments:y})}const m={segmentInfo:segmentInfoPayload({type:this.loaderType_,segment:e})};this.trigger({type:"segmentappendstart",metadata:m}),this.sourceUpdater_.appendBuffer({segmentInfo:e,type:n,bytes:l},this.handleAppendError_.bind(this,{segmentInfo:e,type:n,bytes:l}))}handleSegmentTimingInfo_(e,n,o){if(!this.pendingSegment_||n!==this.pendingSegment_.requestId)return;const u=this.pendingSegment_.segment,l=`${e}TimingInfo`;u[l]||(u[l]={}),u[l].transmuxerPrependedSeconds=o.prependedContentDuration||0,u[l].transmuxedPresentationStart=o.start.presentation,u[l].transmuxedDecodeStart=o.start.decode,u[l].transmuxedPresentationEnd=o.end.presentation,u[l].transmuxedDecodeEnd=o.end.decode,u[l].baseMediaDecodeTime=o.baseMediaDecodeTime}appendData_(e,n){const{type:o,data:u}=n;if(!u||!u.byteLength||o==="audio"&&this.audioDisabled_)return;const l=this.getInitSegmentAndUpdateState_({type:o,initSegment:n.initSegment,playlist:e.playlist,map:e.isFmp4?e.segment.map:null});this.appendToSourceBuffer_({segmentInfo:e,type:o,initSegment:l,data:u})}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_()){checkAndFixTimelines(this),this.loadQueue_.push(()=>{const n=_extends$2({},e,{forceTimestampOffset:!0});_extends$2(e,this.generateSegmentInfo_(n)),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 n=this.createSimplifiedSegmentObj_(e),o=this.isEndOfStream_(e.mediaIndex,e.playlist,e.partIndex),u=this.mediaIndex!==null,l=e.timeline!==this.currentTimeline_&&e.timeline>0,m=o||u&&l;this.logger_(`Requesting
${compactSegmentUrlDescription(e.uri)}
${segmentInfoString(e)}`),n.map&&!n.map.bytes&&(this.logger_("going to request init segment."),this.appendInitSegment_={video:!0,audio:!0}),e.abortRequests=mediaSegmentRequest({xhr:this.vhs_.xhr,xhrOptions:this.xhrOptions_,decryptionWorker:this.decrypter_,segment:n,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:m,endedTimelineFn:()=>{this.logger_("received endedtimeline callback")},id3Fn:this.handleId3_.bind(this),dataFn:this.handleData_.bind(this),doneFn:this.segmentRequestFinished_.bind(this),onTransmuxerLog:({message:y,level:E,stream:C})=>{this.logger_(`${segmentInfoString(e)} logged from transmuxer stream ${C} as a ${E}: ${y}`)},triggerSegmentEventFn:({type:y,segment:E,keyInfo:C,trackInfo:k,timingInfo:A})=>{const P={segmentInfo:segmentInfoPayload({segment:E})};C&&(P.keyInfo=C),k&&(P.trackInfo=k),A&&(P.timingInfo=A),this.trigger({type:y,metadata:P})}})}trimBackBuffer_(e){const n=safeBackBufferTrimTime(this.seekable_(),this.currentTime_(),this.playlist_.targetDuration||10);n>0&&this.remove(0,n)}createSimplifiedSegmentObj_(e){const n=e.segment,o=e.part,u=e.segment.key||e.segment.map&&e.segment.map.key,l=e.segment.map&&!e.segment.map.bytes,m={resolvedUri:o?o.resolvedUri:n.resolvedUri,byterange:o?o.byterange:n.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:u,isMediaInitialization:l},y=e.playlist.segments[e.mediaIndex-1];if(y&&y.timeline===n.timeline&&(y.videoTimingInfo?m.baseStartTime=y.videoTimingInfo.transmuxedDecodeEnd:y.audioTimingInfo&&(m.baseStartTime=y.audioTimingInfo.transmuxedDecodeEnd)),n.key){const E=n.key.iv||new Uint32Array([0,0,0,e.mediaIndex+e.playlist.mediaSequence]);m.key=this.segmentKey(n.key),m.key.iv=E}return n.map&&(m.map=this.initSegmentForMap(n.map)),m}saveTransferStats_(e){this.mediaRequests+=1,e&&(this.mediaBytesTransferred+=e.bytesReceived,this.mediaTransferDuration+=e.roundTripTime)}saveBandwidthRelatedStats_(e,n){if(this.pendingSegment_.byteLength=n.bytesReceived,e<MIN_SEGMENT_DURATION_TO_SAVE_STATS){this.logger_(`Ignoring segment's bandwidth because its duration of ${e} is less than the min to record ${MIN_SEGMENT_DURATION_TO_SAVE_STATS}`);return}const o={bandwidthInfo:{from:this.bandwidth,to:n.bandwidth}};this.trigger({type:"bandwidthupdated",metadata:o}),this.bandwidth=n.bandwidth,this.roundTrip=n.roundTripTime}handleTimeout_(){this.mediaRequestsTimedout+=1,this.bandwidth=1,this.roundTrip=NaN,this.trigger("bandwidthupdate"),this.trigger("timeout")}segmentRequestFinished_(e,n,o){if(this.callQueue_.length){this.callQueue_.push(this.segmentRequestFinished_.bind(this,e,n,o));return}if(this.saveTransferStats_(n.stats),!this.pendingSegment_||n.requestId!==this.pendingSegment_.requestId)return;if(e){if(this.pendingSegment_=null,this.state="READY",e.code===REQUEST_ERRORS.ABORTED)return;if(this.pause(),e.code===REQUEST_ERRORS.TIMEOUT){this.handleTimeout_();return}this.mediaRequestsErrored+=1,this.error(e),this.trigger("error");return}const u=this.pendingSegment_;this.saveBandwidthRelatedStats_(u.duration,n.stats),u.endOfAllRequests=n.endOfAllRequests,o.gopInfo&&(this.gopBuffer_=updateGopBuffer(this.gopBuffer_,o.gopInfo,this.safeAppend_)),this.state="APPENDING",this.trigger("appending"),this.waitForAppendsToComplete_(u)}setTimeMapping_(e){const n=this.syncController_.mappingForTimeline(e);n!==null&&(this.timeMapping_=n)}updateMediaSecondsLoaded_(e){typeof e.start=="number"&&typeof e.end=="number"?this.mediaSecondsLoaded+=e.end-e.start:this.mediaSecondsLoaded+=e.duration}shouldUpdateTransmuxerTimestampOffset_(e){return e===null?!1:this.loaderType_==="main"&&e!==this.sourceUpdater_.videoTimestampOffset()||!this.audioDisabled_&&e!==this.sourceUpdater_.audioTimestampOffset()}trueSegmentStart_({currentStart:e,playlist:n,mediaIndex:o,firstVideoFrameTimeForData:u,currentVideoTimestampOffset:l,useVideoTimingInfo:m,videoTimingInfo:y,audioTimingInfo:E}){if(typeof e<"u")return e;if(!m)return E.start;const C=n.segments[o-1];return o===0||!C||typeof C.start>"u"||C.end!==u+l?u:y.start}waitForAppendsToComplete_(e){const n=this.getCurrentMediaInfo_(e);if(!n){this.error({message:"No starting media returned, likely due to an unsupported media format.",playlistExclusionDuration:1/0}),this.trigger("error");return}const{hasAudio:o,hasVideo:u,isMuxed:l}=n,m=this.loaderType_==="main"&&u,y=!this.audioDisabled_&&o&&!l;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}m&&e.waitingOnAppends++,y&&e.waitingOnAppends++,m&&this.sourceUpdater_.videoQueueCallback(this.checkAppendsDone_.bind(this,e)),y&&this.sourceUpdater_.audioQueueCallback(this.checkAppendsDone_.bind(this,e))}checkAppendsDone_(e){this.checkForAbort_(e.requestId)||(e.waitingOnAppends--,e.waitingOnAppends===0&&this.handleAppendsDone_())}checkForIllegalMediaSwitch(e){const n=illegalMediaSwitch(this.loaderType_,this.getCurrentMediaInfo_(),e);return n?(this.error({message:n,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 n=!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),n=!0),e.timestampOffset!==this.sourceUpdater_.audioTimestampOffset()&&(this.sourceUpdater_.audioTimestampOffset(e.timestampOffset),n=!0),n&&this.trigger("timestampoffset")}getSegmentStartTimeForTimestampOffsetCalculation_({videoTimingInfo:e,audioTimingInfo:n,timingInfo:o}){return this.useDtsForTimestampOffset_?e&&typeof e.transmuxedDecodeStart=="number"?e.transmuxedDecodeStart:n&&typeof n.transmuxedDecodeStart=="number"?n.transmuxedDecodeStart:o.start:o.start}updateTimingInfoEnd_(e){e.timingInfo=e.timingInfo||{};const n=this.getMediaInfo_(),u=this.loaderType_==="main"&&n&&n.hasVideo&&e.videoTimingInfo?e.videoTimingInfo:e.audioTimingInfo;u&&(e.timingInfo.end=typeof u.end=="number"?u.end:u.start+e.duration)}handleAppendsDone_(){if(this.pendingSegment_){const E={segmentInfo:segmentInfoPayload({type:this.loaderType_,segment:this.pendingSegment_})};this.trigger({type:"appendsdone",metadata:E})}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 n=getTroublesomeSegmentDurationMessage(e,this.sourceType_);if(n&&(n.severity==="warn"?videojs.log.warn(n.message):this.logger_(n.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 ${segmentInfoString(e)}`);return}this.logger_(`Appended ${segmentInfoString(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 o=e.segment,u=e.part,l=o.end&&this.currentTime_()-o.end>e.playlist.targetDuration*3,m=u&&u.end&&this.currentTime_()-u.end>e.playlist.partTargetDuration*3;if(l||m){this.logger_(`bad ${l?"segment":"part"} ${segmentInfoString(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.duration<MIN_SEGMENT_DURATION_TO_SAVE_STATS){this.logger_(`Ignoring segment's throughput because its duration of ${e.duration} is less than the min to record ${MIN_SEGMENT_DURATION_TO_SAVE_STATS}`);return}const n=this.throughput.rate,o=Date.now()-e.endOfAllRequests+1,u=Math.floor(e.byteLength/o*8*1e3);this.throughput.rate+=(u-n)/++this.throughput.count}addSegmentMetadataCue_(e){if(!this.segmentMetadataTrack_)return;const n=e.segment,o=n.start,u=n.end;if(!finite(o)||!finite(u))return;removeCuesFromTrack(o,u,this.segmentMetadataTrack_);const l=window$1$1.WebKitDataCue||window$1$1.VTTCue,m={custom:n.custom,dateTimeObject:n.dateTimeObject,dateTimeString:n.dateTimeString,programDateTime:n.programDateTime,bandwidth:e.playlist.attributes.BANDWIDTH,resolution:e.playlist.attributes.RESOLUTION,codecs:e.playlist.attributes.CODECS,byteLength:e.byteLength,uri:e.uri,timeline:e.timeline,playlist:e.playlist.id,start:o,end:u},y=JSON.stringify(m),E=new l(o,u,y);E.value=m,this.segmentMetadataTrack_.addCue(E)}}function noop$1(){}const toTitleCase=function(t){return typeof t!="string"?t:t.replace(/./,e=>e.toUpperCase())},bufferTypes=["video","audio"],updating=(t,e)=>{const n=e[`${t}Buffer`];return n&&n.updating||e.queuePending[t]},nextQueueIndexOfType=(t,e)=>{for(let n=0;n<e.length;n++){const o=e[n];if(o.type==="mediaSource")return null;if(o.type===t)return n}return null},shiftQueue=(t,e)=>{if(e.queue.length===0)return;let n=0,o=e.queue[n];if(o.type==="mediaSource"){!e.updating()&&e.mediaSource.readyState!=="closed"&&(e.queue.shift(),o.action(e),o.doneFn&&o.doneFn(),shiftQueue("audio",e),shiftQueue("video",e));return}if(t!=="mediaSource"&&!(!e.ready()||e.mediaSource.readyState==="closed"||updating(t,e))){if(o.type!==t){if(n=nextQueueIndexOfType(t,e.queue),n===null)return;o=e.queue[n]}if(e.queue.splice(n,1),e.queuePending[t]=o,o.action(t,e),!o.doneFn){e.queuePending[t]=null,shiftQueue(t,e);return}}},cleanupBuffer=(t,e)=>{const n=e[`${t}Buffer`],o=toTitleCase(t);n&&(n.removeEventListener("updateend",e[`on${o}UpdateEnd_`]),n.removeEventListener("error",e[`on${o}Error_`]),e.codecs[t]=null,e[`${t}Buffer`]=null)},inSourceBuffers=(t,e)=>t&&e&&Array.prototype.indexOf.call(t.sourceBuffers,e)!==-1,actions={appendBuffer:(t,e,n)=>(o,u)=>{const l=u[`${o}Buffer`];if(inSourceBuffers(u.mediaSource,l)){u.logger_(`Appending segment ${e.mediaIndex}'s ${t.length} bytes to ${o}Buffer`);try{l.appendBuffer(t)}catch(m){u.logger_(`Error with code ${m.code} `+(m.code===QUOTA_EXCEEDED_ERR?"(QUOTA_EXCEEDED_ERR) ":"")+`when appending segment ${e.mediaIndex} to ${o}Buffer`),u.queuePending[o]=null,n(m)}}},remove:(t,e)=>(n,o)=>{const u=o[`${n}Buffer`];if(inSourceBuffers(o.mediaSource,u)){o.logger_(`Removing ${t} to ${e} from ${n}Buffer`);try{u.remove(t,e)}catch{o.logger_(`Remove ${t} to ${e} from ${n}Buffer failed`)}}},timestampOffset:t=>(e,n)=>{const o=n[`${e}Buffer`];inSourceBuffers(n.mediaSource,o)&&(n.logger_(`Setting ${e}timestampOffset to ${t}`),o.timestampOffset=t)},callback:t=>(e,n)=>{t()},endOfStream:t=>e=>{if(e.mediaSource.readyState==="open"){e.logger_(`Calling mediaSource endOfStream(${t||""})`);try{e.mediaSource.endOfStream(t)}catch(n){videojs.log.warn("Failed to call media source endOfStream",n)}}},duration:t=>e=>{e.logger_(`Setting mediaSource duration to ${t}`);try{e.mediaSource.duration=t}catch(n){videojs.log.warn("Failed to set media source duration",n)}},abort:()=>(t,e)=>{if(e.mediaSource.readyState!=="open")return;const n=e[`${t}Buffer`];if(inSourceBuffers(e.mediaSource,n)){e.logger_(`calling abort on ${t}Buffer`);try{n.abort()}catch(o){videojs.log.warn(`Failed to abort on ${t}Buffer`,o)}}},addSourceBuffer:(t,e)=>n=>{const o=toTitleCase(t),u=getMimeForCodec(e);n.logger_(`Adding ${t}Buffer with codec ${e} to mediaSource`);const l=n.mediaSource.addSourceBuffer(u);l.addEventListener("updateend",n[`on${o}UpdateEnd_`]),l.addEventListener("error",n[`on${o}Error_`]),n.codecs[t]=e,n[`${t}Buffer`]=l},removeSourceBuffer:t=>e=>{const n=e[`${t}Buffer`];if(cleanupBuffer(t,e),!!inSourceBuffers(e.mediaSource,n)){e.logger_(`Removing ${t}Buffer with codec ${e.codecs[t]} from mediaSource`);try{e.mediaSource.removeSourceBuffer(n)}catch(o){videojs.log.warn(`Failed to removeSourceBuffer ${t}Buffer`,o)}}},changeType:t=>(e,n)=>{const o=n[`${e}Buffer`],u=getMimeForCodec(t);if(!inSourceBuffers(n.mediaSource,o))return;const l=t.substring(0,t.indexOf(".")),m=n.codecs[e];if(m.substring(0,m.indexOf("."))===l)return;const E={codecsChangeInfo:{from:m,to:t}};n.trigger({type:"codecschange",metadata:E}),n.logger_(`changing ${e}Buffer codec from ${m} to ${t}`);try{o.changeType(u),n.codecs[e]=t}catch(C){E.errorType=videojs.Error.StreamingCodecsChangeError,E.error=C,C.metadata=E,n.error_=C,n.trigger("error"),videojs.log.warn(`Failed to changeType on ${e}Buffer`,C)}}},pushQueue=({type:t,sourceUpdater:e,action:n,doneFn:o,name:u})=>{e.queue.push({type:t,action:n,doneFn:o,name:u}),shiftQueue(t,e)},onUpdateend=(t,e)=>n=>{const o=e[`${t}Buffered`](),u=bufferedRangesToString(o);if(e.logger_(`received "updateend" event for ${t} Source Buffer: `,u),e.queuePending[t]){const l=e.queuePending[t].doneFn;e.queuePending[t]=null,l&&l(e[`${t}Error_`])}shiftQueue(t,e)};class SourceUpdater extends videojs.EventTarget{constructor(e){super(),this.mediaSource=e,this.sourceopenListener_=()=>shiftQueue("mediaSource",this),this.mediaSource.addEventListener("sourceopen",this.sourceopenListener_),this.logger_=logger("SourceUpdater"),this.audioTimestampOffset_=0,this.videoTimestampOffset_=0,this.queue=[],this.queuePending={audio:null,video:null},this.delayedAudioAppendQueue_=[],this.videoAppendQueued_=!1,this.codecs={},this.onVideoUpdateEnd_=onUpdateend("video",this),this.onAudioUpdateEnd_=onUpdateend("audio",this),this.onVideoError_=n=>{this.videoError_=n},this.onAudioError_=n=>{this.audioError_=n},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,n){pushQueue({type:"mediaSource",sourceUpdater:this,action:actions.addSourceBuffer(e,n),name:"addSourceBuffer"})}abort(e){pushQueue({type:e,sourceUpdater:this,action:actions.abort(e),name:"abort"})}removeSourceBuffer(e){if(!this.canRemoveSourceBuffer()){videojs.log.error("removeSourceBuffer is not supported!");return}pushQueue({type:"mediaSource",sourceUpdater:this,action:actions.removeSourceBuffer(e),name:"removeSourceBuffer"})}canRemoveSourceBuffer(){return!videojs.browser.IS_FIREFOX&&window$1$1.MediaSource&&window$1$1.MediaSource.prototype&&typeof window$1$1.MediaSource.prototype.removeSourceBuffer=="function"}static canChangeType(){return window$1$1.SourceBuffer&&window$1$1.SourceBuffer.prototype&&typeof window$1$1.SourceBuffer.prototype.changeType=="function"}canChangeType(){return this.constructor.canChangeType()}changeType(e,n){if(!this.canChangeType()){videojs.log.error("changeType is not supported!");return}pushQueue({type:e,sourceUpdater:this,action:actions.changeType(n),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(n=>{const o=e[n];if(!this.hasCreatedSourceBuffers())return this.addSourceBuffer(n,o);this.canChangeType()&&this.changeType(n,o)})}appendBuffer(e,n){const{segmentInfo:o,type:u,bytes:l}=e;if(this.processedAppend_=!0,u==="audio"&&this.videoBuffer&&!this.videoAppendQueued_){this.delayedAudioAppendQueue_.push([e,n]),this.logger_(`delayed audio append of ${l.length} until video append`);return}const m=n;if(pushQueue({type:u,sourceUpdater:this,action:actions.appendBuffer(l,o||{mediaIndex:-1},m),doneFn:n,name:"appendBuffer"}),u==="video"){if(this.videoAppendQueued_=!0,!this.delayedAudioAppendQueue_.length)return;const y=this.delayedAudioAppendQueue_.slice();this.logger_(`queuing delayed audio ${y.length} appendBuffers`),this.delayedAudioAppendQueue_.length=0,y.forEach(E=>{this.appendBuffer.apply(this,E)})}}audioBuffered(){return inSourceBuffers(this.mediaSource,this.audioBuffer)&&this.audioBuffer.buffered?this.audioBuffer.buffered:createTimeRanges()}videoBuffered(){return inSourceBuffers(this.mediaSource,this.videoBuffer)&&this.videoBuffer.buffered?this.videoBuffer.buffered:createTimeRanges()}buffered(){const e=inSourceBuffers(this.mediaSource,this.videoBuffer)?this.videoBuffer:null,n=inSourceBuffers(this.mediaSource,this.audioBuffer)?this.audioBuffer:null;return n&&!e?this.audioBuffered():e&&!n?this.videoBuffered():bufferIntersection(this.audioBuffered(),this.videoBuffered())}setDuration(e,n=noop$1){pushQueue({type:"mediaSource",sourceUpdater:this,action:actions.duration(e),name:"duration",doneFn:n})}endOfStream(e=null,n=noop$1){typeof e!="string"&&(e=void 0),pushQueue({type:"mediaSource",sourceUpdater:this,action:actions.endOfStream(e),name:"endOfStream",doneFn:n})}removeAudio(e,n,o=noop$1){if(!this.audioBuffered().length||this.audioBuffered().end(0)===0){o();return}pushQueue({type:"audio",sourceUpdater:this,action:actions.remove(e,n),doneFn:o,name:"remove"})}removeVideo(e,n,o=noop$1){if(!this.videoBuffered().length||this.videoBuffered().end(0)===0){o();return}pushQueue({type:"video",sourceUpdater:this,action:actions.remove(e,n),doneFn:o,name:"remove"})}updating(){return!!(updating("audio",this)||updating("video",this))}audioTimestampOffset(e){return typeof e<"u"&&this.audioBuffer&&this.audioTimestampOffset_!==e&&(pushQueue({type:"audio",sourceUpdater:this,action:actions.timestampOffset(e),name:"timestampOffset"}),this.audioTimestampOffset_=e),this.audioTimestampOffset_}videoTimestampOffset(e){return typeof e<"u"&&this.videoBuffer&&this.videoTimestampOffset_!==e&&(pushQueue({type:"video",sourceUpdater:this,action:actions.timestampOffset(e),name:"timestampOffset"}),this.videoTimestampOffset_=e),this.videoTimestampOffset_}audioQueueCallback(e){this.audioBuffer&&pushQueue({type:"audio",sourceUpdater:this,action:actions.callback(e),name:"callback"})}videoQueueCallback(e){this.videoBuffer&&pushQueue({type:"video",sourceUpdater:this,action:actions.callback(e),name:"callback"})}dispose(){this.trigger("dispose"),bufferTypes.forEach(e=>{this.abort(e),this.canRemoveSourceBuffer()?this.removeSourceBuffer(e):this[`${e}QueueCallback`](()=>cleanupBuffer(e,this))}),this.videoAppendQueued_=!1,this.delayedAudioAppendQueue_.length=0,this.sourceopenListener_&&this.mediaSource.removeEventListener("sourceopen",this.sourceopenListener_),this.off()}}const uint8ToUtf8=t=>decodeURIComponent(escape(String.fromCharCode.apply(null,t))),bufferToHexString=t=>{const e=new Uint8Array(t);return Array.from(e).map(n=>n.toString(16).padStart(2,"0")).join("")},VTT_LINE_TERMINATORS=new Uint8Array(`

`.split("").map(t=>t.charCodeAt(0)));class NoVttJsError extends Error{constructor(){super("Trying to parse received VTT cues, but there is no WebVTT. Make sure vtt.js is loaded.")}}class VTTSegmentLoader extends SegmentLoader{constructor(e,n={}){super(e,n),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 createTimeRanges();const e=this.subtitlesTrack_.cues,n=e[0].startTime,o=e[e.length-1].startTime;return createTimeRanges([[n,o]])}initSegmentForMap(e,n=!1){if(!e)return null;const o=initSegmentId(e);let u=this.initSegments_[o];if(n&&!u&&e.bytes){const l=VTT_LINE_TERMINATORS.byteLength+e.bytes.byteLength,m=new Uint8Array(l);m.set(e.bytes),m.set(VTT_LINE_TERMINATORS,e.bytes.byteLength),this.initSegments_[o]=u={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:m}}return u||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,n){removeCuesFromTrack(e,n,this.subtitlesTrack_)}fillBuffer_(){const e=this.chooseNextRequest_();if(e){if(this.syncController_.timestampOffsetForTimeline(e.timeline)===null){const n=()=>{this.state="READY",this.paused()||this.monitorBuffer_()};this.syncController_.one("timestampoffset",n),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,n,o){if(!this.subtitlesTrack_){this.state="READY";return}if(this.saveTransferStats_(n.stats),!this.pendingSegment_){this.state="READY",this.mediaRequestsAborted+=1;return}if(e){e.code===REQUEST_ERRORS.TIMEOUT&&this.handleTimeout_(),e.code===REQUEST_ERRORS.ABORTED?this.mediaRequestsAborted+=1:this.mediaRequestsErrored+=1,this.stopForError(e);return}const u=this.pendingSegment_;this.saveBandwidthRelatedStats_(u.duration,n.stats),n.key&&this.segmentKey(n.key,!0),this.state="APPENDING",this.trigger("appending");const l=u.segment;if(l.map&&(l.map.bytes=n.map.bytes),u.bytes=n.bytes,typeof window$1$1.WebVTT!="function"&&typeof this.loadVttJs=="function"){this.state="WAITING_ON_VTTJS",this.loadVttJs().then(()=>this.segmentRequestFinished_(e,n,o),()=>this.stopForError({message:"Error loading vtt.js"}));return}l.requested=!0;try{this.parseVTTCues_(u)}catch(m){this.stopForError({message:m.message,metadata:{errorType:videojs.Error.StreamingVttParserError,error:m}});return}if(this.updateTimeMapping_(u,this.syncController_.timelines[u.timeline],this.playlist_),u.cues.length?u.timingInfo={start:u.cues[0].startTime,end:u.cues[u.cues.length-1].endTime}:u.timingInfo={start:u.startOfSegment,end:u.startOfSegment+u.duration},u.isSyncRequest){this.trigger("syncinfoupdate"),this.pendingSegment_=null,this.state="READY";return}u.byteLength=u.bytes.byteLength,this.mediaSecondsLoaded+=l.duration,u.cues.forEach(m=>{this.subtitlesTrack_.addCue(this.featuresNativeTextTracks_?new window$1$1.VTTCue(m.startTime,m.endTime,m.text):m)}),removeDuplicateCuesFromTrack(this.subtitlesTrack_),this.handleAppendsDone_()}handleData_(){}updateTimingInfoEnd_(){}parseVTTCues_(e){let n,o=!1;if(typeof window$1$1.WebVTT!="function")throw new NoVttJsError;typeof window$1$1.TextDecoder=="function"?n=new window$1$1.TextDecoder("utf8"):(n=window$1$1.WebVTT.StringDecoder(),o=!0);const u=new window$1$1.WebVTT.Parser(window$1$1,window$1$1.vttjs,n);if(e.cues=[],e.timestampmap={MPEGTS:0,LOCAL:0},u.oncue=e.cues.push.bind(e.cues),u.ontimestampmap=m=>{e.timestampmap=m},u.onparsingerror=m=>{videojs.log.warn("Error encountered when parsing cues: "+m.message)},e.segment.map){let m=e.segment.map.bytes;o&&(m=uint8ToUtf8(m)),u.parse(m)}let l=e.bytes;o&&(l=uint8ToUtf8(l)),u.parse(l),u.flush()}updateTimeMapping_(e,n,o){const u=e.segment;if(!n)return;if(!e.cues.length){u.empty=!0;return}const{MPEGTS:l,LOCAL:m}=e.timestampmap,E=l/clock.ONE_SECOND_IN_TS-m+n.mapping;if(e.cues.forEach(C=>{const k=C.endTime-C.startTime,A=this.handleRollover_(C.startTime+E,n.time);C.startTime=Math.max(A,0),C.endTime=Math.max(A+k,0)}),!o.syncInfo){const C=e.cues[0].startTime,k=e.cues[e.cues.length-1].startTime;o.syncInfo={mediaSequence:o.mediaSequence+e.mediaIndex,time:Math.min(C,k-u.duration)}}}handleRollover_(e,n){if(n===null)return e;let o=e*clock.ONE_SECOND_IN_TS;const u=n*clock.ONE_SECOND_IN_TS;let l;for(u<o?l=-8589934592:l=8589934592;Math.abs(o-u)>4294967296;)o+=l;return o/clock.ONE_SECOND_IN_TS}}const findAdCue=function(t,e){const n=t.cues;for(let o=0;o<n.length;o++){const u=n[o];if(e>=u.adStartTime&&e<=u.adEndTime)return u}return null},updateAdCues=function(t,e,n=0){if(!t.segments)return;let o=n,u;for(let l=0;l<t.segments.length;l++){const m=t.segments[l];if(u||(u=findAdCue(e,o+m.duration/2)),u){if("cueIn"in m){u.endTime=o,u.adEndTime=o,o+=m.duration,u=null;continue}if(o<u.endTime){o+=m.duration;continue}u.endTime+=m.duration}else if("cueOut"in m&&(u=new window$1$1.VTTCue(o,o+m.duration,m.cueOut),u.adStartTime=o,u.adEndTime=o+parseFloat(m.cueOut),e.addCue(u)),"cueOutCont"in m){const[y,E]=m.cueOutCont.split("/").map(parseFloat);u=new window$1$1.VTTCue(o,o+m.duration,""),u.adStartTime=o-y,u.adEndTime=u.adStartTime+E,e.addCue(u)}o+=m.duration}};class SyncInfo{constructor({start:e,end:n,segmentIndex:o,partIndex:u=null,appended:l=!1}){this.start_=e,this.end_=n,this.segmentIndex_=o,this.partIndex_=u,this.appended_=l}isInRange(e){return e>=this.start&&e<this.end}markAppended(){this.appended_=!0}resetAppendedStatus(){this.appended_=!1}get isAppended(){return this.appended_}get start(){return this.start_}get end(){return this.end_}get segmentIndex(){return this.segmentIndex_}get partIndex(){return this.partIndex_}}class SyncInfoData{constructor(e,n=[]){this.segmentSyncInfo_=e,this.partsSyncInfo_=n}get segmentSyncInfo(){return this.segmentSyncInfo_}get partsSyncInfo(){return this.partsSyncInfo_}get hasPartsSyncInfo(){return this.partsSyncInfo_.length>0}resetAppendStatus(){this.segmentSyncInfo_.resetAppendedStatus(),this.partsSyncInfo_.forEach(e=>e.resetAppendedStatus())}}class MediaSequenceSync{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,n){const{mediaSequence:o,segments:u}=e;if(this.isReliable_=this.isReliablePlaylist_(o,u),!!this.isReliable_)return this.updateStorage_(u,o,this.calculateBaseTime_(o,n))}getSyncInfoForTime(e){for(const{segmentSyncInfo:n,partsSyncInfo:o}of this.storage_.values())if(o.length){for(const u of o)if(u.isInRange(e))return u}else if(n.isInRange(e))return n;return null}getSyncInfoForMediaSequence(e){return this.storage_.get(e)}updateStorage_(e,n,o){const u=new Map;let l=`
`,m=o,y=n;this.start_=m,e.forEach((E,C)=>{const k=this.storage_.get(y),A=m,D=A+E.duration,P=!!(k&&k.segmentSyncInfo&&k.segmentSyncInfo.isAppended),R=new SyncInfo({start:A,end:D,appended:P,segmentIndex:C});E.syncInfo=R;let B=m;const F=(E.parts||[]).map((j,N)=>{const Y=B,J=B+j.duration,ie=!!(k&&k.partsSyncInfo&&k.partsSyncInfo[N]&&k.partsSyncInfo[N].isAppended),ue=new SyncInfo({start:Y,end:J,appended:ie,segmentIndex:C,partIndex:N});return B=J,l+=`Media Sequence: ${y}.${N} | Range: ${Y} --> ${J} | Appended: ${ie}
`,j.syncInfo=ue,ue});u.set(y,new SyncInfoData(R,F)),l+=`${compactSegmentUrlDescription(E.resolvedUri)} | Media Sequence: ${y} | Range: ${A} --> ${D} | Appended: ${P}
`,y++,m=D}),this.end_=m,this.storage_=u,this.diagnostics_=l}calculateBaseTime_(e,n){return this.storage_.size?this.storage_.has(e)?this.storage_.get(e).segmentSyncInfo.start:n:0}isReliablePlaylist_(e,n){return e!=null&&Array.isArray(n)&&n.length}}class DependantMediaSequenceSync extends MediaSequenceSync{constructor(e){super(),this.parent_=e}calculateBaseTime_(e,n){if(!this.storage_.size){const o=this.parent_.getSyncInfoForMediaSequence(e);return o?o.segmentSyncInfo.start:0}return super.calculateBaseTime_(e,n)}}const MAX_MEDIA_SEQUENCE_DIFF_FOR_SYNC=86400,syncPointStrategies=[{name:"VOD",run:(t,e,n,o,u)=>n!==1/0?{time:0,segmentIndex:0,partIndex:null}:null},{name:"MediaSequence",run:(t,e,n,o,u,l)=>{const m=t.getMediaSequenceSync(l);if(!m||!m.isReliable)return null;const y=m.getSyncInfoForTime(u);return y?{time:y.start,partIndex:y.partIndex,segmentIndex:y.segmentIndex}:null}},{name:"ProgramDateTime",run:(t,e,n,o,u)=>{if(!Object.keys(t.timelineToDatetimeMappings).length)return null;let l=null,m=null;const y=getPartsAndSegments(e);u=u||0;for(let E=0;E<y.length;E++){const C=e.endList||u===0?E:y.length-(E+1),k=y[C],A=k.segment,D=t.timelineToDatetimeMappings[A.timeline];if(!D||!A.dateTimeObject)continue;let R=A.dateTimeObject.getTime()/1e3+D;if(A.parts&&typeof k.partIndex=="number")for(let F=0;F<k.partIndex;F++)R+=A.parts[F].duration;const B=Math.abs(u-R);if(m!==null&&(B===0||m<B))break;m=B,l={time:R,segmentIndex:k.segmentIndex,partIndex:k.partIndex}}return l}},{name:"Segment",run:(t,e,n,o,u)=>{let l=null,m=null;u=u||0;const y=getPartsAndSegments(e);for(let E=0;E<y.length;E++){const C=e.endList||u===0?E:y.length-(E+1),k=y[C],A=k.segment,D=k.part&&k.part.start||A&&A.start;if(A.timeline===o&&typeof D<"u"){const P=Math.abs(u-D);if(m!==null&&m<P)break;(!l||m===null||m>=P)&&(m=P,l={time:D,segmentIndex:k.segmentIndex,partIndex:k.partIndex})}}return l}},{name:"Discontinuity",run:(t,e,n,o,u)=>{let l=null;if(u=u||0,e.discontinuityStarts&&e.discontinuityStarts.length){let m=null;for(let y=0;y<e.discontinuityStarts.length;y++){const E=e.discontinuityStarts[y],C=e.discontinuitySequence+y+1,k=t.discontinuities[C];if(k){const A=Math.abs(u-k.time);if(m!==null&&m<A)break;(!l||m===null||m>=A)&&(m=A,l={time:k.time,segmentIndex:E,partIndex:null})}}}return l}},{name:"Playlist",run:(t,e,n,o,u)=>e.syncInfo?{time:e.syncInfo.time,segmentIndex:e.syncInfo.mediaSequence-e.mediaSequence,partIndex:null}:null}];class SyncController extends videojs.EventTarget{constructor(e={}){super(),this.timelines=[],this.discontinuities=[],this.timelineToDatetimeMappings={};const n=new MediaSequenceSync,o=new DependantMediaSequenceSync(n),u=new DependantMediaSequenceSync(n);this.mediaSequenceStorage_={main:n,audio:o,vtt:u},this.logger_=logger("SyncController")}getMediaSequenceSync(e){return this.mediaSequenceStorage_[e]||null}getSyncPoint(e,n,o,u,l){if(n!==1/0)return syncPointStrategies.find(({name:E})=>E==="VOD").run(this,e,n);const m=this.runStrategies_(e,n,o,u,l);if(!m.length)return null;for(const y of m){const{syncPoint:E,strategy:C}=y,{segmentIndex:k,time:A}=E;if(k<0)continue;const D=e.segments[k],P=A,R=P+D.duration;if(this.logger_(`Strategy: ${C}. Current time: ${u}. selected segment: ${k}. Time: [${P} -> ${R}]}`),u>=P&&u<R)return this.logger_("Found sync point with exact match: ",E),E}return this.selectSyncPoint_(m,{key:"time",value:u})}getExpiredTime(e,n){if(!e||!e.segments)return null;const o=this.runStrategies_(e,n,e.discontinuitySequence,0);if(!o.length)return null;const u=this.selectSyncPoint_(o,{key:"segmentIndex",value:0});return u.segmentIndex>0&&(u.time*=-1),Math.abs(u.time+sumDurations({defaultDuration:e.targetDuration,durationList:e.segments,startIndex:u.segmentIndex,endIndex:0}))}runStrategies_(e,n,o,u,l){const m=[];for(let y=0;y<syncPointStrategies.length;y++){const E=syncPointStrategies[y],C=E.run(this,e,n,o,u,l);C&&(C.strategy=E.name,m.push({strategy:E.name,syncPoint:C}))}return m}selectSyncPoint_(e,n){let o=e[0].syncPoint,u=Math.abs(e[0].syncPoint[n.key]-n.value),l=e[0].strategy;for(let m=1;m<e.length;m++){const y=Math.abs(e[m].syncPoint[n.key]-n.value);y<u&&(u=y,o=e[m].syncPoint,l=e[m].strategy)}return this.logger_(`syncPoint for [${n.key}: ${n.value}] chosen with strategy [${l}]: [time:${o.time}, segmentIndex:${o.segmentIndex}`+(typeof o.partIndex=="number"?`,partIndex:${o.partIndex}`:"")+"]"),o}saveExpiredSegmentInfo(e,n){const o=n.mediaSequence-e.mediaSequence;if(o>MAX_MEDIA_SEQUENCE_DIFF_FOR_SYNC){videojs.log.warn(`Not saving expired segment info. Media sequence gap ${o} is too large.`);return}for(let u=o-1;u>=0;u--){const l=e.segments[u];if(l&&typeof l.start<"u"){n.syncInfo={mediaSequence:e.mediaSequence+u,time:l.start},this.logger_(`playlist refresh sync: [time:${n.syncInfo.time}, mediaSequence: ${n.syncInfo.mediaSequence}]`),this.trigger("syncinfoupdate");break}}}setDateTimeMappingForStart(e){if(this.timelineToDatetimeMappings={},e.segments&&e.segments.length&&e.segments[0].dateTimeObject){const n=e.segments[0],o=n.dateTimeObject.getTime()/1e3;this.timelineToDatetimeMappings[n.timeline]=-o}}saveSegmentTimingInfo({segmentInfo:e,shouldSaveTimelineMapping:n}){const o=this.calculateSegmentTimeMapping_(e,e.timingInfo,n),u=e.segment;o&&(this.saveDiscontinuitySyncInfo_(e),e.playlist.syncInfo||(e.playlist.syncInfo={mediaSequence:e.playlist.mediaSequence+e.mediaIndex,time:u.start}));const l=u.dateTimeObject;u.discontinuity&&n&&l&&(this.timelineToDatetimeMappings[u.timeline]=-(l.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,n,o){const u=e.segment,l=e.part;let m=this.timelines[e.timeline],y,E;if(typeof e.timestampOffset=="number")m={time:e.startOfSegment,mapping:e.startOfSegment-n.start},o&&(this.timelines[e.timeline]=m,this.trigger("timestampoffset"),this.logger_(`time mapping for timeline ${e.timeline}: [time: ${m.time}] [mapping: ${m.mapping}]`)),y=e.startOfSegment,E=n.end+m.mapping;else if(m)y=n.start+m.mapping,E=n.end+m.mapping;else return!1;return l&&(l.start=y,l.end=E),(!u.start||y<u.start)&&(u.start=y),u.end=E,!0}saveDiscontinuitySyncInfo_(e){const n=e.playlist,o=e.segment;if(o.discontinuity)this.discontinuities[o.timeline]={time:o.start,accuracy:0};else if(n.discontinuityStarts&&n.discontinuityStarts.length)for(let u=0;u<n.discontinuityStarts.length;u++){const l=n.discontinuityStarts[u],m=n.discontinuitySequence+u+1,y=l-e.mediaIndex,E=Math.abs(y);if(!this.discontinuities[m]||this.discontinuities[m].accuracy>E){let C;y<0?C=o.start-sumDurations({defaultDuration:n.targetDuration,durationList:n.segments,startIndex:e.mediaIndex,endIndex:l}):C=o.end+sumDurations({defaultDuration:n.targetDuration,durationList:n.segments,startIndex:e.mediaIndex+1,endIndex:l}),this.discontinuities[m]={time:C,accuracy:E}}}}dispose(){this.trigger("dispose"),this.off()}}class TimelineChangeController extends videojs.EventTarget{constructor(){super(),this.pendingTimelineChanges_={},this.lastTimelineChanges_={}}clearPendingTimelineChange(e){this.pendingTimelineChanges_[e]=null,this.trigger("pendingtimelinechange")}pendingTimelineChange({type:e,from:n,to:o}){return typeof n=="number"&&typeof o=="number"&&(this.pendingTimelineChanges_[e]={type:e,from:n,to:o},this.trigger("pendingtimelinechange")),this.pendingTimelineChanges_[e]}lastTimelineChange({type:e,from:n,to:o}){if(typeof n=="number"&&typeof o=="number"){this.lastTimelineChanges_[e]={type:e,from:n,to:o},delete this.pendingTimelineChanges_[e];const u={timelineChangeInfo:{from:n,to:o}};this.trigger({type:"timelinechange",metadata:u})}return this.lastTimelineChanges_[e]}dispose(){this.trigger("dispose"),this.pendingTimelineChanges_={},this.lastTimelineChanges_={},this.off()}}const workerCode=transform(getWorkerString(function(){var t=function(){function B(){this.listeners={}}var F=B.prototype;return F.on=function(N,Y){this.listeners[N]||(this.listeners[N]=[]),this.listeners[N].push(Y)},F.off=function(N,Y){if(!this.listeners[N])return!1;var J=this.listeners[N].indexOf(Y);return this.listeners[N]=this.listeners[N].slice(0),this.listeners[N].splice(J,1),J>-1},F.trigger=function(N){var Y=this.listeners[N];if(Y)if(arguments.length===2)for(var J=Y.length,ie=0;ie<J;++ie)Y[ie].call(this,arguments[1]);else for(var ue=Array.prototype.slice.call(arguments,1),Q=Y.length,ce=0;ce<Q;++ce)Y[ce].apply(this,ue)},F.dispose=function(){this.listeners={}},F.pipe=function(N){this.on("data",function(Y){N.push(Y)})},B}();/*! @name pkcs7 @version 1.0.4 @license Apache-2.0 */function e(B){return B.subarray(0,B.byteLength-B[B.byteLength-1])}/*! @name aes-decrypter @version 4.0.2 @license Apache-2.0 */const n=function(){const B=[[[],[],[],[],[]],[[],[],[],[],[]]],F=B[0],j=B[1],N=F[4],Y=j[4];let J,ie,ue;const Q=[],ce=[];let he,ke,L,d,v,w;for(J=0;J<256;J++)ce[(Q[J]=J<<1^(J>>7)*283)^J]=J;for(ie=ue=0;!N[ie];ie^=he||1,ue=ce[ue]||1)for(d=ue^ue<<1^ue<<2^ue<<3^ue<<4,d=d>>8^d&255^99,N[ie]=d,Y[d]=ie,L=Q[ke=Q[he=Q[ie]]],w=L*16843009^ke*65537^he*257^ie*16843008,v=Q[d]*257^d*16843008,J=0;J<4;J++)F[J][ie]=v=v<<24^v>>>8,j[J][d]=w=w<<24^w>>>8;for(J=0;J<5;J++)F[J]=F[J].slice(0),j[J]=j[J].slice(0);return B};let o=null;class u{constructor(F){o||(o=n()),this._tables=[[o[0][0].slice(),o[0][1].slice(),o[0][2].slice(),o[0][3].slice(),o[0][4].slice()],[o[1][0].slice(),o[1][1].slice(),o[1][2].slice(),o[1][3].slice(),o[1][4].slice()]];let j,N,Y;const J=this._tables[0][4],ie=this._tables[1],ue=F.length;let Q=1;if(ue!==4&&ue!==6&&ue!==8)throw new Error("Invalid aes key size");const ce=F.slice(0),he=[];for(this._key=[ce,he],j=ue;j<4*ue+28;j++)Y=ce[j-1],(j%ue===0||ue===8&&j%ue===4)&&(Y=J[Y>>>24]<<24^J[Y>>16&255]<<16^J[Y>>8&255]<<8^J[Y&255],j%ue===0&&(Y=Y<<8^Y>>>24^Q<<24,Q=Q<<1^(Q>>7)*283)),ce[j]=ce[j-ue]^Y;for(N=0;j;N++,j--)Y=ce[N&3?j:j-4],j<=4||N<4?he[N]=Y:he[N]=ie[0][J[Y>>>24]]^ie[1][J[Y>>16&255]]^ie[2][J[Y>>8&255]]^ie[3][J[Y&255]]}decrypt(F,j,N,Y,J,ie){const ue=this._key[1];let Q=F^ue[0],ce=Y^ue[1],he=N^ue[2],ke=j^ue[3],L,d,v;const w=ue.length/4-2;let c,p=4;const x=this._tables[1],S=x[0],b=x[1],h=x[2],T=x[3],M=x[4];for(c=0;c<w;c++)L=S[Q>>>24]^b[ce>>16&255]^h[he>>8&255]^T[ke&255]^ue[p],d=S[ce>>>24]^b[he>>16&255]^h[ke>>8&255]^T[Q&255]^ue[p+1],v=S[he>>>24]^b[ke>>16&255]^h[Q>>8&255]^T[ce&255]^ue[p+2],ke=S[ke>>>24]^b[Q>>16&255]^h[ce>>8&255]^T[he&255]^ue[p+3],p+=4,Q=L,ce=d,he=v;for(c=0;c<4;c++)J[(3&-c)+ie]=M[Q>>>24]<<24^M[ce>>16&255]<<16^M[he>>8&255]<<8^M[ke&255]^ue[p++],L=Q,Q=ce,ce=he,he=ke,ke=L}}class l extends t{constructor(){super(t),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(F){this.jobs.push(F),this.timeout_||(this.timeout_=setTimeout(this.processJob_.bind(this),this.delay))}}const m=function(B){return B<<24|(B&65280)<<8|(B&16711680)>>8|B>>>24},y=function(B,F,j){const N=new Int32Array(B.buffer,B.byteOffset,B.byteLength>>2),Y=new u(Array.prototype.slice.call(F)),J=new Uint8Array(B.byteLength),ie=new Int32Array(J.buffer);let ue,Q,ce,he,ke,L,d,v,w;for(ue=j[0],Q=j[1],ce=j[2],he=j[3],w=0;w<N.length;w+=4)ke=m(N[w]),L=m(N[w+1]),d=m(N[w+2]),v=m(N[w+3]),Y.decrypt(ke,L,d,v,ie,w),ie[w]=m(ie[w]^ue),ie[w+1]=m(ie[w+1]^Q),ie[w+2]=m(ie[w+2]^ce),ie[w+3]=m(ie[w+3]^he),ue=ke,Q=L,ce=d,he=v;return J};class E{constructor(F,j,N,Y){const J=E.STEP,ie=new Int32Array(F.buffer),ue=new Uint8Array(F.byteLength);let Q=0;for(this.asyncStream_=new l,this.asyncStream_.push(this.decryptChunk_(ie.subarray(Q,Q+J),j,N,ue)),Q=J;Q<ie.length;Q+=J)N=new Uint32Array([m(ie[Q-4]),m(ie[Q-3]),m(ie[Q-2]),m(ie[Q-1])]),this.asyncStream_.push(this.decryptChunk_(ie.subarray(Q,Q+J),j,N,ue));this.asyncStream_.push(function(){Y(null,e(ue))})}static get STEP(){return 32e3}decryptChunk_(F,j,N,Y){return function(){const J=y(F,j,N);Y.set(J,F.byteOffset)}}}var C=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global$1<"u"?global$1:typeof self<"u"?self:{},k;typeof window<"u"?k=window:typeof C<"u"?k=C:typeof self<"u"?k=self:k={};var A=k,D=function(F){return ArrayBuffer.isView==="function"?ArrayBuffer.isView(F):F&&F.buffer instanceof ArrayBuffer},P=A.BigInt||Number;P("0x1"),P("0x100"),P("0x10000"),P("0x1000000"),P("0x100000000"),P("0x10000000000"),P("0x1000000000000"),P("0x100000000000000"),P("0x10000000000000000"),function(){var B=new Uint16Array([65484]),F=new Uint8Array(B.buffer,B.byteOffset,B.byteLength);return F[0]===255?"big":F[0]===204?"little":"unknown"}();const R=function(B){const F={};return Object.keys(B).forEach(j=>{const N=B[j];D(N)?F[j]={bytes:N.buffer,byteOffset:N.byteOffset,byteLength:N.byteLength}:F[j]=N}),F};self.onmessage=function(B){const F=B.data,j=new Uint8Array(F.encrypted.bytes,F.encrypted.byteOffset,F.encrypted.byteLength),N=new Uint32Array(F.key.bytes,F.key.byteOffset,F.key.byteLength/4),Y=new Uint32Array(F.iv.bytes,F.iv.byteOffset,F.iv.byteLength/4);new E(j,N,Y,function(J,ie){self.postMessage(R({source:F.source,decrypted:ie}),[ie.buffer])})}}));var Decrypter=factory(workerCode);const audioTrackKind_=t=>{let e=t.default?"main":"alternative";return t.characteristics&&t.characteristics.indexOf("public.accessibility.describes-video")>=0&&(e="main-desc"),e},stopLoaders=(t,e)=>{t.abort(),t.pause(),e&&e.activePlaylistLoader&&(e.activePlaylistLoader.pause(),e.activePlaylistLoader=null)},startLoaders=(t,e)=>{e.activePlaylistLoader=t,t.load()},onGroupChanged=(t,e)=>()=>{const{segmentLoaders:{[t]:n,main:o},mediaTypes:{[t]:u}}=e,l=u.activeTrack(),m=u.getActiveGroup(),y=u.activePlaylistLoader,E=u.lastGroup_;if(!(m&&E&&m.id===E.id)&&(u.lastGroup_=m,u.lastTrack_=l,stopLoaders(n,u),!(!m||m.isMainPlaylist))){if(!m.playlistLoader){y&&o.resetEverything();return}n.resyncLoader(),startLoaders(m.playlistLoader,u)}},onGroupChanging=(t,e)=>()=>{const{segmentLoaders:{[t]:n},mediaTypes:{[t]:o}}=e;o.lastGroup_=null,n.abort(),n.pause()},onTrackChanged=(t,e)=>()=>{const{mainPlaylistLoader:n,segmentLoaders:{[t]:o,main:u},mediaTypes:{[t]:l}}=e,m=l.activeTrack(),y=l.getActiveGroup(),E=l.activePlaylistLoader,C=l.lastTrack_;if(!(C&&m&&C.id===m.id)&&(l.lastGroup_=y,l.lastTrack_=m,stopLoaders(o,l),!!y)){if(y.isMainPlaylist){if(!m||!C||m.id===C.id)return;const k=e.vhs.playlistController_,A=k.selectPlaylist();if(k.media()===A)return;l.logger_(`track change. Switching main audio from ${C.id} to ${m.id}`),n.pause(),u.resetEverything(),k.fastQualityChange_(A);return}if(t==="AUDIO"){if(!y.playlistLoader){u.setAudio(!0),u.resetEverything();return}o.setAudio(!0),u.setAudio(!1)}if(E===y.playlistLoader){startLoaders(y.playlistLoader,l);return}o.track&&o.track(m),o.resetEverything(),startLoaders(y.playlistLoader,l)}},onError={AUDIO:(t,e)=>()=>{const{mediaTypes:{[t]:n},excludePlaylist:o}=e,u=n.activeTrack(),l=n.activeGroup(),m=(l.filter(E=>E.default)[0]||l[0]).id,y=n.tracks[m];if(u===y){o({error:{message:"Problem encountered loading the default audio track."}});return}videojs.log.warn("Problem encountered loading the alternate audio track.Switching back to default.");for(const E in n.tracks)n.tracks[E].enabled=n.tracks[E]===y;n.onTrackChanged()},SUBTITLES:(t,e)=>()=>{const{mediaTypes:{[t]:n}}=e;videojs.log.warn("Problem encountered loading the subtitle track.Disabling subtitle track.");const o=n.activeTrack();o&&(o.mode="disabled"),n.onTrackChanged()}},setupListeners={AUDIO:(t,e,n)=>{if(!e)return;const{tech:o,requestOptions:u,segmentLoaders:{[t]:l}}=n;e.on("loadedmetadata",()=>{const m=e.media();l.playlist(m,u),(!o.paused()||m.endList&&o.preload()!=="none")&&l.load()}),e.on("loadedplaylist",()=>{l.playlist(e.media(),u),o.paused()||l.load()}),e.on("error",onError[t](t,n))},SUBTITLES:(t,e,n)=>{const{tech:o,requestOptions:u,segmentLoaders:{[t]:l},mediaTypes:{[t]:m}}=n;e.on("loadedmetadata",()=>{const y=e.media();l.playlist(y,u),l.track(m.activeTrack()),(!o.paused()||y.endList&&o.preload()!=="none")&&l.load()}),e.on("loadedplaylist",()=>{l.playlist(e.media(),u),o.paused()||l.load()}),e.on("error",onError[t](t,n))}},initialize={AUDIO:(t,e)=>{const{vhs:n,sourceType:o,segmentLoaders:{[t]:u},requestOptions:l,main:{mediaGroups:m},mediaTypes:{[t]:{groups:y,tracks:E,logger_:C}},mainPlaylistLoader:k}=e,A=isAudioOnly(k.main);(!m[t]||Object.keys(m[t]).length===0)&&(m[t]={main:{default:{default:!0}}},A&&(m[t].main.default.playlists=k.main.playlists));for(const D in m[t]){y[D]||(y[D]=[]);for(const P in m[t][D]){let R=m[t][D][P],B;if(A?(C(`AUDIO group '${D}' label '${P}' is a main playlist`),R.isMainPlaylist=!0,B=null):o==="vhs-json"&&R.playlists?B=new PlaylistLoader(R.playlists[0],n,l):R.resolvedUri?B=new PlaylistLoader(R.resolvedUri,n,l):R.playlists&&o==="dash"?B=new DashPlaylistLoader(R.playlists[0],n,l,k):B=null,R=merge({id:P,playlistLoader:B},R),setupListeners[t](t,R.playlistLoader,e),y[D].push(R),typeof E[P]>"u"){const F=new videojs.AudioTrack({id:P,kind:audioTrackKind_(R),enabled:!1,language:R.language,default:R.default,label:P});E[P]=F}}}u.on("error",onError[t](t,e))},SUBTITLES:(t,e)=>{const{tech:n,vhs:o,sourceType:u,segmentLoaders:{[t]:l},requestOptions:m,main:{mediaGroups:y},mediaTypes:{[t]:{groups:E,tracks:C}},mainPlaylistLoader:k}=e;for(const A in y[t]){E[A]||(E[A]=[]);for(const D in y[t][A]){if(!o.options_.useForcedSubtitles&&y[t][A][D].forced)continue;let P=y[t][A][D],R;if(u==="hls")R=new PlaylistLoader(P.resolvedUri,o,m);else if(u==="dash"){if(!P.playlists.filter(F=>F.excludeUntil!==1/0).length)return;R=new DashPlaylistLoader(P.playlists[0],o,m,k)}else u==="vhs-json"&&(R=new PlaylistLoader(P.playlists?P.playlists[0]:P.resolvedUri,o,m));if(P=merge({id:D,playlistLoader:R},P),setupListeners[t](t,P.playlistLoader,e),E[A].push(P),typeof C[D]>"u"){const B=n.addRemoteTextTrack({id:D,kind:"subtitles",default:P.default&&P.autoselect,language:P.language,label:D},!1).track;C[D]=B}}}l.on("error",onError[t](t,e))},"CLOSED-CAPTIONS":(t,e)=>{const{tech:n,main:{mediaGroups:o},mediaTypes:{[t]:{groups:u,tracks:l}}}=e;for(const m in o[t]){u[m]||(u[m]=[]);for(const y in o[t][m]){const E=o[t][m][y];if(!/^(?:CC|SERVICE)/.test(E.instreamId))continue;const C=n.options_.vhs&&n.options_.vhs.captionServices||{};let k={label:y,language:E.language,instreamId:E.instreamId,default:E.default&&E.autoselect};if(C[k.instreamId]&&(k=merge(k,C[k.instreamId])),k.default===void 0&&delete k.default,u[m].push(merge({id:y},E)),typeof l[y]>"u"){const A=n.addRemoteTextTrack({id:k.instreamId,kind:"captions",default:k.default,language:k.language,label:k.label},!1).track;l[y]=A}}}}},groupMatch=(t,e)=>{for(let n=0;n<t.length;n++)if(playlistMatch(e,t[n])||t[n].playlists&&groupMatch(t[n].playlists,e))return!0;return!1},activeGroup=(t,e)=>n=>{const{mainPlaylistLoader:o,mediaTypes:{[t]:{groups:u}}}=e,l=o.media();if(!l)return null;let m=null;l.attributes[t]&&(m=u[l.attributes[t]]);const y=Object.keys(u);if(!m)if(t==="AUDIO"&&y.length>1&&isAudioOnly(e.main))for(let E=0;E<y.length;E++){const C=u[y[E]];if(groupMatch(C,l)){m=C;break}}else u.main?m=u.main:y.length===1&&(m=u[y[0]]);return typeof n>"u"?m:n===null||!m?null:m.filter(E=>E.id===n.id)[0]||null},activeTrack={AUDIO:(t,e)=>()=>{const{mediaTypes:{[t]:{tracks:n}}}=e;for(const o in n)if(n[o].enabled)return n[o];return null},SUBTITLES:(t,e)=>()=>{const{mediaTypes:{[t]:{tracks:n}}}=e;for(const o in n)if(n[o].mode==="showing"||n[o].mode==="hidden")return n[o];return null}},getActiveGroup=(t,{mediaTypes:e})=>()=>{const n=e[t].activeTrack();return n?e[t].activeGroup(n):null},setupMediaGroups=t=>{["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(C=>{initialize[C](C,t)});const{mediaTypes:e,mainPlaylistLoader:n,tech:o,vhs:u,segmentLoaders:{["AUDIO"]:l,main:m}}=t;["AUDIO","SUBTITLES"].forEach(C=>{e[C].activeGroup=activeGroup(C,t),e[C].activeTrack=activeTrack[C](C,t),e[C].onGroupChanged=onGroupChanged(C,t),e[C].onGroupChanging=onGroupChanging(C,t),e[C].onTrackChanged=onTrackChanged(C,t),e[C].getActiveGroup=getActiveGroup(C,t)});const y=e.AUDIO.activeGroup();if(y){const C=(y.filter(A=>A.default)[0]||y[0]).id;e.AUDIO.tracks[C].enabled=!0,e.AUDIO.onGroupChanged(),e.AUDIO.onTrackChanged(),e.AUDIO.getActiveGroup().playlistLoader?(m.setAudio(!1),l.setAudio(!0)):m.setAudio(!0)}n.on("mediachange",()=>{["AUDIO","SUBTITLES"].forEach(C=>e[C].onGroupChanged())}),n.on("mediachanging",()=>{["AUDIO","SUBTITLES"].forEach(C=>e[C].onGroupChanging())});const E=()=>{e.AUDIO.onTrackChanged(),o.trigger({type:"usage",name:"vhs-audio-change"})};o.audioTracks().addEventListener("change",E),o.remoteTextTracks().addEventListener("change",e.SUBTITLES.onTrackChanged),u.on("dispose",()=>{o.audioTracks().removeEventListener("change",E),o.remoteTextTracks().removeEventListener("change",e.SUBTITLES.onTrackChanged)}),o.clearTracks("audio");for(const C in e.AUDIO.tracks)o.audioTracks().addTrack(e.AUDIO.tracks[C])},createMediaTypes=()=>{const t={};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(e=>{t[e]={groups:{},tracks:{},activePlaylistLoader:null,activeGroup:noop$1,activeTrack:noop$1,getActiveGroup:noop$1,onGroupChanged:noop$1,onTrackChanged:noop$1,lastTrack_:null,logger_:logger(`MediaGroups[${e}]`)}}),t};class SteeringManifest{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_=resolveUrl(this.reloadUri_,e))}set priority(e){e&&e.length&&(this.priority_=e)}set pathwayClones(e){e&&e.length&&(this.pathwayClones_=new Map(e.map(n=>[n.ID,n])))}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 ContentSteeringController extends videojs.EventTarget{constructor(e,n){super(),this.currentPathway=null,this.defaultPathway=null,this.queryBeforeStart=!1,this.availablePathways_=new Set,this.steeringManifest=new SteeringManifest,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_=logger("Content Steering"),this.xhr_=e,this.getBandwidth_=n}assignTagProperties(e,n){this.manifestType_=n.serverUri?"HLS":"DASH";const o=n.serverUri||n.serverURL;if(!o){this.logger_(`steering manifest URL is ${o}, cannot request steering manifest.`),this.trigger("error");return}if(o.startsWith("data:")){this.decodeDataUriManifest_(o.substring(o.indexOf(",")+1));return}this.steeringManifest.reloadUri=resolveUrl(e,o),this.defaultPathway=n.pathwayId||n.defaultServiceLocation,this.queryBeforeStart=n.queryBeforeStart,this.proxyServerUrl_=n.proxyServerURL,this.defaultPathway&&!this.queryBeforeStart&&this.trigger("content-steering")}requestSteeringManifest(e){const n=this.steeringManifest.reloadUri;if(!n)return;const o=e?n:this.getRequestURI(n);if(!o){this.logger_("No valid content steering manifest URIs. Stopping content steering."),this.trigger("error"),this.dispose();return}const u={contentSteeringInfo:{uri:o}};this.trigger({type:"contentsteeringloadstart",metadata:u}),this.request_=this.xhr_({uri:o,requestType:"content-steering-manifest"},(l,m)=>{if(l){if(m.status===410){this.logger_(`manifest request 410 ${l}.`),this.logger_(`There will be no more content steering requests to ${o} this session.`),this.excludedSteeringManifestURLs.add(o);return}if(m.status===429){const C=m.responseHeaders["retry-after"];this.logger_(`manifest request 429 ${l}.`),this.logger_(`content steering will retry in ${C} seconds.`),this.startTTLTimeout_(parseInt(C,10));return}this.logger_(`manifest failed to load ${l}.`),this.startTTLTimeout_();return}this.trigger({type:"contentsteeringloadcomplete",metadata:u});let y;try{y=JSON.parse(this.request_.responseText)}catch(C){const k={errorType:videojs.Error.StreamingContentSteeringParserError,error:C};this.trigger({type:"error",metadata:k})}this.assignSteeringProperties_(y);const E={contentSteeringInfo:u.contentSteeringInfo,contentSteeringManifest:{version:this.steeringManifest.version,reloadUri:this.steeringManifest.reloadUri,priority:this.steeringManifest.priority}};this.trigger({type:"contentsteeringparsed",metadata:E}),this.startTTLTimeout_()})}setProxyServerUrl_(e){const n=new window$1$1.URL(e),o=new window$1$1.URL(this.proxyServerUrl_);return o.searchParams.set("url",encodeURI(n.toString())),this.setSteeringParams_(o.toString())}decodeDataUriManifest_(e){const n=JSON.parse(window$1$1.atob(e));this.assignSteeringProperties_(n)}setSteeringParams_(e){const n=new window$1$1.URL(e),o=this.getPathway(),u=this.getBandwidth_();if(o){const l=`_${this.manifestType_}_pathway`;n.searchParams.set(l,o)}if(u){const l=`_${this.manifestType_}_throughput`;n.searchParams.set(l,u)}return n.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 o=(u=>{for(const l of u)if(this.availablePathways_.has(l))return l;return[...this.availablePathways_][0]})(this.steeringManifest.priority);this.currentPathway!==o&&(this.currentPathway=o,this.trigger("content-steering"))}getPathway(){return this.currentPathway||this.defaultPathway}getRequestURI(e){if(!e)return null;const n=u=>this.excludedSteeringManifestURLs.has(u);if(this.proxyServerUrl_){const u=this.setProxyServerUrl_(e);if(!n(u))return u}const o=this.setSteeringParams_(e);return n(o)?null:o}startTTLTimeout_(e=this.steeringManifest.ttl){const n=e*1e3;this.ttlTimeout_=window$1$1.setTimeout(()=>{this.requestSteeringManifest()},n)}clearTTLTimeout_(){window$1$1.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 SteeringManifest}addAvailablePathway(e){e&&this.availablePathways_.add(e)}clearAvailablePathways(){this.availablePathways_.clear()}excludePathway(e){return this.availablePathways_.delete(e)}didDASHTagChange(e,n){return!n&&this.steeringManifest.reloadUri||n&&(resolveUrl(e,n.serverURL)!==this.steeringManifest.reloadUri||n.defaultServiceLocation!==this.defaultPathway||n.queryBeforeStart!==this.queryBeforeStart||n.proxyServerURL!==this.proxyServerUrl_)}getAvailablePathways(){return this.availablePathways_}}const ABORT_EARLY_EXCLUSION_SECONDS=10;let Vhs$1;const loaderStats=["mediaRequests","mediaRequestsAborted","mediaRequestsTimedout","mediaRequestsErrored","mediaTransferDuration","mediaBytesTransferred","mediaAppends"],sumLoaderStat=function(t){return this.audioSegmentLoader_[t]+this.mainSegmentLoader_[t]},shouldSwitchToMedia=function({currentPlaylist:t,buffered:e,currentTime:n,nextPlaylist:o,bufferLowWaterLine:u,bufferHighWaterLine:l,duration:m,bufferBasedABR:y,log:E}){if(!o)return videojs.log.warn("We received no playlist to switch to. Please check your stream."),!1;const C=`allowing switch ${t&&t.id||"null"} -> ${o.id}`;if(!t)return E(`${C} as current playlist is not set`),!0;if(o.id===t.id)return!1;const k=!!findRange(e,n).length;if(!t.endList)return!k&&typeof t.partTargetDuration=="number"?(E(`not ${C} as current playlist is live llhls, but currentTime isn't in buffered.`),!1):(E(`${C} as current playlist is live`),!0);const A=timeAheadOf(e,n),D=y?Config.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:Config.MAX_BUFFER_LOW_WATER_LINE;if(m<D)return E(`${C} as duration < max low water line (${m} < ${D})`),!0;const P=o.attributes.BANDWIDTH,R=t.attributes.BANDWIDTH;if(P<R&&(!y||A<l)){let B=`${C} as next bandwidth < current bandwidth (${P} < ${R})`;return y&&(B+=` and forwardBuffer < bufferHighWaterLine (${A} < ${l})`),E(B),!0}if((!y||P>R)&&A>=u){let B=`${C} as forwardBuffer >= bufferLowWaterLine (${A} >= ${u})`;return y&&(B+=` and next bandwidth > current bandwidth (${P} > ${R})`),E(B),!0}return E(`not ${C} as no switching criteria met`),!1};class PlaylistController extends videojs.EventTarget{constructor(e){super();const{src:n,withCredentials:o,tech:u,bandwidth:l,externVhs:m,useCueTags:y,playlistExclusionDuration:E,enableLowInitialPlaylist:C,sourceType:k,cacheEncryptionKeys:A,bufferBasedABR:D,leastPixelDiffSelector:P,captionServices:R,experimentalUseMMS:B}=e;if(!n)throw new Error("A non-empty playlist URL or JSON manifest string is required");let{maxPlaylistRetries:F}=e;(F===null||typeof F>"u")&&(F=1/0),Vhs$1=m,this.bufferBasedABR=!!D,this.leastPixelDiffSelector=!!P,this.withCredentials=o,this.tech_=u,this.vhs_=u.vhs,this.player_=e.player_,this.sourceType_=k,this.useCueTags_=y,this.playlistExclusionDuration=E,this.maxPlaylistRetries=F,this.enableLowInitialPlaylist=C,this.useCueTags_&&(this.cueTagsTrack_=this.tech_.addTextTrack("metadata","ad-cues"),this.cueTagsTrack_.inBandMetadataTrackDispatchType=""),this.requestOptions_={withCredentials:o,maxPlaylistRetries:F,timeout:null},this.on("error",this.pauseLoading),this.mediaTypes_=createMediaTypes(),B&&window$1$1.ManagedMediaSource?(this.tech_.el_.disableRemotePlayback=!0,this.mediaSource=new window$1$1.ManagedMediaSource,videojs.log("Using ManagedMediaSource")):window$1$1.MediaSource&&(this.mediaSource=new window$1$1.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_=createTimeRanges(),this.hasPlayed_=!1,this.syncController_=new SyncController(e),this.segmentMetadataTrack_=u.addRemoteTextTrack({kind:"metadata",label:"segment-metadata"},!1).track,this.decrypter_=new Decrypter,this.sourceUpdater_=new SourceUpdater(this.mediaSource),this.inbandTextTracks_={},this.timelineChangeController_=new TimelineChangeController,this.keyStatusMap_=new Map;const j={vhs:this.vhs_,parse708captions:e.parse708captions,useDtsForTimestampOffset:e.useDtsForTimestampOffset,captionServices:R,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:l,syncController:this.syncController_,decrypter:this.decrypter_,sourceType:this.sourceType_,inbandTextTracks:this.inbandTextTracks_,cacheEncryptionKeys:A,sourceUpdater:this.sourceUpdater_,timelineChangeController:this.timelineChangeController_,exactManifestTimings:e.exactManifestTimings,addMetadataToTextTrack:this.addMetadataToTextTrack.bind(this)};this.mainPlaylistLoader_=this.sourceType_==="dash"?new DashPlaylistLoader(n,this.vhs_,merge(this.requestOptions_,{addMetadataToTextTrack:this.addMetadataToTextTrack.bind(this)})):new PlaylistLoader(n,this.vhs_,merge(this.requestOptions_,{addDateRangesToTextTrack:this.addDateRangesToTextTrack_.bind(this)})),this.setupMainPlaylistLoaderListeners_(),this.mainSegmentLoader_=new SegmentLoader(merge(j,{segmentMetadataTrack:this.segmentMetadataTrack_,loaderType:"main"}),e),this.audioSegmentLoader_=new SegmentLoader(merge(j,{loaderType:"audio"}),e),this.subtitleSegmentLoader_=new VTTSegmentLoader(merge(j,{loaderType:"vtt",featuresNativeTextTracks:this.tech_.featuresNativeTextTracks,loadVttJs:()=>new Promise((J,ie)=>{function ue(){u.off("vttjserror",Q),J()}function Q(){u.off("vttjsloaded",ue),ie()}u.one("vttjsloaded",ue),u.one("vttjserror",Q),u.addWebVttScript_()})}),e);const N=()=>this.mainSegmentLoader_.bandwidth;this.contentSteeringController_=new ContentSteeringController(this.vhs_.xhr,N),this.setupSegmentLoaderListeners_(),this.bufferBasedABR&&(this.mainPlaylistLoader_.one("loadedplaylist",()=>this.startABRTimer_()),this.tech_.on("pause",()=>this.stopABRTimer_()),this.tech_.on("play",()=>this.startABRTimer_())),loaderStats.forEach(J=>{this[J+"_"]=sumLoaderStat.bind(this,J)}),this.logger_=logger("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 Y=this.tech_.preload()==="none"?"play":"loadstart";this.tech_.one(Y,()=>{const J=Date.now();this.tech_.one("loadeddata",()=>{this.timeToLoadedData__=Date.now()-J,this.mainAppendsToLoadedData__=this.mainSegmentLoader_.mediaAppends,this.audioAppendsToLoadedData__=this.audioSegmentLoader_.mediaAppends})})}mainAppendsToLoadedData_(){return this.mainAppendsToLoadedData__}audioAppendsToLoadedData_(){return this.audioAppendsToLoadedData__}appendsToLoadedData_(){const e=this.mainAppendsToLoadedData_(),n=this.audioAppendsToLoadedData_();return e===-1||n===-1?-1:e+n}timeToLoadedData_(){return this.timeToLoadedData__}checkABR_(e="abr"){const n=this.selectPlaylist();n&&this.shouldSwitchToMedia_(n)&&this.switchMedia_(n,e)}switchMedia_(e,n,o){const u=this.media(),l=u&&(u.id||u.uri),m=e&&(e.id||e.uri);if(l&&l!==m){this.logger_(`switch media ${l} -> ${m} from ${n}`);const y={renditionInfo:{id:m,bandwidth:e.attributes.BANDWIDTH,resolution:e.attributes.RESOLUTION,codecs:e.attributes.CODECS},cause:n};this.trigger({type:"renditionselected",metadata:y}),this.tech_.trigger({type:"usage",name:`vhs-rendition-change-${n}`})}this.mainPlaylistLoader_.media(e,o)}switchMediaForDASHContentSteering_(){["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(e=>{const n=this.mediaTypes_[e],o=n?n.activeGroup():null,u=this.contentSteeringController_.getPathway();if(o&&u){const m=(o.length?o[0].playlists:o.playlists).filter(y=>y.attributes.serviceLocation===u);m.length&&this.mediaTypes_[e].activePlaylistLoader.media(m[0])}})}startABRTimer_(){this.stopABRTimer_(),this.abrTimer_=window$1$1.setInterval(()=>this.checkABR_(),250)}stopABRTimer_(){this.tech_.scrubbing&&this.tech_.scrubbing()||(window$1$1.clearInterval(this.abrTimer_),this.abrTimer_=null)}getAudioTrackPlaylists_(){const e=this.main(),n=e&&e.playlists||[];if(!e||!e.mediaGroups||!e.mediaGroups.AUDIO)return n;const o=e.mediaGroups.AUDIO,u=Object.keys(o);let l;if(Object.keys(this.mediaTypes_.AUDIO.groups).length)l=this.mediaTypes_.AUDIO.activeTrack();else{const y=o.main||u.length&&o[u[0]];for(const E in y)if(y[E].default){l={label:E};break}}if(!l)return n;const m=[];for(const y in o)if(o[y][l.label]){const E=o[y][l.label];if(E.playlists&&E.playlists.length)m.push.apply(m,E.playlists);else if(E.uri)m.push(E);else if(e.playlists.length)for(let C=0;C<e.playlists.length;C++){const k=e.playlists[C];k.attributes&&k.attributes.AUDIO&&k.attributes.AUDIO===y&&m.push(k)}}return m.length?m:n}setupMainPlaylistLoaderListeners_(){this.mainPlaylistLoader_.on("loadedmetadata",()=>{const n=this.mainPlaylistLoader_.media(),o=n.targetDuration*1.5*1e3;isLowestEnabledRendition(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.media())?this.requestOptions_.timeout=0:this.requestOptions_.timeout=o,n.endList&&this.tech_.preload()!=="none"&&(this.mainSegmentLoader_.playlist(n,this.requestOptions_),this.mainSegmentLoader_.load()),setupMediaGroups({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(),n),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 n=this.mainPlaylistLoader_.media();if(!n){this.attachContentSteeringListeners_(),this.initContentSteeringController_(),this.excludeUnsupportedVariants_();let o;if(this.enableLowInitialPlaylist&&(o=this.selectInitialPlaylist()),o||(o=this.selectPlaylist()),!o||!this.shouldSwitchToMedia_(o)||(this.initialMedia_=o,this.switchMedia_(this.initialMedia_,"initial"),!(this.sourceType_==="vhs-json"&&this.initialMedia_.segments)))return;n=this.initialMedia_}this.handleUpdatedMediaPlaylist(n)}),this.mainPlaylistLoader_.on("error",()=>{const n=this.mainPlaylistLoader_.error;this.excludePlaylist({playlistToExclude:n.playlist,error:n})}),this.mainPlaylistLoader_.on("mediachanging",()=>{this.mainSegmentLoader_.abort(),this.mainSegmentLoader_.pause()}),this.mainPlaylistLoader_.on("mediachange",()=>{const n=this.mainPlaylistLoader_.media(),o=n.targetDuration*1.5*1e3;isLowestEnabledRendition(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.media())?this.requestOptions_.timeout=0:this.requestOptions_.timeout=o,this.sourceType_==="dash"&&this.mainPlaylistLoader_.load(),this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.playlist(n,this.requestOptions_),this.waitingForFastQualityPlaylistReceived_?this.runFastQualitySwitch_():this.mainSegmentLoader_.load(),this.tech_.trigger({type:"mediachange",bubbles:!0})}),this.mainPlaylistLoader_.on("playlistunchanged",()=>{const n=this.mainPlaylistLoader_.media();if(n.lastExcludeReason_==="playlist-unchanged")return;this.stuckAtPlaylistEnd_(n)&&(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(n=>{this.mainPlaylistLoader_.on(n,o=>{this.player_.trigger(_extends$2({},o))})})}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,n){const o=e.mediaGroups||{};let u=!0;const l=Object.keys(o.AUDIO);for(const m in o.AUDIO)for(const y in o.AUDIO[m])o.AUDIO[m][y].uri||(u=!1);u&&this.tech_.trigger({type:"usage",name:"vhs-demuxed"}),Object.keys(o.SUBTITLES).length&&this.tech_.trigger({type:"usage",name:"vhs-webvtt"}),Vhs$1.Playlist.isAes(n)&&this.tech_.trigger({type:"usage",name:"vhs-aes"}),l.length&&Object.keys(o.AUDIO[l[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 n=this.mainPlaylistLoader_.media()||this.mainPlaylistLoader_.pendingMedia_,o=this.tech_.currentTime(),u=this.bufferLowWaterLine(),l=this.bufferHighWaterLine(),m=this.tech_.buffered();return shouldSwitchToMedia({buffered:m,currentTime:o,currentPlaylist:n,nextPlaylist:e,bufferLowWaterLine:u,bufferHighWaterLine:l,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 o=this.mainSegmentLoader_.error();this.excludePlaylist({playlistToExclude:o.playlist,error:o})}),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 o=this.audioSegmentLoader_.pendingSegment_;if(!o||!o.segment||!o.segment.syncInfo)return;const u=o.segment.syncInfo.end+.01;this.tech_.setCurrentTime(u)}),this.mainSegmentLoader_.on("earlyabort",o=>{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:ABORT_EARLY_EXCLUSION_SECONDS}))});const e=()=>{if(!this.sourceUpdater_.hasCreatedSourceBuffers())return this.tryToCreateSourceBuffers_();const o=this.getCodecsOrExclude_();o&&this.sourceUpdater_.addOrChangeSourceBuffers(o)};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(o=>{this.mainSegmentLoader_.on(o,u=>{this.player_.trigger(_extends$2({},u))}),this.audioSegmentLoader_.on(o,u=>{this.player_.trigger(_extends$2({},u))}),this.subtitleSegmentLoader_.on(o,u=>{this.player_.trigger(_extends$2({},u))})})}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()<e.start(0))return this.tech_.setCurrentTime(e.end(e.length-1))}setupFirstPlay(){const e=this.mainPlaylistLoader_.media();if(!e||this.tech_.paused()||this.hasPlayed_)return!1;if(!e.endList||e.start){const n=this.seekable();if(!n.length)return!1;const o=n.end(0);let u=o;if(e.start){const l=e.start.timeOffset;l<0?u=Math.max(o+l,n.start(0)):u=Math.min(o,l)}this.trigger("firstplay"),this.tech_.setCurrentTime(u)}return this.hasPlayed_=!0,this.load(),!0}handleSourceOpen_(){if(this.tryToCreateSourceBuffers_(),this.tech_.autoplay()){const e=this.tech_.play();typeof e<"u"&&typeof e.then=="function"&&e.then(null,n=>{})}this.trigger("sourceopen")}handleSourceEnded_(){if(!this.inbandTextTracks_.metadataTrack_)return;const e=this.inbandTextTracks_.metadataTrack_.cues;if(!e||!e.length)return;const n=this.duration();e[e.length-1].endTime=isNaN(n)||Math.abs(n)===1/0?Number.MAX_VALUE:n}handleDurationChange_(){this.tech_.trigger("durationchange")}onEndOfStream(){let e=this.mainSegmentLoader_.ended_;if(this.mediaTypes_.AUDIO.activePlaylistLoader){const n=this.mainSegmentLoader_.getCurrentMediaInfo_();!n||n.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 o=this.syncController_.getExpiredTime(e,this.duration());if(o===null)return!1;const u=Vhs$1.Playlist.playlistEnd(e,o),l=this.tech_.currentTime(),m=this.tech_.buffered();if(!m.length)return u-l<=SAFE_TIME_DELTA;const y=m.end(m.length-1);return y-l<=SAFE_TIME_DELTA&&u-y<=SAFE_TIME_DELTA}excludePlaylist({playlistToExclude:e=this.mainPlaylistLoader_.media(),error:n={},playlistExclusionDuration:o}){if(e=e||this.mainPlaylistLoader_.media(),o=o||n.playlistExclusionDuration||this.playlistExclusionDuration,!e){this.error=n,this.mediaSource.readyState!=="open"?this.trigger("error"):this.sourceUpdater_.endOfStream("network");return}e.playlistErrors_++;const u=this.mainPlaylistLoader_.main.playlists,l=u.filter(isEnabled),m=l.length===1&&l[0]===e;if(u.length===1&&o!==1/0)return videojs.log.warn(`Problem encountered with playlist ${e.id}. Trying again since it is the only playlist.`),this.tech_.trigger("retryplaylist"),this.mainPlaylistLoader_.load(m);if(m){if(this.main().contentSteering){const R=this.pathwayAttribute_(e),B=this.contentSteeringController_.steeringManifest.ttl*1e3;this.contentSteeringController_.excludePathway(R),this.excludeThenChangePathway_(),setTimeout(()=>{this.contentSteeringController_.addAvailablePathway(R)},B);return}let P=!1;u.forEach(R=>{if(R===e)return;const B=R.excludeUntil;typeof B<"u"&&B!==1/0&&(P=!0,delete R.excludeUntil)}),P&&(videojs.log.warn("Removing other playlists from the exclusion list because the last rendition is about to be excluded."),this.tech_.trigger("retryplaylist"))}let y;e.playlistErrors_>this.maxPlaylistRetries?y=1/0:y=Date.now()+o*1e3,e.excludeUntil=y,n.reason&&(e.lastExcludeReason_=n.reason),this.tech_.trigger("excludeplaylist"),this.tech_.trigger({type:"usage",name:"vhs-rendition-excluded"});const E=this.selectPlaylist();if(!E){this.error="Playback cannot continue. No available working or supported playlists.",this.trigger("error");return}const C=n.internal?this.logger_:videojs.log.warn,k=n.message?" "+n.message:"";C(`${n.internal?"Internal problem":"Problem"} encountered with playlist ${e.id}.${k} Switching to playlist ${E.id}.`),E.attributes.AUDIO!==e.attributes.AUDIO&&this.delegateLoaders_("audio",["abort","pause"]),E.attributes.SUBTITLES!==e.attributes.SUBTITLES&&this.delegateLoaders_("subtitle",["abort","pause"]),this.delegateLoaders_("main",["abort","pause"]);const A=E.targetDuration/2*1e3||5*1e3,D=typeof E.lastRequest=="number"&&Date.now()-E.lastRequest<=A;return this.switchMedia_(E,"exclude",m||D)}pauseLoading(){this.delegateLoaders_("all",["abort","pause"]),this.stopABRTimer_()}delegateLoaders_(e,n){const o=[],u=e==="all";(u||e==="main")&&o.push(this.mainPlaylistLoader_);const l=[];(u||e==="audio")&&l.push("AUDIO"),(u||e==="subtitle")&&(l.push("CLOSED-CAPTIONS"),l.push("SUBTITLES")),l.forEach(m=>{const y=this.mediaTypes_[m]&&this.mediaTypes_[m].activePlaylistLoader;y&&o.push(y)}),["main","audio","subtitle"].forEach(m=>{const y=this[`${m}SegmentLoader_`];y&&(e===m||e==="all")&&o.push(y)}),o.forEach(m=>n.forEach(y=>{typeof m[y]=="function"&&m[y]()}))}setCurrentTime(e){const n=findRange(this.tech_.buffered(),e);if(!(this.mainPlaylistLoader_&&this.mainPlaylistLoader_.media())||!this.mainPlaylistLoader_.media().segments)return 0;if(n&&n.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:Vhs$1.Playlist.duration(e):1/0:0}seekable(){return this.seekable_}onSyncInfoUpdate_(){let e;if(!this.mainPlaylistLoader_)return;let n=this.mainPlaylistLoader_.media();if(!n)return;let o=this.syncController_.getExpiredTime(n,this.duration());if(o===null)return;const u=this.mainPlaylistLoader_.main,l=Vhs$1.Playlist.seekable(n,o,Vhs$1.Playlist.liveEdgeDelay(u,n));if(l.length===0||this.mediaTypes_.AUDIO.activePlaylistLoader&&(n=this.mediaTypes_.AUDIO.activePlaylistLoader.media(),o=this.syncController_.getExpiredTime(n,this.duration()),o===null||(e=Vhs$1.Playlist.seekable(n,o,Vhs$1.Playlist.liveEdgeDelay(u,n)),e.length===0)))return;let m,y;if(this.seekable_&&this.seekable_.length&&(m=this.seekable_.end(0),y=this.seekable_.start(0)),e?e.start(0)>l.end(0)||l.start(0)>e.end(0)?this.seekable_=l:this.seekable_=createTimeRanges([[e.start(0)>l.start(0)?e.start(0):l.start(0),e.end(0)<l.end(0)?e.end(0):l.end(0)]]):this.seekable_=l,this.seekable_&&this.seekable_.length&&this.seekable_.end(0)===m&&this.seekable_.start(0)===y)return;this.logger_(`seekable updated [${printableRange(this.seekable_)}]`);const E={seekableRanges:this.seekable_};this.trigger({type:"seekablerangeschanged",metadata:E}),this.tech_.trigger("seekablechanged")}updateDuration(e){if(this.updateDuration_&&(this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.updateDuration_=null),this.mediaSource.readyState!=="open"){this.updateDuration_=this.updateDuration.bind(this,e),this.mediaSource.addEventListener("sourceopen",this.updateDuration_);return}if(e){const u=this.seekable();if(!u.length)return;(isNaN(this.mediaSource.duration)||this.mediaSource.duration<u.end(u.length-1))&&this.sourceUpdater_.setDuration(u.end(u.length-1));return}const n=this.tech_.buffered();let o=Vhs$1.Playlist.duration(this.mainPlaylistLoader_.media());n.length>0&&(o=Math.max(o,n.end(n.length-1))),this.mediaSource.duration!==o&&this.sourceUpdater_.setDuration(o)}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 n=this.mediaTypes_[e].groups;for(const o in n)n[o].forEach(u=>{u.playlistLoader&&u.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,n=!!this.mainSegmentLoader_.getCurrentMediaInfo_(),o=e?!!this.audioSegmentLoader_.getCurrentMediaInfo_():!0;return!(!n||!o)}getCodecsOrExclude_(){const e={main:this.mainSegmentLoader_.getCurrentMediaInfo_()||{},audio:this.audioSegmentLoader_.getCurrentMediaInfo_()||{}},n=this.mainSegmentLoader_.getPendingSegmentPlaylist()||this.media();e.video=e.main;const o=codecsForPlaylist(this.main(),n),u={},l=!!this.mediaTypes_.AUDIO.activePlaylistLoader;if(e.main.hasVideo&&(u.video=o.video||e.main.videoCodec||DEFAULT_VIDEO_CODEC),e.main.isMuxed&&(u.video+=`,${o.audio||e.main.audioCodec||DEFAULT_AUDIO_CODEC}`),(e.main.hasAudio&&!e.main.isMuxed||e.audio.hasAudio||l)&&(u.audio=o.audio||e.main.audioCodec||e.audio.audioCodec||DEFAULT_AUDIO_CODEC,e.audio.isFmp4=e.main.hasAudio&&!e.main.isMuxed?e.main.isFmp4:e.audio.isFmp4),!u.audio&&!u.video){this.excludePlaylist({playlistToExclude:n,error:{message:"Could not determine codecs for playlist."},playlistExclusionDuration:1/0});return}const m=(C,k)=>C?browserSupportsCodec(k):muxerSupportsCodec(k),y={};let E;if(["video","audio"].forEach(function(C){if(u.hasOwnProperty(C)&&!m(e[C].isFmp4,u[C])){const k=e[C].isFmp4?"browser":"muxer";y[k]=y[k]||[],y[k].push(u[C]),C==="audio"&&(E=k)}}),l&&E&&n.attributes.AUDIO){const C=n.attributes.AUDIO;this.main().playlists.forEach(k=>{(k.attributes&&k.attributes.AUDIO)===C&&k!==n&&(k.excludeUntil=1/0)}),this.logger_(`excluding audio group ${C} as ${E} does not support codec(s): "${u.audio}"`)}if(Object.keys(y).length){const C=Object.keys(y).reduce((k,A)=>(k&&(k+=", "),k+=`${A} does not support codec(s): "${y[A].join(",")}"`,k),"")+".";this.excludePlaylist({playlistToExclude:n,error:{internal:!0,message:C},playlistExclusionDuration:1/0});return}if(this.sourceUpdater_.hasCreatedSourceBuffers()&&!this.sourceUpdater_.canChangeType()){const C=[];if(["video","audio"].forEach(k=>{const A=(parseCodecs(this.sourceUpdater_.codecs[k]||"")[0]||{}).type,D=(parseCodecs(u[k]||"")[0]||{}).type;A&&D&&A.toLowerCase()!==D.toLowerCase()&&C.push(`"${this.sourceUpdater_.codecs[k]}" -> "${u[k]}"`)}),C.length){this.excludePlaylist({playlistToExclude:n,error:{message:`Codec switching not supported: ${C.join(", ")}.`,internal:!0},playlistExclusionDuration:1/0});return}}return u}tryToCreateSourceBuffers_(){if(this.mediaSource.readyState!=="open"||this.sourceUpdater_.hasCreatedSourceBuffers()||!this.areMediaTypesKnown_())return;const e=this.getCodecsOrExclude_();if(!e)return;this.sourceUpdater_.createSourceBuffers(e);const n=[e.video,e.audio].filter(Boolean).join(",");this.excludeIncompatibleVariants_(n)}excludeUnsupportedVariants_(){const e=this.main().playlists,n=[];Object.keys(e).forEach(o=>{const u=e[o];if(n.indexOf(u.id)!==-1)return;n.push(u.id);const l=codecsForPlaylist(this.main,u),m=[];l.audio&&!muxerSupportsCodec(l.audio)&&!browserSupportsCodec(l.audio)&&m.push(`audio codec ${l.audio}`),l.video&&!muxerSupportsCodec(l.video)&&!browserSupportsCodec(l.video)&&m.push(`video codec ${l.video}`),l.text&&l.text==="stpp.ttml.im1t"&&m.push(`text codec ${l.text}`),m.length&&(u.excludeUntil=1/0,this.logger_(`excluding ${u.id} for unsupported: ${m.join(", ")}`))})}excludeIncompatibleVariants_(e){const n=[],o=this.main().playlists,u=unwrapCodecList(parseCodecs(e)),l=codecCount(u),m=u.video&&parseCodecs(u.video)[0]||null,y=u.audio&&parseCodecs(u.audio)[0]||null;Object.keys(o).forEach(E=>{const C=o[E];if(n.indexOf(C.id)!==-1||C.excludeUntil===1/0)return;n.push(C.id);const k=[],A=codecsForPlaylist(this.mainPlaylistLoader_.main,C),D=codecCount(A);if(!(!A.audio&&!A.video)){if(D!==l&&k.push(`codec count "${D}" !== "${l}"`),!this.sourceUpdater_.canChangeType()){const P=A.video&&parseCodecs(A.video)[0]||null,R=A.audio&&parseCodecs(A.audio)[0]||null;P&&m&&P.type.toLowerCase()!==m.type.toLowerCase()&&k.push(`video codec "${P.type}" !== "${m.type}"`),R&&y&&R.type.toLowerCase()!==y.type.toLowerCase()&&k.push(`audio codec "${R.type}" !== "${y.type}"`)}k.length&&(C.excludeUntil=1/0,this.logger_(`excluding ${C.id}: ${k.join(" && ")}`))}})}updateAdCues_(e){let n=0;const o=this.seekable();o.length&&(n=o.start(0)),updateAdCues(e,this.cueTagsTrack_,n)}goalBufferLength(){const e=this.tech_.currentTime(),n=Config.GOAL_BUFFER_LENGTH,o=Config.GOAL_BUFFER_LENGTH_RATE,u=Math.max(n,Config.MAX_GOAL_BUFFER_LENGTH);return Math.min(n+e*o,u)}bufferLowWaterLine(){const e=this.tech_.currentTime(),n=Config.BUFFER_LOW_WATER_LINE,o=Config.BUFFER_LOW_WATER_LINE_RATE,u=Math.max(n,Config.MAX_BUFFER_LOW_WATER_LINE),l=Math.max(n,Config.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE);return Math.min(n+e*o,this.bufferBasedABR?l:u)}bufferHighWaterLine(){return Config.BUFFER_HIGH_WATER_LINE}addDateRangesToTextTrack_(e){createMetadataTrackIfNotExists(this.inbandTextTracks_,"com.apple.streaming",this.tech_),addDateRangeMetadata({inbandTextTracks:this.inbandTextTracks_,dateRanges:e})}addMetadataToTextTrack(e,n,o){const u=this.sourceUpdater_.videoBuffer?this.sourceUpdater_.videoTimestampOffset():this.sourceUpdater_.audioTimestampOffset();createMetadataTrackIfNotExists(this.inbandTextTracks_,e,this.tech_),addMetadata({inbandTextTracks:this.inbandTextTracks_,metadataArray:n,timestampOffset:u,videoDuration:o})}pathwayAttribute_(e){return e.attributes["PATHWAY-ID"]||e.attributes.serviceLocation}initContentSteeringController_(){const e=this.main();if(e.contentSteering){for(const n of e.playlists)this.contentSteeringController_.addAvailablePathway(this.pathwayAttribute_(n));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(n=>{this.contentSteeringController_.on(n,o=>{this.trigger(_extends$2({},o))})}),this.sourceType_==="dash"&&this.mainPlaylistLoader_.on("loadedplaylist",()=>{const n=this.main();(this.contentSteeringController_.didDASHTagChange(n.uri,n.contentSteering)||(()=>{const l=this.contentSteeringController_.getAvailablePathways(),m=[];for(const y of n.playlists){const E=y.attributes.serviceLocation;if(E&&(m.push(E),!l.has(E)))return!0}return!!(!m.length&&l.size)})())&&this.resetContentSteeringController_()})}excludeThenChangePathway_(){const e=this.contentSteeringController_.getPathway();if(!e)return;this.handlePathwayClones_();const o=this.main().playlists,u=new Set;let l=!1;Object.keys(o).forEach(m=>{const y=o[m],E=this.pathwayAttribute_(y),C=E&&e!==E;y.excludeUntil===1/0&&y.lastExcludeReason_==="content-steering"&&!C&&(delete y.excludeUntil,delete y.lastExcludeReason_,l=!0);const A=!y.excludeUntil&&y.excludeUntil!==1/0;!u.has(y.id)&&C&&A&&(u.add(y.id),y.excludeUntil=1/0,y.lastExcludeReason_="content-steering",this.logger_(`excluding ${y.id} for ${y.lastExcludeReason_}`))}),this.contentSteeringController_.manifestType_==="DASH"&&Object.keys(this.mediaTypes_).forEach(m=>{const y=this.mediaTypes_[m];if(y.activePlaylistLoader){const E=y.activePlaylistLoader.media_;E&&E.attributes.serviceLocation!==e&&(l=!0)}}),l&&this.changeSegmentPathway_()}handlePathwayClones_(){const n=this.main().playlists,o=this.contentSteeringController_.currentPathwayClones,u=this.contentSteeringController_.nextPathwayClones;if(o&&o.size||u&&u.size){for(const[m,y]of o.entries())u.get(m)||(this.mainPlaylistLoader_.updateOrDeleteClone(y),this.contentSteeringController_.excludePathway(m));for(const[m,y]of u.entries()){const E=o.get(m);if(!E){n.filter(k=>k.attributes["PATHWAY-ID"]===y["BASE-ID"]).forEach(k=>{this.mainPlaylistLoader_.addClonePathway(y,k)}),this.contentSteeringController_.addAvailablePathway(m);continue}this.equalPathwayClones_(E,y)||(this.mainPlaylistLoader_.updateOrDeleteClone(y,!0),this.contentSteeringController_.addAvailablePathway(m))}this.contentSteeringController_.currentPathwayClones=new Map(JSON.parse(JSON.stringify([...u])))}}equalPathwayClones_(e,n){if(e["BASE-ID"]!==n["BASE-ID"]||e.ID!==n.ID||e["URI-REPLACEMENT"].HOST!==n["URI-REPLACEMENT"].HOST)return!1;const o=e["URI-REPLACEMENT"].PARAMS,u=n["URI-REPLACEMENT"].PARAMS;for(const l in o)if(o[l]!==u[l])return!1;for(const l in u)if(o[l]!==u[l])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 n="non-usable";this.mainPlaylistLoader_.main.playlists.forEach(o=>{const u=this.mainPlaylistLoader_.getKeyIdSet(o);!u||!u.size||u.forEach(l=>{const m="usable",y=this.keyStatusMap_.has(l)&&this.keyStatusMap_.get(l)===m,E=o.lastExcludeReason_===n&&o.excludeUntil===1/0;y?y&&E&&(delete o.excludeUntil,delete o.lastExcludeReason_,this.logger_(`enabling playlist ${o.id} because key ID ${l} is ${m}`)):(o.excludeUntil!==1/0&&o.lastExcludeReason_!==n&&(o.excludeUntil=1/0,o.lastExcludeReason_=n,this.logger_(`excluding playlist ${o.id} because the key ID ${l} doesn't exist in the keyStatusMap or is not ${m}`)),e++)})}),e>=this.mainPlaylistLoader_.main.playlists.length&&this.mainPlaylistLoader_.main.playlists.forEach(o=>{const u=o&&o.attributes&&o.attributes.RESOLUTION&&o.attributes.RESOLUTION.height<720,l=o.excludeUntil===1/0&&o.lastExcludeReason_===n;u&&l&&(delete o.excludeUntil,videojs.log.warn(`enabling non-HD playlist ${o.id} because all playlists were excluded due to ${n} key IDs`))})}addKeyStatus_(e,n){const l=(typeof e=="string"?e:bufferToHexString(e)).slice(0,32).toLowerCase();this.logger_(`KeyStatus '${n}' with key ID ${l} added to the keyStatusMap`),this.keyStatusMap_.set(l,n)}updatePlaylistByKeyStatus(e,n){this.addKeyStatus_(e,n),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 enableFunction=(t,e,n)=>o=>{const u=t.main.playlists[e],l=isIncompatible(u),m=isEnabled(u);if(typeof o>"u")return m;o?delete u.disabled:u.disabled=!0;const y={renditionInfo:{id:e,bandwidth:u.attributes.BANDWIDTH,resolution:u.attributes.RESOLUTION,codecs:u.attributes.CODECS},cause:"fast-quality"};return o!==m&&!l&&(n(u),o?t.trigger({type:"renditionenabled",metadata:y}):t.trigger({type:"renditiondisabled",metadata:y})),o};class Representation{constructor(e,n,o){const{playlistController_:u}=e,l=u.fastQualityChange_.bind(u);if(n.attributes){const m=n.attributes.RESOLUTION;this.width=m&&m.width,this.height=m&&m.height,this.bandwidth=n.attributes.BANDWIDTH,this.frameRate=n.attributes["FRAME-RATE"]}this.codecs=codecsForPlaylist(u.main(),n),this.playlist=n,this.id=o,this.enabled=enableFunction(e.playlists,n.id,l)}}const renditionSelectionMixin=function(t){t.representations=()=>{const e=t.playlistController_.main(),n=isAudioOnly(e)?t.playlistController_.getAudioTrackPlaylists_():e.playlists;return n?n.filter(o=>!isIncompatible(o)).map((o,u)=>new Representation(t,o,o.id)):[]}},timerCancelEvents=["seeking","seeked","pause","playing","error"];class PlaybackWatcher extends videojs.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_=logger("PlaybackWatcher"),this.logger_("initialize");const n=()=>this.monitorCurrentTime_(),o=()=>this.monitorCurrentTime_(),u=()=>this.techWaiting_(),l=()=>this.resetTimeUpdate_(),m=this.playlistController_,y=["main","subtitle","audio"],E={};y.forEach(k=>{E[k]={reset:()=>this.resetSegmentDownloads_(k),updateend:()=>this.checkSegmentDownloads_(k)},m[`${k}SegmentLoader_`].on("appendsdone",E[k].updateend),m[`${k}SegmentLoader_`].on("playlistupdate",E[k].reset),this.tech_.on(["seeked","seeking"],E[k].reset)});const C=k=>{["main","audio"].forEach(A=>{m[`${A}SegmentLoader_`][k]("appended",this.seekingAppendCheck_)})};this.seekingAppendCheck_=()=>{this.fixesBadSeeks_()&&(this.consecutiveUpdates=0,this.lastRecordedTime=this.tech_.currentTime(),C("off"))},this.clearSeekingAppendCheck_=()=>C("off"),this.watchForBadSeeking_=()=>{this.clearSeekingAppendCheck_(),C("on")},this.tech_.on("seeked",this.clearSeekingAppendCheck_),this.tech_.on("seeking",this.watchForBadSeeking_),this.tech_.on("waiting",u),this.tech_.on(timerCancelEvents,l),this.tech_.on("canplay",o),this.tech_.one("play",n),this.dispose=()=>{this.clearSeekingAppendCheck_(),this.logger_("dispose"),this.tech_.off("waiting",u),this.tech_.off(timerCancelEvents,l),this.tech_.off("canplay",o),this.tech_.off("play",n),this.tech_.off("seeking",this.watchForBadSeeking_),this.tech_.off("seeked",this.clearSeekingAppendCheck_),y.forEach(k=>{m[`${k}SegmentLoader_`].off("appendsdone",E[k].updateend),m[`${k}SegmentLoader_`].off("playlistupdate",E[k].reset),this.tech_.off(["seeked","seeking"],E[k].reset)}),this.checkCurrentTimeTimeout_&&window$1$1.clearTimeout(this.checkCurrentTimeTimeout_),this.resetTimeUpdate_()}}monitorCurrentTime_(){this.checkCurrentTime_(),this.checkCurrentTimeTimeout_&&window$1$1.clearTimeout(this.checkCurrentTimeTimeout_),this.checkCurrentTimeTimeout_=window$1$1.setTimeout(this.monitorCurrentTime_.bind(this),250)}resetSegmentDownloads_(e){const n=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_`]=n.buffered_()}checkSegmentDownloads_(e){const n=this.playlistController_,o=n[`${e}SegmentLoader_`],u=o.buffered_(),l=isRangeDifferent(this[`${e}Buffered_`],u);if(this[`${e}Buffered_`]=u,l){const m={bufferedRanges:u};n.trigger({type:"bufferedrangeschanged",metadata:m}),this.resetSegmentDownloads_(e);return}this[`${e}StalledDownloads_`]++,this.logger_(`found #${this[`${e}StalledDownloads_`]} ${e} appends that did not increase buffer (possible stalled download)`,{playlistId:o.playlist_&&o.playlist_.id,buffered:timeRangesToArray(u)}),!(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"&&n.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(),n=this.tech_.buffered();if(this.lastRecordedTime===e&&(!n.length||e+SAFE_TIME_DELTA>=n.end(n.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(createTimeRanges([this.lastRecordedTime,e]));const o={playedRanges:this.playedRanges_};this.playlistController_.trigger({type:"playedrangeschanged",metadata:o}),this.consecutiveUpdates=0,this.lastRecordedTime=e}}resetTimeUpdate_(){this.consecutiveUpdates=0}fixesBadSeeks_(){if(!this.tech_.seeking())return!1;const n=this.seekable(),o=this.tech_.currentTime(),u=this.afterSeekableWindow_(n,o,this.media(),this.allowSeeksWithinUnsafeLiveWindow);let l;if(u&&(l=n.end(n.length-1)),this.beforeSeekableWindow_(n,o)){const R=n.start(0);l=R+(R===n.end(0)?0:SAFE_TIME_DELTA)}if(typeof l<"u")return this.logger_(`Trying to seek outside of seekable at time ${o} with seekable range ${printableRange(n)}. Seeking to ${l}.`),this.tech_.setCurrentTime(l),!0;const m=this.playlistController_.sourceUpdater_,y=this.tech_.buffered(),E=m.audioBuffer?m.audioBuffered():null,C=m.videoBuffer?m.videoBuffered():null,k=this.media(),A=k.partTargetDuration?k.partTargetDuration:(k.targetDuration-TIME_FUDGE_FACTOR)*2,D=[E,C];for(let R=0;R<D.length;R++){if(!D[R])continue;if(timeAheadOf(D[R],o)<A)return!1}const P=findNextRange(y,o);return P.length===0?!1:(l=P.start(0)+SAFE_TIME_DELTA,this.logger_(`Buffered region starts (${P.start(0)})  just beyond seek point (${o}). Seeking to ${l}.`),this.tech_.setCurrentTime(l),!0)}waiting_(){if(this.techWaiting_())return;const e=this.tech_.currentTime(),n=this.tech_.buffered(),o=findRange(n,e);if(o.length&&e+3<=o.end(0)){this.resetTimeUpdate_(),this.tech_.setCurrentTime(e),this.logger_(`Stopped at ${e} while inside a buffered region [${o.start(0)} -> ${o.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(),n=this.tech_.currentTime();if(this.tech_.seeking())return!0;if(this.beforeSeekableWindow_(e,n)){const y=e.end(e.length-1);return this.logger_(`Fell out of live window at time ${n}. Seeking to live point (seekable end) ${y}`),this.resetTimeUpdate_(),this.tech_.setCurrentTime(y),this.tech_.trigger({type:"usage",name:"vhs-live-resync"}),!0}const o=this.tech_.vhs.playlistController_.sourceUpdater_,u=this.tech_.buffered();if(this.videoUnderflow_({audioBuffered:o.audioBuffered(),videoBuffered:o.videoBuffered(),currentTime:n}))return this.resetTimeUpdate_(),this.tech_.setCurrentTime(n),this.tech_.trigger({type:"usage",name:"vhs-video-underflow"}),!0;const m=findNextRange(u,n);return m.length>0?(this.logger_(`Stopped at ${n} and seeking to ${m.start(0)}`),this.resetTimeUpdate_(),this.skipTheGap_(n),!0):!1}afterSeekableWindow_(e,n,o,u=!1){if(!e.length)return!1;let l=e.end(e.length-1)+SAFE_TIME_DELTA;const m=!o.endList,y=typeof o.partTargetDuration=="number";return m&&(y||u)&&(l=e.end(e.length-1)+o.targetDuration*3),n>l}beforeSeekableWindow_(e,n){return!!(e.length&&e.start(0)>0&&n<e.start(0)-this.liveRangeSafeTimeDelta)}videoUnderflow_({videoBuffered:e,audioBuffered:n,currentTime:o}){if(!e)return;let u;if(e.length&&n.length){const l=findRange(e,o-3),m=findRange(e,o),y=findRange(n,o);y.length&&!m.length&&l.length&&(u={start:l.end(0),end:y.end(0)})}else findNextRange(e,o).length||(u=this.gapFromVideoUnderflow_(e,o));return u?(this.logger_(`Encountered a gap in video from ${u.start} to ${u.end}. Seeking to current time ${o}`),!0):!1}skipTheGap_(e){const n=this.tech_.buffered(),o=this.tech_.currentTime(),u=findNextRange(n,o);if(this.resetTimeUpdate_(),u.length===0||o!==e)return;this.logger_("skipTheGap_:","currentTime:",o,"scheduled currentTime:",e,"nextRange start:",u.start(0)),this.tech_.setCurrentTime(u.start(0)+TIME_FUDGE_FACTOR);const l={gapInfo:{from:o,to:u.start(0)}};this.playlistController_.trigger({type:"gapjumped",metadata:l}),this.tech_.trigger({type:"usage",name:"vhs-gap-skip"})}gapFromVideoUnderflow_(e,n){const o=findGaps(e);for(let u=0;u<o.length;u++){const l=o.start(u),m=o.end(u);if(n-l<4&&n-l>2)return{start:l,end:m}}return null}}const defaultOptions$1={errorInterval:30,getSource(t){const n=this.tech({IWillNotUseThisInPlugins:!0}).currentSource_||this.currentSource();return t(n)}},initPlugin=function(t,e){let n=0,o=0;const u=merge(defaultOptions$1,e);t.ready(()=>{t.trigger({type:"usage",name:"vhs-error-reload-initialized"})});const l=function(){o&&t.currentTime(o)},m=function(k){k!=null&&(o=t.duration()!==1/0&&t.currentTime()||0,t.one("loadedmetadata",l),t.src(k),t.trigger({type:"usage",name:"vhs-error-reload"}),t.play())},y=function(){if(Date.now()-n<u.errorInterval*1e3){t.trigger({type:"usage",name:"vhs-error-reload-canceled"});return}if(!u.getSource||typeof u.getSource!="function"){videojs.log.error("ERROR: reloadSourceOnError - The option getSource must be a function!");return}return n=Date.now(),u.getSource.call(t,m)},E=function(){t.off("loadedmetadata",l),t.off("error",y),t.off("dispose",E)},C=function(k){E(),initPlugin(t,k)};t.on("error",y),t.on("dispose",E),t.reloadSourceOnError=C},reloadSourceOnError=function(t){initPlugin(this,t)};var version$4="3.14.2",version$3="7.0.3",version$2$1="1.3.0",version$1$1="7.2.0",version$7="4.0.2";const Vhs={PlaylistLoader,Playlist,utils:utils$r,STANDARD_PLAYLIST_SELECTOR:lastBandwidthSelector,INITIAL_PLAYLIST_SELECTOR:lowestBitrateCompatibleVariantSelector,lastBandwidthSelector,movingAverageBandwidthSelector,comparePlaylistBandwidth,comparePlaylistResolution,xhr:xhrFactory()};Object.keys(Config).forEach(t=>{Object.defineProperty(Vhs,t,{get(){return videojs.log.warn(`using Vhs.${t} is UNSAFE be sure you know what you are doing`),Config[t]},set(e){if(videojs.log.warn(`using Vhs.${t} is UNSAFE be sure you know what you are doing`),typeof e!="number"||e<0){videojs.log.warn(`value of Vhs.${t} must be greater than or equal to 0`);return}Config[t]=e}})});const LOCAL_STORAGE_KEY="videojs-vhs",handleVhsMediaChange=function(t,e){const n=e.media();let o=-1;for(let u=0;u<t.length;u++)if(t[u].id===n.id){o=u;break}t.selectedIndex_=o,t.trigger({selectedIndex:o,type:"change"})},handleVhsLoadedMetadata=function(t,e){e.representations().forEach(n=>{t.addQualityLevel(n)}),handleVhsMediaChange(t,e.playlists)};Vhs.canPlaySource=function(){return videojs.log.warn("VHS is no longer a tech. Please remove it from your player's techOrder.")};const emeKeySystems=(t,e,n)=>{if(!t)return t;let o={};e&&e.attributes&&e.attributes.CODECS&&(o=unwrapCodecList(parseCodecs(e.attributes.CODECS))),n&&n.attributes&&n.attributes.CODECS&&(o.audio=n.attributes.CODECS);const u=getMimeForCodec(o.video),l=getMimeForCodec(o.audio),m={};for(const y in t)m[y]={},l&&(m[y].audioContentType=l),u&&(m[y].videoContentType=u),e.contentProtection&&e.contentProtection[y]&&e.contentProtection[y].pssh&&(m[y].pssh=e.contentProtection[y].pssh),typeof t[y]=="string"&&(m[y].url=t[y]);return merge(t,m)},getAllPsshKeySystemsOptions=(t,e)=>t.reduce((n,o)=>{if(!o.contentProtection)return n;const u=e.reduce((l,m)=>{const y=o.contentProtection[m];return y&&y.pssh&&(l[m]={pssh:y.pssh}),l},{});return Object.keys(u).length&&n.push(u),n},[]),waitForKeySessionCreation=({player:t,sourceKeySystems:e,audioMedia:n,mainPlaylists:o})=>{if(!t.eme.initializeMediaKeys)return Promise.resolve();const u=n?o.concat([n]):o,l=getAllPsshKeySystemsOptions(u,Object.keys(e)),m=[],y=[];return l.forEach(E=>{y.push(new Promise((C,k)=>{t.tech_.one("keysessioncreated",C)})),m.push(new Promise((C,k)=>{t.eme.initializeMediaKeys({keySystems:E},A=>{if(A){k(A);return}C()})}))}),Promise.race([Promise.all(m),Promise.race(y)])},setupEmeOptions=({player:t,sourceKeySystems:e,media:n,audioMedia:o})=>{const u=emeKeySystems(e,n,o);return u?(t.currentSource().keySystems=u,u&&!t.eme?(videojs.log.warn("DRM encrypted source cannot be decrypted without a DRM plugin"),!1):!0):!1},getVhsLocalStorage=()=>{if(!window$1$1.localStorage)return null;const t=window$1$1.localStorage.getItem(LOCAL_STORAGE_KEY);if(!t)return null;try{return JSON.parse(t)}catch{return null}},updateVhsLocalStorage=t=>{if(!window$1$1.localStorage)return!1;let e=getVhsLocalStorage();e=e?merge(e,t):t;try{window$1$1.localStorage.setItem(LOCAL_STORAGE_KEY,JSON.stringify(e))}catch{return!1}return e},expandDataUri=t=>t.toLowerCase().indexOf("data:application/vnd.videojs.vhs+json,")===0?JSON.parse(t.substring(t.indexOf(",")+1)):t,addOnRequestHook=(t,e)=>{t._requestCallbackSet||(t._requestCallbackSet=new Set),t._requestCallbackSet.add(e)},addOnResponseHook=(t,e)=>{t._responseCallbackSet||(t._responseCallbackSet=new Set),t._responseCallbackSet.add(e)},removeOnRequestHook=(t,e)=>{t._requestCallbackSet&&(t._requestCallbackSet.delete(e),t._requestCallbackSet.size||delete t._requestCallbackSet)},removeOnResponseHook=(t,e)=>{t._responseCallbackSet&&(t._responseCallbackSet.delete(e),t._responseCallbackSet.size||delete t._responseCallbackSet)};Vhs.supportsNativeHls=function(){if(!document$1$1||!document$1$1.createElement)return!1;const t=document$1$1.createElement("video");return videojs.getTech("Html5").isSupported()?["application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","application/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"].some(function(n){return/maybe|probably/i.test(t.canPlayType(n))}):!1}(),Vhs.supportsNativeDash=function(){return!document$1$1||!document$1$1.createElement||!videojs.getTech("Html5").isSupported()?!1:/maybe|probably/i.test(document$1$1.createElement("video").canPlayType("application/dash+xml"))}(),Vhs.supportsTypeNatively=t=>t==="hls"?Vhs.supportsNativeHls:t==="dash"?Vhs.supportsNativeDash:!1,Vhs.isSupported=function(){return videojs.log.warn("VHS is no longer a tech. Please remove it from your player's techOrder.")},Vhs.xhr.onRequest=function(t){addOnRequestHook(Vhs.xhr,t)},Vhs.xhr.onResponse=function(t){addOnResponseHook(Vhs.xhr,t)},Vhs.xhr.offRequest=function(t){removeOnRequestHook(Vhs.xhr,t)},Vhs.xhr.offResponse=function(t){removeOnResponseHook(Vhs.xhr,t)};const Component=videojs.getComponent("Component");class VhsHandler extends Component{constructor(e,n,o){if(super(n,o.vhs),typeof o.initialBandwidth=="number"&&(this.options_.bandwidth=o.initialBandwidth),this.logger_=logger("VhsHandler"),n.options_&&n.options_.playerId){const u=videojs.getPlayer(n.options_.playerId);this.player_=u}if(this.tech_=n,this.source_=e,this.stats={},this.ignoreNextSeekingEvent_=!1,this.setOptions_(),this.options_.overrideNative&&n.overrideNativeAudioTracks&&n.overrideNativeVideoTracks)n.overrideNativeAudioTracks(!0),n.overrideNativeVideoTracks(!0);else if(this.options_.overrideNative&&(n.featuresNativeVideoTracks||n.featuresNativeAudioTracks))throw new Error("Overriding native VHS requires emulated tracks. See https://git.io/vMpjB");this.on(document$1$1,["fullscreenchange","webkitfullscreenchange","mozfullscreenchange","MSFullscreenChange"],u=>{const l=document$1$1.fullscreenElement||document$1$1.webkitFullscreenElement||document$1$1.mozFullScreenElement||document$1$1.msFullscreenElement;l&&l.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_=merge(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 o=getVhsLocalStorage();o&&o.bandwidth&&(this.options_.bandwidth=o.bandwidth,this.tech_.trigger({type:"usage",name:"vhs-bandwidth-from-local-storage"})),o&&o.throughput&&(this.options_.throughput=o.throughput,this.tech_.trigger({type:"usage",name:"vhs-throughput-from-local-storage"}))}typeof this.options_.bandwidth!="number"&&(this.options_.bandwidth=Config.INITIAL_BANDWIDTH),this.options_.enableLowInitialPlaylist=this.options_.enableLowInitialPlaylist&&this.options_.bandwidth===Config.INITIAL_BANDWIDTH,["withCredentials","useDevicePixelRatio","customPixelRatio","limitRenditionByPlayerDimensions","bandwidth","customTagParsers","customTagMappers","cacheEncryptionKeys","playlistSelector","initialPlaylistSelector","bufferBasedABR","liveRangeSafeTimeDelta","llhls","useForcedSubtitles","useNetworkInformationApi","useDtsForTimestampOffset","exactManifestTimings","leastPixelDiffSelector"].forEach(o=>{typeof this.source_[o]<"u"&&(this.options_[o]=this.source_[o])}),this.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions,this.useDevicePixelRatio=this.options_.useDevicePixelRatio;const n=this.options_.customPixelRatio;typeof n=="number"&&n>=0&&(this.customPixelRatio=n)}setOptions(e={}){this.setOptions_(e)}src(e,n){if(!e)return;this.setOptions_(),this.options_.src=expandDataUri(this.source_.src),this.options_.tech=this.tech_,this.options_.externVhs=Vhs,this.options_.sourceType=simpleTypeFromSourceType(n),this.options_.seekTo=l=>{this.tech_.setCurrentTime(l)},this.options_.player_=this.player_,this.playlistController_=new PlaylistController(this.options_);const o=merge({liveRangeSafeTimeDelta:SAFE_TIME_DELTA},this.options_,{seekable:()=>this.seekable(),media:()=>this.playlistController_.media(),playlistController:this.playlistController_});this.playbackWatcher_=new PlaybackWatcher(o),this.attachStreamingEventListeners_(),this.playlistController_.on("error",()=>{const l=videojs.players[this.tech_.options_.playerId];let m=this.playlistController_.error;typeof m=="object"&&!m.code?m.code=3:typeof m=="string"&&(m={message:m,code:3}),l.error(m)});const u=this.options_.bufferBasedABR?Vhs.movingAverageBandwidthSelector(.55):Vhs.STANDARD_PLAYLIST_SELECTOR;this.playlistController_.selectPlaylist=this.selectPlaylist?this.selectPlaylist.bind(this):u.bind(this),this.playlistController_.selectInitialPlaylist=Vhs.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(l){this.playlistController_.selectPlaylist=l.bind(this)}},throughput:{get(){return this.playlistController_.mainSegmentLoader_.throughput.rate},set(l){this.playlistController_.mainSegmentLoader_.throughput.rate=l,this.playlistController_.mainSegmentLoader_.throughput.count=1}},bandwidth:{get(){let l=this.playlistController_.mainSegmentLoader_.bandwidth;const m=window$1$1.navigator.connection||window$1$1.navigator.mozConnection||window$1$1.navigator.webkitConnection,y=1e7;if(this.options_.useNetworkInformationApi&&m){const E=m.downlink*1e3*1e3;E>=y&&l>=y?l=Math.max(l,E):l=E}return l},set(l){this.playlistController_.mainSegmentLoader_.bandwidth=l,this.playlistController_.mainSegmentLoader_.throughput={rate:0,count:0}}},systemBandwidth:{get(){const l=1/(this.bandwidth||1);let m;return this.throughput>0?m=1/this.throughput:m=0,Math.floor(1/(l+m))},set(){videojs.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:()=>timeRangesToArray(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:()=>timeRangesToArray(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&&updateVhsLocalStorage({bandwidth:this.bandwidth,throughput:Math.round(this.throughput)})}),this.playlistController_.on("selectedinitialmedia",()=>{renditionSelectionMixin(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_=window$1$1.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"),waitForKeySessionCreation({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(n=>{this.logger_("error while creating EME key session",n),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,n=setupEmeOptions({player:this.player_,sourceKeySystems:this.source_.keySystems,media:this.playlists.media(),audioMedia:e&&e.media()});if(this.player_.tech_.on("keystatuschange",o=>{this.playlistController_.updatePlaylistByKeyStatus(o.keyId,o.status)}),this.handleWaitingForKey_=this.handleWaitingForKey_.bind(this),this.player_.tech_.on("waitingforkey",this.handleWaitingForKey_),!n){this.playlistController_.sourceUpdater_.initializedEme();return}this.createKeySessions_()}setupQualityLevels_(){const e=videojs.players[this.tech_.options_.playerId];!e||!e.qualityLevels||this.qualityLevels_||(this.qualityLevels_=e.qualityLevels(),this.playlistController_.on("selectedinitialmedia",()=>{handleVhsLoadedMetadata(this.qualityLevels_,this)}),this.playlists.on("mediachange",()=>{handleVhsMediaChange(this.qualityLevels_,this.playlists)}))}static version(){return{"@videojs/http-streaming":version$4,"mux.js":version$3,"mpd-parser":version$2$1,"m3u8-parser":version$1$1,"aes-decrypter":version$7}}version(){return this.constructor.version()}canChangeType(){return SourceUpdater.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_&&window$1$1.URL.revokeObjectURL&&(window$1$1.URL.revokeObjectURL(this.mediaSourceUrl_),this.mediaSourceUrl_=null),this.tech_&&this.tech_.off("waitingforkey",this.handleWaitingForKey_),super.dispose()}convertToProgramTime(e,n){return getProgramTime({playlist:this.playlistController_.media(),time:e,callback:n})}seekToProgramTime(e,n,o=!0,u=2){return seekToProgramTime({programTime:e,playlist:this.playlistController_.media(),retryCount:u,pauseAfterSeek:o,seekTo:this.options_.seekTo,tech:this.options_.tech,callback:n})}setupXhrHooks_(){this.xhr.onRequest=e=>{addOnRequestHook(this.xhr,e)},this.xhr.onResponse=e=>{addOnResponseHook(this.xhr,e)},this.xhr.offRequest=e=>{removeOnRequestHook(this.xhr,e)},this.xhr.offResponse=e=>{removeOnResponseHook(this.xhr,e)},this.player_.trigger("xhr-hooks-ready")}attachStreamingEventListeners_(){const e=["seekablerangeschanged","bufferedrangeschanged","contentsteeringloadstart","contentsteeringloadcomplete","contentsteeringparsed"],n=["gapjumped","playedrangeschanged"];e.forEach(o=>{this.playlistController_.on(o,u=>{this.player_.trigger(_extends$2({},u))})}),n.forEach(o=>{this.playbackWatcher_.on(o,u=>{this.player_.trigger(_extends$2({},u))})})}}const VhsSourceHandler={name:"videojs-http-streaming",VERSION:version$4,canHandleSource(t,e={}){const n=merge(videojs.options,e);return!n.vhs.experimentalUseMMS&&!browserSupportsCodec("avc1.4d400d,mp4a.40.2",!1)?!1:VhsSourceHandler.canPlayType(t.type,n)},handleSource(t,e,n={}){const o=merge(videojs.options,n);return e.vhs=new VhsHandler(t,e,o),e.vhs.xhr=xhrFactory(),e.vhs.setupXhrHooks_(),e.vhs.src(t.src,t.type),e.vhs},canPlayType(t,e){const n=simpleTypeFromSourceType(t);if(!n)return"";const o=VhsSourceHandler.getOverrideNative(e);return!Vhs.supportsTypeNatively(n)||o?"maybe":""},getOverrideNative(t={}){const{vhs:e={}}=t,n=!(videojs.browser.IS_ANY_SAFARI||videojs.browser.IS_IOS),{overrideNative:o=n}=e;return o}},supportsNativeMediaSources=()=>browserSupportsCodec("avc1.4d400d,mp4a.40.2",!0);supportsNativeMediaSources()&&videojs.getTech("Html5").registerSourceHandler(VhsSourceHandler,0),videojs.VhsHandler=VhsHandler,videojs.VhsSourceHandler=VhsSourceHandler,videojs.Vhs=Vhs,videojs.use||videojs.registerComponent("Vhs",Vhs),videojs.options.vhs=videojs.options.vhs||{},(!videojs.getPlugin||!videojs.getPlugin("reloadSourceOnError"))&&videojs.registerPlugin("reloadSourceOnError",reloadSourceOnError);const video_es=Object.freeze(Object.defineProperty({__proto__:null,default:videojs},Symbol.toStringTag,{value:"Module"})),require$$0$5=getAugmentedNamespace(video_es);(function(t,e){(function(n,o){{var u=require$$0$5;t.exports=o(u.default||u)}})(commonjsGlobal$1,function(n){var o=n.browser.IS_IOS||n.browser.IS_NATIVE_ANDROID,u=n.getTech("Tech");class l extends u{constructor(k,A){super(k,A),this.setPoster(k.poster),this.setSrc(this.options_.source,!0),this.setTimeout((function(){this.el_&&(this.el_.parentNode.className+=" vjs-youtube",o&&(this.el_.parentNode.className+=" vjs-youtube-mobile"),l.isApiReady?this.initYTPlayer():l.apiReadyQueue.push(this))}).bind(this))}dispose(){if(this.ytPlayer)this.ytPlayer.stopVideo&&this.ytPlayer.stopVideo(),this.ytPlayer.destroy&&this.ytPlayer.destroy();else{var k=l.apiReadyQueue.indexOf(this);k!==-1&&l.apiReadyQueue.splice(k,1)}this.ytPlayer=null,this.el_.parentNode.className=this.el_.parentNode.className.replace(" vjs-youtube","").replace(" vjs-youtube-mobile",""),this.el_.parentNode.removeChild(this.el_),u.prototype.dispose.call(this)}createEl(){var k=document.createElement("div");k.setAttribute("id",this.options_.techId),k.setAttribute("style","width:100%;height:100%;top:0;left:0;position:absolute"),k.setAttribute("class","vjs-tech");var A=document.createElement("div");if(A.appendChild(k),!o&&!this.options_.ytControls){var D=document.createElement("div");D.setAttribute("class","vjs-iframe-blocker"),D.setAttribute("style","position:absolute;top:0;left:0;width:100%;height:100%"),D.onclick=(function(){this.pause()}).bind(this),A.appendChild(D)}return A}initYTPlayer(){var k={controls:0,modestbranding:1,rel:0,showinfo:0,loop:this.options_.loop?1:0};if(typeof this.options_.autohide<"u"&&(k.autohide=this.options_.autohide),typeof this.options_.cc_load_policy<"u"&&(k.cc_load_policy=this.options_.cc_load_policy),typeof this.options_.ytControls<"u"&&(k.controls=this.options_.ytControls),typeof this.options_.disablekb<"u"&&(k.disablekb=this.options_.disablekb),typeof this.options_.color<"u"&&(k.color=this.options_.color),k.controls?typeof this.options_.fs<"u"&&(k.fs=this.options_.fs):k.fs=0,this.options_.source.src.indexOf("end=")!==-1){var A=this.options_.source.src.match(/end=([0-9]*)/);this.options_.end=parseInt(A[1])}if(typeof this.options_.end<"u"&&(k.end=this.options_.end),typeof this.options_.hl<"u"?k.hl=this.options_.hl:typeof this.options_.language<"u"&&(k.hl=this.options_.language.substr(0,2)),typeof this.options_.iv_load_policy<"u"&&(k.iv_load_policy=this.options_.iv_load_policy),typeof this.options_.list<"u"?k.list=this.options_.list:this.url&&typeof this.url.listId<"u"&&(k.list=this.url.listId),typeof this.options_.listType<"u"&&(k.listType=this.options_.listType),typeof this.options_.modestbranding<"u"&&(k.modestbranding=this.options_.modestbranding),typeof this.options_.playlist<"u"&&(k.playlist=this.options_.playlist),typeof this.options_.playsinline<"u"&&(k.playsinline=this.options_.playsinline),typeof this.options_.rel<"u"&&(k.rel=this.options_.rel),typeof this.options_.showinfo<"u"&&(k.showinfo=this.options_.showinfo),this.options_.source.src.indexOf("start=")!==-1){var D=this.options_.source.src.match(/start=([0-9]*)/);this.options_.start=parseInt(D[1])}if(typeof this.options_.start<"u"&&(k.start=this.options_.start),typeof this.options_.theme<"u"&&(k.theme=this.options_.theme),typeof this.options_.customVars<"u"){var P=this.options_.customVars;Object.keys(P).forEach(function(B){k[B]=P[B]})}this.activeVideoId=this.url?this.url.videoId:null,this.activeList=k.list;var R={videoId:this.activeVideoId,playerVars:k,events:{onReady:this.onPlayerReady.bind(this),onPlaybackQualityChange:this.onPlayerPlaybackQualityChange.bind(this),onPlaybackRateChange:this.onPlayerPlaybackRateChange.bind(this),onStateChange:this.onPlayerStateChange.bind(this),onVolumeChange:this.onPlayerVolumeChange.bind(this),onError:this.onPlayerError.bind(this)}};typeof this.options_.enablePrivacyEnhancedMode<"u"&&this.options_.enablePrivacyEnhancedMode&&(R.host="https://www.youtube-nocookie.com"),this.ytPlayer=new YT.Player(this.options_.techId,R)}onPlayerReady(){this.options_.muted&&this.ytPlayer.mute();var k=this.ytPlayer.getAvailablePlaybackRates();k.length>1&&(this.featuresPlaybackRate=!0),this.playerReady_=!0,this.triggerReady(),this.playOnReady?this.play():this.cueOnReady&&(this.cueVideoById_(this.url.videoId),this.activeVideoId=this.url.videoId)}onPlayerPlaybackQualityChange(){}onPlayerPlaybackRateChange(){this.trigger("ratechange")}onPlayerStateChange(k){var A=k.data;if(!(A===this.lastState||this.errorNumber))switch(this.lastState=A,A){case-1:this.trigger("loadstart"),this.trigger("loadedmetadata"),this.trigger("durationchange"),this.trigger("ratechange");break;case YT.PlayerState.ENDED:this.trigger("ended");break;case YT.PlayerState.PLAYING:this.trigger("timeupdate"),this.trigger("durationchange"),this.trigger("playing"),this.trigger("play"),this.isSeeking&&this.onSeeked();break;case YT.PlayerState.PAUSED:this.trigger("canplay"),this.isSeeking?this.onSeeked():this.trigger("pause");break;case YT.PlayerState.BUFFERING:this.player_.trigger("timeupdate"),this.player_.trigger("waiting");break}}onPlayerVolumeChange(){this.trigger("volumechange")}onPlayerError(k){this.errorNumber=k.data,this.trigger("pause"),this.trigger("error")}error(){var k=1e3+this.errorNumber;switch(this.errorNumber){case 5:return{code:k,message:"Error while trying to play the video"};case 2:case 100:return{code:k,message:"Unable to find the video"};case 101:case 150:return{code:k,message:"Playback on other Websites has been disabled by the video owner."}}return{code:k,message:"YouTube unknown error ("+this.errorNumber+")"}}loadVideoById_(k){var A={videoId:k};this.options_.start&&(A.startSeconds=this.options_.start),this.options_.end&&(A.endSeconds=this.options_.end),this.ytPlayer.loadVideoById(A)}cueVideoById_(k){var A={videoId:k};this.options_.start&&(A.startSeconds=this.options_.start),this.options_.end&&(A.endSeconds=this.options_.end),this.ytPlayer.cueVideoById(A)}src(k){return k&&this.setSrc({src:k}),this.source}poster(){return o?null:this.poster_}setPoster(k){this.poster_=k}setSrc(k){!k||!k.src||(delete this.errorNumber,this.source=k,this.url=l.parseUrl(k.src),this.options_.poster||this.url.videoId&&(this.poster_="https://img.youtube.com/vi/"+this.url.videoId+"/0.jpg",this.trigger("posterchange"),this.checkHighResPoster()),this.options_.autoplay&&!o?this.isReady_?this.play():this.playOnReady=!0:this.activeVideoId!==this.url.videoId&&(this.isReady_?(this.cueVideoById_(this.url.videoId),this.activeVideoId=this.url.videoId):this.cueOnReady=!0))}autoplay(){return this.options_.autoplay}setAutoplay(k){this.options_.autoplay=k}loop(){return this.options_.loop}setLoop(k){this.options_.loop=k}play(){!this.url||!this.url.videoId||(this.wasPausedBeforeSeek=!1,this.isReady_?(this.url.listId&&(this.activeList===this.url.listId?this.ytPlayer.playVideo():(this.ytPlayer.loadPlaylist(this.url.listId),this.activeList=this.url.listId)),this.activeVideoId===this.url.videoId?this.ytPlayer.playVideo():(this.loadVideoById_(this.url.videoId),this.activeVideoId=this.url.videoId)):(this.trigger("waiting"),this.playOnReady=!0))}pause(){this.ytPlayer&&this.ytPlayer.pauseVideo()}paused(){return this.ytPlayer?this.lastState!==YT.PlayerState.PLAYING&&this.lastState!==YT.PlayerState.BUFFERING:!0}currentTime(){return this.ytPlayer?this.ytPlayer.getCurrentTime():0}setCurrentTime(k){this.lastState===YT.PlayerState.PAUSED&&(this.timeBeforeSeek=this.currentTime()),this.isSeeking||(this.wasPausedBeforeSeek=this.paused()),this.ytPlayer.seekTo(k,!0),this.trigger("timeupdate"),this.trigger("seeking"),this.isSeeking=!0,this.lastState===YT.PlayerState.PAUSED&&this.timeBeforeSeek!==k&&(clearInterval(this.checkSeekedInPauseInterval),this.checkSeekedInPauseInterval=setInterval((function(){this.lastState!==YT.PlayerState.PAUSED||!this.isSeeking?clearInterval(this.checkSeekedInPauseInterval):this.currentTime()!==this.timeBeforeSeek&&(this.trigger("timeupdate"),this.onSeeked())}).bind(this),250))}seeking(){return this.isSeeking}seekable(){return this.ytPlayer?n.createTimeRange(0,this.ytPlayer.getDuration()):n.createTimeRange()}onSeeked(){clearInterval(this.checkSeekedInPauseInterval),this.isSeeking=!1,this.wasPausedBeforeSeek&&this.pause(),this.trigger("seeked")}playbackRate(){return this.ytPlayer?this.ytPlayer.getPlaybackRate():1}setPlaybackRate(k){this.ytPlayer&&this.ytPlayer.setPlaybackRate(k)}duration(){return this.ytPlayer?this.ytPlayer.getDuration():0}currentSrc(){return this.source&&this.source.src}ended(){return this.ytPlayer?this.lastState===YT.PlayerState.ENDED:!1}volume(){return this.ytPlayer?this.ytPlayer.getVolume()/100:1}setVolume(k){this.ytPlayer&&this.ytPlayer.setVolume(k*100)}muted(){return this.ytPlayer?this.ytPlayer.isMuted():!1}setMuted(k){if(this.ytPlayer)this.muted(!0);else return;k?this.ytPlayer.mute():this.ytPlayer.unMute(),this.setTimeout(function(){this.trigger("volumechange")},50)}buffered(){if(!this.ytPlayer||!this.ytPlayer.getVideoLoadedFraction)return n.createTimeRange();var k=this.ytPlayer.getVideoLoadedFraction()*this.ytPlayer.getDuration();return n.createTimeRange(0,k)}preload(){}load(){}reset(){}networkState(){if(!this.ytPlayer)return 0;switch(this.ytPlayer.getPlayerState()){case-1:return 0;case 3:return 2;default:return 1}}readyState(){if(!this.ytPlayer)return 0;switch(this.ytPlayer.getPlayerState()){case-1:return 0;case 5:return 1;case 3:return 2;default:return 4}}supportsFullScreen(){return document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled}checkHighResPoster(){var k="https://img.youtube.com/vi/"+this.url.videoId+"/maxresdefault.jpg";try{var A=new Image;A.onload=(function(){if("naturalHeight"in A){if(A.naturalHeight<=90||A.naturalWidth<=120)return}else if(A.height<=90||A.width<=120)return;this.poster_=k,this.trigger("posterchange")}).bind(this),A.onerror=function(){},A.src=k}catch{}}}l.isSupported=function(){return!0},l.canPlaySource=function(C){return l.canPlayType(C.type)},l.canPlayType=function(C){return C==="video/youtube"},l.parseUrl=function(C){var k={videoId:null},A=/^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|\&v=)([^#\&\?]*).*/,D=C.match(A);D&&D[2].length===11&&(k.videoId=D[2]);var P=/[?&]list=([^#\&\?]+)/;return D=C.match(P),D&&D[1]&&(k.listId=D[1]),k};function m(){YT.ready(function(){l.isApiReady=!0;for(var C=0;C<l.apiReadyQueue.length;++C)l.apiReadyQueue[C].initYTPlayer()})}function y(C,k){var A=!1,D=document.createElement("script"),P=document.getElementsByTagName("script")[0];P&&(P.parentNode.insertBefore(D,P),D.onload=function(){A||(A=!0,k())},D.onreadystatechange=function(){!A&&(this.readyState==="complete"||this.readyState==="loaded")&&(A=!0,k())},D.src=C)}function E(){var C=".vjs-youtube .vjs-iframe-blocker { display: none; }.vjs-youtube.vjs-user-inactive .vjs-iframe-blocker { display: block; }.vjs-youtube .vjs-poster { background-size: cover; }.vjs-youtube-mobile .vjs-big-play-button { display: none; }",k=document.head||document.getElementsByTagName("head")[0],A=document.createElement("style");A.type="text/css",A.styleSheet?A.styleSheet.cssText=C:A.appendChild(document.createTextNode(C)),k.appendChild(A)}l.apiReadyQueue=[],typeof document<"u"&&(y("https://www.youtube.com/iframe_api",m),E()),typeof n.registerTech<"u"?n.registerTech("Youtube",l):n.registerComponent("Youtube",l)})})(Youtube);/*! @vimeo/player v2.24.0 | (c) 2024 Vimeo | MIT License | https://github.com/vimeo/player.js */function ownKeys(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter(function(u){return Object.getOwnPropertyDescriptor(t,u).enumerable})),n.push.apply(n,o)}return n}function _objectSpread2(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?ownKeys(Object(n),!0).forEach(function(o){_defineProperty(t,o,n[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ownKeys(Object(n)).forEach(function(o){Object.defineProperty(t,o,Object.getOwnPropertyDescriptor(n,o))})}return t}function _regeneratorRuntime(){_regeneratorRuntime=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,o=Object.defineProperty||function(d,v,w){d[v]=w.value},u=typeof Symbol=="function"?Symbol:{},l=u.iterator||"@@iterator",m=u.asyncIterator||"@@asyncIterator",y=u.toStringTag||"@@toStringTag";function E(d,v,w){return Object.defineProperty(d,v,{value:w,enumerable:!0,configurable:!0,writable:!0}),d[v]}try{E({},"")}catch{E=function(v,w,c){return v[w]=c}}function C(d,v,w,c){var p=v&&v.prototype instanceof D?v:D,x=Object.create(p.prototype),S=new he(c||[]);return o(x,"_invoke",{value:ie(d,w,S)}),x}function k(d,v,w){try{return{type:"normal",arg:d.call(v,w)}}catch(c){return{type:"throw",arg:c}}}t.wrap=C;var A={};function D(){}function P(){}function R(){}var B={};E(B,l,function(){return this});var F=Object.getPrototypeOf,j=F&&F(F(ke([])));j&&j!==e&&n.call(j,l)&&(B=j);var N=R.prototype=D.prototype=Object.create(B);function Y(d){["next","throw","return"].forEach(function(v){E(d,v,function(w){return this._invoke(v,w)})})}function J(d,v){function w(p,x,S,b){var h=k(d[p],d,x);if(h.type!=="throw"){var T=h.arg,M=T.value;return M&&typeof M=="object"&&n.call(M,"__await")?v.resolve(M.__await).then(function(O){w("next",O,S,b)},function(O){w("throw",O,S,b)}):v.resolve(M).then(function(O){T.value=O,S(T)},function(O){return w("throw",O,S,b)})}b(h.arg)}var c;o(this,"_invoke",{value:function(p,x){function S(){return new v(function(b,h){w(p,x,b,h)})}return c=c?c.then(S,S):S()}})}function ie(d,v,w){var c="suspendedStart";return function(p,x){if(c==="executing")throw new Error("Generator is already running");if(c==="completed"){if(p==="throw")throw x;return L()}for(w.method=p,w.arg=x;;){var S=w.delegate;if(S){var b=ue(S,w);if(b){if(b===A)continue;return b}}if(w.method==="next")w.sent=w._sent=w.arg;else if(w.method==="throw"){if(c==="suspendedStart")throw c="completed",w.arg;w.dispatchException(w.arg)}else w.method==="return"&&w.abrupt("return",w.arg);c="executing";var h=k(d,v,w);if(h.type==="normal"){if(c=w.done?"completed":"suspendedYield",h.arg===A)continue;return{value:h.arg,done:w.done}}h.type==="throw"&&(c="completed",w.method="throw",w.arg=h.arg)}}}function ue(d,v){var w=v.method,c=d.iterator[w];if(c===void 0)return v.delegate=null,w==="throw"&&d.iterator.return&&(v.method="return",v.arg=void 0,ue(d,v),v.method==="throw")||w!=="return"&&(v.method="throw",v.arg=new TypeError("The iterator does not provide a '"+w+"' method")),A;var p=k(c,d.iterator,v.arg);if(p.type==="throw")return v.method="throw",v.arg=p.arg,v.delegate=null,A;var x=p.arg;return x?x.done?(v[d.resultName]=x.value,v.next=d.nextLoc,v.method!=="return"&&(v.method="next",v.arg=void 0),v.delegate=null,A):x:(v.method="throw",v.arg=new TypeError("iterator result is not an object"),v.delegate=null,A)}function Q(d){var v={tryLoc:d[0]};1 in d&&(v.catchLoc=d[1]),2 in d&&(v.finallyLoc=d[2],v.afterLoc=d[3]),this.tryEntries.push(v)}function ce(d){var v=d.completion||{};v.type="normal",delete v.arg,d.completion=v}function he(d){this.tryEntries=[{tryLoc:"root"}],d.forEach(Q,this),this.reset(!0)}function ke(d){if(d){var v=d[l];if(v)return v.call(d);if(typeof d.next=="function")return d;if(!isNaN(d.length)){var w=-1,c=function p(){for(;++w<d.length;)if(n.call(d,w))return p.value=d[w],p.done=!1,p;return p.value=void 0,p.done=!0,p};return c.next=c}}return{next:L}}function L(){return{value:void 0,done:!0}}return P.prototype=R,o(N,"constructor",{value:R,configurable:!0}),o(R,"constructor",{value:P,configurable:!0}),P.displayName=E(R,y,"GeneratorFunction"),t.isGeneratorFunction=function(d){var v=typeof d=="function"&&d.constructor;return!!v&&(v===P||(v.displayName||v.name)==="GeneratorFunction")},t.mark=function(d){return Object.setPrototypeOf?Object.setPrototypeOf(d,R):(d.__proto__=R,E(d,y,"GeneratorFunction")),d.prototype=Object.create(N),d},t.awrap=function(d){return{__await:d}},Y(J.prototype),E(J.prototype,m,function(){return this}),t.AsyncIterator=J,t.async=function(d,v,w,c,p){p===void 0&&(p=Promise);var x=new J(C(d,v,w,c),p);return t.isGeneratorFunction(v)?x:x.next().then(function(S){return S.done?S.value:x.next()})},Y(N),E(N,y,"Generator"),E(N,l,function(){return this}),E(N,"toString",function(){return"[object Generator]"}),t.keys=function(d){var v=Object(d),w=[];for(var c in v)w.push(c);return w.reverse(),function p(){for(;w.length;){var x=w.pop();if(x in v)return p.value=x,p.done=!1,p}return p.done=!0,p}},t.values=ke,he.prototype={constructor:he,reset:function(d){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(ce),!d)for(var v in this)v.charAt(0)==="t"&&n.call(this,v)&&!isNaN(+v.slice(1))&&(this[v]=void 0)},stop:function(){this.done=!0;var d=this.tryEntries[0].completion;if(d.type==="throw")throw d.arg;return this.rval},dispatchException:function(d){if(this.done)throw d;var v=this;function w(h,T){return x.type="throw",x.arg=d,v.next=h,T&&(v.method="next",v.arg=void 0),!!T}for(var c=this.tryEntries.length-1;c>=0;--c){var p=this.tryEntries[c],x=p.completion;if(p.tryLoc==="root")return w("end");if(p.tryLoc<=this.prev){var S=n.call(p,"catchLoc"),b=n.call(p,"finallyLoc");if(S&&b){if(this.prev<p.catchLoc)return w(p.catchLoc,!0);if(this.prev<p.finallyLoc)return w(p.finallyLoc)}else if(S){if(this.prev<p.catchLoc)return w(p.catchLoc,!0)}else{if(!b)throw new Error("try statement without catch or finally");if(this.prev<p.finallyLoc)return w(p.finallyLoc)}}}},abrupt:function(d,v){for(var w=this.tryEntries.length-1;w>=0;--w){var c=this.tryEntries[w];if(c.tryLoc<=this.prev&&n.call(c,"finallyLoc")&&this.prev<c.finallyLoc){var p=c;break}}p&&(d==="break"||d==="continue")&&p.tryLoc<=v&&v<=p.finallyLoc&&(p=null);var x=p?p.completion:{};return x.type=d,x.arg=v,p?(this.method="next",this.next=p.finallyLoc,A):this.complete(x)},complete:function(d,v){if(d.type==="throw")throw d.arg;return d.type==="break"||d.type==="continue"?this.next=d.arg:d.type==="return"?(this.rval=this.arg=d.arg,this.method="return",this.next="end"):d.type==="normal"&&v&&(this.next=v),A},finish:function(d){for(var v=this.tryEntries.length-1;v>=0;--v){var w=this.tryEntries[v];if(w.finallyLoc===d)return this.complete(w.completion,w.afterLoc),ce(w),A}},catch:function(d){for(var v=this.tryEntries.length-1;v>=0;--v){var w=this.tryEntries[v];if(w.tryLoc===d){var c=w.completion;if(c.type==="throw"){var p=c.arg;ce(w)}return p}}throw new Error("illegal catch attempt")},delegateYield:function(d,v,w){return this.delegate={iterator:ke(d),resultName:v,nextLoc:w},this.method==="next"&&(this.arg=void 0),A}},t}function asyncGeneratorStep(t,e,n,o,u,l,m){try{var y=t[l](m),E=y.value}catch(C){n(C);return}y.done?e(E):Promise.resolve(E).then(o,u)}function _asyncToGenerator(t){return function(){var e=this,n=arguments;return new Promise(function(o,u){var l=t.apply(e,n);function m(E){asyncGeneratorStep(l,o,u,m,y,"next",E)}function y(E){asyncGeneratorStep(l,o,u,m,y,"throw",E)}m(void 0)})}}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _defineProperties(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,_toPropertyKey(o.key),o)}}function _createClass(t,e,n){return e&&_defineProperties(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function _defineProperty(t,e,n){return e=_toPropertyKey(e),e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function _inherits(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_setPrototypeOf(t,e)}function _getPrototypeOf(t){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},_getPrototypeOf(t)}function _setPrototypeOf(t,e){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(o,u){return o.__proto__=u,o},_setPrototypeOf(t,e)}function _isNativeReflectConstruct(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function _construct(t,e,n){return _isNativeReflectConstruct()?_construct=Reflect.construct.bind():_construct=function(u,l,m){var y=[null];y.push.apply(y,l);var E=Function.bind.apply(u,y),C=new E;return m&&_setPrototypeOf(C,m.prototype),C},_construct.apply(null,arguments)}function _isNativeFunction(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function _wrapNativeSuper(t){var e=typeof Map=="function"?new Map:void 0;return _wrapNativeSuper=function(o){if(o===null||!_isNativeFunction(o))return o;if(typeof o!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e<"u"){if(e.has(o))return e.get(o);e.set(o,u)}function u(){return _construct(o,arguments,_getPrototypeOf(this).constructor)}return u.prototype=Object.create(o.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),_setPrototypeOf(u,o)},_wrapNativeSuper(t)}function _assertThisInitialized(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _possibleConstructorReturn(t,e){if(e&&(typeof e=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(t)}function _createSuper(t){var e=_isNativeReflectConstruct();return function(){var o=_getPrototypeOf(t),u;if(e){var l=_getPrototypeOf(this).constructor;u=Reflect.construct(o,arguments,l)}else u=o.apply(this,arguments);return _possibleConstructorReturn(this,u)}}function _toPrimitive(t,e){if(typeof t!="object"||t===null)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var o=n.call(t,e);if(typeof o!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}function _toPropertyKey(t){var e=_toPrimitive(t,"string");return typeof e=="symbol"?e:String(e)}var isNode=typeof global$1<"u"&&{}.toString.call(global$1)==="[object global]";function getMethodName(t,e){return t.indexOf(e.toLowerCase())===0?t:"".concat(e.toLowerCase()).concat(t.substr(0,1).toUpperCase()).concat(t.substr(1))}function isDomElement(t){return!!(t&&t.nodeType===1&&"nodeName"in t&&t.ownerDocument&&t.ownerDocument.defaultView)}function isInteger(t){return!isNaN(parseFloat(t))&&isFinite(t)&&Math.floor(t)==t}function isVimeoUrl(t){return/^(https?:)?\/\/((((player|www)\.)?vimeo\.com)|((player\.)?[a-zA-Z0-9-]+\.(videoji\.(hk|cn)|vimeo\.work)))(?=$|\/)/.test(t)}function isVimeoEmbed(t){var e=/^https:\/\/player\.((vimeo\.com)|([a-zA-Z0-9-]+\.(videoji\.(hk|cn)|vimeo\.work)))\/video\/\d+/;return e.test(t)}function getOembedDomain(t){for(var e=(t||"").match(/^(?:https?:)?(?:\/\/)?([^/?]+)/),n=(e&&e[1]||"").replace("player.",""),o=[".videoji.hk",".vimeo.work",".videoji.cn"],u=0,l=o;u<l.length;u++){var m=l[u];if(n.endsWith(m))return n}return"vimeo.com"}function getVimeoUrl(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=t.id,n=t.url,o=e||n;if(!o)throw new Error("An id or url must be passed, either in an options object or as a data-vimeo-id or data-vimeo-url attribute.");if(isInteger(o))return"https://vimeo.com/".concat(o);if(isVimeoUrl(o))return o.replace("http:","https:");throw e?new TypeError("“".concat(e,"” is not a valid video id.")):new TypeError("“".concat(o,"” is not a vimeo.com url."))}var subscribe=function(e,n,o){var u=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"addEventListener",l=arguments.length>4&&arguments[4]!==void 0?arguments[4]:"removeEventListener",m=typeof n=="string"?[n]:n;return m.forEach(function(y){e[u](y,o)}),{cancel:function(){return m.forEach(function(E){return e[l](E,o)})}}},arrayIndexOfSupport=typeof Array.prototype.indexOf<"u",postMessageSupport=typeof window<"u"&&typeof window.postMessage<"u";if(!isNode&&(!arrayIndexOfSupport||!postMessageSupport))throw new Error("Sorry, the Vimeo Player API is not available in this browser.");var commonjsGlobal=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global$1<"u"?global$1:typeof self<"u"?self:{};function createCommonjsModule(t,e){return e={exports:{}},t(e,e.exports),e.exports}/*!
 * weakmap-polyfill v2.0.4 - ECMAScript6 WeakMap polyfill
 * https://github.com/polygonplanet/weakmap-polyfill
 * Copyright (c) 2015-2021 polygonplanet <polygon.planet.aqua@gmail.com>
 * @license MIT
 */(function(t){if(t.WeakMap)return;var e=Object.prototype.hasOwnProperty,n=Object.defineProperty&&function(){try{return Object.defineProperty({},"x",{value:1}).x===1}catch{}}(),o=function(l,m,y){n?Object.defineProperty(l,m,{configurable:!0,writable:!0,value:y}):l[m]=y};t.WeakMap=function(){function l(){if(this===void 0)throw new TypeError("Constructor WeakMap requires 'new'");if(o(this,"_id",y("_WeakMap")),arguments.length>0)throw new TypeError("WeakMap iterable is not supported")}o(l.prototype,"delete",function(C){if(m(this,"delete"),!u(C))return!1;var k=C[this._id];return k&&k[0]===C?(delete C[this._id],!0):!1}),o(l.prototype,"get",function(C){if(m(this,"get"),!!u(C)){var k=C[this._id];if(k&&k[0]===C)return k[1]}}),o(l.prototype,"has",function(C){if(m(this,"has"),!u(C))return!1;var k=C[this._id];return!!(k&&k[0]===C)}),o(l.prototype,"set",function(C,k){if(m(this,"set"),!u(C))throw new TypeError("Invalid value used as weak map key");var A=C[this._id];return A&&A[0]===C?(A[1]=k,this):(o(C,this._id,[C,k]),this)});function m(C,k){if(!u(C)||!e.call(C,"_id"))throw new TypeError(k+" method called on incompatible receiver "+typeof C)}function y(C){return C+"_"+E()+"."+E()}function E(){return Math.random().toString().substring(2)}return o(l,"_polyfill",!0),l}();function u(l){return Object(l)===l}})(typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:commonjsGlobal);var npo_src=createCommonjsModule(function(t){/*! Native Promise Only
    v0.8.1 (c) Kyle Simpson
    MIT License: http://getify.mit-license.org
*/(function(n,o,u){o[n]=o[n]||u(),t.exports&&(t.exports=o[n])})("Promise",commonjsGlobal,function(){var n,o,u,l=Object.prototype.toString,m=typeof setImmediate<"u"?function(Y){return setImmediate(Y)}:setTimeout;try{Object.defineProperty({},"x",{}),n=function(Y,J,ie,ue){return Object.defineProperty(Y,J,{value:ie,writable:!0,configurable:ue!==!1})}}catch{n=function(J,ie,ue){return J[ie]=ue,J}}u=function(){var Y,J,ie;function ue(Q,ce){this.fn=Q,this.self=ce,this.next=void 0}return{add:function(ce,he){ie=new ue(ce,he),J?J.next=ie:Y=ie,J=ie,ie=void 0},drain:function(){var ce=Y;for(Y=J=o=void 0;ce;)ce.fn.call(ce.self),ce=ce.next}}}();function y(N,Y){u.add(N,Y),o||(o=m(u.drain))}function E(N){var Y,J=typeof N;return N!=null&&(J=="object"||J=="function")&&(Y=N.then),typeof Y=="function"?Y:!1}function C(){for(var N=0;N<this.chain.length;N++)k(this,this.state===1?this.chain[N].success:this.chain[N].failure,this.chain[N]);this.chain.length=0}function k(N,Y,J){var ie,ue;try{Y===!1?J.reject(N.msg):(Y===!0?ie=N.msg:ie=Y.call(void 0,N.msg),ie===J.promise?J.reject(TypeError("Promise-chain cycle")):(ue=E(ie))?ue.call(ie,J.resolve,J.reject):J.resolve(ie))}catch(Q){J.reject(Q)}}function A(N){var Y,J=this;if(!J.triggered){J.triggered=!0,J.def&&(J=J.def);try{(Y=E(N))?y(function(){var ie=new R(J);try{Y.call(N,function(){A.apply(ie,arguments)},function(){D.apply(ie,arguments)})}catch(ue){D.call(ie,ue)}}):(J.msg=N,J.state=1,J.chain.length>0&&y(C,J))}catch(ie){D.call(new R(J),ie)}}}function D(N){var Y=this;Y.triggered||(Y.triggered=!0,Y.def&&(Y=Y.def),Y.msg=N,Y.state=2,Y.chain.length>0&&y(C,Y))}function P(N,Y,J,ie){for(var ue=0;ue<Y.length;ue++)(function(ce){N.resolve(Y[ce]).then(function(ke){J(ce,ke)},ie)})(ue)}function R(N){this.def=N,this.triggered=!1}function B(N){this.promise=N,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function F(N){if(typeof N!="function")throw TypeError("Not a function");if(this.__NPO__!==0)throw TypeError("Not a promise");this.__NPO__=1;var Y=new B(this);this.then=function(ie,ue){var Q={success:typeof ie=="function"?ie:!0,failure:typeof ue=="function"?ue:!1};return Q.promise=new this.constructor(function(he,ke){if(typeof he!="function"||typeof ke!="function")throw TypeError("Not a function");Q.resolve=he,Q.reject=ke}),Y.chain.push(Q),Y.state!==0&&y(C,Y),Q.promise},this.catch=function(ie){return this.then(void 0,ie)};try{N.call(void 0,function(ie){A.call(Y,ie)},function(ie){D.call(Y,ie)})}catch(J){D.call(Y,J)}}var j=n({},"constructor",F,!1);return F.prototype=j,n(j,"__NPO__",0,!1),n(F,"resolve",function(Y){var J=this;return Y&&typeof Y=="object"&&Y.__NPO__===1?Y:new J(function(ue,Q){if(typeof ue!="function"||typeof Q!="function")throw TypeError("Not a function");ue(Y)})}),n(F,"reject",function(Y){return new this(function(ie,ue){if(typeof ie!="function"||typeof ue!="function")throw TypeError("Not a function");ue(Y)})}),n(F,"all",function(Y){var J=this;return l.call(Y)!="[object Array]"?J.reject(TypeError("Not an array")):Y.length===0?J.resolve([]):new J(function(ue,Q){if(typeof ue!="function"||typeof Q!="function")throw TypeError("Not a function");var ce=Y.length,he=Array(ce),ke=0;P(J,Y,function(d,v){he[d]=v,++ke===ce&&ue(he)},Q)})}),n(F,"race",function(Y){var J=this;return l.call(Y)!="[object Array]"?J.reject(TypeError("Not an array")):new J(function(ue,Q){if(typeof ue!="function"||typeof Q!="function")throw TypeError("Not a function");P(J,Y,function(he,ke){ue(ke)},Q)})}),F})}),callbackMap=new WeakMap;function storeCallback(t,e,n){var o=callbackMap.get(t.element)||{};e in o||(o[e]=[]),o[e].push(n),callbackMap.set(t.element,o)}function getCallbacks(t,e){var n=callbackMap.get(t.element)||{};return n[e]||[]}function removeCallback(t,e,n){var o=callbackMap.get(t.element)||{};if(!o[e])return!0;if(!n)return o[e]=[],callbackMap.set(t.element,o),!0;var u=o[e].indexOf(n);return u!==-1&&o[e].splice(u,1),callbackMap.set(t.element,o),o[e]&&o[e].length===0}function shiftCallbacks(t,e){var n=getCallbacks(t,e);if(n.length<1)return!1;var o=n.shift();return removeCallback(t,e,o),o}function swapCallbacks(t,e){var n=callbackMap.get(t);callbackMap.set(e,n),callbackMap.delete(t)}function parseMessageData(t){if(typeof t=="string")try{t=JSON.parse(t)}catch(e){return console.warn(e),{}}return t}function postMessage(t,e,n){if(!(!t.element.contentWindow||!t.element.contentWindow.postMessage)){var o={method:e};n!==void 0&&(o.value=n);var u=parseFloat(navigator.userAgent.toLowerCase().replace(/^.*msie (\d+).*$/,"$1"));u>=8&&u<10&&(o=JSON.stringify(o)),t.element.contentWindow.postMessage(o,t.origin)}}function processData(t,e){e=parseMessageData(e);var n=[],o;if(e.event){if(e.event==="error"){var u=getCallbacks(t,e.data.method);u.forEach(function(m){var y=new Error(e.data.message);y.name=e.data.name,m.reject(y),removeCallback(t,e.data.method,m)})}n=getCallbacks(t,"event:".concat(e.event)),o=e.data}else if(e.method){var l=shiftCallbacks(t,e.method);l&&(n.push(l),o=e.value)}n.forEach(function(m){try{if(typeof m=="function"){m.call(t,o);return}m.resolve(o)}catch{}})}var oEmbedParameters=["airplay","audio_tracks","autopause","autoplay","background","byline","cc","chapter_id","chapters","chromecast","color","colors","controls","dnt","end_time","fullscreen","height","id","interactive_params","keyboard","loop","maxheight","maxwidth","muted","play_button_position","playsinline","portrait","progress_bar","quality_selector","responsive","speed","start_time","texttrack","title","transcript","transparent","unmute_button","url","vimeo_logo","volume","watch_full_video","width"];function getOEmbedParameters(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return oEmbedParameters.reduce(function(n,o){var u=t.getAttribute("data-vimeo-".concat(o));return(u||u==="")&&(n[o]=u===""?1:u),n},e)}function createEmbed(t,e){var n=t.html;if(!e)throw new TypeError("An element must be provided");if(e.getAttribute("data-vimeo-initialized")!==null)return e.querySelector("iframe");var o=document.createElement("div");return o.innerHTML=n,e.appendChild(o.firstChild),e.setAttribute("data-vimeo-initialized","true"),e.querySelector("iframe")}function getOEmbedData(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;return new Promise(function(o,u){if(!isVimeoUrl(t))throw new TypeError("“".concat(t,"” is not a vimeo.com url."));var l=getOembedDomain(t),m="https://".concat(l,"/api/oembed.json?url=").concat(encodeURIComponent(t));for(var y in e)e.hasOwnProperty(y)&&(m+="&".concat(y,"=").concat(encodeURIComponent(e[y])));var E="XDomainRequest"in window?new XDomainRequest:new XMLHttpRequest;E.open("GET",m,!0),E.onload=function(){if(E.status===404){u(new Error("“".concat(t,"” was not found.")));return}if(E.status===403){u(new Error("“".concat(t,"” is not embeddable.")));return}try{var C=JSON.parse(E.responseText);if(C.domain_status_code===403){createEmbed(C,n),u(new Error("“".concat(t,"” is not embeddable.")));return}o(C)}catch(k){u(k)}},E.onerror=function(){var C=E.status?" (".concat(E.status,")"):"";u(new Error("There was an error fetching the embed code from Vimeo".concat(C,".")))},E.send()})}function initializeEmbeds(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:document,e=[].slice.call(t.querySelectorAll("[data-vimeo-id], [data-vimeo-url]")),n=function(u){"console"in window&&console.error&&console.error("There was an error creating an embed: ".concat(u))};e.forEach(function(o){try{if(o.getAttribute("data-vimeo-defer")!==null)return;var u=getOEmbedParameters(o),l=getVimeoUrl(u);getOEmbedData(l,u,o).then(function(m){return createEmbed(m,o)}).catch(n)}catch(m){n(m)}})}function resizeEmbeds(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:document;if(!window.VimeoPlayerResizeEmbeds_){window.VimeoPlayerResizeEmbeds_=!0;var e=function(o){if(isVimeoUrl(o.origin)&&!(!o.data||o.data.event!=="spacechange")){for(var u=t.querySelectorAll("iframe"),l=0;l<u.length;l++)if(u[l].contentWindow===o.source){var m=u[l].parentElement;m.style.paddingBottom="".concat(o.data.data[0].bottom,"px");break}}};window.addEventListener("message",e)}}function initAppendVideoMetadata(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:document;if(!window.VimeoSeoMetadataAppended){window.VimeoSeoMetadataAppended=!0;var e=function(o){if(isVimeoUrl(o.origin)){var u=parseMessageData(o.data);if(!(!u||u.event!=="ready"))for(var l=t.querySelectorAll("iframe"),m=0;m<l.length;m++){var y=l[m],E=y.contentWindow===o.source;if(isVimeoEmbed(y.src)&&E){var C=new Player(y);C.callMethod("appendVideoMetadata",window.location.href)}}}};window.addEventListener("message",e)}}function checkUrlTimeParam(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:document;if(!window.VimeoCheckedUrlTimeParam){window.VimeoCheckedUrlTimeParam=!0;var e=function(u){"console"in window&&console.error&&console.error("There was an error getting video Id: ".concat(u))},n=function(u){if(isVimeoUrl(u.origin)){var l=parseMessageData(u.data);if(!(!l||l.event!=="ready"))for(var m=t.querySelectorAll("iframe"),y=function(){var k=m[E],A=k.contentWindow===u.source;if(isVimeoEmbed(k.src)&&A){var D=new Player(k);D.getVideoId().then(function(P){var R=new RegExp("[?&]vimeo_t_".concat(P,"=([^&#]*)")).exec(window.location.href);if(R&&R[1]){var B=decodeURI(R[1]);D.setCurrentTime(B)}}).catch(e)}},E=0;E<m.length;E++)y()}};window.addEventListener("message",n)}}function initializeScreenfull(){var t=function(){for(var o,u=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],l=0,m=u.length,y={};l<m;l++)if(o=u[l],o&&o[1]in document){for(l=0;l<o.length;l++)y[u[0][l]]=o[l];return y}return!1}(),e={fullscreenchange:t.fullscreenchange,fullscreenerror:t.fullscreenerror},n={request:function(u){return new Promise(function(l,m){var y=function C(){n.off("fullscreenchange",C),l()};n.on("fullscreenchange",y),u=u||document.documentElement;var E=u[t.requestFullscreen]();E instanceof Promise&&E.then(y).catch(m)})},exit:function(){return new Promise(function(u,l){if(!n.isFullscreen){u();return}var m=function E(){n.off("fullscreenchange",E),u()};n.on("fullscreenchange",m);var y=document[t.exitFullscreen]();y instanceof Promise&&y.then(m).catch(l)})},on:function(u,l){var m=e[u];m&&document.addEventListener(m,l)},off:function(u,l){var m=e[u];m&&document.removeEventListener(m,l)}};return Object.defineProperties(n,{isFullscreen:{get:function(){return!!document[t.fullscreenElement]}},element:{enumerable:!0,get:function(){return document[t.fullscreenElement]}},isEnabled:{enumerable:!0,get:function(){return!!document[t.fullscreenEnabled]}}}),n}var defaultOptions={role:"viewer",autoPlayMuted:!0,allowedDrift:.3,maxAllowedDrift:1,minCheckInterval:.1,maxRateAdjustment:.2,maxTimeToCatchUp:1},TimingSrcConnector=function(t){_inherits(n,t);var e=_createSuper(n);function n(o,u){var l,m=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},y=arguments.length>3?arguments[3]:void 0;return _classCallCheck(this,n),l=e.call(this),_defineProperty(_assertThisInitialized(l),"logger",void 0),_defineProperty(_assertThisInitialized(l),"speedAdjustment",0),_defineProperty(_assertThisInitialized(l),"adjustSpeed",function(){var E=_asyncToGenerator(_regeneratorRuntime().mark(function C(k,A){var D;return _regeneratorRuntime().wrap(function(R){for(;;)switch(R.prev=R.next){case 0:if(l.speedAdjustment!==A){R.next=2;break}return R.abrupt("return");case 2:return R.next=4,k.getPlaybackRate();case 4:return R.t0=R.sent,R.t1=l.speedAdjustment,R.t2=R.t0-R.t1,R.t3=A,D=R.t2+R.t3,l.log("New playbackRate:  ".concat(D)),R.next=12,k.setPlaybackRate(D);case 12:l.speedAdjustment=A;case 13:case"end":return R.stop()}},C)}));return function(C,k){return E.apply(this,arguments)}}()),l.logger=y,l.init(u,o,_objectSpread2(_objectSpread2({},defaultOptions),m)),l}return _createClass(n,[{key:"disconnect",value:function(){this.dispatchEvent(new Event("disconnect"))}},{key:"init",value:function(){var o=_asyncToGenerator(_regeneratorRuntime().mark(function l(m,y,E){var C=this,k,A,D;return _regeneratorRuntime().wrap(function(R){for(;;)switch(R.prev=R.next){case 0:return R.next=2,this.waitForTOReadyState(m,"open");case 2:if(E.role!=="viewer"){R.next=10;break}return R.next=5,this.updatePlayer(m,y,E);case 5:k=subscribe(m,"change",function(){return C.updatePlayer(m,y,E)}),A=this.maintainPlaybackPosition(m,y,E),this.addEventListener("disconnect",function(){A.cancel(),k.cancel()}),R.next=14;break;case 10:return R.next=12,this.updateTimingObject(m,y);case 12:D=subscribe(y,["seeked","play","pause","ratechange"],function(){return C.updateTimingObject(m,y)},"on","off"),this.addEventListener("disconnect",function(){return D.cancel()});case 14:case"end":return R.stop()}},l,this)}));function u(l,m,y){return o.apply(this,arguments)}return u}()},{key:"updateTimingObject",value:function(){var o=_asyncToGenerator(_regeneratorRuntime().mark(function l(m,y){return _regeneratorRuntime().wrap(function(C){for(;;)switch(C.prev=C.next){case 0:return C.t0=m,C.next=3,y.getCurrentTime();case 3:return C.t1=C.sent,C.next=6,y.getPaused();case 6:if(!C.sent){C.next=10;break}C.t2=0,C.next=13;break;case 10:return C.next=12,y.getPlaybackRate();case 12:C.t2=C.sent;case 13:C.t3=C.t2,C.t4={position:C.t1,velocity:C.t3},C.t0.update.call(C.t0,C.t4);case 16:case"end":return C.stop()}},l)}));function u(l,m){return o.apply(this,arguments)}return u}()},{key:"updatePlayer",value:function(){var o=_asyncToGenerator(_regeneratorRuntime().mark(function l(m,y,E){var C,k,A;return _regeneratorRuntime().wrap(function(P){for(;;)switch(P.prev=P.next){case 0:if(C=m.query(),k=C.position,A=C.velocity,typeof k=="number"&&y.setCurrentTime(k),typeof A!="number"){P.next=25;break}if(A!==0){P.next=11;break}return P.next=6,y.getPaused();case 6:if(P.t0=P.sent,P.t0!==!1){P.next=9;break}y.pause();case 9:P.next=25;break;case 11:if(!(A>0)){P.next=25;break}return P.next=14,y.getPaused();case 14:if(P.t1=P.sent,P.t1!==!0){P.next=19;break}return P.next=18,y.play().catch(function(){var R=_asyncToGenerator(_regeneratorRuntime().mark(function B(F){return _regeneratorRuntime().wrap(function(N){for(;;)switch(N.prev=N.next){case 0:if(!(F.name==="NotAllowedError"&&E.autoPlayMuted)){N.next=5;break}return N.next=3,y.setMuted(!0);case 3:return N.next=5,y.play().catch(function(Y){return console.error("Couldn't play the video from TimingSrcConnector. Error:",Y)});case 5:case"end":return N.stop()}},B)}));return function(B){return R.apply(this,arguments)}}());case 18:this.updatePlayer(m,y,E);case 19:return P.next=21,y.getPlaybackRate();case 21:if(P.t2=P.sent,P.t3=A,P.t2===P.t3){P.next=25;break}y.setPlaybackRate(A);case 25:case"end":return P.stop()}},l,this)}));function u(l,m,y){return o.apply(this,arguments)}return u}()},{key:"maintainPlaybackPosition",value:function(u,l,m){var y=this,E=m.allowedDrift,C=m.maxAllowedDrift,k=m.minCheckInterval,A=m.maxRateAdjustment,D=m.maxTimeToCatchUp,P=Math.min(D,Math.max(k,C))*1e3,R=function(){var F=_asyncToGenerator(_regeneratorRuntime().mark(function j(){var N,Y,J,ie,ue;return _regeneratorRuntime().wrap(function(ce){for(;;)switch(ce.prev=ce.next){case 0:if(ce.t0=u.query().velocity===0,ce.t0){ce.next=6;break}return ce.next=4,l.getPaused();case 4:ce.t1=ce.sent,ce.t0=ce.t1===!0;case 6:if(!ce.t0){ce.next=8;break}return ce.abrupt("return");case 8:return ce.t2=u.query().position,ce.next=11,l.getCurrentTime();case 11:if(ce.t3=ce.sent,N=ce.t2-ce.t3,Y=Math.abs(N),y.log("Drift: ".concat(N)),!(Y>C)){ce.next=22;break}return ce.next=18,y.adjustSpeed(l,0);case 18:l.setCurrentTime(u.query().position),y.log("Resync by currentTime"),ce.next=29;break;case 22:if(!(Y>E)){ce.next=29;break}return J=Y/D,ie=A,ue=J<ie?(ie-J)/2:ie,ce.next=28,y.adjustSpeed(l,ue*Math.sign(N));case 28:y.log("Resync by playbackRate");case 29:case"end":return ce.stop()}},j)}));return function(){return F.apply(this,arguments)}}(),B=setInterval(function(){return R()},P);return{cancel:function(){return clearInterval(B)}}}},{key:"log",value:function(u){var l;(l=this.logger)===null||l===void 0||l.call(this,"TimingSrcConnector: ".concat(u))}},{key:"waitForTOReadyState",value:function(u,l){return new Promise(function(m){var y=function E(){u.readyState===l?m():u.addEventListener("readystatechange",E,{once:!0})};y()})}}]),n}(_wrapNativeSuper(EventTarget)),playerMap=new WeakMap,readyMap=new WeakMap,screenfull={},Player=function(){function t(e){var n=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(_classCallCheck(this,t),window.jQuery&&e instanceof jQuery&&(e.length>1&&window.console&&console.warn&&console.warn("A jQuery object with multiple elements was passed, using the first element."),e=e[0]),typeof document<"u"&&typeof e=="string"&&(e=document.getElementById(e)),!isDomElement(e))throw new TypeError("You must pass either a valid element or a valid id.");if(e.nodeName!=="IFRAME"){var u=e.querySelector("iframe");u&&(e=u)}if(e.nodeName==="IFRAME"&&!isVimeoUrl(e.getAttribute("src")||""))throw new Error("The player element passed isn’t a Vimeo embed.");if(playerMap.has(e))return playerMap.get(e);this._window=e.ownerDocument.defaultView,this.element=e,this.origin="*";var l=new npo_src(function(y,E){if(n._onMessage=function(A){if(!(!isVimeoUrl(A.origin)||n.element.contentWindow!==A.source)){n.origin==="*"&&(n.origin=A.origin);var D=parseMessageData(A.data),P=D&&D.event==="error",R=P&&D.data&&D.data.method==="ready";if(R){var B=new Error(D.data.message);B.name=D.data.name,E(B);return}var F=D&&D.event==="ready",j=D&&D.method==="ping";if(F||j){n.element.setAttribute("data-ready","true"),y();return}processData(n,D)}},n._window.addEventListener("message",n._onMessage),n.element.nodeName!=="IFRAME"){var C=getOEmbedParameters(e,o),k=getVimeoUrl(C);getOEmbedData(k,C,e).then(function(A){var D=createEmbed(A,e);return n.element=D,n._originalElement=e,swapCallbacks(e,D),playerMap.set(n.element,n),A}).catch(E)}});if(readyMap.set(this,l),playerMap.set(this.element,this),this.element.nodeName==="IFRAME"&&postMessage(this,"ping"),screenfull.isEnabled){var m=function(){return screenfull.exit()};this.fullscreenchangeHandler=function(){screenfull.isFullscreen?storeCallback(n,"event:exitFullscreen",m):removeCallback(n,"event:exitFullscreen",m),n.ready().then(function(){postMessage(n,"fullscreenchange",screenfull.isFullscreen)})},screenfull.on("fullscreenchange",this.fullscreenchangeHandler)}return this}return _createClass(t,[{key:"callMethod",value:function(n){var o=this,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return new npo_src(function(l,m){return o.ready().then(function(){storeCallback(o,n,{resolve:l,reject:m}),postMessage(o,n,u)}).catch(m)})}},{key:"get",value:function(n){var o=this;return new npo_src(function(u,l){return n=getMethodName(n,"get"),o.ready().then(function(){storeCallback(o,n,{resolve:u,reject:l}),postMessage(o,n)}).catch(l)})}},{key:"set",value:function(n,o){var u=this;return new npo_src(function(l,m){if(n=getMethodName(n,"set"),o==null)throw new TypeError("There must be a value to set.");return u.ready().then(function(){storeCallback(u,n,{resolve:l,reject:m}),postMessage(u,n,o)}).catch(m)})}},{key:"on",value:function(n,o){if(!n)throw new TypeError("You must pass an event name.");if(!o)throw new TypeError("You must pass a callback function.");if(typeof o!="function")throw new TypeError("The callback must be a function.");var u=getCallbacks(this,"event:".concat(n));u.length===0&&this.callMethod("addEventListener",n).catch(function(){}),storeCallback(this,"event:".concat(n),o)}},{key:"off",value:function(n,o){if(!n)throw new TypeError("You must pass an event name.");if(o&&typeof o!="function")throw new TypeError("The callback must be a function.");var u=removeCallback(this,"event:".concat(n),o);u&&this.callMethod("removeEventListener",n).catch(function(l){})}},{key:"loadVideo",value:function(n){return this.callMethod("loadVideo",n)}},{key:"ready",value:function(){var n=readyMap.get(this)||new npo_src(function(o,u){u(new Error("Unknown player. Probably unloaded."))});return npo_src.resolve(n)}},{key:"addCuePoint",value:function(n){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.callMethod("addCuePoint",{time:n,data:o})}},{key:"removeCuePoint",value:function(n){return this.callMethod("removeCuePoint",n)}},{key:"enableTextTrack",value:function(n,o){if(!n)throw new TypeError("You must pass a language.");return this.callMethod("enableTextTrack",{language:n,kind:o})}},{key:"disableTextTrack",value:function(){return this.callMethod("disableTextTrack")}},{key:"pause",value:function(){return this.callMethod("pause")}},{key:"play",value:function(){return this.callMethod("play")}},{key:"requestFullscreen",value:function(){return screenfull.isEnabled?screenfull.request(this.element):this.callMethod("requestFullscreen")}},{key:"exitFullscreen",value:function(){return screenfull.isEnabled?screenfull.exit():this.callMethod("exitFullscreen")}},{key:"getFullscreen",value:function(){return screenfull.isEnabled?npo_src.resolve(screenfull.isFullscreen):this.get("fullscreen")}},{key:"requestPictureInPicture",value:function(){return this.callMethod("requestPictureInPicture")}},{key:"exitPictureInPicture",value:function(){return this.callMethod("exitPictureInPicture")}},{key:"getPictureInPicture",value:function(){return this.get("pictureInPicture")}},{key:"remotePlaybackPrompt",value:function(){return this.callMethod("remotePlaybackPrompt")}},{key:"unload",value:function(){return this.callMethod("unload")}},{key:"destroy",value:function(){var n=this;return new npo_src(function(o){if(readyMap.delete(n),playerMap.delete(n.element),n._originalElement&&(playerMap.delete(n._originalElement),n._originalElement.removeAttribute("data-vimeo-initialized")),n.element&&n.element.nodeName==="IFRAME"&&n.element.parentNode&&(n.element.parentNode.parentNode&&n._originalElement&&n._originalElement!==n.element.parentNode?n.element.parentNode.parentNode.removeChild(n.element.parentNode):n.element.parentNode.removeChild(n.element)),n.element&&n.element.nodeName==="DIV"&&n.element.parentNode){n.element.removeAttribute("data-vimeo-initialized");var u=n.element.querySelector("iframe");u&&u.parentNode&&(u.parentNode.parentNode&&n._originalElement&&n._originalElement!==u.parentNode?u.parentNode.parentNode.removeChild(u.parentNode):u.parentNode.removeChild(u))}n._window.removeEventListener("message",n._onMessage),screenfull.isEnabled&&screenfull.off("fullscreenchange",n.fullscreenchangeHandler),o()})}},{key:"getAutopause",value:function(){return this.get("autopause")}},{key:"setAutopause",value:function(n){return this.set("autopause",n)}},{key:"getBuffered",value:function(){return this.get("buffered")}},{key:"getCameraProps",value:function(){return this.get("cameraProps")}},{key:"setCameraProps",value:function(n){return this.set("cameraProps",n)}},{key:"getChapters",value:function(){return this.get("chapters")}},{key:"getCurrentChapter",value:function(){return this.get("currentChapter")}},{key:"getColor",value:function(){return this.get("color")}},{key:"getColors",value:function(){return npo_src.all([this.get("colorOne"),this.get("colorTwo"),this.get("colorThree"),this.get("colorFour")])}},{key:"setColor",value:function(n){return this.set("color",n)}},{key:"setColors",value:function(n){if(!Array.isArray(n))return new npo_src(function(l,m){return m(new TypeError("Argument must be an array."))});var o=new npo_src(function(l){return l(null)}),u=[n[0]?this.set("colorOne",n[0]):o,n[1]?this.set("colorTwo",n[1]):o,n[2]?this.set("colorThree",n[2]):o,n[3]?this.set("colorFour",n[3]):o];return npo_src.all(u)}},{key:"getCuePoints",value:function(){return this.get("cuePoints")}},{key:"getCurrentTime",value:function(){return this.get("currentTime")}},{key:"setCurrentTime",value:function(n){return this.set("currentTime",n)}},{key:"getDuration",value:function(){return this.get("duration")}},{key:"getEnded",value:function(){return this.get("ended")}},{key:"getLoop",value:function(){return this.get("loop")}},{key:"setLoop",value:function(n){return this.set("loop",n)}},{key:"setMuted",value:function(n){return this.set("muted",n)}},{key:"getMuted",value:function(){return this.get("muted")}},{key:"getPaused",value:function(){return this.get("paused")}},{key:"getPlaybackRate",value:function(){return this.get("playbackRate")}},{key:"setPlaybackRate",value:function(n){return this.set("playbackRate",n)}},{key:"getPlayed",value:function(){return this.get("played")}},{key:"getQualities",value:function(){return this.get("qualities")}},{key:"getQuality",value:function(){return this.get("quality")}},{key:"setQuality",value:function(n){return this.set("quality",n)}},{key:"getRemotePlaybackAvailability",value:function(){return this.get("remotePlaybackAvailability")}},{key:"getRemotePlaybackState",value:function(){return this.get("remotePlaybackState")}},{key:"getSeekable",value:function(){return this.get("seekable")}},{key:"getSeeking",value:function(){return this.get("seeking")}},{key:"getTextTracks",value:function(){return this.get("textTracks")}},{key:"getVideoEmbedCode",value:function(){return this.get("videoEmbedCode")}},{key:"getVideoId",value:function(){return this.get("videoId")}},{key:"getVideoTitle",value:function(){return this.get("videoTitle")}},{key:"getVideoWidth",value:function(){return this.get("videoWidth")}},{key:"getVideoHeight",value:function(){return this.get("videoHeight")}},{key:"getVideoUrl",value:function(){return this.get("videoUrl")}},{key:"getVolume",value:function(){return this.get("volume")}},{key:"setVolume",value:function(n){return this.set("volume",n)}},{key:"setTimingSrc",value:function(){var e=_asyncToGenerator(_regeneratorRuntime().mark(function o(u,l){var m=this,y;return _regeneratorRuntime().wrap(function(C){for(;;)switch(C.prev=C.next){case 0:if(u){C.next=2;break}throw new TypeError("A Timing Object must be provided.");case 2:return C.next=4,this.ready();case 4:return y=new TimingSrcConnector(this,u,l),postMessage(this,"notifyTimingObjectConnect"),y.addEventListener("disconnect",function(){return postMessage(m,"notifyTimingObjectDisconnect")}),C.abrupt("return",y);case 8:case"end":return C.stop()}},o,this)}));function n(o,u){return e.apply(this,arguments)}return n}()}]),t}();isNode||(screenfull=initializeScreenfull(),initializeEmbeds(),resizeEmbeds(),initAppendVideoMetadata(),checkUrlTimeParam());let cssInjected=!1;function injectCss(){if(cssInjected)return;cssInjected=!0;const t=`
    .vjs-vimeo iframe {
      position: absolute;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
    }
  `,e=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",n.styleSheet?n.styleSheet.cssText=t:n.appendChild(document.createTextNode(t)),e.appendChild(n)}const Tech=videojs.getTech("Tech");class Vimeo extends Tech{constructor(e,n){super(e,n),injectCss(),this.setPoster(e.poster),this.initVimeoPlayer()}initVimeoPlayer(){this.options({});const e={url:this.options_.source.src,byline:!1,portrait:!1,title:!1,controls:!1};this.options_.autoplay&&(e.autoplay=!0),typeof this.options_.controls<"u"&&(e.controls=this.options_.controls),this.options_.height&&(e.height=this.options_.height),this.options_.width&&(e.width=this.options_.width),this.options_.maxheight&&(e.maxheight=this.options_.maxheight),this.options_.maxwidth&&(e.maxwidth=this.options_.maxwidth),this.options_.loop&&(e.loop=this.options_.loop),this.options_.color&&(e.color=this.options_.color.replace(/^#/,"")),e.controls=!1,this._player=new Player(this.el(),e),this.initVimeoState(),["play","pause","ended","timeupdate","progress","seeked"].forEach(n=>{this._player.on(n,o=>{this._vimeoState.progress.duration!==o.duration&&this.trigger("durationchange"),this._vimeoState.progress=o,this.trigger(n)})}),this._player.on("pause",()=>this._vimeoState.playing=!1),this._player.on("play",()=>{this._vimeoState.playing=!0,this._vimeoState.ended=!1}),this._player.on("ended",()=>{this._vimeoState.playing=!1,this._vimeoState.ended=!0}),this._player.on("volumechange",n=>this._vimeoState.volume=n),this._player.on("error",n=>this.trigger("error",n)),this.triggerReady()}initVimeoState(){const e=this._vimeoState={ended:!1,playing:!1,volume:0,progress:{seconds:0,percent:0,duration:0}};this._player.getCurrentTime().then(n=>e.progress.seconds=n),this._player.getDuration().then(n=>e.progress.duration=n),this._player.getPaused().then(n=>e.playing=!n),this._player.getVolume().then(n=>e.volume=n)}createEl(){const e=videojs.dom.createEl("div",{id:this.options_.techId});return e.style.cssText="width:100%;height:100%;top:0;left:0;position:absolute",e.className="vjs-vimeo",e}controls(){return!0}supportsFullScreen(){return!0}src(){return this.options_.source}currentSrc(){return this.options_.source.src}currentTime(){return this._vimeoState.progress.seconds}setCurrentTime(e){this._player.setCurrentTime(e)}volume(){return this._vimeoState.volume}setVolume(e){return this._player.setVolume(e)}duration(){return this._vimeoState.progress.duration}buffered(){const e=this._vimeoState.progress;return videojs.createTimeRange(0,e.percent*e.duration)}paused(){return!this._vimeoState.playing}pause(){this._player.pause()}play(){this._player.play()}muted(){return this._vimeoState.volume===0}setMuted(e){return this._player.setMuted(e)}ended(){return this._vimeoState.ended}playbackRate(){return 1}}Vimeo.prototype.featuresTimeupdateEvents=!0,Vimeo.isSupported=function(){return!0},Tech.withSourceHandlers(Vimeo),Vimeo.nativeSourceHandler={},Vimeo.nativeSourceHandler.canPlayType=function(t){return t==="video/vimeo"?"maybe":""},Vimeo.nativeSourceHandler.canHandleSource=function(t){return t.type?Vimeo.nativeSourceHandler.canPlayType(t.type):t.src?Vimeo.nativeSourceHandler.canPlayType(t.src):""},Vimeo.nativeSourceHandler.handleSource=function(t,e){e.src(t.src)},Vimeo.nativeSourceHandler.dispose=function(){},Vimeo.registerSourceHandler(Vimeo.nativeSourceHandler),typeof videojs.registerTech<"u"?videojs.registerTech("Vimeo",Vimeo):videojs.registerComponent("Vimeo",Vimeo),Vimeo.VERSION="0.0.1";const videojsStyles={};var mimeTypes={};const require$$0$4={"application/1d-interleaved-parityfec":{source:"iana"},"application/3gpdash-qoe-report+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/3gpp-ims+xml":{source:"iana",compressible:!0},"application/3gpphal+json":{source:"iana",compressible:!0},"application/3gpphalforms+json":{source:"iana",compressible:!0},"application/a2l":{source:"iana"},"application/ace+cbor":{source:"iana"},"application/activemessage":{source:"iana"},"application/activity+json":{source:"iana",compressible:!0},"application/alto-costmap+json":{source:"iana",compressible:!0},"application/alto-costmapfilter+json":{source:"iana",compressible:!0},"application/alto-directory+json":{source:"iana",compressible:!0},"application/alto-endpointcost+json":{source:"iana",compressible:!0},"application/alto-endpointcostparams+json":{source:"iana",compressible:!0},"application/alto-endpointprop+json":{source:"iana",compressible:!0},"application/alto-endpointpropparams+json":{source:"iana",compressible:!0},"application/alto-error+json":{source:"iana",compressible:!0},"application/alto-networkmap+json":{source:"iana",compressible:!0},"application/alto-networkmapfilter+json":{source:"iana",compressible:!0},"application/alto-updatestreamcontrol+json":{source:"iana",compressible:!0},"application/alto-updatestreamparams+json":{source:"iana",compressible:!0},"application/aml":{source:"iana"},"application/andrew-inset":{source:"iana",extensions:["ez"]},"application/applefile":{source:"iana"},"application/applixware":{source:"apache",extensions:["aw"]},"application/at+jwt":{source:"iana"},"application/atf":{source:"iana"},"application/atfx":{source:"iana"},"application/atom+xml":{source:"iana",compressible:!0,extensions:["atom"]},"application/atomcat+xml":{source:"iana",compressible:!0,extensions:["atomcat"]},"application/atomdeleted+xml":{source:"iana",compressible:!0,extensions:["atomdeleted"]},"application/atomicmail":{source:"iana"},"application/atomsvc+xml":{source:"iana",compressible:!0,extensions:["atomsvc"]},"application/atsc-dwd+xml":{source:"iana",compressible:!0,extensions:["dwd"]},"application/atsc-dynamic-event-message":{source:"iana"},"application/atsc-held+xml":{source:"iana",compressible:!0,extensions:["held"]},"application/atsc-rdt+json":{source:"iana",compressible:!0},"application/atsc-rsat+xml":{source:"iana",compressible:!0,extensions:["rsat"]},"application/atxml":{source:"iana"},"application/auth-policy+xml":{source:"iana",compressible:!0},"application/bacnet-xdd+zip":{source:"iana",compressible:!1},"application/batch-smtp":{source:"iana"},"application/bdoc":{compressible:!1,extensions:["bdoc"]},"application/beep+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/calendar+json":{source:"iana",compressible:!0},"application/calendar+xml":{source:"iana",compressible:!0,extensions:["xcs"]},"application/call-completion":{source:"iana"},"application/cals-1840":{source:"iana"},"application/captive+json":{source:"iana",compressible:!0},"application/cbor":{source:"iana"},"application/cbor-seq":{source:"iana"},"application/cccex":{source:"iana"},"application/ccmp+xml":{source:"iana",compressible:!0},"application/ccxml+xml":{source:"iana",compressible:!0,extensions:["ccxml"]},"application/cdfx+xml":{source:"iana",compressible:!0,extensions:["cdfx"]},"application/cdmi-capability":{source:"iana",extensions:["cdmia"]},"application/cdmi-container":{source:"iana",extensions:["cdmic"]},"application/cdmi-domain":{source:"iana",extensions:["cdmid"]},"application/cdmi-object":{source:"iana",extensions:["cdmio"]},"application/cdmi-queue":{source:"iana",extensions:["cdmiq"]},"application/cdni":{source:"iana"},"application/cea":{source:"iana"},"application/cea-2018+xml":{source:"iana",compressible:!0},"application/cellml+xml":{source:"iana",compressible:!0},"application/cfw":{source:"iana"},"application/city+json":{source:"iana",compressible:!0},"application/clr":{source:"iana"},"application/clue+xml":{source:"iana",compressible:!0},"application/clue_info+xml":{source:"iana",compressible:!0},"application/cms":{source:"iana"},"application/cnrp+xml":{source:"iana",compressible:!0},"application/coap-group+json":{source:"iana",compressible:!0},"application/coap-payload":{source:"iana"},"application/commonground":{source:"iana"},"application/conference-info+xml":{source:"iana",compressible:!0},"application/cose":{source:"iana"},"application/cose-key":{source:"iana"},"application/cose-key-set":{source:"iana"},"application/cpl+xml":{source:"iana",compressible:!0,extensions:["cpl"]},"application/csrattrs":{source:"iana"},"application/csta+xml":{source:"iana",compressible:!0},"application/cstadata+xml":{source:"iana",compressible:!0},"application/csvm+json":{source:"iana",compressible:!0},"application/cu-seeme":{source:"apache",extensions:["cu"]},"application/cwt":{source:"iana"},"application/cybercash":{source:"iana"},"application/dart":{compressible:!0},"application/dash+xml":{source:"iana",compressible:!0,extensions:["mpd"]},"application/dash-patch+xml":{source:"iana",compressible:!0,extensions:["mpp"]},"application/dashdelta":{source:"iana"},"application/davmount+xml":{source:"iana",compressible:!0,extensions:["davmount"]},"application/dca-rft":{source:"iana"},"application/dcd":{source:"iana"},"application/dec-dx":{source:"iana"},"application/dialog-info+xml":{source:"iana",compressible:!0},"application/dicom":{source:"iana"},"application/dicom+json":{source:"iana",compressible:!0},"application/dicom+xml":{source:"iana",compressible:!0},"application/dii":{source:"iana"},"application/dit":{source:"iana"},"application/dns":{source:"iana"},"application/dns+json":{source:"iana",compressible:!0},"application/dns-message":{source:"iana"},"application/docbook+xml":{source:"apache",compressible:!0,extensions:["dbk"]},"application/dots+cbor":{source:"iana"},"application/dskpp+xml":{source:"iana",compressible:!0},"application/dssc+der":{source:"iana",extensions:["dssc"]},"application/dssc+xml":{source:"iana",compressible:!0,extensions:["xdssc"]},"application/dvcs":{source:"iana"},"application/ecmascript":{source:"iana",compressible:!0,extensions:["es","ecma"]},"application/edi-consent":{source:"iana"},"application/edi-x12":{source:"iana",compressible:!1},"application/edifact":{source:"iana",compressible:!1},"application/efi":{source:"iana"},"application/elm+json":{source:"iana",charset:"UTF-8",compressible:!0},"application/elm+xml":{source:"iana",compressible:!0},"application/emergencycalldata.cap+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/emergencycalldata.comment+xml":{source:"iana",compressible:!0},"application/emergencycalldata.control+xml":{source:"iana",compressible:!0},"application/emergencycalldata.deviceinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.ecall.msd":{source:"iana"},"application/emergencycalldata.providerinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.serviceinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.subscriberinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.veds+xml":{source:"iana",compressible:!0},"application/emma+xml":{source:"iana",compressible:!0,extensions:["emma"]},"application/emotionml+xml":{source:"iana",compressible:!0,extensions:["emotionml"]},"application/encaprtp":{source:"iana"},"application/epp+xml":{source:"iana",compressible:!0},"application/epub+zip":{source:"iana",compressible:!1,extensions:["epub"]},"application/eshop":{source:"iana"},"application/exi":{source:"iana",extensions:["exi"]},"application/expect-ct-report+json":{source:"iana",compressible:!0},"application/express":{source:"iana",extensions:["exp"]},"application/fastinfoset":{source:"iana"},"application/fastsoap":{source:"iana"},"application/fdt+xml":{source:"iana",compressible:!0,extensions:["fdt"]},"application/fhir+json":{source:"iana",charset:"UTF-8",compressible:!0},"application/fhir+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/fido.trusted-apps+json":{compressible:!0},"application/fits":{source:"iana"},"application/flexfec":{source:"iana"},"application/font-sfnt":{source:"iana"},"application/font-tdpfr":{source:"iana",extensions:["pfr"]},"application/font-woff":{source:"iana",compressible:!1},"application/framework-attributes+xml":{source:"iana",compressible:!0},"application/geo+json":{source:"iana",compressible:!0,extensions:["geojson"]},"application/geo+json-seq":{source:"iana"},"application/geopackage+sqlite3":{source:"iana"},"application/geoxacml+xml":{source:"iana",compressible:!0},"application/gltf-buffer":{source:"iana"},"application/gml+xml":{source:"iana",compressible:!0,extensions:["gml"]},"application/gpx+xml":{source:"apache",compressible:!0,extensions:["gpx"]},"application/gxf":{source:"apache",extensions:["gxf"]},"application/gzip":{source:"iana",compressible:!1,extensions:["gz"]},"application/h224":{source:"iana"},"application/held+xml":{source:"iana",compressible:!0},"application/hjson":{extensions:["hjson"]},"application/http":{source:"iana"},"application/hyperstudio":{source:"iana",extensions:["stk"]},"application/ibe-key-request+xml":{source:"iana",compressible:!0},"application/ibe-pkg-reply+xml":{source:"iana",compressible:!0},"application/ibe-pp-data":{source:"iana"},"application/iges":{source:"iana"},"application/im-iscomposing+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/index":{source:"iana"},"application/index.cmd":{source:"iana"},"application/index.obj":{source:"iana"},"application/index.response":{source:"iana"},"application/index.vnd":{source:"iana"},"application/inkml+xml":{source:"iana",compressible:!0,extensions:["ink","inkml"]},"application/iotp":{source:"iana"},"application/ipfix":{source:"iana",extensions:["ipfix"]},"application/ipp":{source:"iana"},"application/isup":{source:"iana"},"application/its+xml":{source:"iana",compressible:!0,extensions:["its"]},"application/java-archive":{source:"apache",compressible:!1,extensions:["jar","war","ear"]},"application/java-serialized-object":{source:"apache",compressible:!1,extensions:["ser"]},"application/java-vm":{source:"apache",compressible:!1,extensions:["class"]},"application/javascript":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["js","mjs"]},"application/jf2feed+json":{source:"iana",compressible:!0},"application/jose":{source:"iana"},"application/jose+json":{source:"iana",compressible:!0},"application/jrd+json":{source:"iana",compressible:!0},"application/jscalendar+json":{source:"iana",compressible:!0},"application/json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["json","map"]},"application/json-patch+json":{source:"iana",compressible:!0},"application/json-seq":{source:"iana"},"application/json5":{extensions:["json5"]},"application/jsonml+json":{source:"apache",compressible:!0,extensions:["jsonml"]},"application/jwk+json":{source:"iana",compressible:!0},"application/jwk-set+json":{source:"iana",compressible:!0},"application/jwt":{source:"iana"},"application/kpml-request+xml":{source:"iana",compressible:!0},"application/kpml-response+xml":{source:"iana",compressible:!0},"application/ld+json":{source:"iana",compressible:!0,extensions:["jsonld"]},"application/lgr+xml":{source:"iana",compressible:!0,extensions:["lgr"]},"application/link-format":{source:"iana"},"application/load-control+xml":{source:"iana",compressible:!0},"application/lost+xml":{source:"iana",compressible:!0,extensions:["lostxml"]},"application/lostsync+xml":{source:"iana",compressible:!0},"application/lpf+zip":{source:"iana",compressible:!1},"application/lxf":{source:"iana"},"application/mac-binhex40":{source:"iana",extensions:["hqx"]},"application/mac-compactpro":{source:"apache",extensions:["cpt"]},"application/macwriteii":{source:"iana"},"application/mads+xml":{source:"iana",compressible:!0,extensions:["mads"]},"application/manifest+json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["webmanifest"]},"application/marc":{source:"iana",extensions:["mrc"]},"application/marcxml+xml":{source:"iana",compressible:!0,extensions:["mrcx"]},"application/mathematica":{source:"iana",extensions:["ma","nb","mb"]},"application/mathml+xml":{source:"iana",compressible:!0,extensions:["mathml"]},"application/mathml-content+xml":{source:"iana",compressible:!0},"application/mathml-presentation+xml":{source:"iana",compressible:!0},"application/mbms-associated-procedure-description+xml":{source:"iana",compressible:!0},"application/mbms-deregister+xml":{source:"iana",compressible:!0},"application/mbms-envelope+xml":{source:"iana",compressible:!0},"application/mbms-msk+xml":{source:"iana",compressible:!0},"application/mbms-msk-response+xml":{source:"iana",compressible:!0},"application/mbms-protection-description+xml":{source:"iana",compressible:!0},"application/mbms-reception-report+xml":{source:"iana",compressible:!0},"application/mbms-register+xml":{source:"iana",compressible:!0},"application/mbms-register-response+xml":{source:"iana",compressible:!0},"application/mbms-schedule+xml":{source:"iana",compressible:!0},"application/mbms-user-service-description+xml":{source:"iana",compressible:!0},"application/mbox":{source:"iana",extensions:["mbox"]},"application/media-policy-dataset+xml":{source:"iana",compressible:!0,extensions:["mpf"]},"application/media_control+xml":{source:"iana",compressible:!0},"application/mediaservercontrol+xml":{source:"iana",compressible:!0,extensions:["mscml"]},"application/merge-patch+json":{source:"iana",compressible:!0},"application/metalink+xml":{source:"apache",compressible:!0,extensions:["metalink"]},"application/metalink4+xml":{source:"iana",compressible:!0,extensions:["meta4"]},"application/mets+xml":{source:"iana",compressible:!0,extensions:["mets"]},"application/mf4":{source:"iana"},"application/mikey":{source:"iana"},"application/mipc":{source:"iana"},"application/missing-blocks+cbor-seq":{source:"iana"},"application/mmt-aei+xml":{source:"iana",compressible:!0,extensions:["maei"]},"application/mmt-usd+xml":{source:"iana",compressible:!0,extensions:["musd"]},"application/mods+xml":{source:"iana",compressible:!0,extensions:["mods"]},"application/moss-keys":{source:"iana"},"application/moss-signature":{source:"iana"},"application/mosskey-data":{source:"iana"},"application/mosskey-request":{source:"iana"},"application/mp21":{source:"iana",extensions:["m21","mp21"]},"application/mp4":{source:"iana",extensions:["mp4s","m4p"]},"application/mpeg4-generic":{source:"iana"},"application/mpeg4-iod":{source:"iana"},"application/mpeg4-iod-xmt":{source:"iana"},"application/mrb-consumer+xml":{source:"iana",compressible:!0},"application/mrb-publish+xml":{source:"iana",compressible:!0},"application/msc-ivr+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/msc-mixer+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/msword":{source:"iana",compressible:!1,extensions:["doc","dot"]},"application/mud+json":{source:"iana",compressible:!0},"application/multipart-core":{source:"iana"},"application/mxf":{source:"iana",extensions:["mxf"]},"application/n-quads":{source:"iana",extensions:["nq"]},"application/n-triples":{source:"iana",extensions:["nt"]},"application/nasdata":{source:"iana"},"application/news-checkgroups":{source:"iana",charset:"US-ASCII"},"application/news-groupinfo":{source:"iana",charset:"US-ASCII"},"application/news-transmission":{source:"iana"},"application/nlsml+xml":{source:"iana",compressible:!0},"application/node":{source:"iana",extensions:["cjs"]},"application/nss":{source:"iana"},"application/oauth-authz-req+jwt":{source:"iana"},"application/oblivious-dns-message":{source:"iana"},"application/ocsp-request":{source:"iana"},"application/ocsp-response":{source:"iana"},"application/octet-stream":{source:"iana",compressible:!1,extensions:["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"]},"application/oda":{source:"iana",extensions:["oda"]},"application/odm+xml":{source:"iana",compressible:!0},"application/odx":{source:"iana"},"application/oebps-package+xml":{source:"iana",compressible:!0,extensions:["opf"]},"application/ogg":{source:"iana",compressible:!1,extensions:["ogx"]},"application/omdoc+xml":{source:"apache",compressible:!0,extensions:["omdoc"]},"application/onenote":{source:"apache",extensions:["onetoc","onetoc2","onetmp","onepkg"]},"application/opc-nodeset+xml":{source:"iana",compressible:!0},"application/oscore":{source:"iana"},"application/oxps":{source:"iana",extensions:["oxps"]},"application/p21":{source:"iana"},"application/p21+zip":{source:"iana",compressible:!1},"application/p2p-overlay+xml":{source:"iana",compressible:!0,extensions:["relo"]},"application/parityfec":{source:"iana"},"application/passport":{source:"iana"},"application/patch-ops-error+xml":{source:"iana",compressible:!0,extensions:["xer"]},"application/pdf":{source:"iana",compressible:!1,extensions:["pdf"]},"application/pdx":{source:"iana"},"application/pem-certificate-chain":{source:"iana"},"application/pgp-encrypted":{source:"iana",compressible:!1,extensions:["pgp"]},"application/pgp-keys":{source:"iana",extensions:["asc"]},"application/pgp-signature":{source:"iana",extensions:["asc","sig"]},"application/pics-rules":{source:"apache",extensions:["prf"]},"application/pidf+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/pidf-diff+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/pkcs10":{source:"iana",extensions:["p10"]},"application/pkcs12":{source:"iana"},"application/pkcs7-mime":{source:"iana",extensions:["p7m","p7c"]},"application/pkcs7-signature":{source:"iana",extensions:["p7s"]},"application/pkcs8":{source:"iana",extensions:["p8"]},"application/pkcs8-encrypted":{source:"iana"},"application/pkix-attr-cert":{source:"iana",extensions:["ac"]},"application/pkix-cert":{source:"iana",extensions:["cer"]},"application/pkix-crl":{source:"iana",extensions:["crl"]},"application/pkix-pkipath":{source:"iana",extensions:["pkipath"]},"application/pkixcmp":{source:"iana",extensions:["pki"]},"application/pls+xml":{source:"iana",compressible:!0,extensions:["pls"]},"application/poc-settings+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/postscript":{source:"iana",compressible:!0,extensions:["ai","eps","ps"]},"application/ppsp-tracker+json":{source:"iana",compressible:!0},"application/problem+json":{source:"iana",compressible:!0},"application/problem+xml":{source:"iana",compressible:!0},"application/provenance+xml":{source:"iana",compressible:!0,extensions:["provx"]},"application/prs.alvestrand.titrax-sheet":{source:"iana"},"application/prs.cww":{source:"iana",extensions:["cww"]},"application/prs.cyn":{source:"iana",charset:"7-BIT"},"application/prs.hpub+zip":{source:"iana",compressible:!1},"application/prs.nprend":{source:"iana"},"application/prs.plucker":{source:"iana"},"application/prs.rdf-xml-crypt":{source:"iana"},"application/prs.xsf+xml":{source:"iana",compressible:!0},"application/pskc+xml":{source:"iana",compressible:!0,extensions:["pskcxml"]},"application/pvd+json":{source:"iana",compressible:!0},"application/qsig":{source:"iana"},"application/raml+yaml":{compressible:!0,extensions:["raml"]},"application/raptorfec":{source:"iana"},"application/rdap+json":{source:"iana",compressible:!0},"application/rdf+xml":{source:"iana",compressible:!0,extensions:["rdf","owl"]},"application/reginfo+xml":{source:"iana",compressible:!0,extensions:["rif"]},"application/relax-ng-compact-syntax":{source:"iana",extensions:["rnc"]},"application/remote-printing":{source:"iana"},"application/reputon+json":{source:"iana",compressible:!0},"application/resource-lists+xml":{source:"iana",compressible:!0,extensions:["rl"]},"application/resource-lists-diff+xml":{source:"iana",compressible:!0,extensions:["rld"]},"application/rfc+xml":{source:"iana",compressible:!0},"application/riscos":{source:"iana"},"application/rlmi+xml":{source:"iana",compressible:!0},"application/rls-services+xml":{source:"iana",compressible:!0,extensions:["rs"]},"application/route-apd+xml":{source:"iana",compressible:!0,extensions:["rapd"]},"application/route-s-tsid+xml":{source:"iana",compressible:!0,extensions:["sls"]},"application/route-usd+xml":{source:"iana",compressible:!0,extensions:["rusd"]},"application/rpki-ghostbusters":{source:"iana",extensions:["gbr"]},"application/rpki-manifest":{source:"iana",extensions:["mft"]},"application/rpki-publication":{source:"iana"},"application/rpki-roa":{source:"iana",extensions:["roa"]},"application/rpki-updown":{source:"iana"},"application/rsd+xml":{source:"apache",compressible:!0,extensions:["rsd"]},"application/rss+xml":{source:"apache",compressible:!0,extensions:["rss"]},"application/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"application/rtploopback":{source:"iana"},"application/rtx":{source:"iana"},"application/samlassertion+xml":{source:"iana",compressible:!0},"application/samlmetadata+xml":{source:"iana",compressible:!0},"application/sarif+json":{source:"iana",compressible:!0},"application/sarif-external-properties+json":{source:"iana",compressible:!0},"application/sbe":{source:"iana"},"application/sbml+xml":{source:"iana",compressible:!0,extensions:["sbml"]},"application/scaip+xml":{source:"iana",compressible:!0},"application/scim+json":{source:"iana",compressible:!0},"application/scvp-cv-request":{source:"iana",extensions:["scq"]},"application/scvp-cv-response":{source:"iana",extensions:["scs"]},"application/scvp-vp-request":{source:"iana",extensions:["spq"]},"application/scvp-vp-response":{source:"iana",extensions:["spp"]},"application/sdp":{source:"iana",extensions:["sdp"]},"application/secevent+jwt":{source:"iana"},"application/senml+cbor":{source:"iana"},"application/senml+json":{source:"iana",compressible:!0},"application/senml+xml":{source:"iana",compressible:!0,extensions:["senmlx"]},"application/senml-etch+cbor":{source:"iana"},"application/senml-etch+json":{source:"iana",compressible:!0},"application/senml-exi":{source:"iana"},"application/sensml+cbor":{source:"iana"},"application/sensml+json":{source:"iana",compressible:!0},"application/sensml+xml":{source:"iana",compressible:!0,extensions:["sensmlx"]},"application/sensml-exi":{source:"iana"},"application/sep+xml":{source:"iana",compressible:!0},"application/sep-exi":{source:"iana"},"application/session-info":{source:"iana"},"application/set-payment":{source:"iana"},"application/set-payment-initiation":{source:"iana",extensions:["setpay"]},"application/set-registration":{source:"iana"},"application/set-registration-initiation":{source:"iana",extensions:["setreg"]},"application/sgml":{source:"iana"},"application/sgml-open-catalog":{source:"iana"},"application/shf+xml":{source:"iana",compressible:!0,extensions:["shf"]},"application/sieve":{source:"iana",extensions:["siv","sieve"]},"application/simple-filter+xml":{source:"iana",compressible:!0},"application/simple-message-summary":{source:"iana"},"application/simplesymbolcontainer":{source:"iana"},"application/sipc":{source:"iana"},"application/slate":{source:"iana"},"application/smil":{source:"iana"},"application/smil+xml":{source:"iana",compressible:!0,extensions:["smi","smil"]},"application/smpte336m":{source:"iana"},"application/soap+fastinfoset":{source:"iana"},"application/soap+xml":{source:"iana",compressible:!0},"application/sparql-query":{source:"iana",extensions:["rq"]},"application/sparql-results+xml":{source:"iana",compressible:!0,extensions:["srx"]},"application/spdx+json":{source:"iana",compressible:!0},"application/spirits-event+xml":{source:"iana",compressible:!0},"application/sql":{source:"iana"},"application/srgs":{source:"iana",extensions:["gram"]},"application/srgs+xml":{source:"iana",compressible:!0,extensions:["grxml"]},"application/sru+xml":{source:"iana",compressible:!0,extensions:["sru"]},"application/ssdl+xml":{source:"apache",compressible:!0,extensions:["ssdl"]},"application/ssml+xml":{source:"iana",compressible:!0,extensions:["ssml"]},"application/stix+json":{source:"iana",compressible:!0},"application/swid+xml":{source:"iana",compressible:!0,extensions:["swidtag"]},"application/tamp-apex-update":{source:"iana"},"application/tamp-apex-update-confirm":{source:"iana"},"application/tamp-community-update":{source:"iana"},"application/tamp-community-update-confirm":{source:"iana"},"application/tamp-error":{source:"iana"},"application/tamp-sequence-adjust":{source:"iana"},"application/tamp-sequence-adjust-confirm":{source:"iana"},"application/tamp-status-query":{source:"iana"},"application/tamp-status-response":{source:"iana"},"application/tamp-update":{source:"iana"},"application/tamp-update-confirm":{source:"iana"},"application/tar":{compressible:!0},"application/taxii+json":{source:"iana",compressible:!0},"application/td+json":{source:"iana",compressible:!0},"application/tei+xml":{source:"iana",compressible:!0,extensions:["tei","teicorpus"]},"application/tetra_isi":{source:"iana"},"application/thraud+xml":{source:"iana",compressible:!0,extensions:["tfi"]},"application/timestamp-query":{source:"iana"},"application/timestamp-reply":{source:"iana"},"application/timestamped-data":{source:"iana",extensions:["tsd"]},"application/tlsrpt+gzip":{source:"iana"},"application/tlsrpt+json":{source:"iana",compressible:!0},"application/tnauthlist":{source:"iana"},"application/token-introspection+jwt":{source:"iana"},"application/toml":{compressible:!0,extensions:["toml"]},"application/trickle-ice-sdpfrag":{source:"iana"},"application/trig":{source:"iana",extensions:["trig"]},"application/ttml+xml":{source:"iana",compressible:!0,extensions:["ttml"]},"application/tve-trigger":{source:"iana"},"application/tzif":{source:"iana"},"application/tzif-leap":{source:"iana"},"application/ubjson":{compressible:!1,extensions:["ubj"]},"application/ulpfec":{source:"iana"},"application/urc-grpsheet+xml":{source:"iana",compressible:!0},"application/urc-ressheet+xml":{source:"iana",compressible:!0,extensions:["rsheet"]},"application/urc-targetdesc+xml":{source:"iana",compressible:!0,extensions:["td"]},"application/urc-uisocketdesc+xml":{source:"iana",compressible:!0},"application/vcard+json":{source:"iana",compressible:!0},"application/vcard+xml":{source:"iana",compressible:!0},"application/vemmi":{source:"iana"},"application/vividence.scriptfile":{source:"apache"},"application/vnd.1000minds.decision-model+xml":{source:"iana",compressible:!0,extensions:["1km"]},"application/vnd.3gpp-prose+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-prose-pc3ch+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-v2x-local-service-information":{source:"iana"},"application/vnd.3gpp.5gnas":{source:"iana"},"application/vnd.3gpp.access-transfer-events+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.bsf+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.gmop+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.gtpc":{source:"iana"},"application/vnd.3gpp.interworking-data":{source:"iana"},"application/vnd.3gpp.lpp":{source:"iana"},"application/vnd.3gpp.mc-signalling-ear":{source:"iana"},"application/vnd.3gpp.mcdata-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-payload":{source:"iana"},"application/vnd.3gpp.mcdata-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-signalling":{source:"iana"},"application/vnd.3gpp.mcdata-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-floor-request+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-location-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-mbms-usage-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-signed+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-ue-init-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-affiliation-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-location-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-mbms-usage-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-transmission-request+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mid-call+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.ngap":{source:"iana"},"application/vnd.3gpp.pfcp":{source:"iana"},"application/vnd.3gpp.pic-bw-large":{source:"iana",extensions:["plb"]},"application/vnd.3gpp.pic-bw-small":{source:"iana",extensions:["psb"]},"application/vnd.3gpp.pic-bw-var":{source:"iana",extensions:["pvb"]},"application/vnd.3gpp.s1ap":{source:"iana"},"application/vnd.3gpp.sms":{source:"iana"},"application/vnd.3gpp.sms+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.srvcc-ext+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.srvcc-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.state-and-event-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.ussd+xml":{source:"iana",compressible:!0},"application/vnd.3gpp2.bcmcsinfo+xml":{source:"iana",compressible:!0},"application/vnd.3gpp2.sms":{source:"iana"},"application/vnd.3gpp2.tcap":{source:"iana",extensions:["tcap"]},"application/vnd.3lightssoftware.imagescal":{source:"iana"},"application/vnd.3m.post-it-notes":{source:"iana",extensions:["pwn"]},"application/vnd.accpac.simply.aso":{source:"iana",extensions:["aso"]},"application/vnd.accpac.simply.imp":{source:"iana",extensions:["imp"]},"application/vnd.acucobol":{source:"iana",extensions:["acu"]},"application/vnd.acucorp":{source:"iana",extensions:["atc","acutc"]},"application/vnd.adobe.air-application-installer-package+zip":{source:"apache",compressible:!1,extensions:["air"]},"application/vnd.adobe.flash.movie":{source:"iana"},"application/vnd.adobe.formscentral.fcdt":{source:"iana",extensions:["fcdt"]},"application/vnd.adobe.fxp":{source:"iana",extensions:["fxp","fxpl"]},"application/vnd.adobe.partial-upload":{source:"iana"},"application/vnd.adobe.xdp+xml":{source:"iana",compressible:!0,extensions:["xdp"]},"application/vnd.adobe.xfdf":{source:"iana",extensions:["xfdf"]},"application/vnd.aether.imp":{source:"iana"},"application/vnd.afpc.afplinedata":{source:"iana"},"application/vnd.afpc.afplinedata-pagedef":{source:"iana"},"application/vnd.afpc.cmoca-cmresource":{source:"iana"},"application/vnd.afpc.foca-charset":{source:"iana"},"application/vnd.afpc.foca-codedfont":{source:"iana"},"application/vnd.afpc.foca-codepage":{source:"iana"},"application/vnd.afpc.modca":{source:"iana"},"application/vnd.afpc.modca-cmtable":{source:"iana"},"application/vnd.afpc.modca-formdef":{source:"iana"},"application/vnd.afpc.modca-mediummap":{source:"iana"},"application/vnd.afpc.modca-objectcontainer":{source:"iana"},"application/vnd.afpc.modca-overlay":{source:"iana"},"application/vnd.afpc.modca-pagesegment":{source:"iana"},"application/vnd.age":{source:"iana",extensions:["age"]},"application/vnd.ah-barcode":{source:"iana"},"application/vnd.ahead.space":{source:"iana",extensions:["ahead"]},"application/vnd.airzip.filesecure.azf":{source:"iana",extensions:["azf"]},"application/vnd.airzip.filesecure.azs":{source:"iana",extensions:["azs"]},"application/vnd.amadeus+json":{source:"iana",compressible:!0},"application/vnd.amazon.ebook":{source:"apache",extensions:["azw"]},"application/vnd.amazon.mobi8-ebook":{source:"iana"},"application/vnd.americandynamics.acc":{source:"iana",extensions:["acc"]},"application/vnd.amiga.ami":{source:"iana",extensions:["ami"]},"application/vnd.amundsen.maze+xml":{source:"iana",compressible:!0},"application/vnd.android.ota":{source:"iana"},"application/vnd.android.package-archive":{source:"apache",compressible:!1,extensions:["apk"]},"application/vnd.anki":{source:"iana"},"application/vnd.anser-web-certificate-issue-initiation":{source:"iana",extensions:["cii"]},"application/vnd.anser-web-funds-transfer-initiation":{source:"apache",extensions:["fti"]},"application/vnd.antix.game-component":{source:"iana",extensions:["atx"]},"application/vnd.apache.arrow.file":{source:"iana"},"application/vnd.apache.arrow.stream":{source:"iana"},"application/vnd.apache.thrift.binary":{source:"iana"},"application/vnd.apache.thrift.compact":{source:"iana"},"application/vnd.apache.thrift.json":{source:"iana"},"application/vnd.api+json":{source:"iana",compressible:!0},"application/vnd.aplextor.warrp+json":{source:"iana",compressible:!0},"application/vnd.apothekende.reservation+json":{source:"iana",compressible:!0},"application/vnd.apple.installer+xml":{source:"iana",compressible:!0,extensions:["mpkg"]},"application/vnd.apple.keynote":{source:"iana",extensions:["key"]},"application/vnd.apple.mpegurl":{source:"iana",extensions:["m3u8"]},"application/vnd.apple.numbers":{source:"iana",extensions:["numbers"]},"application/vnd.apple.pages":{source:"iana",extensions:["pages"]},"application/vnd.apple.pkpass":{compressible:!1,extensions:["pkpass"]},"application/vnd.arastra.swi":{source:"iana"},"application/vnd.aristanetworks.swi":{source:"iana",extensions:["swi"]},"application/vnd.artisan+json":{source:"iana",compressible:!0},"application/vnd.artsquare":{source:"iana"},"application/vnd.astraea-software.iota":{source:"iana",extensions:["iota"]},"application/vnd.audiograph":{source:"iana",extensions:["aep"]},"application/vnd.autopackage":{source:"iana"},"application/vnd.avalon+json":{source:"iana",compressible:!0},"application/vnd.avistar+xml":{source:"iana",compressible:!0},"application/vnd.balsamiq.bmml+xml":{source:"iana",compressible:!0,extensions:["bmml"]},"application/vnd.balsamiq.bmpr":{source:"iana"},"application/vnd.banana-accounting":{source:"iana"},"application/vnd.bbf.usp.error":{source:"iana"},"application/vnd.bbf.usp.msg":{source:"iana"},"application/vnd.bbf.usp.msg+json":{source:"iana",compressible:!0},"application/vnd.bekitzur-stech+json":{source:"iana",compressible:!0},"application/vnd.bint.med-content":{source:"iana"},"application/vnd.biopax.rdf+xml":{source:"iana",compressible:!0},"application/vnd.blink-idb-value-wrapper":{source:"iana"},"application/vnd.blueice.multipass":{source:"iana",extensions:["mpm"]},"application/vnd.bluetooth.ep.oob":{source:"iana"},"application/vnd.bluetooth.le.oob":{source:"iana"},"application/vnd.bmi":{source:"iana",extensions:["bmi"]},"application/vnd.bpf":{source:"iana"},"application/vnd.bpf3":{source:"iana"},"application/vnd.businessobjects":{source:"iana",extensions:["rep"]},"application/vnd.byu.uapi+json":{source:"iana",compressible:!0},"application/vnd.cab-jscript":{source:"iana"},"application/vnd.canon-cpdl":{source:"iana"},"application/vnd.canon-lips":{source:"iana"},"application/vnd.capasystems-pg+json":{source:"iana",compressible:!0},"application/vnd.cendio.thinlinc.clientconf":{source:"iana"},"application/vnd.century-systems.tcp_stream":{source:"iana"},"application/vnd.chemdraw+xml":{source:"iana",compressible:!0,extensions:["cdxml"]},"application/vnd.chess-pgn":{source:"iana"},"application/vnd.chipnuts.karaoke-mmd":{source:"iana",extensions:["mmd"]},"application/vnd.ciedi":{source:"iana"},"application/vnd.cinderella":{source:"iana",extensions:["cdy"]},"application/vnd.cirpack.isdn-ext":{source:"iana"},"application/vnd.citationstyles.style+xml":{source:"iana",compressible:!0,extensions:["csl"]},"application/vnd.claymore":{source:"iana",extensions:["cla"]},"application/vnd.cloanto.rp9":{source:"iana",extensions:["rp9"]},"application/vnd.clonk.c4group":{source:"iana",extensions:["c4g","c4d","c4f","c4p","c4u"]},"application/vnd.cluetrust.cartomobile-config":{source:"iana",extensions:["c11amc"]},"application/vnd.cluetrust.cartomobile-config-pkg":{source:"iana",extensions:["c11amz"]},"application/vnd.coffeescript":{source:"iana"},"application/vnd.collabio.xodocuments.document":{source:"iana"},"application/vnd.collabio.xodocuments.document-template":{source:"iana"},"application/vnd.collabio.xodocuments.presentation":{source:"iana"},"application/vnd.collabio.xodocuments.presentation-template":{source:"iana"},"application/vnd.collabio.xodocuments.spreadsheet":{source:"iana"},"application/vnd.collabio.xodocuments.spreadsheet-template":{source:"iana"},"application/vnd.collection+json":{source:"iana",compressible:!0},"application/vnd.collection.doc+json":{source:"iana",compressible:!0},"application/vnd.collection.next+json":{source:"iana",compressible:!0},"application/vnd.comicbook+zip":{source:"iana",compressible:!1},"application/vnd.comicbook-rar":{source:"iana"},"application/vnd.commerce-battelle":{source:"iana"},"application/vnd.commonspace":{source:"iana",extensions:["csp"]},"application/vnd.contact.cmsg":{source:"iana",extensions:["cdbcmsg"]},"application/vnd.coreos.ignition+json":{source:"iana",compressible:!0},"application/vnd.cosmocaller":{source:"iana",extensions:["cmc"]},"application/vnd.crick.clicker":{source:"iana",extensions:["clkx"]},"application/vnd.crick.clicker.keyboard":{source:"iana",extensions:["clkk"]},"application/vnd.crick.clicker.palette":{source:"iana",extensions:["clkp"]},"application/vnd.crick.clicker.template":{source:"iana",extensions:["clkt"]},"application/vnd.crick.clicker.wordbank":{source:"iana",extensions:["clkw"]},"application/vnd.criticaltools.wbs+xml":{source:"iana",compressible:!0,extensions:["wbs"]},"application/vnd.cryptii.pipe+json":{source:"iana",compressible:!0},"application/vnd.crypto-shade-file":{source:"iana"},"application/vnd.cryptomator.encrypted":{source:"iana"},"application/vnd.cryptomator.vault":{source:"iana"},"application/vnd.ctc-posml":{source:"iana",extensions:["pml"]},"application/vnd.ctct.ws+xml":{source:"iana",compressible:!0},"application/vnd.cups-pdf":{source:"iana"},"application/vnd.cups-postscript":{source:"iana"},"application/vnd.cups-ppd":{source:"iana",extensions:["ppd"]},"application/vnd.cups-raster":{source:"iana"},"application/vnd.cups-raw":{source:"iana"},"application/vnd.curl":{source:"iana"},"application/vnd.curl.car":{source:"apache",extensions:["car"]},"application/vnd.curl.pcurl":{source:"apache",extensions:["pcurl"]},"application/vnd.cyan.dean.root+xml":{source:"iana",compressible:!0},"application/vnd.cybank":{source:"iana"},"application/vnd.cyclonedx+json":{source:"iana",compressible:!0},"application/vnd.cyclonedx+xml":{source:"iana",compressible:!0},"application/vnd.d2l.coursepackage1p0+zip":{source:"iana",compressible:!1},"application/vnd.d3m-dataset":{source:"iana"},"application/vnd.d3m-problem":{source:"iana"},"application/vnd.dart":{source:"iana",compressible:!0,extensions:["dart"]},"application/vnd.data-vision.rdz":{source:"iana",extensions:["rdz"]},"application/vnd.datapackage+json":{source:"iana",compressible:!0},"application/vnd.dataresource+json":{source:"iana",compressible:!0},"application/vnd.dbf":{source:"iana",extensions:["dbf"]},"application/vnd.debian.binary-package":{source:"iana"},"application/vnd.dece.data":{source:"iana",extensions:["uvf","uvvf","uvd","uvvd"]},"application/vnd.dece.ttml+xml":{source:"iana",compressible:!0,extensions:["uvt","uvvt"]},"application/vnd.dece.unspecified":{source:"iana",extensions:["uvx","uvvx"]},"application/vnd.dece.zip":{source:"iana",extensions:["uvz","uvvz"]},"application/vnd.denovo.fcselayout-link":{source:"iana",extensions:["fe_launch"]},"application/vnd.desmume.movie":{source:"iana"},"application/vnd.dir-bi.plate-dl-nosuffix":{source:"iana"},"application/vnd.dm.delegation+xml":{source:"iana",compressible:!0},"application/vnd.dna":{source:"iana",extensions:["dna"]},"application/vnd.document+json":{source:"iana",compressible:!0},"application/vnd.dolby.mlp":{source:"apache",extensions:["mlp"]},"application/vnd.dolby.mobile.1":{source:"iana"},"application/vnd.dolby.mobile.2":{source:"iana"},"application/vnd.doremir.scorecloud-binary-document":{source:"iana"},"application/vnd.dpgraph":{source:"iana",extensions:["dpg"]},"application/vnd.dreamfactory":{source:"iana",extensions:["dfac"]},"application/vnd.drive+json":{source:"iana",compressible:!0},"application/vnd.ds-keypoint":{source:"apache",extensions:["kpxx"]},"application/vnd.dtg.local":{source:"iana"},"application/vnd.dtg.local.flash":{source:"iana"},"application/vnd.dtg.local.html":{source:"iana"},"application/vnd.dvb.ait":{source:"iana",extensions:["ait"]},"application/vnd.dvb.dvbisl+xml":{source:"iana",compressible:!0},"application/vnd.dvb.dvbj":{source:"iana"},"application/vnd.dvb.esgcontainer":{source:"iana"},"application/vnd.dvb.ipdcdftnotifaccess":{source:"iana"},"application/vnd.dvb.ipdcesgaccess":{source:"iana"},"application/vnd.dvb.ipdcesgaccess2":{source:"iana"},"application/vnd.dvb.ipdcesgpdd":{source:"iana"},"application/vnd.dvb.ipdcroaming":{source:"iana"},"application/vnd.dvb.iptv.alfec-base":{source:"iana"},"application/vnd.dvb.iptv.alfec-enhancement":{source:"iana"},"application/vnd.dvb.notif-aggregate-root+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-container+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-generic+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-msglist+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-registration-request+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-registration-response+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-init+xml":{source:"iana",compressible:!0},"application/vnd.dvb.pfr":{source:"iana"},"application/vnd.dvb.service":{source:"iana",extensions:["svc"]},"application/vnd.dxr":{source:"iana"},"application/vnd.dynageo":{source:"iana",extensions:["geo"]},"application/vnd.dzr":{source:"iana"},"application/vnd.easykaraoke.cdgdownload":{source:"iana"},"application/vnd.ecdis-update":{source:"iana"},"application/vnd.ecip.rlp":{source:"iana"},"application/vnd.eclipse.ditto+json":{source:"iana",compressible:!0},"application/vnd.ecowin.chart":{source:"iana",extensions:["mag"]},"application/vnd.ecowin.filerequest":{source:"iana"},"application/vnd.ecowin.fileupdate":{source:"iana"},"application/vnd.ecowin.series":{source:"iana"},"application/vnd.ecowin.seriesrequest":{source:"iana"},"application/vnd.ecowin.seriesupdate":{source:"iana"},"application/vnd.efi.img":{source:"iana"},"application/vnd.efi.iso":{source:"iana"},"application/vnd.emclient.accessrequest+xml":{source:"iana",compressible:!0},"application/vnd.enliven":{source:"iana",extensions:["nml"]},"application/vnd.enphase.envoy":{source:"iana"},"application/vnd.eprints.data+xml":{source:"iana",compressible:!0},"application/vnd.epson.esf":{source:"iana",extensions:["esf"]},"application/vnd.epson.msf":{source:"iana",extensions:["msf"]},"application/vnd.epson.quickanime":{source:"iana",extensions:["qam"]},"application/vnd.epson.salt":{source:"iana",extensions:["slt"]},"application/vnd.epson.ssf":{source:"iana",extensions:["ssf"]},"application/vnd.ericsson.quickcall":{source:"iana"},"application/vnd.espass-espass+zip":{source:"iana",compressible:!1},"application/vnd.eszigno3+xml":{source:"iana",compressible:!0,extensions:["es3","et3"]},"application/vnd.etsi.aoc+xml":{source:"iana",compressible:!0},"application/vnd.etsi.asic-e+zip":{source:"iana",compressible:!1},"application/vnd.etsi.asic-s+zip":{source:"iana",compressible:!1},"application/vnd.etsi.cug+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvcommand+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvdiscovery+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvprofile+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-bc+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-cod+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-npvr+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvservice+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsync+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvueprofile+xml":{source:"iana",compressible:!0},"application/vnd.etsi.mcid+xml":{source:"iana",compressible:!0},"application/vnd.etsi.mheg5":{source:"iana"},"application/vnd.etsi.overload-control-policy-dataset+xml":{source:"iana",compressible:!0},"application/vnd.etsi.pstn+xml":{source:"iana",compressible:!0},"application/vnd.etsi.sci+xml":{source:"iana",compressible:!0},"application/vnd.etsi.simservs+xml":{source:"iana",compressible:!0},"application/vnd.etsi.timestamp-token":{source:"iana"},"application/vnd.etsi.tsl+xml":{source:"iana",compressible:!0},"application/vnd.etsi.tsl.der":{source:"iana"},"application/vnd.eu.kasparian.car+json":{source:"iana",compressible:!0},"application/vnd.eudora.data":{source:"iana"},"application/vnd.evolv.ecig.profile":{source:"iana"},"application/vnd.evolv.ecig.settings":{source:"iana"},"application/vnd.evolv.ecig.theme":{source:"iana"},"application/vnd.exstream-empower+zip":{source:"iana",compressible:!1},"application/vnd.exstream-package":{source:"iana"},"application/vnd.ezpix-album":{source:"iana",extensions:["ez2"]},"application/vnd.ezpix-package":{source:"iana",extensions:["ez3"]},"application/vnd.f-secure.mobile":{source:"iana"},"application/vnd.familysearch.gedcom+zip":{source:"iana",compressible:!1},"application/vnd.fastcopy-disk-image":{source:"iana"},"application/vnd.fdf":{source:"iana",extensions:["fdf"]},"application/vnd.fdsn.mseed":{source:"iana",extensions:["mseed"]},"application/vnd.fdsn.seed":{source:"iana",extensions:["seed","dataless"]},"application/vnd.ffsns":{source:"iana"},"application/vnd.ficlab.flb+zip":{source:"iana",compressible:!1},"application/vnd.filmit.zfc":{source:"iana"},"application/vnd.fints":{source:"iana"},"application/vnd.firemonkeys.cloudcell":{source:"iana"},"application/vnd.flographit":{source:"iana",extensions:["gph"]},"application/vnd.fluxtime.clip":{source:"iana",extensions:["ftc"]},"application/vnd.font-fontforge-sfd":{source:"iana"},"application/vnd.framemaker":{source:"iana",extensions:["fm","frame","maker","book"]},"application/vnd.frogans.fnc":{source:"iana",extensions:["fnc"]},"application/vnd.frogans.ltf":{source:"iana",extensions:["ltf"]},"application/vnd.fsc.weblaunch":{source:"iana",extensions:["fsc"]},"application/vnd.fujifilm.fb.docuworks":{source:"iana"},"application/vnd.fujifilm.fb.docuworks.binder":{source:"iana"},"application/vnd.fujifilm.fb.docuworks.container":{source:"iana"},"application/vnd.fujifilm.fb.jfi+xml":{source:"iana",compressible:!0},"application/vnd.fujitsu.oasys":{source:"iana",extensions:["oas"]},"application/vnd.fujitsu.oasys2":{source:"iana",extensions:["oa2"]},"application/vnd.fujitsu.oasys3":{source:"iana",extensions:["oa3"]},"application/vnd.fujitsu.oasysgp":{source:"iana",extensions:["fg5"]},"application/vnd.fujitsu.oasysprs":{source:"iana",extensions:["bh2"]},"application/vnd.fujixerox.art-ex":{source:"iana"},"application/vnd.fujixerox.art4":{source:"iana"},"application/vnd.fujixerox.ddd":{source:"iana",extensions:["ddd"]},"application/vnd.fujixerox.docuworks":{source:"iana",extensions:["xdw"]},"application/vnd.fujixerox.docuworks.binder":{source:"iana",extensions:["xbd"]},"application/vnd.fujixerox.docuworks.container":{source:"iana"},"application/vnd.fujixerox.hbpl":{source:"iana"},"application/vnd.fut-misnet":{source:"iana"},"application/vnd.futoin+cbor":{source:"iana"},"application/vnd.futoin+json":{source:"iana",compressible:!0},"application/vnd.fuzzysheet":{source:"iana",extensions:["fzs"]},"application/vnd.genomatix.tuxedo":{source:"iana",extensions:["txd"]},"application/vnd.gentics.grd+json":{source:"iana",compressible:!0},"application/vnd.geo+json":{source:"iana",compressible:!0},"application/vnd.geocube+xml":{source:"iana",compressible:!0},"application/vnd.geogebra.file":{source:"iana",extensions:["ggb"]},"application/vnd.geogebra.slides":{source:"iana"},"application/vnd.geogebra.tool":{source:"iana",extensions:["ggt"]},"application/vnd.geometry-explorer":{source:"iana",extensions:["gex","gre"]},"application/vnd.geonext":{source:"iana",extensions:["gxt"]},"application/vnd.geoplan":{source:"iana",extensions:["g2w"]},"application/vnd.geospace":{source:"iana",extensions:["g3w"]},"application/vnd.gerber":{source:"iana"},"application/vnd.globalplatform.card-content-mgt":{source:"iana"},"application/vnd.globalplatform.card-content-mgt-response":{source:"iana"},"application/vnd.gmx":{source:"iana",extensions:["gmx"]},"application/vnd.google-apps.document":{compressible:!1,extensions:["gdoc"]},"application/vnd.google-apps.presentation":{compressible:!1,extensions:["gslides"]},"application/vnd.google-apps.spreadsheet":{compressible:!1,extensions:["gsheet"]},"application/vnd.google-earth.kml+xml":{source:"iana",compressible:!0,extensions:["kml"]},"application/vnd.google-earth.kmz":{source:"iana",compressible:!1,extensions:["kmz"]},"application/vnd.gov.sk.e-form+xml":{source:"iana",compressible:!0},"application/vnd.gov.sk.e-form+zip":{source:"iana",compressible:!1},"application/vnd.gov.sk.xmldatacontainer+xml":{source:"iana",compressible:!0},"application/vnd.grafeq":{source:"iana",extensions:["gqf","gqs"]},"application/vnd.gridmp":{source:"iana"},"application/vnd.groove-account":{source:"iana",extensions:["gac"]},"application/vnd.groove-help":{source:"iana",extensions:["ghf"]},"application/vnd.groove-identity-message":{source:"iana",extensions:["gim"]},"application/vnd.groove-injector":{source:"iana",extensions:["grv"]},"application/vnd.groove-tool-message":{source:"iana",extensions:["gtm"]},"application/vnd.groove-tool-template":{source:"iana",extensions:["tpl"]},"application/vnd.groove-vcard":{source:"iana",extensions:["vcg"]},"application/vnd.hal+json":{source:"iana",compressible:!0},"application/vnd.hal+xml":{source:"iana",compressible:!0,extensions:["hal"]},"application/vnd.handheld-entertainment+xml":{source:"iana",compressible:!0,extensions:["zmm"]},"application/vnd.hbci":{source:"iana",extensions:["hbci"]},"application/vnd.hc+json":{source:"iana",compressible:!0},"application/vnd.hcl-bireports":{source:"iana"},"application/vnd.hdt":{source:"iana"},"application/vnd.heroku+json":{source:"iana",compressible:!0},"application/vnd.hhe.lesson-player":{source:"iana",extensions:["les"]},"application/vnd.hl7cda+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.hl7v2+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.hp-hpgl":{source:"iana",extensions:["hpgl"]},"application/vnd.hp-hpid":{source:"iana",extensions:["hpid"]},"application/vnd.hp-hps":{source:"iana",extensions:["hps"]},"application/vnd.hp-jlyt":{source:"iana",extensions:["jlt"]},"application/vnd.hp-pcl":{source:"iana",extensions:["pcl"]},"application/vnd.hp-pclxl":{source:"iana",extensions:["pclxl"]},"application/vnd.httphone":{source:"iana"},"application/vnd.hydrostatix.sof-data":{source:"iana",extensions:["sfd-hdstx"]},"application/vnd.hyper+json":{source:"iana",compressible:!0},"application/vnd.hyper-item+json":{source:"iana",compressible:!0},"application/vnd.hyperdrive+json":{source:"iana",compressible:!0},"application/vnd.hzn-3d-crossword":{source:"iana"},"application/vnd.ibm.afplinedata":{source:"iana"},"application/vnd.ibm.electronic-media":{source:"iana"},"application/vnd.ibm.minipay":{source:"iana",extensions:["mpy"]},"application/vnd.ibm.modcap":{source:"iana",extensions:["afp","listafp","list3820"]},"application/vnd.ibm.rights-management":{source:"iana",extensions:["irm"]},"application/vnd.ibm.secure-container":{source:"iana",extensions:["sc"]},"application/vnd.iccprofile":{source:"iana",extensions:["icc","icm"]},"application/vnd.ieee.1905":{source:"iana"},"application/vnd.igloader":{source:"iana",extensions:["igl"]},"application/vnd.imagemeter.folder+zip":{source:"iana",compressible:!1},"application/vnd.imagemeter.image+zip":{source:"iana",compressible:!1},"application/vnd.immervision-ivp":{source:"iana",extensions:["ivp"]},"application/vnd.immervision-ivu":{source:"iana",extensions:["ivu"]},"application/vnd.ims.imsccv1p1":{source:"iana"},"application/vnd.ims.imsccv1p2":{source:"iana"},"application/vnd.ims.imsccv1p3":{source:"iana"},"application/vnd.ims.lis.v2.result+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolconsumerprofile+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolproxy+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolproxy.id+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolsettings+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolsettings.simple+json":{source:"iana",compressible:!0},"application/vnd.informedcontrol.rms+xml":{source:"iana",compressible:!0},"application/vnd.informix-visionary":{source:"iana"},"application/vnd.infotech.project":{source:"iana"},"application/vnd.infotech.project+xml":{source:"iana",compressible:!0},"application/vnd.innopath.wamp.notification":{source:"iana"},"application/vnd.insors.igm":{source:"iana",extensions:["igm"]},"application/vnd.intercon.formnet":{source:"iana",extensions:["xpw","xpx"]},"application/vnd.intergeo":{source:"iana",extensions:["i2g"]},"application/vnd.intertrust.digibox":{source:"iana"},"application/vnd.intertrust.nncp":{source:"iana"},"application/vnd.intu.qbo":{source:"iana",extensions:["qbo"]},"application/vnd.intu.qfx":{source:"iana",extensions:["qfx"]},"application/vnd.iptc.g2.catalogitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.conceptitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.knowledgeitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.newsitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.newsmessage+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.packageitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.planningitem+xml":{source:"iana",compressible:!0},"application/vnd.ipunplugged.rcprofile":{source:"iana",extensions:["rcprofile"]},"application/vnd.irepository.package+xml":{source:"iana",compressible:!0,extensions:["irp"]},"application/vnd.is-xpr":{source:"iana",extensions:["xpr"]},"application/vnd.isac.fcs":{source:"iana",extensions:["fcs"]},"application/vnd.iso11783-10+zip":{source:"iana",compressible:!1},"application/vnd.jam":{source:"iana",extensions:["jam"]},"application/vnd.japannet-directory-service":{source:"iana"},"application/vnd.japannet-jpnstore-wakeup":{source:"iana"},"application/vnd.japannet-payment-wakeup":{source:"iana"},"application/vnd.japannet-registration":{source:"iana"},"application/vnd.japannet-registration-wakeup":{source:"iana"},"application/vnd.japannet-setstore-wakeup":{source:"iana"},"application/vnd.japannet-verification":{source:"iana"},"application/vnd.japannet-verification-wakeup":{source:"iana"},"application/vnd.jcp.javame.midlet-rms":{source:"iana",extensions:["rms"]},"application/vnd.jisp":{source:"iana",extensions:["jisp"]},"application/vnd.joost.joda-archive":{source:"iana",extensions:["joda"]},"application/vnd.jsk.isdn-ngn":{source:"iana"},"application/vnd.kahootz":{source:"iana",extensions:["ktz","ktr"]},"application/vnd.kde.karbon":{source:"iana",extensions:["karbon"]},"application/vnd.kde.kchart":{source:"iana",extensions:["chrt"]},"application/vnd.kde.kformula":{source:"iana",extensions:["kfo"]},"application/vnd.kde.kivio":{source:"iana",extensions:["flw"]},"application/vnd.kde.kontour":{source:"iana",extensions:["kon"]},"application/vnd.kde.kpresenter":{source:"iana",extensions:["kpr","kpt"]},"application/vnd.kde.kspread":{source:"iana",extensions:["ksp"]},"application/vnd.kde.kword":{source:"iana",extensions:["kwd","kwt"]},"application/vnd.kenameaapp":{source:"iana",extensions:["htke"]},"application/vnd.kidspiration":{source:"iana",extensions:["kia"]},"application/vnd.kinar":{source:"iana",extensions:["kne","knp"]},"application/vnd.koan":{source:"iana",extensions:["skp","skd","skt","skm"]},"application/vnd.kodak-descriptor":{source:"iana",extensions:["sse"]},"application/vnd.las":{source:"iana"},"application/vnd.las.las+json":{source:"iana",compressible:!0},"application/vnd.las.las+xml":{source:"iana",compressible:!0,extensions:["lasxml"]},"application/vnd.laszip":{source:"iana"},"application/vnd.leap+json":{source:"iana",compressible:!0},"application/vnd.liberty-request+xml":{source:"iana",compressible:!0},"application/vnd.llamagraphics.life-balance.desktop":{source:"iana",extensions:["lbd"]},"application/vnd.llamagraphics.life-balance.exchange+xml":{source:"iana",compressible:!0,extensions:["lbe"]},"application/vnd.logipipe.circuit+zip":{source:"iana",compressible:!1},"application/vnd.loom":{source:"iana"},"application/vnd.lotus-1-2-3":{source:"iana",extensions:["123"]},"application/vnd.lotus-approach":{source:"iana",extensions:["apr"]},"application/vnd.lotus-freelance":{source:"iana",extensions:["pre"]},"application/vnd.lotus-notes":{source:"iana",extensions:["nsf"]},"application/vnd.lotus-organizer":{source:"iana",extensions:["org"]},"application/vnd.lotus-screencam":{source:"iana",extensions:["scm"]},"application/vnd.lotus-wordpro":{source:"iana",extensions:["lwp"]},"application/vnd.macports.portpkg":{source:"iana",extensions:["portpkg"]},"application/vnd.mapbox-vector-tile":{source:"iana",extensions:["mvt"]},"application/vnd.marlin.drm.actiontoken+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.conftoken+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.license+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.mdcf":{source:"iana"},"application/vnd.mason+json":{source:"iana",compressible:!0},"application/vnd.maxar.archive.3tz+zip":{source:"iana",compressible:!1},"application/vnd.maxmind.maxmind-db":{source:"iana"},"application/vnd.mcd":{source:"iana",extensions:["mcd"]},"application/vnd.medcalcdata":{source:"iana",extensions:["mc1"]},"application/vnd.mediastation.cdkey":{source:"iana",extensions:["cdkey"]},"application/vnd.meridian-slingshot":{source:"iana"},"application/vnd.mfer":{source:"iana",extensions:["mwf"]},"application/vnd.mfmp":{source:"iana",extensions:["mfm"]},"application/vnd.micro+json":{source:"iana",compressible:!0},"application/vnd.micrografx.flo":{source:"iana",extensions:["flo"]},"application/vnd.micrografx.igx":{source:"iana",extensions:["igx"]},"application/vnd.microsoft.portable-executable":{source:"iana"},"application/vnd.microsoft.windows.thumbnail-cache":{source:"iana"},"application/vnd.miele+json":{source:"iana",compressible:!0},"application/vnd.mif":{source:"iana",extensions:["mif"]},"application/vnd.minisoft-hp3000-save":{source:"iana"},"application/vnd.mitsubishi.misty-guard.trustweb":{source:"iana"},"application/vnd.mobius.daf":{source:"iana",extensions:["daf"]},"application/vnd.mobius.dis":{source:"iana",extensions:["dis"]},"application/vnd.mobius.mbk":{source:"iana",extensions:["mbk"]},"application/vnd.mobius.mqy":{source:"iana",extensions:["mqy"]},"application/vnd.mobius.msl":{source:"iana",extensions:["msl"]},"application/vnd.mobius.plc":{source:"iana",extensions:["plc"]},"application/vnd.mobius.txf":{source:"iana",extensions:["txf"]},"application/vnd.mophun.application":{source:"iana",extensions:["mpn"]},"application/vnd.mophun.certificate":{source:"iana",extensions:["mpc"]},"application/vnd.motorola.flexsuite":{source:"iana"},"application/vnd.motorola.flexsuite.adsi":{source:"iana"},"application/vnd.motorola.flexsuite.fis":{source:"iana"},"application/vnd.motorola.flexsuite.gotap":{source:"iana"},"application/vnd.motorola.flexsuite.kmr":{source:"iana"},"application/vnd.motorola.flexsuite.ttc":{source:"iana"},"application/vnd.motorola.flexsuite.wem":{source:"iana"},"application/vnd.motorola.iprm":{source:"iana"},"application/vnd.mozilla.xul+xml":{source:"iana",compressible:!0,extensions:["xul"]},"application/vnd.ms-3mfdocument":{source:"iana"},"application/vnd.ms-artgalry":{source:"iana",extensions:["cil"]},"application/vnd.ms-asf":{source:"iana"},"application/vnd.ms-cab-compressed":{source:"iana",extensions:["cab"]},"application/vnd.ms-color.iccprofile":{source:"apache"},"application/vnd.ms-excel":{source:"iana",compressible:!1,extensions:["xls","xlm","xla","xlc","xlt","xlw"]},"application/vnd.ms-excel.addin.macroenabled.12":{source:"iana",extensions:["xlam"]},"application/vnd.ms-excel.sheet.binary.macroenabled.12":{source:"iana",extensions:["xlsb"]},"application/vnd.ms-excel.sheet.macroenabled.12":{source:"iana",extensions:["xlsm"]},"application/vnd.ms-excel.template.macroenabled.12":{source:"iana",extensions:["xltm"]},"application/vnd.ms-fontobject":{source:"iana",compressible:!0,extensions:["eot"]},"application/vnd.ms-htmlhelp":{source:"iana",extensions:["chm"]},"application/vnd.ms-ims":{source:"iana",extensions:["ims"]},"application/vnd.ms-lrm":{source:"iana",extensions:["lrm"]},"application/vnd.ms-office.activex+xml":{source:"iana",compressible:!0},"application/vnd.ms-officetheme":{source:"iana",extensions:["thmx"]},"application/vnd.ms-opentype":{source:"apache",compressible:!0},"application/vnd.ms-outlook":{compressible:!1,extensions:["msg"]},"application/vnd.ms-package.obfuscated-opentype":{source:"apache"},"application/vnd.ms-pki.seccat":{source:"apache",extensions:["cat"]},"application/vnd.ms-pki.stl":{source:"apache",extensions:["stl"]},"application/vnd.ms-playready.initiator+xml":{source:"iana",compressible:!0},"application/vnd.ms-powerpoint":{source:"iana",compressible:!1,extensions:["ppt","pps","pot"]},"application/vnd.ms-powerpoint.addin.macroenabled.12":{source:"iana",extensions:["ppam"]},"application/vnd.ms-powerpoint.presentation.macroenabled.12":{source:"iana",extensions:["pptm"]},"application/vnd.ms-powerpoint.slide.macroenabled.12":{source:"iana",extensions:["sldm"]},"application/vnd.ms-powerpoint.slideshow.macroenabled.12":{source:"iana",extensions:["ppsm"]},"application/vnd.ms-powerpoint.template.macroenabled.12":{source:"iana",extensions:["potm"]},"application/vnd.ms-printdevicecapabilities+xml":{source:"iana",compressible:!0},"application/vnd.ms-printing.printticket+xml":{source:"apache",compressible:!0},"application/vnd.ms-printschematicket+xml":{source:"iana",compressible:!0},"application/vnd.ms-project":{source:"iana",extensions:["mpp","mpt"]},"application/vnd.ms-tnef":{source:"iana"},"application/vnd.ms-windows.devicepairing":{source:"iana"},"application/vnd.ms-windows.nwprinting.oob":{source:"iana"},"application/vnd.ms-windows.printerpairing":{source:"iana"},"application/vnd.ms-windows.wsd.oob":{source:"iana"},"application/vnd.ms-wmdrm.lic-chlg-req":{source:"iana"},"application/vnd.ms-wmdrm.lic-resp":{source:"iana"},"application/vnd.ms-wmdrm.meter-chlg-req":{source:"iana"},"application/vnd.ms-wmdrm.meter-resp":{source:"iana"},"application/vnd.ms-word.document.macroenabled.12":{source:"iana",extensions:["docm"]},"application/vnd.ms-word.template.macroenabled.12":{source:"iana",extensions:["dotm"]},"application/vnd.ms-works":{source:"iana",extensions:["wps","wks","wcm","wdb"]},"application/vnd.ms-wpl":{source:"iana",extensions:["wpl"]},"application/vnd.ms-xpsdocument":{source:"iana",compressible:!1,extensions:["xps"]},"application/vnd.msa-disk-image":{source:"iana"},"application/vnd.mseq":{source:"iana",extensions:["mseq"]},"application/vnd.msign":{source:"iana"},"application/vnd.multiad.creator":{source:"iana"},"application/vnd.multiad.creator.cif":{source:"iana"},"application/vnd.music-niff":{source:"iana"},"application/vnd.musician":{source:"iana",extensions:["mus"]},"application/vnd.muvee.style":{source:"iana",extensions:["msty"]},"application/vnd.mynfc":{source:"iana",extensions:["taglet"]},"application/vnd.nacamar.ybrid+json":{source:"iana",compressible:!0},"application/vnd.ncd.control":{source:"iana"},"application/vnd.ncd.reference":{source:"iana"},"application/vnd.nearst.inv+json":{source:"iana",compressible:!0},"application/vnd.nebumind.line":{source:"iana"},"application/vnd.nervana":{source:"iana"},"application/vnd.netfpx":{source:"iana"},"application/vnd.neurolanguage.nlu":{source:"iana",extensions:["nlu"]},"application/vnd.nimn":{source:"iana"},"application/vnd.nintendo.nitro.rom":{source:"iana"},"application/vnd.nintendo.snes.rom":{source:"iana"},"application/vnd.nitf":{source:"iana",extensions:["ntf","nitf"]},"application/vnd.noblenet-directory":{source:"iana",extensions:["nnd"]},"application/vnd.noblenet-sealer":{source:"iana",extensions:["nns"]},"application/vnd.noblenet-web":{source:"iana",extensions:["nnw"]},"application/vnd.nokia.catalogs":{source:"iana"},"application/vnd.nokia.conml+wbxml":{source:"iana"},"application/vnd.nokia.conml+xml":{source:"iana",compressible:!0},"application/vnd.nokia.iptv.config+xml":{source:"iana",compressible:!0},"application/vnd.nokia.isds-radio-presets":{source:"iana"},"application/vnd.nokia.landmark+wbxml":{source:"iana"},"application/vnd.nokia.landmark+xml":{source:"iana",compressible:!0},"application/vnd.nokia.landmarkcollection+xml":{source:"iana",compressible:!0},"application/vnd.nokia.n-gage.ac+xml":{source:"iana",compressible:!0,extensions:["ac"]},"application/vnd.nokia.n-gage.data":{source:"iana",extensions:["ngdat"]},"application/vnd.nokia.n-gage.symbian.install":{source:"iana",extensions:["n-gage"]},"application/vnd.nokia.ncd":{source:"iana"},"application/vnd.nokia.pcd+wbxml":{source:"iana"},"application/vnd.nokia.pcd+xml":{source:"iana",compressible:!0},"application/vnd.nokia.radio-preset":{source:"iana",extensions:["rpst"]},"application/vnd.nokia.radio-presets":{source:"iana",extensions:["rpss"]},"application/vnd.novadigm.edm":{source:"iana",extensions:["edm"]},"application/vnd.novadigm.edx":{source:"iana",extensions:["edx"]},"application/vnd.novadigm.ext":{source:"iana",extensions:["ext"]},"application/vnd.ntt-local.content-share":{source:"iana"},"application/vnd.ntt-local.file-transfer":{source:"iana"},"application/vnd.ntt-local.ogw_remote-access":{source:"iana"},"application/vnd.ntt-local.sip-ta_remote":{source:"iana"},"application/vnd.ntt-local.sip-ta_tcp_stream":{source:"iana"},"application/vnd.oasis.opendocument.chart":{source:"iana",extensions:["odc"]},"application/vnd.oasis.opendocument.chart-template":{source:"iana",extensions:["otc"]},"application/vnd.oasis.opendocument.database":{source:"iana",extensions:["odb"]},"application/vnd.oasis.opendocument.formula":{source:"iana",extensions:["odf"]},"application/vnd.oasis.opendocument.formula-template":{source:"iana",extensions:["odft"]},"application/vnd.oasis.opendocument.graphics":{source:"iana",compressible:!1,extensions:["odg"]},"application/vnd.oasis.opendocument.graphics-template":{source:"iana",extensions:["otg"]},"application/vnd.oasis.opendocument.image":{source:"iana",extensions:["odi"]},"application/vnd.oasis.opendocument.image-template":{source:"iana",extensions:["oti"]},"application/vnd.oasis.opendocument.presentation":{source:"iana",compressible:!1,extensions:["odp"]},"application/vnd.oasis.opendocument.presentation-template":{source:"iana",extensions:["otp"]},"application/vnd.oasis.opendocument.spreadsheet":{source:"iana",compressible:!1,extensions:["ods"]},"application/vnd.oasis.opendocument.spreadsheet-template":{source:"iana",extensions:["ots"]},"application/vnd.oasis.opendocument.text":{source:"iana",compressible:!1,extensions:["odt"]},"application/vnd.oasis.opendocument.text-master":{source:"iana",extensions:["odm"]},"application/vnd.oasis.opendocument.text-template":{source:"iana",extensions:["ott"]},"application/vnd.oasis.opendocument.text-web":{source:"iana",extensions:["oth"]},"application/vnd.obn":{source:"iana"},"application/vnd.ocf+cbor":{source:"iana"},"application/vnd.oci.image.manifest.v1+json":{source:"iana",compressible:!0},"application/vnd.oftn.l10n+json":{source:"iana",compressible:!0},"application/vnd.oipf.contentaccessdownload+xml":{source:"iana",compressible:!0},"application/vnd.oipf.contentaccessstreaming+xml":{source:"iana",compressible:!0},"application/vnd.oipf.cspg-hexbinary":{source:"iana"},"application/vnd.oipf.dae.svg+xml":{source:"iana",compressible:!0},"application/vnd.oipf.dae.xhtml+xml":{source:"iana",compressible:!0},"application/vnd.oipf.mippvcontrolmessage+xml":{source:"iana",compressible:!0},"application/vnd.oipf.pae.gem":{source:"iana"},"application/vnd.oipf.spdiscovery+xml":{source:"iana",compressible:!0},"application/vnd.oipf.spdlist+xml":{source:"iana",compressible:!0},"application/vnd.oipf.ueprofile+xml":{source:"iana",compressible:!0},"application/vnd.oipf.userprofile+xml":{source:"iana",compressible:!0},"application/vnd.olpc-sugar":{source:"iana",extensions:["xo"]},"application/vnd.oma-scws-config":{source:"iana"},"application/vnd.oma-scws-http-request":{source:"iana"},"application/vnd.oma-scws-http-response":{source:"iana"},"application/vnd.oma.bcast.associated-procedure-parameter+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.drm-trigger+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.imd+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.ltkm":{source:"iana"},"application/vnd.oma.bcast.notification+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.provisioningtrigger":{source:"iana"},"application/vnd.oma.bcast.sgboot":{source:"iana"},"application/vnd.oma.bcast.sgdd+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.sgdu":{source:"iana"},"application/vnd.oma.bcast.simple-symbol-container":{source:"iana"},"application/vnd.oma.bcast.smartcard-trigger+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.sprov+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.stkm":{source:"iana"},"application/vnd.oma.cab-address-book+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-feature-handler+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-pcc+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-subs-invite+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-user-prefs+xml":{source:"iana",compressible:!0},"application/vnd.oma.dcd":{source:"iana"},"application/vnd.oma.dcdc":{source:"iana"},"application/vnd.oma.dd2+xml":{source:"iana",compressible:!0,extensions:["dd2"]},"application/vnd.oma.drm.risd+xml":{source:"iana",compressible:!0},"application/vnd.oma.group-usage-list+xml":{source:"iana",compressible:!0},"application/vnd.oma.lwm2m+cbor":{source:"iana"},"application/vnd.oma.lwm2m+json":{source:"iana",compressible:!0},"application/vnd.oma.lwm2m+tlv":{source:"iana"},"application/vnd.oma.pal+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.detailed-progress-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.final-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.groups+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.invocation-descriptor+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.optimized-progress-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.push":{source:"iana"},"application/vnd.oma.scidm.messages+xml":{source:"iana",compressible:!0},"application/vnd.oma.xcap-directory+xml":{source:"iana",compressible:!0},"application/vnd.omads-email+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omads-file+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omads-folder+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omaloc-supl-init":{source:"iana"},"application/vnd.onepager":{source:"iana"},"application/vnd.onepagertamp":{source:"iana"},"application/vnd.onepagertamx":{source:"iana"},"application/vnd.onepagertat":{source:"iana"},"application/vnd.onepagertatp":{source:"iana"},"application/vnd.onepagertatx":{source:"iana"},"application/vnd.openblox.game+xml":{source:"iana",compressible:!0,extensions:["obgx"]},"application/vnd.openblox.game-binary":{source:"iana"},"application/vnd.openeye.oeb":{source:"iana"},"application/vnd.openofficeorg.extension":{source:"apache",extensions:["oxt"]},"application/vnd.openstreetmap.data+xml":{source:"iana",compressible:!0,extensions:["osm"]},"application/vnd.opentimestamps.ots":{source:"iana"},"application/vnd.openxmlformats-officedocument.custom-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.customxmlproperties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawing+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.chart+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramcolors+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramdata+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramlayout+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramstyle+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.extended-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.commentauthors+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.handoutmaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.notesmaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.notesslide+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{source:"iana",compressible:!1,extensions:["pptx"]},"application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.presprops+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slide":{source:"iana",extensions:["sldx"]},"application/vnd.openxmlformats-officedocument.presentationml.slide+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slidelayout+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slidemaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slideshow":{source:"iana",extensions:["ppsx"]},"application/vnd.openxmlformats-officedocument.presentationml.slideshow.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slideupdateinfo+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.tablestyles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.tags+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.template":{source:"iana",extensions:["potx"]},"application/vnd.openxmlformats-officedocument.presentationml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.viewprops+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.calcchain+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.externallink+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcachedefinition+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcacherecords+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivottable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.querytable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionheaders+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionlog+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedstrings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{source:"iana",compressible:!1,extensions:["xlsx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheetmetadata+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.tablesinglecells+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.template":{source:"iana",extensions:["xltx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.usernames+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.volatiledependencies+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.theme+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.themeoverride+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.vmldrawing":{source:"iana"},"application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{source:"iana",compressible:!1,extensions:["docx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.glossary+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.endnotes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.fonttable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.footnotes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.numbering+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.settings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.template":{source:"iana",extensions:["dotx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.websettings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.core-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.digital-signature-xmlsignature+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.relationships+xml":{source:"iana",compressible:!0},"application/vnd.oracle.resource+json":{source:"iana",compressible:!0},"application/vnd.orange.indata":{source:"iana"},"application/vnd.osa.netdeploy":{source:"iana"},"application/vnd.osgeo.mapguide.package":{source:"iana",extensions:["mgp"]},"application/vnd.osgi.bundle":{source:"iana"},"application/vnd.osgi.dp":{source:"iana",extensions:["dp"]},"application/vnd.osgi.subsystem":{source:"iana",extensions:["esa"]},"application/vnd.otps.ct-kip+xml":{source:"iana",compressible:!0},"application/vnd.oxli.countgraph":{source:"iana"},"application/vnd.pagerduty+json":{source:"iana",compressible:!0},"application/vnd.palm":{source:"iana",extensions:["pdb","pqa","oprc"]},"application/vnd.panoply":{source:"iana"},"application/vnd.paos.xml":{source:"iana"},"application/vnd.patentdive":{source:"iana"},"application/vnd.patientecommsdoc":{source:"iana"},"application/vnd.pawaafile":{source:"iana",extensions:["paw"]},"application/vnd.pcos":{source:"iana"},"application/vnd.pg.format":{source:"iana",extensions:["str"]},"application/vnd.pg.osasli":{source:"iana",extensions:["ei6"]},"application/vnd.piaccess.application-licence":{source:"iana"},"application/vnd.picsel":{source:"iana",extensions:["efif"]},"application/vnd.pmi.widget":{source:"iana",extensions:["wg"]},"application/vnd.poc.group-advertisement+xml":{source:"iana",compressible:!0},"application/vnd.pocketlearn":{source:"iana",extensions:["plf"]},"application/vnd.powerbuilder6":{source:"iana",extensions:["pbd"]},"application/vnd.powerbuilder6-s":{source:"iana"},"application/vnd.powerbuilder7":{source:"iana"},"application/vnd.powerbuilder7-s":{source:"iana"},"application/vnd.powerbuilder75":{source:"iana"},"application/vnd.powerbuilder75-s":{source:"iana"},"application/vnd.preminet":{source:"iana"},"application/vnd.previewsystems.box":{source:"iana",extensions:["box"]},"application/vnd.proteus.magazine":{source:"iana",extensions:["mgz"]},"application/vnd.psfs":{source:"iana"},"application/vnd.publishare-delta-tree":{source:"iana",extensions:["qps"]},"application/vnd.pvi.ptid1":{source:"iana",extensions:["ptid"]},"application/vnd.pwg-multiplexed":{source:"iana"},"application/vnd.pwg-xhtml-print+xml":{source:"iana",compressible:!0},"application/vnd.qualcomm.brew-app-res":{source:"iana"},"application/vnd.quarantainenet":{source:"iana"},"application/vnd.quark.quarkxpress":{source:"iana",extensions:["qxd","qxt","qwd","qwt","qxl","qxb"]},"application/vnd.quobject-quoxdocument":{source:"iana"},"application/vnd.radisys.moml+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-conf+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-conn+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-dialog+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-stream+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-conf+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-base+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-fax-detect+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-fax-sendrecv+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-group+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-speech+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-transform+xml":{source:"iana",compressible:!0},"application/vnd.rainstor.data":{source:"iana"},"application/vnd.rapid":{source:"iana"},"application/vnd.rar":{source:"iana",extensions:["rar"]},"application/vnd.realvnc.bed":{source:"iana",extensions:["bed"]},"application/vnd.recordare.musicxml":{source:"iana",extensions:["mxl"]},"application/vnd.recordare.musicxml+xml":{source:"iana",compressible:!0,extensions:["musicxml"]},"application/vnd.renlearn.rlprint":{source:"iana"},"application/vnd.resilient.logic":{source:"iana"},"application/vnd.restful+json":{source:"iana",compressible:!0},"application/vnd.rig.cryptonote":{source:"iana",extensions:["cryptonote"]},"application/vnd.rim.cod":{source:"apache",extensions:["cod"]},"application/vnd.rn-realmedia":{source:"apache",extensions:["rm"]},"application/vnd.rn-realmedia-vbr":{source:"apache",extensions:["rmvb"]},"application/vnd.route66.link66+xml":{source:"iana",compressible:!0,extensions:["link66"]},"application/vnd.rs-274x":{source:"iana"},"application/vnd.ruckus.download":{source:"iana"},"application/vnd.s3sms":{source:"iana"},"application/vnd.sailingtracker.track":{source:"iana",extensions:["st"]},"application/vnd.sar":{source:"iana"},"application/vnd.sbm.cid":{source:"iana"},"application/vnd.sbm.mid2":{source:"iana"},"application/vnd.scribus":{source:"iana"},"application/vnd.sealed.3df":{source:"iana"},"application/vnd.sealed.csf":{source:"iana"},"application/vnd.sealed.doc":{source:"iana"},"application/vnd.sealed.eml":{source:"iana"},"application/vnd.sealed.mht":{source:"iana"},"application/vnd.sealed.net":{source:"iana"},"application/vnd.sealed.ppt":{source:"iana"},"application/vnd.sealed.tiff":{source:"iana"},"application/vnd.sealed.xls":{source:"iana"},"application/vnd.sealedmedia.softseal.html":{source:"iana"},"application/vnd.sealedmedia.softseal.pdf":{source:"iana"},"application/vnd.seemail":{source:"iana",extensions:["see"]},"application/vnd.seis+json":{source:"iana",compressible:!0},"application/vnd.sema":{source:"iana",extensions:["sema"]},"application/vnd.semd":{source:"iana",extensions:["semd"]},"application/vnd.semf":{source:"iana",extensions:["semf"]},"application/vnd.shade-save-file":{source:"iana"},"application/vnd.shana.informed.formdata":{source:"iana",extensions:["ifm"]},"application/vnd.shana.informed.formtemplate":{source:"iana",extensions:["itp"]},"application/vnd.shana.informed.interchange":{source:"iana",extensions:["iif"]},"application/vnd.shana.informed.package":{source:"iana",extensions:["ipk"]},"application/vnd.shootproof+json":{source:"iana",compressible:!0},"application/vnd.shopkick+json":{source:"iana",compressible:!0},"application/vnd.shp":{source:"iana"},"application/vnd.shx":{source:"iana"},"application/vnd.sigrok.session":{source:"iana"},"application/vnd.simtech-mindmapper":{source:"iana",extensions:["twd","twds"]},"application/vnd.siren+json":{source:"iana",compressible:!0},"application/vnd.smaf":{source:"iana",extensions:["mmf"]},"application/vnd.smart.notebook":{source:"iana"},"application/vnd.smart.teacher":{source:"iana",extensions:["teacher"]},"application/vnd.snesdev-page-table":{source:"iana"},"application/vnd.software602.filler.form+xml":{source:"iana",compressible:!0,extensions:["fo"]},"application/vnd.software602.filler.form-xml-zip":{source:"iana"},"application/vnd.solent.sdkm+xml":{source:"iana",compressible:!0,extensions:["sdkm","sdkd"]},"application/vnd.spotfire.dxp":{source:"iana",extensions:["dxp"]},"application/vnd.spotfire.sfs":{source:"iana",extensions:["sfs"]},"application/vnd.sqlite3":{source:"iana"},"application/vnd.sss-cod":{source:"iana"},"application/vnd.sss-dtf":{source:"iana"},"application/vnd.sss-ntf":{source:"iana"},"application/vnd.stardivision.calc":{source:"apache",extensions:["sdc"]},"application/vnd.stardivision.draw":{source:"apache",extensions:["sda"]},"application/vnd.stardivision.impress":{source:"apache",extensions:["sdd"]},"application/vnd.stardivision.math":{source:"apache",extensions:["smf"]},"application/vnd.stardivision.writer":{source:"apache",extensions:["sdw","vor"]},"application/vnd.stardivision.writer-global":{source:"apache",extensions:["sgl"]},"application/vnd.stepmania.package":{source:"iana",extensions:["smzip"]},"application/vnd.stepmania.stepchart":{source:"iana",extensions:["sm"]},"application/vnd.street-stream":{source:"iana"},"application/vnd.sun.wadl+xml":{source:"iana",compressible:!0,extensions:["wadl"]},"application/vnd.sun.xml.calc":{source:"apache",extensions:["sxc"]},"application/vnd.sun.xml.calc.template":{source:"apache",extensions:["stc"]},"application/vnd.sun.xml.draw":{source:"apache",extensions:["sxd"]},"application/vnd.sun.xml.draw.template":{source:"apache",extensions:["std"]},"application/vnd.sun.xml.impress":{source:"apache",extensions:["sxi"]},"application/vnd.sun.xml.impress.template":{source:"apache",extensions:["sti"]},"application/vnd.sun.xml.math":{source:"apache",extensions:["sxm"]},"application/vnd.sun.xml.writer":{source:"apache",extensions:["sxw"]},"application/vnd.sun.xml.writer.global":{source:"apache",extensions:["sxg"]},"application/vnd.sun.xml.writer.template":{source:"apache",extensions:["stw"]},"application/vnd.sus-calendar":{source:"iana",extensions:["sus","susp"]},"application/vnd.svd":{source:"iana",extensions:["svd"]},"application/vnd.swiftview-ics":{source:"iana"},"application/vnd.sycle+xml":{source:"iana",compressible:!0},"application/vnd.syft+json":{source:"iana",compressible:!0},"application/vnd.symbian.install":{source:"apache",extensions:["sis","sisx"]},"application/vnd.syncml+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["xsm"]},"application/vnd.syncml.dm+wbxml":{source:"iana",charset:"UTF-8",extensions:["bdm"]},"application/vnd.syncml.dm+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["xdm"]},"application/vnd.syncml.dm.notification":{source:"iana"},"application/vnd.syncml.dmddf+wbxml":{source:"iana"},"application/vnd.syncml.dmddf+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["ddf"]},"application/vnd.syncml.dmtnds+wbxml":{source:"iana"},"application/vnd.syncml.dmtnds+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.syncml.ds.notification":{source:"iana"},"application/vnd.tableschema+json":{source:"iana",compressible:!0},"application/vnd.tao.intent-module-archive":{source:"iana",extensions:["tao"]},"application/vnd.tcpdump.pcap":{source:"iana",extensions:["pcap","cap","dmp"]},"application/vnd.think-cell.ppttc+json":{source:"iana",compressible:!0},"application/vnd.tmd.mediaflex.api+xml":{source:"iana",compressible:!0},"application/vnd.tml":{source:"iana"},"application/vnd.tmobile-livetv":{source:"iana",extensions:["tmo"]},"application/vnd.tri.onesource":{source:"iana"},"application/vnd.trid.tpt":{source:"iana",extensions:["tpt"]},"application/vnd.triscape.mxs":{source:"iana",extensions:["mxs"]},"application/vnd.trueapp":{source:"iana",extensions:["tra"]},"application/vnd.truedoc":{source:"iana"},"application/vnd.ubisoft.webplayer":{source:"iana"},"application/vnd.ufdl":{source:"iana",extensions:["ufd","ufdl"]},"application/vnd.uiq.theme":{source:"iana",extensions:["utz"]},"application/vnd.umajin":{source:"iana",extensions:["umj"]},"application/vnd.unity":{source:"iana",extensions:["unityweb"]},"application/vnd.uoml+xml":{source:"iana",compressible:!0,extensions:["uoml"]},"application/vnd.uplanet.alert":{source:"iana"},"application/vnd.uplanet.alert-wbxml":{source:"iana"},"application/vnd.uplanet.bearer-choice":{source:"iana"},"application/vnd.uplanet.bearer-choice-wbxml":{source:"iana"},"application/vnd.uplanet.cacheop":{source:"iana"},"application/vnd.uplanet.cacheop-wbxml":{source:"iana"},"application/vnd.uplanet.channel":{source:"iana"},"application/vnd.uplanet.channel-wbxml":{source:"iana"},"application/vnd.uplanet.list":{source:"iana"},"application/vnd.uplanet.list-wbxml":{source:"iana"},"application/vnd.uplanet.listcmd":{source:"iana"},"application/vnd.uplanet.listcmd-wbxml":{source:"iana"},"application/vnd.uplanet.signal":{source:"iana"},"application/vnd.uri-map":{source:"iana"},"application/vnd.valve.source.material":{source:"iana"},"application/vnd.vcx":{source:"iana",extensions:["vcx"]},"application/vnd.vd-study":{source:"iana"},"application/vnd.vectorworks":{source:"iana"},"application/vnd.vel+json":{source:"iana",compressible:!0},"application/vnd.verimatrix.vcas":{source:"iana"},"application/vnd.veritone.aion+json":{source:"iana",compressible:!0},"application/vnd.veryant.thin":{source:"iana"},"application/vnd.ves.encrypted":{source:"iana"},"application/vnd.vidsoft.vidconference":{source:"iana"},"application/vnd.visio":{source:"iana",extensions:["vsd","vst","vss","vsw"]},"application/vnd.visionary":{source:"iana",extensions:["vis"]},"application/vnd.vividence.scriptfile":{source:"iana"},"application/vnd.vsf":{source:"iana",extensions:["vsf"]},"application/vnd.wap.sic":{source:"iana"},"application/vnd.wap.slc":{source:"iana"},"application/vnd.wap.wbxml":{source:"iana",charset:"UTF-8",extensions:["wbxml"]},"application/vnd.wap.wmlc":{source:"iana",extensions:["wmlc"]},"application/vnd.wap.wmlscriptc":{source:"iana",extensions:["wmlsc"]},"application/vnd.webturbo":{source:"iana",extensions:["wtb"]},"application/vnd.wfa.dpp":{source:"iana"},"application/vnd.wfa.p2p":{source:"iana"},"application/vnd.wfa.wsc":{source:"iana"},"application/vnd.windows.devicepairing":{source:"iana"},"application/vnd.wmc":{source:"iana"},"application/vnd.wmf.bootstrap":{source:"iana"},"application/vnd.wolfram.mathematica":{source:"iana"},"application/vnd.wolfram.mathematica.package":{source:"iana"},"application/vnd.wolfram.player":{source:"iana",extensions:["nbp"]},"application/vnd.wordperfect":{source:"iana",extensions:["wpd"]},"application/vnd.wqd":{source:"iana",extensions:["wqd"]},"application/vnd.wrq-hp3000-labelled":{source:"iana"},"application/vnd.wt.stf":{source:"iana",extensions:["stf"]},"application/vnd.wv.csp+wbxml":{source:"iana"},"application/vnd.wv.csp+xml":{source:"iana",compressible:!0},"application/vnd.wv.ssp+xml":{source:"iana",compressible:!0},"application/vnd.xacml+json":{source:"iana",compressible:!0},"application/vnd.xara":{source:"iana",extensions:["xar"]},"application/vnd.xfdl":{source:"iana",extensions:["xfdl"]},"application/vnd.xfdl.webform":{source:"iana"},"application/vnd.xmi+xml":{source:"iana",compressible:!0},"application/vnd.xmpie.cpkg":{source:"iana"},"application/vnd.xmpie.dpkg":{source:"iana"},"application/vnd.xmpie.plan":{source:"iana"},"application/vnd.xmpie.ppkg":{source:"iana"},"application/vnd.xmpie.xlim":{source:"iana"},"application/vnd.yamaha.hv-dic":{source:"iana",extensions:["hvd"]},"application/vnd.yamaha.hv-script":{source:"iana",extensions:["hvs"]},"application/vnd.yamaha.hv-voice":{source:"iana",extensions:["hvp"]},"application/vnd.yamaha.openscoreformat":{source:"iana",extensions:["osf"]},"application/vnd.yamaha.openscoreformat.osfpvg+xml":{source:"iana",compressible:!0,extensions:["osfpvg"]},"application/vnd.yamaha.remote-setup":{source:"iana"},"application/vnd.yamaha.smaf-audio":{source:"iana",extensions:["saf"]},"application/vnd.yamaha.smaf-phrase":{source:"iana",extensions:["spf"]},"application/vnd.yamaha.through-ngn":{source:"iana"},"application/vnd.yamaha.tunnel-udpencap":{source:"iana"},"application/vnd.yaoweme":{source:"iana"},"application/vnd.yellowriver-custom-menu":{source:"iana",extensions:["cmp"]},"application/vnd.youtube.yt":{source:"iana"},"application/vnd.zul":{source:"iana",extensions:["zir","zirz"]},"application/vnd.zzazz.deck+xml":{source:"iana",compressible:!0,extensions:["zaz"]},"application/voicexml+xml":{source:"iana",compressible:!0,extensions:["vxml"]},"application/voucher-cms+json":{source:"iana",compressible:!0},"application/vq-rtcpxr":{source:"iana"},"application/wasm":{source:"iana",compressible:!0,extensions:["wasm"]},"application/watcherinfo+xml":{source:"iana",compressible:!0,extensions:["wif"]},"application/webpush-options+json":{source:"iana",compressible:!0},"application/whoispp-query":{source:"iana"},"application/whoispp-response":{source:"iana"},"application/widget":{source:"iana",extensions:["wgt"]},"application/winhlp":{source:"apache",extensions:["hlp"]},"application/wita":{source:"iana"},"application/wordperfect5.1":{source:"iana"},"application/wsdl+xml":{source:"iana",compressible:!0,extensions:["wsdl"]},"application/wspolicy+xml":{source:"iana",compressible:!0,extensions:["wspolicy"]},"application/x-7z-compressed":{source:"apache",compressible:!1,extensions:["7z"]},"application/x-abiword":{source:"apache",extensions:["abw"]},"application/x-ace-compressed":{source:"apache",extensions:["ace"]},"application/x-amf":{source:"apache"},"application/x-apple-diskimage":{source:"apache",extensions:["dmg"]},"application/x-arj":{compressible:!1,extensions:["arj"]},"application/x-authorware-bin":{source:"apache",extensions:["aab","x32","u32","vox"]},"application/x-authorware-map":{source:"apache",extensions:["aam"]},"application/x-authorware-seg":{source:"apache",extensions:["aas"]},"application/x-bcpio":{source:"apache",extensions:["bcpio"]},"application/x-bdoc":{compressible:!1,extensions:["bdoc"]},"application/x-bittorrent":{source:"apache",extensions:["torrent"]},"application/x-blorb":{source:"apache",extensions:["blb","blorb"]},"application/x-bzip":{source:"apache",compressible:!1,extensions:["bz"]},"application/x-bzip2":{source:"apache",compressible:!1,extensions:["bz2","boz"]},"application/x-cbr":{source:"apache",extensions:["cbr","cba","cbt","cbz","cb7"]},"application/x-cdlink":{source:"apache",extensions:["vcd"]},"application/x-cfs-compressed":{source:"apache",extensions:["cfs"]},"application/x-chat":{source:"apache",extensions:["chat"]},"application/x-chess-pgn":{source:"apache",extensions:["pgn"]},"application/x-chrome-extension":{extensions:["crx"]},"application/x-cocoa":{source:"nginx",extensions:["cco"]},"application/x-compress":{source:"apache"},"application/x-conference":{source:"apache",extensions:["nsc"]},"application/x-cpio":{source:"apache",extensions:["cpio"]},"application/x-csh":{source:"apache",extensions:["csh"]},"application/x-deb":{compressible:!1},"application/x-debian-package":{source:"apache",extensions:["deb","udeb"]},"application/x-dgc-compressed":{source:"apache",extensions:["dgc"]},"application/x-director":{source:"apache",extensions:["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"]},"application/x-doom":{source:"apache",extensions:["wad"]},"application/x-dtbncx+xml":{source:"apache",compressible:!0,extensions:["ncx"]},"application/x-dtbook+xml":{source:"apache",compressible:!0,extensions:["dtb"]},"application/x-dtbresource+xml":{source:"apache",compressible:!0,extensions:["res"]},"application/x-dvi":{source:"apache",compressible:!1,extensions:["dvi"]},"application/x-envoy":{source:"apache",extensions:["evy"]},"application/x-eva":{source:"apache",extensions:["eva"]},"application/x-font-bdf":{source:"apache",extensions:["bdf"]},"application/x-font-dos":{source:"apache"},"application/x-font-framemaker":{source:"apache"},"application/x-font-ghostscript":{source:"apache",extensions:["gsf"]},"application/x-font-libgrx":{source:"apache"},"application/x-font-linux-psf":{source:"apache",extensions:["psf"]},"application/x-font-pcf":{source:"apache",extensions:["pcf"]},"application/x-font-snf":{source:"apache",extensions:["snf"]},"application/x-font-speedo":{source:"apache"},"application/x-font-sunos-news":{source:"apache"},"application/x-font-type1":{source:"apache",extensions:["pfa","pfb","pfm","afm"]},"application/x-font-vfont":{source:"apache"},"application/x-freearc":{source:"apache",extensions:["arc"]},"application/x-futuresplash":{source:"apache",extensions:["spl"]},"application/x-gca-compressed":{source:"apache",extensions:["gca"]},"application/x-glulx":{source:"apache",extensions:["ulx"]},"application/x-gnumeric":{source:"apache",extensions:["gnumeric"]},"application/x-gramps-xml":{source:"apache",extensions:["gramps"]},"application/x-gtar":{source:"apache",extensions:["gtar"]},"application/x-gzip":{source:"apache"},"application/x-hdf":{source:"apache",extensions:["hdf"]},"application/x-httpd-php":{compressible:!0,extensions:["php"]},"application/x-install-instructions":{source:"apache",extensions:["install"]},"application/x-iso9660-image":{source:"apache",extensions:["iso"]},"application/x-iwork-keynote-sffkey":{extensions:["key"]},"application/x-iwork-numbers-sffnumbers":{extensions:["numbers"]},"application/x-iwork-pages-sffpages":{extensions:["pages"]},"application/x-java-archive-diff":{source:"nginx",extensions:["jardiff"]},"application/x-java-jnlp-file":{source:"apache",compressible:!1,extensions:["jnlp"]},"application/x-javascript":{compressible:!0},"application/x-keepass2":{extensions:["kdbx"]},"application/x-latex":{source:"apache",compressible:!1,extensions:["latex"]},"application/x-lua-bytecode":{extensions:["luac"]},"application/x-lzh-compressed":{source:"apache",extensions:["lzh","lha"]},"application/x-makeself":{source:"nginx",extensions:["run"]},"application/x-mie":{source:"apache",extensions:["mie"]},"application/x-mobipocket-ebook":{source:"apache",extensions:["prc","mobi"]},"application/x-mpegurl":{compressible:!1},"application/x-ms-application":{source:"apache",extensions:["application"]},"application/x-ms-shortcut":{source:"apache",extensions:["lnk"]},"application/x-ms-wmd":{source:"apache",extensions:["wmd"]},"application/x-ms-wmz":{source:"apache",extensions:["wmz"]},"application/x-ms-xbap":{source:"apache",extensions:["xbap"]},"application/x-msaccess":{source:"apache",extensions:["mdb"]},"application/x-msbinder":{source:"apache",extensions:["obd"]},"application/x-mscardfile":{source:"apache",extensions:["crd"]},"application/x-msclip":{source:"apache",extensions:["clp"]},"application/x-msdos-program":{extensions:["exe"]},"application/x-msdownload":{source:"apache",extensions:["exe","dll","com","bat","msi"]},"application/x-msmediaview":{source:"apache",extensions:["mvb","m13","m14"]},"application/x-msmetafile":{source:"apache",extensions:["wmf","wmz","emf","emz"]},"application/x-msmoney":{source:"apache",extensions:["mny"]},"application/x-mspublisher":{source:"apache",extensions:["pub"]},"application/x-msschedule":{source:"apache",extensions:["scd"]},"application/x-msterminal":{source:"apache",extensions:["trm"]},"application/x-mswrite":{source:"apache",extensions:["wri"]},"application/x-netcdf":{source:"apache",extensions:["nc","cdf"]},"application/x-ns-proxy-autoconfig":{compressible:!0,extensions:["pac"]},"application/x-nzb":{source:"apache",extensions:["nzb"]},"application/x-perl":{source:"nginx",extensions:["pl","pm"]},"application/x-pilot":{source:"nginx",extensions:["prc","pdb"]},"application/x-pkcs12":{source:"apache",compressible:!1,extensions:["p12","pfx"]},"application/x-pkcs7-certificates":{source:"apache",extensions:["p7b","spc"]},"application/x-pkcs7-certreqresp":{source:"apache",extensions:["p7r"]},"application/x-pki-message":{source:"iana"},"application/x-rar-compressed":{source:"apache",compressible:!1,extensions:["rar"]},"application/x-redhat-package-manager":{source:"nginx",extensions:["rpm"]},"application/x-research-info-systems":{source:"apache",extensions:["ris"]},"application/x-sea":{source:"nginx",extensions:["sea"]},"application/x-sh":{source:"apache",compressible:!0,extensions:["sh"]},"application/x-shar":{source:"apache",extensions:["shar"]},"application/x-shockwave-flash":{source:"apache",compressible:!1,extensions:["swf"]},"application/x-silverlight-app":{source:"apache",extensions:["xap"]},"application/x-sql":{source:"apache",extensions:["sql"]},"application/x-stuffit":{source:"apache",compressible:!1,extensions:["sit"]},"application/x-stuffitx":{source:"apache",extensions:["sitx"]},"application/x-subrip":{source:"apache",extensions:["srt"]},"application/x-sv4cpio":{source:"apache",extensions:["sv4cpio"]},"application/x-sv4crc":{source:"apache",extensions:["sv4crc"]},"application/x-t3vm-image":{source:"apache",extensions:["t3"]},"application/x-tads":{source:"apache",extensions:["gam"]},"application/x-tar":{source:"apache",compressible:!0,extensions:["tar"]},"application/x-tcl":{source:"apache",extensions:["tcl","tk"]},"application/x-tex":{source:"apache",extensions:["tex"]},"application/x-tex-tfm":{source:"apache",extensions:["tfm"]},"application/x-texinfo":{source:"apache",extensions:["texinfo","texi"]},"application/x-tgif":{source:"apache",extensions:["obj"]},"application/x-ustar":{source:"apache",extensions:["ustar"]},"application/x-virtualbox-hdd":{compressible:!0,extensions:["hdd"]},"application/x-virtualbox-ova":{compressible:!0,extensions:["ova"]},"application/x-virtualbox-ovf":{compressible:!0,extensions:["ovf"]},"application/x-virtualbox-vbox":{compressible:!0,extensions:["vbox"]},"application/x-virtualbox-vbox-extpack":{compressible:!1,extensions:["vbox-extpack"]},"application/x-virtualbox-vdi":{compressible:!0,extensions:["vdi"]},"application/x-virtualbox-vhd":{compressible:!0,extensions:["vhd"]},"application/x-virtualbox-vmdk":{compressible:!0,extensions:["vmdk"]},"application/x-wais-source":{source:"apache",extensions:["src"]},"application/x-web-app-manifest+json":{compressible:!0,extensions:["webapp"]},"application/x-www-form-urlencoded":{source:"iana",compressible:!0},"application/x-x509-ca-cert":{source:"iana",extensions:["der","crt","pem"]},"application/x-x509-ca-ra-cert":{source:"iana"},"application/x-x509-next-ca-cert":{source:"iana"},"application/x-xfig":{source:"apache",extensions:["fig"]},"application/x-xliff+xml":{source:"apache",compressible:!0,extensions:["xlf"]},"application/x-xpinstall":{source:"apache",compressible:!1,extensions:["xpi"]},"application/x-xz":{source:"apache",extensions:["xz"]},"application/x-zmachine":{source:"apache",extensions:["z1","z2","z3","z4","z5","z6","z7","z8"]},"application/x400-bp":{source:"iana"},"application/xacml+xml":{source:"iana",compressible:!0},"application/xaml+xml":{source:"apache",compressible:!0,extensions:["xaml"]},"application/xcap-att+xml":{source:"iana",compressible:!0,extensions:["xav"]},"application/xcap-caps+xml":{source:"iana",compressible:!0,extensions:["xca"]},"application/xcap-diff+xml":{source:"iana",compressible:!0,extensions:["xdf"]},"application/xcap-el+xml":{source:"iana",compressible:!0,extensions:["xel"]},"application/xcap-error+xml":{source:"iana",compressible:!0},"application/xcap-ns+xml":{source:"iana",compressible:!0,extensions:["xns"]},"application/xcon-conference-info+xml":{source:"iana",compressible:!0},"application/xcon-conference-info-diff+xml":{source:"iana",compressible:!0},"application/xenc+xml":{source:"iana",compressible:!0,extensions:["xenc"]},"application/xhtml+xml":{source:"iana",compressible:!0,extensions:["xhtml","xht"]},"application/xhtml-voice+xml":{source:"apache",compressible:!0},"application/xliff+xml":{source:"iana",compressible:!0,extensions:["xlf"]},"application/xml":{source:"iana",compressible:!0,extensions:["xml","xsl","xsd","rng"]},"application/xml-dtd":{source:"iana",compressible:!0,extensions:["dtd"]},"application/xml-external-parsed-entity":{source:"iana"},"application/xml-patch+xml":{source:"iana",compressible:!0},"application/xmpp+xml":{source:"iana",compressible:!0},"application/xop+xml":{source:"iana",compressible:!0,extensions:["xop"]},"application/xproc+xml":{source:"apache",compressible:!0,extensions:["xpl"]},"application/xslt+xml":{source:"iana",compressible:!0,extensions:["xsl","xslt"]},"application/xspf+xml":{source:"apache",compressible:!0,extensions:["xspf"]},"application/xv+xml":{source:"iana",compressible:!0,extensions:["mxml","xhvml","xvml","xvm"]},"application/yang":{source:"iana",extensions:["yang"]},"application/yang-data+json":{source:"iana",compressible:!0},"application/yang-data+xml":{source:"iana",compressible:!0},"application/yang-patch+json":{source:"iana",compressible:!0},"application/yang-patch+xml":{source:"iana",compressible:!0},"application/yin+xml":{source:"iana",compressible:!0,extensions:["yin"]},"application/zip":{source:"iana",compressible:!1,extensions:["zip"]},"application/zlib":{source:"iana"},"application/zstd":{source:"iana"},"audio/1d-interleaved-parityfec":{source:"iana"},"audio/32kadpcm":{source:"iana"},"audio/3gpp":{source:"iana",compressible:!1,extensions:["3gpp"]},"audio/3gpp2":{source:"iana"},"audio/aac":{source:"iana"},"audio/ac3":{source:"iana"},"audio/adpcm":{source:"apache",extensions:["adp"]},"audio/amr":{source:"iana",extensions:["amr"]},"audio/amr-wb":{source:"iana"},"audio/amr-wb+":{source:"iana"},"audio/aptx":{source:"iana"},"audio/asc":{source:"iana"},"audio/atrac-advanced-lossless":{source:"iana"},"audio/atrac-x":{source:"iana"},"audio/atrac3":{source:"iana"},"audio/basic":{source:"iana",compressible:!1,extensions:["au","snd"]},"audio/bv16":{source:"iana"},"audio/bv32":{source:"iana"},"audio/clearmode":{source:"iana"},"audio/cn":{source:"iana"},"audio/dat12":{source:"iana"},"audio/dls":{source:"iana"},"audio/dsr-es201108":{source:"iana"},"audio/dsr-es202050":{source:"iana"},"audio/dsr-es202211":{source:"iana"},"audio/dsr-es202212":{source:"iana"},"audio/dv":{source:"iana"},"audio/dvi4":{source:"iana"},"audio/eac3":{source:"iana"},"audio/encaprtp":{source:"iana"},"audio/evrc":{source:"iana"},"audio/evrc-qcp":{source:"iana"},"audio/evrc0":{source:"iana"},"audio/evrc1":{source:"iana"},"audio/evrcb":{source:"iana"},"audio/evrcb0":{source:"iana"},"audio/evrcb1":{source:"iana"},"audio/evrcnw":{source:"iana"},"audio/evrcnw0":{source:"iana"},"audio/evrcnw1":{source:"iana"},"audio/evrcwb":{source:"iana"},"audio/evrcwb0":{source:"iana"},"audio/evrcwb1":{source:"iana"},"audio/evs":{source:"iana"},"audio/flexfec":{source:"iana"},"audio/fwdred":{source:"iana"},"audio/g711-0":{source:"iana"},"audio/g719":{source:"iana"},"audio/g722":{source:"iana"},"audio/g7221":{source:"iana"},"audio/g723":{source:"iana"},"audio/g726-16":{source:"iana"},"audio/g726-24":{source:"iana"},"audio/g726-32":{source:"iana"},"audio/g726-40":{source:"iana"},"audio/g728":{source:"iana"},"audio/g729":{source:"iana"},"audio/g7291":{source:"iana"},"audio/g729d":{source:"iana"},"audio/g729e":{source:"iana"},"audio/gsm":{source:"iana"},"audio/gsm-efr":{source:"iana"},"audio/gsm-hr-08":{source:"iana"},"audio/ilbc":{source:"iana"},"audio/ip-mr_v2.5":{source:"iana"},"audio/isac":{source:"apache"},"audio/l16":{source:"iana"},"audio/l20":{source:"iana"},"audio/l24":{source:"iana",compressible:!1},"audio/l8":{source:"iana"},"audio/lpc":{source:"iana"},"audio/melp":{source:"iana"},"audio/melp1200":{source:"iana"},"audio/melp2400":{source:"iana"},"audio/melp600":{source:"iana"},"audio/mhas":{source:"iana"},"audio/midi":{source:"apache",extensions:["mid","midi","kar","rmi"]},"audio/mobile-xmf":{source:"iana",extensions:["mxmf"]},"audio/mp3":{compressible:!1,extensions:["mp3"]},"audio/mp4":{source:"iana",compressible:!1,extensions:["m4a","mp4a"]},"audio/mp4a-latm":{source:"iana"},"audio/mpa":{source:"iana"},"audio/mpa-robust":{source:"iana"},"audio/mpeg":{source:"iana",compressible:!1,extensions:["mpga","mp2","mp2a","mp3","m2a","m3a"]},"audio/mpeg4-generic":{source:"iana"},"audio/musepack":{source:"apache"},"audio/ogg":{source:"iana",compressible:!1,extensions:["oga","ogg","spx","opus"]},"audio/opus":{source:"iana"},"audio/parityfec":{source:"iana"},"audio/pcma":{source:"iana"},"audio/pcma-wb":{source:"iana"},"audio/pcmu":{source:"iana"},"audio/pcmu-wb":{source:"iana"},"audio/prs.sid":{source:"iana"},"audio/qcelp":{source:"iana"},"audio/raptorfec":{source:"iana"},"audio/red":{source:"iana"},"audio/rtp-enc-aescm128":{source:"iana"},"audio/rtp-midi":{source:"iana"},"audio/rtploopback":{source:"iana"},"audio/rtx":{source:"iana"},"audio/s3m":{source:"apache",extensions:["s3m"]},"audio/scip":{source:"iana"},"audio/silk":{source:"apache",extensions:["sil"]},"audio/smv":{source:"iana"},"audio/smv-qcp":{source:"iana"},"audio/smv0":{source:"iana"},"audio/sofa":{source:"iana"},"audio/sp-midi":{source:"iana"},"audio/speex":{source:"iana"},"audio/t140c":{source:"iana"},"audio/t38":{source:"iana"},"audio/telephone-event":{source:"iana"},"audio/tetra_acelp":{source:"iana"},"audio/tetra_acelp_bb":{source:"iana"},"audio/tone":{source:"iana"},"audio/tsvcis":{source:"iana"},"audio/uemclip":{source:"iana"},"audio/ulpfec":{source:"iana"},"audio/usac":{source:"iana"},"audio/vdvi":{source:"iana"},"audio/vmr-wb":{source:"iana"},"audio/vnd.3gpp.iufp":{source:"iana"},"audio/vnd.4sb":{source:"iana"},"audio/vnd.audiokoz":{source:"iana"},"audio/vnd.celp":{source:"iana"},"audio/vnd.cisco.nse":{source:"iana"},"audio/vnd.cmles.radio-events":{source:"iana"},"audio/vnd.cns.anp1":{source:"iana"},"audio/vnd.cns.inf1":{source:"iana"},"audio/vnd.dece.audio":{source:"iana",extensions:["uva","uvva"]},"audio/vnd.digital-winds":{source:"iana",extensions:["eol"]},"audio/vnd.dlna.adts":{source:"iana"},"audio/vnd.dolby.heaac.1":{source:"iana"},"audio/vnd.dolby.heaac.2":{source:"iana"},"audio/vnd.dolby.mlp":{source:"iana"},"audio/vnd.dolby.mps":{source:"iana"},"audio/vnd.dolby.pl2":{source:"iana"},"audio/vnd.dolby.pl2x":{source:"iana"},"audio/vnd.dolby.pl2z":{source:"iana"},"audio/vnd.dolby.pulse.1":{source:"iana"},"audio/vnd.dra":{source:"iana",extensions:["dra"]},"audio/vnd.dts":{source:"iana",extensions:["dts"]},"audio/vnd.dts.hd":{source:"iana",extensions:["dtshd"]},"audio/vnd.dts.uhd":{source:"iana"},"audio/vnd.dvb.file":{source:"iana"},"audio/vnd.everad.plj":{source:"iana"},"audio/vnd.hns.audio":{source:"iana"},"audio/vnd.lucent.voice":{source:"iana",extensions:["lvp"]},"audio/vnd.ms-playready.media.pya":{source:"iana",extensions:["pya"]},"audio/vnd.nokia.mobile-xmf":{source:"iana"},"audio/vnd.nortel.vbk":{source:"iana"},"audio/vnd.nuera.ecelp4800":{source:"iana",extensions:["ecelp4800"]},"audio/vnd.nuera.ecelp7470":{source:"iana",extensions:["ecelp7470"]},"audio/vnd.nuera.ecelp9600":{source:"iana",extensions:["ecelp9600"]},"audio/vnd.octel.sbc":{source:"iana"},"audio/vnd.presonus.multitrack":{source:"iana"},"audio/vnd.qcelp":{source:"iana"},"audio/vnd.rhetorex.32kadpcm":{source:"iana"},"audio/vnd.rip":{source:"iana",extensions:["rip"]},"audio/vnd.rn-realaudio":{compressible:!1},"audio/vnd.sealedmedia.softseal.mpeg":{source:"iana"},"audio/vnd.vmx.cvsd":{source:"iana"},"audio/vnd.wave":{compressible:!1},"audio/vorbis":{source:"iana",compressible:!1},"audio/vorbis-config":{source:"iana"},"audio/wav":{compressible:!1,extensions:["wav"]},"audio/wave":{compressible:!1,extensions:["wav"]},"audio/webm":{source:"apache",compressible:!1,extensions:["weba"]},"audio/x-aac":{source:"apache",compressible:!1,extensions:["aac"]},"audio/x-aiff":{source:"apache",extensions:["aif","aiff","aifc"]},"audio/x-caf":{source:"apache",compressible:!1,extensions:["caf"]},"audio/x-flac":{source:"apache",extensions:["flac"]},"audio/x-m4a":{source:"nginx",extensions:["m4a"]},"audio/x-matroska":{source:"apache",extensions:["mka"]},"audio/x-mpegurl":{source:"apache",extensions:["m3u"]},"audio/x-ms-wax":{source:"apache",extensions:["wax"]},"audio/x-ms-wma":{source:"apache",extensions:["wma"]},"audio/x-pn-realaudio":{source:"apache",extensions:["ram","ra"]},"audio/x-pn-realaudio-plugin":{source:"apache",extensions:["rmp"]},"audio/x-realaudio":{source:"nginx",extensions:["ra"]},"audio/x-tta":{source:"apache"},"audio/x-wav":{source:"apache",extensions:["wav"]},"audio/xm":{source:"apache",extensions:["xm"]},"chemical/x-cdx":{source:"apache",extensions:["cdx"]},"chemical/x-cif":{source:"apache",extensions:["cif"]},"chemical/x-cmdf":{source:"apache",extensions:["cmdf"]},"chemical/x-cml":{source:"apache",extensions:["cml"]},"chemical/x-csml":{source:"apache",extensions:["csml"]},"chemical/x-pdb":{source:"apache"},"chemical/x-xyz":{source:"apache",extensions:["xyz"]},"font/collection":{source:"iana",extensions:["ttc"]},"font/otf":{source:"iana",compressible:!0,extensions:["otf"]},"font/sfnt":{source:"iana"},"font/ttf":{source:"iana",compressible:!0,extensions:["ttf"]},"font/woff":{source:"iana",extensions:["woff"]},"font/woff2":{source:"iana",extensions:["woff2"]},"image/aces":{source:"iana",extensions:["exr"]},"image/apng":{compressible:!1,extensions:["apng"]},"image/avci":{source:"iana",extensions:["avci"]},"image/avcs":{source:"iana",extensions:["avcs"]},"image/avif":{source:"iana",compressible:!1,extensions:["avif"]},"image/bmp":{source:"iana",compressible:!0,extensions:["bmp"]},"image/cgm":{source:"iana",extensions:["cgm"]},"image/dicom-rle":{source:"iana",extensions:["drle"]},"image/emf":{source:"iana",extensions:["emf"]},"image/fits":{source:"iana",extensions:["fits"]},"image/g3fax":{source:"iana",extensions:["g3"]},"image/gif":{source:"iana",compressible:!1,extensions:["gif"]},"image/heic":{source:"iana",extensions:["heic"]},"image/heic-sequence":{source:"iana",extensions:["heics"]},"image/heif":{source:"iana",extensions:["heif"]},"image/heif-sequence":{source:"iana",extensions:["heifs"]},"image/hej2k":{source:"iana",extensions:["hej2"]},"image/hsj2":{source:"iana",extensions:["hsj2"]},"image/ief":{source:"iana",extensions:["ief"]},"image/jls":{source:"iana",extensions:["jls"]},"image/jp2":{source:"iana",compressible:!1,extensions:["jp2","jpg2"]},"image/jpeg":{source:"iana",compressible:!1,extensions:["jpeg","jpg","jpe"]},"image/jph":{source:"iana",extensions:["jph"]},"image/jphc":{source:"iana",extensions:["jhc"]},"image/jpm":{source:"iana",compressible:!1,extensions:["jpm"]},"image/jpx":{source:"iana",compressible:!1,extensions:["jpx","jpf"]},"image/jxr":{source:"iana",extensions:["jxr"]},"image/jxra":{source:"iana",extensions:["jxra"]},"image/jxrs":{source:"iana",extensions:["jxrs"]},"image/jxs":{source:"iana",extensions:["jxs"]},"image/jxsc":{source:"iana",extensions:["jxsc"]},"image/jxsi":{source:"iana",extensions:["jxsi"]},"image/jxss":{source:"iana",extensions:["jxss"]},"image/ktx":{source:"iana",extensions:["ktx"]},"image/ktx2":{source:"iana",extensions:["ktx2"]},"image/naplps":{source:"iana"},"image/pjpeg":{compressible:!1},"image/png":{source:"iana",compressible:!1,extensions:["png"]},"image/prs.btif":{source:"iana",extensions:["btif"]},"image/prs.pti":{source:"iana",extensions:["pti"]},"image/pwg-raster":{source:"iana"},"image/sgi":{source:"apache",extensions:["sgi"]},"image/svg+xml":{source:"iana",compressible:!0,extensions:["svg","svgz"]},"image/t38":{source:"iana",extensions:["t38"]},"image/tiff":{source:"iana",compressible:!1,extensions:["tif","tiff"]},"image/tiff-fx":{source:"iana",extensions:["tfx"]},"image/vnd.adobe.photoshop":{source:"iana",compressible:!0,extensions:["psd"]},"image/vnd.airzip.accelerator.azv":{source:"iana",extensions:["azv"]},"image/vnd.cns.inf2":{source:"iana"},"image/vnd.dece.graphic":{source:"iana",extensions:["uvi","uvvi","uvg","uvvg"]},"image/vnd.djvu":{source:"iana",extensions:["djvu","djv"]},"image/vnd.dvb.subtitle":{source:"iana",extensions:["sub"]},"image/vnd.dwg":{source:"iana",extensions:["dwg"]},"image/vnd.dxf":{source:"iana",extensions:["dxf"]},"image/vnd.fastbidsheet":{source:"iana",extensions:["fbs"]},"image/vnd.fpx":{source:"iana",extensions:["fpx"]},"image/vnd.fst":{source:"iana",extensions:["fst"]},"image/vnd.fujixerox.edmics-mmr":{source:"iana",extensions:["mmr"]},"image/vnd.fujixerox.edmics-rlc":{source:"iana",extensions:["rlc"]},"image/vnd.globalgraphics.pgb":{source:"iana"},"image/vnd.microsoft.icon":{source:"iana",compressible:!0,extensions:["ico"]},"image/vnd.mix":{source:"iana"},"image/vnd.mozilla.apng":{source:"iana"},"image/vnd.ms-dds":{compressible:!0,extensions:["dds"]},"image/vnd.ms-modi":{source:"iana",extensions:["mdi"]},"image/vnd.ms-photo":{source:"apache",extensions:["wdp"]},"image/vnd.net-fpx":{source:"iana",extensions:["npx"]},"image/vnd.pco.b16":{source:"iana",extensions:["b16"]},"image/vnd.radiance":{source:"iana"},"image/vnd.sealed.png":{source:"iana"},"image/vnd.sealedmedia.softseal.gif":{source:"iana"},"image/vnd.sealedmedia.softseal.jpg":{source:"iana"},"image/vnd.svf":{source:"iana"},"image/vnd.tencent.tap":{source:"iana",extensions:["tap"]},"image/vnd.valve.source.texture":{source:"iana",extensions:["vtf"]},"image/vnd.wap.wbmp":{source:"iana",extensions:["wbmp"]},"image/vnd.xiff":{source:"iana",extensions:["xif"]},"image/vnd.zbrush.pcx":{source:"iana",extensions:["pcx"]},"image/webp":{source:"apache",extensions:["webp"]},"image/wmf":{source:"iana",extensions:["wmf"]},"image/x-3ds":{source:"apache",extensions:["3ds"]},"image/x-cmu-raster":{source:"apache",extensions:["ras"]},"image/x-cmx":{source:"apache",extensions:["cmx"]},"image/x-freehand":{source:"apache",extensions:["fh","fhc","fh4","fh5","fh7"]},"image/x-icon":{source:"apache",compressible:!0,extensions:["ico"]},"image/x-jng":{source:"nginx",extensions:["jng"]},"image/x-mrsid-image":{source:"apache",extensions:["sid"]},"image/x-ms-bmp":{source:"nginx",compressible:!0,extensions:["bmp"]},"image/x-pcx":{source:"apache",extensions:["pcx"]},"image/x-pict":{source:"apache",extensions:["pic","pct"]},"image/x-portable-anymap":{source:"apache",extensions:["pnm"]},"image/x-portable-bitmap":{source:"apache",extensions:["pbm"]},"image/x-portable-graymap":{source:"apache",extensions:["pgm"]},"image/x-portable-pixmap":{source:"apache",extensions:["ppm"]},"image/x-rgb":{source:"apache",extensions:["rgb"]},"image/x-tga":{source:"apache",extensions:["tga"]},"image/x-xbitmap":{source:"apache",extensions:["xbm"]},"image/x-xcf":{compressible:!1},"image/x-xpixmap":{source:"apache",extensions:["xpm"]},"image/x-xwindowdump":{source:"apache",extensions:["xwd"]},"message/cpim":{source:"iana"},"message/delivery-status":{source:"iana"},"message/disposition-notification":{source:"iana",extensions:["disposition-notification"]},"message/external-body":{source:"iana"},"message/feedback-report":{source:"iana"},"message/global":{source:"iana",extensions:["u8msg"]},"message/global-delivery-status":{source:"iana",extensions:["u8dsn"]},"message/global-disposition-notification":{source:"iana",extensions:["u8mdn"]},"message/global-headers":{source:"iana",extensions:["u8hdr"]},"message/http":{source:"iana",compressible:!1},"message/imdn+xml":{source:"iana",compressible:!0},"message/news":{source:"iana"},"message/partial":{source:"iana",compressible:!1},"message/rfc822":{source:"iana",compressible:!0,extensions:["eml","mime"]},"message/s-http":{source:"iana"},"message/sip":{source:"iana"},"message/sipfrag":{source:"iana"},"message/tracking-status":{source:"iana"},"message/vnd.si.simp":{source:"iana"},"message/vnd.wfa.wsc":{source:"iana",extensions:["wsc"]},"model/3mf":{source:"iana",extensions:["3mf"]},"model/e57":{source:"iana"},"model/gltf+json":{source:"iana",compressible:!0,extensions:["gltf"]},"model/gltf-binary":{source:"iana",compressible:!0,extensions:["glb"]},"model/iges":{source:"iana",compressible:!1,extensions:["igs","iges"]},"model/mesh":{source:"iana",compressible:!1,extensions:["msh","mesh","silo"]},"model/mtl":{source:"iana",extensions:["mtl"]},"model/obj":{source:"iana",extensions:["obj"]},"model/step":{source:"iana"},"model/step+xml":{source:"iana",compressible:!0,extensions:["stpx"]},"model/step+zip":{source:"iana",compressible:!1,extensions:["stpz"]},"model/step-xml+zip":{source:"iana",compressible:!1,extensions:["stpxz"]},"model/stl":{source:"iana",extensions:["stl"]},"model/vnd.collada+xml":{source:"iana",compressible:!0,extensions:["dae"]},"model/vnd.dwf":{source:"iana",extensions:["dwf"]},"model/vnd.flatland.3dml":{source:"iana"},"model/vnd.gdl":{source:"iana",extensions:["gdl"]},"model/vnd.gs-gdl":{source:"apache"},"model/vnd.gs.gdl":{source:"iana"},"model/vnd.gtw":{source:"iana",extensions:["gtw"]},"model/vnd.moml+xml":{source:"iana",compressible:!0},"model/vnd.mts":{source:"iana",extensions:["mts"]},"model/vnd.opengex":{source:"iana",extensions:["ogex"]},"model/vnd.parasolid.transmit.binary":{source:"iana",extensions:["x_b"]},"model/vnd.parasolid.transmit.text":{source:"iana",extensions:["x_t"]},"model/vnd.pytha.pyox":{source:"iana"},"model/vnd.rosette.annotated-data-model":{source:"iana"},"model/vnd.sap.vds":{source:"iana",extensions:["vds"]},"model/vnd.usdz+zip":{source:"iana",compressible:!1,extensions:["usdz"]},"model/vnd.valve.source.compiled-map":{source:"iana",extensions:["bsp"]},"model/vnd.vtu":{source:"iana",extensions:["vtu"]},"model/vrml":{source:"iana",compressible:!1,extensions:["wrl","vrml"]},"model/x3d+binary":{source:"apache",compressible:!1,extensions:["x3db","x3dbz"]},"model/x3d+fastinfoset":{source:"iana",extensions:["x3db"]},"model/x3d+vrml":{source:"apache",compressible:!1,extensions:["x3dv","x3dvz"]},"model/x3d+xml":{source:"iana",compressible:!0,extensions:["x3d","x3dz"]},"model/x3d-vrml":{source:"iana",extensions:["x3dv"]},"multipart/alternative":{source:"iana",compressible:!1},"multipart/appledouble":{source:"iana"},"multipart/byteranges":{source:"iana"},"multipart/digest":{source:"iana"},"multipart/encrypted":{source:"iana",compressible:!1},"multipart/form-data":{source:"iana",compressible:!1},"multipart/header-set":{source:"iana"},"multipart/mixed":{source:"iana"},"multipart/multilingual":{source:"iana"},"multipart/parallel":{source:"iana"},"multipart/related":{source:"iana",compressible:!1},"multipart/report":{source:"iana"},"multipart/signed":{source:"iana",compressible:!1},"multipart/vnd.bint.med-plus":{source:"iana"},"multipart/voice-message":{source:"iana"},"multipart/x-mixed-replace":{source:"iana"},"text/1d-interleaved-parityfec":{source:"iana"},"text/cache-manifest":{source:"iana",compressible:!0,extensions:["appcache","manifest"]},"text/calendar":{source:"iana",extensions:["ics","ifb"]},"text/calender":{compressible:!0},"text/cmd":{compressible:!0},"text/coffeescript":{extensions:["coffee","litcoffee"]},"text/cql":{source:"iana"},"text/cql-expression":{source:"iana"},"text/cql-identifier":{source:"iana"},"text/css":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["css"]},"text/csv":{source:"iana",compressible:!0,extensions:["csv"]},"text/csv-schema":{source:"iana"},"text/directory":{source:"iana"},"text/dns":{source:"iana"},"text/ecmascript":{source:"iana"},"text/encaprtp":{source:"iana"},"text/enriched":{source:"iana"},"text/fhirpath":{source:"iana"},"text/flexfec":{source:"iana"},"text/fwdred":{source:"iana"},"text/gff3":{source:"iana"},"text/grammar-ref-list":{source:"iana"},"text/html":{source:"iana",compressible:!0,extensions:["html","htm","shtml"]},"text/jade":{extensions:["jade"]},"text/javascript":{source:"iana",compressible:!0},"text/jcr-cnd":{source:"iana"},"text/jsx":{compressible:!0,extensions:["jsx"]},"text/less":{compressible:!0,extensions:["less"]},"text/markdown":{source:"iana",compressible:!0,extensions:["markdown","md"]},"text/mathml":{source:"nginx",extensions:["mml"]},"text/mdx":{compressible:!0,extensions:["mdx"]},"text/mizar":{source:"iana"},"text/n3":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["n3"]},"text/parameters":{source:"iana",charset:"UTF-8"},"text/parityfec":{source:"iana"},"text/plain":{source:"iana",compressible:!0,extensions:["txt","text","conf","def","list","log","in","ini"]},"text/provenance-notation":{source:"iana",charset:"UTF-8"},"text/prs.fallenstein.rst":{source:"iana"},"text/prs.lines.tag":{source:"iana",extensions:["dsc"]},"text/prs.prop.logic":{source:"iana"},"text/raptorfec":{source:"iana"},"text/red":{source:"iana"},"text/rfc822-headers":{source:"iana"},"text/richtext":{source:"iana",compressible:!0,extensions:["rtx"]},"text/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"text/rtp-enc-aescm128":{source:"iana"},"text/rtploopback":{source:"iana"},"text/rtx":{source:"iana"},"text/sgml":{source:"iana",extensions:["sgml","sgm"]},"text/shaclc":{source:"iana"},"text/shex":{source:"iana",extensions:["shex"]},"text/slim":{extensions:["slim","slm"]},"text/spdx":{source:"iana",extensions:["spdx"]},"text/strings":{source:"iana"},"text/stylus":{extensions:["stylus","styl"]},"text/t140":{source:"iana"},"text/tab-separated-values":{source:"iana",compressible:!0,extensions:["tsv"]},"text/troff":{source:"iana",extensions:["t","tr","roff","man","me","ms"]},"text/turtle":{source:"iana",charset:"UTF-8",extensions:["ttl"]},"text/ulpfec":{source:"iana"},"text/uri-list":{source:"iana",compressible:!0,extensions:["uri","uris","urls"]},"text/vcard":{source:"iana",compressible:!0,extensions:["vcard"]},"text/vnd.a":{source:"iana"},"text/vnd.abc":{source:"iana"},"text/vnd.ascii-art":{source:"iana"},"text/vnd.curl":{source:"iana",extensions:["curl"]},"text/vnd.curl.dcurl":{source:"apache",extensions:["dcurl"]},"text/vnd.curl.mcurl":{source:"apache",extensions:["mcurl"]},"text/vnd.curl.scurl":{source:"apache",extensions:["scurl"]},"text/vnd.debian.copyright":{source:"iana",charset:"UTF-8"},"text/vnd.dmclientscript":{source:"iana"},"text/vnd.dvb.subtitle":{source:"iana",extensions:["sub"]},"text/vnd.esmertec.theme-descriptor":{source:"iana",charset:"UTF-8"},"text/vnd.familysearch.gedcom":{source:"iana",extensions:["ged"]},"text/vnd.ficlab.flt":{source:"iana"},"text/vnd.fly":{source:"iana",extensions:["fly"]},"text/vnd.fmi.flexstor":{source:"iana",extensions:["flx"]},"text/vnd.gml":{source:"iana"},"text/vnd.graphviz":{source:"iana",extensions:["gv"]},"text/vnd.hans":{source:"iana"},"text/vnd.hgl":{source:"iana"},"text/vnd.in3d.3dml":{source:"iana",extensions:["3dml"]},"text/vnd.in3d.spot":{source:"iana",extensions:["spot"]},"text/vnd.iptc.newsml":{source:"iana"},"text/vnd.iptc.nitf":{source:"iana"},"text/vnd.latex-z":{source:"iana"},"text/vnd.motorola.reflex":{source:"iana"},"text/vnd.ms-mediapackage":{source:"iana"},"text/vnd.net2phone.commcenter.command":{source:"iana"},"text/vnd.radisys.msml-basic-layout":{source:"iana"},"text/vnd.senx.warpscript":{source:"iana"},"text/vnd.si.uricatalogue":{source:"iana"},"text/vnd.sosi":{source:"iana"},"text/vnd.sun.j2me.app-descriptor":{source:"iana",charset:"UTF-8",extensions:["jad"]},"text/vnd.trolltech.linguist":{source:"iana",charset:"UTF-8"},"text/vnd.wap.si":{source:"iana"},"text/vnd.wap.sl":{source:"iana"},"text/vnd.wap.wml":{source:"iana",extensions:["wml"]},"text/vnd.wap.wmlscript":{source:"iana",extensions:["wmls"]},"text/vtt":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["vtt"]},"text/x-asm":{source:"apache",extensions:["s","asm"]},"text/x-c":{source:"apache",extensions:["c","cc","cxx","cpp","h","hh","dic"]},"text/x-component":{source:"nginx",extensions:["htc"]},"text/x-fortran":{source:"apache",extensions:["f","for","f77","f90"]},"text/x-gwt-rpc":{compressible:!0},"text/x-handlebars-template":{extensions:["hbs"]},"text/x-java-source":{source:"apache",extensions:["java"]},"text/x-jquery-tmpl":{compressible:!0},"text/x-lua":{extensions:["lua"]},"text/x-markdown":{compressible:!0,extensions:["mkd"]},"text/x-nfo":{source:"apache",extensions:["nfo"]},"text/x-opml":{source:"apache",extensions:["opml"]},"text/x-org":{compressible:!0,extensions:["org"]},"text/x-pascal":{source:"apache",extensions:["p","pas"]},"text/x-processing":{compressible:!0,extensions:["pde"]},"text/x-sass":{extensions:["sass"]},"text/x-scss":{extensions:["scss"]},"text/x-setext":{source:"apache",extensions:["etx"]},"text/x-sfv":{source:"apache",extensions:["sfv"]},"text/x-suse-ymp":{compressible:!0,extensions:["ymp"]},"text/x-uuencode":{source:"apache",extensions:["uu"]},"text/x-vcalendar":{source:"apache",extensions:["vcs"]},"text/x-vcard":{source:"apache",extensions:["vcf"]},"text/xml":{source:"iana",compressible:!0,extensions:["xml"]},"text/xml-external-parsed-entity":{source:"iana"},"text/yaml":{compressible:!0,extensions:["yaml","yml"]},"video/1d-interleaved-parityfec":{source:"iana"},"video/3gpp":{source:"iana",extensions:["3gp","3gpp"]},"video/3gpp-tt":{source:"iana"},"video/3gpp2":{source:"iana",extensions:["3g2"]},"video/av1":{source:"iana"},"video/bmpeg":{source:"iana"},"video/bt656":{source:"iana"},"video/celb":{source:"iana"},"video/dv":{source:"iana"},"video/encaprtp":{source:"iana"},"video/ffv1":{source:"iana"},"video/flexfec":{source:"iana"},"video/h261":{source:"iana",extensions:["h261"]},"video/h263":{source:"iana",extensions:["h263"]},"video/h263-1998":{source:"iana"},"video/h263-2000":{source:"iana"},"video/h264":{source:"iana",extensions:["h264"]},"video/h264-rcdo":{source:"iana"},"video/h264-svc":{source:"iana"},"video/h265":{source:"iana"},"video/iso.segment":{source:"iana",extensions:["m4s"]},"video/jpeg":{source:"iana",extensions:["jpgv"]},"video/jpeg2000":{source:"iana"},"video/jpm":{source:"apache",extensions:["jpm","jpgm"]},"video/jxsv":{source:"iana"},"video/mj2":{source:"iana",extensions:["mj2","mjp2"]},"video/mp1s":{source:"iana"},"video/mp2p":{source:"iana"},"video/mp2t":{source:"iana",extensions:["ts"]},"video/mp4":{source:"iana",compressible:!1,extensions:["mp4","mp4v","mpg4"]},"video/mp4v-es":{source:"iana"},"video/mpeg":{source:"iana",compressible:!1,extensions:["mpeg","mpg","mpe","m1v","m2v"]},"video/mpeg4-generic":{source:"iana"},"video/mpv":{source:"iana"},"video/nv":{source:"iana"},"video/ogg":{source:"iana",compressible:!1,extensions:["ogv"]},"video/parityfec":{source:"iana"},"video/pointer":{source:"iana"},"video/quicktime":{source:"iana",compressible:!1,extensions:["qt","mov"]},"video/raptorfec":{source:"iana"},"video/raw":{source:"iana"},"video/rtp-enc-aescm128":{source:"iana"},"video/rtploopback":{source:"iana"},"video/rtx":{source:"iana"},"video/scip":{source:"iana"},"video/smpte291":{source:"iana"},"video/smpte292m":{source:"iana"},"video/ulpfec":{source:"iana"},"video/vc1":{source:"iana"},"video/vc2":{source:"iana"},"video/vnd.cctv":{source:"iana"},"video/vnd.dece.hd":{source:"iana",extensions:["uvh","uvvh"]},"video/vnd.dece.mobile":{source:"iana",extensions:["uvm","uvvm"]},"video/vnd.dece.mp4":{source:"iana"},"video/vnd.dece.pd":{source:"iana",extensions:["uvp","uvvp"]},"video/vnd.dece.sd":{source:"iana",extensions:["uvs","uvvs"]},"video/vnd.dece.video":{source:"iana",extensions:["uvv","uvvv"]},"video/vnd.directv.mpeg":{source:"iana"},"video/vnd.directv.mpeg-tts":{source:"iana"},"video/vnd.dlna.mpeg-tts":{source:"iana"},"video/vnd.dvb.file":{source:"iana",extensions:["dvb"]},"video/vnd.fvt":{source:"iana",extensions:["fvt"]},"video/vnd.hns.video":{source:"iana"},"video/vnd.iptvforum.1dparityfec-1010":{source:"iana"},"video/vnd.iptvforum.1dparityfec-2005":{source:"iana"},"video/vnd.iptvforum.2dparityfec-1010":{source:"iana"},"video/vnd.iptvforum.2dparityfec-2005":{source:"iana"},"video/vnd.iptvforum.ttsavc":{source:"iana"},"video/vnd.iptvforum.ttsmpeg2":{source:"iana"},"video/vnd.motorola.video":{source:"iana"},"video/vnd.motorola.videop":{source:"iana"},"video/vnd.mpegurl":{source:"iana",extensions:["mxu","m4u"]},"video/vnd.ms-playready.media.pyv":{source:"iana",extensions:["pyv"]},"video/vnd.nokia.interleaved-multimedia":{source:"iana"},"video/vnd.nokia.mp4vr":{source:"iana"},"video/vnd.nokia.videovoip":{source:"iana"},"video/vnd.objectvideo":{source:"iana"},"video/vnd.radgamettools.bink":{source:"iana"},"video/vnd.radgamettools.smacker":{source:"iana"},"video/vnd.sealed.mpeg1":{source:"iana"},"video/vnd.sealed.mpeg4":{source:"iana"},"video/vnd.sealed.swf":{source:"iana"},"video/vnd.sealedmedia.softseal.mov":{source:"iana"},"video/vnd.uvvu.mp4":{source:"iana",extensions:["uvu","uvvu"]},"video/vnd.vivo":{source:"iana",extensions:["viv"]},"video/vnd.youtube.yt":{source:"iana"},"video/vp8":{source:"iana"},"video/vp9":{source:"iana"},"video/webm":{source:"apache",compressible:!1,extensions:["webm"]},"video/x-f4v":{source:"apache",extensions:["f4v"]},"video/x-fli":{source:"apache",extensions:["fli"]},"video/x-flv":{source:"apache",compressible:!1,extensions:["flv"]},"video/x-m4v":{source:"apache",extensions:["m4v"]},"video/x-matroska":{source:"apache",compressible:!1,extensions:["mkv","mk3d","mks"]},"video/x-mng":{source:"apache",extensions:["mng"]},"video/x-ms-asf":{source:"apache",extensions:["asf","asx"]},"video/x-ms-vob":{source:"apache",extensions:["vob"]},"video/x-ms-wm":{source:"apache",extensions:["wm"]},"video/x-ms-wmv":{source:"apache",compressible:!1,extensions:["wmv"]},"video/x-ms-wmx":{source:"apache",extensions:["wmx"]},"video/x-ms-wvx":{source:"apache",extensions:["wvx"]},"video/x-msvideo":{source:"apache",extensions:["avi"]},"video/x-sgi-movie":{source:"apache",extensions:["movie"]},"video/x-smv":{source:"apache",extensions:["smv"]},"x-conference/x-cooltalk":{source:"apache",extensions:["ice"]},"x-shader/x-fragment":{compressible:!0},"x-shader/x-vertex":{compressible:!0}};/*!
 * mime-db
 * Copyright(c) 2014 Jonathan Ong
 * Copyright(c) 2015-2022 Douglas Christopher Wilson
 * MIT Licensed
 */var mimeDb=require$$0$4;function getDefaultExportFromCjs(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var browser$e={exports:{}},process=browser$e.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(t){if(cachedSetTimeout===setTimeout)return setTimeout(t,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(t,0);try{return cachedSetTimeout(t,0)}catch{try{return cachedSetTimeout.call(null,t,0)}catch{return cachedSetTimeout.call(this,t,0)}}}function runClearTimeout(t){if(cachedClearTimeout===clearTimeout)return clearTimeout(t);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(t);try{return cachedClearTimeout(t)}catch{try{return cachedClearTimeout.call(null,t)}catch{return cachedClearTimeout.call(this,t)}}}var queue=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var t=runTimeout(cleanUpNextTick);draining=!0;for(var e=queue.length;e;){for(currentQueue=queue,queue=[];++queueIndex<e;)currentQueue&&currentQueue[queueIndex].run();queueIndex=-1,e=queue.length}currentQueue=null,draining=!1,runClearTimeout(t)}}process.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];queue.push(new Item(t,e)),queue.length===1&&!draining&&runTimeout(drainQueue)};function Item(t,e){this.fun=t,this.array=e}Item.prototype.run=function(){this.fun.apply(null,this.array)},process.title="browser",process.browser=!0,process.env={},process.argv=[],process.version="",process.versions={};function noop(){}process.on=noop,process.addListener=noop,process.once=noop,process.off=noop,process.removeListener=noop,process.removeAllListeners=noop,process.emit=noop,process.prependListener=noop,process.prependOnceListener=noop,process.listeners=function(t){return[]},process.binding=function(t){throw new Error("process.binding is not supported")},process.cwd=function(){return"/"},process.chdir=function(t){throw new Error("process.chdir is not supported")},process.umask=function(){return 0};var browserExports$1=browser$e.exports;const process$1=getDefaultExportFromCjs(browserExports$1);function assertPath(t){if(typeof t!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(t))}function normalizeStringPosix(t,e){for(var n="",o=0,u=-1,l=0,m,y=0;y<=t.length;++y){if(y<t.length)m=t.charCodeAt(y);else{if(m===47)break;m=47}if(m===47){if(!(u===y-1||l===1))if(u!==y-1&&l===2){if(n.length<2||o!==2||n.charCodeAt(n.length-1)!==46||n.charCodeAt(n.length-2)!==46){if(n.length>2){var E=n.lastIndexOf("/");if(E!==n.length-1){E===-1?(n="",o=0):(n=n.slice(0,E),o=n.length-1-n.lastIndexOf("/")),u=y,l=0;continue}}else if(n.length===2||n.length===1){n="",o=0,u=y,l=0;continue}}e&&(n.length>0?n+="/..":n="..",o=2)}else n.length>0?n+="/"+t.slice(u+1,y):n=t.slice(u+1,y),o=y-u-1;u=y,l=0}else m===46&&l!==-1?++l:l=-1}return n}function _format(t,e){var n=e.dir||e.root,o=e.base||(e.name||"")+(e.ext||"");return n?n===e.root?n+o:n+t+o:o}var posix={resolve:function(){for(var e="",n=!1,o,u=arguments.length-1;u>=-1&&!n;u--){var l;u>=0?l=arguments[u]:(o===void 0&&(o=process$1.cwd()),l=o),assertPath(l),l.length!==0&&(e=l+"/"+e,n=l.charCodeAt(0)===47)}return e=normalizeStringPosix(e,!n),n?e.length>0?"/"+e:"/":e.length>0?e:"."},normalize:function(e){if(assertPath(e),e.length===0)return".";var n=e.charCodeAt(0)===47,o=e.charCodeAt(e.length-1)===47;return e=normalizeStringPosix(e,!n),e.length===0&&!n&&(e="."),e.length>0&&o&&(e+="/"),n?"/"+e:e},isAbsolute:function(e){return assertPath(e),e.length>0&&e.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var e,n=0;n<arguments.length;++n){var o=arguments[n];assertPath(o),o.length>0&&(e===void 0?e=o:e+="/"+o)}return e===void 0?".":posix.normalize(e)},relative:function(e,n){if(assertPath(e),assertPath(n),e===n||(e=posix.resolve(e),n=posix.resolve(n),e===n))return"";for(var o=1;o<e.length&&e.charCodeAt(o)===47;++o);for(var u=e.length,l=u-o,m=1;m<n.length&&n.charCodeAt(m)===47;++m);for(var y=n.length,E=y-m,C=l<E?l:E,k=-1,A=0;A<=C;++A){if(A===C){if(E>C){if(n.charCodeAt(m+A)===47)return n.slice(m+A+1);if(A===0)return n.slice(m+A)}else l>C&&(e.charCodeAt(o+A)===47?k=A:A===0&&(k=0));break}var D=e.charCodeAt(o+A),P=n.charCodeAt(m+A);if(D!==P)break;D===47&&(k=A)}var R="";for(A=o+k+1;A<=u;++A)(A===u||e.charCodeAt(A)===47)&&(R.length===0?R+="..":R+="/..");return R.length>0?R+n.slice(m+k):(m+=k,n.charCodeAt(m)===47&&++m,n.slice(m))},_makeLong:function(e){return e},dirname:function(e){if(assertPath(e),e.length===0)return".";for(var n=e.charCodeAt(0),o=n===47,u=-1,l=!0,m=e.length-1;m>=1;--m)if(n=e.charCodeAt(m),n===47){if(!l){u=m;break}}else l=!1;return u===-1?o?"/":".":o&&u===1?"//":e.slice(0,u)},basename:function(e,n){if(n!==void 0&&typeof n!="string")throw new TypeError('"ext" argument must be a string');assertPath(e);var o=0,u=-1,l=!0,m;if(n!==void 0&&n.length>0&&n.length<=e.length){if(n.length===e.length&&n===e)return"";var y=n.length-1,E=-1;for(m=e.length-1;m>=0;--m){var C=e.charCodeAt(m);if(C===47){if(!l){o=m+1;break}}else E===-1&&(l=!1,E=m+1),y>=0&&(C===n.charCodeAt(y)?--y===-1&&(u=m):(y=-1,u=E))}return o===u?u=E:u===-1&&(u=e.length),e.slice(o,u)}else{for(m=e.length-1;m>=0;--m)if(e.charCodeAt(m)===47){if(!l){o=m+1;break}}else u===-1&&(l=!1,u=m+1);return u===-1?"":e.slice(o,u)}},extname:function(e){assertPath(e);for(var n=-1,o=0,u=-1,l=!0,m=0,y=e.length-1;y>=0;--y){var E=e.charCodeAt(y);if(E===47){if(!l){o=y+1;break}continue}u===-1&&(l=!1,u=y+1),E===46?n===-1?n=y:m!==1&&(m=1):n!==-1&&(m=-1)}return n===-1||u===-1||m===0||m===1&&n===u-1&&n===o+1?"":e.slice(n,u)},format:function(e){if(e===null||typeof e!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof e);return _format("/",e)},parse:function(e){assertPath(e);var n={root:"",dir:"",base:"",ext:"",name:""};if(e.length===0)return n;var o=e.charCodeAt(0),u=o===47,l;u?(n.root="/",l=1):l=0;for(var m=-1,y=0,E=-1,C=!0,k=e.length-1,A=0;k>=l;--k){if(o=e.charCodeAt(k),o===47){if(!C){y=k+1;break}continue}E===-1&&(C=!1,E=k+1),o===46?m===-1?m=k:A!==1&&(A=1):m!==-1&&(A=-1)}return m===-1||E===-1||A===0||A===1&&m===E-1&&m===y+1?E!==-1&&(y===0&&u?n.base=n.name=e.slice(1,E):n.base=n.name=e.slice(y,E)):(y===0&&u?(n.name=e.slice(1,m),n.base=e.slice(1,E)):(n.name=e.slice(y,m),n.base=e.slice(y,E)),n.ext=e.slice(m,E)),y>0?n.dir=e.slice(0,y-1):u&&(n.dir="/"),n},sep:"/",delimiter:":",win32:null,posix:null};posix.posix=posix;var pathBrowserify=posix;/*!
 * mime-types
 * Copyright(c) 2014 Jonathan Ong
 * Copyright(c) 2015 Douglas Christopher Wilson
 * MIT Licensed
 */(function(t){var e=mimeDb,n=pathBrowserify.extname,o=/^\s*([^;\s]*)(?:;|\s|$)/,u=/^text\//i;t.charset=l,t.charsets={lookup:l},t.contentType=m,t.extension=y,t.extensions=Object.create(null),t.lookup=E,t.types=Object.create(null),C(t.extensions,t.types);function l(k){if(!k||typeof k!="string")return!1;var A=o.exec(k),D=A&&e[A[1].toLowerCase()];return D&&D.charset?D.charset:A&&u.test(A[1])?"UTF-8":!1}function m(k){if(!k||typeof k!="string")return!1;var A=k.indexOf("/")===-1?t.lookup(k):k;if(!A)return!1;if(A.indexOf("charset")===-1){var D=t.charset(A);D&&(A+="; charset="+D.toLowerCase())}return A}function y(k){if(!k||typeof k!="string")return!1;var A=o.exec(k),D=A&&t.extensions[A[1].toLowerCase()];return!D||!D.length?!1:D[0]}function E(k){if(!k||typeof k!="string")return!1;var A=n("x."+k).toLowerCase().substr(1);return A&&t.types[A]||!1}function C(k,A){var D=["nginx","apache",void 0,"iana"];Object.keys(e).forEach(function(R){var B=e[R],F=B.extensions;if(!(!F||!F.length)){k[R]=F;for(var j=0;j<F.length;j++){var N=F[j];if(A[N]){var Y=D.indexOf(e[A[N]].source),J=D.indexOf(B.source);if(A[N]!=="application/octet-stream"&&(Y>J||Y===J&&A[N].substr(0,12)==="application/"))continue}A[N]=R}}})}})(mimeTypes);const mime=getDefaultExportFromCjs$1(mimeTypes),alternative_types=[{regex:/^(https?:\/\/)?((?:www|m)\.)?(?:youtube(?:-nocookie)?\.com|youtu.be)/,type:"video/youtube"},{regex:/^(https?:\/\/)?(www\.)?vimeo\.com/,type:"video/vimeo"}],VideojsPlayerWidget=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){var n={techOrder:["html5","Youtube","Vimeo"]},o=!1,u=!0;typeof this.video>"u"&&(this.video=this.media.video);let l=mime.lookup(this.video);if(!l){for(const C of alternative_types)if(C.regex.test(this.video)){l=C.type;break}}if(n.src={type:l||!1,src:this.video},n.controls=!1,n.width=this.width,this.height&&(n.height=this.height),this.autostart&&(n.autostart=!0),this.url_transform&&(n.src.src=this.url_transform(n.src.src)),!this.media)return;var m=this.media;const y=`video_${this.generateUid("_")}`;this.$.append(`<video class="video-js" id="${y}"><source type="${n.src.type||"video/mp4"}" src="${n.src.src}"></source></video>`);const E=videojs(y,n);m.on("setcurrenttime",function(C){o=u,E.currentTime(C/1e3)}),m.on("setvolume",function(C){E.volume(C),m.volume=C}),m.on("setmuted",function(C){E.muted(C),m.muted=C}),m.on("setplay",function(){E.play(),m.paused=!1}),m.on("setpause",function(){E.pause(),m.paused=!0}),E.on("timeupdate",function(){m.trigger("timeupdate",new t.Model.Time(E.currentTime()*1e3))}),E.ready(function(){m.trigger("timeupdate",new t.Model.Time(E.currentTime()*1e3)),u=E.paused(),m.paused=E.paused(),m.trigger("loadedmetadata")}),E.on("pause",function(){u=!0,m.trigger("pause")}),E.on("play",function(){u=!1,m.trigger("play")}),videojs.use("*",function(C){return{play:function(k,A){return u=!1,m.trigger("play"),A},setCurrentTime:function(k){return o?(E.pause(),o=!1):u&&!E.paused()&&(u=!1,m.trigger("play")),m.trigger("timeupdate",new t.Model.Time(k)),k},pause:function(k,A){return u=!0,m.trigger("pause"),A},setMuted:function(k){return m.muted=k,m.trigger("volumechange"),k},setVolume:function(k){return m.volume=k,m.trigger("volumechange"),k}}}),this.videojsPlayer=E}},Fi(e,"defaults",{}),e};function defaults(t){const e={};return e.language="en",e.widgetsDir="widgets",e.widgetsRequirements={PopcornPlayer:{noCss:!0,requires:["popcorn"]},HtmlPlayer:{noCss:!0},JwpPlayer:{noCss:!0,requires:["jwplayer"]},DailymotionPlayer:{noCss:!0,requires:["swfObject"]},AdaptivePlayer:{noCss:!0},AutoPlayer:{noCss:!0},AnnotationsList:{requires:["jwplayer"]},Sparkline:{noCss:!0,requires:["raphael"]},Arrow:{noCss:!0,requires:["raphael"]},Mediafragment:{noCss:!0},Trace:{noCss:!0,requires:["tracemanager"]},Slideshare:{requires:["swfObject"]},Social:{requires:["zeroClipboardJs"]},Renkan:{requires:["backbone","backboneRelational","paper","jqueryMousewheel","renkanPublish"]},KnowledgeConcierge:{requires:["processing"]},MultiSegments:{noCss:!0},SlideVideoPlayer:{requires:["jQuery","jQueryUI","splitter"]},Shortcuts:{requires:["mousetrap","mousetrapGlobal"]},VideojsPlayer:{requires:["videojs","videojs-youtube","videojs-vimeo"]}},e.guiDefaults={width:640,container:"LdtPlayer",spacer_div_height:0,widgets:[]},e}function metadataplayer(t){var e=t.Metadataplayer=function(n){t.log("IriSP.Metadataplayer constructor");for(var o in t.guiDefaults)t.guiDefaults.hasOwnProperty(o)&&!n.hasOwnProperty(o)&&(n[o]=t.guiDefaults[o]);var u=document.getElementById(n.container);u.innerHTML='<h3 class="Ldt-Loader">Loading... Chargement...</h3>',this.sourceManager=new t.Model.Directory,this.config=n,this.__events={},this.onLibsLoaded()};e.prototype.toString=function(){return"Metadataplayer in #"+this.config.container},e.prototype.on=function(n,o){typeof this.__events[n]>"u"&&(this.__events[n]=[]),this.__events[n].push(o)},e.prototype.trigger=function(n,o){var u=this;_$1(this.__events[n]).each(function(l){l.call(u,o)})},e.prototype.onLibsLoaded=function(){t.log("IriSP.Metadataplayer.prototype.onLibsLoaded"),this.$=jQuery("#"+this.config.container),this.$.css({width:this.config.width,clear:"both"}),typeof this.config.height<"u"&&this.$.css("height",this.config.height),this.widgets=[];var n=this;_$1(this.config.widgets).each(function(o,u){n.widgets.push(null),n.loadWidget(o,function(l){n.widgets[u]=l,l.isLoaded()&&n.trigger("widget-loaded")})}),this.$.find(".Ldt-Loader").detach(),this.widgetsLoaded=!1,this.on("widget-loaded",function(){if(!n.widgetsLoaded){var o=!_$1(n.widgets).some(function(u){return!(u&&u.isLoaded())});o&&(n.widgetsLoaded=!0,n.trigger("widgets-loaded"))}})},e.prototype.loadLocalAnnotations=function(n){return this.localSource===void 0&&(this.localSource=this.sourceManager.newLocalSource({serializer:IriSP.serializers.ldt_localstorage})),n&&(this.localSource.identifier=n),this.localSource.deSerialize(window.localStorage[this.localSource.identifier]||"[]"),this.localSource},e.prototype.saveLocalAnnotations=function(){window.localStorage[this.localSource.identifier]=this.localSource.serialize()},e.prototype.addLocalAnnotation=function(n){this.loadLocalAnnotations(),this.localSource.getAnnotations().push(n),this.saveLocalAnnotations()},e.prototype.deleteLocalAnnotation=function(n){this.localSource.getAnnotations().removeId(n,!0),this.saveLocalAnnotations()},e.prototype.getLocalAnnotation=function(n){return this.loadLocalAnnotations(),_$1.first(_$1.filter(this.localSource.getAnnotations(),function(o){return o.id==n}))},e.prototype.loadMetadata=function(n){return n.elementType==="source"?n:(typeof n.serializer>"u"&&typeof n.format<"u"&&(n.serializer=t.serializers[n.format]),typeof n.url<"u"&&typeof n.serializer<"u"?this.sourceManager.remoteSource(n):this.sourceManager.newLocalSource(n))},e.prototype.loadWidget=function(n,o){if(typeof n.container>"u"){var u=this.layoutDivs(n.type);n.container=u[0]}var l=this;typeof t.Widgets[n.type]<"u"?_$1.defer(function(){o(new t.Widgets[n.type](l,n))}):t.log("Widget type "+n.type+" Unkown !")},e.prototype.layoutDivs=function(n,o){typeof n>"u"&&(n="");var u=_$1.uniqueId(this.config.container+"_widget_"+n+"_"),l=_$1.uniqueId("LdtPlayer_spacer_"),m=jQuery("<div>").attr("id",u).css({width:this.config.width+"px",position:"relative",clear:"both"}),y=jQuery("<div>").attr("id",l).css({width:this.config.width+"px",height:this.config.spacer_div_height+"px",position:"relative",clear:"both"});return typeof o<"u"&&m.css("height",o),this.$.append(m),this.$.append(y),[u,l]}}/*!
 * mustache.js - Logic-less {{mustache}} templates with JavaScript
 * http://github.com/janl/mustache.js
 */var objectToString$1=Object.prototype.toString,isArray$4=Array.isArray||function(e){return objectToString$1.call(e)==="[object Array]"};function isFunction$1(t){return typeof t=="function"}function typeStr(t){return isArray$4(t)?"array":typeof t}function escapeRegExp(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function hasProperty(t,e){return t!=null&&typeof t=="object"&&e in t}function primitiveHasOwnProperty(t,e){return t!=null&&typeof t!="object"&&t.hasOwnProperty&&t.hasOwnProperty(e)}var regExpTest=RegExp.prototype.test;function testRegExp(t,e){return regExpTest.call(t,e)}var nonSpaceRe=/\S/;function isWhitespace(t){return!testRegExp(nonSpaceRe,t)}var entityMap={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;","`":"&#x60;","=":"&#x3D;"};function escapeHtml(t){return String(t).replace(/[&<>"'`=\/]/g,function(n){return entityMap[n]})}var whiteRe=/\s*/,spaceRe=/\s+/,equalsRe=/\s*=/,curlyRe=/\s*\}/,tagRe=/#|\^|\/|>|\{|&|=|!/;function parseTemplate(t,e){if(!t)return[];var n=!1,o=[],u=[],l=[],m=!1,y=!1,E="",C=0;function k(){if(m&&!y)for(;l.length;)delete u[l.pop()];else l=[];m=!1,y=!1}var A,D,P;function R(ce){if(typeof ce=="string"&&(ce=ce.split(spaceRe,2)),!isArray$4(ce)||ce.length!==2)throw new Error("Invalid tags: "+ce);A=new RegExp(escapeRegExp(ce[0])+"\\s*"),D=new RegExp("\\s*"+escapeRegExp(ce[1])),P=new RegExp("\\s*"+escapeRegExp("}"+ce[1]))}R(e||mustache.tags);for(var B=new Scanner(t),F,j,N,Y,J,ie;!B.eos();){if(F=B.pos,N=B.scanUntil(A),N)for(var ue=0,Q=N.length;ue<Q;++ue)Y=N.charAt(ue),isWhitespace(Y)?(l.push(u.length),E+=Y):(y=!0,n=!0,E+=" "),u.push(["text",Y,F,F+1]),F+=1,Y===`
`&&(k(),E="",C=0,n=!1);if(!B.scan(A))break;if(m=!0,j=B.scan(tagRe)||"name",B.scan(whiteRe),j==="="?(N=B.scanUntil(equalsRe),B.scan(equalsRe),B.scanUntil(D)):j==="{"?(N=B.scanUntil(P),B.scan(curlyRe),B.scanUntil(D),j="&"):N=B.scanUntil(D),!B.scan(D))throw new Error("Unclosed tag at "+B.pos);if(j==">"?J=[j,N,F,B.pos,E,C,n]:J=[j,N,F,B.pos],C++,u.push(J),j==="#"||j==="^")o.push(J);else if(j==="/"){if(ie=o.pop(),!ie)throw new Error('Unopened section "'+N+'" at '+F);if(ie[1]!==N)throw new Error('Unclosed section "'+ie[1]+'" at '+F)}else j==="name"||j==="{"||j==="&"?y=!0:j==="="&&R(N)}if(k(),ie=o.pop(),ie)throw new Error('Unclosed section "'+ie[1]+'" at '+B.pos);return nestTokens(squashTokens(u))}function squashTokens(t){for(var e=[],n,o,u=0,l=t.length;u<l;++u)n=t[u],n&&(n[0]==="text"&&o&&o[0]==="text"?(o[1]+=n[1],o[3]=n[3]):(e.push(n),o=n));return e}function nestTokens(t){for(var e=[],n=e,o=[],u,l,m=0,y=t.length;m<y;++m)switch(u=t[m],u[0]){case"#":case"^":n.push(u),o.push(u),n=u[4]=[];break;case"/":l=o.pop(),l[5]=u[2],n=o.length>0?o[o.length-1][4]:e;break;default:n.push(u)}return e}function Scanner(t){this.string=t,this.tail=t,this.pos=0}Scanner.prototype.eos=function(){return this.tail===""},Scanner.prototype.scan=function(e){var n=this.tail.match(e);if(!n||n.index!==0)return"";var o=n[0];return this.tail=this.tail.substring(o.length),this.pos+=o.length,o},Scanner.prototype.scanUntil=function(e){var n=this.tail.search(e),o;switch(n){case-1:o=this.tail,this.tail="";break;case 0:o="";break;default:o=this.tail.substring(0,n),this.tail=this.tail.substring(n)}return this.pos+=o.length,o};function Context(t,e){this.view=t,this.cache={".":this.view},this.parent=e}Context.prototype.push=function(e){return new Context(e,this)},Context.prototype.lookup=function(e){var n=this.cache,o;if(n.hasOwnProperty(e))o=n[e];else{for(var u=this,l,m,y,E=!1;u;){if(e.indexOf(".")>0)for(l=u.view,m=e.split("."),y=0;l!=null&&y<m.length;)y===m.length-1&&(E=hasProperty(l,m[y])||primitiveHasOwnProperty(l,m[y])),l=l[m[y++]];else l=u.view[e],E=hasProperty(u.view,e);if(E){o=l;break}u=u.parent}n[e]=o}return isFunction$1(o)&&(o=o.call(this.view)),o};function Writer(){this.templateCache={_cache:{},set:function(e,n){this._cache[e]=n},get:function(e){return this._cache[e]},clear:function(){this._cache={}}}}Writer.prototype.clearCache=function(){typeof this.templateCache<"u"&&this.templateCache.clear()},Writer.prototype.parse=function(e,n){var o=this.templateCache,u=e+":"+(n||mustache.tags).join(":"),l=typeof o<"u",m=l?o.get(u):void 0;return m==null&&(m=parseTemplate(e,n),l&&o.set(u,m)),m},Writer.prototype.render=function(e,n,o,u){var l=this.getConfigTags(u),m=this.parse(e,l),y=n instanceof Context?n:new Context(n,void 0);return this.renderTokens(m,y,o,e,u)},Writer.prototype.renderTokens=function(e,n,o,u,l){for(var m="",y,E,C,k=0,A=e.length;k<A;++k)C=void 0,y=e[k],E=y[0],E==="#"?C=this.renderSection(y,n,o,u,l):E==="^"?C=this.renderInverted(y,n,o,u,l):E===">"?C=this.renderPartial(y,n,o,l):E==="&"?C=this.unescapedValue(y,n):E==="name"?C=this.escapedValue(y,n,l):E==="text"&&(C=this.rawValue(y)),C!==void 0&&(m+=C);return m},Writer.prototype.renderSection=function(e,n,o,u,l){var m=this,y="",E=n.lookup(e[1]);function C(D){return m.render(D,n,o,l)}if(E){if(isArray$4(E))for(var k=0,A=E.length;k<A;++k)y+=this.renderTokens(e[4],n.push(E[k]),o,u,l);else if(typeof E=="object"||typeof E=="string"||typeof E=="number")y+=this.renderTokens(e[4],n.push(E),o,u,l);else if(isFunction$1(E)){if(typeof u!="string")throw new Error("Cannot use higher-order sections without the original template");E=E.call(n.view,u.slice(e[3],e[5]),C),E!=null&&(y+=E)}else y+=this.renderTokens(e[4],n,o,u,l);return y}},Writer.prototype.renderInverted=function(e,n,o,u,l){var m=n.lookup(e[1]);if(!m||isArray$4(m)&&m.length===0)return this.renderTokens(e[4],n,o,u,l)},Writer.prototype.indentPartial=function(e,n,o){for(var u=n.replace(/[^ \t]/g,""),l=e.split(`
`),m=0;m<l.length;m++)l[m].length&&(m>0||!o)&&(l[m]=u+l[m]);return l.join(`
`)},Writer.prototype.renderPartial=function(e,n,o,u){if(o){var l=this.getConfigTags(u),m=isFunction$1(o)?o(e[1]):o[e[1]];if(m!=null){var y=e[6],E=e[5],C=e[4],k=m;E==0&&C&&(k=this.indentPartial(m,C,y));var A=this.parse(k,l);return this.renderTokens(A,n,o,k,u)}}},Writer.prototype.unescapedValue=function(e,n){var o=n.lookup(e[1]);if(o!=null)return o},Writer.prototype.escapedValue=function(e,n,o){var u=this.getConfigEscape(o)||mustache.escape,l=n.lookup(e[1]);if(l!=null)return typeof l=="number"&&u===mustache.escape?String(l):u(l)},Writer.prototype.rawValue=function(e){return e[1]},Writer.prototype.getConfigTags=function(e){return isArray$4(e)?e:e&&typeof e=="object"?e.tags:void 0},Writer.prototype.getConfigEscape=function(e){if(e&&typeof e=="object"&&!isArray$4(e))return e.escape};var mustache={name:"mustache.js",version:"4.2.0",tags:["{{","}}"],clearCache:void 0,escape:void 0,parse:void 0,render:void 0,Scanner:void 0,Context:void 0,Writer:void 0,set templateCache(t){defaultWriter.templateCache=t},get templateCache(){return defaultWriter.templateCache}},defaultWriter=new Writer;mustache.clearCache=function(){return defaultWriter.clearCache()},mustache.parse=function(e,n){return defaultWriter.parse(e,n)},mustache.render=function(e,n,o,u){if(typeof e!="string")throw new TypeError('Invalid template! Template should be a "string" but "'+typeStr(e)+'" was given as the first argument for mustache#render(template, view, partials)');return defaultWriter.render(e,n,o,u)},mustache.escape=escapeHtml,mustache.Scanner=Scanner,mustache.Context=Context,mustache.Writer=Writer;function widgetsBase(t){var n;const e={};return e.Widget=(n=class{constructor(o,u){if(typeof o>"u")return;this.__subwidgets=[];var l=u.type||"(unknown)",m=_$1.defaults({},u,o&&o.config?o.config.default_options:{},this.constructor.defaults),y=this;_$1(m).forEach(function(C,k){y[k]=C}),this.$=jQuery("#"+this.container),typeof this.width>"u"?this.width=this.$.width():this.$.css("width",this.width),typeof this.height<"u"&&this.$.css("height",this.height),this.player=o||new t.FakeClass(["on","trigger","off","loadWidget","loadMetadata"]),this.$.addClass("Ldt-TraceMe Ldt-Widget").attr("widget-type",l),this.l10n=typeof this.constructor.messages[t.language]<"u"?this.constructor.messages[t.language]:t.language.length>2&&typeof this.constructor.messages[t.language.substr(0,2)]<"u"?this.constructor.messages[t.language.substr(0,2)]:this.constructor.messages.en;function E(){if(y.localannotations&&(y.localsource=o.loadLocalAnnotations(y.localannotations),y.source.merge(y.localsource)),y.media_id)y.media=this.getElement(y.media_id);else{var C={is_mashup:y.is_mashup||!1};y.media=y.source.getCurrentMedia(C)}y.pre_draw_callback?jQuery.when(y.pre_draw_callback()).done(y.draw()):y.draw(),y.player.trigger("widget-loaded")}this.metadata?(this.source=o.loadMetadata(this.metadata),this.source.onLoad(E)):this.source&&E()}toString(){return"Widget "+this.type}templateToHtml(o){return mustache.render(o,this)}renderTemplate(){this.$.append(this.templateToHtml(this.constructor.template))}functionWrapper(o){var u=this,l=this[o];if(typeof l<"u")return function(){return l.apply(u,Array.prototype.slice.call(arguments,0))};console.log("Error, Unknown function IriSP.Widgets."+this.type+"."+o)}getFunctionOrName(o){switch(typeof o){case"function":return o;case"string":return this.functionWrapper(o);default:return}}onMdpEvent(o,u){this.player.on(o,this.getFunctionOrName(u))}onMediaEvent(o,u){this.media.on(o,this.getFunctionOrName(u))}getWidgetAnnotations(){var o=null;return typeof this.annotation_type>"u"?o=this.media.getAnnotations():this.annotation_type.elementType==="annotationType"?o=this.annotation_type.getAnnotations():o=this.media.getAnnotationsByTypeTitle(this.annotation_type),typeof this.annotation_filter<"u"?this.annotation_filter(o):o}getWidgetAnnotationsAtTime(){var o=this.media.getCurrentTime();return this.getWidgetAnnotations().filter(function(u){return u.begin<=o&&u.end>o})}isLoaded(){var o=!_$1(this.__subwidgets).some(function(u){return!(u&&u.isLoaded())});return o}insertSubwidget(o,u,l){var m=o.attr("id"),y=this,E=this.__subwidgets.length;this.__subwidgets.push(null),typeof m>"u"&&(m=_$1.uniqueId(this.container+"_sub_widget_"+u.type),o.attr("id",m)),u.container=m,y.player.loadWidget(u,function(C){l&&(y[l]=C),y.__subwidgets[E]=C})}navigate(o){for(var u=this,l=u.media.getCurrentTime(),m=u.getWidgetAnnotations().sortBy(function(E){return E.begin}),y=0;y<m.length;y++)if(m[y].begin<=l&&l<m[y].end){y=Math.min(m.length-1,Math.max(0,y+o)),u.media.setCurrentTime(m[y].begin);break}}exportAnnotations(o){var u=this;o===void 0&&(o=this.getWidgetAnnotations());var l=jQuery,m=mustache.render(`[video:{{url}}]
`,{url:u.media.url})+o.map(function(y){return mustache.render("[{{ a.begin }}]{{ a.title }} {{ a.description }}[{{ a.end }}]",{a:y})}).join(`
`);l("<pre>").addClass("exportContainer").text(m).dialog({title:"Annotation export",open:function(y,E){var C;document.selection?(C=document.body.createTextRange(),C.moveToElementText(this[0]),C.select()):window.getSelection&&(C=document.createRange(),C.selectNode(this[0]),window.getSelection().addRange(C))},autoOpen:!0,width:"80%",minHeight:"400",height:400,buttons:[{text:"Close",click:function(){l(this).dialog("close")}},{text:"Download",click:function(){a=document.createElement("a"),a.setAttribute("href","data:text/plain;base64,"+btoa(m)),a.setAttribute("download","Annotations - "+u.media.title.replace(/[^ \w]/g,"")+".txt"),a.click()}}]})}draw(){}generateUid(o="-"){return`xxxxxxxx${o}xxxx${o}4xxx${o}yxxx${o}xxxxxxxxxxxx`.replace(/[xy]/g,function(u){var l=Math.random()*16|0,m=u==="x"?l:l&3|8;return m.toString(16)})}},Fi(n,"defaults",{}),Fi(n,"template",""),Fi(n,"messages",{en:{}}),n),e}const AdaptivePlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){typeof this.video>"u"&&(this.video=this.media.video);var n=["autostart","video","height","width","url_transform"],o={},u=document.createElement("video").canPlayType(this.mime_type);o.type=u!=="no"?this.normal_player:this.fallback_player;for(var l=0;l<n.length;l++)typeof this[n[l]]<"u"&&(o[n[l]]=this[n[l]]);this.insertSubwidget(this.$,o)}},Fi(e,"defaults",{mime_type:'video/mp4; codecs="avc1.42E01E"',normal_player:"HtmlPlayer",fallback_player:"VideojsPlayer"}),e},helloWorldStyles={},HelloWorld=function(t){var e;return e=class extends t.Widgets.Widget{constructor(o,u){super(o,u);Fi(this,"draw",function(){this.renderTemplate(),console.log("HelloWorldWidget was drawn")});console.log("Calling IriSP.Widget's constructor from IriSP.HelloWorldWidget")}},Fi(e,"defaults",{text:"world"}),Fi(e,"template",'<div class="Ldt-HelloWorld"><p>{{l10n.Hello}} {{text}}</p><p>Looks like we have <span class="Ldt-HelloWorld-annotations">{{source.contents.annotation.length}} annotations</span> in this feed</p></div>'),Fi(e,"messages",{fr:{Hello:"Bonjour,"},en:{Hello:"Hello,"}}),e},annotationStyles={},Annotation=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.lastAnnotation=!1,this.minimized=this.start_minimized||!1,this.bounds=[0,0]}draw(){var n=this,o;function u(y){var E=n.getWidgetAnnotationsAtTime();E.length||(n.$.find(".Ldt-Annotation-Inner").addClass("Ldt-Annotation-Empty"),n.arrow&&n.arrow.moveToTime(y),n.bounds=[y,y],n.sendBounds())}function l(){if(o){var y=o.title,E=o.description.replace(/(^\s+|\s+$)/g,""),C=o.found&&n.source.getAnnotations().regexp||!1;n.$.find(".Ldt-Annotation-Title").html(IriSP.textFieldHtml(y,C)||"("+n.l10n.untitled+")"),E?(n.$.find(".Ldt-Annotation-Description-Block").removeClass("Ldt-Annotation-EmptyBlock"),n.$.find(".Ldt-Annotation-Description").html(IriSP.textFieldHtml(E,C))):n.$.find(".Ldt-Annotation-Description-Block").addClass("Ldt-Annotation-EmptyBlock")}}function m(y){o=y;var E=typeof y.url<"u"?y.url:document.location.href.replace(/#.*$/,"")+"#id="+y.id,C=n.l10n.watching+y.title+(n.site_name?n.l10n.on_site+n.site_name:""),k=y.getTags(),A=n.$.find(".Ldt-Annotation-Tags");A.empty(),k.length?(n.$.find(".Ldt-Annotation-Tags-Block").removeClass("Ldt-Annotation-EmptyBlock"),k.forEach(function(D){var P=D.title.replace(/(^\s+|\s+$)/g,"");if(P){var R=jQuery('<li class="Ldt-Annotation-TagLabel"></li>').append(jQuery("<span>").text(P));R.on("click",function(){n.search_on_tag_click&&n.source.getAnnotations().search(P),D.trigger("click")}),A.append(R)}})):n.$.find(".Ldt-Annotation-Tags-Block").addClass("Ldt-Annotation-EmptyBlock"),l(),n.show_creator&&n.$.find(".Ldt-Annotation-Creator").text(y.creator),n.show_annotation_type&&(n.$.find(".Ldt-Annotation-Type").text(y.getAnnotationType().title),n.$.find(".Ldt-Annotation-Type").attr("title",y.getAnnotationType().description)),n.$.find(".Ldt-Annotation-Begin").text(y.begin.toString()),n.$.find(".Ldt-Annotation-End").text(y.end.toString()),y.elementType==="mashedAnnotation"?(n.$.find(".Ldt-Annotation-Inner").addClass("Ldt-Annotation-isMashup"),n.$.find(".Ldt-Annotation-MashupMedia").text(y.getMedia().title),n.$.find(".Ldt-Annotation-MashupBegin").text(y.annotation.begin.toString()),n.$.find(".Ldt-Annotation-MashupEnd").text(y.annotation.end.toString())):n.$.find(".Ldt-Annotation-Inner").removeClass("Ldt-Annotation-isMashup"),typeof n.socialWidget<"u"?n.socialWidget.updateUrls(E,C):setTimeout(function(){typeof n.socialWidget<"u"&&n.socialWidget.updateUrls(E,C)},800),n.$.find(".Ldt-Annotation-Inner").removeClass("Ldt-Annotation-Empty"),n.bounds=[y.begin,y.end],n.arrow&&n.arrow.moveToTime((1-n.arrow_position)*y.begin+n.arrow_position*y.end),n.sendBounds()}this.renderTemplate(),this.$.find(".Ldt-Annotation-Title").click(function(){return o&&n.media.setCurrentTime(o.begin),!1}),this.show_social&&this.insertSubwidget(this.$.find(".Ldt-Annotation-Social"),{type:"Social"},"socialWidget"),this.show_arrow&&this.insertSubwidget(this.$.find(".Ldt-Annotation-Arrow"),{type:"Arrow",width:this.width},"arrow"),this.onMediaEvent("timeupdate",u),this.onMdpEvent("Annotation.hide","hide"),this.onMdpEvent("Annotation.show","show"),this.onMdpEvent("Annotation.minimize","minimize"),this.onMdpEvent("Annotation.maximize","maximize"),this.onMdpEvent("Annotation.getBounds","sendBounds"),this.$.find(".Ldt-Annotation-MaxMinButton").click(this.functionWrapper("toggleSize")),this.$.on("resize",function(){n.width=n.$.parent().width(),n.$.css({width:n.width})}),this.getWidgetAnnotations().forEach(function(y){y.on("enter",function(){m(y)})}),this.source.getAnnotations().on("found",l),this.source.getAnnotations().on("not-found",l),this.source.getAnnotations().on("search-cleared",l),IriSP.attachDndData(this.$.find("h3"),function(){return{title:o.title,description:o.description,image:o.thumbnail,uri:typeof o.url<"u"?o.url:document.location.href.replace(/#.*$/,"")+"#id="+o.id,text:"["+o.begin.toString()+"] "+o.title}})}sendBounds(){this.player.trigger("Annotation.boundsChanged",this.bounds)}drawAnnotation(n){this.lastAnnotation=n.id}hide(){this.$.slideUp()}show(){this.$.slideDown()}toggleSize(){this.minimized?this.maximize():this.minimize()}minimize(){this.minimized=!0,this.$.find(".Ldt-Annotation-Inner").addClass("Ldt-Annotation-Minimized")}maximize(){this.minimized=!1,this.$.find(".Ldt-Annotation-Inner").removeClass("Ldt-Annotation-Minimized")}},Fi(e,"messages",{fr:{watching:"Je regarde ",on_site:" sur ",tags_:"Mots-clés :",description_:"Description :",creator_:"Créé par :",excerpt_from:"Extrait de :",untitled:"Segment sans titre"},en:{watching:"I'm watching ",on_site:" on ",tags_:"Keywords:",description_:"Description:",creator_:"Created by :",excerpt_from:"Excerpt from:",untitled:"Untitled segment"}}),Fi(e,"template",'{{#show_arrow}}<div class="Ldt-Annotation-Arrow"></div>{{/show_arrow}}<div class="Ldt-Annotation-Widget {{^show_arrow}}Ldt-Annotation-ShowTop{{/show_arrow}}"><div class="Ldt-Annotation-Inner Ldt-Annotation-Empty{{#start_minimized}} Ldt-Annotation-Minimized{{/start_minimized}}"><div class="Ldt-Annotation-HiddenWhenEmpty Ldt-Annotation-MaxMinButton"></div>{{#show_social}}<div class="Ldt-Annotation-Social Ldt-Annotation-HiddenWhenMinimized Ldt-Annotation-HiddenWhenEmpty"></div>{{/show_social}}<h3 class="Ldt-Annotation-HiddenWhenEmpty">{{#show_annotation_type}}<span class="Ldt-Annotation-Type"></span> » {{/show_annotation_type}}<a class="Ldt-Annotation-Title" href="#"></a> <span class="Ldt-Annotation-Time Ldt-Annotation-HiddenWhenMinimized">(<span class="Ldt-Annotation-Begin"></span> - <span class="Ldt-Annotation-End"></span>)</span></h3><h3 class="Ldt-Annotation-MashupOrigin Ldt-Annotation-HiddenWhenEmpty">{{l10n.excerpt_from}} <span class="Ldt-Annotation-MashupMedia"></span> <span class="Ldt-Annotation-Time Ldt-Annotation-HiddenWhenMinimized">(<span class="Ldt-Annotation-MashupBegin"></span> - <span class="Ldt-Annotation-MashupEnd"></span>)</span></h3><div class="Ldt-Annotation-Cleared Ldt-Annotation-HiddenWhenMinimized Ldt-Annotation-HiddenWhenEmpty Ldt-Annotation-Creator-Block"><div class="Ldt-Annotation-Label">{{l10n.creator_}}</div>{{#show_creator}}<p class="Ldt-Annotation-Labelled Ldt-Annotation-Creator"></p></div>{{/show_creator}}{{#show_description}}<div class="Ldt-Annotation-Cleared Ldt-Annotation-HiddenWhenMinimized Ldt-Annotation-HiddenWhenEmpty Ldt-Annotation-Description-Block"><div class="Ldt-Annotation-Label">{{l10n.description_}}</div><p class="Ldt-Annotation-Labelled Ldt-Annotation-Description"></p></div>{{/show_description}}<div class="Ldt-Annotation-Tags-Block Ldt-Annotation-HiddenWhenMinimized Ldt-Annotation-HiddenWhenEmpty Ldt-Annotation-Cleared"><div class="Ldt-Annotation-Label">{{l10n.tags_}}</div><ul class="Ldt-Annotation-Labelled Ldt-Annotation-Tags"></ul></div></div></div></div>'),Fi(e,"defaults",{annotation_type:"chap",start_minimized:!1,show_arrow:!0,show_creator:!0,show_description:!0,arrow_position:.5,site_name:"Lignes de Temps",search_on_tag_click:!0,show_social:!0,show_annotation_type:!1}),e},annotationsControllerStyles={},AnnotationsController=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){this.renderTemplate();var n=this;this.element_$=this.$.find(".Ldt-AnnotationsController"),this.displayButton_$=this.$.find(".Ldt-AnnotationsController-ShowAnnotationsListButton"),this.writeButton_$=this.$.find(".Ldt-AnnotationsController-ShowCreateAnnotationButton"),this.writeButton_$.click(function(){n.writeButton_$.hasClass("selected")?(n.player.trigger("CreateAnnotation.hide"),n.toggle_widgets?n.player.trigger("AnnotationsList.show"):n.display_or_write&&n.player.trigger("AnnotationsList.hide")):(n.player.trigger("CreateAnnotation.show"),n.display_or_write&&n.player.trigger("AnnotationsList.hide"))}),this.displayButton_$.click(function(){n.displayButton_$.hasClass("selected")?(n.player.trigger("AnnotationsList.hide"),n.toggle_widgets?n.player.trigger("CreateAnnotation.show"):n.display_or_write&&n.player.trigger("CreateAnnotation.hide")):(n.player.trigger("AnnotationsList.show"),n.display_or_write&&n.player.trigger("CreateAnnotation.hide"))}),this.hide_without_segment&&(this.onMediaEvent("timeupdate",function(){n.refresh()}),this.onMediaEvent("settimerange",function(o){n.refresh(o)}),this.segments=this.source.getAnnotationsByTypeTitle(this.segments_annotation_type),this.currentSegment=!1),this.createAnnotationEnabled=!1,this.onMdpEvent("CreateAnnotation.hide",function(){n.hide_when_writing&&n.show(),n.createAnnotationEnabled=!1,n.writeButton_$.toggleClass("selected",!1)}),this.onMdpEvent("CreateAnnotation.show",function(){n.hide_when_writing&&n.hide(),n.createAnnotationEnabled=!0,n.writeButton_$.toggleClass("selected",!0)}),this.onMdpEvent("AnnotationsList.hide",function(){n.displayButton_$.toggleClass("selected",!1)}),this.onMdpEvent("AnnotationsList.show",function(){n.displayButton_$.toggleClass("selected",!0)}),this.starts_hidden?(this.visible=!0,this.hide()):(this.visible=!1,this.show()),this.starting_widget&&this.visible&&(this.starting_widget=="AnnotationsList"?this.player.trigger("AnnotationsList.show"):this.starting_widget=="CreateAnnotation"&&this.player.trigger("CreateAnnotation.show"))}refresh(n){if(n=typeof n<"u"?n:!1,n||this.media.getTimeRange()&&(n=this.media.getTimeRange()),this.hide_without_segment){if(!n&&!this.media.getTimeRange())_currentTime=this.media.getCurrentTime(),_currentSegments=this.segments.filter(function(l){return _currentTime>=l.begin&&_currentTime<=l.end}),_currentSegments.length>0?currentSegment=!0:currentSegment=!1;else{var o=n[0],u=n[1];_currentSegments=this.segments.filter(function(l){return o==l.begin&&u==l.end}),_currentSegments.length>0?currentSegment=!0:currentSegment=!1}!currentSegment&&_currentSegments.length==0?(this.visible||this.hide_when_writing)&&(this.writeButton_$.toggleClass("selected",!1),this.displayButton_$.toggleClass("selected",!1),this.player.trigger("CreateAnnotation.hide"),this.player.trigger("AnnotationsList.hide"),this.hide()):this.visible||(this.createAnnotationEnabled||this.show(),this.writeButton_$.toggleClass("selected",!1),this.displayButton_$.toggleClass("selected",!1),this.starting_widget=="AnnotationsList"&&this.player.trigger("AnnotationsList.show"),this.starting_widget=="CreateAnnotation"&&this.player.trigger("CreateAnnotation.show"))}}hide(){this.visible&&(this.visible=!1,this.element_$.hide())}show(){this.visible||(this.visible=!0,this.element_$.show())}},Fi(e,"defaults",{display_or_write:!1,toggle_widgets:!1,starts_hidden:!1,hide_without_segment:!1,hide_when_writing:!0,starting_widget:!1,always_show_widget:!1,segments_annotation_type:"chap",custom_write_text:!1,custom_display_text:!1}),Fi(e,"template","<div class='Ldt-AnnotationsController'><div class='Ldt-AnnotationsController-ButtonsContainer'>    <div class='Ldt-AnnotationsController-Button Ldt-AnnotationsController-ShowCreateAnnotationButton'>{{#custom_write_text}}{{/custom_write_text}}{{custom_write_text}}{{^custom_write_text}}{{l10n.write}}{{/custom_write_text}}</div>    <div class='Ldt-AnnotationsController-Button Ldt-AnnotationsController-ShowAnnotationsListButton'>{{#custom_display_text}}{{/custom_display_text}}{{custom_display_text}}{{^custom_display_text}}{{l10n.display}}{{/custom_display_text}}</div></div></div>"),Fi(e,"messages",{en:{write:"Write",display:"Display"},fr:{write:"Ecrire",display:"Voir"}}),e},annotationsListStyles={},AnnotationsList=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.lastIds=[];var u=this;this.throttledRefresh=_$1.throttle(function(l){u.refresh(l)},800),this.searchString=!1,this.lastSearch=!1,this.localSource=void 0}importUsers(){if(!this.source.users_data&&this.api_users_endpoint){this.usernames=Array();var n=this,o=this.getWidgetAnnotations(),u="";return o.forEach(function(l){n.usernames.indexOf(l.creator)==-1&&n.usernames.push(l.creator)}),this.usernames.forEach(function(l){u+=l+","}),u=u.substring(0,u.length-1),_url=mustache.render(this.api_users_endpoint,{usernames_list_string:encodeURIComponent(u),usernames_list_length:this.usernames.length}),jQuery.ajax({async:!1,url:_url,type:"GET",success:function(l){n.source.users_data=l.objects},error:function(l,m,y){console.log(l),console.log(m),console.log(y)}})}}ajaxSource(){var n=this.media.getCurrentTime(),o=this.media.duration;this.lastAjaxQuery=n;var u=mustache.render(this.ajax_url,{media:this.source.currentMedia.id,begin:Math.max(0,n-this.ajax_granularity),end:Math.min(o.milliseconds,n+this.ajax_granularity)});this.currentSource=this.player.loadMetadata(_$1.defaults({url:u},this.metadata))}showScreen(n){this.$.find(".Ldt-AnnotationsList-Screen"+n).show().siblings().hide()}ajaxMashup(){var n=this.media.getCurrentTime(),o=this.source.currentMedia.getAnnotationAtTime(n);if(typeof o<"u"&&o.id!==this.lastMashupAnnotation){this.lastMashupAnnotation=o.id;var u=o.getMedia(),l=mustache.render(this.ajax_url,{media:u.id,begin:Math.max(0,o.annotation.begin.milliseconds-this.ajax_granularity),end:Math.min(u.duration.milliseconds,o.annotation.end.milliseconds+this.ajax_granularity)});this.currentSource=this.player.loadMetadata(_$1.defaults({url:l},this.metadata))}}importAnnotations(){var n=this,o=jQuery,u=o("<textarea>");o("<div>").append(o("<span>").addClass("importAnnotationsLabel").text(n.messages.import_annotations)).addClass("importContainer").dialog({title:"Annotation import",autoOpen:!0,width:"80%",minHeight:"400",height:400,buttons:[{text:"Close",click:function(){o(this).dialog("close")}},{text:"Import",click:function(){for(var l=/(\[[\d:]+\])/,m=u[0].value.split(l).filter(function(P){return!P.match(/^\s*$/)}),y=null,E=null,C=null,k=null,A=0;A<m.length;A++){var D=m[A];D.match(l)?(k=="text"?(E=t.timestamp2ms(D.slice(1,-1)),TODO.createAnnotation(y,E,C),y=E,E=null,C=null):(C=null,y=t.timestamp2ms(D.slice(1,-1)),E=null),k="timestamp"):(C=D,k="text"),k=="text"&&y!==null&&TODO.createAnnotation(y,y,C)}}}]})}refresh(n){if(n=typeof n<"u"&&n,this.currentSource.status!==t.Model._SOURCE_STATUS_READY)return 0;var o=this,u=this.media.getCurrentTime(),l=this.annotation_type?this.currentSource.getAnnotationsByTypeTitle(this.annotation_type):this.currentSource.getAnnotations();if(this.mashupMode){var m=this.source.currentMedia.getAnnotationAtTime(u);if(typeof m<"u"){u=u-m.begin+m.annotation.begin;var y=m.getMedia().id;l=l.filter(function(F){return F.getMedia().id===y})}}l=l.filter(function(F){return F.found!==!1}),this.filter_by_segments&&!(this.show_filters&&this.segment_filter&&this.ignoresegmentcheckbox_$[0].checked)&&(_segmentsAnnotation=this.currentSource.getAnnotationsByTypeTitle(this.segments_annotation_type),this.media.getTimeRange()?_currentSegments=_segmentsAnnotation.filter(function(F){return o.media.getTimeRange()[0]==F.begin&&o.media.getTimeRange()[1]==F.end}):_currentSegments=_segmentsAnnotation.filter(function(F){return u>=F.begin&&u<=F.end}),_currentSegments.length==0?l=l.filter(function(F){return!1}):l=l.filter(function(F){return _annotation_time=(F.begin+F.end)/2,_currentSegments[0].begin<=_annotation_time&&_currentSegments[0].end>=_annotation_time}),this.annotations_count_header&&this.annotations_count!=l.length&&(this.annotations_count=l.length,this.refreshHeader())),this.show_only_annotation_from_user&&(l=l.filter(function(F){return F.creator==o.show_only_annotation_from_user})),this.limit_count&&(l=l.sortBy(function(F){return Math.abs((F.begin+F.end)/2-u)}).slice(0,this.limit_count)),this.newest_first?l=l.sortBy(function(F){return-F.created.valueOf()}):l=l.sortBy(function(F){return F.begin}),this.show_filters&&(this.user_filter&&(_username=this.userselect_$[0].options[this.userselect_$[0].selectedIndex].value,_username!="false"&&(l=l.filter(function(F){return F.creator==_username}))),this.keyword_filter&&(_keyword=this.keywordinput_$[0].value,_keyword!=""&&(l=l.filter(function(F){return F.description.toLowerCase().match(_keyword.toLowerCase())}))),this.date_filter&&this.datefilterinput_$[0].value!=""&&(_date=this.datefilterinput_$.datepicker("getDate"),l=l.filter(function(F){return F.created.getDate()==_date.getDate()&&F.created.getMonth()==_date.getMonth()&&F.created.getFullYear()==_date.getFullYear()})),this.latest_contributions_filter&&this.latestcontributionscheckbox_$[0].checked&&(l=l.sortBy(function(F){return-F.created.valueOf()}),this.usernames.forEach(function(F){latest_ann=l.filter(function(j){return j.creator==F})[0],l=l.filter(function(j){return j.id==(latest_ann?latest_ann.id:!1)||j.creator!=F})})));var E=l.idIndex;if(n||!_$1.isEqual(E,this.lastIds)||this.searchString!==this.lastSearch){if(this.lastSearch=this.searchString,this.lastIds=E,this.list_$.html(""),l.forEach(function(F){var j=typeof F.url<"u"&&F.url?F.url:typeof o.source.projectId<"u"&&typeof F.project<"u"&&F.project&&o.source.projectId!==F.project?mustache.render(o.foreign_url,{project:F.project,media:F.media.id,annotation:F.id,annotationType:F.annotationType.id}):document.location.href.replace(/#.*$/,"")+"#id="+F.id+"&t="+F.begin/1e3,N=F.project!=o.source.projectId,Y="",J=F.description,ie=typeof F.thumbnail<"u"&&F.thumbnail?F.thumbnail:o.default_thumbnail;if(o.show_creator&&F.creator){var ue=[],Q={},ce="";o.source.users_data&&(ue=o.source.users_data.filter(function(x){return x.username==F.creator})),ue.length==0?Q.username=F.creator:Q=ue[0],ce=o.make_name_string_function(Q)}if(o.show_title&&F.title)var Y=F.title;var he;_$1(o.polemics).each(function(x){var S=t.Model.regexpFromTextOrArray(x.keyword,!0);S.test(Y+" "+J)&&(he=x.background_color)});var ke=!1;if(o.show_creation_date&&(ke=F.created.toLocaleDateString()+", "+F.created.toLocaleTimeString().replace(/\u200E/g,"").replace(/^([^\d]*\d{1,2}:\d{1,2}):\d{1,2}([^\d]*)$/,"$1$2")),o.tags==!0)var L=F.getTagTexts();else var L=!1;var d={id:F.id,media_id:F.getMedia().id,htitle:t.textFieldHtml(Y),title:Y,creator:ce,hdescription:t.textFieldHtml(J),description:J,begin:F.begin.toString(),end:F.end.toString(),created:ke,show_timecode:o.show_timecode,show_end_time:o.show_end_time,show_title:o.show_title&&Y,thumbnail:ie,url:j,tags:L,specific_style:typeof he<"u"?"background-color: "+he:"",l10n:o.l10n,editable:o.editable,external:N,show_publish:o.show_publish,show_creator:o.show_creator,show_twitter:o.show_twitter,twitter_param:jQuery.param({url:j,text:t.textFieldHtml(Y)+(o.twitter_hashtag?" #"+o.twitter_hashtag:"")}),allow_annotations_deletion:o.allow_annotations_deletion},v=mustache.render(o.constructor.annotationTemplate,d),w=jQuery(v),c=function(){o.$.find(".Ldt-AnnotationsList-li").removeClass("selected"),w.addClass("selected")},p=function(){o.$.find(".Ldt-AnnotationsList-li").removeClass("selected")};w.mouseover(function(){F.trigger("select")}).mouseout(function(){F.trigger("unselect")}).click(function(){o.filter_by_segments&&o.media.getTimeRange()&&(_ann_time=(F.begin+F.end)/2,(_ann_time<=o.media.getTimeRange()[0]||_ann_time>=o.media.getTimeRange()[1])&&o.media.resetTimeRange()),F.trigger("click")}).appendTo(o.list_$),t.attachDndData(w.find("[draggable]"),{title:Y,description:J,uri:j,image:F.thumbnail,text:"["+F.begin.toString()+"] "+Y}),w.on("remove",function(){F.off("select",c),F.off("unselect",p)}),F.on("select",c),F.on("unselect",p)}),this.$.find(".Ldt-AnnotationsList-Tag-Li").each(function(){var F=jQuery(this);F.text().replace(/(^\s+|\s+$)/g,"")||F.remove()}),this.editable){var C=o,k=jQuery,A=function(F,j){var N="#FF9999",Y="#99FF99";j===void 0&&(j=F);var J=k(F.dataset.editable_type==="multiline"?"<textarea>":"<input>").addClass("editableInput").insertBefore(k(j));J[0].value=F.dataset.editable_value,k(J).show().focus(),k(F).addClass("editing");function ie(ce){k(F).removeClass("editing"),J.remove();var he=k(F).css("background-color");k(F).stop().css("background-color",ce).animate({backgroundColor:he},1e3)}function ue(ce){ie(N)}function Q(){var ce=J[0].value;if(ce==F.dataset.editable_value){ie(Y);return}if(ce==""){R(F.dataset.editable_id),C.player.trigger("Annotation.delete",F.dataset.editable_id);return}else{var he=ce;if(F.dataset.editable_type=="timestamp"&&(he=t.timestamp2ms(ce),Number.isNaN(he))){ue();return}F.dataset.editable_value=ce,ce=he,k(F).text(he)}var ke=D(F.dataset.editable_id);ke===void 0?(console.log("Strange error: cannot find edited annotation"),ie(N)):(F.dataset.editable_value=ce,F.dataset.editable_field=="begin"?ke.setBegin(ce):F.dataset.editable_field=="end"?ke.setEnd(ce):ke[F.dataset.editable_field]=ce,ke.modified=new Date,ke.contributor=C.player.config.username||"COCo User",C.player.addLocalAnnotation(ke),C.player.trigger("Annotation.update",ke),ie(Y))}k(J).bind("keydown",function(ce){ce.which==13?(ce.preventDefault(),Q()):ce.which==27&&(ce.preventDefault(),ue())}).bind("blur",function(ce){Q()})},D=function(F){return C.player.getLocalAnnotation(F)},P=function(){C.player.saveLocalAnnotations(),C.source.merge(C.player.localSource)},R=function(F){C.source.getAnnotations().removeId(F,!0),C.player.deleteLocalAnnotation(F),C.refresh(!0)};this.$.find(".Ldt-AnnotationsList-Delete").click(function(F){var j=D(this.dataset.editable_id);confirm(mustache.render(C.l10n.confirm_delete_message,{annotation:j}))&&R(this.dataset.editable_id),C.refresh(!0)}),this.$.find(".Ldt-AnnotationsList-Edit").click(function(F){if(C.on_edit){var j=D(this.dataset.editable_id);C.on_edit(j)}else{var N=k(this).parents(".Ldt-AnnotationsList-li").find(".Ldt-AnnotationsList-TitleContent.Ldt-live-editable");A(N[0])}}),this.$.find(".Ldt-AnnotationsList-PublishAnnotation").click(function(F){var j=D(this.dataset.editable_id);if(confirm(mustache.render(C.l10n.confirm_publish_message,{annotation:j}))){var N=mustache.render(C.api_endpoint_template,{id:C.source.projectId});if(N!==""){var Y=C.player.sourceManager.newLocalSource({serializer:t.serializers[C.api_serializer]});if(C.publish_type){var J=C.source.getAnnotationTypes().filter(function(ue){return ue.title==C.publish_type});J.length==1&&j.setAnnotationType(J[0].id)}var ie=new t.Model.List(C.player.sourceManager);ie.push(j),Y.addList("annotation",ie),jQuery.ajax({url:N,type:C.api_method,contentType:"application/json",data:Y.serialize(),success:function(ue){k(this).addClass("published");var Q=D(j.id);Q.setTags(["published"]),P(),C.player.trigger("Annotation.publish",j)},error:function(ue,Q,ce){t.log("Error when sending annotation",ce)}})}}}),this.$.find(".Ldt-AnnotationsList-TimeEdit").dblclick(function(F){var j=this,N=D(j.dataset.editable_id);N!==void 0&&(N.setBegin(C.media.getCurrentTime().milliseconds),P(),C.player.trigger("Annotation.update",N),C.refresh(!0))})}if(this.$.find(".Ldt-AnnotationsList-Tag-Li").click(function(){o.source.getAnnotations().search(jQuery(this).text().replace(/(^\s+|\s+$)/g,""))}),this.$.find(".Ldt-Annotation-Timecode").click(function(){o.media.setCurrentTime(Number(this.dataset.timecode))}),this.$.find(".Ldt-AnnotationsList-Play").click(function(){var F=jQuery(this),j=F.attr("data-annotation-id");o.jwplayers[j]&&jwplayer(o.jwplayers[j]).play(),o.media.pause()}),this.source.getAnnotations().searching){var B=o.source.getAnnotations().regexp||!1;this.$.find(".Ldt-AnnotationsList-Title a, .Ldt-AnnotationsList-Description").each(function(){var F=jQuery(this);F.html(t.textFieldHtml(F.text(),B))})}this.$.find(".Ldt-AnnotationsList-DeleteButton").click(o.functionWrapper("onDeleteClick"))}return this.ajax_url&&(this.mashupMode?this.ajaxMashup():Math.abs(u-this.lastAjaxQuery)>this.ajax_granularity&&this.ajaxSource()),l.length}onDeleteClick(n){_list=this.getWidgetAnnotations(),ann_id=n.target.dataset.annotation,delete_preview_$=this.$.find(".Ldt-AnnotationsList-ul-ToDelete"),delete_preview_$.html(""),_list=_list.filter(function(D){return D.id==ann_id});var o=_list[0],u="",l="",m=this;if(o.creator){var y=[],E={};m.source.users_data&&(y=m.source.users_data.filter(function(D){return D.username==o.creator})),y.length==0?E.username=o.creator:E=y[0],l=m.make_name_string_function(E)}if(o.title){var C=o.title;C.substr(0,u.length+1)==u+":"&&(u=""),u=u+(u==""?"":": ")+o.title}var k=!1;this.show_creation_date&&(k=o.created.toLocaleDateString()+", "+o.created.toLocaleTimeString());var A={id:o.id,media_id:o.getMedia().id,htitle:t.textFieldHtml(u),hdescription:t.textFieldHtml(o.description),begin:o.begin.toString(),end:o.end.toString(),created:k,show_timecode:this.show_timecode,show_creator:this.show_creator,creator:l,tags:!1,l10n:this.l10n,allow_annotations_deletion:!1};_html=mustache.render(this.constructor.annotationTemplate,A),delete_preview_$.html(_html),this.$.find(".Ldt-AnnotationsList-ConfirmDelete").click(function(){m.sendDelete(ann_id)}),this.showScreen("Delete")}refreshHeader(){var n=" ("+this.annotations_count+" "+this.annotations_count_header_string+")";this.$.find(".Ldt-AnnotationsList-header").html(""),this.$.find(".Ldt-AnnotationsList-header").html(this.custom_header&&typeof this.custom_header=="string"?this.custom_header+n:this.l10n.header+n)}hide(){var n=this;this.visible&&(this.visible=!1,this.widget_$.slideUp(function(){n.$.find(".Ldt-AnnotationsList-header").hide()}),this.showScreen("Main"))}show(){this.visible||(this.visible=!0,this.$.find(".Ldt-AnnotationsList-header").show(),this.widget_$.slideDown(),this.showScreen("Main"))}toggle(){this.always_visible||(this.visible?this.hide():this.show())}revertToMainScreen(){this.$.find(".Ldt-AnnotationsList-ScreenMain").is(":hidden")&&this.showScreen("Main")}sendDelete(n){var o=this,u=mustache.render(this.api_delete_endpoint,{annotation_id:n,project_id:this.project_id});jQuery.ajax({url:u,type:this.api_delete_method,contentType:"application/json",success:function(l){o.showScreen("Success"),window.setTimeout(o.functionWrapper("revertToMainScreen"),o.after_send_timeout||2e3),o.currentSource.getAnnotations().removeId(n),o.player.trigger("AnnotationsList.refresh")},error:function(l,m,y){t.log("Error when sending annotation",y),o.showScreen("Error"),window.setTimeout(o.functionWrapper("revertToMainScreen"),o.after_send_timeout||2e3)}}),this.showScreen("Sending")}draw(){this.jwplayers={},this.mashupMode=this.media.elementType==="mashup",this.renderTemplate();var n=this;this.list_$=this.$.find(".Ldt-AnnotationsList-ul"),this.widget_$=this.$.find(".Ldt-AnnotationsListWidget"),this.widget_max_height&&this.widget_$.css("max-height",this.widget_max_height),this.show_filters&&(this.user_filter&&(this.userselect_$=this.$.find("#Ldt-AnnotationsList-userFilter"),this.userselect_$.change(function(){n.player.trigger("AnnotationsList.refresh")}),this.userselect_$.html("<option selected value='false'>"+this.l10n.everyone+"</option>"),this.usernames.forEach(function(l){var m=n.source.users_data.filter(function(E){return E.username==l}),y={};m.length==0?y.username=l:y=m[0],n.userselect_$.append("<option value='"+l+"'>"+n.make_name_string_function(y)+"</option>")})),this.keyword_filter&&(this.keywordinput_$=this.$.find("#Ldt-AnnotationsList-keywordsFilter"),this.keywordinput_$.keyup(function(){n.player.trigger("AnnotationsList.refresh")})),this.segment_filter&&(this.ignoresegmentcheckbox_$=this.$.find("#Ldt-AnnotationsList-ignoreSegmentsFilter"),this.ignoresegmentcheckbox_$.click(function(){n.player.trigger("AnnotationsList.refresh")})),this.date_filter&&(this.datefilterinput_$=this.$.find("#Ldt-AnnotationsList-dateFilter"),this.datefilterinput_$.datepicker({dateFormat:"dd/mm/yy"}),this.datefilterinput_$.change(function(){n.player.trigger("AnnotationsList.refresh")}),this.current_day_filter&&(currentDate=new Date,this.datefilterinput_$.datepicker("setDate",currentDate))),this.latest_contributions_filter&&(this.latestcontributionscheckbox_$=this.$.find("#Ldt-AnnotationsList-latestContributionsFilter"),this.latestcontributionscheckbox_$.click(function(){n.player.trigger("AnnotationsList.refresh")}))),this.source.getAnnotations().on("search",function(l){n.searchString=l,n.source!==n.currentSource&&(n.currentSource.getAnnotations().search(l),n.throttledRefresh())}),this.source.getAnnotations().on("found",function(){n.throttledRefresh()}),this.source.getAnnotations().on("not-found",function(){n.throttledRefresh()}),this.source.getAnnotations().on("clear-search",function(){n.searchString=!1,n.source!==n.currentSource&&n.currentSource.getAnnotations().trigger("clear-search")}),this.$.find(".Ldt-AnnotationsList-Close").click(function(){n.showScreen("Main")}),this.source.getAnnotations().on("search-cleared",function(){n.throttledRefresh()}),this.onMdpEvent("AnnotationsList.refresh",function(){n.ajax_url&&(n.mashupMode?n.ajaxMashup():n.ajaxSource()),n.throttledRefresh(!1)}),this.onMdpEvent("AnnotationsList.update",function(){n.ajax_url&&(n.mashupMode?n.ajaxMashup():n.ajaxSource()),n.throttledRefresh(!0)}),this.ajax_url?this.mashupMode?this.ajaxMashup():this.ajaxSource():this.currentSource=this.source,this.refresh_interval&&window.setInterval(function(){n.currentSource.get()},this.refresh_interval),this.annotations_count_header&&(this.annotations_count=!1),this.onMdpEvent("AnnotationsList.toggle","toggle"),this.onMdpEvent("AnnotationsList.hide","hide"),this.onMdpEvent("AnnotationsList.show","show"),this.onMdpEvent("createAnnotationWidget.addedAnnotation",this.throttledRefresh);for(var o=["timeupdate","seeked","loadedmetadata","settimerange"],u=0;u<o.length;u++)this.onMediaEvent(o[u],this.throttledRefresh);this.throttledRefresh(),this.showScreen("Main"),this.$.find(".Ldt-AnnotationsList-CancelDelete").click(function(){n.showScreen("Main")}),this.visible=!0,this.start_visible||this.hide()}},Fi(e,"defaults",{pre_draw_callback:function(){return this.importUsers()},ajax_url:!1,ajax_granularity:6e5,default_thumbnail:"",custom_external_icon:"",foreign_url:"",annotation_type:!1,refresh_interval:0,limit_count:20,newest_first:!1,show_title:!0,show_audio:!0,show_creator:!0,show_controls:!1,show_end_time:!0,show_publish:!1,show_twitter:!1,twitter_hashtag:"",on_edit:void 0,publish_type:"PublicContribution",api_endpoint_template:"",api_serializer:"ldt_annotate",api_method:"POST",editable:!1,editable_storage:"",widget_max_height:680,always_visible:!1,start_visible:!0,show_audio:!0,show_filters:!1,keyword_filter:!0,date_filter:!0,user_filter:!0,segment_filter:!0,latest_contributions_filter:!1,current_day_filter:!0,show_header:!1,custom_header:!1,annotations_count_header:!0,annotations_count_header_string:"annotations",show_creation_date:!1,show_timecode:!0,show_end_time:!0,project_id:"",allow_annotations_deletion:!1,api_delete_endpoint:"",api_delete_method:"DELETE",api_users_endpoint:"",api_users_method:"GET",make_name_string_function:function(n){return n.username?n.username:"Anonymous"},filter_by_segments:!1,segment_filter:!0,segments_annotation_type:"chap",show_only_annotation_from_user:!1,tags:!0,polemics:[{keyword:"++",background_color:"#c9ecc6"},{keyword:"--",background_color:"#f9c5c6"},{keyword:"??",background_color:"#cec5f9"},{keyword:"==",background_color:"#f9f4c6"}]}),Fi(e,"messages",{en:{voice_annotation:"Voice Annotation",now_playing:"Now playing...",previous:"Previous",next:"Next",set_time:"Double-click to update to current player time",edit_annotation:"Edit note",delete_annotation:"Delete note",publish_annotation:"Make note public",import_annotations:"Paste or load notes in this field and press Import.",confirm_delete_message:"You are about to delete {{ annotation.title }}. Are you sure you want to delete it?",confirm_publish_message:"You are about to publish {{ annotation.title }}. Are you sure you want to make it public?",tweet_annotation:"Tweet annotation",external_annotation:"This annotation was submitted to another project",everyone:"Everyone",header:"Annotations for this content",segment_filter:"All cuttings",latest_contributions:"Latest contributions",close_widget:"Close",confirm:"Confirm",cancel:"Cancel",annotation_deletion_delete:"You will delete this annotation",annotation_deletion_sending:"Your deletion request is being sent ... ",annotation_deletion_success:"The annotation has been deleted.",annotation_deletion_error:"There was an error contacting the server. The annotation has not been deleted."},fr:{voice_annotation:"Annotation Vocale",now_playing:"Lecture en cours...",previous:"Précédent",next:"Suivant",set_time:"Double-cliquer pour fixer au temps du lecteur",edit_annotation:"Éditer la note",delete_annotation:"Supprimer la note",publish_annotation:"Rendre la note publique",import_annotations:"Copiez ou chargez des notes dans ce champ et appuyez sur Import",confirm_delete_message:"Vous allez supprimer {{ annotation.title }}. Êtes-vous certain(e) ?",confirm_publish_message:"Vous allez publier {{ annotation.title }}. Êtes-vous certain(e) ?",tweet_annotation:"Tweeter l'annotation",external_annotation:"Cette annotation a été postée sur un autre projet",everyone:"Tous",header:"Annotations sur ce contenu",segment_filter:"Tous les segments",latest_contributions:"Dernières contributions",close_widget:"Fermer",confirm:"Confirmer",cancel:"Annuler",annotation_deletion_delete:"Vous allez supprimer cette annotation",annotation_deletion_sending:"Votre demande de suppression est en cours d'envoi ... ",annotation_deletion_success:"L'annotation a été supprimée.",annotation_deletion_error:"Une erreur s'est produite en contactant le serveur. L'annotation n'a pas été supprimée."}}),Fi(e,"template",'{{#show_header}}<p class="Ldt-AnnotationsList-header">{{#custom_header}}{{custom_header}}{{/custom_header}}{{^custom_header}}{{l10n.header}}{{/custom_header}}</p>{{/show_header}}<div class="Ldt-AnnotationsListWidget"><div class="Ldt-AnnotationsList-ScreenMain">{{#show_filters}}<div class="Ldt-AnnotationsList-Filters">{{#keyword_filter}}<input class="Ldt-AnnotationsList-filter-text" id="Ldt-AnnotationsList-keywordsFilter" type="text" value=""></input>{{/keyword_filter}}{{#user_filter}}<select class="Ldt-AnnotationsList-filter-dropdown" id="Ldt-AnnotationsList-userFilter"><option selected value="">{{l10n.everyone}}</option></select>{{/user_filter}}{{#date_filter}}<label class="Ldt-AnnotationsList-filter-date">Date: <input id="Ldt-AnnotationsList-dateFilter" type="text"></input></label>{{/date_filter}}{{#segment_filter}}<label class="Ldt-AnnotationsList-filter-checkbox"><input type="checkbox" id="Ldt-AnnotationsList-ignoreSegmentsFilter">{{l10n.segment_filter}}</label>{{/segment_filter}}{{#latest_contributions_filter}}<label class="Ldt-AnnotationsList-filter-checkbox"><input type="checkbox" id="Ldt-AnnotationsList-latestContributionsFilter">{{l10n.latest_contributions}}</label>{{/latest_contributions_filter}}</div>{{/show_filters}}{{#show_controls}}<div class="Ldt-AnnotationsList-Controls"><span class="Ldt-AnnotationsList-Control-Prev">{{ l10n.previous }}</span> | <span class="Ldt-AnnotationsList-Control-Next">{{ l10n.next }}</span></div>{{/show_controls}}{{#show_audio}}<div class="Ldt-AnnotationsList-Audio"></div>{{/show_audio}}<ul class="Ldt-AnnotationsList-ul"></ul></div>{{#allow_annotations_deletion}}<div data-annotation="{{id}}" class="Ldt-AnnotationsList-Screen Ldt-AnnotationsList-ScreenDelete"><a title="{{l10n.close_widget}}" class="Ldt-AnnotationsList-Close" href="#"></a>{{l10n.annotation_deletion_delete}}<ul class="Ldt-AnnotationsList-ul-ToDelete"></ul><a class="Ldt-AnnotationsList-ConfirmDelete">{{l10n.confirm}}</a> <a class="Ldt-AnnotationsList-CancelDelete">{{l10n.cancel}}</a></div><div data-annotation="{{id}}" class="Ldt-AnnotationsList-Screen Ldt-AnnotationsList-ScreenSending"><a title="{{l10n.close_widget}}" class="Ldt-AnnotationsList-Close" href="#"></a>{{l10n.annotation_deletion_sending}}</div><div data-annotation="{{id}}" class="Ldt-AnnotationsList-Screen Ldt-AnnotationsList-ScreenSuccess"><a title="{{l10n.close_widget}}" class="Ldt-AnnotationsList-Close" href="#"></a>{{l10n.annotation_deletion_success}}</div><div data.annotation="{{id}}" class="Ldt-AnnotationsList-Screen Ldt-AnnotationsList-ScreenError"><a title="{{l10n.close_widget}}" class="Ldt-AnnotationsList-Close" href="#"></a>{{l10n.annotation_deletion_error}}</div>{{/allow_annotations_deletion}}</div>'),Fi(e,"annotationTemplate",'<li class="Ldt-AnnotationsList-li Ldt-Highlighter-Annotation Ldt-TraceMe" data-annotation="{{ id }}" data-begin="{{ begin_ms }}" data-end="{{ end_ms }}" trace-info="annotation-id:{{id}}, media-id:{{media_id}}" style="{{specific_style}}"><div data-annotation="{{ id }}" class="Ldt-AnnotationsList-ThumbContainer Ldt-AnnotationsList-Annotation-Screen Ldt-AnnotationsList-Annotation-ScreenMain"><a {{#url}}href="{{url}}"{{/url}} draggable="true"><img title="{{^external}}{{ begin }} - {{ end }}{{/external}}{{#external}}{{l10n.external_annotation}}{{/external}}" class="Ldt-AnnotationsList-Thumbnail" src="{{thumbnail}}" />{{#external}}<div title="{{l10n.external_annotation}}" class="Ldt-AnnotationsList-External-Icon"></div>{{/external}}</a></div>{{#allow_annotations_deletion}}<div data-annotation="{{ id }}" class="Ldt-AnnotationsList-DeleteButton">&#10006;</div>{{/allow_annotations_deletion}}{{#show_timecode}}<div title="{{l10n.set_time}}" class="Ldt-AnnotationsList-Duration"><span class="Ldt-AnnotationsList-Begin Ldt-live-editable Ldt-AnnotationsList-TimeEdit" data-editable_value="{{begin}}" data-editable_id="{{id}}" data-editable_field="begin" data-editable_type="timestamp">{{begin}}</span>{{#show_end_time}} - <span class="Ldt-AnnotationsList-End Ldt-live-editable" data-editable_value="{{end}}" data-editable_id="{{id}}" data-editable_field="end" data-editable_type="timestamp">{{end}}</span>{{/show_end_time}}</div>{{/show_timecode}}<h3 class="Ldt-AnnotationsList-Title Ldt-Annotation-Timecode" data-timecode="{{ begin_ms }}" draggable="true">{{#show_title}}<span class="Ldt-AnnotationsList-TitleContent Ldt-live-editable" data-editable_value="{{title}}" data-editable_type="multiline" data-editable_id="{{id}}" data-editable_field="title">{{{htitle}}}</span>{{/show_title}}{{#show_creator}}<span class="Ldt-AnnotationsList-Creator">{{ creator }}</span>{{/show_creator}}</h3><p class="Ldt-AnnotationsList-Description Ldt-live-editable" data-editable_type="multiline" data-editable_value="{{description}}" data-editable_id="{{id}}" data-editable_field="description">{{{hdescription}}}</p>{{#created}}<div class="Ldt-AnnotationsList-CreationDate">{{{created}}}</div>{{/created}}{{#tags.length}}<ul class="Ldt-AnnotationsList-Tags">{{#tags}}{{#.}}<li class="Ldt-AnnotationsList-Tag-Li"><span>{{.}}</span></li>{{/.}}{{/tags}}</ul>{{/tags.length}}{{#audio}}<div class="Ldt-AnnotationsList-Play" data-annotation-id="{{id}}">{{l10n.voice_annotation}}</div>{{/audio}}<div class="Ldt-AnnotationsList-EditControls">{{#show_twitter}}<a title="{{l10n.tweet_annotation}}" target="_blank" href="https://twitter.com/intent/tweet?{{twitter_param}}"><img width="16" height="16" src="metadataplayer/img/twitter.svg"></a>{{/show_twitter}}{{#show_publish}}<div title="{{l10n.publish_annotation}}" class="Ldt-AnnotationsList-PublishAnnotation" data-editable_id="{{id}}"></div>{{/show_publish}}{{#editable}}<div title="{{l10n.edit_annotation}}" class="Ldt-AnnotationsList-Edit" data-editable_id="{{id}}"></div><div title="{{l10n.delete_annotation}}" class="Ldt-AnnotationsList-Delete" data-editable_id="{{id}}"></div>{{/editable}}</div></li>'),e};var raphael_min={exports:{}};(function(t,e){(function(n,o){t.exports=o()})(window,function(){return function(n){var o={};function u(l){if(o[l])return o[l].exports;var m=o[l]={i:l,l:!1,exports:{}};return n[l].call(m.exports,m,m.exports,u),m.l=!0,m.exports}return u.m=n,u.c=o,u.d=function(l,m,y){u.o(l,m)||Object.defineProperty(l,m,{enumerable:!0,get:y})},u.r=function(l){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(l,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(l,"__esModule",{value:!0})},u.t=function(l,m){if(1&m&&(l=u(l)),8&m||4&m&&typeof l=="object"&&l&&l.__esModule)return l;var y=Object.create(null);if(u.r(y),Object.defineProperty(y,"default",{enumerable:!0,value:l}),2&m&&typeof l!="string")for(var E in l)u.d(y,E,(function(C){return l[C]}).bind(null,E));return y},u.n=function(l){var m=l&&l.__esModule?function(){return l.default}:function(){return l};return u.d(m,"a",m),m},u.o=function(l,m){return Object.prototype.hasOwnProperty.call(l,m)},u.p="",u(u.s=1)}([function(n,o,u){var l,m;l=[u(2)],(m=(function(y){function E(le){if(E.is(le,"function"))return C?le():y.on("raphael.DOMload",le);if(E.is(le,b))return E._engine.create[N](E,le.splice(0,3+E.is(le[0],S))).add(le);var we=Array.prototype.slice.call(arguments,0);if(E.is(we[we.length-1],"function")){var $e=we.pop();return C?$e.call(E._engine.create[N](E,we)):y.on("raphael.DOMload",function(){$e.call(E._engine.create[N](E,we))})}return E._engine.create[N](E,arguments)}E.version="2.3.0",E.eve=y;var C,k,A=/[, ]+/,D={circle:1,rect:1,path:1,ellipse:1,text:1,image:1},P=/\{(\d+)\}/g,R="hasOwnProperty",B={doc:document,win:window},F={was:Object.prototype[R].call(B.win,"Raphael"),is:B.win.Raphael},j=function(){this.ca=this.customAttributes={}},N="apply",Y="concat",J="ontouchstart"in window||window.TouchEvent||window.DocumentTouch&&document instanceof DocumentTouch,ie="",ue=" ",Q=String,ce="split",he="click dblclick mousedown mousemove mouseout mouseover mouseup touchstart touchmove touchend touchcancel"[ce](ue),ke={mousedown:"touchstart",mousemove:"touchmove",mouseup:"touchend"},L=Q.prototype.toLowerCase,d=Math,v=d.max,w=d.min,c=d.abs,p=d.pow,x=d.PI,S="number",b="array",h=Object.prototype.toString,T=(E._ISURL=/^url\(['"]?(.+?)['"]?\)$/i,/^\s*((#[a-f\d]{6})|(#[a-f\d]{3})|rgba?\(\s*([\d\.]+%?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+%?(?:\s*,\s*[\d\.]+%?)?)\s*\)|hsba?\(\s*([\d\.]+(?:deg|\xb0|%)?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+(?:%?\s*,\s*[\d\.]+)?)%?\s*\)|hsla?\(\s*([\d\.]+(?:deg|\xb0|%)?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+(?:%?\s*,\s*[\d\.]+)?)%?\s*\))\s*$/i),M={NaN:1,Infinity:1,"-Infinity":1},O=/^(?:cubic-)?bezier\(([^,]+),([^,]+),([^,]+),([^\)]+)\)/,V=d.round,ee=parseFloat,Z=parseInt,U=Q.prototype.toUpperCase,z=E._availableAttrs={"arrow-end":"none","arrow-start":"none",blur:0,"clip-rect":"0 0 1e9 1e9",cursor:"default",cx:0,cy:0,fill:"#fff","fill-opacity":1,font:'10px "Arial"',"font-family":'"Arial"',"font-size":"10","font-style":"normal","font-weight":400,gradient:0,height:0,href:"http://raphaeljs.com/","letter-spacing":0,opacity:1,path:"M0,0",r:0,rx:0,ry:0,src:"",stroke:"#000","stroke-dasharray":"","stroke-linecap":"butt","stroke-linejoin":"butt","stroke-miterlimit":0,"stroke-opacity":1,"stroke-width":1,target:"_blank","text-anchor":"middle",title:"Raphael",transform:"",width:0,x:0,y:0,class:""},ne=E._availableAnimAttrs={blur:S,"clip-rect":"csv",cx:S,cy:S,fill:"colour","fill-opacity":S,"font-size":S,height:S,opacity:S,path:"path",r:S,rx:S,ry:S,stroke:"colour","stroke-opacity":S,"stroke-width":S,transform:"transform",width:S,x:S,y:S},fe=/[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*/,me={hs:1,rg:1},de=/,?([achlmqrstvxz]),?/gi,je=/([achlmrqstvz])[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029,]*((-?\d*\.?\d*(?:e[\-+]?\d+)?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*)+)/gi,lt=/([rstm])[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029,]*((-?\d*\.?\d*(?:e[\-+]?\d+)?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*)+)/gi,it=/(-?\d*\.?\d*(?:e[\-+]?\d+)?)[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*/gi,ot=(E._radial_gradient=/^r(?:\(([^,]+?)[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*([^\)]+?)\))?/,{}),Ct=function(le,we){return ee(le)-ee(we)},nt=function(le){return le},Je=E._rectPath=function(le,we,$e,Oe,Ge){return Ge?[["M",le+Ge,we],["l",$e-2*Ge,0],["a",Ge,Ge,0,0,1,Ge,Ge],["l",0,Oe-2*Ge],["a",Ge,Ge,0,0,1,-Ge,Ge],["l",2*Ge-$e,0],["a",Ge,Ge,0,0,1,-Ge,-Ge],["l",0,2*Ge-Oe],["a",Ge,Ge,0,0,1,Ge,-Ge],["z"]]:[["M",le,we],["l",$e,0],["l",0,Oe],["l",-$e,0],["z"]]},tt=function(le,we,$e,Oe){return Oe==null&&(Oe=$e),[["M",le,we],["m",0,-Oe],["a",$e,Oe,0,1,1,0,2*Oe],["a",$e,Oe,0,1,1,0,-2*Oe],["z"]]},rt=E._getPath={path:function(le){return le.attr("path")},circle:function(le){var we=le.attrs;return tt(we.cx,we.cy,we.r)},ellipse:function(le){var we=le.attrs;return tt(we.cx,we.cy,we.rx,we.ry)},rect:function(le){var we=le.attrs;return Je(we.x,we.y,we.width,we.height,we.r)},image:function(le){var we=le.attrs;return Je(we.x,we.y,we.width,we.height)},text:function(le){var we=le._getBBox();return Je(we.x,we.y,we.width,we.height)},set:function(le){var we=le._getBBox();return Je(we.x,we.y,we.width,we.height)}},ht=E.mapPath=function(le,we){if(!we)return le;var $e,Oe,Ge,st,xe,Ee,Ie;for(Ge=0,xe=(le=Xt(le)).length;Ge<xe;Ge++)for(st=1,Ee=(Ie=le[Ge]).length;st<Ee;st+=2)$e=we.x(Ie[st],Ie[st+1]),Oe=we.y(Ie[st],Ie[st+1]),Ie[st]=$e,Ie[st+1]=Oe;return le};if(E._g=B,E.type=B.win.SVGAngle||B.doc.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")?"SVG":"VML",E.type=="VML"){var Ot,Ve=B.doc.createElement("div");if(Ve.innerHTML='<v:shape adj="1"/>',(Ot=Ve.firstChild).style.behavior="url(#default#VML)",!Ot||typeof Ot.adj!="object")return E.type=ie;Ve=null}function We(le){if(typeof le=="function"||Object(le)!==le)return le;var we=new le.constructor;for(var $e in le)le[R]($e)&&(we[$e]=We(le[$e]));return we}E.svg=!(E.vml=E.type=="VML"),E._Paper=j,E.fn=k=j.prototype=E.prototype,E._id=0,E.is=function(le,we){return(we=L.call(we))=="finite"?!M[R](+le):we=="array"?le instanceof Array:we=="null"&&le===null||we==typeof le&&le!==null||we=="object"&&le===Object(le)||we=="array"&&Array.isArray&&Array.isArray(le)||h.call(le).slice(8,-1).toLowerCase()==we},E.angle=function(le,we,$e,Oe,Ge,st){if(Ge==null){var xe=le-$e,Ee=we-Oe;return xe||Ee?(180+180*d.atan2(-Ee,-xe)/x+360)%360:0}return E.angle(le,we,Ge,st)-E.angle($e,Oe,Ge,st)},E.rad=function(le){return le%360*x/180},E.deg=function(le){return Math.round(180*le/x%360*1e3)/1e3},E.snapTo=function(le,we,$e){if($e=E.is($e,"finite")?$e:10,E.is(le,b)){for(var Oe=le.length;Oe--;)if(c(le[Oe]-we)<=$e)return le[Oe]}else{var Ge=we%(le=+le);if(Ge<$e)return we-Ge;if(Ge>le-$e)return we-Ge+le}return we};var Gt,wt;E.createUUID=(Gt=/[xy]/g,wt=function(le){var we=16*d.random()|0;return(le=="x"?we:3&we|8).toString(16)},function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(Gt,wt).toUpperCase()}),E.setWindow=function(le){y("raphael.setWindow",E,B.win,le),B.win=le,B.doc=B.win.document,E._engine.initWin&&E._engine.initWin(B.win)};var Et=function(le){if(E.vml){var we,$e=/^\s+|\s+$/g;try{var Oe=new ActiveXObject("htmlfile");Oe.write("<body>"),Oe.close(),we=Oe.body}catch{we=createPopup().document.body}var Ge=we.createTextRange();Et=Ue(function(xe){try{we.style.color=Q(xe).replace($e,ie);var Ee=Ge.queryCommandValue("ForeColor");return"#"+("000000"+(Ee=(255&Ee)<<16|65280&Ee|(16711680&Ee)>>>16).toString(16)).slice(-6)}catch{return"none"}})}else{var st=B.doc.createElement("i");st.title="Raphaël Colour Picker",st.style.display="none",B.doc.body.appendChild(st),Et=Ue(function(xe){return st.style.color=xe,B.doc.defaultView.getComputedStyle(st,ie).getPropertyValue("color")})}return Et(le)},Yt=function(){return"hsb("+[this.h,this.s,this.b]+")"},Ce=function(){return"hsl("+[this.h,this.s,this.l]+")"},te=function(){return this.hex},ye=function(le,we,$e){if(we==null&&E.is(le,"object")&&"r"in le&&"g"in le&&"b"in le&&($e=le.b,we=le.g,le=le.r),we==null&&E.is(le,"string")){var Oe=E.getRGB(le);le=Oe.r,we=Oe.g,$e=Oe.b}return(le>1||we>1||$e>1)&&(le/=255,we/=255,$e/=255),[le,we,$e]},Le=function(le,we,$e,Oe){var Ge={r:le*=255,g:we*=255,b:$e*=255,hex:E.rgb(le,we,$e),toString:te};return E.is(Oe,"finite")&&(Ge.opacity=Oe),Ge};function Ue(le,we,$e){return function Oe(){var Ge=Array.prototype.slice.call(arguments,0),st=Ge.join("␀"),xe=Oe.cache=Oe.cache||{},Ee=Oe.count=Oe.count||[];return xe[R](st)?(function(Ie,Xe){for(var xt=0,Lt=Ie.length;xt<Lt;xt++)if(Ie[xt]===Xe)return Ie.push(Ie.splice(xt,1)[0])}(Ee,st),$e?$e(xe[st]):xe[st]):(Ee.length>=1e3&&delete xe[Ee.shift()],Ee.push(st),xe[st]=le[N](we,Ge),$e?$e(xe[st]):xe[st])}}E.color=function(le){var we;return E.is(le,"object")&&"h"in le&&"s"in le&&"b"in le?(we=E.hsb2rgb(le),le.r=we.r,le.g=we.g,le.b=we.b,le.hex=we.hex):E.is(le,"object")&&"h"in le&&"s"in le&&"l"in le?(we=E.hsl2rgb(le),le.r=we.r,le.g=we.g,le.b=we.b,le.hex=we.hex):(E.is(le,"string")&&(le=E.getRGB(le)),E.is(le,"object")&&"r"in le&&"g"in le&&"b"in le?(we=E.rgb2hsl(le),le.h=we.h,le.s=we.s,le.l=we.l,we=E.rgb2hsb(le),le.v=we.b):(le={hex:"none"}).r=le.g=le.b=le.h=le.s=le.v=le.l=-1),le.toString=te,le},E.hsb2rgb=function(le,we,$e,Oe){var Ge,st,xe,Ee,Ie;return this.is(le,"object")&&"h"in le&&"s"in le&&"b"in le&&($e=le.b,we=le.s,Oe=le.o,le=le.h),Ee=(Ie=$e*we)*(1-c((le=(le*=360)%360/60)%2-1)),Ge=st=xe=$e-Ie,Le(Ge+=[Ie,Ee,0,0,Ee,Ie][le=~~le],st+=[Ee,Ie,Ie,Ee,0,0][le],xe+=[0,0,Ee,Ie,Ie,Ee][le],Oe)},E.hsl2rgb=function(le,we,$e,Oe){var Ge,st,xe,Ee,Ie;return this.is(le,"object")&&"h"in le&&"s"in le&&"l"in le&&($e=le.l,we=le.s,le=le.h),(le>1||we>1||$e>1)&&(le/=360,we/=100,$e/=100),Ee=(Ie=2*we*($e<.5?$e:1-$e))*(1-c((le=(le*=360)%360/60)%2-1)),Ge=st=xe=$e-Ie/2,Le(Ge+=[Ie,Ee,0,0,Ee,Ie][le=~~le],st+=[Ee,Ie,Ie,Ee,0,0][le],xe+=[0,0,Ee,Ie,Ie,Ee][le],Oe)},E.rgb2hsb=function(le,we,$e){var Oe,Ge;return le=($e=ye(le,we,$e))[0],we=$e[1],$e=$e[2],{h:(((Ge=(Oe=v(le,we,$e))-w(le,we,$e))==0?null:Oe==le?(we-$e)/Ge:Oe==we?($e-le)/Ge+2:(le-we)/Ge+4)+360)%6*60/360,s:Ge==0?0:Ge/Oe,b:Oe,toString:Yt}},E.rgb2hsl=function(le,we,$e){var Oe,Ge,st,xe;return le=($e=ye(le,we,$e))[0],we=$e[1],$e=$e[2],Oe=((Ge=v(le,we,$e))+(st=w(le,we,$e)))/2,{h:(((xe=Ge-st)==0?null:Ge==le?(we-$e)/xe:Ge==we?($e-le)/xe+2:(le-we)/xe+4)+360)%6*60/360,s:xe==0?0:Oe<.5?xe/(2*Oe):xe/(2-2*Oe),l:Oe,toString:Ce}},E._path2string=function(){return this.join(",").replace(de,"$1")},E._preload=function(le,we){var $e=B.doc.createElement("img");$e.style.cssText="position:absolute;left:-9999em;top:-9999em",$e.onload=function(){we.call(this),this.onload=null,B.doc.body.removeChild(this)},$e.onerror=function(){B.doc.body.removeChild(this)},B.doc.body.appendChild($e),$e.src=le};function Qe(){return this.hex}function Ke(le,we){for(var $e=[],Oe=0,Ge=le.length;Ge-2*!we>Oe;Oe+=2){var st=[{x:+le[Oe-2],y:+le[Oe-1]},{x:+le[Oe],y:+le[Oe+1]},{x:+le[Oe+2],y:+le[Oe+3]},{x:+le[Oe+4],y:+le[Oe+5]}];we?Oe?Ge-4==Oe?st[3]={x:+le[0],y:+le[1]}:Ge-2==Oe&&(st[2]={x:+le[0],y:+le[1]},st[3]={x:+le[2],y:+le[3]}):st[0]={x:+le[Ge-2],y:+le[Ge-1]}:Ge-4==Oe?st[3]=st[2]:Oe||(st[0]={x:+le[Oe],y:+le[Oe+1]}),$e.push(["C",(-st[0].x+6*st[1].x+st[2].x)/6,(-st[0].y+6*st[1].y+st[2].y)/6,(st[1].x+6*st[2].x-st[3].x)/6,(st[1].y+6*st[2].y-st[3].y)/6,st[2].x,st[2].y])}return $e}E.getRGB=Ue(function(le){if(!le||(le=Q(le)).indexOf("-")+1)return{r:-1,g:-1,b:-1,hex:"none",error:1,toString:Qe};if(le=="none")return{r:-1,g:-1,b:-1,hex:"none",toString:Qe};!me[R](le.toLowerCase().substring(0,2))&&le.charAt()!="#"&&(le=Et(le));var we,$e,Oe,Ge,st,xe,Ee=le.match(T);return Ee?(Ee[2]&&(Oe=Z(Ee[2].substring(5),16),$e=Z(Ee[2].substring(3,5),16),we=Z(Ee[2].substring(1,3),16)),Ee[3]&&(Oe=Z((st=Ee[3].charAt(3))+st,16),$e=Z((st=Ee[3].charAt(2))+st,16),we=Z((st=Ee[3].charAt(1))+st,16)),Ee[4]&&(xe=Ee[4][ce](fe),we=ee(xe[0]),xe[0].slice(-1)=="%"&&(we*=2.55),$e=ee(xe[1]),xe[1].slice(-1)=="%"&&($e*=2.55),Oe=ee(xe[2]),xe[2].slice(-1)=="%"&&(Oe*=2.55),Ee[1].toLowerCase().slice(0,4)=="rgba"&&(Ge=ee(xe[3])),xe[3]&&xe[3].slice(-1)=="%"&&(Ge/=100)),Ee[5]?(xe=Ee[5][ce](fe),we=ee(xe[0]),xe[0].slice(-1)=="%"&&(we*=2.55),$e=ee(xe[1]),xe[1].slice(-1)=="%"&&($e*=2.55),Oe=ee(xe[2]),xe[2].slice(-1)=="%"&&(Oe*=2.55),(xe[0].slice(-3)=="deg"||xe[0].slice(-1)=="°")&&(we/=360),Ee[1].toLowerCase().slice(0,4)=="hsba"&&(Ge=ee(xe[3])),xe[3]&&xe[3].slice(-1)=="%"&&(Ge/=100),E.hsb2rgb(we,$e,Oe,Ge)):Ee[6]?(xe=Ee[6][ce](fe),we=ee(xe[0]),xe[0].slice(-1)=="%"&&(we*=2.55),$e=ee(xe[1]),xe[1].slice(-1)=="%"&&($e*=2.55),Oe=ee(xe[2]),xe[2].slice(-1)=="%"&&(Oe*=2.55),(xe[0].slice(-3)=="deg"||xe[0].slice(-1)=="°")&&(we/=360),Ee[1].toLowerCase().slice(0,4)=="hsla"&&(Ge=ee(xe[3])),xe[3]&&xe[3].slice(-1)=="%"&&(Ge/=100),E.hsl2rgb(we,$e,Oe,Ge)):((Ee={r:we,g:$e,b:Oe,toString:Qe}).hex="#"+(16777216|Oe|$e<<8|we<<16).toString(16).slice(1),E.is(Ge,"finite")&&(Ee.opacity=Ge),Ee)):{r:-1,g:-1,b:-1,hex:"none",error:1,toString:Qe}},E),E.hsb=Ue(function(le,we,$e){return E.hsb2rgb(le,we,$e).hex}),E.hsl=Ue(function(le,we,$e){return E.hsl2rgb(le,we,$e).hex}),E.rgb=Ue(function(le,we,$e){function Oe(Ge){return Ge+.5|0}return"#"+(16777216|Oe($e)|Oe(we)<<8|Oe(le)<<16).toString(16).slice(1)}),E.getColor=function(le){var we=this.getColor.start=this.getColor.start||{h:0,s:1,b:le||.75},$e=this.hsb2rgb(we.h,we.s,we.b);return we.h+=.075,we.h>1&&(we.h=0,we.s-=.2,we.s<=0&&(this.getColor.start={h:0,s:1,b:we.b})),$e.hex},E.getColor.reset=function(){delete this.start},E.parsePathString=function(le){if(!le)return null;var we=De(le);if(we.arr)return vt(we.arr);var $e={a:7,c:6,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,z:0},Oe=[];return E.is(le,b)&&E.is(le[0],b)&&(Oe=vt(le)),Oe.length||Q(le).replace(je,function(Ge,st,xe){var Ee=[],Ie=st.toLowerCase();if(xe.replace(it,function(Xe,xt){xt&&Ee.push(+xt)}),Ie=="m"&&Ee.length>2&&(Oe.push([st][Y](Ee.splice(0,2))),Ie="l",st=st=="m"?"l":"L"),Ie=="r")Oe.push([st][Y](Ee));else for(;Ee.length>=$e[Ie]&&(Oe.push([st][Y](Ee.splice(0,$e[Ie]))),$e[Ie]););}),Oe.toString=E._path2string,we.arr=vt(Oe),Oe},E.parseTransformString=Ue(function(le){if(!le)return null;var we=[];return E.is(le,b)&&E.is(le[0],b)&&(we=vt(le)),we.length||Q(le).replace(lt,function($e,Oe,Ge){var st=[];L.call(Oe),Ge.replace(it,function(xe,Ee){Ee&&st.push(+Ee)}),we.push([Oe][Y](st))}),we.toString=E._path2string,we},this,function(le){if(!le)return le;for(var we=[],$e=0;$e<le.length;$e++){for(var Oe=[],Ge=0;Ge<le[$e].length;Ge++)Oe.push(le[$e][Ge]);we.push(Oe)}return we});var De=function(le){var we=De.ps=De.ps||{};return we[le]?we[le].sleep=100:we[le]={sleep:100},setTimeout(function(){for(var $e in we)we[R]($e)&&$e!=le&&(we[$e].sleep--,!we[$e].sleep&&delete we[$e])}),we[le]};function Vt(le,we,$e,Oe,Ge){return le*(le*(-3*we+9*$e-9*Oe+3*Ge)+6*we-12*$e+6*Oe)-3*we+3*$e}function At(le,we,$e,Oe,Ge,st,xe,Ee,Ie){Ie==null&&(Ie=1);for(var Xe=(Ie=Ie>1?1:Ie<0?0:Ie)/2,xt=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],Lt=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],Ft=0,jt=0;jt<12;jt++){var si=Xe*xt[jt]+Xe,yi=Vt(si,le,$e,Ge,xe),vi=Vt(si,we,Oe,st,Ee),li=yi*yi+vi*vi;Ft+=Lt[jt]*d.sqrt(li)}return Xe*Ft}function ve(le,we,$e,Oe,Ge,st,xe,Ee){if(!(v(le,$e)<w(Ge,xe)||w(le,$e)>v(Ge,xe)||v(we,Oe)<w(st,Ee)||w(we,Oe)>v(st,Ee))){var Ie=(le-$e)*(st-Ee)-(we-Oe)*(Ge-xe);if(Ie){var Xe=((le*Oe-we*$e)*(Ge-xe)-(le-$e)*(Ge*Ee-st*xe))/Ie,xt=((le*Oe-we*$e)*(st-Ee)-(we-Oe)*(Ge*Ee-st*xe))/Ie,Lt=+Xe.toFixed(2),Ft=+xt.toFixed(2);if(!(Lt<+w(le,$e).toFixed(2)||Lt>+v(le,$e).toFixed(2)||Lt<+w(Ge,xe).toFixed(2)||Lt>+v(Ge,xe).toFixed(2)||Ft<+w(we,Oe).toFixed(2)||Ft>+v(we,Oe).toFixed(2)||Ft<+w(st,Ee).toFixed(2)||Ft>+v(st,Ee).toFixed(2)))return{x:Xe,y:xt}}}}function Pt(le,we,$e){var Oe=E.bezierBBox(le),Ge=E.bezierBBox(we);if(!E.isBBoxIntersect(Oe,Ge))return $e?0:[];for(var st=At.apply(0,le),xe=At.apply(0,we),Ee=v(~~(st/5),1),Ie=v(~~(xe/5),1),Xe=[],xt=[],Lt={},Ft=$e?0:[],jt=0;jt<Ee+1;jt++){var si=E.findDotsAtSegment.apply(E,le.concat(jt/Ee));Xe.push({x:si.x,y:si.y,t:jt/Ee})}for(jt=0;jt<Ie+1;jt++)si=E.findDotsAtSegment.apply(E,we.concat(jt/Ie)),xt.push({x:si.x,y:si.y,t:jt/Ie});for(jt=0;jt<Ee;jt++)for(var yi=0;yi<Ie;yi++){var vi=Xe[jt],li=Xe[jt+1],Vi=xt[yi],Ei=xt[yi+1],$i=c(li.x-vi.x)<.001?"y":"x",xi=c(Ei.x-Vi.x)<.001?"y":"x",ir=ve(vi.x,vi.y,li.x,li.y,Vi.x,Vi.y,Ei.x,Ei.y);if(ir){if(Lt[ir.x.toFixed(4)]==ir.y.toFixed(4))continue;Lt[ir.x.toFixed(4)]=ir.y.toFixed(4);var Ji=vi.t+c((ir[$i]-vi[$i])/(li[$i]-vi[$i]))*(li.t-vi.t),ur=Vi.t+c((ir[xi]-Vi[xi])/(Ei[xi]-Vi[xi]))*(Ei.t-Vi.t);Ji>=0&&Ji<=1.001&&ur>=0&&ur<=1.001&&($e?Ft++:Ft.push({x:ir.x,y:ir.y,t1:w(Ji,1),t2:w(ur,1)}))}}return Ft}function pt(le,we,$e){le=E._path2curve(le),we=E._path2curve(we);for(var Oe,Ge,st,xe,Ee,Ie,Xe,xt,Lt,Ft,jt=$e?0:[],si=0,yi=le.length;si<yi;si++){var vi=le[si];if(vi[0]=="M")Oe=Ee=vi[1],Ge=Ie=vi[2];else{vi[0]=="C"?(Lt=[Oe,Ge].concat(vi.slice(1)),Oe=Lt[6],Ge=Lt[7]):(Lt=[Oe,Ge,Oe,Ge,Ee,Ie,Ee,Ie],Oe=Ee,Ge=Ie);for(var li=0,Vi=we.length;li<Vi;li++){var Ei=we[li];if(Ei[0]=="M")st=Xe=Ei[1],xe=xt=Ei[2];else{Ei[0]=="C"?(Ft=[st,xe].concat(Ei.slice(1)),st=Ft[6],xe=Ft[7]):(Ft=[st,xe,st,xe,Xe,xt,Xe,xt],st=Xe,xe=xt);var $i=Pt(Lt,Ft,$e);if($e)jt+=$i;else{for(var xi=0,ir=$i.length;xi<ir;xi++)$i[xi].segment1=si,$i[xi].segment2=li,$i[xi].bez1=Lt,$i[xi].bez2=Ft;jt=jt.concat($i)}}}}}return jt}E.findDotsAtSegment=function(le,we,$e,Oe,Ge,st,xe,Ee,Ie){var Xe=1-Ie,xt=p(Xe,3),Lt=p(Xe,2),Ft=Ie*Ie,jt=Ft*Ie,si=xt*le+3*Lt*Ie*$e+3*Xe*Ie*Ie*Ge+jt*xe,yi=xt*we+3*Lt*Ie*Oe+3*Xe*Ie*Ie*st+jt*Ee,vi=le+2*Ie*($e-le)+Ft*(Ge-2*$e+le),li=we+2*Ie*(Oe-we)+Ft*(st-2*Oe+we),Vi=$e+2*Ie*(Ge-$e)+Ft*(xe-2*Ge+$e),Ei=Oe+2*Ie*(st-Oe)+Ft*(Ee-2*st+Oe),$i=Xe*le+Ie*$e,xi=Xe*we+Ie*Oe,ir=Xe*Ge+Ie*xe,Ji=Xe*st+Ie*Ee,ur=90-180*d.atan2(vi-Vi,li-Ei)/x;return(vi>Vi||li<Ei)&&(ur+=180),{x:si,y:yi,m:{x:vi,y:li},n:{x:Vi,y:Ei},start:{x:$i,y:xi},end:{x:ir,y:Ji},alpha:ur}},E.bezierBBox=function(le,we,$e,Oe,Ge,st,xe,Ee){E.is(le,"array")||(le=[le,we,$e,Oe,Ge,st,xe,Ee]);var Ie=Ut.apply(null,le);return{x:Ie.min.x,y:Ie.min.y,x2:Ie.max.x,y2:Ie.max.y,width:Ie.max.x-Ie.min.x,height:Ie.max.y-Ie.min.y}},E.isPointInsideBBox=function(le,we,$e){return we>=le.x&&we<=le.x2&&$e>=le.y&&$e<=le.y2},E.isBBoxIntersect=function(le,we){var $e=E.isPointInsideBBox;return $e(we,le.x,le.y)||$e(we,le.x2,le.y)||$e(we,le.x,le.y2)||$e(we,le.x2,le.y2)||$e(le,we.x,we.y)||$e(le,we.x2,we.y)||$e(le,we.x,we.y2)||$e(le,we.x2,we.y2)||(le.x<we.x2&&le.x>we.x||we.x<le.x2&&we.x>le.x)&&(le.y<we.y2&&le.y>we.y||we.y<le.y2&&we.y>le.y)},E.pathIntersection=function(le,we){return pt(le,we)},E.pathIntersectionNumber=function(le,we){return pt(le,we,1)},E.isPointInsidePath=function(le,we,$e){var Oe=E.pathBBox(le);return E.isPointInsideBBox(Oe,we,$e)&&pt(le,[["M",we,$e],["H",Oe.x2+10]],1)%2==1},E._removedFactory=function(le){return function(){y("raphael.log",null,"Raphaël: you are calling to method “"+le+"” of removed object",le)}};var Ne=E.pathBBox=function(le){var we=De(le);if(we.bbox)return We(we.bbox);if(!le)return{x:0,y:0,width:0,height:0,x2:0,y2:0};for(var $e,Oe=0,Ge=0,st=[],xe=[],Ee=0,Ie=(le=Xt(le)).length;Ee<Ie;Ee++)if(($e=le[Ee])[0]=="M")Oe=$e[1],Ge=$e[2],st.push(Oe),xe.push(Ge);else{var Xe=Ut(Oe,Ge,$e[1],$e[2],$e[3],$e[4],$e[5],$e[6]);st=st[Y](Xe.min.x,Xe.max.x),xe=xe[Y](Xe.min.y,Xe.max.y),Oe=$e[5],Ge=$e[6]}var xt=w[N](0,st),Lt=w[N](0,xe),Ft=v[N](0,st),jt=v[N](0,xe),si=Ft-xt,yi=jt-Lt,vi={x:xt,y:Lt,x2:Ft,y2:jt,width:si,height:yi,cx:xt+si/2,cy:Lt+yi/2};return we.bbox=We(vi),vi},vt=function(le){var we=We(le);return we.toString=E._path2string,we},ut=E._pathToRelative=function(le){var we=De(le);if(we.rel)return vt(we.rel);E.is(le,b)&&E.is(le&&le[0],b)||(le=E.parsePathString(le));var $e=[],Oe=0,Ge=0,st=0,xe=0,Ee=0;le[0][0]=="M"&&(st=Oe=le[0][1],xe=Ge=le[0][2],Ee++,$e.push(["M",Oe,Ge]));for(var Ie=Ee,Xe=le.length;Ie<Xe;Ie++){var xt=$e[Ie]=[],Lt=le[Ie];if(Lt[0]!=L.call(Lt[0]))switch(xt[0]=L.call(Lt[0]),xt[0]){case"a":xt[1]=Lt[1],xt[2]=Lt[2],xt[3]=Lt[3],xt[4]=Lt[4],xt[5]=Lt[5],xt[6]=+(Lt[6]-Oe).toFixed(3),xt[7]=+(Lt[7]-Ge).toFixed(3);break;case"v":xt[1]=+(Lt[1]-Ge).toFixed(3);break;case"m":st=Lt[1],xe=Lt[2];default:for(var Ft=1,jt=Lt.length;Ft<jt;Ft++)xt[Ft]=+(Lt[Ft]-(Ft%2?Oe:Ge)).toFixed(3)}else{xt=$e[Ie]=[],Lt[0]=="m"&&(st=Lt[1]+Oe,xe=Lt[2]+Ge);for(var si=0,yi=Lt.length;si<yi;si++)$e[Ie][si]=Lt[si]}var vi=$e[Ie].length;switch($e[Ie][0]){case"z":Oe=st,Ge=xe;break;case"h":Oe+=+$e[Ie][vi-1];break;case"v":Ge+=+$e[Ie][vi-1];break;default:Oe+=+$e[Ie][vi-2],Ge+=+$e[Ie][vi-1]}}return $e.toString=E._path2string,we.rel=vt($e),$e},$t=E._pathToAbsolute=function(le){var we=De(le);if(we.abs)return vt(we.abs);if(E.is(le,b)&&E.is(le&&le[0],b)||(le=E.parsePathString(le)),!le||!le.length)return[["M",0,0]];var $e=[],Oe=0,Ge=0,st=0,xe=0,Ee=0;le[0][0]=="M"&&(st=Oe=+le[0][1],xe=Ge=+le[0][2],Ee++,$e[0]=["M",Oe,Ge]);for(var Ie,Xe,xt=le.length==3&&le[0][0]=="M"&&le[1][0].toUpperCase()=="R"&&le[2][0].toUpperCase()=="Z",Lt=Ee,Ft=le.length;Lt<Ft;Lt++){if($e.push(Ie=[]),(Xe=le[Lt])[0]!=U.call(Xe[0]))switch(Ie[0]=U.call(Xe[0]),Ie[0]){case"A":Ie[1]=Xe[1],Ie[2]=Xe[2],Ie[3]=Xe[3],Ie[4]=Xe[4],Ie[5]=Xe[5],Ie[6]=+(Xe[6]+Oe),Ie[7]=+(Xe[7]+Ge);break;case"V":Ie[1]=+Xe[1]+Ge;break;case"H":Ie[1]=+Xe[1]+Oe;break;case"R":for(var jt=[Oe,Ge][Y](Xe.slice(1)),si=2,yi=jt.length;si<yi;si++)jt[si]=+jt[si]+Oe,jt[++si]=+jt[si]+Ge;$e.pop(),$e=$e[Y](Ke(jt,xt));break;case"M":st=+Xe[1]+Oe,xe=+Xe[2]+Ge;default:for(si=1,yi=Xe.length;si<yi;si++)Ie[si]=+Xe[si]+(si%2?Oe:Ge)}else if(Xe[0]=="R")jt=[Oe,Ge][Y](Xe.slice(1)),$e.pop(),$e=$e[Y](Ke(jt,xt)),Ie=["R"][Y](Xe.slice(-2));else for(var vi=0,li=Xe.length;vi<li;vi++)Ie[vi]=Xe[vi];switch(Ie[0]){case"Z":Oe=st,Ge=xe;break;case"H":Oe=Ie[1];break;case"V":Ge=Ie[1];break;case"M":st=Ie[Ie.length-2],xe=Ie[Ie.length-1];default:Oe=Ie[Ie.length-2],Ge=Ie[Ie.length-1]}}return $e.toString=E._path2string,we.abs=vt($e),$e},fi=function(le,we,$e,Oe){return[le,we,$e,Oe,$e,Oe]},kt=function(le,we,$e,Oe,Ge,st){return[1/3*le+2/3*$e,1/3*we+2/3*Oe,1/3*Ge+2/3*$e,1/3*st+2/3*Oe,Ge,st]},Wt=function(le,we,$e,Oe,Ge,st,xe,Ee,Ie,Xe){var xt,Lt=120*x/180,Ft=x/180*(+Ge||0),jt=[],si=Ue(function(X,ae,Te){return{x:X*d.cos(Te)-ae*d.sin(Te),y:X*d.sin(Te)+ae*d.cos(Te)}});if(Xe)Ji=Xe[0],ur=Xe[1],xi=Xe[2],ir=Xe[3];else{le=(xt=si(le,we,-Ft)).x,we=xt.y,Ee=(xt=si(Ee,Ie,-Ft)).x,Ie=xt.y;var yi=(le-Ee)/2,vi=(we-Ie)/2,li=yi*yi/($e*$e)+vi*vi/(Oe*Oe);li>1&&($e*=li=d.sqrt(li),Oe*=li);var Vi=$e*$e,Ei=Oe*Oe,$i=(st==xe?-1:1)*d.sqrt(c((Vi*Ei-Vi*vi*vi-Ei*yi*yi)/(Vi*vi*vi+Ei*yi*yi))),xi=$i*$e*vi/Oe+(le+Ee)/2,ir=$i*-Oe*yi/$e+(we+Ie)/2,Ji=d.asin(((we-ir)/Oe).toFixed(9)),ur=d.asin(((Ie-ir)/Oe).toFixed(9));(Ji=le<xi?x-Ji:Ji)<0&&(Ji=2*x+Ji),(ur=Ee<xi?x-ur:ur)<0&&(ur=2*x+ur),xe&&Ji>ur&&(Ji-=2*x),!xe&&ur>Ji&&(ur-=2*x)}var zn=ur-Ji;if(c(zn)>Lt){var Un=ur,_r=Ee,xr=Ie;ur=Ji+Lt*(xe&&ur>Ji?1:-1),Ee=xi+$e*d.cos(ur),Ie=ir+Oe*d.sin(ur),jt=Wt(Ee,Ie,$e,Oe,Ge,0,xe,_r,xr,[ur,Un,xi,ir])}zn=ur-Ji;var En=d.cos(Ji),kn=d.sin(Ji),ia=d.cos(ur),pn=d.sin(ur),yn=d.tan(zn/4),ca=4/3*$e*yn,_a=4/3*Oe*yn,fa=[le,we],$r=[le+ca*kn,we-_a*En],Hn=[Ee+ca*pn,Ie-_a*ia],Zr=[Ee,Ie];if($r[0]=2*fa[0]-$r[0],$r[1]=2*fa[1]-$r[1],Xe)return[$r,Hn,Zr][Y](jt);for(var xa=[],mn=0,tn=(jt=[$r,Hn,Zr][Y](jt).join()[ce](",")).length;mn<tn;mn++)xa[mn]=mn%2?si(jt[mn-1],jt[mn],Ft).y:si(jt[mn],jt[mn+1],Ft).x;return xa},Zi=function(le,we,$e,Oe,Ge,st,xe,Ee,Ie){var Xe=1-Ie;return{x:p(Xe,3)*le+3*p(Xe,2)*Ie*$e+3*Xe*Ie*Ie*Ge+p(Ie,3)*xe,y:p(Xe,3)*we+3*p(Xe,2)*Ie*Oe+3*Xe*Ie*Ie*st+p(Ie,3)*Ee}},Ut=Ue(function(le,we,$e,Oe,Ge,st,xe,Ee){var Ie,Xe=Ge-2*$e+le-(xe-2*Ge+$e),xt=2*($e-le)-2*(Ge-$e),Lt=le-$e,Ft=(-xt+d.sqrt(xt*xt-4*Xe*Lt))/2/Xe,jt=(-xt-d.sqrt(xt*xt-4*Xe*Lt))/2/Xe,si=[we,Ee],yi=[le,xe];return c(Ft)>"1e12"&&(Ft=.5),c(jt)>"1e12"&&(jt=.5),Ft>0&&Ft<1&&(Ie=Zi(le,we,$e,Oe,Ge,st,xe,Ee,Ft),yi.push(Ie.x),si.push(Ie.y)),jt>0&&jt<1&&(Ie=Zi(le,we,$e,Oe,Ge,st,xe,Ee,jt),yi.push(Ie.x),si.push(Ie.y)),Xe=st-2*Oe+we-(Ee-2*st+Oe),Lt=we-Oe,Ft=(-(xt=2*(Oe-we)-2*(st-Oe))+d.sqrt(xt*xt-4*Xe*Lt))/2/Xe,jt=(-xt-d.sqrt(xt*xt-4*Xe*Lt))/2/Xe,c(Ft)>"1e12"&&(Ft=.5),c(jt)>"1e12"&&(jt=.5),Ft>0&&Ft<1&&(Ie=Zi(le,we,$e,Oe,Ge,st,xe,Ee,Ft),yi.push(Ie.x),si.push(Ie.y)),jt>0&&jt<1&&(Ie=Zi(le,we,$e,Oe,Ge,st,xe,Ee,jt),yi.push(Ie.x),si.push(Ie.y)),{min:{x:w[N](0,yi),y:w[N](0,si)},max:{x:v[N](0,yi),y:v[N](0,si)}}}),Xt=E._path2curve=Ue(function(le,we){var $e=!we&&De(le);if(!we&&$e.curve)return vt($e.curve);for(var Oe=$t(le),Ge=we&&$t(we),st={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},xe={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},Ee=function($i,xi,ir){var Ji,ur;if(!$i)return["C",xi.x,xi.y,xi.x,xi.y,xi.x,xi.y];switch(!($i[0]in{T:1,Q:1})&&(xi.qx=xi.qy=null),$i[0]){case"M":xi.X=$i[1],xi.Y=$i[2];break;case"A":$i=["C"][Y](Wt[N](0,[xi.x,xi.y][Y]($i.slice(1))));break;case"S":ir=="C"||ir=="S"?(Ji=2*xi.x-xi.bx,ur=2*xi.y-xi.by):(Ji=xi.x,ur=xi.y),$i=["C",Ji,ur][Y]($i.slice(1));break;case"T":ir=="Q"||ir=="T"?(xi.qx=2*xi.x-xi.qx,xi.qy=2*xi.y-xi.qy):(xi.qx=xi.x,xi.qy=xi.y),$i=["C"][Y](kt(xi.x,xi.y,xi.qx,xi.qy,$i[1],$i[2]));break;case"Q":xi.qx=$i[1],xi.qy=$i[2],$i=["C"][Y](kt(xi.x,xi.y,$i[1],$i[2],$i[3],$i[4]));break;case"L":$i=["C"][Y](fi(xi.x,xi.y,$i[1],$i[2]));break;case"H":$i=["C"][Y](fi(xi.x,xi.y,$i[1],xi.y));break;case"V":$i=["C"][Y](fi(xi.x,xi.y,xi.x,$i[1]));break;case"Z":$i=["C"][Y](fi(xi.x,xi.y,xi.X,xi.Y))}return $i},Ie=function($i,xi){if($i[xi].length>7){$i[xi].shift();for(var ir=$i[xi];ir.length;)xt[xi]="A",Ge&&(Lt[xi]="A"),$i.splice(xi++,0,["C"][Y](ir.splice(0,6)));$i.splice(xi,1),yi=v(Oe.length,Ge&&Ge.length||0)}},Xe=function($i,xi,ir,Ji,ur){$i&&xi&&$i[ur][0]=="M"&&xi[ur][0]!="M"&&(xi.splice(ur,0,["M",Ji.x,Ji.y]),ir.bx=0,ir.by=0,ir.x=$i[ur][1],ir.y=$i[ur][2],yi=v(Oe.length,Ge&&Ge.length||0))},xt=[],Lt=[],Ft="",jt="",si=0,yi=v(Oe.length,Ge&&Ge.length||0);si<yi;si++){Oe[si]&&(Ft=Oe[si][0]),Ft!="C"&&(xt[si]=Ft,si&&(jt=xt[si-1])),Oe[si]=Ee(Oe[si],st,jt),xt[si]!="A"&&Ft=="C"&&(xt[si]="C"),Ie(Oe,si),Ge&&(Ge[si]&&(Ft=Ge[si][0]),Ft!="C"&&(Lt[si]=Ft,si&&(jt=Lt[si-1])),Ge[si]=Ee(Ge[si],xe,jt),Lt[si]!="A"&&Ft=="C"&&(Lt[si]="C"),Ie(Ge,si)),Xe(Oe,Ge,st,xe,si),Xe(Ge,Oe,xe,st,si);var vi=Oe[si],li=Ge&&Ge[si],Vi=vi.length,Ei=Ge&&li.length;st.x=vi[Vi-2],st.y=vi[Vi-1],st.bx=ee(vi[Vi-4])||st.x,st.by=ee(vi[Vi-3])||st.y,xe.bx=Ge&&(ee(li[Ei-4])||xe.x),xe.by=Ge&&(ee(li[Ei-3])||xe.y),xe.x=Ge&&li[Ei-2],xe.y=Ge&&li[Ei-1]}return Ge||($e.curve=vt(Oe)),Ge?[Oe,Ge]:Oe},null,vt),Be=(E._parseDots=Ue(function(le){for(var we=[],$e=0,Oe=le.length;$e<Oe;$e++){var Ge={},st=le[$e].match(/^([^:]*):?([\d\.]*)/);if(Ge.color=E.getRGB(st[1]),Ge.color.error)return null;Ge.opacity=Ge.color.opacity,Ge.color=Ge.color.hex,st[2]&&(Ge.offset=st[2]+"%"),we.push(Ge)}for($e=1,Oe=we.length-1;$e<Oe;$e++)if(!we[$e].offset){for(var xe=ee(we[$e-1].offset||0),Ee=0,Ie=$e+1;Ie<Oe;Ie++)if(we[Ie].offset){Ee=we[Ie].offset;break}Ee||(Ee=100,Ie=Oe);for(var Xe=((Ee=ee(Ee))-xe)/(Ie-$e+1);$e<Ie;$e++)xe+=Xe,we[$e].offset=xe+"%"}return we}),E._tear=function(le,we){le==we.top&&(we.top=le.prev),le==we.bottom&&(we.bottom=le.next),le.next&&(le.next.prev=le.prev),le.prev&&(le.prev.next=le.next)}),be=(E._tofront=function(le,we){we.top!==le&&(Be(le,we),le.next=null,le.prev=we.top,we.top.next=le,we.top=le)},E._toback=function(le,we){we.bottom!==le&&(Be(le,we),le.next=we.bottom,le.prev=null,we.bottom.prev=le,we.bottom=le)},E._insertafter=function(le,we,$e){Be(le,$e),we==$e.top&&($e.top=le),we.next&&(we.next.prev=le),le.next=we.next,le.prev=we,we.next=le},E._insertbefore=function(le,we,$e){Be(le,$e),we==$e.bottom&&($e.bottom=le),we.prev&&(we.prev.next=le),le.prev=we.prev,we.prev=le,le.next=we},E.toMatrix=function(le,we){var $e=Ne(le),Oe={_:{transform:ie},getBBox:function(){return $e}};return ge(Oe,we),Oe.matrix}),ge=(E.transformPath=function(le,we){return ht(le,be(le,we))},E._extractTransform=function(le,we){if(we==null)return le._.transform;we=Q(we).replace(/\.{3}|\u2026/g,le._.transform||ie);var $e,Oe,Ge=E.parseTransformString(we),st=0,xe=1,Ee=1,Ie=le._,Xe=new qe;if(Ie.transform=Ge||[],Ge)for(var xt=0,Lt=Ge.length;xt<Lt;xt++){var Ft,jt,si,yi,vi,li=Ge[xt],Vi=li.length,Ei=Q(li[0]).toLowerCase(),$i=li[0]!=Ei,xi=$i?Xe.invert():0;Ei=="t"&&Vi==3?$i?(Ft=xi.x(0,0),jt=xi.y(0,0),si=xi.x(li[1],li[2]),yi=xi.y(li[1],li[2]),Xe.translate(si-Ft,yi-jt)):Xe.translate(li[1],li[2]):Ei=="r"?Vi==2?(vi=vi||le.getBBox(1),Xe.rotate(li[1],vi.x+vi.width/2,vi.y+vi.height/2),st+=li[1]):Vi==4&&($i?(si=xi.x(li[2],li[3]),yi=xi.y(li[2],li[3]),Xe.rotate(li[1],si,yi)):Xe.rotate(li[1],li[2],li[3]),st+=li[1]):Ei=="s"?Vi==2||Vi==3?(vi=vi||le.getBBox(1),Xe.scale(li[1],li[Vi-1],vi.x+vi.width/2,vi.y+vi.height/2),xe*=li[1],Ee*=li[Vi-1]):Vi==5&&($i?(si=xi.x(li[3],li[4]),yi=xi.y(li[3],li[4]),Xe.scale(li[1],li[2],si,yi)):Xe.scale(li[1],li[2],li[3],li[4]),xe*=li[1],Ee*=li[2]):Ei=="m"&&Vi==7&&Xe.add(li[1],li[2],li[3],li[4],li[5],li[6]),Ie.dirtyT=1,le.matrix=Xe}le.matrix=Xe,Ie.sx=xe,Ie.sy=Ee,Ie.deg=st,Ie.dx=$e=Xe.e,Ie.dy=Oe=Xe.f,xe==1&&Ee==1&&!st&&Ie.bbox?(Ie.bbox.x+=+$e,Ie.bbox.y+=+Oe):Ie.dirtyT=1}),oe=function(le){var we=le[0];switch(we.toLowerCase()){case"t":return[we,0,0];case"m":return[we,1,0,0,1,0,0];case"r":return le.length==4?[we,0,le[2],le[3]]:[we,0];case"s":return le.length==5?[we,1,1,le[3],le[4]]:le.length==3?[we,1,1]:[we,1]}},Ae=E._equaliseTransform=function(le,we){we=Q(we).replace(/\.{3}|\u2026/g,le),le=E.parseTransformString(le)||[],we=E.parseTransformString(we)||[];for(var $e,Oe,Ge,st,xe=v(le.length,we.length),Ee=[],Ie=[],Xe=0;Xe<xe;Xe++){if(Ge=le[Xe]||oe(we[Xe]),st=we[Xe]||oe(Ge),Ge[0]!=st[0]||Ge[0].toLowerCase()=="r"&&(Ge[2]!=st[2]||Ge[3]!=st[3])||Ge[0].toLowerCase()=="s"&&(Ge[3]!=st[3]||Ge[4]!=st[4]))return;for(Ee[Xe]=[],Ie[Xe]=[],$e=0,Oe=v(Ge.length,st.length);$e<Oe;$e++)$e in Ge&&(Ee[Xe][$e]=Ge[$e]),$e in st&&(Ie[Xe][$e]=st[$e])}return{from:Ee,to:Ie}};function qe(le,we,$e,Oe,Ge,st){le!=null?(this.a=+le,this.b=+we,this.c=+$e,this.d=+Oe,this.e=+Ge,this.f=+st):(this.a=1,this.b=0,this.c=0,this.d=1,this.e=0,this.f=0)}E._getContainer=function(le,we,$e,Oe){var Ge;if((Ge=Oe!=null||E.is(le,"object")?le:B.doc.getElementById(le))!=null)return Ge.tagName?we==null?{container:Ge,width:Ge.style.pixelWidth||Ge.offsetWidth,height:Ge.style.pixelHeight||Ge.offsetHeight}:{container:Ge,width:we,height:$e}:{container:1,x:le,y:we,width:$e,height:Oe}},E.pathToRelative=ut,E._engine={},E.path2curve=Xt,E.matrix=function(le,we,$e,Oe,Ge,st){return new qe(le,we,$e,Oe,Ge,st)},function(le){function we(Oe){return Oe[0]*Oe[0]+Oe[1]*Oe[1]}function $e(Oe){var Ge=d.sqrt(we(Oe));Oe[0]&&(Oe[0]/=Ge),Oe[1]&&(Oe[1]/=Ge)}le.add=function(Oe,Ge,st,xe,Ee,Ie){var Xe,xt,Lt,Ft,jt=[[],[],[]],si=[[this.a,this.c,this.e],[this.b,this.d,this.f],[0,0,1]],yi=[[Oe,st,Ee],[Ge,xe,Ie],[0,0,1]];for(Oe&&Oe instanceof qe&&(yi=[[Oe.a,Oe.c,Oe.e],[Oe.b,Oe.d,Oe.f],[0,0,1]]),Xe=0;Xe<3;Xe++)for(xt=0;xt<3;xt++){for(Ft=0,Lt=0;Lt<3;Lt++)Ft+=si[Xe][Lt]*yi[Lt][xt];jt[Xe][xt]=Ft}this.a=jt[0][0],this.b=jt[1][0],this.c=jt[0][1],this.d=jt[1][1],this.e=jt[0][2],this.f=jt[1][2]},le.invert=function(){var Oe=this,Ge=Oe.a*Oe.d-Oe.b*Oe.c;return new qe(Oe.d/Ge,-Oe.b/Ge,-Oe.c/Ge,Oe.a/Ge,(Oe.c*Oe.f-Oe.d*Oe.e)/Ge,(Oe.b*Oe.e-Oe.a*Oe.f)/Ge)},le.clone=function(){return new qe(this.a,this.b,this.c,this.d,this.e,this.f)},le.translate=function(Oe,Ge){this.add(1,0,0,1,Oe,Ge)},le.scale=function(Oe,Ge,st,xe){Ge==null&&(Ge=Oe),(st||xe)&&this.add(1,0,0,1,st,xe),this.add(Oe,0,0,Ge,0,0),(st||xe)&&this.add(1,0,0,1,-st,-xe)},le.rotate=function(Oe,Ge,st){Oe=E.rad(Oe),Ge=Ge||0,st=st||0;var xe=+d.cos(Oe).toFixed(9),Ee=+d.sin(Oe).toFixed(9);this.add(xe,Ee,-Ee,xe,Ge,st),this.add(1,0,0,1,-Ge,-st)},le.x=function(Oe,Ge){return Oe*this.a+Ge*this.c+this.e},le.y=function(Oe,Ge){return Oe*this.b+Ge*this.d+this.f},le.get=function(Oe){return+this[Q.fromCharCode(97+Oe)].toFixed(4)},le.toString=function(){return E.svg?"matrix("+[this.get(0),this.get(1),this.get(2),this.get(3),this.get(4),this.get(5)].join()+")":[this.get(0),this.get(2),this.get(1),this.get(3),0,0].join()},le.toFilter=function(){return"progid:DXImageTransform.Microsoft.Matrix(M11="+this.get(0)+", M12="+this.get(2)+", M21="+this.get(1)+", M22="+this.get(3)+", Dx="+this.get(4)+", Dy="+this.get(5)+", sizingmethod='auto expand')"},le.offset=function(){return[this.e.toFixed(4),this.f.toFixed(4)]},le.split=function(){var Oe={};Oe.dx=this.e,Oe.dy=this.f;var Ge=[[this.a,this.c],[this.b,this.d]];Oe.scalex=d.sqrt(we(Ge[0])),$e(Ge[0]),Oe.shear=Ge[0][0]*Ge[1][0]+Ge[0][1]*Ge[1][1],Ge[1]=[Ge[1][0]-Ge[0][0]*Oe.shear,Ge[1][1]-Ge[0][1]*Oe.shear],Oe.scaley=d.sqrt(we(Ge[1])),$e(Ge[1]),Oe.shear/=Oe.scaley;var st=-Ge[0][1],xe=Ge[1][1];return xe<0?(Oe.rotate=E.deg(d.acos(xe)),st<0&&(Oe.rotate=360-Oe.rotate)):Oe.rotate=E.deg(d.asin(st)),Oe.isSimple=!(+Oe.shear.toFixed(9)||Oe.scalex.toFixed(9)!=Oe.scaley.toFixed(9)&&Oe.rotate),Oe.isSuperSimple=!+Oe.shear.toFixed(9)&&Oe.scalex.toFixed(9)==Oe.scaley.toFixed(9)&&!Oe.rotate,Oe.noRotation=!+Oe.shear.toFixed(9)&&!Oe.rotate,Oe},le.toTransformString=function(Oe){var Ge=Oe||this[ce]();return Ge.isSimple?(Ge.scalex=+Ge.scalex.toFixed(4),Ge.scaley=+Ge.scaley.toFixed(4),Ge.rotate=+Ge.rotate.toFixed(4),(Ge.dx||Ge.dy?"t"+[Ge.dx,Ge.dy]:ie)+(Ge.scalex!=1||Ge.scaley!=1?"s"+[Ge.scalex,Ge.scaley,0,0]:ie)+(Ge.rotate?"r"+[Ge.rotate,0,0]:ie)):"m"+[this.get(0),this.get(1),this.get(2),this.get(3),this.get(4),this.get(5)]}}(qe.prototype);for(var bt=function(){this.returnValue=!1},at=function(){return this.originalEvent.preventDefault()},gt=function(){this.cancelBubble=!0},ei=function(){return this.originalEvent.stopPropagation()},ii=function(le){var we=B.doc.documentElement.scrollTop||B.doc.body.scrollTop,$e=B.doc.documentElement.scrollLeft||B.doc.body.scrollLeft;return{x:le.clientX+$e,y:le.clientY+we}},Bi=B.doc.addEventListener?function(le,we,$e,Oe){var Ge=function(xe){var Ee=ii(xe);return $e.call(Oe,xe,Ee.x,Ee.y)};if(le.addEventListener(we,Ge,!1),J&&ke[we]){var st=function(xe){for(var Ee=ii(xe),Ie=xe,Xe=0,xt=xe.targetTouches&&xe.targetTouches.length;Xe<xt;Xe++)if(xe.targetTouches[Xe].target==le){(xe=xe.targetTouches[Xe]).originalEvent=Ie,xe.preventDefault=at,xe.stopPropagation=ei;break}return $e.call(Oe,xe,Ee.x,Ee.y)};le.addEventListener(ke[we],st,!1)}return function(){return le.removeEventListener(we,Ge,!1),J&&ke[we]&&le.removeEventListener(ke[we],st,!1),!0}}:B.doc.attachEvent?function(le,we,$e,Oe){var Ge=function(st){st=st||B.win.event;var xe=B.doc.documentElement.scrollTop||B.doc.body.scrollTop,Ee=B.doc.documentElement.scrollLeft||B.doc.body.scrollLeft,Ie=st.clientX+Ee,Xe=st.clientY+xe;return st.preventDefault=st.preventDefault||bt,st.stopPropagation=st.stopPropagation||gt,$e.call(Oe,st,Ie,Xe)};return le.attachEvent("on"+we,Ge),function(){return le.detachEvent("on"+we,Ge),!0}}:void 0,hi=[],Di=function(le){for(var we,$e=le.clientX,Oe=le.clientY,Ge=B.doc.documentElement.scrollTop||B.doc.body.scrollTop,st=B.doc.documentElement.scrollLeft||B.doc.body.scrollLeft,xe=hi.length;xe--;){if(we=hi[xe],J&&le.touches){for(var Ee,Ie=le.touches.length;Ie--;)if((Ee=le.touches[Ie]).identifier==we.el._drag.id){$e=Ee.clientX,Oe=Ee.clientY,(le.originalEvent?le.originalEvent:le).preventDefault();break}}else le.preventDefault();var Xe,xt=we.el.node,Lt=xt.nextSibling,Ft=xt.parentNode,jt=xt.style.display;B.win.opera&&Ft.removeChild(xt),xt.style.display="none",Xe=we.el.paper.getElementByPoint($e,Oe),xt.style.display=jt,B.win.opera&&(Lt?Ft.insertBefore(xt,Lt):Ft.appendChild(xt)),Xe&&y("raphael.drag.over."+we.el.id,we.el,Xe),$e+=st,Oe+=Ge,y("raphael.drag.move."+we.el.id,we.move_scope||we.el,$e-we.el._drag.x,Oe-we.el._drag.y,$e,Oe,le)}},ni=function(le){E.unmousemove(Di).unmouseup(ni);for(var we,$e=hi.length;$e--;)(we=hi[$e]).el._drag={},y("raphael.drag.end."+we.el.id,we.end_scope||we.start_scope||we.move_scope||we.el,le);hi=[]},pi=E.el={},Ii=he.length;Ii--;)(function(le){E[le]=pi[le]=function(we,$e){return E.is(we,"function")&&(this.events=this.events||[],this.events.push({name:le,f:we,unbind:Bi(this.shape||this.node||B.doc,le,we,$e||this)})),this},E["un"+le]=pi["un"+le]=function(we){for(var $e=this.events||[],Oe=$e.length;Oe--;)$e[Oe].name!=le||!E.is(we,"undefined")&&$e[Oe].f!=we||($e[Oe].unbind(),$e.splice(Oe,1),!$e.length&&delete this.events);return this}})(he[Ii]);pi.data=function(le,we){var $e=ot[this.id]=ot[this.id]||{};if(arguments.length==0)return $e;if(arguments.length==1){if(E.is(le,"object")){for(var Oe in le)le[R](Oe)&&this.data(Oe,le[Oe]);return this}return y("raphael.data.get."+this.id,this,$e[le],le),$e[le]}return $e[le]=we,y("raphael.data.set."+this.id,this,we,le),this},pi.removeData=function(le){return le==null?delete ot[this.id]:ot[this.id]&&delete ot[this.id][le],this},pi.getData=function(){return We(ot[this.id]||{})},pi.hover=function(le,we,$e,Oe){return this.mouseover(le,$e).mouseout(we,Oe||$e)},pi.unhover=function(le,we){return this.unmouseover(le).unmouseout(we)};var Ci=[];pi.drag=function(le,we,$e,Oe,Ge,st){function xe(Ee){(Ee.originalEvent||Ee).preventDefault();var Ie=Ee.clientX,Xe=Ee.clientY,xt=B.doc.documentElement.scrollTop||B.doc.body.scrollTop,Lt=B.doc.documentElement.scrollLeft||B.doc.body.scrollLeft;if(this._drag.id=Ee.identifier,J&&Ee.touches){for(var Ft,jt=Ee.touches.length;jt--;)if(Ft=Ee.touches[jt],this._drag.id=Ft.identifier,Ft.identifier==this._drag.id){Ie=Ft.clientX,Xe=Ft.clientY;break}}this._drag.x=Ie+Lt,this._drag.y=Xe+xt,!hi.length&&E.mousemove(Di).mouseup(ni),hi.push({el:this,move_scope:Oe,start_scope:Ge,end_scope:st}),we&&y.on("raphael.drag.start."+this.id,we),le&&y.on("raphael.drag.move."+this.id,le),$e&&y.on("raphael.drag.end."+this.id,$e),y("raphael.drag.start."+this.id,Ge||Oe||this,this._drag.x,this._drag.y,Ee)}return this._drag={},Ci.push({el:this,start:xe}),this.mousedown(xe),this},pi.onDragOver=function(le){le?y.on("raphael.drag.over."+this.id,le):y.unbind("raphael.drag.over."+this.id)},pi.undrag=function(){for(var le=Ci.length;le--;)Ci[le].el==this&&(this.unmousedown(Ci[le].start),Ci.splice(le,1),y.unbind("raphael.drag.*."+this.id));!Ci.length&&E.unmousemove(Di).unmouseup(ni),hi=[]},k.circle=function(le,we,$e){var Oe=E._engine.circle(this,le||0,we||0,$e||0);return this.__set__&&this.__set__.push(Oe),Oe},k.rect=function(le,we,$e,Oe,Ge){var st=E._engine.rect(this,le||0,we||0,$e||0,Oe||0,Ge||0);return this.__set__&&this.__set__.push(st),st},k.ellipse=function(le,we,$e,Oe){var Ge=E._engine.ellipse(this,le||0,we||0,$e||0,Oe||0);return this.__set__&&this.__set__.push(Ge),Ge},k.path=function(le){le&&!E.is(le,"string")&&!E.is(le[0],b)&&(le+=ie);var we=E._engine.path(E.format[N](E,arguments),this);return this.__set__&&this.__set__.push(we),we},k.image=function(le,we,$e,Oe,Ge){var st=E._engine.image(this,le||"about:blank",we||0,$e||0,Oe||0,Ge||0);return this.__set__&&this.__set__.push(st),st},k.text=function(le,we,$e){var Oe=E._engine.text(this,le||0,we||0,Q($e));return this.__set__&&this.__set__.push(Oe),Oe},k.set=function(le){!E.is(le,"array")&&(le=Array.prototype.splice.call(arguments,0,arguments.length));var we=new er(le);return this.__set__&&this.__set__.push(we),we.paper=this,we.type="set",we},k.setStart=function(le){this.__set__=le||this.set()},k.setFinish=function(le){var we=this.__set__;return delete this.__set__,we},k.getSize=function(){var le=this.canvas.parentNode;return{width:le.offsetWidth,height:le.offsetHeight}},k.setSize=function(le,we){return E._engine.setSize.call(this,le,we)},k.setViewBox=function(le,we,$e,Oe,Ge){return E._engine.setViewBox.call(this,le,we,$e,Oe,Ge)},k.top=k.bottom=null,k.raphael=E;function zi(){return this.x+ue+this.y+ue+this.width+" × "+this.height}k.getElementByPoint=function(le,we){var $e,Oe,Ge,st,xe,Ee,Ie,Xe=this.canvas,xt=B.doc.elementFromPoint(le,we);if(B.win.opera&&xt.tagName=="svg"){var Lt=(Oe=($e=Xe).getBoundingClientRect(),Ge=$e.ownerDocument,st=Ge.body,xe=Ge.documentElement,Ee=xe.clientTop||st.clientTop||0,Ie=xe.clientLeft||st.clientLeft||0,{y:Oe.top+(B.win.pageYOffset||xe.scrollTop||st.scrollTop)-Ee,x:Oe.left+(B.win.pageXOffset||xe.scrollLeft||st.scrollLeft)-Ie}),Ft=Xe.createSVGRect();Ft.x=le-Lt.x,Ft.y=we-Lt.y,Ft.width=Ft.height=1;var jt=Xe.getIntersectionList(Ft,null);jt.length&&(xt=jt[jt.length-1])}if(!xt)return null;for(;xt.parentNode&&xt!=Xe.parentNode&&!xt.raphael;)xt=xt.parentNode;return xt==this.canvas.parentNode&&(xt=Xe),xt=xt&&xt.raphael?this.getById(xt.raphaelid):null},k.getElementsByBBox=function(le){var we=this.set();return this.forEach(function($e){E.isBBoxIntersect($e.getBBox(),le)&&we.push($e)}),we},k.getById=function(le){for(var we=this.bottom;we;){if(we.id==le)return we;we=we.next}return null},k.forEach=function(le,we){for(var $e=this.bottom;$e;){if(le.call(we,$e)===!1)return this;$e=$e.next}return this},k.getElementsByPoint=function(le,we){var $e=this.set();return this.forEach(function(Oe){Oe.isPointInside(le,we)&&$e.push(Oe)}),$e},pi.isPointInside=function(le,we){var $e=this.realPath=rt[this.type](this);return this.attr("transform")&&this.attr("transform").length&&($e=E.transformPath($e,this.attr("transform"))),E.isPointInsidePath($e,le,we)},pi.getBBox=function(le){if(this.removed)return{};var we=this._;return le?(!we.dirty&&we.bboxwt||(this.realPath=rt[this.type](this),we.bboxwt=Ne(this.realPath),we.bboxwt.toString=zi,we.dirty=0),we.bboxwt):((we.dirty||we.dirtyT||!we.bbox)&&(!we.dirty&&this.realPath||(we.bboxwt=0,this.realPath=rt[this.type](this)),we.bbox=Ne(ht(this.realPath,this.matrix)),we.bbox.toString=zi,we.dirty=we.dirtyT=0),we.bbox)},pi.clone=function(){if(this.removed)return null;var le=this.paper[this.type]().attr(this.attr());return this.__set__&&this.__set__.push(le),le},pi.glow=function(le){if(this.type=="text")return null;var we={width:((le=le||{}).width||10)+(+this.attr("stroke-width")||1),fill:le.fill||!1,opacity:le.opacity==null?.5:le.opacity,offsetx:le.offsetx||0,offsety:le.offsety||0,color:le.color||"#000"},$e=we.width/2,Oe=this.paper,Ge=Oe.set(),st=this.realPath||rt[this.type](this);st=this.matrix?ht(st,this.matrix):st;for(var xe=1;xe<$e+1;xe++)Ge.push(Oe.path(st).attr({stroke:we.color,fill:we.fill?we.color:"none","stroke-linejoin":"round","stroke-linecap":"round","stroke-width":+(we.width/$e*xe).toFixed(3),opacity:+(we.opacity/$e).toFixed(3)}));return Ge.insertBefore(this).translate(we.offsetx,we.offsety)};var qi=function(le,we,$e,Oe,Ge,st,xe,Ee,Ie){return Ie==null?At(le,we,$e,Oe,Ge,st,xe,Ee):E.findDotsAtSegment(le,we,$e,Oe,Ge,st,xe,Ee,function(Xe,xt,Lt,Ft,jt,si,yi,vi,li){if(!(li<0||At(Xe,xt,Lt,Ft,jt,si,yi,vi)<li)){var Vi,Ei=.5,$i=1-Ei;for(Vi=At(Xe,xt,Lt,Ft,jt,si,yi,vi,$i);c(Vi-li)>.01;)Vi=At(Xe,xt,Lt,Ft,jt,si,yi,vi,$i+=(Vi<li?1:-1)*(Ei/=2));return $i}}(le,we,$e,Oe,Ge,st,xe,Ee,Ie))},Ai=function(le,we){return function($e,Oe,Ge){for(var st,xe,Ee,Ie,Xe,xt="",Lt={},Ft=0,jt=0,si=($e=Xt($e)).length;jt<si;jt++){if((Ee=$e[jt])[0]=="M")st=+Ee[1],xe=+Ee[2];else{if(Ft+(Ie=qi(st,xe,Ee[1],Ee[2],Ee[3],Ee[4],Ee[5],Ee[6]))>Oe){if(we&&!Lt.start){if(xt+=["C"+(Xe=qi(st,xe,Ee[1],Ee[2],Ee[3],Ee[4],Ee[5],Ee[6],Oe-Ft)).start.x,Xe.start.y,Xe.m.x,Xe.m.y,Xe.x,Xe.y],Ge)return xt;Lt.start=xt,xt=["M"+Xe.x,Xe.y+"C"+Xe.n.x,Xe.n.y,Xe.end.x,Xe.end.y,Ee[5],Ee[6]].join(),Ft+=Ie,st=+Ee[5],xe=+Ee[6];continue}if(!le&&!we)return{x:(Xe=qi(st,xe,Ee[1],Ee[2],Ee[3],Ee[4],Ee[5],Ee[6],Oe-Ft)).x,y:Xe.y,alpha:Xe.alpha}}Ft+=Ie,st=+Ee[5],xe=+Ee[6]}xt+=Ee.shift()+Ee}return Lt.end=xt,(Xe=le?Ft:we?Lt:E.findDotsAtSegment(st,xe,Ee[0],Ee[1],Ee[2],Ee[3],Ee[4],Ee[5],1)).alpha&&(Xe={x:Xe.x,y:Xe.y,alpha:Xe.alpha}),Xe}},Oi=Ai(1),ki=Ai(),Ti=Ai(0,1);E.getTotalLength=Oi,E.getPointAtLength=ki,E.getSubpath=function(le,we,$e){if(this.getTotalLength(le)-$e<1e-6)return Ti(le,we).end;var Oe=Ti(le,$e,1);return we?Ti(Oe,we).end:Oe},pi.getTotalLength=function(){var le=this.getPath();if(le)return this.node.getTotalLength?this.node.getTotalLength():Oi(le)},pi.getPointAtLength=function(le){var we=this.getPath();if(we)return ki(we,le)},pi.getPath=function(){var le,we=E._getPath[this.type];if(this.type!="text"&&this.type!="set")return we&&(le=we(this)),le},pi.getSubpath=function(le,we){var $e=this.getPath();if($e)return E.getSubpath($e,le,we)};var wi=E.easing_formulas={linear:function(le){return le},"<":function(le){return p(le,1.7)},">":function(le){return p(le,.48)},"<>":function(le){var we=.48-le/1.04,$e=d.sqrt(.1734+we*we),Oe=$e-we,Ge=-$e-we,st=p(c(Oe),1/3)*(Oe<0?-1:1)+p(c(Ge),1/3)*(Ge<0?-1:1)+.5;return 3*(1-st)*st*st+st*st*st},backIn:function(le){var we=1.70158;return le*le*((we+1)*le-we)},backOut:function(le){var we=1.70158;return(le-=1)*le*((we+1)*le+we)+1},elastic:function(le){return le==!!le?le:p(2,-10*le)*d.sin(2*x*(le-.075)/.3)+1},bounce:function(le){var we=7.5625,$e=2.75;return le<1/$e?we*le*le:le<2/$e?we*(le-=1.5/$e)*le+.75:le<2.5/$e?we*(le-=2.25/$e)*le+.9375:we*(le-=2.625/$e)*le+.984375}};wi.easeIn=wi["ease-in"]=wi["<"],wi.easeOut=wi["ease-out"]=wi[">"],wi.easeInOut=wi["ease-in-out"]=wi["<>"],wi["back-in"]=wi.backIn,wi["back-out"]=wi.backOut;var oi=[],zt=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(le){setTimeout(le,16)},Qt=function(){for(var le=+new Date,we=0;we<oi.length;we++){var $e=oi[we];if(!$e.el.removed&&!$e.paused){var Oe,Ge,st=le-$e.start,xe=$e.ms,Ee=$e.easing,Ie=$e.from,Xe=$e.diff,xt=$e.to,Lt=($e.t,$e.el),Ft={},jt={};if($e.initstatus?(st=($e.initstatus*$e.anim.top-$e.prev)/($e.percent-$e.prev)*xe,$e.status=$e.initstatus,delete $e.initstatus,$e.stop&&oi.splice(we--,1)):$e.status=($e.prev+($e.percent-$e.prev)*(st/xe))/$e.anim.top,!(st<0))if(st<xe){var si=Ee(st/xe);for(var yi in Ie)if(Ie[R](yi)){switch(ne[yi]){case S:Oe=+Ie[yi]+si*xe*Xe[yi];break;case"colour":Oe="rgb("+[Si(V(Ie[yi].r+si*xe*Xe[yi].r)),Si(V(Ie[yi].g+si*xe*Xe[yi].g)),Si(V(Ie[yi].b+si*xe*Xe[yi].b))].join(",")+")";break;case"path":Oe=[];for(var vi=0,li=Ie[yi].length;vi<li;vi++){Oe[vi]=[Ie[yi][vi][0]];for(var Vi=1,Ei=Ie[yi][vi].length;Vi<Ei;Vi++)Oe[vi][Vi]=+Ie[yi][vi][Vi]+si*xe*Xe[yi][vi][Vi];Oe[vi]=Oe[vi].join(ue)}Oe=Oe.join(ue);break;case"transform":if(Xe[yi].real)for(Oe=[],vi=0,li=Ie[yi].length;vi<li;vi++)for(Oe[vi]=[Ie[yi][vi][0]],Vi=1,Ei=Ie[yi][vi].length;Vi<Ei;Vi++)Oe[vi][Vi]=Ie[yi][vi][Vi]+si*xe*Xe[yi][vi][Vi];else{var $i=function(ir){return+Ie[yi][ir]+si*xe*Xe[yi][ir]};Oe=[["m",$i(0),$i(1),$i(2),$i(3),$i(4),$i(5)]]}break;case"csv":if(yi=="clip-rect")for(Oe=[],vi=4;vi--;)Oe[vi]=+Ie[yi][vi]+si*xe*Xe[yi][vi];break;default:var xi=[][Y](Ie[yi]);for(Oe=[],vi=Lt.paper.customAttributes[yi].length;vi--;)Oe[vi]=+xi[vi]+si*xe*Xe[yi][vi]}Ft[yi]=Oe}Lt.attr(Ft),function(ir,Ji,ur){setTimeout(function(){y("raphael.anim.frame."+ir,Ji,ur)})}(Lt.id,Lt,$e.anim)}else{if(function(ir,Ji,ur){setTimeout(function(){y("raphael.anim.frame."+Ji.id,Ji,ur),y("raphael.anim.finish."+Ji.id,Ji,ur),E.is(ir,"function")&&ir.call(Ji)})}($e.callback,Lt,$e.anim),Lt.attr(xt),oi.splice(we--,1),$e.repeat>1&&!$e.next){for(Ge in xt)xt[R](Ge)&&(jt[Ge]=$e.totalOrigin[Ge]);$e.el.attr(jt),gi($e.anim,$e.el,$e.anim.percents[0],null,$e.totalOrigin,$e.repeat-1)}$e.next&&!$e.stop&&gi($e.anim,$e.el,$e.next,null,$e.totalOrigin,$e.repeat)}}}oi.length&&zt(Qt)},Si=function(le){return le>255?255:le<0?0:le};function mi(le,we,$e,Oe,Ge,st){var xe=3*we,Ee=3*(Oe-we)-xe,Ie=1-xe-Ee,Xe=3*$e,xt=3*(Ge-$e)-Xe,Lt=1-Xe-xt;function Ft(jt){return((Ie*jt+Ee)*jt+xe)*jt}return function(jt,si){var yi=function(vi,li){var Vi,Ei,$i,xi,ir,Ji;for($i=vi,Ji=0;Ji<8;Ji++){if(xi=Ft($i)-vi,c(xi)<li)return $i;if(c(ir=(3*Ie*$i+2*Ee)*$i+xe)<1e-6)break;$i-=xi/ir}if(Ei=1,($i=vi)<(Vi=0))return Vi;if($i>Ei)return Ei;for(;Vi<Ei;){if(xi=Ft($i),c(xi-vi)<li)return $i;vi>xi?Vi=$i:Ei=$i,$i=(Ei-Vi)/2+Vi}return $i}(jt,si);return((Lt*yi+xt)*yi+Xe)*yi}(le,1/(200*st))}function ai(le,we){var $e=[],Oe={};if(this.ms=we,this.times=1,le){for(var Ge in le)le[R](Ge)&&(Oe[ee(Ge)]=le[Ge],$e.push(ee(Ge)));$e.sort(Ct)}this.anim=Oe,this.top=$e[$e.length-1],this.percents=$e}function gi(le,we,$e,Oe,Ge,st){$e=ee($e);var xe,Ee,Ie,Xe,xt,Lt,Ft=le.ms,jt={},si={},yi={};if(Oe)for(li=0,Vi=oi.length;li<Vi;li++){var vi=oi[li];if(vi.el.id==we.id&&vi.anim==le){vi.percent!=$e?(oi.splice(li,1),Ie=1):Ee=vi,we.attr(vi.totalOrigin);break}}else Oe=+si;for(var li=0,Vi=le.percents.length;li<Vi;li++){if(le.percents[li]==$e||le.percents[li]>Oe*le.top){$e=le.percents[li],xt=le.percents[li-1]||0,Ft=Ft/le.top*($e-xt),Xe=le.percents[li+1],xe=le.anim[$e];break}Oe&&we.attr(le.anim[le.percents[li]])}if(xe){if(Ee)Ee.initstatus=Oe,Ee.start=new Date-Ee.ms*Oe;else{for(var Ei in xe)if(xe[R](Ei)&&(ne[R](Ei)||we.paper.customAttributes[R](Ei)))switch(jt[Ei]=we.attr(Ei),jt[Ei]==null&&(jt[Ei]=z[Ei]),si[Ei]=xe[Ei],ne[Ei]){case S:yi[Ei]=(si[Ei]-jt[Ei])/Ft;break;case"colour":jt[Ei]=E.getRGB(jt[Ei]);var $i=E.getRGB(si[Ei]);yi[Ei]={r:($i.r-jt[Ei].r)/Ft,g:($i.g-jt[Ei].g)/Ft,b:($i.b-jt[Ei].b)/Ft};break;case"path":var xi=Xt(jt[Ei],si[Ei]),ir=xi[1];for(jt[Ei]=xi[0],yi[Ei]=[],li=0,Vi=jt[Ei].length;li<Vi;li++){yi[Ei][li]=[0];for(var Ji=1,ur=jt[Ei][li].length;Ji<ur;Ji++)yi[Ei][li][Ji]=(ir[li][Ji]-jt[Ei][li][Ji])/Ft}break;case"transform":var zn=we._,Un=Ae(zn[Ei],si[Ei]);if(Un)for(jt[Ei]=Un.from,si[Ei]=Un.to,yi[Ei]=[],yi[Ei].real=!0,li=0,Vi=jt[Ei].length;li<Vi;li++)for(yi[Ei][li]=[jt[Ei][li][0]],Ji=1,ur=jt[Ei][li].length;Ji<ur;Ji++)yi[Ei][li][Ji]=(si[Ei][li][Ji]-jt[Ei][li][Ji])/Ft;else{var _r=we.matrix||new qe,xr={_:{transform:zn.transform},getBBox:function(){return we.getBBox(1)}};jt[Ei]=[_r.a,_r.b,_r.c,_r.d,_r.e,_r.f],ge(xr,si[Ei]),si[Ei]=xr._.transform,yi[Ei]=[(xr.matrix.a-_r.a)/Ft,(xr.matrix.b-_r.b)/Ft,(xr.matrix.c-_r.c)/Ft,(xr.matrix.d-_r.d)/Ft,(xr.matrix.e-_r.e)/Ft,(xr.matrix.f-_r.f)/Ft]}break;case"csv":var En=Q(xe[Ei])[ce](A),kn=Q(jt[Ei])[ce](A);if(Ei=="clip-rect")for(jt[Ei]=kn,yi[Ei]=[],li=kn.length;li--;)yi[Ei][li]=(En[li]-jt[Ei][li])/Ft;si[Ei]=En;break;default:for(En=[][Y](xe[Ei]),kn=[][Y](jt[Ei]),yi[Ei]=[],li=we.paper.customAttributes[Ei].length;li--;)yi[Ei][li]=((En[li]||0)-(kn[li]||0))/Ft}var ia=xe.easing,pn=E.easing_formulas[ia];if(!pn)if((pn=Q(ia).match(O))&&pn.length==5){var yn=pn;pn=function(ca){return mi(ca,+yn[1],+yn[2],+yn[3],+yn[4],Ft)}}else pn=nt;if(vi={anim:le,percent:$e,timestamp:Lt=xe.start||le.start||+new Date,start:Lt+(le.del||0),status:0,initstatus:Oe||0,stop:!1,ms:Ft,easing:pn,from:jt,diff:yi,to:si,el:we,callback:xe.callback,prev:xt,next:Xe,repeat:st||le.times,origin:we.attr(),totalOrigin:Ge},oi.push(vi),Oe&&!Ee&&!Ie&&(vi.stop=!0,vi.start=new Date-Ft*Oe,oi.length==1))return Qt();Ie&&(vi.start=new Date-vi.ms*Oe),oi.length==1&&zt(Qt)}y("raphael.anim.start."+we.id,we,le)}}function Hi(le){for(var we=0;we<oi.length;we++)oi[we].el.paper==le&&oi.splice(we--,1)}pi.animateWith=function(le,we,$e,Oe,Ge,st){if(this.removed)return st&&st.call(this),this;var xe=$e instanceof ai?$e:E.animation($e,Oe,Ge,st);gi(xe,this,xe.percents[0],null,this.attr());for(var Ee=0,Ie=oi.length;Ee<Ie;Ee++)if(oi[Ee].anim==we&&oi[Ee].el==le){oi[Ie-1].start=oi[Ee].start;break}return this},pi.onAnimation=function(le){return le?y.on("raphael.anim.frame."+this.id,le):y.unbind("raphael.anim.frame."+this.id),this},ai.prototype.delay=function(le){var we=new ai(this.anim,this.ms);return we.times=this.times,we.del=+le||0,we},ai.prototype.repeat=function(le){var we=new ai(this.anim,this.ms);return we.del=this.del,we.times=d.floor(v(le,0))||1,we},E.animation=function(le,we,$e,Oe){if(le instanceof ai)return le;!E.is($e,"function")&&$e||(Oe=Oe||$e||null,$e=null),le=Object(le),we=+we||0;var Ge,st,xe={};for(st in le)le[R](st)&&ee(st)!=st&&ee(st)+"%"!=st&&(Ge=!0,xe[st]=le[st]);if(Ge)return $e&&(xe.easing=$e),Oe&&(xe.callback=Oe),new ai({100:xe},we);if(Oe){var Ee=0;for(var Ie in le){var Xe=Z(Ie);le[R](Ie)&&Xe>Ee&&(Ee=Xe)}!le[Ee+="%"].callback&&(le[Ee].callback=Oe)}return new ai(le,we)},pi.animate=function(le,we,$e,Oe){if(this.removed)return Oe&&Oe.call(this),this;var Ge=le instanceof ai?le:E.animation(le,we,$e,Oe);return gi(Ge,this,Ge.percents[0],null,this.attr()),this},pi.setTime=function(le,we){return le&&we!=null&&this.status(le,w(we,le.ms)/le.ms),this},pi.status=function(le,we){var $e,Oe,Ge=[],st=0;if(we!=null)return gi(le,this,-1,w(we,1)),this;for($e=oi.length;st<$e;st++)if((Oe=oi[st]).el.id==this.id&&(!le||Oe.anim==le)){if(le)return Oe.status;Ge.push({anim:Oe.anim,status:Oe.status})}return le?0:Ge},pi.pause=function(le){for(var we=0;we<oi.length;we++)oi[we].el.id!=this.id||le&&oi[we].anim!=le||y("raphael.anim.pause."+this.id,this,oi[we].anim)!==!1&&(oi[we].paused=!0);return this},pi.resume=function(le){for(var we=0;we<oi.length;we++)if(oi[we].el.id==this.id&&(!le||oi[we].anim==le)){var $e=oi[we];y("raphael.anim.resume."+this.id,this,$e.anim)!==!1&&(delete $e.paused,this.status($e.anim,$e.status))}return this},pi.stop=function(le){for(var we=0;we<oi.length;we++)oi[we].el.id!=this.id||le&&oi[we].anim!=le||y("raphael.anim.stop."+this.id,this,oi[we].anim)!==!1&&oi.splice(we--,1);return this},y.on("raphael.remove",Hi),y.on("raphael.clear",Hi),pi.toString=function(){return"Raphaël’s object"};var or,nr,Gi,Mt,er=function(le){if(this.items=[],this.length=0,this.type="set",le)for(var we=0,$e=le.length;we<$e;we++)!le[we]||le[we].constructor!=pi.constructor&&le[we].constructor!=er||(this[this.items.length]=this.items[this.items.length]=le[we],this.length++)},tr=er.prototype;for(var br in tr.push=function(){for(var le,we,$e=0,Oe=arguments.length;$e<Oe;$e++)!(le=arguments[$e])||le.constructor!=pi.constructor&&le.constructor!=er||(this[we=this.items.length]=this.items[we]=le,this.length++);return this},tr.pop=function(){return this.length&&delete this[this.length--],this.items.pop()},tr.forEach=function(le,we){for(var $e=0,Oe=this.items.length;$e<Oe;$e++)if(le.call(we,this.items[$e],$e)===!1)return this;return this},pi)pi[R](br)&&(tr[br]=function(le){return function(){var we=arguments;return this.forEach(function($e){$e[le][N]($e,we)})}}(br));return tr.attr=function(le,we){if(le&&E.is(le,b)&&E.is(le[0],"object"))for(var $e=0,Oe=le.length;$e<Oe;$e++)this.items[$e].attr(le[$e]);else for(var Ge=0,st=this.items.length;Ge<st;Ge++)this.items[Ge].attr(le,we);return this},tr.clear=function(){for(;this.length;)this.pop()},tr.splice=function(le,we,$e){le=le<0?v(this.length+le,0):le,we=v(0,w(this.length-le,we));var Oe,Ge=[],st=[],xe=[];for(Oe=2;Oe<arguments.length;Oe++)xe.push(arguments[Oe]);for(Oe=0;Oe<we;Oe++)st.push(this[le+Oe]);for(;Oe<this.length-le;Oe++)Ge.push(this[le+Oe]);var Ee=xe.length;for(Oe=0;Oe<Ee+Ge.length;Oe++)this.items[le+Oe]=this[le+Oe]=Oe<Ee?xe[Oe]:Ge[Oe-Ee];for(Oe=this.items.length=this.length-=we-Ee;this[Oe];)delete this[Oe++];return new er(st)},tr.exclude=function(le){for(var we=0,$e=this.length;we<$e;we++)if(this[we]==le)return this.splice(we,1),!0},tr.animate=function(le,we,$e,Oe){(E.is($e,"function")||!$e)&&(Oe=$e||null);var Ge,st,xe=this.items.length,Ee=xe,Ie=this;if(!xe)return this;Oe&&(st=function(){!--xe&&Oe.call(Ie)}),$e=E.is($e,"string")?$e:st;var Xe=E.animation(le,we,$e,st);for(Ge=this.items[--Ee].animate(Xe);Ee--;)this.items[Ee]&&!this.items[Ee].removed&&this.items[Ee].animateWith(Ge,Xe,Xe),this.items[Ee]&&!this.items[Ee].removed||xe--;return this},tr.insertAfter=function(le){for(var we=this.items.length;we--;)this.items[we].insertAfter(le);return this},tr.getBBox=function(){for(var le=[],we=[],$e=[],Oe=[],Ge=this.items.length;Ge--;)if(!this.items[Ge].removed){var st=this.items[Ge].getBBox();le.push(st.x),we.push(st.y),$e.push(st.x+st.width),Oe.push(st.y+st.height)}return{x:le=w[N](0,le),y:we=w[N](0,we),x2:$e=v[N](0,$e),y2:Oe=v[N](0,Oe),width:$e-le,height:Oe-we}},tr.clone=function(le){le=this.paper.set();for(var we=0,$e=this.items.length;we<$e;we++)le.push(this.items[we].clone());return le},tr.toString=function(){return"Raphaël‘s set"},tr.glow=function(le){var we=this.paper.set();return this.forEach(function($e,Oe){var Ge=$e.glow(le);Ge!=null&&Ge.forEach(function(st,xe){we.push(st)})}),we},tr.isPointInside=function(le,we){var $e=!1;return this.forEach(function(Oe){if(Oe.isPointInside(le,we))return $e=!0,!1}),$e},E.registerFont=function(le){if(!le.face)return le;this.fonts=this.fonts||{};var we={w:le.w,face:{},glyphs:{}},$e=le.face["font-family"];for(var Oe in le.face)le.face[R](Oe)&&(we.face[Oe]=le.face[Oe]);if(this.fonts[$e]?this.fonts[$e].push(we):this.fonts[$e]=[we],!le.svg){for(var Ge in we.face["units-per-em"]=Z(le.face["units-per-em"],10),le.glyphs)if(le.glyphs[R](Ge)){var st=le.glyphs[Ge];if(we.glyphs[Ge]={w:st.w,k:{},d:st.d&&"M"+st.d.replace(/[mlcxtrv]/g,function(Ee){return{l:"L",c:"C",x:"z",t:"m",r:"l",v:"c"}[Ee]||"M"})+"z"},st.k)for(var xe in st.k)st[R](xe)&&(we.glyphs[Ge].k[xe]=st.k[xe])}}return le},k.getFont=function(le,we,$e,Oe){if(Oe=Oe||"normal",$e=$e||"normal",we=+we||{normal:400,bold:700,lighter:300,bolder:800}[we]||400,E.fonts){var Ge,st=E.fonts[le];if(!st){var xe=new RegExp("(^|\\s)"+le.replace(/[^\w\d\s+!~.:_-]/g,ie)+"(\\s|$)","i");for(var Ee in E.fonts)if(E.fonts[R](Ee)&&xe.test(Ee)){st=E.fonts[Ee];break}}if(st)for(var Ie=0,Xe=st.length;Ie<Xe&&((Ge=st[Ie]).face["font-weight"]!=we||Ge.face["font-style"]!=$e&&Ge.face["font-style"]||Ge.face["font-stretch"]!=Oe);Ie++);return Ge}},k.print=function(le,we,$e,Oe,Ge,st,xe,Ee){st=st||"middle",xe=v(w(xe||0,1),-1),Ee=v(w(Ee||1,3),1);var Ie,Xe=Q($e)[ce](ie),xt=0,Lt=0,Ft=ie;if(E.is(Oe,"string")&&(Oe=this.getFont(Oe)),Oe){Ie=(Ge||16)/Oe.face["units-per-em"];for(var jt=Oe.face.bbox[ce](A),si=+jt[0],yi=jt[3]-jt[1],vi=0,li=+jt[1]+(st=="baseline"?yi+ +Oe.face.descent:yi/2),Vi=0,Ei=Xe.length;Vi<Ei;Vi++){if(Xe[Vi]==`
`)xt=0,xi=0,Lt=0,vi+=yi*Ee;else{var $i=Lt&&Oe.glyphs[Xe[Vi-1]]||{},xi=Oe.glyphs[Xe[Vi]];xt+=Lt?($i.w||Oe.w)+($i.k&&$i.k[Xe[Vi]]||0)+Oe.w*xe:0,Lt=1}xi&&xi.d&&(Ft+=E.transformPath(xi.d,["t",xt*Ie,vi*Ie,"s",Ie,Ie,si,li,"t",(le-si)/Ie,(we-li)/Ie]))}}return this.path(Ft).attr({fill:"#000",stroke:"none"})},k.add=function(le){if(E.is(le,"array"))for(var we,$e=this.set(),Oe=0,Ge=le.length;Oe<Ge;Oe++)we=le[Oe]||{},D[R](we.type)&&$e.push(this[we.type]().attr(we));return $e},E.format=function(le,we){var $e=E.is(we,b)?[0][Y](we):arguments;return le&&E.is(le,"string")&&$e.length-1&&(le=le.replace(P,function(Oe,Ge){return $e[++Ge]==null?ie:$e[Ge]})),le||ie},E.fullfill=(or=/\{([^\}]+)\}/g,nr=/(?:(?:^|\.)(.+?)(?=\[|\.|$|\()|\[('|")(.+?)\2\])(\(\))?/g,function(le,we){return String(le).replace(or,function($e,Oe){return function(Ge,st,xe){var Ee=xe;return st.replace(nr,function(Ie,Xe,xt,Lt,Ft){Xe=Xe||Lt,Ee&&(Xe in Ee&&(Ee=Ee[Xe]),typeof Ee=="function"&&Ft&&(Ee=Ee()))}),Ee=(Ee==null||Ee==xe?Ge:Ee)+""}($e,Oe,we)})}),E.ninja=function(){if(F.was)B.win.Raphael=F.is;else{window.Raphael=void 0;try{delete window.Raphael}catch{}}return E},E.st=tr,y.on("raphael.DOMload",function(){C=!0}),(Gi=document).readyState==null&&Gi.addEventListener&&(Gi.addEventListener("DOMContentLoaded",Mt=function(){Gi.removeEventListener("DOMContentLoaded",Mt,!1),Gi.readyState="complete"},!1),Gi.readyState="loading"),function le(){/in/.test(Gi.readyState)?setTimeout(le,9):E.eve("raphael.DOMload")}(),E}).apply(o,l))===void 0||(n.exports=m)},function(n,o,u){var l,m;l=[u(0),u(3),u(4)],(m=(function(y){return y}).apply(o,l))===void 0||(n.exports=m)},function(n,o,u){var l,m,y,E,C,k,A,D,P,R,B,F,j,N;E="hasOwnProperty",C=/[\.\/]/,k=/\s*,\s*/,A=function(Y,J){return Y-J},D={n:{}},P=function(){for(var Y=0,J=this.length;Y<J;Y++)if(this[Y]!==void 0)return this[Y]},R=function(){for(var Y=this.length;--Y;)if(this[Y]!==void 0)return this[Y]},B=Object.prototype.toString,F=String,j=Array.isArray||function(Y){return Y instanceof Array||B.call(Y)=="[object Array]"},(N=function(Y,J){var ie,ue=y,Q=Array.prototype.slice.call(arguments,2),ce=N.listeners(Y),he=0,ke=[],L={},d=[],v=m;d.firstDefined=P,d.lastDefined=R,m=Y,y=0;for(var w=0,c=ce.length;w<c;w++)"zIndex"in ce[w]&&(ke.push(ce[w].zIndex),ce[w].zIndex<0&&(L[ce[w].zIndex]=ce[w]));for(ke.sort(A);ke[he]<0;)if(ie=L[ke[he++]],d.push(ie.apply(J,Q)),y)return y=ue,d;for(w=0;w<c;w++)if("zIndex"in(ie=ce[w]))if(ie.zIndex==ke[he]){if(d.push(ie.apply(J,Q)),y)break;do if((ie=L[ke[++he]])&&d.push(ie.apply(J,Q)),y)break;while(ie)}else L[ie.zIndex]=ie;else if(d.push(ie.apply(J,Q)),y)break;return y=ue,m=v,d})._events=D,N.listeners=function(Y){var J,ie,ue,Q,ce,he,ke,L,d=j(Y)?Y:Y.split(C),v=D,w=[v],c=[];for(Q=0,ce=d.length;Q<ce;Q++){for(L=[],he=0,ke=w.length;he<ke;he++)for(ie=[(v=w[he].n)[d[Q]],v["*"]],ue=2;ue--;)(J=ie[ue])&&(L.push(J),c=c.concat(J.f||[]));w=L}return c},N.separator=function(Y){Y?(Y="["+(Y=F(Y).replace(/(?=[\.\^\]\[\-])/g,"\\"))+"]",C=new RegExp(Y)):C=/[\.\/]/},N.on=function(Y,J){if(typeof J!="function")return function(){};for(var ie=j(Y)?j(Y[0])?Y:[Y]:F(Y).split(k),ue=0,Q=ie.length;ue<Q;ue++)(function(ce){for(var he,ke=j(ce)?ce:F(ce).split(C),L=D,d=0,v=ke.length;d<v;d++)L=(L=L.n).hasOwnProperty(ke[d])&&L[ke[d]]||(L[ke[d]]={n:{}});for(L.f=L.f||[],d=0,v=L.f.length;d<v;d++)if(L.f[d]==J){he=!0;break}!he&&L.f.push(J)})(ie[ue]);return function(ce){+ce==+ce&&(J.zIndex=+ce)}},N.f=function(Y){var J=[].slice.call(arguments,1);return function(){N.apply(null,[Y,null].concat(J).concat([].slice.call(arguments,0)))}},N.stop=function(){y=1},N.nt=function(Y){var J=j(m)?m.join("."):m;return Y?new RegExp("(?:\\.|\\/|^)"+Y+"(?:\\.|\\/|$)").test(J):J},N.nts=function(){return j(m)?m:m.split(C)},N.off=N.unbind=function(Y,J){if(Y){var ie=j(Y)?j(Y[0])?Y:[Y]:F(Y).split(k);if(ie.length>1)for(var ue=0,Q=ie.length;ue<Q;ue++)N.off(ie[ue],J);else{ie=j(Y)?Y:F(Y).split(C);var ce,he,ke,L,d,v=[D];for(ue=0,Q=ie.length;ue<Q;ue++)for(L=0;L<v.length;L+=ke.length-2){if(ke=[L,1],ce=v[L].n,ie[ue]!="*")ce[ie[ue]]&&ke.push(ce[ie[ue]]);else for(he in ce)ce[E](he)&&ke.push(ce[he]);v.splice.apply(v,ke)}for(ue=0,Q=v.length;ue<Q;ue++)for(ce=v[ue];ce.n;){if(J){if(ce.f){for(L=0,d=ce.f.length;L<d;L++)if(ce.f[L]==J){ce.f.splice(L,1);break}!ce.f.length&&delete ce.f}for(he in ce.n)if(ce.n[E](he)&&ce.n[he].f){var w=ce.n[he].f;for(L=0,d=w.length;L<d;L++)if(w[L]==J){w.splice(L,1);break}!w.length&&delete ce.n[he].f}}else for(he in delete ce.f,ce.n)ce.n[E](he)&&ce.n[he].f&&delete ce.n[he].f;ce=ce.n}}}else N._events=D={n:{}}},N.once=function(Y,J){var ie=function(){return N.off(Y,ie),J.apply(this,arguments)};return N.on(Y,ie)},N.version="0.5.0",N.toString=function(){return"You are running Eve 0.5.0"},n.exports?n.exports=N:(l=(function(){return N}).apply(o,[]))===void 0||(n.exports=l)},function(n,o,u){var l,m;l=[u(0)],(m=(function(y){if(!y||y.svg){var E="hasOwnProperty",C=String,k=parseFloat,A=parseInt,D=Math,P=D.max,R=D.abs,B=D.pow,F=/[, ]+/,j=y.eve,N="",Y=" ",J="http://www.w3.org/1999/xlink",ie={block:"M5,0 0,2.5 5,5z",classic:"M5,0 0,2.5 5,5 3.5,3 3.5,2z",diamond:"M2.5,0 5,2.5 2.5,5 0,2.5z",open:"M6,1 1,3.5 6,6",oval:"M2.5,0A2.5,2.5,0,0,1,2.5,5 2.5,2.5,0,0,1,2.5,0z"},ue={};y.toString=function(){return`Your browser supports SVG.
You are running Raphaël `+this.version};var Q=function(T,M){if(M)for(var O in typeof T=="string"&&(T=Q(T)),M)M[E](O)&&(O.substring(0,6)=="xlink:"?T.setAttributeNS(J,O.substring(6),C(M[O])):T.setAttribute(O,C(M[O])));else(T=y._g.doc.createElementNS("http://www.w3.org/2000/svg",T)).style&&(T.style.webkitTapHighlightColor="rgba(0,0,0,0)");return T},ce=function(T,M){var O="linear",V=T.id+M,ee=.5,Z=.5,U=T.node,z=T.paper,ne=U.style,fe=y._g.doc.getElementById(V);if(!fe){if(M=(M=C(M).replace(y._radial_gradient,function(Ct,nt,Je){if(O="radial",nt&&Je){ee=k(nt);var tt=2*((Z=k(Je))>.5)-1;B(ee-.5,2)+B(Z-.5,2)>.25&&(Z=D.sqrt(.25-B(ee-.5,2))*tt+.5)&&Z!=.5&&(Z=Z.toFixed(5)-1e-5*tt)}return N})).split(/\s*\-\s*/),O=="linear"){var me=M.shift();if(me=-k(me),isNaN(me))return null;var de=[0,0,D.cos(y.rad(me)),D.sin(y.rad(me))],je=1/(P(R(de[2]),R(de[3]))||1);de[2]*=je,de[3]*=je,de[2]<0&&(de[0]=-de[2],de[2]=0),de[3]<0&&(de[1]=-de[3],de[3]=0)}var lt=y._parseDots(M);if(!lt)return null;if(V=V.replace(/[\(\)\s,\xb0#]/g,"_"),T.gradient&&V!=T.gradient.id&&(z.defs.removeChild(T.gradient),delete T.gradient),!T.gradient){fe=Q(O+"Gradient",{id:V}),T.gradient=fe,Q(fe,O=="radial"?{fx:ee,fy:Z}:{x1:de[0],y1:de[1],x2:de[2],y2:de[3],gradientTransform:T.matrix.invert()}),z.defs.appendChild(fe);for(var it=0,ot=lt.length;it<ot;it++)fe.appendChild(Q("stop",{offset:lt[it].offset?lt[it].offset:it?"100%":"0%","stop-color":lt[it].color||"#fff","stop-opacity":isFinite(lt[it].opacity)?lt[it].opacity:1}))}}return Q(U,{fill:he(V),opacity:1,"fill-opacity":1}),ne.fill=N,ne.opacity=1,ne.fillOpacity=1,1},he=function(T){if((M=document.documentMode)&&(M===9||M===10))return"url('#"+T+"')";var M,O=document.location;return"url('"+(O.protocol+"//"+O.host+O.pathname+O.search)+"#"+T+"')"},ke=function(T){var M=T.getBBox(1);Q(T.pattern,{patternTransform:T.matrix.invert()+" translate("+M.x+","+M.y+")"})},L=function(T,M,O){if(T.type=="path"){for(var V,ee,Z,U,z,ne=C(M).toLowerCase().split("-"),fe=T.paper,me=O?"end":"start",de=T.node,je=T.attrs,lt=je["stroke-width"],it=ne.length,ot="classic",Ct=3,nt=3,Je=5;it--;)switch(ne[it]){case"block":case"classic":case"oval":case"diamond":case"open":case"none":ot=ne[it];break;case"wide":nt=5;break;case"narrow":nt=2;break;case"long":Ct=5;break;case"short":Ct=2}if(ot=="open"?(Ct+=2,nt+=2,Je+=2,Z=1,U=O?4:1,z={fill:"none",stroke:je.stroke}):(U=Z=Ct/2,z={fill:je.stroke,stroke:"none"}),T._.arrows?O?(T._.arrows.endPath&&ue[T._.arrows.endPath]--,T._.arrows.endMarker&&ue[T._.arrows.endMarker]--):(T._.arrows.startPath&&ue[T._.arrows.startPath]--,T._.arrows.startMarker&&ue[T._.arrows.startMarker]--):T._.arrows={},ot!="none"){var tt="raphael-marker-"+ot,rt="raphael-marker-"+me+ot+Ct+nt+"-obj"+T.id;y._g.doc.getElementById(tt)?ue[tt]++:(fe.defs.appendChild(Q(Q("path"),{"stroke-linecap":"round",d:ie[ot],id:tt})),ue[tt]=1);var ht,Ot=y._g.doc.getElementById(rt);Ot?(ue[rt]++,ht=Ot.getElementsByTagName("use")[0]):(Ot=Q(Q("marker"),{id:rt,markerHeight:nt,markerWidth:Ct,orient:"auto",refX:U,refY:nt/2}),ht=Q(Q("use"),{"xlink:href":"#"+tt,transform:(O?"rotate(180 "+Ct/2+" "+nt/2+") ":N)+"scale("+Ct/Je+","+nt/Je+")","stroke-width":(1/((Ct/Je+nt/Je)/2)).toFixed(4)}),Ot.appendChild(ht),fe.defs.appendChild(Ot),ue[rt]=1),Q(ht,z);var Ve=Z*(ot!="diamond"&&ot!="oval");O?(V=T._.arrows.startdx*lt||0,ee=y.getTotalLength(je.path)-Ve*lt):(V=Ve*lt,ee=y.getTotalLength(je.path)-(T._.arrows.enddx*lt||0)),(z={})["marker-"+me]="url(#"+rt+")",(ee||V)&&(z.d=y.getSubpath(je.path,V,ee)),Q(de,z),T._.arrows[me+"Path"]=tt,T._.arrows[me+"Marker"]=rt,T._.arrows[me+"dx"]=Ve,T._.arrows[me+"Type"]=ot,T._.arrows[me+"String"]=M}else O?(V=T._.arrows.startdx*lt||0,ee=y.getTotalLength(je.path)-V):(V=0,ee=y.getTotalLength(je.path)-(T._.arrows.enddx*lt||0)),T._.arrows[me+"Path"]&&Q(de,{d:y.getSubpath(je.path,V,ee)}),delete T._.arrows[me+"Path"],delete T._.arrows[me+"Marker"],delete T._.arrows[me+"dx"],delete T._.arrows[me+"Type"],delete T._.arrows[me+"String"];for(z in ue)if(ue[E](z)&&!ue[z]){var We=y._g.doc.getElementById(z);We&&We.parentNode.removeChild(We)}}},d={"-":[3,1],".":[1,1],"-.":[3,1,1,1],"-..":[3,1,1,1,1,1],". ":[1,3],"- ":[4,3],"--":[8,3],"- .":[4,3,1,3],"--.":[8,3,1,3],"--..":[8,3,1,3,1,3]},v=function(T,M,O){if(M=d[C(M).toLowerCase()]){for(var V=T.attrs["stroke-width"]||"1",ee={round:V,square:V,butt:0}[T.attrs["stroke-linecap"]||O["stroke-linecap"]]||0,Z=[],U=M.length;U--;)Z[U]=M[U]*V+(U%2?1:-1)*ee;Q(T.node,{"stroke-dasharray":Z.join(",")})}else Q(T.node,{"stroke-dasharray":"none"})},w=function(T,M){var O=T.node,V=T.attrs,ee=O.style.visibility;for(var Z in O.style.visibility="hidden",M)if(M[E](Z)){if(!y._availableAttrs[E](Z))continue;var U=M[Z];switch(V[Z]=U,Z){case"blur":T.blur(U);break;case"title":var z=O.getElementsByTagName("title");if(z.length&&(z=z[0]))z.firstChild.nodeValue=U;else{z=Q("title");var ne=y._g.doc.createTextNode(U);z.appendChild(ne),O.appendChild(z)}break;case"href":case"target":var fe=O.parentNode;if(fe.tagName.toLowerCase()!="a"){var me=Q("a");fe.insertBefore(me,O),me.appendChild(O),fe=me}Z=="target"?fe.setAttributeNS(J,"show",U=="blank"?"new":U):fe.setAttributeNS(J,Z,U);break;case"cursor":O.style.cursor=U;break;case"transform":T.transform(U);break;case"arrow-start":L(T,U);break;case"arrow-end":L(T,U,1);break;case"clip-rect":var de=C(U).split(F);if(de.length==4){T.clip&&T.clip.parentNode.parentNode.removeChild(T.clip.parentNode);var je=Q("clipPath"),lt=Q("rect");je.id=y.createUUID(),Q(lt,{x:de[0],y:de[1],width:de[2],height:de[3]}),je.appendChild(lt),T.paper.defs.appendChild(je),Q(O,{"clip-path":"url(#"+je.id+")"}),T.clip=lt}if(!U){var it=O.getAttribute("clip-path");if(it){var ot=y._g.doc.getElementById(it.replace(/(^url\(#|\)$)/g,N));ot&&ot.parentNode.removeChild(ot),Q(O,{"clip-path":N}),delete T.clip}}break;case"path":T.type=="path"&&(Q(O,{d:U?V.path=y._pathToAbsolute(U):"M0,0"}),T._.dirty=1,T._.arrows&&("startString"in T._.arrows&&L(T,T._.arrows.startString),"endString"in T._.arrows&&L(T,T._.arrows.endString,1)));break;case"width":if(O.setAttribute(Z,U),T._.dirty=1,!V.fx)break;Z="x",U=V.x;case"x":V.fx&&(U=-V.x-(V.width||0));case"rx":if(Z=="rx"&&T.type=="rect")break;case"cx":O.setAttribute(Z,U),T.pattern&&ke(T),T._.dirty=1;break;case"height":if(O.setAttribute(Z,U),T._.dirty=1,!V.fy)break;Z="y",U=V.y;case"y":V.fy&&(U=-V.y-(V.height||0));case"ry":if(Z=="ry"&&T.type=="rect")break;case"cy":O.setAttribute(Z,U),T.pattern&&ke(T),T._.dirty=1;break;case"r":T.type=="rect"?Q(O,{rx:U,ry:U}):O.setAttribute(Z,U),T._.dirty=1;break;case"src":T.type=="image"&&O.setAttributeNS(J,"href",U);break;case"stroke-width":T._.sx==1&&T._.sy==1||(U/=P(R(T._.sx),R(T._.sy))||1),O.setAttribute(Z,U),V["stroke-dasharray"]&&v(T,V["stroke-dasharray"],M),T._.arrows&&("startString"in T._.arrows&&L(T,T._.arrows.startString),"endString"in T._.arrows&&L(T,T._.arrows.endString,1));break;case"stroke-dasharray":v(T,U,M);break;case"fill":var Ct=C(U).match(y._ISURL);if(Ct){je=Q("pattern");var nt=Q("image");je.id=y.createUUID(),Q(je,{x:0,y:0,patternUnits:"userSpaceOnUse",height:1,width:1}),Q(nt,{x:0,y:0,"xlink:href":Ct[1]}),je.appendChild(nt),function(Ot){y._preload(Ct[1],function(){var Ve=this.offsetWidth,We=this.offsetHeight;Q(Ot,{width:Ve,height:We}),Q(nt,{width:Ve,height:We})})}(je),T.paper.defs.appendChild(je),Q(O,{fill:"url(#"+je.id+")"}),T.pattern=je,T.pattern&&ke(T);break}var Je=y.getRGB(U);if(Je.error){if((T.type=="circle"||T.type=="ellipse"||C(U).charAt()!="r")&&ce(T,U)){if("opacity"in V||"fill-opacity"in V){var tt=y._g.doc.getElementById(O.getAttribute("fill").replace(/^url\(#|\)$/g,N));if(tt){var rt=tt.getElementsByTagName("stop");Q(rt[rt.length-1],{"stop-opacity":("opacity"in V?V.opacity:1)*("fill-opacity"in V?V["fill-opacity"]:1)})}}V.gradient=U,V.fill="none";break}}else delete M.gradient,delete V.gradient,!y.is(V.opacity,"undefined")&&y.is(M.opacity,"undefined")&&Q(O,{opacity:V.opacity}),!y.is(V["fill-opacity"],"undefined")&&y.is(M["fill-opacity"],"undefined")&&Q(O,{"fill-opacity":V["fill-opacity"]});Je[E]("opacity")&&Q(O,{"fill-opacity":Je.opacity>1?Je.opacity/100:Je.opacity});case"stroke":Je=y.getRGB(U),O.setAttribute(Z,Je.hex),Z=="stroke"&&Je[E]("opacity")&&Q(O,{"stroke-opacity":Je.opacity>1?Je.opacity/100:Je.opacity}),Z=="stroke"&&T._.arrows&&("startString"in T._.arrows&&L(T,T._.arrows.startString),"endString"in T._.arrows&&L(T,T._.arrows.endString,1));break;case"gradient":(T.type=="circle"||T.type=="ellipse"||C(U).charAt()!="r")&&ce(T,U);break;case"opacity":V.gradient&&!V[E]("stroke-opacity")&&Q(O,{"stroke-opacity":U>1?U/100:U});case"fill-opacity":if(V.gradient){(tt=y._g.doc.getElementById(O.getAttribute("fill").replace(/^url\(#|\)$/g,N)))&&(rt=tt.getElementsByTagName("stop"),Q(rt[rt.length-1],{"stop-opacity":U}));break}default:Z=="font-size"&&(U=A(U,10)+"px");var ht=Z.replace(/(\-.)/g,function(Ot){return Ot.substring(1).toUpperCase()});O.style[ht]=U,T._.dirty=1,O.setAttribute(Z,U)}}c(T,M),O.style.visibility=ee},c=function(T,M){if(T.type=="text"&&(M[E]("text")||M[E]("font")||M[E]("font-size")||M[E]("x")||M[E]("y"))){var O=T.attrs,V=T.node,ee=V.firstChild?A(y._g.doc.defaultView.getComputedStyle(V.firstChild,N).getPropertyValue("font-size"),10):10;if(M[E]("text")){for(O.text=M.text;V.firstChild;)V.removeChild(V.firstChild);for(var Z,U=C(M.text).split(`
`),z=[],ne=0,fe=U.length;ne<fe;ne++)Z=Q("tspan"),ne&&Q(Z,{dy:1.2*ee,x:O.x}),Z.appendChild(y._g.doc.createTextNode(U[ne])),V.appendChild(Z),z[ne]=Z}else for(ne=0,fe=(z=V.getElementsByTagName("tspan")).length;ne<fe;ne++)ne?Q(z[ne],{dy:1.2*ee,x:O.x}):Q(z[0],{dy:0});Q(V,{x:O.x,y:O.y}),T._.dirty=1;var me=T._getBBox(),de=O.y-(me.y+me.height/2);de&&y.is(de,"finite")&&Q(z[0],{dy:de})}},p=function(T){return T.parentNode&&T.parentNode.tagName.toLowerCase()==="a"?T.parentNode:T},x=function(T,M){this[0]=this.node=T,T.raphael=!0,this.id=("0000"+(Math.random()*Math.pow(36,5)<<0).toString(36)).slice(-5),T.raphaelid=this.id,this.matrix=y.matrix(),this.realPath=null,this.paper=M,this.attrs=this.attrs||{},this._={transform:[],sx:1,sy:1,deg:0,dx:0,dy:0,dirty:1},!M.bottom&&(M.bottom=this),this.prev=M.top,M.top&&(M.top.next=this),M.top=this,this.next=null},S=y.el;x.prototype=S,S.constructor=x,y._engine.path=function(T,M){var O=Q("path");M.canvas&&M.canvas.appendChild(O);var V=new x(O,M);return V.type="path",w(V,{fill:"none",stroke:"#000",path:T}),V},S.rotate=function(T,M,O){if(this.removed)return this;if((T=C(T).split(F)).length-1&&(M=k(T[1]),O=k(T[2])),T=k(T[0]),O==null&&(M=O),M==null||O==null){var V=this.getBBox(1);M=V.x+V.width/2,O=V.y+V.height/2}return this.transform(this._.transform.concat([["r",T,M,O]])),this},S.scale=function(T,M,O,V){if(this.removed)return this;if((T=C(T).split(F)).length-1&&(M=k(T[1]),O=k(T[2]),V=k(T[3])),T=k(T[0]),M==null&&(M=T),V==null&&(O=V),O==null||V==null)var ee=this.getBBox(1);return O=O??ee.x+ee.width/2,V=V??ee.y+ee.height/2,this.transform(this._.transform.concat([["s",T,M,O,V]])),this},S.translate=function(T,M){return this.removed?this:((T=C(T).split(F)).length-1&&(M=k(T[1])),T=k(T[0])||0,M=+M||0,this.transform(this._.transform.concat([["t",T,M]])),this)},S.transform=function(T){var M=this._;if(T==null)return M.transform;if(y._extractTransform(this,T),this.clip&&Q(this.clip,{transform:this.matrix.invert()}),this.pattern&&ke(this),this.node&&Q(this.node,{transform:this.matrix}),M.sx!=1||M.sy!=1){var O=this.attrs[E]("stroke-width")?this.attrs["stroke-width"]:1;this.attr({"stroke-width":O})}return this},S.hide=function(){return this.removed||(this.node.style.display="none"),this},S.show=function(){return this.removed||(this.node.style.display=""),this},S.remove=function(){var T=p(this.node);if(!this.removed&&T.parentNode){var M=this.paper;for(var O in M.__set__&&M.__set__.exclude(this),j.unbind("raphael.*.*."+this.id),this.gradient&&M.defs.removeChild(this.gradient),y._tear(this,M),T.parentNode.removeChild(T),this.removeData(),this)this[O]=typeof this[O]=="function"?y._removedFactory(O):null;this.removed=!0}},S._getBBox=function(){if(this.node.style.display=="none"){this.show();var T=!0}var M,O=!1;this.paper.canvas.parentElement?M=this.paper.canvas.parentElement.style:this.paper.canvas.parentNode&&(M=this.paper.canvas.parentNode.style),M&&M.display=="none"&&(O=!0,M.display="");var V={};try{V=this.node.getBBox()}catch{V={x:this.node.clientLeft,y:this.node.clientTop,width:this.node.clientWidth,height:this.node.clientHeight}}finally{V=V||{},O&&(M.display="none")}return T&&this.hide(),V},S.attr=function(T,M){if(this.removed)return this;if(T==null){var O={};for(var V in this.attrs)this.attrs[E](V)&&(O[V]=this.attrs[V]);return O.gradient&&O.fill=="none"&&(O.fill=O.gradient)&&delete O.gradient,O.transform=this._.transform,O}if(M==null&&y.is(T,"string")){if(T=="fill"&&this.attrs.fill=="none"&&this.attrs.gradient)return this.attrs.gradient;if(T=="transform")return this._.transform;for(var ee=T.split(F),Z={},U=0,z=ee.length;U<z;U++)(T=ee[U])in this.attrs?Z[T]=this.attrs[T]:y.is(this.paper.customAttributes[T],"function")?Z[T]=this.paper.customAttributes[T].def:Z[T]=y._availableAttrs[T];return z-1?Z:Z[ee[0]]}if(M==null&&y.is(T,"array")){for(Z={},U=0,z=T.length;U<z;U++)Z[T[U]]=this.attr(T[U]);return Z}if(M!=null){var ne={};ne[T]=M}else T!=null&&y.is(T,"object")&&(ne=T);for(var fe in ne)j("raphael.attr."+fe+"."+this.id,this,ne[fe]);for(fe in this.paper.customAttributes)if(this.paper.customAttributes[E](fe)&&ne[E](fe)&&y.is(this.paper.customAttributes[fe],"function")){var me=this.paper.customAttributes[fe].apply(this,[].concat(ne[fe]));for(var de in this.attrs[fe]=ne[fe],me)me[E](de)&&(ne[de]=me[de])}return w(this,ne),this},S.toFront=function(){if(this.removed)return this;var T=p(this.node);T.parentNode.appendChild(T);var M=this.paper;return M.top!=this&&y._tofront(this,M),this},S.toBack=function(){if(this.removed)return this;var T=p(this.node),M=T.parentNode;return M.insertBefore(T,M.firstChild),y._toback(this,this.paper),this.paper,this},S.insertAfter=function(T){if(this.removed||!T)return this;var M=p(this.node),O=p(T.node||T[T.length-1].node);return O.nextSibling?O.parentNode.insertBefore(M,O.nextSibling):O.parentNode.appendChild(M),y._insertafter(this,T,this.paper),this},S.insertBefore=function(T){if(this.removed||!T)return this;var M=p(this.node),O=p(T.node||T[0].node);return O.parentNode.insertBefore(M,O),y._insertbefore(this,T,this.paper),this},S.blur=function(T){var M=this;if(+T!=0){var O=Q("filter"),V=Q("feGaussianBlur");M.attrs.blur=T,O.id=y.createUUID(),Q(V,{stdDeviation:+T||1.5}),O.appendChild(V),M.paper.defs.appendChild(O),M._blur=O,Q(M.node,{filter:"url(#"+O.id+")"})}else M._blur&&(M._blur.parentNode.removeChild(M._blur),delete M._blur,delete M.attrs.blur),M.node.removeAttribute("filter");return M},y._engine.circle=function(T,M,O,V){var ee=Q("circle");T.canvas&&T.canvas.appendChild(ee);var Z=new x(ee,T);return Z.attrs={cx:M,cy:O,r:V,fill:"none",stroke:"#000"},Z.type="circle",Q(ee,Z.attrs),Z},y._engine.rect=function(T,M,O,V,ee,Z){var U=Q("rect");T.canvas&&T.canvas.appendChild(U);var z=new x(U,T);return z.attrs={x:M,y:O,width:V,height:ee,rx:Z||0,ry:Z||0,fill:"none",stroke:"#000"},z.type="rect",Q(U,z.attrs),z},y._engine.ellipse=function(T,M,O,V,ee){var Z=Q("ellipse");T.canvas&&T.canvas.appendChild(Z);var U=new x(Z,T);return U.attrs={cx:M,cy:O,rx:V,ry:ee,fill:"none",stroke:"#000"},U.type="ellipse",Q(Z,U.attrs),U},y._engine.image=function(T,M,O,V,ee,Z){var U=Q("image");Q(U,{x:O,y:V,width:ee,height:Z,preserveAspectRatio:"none"}),U.setAttributeNS(J,"href",M),T.canvas&&T.canvas.appendChild(U);var z=new x(U,T);return z.attrs={x:O,y:V,width:ee,height:Z,src:M},z.type="image",z},y._engine.text=function(T,M,O,V){var ee=Q("text");T.canvas&&T.canvas.appendChild(ee);var Z=new x(ee,T);return Z.attrs={x:M,y:O,"text-anchor":"middle",text:V,"font-family":y._availableAttrs["font-family"],"font-size":y._availableAttrs["font-size"],stroke:"none",fill:"#000"},Z.type="text",w(Z,Z.attrs),Z},y._engine.setSize=function(T,M){return this.width=T||this.width,this.height=M||this.height,this.canvas.setAttribute("width",this.width),this.canvas.setAttribute("height",this.height),this._viewBox&&this.setViewBox.apply(this,this._viewBox),this},y._engine.create=function(){var T=y._getContainer.apply(0,arguments),M=T&&T.container;if(!M)throw new Error("SVG container not found.");var O,V=T.x,ee=T.y,Z=T.width,U=T.height,z=Q("svg"),ne="overflow:hidden;";return V=V||0,ee=ee||0,Q(z,{height:U=U||342,version:1.1,width:Z=Z||512,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"}),M==1?(z.style.cssText=ne+"position:absolute;left:"+V+"px;top:"+ee+"px",y._g.doc.body.appendChild(z),O=1):(z.style.cssText=ne+"position:relative",M.firstChild?M.insertBefore(z,M.firstChild):M.appendChild(z)),(M=new y._Paper).width=Z,M.height=U,M.canvas=z,M.clear(),M._left=M._top=0,O&&(M.renderfix=function(){}),M.renderfix(),M},y._engine.setViewBox=function(T,M,O,V,ee){j("raphael.setViewBox",this,this._viewBox,[T,M,O,V,ee]);var Z,U,z=this.getSize(),ne=P(O/z.width,V/z.height),fe=this.top,me=ee?"xMidYMid meet":"xMinYMin";for(T==null?(this._vbSize&&(ne=1),delete this._vbSize,Z="0 0 "+this.width+Y+this.height):(this._vbSize=ne,Z=T+Y+M+Y+O+Y+V),Q(this.canvas,{viewBox:Z,preserveAspectRatio:me});ne&&fe;)U="stroke-width"in fe.attrs?fe.attrs["stroke-width"]:1,fe.attr({"stroke-width":U}),fe._.dirty=1,fe._.dirtyT=1,fe=fe.prev;return this._viewBox=[T,M,O,V,!!ee],this},y.prototype.renderfix=function(){var T,M=this.canvas,O=M.style;try{T=M.getScreenCTM()||M.createSVGMatrix()}catch{T=M.createSVGMatrix()}var V=-T.e%1,ee=-T.f%1;(V||ee)&&(V&&(this._left=(this._left+V)%1,O.left=this._left+"px"),ee&&(this._top=(this._top+ee)%1,O.top=this._top+"px"))},y.prototype.clear=function(){y.eve("raphael.clear",this);for(var T=this.canvas;T.firstChild;)T.removeChild(T.firstChild);this.bottom=this.top=null,(this.desc=Q("desc")).appendChild(y._g.doc.createTextNode("Created with Raphaël "+y.version)),T.appendChild(this.desc),T.appendChild(this.defs=Q("defs"))},y.prototype.remove=function(){for(var T in j("raphael.remove",this),this.canvas.parentNode&&this.canvas.parentNode.removeChild(this.canvas),this)this[T]=typeof this[T]=="function"?y._removedFactory(T):null};var b=y.st;for(var h in S)S[E](h)&&!b[E](h)&&(b[h]=function(T){return function(){var M=arguments;return this.forEach(function(O){O[T].apply(O,M)})}}(h))}}).apply(o,l))===void 0||(n.exports=m)},function(n,o,u){var l,m;l=[u(0)],(m=(function(y){if(!y||y.vml){var E="hasOwnProperty",C=String,k=parseFloat,A=Math,D=A.round,P=A.max,R=A.min,B=A.abs,F=/[, ]+/,j=y.eve,N=" ",Y="",J={M:"m",L:"l",C:"c",Z:"x",m:"t",l:"r",c:"v",z:"x"},ie=/([clmz]),?([^clmz]*)/gi,ue=/ progid:\S+Blur\([^\)]+\)/g,Q=/-?[^,\s-]+/g,ce="position:absolute;left:0;top:0;width:1px;height:1px;behavior:url(#default#VML)",he=21600,ke={path:1,rect:1,image:1},L={circle:1,ellipse:1},d=function(M,O,V){var ee=y.matrix();return ee.rotate(-M,.5,.5),{dx:ee.x(O,V),dy:ee.y(O,V)}},v=function(M,O,V,ee,Z,U){var z=M._,ne=M.matrix,fe=z.fillpos,me=M.node,de=me.style,je=1,lt="",it=he/O,ot=he/V;if(de.visibility="hidden",O&&V){if(me.coordsize=B(it)+N+B(ot),de.rotation=U*(O*V<0?-1:1),U){var Ct=d(U,ee,Z);ee=Ct.dx,Z=Ct.dy}if(O<0&&(lt+="x"),V<0&&(lt+=" y")&&(je=-1),de.flip=lt,me.coordorigin=ee*-it+N+Z*-ot,fe||z.fillsize){var nt=me.getElementsByTagName("fill");nt=nt&&nt[0],me.removeChild(nt),fe&&(Ct=d(U,ne.x(fe[0],fe[1]),ne.y(fe[0],fe[1])),nt.position=Ct.dx*je+N+Ct.dy*je),z.fillsize&&(nt.size=z.fillsize[0]*B(O)+N+z.fillsize[1]*B(V)),me.appendChild(nt)}de.visibility="visible"}};y.toString=function(){return`Your browser doesn’t support SVG. Falling down to VML.
You are running Raphaël `+this.version};var w,c=function(M,O,V){for(var ee=C(O).toLowerCase().split("-"),Z=V?"end":"start",U=ee.length,z="classic",ne="medium",fe="medium";U--;)switch(ee[U]){case"block":case"classic":case"oval":case"diamond":case"open":case"none":z=ee[U];break;case"wide":case"narrow":fe=ee[U];break;case"long":case"short":ne=ee[U]}var me=M.node.getElementsByTagName("stroke")[0];me[Z+"arrow"]=z,me[Z+"arrowlength"]=ne,me[Z+"arrowwidth"]=fe},p=function(M,O){M.attrs=M.attrs||{};var V=M.node,ee=M.attrs,Z=V.style,U=ke[M.type]&&(O.x!=ee.x||O.y!=ee.y||O.width!=ee.width||O.height!=ee.height||O.cx!=ee.cx||O.cy!=ee.cy||O.rx!=ee.rx||O.ry!=ee.ry||O.r!=ee.r),z=L[M.type]&&(ee.cx!=O.cx||ee.cy!=O.cy||ee.r!=O.r||ee.rx!=O.rx||ee.ry!=O.ry),ne=M;for(var fe in O)O[E](fe)&&(ee[fe]=O[fe]);if(U&&(ee.path=y._getPath[M.type](M),M._.dirty=1),O.href&&(V.href=O.href),O.title&&(V.title=O.title),O.target&&(V.target=O.target),O.cursor&&(Z.cursor=O.cursor),"blur"in O&&M.blur(O.blur),(O.path&&M.type=="path"||U)&&(V.path=function(Ue){var Qe=/[ahqstv]/gi,Ke=y._pathToAbsolute;if(C(Ue).match(Qe)&&(Ke=y._path2curve),Qe=/[clmz]/g,Ke==y._pathToAbsolute&&!C(Ue).match(Qe)){var De=C(Ue).replace(ie,function(ut,$t,fi){var kt=[],Wt=$t.toLowerCase()=="m",Zi=J[$t];return fi.replace(Q,function(Ut){Wt&&kt.length==2&&(Zi+=kt+J[$t=="m"?"l":"L"],kt=[]),kt.push(D(Ut*he))}),Zi+kt});return De}var Vt,At,ve=Ke(Ue);De=[];for(var Pt=0,pt=ve.length;Pt<pt;Pt++){Vt=ve[Pt],(At=ve[Pt][0].toLowerCase())=="z"&&(At="x");for(var Ne=1,vt=Vt.length;Ne<vt;Ne++)At+=D(Vt[Ne]*he)+(Ne!=vt-1?",":Y);De.push(At)}return De.join(N)}(~C(ee.path).toLowerCase().indexOf("r")?y._pathToAbsolute(ee.path):ee.path),M._.dirty=1,M.type=="image"&&(M._.fillpos=[ee.x,ee.y],M._.fillsize=[ee.width,ee.height],v(M,1,1,0,0,0))),"transform"in O&&M.transform(O.transform),z){var me=+ee.cx,de=+ee.cy,je=+ee.rx||+ee.r||0,lt=+ee.ry||+ee.r||0;V.path=y.format("ar{0},{1},{2},{3},{4},{1},{4},{1}x",D((me-je)*he),D((de-lt)*he),D((me+je)*he),D((de+lt)*he),D(me*he)),M._.dirty=1}if("clip-rect"in O){var it=C(O["clip-rect"]).split(F);if(it.length==4){it[2]=+it[2]+ +it[0],it[3]=+it[3]+ +it[1];var ot=V.clipRect||y._g.doc.createElement("div"),Ct=ot.style;Ct.clip=y.format("rect({1}px {2}px {3}px {0}px)",it),V.clipRect||(Ct.position="absolute",Ct.top=0,Ct.left=0,Ct.width=M.paper.width+"px",Ct.height=M.paper.height+"px",V.parentNode.insertBefore(ot,V),ot.appendChild(V),V.clipRect=ot)}O["clip-rect"]||V.clipRect&&(V.clipRect.style.clip="auto")}if(M.textpath){var nt=M.textpath.style;O.font&&(nt.font=O.font),O["font-family"]&&(nt.fontFamily='"'+O["font-family"].split(",")[0].replace(/^['"]+|['"]+$/g,Y)+'"'),O["font-size"]&&(nt.fontSize=O["font-size"]),O["font-weight"]&&(nt.fontWeight=O["font-weight"]),O["font-style"]&&(nt.fontStyle=O["font-style"])}if("arrow-start"in O&&c(ne,O["arrow-start"]),"arrow-end"in O&&c(ne,O["arrow-end"],1),O.opacity!=null||O.fill!=null||O.src!=null||O.stroke!=null||O["stroke-width"]!=null||O["stroke-opacity"]!=null||O["fill-opacity"]!=null||O["stroke-dasharray"]!=null||O["stroke-miterlimit"]!=null||O["stroke-linejoin"]!=null||O["stroke-linecap"]!=null){var Je=V.getElementsByTagName("fill");if(!(Je=Je&&Je[0])&&(Je=w("fill")),M.type=="image"&&O.src&&(Je.src=O.src),O.fill&&(Je.on=!0),Je.on!=null&&O.fill!="none"&&O.fill!==null||(Je.on=!1),Je.on&&O.fill){var tt=C(O.fill).match(y._ISURL);if(tt){Je.parentNode==V&&V.removeChild(Je),Je.rotate=!0,Je.src=tt[1],Je.type="tile";var rt=M.getBBox(1);Je.position=rt.x+N+rt.y,M._.fillpos=[rt.x,rt.y],y._preload(tt[1],function(){M._.fillsize=[this.offsetWidth,this.offsetHeight]})}else Je.color=y.getRGB(O.fill).hex,Je.src=Y,Je.type="solid",y.getRGB(O.fill).error&&(ne.type in{circle:1,ellipse:1}||C(O.fill).charAt()!="r")&&x(ne,O.fill,Je)&&(ee.fill="none",ee.gradient=O.fill,Je.rotate=!1)}if("fill-opacity"in O||"opacity"in O){var ht=((+ee["fill-opacity"]+1||2)-1)*((+ee.opacity+1||2)-1)*((+y.getRGB(O.fill).o+1||2)-1);ht=R(P(ht,0),1),Je.opacity=ht,Je.src&&(Je.color="none")}V.appendChild(Je);var Ot=V.getElementsByTagName("stroke")&&V.getElementsByTagName("stroke")[0],Ve=!1;!Ot&&(Ve=Ot=w("stroke")),(O.stroke&&O.stroke!="none"||O["stroke-width"]||O["stroke-opacity"]!=null||O["stroke-dasharray"]||O["stroke-miterlimit"]||O["stroke-linejoin"]||O["stroke-linecap"])&&(Ot.on=!0),(O.stroke=="none"||O.stroke===null||Ot.on==null||O.stroke==0||O["stroke-width"]==0)&&(Ot.on=!1);var We=y.getRGB(O.stroke);Ot.on&&O.stroke&&(Ot.color=We.hex),ht=((+ee["stroke-opacity"]+1||2)-1)*((+ee.opacity+1||2)-1)*((+We.o+1||2)-1);var Gt=.75*(k(O["stroke-width"])||1);if(ht=R(P(ht,0),1),O["stroke-width"]==null&&(Gt=ee["stroke-width"]),O["stroke-width"]&&(Ot.weight=Gt),Gt&&Gt<1&&(ht*=Gt)&&(Ot.weight=1),Ot.opacity=ht,O["stroke-linejoin"]&&(Ot.joinstyle=O["stroke-linejoin"]||"miter"),Ot.miterlimit=O["stroke-miterlimit"]||8,O["stroke-linecap"]&&(Ot.endcap=O["stroke-linecap"]=="butt"?"flat":O["stroke-linecap"]=="square"?"square":"round"),"stroke-dasharray"in O){var wt={"-":"shortdash",".":"shortdot","-.":"shortdashdot","-..":"shortdashdotdot",". ":"dot","- ":"dash","--":"longdash","- .":"dashdot","--.":"longdashdot","--..":"longdashdotdot"};Ot.dashstyle=wt[E](O["stroke-dasharray"])?wt[O["stroke-dasharray"]]:Y}Ve&&V.appendChild(Ot)}if(ne.type=="text"){ne.paper.canvas.style.display=Y;var Et=ne.paper.span,Yt=ee.font&&ee.font.match(/\d+(?:\.\d*)?(?=px)/);Z=Et.style,ee.font&&(Z.font=ee.font),ee["font-family"]&&(Z.fontFamily=ee["font-family"]),ee["font-weight"]&&(Z.fontWeight=ee["font-weight"]),ee["font-style"]&&(Z.fontStyle=ee["font-style"]),Yt=k(ee["font-size"]||Yt&&Yt[0])||10,Z.fontSize=100*Yt+"px",ne.textpath.string&&(Et.innerHTML=C(ne.textpath.string).replace(/</g,"&#60;").replace(/&/g,"&#38;").replace(/\n/g,"<br>"));var Ce=Et.getBoundingClientRect();ne.W=ee.w=(Ce.right-Ce.left)/100,ne.H=ee.h=(Ce.bottom-Ce.top)/100,ne.X=ee.x,ne.Y=ee.y+ne.H/2,("x"in O||"y"in O)&&(ne.path.v=y.format("m{0},{1}l{2},{1}",D(ee.x*he),D(ee.y*he),D(ee.x*he)+1));for(var te=["x","y","text","font","font-family","font-weight","font-style","font-size"],ye=0,Le=te.length;ye<Le;ye++)if(te[ye]in O){ne._.dirty=1;break}switch(ee["text-anchor"]){case"start":ne.textpath.style["v-text-align"]="left",ne.bbx=ne.W/2;break;case"end":ne.textpath.style["v-text-align"]="right",ne.bbx=-ne.W/2;break;default:ne.textpath.style["v-text-align"]="center",ne.bbx=0}ne.textpath.style["v-text-kern"]=!0}},x=function(M,O,V){M.attrs=M.attrs||{},M.attrs;var ee=Math.pow,Z="linear",U=".5 .5";if(M.attrs.gradient=O,O=(O=C(O).replace(y._radial_gradient,function(je,lt,it){return Z="radial",lt&&it&&(lt=k(lt),it=k(it),ee(lt-.5,2)+ee(it-.5,2)>.25&&(it=A.sqrt(.25-ee(lt-.5,2))*(2*(it>.5)-1)+.5),U=lt+N+it),Y})).split(/\s*\-\s*/),Z=="linear"){var z=O.shift();if(z=-k(z),isNaN(z))return null}var ne=y._parseDots(O);if(!ne)return null;if(M=M.shape||M.node,ne.length){M.removeChild(V),V.on=!0,V.method="none",V.color=ne[0].color,V.color2=ne[ne.length-1].color;for(var fe=[],me=0,de=ne.length;me<de;me++)ne[me].offset&&fe.push(ne[me].offset+N+ne[me].color);V.colors=fe.length?fe.join():"0% "+V.color,Z=="radial"?(V.type="gradientTitle",V.focus="100%",V.focussize="0 0",V.focusposition=U,V.angle=0):(V.type="gradient",V.angle=(270-z)%360),M.appendChild(V)}return 1},S=function(M,O){this[0]=this.node=M,M.raphael=!0,this.id=y._oid++,M.raphaelid=this.id,this.X=0,this.Y=0,this.attrs={},this.paper=O,this.matrix=y.matrix(),this._={transform:[],sx:1,sy:1,dx:0,dy:0,deg:0,dirty:1,dirtyT:1},!O.bottom&&(O.bottom=this),this.prev=O.top,O.top&&(O.top.next=this),O.top=this,this.next=null},b=y.el;S.prototype=b,b.constructor=S,b.transform=function(M){if(M==null)return this._.transform;var O,V=this.paper._viewBoxShift,ee=V?"s"+[V.scale,V.scale]+"-1-1t"+[V.dx,V.dy]:Y;V&&(O=M=C(M).replace(/\.{3}|\u2026/g,this._.transform||Y)),y._extractTransform(this,ee+M);var Z,U=this.matrix.clone(),z=this.skew,ne=this.node,fe=~C(this.attrs.fill).indexOf("-"),me=!C(this.attrs.fill).indexOf("url(");if(U.translate(1,1),me||fe||this.type=="image")if(z.matrix="1 0 0 1",z.offset="0 0",Z=U.split(),fe&&Z.noRotation||!Z.isSimple){ne.style.filter=U.toFilter();var de=this.getBBox(),je=this.getBBox(1),lt=de.x-je.x,it=de.y-je.y;ne.coordorigin=lt*-he+N+it*-he,v(this,1,1,lt,it,0)}else ne.style.filter=Y,v(this,Z.scalex,Z.scaley,Z.dx,Z.dy,Z.rotate);else ne.style.filter=Y,z.matrix=C(U),z.offset=U.offset();return O!==null&&(this._.transform=O,y._extractTransform(this,O)),this},b.rotate=function(M,O,V){if(this.removed)return this;if(M!=null){if((M=C(M).split(F)).length-1&&(O=k(M[1]),V=k(M[2])),M=k(M[0]),V==null&&(O=V),O==null||V==null){var ee=this.getBBox(1);O=ee.x+ee.width/2,V=ee.y+ee.height/2}return this._.dirtyT=1,this.transform(this._.transform.concat([["r",M,O,V]])),this}},b.translate=function(M,O){return this.removed?this:((M=C(M).split(F)).length-1&&(O=k(M[1])),M=k(M[0])||0,O=+O||0,this._.bbox&&(this._.bbox.x+=M,this._.bbox.y+=O),this.transform(this._.transform.concat([["t",M,O]])),this)},b.scale=function(M,O,V,ee){if(this.removed)return this;if((M=C(M).split(F)).length-1&&(O=k(M[1]),V=k(M[2]),ee=k(M[3]),isNaN(V)&&(V=null),isNaN(ee)&&(ee=null)),M=k(M[0]),O==null&&(O=M),ee==null&&(V=ee),V==null||ee==null)var Z=this.getBBox(1);return V=V??Z.x+Z.width/2,ee=ee??Z.y+Z.height/2,this.transform(this._.transform.concat([["s",M,O,V,ee]])),this._.dirtyT=1,this},b.hide=function(){return!this.removed&&(this.node.style.display="none"),this},b.show=function(){return!this.removed&&(this.node.style.display=Y),this},b.auxGetBBox=y.el.getBBox,b.getBBox=function(){var M=this.auxGetBBox();if(this.paper&&this.paper._viewBoxShift){var O={},V=1/this.paper._viewBoxShift.scale;return O.x=M.x-this.paper._viewBoxShift.dx,O.x*=V,O.y=M.y-this.paper._viewBoxShift.dy,O.y*=V,O.width=M.width*V,O.height=M.height*V,O.x2=O.x+O.width,O.y2=O.y+O.height,O}return M},b._getBBox=function(){return this.removed?{}:{x:this.X+(this.bbx||0)-this.W/2,y:this.Y-this.H,width:this.W,height:this.H}},b.remove=function(){if(!this.removed&&this.node.parentNode){for(var M in this.paper.__set__&&this.paper.__set__.exclude(this),y.eve.unbind("raphael.*.*."+this.id),y._tear(this,this.paper),this.node.parentNode.removeChild(this.node),this.shape&&this.shape.parentNode.removeChild(this.shape),this)this[M]=typeof this[M]=="function"?y._removedFactory(M):null;this.removed=!0}},b.attr=function(M,O){if(this.removed)return this;if(M==null){var V={};for(var ee in this.attrs)this.attrs[E](ee)&&(V[ee]=this.attrs[ee]);return V.gradient&&V.fill=="none"&&(V.fill=V.gradient)&&delete V.gradient,V.transform=this._.transform,V}if(O==null&&y.is(M,"string")){if(M=="fill"&&this.attrs.fill=="none"&&this.attrs.gradient)return this.attrs.gradient;for(var Z=M.split(F),U={},z=0,ne=Z.length;z<ne;z++)(M=Z[z])in this.attrs?U[M]=this.attrs[M]:y.is(this.paper.customAttributes[M],"function")?U[M]=this.paper.customAttributes[M].def:U[M]=y._availableAttrs[M];return ne-1?U:U[Z[0]]}if(this.attrs&&O==null&&y.is(M,"array")){for(U={},z=0,ne=M.length;z<ne;z++)U[M[z]]=this.attr(M[z]);return U}var fe;for(var me in O!=null&&((fe={})[M]=O),O==null&&y.is(M,"object")&&(fe=M),fe)j("raphael.attr."+me+"."+this.id,this,fe[me]);if(fe){for(me in this.paper.customAttributes)if(this.paper.customAttributes[E](me)&&fe[E](me)&&y.is(this.paper.customAttributes[me],"function")){var de=this.paper.customAttributes[me].apply(this,[].concat(fe[me]));for(var je in this.attrs[me]=fe[me],de)de[E](je)&&(fe[je]=de[je])}fe.text&&this.type=="text"&&(this.textpath.string=fe.text),p(this,fe)}return this},b.toFront=function(){return!this.removed&&this.node.parentNode.appendChild(this.node),this.paper&&this.paper.top!=this&&y._tofront(this,this.paper),this},b.toBack=function(){return this.removed?this:(this.node.parentNode.firstChild!=this.node&&(this.node.parentNode.insertBefore(this.node,this.node.parentNode.firstChild),y._toback(this,this.paper)),this)},b.insertAfter=function(M){return this.removed?this:(M.constructor==y.st.constructor&&(M=M[M.length-1]),M.node.nextSibling?M.node.parentNode.insertBefore(this.node,M.node.nextSibling):M.node.parentNode.appendChild(this.node),y._insertafter(this,M,this.paper),this)},b.insertBefore=function(M){return this.removed?this:(M.constructor==y.st.constructor&&(M=M[0]),M.node.parentNode.insertBefore(this.node,M.node),y._insertbefore(this,M,this.paper),this)},b.blur=function(M){var O=this.node.runtimeStyle,V=O.filter;return V=V.replace(ue,Y),+M!=0?(this.attrs.blur=M,O.filter=V+N+" progid:DXImageTransform.Microsoft.Blur(pixelradius="+(+M||1.5)+")",O.margin=y.format("-{0}px 0 0 -{0}px",D(+M||1.5))):(O.filter=V,O.margin=0,delete this.attrs.blur),this},y._engine.path=function(M,O){var V=w("shape");V.style.cssText=ce,V.coordsize=he+N+he,V.coordorigin=O.coordorigin;var ee=new S(V,O),Z={fill:"none",stroke:"#000"};M&&(Z.path=M),ee.type="path",ee.path=[],ee.Path=Y,p(ee,Z),O.canvas&&O.canvas.appendChild(V);var U=w("skew");return U.on=!0,V.appendChild(U),ee.skew=U,ee.transform(Y),ee},y._engine.rect=function(M,O,V,ee,Z,U){var z=y._rectPath(O,V,ee,Z,U),ne=M.path(z),fe=ne.attrs;return ne.X=fe.x=O,ne.Y=fe.y=V,ne.W=fe.width=ee,ne.H=fe.height=Z,fe.r=U,fe.path=z,ne.type="rect",ne},y._engine.ellipse=function(M,O,V,ee,Z){var U=M.path();return U.attrs,U.X=O-ee,U.Y=V-Z,U.W=2*ee,U.H=2*Z,U.type="ellipse",p(U,{cx:O,cy:V,rx:ee,ry:Z}),U},y._engine.circle=function(M,O,V,ee){var Z=M.path();return Z.attrs,Z.X=O-ee,Z.Y=V-ee,Z.W=Z.H=2*ee,Z.type="circle",p(Z,{cx:O,cy:V,r:ee}),Z},y._engine.image=function(M,O,V,ee,Z,U){var z=y._rectPath(V,ee,Z,U),ne=M.path(z).attr({stroke:"none"}),fe=ne.attrs,me=ne.node,de=me.getElementsByTagName("fill")[0];return fe.src=O,ne.X=fe.x=V,ne.Y=fe.y=ee,ne.W=fe.width=Z,ne.H=fe.height=U,fe.path=z,ne.type="image",de.parentNode==me&&me.removeChild(de),de.rotate=!0,de.src=O,de.type="tile",ne._.fillpos=[V,ee],ne._.fillsize=[Z,U],me.appendChild(de),v(ne,1,1,0,0,0),ne},y._engine.text=function(M,O,V,ee){var Z=w("shape"),U=w("path"),z=w("textpath");O=O||0,V=V||0,ee=ee||"",U.v=y.format("m{0},{1}l{2},{1}",D(O*he),D(V*he),D(O*he)+1),U.textpathok=!0,z.string=C(ee),z.on=!0,Z.style.cssText=ce,Z.coordsize=he+N+he,Z.coordorigin="0 0";var ne=new S(Z,M),fe={fill:"#000",stroke:"none",font:y._availableAttrs.font,text:ee};ne.shape=Z,ne.path=U,ne.textpath=z,ne.type="text",ne.attrs.text=C(ee),ne.attrs.x=O,ne.attrs.y=V,ne.attrs.w=1,ne.attrs.h=1,p(ne,fe),Z.appendChild(z),Z.appendChild(U),M.canvas.appendChild(Z);var me=w("skew");return me.on=!0,Z.appendChild(me),ne.skew=me,ne.transform(Y),ne},y._engine.setSize=function(M,O){var V=this.canvas.style;return this.width=M,this.height=O,M==+M&&(M+="px"),O==+O&&(O+="px"),V.width=M,V.height=O,V.clip="rect(0 "+M+" "+O+" 0)",this._viewBox&&y._engine.setViewBox.apply(this,this._viewBox),this},y._engine.setViewBox=function(M,O,V,ee,Z){y.eve("raphael.setViewBox",this,this._viewBox,[M,O,V,ee,Z]);var U,z,ne=this.getSize(),fe=ne.width,me=ne.height;return Z&&(V*(U=me/ee)<fe&&(M-=(fe-V*U)/2/U),ee*(z=fe/V)<me&&(O-=(me-ee*z)/2/z)),this._viewBox=[M,O,V,ee,!!Z],this._viewBoxShift={dx:-M,dy:-O,scale:ne},this.forEach(function(de){de.transform("...")}),this},y._engine.initWin=function(M){var O=M.document;O.styleSheets.length<31?O.createStyleSheet().addRule(".rvml","behavior:url(#default#VML)"):O.styleSheets[0].addRule(".rvml","behavior:url(#default#VML)");try{!O.namespaces.rvml&&O.namespaces.add("rvml","urn:schemas-microsoft-com:vml"),w=function(V){return O.createElement("<rvml:"+V+' class="rvml">')}}catch{w=function(ee){return O.createElement("<"+ee+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">')}}},y._engine.initWin(y._g.win),y._engine.create=function(){var M=y._getContainer.apply(0,arguments),O=M.container,V=M.height,ee=M.width,Z=M.x,U=M.y;if(!O)throw new Error("VML container not found.");var z=new y._Paper,ne=z.canvas=y._g.doc.createElement("div"),fe=ne.style;return Z=Z||0,U=U||0,ee=ee||512,V=V||342,z.width=ee,z.height=V,ee==+ee&&(ee+="px"),V==+V&&(V+="px"),z.coordsize=216e5+N+216e5,z.coordorigin="0 0",z.span=y._g.doc.createElement("span"),z.span.style.cssText="position:absolute;left:-9999em;top:-9999em;padding:0;margin:0;line-height:1;",ne.appendChild(z.span),fe.cssText=y.format("top:0;left:0;width:{0};height:{1};display:inline-block;position:relative;clip:rect(0 {0} {1} 0);overflow:hidden",ee,V),O==1?(y._g.doc.body.appendChild(ne),fe.left=Z+"px",fe.top=U+"px",fe.position="absolute"):O.firstChild?O.insertBefore(ne,O.firstChild):O.appendChild(ne),z.renderfix=function(){},z},y.prototype.clear=function(){y.eve("raphael.clear",this),this.canvas.innerHTML=Y,this.span=y._g.doc.createElement("span"),this.span.style.cssText="position:absolute;left:-9999em;top:-9999em;padding:0;margin:0;line-height:1;display:inline;",this.canvas.appendChild(this.span),this.bottom=this.top=null},y.prototype.remove=function(){for(var M in y.eve("raphael.remove",this),this.canvas.parentNode.removeChild(this.canvas),this)this[M]=typeof this[M]=="function"?y._removedFactory(M):null;return!0};var h=y.st;for(var T in b)b[E](T)&&!h[E](T)&&(h[T]=function(M){return function(){var O=arguments;return this.forEach(function(V){V[M].apply(V,O)})}}(T))}}).apply(o,l))===void 0||(n.exports=m)}])})})(raphael_min);var raphael_minExports=raphael_min.exports;const Raphael=getDefaultExportFromCjs$1(raphael_minExports),Arrow=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.current_pilot_widget=this.pilot_widget}draw(){this.height=this.arrow_height+this.base_height,this.$.addClass("Ldt-Arrow").css({height:1+this.height+"px","margin-top":"1px",overflow:"hidden"}),this.paper=new Raphael(this.container,this.width,1+this.height),window.myArrow=this,this.svgArrow=this.paper.path("M0,"+this.height+"L"+this.width+","+this.height),this.svgArrow.attr({stroke:this.stroke_color,"stroke-width":this.stroke_width,fill:this.fill_url?"url("+this.fill_url+")":this.fill_color}),this.moveToX(0)}drawAt(n){n=Math.max(0,Math.min(n,this.width));var o="M0,"+this.height+"L0,"+Math.min(this.height,this.arrow_height+this.base_curve)+"Q0,"+this.arrow_height+" "+Math.max(0,Math.min(this.base_curve,n-this.arrow_width/2))+","+this.arrow_height+"L"+Math.max(0,n-this.arrow_width/2)+","+this.arrow_height+"L"+Math.max(0,n-this.arrow_width/2)+","+Math.min(this.arrow_height,2*this.arrow_height*n/this.arrow_width)+"L"+n+",0L"+Math.min(this.width,n+this.arrow_width/2)+","+Math.min(this.arrow_height,2*this.arrow_height*(this.width-n)/this.arrow_width)+"L"+Math.min(this.width,n+this.arrow_width/2)+","+this.arrow_height+"L"+Math.min(this.width,Math.max(this.width-this.base_curve,n+this.arrow_width/2))+","+this.arrow_height+"Q"+this.width+","+this.arrow_height+" "+this.width+","+Math.min(this.height,this.arrow_height+this.base_curve)+"L"+this.width+","+this.height;this.svgArrow.attr({path:o})}moveToX(n){this.targetX=Math.max(0,Math.min(n,this.width)),typeof this.animInterval>"u"&&(this.animInterval=window.setInterval(this.functionWrapper("increment"),40)),this.increment()}moveToTime(n){this.media&&this.moveToX(this.width*n/this.media.duration)}increment(){typeof this.currentX>"u"&&(this.currentX=this.targetX),this.currentX<this.targetX&&(this.currentX=Math.min(this.targetX,this.currentX+this.animation_speed)),this.currentX>this.targetX&&(this.currentX=Math.max(this.targetX,this.currentX-this.animation_speed)),this.currentX===this.targetX&&(window.clearInterval(this.animInterval),this.animInterval=void 0),this.drawAt(this.currentX)}},Fi(e,"defaults",{arrow_height:12,arrow_width:20,base_height:0,base_curve:0,fill_url:t.widgetsDir+"/img/pinstripe.png",fill_color:"#ffffff",stroke_color:"#b7b7b7",stroke_width:1.5,animation_speed:20}),e},controllerStyles={},Controller=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.lastSearchValue=""}draw(){var n=this;this.renderTemplate(),this.$playButton=this.$.find(".Ldt-Ctrl-Play"),this.$searchBlock=this.$.find(".Ldt-Ctrl-Search"),this.$searchInput=this.$.find(".Ldt-Ctrl-SearchInput"),this.$volumeBar=this.$.find(".Ldt-Ctrl-Volume-Bar"),this.onMediaEvent("play","playButtonUpdater"),this.onMediaEvent("pause","playButtonUpdater"),this.onMediaEvent("volumechange","volumeUpdater"),this.onMediaEvent("timeupdate","timeDisplayUpdater"),this.onMediaEvent("loadedmetadata","volumeUpdater"),this.$playButton.click(this.functionWrapper("playHandler")),this.enable_quiz_toggle!==void 0?this.enable_quiz_toggle?(this.$.find(".Ldt-Ctrl-Quiz-Enable").addClass("Ldt-Ctrl-Quiz-Toggle-Active"),this.$.find(".Ldt-Ctrl-Quiz-Create").addClass("Ldt-Ctrl-Quiz-Toggle-Active"),this.$.find("#QuizEditContainer").show()):(this.$.find(".Ldt-Ctrl-Quiz-Enable").removeClass("Ldt-Ctrl-Quiz-Toggle-Active"),this.$.find(".Ldt-Ctrl-Quiz-Create").removeClass("Ldt-Ctrl-Quiz-Toggle-Active"),this.player.trigger("QuizCreator.hide"),this.$.find("#QuizEditContainer").hide()):this.$.find(".Ldt-Ctrl-Quiz-Enable").hide(),this.$.find(".Ldt-Ctrl-Annotate").click(function(){n.player.trigger("CreateAnnotation.toggle")}),this.$.find(".Ldt-Ctrl-SearchBtn").click(this.functionWrapper("searchButtonHandler")),this.$searchInput.keyup(this.functionWrapper("searchHandler")),this.$searchInput.on("search",this.functionWrapper("searchHandler")),this.$.find(".Ldt-Ctrl-Fullscreen-Button").click(this.functionWrapper("toggleFullscreen"));var o=t.getFullscreenEventname();o&&document.addEventListener(o,function(){t.isFullscreen()&&t.getFullscreenElement()==n.$[0]?n.$.addClass("Ldt-Fullscreen-Element"):n.$.removeClass("Ldt-Fullscreen-Element")}),this.$.find(".Ldt-Ctrl-Quiz-Enable").click(this.functionWrapper("toggleQuiz")),this.$.find(".Ldt-Ctrl-Quiz-Create").click(this.functionWrapper("createQuiz"));var u=this.$.find(".Ldt-Ctrl-Volume-Control");if(this.$.find(".Ldt-Ctrl-Sound").click(this.functionWrapper("muteHandler")).mouseover(function(){u.show()}).mouseout(function(){u.hide()}),u.mouseover(function(){u.show()}).mouseout(function(){u.hide()}),!this.disable_ctrl_f){var l=70,m=0;jQuery(document).keydown(function(E){if(E.keyCode===l&&(E.ctrlKey||E.metaKey)){var C=jQuery.now();return C-m>2e3&&n.searchButtonHandler(),m=C,!1}})}this.$volumeBar.slider({slide:function(E,C){n.$volumeBar.attr("title",n.l10n.volume+": "+C.value+"%"),n.media.setVolume(C.value/100)},stop:this.functionWrapper("volumeUpdater")}),this.$.hover(function(){n.player.trigger("Player.MouseOver")},function(){n.player.trigger("Player.MouseOut")}),this.timeDisplayUpdater(new t.Model.Time(0));var y=this.source.getAnnotations();y.on("search",function(E){n.$searchInput.val(E),n.showSearchBlock()}),y.on("found",function(E){n.$searchInput.css("background-color","#e1ffe1")}),y.on("not-found",function(E){n.$searchInput.css("background-color","#d62e3a")}),y.on("search-cleared",function(){n.hideSearchBlock()}),n.always_show_search&&n.showSearchBlock()}timeDisplayUpdater(n){var o=this.media.duration;this.$.find(".Ldt-Ctrl-Time-Elapsed").html(n.toString()),this.$.find(".Ldt-Ctrl-Time-Total").html(o.toString())}playButtonUpdater(){this.media.getPaused()?this.$playButton.attr("title",this.l10n.play).removeClass("Ldt-Ctrl-Play-PauseState").addClass("Ldt-Ctrl-Play-PlayState"):this.$playButton.attr("title",this.l10n.pause).removeClass("Ldt-Ctrl-Play-PlayState").addClass("Ldt-Ctrl-Play-PauseState")}toggleFullscreen(){t.isFullscreen()?t.setFullScreen(this.$[0],!1):t.setFullScreen(this.$[0],!0)}createQuiz(){this.player.trigger("Quiz.hide"),this.media.pause(),this.player.trigger("QuizCreator.create")}toggleQuiz(){this.enable_quiz_toggle=!this.enable_quiz_toggle,this.enable_quiz_toggle?(jQuery(".Ldt-Ctrl-Quiz-Enable").addClass("Ldt-Ctrl-Quiz-Toggle-Active"),jQuery(".Ldt-Ctrl-Quiz-Create").addClass("Ldt-Ctrl-Quiz-Toggle-Active"),this.player.trigger("Quiz.activate")):(jQuery(".Ldt-Ctrl-Quiz-Enable").removeClass("Ldt-Ctrl-Quiz-Toggle-Active"),jQuery(".Ldt-Ctrl-Quiz-Create").removeClass("Ldt-Ctrl-Quiz-Toggle-Active"),this.player.trigger("Quiz.deactivate"),this.player.trigger("QuizCreator.hide"))}playHandler(){this.media.getPaused()?this.media.play():this.media.pause()}muteHandler(){this.media.setMuted(!this.media.getMuted())}volumeUpdater(){var n=this.media.getMuted(),o=this.media.getVolume();o===!1&&(o=.5);var u=this.$.find(".Ldt-Ctrl-Sound");u.removeClass("Ldt-Ctrl-Sound-Mute Ldt-Ctrl-Sound-Half Ldt-Ctrl-Sound-Full"),n?u.attr("title",this.l10n.unmute).addClass("Ldt-Ctrl-Sound-Mute"):u.attr("title",this.l10n.mute).addClass(o<.5?"Ldt-Ctrl-Sound-Half":"Ldt-Ctrl-Sound-Full"),this.$volumeBar.slider("value",n?0:100*o)}showSearchBlock(){this.$searchBlock.animate({width:"160px"},200),this.$searchInput.css("background-color","#fff"),this.$searchInput.focus()}hideSearchBlock(){this.always_show_search||this.$searchBlock.animate({width:0},200)}searchButtonHandler(){if(this.$searchBlock.width())this.hideSearchBlock();else{this.showSearchBlock();var n=this.$searchInput.val();n&&this.source.getAnnotations().search(n)}}searchHandler(){this.$searchBlock.width()||(this.$searchBlock.css({width:"160px"}),this.$searchInput.css("background-color","#fff"));var n=this.$searchInput.val();this._positiveMatch=!1,n!==this.lastSearchValue&&(n?this.source.getAnnotations().search(n):(this.source.getAnnotations().trigger("clear-search"),this.$searchInput.css("background-color",""))),this.lastSearchValue=n}},Fi(e,"defaults",{disable_annotate_btn:!1,disable_search_btn:!1,disable_ctrl_f:!1,disable_fullscreen:!0,always_show_search:!1,enable_quiz_toggle:void 0}),Fi(e,"template",'<div class="Ldt-Ctrl"><div class="Ldt-Ctrl-Left"><div class="Ldt-Ctrl-button Ldt-Ctrl-Play Ldt-Ctrl-Play-PlayState Ldt-TraceMe" title="{{l10n.play_pause}}"></div><div class="Ldt-Ctrl-spacer"></div>{{^disable_annotate_btn}}<div class="Ldt-Ctrl-button Ldt-Ctrl-Annotate Ldt-TraceMe" title="{{l10n.annotate}}"></div><div class="Ldt-Ctrl-spacer"></div>{{/disable_annotate_btn}}{{^disable_search_btn}}<div class="Ldt-Ctrl-button Ldt-Ctrl-SearchBtn Ldt-TraceMe" title="{{l10n.search}}"></div>{{/disable_search_btn}}<div class="Ldt-Ctrl-Search"><input placeholder="{{ l10n.search }}" type="search" class="Ldt-Ctrl-SearchInput Ldt-TraceMe"></input></div><div class="Ldt-Ctrl-Quiz-Enable Ldt-TraceMe" title="Activer/Désactiver le quiz"></div><div class="Ldt-Ctrl-Quiz-Create Ldt-TraceMe" ></div></div><div class="Ldt-Ctrl-Right">{{^disable_fullscreen}}<div class="Ldt-Ctrl-Fullscreen-Button Ldt-TraceMe" title="Passer le lecteur en plein-écran"></div{{/disable_fullscreen}}<div class="Ldt-Ctrl-spacer"></div><div class="Ldt-Ctrl-Time"><div class="Ldt-Ctrl-Time-Elapsed" title="{{l10n.elapsed_time}}">00:00</div><div class="Ldt-Ctrl-Time-Separator">/</div><div class="Ldt-Ctrl-Time-Total" title="{{l10n.total_time}}">00:00</div></div><div class="Ldt-Ctrl-spacer"></div><div class="Ldt-Ctrl-button Ldt-Ctrl-Sound Ldt-Ctrl-Sound-Full Ldt-TraceMe" title="{{l10n.mute_unmute}}"></div></div><div class="Ldt-Ctrl-Volume-Control" title="{{l10n.volume_control}}"><div class="Ldt-Ctrl-Volume-Bar"></div></div></div>'),Fi(e,"messages",{en:{play_pause:"Play/Pause",mute_unmute:"Mute/Unmute",play:"Play",pause:"Pause",mute:"Mute",unmute:"Unmute",annotate:"Annotate",search:"Search",elapsed_time:"Elapsed time",total_time:"Total duration",volume:"Volume",volume_control:"Volume control",enable_quiz:"Enable quiz"},fr:{play_pause:"Lecture/Pause",mute_unmute:"Couper/Activer le son",play:"Lecture",pause:"Pause",mute:"Couper le son",unmute:"Activer le son",annotate:"Annoter",search:"Rechercher",elapsed_time:"Temps écoulé",total_time:"Durée totale",volume:"Niveau sonore",volume_control:"Réglage du niveau sonore",enable_quiz:"Activer le quiz"}}),e},createAnnotationStyles={},CreateAnnotation=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.editable_storage!=""&&window.localStorage[this.editable_storage]&&this.source.onLoad(function(){var u=this.player.sourceManager.newLocalSource({serializer:t.serializers.ldt_localstorage});u.deSerialize(window.localStorage[this.editable_storage]),_this.source.merge(u)})}draw(){var n=this;this.begin=new t.Model.Time,this.end=this.source.getDuration(),this.tag_prefix=this.tag_prefix||"",this.tag_titles&&!this.tags&&(this.tag_titles.length==1&&this.tag_titles[0]==""?this.tags=!0:this.tags=_$1(this.tag_titles).map(function(o){var u,l=n.source.getTags().searchByTitle(o,!0);return l.length?u=l[0]:(u=new t.Model.Tag(!1,n.source),n.source.getTags().push(u),u.title=o),u}).value()),this.tags||(this.tags=this.source.getTags().sortBy(function(o){return-o.getAnnotations().length}).slice(0,this.max_tags).map(function(o){return o})),this.renderTemplate(),this.show_slice?this.insertSubwidget(this.$.find(".Ldt-CreateAnnotation-Slice"),{type:"Slice",show_arrow:this.show_arrow,annotation_type:this.slice_annotation_type,onBoundsChanged:function(o,u){n.setBeginEnd(o,u)}},"slice"):(this.show_arrow&&this.insertSubwidget(this.$.find(".Ldt-CreateAnnotation-Arrow"),{type:"Arrow"},"arrow"),this.onMediaEvent("timeupdate",function(o){n.$.find(".Ldt-CreateAnnotation-Description").val().trim()==""&&(n.setBeginEnd(o,o),n.arrow&&n.arrow.moveToTime(o))})),this.$.find(".Ldt-CreateAnnotation-Cancel").click(function(){n.player.trigger("CreateAnnotation.hide")}),this.$.find(".Ldt-CreateAnnotation-Close").click(function(){return n.close_after_send?n.player.trigger("CreateAnnotation.hide"):n.showScreen("Main"),!1}),this.$.find(".Ldt-CreateAnnotation-TagLi, .Ldt-CreateAnnotation-PolemicLi").click(function(){return n.addKeyword(jQuery(this).attr("data-text")),!1}),this.$.find(".Ldt-CreateAnnotation-PolemicLi").each(function(){var o=jQuery(this),u=o.attr("data-text"),l=n.l10n["polemic"+u];l&&o.attr("title",l)}),this.$.find(".Ldt-CreateAnnotation-Description").bind("change keyup input paste",this.functionWrapper("onDescriptionChange")),this.show_title_field&&this.$.find(".Ldt-CreateAnnotation-Title").bind("change keyup input paste",this.functionWrapper("onTitleChange")),this.show_creator_field&&this.$.find(".Ldt-CreateAnnotation-Creator").bind("change keyup input paste",this.functionWrapper("onCreatorChange")),this.$.find("[class^='Ldt-CreateAnnotation-Control-']").click(function(){var o=this.className.replace("Ldt-CreateAnnotation-Control-","");switch(o){case"In":this.setBegin(n.media.getCurrentTime());break;case"Out":this.setEnd(n.media.getCurrentTime()||n.media.duration);break;case"Play":this.media.setCurrentTime(n.begin),this.media.play();break}return!1}),this.start_visible?this.show():(this.$.hide(),this.hide()),this.onMdpEvent("CreateAnnotation.toggle","toggle"),this.onMdpEvent("CreateAnnotation.hide","hide"),this.onMdpEvent("CreateAnnotation.show","show"),this.$.find("form").submit(this.functionWrapper("onSubmit"))}setBegin(n){this.begin=new t.Model.Time(n||0),this.$.find(".Ldt-CreateAnnotation-Begin").html(this.begin.toString())}setEnd(n){this.end=new t.Model.Time(n||0),this.$.find(".Ldt-CreateAnnotation-End").html(this.end.toString())}setBeginEnd(n,o){this.setBegin(n),this.setEnd(o)}showScreen(n){this.$.find(".Ldt-CreateAnnotation-"+n).show().siblings().hide()}show(){this.visible||(this.visible=!0,this.pause_when_displaying&&this.media.pause(),this.showScreen("Main"),this.$.find(".Ldt-CreateAnnotation-Description").val("").css("border-color","#666666").addClass("empty"),this.show_title_field&&this.$.find(".Ldt-CreateAnnotation-Title").val("").css("border-color","#666666").addClass("empty"),this.show_creator_field&&(this.$.find(".Ldt-CreateAnnotation-Creator").val(this.creator_name).css("border-color","#666666"),this.creator_name||this.$.find(".Ldt-CreateAnnotation-Creator").addClass("empty")),this.$.find(".Ldt-CreateAnnotation-TagLi, .Ldt-CreateAnnotation-PolemicLi").removeClass("selected"),this.$.slideDown(),this.minimize_annotation_widget&&this.player.trigger("Annotation.minimize"))}hide(){this.visible&&(this.always_visible||(this.visible=!1,this.$.slideUp(),this.minimize_annotation_widget&&this.player.trigger("Annotation.maximize")))}toggle(){if(!this.always_visible)if(this.visible)this.hide();else{var n=this.media.getCurrentTime()||0;this.setBeginEnd(n,n),this.slice_widget&&this.slice_widget.setBounds(this.begin,this.end),this.show(),this.$.find(".Ldt-CreateAnnotation-Description").focus()}}addKeyword(n){var o=this.$.find(".Ldt-CreateAnnotation-Description"),u=t.Model.regexpFromTextOrArray(n),l=o.val();l=l.match(u)?l.replace(u,""):l+" "+n,o.val(l.replace(/\s{2,}/g," ").replace(/(^\s+|\s+$)/g,"")),this.onDescriptionChange()}pauseOnWrite(){this.pause_on_write&&!this.media.getPaused()&&this.media.pause()}onDescriptionChange(n){if(n!==void 0&&n.keyCode==13&&!n.shiftKey)return this.onSubmit(),!0;var o=this.$.find(".Ldt-CreateAnnotation-Description"),u=o.val();return o.css("border-color",u?"#666666":"#ff0000"),u?o.removeClass("empty"):o.addClass("empty"),this.$.find(".Ldt-CreateAnnotation-TagLi, .Ldt-CreateAnnotation-PolemicLi").each(function(){var l=t.Model.regexpFromTextOrArray(jQuery(this).attr("data-text"));u.match(l)?jQuery(this).addClass("selected"):jQuery(this).removeClass("selected")}),this.pauseOnWrite(),!!u}onTitleChange(){var n=this.$.find(".Ldt-CreateAnnotation-Title"),o=n.val();return n.css("border-color",o?"#666666":"#ff0000"),o?n.removeClass("empty"):n.addClass("empty"),this.pauseOnWrite(),!!o}onCreatorChange(){var n=this.$.find(".Ldt-CreateAnnotation-Creator"),o=n.val();return n.css("border-color",o?"#666666":"#ff0000"),o?n.removeClass("empty"):n.addClass("empty"),this.pauseOnWrite(),!!o}onSubmit(){if(!this.onDescriptionChange()||this.show_title_field&&!this.onTitleChange()||this.show_creator_field&&!this.onCreatorChange())return!1;var n=this,o=new t.Model.List(this.player.sourceManager),u=this.player.sourceManager.newLocalSource({serializer:t.serializers[this.api_serializer]}),l=this.player.sourceManager.newLocalSource({serializer:t.serializers.ldt_localstorage}),m=new t.Model.Annotation(!1,u),y=this.source.getAnnotationTypes().searchByTitle(this.annotation_type,!0),E=y.length?y[0]:new t.Model.AnnotationType(!1,u),C=mustache.render(this.api_endpoint_template,{id:this.source.projectId});if(y.length||(E.dont_send_id=!0,E.title=this.annotation_type),m.setMedia(this.source.currentMedia.id),this.post_at_segment_time){var k=this.media.getCurrentTime(),A=this.source.getAnnotationsByTypeTitle(this.segments_annotation_type),D=A.filter(function(R){return k>=R.begin&&k<=R.end});D.length==0?(m.setBegin(this.begin),m.setEnd(this.end)):(m.setBegin(D[0].begin),m.setEnd(D[0].end))}else m.setBeginEnd(this.begin,this.end);m.setAnnotationType(E.id),this.show_title_field&&(m.title=this.$.find(".Ldt-CreateAnnotation-Title").val()),this.project_id!=""&&(m.project_id=this.project_id),m.created=new Date,m.description=this.$.find(".Ldt-CreateAnnotation-Description").val();var P=Array.prototype.map.call(this.$.find(".Ldt-CreateAnnotation-TagLi.selected"),function(R){return jQuery(R).attr("tag-id")});if(_$1(m.description.match(/#[^\s#.,;]+/g)).each(function(R){var B,F=R.replace(/^#/,""),j=n.source.getTags().searchByTitle(F,!0);j.length?B=j[0]:(B=new t.Model.Tag(!1,n.source),n.source.getTags().push(B),B.title=F),P.indexOf(B.id)===-1&&P.push(B.id)}),m.setTags(_$1(P).uniq()),this.audio_url&&(m.audio={src:"mic",mimetype:"audio/mp3",href:this.audio_url}),this.show_creator_field?m.creator=this.$.find(".Ldt-CreateAnnotation-Creator").val():m.creator=this.creator_name,o.push(m),this.editable_storage!=""&&(l.addList("annotation",o),n.source.merge(l),window.localStorage[this.editable_storage]&&l.deSerialize(window.localStorage[this.editable_storage]),window.localStorage[n.editable_storage]=l.serialize(),n.player.trigger("AnnotationsList.refresh"),n.player.trigger("Annotation.create",m),n.$.find(".Ldt-CreateAnnotation-Description").val("")),C!==""){o.push(m),u.addList("annotation",o);var n=this;jQuery.ajax({url:C,type:this.api_method,contentType:"application/json",data:u.serialize(),success:function(B){n.showScreen("Saved"),n.after_send_timeout&&window.setTimeout(function(){n.close_after_send?n.player.trigger("CreateAnnotation.hide"):n.player.trigger("CreateAnnotation.show")},n.after_send_timeout),u.getAnnotations().removeElement(m,!0),u.deSerialize(B),n.source.merge(u),n.pause_on_write&&n.media.getPaused()&&n.media.play(),n.player.trigger("AnnotationsList.refresh")},error:function(B,F,j){t.log("Error when sending annotation",j),u.getAnnotations().removeElement(m,!0),n.showScreen("Error"),window.setTimeout(function(){n.showScreen("Main")},n.after_send_timeout||5e3)}}),this.showScreen("Wait")}return!1}},Fi(e,"defaults",{show_title_field:!0,show_creator_field:!0,creator_field_readonly:!1,start_visible:!0,always_visible:!1,show_slice:!0,show_arrow:!0,show_time:!0,minimize_annotation_widget:!0,creator_name:"",creator_avatar:"",tags:!1,tag_titles:!1,pause_on_write:!0,max_tags:8,polemics:[{keyword:"++",background_color:"#00a000",text_color:"#ffffff"},{keyword:"--",background_color:"#c00000",text_color:"#ffffff"},{keyword:"??",background_color:"#0000e0",text_color:"#ffffff"},{keyword:"==",background_color:"#f0e000",text_color:"#000000"}],slice_annotation_type:"chap",annotation_type:"Contributions",post_at_segment_time:!1,segment_annotation_type:"chap",api_serializer:"ldt_annotate",api_endpoint_template:"",api_method:"POST",editable_storage:"",project_id:"",after_send_timeout:0,close_after_send:!1,tag_prefix:"#",pause_when_displaying:!1,custom_send_button:!1,custom_cancel_button:!1,custom_description_placeholder:!1,preview_mode:!1}),Fi(e,"messages",{en:{from_time:"from",to_time:"to",at_time:"at",submit:"Submit",preview_submit:"You cannot submit annotations in preview mode",cancel:"Cancel",add_keywords_:"Add keywords:",add_polemic_keywords_:"Add polemic attributes :",your_name_:"Your name:",annotate_video:"New note",type_title:"Annotation title",type_description:"Enter a new note...",wait_while_processing:"Please wait while your annotation is being processed...",error_while_contacting:"An error happened while contacting the server. Your annotation has not been saved.",annotation_saved:"Thank you, your annotation has been saved.",share_annotation:"Would you like to share it on social networks ?",close_widget:"Hide the annotation form","polemic++":"Agree","polemic--":"Disagree","polemic??":"Question","polemic==":"Reference",in_tooltip:"Set begin time to current player time",out_tooltip:"Set begin time to current player time",play_tooltip:"Play the fragment"},fr:{from_time:"de",to_time:"à",at_time:"à",submit:"Envoyer",preview_submit:"Vous ne pouvez pas envoyer d'annotation en mode aperçu",cancel:"Annuler",add_keywords_:"Ajouter des mots-clés :",add_polemic_keywords_:"Ajouter des attributs polémiques :",your_name_:"Votre nom :",annotate_video:"Entrez une nouvelle note...",type_title:"Titre de l'annotation",type_description:"Prenez vos notes...",wait_while_processing:"Veuillez patienter pendant le traitement de votre annotation...",error_while_contacting:"Une erreur s'est produite en contactant le serveur. Votre annotation n'a pas été enregistrée.",annotation_saved:"Merci, votre annotation a été enregistrée.",share_annotation:"Souhaitez-vous la partager sur les réseaux sociaux ?",close_widget:"Cacher le formulaire de création d'annotations","polemic++":"Accord","polemic--":"Désaccord","polemic??":"Question","polemic==":"Référence",in_tooltip:"Utiliser le temps courant comme début",out_tooltip:"Utiliser le temps courant comme fin",play_tooltip:"Jouer le fragment"}}),Fi(e,"template",'{{#show_slice}}<div class="Ldt-CreateAnnotation-Slice Ldt-TraceMe"></div>{{/show_slice}}{{^show_slice}}{{#show_arrow}}<div class="Ldt-CreateAnnotation-Arrow"></div>{{/show_arrow}}{{/show_slice}}<div class="Ldt-CreateAnnotation"><div class="Ldt-CreateAnnotation-Inner"><form class="Ldt-CreateAnnotation-Screen Ldt-CreateAnnotation-Main"><h3><span class="Ldt-CreateAnnotation-h3Left">{{l10n.annotate_video}}{{#show_title_field}}</span></h3><h3><span class="Ldt-CreateAnnotation-h3Left"><input class="Ldt-CreateAnnotation-Title empty" placeholder="{{l10n.type_title}}" />{{/show_title_field}}{{#show_time}}<span class="Ldt-CreateAnnotation-Times"> {{#show_slice}}{{l10n.from_time}} {{/show_slice}}{{^show_slice}}{{l10n.at_time}} {{/show_slice}} <span class="Ldt-CreateAnnotation-Begin">00:00</span>{{/show_time}}{{#show_slice}} {{l10n.to_time}} <span class="Ldt-CreateAnnotation-End">{{end}}</span>{{/show_slice}}</span></span>{{#show_creator_field}}{{l10n.your_name_}} <input class="Ldt-CreateAnnotation-Creator empty" value="{{creator_name}}" {{#creator_field_readonly}}readonly{{/creator_field_readonly}}/>{{/show_creator_field}}</h3>{{#show_controls}}<div class="Ldt-CreateAnnotation-Controls"><span title="{{l10n.in_tooltip}}" class="Ldt-CreateAnnotation-Control-In">In</span><span title="{{l10n.out_tooltip}}" class="Ldt-CreateAnnotation-Control-Out">Out</span><span title="{{l10n.play_tooltip}}" class="Ldt-CreateAnnotation-Control-Play">Play</span></div>{{/show_controls}}<textarea class="Ldt-CreateAnnotation-Description Ldt-TraceMe empty" placeholder="{{#custom_description_placeholder}}{{custom_description_placeholder}}{{/custom_description_placeholder}}{{^custom_description_placeholder}}{{l10n.type_description}}{{/custom_description_placeholder}}"></textarea>{{#show_creator_field}}<div class="Ldt-CreateAnnotation-Avatar"><img src="{{creator_avatar}}" title="{{creator_name}}"></img></div>{{/show_creator_field}}<div class="Ldt-CreateAnnotation-SubmitArea Ldt-TraceMe">{{#preview_mode}}<input type="button" class="Ldt-CreateAnnotation-PreviewSubmit" title="{{l10n.preview_submit}}" value="{{#custom_send_button}}{{custom_send_button}}{{/custom_send_button}}{{^custom_send_button}}{{l10n.submit}}{{/custom_send_button}}" />{{/preview_mode}}{{^preview_mode}}<input type="submit" class="Ldt-CreateAnnotation-Submit" value="{{#custom_send_button}}{{custom_send_button}}{{/custom_send_button}}{{^custom_send_button}}{{l10n.submit}}{{/custom_send_button}}" />{{/preview_mode}}<input type="button" class="Ldt-CreateAnnotation-Cancel" value="{{#custom_cancel_button}}{{custom_cancel_button}}{{/custom_cancel_button}}{{^custom_cancel_button}}{{l10n.cancel}}{{/custom_cancel_button}}" /><div class="Ldt-CreateAnnotation-Begin Ldt-CreateAnnotation-Times">00:00</div></div>{{#tags.length}}<div class="Ldt-CreateAnnotation-Tags"><div class="Ldt-CreateAnnotation-TagTitle">{{l10n.add_keywords_}}</div><ul class="Ldt-CreateAnnotation-TagList">{{#tags}}<li class="Ldt-CreateAnnotation-TagLi" tag-id="{{id}}" data-text="{{tag_prefix}}{{title}}"><span class="Ldt-CreateAnnotation-TagButton">{{title}}</span></li>{{/tags}}</ul></div>{{/tags.length}}{{#polemics.length}}<div class="Ldt-CreateAnnotation-Polemics"><div class="Ldt-CreateAnnotation-PolemicTitle">{{l10n.add_polemic_keywords_}}</div><ul class="Ldt-CreateAnnotation-PolemicList">{{#polemics}}<li class="Ldt-CreateAnnotation-PolemicLi" style="background-color: {{background_color}}; color: {{text_color}}" data-text="{{keyword}}">{{keyword}}</li>{{/polemics}}</ul></div>{{/polemics.length}}<div style="clear: both;"></div></form><div class="Ldt-CreateAnnotation-Screen Ldt-CreateAnnotation-Wait"><div class="Ldt-CreateAnnotation-InnerBox">{{l10n.wait_while_processing}}</div></div><div class="Ldt-CreateAnnotation-Screen Ldt-CreateAnnotation-Error">{{^always_visible}}<a title="{{l10n.close_widget}}" class="Ldt-CreateAnnotation-Close" href="#"></a>{{/always_visible}}<div class="Ldt-CreateAnnotation-InnerBox">{{l10n.error_while_contacting}}</div></div><div class="Ldt-CreateAnnotation-Screen Ldt-CreateAnnotation-Saved">{{^always_visible}}<a title="{{l10n.close_widget}}" class="Ldt-CreateAnnotation-Close" href="#"></a>{{/always_visible}}<div class="Ldt-CreateAnnotation-InnerBox">{{l10n.annotation_saved}}</div></div></div></div>'),e},currentSegmentInfoboxStyles={},CurrentSegmentInfobox=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){var n=this;this.segments=this.getWidgetAnnotations(),this.renderTemplate(),this.currentSegment=!1,this.clearBox(),this.refresh(),this.onMediaEvent("timeupdate","refresh"),this.onMediaEvent("settimerange",function(o){var u=o[0],l=o[1],m=n.segments.filter(function(y){return y.begin.milliseconds==u.milliseconds&&y.end.milliseconds==l.milliseconds});m.length>0&&(n.$.toggleClass("editing",!1),n.currentSegment.id!=m[0].id&&(n.currentSegment=m[0],_data={editable_segments:n.editable_segments,edit:n.custom_edit_text?n.custom_edit_text:n.l10n.edit,title:n.currentSegment.title,description:n.currentSegment.description,description_placeholder:n.empty_description_placeholder,tags:n.currentSegment.getTagTexts()},n.$.html(mustache.render(n.template,_data)),n.editable_segments&&n.currentSegment&&n.$.find(".Ldt-CurrentSegmentInfobox").click(n.functionWrapper("enableEditMode"))))}),this.editable_segments&&this.currentSegment&&this.$.find(".Ldt-CurrentSegmentInfobox").click(n.functionWrapper("enableEditMode"))}enableEditMode(){this.currentSegment&&(_data={title:this.currentSegment.title,description:this.currentSegment.description,tags:this.currentSegment.getTagTexts(),submit:this.l10n.submit,cancel:this.l10n.cancel,headers:this.show_headers,tags_header:this.custom_tags_header?this.custom_tags_header:this.l10n.tags_header,fields_header:this.custom_fields_header?this.custom_fields_header:this.l10n.fields_header,new_tag:this.l10n.new_tag,delete_tag:this.l10n.delete_tag,new_tag_button:this.new_tag_button},this.$.toggleClass("editing",!0),this.$.html(mustache.render(this.editTemplate,_data)),this.$.find(".Ldt-CurrentSegmentInfobox-CancelButton").click(this.functionWrapper("disableEditMode")),this.new_tag_button?this.$.find(".Ldt-CurrentSegmentInfobox-CreateTagButton").click(this.functionWrapper("insertTagInput")):(this.$.find(".Ldt-CurrentSegmentInfobox-CreateTagInput").keypress(this.functionWrapper("insertTagInputKeypress")),this.$.find(".Ldt-CurrentSegmentInfobox-CreateTagInput-Add").click(this.functionWrapper("insertTagInputKeypress"))),this.$.find(".Ldt-CurrentSegmentInfobox-Tags-Li-DeleteTagButton").click(this.functionWrapper("deleteTagInput")),this.$.find(".Ldt-CurrentSegmentInfobox-SubmitButton").click(this.functionWrapper("onSubmit")))}disableEditMode(){this.currentSegment&&(_data={editable_segments:this.editable_segments,edit:this.custom_edit_text?this.custom_edit_text:this.l10n.edit,title:this.currentSegment.title,description:this.currentSegment.description,description_placeholder:this.empty_description_placeholder,tags:this.currentSegment.getTagTexts()},this.$.toggleClass("editing",!1),this.$.html(mustache.render(this.template,_data)),this.$.find(".Ldt-CurrentSegmentInfobox").click(this.functionWrapper("enableEditMode")))}insertTagInput(){!this.currentSegment.getTagTexts().length&&!this.$.find(".Ldt-CurrentSegmentInfobox-Tags-Ul").length&&this.$.find(".Ldt-CurrentSegmentInfobox-Tags").prepend('<ul class="Ldt-CurrentSegmentInfobox-Tags-Ul"></ul>'),this.$.find(".Ldt-CurrentSegmentInfobox-Tags-Ul").append('<li class="Ldt-CurrentSegmentInfobox-Tags-Li"><input type="text" class="Ldt-CurrentSegmentInfobox-Tags-Li-Input" value=""></input><div class="Ldt-CurrentSegmentInfobox-Tags-Li-DeleteTagButton">'+this.l10n.delete_tag+"</div></li>"),this.$.find(".Ldt-CurrentSegmentInfobox-Tags-Li-DeleteTagButton").click(this.functionWrapper("deleteTagInput"))}insertTagInputKeypress(n){var o=n.keyCode?n.keyCode:n.which;if(o=="13"||n.type=="click")return!this.currentSegment.getTagTexts().length&&!this.$.find(".Ldt-CurrentSegmentInfobox-Tags-Ul").length&&this.$.find(".Ldt-CurrentSegmentInfobox-Tags").prepend('<ul class="Ldt-CurrentSegmentInfobox-Tags-Ul"></ul>'),this.$.find(".Ldt-CurrentSegmentInfobox-Tags-Ul").append('<li class="Ldt-CurrentSegmentInfobox-Tags-Li"><input type="text" class="Ldt-CurrentSegmentInfobox-Tags-Li-Input" value="'+this.$.find(".Ldt-CurrentSegmentInfobox-CreateTagInput").val()+'"></input><div class="Ldt-CurrentSegmentInfobox-Tags-Li-DeleteTagButton">'+this.l10n.delete_tag+"</div></li>"),this.$.find(".Ldt-CurrentSegmentInfobox-Tags-Li-DeleteTagButton").click(this.functionWrapper("deleteTagInput")),this.$.find(".Ldt-CurrentSegmentInfobox-CreateTagInput").val(""),!1}deleteTagInput(n){jQuery(n.currentTarget).parent().remove()}onSubmit(){new_tags_titles=this.$.find(".Ldt-CurrentSegmentInfobox-Tags-Li-Input").map(function(){if(jQuery(this).val())return jQuery(this).val()}),new_title=this.$.find(".Ldt-CurrentSegmentInfobox-TitleInput").val(),new_description=this.$.find(".Ldt-CurrentSegmentInfobox-DescriptionInput").val();var n=this,o=new t.Model.List(this.player.sourceManager),u=this.player.sourceManager.newLocalSource({serializer:t.serializers[this.api_serializer]}),l=new t.Model.Annotation(this.currentSegment.id,u);l.setAnnotationType(this.currentSegment.getAnnotationType().id),l.setMedia(this.currentSegment.getMedia().id),l.setBegin(this.currentSegment.begin),l.setEnd(this.currentSegment.end),l.created=this.currentSegment.created,l.creator=this.currentSegment.creator,l.title=new_title,l.description=new_description;var m=_$1(new_tags_titles).map(function(y){var E=n.source.getTags(!0).searchByTitle(y,!0);if(E.length)var C=E[0];else C=new t.Model.Tag(y.replace(/\W/g,"_"),n.source),C.title=y,n.source.getTags().push(C);return C.id}).value();l.setTags(m),l.project_id=this.project_id,o.push(l),u.addList("annotation",o),_url=mustache.render(this.api_endpoint_template,{annotation_id:this.currentSegment.id}),t.jQuery.ajax({url:_url,type:this.api_method,contentType:"application/json",data:u.serialize(),success:function(y){u.getAnnotations().removeElement(l,!0),u.deSerialize(y),n.source.merge(u),n.segments.forEach(function(E){E.id==l.id&&n.segments.removeElement(E)}),n.segments.push(l),n.currentSegment=l,y={editable_segments:n.editable_segments,edit:n.custom_edit_text?n.custom_edit_text:n.l10n.edit,title:n.currentSegment.title,description:n.currentSegment.description,description_placeholder:n.empty_description_placeholder,tags:n.currentSegment.getTagTexts()},n.$.html(mustache.render(n.template,y)),n.editable_segments&&n.currentSegment&&n.$.find(".Ldt-CurrentSegmentInfobox").click(n.functionWrapper("enableEditMode")),n.$.toggleClass("editing",!1)},error:function(y,E,C){t.log("Error when sending annotation",C),u.getAnnotations().removeElement(l,!0)}})}refresh(){if(!this.media.getTimeRange()){var n=this.media.getCurrentTime(),o=this.segments.filter(function(u){return u.begin<=n&&u.end>=n});o.length>0?this.currentSegment.id!=o[0].id&&(this.currentSegment=o[0],_data={editable_segments:this.editable_segments,edit:this.custom_edit_text?this.custom_edit_text:this.l10n.edit,title:this.currentSegment.title,description:this.currentSegment.description,description_placeholder:this.empty_description_placeholder,tags:this.currentSegment.getTagTexts()},this.$.html(mustache.render(this.template,_data)),this.editable_segments&&this.currentSegment&&this.$.find(".Ldt-CurrentSegmentInfobox").click(this.functionWrapper("enableEditMode"))):(this.currentSegment=!1,this.clearBox())}}clearBox(){var n=this.l10n.empty;this.empty_message&&(n=this.empty_message),this.$.find(".Ldt-CurrentSegmentInfobox").html("<div class='Ldt-CurrentSegmentInfobox-Element Ldt-CurrentSegmentInfobox-NoSegment'>"+n+"</div>")}},Fi(e,"defaults",{annotation_type:"chap",editable_segments:!1,empty_message:!1,project_id:!1,api_serializer:"ldt_annotate",api_method:"PUT",api_endpoint_template:"",new_tag_button:!0,show_headers:!1,custom_edit_text:!1,empty_description_placeholder:!1}),Fi(e,"template",'<div class="Ldt-CurrentSegmentInfobox"><div class="Ldt-CurrentSegmentInfobox-SelectedSegment">{{#editable_segments}}<div class="Ldt-CurrentSegmentInfobox-EditButton">{{edit}}</div>{{/editable_segments}}<div class="Ldt-CurrentSegmentInfobox-Element Ldt-CurrentSegmentInfobox-Title">{{title}}</div><div class="Ldt-CurrentSegmentInfobox-Element Ldt-CurrentSegmentInfobox-Description">{{description}}</div>{{^description}}{{^tags.length}}{{#description_placeholder}}<div class="Ldt-CurrentSegmentInfobox-Element Ldt-CurrentSegmentInfobox-Description-placeholder">{{description_placeholder}}</div>{{/description_placeholder}}{{/tags.length}}{{/description}}<div class="Ldt-CurrentSegmentInfobox-Element Ldt-CurrentSegmentInfobox-Tags">{{#tags.length}}<ul class="Ldt-CurrentSegmentInfobox-Tags-Ul">{{#tags}}{{#.}}<li class="Ldt-CurrentSegmentInfobox-Tags-Li"><span>{{.}}</span></li>{{/.}}{{/tags}}</ul>{{/tags.length}}</div></div></div>'),Fi(e,"editTemplate",'<div class="Ldt-CurrentSegmentInfobox"><div class="Ldt-CurrentSegmentInfobox-SelectedSegment">{{#headers}}<div class="Ldt-CurrentSegmentInfobox-FieldsHeader">{{fields_header}}</div>{{/headers}}<input type="text" class="Ldt-CurrentSegmentInfobox-Element Ldt-CurrentSegmentInfobox-TitleInput Ldt-CurrentSegmentInfobox-Title" value="{{title}}"></input><textarea class="Ldt-CurrentSegmentInfobox-Element Ldt-CurrentSegmentInfobox-DescriptionInput Ldt-CurrentSegmentInfobox-Description">{{description}}</textarea><div class="Ldt-CurrentSegmentInfobox-Element Ldt-CurrentSegmentInfobox-Tags">{{#headers}}<div class="Ldt-CurrentSegmentInfobox-TagsHeader">{{tags_header}}</div>{{/headers}}{{#new_tag_button}}<div class="Ldt-CurrentSegmentInfobox-CreateTagButton">{{new_tag}}</div>{{/new_tag_button}}{{^new_tag_button}}<input class="Ldt-CurrentSegmentInfobox-CreateTagInput" placeholder="{{new_tag}}"></input><div class="Ldt-CurrentSegmentInfobox-CreateTagInput-Add">+</div>{{/new_tag_button}}<ul class="Ldt-CurrentSegmentInfobox-Tags-Ul">{{#tags}}{{#.}}<li class="Ldt-CurrentSegmentInfobox-Tags-Li"><input type="text" class="Ldt-CurrentSegmentInfobox-Tags-Li-Input" value="{{.}}"></input><div class="Ldt-CurrentSegmentInfobox-Tags-Li-DeleteTagButton">{{delete_tag}}</div></li>{{/.}}{{/tags}}</ul></div><div class="Ldt-CurrentSegmentInfobox-SubmitButton">{{submit}}</div><div class="Ldt-CurrentSegmentInfobox-CancelButton">{{cancel}}</div></div></div>'),Fi(e,"messages",{fr:{submit:"Soumettre",cancel:"Annuler",edit:"Editer",new_tag:"Nouveau tag",delete_tag:"Supprimer",fields_header:"Commentaire associé à ce segment",tags_header:"Mots-clés associés à ce segment",empty:"Le player vidéo ne lit actuellement aucun segment"},en:{submit:"Submit",cancel:"Cancel",edit:"Edit",new_tag:"New tag",delete_tag:"Delete tag",fields_header:"Current segment content",tags_header:"Current segment tags",empty:"The player currently doesn't read any segment"}}),e},DailymotionPlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(o,u){super(o,u);Fi(this,"draw",function(){typeof this.video>"u"&&(this.video=this.media.video),this.height=this.height||Math.floor(this.width/this.aspect_ratio);var o=this.media,u=null,l=this,m={pause:!0,apiready:!1,volume:0,time:0,duration:0},y=this.video.match(/www.dailymotion.com\/video\/(.+)/);y&&(u=y[1]);var E=mustache.render("{{ protocol }}//www.dailymotion.com/embed/video/{{ videoid }}",{protocol:document.location.protocol.search("http")==0?document.location.protocol:"http:",videoid:u}),C={api:"postMessage",chromeless:1,id:"dm_player",related:0,autoplay:1};l.$.html(mustache.render('<iframe id="{{ id }}" src="{{ player_url }}?{{ params }}" width="{{ width }}" height="{{ height }}" frameborder="0"></iframe>',{player_url:E,params:Object.keys(C).reduce(function(A,D){return A.push(D+"="+encodeURIComponent(C[D])),A},[]).join("&"),width:this.width,height:this.height,id:C.id}));function k(){var A=l.$.find("#"+C.id)[0].contentWindow,D=function(P,R){R!==void 0&&(P=P+"="+R),A.postMessage(P,"*")};o.getCurrentTime=function(){return m.time},o.getVolume=function(){return m.volume},o.getPaused=function(){return m.pause},o.getMuted=function(){return m.muted},o.setCurrentTime=function(P){D("seek",P/1e3)},o.setVolume=function(P){D("volume",P*100)},o.mute=function(){D("muted",1)},o.unmute=function(){D("muted",0)},o.play=function(){D("play")},o.pause=function(){D("pause")}}window.addEventListener("message",function(A){if(A.data.split!==void 0){var D=A.data.split("&").map(function(P){return P.split("=")}).reduce(function(P,R){return P[R[0]]=decodeURIComponent(R[1]),P},{});switch(D.event){case"apiready":m.apiready=!0,k();break;case"durationchange":D.duration.slice(-2)=="sc"&&(m.duration=1e3*Number(D.duration.slice(0,-2)),o.setDuration(m.duration));break;case"ended":m.pause=!0;break;case"loadedmetadata":o.trigger("loadedmetadata");break;case"pause":m.pause=!0,o.trigger("pause");break;case"play":m.pause=!1,o.trigger("play");break;case"seeked":m.time=new t.Model.Time(1e3*Number(D.time)),o.trigger("seeked");break;case"timeupdate":m.time=new t.Model.Time(1e3*Number(D.time)),o.trigger("timeupdate",m.time);break;case"volumechange":m.muted=D.muted=="true",m.volume=Number(D.volume)/100;break}}},!1)})}},Fi(e,"defaults",{aspect_ratio:14/9}),e},enrichedPlanStyles={},EnrichedPlan=function(t){var e;return e=class extends t.Widgets.Widget{constructor(o,u){super(o,u);Fi(this,"annotationTemplate",'<div title="{{ begin }} - {{ atitle }}" data-id="{{ id }}" data-timecode="{{begintc}}" class="Ldt-EnrichedPlan-SlideItem Ldt-EnrichedPlan-Note {{category}} {{filtered}}"><span class="Ldt-EnrichedPlan-Note-Text">{{{ text }}}</span> <span class="Ldt-EnrichedPlan-Note-Author">{{ author }}</span></div>')}draw(){var o=this;o.prefix="TODO";var u=this.getWidgetAnnotations().sortBy(function(C){return C.begin}),l=this.media.getAnnotations().filter(function(C){return C.getAnnotationType().title!=o.annotation_type}).sortBy(function(C){return C.begin});u.forEach(function(C){C.annotations=l.filter(function(k){return k.begin>=C.begin&&k.begin<=C.end})}),o.renderTemplate();var m=o.$.find(".Ldt-EnrichedPlan-Container"),y=o.$.find(".Ldt-EnrichedPlan-Content");function E(C){return C.title.indexOf("Anonyme")<0?"Own":"Other"}u.forEach(function(C){var k=mustache.render(o.slideTemplate,{id:C.id,atitle:t.textFieldHtml(C.title),level:C.content.level||1,begin:C.begin.toString(),begintc:C.begin.milliseconds,thumbnail:C.thumbnail,show_slides:o.show_slides,notes:C.annotations.map(function(D){return mustache.render(o.annotationTemplate,{id:D.id,text:t.textFieldHtml(D.description||D.title),author:D.creator,begin:D.begin.toString(),begintc:D.begin.milliseconds,atitle:D.title.slice(0,20),category:"Ldt-EnrichedPlan-Note-"+E(D),filtered:E(D)=="Own"&&!o.show_own_notes||E(D)=="Other"&&!o.show_other_notes||E(D)=="Teacher"&&!o.show_teacher_notes?"filtered_out":""})}).join(`
`)}),A=t.jQuery(k);y.append(A)}),m.on("click","[data-timecode]",function(){o.media.setCurrentTime(Number(this.dataset.timecode))}),m.on("click",".Ldt-EnrichedPlan-Control-Checkbox",function(){var C=_.first(_.filter(this.classList,function(k){return k!="Ldt-EnrichedPlan-Control-Checkbox"}));C!==void 0&&(jQuery(this).is(":checked")?y.find(".Ldt-EnrichedPlan-Slide ."+C).removeClass("filtered_out"):y.find(".Ldt-EnrichedPlan-Slide ."+C).addClass("filtered_out"))}),m.find(".Ldt-EnrichedPlan-Search-Input").on("search",function(){var C=jQuery(this).val().toLocaleLowerCase();C===""?y.find(".Ldt-EnrichedPlan-Note").removeClass("non_matching"):jQuery(".Ldt-EnrichedPlan-Note").each(function(){var k=jQuery(this);k.text().toLocaleLowerCase().indexOf(C)>-1?k.removeClass("non_matching"):k.addClass("non_matching")})})}},Fi(e,"defaults",{annotation_type:"Slides",annotation_types:[],show_controls:!0,show_slides:!0,show_teacher_notes:!0,show_other_notes:!0,show_own_notes:!0}),Fi(e,"template",'<div class="Ldt-EnrichedPlan-Container">{{#show_controls}}<form class="Ldt-EnrichedPlan-Controls"> <input id="{{prefix}}teacher_note_checkbox" class="Ldt-EnrichedPlan-Control-Checkbox Ldt-EnrichedPlan-Note-Teacher" {{#show_teacher_notes}}checked{{/show_teacher_notes}} type="checkbox"> <label for="{{prefix}}teacher_note_checkbox" class="Ldt-EnrichedPlan-Control-Label Ldt-EnrichedPlan-Note-Teacher">Notes Enseignant</label> <input id="{{prefix}}other_note_checkbox" class="Ldt-EnrichedPlan-Control-Checkbox Ldt-EnrichedPlan-Note-Other" {{#show_other_notes}}checked{{/show_other_notes}} type="checkbox"> <label for="{{prefix}}other_note_checkbox" class="Ldt-EnrichedPlan-Control-Label Ldt-EnrichedPlan-Note-Other">Notes Autres</label> <input id="{{prefix}}simplified_plan_checkbox" class="Ldt-EnrichedPlan-Control-Checkbox Ldt-EnrichedPlan-Note-Own" {{#show_own_notes}}checked{{/show_own_notes}} type="checkbox"> <label for="{{prefix}}simplified_plan_checkbox" class="Ldt-EnrichedPlan-Control-Label Ldt-EnrichedPlan-Note-Own">Notes perso.</label> <input id="{{prefix}}slide_display_checkbox" class="Ldt-EnrichedPlan-Control-Checkbox Ldt-EnrichedPlan-Slide-Display" {{#show_slides}}checked{{/show_slides}} type="checkbox"> <label for="{{prefix}}slide_display_checkbox" class="Ldt-EnrichedPlan-Control-Label Ldt-EnrichedPlan-Slide-Display">Diapo<br/>&nbsp;</label> <input class="Ldt-EnrichedPlan-Search-Input" type="search" incremental placeholder="Recherchez"/></form>{{/show_controls}}<div class="Ldt-EnrichedPlan-Content"></div></div>'),Fi(e,"slideTemplate",'<div data-id="{{ id }}" class="Ldt-EnrichedPlan-Slide">  <div class="Ldt-EnrichedPlan-SlideItem Ldt-EnrichedPlan-SlideTimecode">{{ begin }}</div>  <div data-timecode="{{begintc}}" class="Ldt-EnrichedPlan-SlideItem {{^show_slides}}filtered_out{{/show_slides}} Ldt-EnrichedPlan-SlideThumbnail Ldt-EnrichedPlan-Slide-Display"><img title="{{ begin }} - {{ atitle }}" src="{{ thumbnail }}"></div>  <div class="Ldt-EnrichedPlan-SlideContent">     <div data-timecode="{{begintc}}" class="Ldt-EnrichedPlan-SlideTitle Ldt-EnrichedPlan-SlideTitle{{ level }}">{{ atitle }}</div>     <div class="Ldt-EnrichedPlan-SlideNotes">{{{ notes }}}</div>  </div></div>'),e},highlighterStyles={},Highlighter=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o);var u=this;this.throttledRefresh=_$1.throttle(function(){console.log("highlighter Refresh"),u.update()},800)}update(){var n=this,o=n.media.getCurrentTime();return n.$.find(".Ldt-Highlighter-Annotation",document).toggleClass("currentAnnotation",function(){return this.dataset.media===n.media.id&&this.dataset.begin<=o&&o<this.dataset.end}),console.log(n.$.find(".currentAnnotation")),!1}draw(){for(var n=this,o=["timeupdate","seeked","loadedmetadata"],u=0;u<o.length;u++)n.onMediaEvent(o[u],n.throttledRefresh);n.throttledRefresh()}},Fi(e,"defaults",{}),e},HtmlMashupPlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){!this.height&&this.aspect_ratio&&(this.height=this.width/this.aspect_ratio,this.$.css("height",this.height)),this.background&&this.$.css("background",this.background);var n=this.media,o=this.$,u=this.width,l=this.height,m=this.url_transform;n.currentMedia=null,n.currentAnnotation=null,n.seeking=!1;var y,E,C=0,k;function A(){C>=n.duration&&(n.paused||(n.paused=!0,n.trigger("pause")),C=0);var P=n.getAnnotationAtTime(C);if(typeof P>"u"){n.currentMedia&&(n.currentMedia.pause(),n.paused||(n.paused=!0,n.trigger("pause")));return}n.currentAnnotation=P,y=n.currentAnnotation.annotation.begin.milliseconds,E=n.currentAnnotation.annotation.end.milliseconds,k=y-n.currentAnnotation.begin.milliseconds,n.currentMedia=n.currentAnnotation.getMedia(),n.getMedias().forEach(function(R){R!==n.currentMedia?(R.hide(),R.pause()):R.show()}),n.currentMedia.setCurrentTime(C+k),n.currentMedia.seeking=!0,n.paused||(n.currentMedia.play(),n.seeking=!0),n.trigger("timeupdate",new t.Model.Time(C))}n.getMedias().forEach(D),A(),n.trigger("loadedmetadata");function D(P){if(!P.has_player){P.has_player=!0;var R=P.video;typeof m=="function"&&(R=m(P.video));var B="video_"+P.id,F;P.show=function(){if(document.getElementById(B))return;P.loaded=!1,P.paused=!0;var Y=jQuery("<video>");if(Y.attr({id:B,width:u,height:l}).css({width:u,height:l}),typeof R=="string")Y.attr("src",R);else for(var J=0;J<R.length;J++){var ie=t.jQuery("<source>");ie.attr({src:R[J].src,type:R[J].type}),Y.append(ie)}o.append(Y),F=Y[0];function ue(){P.muted=F.muted,P.volume=F.volume}Y.on("loadedmetadata",function(){ue(),P.loaded=!0,P.trigger("loadedmetadata"),P.trigger("volumechange")}),Y.on("timeupdate",function(){P.trigger("timeupdate",new t.Model.Time(1e3*F.currentTime))}),Y.on("volumechange",function(){ue(),P.trigger("volumechange")}),Y.on("play",function(){P.trigger("play")}),Y.on("pause",function(){P.trigger("pause")}),Y.on("seeking",function(){P.trigger("seeking")}),Y.on("seeked",function(){P.trigger("seeked")})},P.hide=function(){F=void 0,o.find("#"+B).remove()};var j=void 0,N=void 0;P.on("setcurrenttime",function(Y){if(F&&F.readyState>=F.HAVE_METADATA)try{F.currentTime=Y/1e3,j=void 0}catch{j=Y}else j=Y}),P.on("setvolume",function(Y){F&&F.readyState>=F.HAVE_METADATA&&(P.volume=Y,F.volume=Y)}),P.on("setmuted",function(Y){F&&F.readyState>=F.HAVE_METADATA&&(P.muted=Y,F.muted=Y)}),P.on("setplay",function(){if(F&&F.readyState>=F.HAVE_METADATA)try{F.play(),N=void 0}catch{N=!0}else N=!0}),P.on("setpause",function(){if(F&&F.readyState>=F.HAVE_METADATA)try{F.pause(),N=void 0}catch{N=!1}else N=!1}),P.on("loadedmetadata",function(){typeof j<"u"&&P.setCurrentTime(j),typeof N<"u"&&(N?P.play():P.pause())}),P.on("play",function(){P===n.currentMedia&&n.trigger("play")}),P.on("pause",function(){P===n.currentMedia&&n.trigger("pause")}),P.on("timeupdate",function(Y){!n.paused&&P===n.currentMedia&&!P.seeking&&(Y<E?Y>=y?C=Y-k:(C=y-k,P.setCurrentTime(y)):(C=E-k,P.pause(),A()),n.trigger("timeupdate",new t.Model.Time(C)))}),P.on("seeked",function(){P.seeking=!1,P===n.currentMedia&&n.seeking&&(n.seeking=!1)}),P.on("volumechange",function(){n.muted=P.muted,n.volume=P.volume,n.trigger("volumechange")})}}n.on("setcurrenttime",function(P){C=P,A()}),n.on("setvolume",function(P){n.getMedias().forEach(function(R){R.setVolume(P)}),n.volume=P}),n.on("setmuted",function(P){n.getMedias().forEach(function(R){R.setMuted(P)}),n.muted=P}),n.on("setplay",function(){n.paused=!1,A()}),n.on("setpause",function(){n.paused=!0,n.currentMedia&&n.currentMedia.pause()}),n.on("loadedmetadata",function(){A()})}},Fi(e,"defaults",{aspect_ratio:14/9,background:"#333333"}),e},HtmlPlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){t.htmlPlayer(this.media,this.$,this)}},Fi(e,"defaults",{}),e},imageDisplayStyles={},ImageDisplay=function(t){var e;return e=class extends t.Widgets.Widget{constructor(o,u){super(o,u);Fi(this,"annotationTemplate","")}update(o){this.image.css("background-image","url("+o.thumbnail+")"),this.image.attr("title",t.textFieldHtml(o.title)+" - "+o.begin.toString())}draw(){var o=this.getWidgetAnnotations().sortBy(function(l){return l.begin}),u=this;u.renderTemplate(),u.image=u.$.find(".Ldt-ImageDisplay-Container"),u.$.find(".Ldt-ImageDisplay-Overlay-Left").on("click",function(){u.navigate(-1)}),u.$.find(".Ldt-ImageDisplay-Overlay-Right").on("click",function(){u.navigate(1)}),o.forEach(function(l){l.on("enter",function(){u.update(l)})}),o.length&&u.update(o[0])}},Fi(e,"defaults",{annotation_type:"Slides"}),Fi(e,"template",'<div class="Ldt-ImageDisplay-Container"><div class="Ldt-ImageDisplay-Overlay Ldt-ImageDisplay-Overlay-Left"></div><div class="Ldt-ImageDisplay-Overlay Ldt-ImageDisplay-Overlay-Right"></div></div>'),e};var hasOwn$1=Object.prototype.hasOwnProperty,toStr$4=Object.prototype.toString,defineProperty=Object.defineProperty,gOPD$2=Object.getOwnPropertyDescriptor,isArray$3=function(e){return typeof Array.isArray=="function"?Array.isArray(e):toStr$4.call(e)==="[object Array]"},isPlainObject=function(e){if(!e||toStr$4.call(e)!=="[object Object]")return!1;var n=hasOwn$1.call(e,"constructor"),o=e.constructor&&e.constructor.prototype&&hasOwn$1.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!n&&!o)return!1;var u;for(u in e);return typeof u>"u"||hasOwn$1.call(e,u)},setProperty=function(e,n){defineProperty&&n.name==="__proto__"?defineProperty(e,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):e[n.name]=n.newValue},getProperty=function(e,n){if(n==="__proto__")if(hasOwn$1.call(e,n)){if(gOPD$2)return gOPD$2(e,n).value}else return;return e[n]},extend$1=function t(){var e,n,o,u,l,m,y=arguments[0],E=1,C=arguments.length,k=!1;for(typeof y=="boolean"&&(k=y,y=arguments[1]||{},E=2),(y==null||typeof y!="object"&&typeof y!="function")&&(y={});E<C;++E)if(e=arguments[E],e!=null)for(n in e)o=getProperty(y,n),u=getProperty(e,n),y!==u&&(k&&u&&(isPlainObject(u)||(l=isArray$3(u)))?(l?(l=!1,m=o&&isArray$3(o)?o:[]):m=o&&isPlainObject(o)?o:{},setProperty(y,{name:n,newValue:t(k,m,u)})):typeof u<"u"&&setProperty(y,{name:n,newValue:u}));return y},cookies$1={},cookie={},empty=null;const empty$1=Object.freeze(Object.defineProperty({__proto__:null,default:empty},Symbol.toStringTag,{value:"Module"})),require$$1$5=getAugmentedNamespace(empty$1);var punycode$2={exports:{}};/*! https://mths.be/punycode v1.4.1 by @mathias */punycode$2.exports;var hasRequiredPunycode;function requirePunycode(){return hasRequiredPunycode||(hasRequiredPunycode=1,function(t,e){(function(n){var o=e&&!e.nodeType&&e,u=t&&!t.nodeType&&t,l=typeof commonjsGlobal$1=="object"&&commonjsGlobal$1;(l.global===l||l.window===l||l.self===l)&&(n=l);var m,y=2147483647,E=36,C=1,k=26,A=38,D=700,P=72,R=128,B="-",F=/^xn--/,j=/[^\x20-\x7E]/,N=/[\x2E\u3002\uFF0E\uFF61]/g,Y={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},J=E-C,ie=Math.floor,ue=String.fromCharCode,Q;function ce(h){throw new RangeError(Y[h])}function he(h,T){for(var M=h.length,O=[];M--;)O[M]=T(h[M]);return O}function ke(h,T){var M=h.split("@"),O="";M.length>1&&(O=M[0]+"@",h=M[1]),h=h.replace(N,".");var V=h.split("."),ee=he(V,T).join(".");return O+ee}function L(h){for(var T=[],M=0,O=h.length,V,ee;M<O;)V=h.charCodeAt(M++),V>=55296&&V<=56319&&M<O?(ee=h.charCodeAt(M++),(ee&64512)==56320?T.push(((V&1023)<<10)+(ee&1023)+65536):(T.push(V),M--)):T.push(V);return T}function d(h){return he(h,function(T){var M="";return T>65535&&(T-=65536,M+=ue(T>>>10&1023|55296),T=56320|T&1023),M+=ue(T),M}).join("")}function v(h){return h-48<10?h-22:h-65<26?h-65:h-97<26?h-97:E}function w(h,T){return h+22+75*(h<26)-((T!=0)<<5)}function c(h,T,M){var O=0;for(h=M?ie(h/D):h>>1,h+=ie(h/T);h>J*k>>1;O+=E)h=ie(h/J);return ie(O+(J+1)*h/(h+A))}function p(h){var T=[],M=h.length,O,V=0,ee=R,Z=P,U,z,ne,fe,me,de,je,lt,it;for(U=h.lastIndexOf(B),U<0&&(U=0),z=0;z<U;++z)h.charCodeAt(z)>=128&&ce("not-basic"),T.push(h.charCodeAt(z));for(ne=U>0?U+1:0;ne<M;){for(fe=V,me=1,de=E;ne>=M&&ce("invalid-input"),je=v(h.charCodeAt(ne++)),(je>=E||je>ie((y-V)/me))&&ce("overflow"),V+=je*me,lt=de<=Z?C:de>=Z+k?k:de-Z,!(je<lt);de+=E)it=E-lt,me>ie(y/it)&&ce("overflow"),me*=it;O=T.length+1,Z=c(V-fe,O,fe==0),ie(V/O)>y-ee&&ce("overflow"),ee+=ie(V/O),V%=O,T.splice(V++,0,ee)}return d(T)}function x(h){var T,M,O,V,ee,Z,U,z,ne,fe,me,de=[],je,lt,it,ot;for(h=L(h),je=h.length,T=R,M=0,ee=P,Z=0;Z<je;++Z)me=h[Z],me<128&&de.push(ue(me));for(O=V=de.length,V&&de.push(B);O<je;){for(U=y,Z=0;Z<je;++Z)me=h[Z],me>=T&&me<U&&(U=me);for(lt=O+1,U-T>ie((y-M)/lt)&&ce("overflow"),M+=(U-T)*lt,T=U,Z=0;Z<je;++Z)if(me=h[Z],me<T&&++M>y&&ce("overflow"),me==T){for(z=M,ne=E;fe=ne<=ee?C:ne>=ee+k?k:ne-ee,!(z<fe);ne+=E)ot=z-fe,it=E-fe,de.push(ue(w(fe+ot%it,0))),z=ie(ot/it);de.push(ue(w(z,0))),ee=c(M,lt,O==V),M=0,++O}++M,++T}return de.join("")}function S(h){return ke(h,function(T){return F.test(T)?p(T.slice(4).toLowerCase()):T})}function b(h){return ke(h,function(T){return j.test(T)?"xn--"+x(T):T})}if(m={version:"1.4.1",ucs2:{decode:L,encode:d},decode:p,encode:x,toASCII:b,toUnicode:S},o&&u)if(t.exports==o)u.exports=m;else for(Q in m)m.hasOwnProperty(Q)&&(o[Q]=m[Q]);else n.punycode=m})(commonjsGlobal$1)}(punycode$2,punycode$2.exports)),punycode$2.exports}var punycodeExports=requirePunycode();const require$$0$3=getDefaultExportFromCjs$1(punycodeExports);function hasOwnProperty$1(t,e){return Object.prototype.hasOwnProperty.call(t,e)}var decode$1=function(t,e,n,o){e=e||"&",n=n||"=";var u={};if(typeof t!="string"||t.length===0)return u;var l=/\+/g;t=t.split(e);var m=1e3;o&&typeof o.maxKeys=="number"&&(m=o.maxKeys);var y=t.length;m>0&&y>m&&(y=m);for(var E=0;E<y;++E){var C=t[E].replace(l,"%20"),k=C.indexOf(n),A,D,P,R;k>=0?(A=C.substr(0,k),D=C.substr(k+1)):(A=C,D=""),P=decodeURIComponent(A),R=decodeURIComponent(D),hasOwnProperty$1(u,P)?isArray$2(u[P])?u[P].push(R):u[P]=[u[P],R]:u[P]=R}return u},isArray$2=Array.isArray||function(t){return Object.prototype.toString.call(t)==="[object Array]"},stringifyPrimitive=function(t){switch(typeof t){case"string":return t;case"boolean":return t?"true":"false";case"number":return isFinite(t)?t:"";default:return""}},encode$1=function(t,e,n,o){return e=e||"&",n=n||"=",t===null&&(t=void 0),typeof t=="object"?map(objectKeys$1(t),function(u){var l=encodeURIComponent(stringifyPrimitive(u))+n;return isArray$1(t[u])?map(t[u],function(m){return l+encodeURIComponent(stringifyPrimitive(m))}).join(e):l+encodeURIComponent(stringifyPrimitive(t[u]))}).join(e):o?encodeURIComponent(stringifyPrimitive(o))+n+encodeURIComponent(stringifyPrimitive(t)):""},isArray$1=Array.isArray||function(t){return Object.prototype.toString.call(t)==="[object Array]"};function map(t,e){if(t.map)return t.map(e);for(var n=[],o=0;o<t.length;o++)n.push(e(t[o],o));return n}var objectKeys$1=Object.keys||function(t){var e=[];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.push(n);return e},stringify$1,parse$3,decode=parse$3=decode$1,encode=stringify$1=encode$1;function qsEscape(t){return encodeURIComponent(t)}function qsUnescape(t){return decodeURIComponent(t)}var api$2={decode,encode,parse:parse$3,stringify:stringify$1,escape:qsEscape,unescape:qsUnescape};const querystring$2=Object.freeze(Object.defineProperty({__proto__:null,decode,default:api$2,encode,escape:qsEscape,get parse(){return parse$3},get stringify(){return stringify$1},unescape:qsUnescape},Symbol.toStringTag,{value:"Module"}));var util$1$1={isString:function(t){return typeof t=="string"},isObject:function(t){return typeof t=="object"&&t!==null},isNull:function(t){return t===null},isNullOrUndefined:function(t){return t==null}},punycode$1=require$$0$3,util$7=util$1$1,parse$2=urlParse$1,resolve$1=urlResolve,resolveObject=urlResolveObject,format$1=urlFormat,Url_1=Url;function Url(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var protocolPattern=/^([a-z0-9.+-]+:)/i,portPattern=/:[0-9]*$/,simplePathPattern=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,delims=["<",">",'"',"`"," ","\r",`
`,"	"],unwise=["{","}","|","\\","^","`"].concat(delims),autoEscape=["'"].concat(unwise),nonHostChars=["%","/","?",";","#"].concat(autoEscape),hostEndingChars=["/","?","#"],hostnameMaxLen=255,hostnamePartPattern=/^[+a-z0-9A-Z_-]{0,63}$/,hostnamePartStart=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,unsafeProtocol={javascript:!0,"javascript:":!0},hostlessProtocol={javascript:!0,"javascript:":!0},slashedProtocol={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},querystring$1=api$2;function urlParse$1(t,e,n){if(t&&util$7.isObject(t)&&t instanceof Url)return t;var o=new Url;return o.parse(t,e,n),o}Url.prototype.parse=function(t,e,n){if(!util$7.isString(t))throw new TypeError("Parameter 'url' must be a string, not "+typeof t);var o=t.indexOf("?"),u=o!==-1&&o<t.indexOf("#")?"?":"#",l=t.split(u),m=/\\/g;l[0]=l[0].replace(m,"/"),t=l.join(u);var y=t;if(y=y.trim(),!n&&t.split("#").length===1){var E=simplePathPattern.exec(y);if(E)return this.path=y,this.href=y,this.pathname=E[1],E[2]?(this.search=E[2],e?this.query=querystring$1.parse(this.search.substr(1)):this.query=this.search.substr(1)):e&&(this.search="",this.query={}),this}var C=protocolPattern.exec(y);if(C){C=C[0];var k=C.toLowerCase();this.protocol=k,y=y.substr(C.length)}if(n||C||y.match(/^\/\/[^@\/]+@[^@\/]+/)){var A=y.substr(0,2)==="//";A&&!(C&&hostlessProtocol[C])&&(y=y.substr(2),this.slashes=!0)}if(!hostlessProtocol[C]&&(A||C&&!slashedProtocol[C])){for(var D=-1,P=0;P<hostEndingChars.length;P++){var R=y.indexOf(hostEndingChars[P]);R!==-1&&(D===-1||R<D)&&(D=R)}var B,F;D===-1?F=y.lastIndexOf("@"):F=y.lastIndexOf("@",D),F!==-1&&(B=y.slice(0,F),y=y.slice(F+1),this.auth=decodeURIComponent(B)),D=-1;for(var P=0;P<nonHostChars.length;P++){var R=y.indexOf(nonHostChars[P]);R!==-1&&(D===-1||R<D)&&(D=R)}D===-1&&(D=y.length),this.host=y.slice(0,D),y=y.slice(D),this.parseHost(),this.hostname=this.hostname||"";var j=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!j)for(var N=this.hostname.split(/\./),P=0,Y=N.length;P<Y;P++){var J=N[P];if(J&&!J.match(hostnamePartPattern)){for(var ie="",ue=0,Q=J.length;ue<Q;ue++)J.charCodeAt(ue)>127?ie+="x":ie+=J[ue];if(!ie.match(hostnamePartPattern)){var ce=N.slice(0,P),he=N.slice(P+1),ke=J.match(hostnamePartStart);ke&&(ce.push(ke[1]),he.unshift(ke[2])),he.length&&(y="/"+he.join(".")+y),this.hostname=ce.join(".");break}}}this.hostname.length>hostnameMaxLen?this.hostname="":this.hostname=this.hostname.toLowerCase(),j||(this.hostname=punycode$1.toASCII(this.hostname));var L=this.port?":"+this.port:"",d=this.hostname||"";this.host=d+L,this.href+=this.host,j&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),y[0]!=="/"&&(y="/"+y))}if(!unsafeProtocol[k])for(var P=0,Y=autoEscape.length;P<Y;P++){var v=autoEscape[P];if(y.indexOf(v)!==-1){var w=encodeURIComponent(v);w===v&&(w=escape(v)),y=y.split(v).join(w)}}var c=y.indexOf("#");c!==-1&&(this.hash=y.substr(c),y=y.slice(0,c));var p=y.indexOf("?");if(p!==-1?(this.search=y.substr(p),this.query=y.substr(p+1),e&&(this.query=querystring$1.parse(this.query)),y=y.slice(0,p)):e&&(this.search="",this.query={}),y&&(this.pathname=y),slashedProtocol[k]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var L=this.pathname||"",x=this.search||"";this.path=L+x}return this.href=this.format(),this};function urlFormat(t){return util$7.isString(t)&&(t=urlParse$1(t)),t instanceof Url?t.format():Url.prototype.format.call(t)}Url.prototype.format=function(){var t=this.auth||"";t&&(t=encodeURIComponent(t),t=t.replace(/%3A/i,":"),t+="@");var e=this.protocol||"",n=this.pathname||"",o=this.hash||"",u=!1,l="";this.host?u=t+this.host:this.hostname&&(u=t+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(u+=":"+this.port)),this.query&&util$7.isObject(this.query)&&Object.keys(this.query).length&&(l=querystring$1.stringify(this.query));var m=this.search||l&&"?"+l||"";return e&&e.substr(-1)!==":"&&(e+=":"),this.slashes||(!e||slashedProtocol[e])&&u!==!1?(u="//"+(u||""),n&&n.charAt(0)!=="/"&&(n="/"+n)):u||(u=""),o&&o.charAt(0)!=="#"&&(o="#"+o),m&&m.charAt(0)!=="?"&&(m="?"+m),n=n.replace(/[?#]/g,function(y){return encodeURIComponent(y)}),m=m.replace("#","%23"),e+u+n+m+o};function urlResolve(t,e){return urlParse$1(t,!1,!0).resolve(e)}Url.prototype.resolve=function(t){return this.resolveObject(urlParse$1(t,!1,!0)).format()};function urlResolveObject(t,e){return t?urlParse$1(t,!1,!0).resolveObject(e):e}Url.prototype.resolveObject=function(t){if(util$7.isString(t)){var e=new Url;e.parse(t,!1,!0),t=e}for(var n=new Url,o=Object.keys(this),u=0;u<o.length;u++){var l=o[u];n[l]=this[l]}if(n.hash=t.hash,t.href==="")return n.href=n.format(),n;if(t.slashes&&!t.protocol){for(var m=Object.keys(t),y=0;y<m.length;y++){var E=m[y];E!=="protocol"&&(n[E]=t[E])}return slashedProtocol[n.protocol]&&n.hostname&&!n.pathname&&(n.path=n.pathname="/"),n.href=n.format(),n}if(t.protocol&&t.protocol!==n.protocol){if(!slashedProtocol[t.protocol]){for(var C=Object.keys(t),k=0;k<C.length;k++){var A=C[k];n[A]=t[A]}return n.href=n.format(),n}if(n.protocol=t.protocol,!t.host&&!hostlessProtocol[t.protocol]){for(var Y=(t.pathname||"").split("/");Y.length&&!(t.host=Y.shift()););t.host||(t.host=""),t.hostname||(t.hostname=""),Y[0]!==""&&Y.unshift(""),Y.length<2&&Y.unshift(""),n.pathname=Y.join("/")}else n.pathname=t.pathname;if(n.search=t.search,n.query=t.query,n.host=t.host||"",n.auth=t.auth,n.hostname=t.hostname||t.host,n.port=t.port,n.pathname||n.search){var D=n.pathname||"",P=n.search||"";n.path=D+P}return n.slashes=n.slashes||t.slashes,n.href=n.format(),n}var R=n.pathname&&n.pathname.charAt(0)==="/",B=t.host||t.pathname&&t.pathname.charAt(0)==="/",F=B||R||n.host&&t.pathname,j=F,N=n.pathname&&n.pathname.split("/")||[],Y=t.pathname&&t.pathname.split("/")||[],J=n.protocol&&!slashedProtocol[n.protocol];if(J&&(n.hostname="",n.port=null,n.host&&(N[0]===""?N[0]=n.host:N.unshift(n.host)),n.host="",t.protocol&&(t.hostname=null,t.port=null,t.host&&(Y[0]===""?Y[0]=t.host:Y.unshift(t.host)),t.host=null),F=F&&(Y[0]===""||N[0]==="")),B)n.host=t.host||t.host===""?t.host:n.host,n.hostname=t.hostname||t.hostname===""?t.hostname:n.hostname,n.search=t.search,n.query=t.query,N=Y;else if(Y.length)N||(N=[]),N.pop(),N=N.concat(Y),n.search=t.search,n.query=t.query;else if(!util$7.isNullOrUndefined(t.search)){if(J){n.hostname=n.host=N.shift();var ie=n.host&&n.host.indexOf("@")>0?n.host.split("@"):!1;ie&&(n.auth=ie.shift(),n.host=n.hostname=ie.shift())}return n.search=t.search,n.query=t.query,(!util$7.isNull(n.pathname)||!util$7.isNull(n.search))&&(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.href=n.format(),n}if(!N.length)return n.pathname=null,n.search?n.path="/"+n.search:n.path=null,n.href=n.format(),n;for(var ue=N.slice(-1)[0],Q=(n.host||t.host||N.length>1)&&(ue==="."||ue==="..")||ue==="",ce=0,he=N.length;he>=0;he--)ue=N[he],ue==="."?N.splice(he,1):ue===".."?(N.splice(he,1),ce++):ce&&(N.splice(he,1),ce--);if(!F&&!j)for(;ce--;ce)N.unshift("..");F&&N[0]!==""&&(!N[0]||N[0].charAt(0)!=="/")&&N.unshift(""),Q&&N.join("/").substr(-1)!=="/"&&N.push("");var ke=N[0]===""||N[0]&&N[0].charAt(0)==="/";if(J){n.hostname=n.host=ke?"":N.length?N.shift():"";var ie=n.host&&n.host.indexOf("@")>0?n.host.split("@"):!1;ie&&(n.auth=ie.shift(),n.host=n.hostname=ie.shift())}return F=F||n.host&&N.length,F&&!ke&&N.unshift(""),N.length?n.pathname=N.join("/"):(n.pathname=null,n.path=null),(!util$7.isNull(n.pathname)||!util$7.isNull(n.search))&&(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.auth=t.auth||n.auth,n.slashes=n.slashes||t.slashes,n.href=n.format(),n},Url.prototype.parseHost=function(){var t=this.host,e=portPattern.exec(t);e&&(e=e[0],e!==":"&&(this.port=e.substr(1)),t=t.substr(0,t.length-e.length)),t&&(this.hostname=t)};function normalizeArray(t,e){for(var n=0,o=t.length-1;o>=0;o--){var u=t[o];u==="."?t.splice(o,1):u===".."?(t.splice(o,1),n++):n&&(t.splice(o,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}function resolve(){for(var t="",e=!1,n=arguments.length-1;n>=-1&&!e;n--){var o=n>=0?arguments[n]:"/";if(typeof o!="string")throw new TypeError("Arguments to path.resolve must be strings");if(!o)continue;t=o+"/"+t,e=o.charAt(0)==="/"}return t=normalizeArray(filter(t.split("/"),function(u){return!!u}),!e).join("/"),(e?"/":"")+t||"."}function filter(t,e){if(t.filter)return t.filter(e);for(var n=[],o=0;o<t.length;o++)e(t[o],o,t)&&n.push(t[o]);return n}var _globalThis=function(t){function e(){var o=this||self;return delete t.prototype.__magic__,o}if(typeof globalThis=="object")return globalThis;if(this)return e();t.defineProperty(t.prototype,"__magic__",{configurable:!0,get:e});var n=__magic__;return n}(Object),formatImport=format$1,parseImport=parse$2,resolveImport=resolve$1,UrlImport=Url_1,URL$1=_globalThis.URL,URLSearchParams=_globalThis.URLSearchParams,percentRegEx=/%/g,backslashRegEx=/\\/g,newlineRegEx=/\n/g,carriageReturnRegEx=/\r/g,tabRegEx=/\t/g,CHAR_FORWARD_SLASH=47;function isURLInstance(t){var e=t??null;return!!(e!==null&&(e!=null&&e.href)&&(e!=null&&e.origin))}function getPathFromURLPosix(t){if(t.hostname!=="")throw new TypeError('File URL host must be "localhost" or empty on browser');for(var e=t.pathname,n=0;n<e.length;n++)if(e[n]==="%"){var o=e.codePointAt(n+2)|32;if(e[n+1]==="2"&&o===102)throw new TypeError("File URL path must not include encoded / characters")}return decodeURIComponent(e)}function encodePathChars(t){return t.includes("%")&&(t=t.replace(percentRegEx,"%25")),t.includes("\\")&&(t=t.replace(backslashRegEx,"%5C")),t.includes(`
`)&&(t=t.replace(newlineRegEx,"%0A")),t.includes("\r")&&(t=t.replace(carriageReturnRegEx,"%0D")),t.includes("	")&&(t=t.replace(tabRegEx,"%09")),t}var domainToASCII=function(e){if(typeof e>"u")throw new TypeError('The "domain" argument must be specified');return new URL$1("http://"+e).hostname},domainToUnicode=function(e){if(typeof e>"u")throw new TypeError('The "domain" argument must be specified');return new URL$1("http://"+e).hostname},pathToFileURL=function(e){var n=new URL$1("file://"),o=resolve(e),u=e.charCodeAt(e.length-1);return u===CHAR_FORWARD_SLASH&&o[o.length-1]!=="/"&&(o+="/"),n.pathname=encodePathChars(o),n},fileURLToPath=function(e){if(!isURLInstance(e)&&typeof e!="string")throw new TypeError('The "path" argument must be of type string or an instance of URL. Received type '+typeof e+" ("+e+")");var n=new URL$1(e);if(n.protocol!=="file:")throw new TypeError("The URL must be of scheme file");return getPathFromURLPosix(n)},formatImportWithOverloads=function(e,n){var o,u,l;if(n===void 0&&(n={}),!(e instanceof URL$1))return formatImport(e);if(typeof n!="object"||n===null)throw new TypeError('The "options" argument must be of type object.');var m=(o=n.auth)!=null?o:!0,y=(u=n.fragment)!=null?u:!0,E=(l=n.search)!=null?l:!0,C=new URL$1(e.toString());return m||(C.username="",C.password=""),y||(C.hash=""),E||(C.search=""),C.toString()},api$1={format:formatImportWithOverloads,parse:parseImport,resolve:resolveImport,resolveObject,Url:UrlImport,URL:URL$1,URLSearchParams,domainToASCII,domainToUnicode,pathToFileURL,fileURLToPath};const url=Object.freeze(Object.defineProperty({__proto__:null,URL:URL$1,URLSearchParams,Url:UrlImport,default:api$1,domainToASCII,domainToUnicode,fileURLToPath,format:formatImportWithOverloads,parse:parseImport,pathToFileURL,resolve:resolveImport,resolveObject},Symbol.toStringTag,{value:"Module"})),require$$2$2=getAugmentedNamespace(url);var util$6={},types$1={},shams$1=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},n=Symbol("test"),o=Object(n);if(typeof n=="string"||Object.prototype.toString.call(n)!=="[object Symbol]"||Object.prototype.toString.call(o)!=="[object Symbol]")return!1;var u=42;e[n]=u;for(n in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var l=Object.getOwnPropertySymbols(e);if(l.length!==1||l[0]!==n||!Object.prototype.propertyIsEnumerable.call(e,n))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var m=Object.getOwnPropertyDescriptor(e,n);if(m.value!==u||m.enumerable!==!0)return!1}return!0},hasSymbols$2=shams$1,shams=function(){return hasSymbols$2()&&!!Symbol.toStringTag},esErrors=Error,_eval=EvalError,range=RangeError,ref$1=ReferenceError,syntax=SyntaxError,type$j=TypeError,uri=URIError,origSymbol=typeof Symbol<"u"&&Symbol,hasSymbolSham=shams$1,hasSymbols$1=function(){return typeof origSymbol!="function"||typeof Symbol!="function"||typeof origSymbol("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:hasSymbolSham()},test={__proto__:null,foo:{}},$Object=Object,hasProto$1=function(){return{__proto__:test}.foo===test.foo&&!(test instanceof $Object)},ERROR_MESSAGE="Function.prototype.bind called on incompatible ",toStr$3=Object.prototype.toString,max=Math.max,funcType="[object Function]",concatty=function(e,n){for(var o=[],u=0;u<e.length;u+=1)o[u]=e[u];for(var l=0;l<n.length;l+=1)o[l+e.length]=n[l];return o},slicy=function(e,n){for(var o=[],u=n,l=0;u<e.length;u+=1,l+=1)o[l]=e[u];return o},joiny=function(t,e){for(var n="",o=0;o<t.length;o+=1)n+=t[o],o+1<t.length&&(n+=e);return n},implementation$5=function(e){var n=this;if(typeof n!="function"||toStr$3.apply(n)!==funcType)throw new TypeError(ERROR_MESSAGE+n);for(var o=slicy(arguments,1),u,l=function(){if(this instanceof u){var k=n.apply(this,concatty(o,arguments));return Object(k)===k?k:this}return n.apply(e,concatty(o,arguments))},m=max(0,n.length-o.length),y=[],E=0;E<m;E++)y[E]="$"+E;if(u=Function("binder","return function ("+joiny(y,",")+"){ return binder.apply(this,arguments); }")(l),n.prototype){var C=function(){};C.prototype=n.prototype,u.prototype=new C,C.prototype=null}return u},implementation$4=implementation$5,functionBind=Function.prototype.bind||implementation$4,call=Function.prototype.call,$hasOwn=Object.prototype.hasOwnProperty,bind$1=functionBind,hasown=bind$1.call(call,$hasOwn),undefined$1,$Error=esErrors,$EvalError=_eval,$RangeError=range,$ReferenceError=ref$1,$SyntaxError$1=syntax,$TypeError$2=type$j,$URIError=uri,$Function=Function,getEvalledConstructor=function(t){try{return $Function('"use strict"; return ('+t+").constructor;")()}catch{}},$gOPD$1=Object.getOwnPropertyDescriptor;if($gOPD$1)try{$gOPD$1({},"")}catch{$gOPD$1=null}var throwTypeError=function(){throw new $TypeError$2},ThrowTypeError=$gOPD$1?function(){try{return arguments.callee,throwTypeError}catch{try{return $gOPD$1(arguments,"callee").get}catch{return throwTypeError}}}():throwTypeError,hasSymbols=hasSymbols$1(),hasProto=hasProto$1(),getProto$1=Object.getPrototypeOf||(hasProto?function(t){return t.__proto__}:null),needsEval={},TypedArray=typeof Uint8Array>"u"||!getProto$1?undefined$1:getProto$1(Uint8Array),INTRINSICS={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?undefined$1:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?undefined$1:ArrayBuffer,"%ArrayIteratorPrototype%":hasSymbols&&getProto$1?getProto$1([][Symbol.iterator]()):undefined$1,"%AsyncFromSyncIteratorPrototype%":undefined$1,"%AsyncFunction%":needsEval,"%AsyncGenerator%":needsEval,"%AsyncGeneratorFunction%":needsEval,"%AsyncIteratorPrototype%":needsEval,"%Atomics%":typeof Atomics>"u"?undefined$1:Atomics,"%BigInt%":typeof BigInt>"u"?undefined$1:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?undefined$1:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?undefined$1:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?undefined$1:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":$Error,"%eval%":eval,"%EvalError%":$EvalError,"%Float32Array%":typeof Float32Array>"u"?undefined$1:Float32Array,"%Float64Array%":typeof Float64Array>"u"?undefined$1:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?undefined$1:FinalizationRegistry,"%Function%":$Function,"%GeneratorFunction%":needsEval,"%Int8Array%":typeof Int8Array>"u"?undefined$1:Int8Array,"%Int16Array%":typeof Int16Array>"u"?undefined$1:Int16Array,"%Int32Array%":typeof Int32Array>"u"?undefined$1:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":hasSymbols&&getProto$1?getProto$1(getProto$1([][Symbol.iterator]())):undefined$1,"%JSON%":typeof JSON=="object"?JSON:undefined$1,"%Map%":typeof Map>"u"?undefined$1:Map,"%MapIteratorPrototype%":typeof Map>"u"||!hasSymbols||!getProto$1?undefined$1:getProto$1(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?undefined$1:Promise,"%Proxy%":typeof Proxy>"u"?undefined$1:Proxy,"%RangeError%":$RangeError,"%ReferenceError%":$ReferenceError,"%Reflect%":typeof Reflect>"u"?undefined$1:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?undefined$1:Set,"%SetIteratorPrototype%":typeof Set>"u"||!hasSymbols||!getProto$1?undefined$1:getProto$1(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?undefined$1:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":hasSymbols&&getProto$1?getProto$1(""[Symbol.iterator]()):undefined$1,"%Symbol%":hasSymbols?Symbol:undefined$1,"%SyntaxError%":$SyntaxError$1,"%ThrowTypeError%":ThrowTypeError,"%TypedArray%":TypedArray,"%TypeError%":$TypeError$2,"%Uint8Array%":typeof Uint8Array>"u"?undefined$1:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?undefined$1:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?undefined$1:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?undefined$1:Uint32Array,"%URIError%":$URIError,"%WeakMap%":typeof WeakMap>"u"?undefined$1:WeakMap,"%WeakRef%":typeof WeakRef>"u"?undefined$1:WeakRef,"%WeakSet%":typeof WeakSet>"u"?undefined$1:WeakSet};if(getProto$1)try{null.error}catch(t){var errorProto=getProto$1(getProto$1(t));INTRINSICS["%Error.prototype%"]=errorProto}var doEval=function t(e){var n;if(e==="%AsyncFunction%")n=getEvalledConstructor("async function () {}");else if(e==="%GeneratorFunction%")n=getEvalledConstructor("function* () {}");else if(e==="%AsyncGeneratorFunction%")n=getEvalledConstructor("async function* () {}");else if(e==="%AsyncGenerator%"){var o=t("%AsyncGeneratorFunction%");o&&(n=o.prototype)}else if(e==="%AsyncIteratorPrototype%"){var u=t("%AsyncGenerator%");u&&getProto$1&&(n=getProto$1(u.prototype))}return INTRINSICS[e]=n,n},LEGACY_ALIASES={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},bind=functionBind,hasOwn=hasown,$concat=bind.call(Function.call,Array.prototype.concat),$spliceApply=bind.call(Function.apply,Array.prototype.splice),$replace=bind.call(Function.call,String.prototype.replace),$strSlice=bind.call(Function.call,String.prototype.slice),$exec=bind.call(Function.call,RegExp.prototype.exec),rePropName=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,reEscapeChar=/\\(\\)?/g,stringToPath=function(e){var n=$strSlice(e,0,1),o=$strSlice(e,-1);if(n==="%"&&o!=="%")throw new $SyntaxError$1("invalid intrinsic syntax, expected closing `%`");if(o==="%"&&n!=="%")throw new $SyntaxError$1("invalid intrinsic syntax, expected opening `%`");var u=[];return $replace(e,rePropName,function(l,m,y,E){u[u.length]=y?$replace(E,reEscapeChar,"$1"):m||l}),u},getBaseIntrinsic=function(e,n){var o=e,u;if(hasOwn(LEGACY_ALIASES,o)&&(u=LEGACY_ALIASES[o],o="%"+u[0]+"%"),hasOwn(INTRINSICS,o)){var l=INTRINSICS[o];if(l===needsEval&&(l=doEval(o)),typeof l>"u"&&!n)throw new $TypeError$2("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:u,name:o,value:l}}throw new $SyntaxError$1("intrinsic "+e+" does not exist!")},getIntrinsic=function(e,n){if(typeof e!="string"||e.length===0)throw new $TypeError$2("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof n!="boolean")throw new $TypeError$2('"allowMissing" argument must be a boolean');if($exec(/^%?[^%]*%?$/,e)===null)throw new $SyntaxError$1("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var o=stringToPath(e),u=o.length>0?o[0]:"",l=getBaseIntrinsic("%"+u+"%",n),m=l.name,y=l.value,E=!1,C=l.alias;C&&(u=C[0],$spliceApply(o,$concat([0,1],C)));for(var k=1,A=!0;k<o.length;k+=1){var D=o[k],P=$strSlice(D,0,1),R=$strSlice(D,-1);if((P==='"'||P==="'"||P==="`"||R==='"'||R==="'"||R==="`")&&P!==R)throw new $SyntaxError$1("property names with quotes must have matching quotes");if((D==="constructor"||!A)&&(E=!0),u+="."+D,m="%"+u+"%",hasOwn(INTRINSICS,m))y=INTRINSICS[m];else if(y!=null){if(!(D in y)){if(!n)throw new $TypeError$2("base intrinsic for "+e+" exists, but the property is not available.");return}if($gOPD$1&&k+1>=o.length){var B=$gOPD$1(y,D);A=!!B,A&&"get"in B&&!("originalValue"in B.get)?y=B.get:y=y[D]}else A=hasOwn(y,D),y=y[D];A&&!E&&(INTRINSICS[m]=y)}}return y},callBind$2={exports:{}},esDefineProperty,hasRequiredEsDefineProperty;function requireEsDefineProperty(){if(hasRequiredEsDefineProperty)return esDefineProperty;hasRequiredEsDefineProperty=1;var t=getIntrinsic,e=t("%Object.defineProperty%",!0)||!1;if(e)try{e({},"a",{value:1})}catch{e=!1}return esDefineProperty=e,esDefineProperty}var GetIntrinsic$2=getIntrinsic,$gOPD=GetIntrinsic$2("%Object.getOwnPropertyDescriptor%",!0);if($gOPD)try{$gOPD([],"length")}catch{$gOPD=null}var gopd$1=$gOPD,$defineProperty$1=requireEsDefineProperty(),$SyntaxError=syntax,$TypeError$1=type$j,gopd=gopd$1,defineDataProperty=function(e,n,o){if(!e||typeof e!="object"&&typeof e!="function")throw new $TypeError$1("`obj` must be an object or a function`");if(typeof n!="string"&&typeof n!="symbol")throw new $TypeError$1("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new $TypeError$1("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new $TypeError$1("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new $TypeError$1("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new $TypeError$1("`loose`, if provided, must be a boolean");var u=arguments.length>3?arguments[3]:null,l=arguments.length>4?arguments[4]:null,m=arguments.length>5?arguments[5]:null,y=arguments.length>6?arguments[6]:!1,E=!!gopd&&gopd(e,n);if($defineProperty$1)$defineProperty$1(e,n,{configurable:m===null&&E?E.configurable:!m,enumerable:u===null&&E?E.enumerable:!u,value:o,writable:l===null&&E?E.writable:!l});else if(y||!u&&!l&&!m)e[n]=o;else throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},$defineProperty=requireEsDefineProperty(),hasPropertyDescriptors=function(){return!!$defineProperty};hasPropertyDescriptors.hasArrayLengthDefineBug=function(){if(!$defineProperty)return null;try{return $defineProperty([],"length",{value:1}).length!==1}catch{return!0}};var hasPropertyDescriptors_1=hasPropertyDescriptors,GetIntrinsic$1=getIntrinsic,define$1=defineDataProperty,hasDescriptors=hasPropertyDescriptors_1(),gOPD$1=gopd$1,$TypeError=type$j,$floor=GetIntrinsic$1("%Math.floor%"),setFunctionLength=function(e,n){if(typeof e!="function")throw new $TypeError("`fn` is not a function");if(typeof n!="number"||n<0||n>4294967295||$floor(n)!==n)throw new $TypeError("`length` must be a positive 32-bit integer");var o=arguments.length>2&&!!arguments[2],u=!0,l=!0;if("length"in e&&gOPD$1){var m=gOPD$1(e,"length");m&&!m.configurable&&(u=!1),m&&!m.writable&&(l=!1)}return(u||l||!o)&&(hasDescriptors?define$1(e,"length",n,!0,!0):define$1(e,"length",n)),e};(function(t){var e=functionBind,n=getIntrinsic,o=setFunctionLength,u=type$j,l=n("%Function.prototype.apply%"),m=n("%Function.prototype.call%"),y=n("%Reflect.apply%",!0)||e.call(m,l),E=requireEsDefineProperty(),C=n("%Math.max%");t.exports=function(D){if(typeof D!="function")throw new u("a function is required");var P=y(e,m,arguments);return o(P,1+C(0,D.length-(arguments.length-1)),!0)};var k=function(){return y(e,l,arguments)};E?E(t.exports,"apply",{value:k}):t.exports.apply=k})(callBind$2);var callBindExports=callBind$2.exports,GetIntrinsic=getIntrinsic,callBind$1=callBindExports,$indexOf$1=callBind$1(GetIntrinsic("String.prototype.indexOf")),callBound$2=function(e,n){var o=GetIntrinsic(e,!!n);return typeof o=="function"&&$indexOf$1(e,".prototype.")>-1?callBind$1(o):o},hasToStringTag$3=shams(),callBound$1=callBound$2,$toString$1=callBound$1("Object.prototype.toString"),isStandardArguments=function(e){return hasToStringTag$3&&e&&typeof e=="object"&&Symbol.toStringTag in e?!1:$toString$1(e)==="[object Arguments]"},isLegacyArguments=function(e){return isStandardArguments(e)?!0:e!==null&&typeof e=="object"&&typeof e.length=="number"&&e.length>=0&&$toString$1(e)!=="[object Array]"&&$toString$1(e.callee)==="[object Function]"},supportsStandardArguments=function(){return isStandardArguments(arguments)}();isStandardArguments.isLegacyArguments=isLegacyArguments;var isArguments$1=supportsStandardArguments?isStandardArguments:isLegacyArguments,toStr$2=Object.prototype.toString,fnToStr$1=Function.prototype.toString,isFnRegex=/^\s*(?:function)?\*/,hasToStringTag$2=shams(),getProto=Object.getPrototypeOf,getGeneratorFunc=function(){if(!hasToStringTag$2)return!1;try{return Function("return function*() {}")()}catch{}},GeneratorFunction,isGeneratorFunction=function(e){if(typeof e!="function")return!1;if(isFnRegex.test(fnToStr$1.call(e)))return!0;if(!hasToStringTag$2){var n=toStr$2.call(e);return n==="[object GeneratorFunction]"}if(!getProto)return!1;if(typeof GeneratorFunction>"u"){var o=getGeneratorFunc();GeneratorFunction=o?getProto(o):!1}return getProto(e)===GeneratorFunction},fnToStr=Function.prototype.toString,reflectApply=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,badArrayLike,isCallableMarker;if(typeof reflectApply=="function"&&typeof Object.defineProperty=="function")try{badArrayLike=Object.defineProperty({},"length",{get:function(){throw isCallableMarker}}),isCallableMarker={},reflectApply(function(){throw 42},null,badArrayLike)}catch(t){t!==isCallableMarker&&(reflectApply=null)}else reflectApply=null;var constructorRegex=/^\s*class\b/,isES6ClassFn=function(e){try{var n=fnToStr.call(e);return constructorRegex.test(n)}catch{return!1}},tryFunctionObject=function(e){try{return isES6ClassFn(e)?!1:(fnToStr.call(e),!0)}catch{return!1}},toStr$1=Object.prototype.toString,objectClass="[object Object]",fnClass="[object Function]",genClass="[object GeneratorFunction]",ddaClass="[object HTMLAllCollection]",ddaClass2="[object HTML document.all class]",ddaClass3="[object HTMLCollection]",hasToStringTag$1=typeof Symbol=="function"&&!!Symbol.toStringTag,isIE68=!(0 in[,]),isDDA=function(){return!1};if(typeof document=="object"){var all=document.all;toStr$1.call(all)===toStr$1.call(document.all)&&(isDDA=function(e){if((isIE68||!e)&&(typeof e>"u"||typeof e=="object"))try{var n=toStr$1.call(e);return(n===ddaClass||n===ddaClass2||n===ddaClass3||n===objectClass)&&e("")==null}catch{}return!1})}var isCallable$1=reflectApply?function(e){if(isDDA(e))return!0;if(!e||typeof e!="function"&&typeof e!="object")return!1;try{reflectApply(e,null,badArrayLike)}catch(n){if(n!==isCallableMarker)return!1}return!isES6ClassFn(e)&&tryFunctionObject(e)}:function(e){if(isDDA(e))return!0;if(!e||typeof e!="function"&&typeof e!="object")return!1;if(hasToStringTag$1)return tryFunctionObject(e);if(isES6ClassFn(e))return!1;var n=toStr$1.call(e);return n!==fnClass&&n!==genClass&&!/^\[object HTML/.test(n)?!1:tryFunctionObject(e)},isCallable=isCallable$1,toStr=Object.prototype.toString,hasOwnProperty=Object.prototype.hasOwnProperty,forEachArray=function(e,n,o){for(var u=0,l=e.length;u<l;u++)hasOwnProperty.call(e,u)&&(o==null?n(e[u],u,e):n.call(o,e[u],u,e))},forEachString=function(e,n,o){for(var u=0,l=e.length;u<l;u++)o==null?n(e.charAt(u),u,e):n.call(o,e.charAt(u),u,e)},forEachObject=function(e,n,o){for(var u in e)hasOwnProperty.call(e,u)&&(o==null?n(e[u],u,e):n.call(o,e[u],u,e))},forEach$1=function(e,n,o){if(!isCallable(n))throw new TypeError("iterator must be a function");var u;arguments.length>=3&&(u=o),toStr.call(e)==="[object Array]"?forEachArray(e,n,u):typeof e=="string"?forEachString(e,n,u):forEachObject(e,n,u)},forEach_1=forEach$1,possibleTypedArrayNames=["Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"],possibleNames=possibleTypedArrayNames,g$1=typeof globalThis>"u"?commonjsGlobal$1:globalThis,availableTypedArrays$1=function(){for(var e=[],n=0;n<possibleNames.length;n++)typeof g$1[possibleNames[n]]=="function"&&(e[e.length]=possibleNames[n]);return e},forEach=forEach_1,availableTypedArrays=availableTypedArrays$1,callBind=callBindExports,callBound=callBound$2,gOPD=gopd$1,$toString=callBound("Object.prototype.toString"),hasToStringTag=shams(),g=typeof globalThis>"u"?commonjsGlobal$1:globalThis,typedArrays=availableTypedArrays(),$slice=callBound("String.prototype.slice"),getPrototypeOf=Object.getPrototypeOf,$indexOf=callBound("Array.prototype.indexOf",!0)||function(e,n){for(var o=0;o<e.length;o+=1)if(e[o]===n)return o;return-1},cache$1={__proto__:null};hasToStringTag&&gOPD&&getPrototypeOf?forEach(typedArrays,function(t){var e=new g[t];if(Symbol.toStringTag in e){var n=getPrototypeOf(e),o=gOPD(n,Symbol.toStringTag);if(!o){var u=getPrototypeOf(n);o=gOPD(u,Symbol.toStringTag)}cache$1["$"+t]=callBind(o.get)}}):forEach(typedArrays,function(t){var e=new g[t],n=e.slice||e.set;n&&(cache$1["$"+t]=callBind(n))});var tryTypedArrays=function(e){var n=!1;return forEach(cache$1,function(o,u){if(!n)try{"$"+o(e)===u&&(n=$slice(u,1))}catch{}}),n},trySlices=function(e){var n=!1;return forEach(cache$1,function(o,u){if(!n)try{o(e),n=$slice(u,1)}catch{}}),n},whichTypedArray$1=function(e){if(!e||typeof e!="object")return!1;if(!hasToStringTag){var n=$slice($toString(e),8,-1);return $indexOf(typedArrays,n)>-1?n:n!=="Object"?!1:trySlices(e)}return gOPD?tryTypedArrays(e):null},whichTypedArray=whichTypedArray$1,isTypedArray=function(e){return!!whichTypedArray(e)};(function(t){var e=isArguments$1,n=isGeneratorFunction,o=whichTypedArray$1,u=isTypedArray;function l(Je){return Je.call.bind(Je)}var m=typeof BigInt<"u",y=typeof Symbol<"u",E=l(Object.prototype.toString),C=l(Number.prototype.valueOf),k=l(String.prototype.valueOf),A=l(Boolean.prototype.valueOf);if(m)var D=l(BigInt.prototype.valueOf);if(y)var P=l(Symbol.prototype.valueOf);function R(Je,tt){if(typeof Je!="object")return!1;try{return tt(Je),!0}catch{return!1}}t.isArgumentsObject=e,t.isGeneratorFunction=n,t.isTypedArray=u;function B(Je){return typeof Promise<"u"&&Je instanceof Promise||Je!==null&&typeof Je=="object"&&typeof Je.then=="function"&&typeof Je.catch=="function"}t.isPromise=B;function F(Je){return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?ArrayBuffer.isView(Je):u(Je)||O(Je)}t.isArrayBufferView=F;function j(Je){return o(Je)==="Uint8Array"}t.isUint8Array=j;function N(Je){return o(Je)==="Uint8ClampedArray"}t.isUint8ClampedArray=N;function Y(Je){return o(Je)==="Uint16Array"}t.isUint16Array=Y;function J(Je){return o(Je)==="Uint32Array"}t.isUint32Array=J;function ie(Je){return o(Je)==="Int8Array"}t.isInt8Array=ie;function ue(Je){return o(Je)==="Int16Array"}t.isInt16Array=ue;function Q(Je){return o(Je)==="Int32Array"}t.isInt32Array=Q;function ce(Je){return o(Je)==="Float32Array"}t.isFloat32Array=ce;function he(Je){return o(Je)==="Float64Array"}t.isFloat64Array=he;function ke(Je){return o(Je)==="BigInt64Array"}t.isBigInt64Array=ke;function L(Je){return o(Je)==="BigUint64Array"}t.isBigUint64Array=L;function d(Je){return E(Je)==="[object Map]"}d.working=typeof Map<"u"&&d(new Map);function v(Je){return typeof Map>"u"?!1:d.working?d(Je):Je instanceof Map}t.isMap=v;function w(Je){return E(Je)==="[object Set]"}w.working=typeof Set<"u"&&w(new Set);function c(Je){return typeof Set>"u"?!1:w.working?w(Je):Je instanceof Set}t.isSet=c;function p(Je){return E(Je)==="[object WeakMap]"}p.working=typeof WeakMap<"u"&&p(new WeakMap);function x(Je){return typeof WeakMap>"u"?!1:p.working?p(Je):Je instanceof WeakMap}t.isWeakMap=x;function S(Je){return E(Je)==="[object WeakSet]"}S.working=typeof WeakSet<"u"&&S(new WeakSet);function b(Je){return S(Je)}t.isWeakSet=b;function h(Je){return E(Je)==="[object ArrayBuffer]"}h.working=typeof ArrayBuffer<"u"&&h(new ArrayBuffer);function T(Je){return typeof ArrayBuffer>"u"?!1:h.working?h(Je):Je instanceof ArrayBuffer}t.isArrayBuffer=T;function M(Je){return E(Je)==="[object DataView]"}M.working=typeof ArrayBuffer<"u"&&typeof DataView<"u"&&M(new DataView(new ArrayBuffer(1),0,1));function O(Je){return typeof DataView>"u"?!1:M.working?M(Je):Je instanceof DataView}t.isDataView=O;var V=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:void 0;function ee(Je){return E(Je)==="[object SharedArrayBuffer]"}function Z(Je){return typeof V>"u"?!1:(typeof ee.working>"u"&&(ee.working=ee(new V)),ee.working?ee(Je):Je instanceof V)}t.isSharedArrayBuffer=Z;function U(Je){return E(Je)==="[object AsyncFunction]"}t.isAsyncFunction=U;function z(Je){return E(Je)==="[object Map Iterator]"}t.isMapIterator=z;function ne(Je){return E(Je)==="[object Set Iterator]"}t.isSetIterator=ne;function fe(Je){return E(Je)==="[object Generator]"}t.isGeneratorObject=fe;function me(Je){return E(Je)==="[object WebAssembly.Module]"}t.isWebAssemblyCompiledModule=me;function de(Je){return R(Je,C)}t.isNumberObject=de;function je(Je){return R(Je,k)}t.isStringObject=je;function lt(Je){return R(Je,A)}t.isBooleanObject=lt;function it(Je){return m&&R(Je,D)}t.isBigIntObject=it;function ot(Je){return y&&R(Je,P)}t.isSymbolObject=ot;function Ct(Je){return de(Je)||je(Je)||lt(Je)||it(Je)||ot(Je)}t.isBoxedPrimitive=Ct;function nt(Je){return typeof Uint8Array<"u"&&(T(Je)||Z(Je))}t.isAnyArrayBuffer=nt,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(Je){Object.defineProperty(t,Je,{enumerable:!1,value:function(){throw new Error(Je+" is not supported in userland")}})})})(types$1);var isBufferBrowser=function(e){return e&&typeof e=="object"&&typeof e.copy=="function"&&typeof e.fill=="function"&&typeof e.readUInt8=="function"},inherits_browser={exports:{}};typeof Object.create=="function"?inherits_browser.exports=function(e,n){n&&(e.super_=n,e.prototype=Object.create(n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:inherits_browser.exports=function(e,n){if(n){e.super_=n;var o=function(){};o.prototype=n.prototype,e.prototype=new o,e.prototype.constructor=e}};var inherits_browserExports=inherits_browser.exports;(function(t){var e=Object.getOwnPropertyDescriptors||function(O){for(var V=Object.keys(O),ee={},Z=0;Z<V.length;Z++)ee[V[Z]]=Object.getOwnPropertyDescriptor(O,V[Z]);return ee},n=/%[sdj%]/g;t.format=function(M){if(!ie(M)){for(var O=[],V=0;V<arguments.length;V++)O.push(m(arguments[V]));return O.join(" ")}for(var V=1,ee=arguments,Z=ee.length,U=String(M).replace(n,function(ne){if(ne==="%%")return"%";if(V>=Z)return ne;switch(ne){case"%s":return String(ee[V++]);case"%d":return Number(ee[V++]);case"%j":try{return JSON.stringify(ee[V++])}catch{return"[Circular]"}default:return ne}}),z=ee[V];V<Z;z=ee[++V])N(z)||!he(z)?U+=" "+z:U+=" "+m(z);return U},t.deprecate=function(M,O){if(typeof process$1<"u"&&process$1.noDeprecation===!0)return M;if(typeof process$1>"u")return function(){return t.deprecate(M,O).apply(this,arguments)};var V=!1;function ee(){if(!V){if(process$1.throwDeprecation)throw new Error(O);process$1.traceDeprecation?console.trace(O):console.error(O),V=!0}return M.apply(this,arguments)}return ee};var o={},u=/^$/;if(process$1.env.NODE_DEBUG){var l=process$1.env.NODE_DEBUG;l=l.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),u=new RegExp("^"+l+"$","i")}t.debuglog=function(M){if(M=M.toUpperCase(),!o[M])if(u.test(M)){var O=process$1.pid;o[M]=function(){var V=t.format.apply(t,arguments);console.error("%s %d: %s",M,O,V)}}else o[M]=function(){};return o[M]};function m(M,O){var V={seen:[],stylize:E};return arguments.length>=3&&(V.depth=arguments[2]),arguments.length>=4&&(V.colors=arguments[3]),j(O)?V.showHidden=O:O&&t._extend(V,O),Q(V.showHidden)&&(V.showHidden=!1),Q(V.depth)&&(V.depth=2),Q(V.colors)&&(V.colors=!1),Q(V.customInspect)&&(V.customInspect=!0),V.colors&&(V.stylize=y),k(V,M,V.depth)}t.inspect=m,m.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},m.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function y(M,O){var V=m.styles[O];return V?"\x1B["+m.colors[V][0]+"m"+M+"\x1B["+m.colors[V][1]+"m":M}function E(M,O){return M}function C(M){var O={};return M.forEach(function(V,ee){O[V]=!0}),O}function k(M,O,V){if(M.customInspect&&O&&d(O.inspect)&&O.inspect!==t.inspect&&!(O.constructor&&O.constructor.prototype===O)){var ee=O.inspect(V,M);return ie(ee)||(ee=k(M,ee,V)),ee}var Z=A(M,O);if(Z)return Z;var U=Object.keys(O),z=C(U);if(M.showHidden&&(U=Object.getOwnPropertyNames(O)),L(O)&&(U.indexOf("message")>=0||U.indexOf("description")>=0))return D(O);if(U.length===0){if(d(O)){var ne=O.name?": "+O.name:"";return M.stylize("[Function"+ne+"]","special")}if(ce(O))return M.stylize(RegExp.prototype.toString.call(O),"regexp");if(ke(O))return M.stylize(Date.prototype.toString.call(O),"date");if(L(O))return D(O)}var fe="",me=!1,de=["{","}"];if(F(O)&&(me=!0,de=["[","]"]),d(O)){var je=O.name?": "+O.name:"";fe=" [Function"+je+"]"}if(ce(O)&&(fe=" "+RegExp.prototype.toString.call(O)),ke(O)&&(fe=" "+Date.prototype.toUTCString.call(O)),L(O)&&(fe=" "+D(O)),U.length===0&&(!me||O.length==0))return de[0]+fe+de[1];if(V<0)return ce(O)?M.stylize(RegExp.prototype.toString.call(O),"regexp"):M.stylize("[Object]","special");M.seen.push(O);var lt;return me?lt=P(M,O,V,z,U):lt=U.map(function(it){return R(M,O,V,z,it,me)}),M.seen.pop(),B(lt,fe,de)}function A(M,O){if(Q(O))return M.stylize("undefined","undefined");if(ie(O)){var V="'"+JSON.stringify(O).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return M.stylize(V,"string")}if(J(O))return M.stylize(""+O,"number");if(j(O))return M.stylize(""+O,"boolean");if(N(O))return M.stylize("null","null")}function D(M){return"["+Error.prototype.toString.call(M)+"]"}function P(M,O,V,ee,Z){for(var U=[],z=0,ne=O.length;z<ne;++z)S(O,String(z))?U.push(R(M,O,V,ee,String(z),!0)):U.push("");return Z.forEach(function(fe){fe.match(/^\d+$/)||U.push(R(M,O,V,ee,fe,!0))}),U}function R(M,O,V,ee,Z,U){var z,ne,fe;if(fe=Object.getOwnPropertyDescriptor(O,Z)||{value:O[Z]},fe.get?fe.set?ne=M.stylize("[Getter/Setter]","special"):ne=M.stylize("[Getter]","special"):fe.set&&(ne=M.stylize("[Setter]","special")),S(ee,Z)||(z="["+Z+"]"),ne||(M.seen.indexOf(fe.value)<0?(N(V)?ne=k(M,fe.value,null):ne=k(M,fe.value,V-1),ne.indexOf(`
`)>-1&&(U?ne=ne.split(`
`).map(function(me){return"  "+me}).join(`
`).slice(2):ne=`
`+ne.split(`
`).map(function(me){return"   "+me}).join(`
`))):ne=M.stylize("[Circular]","special")),Q(z)){if(U&&Z.match(/^\d+$/))return ne;z=JSON.stringify(""+Z),z.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(z=z.slice(1,-1),z=M.stylize(z,"name")):(z=z.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),z=M.stylize(z,"string"))}return z+": "+ne}function B(M,O,V){var ee=M.reduce(function(Z,U){return U.indexOf(`
`)>=0,Z+U.replace(/\u001b\[\d\d?m/g,"").length+1},0);return ee>60?V[0]+(O===""?"":O+`
 `)+" "+M.join(`,
  `)+" "+V[1]:V[0]+O+" "+M.join(", ")+" "+V[1]}t.types=types$1;function F(M){return Array.isArray(M)}t.isArray=F;function j(M){return typeof M=="boolean"}t.isBoolean=j;function N(M){return M===null}t.isNull=N;function Y(M){return M==null}t.isNullOrUndefined=Y;function J(M){return typeof M=="number"}t.isNumber=J;function ie(M){return typeof M=="string"}t.isString=ie;function ue(M){return typeof M=="symbol"}t.isSymbol=ue;function Q(M){return M===void 0}t.isUndefined=Q;function ce(M){return he(M)&&w(M)==="[object RegExp]"}t.isRegExp=ce,t.types.isRegExp=ce;function he(M){return typeof M=="object"&&M!==null}t.isObject=he;function ke(M){return he(M)&&w(M)==="[object Date]"}t.isDate=ke,t.types.isDate=ke;function L(M){return he(M)&&(w(M)==="[object Error]"||M instanceof Error)}t.isError=L,t.types.isNativeError=L;function d(M){return typeof M=="function"}t.isFunction=d;function v(M){return M===null||typeof M=="boolean"||typeof M=="number"||typeof M=="string"||typeof M=="symbol"||typeof M>"u"}t.isPrimitive=v,t.isBuffer=isBufferBrowser;function w(M){return Object.prototype.toString.call(M)}function c(M){return M<10?"0"+M.toString(10):M.toString(10)}var p=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function x(){var M=new Date,O=[c(M.getHours()),c(M.getMinutes()),c(M.getSeconds())].join(":");return[M.getDate(),p[M.getMonth()],O].join(" ")}t.log=function(){console.log("%s - %s",x(),t.format.apply(t,arguments))},t.inherits=inherits_browserExports,t._extend=function(M,O){if(!O||!he(O))return M;for(var V=Object.keys(O),ee=V.length;ee--;)M[V[ee]]=O[V[ee]];return M};function S(M,O){return Object.prototype.hasOwnProperty.call(M,O)}var b=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;t.promisify=function(O){if(typeof O!="function")throw new TypeError('The "original" argument must be of type Function');if(b&&O[b]){var V=O[b];if(typeof V!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(V,b,{value:V,enumerable:!1,writable:!1,configurable:!0}),V}function V(){for(var ee,Z,U=new Promise(function(fe,me){ee=fe,Z=me}),z=[],ne=0;ne<arguments.length;ne++)z.push(arguments[ne]);z.push(function(fe,me){fe?Z(fe):ee(me)});try{O.apply(this,z)}catch(fe){Z(fe)}return U}return Object.setPrototypeOf(V,Object.getPrototypeOf(O)),b&&Object.defineProperty(V,b,{value:V,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(V,e(O))},t.promisify.custom=b;function h(M,O){if(!M){var V=new Error("Promise was rejected with a falsy value");V.reason=M,M=V}return O(M)}function T(M){if(typeof M!="function")throw new TypeError('The "original" argument must be of type Function');function O(){for(var V=[],ee=0;ee<arguments.length;ee++)V.push(arguments[ee]);var Z=V.pop();if(typeof Z!="function")throw new TypeError("The last argument must be of type Function");var U=this,z=function(){return Z.apply(U,arguments)};M.apply(this,V).then(function(ne){process$1.nextTick(z.bind(null,null,ne))},function(ne){process$1.nextTick(h.bind(null,ne,z))})}return Object.setPrototypeOf(O,Object.getPrototypeOf(M)),Object.defineProperties(O,e(M)),O}t.callbackify=T})(util$6);var pubsuffixPsl={},psl$1={};const require$$1$4=["ac","com.ac","edu.ac","gov.ac","net.ac","mil.ac","org.ac","ad","nom.ad","ae","co.ae","net.ae","org.ae","sch.ae","ac.ae","gov.ae","mil.ae","aero","accident-investigation.aero","accident-prevention.aero","aerobatic.aero","aeroclub.aero","aerodrome.aero","agents.aero","aircraft.aero","airline.aero","airport.aero","air-surveillance.aero","airtraffic.aero","air-traffic-control.aero","ambulance.aero","amusement.aero","association.aero","author.aero","ballooning.aero","broker.aero","caa.aero","cargo.aero","catering.aero","certification.aero","championship.aero","charter.aero","civilaviation.aero","club.aero","conference.aero","consultant.aero","consulting.aero","control.aero","council.aero","crew.aero","design.aero","dgca.aero","educator.aero","emergency.aero","engine.aero","engineer.aero","entertainment.aero","equipment.aero","exchange.aero","express.aero","federation.aero","flight.aero","fuel.aero","gliding.aero","government.aero","groundhandling.aero","group.aero","hanggliding.aero","homebuilt.aero","insurance.aero","journal.aero","journalist.aero","leasing.aero","logistics.aero","magazine.aero","maintenance.aero","media.aero","microlight.aero","modelling.aero","navigation.aero","parachuting.aero","paragliding.aero","passenger-association.aero","pilot.aero","press.aero","production.aero","recreation.aero","repbody.aero","res.aero","research.aero","rotorcraft.aero","safety.aero","scientist.aero","services.aero","show.aero","skydiving.aero","software.aero","student.aero","trader.aero","trading.aero","trainer.aero","union.aero","workinggroup.aero","works.aero","af","gov.af","com.af","org.af","net.af","edu.af","ag","com.ag","org.ag","net.ag","co.ag","nom.ag","ai","off.ai","com.ai","net.ai","org.ai","al","com.al","edu.al","gov.al","mil.al","net.al","org.al","am","co.am","com.am","commune.am","net.am","org.am","ao","ed.ao","gv.ao","og.ao","co.ao","pb.ao","it.ao","aq","ar","bet.ar","com.ar","coop.ar","edu.ar","gob.ar","gov.ar","int.ar","mil.ar","musica.ar","mutual.ar","net.ar","org.ar","senasa.ar","tur.ar","arpa","e164.arpa","in-addr.arpa","ip6.arpa","iris.arpa","uri.arpa","urn.arpa","as","gov.as","asia","at","ac.at","co.at","gv.at","or.at","sth.ac.at","au","com.au","net.au","org.au","edu.au","gov.au","asn.au","id.au","info.au","conf.au","oz.au","act.au","nsw.au","nt.au","qld.au","sa.au","tas.au","vic.au","wa.au","act.edu.au","catholic.edu.au","nsw.edu.au","nt.edu.au","qld.edu.au","sa.edu.au","tas.edu.au","vic.edu.au","wa.edu.au","qld.gov.au","sa.gov.au","tas.gov.au","vic.gov.au","wa.gov.au","schools.nsw.edu.au","aw","com.aw","ax","az","com.az","net.az","int.az","gov.az","org.az","edu.az","info.az","pp.az","mil.az","name.az","pro.az","biz.az","ba","com.ba","edu.ba","gov.ba","mil.ba","net.ba","org.ba","bb","biz.bb","co.bb","com.bb","edu.bb","gov.bb","info.bb","net.bb","org.bb","store.bb","tv.bb","*.bd","be","ac.be","bf","gov.bf","bg","a.bg","b.bg","c.bg","d.bg","e.bg","f.bg","g.bg","h.bg","i.bg","j.bg","k.bg","l.bg","m.bg","n.bg","o.bg","p.bg","q.bg","r.bg","s.bg","t.bg","u.bg","v.bg","w.bg","x.bg","y.bg","z.bg","0.bg","1.bg","2.bg","3.bg","4.bg","5.bg","6.bg","7.bg","8.bg","9.bg","bh","com.bh","edu.bh","net.bh","org.bh","gov.bh","bi","co.bi","com.bi","edu.bi","or.bi","org.bi","biz","bj","asso.bj","barreau.bj","gouv.bj","bm","com.bm","edu.bm","gov.bm","net.bm","org.bm","bn","com.bn","edu.bn","gov.bn","net.bn","org.bn","bo","com.bo","edu.bo","gob.bo","int.bo","org.bo","net.bo","mil.bo","tv.bo","web.bo","academia.bo","agro.bo","arte.bo","blog.bo","bolivia.bo","ciencia.bo","cooperativa.bo","democracia.bo","deporte.bo","ecologia.bo","economia.bo","empresa.bo","indigena.bo","industria.bo","info.bo","medicina.bo","movimiento.bo","musica.bo","natural.bo","nombre.bo","noticias.bo","patria.bo","politica.bo","profesional.bo","plurinacional.bo","pueblo.bo","revista.bo","salud.bo","tecnologia.bo","tksat.bo","transporte.bo","wiki.bo","br","9guacu.br","abc.br","adm.br","adv.br","agr.br","aju.br","am.br","anani.br","aparecida.br","app.br","arq.br","art.br","ato.br","b.br","barueri.br","belem.br","bhz.br","bib.br","bio.br","blog.br","bmd.br","boavista.br","bsb.br","campinagrande.br","campinas.br","caxias.br","cim.br","cng.br","cnt.br","com.br","contagem.br","coop.br","coz.br","cri.br","cuiaba.br","curitiba.br","def.br","des.br","det.br","dev.br","ecn.br","eco.br","edu.br","emp.br","enf.br","eng.br","esp.br","etc.br","eti.br","far.br","feira.br","flog.br","floripa.br","fm.br","fnd.br","fortal.br","fot.br","foz.br","fst.br","g12.br","geo.br","ggf.br","goiania.br","gov.br","ac.gov.br","al.gov.br","am.gov.br","ap.gov.br","ba.gov.br","ce.gov.br","df.gov.br","es.gov.br","go.gov.br","ma.gov.br","mg.gov.br","ms.gov.br","mt.gov.br","pa.gov.br","pb.gov.br","pe.gov.br","pi.gov.br","pr.gov.br","rj.gov.br","rn.gov.br","ro.gov.br","rr.gov.br","rs.gov.br","sc.gov.br","se.gov.br","sp.gov.br","to.gov.br","gru.br","imb.br","ind.br","inf.br","jab.br","jampa.br","jdf.br","joinville.br","jor.br","jus.br","leg.br","lel.br","log.br","londrina.br","macapa.br","maceio.br","manaus.br","maringa.br","mat.br","med.br","mil.br","morena.br","mp.br","mus.br","natal.br","net.br","niteroi.br","*.nom.br","not.br","ntr.br","odo.br","ong.br","org.br","osasco.br","palmas.br","poa.br","ppg.br","pro.br","psc.br","psi.br","pvh.br","qsl.br","radio.br","rec.br","recife.br","rep.br","ribeirao.br","rio.br","riobranco.br","riopreto.br","salvador.br","sampa.br","santamaria.br","santoandre.br","saobernardo.br","saogonca.br","seg.br","sjc.br","slg.br","slz.br","sorocaba.br","srv.br","taxi.br","tc.br","tec.br","teo.br","the.br","tmp.br","trd.br","tur.br","tv.br","udi.br","vet.br","vix.br","vlog.br","wiki.br","zlg.br","bs","com.bs","net.bs","org.bs","edu.bs","gov.bs","bt","com.bt","edu.bt","gov.bt","net.bt","org.bt","bv","bw","co.bw","org.bw","by","gov.by","mil.by","com.by","of.by","bz","com.bz","net.bz","org.bz","edu.bz","gov.bz","ca","ab.ca","bc.ca","mb.ca","nb.ca","nf.ca","nl.ca","ns.ca","nt.ca","nu.ca","on.ca","pe.ca","qc.ca","sk.ca","yk.ca","gc.ca","cat","cc","cd","gov.cd","cf","cg","ch","ci","org.ci","or.ci","com.ci","co.ci","edu.ci","ed.ci","ac.ci","net.ci","go.ci","asso.ci","aéroport.ci","int.ci","presse.ci","md.ci","gouv.ci","*.ck","!www.ck","cl","co.cl","gob.cl","gov.cl","mil.cl","cm","co.cm","com.cm","gov.cm","net.cm","cn","ac.cn","com.cn","edu.cn","gov.cn","net.cn","org.cn","mil.cn","公司.cn","网络.cn","網絡.cn","ah.cn","bj.cn","cq.cn","fj.cn","gd.cn","gs.cn","gz.cn","gx.cn","ha.cn","hb.cn","he.cn","hi.cn","hl.cn","hn.cn","jl.cn","js.cn","jx.cn","ln.cn","nm.cn","nx.cn","qh.cn","sc.cn","sd.cn","sh.cn","sn.cn","sx.cn","tj.cn","xj.cn","xz.cn","yn.cn","zj.cn","hk.cn","mo.cn","tw.cn","co","arts.co","com.co","edu.co","firm.co","gov.co","info.co","int.co","mil.co","net.co","nom.co","org.co","rec.co","web.co","com","coop","cr","ac.cr","co.cr","ed.cr","fi.cr","go.cr","or.cr","sa.cr","cu","com.cu","edu.cu","org.cu","net.cu","gov.cu","inf.cu","cv","com.cv","edu.cv","int.cv","nome.cv","org.cv","cw","com.cw","edu.cw","net.cw","org.cw","cx","gov.cx","cy","ac.cy","biz.cy","com.cy","ekloges.cy","gov.cy","ltd.cy","mil.cy","net.cy","org.cy","press.cy","pro.cy","tm.cy","cz","de","dj","dk","dm","com.dm","net.dm","org.dm","edu.dm","gov.dm","do","art.do","com.do","edu.do","gob.do","gov.do","mil.do","net.do","org.do","sld.do","web.do","dz","art.dz","asso.dz","com.dz","edu.dz","gov.dz","org.dz","net.dz","pol.dz","soc.dz","tm.dz","ec","com.ec","info.ec","net.ec","fin.ec","k12.ec","med.ec","pro.ec","org.ec","edu.ec","gov.ec","gob.ec","mil.ec","edu","ee","edu.ee","gov.ee","riik.ee","lib.ee","med.ee","com.ee","pri.ee","aip.ee","org.ee","fie.ee","eg","com.eg","edu.eg","eun.eg","gov.eg","mil.eg","name.eg","net.eg","org.eg","sci.eg","*.er","es","com.es","nom.es","org.es","gob.es","edu.es","et","com.et","gov.et","org.et","edu.et","biz.et","name.et","info.et","net.et","eu","fi","aland.fi","fj","ac.fj","biz.fj","com.fj","gov.fj","info.fj","mil.fj","name.fj","net.fj","org.fj","pro.fj","*.fk","com.fm","edu.fm","net.fm","org.fm","fm","fo","fr","asso.fr","com.fr","gouv.fr","nom.fr","prd.fr","tm.fr","aeroport.fr","avocat.fr","avoues.fr","cci.fr","chambagri.fr","chirurgiens-dentistes.fr","experts-comptables.fr","geometre-expert.fr","greta.fr","huissier-justice.fr","medecin.fr","notaires.fr","pharmacien.fr","port.fr","veterinaire.fr","ga","gb","edu.gd","gov.gd","gd","ge","com.ge","edu.ge","gov.ge","org.ge","mil.ge","net.ge","pvt.ge","gf","gg","co.gg","net.gg","org.gg","gh","com.gh","edu.gh","gov.gh","org.gh","mil.gh","gi","com.gi","ltd.gi","gov.gi","mod.gi","edu.gi","org.gi","gl","co.gl","com.gl","edu.gl","net.gl","org.gl","gm","gn","ac.gn","com.gn","edu.gn","gov.gn","org.gn","net.gn","gov","gp","com.gp","net.gp","mobi.gp","edu.gp","org.gp","asso.gp","gq","gr","com.gr","edu.gr","net.gr","org.gr","gov.gr","gs","gt","com.gt","edu.gt","gob.gt","ind.gt","mil.gt","net.gt","org.gt","gu","com.gu","edu.gu","gov.gu","guam.gu","info.gu","net.gu","org.gu","web.gu","gw","gy","co.gy","com.gy","edu.gy","gov.gy","net.gy","org.gy","hk","com.hk","edu.hk","gov.hk","idv.hk","net.hk","org.hk","公司.hk","教育.hk","敎育.hk","政府.hk","個人.hk","个��.hk","箇人.hk","網络.hk","网络.hk","组織.hk","網絡.hk","网絡.hk","组织.hk","組織.hk","組织.hk","hm","hn","com.hn","edu.hn","org.hn","net.hn","mil.hn","gob.hn","hr","iz.hr","from.hr","name.hr","com.hr","ht","com.ht","shop.ht","firm.ht","info.ht","adult.ht","net.ht","pro.ht","org.ht","med.ht","art.ht","coop.ht","pol.ht","asso.ht","edu.ht","rel.ht","gouv.ht","perso.ht","hu","co.hu","info.hu","org.hu","priv.hu","sport.hu","tm.hu","2000.hu","agrar.hu","bolt.hu","casino.hu","city.hu","erotica.hu","erotika.hu","film.hu","forum.hu","games.hu","hotel.hu","ingatlan.hu","jogasz.hu","konyvelo.hu","lakas.hu","media.hu","news.hu","reklam.hu","sex.hu","shop.hu","suli.hu","szex.hu","tozsde.hu","utazas.hu","video.hu","id","ac.id","biz.id","co.id","desa.id","go.id","mil.id","my.id","net.id","or.id","ponpes.id","sch.id","web.id","ie","gov.ie","il","ac.il","co.il","gov.il","idf.il","k12.il","muni.il","net.il","org.il","im","ac.im","co.im","com.im","ltd.co.im","net.im","org.im","plc.co.im","tt.im","tv.im","in","co.in","firm.in","net.in","org.in","gen.in","ind.in","nic.in","ac.in","edu.in","res.in","gov.in","mil.in","info","int","eu.int","io","com.io","iq","gov.iq","edu.iq","mil.iq","com.iq","org.iq","net.iq","ir","ac.ir","co.ir","gov.ir","id.ir","net.ir","org.ir","sch.ir","ایران.ir","ايران.ir","is","net.is","com.is","edu.is","gov.is","org.is","int.is","it","gov.it","edu.it","abr.it","abruzzo.it","aosta-valley.it","aostavalley.it","bas.it","basilicata.it","cal.it","calabria.it","cam.it","campania.it","emilia-romagna.it","emiliaromagna.it","emr.it","friuli-v-giulia.it","friuli-ve-giulia.it","friuli-vegiulia.it","friuli-venezia-giulia.it","friuli-veneziagiulia.it","friuli-vgiulia.it","friuliv-giulia.it","friulive-giulia.it","friulivegiulia.it","friulivenezia-giulia.it","friuliveneziagiulia.it","friulivgiulia.it","fvg.it","laz.it","lazio.it","lig.it","liguria.it","lom.it","lombardia.it","lombardy.it","lucania.it","mar.it","marche.it","mol.it","molise.it","piedmont.it","piemonte.it","pmn.it","pug.it","puglia.it","sar.it","sardegna.it","sardinia.it","sic.it","sicilia.it","sicily.it","taa.it","tos.it","toscana.it","trentin-sud-tirol.it","trentin-süd-tirol.it","trentin-sudtirol.it","trentin-südtirol.it","trentin-sued-tirol.it","trentin-suedtirol.it","trentino-a-adige.it","trentino-aadige.it","trentino-alto-adige.it","trentino-altoadige.it","trentino-s-tirol.it","trentino-stirol.it","trentino-sud-tirol.it","trentino-süd-tirol.it","trentino-sudtirol.it","trentino-südtirol.it","trentino-sued-tirol.it","trentino-suedtirol.it","trentino.it","trentinoa-adige.it","trentinoaadige.it","trentinoalto-adige.it","trentinoaltoadige.it","trentinos-tirol.it","trentinostirol.it","trentinosud-tirol.it","trentinosüd-tirol.it","trentinosudtirol.it","trentinosüdtirol.it","trentinosued-tirol.it","trentinosuedtirol.it","trentinsud-tirol.it","trentinsüd-tirol.it","trentinsudtirol.it","trentinsüdtirol.it","trentinsued-tirol.it","trentinsuedtirol.it","tuscany.it","umb.it","umbria.it","val-d-aosta.it","val-daosta.it","vald-aosta.it","valdaosta.it","valle-aosta.it","valle-d-aosta.it","valle-daosta.it","valleaosta.it","valled-aosta.it","valledaosta.it","vallee-aoste.it","vallée-aoste.it","vallee-d-aoste.it","vallée-d-aoste.it","valleeaoste.it","valléeaoste.it","valleedaoste.it","valléedaoste.it","vao.it","vda.it","ven.it","veneto.it","ag.it","agrigento.it","al.it","alessandria.it","alto-adige.it","altoadige.it","an.it","ancona.it","andria-barletta-trani.it","andria-trani-barletta.it","andriabarlettatrani.it","andriatranibarletta.it","ao.it","aosta.it","aoste.it","ap.it","aq.it","aquila.it","ar.it","arezzo.it","ascoli-piceno.it","ascolipiceno.it","asti.it","at.it","av.it","avellino.it","ba.it","balsan-sudtirol.it","balsan-südtirol.it","balsan-suedtirol.it","balsan.it","bari.it","barletta-trani-andria.it","barlettatraniandria.it","belluno.it","benevento.it","bergamo.it","bg.it","bi.it","biella.it","bl.it","bn.it","bo.it","bologna.it","bolzano-altoadige.it","bolzano.it","bozen-sudtirol.it","bozen-südtirol.it","bozen-suedtirol.it","bozen.it","br.it","brescia.it","brindisi.it","bs.it","bt.it","bulsan-sudtirol.it","bulsan-südtirol.it","bulsan-suedtirol.it","bulsan.it","bz.it","ca.it","cagliari.it","caltanissetta.it","campidano-medio.it","campidanomedio.it","campobasso.it","carbonia-iglesias.it","carboniaiglesias.it","carrara-massa.it","carraramassa.it","caserta.it","catania.it","catanzaro.it","cb.it","ce.it","cesena-forli.it","cesena-forlì.it","cesenaforli.it","cesenaforlì.it","ch.it","chieti.it","ci.it","cl.it","cn.it","co.it","como.it","cosenza.it","cr.it","cremona.it","crotone.it","cs.it","ct.it","cuneo.it","cz.it","dell-ogliastra.it","dellogliastra.it","en.it","enna.it","fc.it","fe.it","fermo.it","ferrara.it","fg.it","fi.it","firenze.it","florence.it","fm.it","foggia.it","forli-cesena.it","forlì-cesena.it","forlicesena.it","forlìcesena.it","fr.it","frosinone.it","ge.it","genoa.it","genova.it","go.it","gorizia.it","gr.it","grosseto.it","iglesias-carbonia.it","iglesiascarbonia.it","im.it","imperia.it","is.it","isernia.it","kr.it","la-spezia.it","laquila.it","laspezia.it","latina.it","lc.it","le.it","lecce.it","lecco.it","li.it","livorno.it","lo.it","lodi.it","lt.it","lu.it","lucca.it","macerata.it","mantova.it","massa-carrara.it","massacarrara.it","matera.it","mb.it","mc.it","me.it","medio-campidano.it","mediocampidano.it","messina.it","mi.it","milan.it","milano.it","mn.it","mo.it","modena.it","monza-brianza.it","monza-e-della-brianza.it","monza.it","monzabrianza.it","monzaebrianza.it","monzaedellabrianza.it","ms.it","mt.it","na.it","naples.it","napoli.it","no.it","novara.it","nu.it","nuoro.it","og.it","ogliastra.it","olbia-tempio.it","olbiatempio.it","or.it","oristano.it","ot.it","pa.it","padova.it","padua.it","palermo.it","parma.it","pavia.it","pc.it","pd.it","pe.it","perugia.it","pesaro-urbino.it","pesarourbino.it","pescara.it","pg.it","pi.it","piacenza.it","pisa.it","pistoia.it","pn.it","po.it","pordenone.it","potenza.it","pr.it","prato.it","pt.it","pu.it","pv.it","pz.it","ra.it","ragusa.it","ravenna.it","rc.it","re.it","reggio-calabria.it","reggio-emilia.it","reggiocalabria.it","reggioemilia.it","rg.it","ri.it","rieti.it","rimini.it","rm.it","rn.it","ro.it","roma.it","rome.it","rovigo.it","sa.it","salerno.it","sassari.it","savona.it","si.it","siena.it","siracusa.it","so.it","sondrio.it","sp.it","sr.it","ss.it","suedtirol.it","südtirol.it","sv.it","ta.it","taranto.it","te.it","tempio-olbia.it","tempioolbia.it","teramo.it","terni.it","tn.it","to.it","torino.it","tp.it","tr.it","trani-andria-barletta.it","trani-barletta-andria.it","traniandriabarletta.it","tranibarlettaandria.it","trapani.it","trento.it","treviso.it","trieste.it","ts.it","turin.it","tv.it","ud.it","udine.it","urbino-pesaro.it","urbinopesaro.it","va.it","varese.it","vb.it","vc.it","ve.it","venezia.it","venice.it","verbania.it","vercelli.it","verona.it","vi.it","vibo-valentia.it","vibovalentia.it","vicenza.it","viterbo.it","vr.it","vs.it","vt.it","vv.it","je","co.je","net.je","org.je","*.jm","jo","com.jo","org.jo","net.jo","edu.jo","sch.jo","gov.jo","mil.jo","name.jo","jobs","jp","ac.jp","ad.jp","co.jp","ed.jp","go.jp","gr.jp","lg.jp","ne.jp","or.jp","aichi.jp","akita.jp","aomori.jp","chiba.jp","ehime.jp","fukui.jp","fukuoka.jp","fukushima.jp","gifu.jp","gunma.jp","hiroshima.jp","hokkaido.jp","hyogo.jp","ibaraki.jp","ishikawa.jp","iwate.jp","kagawa.jp","kagoshima.jp","kanagawa.jp","kochi.jp","kumamoto.jp","kyoto.jp","mie.jp","miyagi.jp","miyazaki.jp","nagano.jp","nagasaki.jp","nara.jp","niigata.jp","oita.jp","okayama.jp","okinawa.jp","osaka.jp","saga.jp","saitama.jp","shiga.jp","shimane.jp","shizuoka.jp","tochigi.jp","tokushima.jp","tokyo.jp","tottori.jp","toyama.jp","wakayama.jp","yamagata.jp","yamaguchi.jp","yamanashi.jp","栃木.jp","愛知.jp","愛媛.jp","兵庫.jp","熊本.jp","茨城.jp","北海道.jp","千葉.jp","和歌山.jp","長崎.jp","長野.jp","新潟.jp","青森.jp","静岡.jp","東京.jp","石川.jp","埼玉.jp","三重.jp","京都.jp","佐賀.jp","大分.jp","大阪.jp","奈良.jp","宮城.jp","宮崎.jp","富山.jp","山口.jp","山形.jp","山梨.jp","岩手.jp","岐阜.jp","岡山.jp","島根.jp","広島.jp","徳島.jp","沖縄.jp","滋賀.jp","神奈川.jp","福井.jp","福岡.jp","福島.jp","秋田.jp","群馬.jp","香川.jp","高知.jp","鳥取.jp","鹿児島.jp","*.kawasaki.jp","*.kitakyushu.jp","*.kobe.jp","*.nagoya.jp","*.sapporo.jp","*.sendai.jp","*.yokohama.jp","!city.kawasaki.jp","!city.kitakyushu.jp","!city.kobe.jp","!city.nagoya.jp","!city.sapporo.jp","!city.sendai.jp","!city.yokohama.jp","aisai.aichi.jp","ama.aichi.jp","anjo.aichi.jp","asuke.aichi.jp","chiryu.aichi.jp","chita.aichi.jp","fuso.aichi.jp","gamagori.aichi.jp","handa.aichi.jp","hazu.aichi.jp","hekinan.aichi.jp","higashiura.aichi.jp","ichinomiya.aichi.jp","inazawa.aichi.jp","inuyama.aichi.jp","isshiki.aichi.jp","iwakura.aichi.jp","kanie.aichi.jp","kariya.aichi.jp","kasugai.aichi.jp","kira.aichi.jp","kiyosu.aichi.jp","komaki.aichi.jp","konan.aichi.jp","kota.aichi.jp","mihama.aichi.jp","miyoshi.aichi.jp","nishio.aichi.jp","nisshin.aichi.jp","obu.aichi.jp","oguchi.aichi.jp","oharu.aichi.jp","okazaki.aichi.jp","owariasahi.aichi.jp","seto.aichi.jp","shikatsu.aichi.jp","shinshiro.aichi.jp","shitara.aichi.jp","tahara.aichi.jp","takahama.aichi.jp","tobishima.aichi.jp","toei.aichi.jp","togo.aichi.jp","tokai.aichi.jp","tokoname.aichi.jp","toyoake.aichi.jp","toyohashi.aichi.jp","toyokawa.aichi.jp","toyone.aichi.jp","toyota.aichi.jp","tsushima.aichi.jp","yatomi.aichi.jp","akita.akita.jp","daisen.akita.jp","fujisato.akita.jp","gojome.akita.jp","hachirogata.akita.jp","happou.akita.jp","higashinaruse.akita.jp","honjo.akita.jp","honjyo.akita.jp","ikawa.akita.jp","kamikoani.akita.jp","kamioka.akita.jp","katagami.akita.jp","kazuno.akita.jp","kitaakita.akita.jp","kosaka.akita.jp","kyowa.akita.jp","misato.akita.jp","mitane.akita.jp","moriyoshi.akita.jp","nikaho.akita.jp","noshiro.akita.jp","odate.akita.jp","oga.akita.jp","ogata.akita.jp","semboku.akita.jp","yokote.akita.jp","yurihonjo.akita.jp","aomori.aomori.jp","gonohe.aomori.jp","hachinohe.aomori.jp","hashikami.aomori.jp","hiranai.aomori.jp","hirosaki.aomori.jp","itayanagi.aomori.jp","kuroishi.aomori.jp","misawa.aomori.jp","mutsu.aomori.jp","nakadomari.aomori.jp","noheji.aomori.jp","oirase.aomori.jp","owani.aomori.jp","rokunohe.aomori.jp","sannohe.aomori.jp","shichinohe.aomori.jp","shingo.aomori.jp","takko.aomori.jp","towada.aomori.jp","tsugaru.aomori.jp","tsuruta.aomori.jp","abiko.chiba.jp","asahi.chiba.jp","chonan.chiba.jp","chosei.chiba.jp","choshi.chiba.jp","chuo.chiba.jp","funabashi.chiba.jp","futtsu.chiba.jp","hanamigawa.chiba.jp","ichihara.chiba.jp","ichikawa.chiba.jp","ichinomiya.chiba.jp","inzai.chiba.jp","isumi.chiba.jp","kamagaya.chiba.jp","kamogawa.chiba.jp","kashiwa.chiba.jp","katori.chiba.jp","katsuura.chiba.jp","kimitsu.chiba.jp","kisarazu.chiba.jp","kozaki.chiba.jp","kujukuri.chiba.jp","kyonan.chiba.jp","matsudo.chiba.jp","midori.chiba.jp","mihama.chiba.jp","minamiboso.chiba.jp","mobara.chiba.jp","mutsuzawa.chiba.jp","nagara.chiba.jp","nagareyama.chiba.jp","narashino.chiba.jp","narita.chiba.jp","noda.chiba.jp","oamishirasato.chiba.jp","omigawa.chiba.jp","onjuku.chiba.jp","otaki.chiba.jp","sakae.chiba.jp","sakura.chiba.jp","shimofusa.chiba.jp","shirako.chiba.jp","shiroi.chiba.jp","shisui.chiba.jp","sodegaura.chiba.jp","sosa.chiba.jp","tako.chiba.jp","tateyama.chiba.jp","togane.chiba.jp","tohnosho.chiba.jp","tomisato.chiba.jp","urayasu.chiba.jp","yachimata.chiba.jp","yachiyo.chiba.jp","yokaichiba.chiba.jp","yokoshibahikari.chiba.jp","yotsukaido.chiba.jp","ainan.ehime.jp","honai.ehime.jp","ikata.ehime.jp","imabari.ehime.jp","iyo.ehime.jp","kamijima.ehime.jp","kihoku.ehime.jp","kumakogen.ehime.jp","masaki.ehime.jp","matsuno.ehime.jp","matsuyama.ehime.jp","namikata.ehime.jp","niihama.ehime.jp","ozu.ehime.jp","saijo.ehime.jp","seiyo.ehime.jp","shikokuchuo.ehime.jp","tobe.ehime.jp","toon.ehime.jp","uchiko.ehime.jp","uwajima.ehime.jp","yawatahama.ehime.jp","echizen.fukui.jp","eiheiji.fukui.jp","fukui.fukui.jp","ikeda.fukui.jp","katsuyama.fukui.jp","mihama.fukui.jp","minamiechizen.fukui.jp","obama.fukui.jp","ohi.fukui.jp","ono.fukui.jp","sabae.fukui.jp","sakai.fukui.jp","takahama.fukui.jp","tsuruga.fukui.jp","wakasa.fukui.jp","ashiya.fukuoka.jp","buzen.fukuoka.jp","chikugo.fukuoka.jp","chikuho.fukuoka.jp","chikujo.fukuoka.jp","chikushino.fukuoka.jp","chikuzen.fukuoka.jp","chuo.fukuoka.jp","dazaifu.fukuoka.jp","fukuchi.fukuoka.jp","hakata.fukuoka.jp","higashi.fukuoka.jp","hirokawa.fukuoka.jp","hisayama.fukuoka.jp","iizuka.fukuoka.jp","inatsuki.fukuoka.jp","kaho.fukuoka.jp","kasuga.fukuoka.jp","kasuya.fukuoka.jp","kawara.fukuoka.jp","keisen.fukuoka.jp","koga.fukuoka.jp","kurate.fukuoka.jp","kurogi.fukuoka.jp","kurume.fukuoka.jp","minami.fukuoka.jp","miyako.fukuoka.jp","miyama.fukuoka.jp","miyawaka.fukuoka.jp","mizumaki.fukuoka.jp","munakata.fukuoka.jp","nakagawa.fukuoka.jp","nakama.fukuoka.jp","nishi.fukuoka.jp","nogata.fukuoka.jp","ogori.fukuoka.jp","okagaki.fukuoka.jp","okawa.fukuoka.jp","oki.fukuoka.jp","omuta.fukuoka.jp","onga.fukuoka.jp","onojo.fukuoka.jp","oto.fukuoka.jp","saigawa.fukuoka.jp","sasaguri.fukuoka.jp","shingu.fukuoka.jp","shinyoshitomi.fukuoka.jp","shonai.fukuoka.jp","soeda.fukuoka.jp","sue.fukuoka.jp","tachiarai.fukuoka.jp","tagawa.fukuoka.jp","takata.fukuoka.jp","toho.fukuoka.jp","toyotsu.fukuoka.jp","tsuiki.fukuoka.jp","ukiha.fukuoka.jp","umi.fukuoka.jp","usui.fukuoka.jp","yamada.fukuoka.jp","yame.fukuoka.jp","yanagawa.fukuoka.jp","yukuhashi.fukuoka.jp","aizubange.fukushima.jp","aizumisato.fukushima.jp","aizuwakamatsu.fukushima.jp","asakawa.fukushima.jp","bandai.fukushima.jp","date.fukushima.jp","fukushima.fukushima.jp","furudono.fukushima.jp","futaba.fukushima.jp","hanawa.fukushima.jp","higashi.fukushima.jp","hirata.fukushima.jp","hirono.fukushima.jp","iitate.fukushima.jp","inawashiro.fukushima.jp","ishikawa.fukushima.jp","iwaki.fukushima.jp","izumizaki.fukushima.jp","kagamiishi.fukushima.jp","kaneyama.fukushima.jp","kawamata.fukushima.jp","kitakata.fukushima.jp","kitashiobara.fukushima.jp","koori.fukushima.jp","koriyama.fukushima.jp","kunimi.fukushima.jp","miharu.fukushima.jp","mishima.fukushima.jp","namie.fukushima.jp","nango.fukushima.jp","nishiaizu.fukushima.jp","nishigo.fukushima.jp","okuma.fukushima.jp","omotego.fukushima.jp","ono.fukushima.jp","otama.fukushima.jp","samegawa.fukushima.jp","shimogo.fukushima.jp","shirakawa.fukushima.jp","showa.fukushima.jp","soma.fukushima.jp","sukagawa.fukushima.jp","taishin.fukushima.jp","tamakawa.fukushima.jp","tanagura.fukushima.jp","tenei.fukushima.jp","yabuki.fukushima.jp","yamato.fukushima.jp","yamatsuri.fukushima.jp","yanaizu.fukushima.jp","yugawa.fukushima.jp","anpachi.gifu.jp","ena.gifu.jp","gifu.gifu.jp","ginan.gifu.jp","godo.gifu.jp","gujo.gifu.jp","hashima.gifu.jp","hichiso.gifu.jp","hida.gifu.jp","higashishirakawa.gifu.jp","ibigawa.gifu.jp","ikeda.gifu.jp","kakamigahara.gifu.jp","kani.gifu.jp","kasahara.gifu.jp","kasamatsu.gifu.jp","kawaue.gifu.jp","kitagata.gifu.jp","mino.gifu.jp","minokamo.gifu.jp","mitake.gifu.jp","mizunami.gifu.jp","motosu.gifu.jp","nakatsugawa.gifu.jp","ogaki.gifu.jp","sakahogi.gifu.jp","seki.gifu.jp","sekigahara.gifu.jp","shirakawa.gifu.jp","tajimi.gifu.jp","takayama.gifu.jp","tarui.gifu.jp","toki.gifu.jp","tomika.gifu.jp","wanouchi.gifu.jp","yamagata.gifu.jp","yaotsu.gifu.jp","yoro.gifu.jp","annaka.gunma.jp","chiyoda.gunma.jp","fujioka.gunma.jp","higashiagatsuma.gunma.jp","isesaki.gunma.jp","itakura.gunma.jp","kanna.gunma.jp","kanra.gunma.jp","katashina.gunma.jp","kawaba.gunma.jp","kiryu.gunma.jp","kusatsu.gunma.jp","maebashi.gunma.jp","meiwa.gunma.jp","midori.gunma.jp","minakami.gunma.jp","naganohara.gunma.jp","nakanojo.gunma.jp","nanmoku.gunma.jp","numata.gunma.jp","oizumi.gunma.jp","ora.gunma.jp","ota.gunma.jp","shibukawa.gunma.jp","shimonita.gunma.jp","shinto.gunma.jp","showa.gunma.jp","takasaki.gunma.jp","takayama.gunma.jp","tamamura.gunma.jp","tatebayashi.gunma.jp","tomioka.gunma.jp","tsukiyono.gunma.jp","tsumagoi.gunma.jp","ueno.gunma.jp","yoshioka.gunma.jp","asaminami.hiroshima.jp","daiwa.hiroshima.jp","etajima.hiroshima.jp","fuchu.hiroshima.jp","fukuyama.hiroshima.jp","hatsukaichi.hiroshima.jp","higashihiroshima.hiroshima.jp","hongo.hiroshima.jp","jinsekikogen.hiroshima.jp","kaita.hiroshima.jp","kui.hiroshima.jp","kumano.hiroshima.jp","kure.hiroshima.jp","mihara.hiroshima.jp","miyoshi.hiroshima.jp","naka.hiroshima.jp","onomichi.hiroshima.jp","osakikamijima.hiroshima.jp","otake.hiroshima.jp","saka.hiroshima.jp","sera.hiroshima.jp","seranishi.hiroshima.jp","shinichi.hiroshima.jp","shobara.hiroshima.jp","takehara.hiroshima.jp","abashiri.hokkaido.jp","abira.hokkaido.jp","aibetsu.hokkaido.jp","akabira.hokkaido.jp","akkeshi.hokkaido.jp","asahikawa.hokkaido.jp","ashibetsu.hokkaido.jp","ashoro.hokkaido.jp","assabu.hokkaido.jp","atsuma.hokkaido.jp","bibai.hokkaido.jp","biei.hokkaido.jp","bifuka.hokkaido.jp","bihoro.hokkaido.jp","biratori.hokkaido.jp","chippubetsu.hokkaido.jp","chitose.hokkaido.jp","date.hokkaido.jp","ebetsu.hokkaido.jp","embetsu.hokkaido.jp","eniwa.hokkaido.jp","erimo.hokkaido.jp","esan.hokkaido.jp","esashi.hokkaido.jp","fukagawa.hokkaido.jp","fukushima.hokkaido.jp","furano.hokkaido.jp","furubira.hokkaido.jp","haboro.hokkaido.jp","hakodate.hokkaido.jp","hamatonbetsu.hokkaido.jp","hidaka.hokkaido.jp","higashikagura.hokkaido.jp","higashikawa.hokkaido.jp","hiroo.hokkaido.jp","hokuryu.hokkaido.jp","hokuto.hokkaido.jp","honbetsu.hokkaido.jp","horokanai.hokkaido.jp","horonobe.hokkaido.jp","ikeda.hokkaido.jp","imakane.hokkaido.jp","ishikari.hokkaido.jp","iwamizawa.hokkaido.jp","iwanai.hokkaido.jp","kamifurano.hokkaido.jp","kamikawa.hokkaido.jp","kamishihoro.hokkaido.jp","kamisunagawa.hokkaido.jp","kamoenai.hokkaido.jp","kayabe.hokkaido.jp","kembuchi.hokkaido.jp","kikonai.hokkaido.jp","kimobetsu.hokkaido.jp","kitahiroshima.hokkaido.jp","kitami.hokkaido.jp","kiyosato.hokkaido.jp","koshimizu.hokkaido.jp","kunneppu.hokkaido.jp","kuriyama.hokkaido.jp","kuromatsunai.hokkaido.jp","kushiro.hokkaido.jp","kutchan.hokkaido.jp","kyowa.hokkaido.jp","mashike.hokkaido.jp","matsumae.hokkaido.jp","mikasa.hokkaido.jp","minamifurano.hokkaido.jp","mombetsu.hokkaido.jp","moseushi.hokkaido.jp","mukawa.hokkaido.jp","muroran.hokkaido.jp","naie.hokkaido.jp","nakagawa.hokkaido.jp","nakasatsunai.hokkaido.jp","nakatombetsu.hokkaido.jp","nanae.hokkaido.jp","nanporo.hokkaido.jp","nayoro.hokkaido.jp","nemuro.hokkaido.jp","niikappu.hokkaido.jp","niki.hokkaido.jp","nishiokoppe.hokkaido.jp","noboribetsu.hokkaido.jp","numata.hokkaido.jp","obihiro.hokkaido.jp","obira.hokkaido.jp","oketo.hokkaido.jp","okoppe.hokkaido.jp","otaru.hokkaido.jp","otobe.hokkaido.jp","otofuke.hokkaido.jp","otoineppu.hokkaido.jp","oumu.hokkaido.jp","ozora.hokkaido.jp","pippu.hokkaido.jp","rankoshi.hokkaido.jp","rebun.hokkaido.jp","rikubetsu.hokkaido.jp","rishiri.hokkaido.jp","rishirifuji.hokkaido.jp","saroma.hokkaido.jp","sarufutsu.hokkaido.jp","shakotan.hokkaido.jp","shari.hokkaido.jp","shibecha.hokkaido.jp","shibetsu.hokkaido.jp","shikabe.hokkaido.jp","shikaoi.hokkaido.jp","shimamaki.hokkaido.jp","shimizu.hokkaido.jp","shimokawa.hokkaido.jp","shinshinotsu.hokkaido.jp","shintoku.hokkaido.jp","shiranuka.hokkaido.jp","shiraoi.hokkaido.jp","shiriuchi.hokkaido.jp","sobetsu.hokkaido.jp","sunagawa.hokkaido.jp","taiki.hokkaido.jp","takasu.hokkaido.jp","takikawa.hokkaido.jp","takinoue.hokkaido.jp","teshikaga.hokkaido.jp","tobetsu.hokkaido.jp","tohma.hokkaido.jp","tomakomai.hokkaido.jp","tomari.hokkaido.jp","toya.hokkaido.jp","toyako.hokkaido.jp","toyotomi.hokkaido.jp","toyoura.hokkaido.jp","tsubetsu.hokkaido.jp","tsukigata.hokkaido.jp","urakawa.hokkaido.jp","urausu.hokkaido.jp","uryu.hokkaido.jp","utashinai.hokkaido.jp","wakkanai.hokkaido.jp","wassamu.hokkaido.jp","yakumo.hokkaido.jp","yoichi.hokkaido.jp","aioi.hyogo.jp","akashi.hyogo.jp","ako.hyogo.jp","amagasaki.hyogo.jp","aogaki.hyogo.jp","asago.hyogo.jp","ashiya.hyogo.jp","awaji.hyogo.jp","fukusaki.hyogo.jp","goshiki.hyogo.jp","harima.hyogo.jp","himeji.hyogo.jp","ichikawa.hyogo.jp","inagawa.hyogo.jp","itami.hyogo.jp","kakogawa.hyogo.jp","kamigori.hyogo.jp","kamikawa.hyogo.jp","kasai.hyogo.jp","kasuga.hyogo.jp","kawanishi.hyogo.jp","miki.hyogo.jp","minamiawaji.hyogo.jp","nishinomiya.hyogo.jp","nishiwaki.hyogo.jp","ono.hyogo.jp","sanda.hyogo.jp","sannan.hyogo.jp","sasayama.hyogo.jp","sayo.hyogo.jp","shingu.hyogo.jp","shinonsen.hyogo.jp","shiso.hyogo.jp","sumoto.hyogo.jp","taishi.hyogo.jp","taka.hyogo.jp","takarazuka.hyogo.jp","takasago.hyogo.jp","takino.hyogo.jp","tamba.hyogo.jp","tatsuno.hyogo.jp","toyooka.hyogo.jp","yabu.hyogo.jp","yashiro.hyogo.jp","yoka.hyogo.jp","yokawa.hyogo.jp","ami.ibaraki.jp","asahi.ibaraki.jp","bando.ibaraki.jp","chikusei.ibaraki.jp","daigo.ibaraki.jp","fujishiro.ibaraki.jp","hitachi.ibaraki.jp","hitachinaka.ibaraki.jp","hitachiomiya.ibaraki.jp","hitachiota.ibaraki.jp","ibaraki.ibaraki.jp","ina.ibaraki.jp","inashiki.ibaraki.jp","itako.ibaraki.jp","iwama.ibaraki.jp","joso.ibaraki.jp","kamisu.ibaraki.jp","kasama.ibaraki.jp","kashima.ibaraki.jp","kasumigaura.ibaraki.jp","koga.ibaraki.jp","miho.ibaraki.jp","mito.ibaraki.jp","moriya.ibaraki.jp","naka.ibaraki.jp","namegata.ibaraki.jp","oarai.ibaraki.jp","ogawa.ibaraki.jp","omitama.ibaraki.jp","ryugasaki.ibaraki.jp","sakai.ibaraki.jp","sakuragawa.ibaraki.jp","shimodate.ibaraki.jp","shimotsuma.ibaraki.jp","shirosato.ibaraki.jp","sowa.ibaraki.jp","suifu.ibaraki.jp","takahagi.ibaraki.jp","tamatsukuri.ibaraki.jp","tokai.ibaraki.jp","tomobe.ibaraki.jp","tone.ibaraki.jp","toride.ibaraki.jp","tsuchiura.ibaraki.jp","tsukuba.ibaraki.jp","uchihara.ibaraki.jp","ushiku.ibaraki.jp","yachiyo.ibaraki.jp","yamagata.ibaraki.jp","yawara.ibaraki.jp","yuki.ibaraki.jp","anamizu.ishikawa.jp","hakui.ishikawa.jp","hakusan.ishikawa.jp","kaga.ishikawa.jp","kahoku.ishikawa.jp","kanazawa.ishikawa.jp","kawakita.ishikawa.jp","komatsu.ishikawa.jp","nakanoto.ishikawa.jp","nanao.ishikawa.jp","nomi.ishikawa.jp","nonoichi.ishikawa.jp","noto.ishikawa.jp","shika.ishikawa.jp","suzu.ishikawa.jp","tsubata.ishikawa.jp","tsurugi.ishikawa.jp","uchinada.ishikawa.jp","wajima.ishikawa.jp","fudai.iwate.jp","fujisawa.iwate.jp","hanamaki.iwate.jp","hiraizumi.iwate.jp","hirono.iwate.jp","ichinohe.iwate.jp","ichinoseki.iwate.jp","iwaizumi.iwate.jp","iwate.iwate.jp","joboji.iwate.jp","kamaishi.iwate.jp","kanegasaki.iwate.jp","karumai.iwate.jp","kawai.iwate.jp","kitakami.iwate.jp","kuji.iwate.jp","kunohe.iwate.jp","kuzumaki.iwate.jp","miyako.iwate.jp","mizusawa.iwate.jp","morioka.iwate.jp","ninohe.iwate.jp","noda.iwate.jp","ofunato.iwate.jp","oshu.iwate.jp","otsuchi.iwate.jp","rikuzentakata.iwate.jp","shiwa.iwate.jp","shizukuishi.iwate.jp","sumita.iwate.jp","tanohata.iwate.jp","tono.iwate.jp","yahaba.iwate.jp","yamada.iwate.jp","ayagawa.kagawa.jp","higashikagawa.kagawa.jp","kanonji.kagawa.jp","kotohira.kagawa.jp","manno.kagawa.jp","marugame.kagawa.jp","mitoyo.kagawa.jp","naoshima.kagawa.jp","sanuki.kagawa.jp","tadotsu.kagawa.jp","takamatsu.kagawa.jp","tonosho.kagawa.jp","uchinomi.kagawa.jp","utazu.kagawa.jp","zentsuji.kagawa.jp","akune.kagoshima.jp","amami.kagoshima.jp","hioki.kagoshima.jp","isa.kagoshima.jp","isen.kagoshima.jp","izumi.kagoshima.jp","kagoshima.kagoshima.jp","kanoya.kagoshima.jp","kawanabe.kagoshima.jp","kinko.kagoshima.jp","kouyama.kagoshima.jp","makurazaki.kagoshima.jp","matsumoto.kagoshima.jp","minamitane.kagoshima.jp","nakatane.kagoshima.jp","nishinoomote.kagoshima.jp","satsumasendai.kagoshima.jp","soo.kagoshima.jp","tarumizu.kagoshima.jp","yusui.kagoshima.jp","aikawa.kanagawa.jp","atsugi.kanagawa.jp","ayase.kanagawa.jp","chigasaki.kanagawa.jp","ebina.kanagawa.jp","fujisawa.kanagawa.jp","hadano.kanagawa.jp","hakone.kanagawa.jp","hiratsuka.kanagawa.jp","isehara.kanagawa.jp","kaisei.kanagawa.jp","kamakura.kanagawa.jp","kiyokawa.kanagawa.jp","matsuda.kanagawa.jp","minamiashigara.kanagawa.jp","miura.kanagawa.jp","nakai.kanagawa.jp","ninomiya.kanagawa.jp","odawara.kanagawa.jp","oi.kanagawa.jp","oiso.kanagawa.jp","sagamihara.kanagawa.jp","samukawa.kanagawa.jp","tsukui.kanagawa.jp","yamakita.kanagawa.jp","yamato.kanagawa.jp","yokosuka.kanagawa.jp","yugawara.kanagawa.jp","zama.kanagawa.jp","zushi.kanagawa.jp","aki.kochi.jp","geisei.kochi.jp","hidaka.kochi.jp","higashitsuno.kochi.jp","ino.kochi.jp","kagami.kochi.jp","kami.kochi.jp","kitagawa.kochi.jp","kochi.kochi.jp","mihara.kochi.jp","motoyama.kochi.jp","muroto.kochi.jp","nahari.kochi.jp","nakamura.kochi.jp","nankoku.kochi.jp","nishitosa.kochi.jp","niyodogawa.kochi.jp","ochi.kochi.jp","okawa.kochi.jp","otoyo.kochi.jp","otsuki.kochi.jp","sakawa.kochi.jp","sukumo.kochi.jp","susaki.kochi.jp","tosa.kochi.jp","tosashimizu.kochi.jp","toyo.kochi.jp","tsuno.kochi.jp","umaji.kochi.jp","yasuda.kochi.jp","yusuhara.kochi.jp","amakusa.kumamoto.jp","arao.kumamoto.jp","aso.kumamoto.jp","choyo.kumamoto.jp","gyokuto.kumamoto.jp","kamiamakusa.kumamoto.jp","kikuchi.kumamoto.jp","kumamoto.kumamoto.jp","mashiki.kumamoto.jp","mifune.kumamoto.jp","minamata.kumamoto.jp","minamioguni.kumamoto.jp","nagasu.kumamoto.jp","nishihara.kumamoto.jp","oguni.kumamoto.jp","ozu.kumamoto.jp","sumoto.kumamoto.jp","takamori.kumamoto.jp","uki.kumamoto.jp","uto.kumamoto.jp","yamaga.kumamoto.jp","yamato.kumamoto.jp","yatsushiro.kumamoto.jp","ayabe.kyoto.jp","fukuchiyama.kyoto.jp","higashiyama.kyoto.jp","ide.kyoto.jp","ine.kyoto.jp","joyo.kyoto.jp","kameoka.kyoto.jp","kamo.kyoto.jp","kita.kyoto.jp","kizu.kyoto.jp","kumiyama.kyoto.jp","kyotamba.kyoto.jp","kyotanabe.kyoto.jp","kyotango.kyoto.jp","maizuru.kyoto.jp","minami.kyoto.jp","minamiyamashiro.kyoto.jp","miyazu.kyoto.jp","muko.kyoto.jp","nagaokakyo.kyoto.jp","nakagyo.kyoto.jp","nantan.kyoto.jp","oyamazaki.kyoto.jp","sakyo.kyoto.jp","seika.kyoto.jp","tanabe.kyoto.jp","uji.kyoto.jp","ujitawara.kyoto.jp","wazuka.kyoto.jp","yamashina.kyoto.jp","yawata.kyoto.jp","asahi.mie.jp","inabe.mie.jp","ise.mie.jp","kameyama.mie.jp","kawagoe.mie.jp","kiho.mie.jp","kisosaki.mie.jp","kiwa.mie.jp","komono.mie.jp","kumano.mie.jp","kuwana.mie.jp","matsusaka.mie.jp","meiwa.mie.jp","mihama.mie.jp","minamiise.mie.jp","misugi.mie.jp","miyama.mie.jp","nabari.mie.jp","shima.mie.jp","suzuka.mie.jp","tado.mie.jp","taiki.mie.jp","taki.mie.jp","tamaki.mie.jp","toba.mie.jp","tsu.mie.jp","udono.mie.jp","ureshino.mie.jp","watarai.mie.jp","yokkaichi.mie.jp","furukawa.miyagi.jp","higashimatsushima.miyagi.jp","ishinomaki.miyagi.jp","iwanuma.miyagi.jp","kakuda.miyagi.jp","kami.miyagi.jp","kawasaki.miyagi.jp","marumori.miyagi.jp","matsushima.miyagi.jp","minamisanriku.miyagi.jp","misato.miyagi.jp","murata.miyagi.jp","natori.miyagi.jp","ogawara.miyagi.jp","ohira.miyagi.jp","onagawa.miyagi.jp","osaki.miyagi.jp","rifu.miyagi.jp","semine.miyagi.jp","shibata.miyagi.jp","shichikashuku.miyagi.jp","shikama.miyagi.jp","shiogama.miyagi.jp","shiroishi.miyagi.jp","tagajo.miyagi.jp","taiwa.miyagi.jp","tome.miyagi.jp","tomiya.miyagi.jp","wakuya.miyagi.jp","watari.miyagi.jp","yamamoto.miyagi.jp","zao.miyagi.jp","aya.miyazaki.jp","ebino.miyazaki.jp","gokase.miyazaki.jp","hyuga.miyazaki.jp","kadogawa.miyazaki.jp","kawaminami.miyazaki.jp","kijo.miyazaki.jp","kitagawa.miyazaki.jp","kitakata.miyazaki.jp","kitaura.miyazaki.jp","kobayashi.miyazaki.jp","kunitomi.miyazaki.jp","kushima.miyazaki.jp","mimata.miyazaki.jp","miyakonojo.miyazaki.jp","miyazaki.miyazaki.jp","morotsuka.miyazaki.jp","nichinan.miyazaki.jp","nishimera.miyazaki.jp","nobeoka.miyazaki.jp","saito.miyazaki.jp","shiiba.miyazaki.jp","shintomi.miyazaki.jp","takaharu.miyazaki.jp","takanabe.miyazaki.jp","takazaki.miyazaki.jp","tsuno.miyazaki.jp","achi.nagano.jp","agematsu.nagano.jp","anan.nagano.jp","aoki.nagano.jp","asahi.nagano.jp","azumino.nagano.jp","chikuhoku.nagano.jp","chikuma.nagano.jp","chino.nagano.jp","fujimi.nagano.jp","hakuba.nagano.jp","hara.nagano.jp","hiraya.nagano.jp","iida.nagano.jp","iijima.nagano.jp","iiyama.nagano.jp","iizuna.nagano.jp","ikeda.nagano.jp","ikusaka.nagano.jp","ina.nagano.jp","karuizawa.nagano.jp","kawakami.nagano.jp","kiso.nagano.jp","kisofukushima.nagano.jp","kitaaiki.nagano.jp","komagane.nagano.jp","komoro.nagano.jp","matsukawa.nagano.jp","matsumoto.nagano.jp","miasa.nagano.jp","minamiaiki.nagano.jp","minamimaki.nagano.jp","minamiminowa.nagano.jp","minowa.nagano.jp","miyada.nagano.jp","miyota.nagano.jp","mochizuki.nagano.jp","nagano.nagano.jp","nagawa.nagano.jp","nagiso.nagano.jp","nakagawa.nagano.jp","nakano.nagano.jp","nozawaonsen.nagano.jp","obuse.nagano.jp","ogawa.nagano.jp","okaya.nagano.jp","omachi.nagano.jp","omi.nagano.jp","ookuwa.nagano.jp","ooshika.nagano.jp","otaki.nagano.jp","otari.nagano.jp","sakae.nagano.jp","sakaki.nagano.jp","saku.nagano.jp","sakuho.nagano.jp","shimosuwa.nagano.jp","shinanomachi.nagano.jp","shiojiri.nagano.jp","suwa.nagano.jp","suzaka.nagano.jp","takagi.nagano.jp","takamori.nagano.jp","takayama.nagano.jp","tateshina.nagano.jp","tatsuno.nagano.jp","togakushi.nagano.jp","togura.nagano.jp","tomi.nagano.jp","ueda.nagano.jp","wada.nagano.jp","yamagata.nagano.jp","yamanouchi.nagano.jp","yasaka.nagano.jp","yasuoka.nagano.jp","chijiwa.nagasaki.jp","futsu.nagasaki.jp","goto.nagasaki.jp","hasami.nagasaki.jp","hirado.nagasaki.jp","iki.nagasaki.jp","isahaya.nagasaki.jp","kawatana.nagasaki.jp","kuchinotsu.nagasaki.jp","matsuura.nagasaki.jp","nagasaki.nagasaki.jp","obama.nagasaki.jp","omura.nagasaki.jp","oseto.nagasaki.jp","saikai.nagasaki.jp","sasebo.nagasaki.jp","seihi.nagasaki.jp","shimabara.nagasaki.jp","shinkamigoto.nagasaki.jp","togitsu.nagasaki.jp","tsushima.nagasaki.jp","unzen.nagasaki.jp","ando.nara.jp","gose.nara.jp","heguri.nara.jp","higashiyoshino.nara.jp","ikaruga.nara.jp","ikoma.nara.jp","kamikitayama.nara.jp","kanmaki.nara.jp","kashiba.nara.jp","kashihara.nara.jp","katsuragi.nara.jp","kawai.nara.jp","kawakami.nara.jp","kawanishi.nara.jp","koryo.nara.jp","kurotaki.nara.jp","mitsue.nara.jp","miyake.nara.jp","nara.nara.jp","nosegawa.nara.jp","oji.nara.jp","ouda.nara.jp","oyodo.nara.jp","sakurai.nara.jp","sango.nara.jp","shimoichi.nara.jp","shimokitayama.nara.jp","shinjo.nara.jp","soni.nara.jp","takatori.nara.jp","tawaramoto.nara.jp","tenkawa.nara.jp","tenri.nara.jp","uda.nara.jp","yamatokoriyama.nara.jp","yamatotakada.nara.jp","yamazoe.nara.jp","yoshino.nara.jp","aga.niigata.jp","agano.niigata.jp","gosen.niigata.jp","itoigawa.niigata.jp","izumozaki.niigata.jp","joetsu.niigata.jp","kamo.niigata.jp","kariwa.niigata.jp","kashiwazaki.niigata.jp","minamiuonuma.niigata.jp","mitsuke.niigata.jp","muika.niigata.jp","murakami.niigata.jp","myoko.niigata.jp","nagaoka.niigata.jp","niigata.niigata.jp","ojiya.niigata.jp","omi.niigata.jp","sado.niigata.jp","sanjo.niigata.jp","seiro.niigata.jp","seirou.niigata.jp","sekikawa.niigata.jp","shibata.niigata.jp","tagami.niigata.jp","tainai.niigata.jp","tochio.niigata.jp","tokamachi.niigata.jp","tsubame.niigata.jp","tsunan.niigata.jp","uonuma.niigata.jp","yahiko.niigata.jp","yoita.niigata.jp","yuzawa.niigata.jp","beppu.oita.jp","bungoono.oita.jp","bungotakada.oita.jp","hasama.oita.jp","hiji.oita.jp","himeshima.oita.jp","hita.oita.jp","kamitsue.oita.jp","kokonoe.oita.jp","kuju.oita.jp","kunisaki.oita.jp","kusu.oita.jp","oita.oita.jp","saiki.oita.jp","taketa.oita.jp","tsukumi.oita.jp","usa.oita.jp","usuki.oita.jp","yufu.oita.jp","akaiwa.okayama.jp","asakuchi.okayama.jp","bizen.okayama.jp","hayashima.okayama.jp","ibara.okayama.jp","kagamino.okayama.jp","kasaoka.okayama.jp","kibichuo.okayama.jp","kumenan.okayama.jp","kurashiki.okayama.jp","maniwa.okayama.jp","misaki.okayama.jp","nagi.okayama.jp","niimi.okayama.jp","nishiawakura.okayama.jp","okayama.okayama.jp","satosho.okayama.jp","setouchi.okayama.jp","shinjo.okayama.jp","shoo.okayama.jp","soja.okayama.jp","takahashi.okayama.jp","tamano.okayama.jp","tsuyama.okayama.jp","wake.okayama.jp","yakage.okayama.jp","aguni.okinawa.jp","ginowan.okinawa.jp","ginoza.okinawa.jp","gushikami.okinawa.jp","haebaru.okinawa.jp","higashi.okinawa.jp","hirara.okinawa.jp","iheya.okinawa.jp","ishigaki.okinawa.jp","ishikawa.okinawa.jp","itoman.okinawa.jp","izena.okinawa.jp","kadena.okinawa.jp","kin.okinawa.jp","kitadaito.okinawa.jp","kitanakagusuku.okinawa.jp","kumejima.okinawa.jp","kunigami.okinawa.jp","minamidaito.okinawa.jp","motobu.okinawa.jp","nago.okinawa.jp","naha.okinawa.jp","nakagusuku.okinawa.jp","nakijin.okinawa.jp","nanjo.okinawa.jp","nishihara.okinawa.jp","ogimi.okinawa.jp","okinawa.okinawa.jp","onna.okinawa.jp","shimoji.okinawa.jp","taketomi.okinawa.jp","tarama.okinawa.jp","tokashiki.okinawa.jp","tomigusuku.okinawa.jp","tonaki.okinawa.jp","urasoe.okinawa.jp","uruma.okinawa.jp","yaese.okinawa.jp","yomitan.okinawa.jp","yonabaru.okinawa.jp","yonaguni.okinawa.jp","zamami.okinawa.jp","abeno.osaka.jp","chihayaakasaka.osaka.jp","chuo.osaka.jp","daito.osaka.jp","fujiidera.osaka.jp","habikino.osaka.jp","hannan.osaka.jp","higashiosaka.osaka.jp","higashisumiyoshi.osaka.jp","higashiyodogawa.osaka.jp","hirakata.osaka.jp","ibaraki.osaka.jp","ikeda.osaka.jp","izumi.osaka.jp","izumiotsu.osaka.jp","izumisano.osaka.jp","kadoma.osaka.jp","kaizuka.osaka.jp","kanan.osaka.jp","kashiwara.osaka.jp","katano.osaka.jp","kawachinagano.osaka.jp","kishiwada.osaka.jp","kita.osaka.jp","kumatori.osaka.jp","matsubara.osaka.jp","minato.osaka.jp","minoh.osaka.jp","misaki.osaka.jp","moriguchi.osaka.jp","neyagawa.osaka.jp","nishi.osaka.jp","nose.osaka.jp","osakasayama.osaka.jp","sakai.osaka.jp","sayama.osaka.jp","sennan.osaka.jp","settsu.osaka.jp","shijonawate.osaka.jp","shimamoto.osaka.jp","suita.osaka.jp","tadaoka.osaka.jp","taishi.osaka.jp","tajiri.osaka.jp","takaishi.osaka.jp","takatsuki.osaka.jp","tondabayashi.osaka.jp","toyonaka.osaka.jp","toyono.osaka.jp","yao.osaka.jp","ariake.saga.jp","arita.saga.jp","fukudomi.saga.jp","genkai.saga.jp","hamatama.saga.jp","hizen.saga.jp","imari.saga.jp","kamimine.saga.jp","kanzaki.saga.jp","karatsu.saga.jp","kashima.saga.jp","kitagata.saga.jp","kitahata.saga.jp","kiyama.saga.jp","kouhoku.saga.jp","kyuragi.saga.jp","nishiarita.saga.jp","ogi.saga.jp","omachi.saga.jp","ouchi.saga.jp","saga.saga.jp","shiroishi.saga.jp","taku.saga.jp","tara.saga.jp","tosu.saga.jp","yoshinogari.saga.jp","arakawa.saitama.jp","asaka.saitama.jp","chichibu.saitama.jp","fujimi.saitama.jp","fujimino.saitama.jp","fukaya.saitama.jp","hanno.saitama.jp","hanyu.saitama.jp","hasuda.saitama.jp","hatogaya.saitama.jp","hatoyama.saitama.jp","hidaka.saitama.jp","higashichichibu.saitama.jp","higashimatsuyama.saitama.jp","honjo.saitama.jp","ina.saitama.jp","iruma.saitama.jp","iwatsuki.saitama.jp","kamiizumi.saitama.jp","kamikawa.saitama.jp","kamisato.saitama.jp","kasukabe.saitama.jp","kawagoe.saitama.jp","kawaguchi.saitama.jp","kawajima.saitama.jp","kazo.saitama.jp","kitamoto.saitama.jp","koshigaya.saitama.jp","kounosu.saitama.jp","kuki.saitama.jp","kumagaya.saitama.jp","matsubushi.saitama.jp","minano.saitama.jp","misato.saitama.jp","miyashiro.saitama.jp","miyoshi.saitama.jp","moroyama.saitama.jp","nagatoro.saitama.jp","namegawa.saitama.jp","niiza.saitama.jp","ogano.saitama.jp","ogawa.saitama.jp","ogose.saitama.jp","okegawa.saitama.jp","omiya.saitama.jp","otaki.saitama.jp","ranzan.saitama.jp","ryokami.saitama.jp","saitama.saitama.jp","sakado.saitama.jp","satte.saitama.jp","sayama.saitama.jp","shiki.saitama.jp","shiraoka.saitama.jp","soka.saitama.jp","sugito.saitama.jp","toda.saitama.jp","tokigawa.saitama.jp","tokorozawa.saitama.jp","tsurugashima.saitama.jp","urawa.saitama.jp","warabi.saitama.jp","yashio.saitama.jp","yokoze.saitama.jp","yono.saitama.jp","yorii.saitama.jp","yoshida.saitama.jp","yoshikawa.saitama.jp","yoshimi.saitama.jp","aisho.shiga.jp","gamo.shiga.jp","higashiomi.shiga.jp","hikone.shiga.jp","koka.shiga.jp","konan.shiga.jp","kosei.shiga.jp","koto.shiga.jp","kusatsu.shiga.jp","maibara.shiga.jp","moriyama.shiga.jp","nagahama.shiga.jp","nishiazai.shiga.jp","notogawa.shiga.jp","omihachiman.shiga.jp","otsu.shiga.jp","ritto.shiga.jp","ryuoh.shiga.jp","takashima.shiga.jp","takatsuki.shiga.jp","torahime.shiga.jp","toyosato.shiga.jp","yasu.shiga.jp","akagi.shimane.jp","ama.shimane.jp","gotsu.shimane.jp","hamada.shimane.jp","higashiizumo.shimane.jp","hikawa.shimane.jp","hikimi.shimane.jp","izumo.shimane.jp","kakinoki.shimane.jp","masuda.shimane.jp","matsue.shimane.jp","misato.shimane.jp","nishinoshima.shimane.jp","ohda.shimane.jp","okinoshima.shimane.jp","okuizumo.shimane.jp","shimane.shimane.jp","tamayu.shimane.jp","tsuwano.shimane.jp","unnan.shimane.jp","yakumo.shimane.jp","yasugi.shimane.jp","yatsuka.shimane.jp","arai.shizuoka.jp","atami.shizuoka.jp","fuji.shizuoka.jp","fujieda.shizuoka.jp","fujikawa.shizuoka.jp","fujinomiya.shizuoka.jp","fukuroi.shizuoka.jp","gotemba.shizuoka.jp","haibara.shizuoka.jp","hamamatsu.shizuoka.jp","higashiizu.shizuoka.jp","ito.shizuoka.jp","iwata.shizuoka.jp","izu.shizuoka.jp","izunokuni.shizuoka.jp","kakegawa.shizuoka.jp","kannami.shizuoka.jp","kawanehon.shizuoka.jp","kawazu.shizuoka.jp","kikugawa.shizuoka.jp","kosai.shizuoka.jp","makinohara.shizuoka.jp","matsuzaki.shizuoka.jp","minamiizu.shizuoka.jp","mishima.shizuoka.jp","morimachi.shizuoka.jp","nishiizu.shizuoka.jp","numazu.shizuoka.jp","omaezaki.shizuoka.jp","shimada.shizuoka.jp","shimizu.shizuoka.jp","shimoda.shizuoka.jp","shizuoka.shizuoka.jp","susono.shizuoka.jp","yaizu.shizuoka.jp","yoshida.shizuoka.jp","ashikaga.tochigi.jp","bato.tochigi.jp","haga.tochigi.jp","ichikai.tochigi.jp","iwafune.tochigi.jp","kaminokawa.tochigi.jp","kanuma.tochigi.jp","karasuyama.tochigi.jp","kuroiso.tochigi.jp","mashiko.tochigi.jp","mibu.tochigi.jp","moka.tochigi.jp","motegi.tochigi.jp","nasu.tochigi.jp","nasushiobara.tochigi.jp","nikko.tochigi.jp","nishikata.tochigi.jp","nogi.tochigi.jp","ohira.tochigi.jp","ohtawara.tochigi.jp","oyama.tochigi.jp","sakura.tochigi.jp","sano.tochigi.jp","shimotsuke.tochigi.jp","shioya.tochigi.jp","takanezawa.tochigi.jp","tochigi.tochigi.jp","tsuga.tochigi.jp","ujiie.tochigi.jp","utsunomiya.tochigi.jp","yaita.tochigi.jp","aizumi.tokushima.jp","anan.tokushima.jp","ichiba.tokushima.jp","itano.tokushima.jp","kainan.tokushima.jp","komatsushima.tokushima.jp","matsushige.tokushima.jp","mima.tokushima.jp","minami.tokushima.jp","miyoshi.tokushima.jp","mugi.tokushima.jp","nakagawa.tokushima.jp","naruto.tokushima.jp","sanagochi.tokushima.jp","shishikui.tokushima.jp","tokushima.tokushima.jp","wajiki.tokushima.jp","adachi.tokyo.jp","akiruno.tokyo.jp","akishima.tokyo.jp","aogashima.tokyo.jp","arakawa.tokyo.jp","bunkyo.tokyo.jp","chiyoda.tokyo.jp","chofu.tokyo.jp","chuo.tokyo.jp","edogawa.tokyo.jp","fuchu.tokyo.jp","fussa.tokyo.jp","hachijo.tokyo.jp","hachioji.tokyo.jp","hamura.tokyo.jp","higashikurume.tokyo.jp","higashimurayama.tokyo.jp","higashiyamato.tokyo.jp","hino.tokyo.jp","hinode.tokyo.jp","hinohara.tokyo.jp","inagi.tokyo.jp","itabashi.tokyo.jp","katsushika.tokyo.jp","kita.tokyo.jp","kiyose.tokyo.jp","kodaira.tokyo.jp","koganei.tokyo.jp","kokubunji.tokyo.jp","komae.tokyo.jp","koto.tokyo.jp","kouzushima.tokyo.jp","kunitachi.tokyo.jp","machida.tokyo.jp","meguro.tokyo.jp","minato.tokyo.jp","mitaka.tokyo.jp","mizuho.tokyo.jp","musashimurayama.tokyo.jp","musashino.tokyo.jp","nakano.tokyo.jp","nerima.tokyo.jp","ogasawara.tokyo.jp","okutama.tokyo.jp","ome.tokyo.jp","oshima.tokyo.jp","ota.tokyo.jp","setagaya.tokyo.jp","shibuya.tokyo.jp","shinagawa.tokyo.jp","shinjuku.tokyo.jp","suginami.tokyo.jp","sumida.tokyo.jp","tachikawa.tokyo.jp","taito.tokyo.jp","tama.tokyo.jp","toshima.tokyo.jp","chizu.tottori.jp","hino.tottori.jp","kawahara.tottori.jp","koge.tottori.jp","kotoura.tottori.jp","misasa.tottori.jp","nanbu.tottori.jp","nichinan.tottori.jp","sakaiminato.tottori.jp","tottori.tottori.jp","wakasa.tottori.jp","yazu.tottori.jp","yonago.tottori.jp","asahi.toyama.jp","fuchu.toyama.jp","fukumitsu.toyama.jp","funahashi.toyama.jp","himi.toyama.jp","imizu.toyama.jp","inami.toyama.jp","johana.toyama.jp","kamiichi.toyama.jp","kurobe.toyama.jp","nakaniikawa.toyama.jp","namerikawa.toyama.jp","nanto.toyama.jp","nyuzen.toyama.jp","oyabe.toyama.jp","taira.toyama.jp","takaoka.toyama.jp","tateyama.toyama.jp","toga.toyama.jp","tonami.toyama.jp","toyama.toyama.jp","unazuki.toyama.jp","uozu.toyama.jp","yamada.toyama.jp","arida.wakayama.jp","aridagawa.wakayama.jp","gobo.wakayama.jp","hashimoto.wakayama.jp","hidaka.wakayama.jp","hirogawa.wakayama.jp","inami.wakayama.jp","iwade.wakayama.jp","kainan.wakayama.jp","kamitonda.wakayama.jp","katsuragi.wakayama.jp","kimino.wakayama.jp","kinokawa.wakayama.jp","kitayama.wakayama.jp","koya.wakayama.jp","koza.wakayama.jp","kozagawa.wakayama.jp","kudoyama.wakayama.jp","kushimoto.wakayama.jp","mihama.wakayama.jp","misato.wakayama.jp","nachikatsuura.wakayama.jp","shingu.wakayama.jp","shirahama.wakayama.jp","taiji.wakayama.jp","tanabe.wakayama.jp","wakayama.wakayama.jp","yuasa.wakayama.jp","yura.wakayama.jp","asahi.yamagata.jp","funagata.yamagata.jp","higashine.yamagata.jp","iide.yamagata.jp","kahoku.yamagata.jp","kaminoyama.yamagata.jp","kaneyama.yamagata.jp","kawanishi.yamagata.jp","mamurogawa.yamagata.jp","mikawa.yamagata.jp","murayama.yamagata.jp","nagai.yamagata.jp","nakayama.yamagata.jp","nanyo.yamagata.jp","nishikawa.yamagata.jp","obanazawa.yamagata.jp","oe.yamagata.jp","oguni.yamagata.jp","ohkura.yamagata.jp","oishida.yamagata.jp","sagae.yamagata.jp","sakata.yamagata.jp","sakegawa.yamagata.jp","shinjo.yamagata.jp","shirataka.yamagata.jp","shonai.yamagata.jp","takahata.yamagata.jp","tendo.yamagata.jp","tozawa.yamagata.jp","tsuruoka.yamagata.jp","yamagata.yamagata.jp","yamanobe.yamagata.jp","yonezawa.yamagata.jp","yuza.yamagata.jp","abu.yamaguchi.jp","hagi.yamaguchi.jp","hikari.yamaguchi.jp","hofu.yamaguchi.jp","iwakuni.yamaguchi.jp","kudamatsu.yamaguchi.jp","mitou.yamaguchi.jp","nagato.yamaguchi.jp","oshima.yamaguchi.jp","shimonoseki.yamaguchi.jp","shunan.yamaguchi.jp","tabuse.yamaguchi.jp","tokuyama.yamaguchi.jp","toyota.yamaguchi.jp","ube.yamaguchi.jp","yuu.yamaguchi.jp","chuo.yamanashi.jp","doshi.yamanashi.jp","fuefuki.yamanashi.jp","fujikawa.yamanashi.jp","fujikawaguchiko.yamanashi.jp","fujiyoshida.yamanashi.jp","hayakawa.yamanashi.jp","hokuto.yamanashi.jp","ichikawamisato.yamanashi.jp","kai.yamanashi.jp","kofu.yamanashi.jp","koshu.yamanashi.jp","kosuge.yamanashi.jp","minami-alps.yamanashi.jp","minobu.yamanashi.jp","nakamichi.yamanashi.jp","nanbu.yamanashi.jp","narusawa.yamanashi.jp","nirasaki.yamanashi.jp","nishikatsura.yamanashi.jp","oshino.yamanashi.jp","otsuki.yamanashi.jp","showa.yamanashi.jp","tabayama.yamanashi.jp","tsuru.yamanashi.jp","uenohara.yamanashi.jp","yamanakako.yamanashi.jp","yamanashi.yamanashi.jp","ke","ac.ke","co.ke","go.ke","info.ke","me.ke","mobi.ke","ne.ke","or.ke","sc.ke","kg","org.kg","net.kg","com.kg","edu.kg","gov.kg","mil.kg","*.kh","ki","edu.ki","biz.ki","net.ki","org.ki","gov.ki","info.ki","com.ki","km","org.km","nom.km","gov.km","prd.km","tm.km","edu.km","mil.km","ass.km","com.km","coop.km","asso.km","presse.km","medecin.km","notaires.km","pharmaciens.km","veterinaire.km","gouv.km","kn","net.kn","org.kn","edu.kn","gov.kn","kp","com.kp","edu.kp","gov.kp","org.kp","rep.kp","tra.kp","kr","ac.kr","co.kr","es.kr","go.kr","hs.kr","kg.kr","mil.kr","ms.kr","ne.kr","or.kr","pe.kr","re.kr","sc.kr","busan.kr","chungbuk.kr","chungnam.kr","daegu.kr","daejeon.kr","gangwon.kr","gwangju.kr","gyeongbuk.kr","gyeonggi.kr","gyeongnam.kr","incheon.kr","jeju.kr","jeonbuk.kr","jeonnam.kr","seoul.kr","ulsan.kr","kw","com.kw","edu.kw","emb.kw","gov.kw","ind.kw","net.kw","org.kw","ky","com.ky","edu.ky","net.ky","org.ky","kz","org.kz","edu.kz","net.kz","gov.kz","mil.kz","com.kz","la","int.la","net.la","info.la","edu.la","gov.la","per.la","com.la","org.la","lb","com.lb","edu.lb","gov.lb","net.lb","org.lb","lc","com.lc","net.lc","co.lc","org.lc","edu.lc","gov.lc","li","lk","gov.lk","sch.lk","net.lk","int.lk","com.lk","org.lk","edu.lk","ngo.lk","soc.lk","web.lk","ltd.lk","assn.lk","grp.lk","hotel.lk","ac.lk","lr","com.lr","edu.lr","gov.lr","org.lr","net.lr","ls","ac.ls","biz.ls","co.ls","edu.ls","gov.ls","info.ls","net.ls","org.ls","sc.ls","lt","gov.lt","lu","lv","com.lv","edu.lv","gov.lv","org.lv","mil.lv","id.lv","net.lv","asn.lv","conf.lv","ly","com.ly","net.ly","gov.ly","plc.ly","edu.ly","sch.ly","med.ly","org.ly","id.ly","ma","co.ma","net.ma","gov.ma","org.ma","ac.ma","press.ma","mc","tm.mc","asso.mc","md","me","co.me","net.me","org.me","edu.me","ac.me","gov.me","its.me","priv.me","mg","org.mg","nom.mg","gov.mg","prd.mg","tm.mg","edu.mg","mil.mg","com.mg","co.mg","mh","mil","mk","com.mk","org.mk","net.mk","edu.mk","gov.mk","inf.mk","name.mk","ml","com.ml","edu.ml","gouv.ml","gov.ml","net.ml","org.ml","presse.ml","*.mm","mn","gov.mn","edu.mn","org.mn","mo","com.mo","net.mo","org.mo","edu.mo","gov.mo","mobi","mp","mq","mr","gov.mr","ms","com.ms","edu.ms","gov.ms","net.ms","org.ms","mt","com.mt","edu.mt","net.mt","org.mt","mu","com.mu","net.mu","org.mu","gov.mu","ac.mu","co.mu","or.mu","museum","academy.museum","agriculture.museum","air.museum","airguard.museum","alabama.museum","alaska.museum","amber.museum","ambulance.museum","american.museum","americana.museum","americanantiques.museum","americanart.museum","amsterdam.museum","and.museum","annefrank.museum","anthro.museum","anthropology.museum","antiques.museum","aquarium.museum","arboretum.museum","archaeological.museum","archaeology.museum","architecture.museum","art.museum","artanddesign.museum","artcenter.museum","artdeco.museum","arteducation.museum","artgallery.museum","arts.museum","artsandcrafts.museum","asmatart.museum","assassination.museum","assisi.museum","association.museum","astronomy.museum","atlanta.museum","austin.museum","australia.museum","automotive.museum","aviation.museum","axis.museum","badajoz.museum","baghdad.museum","bahn.museum","bale.museum","baltimore.museum","barcelona.museum","baseball.museum","basel.museum","baths.museum","bauern.museum","beauxarts.museum","beeldengeluid.museum","bellevue.museum","bergbau.museum","berkeley.museum","berlin.museum","bern.museum","bible.museum","bilbao.museum","bill.museum","birdart.museum","birthplace.museum","bonn.museum","boston.museum","botanical.museum","botanicalgarden.museum","botanicgarden.museum","botany.museum","brandywinevalley.museum","brasil.museum","bristol.museum","british.museum","britishcolumbia.museum","broadcast.museum","brunel.museum","brussel.museum","brussels.museum","bruxelles.museum","building.museum","burghof.museum","bus.museum","bushey.museum","cadaques.museum","california.museum","cambridge.museum","can.museum","canada.museum","capebreton.museum","carrier.museum","cartoonart.museum","casadelamoneda.museum","castle.museum","castres.museum","celtic.museum","center.museum","chattanooga.museum","cheltenham.museum","chesapeakebay.museum","chicago.museum","children.museum","childrens.museum","childrensgarden.museum","chiropractic.museum","chocolate.museum","christiansburg.museum","cincinnati.museum","cinema.museum","circus.museum","civilisation.museum","civilization.museum","civilwar.museum","clinton.museum","clock.museum","coal.museum","coastaldefence.museum","cody.museum","coldwar.museum","collection.museum","colonialwilliamsburg.museum","coloradoplateau.museum","columbia.museum","columbus.museum","communication.museum","communications.museum","community.museum","computer.museum","computerhistory.museum","comunicações.museum","contemporary.museum","contemporaryart.museum","convent.museum","copenhagen.museum","corporation.museum","correios-e-telecomunicações.museum","corvette.museum","costume.museum","countryestate.museum","county.museum","crafts.museum","cranbrook.museum","creation.museum","cultural.museum","culturalcenter.museum","culture.museum","cyber.museum","cymru.museum","dali.museum","dallas.museum","database.museum","ddr.museum","decorativearts.museum","delaware.museum","delmenhorst.museum","denmark.museum","depot.museum","design.museum","detroit.museum","dinosaur.museum","discovery.museum","dolls.museum","donostia.museum","durham.museum","eastafrica.museum","eastcoast.museum","education.museum","educational.museum","egyptian.museum","eisenbahn.museum","elburg.museum","elvendrell.museum","embroidery.museum","encyclopedic.museum","england.museum","entomology.museum","environment.museum","environmentalconservation.museum","epilepsy.museum","essex.museum","estate.museum","ethnology.museum","exeter.museum","exhibition.museum","family.museum","farm.museum","farmequipment.museum","farmers.museum","farmstead.museum","field.museum","figueres.museum","filatelia.museum","film.museum","fineart.museum","finearts.museum","finland.museum","flanders.museum","florida.museum","force.museum","fortmissoula.museum","fortworth.museum","foundation.museum","francaise.museum","frankfurt.museum","franziskaner.museum","freemasonry.museum","freiburg.museum","fribourg.museum","frog.museum","fundacio.museum","furniture.museum","gallery.museum","garden.museum","gateway.museum","geelvinck.museum","gemological.museum","geology.museum","georgia.museum","giessen.museum","glas.museum","glass.museum","gorge.museum","grandrapids.museum","graz.museum","guernsey.museum","halloffame.museum","hamburg.museum","handson.museum","harvestcelebration.museum","hawaii.museum","health.museum","heimatunduhren.museum","hellas.museum","helsinki.museum","hembygdsforbund.museum","heritage.museum","histoire.museum","historical.museum","historicalsociety.museum","historichouses.museum","historisch.museum","historisches.museum","history.museum","historyofscience.museum","horology.museum","house.museum","humanities.museum","illustration.museum","imageandsound.museum","indian.museum","indiana.museum","indianapolis.museum","indianmarket.museum","intelligence.museum","interactive.museum","iraq.museum","iron.museum","isleofman.museum","jamison.museum","jefferson.museum","jerusalem.museum","jewelry.museum","jewish.museum","jewishart.museum","jfk.museum","journalism.museum","judaica.museum","judygarland.museum","juedisches.museum","juif.museum","karate.museum","karikatur.museum","kids.museum","koebenhavn.museum","koeln.museum","kunst.museum","kunstsammlung.museum","kunstunddesign.museum","labor.museum","labour.museum","lajolla.museum","lancashire.museum","landes.museum","lans.museum","läns.museum","larsson.museum","lewismiller.museum","lincoln.museum","linz.museum","living.museum","livinghistory.museum","localhistory.museum","london.museum","losangeles.museum","louvre.museum","loyalist.museum","lucerne.museum","luxembourg.museum","luzern.museum","mad.museum","madrid.museum","mallorca.museum","manchester.museum","mansion.museum","mansions.museum","manx.museum","marburg.museum","maritime.museum","maritimo.museum","maryland.museum","marylhurst.museum","media.museum","medical.museum","medizinhistorisches.museum","meeres.museum","memorial.museum","mesaverde.museum","michigan.museum","midatlantic.museum","military.museum","mill.museum","miners.museum","mining.museum","minnesota.museum","missile.museum","missoula.museum","modern.museum","moma.museum","money.museum","monmouth.museum","monticello.museum","montreal.museum","moscow.museum","motorcycle.museum","muenchen.museum","muenster.museum","mulhouse.museum","muncie.museum","museet.museum","museumcenter.museum","museumvereniging.museum","music.museum","national.museum","nationalfirearms.museum","nationalheritage.museum","nativeamerican.museum","naturalhistory.museum","naturalhistorymuseum.museum","naturalsciences.museum","nature.museum","naturhistorisches.museum","natuurwetenschappen.museum","naumburg.museum","naval.museum","nebraska.museum","neues.museum","newhampshire.museum","newjersey.museum","newmexico.museum","newport.museum","newspaper.museum","newyork.museum","niepce.museum","norfolk.museum","north.museum","nrw.museum","nyc.museum","nyny.museum","oceanographic.museum","oceanographique.museum","omaha.museum","online.museum","ontario.museum","openair.museum","oregon.museum","oregontrail.museum","otago.museum","oxford.museum","pacific.museum","paderborn.museum","palace.museum","paleo.museum","palmsprings.museum","panama.museum","paris.museum","pasadena.museum","pharmacy.museum","philadelphia.museum","philadelphiaarea.museum","philately.museum","phoenix.museum","photography.museum","pilots.museum","pittsburgh.museum","planetarium.museum","plantation.museum","plants.museum","plaza.museum","portal.museum","portland.museum","portlligat.museum","posts-and-telecommunications.museum","preservation.museum","presidio.museum","press.museum","project.museum","public.museum","pubol.museum","quebec.museum","railroad.museum","railway.museum","research.museum","resistance.museum","riodejaneiro.museum","rochester.museum","rockart.museum","roma.museum","russia.museum","saintlouis.museum","salem.museum","salvadordali.museum","salzburg.museum","sandiego.museum","sanfrancisco.museum","santabarbara.museum","santacruz.museum","santafe.museum","saskatchewan.museum","satx.museum","savannahga.museum","schlesisches.museum","schoenbrunn.museum","schokoladen.museum","school.museum","schweiz.museum","science.museum","scienceandhistory.museum","scienceandindustry.museum","sciencecenter.museum","sciencecenters.museum","science-fiction.museum","sciencehistory.museum","sciences.museum","sciencesnaturelles.museum","scotland.museum","seaport.museum","settlement.museum","settlers.museum","shell.museum","sherbrooke.museum","sibenik.museum","silk.museum","ski.museum","skole.museum","society.museum","sologne.museum","soundandvision.museum","southcarolina.museum","southwest.museum","space.museum","spy.museum","square.museum","stadt.museum","stalbans.museum","starnberg.museum","state.museum","stateofdelaware.museum","station.museum","steam.museum","steiermark.museum","stjohn.museum","stockholm.museum","stpetersburg.museum","stuttgart.museum","suisse.museum","surgeonshall.museum","surrey.museum","svizzera.museum","sweden.museum","sydney.museum","tank.museum","tcm.museum","technology.museum","telekommunikation.museum","television.museum","texas.museum","textile.museum","theater.museum","time.museum","timekeeping.museum","topology.museum","torino.museum","touch.museum","town.museum","transport.museum","tree.museum","trolley.museum","trust.museum","trustee.museum","uhren.museum","ulm.museum","undersea.museum","university.museum","usa.museum","usantiques.museum","usarts.museum","uscountryestate.museum","usculture.museum","usdecorativearts.museum","usgarden.museum","ushistory.museum","ushuaia.museum","uslivinghistory.museum","utah.museum","uvic.museum","valley.museum","vantaa.museum","versailles.museum","viking.museum","village.museum","virginia.museum","virtual.museum","virtuel.museum","vlaanderen.museum","volkenkunde.museum","wales.museum","wallonie.museum","war.museum","washingtondc.museum","watchandclock.museum","watch-and-clock.museum","western.museum","westfalen.museum","whaling.museum","wildlife.museum","williamsburg.museum","windmill.museum","workshop.museum","york.museum","yorkshire.museum","yosemite.museum","youth.museum","zoological.museum","zoology.museum","ירושלים.museum","иком.museum","mv","aero.mv","biz.mv","com.mv","coop.mv","edu.mv","gov.mv","info.mv","int.mv","mil.mv","museum.mv","name.mv","net.mv","org.mv","pro.mv","mw","ac.mw","biz.mw","co.mw","com.mw","coop.mw","edu.mw","gov.mw","int.mw","museum.mw","net.mw","org.mw","mx","com.mx","org.mx","gob.mx","edu.mx","net.mx","my","biz.my","com.my","edu.my","gov.my","mil.my","name.my","net.my","org.my","mz","ac.mz","adv.mz","co.mz","edu.mz","gov.mz","mil.mz","net.mz","org.mz","na","info.na","pro.na","name.na","school.na","or.na","dr.na","us.na","mx.na","ca.na","in.na","cc.na","tv.na","ws.na","mobi.na","co.na","com.na","org.na","name","nc","asso.nc","nom.nc","ne","net","nf","com.nf","net.nf","per.nf","rec.nf","web.nf","arts.nf","firm.nf","info.nf","other.nf","store.nf","ng","com.ng","edu.ng","gov.ng","i.ng","mil.ng","mobi.ng","name.ng","net.ng","org.ng","sch.ng","ni","ac.ni","biz.ni","co.ni","com.ni","edu.ni","gob.ni","in.ni","info.ni","int.ni","mil.ni","net.ni","nom.ni","org.ni","web.ni","nl","no","fhs.no","vgs.no","fylkesbibl.no","folkebibl.no","museum.no","idrett.no","priv.no","mil.no","stat.no","dep.no","kommune.no","herad.no","aa.no","ah.no","bu.no","fm.no","hl.no","hm.no","jan-mayen.no","mr.no","nl.no","nt.no","of.no","ol.no","oslo.no","rl.no","sf.no","st.no","svalbard.no","tm.no","tr.no","va.no","vf.no","gs.aa.no","gs.ah.no","gs.bu.no","gs.fm.no","gs.hl.no","gs.hm.no","gs.jan-mayen.no","gs.mr.no","gs.nl.no","gs.nt.no","gs.of.no","gs.ol.no","gs.oslo.no","gs.rl.no","gs.sf.no","gs.st.no","gs.svalbard.no","gs.tm.no","gs.tr.no","gs.va.no","gs.vf.no","akrehamn.no","åkrehamn.no","algard.no","ålgård.no","arna.no","brumunddal.no","bryne.no","bronnoysund.no","brønnøysund.no","drobak.no","drøbak.no","egersund.no","fetsund.no","floro.no","florø.no","fredrikstad.no","hokksund.no","honefoss.no","hønefoss.no","jessheim.no","jorpeland.no","jørpeland.no","kirkenes.no","kopervik.no","krokstadelva.no","langevag.no","langevåg.no","leirvik.no","mjondalen.no","mjøndalen.no","mo-i-rana.no","mosjoen.no","mosjøen.no","nesoddtangen.no","orkanger.no","osoyro.no","osøyro.no","raholt.no","råholt.no","sandnessjoen.no","sandnessjøen.no","skedsmokorset.no","slattum.no","spjelkavik.no","stathelle.no","stavern.no","stjordalshalsen.no","stjørdalshalsen.no","tananger.no","tranby.no","vossevangen.no","afjord.no","åfjord.no","agdenes.no","al.no","ål.no","alesund.no","ålesund.no","alstahaug.no","alta.no","áltá.no","alaheadju.no","álaheadju.no","alvdal.no","amli.no","åmli.no","amot.no","åmot.no","andebu.no","andoy.no","andøy.no","andasuolo.no","ardal.no","årdal.no","aremark.no","arendal.no","ås.no","aseral.no","åseral.no","asker.no","askim.no","askvoll.no","askoy.no","askøy.no","asnes.no","åsnes.no","audnedaln.no","aukra.no","aure.no","aurland.no","aurskog-holand.no","aurskog-høland.no","austevoll.no","austrheim.no","averoy.no","averøy.no","balestrand.no","ballangen.no","balat.no","bálát.no","balsfjord.no","bahccavuotna.no","báhccavuotna.no","bamble.no","bardu.no","beardu.no","beiarn.no","bajddar.no","bájddar.no","baidar.no","báidár.no","berg.no","bergen.no","berlevag.no","berlevåg.no","bearalvahki.no","bearalváhki.no","bindal.no","birkenes.no","bjarkoy.no","bjarkøy.no","bjerkreim.no","bjugn.no","bodo.no","bodø.no","badaddja.no","bådåddjå.no","budejju.no","bokn.no","bremanger.no","bronnoy.no","brønnøy.no","bygland.no","bykle.no","barum.no","bærum.no","bo.telemark.no","bø.telemark.no","bo.nordland.no","bø.nordland.no","bievat.no","bievát.no","bomlo.no","bømlo.no","batsfjord.no","båtsfjord.no","bahcavuotna.no","báhcavuotna.no","dovre.no","drammen.no","drangedal.no","dyroy.no","dyrøy.no","donna.no","dønna.no","eid.no","eidfjord.no","eidsberg.no","eidskog.no","eidsvoll.no","eigersund.no","elverum.no","enebakk.no","engerdal.no","etne.no","etnedal.no","evenes.no","evenassi.no","evenášši.no","evje-og-hornnes.no","farsund.no","fauske.no","fuossko.no","fuoisku.no","fedje.no","fet.no","finnoy.no","finnøy.no","fitjar.no","fjaler.no","fjell.no","flakstad.no","flatanger.no","flekkefjord.no","flesberg.no","flora.no","fla.no","flå.no","folldal.no","forsand.no","fosnes.no","frei.no","frogn.no","froland.no","frosta.no","frana.no","fræna.no","froya.no","frøya.no","fusa.no","fyresdal.no","forde.no","førde.no","gamvik.no","gangaviika.no","gáŋgaviika.no","gaular.no","gausdal.no","gildeskal.no","gildeskål.no","giske.no","gjemnes.no","gjerdrum.no","gjerstad.no","gjesdal.no","gjovik.no","gjøvik.no","gloppen.no","gol.no","gran.no","grane.no","granvin.no","gratangen.no","grimstad.no","grong.no","kraanghke.no","kråanghke.no","grue.no","gulen.no","hadsel.no","halden.no","halsa.no","hamar.no","hamaroy.no","habmer.no","hábmer.no","hapmir.no","hápmir.no","hammerfest.no","hammarfeasta.no","hámmárfeasta.no","haram.no","hareid.no","harstad.no","hasvik.no","aknoluokta.no","ákŋoluokta.no","hattfjelldal.no","aarborte.no","haugesund.no","hemne.no","hemnes.no","hemsedal.no","heroy.more-og-romsdal.no","herøy.møre-og-romsdal.no","heroy.nordland.no","herøy.nordland.no","hitra.no","hjartdal.no","hjelmeland.no","hobol.no","hobøl.no","hof.no","hol.no","hole.no","holmestrand.no","holtalen.no","holtålen.no","hornindal.no","horten.no","hurdal.no","hurum.no","hvaler.no","hyllestad.no","hagebostad.no","hægebostad.no","hoyanger.no","høyanger.no","hoylandet.no","høylandet.no","ha.no","hå.no","ibestad.no","inderoy.no","inderøy.no","iveland.no","jevnaker.no","jondal.no","jolster.no","jølster.no","karasjok.no","karasjohka.no","kárášjohka.no","karlsoy.no","galsa.no","gálsá.no","karmoy.no","karmøy.no","kautokeino.no","guovdageaidnu.no","klepp.no","klabu.no","klæbu.no","kongsberg.no","kongsvinger.no","kragero.no","kragerø.no","kristiansand.no","kristiansund.no","krodsherad.no","krødsherad.no","kvalsund.no","rahkkeravju.no","ráhkkerávju.no","kvam.no","kvinesdal.no","kvinnherad.no","kviteseid.no","kvitsoy.no","kvitsøy.no","kvafjord.no","kvæfjord.no","giehtavuoatna.no","kvanangen.no","kvænangen.no","navuotna.no","návuotna.no","kafjord.no","kåfjord.no","gaivuotna.no","gáivuotna.no","larvik.no","lavangen.no","lavagis.no","loabat.no","loabát.no","lebesby.no","davvesiida.no","leikanger.no","leirfjord.no","leka.no","leksvik.no","lenvik.no","leangaviika.no","leaŋgaviika.no","lesja.no","levanger.no","lier.no","lierne.no","lillehammer.no","lillesand.no","lindesnes.no","lindas.no","lindås.no","lom.no","loppa.no","lahppi.no","láhppi.no","lund.no","lunner.no","luroy.no","lurøy.no","luster.no","lyngdal.no","lyngen.no","ivgu.no","lardal.no","lerdal.no","lærdal.no","lodingen.no","lødingen.no","lorenskog.no","lørenskog.no","loten.no","løten.no","malvik.no","masoy.no","måsøy.no","muosat.no","muosát.no","mandal.no","marker.no","marnardal.no","masfjorden.no","meland.no","meldal.no","melhus.no","meloy.no","meløy.no","meraker.no","meråker.no","moareke.no","moåreke.no","midsund.no","midtre-gauldal.no","modalen.no","modum.no","molde.no","moskenes.no","moss.no","mosvik.no","malselv.no","målselv.no","malatvuopmi.no","málatvuopmi.no","namdalseid.no","aejrie.no","namsos.no","namsskogan.no","naamesjevuemie.no","nååmesjevuemie.no","laakesvuemie.no","nannestad.no","narvik.no","narviika.no","naustdal.no","nedre-eiker.no","nes.akershus.no","nes.buskerud.no","nesna.no","nesodden.no","nesseby.no","unjarga.no","unjárga.no","nesset.no","nissedal.no","nittedal.no","nord-aurdal.no","nord-fron.no","nord-odal.no","norddal.no","nordkapp.no","davvenjarga.no","davvenjárga.no","nordre-land.no","nordreisa.no","raisa.no","ráisa.no","nore-og-uvdal.no","notodden.no","naroy.no","nærøy.no","notteroy.no","nøtterøy.no","odda.no","oksnes.no","øksnes.no","oppdal.no","oppegard.no","oppegård.no","orkdal.no","orland.no","ørland.no","orskog.no","ørskog.no","orsta.no","ørsta.no","os.hedmark.no","os.hordaland.no","osen.no","osteroy.no","osterøy.no","ostre-toten.no","østre-toten.no","overhalla.no","ovre-eiker.no","øvre-eiker.no","oyer.no","øyer.no","oygarden.no","øygarden.no","oystre-slidre.no","øystre-slidre.no","porsanger.no","porsangu.no","porsáŋgu.no","porsgrunn.no","radoy.no","radøy.no","rakkestad.no","rana.no","ruovat.no","randaberg.no","rauma.no","rendalen.no","rennebu.no","rennesoy.no","rennesøy.no","rindal.no","ringebu.no","ringerike.no","ringsaker.no","rissa.no","risor.no","risør.no","roan.no","rollag.no","rygge.no","ralingen.no","rælingen.no","rodoy.no","rødøy.no","romskog.no","rømskog.no","roros.no","røros.no","rost.no","røst.no","royken.no","røyken.no","royrvik.no","røyrvik.no","rade.no","råde.no","salangen.no","siellak.no","saltdal.no","salat.no","sálát.no","sálat.no","samnanger.no","sande.more-og-romsdal.no","sande.møre-og-romsdal.no","sande.vestfold.no","sandefjord.no","sandnes.no","sandoy.no","sandøy.no","sarpsborg.no","sauda.no","sauherad.no","sel.no","selbu.no","selje.no","seljord.no","sigdal.no","siljan.no","sirdal.no","skaun.no","skedsmo.no","ski.no","skien.no","skiptvet.no","skjervoy.no","skjervøy.no","skierva.no","skiervá.no","skjak.no","skjåk.no","skodje.no","skanland.no","skånland.no","skanit.no","skánit.no","smola.no","smøla.no","snillfjord.no","snasa.no","snåsa.no","snoasa.no","snaase.no","snåase.no","sogndal.no","sokndal.no","sola.no","solund.no","songdalen.no","sortland.no","spydeberg.no","stange.no","stavanger.no","steigen.no","steinkjer.no","stjordal.no","stjørdal.no","stokke.no","stor-elvdal.no","stord.no","stordal.no","storfjord.no","omasvuotna.no","strand.no","stranda.no","stryn.no","sula.no","suldal.no","sund.no","sunndal.no","surnadal.no","sveio.no","svelvik.no","sykkylven.no","sogne.no","søgne.no","somna.no","sømna.no","sondre-land.no","søndre-land.no","sor-aurdal.no","sør-aurdal.no","sor-fron.no","sør-fron.no","sor-odal.no","sør-odal.no","sor-varanger.no","sør-varanger.no","matta-varjjat.no","mátta-várjjat.no","sorfold.no","sørfold.no","sorreisa.no","sørreisa.no","sorum.no","sørum.no","tana.no","deatnu.no","time.no","tingvoll.no","tinn.no","tjeldsund.no","dielddanuorri.no","tjome.no","tjøme.no","tokke.no","tolga.no","torsken.no","tranoy.no","tranøy.no","tromso.no","tromsø.no","tromsa.no","romsa.no","trondheim.no","troandin.no","trysil.no","trana.no","træna.no","trogstad.no","trøgstad.no","tvedestrand.no","tydal.no","tynset.no","tysfjord.no","divtasvuodna.no","divttasvuotna.no","tysnes.no","tysvar.no","tysvær.no","tonsberg.no","tønsberg.no","ullensaker.no","ullensvang.no","ulvik.no","utsira.no","vadso.no","vadsø.no","cahcesuolo.no","čáhcesuolo.no","vaksdal.no","valle.no","vang.no","vanylven.no","vardo.no","vardø.no","varggat.no","várggát.no","vefsn.no","vaapste.no","vega.no","vegarshei.no","vegårshei.no","vennesla.no","verdal.no","verran.no","vestby.no","vestnes.no","vestre-slidre.no","vestre-toten.no","vestvagoy.no","vestvågøy.no","vevelstad.no","vik.no","vikna.no","vindafjord.no","volda.no","voss.no","varoy.no","værøy.no","vagan.no","vågan.no","voagat.no","vagsoy.no","vågsøy.no","vaga.no","vågå.no","valer.ostfold.no","våler.østfold.no","valer.hedmark.no","våler.hedmark.no","*.np","nr","biz.nr","info.nr","gov.nr","edu.nr","org.nr","net.nr","com.nr","nu","nz","ac.nz","co.nz","cri.nz","geek.nz","gen.nz","govt.nz","health.nz","iwi.nz","kiwi.nz","maori.nz","mil.nz","māori.nz","net.nz","org.nz","parliament.nz","school.nz","om","co.om","com.om","edu.om","gov.om","med.om","museum.om","net.om","org.om","pro.om","onion","org","pa","ac.pa","gob.pa","com.pa","org.pa","sld.pa","edu.pa","net.pa","ing.pa","abo.pa","med.pa","nom.pa","pe","edu.pe","gob.pe","nom.pe","mil.pe","org.pe","com.pe","net.pe","pf","com.pf","org.pf","edu.pf","*.pg","ph","com.ph","net.ph","org.ph","gov.ph","edu.ph","ngo.ph","mil.ph","i.ph","pk","com.pk","net.pk","edu.pk","org.pk","fam.pk","biz.pk","web.pk","gov.pk","gob.pk","gok.pk","gon.pk","gop.pk","gos.pk","info.pk","pl","com.pl","net.pl","org.pl","aid.pl","agro.pl","atm.pl","auto.pl","biz.pl","edu.pl","gmina.pl","gsm.pl","info.pl","mail.pl","miasta.pl","media.pl","mil.pl","nieruchomosci.pl","nom.pl","pc.pl","powiat.pl","priv.pl","realestate.pl","rel.pl","sex.pl","shop.pl","sklep.pl","sos.pl","szkola.pl","targi.pl","tm.pl","tourism.pl","travel.pl","turystyka.pl","gov.pl","ap.gov.pl","ic.gov.pl","is.gov.pl","us.gov.pl","kmpsp.gov.pl","kppsp.gov.pl","kwpsp.gov.pl","psp.gov.pl","wskr.gov.pl","kwp.gov.pl","mw.gov.pl","ug.gov.pl","um.gov.pl","umig.gov.pl","ugim.gov.pl","upow.gov.pl","uw.gov.pl","starostwo.gov.pl","pa.gov.pl","po.gov.pl","psse.gov.pl","pup.gov.pl","rzgw.gov.pl","sa.gov.pl","so.gov.pl","sr.gov.pl","wsa.gov.pl","sko.gov.pl","uzs.gov.pl","wiih.gov.pl","winb.gov.pl","pinb.gov.pl","wios.gov.pl","witd.gov.pl","wzmiuw.gov.pl","piw.gov.pl","wiw.gov.pl","griw.gov.pl","wif.gov.pl","oum.gov.pl","sdn.gov.pl","zp.gov.pl","uppo.gov.pl","mup.gov.pl","wuoz.gov.pl","konsulat.gov.pl","oirm.gov.pl","augustow.pl","babia-gora.pl","bedzin.pl","beskidy.pl","bialowieza.pl","bialystok.pl","bielawa.pl","bieszczady.pl","boleslawiec.pl","bydgoszcz.pl","bytom.pl","cieszyn.pl","czeladz.pl","czest.pl","dlugoleka.pl","elblag.pl","elk.pl","glogow.pl","gniezno.pl","gorlice.pl","grajewo.pl","ilawa.pl","jaworzno.pl","jelenia-gora.pl","jgora.pl","kalisz.pl","kazimierz-dolny.pl","karpacz.pl","kartuzy.pl","kaszuby.pl","katowice.pl","kepno.pl","ketrzyn.pl","klodzko.pl","kobierzyce.pl","kolobrzeg.pl","konin.pl","konskowola.pl","kutno.pl","lapy.pl","lebork.pl","legnica.pl","lezajsk.pl","limanowa.pl","lomza.pl","lowicz.pl","lubin.pl","lukow.pl","malbork.pl","malopolska.pl","mazowsze.pl","mazury.pl","mielec.pl","mielno.pl","mragowo.pl","naklo.pl","nowaruda.pl","nysa.pl","olawa.pl","olecko.pl","olkusz.pl","olsztyn.pl","opoczno.pl","opole.pl","ostroda.pl","ostroleka.pl","ostrowiec.pl","ostrowwlkp.pl","pila.pl","pisz.pl","podhale.pl","podlasie.pl","polkowice.pl","pomorze.pl","pomorskie.pl","prochowice.pl","pruszkow.pl","przeworsk.pl","pulawy.pl","radom.pl","rawa-maz.pl","rybnik.pl","rzeszow.pl","sanok.pl","sejny.pl","slask.pl","slupsk.pl","sosnowiec.pl","stalowa-wola.pl","skoczow.pl","starachowice.pl","stargard.pl","suwalki.pl","swidnica.pl","swiebodzin.pl","swinoujscie.pl","szczecin.pl","szczytno.pl","tarnobrzeg.pl","tgory.pl","turek.pl","tychy.pl","ustka.pl","walbrzych.pl","warmia.pl","warszawa.pl","waw.pl","wegrow.pl","wielun.pl","wlocl.pl","wloclawek.pl","wodzislaw.pl","wolomin.pl","wroclaw.pl","zachpomor.pl","zagan.pl","zarow.pl","zgora.pl","zgorzelec.pl","pm","pn","gov.pn","co.pn","org.pn","edu.pn","net.pn","post","pr","com.pr","net.pr","org.pr","gov.pr","edu.pr","isla.pr","pro.pr","biz.pr","info.pr","name.pr","est.pr","prof.pr","ac.pr","pro","aaa.pro","aca.pro","acct.pro","avocat.pro","bar.pro","cpa.pro","eng.pro","jur.pro","law.pro","med.pro","recht.pro","ps","edu.ps","gov.ps","sec.ps","plo.ps","com.ps","org.ps","net.ps","pt","net.pt","gov.pt","org.pt","edu.pt","int.pt","publ.pt","com.pt","nome.pt","pw","co.pw","ne.pw","or.pw","ed.pw","go.pw","belau.pw","py","com.py","coop.py","edu.py","gov.py","mil.py","net.py","org.py","qa","com.qa","edu.qa","gov.qa","mil.qa","name.qa","net.qa","org.qa","sch.qa","re","asso.re","com.re","nom.re","ro","arts.ro","com.ro","firm.ro","info.ro","nom.ro","nt.ro","org.ro","rec.ro","store.ro","tm.ro","www.ro","rs","ac.rs","co.rs","edu.rs","gov.rs","in.rs","org.rs","ru","rw","ac.rw","co.rw","coop.rw","gov.rw","mil.rw","net.rw","org.rw","sa","com.sa","net.sa","org.sa","gov.sa","med.sa","pub.sa","edu.sa","sch.sa","sb","com.sb","edu.sb","gov.sb","net.sb","org.sb","sc","com.sc","gov.sc","net.sc","org.sc","edu.sc","sd","com.sd","net.sd","org.sd","edu.sd","med.sd","tv.sd","gov.sd","info.sd","se","a.se","ac.se","b.se","bd.se","brand.se","c.se","d.se","e.se","f.se","fh.se","fhsk.se","fhv.se","g.se","h.se","i.se","k.se","komforb.se","kommunalforbund.se","komvux.se","l.se","lanbib.se","m.se","n.se","naturbruksgymn.se","o.se","org.se","p.se","parti.se","pp.se","press.se","r.se","s.se","t.se","tm.se","u.se","w.se","x.se","y.se","z.se","sg","com.sg","net.sg","org.sg","gov.sg","edu.sg","per.sg","sh","com.sh","net.sh","gov.sh","org.sh","mil.sh","si","sj","sk","sl","com.sl","net.sl","edu.sl","gov.sl","org.sl","sm","sn","art.sn","com.sn","edu.sn","gouv.sn","org.sn","perso.sn","univ.sn","so","com.so","edu.so","gov.so","me.so","net.so","org.so","sr","ss","biz.ss","com.ss","edu.ss","gov.ss","me.ss","net.ss","org.ss","sch.ss","st","co.st","com.st","consulado.st","edu.st","embaixada.st","mil.st","net.st","org.st","principe.st","saotome.st","store.st","su","sv","com.sv","edu.sv","gob.sv","org.sv","red.sv","sx","gov.sx","sy","edu.sy","gov.sy","net.sy","mil.sy","com.sy","org.sy","sz","co.sz","ac.sz","org.sz","tc","td","tel","tf","tg","th","ac.th","co.th","go.th","in.th","mi.th","net.th","or.th","tj","ac.tj","biz.tj","co.tj","com.tj","edu.tj","go.tj","gov.tj","int.tj","mil.tj","name.tj","net.tj","nic.tj","org.tj","test.tj","web.tj","tk","tl","gov.tl","tm","com.tm","co.tm","org.tm","net.tm","nom.tm","gov.tm","mil.tm","edu.tm","tn","com.tn","ens.tn","fin.tn","gov.tn","ind.tn","info.tn","intl.tn","mincom.tn","nat.tn","net.tn","org.tn","perso.tn","tourism.tn","to","com.to","gov.to","net.to","org.to","edu.to","mil.to","tr","av.tr","bbs.tr","bel.tr","biz.tr","com.tr","dr.tr","edu.tr","gen.tr","gov.tr","info.tr","mil.tr","k12.tr","kep.tr","name.tr","net.tr","org.tr","pol.tr","tel.tr","tsk.tr","tv.tr","web.tr","nc.tr","gov.nc.tr","tt","co.tt","com.tt","org.tt","net.tt","biz.tt","info.tt","pro.tt","int.tt","coop.tt","jobs.tt","mobi.tt","travel.tt","museum.tt","aero.tt","name.tt","gov.tt","edu.tt","tv","tw","edu.tw","gov.tw","mil.tw","com.tw","net.tw","org.tw","idv.tw","game.tw","ebiz.tw","club.tw","網路.tw","組織.tw","商業.tw","tz","ac.tz","co.tz","go.tz","hotel.tz","info.tz","me.tz","mil.tz","mobi.tz","ne.tz","or.tz","sc.tz","tv.tz","ua","com.ua","edu.ua","gov.ua","in.ua","net.ua","org.ua","cherkassy.ua","cherkasy.ua","chernigov.ua","chernihiv.ua","chernivtsi.ua","chernovtsy.ua","ck.ua","cn.ua","cr.ua","crimea.ua","cv.ua","dn.ua","dnepropetrovsk.ua","dnipropetrovsk.ua","donetsk.ua","dp.ua","if.ua","ivano-frankivsk.ua","kh.ua","kharkiv.ua","kharkov.ua","kherson.ua","khmelnitskiy.ua","khmelnytskyi.ua","kiev.ua","kirovograd.ua","km.ua","kr.ua","krym.ua","ks.ua","kv.ua","kyiv.ua","lg.ua","lt.ua","lugansk.ua","lutsk.ua","lv.ua","lviv.ua","mk.ua","mykolaiv.ua","nikolaev.ua","od.ua","odesa.ua","odessa.ua","pl.ua","poltava.ua","rivne.ua","rovno.ua","rv.ua","sb.ua","sebastopol.ua","sevastopol.ua","sm.ua","sumy.ua","te.ua","ternopil.ua","uz.ua","uzhgorod.ua","vinnica.ua","vinnytsia.ua","vn.ua","volyn.ua","yalta.ua","zaporizhzhe.ua","zaporizhzhia.ua","zhitomir.ua","zhytomyr.ua","zp.ua","zt.ua","ug","co.ug","or.ug","ac.ug","sc.ug","go.ug","ne.ug","com.ug","org.ug","uk","ac.uk","co.uk","gov.uk","ltd.uk","me.uk","net.uk","nhs.uk","org.uk","plc.uk","police.uk","*.sch.uk","us","dni.us","fed.us","isa.us","kids.us","nsn.us","ak.us","al.us","ar.us","as.us","az.us","ca.us","co.us","ct.us","dc.us","de.us","fl.us","ga.us","gu.us","hi.us","ia.us","id.us","il.us","in.us","ks.us","ky.us","la.us","ma.us","md.us","me.us","mi.us","mn.us","mo.us","ms.us","mt.us","nc.us","nd.us","ne.us","nh.us","nj.us","nm.us","nv.us","ny.us","oh.us","ok.us","or.us","pa.us","pr.us","ri.us","sc.us","sd.us","tn.us","tx.us","ut.us","vi.us","vt.us","va.us","wa.us","wi.us","wv.us","wy.us","k12.ak.us","k12.al.us","k12.ar.us","k12.as.us","k12.az.us","k12.ca.us","k12.co.us","k12.ct.us","k12.dc.us","k12.de.us","k12.fl.us","k12.ga.us","k12.gu.us","k12.ia.us","k12.id.us","k12.il.us","k12.in.us","k12.ks.us","k12.ky.us","k12.la.us","k12.ma.us","k12.md.us","k12.me.us","k12.mi.us","k12.mn.us","k12.mo.us","k12.ms.us","k12.mt.us","k12.nc.us","k12.ne.us","k12.nh.us","k12.nj.us","k12.nm.us","k12.nv.us","k12.ny.us","k12.oh.us","k12.ok.us","k12.or.us","k12.pa.us","k12.pr.us","k12.sc.us","k12.tn.us","k12.tx.us","k12.ut.us","k12.vi.us","k12.vt.us","k12.va.us","k12.wa.us","k12.wi.us","k12.wy.us","cc.ak.us","cc.al.us","cc.ar.us","cc.as.us","cc.az.us","cc.ca.us","cc.co.us","cc.ct.us","cc.dc.us","cc.de.us","cc.fl.us","cc.ga.us","cc.gu.us","cc.hi.us","cc.ia.us","cc.id.us","cc.il.us","cc.in.us","cc.ks.us","cc.ky.us","cc.la.us","cc.ma.us","cc.md.us","cc.me.us","cc.mi.us","cc.mn.us","cc.mo.us","cc.ms.us","cc.mt.us","cc.nc.us","cc.nd.us","cc.ne.us","cc.nh.us","cc.nj.us","cc.nm.us","cc.nv.us","cc.ny.us","cc.oh.us","cc.ok.us","cc.or.us","cc.pa.us","cc.pr.us","cc.ri.us","cc.sc.us","cc.sd.us","cc.tn.us","cc.tx.us","cc.ut.us","cc.vi.us","cc.vt.us","cc.va.us","cc.wa.us","cc.wi.us","cc.wv.us","cc.wy.us","lib.ak.us","lib.al.us","lib.ar.us","lib.as.us","lib.az.us","lib.ca.us","lib.co.us","lib.ct.us","lib.dc.us","lib.fl.us","lib.ga.us","lib.gu.us","lib.hi.us","lib.ia.us","lib.id.us","lib.il.us","lib.in.us","lib.ks.us","lib.ky.us","lib.la.us","lib.ma.us","lib.md.us","lib.me.us","lib.mi.us","lib.mn.us","lib.mo.us","lib.ms.us","lib.mt.us","lib.nc.us","lib.nd.us","lib.ne.us","lib.nh.us","lib.nj.us","lib.nm.us","lib.nv.us","lib.ny.us","lib.oh.us","lib.ok.us","lib.or.us","lib.pa.us","lib.pr.us","lib.ri.us","lib.sc.us","lib.sd.us","lib.tn.us","lib.tx.us","lib.ut.us","lib.vi.us","lib.vt.us","lib.va.us","lib.wa.us","lib.wi.us","lib.wy.us","pvt.k12.ma.us","chtr.k12.ma.us","paroch.k12.ma.us","ann-arbor.mi.us","cog.mi.us","dst.mi.us","eaton.mi.us","gen.mi.us","mus.mi.us","tec.mi.us","washtenaw.mi.us","uy","com.uy","edu.uy","gub.uy","mil.uy","net.uy","org.uy","uz","co.uz","com.uz","net.uz","org.uz","va","vc","com.vc","net.vc","org.vc","gov.vc","mil.vc","edu.vc","ve","arts.ve","bib.ve","co.ve","com.ve","e12.ve","edu.ve","firm.ve","gob.ve","gov.ve","info.ve","int.ve","mil.ve","net.ve","nom.ve","org.ve","rar.ve","rec.ve","store.ve","tec.ve","web.ve","vg","vi","co.vi","com.vi","k12.vi","net.vi","org.vi","vn","com.vn","net.vn","org.vn","edu.vn","gov.vn","int.vn","ac.vn","biz.vn","info.vn","name.vn","pro.vn","health.vn","vu","com.vu","edu.vu","net.vu","org.vu","wf","ws","com.ws","net.ws","org.ws","gov.ws","edu.ws","yt","امارات","հայ","বাংলা","бг","البحرين","бел","中国","中國","الجزائر","مصر","ею","ευ","موريتانيا","გე","ελ","香港","公司.香港","教育.香港","政府.香港","個人.香港","網絡.香港","組織.香港","ಭಾರತ","ଭାରତ","ভাৰত","भारतम्","भारोत","ڀارت","ഭാരതം","भारत","بارت","بھارت","భారత్","ભારત","ਭਾਰਤ","ভারত","இந்தியா","ایران","ايران","عراق","الاردن","한국","қаз","ລາວ","ලංකා","இலங்கை","المغرب","мкд","мон","澳門","澳门","مليسيا","عمان","پاکستان","پاكستان","فلسطين","срб","пр.срб","орг.срб","обр.срб","од.срб","упр.срб","ак.срб","рф","قطر","السعودية","السعودیة","السعودیۃ","السعوديه","سودان","新加坡","சிங்கப்பூர்","سورية","سوريا","ไทย","ศึกษา.ไทย","ธุรกิจ.ไทย","รัฐบาล.ไทย","ทหาร.ไทย","เน็ต.ไทย","องค์กร.ไทย","تونس","台灣","台湾","臺灣","укр","اليمن","xxx","ye","com.ye","edu.ye","gov.ye","net.ye","mil.ye","org.ye","ac.za","agric.za","alt.za","co.za","edu.za","gov.za","grondar.za","law.za","mil.za","net.za","ngo.za","nic.za","nis.za","nom.za","org.za","school.za","tm.za","web.za","zm","ac.zm","biz.zm","co.zm","com.zm","edu.zm","gov.zm","info.zm","mil.zm","net.zm","org.zm","sch.zm","zw","ac.zw","co.zw","gov.zw","mil.zw","org.zw","aaa","aarp","abarth","abb","abbott","abbvie","abc","able","abogado","abudhabi","academy","accenture","accountant","accountants","aco","actor","adac","ads","adult","aeg","aetna","afl","africa","agakhan","agency","aig","airbus","airforce","airtel","akdn","alfaromeo","alibaba","alipay","allfinanz","allstate","ally","alsace","alstom","amazon","americanexpress","americanfamily","amex","amfam","amica","amsterdam","analytics","android","anquan","anz","aol","apartments","app","apple","aquarelle","arab","aramco","archi","army","art","arte","asda","associates","athleta","attorney","auction","audi","audible","audio","auspost","author","auto","autos","avianca","aws","axa","azure","baby","baidu","banamex","bananarepublic","band","bank","bar","barcelona","barclaycard","barclays","barefoot","bargains","baseball","basketball","bauhaus","bayern","bbc","bbt","bbva","bcg","bcn","beats","beauty","beer","bentley","berlin","best","bestbuy","bet","bharti","bible","bid","bike","bing","bingo","bio","black","blackfriday","blockbuster","blog","bloomberg","blue","bms","bmw","bnpparibas","boats","boehringer","bofa","bom","bond","boo","book","booking","bosch","bostik","boston","bot","boutique","box","bradesco","bridgestone","broadway","broker","brother","brussels","bugatti","build","builders","business","buy","buzz","bzh","cab","cafe","cal","call","calvinklein","cam","camera","camp","cancerresearch","canon","capetown","capital","capitalone","car","caravan","cards","care","career","careers","cars","casa","case","cash","casino","catering","catholic","cba","cbn","cbre","cbs","center","ceo","cern","cfa","cfd","chanel","channel","charity","chase","chat","cheap","chintai","christmas","chrome","church","cipriani","circle","cisco","citadel","citi","citic","city","cityeats","claims","cleaning","click","clinic","clinique","clothing","cloud","club","clubmed","coach","codes","coffee","college","cologne","comcast","commbank","community","company","compare","computer","comsec","condos","construction","consulting","contact","contractors","cooking","cookingchannel","cool","corsica","country","coupon","coupons","courses","cpa","credit","creditcard","creditunion","cricket","crown","crs","cruise","cruises","cuisinella","cymru","cyou","dabur","dad","dance","data","date","dating","datsun","day","dclk","dds","deal","dealer","deals","degree","delivery","dell","deloitte","delta","democrat","dental","dentist","desi","design","dev","dhl","diamonds","diet","digital","direct","directory","discount","discover","dish","diy","dnp","docs","doctor","dog","domains","dot","download","drive","dtv","dubai","dunlop","dupont","durban","dvag","dvr","earth","eat","eco","edeka","education","email","emerck","energy","engineer","engineering","enterprises","epson","equipment","ericsson","erni","esq","estate","etisalat","eurovision","eus","events","exchange","expert","exposed","express","extraspace","fage","fail","fairwinds","faith","family","fan","fans","farm","farmers","fashion","fast","fedex","feedback","ferrari","ferrero","fiat","fidelity","fido","film","final","finance","financial","fire","firestone","firmdale","fish","fishing","fit","fitness","flickr","flights","flir","florist","flowers","fly","foo","food","foodnetwork","football","ford","forex","forsale","forum","foundation","fox","free","fresenius","frl","frogans","frontdoor","frontier","ftr","fujitsu","fun","fund","furniture","futbol","fyi","gal","gallery","gallo","gallup","game","games","gap","garden","gay","gbiz","gdn","gea","gent","genting","george","ggee","gift","gifts","gives","giving","glass","gle","global","globo","gmail","gmbh","gmo","gmx","godaddy","gold","goldpoint","golf","goo","goodyear","goog","google","gop","got","grainger","graphics","gratis","green","gripe","grocery","group","guardian","gucci","guge","guide","guitars","guru","hair","hamburg","hangout","haus","hbo","hdfc","hdfcbank","health","healthcare","help","helsinki","here","hermes","hgtv","hiphop","hisamitsu","hitachi","hiv","hkt","hockey","holdings","holiday","homedepot","homegoods","homes","homesense","honda","horse","hospital","host","hosting","hot","hoteles","hotels","hotmail","house","how","hsbc","hughes","hyatt","hyundai","ibm","icbc","ice","icu","ieee","ifm","ikano","imamat","imdb","immo","immobilien","inc","industries","infiniti","ing","ink","institute","insurance","insure","international","intuit","investments","ipiranga","irish","ismaili","ist","istanbul","itau","itv","jaguar","java","jcb","jeep","jetzt","jewelry","jio","jll","jmp","jnj","joburg","jot","joy","jpmorgan","jprs","juegos","juniper","kaufen","kddi","kerryhotels","kerrylogistics","kerryproperties","kfh","kia","kids","kim","kinder","kindle","kitchen","kiwi","koeln","komatsu","kosher","kpmg","kpn","krd","kred","kuokgroup","kyoto","lacaixa","lamborghini","lamer","lancaster","lancia","land","landrover","lanxess","lasalle","lat","latino","latrobe","law","lawyer","lds","lease","leclerc","lefrak","legal","lego","lexus","lgbt","lidl","life","lifeinsurance","lifestyle","lighting","like","lilly","limited","limo","lincoln","linde","link","lipsy","live","living","llc","llp","loan","loans","locker","locus","loft","lol","london","lotte","lotto","love","lpl","lplfinancial","ltd","ltda","lundbeck","luxe","luxury","macys","madrid","maif","maison","makeup","man","management","mango","map","market","marketing","markets","marriott","marshalls","maserati","mattel","mba","mckinsey","med","media","meet","melbourne","meme","memorial","men","menu","merckmsd","miami","microsoft","mini","mint","mit","mitsubishi","mlb","mls","mma","mobile","moda","moe","moi","mom","monash","money","monster","mormon","mortgage","moscow","moto","motorcycles","mov","movie","msd","mtn","mtr","music","mutual","nab","nagoya","natura","navy","nba","nec","netbank","netflix","network","neustar","new","news","next","nextdirect","nexus","nfl","ngo","nhk","nico","nike","nikon","ninja","nissan","nissay","nokia","northwesternmutual","norton","now","nowruz","nowtv","nra","nrw","ntt","nyc","obi","observer","office","okinawa","olayan","olayangroup","oldnavy","ollo","omega","one","ong","onl","online","ooo","open","oracle","orange","organic","origins","osaka","otsuka","ott","ovh","page","panasonic","paris","pars","partners","parts","party","passagens","pay","pccw","pet","pfizer","pharmacy","phd","philips","phone","photo","photography","photos","physio","pics","pictet","pictures","pid","pin","ping","pink","pioneer","pizza","place","play","playstation","plumbing","plus","pnc","pohl","poker","politie","porn","pramerica","praxi","press","prime","prod","productions","prof","progressive","promo","properties","property","protection","pru","prudential","pub","pwc","qpon","quebec","quest","racing","radio","read","realestate","realtor","realty","recipes","red","redstone","redumbrella","rehab","reise","reisen","reit","reliance","ren","rent","rentals","repair","report","republican","rest","restaurant","review","reviews","rexroth","rich","richardli","ricoh","ril","rio","rip","rocher","rocks","rodeo","rogers","room","rsvp","rugby","ruhr","run","rwe","ryukyu","saarland","safe","safety","sakura","sale","salon","samsclub","samsung","sandvik","sandvikcoromant","sanofi","sap","sarl","sas","save","saxo","sbi","sbs","sca","scb","schaeffler","schmidt","scholarships","school","schule","schwarz","science","scot","search","seat","secure","security","seek","select","sener","services","ses","seven","sew","sex","sexy","sfr","shangrila","sharp","shaw","shell","shia","shiksha","shoes","shop","shopping","shouji","show","showtime","silk","sina","singles","site","ski","skin","sky","skype","sling","smart","smile","sncf","soccer","social","softbank","software","sohu","solar","solutions","song","sony","soy","spa","space","sport","spot","srl","stada","staples","star","statebank","statefarm","stc","stcgroup","stockholm","storage","store","stream","studio","study","style","sucks","supplies","supply","support","surf","surgery","suzuki","swatch","swiss","sydney","systems","tab","taipei","talk","taobao","target","tatamotors","tatar","tattoo","tax","taxi","tci","tdk","team","tech","technology","temasek","tennis","teva","thd","theater","theatre","tiaa","tickets","tienda","tiffany","tips","tires","tirol","tjmaxx","tjx","tkmaxx","tmall","today","tokyo","tools","top","toray","toshiba","total","tours","town","toyota","toys","trade","trading","training","travel","travelchannel","travelers","travelersinsurance","trust","trv","tube","tui","tunes","tushu","tvs","ubank","ubs","unicom","university","uno","uol","ups","vacations","vana","vanguard","vegas","ventures","verisign","versicherung","vet","viajes","video","vig","viking","villas","vin","vip","virgin","visa","vision","viva","vivo","vlaanderen","vodka","volkswagen","volvo","vote","voting","voto","voyage","vuelos","wales","walmart","walter","wang","wanggou","watch","watches","weather","weatherchannel","webcam","weber","website","wedding","weibo","weir","whoswho","wien","wiki","williamhill","win","windows","wine","winners","wme","wolterskluwer","woodside","work","works","world","wow","wtc","wtf","xbox","xerox","xfinity","xihuan","xin","कॉम","セール","佛山","慈善","集团","在线","点看","คอม","八卦","موقع","公益","公司","香格里拉","网站","移动","我爱你","москва","католик","онлайн","сайт","联通","קום","时尚","微博","淡马锡","ファッション","орг","नेट","ストア","アマゾン","삼성","商标","商店","商城","дети","ポイント","新闻","家電","كوم","中文网","中信","娱乐","谷歌","電訊盈科","购物","クラウド","通販","网店","संगठन","餐厅","网络","ком","亚马逊","诺基亚","食品","飞利浦","手机","ارامكو","العليان","اتصالات","بازار","ابوظبي","كاثوليك","همراه","닷컴","政府","شبكة","بيتك","عرب","机构","组织机构","健康","招聘","рус","大拿","みんな","グーグル","世界","書籍","网址","닷넷","コム","天主教","游戏","vermögensberater","vermögensberatung","企业","信息","嘉里大酒店","嘉里","广东","政务","xyz","yachts","yahoo","yamaxun","yandex","yodobashi","yoga","yokohama","you","youtube","yun","zappos","zara","zero","zip","zone","zuerich","cc.ua","inf.ua","ltd.ua","611.to","graphox.us","*.devcdnaccesso.com","adobeaemcloud.com","*.dev.adobeaemcloud.com","hlx.live","adobeaemcloud.net","hlx.page","hlx3.page","beep.pl","airkitapps.com","airkitapps-au.com","airkitapps.eu","aivencloud.com","barsy.ca","*.compute.estate","*.alces.network","kasserver.com","altervista.org","alwaysdata.net","cloudfront.net","*.compute.amazonaws.com","*.compute-1.amazonaws.com","*.compute.amazonaws.com.cn","us-east-1.amazonaws.com","cn-north-1.eb.amazonaws.com.cn","cn-northwest-1.eb.amazonaws.com.cn","elasticbeanstalk.com","ap-northeast-1.elasticbeanstalk.com","ap-northeast-2.elasticbeanstalk.com","ap-northeast-3.elasticbeanstalk.com","ap-south-1.elasticbeanstalk.com","ap-southeast-1.elasticbeanstalk.com","ap-southeast-2.elasticbeanstalk.com","ca-central-1.elasticbeanstalk.com","eu-central-1.elasticbeanstalk.com","eu-west-1.elasticbeanstalk.com","eu-west-2.elasticbeanstalk.com","eu-west-3.elasticbeanstalk.com","sa-east-1.elasticbeanstalk.com","us-east-1.elasticbeanstalk.com","us-east-2.elasticbeanstalk.com","us-gov-west-1.elasticbeanstalk.com","us-west-1.elasticbeanstalk.com","us-west-2.elasticbeanstalk.com","*.elb.amazonaws.com","*.elb.amazonaws.com.cn","awsglobalaccelerator.com","s3.amazonaws.com","s3-ap-northeast-1.amazonaws.com","s3-ap-northeast-2.amazonaws.com","s3-ap-south-1.amazonaws.com","s3-ap-southeast-1.amazonaws.com","s3-ap-southeast-2.amazonaws.com","s3-ca-central-1.amazonaws.com","s3-eu-central-1.amazonaws.com","s3-eu-west-1.amazonaws.com","s3-eu-west-2.amazonaws.com","s3-eu-west-3.amazonaws.com","s3-external-1.amazonaws.com","s3-fips-us-gov-west-1.amazonaws.com","s3-sa-east-1.amazonaws.com","s3-us-gov-west-1.amazonaws.com","s3-us-east-2.amazonaws.com","s3-us-west-1.amazonaws.com","s3-us-west-2.amazonaws.com","s3.ap-northeast-2.amazonaws.com","s3.ap-south-1.amazonaws.com","s3.cn-north-1.amazonaws.com.cn","s3.ca-central-1.amazonaws.com","s3.eu-central-1.amazonaws.com","s3.eu-west-2.amazonaws.com","s3.eu-west-3.amazonaws.com","s3.us-east-2.amazonaws.com","s3.dualstack.ap-northeast-1.amazonaws.com","s3.dualstack.ap-northeast-2.amazonaws.com","s3.dualstack.ap-south-1.amazonaws.com","s3.dualstack.ap-southeast-1.amazonaws.com","s3.dualstack.ap-southeast-2.amazonaws.com","s3.dualstack.ca-central-1.amazonaws.com","s3.dualstack.eu-central-1.amazonaws.com","s3.dualstack.eu-west-1.amazonaws.com","s3.dualstack.eu-west-2.amazonaws.com","s3.dualstack.eu-west-3.amazonaws.com","s3.dualstack.sa-east-1.amazonaws.com","s3.dualstack.us-east-1.amazonaws.com","s3.dualstack.us-east-2.amazonaws.com","s3-website-us-east-1.amazonaws.com","s3-website-us-west-1.amazonaws.com","s3-website-us-west-2.amazonaws.com","s3-website-ap-northeast-1.amazonaws.com","s3-website-ap-southeast-1.amazonaws.com","s3-website-ap-southeast-2.amazonaws.com","s3-website-eu-west-1.amazonaws.com","s3-website-sa-east-1.amazonaws.com","s3-website.ap-northeast-2.amazonaws.com","s3-website.ap-south-1.amazonaws.com","s3-website.ca-central-1.amazonaws.com","s3-website.eu-central-1.amazonaws.com","s3-website.eu-west-2.amazonaws.com","s3-website.eu-west-3.amazonaws.com","s3-website.us-east-2.amazonaws.com","t3l3p0rt.net","tele.amune.org","apigee.io","siiites.com","appspacehosted.com","appspaceusercontent.com","appudo.net","on-aptible.com","user.aseinet.ne.jp","gv.vc","d.gv.vc","user.party.eus","pimienta.org","poivron.org","potager.org","sweetpepper.org","myasustor.com","cdn.prod.atlassian-dev.net","translated.page","myfritz.net","onavstack.net","*.awdev.ca","*.advisor.ws","ecommerce-shop.pl","b-data.io","backplaneapp.io","balena-devices.com","rs.ba","*.banzai.cloud","app.banzaicloud.io","*.backyards.banzaicloud.io","base.ec","official.ec","buyshop.jp","fashionstore.jp","handcrafted.jp","kawaiishop.jp","supersale.jp","theshop.jp","shopselect.net","base.shop","*.beget.app","betainabox.com","bnr.la","bitbucket.io","blackbaudcdn.net","of.je","bluebite.io","boomla.net","boutir.com","boxfuse.io","square7.ch","bplaced.com","bplaced.de","square7.de","bplaced.net","square7.net","shop.brendly.rs","browsersafetymark.io","uk0.bigv.io","dh.bytemark.co.uk","vm.bytemark.co.uk","cafjs.com","mycd.eu","drr.ac","uwu.ai","carrd.co","crd.co","ju.mp","ae.org","br.com","cn.com","com.de","com.se","de.com","eu.com","gb.net","hu.net","jp.net","jpn.com","mex.com","ru.com","sa.com","se.net","uk.com","uk.net","us.com","za.bz","za.com","ar.com","hu.com","kr.com","no.com","qc.com","uy.com","africa.com","gr.com","in.net","web.in","us.org","co.com","aus.basketball","nz.basketball","radio.am","radio.fm","c.la","certmgr.org","cx.ua","discourse.group","discourse.team","cleverapps.io","clerk.app","clerkstage.app","*.lcl.dev","*.lclstage.dev","*.stg.dev","*.stgstage.dev","clickrising.net","c66.me","cloud66.ws","cloud66.zone","jdevcloud.com","wpdevcloud.com","cloudaccess.host","freesite.host","cloudaccess.net","cloudcontrolled.com","cloudcontrolapp.com","*.cloudera.site","pages.dev","trycloudflare.com","workers.dev","wnext.app","co.ca","*.otap.co","co.cz","c.cdn77.org","cdn77-ssl.net","r.cdn77.net","rsc.cdn77.org","ssl.origin.cdn77-secure.org","cloudns.asia","cloudns.biz","cloudns.club","cloudns.cc","cloudns.eu","cloudns.in","cloudns.info","cloudns.org","cloudns.pro","cloudns.pw","cloudns.us","cnpy.gdn","codeberg.page","co.nl","co.no","webhosting.be","hosting-cluster.nl","ac.ru","edu.ru","gov.ru","int.ru","mil.ru","test.ru","dyn.cosidns.de","dynamisches-dns.de","dnsupdater.de","internet-dns.de","l-o-g-i-n.de","dynamic-dns.info","feste-ip.net","knx-server.net","static-access.net","realm.cz","*.cryptonomic.net","cupcake.is","curv.dev","*.customer-oci.com","*.oci.customer-oci.com","*.ocp.customer-oci.com","*.ocs.customer-oci.com","cyon.link","cyon.site","fnwk.site","folionetwork.site","platform0.app","daplie.me","localhost.daplie.me","dattolocal.com","dattorelay.com","dattoweb.com","mydatto.com","dattolocal.net","mydatto.net","biz.dk","co.dk","firm.dk","reg.dk","store.dk","dyndns.dappnode.io","*.dapps.earth","*.bzz.dapps.earth","builtwithdark.com","demo.datadetect.com","instance.datadetect.com","edgestack.me","ddns5.com","debian.net","deno.dev","deno-staging.dev","dedyn.io","deta.app","deta.dev","*.rss.my.id","*.diher.solutions","discordsays.com","discordsez.com","jozi.biz","dnshome.de","online.th","shop.th","drayddns.com","shoparena.pl","dreamhosters.com","mydrobo.com","drud.io","drud.us","duckdns.org","bip.sh","bitbridge.net","dy.fi","tunk.org","dyndns-at-home.com","dyndns-at-work.com","dyndns-blog.com","dyndns-free.com","dyndns-home.com","dyndns-ip.com","dyndns-mail.com","dyndns-office.com","dyndns-pics.com","dyndns-remote.com","dyndns-server.com","dyndns-web.com","dyndns-wiki.com","dyndns-work.com","dyndns.biz","dyndns.info","dyndns.org","dyndns.tv","at-band-camp.net","ath.cx","barrel-of-knowledge.info","barrell-of-knowledge.info","better-than.tv","blogdns.com","blogdns.net","blogdns.org","blogsite.org","boldlygoingnowhere.org","broke-it.net","buyshouses.net","cechire.com","dnsalias.com","dnsalias.net","dnsalias.org","dnsdojo.com","dnsdojo.net","dnsdojo.org","does-it.net","doesntexist.com","doesntexist.org","dontexist.com","dontexist.net","dontexist.org","doomdns.com","doomdns.org","dvrdns.org","dyn-o-saur.com","dynalias.com","dynalias.net","dynalias.org","dynathome.net","dyndns.ws","endofinternet.net","endofinternet.org","endoftheinternet.org","est-a-la-maison.com","est-a-la-masion.com","est-le-patron.com","est-mon-blogueur.com","for-better.biz","for-more.biz","for-our.info","for-some.biz","for-the.biz","forgot.her.name","forgot.his.name","from-ak.com","from-al.com","from-ar.com","from-az.net","from-ca.com","from-co.net","from-ct.com","from-dc.com","from-de.com","from-fl.com","from-ga.com","from-hi.com","from-ia.com","from-id.com","from-il.com","from-in.com","from-ks.com","from-ky.com","from-la.net","from-ma.com","from-md.com","from-me.org","from-mi.com","from-mn.com","from-mo.com","from-ms.com","from-mt.com","from-nc.com","from-nd.com","from-ne.com","from-nh.com","from-nj.com","from-nm.com","from-nv.com","from-ny.net","from-oh.com","from-ok.com","from-or.com","from-pa.com","from-pr.com","from-ri.com","from-sc.com","from-sd.com","from-tn.com","from-tx.com","from-ut.com","from-va.com","from-vt.com","from-wa.com","from-wi.com","from-wv.com","from-wy.com","ftpaccess.cc","fuettertdasnetz.de","game-host.org","game-server.cc","getmyip.com","gets-it.net","go.dyndns.org","gotdns.com","gotdns.org","groks-the.info","groks-this.info","ham-radio-op.net","here-for-more.info","hobby-site.com","hobby-site.org","home.dyndns.org","homedns.org","homeftp.net","homeftp.org","homeip.net","homelinux.com","homelinux.net","homelinux.org","homeunix.com","homeunix.net","homeunix.org","iamallama.com","in-the-band.net","is-a-anarchist.com","is-a-blogger.com","is-a-bookkeeper.com","is-a-bruinsfan.org","is-a-bulls-fan.com","is-a-candidate.org","is-a-caterer.com","is-a-celticsfan.org","is-a-chef.com","is-a-chef.net","is-a-chef.org","is-a-conservative.com","is-a-cpa.com","is-a-cubicle-slave.com","is-a-democrat.com","is-a-designer.com","is-a-doctor.com","is-a-financialadvisor.com","is-a-geek.com","is-a-geek.net","is-a-geek.org","is-a-green.com","is-a-guru.com","is-a-hard-worker.com","is-a-hunter.com","is-a-knight.org","is-a-landscaper.com","is-a-lawyer.com","is-a-liberal.com","is-a-libertarian.com","is-a-linux-user.org","is-a-llama.com","is-a-musician.com","is-a-nascarfan.com","is-a-nurse.com","is-a-painter.com","is-a-patsfan.org","is-a-personaltrainer.com","is-a-photographer.com","is-a-player.com","is-a-republican.com","is-a-rockstar.com","is-a-socialist.com","is-a-soxfan.org","is-a-student.com","is-a-teacher.com","is-a-techie.com","is-a-therapist.com","is-an-accountant.com","is-an-actor.com","is-an-actress.com","is-an-anarchist.com","is-an-artist.com","is-an-engineer.com","is-an-entertainer.com","is-by.us","is-certified.com","is-found.org","is-gone.com","is-into-anime.com","is-into-cars.com","is-into-cartoons.com","is-into-games.com","is-leet.com","is-lost.org","is-not-certified.com","is-saved.org","is-slick.com","is-uberleet.com","is-very-bad.org","is-very-evil.org","is-very-good.org","is-very-nice.org","is-very-sweet.org","is-with-theband.com","isa-geek.com","isa-geek.net","isa-geek.org","isa-hockeynut.com","issmarterthanyou.com","isteingeek.de","istmein.de","kicks-ass.net","kicks-ass.org","knowsitall.info","land-4-sale.us","lebtimnetz.de","leitungsen.de","likes-pie.com","likescandy.com","merseine.nu","mine.nu","misconfused.org","mypets.ws","myphotos.cc","neat-url.com","office-on-the.net","on-the-web.tv","podzone.net","podzone.org","readmyblog.org","saves-the-whales.com","scrapper-site.net","scrapping.cc","selfip.biz","selfip.com","selfip.info","selfip.net","selfip.org","sells-for-less.com","sells-for-u.com","sells-it.net","sellsyourhome.org","servebbs.com","servebbs.net","servebbs.org","serveftp.net","serveftp.org","servegame.org","shacknet.nu","simple-url.com","space-to-rent.com","stuff-4-sale.org","stuff-4-sale.us","teaches-yoga.com","thruhere.net","traeumtgerade.de","webhop.biz","webhop.info","webhop.net","webhop.org","worse-than.tv","writesthisblog.com","ddnss.de","dyn.ddnss.de","dyndns.ddnss.de","dyndns1.de","dyn-ip24.de","home-webserver.de","dyn.home-webserver.de","myhome-server.de","ddnss.org","definima.net","definima.io","ondigitalocean.app","*.digitaloceanspaces.com","bci.dnstrace.pro","ddnsfree.com","ddnsgeek.com","giize.com","gleeze.com","kozow.com","loseyourip.com","ooguy.com","theworkpc.com","casacam.net","dynu.net","accesscam.org","camdvr.org","freeddns.org","mywire.org","webredirect.org","myddns.rocks","blogsite.xyz","dynv6.net","e4.cz","eero.online","eero-stage.online","elementor.cloud","elementor.cool","en-root.fr","mytuleap.com","tuleap-partners.com","encr.app","encoreapi.com","onred.one","staging.onred.one","eu.encoway.cloud","eu.org","al.eu.org","asso.eu.org","at.eu.org","au.eu.org","be.eu.org","bg.eu.org","ca.eu.org","cd.eu.org","ch.eu.org","cn.eu.org","cy.eu.org","cz.eu.org","de.eu.org","dk.eu.org","edu.eu.org","ee.eu.org","es.eu.org","fi.eu.org","fr.eu.org","gr.eu.org","hr.eu.org","hu.eu.org","ie.eu.org","il.eu.org","in.eu.org","int.eu.org","is.eu.org","it.eu.org","jp.eu.org","kr.eu.org","lt.eu.org","lu.eu.org","lv.eu.org","mc.eu.org","me.eu.org","mk.eu.org","mt.eu.org","my.eu.org","net.eu.org","ng.eu.org","nl.eu.org","no.eu.org","nz.eu.org","paris.eu.org","pl.eu.org","pt.eu.org","q-a.eu.org","ro.eu.org","ru.eu.org","se.eu.org","si.eu.org","sk.eu.org","tr.eu.org","uk.eu.org","us.eu.org","eurodir.ru","eu-1.evennode.com","eu-2.evennode.com","eu-3.evennode.com","eu-4.evennode.com","us-1.evennode.com","us-2.evennode.com","us-3.evennode.com","us-4.evennode.com","twmail.cc","twmail.net","twmail.org","mymailer.com.tw","url.tw","onfabrica.com","apps.fbsbx.com","ru.net","adygeya.ru","bashkiria.ru","bir.ru","cbg.ru","com.ru","dagestan.ru","grozny.ru","kalmykia.ru","kustanai.ru","marine.ru","mordovia.ru","msk.ru","mytis.ru","nalchik.ru","nov.ru","pyatigorsk.ru","spb.ru","vladikavkaz.ru","vladimir.ru","abkhazia.su","adygeya.su","aktyubinsk.su","arkhangelsk.su","armenia.su","ashgabad.su","azerbaijan.su","balashov.su","bashkiria.su","bryansk.su","bukhara.su","chimkent.su","dagestan.su","east-kazakhstan.su","exnet.su","georgia.su","grozny.su","ivanovo.su","jambyl.su","kalmykia.su","kaluga.su","karacol.su","karaganda.su","karelia.su","khakassia.su","krasnodar.su","kurgan.su","kustanai.su","lenug.su","mangyshlak.su","mordovia.su","msk.su","murmansk.su","nalchik.su","navoi.su","north-kazakhstan.su","nov.su","obninsk.su","penza.su","pokrovsk.su","sochi.su","spb.su","tashkent.su","termez.su","togliatti.su","troitsk.su","tselinograd.su","tula.su","tuva.su","vladikavkaz.su","vladimir.su","vologda.su","channelsdvr.net","u.channelsdvr.net","edgecompute.app","fastly-terrarium.com","fastlylb.net","map.fastlylb.net","freetls.fastly.net","map.fastly.net","a.prod.fastly.net","global.prod.fastly.net","a.ssl.fastly.net","b.ssl.fastly.net","global.ssl.fastly.net","fastvps-server.com","fastvps.host","myfast.host","fastvps.site","myfast.space","fedorainfracloud.org","fedorapeople.org","cloud.fedoraproject.org","app.os.fedoraproject.org","app.os.stg.fedoraproject.org","conn.uk","copro.uk","hosp.uk","mydobiss.com","fh-muenster.io","filegear.me","filegear-au.me","filegear-de.me","filegear-gb.me","filegear-ie.me","filegear-jp.me","filegear-sg.me","firebaseapp.com","fireweb.app","flap.id","onflashdrive.app","fldrv.com","fly.dev","edgeapp.net","shw.io","flynnhosting.net","forgeblocks.com","id.forgerock.io","framer.app","framercanvas.com","*.frusky.de","ravpage.co.il","0e.vc","freebox-os.com","freeboxos.com","fbx-os.fr","fbxos.fr","freebox-os.fr","freeboxos.fr","freedesktop.org","freemyip.com","wien.funkfeuer.at","*.futurecms.at","*.ex.futurecms.at","*.in.futurecms.at","futurehosting.at","futuremailing.at","*.ex.ortsinfo.at","*.kunden.ortsinfo.at","*.statics.cloud","independent-commission.uk","independent-inquest.uk","independent-inquiry.uk","independent-panel.uk","independent-review.uk","public-inquiry.uk","royal-commission.uk","campaign.gov.uk","service.gov.uk","api.gov.uk","gehirn.ne.jp","usercontent.jp","gentapps.com","gentlentapis.com","lab.ms","cdn-edges.net","ghost.io","gsj.bz","githubusercontent.com","githubpreview.dev","github.io","gitlab.io","gitapp.si","gitpage.si","glitch.me","nog.community","co.ro","shop.ro","lolipop.io","angry.jp","babyblue.jp","babymilk.jp","backdrop.jp","bambina.jp","bitter.jp","blush.jp","boo.jp","boy.jp","boyfriend.jp","but.jp","candypop.jp","capoo.jp","catfood.jp","cheap.jp","chicappa.jp","chillout.jp","chips.jp","chowder.jp","chu.jp","ciao.jp","cocotte.jp","coolblog.jp","cranky.jp","cutegirl.jp","daa.jp","deca.jp","deci.jp","digick.jp","egoism.jp","fakefur.jp","fem.jp","flier.jp","floppy.jp","fool.jp","frenchkiss.jp","girlfriend.jp","girly.jp","gloomy.jp","gonna.jp","greater.jp","hacca.jp","heavy.jp","her.jp","hiho.jp","hippy.jp","holy.jp","hungry.jp","icurus.jp","itigo.jp","jellybean.jp","kikirara.jp","kill.jp","kilo.jp","kuron.jp","littlestar.jp","lolipopmc.jp","lolitapunk.jp","lomo.jp","lovepop.jp","lovesick.jp","main.jp","mods.jp","mond.jp","mongolian.jp","moo.jp","namaste.jp","nikita.jp","nobushi.jp","noor.jp","oops.jp","parallel.jp","parasite.jp","pecori.jp","peewee.jp","penne.jp","pepper.jp","perma.jp","pigboat.jp","pinoko.jp","punyu.jp","pupu.jp","pussycat.jp","pya.jp","raindrop.jp","readymade.jp","sadist.jp","schoolbus.jp","secret.jp","staba.jp","stripper.jp","sub.jp","sunnyday.jp","thick.jp","tonkotsu.jp","under.jp","upper.jp","velvet.jp","verse.jp","versus.jp","vivian.jp","watson.jp","weblike.jp","whitesnow.jp","zombie.jp","heteml.net","cloudapps.digital","london.cloudapps.digital","pymnt.uk","homeoffice.gov.uk","ro.im","goip.de","run.app","a.run.app","web.app","*.0emm.com","appspot.com","*.r.appspot.com","codespot.com","googleapis.com","googlecode.com","pagespeedmobilizer.com","publishproxy.com","withgoogle.com","withyoutube.com","*.gateway.dev","cloud.goog","translate.goog","*.usercontent.goog","cloudfunctions.net","blogspot.ae","blogspot.al","blogspot.am","blogspot.ba","blogspot.be","blogspot.bg","blogspot.bj","blogspot.ca","blogspot.cf","blogspot.ch","blogspot.cl","blogspot.co.at","blogspot.co.id","blogspot.co.il","blogspot.co.ke","blogspot.co.nz","blogspot.co.uk","blogspot.co.za","blogspot.com","blogspot.com.ar","blogspot.com.au","blogspot.com.br","blogspot.com.by","blogspot.com.co","blogspot.com.cy","blogspot.com.ee","blogspot.com.eg","blogspot.com.es","blogspot.com.mt","blogspot.com.ng","blogspot.com.tr","blogspot.com.uy","blogspot.cv","blogspot.cz","blogspot.de","blogspot.dk","blogspot.fi","blogspot.fr","blogspot.gr","blogspot.hk","blogspot.hr","blogspot.hu","blogspot.ie","blogspot.in","blogspot.is","blogspot.it","blogspot.jp","blogspot.kr","blogspot.li","blogspot.lt","blogspot.lu","blogspot.md","blogspot.mk","blogspot.mr","blogspot.mx","blogspot.my","blogspot.nl","blogspot.no","blogspot.pe","blogspot.pt","blogspot.qa","blogspot.re","blogspot.ro","blogspot.rs","blogspot.ru","blogspot.se","blogspot.sg","blogspot.si","blogspot.sk","blogspot.sn","blogspot.td","blogspot.tw","blogspot.ug","blogspot.vn","goupile.fr","gov.nl","awsmppl.com","günstigbestellen.de","günstigliefern.de","fin.ci","free.hr","caa.li","ua.rs","conf.se","hs.zone","hs.run","hashbang.sh","hasura.app","hasura-app.io","pages.it.hs-heilbronn.de","hepforge.org","herokuapp.com","herokussl.com","ravendb.cloud","myravendb.com","ravendb.community","ravendb.me","development.run","ravendb.run","homesklep.pl","secaas.hk","hoplix.shop","orx.biz","biz.gl","col.ng","firm.ng","gen.ng","ltd.ng","ngo.ng","edu.scot","sch.so","hostyhosting.io","häkkinen.fi","*.moonscale.io","moonscale.net","iki.fi","ibxos.it","iliadboxos.it","impertrixcdn.com","impertrix.com","smushcdn.com","wphostedmail.com","wpmucdn.com","tempurl.host","wpmudev.host","dyn-berlin.de","in-berlin.de","in-brb.de","in-butter.de","in-dsl.de","in-dsl.net","in-dsl.org","in-vpn.de","in-vpn.net","in-vpn.org","biz.at","info.at","info.cx","ac.leg.br","al.leg.br","am.leg.br","ap.leg.br","ba.leg.br","ce.leg.br","df.leg.br","es.leg.br","go.leg.br","ma.leg.br","mg.leg.br","ms.leg.br","mt.leg.br","pa.leg.br","pb.leg.br","pe.leg.br","pi.leg.br","pr.leg.br","rj.leg.br","rn.leg.br","ro.leg.br","rr.leg.br","rs.leg.br","sc.leg.br","se.leg.br","sp.leg.br","to.leg.br","pixolino.com","na4u.ru","iopsys.se","ipifony.net","iservschule.de","mein-iserv.de","schulplattform.de","schulserver.de","test-iserv.de","iserv.dev","iobb.net","mel.cloudlets.com.au","cloud.interhostsolutions.be","users.scale.virtualcloud.com.br","mycloud.by","alp1.ae.flow.ch","appengine.flow.ch","es-1.axarnet.cloud","diadem.cloud","vip.jelastic.cloud","jele.cloud","it1.eur.aruba.jenv-aruba.cloud","it1.jenv-aruba.cloud","keliweb.cloud","cs.keliweb.cloud","oxa.cloud","tn.oxa.cloud","uk.oxa.cloud","primetel.cloud","uk.primetel.cloud","ca.reclaim.cloud","uk.reclaim.cloud","us.reclaim.cloud","ch.trendhosting.cloud","de.trendhosting.cloud","jele.club","amscompute.com","clicketcloud.com","dopaas.com","hidora.com","paas.hosted-by-previder.com","rag-cloud.hosteur.com","rag-cloud-ch.hosteur.com","jcloud.ik-server.com","jcloud-ver-jpc.ik-server.com","demo.jelastic.com","kilatiron.com","paas.massivegrid.com","jed.wafaicloud.com","lon.wafaicloud.com","ryd.wafaicloud.com","j.scaleforce.com.cy","jelastic.dogado.eu","fi.cloudplatform.fi","demo.datacenter.fi","paas.datacenter.fi","jele.host","mircloud.host","paas.beebyte.io","sekd1.beebyteapp.io","jele.io","cloud-fr1.unispace.io","jc.neen.it","cloud.jelastic.open.tim.it","jcloud.kz","upaas.kazteleport.kz","cloudjiffy.net","fra1-de.cloudjiffy.net","west1-us.cloudjiffy.net","jls-sto1.elastx.net","jls-sto2.elastx.net","jls-sto3.elastx.net","faststacks.net","fr-1.paas.massivegrid.net","lon-1.paas.massivegrid.net","lon-2.paas.massivegrid.net","ny-1.paas.massivegrid.net","ny-2.paas.massivegrid.net","sg-1.paas.massivegrid.net","jelastic.saveincloud.net","nordeste-idc.saveincloud.net","j.scaleforce.net","jelastic.tsukaeru.net","sdscloud.pl","unicloud.pl","mircloud.ru","jelastic.regruhosting.ru","enscaled.sg","jele.site","jelastic.team","orangecloud.tn","j.layershift.co.uk","phx.enscaled.us","mircloud.us","myjino.ru","*.hosting.myjino.ru","*.landing.myjino.ru","*.spectrum.myjino.ru","*.vps.myjino.ru","jotelulu.cloud","*.triton.zone","*.cns.joyent.com","js.org","kaas.gg","khplay.nl","ktistory.com","kapsi.fi","keymachine.de","kinghost.net","uni5.net","knightpoint.systems","koobin.events","oya.to","kuleuven.cloud","ezproxy.kuleuven.be","co.krd","edu.krd","krellian.net","webthings.io","git-repos.de","lcube-server.de","svn-repos.de","leadpages.co","lpages.co","lpusercontent.com","lelux.site","co.business","co.education","co.events","co.financial","co.network","co.place","co.technology","app.lmpm.com","linkyard.cloud","linkyard-cloud.ch","members.linode.com","*.nodebalancer.linode.com","*.linodeobjects.com","ip.linodeusercontent.com","we.bs","*.user.localcert.dev","localzone.xyz","loginline.app","loginline.dev","loginline.io","loginline.services","loginline.site","servers.run","lohmus.me","krasnik.pl","leczna.pl","lubartow.pl","lublin.pl","poniatowa.pl","swidnik.pl","glug.org.uk","lug.org.uk","lugs.org.uk","barsy.bg","barsy.co.uk","barsyonline.co.uk","barsycenter.com","barsyonline.com","barsy.club","barsy.de","barsy.eu","barsy.in","barsy.info","barsy.io","barsy.me","barsy.menu","barsy.mobi","barsy.net","barsy.online","barsy.org","barsy.pro","barsy.pub","barsy.ro","barsy.shop","barsy.site","barsy.support","barsy.uk","*.magentosite.cloud","mayfirst.info","mayfirst.org","hb.cldmail.ru","cn.vu","mazeplay.com","mcpe.me","mcdir.me","mcdir.ru","mcpre.ru","vps.mcdir.ru","mediatech.by","mediatech.dev","hra.health","miniserver.com","memset.net","messerli.app","*.cloud.metacentrum.cz","custom.metacentrum.cz","flt.cloud.muni.cz","usr.cloud.muni.cz","meteorapp.com","eu.meteorapp.com","co.pl","*.azurecontainer.io","azurewebsites.net","azure-mobile.net","cloudapp.net","azurestaticapps.net","1.azurestaticapps.net","centralus.azurestaticapps.net","eastasia.azurestaticapps.net","eastus2.azurestaticapps.net","westeurope.azurestaticapps.net","westus2.azurestaticapps.net","csx.cc","mintere.site","forte.id","mozilla-iot.org","bmoattachments.org","net.ru","org.ru","pp.ru","hostedpi.com","customer.mythic-beasts.com","caracal.mythic-beasts.com","fentiger.mythic-beasts.com","lynx.mythic-beasts.com","ocelot.mythic-beasts.com","oncilla.mythic-beasts.com","onza.mythic-beasts.com","sphinx.mythic-beasts.com","vs.mythic-beasts.com","x.mythic-beasts.com","yali.mythic-beasts.com","cust.retrosnub.co.uk","ui.nabu.casa","pony.club","of.fashion","in.london","of.london","from.marketing","with.marketing","for.men","repair.men","and.mom","for.mom","for.one","under.one","for.sale","that.win","from.work","to.work","cloud.nospamproxy.com","netlify.app","4u.com","ngrok.io","nh-serv.co.uk","nfshost.com","*.developer.app","noop.app","*.northflank.app","*.build.run","*.code.run","*.database.run","*.migration.run","noticeable.news","dnsking.ch","mypi.co","n4t.co","001www.com","ddnslive.com","myiphost.com","forumz.info","16-b.it","32-b.it","64-b.it","soundcast.me","tcp4.me","dnsup.net","hicam.net","now-dns.net","ownip.net","vpndns.net","dynserv.org","now-dns.org","x443.pw","now-dns.top","ntdll.top","freeddns.us","crafting.xyz","zapto.xyz","nsupdate.info","nerdpol.ovh","blogsyte.com","brasilia.me","cable-modem.org","ciscofreak.com","collegefan.org","couchpotatofries.org","damnserver.com","ddns.me","ditchyourip.com","dnsfor.me","dnsiskinky.com","dvrcam.info","dynns.com","eating-organic.net","fantasyleague.cc","geekgalaxy.com","golffan.us","health-carereform.com","homesecuritymac.com","homesecuritypc.com","hopto.me","ilovecollege.info","loginto.me","mlbfan.org","mmafan.biz","myactivedirectory.com","mydissent.net","myeffect.net","mymediapc.net","mypsx.net","mysecuritycamera.com","mysecuritycamera.net","mysecuritycamera.org","net-freaks.com","nflfan.org","nhlfan.net","no-ip.ca","no-ip.co.uk","no-ip.net","noip.us","onthewifi.com","pgafan.net","point2this.com","pointto.us","privatizehealthinsurance.net","quicksytes.com","read-books.org","securitytactics.com","serveexchange.com","servehumour.com","servep2p.com","servesarcasm.com","stufftoread.com","ufcfan.org","unusualperson.com","workisboring.com","3utilities.com","bounceme.net","ddns.net","ddnsking.com","gotdns.ch","hopto.org","myftp.biz","myftp.org","myvnc.com","no-ip.biz","no-ip.info","no-ip.org","noip.me","redirectme.net","servebeer.com","serveblog.net","servecounterstrike.com","serveftp.com","servegame.com","servehalflife.com","servehttp.com","serveirc.com","serveminecraft.net","servemp3.com","servepics.com","servequake.com","sytes.net","webhop.me","zapto.org","stage.nodeart.io","pcloud.host","nyc.mn","static.observableusercontent.com","cya.gg","omg.lol","cloudycluster.net","omniwe.site","service.one","nid.io","opensocial.site","opencraft.hosting","orsites.com","operaunite.com","tech.orange","authgear-staging.com","authgearapps.com","skygearapp.com","outsystemscloud.com","*.webpaas.ovh.net","*.hosting.ovh.net","ownprovider.com","own.pm","*.owo.codes","ox.rs","oy.lc","pgfog.com","pagefrontapp.com","pagexl.com","*.paywhirl.com","bar0.net","bar1.net","bar2.net","rdv.to","art.pl","gliwice.pl","krakow.pl","poznan.pl","wroc.pl","zakopane.pl","pantheonsite.io","gotpantheon.com","mypep.link","perspecta.cloud","lk3.ru","on-web.fr","bc.platform.sh","ent.platform.sh","eu.platform.sh","us.platform.sh","*.platformsh.site","*.tst.site","platter-app.com","platter-app.dev","platterp.us","pdns.page","plesk.page","pleskns.com","dyn53.io","onporter.run","co.bn","postman-echo.com","pstmn.io","mock.pstmn.io","httpbin.org","prequalifyme.today","xen.prgmr.com","priv.at","prvcy.page","*.dweb.link","protonet.io","chirurgiens-dentistes-en-france.fr","byen.site","pubtls.org","pythonanywhere.com","eu.pythonanywhere.com","qoto.io","qualifioapp.com","qbuser.com","cloudsite.builders","instances.spawn.cc","instantcloud.cn","ras.ru","qa2.com","qcx.io","*.sys.qcx.io","dev-myqnapcloud.com","alpha-myqnapcloud.com","myqnapcloud.com","*.quipelements.com","vapor.cloud","vaporcloud.io","rackmaze.com","rackmaze.net","g.vbrplsbx.io","*.on-k3s.io","*.on-rancher.cloud","*.on-rio.io","readthedocs.io","rhcloud.com","app.render.com","onrender.com","repl.co","id.repl.co","repl.run","resindevice.io","devices.resinstaging.io","hzc.io","wellbeingzone.eu","wellbeingzone.co.uk","adimo.co.uk","itcouldbewor.se","git-pages.rit.edu","rocky.page","биз.рус","ком.рус","крым.рус","мир.рус","мск.рус","орг.рус","самара.рус","сочи.рус","спб.рус","я.рус","*.builder.code.com","*.dev-builder.code.com","*.stg-builder.code.com","sandcats.io","logoip.de","logoip.com","fr-par-1.baremetal.scw.cloud","fr-par-2.baremetal.scw.cloud","nl-ams-1.baremetal.scw.cloud","fnc.fr-par.scw.cloud","functions.fnc.fr-par.scw.cloud","k8s.fr-par.scw.cloud","nodes.k8s.fr-par.scw.cloud","s3.fr-par.scw.cloud","s3-website.fr-par.scw.cloud","whm.fr-par.scw.cloud","priv.instances.scw.cloud","pub.instances.scw.cloud","k8s.scw.cloud","k8s.nl-ams.scw.cloud","nodes.k8s.nl-ams.scw.cloud","s3.nl-ams.scw.cloud","s3-website.nl-ams.scw.cloud","whm.nl-ams.scw.cloud","k8s.pl-waw.scw.cloud","nodes.k8s.pl-waw.scw.cloud","s3.pl-waw.scw.cloud","s3-website.pl-waw.scw.cloud","scalebook.scw.cloud","smartlabeling.scw.cloud","dedibox.fr","schokokeks.net","gov.scot","service.gov.scot","scrysec.com","firewall-gateway.com","firewall-gateway.de","my-gateway.de","my-router.de","spdns.de","spdns.eu","firewall-gateway.net","my-firewall.org","myfirewall.org","spdns.org","seidat.net","sellfy.store","senseering.net","minisite.ms","magnet.page","biz.ua","co.ua","pp.ua","shiftcrypto.dev","shiftcrypto.io","shiftedit.io","myshopblocks.com","myshopify.com","shopitsite.com","shopware.store","mo-siemens.io","1kapp.com","appchizi.com","applinzi.com","sinaapp.com","vipsinaapp.com","siteleaf.net","bounty-full.com","alpha.bounty-full.com","beta.bounty-full.com","small-web.org","vp4.me","try-snowplow.com","srht.site","stackhero-network.com","musician.io","novecore.site","static.land","dev.static.land","sites.static.land","storebase.store","vps-host.net","atl.jelastic.vps-host.net","njs.jelastic.vps-host.net","ric.jelastic.vps-host.net","playstation-cloud.com","apps.lair.io","*.stolos.io","spacekit.io","customer.speedpartner.de","myspreadshop.at","myspreadshop.com.au","myspreadshop.be","myspreadshop.ca","myspreadshop.ch","myspreadshop.com","myspreadshop.de","myspreadshop.dk","myspreadshop.es","myspreadshop.fi","myspreadshop.fr","myspreadshop.ie","myspreadshop.it","myspreadshop.net","myspreadshop.nl","myspreadshop.no","myspreadshop.pl","myspreadshop.se","myspreadshop.co.uk","api.stdlib.com","storj.farm","utwente.io","soc.srcf.net","user.srcf.net","temp-dns.com","supabase.co","supabase.in","supabase.net","su.paba.se","*.s5y.io","*.sensiosite.cloud","syncloud.it","dscloud.biz","direct.quickconnect.cn","dsmynas.com","familyds.com","diskstation.me","dscloud.me","i234.me","myds.me","synology.me","dscloud.mobi","dsmynas.net","familyds.net","dsmynas.org","familyds.org","vpnplus.to","direct.quickconnect.to","tabitorder.co.il","taifun-dns.de","beta.tailscale.net","ts.net","gda.pl","gdansk.pl","gdynia.pl","med.pl","sopot.pl","site.tb-hosting.com","edugit.io","s3.teckids.org","telebit.app","telebit.io","*.telebit.xyz","gwiddle.co.uk","*.firenet.ch","*.svc.firenet.ch","reservd.com","thingdustdata.com","cust.dev.thingdust.io","cust.disrec.thingdust.io","cust.prod.thingdust.io","cust.testing.thingdust.io","reservd.dev.thingdust.io","reservd.disrec.thingdust.io","reservd.testing.thingdust.io","tickets.io","arvo.network","azimuth.network","tlon.network","torproject.net","pages.torproject.net","bloxcms.com","townnews-staging.com","tbits.me","12hp.at","2ix.at","4lima.at","lima-city.at","12hp.ch","2ix.ch","4lima.ch","lima-city.ch","trafficplex.cloud","de.cool","12hp.de","2ix.de","4lima.de","lima-city.de","1337.pictures","clan.rip","lima-city.rocks","webspace.rocks","lima.zone","*.transurl.be","*.transurl.eu","*.transurl.nl","site.transip.me","tuxfamily.org","dd-dns.de","diskstation.eu","diskstation.org","dray-dns.de","draydns.de","dyn-vpn.de","dynvpn.de","mein-vigor.de","my-vigor.de","my-wan.de","syno-ds.de","synology-diskstation.de","synology-ds.de","typedream.app","pro.typeform.com","uber.space","*.uberspace.de","hk.com","hk.org","ltd.hk","inc.hk","name.pm","sch.tf","biz.wf","sch.wf","org.yt","virtualuser.de","virtual-user.de","upli.io","urown.cloud","dnsupdate.info","lib.de.us","2038.io","vercel.app","vercel.dev","now.sh","router.management","v-info.info","voorloper.cloud","neko.am","nyaa.am","be.ax","cat.ax","es.ax","eu.ax","gg.ax","mc.ax","us.ax","xy.ax","nl.ci","xx.gl","app.gp","blog.gt","de.gt","to.gt","be.gy","cc.hn","blog.kg","io.kg","jp.kg","tv.kg","uk.kg","us.kg","de.ls","at.md","de.md","jp.md","to.md","indie.porn","vxl.sh","ch.tc","me.tc","we.tc","nyan.to","at.vg","blog.vu","dev.vu","me.vu","v.ua","*.vultrobjects.com","wafflecell.com","*.webhare.dev","reserve-online.net","reserve-online.com","bookonline.app","hotelwithflight.com","wedeploy.io","wedeploy.me","wedeploy.sh","remotewd.com","pages.wiardweb.com","wmflabs.org","toolforge.org","wmcloud.org","panel.gg","daemon.panel.gg","messwithdns.com","woltlab-demo.com","myforum.community","community-pro.de","diskussionsbereich.de","community-pro.net","meinforum.net","affinitylottery.org.uk","raffleentry.org.uk","weeklylottery.org.uk","wpenginepowered.com","js.wpenginepowered.com","wixsite.com","editorx.io","half.host","xnbay.com","u2.xnbay.com","u2-local.xnbay.com","cistron.nl","demon.nl","xs4all.space","yandexcloud.net","storage.yandexcloud.net","website.yandexcloud.net","official.academy","yolasite.com","ybo.faith","yombo.me","homelink.one","ybo.party","ybo.review","ybo.science","ybo.trade","ynh.fr","nohost.me","noho.st","za.net","za.org","bss.design","basicserver.io","virtualserver.io","enterprisecloud.nu"];(function(t){var e=requirePunycode(),n={};n.rules=require$$1$4.map(function(o){return{rule:o,suffix:o.replace(/^(\*\.|\!)/,""),punySuffix:-1,wildcard:o.charAt(0)==="*",exception:o.charAt(0)==="!"}}),n.endsWith=function(o,u){return o.indexOf(u,o.length-u.length)!==-1},n.findRule=function(o){var u=e.toASCII(o);return n.rules.reduce(function(l,m){return m.punySuffix===-1&&(m.punySuffix=e.toASCII(m.suffix)),!n.endsWith(u,"."+m.punySuffix)&&u!==m.punySuffix?l:m},null)},t.errorCodes={DOMAIN_TOO_SHORT:"Domain name too short.",DOMAIN_TOO_LONG:"Domain name too long. It should be no more than 255 chars.",LABEL_STARTS_WITH_DASH:"Domain name label can not start with a dash.",LABEL_ENDS_WITH_DASH:"Domain name label can not end with a dash.",LABEL_TOO_LONG:"Domain name label should be at most 63 chars long.",LABEL_TOO_SHORT:"Domain name label should be at least 1 character long.",LABEL_INVALID_CHARS:"Domain name label can only contain alphanumeric characters or dashes."},n.validate=function(o){var u=e.toASCII(o);if(u.length<1)return"DOMAIN_TOO_SHORT";if(u.length>255)return"DOMAIN_TOO_LONG";for(var l=u.split("."),m,y=0;y<l.length;++y){if(m=l[y],!m.length)return"LABEL_TOO_SHORT";if(m.length>63)return"LABEL_TOO_LONG";if(m.charAt(0)==="-")return"LABEL_STARTS_WITH_DASH";if(m.charAt(m.length-1)==="-")return"LABEL_ENDS_WITH_DASH";if(!/^[a-z0-9\-]+$/.test(m))return"LABEL_INVALID_CHARS"}},t.parse=function(o){if(typeof o!="string")throw new TypeError("Domain name must be a string.");var u=o.slice(0).toLowerCase();u.charAt(u.length-1)==="."&&(u=u.slice(0,u.length-1));var l=n.validate(u);if(l)return{input:o,error:{message:t.errorCodes[l],code:l}};var m={input:o,tld:null,sld:null,domain:null,subdomain:null,listed:!1},y=u.split(".");if(y[y.length-1]==="local")return m;var E=function(){return/xn--/.test(u)&&(m.domain&&(m.domain=e.toASCII(m.domain)),m.subdomain&&(m.subdomain=e.toASCII(m.subdomain))),m},C=n.findRule(u);if(!C)return y.length<2?m:(m.tld=y.pop(),m.sld=y.pop(),m.domain=[m.sld,m.tld].join("."),y.length&&(m.subdomain=y.pop()),E());m.listed=!0;var k=C.suffix.split("."),A=y.slice(0,y.length-k.length);return C.exception&&A.push(k.shift()),m.tld=k.join("."),!A.length||(C.wildcard&&(k.unshift(A.pop()),m.tld=k.join(".")),!A.length)||(m.sld=A.pop(),m.domain=[m.sld,m.tld].join("."),A.length&&(m.subdomain=A.join("."))),E()},t.get=function(o){return o&&t.parse(o).domain||null},t.isValid=function(o){var u=t.parse(o);return!!(u.domain&&u.listed)}})(psl$1);/*!
 * Copyright (c) 2018, Salesforce.com, Inc.
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * 1. Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright notice,
 * this list of conditions and the following disclaimer in the documentation
 * and/or other materials provided with the distribution.
 *
 * 3. Neither the name of Salesforce.com nor the names of its contributors may
 * be used to endorse or promote products derived from this software without
 * specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */var psl=psl$1;function getPublicSuffix(t){return psl.get(t)}pubsuffixPsl.getPublicSuffix=getPublicSuffix;var store={};/*!
 * Copyright (c) 2015, Salesforce.com, Inc.
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * 1. Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright notice,
 * this list of conditions and the following disclaimer in the documentation
 * and/or other materials provided with the distribution.
 *
 * 3. Neither the name of Salesforce.com nor the names of its contributors may
 * be used to endorse or promote products derived from this software without
 * specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */function Store$2(){}store.Store=Store$2,Store$2.prototype.synchronous=!1,Store$2.prototype.findCookie=function(t,e,n,o){throw new Error("findCookie is not implemented")},Store$2.prototype.findCookies=function(t,e,n){throw new Error("findCookies is not implemented")},Store$2.prototype.putCookie=function(t,e){throw new Error("putCookie is not implemented")},Store$2.prototype.updateCookie=function(t,e,n){throw new Error("updateCookie is not implemented")},Store$2.prototype.removeCookie=function(t,e,n,o){throw new Error("removeCookie is not implemented")},Store$2.prototype.removeCookies=function(t,e,n){throw new Error("removeCookies is not implemented")},Store$2.prototype.removeAllCookies=function(t){throw new Error("removeAllCookies is not implemented")},Store$2.prototype.getAllCookies=function(t){throw new Error("getAllCookies is not implemented (therefore jar cannot be serialized)")};var memstore={},permuteDomain$2={};/*!
 * Copyright (c) 2015, Salesforce.com, Inc.
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * 1. Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright notice,
 * this list of conditions and the following disclaimer in the documentation
 * and/or other materials provided with the distribution.
 *
 * 3. Neither the name of Salesforce.com nor the names of its contributors may
 * be used to endorse or promote products derived from this software without
 * specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */var pubsuffix$1=pubsuffixPsl;function permuteDomain$1(t){var e=pubsuffix$1.getPublicSuffix(t);if(!e)return null;if(e==t)return[t];for(var n=t.slice(0,-(e.length+1)),o=n.split(".").reverse(),u=e,l=[u];o.length;)u=o.shift()+"."+u,l.push(u);return l}permuteDomain$2.permuteDomain=permuteDomain$1;var pathMatch$3={};/*!
 * Copyright (c) 2015, Salesforce.com, Inc.
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * 1. Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright notice,
 * this list of conditions and the following disclaimer in the documentation
 * and/or other materials provided with the distribution.
 *
 * 3. Neither the name of Salesforce.com nor the names of its contributors may
 * be used to endorse or promote products derived from this software without
 * specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */function pathMatch$2(t,e){if(e===t)return!0;var n=t.indexOf(e);return n===0&&(e.substr(-1)==="/"||t.substr(e.length,1)==="/")}pathMatch$3.pathMatch=pathMatch$2;/*!
 * Copyright (c) 2015, Salesforce.com, Inc.
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * 1. Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright notice,
 * this list of conditions and the following disclaimer in the documentation
 * and/or other materials provided with the distribution.
 *
 * 3. Neither the name of Salesforce.com nor the names of its contributors may
 * be used to endorse or promote products derived from this software without
 * specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */var Store$1=store.Store,permuteDomain=permuteDomain$2.permuteDomain,pathMatch$1=pathMatch$3.pathMatch,util$5=util$6;function MemoryCookieStore$1(){Store$1.call(this),this.idx={}}util$5.inherits(MemoryCookieStore$1,Store$1),memstore.MemoryCookieStore=MemoryCookieStore$1,MemoryCookieStore$1.prototype.idx=null,MemoryCookieStore$1.prototype.synchronous=!0,MemoryCookieStore$1.prototype.inspect=function(){return"{ idx: "+util$5.inspect(this.idx,!1,2)+" }"},util$5.inspect.custom&&(MemoryCookieStore$1.prototype[util$5.inspect.custom]=MemoryCookieStore$1.prototype.inspect),MemoryCookieStore$1.prototype.findCookie=function(t,e,n,o){return!this.idx[t]||!this.idx[t][e]?o(null,void 0):o(null,this.idx[t][e][n]||null)},MemoryCookieStore$1.prototype.findCookies=function(t,e,n){var o=[];if(!t)return n(null,[]);var u;e?u=function(E){Object.keys(E).forEach(function(C){if(pathMatch$1(e,C)){var k=E[C];for(var A in k)o.push(k[A])}})}:u=function(E){for(var C in E){var k=E[C];for(var A in k)o.push(k[A])}};var l=permuteDomain(t)||[t],m=this.idx;l.forEach(function(y){var E=m[y];E&&u(E)}),n(null,o)},MemoryCookieStore$1.prototype.putCookie=function(t,e){this.idx[t.domain]||(this.idx[t.domain]={}),this.idx[t.domain][t.path]||(this.idx[t.domain][t.path]={}),this.idx[t.domain][t.path][t.key]=t,e(null)},MemoryCookieStore$1.prototype.updateCookie=function(t,e,n){this.putCookie(e,n)},MemoryCookieStore$1.prototype.removeCookie=function(t,e,n,o){this.idx[t]&&this.idx[t][e]&&this.idx[t][e][n]&&delete this.idx[t][e][n],o(null)},MemoryCookieStore$1.prototype.removeCookies=function(t,e,n){return this.idx[t]&&(e?delete this.idx[t][e]:delete this.idx[t]),n(null)},MemoryCookieStore$1.prototype.removeAllCookies=function(t){return this.idx={},t(null)},MemoryCookieStore$1.prototype.getAllCookies=function(t){var e=[],n=this.idx,o=Object.keys(n);o.forEach(function(u){var l=Object.keys(n[u]);l.forEach(function(m){var y=Object.keys(n[u][m]);y.forEach(function(E){E!==null&&e.push(n[u][m][E])})})}),e.sort(function(u,l){return(u.creationIndex||0)-(l.creationIndex||0)}),t(null,e)};var version$2="2.5.0";/*!
 * Copyright (c) 2015, Salesforce.com, Inc.
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * 1. Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright notice,
 * this list of conditions and the following disclaimer in the documentation
 * and/or other materials provided with the distribution.
 *
 * 3. Neither the name of Salesforce.com nor the names of its contributors may
 * be used to endorse or promote products derived from this software without
 * specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */var net=require$$1$5,urlParse=require$$2$2.parse,util$4=util$6,pubsuffix=pubsuffixPsl,Store=store.Store,MemoryCookieStore=memstore.MemoryCookieStore,pathMatch=pathMatch$3.pathMatch,VERSION=version$2,punycode;try{punycode=requirePunycode()}catch(t){console.warn("tough-cookie: can't load punycode; won't use punycode for domain normalization")}var COOKIE_OCTETS=/^[\x21\x23-\x2B\x2D-\x3A\x3C-\x5B\x5D-\x7E]+$/,CONTROL_CHARS=/[\x00-\x1F]/,TERMINATORS=[`
`,"\r","\0"],PATH_VALUE=/[\x20-\x3A\x3C-\x7E]+/,DATE_DELIM=/[\x09\x20-\x2F\x3B-\x40\x5B-\x60\x7B-\x7E]/,MONTH_TO_NUM={jan:0,feb:1,mar:2,apr:3,may:4,jun:5,jul:6,aug:7,sep:8,oct:9,nov:10,dec:11},NUM_TO_MONTH=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],NUM_TO_DAY=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],MAX_TIME=2147483647e3,MIN_TIME=0;function parseDigits(t,e,n,o){for(var u=0;u<t.length;){var l=t.charCodeAt(u);if(l<=47||l>=58)break;u++}return u<e||u>n||!o&&u!=t.length?null:parseInt(t.substr(0,u),10)}function parseTime(t){var e=t.split(":"),n=[0,0,0];if(e.length!==3)return null;for(var o=0;o<3;o++){var u=o==2,l=parseDigits(e[o],1,2,u);if(l===null)return null;n[o]=l}return n}function parseMonth(t){t=String(t).substr(0,3).toLowerCase();var e=MONTH_TO_NUM[t];return e>=0?e:null}function parseDate(t){if(t){var e=t.split(DATE_DELIM);if(e){for(var n=null,o=null,u=null,l=null,m=null,y=null,E=0;E<e.length;E++){var C=e[E].trim();if(C.length){var k;if(u===null&&(k=parseTime(C),k)){n=k[0],o=k[1],u=k[2];continue}if(l===null&&(k=parseDigits(C,1,2,!0),k!==null)){l=k;continue}if(m===null&&(k=parseMonth(C),k!==null)){m=k;continue}y===null&&(k=parseDigits(C,2,4,!0),k!==null&&(y=k,y>=70&&y<=99?y+=1900:y>=0&&y<=69&&(y+=2e3)))}}if(!(l===null||m===null||y===null||u===null||l<1||l>31||y<1601||n>23||o>59||u>59))return new Date(Date.UTC(y,m,l,n,o,u))}}}function formatDate(t){var e=t.getUTCDate();e=e>=10?e:"0"+e;var n=t.getUTCHours();n=n>=10?n:"0"+n;var o=t.getUTCMinutes();o=o>=10?o:"0"+o;var u=t.getUTCSeconds();return u=u>=10?u:"0"+u,NUM_TO_DAY[t.getUTCDay()]+", "+e+" "+NUM_TO_MONTH[t.getUTCMonth()]+" "+t.getUTCFullYear()+" "+n+":"+o+":"+u+" GMT"}function canonicalDomain(t){return t==null?null:(t=t.trim().replace(/^\./,""),punycode&&/[^\u0001-\u007f]/.test(t)&&(t=punycode.toASCII(t)),t.toLowerCase())}function domainMatch(t,e,n){if(t==null||e==null)return null;if(n!==!1&&(t=canonicalDomain(t),e=canonicalDomain(e)),t==e)return!0;if(net.isIP(t))return!1;var o=t.indexOf(e);return!(o<=0||t.length!==e.length+o||t.substr(o-1,1)!==".")}function defaultPath(t){if(!t||t.substr(0,1)!=="/")return"/";if(t==="/")return t;var e=t.lastIndexOf("/");return e===0?"/":t.slice(0,e)}function trimTerminator(t){for(var e=0;e<TERMINATORS.length;e++){var n=t.indexOf(TERMINATORS[e]);n!==-1&&(t=t.substr(0,n))}return t}function parseCookiePair(t,e){t=trimTerminator(t);var n=t.indexOf("=");if(e)n===0&&(t=t.substr(1),n=t.indexOf("="));else if(n<=0)return;var o,u;if(n<=0?(o="",u=t.trim()):(o=t.substr(0,n).trim(),u=t.substr(n+1).trim()),!(CONTROL_CHARS.test(o)||CONTROL_CHARS.test(u))){var l=new Cookie$1;return l.key=o,l.value=u,l}}function parse$1(t,e){(!e||typeof e!="object")&&(e={}),t=t.trim();var n=t.indexOf(";"),o=n===-1?t:t.substr(0,n),u=parseCookiePair(o,!!e.loose);if(u){if(n===-1)return u;var l=t.slice(n+1).trim();if(l.length===0)return u;for(var m=l.split(";");m.length;){var y=m.shift().trim();if(y.length!==0){var E=y.indexOf("="),C,k;switch(E===-1?(C=y,k=null):(C=y.substr(0,E),k=y.substr(E+1)),C=C.trim().toLowerCase(),k&&(k=k.trim()),C){case"expires":if(k){var A=parseDate(k);A&&(u.expires=A)}break;case"max-age":if(k&&/^-?[0-9]+$/.test(k)){var D=parseInt(k,10);u.setMaxAge(D)}break;case"domain":if(k){var P=k.trim().replace(/^\./,"");P&&(u.domain=P.toLowerCase())}break;case"path":u.path=k&&k[0]==="/"?k:null;break;case"secure":u.secure=!0;break;case"httponly":u.httpOnly=!0;break;default:u.extensions=u.extensions||[],u.extensions.push(y);break}}}return u}}function jsonParse(t){var e;try{e=JSON.parse(t)}catch(n){return n}return e}function fromJSON(t){if(!t)return null;var e;if(typeof t=="string"){if(e=jsonParse(t),e instanceof Error)return null}else e=t;for(var n=new Cookie$1,o=0;o<Cookie$1.serializableProperties.length;o++){var u=Cookie$1.serializableProperties[o];e[u]===void 0||e[u]===Cookie$1.prototype[u]||(u==="expires"||u==="creation"||u==="lastAccessed"?e[u]===null?n[u]=null:n[u]=e[u]=="Infinity"?"Infinity":new Date(e[u]):n[u]=e[u])}return n}function cookieCompare(t,e){var n=0,o=t.path?t.path.length:0,u=e.path?e.path.length:0;if(n=u-o,n!==0)return n;var l=t.creation?t.creation.getTime():MAX_TIME,m=e.creation?e.creation.getTime():MAX_TIME;return n=l-m,n!==0||(n=t.creationIndex-e.creationIndex),n}function permutePath(t){if(t==="/")return["/"];t.lastIndexOf("/")===t.length-1&&(t=t.substr(0,t.length-1));for(var e=[t];t.length>1;){var n=t.lastIndexOf("/");if(n===0)break;t=t.substr(0,n),e.push(t)}return e.push("/"),e}function getCookieContext(t){if(t instanceof Object)return t;try{t=decodeURI(t)}catch{}return urlParse(t)}function Cookie$1(t){t=t||{},Object.keys(t).forEach(function(e){Cookie$1.prototype.hasOwnProperty(e)&&Cookie$1.prototype[e]!==t[e]&&e.substr(0,1)!=="_"&&(this[e]=t[e])},this),this.creation=this.creation||new Date,Object.defineProperty(this,"creationIndex",{configurable:!1,enumerable:!1,writable:!0,value:++Cookie$1.cookiesCreated})}Cookie$1.cookiesCreated=0,Cookie$1.parse=parse$1,Cookie$1.fromJSON=fromJSON,Cookie$1.prototype.key="",Cookie$1.prototype.value="",Cookie$1.prototype.expires="Infinity",Cookie$1.prototype.maxAge=null,Cookie$1.prototype.domain=null,Cookie$1.prototype.path=null,Cookie$1.prototype.secure=!1,Cookie$1.prototype.httpOnly=!1,Cookie$1.prototype.extensions=null,Cookie$1.prototype.hostOnly=null,Cookie$1.prototype.pathIsDefault=null,Cookie$1.prototype.creation=null,Cookie$1.prototype.lastAccessed=null,Object.defineProperty(Cookie$1.prototype,"creationIndex",{configurable:!0,enumerable:!1,writable:!0,value:0}),Cookie$1.serializableProperties=Object.keys(Cookie$1.prototype).filter(function(t){return!(Cookie$1.prototype[t]instanceof Function||t==="creationIndex"||t.substr(0,1)==="_")}),Cookie$1.prototype.inspect=function(){var e=Date.now();return'Cookie="'+this.toString()+"; hostOnly="+(this.hostOnly!=null?this.hostOnly:"?")+"; aAge="+(this.lastAccessed?e-this.lastAccessed.getTime()+"ms":"?")+"; cAge="+(this.creation?e-this.creation.getTime()+"ms":"?")+'"'},util$4.inspect.custom&&(Cookie$1.prototype[util$4.inspect.custom]=Cookie$1.prototype.inspect),Cookie$1.prototype.toJSON=function(){for(var t={},e=Cookie$1.serializableProperties,n=0;n<e.length;n++){var o=e[n];this[o]!==Cookie$1.prototype[o]&&(o==="expires"||o==="creation"||o==="lastAccessed"?this[o]===null?t[o]=null:t[o]=this[o]=="Infinity"?"Infinity":this[o].toISOString():o==="maxAge"?this[o]!==null&&(t[o]=this[o]==1/0||this[o]==-1/0?this[o].toString():this[o]):this[o]!==Cookie$1.prototype[o]&&(t[o]=this[o]))}return t},Cookie$1.prototype.clone=function(){return fromJSON(this.toJSON())},Cookie$1.prototype.validate=function(){if(!COOKIE_OCTETS.test(this.value)||this.expires!=1/0&&!(this.expires instanceof Date)&&!parseDate(this.expires)||this.maxAge!=null&&this.maxAge<=0||this.path!=null&&!PATH_VALUE.test(this.path))return!1;var e=this.cdomain();if(e){if(e.match(/\.$/))return!1;var n=pubsuffix.getPublicSuffix(e);if(n==null)return!1}return!0},Cookie$1.prototype.setExpires=function(e){e instanceof Date?this.expires=e:this.expires=parseDate(e)||"Infinity"},Cookie$1.prototype.setMaxAge=function(e){e===1/0||e===-1/0?this.maxAge=e.toString():this.maxAge=e},Cookie$1.prototype.cookieString=function(){var e=this.value;return e==null&&(e=""),this.key===""?e:this.key+"="+e},Cookie$1.prototype.toString=function(){var e=this.cookieString();return this.expires!=1/0&&(this.expires instanceof Date?e+="; Expires="+formatDate(this.expires):e+="; Expires="+this.expires),this.maxAge!=null&&this.maxAge!=1/0&&(e+="; Max-Age="+this.maxAge),this.domain&&!this.hostOnly&&(e+="; Domain="+this.domain),this.path&&(e+="; Path="+this.path),this.secure&&(e+="; Secure"),this.httpOnly&&(e+="; HttpOnly"),this.extensions&&this.extensions.forEach(function(n){e+="; "+n}),e},Cookie$1.prototype.TTL=function(e){if(this.maxAge!=null)return this.maxAge<=0?0:this.maxAge*1e3;var n=this.expires;return n!=1/0?(n instanceof Date||(n=parseDate(n)||1/0),n==1/0?1/0:n.getTime()-(e||Date.now())):1/0},Cookie$1.prototype.expiryTime=function(e){if(this.maxAge!=null){var n=e||this.creation||new Date,o=this.maxAge<=0?-1/0:this.maxAge*1e3;return n.getTime()+o}return this.expires==1/0?1/0:this.expires.getTime()},Cookie$1.prototype.expiryDate=function(e){var n=this.expiryTime(e);return n==1/0?new Date(MAX_TIME):n==-1/0?new Date(MIN_TIME):new Date(n)},Cookie$1.prototype.isPersistent=function(){return this.maxAge!=null||this.expires!=1/0},Cookie$1.prototype.cdomain=Cookie$1.prototype.canonicalizedDomain=function(){return this.domain==null?null:canonicalDomain(this.domain)};function CookieJar$1(t,e){typeof e=="boolean"?e={rejectPublicSuffixes:e}:e==null&&(e={}),e.rejectPublicSuffixes!=null&&(this.rejectPublicSuffixes=e.rejectPublicSuffixes),e.looseMode!=null&&(this.enableLooseMode=e.looseMode),t||(t=new MemoryCookieStore),this.store=t}CookieJar$1.prototype.store=null,CookieJar$1.prototype.rejectPublicSuffixes=!0,CookieJar$1.prototype.enableLooseMode=!1;var CAN_BE_SYNC=[];CAN_BE_SYNC.push("setCookie"),CookieJar$1.prototype.setCookie=function(t,e,n,o){var u,l=getCookieContext(e);n instanceof Function&&(o=n,n={});var m=canonicalDomain(l.hostname),y=this.enableLooseMode;if(n.loose!=null&&(y=n.loose),t instanceof Cookie$1||(t=Cookie$1.parse(t,{loose:y})),!t)return u=new Error("Cookie failed to parse"),o(n.ignoreError?null:u);var E=n.now||new Date;if(this.rejectPublicSuffixes&&t.domain){var C=pubsuffix.getPublicSuffix(t.cdomain());if(C==null)return u=new Error("Cookie has domain set to a public suffix"),o(n.ignoreError?null:u)}if(t.domain){if(!domainMatch(m,t.cdomain(),!1))return u=new Error("Cookie not in this host's domain. Cookie:"+t.cdomain()+" Request:"+m),o(n.ignoreError?null:u);t.hostOnly==null&&(t.hostOnly=!1)}else t.hostOnly=!0,t.domain=m;if((!t.path||t.path[0]!=="/")&&(t.path=defaultPath(l.pathname),t.pathIsDefault=!0),n.http===!1&&t.httpOnly)return u=new Error("Cookie is HttpOnly and this isn't an HTTP API"),o(n.ignoreError?null:u);var k=this.store;k.updateCookie||(k.updateCookie=function(D,P,R){this.putCookie(P,R)});function A(D,P){if(D)return o(D);var R=function(B){if(B)return o(B);o(null,t)};if(P){if(n.http===!1&&P.httpOnly)return D=new Error("old Cookie is HttpOnly and this isn't an HTTP API"),o(n.ignoreError?null:D);t.creation=P.creation,t.creationIndex=P.creationIndex,t.lastAccessed=E,k.updateCookie(P,t,R)}else t.creation=t.lastAccessed=E,k.putCookie(t,R)}k.findCookie(t.domain,t.path,t.key,A)},CAN_BE_SYNC.push("getCookies"),CookieJar$1.prototype.getCookies=function(t,e,n){var o=getCookieContext(t);e instanceof Function&&(n=e,e={});var u=canonicalDomain(o.hostname),l=o.pathname||"/",m=e.secure;m==null&&o.protocol&&(o.protocol=="https:"||o.protocol=="wss:")&&(m=!0);var y=e.http;y==null&&(y=!0);var E=e.now||Date.now(),C=e.expire!==!1,k=!!e.allPaths,A=this.store;function D(P){if(P.hostOnly){if(P.domain!=u)return!1}else if(!domainMatch(u,P.domain,!1))return!1;return!k&&!pathMatch(l,P.path)||P.secure&&!m||P.httpOnly&&!y?!1:C&&P.expiryTime()<=E?(A.removeCookie(P.domain,P.path,P.key,function(){}),!1):!0}A.findCookies(u,k?null:l,function(P,R){if(P)return n(P);R=R.filter(D),e.sort!==!1&&(R=R.sort(cookieCompare));var B=new Date;R.forEach(function(F){F.lastAccessed=B}),n(null,R)})},CAN_BE_SYNC.push("getCookieString"),CookieJar$1.prototype.getCookieString=function(){var t=Array.prototype.slice.call(arguments,0),e=t.pop(),n=function(o,u){o?e(o):e(null,u.sort(cookieCompare).map(function(l){return l.cookieString()}).join("; "))};t.push(n),this.getCookies.apply(this,t)},CAN_BE_SYNC.push("getSetCookieStrings"),CookieJar$1.prototype.getSetCookieStrings=function(){var t=Array.prototype.slice.call(arguments,0),e=t.pop(),n=function(o,u){o?e(o):e(null,u.map(function(l){return l.toString()}))};t.push(n),this.getCookies.apply(this,t)},CAN_BE_SYNC.push("serialize"),CookieJar$1.prototype.serialize=function(t){var e=this.store.constructor.name;e==="Object"&&(e=null);var n={version:"tough-cookie@"+VERSION,storeType:e,rejectPublicSuffixes:!!this.rejectPublicSuffixes,cookies:[]};if(!(this.store.getAllCookies&&typeof this.store.getAllCookies=="function"))return t(new Error("store does not support getAllCookies and cannot be serialized"));this.store.getAllCookies(function(o,u){return o?t(o):(n.cookies=u.map(function(l){return l=l instanceof Cookie$1?l.toJSON():l,delete l.creationIndex,l}),t(null,n))})},CookieJar$1.prototype.toJSON=function(){return this.serializeSync()},CAN_BE_SYNC.push("_importCookies"),CookieJar$1.prototype._importCookies=function(t,e){var n=this,o=t.cookies;if(!o||!Array.isArray(o))return e(new Error("serialized jar has no cookies array"));o=o.slice();function u(l){if(l)return e(l);if(!o.length)return e(l,n);var m;try{m=fromJSON(o.shift())}catch(y){return e(y)}if(m===null)return u(null);n.store.putCookie(m,u)}u()},CookieJar$1.deserialize=function(t,e,n){arguments.length!==3&&(n=e,e=null);var o;if(typeof t=="string"){if(o=jsonParse(t),o instanceof Error)return n(o)}else o=t;var u=new CookieJar$1(e,o.rejectPublicSuffixes);u._importCookies(o,function(l){if(l)return n(l);n(null,u)})},CookieJar$1.deserializeSync=function(t,e){var n=typeof t=="string"?JSON.parse(t):t,o=new CookieJar$1(e,n.rejectPublicSuffixes);if(!o.store.synchronous)throw new Error("CookieJar store is not synchronous; use async API instead.");return o._importCookiesSync(n),o},CookieJar$1.fromJSON=CookieJar$1.deserializeSync,CookieJar$1.prototype.clone=function(t,e){arguments.length===1&&(e=t,t=null),this.serialize(function(n,o){if(n)return e(n);CookieJar$1.deserialize(o,t,e)})},CAN_BE_SYNC.push("removeAllCookies"),CookieJar$1.prototype.removeAllCookies=function(t){var e=this.store;if(e.removeAllCookies instanceof Function&&e.removeAllCookies!==Store.prototype.removeAllCookies)return e.removeAllCookies(t);e.getAllCookies(function(n,o){if(n)return t(n);if(o.length===0)return t(null);var u=0,l=[];function m(y){if(y&&l.push(y),u++,u===o.length)return t(l.length?l[0]:null)}o.forEach(function(y){e.removeCookie(y.domain,y.path,y.key,m)})})},CookieJar$1.prototype._cloneSync=syncWrap("clone"),CookieJar$1.prototype.cloneSync=function(t){if(!t.synchronous)throw new Error("CookieJar clone destination store is not synchronous; use async API instead.");return this._cloneSync(t)};function syncWrap(t){return function(){if(!this.store.synchronous)throw new Error("CookieJar store is not synchronous; use async API instead.");var e=Array.prototype.slice.call(arguments),n,o;if(e.push(function(l,m){n=l,o=m}),this[t].apply(this,e),n)throw n;return o}}CAN_BE_SYNC.forEach(function(t){CookieJar$1.prototype[t+"Sync"]=syncWrap(t)}),cookie.version=VERSION,cookie.CookieJar=CookieJar$1,cookie.Cookie=Cookie$1,cookie.Store=Store,cookie.MemoryCookieStore=MemoryCookieStore,cookie.parseDate=parseDate,cookie.formatDate=formatDate,cookie.parse=parse$1,cookie.fromJSON=fromJSON,cookie.domainMatch=domainMatch,cookie.defaultPath=defaultPath,cookie.pathMatch=pathMatch,cookie.getPublicSuffix=pubsuffix.getPublicSuffix,cookie.cookieCompare=cookieCompare,cookie.permuteDomain=permuteDomain$2.permuteDomain,cookie.permutePath=permutePath,cookie.canonicalDomain=canonicalDomain;var tough=cookie,Cookie=tough.Cookie,CookieJar=tough.CookieJar;cookies$1.parse=function(t){if(t&&t.uri&&(t=t.uri),typeof t!="string")throw new Error("The cookie function only accepts STRING as param");return Cookie.parse(t,{loose:!0})};function RequestJar(t){var e=this;e._jar=new CookieJar(t,{looseMode:!0})}RequestJar.prototype.setCookie=function(t,e,n){var o=this;return o._jar.setCookieSync(t,e,n||{})},RequestJar.prototype.getCookieString=function(t){var e=this;return e._jar.getCookieStringSync(t)},RequestJar.prototype.getCookies=function(t){var e=this;return e._jar.getCookiesSync(t)},cookies$1.jar=function(t){return new RequestJar(t)};var helpers$1={},stringify={exports:{}};(function(t,e){e=t.exports=n,e.getSerialize=o;function n(u,l,m,y){return JSON.stringify(u,o(l,y),m)}function o(u,l){var m=[],y=[];return l==null&&(l=function(E,C){return m[0]===C?"[Circular ~]":"[Circular ~."+y.slice(0,m.indexOf(C)).join(".")+"]"}),function(E,C){if(m.length>0){var k=m.indexOf(this);~k?m.splice(k+1):m.push(this),~k?y.splice(k,1/0,E):y.push(E),~m.indexOf(C)&&(C=l.call(this,E,C))}else m.push(C);return u==null?C:u.call(this,E,C)}}})(stringify,stringify.exports);var stringifyExports=stringify.exports,cryptoBrowserify={},browser$d={exports:{}},safeBuffer$2={exports:{}};const require$$0$2=getAugmentedNamespace(dist);/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */(function(t,e){var n=require$$0$2,o=n.Buffer;function u(m,y){for(var E in m)y[E]=m[E]}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?t.exports=n:(u(n,e),e.Buffer=l);function l(m,y,E){return o(m,y,E)}l.prototype=Object.create(o.prototype),u(o,l),l.from=function(m,y,E){if(typeof m=="number")throw new TypeError("Argument must not be a number");return o(m,y,E)},l.alloc=function(m,y,E){if(typeof m!="number")throw new TypeError("Argument must be a number");var C=o(m);return y!==void 0?typeof E=="string"?C.fill(y,E):C.fill(y):C.fill(0),C},l.allocUnsafe=function(m){if(typeof m!="number")throw new TypeError("Argument must be a number");return o(m)},l.allocUnsafeSlow=function(m){if(typeof m!="number")throw new TypeError("Argument must be a number");return n.SlowBuffer(m)}})(safeBuffer$2,safeBuffer$2.exports);var safeBufferExports$1=safeBuffer$2.exports,MAX_BYTES=65536,MAX_UINT32=4294967295;function oldBrowser$1(){throw new Error(`Secure random number generation is not supported by this browser.
Use Chrome, Firefox or Internet Explorer 11`)}var Buffer$B=safeBufferExports$1.Buffer,crypto$3=commonjsGlobal$1.crypto||commonjsGlobal$1.msCrypto;crypto$3&&crypto$3.getRandomValues?browser$d.exports=randomBytes$2:browser$d.exports=oldBrowser$1;function randomBytes$2(t,e){if(t>MAX_UINT32)throw new RangeError("requested too many random bytes");var n=Buffer$B.allocUnsafe(t);if(t>0)if(t>MAX_BYTES)for(var o=0;o<t;o+=MAX_BYTES)crypto$3.getRandomValues(n.slice(o,o+MAX_BYTES));else crypto$3.getRandomValues(n);return typeof e=="function"?process$1.nextTick(function(){e(null,n)}):n}var browserExports=browser$d.exports,events={exports:{}},hasRequiredEvents;function requireEvents(){if(hasRequiredEvents)return events.exports;hasRequiredEvents=1;var t=typeof Reflect=="object"?Reflect:null,e=t&&typeof t.apply=="function"?t.apply:function(ie,ue,Q){return Function.prototype.apply.call(ie,ue,Q)},n;t&&typeof t.ownKeys=="function"?n=t.ownKeys:Object.getOwnPropertySymbols?n=function(ie){return Object.getOwnPropertyNames(ie).concat(Object.getOwnPropertySymbols(ie))}:n=function(ie){return Object.getOwnPropertyNames(ie)};function o(J){console&&console.warn&&console.warn(J)}var u=Number.isNaN||function(ie){return ie!==ie};function l(){l.init.call(this)}events.exports=l,events.exports.once=j,l.EventEmitter=l,l.prototype._events=void 0,l.prototype._eventsCount=0,l.prototype._maxListeners=void 0;var m=10;function y(J){if(typeof J!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof J)}Object.defineProperty(l,"defaultMaxListeners",{enumerable:!0,get:function(){return m},set:function(J){if(typeof J!="number"||J<0||u(J))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+J+".");m=J}}),l.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},l.prototype.setMaxListeners=function(ie){if(typeof ie!="number"||ie<0||u(ie))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+ie+".");return this._maxListeners=ie,this};function E(J){return J._maxListeners===void 0?l.defaultMaxListeners:J._maxListeners}l.prototype.getMaxListeners=function(){return E(this)},l.prototype.emit=function(ie){for(var ue=[],Q=1;Q<arguments.length;Q++)ue.push(arguments[Q]);var ce=ie==="error",he=this._events;if(he!==void 0)ce=ce&&he.error===void 0;else if(!ce)return!1;if(ce){var ke;if(ue.length>0&&(ke=ue[0]),ke instanceof Error)throw ke;var L=new Error("Unhandled error."+(ke?" ("+ke.message+")":""));throw L.context=ke,L}var d=he[ie];if(d===void 0)return!1;if(typeof d=="function")e(d,this,ue);else for(var v=d.length,w=R(d,v),Q=0;Q<v;++Q)e(w[Q],this,ue);return!0};function C(J,ie,ue,Q){var ce,he,ke;if(y(ue),he=J._events,he===void 0?(he=J._events=Object.create(null),J._eventsCount=0):(he.newListener!==void 0&&(J.emit("newListener",ie,ue.listener?ue.listener:ue),he=J._events),ke=he[ie]),ke===void 0)ke=he[ie]=ue,++J._eventsCount;else if(typeof ke=="function"?ke=he[ie]=Q?[ue,ke]:[ke,ue]:Q?ke.unshift(ue):ke.push(ue),ce=E(J),ce>0&&ke.length>ce&&!ke.warned){ke.warned=!0;var L=new Error("Possible EventEmitter memory leak detected. "+ke.length+" "+String(ie)+" listeners added. Use emitter.setMaxListeners() to increase limit");L.name="MaxListenersExceededWarning",L.emitter=J,L.type=ie,L.count=ke.length,o(L)}return J}l.prototype.addListener=function(ie,ue){return C(this,ie,ue,!1)},l.prototype.on=l.prototype.addListener,l.prototype.prependListener=function(ie,ue){return C(this,ie,ue,!0)};function k(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function A(J,ie,ue){var Q={fired:!1,wrapFn:void 0,target:J,type:ie,listener:ue},ce=k.bind(Q);return ce.listener=ue,Q.wrapFn=ce,ce}l.prototype.once=function(ie,ue){return y(ue),this.on(ie,A(this,ie,ue)),this},l.prototype.prependOnceListener=function(ie,ue){return y(ue),this.prependListener(ie,A(this,ie,ue)),this},l.prototype.removeListener=function(ie,ue){var Q,ce,he,ke,L;if(y(ue),ce=this._events,ce===void 0)return this;if(Q=ce[ie],Q===void 0)return this;if(Q===ue||Q.listener===ue)--this._eventsCount===0?this._events=Object.create(null):(delete ce[ie],ce.removeListener&&this.emit("removeListener",ie,Q.listener||ue));else if(typeof Q!="function"){for(he=-1,ke=Q.length-1;ke>=0;ke--)if(Q[ke]===ue||Q[ke].listener===ue){L=Q[ke].listener,he=ke;break}if(he<0)return this;he===0?Q.shift():B(Q,he),Q.length===1&&(ce[ie]=Q[0]),ce.removeListener!==void 0&&this.emit("removeListener",ie,L||ue)}return this},l.prototype.off=l.prototype.removeListener,l.prototype.removeAllListeners=function(ie){var ue,Q,ce;if(Q=this._events,Q===void 0)return this;if(Q.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):Q[ie]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete Q[ie]),this;if(arguments.length===0){var he=Object.keys(Q),ke;for(ce=0;ce<he.length;++ce)ke=he[ce],ke!=="removeListener"&&this.removeAllListeners(ke);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(ue=Q[ie],typeof ue=="function")this.removeListener(ie,ue);else if(ue!==void 0)for(ce=ue.length-1;ce>=0;ce--)this.removeListener(ie,ue[ce]);return this};function D(J,ie,ue){var Q=J._events;if(Q===void 0)return[];var ce=Q[ie];return ce===void 0?[]:typeof ce=="function"?ue?[ce.listener||ce]:[ce]:ue?F(ce):R(ce,ce.length)}l.prototype.listeners=function(ie){return D(this,ie,!0)},l.prototype.rawListeners=function(ie){return D(this,ie,!1)},l.listenerCount=function(J,ie){return typeof J.listenerCount=="function"?J.listenerCount(ie):P.call(J,ie)},l.prototype.listenerCount=P;function P(J){var ie=this._events;if(ie!==void 0){var ue=ie[J];if(typeof ue=="function")return 1;if(ue!==void 0)return ue.length}return 0}l.prototype.eventNames=function(){return this._eventsCount>0?n(this._events):[]};function R(J,ie){for(var ue=new Array(ie),Q=0;Q<ie;++Q)ue[Q]=J[Q];return ue}function B(J,ie){for(;ie+1<J.length;ie++)J[ie]=J[ie+1];J.pop()}function F(J){for(var ie=new Array(J.length),ue=0;ue<ie.length;++ue)ie[ue]=J[ue].listener||J[ue];return ie}function j(J,ie){return new Promise(function(ue,Q){function ce(ke){J.removeListener(ie,he),Q(ke)}function he(){typeof J.removeListener=="function"&&J.removeListener("error",ce),ue([].slice.call(arguments))}Y(J,ie,he,{once:!0}),ie!=="error"&&N(J,ce,{once:!0})})}function N(J,ie,ue){typeof J.on=="function"&&Y(J,"error",ie,ue)}function Y(J,ie,ue,Q){if(typeof J.on=="function")Q.once?J.once(ie,ue):J.on(ie,ue);else if(typeof J.addEventListener=="function")J.addEventListener(ie,function ce(he){Q.once&&J.removeEventListener(ie,ce),ue(he)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof J)}return events.exports}var streamBrowser$1,hasRequiredStreamBrowser;function requireStreamBrowser(){return hasRequiredStreamBrowser||(hasRequiredStreamBrowser=1,streamBrowser$1=requireEvents().EventEmitter),streamBrowser$1}var buffer_list,hasRequiredBuffer_list;function requireBuffer_list(){if(hasRequiredBuffer_list)return buffer_list;hasRequiredBuffer_list=1;function t(R,B){var F=Object.keys(R);if(Object.getOwnPropertySymbols){var j=Object.getOwnPropertySymbols(R);B&&(j=j.filter(function(N){return Object.getOwnPropertyDescriptor(R,N).enumerable})),F.push.apply(F,j)}return F}function e(R){for(var B=1;B<arguments.length;B++){var F=arguments[B]!=null?arguments[B]:{};B%2?t(Object(F),!0).forEach(function(j){n(R,j,F[j])}):Object.getOwnPropertyDescriptors?Object.defineProperties(R,Object.getOwnPropertyDescriptors(F)):t(Object(F)).forEach(function(j){Object.defineProperty(R,j,Object.getOwnPropertyDescriptor(F,j))})}return R}function n(R,B,F){return B=m(B),B in R?Object.defineProperty(R,B,{value:F,enumerable:!0,configurable:!0,writable:!0}):R[B]=F,R}function o(R,B){if(!(R instanceof B))throw new TypeError("Cannot call a class as a function")}function u(R,B){for(var F=0;F<B.length;F++){var j=B[F];j.enumerable=j.enumerable||!1,j.configurable=!0,"value"in j&&(j.writable=!0),Object.defineProperty(R,m(j.key),j)}}function l(R,B,F){return B&&u(R.prototype,B),Object.defineProperty(R,"prototype",{writable:!1}),R}function m(R){var B=y(R,"string");return typeof B=="symbol"?B:String(B)}function y(R,B){if(typeof R!="object"||R===null)return R;var F=R[Symbol.toPrimitive];if(F!==void 0){var j=F.call(R,B||"default");if(typeof j!="object")return j;throw new TypeError("@@toPrimitive must return a primitive value.")}return(B==="string"?String:Number)(R)}var E=require$$0$2,C=E.Buffer,k=util$6,A=k.inspect,D=A&&A.custom||"inspect";function P(R,B,F){C.prototype.copy.call(R,B,F)}return buffer_list=function(){function R(){o(this,R),this.head=null,this.tail=null,this.length=0}return l(R,[{key:"push",value:function(F){var j={data:F,next:null};this.length>0?this.tail.next=j:this.head=j,this.tail=j,++this.length}},{key:"unshift",value:function(F){var j={data:F,next:this.head};this.length===0&&(this.tail=j),this.head=j,++this.length}},{key:"shift",value:function(){if(this.length!==0){var F=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,F}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(F){if(this.length===0)return"";for(var j=this.head,N=""+j.data;j=j.next;)N+=F+j.data;return N}},{key:"concat",value:function(F){if(this.length===0)return C.alloc(0);for(var j=C.allocUnsafe(F>>>0),N=this.head,Y=0;N;)P(N.data,j,Y),Y+=N.data.length,N=N.next;return j}},{key:"consume",value:function(F,j){var N;return F<this.head.data.length?(N=this.head.data.slice(0,F),this.head.data=this.head.data.slice(F)):F===this.head.data.length?N=this.shift():N=j?this._getString(F):this._getBuffer(F),N}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(F){var j=this.head,N=1,Y=j.data;for(F-=Y.length;j=j.next;){var J=j.data,ie=F>J.length?J.length:F;if(ie===J.length?Y+=J:Y+=J.slice(0,F),F-=ie,F===0){ie===J.length?(++N,j.next?this.head=j.next:this.head=this.tail=null):(this.head=j,j.data=J.slice(ie));break}++N}return this.length-=N,Y}},{key:"_getBuffer",value:function(F){var j=C.allocUnsafe(F),N=this.head,Y=1;for(N.data.copy(j),F-=N.data.length;N=N.next;){var J=N.data,ie=F>J.length?J.length:F;if(J.copy(j,j.length-F,0,ie),F-=ie,F===0){ie===J.length?(++Y,N.next?this.head=N.next:this.head=this.tail=null):(this.head=N,N.data=J.slice(ie));break}++Y}return this.length-=Y,j}},{key:D,value:function(F,j){return A(this,e(e({},j),{},{depth:0,customInspect:!1}))}}]),R}(),buffer_list}var destroy_1$1,hasRequiredDestroy;function requireDestroy(){if(hasRequiredDestroy)return destroy_1$1;hasRequiredDestroy=1;function t(m,y){var E=this,C=this._readableState&&this._readableState.destroyed,k=this._writableState&&this._writableState.destroyed;return C||k?(y?y(m):m&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process$1.nextTick(u,this,m)):process$1.nextTick(u,this,m)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(m||null,function(A){!y&&A?E._writableState?E._writableState.errorEmitted?process$1.nextTick(n,E):(E._writableState.errorEmitted=!0,process$1.nextTick(e,E,A)):process$1.nextTick(e,E,A):y?(process$1.nextTick(n,E),y(A)):process$1.nextTick(n,E)}),this)}function e(m,y){u(m,y),n(m)}function n(m){m._writableState&&!m._writableState.emitClose||m._readableState&&!m._readableState.emitClose||m.emit("close")}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function u(m,y){m.emit("error",y)}function l(m,y){var E=m._readableState,C=m._writableState;E&&E.autoDestroy||C&&C.autoDestroy?m.destroy(y):m.emit("error",y)}return destroy_1$1={destroy:t,undestroy:o,errorOrDestroy:l},destroy_1$1}var errorsBrowser={},hasRequiredErrorsBrowser;function requireErrorsBrowser(){if(hasRequiredErrorsBrowser)return errorsBrowser;hasRequiredErrorsBrowser=1;function t(y,E){y.prototype=Object.create(E.prototype),y.prototype.constructor=y,y.__proto__=E}var e={};function n(y,E,C){C||(C=Error);function k(D,P,R){return typeof E=="string"?E:E(D,P,R)}var A=function(D){t(P,D);function P(R,B,F){return D.call(this,k(R,B,F))||this}return P}(C);A.prototype.name=C.name,A.prototype.code=y,e[y]=A}function o(y,E){if(Array.isArray(y)){var C=y.length;return y=y.map(function(k){return String(k)}),C>2?"one of ".concat(E," ").concat(y.slice(0,C-1).join(", "),", or ")+y[C-1]:C===2?"one of ".concat(E," ").concat(y[0]," or ").concat(y[1]):"of ".concat(E," ").concat(y[0])}else return"of ".concat(E," ").concat(String(y))}function u(y,E,C){return y.substr(0,E.length)===E}function l(y,E,C){return(C===void 0||C>y.length)&&(C=y.length),y.substring(C-E.length,C)===E}function m(y,E,C){return typeof C!="number"&&(C=0),C+E.length>y.length?!1:y.indexOf(E,C)!==-1}return n("ERR_INVALID_OPT_VALUE",function(y,E){return'The value "'+E+'" is invalid for option "'+y+'"'},TypeError),n("ERR_INVALID_ARG_TYPE",function(y,E,C){var k;typeof E=="string"&&u(E,"not ")?(k="must not be",E=E.replace(/^not /,"")):k="must be";var A;if(l(y," argument"))A="The ".concat(y," ").concat(k," ").concat(o(E,"type"));else{var D=m(y,".")?"property":"argument";A='The "'.concat(y,'" ').concat(D," ").concat(k," ").concat(o(E,"type"))}return A+=". Received type ".concat(typeof C),A},TypeError),n("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),n("ERR_METHOD_NOT_IMPLEMENTED",function(y){return"The "+y+" method is not implemented"}),n("ERR_STREAM_PREMATURE_CLOSE","Premature close"),n("ERR_STREAM_DESTROYED",function(y){return"Cannot call "+y+" after a stream was destroyed"}),n("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),n("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),n("ERR_STREAM_WRITE_AFTER_END","write after end"),n("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),n("ERR_UNKNOWN_ENCODING",function(y){return"Unknown encoding: "+y},TypeError),n("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),errorsBrowser.codes=e,errorsBrowser}var state,hasRequiredState;function requireState(){if(hasRequiredState)return state;hasRequiredState=1;var t=requireErrorsBrowser().codes.ERR_INVALID_OPT_VALUE;function e(o,u,l){return o.highWaterMark!=null?o.highWaterMark:u?o[l]:null}function n(o,u,l,m){var y=e(u,m,l);if(y!=null){if(!(isFinite(y)&&Math.floor(y)===y)||y<0){var E=m?l:"highWaterMark";throw new t(E,y)}return Math.floor(y)}return o.objectMode?16:16*1024}return state={getHighWaterMark:n},state}var browser$c,hasRequiredBrowser$5;function requireBrowser$5(){if(hasRequiredBrowser$5)return browser$c;hasRequiredBrowser$5=1,browser$c=t;function t(n,o){if(e("noDeprecation"))return n;var u=!1;function l(){if(!u){if(e("throwDeprecation"))throw new Error(o);e("traceDeprecation")?console.trace(o):console.warn(o),u=!0}return n.apply(this,arguments)}return l}function e(n){try{if(!commonjsGlobal$1.localStorage)return!1}catch{return!1}var o=commonjsGlobal$1.localStorage[n];return o==null?!1:String(o).toLowerCase()==="true"}return browser$c}var _stream_writable$1,hasRequired_stream_writable$1;function require_stream_writable$1(){if(hasRequired_stream_writable$1)return _stream_writable$1;hasRequired_stream_writable$1=1,_stream_writable$1=ce;function t(Z){var U=this;this.next=null,this.entry=null,this.finish=function(){ee(U,Z)}}var e;ce.WritableState=ue;var n={deprecate:requireBrowser$5()},o=requireStreamBrowser(),u=require$$0$2.Buffer,l=(typeof commonjsGlobal$1<"u"?commonjsGlobal$1:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function m(Z){return u.from(Z)}function y(Z){return u.isBuffer(Z)||Z instanceof l}var E=requireDestroy(),C=requireState(),k=C.getHighWaterMark,A=requireErrorsBrowser().codes,D=A.ERR_INVALID_ARG_TYPE,P=A.ERR_METHOD_NOT_IMPLEMENTED,R=A.ERR_MULTIPLE_CALLBACK,B=A.ERR_STREAM_CANNOT_PIPE,F=A.ERR_STREAM_DESTROYED,j=A.ERR_STREAM_NULL_VALUES,N=A.ERR_STREAM_WRITE_AFTER_END,Y=A.ERR_UNKNOWN_ENCODING,J=E.errorOrDestroy;inherits_browserExports(ce,o);function ie(){}function ue(Z,U,z){e=e||require_stream_duplex$1(),Z=Z||{},typeof z!="boolean"&&(z=U instanceof e),this.objectMode=!!Z.objectMode,z&&(this.objectMode=this.objectMode||!!Z.writableObjectMode),this.highWaterMark=k(this,Z,"writableHighWaterMark",z),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var ne=Z.decodeStrings===!1;this.decodeStrings=!ne,this.defaultEncoding=Z.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(fe){p(U,fe)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=Z.emitClose!==!1,this.autoDestroy=!!Z.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}ue.prototype.getBuffer=function(){for(var U=this.bufferedRequest,z=[];U;)z.push(U),U=U.next;return z},function(){try{Object.defineProperty(ue.prototype,"buffer",{get:n.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var Q;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(Q=Function.prototype[Symbol.hasInstance],Object.defineProperty(ce,Symbol.hasInstance,{value:function(U){return Q.call(this,U)?!0:this!==ce?!1:U&&U._writableState instanceof ue}})):Q=function(U){return U instanceof this};function ce(Z){e=e||require_stream_duplex$1();var U=this instanceof e;if(!U&&!Q.call(ce,this))return new ce(Z);this._writableState=new ue(Z,this,U),this.writable=!0,Z&&(typeof Z.write=="function"&&(this._write=Z.write),typeof Z.writev=="function"&&(this._writev=Z.writev),typeof Z.destroy=="function"&&(this._destroy=Z.destroy),typeof Z.final=="function"&&(this._final=Z.final)),o.call(this)}ce.prototype.pipe=function(){J(this,new B)};function he(Z,U){var z=new N;J(Z,z),process$1.nextTick(U,z)}function ke(Z,U,z,ne){var fe;return z===null?fe=new j:typeof z!="string"&&!U.objectMode&&(fe=new D("chunk",["string","Buffer"],z)),fe?(J(Z,fe),process$1.nextTick(ne,fe),!1):!0}ce.prototype.write=function(Z,U,z){var ne=this._writableState,fe=!1,me=!ne.objectMode&&y(Z);return me&&!u.isBuffer(Z)&&(Z=m(Z)),typeof U=="function"&&(z=U,U=null),me?U="buffer":U||(U=ne.defaultEncoding),typeof z!="function"&&(z=ie),ne.ending?he(this,z):(me||ke(this,ne,Z,z))&&(ne.pendingcb++,fe=d(this,ne,me,Z,U,z)),fe},ce.prototype.cork=function(){this._writableState.corked++},ce.prototype.uncork=function(){var Z=this._writableState;Z.corked&&(Z.corked--,!Z.writing&&!Z.corked&&!Z.bufferProcessing&&Z.bufferedRequest&&b(this,Z))},ce.prototype.setDefaultEncoding=function(U){if(typeof U=="string"&&(U=U.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((U+"").toLowerCase())>-1))throw new Y(U);return this._writableState.defaultEncoding=U,this},Object.defineProperty(ce.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function L(Z,U,z){return!Z.objectMode&&Z.decodeStrings!==!1&&typeof U=="string"&&(U=u.from(U,z)),U}Object.defineProperty(ce.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function d(Z,U,z,ne,fe,me){if(!z){var de=L(U,ne,fe);ne!==de&&(z=!0,fe="buffer",ne=de)}var je=U.objectMode?1:ne.length;U.length+=je;var lt=U.length<U.highWaterMark;if(lt||(U.needDrain=!0),U.writing||U.corked){var it=U.lastBufferedRequest;U.lastBufferedRequest={chunk:ne,encoding:fe,isBuf:z,callback:me,next:null},it?it.next=U.lastBufferedRequest:U.bufferedRequest=U.lastBufferedRequest,U.bufferedRequestCount+=1}else v(Z,U,!1,je,ne,fe,me);return lt}function v(Z,U,z,ne,fe,me,de){U.writelen=ne,U.writecb=de,U.writing=!0,U.sync=!0,U.destroyed?U.onwrite(new F("write")):z?Z._writev(fe,U.onwrite):Z._write(fe,me,U.onwrite),U.sync=!1}function w(Z,U,z,ne,fe){--U.pendingcb,z?(process$1.nextTick(fe,ne),process$1.nextTick(O,Z,U),Z._writableState.errorEmitted=!0,J(Z,ne)):(fe(ne),Z._writableState.errorEmitted=!0,J(Z,ne),O(Z,U))}function c(Z){Z.writing=!1,Z.writecb=null,Z.length-=Z.writelen,Z.writelen=0}function p(Z,U){var z=Z._writableState,ne=z.sync,fe=z.writecb;if(typeof fe!="function")throw new R;if(c(z),U)w(Z,z,ne,U,fe);else{var me=h(z)||Z.destroyed;!me&&!z.corked&&!z.bufferProcessing&&z.bufferedRequest&&b(Z,z),ne?process$1.nextTick(x,Z,z,me,fe):x(Z,z,me,fe)}}function x(Z,U,z,ne){z||S(Z,U),U.pendingcb--,ne(),O(Z,U)}function S(Z,U){U.length===0&&U.needDrain&&(U.needDrain=!1,Z.emit("drain"))}function b(Z,U){U.bufferProcessing=!0;var z=U.bufferedRequest;if(Z._writev&&z&&z.next){var ne=U.bufferedRequestCount,fe=new Array(ne),me=U.corkedRequestsFree;me.entry=z;for(var de=0,je=!0;z;)fe[de]=z,z.isBuf||(je=!1),z=z.next,de+=1;fe.allBuffers=je,v(Z,U,!0,U.length,fe,"",me.finish),U.pendingcb++,U.lastBufferedRequest=null,me.next?(U.corkedRequestsFree=me.next,me.next=null):U.corkedRequestsFree=new t(U),U.bufferedRequestCount=0}else{for(;z;){var lt=z.chunk,it=z.encoding,ot=z.callback,Ct=U.objectMode?1:lt.length;if(v(Z,U,!1,Ct,lt,it,ot),z=z.next,U.bufferedRequestCount--,U.writing)break}z===null&&(U.lastBufferedRequest=null)}U.bufferedRequest=z,U.bufferProcessing=!1}ce.prototype._write=function(Z,U,z){z(new P("_write()"))},ce.prototype._writev=null,ce.prototype.end=function(Z,U,z){var ne=this._writableState;return typeof Z=="function"?(z=Z,Z=null,U=null):typeof U=="function"&&(z=U,U=null),Z!=null&&this.write(Z,U),ne.corked&&(ne.corked=1,this.uncork()),ne.ending||V(this,ne,z),this},Object.defineProperty(ce.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function h(Z){return Z.ending&&Z.length===0&&Z.bufferedRequest===null&&!Z.finished&&!Z.writing}function T(Z,U){Z._final(function(z){U.pendingcb--,z&&J(Z,z),U.prefinished=!0,Z.emit("prefinish"),O(Z,U)})}function M(Z,U){!U.prefinished&&!U.finalCalled&&(typeof Z._final=="function"&&!U.destroyed?(U.pendingcb++,U.finalCalled=!0,process$1.nextTick(T,Z,U)):(U.prefinished=!0,Z.emit("prefinish")))}function O(Z,U){var z=h(U);if(z&&(M(Z,U),U.pendingcb===0&&(U.finished=!0,Z.emit("finish"),U.autoDestroy))){var ne=Z._readableState;(!ne||ne.autoDestroy&&ne.endEmitted)&&Z.destroy()}return z}function V(Z,U,z){U.ending=!0,O(Z,U),z&&(U.finished?process$1.nextTick(z):Z.once("finish",z)),U.ended=!0,Z.writable=!1}function ee(Z,U,z){var ne=Z.entry;for(Z.entry=null;ne;){var fe=ne.callback;U.pendingcb--,fe(z),ne=ne.next}U.corkedRequestsFree.next=Z}return Object.defineProperty(ce.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(U){this._writableState&&(this._writableState.destroyed=U)}}),ce.prototype.destroy=E.destroy,ce.prototype._undestroy=E.undestroy,ce.prototype._destroy=function(Z,U){U(Z)},_stream_writable$1}var _stream_duplex$1,hasRequired_stream_duplex$1;function require_stream_duplex$1(){if(hasRequired_stream_duplex$1)return _stream_duplex$1;hasRequired_stream_duplex$1=1;var t=Object.keys||function(C){var k=[];for(var A in C)k.push(A);return k};_stream_duplex$1=m;var e=require_stream_readable$1(),n=require_stream_writable$1();inherits_browserExports(m,e);for(var o=t(n.prototype),u=0;u<o.length;u++){var l=o[u];m.prototype[l]||(m.prototype[l]=n.prototype[l])}function m(C){if(!(this instanceof m))return new m(C);e.call(this,C),n.call(this,C),this.allowHalfOpen=!0,C&&(C.readable===!1&&(this.readable=!1),C.writable===!1&&(this.writable=!1),C.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",y)))}Object.defineProperty(m.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(m.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(m.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function y(){this._writableState.ended||process$1.nextTick(E,this)}function E(C){C.end()}return Object.defineProperty(m.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(k){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=k,this._writableState.destroyed=k)}}),_stream_duplex$1}var string_decoder={},Buffer$A=safeBufferExports$1.Buffer,isEncoding=Buffer$A.isEncoding||function(t){switch(t=""+t,t&&t.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function _normalizeEncoding(t){if(!t)return"utf8";for(var e;;)switch(t){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function normalizeEncoding(t){var e=_normalizeEncoding(t);if(typeof e!="string"&&(Buffer$A.isEncoding===isEncoding||!isEncoding(t)))throw new Error("Unknown encoding: "+t);return e||t}string_decoder.StringDecoder=StringDecoder$1;function StringDecoder$1(t){this.encoding=normalizeEncoding(t);var e;switch(this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,e=4;break;case"utf8":this.fillLast=utf8FillLast,e=4;break;case"base64":this.text=base64Text,this.end=base64End,e=3;break;default:this.write=simpleWrite,this.end=simpleEnd;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Buffer$A.allocUnsafe(e)}StringDecoder$1.prototype.write=function(t){if(t.length===0)return"";var e,n;if(this.lastNeed){if(e=this.fillLast(t),e===void 0)return"";n=this.lastNeed,this.lastNeed=0}else n=0;return n<t.length?e?e+this.text(t,n):this.text(t,n):e||""},StringDecoder$1.prototype.end=utf8End,StringDecoder$1.prototype.text=utf8Text,StringDecoder$1.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length};function utf8CheckByte(t){return t<=127?0:t>>5===6?2:t>>4===14?3:t>>3===30?4:t>>6===2?-1:-2}function utf8CheckIncomplete(t,e,n){var o=e.length-1;if(o<n)return 0;var u=utf8CheckByte(e[o]);return u>=0?(u>0&&(t.lastNeed=u-1),u):--o<n||u===-2?0:(u=utf8CheckByte(e[o]),u>=0?(u>0&&(t.lastNeed=u-2),u):--o<n||u===-2?0:(u=utf8CheckByte(e[o]),u>=0?(u>0&&(u===2?u=0:t.lastNeed=u-3),u):0))}function utf8CheckExtraBytes(t,e,n){if((e[0]&192)!==128)return t.lastNeed=0,"�";if(t.lastNeed>1&&e.length>1){if((e[1]&192)!==128)return t.lastNeed=1,"�";if(t.lastNeed>2&&e.length>2&&(e[2]&192)!==128)return t.lastNeed=2,"�"}}function utf8FillLast(t){var e=this.lastTotal-this.lastNeed,n=utf8CheckExtraBytes(this,t);if(n!==void 0)return n;if(this.lastNeed<=t.length)return t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length}function utf8Text(t,e){var n=utf8CheckIncomplete(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=n;var o=t.length-(n-this.lastNeed);return t.copy(this.lastChar,0,o),t.toString("utf8",e,o)}function utf8End(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�":e}function utf16Text(t,e){if((t.length-e)%2===0){var n=t.toString("utf16le",e);if(n){var o=n.charCodeAt(n.length-1);if(o>=55296&&o<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],n.slice(0,-1)}return n}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function utf16End(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var n=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,n)}return e}function base64Text(t,e){var n=(t.length-e)%3;return n===0?t.toString("base64",e):(this.lastNeed=3-n,this.lastTotal=3,n===1?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-n))}function base64End(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function simpleWrite(t){return t.toString(this.encoding)}function simpleEnd(t){return t&&t.length?this.write(t):""}var endOfStream,hasRequiredEndOfStream;function requireEndOfStream(){if(hasRequiredEndOfStream)return endOfStream;hasRequiredEndOfStream=1;var t=requireErrorsBrowser().codes.ERR_STREAM_PREMATURE_CLOSE;function e(l){var m=!1;return function(){if(!m){m=!0;for(var y=arguments.length,E=new Array(y),C=0;C<y;C++)E[C]=arguments[C];l.apply(this,E)}}}function n(){}function o(l){return l.setHeader&&typeof l.abort=="function"}function u(l,m,y){if(typeof m=="function")return u(l,null,m);m||(m={}),y=e(y||n);var E=m.readable||m.readable!==!1&&l.readable,C=m.writable||m.writable!==!1&&l.writable,k=function(){l.writable||D()},A=l._writableState&&l._writableState.finished,D=function(){C=!1,A=!0,E||y.call(l)},P=l._readableState&&l._readableState.endEmitted,R=function(){E=!1,P=!0,C||y.call(l)},B=function(Y){y.call(l,Y)},F=function(){var Y;if(E&&!P)return(!l._readableState||!l._readableState.ended)&&(Y=new t),y.call(l,Y);if(C&&!A)return(!l._writableState||!l._writableState.ended)&&(Y=new t),y.call(l,Y)},j=function(){l.req.on("finish",D)};return o(l)?(l.on("complete",D),l.on("abort",F),l.req?j():l.on("request",j)):C&&!l._writableState&&(l.on("end",k),l.on("close",k)),l.on("end",R),l.on("finish",D),m.error!==!1&&l.on("error",B),l.on("close",F),function(){l.removeListener("complete",D),l.removeListener("abort",F),l.removeListener("request",j),l.req&&l.req.removeListener("finish",D),l.removeListener("end",k),l.removeListener("close",k),l.removeListener("finish",D),l.removeListener("end",R),l.removeListener("error",B),l.removeListener("close",F)}}return endOfStream=u,endOfStream}var async_iterator,hasRequiredAsync_iterator;function requireAsync_iterator(){if(hasRequiredAsync_iterator)return async_iterator;hasRequiredAsync_iterator=1;var t;function e(Y,J,ie){return J=n(J),J in Y?Object.defineProperty(Y,J,{value:ie,enumerable:!0,configurable:!0,writable:!0}):Y[J]=ie,Y}function n(Y){var J=o(Y,"string");return typeof J=="symbol"?J:String(J)}function o(Y,J){if(typeof Y!="object"||Y===null)return Y;var ie=Y[Symbol.toPrimitive];if(ie!==void 0){var ue=ie.call(Y,J||"default");if(typeof ue!="object")return ue;throw new TypeError("@@toPrimitive must return a primitive value.")}return(J==="string"?String:Number)(Y)}var u=requireEndOfStream(),l=Symbol("lastResolve"),m=Symbol("lastReject"),y=Symbol("error"),E=Symbol("ended"),C=Symbol("lastPromise"),k=Symbol("handlePromise"),A=Symbol("stream");function D(Y,J){return{value:Y,done:J}}function P(Y){var J=Y[l];if(J!==null){var ie=Y[A].read();ie!==null&&(Y[C]=null,Y[l]=null,Y[m]=null,J(D(ie,!1)))}}function R(Y){process$1.nextTick(P,Y)}function B(Y,J){return function(ie,ue){Y.then(function(){if(J[E]){ie(D(void 0,!0));return}J[k](ie,ue)},ue)}}var F=Object.getPrototypeOf(function(){}),j=Object.setPrototypeOf((t={get stream(){return this[A]},next:function(){var J=this,ie=this[y];if(ie!==null)return Promise.reject(ie);if(this[E])return Promise.resolve(D(void 0,!0));if(this[A].destroyed)return new Promise(function(he,ke){process$1.nextTick(function(){J[y]?ke(J[y]):he(D(void 0,!0))})});var ue=this[C],Q;if(ue)Q=new Promise(B(ue,this));else{var ce=this[A].read();if(ce!==null)return Promise.resolve(D(ce,!1));Q=new Promise(this[k])}return this[C]=Q,Q}},e(t,Symbol.asyncIterator,function(){return this}),e(t,"return",function(){var J=this;return new Promise(function(ie,ue){J[A].destroy(null,function(Q){if(Q){ue(Q);return}ie(D(void 0,!0))})})}),t),F),N=function(J){var ie,ue=Object.create(j,(ie={},e(ie,A,{value:J,writable:!0}),e(ie,l,{value:null,writable:!0}),e(ie,m,{value:null,writable:!0}),e(ie,y,{value:null,writable:!0}),e(ie,E,{value:J._readableState.endEmitted,writable:!0}),e(ie,k,{value:function(ce,he){var ke=ue[A].read();ke?(ue[C]=null,ue[l]=null,ue[m]=null,ce(D(ke,!1))):(ue[l]=ce,ue[m]=he)},writable:!0}),ie));return ue[C]=null,u(J,function(Q){if(Q&&Q.code!=="ERR_STREAM_PREMATURE_CLOSE"){var ce=ue[m];ce!==null&&(ue[C]=null,ue[l]=null,ue[m]=null,ce(Q)),ue[y]=Q;return}var he=ue[l];he!==null&&(ue[C]=null,ue[l]=null,ue[m]=null,he(D(void 0,!0))),ue[E]=!0}),J.on("readable",R.bind(null,ue)),ue};return async_iterator=N,async_iterator}var fromBrowser,hasRequiredFromBrowser;function requireFromBrowser(){return hasRequiredFromBrowser||(hasRequiredFromBrowser=1,fromBrowser=function(){throw new Error("Readable.from is not available in the browser")}),fromBrowser}var _stream_readable$1,hasRequired_stream_readable$1;function require_stream_readable$1(){if(hasRequired_stream_readable$1)return _stream_readable$1;hasRequired_stream_readable$1=1,_stream_readable$1=he;var t;he.ReadableState=ce,requireEvents().EventEmitter;var e=function(de,je){return de.listeners(je).length},n=requireStreamBrowser(),o=require$$0$2.Buffer,u=(typeof commonjsGlobal$1<"u"?commonjsGlobal$1:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function l(me){return o.from(me)}function m(me){return o.isBuffer(me)||me instanceof u}var y=util$6,E;y&&y.debuglog?E=y.debuglog("stream"):E=function(){};var C=requireBuffer_list(),k=requireDestroy(),A=requireState(),D=A.getHighWaterMark,P=requireErrorsBrowser().codes,R=P.ERR_INVALID_ARG_TYPE,B=P.ERR_STREAM_PUSH_AFTER_EOF,F=P.ERR_METHOD_NOT_IMPLEMENTED,j=P.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,N,Y,J;inherits_browserExports(he,n);var ie=k.errorOrDestroy,ue=["error","close","destroy","pause","resume"];function Q(me,de,je){if(typeof me.prependListener=="function")return me.prependListener(de,je);!me._events||!me._events[de]?me.on(de,je):Array.isArray(me._events[de])?me._events[de].unshift(je):me._events[de]=[je,me._events[de]]}function ce(me,de,je){t=t||require_stream_duplex$1(),me=me||{},typeof je!="boolean"&&(je=de instanceof t),this.objectMode=!!me.objectMode,je&&(this.objectMode=this.objectMode||!!me.readableObjectMode),this.highWaterMark=D(this,me,"readableHighWaterMark",je),this.buffer=new C,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=me.emitClose!==!1,this.autoDestroy=!!me.autoDestroy,this.destroyed=!1,this.defaultEncoding=me.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,me.encoding&&(N||(N=string_decoder.StringDecoder),this.decoder=new N(me.encoding),this.encoding=me.encoding)}function he(me){if(t=t||require_stream_duplex$1(),!(this instanceof he))return new he(me);var de=this instanceof t;this._readableState=new ce(me,this,de),this.readable=!0,me&&(typeof me.read=="function"&&(this._read=me.read),typeof me.destroy=="function"&&(this._destroy=me.destroy)),n.call(this)}Object.defineProperty(he.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(de){this._readableState&&(this._readableState.destroyed=de)}}),he.prototype.destroy=k.destroy,he.prototype._undestroy=k.undestroy,he.prototype._destroy=function(me,de){de(me)},he.prototype.push=function(me,de){var je=this._readableState,lt;return je.objectMode?lt=!0:typeof me=="string"&&(de=de||je.defaultEncoding,de!==je.encoding&&(me=o.from(me,de),de=""),lt=!0),ke(this,me,de,!1,lt)},he.prototype.unshift=function(me){return ke(this,me,null,!0,!1)};function ke(me,de,je,lt,it){E("readableAddChunk",de);var ot=me._readableState;if(de===null)ot.reading=!1,p(me,ot);else{var Ct;if(it||(Ct=d(ot,de)),Ct)ie(me,Ct);else if(ot.objectMode||de&&de.length>0)if(typeof de!="string"&&!ot.objectMode&&Object.getPrototypeOf(de)!==o.prototype&&(de=l(de)),lt)ot.endEmitted?ie(me,new j):L(me,ot,de,!0);else if(ot.ended)ie(me,new B);else{if(ot.destroyed)return!1;ot.reading=!1,ot.decoder&&!je?(de=ot.decoder.write(de),ot.objectMode||de.length!==0?L(me,ot,de,!1):b(me,ot)):L(me,ot,de,!1)}else lt||(ot.reading=!1,b(me,ot))}return!ot.ended&&(ot.length<ot.highWaterMark||ot.length===0)}function L(me,de,je,lt){de.flowing&&de.length===0&&!de.sync?(de.awaitDrain=0,me.emit("data",je)):(de.length+=de.objectMode?1:je.length,lt?de.buffer.unshift(je):de.buffer.push(je),de.needReadable&&x(me)),b(me,de)}function d(me,de){var je;return!m(de)&&typeof de!="string"&&de!==void 0&&!me.objectMode&&(je=new R("chunk",["string","Buffer","Uint8Array"],de)),je}he.prototype.isPaused=function(){return this._readableState.flowing===!1},he.prototype.setEncoding=function(me){N||(N=string_decoder.StringDecoder);var de=new N(me);this._readableState.decoder=de,this._readableState.encoding=this._readableState.decoder.encoding;for(var je=this._readableState.buffer.head,lt="";je!==null;)lt+=de.write(je.data),je=je.next;return this._readableState.buffer.clear(),lt!==""&&this._readableState.buffer.push(lt),this._readableState.length=lt.length,this};var v=1073741824;function w(me){return me>=v?me=v:(me--,me|=me>>>1,me|=me>>>2,me|=me>>>4,me|=me>>>8,me|=me>>>16,me++),me}function c(me,de){return me<=0||de.length===0&&de.ended?0:de.objectMode?1:me!==me?de.flowing&&de.length?de.buffer.head.data.length:de.length:(me>de.highWaterMark&&(de.highWaterMark=w(me)),me<=de.length?me:de.ended?de.length:(de.needReadable=!0,0))}he.prototype.read=function(me){E("read",me),me=parseInt(me,10);var de=this._readableState,je=me;if(me!==0&&(de.emittedReadable=!1),me===0&&de.needReadable&&((de.highWaterMark!==0?de.length>=de.highWaterMark:de.length>0)||de.ended))return E("read: emitReadable",de.length,de.ended),de.length===0&&de.ended?z(this):x(this),null;if(me=c(me,de),me===0&&de.ended)return de.length===0&&z(this),null;var lt=de.needReadable;E("need readable",lt),(de.length===0||de.length-me<de.highWaterMark)&&(lt=!0,E("length less than watermark",lt)),de.ended||de.reading?(lt=!1,E("reading or ended",lt)):lt&&(E("do read"),de.reading=!0,de.sync=!0,de.length===0&&(de.needReadable=!0),this._read(de.highWaterMark),de.sync=!1,de.reading||(me=c(je,de)));var it;return me>0?it=U(me,de):it=null,it===null?(de.needReadable=de.length<=de.highWaterMark,me=0):(de.length-=me,de.awaitDrain=0),de.length===0&&(de.ended||(de.needReadable=!0),je!==me&&de.ended&&z(this)),it!==null&&this.emit("data",it),it};function p(me,de){if(E("onEofChunk"),!de.ended){if(de.decoder){var je=de.decoder.end();je&&je.length&&(de.buffer.push(je),de.length+=de.objectMode?1:je.length)}de.ended=!0,de.sync?x(me):(de.needReadable=!1,de.emittedReadable||(de.emittedReadable=!0,S(me)))}}function x(me){var de=me._readableState;E("emitReadable",de.needReadable,de.emittedReadable),de.needReadable=!1,de.emittedReadable||(E("emitReadable",de.flowing),de.emittedReadable=!0,process$1.nextTick(S,me))}function S(me){var de=me._readableState;E("emitReadable_",de.destroyed,de.length,de.ended),!de.destroyed&&(de.length||de.ended)&&(me.emit("readable"),de.emittedReadable=!1),de.needReadable=!de.flowing&&!de.ended&&de.length<=de.highWaterMark,Z(me)}function b(me,de){de.readingMore||(de.readingMore=!0,process$1.nextTick(h,me,de))}function h(me,de){for(;!de.reading&&!de.ended&&(de.length<de.highWaterMark||de.flowing&&de.length===0);){var je=de.length;if(E("maybeReadMore read 0"),me.read(0),je===de.length)break}de.readingMore=!1}he.prototype._read=function(me){ie(this,new F("_read()"))},he.prototype.pipe=function(me,de){var je=this,lt=this._readableState;switch(lt.pipesCount){case 0:lt.pipes=me;break;case 1:lt.pipes=[lt.pipes,me];break;default:lt.pipes.push(me);break}lt.pipesCount+=1,E("pipe count=%d opts=%j",lt.pipesCount,de);var it=(!de||de.end!==!1)&&me!==process$1.stdout&&me!==process$1.stderr,ot=it?nt:Gt;lt.endEmitted?process$1.nextTick(ot):je.once("end",ot),me.on("unpipe",Ct);function Ct(wt,Et){E("onunpipe"),wt===je&&Et&&Et.hasUnpiped===!1&&(Et.hasUnpiped=!0,rt())}function nt(){E("onend"),me.end()}var Je=T(je);me.on("drain",Je);var tt=!1;function rt(){E("cleanup"),me.removeListener("close",Ve),me.removeListener("finish",We),me.removeListener("drain",Je),me.removeListener("error",Ot),me.removeListener("unpipe",Ct),je.removeListener("end",nt),je.removeListener("end",Gt),je.removeListener("data",ht),tt=!0,lt.awaitDrain&&(!me._writableState||me._writableState.needDrain)&&Je()}je.on("data",ht);function ht(wt){E("ondata");var Et=me.write(wt);E("dest.write",Et),Et===!1&&((lt.pipesCount===1&&lt.pipes===me||lt.pipesCount>1&&fe(lt.pipes,me)!==-1)&&!tt&&(E("false write response, pause",lt.awaitDrain),lt.awaitDrain++),je.pause())}function Ot(wt){E("onerror",wt),Gt(),me.removeListener("error",Ot),e(me,"error")===0&&ie(me,wt)}Q(me,"error",Ot);function Ve(){me.removeListener("finish",We),Gt()}me.once("close",Ve);function We(){E("onfinish"),me.removeListener("close",Ve),Gt()}me.once("finish",We);function Gt(){E("unpipe"),je.unpipe(me)}return me.emit("pipe",je),lt.flowing||(E("pipe resume"),je.resume()),me};function T(me){return function(){var je=me._readableState;E("pipeOnDrain",je.awaitDrain),je.awaitDrain&&je.awaitDrain--,je.awaitDrain===0&&e(me,"data")&&(je.flowing=!0,Z(me))}}he.prototype.unpipe=function(me){var de=this._readableState,je={hasUnpiped:!1};if(de.pipesCount===0)return this;if(de.pipesCount===1)return me&&me!==de.pipes?this:(me||(me=de.pipes),de.pipes=null,de.pipesCount=0,de.flowing=!1,me&&me.emit("unpipe",this,je),this);if(!me){var lt=de.pipes,it=de.pipesCount;de.pipes=null,de.pipesCount=0,de.flowing=!1;for(var ot=0;ot<it;ot++)lt[ot].emit("unpipe",this,{hasUnpiped:!1});return this}var Ct=fe(de.pipes,me);return Ct===-1?this:(de.pipes.splice(Ct,1),de.pipesCount-=1,de.pipesCount===1&&(de.pipes=de.pipes[0]),me.emit("unpipe",this,je),this)},he.prototype.on=function(me,de){var je=n.prototype.on.call(this,me,de),lt=this._readableState;return me==="data"?(lt.readableListening=this.listenerCount("readable")>0,lt.flowing!==!1&&this.resume()):me==="readable"&&!lt.endEmitted&&!lt.readableListening&&(lt.readableListening=lt.needReadable=!0,lt.flowing=!1,lt.emittedReadable=!1,E("on readable",lt.length,lt.reading),lt.length?x(this):lt.reading||process$1.nextTick(O,this)),je},he.prototype.addListener=he.prototype.on,he.prototype.removeListener=function(me,de){var je=n.prototype.removeListener.call(this,me,de);return me==="readable"&&process$1.nextTick(M,this),je},he.prototype.removeAllListeners=function(me){var de=n.prototype.removeAllListeners.apply(this,arguments);return(me==="readable"||me===void 0)&&process$1.nextTick(M,this),de};function M(me){var de=me._readableState;de.readableListening=me.listenerCount("readable")>0,de.resumeScheduled&&!de.paused?de.flowing=!0:me.listenerCount("data")>0&&me.resume()}function O(me){E("readable nexttick read 0"),me.read(0)}he.prototype.resume=function(){var me=this._readableState;return me.flowing||(E("resume"),me.flowing=!me.readableListening,V(this,me)),me.paused=!1,this};function V(me,de){de.resumeScheduled||(de.resumeScheduled=!0,process$1.nextTick(ee,me,de))}function ee(me,de){E("resume",de.reading),de.reading||me.read(0),de.resumeScheduled=!1,me.emit("resume"),Z(me),de.flowing&&!de.reading&&me.read(0)}he.prototype.pause=function(){return E("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(E("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function Z(me){var de=me._readableState;for(E("flow",de.flowing);de.flowing&&me.read()!==null;);}he.prototype.wrap=function(me){var de=this,je=this._readableState,lt=!1;me.on("end",function(){if(E("wrapped end"),je.decoder&&!je.ended){var Ct=je.decoder.end();Ct&&Ct.length&&de.push(Ct)}de.push(null)}),me.on("data",function(Ct){if(E("wrapped data"),je.decoder&&(Ct=je.decoder.write(Ct)),!(je.objectMode&&Ct==null)&&!(!je.objectMode&&(!Ct||!Ct.length))){var nt=de.push(Ct);nt||(lt=!0,me.pause())}});for(var it in me)this[it]===void 0&&typeof me[it]=="function"&&(this[it]=function(nt){return function(){return me[nt].apply(me,arguments)}}(it));for(var ot=0;ot<ue.length;ot++)me.on(ue[ot],this.emit.bind(this,ue[ot]));return this._read=function(Ct){E("wrapped _read",Ct),lt&&(lt=!1,me.resume())},this},typeof Symbol=="function"&&(he.prototype[Symbol.asyncIterator]=function(){return Y===void 0&&(Y=requireAsync_iterator()),Y(this)}),Object.defineProperty(he.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(he.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(he.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(de){this._readableState&&(this._readableState.flowing=de)}}),he._fromList=U,Object.defineProperty(he.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function U(me,de){if(de.length===0)return null;var je;return de.objectMode?je=de.buffer.shift():!me||me>=de.length?(de.decoder?je=de.buffer.join(""):de.buffer.length===1?je=de.buffer.first():je=de.buffer.concat(de.length),de.buffer.clear()):je=de.buffer.consume(me,de.decoder),je}function z(me){var de=me._readableState;E("endReadable",de.endEmitted),de.endEmitted||(de.ended=!0,process$1.nextTick(ne,de,me))}function ne(me,de){if(E("endReadableNT",me.endEmitted,me.length),!me.endEmitted&&me.length===0&&(me.endEmitted=!0,de.readable=!1,de.emit("end"),me.autoDestroy)){var je=de._writableState;(!je||je.autoDestroy&&je.finished)&&de.destroy()}}typeof Symbol=="function"&&(he.from=function(me,de){return J===void 0&&(J=requireFromBrowser()),J(he,me,de)});function fe(me,de){for(var je=0,lt=me.length;je<lt;je++)if(me[je]===de)return je;return-1}return _stream_readable$1}var _stream_transform$1,hasRequired_stream_transform;function require_stream_transform(){if(hasRequired_stream_transform)return _stream_transform$1;hasRequired_stream_transform=1,_stream_transform$1=y;var t=requireErrorsBrowser().codes,e=t.ERR_METHOD_NOT_IMPLEMENTED,n=t.ERR_MULTIPLE_CALLBACK,o=t.ERR_TRANSFORM_ALREADY_TRANSFORMING,u=t.ERR_TRANSFORM_WITH_LENGTH_0,l=require_stream_duplex$1();inherits_browserExports(y,l);function m(k,A){var D=this._transformState;D.transforming=!1;var P=D.writecb;if(P===null)return this.emit("error",new n);D.writechunk=null,D.writecb=null,A!=null&&this.push(A),P(k);var R=this._readableState;R.reading=!1,(R.needReadable||R.length<R.highWaterMark)&&this._read(R.highWaterMark)}function y(k){if(!(this instanceof y))return new y(k);l.call(this,k),this._transformState={afterTransform:m.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,k&&(typeof k.transform=="function"&&(this._transform=k.transform),typeof k.flush=="function"&&(this._flush=k.flush)),this.on("prefinish",E)}function E(){var k=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(A,D){C(k,A,D)}):C(this,null,null)}y.prototype.push=function(k,A){return this._transformState.needTransform=!1,l.prototype.push.call(this,k,A)},y.prototype._transform=function(k,A,D){D(new e("_transform()"))},y.prototype._write=function(k,A,D){var P=this._transformState;if(P.writecb=D,P.writechunk=k,P.writeencoding=A,!P.transforming){var R=this._readableState;(P.needTransform||R.needReadable||R.length<R.highWaterMark)&&this._read(R.highWaterMark)}},y.prototype._read=function(k){var A=this._transformState;A.writechunk!==null&&!A.transforming?(A.transforming=!0,this._transform(A.writechunk,A.writeencoding,A.afterTransform)):A.needTransform=!0},y.prototype._destroy=function(k,A){l.prototype._destroy.call(this,k,function(D){A(D)})};function C(k,A,D){if(A)return k.emit("error",A);if(D!=null&&k.push(D),k._writableState.length)throw new u;if(k._transformState.transforming)throw new o;return k.push(null)}return _stream_transform$1}var _stream_passthrough$1,hasRequired_stream_passthrough;function require_stream_passthrough(){if(hasRequired_stream_passthrough)return _stream_passthrough$1;hasRequired_stream_passthrough=1,_stream_passthrough$1=e;var t=require_stream_transform();inherits_browserExports(e,t);function e(n){if(!(this instanceof e))return new e(n);t.call(this,n)}return e.prototype._transform=function(n,o,u){u(null,n)},_stream_passthrough$1}var pipeline_1,hasRequiredPipeline;function requirePipeline(){if(hasRequiredPipeline)return pipeline_1;hasRequiredPipeline=1;var t;function e(D){var P=!1;return function(){P||(P=!0,D.apply(void 0,arguments))}}var n=requireErrorsBrowser().codes,o=n.ERR_MISSING_ARGS,u=n.ERR_STREAM_DESTROYED;function l(D){if(D)throw D}function m(D){return D.setHeader&&typeof D.abort=="function"}function y(D,P,R,B){B=e(B);var F=!1;D.on("close",function(){F=!0}),t===void 0&&(t=requireEndOfStream()),t(D,{readable:P,writable:R},function(N){if(N)return B(N);F=!0,B()});var j=!1;return function(N){if(!F&&!j){if(j=!0,m(D))return D.abort();if(typeof D.destroy=="function")return D.destroy();B(N||new u("pipe"))}}}function E(D){D()}function C(D,P){return D.pipe(P)}function k(D){return!D.length||typeof D[D.length-1]!="function"?l:D.pop()}function A(){for(var D=arguments.length,P=new Array(D),R=0;R<D;R++)P[R]=arguments[R];var B=k(P);if(Array.isArray(P[0])&&(P=P[0]),P.length<2)throw new o("streams");var F,j=P.map(function(N,Y){var J=Y<P.length-1,ie=Y>0;return y(N,J,ie,function(ue){F||(F=ue),ue&&j.forEach(E),!J&&(j.forEach(E),B(F))})});return P.reduce(C)}return pipeline_1=A,pipeline_1}var streamBrowserify,hasRequiredStreamBrowserify;function requireStreamBrowserify(){if(hasRequiredStreamBrowserify)return streamBrowserify;hasRequiredStreamBrowserify=1,streamBrowserify=n;var t=requireEvents().EventEmitter,e=inherits_browserExports;e(n,t),n.Readable=require_stream_readable$1(),n.Writable=require_stream_writable$1(),n.Duplex=require_stream_duplex$1(),n.Transform=require_stream_transform(),n.PassThrough=require_stream_passthrough(),n.finished=requireEndOfStream(),n.pipeline=requirePipeline(),n.Stream=n;function n(){t.call(this)}return n.prototype.pipe=function(o,u){var l=this;function m(P){o.writable&&o.write(P)===!1&&l.pause&&l.pause()}l.on("data",m);function y(){l.readable&&l.resume&&l.resume()}o.on("drain",y),!o._isStdio&&(!u||u.end!==!1)&&(l.on("end",C),l.on("close",k));var E=!1;function C(){E||(E=!0,o.end())}function k(){E||(E=!0,typeof o.destroy=="function"&&o.destroy())}function A(P){if(D(),t.listenerCount(this,"error")===0)throw P}l.on("error",A),o.on("error",A);function D(){l.removeListener("data",m),o.removeListener("drain",y),l.removeListener("end",C),l.removeListener("close",k),l.removeListener("error",A),o.removeListener("error",A),l.removeListener("end",D),l.removeListener("close",D),o.removeListener("close",D)}return l.on("end",D),l.on("close",D),o.on("close",D),o.emit("pipe",l),o},streamBrowserify}var Buffer$z=safeBufferExports$1.Buffer,Transform$7=requireStreamBrowserify().Transform,inherits$p=inherits_browserExports;function throwIfNotStringOrBuffer(t,e){if(!Buffer$z.isBuffer(t)&&typeof t!="string")throw new TypeError(e+" must be a string or a buffer")}function HashBase$2(t){Transform$7.call(this),this._block=Buffer$z.allocUnsafe(t),this._blockSize=t,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}inherits$p(HashBase$2,Transform$7),HashBase$2.prototype._transform=function(t,e,n){var o=null;try{this.update(t,e)}catch(u){o=u}n(o)},HashBase$2.prototype._flush=function(t){var e=null;try{this.push(this.digest())}catch(n){e=n}t(e)},HashBase$2.prototype.update=function(t,e){if(throwIfNotStringOrBuffer(t,"Data"),this._finalized)throw new Error("Digest already called");Buffer$z.isBuffer(t)||(t=Buffer$z.from(t,e));for(var n=this._block,o=0;this._blockOffset+t.length-o>=this._blockSize;){for(var u=this._blockOffset;u<this._blockSize;)n[u++]=t[o++];this._update(),this._blockOffset=0}for(;o<t.length;)n[this._blockOffset++]=t[o++];for(var l=0,m=t.length*8;m>0;++l)this._length[l]+=m,m=this._length[l]/4294967296|0,m>0&&(this._length[l]-=4294967296*m);return this},HashBase$2.prototype._update=function(){throw new Error("_update is not implemented")},HashBase$2.prototype.digest=function(t){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var e=this._digest();t!==void 0&&(e=e.toString(t)),this._block.fill(0),this._blockOffset=0;for(var n=0;n<4;++n)this._length[n]=0;return e},HashBase$2.prototype._digest=function(){throw new Error("_digest is not implemented")};var hashBase=HashBase$2,inherits$o=inherits_browserExports,HashBase$1=hashBase,Buffer$y=safeBufferExports$1.Buffer,ARRAY16$1=new Array(16);function MD5$3(){HashBase$1.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}inherits$o(MD5$3,HashBase$1),MD5$3.prototype._update=function(){for(var t=ARRAY16$1,e=0;e<16;++e)t[e]=this._block.readInt32LE(e*4);var n=this._a,o=this._b,u=this._c,l=this._d;n=fnF(n,o,u,l,t[0],3614090360,7),l=fnF(l,n,o,u,t[1],3905402710,12),u=fnF(u,l,n,o,t[2],606105819,17),o=fnF(o,u,l,n,t[3],3250441966,22),n=fnF(n,o,u,l,t[4],4118548399,7),l=fnF(l,n,o,u,t[5],1200080426,12),u=fnF(u,l,n,o,t[6],2821735955,17),o=fnF(o,u,l,n,t[7],4249261313,22),n=fnF(n,o,u,l,t[8],1770035416,7),l=fnF(l,n,o,u,t[9],2336552879,12),u=fnF(u,l,n,o,t[10],4294925233,17),o=fnF(o,u,l,n,t[11],2304563134,22),n=fnF(n,o,u,l,t[12],1804603682,7),l=fnF(l,n,o,u,t[13],4254626195,12),u=fnF(u,l,n,o,t[14],2792965006,17),o=fnF(o,u,l,n,t[15],1236535329,22),n=fnG(n,o,u,l,t[1],4129170786,5),l=fnG(l,n,o,u,t[6],3225465664,9),u=fnG(u,l,n,o,t[11],643717713,14),o=fnG(o,u,l,n,t[0],3921069994,20),n=fnG(n,o,u,l,t[5],3593408605,5),l=fnG(l,n,o,u,t[10],38016083,9),u=fnG(u,l,n,o,t[15],3634488961,14),o=fnG(o,u,l,n,t[4],3889429448,20),n=fnG(n,o,u,l,t[9],568446438,5),l=fnG(l,n,o,u,t[14],3275163606,9),u=fnG(u,l,n,o,t[3],4107603335,14),o=fnG(o,u,l,n,t[8],1163531501,20),n=fnG(n,o,u,l,t[13],2850285829,5),l=fnG(l,n,o,u,t[2],4243563512,9),u=fnG(u,l,n,o,t[7],1735328473,14),o=fnG(o,u,l,n,t[12],2368359562,20),n=fnH(n,o,u,l,t[5],4294588738,4),l=fnH(l,n,o,u,t[8],2272392833,11),u=fnH(u,l,n,o,t[11],1839030562,16),o=fnH(o,u,l,n,t[14],4259657740,23),n=fnH(n,o,u,l,t[1],2763975236,4),l=fnH(l,n,o,u,t[4],1272893353,11),u=fnH(u,l,n,o,t[7],4139469664,16),o=fnH(o,u,l,n,t[10],3200236656,23),n=fnH(n,o,u,l,t[13],681279174,4),l=fnH(l,n,o,u,t[0],3936430074,11),u=fnH(u,l,n,o,t[3],3572445317,16),o=fnH(o,u,l,n,t[6],76029189,23),n=fnH(n,o,u,l,t[9],3654602809,4),l=fnH(l,n,o,u,t[12],3873151461,11),u=fnH(u,l,n,o,t[15],530742520,16),o=fnH(o,u,l,n,t[2],3299628645,23),n=fnI(n,o,u,l,t[0],4096336452,6),l=fnI(l,n,o,u,t[7],1126891415,10),u=fnI(u,l,n,o,t[14],2878612391,15),o=fnI(o,u,l,n,t[5],4237533241,21),n=fnI(n,o,u,l,t[12],1700485571,6),l=fnI(l,n,o,u,t[3],2399980690,10),u=fnI(u,l,n,o,t[10],4293915773,15),o=fnI(o,u,l,n,t[1],2240044497,21),n=fnI(n,o,u,l,t[8],1873313359,6),l=fnI(l,n,o,u,t[15],4264355552,10),u=fnI(u,l,n,o,t[6],2734768916,15),o=fnI(o,u,l,n,t[13],1309151649,21),n=fnI(n,o,u,l,t[4],4149444226,6),l=fnI(l,n,o,u,t[11],3174756917,10),u=fnI(u,l,n,o,t[2],718787259,15),o=fnI(o,u,l,n,t[9],3951481745,21),this._a=this._a+n|0,this._b=this._b+o|0,this._c=this._c+u|0,this._d=this._d+l|0},MD5$3.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=Buffer$y.allocUnsafe(16);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t};function rotl$1(t,e){return t<<e|t>>>32-e}function fnF(t,e,n,o,u,l,m){return rotl$1(t+(e&n|~e&o)+u+l|0,m)+e|0}function fnG(t,e,n,o,u,l,m){return rotl$1(t+(e&o|n&~o)+u+l|0,m)+e|0}function fnH(t,e,n,o,u,l,m){return rotl$1(t+(e^n^o)+u+l|0,m)+e|0}function fnI(t,e,n,o,u,l,m){return rotl$1(t+(n^(e|~o))+u+l|0,m)+e|0}var md5_js=MD5$3,Buffer$x=require$$0$2.Buffer,inherits$n=inherits_browserExports,HashBase=hashBase,ARRAY16=new Array(16),zl=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],zr=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],sl=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],sr=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],hl=[0,1518500249,1859775393,2400959708,2840853838],hr=[1352829926,1548603684,1836072691,2053994217,0];function RIPEMD160$4(){HashBase.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}inherits$n(RIPEMD160$4,HashBase),RIPEMD160$4.prototype._update=function(){for(var t=ARRAY16,e=0;e<16;++e)t[e]=this._block.readInt32LE(e*4);for(var n=this._a|0,o=this._b|0,u=this._c|0,l=this._d|0,m=this._e|0,y=this._a|0,E=this._b|0,C=this._c|0,k=this._d|0,A=this._e|0,D=0;D<80;D+=1){var P,R;D<16?(P=fn1(n,o,u,l,m,t[zl[D]],hl[0],sl[D]),R=fn5(y,E,C,k,A,t[zr[D]],hr[0],sr[D])):D<32?(P=fn2(n,o,u,l,m,t[zl[D]],hl[1],sl[D]),R=fn4(y,E,C,k,A,t[zr[D]],hr[1],sr[D])):D<48?(P=fn3(n,o,u,l,m,t[zl[D]],hl[2],sl[D]),R=fn3(y,E,C,k,A,t[zr[D]],hr[2],sr[D])):D<64?(P=fn4(n,o,u,l,m,t[zl[D]],hl[3],sl[D]),R=fn2(y,E,C,k,A,t[zr[D]],hr[3],sr[D])):(P=fn5(n,o,u,l,m,t[zl[D]],hl[4],sl[D]),R=fn1(y,E,C,k,A,t[zr[D]],hr[4],sr[D])),n=m,m=l,l=rotl(u,10),u=o,o=P,y=A,A=k,k=rotl(C,10),C=E,E=R}var B=this._b+u+k|0;this._b=this._c+l+A|0,this._c=this._d+m+y|0,this._d=this._e+n+E|0,this._e=this._a+o+C|0,this._a=B},RIPEMD160$4.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=Buffer$x.alloc?Buffer$x.alloc(20):new Buffer$x(20);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t.writeInt32LE(this._e,16),t};function rotl(t,e){return t<<e|t>>>32-e}function fn1(t,e,n,o,u,l,m,y){return rotl(t+(e^n^o)+l+m|0,y)+u|0}function fn2(t,e,n,o,u,l,m,y){return rotl(t+(e&n|~e&o)+l+m|0,y)+u|0}function fn3(t,e,n,o,u,l,m,y){return rotl(t+((e|~n)^o)+l+m|0,y)+u|0}function fn4(t,e,n,o,u,l,m,y){return rotl(t+(e&o|n&~o)+l+m|0,y)+u|0}function fn5(t,e,n,o,u,l,m,y){return rotl(t+(e^(n|~o))+l+m|0,y)+u|0}var ripemd160=RIPEMD160$4,sha_js={exports:{}},Buffer$w=safeBufferExports$1.Buffer;function Hash$7(t,e){this._block=Buffer$w.alloc(t),this._finalSize=e,this._blockSize=t,this._len=0}Hash$7.prototype.update=function(t,e){typeof t=="string"&&(e=e||"utf8",t=Buffer$w.from(t,e));for(var n=this._block,o=this._blockSize,u=t.length,l=this._len,m=0;m<u;){for(var y=l%o,E=Math.min(u-m,o-y),C=0;C<E;C++)n[y+C]=t[m+C];l+=E,m+=E,l%o===0&&this._update(n)}return this._len+=u,this},Hash$7.prototype.digest=function(t){var e=this._len%this._blockSize;this._block[e]=128,this._block.fill(0,e+1),e>=this._finalSize&&(this._update(this._block),this._block.fill(0));var n=this._len*8;if(n<=4294967295)this._block.writeUInt32BE(n,this._blockSize-4);else{var o=(n&4294967295)>>>0,u=(n-o)/4294967296;this._block.writeUInt32BE(u,this._blockSize-8),this._block.writeUInt32BE(o,this._blockSize-4)}this._update(this._block);var l=this._hash();return t?l.toString(t):l},Hash$7.prototype._update=function(){throw new Error("_update must be implemented by subclass")};var hash$3=Hash$7,inherits$m=inherits_browserExports,Hash$6=hash$3,Buffer$v=safeBufferExports$1.Buffer,K$4=[1518500249,1859775393,-1894007588,-899497514],W$5=new Array(80);function Sha(){this.init(),this._w=W$5,Hash$6.call(this,64,56)}inherits$m(Sha,Hash$6),Sha.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function rotl5$1(t){return t<<5|t>>>27}function rotl30$1(t){return t<<30|t>>>2}function ft$1(t,e,n,o){return t===0?e&n|~e&o:t===2?e&n|e&o|n&o:e^n^o}Sha.prototype._update=function(t){for(var e=this._w,n=this._a|0,o=this._b|0,u=this._c|0,l=this._d|0,m=this._e|0,y=0;y<16;++y)e[y]=t.readInt32BE(y*4);for(;y<80;++y)e[y]=e[y-3]^e[y-8]^e[y-14]^e[y-16];for(var E=0;E<80;++E){var C=~~(E/20),k=rotl5$1(n)+ft$1(C,o,u,l)+m+e[E]+K$4[C]|0;m=l,l=u,u=rotl30$1(o),o=n,n=k}this._a=n+this._a|0,this._b=o+this._b|0,this._c=u+this._c|0,this._d=l+this._d|0,this._e=m+this._e|0},Sha.prototype._hash=function(){var t=Buffer$v.allocUnsafe(20);return t.writeInt32BE(this._a|0,0),t.writeInt32BE(this._b|0,4),t.writeInt32BE(this._c|0,8),t.writeInt32BE(this._d|0,12),t.writeInt32BE(this._e|0,16),t};var sha$4=Sha,inherits$l=inherits_browserExports,Hash$5=hash$3,Buffer$u=safeBufferExports$1.Buffer,K$3=[1518500249,1859775393,-1894007588,-899497514],W$4=new Array(80);function Sha1(){this.init(),this._w=W$4,Hash$5.call(this,64,56)}inherits$l(Sha1,Hash$5),Sha1.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function rotl1(t){return t<<1|t>>>31}function rotl5(t){return t<<5|t>>>27}function rotl30(t){return t<<30|t>>>2}function ft(t,e,n,o){return t===0?e&n|~e&o:t===2?e&n|e&o|n&o:e^n^o}Sha1.prototype._update=function(t){for(var e=this._w,n=this._a|0,o=this._b|0,u=this._c|0,l=this._d|0,m=this._e|0,y=0;y<16;++y)e[y]=t.readInt32BE(y*4);for(;y<80;++y)e[y]=rotl1(e[y-3]^e[y-8]^e[y-14]^e[y-16]);for(var E=0;E<80;++E){var C=~~(E/20),k=rotl5(n)+ft(C,o,u,l)+m+e[E]+K$3[C]|0;m=l,l=u,u=rotl30(o),o=n,n=k}this._a=n+this._a|0,this._b=o+this._b|0,this._c=u+this._c|0,this._d=l+this._d|0,this._e=m+this._e|0},Sha1.prototype._hash=function(){var t=Buffer$u.allocUnsafe(20);return t.writeInt32BE(this._a|0,0),t.writeInt32BE(this._b|0,4),t.writeInt32BE(this._c|0,8),t.writeInt32BE(this._d|0,12),t.writeInt32BE(this._e|0,16),t};var sha1$2=Sha1,inherits$k=inherits_browserExports,Hash$4=hash$3,Buffer$t=safeBufferExports$1.Buffer,K$2=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],W$3=new Array(64);function Sha256$1(){this.init(),this._w=W$3,Hash$4.call(this,64,56)}inherits$k(Sha256$1,Hash$4),Sha256$1.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this};function ch(t,e,n){return n^t&(e^n)}function maj$1(t,e,n){return t&e|n&(t|e)}function sigma0$1(t){return(t>>>2|t<<30)^(t>>>13|t<<19)^(t>>>22|t<<10)}function sigma1$1(t){return(t>>>6|t<<26)^(t>>>11|t<<21)^(t>>>25|t<<7)}function gamma0(t){return(t>>>7|t<<25)^(t>>>18|t<<14)^t>>>3}function gamma1(t){return(t>>>17|t<<15)^(t>>>19|t<<13)^t>>>10}Sha256$1.prototype._update=function(t){for(var e=this._w,n=this._a|0,o=this._b|0,u=this._c|0,l=this._d|0,m=this._e|0,y=this._f|0,E=this._g|0,C=this._h|0,k=0;k<16;++k)e[k]=t.readInt32BE(k*4);for(;k<64;++k)e[k]=gamma1(e[k-2])+e[k-7]+gamma0(e[k-15])+e[k-16]|0;for(var A=0;A<64;++A){var D=C+sigma1$1(m)+ch(m,y,E)+K$2[A]+e[A]|0,P=sigma0$1(n)+maj$1(n,o,u)|0;C=E,E=y,y=m,m=l+D|0,l=u,u=o,o=n,n=D+P|0}this._a=n+this._a|0,this._b=o+this._b|0,this._c=u+this._c|0,this._d=l+this._d|0,this._e=m+this._e|0,this._f=y+this._f|0,this._g=E+this._g|0,this._h=C+this._h|0},Sha256$1.prototype._hash=function(){var t=Buffer$t.allocUnsafe(32);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t.writeInt32BE(this._h,28),t};var sha256$1=Sha256$1,inherits$j=inherits_browserExports,Sha256=sha256$1,Hash$3=hash$3,Buffer$s=safeBufferExports$1.Buffer,W$2=new Array(64);function Sha224(){this.init(),this._w=W$2,Hash$3.call(this,64,56)}inherits$j(Sha224,Sha256),Sha224.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},Sha224.prototype._hash=function(){var t=Buffer$s.allocUnsafe(28);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t};var sha224$1=Sha224,inherits$i=inherits_browserExports,Hash$2=hash$3,Buffer$r=safeBufferExports$1.Buffer,K$1=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],W$1=new Array(160);function Sha512(){this.init(),this._w=W$1,Hash$2.call(this,128,112)}inherits$i(Sha512,Hash$2),Sha512.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this};function Ch(t,e,n){return n^t&(e^n)}function maj(t,e,n){return t&e|n&(t|e)}function sigma0(t,e){return(t>>>28|e<<4)^(e>>>2|t<<30)^(e>>>7|t<<25)}function sigma1(t,e){return(t>>>14|e<<18)^(t>>>18|e<<14)^(e>>>9|t<<23)}function Gamma0(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^t>>>7}function Gamma0l(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^(t>>>7|e<<25)}function Gamma1(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^t>>>6}function Gamma1l(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^(t>>>6|e<<26)}function getCarry(t,e){return t>>>0<e>>>0?1:0}Sha512.prototype._update=function(t){for(var e=this._w,n=this._ah|0,o=this._bh|0,u=this._ch|0,l=this._dh|0,m=this._eh|0,y=this._fh|0,E=this._gh|0,C=this._hh|0,k=this._al|0,A=this._bl|0,D=this._cl|0,P=this._dl|0,R=this._el|0,B=this._fl|0,F=this._gl|0,j=this._hl|0,N=0;N<32;N+=2)e[N]=t.readInt32BE(N*4),e[N+1]=t.readInt32BE(N*4+4);for(;N<160;N+=2){var Y=e[N-30],J=e[N-15*2+1],ie=Gamma0(Y,J),ue=Gamma0l(J,Y);Y=e[N-2*2],J=e[N-2*2+1];var Q=Gamma1(Y,J),ce=Gamma1l(J,Y),he=e[N-7*2],ke=e[N-7*2+1],L=e[N-16*2],d=e[N-16*2+1],v=ue+ke|0,w=ie+he+getCarry(v,ue)|0;v=v+ce|0,w=w+Q+getCarry(v,ce)|0,v=v+d|0,w=w+L+getCarry(v,d)|0,e[N]=w,e[N+1]=v}for(var c=0;c<160;c+=2){w=e[c],v=e[c+1];var p=maj(n,o,u),x=maj(k,A,D),S=sigma0(n,k),b=sigma0(k,n),h=sigma1(m,R),T=sigma1(R,m),M=K$1[c],O=K$1[c+1],V=Ch(m,y,E),ee=Ch(R,B,F),Z=j+T|0,U=C+h+getCarry(Z,j)|0;Z=Z+ee|0,U=U+V+getCarry(Z,ee)|0,Z=Z+O|0,U=U+M+getCarry(Z,O)|0,Z=Z+v|0,U=U+w+getCarry(Z,v)|0;var z=b+x|0,ne=S+p+getCarry(z,b)|0;C=E,j=F,E=y,F=B,y=m,B=R,R=P+Z|0,m=l+U+getCarry(R,P)|0,l=u,P=D,u=o,D=A,o=n,A=k,k=Z+z|0,n=U+ne+getCarry(k,Z)|0}this._al=this._al+k|0,this._bl=this._bl+A|0,this._cl=this._cl+D|0,this._dl=this._dl+P|0,this._el=this._el+R|0,this._fl=this._fl+B|0,this._gl=this._gl+F|0,this._hl=this._hl+j|0,this._ah=this._ah+n+getCarry(this._al,k)|0,this._bh=this._bh+o+getCarry(this._bl,A)|0,this._ch=this._ch+u+getCarry(this._cl,D)|0,this._dh=this._dh+l+getCarry(this._dl,P)|0,this._eh=this._eh+m+getCarry(this._el,R)|0,this._fh=this._fh+y+getCarry(this._fl,B)|0,this._gh=this._gh+E+getCarry(this._gl,F)|0,this._hh=this._hh+C+getCarry(this._hl,j)|0},Sha512.prototype._hash=function(){var t=Buffer$r.allocUnsafe(64);function e(n,o,u){t.writeInt32BE(n,u),t.writeInt32BE(o,u+4)}return e(this._ah,this._al,0),e(this._bh,this._bl,8),e(this._ch,this._cl,16),e(this._dh,this._dl,24),e(this._eh,this._el,32),e(this._fh,this._fl,40),e(this._gh,this._gl,48),e(this._hh,this._hl,56),t};var sha512$1=Sha512,inherits$h=inherits_browserExports,SHA512$2=sha512$1,Hash$1=hash$3,Buffer$q=safeBufferExports$1.Buffer,W=new Array(160);function Sha384(){this.init(),this._w=W,Hash$1.call(this,128,112)}inherits$h(Sha384,SHA512$2),Sha384.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},Sha384.prototype._hash=function(){var t=Buffer$q.allocUnsafe(48);function e(n,o,u){t.writeInt32BE(n,u),t.writeInt32BE(o,u+4)}return e(this._ah,this._al,0),e(this._bh,this._bl,8),e(this._ch,this._cl,16),e(this._dh,this._dl,24),e(this._eh,this._el,32),e(this._fh,this._fl,40),t};var sha384$1=Sha384,exports$1=sha_js.exports=function(e){e=e.toLowerCase();var n=exports$1[e];if(!n)throw new Error(e+" is not supported (we accept pull requests)");return new n};exports$1.sha=sha$4,exports$1.sha1=sha1$2,exports$1.sha224=sha224$1,exports$1.sha256=sha256$1,exports$1.sha384=sha384$1,exports$1.sha512=sha512$1;var sha_jsExports=sha_js.exports,Buffer$p=safeBufferExports$1.Buffer,Transform$6=requireStreamBrowserify().Transform,StringDecoder=string_decoder.StringDecoder,inherits$g=inherits_browserExports;function CipherBase$1(t){Transform$6.call(this),this.hashMode=typeof t=="string",this.hashMode?this[t]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}inherits$g(CipherBase$1,Transform$6),CipherBase$1.prototype.update=function(t,e,n){typeof t=="string"&&(t=Buffer$p.from(t,e));var o=this._update(t);return this.hashMode?this:(n&&(o=this._toString(o,n)),o)},CipherBase$1.prototype.setAutoPadding=function(){},CipherBase$1.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},CipherBase$1.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},CipherBase$1.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},CipherBase$1.prototype._transform=function(t,e,n){var o;try{this.hashMode?this._update(t):this.push(this._update(t))}catch(u){o=u}finally{n(o)}},CipherBase$1.prototype._flush=function(t){var e;try{this.push(this.__final())}catch(n){e=n}t(e)},CipherBase$1.prototype._finalOrDigest=function(t){var e=this.__final()||Buffer$p.alloc(0);return t&&(e=this._toString(e,t,!0)),e},CipherBase$1.prototype._toString=function(t,e,n){if(this._decoder||(this._decoder=new StringDecoder(e),this._encoding=e),this._encoding!==e)throw new Error("can't switch encodings");var o=this._decoder.write(t);return n&&(o+=this._decoder.end()),o};var cipherBase=CipherBase$1,inherits$f=inherits_browserExports,MD5$2=md5_js,RIPEMD160$3=ripemd160,sha$3=sha_jsExports,Base$5=cipherBase;function Hash(t){Base$5.call(this,"digest"),this._hash=t}inherits$f(Hash,Base$5),Hash.prototype._update=function(t){this._hash.update(t)},Hash.prototype._final=function(){return this._hash.digest()};var browser$b=function(e){return e=e.toLowerCase(),e==="md5"?new MD5$2:e==="rmd160"||e==="ripemd160"?new RIPEMD160$3:new Hash(sha$3(e))},inherits$e=inherits_browserExports,Buffer$o=safeBufferExports$1.Buffer,Base$4=cipherBase,ZEROS$2=Buffer$o.alloc(128),blocksize=64;function Hmac$3(t,e){Base$4.call(this,"digest"),typeof e=="string"&&(e=Buffer$o.from(e)),this._alg=t,this._key=e,e.length>blocksize?e=t(e):e.length<blocksize&&(e=Buffer$o.concat([e,ZEROS$2],blocksize));for(var n=this._ipad=Buffer$o.allocUnsafe(blocksize),o=this._opad=Buffer$o.allocUnsafe(blocksize),u=0;u<blocksize;u++)n[u]=e[u]^54,o[u]=e[u]^92;this._hash=[n]}inherits$e(Hmac$3,Base$4),Hmac$3.prototype._update=function(t){this._hash.push(t)},Hmac$3.prototype._final=function(){var t=this._alg(Buffer$o.concat(this._hash));return this._alg(Buffer$o.concat([this._opad,t]))};var legacy=Hmac$3,MD5$1=md5_js,md5$3=function(t){return new MD5$1().update(t).digest()},inherits$d=inherits_browserExports,Legacy=legacy,Base$3=cipherBase,Buffer$n=safeBufferExports$1.Buffer,md5$2=md5$3,RIPEMD160$2=ripemd160,sha$2=sha_jsExports,ZEROS$1=Buffer$n.alloc(128);function Hmac$2(t,e){Base$3.call(this,"digest"),typeof e=="string"&&(e=Buffer$n.from(e));var n=t==="sha512"||t==="sha384"?128:64;if(this._alg=t,this._key=e,e.length>n){var o=t==="rmd160"?new RIPEMD160$2:sha$2(t);e=o.update(e).digest()}else e.length<n&&(e=Buffer$n.concat([e,ZEROS$1],n));for(var u=this._ipad=Buffer$n.allocUnsafe(n),l=this._opad=Buffer$n.allocUnsafe(n),m=0;m<n;m++)u[m]=e[m]^54,l[m]=e[m]^92;this._hash=t==="rmd160"?new RIPEMD160$2:sha$2(t),this._hash.update(u)}inherits$d(Hmac$2,Base$3),Hmac$2.prototype._update=function(t){this._hash.update(t)},Hmac$2.prototype._final=function(){var t=this._hash.digest(),e=this._alg==="rmd160"?new RIPEMD160$2:sha$2(this._alg);return e.update(this._opad).update(t).digest()};var browser$a=function(e,n){return e=e.toLowerCase(),e==="rmd160"||e==="ripemd160"?new Hmac$2("rmd160",n):e==="md5"?new Legacy(md5$2,n):new Hmac$2(e,n)};const sha224WithRSAEncryption={sign:"rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption={sign:"rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption={sign:"rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption={sign:"rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},sha256={sign:"ecdsa",hash:"sha256",id:""},sha224={sign:"ecdsa",hash:"sha224",id:""},sha384={sign:"ecdsa",hash:"sha384",id:""},sha512={sign:"ecdsa",hash:"sha512",id:""},DSA={sign:"dsa",hash:"sha1",id:""},ripemd160WithRSA={sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption={sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"},require$$6$1={sha224WithRSAEncryption,"RSA-SHA224":{sign:"ecdsa/rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption,"RSA-SHA256":{sign:"ecdsa/rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption,"RSA-SHA384":{sign:"ecdsa/rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption,"RSA-SHA512":{sign:"ecdsa/rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA1":{sign:"rsa",hash:"sha1",id:"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{sign:"ecdsa",hash:"sha1",id:""},sha256,sha224,sha384,sha512,"DSA-SHA":{sign:"dsa",hash:"sha1",id:""},"DSA-SHA1":{sign:"dsa",hash:"sha1",id:""},DSA,"DSA-WITH-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-WITH-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-WITH-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-WITH-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-RIPEMD160":{sign:"dsa",hash:"rmd160",id:""},ripemd160WithRSA,"RSA-RIPEMD160":{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption,"RSA-MD5":{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"}};var algos=require$$6$1,browser$9={},MAX_ALLOC=Math.pow(2,30)-1,precondition=function(t,e){if(typeof t!="number")throw new TypeError("Iterations not a number");if(t<0)throw new TypeError("Bad iterations");if(typeof e!="number")throw new TypeError("Key length not a number");if(e<0||e>MAX_ALLOC||e!==e)throw new TypeError("Bad key length")},defaultEncoding$2;if(commonjsGlobal$1.process&&commonjsGlobal$1.process.browser)defaultEncoding$2="utf-8";else if(commonjsGlobal$1.process&&commonjsGlobal$1.process.version){var pVersionMajor=parseInt(process$1.version.split(".")[0].slice(1),10);defaultEncoding$2=pVersionMajor>=6?"utf-8":"binary"}else defaultEncoding$2="utf-8";var defaultEncoding_1=defaultEncoding$2,Buffer$m=safeBufferExports$1.Buffer,toBuffer$2=function(t,e,n){if(Buffer$m.isBuffer(t))return t;if(typeof t=="string")return Buffer$m.from(t,e);if(ArrayBuffer.isView(t))return Buffer$m.from(t.buffer);throw new TypeError(n+" must be a string, a Buffer, a typed array or a DataView")},md5$1=md5$3,RIPEMD160$1=ripemd160,sha$1=sha_jsExports,Buffer$l=safeBufferExports$1.Buffer,checkParameters$1=precondition,defaultEncoding$1=defaultEncoding_1,toBuffer$1=toBuffer$2,ZEROS=Buffer$l.alloc(128),sizes={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function Hmac$1(t,e,n){var o=getDigest(t),u=t==="sha512"||t==="sha384"?128:64;e.length>u?e=o(e):e.length<u&&(e=Buffer$l.concat([e,ZEROS],u));for(var l=Buffer$l.allocUnsafe(u+sizes[t]),m=Buffer$l.allocUnsafe(u+sizes[t]),y=0;y<u;y++)l[y]=e[y]^54,m[y]=e[y]^92;var E=Buffer$l.allocUnsafe(u+n+4);l.copy(E,0,0,u),this.ipad1=E,this.ipad2=l,this.opad=m,this.alg=t,this.blocksize=u,this.hash=o,this.size=sizes[t]}Hmac$1.prototype.run=function(t,e){t.copy(e,this.blocksize);var n=this.hash(e);return n.copy(this.opad,this.blocksize),this.hash(this.opad)};function getDigest(t){function e(o){return sha$1(t).update(o).digest()}function n(o){return new RIPEMD160$1().update(o).digest()}return t==="rmd160"||t==="ripemd160"?n:t==="md5"?md5$1:e}function pbkdf2(t,e,n,o,u){checkParameters$1(n,o),t=toBuffer$1(t,defaultEncoding$1,"Password"),e=toBuffer$1(e,defaultEncoding$1,"Salt"),u=u||"sha1";var l=new Hmac$1(u,t,e.length),m=Buffer$l.allocUnsafe(o),y=Buffer$l.allocUnsafe(e.length+4);e.copy(y,0,0,e.length);for(var E=0,C=sizes[u],k=Math.ceil(o/C),A=1;A<=k;A++){y.writeUInt32BE(A,e.length);for(var D=l.run(y,l.ipad1),P=D,R=1;R<n;R++){P=l.run(P,l.ipad2);for(var B=0;B<C;B++)D[B]^=P[B]}D.copy(m,E),E+=C}return m}var syncBrowser=pbkdf2,Buffer$k=safeBufferExports$1.Buffer,checkParameters=precondition,defaultEncoding=defaultEncoding_1,sync=syncBrowser,toBuffer=toBuffer$2,ZERO_BUF,subtle=commonjsGlobal$1.crypto&&commonjsGlobal$1.crypto.subtle,toBrowser={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},checks=[];function checkNative(t){if(commonjsGlobal$1.process&&!commonjsGlobal$1.process.browser||!subtle||!subtle.importKey||!subtle.deriveBits)return Promise.resolve(!1);if(checks[t]!==void 0)return checks[t];ZERO_BUF=ZERO_BUF||Buffer$k.alloc(8);var e=browserPbkdf2(ZERO_BUF,ZERO_BUF,10,128,t).then(function(){return!0}).catch(function(){return!1});return checks[t]=e,e}var nextTick$1;function getNextTick(){return nextTick$1||(commonjsGlobal$1.process&&commonjsGlobal$1.process.nextTick?nextTick$1=commonjsGlobal$1.process.nextTick:commonjsGlobal$1.queueMicrotask?nextTick$1=commonjsGlobal$1.queueMicrotask:commonjsGlobal$1.setImmediate?nextTick$1=commonjsGlobal$1.setImmediate:nextTick$1=commonjsGlobal$1.setTimeout,nextTick$1)}function browserPbkdf2(t,e,n,o,u){return subtle.importKey("raw",t,{name:"PBKDF2"},!1,["deriveBits"]).then(function(l){return subtle.deriveBits({name:"PBKDF2",salt:e,iterations:n,hash:{name:u}},l,o<<3)}).then(function(l){return Buffer$k.from(l)})}function resolvePromise(t,e){t.then(function(n){getNextTick()(function(){e(null,n)})},function(n){getNextTick()(function(){e(n)})})}var async$1=function(t,e,n,o,u,l){typeof u=="function"&&(l=u,u=void 0),u=u||"sha1";var m=toBrowser[u.toLowerCase()];if(!m||typeof commonjsGlobal$1.Promise!="function"){getNextTick()(function(){var y;try{y=sync(t,e,n,o,u)}catch(E){return l(E)}l(null,y)});return}if(checkParameters(n,o),t=toBuffer(t,defaultEncoding,"Password"),e=toBuffer(e,defaultEncoding,"Salt"),typeof l!="function")throw new Error("No callback provided to pbkdf2");resolvePromise(checkNative(m).then(function(y){return y?browserPbkdf2(t,e,n,o,m):sync(t,e,n,o,u)}),l)};browser$9.pbkdf2=async$1,browser$9.pbkdf2Sync=syncBrowser;var browser$8={},des$2={},utils$q={};utils$q.readUInt32BE=function(e,n){var o=e[0+n]<<24|e[1+n]<<16|e[2+n]<<8|e[3+n];return o>>>0},utils$q.writeUInt32BE=function(e,n,o){e[0+o]=n>>>24,e[1+o]=n>>>16&255,e[2+o]=n>>>8&255,e[3+o]=n&255},utils$q.ip=function(e,n,o,u){for(var l=0,m=0,y=6;y>=0;y-=2){for(var E=0;E<=24;E+=8)l<<=1,l|=n>>>E+y&1;for(var E=0;E<=24;E+=8)l<<=1,l|=e>>>E+y&1}for(var y=6;y>=0;y-=2){for(var E=1;E<=25;E+=8)m<<=1,m|=n>>>E+y&1;for(var E=1;E<=25;E+=8)m<<=1,m|=e>>>E+y&1}o[u+0]=l>>>0,o[u+1]=m>>>0},utils$q.rip=function(e,n,o,u){for(var l=0,m=0,y=0;y<4;y++)for(var E=24;E>=0;E-=8)l<<=1,l|=n>>>E+y&1,l<<=1,l|=e>>>E+y&1;for(var y=4;y<8;y++)for(var E=24;E>=0;E-=8)m<<=1,m|=n>>>E+y&1,m<<=1,m|=e>>>E+y&1;o[u+0]=l>>>0,o[u+1]=m>>>0},utils$q.pc1=function(e,n,o,u){for(var l=0,m=0,y=7;y>=5;y--){for(var E=0;E<=24;E+=8)l<<=1,l|=n>>E+y&1;for(var E=0;E<=24;E+=8)l<<=1,l|=e>>E+y&1}for(var E=0;E<=24;E+=8)l<<=1,l|=n>>E+y&1;for(var y=1;y<=3;y++){for(var E=0;E<=24;E+=8)m<<=1,m|=n>>E+y&1;for(var E=0;E<=24;E+=8)m<<=1,m|=e>>E+y&1}for(var E=0;E<=24;E+=8)m<<=1,m|=e>>E+y&1;o[u+0]=l>>>0,o[u+1]=m>>>0},utils$q.r28shl=function(e,n){return e<<n&268435455|e>>>28-n};var pc2table=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];utils$q.pc2=function(e,n,o,u){for(var l=0,m=0,y=pc2table.length>>>1,E=0;E<y;E++)l<<=1,l|=e>>>pc2table[E]&1;for(var E=y;E<pc2table.length;E++)m<<=1,m|=n>>>pc2table[E]&1;o[u+0]=l>>>0,o[u+1]=m>>>0},utils$q.expand=function(e,n,o){var u=0,l=0;u=(e&1)<<5|e>>>27;for(var m=23;m>=15;m-=4)u<<=6,u|=e>>>m&63;for(var m=11;m>=3;m-=4)l|=e>>>m&63,l<<=6;l|=(e&31)<<1|e>>>31,n[o+0]=u>>>0,n[o+1]=l>>>0};var sTable=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];utils$q.substitute=function(e,n){for(var o=0,u=0;u<4;u++){var l=e>>>18-u*6&63,m=sTable[u*64+l];o<<=4,o|=m}for(var u=0;u<4;u++){var l=n>>>18-u*6&63,m=sTable[4*64+u*64+l];o<<=4,o|=m}return o>>>0};var permuteTable=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];utils$q.permute=function(e){for(var n=0,o=0;o<permuteTable.length;o++)n<<=1,n|=e>>>permuteTable[o]&1;return n>>>0},utils$q.padSplit=function(e,n,o){for(var u=e.toString(2);u.length<n;)u="0"+u;for(var l=[],m=0;m<n;m+=o)l.push(u.slice(m,m+o));return l.join(" ")};var minimalisticAssert=assert$j;function assert$j(t,e){if(!t)throw new Error(e||"Assertion failed")}assert$j.equal=function(e,n,o){if(e!=n)throw new Error(o||"Assertion failed: "+e+" != "+n)};var assert$i=minimalisticAssert;function Cipher$3(t){this.options=t,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0,this.padding=t.padding!==!1}var cipher=Cipher$3;Cipher$3.prototype._init=function(){},Cipher$3.prototype.update=function(e){return e.length===0?[]:this.type==="decrypt"?this._updateDecrypt(e):this._updateEncrypt(e)},Cipher$3.prototype._buffer=function(e,n){for(var o=Math.min(this.buffer.length-this.bufferOff,e.length-n),u=0;u<o;u++)this.buffer[this.bufferOff+u]=e[n+u];return this.bufferOff+=o,o},Cipher$3.prototype._flushBuffer=function(e,n){return this._update(this.buffer,0,e,n),this.bufferOff=0,this.blockSize},Cipher$3.prototype._updateEncrypt=function(e){var n=0,o=0,u=(this.bufferOff+e.length)/this.blockSize|0,l=new Array(u*this.blockSize);this.bufferOff!==0&&(n+=this._buffer(e,n),this.bufferOff===this.buffer.length&&(o+=this._flushBuffer(l,o)));for(var m=e.length-(e.length-n)%this.blockSize;n<m;n+=this.blockSize)this._update(e,n,l,o),o+=this.blockSize;for(;n<e.length;n++,this.bufferOff++)this.buffer[this.bufferOff]=e[n];return l},Cipher$3.prototype._updateDecrypt=function(e){for(var n=0,o=0,u=Math.ceil((this.bufferOff+e.length)/this.blockSize)-1,l=new Array(u*this.blockSize);u>0;u--)n+=this._buffer(e,n),o+=this._flushBuffer(l,o);return n+=this._buffer(e,n),l},Cipher$3.prototype.final=function(e){var n;e&&(n=this.update(e));var o;return this.type==="encrypt"?o=this._finalEncrypt():o=this._finalDecrypt(),n?n.concat(o):o},Cipher$3.prototype._pad=function(e,n){if(n===0)return!1;for(;n<e.length;)e[n++]=0;return!0},Cipher$3.prototype._finalEncrypt=function(){if(!this._pad(this.buffer,this.bufferOff))return[];var e=new Array(this.blockSize);return this._update(this.buffer,0,e,0),e},Cipher$3.prototype._unpad=function(e){return e},Cipher$3.prototype._finalDecrypt=function(){assert$i.equal(this.bufferOff,this.blockSize,"Not enough data to decrypt");var e=new Array(this.blockSize);return this._flushBuffer(e,0),this._unpad(e)};var assert$h=minimalisticAssert,inherits$c=inherits_browserExports,utils$p=utils$q,Cipher$2=cipher;function DESState(){this.tmp=new Array(2),this.keys=null}function DES$3(t){Cipher$2.call(this,t);var e=new DESState;this._desState=e,this.deriveKeys(e,t.key)}inherits$c(DES$3,Cipher$2);var des$1=DES$3;DES$3.create=function(e){return new DES$3(e)};var shiftTable=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];DES$3.prototype.deriveKeys=function(e,n){e.keys=new Array(16*2),assert$h.equal(n.length,this.blockSize,"Invalid key length");var o=utils$p.readUInt32BE(n,0),u=utils$p.readUInt32BE(n,4);utils$p.pc1(o,u,e.tmp,0),o=e.tmp[0],u=e.tmp[1];for(var l=0;l<e.keys.length;l+=2){var m=shiftTable[l>>>1];o=utils$p.r28shl(o,m),u=utils$p.r28shl(u,m),utils$p.pc2(o,u,e.keys,l)}},DES$3.prototype._update=function(e,n,o,u){var l=this._desState,m=utils$p.readUInt32BE(e,n),y=utils$p.readUInt32BE(e,n+4);utils$p.ip(m,y,l.tmp,0),m=l.tmp[0],y=l.tmp[1],this.type==="encrypt"?this._encrypt(l,m,y,l.tmp,0):this._decrypt(l,m,y,l.tmp,0),m=l.tmp[0],y=l.tmp[1],utils$p.writeUInt32BE(o,m,u),utils$p.writeUInt32BE(o,y,u+4)},DES$3.prototype._pad=function(e,n){if(this.padding===!1)return!1;for(var o=e.length-n,u=n;u<e.length;u++)e[u]=o;return!0},DES$3.prototype._unpad=function(e){if(this.padding===!1)return e;for(var n=e[e.length-1],o=e.length-n;o<e.length;o++)assert$h.equal(e[o],n);return e.slice(0,e.length-n)},DES$3.prototype._encrypt=function(e,n,o,u,l){for(var m=n,y=o,E=0;E<e.keys.length;E+=2){var C=e.keys[E],k=e.keys[E+1];utils$p.expand(y,e.tmp,0),C^=e.tmp[0],k^=e.tmp[1];var A=utils$p.substitute(C,k),D=utils$p.permute(A),P=y;y=(m^D)>>>0,m=P}utils$p.rip(y,m,u,l)},DES$3.prototype._decrypt=function(e,n,o,u,l){for(var m=o,y=n,E=e.keys.length-2;E>=0;E-=2){var C=e.keys[E],k=e.keys[E+1];utils$p.expand(m,e.tmp,0),C^=e.tmp[0],k^=e.tmp[1];var A=utils$p.substitute(C,k),D=utils$p.permute(A),P=m;m=(y^D)>>>0,y=P}utils$p.rip(m,y,u,l)};var cbc$1={},assert$g=minimalisticAssert,inherits$b=inherits_browserExports,proto={};function CBCState(t){assert$g.equal(t.length,8,"Invalid IV length"),this.iv=new Array(8);for(var e=0;e<this.iv.length;e++)this.iv[e]=t[e]}function instantiate(t){function e(l){t.call(this,l),this._cbcInit()}inherits$b(e,t);for(var n=Object.keys(proto),o=0;o<n.length;o++){var u=n[o];e.prototype[u]=proto[u]}return e.create=function(m){return new e(m)},e}cbc$1.instantiate=instantiate,proto._cbcInit=function(){var e=new CBCState(this.options.iv);this._cbcState=e},proto._update=function(e,n,o,u){var l=this._cbcState,m=this.constructor.super_.prototype,y=l.iv;if(this.type==="encrypt"){for(var E=0;E<this.blockSize;E++)y[E]^=e[n+E];m._update.call(this,y,0,o,u);for(var E=0;E<this.blockSize;E++)y[E]=o[u+E]}else{m._update.call(this,e,n,o,u);for(var E=0;E<this.blockSize;E++)o[u+E]^=y[E];for(var E=0;E<this.blockSize;E++)y[E]=e[n+E]}};var assert$f=minimalisticAssert,inherits$a=inherits_browserExports,Cipher$1=cipher,DES$2=des$1;function EDEState(t,e){assert$f.equal(e.length,24,"Invalid key length");var n=e.slice(0,8),o=e.slice(8,16),u=e.slice(16,24);t==="encrypt"?this.ciphers=[DES$2.create({type:"encrypt",key:n}),DES$2.create({type:"decrypt",key:o}),DES$2.create({type:"encrypt",key:u})]:this.ciphers=[DES$2.create({type:"decrypt",key:u}),DES$2.create({type:"encrypt",key:o}),DES$2.create({type:"decrypt",key:n})]}function EDE(t){Cipher$1.call(this,t);var e=new EDEState(this.type,this.options.key);this._edeState=e}inherits$a(EDE,Cipher$1);var ede=EDE;EDE.create=function(e){return new EDE(e)},EDE.prototype._update=function(e,n,o,u){var l=this._edeState;l.ciphers[0]._update(e,n,o,u),l.ciphers[1]._update(o,u,o,u),l.ciphers[2]._update(o,u,o,u)},EDE.prototype._pad=DES$2.prototype._pad,EDE.prototype._unpad=DES$2.prototype._unpad,des$2.utils=utils$q,des$2.Cipher=cipher,des$2.DES=des$1,des$2.CBC=cbc$1,des$2.EDE=ede;var CipherBase=cipherBase,des=des$2,inherits$9=inherits_browserExports,Buffer$j=safeBufferExports$1.Buffer,modes$3={"des-ede3-cbc":des.CBC.instantiate(des.EDE),"des-ede3":des.EDE,"des-ede-cbc":des.CBC.instantiate(des.EDE),"des-ede":des.EDE,"des-cbc":des.CBC.instantiate(des.DES),"des-ecb":des.DES};modes$3.des=modes$3["des-cbc"],modes$3.des3=modes$3["des-ede3-cbc"];var browserifyDes=DES$1;inherits$9(DES$1,CipherBase);function DES$1(t){CipherBase.call(this);var e=t.mode.toLowerCase(),n=modes$3[e],o;t.decrypt?o="decrypt":o="encrypt";var u=t.key;Buffer$j.isBuffer(u)||(u=Buffer$j.from(u)),(e==="des-ede"||e==="des-ede-cbc")&&(u=Buffer$j.concat([u,u.slice(0,8)]));var l=t.iv;Buffer$j.isBuffer(l)||(l=Buffer$j.from(l)),this._des=n.create({key:u,iv:l,type:o})}DES$1.prototype._update=function(t){return Buffer$j.from(this._des.update(t))},DES$1.prototype._final=function(){return Buffer$j.from(this._des.final())};var browser$7={},encrypter={},ecb={};ecb.encrypt=function(t,e){return t._cipher.encryptBlock(e)},ecb.decrypt=function(t,e){return t._cipher.decryptBlock(e)};var cbc={},bufferXor=function(e,n){for(var o=Math.min(e.length,n.length),u=new Buffer$C(o),l=0;l<o;++l)u[l]=e[l]^n[l];return u},xor$7=bufferXor;cbc.encrypt=function(t,e){var n=xor$7(e,t._prev);return t._prev=t._cipher.encryptBlock(n),t._prev},cbc.decrypt=function(t,e){var n=t._prev;t._prev=e;var o=t._cipher.decryptBlock(e);return xor$7(o,n)};var cfb={},Buffer$i=safeBufferExports$1.Buffer,xor$6=bufferXor;function encryptStart(t,e,n){var o=e.length,u=xor$6(e,t._cache);return t._cache=t._cache.slice(o),t._prev=Buffer$i.concat([t._prev,n?e:u]),u}cfb.encrypt=function(t,e,n){for(var o=Buffer$i.allocUnsafe(0),u;e.length;)if(t._cache.length===0&&(t._cache=t._cipher.encryptBlock(t._prev),t._prev=Buffer$i.allocUnsafe(0)),t._cache.length<=e.length)u=t._cache.length,o=Buffer$i.concat([o,encryptStart(t,e.slice(0,u),n)]),e=e.slice(u);else{o=Buffer$i.concat([o,encryptStart(t,e,n)]);break}return o};var cfb8={},Buffer$h=safeBufferExports$1.Buffer;function encryptByte$1(t,e,n){var o=t._cipher.encryptBlock(t._prev),u=o[0]^e;return t._prev=Buffer$h.concat([t._prev.slice(1),Buffer$h.from([n?e:u])]),u}cfb8.encrypt=function(t,e,n){for(var o=e.length,u=Buffer$h.allocUnsafe(o),l=-1;++l<o;)u[l]=encryptByte$1(t,e[l],n);return u};var cfb1={},Buffer$g=safeBufferExports$1.Buffer;function encryptByte(t,e,n){for(var o,u=-1,l=8,m=0,y,E;++u<l;)o=t._cipher.encryptBlock(t._prev),y=e&1<<7-u?128:0,E=o[0]^y,m+=(E&128)>>u%8,t._prev=shiftIn(t._prev,n?y:E);return m}function shiftIn(t,e){var n=t.length,o=-1,u=Buffer$g.allocUnsafe(t.length);for(t=Buffer$g.concat([t,Buffer$g.from([e])]);++o<n;)u[o]=t[o]<<1|t[o+1]>>7;return u}cfb1.encrypt=function(t,e,n){for(var o=e.length,u=Buffer$g.allocUnsafe(o),l=-1;++l<o;)u[l]=encryptByte(t,e[l],n);return u};var ofb={},xor$5=bufferXor;function getBlock$1(t){return t._prev=t._cipher.encryptBlock(t._prev),t._prev}ofb.encrypt=function(t,e){for(;t._cache.length<e.length;)t._cache=Buffer$C.concat([t._cache,getBlock$1(t)]);var n=t._cache.slice(0,e.length);return t._cache=t._cache.slice(e.length),xor$5(e,n)};var ctr={};function incr32$2(t){for(var e=t.length,n;e--;)if(n=t.readUInt8(e),n===255)t.writeUInt8(0,e);else{n++,t.writeUInt8(n,e);break}}var incr32_1=incr32$2,xor$4=bufferXor,Buffer$f=safeBufferExports$1.Buffer,incr32$1=incr32_1;function getBlock(t){var e=t._cipher.encryptBlockRaw(t._prev);return incr32$1(t._prev),e}var blockSize=16;ctr.encrypt=function(t,e){var n=Math.ceil(e.length/blockSize),o=t._cache.length;t._cache=Buffer$f.concat([t._cache,Buffer$f.allocUnsafe(n*blockSize)]);for(var u=0;u<n;u++){var l=getBlock(t),m=o+u*blockSize;t._cache.writeUInt32BE(l[0],m+0),t._cache.writeUInt32BE(l[1],m+4),t._cache.writeUInt32BE(l[2],m+8),t._cache.writeUInt32BE(l[3],m+12)}var y=t._cache.slice(0,e.length);return t._cache=t._cache.slice(e.length),xor$4(e,y)};const aes128={cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},aes192={cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},aes256={cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},require$$2$1={"aes-128-ecb":{cipher:"AES",key:128,iv:0,mode:"ECB",type:"block"},"aes-192-ecb":{cipher:"AES",key:192,iv:0,mode:"ECB",type:"block"},"aes-256-ecb":{cipher:"AES",key:256,iv:0,mode:"ECB",type:"block"},"aes-128-cbc":{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},"aes-192-cbc":{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},"aes-256-cbc":{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},aes128,aes192,aes256,"aes-128-cfb":{cipher:"AES",key:128,iv:16,mode:"CFB",type:"stream"},"aes-192-cfb":{cipher:"AES",key:192,iv:16,mode:"CFB",type:"stream"},"aes-256-cfb":{cipher:"AES",key:256,iv:16,mode:"CFB",type:"stream"},"aes-128-cfb8":{cipher:"AES",key:128,iv:16,mode:"CFB8",type:"stream"},"aes-192-cfb8":{cipher:"AES",key:192,iv:16,mode:"CFB8",type:"stream"},"aes-256-cfb8":{cipher:"AES",key:256,iv:16,mode:"CFB8",type:"stream"},"aes-128-cfb1":{cipher:"AES",key:128,iv:16,mode:"CFB1",type:"stream"},"aes-192-cfb1":{cipher:"AES",key:192,iv:16,mode:"CFB1",type:"stream"},"aes-256-cfb1":{cipher:"AES",key:256,iv:16,mode:"CFB1",type:"stream"},"aes-128-ofb":{cipher:"AES",key:128,iv:16,mode:"OFB",type:"stream"},"aes-192-ofb":{cipher:"AES",key:192,iv:16,mode:"OFB",type:"stream"},"aes-256-ofb":{cipher:"AES",key:256,iv:16,mode:"OFB",type:"stream"},"aes-128-ctr":{cipher:"AES",key:128,iv:16,mode:"CTR",type:"stream"},"aes-192-ctr":{cipher:"AES",key:192,iv:16,mode:"CTR",type:"stream"},"aes-256-ctr":{cipher:"AES",key:256,iv:16,mode:"CTR",type:"stream"},"aes-128-gcm":{cipher:"AES",key:128,iv:12,mode:"GCM",type:"auth"},"aes-192-gcm":{cipher:"AES",key:192,iv:12,mode:"GCM",type:"auth"},"aes-256-gcm":{cipher:"AES",key:256,iv:12,mode:"GCM",type:"auth"}};var modeModules={ECB:ecb,CBC:cbc,CFB:cfb,CFB8:cfb8,CFB1:cfb1,OFB:ofb,CTR:ctr,GCM:ctr},modes$2=require$$2$1;for(var key$3 in modes$2)modes$2[key$3].module=modeModules[modes$2[key$3].mode];var modes_1=modes$2,aes$5={},Buffer$e=safeBufferExports$1.Buffer;function asUInt32Array(t){Buffer$e.isBuffer(t)||(t=Buffer$e.from(t));for(var e=t.length/4|0,n=new Array(e),o=0;o<e;o++)n[o]=t.readUInt32BE(o*4);return n}function scrubVec(t){for(var e=0;e<t.length;t++)t[e]=0}function cryptBlock(t,e,n,o,u){for(var l=n[0],m=n[1],y=n[2],E=n[3],C=t[0]^e[0],k=t[1]^e[1],A=t[2]^e[2],D=t[3]^e[3],P,R,B,F,j=4,N=1;N<u;N++)P=l[C>>>24]^m[k>>>16&255]^y[A>>>8&255]^E[D&255]^e[j++],R=l[k>>>24]^m[A>>>16&255]^y[D>>>8&255]^E[C&255]^e[j++],B=l[A>>>24]^m[D>>>16&255]^y[C>>>8&255]^E[k&255]^e[j++],F=l[D>>>24]^m[C>>>16&255]^y[k>>>8&255]^E[A&255]^e[j++],C=P,k=R,A=B,D=F;return P=(o[C>>>24]<<24|o[k>>>16&255]<<16|o[A>>>8&255]<<8|o[D&255])^e[j++],R=(o[k>>>24]<<24|o[A>>>16&255]<<16|o[D>>>8&255]<<8|o[C&255])^e[j++],B=(o[A>>>24]<<24|o[D>>>16&255]<<16|o[C>>>8&255]<<8|o[k&255])^e[j++],F=(o[D>>>24]<<24|o[C>>>16&255]<<16|o[k>>>8&255]<<8|o[A&255])^e[j++],P=P>>>0,R=R>>>0,B=B>>>0,F=F>>>0,[P,R,B,F]}var RCON=[0,1,2,4,8,16,32,64,128,27,54],G=function(){for(var t=new Array(256),e=0;e<256;e++)e<128?t[e]=e<<1:t[e]=e<<1^283;for(var n=[],o=[],u=[[],[],[],[]],l=[[],[],[],[]],m=0,y=0,E=0;E<256;++E){var C=y^y<<1^y<<2^y<<3^y<<4;C=C>>>8^C&255^99,n[m]=C,o[C]=m;var k=t[m],A=t[k],D=t[A],P=t[C]*257^C*16843008;u[0][m]=P<<24|P>>>8,u[1][m]=P<<16|P>>>16,u[2][m]=P<<8|P>>>24,u[3][m]=P,P=D*16843009^A*65537^k*257^m*16843008,l[0][C]=P<<24|P>>>8,l[1][C]=P<<16|P>>>16,l[2][C]=P<<8|P>>>24,l[3][C]=P,m===0?m=y=1:(m=k^t[t[t[D^k]]],y^=t[t[y]])}return{SBOX:n,INV_SBOX:o,SUB_MIX:u,INV_SUB_MIX:l}}();function AES(t){this._key=asUInt32Array(t),this._reset()}AES.blockSize=4*4,AES.keySize=256/8,AES.prototype.blockSize=AES.blockSize,AES.prototype.keySize=AES.keySize,AES.prototype._reset=function(){for(var t=this._key,e=t.length,n=e+6,o=(n+1)*4,u=[],l=0;l<e;l++)u[l]=t[l];for(l=e;l<o;l++){var m=u[l-1];l%e===0?(m=m<<8|m>>>24,m=G.SBOX[m>>>24]<<24|G.SBOX[m>>>16&255]<<16|G.SBOX[m>>>8&255]<<8|G.SBOX[m&255],m^=RCON[l/e|0]<<24):e>6&&l%e===4&&(m=G.SBOX[m>>>24]<<24|G.SBOX[m>>>16&255]<<16|G.SBOX[m>>>8&255]<<8|G.SBOX[m&255]),u[l]=u[l-e]^m}for(var y=[],E=0;E<o;E++){var C=o-E,k=u[C-(E%4?0:4)];E<4||C<=4?y[E]=k:y[E]=G.INV_SUB_MIX[0][G.SBOX[k>>>24]]^G.INV_SUB_MIX[1][G.SBOX[k>>>16&255]]^G.INV_SUB_MIX[2][G.SBOX[k>>>8&255]]^G.INV_SUB_MIX[3][G.SBOX[k&255]]}this._nRounds=n,this._keySchedule=u,this._invKeySchedule=y},AES.prototype.encryptBlockRaw=function(t){return t=asUInt32Array(t),cryptBlock(t,this._keySchedule,G.SUB_MIX,G.SBOX,this._nRounds)},AES.prototype.encryptBlock=function(t){var e=this.encryptBlockRaw(t),n=Buffer$e.allocUnsafe(16);return n.writeUInt32BE(e[0],0),n.writeUInt32BE(e[1],4),n.writeUInt32BE(e[2],8),n.writeUInt32BE(e[3],12),n},AES.prototype.decryptBlock=function(t){t=asUInt32Array(t);var e=t[1];t[1]=t[3],t[3]=e;var n=cryptBlock(t,this._invKeySchedule,G.INV_SUB_MIX,G.INV_SBOX,this._nRounds),o=Buffer$e.allocUnsafe(16);return o.writeUInt32BE(n[0],0),o.writeUInt32BE(n[3],4),o.writeUInt32BE(n[2],8),o.writeUInt32BE(n[1],12),o},AES.prototype.scrub=function(){scrubVec(this._keySchedule),scrubVec(this._invKeySchedule),scrubVec(this._key)},aes$5.AES=AES;var Buffer$d=safeBufferExports$1.Buffer,ZEROES=Buffer$d.alloc(16,0);function toArray$1(t){return[t.readUInt32BE(0),t.readUInt32BE(4),t.readUInt32BE(8),t.readUInt32BE(12)]}function fromArray(t){var e=Buffer$d.allocUnsafe(16);return e.writeUInt32BE(t[0]>>>0,0),e.writeUInt32BE(t[1]>>>0,4),e.writeUInt32BE(t[2]>>>0,8),e.writeUInt32BE(t[3]>>>0,12),e}function GHASH$1(t){this.h=t,this.state=Buffer$d.alloc(16,0),this.cache=Buffer$d.allocUnsafe(0)}GHASH$1.prototype.ghash=function(t){for(var e=-1;++e<t.length;)this.state[e]^=t[e];this._multiply()},GHASH$1.prototype._multiply=function(){for(var t=toArray$1(this.h),e=[0,0,0,0],n,o,u,l=-1;++l<128;){for(o=(this.state[~~(l/8)]&1<<7-l%8)!==0,o&&(e[0]^=t[0],e[1]^=t[1],e[2]^=t[2],e[3]^=t[3]),u=(t[3]&1)!==0,n=3;n>0;n--)t[n]=t[n]>>>1|(t[n-1]&1)<<31;t[0]=t[0]>>>1,u&&(t[0]=t[0]^225<<24)}this.state=fromArray(e)},GHASH$1.prototype.update=function(t){this.cache=Buffer$d.concat([this.cache,t]);for(var e;this.cache.length>=16;)e=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(e)},GHASH$1.prototype.final=function(t,e){return this.cache.length&&this.ghash(Buffer$d.concat([this.cache,ZEROES],16)),this.ghash(fromArray([0,t,0,e])),this.state};var ghash=GHASH$1,aes$4=aes$5,Buffer$c=safeBufferExports$1.Buffer,Transform$5=cipherBase,inherits$8=inherits_browserExports,GHASH=ghash,xor$3=bufferXor,incr32=incr32_1;function xorTest(t,e){var n=0;t.length!==e.length&&n++;for(var o=Math.min(t.length,e.length),u=0;u<o;++u)n+=t[u]^e[u];return n}function calcIv(t,e,n){if(e.length===12)return t._finID=Buffer$c.concat([e,Buffer$c.from([0,0,0,1])]),Buffer$c.concat([e,Buffer$c.from([0,0,0,2])]);var o=new GHASH(n),u=e.length,l=u%16;o.update(e),l&&(l=16-l,o.update(Buffer$c.alloc(l,0))),o.update(Buffer$c.alloc(8,0));var m=u*8,y=Buffer$c.alloc(8);y.writeUIntBE(m,0,8),o.update(y),t._finID=o.state;var E=Buffer$c.from(t._finID);return incr32(E),E}function StreamCipher$3(t,e,n,o){Transform$5.call(this);var u=Buffer$c.alloc(4,0);this._cipher=new aes$4.AES(e);var l=this._cipher.encryptBlock(u);this._ghash=new GHASH(l),n=calcIv(this,n,l),this._prev=Buffer$c.from(n),this._cache=Buffer$c.allocUnsafe(0),this._secCache=Buffer$c.allocUnsafe(0),this._decrypt=o,this._alen=0,this._len=0,this._mode=t,this._authTag=null,this._called=!1}inherits$8(StreamCipher$3,Transform$5),StreamCipher$3.prototype._update=function(t){if(!this._called&&this._alen){var e=16-this._alen%16;e<16&&(e=Buffer$c.alloc(e,0),this._ghash.update(e))}this._called=!0;var n=this._mode.encrypt(this,t);return this._decrypt?this._ghash.update(t):this._ghash.update(n),this._len+=t.length,n},StreamCipher$3.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var t=xor$3(this._ghash.final(this._alen*8,this._len*8),this._cipher.encryptBlock(this._finID));if(this._decrypt&&xorTest(t,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=t,this._cipher.scrub()},StreamCipher$3.prototype.getAuthTag=function(){if(this._decrypt||!Buffer$c.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},StreamCipher$3.prototype.setAuthTag=function(e){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=e},StreamCipher$3.prototype.setAAD=function(e){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(e),this._alen+=e.length};var authCipher=StreamCipher$3,aes$3=aes$5,Buffer$b=safeBufferExports$1.Buffer,Transform$4=cipherBase,inherits$7=inherits_browserExports;function StreamCipher$2(t,e,n,o){Transform$4.call(this),this._cipher=new aes$3.AES(e),this._prev=Buffer$b.from(n),this._cache=Buffer$b.allocUnsafe(0),this._secCache=Buffer$b.allocUnsafe(0),this._decrypt=o,this._mode=t}inherits$7(StreamCipher$2,Transform$4),StreamCipher$2.prototype._update=function(t){return this._mode.encrypt(this,t,this._decrypt)},StreamCipher$2.prototype._final=function(){this._cipher.scrub()};var streamCipher=StreamCipher$2,Buffer$a=safeBufferExports$1.Buffer,MD5=md5_js;function EVP_BytesToKey(t,e,n,o){if(Buffer$a.isBuffer(t)||(t=Buffer$a.from(t,"binary")),e&&(Buffer$a.isBuffer(e)||(e=Buffer$a.from(e,"binary")),e.length!==8))throw new RangeError("salt should be Buffer with 8 byte length");for(var u=n/8,l=Buffer$a.alloc(u),m=Buffer$a.alloc(o||0),y=Buffer$a.alloc(0);u>0||o>0;){var E=new MD5;E.update(y),E.update(t),e&&E.update(e),y=E.digest();var C=0;if(u>0){var k=l.length-u;C=Math.min(u,y.length),y.copy(l,k,0,C),u-=C}if(C<y.length&&o>0){var A=m.length-o,D=Math.min(o,y.length-C);y.copy(m,A,C,C+D),o-=D}}return y.fill(0),{key:l,iv:m}}var evp_bytestokey=EVP_BytesToKey,MODES$1=modes_1,AuthCipher$1=authCipher,Buffer$9=safeBufferExports$1.Buffer,StreamCipher$1=streamCipher,Transform$3=cipherBase,aes$2=aes$5,ebtk$2=evp_bytestokey,inherits$6=inherits_browserExports;function Cipher(t,e,n){Transform$3.call(this),this._cache=new Splitter$1,this._cipher=new aes$2.AES(e),this._prev=Buffer$9.from(n),this._mode=t,this._autopadding=!0}inherits$6(Cipher,Transform$3),Cipher.prototype._update=function(t){this._cache.add(t);for(var e,n,o=[];e=this._cache.get();)n=this._mode.encrypt(this,e),o.push(n);return Buffer$9.concat(o)};var PADDING=Buffer$9.alloc(16,16);Cipher.prototype._final=function(){var t=this._cache.flush();if(this._autopadding)return t=this._mode.encrypt(this,t),this._cipher.scrub(),t;if(!t.equals(PADDING))throw this._cipher.scrub(),new Error("data not multiple of block length")},Cipher.prototype.setAutoPadding=function(t){return this._autopadding=!!t,this};function Splitter$1(){this.cache=Buffer$9.allocUnsafe(0)}Splitter$1.prototype.add=function(t){this.cache=Buffer$9.concat([this.cache,t])},Splitter$1.prototype.get=function(){if(this.cache.length>15){var t=this.cache.slice(0,16);return this.cache=this.cache.slice(16),t}return null},Splitter$1.prototype.flush=function(){for(var t=16-this.cache.length,e=Buffer$9.allocUnsafe(t),n=-1;++n<t;)e.writeUInt8(t,n);return Buffer$9.concat([this.cache,e])};function createCipheriv$1(t,e,n){var o=MODES$1[t.toLowerCase()];if(!o)throw new TypeError("invalid suite type");if(typeof e=="string"&&(e=Buffer$9.from(e)),e.length!==o.key/8)throw new TypeError("invalid key length "+e.length);if(typeof n=="string"&&(n=Buffer$9.from(n)),o.mode!=="GCM"&&n.length!==o.iv)throw new TypeError("invalid iv length "+n.length);return o.type==="stream"?new StreamCipher$1(o.module,e,n):o.type==="auth"?new AuthCipher$1(o.module,e,n):new Cipher(o.module,e,n)}function createCipher$1(t,e){var n=MODES$1[t.toLowerCase()];if(!n)throw new TypeError("invalid suite type");var o=ebtk$2(e,!1,n.key,n.iv);return createCipheriv$1(t,o.key,o.iv)}encrypter.createCipheriv=createCipheriv$1,encrypter.createCipher=createCipher$1;var decrypter={},AuthCipher=authCipher,Buffer$8=safeBufferExports$1.Buffer,MODES=modes_1,StreamCipher=streamCipher,Transform$2=cipherBase,aes$1=aes$5,ebtk$1=evp_bytestokey,inherits$5=inherits_browserExports;function Decipher(t,e,n){Transform$2.call(this),this._cache=new Splitter,this._last=void 0,this._cipher=new aes$1.AES(e),this._prev=Buffer$8.from(n),this._mode=t,this._autopadding=!0}inherits$5(Decipher,Transform$2),Decipher.prototype._update=function(t){this._cache.add(t);for(var e,n,o=[];e=this._cache.get(this._autopadding);)n=this._mode.decrypt(this,e),o.push(n);return Buffer$8.concat(o)},Decipher.prototype._final=function(){var t=this._cache.flush();if(this._autopadding)return unpad(this._mode.decrypt(this,t));if(t)throw new Error("data not multiple of block length")},Decipher.prototype.setAutoPadding=function(t){return this._autopadding=!!t,this};function Splitter(){this.cache=Buffer$8.allocUnsafe(0)}Splitter.prototype.add=function(t){this.cache=Buffer$8.concat([this.cache,t])},Splitter.prototype.get=function(t){var e;if(t){if(this.cache.length>16)return e=this.cache.slice(0,16),this.cache=this.cache.slice(16),e}else if(this.cache.length>=16)return e=this.cache.slice(0,16),this.cache=this.cache.slice(16),e;return null},Splitter.prototype.flush=function(){if(this.cache.length)return this.cache};function unpad(t){var e=t[15];if(e<1||e>16)throw new Error("unable to decrypt data");for(var n=-1;++n<e;)if(t[n+(16-e)]!==e)throw new Error("unable to decrypt data");if(e!==16)return t.slice(0,16-e)}function createDecipheriv$1(t,e,n){var o=MODES[t.toLowerCase()];if(!o)throw new TypeError("invalid suite type");if(typeof n=="string"&&(n=Buffer$8.from(n)),o.mode!=="GCM"&&n.length!==o.iv)throw new TypeError("invalid iv length "+n.length);if(typeof e=="string"&&(e=Buffer$8.from(e)),e.length!==o.key/8)throw new TypeError("invalid key length "+e.length);return o.type==="stream"?new StreamCipher(o.module,e,n,!0):o.type==="auth"?new AuthCipher(o.module,e,n,!0):new Decipher(o.module,e,n)}function createDecipher$1(t,e){var n=MODES[t.toLowerCase()];if(!n)throw new TypeError("invalid suite type");var o=ebtk$1(e,!1,n.key,n.iv);return createDecipheriv$1(t,o.key,o.iv)}decrypter.createDecipher=createDecipher$1,decrypter.createDecipheriv=createDecipheriv$1;var ciphers$2=encrypter,deciphers=decrypter,modes$1=require$$2$1;function getCiphers$1(){return Object.keys(modes$1)}browser$7.createCipher=browser$7.Cipher=ciphers$2.createCipher,browser$7.createCipheriv=browser$7.Cipheriv=ciphers$2.createCipheriv,browser$7.createDecipher=browser$7.Decipher=deciphers.createDecipher,browser$7.createDecipheriv=browser$7.Decipheriv=deciphers.createDecipheriv,browser$7.listCiphers=browser$7.getCiphers=getCiphers$1;var modes={};(function(t){t["des-ecb"]={key:8,iv:0},t["des-cbc"]=t.des={key:8,iv:8},t["des-ede3-cbc"]=t.des3={key:24,iv:8},t["des-ede3"]={key:24,iv:0},t["des-ede-cbc"]={key:16,iv:8},t["des-ede"]={key:16,iv:0}})(modes);var DES=browserifyDes,aes=browser$7,aesModes=modes_1,desModes=modes,ebtk=evp_bytestokey;function createCipher(t,e){t=t.toLowerCase();var n,o;if(aesModes[t])n=aesModes[t].key,o=aesModes[t].iv;else if(desModes[t])n=desModes[t].key*8,o=desModes[t].iv;else throw new TypeError("invalid suite type");var u=ebtk(e,!1,n,o);return createCipheriv(t,u.key,u.iv)}function createDecipher(t,e){t=t.toLowerCase();var n,o;if(aesModes[t])n=aesModes[t].key,o=aesModes[t].iv;else if(desModes[t])n=desModes[t].key*8,o=desModes[t].iv;else throw new TypeError("invalid suite type");var u=ebtk(e,!1,n,o);return createDecipheriv(t,u.key,u.iv)}function createCipheriv(t,e,n){if(t=t.toLowerCase(),aesModes[t])return aes.createCipheriv(t,e,n);if(desModes[t])return new DES({key:e,iv:n,mode:t});throw new TypeError("invalid suite type")}function createDecipheriv(t,e,n){if(t=t.toLowerCase(),aesModes[t])return aes.createDecipheriv(t,e,n);if(desModes[t])return new DES({key:e,iv:n,mode:t,decrypt:!0});throw new TypeError("invalid suite type")}function getCiphers(){return Object.keys(desModes).concat(aes.getCiphers())}browser$8.createCipher=browser$8.Cipher=createCipher,browser$8.createCipheriv=browser$8.Cipheriv=createCipheriv,browser$8.createDecipher=browser$8.Decipher=createDecipher,browser$8.createDecipheriv=browser$8.Decipheriv=createDecipheriv,browser$8.listCiphers=browser$8.getCiphers=getCiphers;var browser$6={},bn$6={exports:{}};bn$6.exports,function(t){(function(e,n){function o(L,d){if(!L)throw new Error(d||"Assertion failed")}function u(L,d){L.super_=d;var v=function(){};v.prototype=d.prototype,L.prototype=new v,L.prototype.constructor=L}function l(L,d,v){if(l.isBN(L))return L;this.negative=0,this.words=null,this.length=0,this.red=null,L!==null&&((d==="le"||d==="be")&&(v=d,d=10),this._init(L||0,d||10,v||"be"))}typeof e=="object"?e.exports=l:n.BN=l,l.BN=l,l.wordSize=26;var m;try{typeof window<"u"&&typeof window.Buffer<"u"?m=window.Buffer:m=require$$0$2.Buffer}catch{}l.isBN=function(d){return d instanceof l?!0:d!==null&&typeof d=="object"&&d.constructor.wordSize===l.wordSize&&Array.isArray(d.words)},l.max=function(d,v){return d.cmp(v)>0?d:v},l.min=function(d,v){return d.cmp(v)<0?d:v},l.prototype._init=function(d,v,w){if(typeof d=="number")return this._initNumber(d,v,w);if(typeof d=="object")return this._initArray(d,v,w);v==="hex"&&(v=16),o(v===(v|0)&&v>=2&&v<=36),d=d.toString().replace(/\s+/g,"");var c=0;d[0]==="-"&&(c++,this.negative=1),c<d.length&&(v===16?this._parseHex(d,c,w):(this._parseBase(d,v,c),w==="le"&&this._initArray(this.toArray(),v,w)))},l.prototype._initNumber=function(d,v,w){d<0&&(this.negative=1,d=-d),d<67108864?(this.words=[d&67108863],this.length=1):d<4503599627370496?(this.words=[d&67108863,d/67108864&67108863],this.length=2):(o(d<9007199254740992),this.words=[d&67108863,d/67108864&67108863,1],this.length=3),w==="le"&&this._initArray(this.toArray(),v,w)},l.prototype._initArray=function(d,v,w){if(o(typeof d.length=="number"),d.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(d.length/3),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p,x,S=0;if(w==="be")for(c=d.length-1,p=0;c>=0;c-=3)x=d[c]|d[c-1]<<8|d[c-2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);else if(w==="le")for(c=0,p=0;c<d.length;c+=3)x=d[c]|d[c+1]<<8|d[c+2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);return this.strip()};function y(L,d){var v=L.charCodeAt(d);return v>=65&&v<=70?v-55:v>=97&&v<=102?v-87:v-48&15}function E(L,d,v){var w=y(L,v);return v-1>=d&&(w|=y(L,v-1)<<4),w}l.prototype._parseHex=function(d,v,w){this.length=Math.ceil((d.length-v)/6),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p=0,x=0,S;if(w==="be")for(c=d.length-1;c>=v;c-=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8;else{var b=d.length-v;for(c=b%2===0?v+1:v;c<d.length;c+=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8}this.strip()};function C(L,d,v,w){for(var c=0,p=Math.min(L.length,v),x=d;x<p;x++){var S=L.charCodeAt(x)-48;c*=w,S>=49?c+=S-49+10:S>=17?c+=S-17+10:c+=S}return c}l.prototype._parseBase=function(d,v,w){this.words=[0],this.length=1;for(var c=0,p=1;p<=67108863;p*=v)c++;c--,p=p/v|0;for(var x=d.length-w,S=x%c,b=Math.min(x,x-S)+w,h=0,T=w;T<b;T+=c)h=C(d,T,T+c,v),this.imuln(p),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h);if(S!==0){var M=1;for(h=C(d,T,d.length,v),T=0;T<S;T++)M*=v;this.imuln(M),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h)}this.strip()},l.prototype.copy=function(d){d.words=new Array(this.length);for(var v=0;v<this.length;v++)d.words[v]=this.words[v];d.length=this.length,d.negative=this.negative,d.red=this.red},l.prototype.clone=function(){var d=new l(null);return this.copy(d),d},l.prototype._expand=function(d){for(;this.length<d;)this.words[this.length++]=0;return this},l.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},l.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},l.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var k=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],D=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];l.prototype.toString=function(d,v){d=d||10,v=v|0||1;var w;if(d===16||d==="hex"){w="";for(var c=0,p=0,x=0;x<this.length;x++){var S=this.words[x],b=((S<<c|p)&16777215).toString(16);p=S>>>24-c&16777215,p!==0||x!==this.length-1?w=k[6-b.length]+b+w:w=b+w,c+=2,c>=26&&(c-=26,x--)}for(p!==0&&(w=p.toString(16)+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}if(d===(d|0)&&d>=2&&d<=36){var h=A[d],T=D[d];w="";var M=this.clone();for(M.negative=0;!M.isZero();){var O=M.modn(T).toString(d);M=M.idivn(T),M.isZero()?w=O+w:w=k[h-O.length]+O+w}for(this.isZero()&&(w="0"+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}o(!1,"Base should be between 2 and 36")},l.prototype.toNumber=function(){var d=this.words[0];return this.length===2?d+=this.words[1]*67108864:this.length===3&&this.words[2]===1?d+=4503599627370496+this.words[1]*67108864:this.length>2&&o(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-d:d},l.prototype.toJSON=function(){return this.toString(16)},l.prototype.toBuffer=function(d,v){return o(typeof m<"u"),this.toArrayLike(m,d,v)},l.prototype.toArray=function(d,v){return this.toArrayLike(Array,d,v)},l.prototype.toArrayLike=function(d,v,w){var c=this.byteLength(),p=w||Math.max(1,c);o(c<=p,"byte array longer than desired length"),o(p>0,"Requested array length <= 0"),this.strip();var x=v==="le",S=new d(p),b,h,T=this.clone();if(x){for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[h]=b;for(;h<p;h++)S[h]=0}else{for(h=0;h<p-c;h++)S[h]=0;for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[p-h-1]=b}return S},Math.clz32?l.prototype._countBits=function(d){return 32-Math.clz32(d)}:l.prototype._countBits=function(d){var v=d,w=0;return v>=4096&&(w+=13,v>>>=13),v>=64&&(w+=7,v>>>=7),v>=8&&(w+=4,v>>>=4),v>=2&&(w+=2,v>>>=2),w+v},l.prototype._zeroBits=function(d){if(d===0)return 26;var v=d,w=0;return v&8191||(w+=13,v>>>=13),v&127||(w+=7,v>>>=7),v&15||(w+=4,v>>>=4),v&3||(w+=2,v>>>=2),v&1||w++,w},l.prototype.bitLength=function(){var d=this.words[this.length-1],v=this._countBits(d);return(this.length-1)*26+v};function P(L){for(var d=new Array(L.bitLength()),v=0;v<d.length;v++){var w=v/26|0,c=v%26;d[v]=(L.words[w]&1<<c)>>>c}return d}l.prototype.zeroBits=function(){if(this.isZero())return 0;for(var d=0,v=0;v<this.length;v++){var w=this._zeroBits(this.words[v]);if(d+=w,w!==26)break}return d},l.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},l.prototype.toTwos=function(d){return this.negative!==0?this.abs().inotn(d).iaddn(1):this.clone()},l.prototype.fromTwos=function(d){return this.testn(d-1)?this.notn(d).iaddn(1).ineg():this.clone()},l.prototype.isNeg=function(){return this.negative!==0},l.prototype.neg=function(){return this.clone().ineg()},l.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},l.prototype.iuor=function(d){for(;this.length<d.length;)this.words[this.length++]=0;for(var v=0;v<d.length;v++)this.words[v]=this.words[v]|d.words[v];return this.strip()},l.prototype.ior=function(d){return o((this.negative|d.negative)===0),this.iuor(d)},l.prototype.or=function(d){return this.length>d.length?this.clone().ior(d):d.clone().ior(this)},l.prototype.uor=function(d){return this.length>d.length?this.clone().iuor(d):d.clone().iuor(this)},l.prototype.iuand=function(d){var v;this.length>d.length?v=d:v=this;for(var w=0;w<v.length;w++)this.words[w]=this.words[w]&d.words[w];return this.length=v.length,this.strip()},l.prototype.iand=function(d){return o((this.negative|d.negative)===0),this.iuand(d)},l.prototype.and=function(d){return this.length>d.length?this.clone().iand(d):d.clone().iand(this)},l.prototype.uand=function(d){return this.length>d.length?this.clone().iuand(d):d.clone().iuand(this)},l.prototype.iuxor=function(d){var v,w;this.length>d.length?(v=this,w=d):(v=d,w=this);for(var c=0;c<w.length;c++)this.words[c]=v.words[c]^w.words[c];if(this!==v)for(;c<v.length;c++)this.words[c]=v.words[c];return this.length=v.length,this.strip()},l.prototype.ixor=function(d){return o((this.negative|d.negative)===0),this.iuxor(d)},l.prototype.xor=function(d){return this.length>d.length?this.clone().ixor(d):d.clone().ixor(this)},l.prototype.uxor=function(d){return this.length>d.length?this.clone().iuxor(d):d.clone().iuxor(this)},l.prototype.inotn=function(d){o(typeof d=="number"&&d>=0);var v=Math.ceil(d/26)|0,w=d%26;this._expand(v),w>0&&v--;for(var c=0;c<v;c++)this.words[c]=~this.words[c]&67108863;return w>0&&(this.words[c]=~this.words[c]&67108863>>26-w),this.strip()},l.prototype.notn=function(d){return this.clone().inotn(d)},l.prototype.setn=function(d,v){o(typeof d=="number"&&d>=0);var w=d/26|0,c=d%26;return this._expand(w+1),v?this.words[w]=this.words[w]|1<<c:this.words[w]=this.words[w]&~(1<<c),this.strip()},l.prototype.iadd=function(d){var v;if(this.negative!==0&&d.negative===0)return this.negative=0,v=this.isub(d),this.negative^=1,this._normSign();if(this.negative===0&&d.negative!==0)return d.negative=0,v=this.isub(d),d.negative=1,v._normSign();var w,c;this.length>d.length?(w=this,c=d):(w=d,c=this);for(var p=0,x=0;x<c.length;x++)v=(w.words[x]|0)+(c.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;for(;p!==0&&x<w.length;x++)v=(w.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;if(this.length=w.length,p!==0)this.words[this.length]=p,this.length++;else if(w!==this)for(;x<w.length;x++)this.words[x]=w.words[x];return this},l.prototype.add=function(d){var v;return d.negative!==0&&this.negative===0?(d.negative=0,v=this.sub(d),d.negative^=1,v):d.negative===0&&this.negative!==0?(this.negative=0,v=d.sub(this),this.negative=1,v):this.length>d.length?this.clone().iadd(d):d.clone().iadd(this)},l.prototype.isub=function(d){if(d.negative!==0){d.negative=0;var v=this.iadd(d);return d.negative=1,v._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(d),this.negative=1,this._normSign();var w=this.cmp(d);if(w===0)return this.negative=0,this.length=1,this.words[0]=0,this;var c,p;w>0?(c=this,p=d):(c=d,p=this);for(var x=0,S=0;S<p.length;S++)v=(c.words[S]|0)-(p.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;for(;x!==0&&S<c.length;S++)v=(c.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;if(x===0&&S<c.length&&c!==this)for(;S<c.length;S++)this.words[S]=c.words[S];return this.length=Math.max(this.length,S),c!==this&&(this.negative=1),this.strip()},l.prototype.sub=function(d){return this.clone().isub(d)};function R(L,d,v){v.negative=d.negative^L.negative;var w=L.length+d.length|0;v.length=w,w=w-1|0;var c=L.words[0]|0,p=d.words[0]|0,x=c*p,S=x&67108863,b=x/67108864|0;v.words[0]=S;for(var h=1;h<w;h++){for(var T=b>>>26,M=b&67108863,O=Math.min(h,d.length-1),V=Math.max(0,h-L.length+1);V<=O;V++){var ee=h-V|0;c=L.words[ee]|0,p=d.words[V]|0,x=c*p+M,T+=x/67108864|0,M=x&67108863}v.words[h]=M|0,b=T|0}return b!==0?v.words[h]=b|0:v.length--,v.strip()}var B=function(d,v,w){var c=d.words,p=v.words,x=w.words,S=0,b,h,T,M=c[0]|0,O=M&8191,V=M>>>13,ee=c[1]|0,Z=ee&8191,U=ee>>>13,z=c[2]|0,ne=z&8191,fe=z>>>13,me=c[3]|0,de=me&8191,je=me>>>13,lt=c[4]|0,it=lt&8191,ot=lt>>>13,Ct=c[5]|0,nt=Ct&8191,Je=Ct>>>13,tt=c[6]|0,rt=tt&8191,ht=tt>>>13,Ot=c[7]|0,Ve=Ot&8191,We=Ot>>>13,Gt=c[8]|0,wt=Gt&8191,Et=Gt>>>13,Yt=c[9]|0,Ce=Yt&8191,te=Yt>>>13,ye=p[0]|0,Le=ye&8191,Ue=ye>>>13,Qe=p[1]|0,Ke=Qe&8191,De=Qe>>>13,Vt=p[2]|0,At=Vt&8191,ve=Vt>>>13,Pt=p[3]|0,pt=Pt&8191,Ne=Pt>>>13,vt=p[4]|0,ut=vt&8191,$t=vt>>>13,fi=p[5]|0,kt=fi&8191,Wt=fi>>>13,Zi=p[6]|0,Ut=Zi&8191,Xt=Zi>>>13,Be=p[7]|0,be=Be&8191,ge=Be>>>13,oe=p[8]|0,Ae=oe&8191,qe=oe>>>13,bt=p[9]|0,at=bt&8191,gt=bt>>>13;w.negative=d.negative^v.negative,w.length=19,b=Math.imul(O,Le),h=Math.imul(O,Ue),h=h+Math.imul(V,Le)|0,T=Math.imul(V,Ue);var ei=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ei>>>26)|0,ei&=67108863,b=Math.imul(Z,Le),h=Math.imul(Z,Ue),h=h+Math.imul(U,Le)|0,T=Math.imul(U,Ue),b=b+Math.imul(O,Ke)|0,h=h+Math.imul(O,De)|0,h=h+Math.imul(V,Ke)|0,T=T+Math.imul(V,De)|0;var ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ii>>>26)|0,ii&=67108863,b=Math.imul(ne,Le),h=Math.imul(ne,Ue),h=h+Math.imul(fe,Le)|0,T=Math.imul(fe,Ue),b=b+Math.imul(Z,Ke)|0,h=h+Math.imul(Z,De)|0,h=h+Math.imul(U,Ke)|0,T=T+Math.imul(U,De)|0,b=b+Math.imul(O,At)|0,h=h+Math.imul(O,ve)|0,h=h+Math.imul(V,At)|0,T=T+Math.imul(V,ve)|0;var Bi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Bi>>>26)|0,Bi&=67108863,b=Math.imul(de,Le),h=Math.imul(de,Ue),h=h+Math.imul(je,Le)|0,T=Math.imul(je,Ue),b=b+Math.imul(ne,Ke)|0,h=h+Math.imul(ne,De)|0,h=h+Math.imul(fe,Ke)|0,T=T+Math.imul(fe,De)|0,b=b+Math.imul(Z,At)|0,h=h+Math.imul(Z,ve)|0,h=h+Math.imul(U,At)|0,T=T+Math.imul(U,ve)|0,b=b+Math.imul(O,pt)|0,h=h+Math.imul(O,Ne)|0,h=h+Math.imul(V,pt)|0,T=T+Math.imul(V,Ne)|0;var hi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(hi>>>26)|0,hi&=67108863,b=Math.imul(it,Le),h=Math.imul(it,Ue),h=h+Math.imul(ot,Le)|0,T=Math.imul(ot,Ue),b=b+Math.imul(de,Ke)|0,h=h+Math.imul(de,De)|0,h=h+Math.imul(je,Ke)|0,T=T+Math.imul(je,De)|0,b=b+Math.imul(ne,At)|0,h=h+Math.imul(ne,ve)|0,h=h+Math.imul(fe,At)|0,T=T+Math.imul(fe,ve)|0,b=b+Math.imul(Z,pt)|0,h=h+Math.imul(Z,Ne)|0,h=h+Math.imul(U,pt)|0,T=T+Math.imul(U,Ne)|0,b=b+Math.imul(O,ut)|0,h=h+Math.imul(O,$t)|0,h=h+Math.imul(V,ut)|0,T=T+Math.imul(V,$t)|0;var Di=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Di>>>26)|0,Di&=67108863,b=Math.imul(nt,Le),h=Math.imul(nt,Ue),h=h+Math.imul(Je,Le)|0,T=Math.imul(Je,Ue),b=b+Math.imul(it,Ke)|0,h=h+Math.imul(it,De)|0,h=h+Math.imul(ot,Ke)|0,T=T+Math.imul(ot,De)|0,b=b+Math.imul(de,At)|0,h=h+Math.imul(de,ve)|0,h=h+Math.imul(je,At)|0,T=T+Math.imul(je,ve)|0,b=b+Math.imul(ne,pt)|0,h=h+Math.imul(ne,Ne)|0,h=h+Math.imul(fe,pt)|0,T=T+Math.imul(fe,Ne)|0,b=b+Math.imul(Z,ut)|0,h=h+Math.imul(Z,$t)|0,h=h+Math.imul(U,ut)|0,T=T+Math.imul(U,$t)|0,b=b+Math.imul(O,kt)|0,h=h+Math.imul(O,Wt)|0,h=h+Math.imul(V,kt)|0,T=T+Math.imul(V,Wt)|0;var ni=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ni>>>26)|0,ni&=67108863,b=Math.imul(rt,Le),h=Math.imul(rt,Ue),h=h+Math.imul(ht,Le)|0,T=Math.imul(ht,Ue),b=b+Math.imul(nt,Ke)|0,h=h+Math.imul(nt,De)|0,h=h+Math.imul(Je,Ke)|0,T=T+Math.imul(Je,De)|0,b=b+Math.imul(it,At)|0,h=h+Math.imul(it,ve)|0,h=h+Math.imul(ot,At)|0,T=T+Math.imul(ot,ve)|0,b=b+Math.imul(de,pt)|0,h=h+Math.imul(de,Ne)|0,h=h+Math.imul(je,pt)|0,T=T+Math.imul(je,Ne)|0,b=b+Math.imul(ne,ut)|0,h=h+Math.imul(ne,$t)|0,h=h+Math.imul(fe,ut)|0,T=T+Math.imul(fe,$t)|0,b=b+Math.imul(Z,kt)|0,h=h+Math.imul(Z,Wt)|0,h=h+Math.imul(U,kt)|0,T=T+Math.imul(U,Wt)|0,b=b+Math.imul(O,Ut)|0,h=h+Math.imul(O,Xt)|0,h=h+Math.imul(V,Ut)|0,T=T+Math.imul(V,Xt)|0;var pi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(pi>>>26)|0,pi&=67108863,b=Math.imul(Ve,Le),h=Math.imul(Ve,Ue),h=h+Math.imul(We,Le)|0,T=Math.imul(We,Ue),b=b+Math.imul(rt,Ke)|0,h=h+Math.imul(rt,De)|0,h=h+Math.imul(ht,Ke)|0,T=T+Math.imul(ht,De)|0,b=b+Math.imul(nt,At)|0,h=h+Math.imul(nt,ve)|0,h=h+Math.imul(Je,At)|0,T=T+Math.imul(Je,ve)|0,b=b+Math.imul(it,pt)|0,h=h+Math.imul(it,Ne)|0,h=h+Math.imul(ot,pt)|0,T=T+Math.imul(ot,Ne)|0,b=b+Math.imul(de,ut)|0,h=h+Math.imul(de,$t)|0,h=h+Math.imul(je,ut)|0,T=T+Math.imul(je,$t)|0,b=b+Math.imul(ne,kt)|0,h=h+Math.imul(ne,Wt)|0,h=h+Math.imul(fe,kt)|0,T=T+Math.imul(fe,Wt)|0,b=b+Math.imul(Z,Ut)|0,h=h+Math.imul(Z,Xt)|0,h=h+Math.imul(U,Ut)|0,T=T+Math.imul(U,Xt)|0,b=b+Math.imul(O,be)|0,h=h+Math.imul(O,ge)|0,h=h+Math.imul(V,be)|0,T=T+Math.imul(V,ge)|0;var Ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ii>>>26)|0,Ii&=67108863,b=Math.imul(wt,Le),h=Math.imul(wt,Ue),h=h+Math.imul(Et,Le)|0,T=Math.imul(Et,Ue),b=b+Math.imul(Ve,Ke)|0,h=h+Math.imul(Ve,De)|0,h=h+Math.imul(We,Ke)|0,T=T+Math.imul(We,De)|0,b=b+Math.imul(rt,At)|0,h=h+Math.imul(rt,ve)|0,h=h+Math.imul(ht,At)|0,T=T+Math.imul(ht,ve)|0,b=b+Math.imul(nt,pt)|0,h=h+Math.imul(nt,Ne)|0,h=h+Math.imul(Je,pt)|0,T=T+Math.imul(Je,Ne)|0,b=b+Math.imul(it,ut)|0,h=h+Math.imul(it,$t)|0,h=h+Math.imul(ot,ut)|0,T=T+Math.imul(ot,$t)|0,b=b+Math.imul(de,kt)|0,h=h+Math.imul(de,Wt)|0,h=h+Math.imul(je,kt)|0,T=T+Math.imul(je,Wt)|0,b=b+Math.imul(ne,Ut)|0,h=h+Math.imul(ne,Xt)|0,h=h+Math.imul(fe,Ut)|0,T=T+Math.imul(fe,Xt)|0,b=b+Math.imul(Z,be)|0,h=h+Math.imul(Z,ge)|0,h=h+Math.imul(U,be)|0,T=T+Math.imul(U,ge)|0,b=b+Math.imul(O,Ae)|0,h=h+Math.imul(O,qe)|0,h=h+Math.imul(V,Ae)|0,T=T+Math.imul(V,qe)|0;var Ci=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ci>>>26)|0,Ci&=67108863,b=Math.imul(Ce,Le),h=Math.imul(Ce,Ue),h=h+Math.imul(te,Le)|0,T=Math.imul(te,Ue),b=b+Math.imul(wt,Ke)|0,h=h+Math.imul(wt,De)|0,h=h+Math.imul(Et,Ke)|0,T=T+Math.imul(Et,De)|0,b=b+Math.imul(Ve,At)|0,h=h+Math.imul(Ve,ve)|0,h=h+Math.imul(We,At)|0,T=T+Math.imul(We,ve)|0,b=b+Math.imul(rt,pt)|0,h=h+Math.imul(rt,Ne)|0,h=h+Math.imul(ht,pt)|0,T=T+Math.imul(ht,Ne)|0,b=b+Math.imul(nt,ut)|0,h=h+Math.imul(nt,$t)|0,h=h+Math.imul(Je,ut)|0,T=T+Math.imul(Je,$t)|0,b=b+Math.imul(it,kt)|0,h=h+Math.imul(it,Wt)|0,h=h+Math.imul(ot,kt)|0,T=T+Math.imul(ot,Wt)|0,b=b+Math.imul(de,Ut)|0,h=h+Math.imul(de,Xt)|0,h=h+Math.imul(je,Ut)|0,T=T+Math.imul(je,Xt)|0,b=b+Math.imul(ne,be)|0,h=h+Math.imul(ne,ge)|0,h=h+Math.imul(fe,be)|0,T=T+Math.imul(fe,ge)|0,b=b+Math.imul(Z,Ae)|0,h=h+Math.imul(Z,qe)|0,h=h+Math.imul(U,Ae)|0,T=T+Math.imul(U,qe)|0,b=b+Math.imul(O,at)|0,h=h+Math.imul(O,gt)|0,h=h+Math.imul(V,at)|0,T=T+Math.imul(V,gt)|0;var zi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zi>>>26)|0,zi&=67108863,b=Math.imul(Ce,Ke),h=Math.imul(Ce,De),h=h+Math.imul(te,Ke)|0,T=Math.imul(te,De),b=b+Math.imul(wt,At)|0,h=h+Math.imul(wt,ve)|0,h=h+Math.imul(Et,At)|0,T=T+Math.imul(Et,ve)|0,b=b+Math.imul(Ve,pt)|0,h=h+Math.imul(Ve,Ne)|0,h=h+Math.imul(We,pt)|0,T=T+Math.imul(We,Ne)|0,b=b+Math.imul(rt,ut)|0,h=h+Math.imul(rt,$t)|0,h=h+Math.imul(ht,ut)|0,T=T+Math.imul(ht,$t)|0,b=b+Math.imul(nt,kt)|0,h=h+Math.imul(nt,Wt)|0,h=h+Math.imul(Je,kt)|0,T=T+Math.imul(Je,Wt)|0,b=b+Math.imul(it,Ut)|0,h=h+Math.imul(it,Xt)|0,h=h+Math.imul(ot,Ut)|0,T=T+Math.imul(ot,Xt)|0,b=b+Math.imul(de,be)|0,h=h+Math.imul(de,ge)|0,h=h+Math.imul(je,be)|0,T=T+Math.imul(je,ge)|0,b=b+Math.imul(ne,Ae)|0,h=h+Math.imul(ne,qe)|0,h=h+Math.imul(fe,Ae)|0,T=T+Math.imul(fe,qe)|0,b=b+Math.imul(Z,at)|0,h=h+Math.imul(Z,gt)|0,h=h+Math.imul(U,at)|0,T=T+Math.imul(U,gt)|0;var qi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(qi>>>26)|0,qi&=67108863,b=Math.imul(Ce,At),h=Math.imul(Ce,ve),h=h+Math.imul(te,At)|0,T=Math.imul(te,ve),b=b+Math.imul(wt,pt)|0,h=h+Math.imul(wt,Ne)|0,h=h+Math.imul(Et,pt)|0,T=T+Math.imul(Et,Ne)|0,b=b+Math.imul(Ve,ut)|0,h=h+Math.imul(Ve,$t)|0,h=h+Math.imul(We,ut)|0,T=T+Math.imul(We,$t)|0,b=b+Math.imul(rt,kt)|0,h=h+Math.imul(rt,Wt)|0,h=h+Math.imul(ht,kt)|0,T=T+Math.imul(ht,Wt)|0,b=b+Math.imul(nt,Ut)|0,h=h+Math.imul(nt,Xt)|0,h=h+Math.imul(Je,Ut)|0,T=T+Math.imul(Je,Xt)|0,b=b+Math.imul(it,be)|0,h=h+Math.imul(it,ge)|0,h=h+Math.imul(ot,be)|0,T=T+Math.imul(ot,ge)|0,b=b+Math.imul(de,Ae)|0,h=h+Math.imul(de,qe)|0,h=h+Math.imul(je,Ae)|0,T=T+Math.imul(je,qe)|0,b=b+Math.imul(ne,at)|0,h=h+Math.imul(ne,gt)|0,h=h+Math.imul(fe,at)|0,T=T+Math.imul(fe,gt)|0;var Ai=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ai>>>26)|0,Ai&=67108863,b=Math.imul(Ce,pt),h=Math.imul(Ce,Ne),h=h+Math.imul(te,pt)|0,T=Math.imul(te,Ne),b=b+Math.imul(wt,ut)|0,h=h+Math.imul(wt,$t)|0,h=h+Math.imul(Et,ut)|0,T=T+Math.imul(Et,$t)|0,b=b+Math.imul(Ve,kt)|0,h=h+Math.imul(Ve,Wt)|0,h=h+Math.imul(We,kt)|0,T=T+Math.imul(We,Wt)|0,b=b+Math.imul(rt,Ut)|0,h=h+Math.imul(rt,Xt)|0,h=h+Math.imul(ht,Ut)|0,T=T+Math.imul(ht,Xt)|0,b=b+Math.imul(nt,be)|0,h=h+Math.imul(nt,ge)|0,h=h+Math.imul(Je,be)|0,T=T+Math.imul(Je,ge)|0,b=b+Math.imul(it,Ae)|0,h=h+Math.imul(it,qe)|0,h=h+Math.imul(ot,Ae)|0,T=T+Math.imul(ot,qe)|0,b=b+Math.imul(de,at)|0,h=h+Math.imul(de,gt)|0,h=h+Math.imul(je,at)|0,T=T+Math.imul(je,gt)|0;var Oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Oi>>>26)|0,Oi&=67108863,b=Math.imul(Ce,ut),h=Math.imul(Ce,$t),h=h+Math.imul(te,ut)|0,T=Math.imul(te,$t),b=b+Math.imul(wt,kt)|0,h=h+Math.imul(wt,Wt)|0,h=h+Math.imul(Et,kt)|0,T=T+Math.imul(Et,Wt)|0,b=b+Math.imul(Ve,Ut)|0,h=h+Math.imul(Ve,Xt)|0,h=h+Math.imul(We,Ut)|0,T=T+Math.imul(We,Xt)|0,b=b+Math.imul(rt,be)|0,h=h+Math.imul(rt,ge)|0,h=h+Math.imul(ht,be)|0,T=T+Math.imul(ht,ge)|0,b=b+Math.imul(nt,Ae)|0,h=h+Math.imul(nt,qe)|0,h=h+Math.imul(Je,Ae)|0,T=T+Math.imul(Je,qe)|0,b=b+Math.imul(it,at)|0,h=h+Math.imul(it,gt)|0,h=h+Math.imul(ot,at)|0,T=T+Math.imul(ot,gt)|0;var ki=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ki>>>26)|0,ki&=67108863,b=Math.imul(Ce,kt),h=Math.imul(Ce,Wt),h=h+Math.imul(te,kt)|0,T=Math.imul(te,Wt),b=b+Math.imul(wt,Ut)|0,h=h+Math.imul(wt,Xt)|0,h=h+Math.imul(Et,Ut)|0,T=T+Math.imul(Et,Xt)|0,b=b+Math.imul(Ve,be)|0,h=h+Math.imul(Ve,ge)|0,h=h+Math.imul(We,be)|0,T=T+Math.imul(We,ge)|0,b=b+Math.imul(rt,Ae)|0,h=h+Math.imul(rt,qe)|0,h=h+Math.imul(ht,Ae)|0,T=T+Math.imul(ht,qe)|0,b=b+Math.imul(nt,at)|0,h=h+Math.imul(nt,gt)|0,h=h+Math.imul(Je,at)|0,T=T+Math.imul(Je,gt)|0;var Ti=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ti>>>26)|0,Ti&=67108863,b=Math.imul(Ce,Ut),h=Math.imul(Ce,Xt),h=h+Math.imul(te,Ut)|0,T=Math.imul(te,Xt),b=b+Math.imul(wt,be)|0,h=h+Math.imul(wt,ge)|0,h=h+Math.imul(Et,be)|0,T=T+Math.imul(Et,ge)|0,b=b+Math.imul(Ve,Ae)|0,h=h+Math.imul(Ve,qe)|0,h=h+Math.imul(We,Ae)|0,T=T+Math.imul(We,qe)|0,b=b+Math.imul(rt,at)|0,h=h+Math.imul(rt,gt)|0,h=h+Math.imul(ht,at)|0,T=T+Math.imul(ht,gt)|0;var wi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(wi>>>26)|0,wi&=67108863,b=Math.imul(Ce,be),h=Math.imul(Ce,ge),h=h+Math.imul(te,be)|0,T=Math.imul(te,ge),b=b+Math.imul(wt,Ae)|0,h=h+Math.imul(wt,qe)|0,h=h+Math.imul(Et,Ae)|0,T=T+Math.imul(Et,qe)|0,b=b+Math.imul(Ve,at)|0,h=h+Math.imul(Ve,gt)|0,h=h+Math.imul(We,at)|0,T=T+Math.imul(We,gt)|0;var oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(oi>>>26)|0,oi&=67108863,b=Math.imul(Ce,Ae),h=Math.imul(Ce,qe),h=h+Math.imul(te,Ae)|0,T=Math.imul(te,qe),b=b+Math.imul(wt,at)|0,h=h+Math.imul(wt,gt)|0,h=h+Math.imul(Et,at)|0,T=T+Math.imul(Et,gt)|0;var zt=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zt>>>26)|0,zt&=67108863,b=Math.imul(Ce,at),h=Math.imul(Ce,gt),h=h+Math.imul(te,at)|0,T=Math.imul(te,gt);var Qt=(S+b|0)+((h&8191)<<13)|0;return S=(T+(h>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,x[0]=ei,x[1]=ii,x[2]=Bi,x[3]=hi,x[4]=Di,x[5]=ni,x[6]=pi,x[7]=Ii,x[8]=Ci,x[9]=zi,x[10]=qi,x[11]=Ai,x[12]=Oi,x[13]=ki,x[14]=Ti,x[15]=wi,x[16]=oi,x[17]=zt,x[18]=Qt,S!==0&&(x[19]=S,w.length++),w};Math.imul||(B=R);function F(L,d,v){v.negative=d.negative^L.negative,v.length=L.length+d.length;for(var w=0,c=0,p=0;p<v.length-1;p++){var x=c;c=0;for(var S=w&67108863,b=Math.min(p,d.length-1),h=Math.max(0,p-L.length+1);h<=b;h++){var T=p-h,M=L.words[T]|0,O=d.words[h]|0,V=M*O,ee=V&67108863;x=x+(V/67108864|0)|0,ee=ee+S|0,S=ee&67108863,x=x+(ee>>>26)|0,c+=x>>>26,x&=67108863}v.words[p]=S,w=x,x=c}return w!==0?v.words[p]=w:v.length--,v.strip()}function j(L,d,v){var w=new N;return w.mulp(L,d,v)}l.prototype.mulTo=function(d,v){var w,c=this.length+d.length;return this.length===10&&d.length===10?w=B(this,d,v):c<63?w=R(this,d,v):c<1024?w=F(this,d,v):w=j(this,d,v),w};function N(L,d){this.x=L,this.y=d}N.prototype.makeRBT=function(d){for(var v=new Array(d),w=l.prototype._countBits(d)-1,c=0;c<d;c++)v[c]=this.revBin(c,w,d);return v},N.prototype.revBin=function(d,v,w){if(d===0||d===w-1)return d;for(var c=0,p=0;p<v;p++)c|=(d&1)<<v-p-1,d>>=1;return c},N.prototype.permute=function(d,v,w,c,p,x){for(var S=0;S<x;S++)c[S]=v[d[S]],p[S]=w[d[S]]},N.prototype.transform=function(d,v,w,c,p,x){this.permute(x,d,v,w,c,p);for(var S=1;S<p;S<<=1)for(var b=S<<1,h=Math.cos(2*Math.PI/b),T=Math.sin(2*Math.PI/b),M=0;M<p;M+=b)for(var O=h,V=T,ee=0;ee<S;ee++){var Z=w[M+ee],U=c[M+ee],z=w[M+ee+S],ne=c[M+ee+S],fe=O*z-V*ne;ne=O*ne+V*z,z=fe,w[M+ee]=Z+z,c[M+ee]=U+ne,w[M+ee+S]=Z-z,c[M+ee+S]=U-ne,ee!==b&&(fe=h*O-T*V,V=h*V+T*O,O=fe)}},N.prototype.guessLen13b=function(d,v){var w=Math.max(v,d)|1,c=w&1,p=0;for(w=w/2|0;w;w=w>>>1)p++;return 1<<p+1+c},N.prototype.conjugate=function(d,v,w){if(!(w<=1))for(var c=0;c<w/2;c++){var p=d[c];d[c]=d[w-c-1],d[w-c-1]=p,p=v[c],v[c]=-v[w-c-1],v[w-c-1]=-p}},N.prototype.normalize13b=function(d,v){for(var w=0,c=0;c<v/2;c++){var p=Math.round(d[2*c+1]/v)*8192+Math.round(d[2*c]/v)+w;d[c]=p&67108863,p<67108864?w=0:w=p/67108864|0}return d},N.prototype.convert13b=function(d,v,w,c){for(var p=0,x=0;x<v;x++)p=p+(d[x]|0),w[2*x]=p&8191,p=p>>>13,w[2*x+1]=p&8191,p=p>>>13;for(x=2*v;x<c;++x)w[x]=0;o(p===0),o((p&-8192)===0)},N.prototype.stub=function(d){for(var v=new Array(d),w=0;w<d;w++)v[w]=0;return v},N.prototype.mulp=function(d,v,w){var c=2*this.guessLen13b(d.length,v.length),p=this.makeRBT(c),x=this.stub(c),S=new Array(c),b=new Array(c),h=new Array(c),T=new Array(c),M=new Array(c),O=new Array(c),V=w.words;V.length=c,this.convert13b(d.words,d.length,S,c),this.convert13b(v.words,v.length,T,c),this.transform(S,x,b,h,c,p),this.transform(T,x,M,O,c,p);for(var ee=0;ee<c;ee++){var Z=b[ee]*M[ee]-h[ee]*O[ee];h[ee]=b[ee]*O[ee]+h[ee]*M[ee],b[ee]=Z}return this.conjugate(b,h,c),this.transform(b,h,V,x,c,p),this.conjugate(V,x,c),this.normalize13b(V,c),w.negative=d.negative^v.negative,w.length=d.length+v.length,w.strip()},l.prototype.mul=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),this.mulTo(d,v)},l.prototype.mulf=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),j(this,d,v)},l.prototype.imul=function(d){return this.clone().mulTo(d,this)},l.prototype.imuln=function(d){o(typeof d=="number"),o(d<67108864);for(var v=0,w=0;w<this.length;w++){var c=(this.words[w]|0)*d,p=(c&67108863)+(v&67108863);v>>=26,v+=c/67108864|0,v+=p>>>26,this.words[w]=p&67108863}return v!==0&&(this.words[w]=v,this.length++),this},l.prototype.muln=function(d){return this.clone().imuln(d)},l.prototype.sqr=function(){return this.mul(this)},l.prototype.isqr=function(){return this.imul(this.clone())},l.prototype.pow=function(d){var v=P(d);if(v.length===0)return new l(1);for(var w=this,c=0;c<v.length&&v[c]===0;c++,w=w.sqr());if(++c<v.length)for(var p=w.sqr();c<v.length;c++,p=p.sqr())v[c]!==0&&(w=w.mul(p));return w},l.prototype.iushln=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=67108863>>>26-v<<26-v,p;if(v!==0){var x=0;for(p=0;p<this.length;p++){var S=this.words[p]&c,b=(this.words[p]|0)-S<<v;this.words[p]=b|x,x=S>>>26-v}x&&(this.words[p]=x,this.length++)}if(w!==0){for(p=this.length-1;p>=0;p--)this.words[p+w]=this.words[p];for(p=0;p<w;p++)this.words[p]=0;this.length+=w}return this.strip()},l.prototype.ishln=function(d){return o(this.negative===0),this.iushln(d)},l.prototype.iushrn=function(d,v,w){o(typeof d=="number"&&d>=0);var c;v?c=(v-v%26)/26:c=0;var p=d%26,x=Math.min((d-p)/26,this.length),S=67108863^67108863>>>p<<p,b=w;if(c-=x,c=Math.max(0,c),b){for(var h=0;h<x;h++)b.words[h]=this.words[h];b.length=x}if(x!==0)if(this.length>x)for(this.length-=x,h=0;h<this.length;h++)this.words[h]=this.words[h+x];else this.words[0]=0,this.length=1;var T=0;for(h=this.length-1;h>=0&&(T!==0||h>=c);h--){var M=this.words[h]|0;this.words[h]=T<<26-p|M>>>p,T=M&S}return b&&T!==0&&(b.words[b.length++]=T),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},l.prototype.ishrn=function(d,v,w){return o(this.negative===0),this.iushrn(d,v,w)},l.prototype.shln=function(d){return this.clone().ishln(d)},l.prototype.ushln=function(d){return this.clone().iushln(d)},l.prototype.shrn=function(d){return this.clone().ishrn(d)},l.prototype.ushrn=function(d){return this.clone().iushrn(d)},l.prototype.testn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return!1;var p=this.words[w];return!!(p&c)},l.prototype.imaskn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26;if(o(this.negative===0,"imaskn works only with positive numbers"),this.length<=w)return this;if(v!==0&&w++,this.length=Math.min(w,this.length),v!==0){var c=67108863^67108863>>>v<<v;this.words[this.length-1]&=c}return this.strip()},l.prototype.maskn=function(d){return this.clone().imaskn(d)},l.prototype.iaddn=function(d){return o(typeof d=="number"),o(d<67108864),d<0?this.isubn(-d):this.negative!==0?this.length===1&&(this.words[0]|0)<d?(this.words[0]=d-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(d),this.negative=1,this):this._iaddn(d)},l.prototype._iaddn=function(d){this.words[0]+=d;for(var v=0;v<this.length&&this.words[v]>=67108864;v++)this.words[v]-=67108864,v===this.length-1?this.words[v+1]=1:this.words[v+1]++;return this.length=Math.max(this.length,v+1),this},l.prototype.isubn=function(d){if(o(typeof d=="number"),o(d<67108864),d<0)return this.iaddn(-d);if(this.negative!==0)return this.negative=0,this.iaddn(d),this.negative=1,this;if(this.words[0]-=d,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var v=0;v<this.length&&this.words[v]<0;v++)this.words[v]+=67108864,this.words[v+1]-=1;return this.strip()},l.prototype.addn=function(d){return this.clone().iaddn(d)},l.prototype.subn=function(d){return this.clone().isubn(d)},l.prototype.iabs=function(){return this.negative=0,this},l.prototype.abs=function(){return this.clone().iabs()},l.prototype._ishlnsubmul=function(d,v,w){var c=d.length+w,p;this._expand(c);var x,S=0;for(p=0;p<d.length;p++){x=(this.words[p+w]|0)+S;var b=(d.words[p]|0)*v;x-=b&67108863,S=(x>>26)-(b/67108864|0),this.words[p+w]=x&67108863}for(;p<this.length-w;p++)x=(this.words[p+w]|0)+S,S=x>>26,this.words[p+w]=x&67108863;if(S===0)return this.strip();for(o(S===-1),S=0,p=0;p<this.length;p++)x=-(this.words[p]|0)+S,S=x>>26,this.words[p]=x&67108863;return this.negative=1,this.strip()},l.prototype._wordDiv=function(d,v){var w=this.length-d.length,c=this.clone(),p=d,x=p.words[p.length-1]|0,S=this._countBits(x);w=26-S,w!==0&&(p=p.ushln(w),c.iushln(w),x=p.words[p.length-1]|0);var b=c.length-p.length,h;if(v!=="mod"){h=new l(null),h.length=b+1,h.words=new Array(h.length);for(var T=0;T<h.length;T++)h.words[T]=0}var M=c.clone()._ishlnsubmul(p,1,b);M.negative===0&&(c=M,h&&(h.words[b]=1));for(var O=b-1;O>=0;O--){var V=(c.words[p.length+O]|0)*67108864+(c.words[p.length+O-1]|0);for(V=Math.min(V/x|0,67108863),c._ishlnsubmul(p,V,O);c.negative!==0;)V--,c.negative=0,c._ishlnsubmul(p,1,O),c.isZero()||(c.negative^=1);h&&(h.words[O]=V)}return h&&h.strip(),c.strip(),v!=="div"&&w!==0&&c.iushrn(w),{div:h||null,mod:c}},l.prototype.divmod=function(d,v,w){if(o(!d.isZero()),this.isZero())return{div:new l(0),mod:new l(0)};var c,p,x;return this.negative!==0&&d.negative===0?(x=this.neg().divmod(d,v),v!=="mod"&&(c=x.div.neg()),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.iadd(d)),{div:c,mod:p}):this.negative===0&&d.negative!==0?(x=this.divmod(d.neg(),v),v!=="mod"&&(c=x.div.neg()),{div:c,mod:x.mod}):this.negative&d.negative?(x=this.neg().divmod(d.neg(),v),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.isub(d)),{div:x.div,mod:p}):d.length>this.length||this.cmp(d)<0?{div:new l(0),mod:this}:d.length===1?v==="div"?{div:this.divn(d.words[0]),mod:null}:v==="mod"?{div:null,mod:new l(this.modn(d.words[0]))}:{div:this.divn(d.words[0]),mod:new l(this.modn(d.words[0]))}:this._wordDiv(d,v)},l.prototype.div=function(d){return this.divmod(d,"div",!1).div},l.prototype.mod=function(d){return this.divmod(d,"mod",!1).mod},l.prototype.umod=function(d){return this.divmod(d,"mod",!0).mod},l.prototype.divRound=function(d){var v=this.divmod(d);if(v.mod.isZero())return v.div;var w=v.div.negative!==0?v.mod.isub(d):v.mod,c=d.ushrn(1),p=d.andln(1),x=w.cmp(c);return x<0||p===1&&x===0?v.div:v.div.negative!==0?v.div.isubn(1):v.div.iaddn(1)},l.prototype.modn=function(d){o(d<=67108863);for(var v=(1<<26)%d,w=0,c=this.length-1;c>=0;c--)w=(v*w+(this.words[c]|0))%d;return w},l.prototype.idivn=function(d){o(d<=67108863);for(var v=0,w=this.length-1;w>=0;w--){var c=(this.words[w]|0)+v*67108864;this.words[w]=c/d|0,v=c%d}return this.strip()},l.prototype.divn=function(d){return this.clone().idivn(d)},l.prototype.egcd=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=new l(0),S=new l(1),b=0;v.isEven()&&w.isEven();)v.iushrn(1),w.iushrn(1),++b;for(var h=w.clone(),T=v.clone();!v.isZero();){for(var M=0,O=1;!(v.words[0]&O)&&M<26;++M,O<<=1);if(M>0)for(v.iushrn(M);M-- >0;)(c.isOdd()||p.isOdd())&&(c.iadd(h),p.isub(T)),c.iushrn(1),p.iushrn(1);for(var V=0,ee=1;!(w.words[0]&ee)&&V<26;++V,ee<<=1);if(V>0)for(w.iushrn(V);V-- >0;)(x.isOdd()||S.isOdd())&&(x.iadd(h),S.isub(T)),x.iushrn(1),S.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(x),p.isub(S)):(w.isub(v),x.isub(c),S.isub(p))}return{a:x,b:S,gcd:w.iushln(b)}},l.prototype._invmp=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=w.clone();v.cmpn(1)>0&&w.cmpn(1)>0;){for(var S=0,b=1;!(v.words[0]&b)&&S<26;++S,b<<=1);if(S>0)for(v.iushrn(S);S-- >0;)c.isOdd()&&c.iadd(x),c.iushrn(1);for(var h=0,T=1;!(w.words[0]&T)&&h<26;++h,T<<=1);if(h>0)for(w.iushrn(h);h-- >0;)p.isOdd()&&p.iadd(x),p.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(p)):(w.isub(v),p.isub(c))}var M;return v.cmpn(1)===0?M=c:M=p,M.cmpn(0)<0&&M.iadd(d),M},l.prototype.gcd=function(d){if(this.isZero())return d.abs();if(d.isZero())return this.abs();var v=this.clone(),w=d.clone();v.negative=0,w.negative=0;for(var c=0;v.isEven()&&w.isEven();c++)v.iushrn(1),w.iushrn(1);do{for(;v.isEven();)v.iushrn(1);for(;w.isEven();)w.iushrn(1);var p=v.cmp(w);if(p<0){var x=v;v=w,w=x}else if(p===0||w.cmpn(1)===0)break;v.isub(w)}while(!0);return w.iushln(c)},l.prototype.invm=function(d){return this.egcd(d).a.umod(d)},l.prototype.isEven=function(){return(this.words[0]&1)===0},l.prototype.isOdd=function(){return(this.words[0]&1)===1},l.prototype.andln=function(d){return this.words[0]&d},l.prototype.bincn=function(d){o(typeof d=="number");var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return this._expand(w+1),this.words[w]|=c,this;for(var p=c,x=w;p!==0&&x<this.length;x++){var S=this.words[x]|0;S+=p,p=S>>>26,S&=67108863,this.words[x]=S}return p!==0&&(this.words[x]=p,this.length++),this},l.prototype.isZero=function(){return this.length===1&&this.words[0]===0},l.prototype.cmpn=function(d){var v=d<0;if(this.negative!==0&&!v)return-1;if(this.negative===0&&v)return 1;this.strip();var w;if(this.length>1)w=1;else{v&&(d=-d),o(d<=67108863,"Number is too big");var c=this.words[0]|0;w=c===d?0:c<d?-1:1}return this.negative!==0?-w|0:w},l.prototype.cmp=function(d){if(this.negative!==0&&d.negative===0)return-1;if(this.negative===0&&d.negative!==0)return 1;var v=this.ucmp(d);return this.negative!==0?-v|0:v},l.prototype.ucmp=function(d){if(this.length>d.length)return 1;if(this.length<d.length)return-1;for(var v=0,w=this.length-1;w>=0;w--){var c=this.words[w]|0,p=d.words[w]|0;if(c!==p){c<p?v=-1:c>p&&(v=1);break}}return v},l.prototype.gtn=function(d){return this.cmpn(d)===1},l.prototype.gt=function(d){return this.cmp(d)===1},l.prototype.gten=function(d){return this.cmpn(d)>=0},l.prototype.gte=function(d){return this.cmp(d)>=0},l.prototype.ltn=function(d){return this.cmpn(d)===-1},l.prototype.lt=function(d){return this.cmp(d)===-1},l.prototype.lten=function(d){return this.cmpn(d)<=0},l.prototype.lte=function(d){return this.cmp(d)<=0},l.prototype.eqn=function(d){return this.cmpn(d)===0},l.prototype.eq=function(d){return this.cmp(d)===0},l.red=function(d){return new he(d)},l.prototype.toRed=function(d){return o(!this.red,"Already a number in reduction context"),o(this.negative===0,"red works only with positives"),d.convertTo(this)._forceRed(d)},l.prototype.fromRed=function(){return o(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},l.prototype._forceRed=function(d){return this.red=d,this},l.prototype.forceRed=function(d){return o(!this.red,"Already a number in reduction context"),this._forceRed(d)},l.prototype.redAdd=function(d){return o(this.red,"redAdd works only with red numbers"),this.red.add(this,d)},l.prototype.redIAdd=function(d){return o(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,d)},l.prototype.redSub=function(d){return o(this.red,"redSub works only with red numbers"),this.red.sub(this,d)},l.prototype.redISub=function(d){return o(this.red,"redISub works only with red numbers"),this.red.isub(this,d)},l.prototype.redShl=function(d){return o(this.red,"redShl works only with red numbers"),this.red.shl(this,d)},l.prototype.redMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.mul(this,d)},l.prototype.redIMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.imul(this,d)},l.prototype.redSqr=function(){return o(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},l.prototype.redISqr=function(){return o(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},l.prototype.redSqrt=function(){return o(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},l.prototype.redInvm=function(){return o(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},l.prototype.redNeg=function(){return o(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},l.prototype.redPow=function(d){return o(this.red&&!d.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,d)};var Y={k256:null,p224:null,p192:null,p25519:null};function J(L,d){this.name=L,this.p=new l(d,16),this.n=this.p.bitLength(),this.k=new l(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}J.prototype._tmp=function(){var d=new l(null);return d.words=new Array(Math.ceil(this.n/13)),d},J.prototype.ireduce=function(d){var v=d,w;do this.split(v,this.tmp),v=this.imulK(v),v=v.iadd(this.tmp),w=v.bitLength();while(w>this.n);var c=w<this.n?-1:v.ucmp(this.p);return c===0?(v.words[0]=0,v.length=1):c>0?v.isub(this.p):v.strip!==void 0?v.strip():v._strip(),v},J.prototype.split=function(d,v){d.iushrn(this.n,0,v)},J.prototype.imulK=function(d){return d.imul(this.k)};function ie(){J.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}u(ie,J),ie.prototype.split=function(d,v){for(var w=4194303,c=Math.min(d.length,9),p=0;p<c;p++)v.words[p]=d.words[p];if(v.length=c,d.length<=9){d.words[0]=0,d.length=1;return}var x=d.words[9];for(v.words[v.length++]=x&w,p=10;p<d.length;p++){var S=d.words[p]|0;d.words[p-10]=(S&w)<<4|x>>>22,x=S}x>>>=22,d.words[p-10]=x,x===0&&d.length>10?d.length-=10:d.length-=9},ie.prototype.imulK=function(d){d.words[d.length]=0,d.words[d.length+1]=0,d.length+=2;for(var v=0,w=0;w<d.length;w++){var c=d.words[w]|0;v+=c*977,d.words[w]=v&67108863,v=c*64+(v/67108864|0)}return d.words[d.length-1]===0&&(d.length--,d.words[d.length-1]===0&&d.length--),d};function ue(){J.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}u(ue,J);function Q(){J.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}u(Q,J);function ce(){J.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}u(ce,J),ce.prototype.imulK=function(d){for(var v=0,w=0;w<d.length;w++){var c=(d.words[w]|0)*19+v,p=c&67108863;c>>>=26,d.words[w]=p,v=c}return v!==0&&(d.words[d.length++]=v),d},l._prime=function(d){if(Y[d])return Y[d];var v;if(d==="k256")v=new ie;else if(d==="p224")v=new ue;else if(d==="p192")v=new Q;else if(d==="p25519")v=new ce;else throw new Error("Unknown prime "+d);return Y[d]=v,v};function he(L){if(typeof L=="string"){var d=l._prime(L);this.m=d.p,this.prime=d}else o(L.gtn(1),"modulus must be greater than 1"),this.m=L,this.prime=null}he.prototype._verify1=function(d){o(d.negative===0,"red works only with positives"),o(d.red,"red works only with red numbers")},he.prototype._verify2=function(d,v){o((d.negative|v.negative)===0,"red works only with positives"),o(d.red&&d.red===v.red,"red works only with red numbers")},he.prototype.imod=function(d){return this.prime?this.prime.ireduce(d)._forceRed(this):d.umod(this.m)._forceRed(this)},he.prototype.neg=function(d){return d.isZero()?d.clone():this.m.sub(d)._forceRed(this)},he.prototype.add=function(d,v){this._verify2(d,v);var w=d.add(v);return w.cmp(this.m)>=0&&w.isub(this.m),w._forceRed(this)},he.prototype.iadd=function(d,v){this._verify2(d,v);var w=d.iadd(v);return w.cmp(this.m)>=0&&w.isub(this.m),w},he.prototype.sub=function(d,v){this._verify2(d,v);var w=d.sub(v);return w.cmpn(0)<0&&w.iadd(this.m),w._forceRed(this)},he.prototype.isub=function(d,v){this._verify2(d,v);var w=d.isub(v);return w.cmpn(0)<0&&w.iadd(this.m),w},he.prototype.shl=function(d,v){return this._verify1(d),this.imod(d.ushln(v))},he.prototype.imul=function(d,v){return this._verify2(d,v),this.imod(d.imul(v))},he.prototype.mul=function(d,v){return this._verify2(d,v),this.imod(d.mul(v))},he.prototype.isqr=function(d){return this.imul(d,d.clone())},he.prototype.sqr=function(d){return this.mul(d,d)},he.prototype.sqrt=function(d){if(d.isZero())return d.clone();var v=this.m.andln(3);if(o(v%2===1),v===3){var w=this.m.add(new l(1)).iushrn(2);return this.pow(d,w)}for(var c=this.m.subn(1),p=0;!c.isZero()&&c.andln(1)===0;)p++,c.iushrn(1);o(!c.isZero());var x=new l(1).toRed(this),S=x.redNeg(),b=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new l(2*h*h).toRed(this);this.pow(h,b).cmp(S)!==0;)h.redIAdd(S);for(var T=this.pow(h,c),M=this.pow(d,c.addn(1).iushrn(1)),O=this.pow(d,c),V=p;O.cmp(x)!==0;){for(var ee=O,Z=0;ee.cmp(x)!==0;Z++)ee=ee.redSqr();o(Z<V);var U=this.pow(T,new l(1).iushln(V-Z-1));M=M.redMul(U),T=U.redSqr(),O=O.redMul(T),V=Z}return M},he.prototype.invm=function(d){var v=d._invmp(this.m);return v.negative!==0?(v.negative=0,this.imod(v).redNeg()):this.imod(v)},he.prototype.pow=function(d,v){if(v.isZero())return new l(1).toRed(this);if(v.cmpn(1)===0)return d.clone();var w=4,c=new Array(1<<w);c[0]=new l(1).toRed(this),c[1]=d;for(var p=2;p<c.length;p++)c[p]=this.mul(c[p-1],d);var x=c[0],S=0,b=0,h=v.bitLength()%26;for(h===0&&(h=26),p=v.length-1;p>=0;p--){for(var T=v.words[p],M=h-1;M>=0;M--){var O=T>>M&1;if(x!==c[0]&&(x=this.sqr(x)),O===0&&S===0){b=0;continue}S<<=1,S|=O,b++,!(b!==w&&(p!==0||M!==0))&&(x=this.mul(x,c[S]),b=0,S=0)}h=26}return x},he.prototype.convertTo=function(d){var v=d.umod(this.m);return v===d?v.clone():v},he.prototype.convertFrom=function(d){var v=d.clone();return v.red=null,v},l.mont=function(d){return new ke(d)};function ke(L){he.call(this,L),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new l(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}u(ke,he),ke.prototype.convertTo=function(d){return this.imod(d.ushln(this.shift))},ke.prototype.convertFrom=function(d){var v=this.imod(d.mul(this.rinv));return v.red=null,v},ke.prototype.imul=function(d,v){if(d.isZero()||v.isZero())return d.words[0]=0,d.length=1,d;var w=d.imul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.mul=function(d,v){if(d.isZero()||v.isZero())return new l(0)._forceRed(this);var w=d.mul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.invm=function(d){var v=this.imod(d._invmp(this.m).mul(this.r2));return v._forceRed(this)}})(t,commonjsGlobal$1)}(bn$6);var bnExports$6=bn$6.exports,bn$5={exports:{}};bn$5.exports,function(t){(function(e,n){function o(L,d){if(!L)throw new Error(d||"Assertion failed")}function u(L,d){L.super_=d;var v=function(){};v.prototype=d.prototype,L.prototype=new v,L.prototype.constructor=L}function l(L,d,v){if(l.isBN(L))return L;this.negative=0,this.words=null,this.length=0,this.red=null,L!==null&&((d==="le"||d==="be")&&(v=d,d=10),this._init(L||0,d||10,v||"be"))}typeof e=="object"?e.exports=l:n.BN=l,l.BN=l,l.wordSize=26;var m;try{typeof window<"u"&&typeof window.Buffer<"u"?m=window.Buffer:m=require$$0$2.Buffer}catch{}l.isBN=function(d){return d instanceof l?!0:d!==null&&typeof d=="object"&&d.constructor.wordSize===l.wordSize&&Array.isArray(d.words)},l.max=function(d,v){return d.cmp(v)>0?d:v},l.min=function(d,v){return d.cmp(v)<0?d:v},l.prototype._init=function(d,v,w){if(typeof d=="number")return this._initNumber(d,v,w);if(typeof d=="object")return this._initArray(d,v,w);v==="hex"&&(v=16),o(v===(v|0)&&v>=2&&v<=36),d=d.toString().replace(/\s+/g,"");var c=0;d[0]==="-"&&(c++,this.negative=1),c<d.length&&(v===16?this._parseHex(d,c,w):(this._parseBase(d,v,c),w==="le"&&this._initArray(this.toArray(),v,w)))},l.prototype._initNumber=function(d,v,w){d<0&&(this.negative=1,d=-d),d<67108864?(this.words=[d&67108863],this.length=1):d<4503599627370496?(this.words=[d&67108863,d/67108864&67108863],this.length=2):(o(d<9007199254740992),this.words=[d&67108863,d/67108864&67108863,1],this.length=3),w==="le"&&this._initArray(this.toArray(),v,w)},l.prototype._initArray=function(d,v,w){if(o(typeof d.length=="number"),d.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(d.length/3),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p,x,S=0;if(w==="be")for(c=d.length-1,p=0;c>=0;c-=3)x=d[c]|d[c-1]<<8|d[c-2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);else if(w==="le")for(c=0,p=0;c<d.length;c+=3)x=d[c]|d[c+1]<<8|d[c+2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);return this.strip()};function y(L,d){var v=L.charCodeAt(d);return v>=65&&v<=70?v-55:v>=97&&v<=102?v-87:v-48&15}function E(L,d,v){var w=y(L,v);return v-1>=d&&(w|=y(L,v-1)<<4),w}l.prototype._parseHex=function(d,v,w){this.length=Math.ceil((d.length-v)/6),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p=0,x=0,S;if(w==="be")for(c=d.length-1;c>=v;c-=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8;else{var b=d.length-v;for(c=b%2===0?v+1:v;c<d.length;c+=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8}this.strip()};function C(L,d,v,w){for(var c=0,p=Math.min(L.length,v),x=d;x<p;x++){var S=L.charCodeAt(x)-48;c*=w,S>=49?c+=S-49+10:S>=17?c+=S-17+10:c+=S}return c}l.prototype._parseBase=function(d,v,w){this.words=[0],this.length=1;for(var c=0,p=1;p<=67108863;p*=v)c++;c--,p=p/v|0;for(var x=d.length-w,S=x%c,b=Math.min(x,x-S)+w,h=0,T=w;T<b;T+=c)h=C(d,T,T+c,v),this.imuln(p),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h);if(S!==0){var M=1;for(h=C(d,T,d.length,v),T=0;T<S;T++)M*=v;this.imuln(M),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h)}this.strip()},l.prototype.copy=function(d){d.words=new Array(this.length);for(var v=0;v<this.length;v++)d.words[v]=this.words[v];d.length=this.length,d.negative=this.negative,d.red=this.red},l.prototype.clone=function(){var d=new l(null);return this.copy(d),d},l.prototype._expand=function(d){for(;this.length<d;)this.words[this.length++]=0;return this},l.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},l.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},l.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var k=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],D=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];l.prototype.toString=function(d,v){d=d||10,v=v|0||1;var w;if(d===16||d==="hex"){w="";for(var c=0,p=0,x=0;x<this.length;x++){var S=this.words[x],b=((S<<c|p)&16777215).toString(16);p=S>>>24-c&16777215,p!==0||x!==this.length-1?w=k[6-b.length]+b+w:w=b+w,c+=2,c>=26&&(c-=26,x--)}for(p!==0&&(w=p.toString(16)+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}if(d===(d|0)&&d>=2&&d<=36){var h=A[d],T=D[d];w="";var M=this.clone();for(M.negative=0;!M.isZero();){var O=M.modn(T).toString(d);M=M.idivn(T),M.isZero()?w=O+w:w=k[h-O.length]+O+w}for(this.isZero()&&(w="0"+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}o(!1,"Base should be between 2 and 36")},l.prototype.toNumber=function(){var d=this.words[0];return this.length===2?d+=this.words[1]*67108864:this.length===3&&this.words[2]===1?d+=4503599627370496+this.words[1]*67108864:this.length>2&&o(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-d:d},l.prototype.toJSON=function(){return this.toString(16)},l.prototype.toBuffer=function(d,v){return o(typeof m<"u"),this.toArrayLike(m,d,v)},l.prototype.toArray=function(d,v){return this.toArrayLike(Array,d,v)},l.prototype.toArrayLike=function(d,v,w){var c=this.byteLength(),p=w||Math.max(1,c);o(c<=p,"byte array longer than desired length"),o(p>0,"Requested array length <= 0"),this.strip();var x=v==="le",S=new d(p),b,h,T=this.clone();if(x){for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[h]=b;for(;h<p;h++)S[h]=0}else{for(h=0;h<p-c;h++)S[h]=0;for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[p-h-1]=b}return S},Math.clz32?l.prototype._countBits=function(d){return 32-Math.clz32(d)}:l.prototype._countBits=function(d){var v=d,w=0;return v>=4096&&(w+=13,v>>>=13),v>=64&&(w+=7,v>>>=7),v>=8&&(w+=4,v>>>=4),v>=2&&(w+=2,v>>>=2),w+v},l.prototype._zeroBits=function(d){if(d===0)return 26;var v=d,w=0;return v&8191||(w+=13,v>>>=13),v&127||(w+=7,v>>>=7),v&15||(w+=4,v>>>=4),v&3||(w+=2,v>>>=2),v&1||w++,w},l.prototype.bitLength=function(){var d=this.words[this.length-1],v=this._countBits(d);return(this.length-1)*26+v};function P(L){for(var d=new Array(L.bitLength()),v=0;v<d.length;v++){var w=v/26|0,c=v%26;d[v]=(L.words[w]&1<<c)>>>c}return d}l.prototype.zeroBits=function(){if(this.isZero())return 0;for(var d=0,v=0;v<this.length;v++){var w=this._zeroBits(this.words[v]);if(d+=w,w!==26)break}return d},l.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},l.prototype.toTwos=function(d){return this.negative!==0?this.abs().inotn(d).iaddn(1):this.clone()},l.prototype.fromTwos=function(d){return this.testn(d-1)?this.notn(d).iaddn(1).ineg():this.clone()},l.prototype.isNeg=function(){return this.negative!==0},l.prototype.neg=function(){return this.clone().ineg()},l.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},l.prototype.iuor=function(d){for(;this.length<d.length;)this.words[this.length++]=0;for(var v=0;v<d.length;v++)this.words[v]=this.words[v]|d.words[v];return this.strip()},l.prototype.ior=function(d){return o((this.negative|d.negative)===0),this.iuor(d)},l.prototype.or=function(d){return this.length>d.length?this.clone().ior(d):d.clone().ior(this)},l.prototype.uor=function(d){return this.length>d.length?this.clone().iuor(d):d.clone().iuor(this)},l.prototype.iuand=function(d){var v;this.length>d.length?v=d:v=this;for(var w=0;w<v.length;w++)this.words[w]=this.words[w]&d.words[w];return this.length=v.length,this.strip()},l.prototype.iand=function(d){return o((this.negative|d.negative)===0),this.iuand(d)},l.prototype.and=function(d){return this.length>d.length?this.clone().iand(d):d.clone().iand(this)},l.prototype.uand=function(d){return this.length>d.length?this.clone().iuand(d):d.clone().iuand(this)},l.prototype.iuxor=function(d){var v,w;this.length>d.length?(v=this,w=d):(v=d,w=this);for(var c=0;c<w.length;c++)this.words[c]=v.words[c]^w.words[c];if(this!==v)for(;c<v.length;c++)this.words[c]=v.words[c];return this.length=v.length,this.strip()},l.prototype.ixor=function(d){return o((this.negative|d.negative)===0),this.iuxor(d)},l.prototype.xor=function(d){return this.length>d.length?this.clone().ixor(d):d.clone().ixor(this)},l.prototype.uxor=function(d){return this.length>d.length?this.clone().iuxor(d):d.clone().iuxor(this)},l.prototype.inotn=function(d){o(typeof d=="number"&&d>=0);var v=Math.ceil(d/26)|0,w=d%26;this._expand(v),w>0&&v--;for(var c=0;c<v;c++)this.words[c]=~this.words[c]&67108863;return w>0&&(this.words[c]=~this.words[c]&67108863>>26-w),this.strip()},l.prototype.notn=function(d){return this.clone().inotn(d)},l.prototype.setn=function(d,v){o(typeof d=="number"&&d>=0);var w=d/26|0,c=d%26;return this._expand(w+1),v?this.words[w]=this.words[w]|1<<c:this.words[w]=this.words[w]&~(1<<c),this.strip()},l.prototype.iadd=function(d){var v;if(this.negative!==0&&d.negative===0)return this.negative=0,v=this.isub(d),this.negative^=1,this._normSign();if(this.negative===0&&d.negative!==0)return d.negative=0,v=this.isub(d),d.negative=1,v._normSign();var w,c;this.length>d.length?(w=this,c=d):(w=d,c=this);for(var p=0,x=0;x<c.length;x++)v=(w.words[x]|0)+(c.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;for(;p!==0&&x<w.length;x++)v=(w.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;if(this.length=w.length,p!==0)this.words[this.length]=p,this.length++;else if(w!==this)for(;x<w.length;x++)this.words[x]=w.words[x];return this},l.prototype.add=function(d){var v;return d.negative!==0&&this.negative===0?(d.negative=0,v=this.sub(d),d.negative^=1,v):d.negative===0&&this.negative!==0?(this.negative=0,v=d.sub(this),this.negative=1,v):this.length>d.length?this.clone().iadd(d):d.clone().iadd(this)},l.prototype.isub=function(d){if(d.negative!==0){d.negative=0;var v=this.iadd(d);return d.negative=1,v._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(d),this.negative=1,this._normSign();var w=this.cmp(d);if(w===0)return this.negative=0,this.length=1,this.words[0]=0,this;var c,p;w>0?(c=this,p=d):(c=d,p=this);for(var x=0,S=0;S<p.length;S++)v=(c.words[S]|0)-(p.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;for(;x!==0&&S<c.length;S++)v=(c.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;if(x===0&&S<c.length&&c!==this)for(;S<c.length;S++)this.words[S]=c.words[S];return this.length=Math.max(this.length,S),c!==this&&(this.negative=1),this.strip()},l.prototype.sub=function(d){return this.clone().isub(d)};function R(L,d,v){v.negative=d.negative^L.negative;var w=L.length+d.length|0;v.length=w,w=w-1|0;var c=L.words[0]|0,p=d.words[0]|0,x=c*p,S=x&67108863,b=x/67108864|0;v.words[0]=S;for(var h=1;h<w;h++){for(var T=b>>>26,M=b&67108863,O=Math.min(h,d.length-1),V=Math.max(0,h-L.length+1);V<=O;V++){var ee=h-V|0;c=L.words[ee]|0,p=d.words[V]|0,x=c*p+M,T+=x/67108864|0,M=x&67108863}v.words[h]=M|0,b=T|0}return b!==0?v.words[h]=b|0:v.length--,v.strip()}var B=function(d,v,w){var c=d.words,p=v.words,x=w.words,S=0,b,h,T,M=c[0]|0,O=M&8191,V=M>>>13,ee=c[1]|0,Z=ee&8191,U=ee>>>13,z=c[2]|0,ne=z&8191,fe=z>>>13,me=c[3]|0,de=me&8191,je=me>>>13,lt=c[4]|0,it=lt&8191,ot=lt>>>13,Ct=c[5]|0,nt=Ct&8191,Je=Ct>>>13,tt=c[6]|0,rt=tt&8191,ht=tt>>>13,Ot=c[7]|0,Ve=Ot&8191,We=Ot>>>13,Gt=c[8]|0,wt=Gt&8191,Et=Gt>>>13,Yt=c[9]|0,Ce=Yt&8191,te=Yt>>>13,ye=p[0]|0,Le=ye&8191,Ue=ye>>>13,Qe=p[1]|0,Ke=Qe&8191,De=Qe>>>13,Vt=p[2]|0,At=Vt&8191,ve=Vt>>>13,Pt=p[3]|0,pt=Pt&8191,Ne=Pt>>>13,vt=p[4]|0,ut=vt&8191,$t=vt>>>13,fi=p[5]|0,kt=fi&8191,Wt=fi>>>13,Zi=p[6]|0,Ut=Zi&8191,Xt=Zi>>>13,Be=p[7]|0,be=Be&8191,ge=Be>>>13,oe=p[8]|0,Ae=oe&8191,qe=oe>>>13,bt=p[9]|0,at=bt&8191,gt=bt>>>13;w.negative=d.negative^v.negative,w.length=19,b=Math.imul(O,Le),h=Math.imul(O,Ue),h=h+Math.imul(V,Le)|0,T=Math.imul(V,Ue);var ei=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ei>>>26)|0,ei&=67108863,b=Math.imul(Z,Le),h=Math.imul(Z,Ue),h=h+Math.imul(U,Le)|0,T=Math.imul(U,Ue),b=b+Math.imul(O,Ke)|0,h=h+Math.imul(O,De)|0,h=h+Math.imul(V,Ke)|0,T=T+Math.imul(V,De)|0;var ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ii>>>26)|0,ii&=67108863,b=Math.imul(ne,Le),h=Math.imul(ne,Ue),h=h+Math.imul(fe,Le)|0,T=Math.imul(fe,Ue),b=b+Math.imul(Z,Ke)|0,h=h+Math.imul(Z,De)|0,h=h+Math.imul(U,Ke)|0,T=T+Math.imul(U,De)|0,b=b+Math.imul(O,At)|0,h=h+Math.imul(O,ve)|0,h=h+Math.imul(V,At)|0,T=T+Math.imul(V,ve)|0;var Bi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Bi>>>26)|0,Bi&=67108863,b=Math.imul(de,Le),h=Math.imul(de,Ue),h=h+Math.imul(je,Le)|0,T=Math.imul(je,Ue),b=b+Math.imul(ne,Ke)|0,h=h+Math.imul(ne,De)|0,h=h+Math.imul(fe,Ke)|0,T=T+Math.imul(fe,De)|0,b=b+Math.imul(Z,At)|0,h=h+Math.imul(Z,ve)|0,h=h+Math.imul(U,At)|0,T=T+Math.imul(U,ve)|0,b=b+Math.imul(O,pt)|0,h=h+Math.imul(O,Ne)|0,h=h+Math.imul(V,pt)|0,T=T+Math.imul(V,Ne)|0;var hi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(hi>>>26)|0,hi&=67108863,b=Math.imul(it,Le),h=Math.imul(it,Ue),h=h+Math.imul(ot,Le)|0,T=Math.imul(ot,Ue),b=b+Math.imul(de,Ke)|0,h=h+Math.imul(de,De)|0,h=h+Math.imul(je,Ke)|0,T=T+Math.imul(je,De)|0,b=b+Math.imul(ne,At)|0,h=h+Math.imul(ne,ve)|0,h=h+Math.imul(fe,At)|0,T=T+Math.imul(fe,ve)|0,b=b+Math.imul(Z,pt)|0,h=h+Math.imul(Z,Ne)|0,h=h+Math.imul(U,pt)|0,T=T+Math.imul(U,Ne)|0,b=b+Math.imul(O,ut)|0,h=h+Math.imul(O,$t)|0,h=h+Math.imul(V,ut)|0,T=T+Math.imul(V,$t)|0;var Di=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Di>>>26)|0,Di&=67108863,b=Math.imul(nt,Le),h=Math.imul(nt,Ue),h=h+Math.imul(Je,Le)|0,T=Math.imul(Je,Ue),b=b+Math.imul(it,Ke)|0,h=h+Math.imul(it,De)|0,h=h+Math.imul(ot,Ke)|0,T=T+Math.imul(ot,De)|0,b=b+Math.imul(de,At)|0,h=h+Math.imul(de,ve)|0,h=h+Math.imul(je,At)|0,T=T+Math.imul(je,ve)|0,b=b+Math.imul(ne,pt)|0,h=h+Math.imul(ne,Ne)|0,h=h+Math.imul(fe,pt)|0,T=T+Math.imul(fe,Ne)|0,b=b+Math.imul(Z,ut)|0,h=h+Math.imul(Z,$t)|0,h=h+Math.imul(U,ut)|0,T=T+Math.imul(U,$t)|0,b=b+Math.imul(O,kt)|0,h=h+Math.imul(O,Wt)|0,h=h+Math.imul(V,kt)|0,T=T+Math.imul(V,Wt)|0;var ni=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ni>>>26)|0,ni&=67108863,b=Math.imul(rt,Le),h=Math.imul(rt,Ue),h=h+Math.imul(ht,Le)|0,T=Math.imul(ht,Ue),b=b+Math.imul(nt,Ke)|0,h=h+Math.imul(nt,De)|0,h=h+Math.imul(Je,Ke)|0,T=T+Math.imul(Je,De)|0,b=b+Math.imul(it,At)|0,h=h+Math.imul(it,ve)|0,h=h+Math.imul(ot,At)|0,T=T+Math.imul(ot,ve)|0,b=b+Math.imul(de,pt)|0,h=h+Math.imul(de,Ne)|0,h=h+Math.imul(je,pt)|0,T=T+Math.imul(je,Ne)|0,b=b+Math.imul(ne,ut)|0,h=h+Math.imul(ne,$t)|0,h=h+Math.imul(fe,ut)|0,T=T+Math.imul(fe,$t)|0,b=b+Math.imul(Z,kt)|0,h=h+Math.imul(Z,Wt)|0,h=h+Math.imul(U,kt)|0,T=T+Math.imul(U,Wt)|0,b=b+Math.imul(O,Ut)|0,h=h+Math.imul(O,Xt)|0,h=h+Math.imul(V,Ut)|0,T=T+Math.imul(V,Xt)|0;var pi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(pi>>>26)|0,pi&=67108863,b=Math.imul(Ve,Le),h=Math.imul(Ve,Ue),h=h+Math.imul(We,Le)|0,T=Math.imul(We,Ue),b=b+Math.imul(rt,Ke)|0,h=h+Math.imul(rt,De)|0,h=h+Math.imul(ht,Ke)|0,T=T+Math.imul(ht,De)|0,b=b+Math.imul(nt,At)|0,h=h+Math.imul(nt,ve)|0,h=h+Math.imul(Je,At)|0,T=T+Math.imul(Je,ve)|0,b=b+Math.imul(it,pt)|0,h=h+Math.imul(it,Ne)|0,h=h+Math.imul(ot,pt)|0,T=T+Math.imul(ot,Ne)|0,b=b+Math.imul(de,ut)|0,h=h+Math.imul(de,$t)|0,h=h+Math.imul(je,ut)|0,T=T+Math.imul(je,$t)|0,b=b+Math.imul(ne,kt)|0,h=h+Math.imul(ne,Wt)|0,h=h+Math.imul(fe,kt)|0,T=T+Math.imul(fe,Wt)|0,b=b+Math.imul(Z,Ut)|0,h=h+Math.imul(Z,Xt)|0,h=h+Math.imul(U,Ut)|0,T=T+Math.imul(U,Xt)|0,b=b+Math.imul(O,be)|0,h=h+Math.imul(O,ge)|0,h=h+Math.imul(V,be)|0,T=T+Math.imul(V,ge)|0;var Ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ii>>>26)|0,Ii&=67108863,b=Math.imul(wt,Le),h=Math.imul(wt,Ue),h=h+Math.imul(Et,Le)|0,T=Math.imul(Et,Ue),b=b+Math.imul(Ve,Ke)|0,h=h+Math.imul(Ve,De)|0,h=h+Math.imul(We,Ke)|0,T=T+Math.imul(We,De)|0,b=b+Math.imul(rt,At)|0,h=h+Math.imul(rt,ve)|0,h=h+Math.imul(ht,At)|0,T=T+Math.imul(ht,ve)|0,b=b+Math.imul(nt,pt)|0,h=h+Math.imul(nt,Ne)|0,h=h+Math.imul(Je,pt)|0,T=T+Math.imul(Je,Ne)|0,b=b+Math.imul(it,ut)|0,h=h+Math.imul(it,$t)|0,h=h+Math.imul(ot,ut)|0,T=T+Math.imul(ot,$t)|0,b=b+Math.imul(de,kt)|0,h=h+Math.imul(de,Wt)|0,h=h+Math.imul(je,kt)|0,T=T+Math.imul(je,Wt)|0,b=b+Math.imul(ne,Ut)|0,h=h+Math.imul(ne,Xt)|0,h=h+Math.imul(fe,Ut)|0,T=T+Math.imul(fe,Xt)|0,b=b+Math.imul(Z,be)|0,h=h+Math.imul(Z,ge)|0,h=h+Math.imul(U,be)|0,T=T+Math.imul(U,ge)|0,b=b+Math.imul(O,Ae)|0,h=h+Math.imul(O,qe)|0,h=h+Math.imul(V,Ae)|0,T=T+Math.imul(V,qe)|0;var Ci=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ci>>>26)|0,Ci&=67108863,b=Math.imul(Ce,Le),h=Math.imul(Ce,Ue),h=h+Math.imul(te,Le)|0,T=Math.imul(te,Ue),b=b+Math.imul(wt,Ke)|0,h=h+Math.imul(wt,De)|0,h=h+Math.imul(Et,Ke)|0,T=T+Math.imul(Et,De)|0,b=b+Math.imul(Ve,At)|0,h=h+Math.imul(Ve,ve)|0,h=h+Math.imul(We,At)|0,T=T+Math.imul(We,ve)|0,b=b+Math.imul(rt,pt)|0,h=h+Math.imul(rt,Ne)|0,h=h+Math.imul(ht,pt)|0,T=T+Math.imul(ht,Ne)|0,b=b+Math.imul(nt,ut)|0,h=h+Math.imul(nt,$t)|0,h=h+Math.imul(Je,ut)|0,T=T+Math.imul(Je,$t)|0,b=b+Math.imul(it,kt)|0,h=h+Math.imul(it,Wt)|0,h=h+Math.imul(ot,kt)|0,T=T+Math.imul(ot,Wt)|0,b=b+Math.imul(de,Ut)|0,h=h+Math.imul(de,Xt)|0,h=h+Math.imul(je,Ut)|0,T=T+Math.imul(je,Xt)|0,b=b+Math.imul(ne,be)|0,h=h+Math.imul(ne,ge)|0,h=h+Math.imul(fe,be)|0,T=T+Math.imul(fe,ge)|0,b=b+Math.imul(Z,Ae)|0,h=h+Math.imul(Z,qe)|0,h=h+Math.imul(U,Ae)|0,T=T+Math.imul(U,qe)|0,b=b+Math.imul(O,at)|0,h=h+Math.imul(O,gt)|0,h=h+Math.imul(V,at)|0,T=T+Math.imul(V,gt)|0;var zi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zi>>>26)|0,zi&=67108863,b=Math.imul(Ce,Ke),h=Math.imul(Ce,De),h=h+Math.imul(te,Ke)|0,T=Math.imul(te,De),b=b+Math.imul(wt,At)|0,h=h+Math.imul(wt,ve)|0,h=h+Math.imul(Et,At)|0,T=T+Math.imul(Et,ve)|0,b=b+Math.imul(Ve,pt)|0,h=h+Math.imul(Ve,Ne)|0,h=h+Math.imul(We,pt)|0,T=T+Math.imul(We,Ne)|0,b=b+Math.imul(rt,ut)|0,h=h+Math.imul(rt,$t)|0,h=h+Math.imul(ht,ut)|0,T=T+Math.imul(ht,$t)|0,b=b+Math.imul(nt,kt)|0,h=h+Math.imul(nt,Wt)|0,h=h+Math.imul(Je,kt)|0,T=T+Math.imul(Je,Wt)|0,b=b+Math.imul(it,Ut)|0,h=h+Math.imul(it,Xt)|0,h=h+Math.imul(ot,Ut)|0,T=T+Math.imul(ot,Xt)|0,b=b+Math.imul(de,be)|0,h=h+Math.imul(de,ge)|0,h=h+Math.imul(je,be)|0,T=T+Math.imul(je,ge)|0,b=b+Math.imul(ne,Ae)|0,h=h+Math.imul(ne,qe)|0,h=h+Math.imul(fe,Ae)|0,T=T+Math.imul(fe,qe)|0,b=b+Math.imul(Z,at)|0,h=h+Math.imul(Z,gt)|0,h=h+Math.imul(U,at)|0,T=T+Math.imul(U,gt)|0;var qi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(qi>>>26)|0,qi&=67108863,b=Math.imul(Ce,At),h=Math.imul(Ce,ve),h=h+Math.imul(te,At)|0,T=Math.imul(te,ve),b=b+Math.imul(wt,pt)|0,h=h+Math.imul(wt,Ne)|0,h=h+Math.imul(Et,pt)|0,T=T+Math.imul(Et,Ne)|0,b=b+Math.imul(Ve,ut)|0,h=h+Math.imul(Ve,$t)|0,h=h+Math.imul(We,ut)|0,T=T+Math.imul(We,$t)|0,b=b+Math.imul(rt,kt)|0,h=h+Math.imul(rt,Wt)|0,h=h+Math.imul(ht,kt)|0,T=T+Math.imul(ht,Wt)|0,b=b+Math.imul(nt,Ut)|0,h=h+Math.imul(nt,Xt)|0,h=h+Math.imul(Je,Ut)|0,T=T+Math.imul(Je,Xt)|0,b=b+Math.imul(it,be)|0,h=h+Math.imul(it,ge)|0,h=h+Math.imul(ot,be)|0,T=T+Math.imul(ot,ge)|0,b=b+Math.imul(de,Ae)|0,h=h+Math.imul(de,qe)|0,h=h+Math.imul(je,Ae)|0,T=T+Math.imul(je,qe)|0,b=b+Math.imul(ne,at)|0,h=h+Math.imul(ne,gt)|0,h=h+Math.imul(fe,at)|0,T=T+Math.imul(fe,gt)|0;var Ai=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ai>>>26)|0,Ai&=67108863,b=Math.imul(Ce,pt),h=Math.imul(Ce,Ne),h=h+Math.imul(te,pt)|0,T=Math.imul(te,Ne),b=b+Math.imul(wt,ut)|0,h=h+Math.imul(wt,$t)|0,h=h+Math.imul(Et,ut)|0,T=T+Math.imul(Et,$t)|0,b=b+Math.imul(Ve,kt)|0,h=h+Math.imul(Ve,Wt)|0,h=h+Math.imul(We,kt)|0,T=T+Math.imul(We,Wt)|0,b=b+Math.imul(rt,Ut)|0,h=h+Math.imul(rt,Xt)|0,h=h+Math.imul(ht,Ut)|0,T=T+Math.imul(ht,Xt)|0,b=b+Math.imul(nt,be)|0,h=h+Math.imul(nt,ge)|0,h=h+Math.imul(Je,be)|0,T=T+Math.imul(Je,ge)|0,b=b+Math.imul(it,Ae)|0,h=h+Math.imul(it,qe)|0,h=h+Math.imul(ot,Ae)|0,T=T+Math.imul(ot,qe)|0,b=b+Math.imul(de,at)|0,h=h+Math.imul(de,gt)|0,h=h+Math.imul(je,at)|0,T=T+Math.imul(je,gt)|0;var Oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Oi>>>26)|0,Oi&=67108863,b=Math.imul(Ce,ut),h=Math.imul(Ce,$t),h=h+Math.imul(te,ut)|0,T=Math.imul(te,$t),b=b+Math.imul(wt,kt)|0,h=h+Math.imul(wt,Wt)|0,h=h+Math.imul(Et,kt)|0,T=T+Math.imul(Et,Wt)|0,b=b+Math.imul(Ve,Ut)|0,h=h+Math.imul(Ve,Xt)|0,h=h+Math.imul(We,Ut)|0,T=T+Math.imul(We,Xt)|0,b=b+Math.imul(rt,be)|0,h=h+Math.imul(rt,ge)|0,h=h+Math.imul(ht,be)|0,T=T+Math.imul(ht,ge)|0,b=b+Math.imul(nt,Ae)|0,h=h+Math.imul(nt,qe)|0,h=h+Math.imul(Je,Ae)|0,T=T+Math.imul(Je,qe)|0,b=b+Math.imul(it,at)|0,h=h+Math.imul(it,gt)|0,h=h+Math.imul(ot,at)|0,T=T+Math.imul(ot,gt)|0;var ki=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ki>>>26)|0,ki&=67108863,b=Math.imul(Ce,kt),h=Math.imul(Ce,Wt),h=h+Math.imul(te,kt)|0,T=Math.imul(te,Wt),b=b+Math.imul(wt,Ut)|0,h=h+Math.imul(wt,Xt)|0,h=h+Math.imul(Et,Ut)|0,T=T+Math.imul(Et,Xt)|0,b=b+Math.imul(Ve,be)|0,h=h+Math.imul(Ve,ge)|0,h=h+Math.imul(We,be)|0,T=T+Math.imul(We,ge)|0,b=b+Math.imul(rt,Ae)|0,h=h+Math.imul(rt,qe)|0,h=h+Math.imul(ht,Ae)|0,T=T+Math.imul(ht,qe)|0,b=b+Math.imul(nt,at)|0,h=h+Math.imul(nt,gt)|0,h=h+Math.imul(Je,at)|0,T=T+Math.imul(Je,gt)|0;var Ti=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ti>>>26)|0,Ti&=67108863,b=Math.imul(Ce,Ut),h=Math.imul(Ce,Xt),h=h+Math.imul(te,Ut)|0,T=Math.imul(te,Xt),b=b+Math.imul(wt,be)|0,h=h+Math.imul(wt,ge)|0,h=h+Math.imul(Et,be)|0,T=T+Math.imul(Et,ge)|0,b=b+Math.imul(Ve,Ae)|0,h=h+Math.imul(Ve,qe)|0,h=h+Math.imul(We,Ae)|0,T=T+Math.imul(We,qe)|0,b=b+Math.imul(rt,at)|0,h=h+Math.imul(rt,gt)|0,h=h+Math.imul(ht,at)|0,T=T+Math.imul(ht,gt)|0;var wi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(wi>>>26)|0,wi&=67108863,b=Math.imul(Ce,be),h=Math.imul(Ce,ge),h=h+Math.imul(te,be)|0,T=Math.imul(te,ge),b=b+Math.imul(wt,Ae)|0,h=h+Math.imul(wt,qe)|0,h=h+Math.imul(Et,Ae)|0,T=T+Math.imul(Et,qe)|0,b=b+Math.imul(Ve,at)|0,h=h+Math.imul(Ve,gt)|0,h=h+Math.imul(We,at)|0,T=T+Math.imul(We,gt)|0;var oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(oi>>>26)|0,oi&=67108863,b=Math.imul(Ce,Ae),h=Math.imul(Ce,qe),h=h+Math.imul(te,Ae)|0,T=Math.imul(te,qe),b=b+Math.imul(wt,at)|0,h=h+Math.imul(wt,gt)|0,h=h+Math.imul(Et,at)|0,T=T+Math.imul(Et,gt)|0;var zt=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zt>>>26)|0,zt&=67108863,b=Math.imul(Ce,at),h=Math.imul(Ce,gt),h=h+Math.imul(te,at)|0,T=Math.imul(te,gt);var Qt=(S+b|0)+((h&8191)<<13)|0;return S=(T+(h>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,x[0]=ei,x[1]=ii,x[2]=Bi,x[3]=hi,x[4]=Di,x[5]=ni,x[6]=pi,x[7]=Ii,x[8]=Ci,x[9]=zi,x[10]=qi,x[11]=Ai,x[12]=Oi,x[13]=ki,x[14]=Ti,x[15]=wi,x[16]=oi,x[17]=zt,x[18]=Qt,S!==0&&(x[19]=S,w.length++),w};Math.imul||(B=R);function F(L,d,v){v.negative=d.negative^L.negative,v.length=L.length+d.length;for(var w=0,c=0,p=0;p<v.length-1;p++){var x=c;c=0;for(var S=w&67108863,b=Math.min(p,d.length-1),h=Math.max(0,p-L.length+1);h<=b;h++){var T=p-h,M=L.words[T]|0,O=d.words[h]|0,V=M*O,ee=V&67108863;x=x+(V/67108864|0)|0,ee=ee+S|0,S=ee&67108863,x=x+(ee>>>26)|0,c+=x>>>26,x&=67108863}v.words[p]=S,w=x,x=c}return w!==0?v.words[p]=w:v.length--,v.strip()}function j(L,d,v){var w=new N;return w.mulp(L,d,v)}l.prototype.mulTo=function(d,v){var w,c=this.length+d.length;return this.length===10&&d.length===10?w=B(this,d,v):c<63?w=R(this,d,v):c<1024?w=F(this,d,v):w=j(this,d,v),w};function N(L,d){this.x=L,this.y=d}N.prototype.makeRBT=function(d){for(var v=new Array(d),w=l.prototype._countBits(d)-1,c=0;c<d;c++)v[c]=this.revBin(c,w,d);return v},N.prototype.revBin=function(d,v,w){if(d===0||d===w-1)return d;for(var c=0,p=0;p<v;p++)c|=(d&1)<<v-p-1,d>>=1;return c},N.prototype.permute=function(d,v,w,c,p,x){for(var S=0;S<x;S++)c[S]=v[d[S]],p[S]=w[d[S]]},N.prototype.transform=function(d,v,w,c,p,x){this.permute(x,d,v,w,c,p);for(var S=1;S<p;S<<=1)for(var b=S<<1,h=Math.cos(2*Math.PI/b),T=Math.sin(2*Math.PI/b),M=0;M<p;M+=b)for(var O=h,V=T,ee=0;ee<S;ee++){var Z=w[M+ee],U=c[M+ee],z=w[M+ee+S],ne=c[M+ee+S],fe=O*z-V*ne;ne=O*ne+V*z,z=fe,w[M+ee]=Z+z,c[M+ee]=U+ne,w[M+ee+S]=Z-z,c[M+ee+S]=U-ne,ee!==b&&(fe=h*O-T*V,V=h*V+T*O,O=fe)}},N.prototype.guessLen13b=function(d,v){var w=Math.max(v,d)|1,c=w&1,p=0;for(w=w/2|0;w;w=w>>>1)p++;return 1<<p+1+c},N.prototype.conjugate=function(d,v,w){if(!(w<=1))for(var c=0;c<w/2;c++){var p=d[c];d[c]=d[w-c-1],d[w-c-1]=p,p=v[c],v[c]=-v[w-c-1],v[w-c-1]=-p}},N.prototype.normalize13b=function(d,v){for(var w=0,c=0;c<v/2;c++){var p=Math.round(d[2*c+1]/v)*8192+Math.round(d[2*c]/v)+w;d[c]=p&67108863,p<67108864?w=0:w=p/67108864|0}return d},N.prototype.convert13b=function(d,v,w,c){for(var p=0,x=0;x<v;x++)p=p+(d[x]|0),w[2*x]=p&8191,p=p>>>13,w[2*x+1]=p&8191,p=p>>>13;for(x=2*v;x<c;++x)w[x]=0;o(p===0),o((p&-8192)===0)},N.prototype.stub=function(d){for(var v=new Array(d),w=0;w<d;w++)v[w]=0;return v},N.prototype.mulp=function(d,v,w){var c=2*this.guessLen13b(d.length,v.length),p=this.makeRBT(c),x=this.stub(c),S=new Array(c),b=new Array(c),h=new Array(c),T=new Array(c),M=new Array(c),O=new Array(c),V=w.words;V.length=c,this.convert13b(d.words,d.length,S,c),this.convert13b(v.words,v.length,T,c),this.transform(S,x,b,h,c,p),this.transform(T,x,M,O,c,p);for(var ee=0;ee<c;ee++){var Z=b[ee]*M[ee]-h[ee]*O[ee];h[ee]=b[ee]*O[ee]+h[ee]*M[ee],b[ee]=Z}return this.conjugate(b,h,c),this.transform(b,h,V,x,c,p),this.conjugate(V,x,c),this.normalize13b(V,c),w.negative=d.negative^v.negative,w.length=d.length+v.length,w.strip()},l.prototype.mul=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),this.mulTo(d,v)},l.prototype.mulf=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),j(this,d,v)},l.prototype.imul=function(d){return this.clone().mulTo(d,this)},l.prototype.imuln=function(d){o(typeof d=="number"),o(d<67108864);for(var v=0,w=0;w<this.length;w++){var c=(this.words[w]|0)*d,p=(c&67108863)+(v&67108863);v>>=26,v+=c/67108864|0,v+=p>>>26,this.words[w]=p&67108863}return v!==0&&(this.words[w]=v,this.length++),this},l.prototype.muln=function(d){return this.clone().imuln(d)},l.prototype.sqr=function(){return this.mul(this)},l.prototype.isqr=function(){return this.imul(this.clone())},l.prototype.pow=function(d){var v=P(d);if(v.length===0)return new l(1);for(var w=this,c=0;c<v.length&&v[c]===0;c++,w=w.sqr());if(++c<v.length)for(var p=w.sqr();c<v.length;c++,p=p.sqr())v[c]!==0&&(w=w.mul(p));return w},l.prototype.iushln=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=67108863>>>26-v<<26-v,p;if(v!==0){var x=0;for(p=0;p<this.length;p++){var S=this.words[p]&c,b=(this.words[p]|0)-S<<v;this.words[p]=b|x,x=S>>>26-v}x&&(this.words[p]=x,this.length++)}if(w!==0){for(p=this.length-1;p>=0;p--)this.words[p+w]=this.words[p];for(p=0;p<w;p++)this.words[p]=0;this.length+=w}return this.strip()},l.prototype.ishln=function(d){return o(this.negative===0),this.iushln(d)},l.prototype.iushrn=function(d,v,w){o(typeof d=="number"&&d>=0);var c;v?c=(v-v%26)/26:c=0;var p=d%26,x=Math.min((d-p)/26,this.length),S=67108863^67108863>>>p<<p,b=w;if(c-=x,c=Math.max(0,c),b){for(var h=0;h<x;h++)b.words[h]=this.words[h];b.length=x}if(x!==0)if(this.length>x)for(this.length-=x,h=0;h<this.length;h++)this.words[h]=this.words[h+x];else this.words[0]=0,this.length=1;var T=0;for(h=this.length-1;h>=0&&(T!==0||h>=c);h--){var M=this.words[h]|0;this.words[h]=T<<26-p|M>>>p,T=M&S}return b&&T!==0&&(b.words[b.length++]=T),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},l.prototype.ishrn=function(d,v,w){return o(this.negative===0),this.iushrn(d,v,w)},l.prototype.shln=function(d){return this.clone().ishln(d)},l.prototype.ushln=function(d){return this.clone().iushln(d)},l.prototype.shrn=function(d){return this.clone().ishrn(d)},l.prototype.ushrn=function(d){return this.clone().iushrn(d)},l.prototype.testn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return!1;var p=this.words[w];return!!(p&c)},l.prototype.imaskn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26;if(o(this.negative===0,"imaskn works only with positive numbers"),this.length<=w)return this;if(v!==0&&w++,this.length=Math.min(w,this.length),v!==0){var c=67108863^67108863>>>v<<v;this.words[this.length-1]&=c}return this.strip()},l.prototype.maskn=function(d){return this.clone().imaskn(d)},l.prototype.iaddn=function(d){return o(typeof d=="number"),o(d<67108864),d<0?this.isubn(-d):this.negative!==0?this.length===1&&(this.words[0]|0)<d?(this.words[0]=d-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(d),this.negative=1,this):this._iaddn(d)},l.prototype._iaddn=function(d){this.words[0]+=d;for(var v=0;v<this.length&&this.words[v]>=67108864;v++)this.words[v]-=67108864,v===this.length-1?this.words[v+1]=1:this.words[v+1]++;return this.length=Math.max(this.length,v+1),this},l.prototype.isubn=function(d){if(o(typeof d=="number"),o(d<67108864),d<0)return this.iaddn(-d);if(this.negative!==0)return this.negative=0,this.iaddn(d),this.negative=1,this;if(this.words[0]-=d,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var v=0;v<this.length&&this.words[v]<0;v++)this.words[v]+=67108864,this.words[v+1]-=1;return this.strip()},l.prototype.addn=function(d){return this.clone().iaddn(d)},l.prototype.subn=function(d){return this.clone().isubn(d)},l.prototype.iabs=function(){return this.negative=0,this},l.prototype.abs=function(){return this.clone().iabs()},l.prototype._ishlnsubmul=function(d,v,w){var c=d.length+w,p;this._expand(c);var x,S=0;for(p=0;p<d.length;p++){x=(this.words[p+w]|0)+S;var b=(d.words[p]|0)*v;x-=b&67108863,S=(x>>26)-(b/67108864|0),this.words[p+w]=x&67108863}for(;p<this.length-w;p++)x=(this.words[p+w]|0)+S,S=x>>26,this.words[p+w]=x&67108863;if(S===0)return this.strip();for(o(S===-1),S=0,p=0;p<this.length;p++)x=-(this.words[p]|0)+S,S=x>>26,this.words[p]=x&67108863;return this.negative=1,this.strip()},l.prototype._wordDiv=function(d,v){var w=this.length-d.length,c=this.clone(),p=d,x=p.words[p.length-1]|0,S=this._countBits(x);w=26-S,w!==0&&(p=p.ushln(w),c.iushln(w),x=p.words[p.length-1]|0);var b=c.length-p.length,h;if(v!=="mod"){h=new l(null),h.length=b+1,h.words=new Array(h.length);for(var T=0;T<h.length;T++)h.words[T]=0}var M=c.clone()._ishlnsubmul(p,1,b);M.negative===0&&(c=M,h&&(h.words[b]=1));for(var O=b-1;O>=0;O--){var V=(c.words[p.length+O]|0)*67108864+(c.words[p.length+O-1]|0);for(V=Math.min(V/x|0,67108863),c._ishlnsubmul(p,V,O);c.negative!==0;)V--,c.negative=0,c._ishlnsubmul(p,1,O),c.isZero()||(c.negative^=1);h&&(h.words[O]=V)}return h&&h.strip(),c.strip(),v!=="div"&&w!==0&&c.iushrn(w),{div:h||null,mod:c}},l.prototype.divmod=function(d,v,w){if(o(!d.isZero()),this.isZero())return{div:new l(0),mod:new l(0)};var c,p,x;return this.negative!==0&&d.negative===0?(x=this.neg().divmod(d,v),v!=="mod"&&(c=x.div.neg()),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.iadd(d)),{div:c,mod:p}):this.negative===0&&d.negative!==0?(x=this.divmod(d.neg(),v),v!=="mod"&&(c=x.div.neg()),{div:c,mod:x.mod}):this.negative&d.negative?(x=this.neg().divmod(d.neg(),v),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.isub(d)),{div:x.div,mod:p}):d.length>this.length||this.cmp(d)<0?{div:new l(0),mod:this}:d.length===1?v==="div"?{div:this.divn(d.words[0]),mod:null}:v==="mod"?{div:null,mod:new l(this.modn(d.words[0]))}:{div:this.divn(d.words[0]),mod:new l(this.modn(d.words[0]))}:this._wordDiv(d,v)},l.prototype.div=function(d){return this.divmod(d,"div",!1).div},l.prototype.mod=function(d){return this.divmod(d,"mod",!1).mod},l.prototype.umod=function(d){return this.divmod(d,"mod",!0).mod},l.prototype.divRound=function(d){var v=this.divmod(d);if(v.mod.isZero())return v.div;var w=v.div.negative!==0?v.mod.isub(d):v.mod,c=d.ushrn(1),p=d.andln(1),x=w.cmp(c);return x<0||p===1&&x===0?v.div:v.div.negative!==0?v.div.isubn(1):v.div.iaddn(1)},l.prototype.modn=function(d){o(d<=67108863);for(var v=(1<<26)%d,w=0,c=this.length-1;c>=0;c--)w=(v*w+(this.words[c]|0))%d;return w},l.prototype.idivn=function(d){o(d<=67108863);for(var v=0,w=this.length-1;w>=0;w--){var c=(this.words[w]|0)+v*67108864;this.words[w]=c/d|0,v=c%d}return this.strip()},l.prototype.divn=function(d){return this.clone().idivn(d)},l.prototype.egcd=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=new l(0),S=new l(1),b=0;v.isEven()&&w.isEven();)v.iushrn(1),w.iushrn(1),++b;for(var h=w.clone(),T=v.clone();!v.isZero();){for(var M=0,O=1;!(v.words[0]&O)&&M<26;++M,O<<=1);if(M>0)for(v.iushrn(M);M-- >0;)(c.isOdd()||p.isOdd())&&(c.iadd(h),p.isub(T)),c.iushrn(1),p.iushrn(1);for(var V=0,ee=1;!(w.words[0]&ee)&&V<26;++V,ee<<=1);if(V>0)for(w.iushrn(V);V-- >0;)(x.isOdd()||S.isOdd())&&(x.iadd(h),S.isub(T)),x.iushrn(1),S.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(x),p.isub(S)):(w.isub(v),x.isub(c),S.isub(p))}return{a:x,b:S,gcd:w.iushln(b)}},l.prototype._invmp=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=w.clone();v.cmpn(1)>0&&w.cmpn(1)>0;){for(var S=0,b=1;!(v.words[0]&b)&&S<26;++S,b<<=1);if(S>0)for(v.iushrn(S);S-- >0;)c.isOdd()&&c.iadd(x),c.iushrn(1);for(var h=0,T=1;!(w.words[0]&T)&&h<26;++h,T<<=1);if(h>0)for(w.iushrn(h);h-- >0;)p.isOdd()&&p.iadd(x),p.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(p)):(w.isub(v),p.isub(c))}var M;return v.cmpn(1)===0?M=c:M=p,M.cmpn(0)<0&&M.iadd(d),M},l.prototype.gcd=function(d){if(this.isZero())return d.abs();if(d.isZero())return this.abs();var v=this.clone(),w=d.clone();v.negative=0,w.negative=0;for(var c=0;v.isEven()&&w.isEven();c++)v.iushrn(1),w.iushrn(1);do{for(;v.isEven();)v.iushrn(1);for(;w.isEven();)w.iushrn(1);var p=v.cmp(w);if(p<0){var x=v;v=w,w=x}else if(p===0||w.cmpn(1)===0)break;v.isub(w)}while(!0);return w.iushln(c)},l.prototype.invm=function(d){return this.egcd(d).a.umod(d)},l.prototype.isEven=function(){return(this.words[0]&1)===0},l.prototype.isOdd=function(){return(this.words[0]&1)===1},l.prototype.andln=function(d){return this.words[0]&d},l.prototype.bincn=function(d){o(typeof d=="number");var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return this._expand(w+1),this.words[w]|=c,this;for(var p=c,x=w;p!==0&&x<this.length;x++){var S=this.words[x]|0;S+=p,p=S>>>26,S&=67108863,this.words[x]=S}return p!==0&&(this.words[x]=p,this.length++),this},l.prototype.isZero=function(){return this.length===1&&this.words[0]===0},l.prototype.cmpn=function(d){var v=d<0;if(this.negative!==0&&!v)return-1;if(this.negative===0&&v)return 1;this.strip();var w;if(this.length>1)w=1;else{v&&(d=-d),o(d<=67108863,"Number is too big");var c=this.words[0]|0;w=c===d?0:c<d?-1:1}return this.negative!==0?-w|0:w},l.prototype.cmp=function(d){if(this.negative!==0&&d.negative===0)return-1;if(this.negative===0&&d.negative!==0)return 1;var v=this.ucmp(d);return this.negative!==0?-v|0:v},l.prototype.ucmp=function(d){if(this.length>d.length)return 1;if(this.length<d.length)return-1;for(var v=0,w=this.length-1;w>=0;w--){var c=this.words[w]|0,p=d.words[w]|0;if(c!==p){c<p?v=-1:c>p&&(v=1);break}}return v},l.prototype.gtn=function(d){return this.cmpn(d)===1},l.prototype.gt=function(d){return this.cmp(d)===1},l.prototype.gten=function(d){return this.cmpn(d)>=0},l.prototype.gte=function(d){return this.cmp(d)>=0},l.prototype.ltn=function(d){return this.cmpn(d)===-1},l.prototype.lt=function(d){return this.cmp(d)===-1},l.prototype.lten=function(d){return this.cmpn(d)<=0},l.prototype.lte=function(d){return this.cmp(d)<=0},l.prototype.eqn=function(d){return this.cmpn(d)===0},l.prototype.eq=function(d){return this.cmp(d)===0},l.red=function(d){return new he(d)},l.prototype.toRed=function(d){return o(!this.red,"Already a number in reduction context"),o(this.negative===0,"red works only with positives"),d.convertTo(this)._forceRed(d)},l.prototype.fromRed=function(){return o(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},l.prototype._forceRed=function(d){return this.red=d,this},l.prototype.forceRed=function(d){return o(!this.red,"Already a number in reduction context"),this._forceRed(d)},l.prototype.redAdd=function(d){return o(this.red,"redAdd works only with red numbers"),this.red.add(this,d)},l.prototype.redIAdd=function(d){return o(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,d)},l.prototype.redSub=function(d){return o(this.red,"redSub works only with red numbers"),this.red.sub(this,d)},l.prototype.redISub=function(d){return o(this.red,"redISub works only with red numbers"),this.red.isub(this,d)},l.prototype.redShl=function(d){return o(this.red,"redShl works only with red numbers"),this.red.shl(this,d)},l.prototype.redMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.mul(this,d)},l.prototype.redIMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.imul(this,d)},l.prototype.redSqr=function(){return o(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},l.prototype.redISqr=function(){return o(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},l.prototype.redSqrt=function(){return o(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},l.prototype.redInvm=function(){return o(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},l.prototype.redNeg=function(){return o(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},l.prototype.redPow=function(d){return o(this.red&&!d.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,d)};var Y={k256:null,p224:null,p192:null,p25519:null};function J(L,d){this.name=L,this.p=new l(d,16),this.n=this.p.bitLength(),this.k=new l(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}J.prototype._tmp=function(){var d=new l(null);return d.words=new Array(Math.ceil(this.n/13)),d},J.prototype.ireduce=function(d){var v=d,w;do this.split(v,this.tmp),v=this.imulK(v),v=v.iadd(this.tmp),w=v.bitLength();while(w>this.n);var c=w<this.n?-1:v.ucmp(this.p);return c===0?(v.words[0]=0,v.length=1):c>0?v.isub(this.p):v.strip!==void 0?v.strip():v._strip(),v},J.prototype.split=function(d,v){d.iushrn(this.n,0,v)},J.prototype.imulK=function(d){return d.imul(this.k)};function ie(){J.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}u(ie,J),ie.prototype.split=function(d,v){for(var w=4194303,c=Math.min(d.length,9),p=0;p<c;p++)v.words[p]=d.words[p];if(v.length=c,d.length<=9){d.words[0]=0,d.length=1;return}var x=d.words[9];for(v.words[v.length++]=x&w,p=10;p<d.length;p++){var S=d.words[p]|0;d.words[p-10]=(S&w)<<4|x>>>22,x=S}x>>>=22,d.words[p-10]=x,x===0&&d.length>10?d.length-=10:d.length-=9},ie.prototype.imulK=function(d){d.words[d.length]=0,d.words[d.length+1]=0,d.length+=2;for(var v=0,w=0;w<d.length;w++){var c=d.words[w]|0;v+=c*977,d.words[w]=v&67108863,v=c*64+(v/67108864|0)}return d.words[d.length-1]===0&&(d.length--,d.words[d.length-1]===0&&d.length--),d};function ue(){J.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}u(ue,J);function Q(){J.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}u(Q,J);function ce(){J.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}u(ce,J),ce.prototype.imulK=function(d){for(var v=0,w=0;w<d.length;w++){var c=(d.words[w]|0)*19+v,p=c&67108863;c>>>=26,d.words[w]=p,v=c}return v!==0&&(d.words[d.length++]=v),d},l._prime=function(d){if(Y[d])return Y[d];var v;if(d==="k256")v=new ie;else if(d==="p224")v=new ue;else if(d==="p192")v=new Q;else if(d==="p25519")v=new ce;else throw new Error("Unknown prime "+d);return Y[d]=v,v};function he(L){if(typeof L=="string"){var d=l._prime(L);this.m=d.p,this.prime=d}else o(L.gtn(1),"modulus must be greater than 1"),this.m=L,this.prime=null}he.prototype._verify1=function(d){o(d.negative===0,"red works only with positives"),o(d.red,"red works only with red numbers")},he.prototype._verify2=function(d,v){o((d.negative|v.negative)===0,"red works only with positives"),o(d.red&&d.red===v.red,"red works only with red numbers")},he.prototype.imod=function(d){return this.prime?this.prime.ireduce(d)._forceRed(this):d.umod(this.m)._forceRed(this)},he.prototype.neg=function(d){return d.isZero()?d.clone():this.m.sub(d)._forceRed(this)},he.prototype.add=function(d,v){this._verify2(d,v);var w=d.add(v);return w.cmp(this.m)>=0&&w.isub(this.m),w._forceRed(this)},he.prototype.iadd=function(d,v){this._verify2(d,v);var w=d.iadd(v);return w.cmp(this.m)>=0&&w.isub(this.m),w},he.prototype.sub=function(d,v){this._verify2(d,v);var w=d.sub(v);return w.cmpn(0)<0&&w.iadd(this.m),w._forceRed(this)},he.prototype.isub=function(d,v){this._verify2(d,v);var w=d.isub(v);return w.cmpn(0)<0&&w.iadd(this.m),w},he.prototype.shl=function(d,v){return this._verify1(d),this.imod(d.ushln(v))},he.prototype.imul=function(d,v){return this._verify2(d,v),this.imod(d.imul(v))},he.prototype.mul=function(d,v){return this._verify2(d,v),this.imod(d.mul(v))},he.prototype.isqr=function(d){return this.imul(d,d.clone())},he.prototype.sqr=function(d){return this.mul(d,d)},he.prototype.sqrt=function(d){if(d.isZero())return d.clone();var v=this.m.andln(3);if(o(v%2===1),v===3){var w=this.m.add(new l(1)).iushrn(2);return this.pow(d,w)}for(var c=this.m.subn(1),p=0;!c.isZero()&&c.andln(1)===0;)p++,c.iushrn(1);o(!c.isZero());var x=new l(1).toRed(this),S=x.redNeg(),b=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new l(2*h*h).toRed(this);this.pow(h,b).cmp(S)!==0;)h.redIAdd(S);for(var T=this.pow(h,c),M=this.pow(d,c.addn(1).iushrn(1)),O=this.pow(d,c),V=p;O.cmp(x)!==0;){for(var ee=O,Z=0;ee.cmp(x)!==0;Z++)ee=ee.redSqr();o(Z<V);var U=this.pow(T,new l(1).iushln(V-Z-1));M=M.redMul(U),T=U.redSqr(),O=O.redMul(T),V=Z}return M},he.prototype.invm=function(d){var v=d._invmp(this.m);return v.negative!==0?(v.negative=0,this.imod(v).redNeg()):this.imod(v)},he.prototype.pow=function(d,v){if(v.isZero())return new l(1).toRed(this);if(v.cmpn(1)===0)return d.clone();var w=4,c=new Array(1<<w);c[0]=new l(1).toRed(this),c[1]=d;for(var p=2;p<c.length;p++)c[p]=this.mul(c[p-1],d);var x=c[0],S=0,b=0,h=v.bitLength()%26;for(h===0&&(h=26),p=v.length-1;p>=0;p--){for(var T=v.words[p],M=h-1;M>=0;M--){var O=T>>M&1;if(x!==c[0]&&(x=this.sqr(x)),O===0&&S===0){b=0;continue}S<<=1,S|=O,b++,!(b!==w&&(p!==0||M!==0))&&(x=this.mul(x,c[S]),b=0,S=0)}h=26}return x},he.prototype.convertTo=function(d){var v=d.umod(this.m);return v===d?v.clone():v},he.prototype.convertFrom=function(d){var v=d.clone();return v.red=null,v},l.mont=function(d){return new ke(d)};function ke(L){he.call(this,L),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new l(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}u(ke,he),ke.prototype.convertTo=function(d){return this.imod(d.ushln(this.shift))},ke.prototype.convertFrom=function(d){var v=this.imod(d.mul(this.rinv));return v.red=null,v},ke.prototype.imul=function(d,v){if(d.isZero()||v.isZero())return d.words[0]=0,d.length=1,d;var w=d.imul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.mul=function(d,v){if(d.isZero()||v.isZero())return new l(0)._forceRed(this);var w=d.mul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.invm=function(d){var v=this.imod(d._invmp(this.m).mul(this.r2));return v._forceRed(this)}})(t,commonjsGlobal$1)}(bn$5);var bnExports$5=bn$5.exports,brorand={exports:{}},hasRequiredBrorand;function requireBrorand(){if(hasRequiredBrorand)return brorand.exports;hasRequiredBrorand=1;var t;brorand.exports=function(u){return t||(t=new e(null)),t.generate(u)};function e(o){this.rand=o}if(brorand.exports.Rand=e,e.prototype.generate=function(u){return this._rand(u)},e.prototype._rand=function(u){if(this.rand.getBytes)return this.rand.getBytes(u);for(var l=new Uint8Array(u),m=0;m<l.length;m++)l[m]=this.rand.getByte();return l},typeof self=="object")self.crypto&&self.crypto.getRandomValues?e.prototype._rand=function(u){var l=new Uint8Array(u);return self.crypto.getRandomValues(l),l}:self.msCrypto&&self.msCrypto.getRandomValues?e.prototype._rand=function(u){var l=new Uint8Array(u);return self.msCrypto.getRandomValues(l),l}:typeof window=="object"&&(e.prototype._rand=function(){throw new Error("Not implemented yet")});else try{var n=requireCryptoBrowserify();if(typeof n.randomBytes!="function")throw new Error("Not supported");e.prototype._rand=function(u){return n.randomBytes(u)}}catch{}return brorand.exports}var mr,hasRequiredMr;function requireMr(){if(hasRequiredMr)return mr;hasRequiredMr=1;var t=bnExports$5,e=requireBrorand();function n(o){this.rand=o||new e.Rand}return mr=n,n.create=function(u){return new n(u)},n.prototype._randbelow=function(u){var l=u.bitLength(),m=Math.ceil(l/8);do var y=new t(this.rand.generate(m));while(y.cmp(u)>=0);return y},n.prototype._randrange=function(u,l){var m=l.sub(u);return u.add(this._randbelow(m))},n.prototype.test=function(u,l,m){var y=u.bitLength(),E=t.mont(u),C=new t(1).toRed(E);l||(l=Math.max(1,y/48|0));for(var k=u.subn(1),A=0;!k.testn(A);A++);for(var D=u.shrn(A),P=k.toRed(E),R=!0;l>0;l--){var B=this._randrange(new t(2),k);m&&m(B);var F=B.toRed(E).redPow(D);if(!(F.cmp(C)===0||F.cmp(P)===0)){for(var j=1;j<A;j++){if(F=F.redSqr(),F.cmp(C)===0)return!1;if(F.cmp(P)===0)break}if(j===A)return!1}}return R},n.prototype.getDivisor=function(u,l){var m=u.bitLength(),y=t.mont(u),E=new t(1).toRed(y);l||(l=Math.max(1,m/48|0));for(var C=u.subn(1),k=0;!C.testn(k);k++);for(var A=u.shrn(k),D=C.toRed(y);l>0;l--){var P=this._randrange(new t(2),C),R=u.gcd(P);if(R.cmpn(1)!==0)return R;var B=P.toRed(y).redPow(A);if(!(B.cmp(E)===0||B.cmp(D)===0)){for(var F=1;F<k;F++){if(B=B.redSqr(),B.cmp(E)===0)return B.fromRed().subn(1).gcd(u);if(B.cmp(D)===0)break}if(F===k)return B=B.redSqr(),B.fromRed().subn(1).gcd(u)}}return!1},mr}var generatePrime,hasRequiredGeneratePrime;function requireGeneratePrime(){if(hasRequiredGeneratePrime)return generatePrime;hasRequiredGeneratePrime=1;var t=browserExports;generatePrime=F,F.simpleSieve=R,F.fermatTest=B;var e=bnExports$6,n=new e(24),o=requireMr(),u=new o,l=new e(1),m=new e(2),y=new e(5);new e(16),new e(8);var E=new e(10),C=new e(3);new e(7);var k=new e(11),A=new e(4);new e(12);var D=null;function P(){if(D!==null)return D;var j=1048576,N=[];N[0]=2;for(var Y=1,J=3;J<j;J+=2){for(var ie=Math.ceil(Math.sqrt(J)),ue=0;ue<Y&&N[ue]<=ie&&J%N[ue]!==0;ue++);Y!==ue&&N[ue]<=ie||(N[Y++]=J)}return D=N,N}function R(j){for(var N=P(),Y=0;Y<N.length;Y++)if(j.modn(N[Y])===0)return j.cmpn(N[Y])===0;return!0}function B(j){var N=e.mont(j);return m.toRed(N).redPow(j.subn(1)).fromRed().cmpn(1)===0}function F(j,N){if(j<16)return N===2||N===5?new e([140,123]):new e([140,39]);N=new e(N);for(var Y,J;;){for(Y=new e(t(Math.ceil(j/8)));Y.bitLength()>j;)Y.ishrn(1);if(Y.isEven()&&Y.iadd(l),Y.testn(1)||Y.iadd(m),N.cmp(m)){if(!N.cmp(y))for(;Y.mod(E).cmp(C);)Y.iadd(A)}else for(;Y.mod(n).cmp(k);)Y.iadd(A);if(J=Y.shrn(1),R(J)&&R(Y)&&B(J)&&B(Y)&&u.test(J)&&u.test(Y))return Y}}return generatePrime}const modp1={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},modp2={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},modp5={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},modp14={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},modp15={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},modp16={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},modp17={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},modp18={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"},require$$1$3={modp1,modp2,modp5,modp14,modp15,modp16,modp17,modp18};var dh,hasRequiredDh;function requireDh(){if(hasRequiredDh)return dh;hasRequiredDh=1;var t=bnExports$6,e=requireMr(),n=new e,o=new t(24),u=new t(11),l=new t(10),m=new t(3),y=new t(7),E=requireGeneratePrime(),C=browserExports;dh=R;function k(F,j){return j=j||"utf8",Buffer$C.isBuffer(F)||(F=new Buffer$C(F,j)),this._pub=new t(F),this}function A(F,j){return j=j||"utf8",Buffer$C.isBuffer(F)||(F=new Buffer$C(F,j)),this._priv=new t(F),this}var D={};function P(F,j){var N=j.toString("hex"),Y=[N,F.toString(16)].join("_");if(Y in D)return D[Y];var J=0;if(F.isEven()||!E.simpleSieve||!E.fermatTest(F)||!n.test(F))return J+=1,N==="02"||N==="05"?J+=8:J+=4,D[Y]=J,J;n.test(F.shrn(1))||(J+=2);var ie;switch(N){case"02":F.mod(o).cmp(u)&&(J+=8);break;case"05":ie=F.mod(l),ie.cmp(m)&&ie.cmp(y)&&(J+=8);break;default:J+=4}return D[Y]=J,J}function R(F,j,N){this.setGenerator(j),this.__prime=new t(F),this._prime=t.mont(this.__prime),this._primeLen=F.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,N?(this.setPublicKey=k,this.setPrivateKey=A):this._primeCode=8}Object.defineProperty(R.prototype,"verifyError",{enumerable:!0,get:function(){return typeof this._primeCode!="number"&&(this._primeCode=P(this.__prime,this.__gen)),this._primeCode}}),R.prototype.generateKeys=function(){return this._priv||(this._priv=new t(C(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},R.prototype.computeSecret=function(F){F=new t(F),F=F.toRed(this._prime);var j=F.redPow(this._priv).fromRed(),N=new Buffer$C(j.toArray()),Y=this.getPrime();if(N.length<Y.length){var J=new Buffer$C(Y.length-N.length);J.fill(0),N=Buffer$C.concat([J,N])}return N},R.prototype.getPublicKey=function(j){return B(this._pub,j)},R.prototype.getPrivateKey=function(j){return B(this._priv,j)},R.prototype.getPrime=function(F){return B(this.__prime,F)},R.prototype.getGenerator=function(F){return B(this._gen,F)},R.prototype.setGenerator=function(F,j){return j=j||"utf8",Buffer$C.isBuffer(F)||(F=new Buffer$C(F,j)),this.__gen=F,this._gen=new t(F),this};function B(F,j){var N=new Buffer$C(F.toArray());return j?N.toString(j):N}return dh}var hasRequiredBrowser$4;function requireBrowser$4(){if(hasRequiredBrowser$4)return browser$6;hasRequiredBrowser$4=1;var t=requireGeneratePrime(),e=require$$1$3,n=requireDh();function o(m){var y=new Buffer$C(e[m].prime,"hex"),E=new Buffer$C(e[m].gen,"hex");return new n(y,E)}var u={binary:!0,hex:!0,base64:!0};function l(m,y,E,C){return Buffer$C.isBuffer(y)||u[y]===void 0?l(m,"binary",y,E):(y=y||"binary",C=C||"binary",E=E||new Buffer$C([2]),Buffer$C.isBuffer(E)||(E=new Buffer$C(E,C)),typeof m=="number"?new n(t(m,E),E,!0):(Buffer$C.isBuffer(m)||(m=new Buffer$C(m,y)),new n(m,E,!0)))}return browser$6.DiffieHellmanGroup=browser$6.createDiffieHellmanGroup=browser$6.getDiffieHellman=o,browser$6.createDiffieHellman=browser$6.DiffieHellman=l,browser$6}var readableBrowser$1={exports:{}},processNextickArgs={exports:{}};typeof process$1>"u"||!process$1.version||process$1.version.indexOf("v0.")===0||process$1.version.indexOf("v1.")===0&&process$1.version.indexOf("v1.8.")!==0?processNextickArgs.exports={nextTick}:processNextickArgs.exports=process$1;function nextTick(t,e,n,o){if(typeof t!="function")throw new TypeError('"callback" argument must be a function');var u=arguments.length,l,m;switch(u){case 0:case 1:return process$1.nextTick(t);case 2:return process$1.nextTick(function(){t.call(null,e)});case 3:return process$1.nextTick(function(){t.call(null,e,n)});case 4:return process$1.nextTick(function(){t.call(null,e,n,o)});default:for(l=new Array(u-1),m=0;m<l.length;)l[m++]=arguments[m];return process$1.nextTick(function(){t.apply(null,l)})}}var processNextickArgsExports=processNextickArgs.exports,toString={}.toString,isarray=Array.isArray||function(t){return toString.call(t)=="[object Array]"},streamBrowser=requireEvents().EventEmitter,safeBuffer$1={exports:{}};(function(t,e){var n=require$$0$2,o=n.Buffer;function u(m,y){for(var E in m)y[E]=m[E]}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?t.exports=n:(u(n,e),e.Buffer=l);function l(m,y,E){return o(m,y,E)}u(o,l),l.from=function(m,y,E){if(typeof m=="number")throw new TypeError("Argument must not be a number");return o(m,y,E)},l.alloc=function(m,y,E){if(typeof m!="number")throw new TypeError("Argument must be a number");var C=o(m);return y!==void 0?typeof E=="string"?C.fill(y,E):C.fill(y):C.fill(0),C},l.allocUnsafe=function(m){if(typeof m!="number")throw new TypeError("Argument must be a number");return o(m)},l.allocUnsafeSlow=function(m){if(typeof m!="number")throw new TypeError("Argument must be a number");return n.SlowBuffer(m)}})(safeBuffer$1,safeBuffer$1.exports);var safeBufferExports=safeBuffer$1.exports,util$3={};function isArray(t){return Array.isArray?Array.isArray(t):objectToString(t)==="[object Array]"}util$3.isArray=isArray;function isBoolean(t){return typeof t=="boolean"}util$3.isBoolean=isBoolean;function isNull(t){return t===null}util$3.isNull=isNull;function isNullOrUndefined(t){return t==null}util$3.isNullOrUndefined=isNullOrUndefined;function isNumber(t){return typeof t=="number"}util$3.isNumber=isNumber;function isString(t){return typeof t=="string"}util$3.isString=isString;function isSymbol(t){return typeof t=="symbol"}util$3.isSymbol=isSymbol;function isUndefined(t){return t===void 0}util$3.isUndefined=isUndefined;function isRegExp(t){return objectToString(t)==="[object RegExp]"}util$3.isRegExp=isRegExp;function isObject(t){return typeof t=="object"&&t!==null}util$3.isObject=isObject;function isDate(t){return objectToString(t)==="[object Date]"}util$3.isDate=isDate;function isError(t){return objectToString(t)==="[object Error]"||t instanceof Error}util$3.isError=isError;function isFunction(t){return typeof t=="function"}util$3.isFunction=isFunction;function isPrimitive(t){return t===null||typeof t=="boolean"||typeof t=="number"||typeof t=="string"||typeof t=="symbol"||typeof t>"u"}util$3.isPrimitive=isPrimitive,util$3.isBuffer=Buffer$C.isBuffer;function objectToString(t){return Object.prototype.toString.call(t)}var BufferList={exports:{}},hasRequiredBufferList;function requireBufferList(){return hasRequiredBufferList||(hasRequiredBufferList=1,function(t){function e(l,m){if(!(l instanceof m))throw new TypeError("Cannot call a class as a function")}var n=safeBufferExports.Buffer,o=util$6;function u(l,m,y){l.copy(m,y)}t.exports=function(){function l(){e(this,l),this.head=null,this.tail=null,this.length=0}return l.prototype.push=function(y){var E={data:y,next:null};this.length>0?this.tail.next=E:this.head=E,this.tail=E,++this.length},l.prototype.unshift=function(y){var E={data:y,next:this.head};this.length===0&&(this.tail=E),this.head=E,++this.length},l.prototype.shift=function(){if(this.length!==0){var y=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,y}},l.prototype.clear=function(){this.head=this.tail=null,this.length=0},l.prototype.join=function(y){if(this.length===0)return"";for(var E=this.head,C=""+E.data;E=E.next;)C+=y+E.data;return C},l.prototype.concat=function(y){if(this.length===0)return n.alloc(0);for(var E=n.allocUnsafe(y>>>0),C=this.head,k=0;C;)u(C.data,E,k),k+=C.data.length,C=C.next;return E},l}(),o&&o.inspect&&o.inspect.custom&&(t.exports.prototype[o.inspect.custom]=function(){var l=o.inspect({length:this.length});return this.constructor.name+" "+l})}(BufferList)),BufferList.exports}var pna=processNextickArgsExports;function destroy(t,e){var n=this,o=this._readableState&&this._readableState.destroyed,u=this._writableState&&this._writableState.destroyed;return o||u?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,pna.nextTick(emitErrorNT,this,t)):pna.nextTick(emitErrorNT,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(l){!e&&l?n._writableState?n._writableState.errorEmitted||(n._writableState.errorEmitted=!0,pna.nextTick(emitErrorNT,n,l)):pna.nextTick(emitErrorNT,n,l):e&&e(l)}),this)}function undestroy(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function emitErrorNT(t,e){t.emit("error",e)}var destroy_1={destroy,undestroy},_stream_writable,hasRequired_stream_writable;function require_stream_writable(){if(hasRequired_stream_writable)return _stream_writable;hasRequired_stream_writable=1;var t=processNextickArgsExports;_stream_writable=B;function e(x){var S=this;this.next=null,this.entry=null,this.finish=function(){p(S,x)}}var n=!process$1.browser&&["v0.10","v0.9."].indexOf(process$1.version.slice(0,5))>-1?setImmediate:t.nextTick,o;B.WritableState=P;var u=Object.create(util$3);u.inherits=inherits_browserExports;var l={deprecate:requireBrowser$5()},m=streamBrowser,y=safeBufferExports.Buffer,E=(typeof commonjsGlobal$1<"u"?commonjsGlobal$1:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function C(x){return y.from(x)}function k(x){return y.isBuffer(x)||x instanceof E}var A=destroy_1;u.inherits(B,m);function D(){}function P(x,S){o=o||require_stream_duplex(),x=x||{};var b=S instanceof o;this.objectMode=!!x.objectMode,b&&(this.objectMode=this.objectMode||!!x.writableObjectMode);var h=x.highWaterMark,T=x.writableHighWaterMark,M=this.objectMode?16:16*1024;h||h===0?this.highWaterMark=h:b&&(T||T===0)?this.highWaterMark=T:this.highWaterMark=M,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var O=x.decodeStrings===!1;this.decodeStrings=!O,this.defaultEncoding=x.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(V){Q(S,V)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new e(this)}P.prototype.getBuffer=function(){for(var S=this.bufferedRequest,b=[];S;)b.push(S),S=S.next;return b},function(){try{Object.defineProperty(P.prototype,"buffer",{get:l.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var R;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(R=Function.prototype[Symbol.hasInstance],Object.defineProperty(B,Symbol.hasInstance,{value:function(x){return R.call(this,x)?!0:this!==B?!1:x&&x._writableState instanceof P}})):R=function(x){return x instanceof this};function B(x){if(o=o||require_stream_duplex(),!R.call(B,this)&&!(this instanceof o))return new B(x);this._writableState=new P(x,this),this.writable=!0,x&&(typeof x.write=="function"&&(this._write=x.write),typeof x.writev=="function"&&(this._writev=x.writev),typeof x.destroy=="function"&&(this._destroy=x.destroy),typeof x.final=="function"&&(this._final=x.final)),m.call(this)}B.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function F(x,S){var b=new Error("write after end");x.emit("error",b),t.nextTick(S,b)}function j(x,S,b,h){var T=!0,M=!1;return b===null?M=new TypeError("May not write null values to stream"):typeof b!="string"&&b!==void 0&&!S.objectMode&&(M=new TypeError("Invalid non-string/buffer chunk")),M&&(x.emit("error",M),t.nextTick(h,M),T=!1),T}B.prototype.write=function(x,S,b){var h=this._writableState,T=!1,M=!h.objectMode&&k(x);return M&&!y.isBuffer(x)&&(x=C(x)),typeof S=="function"&&(b=S,S=null),M?S="buffer":S||(S=h.defaultEncoding),typeof b!="function"&&(b=D),h.ended?F(this,b):(M||j(this,h,x,b))&&(h.pendingcb++,T=Y(this,h,M,x,S,b)),T},B.prototype.cork=function(){var x=this._writableState;x.corked++},B.prototype.uncork=function(){var x=this._writableState;x.corked&&(x.corked--,!x.writing&&!x.corked&&!x.bufferProcessing&&x.bufferedRequest&&ke(this,x))},B.prototype.setDefaultEncoding=function(S){if(typeof S=="string"&&(S=S.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((S+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+S);return this._writableState.defaultEncoding=S,this};function N(x,S,b){return!x.objectMode&&x.decodeStrings!==!1&&typeof S=="string"&&(S=y.from(S,b)),S}Object.defineProperty(B.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function Y(x,S,b,h,T,M){if(!b){var O=N(S,h,T);h!==O&&(b=!0,T="buffer",h=O)}var V=S.objectMode?1:h.length;S.length+=V;var ee=S.length<S.highWaterMark;if(ee||(S.needDrain=!0),S.writing||S.corked){var Z=S.lastBufferedRequest;S.lastBufferedRequest={chunk:h,encoding:T,isBuf:b,callback:M,next:null},Z?Z.next=S.lastBufferedRequest:S.bufferedRequest=S.lastBufferedRequest,S.bufferedRequestCount+=1}else J(x,S,!1,V,h,T,M);return ee}function J(x,S,b,h,T,M,O){S.writelen=h,S.writecb=O,S.writing=!0,S.sync=!0,b?x._writev(T,S.onwrite):x._write(T,M,S.onwrite),S.sync=!1}function ie(x,S,b,h,T){--S.pendingcb,b?(t.nextTick(T,h),t.nextTick(w,x,S),x._writableState.errorEmitted=!0,x.emit("error",h)):(T(h),x._writableState.errorEmitted=!0,x.emit("error",h),w(x,S))}function ue(x){x.writing=!1,x.writecb=null,x.length-=x.writelen,x.writelen=0}function Q(x,S){var b=x._writableState,h=b.sync,T=b.writecb;if(ue(b),S)ie(x,b,h,S,T);else{var M=L(b);!M&&!b.corked&&!b.bufferProcessing&&b.bufferedRequest&&ke(x,b),h?n(ce,x,b,M,T):ce(x,b,M,T)}}function ce(x,S,b,h){b||he(x,S),S.pendingcb--,h(),w(x,S)}function he(x,S){S.length===0&&S.needDrain&&(S.needDrain=!1,x.emit("drain"))}function ke(x,S){S.bufferProcessing=!0;var b=S.bufferedRequest;if(x._writev&&b&&b.next){var h=S.bufferedRequestCount,T=new Array(h),M=S.corkedRequestsFree;M.entry=b;for(var O=0,V=!0;b;)T[O]=b,b.isBuf||(V=!1),b=b.next,O+=1;T.allBuffers=V,J(x,S,!0,S.length,T,"",M.finish),S.pendingcb++,S.lastBufferedRequest=null,M.next?(S.corkedRequestsFree=M.next,M.next=null):S.corkedRequestsFree=new e(S),S.bufferedRequestCount=0}else{for(;b;){var ee=b.chunk,Z=b.encoding,U=b.callback,z=S.objectMode?1:ee.length;if(J(x,S,!1,z,ee,Z,U),b=b.next,S.bufferedRequestCount--,S.writing)break}b===null&&(S.lastBufferedRequest=null)}S.bufferedRequest=b,S.bufferProcessing=!1}B.prototype._write=function(x,S,b){b(new Error("_write() is not implemented"))},B.prototype._writev=null,B.prototype.end=function(x,S,b){var h=this._writableState;typeof x=="function"?(b=x,x=null,S=null):typeof S=="function"&&(b=S,S=null),x!=null&&this.write(x,S),h.corked&&(h.corked=1,this.uncork()),h.ending||c(this,h,b)};function L(x){return x.ending&&x.length===0&&x.bufferedRequest===null&&!x.finished&&!x.writing}function d(x,S){x._final(function(b){S.pendingcb--,b&&x.emit("error",b),S.prefinished=!0,x.emit("prefinish"),w(x,S)})}function v(x,S){!S.prefinished&&!S.finalCalled&&(typeof x._final=="function"?(S.pendingcb++,S.finalCalled=!0,t.nextTick(d,x,S)):(S.prefinished=!0,x.emit("prefinish")))}function w(x,S){var b=L(S);return b&&(v(x,S),S.pendingcb===0&&(S.finished=!0,x.emit("finish"))),b}function c(x,S,b){S.ending=!0,w(x,S),b&&(S.finished?t.nextTick(b):x.once("finish",b)),S.ended=!0,x.writable=!1}function p(x,S,b){var h=x.entry;for(x.entry=null;h;){var T=h.callback;S.pendingcb--,T(b),h=h.next}S.corkedRequestsFree.next=x}return Object.defineProperty(B.prototype,"destroyed",{get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(x){this._writableState&&(this._writableState.destroyed=x)}}),B.prototype.destroy=A.destroy,B.prototype._undestroy=A.undestroy,B.prototype._destroy=function(x,S){this.end(),S(x)},_stream_writable}var _stream_duplex,hasRequired_stream_duplex;function require_stream_duplex(){if(hasRequired_stream_duplex)return _stream_duplex;hasRequired_stream_duplex=1;var t=processNextickArgsExports,e=Object.keys||function(A){var D=[];for(var P in A)D.push(P);return D};_stream_duplex=E;var n=Object.create(util$3);n.inherits=inherits_browserExports;var o=require_stream_readable(),u=require_stream_writable();n.inherits(E,o);for(var l=e(u.prototype),m=0;m<l.length;m++){var y=l[m];E.prototype[y]||(E.prototype[y]=u.prototype[y])}function E(A){if(!(this instanceof E))return new E(A);o.call(this,A),u.call(this,A),A&&A.readable===!1&&(this.readable=!1),A&&A.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,A&&A.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",C)}Object.defineProperty(E.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function C(){this.allowHalfOpen||this._writableState.ended||t.nextTick(k,this)}function k(A){A.end()}return Object.defineProperty(E.prototype,"destroyed",{get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(A){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=A,this._writableState.destroyed=A)}}),E.prototype._destroy=function(A,D){this.push(null),this.end(),t.nextTick(D,A)},_stream_duplex}var _stream_readable,hasRequired_stream_readable;function require_stream_readable(){if(hasRequired_stream_readable)return _stream_readable;hasRequired_stream_readable=1;var t=processNextickArgsExports;_stream_readable=N;var e=isarray,n;N.ReadableState=j,requireEvents().EventEmitter;var o=function(U,z){return U.listeners(z).length},u=streamBrowser,l=safeBufferExports.Buffer,m=(typeof commonjsGlobal$1<"u"?commonjsGlobal$1:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function y(U){return l.from(U)}function E(U){return l.isBuffer(U)||U instanceof m}var C=Object.create(util$3);C.inherits=inherits_browserExports;var k=util$6,A=void 0;k&&k.debuglog?A=k.debuglog("stream"):A=function(){};var D=requireBufferList(),P=destroy_1,R;C.inherits(N,u);var B=["error","close","destroy","pause","resume"];function F(U,z,ne){if(typeof U.prependListener=="function")return U.prependListener(z,ne);!U._events||!U._events[z]?U.on(z,ne):e(U._events[z])?U._events[z].unshift(ne):U._events[z]=[ne,U._events[z]]}function j(U,z){n=n||require_stream_duplex(),U=U||{};var ne=z instanceof n;this.objectMode=!!U.objectMode,ne&&(this.objectMode=this.objectMode||!!U.readableObjectMode);var fe=U.highWaterMark,me=U.readableHighWaterMark,de=this.objectMode?16:16*1024;fe||fe===0?this.highWaterMark=fe:ne&&(me||me===0)?this.highWaterMark=me:this.highWaterMark=de,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new D,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=U.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,U.encoding&&(R||(R=string_decoder.StringDecoder),this.decoder=new R(U.encoding),this.encoding=U.encoding)}function N(U){if(n=n||require_stream_duplex(),!(this instanceof N))return new N(U);this._readableState=new j(U,this),this.readable=!0,U&&(typeof U.read=="function"&&(this._read=U.read),typeof U.destroy=="function"&&(this._destroy=U.destroy)),u.call(this)}Object.defineProperty(N.prototype,"destroyed",{get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(U){this._readableState&&(this._readableState.destroyed=U)}}),N.prototype.destroy=P.destroy,N.prototype._undestroy=P.undestroy,N.prototype._destroy=function(U,z){this.push(null),z(U)},N.prototype.push=function(U,z){var ne=this._readableState,fe;return ne.objectMode?fe=!0:typeof U=="string"&&(z=z||ne.defaultEncoding,z!==ne.encoding&&(U=l.from(U,z),z=""),fe=!0),Y(this,U,z,!1,fe)},N.prototype.unshift=function(U){return Y(this,U,null,!0,!1)};function Y(U,z,ne,fe,me){var de=U._readableState;if(z===null)de.reading=!1,ke(U,de);else{var je;me||(je=ie(de,z)),je?U.emit("error",je):de.objectMode||z&&z.length>0?(typeof z!="string"&&!de.objectMode&&Object.getPrototypeOf(z)!==l.prototype&&(z=y(z)),fe?de.endEmitted?U.emit("error",new Error("stream.unshift() after end event")):J(U,de,z,!0):de.ended?U.emit("error",new Error("stream.push() after EOF")):(de.reading=!1,de.decoder&&!ne?(z=de.decoder.write(z),de.objectMode||z.length!==0?J(U,de,z,!1):v(U,de)):J(U,de,z,!1))):fe||(de.reading=!1)}return ue(de)}function J(U,z,ne,fe){z.flowing&&z.length===0&&!z.sync?(U.emit("data",ne),U.read(0)):(z.length+=z.objectMode?1:ne.length,fe?z.buffer.unshift(ne):z.buffer.push(ne),z.needReadable&&L(U)),v(U,z)}function ie(U,z){var ne;return!E(z)&&typeof z!="string"&&z!==void 0&&!U.objectMode&&(ne=new TypeError("Invalid non-string/buffer chunk")),ne}function ue(U){return!U.ended&&(U.needReadable||U.length<U.highWaterMark||U.length===0)}N.prototype.isPaused=function(){return this._readableState.flowing===!1},N.prototype.setEncoding=function(U){return R||(R=string_decoder.StringDecoder),this._readableState.decoder=new R(U),this._readableState.encoding=U,this};var Q=8388608;function ce(U){return U>=Q?U=Q:(U--,U|=U>>>1,U|=U>>>2,U|=U>>>4,U|=U>>>8,U|=U>>>16,U++),U}function he(U,z){return U<=0||z.length===0&&z.ended?0:z.objectMode?1:U!==U?z.flowing&&z.length?z.buffer.head.data.length:z.length:(U>z.highWaterMark&&(z.highWaterMark=ce(U)),U<=z.length?U:z.ended?z.length:(z.needReadable=!0,0))}N.prototype.read=function(U){A("read",U),U=parseInt(U,10);var z=this._readableState,ne=U;if(U!==0&&(z.emittedReadable=!1),U===0&&z.needReadable&&(z.length>=z.highWaterMark||z.ended))return A("read: emitReadable",z.length,z.ended),z.length===0&&z.ended?V(this):L(this),null;if(U=he(U,z),U===0&&z.ended)return z.length===0&&V(this),null;var fe=z.needReadable;A("need readable",fe),(z.length===0||z.length-U<z.highWaterMark)&&(fe=!0,A("length less than watermark",fe)),z.ended||z.reading?(fe=!1,A("reading or ended",fe)):fe&&(A("do read"),z.reading=!0,z.sync=!0,z.length===0&&(z.needReadable=!0),this._read(z.highWaterMark),z.sync=!1,z.reading||(U=he(ne,z)));var me;return U>0?me=h(U,z):me=null,me===null?(z.needReadable=!0,U=0):z.length-=U,z.length===0&&(z.ended||(z.needReadable=!0),ne!==U&&z.ended&&V(this)),me!==null&&this.emit("data",me),me};function ke(U,z){if(!z.ended){if(z.decoder){var ne=z.decoder.end();ne&&ne.length&&(z.buffer.push(ne),z.length+=z.objectMode?1:ne.length)}z.ended=!0,L(U)}}function L(U){var z=U._readableState;z.needReadable=!1,z.emittedReadable||(A("emitReadable",z.flowing),z.emittedReadable=!0,z.sync?t.nextTick(d,U):d(U))}function d(U){A("emit readable"),U.emit("readable"),b(U)}function v(U,z){z.readingMore||(z.readingMore=!0,t.nextTick(w,U,z))}function w(U,z){for(var ne=z.length;!z.reading&&!z.flowing&&!z.ended&&z.length<z.highWaterMark&&(A("maybeReadMore read 0"),U.read(0),ne!==z.length);)ne=z.length;z.readingMore=!1}N.prototype._read=function(U){this.emit("error",new Error("_read() is not implemented"))},N.prototype.pipe=function(U,z){var ne=this,fe=this._readableState;switch(fe.pipesCount){case 0:fe.pipes=U;break;case 1:fe.pipes=[fe.pipes,U];break;default:fe.pipes.push(U);break}fe.pipesCount+=1,A("pipe count=%d opts=%j",fe.pipesCount,z);var me=(!z||z.end!==!1)&&U!==process$1.stdout&&U!==process$1.stderr,de=me?lt:Ot;fe.endEmitted?t.nextTick(de):ne.once("end",de),U.on("unpipe",je);function je(Ve,We){A("onunpipe"),Ve===ne&&We&&We.hasUnpiped===!1&&(We.hasUnpiped=!0,Ct())}function lt(){A("onend"),U.end()}var it=c(ne);U.on("drain",it);var ot=!1;function Ct(){A("cleanup"),U.removeListener("close",rt),U.removeListener("finish",ht),U.removeListener("drain",it),U.removeListener("error",tt),U.removeListener("unpipe",je),ne.removeListener("end",lt),ne.removeListener("end",Ot),ne.removeListener("data",Je),ot=!0,fe.awaitDrain&&(!U._writableState||U._writableState.needDrain)&&it()}var nt=!1;ne.on("data",Je);function Je(Ve){A("ondata"),nt=!1;var We=U.write(Ve);We===!1&&!nt&&((fe.pipesCount===1&&fe.pipes===U||fe.pipesCount>1&&Z(fe.pipes,U)!==-1)&&!ot&&(A("false write response, pause",fe.awaitDrain),fe.awaitDrain++,nt=!0),ne.pause())}function tt(Ve){A("onerror",Ve),Ot(),U.removeListener("error",tt),o(U,"error")===0&&U.emit("error",Ve)}F(U,"error",tt);function rt(){U.removeListener("finish",ht),Ot()}U.once("close",rt);function ht(){A("onfinish"),U.removeListener("close",rt),Ot()}U.once("finish",ht);function Ot(){A("unpipe"),ne.unpipe(U)}return U.emit("pipe",ne),fe.flowing||(A("pipe resume"),ne.resume()),U};function c(U){return function(){var z=U._readableState;A("pipeOnDrain",z.awaitDrain),z.awaitDrain&&z.awaitDrain--,z.awaitDrain===0&&o(U,"data")&&(z.flowing=!0,b(U))}}N.prototype.unpipe=function(U){var z=this._readableState,ne={hasUnpiped:!1};if(z.pipesCount===0)return this;if(z.pipesCount===1)return U&&U!==z.pipes?this:(U||(U=z.pipes),z.pipes=null,z.pipesCount=0,z.flowing=!1,U&&U.emit("unpipe",this,ne),this);if(!U){var fe=z.pipes,me=z.pipesCount;z.pipes=null,z.pipesCount=0,z.flowing=!1;for(var de=0;de<me;de++)fe[de].emit("unpipe",this,{hasUnpiped:!1});return this}var je=Z(z.pipes,U);return je===-1?this:(z.pipes.splice(je,1),z.pipesCount-=1,z.pipesCount===1&&(z.pipes=z.pipes[0]),U.emit("unpipe",this,ne),this)},N.prototype.on=function(U,z){var ne=u.prototype.on.call(this,U,z);if(U==="data")this._readableState.flowing!==!1&&this.resume();else if(U==="readable"){var fe=this._readableState;!fe.endEmitted&&!fe.readableListening&&(fe.readableListening=fe.needReadable=!0,fe.emittedReadable=!1,fe.reading?fe.length&&L(this):t.nextTick(p,this))}return ne},N.prototype.addListener=N.prototype.on;function p(U){A("readable nexttick read 0"),U.read(0)}N.prototype.resume=function(){var U=this._readableState;return U.flowing||(A("resume"),U.flowing=!0,x(this,U)),this};function x(U,z){z.resumeScheduled||(z.resumeScheduled=!0,t.nextTick(S,U,z))}function S(U,z){z.reading||(A("resume read 0"),U.read(0)),z.resumeScheduled=!1,z.awaitDrain=0,U.emit("resume"),b(U),z.flowing&&!z.reading&&U.read(0)}N.prototype.pause=function(){return A("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(A("pause"),this._readableState.flowing=!1,this.emit("pause")),this};function b(U){var z=U._readableState;for(A("flow",z.flowing);z.flowing&&U.read()!==null;);}N.prototype.wrap=function(U){var z=this,ne=this._readableState,fe=!1;U.on("end",function(){if(A("wrapped end"),ne.decoder&&!ne.ended){var je=ne.decoder.end();je&&je.length&&z.push(je)}z.push(null)}),U.on("data",function(je){if(A("wrapped data"),ne.decoder&&(je=ne.decoder.write(je)),!(ne.objectMode&&je==null)&&!(!ne.objectMode&&(!je||!je.length))){var lt=z.push(je);lt||(fe=!0,U.pause())}});for(var me in U)this[me]===void 0&&typeof U[me]=="function"&&(this[me]=function(je){return function(){return U[je].apply(U,arguments)}}(me));for(var de=0;de<B.length;de++)U.on(B[de],this.emit.bind(this,B[de]));return this._read=function(je){A("wrapped _read",je),fe&&(fe=!1,U.resume())},this},Object.defineProperty(N.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),N._fromList=h;function h(U,z){if(z.length===0)return null;var ne;return z.objectMode?ne=z.buffer.shift():!U||U>=z.length?(z.decoder?ne=z.buffer.join(""):z.buffer.length===1?ne=z.buffer.head.data:ne=z.buffer.concat(z.length),z.buffer.clear()):ne=T(U,z.buffer,z.decoder),ne}function T(U,z,ne){var fe;return U<z.head.data.length?(fe=z.head.data.slice(0,U),z.head.data=z.head.data.slice(U)):U===z.head.data.length?fe=z.shift():fe=ne?M(U,z):O(U,z),fe}function M(U,z){var ne=z.head,fe=1,me=ne.data;for(U-=me.length;ne=ne.next;){var de=ne.data,je=U>de.length?de.length:U;if(je===de.length?me+=de:me+=de.slice(0,U),U-=je,U===0){je===de.length?(++fe,ne.next?z.head=ne.next:z.head=z.tail=null):(z.head=ne,ne.data=de.slice(je));break}++fe}return z.length-=fe,me}function O(U,z){var ne=l.allocUnsafe(U),fe=z.head,me=1;for(fe.data.copy(ne),U-=fe.data.length;fe=fe.next;){var de=fe.data,je=U>de.length?de.length:U;if(de.copy(ne,ne.length-U,0,je),U-=je,U===0){je===de.length?(++me,fe.next?z.head=fe.next:z.head=z.tail=null):(z.head=fe,fe.data=de.slice(je));break}++me}return z.length-=me,ne}function V(U){var z=U._readableState;if(z.length>0)throw new Error('"endReadable()" called on non-empty stream');z.endEmitted||(z.ended=!0,t.nextTick(ee,z,U))}function ee(U,z){!U.endEmitted&&U.length===0&&(U.endEmitted=!0,z.readable=!1,z.emit("end"))}function Z(U,z){for(var ne=0,fe=U.length;ne<fe;ne++)if(U[ne]===z)return ne;return-1}return _stream_readable}var _stream_transform=Transform$1,Duplex=require_stream_duplex(),util$2=Object.create(util$3);util$2.inherits=inherits_browserExports,util$2.inherits(Transform$1,Duplex);function afterTransform(t,e){var n=this._transformState;n.transforming=!1;var o=n.writecb;if(!o)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,e!=null&&this.push(e),o(t);var u=this._readableState;u.reading=!1,(u.needReadable||u.length<u.highWaterMark)&&this._read(u.highWaterMark)}function Transform$1(t){if(!(this instanceof Transform$1))return new Transform$1(t);Duplex.call(this,t),this._transformState={afterTransform:afterTransform.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&(typeof t.transform=="function"&&(this._transform=t.transform),typeof t.flush=="function"&&(this._flush=t.flush)),this.on("prefinish",prefinish)}function prefinish(){var t=this;typeof this._flush=="function"?this._flush(function(e,n){done(t,e,n)}):done(this,null,null)}Transform$1.prototype.push=function(t,e){return this._transformState.needTransform=!1,Duplex.prototype.push.call(this,t,e)},Transform$1.prototype._transform=function(t,e,n){throw new Error("_transform() is not implemented")},Transform$1.prototype._write=function(t,e,n){var o=this._transformState;if(o.writecb=n,o.writechunk=t,o.writeencoding=e,!o.transforming){var u=this._readableState;(o.needTransform||u.needReadable||u.length<u.highWaterMark)&&this._read(u.highWaterMark)}},Transform$1.prototype._read=function(t){var e=this._transformState;e.writechunk!==null&&e.writecb&&!e.transforming?(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform)):e.needTransform=!0},Transform$1.prototype._destroy=function(t,e){var n=this;Duplex.prototype._destroy.call(this,t,function(o){e(o),n.emit("close")})};function done(t,e,n){if(e)return t.emit("error",e);if(n!=null&&t.push(n),t._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(t._transformState.transforming)throw new Error("Calling transform done when still transforming");return t.push(null)}var _stream_passthrough=PassThrough,Transform=_stream_transform,util$1=Object.create(util$3);util$1.inherits=inherits_browserExports,util$1.inherits(PassThrough,Transform);function PassThrough(t){if(!(this instanceof PassThrough))return new PassThrough(t);Transform.call(this,t)}PassThrough.prototype._transform=function(t,e,n){n(null,t)},function(t,e){e=t.exports=require_stream_readable(),e.Stream=e,e.Readable=e,e.Writable=require_stream_writable(),e.Duplex=require_stream_duplex(),e.Transform=_stream_transform,e.PassThrough=_stream_passthrough}(readableBrowser$1,readableBrowser$1.exports);var readableBrowserExports=readableBrowser$1.exports,sign={exports:{}},bn$4={exports:{}};bn$4.exports,function(t){(function(e,n){function o(v,w){if(!v)throw new Error(w||"Assertion failed")}function u(v,w){v.super_=w;var c=function(){};c.prototype=w.prototype,v.prototype=new c,v.prototype.constructor=v}function l(v,w,c){if(l.isBN(v))return v;this.negative=0,this.words=null,this.length=0,this.red=null,v!==null&&((w==="le"||w==="be")&&(c=w,w=10),this._init(v||0,w||10,c||"be"))}typeof e=="object"?e.exports=l:n.BN=l,l.BN=l,l.wordSize=26;var m;try{typeof window<"u"&&typeof window.Buffer<"u"?m=window.Buffer:m=require$$0$2.Buffer}catch{}l.isBN=function(w){return w instanceof l?!0:w!==null&&typeof w=="object"&&w.constructor.wordSize===l.wordSize&&Array.isArray(w.words)},l.max=function(w,c){return w.cmp(c)>0?w:c},l.min=function(w,c){return w.cmp(c)<0?w:c},l.prototype._init=function(w,c,p){if(typeof w=="number")return this._initNumber(w,c,p);if(typeof w=="object")return this._initArray(w,c,p);c==="hex"&&(c=16),o(c===(c|0)&&c>=2&&c<=36),w=w.toString().replace(/\s+/g,"");var x=0;w[0]==="-"&&(x++,this.negative=1),x<w.length&&(c===16?this._parseHex(w,x,p):(this._parseBase(w,c,x),p==="le"&&this._initArray(this.toArray(),c,p)))},l.prototype._initNumber=function(w,c,p){w<0&&(this.negative=1,w=-w),w<67108864?(this.words=[w&67108863],this.length=1):w<4503599627370496?(this.words=[w&67108863,w/67108864&67108863],this.length=2):(o(w<9007199254740992),this.words=[w&67108863,w/67108864&67108863,1],this.length=3),p==="le"&&this._initArray(this.toArray(),c,p)},l.prototype._initArray=function(w,c,p){if(o(typeof w.length=="number"),w.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(w.length/3),this.words=new Array(this.length);for(var x=0;x<this.length;x++)this.words[x]=0;var S,b,h=0;if(p==="be")for(x=w.length-1,S=0;x>=0;x-=3)b=w[x]|w[x-1]<<8|w[x-2]<<16,this.words[S]|=b<<h&67108863,this.words[S+1]=b>>>26-h&67108863,h+=24,h>=26&&(h-=26,S++);else if(p==="le")for(x=0,S=0;x<w.length;x+=3)b=w[x]|w[x+1]<<8|w[x+2]<<16,this.words[S]|=b<<h&67108863,this.words[S+1]=b>>>26-h&67108863,h+=24,h>=26&&(h-=26,S++);return this._strip()};function y(v,w){var c=v.charCodeAt(w);if(c>=48&&c<=57)return c-48;if(c>=65&&c<=70)return c-55;if(c>=97&&c<=102)return c-87;o(!1,"Invalid character in "+v)}function E(v,w,c){var p=y(v,c);return c-1>=w&&(p|=y(v,c-1)<<4),p}l.prototype._parseHex=function(w,c,p){this.length=Math.ceil((w.length-c)/6),this.words=new Array(this.length);for(var x=0;x<this.length;x++)this.words[x]=0;var S=0,b=0,h;if(p==="be")for(x=w.length-1;x>=c;x-=2)h=E(w,c,x)<<S,this.words[b]|=h&67108863,S>=18?(S-=18,b+=1,this.words[b]|=h>>>26):S+=8;else{var T=w.length-c;for(x=T%2===0?c+1:c;x<w.length;x+=2)h=E(w,c,x)<<S,this.words[b]|=h&67108863,S>=18?(S-=18,b+=1,this.words[b]|=h>>>26):S+=8}this._strip()};function C(v,w,c,p){for(var x=0,S=0,b=Math.min(v.length,c),h=w;h<b;h++){var T=v.charCodeAt(h)-48;x*=p,T>=49?S=T-49+10:T>=17?S=T-17+10:S=T,o(T>=0&&S<p,"Invalid character"),x+=S}return x}l.prototype._parseBase=function(w,c,p){this.words=[0],this.length=1;for(var x=0,S=1;S<=67108863;S*=c)x++;x--,S=S/c|0;for(var b=w.length-p,h=b%x,T=Math.min(b,b-h)+p,M=0,O=p;O<T;O+=x)M=C(w,O,O+x,c),this.imuln(S),this.words[0]+M<67108864?this.words[0]+=M:this._iaddn(M);if(h!==0){var V=1;for(M=C(w,O,w.length,c),O=0;O<h;O++)V*=c;this.imuln(V),this.words[0]+M<67108864?this.words[0]+=M:this._iaddn(M)}this._strip()},l.prototype.copy=function(w){w.words=new Array(this.length);for(var c=0;c<this.length;c++)w.words[c]=this.words[c];w.length=this.length,w.negative=this.negative,w.red=this.red};function k(v,w){v.words=w.words,v.length=w.length,v.negative=w.negative,v.red=w.red}if(l.prototype._move=function(w){k(w,this)},l.prototype.clone=function(){var w=new l(null);return this.copy(w),w},l.prototype._expand=function(w){for(;this.length<w;)this.words[this.length++]=0;return this},l.prototype._strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},l.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{l.prototype[Symbol.for("nodejs.util.inspect.custom")]=A}catch{l.prototype.inspect=A}else l.prototype.inspect=A;function A(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var D=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],P=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],R=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];l.prototype.toString=function(w,c){w=w||10,c=c|0||1;var p;if(w===16||w==="hex"){p="";for(var x=0,S=0,b=0;b<this.length;b++){var h=this.words[b],T=((h<<x|S)&16777215).toString(16);S=h>>>24-x&16777215,x+=2,x>=26&&(x-=26,b--),S!==0||b!==this.length-1?p=D[6-T.length]+T+p:p=T+p}for(S!==0&&(p=S.toString(16)+p);p.length%c!==0;)p="0"+p;return this.negative!==0&&(p="-"+p),p}if(w===(w|0)&&w>=2&&w<=36){var M=P[w],O=R[w];p="";var V=this.clone();for(V.negative=0;!V.isZero();){var ee=V.modrn(O).toString(w);V=V.idivn(O),V.isZero()?p=ee+p:p=D[M-ee.length]+ee+p}for(this.isZero()&&(p="0"+p);p.length%c!==0;)p="0"+p;return this.negative!==0&&(p="-"+p),p}o(!1,"Base should be between 2 and 36")},l.prototype.toNumber=function(){var w=this.words[0];return this.length===2?w+=this.words[1]*67108864:this.length===3&&this.words[2]===1?w+=4503599627370496+this.words[1]*67108864:this.length>2&&o(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-w:w},l.prototype.toJSON=function(){return this.toString(16,2)},m&&(l.prototype.toBuffer=function(w,c){return this.toArrayLike(m,w,c)}),l.prototype.toArray=function(w,c){return this.toArrayLike(Array,w,c)};var B=function(w,c){return w.allocUnsafe?w.allocUnsafe(c):new w(c)};l.prototype.toArrayLike=function(w,c,p){this._strip();var x=this.byteLength(),S=p||Math.max(1,x);o(x<=S,"byte array longer than desired length"),o(S>0,"Requested array length <= 0");var b=B(w,S),h=c==="le"?"LE":"BE";return this["_toArrayLike"+h](b,x),b},l.prototype._toArrayLikeLE=function(w,c){for(var p=0,x=0,S=0,b=0;S<this.length;S++){var h=this.words[S]<<b|x;w[p++]=h&255,p<w.length&&(w[p++]=h>>8&255),p<w.length&&(w[p++]=h>>16&255),b===6?(p<w.length&&(w[p++]=h>>24&255),x=0,b=0):(x=h>>>24,b+=2)}if(p<w.length)for(w[p++]=x;p<w.length;)w[p++]=0},l.prototype._toArrayLikeBE=function(w,c){for(var p=w.length-1,x=0,S=0,b=0;S<this.length;S++){var h=this.words[S]<<b|x;w[p--]=h&255,p>=0&&(w[p--]=h>>8&255),p>=0&&(w[p--]=h>>16&255),b===6?(p>=0&&(w[p--]=h>>24&255),x=0,b=0):(x=h>>>24,b+=2)}if(p>=0)for(w[p--]=x;p>=0;)w[p--]=0},Math.clz32?l.prototype._countBits=function(w){return 32-Math.clz32(w)}:l.prototype._countBits=function(w){var c=w,p=0;return c>=4096&&(p+=13,c>>>=13),c>=64&&(p+=7,c>>>=7),c>=8&&(p+=4,c>>>=4),c>=2&&(p+=2,c>>>=2),p+c},l.prototype._zeroBits=function(w){if(w===0)return 26;var c=w,p=0;return c&8191||(p+=13,c>>>=13),c&127||(p+=7,c>>>=7),c&15||(p+=4,c>>>=4),c&3||(p+=2,c>>>=2),c&1||p++,p},l.prototype.bitLength=function(){var w=this.words[this.length-1],c=this._countBits(w);return(this.length-1)*26+c};function F(v){for(var w=new Array(v.bitLength()),c=0;c<w.length;c++){var p=c/26|0,x=c%26;w[c]=v.words[p]>>>x&1}return w}l.prototype.zeroBits=function(){if(this.isZero())return 0;for(var w=0,c=0;c<this.length;c++){var p=this._zeroBits(this.words[c]);if(w+=p,p!==26)break}return w},l.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},l.prototype.toTwos=function(w){return this.negative!==0?this.abs().inotn(w).iaddn(1):this.clone()},l.prototype.fromTwos=function(w){return this.testn(w-1)?this.notn(w).iaddn(1).ineg():this.clone()},l.prototype.isNeg=function(){return this.negative!==0},l.prototype.neg=function(){return this.clone().ineg()},l.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},l.prototype.iuor=function(w){for(;this.length<w.length;)this.words[this.length++]=0;for(var c=0;c<w.length;c++)this.words[c]=this.words[c]|w.words[c];return this._strip()},l.prototype.ior=function(w){return o((this.negative|w.negative)===0),this.iuor(w)},l.prototype.or=function(w){return this.length>w.length?this.clone().ior(w):w.clone().ior(this)},l.prototype.uor=function(w){return this.length>w.length?this.clone().iuor(w):w.clone().iuor(this)},l.prototype.iuand=function(w){var c;this.length>w.length?c=w:c=this;for(var p=0;p<c.length;p++)this.words[p]=this.words[p]&w.words[p];return this.length=c.length,this._strip()},l.prototype.iand=function(w){return o((this.negative|w.negative)===0),this.iuand(w)},l.prototype.and=function(w){return this.length>w.length?this.clone().iand(w):w.clone().iand(this)},l.prototype.uand=function(w){return this.length>w.length?this.clone().iuand(w):w.clone().iuand(this)},l.prototype.iuxor=function(w){var c,p;this.length>w.length?(c=this,p=w):(c=w,p=this);for(var x=0;x<p.length;x++)this.words[x]=c.words[x]^p.words[x];if(this!==c)for(;x<c.length;x++)this.words[x]=c.words[x];return this.length=c.length,this._strip()},l.prototype.ixor=function(w){return o((this.negative|w.negative)===0),this.iuxor(w)},l.prototype.xor=function(w){return this.length>w.length?this.clone().ixor(w):w.clone().ixor(this)},l.prototype.uxor=function(w){return this.length>w.length?this.clone().iuxor(w):w.clone().iuxor(this)},l.prototype.inotn=function(w){o(typeof w=="number"&&w>=0);var c=Math.ceil(w/26)|0,p=w%26;this._expand(c),p>0&&c--;for(var x=0;x<c;x++)this.words[x]=~this.words[x]&67108863;return p>0&&(this.words[x]=~this.words[x]&67108863>>26-p),this._strip()},l.prototype.notn=function(w){return this.clone().inotn(w)},l.prototype.setn=function(w,c){o(typeof w=="number"&&w>=0);var p=w/26|0,x=w%26;return this._expand(p+1),c?this.words[p]=this.words[p]|1<<x:this.words[p]=this.words[p]&~(1<<x),this._strip()},l.prototype.iadd=function(w){var c;if(this.negative!==0&&w.negative===0)return this.negative=0,c=this.isub(w),this.negative^=1,this._normSign();if(this.negative===0&&w.negative!==0)return w.negative=0,c=this.isub(w),w.negative=1,c._normSign();var p,x;this.length>w.length?(p=this,x=w):(p=w,x=this);for(var S=0,b=0;b<x.length;b++)c=(p.words[b]|0)+(x.words[b]|0)+S,this.words[b]=c&67108863,S=c>>>26;for(;S!==0&&b<p.length;b++)c=(p.words[b]|0)+S,this.words[b]=c&67108863,S=c>>>26;if(this.length=p.length,S!==0)this.words[this.length]=S,this.length++;else if(p!==this)for(;b<p.length;b++)this.words[b]=p.words[b];return this},l.prototype.add=function(w){var c;return w.negative!==0&&this.negative===0?(w.negative=0,c=this.sub(w),w.negative^=1,c):w.negative===0&&this.negative!==0?(this.negative=0,c=w.sub(this),this.negative=1,c):this.length>w.length?this.clone().iadd(w):w.clone().iadd(this)},l.prototype.isub=function(w){if(w.negative!==0){w.negative=0;var c=this.iadd(w);return w.negative=1,c._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(w),this.negative=1,this._normSign();var p=this.cmp(w);if(p===0)return this.negative=0,this.length=1,this.words[0]=0,this;var x,S;p>0?(x=this,S=w):(x=w,S=this);for(var b=0,h=0;h<S.length;h++)c=(x.words[h]|0)-(S.words[h]|0)+b,b=c>>26,this.words[h]=c&67108863;for(;b!==0&&h<x.length;h++)c=(x.words[h]|0)+b,b=c>>26,this.words[h]=c&67108863;if(b===0&&h<x.length&&x!==this)for(;h<x.length;h++)this.words[h]=x.words[h];return this.length=Math.max(this.length,h),x!==this&&(this.negative=1),this._strip()},l.prototype.sub=function(w){return this.clone().isub(w)};function j(v,w,c){c.negative=w.negative^v.negative;var p=v.length+w.length|0;c.length=p,p=p-1|0;var x=v.words[0]|0,S=w.words[0]|0,b=x*S,h=b&67108863,T=b/67108864|0;c.words[0]=h;for(var M=1;M<p;M++){for(var O=T>>>26,V=T&67108863,ee=Math.min(M,w.length-1),Z=Math.max(0,M-v.length+1);Z<=ee;Z++){var U=M-Z|0;x=v.words[U]|0,S=w.words[Z]|0,b=x*S+V,O+=b/67108864|0,V=b&67108863}c.words[M]=V|0,T=O|0}return T!==0?c.words[M]=T|0:c.length--,c._strip()}var N=function(w,c,p){var x=w.words,S=c.words,b=p.words,h=0,T,M,O,V=x[0]|0,ee=V&8191,Z=V>>>13,U=x[1]|0,z=U&8191,ne=U>>>13,fe=x[2]|0,me=fe&8191,de=fe>>>13,je=x[3]|0,lt=je&8191,it=je>>>13,ot=x[4]|0,Ct=ot&8191,nt=ot>>>13,Je=x[5]|0,tt=Je&8191,rt=Je>>>13,ht=x[6]|0,Ot=ht&8191,Ve=ht>>>13,We=x[7]|0,Gt=We&8191,wt=We>>>13,Et=x[8]|0,Yt=Et&8191,Ce=Et>>>13,te=x[9]|0,ye=te&8191,Le=te>>>13,Ue=S[0]|0,Qe=Ue&8191,Ke=Ue>>>13,De=S[1]|0,Vt=De&8191,At=De>>>13,ve=S[2]|0,Pt=ve&8191,pt=ve>>>13,Ne=S[3]|0,vt=Ne&8191,ut=Ne>>>13,$t=S[4]|0,fi=$t&8191,kt=$t>>>13,Wt=S[5]|0,Zi=Wt&8191,Ut=Wt>>>13,Xt=S[6]|0,Be=Xt&8191,be=Xt>>>13,ge=S[7]|0,oe=ge&8191,Ae=ge>>>13,qe=S[8]|0,bt=qe&8191,at=qe>>>13,gt=S[9]|0,ei=gt&8191,ii=gt>>>13;p.negative=w.negative^c.negative,p.length=19,T=Math.imul(ee,Qe),M=Math.imul(ee,Ke),M=M+Math.imul(Z,Qe)|0,O=Math.imul(Z,Ke);var Bi=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Bi>>>26)|0,Bi&=67108863,T=Math.imul(z,Qe),M=Math.imul(z,Ke),M=M+Math.imul(ne,Qe)|0,O=Math.imul(ne,Ke),T=T+Math.imul(ee,Vt)|0,M=M+Math.imul(ee,At)|0,M=M+Math.imul(Z,Vt)|0,O=O+Math.imul(Z,At)|0;var hi=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(hi>>>26)|0,hi&=67108863,T=Math.imul(me,Qe),M=Math.imul(me,Ke),M=M+Math.imul(de,Qe)|0,O=Math.imul(de,Ke),T=T+Math.imul(z,Vt)|0,M=M+Math.imul(z,At)|0,M=M+Math.imul(ne,Vt)|0,O=O+Math.imul(ne,At)|0,T=T+Math.imul(ee,Pt)|0,M=M+Math.imul(ee,pt)|0,M=M+Math.imul(Z,Pt)|0,O=O+Math.imul(Z,pt)|0;var Di=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Di>>>26)|0,Di&=67108863,T=Math.imul(lt,Qe),M=Math.imul(lt,Ke),M=M+Math.imul(it,Qe)|0,O=Math.imul(it,Ke),T=T+Math.imul(me,Vt)|0,M=M+Math.imul(me,At)|0,M=M+Math.imul(de,Vt)|0,O=O+Math.imul(de,At)|0,T=T+Math.imul(z,Pt)|0,M=M+Math.imul(z,pt)|0,M=M+Math.imul(ne,Pt)|0,O=O+Math.imul(ne,pt)|0,T=T+Math.imul(ee,vt)|0,M=M+Math.imul(ee,ut)|0,M=M+Math.imul(Z,vt)|0,O=O+Math.imul(Z,ut)|0;var ni=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(ni>>>26)|0,ni&=67108863,T=Math.imul(Ct,Qe),M=Math.imul(Ct,Ke),M=M+Math.imul(nt,Qe)|0,O=Math.imul(nt,Ke),T=T+Math.imul(lt,Vt)|0,M=M+Math.imul(lt,At)|0,M=M+Math.imul(it,Vt)|0,O=O+Math.imul(it,At)|0,T=T+Math.imul(me,Pt)|0,M=M+Math.imul(me,pt)|0,M=M+Math.imul(de,Pt)|0,O=O+Math.imul(de,pt)|0,T=T+Math.imul(z,vt)|0,M=M+Math.imul(z,ut)|0,M=M+Math.imul(ne,vt)|0,O=O+Math.imul(ne,ut)|0,T=T+Math.imul(ee,fi)|0,M=M+Math.imul(ee,kt)|0,M=M+Math.imul(Z,fi)|0,O=O+Math.imul(Z,kt)|0;var pi=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(pi>>>26)|0,pi&=67108863,T=Math.imul(tt,Qe),M=Math.imul(tt,Ke),M=M+Math.imul(rt,Qe)|0,O=Math.imul(rt,Ke),T=T+Math.imul(Ct,Vt)|0,M=M+Math.imul(Ct,At)|0,M=M+Math.imul(nt,Vt)|0,O=O+Math.imul(nt,At)|0,T=T+Math.imul(lt,Pt)|0,M=M+Math.imul(lt,pt)|0,M=M+Math.imul(it,Pt)|0,O=O+Math.imul(it,pt)|0,T=T+Math.imul(me,vt)|0,M=M+Math.imul(me,ut)|0,M=M+Math.imul(de,vt)|0,O=O+Math.imul(de,ut)|0,T=T+Math.imul(z,fi)|0,M=M+Math.imul(z,kt)|0,M=M+Math.imul(ne,fi)|0,O=O+Math.imul(ne,kt)|0,T=T+Math.imul(ee,Zi)|0,M=M+Math.imul(ee,Ut)|0,M=M+Math.imul(Z,Zi)|0,O=O+Math.imul(Z,Ut)|0;var Ii=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Ii>>>26)|0,Ii&=67108863,T=Math.imul(Ot,Qe),M=Math.imul(Ot,Ke),M=M+Math.imul(Ve,Qe)|0,O=Math.imul(Ve,Ke),T=T+Math.imul(tt,Vt)|0,M=M+Math.imul(tt,At)|0,M=M+Math.imul(rt,Vt)|0,O=O+Math.imul(rt,At)|0,T=T+Math.imul(Ct,Pt)|0,M=M+Math.imul(Ct,pt)|0,M=M+Math.imul(nt,Pt)|0,O=O+Math.imul(nt,pt)|0,T=T+Math.imul(lt,vt)|0,M=M+Math.imul(lt,ut)|0,M=M+Math.imul(it,vt)|0,O=O+Math.imul(it,ut)|0,T=T+Math.imul(me,fi)|0,M=M+Math.imul(me,kt)|0,M=M+Math.imul(de,fi)|0,O=O+Math.imul(de,kt)|0,T=T+Math.imul(z,Zi)|0,M=M+Math.imul(z,Ut)|0,M=M+Math.imul(ne,Zi)|0,O=O+Math.imul(ne,Ut)|0,T=T+Math.imul(ee,Be)|0,M=M+Math.imul(ee,be)|0,M=M+Math.imul(Z,Be)|0,O=O+Math.imul(Z,be)|0;var Ci=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Ci>>>26)|0,Ci&=67108863,T=Math.imul(Gt,Qe),M=Math.imul(Gt,Ke),M=M+Math.imul(wt,Qe)|0,O=Math.imul(wt,Ke),T=T+Math.imul(Ot,Vt)|0,M=M+Math.imul(Ot,At)|0,M=M+Math.imul(Ve,Vt)|0,O=O+Math.imul(Ve,At)|0,T=T+Math.imul(tt,Pt)|0,M=M+Math.imul(tt,pt)|0,M=M+Math.imul(rt,Pt)|0,O=O+Math.imul(rt,pt)|0,T=T+Math.imul(Ct,vt)|0,M=M+Math.imul(Ct,ut)|0,M=M+Math.imul(nt,vt)|0,O=O+Math.imul(nt,ut)|0,T=T+Math.imul(lt,fi)|0,M=M+Math.imul(lt,kt)|0,M=M+Math.imul(it,fi)|0,O=O+Math.imul(it,kt)|0,T=T+Math.imul(me,Zi)|0,M=M+Math.imul(me,Ut)|0,M=M+Math.imul(de,Zi)|0,O=O+Math.imul(de,Ut)|0,T=T+Math.imul(z,Be)|0,M=M+Math.imul(z,be)|0,M=M+Math.imul(ne,Be)|0,O=O+Math.imul(ne,be)|0,T=T+Math.imul(ee,oe)|0,M=M+Math.imul(ee,Ae)|0,M=M+Math.imul(Z,oe)|0,O=O+Math.imul(Z,Ae)|0;var zi=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(zi>>>26)|0,zi&=67108863,T=Math.imul(Yt,Qe),M=Math.imul(Yt,Ke),M=M+Math.imul(Ce,Qe)|0,O=Math.imul(Ce,Ke),T=T+Math.imul(Gt,Vt)|0,M=M+Math.imul(Gt,At)|0,M=M+Math.imul(wt,Vt)|0,O=O+Math.imul(wt,At)|0,T=T+Math.imul(Ot,Pt)|0,M=M+Math.imul(Ot,pt)|0,M=M+Math.imul(Ve,Pt)|0,O=O+Math.imul(Ve,pt)|0,T=T+Math.imul(tt,vt)|0,M=M+Math.imul(tt,ut)|0,M=M+Math.imul(rt,vt)|0,O=O+Math.imul(rt,ut)|0,T=T+Math.imul(Ct,fi)|0,M=M+Math.imul(Ct,kt)|0,M=M+Math.imul(nt,fi)|0,O=O+Math.imul(nt,kt)|0,T=T+Math.imul(lt,Zi)|0,M=M+Math.imul(lt,Ut)|0,M=M+Math.imul(it,Zi)|0,O=O+Math.imul(it,Ut)|0,T=T+Math.imul(me,Be)|0,M=M+Math.imul(me,be)|0,M=M+Math.imul(de,Be)|0,O=O+Math.imul(de,be)|0,T=T+Math.imul(z,oe)|0,M=M+Math.imul(z,Ae)|0,M=M+Math.imul(ne,oe)|0,O=O+Math.imul(ne,Ae)|0,T=T+Math.imul(ee,bt)|0,M=M+Math.imul(ee,at)|0,M=M+Math.imul(Z,bt)|0,O=O+Math.imul(Z,at)|0;var qi=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(qi>>>26)|0,qi&=67108863,T=Math.imul(ye,Qe),M=Math.imul(ye,Ke),M=M+Math.imul(Le,Qe)|0,O=Math.imul(Le,Ke),T=T+Math.imul(Yt,Vt)|0,M=M+Math.imul(Yt,At)|0,M=M+Math.imul(Ce,Vt)|0,O=O+Math.imul(Ce,At)|0,T=T+Math.imul(Gt,Pt)|0,M=M+Math.imul(Gt,pt)|0,M=M+Math.imul(wt,Pt)|0,O=O+Math.imul(wt,pt)|0,T=T+Math.imul(Ot,vt)|0,M=M+Math.imul(Ot,ut)|0,M=M+Math.imul(Ve,vt)|0,O=O+Math.imul(Ve,ut)|0,T=T+Math.imul(tt,fi)|0,M=M+Math.imul(tt,kt)|0,M=M+Math.imul(rt,fi)|0,O=O+Math.imul(rt,kt)|0,T=T+Math.imul(Ct,Zi)|0,M=M+Math.imul(Ct,Ut)|0,M=M+Math.imul(nt,Zi)|0,O=O+Math.imul(nt,Ut)|0,T=T+Math.imul(lt,Be)|0,M=M+Math.imul(lt,be)|0,M=M+Math.imul(it,Be)|0,O=O+Math.imul(it,be)|0,T=T+Math.imul(me,oe)|0,M=M+Math.imul(me,Ae)|0,M=M+Math.imul(de,oe)|0,O=O+Math.imul(de,Ae)|0,T=T+Math.imul(z,bt)|0,M=M+Math.imul(z,at)|0,M=M+Math.imul(ne,bt)|0,O=O+Math.imul(ne,at)|0,T=T+Math.imul(ee,ei)|0,M=M+Math.imul(ee,ii)|0,M=M+Math.imul(Z,ei)|0,O=O+Math.imul(Z,ii)|0;var Ai=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Ai>>>26)|0,Ai&=67108863,T=Math.imul(ye,Vt),M=Math.imul(ye,At),M=M+Math.imul(Le,Vt)|0,O=Math.imul(Le,At),T=T+Math.imul(Yt,Pt)|0,M=M+Math.imul(Yt,pt)|0,M=M+Math.imul(Ce,Pt)|0,O=O+Math.imul(Ce,pt)|0,T=T+Math.imul(Gt,vt)|0,M=M+Math.imul(Gt,ut)|0,M=M+Math.imul(wt,vt)|0,O=O+Math.imul(wt,ut)|0,T=T+Math.imul(Ot,fi)|0,M=M+Math.imul(Ot,kt)|0,M=M+Math.imul(Ve,fi)|0,O=O+Math.imul(Ve,kt)|0,T=T+Math.imul(tt,Zi)|0,M=M+Math.imul(tt,Ut)|0,M=M+Math.imul(rt,Zi)|0,O=O+Math.imul(rt,Ut)|0,T=T+Math.imul(Ct,Be)|0,M=M+Math.imul(Ct,be)|0,M=M+Math.imul(nt,Be)|0,O=O+Math.imul(nt,be)|0,T=T+Math.imul(lt,oe)|0,M=M+Math.imul(lt,Ae)|0,M=M+Math.imul(it,oe)|0,O=O+Math.imul(it,Ae)|0,T=T+Math.imul(me,bt)|0,M=M+Math.imul(me,at)|0,M=M+Math.imul(de,bt)|0,O=O+Math.imul(de,at)|0,T=T+Math.imul(z,ei)|0,M=M+Math.imul(z,ii)|0,M=M+Math.imul(ne,ei)|0,O=O+Math.imul(ne,ii)|0;var Oi=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Oi>>>26)|0,Oi&=67108863,T=Math.imul(ye,Pt),M=Math.imul(ye,pt),M=M+Math.imul(Le,Pt)|0,O=Math.imul(Le,pt),T=T+Math.imul(Yt,vt)|0,M=M+Math.imul(Yt,ut)|0,M=M+Math.imul(Ce,vt)|0,O=O+Math.imul(Ce,ut)|0,T=T+Math.imul(Gt,fi)|0,M=M+Math.imul(Gt,kt)|0,M=M+Math.imul(wt,fi)|0,O=O+Math.imul(wt,kt)|0,T=T+Math.imul(Ot,Zi)|0,M=M+Math.imul(Ot,Ut)|0,M=M+Math.imul(Ve,Zi)|0,O=O+Math.imul(Ve,Ut)|0,T=T+Math.imul(tt,Be)|0,M=M+Math.imul(tt,be)|0,M=M+Math.imul(rt,Be)|0,O=O+Math.imul(rt,be)|0,T=T+Math.imul(Ct,oe)|0,M=M+Math.imul(Ct,Ae)|0,M=M+Math.imul(nt,oe)|0,O=O+Math.imul(nt,Ae)|0,T=T+Math.imul(lt,bt)|0,M=M+Math.imul(lt,at)|0,M=M+Math.imul(it,bt)|0,O=O+Math.imul(it,at)|0,T=T+Math.imul(me,ei)|0,M=M+Math.imul(me,ii)|0,M=M+Math.imul(de,ei)|0,O=O+Math.imul(de,ii)|0;var ki=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(ki>>>26)|0,ki&=67108863,T=Math.imul(ye,vt),M=Math.imul(ye,ut),M=M+Math.imul(Le,vt)|0,O=Math.imul(Le,ut),T=T+Math.imul(Yt,fi)|0,M=M+Math.imul(Yt,kt)|0,M=M+Math.imul(Ce,fi)|0,O=O+Math.imul(Ce,kt)|0,T=T+Math.imul(Gt,Zi)|0,M=M+Math.imul(Gt,Ut)|0,M=M+Math.imul(wt,Zi)|0,O=O+Math.imul(wt,Ut)|0,T=T+Math.imul(Ot,Be)|0,M=M+Math.imul(Ot,be)|0,M=M+Math.imul(Ve,Be)|0,O=O+Math.imul(Ve,be)|0,T=T+Math.imul(tt,oe)|0,M=M+Math.imul(tt,Ae)|0,M=M+Math.imul(rt,oe)|0,O=O+Math.imul(rt,Ae)|0,T=T+Math.imul(Ct,bt)|0,M=M+Math.imul(Ct,at)|0,M=M+Math.imul(nt,bt)|0,O=O+Math.imul(nt,at)|0,T=T+Math.imul(lt,ei)|0,M=M+Math.imul(lt,ii)|0,M=M+Math.imul(it,ei)|0,O=O+Math.imul(it,ii)|0;var Ti=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Ti>>>26)|0,Ti&=67108863,T=Math.imul(ye,fi),M=Math.imul(ye,kt),M=M+Math.imul(Le,fi)|0,O=Math.imul(Le,kt),T=T+Math.imul(Yt,Zi)|0,M=M+Math.imul(Yt,Ut)|0,M=M+Math.imul(Ce,Zi)|0,O=O+Math.imul(Ce,Ut)|0,T=T+Math.imul(Gt,Be)|0,M=M+Math.imul(Gt,be)|0,M=M+Math.imul(wt,Be)|0,O=O+Math.imul(wt,be)|0,T=T+Math.imul(Ot,oe)|0,M=M+Math.imul(Ot,Ae)|0,M=M+Math.imul(Ve,oe)|0,O=O+Math.imul(Ve,Ae)|0,T=T+Math.imul(tt,bt)|0,M=M+Math.imul(tt,at)|0,M=M+Math.imul(rt,bt)|0,O=O+Math.imul(rt,at)|0,T=T+Math.imul(Ct,ei)|0,M=M+Math.imul(Ct,ii)|0,M=M+Math.imul(nt,ei)|0,O=O+Math.imul(nt,ii)|0;var wi=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(wi>>>26)|0,wi&=67108863,T=Math.imul(ye,Zi),M=Math.imul(ye,Ut),M=M+Math.imul(Le,Zi)|0,O=Math.imul(Le,Ut),T=T+Math.imul(Yt,Be)|0,M=M+Math.imul(Yt,be)|0,M=M+Math.imul(Ce,Be)|0,O=O+Math.imul(Ce,be)|0,T=T+Math.imul(Gt,oe)|0,M=M+Math.imul(Gt,Ae)|0,M=M+Math.imul(wt,oe)|0,O=O+Math.imul(wt,Ae)|0,T=T+Math.imul(Ot,bt)|0,M=M+Math.imul(Ot,at)|0,M=M+Math.imul(Ve,bt)|0,O=O+Math.imul(Ve,at)|0,T=T+Math.imul(tt,ei)|0,M=M+Math.imul(tt,ii)|0,M=M+Math.imul(rt,ei)|0,O=O+Math.imul(rt,ii)|0;var oi=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(oi>>>26)|0,oi&=67108863,T=Math.imul(ye,Be),M=Math.imul(ye,be),M=M+Math.imul(Le,Be)|0,O=Math.imul(Le,be),T=T+Math.imul(Yt,oe)|0,M=M+Math.imul(Yt,Ae)|0,M=M+Math.imul(Ce,oe)|0,O=O+Math.imul(Ce,Ae)|0,T=T+Math.imul(Gt,bt)|0,M=M+Math.imul(Gt,at)|0,M=M+Math.imul(wt,bt)|0,O=O+Math.imul(wt,at)|0,T=T+Math.imul(Ot,ei)|0,M=M+Math.imul(Ot,ii)|0,M=M+Math.imul(Ve,ei)|0,O=O+Math.imul(Ve,ii)|0;var zt=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(zt>>>26)|0,zt&=67108863,T=Math.imul(ye,oe),M=Math.imul(ye,Ae),M=M+Math.imul(Le,oe)|0,O=Math.imul(Le,Ae),T=T+Math.imul(Yt,bt)|0,M=M+Math.imul(Yt,at)|0,M=M+Math.imul(Ce,bt)|0,O=O+Math.imul(Ce,at)|0,T=T+Math.imul(Gt,ei)|0,M=M+Math.imul(Gt,ii)|0,M=M+Math.imul(wt,ei)|0,O=O+Math.imul(wt,ii)|0;var Qt=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,T=Math.imul(ye,bt),M=Math.imul(ye,at),M=M+Math.imul(Le,bt)|0,O=Math.imul(Le,at),T=T+Math.imul(Yt,ei)|0,M=M+Math.imul(Yt,ii)|0,M=M+Math.imul(Ce,ei)|0,O=O+Math.imul(Ce,ii)|0;var Si=(h+T|0)+((M&8191)<<13)|0;h=(O+(M>>>13)|0)+(Si>>>26)|0,Si&=67108863,T=Math.imul(ye,ei),M=Math.imul(ye,ii),M=M+Math.imul(Le,ei)|0,O=Math.imul(Le,ii);var mi=(h+T|0)+((M&8191)<<13)|0;return h=(O+(M>>>13)|0)+(mi>>>26)|0,mi&=67108863,b[0]=Bi,b[1]=hi,b[2]=Di,b[3]=ni,b[4]=pi,b[5]=Ii,b[6]=Ci,b[7]=zi,b[8]=qi,b[9]=Ai,b[10]=Oi,b[11]=ki,b[12]=Ti,b[13]=wi,b[14]=oi,b[15]=zt,b[16]=Qt,b[17]=Si,b[18]=mi,h!==0&&(b[19]=h,p.length++),p};Math.imul||(N=j);function Y(v,w,c){c.negative=w.negative^v.negative,c.length=v.length+w.length;for(var p=0,x=0,S=0;S<c.length-1;S++){var b=x;x=0;for(var h=p&67108863,T=Math.min(S,w.length-1),M=Math.max(0,S-v.length+1);M<=T;M++){var O=S-M,V=v.words[O]|0,ee=w.words[M]|0,Z=V*ee,U=Z&67108863;b=b+(Z/67108864|0)|0,U=U+h|0,h=U&67108863,b=b+(U>>>26)|0,x+=b>>>26,b&=67108863}c.words[S]=h,p=b,b=x}return p!==0?c.words[S]=p:c.length--,c._strip()}function J(v,w,c){return Y(v,w,c)}l.prototype.mulTo=function(w,c){var p,x=this.length+w.length;return this.length===10&&w.length===10?p=N(this,w,c):x<63?p=j(this,w,c):x<1024?p=Y(this,w,c):p=J(this,w,c),p},l.prototype.mul=function(w){var c=new l(null);return c.words=new Array(this.length+w.length),this.mulTo(w,c)},l.prototype.mulf=function(w){var c=new l(null);return c.words=new Array(this.length+w.length),J(this,w,c)},l.prototype.imul=function(w){return this.clone().mulTo(w,this)},l.prototype.imuln=function(w){var c=w<0;c&&(w=-w),o(typeof w=="number"),o(w<67108864);for(var p=0,x=0;x<this.length;x++){var S=(this.words[x]|0)*w,b=(S&67108863)+(p&67108863);p>>=26,p+=S/67108864|0,p+=b>>>26,this.words[x]=b&67108863}return p!==0&&(this.words[x]=p,this.length++),c?this.ineg():this},l.prototype.muln=function(w){return this.clone().imuln(w)},l.prototype.sqr=function(){return this.mul(this)},l.prototype.isqr=function(){return this.imul(this.clone())},l.prototype.pow=function(w){var c=F(w);if(c.length===0)return new l(1);for(var p=this,x=0;x<c.length&&c[x]===0;x++,p=p.sqr());if(++x<c.length)for(var S=p.sqr();x<c.length;x++,S=S.sqr())c[x]!==0&&(p=p.mul(S));return p},l.prototype.iushln=function(w){o(typeof w=="number"&&w>=0);var c=w%26,p=(w-c)/26,x=67108863>>>26-c<<26-c,S;if(c!==0){var b=0;for(S=0;S<this.length;S++){var h=this.words[S]&x,T=(this.words[S]|0)-h<<c;this.words[S]=T|b,b=h>>>26-c}b&&(this.words[S]=b,this.length++)}if(p!==0){for(S=this.length-1;S>=0;S--)this.words[S+p]=this.words[S];for(S=0;S<p;S++)this.words[S]=0;this.length+=p}return this._strip()},l.prototype.ishln=function(w){return o(this.negative===0),this.iushln(w)},l.prototype.iushrn=function(w,c,p){o(typeof w=="number"&&w>=0);var x;c?x=(c-c%26)/26:x=0;var S=w%26,b=Math.min((w-S)/26,this.length),h=67108863^67108863>>>S<<S,T=p;if(x-=b,x=Math.max(0,x),T){for(var M=0;M<b;M++)T.words[M]=this.words[M];T.length=b}if(b!==0)if(this.length>b)for(this.length-=b,M=0;M<this.length;M++)this.words[M]=this.words[M+b];else this.words[0]=0,this.length=1;var O=0;for(M=this.length-1;M>=0&&(O!==0||M>=x);M--){var V=this.words[M]|0;this.words[M]=O<<26-S|V>>>S,O=V&h}return T&&O!==0&&(T.words[T.length++]=O),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},l.prototype.ishrn=function(w,c,p){return o(this.negative===0),this.iushrn(w,c,p)},l.prototype.shln=function(w){return this.clone().ishln(w)},l.prototype.ushln=function(w){return this.clone().iushln(w)},l.prototype.shrn=function(w){return this.clone().ishrn(w)},l.prototype.ushrn=function(w){return this.clone().iushrn(w)},l.prototype.testn=function(w){o(typeof w=="number"&&w>=0);var c=w%26,p=(w-c)/26,x=1<<c;if(this.length<=p)return!1;var S=this.words[p];return!!(S&x)},l.prototype.imaskn=function(w){o(typeof w=="number"&&w>=0);var c=w%26,p=(w-c)/26;if(o(this.negative===0,"imaskn works only with positive numbers"),this.length<=p)return this;if(c!==0&&p++,this.length=Math.min(p,this.length),c!==0){var x=67108863^67108863>>>c<<c;this.words[this.length-1]&=x}return this._strip()},l.prototype.maskn=function(w){return this.clone().imaskn(w)},l.prototype.iaddn=function(w){return o(typeof w=="number"),o(w<67108864),w<0?this.isubn(-w):this.negative!==0?this.length===1&&(this.words[0]|0)<=w?(this.words[0]=w-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(w),this.negative=1,this):this._iaddn(w)},l.prototype._iaddn=function(w){this.words[0]+=w;for(var c=0;c<this.length&&this.words[c]>=67108864;c++)this.words[c]-=67108864,c===this.length-1?this.words[c+1]=1:this.words[c+1]++;return this.length=Math.max(this.length,c+1),this},l.prototype.isubn=function(w){if(o(typeof w=="number"),o(w<67108864),w<0)return this.iaddn(-w);if(this.negative!==0)return this.negative=0,this.iaddn(w),this.negative=1,this;if(this.words[0]-=w,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var c=0;c<this.length&&this.words[c]<0;c++)this.words[c]+=67108864,this.words[c+1]-=1;return this._strip()},l.prototype.addn=function(w){return this.clone().iaddn(w)},l.prototype.subn=function(w){return this.clone().isubn(w)},l.prototype.iabs=function(){return this.negative=0,this},l.prototype.abs=function(){return this.clone().iabs()},l.prototype._ishlnsubmul=function(w,c,p){var x=w.length+p,S;this._expand(x);var b,h=0;for(S=0;S<w.length;S++){b=(this.words[S+p]|0)+h;var T=(w.words[S]|0)*c;b-=T&67108863,h=(b>>26)-(T/67108864|0),this.words[S+p]=b&67108863}for(;S<this.length-p;S++)b=(this.words[S+p]|0)+h,h=b>>26,this.words[S+p]=b&67108863;if(h===0)return this._strip();for(o(h===-1),h=0,S=0;S<this.length;S++)b=-(this.words[S]|0)+h,h=b>>26,this.words[S]=b&67108863;return this.negative=1,this._strip()},l.prototype._wordDiv=function(w,c){var p=this.length-w.length,x=this.clone(),S=w,b=S.words[S.length-1]|0,h=this._countBits(b);p=26-h,p!==0&&(S=S.ushln(p),x.iushln(p),b=S.words[S.length-1]|0);var T=x.length-S.length,M;if(c!=="mod"){M=new l(null),M.length=T+1,M.words=new Array(M.length);for(var O=0;O<M.length;O++)M.words[O]=0}var V=x.clone()._ishlnsubmul(S,1,T);V.negative===0&&(x=V,M&&(M.words[T]=1));for(var ee=T-1;ee>=0;ee--){var Z=(x.words[S.length+ee]|0)*67108864+(x.words[S.length+ee-1]|0);for(Z=Math.min(Z/b|0,67108863),x._ishlnsubmul(S,Z,ee);x.negative!==0;)Z--,x.negative=0,x._ishlnsubmul(S,1,ee),x.isZero()||(x.negative^=1);M&&(M.words[ee]=Z)}return M&&M._strip(),x._strip(),c!=="div"&&p!==0&&x.iushrn(p),{div:M||null,mod:x}},l.prototype.divmod=function(w,c,p){if(o(!w.isZero()),this.isZero())return{div:new l(0),mod:new l(0)};var x,S,b;return this.negative!==0&&w.negative===0?(b=this.neg().divmod(w,c),c!=="mod"&&(x=b.div.neg()),c!=="div"&&(S=b.mod.neg(),p&&S.negative!==0&&S.iadd(w)),{div:x,mod:S}):this.negative===0&&w.negative!==0?(b=this.divmod(w.neg(),c),c!=="mod"&&(x=b.div.neg()),{div:x,mod:b.mod}):this.negative&w.negative?(b=this.neg().divmod(w.neg(),c),c!=="div"&&(S=b.mod.neg(),p&&S.negative!==0&&S.isub(w)),{div:b.div,mod:S}):w.length>this.length||this.cmp(w)<0?{div:new l(0),mod:this}:w.length===1?c==="div"?{div:this.divn(w.words[0]),mod:null}:c==="mod"?{div:null,mod:new l(this.modrn(w.words[0]))}:{div:this.divn(w.words[0]),mod:new l(this.modrn(w.words[0]))}:this._wordDiv(w,c)},l.prototype.div=function(w){return this.divmod(w,"div",!1).div},l.prototype.mod=function(w){return this.divmod(w,"mod",!1).mod},l.prototype.umod=function(w){return this.divmod(w,"mod",!0).mod},l.prototype.divRound=function(w){var c=this.divmod(w);if(c.mod.isZero())return c.div;var p=c.div.negative!==0?c.mod.isub(w):c.mod,x=w.ushrn(1),S=w.andln(1),b=p.cmp(x);return b<0||S===1&&b===0?c.div:c.div.negative!==0?c.div.isubn(1):c.div.iaddn(1)},l.prototype.modrn=function(w){var c=w<0;c&&(w=-w),o(w<=67108863);for(var p=(1<<26)%w,x=0,S=this.length-1;S>=0;S--)x=(p*x+(this.words[S]|0))%w;return c?-x:x},l.prototype.modn=function(w){return this.modrn(w)},l.prototype.idivn=function(w){var c=w<0;c&&(w=-w),o(w<=67108863);for(var p=0,x=this.length-1;x>=0;x--){var S=(this.words[x]|0)+p*67108864;this.words[x]=S/w|0,p=S%w}return this._strip(),c?this.ineg():this},l.prototype.divn=function(w){return this.clone().idivn(w)},l.prototype.egcd=function(w){o(w.negative===0),o(!w.isZero());var c=this,p=w.clone();c.negative!==0?c=c.umod(w):c=c.clone();for(var x=new l(1),S=new l(0),b=new l(0),h=new l(1),T=0;c.isEven()&&p.isEven();)c.iushrn(1),p.iushrn(1),++T;for(var M=p.clone(),O=c.clone();!c.isZero();){for(var V=0,ee=1;!(c.words[0]&ee)&&V<26;++V,ee<<=1);if(V>0)for(c.iushrn(V);V-- >0;)(x.isOdd()||S.isOdd())&&(x.iadd(M),S.isub(O)),x.iushrn(1),S.iushrn(1);for(var Z=0,U=1;!(p.words[0]&U)&&Z<26;++Z,U<<=1);if(Z>0)for(p.iushrn(Z);Z-- >0;)(b.isOdd()||h.isOdd())&&(b.iadd(M),h.isub(O)),b.iushrn(1),h.iushrn(1);c.cmp(p)>=0?(c.isub(p),x.isub(b),S.isub(h)):(p.isub(c),b.isub(x),h.isub(S))}return{a:b,b:h,gcd:p.iushln(T)}},l.prototype._invmp=function(w){o(w.negative===0),o(!w.isZero());var c=this,p=w.clone();c.negative!==0?c=c.umod(w):c=c.clone();for(var x=new l(1),S=new l(0),b=p.clone();c.cmpn(1)>0&&p.cmpn(1)>0;){for(var h=0,T=1;!(c.words[0]&T)&&h<26;++h,T<<=1);if(h>0)for(c.iushrn(h);h-- >0;)x.isOdd()&&x.iadd(b),x.iushrn(1);for(var M=0,O=1;!(p.words[0]&O)&&M<26;++M,O<<=1);if(M>0)for(p.iushrn(M);M-- >0;)S.isOdd()&&S.iadd(b),S.iushrn(1);c.cmp(p)>=0?(c.isub(p),x.isub(S)):(p.isub(c),S.isub(x))}var V;return c.cmpn(1)===0?V=x:V=S,V.cmpn(0)<0&&V.iadd(w),V},l.prototype.gcd=function(w){if(this.isZero())return w.abs();if(w.isZero())return this.abs();var c=this.clone(),p=w.clone();c.negative=0,p.negative=0;for(var x=0;c.isEven()&&p.isEven();x++)c.iushrn(1),p.iushrn(1);do{for(;c.isEven();)c.iushrn(1);for(;p.isEven();)p.iushrn(1);var S=c.cmp(p);if(S<0){var b=c;c=p,p=b}else if(S===0||p.cmpn(1)===0)break;c.isub(p)}while(!0);return p.iushln(x)},l.prototype.invm=function(w){return this.egcd(w).a.umod(w)},l.prototype.isEven=function(){return(this.words[0]&1)===0},l.prototype.isOdd=function(){return(this.words[0]&1)===1},l.prototype.andln=function(w){return this.words[0]&w},l.prototype.bincn=function(w){o(typeof w=="number");var c=w%26,p=(w-c)/26,x=1<<c;if(this.length<=p)return this._expand(p+1),this.words[p]|=x,this;for(var S=x,b=p;S!==0&&b<this.length;b++){var h=this.words[b]|0;h+=S,S=h>>>26,h&=67108863,this.words[b]=h}return S!==0&&(this.words[b]=S,this.length++),this},l.prototype.isZero=function(){return this.length===1&&this.words[0]===0},l.prototype.cmpn=function(w){var c=w<0;if(this.negative!==0&&!c)return-1;if(this.negative===0&&c)return 1;this._strip();var p;if(this.length>1)p=1;else{c&&(w=-w),o(w<=67108863,"Number is too big");var x=this.words[0]|0;p=x===w?0:x<w?-1:1}return this.negative!==0?-p|0:p},l.prototype.cmp=function(w){if(this.negative!==0&&w.negative===0)return-1;if(this.negative===0&&w.negative!==0)return 1;var c=this.ucmp(w);return this.negative!==0?-c|0:c},l.prototype.ucmp=function(w){if(this.length>w.length)return 1;if(this.length<w.length)return-1;for(var c=0,p=this.length-1;p>=0;p--){var x=this.words[p]|0,S=w.words[p]|0;if(x!==S){x<S?c=-1:x>S&&(c=1);break}}return c},l.prototype.gtn=function(w){return this.cmpn(w)===1},l.prototype.gt=function(w){return this.cmp(w)===1},l.prototype.gten=function(w){return this.cmpn(w)>=0},l.prototype.gte=function(w){return this.cmp(w)>=0},l.prototype.ltn=function(w){return this.cmpn(w)===-1},l.prototype.lt=function(w){return this.cmp(w)===-1},l.prototype.lten=function(w){return this.cmpn(w)<=0},l.prototype.lte=function(w){return this.cmp(w)<=0},l.prototype.eqn=function(w){return this.cmpn(w)===0},l.prototype.eq=function(w){return this.cmp(w)===0},l.red=function(w){return new L(w)},l.prototype.toRed=function(w){return o(!this.red,"Already a number in reduction context"),o(this.negative===0,"red works only with positives"),w.convertTo(this)._forceRed(w)},l.prototype.fromRed=function(){return o(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},l.prototype._forceRed=function(w){return this.red=w,this},l.prototype.forceRed=function(w){return o(!this.red,"Already a number in reduction context"),this._forceRed(w)},l.prototype.redAdd=function(w){return o(this.red,"redAdd works only with red numbers"),this.red.add(this,w)},l.prototype.redIAdd=function(w){return o(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,w)},l.prototype.redSub=function(w){return o(this.red,"redSub works only with red numbers"),this.red.sub(this,w)},l.prototype.redISub=function(w){return o(this.red,"redISub works only with red numbers"),this.red.isub(this,w)},l.prototype.redShl=function(w){return o(this.red,"redShl works only with red numbers"),this.red.shl(this,w)},l.prototype.redMul=function(w){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,w),this.red.mul(this,w)},l.prototype.redIMul=function(w){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,w),this.red.imul(this,w)},l.prototype.redSqr=function(){return o(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},l.prototype.redISqr=function(){return o(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},l.prototype.redSqrt=function(){return o(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},l.prototype.redInvm=function(){return o(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},l.prototype.redNeg=function(){return o(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},l.prototype.redPow=function(w){return o(this.red&&!w.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,w)};var ie={k256:null,p224:null,p192:null,p25519:null};function ue(v,w){this.name=v,this.p=new l(w,16),this.n=this.p.bitLength(),this.k=new l(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}ue.prototype._tmp=function(){var w=new l(null);return w.words=new Array(Math.ceil(this.n/13)),w},ue.prototype.ireduce=function(w){var c=w,p;do this.split(c,this.tmp),c=this.imulK(c),c=c.iadd(this.tmp),p=c.bitLength();while(p>this.n);var x=p<this.n?-1:c.ucmp(this.p);return x===0?(c.words[0]=0,c.length=1):x>0?c.isub(this.p):c.strip!==void 0?c.strip():c._strip(),c},ue.prototype.split=function(w,c){w.iushrn(this.n,0,c)},ue.prototype.imulK=function(w){return w.imul(this.k)};function Q(){ue.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}u(Q,ue),Q.prototype.split=function(w,c){for(var p=4194303,x=Math.min(w.length,9),S=0;S<x;S++)c.words[S]=w.words[S];if(c.length=x,w.length<=9){w.words[0]=0,w.length=1;return}var b=w.words[9];for(c.words[c.length++]=b&p,S=10;S<w.length;S++){var h=w.words[S]|0;w.words[S-10]=(h&p)<<4|b>>>22,b=h}b>>>=22,w.words[S-10]=b,b===0&&w.length>10?w.length-=10:w.length-=9},Q.prototype.imulK=function(w){w.words[w.length]=0,w.words[w.length+1]=0,w.length+=2;for(var c=0,p=0;p<w.length;p++){var x=w.words[p]|0;c+=x*977,w.words[p]=c&67108863,c=x*64+(c/67108864|0)}return w.words[w.length-1]===0&&(w.length--,w.words[w.length-1]===0&&w.length--),w};function ce(){ue.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}u(ce,ue);function he(){ue.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}u(he,ue);function ke(){ue.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}u(ke,ue),ke.prototype.imulK=function(w){for(var c=0,p=0;p<w.length;p++){var x=(w.words[p]|0)*19+c,S=x&67108863;x>>>=26,w.words[p]=S,c=x}return c!==0&&(w.words[w.length++]=c),w},l._prime=function(w){if(ie[w])return ie[w];var c;if(w==="k256")c=new Q;else if(w==="p224")c=new ce;else if(w==="p192")c=new he;else if(w==="p25519")c=new ke;else throw new Error("Unknown prime "+w);return ie[w]=c,c};function L(v){if(typeof v=="string"){var w=l._prime(v);this.m=w.p,this.prime=w}else o(v.gtn(1),"modulus must be greater than 1"),this.m=v,this.prime=null}L.prototype._verify1=function(w){o(w.negative===0,"red works only with positives"),o(w.red,"red works only with red numbers")},L.prototype._verify2=function(w,c){o((w.negative|c.negative)===0,"red works only with positives"),o(w.red&&w.red===c.red,"red works only with red numbers")},L.prototype.imod=function(w){return this.prime?this.prime.ireduce(w)._forceRed(this):(k(w,w.umod(this.m)._forceRed(this)),w)},L.prototype.neg=function(w){return w.isZero()?w.clone():this.m.sub(w)._forceRed(this)},L.prototype.add=function(w,c){this._verify2(w,c);var p=w.add(c);return p.cmp(this.m)>=0&&p.isub(this.m),p._forceRed(this)},L.prototype.iadd=function(w,c){this._verify2(w,c);var p=w.iadd(c);return p.cmp(this.m)>=0&&p.isub(this.m),p},L.prototype.sub=function(w,c){this._verify2(w,c);var p=w.sub(c);return p.cmpn(0)<0&&p.iadd(this.m),p._forceRed(this)},L.prototype.isub=function(w,c){this._verify2(w,c);var p=w.isub(c);return p.cmpn(0)<0&&p.iadd(this.m),p},L.prototype.shl=function(w,c){return this._verify1(w),this.imod(w.ushln(c))},L.prototype.imul=function(w,c){return this._verify2(w,c),this.imod(w.imul(c))},L.prototype.mul=function(w,c){return this._verify2(w,c),this.imod(w.mul(c))},L.prototype.isqr=function(w){return this.imul(w,w.clone())},L.prototype.sqr=function(w){return this.mul(w,w)},L.prototype.sqrt=function(w){if(w.isZero())return w.clone();var c=this.m.andln(3);if(o(c%2===1),c===3){var p=this.m.add(new l(1)).iushrn(2);return this.pow(w,p)}for(var x=this.m.subn(1),S=0;!x.isZero()&&x.andln(1)===0;)S++,x.iushrn(1);o(!x.isZero());var b=new l(1).toRed(this),h=b.redNeg(),T=this.m.subn(1).iushrn(1),M=this.m.bitLength();for(M=new l(2*M*M).toRed(this);this.pow(M,T).cmp(h)!==0;)M.redIAdd(h);for(var O=this.pow(M,x),V=this.pow(w,x.addn(1).iushrn(1)),ee=this.pow(w,x),Z=S;ee.cmp(b)!==0;){for(var U=ee,z=0;U.cmp(b)!==0;z++)U=U.redSqr();o(z<Z);var ne=this.pow(O,new l(1).iushln(Z-z-1));V=V.redMul(ne),O=ne.redSqr(),ee=ee.redMul(O),Z=z}return V},L.prototype.invm=function(w){var c=w._invmp(this.m);return c.negative!==0?(c.negative=0,this.imod(c).redNeg()):this.imod(c)},L.prototype.pow=function(w,c){if(c.isZero())return new l(1).toRed(this);if(c.cmpn(1)===0)return w.clone();var p=4,x=new Array(1<<p);x[0]=new l(1).toRed(this),x[1]=w;for(var S=2;S<x.length;S++)x[S]=this.mul(x[S-1],w);var b=x[0],h=0,T=0,M=c.bitLength()%26;for(M===0&&(M=26),S=c.length-1;S>=0;S--){for(var O=c.words[S],V=M-1;V>=0;V--){var ee=O>>V&1;if(b!==x[0]&&(b=this.sqr(b)),ee===0&&h===0){T=0;continue}h<<=1,h|=ee,T++,!(T!==p&&(S!==0||V!==0))&&(b=this.mul(b,x[h]),T=0,h=0)}M=26}return b},L.prototype.convertTo=function(w){var c=w.umod(this.m);return c===w?c.clone():c},L.prototype.convertFrom=function(w){var c=w.clone();return c.red=null,c},l.mont=function(w){return new d(w)};function d(v){L.call(this,v),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new l(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}u(d,L),d.prototype.convertTo=function(w){return this.imod(w.ushln(this.shift))},d.prototype.convertFrom=function(w){var c=this.imod(w.mul(this.rinv));return c.red=null,c},d.prototype.imul=function(w,c){if(w.isZero()||c.isZero())return w.words[0]=0,w.length=1,w;var p=w.imul(c),x=p.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),S=p.isub(x).iushrn(this.shift),b=S;return S.cmp(this.m)>=0?b=S.isub(this.m):S.cmpn(0)<0&&(b=S.iadd(this.m)),b._forceRed(this)},d.prototype.mul=function(w,c){if(w.isZero()||c.isZero())return new l(0)._forceRed(this);var p=w.mul(c),x=p.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),S=p.isub(x).iushrn(this.shift),b=S;return S.cmp(this.m)>=0?b=S.isub(this.m):S.cmpn(0)<0&&(b=S.iadd(this.m)),b._forceRed(this)},d.prototype.invm=function(w){var c=this.imod(w._invmp(this.m).mul(this.r2));return c._forceRed(this)}})(t,commonjsGlobal$1)}(bn$4);var bnExports$4=bn$4.exports,BN$a=bnExports$4,randomBytes$1=browserExports;function blind(t){var e=getr(t),n=e.toRed(BN$a.mont(t.modulus)).redPow(new BN$a(t.publicExponent)).fromRed();return{blinder:n,unblinder:e.invm(t.modulus)}}function getr(t){var e=t.modulus.byteLength(),n;do n=new BN$a(randomBytes$1(e));while(n.cmp(t.modulus)>=0||!n.umod(t.prime1)||!n.umod(t.prime2));return n}function crt$2(t,e){var n=blind(e),o=e.modulus.byteLength(),u=new BN$a(t).mul(n.blinder).umod(e.modulus),l=u.toRed(BN$a.mont(e.prime1)),m=u.toRed(BN$a.mont(e.prime2)),y=e.coefficient,E=e.prime1,C=e.prime2,k=l.redPow(e.exponent1).fromRed(),A=m.redPow(e.exponent2).fromRed(),D=k.isub(A).imul(y).umod(E).imul(C);return A.iadd(D).imul(n.unblinder).umod(e.modulus).toArrayLike(Buffer$C,"be",o)}crt$2.getr=getr;var browserifyRsa=crt$2,elliptic={};const name="elliptic",version$1="6.5.7",description$1="EC cryptography",main$1="lib/elliptic.js",files=["lib"],scripts={lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},repository={type:"git",url:"git@github.com:indutny/elliptic"},keywords=["EC","Elliptic","curve","Cryptography"],author="Fedor Indutny <fedor@indutny.com>",license="MIT",bugs={url:"https://github.com/indutny/elliptic/issues"},homepage="https://github.com/indutny/elliptic",devDependencies={brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},dependencies$1={"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"},require$$0$1={name,version:version$1,description:description$1,main:main$1,files,scripts,repository,keywords,author,license,bugs,homepage,devDependencies,dependencies:dependencies$1};var utils$o={},bn$3={exports:{}};bn$3.exports,function(t){(function(e,n){function o(L,d){if(!L)throw new Error(d||"Assertion failed")}function u(L,d){L.super_=d;var v=function(){};v.prototype=d.prototype,L.prototype=new v,L.prototype.constructor=L}function l(L,d,v){if(l.isBN(L))return L;this.negative=0,this.words=null,this.length=0,this.red=null,L!==null&&((d==="le"||d==="be")&&(v=d,d=10),this._init(L||0,d||10,v||"be"))}typeof e=="object"?e.exports=l:n.BN=l,l.BN=l,l.wordSize=26;var m;try{typeof window<"u"&&typeof window.Buffer<"u"?m=window.Buffer:m=require$$0$2.Buffer}catch{}l.isBN=function(d){return d instanceof l?!0:d!==null&&typeof d=="object"&&d.constructor.wordSize===l.wordSize&&Array.isArray(d.words)},l.max=function(d,v){return d.cmp(v)>0?d:v},l.min=function(d,v){return d.cmp(v)<0?d:v},l.prototype._init=function(d,v,w){if(typeof d=="number")return this._initNumber(d,v,w);if(typeof d=="object")return this._initArray(d,v,w);v==="hex"&&(v=16),o(v===(v|0)&&v>=2&&v<=36),d=d.toString().replace(/\s+/g,"");var c=0;d[0]==="-"&&(c++,this.negative=1),c<d.length&&(v===16?this._parseHex(d,c,w):(this._parseBase(d,v,c),w==="le"&&this._initArray(this.toArray(),v,w)))},l.prototype._initNumber=function(d,v,w){d<0&&(this.negative=1,d=-d),d<67108864?(this.words=[d&67108863],this.length=1):d<4503599627370496?(this.words=[d&67108863,d/67108864&67108863],this.length=2):(o(d<9007199254740992),this.words=[d&67108863,d/67108864&67108863,1],this.length=3),w==="le"&&this._initArray(this.toArray(),v,w)},l.prototype._initArray=function(d,v,w){if(o(typeof d.length=="number"),d.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(d.length/3),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p,x,S=0;if(w==="be")for(c=d.length-1,p=0;c>=0;c-=3)x=d[c]|d[c-1]<<8|d[c-2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);else if(w==="le")for(c=0,p=0;c<d.length;c+=3)x=d[c]|d[c+1]<<8|d[c+2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);return this.strip()};function y(L,d){var v=L.charCodeAt(d);return v>=65&&v<=70?v-55:v>=97&&v<=102?v-87:v-48&15}function E(L,d,v){var w=y(L,v);return v-1>=d&&(w|=y(L,v-1)<<4),w}l.prototype._parseHex=function(d,v,w){this.length=Math.ceil((d.length-v)/6),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p=0,x=0,S;if(w==="be")for(c=d.length-1;c>=v;c-=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8;else{var b=d.length-v;for(c=b%2===0?v+1:v;c<d.length;c+=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8}this.strip()};function C(L,d,v,w){for(var c=0,p=Math.min(L.length,v),x=d;x<p;x++){var S=L.charCodeAt(x)-48;c*=w,S>=49?c+=S-49+10:S>=17?c+=S-17+10:c+=S}return c}l.prototype._parseBase=function(d,v,w){this.words=[0],this.length=1;for(var c=0,p=1;p<=67108863;p*=v)c++;c--,p=p/v|0;for(var x=d.length-w,S=x%c,b=Math.min(x,x-S)+w,h=0,T=w;T<b;T+=c)h=C(d,T,T+c,v),this.imuln(p),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h);if(S!==0){var M=1;for(h=C(d,T,d.length,v),T=0;T<S;T++)M*=v;this.imuln(M),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h)}this.strip()},l.prototype.copy=function(d){d.words=new Array(this.length);for(var v=0;v<this.length;v++)d.words[v]=this.words[v];d.length=this.length,d.negative=this.negative,d.red=this.red},l.prototype.clone=function(){var d=new l(null);return this.copy(d),d},l.prototype._expand=function(d){for(;this.length<d;)this.words[this.length++]=0;return this},l.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},l.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},l.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var k=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],D=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];l.prototype.toString=function(d,v){d=d||10,v=v|0||1;var w;if(d===16||d==="hex"){w="";for(var c=0,p=0,x=0;x<this.length;x++){var S=this.words[x],b=((S<<c|p)&16777215).toString(16);p=S>>>24-c&16777215,p!==0||x!==this.length-1?w=k[6-b.length]+b+w:w=b+w,c+=2,c>=26&&(c-=26,x--)}for(p!==0&&(w=p.toString(16)+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}if(d===(d|0)&&d>=2&&d<=36){var h=A[d],T=D[d];w="";var M=this.clone();for(M.negative=0;!M.isZero();){var O=M.modn(T).toString(d);M=M.idivn(T),M.isZero()?w=O+w:w=k[h-O.length]+O+w}for(this.isZero()&&(w="0"+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}o(!1,"Base should be between 2 and 36")},l.prototype.toNumber=function(){var d=this.words[0];return this.length===2?d+=this.words[1]*67108864:this.length===3&&this.words[2]===1?d+=4503599627370496+this.words[1]*67108864:this.length>2&&o(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-d:d},l.prototype.toJSON=function(){return this.toString(16)},l.prototype.toBuffer=function(d,v){return o(typeof m<"u"),this.toArrayLike(m,d,v)},l.prototype.toArray=function(d,v){return this.toArrayLike(Array,d,v)},l.prototype.toArrayLike=function(d,v,w){var c=this.byteLength(),p=w||Math.max(1,c);o(c<=p,"byte array longer than desired length"),o(p>0,"Requested array length <= 0"),this.strip();var x=v==="le",S=new d(p),b,h,T=this.clone();if(x){for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[h]=b;for(;h<p;h++)S[h]=0}else{for(h=0;h<p-c;h++)S[h]=0;for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[p-h-1]=b}return S},Math.clz32?l.prototype._countBits=function(d){return 32-Math.clz32(d)}:l.prototype._countBits=function(d){var v=d,w=0;return v>=4096&&(w+=13,v>>>=13),v>=64&&(w+=7,v>>>=7),v>=8&&(w+=4,v>>>=4),v>=2&&(w+=2,v>>>=2),w+v},l.prototype._zeroBits=function(d){if(d===0)return 26;var v=d,w=0;return v&8191||(w+=13,v>>>=13),v&127||(w+=7,v>>>=7),v&15||(w+=4,v>>>=4),v&3||(w+=2,v>>>=2),v&1||w++,w},l.prototype.bitLength=function(){var d=this.words[this.length-1],v=this._countBits(d);return(this.length-1)*26+v};function P(L){for(var d=new Array(L.bitLength()),v=0;v<d.length;v++){var w=v/26|0,c=v%26;d[v]=(L.words[w]&1<<c)>>>c}return d}l.prototype.zeroBits=function(){if(this.isZero())return 0;for(var d=0,v=0;v<this.length;v++){var w=this._zeroBits(this.words[v]);if(d+=w,w!==26)break}return d},l.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},l.prototype.toTwos=function(d){return this.negative!==0?this.abs().inotn(d).iaddn(1):this.clone()},l.prototype.fromTwos=function(d){return this.testn(d-1)?this.notn(d).iaddn(1).ineg():this.clone()},l.prototype.isNeg=function(){return this.negative!==0},l.prototype.neg=function(){return this.clone().ineg()},l.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},l.prototype.iuor=function(d){for(;this.length<d.length;)this.words[this.length++]=0;for(var v=0;v<d.length;v++)this.words[v]=this.words[v]|d.words[v];return this.strip()},l.prototype.ior=function(d){return o((this.negative|d.negative)===0),this.iuor(d)},l.prototype.or=function(d){return this.length>d.length?this.clone().ior(d):d.clone().ior(this)},l.prototype.uor=function(d){return this.length>d.length?this.clone().iuor(d):d.clone().iuor(this)},l.prototype.iuand=function(d){var v;this.length>d.length?v=d:v=this;for(var w=0;w<v.length;w++)this.words[w]=this.words[w]&d.words[w];return this.length=v.length,this.strip()},l.prototype.iand=function(d){return o((this.negative|d.negative)===0),this.iuand(d)},l.prototype.and=function(d){return this.length>d.length?this.clone().iand(d):d.clone().iand(this)},l.prototype.uand=function(d){return this.length>d.length?this.clone().iuand(d):d.clone().iuand(this)},l.prototype.iuxor=function(d){var v,w;this.length>d.length?(v=this,w=d):(v=d,w=this);for(var c=0;c<w.length;c++)this.words[c]=v.words[c]^w.words[c];if(this!==v)for(;c<v.length;c++)this.words[c]=v.words[c];return this.length=v.length,this.strip()},l.prototype.ixor=function(d){return o((this.negative|d.negative)===0),this.iuxor(d)},l.prototype.xor=function(d){return this.length>d.length?this.clone().ixor(d):d.clone().ixor(this)},l.prototype.uxor=function(d){return this.length>d.length?this.clone().iuxor(d):d.clone().iuxor(this)},l.prototype.inotn=function(d){o(typeof d=="number"&&d>=0);var v=Math.ceil(d/26)|0,w=d%26;this._expand(v),w>0&&v--;for(var c=0;c<v;c++)this.words[c]=~this.words[c]&67108863;return w>0&&(this.words[c]=~this.words[c]&67108863>>26-w),this.strip()},l.prototype.notn=function(d){return this.clone().inotn(d)},l.prototype.setn=function(d,v){o(typeof d=="number"&&d>=0);var w=d/26|0,c=d%26;return this._expand(w+1),v?this.words[w]=this.words[w]|1<<c:this.words[w]=this.words[w]&~(1<<c),this.strip()},l.prototype.iadd=function(d){var v;if(this.negative!==0&&d.negative===0)return this.negative=0,v=this.isub(d),this.negative^=1,this._normSign();if(this.negative===0&&d.negative!==0)return d.negative=0,v=this.isub(d),d.negative=1,v._normSign();var w,c;this.length>d.length?(w=this,c=d):(w=d,c=this);for(var p=0,x=0;x<c.length;x++)v=(w.words[x]|0)+(c.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;for(;p!==0&&x<w.length;x++)v=(w.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;if(this.length=w.length,p!==0)this.words[this.length]=p,this.length++;else if(w!==this)for(;x<w.length;x++)this.words[x]=w.words[x];return this},l.prototype.add=function(d){var v;return d.negative!==0&&this.negative===0?(d.negative=0,v=this.sub(d),d.negative^=1,v):d.negative===0&&this.negative!==0?(this.negative=0,v=d.sub(this),this.negative=1,v):this.length>d.length?this.clone().iadd(d):d.clone().iadd(this)},l.prototype.isub=function(d){if(d.negative!==0){d.negative=0;var v=this.iadd(d);return d.negative=1,v._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(d),this.negative=1,this._normSign();var w=this.cmp(d);if(w===0)return this.negative=0,this.length=1,this.words[0]=0,this;var c,p;w>0?(c=this,p=d):(c=d,p=this);for(var x=0,S=0;S<p.length;S++)v=(c.words[S]|0)-(p.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;for(;x!==0&&S<c.length;S++)v=(c.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;if(x===0&&S<c.length&&c!==this)for(;S<c.length;S++)this.words[S]=c.words[S];return this.length=Math.max(this.length,S),c!==this&&(this.negative=1),this.strip()},l.prototype.sub=function(d){return this.clone().isub(d)};function R(L,d,v){v.negative=d.negative^L.negative;var w=L.length+d.length|0;v.length=w,w=w-1|0;var c=L.words[0]|0,p=d.words[0]|0,x=c*p,S=x&67108863,b=x/67108864|0;v.words[0]=S;for(var h=1;h<w;h++){for(var T=b>>>26,M=b&67108863,O=Math.min(h,d.length-1),V=Math.max(0,h-L.length+1);V<=O;V++){var ee=h-V|0;c=L.words[ee]|0,p=d.words[V]|0,x=c*p+M,T+=x/67108864|0,M=x&67108863}v.words[h]=M|0,b=T|0}return b!==0?v.words[h]=b|0:v.length--,v.strip()}var B=function(d,v,w){var c=d.words,p=v.words,x=w.words,S=0,b,h,T,M=c[0]|0,O=M&8191,V=M>>>13,ee=c[1]|0,Z=ee&8191,U=ee>>>13,z=c[2]|0,ne=z&8191,fe=z>>>13,me=c[3]|0,de=me&8191,je=me>>>13,lt=c[4]|0,it=lt&8191,ot=lt>>>13,Ct=c[5]|0,nt=Ct&8191,Je=Ct>>>13,tt=c[6]|0,rt=tt&8191,ht=tt>>>13,Ot=c[7]|0,Ve=Ot&8191,We=Ot>>>13,Gt=c[8]|0,wt=Gt&8191,Et=Gt>>>13,Yt=c[9]|0,Ce=Yt&8191,te=Yt>>>13,ye=p[0]|0,Le=ye&8191,Ue=ye>>>13,Qe=p[1]|0,Ke=Qe&8191,De=Qe>>>13,Vt=p[2]|0,At=Vt&8191,ve=Vt>>>13,Pt=p[3]|0,pt=Pt&8191,Ne=Pt>>>13,vt=p[4]|0,ut=vt&8191,$t=vt>>>13,fi=p[5]|0,kt=fi&8191,Wt=fi>>>13,Zi=p[6]|0,Ut=Zi&8191,Xt=Zi>>>13,Be=p[7]|0,be=Be&8191,ge=Be>>>13,oe=p[8]|0,Ae=oe&8191,qe=oe>>>13,bt=p[9]|0,at=bt&8191,gt=bt>>>13;w.negative=d.negative^v.negative,w.length=19,b=Math.imul(O,Le),h=Math.imul(O,Ue),h=h+Math.imul(V,Le)|0,T=Math.imul(V,Ue);var ei=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ei>>>26)|0,ei&=67108863,b=Math.imul(Z,Le),h=Math.imul(Z,Ue),h=h+Math.imul(U,Le)|0,T=Math.imul(U,Ue),b=b+Math.imul(O,Ke)|0,h=h+Math.imul(O,De)|0,h=h+Math.imul(V,Ke)|0,T=T+Math.imul(V,De)|0;var ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ii>>>26)|0,ii&=67108863,b=Math.imul(ne,Le),h=Math.imul(ne,Ue),h=h+Math.imul(fe,Le)|0,T=Math.imul(fe,Ue),b=b+Math.imul(Z,Ke)|0,h=h+Math.imul(Z,De)|0,h=h+Math.imul(U,Ke)|0,T=T+Math.imul(U,De)|0,b=b+Math.imul(O,At)|0,h=h+Math.imul(O,ve)|0,h=h+Math.imul(V,At)|0,T=T+Math.imul(V,ve)|0;var Bi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Bi>>>26)|0,Bi&=67108863,b=Math.imul(de,Le),h=Math.imul(de,Ue),h=h+Math.imul(je,Le)|0,T=Math.imul(je,Ue),b=b+Math.imul(ne,Ke)|0,h=h+Math.imul(ne,De)|0,h=h+Math.imul(fe,Ke)|0,T=T+Math.imul(fe,De)|0,b=b+Math.imul(Z,At)|0,h=h+Math.imul(Z,ve)|0,h=h+Math.imul(U,At)|0,T=T+Math.imul(U,ve)|0,b=b+Math.imul(O,pt)|0,h=h+Math.imul(O,Ne)|0,h=h+Math.imul(V,pt)|0,T=T+Math.imul(V,Ne)|0;var hi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(hi>>>26)|0,hi&=67108863,b=Math.imul(it,Le),h=Math.imul(it,Ue),h=h+Math.imul(ot,Le)|0,T=Math.imul(ot,Ue),b=b+Math.imul(de,Ke)|0,h=h+Math.imul(de,De)|0,h=h+Math.imul(je,Ke)|0,T=T+Math.imul(je,De)|0,b=b+Math.imul(ne,At)|0,h=h+Math.imul(ne,ve)|0,h=h+Math.imul(fe,At)|0,T=T+Math.imul(fe,ve)|0,b=b+Math.imul(Z,pt)|0,h=h+Math.imul(Z,Ne)|0,h=h+Math.imul(U,pt)|0,T=T+Math.imul(U,Ne)|0,b=b+Math.imul(O,ut)|0,h=h+Math.imul(O,$t)|0,h=h+Math.imul(V,ut)|0,T=T+Math.imul(V,$t)|0;var Di=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Di>>>26)|0,Di&=67108863,b=Math.imul(nt,Le),h=Math.imul(nt,Ue),h=h+Math.imul(Je,Le)|0,T=Math.imul(Je,Ue),b=b+Math.imul(it,Ke)|0,h=h+Math.imul(it,De)|0,h=h+Math.imul(ot,Ke)|0,T=T+Math.imul(ot,De)|0,b=b+Math.imul(de,At)|0,h=h+Math.imul(de,ve)|0,h=h+Math.imul(je,At)|0,T=T+Math.imul(je,ve)|0,b=b+Math.imul(ne,pt)|0,h=h+Math.imul(ne,Ne)|0,h=h+Math.imul(fe,pt)|0,T=T+Math.imul(fe,Ne)|0,b=b+Math.imul(Z,ut)|0,h=h+Math.imul(Z,$t)|0,h=h+Math.imul(U,ut)|0,T=T+Math.imul(U,$t)|0,b=b+Math.imul(O,kt)|0,h=h+Math.imul(O,Wt)|0,h=h+Math.imul(V,kt)|0,T=T+Math.imul(V,Wt)|0;var ni=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ni>>>26)|0,ni&=67108863,b=Math.imul(rt,Le),h=Math.imul(rt,Ue),h=h+Math.imul(ht,Le)|0,T=Math.imul(ht,Ue),b=b+Math.imul(nt,Ke)|0,h=h+Math.imul(nt,De)|0,h=h+Math.imul(Je,Ke)|0,T=T+Math.imul(Je,De)|0,b=b+Math.imul(it,At)|0,h=h+Math.imul(it,ve)|0,h=h+Math.imul(ot,At)|0,T=T+Math.imul(ot,ve)|0,b=b+Math.imul(de,pt)|0,h=h+Math.imul(de,Ne)|0,h=h+Math.imul(je,pt)|0,T=T+Math.imul(je,Ne)|0,b=b+Math.imul(ne,ut)|0,h=h+Math.imul(ne,$t)|0,h=h+Math.imul(fe,ut)|0,T=T+Math.imul(fe,$t)|0,b=b+Math.imul(Z,kt)|0,h=h+Math.imul(Z,Wt)|0,h=h+Math.imul(U,kt)|0,T=T+Math.imul(U,Wt)|0,b=b+Math.imul(O,Ut)|0,h=h+Math.imul(O,Xt)|0,h=h+Math.imul(V,Ut)|0,T=T+Math.imul(V,Xt)|0;var pi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(pi>>>26)|0,pi&=67108863,b=Math.imul(Ve,Le),h=Math.imul(Ve,Ue),h=h+Math.imul(We,Le)|0,T=Math.imul(We,Ue),b=b+Math.imul(rt,Ke)|0,h=h+Math.imul(rt,De)|0,h=h+Math.imul(ht,Ke)|0,T=T+Math.imul(ht,De)|0,b=b+Math.imul(nt,At)|0,h=h+Math.imul(nt,ve)|0,h=h+Math.imul(Je,At)|0,T=T+Math.imul(Je,ve)|0,b=b+Math.imul(it,pt)|0,h=h+Math.imul(it,Ne)|0,h=h+Math.imul(ot,pt)|0,T=T+Math.imul(ot,Ne)|0,b=b+Math.imul(de,ut)|0,h=h+Math.imul(de,$t)|0,h=h+Math.imul(je,ut)|0,T=T+Math.imul(je,$t)|0,b=b+Math.imul(ne,kt)|0,h=h+Math.imul(ne,Wt)|0,h=h+Math.imul(fe,kt)|0,T=T+Math.imul(fe,Wt)|0,b=b+Math.imul(Z,Ut)|0,h=h+Math.imul(Z,Xt)|0,h=h+Math.imul(U,Ut)|0,T=T+Math.imul(U,Xt)|0,b=b+Math.imul(O,be)|0,h=h+Math.imul(O,ge)|0,h=h+Math.imul(V,be)|0,T=T+Math.imul(V,ge)|0;var Ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ii>>>26)|0,Ii&=67108863,b=Math.imul(wt,Le),h=Math.imul(wt,Ue),h=h+Math.imul(Et,Le)|0,T=Math.imul(Et,Ue),b=b+Math.imul(Ve,Ke)|0,h=h+Math.imul(Ve,De)|0,h=h+Math.imul(We,Ke)|0,T=T+Math.imul(We,De)|0,b=b+Math.imul(rt,At)|0,h=h+Math.imul(rt,ve)|0,h=h+Math.imul(ht,At)|0,T=T+Math.imul(ht,ve)|0,b=b+Math.imul(nt,pt)|0,h=h+Math.imul(nt,Ne)|0,h=h+Math.imul(Je,pt)|0,T=T+Math.imul(Je,Ne)|0,b=b+Math.imul(it,ut)|0,h=h+Math.imul(it,$t)|0,h=h+Math.imul(ot,ut)|0,T=T+Math.imul(ot,$t)|0,b=b+Math.imul(de,kt)|0,h=h+Math.imul(de,Wt)|0,h=h+Math.imul(je,kt)|0,T=T+Math.imul(je,Wt)|0,b=b+Math.imul(ne,Ut)|0,h=h+Math.imul(ne,Xt)|0,h=h+Math.imul(fe,Ut)|0,T=T+Math.imul(fe,Xt)|0,b=b+Math.imul(Z,be)|0,h=h+Math.imul(Z,ge)|0,h=h+Math.imul(U,be)|0,T=T+Math.imul(U,ge)|0,b=b+Math.imul(O,Ae)|0,h=h+Math.imul(O,qe)|0,h=h+Math.imul(V,Ae)|0,T=T+Math.imul(V,qe)|0;var Ci=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ci>>>26)|0,Ci&=67108863,b=Math.imul(Ce,Le),h=Math.imul(Ce,Ue),h=h+Math.imul(te,Le)|0,T=Math.imul(te,Ue),b=b+Math.imul(wt,Ke)|0,h=h+Math.imul(wt,De)|0,h=h+Math.imul(Et,Ke)|0,T=T+Math.imul(Et,De)|0,b=b+Math.imul(Ve,At)|0,h=h+Math.imul(Ve,ve)|0,h=h+Math.imul(We,At)|0,T=T+Math.imul(We,ve)|0,b=b+Math.imul(rt,pt)|0,h=h+Math.imul(rt,Ne)|0,h=h+Math.imul(ht,pt)|0,T=T+Math.imul(ht,Ne)|0,b=b+Math.imul(nt,ut)|0,h=h+Math.imul(nt,$t)|0,h=h+Math.imul(Je,ut)|0,T=T+Math.imul(Je,$t)|0,b=b+Math.imul(it,kt)|0,h=h+Math.imul(it,Wt)|0,h=h+Math.imul(ot,kt)|0,T=T+Math.imul(ot,Wt)|0,b=b+Math.imul(de,Ut)|0,h=h+Math.imul(de,Xt)|0,h=h+Math.imul(je,Ut)|0,T=T+Math.imul(je,Xt)|0,b=b+Math.imul(ne,be)|0,h=h+Math.imul(ne,ge)|0,h=h+Math.imul(fe,be)|0,T=T+Math.imul(fe,ge)|0,b=b+Math.imul(Z,Ae)|0,h=h+Math.imul(Z,qe)|0,h=h+Math.imul(U,Ae)|0,T=T+Math.imul(U,qe)|0,b=b+Math.imul(O,at)|0,h=h+Math.imul(O,gt)|0,h=h+Math.imul(V,at)|0,T=T+Math.imul(V,gt)|0;var zi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zi>>>26)|0,zi&=67108863,b=Math.imul(Ce,Ke),h=Math.imul(Ce,De),h=h+Math.imul(te,Ke)|0,T=Math.imul(te,De),b=b+Math.imul(wt,At)|0,h=h+Math.imul(wt,ve)|0,h=h+Math.imul(Et,At)|0,T=T+Math.imul(Et,ve)|0,b=b+Math.imul(Ve,pt)|0,h=h+Math.imul(Ve,Ne)|0,h=h+Math.imul(We,pt)|0,T=T+Math.imul(We,Ne)|0,b=b+Math.imul(rt,ut)|0,h=h+Math.imul(rt,$t)|0,h=h+Math.imul(ht,ut)|0,T=T+Math.imul(ht,$t)|0,b=b+Math.imul(nt,kt)|0,h=h+Math.imul(nt,Wt)|0,h=h+Math.imul(Je,kt)|0,T=T+Math.imul(Je,Wt)|0,b=b+Math.imul(it,Ut)|0,h=h+Math.imul(it,Xt)|0,h=h+Math.imul(ot,Ut)|0,T=T+Math.imul(ot,Xt)|0,b=b+Math.imul(de,be)|0,h=h+Math.imul(de,ge)|0,h=h+Math.imul(je,be)|0,T=T+Math.imul(je,ge)|0,b=b+Math.imul(ne,Ae)|0,h=h+Math.imul(ne,qe)|0,h=h+Math.imul(fe,Ae)|0,T=T+Math.imul(fe,qe)|0,b=b+Math.imul(Z,at)|0,h=h+Math.imul(Z,gt)|0,h=h+Math.imul(U,at)|0,T=T+Math.imul(U,gt)|0;var qi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(qi>>>26)|0,qi&=67108863,b=Math.imul(Ce,At),h=Math.imul(Ce,ve),h=h+Math.imul(te,At)|0,T=Math.imul(te,ve),b=b+Math.imul(wt,pt)|0,h=h+Math.imul(wt,Ne)|0,h=h+Math.imul(Et,pt)|0,T=T+Math.imul(Et,Ne)|0,b=b+Math.imul(Ve,ut)|0,h=h+Math.imul(Ve,$t)|0,h=h+Math.imul(We,ut)|0,T=T+Math.imul(We,$t)|0,b=b+Math.imul(rt,kt)|0,h=h+Math.imul(rt,Wt)|0,h=h+Math.imul(ht,kt)|0,T=T+Math.imul(ht,Wt)|0,b=b+Math.imul(nt,Ut)|0,h=h+Math.imul(nt,Xt)|0,h=h+Math.imul(Je,Ut)|0,T=T+Math.imul(Je,Xt)|0,b=b+Math.imul(it,be)|0,h=h+Math.imul(it,ge)|0,h=h+Math.imul(ot,be)|0,T=T+Math.imul(ot,ge)|0,b=b+Math.imul(de,Ae)|0,h=h+Math.imul(de,qe)|0,h=h+Math.imul(je,Ae)|0,T=T+Math.imul(je,qe)|0,b=b+Math.imul(ne,at)|0,h=h+Math.imul(ne,gt)|0,h=h+Math.imul(fe,at)|0,T=T+Math.imul(fe,gt)|0;var Ai=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ai>>>26)|0,Ai&=67108863,b=Math.imul(Ce,pt),h=Math.imul(Ce,Ne),h=h+Math.imul(te,pt)|0,T=Math.imul(te,Ne),b=b+Math.imul(wt,ut)|0,h=h+Math.imul(wt,$t)|0,h=h+Math.imul(Et,ut)|0,T=T+Math.imul(Et,$t)|0,b=b+Math.imul(Ve,kt)|0,h=h+Math.imul(Ve,Wt)|0,h=h+Math.imul(We,kt)|0,T=T+Math.imul(We,Wt)|0,b=b+Math.imul(rt,Ut)|0,h=h+Math.imul(rt,Xt)|0,h=h+Math.imul(ht,Ut)|0,T=T+Math.imul(ht,Xt)|0,b=b+Math.imul(nt,be)|0,h=h+Math.imul(nt,ge)|0,h=h+Math.imul(Je,be)|0,T=T+Math.imul(Je,ge)|0,b=b+Math.imul(it,Ae)|0,h=h+Math.imul(it,qe)|0,h=h+Math.imul(ot,Ae)|0,T=T+Math.imul(ot,qe)|0,b=b+Math.imul(de,at)|0,h=h+Math.imul(de,gt)|0,h=h+Math.imul(je,at)|0,T=T+Math.imul(je,gt)|0;var Oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Oi>>>26)|0,Oi&=67108863,b=Math.imul(Ce,ut),h=Math.imul(Ce,$t),h=h+Math.imul(te,ut)|0,T=Math.imul(te,$t),b=b+Math.imul(wt,kt)|0,h=h+Math.imul(wt,Wt)|0,h=h+Math.imul(Et,kt)|0,T=T+Math.imul(Et,Wt)|0,b=b+Math.imul(Ve,Ut)|0,h=h+Math.imul(Ve,Xt)|0,h=h+Math.imul(We,Ut)|0,T=T+Math.imul(We,Xt)|0,b=b+Math.imul(rt,be)|0,h=h+Math.imul(rt,ge)|0,h=h+Math.imul(ht,be)|0,T=T+Math.imul(ht,ge)|0,b=b+Math.imul(nt,Ae)|0,h=h+Math.imul(nt,qe)|0,h=h+Math.imul(Je,Ae)|0,T=T+Math.imul(Je,qe)|0,b=b+Math.imul(it,at)|0,h=h+Math.imul(it,gt)|0,h=h+Math.imul(ot,at)|0,T=T+Math.imul(ot,gt)|0;var ki=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ki>>>26)|0,ki&=67108863,b=Math.imul(Ce,kt),h=Math.imul(Ce,Wt),h=h+Math.imul(te,kt)|0,T=Math.imul(te,Wt),b=b+Math.imul(wt,Ut)|0,h=h+Math.imul(wt,Xt)|0,h=h+Math.imul(Et,Ut)|0,T=T+Math.imul(Et,Xt)|0,b=b+Math.imul(Ve,be)|0,h=h+Math.imul(Ve,ge)|0,h=h+Math.imul(We,be)|0,T=T+Math.imul(We,ge)|0,b=b+Math.imul(rt,Ae)|0,h=h+Math.imul(rt,qe)|0,h=h+Math.imul(ht,Ae)|0,T=T+Math.imul(ht,qe)|0,b=b+Math.imul(nt,at)|0,h=h+Math.imul(nt,gt)|0,h=h+Math.imul(Je,at)|0,T=T+Math.imul(Je,gt)|0;var Ti=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ti>>>26)|0,Ti&=67108863,b=Math.imul(Ce,Ut),h=Math.imul(Ce,Xt),h=h+Math.imul(te,Ut)|0,T=Math.imul(te,Xt),b=b+Math.imul(wt,be)|0,h=h+Math.imul(wt,ge)|0,h=h+Math.imul(Et,be)|0,T=T+Math.imul(Et,ge)|0,b=b+Math.imul(Ve,Ae)|0,h=h+Math.imul(Ve,qe)|0,h=h+Math.imul(We,Ae)|0,T=T+Math.imul(We,qe)|0,b=b+Math.imul(rt,at)|0,h=h+Math.imul(rt,gt)|0,h=h+Math.imul(ht,at)|0,T=T+Math.imul(ht,gt)|0;var wi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(wi>>>26)|0,wi&=67108863,b=Math.imul(Ce,be),h=Math.imul(Ce,ge),h=h+Math.imul(te,be)|0,T=Math.imul(te,ge),b=b+Math.imul(wt,Ae)|0,h=h+Math.imul(wt,qe)|0,h=h+Math.imul(Et,Ae)|0,T=T+Math.imul(Et,qe)|0,b=b+Math.imul(Ve,at)|0,h=h+Math.imul(Ve,gt)|0,h=h+Math.imul(We,at)|0,T=T+Math.imul(We,gt)|0;var oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(oi>>>26)|0,oi&=67108863,b=Math.imul(Ce,Ae),h=Math.imul(Ce,qe),h=h+Math.imul(te,Ae)|0,T=Math.imul(te,qe),b=b+Math.imul(wt,at)|0,h=h+Math.imul(wt,gt)|0,h=h+Math.imul(Et,at)|0,T=T+Math.imul(Et,gt)|0;var zt=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zt>>>26)|0,zt&=67108863,b=Math.imul(Ce,at),h=Math.imul(Ce,gt),h=h+Math.imul(te,at)|0,T=Math.imul(te,gt);var Qt=(S+b|0)+((h&8191)<<13)|0;return S=(T+(h>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,x[0]=ei,x[1]=ii,x[2]=Bi,x[3]=hi,x[4]=Di,x[5]=ni,x[6]=pi,x[7]=Ii,x[8]=Ci,x[9]=zi,x[10]=qi,x[11]=Ai,x[12]=Oi,x[13]=ki,x[14]=Ti,x[15]=wi,x[16]=oi,x[17]=zt,x[18]=Qt,S!==0&&(x[19]=S,w.length++),w};Math.imul||(B=R);function F(L,d,v){v.negative=d.negative^L.negative,v.length=L.length+d.length;for(var w=0,c=0,p=0;p<v.length-1;p++){var x=c;c=0;for(var S=w&67108863,b=Math.min(p,d.length-1),h=Math.max(0,p-L.length+1);h<=b;h++){var T=p-h,M=L.words[T]|0,O=d.words[h]|0,V=M*O,ee=V&67108863;x=x+(V/67108864|0)|0,ee=ee+S|0,S=ee&67108863,x=x+(ee>>>26)|0,c+=x>>>26,x&=67108863}v.words[p]=S,w=x,x=c}return w!==0?v.words[p]=w:v.length--,v.strip()}function j(L,d,v){var w=new N;return w.mulp(L,d,v)}l.prototype.mulTo=function(d,v){var w,c=this.length+d.length;return this.length===10&&d.length===10?w=B(this,d,v):c<63?w=R(this,d,v):c<1024?w=F(this,d,v):w=j(this,d,v),w};function N(L,d){this.x=L,this.y=d}N.prototype.makeRBT=function(d){for(var v=new Array(d),w=l.prototype._countBits(d)-1,c=0;c<d;c++)v[c]=this.revBin(c,w,d);return v},N.prototype.revBin=function(d,v,w){if(d===0||d===w-1)return d;for(var c=0,p=0;p<v;p++)c|=(d&1)<<v-p-1,d>>=1;return c},N.prototype.permute=function(d,v,w,c,p,x){for(var S=0;S<x;S++)c[S]=v[d[S]],p[S]=w[d[S]]},N.prototype.transform=function(d,v,w,c,p,x){this.permute(x,d,v,w,c,p);for(var S=1;S<p;S<<=1)for(var b=S<<1,h=Math.cos(2*Math.PI/b),T=Math.sin(2*Math.PI/b),M=0;M<p;M+=b)for(var O=h,V=T,ee=0;ee<S;ee++){var Z=w[M+ee],U=c[M+ee],z=w[M+ee+S],ne=c[M+ee+S],fe=O*z-V*ne;ne=O*ne+V*z,z=fe,w[M+ee]=Z+z,c[M+ee]=U+ne,w[M+ee+S]=Z-z,c[M+ee+S]=U-ne,ee!==b&&(fe=h*O-T*V,V=h*V+T*O,O=fe)}},N.prototype.guessLen13b=function(d,v){var w=Math.max(v,d)|1,c=w&1,p=0;for(w=w/2|0;w;w=w>>>1)p++;return 1<<p+1+c},N.prototype.conjugate=function(d,v,w){if(!(w<=1))for(var c=0;c<w/2;c++){var p=d[c];d[c]=d[w-c-1],d[w-c-1]=p,p=v[c],v[c]=-v[w-c-1],v[w-c-1]=-p}},N.prototype.normalize13b=function(d,v){for(var w=0,c=0;c<v/2;c++){var p=Math.round(d[2*c+1]/v)*8192+Math.round(d[2*c]/v)+w;d[c]=p&67108863,p<67108864?w=0:w=p/67108864|0}return d},N.prototype.convert13b=function(d,v,w,c){for(var p=0,x=0;x<v;x++)p=p+(d[x]|0),w[2*x]=p&8191,p=p>>>13,w[2*x+1]=p&8191,p=p>>>13;for(x=2*v;x<c;++x)w[x]=0;o(p===0),o((p&-8192)===0)},N.prototype.stub=function(d){for(var v=new Array(d),w=0;w<d;w++)v[w]=0;return v},N.prototype.mulp=function(d,v,w){var c=2*this.guessLen13b(d.length,v.length),p=this.makeRBT(c),x=this.stub(c),S=new Array(c),b=new Array(c),h=new Array(c),T=new Array(c),M=new Array(c),O=new Array(c),V=w.words;V.length=c,this.convert13b(d.words,d.length,S,c),this.convert13b(v.words,v.length,T,c),this.transform(S,x,b,h,c,p),this.transform(T,x,M,O,c,p);for(var ee=0;ee<c;ee++){var Z=b[ee]*M[ee]-h[ee]*O[ee];h[ee]=b[ee]*O[ee]+h[ee]*M[ee],b[ee]=Z}return this.conjugate(b,h,c),this.transform(b,h,V,x,c,p),this.conjugate(V,x,c),this.normalize13b(V,c),w.negative=d.negative^v.negative,w.length=d.length+v.length,w.strip()},l.prototype.mul=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),this.mulTo(d,v)},l.prototype.mulf=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),j(this,d,v)},l.prototype.imul=function(d){return this.clone().mulTo(d,this)},l.prototype.imuln=function(d){o(typeof d=="number"),o(d<67108864);for(var v=0,w=0;w<this.length;w++){var c=(this.words[w]|0)*d,p=(c&67108863)+(v&67108863);v>>=26,v+=c/67108864|0,v+=p>>>26,this.words[w]=p&67108863}return v!==0&&(this.words[w]=v,this.length++),this},l.prototype.muln=function(d){return this.clone().imuln(d)},l.prototype.sqr=function(){return this.mul(this)},l.prototype.isqr=function(){return this.imul(this.clone())},l.prototype.pow=function(d){var v=P(d);if(v.length===0)return new l(1);for(var w=this,c=0;c<v.length&&v[c]===0;c++,w=w.sqr());if(++c<v.length)for(var p=w.sqr();c<v.length;c++,p=p.sqr())v[c]!==0&&(w=w.mul(p));return w},l.prototype.iushln=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=67108863>>>26-v<<26-v,p;if(v!==0){var x=0;for(p=0;p<this.length;p++){var S=this.words[p]&c,b=(this.words[p]|0)-S<<v;this.words[p]=b|x,x=S>>>26-v}x&&(this.words[p]=x,this.length++)}if(w!==0){for(p=this.length-1;p>=0;p--)this.words[p+w]=this.words[p];for(p=0;p<w;p++)this.words[p]=0;this.length+=w}return this.strip()},l.prototype.ishln=function(d){return o(this.negative===0),this.iushln(d)},l.prototype.iushrn=function(d,v,w){o(typeof d=="number"&&d>=0);var c;v?c=(v-v%26)/26:c=0;var p=d%26,x=Math.min((d-p)/26,this.length),S=67108863^67108863>>>p<<p,b=w;if(c-=x,c=Math.max(0,c),b){for(var h=0;h<x;h++)b.words[h]=this.words[h];b.length=x}if(x!==0)if(this.length>x)for(this.length-=x,h=0;h<this.length;h++)this.words[h]=this.words[h+x];else this.words[0]=0,this.length=1;var T=0;for(h=this.length-1;h>=0&&(T!==0||h>=c);h--){var M=this.words[h]|0;this.words[h]=T<<26-p|M>>>p,T=M&S}return b&&T!==0&&(b.words[b.length++]=T),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},l.prototype.ishrn=function(d,v,w){return o(this.negative===0),this.iushrn(d,v,w)},l.prototype.shln=function(d){return this.clone().ishln(d)},l.prototype.ushln=function(d){return this.clone().iushln(d)},l.prototype.shrn=function(d){return this.clone().ishrn(d)},l.prototype.ushrn=function(d){return this.clone().iushrn(d)},l.prototype.testn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return!1;var p=this.words[w];return!!(p&c)},l.prototype.imaskn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26;if(o(this.negative===0,"imaskn works only with positive numbers"),this.length<=w)return this;if(v!==0&&w++,this.length=Math.min(w,this.length),v!==0){var c=67108863^67108863>>>v<<v;this.words[this.length-1]&=c}return this.strip()},l.prototype.maskn=function(d){return this.clone().imaskn(d)},l.prototype.iaddn=function(d){return o(typeof d=="number"),o(d<67108864),d<0?this.isubn(-d):this.negative!==0?this.length===1&&(this.words[0]|0)<d?(this.words[0]=d-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(d),this.negative=1,this):this._iaddn(d)},l.prototype._iaddn=function(d){this.words[0]+=d;for(var v=0;v<this.length&&this.words[v]>=67108864;v++)this.words[v]-=67108864,v===this.length-1?this.words[v+1]=1:this.words[v+1]++;return this.length=Math.max(this.length,v+1),this},l.prototype.isubn=function(d){if(o(typeof d=="number"),o(d<67108864),d<0)return this.iaddn(-d);if(this.negative!==0)return this.negative=0,this.iaddn(d),this.negative=1,this;if(this.words[0]-=d,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var v=0;v<this.length&&this.words[v]<0;v++)this.words[v]+=67108864,this.words[v+1]-=1;return this.strip()},l.prototype.addn=function(d){return this.clone().iaddn(d)},l.prototype.subn=function(d){return this.clone().isubn(d)},l.prototype.iabs=function(){return this.negative=0,this},l.prototype.abs=function(){return this.clone().iabs()},l.prototype._ishlnsubmul=function(d,v,w){var c=d.length+w,p;this._expand(c);var x,S=0;for(p=0;p<d.length;p++){x=(this.words[p+w]|0)+S;var b=(d.words[p]|0)*v;x-=b&67108863,S=(x>>26)-(b/67108864|0),this.words[p+w]=x&67108863}for(;p<this.length-w;p++)x=(this.words[p+w]|0)+S,S=x>>26,this.words[p+w]=x&67108863;if(S===0)return this.strip();for(o(S===-1),S=0,p=0;p<this.length;p++)x=-(this.words[p]|0)+S,S=x>>26,this.words[p]=x&67108863;return this.negative=1,this.strip()},l.prototype._wordDiv=function(d,v){var w=this.length-d.length,c=this.clone(),p=d,x=p.words[p.length-1]|0,S=this._countBits(x);w=26-S,w!==0&&(p=p.ushln(w),c.iushln(w),x=p.words[p.length-1]|0);var b=c.length-p.length,h;if(v!=="mod"){h=new l(null),h.length=b+1,h.words=new Array(h.length);for(var T=0;T<h.length;T++)h.words[T]=0}var M=c.clone()._ishlnsubmul(p,1,b);M.negative===0&&(c=M,h&&(h.words[b]=1));for(var O=b-1;O>=0;O--){var V=(c.words[p.length+O]|0)*67108864+(c.words[p.length+O-1]|0);for(V=Math.min(V/x|0,67108863),c._ishlnsubmul(p,V,O);c.negative!==0;)V--,c.negative=0,c._ishlnsubmul(p,1,O),c.isZero()||(c.negative^=1);h&&(h.words[O]=V)}return h&&h.strip(),c.strip(),v!=="div"&&w!==0&&c.iushrn(w),{div:h||null,mod:c}},l.prototype.divmod=function(d,v,w){if(o(!d.isZero()),this.isZero())return{div:new l(0),mod:new l(0)};var c,p,x;return this.negative!==0&&d.negative===0?(x=this.neg().divmod(d,v),v!=="mod"&&(c=x.div.neg()),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.iadd(d)),{div:c,mod:p}):this.negative===0&&d.negative!==0?(x=this.divmod(d.neg(),v),v!=="mod"&&(c=x.div.neg()),{div:c,mod:x.mod}):this.negative&d.negative?(x=this.neg().divmod(d.neg(),v),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.isub(d)),{div:x.div,mod:p}):d.length>this.length||this.cmp(d)<0?{div:new l(0),mod:this}:d.length===1?v==="div"?{div:this.divn(d.words[0]),mod:null}:v==="mod"?{div:null,mod:new l(this.modn(d.words[0]))}:{div:this.divn(d.words[0]),mod:new l(this.modn(d.words[0]))}:this._wordDiv(d,v)},l.prototype.div=function(d){return this.divmod(d,"div",!1).div},l.prototype.mod=function(d){return this.divmod(d,"mod",!1).mod},l.prototype.umod=function(d){return this.divmod(d,"mod",!0).mod},l.prototype.divRound=function(d){var v=this.divmod(d);if(v.mod.isZero())return v.div;var w=v.div.negative!==0?v.mod.isub(d):v.mod,c=d.ushrn(1),p=d.andln(1),x=w.cmp(c);return x<0||p===1&&x===0?v.div:v.div.negative!==0?v.div.isubn(1):v.div.iaddn(1)},l.prototype.modn=function(d){o(d<=67108863);for(var v=(1<<26)%d,w=0,c=this.length-1;c>=0;c--)w=(v*w+(this.words[c]|0))%d;return w},l.prototype.idivn=function(d){o(d<=67108863);for(var v=0,w=this.length-1;w>=0;w--){var c=(this.words[w]|0)+v*67108864;this.words[w]=c/d|0,v=c%d}return this.strip()},l.prototype.divn=function(d){return this.clone().idivn(d)},l.prototype.egcd=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=new l(0),S=new l(1),b=0;v.isEven()&&w.isEven();)v.iushrn(1),w.iushrn(1),++b;for(var h=w.clone(),T=v.clone();!v.isZero();){for(var M=0,O=1;!(v.words[0]&O)&&M<26;++M,O<<=1);if(M>0)for(v.iushrn(M);M-- >0;)(c.isOdd()||p.isOdd())&&(c.iadd(h),p.isub(T)),c.iushrn(1),p.iushrn(1);for(var V=0,ee=1;!(w.words[0]&ee)&&V<26;++V,ee<<=1);if(V>0)for(w.iushrn(V);V-- >0;)(x.isOdd()||S.isOdd())&&(x.iadd(h),S.isub(T)),x.iushrn(1),S.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(x),p.isub(S)):(w.isub(v),x.isub(c),S.isub(p))}return{a:x,b:S,gcd:w.iushln(b)}},l.prototype._invmp=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=w.clone();v.cmpn(1)>0&&w.cmpn(1)>0;){for(var S=0,b=1;!(v.words[0]&b)&&S<26;++S,b<<=1);if(S>0)for(v.iushrn(S);S-- >0;)c.isOdd()&&c.iadd(x),c.iushrn(1);for(var h=0,T=1;!(w.words[0]&T)&&h<26;++h,T<<=1);if(h>0)for(w.iushrn(h);h-- >0;)p.isOdd()&&p.iadd(x),p.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(p)):(w.isub(v),p.isub(c))}var M;return v.cmpn(1)===0?M=c:M=p,M.cmpn(0)<0&&M.iadd(d),M},l.prototype.gcd=function(d){if(this.isZero())return d.abs();if(d.isZero())return this.abs();var v=this.clone(),w=d.clone();v.negative=0,w.negative=0;for(var c=0;v.isEven()&&w.isEven();c++)v.iushrn(1),w.iushrn(1);do{for(;v.isEven();)v.iushrn(1);for(;w.isEven();)w.iushrn(1);var p=v.cmp(w);if(p<0){var x=v;v=w,w=x}else if(p===0||w.cmpn(1)===0)break;v.isub(w)}while(!0);return w.iushln(c)},l.prototype.invm=function(d){return this.egcd(d).a.umod(d)},l.prototype.isEven=function(){return(this.words[0]&1)===0},l.prototype.isOdd=function(){return(this.words[0]&1)===1},l.prototype.andln=function(d){return this.words[0]&d},l.prototype.bincn=function(d){o(typeof d=="number");var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return this._expand(w+1),this.words[w]|=c,this;for(var p=c,x=w;p!==0&&x<this.length;x++){var S=this.words[x]|0;S+=p,p=S>>>26,S&=67108863,this.words[x]=S}return p!==0&&(this.words[x]=p,this.length++),this},l.prototype.isZero=function(){return this.length===1&&this.words[0]===0},l.prototype.cmpn=function(d){var v=d<0;if(this.negative!==0&&!v)return-1;if(this.negative===0&&v)return 1;this.strip();var w;if(this.length>1)w=1;else{v&&(d=-d),o(d<=67108863,"Number is too big");var c=this.words[0]|0;w=c===d?0:c<d?-1:1}return this.negative!==0?-w|0:w},l.prototype.cmp=function(d){if(this.negative!==0&&d.negative===0)return-1;if(this.negative===0&&d.negative!==0)return 1;var v=this.ucmp(d);return this.negative!==0?-v|0:v},l.prototype.ucmp=function(d){if(this.length>d.length)return 1;if(this.length<d.length)return-1;for(var v=0,w=this.length-1;w>=0;w--){var c=this.words[w]|0,p=d.words[w]|0;if(c!==p){c<p?v=-1:c>p&&(v=1);break}}return v},l.prototype.gtn=function(d){return this.cmpn(d)===1},l.prototype.gt=function(d){return this.cmp(d)===1},l.prototype.gten=function(d){return this.cmpn(d)>=0},l.prototype.gte=function(d){return this.cmp(d)>=0},l.prototype.ltn=function(d){return this.cmpn(d)===-1},l.prototype.lt=function(d){return this.cmp(d)===-1},l.prototype.lten=function(d){return this.cmpn(d)<=0},l.prototype.lte=function(d){return this.cmp(d)<=0},l.prototype.eqn=function(d){return this.cmpn(d)===0},l.prototype.eq=function(d){return this.cmp(d)===0},l.red=function(d){return new he(d)},l.prototype.toRed=function(d){return o(!this.red,"Already a number in reduction context"),o(this.negative===0,"red works only with positives"),d.convertTo(this)._forceRed(d)},l.prototype.fromRed=function(){return o(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},l.prototype._forceRed=function(d){return this.red=d,this},l.prototype.forceRed=function(d){return o(!this.red,"Already a number in reduction context"),this._forceRed(d)},l.prototype.redAdd=function(d){return o(this.red,"redAdd works only with red numbers"),this.red.add(this,d)},l.prototype.redIAdd=function(d){return o(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,d)},l.prototype.redSub=function(d){return o(this.red,"redSub works only with red numbers"),this.red.sub(this,d)},l.prototype.redISub=function(d){return o(this.red,"redISub works only with red numbers"),this.red.isub(this,d)},l.prototype.redShl=function(d){return o(this.red,"redShl works only with red numbers"),this.red.shl(this,d)},l.prototype.redMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.mul(this,d)},l.prototype.redIMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.imul(this,d)},l.prototype.redSqr=function(){return o(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},l.prototype.redISqr=function(){return o(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},l.prototype.redSqrt=function(){return o(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},l.prototype.redInvm=function(){return o(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},l.prototype.redNeg=function(){return o(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},l.prototype.redPow=function(d){return o(this.red&&!d.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,d)};var Y={k256:null,p224:null,p192:null,p25519:null};function J(L,d){this.name=L,this.p=new l(d,16),this.n=this.p.bitLength(),this.k=new l(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}J.prototype._tmp=function(){var d=new l(null);return d.words=new Array(Math.ceil(this.n/13)),d},J.prototype.ireduce=function(d){var v=d,w;do this.split(v,this.tmp),v=this.imulK(v),v=v.iadd(this.tmp),w=v.bitLength();while(w>this.n);var c=w<this.n?-1:v.ucmp(this.p);return c===0?(v.words[0]=0,v.length=1):c>0?v.isub(this.p):v.strip!==void 0?v.strip():v._strip(),v},J.prototype.split=function(d,v){d.iushrn(this.n,0,v)},J.prototype.imulK=function(d){return d.imul(this.k)};function ie(){J.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}u(ie,J),ie.prototype.split=function(d,v){for(var w=4194303,c=Math.min(d.length,9),p=0;p<c;p++)v.words[p]=d.words[p];if(v.length=c,d.length<=9){d.words[0]=0,d.length=1;return}var x=d.words[9];for(v.words[v.length++]=x&w,p=10;p<d.length;p++){var S=d.words[p]|0;d.words[p-10]=(S&w)<<4|x>>>22,x=S}x>>>=22,d.words[p-10]=x,x===0&&d.length>10?d.length-=10:d.length-=9},ie.prototype.imulK=function(d){d.words[d.length]=0,d.words[d.length+1]=0,d.length+=2;for(var v=0,w=0;w<d.length;w++){var c=d.words[w]|0;v+=c*977,d.words[w]=v&67108863,v=c*64+(v/67108864|0)}return d.words[d.length-1]===0&&(d.length--,d.words[d.length-1]===0&&d.length--),d};function ue(){J.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}u(ue,J);function Q(){J.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}u(Q,J);function ce(){J.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}u(ce,J),ce.prototype.imulK=function(d){for(var v=0,w=0;w<d.length;w++){var c=(d.words[w]|0)*19+v,p=c&67108863;c>>>=26,d.words[w]=p,v=c}return v!==0&&(d.words[d.length++]=v),d},l._prime=function(d){if(Y[d])return Y[d];var v;if(d==="k256")v=new ie;else if(d==="p224")v=new ue;else if(d==="p192")v=new Q;else if(d==="p25519")v=new ce;else throw new Error("Unknown prime "+d);return Y[d]=v,v};function he(L){if(typeof L=="string"){var d=l._prime(L);this.m=d.p,this.prime=d}else o(L.gtn(1),"modulus must be greater than 1"),this.m=L,this.prime=null}he.prototype._verify1=function(d){o(d.negative===0,"red works only with positives"),o(d.red,"red works only with red numbers")},he.prototype._verify2=function(d,v){o((d.negative|v.negative)===0,"red works only with positives"),o(d.red&&d.red===v.red,"red works only with red numbers")},he.prototype.imod=function(d){return this.prime?this.prime.ireduce(d)._forceRed(this):d.umod(this.m)._forceRed(this)},he.prototype.neg=function(d){return d.isZero()?d.clone():this.m.sub(d)._forceRed(this)},he.prototype.add=function(d,v){this._verify2(d,v);var w=d.add(v);return w.cmp(this.m)>=0&&w.isub(this.m),w._forceRed(this)},he.prototype.iadd=function(d,v){this._verify2(d,v);var w=d.iadd(v);return w.cmp(this.m)>=0&&w.isub(this.m),w},he.prototype.sub=function(d,v){this._verify2(d,v);var w=d.sub(v);return w.cmpn(0)<0&&w.iadd(this.m),w._forceRed(this)},he.prototype.isub=function(d,v){this._verify2(d,v);var w=d.isub(v);return w.cmpn(0)<0&&w.iadd(this.m),w},he.prototype.shl=function(d,v){return this._verify1(d),this.imod(d.ushln(v))},he.prototype.imul=function(d,v){return this._verify2(d,v),this.imod(d.imul(v))},he.prototype.mul=function(d,v){return this._verify2(d,v),this.imod(d.mul(v))},he.prototype.isqr=function(d){return this.imul(d,d.clone())},he.prototype.sqr=function(d){return this.mul(d,d)},he.prototype.sqrt=function(d){if(d.isZero())return d.clone();var v=this.m.andln(3);if(o(v%2===1),v===3){var w=this.m.add(new l(1)).iushrn(2);return this.pow(d,w)}for(var c=this.m.subn(1),p=0;!c.isZero()&&c.andln(1)===0;)p++,c.iushrn(1);o(!c.isZero());var x=new l(1).toRed(this),S=x.redNeg(),b=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new l(2*h*h).toRed(this);this.pow(h,b).cmp(S)!==0;)h.redIAdd(S);for(var T=this.pow(h,c),M=this.pow(d,c.addn(1).iushrn(1)),O=this.pow(d,c),V=p;O.cmp(x)!==0;){for(var ee=O,Z=0;ee.cmp(x)!==0;Z++)ee=ee.redSqr();o(Z<V);var U=this.pow(T,new l(1).iushln(V-Z-1));M=M.redMul(U),T=U.redSqr(),O=O.redMul(T),V=Z}return M},he.prototype.invm=function(d){var v=d._invmp(this.m);return v.negative!==0?(v.negative=0,this.imod(v).redNeg()):this.imod(v)},he.prototype.pow=function(d,v){if(v.isZero())return new l(1).toRed(this);if(v.cmpn(1)===0)return d.clone();var w=4,c=new Array(1<<w);c[0]=new l(1).toRed(this),c[1]=d;for(var p=2;p<c.length;p++)c[p]=this.mul(c[p-1],d);var x=c[0],S=0,b=0,h=v.bitLength()%26;for(h===0&&(h=26),p=v.length-1;p>=0;p--){for(var T=v.words[p],M=h-1;M>=0;M--){var O=T>>M&1;if(x!==c[0]&&(x=this.sqr(x)),O===0&&S===0){b=0;continue}S<<=1,S|=O,b++,!(b!==w&&(p!==0||M!==0))&&(x=this.mul(x,c[S]),b=0,S=0)}h=26}return x},he.prototype.convertTo=function(d){var v=d.umod(this.m);return v===d?v.clone():v},he.prototype.convertFrom=function(d){var v=d.clone();return v.red=null,v},l.mont=function(d){return new ke(d)};function ke(L){he.call(this,L),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new l(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}u(ke,he),ke.prototype.convertTo=function(d){return this.imod(d.ushln(this.shift))},ke.prototype.convertFrom=function(d){var v=this.imod(d.mul(this.rinv));return v.red=null,v},ke.prototype.imul=function(d,v){if(d.isZero()||v.isZero())return d.words[0]=0,d.length=1,d;var w=d.imul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.mul=function(d,v){if(d.isZero()||v.isZero())return new l(0)._forceRed(this);var w=d.mul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.invm=function(d){var v=this.imod(d._invmp(this.m).mul(this.r2));return v._forceRed(this)}})(t,commonjsGlobal$1)}(bn$3);var bnExports$3=bn$3.exports,utils$n={};(function(t){var e=t;function n(l,m){if(Array.isArray(l))return l.slice();if(!l)return[];var y=[];if(typeof l!="string"){for(var E=0;E<l.length;E++)y[E]=l[E]|0;return y}if(m==="hex"){l=l.replace(/[^a-z0-9]+/ig,""),l.length%2!==0&&(l="0"+l);for(var E=0;E<l.length;E+=2)y.push(parseInt(l[E]+l[E+1],16))}else for(var E=0;E<l.length;E++){var C=l.charCodeAt(E),k=C>>8,A=C&255;k?y.push(k,A):y.push(A)}return y}e.toArray=n;function o(l){return l.length===1?"0"+l:l}e.zero2=o;function u(l){for(var m="",y=0;y<l.length;y++)m+=o(l[y].toString(16));return m}e.toHex=u,e.encode=function(m,y){return y==="hex"?u(m):m}})(utils$n),function(t){var e=t,n=bnExports$3,o=minimalisticAssert,u=utils$n;e.assert=o,e.toArray=u.toArray,e.zero2=u.zero2,e.toHex=u.toHex,e.encode=u.encode;function l(k,A,D){var P=new Array(Math.max(k.bitLength(),D)+1),R;for(R=0;R<P.length;R+=1)P[R]=0;var B=1<<A+1,F=k.clone();for(R=0;R<P.length;R++){var j,N=F.andln(B-1);F.isOdd()?(N>(B>>1)-1?j=(B>>1)-N:j=N,F.isubn(j)):j=0,P[R]=j,F.iushrn(1)}return P}e.getNAF=l;function m(k,A){var D=[[],[]];k=k.clone(),A=A.clone();for(var P=0,R=0,B;k.cmpn(-P)>0||A.cmpn(-R)>0;){var F=k.andln(3)+P&3,j=A.andln(3)+R&3;F===3&&(F=-1),j===3&&(j=-1);var N;F&1?(B=k.andln(7)+P&7,(B===3||B===5)&&j===2?N=-F:N=F):N=0,D[0].push(N);var Y;j&1?(B=A.andln(7)+R&7,(B===3||B===5)&&F===2?Y=-j:Y=j):Y=0,D[1].push(Y),2*P===N+1&&(P=1-P),2*R===Y+1&&(R=1-R),k.iushrn(1),A.iushrn(1)}return D}e.getJSF=m;function y(k,A,D){var P="_"+A;k.prototype[A]=function(){return this[P]!==void 0?this[P]:this[P]=D.call(this)}}e.cachedProperty=y;function E(k){return typeof k=="string"?e.toArray(k,"hex"):k}e.parseBytes=E;function C(k){return new n(k,"hex","le")}e.intFromLE=C}(utils$o);var curve={},BN$9=bnExports$3,utils$m=utils$o,getNAF=utils$m.getNAF,getJSF=utils$m.getJSF,assert$e=utils$m.assert;function BaseCurve(t,e){this.type=t,this.p=new BN$9(e.p,16),this.red=e.prime?BN$9.red(e.prime):BN$9.mont(this.p),this.zero=new BN$9(0).toRed(this.red),this.one=new BN$9(1).toRed(this.red),this.two=new BN$9(2).toRed(this.red),this.n=e.n&&new BN$9(e.n,16),this.g=e.g&&this.pointFromJSON(e.g,e.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var n=this.n&&this.p.div(this.n);!n||n.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var base$1=BaseCurve;BaseCurve.prototype.point=function(){throw new Error("Not implemented")},BaseCurve.prototype.validate=function(){throw new Error("Not implemented")},BaseCurve.prototype._fixedNafMul=function(e,n){assert$e(e.precomputed);var o=e._getDoubles(),u=getNAF(n,1,this._bitLength),l=(1<<o.step+1)-(o.step%2===0?2:1);l/=3;var m=[],y,E;for(y=0;y<u.length;y+=o.step){E=0;for(var C=y+o.step-1;C>=y;C--)E=(E<<1)+u[C];m.push(E)}for(var k=this.jpoint(null,null,null),A=this.jpoint(null,null,null),D=l;D>0;D--){for(y=0;y<m.length;y++)E=m[y],E===D?A=A.mixedAdd(o.points[y]):E===-D&&(A=A.mixedAdd(o.points[y].neg()));k=k.add(A)}return k.toP()},BaseCurve.prototype._wnafMul=function(e,n){var o=4,u=e._getNAFPoints(o);o=u.wnd;for(var l=u.points,m=getNAF(n,o,this._bitLength),y=this.jpoint(null,null,null),E=m.length-1;E>=0;E--){for(var C=0;E>=0&&m[E]===0;E--)C++;if(E>=0&&C++,y=y.dblp(C),E<0)break;var k=m[E];assert$e(k!==0),e.type==="affine"?k>0?y=y.mixedAdd(l[k-1>>1]):y=y.mixedAdd(l[-k-1>>1].neg()):k>0?y=y.add(l[k-1>>1]):y=y.add(l[-k-1>>1].neg())}return e.type==="affine"?y.toP():y},BaseCurve.prototype._wnafMulAdd=function(e,n,o,u,l){var m=this._wnafT1,y=this._wnafT2,E=this._wnafT3,C=0,k,A,D;for(k=0;k<u;k++){D=n[k];var P=D._getNAFPoints(e);m[k]=P.wnd,y[k]=P.points}for(k=u-1;k>=1;k-=2){var R=k-1,B=k;if(m[R]!==1||m[B]!==1){E[R]=getNAF(o[R],m[R],this._bitLength),E[B]=getNAF(o[B],m[B],this._bitLength),C=Math.max(E[R].length,C),C=Math.max(E[B].length,C);continue}var F=[n[R],null,null,n[B]];n[R].y.cmp(n[B].y)===0?(F[1]=n[R].add(n[B]),F[2]=n[R].toJ().mixedAdd(n[B].neg())):n[R].y.cmp(n[B].y.redNeg())===0?(F[1]=n[R].toJ().mixedAdd(n[B]),F[2]=n[R].add(n[B].neg())):(F[1]=n[R].toJ().mixedAdd(n[B]),F[2]=n[R].toJ().mixedAdd(n[B].neg()));var j=[-3,-1,-5,-7,0,7,5,1,3],N=getJSF(o[R],o[B]);for(C=Math.max(N[0].length,C),E[R]=new Array(C),E[B]=new Array(C),A=0;A<C;A++){var Y=N[0][A]|0,J=N[1][A]|0;E[R][A]=j[(Y+1)*3+(J+1)],E[B][A]=0,y[R]=F}}var ie=this.jpoint(null,null,null),ue=this._wnafT4;for(k=C;k>=0;k--){for(var Q=0;k>=0;){var ce=!0;for(A=0;A<u;A++)ue[A]=E[A][k]|0,ue[A]!==0&&(ce=!1);if(!ce)break;Q++,k--}if(k>=0&&Q++,ie=ie.dblp(Q),k<0)break;for(A=0;A<u;A++){var he=ue[A];he!==0&&(he>0?D=y[A][he-1>>1]:he<0&&(D=y[A][-he-1>>1].neg()),D.type==="affine"?ie=ie.mixedAdd(D):ie=ie.add(D))}}for(k=0;k<u;k++)y[k]=null;return l?ie:ie.toP()};function BasePoint(t,e){this.curve=t,this.type=e,this.precomputed=null}BaseCurve.BasePoint=BasePoint,BasePoint.prototype.eq=function(){throw new Error("Not implemented")},BasePoint.prototype.validate=function(){return this.curve.validate(this)},BaseCurve.prototype.decodePoint=function(e,n){e=utils$m.toArray(e,n);var o=this.p.byteLength();if((e[0]===4||e[0]===6||e[0]===7)&&e.length-1===2*o){e[0]===6?assert$e(e[e.length-1]%2===0):e[0]===7&&assert$e(e[e.length-1]%2===1);var u=this.point(e.slice(1,1+o),e.slice(1+o,1+2*o));return u}else if((e[0]===2||e[0]===3)&&e.length-1===o)return this.pointFromX(e.slice(1,1+o),e[0]===3);throw new Error("Unknown point format")},BasePoint.prototype.encodeCompressed=function(e){return this.encode(e,!0)},BasePoint.prototype._encode=function(e){var n=this.curve.p.byteLength(),o=this.getX().toArray("be",n);return e?[this.getY().isEven()?2:3].concat(o):[4].concat(o,this.getY().toArray("be",n))},BasePoint.prototype.encode=function(e,n){return utils$m.encode(this._encode(n),e)},BasePoint.prototype.precompute=function(e){if(this.precomputed)return this;var n={doubles:null,naf:null,beta:null};return n.naf=this._getNAFPoints(8),n.doubles=this._getDoubles(4,e),n.beta=this._getBeta(),this.precomputed=n,this},BasePoint.prototype._hasDoubles=function(e){if(!this.precomputed)return!1;var n=this.precomputed.doubles;return n?n.points.length>=Math.ceil((e.bitLength()+1)/n.step):!1},BasePoint.prototype._getDoubles=function(e,n){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var o=[this],u=this,l=0;l<n;l+=e){for(var m=0;m<e;m++)u=u.dbl();o.push(u)}return{step:e,points:o}},BasePoint.prototype._getNAFPoints=function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var n=[this],o=(1<<e)-1,u=o===1?null:this.dbl(),l=1;l<o;l++)n[l]=n[l-1].add(u);return{wnd:e,points:n}},BasePoint.prototype._getBeta=function(){return null},BasePoint.prototype.dblp=function(e){for(var n=this,o=0;o<e;o++)n=n.dbl();return n};var utils$l=utils$o,BN$8=bnExports$3,inherits$4=inherits_browserExports,Base$2=base$1,assert$d=utils$l.assert;function ShortCurve(t){Base$2.call(this,"short",t),this.a=new BN$8(t.a,16).toRed(this.red),this.b=new BN$8(t.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=this.a.fromRed().cmpn(0)===0,this.threeA=this.a.fromRed().sub(this.p).cmpn(-3)===0,this.endo=this._getEndomorphism(t),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}inherits$4(ShortCurve,Base$2);var short=ShortCurve;ShortCurve.prototype._getEndomorphism=function(e){if(!(!this.zeroA||!this.g||!this.n||this.p.modn(3)!==1)){var n,o;if(e.beta)n=new BN$8(e.beta,16).toRed(this.red);else{var u=this._getEndoRoots(this.p);n=u[0].cmp(u[1])<0?u[0]:u[1],n=n.toRed(this.red)}if(e.lambda)o=new BN$8(e.lambda,16);else{var l=this._getEndoRoots(this.n);this.g.mul(l[0]).x.cmp(this.g.x.redMul(n))===0?o=l[0]:(o=l[1],assert$d(this.g.mul(o).x.cmp(this.g.x.redMul(n))===0))}var m;return e.basis?m=e.basis.map(function(y){return{a:new BN$8(y.a,16),b:new BN$8(y.b,16)}}):m=this._getEndoBasis(o),{beta:n,lambda:o,basis:m}}},ShortCurve.prototype._getEndoRoots=function(e){var n=e===this.p?this.red:BN$8.mont(e),o=new BN$8(2).toRed(n).redInvm(),u=o.redNeg(),l=new BN$8(3).toRed(n).redNeg().redSqrt().redMul(o),m=u.redAdd(l).fromRed(),y=u.redSub(l).fromRed();return[m,y]},ShortCurve.prototype._getEndoBasis=function(e){for(var n=this.n.ushrn(Math.floor(this.n.bitLength()/2)),o=e,u=this.n.clone(),l=new BN$8(1),m=new BN$8(0),y=new BN$8(0),E=new BN$8(1),C,k,A,D,P,R,B,F=0,j,N;o.cmpn(0)!==0;){var Y=u.div(o);j=u.sub(Y.mul(o)),N=y.sub(Y.mul(l));var J=E.sub(Y.mul(m));if(!A&&j.cmp(n)<0)C=B.neg(),k=l,A=j.neg(),D=N;else if(A&&++F===2)break;B=j,u=o,o=j,y=l,l=N,E=m,m=J}P=j.neg(),R=N;var ie=A.sqr().add(D.sqr()),ue=P.sqr().add(R.sqr());return ue.cmp(ie)>=0&&(P=C,R=k),A.negative&&(A=A.neg(),D=D.neg()),P.negative&&(P=P.neg(),R=R.neg()),[{a:A,b:D},{a:P,b:R}]},ShortCurve.prototype._endoSplit=function(e){var n=this.endo.basis,o=n[0],u=n[1],l=u.b.mul(e).divRound(this.n),m=o.b.neg().mul(e).divRound(this.n),y=l.mul(o.a),E=m.mul(u.a),C=l.mul(o.b),k=m.mul(u.b),A=e.sub(y).sub(E),D=C.add(k).neg();return{k1:A,k2:D}},ShortCurve.prototype.pointFromX=function(e,n){e=new BN$8(e,16),e.red||(e=e.toRed(this.red));var o=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),u=o.redSqrt();if(u.redSqr().redSub(o).cmp(this.zero)!==0)throw new Error("invalid point");var l=u.fromRed().isOdd();return(n&&!l||!n&&l)&&(u=u.redNeg()),this.point(e,u)},ShortCurve.prototype.validate=function(e){if(e.inf)return!0;var n=e.x,o=e.y,u=this.a.redMul(n),l=n.redSqr().redMul(n).redIAdd(u).redIAdd(this.b);return o.redSqr().redISub(l).cmpn(0)===0},ShortCurve.prototype._endoWnafMulAdd=function(e,n,o){for(var u=this._endoWnafT1,l=this._endoWnafT2,m=0;m<e.length;m++){var y=this._endoSplit(n[m]),E=e[m],C=E._getBeta();y.k1.negative&&(y.k1.ineg(),E=E.neg(!0)),y.k2.negative&&(y.k2.ineg(),C=C.neg(!0)),u[m*2]=E,u[m*2+1]=C,l[m*2]=y.k1,l[m*2+1]=y.k2}for(var k=this._wnafMulAdd(1,u,l,m*2,o),A=0;A<m*2;A++)u[A]=null,l[A]=null;return k};function Point$2(t,e,n,o){Base$2.BasePoint.call(this,t,"affine"),e===null&&n===null?(this.x=null,this.y=null,this.inf=!0):(this.x=new BN$8(e,16),this.y=new BN$8(n,16),o&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}inherits$4(Point$2,Base$2.BasePoint),ShortCurve.prototype.point=function(e,n,o){return new Point$2(this,e,n,o)},ShortCurve.prototype.pointFromJSON=function(e,n){return Point$2.fromJSON(this,e,n)},Point$2.prototype._getBeta=function(){if(this.curve.endo){var e=this.precomputed;if(e&&e.beta)return e.beta;var n=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var o=this.curve,u=function(l){return o.point(l.x.redMul(o.endo.beta),l.y)};e.beta=n,n.precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(u)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(u)}}}return n}},Point$2.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},Point$2.fromJSON=function(e,n,o){typeof n=="string"&&(n=JSON.parse(n));var u=e.point(n[0],n[1],o);if(!n[2])return u;function l(y){return e.point(y[0],y[1],o)}var m=n[2];return u.precomputed={beta:null,doubles:m.doubles&&{step:m.doubles.step,points:[u].concat(m.doubles.points.map(l))},naf:m.naf&&{wnd:m.naf.wnd,points:[u].concat(m.naf.points.map(l))}},u},Point$2.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},Point$2.prototype.isInfinity=function(){return this.inf},Point$2.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(this.x.cmp(e.x)===0)return this.curve.point(null,null);var n=this.y.redSub(e.y);n.cmpn(0)!==0&&(n=n.redMul(this.x.redSub(e.x).redInvm()));var o=n.redSqr().redISub(this.x).redISub(e.x),u=n.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,u)},Point$2.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(e.cmpn(0)===0)return this.curve.point(null,null);var n=this.curve.a,o=this.x.redSqr(),u=e.redInvm(),l=o.redAdd(o).redIAdd(o).redIAdd(n).redMul(u),m=l.redSqr().redISub(this.x.redAdd(this.x)),y=l.redMul(this.x.redSub(m)).redISub(this.y);return this.curve.point(m,y)},Point$2.prototype.getX=function(){return this.x.fromRed()},Point$2.prototype.getY=function(){return this.y.fromRed()},Point$2.prototype.mul=function(e){return e=new BN$8(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},Point$2.prototype.mulAdd=function(e,n,o){var u=[this,n],l=[e,o];return this.curve.endo?this.curve._endoWnafMulAdd(u,l):this.curve._wnafMulAdd(1,u,l,2)},Point$2.prototype.jmulAdd=function(e,n,o){var u=[this,n],l=[e,o];return this.curve.endo?this.curve._endoWnafMulAdd(u,l,!0):this.curve._wnafMulAdd(1,u,l,2,!0)},Point$2.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||this.x.cmp(e.x)===0&&this.y.cmp(e.y)===0)},Point$2.prototype.neg=function(e){if(this.inf)return this;var n=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var o=this.precomputed,u=function(l){return l.neg()};n.precomputed={naf:o.naf&&{wnd:o.naf.wnd,points:o.naf.points.map(u)},doubles:o.doubles&&{step:o.doubles.step,points:o.doubles.points.map(u)}}}return n},Point$2.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var e=this.curve.jpoint(this.x,this.y,this.curve.one);return e};function JPoint(t,e,n,o){Base$2.BasePoint.call(this,t,"jacobian"),e===null&&n===null&&o===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new BN$8(0)):(this.x=new BN$8(e,16),this.y=new BN$8(n,16),this.z=new BN$8(o,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}inherits$4(JPoint,Base$2.BasePoint),ShortCurve.prototype.jpoint=function(e,n,o){return new JPoint(this,e,n,o)},JPoint.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),n=e.redSqr(),o=this.x.redMul(n),u=this.y.redMul(n).redMul(e);return this.curve.point(o,u)},JPoint.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},JPoint.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var n=e.z.redSqr(),o=this.z.redSqr(),u=this.x.redMul(n),l=e.x.redMul(o),m=this.y.redMul(n.redMul(e.z)),y=e.y.redMul(o.redMul(this.z)),E=u.redSub(l),C=m.redSub(y);if(E.cmpn(0)===0)return C.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var k=E.redSqr(),A=k.redMul(E),D=u.redMul(k),P=C.redSqr().redIAdd(A).redISub(D).redISub(D),R=C.redMul(D.redISub(P)).redISub(m.redMul(A)),B=this.z.redMul(e.z).redMul(E);return this.curve.jpoint(P,R,B)},JPoint.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var n=this.z.redSqr(),o=this.x,u=e.x.redMul(n),l=this.y,m=e.y.redMul(n).redMul(this.z),y=o.redSub(u),E=l.redSub(m);if(y.cmpn(0)===0)return E.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var C=y.redSqr(),k=C.redMul(y),A=o.redMul(C),D=E.redSqr().redIAdd(k).redISub(A).redISub(A),P=E.redMul(A.redISub(D)).redISub(l.redMul(k)),R=this.z.redMul(y);return this.curve.jpoint(D,P,R)},JPoint.prototype.dblp=function(e){if(e===0)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var n;if(this.curve.zeroA||this.curve.threeA){var o=this;for(n=0;n<e;n++)o=o.dbl();return o}var u=this.curve.a,l=this.curve.tinv,m=this.x,y=this.y,E=this.z,C=E.redSqr().redSqr(),k=y.redAdd(y);for(n=0;n<e;n++){var A=m.redSqr(),D=k.redSqr(),P=D.redSqr(),R=A.redAdd(A).redIAdd(A).redIAdd(u.redMul(C)),B=m.redMul(D),F=R.redSqr().redISub(B.redAdd(B)),j=B.redISub(F),N=R.redMul(j);N=N.redIAdd(N).redISub(P);var Y=k.redMul(E);n+1<e&&(C=C.redMul(P)),m=F,E=Y,k=N}return this.curve.jpoint(m,k.redMul(l),E)},JPoint.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},JPoint.prototype._zeroDbl=function(){var e,n,o;if(this.zOne){var u=this.x.redSqr(),l=this.y.redSqr(),m=l.redSqr(),y=this.x.redAdd(l).redSqr().redISub(u).redISub(m);y=y.redIAdd(y);var E=u.redAdd(u).redIAdd(u),C=E.redSqr().redISub(y).redISub(y),k=m.redIAdd(m);k=k.redIAdd(k),k=k.redIAdd(k),e=C,n=E.redMul(y.redISub(C)).redISub(k),o=this.y.redAdd(this.y)}else{var A=this.x.redSqr(),D=this.y.redSqr(),P=D.redSqr(),R=this.x.redAdd(D).redSqr().redISub(A).redISub(P);R=R.redIAdd(R);var B=A.redAdd(A).redIAdd(A),F=B.redSqr(),j=P.redIAdd(P);j=j.redIAdd(j),j=j.redIAdd(j),e=F.redISub(R).redISub(R),n=B.redMul(R.redISub(e)).redISub(j),o=this.y.redMul(this.z),o=o.redIAdd(o)}return this.curve.jpoint(e,n,o)},JPoint.prototype._threeDbl=function(){var e,n,o;if(this.zOne){var u=this.x.redSqr(),l=this.y.redSqr(),m=l.redSqr(),y=this.x.redAdd(l).redSqr().redISub(u).redISub(m);y=y.redIAdd(y);var E=u.redAdd(u).redIAdd(u).redIAdd(this.curve.a),C=E.redSqr().redISub(y).redISub(y);e=C;var k=m.redIAdd(m);k=k.redIAdd(k),k=k.redIAdd(k),n=E.redMul(y.redISub(C)).redISub(k),o=this.y.redAdd(this.y)}else{var A=this.z.redSqr(),D=this.y.redSqr(),P=this.x.redMul(D),R=this.x.redSub(A).redMul(this.x.redAdd(A));R=R.redAdd(R).redIAdd(R);var B=P.redIAdd(P);B=B.redIAdd(B);var F=B.redAdd(B);e=R.redSqr().redISub(F),o=this.y.redAdd(this.z).redSqr().redISub(D).redISub(A);var j=D.redSqr();j=j.redIAdd(j),j=j.redIAdd(j),j=j.redIAdd(j),n=R.redMul(B.redISub(e)).redISub(j)}return this.curve.jpoint(e,n,o)},JPoint.prototype._dbl=function(){var e=this.curve.a,n=this.x,o=this.y,u=this.z,l=u.redSqr().redSqr(),m=n.redSqr(),y=o.redSqr(),E=m.redAdd(m).redIAdd(m).redIAdd(e.redMul(l)),C=n.redAdd(n);C=C.redIAdd(C);var k=C.redMul(y),A=E.redSqr().redISub(k.redAdd(k)),D=k.redISub(A),P=y.redSqr();P=P.redIAdd(P),P=P.redIAdd(P),P=P.redIAdd(P);var R=E.redMul(D).redISub(P),B=o.redAdd(o).redMul(u);return this.curve.jpoint(A,R,B)},JPoint.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),n=this.y.redSqr(),o=this.z.redSqr(),u=n.redSqr(),l=e.redAdd(e).redIAdd(e),m=l.redSqr(),y=this.x.redAdd(n).redSqr().redISub(e).redISub(u);y=y.redIAdd(y),y=y.redAdd(y).redIAdd(y),y=y.redISub(m);var E=y.redSqr(),C=u.redIAdd(u);C=C.redIAdd(C),C=C.redIAdd(C),C=C.redIAdd(C);var k=l.redIAdd(y).redSqr().redISub(m).redISub(E).redISub(C),A=n.redMul(k);A=A.redIAdd(A),A=A.redIAdd(A);var D=this.x.redMul(E).redISub(A);D=D.redIAdd(D),D=D.redIAdd(D);var P=this.y.redMul(k.redMul(C.redISub(k)).redISub(y.redMul(E)));P=P.redIAdd(P),P=P.redIAdd(P),P=P.redIAdd(P);var R=this.z.redAdd(y).redSqr().redISub(o).redISub(E);return this.curve.jpoint(D,P,R)},JPoint.prototype.mul=function(e,n){return e=new BN$8(e,n),this.curve._wnafMul(this,e)},JPoint.prototype.eq=function(e){if(e.type==="affine")return this.eq(e.toJ());if(this===e)return!0;var n=this.z.redSqr(),o=e.z.redSqr();if(this.x.redMul(o).redISub(e.x.redMul(n)).cmpn(0)!==0)return!1;var u=n.redMul(this.z),l=o.redMul(e.z);return this.y.redMul(l).redISub(e.y.redMul(u)).cmpn(0)===0},JPoint.prototype.eqXToP=function(e){var n=this.z.redSqr(),o=e.toRed(this.curve.red).redMul(n);if(this.x.cmp(o)===0)return!0;for(var u=e.clone(),l=this.curve.redN.redMul(n);;){if(u.iadd(this.curve.n),u.cmp(this.curve.p)>=0)return!1;if(o.redIAdd(l),this.x.cmp(o)===0)return!0}},JPoint.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},JPoint.prototype.isInfinity=function(){return this.z.cmpn(0)===0};var BN$7=bnExports$3,inherits$3=inherits_browserExports,Base$1=base$1,utils$k=utils$o;function MontCurve(t){Base$1.call(this,"mont",t),this.a=new BN$7(t.a,16).toRed(this.red),this.b=new BN$7(t.b,16).toRed(this.red),this.i4=new BN$7(4).toRed(this.red).redInvm(),this.two=new BN$7(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}inherits$3(MontCurve,Base$1);var mont=MontCurve;MontCurve.prototype.validate=function(e){var n=e.normalize().x,o=n.redSqr(),u=o.redMul(n).redAdd(o.redMul(this.a)).redAdd(n),l=u.redSqrt();return l.redSqr().cmp(u)===0};function Point$1(t,e,n){Base$1.BasePoint.call(this,t,"projective"),e===null&&n===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new BN$7(e,16),this.z=new BN$7(n,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}inherits$3(Point$1,Base$1.BasePoint),MontCurve.prototype.decodePoint=function(e,n){return this.point(utils$k.toArray(e,n),1)},MontCurve.prototype.point=function(e,n){return new Point$1(this,e,n)},MontCurve.prototype.pointFromJSON=function(e){return Point$1.fromJSON(this,e)},Point$1.prototype.precompute=function(){},Point$1.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},Point$1.fromJSON=function(e,n){return new Point$1(e,n[0],n[1]||e.one)},Point$1.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},Point$1.prototype.isInfinity=function(){return this.z.cmpn(0)===0},Point$1.prototype.dbl=function(){var e=this.x.redAdd(this.z),n=e.redSqr(),o=this.x.redSub(this.z),u=o.redSqr(),l=n.redSub(u),m=n.redMul(u),y=l.redMul(u.redAdd(this.curve.a24.redMul(l)));return this.curve.point(m,y)},Point$1.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},Point$1.prototype.diffAdd=function(e,n){var o=this.x.redAdd(this.z),u=this.x.redSub(this.z),l=e.x.redAdd(e.z),m=e.x.redSub(e.z),y=m.redMul(o),E=l.redMul(u),C=n.z.redMul(y.redAdd(E).redSqr()),k=n.x.redMul(y.redISub(E).redSqr());return this.curve.point(C,k)},Point$1.prototype.mul=function(e){for(var n=e.clone(),o=this,u=this.curve.point(null,null),l=this,m=[];n.cmpn(0)!==0;n.iushrn(1))m.push(n.andln(1));for(var y=m.length-1;y>=0;y--)m[y]===0?(o=o.diffAdd(u,l),u=u.dbl()):(u=o.diffAdd(u,l),o=o.dbl());return u},Point$1.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},Point$1.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},Point$1.prototype.eq=function(e){return this.getX().cmp(e.getX())===0},Point$1.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},Point$1.prototype.getX=function(){return this.normalize(),this.x.fromRed()};var utils$j=utils$o,BN$6=bnExports$3,inherits$2=inherits_browserExports,Base=base$1,assert$c=utils$j.assert;function EdwardsCurve(t){this.twisted=(t.a|0)!==1,this.mOneA=this.twisted&&(t.a|0)===-1,this.extended=this.mOneA,Base.call(this,"edwards",t),this.a=new BN$6(t.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new BN$6(t.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new BN$6(t.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),assert$c(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(t.c|0)===1}inherits$2(EdwardsCurve,Base);var edwards=EdwardsCurve;EdwardsCurve.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},EdwardsCurve.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},EdwardsCurve.prototype.jpoint=function(e,n,o,u){return this.point(e,n,o,u)},EdwardsCurve.prototype.pointFromX=function(e,n){e=new BN$6(e,16),e.red||(e=e.toRed(this.red));var o=e.redSqr(),u=this.c2.redSub(this.a.redMul(o)),l=this.one.redSub(this.c2.redMul(this.d).redMul(o)),m=u.redMul(l.redInvm()),y=m.redSqrt();if(y.redSqr().redSub(m).cmp(this.zero)!==0)throw new Error("invalid point");var E=y.fromRed().isOdd();return(n&&!E||!n&&E)&&(y=y.redNeg()),this.point(e,y)},EdwardsCurve.prototype.pointFromY=function(e,n){e=new BN$6(e,16),e.red||(e=e.toRed(this.red));var o=e.redSqr(),u=o.redSub(this.c2),l=o.redMul(this.d).redMul(this.c2).redSub(this.a),m=u.redMul(l.redInvm());if(m.cmp(this.zero)===0){if(n)throw new Error("invalid point");return this.point(this.zero,e)}var y=m.redSqrt();if(y.redSqr().redSub(m).cmp(this.zero)!==0)throw new Error("invalid point");return y.fromRed().isOdd()!==n&&(y=y.redNeg()),this.point(y,e)},EdwardsCurve.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var n=e.x.redSqr(),o=e.y.redSqr(),u=n.redMul(this.a).redAdd(o),l=this.c2.redMul(this.one.redAdd(this.d.redMul(n).redMul(o)));return u.cmp(l)===0};function Point(t,e,n,o,u){Base.BasePoint.call(this,t,"projective"),e===null&&n===null&&o===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new BN$6(e,16),this.y=new BN$6(n,16),this.z=o?new BN$6(o,16):this.curve.one,this.t=u&&new BN$6(u,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}inherits$2(Point,Base.BasePoint),EdwardsCurve.prototype.pointFromJSON=function(e){return Point.fromJSON(this,e)},EdwardsCurve.prototype.point=function(e,n,o,u){return new Point(this,e,n,o,u)},Point.fromJSON=function(e,n){return new Point(e,n[0],n[1],n[2])},Point.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},Point.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)},Point.prototype._extDbl=function(){var e=this.x.redSqr(),n=this.y.redSqr(),o=this.z.redSqr();o=o.redIAdd(o);var u=this.curve._mulA(e),l=this.x.redAdd(this.y).redSqr().redISub(e).redISub(n),m=u.redAdd(n),y=m.redSub(o),E=u.redSub(n),C=l.redMul(y),k=m.redMul(E),A=l.redMul(E),D=y.redMul(m);return this.curve.point(C,k,D,A)},Point.prototype._projDbl=function(){var e=this.x.redAdd(this.y).redSqr(),n=this.x.redSqr(),o=this.y.redSqr(),u,l,m,y,E,C;if(this.curve.twisted){y=this.curve._mulA(n);var k=y.redAdd(o);this.zOne?(u=e.redSub(n).redSub(o).redMul(k.redSub(this.curve.two)),l=k.redMul(y.redSub(o)),m=k.redSqr().redSub(k).redSub(k)):(E=this.z.redSqr(),C=k.redSub(E).redISub(E),u=e.redSub(n).redISub(o).redMul(C),l=k.redMul(y.redSub(o)),m=k.redMul(C))}else y=n.redAdd(o),E=this.curve._mulC(this.z).redSqr(),C=y.redSub(E).redSub(E),u=this.curve._mulC(e.redISub(y)).redMul(C),l=this.curve._mulC(y).redMul(n.redISub(o)),m=y.redMul(C);return this.curve.point(u,l,m)},Point.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},Point.prototype._extAdd=function(e){var n=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),o=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),u=this.t.redMul(this.curve.dd).redMul(e.t),l=this.z.redMul(e.z.redAdd(e.z)),m=o.redSub(n),y=l.redSub(u),E=l.redAdd(u),C=o.redAdd(n),k=m.redMul(y),A=E.redMul(C),D=m.redMul(C),P=y.redMul(E);return this.curve.point(k,A,P,D)},Point.prototype._projAdd=function(e){var n=this.z.redMul(e.z),o=n.redSqr(),u=this.x.redMul(e.x),l=this.y.redMul(e.y),m=this.curve.d.redMul(u).redMul(l),y=o.redSub(m),E=o.redAdd(m),C=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(u).redISub(l),k=n.redMul(y).redMul(C),A,D;return this.curve.twisted?(A=n.redMul(E).redMul(l.redSub(this.curve._mulA(u))),D=y.redMul(E)):(A=n.redMul(E).redMul(l.redSub(u)),D=this.curve._mulC(y).redMul(E)),this.curve.point(k,A,D)},Point.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},Point.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},Point.prototype.mulAdd=function(e,n,o){return this.curve._wnafMulAdd(1,[this,n],[e,o],2,!1)},Point.prototype.jmulAdd=function(e,n,o){return this.curve._wnafMulAdd(1,[this,n],[e,o],2,!0)},Point.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},Point.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},Point.prototype.getX=function(){return this.normalize(),this.x.fromRed()},Point.prototype.getY=function(){return this.normalize(),this.y.fromRed()},Point.prototype.eq=function(e){return this===e||this.getX().cmp(e.getX())===0&&this.getY().cmp(e.getY())===0},Point.prototype.eqXToP=function(e){var n=e.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(n)===0)return!0;for(var o=e.clone(),u=this.curve.redN.redMul(this.z);;){if(o.iadd(this.curve.n),o.cmp(this.curve.p)>=0)return!1;if(n.redIAdd(u),this.x.cmp(n)===0)return!0}},Point.prototype.toP=Point.prototype.normalize,Point.prototype.mixedAdd=Point.prototype.add,function(t){var e=t;e.base=base$1,e.short=short,e.mont=mont,e.edwards=edwards}(curve);var curves$1={},hash$2={},utils$i={},assert$b=minimalisticAssert,inherits$1=inherits_browserExports;utils$i.inherits=inherits$1;function isSurrogatePair(t,e){return(t.charCodeAt(e)&64512)!==55296||e<0||e+1>=t.length?!1:(t.charCodeAt(e+1)&64512)===56320}function toArray(t,e){if(Array.isArray(t))return t.slice();if(!t)return[];var n=[];if(typeof t=="string")if(e){if(e==="hex")for(t=t.replace(/[^a-z0-9]+/ig,""),t.length%2!==0&&(t="0"+t),u=0;u<t.length;u+=2)n.push(parseInt(t[u]+t[u+1],16))}else for(var o=0,u=0;u<t.length;u++){var l=t.charCodeAt(u);l<128?n[o++]=l:l<2048?(n[o++]=l>>6|192,n[o++]=l&63|128):isSurrogatePair(t,u)?(l=65536+((l&1023)<<10)+(t.charCodeAt(++u)&1023),n[o++]=l>>18|240,n[o++]=l>>12&63|128,n[o++]=l>>6&63|128,n[o++]=l&63|128):(n[o++]=l>>12|224,n[o++]=l>>6&63|128,n[o++]=l&63|128)}else for(u=0;u<t.length;u++)n[u]=t[u]|0;return n}utils$i.toArray=toArray;function toHex(t){for(var e="",n=0;n<t.length;n++)e+=zero2(t[n].toString(16));return e}utils$i.toHex=toHex;function htonl(t){var e=t>>>24|t>>>8&65280|t<<8&16711680|(t&255)<<24;return e>>>0}utils$i.htonl=htonl;function toHex32(t,e){for(var n="",o=0;o<t.length;o++){var u=t[o];e==="little"&&(u=htonl(u)),n+=zero8(u.toString(16))}return n}utils$i.toHex32=toHex32;function zero2(t){return t.length===1?"0"+t:t}utils$i.zero2=zero2;function zero8(t){return t.length===7?"0"+t:t.length===6?"00"+t:t.length===5?"000"+t:t.length===4?"0000"+t:t.length===3?"00000"+t:t.length===2?"000000"+t:t.length===1?"0000000"+t:t}utils$i.zero8=zero8;function join32(t,e,n,o){var u=n-e;assert$b(u%4===0);for(var l=new Array(u/4),m=0,y=e;m<l.length;m++,y+=4){var E;o==="big"?E=t[y]<<24|t[y+1]<<16|t[y+2]<<8|t[y+3]:E=t[y+3]<<24|t[y+2]<<16|t[y+1]<<8|t[y],l[m]=E>>>0}return l}utils$i.join32=join32;function split32(t,e){for(var n=new Array(t.length*4),o=0,u=0;o<t.length;o++,u+=4){var l=t[o];e==="big"?(n[u]=l>>>24,n[u+1]=l>>>16&255,n[u+2]=l>>>8&255,n[u+3]=l&255):(n[u+3]=l>>>24,n[u+2]=l>>>16&255,n[u+1]=l>>>8&255,n[u]=l&255)}return n}utils$i.split32=split32;function rotr32$1(t,e){return t>>>e|t<<32-e}utils$i.rotr32=rotr32$1;function rotl32$2(t,e){return t<<e|t>>>32-e}utils$i.rotl32=rotl32$2;function sum32$3(t,e){return t+e>>>0}utils$i.sum32=sum32$3;function sum32_3$1(t,e,n){return t+e+n>>>0}utils$i.sum32_3=sum32_3$1;function sum32_4$2(t,e,n,o){return t+e+n+o>>>0}utils$i.sum32_4=sum32_4$2;function sum32_5$2(t,e,n,o,u){return t+e+n+o+u>>>0}utils$i.sum32_5=sum32_5$2;function sum64$1(t,e,n,o){var u=t[e],l=t[e+1],m=o+l>>>0,y=(m<o?1:0)+n+u;t[e]=y>>>0,t[e+1]=m}utils$i.sum64=sum64$1;function sum64_hi$1(t,e,n,o){var u=e+o>>>0,l=(u<e?1:0)+t+n;return l>>>0}utils$i.sum64_hi=sum64_hi$1;function sum64_lo$1(t,e,n,o){var u=e+o;return u>>>0}utils$i.sum64_lo=sum64_lo$1;function sum64_4_hi$1(t,e,n,o,u,l,m,y){var E=0,C=e;C=C+o>>>0,E+=C<e?1:0,C=C+l>>>0,E+=C<l?1:0,C=C+y>>>0,E+=C<y?1:0;var k=t+n+u+m+E;return k>>>0}utils$i.sum64_4_hi=sum64_4_hi$1;function sum64_4_lo$1(t,e,n,o,u,l,m,y){var E=e+o+l+y;return E>>>0}utils$i.sum64_4_lo=sum64_4_lo$1;function sum64_5_hi$1(t,e,n,o,u,l,m,y,E,C){var k=0,A=e;A=A+o>>>0,k+=A<e?1:0,A=A+l>>>0,k+=A<l?1:0,A=A+y>>>0,k+=A<y?1:0,A=A+C>>>0,k+=A<C?1:0;var D=t+n+u+m+E+k;return D>>>0}utils$i.sum64_5_hi=sum64_5_hi$1;function sum64_5_lo$1(t,e,n,o,u,l,m,y,E,C){var k=e+o+l+y+C;return k>>>0}utils$i.sum64_5_lo=sum64_5_lo$1;function rotr64_hi$1(t,e,n){var o=e<<32-n|t>>>n;return o>>>0}utils$i.rotr64_hi=rotr64_hi$1;function rotr64_lo$1(t,e,n){var o=t<<32-n|e>>>n;return o>>>0}utils$i.rotr64_lo=rotr64_lo$1;function shr64_hi$1(t,e,n){return t>>>n}utils$i.shr64_hi=shr64_hi$1;function shr64_lo$1(t,e,n){var o=t<<32-n|e>>>n;return o>>>0}utils$i.shr64_lo=shr64_lo$1;var common$6={},utils$h=utils$i,assert$a=minimalisticAssert;function BlockHash$4(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}common$6.BlockHash=BlockHash$4,BlockHash$4.prototype.update=function(e,n){if(e=utils$h.toArray(e,n),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){e=this.pending;var o=e.length%this._delta8;this.pending=e.slice(e.length-o,e.length),this.pending.length===0&&(this.pending=null),e=utils$h.join32(e,0,e.length-o,this.endian);for(var u=0;u<e.length;u+=this._delta32)this._update(e,u,u+this._delta32)}return this},BlockHash$4.prototype.digest=function(e){return this.update(this._pad()),assert$a(this.pending===null),this._digest(e)},BlockHash$4.prototype._pad=function(){var e=this.pendingTotal,n=this._delta8,o=n-(e+this.padLength)%n,u=new Array(o+this.padLength);u[0]=128;for(var l=1;l<o;l++)u[l]=0;if(e<<=3,this.endian==="big"){for(var m=8;m<this.padLength;m++)u[l++]=0;u[l++]=0,u[l++]=0,u[l++]=0,u[l++]=0,u[l++]=e>>>24&255,u[l++]=e>>>16&255,u[l++]=e>>>8&255,u[l++]=e&255}else for(u[l++]=e&255,u[l++]=e>>>8&255,u[l++]=e>>>16&255,u[l++]=e>>>24&255,u[l++]=0,u[l++]=0,u[l++]=0,u[l++]=0,m=8;m<this.padLength;m++)u[l++]=0;return u};var sha={},common$5={},utils$g=utils$i,rotr32=utils$g.rotr32;function ft_1$1(t,e,n,o){if(t===0)return ch32$1(e,n,o);if(t===1||t===3)return p32(e,n,o);if(t===2)return maj32$1(e,n,o)}common$5.ft_1=ft_1$1;function ch32$1(t,e,n){return t&e^~t&n}common$5.ch32=ch32$1;function maj32$1(t,e,n){return t&e^t&n^e&n}common$5.maj32=maj32$1;function p32(t,e,n){return t^e^n}common$5.p32=p32;function s0_256$1(t){return rotr32(t,2)^rotr32(t,13)^rotr32(t,22)}common$5.s0_256=s0_256$1;function s1_256$1(t){return rotr32(t,6)^rotr32(t,11)^rotr32(t,25)}common$5.s1_256=s1_256$1;function g0_256$1(t){return rotr32(t,7)^rotr32(t,18)^t>>>3}common$5.g0_256=g0_256$1;function g1_256$1(t){return rotr32(t,17)^rotr32(t,19)^t>>>10}common$5.g1_256=g1_256$1;var utils$f=utils$i,common$4=common$6,shaCommon$1=common$5,rotl32$1=utils$f.rotl32,sum32$2=utils$f.sum32,sum32_5$1=utils$f.sum32_5,ft_1=shaCommon$1.ft_1,BlockHash$3=common$4.BlockHash,sha1_K=[1518500249,1859775393,2400959708,3395469782];function SHA1(){if(!(this instanceof SHA1))return new SHA1;BlockHash$3.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}utils$f.inherits(SHA1,BlockHash$3);var _1=SHA1;SHA1.blockSize=512,SHA1.outSize=160,SHA1.hmacStrength=80,SHA1.padLength=64,SHA1.prototype._update=function(e,n){for(var o=this.W,u=0;u<16;u++)o[u]=e[n+u];for(;u<o.length;u++)o[u]=rotl32$1(o[u-3]^o[u-8]^o[u-14]^o[u-16],1);var l=this.h[0],m=this.h[1],y=this.h[2],E=this.h[3],C=this.h[4];for(u=0;u<o.length;u++){var k=~~(u/20),A=sum32_5$1(rotl32$1(l,5),ft_1(k,m,y,E),C,o[u],sha1_K[k]);C=E,E=y,y=rotl32$1(m,30),m=l,l=A}this.h[0]=sum32$2(this.h[0],l),this.h[1]=sum32$2(this.h[1],m),this.h[2]=sum32$2(this.h[2],y),this.h[3]=sum32$2(this.h[3],E),this.h[4]=sum32$2(this.h[4],C)},SHA1.prototype._digest=function(e){return e==="hex"?utils$f.toHex32(this.h,"big"):utils$f.split32(this.h,"big")};var utils$e=utils$i,common$3=common$6,shaCommon=common$5,assert$9=minimalisticAssert,sum32$1=utils$e.sum32,sum32_4$1=utils$e.sum32_4,sum32_5=utils$e.sum32_5,ch32=shaCommon.ch32,maj32=shaCommon.maj32,s0_256=shaCommon.s0_256,s1_256=shaCommon.s1_256,g0_256=shaCommon.g0_256,g1_256=shaCommon.g1_256,BlockHash$2=common$3.BlockHash,sha256_K=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function SHA256$1(){if(!(this instanceof SHA256$1))return new SHA256$1;BlockHash$2.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=sha256_K,this.W=new Array(64)}utils$e.inherits(SHA256$1,BlockHash$2);var _256=SHA256$1;SHA256$1.blockSize=512,SHA256$1.outSize=256,SHA256$1.hmacStrength=192,SHA256$1.padLength=64,SHA256$1.prototype._update=function(e,n){for(var o=this.W,u=0;u<16;u++)o[u]=e[n+u];for(;u<o.length;u++)o[u]=sum32_4$1(g1_256(o[u-2]),o[u-7],g0_256(o[u-15]),o[u-16]);var l=this.h[0],m=this.h[1],y=this.h[2],E=this.h[3],C=this.h[4],k=this.h[5],A=this.h[6],D=this.h[7];for(assert$9(this.k.length===o.length),u=0;u<o.length;u++){var P=sum32_5(D,s1_256(C),ch32(C,k,A),this.k[u],o[u]),R=sum32$1(s0_256(l),maj32(l,m,y));D=A,A=k,k=C,C=sum32$1(E,P),E=y,y=m,m=l,l=sum32$1(P,R)}this.h[0]=sum32$1(this.h[0],l),this.h[1]=sum32$1(this.h[1],m),this.h[2]=sum32$1(this.h[2],y),this.h[3]=sum32$1(this.h[3],E),this.h[4]=sum32$1(this.h[4],C),this.h[5]=sum32$1(this.h[5],k),this.h[6]=sum32$1(this.h[6],A),this.h[7]=sum32$1(this.h[7],D)},SHA256$1.prototype._digest=function(e){return e==="hex"?utils$e.toHex32(this.h,"big"):utils$e.split32(this.h,"big")};var utils$d=utils$i,SHA256=_256;function SHA224(){if(!(this instanceof SHA224))return new SHA224;SHA256.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}utils$d.inherits(SHA224,SHA256);var _224=SHA224;SHA224.blockSize=512,SHA224.outSize=224,SHA224.hmacStrength=192,SHA224.padLength=64,SHA224.prototype._digest=function(e){return e==="hex"?utils$d.toHex32(this.h.slice(0,7),"big"):utils$d.split32(this.h.slice(0,7),"big")};var utils$c=utils$i,common$2=common$6,assert$8=minimalisticAssert,rotr64_hi=utils$c.rotr64_hi,rotr64_lo=utils$c.rotr64_lo,shr64_hi=utils$c.shr64_hi,shr64_lo=utils$c.shr64_lo,sum64=utils$c.sum64,sum64_hi=utils$c.sum64_hi,sum64_lo=utils$c.sum64_lo,sum64_4_hi=utils$c.sum64_4_hi,sum64_4_lo=utils$c.sum64_4_lo,sum64_5_hi=utils$c.sum64_5_hi,sum64_5_lo=utils$c.sum64_5_lo,BlockHash$1=common$2.BlockHash,sha512_K=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function SHA512$1(){if(!(this instanceof SHA512$1))return new SHA512$1;BlockHash$1.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=sha512_K,this.W=new Array(160)}utils$c.inherits(SHA512$1,BlockHash$1);var _512=SHA512$1;SHA512$1.blockSize=1024,SHA512$1.outSize=512,SHA512$1.hmacStrength=192,SHA512$1.padLength=128,SHA512$1.prototype._prepareBlock=function(e,n){for(var o=this.W,u=0;u<32;u++)o[u]=e[n+u];for(;u<o.length;u+=2){var l=g1_512_hi(o[u-4],o[u-3]),m=g1_512_lo(o[u-4],o[u-3]),y=o[u-14],E=o[u-13],C=g0_512_hi(o[u-30],o[u-29]),k=g0_512_lo(o[u-30],o[u-29]),A=o[u-32],D=o[u-31];o[u]=sum64_4_hi(l,m,y,E,C,k,A,D),o[u+1]=sum64_4_lo(l,m,y,E,C,k,A,D)}},SHA512$1.prototype._update=function(e,n){this._prepareBlock(e,n);var o=this.W,u=this.h[0],l=this.h[1],m=this.h[2],y=this.h[3],E=this.h[4],C=this.h[5],k=this.h[6],A=this.h[7],D=this.h[8],P=this.h[9],R=this.h[10],B=this.h[11],F=this.h[12],j=this.h[13],N=this.h[14],Y=this.h[15];assert$8(this.k.length===o.length);for(var J=0;J<o.length;J+=2){var ie=N,ue=Y,Q=s1_512_hi(D,P),ce=s1_512_lo(D,P),he=ch64_hi(D,P,R,B,F),ke=ch64_lo(D,P,R,B,F,j),L=this.k[J],d=this.k[J+1],v=o[J],w=o[J+1],c=sum64_5_hi(ie,ue,Q,ce,he,ke,L,d,v,w),p=sum64_5_lo(ie,ue,Q,ce,he,ke,L,d,v,w);ie=s0_512_hi(u,l),ue=s0_512_lo(u,l),Q=maj64_hi(u,l,m,y,E),ce=maj64_lo(u,l,m,y,E,C);var x=sum64_hi(ie,ue,Q,ce),S=sum64_lo(ie,ue,Q,ce);N=F,Y=j,F=R,j=B,R=D,B=P,D=sum64_hi(k,A,c,p),P=sum64_lo(A,A,c,p),k=E,A=C,E=m,C=y,m=u,y=l,u=sum64_hi(c,p,x,S),l=sum64_lo(c,p,x,S)}sum64(this.h,0,u,l),sum64(this.h,2,m,y),sum64(this.h,4,E,C),sum64(this.h,6,k,A),sum64(this.h,8,D,P),sum64(this.h,10,R,B),sum64(this.h,12,F,j),sum64(this.h,14,N,Y)},SHA512$1.prototype._digest=function(e){return e==="hex"?utils$c.toHex32(this.h,"big"):utils$c.split32(this.h,"big")};function ch64_hi(t,e,n,o,u){var l=t&n^~t&u;return l<0&&(l+=4294967296),l}function ch64_lo(t,e,n,o,u,l){var m=e&o^~e&l;return m<0&&(m+=4294967296),m}function maj64_hi(t,e,n,o,u){var l=t&n^t&u^n&u;return l<0&&(l+=4294967296),l}function maj64_lo(t,e,n,o,u,l){var m=e&o^e&l^o&l;return m<0&&(m+=4294967296),m}function s0_512_hi(t,e){var n=rotr64_hi(t,e,28),o=rotr64_hi(e,t,2),u=rotr64_hi(e,t,7),l=n^o^u;return l<0&&(l+=4294967296),l}function s0_512_lo(t,e){var n=rotr64_lo(t,e,28),o=rotr64_lo(e,t,2),u=rotr64_lo(e,t,7),l=n^o^u;return l<0&&(l+=4294967296),l}function s1_512_hi(t,e){var n=rotr64_hi(t,e,14),o=rotr64_hi(t,e,18),u=rotr64_hi(e,t,9),l=n^o^u;return l<0&&(l+=4294967296),l}function s1_512_lo(t,e){var n=rotr64_lo(t,e,14),o=rotr64_lo(t,e,18),u=rotr64_lo(e,t,9),l=n^o^u;return l<0&&(l+=4294967296),l}function g0_512_hi(t,e){var n=rotr64_hi(t,e,1),o=rotr64_hi(t,e,8),u=shr64_hi(t,e,7),l=n^o^u;return l<0&&(l+=4294967296),l}function g0_512_lo(t,e){var n=rotr64_lo(t,e,1),o=rotr64_lo(t,e,8),u=shr64_lo(t,e,7),l=n^o^u;return l<0&&(l+=4294967296),l}function g1_512_hi(t,e){var n=rotr64_hi(t,e,19),o=rotr64_hi(e,t,29),u=shr64_hi(t,e,6),l=n^o^u;return l<0&&(l+=4294967296),l}function g1_512_lo(t,e){var n=rotr64_lo(t,e,19),o=rotr64_lo(e,t,29),u=shr64_lo(t,e,6),l=n^o^u;return l<0&&(l+=4294967296),l}var utils$b=utils$i,SHA512=_512;function SHA384(){if(!(this instanceof SHA384))return new SHA384;SHA512.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}utils$b.inherits(SHA384,SHA512);var _384=SHA384;SHA384.blockSize=1024,SHA384.outSize=384,SHA384.hmacStrength=192,SHA384.padLength=128,SHA384.prototype._digest=function(e){return e==="hex"?utils$b.toHex32(this.h.slice(0,12),"big"):utils$b.split32(this.h.slice(0,12),"big")},sha.sha1=_1,sha.sha224=_224,sha.sha256=_256,sha.sha384=_384,sha.sha512=_512;var ripemd={},utils$a=utils$i,common$1=common$6,rotl32=utils$a.rotl32,sum32=utils$a.sum32,sum32_3=utils$a.sum32_3,sum32_4=utils$a.sum32_4,BlockHash=common$1.BlockHash;function RIPEMD160(){if(!(this instanceof RIPEMD160))return new RIPEMD160;BlockHash.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}utils$a.inherits(RIPEMD160,BlockHash),ripemd.ripemd160=RIPEMD160,RIPEMD160.blockSize=512,RIPEMD160.outSize=160,RIPEMD160.hmacStrength=192,RIPEMD160.padLength=64,RIPEMD160.prototype._update=function(e,n){for(var o=this.h[0],u=this.h[1],l=this.h[2],m=this.h[3],y=this.h[4],E=o,C=u,k=l,A=m,D=y,P=0;P<80;P++){var R=sum32(rotl32(sum32_4(o,f(P,u,l,m),e[r[P]+n],K(P)),s[P]),y);o=y,y=m,m=rotl32(l,10),l=u,u=R,R=sum32(rotl32(sum32_4(E,f(79-P,C,k,A),e[rh[P]+n],Kh(P)),sh[P]),D),E=D,D=A,A=rotl32(k,10),k=C,C=R}R=sum32_3(this.h[1],l,A),this.h[1]=sum32_3(this.h[2],m,D),this.h[2]=sum32_3(this.h[3],y,E),this.h[3]=sum32_3(this.h[4],o,C),this.h[4]=sum32_3(this.h[0],u,k),this.h[0]=R},RIPEMD160.prototype._digest=function(e){return e==="hex"?utils$a.toHex32(this.h,"little"):utils$a.split32(this.h,"little")};function f(t,e,n,o){return t<=15?e^n^o:t<=31?e&n|~e&o:t<=47?(e|~n)^o:t<=63?e&o|n&~o:e^(n|~o)}function K(t){return t<=15?0:t<=31?1518500249:t<=47?1859775393:t<=63?2400959708:2840853838}function Kh(t){return t<=15?1352829926:t<=31?1548603684:t<=47?1836072691:t<=63?2053994217:0}var r=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],rh=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],s=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],sh=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],utils$9=utils$i,assert$7=minimalisticAssert;function Hmac(t,e,n){if(!(this instanceof Hmac))return new Hmac(t,e,n);this.Hash=t,this.blockSize=t.blockSize/8,this.outSize=t.outSize/8,this.inner=null,this.outer=null,this._init(utils$9.toArray(e,n))}var hmac=Hmac;Hmac.prototype._init=function(e){e.length>this.blockSize&&(e=new this.Hash().update(e).digest()),assert$7(e.length<=this.blockSize);for(var n=e.length;n<this.blockSize;n++)e.push(0);for(n=0;n<e.length;n++)e[n]^=54;for(this.inner=new this.Hash().update(e),n=0;n<e.length;n++)e[n]^=106;this.outer=new this.Hash().update(e)},Hmac.prototype.update=function(e,n){return this.inner.update(e,n),this},Hmac.prototype.digest=function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)},function(t){var e=t;e.utils=utils$i,e.common=common$6,e.sha=sha,e.ripemd=ripemd,e.hmac=hmac,e.sha1=e.sha.sha1,e.sha256=e.sha.sha256,e.sha224=e.sha.sha224,e.sha384=e.sha.sha384,e.sha512=e.sha.sha512,e.ripemd160=e.ripemd.ripemd160}(hash$2);var secp256k1,hasRequiredSecp256k1;function requireSecp256k1(){return hasRequiredSecp256k1||(hasRequiredSecp256k1=1,secp256k1={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}),secp256k1}(function(t){var e=t,n=hash$2,o=curve,u=utils$o,l=u.assert;function m(C){C.type==="short"?this.curve=new o.short(C):C.type==="edwards"?this.curve=new o.edwards(C):this.curve=new o.mont(C),this.g=this.curve.g,this.n=this.curve.n,this.hash=C.hash,l(this.g.validate(),"Invalid curve"),l(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}e.PresetCurve=m;function y(C,k){Object.defineProperty(e,C,{configurable:!0,enumerable:!0,get:function(){var A=new m(k);return Object.defineProperty(e,C,{configurable:!0,enumerable:!0,value:A}),A}})}y("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:n.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),y("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:n.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),y("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:n.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),y("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:n.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),y("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:n.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),y("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:n.sha256,gRed:!1,g:["9"]}),y("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:n.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var E;try{E=requireSecp256k1()}catch{E=void 0}y("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:n.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",E]})})(curves$1);var hash$1=hash$2,utils$8=utils$n,assert$6=minimalisticAssert;function HmacDRBG(t){if(!(this instanceof HmacDRBG))return new HmacDRBG(t);this.hash=t.hash,this.predResist=!!t.predResist,this.outLen=this.hash.outSize,this.minEntropy=t.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var e=utils$8.toArray(t.entropy,t.entropyEnc||"hex"),n=utils$8.toArray(t.nonce,t.nonceEnc||"hex"),o=utils$8.toArray(t.pers,t.persEnc||"hex");assert$6(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(e,n,o)}var hmacDrbg=HmacDRBG;HmacDRBG.prototype._init=function(e,n,o){var u=e.concat(n).concat(o);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var l=0;l<this.V.length;l++)this.K[l]=0,this.V[l]=1;this._update(u),this._reseed=1,this.reseedInterval=281474976710656},HmacDRBG.prototype._hmac=function(){return new hash$1.hmac(this.hash,this.K)},HmacDRBG.prototype._update=function(e){var n=this._hmac().update(this.V).update([0]);e&&(n=n.update(e)),this.K=n.digest(),this.V=this._hmac().update(this.V).digest(),e&&(this.K=this._hmac().update(this.V).update([1]).update(e).digest(),this.V=this._hmac().update(this.V).digest())},HmacDRBG.prototype.reseed=function(e,n,o,u){typeof n!="string"&&(u=o,o=n,n=null),e=utils$8.toArray(e,n),o=utils$8.toArray(o,u),assert$6(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(o||[])),this._reseed=1},HmacDRBG.prototype.generate=function(e,n,o,u){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof n!="string"&&(u=o,o=n,n=null),o&&(o=utils$8.toArray(o,u||"hex"),this._update(o));for(var l=[];l.length<e;)this.V=this._hmac().update(this.V).digest(),l=l.concat(this.V);var m=l.slice(0,e);return this._update(o),this._reseed++,utils$8.encode(m,n)};var BN$5=bnExports$3,utils$7=utils$o,assert$5=utils$7.assert;function KeyPair$2(t,e){this.ec=t,this.priv=null,this.pub=null,e.priv&&this._importPrivate(e.priv,e.privEnc),e.pub&&this._importPublic(e.pub,e.pubEnc)}var key$2=KeyPair$2;KeyPair$2.fromPublic=function(e,n,o){return n instanceof KeyPair$2?n:new KeyPair$2(e,{pub:n,pubEnc:o})},KeyPair$2.fromPrivate=function(e,n,o){return n instanceof KeyPair$2?n:new KeyPair$2(e,{priv:n,privEnc:o})},KeyPair$2.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},KeyPair$2.prototype.getPublic=function(e,n){return typeof e=="string"&&(n=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),n?this.pub.encode(n,e):this.pub},KeyPair$2.prototype.getPrivate=function(e){return e==="hex"?this.priv.toString(16,2):this.priv},KeyPair$2.prototype._importPrivate=function(e,n){this.priv=new BN$5(e,n||16),this.priv=this.priv.umod(this.ec.curve.n)},KeyPair$2.prototype._importPublic=function(e,n){if(e.x||e.y){this.ec.curve.type==="mont"?assert$5(e.x,"Need x coordinate"):(this.ec.curve.type==="short"||this.ec.curve.type==="edwards")&&assert$5(e.x&&e.y,"Need both x and y coordinate"),this.pub=this.ec.curve.point(e.x,e.y);return}this.pub=this.ec.curve.decodePoint(e,n)},KeyPair$2.prototype.derive=function(e){return e.validate()||assert$5(e.validate(),"public point not validated"),e.mul(this.priv).getX()},KeyPair$2.prototype.sign=function(e,n,o){return this.ec.sign(e,this,n,o)},KeyPair$2.prototype.verify=function(e,n){return this.ec.verify(e,n,this)},KeyPair$2.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"};var BN$4=bnExports$3,utils$6=utils$o,assert$4=utils$6.assert;function Signature$2(t,e){if(t instanceof Signature$2)return t;this._importDER(t,e)||(assert$4(t.r&&t.s,"Signature without r or s"),this.r=new BN$4(t.r,16),this.s=new BN$4(t.s,16),t.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=t.recoveryParam)}var signature$2=Signature$2;function Position(){this.place=0}function getLength(t,e){var n=t[e.place++];if(!(n&128))return n;var o=n&15;if(o===0||o>4||t[e.place]===0)return!1;for(var u=0,l=0,m=e.place;l<o;l++,m++)u<<=8,u|=t[m],u>>>=0;return u<=127?!1:(e.place=m,u)}function rmPadding(t){for(var e=0,n=t.length-1;!t[e]&&!(t[e+1]&128)&&e<n;)e++;return e===0?t:t.slice(e)}Signature$2.prototype._importDER=function(e,n){e=utils$6.toArray(e,n);var o=new Position;if(e[o.place++]!==48)return!1;var u=getLength(e,o);if(u===!1||u+o.place!==e.length||e[o.place++]!==2)return!1;var l=getLength(e,o);if(l===!1||e[o.place]&128)return!1;var m=e.slice(o.place,l+o.place);if(o.place+=l,e[o.place++]!==2)return!1;var y=getLength(e,o);if(y===!1||e.length!==y+o.place||e[o.place]&128)return!1;var E=e.slice(o.place,y+o.place);if(m[0]===0)if(m[1]&128)m=m.slice(1);else return!1;if(E[0]===0)if(E[1]&128)E=E.slice(1);else return!1;return this.r=new BN$4(m),this.s=new BN$4(E),this.recoveryParam=null,!0};function constructLength(t,e){if(e<128){t.push(e);return}var n=1+(Math.log(e)/Math.LN2>>>3);for(t.push(n|128);--n;)t.push(e>>>(n<<3)&255);t.push(e)}Signature$2.prototype.toDER=function(e){var n=this.r.toArray(),o=this.s.toArray();for(n[0]&128&&(n=[0].concat(n)),o[0]&128&&(o=[0].concat(o)),n=rmPadding(n),o=rmPadding(o);!o[0]&&!(o[1]&128);)o=o.slice(1);var u=[2];constructLength(u,n.length),u=u.concat(n),u.push(2),constructLength(u,o.length);var l=u.concat(o),m=[48];return constructLength(m,l.length),m=m.concat(l),utils$6.encode(m,e)};var ec$1,hasRequiredEc$1;function requireEc$1(){if(hasRequiredEc$1)return ec$1;hasRequiredEc$1=1;var t=bnExports$3,e=hmacDrbg,n=utils$o,o=curves$1,u=requireBrorand(),l=n.assert,m=key$2,y=signature$2;function E(C){if(!(this instanceof E))return new E(C);typeof C=="string"&&(l(Object.prototype.hasOwnProperty.call(o,C),"Unknown curve "+C),C=o[C]),C instanceof o.PresetCurve&&(C={curve:C}),this.curve=C.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=C.curve.g,this.g.precompute(C.curve.n.bitLength()+1),this.hash=C.hash||C.curve.hash}return ec$1=E,E.prototype.keyPair=function(k){return new m(this,k)},E.prototype.keyFromPrivate=function(k,A){return m.fromPrivate(this,k,A)},E.prototype.keyFromPublic=function(k,A){return m.fromPublic(this,k,A)},E.prototype.genKeyPair=function(k){k||(k={});for(var A=new e({hash:this.hash,pers:k.pers,persEnc:k.persEnc||"utf8",entropy:k.entropy||u(this.hash.hmacStrength),entropyEnc:k.entropy&&k.entropyEnc||"utf8",nonce:this.n.toArray()}),D=this.n.byteLength(),P=this.n.sub(new t(2));;){var R=new t(A.generate(D));if(!(R.cmp(P)>0))return R.iaddn(1),this.keyFromPrivate(R)}},E.prototype._truncateToN=function(k,A){var D=k.byteLength()*8-this.n.bitLength();return D>0&&(k=k.ushrn(D)),!A&&k.cmp(this.n)>=0?k.sub(this.n):k},E.prototype.sign=function(k,A,D,P){typeof D=="object"&&(P=D,D=null),P||(P={}),A=this.keyFromPrivate(A,D),k=this._truncateToN(new t(k,16));for(var R=this.n.byteLength(),B=A.getPrivate().toArray("be",R),F=k.toArray("be",R),j=new e({hash:this.hash,entropy:B,nonce:F,pers:P.pers,persEnc:P.persEnc||"utf8"}),N=this.n.sub(new t(1)),Y=0;;Y++){var J=P.k?P.k(Y):new t(j.generate(this.n.byteLength()));if(J=this._truncateToN(J,!0),!(J.cmpn(1)<=0||J.cmp(N)>=0)){var ie=this.g.mul(J);if(!ie.isInfinity()){var ue=ie.getX(),Q=ue.umod(this.n);if(Q.cmpn(0)!==0){var ce=J.invm(this.n).mul(Q.mul(A.getPrivate()).iadd(k));if(ce=ce.umod(this.n),ce.cmpn(0)!==0){var he=(ie.getY().isOdd()?1:0)|(ue.cmp(Q)!==0?2:0);return P.canonical&&ce.cmp(this.nh)>0&&(ce=this.n.sub(ce),he^=1),new y({r:Q,s:ce,recoveryParam:he})}}}}}},E.prototype.verify=function(k,A,D,P){k=this._truncateToN(new t(k,16)),D=this.keyFromPublic(D,P),A=new y(A,"hex");var R=A.r,B=A.s;if(R.cmpn(1)<0||R.cmp(this.n)>=0||B.cmpn(1)<0||B.cmp(this.n)>=0)return!1;var F=B.invm(this.n),j=F.mul(k).umod(this.n),N=F.mul(R).umod(this.n),Y;return this.curve._maxwellTrick?(Y=this.g.jmulAdd(j,D.getPublic(),N),Y.isInfinity()?!1:Y.eqXToP(R)):(Y=this.g.mulAdd(j,D.getPublic(),N),Y.isInfinity()?!1:Y.getX().umod(this.n).cmp(R)===0)},E.prototype.recoverPubKey=function(C,k,A,D){l((3&A)===A,"The recovery param is more than two bits"),k=new y(k,D);var P=this.n,R=new t(C),B=k.r,F=k.s,j=A&1,N=A>>1;if(B.cmp(this.curve.p.umod(this.curve.n))>=0&&N)throw new Error("Unable to find sencond key candinate");N?B=this.curve.pointFromX(B.add(this.curve.n),j):B=this.curve.pointFromX(B,j);var Y=k.r.invm(P),J=P.sub(R).mul(Y).umod(P),ie=F.mul(Y).umod(P);return this.g.mulAdd(J,B,ie)},E.prototype.getKeyRecoveryParam=function(C,k,A,D){if(k=new y(k,D),k.recoveryParam!==null)return k.recoveryParam;for(var P=0;P<4;P++){var R;try{R=this.recoverPubKey(C,k,P)}catch{continue}if(R.eq(A))return P}throw new Error("Unable to find valid recovery factor")},ec$1}var utils$5=utils$o,assert$3=utils$5.assert,parseBytes$2=utils$5.parseBytes,cachedProperty$1=utils$5.cachedProperty;function KeyPair$1(t,e){this.eddsa=t,this._secret=parseBytes$2(e.secret),t.isPoint(e.pub)?this._pub=e.pub:this._pubBytes=parseBytes$2(e.pub)}KeyPair$1.fromPublic=function(e,n){return n instanceof KeyPair$1?n:new KeyPair$1(e,{pub:n})},KeyPair$1.fromSecret=function(e,n){return n instanceof KeyPair$1?n:new KeyPair$1(e,{secret:n})},KeyPair$1.prototype.secret=function(){return this._secret},cachedProperty$1(KeyPair$1,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),cachedProperty$1(KeyPair$1,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())}),cachedProperty$1(KeyPair$1,"privBytes",function(){var e=this.eddsa,n=this.hash(),o=e.encodingLength-1,u=n.slice(0,e.encodingLength);return u[0]&=248,u[o]&=127,u[o]|=64,u}),cachedProperty$1(KeyPair$1,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),cachedProperty$1(KeyPair$1,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),cachedProperty$1(KeyPair$1,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),KeyPair$1.prototype.sign=function(e){return assert$3(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},KeyPair$1.prototype.verify=function(e,n){return this.eddsa.verify(e,n,this)},KeyPair$1.prototype.getSecret=function(e){return assert$3(this._secret,"KeyPair is public only"),utils$5.encode(this.secret(),e)},KeyPair$1.prototype.getPublic=function(e){return utils$5.encode(this.pubBytes(),e)};var key$1=KeyPair$1,BN$3=bnExports$3,utils$4=utils$o,assert$2=utils$4.assert,cachedProperty=utils$4.cachedProperty,parseBytes$1=utils$4.parseBytes;function Signature$1(t,e){this.eddsa=t,typeof e!="object"&&(e=parseBytes$1(e)),Array.isArray(e)&&(assert$2(e.length===t.encodingLength*2,"Signature has invalid size"),e={R:e.slice(0,t.encodingLength),S:e.slice(t.encodingLength)}),assert$2(e.R&&e.S,"Signature without R or S"),t.isPoint(e.R)&&(this._R=e.R),e.S instanceof BN$3&&(this._S=e.S),this._Rencoded=Array.isArray(e.R)?e.R:e.Rencoded,this._Sencoded=Array.isArray(e.S)?e.S:e.Sencoded}cachedProperty(Signature$1,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),cachedProperty(Signature$1,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),cachedProperty(Signature$1,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),cachedProperty(Signature$1,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),Signature$1.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},Signature$1.prototype.toHex=function(){return utils$4.encode(this.toBytes(),"hex").toUpperCase()};var signature$1=Signature$1,hash=hash$2,curves=curves$1,utils$3=utils$o,assert$1=utils$3.assert,parseBytes=utils$3.parseBytes,KeyPair=key$1,Signature=signature$1;function EDDSA(t){if(assert$1(t==="ed25519","only tested with ed25519 so far"),!(this instanceof EDDSA))return new EDDSA(t);t=curves[t].curve,this.curve=t,this.g=t.g,this.g.precompute(t.n.bitLength()+1),this.pointClass=t.point().constructor,this.encodingLength=Math.ceil(t.n.bitLength()/8),this.hash=hash.sha512}var eddsa=EDDSA;EDDSA.prototype.sign=function(e,n){e=parseBytes(e);var o=this.keyFromSecret(n),u=this.hashInt(o.messagePrefix(),e),l=this.g.mul(u),m=this.encodePoint(l),y=this.hashInt(m,o.pubBytes(),e).mul(o.priv()),E=u.add(y).umod(this.curve.n);return this.makeSignature({R:l,S:E,Rencoded:m})},EDDSA.prototype.verify=function(e,n,o){if(e=parseBytes(e),n=this.makeSignature(n),n.S().gte(n.eddsa.curve.n)||n.S().isNeg())return!1;var u=this.keyFromPublic(o),l=this.hashInt(n.Rencoded(),u.pubBytes(),e),m=this.g.mul(n.S()),y=n.R().add(u.pub().mul(l));return y.eq(m)},EDDSA.prototype.hashInt=function(){for(var e=this.hash(),n=0;n<arguments.length;n++)e.update(arguments[n]);return utils$3.intFromLE(e.digest()).umod(this.curve.n)},EDDSA.prototype.keyFromPublic=function(e){return KeyPair.fromPublic(this,e)},EDDSA.prototype.keyFromSecret=function(e){return KeyPair.fromSecret(this,e)},EDDSA.prototype.makeSignature=function(e){return e instanceof Signature?e:new Signature(this,e)},EDDSA.prototype.encodePoint=function(e){var n=e.getY().toArray("le",this.encodingLength);return n[this.encodingLength-1]|=e.getX().isOdd()?128:0,n},EDDSA.prototype.decodePoint=function(e){e=utils$3.parseBytes(e);var n=e.length-1,o=e.slice(0,n).concat(e[n]&-129),u=(e[n]&128)!==0,l=utils$3.intFromLE(o);return this.curve.pointFromY(l,u)},EDDSA.prototype.encodeInt=function(e){return e.toArray("le",this.encodingLength)},EDDSA.prototype.decodeInt=function(e){return utils$3.intFromLE(e)},EDDSA.prototype.isPoint=function(e){return e instanceof this.pointClass};var hasRequiredElliptic;function requireElliptic(){return hasRequiredElliptic||(hasRequiredElliptic=1,function(t){var e=t;e.version=require$$0$1.version,e.utils=utils$o,e.rand=requireBrorand(),e.curve=curve,e.curves=curves$1,e.ec=requireEc$1(),e.eddsa=eddsa}(elliptic)),elliptic}var asn1$3={},asn1$2={},bn$2={exports:{}};bn$2.exports,function(t){(function(e,n){function o(L,d){if(!L)throw new Error(d||"Assertion failed")}function u(L,d){L.super_=d;var v=function(){};v.prototype=d.prototype,L.prototype=new v,L.prototype.constructor=L}function l(L,d,v){if(l.isBN(L))return L;this.negative=0,this.words=null,this.length=0,this.red=null,L!==null&&((d==="le"||d==="be")&&(v=d,d=10),this._init(L||0,d||10,v||"be"))}typeof e=="object"?e.exports=l:n.BN=l,l.BN=l,l.wordSize=26;var m;try{typeof window<"u"&&typeof window.Buffer<"u"?m=window.Buffer:m=require$$0$2.Buffer}catch{}l.isBN=function(d){return d instanceof l?!0:d!==null&&typeof d=="object"&&d.constructor.wordSize===l.wordSize&&Array.isArray(d.words)},l.max=function(d,v){return d.cmp(v)>0?d:v},l.min=function(d,v){return d.cmp(v)<0?d:v},l.prototype._init=function(d,v,w){if(typeof d=="number")return this._initNumber(d,v,w);if(typeof d=="object")return this._initArray(d,v,w);v==="hex"&&(v=16),o(v===(v|0)&&v>=2&&v<=36),d=d.toString().replace(/\s+/g,"");var c=0;d[0]==="-"&&(c++,this.negative=1),c<d.length&&(v===16?this._parseHex(d,c,w):(this._parseBase(d,v,c),w==="le"&&this._initArray(this.toArray(),v,w)))},l.prototype._initNumber=function(d,v,w){d<0&&(this.negative=1,d=-d),d<67108864?(this.words=[d&67108863],this.length=1):d<4503599627370496?(this.words=[d&67108863,d/67108864&67108863],this.length=2):(o(d<9007199254740992),this.words=[d&67108863,d/67108864&67108863,1],this.length=3),w==="le"&&this._initArray(this.toArray(),v,w)},l.prototype._initArray=function(d,v,w){if(o(typeof d.length=="number"),d.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(d.length/3),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p,x,S=0;if(w==="be")for(c=d.length-1,p=0;c>=0;c-=3)x=d[c]|d[c-1]<<8|d[c-2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);else if(w==="le")for(c=0,p=0;c<d.length;c+=3)x=d[c]|d[c+1]<<8|d[c+2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);return this.strip()};function y(L,d){var v=L.charCodeAt(d);return v>=65&&v<=70?v-55:v>=97&&v<=102?v-87:v-48&15}function E(L,d,v){var w=y(L,v);return v-1>=d&&(w|=y(L,v-1)<<4),w}l.prototype._parseHex=function(d,v,w){this.length=Math.ceil((d.length-v)/6),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p=0,x=0,S;if(w==="be")for(c=d.length-1;c>=v;c-=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8;else{var b=d.length-v;for(c=b%2===0?v+1:v;c<d.length;c+=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8}this.strip()};function C(L,d,v,w){for(var c=0,p=Math.min(L.length,v),x=d;x<p;x++){var S=L.charCodeAt(x)-48;c*=w,S>=49?c+=S-49+10:S>=17?c+=S-17+10:c+=S}return c}l.prototype._parseBase=function(d,v,w){this.words=[0],this.length=1;for(var c=0,p=1;p<=67108863;p*=v)c++;c--,p=p/v|0;for(var x=d.length-w,S=x%c,b=Math.min(x,x-S)+w,h=0,T=w;T<b;T+=c)h=C(d,T,T+c,v),this.imuln(p),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h);if(S!==0){var M=1;for(h=C(d,T,d.length,v),T=0;T<S;T++)M*=v;this.imuln(M),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h)}this.strip()},l.prototype.copy=function(d){d.words=new Array(this.length);for(var v=0;v<this.length;v++)d.words[v]=this.words[v];d.length=this.length,d.negative=this.negative,d.red=this.red},l.prototype.clone=function(){var d=new l(null);return this.copy(d),d},l.prototype._expand=function(d){for(;this.length<d;)this.words[this.length++]=0;return this},l.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},l.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},l.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var k=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],D=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];l.prototype.toString=function(d,v){d=d||10,v=v|0||1;var w;if(d===16||d==="hex"){w="";for(var c=0,p=0,x=0;x<this.length;x++){var S=this.words[x],b=((S<<c|p)&16777215).toString(16);p=S>>>24-c&16777215,p!==0||x!==this.length-1?w=k[6-b.length]+b+w:w=b+w,c+=2,c>=26&&(c-=26,x--)}for(p!==0&&(w=p.toString(16)+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}if(d===(d|0)&&d>=2&&d<=36){var h=A[d],T=D[d];w="";var M=this.clone();for(M.negative=0;!M.isZero();){var O=M.modn(T).toString(d);M=M.idivn(T),M.isZero()?w=O+w:w=k[h-O.length]+O+w}for(this.isZero()&&(w="0"+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}o(!1,"Base should be between 2 and 36")},l.prototype.toNumber=function(){var d=this.words[0];return this.length===2?d+=this.words[1]*67108864:this.length===3&&this.words[2]===1?d+=4503599627370496+this.words[1]*67108864:this.length>2&&o(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-d:d},l.prototype.toJSON=function(){return this.toString(16)},l.prototype.toBuffer=function(d,v){return o(typeof m<"u"),this.toArrayLike(m,d,v)},l.prototype.toArray=function(d,v){return this.toArrayLike(Array,d,v)},l.prototype.toArrayLike=function(d,v,w){var c=this.byteLength(),p=w||Math.max(1,c);o(c<=p,"byte array longer than desired length"),o(p>0,"Requested array length <= 0"),this.strip();var x=v==="le",S=new d(p),b,h,T=this.clone();if(x){for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[h]=b;for(;h<p;h++)S[h]=0}else{for(h=0;h<p-c;h++)S[h]=0;for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[p-h-1]=b}return S},Math.clz32?l.prototype._countBits=function(d){return 32-Math.clz32(d)}:l.prototype._countBits=function(d){var v=d,w=0;return v>=4096&&(w+=13,v>>>=13),v>=64&&(w+=7,v>>>=7),v>=8&&(w+=4,v>>>=4),v>=2&&(w+=2,v>>>=2),w+v},l.prototype._zeroBits=function(d){if(d===0)return 26;var v=d,w=0;return v&8191||(w+=13,v>>>=13),v&127||(w+=7,v>>>=7),v&15||(w+=4,v>>>=4),v&3||(w+=2,v>>>=2),v&1||w++,w},l.prototype.bitLength=function(){var d=this.words[this.length-1],v=this._countBits(d);return(this.length-1)*26+v};function P(L){for(var d=new Array(L.bitLength()),v=0;v<d.length;v++){var w=v/26|0,c=v%26;d[v]=(L.words[w]&1<<c)>>>c}return d}l.prototype.zeroBits=function(){if(this.isZero())return 0;for(var d=0,v=0;v<this.length;v++){var w=this._zeroBits(this.words[v]);if(d+=w,w!==26)break}return d},l.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},l.prototype.toTwos=function(d){return this.negative!==0?this.abs().inotn(d).iaddn(1):this.clone()},l.prototype.fromTwos=function(d){return this.testn(d-1)?this.notn(d).iaddn(1).ineg():this.clone()},l.prototype.isNeg=function(){return this.negative!==0},l.prototype.neg=function(){return this.clone().ineg()},l.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},l.prototype.iuor=function(d){for(;this.length<d.length;)this.words[this.length++]=0;for(var v=0;v<d.length;v++)this.words[v]=this.words[v]|d.words[v];return this.strip()},l.prototype.ior=function(d){return o((this.negative|d.negative)===0),this.iuor(d)},l.prototype.or=function(d){return this.length>d.length?this.clone().ior(d):d.clone().ior(this)},l.prototype.uor=function(d){return this.length>d.length?this.clone().iuor(d):d.clone().iuor(this)},l.prototype.iuand=function(d){var v;this.length>d.length?v=d:v=this;for(var w=0;w<v.length;w++)this.words[w]=this.words[w]&d.words[w];return this.length=v.length,this.strip()},l.prototype.iand=function(d){return o((this.negative|d.negative)===0),this.iuand(d)},l.prototype.and=function(d){return this.length>d.length?this.clone().iand(d):d.clone().iand(this)},l.prototype.uand=function(d){return this.length>d.length?this.clone().iuand(d):d.clone().iuand(this)},l.prototype.iuxor=function(d){var v,w;this.length>d.length?(v=this,w=d):(v=d,w=this);for(var c=0;c<w.length;c++)this.words[c]=v.words[c]^w.words[c];if(this!==v)for(;c<v.length;c++)this.words[c]=v.words[c];return this.length=v.length,this.strip()},l.prototype.ixor=function(d){return o((this.negative|d.negative)===0),this.iuxor(d)},l.prototype.xor=function(d){return this.length>d.length?this.clone().ixor(d):d.clone().ixor(this)},l.prototype.uxor=function(d){return this.length>d.length?this.clone().iuxor(d):d.clone().iuxor(this)},l.prototype.inotn=function(d){o(typeof d=="number"&&d>=0);var v=Math.ceil(d/26)|0,w=d%26;this._expand(v),w>0&&v--;for(var c=0;c<v;c++)this.words[c]=~this.words[c]&67108863;return w>0&&(this.words[c]=~this.words[c]&67108863>>26-w),this.strip()},l.prototype.notn=function(d){return this.clone().inotn(d)},l.prototype.setn=function(d,v){o(typeof d=="number"&&d>=0);var w=d/26|0,c=d%26;return this._expand(w+1),v?this.words[w]=this.words[w]|1<<c:this.words[w]=this.words[w]&~(1<<c),this.strip()},l.prototype.iadd=function(d){var v;if(this.negative!==0&&d.negative===0)return this.negative=0,v=this.isub(d),this.negative^=1,this._normSign();if(this.negative===0&&d.negative!==0)return d.negative=0,v=this.isub(d),d.negative=1,v._normSign();var w,c;this.length>d.length?(w=this,c=d):(w=d,c=this);for(var p=0,x=0;x<c.length;x++)v=(w.words[x]|0)+(c.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;for(;p!==0&&x<w.length;x++)v=(w.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;if(this.length=w.length,p!==0)this.words[this.length]=p,this.length++;else if(w!==this)for(;x<w.length;x++)this.words[x]=w.words[x];return this},l.prototype.add=function(d){var v;return d.negative!==0&&this.negative===0?(d.negative=0,v=this.sub(d),d.negative^=1,v):d.negative===0&&this.negative!==0?(this.negative=0,v=d.sub(this),this.negative=1,v):this.length>d.length?this.clone().iadd(d):d.clone().iadd(this)},l.prototype.isub=function(d){if(d.negative!==0){d.negative=0;var v=this.iadd(d);return d.negative=1,v._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(d),this.negative=1,this._normSign();var w=this.cmp(d);if(w===0)return this.negative=0,this.length=1,this.words[0]=0,this;var c,p;w>0?(c=this,p=d):(c=d,p=this);for(var x=0,S=0;S<p.length;S++)v=(c.words[S]|0)-(p.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;for(;x!==0&&S<c.length;S++)v=(c.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;if(x===0&&S<c.length&&c!==this)for(;S<c.length;S++)this.words[S]=c.words[S];return this.length=Math.max(this.length,S),c!==this&&(this.negative=1),this.strip()},l.prototype.sub=function(d){return this.clone().isub(d)};function R(L,d,v){v.negative=d.negative^L.negative;var w=L.length+d.length|0;v.length=w,w=w-1|0;var c=L.words[0]|0,p=d.words[0]|0,x=c*p,S=x&67108863,b=x/67108864|0;v.words[0]=S;for(var h=1;h<w;h++){for(var T=b>>>26,M=b&67108863,O=Math.min(h,d.length-1),V=Math.max(0,h-L.length+1);V<=O;V++){var ee=h-V|0;c=L.words[ee]|0,p=d.words[V]|0,x=c*p+M,T+=x/67108864|0,M=x&67108863}v.words[h]=M|0,b=T|0}return b!==0?v.words[h]=b|0:v.length--,v.strip()}var B=function(d,v,w){var c=d.words,p=v.words,x=w.words,S=0,b,h,T,M=c[0]|0,O=M&8191,V=M>>>13,ee=c[1]|0,Z=ee&8191,U=ee>>>13,z=c[2]|0,ne=z&8191,fe=z>>>13,me=c[3]|0,de=me&8191,je=me>>>13,lt=c[4]|0,it=lt&8191,ot=lt>>>13,Ct=c[5]|0,nt=Ct&8191,Je=Ct>>>13,tt=c[6]|0,rt=tt&8191,ht=tt>>>13,Ot=c[7]|0,Ve=Ot&8191,We=Ot>>>13,Gt=c[8]|0,wt=Gt&8191,Et=Gt>>>13,Yt=c[9]|0,Ce=Yt&8191,te=Yt>>>13,ye=p[0]|0,Le=ye&8191,Ue=ye>>>13,Qe=p[1]|0,Ke=Qe&8191,De=Qe>>>13,Vt=p[2]|0,At=Vt&8191,ve=Vt>>>13,Pt=p[3]|0,pt=Pt&8191,Ne=Pt>>>13,vt=p[4]|0,ut=vt&8191,$t=vt>>>13,fi=p[5]|0,kt=fi&8191,Wt=fi>>>13,Zi=p[6]|0,Ut=Zi&8191,Xt=Zi>>>13,Be=p[7]|0,be=Be&8191,ge=Be>>>13,oe=p[8]|0,Ae=oe&8191,qe=oe>>>13,bt=p[9]|0,at=bt&8191,gt=bt>>>13;w.negative=d.negative^v.negative,w.length=19,b=Math.imul(O,Le),h=Math.imul(O,Ue),h=h+Math.imul(V,Le)|0,T=Math.imul(V,Ue);var ei=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ei>>>26)|0,ei&=67108863,b=Math.imul(Z,Le),h=Math.imul(Z,Ue),h=h+Math.imul(U,Le)|0,T=Math.imul(U,Ue),b=b+Math.imul(O,Ke)|0,h=h+Math.imul(O,De)|0,h=h+Math.imul(V,Ke)|0,T=T+Math.imul(V,De)|0;var ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ii>>>26)|0,ii&=67108863,b=Math.imul(ne,Le),h=Math.imul(ne,Ue),h=h+Math.imul(fe,Le)|0,T=Math.imul(fe,Ue),b=b+Math.imul(Z,Ke)|0,h=h+Math.imul(Z,De)|0,h=h+Math.imul(U,Ke)|0,T=T+Math.imul(U,De)|0,b=b+Math.imul(O,At)|0,h=h+Math.imul(O,ve)|0,h=h+Math.imul(V,At)|0,T=T+Math.imul(V,ve)|0;var Bi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Bi>>>26)|0,Bi&=67108863,b=Math.imul(de,Le),h=Math.imul(de,Ue),h=h+Math.imul(je,Le)|0,T=Math.imul(je,Ue),b=b+Math.imul(ne,Ke)|0,h=h+Math.imul(ne,De)|0,h=h+Math.imul(fe,Ke)|0,T=T+Math.imul(fe,De)|0,b=b+Math.imul(Z,At)|0,h=h+Math.imul(Z,ve)|0,h=h+Math.imul(U,At)|0,T=T+Math.imul(U,ve)|0,b=b+Math.imul(O,pt)|0,h=h+Math.imul(O,Ne)|0,h=h+Math.imul(V,pt)|0,T=T+Math.imul(V,Ne)|0;var hi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(hi>>>26)|0,hi&=67108863,b=Math.imul(it,Le),h=Math.imul(it,Ue),h=h+Math.imul(ot,Le)|0,T=Math.imul(ot,Ue),b=b+Math.imul(de,Ke)|0,h=h+Math.imul(de,De)|0,h=h+Math.imul(je,Ke)|0,T=T+Math.imul(je,De)|0,b=b+Math.imul(ne,At)|0,h=h+Math.imul(ne,ve)|0,h=h+Math.imul(fe,At)|0,T=T+Math.imul(fe,ve)|0,b=b+Math.imul(Z,pt)|0,h=h+Math.imul(Z,Ne)|0,h=h+Math.imul(U,pt)|0,T=T+Math.imul(U,Ne)|0,b=b+Math.imul(O,ut)|0,h=h+Math.imul(O,$t)|0,h=h+Math.imul(V,ut)|0,T=T+Math.imul(V,$t)|0;var Di=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Di>>>26)|0,Di&=67108863,b=Math.imul(nt,Le),h=Math.imul(nt,Ue),h=h+Math.imul(Je,Le)|0,T=Math.imul(Je,Ue),b=b+Math.imul(it,Ke)|0,h=h+Math.imul(it,De)|0,h=h+Math.imul(ot,Ke)|0,T=T+Math.imul(ot,De)|0,b=b+Math.imul(de,At)|0,h=h+Math.imul(de,ve)|0,h=h+Math.imul(je,At)|0,T=T+Math.imul(je,ve)|0,b=b+Math.imul(ne,pt)|0,h=h+Math.imul(ne,Ne)|0,h=h+Math.imul(fe,pt)|0,T=T+Math.imul(fe,Ne)|0,b=b+Math.imul(Z,ut)|0,h=h+Math.imul(Z,$t)|0,h=h+Math.imul(U,ut)|0,T=T+Math.imul(U,$t)|0,b=b+Math.imul(O,kt)|0,h=h+Math.imul(O,Wt)|0,h=h+Math.imul(V,kt)|0,T=T+Math.imul(V,Wt)|0;var ni=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ni>>>26)|0,ni&=67108863,b=Math.imul(rt,Le),h=Math.imul(rt,Ue),h=h+Math.imul(ht,Le)|0,T=Math.imul(ht,Ue),b=b+Math.imul(nt,Ke)|0,h=h+Math.imul(nt,De)|0,h=h+Math.imul(Je,Ke)|0,T=T+Math.imul(Je,De)|0,b=b+Math.imul(it,At)|0,h=h+Math.imul(it,ve)|0,h=h+Math.imul(ot,At)|0,T=T+Math.imul(ot,ve)|0,b=b+Math.imul(de,pt)|0,h=h+Math.imul(de,Ne)|0,h=h+Math.imul(je,pt)|0,T=T+Math.imul(je,Ne)|0,b=b+Math.imul(ne,ut)|0,h=h+Math.imul(ne,$t)|0,h=h+Math.imul(fe,ut)|0,T=T+Math.imul(fe,$t)|0,b=b+Math.imul(Z,kt)|0,h=h+Math.imul(Z,Wt)|0,h=h+Math.imul(U,kt)|0,T=T+Math.imul(U,Wt)|0,b=b+Math.imul(O,Ut)|0,h=h+Math.imul(O,Xt)|0,h=h+Math.imul(V,Ut)|0,T=T+Math.imul(V,Xt)|0;var pi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(pi>>>26)|0,pi&=67108863,b=Math.imul(Ve,Le),h=Math.imul(Ve,Ue),h=h+Math.imul(We,Le)|0,T=Math.imul(We,Ue),b=b+Math.imul(rt,Ke)|0,h=h+Math.imul(rt,De)|0,h=h+Math.imul(ht,Ke)|0,T=T+Math.imul(ht,De)|0,b=b+Math.imul(nt,At)|0,h=h+Math.imul(nt,ve)|0,h=h+Math.imul(Je,At)|0,T=T+Math.imul(Je,ve)|0,b=b+Math.imul(it,pt)|0,h=h+Math.imul(it,Ne)|0,h=h+Math.imul(ot,pt)|0,T=T+Math.imul(ot,Ne)|0,b=b+Math.imul(de,ut)|0,h=h+Math.imul(de,$t)|0,h=h+Math.imul(je,ut)|0,T=T+Math.imul(je,$t)|0,b=b+Math.imul(ne,kt)|0,h=h+Math.imul(ne,Wt)|0,h=h+Math.imul(fe,kt)|0,T=T+Math.imul(fe,Wt)|0,b=b+Math.imul(Z,Ut)|0,h=h+Math.imul(Z,Xt)|0,h=h+Math.imul(U,Ut)|0,T=T+Math.imul(U,Xt)|0,b=b+Math.imul(O,be)|0,h=h+Math.imul(O,ge)|0,h=h+Math.imul(V,be)|0,T=T+Math.imul(V,ge)|0;var Ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ii>>>26)|0,Ii&=67108863,b=Math.imul(wt,Le),h=Math.imul(wt,Ue),h=h+Math.imul(Et,Le)|0,T=Math.imul(Et,Ue),b=b+Math.imul(Ve,Ke)|0,h=h+Math.imul(Ve,De)|0,h=h+Math.imul(We,Ke)|0,T=T+Math.imul(We,De)|0,b=b+Math.imul(rt,At)|0,h=h+Math.imul(rt,ve)|0,h=h+Math.imul(ht,At)|0,T=T+Math.imul(ht,ve)|0,b=b+Math.imul(nt,pt)|0,h=h+Math.imul(nt,Ne)|0,h=h+Math.imul(Je,pt)|0,T=T+Math.imul(Je,Ne)|0,b=b+Math.imul(it,ut)|0,h=h+Math.imul(it,$t)|0,h=h+Math.imul(ot,ut)|0,T=T+Math.imul(ot,$t)|0,b=b+Math.imul(de,kt)|0,h=h+Math.imul(de,Wt)|0,h=h+Math.imul(je,kt)|0,T=T+Math.imul(je,Wt)|0,b=b+Math.imul(ne,Ut)|0,h=h+Math.imul(ne,Xt)|0,h=h+Math.imul(fe,Ut)|0,T=T+Math.imul(fe,Xt)|0,b=b+Math.imul(Z,be)|0,h=h+Math.imul(Z,ge)|0,h=h+Math.imul(U,be)|0,T=T+Math.imul(U,ge)|0,b=b+Math.imul(O,Ae)|0,h=h+Math.imul(O,qe)|0,h=h+Math.imul(V,Ae)|0,T=T+Math.imul(V,qe)|0;var Ci=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ci>>>26)|0,Ci&=67108863,b=Math.imul(Ce,Le),h=Math.imul(Ce,Ue),h=h+Math.imul(te,Le)|0,T=Math.imul(te,Ue),b=b+Math.imul(wt,Ke)|0,h=h+Math.imul(wt,De)|0,h=h+Math.imul(Et,Ke)|0,T=T+Math.imul(Et,De)|0,b=b+Math.imul(Ve,At)|0,h=h+Math.imul(Ve,ve)|0,h=h+Math.imul(We,At)|0,T=T+Math.imul(We,ve)|0,b=b+Math.imul(rt,pt)|0,h=h+Math.imul(rt,Ne)|0,h=h+Math.imul(ht,pt)|0,T=T+Math.imul(ht,Ne)|0,b=b+Math.imul(nt,ut)|0,h=h+Math.imul(nt,$t)|0,h=h+Math.imul(Je,ut)|0,T=T+Math.imul(Je,$t)|0,b=b+Math.imul(it,kt)|0,h=h+Math.imul(it,Wt)|0,h=h+Math.imul(ot,kt)|0,T=T+Math.imul(ot,Wt)|0,b=b+Math.imul(de,Ut)|0,h=h+Math.imul(de,Xt)|0,h=h+Math.imul(je,Ut)|0,T=T+Math.imul(je,Xt)|0,b=b+Math.imul(ne,be)|0,h=h+Math.imul(ne,ge)|0,h=h+Math.imul(fe,be)|0,T=T+Math.imul(fe,ge)|0,b=b+Math.imul(Z,Ae)|0,h=h+Math.imul(Z,qe)|0,h=h+Math.imul(U,Ae)|0,T=T+Math.imul(U,qe)|0,b=b+Math.imul(O,at)|0,h=h+Math.imul(O,gt)|0,h=h+Math.imul(V,at)|0,T=T+Math.imul(V,gt)|0;var zi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zi>>>26)|0,zi&=67108863,b=Math.imul(Ce,Ke),h=Math.imul(Ce,De),h=h+Math.imul(te,Ke)|0,T=Math.imul(te,De),b=b+Math.imul(wt,At)|0,h=h+Math.imul(wt,ve)|0,h=h+Math.imul(Et,At)|0,T=T+Math.imul(Et,ve)|0,b=b+Math.imul(Ve,pt)|0,h=h+Math.imul(Ve,Ne)|0,h=h+Math.imul(We,pt)|0,T=T+Math.imul(We,Ne)|0,b=b+Math.imul(rt,ut)|0,h=h+Math.imul(rt,$t)|0,h=h+Math.imul(ht,ut)|0,T=T+Math.imul(ht,$t)|0,b=b+Math.imul(nt,kt)|0,h=h+Math.imul(nt,Wt)|0,h=h+Math.imul(Je,kt)|0,T=T+Math.imul(Je,Wt)|0,b=b+Math.imul(it,Ut)|0,h=h+Math.imul(it,Xt)|0,h=h+Math.imul(ot,Ut)|0,T=T+Math.imul(ot,Xt)|0,b=b+Math.imul(de,be)|0,h=h+Math.imul(de,ge)|0,h=h+Math.imul(je,be)|0,T=T+Math.imul(je,ge)|0,b=b+Math.imul(ne,Ae)|0,h=h+Math.imul(ne,qe)|0,h=h+Math.imul(fe,Ae)|0,T=T+Math.imul(fe,qe)|0,b=b+Math.imul(Z,at)|0,h=h+Math.imul(Z,gt)|0,h=h+Math.imul(U,at)|0,T=T+Math.imul(U,gt)|0;var qi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(qi>>>26)|0,qi&=67108863,b=Math.imul(Ce,At),h=Math.imul(Ce,ve),h=h+Math.imul(te,At)|0,T=Math.imul(te,ve),b=b+Math.imul(wt,pt)|0,h=h+Math.imul(wt,Ne)|0,h=h+Math.imul(Et,pt)|0,T=T+Math.imul(Et,Ne)|0,b=b+Math.imul(Ve,ut)|0,h=h+Math.imul(Ve,$t)|0,h=h+Math.imul(We,ut)|0,T=T+Math.imul(We,$t)|0,b=b+Math.imul(rt,kt)|0,h=h+Math.imul(rt,Wt)|0,h=h+Math.imul(ht,kt)|0,T=T+Math.imul(ht,Wt)|0,b=b+Math.imul(nt,Ut)|0,h=h+Math.imul(nt,Xt)|0,h=h+Math.imul(Je,Ut)|0,T=T+Math.imul(Je,Xt)|0,b=b+Math.imul(it,be)|0,h=h+Math.imul(it,ge)|0,h=h+Math.imul(ot,be)|0,T=T+Math.imul(ot,ge)|0,b=b+Math.imul(de,Ae)|0,h=h+Math.imul(de,qe)|0,h=h+Math.imul(je,Ae)|0,T=T+Math.imul(je,qe)|0,b=b+Math.imul(ne,at)|0,h=h+Math.imul(ne,gt)|0,h=h+Math.imul(fe,at)|0,T=T+Math.imul(fe,gt)|0;var Ai=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ai>>>26)|0,Ai&=67108863,b=Math.imul(Ce,pt),h=Math.imul(Ce,Ne),h=h+Math.imul(te,pt)|0,T=Math.imul(te,Ne),b=b+Math.imul(wt,ut)|0,h=h+Math.imul(wt,$t)|0,h=h+Math.imul(Et,ut)|0,T=T+Math.imul(Et,$t)|0,b=b+Math.imul(Ve,kt)|0,h=h+Math.imul(Ve,Wt)|0,h=h+Math.imul(We,kt)|0,T=T+Math.imul(We,Wt)|0,b=b+Math.imul(rt,Ut)|0,h=h+Math.imul(rt,Xt)|0,h=h+Math.imul(ht,Ut)|0,T=T+Math.imul(ht,Xt)|0,b=b+Math.imul(nt,be)|0,h=h+Math.imul(nt,ge)|0,h=h+Math.imul(Je,be)|0,T=T+Math.imul(Je,ge)|0,b=b+Math.imul(it,Ae)|0,h=h+Math.imul(it,qe)|0,h=h+Math.imul(ot,Ae)|0,T=T+Math.imul(ot,qe)|0,b=b+Math.imul(de,at)|0,h=h+Math.imul(de,gt)|0,h=h+Math.imul(je,at)|0,T=T+Math.imul(je,gt)|0;var Oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Oi>>>26)|0,Oi&=67108863,b=Math.imul(Ce,ut),h=Math.imul(Ce,$t),h=h+Math.imul(te,ut)|0,T=Math.imul(te,$t),b=b+Math.imul(wt,kt)|0,h=h+Math.imul(wt,Wt)|0,h=h+Math.imul(Et,kt)|0,T=T+Math.imul(Et,Wt)|0,b=b+Math.imul(Ve,Ut)|0,h=h+Math.imul(Ve,Xt)|0,h=h+Math.imul(We,Ut)|0,T=T+Math.imul(We,Xt)|0,b=b+Math.imul(rt,be)|0,h=h+Math.imul(rt,ge)|0,h=h+Math.imul(ht,be)|0,T=T+Math.imul(ht,ge)|0,b=b+Math.imul(nt,Ae)|0,h=h+Math.imul(nt,qe)|0,h=h+Math.imul(Je,Ae)|0,T=T+Math.imul(Je,qe)|0,b=b+Math.imul(it,at)|0,h=h+Math.imul(it,gt)|0,h=h+Math.imul(ot,at)|0,T=T+Math.imul(ot,gt)|0;var ki=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ki>>>26)|0,ki&=67108863,b=Math.imul(Ce,kt),h=Math.imul(Ce,Wt),h=h+Math.imul(te,kt)|0,T=Math.imul(te,Wt),b=b+Math.imul(wt,Ut)|0,h=h+Math.imul(wt,Xt)|0,h=h+Math.imul(Et,Ut)|0,T=T+Math.imul(Et,Xt)|0,b=b+Math.imul(Ve,be)|0,h=h+Math.imul(Ve,ge)|0,h=h+Math.imul(We,be)|0,T=T+Math.imul(We,ge)|0,b=b+Math.imul(rt,Ae)|0,h=h+Math.imul(rt,qe)|0,h=h+Math.imul(ht,Ae)|0,T=T+Math.imul(ht,qe)|0,b=b+Math.imul(nt,at)|0,h=h+Math.imul(nt,gt)|0,h=h+Math.imul(Je,at)|0,T=T+Math.imul(Je,gt)|0;var Ti=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ti>>>26)|0,Ti&=67108863,b=Math.imul(Ce,Ut),h=Math.imul(Ce,Xt),h=h+Math.imul(te,Ut)|0,T=Math.imul(te,Xt),b=b+Math.imul(wt,be)|0,h=h+Math.imul(wt,ge)|0,h=h+Math.imul(Et,be)|0,T=T+Math.imul(Et,ge)|0,b=b+Math.imul(Ve,Ae)|0,h=h+Math.imul(Ve,qe)|0,h=h+Math.imul(We,Ae)|0,T=T+Math.imul(We,qe)|0,b=b+Math.imul(rt,at)|0,h=h+Math.imul(rt,gt)|0,h=h+Math.imul(ht,at)|0,T=T+Math.imul(ht,gt)|0;var wi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(wi>>>26)|0,wi&=67108863,b=Math.imul(Ce,be),h=Math.imul(Ce,ge),h=h+Math.imul(te,be)|0,T=Math.imul(te,ge),b=b+Math.imul(wt,Ae)|0,h=h+Math.imul(wt,qe)|0,h=h+Math.imul(Et,Ae)|0,T=T+Math.imul(Et,qe)|0,b=b+Math.imul(Ve,at)|0,h=h+Math.imul(Ve,gt)|0,h=h+Math.imul(We,at)|0,T=T+Math.imul(We,gt)|0;var oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(oi>>>26)|0,oi&=67108863,b=Math.imul(Ce,Ae),h=Math.imul(Ce,qe),h=h+Math.imul(te,Ae)|0,T=Math.imul(te,qe),b=b+Math.imul(wt,at)|0,h=h+Math.imul(wt,gt)|0,h=h+Math.imul(Et,at)|0,T=T+Math.imul(Et,gt)|0;var zt=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zt>>>26)|0,zt&=67108863,b=Math.imul(Ce,at),h=Math.imul(Ce,gt),h=h+Math.imul(te,at)|0,T=Math.imul(te,gt);var Qt=(S+b|0)+((h&8191)<<13)|0;return S=(T+(h>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,x[0]=ei,x[1]=ii,x[2]=Bi,x[3]=hi,x[4]=Di,x[5]=ni,x[6]=pi,x[7]=Ii,x[8]=Ci,x[9]=zi,x[10]=qi,x[11]=Ai,x[12]=Oi,x[13]=ki,x[14]=Ti,x[15]=wi,x[16]=oi,x[17]=zt,x[18]=Qt,S!==0&&(x[19]=S,w.length++),w};Math.imul||(B=R);function F(L,d,v){v.negative=d.negative^L.negative,v.length=L.length+d.length;for(var w=0,c=0,p=0;p<v.length-1;p++){var x=c;c=0;for(var S=w&67108863,b=Math.min(p,d.length-1),h=Math.max(0,p-L.length+1);h<=b;h++){var T=p-h,M=L.words[T]|0,O=d.words[h]|0,V=M*O,ee=V&67108863;x=x+(V/67108864|0)|0,ee=ee+S|0,S=ee&67108863,x=x+(ee>>>26)|0,c+=x>>>26,x&=67108863}v.words[p]=S,w=x,x=c}return w!==0?v.words[p]=w:v.length--,v.strip()}function j(L,d,v){var w=new N;return w.mulp(L,d,v)}l.prototype.mulTo=function(d,v){var w,c=this.length+d.length;return this.length===10&&d.length===10?w=B(this,d,v):c<63?w=R(this,d,v):c<1024?w=F(this,d,v):w=j(this,d,v),w};function N(L,d){this.x=L,this.y=d}N.prototype.makeRBT=function(d){for(var v=new Array(d),w=l.prototype._countBits(d)-1,c=0;c<d;c++)v[c]=this.revBin(c,w,d);return v},N.prototype.revBin=function(d,v,w){if(d===0||d===w-1)return d;for(var c=0,p=0;p<v;p++)c|=(d&1)<<v-p-1,d>>=1;return c},N.prototype.permute=function(d,v,w,c,p,x){for(var S=0;S<x;S++)c[S]=v[d[S]],p[S]=w[d[S]]},N.prototype.transform=function(d,v,w,c,p,x){this.permute(x,d,v,w,c,p);for(var S=1;S<p;S<<=1)for(var b=S<<1,h=Math.cos(2*Math.PI/b),T=Math.sin(2*Math.PI/b),M=0;M<p;M+=b)for(var O=h,V=T,ee=0;ee<S;ee++){var Z=w[M+ee],U=c[M+ee],z=w[M+ee+S],ne=c[M+ee+S],fe=O*z-V*ne;ne=O*ne+V*z,z=fe,w[M+ee]=Z+z,c[M+ee]=U+ne,w[M+ee+S]=Z-z,c[M+ee+S]=U-ne,ee!==b&&(fe=h*O-T*V,V=h*V+T*O,O=fe)}},N.prototype.guessLen13b=function(d,v){var w=Math.max(v,d)|1,c=w&1,p=0;for(w=w/2|0;w;w=w>>>1)p++;return 1<<p+1+c},N.prototype.conjugate=function(d,v,w){if(!(w<=1))for(var c=0;c<w/2;c++){var p=d[c];d[c]=d[w-c-1],d[w-c-1]=p,p=v[c],v[c]=-v[w-c-1],v[w-c-1]=-p}},N.prototype.normalize13b=function(d,v){for(var w=0,c=0;c<v/2;c++){var p=Math.round(d[2*c+1]/v)*8192+Math.round(d[2*c]/v)+w;d[c]=p&67108863,p<67108864?w=0:w=p/67108864|0}return d},N.prototype.convert13b=function(d,v,w,c){for(var p=0,x=0;x<v;x++)p=p+(d[x]|0),w[2*x]=p&8191,p=p>>>13,w[2*x+1]=p&8191,p=p>>>13;for(x=2*v;x<c;++x)w[x]=0;o(p===0),o((p&-8192)===0)},N.prototype.stub=function(d){for(var v=new Array(d),w=0;w<d;w++)v[w]=0;return v},N.prototype.mulp=function(d,v,w){var c=2*this.guessLen13b(d.length,v.length),p=this.makeRBT(c),x=this.stub(c),S=new Array(c),b=new Array(c),h=new Array(c),T=new Array(c),M=new Array(c),O=new Array(c),V=w.words;V.length=c,this.convert13b(d.words,d.length,S,c),this.convert13b(v.words,v.length,T,c),this.transform(S,x,b,h,c,p),this.transform(T,x,M,O,c,p);for(var ee=0;ee<c;ee++){var Z=b[ee]*M[ee]-h[ee]*O[ee];h[ee]=b[ee]*O[ee]+h[ee]*M[ee],b[ee]=Z}return this.conjugate(b,h,c),this.transform(b,h,V,x,c,p),this.conjugate(V,x,c),this.normalize13b(V,c),w.negative=d.negative^v.negative,w.length=d.length+v.length,w.strip()},l.prototype.mul=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),this.mulTo(d,v)},l.prototype.mulf=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),j(this,d,v)},l.prototype.imul=function(d){return this.clone().mulTo(d,this)},l.prototype.imuln=function(d){o(typeof d=="number"),o(d<67108864);for(var v=0,w=0;w<this.length;w++){var c=(this.words[w]|0)*d,p=(c&67108863)+(v&67108863);v>>=26,v+=c/67108864|0,v+=p>>>26,this.words[w]=p&67108863}return v!==0&&(this.words[w]=v,this.length++),this},l.prototype.muln=function(d){return this.clone().imuln(d)},l.prototype.sqr=function(){return this.mul(this)},l.prototype.isqr=function(){return this.imul(this.clone())},l.prototype.pow=function(d){var v=P(d);if(v.length===0)return new l(1);for(var w=this,c=0;c<v.length&&v[c]===0;c++,w=w.sqr());if(++c<v.length)for(var p=w.sqr();c<v.length;c++,p=p.sqr())v[c]!==0&&(w=w.mul(p));return w},l.prototype.iushln=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=67108863>>>26-v<<26-v,p;if(v!==0){var x=0;for(p=0;p<this.length;p++){var S=this.words[p]&c,b=(this.words[p]|0)-S<<v;this.words[p]=b|x,x=S>>>26-v}x&&(this.words[p]=x,this.length++)}if(w!==0){for(p=this.length-1;p>=0;p--)this.words[p+w]=this.words[p];for(p=0;p<w;p++)this.words[p]=0;this.length+=w}return this.strip()},l.prototype.ishln=function(d){return o(this.negative===0),this.iushln(d)},l.prototype.iushrn=function(d,v,w){o(typeof d=="number"&&d>=0);var c;v?c=(v-v%26)/26:c=0;var p=d%26,x=Math.min((d-p)/26,this.length),S=67108863^67108863>>>p<<p,b=w;if(c-=x,c=Math.max(0,c),b){for(var h=0;h<x;h++)b.words[h]=this.words[h];b.length=x}if(x!==0)if(this.length>x)for(this.length-=x,h=0;h<this.length;h++)this.words[h]=this.words[h+x];else this.words[0]=0,this.length=1;var T=0;for(h=this.length-1;h>=0&&(T!==0||h>=c);h--){var M=this.words[h]|0;this.words[h]=T<<26-p|M>>>p,T=M&S}return b&&T!==0&&(b.words[b.length++]=T),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},l.prototype.ishrn=function(d,v,w){return o(this.negative===0),this.iushrn(d,v,w)},l.prototype.shln=function(d){return this.clone().ishln(d)},l.prototype.ushln=function(d){return this.clone().iushln(d)},l.prototype.shrn=function(d){return this.clone().ishrn(d)},l.prototype.ushrn=function(d){return this.clone().iushrn(d)},l.prototype.testn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return!1;var p=this.words[w];return!!(p&c)},l.prototype.imaskn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26;if(o(this.negative===0,"imaskn works only with positive numbers"),this.length<=w)return this;if(v!==0&&w++,this.length=Math.min(w,this.length),v!==0){var c=67108863^67108863>>>v<<v;this.words[this.length-1]&=c}return this.strip()},l.prototype.maskn=function(d){return this.clone().imaskn(d)},l.prototype.iaddn=function(d){return o(typeof d=="number"),o(d<67108864),d<0?this.isubn(-d):this.negative!==0?this.length===1&&(this.words[0]|0)<d?(this.words[0]=d-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(d),this.negative=1,this):this._iaddn(d)},l.prototype._iaddn=function(d){this.words[0]+=d;for(var v=0;v<this.length&&this.words[v]>=67108864;v++)this.words[v]-=67108864,v===this.length-1?this.words[v+1]=1:this.words[v+1]++;return this.length=Math.max(this.length,v+1),this},l.prototype.isubn=function(d){if(o(typeof d=="number"),o(d<67108864),d<0)return this.iaddn(-d);if(this.negative!==0)return this.negative=0,this.iaddn(d),this.negative=1,this;if(this.words[0]-=d,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var v=0;v<this.length&&this.words[v]<0;v++)this.words[v]+=67108864,this.words[v+1]-=1;return this.strip()},l.prototype.addn=function(d){return this.clone().iaddn(d)},l.prototype.subn=function(d){return this.clone().isubn(d)},l.prototype.iabs=function(){return this.negative=0,this},l.prototype.abs=function(){return this.clone().iabs()},l.prototype._ishlnsubmul=function(d,v,w){var c=d.length+w,p;this._expand(c);var x,S=0;for(p=0;p<d.length;p++){x=(this.words[p+w]|0)+S;var b=(d.words[p]|0)*v;x-=b&67108863,S=(x>>26)-(b/67108864|0),this.words[p+w]=x&67108863}for(;p<this.length-w;p++)x=(this.words[p+w]|0)+S,S=x>>26,this.words[p+w]=x&67108863;if(S===0)return this.strip();for(o(S===-1),S=0,p=0;p<this.length;p++)x=-(this.words[p]|0)+S,S=x>>26,this.words[p]=x&67108863;return this.negative=1,this.strip()},l.prototype._wordDiv=function(d,v){var w=this.length-d.length,c=this.clone(),p=d,x=p.words[p.length-1]|0,S=this._countBits(x);w=26-S,w!==0&&(p=p.ushln(w),c.iushln(w),x=p.words[p.length-1]|0);var b=c.length-p.length,h;if(v!=="mod"){h=new l(null),h.length=b+1,h.words=new Array(h.length);for(var T=0;T<h.length;T++)h.words[T]=0}var M=c.clone()._ishlnsubmul(p,1,b);M.negative===0&&(c=M,h&&(h.words[b]=1));for(var O=b-1;O>=0;O--){var V=(c.words[p.length+O]|0)*67108864+(c.words[p.length+O-1]|0);for(V=Math.min(V/x|0,67108863),c._ishlnsubmul(p,V,O);c.negative!==0;)V--,c.negative=0,c._ishlnsubmul(p,1,O),c.isZero()||(c.negative^=1);h&&(h.words[O]=V)}return h&&h.strip(),c.strip(),v!=="div"&&w!==0&&c.iushrn(w),{div:h||null,mod:c}},l.prototype.divmod=function(d,v,w){if(o(!d.isZero()),this.isZero())return{div:new l(0),mod:new l(0)};var c,p,x;return this.negative!==0&&d.negative===0?(x=this.neg().divmod(d,v),v!=="mod"&&(c=x.div.neg()),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.iadd(d)),{div:c,mod:p}):this.negative===0&&d.negative!==0?(x=this.divmod(d.neg(),v),v!=="mod"&&(c=x.div.neg()),{div:c,mod:x.mod}):this.negative&d.negative?(x=this.neg().divmod(d.neg(),v),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.isub(d)),{div:x.div,mod:p}):d.length>this.length||this.cmp(d)<0?{div:new l(0),mod:this}:d.length===1?v==="div"?{div:this.divn(d.words[0]),mod:null}:v==="mod"?{div:null,mod:new l(this.modn(d.words[0]))}:{div:this.divn(d.words[0]),mod:new l(this.modn(d.words[0]))}:this._wordDiv(d,v)},l.prototype.div=function(d){return this.divmod(d,"div",!1).div},l.prototype.mod=function(d){return this.divmod(d,"mod",!1).mod},l.prototype.umod=function(d){return this.divmod(d,"mod",!0).mod},l.prototype.divRound=function(d){var v=this.divmod(d);if(v.mod.isZero())return v.div;var w=v.div.negative!==0?v.mod.isub(d):v.mod,c=d.ushrn(1),p=d.andln(1),x=w.cmp(c);return x<0||p===1&&x===0?v.div:v.div.negative!==0?v.div.isubn(1):v.div.iaddn(1)},l.prototype.modn=function(d){o(d<=67108863);for(var v=(1<<26)%d,w=0,c=this.length-1;c>=0;c--)w=(v*w+(this.words[c]|0))%d;return w},l.prototype.idivn=function(d){o(d<=67108863);for(var v=0,w=this.length-1;w>=0;w--){var c=(this.words[w]|0)+v*67108864;this.words[w]=c/d|0,v=c%d}return this.strip()},l.prototype.divn=function(d){return this.clone().idivn(d)},l.prototype.egcd=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=new l(0),S=new l(1),b=0;v.isEven()&&w.isEven();)v.iushrn(1),w.iushrn(1),++b;for(var h=w.clone(),T=v.clone();!v.isZero();){for(var M=0,O=1;!(v.words[0]&O)&&M<26;++M,O<<=1);if(M>0)for(v.iushrn(M);M-- >0;)(c.isOdd()||p.isOdd())&&(c.iadd(h),p.isub(T)),c.iushrn(1),p.iushrn(1);for(var V=0,ee=1;!(w.words[0]&ee)&&V<26;++V,ee<<=1);if(V>0)for(w.iushrn(V);V-- >0;)(x.isOdd()||S.isOdd())&&(x.iadd(h),S.isub(T)),x.iushrn(1),S.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(x),p.isub(S)):(w.isub(v),x.isub(c),S.isub(p))}return{a:x,b:S,gcd:w.iushln(b)}},l.prototype._invmp=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=w.clone();v.cmpn(1)>0&&w.cmpn(1)>0;){for(var S=0,b=1;!(v.words[0]&b)&&S<26;++S,b<<=1);if(S>0)for(v.iushrn(S);S-- >0;)c.isOdd()&&c.iadd(x),c.iushrn(1);for(var h=0,T=1;!(w.words[0]&T)&&h<26;++h,T<<=1);if(h>0)for(w.iushrn(h);h-- >0;)p.isOdd()&&p.iadd(x),p.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(p)):(w.isub(v),p.isub(c))}var M;return v.cmpn(1)===0?M=c:M=p,M.cmpn(0)<0&&M.iadd(d),M},l.prototype.gcd=function(d){if(this.isZero())return d.abs();if(d.isZero())return this.abs();var v=this.clone(),w=d.clone();v.negative=0,w.negative=0;for(var c=0;v.isEven()&&w.isEven();c++)v.iushrn(1),w.iushrn(1);do{for(;v.isEven();)v.iushrn(1);for(;w.isEven();)w.iushrn(1);var p=v.cmp(w);if(p<0){var x=v;v=w,w=x}else if(p===0||w.cmpn(1)===0)break;v.isub(w)}while(!0);return w.iushln(c)},l.prototype.invm=function(d){return this.egcd(d).a.umod(d)},l.prototype.isEven=function(){return(this.words[0]&1)===0},l.prototype.isOdd=function(){return(this.words[0]&1)===1},l.prototype.andln=function(d){return this.words[0]&d},l.prototype.bincn=function(d){o(typeof d=="number");var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return this._expand(w+1),this.words[w]|=c,this;for(var p=c,x=w;p!==0&&x<this.length;x++){var S=this.words[x]|0;S+=p,p=S>>>26,S&=67108863,this.words[x]=S}return p!==0&&(this.words[x]=p,this.length++),this},l.prototype.isZero=function(){return this.length===1&&this.words[0]===0},l.prototype.cmpn=function(d){var v=d<0;if(this.negative!==0&&!v)return-1;if(this.negative===0&&v)return 1;this.strip();var w;if(this.length>1)w=1;else{v&&(d=-d),o(d<=67108863,"Number is too big");var c=this.words[0]|0;w=c===d?0:c<d?-1:1}return this.negative!==0?-w|0:w},l.prototype.cmp=function(d){if(this.negative!==0&&d.negative===0)return-1;if(this.negative===0&&d.negative!==0)return 1;var v=this.ucmp(d);return this.negative!==0?-v|0:v},l.prototype.ucmp=function(d){if(this.length>d.length)return 1;if(this.length<d.length)return-1;for(var v=0,w=this.length-1;w>=0;w--){var c=this.words[w]|0,p=d.words[w]|0;if(c!==p){c<p?v=-1:c>p&&(v=1);break}}return v},l.prototype.gtn=function(d){return this.cmpn(d)===1},l.prototype.gt=function(d){return this.cmp(d)===1},l.prototype.gten=function(d){return this.cmpn(d)>=0},l.prototype.gte=function(d){return this.cmp(d)>=0},l.prototype.ltn=function(d){return this.cmpn(d)===-1},l.prototype.lt=function(d){return this.cmp(d)===-1},l.prototype.lten=function(d){return this.cmpn(d)<=0},l.prototype.lte=function(d){return this.cmp(d)<=0},l.prototype.eqn=function(d){return this.cmpn(d)===0},l.prototype.eq=function(d){return this.cmp(d)===0},l.red=function(d){return new he(d)},l.prototype.toRed=function(d){return o(!this.red,"Already a number in reduction context"),o(this.negative===0,"red works only with positives"),d.convertTo(this)._forceRed(d)},l.prototype.fromRed=function(){return o(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},l.prototype._forceRed=function(d){return this.red=d,this},l.prototype.forceRed=function(d){return o(!this.red,"Already a number in reduction context"),this._forceRed(d)},l.prototype.redAdd=function(d){return o(this.red,"redAdd works only with red numbers"),this.red.add(this,d)},l.prototype.redIAdd=function(d){return o(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,d)},l.prototype.redSub=function(d){return o(this.red,"redSub works only with red numbers"),this.red.sub(this,d)},l.prototype.redISub=function(d){return o(this.red,"redISub works only with red numbers"),this.red.isub(this,d)},l.prototype.redShl=function(d){return o(this.red,"redShl works only with red numbers"),this.red.shl(this,d)},l.prototype.redMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.mul(this,d)},l.prototype.redIMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.imul(this,d)},l.prototype.redSqr=function(){return o(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},l.prototype.redISqr=function(){return o(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},l.prototype.redSqrt=function(){return o(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},l.prototype.redInvm=function(){return o(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},l.prototype.redNeg=function(){return o(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},l.prototype.redPow=function(d){return o(this.red&&!d.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,d)};var Y={k256:null,p224:null,p192:null,p25519:null};function J(L,d){this.name=L,this.p=new l(d,16),this.n=this.p.bitLength(),this.k=new l(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}J.prototype._tmp=function(){var d=new l(null);return d.words=new Array(Math.ceil(this.n/13)),d},J.prototype.ireduce=function(d){var v=d,w;do this.split(v,this.tmp),v=this.imulK(v),v=v.iadd(this.tmp),w=v.bitLength();while(w>this.n);var c=w<this.n?-1:v.ucmp(this.p);return c===0?(v.words[0]=0,v.length=1):c>0?v.isub(this.p):v.strip!==void 0?v.strip():v._strip(),v},J.prototype.split=function(d,v){d.iushrn(this.n,0,v)},J.prototype.imulK=function(d){return d.imul(this.k)};function ie(){J.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}u(ie,J),ie.prototype.split=function(d,v){for(var w=4194303,c=Math.min(d.length,9),p=0;p<c;p++)v.words[p]=d.words[p];if(v.length=c,d.length<=9){d.words[0]=0,d.length=1;return}var x=d.words[9];for(v.words[v.length++]=x&w,p=10;p<d.length;p++){var S=d.words[p]|0;d.words[p-10]=(S&w)<<4|x>>>22,x=S}x>>>=22,d.words[p-10]=x,x===0&&d.length>10?d.length-=10:d.length-=9},ie.prototype.imulK=function(d){d.words[d.length]=0,d.words[d.length+1]=0,d.length+=2;for(var v=0,w=0;w<d.length;w++){var c=d.words[w]|0;v+=c*977,d.words[w]=v&67108863,v=c*64+(v/67108864|0)}return d.words[d.length-1]===0&&(d.length--,d.words[d.length-1]===0&&d.length--),d};function ue(){J.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}u(ue,J);function Q(){J.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}u(Q,J);function ce(){J.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}u(ce,J),ce.prototype.imulK=function(d){for(var v=0,w=0;w<d.length;w++){var c=(d.words[w]|0)*19+v,p=c&67108863;c>>>=26,d.words[w]=p,v=c}return v!==0&&(d.words[d.length++]=v),d},l._prime=function(d){if(Y[d])return Y[d];var v;if(d==="k256")v=new ie;else if(d==="p224")v=new ue;else if(d==="p192")v=new Q;else if(d==="p25519")v=new ce;else throw new Error("Unknown prime "+d);return Y[d]=v,v};function he(L){if(typeof L=="string"){var d=l._prime(L);this.m=d.p,this.prime=d}else o(L.gtn(1),"modulus must be greater than 1"),this.m=L,this.prime=null}he.prototype._verify1=function(d){o(d.negative===0,"red works only with positives"),o(d.red,"red works only with red numbers")},he.prototype._verify2=function(d,v){o((d.negative|v.negative)===0,"red works only with positives"),o(d.red&&d.red===v.red,"red works only with red numbers")},he.prototype.imod=function(d){return this.prime?this.prime.ireduce(d)._forceRed(this):d.umod(this.m)._forceRed(this)},he.prototype.neg=function(d){return d.isZero()?d.clone():this.m.sub(d)._forceRed(this)},he.prototype.add=function(d,v){this._verify2(d,v);var w=d.add(v);return w.cmp(this.m)>=0&&w.isub(this.m),w._forceRed(this)},he.prototype.iadd=function(d,v){this._verify2(d,v);var w=d.iadd(v);return w.cmp(this.m)>=0&&w.isub(this.m),w},he.prototype.sub=function(d,v){this._verify2(d,v);var w=d.sub(v);return w.cmpn(0)<0&&w.iadd(this.m),w._forceRed(this)},he.prototype.isub=function(d,v){this._verify2(d,v);var w=d.isub(v);return w.cmpn(0)<0&&w.iadd(this.m),w},he.prototype.shl=function(d,v){return this._verify1(d),this.imod(d.ushln(v))},he.prototype.imul=function(d,v){return this._verify2(d,v),this.imod(d.imul(v))},he.prototype.mul=function(d,v){return this._verify2(d,v),this.imod(d.mul(v))},he.prototype.isqr=function(d){return this.imul(d,d.clone())},he.prototype.sqr=function(d){return this.mul(d,d)},he.prototype.sqrt=function(d){if(d.isZero())return d.clone();var v=this.m.andln(3);if(o(v%2===1),v===3){var w=this.m.add(new l(1)).iushrn(2);return this.pow(d,w)}for(var c=this.m.subn(1),p=0;!c.isZero()&&c.andln(1)===0;)p++,c.iushrn(1);o(!c.isZero());var x=new l(1).toRed(this),S=x.redNeg(),b=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new l(2*h*h).toRed(this);this.pow(h,b).cmp(S)!==0;)h.redIAdd(S);for(var T=this.pow(h,c),M=this.pow(d,c.addn(1).iushrn(1)),O=this.pow(d,c),V=p;O.cmp(x)!==0;){for(var ee=O,Z=0;ee.cmp(x)!==0;Z++)ee=ee.redSqr();o(Z<V);var U=this.pow(T,new l(1).iushln(V-Z-1));M=M.redMul(U),T=U.redSqr(),O=O.redMul(T),V=Z}return M},he.prototype.invm=function(d){var v=d._invmp(this.m);return v.negative!==0?(v.negative=0,this.imod(v).redNeg()):this.imod(v)},he.prototype.pow=function(d,v){if(v.isZero())return new l(1).toRed(this);if(v.cmpn(1)===0)return d.clone();var w=4,c=new Array(1<<w);c[0]=new l(1).toRed(this),c[1]=d;for(var p=2;p<c.length;p++)c[p]=this.mul(c[p-1],d);var x=c[0],S=0,b=0,h=v.bitLength()%26;for(h===0&&(h=26),p=v.length-1;p>=0;p--){for(var T=v.words[p],M=h-1;M>=0;M--){var O=T>>M&1;if(x!==c[0]&&(x=this.sqr(x)),O===0&&S===0){b=0;continue}S<<=1,S|=O,b++,!(b!==w&&(p!==0||M!==0))&&(x=this.mul(x,c[S]),b=0,S=0)}h=26}return x},he.prototype.convertTo=function(d){var v=d.umod(this.m);return v===d?v.clone():v},he.prototype.convertFrom=function(d){var v=d.clone();return v.red=null,v},l.mont=function(d){return new ke(d)};function ke(L){he.call(this,L),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new l(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}u(ke,he),ke.prototype.convertTo=function(d){return this.imod(d.ushln(this.shift))},ke.prototype.convertFrom=function(d){var v=this.imod(d.mul(this.rinv));return v.red=null,v},ke.prototype.imul=function(d,v){if(d.isZero()||v.isZero())return d.words[0]=0,d.length=1,d;var w=d.imul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.mul=function(d,v){if(d.isZero()||v.isZero())return new l(0)._forceRed(this);var w=d.mul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.invm=function(d){var v=this.imod(d._invmp(this.m).mul(this.r2));return v._forceRed(this)}})(t,commonjsGlobal$1)}(bn$2);var bnExports$2=bn$2.exports,api={},vmBrowserify={},hasRequiredVmBrowserify;function requireVmBrowserify(){return hasRequiredVmBrowserify||(hasRequiredVmBrowserify=1,function(exports){var indexOf=function(t,e){if(t.indexOf)return t.indexOf(e);for(var n=0;n<t.length;n++)if(t[n]===e)return n;return-1},Object_keys=function(t){if(Object.keys)return Object.keys(t);var e=[];for(var n in t)e.push(n);return e},forEach=function(t,e){if(t.forEach)return t.forEach(e);for(var n=0;n<t.length;n++)e(t[n],n,t)},defineProp=function(){try{return Object.defineProperty({},"_",{}),function(t,e,n){Object.defineProperty(t,e,{writable:!0,enumerable:!1,configurable:!0,value:n})}}catch{return function(e,n,o){e[n]=o}}}(),globals=["Array","Boolean","Date","Error","EvalError","Function","Infinity","JSON","Math","NaN","Number","Object","RangeError","ReferenceError","RegExp","String","SyntaxError","TypeError","URIError","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","eval","isFinite","isNaN","parseFloat","parseInt","undefined","unescape"];function Context(){}Context.prototype={};var Script=exports.Script=function(e){if(!(this instanceof Script))return new Script(e);this.code=e};Script.prototype.runInContext=function(t){if(!(t instanceof Context))throw new TypeError("needs a 'context' argument.");var e=document.createElement("iframe");e.style||(e.style={}),e.style.display="none",document.body.appendChild(e);var n=e.contentWindow,o=n.eval,u=n.execScript;!o&&u&&(u.call(n,"null"),o=n.eval),forEach(Object_keys(t),function(y){n[y]=t[y]}),forEach(globals,function(y){t[y]&&(n[y]=t[y])});var l=Object_keys(n),m=o.call(n,this.code);return forEach(Object_keys(n),function(y){(y in t||indexOf(l,y)===-1)&&(t[y]=n[y])}),forEach(globals,function(y){y in t||defineProp(t,y,n[y])}),document.body.removeChild(e),m},Script.prototype.runInThisContext=function(){return eval(this.code)},Script.prototype.runInNewContext=function(t){var e=Script.createContext(t),n=this.runInContext(e);return t&&forEach(Object_keys(e),function(o){t[o]=e[o]}),n},forEach(Object_keys(Script.prototype),function(t){exports[t]=Script[t]=function(e){var n=Script(e);return n[t].apply(n,[].slice.call(arguments,1))}}),exports.isContext=function(t){return t instanceof Context},exports.createScript=function(t){return exports.Script(t)},exports.createContext=Script.createContext=function(t){var e=new Context;return typeof t=="object"&&forEach(Object_keys(t),function(n){e[n]=t[n]}),e}}(vmBrowserify)),vmBrowserify}var hasRequiredApi;function requireApi(){return hasRequiredApi||(hasRequiredApi=1,function(t){var e=requireAsn1(),n=inherits_browserExports,o=t;o.define=function(m,y){return new u(m,y)};function u(l,m){this.name=l,this.body=m,this.decoders={},this.encoders={}}u.prototype._createNamed=function(m){var y;try{y=requireVmBrowserify().runInThisContext("(function "+this.name+`(entity) {
  this._initNamed(entity);
})`)}catch{y=function(C){this._initNamed(C)}}return n(y,m),y.prototype._initNamed=function(C){m.call(this,C)},new y(this)},u.prototype._getDecoder=function(m){return m=m||"der",this.decoders.hasOwnProperty(m)||(this.decoders[m]=this._createNamed(e.decoders[m])),this.decoders[m]},u.prototype.decode=function(m,y,E){return this._getDecoder(y).decode(m,E)},u.prototype._getEncoder=function(m){return m=m||"der",this.encoders.hasOwnProperty(m)||(this.encoders[m]=this._createNamed(e.encoders[m])),this.encoders[m]},u.prototype.encode=function(m,y,E){return this._getEncoder(y).encode(m,E)}}(api)),api}var base={},reporter={},inherits=inherits_browserExports;function Reporter(t){this._reporterState={obj:null,path:[],options:t||{},errors:[]}}reporter.Reporter=Reporter,Reporter.prototype.isError=function t(e){return e instanceof ReporterError},Reporter.prototype.save=function t(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},Reporter.prototype.restore=function t(e){var n=this._reporterState;n.obj=e.obj,n.path=n.path.slice(0,e.pathLen)},Reporter.prototype.enterKey=function t(e){return this._reporterState.path.push(e)},Reporter.prototype.exitKey=function t(e){var n=this._reporterState;n.path=n.path.slice(0,e-1)},Reporter.prototype.leaveKey=function t(e,n,o){var u=this._reporterState;this.exitKey(e),u.obj!==null&&(u.obj[n]=o)},Reporter.prototype.path=function t(){return this._reporterState.path.join("/")},Reporter.prototype.enterObject=function t(){var e=this._reporterState,n=e.obj;return e.obj={},n},Reporter.prototype.leaveObject=function t(e){var n=this._reporterState,o=n.obj;return n.obj=e,o},Reporter.prototype.error=function t(e){var n,o=this._reporterState,u=e instanceof ReporterError;if(u?n=e:n=new ReporterError(o.path.map(function(l){return"["+JSON.stringify(l)+"]"}).join(""),e.message||e,e.stack),!o.options.partial)throw n;return u||o.errors.push(n),n},Reporter.prototype.wrapResult=function t(e){var n=this._reporterState;return n.options.partial?{result:this.isError(e)?null:e,errors:n.errors}:e};function ReporterError(t,e){this.path=t,this.rethrow(e)}inherits(ReporterError,Error),ReporterError.prototype.rethrow=function t(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,ReporterError),!this.stack)try{throw new Error(this.message)}catch(n){this.stack=n.stack}return this};var buffer={},hasRequiredBuffer;function requireBuffer(){if(hasRequiredBuffer)return buffer;hasRequiredBuffer=1;var t=inherits_browserExports,e=requireBase().Reporter,n=require$$0$2.Buffer;function o(l,m){if(e.call(this,m),!n.isBuffer(l)){this.error("Input not Buffer");return}this.base=l,this.offset=0,this.length=l.length}t(o,e),buffer.DecoderBuffer=o,o.prototype.save=function(){return{offset:this.offset,reporter:e.prototype.save.call(this)}},o.prototype.restore=function(m){var y=new o(this.base);return y.offset=m.offset,y.length=this.offset,this.offset=m.offset,e.prototype.restore.call(this,m.reporter),y},o.prototype.isEmpty=function(){return this.offset===this.length},o.prototype.readUInt8=function(m){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(m||"DecoderBuffer overrun")},o.prototype.skip=function(m,y){if(!(this.offset+m<=this.length))return this.error(y||"DecoderBuffer overrun");var E=new o(this.base);return E._reporterState=this._reporterState,E.offset=this.offset,E.length=this.offset+m,this.offset+=m,E},o.prototype.raw=function(m){return this.base.slice(m?m.offset:this.offset,this.length)};function u(l,m){if(Array.isArray(l))this.length=0,this.value=l.map(function(y){return y instanceof u||(y=new u(y,m)),this.length+=y.length,y},this);else if(typeof l=="number"){if(!(0<=l&&l<=255))return m.error("non-byte EncoderBuffer value");this.value=l,this.length=1}else if(typeof l=="string")this.value=l,this.length=n.byteLength(l);else if(n.isBuffer(l))this.value=l,this.length=l.length;else return m.error("Unsupported type: "+typeof l)}return buffer.EncoderBuffer=u,u.prototype.join=function(m,y){return m||(m=new n(this.length)),y||(y=0),this.length===0||(Array.isArray(this.value)?this.value.forEach(function(E){E.join(m,y),y+=E.length}):(typeof this.value=="number"?m[y]=this.value:typeof this.value=="string"?m.write(this.value,y):n.isBuffer(this.value)&&this.value.copy(m,y),y+=this.length)),m},buffer}var node,hasRequiredNode;function requireNode(){if(hasRequiredNode)return node;hasRequiredNode=1;var t=requireBase().Reporter,e=requireBase().EncoderBuffer,n=requireBase().DecoderBuffer,o=minimalisticAssert,u=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],l=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(u),m=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function y(C,k){var A={};this._baseState=A,A.enc=C,A.parent=k||null,A.children=null,A.tag=null,A.args=null,A.reverseArgs=null,A.choice=null,A.optional=!1,A.any=!1,A.obj=!1,A.use=null,A.useDecoder=null,A.key=null,A.default=null,A.explicit=null,A.implicit=null,A.contains=null,A.parent||(A.children=[],this._wrap())}node=y;var E=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];return y.prototype.clone=function(){var k=this._baseState,A={};E.forEach(function(P){A[P]=k[P]});var D=new this.constructor(A.parent);return D._baseState=A,D},y.prototype._wrap=function(){var k=this._baseState;l.forEach(function(A){this[A]=function(){var P=new this.constructor(this);return k.children.push(P),P[A].apply(P,arguments)}},this)},y.prototype._init=function(k){var A=this._baseState;o(A.parent===null),k.call(this),A.children=A.children.filter(function(D){return D._baseState.parent===this},this),o.equal(A.children.length,1,"Root node can have only one child")},y.prototype._useArgs=function(k){var A=this._baseState,D=k.filter(function(P){return P instanceof this.constructor},this);k=k.filter(function(P){return!(P instanceof this.constructor)},this),D.length!==0&&(o(A.children===null),A.children=D,D.forEach(function(P){P._baseState.parent=this},this)),k.length!==0&&(o(A.args===null),A.args=k,A.reverseArgs=k.map(function(P){if(typeof P!="object"||P.constructor!==Object)return P;var R={};return Object.keys(P).forEach(function(B){B==(B|0)&&(B|=0);var F=P[B];R[F]=B}),R}))},m.forEach(function(C){y.prototype[C]=function(){var A=this._baseState;throw new Error(C+" not implemented for encoding: "+A.enc)}}),u.forEach(function(C){y.prototype[C]=function(){var A=this._baseState,D=Array.prototype.slice.call(arguments);return o(A.tag===null),A.tag=C,this._useArgs(D),this}}),y.prototype.use=function(k){o(k);var A=this._baseState;return o(A.use===null),A.use=k,this},y.prototype.optional=function(){var k=this._baseState;return k.optional=!0,this},y.prototype.def=function(k){var A=this._baseState;return o(A.default===null),A.default=k,A.optional=!0,this},y.prototype.explicit=function(k){var A=this._baseState;return o(A.explicit===null&&A.implicit===null),A.explicit=k,this},y.prototype.implicit=function(k){var A=this._baseState;return o(A.explicit===null&&A.implicit===null),A.implicit=k,this},y.prototype.obj=function(){var k=this._baseState,A=Array.prototype.slice.call(arguments);return k.obj=!0,A.length!==0&&this._useArgs(A),this},y.prototype.key=function(k){var A=this._baseState;return o(A.key===null),A.key=k,this},y.prototype.any=function(){var k=this._baseState;return k.any=!0,this},y.prototype.choice=function(k){var A=this._baseState;return o(A.choice===null),A.choice=k,this._useArgs(Object.keys(k).map(function(D){return k[D]})),this},y.prototype.contains=function(k){var A=this._baseState;return o(A.use===null),A.contains=k,this},y.prototype._decode=function(k,A){var D=this._baseState;if(D.parent===null)return k.wrapResult(D.children[0]._decode(k,A));var P=D.default,R=!0,B=null;if(D.key!==null&&(B=k.enterKey(D.key)),D.optional){var F=null;if(D.explicit!==null?F=D.explicit:D.implicit!==null?F=D.implicit:D.tag!==null&&(F=D.tag),F===null&&!D.any){var j=k.save();try{D.choice===null?this._decodeGeneric(D.tag,k,A):this._decodeChoice(k,A),R=!0}catch{R=!1}k.restore(j)}else if(R=this._peekTag(k,F,D.any),k.isError(R))return R}var N;if(D.obj&&R&&(N=k.enterObject()),R){if(D.explicit!==null){var Y=this._decodeTag(k,D.explicit);if(k.isError(Y))return Y;k=Y}var J=k.offset;if(D.use===null&&D.choice===null){if(D.any)var j=k.save();var ie=this._decodeTag(k,D.implicit!==null?D.implicit:D.tag,D.any);if(k.isError(ie))return ie;D.any?P=k.raw(j):k=ie}if(A&&A.track&&D.tag!==null&&A.track(k.path(),J,k.length,"tagged"),A&&A.track&&D.tag!==null&&A.track(k.path(),k.offset,k.length,"content"),D.any?P=P:D.choice===null?P=this._decodeGeneric(D.tag,k,A):P=this._decodeChoice(k,A),k.isError(P))return P;if(!D.any&&D.choice===null&&D.children!==null&&D.children.forEach(function(ce){ce._decode(k,A)}),D.contains&&(D.tag==="octstr"||D.tag==="bitstr")){var ue=new n(P);P=this._getUse(D.contains,k._reporterState.obj)._decode(ue,A)}}return D.obj&&R&&(P=k.leaveObject(N)),D.key!==null&&(P!==null||R===!0)?k.leaveKey(B,D.key,P):B!==null&&k.exitKey(B),P},y.prototype._decodeGeneric=function(k,A,D){var P=this._baseState;return k==="seq"||k==="set"?null:k==="seqof"||k==="setof"?this._decodeList(A,k,P.args[0],D):/str$/.test(k)?this._decodeStr(A,k,D):k==="objid"&&P.args?this._decodeObjid(A,P.args[0],P.args[1],D):k==="objid"?this._decodeObjid(A,null,null,D):k==="gentime"||k==="utctime"?this._decodeTime(A,k,D):k==="null_"?this._decodeNull(A,D):k==="bool"?this._decodeBool(A,D):k==="objDesc"?this._decodeStr(A,k,D):k==="int"||k==="enum"?this._decodeInt(A,P.args&&P.args[0],D):P.use!==null?this._getUse(P.use,A._reporterState.obj)._decode(A,D):A.error("unknown tag: "+k)},y.prototype._getUse=function(k,A){var D=this._baseState;return D.useDecoder=this._use(k,A),o(D.useDecoder._baseState.parent===null),D.useDecoder=D.useDecoder._baseState.children[0],D.implicit!==D.useDecoder._baseState.implicit&&(D.useDecoder=D.useDecoder.clone(),D.useDecoder._baseState.implicit=D.implicit),D.useDecoder},y.prototype._decodeChoice=function(k,A){var D=this._baseState,P=null,R=!1;return Object.keys(D.choice).some(function(B){var F=k.save(),j=D.choice[B];try{var N=j._decode(k,A);if(k.isError(N))return!1;P={type:B,value:N},R=!0}catch{return k.restore(F),!1}return!0},this),R?P:k.error("Choice not matched")},y.prototype._createEncoderBuffer=function(k){return new e(k,this.reporter)},y.prototype._encode=function(k,A,D){var P=this._baseState;if(!(P.default!==null&&P.default===k)){var R=this._encodeValue(k,A,D);if(R!==void 0&&!this._skipDefault(R,A,D))return R}},y.prototype._encodeValue=function(k,A,D){var P=this._baseState;if(P.parent===null)return P.children[0]._encode(k,A||new t);var j=null;if(this.reporter=A,P.optional&&k===void 0)if(P.default!==null)k=P.default;else return;var R=null,B=!1;if(P.any)j=this._createEncoderBuffer(k);else if(P.choice)j=this._encodeChoice(k,A);else if(P.contains)R=this._getUse(P.contains,D)._encode(k,A),B=!0;else if(P.children)R=P.children.map(function(J){if(J._baseState.tag==="null_")return J._encode(null,A,k);if(J._baseState.key===null)return A.error("Child should have a key");var ie=A.enterKey(J._baseState.key);if(typeof k!="object")return A.error("Child expected, but input is not object");var ue=J._encode(k[J._baseState.key],A,k);return A.leaveKey(ie),ue},this).filter(function(J){return J}),R=this._createEncoderBuffer(R);else if(P.tag==="seqof"||P.tag==="setof"){if(!(P.args&&P.args.length===1))return A.error("Too many args for : "+P.tag);if(!Array.isArray(k))return A.error("seqof/setof, but data is not Array");var F=this.clone();F._baseState.implicit=null,R=this._createEncoderBuffer(k.map(function(J){var ie=this._baseState;return this._getUse(ie.args[0],k)._encode(J,A)},F))}else P.use!==null?j=this._getUse(P.use,D)._encode(k,A):(R=this._encodePrimitive(P.tag,k),B=!0);var j;if(!P.any&&P.choice===null){var N=P.implicit!==null?P.implicit:P.tag,Y=P.implicit===null?"universal":"context";N===null?P.use===null&&A.error("Tag could be omitted only for .use()"):P.use===null&&(j=this._encodeComposite(N,B,Y,R))}return P.explicit!==null&&(j=this._encodeComposite(P.explicit,!1,"context",j)),j},y.prototype._encodeChoice=function(k,A){var D=this._baseState,P=D.choice[k.type];return P||o(!1,k.type+" not found in "+JSON.stringify(Object.keys(D.choice))),P._encode(k.value,A)},y.prototype._encodePrimitive=function(k,A){var D=this._baseState;if(/str$/.test(k))return this._encodeStr(A,k);if(k==="objid"&&D.args)return this._encodeObjid(A,D.reverseArgs[0],D.args[1]);if(k==="objid")return this._encodeObjid(A,null,null);if(k==="gentime"||k==="utctime")return this._encodeTime(A,k);if(k==="null_")return this._encodeNull();if(k==="int"||k==="enum")return this._encodeInt(A,D.args&&D.reverseArgs[0]);if(k==="bool")return this._encodeBool(A);if(k==="objDesc")return this._encodeStr(A,k);throw new Error("Unsupported tag: "+k)},y.prototype._isNumstr=function(k){return/^[0-9 ]*$/.test(k)},y.prototype._isPrintstr=function(k){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(k)},node}var hasRequiredBase;function requireBase(){return hasRequiredBase||(hasRequiredBase=1,function(t){var e=t;e.Reporter=reporter.Reporter,e.DecoderBuffer=requireBuffer().DecoderBuffer,e.EncoderBuffer=requireBuffer().EncoderBuffer,e.Node=requireNode()}(base)),base}var constants$1={},der={},hasRequiredDer$2;function requireDer$2(){return hasRequiredDer$2||(hasRequiredDer$2=1,function(t){var e=requireConstants$1();t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=e._reverse(t.tagClass),t.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},t.tagByName=e._reverse(t.tag)}(der)),der}var hasRequiredConstants$1;function requireConstants$1(){return hasRequiredConstants$1||(hasRequiredConstants$1=1,function(t){var e=t;e._reverse=function(o){var u={};return Object.keys(o).forEach(function(l){(l|0)==l&&(l=l|0);var m=o[l];u[m]=l}),u},e.der=requireDer$2()}(constants$1)),constants$1}var decoders={},der_1$1,hasRequiredDer$1;function requireDer$1(){if(hasRequiredDer$1)return der_1$1;hasRequiredDer$1=1;var t=inherits_browserExports,e=requireAsn1(),n=e.base,o=e.bignum,u=e.constants.der;function l(C){this.enc="der",this.name=C.name,this.entity=C,this.tree=new m,this.tree._init(C.body)}der_1$1=l,l.prototype.decode=function(k,A){return k instanceof n.DecoderBuffer||(k=new n.DecoderBuffer(k,A)),this.tree._decode(k,A)};function m(C){n.Node.call(this,"der",C)}t(m,n.Node),m.prototype._peekTag=function(k,A,D){if(k.isEmpty())return!1;var P=k.save(),R=y(k,'Failed to peek tag: "'+A+'"');return k.isError(R)?R:(k.restore(P),R.tag===A||R.tagStr===A||R.tagStr+"of"===A||D)},m.prototype._decodeTag=function(k,A,D){var P=y(k,'Failed to decode tag of "'+A+'"');if(k.isError(P))return P;var R=E(k,P.primitive,'Failed to get length of "'+A+'"');if(k.isError(R))return R;if(!D&&P.tag!==A&&P.tagStr!==A&&P.tagStr+"of"!==A)return k.error('Failed to match tag: "'+A+'"');if(P.primitive||R!==null)return k.skip(R,'Failed to match body of: "'+A+'"');var B=k.save(),F=this._skipUntilEnd(k,'Failed to skip indefinite length body: "'+this.tag+'"');return k.isError(F)?F:(R=k.offset-B.offset,k.restore(B),k.skip(R,'Failed to match body of: "'+A+'"'))},m.prototype._skipUntilEnd=function(k,A){for(;;){var D=y(k,A);if(k.isError(D))return D;var P=E(k,D.primitive,A);if(k.isError(P))return P;var R;if(D.primitive||P!==null?R=k.skip(P):R=this._skipUntilEnd(k,A),k.isError(R))return R;if(D.tagStr==="end")break}},m.prototype._decodeList=function(k,A,D,P){for(var R=[];!k.isEmpty();){var B=this._peekTag(k,"end");if(k.isError(B))return B;var F=D.decode(k,"der",P);if(k.isError(F)&&B)break;R.push(F)}return R},m.prototype._decodeStr=function(k,A){if(A==="bitstr"){var D=k.readUInt8();return k.isError(D)?D:{unused:D,data:k.raw()}}else if(A==="bmpstr"){var P=k.raw();if(P.length%2===1)return k.error("Decoding of string type: bmpstr length mismatch");for(var R="",B=0;B<P.length/2;B++)R+=String.fromCharCode(P.readUInt16BE(B*2));return R}else if(A==="numstr"){var F=k.raw().toString("ascii");return this._isNumstr(F)?F:k.error("Decoding of string type: numstr unsupported characters")}else{if(A==="octstr")return k.raw();if(A==="objDesc")return k.raw();if(A==="printstr"){var j=k.raw().toString("ascii");return this._isPrintstr(j)?j:k.error("Decoding of string type: printstr unsupported characters")}else return/str$/.test(A)?k.raw().toString():k.error("Decoding of string type: "+A+" unsupported")}},m.prototype._decodeObjid=function(k,A,D){for(var P,R=[],B=0;!k.isEmpty();){var F=k.readUInt8();B<<=7,B|=F&127,F&128||(R.push(B),B=0)}F&128&&R.push(B);var j=R[0]/40|0,N=R[0]%40;if(D?P=R:P=[j,N].concat(R.slice(1)),A){var Y=A[P.join(" ")];Y===void 0&&(Y=A[P.join(".")]),Y!==void 0&&(P=Y)}return P},m.prototype._decodeTime=function(k,A){var D=k.raw().toString();if(A==="gentime")var P=D.slice(0,4)|0,R=D.slice(4,6)|0,B=D.slice(6,8)|0,F=D.slice(8,10)|0,j=D.slice(10,12)|0,N=D.slice(12,14)|0;else if(A==="utctime"){var P=D.slice(0,2)|0,R=D.slice(2,4)|0,B=D.slice(4,6)|0,F=D.slice(6,8)|0,j=D.slice(8,10)|0,N=D.slice(10,12)|0;P<70?P=2e3+P:P=1900+P}else return k.error("Decoding "+A+" time is not supported yet");return Date.UTC(P,R-1,B,F,j,N,0)},m.prototype._decodeNull=function(k){return null},m.prototype._decodeBool=function(k){var A=k.readUInt8();return k.isError(A)?A:A!==0},m.prototype._decodeInt=function(k,A){var D=k.raw(),P=new o(D);return A&&(P=A[P.toString(10)]||P),P},m.prototype._use=function(k,A){return typeof k=="function"&&(k=k(A)),k._getDecoder("der").tree};function y(C,k){var A=C.readUInt8(k);if(C.isError(A))return A;var D=u.tagClass[A>>6],P=(A&32)===0;if((A&31)===31){var R=A;for(A=0;(R&128)===128;){if(R=C.readUInt8(k),C.isError(R))return R;A<<=7,A|=R&127}}else A&=31;var B=u.tag[A];return{cls:D,primitive:P,tag:A,tagStr:B}}function E(C,k,A){var D=C.readUInt8(A);if(C.isError(D))return D;if(!k&&D===128)return null;if(!(D&128))return D;var P=D&127;if(P>4)return C.error("length octect is too long");D=0;for(var R=0;R<P;R++){D<<=8;var B=C.readUInt8(A);if(C.isError(B))return B;D|=B}return D}return der_1$1}var pem$2,hasRequiredPem$2;function requirePem$2(){if(hasRequiredPem$2)return pem$2;hasRequiredPem$2=1;var t=inherits_browserExports,e=require$$0$2.Buffer,n=requireDer$1();function o(u){n.call(this,u),this.enc="pem"}return t(o,n),pem$2=o,o.prototype.decode=function(l,m){for(var y=l.toString().split(/[\r\n]+/g),E=m.label.toUpperCase(),C=/^-----(BEGIN|END) ([^-]+)-----$/,k=-1,A=-1,D=0;D<y.length;D++){var P=y[D].match(C);if(P!==null&&P[2]===E)if(k===-1){if(P[1]!=="BEGIN")break;k=D}else{if(P[1]!=="END")break;A=D;break}}if(k===-1||A===-1)throw new Error("PEM section not found for: "+E);var R=y.slice(k+1,A).join("");R.replace(/[^a-z0-9\+\/=]+/gi,"");var B=new e(R,"base64");return n.prototype.decode.call(this,B,m)},pem$2}var hasRequiredDecoders;function requireDecoders(){return hasRequiredDecoders||(hasRequiredDecoders=1,function(t){var e=t;e.der=requireDer$1(),e.pem=requirePem$2()}(decoders)),decoders}var encoders={},der_1,hasRequiredDer;function requireDer(){if(hasRequiredDer)return der_1;hasRequiredDer=1;var t=inherits_browserExports,e=require$$0$2.Buffer,n=requireAsn1(),o=n.base,u=n.constants.der;function l(C){this.enc="der",this.name=C.name,this.entity=C,this.tree=new m,this.tree._init(C.body)}der_1=l,l.prototype.encode=function(k,A){return this.tree._encode(k,A).join()};function m(C){o.Node.call(this,"der",C)}t(m,o.Node),m.prototype._encodeComposite=function(k,A,D,P){var R=E(k,A,D,this.reporter);if(P.length<128){var j=new e(2);return j[0]=R,j[1]=P.length,this._createEncoderBuffer([j,P])}for(var B=1,F=P.length;F>=256;F>>=8)B++;var j=new e(2+B);j[0]=R,j[1]=128|B;for(var F=1+B,N=P.length;N>0;F--,N>>=8)j[F]=N&255;return this._createEncoderBuffer([j,P])},m.prototype._encodeStr=function(k,A){if(A==="bitstr")return this._createEncoderBuffer([k.unused|0,k.data]);if(A==="bmpstr"){for(var D=new e(k.length*2),P=0;P<k.length;P++)D.writeUInt16BE(k.charCodeAt(P),P*2);return this._createEncoderBuffer(D)}else return A==="numstr"?this._isNumstr(k)?this._createEncoderBuffer(k):this.reporter.error("Encoding of string type: numstr supports only digits and space"):A==="printstr"?this._isPrintstr(k)?this._createEncoderBuffer(k):this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark"):/str$/.test(A)?this._createEncoderBuffer(k):A==="objDesc"?this._createEncoderBuffer(k):this.reporter.error("Encoding of string type: "+A+" unsupported")},m.prototype._encodeObjid=function(k,A,D){if(typeof k=="string"){if(!A)return this.reporter.error("string objid given, but no values map found");if(!A.hasOwnProperty(k))return this.reporter.error("objid not found in values map");k=A[k].split(/[\s\.]+/g);for(var P=0;P<k.length;P++)k[P]|=0}else if(Array.isArray(k)){k=k.slice();for(var P=0;P<k.length;P++)k[P]|=0}if(!Array.isArray(k))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(k));if(!D){if(k[1]>=40)return this.reporter.error("Second objid identifier OOB");k.splice(0,2,k[0]*40+k[1])}for(var R=0,P=0;P<k.length;P++){var B=k[P];for(R++;B>=128;B>>=7)R++}for(var F=new e(R),j=F.length-1,P=k.length-1;P>=0;P--){var B=k[P];for(F[j--]=B&127;(B>>=7)>0;)F[j--]=128|B&127}return this._createEncoderBuffer(F)};function y(C){return C<10?"0"+C:C}m.prototype._encodeTime=function(k,A){var D,P=new Date(k);return A==="gentime"?D=[y(P.getFullYear()),y(P.getUTCMonth()+1),y(P.getUTCDate()),y(P.getUTCHours()),y(P.getUTCMinutes()),y(P.getUTCSeconds()),"Z"].join(""):A==="utctime"?D=[y(P.getFullYear()%100),y(P.getUTCMonth()+1),y(P.getUTCDate()),y(P.getUTCHours()),y(P.getUTCMinutes()),y(P.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+A+" time is not supported yet"),this._encodeStr(D,"octstr")},m.prototype._encodeNull=function(){return this._createEncoderBuffer("")},m.prototype._encodeInt=function(k,A){if(typeof k=="string"){if(!A)return this.reporter.error("String int or enum given, but no values map");if(!A.hasOwnProperty(k))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(k));k=A[k]}if(typeof k!="number"&&!e.isBuffer(k)){var D=k.toArray();!k.sign&&D[0]&128&&D.unshift(0),k=new e(D)}if(e.isBuffer(k)){var P=k.length;k.length===0&&P++;var B=new e(P);return k.copy(B),k.length===0&&(B[0]=0),this._createEncoderBuffer(B)}if(k<128)return this._createEncoderBuffer(k);if(k<256)return this._createEncoderBuffer([0,k]);for(var P=1,R=k;R>=256;R>>=8)P++;for(var B=new Array(P),R=B.length-1;R>=0;R--)B[R]=k&255,k>>=8;return B[0]&128&&B.unshift(0),this._createEncoderBuffer(new e(B))},m.prototype._encodeBool=function(k){return this._createEncoderBuffer(k?255:0)},m.prototype._use=function(k,A){return typeof k=="function"&&(k=k(A)),k._getEncoder("der").tree},m.prototype._skipDefault=function(k,A,D){var P=this._baseState,R;if(P.default===null)return!1;var B=k.join();if(P.defaultBuffer===void 0&&(P.defaultBuffer=this._encodeValue(P.default,A,D).join()),B.length!==P.defaultBuffer.length)return!1;for(R=0;R<B.length;R++)if(B[R]!==P.defaultBuffer[R])return!1;return!0};function E(C,k,A,D){var P;if(C==="seqof"?C="seq":C==="setof"&&(C="set"),u.tagByName.hasOwnProperty(C))P=u.tagByName[C];else if(typeof C=="number"&&(C|0)===C)P=C;else return D.error("Unknown tag: "+C);return P>=31?D.error("Multi-octet tag encoding unsupported"):(k||(P|=32),P|=u.tagClassByName[A||"universal"]<<6,P)}return der_1}var pem$1,hasRequiredPem$1;function requirePem$1(){if(hasRequiredPem$1)return pem$1;hasRequiredPem$1=1;var t=inherits_browserExports,e=requireDer();function n(o){e.call(this,o),this.enc="pem"}return t(n,e),pem$1=n,n.prototype.encode=function(u,l){for(var m=e.prototype.encode.call(this,u),y=m.toString("base64"),E=["-----BEGIN "+l.label+"-----"],C=0;C<y.length;C+=64)E.push(y.slice(C,C+64));return E.push("-----END "+l.label+"-----"),E.join(`
`)},pem$1}var hasRequiredEncoders;function requireEncoders(){return hasRequiredEncoders||(hasRequiredEncoders=1,function(t){var e=t;e.der=requireDer(),e.pem=requirePem$1()}(encoders)),encoders}var hasRequiredAsn1;function requireAsn1(){return hasRequiredAsn1||(hasRequiredAsn1=1,function(t){var e=t;e.bignum=bnExports$2,e.define=requireApi().define,e.base=requireBase(),e.constants=requireConstants$1(),e.decoders=requireDecoders(),e.encoders=requireEncoders()}(asn1$2)),asn1$2}var asn=requireAsn1(),Time=asn.define("Time",function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})}),AttributeTypeValue=asn.define("AttributeTypeValue",function(){this.seq().obj(this.key("type").objid(),this.key("value").any())}),AlgorithmIdentifier$1=asn.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())}),SubjectPublicKeyInfo=asn.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(AlgorithmIdentifier$1),this.key("subjectPublicKey").bitstr())}),RelativeDistinguishedName=asn.define("RelativeDistinguishedName",function(){this.setof(AttributeTypeValue)}),RDNSequence=asn.define("RDNSequence",function(){this.seqof(RelativeDistinguishedName)}),Name=asn.define("Name",function(){this.choice({rdnSequence:this.use(RDNSequence)})}),Validity=asn.define("Validity",function(){this.seq().obj(this.key("notBefore").use(Time),this.key("notAfter").use(Time))}),Extension=asn.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),TBSCertificate=asn.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(AlgorithmIdentifier$1),this.key("issuer").use(Name),this.key("validity").use(Validity),this.key("subject").use(Name),this.key("subjectPublicKeyInfo").use(SubjectPublicKeyInfo),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(Extension).optional())}),X509Certificate=asn.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(TBSCertificate),this.key("signatureAlgorithm").use(AlgorithmIdentifier$1),this.key("signatureValue").bitstr())}),certificate$1=X509Certificate,asn1$1=requireAsn1();asn1$3.certificate=certificate$1;var RSAPrivateKey=asn1$1.define("RSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())});asn1$3.RSAPrivateKey=RSAPrivateKey;var RSAPublicKey=asn1$1.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});asn1$3.RSAPublicKey=RSAPublicKey;var AlgorithmIdentifier=asn1$1.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())}),PublicKey=asn1$1.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(AlgorithmIdentifier),this.key("subjectPublicKey").bitstr())});asn1$3.PublicKey=PublicKey;var PrivateKeyInfo=asn1$1.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(AlgorithmIdentifier),this.key("subjectPrivateKey").octstr())});asn1$3.PrivateKey=PrivateKeyInfo;var EncryptedPrivateKeyInfo=asn1$1.define("EncryptedPrivateKeyInfo",function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())});asn1$3.EncryptedPrivateKey=EncryptedPrivateKeyInfo;var DSAPrivateKey=asn1$1.define("DSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())});asn1$3.DSAPrivateKey=DSAPrivateKey,asn1$3.DSAparam=asn1$1.define("DSAparam",function(){this.int()});var ECParameters=asn1$1.define("ECParameters",function(){this.choice({namedCurve:this.objid()})}),ECPrivateKey=asn1$1.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(ECParameters),this.key("publicKey").optional().explicit(1).bitstr())});asn1$3.ECPrivateKey=ECPrivateKey,asn1$3.signature=asn1$1.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())});const require$$1$2={"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"};var findProc=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,startRegex=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,fullRegex=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,evp=evp_bytestokey,ciphers$1=browser$7,Buffer$7=safeBufferExports$1.Buffer,fixProc$1=function(t,e){var n=t.toString(),o=n.match(findProc),u;if(o){var m="aes"+o[1],y=Buffer$7.from(o[2],"hex"),E=Buffer$7.from(o[3].replace(/[\r\n]/g,""),"base64"),C=evp(e,y.slice(0,8),parseInt(o[1],10)).key,k=[],A=ciphers$1.createDecipheriv(m,C,y);k.push(A.update(E)),k.push(A.final()),u=Buffer$7.concat(k)}else{var l=n.match(fullRegex);u=Buffer$7.from(l[2].replace(/[\r\n]/g,""),"base64")}var D=n.match(startRegex)[1];return{tag:D,data:u}},asn1=asn1$3,aesid=require$$1$2,fixProc=fixProc$1,ciphers=browser$7,compat=browser$9,Buffer$6=safeBufferExports$1.Buffer;function decrypt(t,e){var n=t.algorithm.decrypt.kde.kdeparams.salt,o=parseInt(t.algorithm.decrypt.kde.kdeparams.iters.toString(),10),u=aesid[t.algorithm.decrypt.cipher.algo.join(".")],l=t.algorithm.decrypt.cipher.iv,m=t.subjectPrivateKey,y=parseInt(u.split("-")[1],10)/8,E=compat.pbkdf2Sync(e,n,o,y,"sha1"),C=ciphers.createDecipheriv(u,E,l),k=[];return k.push(C.update(m)),k.push(C.final()),Buffer$6.concat(k)}function parseKeys$2(t){var e;typeof t=="object"&&!Buffer$6.isBuffer(t)&&(e=t.passphrase,t=t.key),typeof t=="string"&&(t=Buffer$6.from(t));var n=fixProc(t,e),o=n.tag,u=n.data,l,m;switch(o){case"CERTIFICATE":m=asn1.certificate.decode(u,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(m||(m=asn1.PublicKey.decode(u,"der")),l=m.algorithm.algorithm.join("."),l){case"1.2.840.113549.1.1.1":return asn1.RSAPublicKey.decode(m.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return m.subjectPrivateKey=m.subjectPublicKey,{type:"ec",data:m};case"1.2.840.10040.4.1":return m.algorithm.params.pub_key=asn1.DSAparam.decode(m.subjectPublicKey.data,"der"),{type:"dsa",data:m.algorithm.params};default:throw new Error("unknown key id "+l)}case"ENCRYPTED PRIVATE KEY":u=asn1.EncryptedPrivateKey.decode(u,"der"),u=decrypt(u,e);case"PRIVATE KEY":switch(m=asn1.PrivateKey.decode(u,"der"),l=m.algorithm.algorithm.join("."),l){case"1.2.840.113549.1.1.1":return asn1.RSAPrivateKey.decode(m.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:m.algorithm.curve,privateKey:asn1.ECPrivateKey.decode(m.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return m.algorithm.params.priv_key=asn1.DSAparam.decode(m.subjectPrivateKey,"der"),{type:"dsa",params:m.algorithm.params};default:throw new Error("unknown key id "+l)}case"RSA PUBLIC KEY":return asn1.RSAPublicKey.decode(u,"der");case"RSA PRIVATE KEY":return asn1.RSAPrivateKey.decode(u,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:asn1.DSAPrivateKey.decode(u,"der")};case"EC PRIVATE KEY":return u=asn1.ECPrivateKey.decode(u,"der"),{curve:u.parameters.value,privateKey:u.privateKey};default:throw new Error("unknown key type "+o)}}parseKeys$2.signature=asn1.signature;var parseAsn1=parseKeys$2;const require$$4$1={"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"};var hasRequiredSign;function requireSign(){if(hasRequiredSign)return sign.exports;hasRequiredSign=1;var t=safeBufferExports$1.Buffer,e=browser$a,n=browserifyRsa,o=requireElliptic().ec,u=bnExports$4,l=parseAsn1,m=require$$4$1,y=1;function E(j,N,Y,J,ie){var ue=l(N);if(ue.curve){if(J!=="ecdsa"&&J!=="ecdsa/rsa")throw new Error("wrong private key type");return C(j,ue)}else if(ue.type==="dsa"){if(J!=="dsa")throw new Error("wrong private key type");return k(j,ue,Y)}if(J!=="rsa"&&J!=="ecdsa/rsa")throw new Error("wrong private key type");if(N.padding!==void 0&&N.padding!==y)throw new Error("illegal or unsupported padding mode");j=t.concat([ie,j]);for(var Q=ue.modulus.byteLength(),ce=[0,1];j.length+ce.length+1<Q;)ce.push(255);ce.push(0);for(var he=-1;++he<j.length;)ce.push(j[he]);var ke=n(ce,ue);return ke}function C(j,N){var Y=m[N.curve.join(".")];if(!Y)throw new Error("unknown curve "+N.curve.join("."));var J=new o(Y),ie=J.keyFromPrivate(N.privateKey),ue=ie.sign(j);return t.from(ue.toDER())}function k(j,N,Y){for(var J=N.params.priv_key,ie=N.params.p,ue=N.params.q,Q=N.params.g,ce=new u(0),he,ke=P(j,ue).mod(ue),L=!1,d=D(J,ue,j,Y);L===!1;)he=B(ue,d,Y),ce=F(Q,he,ie,ue),L=he.invm(ue).imul(ke.add(J.mul(ce))).mod(ue),L.cmpn(0)===0&&(L=!1,ce=new u(0));return A(ce,L)}function A(j,N){j=j.toArray(),N=N.toArray(),j[0]&128&&(j=[0].concat(j)),N[0]&128&&(N=[0].concat(N));var Y=j.length+N.length+4,J=[48,Y,2,j.length];return J=J.concat(j,[2,N.length],N),t.from(J)}function D(j,N,Y,J){if(j=t.from(j.toArray()),j.length<N.byteLength()){var ie=t.alloc(N.byteLength()-j.length);j=t.concat([ie,j])}var ue=Y.length,Q=R(Y,N),ce=t.alloc(ue);ce.fill(1);var he=t.alloc(ue);return he=e(J,he).update(ce).update(t.from([0])).update(j).update(Q).digest(),ce=e(J,he).update(ce).digest(),he=e(J,he).update(ce).update(t.from([1])).update(j).update(Q).digest(),ce=e(J,he).update(ce).digest(),{k:he,v:ce}}function P(j,N){var Y=new u(j),J=(j.length<<3)-N.bitLength();return J>0&&Y.ishrn(J),Y}function R(j,N){j=P(j,N),j=j.mod(N);var Y=t.from(j.toArray());if(Y.length<N.byteLength()){var J=t.alloc(N.byteLength()-Y.length);Y=t.concat([J,Y])}return Y}function B(j,N,Y){var J,ie;do{for(J=t.alloc(0);J.length*8<j.bitLength();)N.v=e(Y,N.k).update(N.v).digest(),J=t.concat([J,N.v]);ie=P(J,j),N.k=e(Y,N.k).update(N.v).update(t.from([0])).digest(),N.v=e(Y,N.k).update(N.v).digest()}while(ie.cmp(j)!==-1);return ie}function F(j,N,Y,J){return j.toRed(u.mont(Y)).redPow(N).fromRed().mod(J)}return sign.exports=E,sign.exports.getKey=D,sign.exports.makeKey=B,sign.exports}var verify_1,hasRequiredVerify$1;function requireVerify$1(){if(hasRequiredVerify$1)return verify_1;hasRequiredVerify$1=1;var t=safeBufferExports$1.Buffer,e=bnExports$4,n=requireElliptic().ec,o=parseAsn1,u=require$$4$1;function l(C,k,A,D,P){var R=o(A);if(R.type==="ec"){if(D!=="ecdsa"&&D!=="ecdsa/rsa")throw new Error("wrong public key type");return m(C,k,R)}else if(R.type==="dsa"){if(D!=="dsa")throw new Error("wrong public key type");return y(C,k,R)}if(D!=="rsa"&&D!=="ecdsa/rsa")throw new Error("wrong public key type");k=t.concat([P,k]);for(var B=R.modulus.byteLength(),F=[1],j=0;k.length+F.length+2<B;)F.push(255),j+=1;F.push(0);for(var N=-1;++N<k.length;)F.push(k[N]);F=t.from(F);var Y=e.mont(R.modulus);C=new e(C).toRed(Y),C=C.redPow(new e(R.publicExponent)),C=t.from(C.fromRed().toArray());var J=j<8?1:0;for(B=Math.min(C.length,F.length),C.length!==F.length&&(J=1),N=-1;++N<B;)J|=C[N]^F[N];return J===0}function m(C,k,A){var D=u[A.data.algorithm.curve.join(".")];if(!D)throw new Error("unknown curve "+A.data.algorithm.curve.join("."));var P=new n(D),R=A.data.subjectPrivateKey.data;return P.verify(k,C,R)}function y(C,k,A){var D=A.data.p,P=A.data.q,R=A.data.g,B=A.data.pub_key,F=o.signature.decode(C,"der"),j=F.s,N=F.r;E(j,P),E(N,P);var Y=e.mont(D),J=j.invm(P),ie=R.toRed(Y).redPow(new e(k).mul(J).mod(P)).fromRed().mul(B.toRed(Y).redPow(N.mul(J).mod(P)).fromRed()).mod(D).mod(P);return ie.cmp(N)===0}function E(C,k){if(C.cmpn(0)<=0)throw new Error("invalid sig");if(C.cmp(k)>=0)throw new Error("invalid sig")}return verify_1=l,verify_1}var browser$5,hasRequiredBrowser$3;function requireBrowser$3(){if(hasRequiredBrowser$3)return browser$5;hasRequiredBrowser$3=1;var t=safeBufferExports$1.Buffer,e=browser$b,n=readableBrowserExports,o=inherits_browserExports,u=requireSign(),l=requireVerify$1(),m=require$$6$1;Object.keys(m).forEach(function(A){m[A].id=t.from(m[A].id,"hex"),m[A.toLowerCase()]=m[A]});function y(A){n.Writable.call(this);var D=m[A];if(!D)throw new Error("Unknown message digest");this._hashType=D.hash,this._hash=e(D.hash),this._tag=D.id,this._signType=D.sign}o(y,n.Writable),y.prototype._write=function(D,P,R){this._hash.update(D),R()},y.prototype.update=function(D,P){return this._hash.update(typeof D=="string"?t.from(D,P):D),this},y.prototype.sign=function(D,P){this.end();var R=this._hash.digest(),B=u(R,D,this._hashType,this._signType,this._tag);return P?B.toString(P):B};function E(A){n.Writable.call(this);var D=m[A];if(!D)throw new Error("Unknown message digest");this._hash=e(D.hash),this._tag=D.id,this._signType=D.sign}o(E,n.Writable),E.prototype._write=function(D,P,R){this._hash.update(D),R()},E.prototype.update=function(D,P){return this._hash.update(typeof D=="string"?t.from(D,P):D),this},E.prototype.verify=function(D,P,R){var B=typeof P=="string"?t.from(P,R):P;this.end();var F=this._hash.digest();return l(B,F,D,this._signType,this._tag)};function C(A){return new y(A)}function k(A){return new E(A)}return browser$5={Sign:C,Verify:k,createSign:C,createVerify:k},browser$5}var bn$1={exports:{}};bn$1.exports,function(t){(function(e,n){function o(L,d){if(!L)throw new Error(d||"Assertion failed")}function u(L,d){L.super_=d;var v=function(){};v.prototype=d.prototype,L.prototype=new v,L.prototype.constructor=L}function l(L,d,v){if(l.isBN(L))return L;this.negative=0,this.words=null,this.length=0,this.red=null,L!==null&&((d==="le"||d==="be")&&(v=d,d=10),this._init(L||0,d||10,v||"be"))}typeof e=="object"?e.exports=l:n.BN=l,l.BN=l,l.wordSize=26;var m;try{typeof window<"u"&&typeof window.Buffer<"u"?m=window.Buffer:m=require$$0$2.Buffer}catch{}l.isBN=function(d){return d instanceof l?!0:d!==null&&typeof d=="object"&&d.constructor.wordSize===l.wordSize&&Array.isArray(d.words)},l.max=function(d,v){return d.cmp(v)>0?d:v},l.min=function(d,v){return d.cmp(v)<0?d:v},l.prototype._init=function(d,v,w){if(typeof d=="number")return this._initNumber(d,v,w);if(typeof d=="object")return this._initArray(d,v,w);v==="hex"&&(v=16),o(v===(v|0)&&v>=2&&v<=36),d=d.toString().replace(/\s+/g,"");var c=0;d[0]==="-"&&(c++,this.negative=1),c<d.length&&(v===16?this._parseHex(d,c,w):(this._parseBase(d,v,c),w==="le"&&this._initArray(this.toArray(),v,w)))},l.prototype._initNumber=function(d,v,w){d<0&&(this.negative=1,d=-d),d<67108864?(this.words=[d&67108863],this.length=1):d<4503599627370496?(this.words=[d&67108863,d/67108864&67108863],this.length=2):(o(d<9007199254740992),this.words=[d&67108863,d/67108864&67108863,1],this.length=3),w==="le"&&this._initArray(this.toArray(),v,w)},l.prototype._initArray=function(d,v,w){if(o(typeof d.length=="number"),d.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(d.length/3),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p,x,S=0;if(w==="be")for(c=d.length-1,p=0;c>=0;c-=3)x=d[c]|d[c-1]<<8|d[c-2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);else if(w==="le")for(c=0,p=0;c<d.length;c+=3)x=d[c]|d[c+1]<<8|d[c+2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);return this.strip()};function y(L,d){var v=L.charCodeAt(d);return v>=65&&v<=70?v-55:v>=97&&v<=102?v-87:v-48&15}function E(L,d,v){var w=y(L,v);return v-1>=d&&(w|=y(L,v-1)<<4),w}l.prototype._parseHex=function(d,v,w){this.length=Math.ceil((d.length-v)/6),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p=0,x=0,S;if(w==="be")for(c=d.length-1;c>=v;c-=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8;else{var b=d.length-v;for(c=b%2===0?v+1:v;c<d.length;c+=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8}this.strip()};function C(L,d,v,w){for(var c=0,p=Math.min(L.length,v),x=d;x<p;x++){var S=L.charCodeAt(x)-48;c*=w,S>=49?c+=S-49+10:S>=17?c+=S-17+10:c+=S}return c}l.prototype._parseBase=function(d,v,w){this.words=[0],this.length=1;for(var c=0,p=1;p<=67108863;p*=v)c++;c--,p=p/v|0;for(var x=d.length-w,S=x%c,b=Math.min(x,x-S)+w,h=0,T=w;T<b;T+=c)h=C(d,T,T+c,v),this.imuln(p),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h);if(S!==0){var M=1;for(h=C(d,T,d.length,v),T=0;T<S;T++)M*=v;this.imuln(M),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h)}this.strip()},l.prototype.copy=function(d){d.words=new Array(this.length);for(var v=0;v<this.length;v++)d.words[v]=this.words[v];d.length=this.length,d.negative=this.negative,d.red=this.red},l.prototype.clone=function(){var d=new l(null);return this.copy(d),d},l.prototype._expand=function(d){for(;this.length<d;)this.words[this.length++]=0;return this},l.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},l.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},l.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var k=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],D=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];l.prototype.toString=function(d,v){d=d||10,v=v|0||1;var w;if(d===16||d==="hex"){w="";for(var c=0,p=0,x=0;x<this.length;x++){var S=this.words[x],b=((S<<c|p)&16777215).toString(16);p=S>>>24-c&16777215,p!==0||x!==this.length-1?w=k[6-b.length]+b+w:w=b+w,c+=2,c>=26&&(c-=26,x--)}for(p!==0&&(w=p.toString(16)+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}if(d===(d|0)&&d>=2&&d<=36){var h=A[d],T=D[d];w="";var M=this.clone();for(M.negative=0;!M.isZero();){var O=M.modn(T).toString(d);M=M.idivn(T),M.isZero()?w=O+w:w=k[h-O.length]+O+w}for(this.isZero()&&(w="0"+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}o(!1,"Base should be between 2 and 36")},l.prototype.toNumber=function(){var d=this.words[0];return this.length===2?d+=this.words[1]*67108864:this.length===3&&this.words[2]===1?d+=4503599627370496+this.words[1]*67108864:this.length>2&&o(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-d:d},l.prototype.toJSON=function(){return this.toString(16)},l.prototype.toBuffer=function(d,v){return o(typeof m<"u"),this.toArrayLike(m,d,v)},l.prototype.toArray=function(d,v){return this.toArrayLike(Array,d,v)},l.prototype.toArrayLike=function(d,v,w){var c=this.byteLength(),p=w||Math.max(1,c);o(c<=p,"byte array longer than desired length"),o(p>0,"Requested array length <= 0"),this.strip();var x=v==="le",S=new d(p),b,h,T=this.clone();if(x){for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[h]=b;for(;h<p;h++)S[h]=0}else{for(h=0;h<p-c;h++)S[h]=0;for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[p-h-1]=b}return S},Math.clz32?l.prototype._countBits=function(d){return 32-Math.clz32(d)}:l.prototype._countBits=function(d){var v=d,w=0;return v>=4096&&(w+=13,v>>>=13),v>=64&&(w+=7,v>>>=7),v>=8&&(w+=4,v>>>=4),v>=2&&(w+=2,v>>>=2),w+v},l.prototype._zeroBits=function(d){if(d===0)return 26;var v=d,w=0;return v&8191||(w+=13,v>>>=13),v&127||(w+=7,v>>>=7),v&15||(w+=4,v>>>=4),v&3||(w+=2,v>>>=2),v&1||w++,w},l.prototype.bitLength=function(){var d=this.words[this.length-1],v=this._countBits(d);return(this.length-1)*26+v};function P(L){for(var d=new Array(L.bitLength()),v=0;v<d.length;v++){var w=v/26|0,c=v%26;d[v]=(L.words[w]&1<<c)>>>c}return d}l.prototype.zeroBits=function(){if(this.isZero())return 0;for(var d=0,v=0;v<this.length;v++){var w=this._zeroBits(this.words[v]);if(d+=w,w!==26)break}return d},l.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},l.prototype.toTwos=function(d){return this.negative!==0?this.abs().inotn(d).iaddn(1):this.clone()},l.prototype.fromTwos=function(d){return this.testn(d-1)?this.notn(d).iaddn(1).ineg():this.clone()},l.prototype.isNeg=function(){return this.negative!==0},l.prototype.neg=function(){return this.clone().ineg()},l.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},l.prototype.iuor=function(d){for(;this.length<d.length;)this.words[this.length++]=0;for(var v=0;v<d.length;v++)this.words[v]=this.words[v]|d.words[v];return this.strip()},l.prototype.ior=function(d){return o((this.negative|d.negative)===0),this.iuor(d)},l.prototype.or=function(d){return this.length>d.length?this.clone().ior(d):d.clone().ior(this)},l.prototype.uor=function(d){return this.length>d.length?this.clone().iuor(d):d.clone().iuor(this)},l.prototype.iuand=function(d){var v;this.length>d.length?v=d:v=this;for(var w=0;w<v.length;w++)this.words[w]=this.words[w]&d.words[w];return this.length=v.length,this.strip()},l.prototype.iand=function(d){return o((this.negative|d.negative)===0),this.iuand(d)},l.prototype.and=function(d){return this.length>d.length?this.clone().iand(d):d.clone().iand(this)},l.prototype.uand=function(d){return this.length>d.length?this.clone().iuand(d):d.clone().iuand(this)},l.prototype.iuxor=function(d){var v,w;this.length>d.length?(v=this,w=d):(v=d,w=this);for(var c=0;c<w.length;c++)this.words[c]=v.words[c]^w.words[c];if(this!==v)for(;c<v.length;c++)this.words[c]=v.words[c];return this.length=v.length,this.strip()},l.prototype.ixor=function(d){return o((this.negative|d.negative)===0),this.iuxor(d)},l.prototype.xor=function(d){return this.length>d.length?this.clone().ixor(d):d.clone().ixor(this)},l.prototype.uxor=function(d){return this.length>d.length?this.clone().iuxor(d):d.clone().iuxor(this)},l.prototype.inotn=function(d){o(typeof d=="number"&&d>=0);var v=Math.ceil(d/26)|0,w=d%26;this._expand(v),w>0&&v--;for(var c=0;c<v;c++)this.words[c]=~this.words[c]&67108863;return w>0&&(this.words[c]=~this.words[c]&67108863>>26-w),this.strip()},l.prototype.notn=function(d){return this.clone().inotn(d)},l.prototype.setn=function(d,v){o(typeof d=="number"&&d>=0);var w=d/26|0,c=d%26;return this._expand(w+1),v?this.words[w]=this.words[w]|1<<c:this.words[w]=this.words[w]&~(1<<c),this.strip()},l.prototype.iadd=function(d){var v;if(this.negative!==0&&d.negative===0)return this.negative=0,v=this.isub(d),this.negative^=1,this._normSign();if(this.negative===0&&d.negative!==0)return d.negative=0,v=this.isub(d),d.negative=1,v._normSign();var w,c;this.length>d.length?(w=this,c=d):(w=d,c=this);for(var p=0,x=0;x<c.length;x++)v=(w.words[x]|0)+(c.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;for(;p!==0&&x<w.length;x++)v=(w.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;if(this.length=w.length,p!==0)this.words[this.length]=p,this.length++;else if(w!==this)for(;x<w.length;x++)this.words[x]=w.words[x];return this},l.prototype.add=function(d){var v;return d.negative!==0&&this.negative===0?(d.negative=0,v=this.sub(d),d.negative^=1,v):d.negative===0&&this.negative!==0?(this.negative=0,v=d.sub(this),this.negative=1,v):this.length>d.length?this.clone().iadd(d):d.clone().iadd(this)},l.prototype.isub=function(d){if(d.negative!==0){d.negative=0;var v=this.iadd(d);return d.negative=1,v._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(d),this.negative=1,this._normSign();var w=this.cmp(d);if(w===0)return this.negative=0,this.length=1,this.words[0]=0,this;var c,p;w>0?(c=this,p=d):(c=d,p=this);for(var x=0,S=0;S<p.length;S++)v=(c.words[S]|0)-(p.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;for(;x!==0&&S<c.length;S++)v=(c.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;if(x===0&&S<c.length&&c!==this)for(;S<c.length;S++)this.words[S]=c.words[S];return this.length=Math.max(this.length,S),c!==this&&(this.negative=1),this.strip()},l.prototype.sub=function(d){return this.clone().isub(d)};function R(L,d,v){v.negative=d.negative^L.negative;var w=L.length+d.length|0;v.length=w,w=w-1|0;var c=L.words[0]|0,p=d.words[0]|0,x=c*p,S=x&67108863,b=x/67108864|0;v.words[0]=S;for(var h=1;h<w;h++){for(var T=b>>>26,M=b&67108863,O=Math.min(h,d.length-1),V=Math.max(0,h-L.length+1);V<=O;V++){var ee=h-V|0;c=L.words[ee]|0,p=d.words[V]|0,x=c*p+M,T+=x/67108864|0,M=x&67108863}v.words[h]=M|0,b=T|0}return b!==0?v.words[h]=b|0:v.length--,v.strip()}var B=function(d,v,w){var c=d.words,p=v.words,x=w.words,S=0,b,h,T,M=c[0]|0,O=M&8191,V=M>>>13,ee=c[1]|0,Z=ee&8191,U=ee>>>13,z=c[2]|0,ne=z&8191,fe=z>>>13,me=c[3]|0,de=me&8191,je=me>>>13,lt=c[4]|0,it=lt&8191,ot=lt>>>13,Ct=c[5]|0,nt=Ct&8191,Je=Ct>>>13,tt=c[6]|0,rt=tt&8191,ht=tt>>>13,Ot=c[7]|0,Ve=Ot&8191,We=Ot>>>13,Gt=c[8]|0,wt=Gt&8191,Et=Gt>>>13,Yt=c[9]|0,Ce=Yt&8191,te=Yt>>>13,ye=p[0]|0,Le=ye&8191,Ue=ye>>>13,Qe=p[1]|0,Ke=Qe&8191,De=Qe>>>13,Vt=p[2]|0,At=Vt&8191,ve=Vt>>>13,Pt=p[3]|0,pt=Pt&8191,Ne=Pt>>>13,vt=p[4]|0,ut=vt&8191,$t=vt>>>13,fi=p[5]|0,kt=fi&8191,Wt=fi>>>13,Zi=p[6]|0,Ut=Zi&8191,Xt=Zi>>>13,Be=p[7]|0,be=Be&8191,ge=Be>>>13,oe=p[8]|0,Ae=oe&8191,qe=oe>>>13,bt=p[9]|0,at=bt&8191,gt=bt>>>13;w.negative=d.negative^v.negative,w.length=19,b=Math.imul(O,Le),h=Math.imul(O,Ue),h=h+Math.imul(V,Le)|0,T=Math.imul(V,Ue);var ei=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ei>>>26)|0,ei&=67108863,b=Math.imul(Z,Le),h=Math.imul(Z,Ue),h=h+Math.imul(U,Le)|0,T=Math.imul(U,Ue),b=b+Math.imul(O,Ke)|0,h=h+Math.imul(O,De)|0,h=h+Math.imul(V,Ke)|0,T=T+Math.imul(V,De)|0;var ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ii>>>26)|0,ii&=67108863,b=Math.imul(ne,Le),h=Math.imul(ne,Ue),h=h+Math.imul(fe,Le)|0,T=Math.imul(fe,Ue),b=b+Math.imul(Z,Ke)|0,h=h+Math.imul(Z,De)|0,h=h+Math.imul(U,Ke)|0,T=T+Math.imul(U,De)|0,b=b+Math.imul(O,At)|0,h=h+Math.imul(O,ve)|0,h=h+Math.imul(V,At)|0,T=T+Math.imul(V,ve)|0;var Bi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Bi>>>26)|0,Bi&=67108863,b=Math.imul(de,Le),h=Math.imul(de,Ue),h=h+Math.imul(je,Le)|0,T=Math.imul(je,Ue),b=b+Math.imul(ne,Ke)|0,h=h+Math.imul(ne,De)|0,h=h+Math.imul(fe,Ke)|0,T=T+Math.imul(fe,De)|0,b=b+Math.imul(Z,At)|0,h=h+Math.imul(Z,ve)|0,h=h+Math.imul(U,At)|0,T=T+Math.imul(U,ve)|0,b=b+Math.imul(O,pt)|0,h=h+Math.imul(O,Ne)|0,h=h+Math.imul(V,pt)|0,T=T+Math.imul(V,Ne)|0;var hi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(hi>>>26)|0,hi&=67108863,b=Math.imul(it,Le),h=Math.imul(it,Ue),h=h+Math.imul(ot,Le)|0,T=Math.imul(ot,Ue),b=b+Math.imul(de,Ke)|0,h=h+Math.imul(de,De)|0,h=h+Math.imul(je,Ke)|0,T=T+Math.imul(je,De)|0,b=b+Math.imul(ne,At)|0,h=h+Math.imul(ne,ve)|0,h=h+Math.imul(fe,At)|0,T=T+Math.imul(fe,ve)|0,b=b+Math.imul(Z,pt)|0,h=h+Math.imul(Z,Ne)|0,h=h+Math.imul(U,pt)|0,T=T+Math.imul(U,Ne)|0,b=b+Math.imul(O,ut)|0,h=h+Math.imul(O,$t)|0,h=h+Math.imul(V,ut)|0,T=T+Math.imul(V,$t)|0;var Di=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Di>>>26)|0,Di&=67108863,b=Math.imul(nt,Le),h=Math.imul(nt,Ue),h=h+Math.imul(Je,Le)|0,T=Math.imul(Je,Ue),b=b+Math.imul(it,Ke)|0,h=h+Math.imul(it,De)|0,h=h+Math.imul(ot,Ke)|0,T=T+Math.imul(ot,De)|0,b=b+Math.imul(de,At)|0,h=h+Math.imul(de,ve)|0,h=h+Math.imul(je,At)|0,T=T+Math.imul(je,ve)|0,b=b+Math.imul(ne,pt)|0,h=h+Math.imul(ne,Ne)|0,h=h+Math.imul(fe,pt)|0,T=T+Math.imul(fe,Ne)|0,b=b+Math.imul(Z,ut)|0,h=h+Math.imul(Z,$t)|0,h=h+Math.imul(U,ut)|0,T=T+Math.imul(U,$t)|0,b=b+Math.imul(O,kt)|0,h=h+Math.imul(O,Wt)|0,h=h+Math.imul(V,kt)|0,T=T+Math.imul(V,Wt)|0;var ni=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ni>>>26)|0,ni&=67108863,b=Math.imul(rt,Le),h=Math.imul(rt,Ue),h=h+Math.imul(ht,Le)|0,T=Math.imul(ht,Ue),b=b+Math.imul(nt,Ke)|0,h=h+Math.imul(nt,De)|0,h=h+Math.imul(Je,Ke)|0,T=T+Math.imul(Je,De)|0,b=b+Math.imul(it,At)|0,h=h+Math.imul(it,ve)|0,h=h+Math.imul(ot,At)|0,T=T+Math.imul(ot,ve)|0,b=b+Math.imul(de,pt)|0,h=h+Math.imul(de,Ne)|0,h=h+Math.imul(je,pt)|0,T=T+Math.imul(je,Ne)|0,b=b+Math.imul(ne,ut)|0,h=h+Math.imul(ne,$t)|0,h=h+Math.imul(fe,ut)|0,T=T+Math.imul(fe,$t)|0,b=b+Math.imul(Z,kt)|0,h=h+Math.imul(Z,Wt)|0,h=h+Math.imul(U,kt)|0,T=T+Math.imul(U,Wt)|0,b=b+Math.imul(O,Ut)|0,h=h+Math.imul(O,Xt)|0,h=h+Math.imul(V,Ut)|0,T=T+Math.imul(V,Xt)|0;var pi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(pi>>>26)|0,pi&=67108863,b=Math.imul(Ve,Le),h=Math.imul(Ve,Ue),h=h+Math.imul(We,Le)|0,T=Math.imul(We,Ue),b=b+Math.imul(rt,Ke)|0,h=h+Math.imul(rt,De)|0,h=h+Math.imul(ht,Ke)|0,T=T+Math.imul(ht,De)|0,b=b+Math.imul(nt,At)|0,h=h+Math.imul(nt,ve)|0,h=h+Math.imul(Je,At)|0,T=T+Math.imul(Je,ve)|0,b=b+Math.imul(it,pt)|0,h=h+Math.imul(it,Ne)|0,h=h+Math.imul(ot,pt)|0,T=T+Math.imul(ot,Ne)|0,b=b+Math.imul(de,ut)|0,h=h+Math.imul(de,$t)|0,h=h+Math.imul(je,ut)|0,T=T+Math.imul(je,$t)|0,b=b+Math.imul(ne,kt)|0,h=h+Math.imul(ne,Wt)|0,h=h+Math.imul(fe,kt)|0,T=T+Math.imul(fe,Wt)|0,b=b+Math.imul(Z,Ut)|0,h=h+Math.imul(Z,Xt)|0,h=h+Math.imul(U,Ut)|0,T=T+Math.imul(U,Xt)|0,b=b+Math.imul(O,be)|0,h=h+Math.imul(O,ge)|0,h=h+Math.imul(V,be)|0,T=T+Math.imul(V,ge)|0;var Ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ii>>>26)|0,Ii&=67108863,b=Math.imul(wt,Le),h=Math.imul(wt,Ue),h=h+Math.imul(Et,Le)|0,T=Math.imul(Et,Ue),b=b+Math.imul(Ve,Ke)|0,h=h+Math.imul(Ve,De)|0,h=h+Math.imul(We,Ke)|0,T=T+Math.imul(We,De)|0,b=b+Math.imul(rt,At)|0,h=h+Math.imul(rt,ve)|0,h=h+Math.imul(ht,At)|0,T=T+Math.imul(ht,ve)|0,b=b+Math.imul(nt,pt)|0,h=h+Math.imul(nt,Ne)|0,h=h+Math.imul(Je,pt)|0,T=T+Math.imul(Je,Ne)|0,b=b+Math.imul(it,ut)|0,h=h+Math.imul(it,$t)|0,h=h+Math.imul(ot,ut)|0,T=T+Math.imul(ot,$t)|0,b=b+Math.imul(de,kt)|0,h=h+Math.imul(de,Wt)|0,h=h+Math.imul(je,kt)|0,T=T+Math.imul(je,Wt)|0,b=b+Math.imul(ne,Ut)|0,h=h+Math.imul(ne,Xt)|0,h=h+Math.imul(fe,Ut)|0,T=T+Math.imul(fe,Xt)|0,b=b+Math.imul(Z,be)|0,h=h+Math.imul(Z,ge)|0,h=h+Math.imul(U,be)|0,T=T+Math.imul(U,ge)|0,b=b+Math.imul(O,Ae)|0,h=h+Math.imul(O,qe)|0,h=h+Math.imul(V,Ae)|0,T=T+Math.imul(V,qe)|0;var Ci=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ci>>>26)|0,Ci&=67108863,b=Math.imul(Ce,Le),h=Math.imul(Ce,Ue),h=h+Math.imul(te,Le)|0,T=Math.imul(te,Ue),b=b+Math.imul(wt,Ke)|0,h=h+Math.imul(wt,De)|0,h=h+Math.imul(Et,Ke)|0,T=T+Math.imul(Et,De)|0,b=b+Math.imul(Ve,At)|0,h=h+Math.imul(Ve,ve)|0,h=h+Math.imul(We,At)|0,T=T+Math.imul(We,ve)|0,b=b+Math.imul(rt,pt)|0,h=h+Math.imul(rt,Ne)|0,h=h+Math.imul(ht,pt)|0,T=T+Math.imul(ht,Ne)|0,b=b+Math.imul(nt,ut)|0,h=h+Math.imul(nt,$t)|0,h=h+Math.imul(Je,ut)|0,T=T+Math.imul(Je,$t)|0,b=b+Math.imul(it,kt)|0,h=h+Math.imul(it,Wt)|0,h=h+Math.imul(ot,kt)|0,T=T+Math.imul(ot,Wt)|0,b=b+Math.imul(de,Ut)|0,h=h+Math.imul(de,Xt)|0,h=h+Math.imul(je,Ut)|0,T=T+Math.imul(je,Xt)|0,b=b+Math.imul(ne,be)|0,h=h+Math.imul(ne,ge)|0,h=h+Math.imul(fe,be)|0,T=T+Math.imul(fe,ge)|0,b=b+Math.imul(Z,Ae)|0,h=h+Math.imul(Z,qe)|0,h=h+Math.imul(U,Ae)|0,T=T+Math.imul(U,qe)|0,b=b+Math.imul(O,at)|0,h=h+Math.imul(O,gt)|0,h=h+Math.imul(V,at)|0,T=T+Math.imul(V,gt)|0;var zi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zi>>>26)|0,zi&=67108863,b=Math.imul(Ce,Ke),h=Math.imul(Ce,De),h=h+Math.imul(te,Ke)|0,T=Math.imul(te,De),b=b+Math.imul(wt,At)|0,h=h+Math.imul(wt,ve)|0,h=h+Math.imul(Et,At)|0,T=T+Math.imul(Et,ve)|0,b=b+Math.imul(Ve,pt)|0,h=h+Math.imul(Ve,Ne)|0,h=h+Math.imul(We,pt)|0,T=T+Math.imul(We,Ne)|0,b=b+Math.imul(rt,ut)|0,h=h+Math.imul(rt,$t)|0,h=h+Math.imul(ht,ut)|0,T=T+Math.imul(ht,$t)|0,b=b+Math.imul(nt,kt)|0,h=h+Math.imul(nt,Wt)|0,h=h+Math.imul(Je,kt)|0,T=T+Math.imul(Je,Wt)|0,b=b+Math.imul(it,Ut)|0,h=h+Math.imul(it,Xt)|0,h=h+Math.imul(ot,Ut)|0,T=T+Math.imul(ot,Xt)|0,b=b+Math.imul(de,be)|0,h=h+Math.imul(de,ge)|0,h=h+Math.imul(je,be)|0,T=T+Math.imul(je,ge)|0,b=b+Math.imul(ne,Ae)|0,h=h+Math.imul(ne,qe)|0,h=h+Math.imul(fe,Ae)|0,T=T+Math.imul(fe,qe)|0,b=b+Math.imul(Z,at)|0,h=h+Math.imul(Z,gt)|0,h=h+Math.imul(U,at)|0,T=T+Math.imul(U,gt)|0;var qi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(qi>>>26)|0,qi&=67108863,b=Math.imul(Ce,At),h=Math.imul(Ce,ve),h=h+Math.imul(te,At)|0,T=Math.imul(te,ve),b=b+Math.imul(wt,pt)|0,h=h+Math.imul(wt,Ne)|0,h=h+Math.imul(Et,pt)|0,T=T+Math.imul(Et,Ne)|0,b=b+Math.imul(Ve,ut)|0,h=h+Math.imul(Ve,$t)|0,h=h+Math.imul(We,ut)|0,T=T+Math.imul(We,$t)|0,b=b+Math.imul(rt,kt)|0,h=h+Math.imul(rt,Wt)|0,h=h+Math.imul(ht,kt)|0,T=T+Math.imul(ht,Wt)|0,b=b+Math.imul(nt,Ut)|0,h=h+Math.imul(nt,Xt)|0,h=h+Math.imul(Je,Ut)|0,T=T+Math.imul(Je,Xt)|0,b=b+Math.imul(it,be)|0,h=h+Math.imul(it,ge)|0,h=h+Math.imul(ot,be)|0,T=T+Math.imul(ot,ge)|0,b=b+Math.imul(de,Ae)|0,h=h+Math.imul(de,qe)|0,h=h+Math.imul(je,Ae)|0,T=T+Math.imul(je,qe)|0,b=b+Math.imul(ne,at)|0,h=h+Math.imul(ne,gt)|0,h=h+Math.imul(fe,at)|0,T=T+Math.imul(fe,gt)|0;var Ai=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ai>>>26)|0,Ai&=67108863,b=Math.imul(Ce,pt),h=Math.imul(Ce,Ne),h=h+Math.imul(te,pt)|0,T=Math.imul(te,Ne),b=b+Math.imul(wt,ut)|0,h=h+Math.imul(wt,$t)|0,h=h+Math.imul(Et,ut)|0,T=T+Math.imul(Et,$t)|0,b=b+Math.imul(Ve,kt)|0,h=h+Math.imul(Ve,Wt)|0,h=h+Math.imul(We,kt)|0,T=T+Math.imul(We,Wt)|0,b=b+Math.imul(rt,Ut)|0,h=h+Math.imul(rt,Xt)|0,h=h+Math.imul(ht,Ut)|0,T=T+Math.imul(ht,Xt)|0,b=b+Math.imul(nt,be)|0,h=h+Math.imul(nt,ge)|0,h=h+Math.imul(Je,be)|0,T=T+Math.imul(Je,ge)|0,b=b+Math.imul(it,Ae)|0,h=h+Math.imul(it,qe)|0,h=h+Math.imul(ot,Ae)|0,T=T+Math.imul(ot,qe)|0,b=b+Math.imul(de,at)|0,h=h+Math.imul(de,gt)|0,h=h+Math.imul(je,at)|0,T=T+Math.imul(je,gt)|0;var Oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Oi>>>26)|0,Oi&=67108863,b=Math.imul(Ce,ut),h=Math.imul(Ce,$t),h=h+Math.imul(te,ut)|0,T=Math.imul(te,$t),b=b+Math.imul(wt,kt)|0,h=h+Math.imul(wt,Wt)|0,h=h+Math.imul(Et,kt)|0,T=T+Math.imul(Et,Wt)|0,b=b+Math.imul(Ve,Ut)|0,h=h+Math.imul(Ve,Xt)|0,h=h+Math.imul(We,Ut)|0,T=T+Math.imul(We,Xt)|0,b=b+Math.imul(rt,be)|0,h=h+Math.imul(rt,ge)|0,h=h+Math.imul(ht,be)|0,T=T+Math.imul(ht,ge)|0,b=b+Math.imul(nt,Ae)|0,h=h+Math.imul(nt,qe)|0,h=h+Math.imul(Je,Ae)|0,T=T+Math.imul(Je,qe)|0,b=b+Math.imul(it,at)|0,h=h+Math.imul(it,gt)|0,h=h+Math.imul(ot,at)|0,T=T+Math.imul(ot,gt)|0;var ki=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ki>>>26)|0,ki&=67108863,b=Math.imul(Ce,kt),h=Math.imul(Ce,Wt),h=h+Math.imul(te,kt)|0,T=Math.imul(te,Wt),b=b+Math.imul(wt,Ut)|0,h=h+Math.imul(wt,Xt)|0,h=h+Math.imul(Et,Ut)|0,T=T+Math.imul(Et,Xt)|0,b=b+Math.imul(Ve,be)|0,h=h+Math.imul(Ve,ge)|0,h=h+Math.imul(We,be)|0,T=T+Math.imul(We,ge)|0,b=b+Math.imul(rt,Ae)|0,h=h+Math.imul(rt,qe)|0,h=h+Math.imul(ht,Ae)|0,T=T+Math.imul(ht,qe)|0,b=b+Math.imul(nt,at)|0,h=h+Math.imul(nt,gt)|0,h=h+Math.imul(Je,at)|0,T=T+Math.imul(Je,gt)|0;var Ti=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ti>>>26)|0,Ti&=67108863,b=Math.imul(Ce,Ut),h=Math.imul(Ce,Xt),h=h+Math.imul(te,Ut)|0,T=Math.imul(te,Xt),b=b+Math.imul(wt,be)|0,h=h+Math.imul(wt,ge)|0,h=h+Math.imul(Et,be)|0,T=T+Math.imul(Et,ge)|0,b=b+Math.imul(Ve,Ae)|0,h=h+Math.imul(Ve,qe)|0,h=h+Math.imul(We,Ae)|0,T=T+Math.imul(We,qe)|0,b=b+Math.imul(rt,at)|0,h=h+Math.imul(rt,gt)|0,h=h+Math.imul(ht,at)|0,T=T+Math.imul(ht,gt)|0;var wi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(wi>>>26)|0,wi&=67108863,b=Math.imul(Ce,be),h=Math.imul(Ce,ge),h=h+Math.imul(te,be)|0,T=Math.imul(te,ge),b=b+Math.imul(wt,Ae)|0,h=h+Math.imul(wt,qe)|0,h=h+Math.imul(Et,Ae)|0,T=T+Math.imul(Et,qe)|0,b=b+Math.imul(Ve,at)|0,h=h+Math.imul(Ve,gt)|0,h=h+Math.imul(We,at)|0,T=T+Math.imul(We,gt)|0;var oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(oi>>>26)|0,oi&=67108863,b=Math.imul(Ce,Ae),h=Math.imul(Ce,qe),h=h+Math.imul(te,Ae)|0,T=Math.imul(te,qe),b=b+Math.imul(wt,at)|0,h=h+Math.imul(wt,gt)|0,h=h+Math.imul(Et,at)|0,T=T+Math.imul(Et,gt)|0;var zt=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zt>>>26)|0,zt&=67108863,b=Math.imul(Ce,at),h=Math.imul(Ce,gt),h=h+Math.imul(te,at)|0,T=Math.imul(te,gt);var Qt=(S+b|0)+((h&8191)<<13)|0;return S=(T+(h>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,x[0]=ei,x[1]=ii,x[2]=Bi,x[3]=hi,x[4]=Di,x[5]=ni,x[6]=pi,x[7]=Ii,x[8]=Ci,x[9]=zi,x[10]=qi,x[11]=Ai,x[12]=Oi,x[13]=ki,x[14]=Ti,x[15]=wi,x[16]=oi,x[17]=zt,x[18]=Qt,S!==0&&(x[19]=S,w.length++),w};Math.imul||(B=R);function F(L,d,v){v.negative=d.negative^L.negative,v.length=L.length+d.length;for(var w=0,c=0,p=0;p<v.length-1;p++){var x=c;c=0;for(var S=w&67108863,b=Math.min(p,d.length-1),h=Math.max(0,p-L.length+1);h<=b;h++){var T=p-h,M=L.words[T]|0,O=d.words[h]|0,V=M*O,ee=V&67108863;x=x+(V/67108864|0)|0,ee=ee+S|0,S=ee&67108863,x=x+(ee>>>26)|0,c+=x>>>26,x&=67108863}v.words[p]=S,w=x,x=c}return w!==0?v.words[p]=w:v.length--,v.strip()}function j(L,d,v){var w=new N;return w.mulp(L,d,v)}l.prototype.mulTo=function(d,v){var w,c=this.length+d.length;return this.length===10&&d.length===10?w=B(this,d,v):c<63?w=R(this,d,v):c<1024?w=F(this,d,v):w=j(this,d,v),w};function N(L,d){this.x=L,this.y=d}N.prototype.makeRBT=function(d){for(var v=new Array(d),w=l.prototype._countBits(d)-1,c=0;c<d;c++)v[c]=this.revBin(c,w,d);return v},N.prototype.revBin=function(d,v,w){if(d===0||d===w-1)return d;for(var c=0,p=0;p<v;p++)c|=(d&1)<<v-p-1,d>>=1;return c},N.prototype.permute=function(d,v,w,c,p,x){for(var S=0;S<x;S++)c[S]=v[d[S]],p[S]=w[d[S]]},N.prototype.transform=function(d,v,w,c,p,x){this.permute(x,d,v,w,c,p);for(var S=1;S<p;S<<=1)for(var b=S<<1,h=Math.cos(2*Math.PI/b),T=Math.sin(2*Math.PI/b),M=0;M<p;M+=b)for(var O=h,V=T,ee=0;ee<S;ee++){var Z=w[M+ee],U=c[M+ee],z=w[M+ee+S],ne=c[M+ee+S],fe=O*z-V*ne;ne=O*ne+V*z,z=fe,w[M+ee]=Z+z,c[M+ee]=U+ne,w[M+ee+S]=Z-z,c[M+ee+S]=U-ne,ee!==b&&(fe=h*O-T*V,V=h*V+T*O,O=fe)}},N.prototype.guessLen13b=function(d,v){var w=Math.max(v,d)|1,c=w&1,p=0;for(w=w/2|0;w;w=w>>>1)p++;return 1<<p+1+c},N.prototype.conjugate=function(d,v,w){if(!(w<=1))for(var c=0;c<w/2;c++){var p=d[c];d[c]=d[w-c-1],d[w-c-1]=p,p=v[c],v[c]=-v[w-c-1],v[w-c-1]=-p}},N.prototype.normalize13b=function(d,v){for(var w=0,c=0;c<v/2;c++){var p=Math.round(d[2*c+1]/v)*8192+Math.round(d[2*c]/v)+w;d[c]=p&67108863,p<67108864?w=0:w=p/67108864|0}return d},N.prototype.convert13b=function(d,v,w,c){for(var p=0,x=0;x<v;x++)p=p+(d[x]|0),w[2*x]=p&8191,p=p>>>13,w[2*x+1]=p&8191,p=p>>>13;for(x=2*v;x<c;++x)w[x]=0;o(p===0),o((p&-8192)===0)},N.prototype.stub=function(d){for(var v=new Array(d),w=0;w<d;w++)v[w]=0;return v},N.prototype.mulp=function(d,v,w){var c=2*this.guessLen13b(d.length,v.length),p=this.makeRBT(c),x=this.stub(c),S=new Array(c),b=new Array(c),h=new Array(c),T=new Array(c),M=new Array(c),O=new Array(c),V=w.words;V.length=c,this.convert13b(d.words,d.length,S,c),this.convert13b(v.words,v.length,T,c),this.transform(S,x,b,h,c,p),this.transform(T,x,M,O,c,p);for(var ee=0;ee<c;ee++){var Z=b[ee]*M[ee]-h[ee]*O[ee];h[ee]=b[ee]*O[ee]+h[ee]*M[ee],b[ee]=Z}return this.conjugate(b,h,c),this.transform(b,h,V,x,c,p),this.conjugate(V,x,c),this.normalize13b(V,c),w.negative=d.negative^v.negative,w.length=d.length+v.length,w.strip()},l.prototype.mul=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),this.mulTo(d,v)},l.prototype.mulf=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),j(this,d,v)},l.prototype.imul=function(d){return this.clone().mulTo(d,this)},l.prototype.imuln=function(d){o(typeof d=="number"),o(d<67108864);for(var v=0,w=0;w<this.length;w++){var c=(this.words[w]|0)*d,p=(c&67108863)+(v&67108863);v>>=26,v+=c/67108864|0,v+=p>>>26,this.words[w]=p&67108863}return v!==0&&(this.words[w]=v,this.length++),this},l.prototype.muln=function(d){return this.clone().imuln(d)},l.prototype.sqr=function(){return this.mul(this)},l.prototype.isqr=function(){return this.imul(this.clone())},l.prototype.pow=function(d){var v=P(d);if(v.length===0)return new l(1);for(var w=this,c=0;c<v.length&&v[c]===0;c++,w=w.sqr());if(++c<v.length)for(var p=w.sqr();c<v.length;c++,p=p.sqr())v[c]!==0&&(w=w.mul(p));return w},l.prototype.iushln=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=67108863>>>26-v<<26-v,p;if(v!==0){var x=0;for(p=0;p<this.length;p++){var S=this.words[p]&c,b=(this.words[p]|0)-S<<v;this.words[p]=b|x,x=S>>>26-v}x&&(this.words[p]=x,this.length++)}if(w!==0){for(p=this.length-1;p>=0;p--)this.words[p+w]=this.words[p];for(p=0;p<w;p++)this.words[p]=0;this.length+=w}return this.strip()},l.prototype.ishln=function(d){return o(this.negative===0),this.iushln(d)},l.prototype.iushrn=function(d,v,w){o(typeof d=="number"&&d>=0);var c;v?c=(v-v%26)/26:c=0;var p=d%26,x=Math.min((d-p)/26,this.length),S=67108863^67108863>>>p<<p,b=w;if(c-=x,c=Math.max(0,c),b){for(var h=0;h<x;h++)b.words[h]=this.words[h];b.length=x}if(x!==0)if(this.length>x)for(this.length-=x,h=0;h<this.length;h++)this.words[h]=this.words[h+x];else this.words[0]=0,this.length=1;var T=0;for(h=this.length-1;h>=0&&(T!==0||h>=c);h--){var M=this.words[h]|0;this.words[h]=T<<26-p|M>>>p,T=M&S}return b&&T!==0&&(b.words[b.length++]=T),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},l.prototype.ishrn=function(d,v,w){return o(this.negative===0),this.iushrn(d,v,w)},l.prototype.shln=function(d){return this.clone().ishln(d)},l.prototype.ushln=function(d){return this.clone().iushln(d)},l.prototype.shrn=function(d){return this.clone().ishrn(d)},l.prototype.ushrn=function(d){return this.clone().iushrn(d)},l.prototype.testn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return!1;var p=this.words[w];return!!(p&c)},l.prototype.imaskn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26;if(o(this.negative===0,"imaskn works only with positive numbers"),this.length<=w)return this;if(v!==0&&w++,this.length=Math.min(w,this.length),v!==0){var c=67108863^67108863>>>v<<v;this.words[this.length-1]&=c}return this.strip()},l.prototype.maskn=function(d){return this.clone().imaskn(d)},l.prototype.iaddn=function(d){return o(typeof d=="number"),o(d<67108864),d<0?this.isubn(-d):this.negative!==0?this.length===1&&(this.words[0]|0)<d?(this.words[0]=d-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(d),this.negative=1,this):this._iaddn(d)},l.prototype._iaddn=function(d){this.words[0]+=d;for(var v=0;v<this.length&&this.words[v]>=67108864;v++)this.words[v]-=67108864,v===this.length-1?this.words[v+1]=1:this.words[v+1]++;return this.length=Math.max(this.length,v+1),this},l.prototype.isubn=function(d){if(o(typeof d=="number"),o(d<67108864),d<0)return this.iaddn(-d);if(this.negative!==0)return this.negative=0,this.iaddn(d),this.negative=1,this;if(this.words[0]-=d,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var v=0;v<this.length&&this.words[v]<0;v++)this.words[v]+=67108864,this.words[v+1]-=1;return this.strip()},l.prototype.addn=function(d){return this.clone().iaddn(d)},l.prototype.subn=function(d){return this.clone().isubn(d)},l.prototype.iabs=function(){return this.negative=0,this},l.prototype.abs=function(){return this.clone().iabs()},l.prototype._ishlnsubmul=function(d,v,w){var c=d.length+w,p;this._expand(c);var x,S=0;for(p=0;p<d.length;p++){x=(this.words[p+w]|0)+S;var b=(d.words[p]|0)*v;x-=b&67108863,S=(x>>26)-(b/67108864|0),this.words[p+w]=x&67108863}for(;p<this.length-w;p++)x=(this.words[p+w]|0)+S,S=x>>26,this.words[p+w]=x&67108863;if(S===0)return this.strip();for(o(S===-1),S=0,p=0;p<this.length;p++)x=-(this.words[p]|0)+S,S=x>>26,this.words[p]=x&67108863;return this.negative=1,this.strip()},l.prototype._wordDiv=function(d,v){var w=this.length-d.length,c=this.clone(),p=d,x=p.words[p.length-1]|0,S=this._countBits(x);w=26-S,w!==0&&(p=p.ushln(w),c.iushln(w),x=p.words[p.length-1]|0);var b=c.length-p.length,h;if(v!=="mod"){h=new l(null),h.length=b+1,h.words=new Array(h.length);for(var T=0;T<h.length;T++)h.words[T]=0}var M=c.clone()._ishlnsubmul(p,1,b);M.negative===0&&(c=M,h&&(h.words[b]=1));for(var O=b-1;O>=0;O--){var V=(c.words[p.length+O]|0)*67108864+(c.words[p.length+O-1]|0);for(V=Math.min(V/x|0,67108863),c._ishlnsubmul(p,V,O);c.negative!==0;)V--,c.negative=0,c._ishlnsubmul(p,1,O),c.isZero()||(c.negative^=1);h&&(h.words[O]=V)}return h&&h.strip(),c.strip(),v!=="div"&&w!==0&&c.iushrn(w),{div:h||null,mod:c}},l.prototype.divmod=function(d,v,w){if(o(!d.isZero()),this.isZero())return{div:new l(0),mod:new l(0)};var c,p,x;return this.negative!==0&&d.negative===0?(x=this.neg().divmod(d,v),v!=="mod"&&(c=x.div.neg()),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.iadd(d)),{div:c,mod:p}):this.negative===0&&d.negative!==0?(x=this.divmod(d.neg(),v),v!=="mod"&&(c=x.div.neg()),{div:c,mod:x.mod}):this.negative&d.negative?(x=this.neg().divmod(d.neg(),v),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.isub(d)),{div:x.div,mod:p}):d.length>this.length||this.cmp(d)<0?{div:new l(0),mod:this}:d.length===1?v==="div"?{div:this.divn(d.words[0]),mod:null}:v==="mod"?{div:null,mod:new l(this.modn(d.words[0]))}:{div:this.divn(d.words[0]),mod:new l(this.modn(d.words[0]))}:this._wordDiv(d,v)},l.prototype.div=function(d){return this.divmod(d,"div",!1).div},l.prototype.mod=function(d){return this.divmod(d,"mod",!1).mod},l.prototype.umod=function(d){return this.divmod(d,"mod",!0).mod},l.prototype.divRound=function(d){var v=this.divmod(d);if(v.mod.isZero())return v.div;var w=v.div.negative!==0?v.mod.isub(d):v.mod,c=d.ushrn(1),p=d.andln(1),x=w.cmp(c);return x<0||p===1&&x===0?v.div:v.div.negative!==0?v.div.isubn(1):v.div.iaddn(1)},l.prototype.modn=function(d){o(d<=67108863);for(var v=(1<<26)%d,w=0,c=this.length-1;c>=0;c--)w=(v*w+(this.words[c]|0))%d;return w},l.prototype.idivn=function(d){o(d<=67108863);for(var v=0,w=this.length-1;w>=0;w--){var c=(this.words[w]|0)+v*67108864;this.words[w]=c/d|0,v=c%d}return this.strip()},l.prototype.divn=function(d){return this.clone().idivn(d)},l.prototype.egcd=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=new l(0),S=new l(1),b=0;v.isEven()&&w.isEven();)v.iushrn(1),w.iushrn(1),++b;for(var h=w.clone(),T=v.clone();!v.isZero();){for(var M=0,O=1;!(v.words[0]&O)&&M<26;++M,O<<=1);if(M>0)for(v.iushrn(M);M-- >0;)(c.isOdd()||p.isOdd())&&(c.iadd(h),p.isub(T)),c.iushrn(1),p.iushrn(1);for(var V=0,ee=1;!(w.words[0]&ee)&&V<26;++V,ee<<=1);if(V>0)for(w.iushrn(V);V-- >0;)(x.isOdd()||S.isOdd())&&(x.iadd(h),S.isub(T)),x.iushrn(1),S.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(x),p.isub(S)):(w.isub(v),x.isub(c),S.isub(p))}return{a:x,b:S,gcd:w.iushln(b)}},l.prototype._invmp=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=w.clone();v.cmpn(1)>0&&w.cmpn(1)>0;){for(var S=0,b=1;!(v.words[0]&b)&&S<26;++S,b<<=1);if(S>0)for(v.iushrn(S);S-- >0;)c.isOdd()&&c.iadd(x),c.iushrn(1);for(var h=0,T=1;!(w.words[0]&T)&&h<26;++h,T<<=1);if(h>0)for(w.iushrn(h);h-- >0;)p.isOdd()&&p.iadd(x),p.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(p)):(w.isub(v),p.isub(c))}var M;return v.cmpn(1)===0?M=c:M=p,M.cmpn(0)<0&&M.iadd(d),M},l.prototype.gcd=function(d){if(this.isZero())return d.abs();if(d.isZero())return this.abs();var v=this.clone(),w=d.clone();v.negative=0,w.negative=0;for(var c=0;v.isEven()&&w.isEven();c++)v.iushrn(1),w.iushrn(1);do{for(;v.isEven();)v.iushrn(1);for(;w.isEven();)w.iushrn(1);var p=v.cmp(w);if(p<0){var x=v;v=w,w=x}else if(p===0||w.cmpn(1)===0)break;v.isub(w)}while(!0);return w.iushln(c)},l.prototype.invm=function(d){return this.egcd(d).a.umod(d)},l.prototype.isEven=function(){return(this.words[0]&1)===0},l.prototype.isOdd=function(){return(this.words[0]&1)===1},l.prototype.andln=function(d){return this.words[0]&d},l.prototype.bincn=function(d){o(typeof d=="number");var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return this._expand(w+1),this.words[w]|=c,this;for(var p=c,x=w;p!==0&&x<this.length;x++){var S=this.words[x]|0;S+=p,p=S>>>26,S&=67108863,this.words[x]=S}return p!==0&&(this.words[x]=p,this.length++),this},l.prototype.isZero=function(){return this.length===1&&this.words[0]===0},l.prototype.cmpn=function(d){var v=d<0;if(this.negative!==0&&!v)return-1;if(this.negative===0&&v)return 1;this.strip();var w;if(this.length>1)w=1;else{v&&(d=-d),o(d<=67108863,"Number is too big");var c=this.words[0]|0;w=c===d?0:c<d?-1:1}return this.negative!==0?-w|0:w},l.prototype.cmp=function(d){if(this.negative!==0&&d.negative===0)return-1;if(this.negative===0&&d.negative!==0)return 1;var v=this.ucmp(d);return this.negative!==0?-v|0:v},l.prototype.ucmp=function(d){if(this.length>d.length)return 1;if(this.length<d.length)return-1;for(var v=0,w=this.length-1;w>=0;w--){var c=this.words[w]|0,p=d.words[w]|0;if(c!==p){c<p?v=-1:c>p&&(v=1);break}}return v},l.prototype.gtn=function(d){return this.cmpn(d)===1},l.prototype.gt=function(d){return this.cmp(d)===1},l.prototype.gten=function(d){return this.cmpn(d)>=0},l.prototype.gte=function(d){return this.cmp(d)>=0},l.prototype.ltn=function(d){return this.cmpn(d)===-1},l.prototype.lt=function(d){return this.cmp(d)===-1},l.prototype.lten=function(d){return this.cmpn(d)<=0},l.prototype.lte=function(d){return this.cmp(d)<=0},l.prototype.eqn=function(d){return this.cmpn(d)===0},l.prototype.eq=function(d){return this.cmp(d)===0},l.red=function(d){return new he(d)},l.prototype.toRed=function(d){return o(!this.red,"Already a number in reduction context"),o(this.negative===0,"red works only with positives"),d.convertTo(this)._forceRed(d)},l.prototype.fromRed=function(){return o(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},l.prototype._forceRed=function(d){return this.red=d,this},l.prototype.forceRed=function(d){return o(!this.red,"Already a number in reduction context"),this._forceRed(d)},l.prototype.redAdd=function(d){return o(this.red,"redAdd works only with red numbers"),this.red.add(this,d)},l.prototype.redIAdd=function(d){return o(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,d)},l.prototype.redSub=function(d){return o(this.red,"redSub works only with red numbers"),this.red.sub(this,d)},l.prototype.redISub=function(d){return o(this.red,"redISub works only with red numbers"),this.red.isub(this,d)},l.prototype.redShl=function(d){return o(this.red,"redShl works only with red numbers"),this.red.shl(this,d)},l.prototype.redMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.mul(this,d)},l.prototype.redIMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.imul(this,d)},l.prototype.redSqr=function(){return o(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},l.prototype.redISqr=function(){return o(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},l.prototype.redSqrt=function(){return o(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},l.prototype.redInvm=function(){return o(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},l.prototype.redNeg=function(){return o(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},l.prototype.redPow=function(d){return o(this.red&&!d.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,d)};var Y={k256:null,p224:null,p192:null,p25519:null};function J(L,d){this.name=L,this.p=new l(d,16),this.n=this.p.bitLength(),this.k=new l(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}J.prototype._tmp=function(){var d=new l(null);return d.words=new Array(Math.ceil(this.n/13)),d},J.prototype.ireduce=function(d){var v=d,w;do this.split(v,this.tmp),v=this.imulK(v),v=v.iadd(this.tmp),w=v.bitLength();while(w>this.n);var c=w<this.n?-1:v.ucmp(this.p);return c===0?(v.words[0]=0,v.length=1):c>0?v.isub(this.p):v.strip!==void 0?v.strip():v._strip(),v},J.prototype.split=function(d,v){d.iushrn(this.n,0,v)},J.prototype.imulK=function(d){return d.imul(this.k)};function ie(){J.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}u(ie,J),ie.prototype.split=function(d,v){for(var w=4194303,c=Math.min(d.length,9),p=0;p<c;p++)v.words[p]=d.words[p];if(v.length=c,d.length<=9){d.words[0]=0,d.length=1;return}var x=d.words[9];for(v.words[v.length++]=x&w,p=10;p<d.length;p++){var S=d.words[p]|0;d.words[p-10]=(S&w)<<4|x>>>22,x=S}x>>>=22,d.words[p-10]=x,x===0&&d.length>10?d.length-=10:d.length-=9},ie.prototype.imulK=function(d){d.words[d.length]=0,d.words[d.length+1]=0,d.length+=2;for(var v=0,w=0;w<d.length;w++){var c=d.words[w]|0;v+=c*977,d.words[w]=v&67108863,v=c*64+(v/67108864|0)}return d.words[d.length-1]===0&&(d.length--,d.words[d.length-1]===0&&d.length--),d};function ue(){J.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}u(ue,J);function Q(){J.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}u(Q,J);function ce(){J.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}u(ce,J),ce.prototype.imulK=function(d){for(var v=0,w=0;w<d.length;w++){var c=(d.words[w]|0)*19+v,p=c&67108863;c>>>=26,d.words[w]=p,v=c}return v!==0&&(d.words[d.length++]=v),d},l._prime=function(d){if(Y[d])return Y[d];var v;if(d==="k256")v=new ie;else if(d==="p224")v=new ue;else if(d==="p192")v=new Q;else if(d==="p25519")v=new ce;else throw new Error("Unknown prime "+d);return Y[d]=v,v};function he(L){if(typeof L=="string"){var d=l._prime(L);this.m=d.p,this.prime=d}else o(L.gtn(1),"modulus must be greater than 1"),this.m=L,this.prime=null}he.prototype._verify1=function(d){o(d.negative===0,"red works only with positives"),o(d.red,"red works only with red numbers")},he.prototype._verify2=function(d,v){o((d.negative|v.negative)===0,"red works only with positives"),o(d.red&&d.red===v.red,"red works only with red numbers")},he.prototype.imod=function(d){return this.prime?this.prime.ireduce(d)._forceRed(this):d.umod(this.m)._forceRed(this)},he.prototype.neg=function(d){return d.isZero()?d.clone():this.m.sub(d)._forceRed(this)},he.prototype.add=function(d,v){this._verify2(d,v);var w=d.add(v);return w.cmp(this.m)>=0&&w.isub(this.m),w._forceRed(this)},he.prototype.iadd=function(d,v){this._verify2(d,v);var w=d.iadd(v);return w.cmp(this.m)>=0&&w.isub(this.m),w},he.prototype.sub=function(d,v){this._verify2(d,v);var w=d.sub(v);return w.cmpn(0)<0&&w.iadd(this.m),w._forceRed(this)},he.prototype.isub=function(d,v){this._verify2(d,v);var w=d.isub(v);return w.cmpn(0)<0&&w.iadd(this.m),w},he.prototype.shl=function(d,v){return this._verify1(d),this.imod(d.ushln(v))},he.prototype.imul=function(d,v){return this._verify2(d,v),this.imod(d.imul(v))},he.prototype.mul=function(d,v){return this._verify2(d,v),this.imod(d.mul(v))},he.prototype.isqr=function(d){return this.imul(d,d.clone())},he.prototype.sqr=function(d){return this.mul(d,d)},he.prototype.sqrt=function(d){if(d.isZero())return d.clone();var v=this.m.andln(3);if(o(v%2===1),v===3){var w=this.m.add(new l(1)).iushrn(2);return this.pow(d,w)}for(var c=this.m.subn(1),p=0;!c.isZero()&&c.andln(1)===0;)p++,c.iushrn(1);o(!c.isZero());var x=new l(1).toRed(this),S=x.redNeg(),b=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new l(2*h*h).toRed(this);this.pow(h,b).cmp(S)!==0;)h.redIAdd(S);for(var T=this.pow(h,c),M=this.pow(d,c.addn(1).iushrn(1)),O=this.pow(d,c),V=p;O.cmp(x)!==0;){for(var ee=O,Z=0;ee.cmp(x)!==0;Z++)ee=ee.redSqr();o(Z<V);var U=this.pow(T,new l(1).iushln(V-Z-1));M=M.redMul(U),T=U.redSqr(),O=O.redMul(T),V=Z}return M},he.prototype.invm=function(d){var v=d._invmp(this.m);return v.negative!==0?(v.negative=0,this.imod(v).redNeg()):this.imod(v)},he.prototype.pow=function(d,v){if(v.isZero())return new l(1).toRed(this);if(v.cmpn(1)===0)return d.clone();var w=4,c=new Array(1<<w);c[0]=new l(1).toRed(this),c[1]=d;for(var p=2;p<c.length;p++)c[p]=this.mul(c[p-1],d);var x=c[0],S=0,b=0,h=v.bitLength()%26;for(h===0&&(h=26),p=v.length-1;p>=0;p--){for(var T=v.words[p],M=h-1;M>=0;M--){var O=T>>M&1;if(x!==c[0]&&(x=this.sqr(x)),O===0&&S===0){b=0;continue}S<<=1,S|=O,b++,!(b!==w&&(p!==0||M!==0))&&(x=this.mul(x,c[S]),b=0,S=0)}h=26}return x},he.prototype.convertTo=function(d){var v=d.umod(this.m);return v===d?v.clone():v},he.prototype.convertFrom=function(d){var v=d.clone();return v.red=null,v},l.mont=function(d){return new ke(d)};function ke(L){he.call(this,L),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new l(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}u(ke,he),ke.prototype.convertTo=function(d){return this.imod(d.ushln(this.shift))},ke.prototype.convertFrom=function(d){var v=this.imod(d.mul(this.rinv));return v.red=null,v},ke.prototype.imul=function(d,v){if(d.isZero()||v.isZero())return d.words[0]=0,d.length=1,d;var w=d.imul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.mul=function(d,v){if(d.isZero()||v.isZero())return new l(0)._forceRed(this);var w=d.mul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.invm=function(d){var v=this.imod(d._invmp(this.m).mul(this.r2));return v._forceRed(this)}})(t,commonjsGlobal$1)}(bn$1);var bnExports$1=bn$1.exports,browser$4,hasRequiredBrowser$2;function requireBrowser$2(){if(hasRequiredBrowser$2)return browser$4;hasRequiredBrowser$2=1;var t=requireElliptic(),e=bnExports$1;browser$4=function(m){return new o(m)};var n={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};n.p224=n.secp224r1,n.p256=n.secp256r1=n.prime256v1,n.p192=n.secp192r1=n.prime192v1,n.p384=n.secp384r1,n.p521=n.secp521r1;function o(l){this.curveType=n[l],this.curveType||(this.curveType={name:l}),this.curve=new t.ec(this.curveType.name),this.keys=void 0}o.prototype.generateKeys=function(l,m){return this.keys=this.curve.genKeyPair(),this.getPublicKey(l,m)},o.prototype.computeSecret=function(l,m,y){m=m||"utf8",Buffer$C.isBuffer(l)||(l=new Buffer$C(l,m));var E=this.curve.keyFromPublic(l).getPublic(),C=E.mul(this.keys.getPrivate()).getX();return u(C,y,this.curveType.byteLength)},o.prototype.getPublicKey=function(l,m){var y=this.keys.getPublic(m==="compressed",!0);return m==="hybrid"&&(y[y.length-1]%2?y[0]=7:y[0]=6),u(y,l)},o.prototype.getPrivateKey=function(l){return u(this.keys.getPrivate(),l)},o.prototype.setPublicKey=function(l,m){return m=m||"utf8",Buffer$C.isBuffer(l)||(l=new Buffer$C(l,m)),this.keys._importPublic(l),this},o.prototype.setPrivateKey=function(l,m){m=m||"utf8",Buffer$C.isBuffer(l)||(l=new Buffer$C(l,m));var y=new e(l);return y=y.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(y),this};function u(l,m,y){Array.isArray(l)||(l=l.toArray());var E=new Buffer$C(l);if(y&&E.length<y){var C=new Buffer$C(y-E.length);C.fill(0),E=Buffer$C.concat([C,E])}return m?E.toString(m):E}return browser$4}var browser$3={},createHash$2=browser$b,Buffer$5=safeBufferExports$1.Buffer,mgf$2=function(t,e){for(var n=Buffer$5.alloc(0),o=0,u;n.length<e;)u=i2ops(o++),n=Buffer$5.concat([n,createHash$2("sha1").update(t).update(u).digest()]);return n.slice(0,e)};function i2ops(t){var e=Buffer$5.allocUnsafe(4);return e.writeUInt32BE(t,0),e}var xor$2=function t(e,n){for(var o=e.length,u=-1;++u<o;)e[u]^=n[u];return e},bn={exports:{}};bn.exports,function(t){(function(e,n){function o(L,d){if(!L)throw new Error(d||"Assertion failed")}function u(L,d){L.super_=d;var v=function(){};v.prototype=d.prototype,L.prototype=new v,L.prototype.constructor=L}function l(L,d,v){if(l.isBN(L))return L;this.negative=0,this.words=null,this.length=0,this.red=null,L!==null&&((d==="le"||d==="be")&&(v=d,d=10),this._init(L||0,d||10,v||"be"))}typeof e=="object"?e.exports=l:n.BN=l,l.BN=l,l.wordSize=26;var m;try{typeof window<"u"&&typeof window.Buffer<"u"?m=window.Buffer:m=require$$0$2.Buffer}catch{}l.isBN=function(d){return d instanceof l?!0:d!==null&&typeof d=="object"&&d.constructor.wordSize===l.wordSize&&Array.isArray(d.words)},l.max=function(d,v){return d.cmp(v)>0?d:v},l.min=function(d,v){return d.cmp(v)<0?d:v},l.prototype._init=function(d,v,w){if(typeof d=="number")return this._initNumber(d,v,w);if(typeof d=="object")return this._initArray(d,v,w);v==="hex"&&(v=16),o(v===(v|0)&&v>=2&&v<=36),d=d.toString().replace(/\s+/g,"");var c=0;d[0]==="-"&&(c++,this.negative=1),c<d.length&&(v===16?this._parseHex(d,c,w):(this._parseBase(d,v,c),w==="le"&&this._initArray(this.toArray(),v,w)))},l.prototype._initNumber=function(d,v,w){d<0&&(this.negative=1,d=-d),d<67108864?(this.words=[d&67108863],this.length=1):d<4503599627370496?(this.words=[d&67108863,d/67108864&67108863],this.length=2):(o(d<9007199254740992),this.words=[d&67108863,d/67108864&67108863,1],this.length=3),w==="le"&&this._initArray(this.toArray(),v,w)},l.prototype._initArray=function(d,v,w){if(o(typeof d.length=="number"),d.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(d.length/3),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p,x,S=0;if(w==="be")for(c=d.length-1,p=0;c>=0;c-=3)x=d[c]|d[c-1]<<8|d[c-2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);else if(w==="le")for(c=0,p=0;c<d.length;c+=3)x=d[c]|d[c+1]<<8|d[c+2]<<16,this.words[p]|=x<<S&67108863,this.words[p+1]=x>>>26-S&67108863,S+=24,S>=26&&(S-=26,p++);return this.strip()};function y(L,d){var v=L.charCodeAt(d);return v>=65&&v<=70?v-55:v>=97&&v<=102?v-87:v-48&15}function E(L,d,v){var w=y(L,v);return v-1>=d&&(w|=y(L,v-1)<<4),w}l.prototype._parseHex=function(d,v,w){this.length=Math.ceil((d.length-v)/6),this.words=new Array(this.length);for(var c=0;c<this.length;c++)this.words[c]=0;var p=0,x=0,S;if(w==="be")for(c=d.length-1;c>=v;c-=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8;else{var b=d.length-v;for(c=b%2===0?v+1:v;c<d.length;c+=2)S=E(d,v,c)<<p,this.words[x]|=S&67108863,p>=18?(p-=18,x+=1,this.words[x]|=S>>>26):p+=8}this.strip()};function C(L,d,v,w){for(var c=0,p=Math.min(L.length,v),x=d;x<p;x++){var S=L.charCodeAt(x)-48;c*=w,S>=49?c+=S-49+10:S>=17?c+=S-17+10:c+=S}return c}l.prototype._parseBase=function(d,v,w){this.words=[0],this.length=1;for(var c=0,p=1;p<=67108863;p*=v)c++;c--,p=p/v|0;for(var x=d.length-w,S=x%c,b=Math.min(x,x-S)+w,h=0,T=w;T<b;T+=c)h=C(d,T,T+c,v),this.imuln(p),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h);if(S!==0){var M=1;for(h=C(d,T,d.length,v),T=0;T<S;T++)M*=v;this.imuln(M),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h)}this.strip()},l.prototype.copy=function(d){d.words=new Array(this.length);for(var v=0;v<this.length;v++)d.words[v]=this.words[v];d.length=this.length,d.negative=this.negative,d.red=this.red},l.prototype.clone=function(){var d=new l(null);return this.copy(d),d},l.prototype._expand=function(d){for(;this.length<d;)this.words[this.length++]=0;return this},l.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},l.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},l.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var k=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],D=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];l.prototype.toString=function(d,v){d=d||10,v=v|0||1;var w;if(d===16||d==="hex"){w="";for(var c=0,p=0,x=0;x<this.length;x++){var S=this.words[x],b=((S<<c|p)&16777215).toString(16);p=S>>>24-c&16777215,p!==0||x!==this.length-1?w=k[6-b.length]+b+w:w=b+w,c+=2,c>=26&&(c-=26,x--)}for(p!==0&&(w=p.toString(16)+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}if(d===(d|0)&&d>=2&&d<=36){var h=A[d],T=D[d];w="";var M=this.clone();for(M.negative=0;!M.isZero();){var O=M.modn(T).toString(d);M=M.idivn(T),M.isZero()?w=O+w:w=k[h-O.length]+O+w}for(this.isZero()&&(w="0"+w);w.length%v!==0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}o(!1,"Base should be between 2 and 36")},l.prototype.toNumber=function(){var d=this.words[0];return this.length===2?d+=this.words[1]*67108864:this.length===3&&this.words[2]===1?d+=4503599627370496+this.words[1]*67108864:this.length>2&&o(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-d:d},l.prototype.toJSON=function(){return this.toString(16)},l.prototype.toBuffer=function(d,v){return o(typeof m<"u"),this.toArrayLike(m,d,v)},l.prototype.toArray=function(d,v){return this.toArrayLike(Array,d,v)},l.prototype.toArrayLike=function(d,v,w){var c=this.byteLength(),p=w||Math.max(1,c);o(c<=p,"byte array longer than desired length"),o(p>0,"Requested array length <= 0"),this.strip();var x=v==="le",S=new d(p),b,h,T=this.clone();if(x){for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[h]=b;for(;h<p;h++)S[h]=0}else{for(h=0;h<p-c;h++)S[h]=0;for(h=0;!T.isZero();h++)b=T.andln(255),T.iushrn(8),S[p-h-1]=b}return S},Math.clz32?l.prototype._countBits=function(d){return 32-Math.clz32(d)}:l.prototype._countBits=function(d){var v=d,w=0;return v>=4096&&(w+=13,v>>>=13),v>=64&&(w+=7,v>>>=7),v>=8&&(w+=4,v>>>=4),v>=2&&(w+=2,v>>>=2),w+v},l.prototype._zeroBits=function(d){if(d===0)return 26;var v=d,w=0;return v&8191||(w+=13,v>>>=13),v&127||(w+=7,v>>>=7),v&15||(w+=4,v>>>=4),v&3||(w+=2,v>>>=2),v&1||w++,w},l.prototype.bitLength=function(){var d=this.words[this.length-1],v=this._countBits(d);return(this.length-1)*26+v};function P(L){for(var d=new Array(L.bitLength()),v=0;v<d.length;v++){var w=v/26|0,c=v%26;d[v]=(L.words[w]&1<<c)>>>c}return d}l.prototype.zeroBits=function(){if(this.isZero())return 0;for(var d=0,v=0;v<this.length;v++){var w=this._zeroBits(this.words[v]);if(d+=w,w!==26)break}return d},l.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},l.prototype.toTwos=function(d){return this.negative!==0?this.abs().inotn(d).iaddn(1):this.clone()},l.prototype.fromTwos=function(d){return this.testn(d-1)?this.notn(d).iaddn(1).ineg():this.clone()},l.prototype.isNeg=function(){return this.negative!==0},l.prototype.neg=function(){return this.clone().ineg()},l.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},l.prototype.iuor=function(d){for(;this.length<d.length;)this.words[this.length++]=0;for(var v=0;v<d.length;v++)this.words[v]=this.words[v]|d.words[v];return this.strip()},l.prototype.ior=function(d){return o((this.negative|d.negative)===0),this.iuor(d)},l.prototype.or=function(d){return this.length>d.length?this.clone().ior(d):d.clone().ior(this)},l.prototype.uor=function(d){return this.length>d.length?this.clone().iuor(d):d.clone().iuor(this)},l.prototype.iuand=function(d){var v;this.length>d.length?v=d:v=this;for(var w=0;w<v.length;w++)this.words[w]=this.words[w]&d.words[w];return this.length=v.length,this.strip()},l.prototype.iand=function(d){return o((this.negative|d.negative)===0),this.iuand(d)},l.prototype.and=function(d){return this.length>d.length?this.clone().iand(d):d.clone().iand(this)},l.prototype.uand=function(d){return this.length>d.length?this.clone().iuand(d):d.clone().iuand(this)},l.prototype.iuxor=function(d){var v,w;this.length>d.length?(v=this,w=d):(v=d,w=this);for(var c=0;c<w.length;c++)this.words[c]=v.words[c]^w.words[c];if(this!==v)for(;c<v.length;c++)this.words[c]=v.words[c];return this.length=v.length,this.strip()},l.prototype.ixor=function(d){return o((this.negative|d.negative)===0),this.iuxor(d)},l.prototype.xor=function(d){return this.length>d.length?this.clone().ixor(d):d.clone().ixor(this)},l.prototype.uxor=function(d){return this.length>d.length?this.clone().iuxor(d):d.clone().iuxor(this)},l.prototype.inotn=function(d){o(typeof d=="number"&&d>=0);var v=Math.ceil(d/26)|0,w=d%26;this._expand(v),w>0&&v--;for(var c=0;c<v;c++)this.words[c]=~this.words[c]&67108863;return w>0&&(this.words[c]=~this.words[c]&67108863>>26-w),this.strip()},l.prototype.notn=function(d){return this.clone().inotn(d)},l.prototype.setn=function(d,v){o(typeof d=="number"&&d>=0);var w=d/26|0,c=d%26;return this._expand(w+1),v?this.words[w]=this.words[w]|1<<c:this.words[w]=this.words[w]&~(1<<c),this.strip()},l.prototype.iadd=function(d){var v;if(this.negative!==0&&d.negative===0)return this.negative=0,v=this.isub(d),this.negative^=1,this._normSign();if(this.negative===0&&d.negative!==0)return d.negative=0,v=this.isub(d),d.negative=1,v._normSign();var w,c;this.length>d.length?(w=this,c=d):(w=d,c=this);for(var p=0,x=0;x<c.length;x++)v=(w.words[x]|0)+(c.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;for(;p!==0&&x<w.length;x++)v=(w.words[x]|0)+p,this.words[x]=v&67108863,p=v>>>26;if(this.length=w.length,p!==0)this.words[this.length]=p,this.length++;else if(w!==this)for(;x<w.length;x++)this.words[x]=w.words[x];return this},l.prototype.add=function(d){var v;return d.negative!==0&&this.negative===0?(d.negative=0,v=this.sub(d),d.negative^=1,v):d.negative===0&&this.negative!==0?(this.negative=0,v=d.sub(this),this.negative=1,v):this.length>d.length?this.clone().iadd(d):d.clone().iadd(this)},l.prototype.isub=function(d){if(d.negative!==0){d.negative=0;var v=this.iadd(d);return d.negative=1,v._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(d),this.negative=1,this._normSign();var w=this.cmp(d);if(w===0)return this.negative=0,this.length=1,this.words[0]=0,this;var c,p;w>0?(c=this,p=d):(c=d,p=this);for(var x=0,S=0;S<p.length;S++)v=(c.words[S]|0)-(p.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;for(;x!==0&&S<c.length;S++)v=(c.words[S]|0)+x,x=v>>26,this.words[S]=v&67108863;if(x===0&&S<c.length&&c!==this)for(;S<c.length;S++)this.words[S]=c.words[S];return this.length=Math.max(this.length,S),c!==this&&(this.negative=1),this.strip()},l.prototype.sub=function(d){return this.clone().isub(d)};function R(L,d,v){v.negative=d.negative^L.negative;var w=L.length+d.length|0;v.length=w,w=w-1|0;var c=L.words[0]|0,p=d.words[0]|0,x=c*p,S=x&67108863,b=x/67108864|0;v.words[0]=S;for(var h=1;h<w;h++){for(var T=b>>>26,M=b&67108863,O=Math.min(h,d.length-1),V=Math.max(0,h-L.length+1);V<=O;V++){var ee=h-V|0;c=L.words[ee]|0,p=d.words[V]|0,x=c*p+M,T+=x/67108864|0,M=x&67108863}v.words[h]=M|0,b=T|0}return b!==0?v.words[h]=b|0:v.length--,v.strip()}var B=function(d,v,w){var c=d.words,p=v.words,x=w.words,S=0,b,h,T,M=c[0]|0,O=M&8191,V=M>>>13,ee=c[1]|0,Z=ee&8191,U=ee>>>13,z=c[2]|0,ne=z&8191,fe=z>>>13,me=c[3]|0,de=me&8191,je=me>>>13,lt=c[4]|0,it=lt&8191,ot=lt>>>13,Ct=c[5]|0,nt=Ct&8191,Je=Ct>>>13,tt=c[6]|0,rt=tt&8191,ht=tt>>>13,Ot=c[7]|0,Ve=Ot&8191,We=Ot>>>13,Gt=c[8]|0,wt=Gt&8191,Et=Gt>>>13,Yt=c[9]|0,Ce=Yt&8191,te=Yt>>>13,ye=p[0]|0,Le=ye&8191,Ue=ye>>>13,Qe=p[1]|0,Ke=Qe&8191,De=Qe>>>13,Vt=p[2]|0,At=Vt&8191,ve=Vt>>>13,Pt=p[3]|0,pt=Pt&8191,Ne=Pt>>>13,vt=p[4]|0,ut=vt&8191,$t=vt>>>13,fi=p[5]|0,kt=fi&8191,Wt=fi>>>13,Zi=p[6]|0,Ut=Zi&8191,Xt=Zi>>>13,Be=p[7]|0,be=Be&8191,ge=Be>>>13,oe=p[8]|0,Ae=oe&8191,qe=oe>>>13,bt=p[9]|0,at=bt&8191,gt=bt>>>13;w.negative=d.negative^v.negative,w.length=19,b=Math.imul(O,Le),h=Math.imul(O,Ue),h=h+Math.imul(V,Le)|0,T=Math.imul(V,Ue);var ei=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ei>>>26)|0,ei&=67108863,b=Math.imul(Z,Le),h=Math.imul(Z,Ue),h=h+Math.imul(U,Le)|0,T=Math.imul(U,Ue),b=b+Math.imul(O,Ke)|0,h=h+Math.imul(O,De)|0,h=h+Math.imul(V,Ke)|0,T=T+Math.imul(V,De)|0;var ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ii>>>26)|0,ii&=67108863,b=Math.imul(ne,Le),h=Math.imul(ne,Ue),h=h+Math.imul(fe,Le)|0,T=Math.imul(fe,Ue),b=b+Math.imul(Z,Ke)|0,h=h+Math.imul(Z,De)|0,h=h+Math.imul(U,Ke)|0,T=T+Math.imul(U,De)|0,b=b+Math.imul(O,At)|0,h=h+Math.imul(O,ve)|0,h=h+Math.imul(V,At)|0,T=T+Math.imul(V,ve)|0;var Bi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Bi>>>26)|0,Bi&=67108863,b=Math.imul(de,Le),h=Math.imul(de,Ue),h=h+Math.imul(je,Le)|0,T=Math.imul(je,Ue),b=b+Math.imul(ne,Ke)|0,h=h+Math.imul(ne,De)|0,h=h+Math.imul(fe,Ke)|0,T=T+Math.imul(fe,De)|0,b=b+Math.imul(Z,At)|0,h=h+Math.imul(Z,ve)|0,h=h+Math.imul(U,At)|0,T=T+Math.imul(U,ve)|0,b=b+Math.imul(O,pt)|0,h=h+Math.imul(O,Ne)|0,h=h+Math.imul(V,pt)|0,T=T+Math.imul(V,Ne)|0;var hi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(hi>>>26)|0,hi&=67108863,b=Math.imul(it,Le),h=Math.imul(it,Ue),h=h+Math.imul(ot,Le)|0,T=Math.imul(ot,Ue),b=b+Math.imul(de,Ke)|0,h=h+Math.imul(de,De)|0,h=h+Math.imul(je,Ke)|0,T=T+Math.imul(je,De)|0,b=b+Math.imul(ne,At)|0,h=h+Math.imul(ne,ve)|0,h=h+Math.imul(fe,At)|0,T=T+Math.imul(fe,ve)|0,b=b+Math.imul(Z,pt)|0,h=h+Math.imul(Z,Ne)|0,h=h+Math.imul(U,pt)|0,T=T+Math.imul(U,Ne)|0,b=b+Math.imul(O,ut)|0,h=h+Math.imul(O,$t)|0,h=h+Math.imul(V,ut)|0,T=T+Math.imul(V,$t)|0;var Di=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Di>>>26)|0,Di&=67108863,b=Math.imul(nt,Le),h=Math.imul(nt,Ue),h=h+Math.imul(Je,Le)|0,T=Math.imul(Je,Ue),b=b+Math.imul(it,Ke)|0,h=h+Math.imul(it,De)|0,h=h+Math.imul(ot,Ke)|0,T=T+Math.imul(ot,De)|0,b=b+Math.imul(de,At)|0,h=h+Math.imul(de,ve)|0,h=h+Math.imul(je,At)|0,T=T+Math.imul(je,ve)|0,b=b+Math.imul(ne,pt)|0,h=h+Math.imul(ne,Ne)|0,h=h+Math.imul(fe,pt)|0,T=T+Math.imul(fe,Ne)|0,b=b+Math.imul(Z,ut)|0,h=h+Math.imul(Z,$t)|0,h=h+Math.imul(U,ut)|0,T=T+Math.imul(U,$t)|0,b=b+Math.imul(O,kt)|0,h=h+Math.imul(O,Wt)|0,h=h+Math.imul(V,kt)|0,T=T+Math.imul(V,Wt)|0;var ni=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ni>>>26)|0,ni&=67108863,b=Math.imul(rt,Le),h=Math.imul(rt,Ue),h=h+Math.imul(ht,Le)|0,T=Math.imul(ht,Ue),b=b+Math.imul(nt,Ke)|0,h=h+Math.imul(nt,De)|0,h=h+Math.imul(Je,Ke)|0,T=T+Math.imul(Je,De)|0,b=b+Math.imul(it,At)|0,h=h+Math.imul(it,ve)|0,h=h+Math.imul(ot,At)|0,T=T+Math.imul(ot,ve)|0,b=b+Math.imul(de,pt)|0,h=h+Math.imul(de,Ne)|0,h=h+Math.imul(je,pt)|0,T=T+Math.imul(je,Ne)|0,b=b+Math.imul(ne,ut)|0,h=h+Math.imul(ne,$t)|0,h=h+Math.imul(fe,ut)|0,T=T+Math.imul(fe,$t)|0,b=b+Math.imul(Z,kt)|0,h=h+Math.imul(Z,Wt)|0,h=h+Math.imul(U,kt)|0,T=T+Math.imul(U,Wt)|0,b=b+Math.imul(O,Ut)|0,h=h+Math.imul(O,Xt)|0,h=h+Math.imul(V,Ut)|0,T=T+Math.imul(V,Xt)|0;var pi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(pi>>>26)|0,pi&=67108863,b=Math.imul(Ve,Le),h=Math.imul(Ve,Ue),h=h+Math.imul(We,Le)|0,T=Math.imul(We,Ue),b=b+Math.imul(rt,Ke)|0,h=h+Math.imul(rt,De)|0,h=h+Math.imul(ht,Ke)|0,T=T+Math.imul(ht,De)|0,b=b+Math.imul(nt,At)|0,h=h+Math.imul(nt,ve)|0,h=h+Math.imul(Je,At)|0,T=T+Math.imul(Je,ve)|0,b=b+Math.imul(it,pt)|0,h=h+Math.imul(it,Ne)|0,h=h+Math.imul(ot,pt)|0,T=T+Math.imul(ot,Ne)|0,b=b+Math.imul(de,ut)|0,h=h+Math.imul(de,$t)|0,h=h+Math.imul(je,ut)|0,T=T+Math.imul(je,$t)|0,b=b+Math.imul(ne,kt)|0,h=h+Math.imul(ne,Wt)|0,h=h+Math.imul(fe,kt)|0,T=T+Math.imul(fe,Wt)|0,b=b+Math.imul(Z,Ut)|0,h=h+Math.imul(Z,Xt)|0,h=h+Math.imul(U,Ut)|0,T=T+Math.imul(U,Xt)|0,b=b+Math.imul(O,be)|0,h=h+Math.imul(O,ge)|0,h=h+Math.imul(V,be)|0,T=T+Math.imul(V,ge)|0;var Ii=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ii>>>26)|0,Ii&=67108863,b=Math.imul(wt,Le),h=Math.imul(wt,Ue),h=h+Math.imul(Et,Le)|0,T=Math.imul(Et,Ue),b=b+Math.imul(Ve,Ke)|0,h=h+Math.imul(Ve,De)|0,h=h+Math.imul(We,Ke)|0,T=T+Math.imul(We,De)|0,b=b+Math.imul(rt,At)|0,h=h+Math.imul(rt,ve)|0,h=h+Math.imul(ht,At)|0,T=T+Math.imul(ht,ve)|0,b=b+Math.imul(nt,pt)|0,h=h+Math.imul(nt,Ne)|0,h=h+Math.imul(Je,pt)|0,T=T+Math.imul(Je,Ne)|0,b=b+Math.imul(it,ut)|0,h=h+Math.imul(it,$t)|0,h=h+Math.imul(ot,ut)|0,T=T+Math.imul(ot,$t)|0,b=b+Math.imul(de,kt)|0,h=h+Math.imul(de,Wt)|0,h=h+Math.imul(je,kt)|0,T=T+Math.imul(je,Wt)|0,b=b+Math.imul(ne,Ut)|0,h=h+Math.imul(ne,Xt)|0,h=h+Math.imul(fe,Ut)|0,T=T+Math.imul(fe,Xt)|0,b=b+Math.imul(Z,be)|0,h=h+Math.imul(Z,ge)|0,h=h+Math.imul(U,be)|0,T=T+Math.imul(U,ge)|0,b=b+Math.imul(O,Ae)|0,h=h+Math.imul(O,qe)|0,h=h+Math.imul(V,Ae)|0,T=T+Math.imul(V,qe)|0;var Ci=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ci>>>26)|0,Ci&=67108863,b=Math.imul(Ce,Le),h=Math.imul(Ce,Ue),h=h+Math.imul(te,Le)|0,T=Math.imul(te,Ue),b=b+Math.imul(wt,Ke)|0,h=h+Math.imul(wt,De)|0,h=h+Math.imul(Et,Ke)|0,T=T+Math.imul(Et,De)|0,b=b+Math.imul(Ve,At)|0,h=h+Math.imul(Ve,ve)|0,h=h+Math.imul(We,At)|0,T=T+Math.imul(We,ve)|0,b=b+Math.imul(rt,pt)|0,h=h+Math.imul(rt,Ne)|0,h=h+Math.imul(ht,pt)|0,T=T+Math.imul(ht,Ne)|0,b=b+Math.imul(nt,ut)|0,h=h+Math.imul(nt,$t)|0,h=h+Math.imul(Je,ut)|0,T=T+Math.imul(Je,$t)|0,b=b+Math.imul(it,kt)|0,h=h+Math.imul(it,Wt)|0,h=h+Math.imul(ot,kt)|0,T=T+Math.imul(ot,Wt)|0,b=b+Math.imul(de,Ut)|0,h=h+Math.imul(de,Xt)|0,h=h+Math.imul(je,Ut)|0,T=T+Math.imul(je,Xt)|0,b=b+Math.imul(ne,be)|0,h=h+Math.imul(ne,ge)|0,h=h+Math.imul(fe,be)|0,T=T+Math.imul(fe,ge)|0,b=b+Math.imul(Z,Ae)|0,h=h+Math.imul(Z,qe)|0,h=h+Math.imul(U,Ae)|0,T=T+Math.imul(U,qe)|0,b=b+Math.imul(O,at)|0,h=h+Math.imul(O,gt)|0,h=h+Math.imul(V,at)|0,T=T+Math.imul(V,gt)|0;var zi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zi>>>26)|0,zi&=67108863,b=Math.imul(Ce,Ke),h=Math.imul(Ce,De),h=h+Math.imul(te,Ke)|0,T=Math.imul(te,De),b=b+Math.imul(wt,At)|0,h=h+Math.imul(wt,ve)|0,h=h+Math.imul(Et,At)|0,T=T+Math.imul(Et,ve)|0,b=b+Math.imul(Ve,pt)|0,h=h+Math.imul(Ve,Ne)|0,h=h+Math.imul(We,pt)|0,T=T+Math.imul(We,Ne)|0,b=b+Math.imul(rt,ut)|0,h=h+Math.imul(rt,$t)|0,h=h+Math.imul(ht,ut)|0,T=T+Math.imul(ht,$t)|0,b=b+Math.imul(nt,kt)|0,h=h+Math.imul(nt,Wt)|0,h=h+Math.imul(Je,kt)|0,T=T+Math.imul(Je,Wt)|0,b=b+Math.imul(it,Ut)|0,h=h+Math.imul(it,Xt)|0,h=h+Math.imul(ot,Ut)|0,T=T+Math.imul(ot,Xt)|0,b=b+Math.imul(de,be)|0,h=h+Math.imul(de,ge)|0,h=h+Math.imul(je,be)|0,T=T+Math.imul(je,ge)|0,b=b+Math.imul(ne,Ae)|0,h=h+Math.imul(ne,qe)|0,h=h+Math.imul(fe,Ae)|0,T=T+Math.imul(fe,qe)|0,b=b+Math.imul(Z,at)|0,h=h+Math.imul(Z,gt)|0,h=h+Math.imul(U,at)|0,T=T+Math.imul(U,gt)|0;var qi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(qi>>>26)|0,qi&=67108863,b=Math.imul(Ce,At),h=Math.imul(Ce,ve),h=h+Math.imul(te,At)|0,T=Math.imul(te,ve),b=b+Math.imul(wt,pt)|0,h=h+Math.imul(wt,Ne)|0,h=h+Math.imul(Et,pt)|0,T=T+Math.imul(Et,Ne)|0,b=b+Math.imul(Ve,ut)|0,h=h+Math.imul(Ve,$t)|0,h=h+Math.imul(We,ut)|0,T=T+Math.imul(We,$t)|0,b=b+Math.imul(rt,kt)|0,h=h+Math.imul(rt,Wt)|0,h=h+Math.imul(ht,kt)|0,T=T+Math.imul(ht,Wt)|0,b=b+Math.imul(nt,Ut)|0,h=h+Math.imul(nt,Xt)|0,h=h+Math.imul(Je,Ut)|0,T=T+Math.imul(Je,Xt)|0,b=b+Math.imul(it,be)|0,h=h+Math.imul(it,ge)|0,h=h+Math.imul(ot,be)|0,T=T+Math.imul(ot,ge)|0,b=b+Math.imul(de,Ae)|0,h=h+Math.imul(de,qe)|0,h=h+Math.imul(je,Ae)|0,T=T+Math.imul(je,qe)|0,b=b+Math.imul(ne,at)|0,h=h+Math.imul(ne,gt)|0,h=h+Math.imul(fe,at)|0,T=T+Math.imul(fe,gt)|0;var Ai=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ai>>>26)|0,Ai&=67108863,b=Math.imul(Ce,pt),h=Math.imul(Ce,Ne),h=h+Math.imul(te,pt)|0,T=Math.imul(te,Ne),b=b+Math.imul(wt,ut)|0,h=h+Math.imul(wt,$t)|0,h=h+Math.imul(Et,ut)|0,T=T+Math.imul(Et,$t)|0,b=b+Math.imul(Ve,kt)|0,h=h+Math.imul(Ve,Wt)|0,h=h+Math.imul(We,kt)|0,T=T+Math.imul(We,Wt)|0,b=b+Math.imul(rt,Ut)|0,h=h+Math.imul(rt,Xt)|0,h=h+Math.imul(ht,Ut)|0,T=T+Math.imul(ht,Xt)|0,b=b+Math.imul(nt,be)|0,h=h+Math.imul(nt,ge)|0,h=h+Math.imul(Je,be)|0,T=T+Math.imul(Je,ge)|0,b=b+Math.imul(it,Ae)|0,h=h+Math.imul(it,qe)|0,h=h+Math.imul(ot,Ae)|0,T=T+Math.imul(ot,qe)|0,b=b+Math.imul(de,at)|0,h=h+Math.imul(de,gt)|0,h=h+Math.imul(je,at)|0,T=T+Math.imul(je,gt)|0;var Oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Oi>>>26)|0,Oi&=67108863,b=Math.imul(Ce,ut),h=Math.imul(Ce,$t),h=h+Math.imul(te,ut)|0,T=Math.imul(te,$t),b=b+Math.imul(wt,kt)|0,h=h+Math.imul(wt,Wt)|0,h=h+Math.imul(Et,kt)|0,T=T+Math.imul(Et,Wt)|0,b=b+Math.imul(Ve,Ut)|0,h=h+Math.imul(Ve,Xt)|0,h=h+Math.imul(We,Ut)|0,T=T+Math.imul(We,Xt)|0,b=b+Math.imul(rt,be)|0,h=h+Math.imul(rt,ge)|0,h=h+Math.imul(ht,be)|0,T=T+Math.imul(ht,ge)|0,b=b+Math.imul(nt,Ae)|0,h=h+Math.imul(nt,qe)|0,h=h+Math.imul(Je,Ae)|0,T=T+Math.imul(Je,qe)|0,b=b+Math.imul(it,at)|0,h=h+Math.imul(it,gt)|0,h=h+Math.imul(ot,at)|0,T=T+Math.imul(ot,gt)|0;var ki=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(ki>>>26)|0,ki&=67108863,b=Math.imul(Ce,kt),h=Math.imul(Ce,Wt),h=h+Math.imul(te,kt)|0,T=Math.imul(te,Wt),b=b+Math.imul(wt,Ut)|0,h=h+Math.imul(wt,Xt)|0,h=h+Math.imul(Et,Ut)|0,T=T+Math.imul(Et,Xt)|0,b=b+Math.imul(Ve,be)|0,h=h+Math.imul(Ve,ge)|0,h=h+Math.imul(We,be)|0,T=T+Math.imul(We,ge)|0,b=b+Math.imul(rt,Ae)|0,h=h+Math.imul(rt,qe)|0,h=h+Math.imul(ht,Ae)|0,T=T+Math.imul(ht,qe)|0,b=b+Math.imul(nt,at)|0,h=h+Math.imul(nt,gt)|0,h=h+Math.imul(Je,at)|0,T=T+Math.imul(Je,gt)|0;var Ti=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(Ti>>>26)|0,Ti&=67108863,b=Math.imul(Ce,Ut),h=Math.imul(Ce,Xt),h=h+Math.imul(te,Ut)|0,T=Math.imul(te,Xt),b=b+Math.imul(wt,be)|0,h=h+Math.imul(wt,ge)|0,h=h+Math.imul(Et,be)|0,T=T+Math.imul(Et,ge)|0,b=b+Math.imul(Ve,Ae)|0,h=h+Math.imul(Ve,qe)|0,h=h+Math.imul(We,Ae)|0,T=T+Math.imul(We,qe)|0,b=b+Math.imul(rt,at)|0,h=h+Math.imul(rt,gt)|0,h=h+Math.imul(ht,at)|0,T=T+Math.imul(ht,gt)|0;var wi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(wi>>>26)|0,wi&=67108863,b=Math.imul(Ce,be),h=Math.imul(Ce,ge),h=h+Math.imul(te,be)|0,T=Math.imul(te,ge),b=b+Math.imul(wt,Ae)|0,h=h+Math.imul(wt,qe)|0,h=h+Math.imul(Et,Ae)|0,T=T+Math.imul(Et,qe)|0,b=b+Math.imul(Ve,at)|0,h=h+Math.imul(Ve,gt)|0,h=h+Math.imul(We,at)|0,T=T+Math.imul(We,gt)|0;var oi=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(oi>>>26)|0,oi&=67108863,b=Math.imul(Ce,Ae),h=Math.imul(Ce,qe),h=h+Math.imul(te,Ae)|0,T=Math.imul(te,qe),b=b+Math.imul(wt,at)|0,h=h+Math.imul(wt,gt)|0,h=h+Math.imul(Et,at)|0,T=T+Math.imul(Et,gt)|0;var zt=(S+b|0)+((h&8191)<<13)|0;S=(T+(h>>>13)|0)+(zt>>>26)|0,zt&=67108863,b=Math.imul(Ce,at),h=Math.imul(Ce,gt),h=h+Math.imul(te,at)|0,T=Math.imul(te,gt);var Qt=(S+b|0)+((h&8191)<<13)|0;return S=(T+(h>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,x[0]=ei,x[1]=ii,x[2]=Bi,x[3]=hi,x[4]=Di,x[5]=ni,x[6]=pi,x[7]=Ii,x[8]=Ci,x[9]=zi,x[10]=qi,x[11]=Ai,x[12]=Oi,x[13]=ki,x[14]=Ti,x[15]=wi,x[16]=oi,x[17]=zt,x[18]=Qt,S!==0&&(x[19]=S,w.length++),w};Math.imul||(B=R);function F(L,d,v){v.negative=d.negative^L.negative,v.length=L.length+d.length;for(var w=0,c=0,p=0;p<v.length-1;p++){var x=c;c=0;for(var S=w&67108863,b=Math.min(p,d.length-1),h=Math.max(0,p-L.length+1);h<=b;h++){var T=p-h,M=L.words[T]|0,O=d.words[h]|0,V=M*O,ee=V&67108863;x=x+(V/67108864|0)|0,ee=ee+S|0,S=ee&67108863,x=x+(ee>>>26)|0,c+=x>>>26,x&=67108863}v.words[p]=S,w=x,x=c}return w!==0?v.words[p]=w:v.length--,v.strip()}function j(L,d,v){var w=new N;return w.mulp(L,d,v)}l.prototype.mulTo=function(d,v){var w,c=this.length+d.length;return this.length===10&&d.length===10?w=B(this,d,v):c<63?w=R(this,d,v):c<1024?w=F(this,d,v):w=j(this,d,v),w};function N(L,d){this.x=L,this.y=d}N.prototype.makeRBT=function(d){for(var v=new Array(d),w=l.prototype._countBits(d)-1,c=0;c<d;c++)v[c]=this.revBin(c,w,d);return v},N.prototype.revBin=function(d,v,w){if(d===0||d===w-1)return d;for(var c=0,p=0;p<v;p++)c|=(d&1)<<v-p-1,d>>=1;return c},N.prototype.permute=function(d,v,w,c,p,x){for(var S=0;S<x;S++)c[S]=v[d[S]],p[S]=w[d[S]]},N.prototype.transform=function(d,v,w,c,p,x){this.permute(x,d,v,w,c,p);for(var S=1;S<p;S<<=1)for(var b=S<<1,h=Math.cos(2*Math.PI/b),T=Math.sin(2*Math.PI/b),M=0;M<p;M+=b)for(var O=h,V=T,ee=0;ee<S;ee++){var Z=w[M+ee],U=c[M+ee],z=w[M+ee+S],ne=c[M+ee+S],fe=O*z-V*ne;ne=O*ne+V*z,z=fe,w[M+ee]=Z+z,c[M+ee]=U+ne,w[M+ee+S]=Z-z,c[M+ee+S]=U-ne,ee!==b&&(fe=h*O-T*V,V=h*V+T*O,O=fe)}},N.prototype.guessLen13b=function(d,v){var w=Math.max(v,d)|1,c=w&1,p=0;for(w=w/2|0;w;w=w>>>1)p++;return 1<<p+1+c},N.prototype.conjugate=function(d,v,w){if(!(w<=1))for(var c=0;c<w/2;c++){var p=d[c];d[c]=d[w-c-1],d[w-c-1]=p,p=v[c],v[c]=-v[w-c-1],v[w-c-1]=-p}},N.prototype.normalize13b=function(d,v){for(var w=0,c=0;c<v/2;c++){var p=Math.round(d[2*c+1]/v)*8192+Math.round(d[2*c]/v)+w;d[c]=p&67108863,p<67108864?w=0:w=p/67108864|0}return d},N.prototype.convert13b=function(d,v,w,c){for(var p=0,x=0;x<v;x++)p=p+(d[x]|0),w[2*x]=p&8191,p=p>>>13,w[2*x+1]=p&8191,p=p>>>13;for(x=2*v;x<c;++x)w[x]=0;o(p===0),o((p&-8192)===0)},N.prototype.stub=function(d){for(var v=new Array(d),w=0;w<d;w++)v[w]=0;return v},N.prototype.mulp=function(d,v,w){var c=2*this.guessLen13b(d.length,v.length),p=this.makeRBT(c),x=this.stub(c),S=new Array(c),b=new Array(c),h=new Array(c),T=new Array(c),M=new Array(c),O=new Array(c),V=w.words;V.length=c,this.convert13b(d.words,d.length,S,c),this.convert13b(v.words,v.length,T,c),this.transform(S,x,b,h,c,p),this.transform(T,x,M,O,c,p);for(var ee=0;ee<c;ee++){var Z=b[ee]*M[ee]-h[ee]*O[ee];h[ee]=b[ee]*O[ee]+h[ee]*M[ee],b[ee]=Z}return this.conjugate(b,h,c),this.transform(b,h,V,x,c,p),this.conjugate(V,x,c),this.normalize13b(V,c),w.negative=d.negative^v.negative,w.length=d.length+v.length,w.strip()},l.prototype.mul=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),this.mulTo(d,v)},l.prototype.mulf=function(d){var v=new l(null);return v.words=new Array(this.length+d.length),j(this,d,v)},l.prototype.imul=function(d){return this.clone().mulTo(d,this)},l.prototype.imuln=function(d){o(typeof d=="number"),o(d<67108864);for(var v=0,w=0;w<this.length;w++){var c=(this.words[w]|0)*d,p=(c&67108863)+(v&67108863);v>>=26,v+=c/67108864|0,v+=p>>>26,this.words[w]=p&67108863}return v!==0&&(this.words[w]=v,this.length++),this},l.prototype.muln=function(d){return this.clone().imuln(d)},l.prototype.sqr=function(){return this.mul(this)},l.prototype.isqr=function(){return this.imul(this.clone())},l.prototype.pow=function(d){var v=P(d);if(v.length===0)return new l(1);for(var w=this,c=0;c<v.length&&v[c]===0;c++,w=w.sqr());if(++c<v.length)for(var p=w.sqr();c<v.length;c++,p=p.sqr())v[c]!==0&&(w=w.mul(p));return w},l.prototype.iushln=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=67108863>>>26-v<<26-v,p;if(v!==0){var x=0;for(p=0;p<this.length;p++){var S=this.words[p]&c,b=(this.words[p]|0)-S<<v;this.words[p]=b|x,x=S>>>26-v}x&&(this.words[p]=x,this.length++)}if(w!==0){for(p=this.length-1;p>=0;p--)this.words[p+w]=this.words[p];for(p=0;p<w;p++)this.words[p]=0;this.length+=w}return this.strip()},l.prototype.ishln=function(d){return o(this.negative===0),this.iushln(d)},l.prototype.iushrn=function(d,v,w){o(typeof d=="number"&&d>=0);var c;v?c=(v-v%26)/26:c=0;var p=d%26,x=Math.min((d-p)/26,this.length),S=67108863^67108863>>>p<<p,b=w;if(c-=x,c=Math.max(0,c),b){for(var h=0;h<x;h++)b.words[h]=this.words[h];b.length=x}if(x!==0)if(this.length>x)for(this.length-=x,h=0;h<this.length;h++)this.words[h]=this.words[h+x];else this.words[0]=0,this.length=1;var T=0;for(h=this.length-1;h>=0&&(T!==0||h>=c);h--){var M=this.words[h]|0;this.words[h]=T<<26-p|M>>>p,T=M&S}return b&&T!==0&&(b.words[b.length++]=T),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},l.prototype.ishrn=function(d,v,w){return o(this.negative===0),this.iushrn(d,v,w)},l.prototype.shln=function(d){return this.clone().ishln(d)},l.prototype.ushln=function(d){return this.clone().iushln(d)},l.prototype.shrn=function(d){return this.clone().ishrn(d)},l.prototype.ushrn=function(d){return this.clone().iushrn(d)},l.prototype.testn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return!1;var p=this.words[w];return!!(p&c)},l.prototype.imaskn=function(d){o(typeof d=="number"&&d>=0);var v=d%26,w=(d-v)/26;if(o(this.negative===0,"imaskn works only with positive numbers"),this.length<=w)return this;if(v!==0&&w++,this.length=Math.min(w,this.length),v!==0){var c=67108863^67108863>>>v<<v;this.words[this.length-1]&=c}return this.strip()},l.prototype.maskn=function(d){return this.clone().imaskn(d)},l.prototype.iaddn=function(d){return o(typeof d=="number"),o(d<67108864),d<0?this.isubn(-d):this.negative!==0?this.length===1&&(this.words[0]|0)<d?(this.words[0]=d-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(d),this.negative=1,this):this._iaddn(d)},l.prototype._iaddn=function(d){this.words[0]+=d;for(var v=0;v<this.length&&this.words[v]>=67108864;v++)this.words[v]-=67108864,v===this.length-1?this.words[v+1]=1:this.words[v+1]++;return this.length=Math.max(this.length,v+1),this},l.prototype.isubn=function(d){if(o(typeof d=="number"),o(d<67108864),d<0)return this.iaddn(-d);if(this.negative!==0)return this.negative=0,this.iaddn(d),this.negative=1,this;if(this.words[0]-=d,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var v=0;v<this.length&&this.words[v]<0;v++)this.words[v]+=67108864,this.words[v+1]-=1;return this.strip()},l.prototype.addn=function(d){return this.clone().iaddn(d)},l.prototype.subn=function(d){return this.clone().isubn(d)},l.prototype.iabs=function(){return this.negative=0,this},l.prototype.abs=function(){return this.clone().iabs()},l.prototype._ishlnsubmul=function(d,v,w){var c=d.length+w,p;this._expand(c);var x,S=0;for(p=0;p<d.length;p++){x=(this.words[p+w]|0)+S;var b=(d.words[p]|0)*v;x-=b&67108863,S=(x>>26)-(b/67108864|0),this.words[p+w]=x&67108863}for(;p<this.length-w;p++)x=(this.words[p+w]|0)+S,S=x>>26,this.words[p+w]=x&67108863;if(S===0)return this.strip();for(o(S===-1),S=0,p=0;p<this.length;p++)x=-(this.words[p]|0)+S,S=x>>26,this.words[p]=x&67108863;return this.negative=1,this.strip()},l.prototype._wordDiv=function(d,v){var w=this.length-d.length,c=this.clone(),p=d,x=p.words[p.length-1]|0,S=this._countBits(x);w=26-S,w!==0&&(p=p.ushln(w),c.iushln(w),x=p.words[p.length-1]|0);var b=c.length-p.length,h;if(v!=="mod"){h=new l(null),h.length=b+1,h.words=new Array(h.length);for(var T=0;T<h.length;T++)h.words[T]=0}var M=c.clone()._ishlnsubmul(p,1,b);M.negative===0&&(c=M,h&&(h.words[b]=1));for(var O=b-1;O>=0;O--){var V=(c.words[p.length+O]|0)*67108864+(c.words[p.length+O-1]|0);for(V=Math.min(V/x|0,67108863),c._ishlnsubmul(p,V,O);c.negative!==0;)V--,c.negative=0,c._ishlnsubmul(p,1,O),c.isZero()||(c.negative^=1);h&&(h.words[O]=V)}return h&&h.strip(),c.strip(),v!=="div"&&w!==0&&c.iushrn(w),{div:h||null,mod:c}},l.prototype.divmod=function(d,v,w){if(o(!d.isZero()),this.isZero())return{div:new l(0),mod:new l(0)};var c,p,x;return this.negative!==0&&d.negative===0?(x=this.neg().divmod(d,v),v!=="mod"&&(c=x.div.neg()),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.iadd(d)),{div:c,mod:p}):this.negative===0&&d.negative!==0?(x=this.divmod(d.neg(),v),v!=="mod"&&(c=x.div.neg()),{div:c,mod:x.mod}):this.negative&d.negative?(x=this.neg().divmod(d.neg(),v),v!=="div"&&(p=x.mod.neg(),w&&p.negative!==0&&p.isub(d)),{div:x.div,mod:p}):d.length>this.length||this.cmp(d)<0?{div:new l(0),mod:this}:d.length===1?v==="div"?{div:this.divn(d.words[0]),mod:null}:v==="mod"?{div:null,mod:new l(this.modn(d.words[0]))}:{div:this.divn(d.words[0]),mod:new l(this.modn(d.words[0]))}:this._wordDiv(d,v)},l.prototype.div=function(d){return this.divmod(d,"div",!1).div},l.prototype.mod=function(d){return this.divmod(d,"mod",!1).mod},l.prototype.umod=function(d){return this.divmod(d,"mod",!0).mod},l.prototype.divRound=function(d){var v=this.divmod(d);if(v.mod.isZero())return v.div;var w=v.div.negative!==0?v.mod.isub(d):v.mod,c=d.ushrn(1),p=d.andln(1),x=w.cmp(c);return x<0||p===1&&x===0?v.div:v.div.negative!==0?v.div.isubn(1):v.div.iaddn(1)},l.prototype.modn=function(d){o(d<=67108863);for(var v=(1<<26)%d,w=0,c=this.length-1;c>=0;c--)w=(v*w+(this.words[c]|0))%d;return w},l.prototype.idivn=function(d){o(d<=67108863);for(var v=0,w=this.length-1;w>=0;w--){var c=(this.words[w]|0)+v*67108864;this.words[w]=c/d|0,v=c%d}return this.strip()},l.prototype.divn=function(d){return this.clone().idivn(d)},l.prototype.egcd=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=new l(0),S=new l(1),b=0;v.isEven()&&w.isEven();)v.iushrn(1),w.iushrn(1),++b;for(var h=w.clone(),T=v.clone();!v.isZero();){for(var M=0,O=1;!(v.words[0]&O)&&M<26;++M,O<<=1);if(M>0)for(v.iushrn(M);M-- >0;)(c.isOdd()||p.isOdd())&&(c.iadd(h),p.isub(T)),c.iushrn(1),p.iushrn(1);for(var V=0,ee=1;!(w.words[0]&ee)&&V<26;++V,ee<<=1);if(V>0)for(w.iushrn(V);V-- >0;)(x.isOdd()||S.isOdd())&&(x.iadd(h),S.isub(T)),x.iushrn(1),S.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(x),p.isub(S)):(w.isub(v),x.isub(c),S.isub(p))}return{a:x,b:S,gcd:w.iushln(b)}},l.prototype._invmp=function(d){o(d.negative===0),o(!d.isZero());var v=this,w=d.clone();v.negative!==0?v=v.umod(d):v=v.clone();for(var c=new l(1),p=new l(0),x=w.clone();v.cmpn(1)>0&&w.cmpn(1)>0;){for(var S=0,b=1;!(v.words[0]&b)&&S<26;++S,b<<=1);if(S>0)for(v.iushrn(S);S-- >0;)c.isOdd()&&c.iadd(x),c.iushrn(1);for(var h=0,T=1;!(w.words[0]&T)&&h<26;++h,T<<=1);if(h>0)for(w.iushrn(h);h-- >0;)p.isOdd()&&p.iadd(x),p.iushrn(1);v.cmp(w)>=0?(v.isub(w),c.isub(p)):(w.isub(v),p.isub(c))}var M;return v.cmpn(1)===0?M=c:M=p,M.cmpn(0)<0&&M.iadd(d),M},l.prototype.gcd=function(d){if(this.isZero())return d.abs();if(d.isZero())return this.abs();var v=this.clone(),w=d.clone();v.negative=0,w.negative=0;for(var c=0;v.isEven()&&w.isEven();c++)v.iushrn(1),w.iushrn(1);do{for(;v.isEven();)v.iushrn(1);for(;w.isEven();)w.iushrn(1);var p=v.cmp(w);if(p<0){var x=v;v=w,w=x}else if(p===0||w.cmpn(1)===0)break;v.isub(w)}while(!0);return w.iushln(c)},l.prototype.invm=function(d){return this.egcd(d).a.umod(d)},l.prototype.isEven=function(){return(this.words[0]&1)===0},l.prototype.isOdd=function(){return(this.words[0]&1)===1},l.prototype.andln=function(d){return this.words[0]&d},l.prototype.bincn=function(d){o(typeof d=="number");var v=d%26,w=(d-v)/26,c=1<<v;if(this.length<=w)return this._expand(w+1),this.words[w]|=c,this;for(var p=c,x=w;p!==0&&x<this.length;x++){var S=this.words[x]|0;S+=p,p=S>>>26,S&=67108863,this.words[x]=S}return p!==0&&(this.words[x]=p,this.length++),this},l.prototype.isZero=function(){return this.length===1&&this.words[0]===0},l.prototype.cmpn=function(d){var v=d<0;if(this.negative!==0&&!v)return-1;if(this.negative===0&&v)return 1;this.strip();var w;if(this.length>1)w=1;else{v&&(d=-d),o(d<=67108863,"Number is too big");var c=this.words[0]|0;w=c===d?0:c<d?-1:1}return this.negative!==0?-w|0:w},l.prototype.cmp=function(d){if(this.negative!==0&&d.negative===0)return-1;if(this.negative===0&&d.negative!==0)return 1;var v=this.ucmp(d);return this.negative!==0?-v|0:v},l.prototype.ucmp=function(d){if(this.length>d.length)return 1;if(this.length<d.length)return-1;for(var v=0,w=this.length-1;w>=0;w--){var c=this.words[w]|0,p=d.words[w]|0;if(c!==p){c<p?v=-1:c>p&&(v=1);break}}return v},l.prototype.gtn=function(d){return this.cmpn(d)===1},l.prototype.gt=function(d){return this.cmp(d)===1},l.prototype.gten=function(d){return this.cmpn(d)>=0},l.prototype.gte=function(d){return this.cmp(d)>=0},l.prototype.ltn=function(d){return this.cmpn(d)===-1},l.prototype.lt=function(d){return this.cmp(d)===-1},l.prototype.lten=function(d){return this.cmpn(d)<=0},l.prototype.lte=function(d){return this.cmp(d)<=0},l.prototype.eqn=function(d){return this.cmpn(d)===0},l.prototype.eq=function(d){return this.cmp(d)===0},l.red=function(d){return new he(d)},l.prototype.toRed=function(d){return o(!this.red,"Already a number in reduction context"),o(this.negative===0,"red works only with positives"),d.convertTo(this)._forceRed(d)},l.prototype.fromRed=function(){return o(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},l.prototype._forceRed=function(d){return this.red=d,this},l.prototype.forceRed=function(d){return o(!this.red,"Already a number in reduction context"),this._forceRed(d)},l.prototype.redAdd=function(d){return o(this.red,"redAdd works only with red numbers"),this.red.add(this,d)},l.prototype.redIAdd=function(d){return o(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,d)},l.prototype.redSub=function(d){return o(this.red,"redSub works only with red numbers"),this.red.sub(this,d)},l.prototype.redISub=function(d){return o(this.red,"redISub works only with red numbers"),this.red.isub(this,d)},l.prototype.redShl=function(d){return o(this.red,"redShl works only with red numbers"),this.red.shl(this,d)},l.prototype.redMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.mul(this,d)},l.prototype.redIMul=function(d){return o(this.red,"redMul works only with red numbers"),this.red._verify2(this,d),this.red.imul(this,d)},l.prototype.redSqr=function(){return o(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},l.prototype.redISqr=function(){return o(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},l.prototype.redSqrt=function(){return o(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},l.prototype.redInvm=function(){return o(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},l.prototype.redNeg=function(){return o(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},l.prototype.redPow=function(d){return o(this.red&&!d.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,d)};var Y={k256:null,p224:null,p192:null,p25519:null};function J(L,d){this.name=L,this.p=new l(d,16),this.n=this.p.bitLength(),this.k=new l(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}J.prototype._tmp=function(){var d=new l(null);return d.words=new Array(Math.ceil(this.n/13)),d},J.prototype.ireduce=function(d){var v=d,w;do this.split(v,this.tmp),v=this.imulK(v),v=v.iadd(this.tmp),w=v.bitLength();while(w>this.n);var c=w<this.n?-1:v.ucmp(this.p);return c===0?(v.words[0]=0,v.length=1):c>0?v.isub(this.p):v.strip!==void 0?v.strip():v._strip(),v},J.prototype.split=function(d,v){d.iushrn(this.n,0,v)},J.prototype.imulK=function(d){return d.imul(this.k)};function ie(){J.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}u(ie,J),ie.prototype.split=function(d,v){for(var w=4194303,c=Math.min(d.length,9),p=0;p<c;p++)v.words[p]=d.words[p];if(v.length=c,d.length<=9){d.words[0]=0,d.length=1;return}var x=d.words[9];for(v.words[v.length++]=x&w,p=10;p<d.length;p++){var S=d.words[p]|0;d.words[p-10]=(S&w)<<4|x>>>22,x=S}x>>>=22,d.words[p-10]=x,x===0&&d.length>10?d.length-=10:d.length-=9},ie.prototype.imulK=function(d){d.words[d.length]=0,d.words[d.length+1]=0,d.length+=2;for(var v=0,w=0;w<d.length;w++){var c=d.words[w]|0;v+=c*977,d.words[w]=v&67108863,v=c*64+(v/67108864|0)}return d.words[d.length-1]===0&&(d.length--,d.words[d.length-1]===0&&d.length--),d};function ue(){J.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}u(ue,J);function Q(){J.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}u(Q,J);function ce(){J.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}u(ce,J),ce.prototype.imulK=function(d){for(var v=0,w=0;w<d.length;w++){var c=(d.words[w]|0)*19+v,p=c&67108863;c>>>=26,d.words[w]=p,v=c}return v!==0&&(d.words[d.length++]=v),d},l._prime=function(d){if(Y[d])return Y[d];var v;if(d==="k256")v=new ie;else if(d==="p224")v=new ue;else if(d==="p192")v=new Q;else if(d==="p25519")v=new ce;else throw new Error("Unknown prime "+d);return Y[d]=v,v};function he(L){if(typeof L=="string"){var d=l._prime(L);this.m=d.p,this.prime=d}else o(L.gtn(1),"modulus must be greater than 1"),this.m=L,this.prime=null}he.prototype._verify1=function(d){o(d.negative===0,"red works only with positives"),o(d.red,"red works only with red numbers")},he.prototype._verify2=function(d,v){o((d.negative|v.negative)===0,"red works only with positives"),o(d.red&&d.red===v.red,"red works only with red numbers")},he.prototype.imod=function(d){return this.prime?this.prime.ireduce(d)._forceRed(this):d.umod(this.m)._forceRed(this)},he.prototype.neg=function(d){return d.isZero()?d.clone():this.m.sub(d)._forceRed(this)},he.prototype.add=function(d,v){this._verify2(d,v);var w=d.add(v);return w.cmp(this.m)>=0&&w.isub(this.m),w._forceRed(this)},he.prototype.iadd=function(d,v){this._verify2(d,v);var w=d.iadd(v);return w.cmp(this.m)>=0&&w.isub(this.m),w},he.prototype.sub=function(d,v){this._verify2(d,v);var w=d.sub(v);return w.cmpn(0)<0&&w.iadd(this.m),w._forceRed(this)},he.prototype.isub=function(d,v){this._verify2(d,v);var w=d.isub(v);return w.cmpn(0)<0&&w.iadd(this.m),w},he.prototype.shl=function(d,v){return this._verify1(d),this.imod(d.ushln(v))},he.prototype.imul=function(d,v){return this._verify2(d,v),this.imod(d.imul(v))},he.prototype.mul=function(d,v){return this._verify2(d,v),this.imod(d.mul(v))},he.prototype.isqr=function(d){return this.imul(d,d.clone())},he.prototype.sqr=function(d){return this.mul(d,d)},he.prototype.sqrt=function(d){if(d.isZero())return d.clone();var v=this.m.andln(3);if(o(v%2===1),v===3){var w=this.m.add(new l(1)).iushrn(2);return this.pow(d,w)}for(var c=this.m.subn(1),p=0;!c.isZero()&&c.andln(1)===0;)p++,c.iushrn(1);o(!c.isZero());var x=new l(1).toRed(this),S=x.redNeg(),b=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new l(2*h*h).toRed(this);this.pow(h,b).cmp(S)!==0;)h.redIAdd(S);for(var T=this.pow(h,c),M=this.pow(d,c.addn(1).iushrn(1)),O=this.pow(d,c),V=p;O.cmp(x)!==0;){for(var ee=O,Z=0;ee.cmp(x)!==0;Z++)ee=ee.redSqr();o(Z<V);var U=this.pow(T,new l(1).iushln(V-Z-1));M=M.redMul(U),T=U.redSqr(),O=O.redMul(T),V=Z}return M},he.prototype.invm=function(d){var v=d._invmp(this.m);return v.negative!==0?(v.negative=0,this.imod(v).redNeg()):this.imod(v)},he.prototype.pow=function(d,v){if(v.isZero())return new l(1).toRed(this);if(v.cmpn(1)===0)return d.clone();var w=4,c=new Array(1<<w);c[0]=new l(1).toRed(this),c[1]=d;for(var p=2;p<c.length;p++)c[p]=this.mul(c[p-1],d);var x=c[0],S=0,b=0,h=v.bitLength()%26;for(h===0&&(h=26),p=v.length-1;p>=0;p--){for(var T=v.words[p],M=h-1;M>=0;M--){var O=T>>M&1;if(x!==c[0]&&(x=this.sqr(x)),O===0&&S===0){b=0;continue}S<<=1,S|=O,b++,!(b!==w&&(p!==0||M!==0))&&(x=this.mul(x,c[S]),b=0,S=0)}h=26}return x},he.prototype.convertTo=function(d){var v=d.umod(this.m);return v===d?v.clone():v},he.prototype.convertFrom=function(d){var v=d.clone();return v.red=null,v},l.mont=function(d){return new ke(d)};function ke(L){he.call(this,L),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new l(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}u(ke,he),ke.prototype.convertTo=function(d){return this.imod(d.ushln(this.shift))},ke.prototype.convertFrom=function(d){var v=this.imod(d.mul(this.rinv));return v.red=null,v},ke.prototype.imul=function(d,v){if(d.isZero()||v.isZero())return d.words[0]=0,d.length=1,d;var w=d.imul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.mul=function(d,v){if(d.isZero()||v.isZero())return new l(0)._forceRed(this);var w=d.mul(v),c=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),p=w.isub(c).iushrn(this.shift),x=p;return p.cmp(this.m)>=0?x=p.isub(this.m):p.cmpn(0)<0&&(x=p.iadd(this.m)),x._forceRed(this)},ke.prototype.invm=function(d){var v=this.imod(d._invmp(this.m).mul(this.r2));return v._forceRed(this)}})(t,commonjsGlobal$1)}(bn);var bnExports=bn.exports,BN$2=bnExports,Buffer$4=safeBufferExports$1.Buffer;function withPublic$2(t,e){return Buffer$4.from(t.toRed(BN$2.mont(e.modulus)).redPow(new BN$2(e.publicExponent)).fromRed().toArray())}var withPublic_1=withPublic$2,parseKeys$1=parseAsn1,randomBytes=browserExports,createHash$1=browser$b,mgf$1=mgf$2,xor$1=xor$2,BN$1=bnExports,withPublic$1=withPublic_1,crt$1=browserifyRsa,Buffer$3=safeBufferExports$1.Buffer,publicEncrypt=function t(e,n,o){var u;e.padding?u=e.padding:o?u=1:u=4;var l=parseKeys$1(e),m;if(u===4)m=oaep$1(l,n);else if(u===1)m=pkcs1$2(l,n,o);else if(u===3){if(m=new BN$1(n),m.cmp(l.modulus)>=0)throw new Error("data too long for modulus")}else throw new Error("unknown padding");return o?crt$1(m,l):withPublic$1(m,l)};function oaep$1(t,e){var n=t.modulus.byteLength(),o=e.length,u=createHash$1("sha1").update(Buffer$3.alloc(0)).digest(),l=u.length,m=2*l;if(o>n-m-2)throw new Error("message too long");var y=Buffer$3.alloc(n-o-m-2),E=n-l-1,C=randomBytes(l),k=xor$1(Buffer$3.concat([u,y,Buffer$3.alloc(1,1),e],E),mgf$1(C,E)),A=xor$1(C,mgf$1(k,l));return new BN$1(Buffer$3.concat([Buffer$3.alloc(1),A,k],n))}function pkcs1$2(t,e,n){var o=e.length,u=t.modulus.byteLength();if(o>u-11)throw new Error("message too long");var l;return n?l=Buffer$3.alloc(u-o-3,255):l=nonZero(u-o-3),new BN$1(Buffer$3.concat([Buffer$3.from([0,n?1:2]),l,Buffer$3.alloc(1),e],u))}function nonZero(t){for(var e=Buffer$3.allocUnsafe(t),n=0,o=randomBytes(t*2),u=0,l;n<t;)u===o.length&&(o=randomBytes(t*2),u=0),l=o[u++],l&&(e[n++]=l);return e}var parseKeys=parseAsn1,mgf=mgf$2,xor=xor$2,BN=bnExports,crt=browserifyRsa,createHash=browser$b,withPublic=withPublic_1,Buffer$2=safeBufferExports$1.Buffer,privateDecrypt=function t(e,n,o){var u;e.padding?u=e.padding:o?u=1:u=4;var l=parseKeys(e),m=l.modulus.byteLength();if(n.length>m||new BN(n).cmp(l.modulus)>=0)throw new Error("decryption error");var y;o?y=withPublic(new BN(n),l):y=crt(n,l);var E=Buffer$2.alloc(m-y.length);if(y=Buffer$2.concat([E,y],m),u===4)return oaep(l,y);if(u===1)return pkcs1$1(l,y,o);if(u===3)return y;throw new Error("unknown padding")};function oaep(t,e){var n=t.modulus.byteLength(),o=createHash("sha1").update(Buffer$2.alloc(0)).digest(),u=o.length;if(e[0]!==0)throw new Error("decryption error");var l=e.slice(1,u+1),m=e.slice(u+1),y=xor(l,mgf(m,u)),E=xor(m,mgf(y,n-u-1));if(compare(o,E.slice(0,u)))throw new Error("decryption error");for(var C=u;E[C]===0;)C++;if(E[C++]!==1)throw new Error("decryption error");return E.slice(C)}function pkcs1$1(t,e,n){for(var o=e.slice(0,2),u=2,l=0;e[u++]!==0;)if(u>=e.length){l++;break}var m=e.slice(2,u-1);if((o.toString("hex")!=="0002"&&!n||o.toString("hex")!=="0001"&&n)&&l++,m.length<8&&l++,l)throw new Error("decryption error");return e.slice(u)}function compare(t,e){t=Buffer$2.from(t),e=Buffer$2.from(e);var n=0,o=t.length;t.length!==e.length&&(n++,o=Math.min(t.length,e.length));for(var u=-1;++u<o;)n+=t[u]^e[u];return n}(function(t){t.publicEncrypt=publicEncrypt,t.privateDecrypt=privateDecrypt,t.privateEncrypt=function(n,o){return t.publicEncrypt(n,o,!0)},t.publicDecrypt=function(n,o){return t.privateDecrypt(n,o,!0)}})(browser$3);var browser$2={};function oldBrowser(){throw new Error(`secure random number generation not supported by this browser
use chrome, FireFox or Internet Explorer 11`)}var safeBuffer=safeBufferExports$1,randombytes=browserExports,Buffer$1=safeBuffer.Buffer,kBufferMaxLength=safeBuffer.kMaxLength,crypto$2=commonjsGlobal$1.crypto||commonjsGlobal$1.msCrypto,kMaxUint32=Math.pow(2,32)-1;function assertOffset(t,e){if(typeof t!="number"||t!==t)throw new TypeError("offset must be a number");if(t>kMaxUint32||t<0)throw new TypeError("offset must be a uint32");if(t>kBufferMaxLength||t>e)throw new RangeError("offset out of range")}function assertSize(t,e,n){if(typeof t!="number"||t!==t)throw new TypeError("size must be a number");if(t>kMaxUint32||t<0)throw new TypeError("size must be a uint32");if(t+e>n||t>kBufferMaxLength)throw new RangeError("buffer too small")}crypto$2&&crypto$2.getRandomValues||!process$1.browser?(browser$2.randomFill=randomFill,browser$2.randomFillSync=randomFillSync):(browser$2.randomFill=oldBrowser,browser$2.randomFillSync=oldBrowser);function randomFill(t,e,n,o){if(!Buffer$1.isBuffer(t)&&!(t instanceof commonjsGlobal$1.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof e=="function")o=e,e=0,n=t.length;else if(typeof n=="function")o=n,n=t.length-e;else if(typeof o!="function")throw new TypeError('"cb" argument must be a function');return assertOffset(e,t.length),assertSize(n,e,t.length),actualFill(t,e,n,o)}function actualFill(t,e,n,o){if(process$1.browser){var u=t.buffer,l=new Uint8Array(u,e,n);if(crypto$2.getRandomValues(l),o){process$1.nextTick(function(){o(null,t)});return}return t}if(o){randombytes(n,function(y,E){if(y)return o(y);E.copy(t,e),o(null,t)});return}var m=randombytes(n);return m.copy(t,e),t}function randomFillSync(t,e,n){if(typeof e>"u"&&(e=0),!Buffer$1.isBuffer(t)&&!(t instanceof commonjsGlobal$1.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return assertOffset(e,t.length),n===void 0&&(n=t.length-e),assertSize(n,e,t.length),actualFill(t,e,n)}var hasRequiredCryptoBrowserify;function requireCryptoBrowserify(){if(hasRequiredCryptoBrowserify)return cryptoBrowserify;hasRequiredCryptoBrowserify=1,cryptoBrowserify.randomBytes=cryptoBrowserify.rng=cryptoBrowserify.pseudoRandomBytes=cryptoBrowserify.prng=browserExports,cryptoBrowserify.createHash=cryptoBrowserify.Hash=browser$b,cryptoBrowserify.createHmac=cryptoBrowserify.Hmac=browser$a;var t=algos,e=Object.keys(t),n=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(e);cryptoBrowserify.getHashes=function(){return n};var o=browser$9;cryptoBrowserify.pbkdf2=o.pbkdf2,cryptoBrowserify.pbkdf2Sync=o.pbkdf2Sync;var u=browser$8;cryptoBrowserify.Cipher=u.Cipher,cryptoBrowserify.createCipher=u.createCipher,cryptoBrowserify.Cipheriv=u.Cipheriv,cryptoBrowserify.createCipheriv=u.createCipheriv,cryptoBrowserify.Decipher=u.Decipher,cryptoBrowserify.createDecipher=u.createDecipher,cryptoBrowserify.Decipheriv=u.Decipheriv,cryptoBrowserify.createDecipheriv=u.createDecipheriv,cryptoBrowserify.getCiphers=u.getCiphers,cryptoBrowserify.listCiphers=u.listCiphers;var l=requireBrowser$4();cryptoBrowserify.DiffieHellmanGroup=l.DiffieHellmanGroup,cryptoBrowserify.createDiffieHellmanGroup=l.createDiffieHellmanGroup,cryptoBrowserify.getDiffieHellman=l.getDiffieHellman,cryptoBrowserify.createDiffieHellman=l.createDiffieHellman,cryptoBrowserify.DiffieHellman=l.DiffieHellman;var m=requireBrowser$3();cryptoBrowserify.createSign=m.createSign,cryptoBrowserify.Sign=m.Sign,cryptoBrowserify.createVerify=m.createVerify,cryptoBrowserify.Verify=m.Verify,cryptoBrowserify.createECDH=requireBrowser$2();var y=browser$3;cryptoBrowserify.publicEncrypt=y.publicEncrypt,cryptoBrowserify.privateEncrypt=y.privateEncrypt,cryptoBrowserify.publicDecrypt=y.publicDecrypt,cryptoBrowserify.privateDecrypt=y.privateDecrypt;var E=browser$2;return cryptoBrowserify.randomFill=E.randomFill,cryptoBrowserify.randomFillSync=E.randomFillSync,cryptoBrowserify.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join(`
`))},cryptoBrowserify.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6},cryptoBrowserify}var jsonSafeStringify=stringifyExports,crypto$1=requireCryptoBrowserify(),Buffer=safeBufferExports$1.Buffer,defer=typeof setImmediate>"u"?process$1.nextTick:setImmediate;function paramsHaveRequestBody$1(t){return t.body||t.requestBodyStream||t.json&&typeof t.json!="boolean"||t.multipart}function safeStringify(t,e){var n;try{n=JSON.stringify(t,e)}catch{n=jsonSafeStringify(t,e)}return n}function md5(t){return crypto$1.createHash("md5").update(t).digest("hex")}function isReadStream(t){return t.readable&&t.path&&t.mode}function toBase64(t){return Buffer.from(t||"","utf8").toString("base64")}function copy(t){var e={};return Object.keys(t).forEach(function(n){e[n]=t[n]}),e}function version(){var t=process$1.version.replace("v","").split(".");return{major:parseInt(t[0],10),minor:parseInt(t[1],10),patch:parseInt(t[2],10)}}helpers$1.paramsHaveRequestBody=paramsHaveRequestBody$1,helpers$1.safeStringify=safeStringify,helpers$1.md5=md5,helpers$1.isReadStream=isReadStream,helpers$1.toBase64=toBase64,helpers$1.copy=copy,helpers$1.version=version,helpers$1.defer=defer;var streamHttp={},request$3={exports:{}},capability={},hasRequiredCapability;function requireCapability(){return hasRequiredCapability||(hasRequiredCapability=1,function(t){t.fetch=u(commonjsGlobal$1.fetch)&&u(commonjsGlobal$1.ReadableStream),t.writableStream=u(commonjsGlobal$1.WritableStream),t.abortController=u(commonjsGlobal$1.AbortController);var e;function n(){if(e!==void 0)return e;if(commonjsGlobal$1.XMLHttpRequest){e=new commonjsGlobal$1.XMLHttpRequest;try{e.open("GET",commonjsGlobal$1.XDomainRequest?"/":"https://example.com")}catch{e=null}}else e=null;return e}function o(l){var m=n();if(!m)return!1;try{return m.responseType=l,m.responseType===l}catch{}return!1}t.arraybuffer=t.fetch||o("arraybuffer"),t.msstream=!t.fetch&&o("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&o("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||(n()?u(n().overrideMimeType):!1);function u(l){return typeof l=="function"}e=null}(capability)),capability}var response={},readableBrowser={exports:{}},hasRequiredReadableBrowser;function requireReadableBrowser(){return hasRequiredReadableBrowser||(hasRequiredReadableBrowser=1,function(t,e){e=t.exports=require_stream_readable$1(),e.Stream=e,e.Readable=e,e.Writable=require_stream_writable$1(),e.Duplex=require_stream_duplex$1(),e.Transform=require_stream_transform(),e.PassThrough=require_stream_passthrough(),e.finished=requireEndOfStream(),e.pipeline=requirePipeline()}(readableBrowser,readableBrowser.exports)),readableBrowser.exports}var hasRequiredResponse;function requireResponse(){if(hasRequiredResponse)return response;hasRequiredResponse=1;var t=requireCapability(),e=inherits_browserExports,n=requireReadableBrowser(),o=response.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},u=response.IncomingMessage=function(l,m,y,E){var C=this;if(n.Readable.call(C),C._mode=y,C.headers={},C.rawHeaders=[],C.trailers={},C.rawTrailers=[],C.on("end",function(){process$1.nextTick(function(){C.emit("close")})}),y==="fetch"){let B=function(){A.read().then(function(F){if(!C._destroyed){if(E(F.done),F.done){C.push(null);return}C.push(Buffer$C.from(F.value)),B()}}).catch(function(F){E(!0),C._destroyed||C.emit("error",F)})};if(C._fetchResponse=m,C.url=m.url,C.statusCode=m.status,C.statusMessage=m.statusText,m.headers.forEach(function(F,j){C.headers[j.toLowerCase()]=F,C.rawHeaders.push(j,F)}),t.writableStream){var k=new WritableStream({write:function(F){return E(!1),new Promise(function(j,N){C._destroyed?N():C.push(Buffer$C.from(F))?j():C._resumeFetch=j})},close:function(){E(!0),C._destroyed||C.push(null)},abort:function(F){E(!0),C._destroyed||C.emit("error",F)}});try{m.body.pipeTo(k).catch(function(F){E(!0),C._destroyed||C.emit("error",F)});return}catch{}}var A=m.body.getReader();B()}else{C._xhr=l,C._pos=0,C.url=l.responseURL,C.statusCode=l.status,C.statusMessage=l.statusText;var D=l.getAllResponseHeaders().split(/\r?\n/);if(D.forEach(function(B){var F=B.match(/^([^:]+):\s*(.*)/);if(F){var j=F[1].toLowerCase();j==="set-cookie"?(C.headers[j]===void 0&&(C.headers[j]=[]),C.headers[j].push(F[2])):C.headers[j]!==void 0?C.headers[j]+=", "+F[2]:C.headers[j]=F[2],C.rawHeaders.push(F[1],F[2])}}),C._charset="x-user-defined",!t.overrideMimeType){var P=C.rawHeaders["mime-type"];if(P){var R=P.match(/;\s*charset=([^;])(;|$)/);R&&(C._charset=R[1].toLowerCase())}C._charset||(C._charset="utf-8")}}};return e(u,n.Readable),u.prototype._read=function(){var l=this,m=l._resumeFetch;m&&(l._resumeFetch=null,m())},u.prototype._onXHRProgress=function(l){var m=this,y=m._xhr,E=null;switch(m._mode){case"text":if(E=y.responseText,E.length>m._pos){var C=E.substr(m._pos);if(m._charset==="x-user-defined"){for(var k=Buffer$C.alloc(C.length),A=0;A<C.length;A++)k[A]=C.charCodeAt(A)&255;m.push(k)}else m.push(C,m._charset);m._pos=E.length}break;case"arraybuffer":if(y.readyState!==o.DONE||!y.response)break;E=y.response,m.push(Buffer$C.from(new Uint8Array(E)));break;case"moz-chunked-arraybuffer":if(E=y.response,y.readyState!==o.LOADING||!E)break;m.push(Buffer$C.from(new Uint8Array(E)));break;case"ms-stream":if(E=y.response,y.readyState!==o.LOADING)break;var D=new commonjsGlobal$1.MSStreamReader;D.onprogress=function(){D.result.byteLength>m._pos&&(m.push(Buffer$C.from(new Uint8Array(D.result.slice(m._pos)))),m._pos=D.result.byteLength)},D.onload=function(){l(!0),m.push(null)},D.readAsArrayBuffer(E);break}m._xhr.readyState===o.DONE&&m._mode!=="ms-stream"&&(l(!0),m.push(null))},response}var hasRequiredRequest$1;function requireRequest$1(){if(hasRequiredRequest$1)return request$3.exports;hasRequiredRequest$1=1;var t=requireCapability(),e=inherits_browserExports,n=requireResponse(),o=requireReadableBrowser(),u=n.IncomingMessage,l=n.readyStates;function m(k,A){return t.fetch&&A?"fetch":t.mozchunkedarraybuffer?"moz-chunked-arraybuffer":t.msstream?"ms-stream":t.arraybuffer&&k?"arraybuffer":"text"}var y=request$3.exports=function(k){var A=this;o.Writable.call(A),A._opts=k,A._body=[],A._headers={},k.auth&&A.setHeader("Authorization","Basic "+Buffer$C.from(k.auth).toString("base64")),Object.keys(k.headers).forEach(function(R){A.setHeader(R,k.headers[R])});var D,P=!0;if(k.mode==="disable-fetch"||"requestTimeout"in k&&!t.abortController)P=!1,D=!0;else if(k.mode==="prefer-streaming")D=!1;else if(k.mode==="allow-wrong-content-type")D=!t.overrideMimeType;else if(!k.mode||k.mode==="default"||k.mode==="prefer-fast")D=!0;else throw new Error("Invalid value for opts.mode");A._mode=m(D,P),A._fetchTimer=null,A._socketTimeout=null,A._socketTimer=null,A.on("finish",function(){A._onFinish()})};e(y,o.Writable),y.prototype.setHeader=function(k,A){var D=this,P=k.toLowerCase();C.indexOf(P)===-1&&(D._headers[P]={name:k,value:A})},y.prototype.getHeader=function(k){var A=this._headers[k.toLowerCase()];return A?A.value:null},y.prototype.removeHeader=function(k){var A=this;delete A._headers[k.toLowerCase()]},y.prototype._onFinish=function(){var k=this;if(!k._destroyed){var A=k._opts;"timeout"in A&&A.timeout!==0&&k.setTimeout(A.timeout);var D=k._headers,P=null;A.method!=="GET"&&A.method!=="HEAD"&&(P=new Blob(k._body,{type:(D["content-type"]||{}).value||""}));var R=[];if(Object.keys(D).forEach(function(N){var Y=D[N].name,J=D[N].value;Array.isArray(J)?J.forEach(function(ie){R.push([Y,ie])}):R.push([Y,J])}),k._mode==="fetch"){var B=null;if(t.abortController){var F=new AbortController;B=F.signal,k._fetchAbortController=F,"requestTimeout"in A&&A.requestTimeout!==0&&(k._fetchTimer=commonjsGlobal$1.setTimeout(function(){k.emit("requestTimeout"),k._fetchAbortController&&k._fetchAbortController.abort()},A.requestTimeout))}commonjsGlobal$1.fetch(k._opts.url,{method:k._opts.method,headers:R,body:P||void 0,mode:"cors",credentials:A.withCredentials?"include":"same-origin",signal:B}).then(function(N){k._fetchResponse=N,k._resetTimers(!1),k._connect()},function(N){k._resetTimers(!0),k._destroyed||k.emit("error",N)})}else{var j=k._xhr=new commonjsGlobal$1.XMLHttpRequest;try{j.open(k._opts.method,k._opts.url,!0)}catch(N){process$1.nextTick(function(){k.emit("error",N)});return}"responseType"in j&&(j.responseType=k._mode),"withCredentials"in j&&(j.withCredentials=!!A.withCredentials),k._mode==="text"&&"overrideMimeType"in j&&j.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in A&&(j.timeout=A.requestTimeout,j.ontimeout=function(){k.emit("requestTimeout")}),R.forEach(function(N){j.setRequestHeader(N[0],N[1])}),k._response=null,j.onreadystatechange=function(){switch(j.readyState){case l.LOADING:case l.DONE:k._onXHRProgress();break}},k._mode==="moz-chunked-arraybuffer"&&(j.onprogress=function(){k._onXHRProgress()}),j.onerror=function(){k._destroyed||(k._resetTimers(!0),k.emit("error",new Error("XHR error")))};try{j.send(P)}catch(N){process$1.nextTick(function(){k.emit("error",N)});return}}}};function E(k){try{var A=k.status;return A!==null&&A!==0}catch{return!1}}y.prototype._onXHRProgress=function(){var k=this;k._resetTimers(!1),!(!E(k._xhr)||k._destroyed)&&(k._response||k._connect(),k._response._onXHRProgress(k._resetTimers.bind(k)))},y.prototype._connect=function(){var k=this;k._destroyed||(k._response=new u(k._xhr,k._fetchResponse,k._mode,k._resetTimers.bind(k)),k._response.on("error",function(A){k.emit("error",A)}),k.emit("response",k._response))},y.prototype._write=function(k,A,D){var P=this;P._body.push(k),D()},y.prototype._resetTimers=function(k){var A=this;commonjsGlobal$1.clearTimeout(A._socketTimer),A._socketTimer=null,k?(commonjsGlobal$1.clearTimeout(A._fetchTimer),A._fetchTimer=null):A._socketTimeout&&(A._socketTimer=commonjsGlobal$1.setTimeout(function(){A.emit("timeout")},A._socketTimeout))},y.prototype.abort=y.prototype.destroy=function(k){var A=this;A._destroyed=!0,A._resetTimers(!0),A._response&&(A._response._destroyed=!0),A._xhr?A._xhr.abort():A._fetchAbortController&&A._fetchAbortController.abort(),k&&A.emit("error",k)},y.prototype.end=function(k,A,D){var P=this;typeof k=="function"&&(D=k,k=void 0),o.Writable.prototype.end.call(P,k,A,D)},y.prototype.setTimeout=function(k,A){var D=this;A&&D.once("timeout",A),D._socketTimeout=k,D._resetTimers(!1)},y.prototype.flushHeaders=function(){},y.prototype.setNoDelay=function(){},y.prototype.setSocketKeepAlive=function(){};var C=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"];return request$3.exports}var immutable,hasRequiredImmutable;function requireImmutable(){if(hasRequiredImmutable)return immutable;hasRequiredImmutable=1,immutable=e;var t=Object.prototype.hasOwnProperty;function e(){for(var n={},o=0;o<arguments.length;o++){var u=arguments[o];for(var l in u)t.call(u,l)&&(n[l]=u[l])}return n}return immutable}var browser$1,hasRequiredBrowser$1;function requireBrowser$1(){return hasRequiredBrowser$1||(hasRequiredBrowser$1=1,browser$1={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"}),browser$1}var hasRequiredStreamHttp;function requireStreamHttp(){return hasRequiredStreamHttp||(hasRequiredStreamHttp=1,function(t){var e=requireRequest$1(),n=requireResponse(),o=requireImmutable(),u=requireBrowser$1(),l=require$$2$2,m=t;m.request=function(y,E){typeof y=="string"?y=l.parse(y):y=o(y);var C=commonjsGlobal$1.location.protocol.search(/^https?:$/)===-1?"http:":"",k=y.protocol||C,A=y.hostname||y.host,D=y.port,P=y.path||"/";A&&A.indexOf(":")!==-1&&(A="["+A+"]"),y.url=(A?k+"//"+A:"")+(D?":"+D:"")+P,y.method=(y.method||"GET").toUpperCase(),y.headers=y.headers||{};var R=new e(y);return E&&R.on("response",E),R},m.get=function(E,C){var k=m.request(E,C);return k.end(),k},m.ClientRequest=e,m.IncomingMessage=n.IncomingMessage,m.Agent=function(){},m.Agent.defaultMaxSockets=4,m.globalAgent=new m.Agent,m.STATUS_CODES=u,m.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]}(streamHttp)),streamHttp}var httpsBrowserify={exports:{}},hasRequiredHttpsBrowserify;function requireHttpsBrowserify(){return hasRequiredHttpsBrowserify||(hasRequiredHttpsBrowserify=1,function(t){var e=requireStreamHttp(),n=require$$2$2,o=t.exports;for(var u in e)e.hasOwnProperty(u)&&(o[u]=e[u]);o.request=function(m,y){return m=l(m),e.request.call(this,m,y)},o.get=function(m,y){return m=l(m),e.get.call(this,m,y)};function l(m){if(typeof m=="string"&&(m=n.parse(m)),m.protocol||(m.protocol="https:"),m.protocol!=="https:")throw new Error('Protocol "'+m.protocol+'" not supported. Expected "https:"');return m}}(httpsBrowserify)),httpsBrowserify.exports}var lib$5={},binding={},assert={exports:{}},errors$2={},hasRequiredErrors$2;function requireErrors$2(){if(hasRequiredErrors$2)return errors$2;hasRequiredErrors$2=1;function t(N){"@babel/helpers - typeof";return t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Y){return typeof Y}:function(Y){return Y&&typeof Symbol=="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y},t(N)}function e(N,Y,J){return Object.defineProperty(N,"prototype",{writable:!1}),N}function n(N,Y){if(!(N instanceof Y))throw new TypeError("Cannot call a class as a function")}function o(N,Y){if(typeof Y!="function"&&Y!==null)throw new TypeError("Super expression must either be null or a function");N.prototype=Object.create(Y&&Y.prototype,{constructor:{value:N,writable:!0,configurable:!0}}),Object.defineProperty(N,"prototype",{writable:!1}),Y&&u(N,Y)}function u(N,Y){return u=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(ie,ue){return ie.__proto__=ue,ie},u(N,Y)}function l(N){var Y=E();return function(){var ie=C(N),ue;if(Y){var Q=C(this).constructor;ue=Reflect.construct(ie,arguments,Q)}else ue=ie.apply(this,arguments);return m(this,ue)}}function m(N,Y){if(Y&&(t(Y)==="object"||typeof Y=="function"))return Y;if(Y!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return y(N)}function y(N){if(N===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return N}function E(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function C(N){return C=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(J){return J.__proto__||Object.getPrototypeOf(J)},C(N)}var k={},A,D;function P(N,Y,J){J||(J=Error);function ie(Q,ce,he){return typeof Y=="string"?Y:Y(Q,ce,he)}var ue=function(Q){o(he,Q);var ce=l(he);function he(ke,L,d){var v;return n(this,he),v=ce.call(this,ie(ke,L,d)),v.code=N,v}return e(he)}(J);k[N]=ue}function R(N,Y){if(Array.isArray(N)){var J=N.length;return N=N.map(function(ie){return String(ie)}),J>2?"one of ".concat(Y," ").concat(N.slice(0,J-1).join(", "),", or ")+N[J-1]:J===2?"one of ".concat(Y," ").concat(N[0]," or ").concat(N[1]):"of ".concat(Y," ").concat(N[0])}else return"of ".concat(Y," ").concat(String(N))}function B(N,Y,J){return N.substr(0,Y.length)===Y}function F(N,Y,J){return(J===void 0||J>N.length)&&(J=N.length),N.substring(J-Y.length,J)===Y}function j(N,Y,J){return typeof J!="number"&&(J=0),J+Y.length>N.length?!1:N.indexOf(Y,J)!==-1}return P("ERR_AMBIGUOUS_ARGUMENT",'The "%s" argument is ambiguous. %s',TypeError),P("ERR_INVALID_ARG_TYPE",function(N,Y,J){A===void 0&&(A=requireAssert$1()),A(typeof N=="string","'name' must be a string");var ie;typeof Y=="string"&&B(Y,"not ")?(ie="must not be",Y=Y.replace(/^not /,"")):ie="must be";var ue;if(F(N," argument"))ue="The ".concat(N," ").concat(ie," ").concat(R(Y,"type"));else{var Q=j(N,".")?"property":"argument";ue='The "'.concat(N,'" ').concat(Q," ").concat(ie," ").concat(R(Y,"type"))}return ue+=". Received type ".concat(t(J)),ue},TypeError),P("ERR_INVALID_ARG_VALUE",function(N,Y){var J=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"is invalid";D===void 0&&(D=util$6);var ie=D.inspect(Y);return ie.length>128&&(ie="".concat(ie.slice(0,128),"...")),"The argument '".concat(N,"' ").concat(J,". Received ").concat(ie)},TypeError),P("ERR_INVALID_RETURN_VALUE",function(N,Y,J){var ie;return J&&J.constructor&&J.constructor.name?ie="instance of ".concat(J.constructor.name):ie="type ".concat(t(J)),"Expected ".concat(N,' to be returned from the "').concat(Y,'"')+" function but got ".concat(ie,".")},TypeError),P("ERR_MISSING_ARGS",function(){for(var N=arguments.length,Y=new Array(N),J=0;J<N;J++)Y[J]=arguments[J];A===void 0&&(A=requireAssert$1()),A(Y.length>0,"At least one arg needs to be specified");var ie="The ",ue=Y.length;switch(Y=Y.map(function(Q){return'"'.concat(Q,'"')}),ue){case 1:ie+="".concat(Y[0]," argument");break;case 2:ie+="".concat(Y[0]," and ").concat(Y[1]," arguments");break;default:ie+=Y.slice(0,ue-1).join(", "),ie+=", and ".concat(Y[ue-1]," arguments");break}return"".concat(ie," must be specified")},TypeError),errors$2.codes=k,errors$2}var assertion_error,hasRequiredAssertion_error;function requireAssertion_error(){if(hasRequiredAssertion_error)return assertion_error;hasRequiredAssertion_error=1;function t(b,h){var T=Object.keys(b);if(Object.getOwnPropertySymbols){var M=Object.getOwnPropertySymbols(b);h&&(M=M.filter(function(O){return Object.getOwnPropertyDescriptor(b,O).enumerable})),T.push.apply(T,M)}return T}function e(b){for(var h=1;h<arguments.length;h++){var T=arguments[h]!=null?arguments[h]:{};h%2?t(Object(T),!0).forEach(function(M){n(b,M,T[M])}):Object.getOwnPropertyDescriptors?Object.defineProperties(b,Object.getOwnPropertyDescriptors(T)):t(Object(T)).forEach(function(M){Object.defineProperty(b,M,Object.getOwnPropertyDescriptor(T,M))})}return b}function n(b,h,T){return h=m(h),h in b?Object.defineProperty(b,h,{value:T,enumerable:!0,configurable:!0,writable:!0}):b[h]=T,b}function o(b,h){if(!(b instanceof h))throw new TypeError("Cannot call a class as a function")}function u(b,h){for(var T=0;T<h.length;T++){var M=h[T];M.enumerable=M.enumerable||!1,M.configurable=!0,"value"in M&&(M.writable=!0),Object.defineProperty(b,m(M.key),M)}}function l(b,h,T){return h&&u(b.prototype,h),Object.defineProperty(b,"prototype",{writable:!1}),b}function m(b){var h=y(b,"string");return N(h)==="symbol"?h:String(h)}function y(b,h){if(N(b)!=="object"||b===null)return b;var T=b[Symbol.toPrimitive];if(T!==void 0){var M=T.call(b,h||"default");if(N(M)!=="object")return M;throw new TypeError("@@toPrimitive must return a primitive value.")}return(h==="string"?String:Number)(b)}function E(b,h){if(typeof h!="function"&&h!==null)throw new TypeError("Super expression must either be null or a function");b.prototype=Object.create(h&&h.prototype,{constructor:{value:b,writable:!0,configurable:!0}}),Object.defineProperty(b,"prototype",{writable:!1}),h&&F(b,h)}function C(b){var h=R();return function(){var M=j(b),O;if(h){var V=j(this).constructor;O=Reflect.construct(M,arguments,V)}else O=M.apply(this,arguments);return k(this,O)}}function k(b,h){if(h&&(N(h)==="object"||typeof h=="function"))return h;if(h!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return A(b)}function A(b){if(b===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b}function D(b){var h=typeof Map=="function"?new Map:void 0;return D=function(M){if(M===null||!B(M))return M;if(typeof M!="function")throw new TypeError("Super expression must either be null or a function");if(typeof h<"u"){if(h.has(M))return h.get(M);h.set(M,O)}function O(){return P(M,arguments,j(this).constructor)}return O.prototype=Object.create(M.prototype,{constructor:{value:O,enumerable:!1,writable:!0,configurable:!0}}),F(O,M)},D(b)}function P(b,h,T){return R()?P=Reflect.construct.bind():P=function(O,V,ee){var Z=[null];Z.push.apply(Z,V);var U=Function.bind.apply(O,Z),z=new U;return ee&&F(z,ee.prototype),z},P.apply(null,arguments)}function R(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function B(b){return Function.toString.call(b).indexOf("[native code]")!==-1}function F(b,h){return F=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(M,O){return M.__proto__=O,M},F(b,h)}function j(b){return j=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(T){return T.__proto__||Object.getPrototypeOf(T)},j(b)}function N(b){"@babel/helpers - typeof";return N=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(h){return typeof h}:function(h){return h&&typeof Symbol=="function"&&h.constructor===Symbol&&h!==Symbol.prototype?"symbol":typeof h},N(b)}var Y=util$6,J=Y.inspect,ie=requireErrors$2(),ue=ie.codes.ERR_INVALID_ARG_TYPE;function Q(b,h,T){return(T===void 0||T>b.length)&&(T=b.length),b.substring(T-h.length,T)===h}function ce(b,h){if(h=Math.floor(h),b.length==0||h==0)return"";var T=b.length*h;for(h=Math.floor(Math.log(h)/Math.log(2));h;)b+=b,h--;return b+=b.substring(0,T-b.length),b}var he="",ke="",L="",d="",v={deepStrictEqual:"Expected values to be strictly deep-equal:",strictEqual:"Expected values to be strictly equal:",strictEqualObject:'Expected "actual" to be reference-equal to "expected":',deepEqual:"Expected values to be loosely deep-equal:",equal:"Expected values to be loosely equal:",notDeepStrictEqual:'Expected "actual" not to be strictly deep-equal to:',notStrictEqual:'Expected "actual" to be strictly unequal to:',notStrictEqualObject:'Expected "actual" not to be reference-equal to "expected":',notDeepEqual:'Expected "actual" not to be loosely deep-equal to:',notEqual:'Expected "actual" to be loosely unequal to:',notIdentical:"Values identical but not reference-equal:"},w=10;function c(b){var h=Object.keys(b),T=Object.create(Object.getPrototypeOf(b));return h.forEach(function(M){T[M]=b[M]}),Object.defineProperty(T,"message",{value:b.message}),T}function p(b){return J(b,{compact:!1,customInspect:!1,depth:1e3,maxArrayLength:1/0,showHidden:!1,breakLength:1/0,showProxy:!1,sorted:!0,getters:!0})}function x(b,h,T){var M="",O="",V=0,ee="",Z=!1,U=p(b),z=U.split(`
`),ne=p(h).split(`
`),fe=0,me="";if(T==="strictEqual"&&N(b)==="object"&&N(h)==="object"&&b!==null&&h!==null&&(T="strictEqualObject"),z.length===1&&ne.length===1&&z[0]!==ne[0]){var de=z[0].length+ne[0].length;if(de<=w){if((N(b)!=="object"||b===null)&&(N(h)!=="object"||h===null)&&(b!==0||h!==0))return"".concat(v[T],`

`)+"".concat(z[0]," !== ").concat(ne[0],`
`)}else if(T!=="strictEqualObject"){var je=process$1.stderr&&process$1.stderr.isTTY?process$1.stderr.columns:80;if(de<je){for(;z[0][fe]===ne[0][fe];)fe++;fe>2&&(me=`
  `.concat(ce(" ",fe),"^"),fe=0)}}}for(var lt=z[z.length-1],it=ne[ne.length-1];lt===it&&(fe++<2?ee=`
  `.concat(lt).concat(ee):M=lt,z.pop(),ne.pop(),!(z.length===0||ne.length===0));)lt=z[z.length-1],it=ne[ne.length-1];var ot=Math.max(z.length,ne.length);if(ot===0){var Ct=U.split(`
`);if(Ct.length>30)for(Ct[26]="".concat(he,"...").concat(d);Ct.length>27;)Ct.pop();return"".concat(v.notIdentical,`

`).concat(Ct.join(`
`),`
`)}fe>3&&(ee=`
`.concat(he,"...").concat(d).concat(ee),Z=!0),M!==""&&(ee=`
  `.concat(M).concat(ee),M="");var nt=0,Je=v[T]+`
`.concat(ke,"+ actual").concat(d," ").concat(L,"- expected").concat(d),tt=" ".concat(he,"...").concat(d," Lines skipped");for(fe=0;fe<ot;fe++){var rt=fe-V;if(z.length<fe+1)rt>1&&fe>2&&(rt>4?(O+=`
`.concat(he,"...").concat(d),Z=!0):rt>3&&(O+=`
  `.concat(ne[fe-2]),nt++),O+=`
  `.concat(ne[fe-1]),nt++),V=fe,M+=`
`.concat(L,"-").concat(d," ").concat(ne[fe]),nt++;else if(ne.length<fe+1)rt>1&&fe>2&&(rt>4?(O+=`
`.concat(he,"...").concat(d),Z=!0):rt>3&&(O+=`
  `.concat(z[fe-2]),nt++),O+=`
  `.concat(z[fe-1]),nt++),V=fe,O+=`
`.concat(ke,"+").concat(d," ").concat(z[fe]),nt++;else{var ht=ne[fe],Ot=z[fe],Ve=Ot!==ht&&(!Q(Ot,",")||Ot.slice(0,-1)!==ht);Ve&&Q(ht,",")&&ht.slice(0,-1)===Ot&&(Ve=!1,Ot+=","),Ve?(rt>1&&fe>2&&(rt>4?(O+=`
`.concat(he,"...").concat(d),Z=!0):rt>3&&(O+=`
  `.concat(z[fe-2]),nt++),O+=`
  `.concat(z[fe-1]),nt++),V=fe,O+=`
`.concat(ke,"+").concat(d," ").concat(Ot),M+=`
`.concat(L,"-").concat(d," ").concat(ht),nt+=2):(O+=M,M="",(rt===1||fe===0)&&(O+=`
  `.concat(Ot),nt++))}if(nt>20&&fe<ot-2)return"".concat(Je).concat(tt,`
`).concat(O,`
`).concat(he,"...").concat(d).concat(M,`
`)+"".concat(he,"...").concat(d)}return"".concat(Je).concat(Z?tt:"",`
`).concat(O).concat(M).concat(ee).concat(me)}var S=function(b,h){E(M,b);var T=C(M);function M(O){var V;if(o(this,M),N(O)!=="object"||O===null)throw new ue("options","Object",O);var ee=O.message,Z=O.operator,U=O.stackStartFn,z=O.actual,ne=O.expected,fe=Error.stackTraceLimit;if(Error.stackTraceLimit=0,ee!=null)V=T.call(this,String(ee));else if(process$1.stderr&&process$1.stderr.isTTY&&(process$1.stderr&&process$1.stderr.getColorDepth&&process$1.stderr.getColorDepth()!==1?(he="\x1B[34m",ke="\x1B[32m",d="\x1B[39m",L="\x1B[31m"):(he="",ke="",d="",L="")),N(z)==="object"&&z!==null&&N(ne)==="object"&&ne!==null&&"stack"in z&&z instanceof Error&&"stack"in ne&&ne instanceof Error&&(z=c(z),ne=c(ne)),Z==="deepStrictEqual"||Z==="strictEqual")V=T.call(this,x(z,ne,Z));else if(Z==="notDeepStrictEqual"||Z==="notStrictEqual"){var me=v[Z],de=p(z).split(`
`);if(Z==="notStrictEqual"&&N(z)==="object"&&z!==null&&(me=v.notStrictEqualObject),de.length>30)for(de[26]="".concat(he,"...").concat(d);de.length>27;)de.pop();de.length===1?V=T.call(this,"".concat(me," ").concat(de[0])):V=T.call(this,"".concat(me,`

`).concat(de.join(`
`),`
`))}else{var je=p(z),lt="",it=v[Z];Z==="notDeepEqual"||Z==="notEqual"?(je="".concat(v[Z],`

`).concat(je),je.length>1024&&(je="".concat(je.slice(0,1021),"..."))):(lt="".concat(p(ne)),je.length>512&&(je="".concat(je.slice(0,509),"...")),lt.length>512&&(lt="".concat(lt.slice(0,509),"...")),Z==="deepEqual"||Z==="equal"?je="".concat(it,`

`).concat(je,`

should equal

`):lt=" ".concat(Z," ").concat(lt)),V=T.call(this,"".concat(je).concat(lt))}return Error.stackTraceLimit=fe,V.generatedMessage=!ee,Object.defineProperty(A(V),"name",{value:"AssertionError [ERR_ASSERTION]",enumerable:!1,writable:!0,configurable:!0}),V.code="ERR_ASSERTION",V.actual=z,V.expected=ne,V.operator=Z,Error.captureStackTrace&&Error.captureStackTrace(A(V),U),V.stack,V.name="AssertionError",k(V)}return l(M,[{key:"toString",value:function(){return"".concat(this.name," [").concat(this.code,"]: ").concat(this.message)}},{key:h,value:function(V,ee){return J(this,e(e({},ee),{},{customInspect:!1,depth:0}))}}]),M}(D(Error),J.custom);return assertion_error=S,assertion_error}var isArguments,hasRequiredIsArguments;function requireIsArguments(){if(hasRequiredIsArguments)return isArguments;hasRequiredIsArguments=1;var t=Object.prototype.toString;return isArguments=function(n){var o=t.call(n),u=o==="[object Arguments]";return u||(u=o!=="[object Array]"&&n!==null&&typeof n=="object"&&typeof n.length=="number"&&n.length>=0&&t.call(n.callee)==="[object Function]"),u},isArguments}var implementation$3,hasRequiredImplementation$3;function requireImplementation$3(){if(hasRequiredImplementation$3)return implementation$3;hasRequiredImplementation$3=1;var t;if(!Object.keys){var e=Object.prototype.hasOwnProperty,n=Object.prototype.toString,o=requireIsArguments(),u=Object.prototype.propertyIsEnumerable,l=!u.call({toString:null},"toString"),m=u.call(function(){},"prototype"),y=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],E=function(D){var P=D.constructor;return P&&P.prototype===D},C={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},k=function(){if(typeof window>"u")return!1;for(var D in window)try{if(!C["$"+D]&&e.call(window,D)&&window[D]!==null&&typeof window[D]=="object")try{E(window[D])}catch{return!0}}catch{return!0}return!1}(),A=function(D){if(typeof window>"u"||!k)return E(D);try{return E(D)}catch{return!1}};t=function(P){var R=P!==null&&typeof P=="object",B=n.call(P)==="[object Function]",F=o(P),j=R&&n.call(P)==="[object String]",N=[];if(!R&&!B&&!F)throw new TypeError("Object.keys called on a non-object");var Y=m&&B;if(j&&P.length>0&&!e.call(P,0))for(var J=0;J<P.length;++J)N.push(String(J));if(F&&P.length>0)for(var ie=0;ie<P.length;++ie)N.push(String(ie));else for(var ue in P)!(Y&&ue==="prototype")&&e.call(P,ue)&&N.push(String(ue));if(l)for(var Q=A(P),ce=0;ce<y.length;++ce)!(Q&&y[ce]==="constructor")&&e.call(P,y[ce])&&N.push(y[ce]);return N}}return implementation$3=t,implementation$3}var objectKeys,hasRequiredObjectKeys;function requireObjectKeys(){if(hasRequiredObjectKeys)return objectKeys;hasRequiredObjectKeys=1;var t=Array.prototype.slice,e=requireIsArguments(),n=Object.keys,o=n?function(m){return n(m)}:requireImplementation$3(),u=Object.keys;return o.shim=function(){if(Object.keys){var m=function(){var y=Object.keys(arguments);return y&&y.length===arguments.length}(1,2);m||(Object.keys=function(E){return e(E)?u(t.call(E)):u(E)})}else Object.keys=o;return Object.keys||o},objectKeys=o,objectKeys}var implementation$2,hasRequiredImplementation$2;function requireImplementation$2(){if(hasRequiredImplementation$2)return implementation$2;hasRequiredImplementation$2=1;var t=requireObjectKeys(),e=shams$1(),n=callBound$2,o=Object,u=n("Array.prototype.push"),l=n("Object.prototype.propertyIsEnumerable"),m=e?Object.getOwnPropertySymbols:null;return implementation$2=function(E,C){if(E==null)throw new TypeError("target must be an object");var k=o(E);if(arguments.length===1)return k;for(var A=1;A<arguments.length;++A){var D=o(arguments[A]),P=t(D),R=e&&(Object.getOwnPropertySymbols||m);if(R)for(var B=R(D),F=0;F<B.length;++F){var j=B[F];l(D,j)&&u(P,j)}for(var N=0;N<P.length;++N){var Y=P[N];if(l(D,Y)){var J=D[Y];k[Y]=J}}}return k},implementation$2}var polyfill$2,hasRequiredPolyfill$2;function requirePolyfill$2(){if(hasRequiredPolyfill$2)return polyfill$2;hasRequiredPolyfill$2=1;var t=requireImplementation$2(),e=function(){if(!Object.assign)return!1;for(var o="abcdefghijklmnopqrst",u=o.split(""),l={},m=0;m<u.length;++m)l[u[m]]=u[m];var y=Object.assign({},l),E="";for(var C in y)E+=C;return o!==E},n=function(){if(!Object.assign||!Object.preventExtensions)return!1;var o=Object.preventExtensions({1:2});try{Object.assign(o,"xy")}catch{return o[1]==="y"}return!1};return polyfill$2=function(){return!Object.assign||e()||n()?t:Object.assign},polyfill$2}var implementation$1,hasRequiredImplementation$1;function requireImplementation$1(){if(hasRequiredImplementation$1)return implementation$1;hasRequiredImplementation$1=1;var t=function(e){return e!==e};return implementation$1=function(n,o){return n===0&&o===0?1/n===1/o:!!(n===o||t(n)&&t(o))},implementation$1}var polyfill$1,hasRequiredPolyfill$1;function requirePolyfill$1(){if(hasRequiredPolyfill$1)return polyfill$1;hasRequiredPolyfill$1=1;var t=requireImplementation$1();return polyfill$1=function(){return typeof Object.is=="function"?Object.is:t},polyfill$1}var defineProperties_1,hasRequiredDefineProperties;function requireDefineProperties(){if(hasRequiredDefineProperties)return defineProperties_1;hasRequiredDefineProperties=1;var t=requireObjectKeys(),e=typeof Symbol=="function"&&typeof Symbol("foo")=="symbol",n=Object.prototype.toString,o=Array.prototype.concat,u=defineDataProperty,l=function(C){return typeof C=="function"&&n.call(C)==="[object Function]"},m=hasPropertyDescriptors_1(),y=function(C,k,A,D){if(k in C){if(D===!0){if(C[k]===A)return}else if(!l(D)||!D())return}m?u(C,k,A,!0):u(C,k,A)},E=function(C,k){var A=arguments.length>2?arguments[2]:{},D=t(k);e&&(D=o.call(D,Object.getOwnPropertySymbols(k)));for(var P=0;P<D.length;P+=1)y(C,D[P],k[D[P]],A[D[P]])};return E.supportsDescriptors=!!m,defineProperties_1=E,defineProperties_1}var shim$1,hasRequiredShim$1;function requireShim$1(){if(hasRequiredShim$1)return shim$1;hasRequiredShim$1=1;var t=requirePolyfill$1(),e=requireDefineProperties();return shim$1=function(){var o=t();return e(Object,{is:o},{is:function(){return Object.is!==o}}),o},shim$1}var objectIs,hasRequiredObjectIs;function requireObjectIs(){if(hasRequiredObjectIs)return objectIs;hasRequiredObjectIs=1;var t=requireDefineProperties(),e=callBindExports,n=requireImplementation$1(),o=requirePolyfill$1(),u=requireShim$1(),l=e(o(),Object);return t(l,{getPolyfill:o,implementation:n,shim:u}),objectIs=l,objectIs}var implementation,hasRequiredImplementation;function requireImplementation(){return hasRequiredImplementation||(hasRequiredImplementation=1,implementation=function(e){return e!==e}),implementation}var polyfill,hasRequiredPolyfill;function requirePolyfill(){if(hasRequiredPolyfill)return polyfill;hasRequiredPolyfill=1;var t=requireImplementation();return polyfill=function(){return Number.isNaN&&Number.isNaN(NaN)&&!Number.isNaN("a")?Number.isNaN:t},polyfill}var shim,hasRequiredShim;function requireShim(){if(hasRequiredShim)return shim;hasRequiredShim=1;var t=requireDefineProperties(),e=requirePolyfill();return shim=function(){var o=e();return t(Number,{isNaN:o},{isNaN:function(){return Number.isNaN!==o}}),o},shim}var isNan,hasRequiredIsNan;function requireIsNan(){if(hasRequiredIsNan)return isNan;hasRequiredIsNan=1;var t=callBindExports,e=requireDefineProperties(),n=requireImplementation(),o=requirePolyfill(),u=requireShim(),l=t(o(),Number);return e(l,{getPolyfill:o,implementation:n,shim:u}),isNan=l,isNan}var comparisons,hasRequiredComparisons;function requireComparisons(){if(hasRequiredComparisons)return comparisons;hasRequiredComparisons=1;function t(Ve,We){return l(Ve)||u(Ve,We)||n(Ve,We)||e()}function e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function n(Ve,We){if(Ve){if(typeof Ve=="string")return o(Ve,We);var Gt=Object.prototype.toString.call(Ve).slice(8,-1);if(Gt==="Object"&&Ve.constructor&&(Gt=Ve.constructor.name),Gt==="Map"||Gt==="Set")return Array.from(Ve);if(Gt==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Gt))return o(Ve,We)}}function o(Ve,We){(We==null||We>Ve.length)&&(We=Ve.length);for(var Gt=0,wt=new Array(We);Gt<We;Gt++)wt[Gt]=Ve[Gt];return wt}function u(Ve,We){var Gt=Ve==null?null:typeof Symbol<"u"&&Ve[Symbol.iterator]||Ve["@@iterator"];if(Gt!=null){var wt,Et,Yt,Ce,te=[],ye=!0,Le=!1;try{if(Yt=(Gt=Gt.call(Ve)).next,We!==0)for(;!(ye=(wt=Yt.call(Gt)).done)&&(te.push(wt.value),te.length!==We);ye=!0);}catch(Ue){Le=!0,Et=Ue}finally{try{if(!ye&&Gt.return!=null&&(Ce=Gt.return(),Object(Ce)!==Ce))return}finally{if(Le)throw Et}}return te}}function l(Ve){if(Array.isArray(Ve))return Ve}function m(Ve){"@babel/helpers - typeof";return m=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(We){return typeof We}:function(We){return We&&typeof Symbol=="function"&&We.constructor===Symbol&&We!==Symbol.prototype?"symbol":typeof We},m(Ve)}var y=/a/g.flags!==void 0,E=function(We){var Gt=[];return We.forEach(function(wt){return Gt.push(wt)}),Gt},C=function(We){var Gt=[];return We.forEach(function(wt,Et){return Gt.push([Et,wt])}),Gt},k=Object.is?Object.is:requireObjectIs(),A=Object.getOwnPropertySymbols?Object.getOwnPropertySymbols:function(){return[]},D=Number.isNaN?Number.isNaN:requireIsNan();function P(Ve){return Ve.call.bind(Ve)}var R=P(Object.prototype.hasOwnProperty),B=P(Object.prototype.propertyIsEnumerable),F=P(Object.prototype.toString),j=util$6.types,N=j.isAnyArrayBuffer,Y=j.isArrayBufferView,J=j.isDate,ie=j.isMap,ue=j.isRegExp,Q=j.isSet,ce=j.isNativeError,he=j.isBoxedPrimitive,ke=j.isNumberObject,L=j.isStringObject,d=j.isBooleanObject,v=j.isBigIntObject,w=j.isSymbolObject,c=j.isFloat32Array,p=j.isFloat64Array;function x(Ve){if(Ve.length===0||Ve.length>10)return!0;for(var We=0;We<Ve.length;We++){var Gt=Ve.charCodeAt(We);if(Gt<48||Gt>57)return!0}return Ve.length===10&&Ve>=Math.pow(2,32)}function S(Ve){return Object.keys(Ve).filter(x).concat(A(Ve).filter(Object.prototype.propertyIsEnumerable.bind(Ve)))}/*!
 * The buffer module from node.js, for the browser.
 *
 * @author   Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
 * @license  MIT
 */function b(Ve,We){if(Ve===We)return 0;for(var Gt=Ve.length,wt=We.length,Et=0,Yt=Math.min(Gt,wt);Et<Yt;++Et)if(Ve[Et]!==We[Et]){Gt=Ve[Et],wt=We[Et];break}return Gt<wt?-1:wt<Gt?1:0}var h=!0,T=!1,M=0,O=1,V=2,ee=3;function Z(Ve,We){return y?Ve.source===We.source&&Ve.flags===We.flags:RegExp.prototype.toString.call(Ve)===RegExp.prototype.toString.call(We)}function U(Ve,We){if(Ve.byteLength!==We.byteLength)return!1;for(var Gt=0;Gt<Ve.byteLength;Gt++)if(Ve[Gt]!==We[Gt])return!1;return!0}function z(Ve,We){return Ve.byteLength!==We.byteLength?!1:b(new Uint8Array(Ve.buffer,Ve.byteOffset,Ve.byteLength),new Uint8Array(We.buffer,We.byteOffset,We.byteLength))===0}function ne(Ve,We){return Ve.byteLength===We.byteLength&&b(new Uint8Array(Ve),new Uint8Array(We))===0}function fe(Ve,We){return ke(Ve)?ke(We)&&k(Number.prototype.valueOf.call(Ve),Number.prototype.valueOf.call(We)):L(Ve)?L(We)&&String.prototype.valueOf.call(Ve)===String.prototype.valueOf.call(We):d(Ve)?d(We)&&Boolean.prototype.valueOf.call(Ve)===Boolean.prototype.valueOf.call(We):v(Ve)?v(We)&&BigInt.prototype.valueOf.call(Ve)===BigInt.prototype.valueOf.call(We):w(We)&&Symbol.prototype.valueOf.call(Ve)===Symbol.prototype.valueOf.call(We)}function me(Ve,We,Gt,wt){if(Ve===We)return Ve!==0?!0:Gt?k(Ve,We):!0;if(Gt){if(m(Ve)!=="object")return typeof Ve=="number"&&D(Ve)&&D(We);if(m(We)!=="object"||Ve===null||We===null||Object.getPrototypeOf(Ve)!==Object.getPrototypeOf(We))return!1}else{if(Ve===null||m(Ve)!=="object")return We===null||m(We)!=="object"?Ve==We:!1;if(We===null||m(We)!=="object")return!1}var Et=F(Ve),Yt=F(We);if(Et!==Yt)return!1;if(Array.isArray(Ve)){if(Ve.length!==We.length)return!1;var Ce=S(Ve),te=S(We);return Ce.length!==te.length?!1:je(Ve,We,Gt,wt,O,Ce)}if(Et==="[object Object]"&&(!ie(Ve)&&ie(We)||!Q(Ve)&&Q(We)))return!1;if(J(Ve)){if(!J(We)||Date.prototype.getTime.call(Ve)!==Date.prototype.getTime.call(We))return!1}else if(ue(Ve)){if(!ue(We)||!Z(Ve,We))return!1}else if(ce(Ve)||Ve instanceof Error){if(Ve.message!==We.message||Ve.name!==We.name)return!1}else if(Y(Ve)){if(!Gt&&(c(Ve)||p(Ve))){if(!U(Ve,We))return!1}else if(!z(Ve,We))return!1;var ye=S(Ve),Le=S(We);return ye.length!==Le.length?!1:je(Ve,We,Gt,wt,M,ye)}else{if(Q(Ve))return!Q(We)||Ve.size!==We.size?!1:je(Ve,We,Gt,wt,V);if(ie(Ve))return!ie(We)||Ve.size!==We.size?!1:je(Ve,We,Gt,wt,ee);if(N(Ve)){if(!ne(Ve,We))return!1}else if(he(Ve)&&!fe(Ve,We))return!1}return je(Ve,We,Gt,wt,M)}function de(Ve,We){return We.filter(function(Gt){return B(Ve,Gt)})}function je(Ve,We,Gt,wt,Et,Yt){if(arguments.length===5){Yt=Object.keys(Ve);var Ce=Object.keys(We);if(Yt.length!==Ce.length)return!1}for(var te=0;te<Yt.length;te++)if(!R(We,Yt[te]))return!1;if(Gt&&arguments.length===5){var ye=A(Ve);if(ye.length!==0){var Le=0;for(te=0;te<ye.length;te++){var Ue=ye[te];if(B(Ve,Ue)){if(!B(We,Ue))return!1;Yt.push(Ue),Le++}else if(B(We,Ue))return!1}var Qe=A(We);if(ye.length!==Qe.length&&de(We,Qe).length!==Le)return!1}else{var Ke=A(We);if(Ke.length!==0&&de(We,Ke).length!==0)return!1}}if(Yt.length===0&&(Et===M||Et===O&&Ve.length===0||Ve.size===0))return!0;if(wt===void 0)wt={val1:new Map,val2:new Map,position:0};else{var De=wt.val1.get(Ve);if(De!==void 0){var Vt=wt.val2.get(We);if(Vt!==void 0)return De===Vt}wt.position++}wt.val1.set(Ve,wt.position),wt.val2.set(We,wt.position);var At=rt(Ve,We,Gt,Yt,wt,Et);return wt.val1.delete(Ve),wt.val2.delete(We),At}function lt(Ve,We,Gt,wt){for(var Et=E(Ve),Yt=0;Yt<Et.length;Yt++){var Ce=Et[Yt];if(me(We,Ce,Gt,wt))return Ve.delete(Ce),!0}return!1}function it(Ve){switch(m(Ve)){case"undefined":return null;case"object":return;case"symbol":return!1;case"string":Ve=+Ve;case"number":if(D(Ve))return!1}return!0}function ot(Ve,We,Gt){var wt=it(Gt);return wt??(We.has(wt)&&!Ve.has(wt))}function Ct(Ve,We,Gt,wt,Et){var Yt=it(Gt);if(Yt!=null)return Yt;var Ce=We.get(Yt);return Ce===void 0&&!We.has(Yt)||!me(wt,Ce,!1,Et)?!1:!Ve.has(Yt)&&me(wt,Ce,!1,Et)}function nt(Ve,We,Gt,wt){for(var Et=null,Yt=E(Ve),Ce=0;Ce<Yt.length;Ce++){var te=Yt[Ce];if(m(te)==="object"&&te!==null)Et===null&&(Et=new Set),Et.add(te);else if(!We.has(te)){if(Gt||!ot(Ve,We,te))return!1;Et===null&&(Et=new Set),Et.add(te)}}if(Et!==null){for(var ye=E(We),Le=0;Le<ye.length;Le++){var Ue=ye[Le];if(m(Ue)==="object"&&Ue!==null){if(!lt(Et,Ue,Gt,wt))return!1}else if(!Gt&&!Ve.has(Ue)&&!lt(Et,Ue,Gt,wt))return!1}return Et.size===0}return!0}function Je(Ve,We,Gt,wt,Et,Yt){for(var Ce=E(Ve),te=0;te<Ce.length;te++){var ye=Ce[te];if(me(Gt,ye,Et,Yt)&&me(wt,We.get(ye),Et,Yt))return Ve.delete(ye),!0}return!1}function tt(Ve,We,Gt,wt){for(var Et=null,Yt=C(Ve),Ce=0;Ce<Yt.length;Ce++){var te=t(Yt[Ce],2),ye=te[0],Le=te[1];if(m(ye)==="object"&&ye!==null)Et===null&&(Et=new Set),Et.add(ye);else{var Ue=We.get(ye);if(Ue===void 0&&!We.has(ye)||!me(Le,Ue,Gt,wt)){if(Gt||!Ct(Ve,We,ye,Le,wt))return!1;Et===null&&(Et=new Set),Et.add(ye)}}}if(Et!==null){for(var Qe=C(We),Ke=0;Ke<Qe.length;Ke++){var De=t(Qe[Ke],2),Vt=De[0],At=De[1];if(m(Vt)==="object"&&Vt!==null){if(!Je(Et,Ve,Vt,At,Gt,wt))return!1}else if(!Gt&&(!Ve.has(Vt)||!me(Ve.get(Vt),At,!1,wt))&&!Je(Et,Ve,Vt,At,!1,wt))return!1}return Et.size===0}return!0}function rt(Ve,We,Gt,wt,Et,Yt){var Ce=0;if(Yt===V){if(!nt(Ve,We,Gt,Et))return!1}else if(Yt===ee){if(!tt(Ve,We,Gt,Et))return!1}else if(Yt===O)for(;Ce<Ve.length;Ce++)if(R(Ve,Ce)){if(!R(We,Ce)||!me(Ve[Ce],We[Ce],Gt,Et))return!1}else{if(R(We,Ce))return!1;for(var te=Object.keys(Ve);Ce<te.length;Ce++){var ye=te[Ce];if(!R(We,ye)||!me(Ve[ye],We[ye],Gt,Et))return!1}return te.length===Object.keys(We).length}for(Ce=0;Ce<wt.length;Ce++){var Le=wt[Ce];if(!me(Ve[Le],We[Le],Gt,Et))return!1}return!0}function ht(Ve,We){return me(Ve,We,T)}function Ot(Ve,We){return me(Ve,We,h)}return comparisons={isDeepEqual:ht,isDeepStrictEqual:Ot},comparisons}var hasRequiredAssert$1;function requireAssert$1(){if(hasRequiredAssert$1)return assert.exports;hasRequiredAssert$1=1;function t(V){"@babel/helpers - typeof";return t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ee){return typeof ee}:function(ee){return ee&&typeof Symbol=="function"&&ee.constructor===Symbol&&ee!==Symbol.prototype?"symbol":typeof ee},t(V)}function e(V,ee,Z){return Object.defineProperty(V,"prototype",{writable:!1}),V}function n(V,ee){if(!(V instanceof ee))throw new TypeError("Cannot call a class as a function")}var o=requireErrors$2(),u=o.codes,l=u.ERR_AMBIGUOUS_ARGUMENT,m=u.ERR_INVALID_ARG_TYPE,y=u.ERR_INVALID_ARG_VALUE,E=u.ERR_INVALID_RETURN_VALUE,C=u.ERR_MISSING_ARGS,k=requireAssertion_error(),A=util$6,D=A.inspect,P=util$6.types,R=P.isPromise,B=P.isRegExp,F=requirePolyfill$2()(),j=requirePolyfill$1()(),N=callBound$2("RegExp.prototype.test"),Y,J;function ie(){var V=requireComparisons();Y=V.isDeepEqual,J=V.isDeepStrictEqual}var ue=!1,Q=assert.exports=d,ce={};function he(V){throw V.message instanceof Error?V.message:new k(V)}function ke(V,ee,Z,U,z){var ne=arguments.length,fe;if(ne===0)fe="Failed";else if(ne===1)Z=V,V=void 0;else{if(ue===!1){ue=!0;var me=process$1.emitWarning?process$1.emitWarning:console.warn.bind(console);me("assert.fail() with more than one argument is deprecated. Please use assert.strictEqual() instead or only pass a message.","DeprecationWarning","DEP0094")}ne===2&&(U="!=")}if(Z instanceof Error)throw Z;var de={actual:V,expected:ee,operator:U===void 0?"fail":U,stackStartFn:z||ke};Z!==void 0&&(de.message=Z);var je=new k(de);throw fe&&(je.message=fe,je.generatedMessage=!0),je}Q.fail=ke,Q.AssertionError=k;function L(V,ee,Z,U){if(!Z){var z=!1;if(ee===0)z=!0,U="No value argument passed to `assert.ok()`";else if(U instanceof Error)throw U;var ne=new k({actual:Z,expected:!0,message:U,operator:"==",stackStartFn:V});throw ne.generatedMessage=z,ne}}function d(){for(var V=arguments.length,ee=new Array(V),Z=0;Z<V;Z++)ee[Z]=arguments[Z];L.apply(void 0,[d,ee.length].concat(ee))}Q.ok=d,Q.equal=function V(ee,Z,U){if(arguments.length<2)throw new C("actual","expected");ee!=Z&&he({actual:ee,expected:Z,message:U,operator:"==",stackStartFn:V})},Q.notEqual=function V(ee,Z,U){if(arguments.length<2)throw new C("actual","expected");ee==Z&&he({actual:ee,expected:Z,message:U,operator:"!=",stackStartFn:V})},Q.deepEqual=function V(ee,Z,U){if(arguments.length<2)throw new C("actual","expected");Y===void 0&&ie(),Y(ee,Z)||he({actual:ee,expected:Z,message:U,operator:"deepEqual",stackStartFn:V})},Q.notDeepEqual=function V(ee,Z,U){if(arguments.length<2)throw new C("actual","expected");Y===void 0&&ie(),Y(ee,Z)&&he({actual:ee,expected:Z,message:U,operator:"notDeepEqual",stackStartFn:V})},Q.deepStrictEqual=function V(ee,Z,U){if(arguments.length<2)throw new C("actual","expected");Y===void 0&&ie(),J(ee,Z)||he({actual:ee,expected:Z,message:U,operator:"deepStrictEqual",stackStartFn:V})},Q.notDeepStrictEqual=v;function v(V,ee,Z){if(arguments.length<2)throw new C("actual","expected");Y===void 0&&ie(),J(V,ee)&&he({actual:V,expected:ee,message:Z,operator:"notDeepStrictEqual",stackStartFn:v})}Q.strictEqual=function V(ee,Z,U){if(arguments.length<2)throw new C("actual","expected");j(ee,Z)||he({actual:ee,expected:Z,message:U,operator:"strictEqual",stackStartFn:V})},Q.notStrictEqual=function V(ee,Z,U){if(arguments.length<2)throw new C("actual","expected");j(ee,Z)&&he({actual:ee,expected:Z,message:U,operator:"notStrictEqual",stackStartFn:V})};var w=e(function V(ee,Z,U){var z=this;n(this,V),Z.forEach(function(ne){ne in ee&&(U!==void 0&&typeof U[ne]=="string"&&B(ee[ne])&&N(ee[ne],U[ne])?z[ne]=U[ne]:z[ne]=ee[ne])})});function c(V,ee,Z,U,z,ne){if(!(Z in V)||!J(V[Z],ee[Z])){if(!U){var fe=new w(V,z),me=new w(ee,z,V),de=new k({actual:fe,expected:me,operator:"deepStrictEqual",stackStartFn:ne});throw de.actual=V,de.expected=ee,de.operator=ne.name,de}he({actual:V,expected:ee,message:U,operator:ne.name,stackStartFn:ne})}}function p(V,ee,Z,U){if(typeof ee!="function"){if(B(ee))return N(ee,V);if(arguments.length===2)throw new m("expected",["Function","RegExp"],ee);if(t(V)!=="object"||V===null){var z=new k({actual:V,expected:ee,message:Z,operator:"deepStrictEqual",stackStartFn:U});throw z.operator=U.name,z}var ne=Object.keys(ee);if(ee instanceof Error)ne.push("name","message");else if(ne.length===0)throw new y("error",ee,"may not be an empty object");return Y===void 0&&ie(),ne.forEach(function(fe){typeof V[fe]=="string"&&B(ee[fe])&&N(ee[fe],V[fe])||c(V,ee,fe,Z,ne,U)}),!0}return ee.prototype!==void 0&&V instanceof ee?!0:Error.isPrototypeOf(ee)?!1:ee.call({},V)===!0}function x(V){if(typeof V!="function")throw new m("fn","Function",V);try{V()}catch(ee){return ee}return ce}function S(V){return R(V)||V!==null&&t(V)==="object"&&typeof V.then=="function"&&typeof V.catch=="function"}function b(V){return Promise.resolve().then(function(){var ee;if(typeof V=="function"){if(ee=V(),!S(ee))throw new E("instance of Promise","promiseFn",ee)}else if(S(V))ee=V;else throw new m("promiseFn",["Function","Promise"],V);return Promise.resolve().then(function(){return ee}).then(function(){return ce}).catch(function(Z){return Z})})}function h(V,ee,Z,U){if(typeof Z=="string"){if(arguments.length===4)throw new m("error",["Object","Error","Function","RegExp"],Z);if(t(ee)==="object"&&ee!==null){if(ee.message===Z)throw new l("error/message",'The error message "'.concat(ee.message,'" is identical to the message.'))}else if(ee===Z)throw new l("error/message",'The error "'.concat(ee,'" is identical to the message.'));U=Z,Z=void 0}else if(Z!=null&&t(Z)!=="object"&&typeof Z!="function")throw new m("error",["Object","Error","Function","RegExp"],Z);if(ee===ce){var z="";Z&&Z.name&&(z+=" (".concat(Z.name,")")),z+=U?": ".concat(U):".";var ne=V.name==="rejects"?"rejection":"exception";he({actual:void 0,expected:Z,operator:V.name,message:"Missing expected ".concat(ne).concat(z),stackStartFn:V})}if(Z&&!p(ee,Z,U,V))throw ee}function T(V,ee,Z,U){if(ee!==ce){if(typeof Z=="string"&&(U=Z,Z=void 0),!Z||p(ee,Z)){var z=U?": ".concat(U):".",ne=V.name==="doesNotReject"?"rejection":"exception";he({actual:ee,expected:Z,operator:V.name,message:"Got unwanted ".concat(ne).concat(z,`
`)+'Actual message: "'.concat(ee&&ee.message,'"'),stackStartFn:V})}throw ee}}Q.throws=function V(ee){for(var Z=arguments.length,U=new Array(Z>1?Z-1:0),z=1;z<Z;z++)U[z-1]=arguments[z];h.apply(void 0,[V,x(ee)].concat(U))},Q.rejects=function V(ee){for(var Z=arguments.length,U=new Array(Z>1?Z-1:0),z=1;z<Z;z++)U[z-1]=arguments[z];return b(ee).then(function(ne){return h.apply(void 0,[V,ne].concat(U))})},Q.doesNotThrow=function V(ee){for(var Z=arguments.length,U=new Array(Z>1?Z-1:0),z=1;z<Z;z++)U[z-1]=arguments[z];T.apply(void 0,[V,x(ee)].concat(U))},Q.doesNotReject=function V(ee){for(var Z=arguments.length,U=new Array(Z>1?Z-1:0),z=1;z<Z;z++)U[z-1]=arguments[z];return b(ee).then(function(ne){return T.apply(void 0,[V,ne].concat(U))})},Q.ifError=function V(ee){if(ee!=null){var Z="ifError got unwanted exception: ";t(ee)==="object"&&typeof ee.message=="string"?ee.message.length===0&&ee.constructor?Z+=ee.constructor.name:Z+=ee.message:Z+=D(ee);var U=new k({actual:ee,expected:null,operator:"ifError",message:Z,stackStartFn:V}),z=ee.stack;if(typeof z=="string"){var ne=z.split(`
`);ne.shift();for(var fe=U.stack.split(`
`),me=0;me<ne.length;me++){var de=fe.indexOf(ne[me]);if(de!==-1){fe=fe.slice(0,de);break}}U.stack="".concat(fe.join(`
`),`
`).concat(ne.join(`
`))}throw U}};function M(V,ee,Z,U,z){if(!B(ee))throw new m("regexp","RegExp",ee);var ne=z==="match";if(typeof V!="string"||N(ee,V)!==ne){if(Z instanceof Error)throw Z;var fe=!Z;Z=Z||(typeof V!="string"?'The "string" argument must be of type string. Received type '+"".concat(t(V)," (").concat(D(V),")"):(ne?"The input did not match the regular expression ":"The input was expected to not match the regular expression ")+"".concat(D(ee),`. Input:

`).concat(D(V),`
`));var me=new k({actual:V,expected:ee,message:Z,operator:z,stackStartFn:U});throw me.generatedMessage=fe,me}}Q.match=function V(ee,Z,U){M(ee,Z,U,V,"match")},Q.doesNotMatch=function V(ee,Z,U){M(ee,Z,U,V,"doesNotMatch")};function O(){for(var V=arguments.length,ee=new Array(V),Z=0;Z<V;Z++)ee[Z]=arguments[Z];L.apply(void 0,[O,ee.length].concat(ee))}return Q.strict=F(O,Q,{equal:Q.strictEqual,deepEqual:Q.deepStrictEqual,notEqual:Q.notStrictEqual,notDeepEqual:Q.notDeepStrictEqual}),Q.strict.strict=Q.strict,assert.exports}var zstream,hasRequiredZstream;function requireZstream(){if(hasRequiredZstream)return zstream;hasRequiredZstream=1;function t(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}return zstream=t,zstream}var deflate={},common={},hasRequiredCommon;function requireCommon(){return hasRequiredCommon||(hasRequiredCommon=1,function(t){var e=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function n(l,m){return Object.prototype.hasOwnProperty.call(l,m)}t.assign=function(l){for(var m=Array.prototype.slice.call(arguments,1);m.length;){var y=m.shift();if(y){if(typeof y!="object")throw new TypeError(y+"must be non-object");for(var E in y)n(y,E)&&(l[E]=y[E])}}return l},t.shrinkBuf=function(l,m){return l.length===m?l:l.subarray?l.subarray(0,m):(l.length=m,l)};var o={arraySet:function(l,m,y,E,C){if(m.subarray&&l.subarray){l.set(m.subarray(y,y+E),C);return}for(var k=0;k<E;k++)l[C+k]=m[y+k]},flattenChunks:function(l){var m,y,E,C,k,A;for(E=0,m=0,y=l.length;m<y;m++)E+=l[m].length;for(A=new Uint8Array(E),C=0,m=0,y=l.length;m<y;m++)k=l[m],A.set(k,C),C+=k.length;return A}},u={arraySet:function(l,m,y,E,C){for(var k=0;k<E;k++)l[C+k]=m[y+k]},flattenChunks:function(l){return[].concat.apply([],l)}};t.setTyped=function(l){l?(t.Buf8=Uint8Array,t.Buf16=Uint16Array,t.Buf32=Int32Array,t.assign(t,o)):(t.Buf8=Array,t.Buf16=Array,t.Buf32=Array,t.assign(t,u))},t.setTyped(e)}(common)),common}var trees={},hasRequiredTrees;function requireTrees(){if(hasRequiredTrees)return trees;hasRequiredTrees=1;var t=requireCommon(),e=4,n=0,o=1,u=2;function l(te){for(var ye=te.length;--ye>=0;)te[ye]=0}var m=0,y=1,E=2,C=3,k=258,A=29,D=256,P=D+1+A,R=30,B=19,F=2*P+1,j=15,N=16,Y=7,J=256,ie=16,ue=17,Q=18,ce=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],he=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],ke=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],L=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],d=512,v=new Array((P+2)*2);l(v);var w=new Array(R*2);l(w);var c=new Array(d);l(c);var p=new Array(k-C+1);l(p);var x=new Array(A);l(x);var S=new Array(R);l(S);function b(te,ye,Le,Ue,Qe){this.static_tree=te,this.extra_bits=ye,this.extra_base=Le,this.elems=Ue,this.max_length=Qe,this.has_stree=te&&te.length}var h,T,M;function O(te,ye){this.dyn_tree=te,this.max_code=0,this.stat_desc=ye}function V(te){return te<256?c[te]:c[256+(te>>>7)]}function ee(te,ye){te.pending_buf[te.pending++]=ye&255,te.pending_buf[te.pending++]=ye>>>8&255}function Z(te,ye,Le){te.bi_valid>N-Le?(te.bi_buf|=ye<<te.bi_valid&65535,ee(te,te.bi_buf),te.bi_buf=ye>>N-te.bi_valid,te.bi_valid+=Le-N):(te.bi_buf|=ye<<te.bi_valid&65535,te.bi_valid+=Le)}function U(te,ye,Le){Z(te,Le[ye*2],Le[ye*2+1])}function z(te,ye){var Le=0;do Le|=te&1,te>>>=1,Le<<=1;while(--ye>0);return Le>>>1}function ne(te){te.bi_valid===16?(ee(te,te.bi_buf),te.bi_buf=0,te.bi_valid=0):te.bi_valid>=8&&(te.pending_buf[te.pending++]=te.bi_buf&255,te.bi_buf>>=8,te.bi_valid-=8)}function fe(te,ye){var Le=ye.dyn_tree,Ue=ye.max_code,Qe=ye.stat_desc.static_tree,Ke=ye.stat_desc.has_stree,De=ye.stat_desc.extra_bits,Vt=ye.stat_desc.extra_base,At=ye.stat_desc.max_length,ve,Pt,pt,Ne,vt,ut,$t=0;for(Ne=0;Ne<=j;Ne++)te.bl_count[Ne]=0;for(Le[te.heap[te.heap_max]*2+1]=0,ve=te.heap_max+1;ve<F;ve++)Pt=te.heap[ve],Ne=Le[Le[Pt*2+1]*2+1]+1,Ne>At&&(Ne=At,$t++),Le[Pt*2+1]=Ne,!(Pt>Ue)&&(te.bl_count[Ne]++,vt=0,Pt>=Vt&&(vt=De[Pt-Vt]),ut=Le[Pt*2],te.opt_len+=ut*(Ne+vt),Ke&&(te.static_len+=ut*(Qe[Pt*2+1]+vt)));if($t!==0){do{for(Ne=At-1;te.bl_count[Ne]===0;)Ne--;te.bl_count[Ne]--,te.bl_count[Ne+1]+=2,te.bl_count[At]--,$t-=2}while($t>0);for(Ne=At;Ne!==0;Ne--)for(Pt=te.bl_count[Ne];Pt!==0;)pt=te.heap[--ve],!(pt>Ue)&&(Le[pt*2+1]!==Ne&&(te.opt_len+=(Ne-Le[pt*2+1])*Le[pt*2],Le[pt*2+1]=Ne),Pt--)}}function me(te,ye,Le){var Ue=new Array(j+1),Qe=0,Ke,De;for(Ke=1;Ke<=j;Ke++)Ue[Ke]=Qe=Qe+Le[Ke-1]<<1;for(De=0;De<=ye;De++){var Vt=te[De*2+1];Vt!==0&&(te[De*2]=z(Ue[Vt]++,Vt))}}function de(){var te,ye,Le,Ue,Qe,Ke=new Array(j+1);for(Le=0,Ue=0;Ue<A-1;Ue++)for(x[Ue]=Le,te=0;te<1<<ce[Ue];te++)p[Le++]=Ue;for(p[Le-1]=Ue,Qe=0,Ue=0;Ue<16;Ue++)for(S[Ue]=Qe,te=0;te<1<<he[Ue];te++)c[Qe++]=Ue;for(Qe>>=7;Ue<R;Ue++)for(S[Ue]=Qe<<7,te=0;te<1<<he[Ue]-7;te++)c[256+Qe++]=Ue;for(ye=0;ye<=j;ye++)Ke[ye]=0;for(te=0;te<=143;)v[te*2+1]=8,te++,Ke[8]++;for(;te<=255;)v[te*2+1]=9,te++,Ke[9]++;for(;te<=279;)v[te*2+1]=7,te++,Ke[7]++;for(;te<=287;)v[te*2+1]=8,te++,Ke[8]++;for(me(v,P+1,Ke),te=0;te<R;te++)w[te*2+1]=5,w[te*2]=z(te,5);h=new b(v,ce,D+1,P,j),T=new b(w,he,0,R,j),M=new b(new Array(0),ke,0,B,Y)}function je(te){var ye;for(ye=0;ye<P;ye++)te.dyn_ltree[ye*2]=0;for(ye=0;ye<R;ye++)te.dyn_dtree[ye*2]=0;for(ye=0;ye<B;ye++)te.bl_tree[ye*2]=0;te.dyn_ltree[J*2]=1,te.opt_len=te.static_len=0,te.last_lit=te.matches=0}function lt(te){te.bi_valid>8?ee(te,te.bi_buf):te.bi_valid>0&&(te.pending_buf[te.pending++]=te.bi_buf),te.bi_buf=0,te.bi_valid=0}function it(te,ye,Le,Ue){lt(te),ee(te,Le),ee(te,~Le),t.arraySet(te.pending_buf,te.window,ye,Le,te.pending),te.pending+=Le}function ot(te,ye,Le,Ue){var Qe=ye*2,Ke=Le*2;return te[Qe]<te[Ke]||te[Qe]===te[Ke]&&Ue[ye]<=Ue[Le]}function Ct(te,ye,Le){for(var Ue=te.heap[Le],Qe=Le<<1;Qe<=te.heap_len&&(Qe<te.heap_len&&ot(ye,te.heap[Qe+1],te.heap[Qe],te.depth)&&Qe++,!ot(ye,Ue,te.heap[Qe],te.depth));)te.heap[Le]=te.heap[Qe],Le=Qe,Qe<<=1;te.heap[Le]=Ue}function nt(te,ye,Le){var Ue,Qe,Ke=0,De,Vt;if(te.last_lit!==0)do Ue=te.pending_buf[te.d_buf+Ke*2]<<8|te.pending_buf[te.d_buf+Ke*2+1],Qe=te.pending_buf[te.l_buf+Ke],Ke++,Ue===0?U(te,Qe,ye):(De=p[Qe],U(te,De+D+1,ye),Vt=ce[De],Vt!==0&&(Qe-=x[De],Z(te,Qe,Vt)),Ue--,De=V(Ue),U(te,De,Le),Vt=he[De],Vt!==0&&(Ue-=S[De],Z(te,Ue,Vt)));while(Ke<te.last_lit);U(te,J,ye)}function Je(te,ye){var Le=ye.dyn_tree,Ue=ye.stat_desc.static_tree,Qe=ye.stat_desc.has_stree,Ke=ye.stat_desc.elems,De,Vt,At=-1,ve;for(te.heap_len=0,te.heap_max=F,De=0;De<Ke;De++)Le[De*2]!==0?(te.heap[++te.heap_len]=At=De,te.depth[De]=0):Le[De*2+1]=0;for(;te.heap_len<2;)ve=te.heap[++te.heap_len]=At<2?++At:0,Le[ve*2]=1,te.depth[ve]=0,te.opt_len--,Qe&&(te.static_len-=Ue[ve*2+1]);for(ye.max_code=At,De=te.heap_len>>1;De>=1;De--)Ct(te,Le,De);ve=Ke;do De=te.heap[1],te.heap[1]=te.heap[te.heap_len--],Ct(te,Le,1),Vt=te.heap[1],te.heap[--te.heap_max]=De,te.heap[--te.heap_max]=Vt,Le[ve*2]=Le[De*2]+Le[Vt*2],te.depth[ve]=(te.depth[De]>=te.depth[Vt]?te.depth[De]:te.depth[Vt])+1,Le[De*2+1]=Le[Vt*2+1]=ve,te.heap[1]=ve++,Ct(te,Le,1);while(te.heap_len>=2);te.heap[--te.heap_max]=te.heap[1],fe(te,ye),me(Le,At,te.bl_count)}function tt(te,ye,Le){var Ue,Qe=-1,Ke,De=ye[0*2+1],Vt=0,At=7,ve=4;for(De===0&&(At=138,ve=3),ye[(Le+1)*2+1]=65535,Ue=0;Ue<=Le;Ue++)Ke=De,De=ye[(Ue+1)*2+1],!(++Vt<At&&Ke===De)&&(Vt<ve?te.bl_tree[Ke*2]+=Vt:Ke!==0?(Ke!==Qe&&te.bl_tree[Ke*2]++,te.bl_tree[ie*2]++):Vt<=10?te.bl_tree[ue*2]++:te.bl_tree[Q*2]++,Vt=0,Qe=Ke,De===0?(At=138,ve=3):Ke===De?(At=6,ve=3):(At=7,ve=4))}function rt(te,ye,Le){var Ue,Qe=-1,Ke,De=ye[0*2+1],Vt=0,At=7,ve=4;for(De===0&&(At=138,ve=3),Ue=0;Ue<=Le;Ue++)if(Ke=De,De=ye[(Ue+1)*2+1],!(++Vt<At&&Ke===De)){if(Vt<ve)do U(te,Ke,te.bl_tree);while(--Vt!==0);else Ke!==0?(Ke!==Qe&&(U(te,Ke,te.bl_tree),Vt--),U(te,ie,te.bl_tree),Z(te,Vt-3,2)):Vt<=10?(U(te,ue,te.bl_tree),Z(te,Vt-3,3)):(U(te,Q,te.bl_tree),Z(te,Vt-11,7));Vt=0,Qe=Ke,De===0?(At=138,ve=3):Ke===De?(At=6,ve=3):(At=7,ve=4)}}function ht(te){var ye;for(tt(te,te.dyn_ltree,te.l_desc.max_code),tt(te,te.dyn_dtree,te.d_desc.max_code),Je(te,te.bl_desc),ye=B-1;ye>=3&&te.bl_tree[L[ye]*2+1]===0;ye--);return te.opt_len+=3*(ye+1)+5+5+4,ye}function Ot(te,ye,Le,Ue){var Qe;for(Z(te,ye-257,5),Z(te,Le-1,5),Z(te,Ue-4,4),Qe=0;Qe<Ue;Qe++)Z(te,te.bl_tree[L[Qe]*2+1],3);rt(te,te.dyn_ltree,ye-1),rt(te,te.dyn_dtree,Le-1)}function Ve(te){var ye=4093624447,Le;for(Le=0;Le<=31;Le++,ye>>>=1)if(ye&1&&te.dyn_ltree[Le*2]!==0)return n;if(te.dyn_ltree[9*2]!==0||te.dyn_ltree[10*2]!==0||te.dyn_ltree[13*2]!==0)return o;for(Le=32;Le<D;Le++)if(te.dyn_ltree[Le*2]!==0)return o;return n}var We=!1;function Gt(te){We||(de(),We=!0),te.l_desc=new O(te.dyn_ltree,h),te.d_desc=new O(te.dyn_dtree,T),te.bl_desc=new O(te.bl_tree,M),te.bi_buf=0,te.bi_valid=0,je(te)}function wt(te,ye,Le,Ue){Z(te,(m<<1)+(Ue?1:0),3),it(te,ye,Le)}function Et(te){Z(te,y<<1,3),U(te,J,v),ne(te)}function Yt(te,ye,Le,Ue){var Qe,Ke,De=0;te.level>0?(te.strm.data_type===u&&(te.strm.data_type=Ve(te)),Je(te,te.l_desc),Je(te,te.d_desc),De=ht(te),Qe=te.opt_len+3+7>>>3,Ke=te.static_len+3+7>>>3,Ke<=Qe&&(Qe=Ke)):Qe=Ke=Le+5,Le+4<=Qe&&ye!==-1?wt(te,ye,Le,Ue):te.strategy===e||Ke===Qe?(Z(te,(y<<1)+(Ue?1:0),3),nt(te,v,w)):(Z(te,(E<<1)+(Ue?1:0),3),Ot(te,te.l_desc.max_code+1,te.d_desc.max_code+1,De+1),nt(te,te.dyn_ltree,te.dyn_dtree)),je(te),Ue&&lt(te)}function Ce(te,ye,Le){return te.pending_buf[te.d_buf+te.last_lit*2]=ye>>>8&255,te.pending_buf[te.d_buf+te.last_lit*2+1]=ye&255,te.pending_buf[te.l_buf+te.last_lit]=Le&255,te.last_lit++,ye===0?te.dyn_ltree[Le*2]++:(te.matches++,ye--,te.dyn_ltree[(p[Le]+D+1)*2]++,te.dyn_dtree[V(ye)*2]++),te.last_lit===te.lit_bufsize-1}return trees._tr_init=Gt,trees._tr_stored_block=wt,trees._tr_flush_block=Yt,trees._tr_tally=Ce,trees._tr_align=Et,trees}var adler32_1,hasRequiredAdler32;function requireAdler32(){if(hasRequiredAdler32)return adler32_1;hasRequiredAdler32=1;function t(e,n,o,u){for(var l=e&65535|0,m=e>>>16&65535|0,y=0;o!==0;){y=o>2e3?2e3:o,o-=y;do l=l+n[u++]|0,m=m+l|0;while(--y);l%=65521,m%=65521}return l|m<<16|0}return adler32_1=t,adler32_1}var crc32_1,hasRequiredCrc32;function requireCrc32(){if(hasRequiredCrc32)return crc32_1;hasRequiredCrc32=1;function t(){for(var o,u=[],l=0;l<256;l++){o=l;for(var m=0;m<8;m++)o=o&1?3988292384^o>>>1:o>>>1;u[l]=o}return u}var e=t();function n(o,u,l,m){var y=e,E=m+l;o^=-1;for(var C=m;C<E;C++)o=o>>>8^y[(o^u[C])&255];return o^-1}return crc32_1=n,crc32_1}var messages,hasRequiredMessages;function requireMessages(){return hasRequiredMessages||(hasRequiredMessages=1,messages={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}),messages}var hasRequiredDeflate;function requireDeflate(){if(hasRequiredDeflate)return deflate;hasRequiredDeflate=1;var t=requireCommon(),e=requireTrees(),n=requireAdler32(),o=requireCrc32(),u=requireMessages(),l=0,m=1,y=3,E=4,C=5,k=0,A=1,D=-2,P=-3,R=-5,B=-1,F=1,j=2,N=3,Y=4,J=0,ie=2,ue=8,Q=9,ce=15,he=8,ke=29,L=256,d=L+1+ke,v=30,w=19,c=2*d+1,p=15,x=3,S=258,b=S+x+1,h=32,T=42,M=69,O=73,V=91,ee=103,Z=113,U=666,z=1,ne=2,fe=3,me=4,de=3;function je(ve,Pt){return ve.msg=u[Pt],Pt}function lt(ve){return(ve<<1)-(ve>4?9:0)}function it(ve){for(var Pt=ve.length;--Pt>=0;)ve[Pt]=0}function ot(ve){var Pt=ve.state,pt=Pt.pending;pt>ve.avail_out&&(pt=ve.avail_out),pt!==0&&(t.arraySet(ve.output,Pt.pending_buf,Pt.pending_out,pt,ve.next_out),ve.next_out+=pt,Pt.pending_out+=pt,ve.total_out+=pt,ve.avail_out-=pt,Pt.pending-=pt,Pt.pending===0&&(Pt.pending_out=0))}function Ct(ve,Pt){e._tr_flush_block(ve,ve.block_start>=0?ve.block_start:-1,ve.strstart-ve.block_start,Pt),ve.block_start=ve.strstart,ot(ve.strm)}function nt(ve,Pt){ve.pending_buf[ve.pending++]=Pt}function Je(ve,Pt){ve.pending_buf[ve.pending++]=Pt>>>8&255,ve.pending_buf[ve.pending++]=Pt&255}function tt(ve,Pt,pt,Ne){var vt=ve.avail_in;return vt>Ne&&(vt=Ne),vt===0?0:(ve.avail_in-=vt,t.arraySet(Pt,ve.input,ve.next_in,vt,pt),ve.state.wrap===1?ve.adler=n(ve.adler,Pt,vt,pt):ve.state.wrap===2&&(ve.adler=o(ve.adler,Pt,vt,pt)),ve.next_in+=vt,ve.total_in+=vt,vt)}function rt(ve,Pt){var pt=ve.max_chain_length,Ne=ve.strstart,vt,ut,$t=ve.prev_length,fi=ve.nice_match,kt=ve.strstart>ve.w_size-b?ve.strstart-(ve.w_size-b):0,Wt=ve.window,Zi=ve.w_mask,Ut=ve.prev,Xt=ve.strstart+S,Be=Wt[Ne+$t-1],be=Wt[Ne+$t];ve.prev_length>=ve.good_match&&(pt>>=2),fi>ve.lookahead&&(fi=ve.lookahead);do if(vt=Pt,!(Wt[vt+$t]!==be||Wt[vt+$t-1]!==Be||Wt[vt]!==Wt[Ne]||Wt[++vt]!==Wt[Ne+1])){Ne+=2,vt++;do;while(Wt[++Ne]===Wt[++vt]&&Wt[++Ne]===Wt[++vt]&&Wt[++Ne]===Wt[++vt]&&Wt[++Ne]===Wt[++vt]&&Wt[++Ne]===Wt[++vt]&&Wt[++Ne]===Wt[++vt]&&Wt[++Ne]===Wt[++vt]&&Wt[++Ne]===Wt[++vt]&&Ne<Xt);if(ut=S-(Xt-Ne),Ne=Xt-S,ut>$t){if(ve.match_start=Pt,$t=ut,ut>=fi)break;Be=Wt[Ne+$t-1],be=Wt[Ne+$t]}}while((Pt=Ut[Pt&Zi])>kt&&--pt!==0);return $t<=ve.lookahead?$t:ve.lookahead}function ht(ve){var Pt=ve.w_size,pt,Ne,vt,ut,$t;do{if(ut=ve.window_size-ve.lookahead-ve.strstart,ve.strstart>=Pt+(Pt-b)){t.arraySet(ve.window,ve.window,Pt,Pt,0),ve.match_start-=Pt,ve.strstart-=Pt,ve.block_start-=Pt,Ne=ve.hash_size,pt=Ne;do vt=ve.head[--pt],ve.head[pt]=vt>=Pt?vt-Pt:0;while(--Ne);Ne=Pt,pt=Ne;do vt=ve.prev[--pt],ve.prev[pt]=vt>=Pt?vt-Pt:0;while(--Ne);ut+=Pt}if(ve.strm.avail_in===0)break;if(Ne=tt(ve.strm,ve.window,ve.strstart+ve.lookahead,ut),ve.lookahead+=Ne,ve.lookahead+ve.insert>=x)for($t=ve.strstart-ve.insert,ve.ins_h=ve.window[$t],ve.ins_h=(ve.ins_h<<ve.hash_shift^ve.window[$t+1])&ve.hash_mask;ve.insert&&(ve.ins_h=(ve.ins_h<<ve.hash_shift^ve.window[$t+x-1])&ve.hash_mask,ve.prev[$t&ve.w_mask]=ve.head[ve.ins_h],ve.head[ve.ins_h]=$t,$t++,ve.insert--,!(ve.lookahead+ve.insert<x)););}while(ve.lookahead<b&&ve.strm.avail_in!==0)}function Ot(ve,Pt){var pt=65535;for(pt>ve.pending_buf_size-5&&(pt=ve.pending_buf_size-5);;){if(ve.lookahead<=1){if(ht(ve),ve.lookahead===0&&Pt===l)return z;if(ve.lookahead===0)break}ve.strstart+=ve.lookahead,ve.lookahead=0;var Ne=ve.block_start+pt;if((ve.strstart===0||ve.strstart>=Ne)&&(ve.lookahead=ve.strstart-Ne,ve.strstart=Ne,Ct(ve,!1),ve.strm.avail_out===0)||ve.strstart-ve.block_start>=ve.w_size-b&&(Ct(ve,!1),ve.strm.avail_out===0))return z}return ve.insert=0,Pt===E?(Ct(ve,!0),ve.strm.avail_out===0?fe:me):(ve.strstart>ve.block_start&&(Ct(ve,!1),ve.strm.avail_out===0),z)}function Ve(ve,Pt){for(var pt,Ne;;){if(ve.lookahead<b){if(ht(ve),ve.lookahead<b&&Pt===l)return z;if(ve.lookahead===0)break}if(pt=0,ve.lookahead>=x&&(ve.ins_h=(ve.ins_h<<ve.hash_shift^ve.window[ve.strstart+x-1])&ve.hash_mask,pt=ve.prev[ve.strstart&ve.w_mask]=ve.head[ve.ins_h],ve.head[ve.ins_h]=ve.strstart),pt!==0&&ve.strstart-pt<=ve.w_size-b&&(ve.match_length=rt(ve,pt)),ve.match_length>=x)if(Ne=e._tr_tally(ve,ve.strstart-ve.match_start,ve.match_length-x),ve.lookahead-=ve.match_length,ve.match_length<=ve.max_lazy_match&&ve.lookahead>=x){ve.match_length--;do ve.strstart++,ve.ins_h=(ve.ins_h<<ve.hash_shift^ve.window[ve.strstart+x-1])&ve.hash_mask,pt=ve.prev[ve.strstart&ve.w_mask]=ve.head[ve.ins_h],ve.head[ve.ins_h]=ve.strstart;while(--ve.match_length!==0);ve.strstart++}else ve.strstart+=ve.match_length,ve.match_length=0,ve.ins_h=ve.window[ve.strstart],ve.ins_h=(ve.ins_h<<ve.hash_shift^ve.window[ve.strstart+1])&ve.hash_mask;else Ne=e._tr_tally(ve,0,ve.window[ve.strstart]),ve.lookahead--,ve.strstart++;if(Ne&&(Ct(ve,!1),ve.strm.avail_out===0))return z}return ve.insert=ve.strstart<x-1?ve.strstart:x-1,Pt===E?(Ct(ve,!0),ve.strm.avail_out===0?fe:me):ve.last_lit&&(Ct(ve,!1),ve.strm.avail_out===0)?z:ne}function We(ve,Pt){for(var pt,Ne,vt;;){if(ve.lookahead<b){if(ht(ve),ve.lookahead<b&&Pt===l)return z;if(ve.lookahead===0)break}if(pt=0,ve.lookahead>=x&&(ve.ins_h=(ve.ins_h<<ve.hash_shift^ve.window[ve.strstart+x-1])&ve.hash_mask,pt=ve.prev[ve.strstart&ve.w_mask]=ve.head[ve.ins_h],ve.head[ve.ins_h]=ve.strstart),ve.prev_length=ve.match_length,ve.prev_match=ve.match_start,ve.match_length=x-1,pt!==0&&ve.prev_length<ve.max_lazy_match&&ve.strstart-pt<=ve.w_size-b&&(ve.match_length=rt(ve,pt),ve.match_length<=5&&(ve.strategy===F||ve.match_length===x&&ve.strstart-ve.match_start>4096)&&(ve.match_length=x-1)),ve.prev_length>=x&&ve.match_length<=ve.prev_length){vt=ve.strstart+ve.lookahead-x,Ne=e._tr_tally(ve,ve.strstart-1-ve.prev_match,ve.prev_length-x),ve.lookahead-=ve.prev_length-1,ve.prev_length-=2;do++ve.strstart<=vt&&(ve.ins_h=(ve.ins_h<<ve.hash_shift^ve.window[ve.strstart+x-1])&ve.hash_mask,pt=ve.prev[ve.strstart&ve.w_mask]=ve.head[ve.ins_h],ve.head[ve.ins_h]=ve.strstart);while(--ve.prev_length!==0);if(ve.match_available=0,ve.match_length=x-1,ve.strstart++,Ne&&(Ct(ve,!1),ve.strm.avail_out===0))return z}else if(ve.match_available){if(Ne=e._tr_tally(ve,0,ve.window[ve.strstart-1]),Ne&&Ct(ve,!1),ve.strstart++,ve.lookahead--,ve.strm.avail_out===0)return z}else ve.match_available=1,ve.strstart++,ve.lookahead--}return ve.match_available&&(Ne=e._tr_tally(ve,0,ve.window[ve.strstart-1]),ve.match_available=0),ve.insert=ve.strstart<x-1?ve.strstart:x-1,Pt===E?(Ct(ve,!0),ve.strm.avail_out===0?fe:me):ve.last_lit&&(Ct(ve,!1),ve.strm.avail_out===0)?z:ne}function Gt(ve,Pt){for(var pt,Ne,vt,ut,$t=ve.window;;){if(ve.lookahead<=S){if(ht(ve),ve.lookahead<=S&&Pt===l)return z;if(ve.lookahead===0)break}if(ve.match_length=0,ve.lookahead>=x&&ve.strstart>0&&(vt=ve.strstart-1,Ne=$t[vt],Ne===$t[++vt]&&Ne===$t[++vt]&&Ne===$t[++vt])){ut=ve.strstart+S;do;while(Ne===$t[++vt]&&Ne===$t[++vt]&&Ne===$t[++vt]&&Ne===$t[++vt]&&Ne===$t[++vt]&&Ne===$t[++vt]&&Ne===$t[++vt]&&Ne===$t[++vt]&&vt<ut);ve.match_length=S-(ut-vt),ve.match_length>ve.lookahead&&(ve.match_length=ve.lookahead)}if(ve.match_length>=x?(pt=e._tr_tally(ve,1,ve.match_length-x),ve.lookahead-=ve.match_length,ve.strstart+=ve.match_length,ve.match_length=0):(pt=e._tr_tally(ve,0,ve.window[ve.strstart]),ve.lookahead--,ve.strstart++),pt&&(Ct(ve,!1),ve.strm.avail_out===0))return z}return ve.insert=0,Pt===E?(Ct(ve,!0),ve.strm.avail_out===0?fe:me):ve.last_lit&&(Ct(ve,!1),ve.strm.avail_out===0)?z:ne}function wt(ve,Pt){for(var pt;;){if(ve.lookahead===0&&(ht(ve),ve.lookahead===0)){if(Pt===l)return z;break}if(ve.match_length=0,pt=e._tr_tally(ve,0,ve.window[ve.strstart]),ve.lookahead--,ve.strstart++,pt&&(Ct(ve,!1),ve.strm.avail_out===0))return z}return ve.insert=0,Pt===E?(Ct(ve,!0),ve.strm.avail_out===0?fe:me):ve.last_lit&&(Ct(ve,!1),ve.strm.avail_out===0)?z:ne}function Et(ve,Pt,pt,Ne,vt){this.good_length=ve,this.max_lazy=Pt,this.nice_length=pt,this.max_chain=Ne,this.func=vt}var Yt;Yt=[new Et(0,0,0,0,Ot),new Et(4,4,8,4,Ve),new Et(4,5,16,8,Ve),new Et(4,6,32,32,Ve),new Et(4,4,16,16,We),new Et(8,16,32,32,We),new Et(8,16,128,128,We),new Et(8,32,128,256,We),new Et(32,128,258,1024,We),new Et(32,258,258,4096,We)];function Ce(ve){ve.window_size=2*ve.w_size,it(ve.head),ve.max_lazy_match=Yt[ve.level].max_lazy,ve.good_match=Yt[ve.level].good_length,ve.nice_match=Yt[ve.level].nice_length,ve.max_chain_length=Yt[ve.level].max_chain,ve.strstart=0,ve.block_start=0,ve.lookahead=0,ve.insert=0,ve.match_length=ve.prev_length=x-1,ve.match_available=0,ve.ins_h=0}function te(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=ue,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new t.Buf16(c*2),this.dyn_dtree=new t.Buf16((2*v+1)*2),this.bl_tree=new t.Buf16((2*w+1)*2),it(this.dyn_ltree),it(this.dyn_dtree),it(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new t.Buf16(p+1),this.heap=new t.Buf16(2*d+1),it(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new t.Buf16(2*d+1),it(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function ye(ve){var Pt;return!ve||!ve.state?je(ve,D):(ve.total_in=ve.total_out=0,ve.data_type=ie,Pt=ve.state,Pt.pending=0,Pt.pending_out=0,Pt.wrap<0&&(Pt.wrap=-Pt.wrap),Pt.status=Pt.wrap?T:Z,ve.adler=Pt.wrap===2?0:1,Pt.last_flush=l,e._tr_init(Pt),k)}function Le(ve){var Pt=ye(ve);return Pt===k&&Ce(ve.state),Pt}function Ue(ve,Pt){return!ve||!ve.state||ve.state.wrap!==2?D:(ve.state.gzhead=Pt,k)}function Qe(ve,Pt,pt,Ne,vt,ut){if(!ve)return D;var $t=1;if(Pt===B&&(Pt=6),Ne<0?($t=0,Ne=-Ne):Ne>15&&($t=2,Ne-=16),vt<1||vt>Q||pt!==ue||Ne<8||Ne>15||Pt<0||Pt>9||ut<0||ut>Y)return je(ve,D);Ne===8&&(Ne=9);var fi=new te;return ve.state=fi,fi.strm=ve,fi.wrap=$t,fi.gzhead=null,fi.w_bits=Ne,fi.w_size=1<<fi.w_bits,fi.w_mask=fi.w_size-1,fi.hash_bits=vt+7,fi.hash_size=1<<fi.hash_bits,fi.hash_mask=fi.hash_size-1,fi.hash_shift=~~((fi.hash_bits+x-1)/x),fi.window=new t.Buf8(fi.w_size*2),fi.head=new t.Buf16(fi.hash_size),fi.prev=new t.Buf16(fi.w_size),fi.lit_bufsize=1<<vt+6,fi.pending_buf_size=fi.lit_bufsize*4,fi.pending_buf=new t.Buf8(fi.pending_buf_size),fi.d_buf=1*fi.lit_bufsize,fi.l_buf=3*fi.lit_bufsize,fi.level=Pt,fi.strategy=ut,fi.method=pt,Le(ve)}function Ke(ve,Pt){return Qe(ve,Pt,ue,ce,he,J)}function De(ve,Pt){var pt,Ne,vt,ut;if(!ve||!ve.state||Pt>C||Pt<0)return ve?je(ve,D):D;if(Ne=ve.state,!ve.output||!ve.input&&ve.avail_in!==0||Ne.status===U&&Pt!==E)return je(ve,ve.avail_out===0?R:D);if(Ne.strm=ve,pt=Ne.last_flush,Ne.last_flush=Pt,Ne.status===T)if(Ne.wrap===2)ve.adler=0,nt(Ne,31),nt(Ne,139),nt(Ne,8),Ne.gzhead?(nt(Ne,(Ne.gzhead.text?1:0)+(Ne.gzhead.hcrc?2:0)+(Ne.gzhead.extra?4:0)+(Ne.gzhead.name?8:0)+(Ne.gzhead.comment?16:0)),nt(Ne,Ne.gzhead.time&255),nt(Ne,Ne.gzhead.time>>8&255),nt(Ne,Ne.gzhead.time>>16&255),nt(Ne,Ne.gzhead.time>>24&255),nt(Ne,Ne.level===9?2:Ne.strategy>=j||Ne.level<2?4:0),nt(Ne,Ne.gzhead.os&255),Ne.gzhead.extra&&Ne.gzhead.extra.length&&(nt(Ne,Ne.gzhead.extra.length&255),nt(Ne,Ne.gzhead.extra.length>>8&255)),Ne.gzhead.hcrc&&(ve.adler=o(ve.adler,Ne.pending_buf,Ne.pending,0)),Ne.gzindex=0,Ne.status=M):(nt(Ne,0),nt(Ne,0),nt(Ne,0),nt(Ne,0),nt(Ne,0),nt(Ne,Ne.level===9?2:Ne.strategy>=j||Ne.level<2?4:0),nt(Ne,de),Ne.status=Z);else{var $t=ue+(Ne.w_bits-8<<4)<<8,fi=-1;Ne.strategy>=j||Ne.level<2?fi=0:Ne.level<6?fi=1:Ne.level===6?fi=2:fi=3,$t|=fi<<6,Ne.strstart!==0&&($t|=h),$t+=31-$t%31,Ne.status=Z,Je(Ne,$t),Ne.strstart!==0&&(Je(Ne,ve.adler>>>16),Je(Ne,ve.adler&65535)),ve.adler=1}if(Ne.status===M)if(Ne.gzhead.extra){for(vt=Ne.pending;Ne.gzindex<(Ne.gzhead.extra.length&65535)&&!(Ne.pending===Ne.pending_buf_size&&(Ne.gzhead.hcrc&&Ne.pending>vt&&(ve.adler=o(ve.adler,Ne.pending_buf,Ne.pending-vt,vt)),ot(ve),vt=Ne.pending,Ne.pending===Ne.pending_buf_size));)nt(Ne,Ne.gzhead.extra[Ne.gzindex]&255),Ne.gzindex++;Ne.gzhead.hcrc&&Ne.pending>vt&&(ve.adler=o(ve.adler,Ne.pending_buf,Ne.pending-vt,vt)),Ne.gzindex===Ne.gzhead.extra.length&&(Ne.gzindex=0,Ne.status=O)}else Ne.status=O;if(Ne.status===O)if(Ne.gzhead.name){vt=Ne.pending;do{if(Ne.pending===Ne.pending_buf_size&&(Ne.gzhead.hcrc&&Ne.pending>vt&&(ve.adler=o(ve.adler,Ne.pending_buf,Ne.pending-vt,vt)),ot(ve),vt=Ne.pending,Ne.pending===Ne.pending_buf_size)){ut=1;break}Ne.gzindex<Ne.gzhead.name.length?ut=Ne.gzhead.name.charCodeAt(Ne.gzindex++)&255:ut=0,nt(Ne,ut)}while(ut!==0);Ne.gzhead.hcrc&&Ne.pending>vt&&(ve.adler=o(ve.adler,Ne.pending_buf,Ne.pending-vt,vt)),ut===0&&(Ne.gzindex=0,Ne.status=V)}else Ne.status=V;if(Ne.status===V)if(Ne.gzhead.comment){vt=Ne.pending;do{if(Ne.pending===Ne.pending_buf_size&&(Ne.gzhead.hcrc&&Ne.pending>vt&&(ve.adler=o(ve.adler,Ne.pending_buf,Ne.pending-vt,vt)),ot(ve),vt=Ne.pending,Ne.pending===Ne.pending_buf_size)){ut=1;break}Ne.gzindex<Ne.gzhead.comment.length?ut=Ne.gzhead.comment.charCodeAt(Ne.gzindex++)&255:ut=0,nt(Ne,ut)}while(ut!==0);Ne.gzhead.hcrc&&Ne.pending>vt&&(ve.adler=o(ve.adler,Ne.pending_buf,Ne.pending-vt,vt)),ut===0&&(Ne.status=ee)}else Ne.status=ee;if(Ne.status===ee&&(Ne.gzhead.hcrc?(Ne.pending+2>Ne.pending_buf_size&&ot(ve),Ne.pending+2<=Ne.pending_buf_size&&(nt(Ne,ve.adler&255),nt(Ne,ve.adler>>8&255),ve.adler=0,Ne.status=Z)):Ne.status=Z),Ne.pending!==0){if(ot(ve),ve.avail_out===0)return Ne.last_flush=-1,k}else if(ve.avail_in===0&&lt(Pt)<=lt(pt)&&Pt!==E)return je(ve,R);if(Ne.status===U&&ve.avail_in!==0)return je(ve,R);if(ve.avail_in!==0||Ne.lookahead!==0||Pt!==l&&Ne.status!==U){var kt=Ne.strategy===j?wt(Ne,Pt):Ne.strategy===N?Gt(Ne,Pt):Yt[Ne.level].func(Ne,Pt);if((kt===fe||kt===me)&&(Ne.status=U),kt===z||kt===fe)return ve.avail_out===0&&(Ne.last_flush=-1),k;if(kt===ne&&(Pt===m?e._tr_align(Ne):Pt!==C&&(e._tr_stored_block(Ne,0,0,!1),Pt===y&&(it(Ne.head),Ne.lookahead===0&&(Ne.strstart=0,Ne.block_start=0,Ne.insert=0))),ot(ve),ve.avail_out===0))return Ne.last_flush=-1,k}return Pt!==E?k:Ne.wrap<=0?A:(Ne.wrap===2?(nt(Ne,ve.adler&255),nt(Ne,ve.adler>>8&255),nt(Ne,ve.adler>>16&255),nt(Ne,ve.adler>>24&255),nt(Ne,ve.total_in&255),nt(Ne,ve.total_in>>8&255),nt(Ne,ve.total_in>>16&255),nt(Ne,ve.total_in>>24&255)):(Je(Ne,ve.adler>>>16),Je(Ne,ve.adler&65535)),ot(ve),Ne.wrap>0&&(Ne.wrap=-Ne.wrap),Ne.pending!==0?k:A)}function Vt(ve){var Pt;return!ve||!ve.state?D:(Pt=ve.state.status,Pt!==T&&Pt!==M&&Pt!==O&&Pt!==V&&Pt!==ee&&Pt!==Z&&Pt!==U?je(ve,D):(ve.state=null,Pt===Z?je(ve,P):k))}function At(ve,Pt){var pt=Pt.length,Ne,vt,ut,$t,fi,kt,Wt,Zi;if(!ve||!ve.state||(Ne=ve.state,$t=Ne.wrap,$t===2||$t===1&&Ne.status!==T||Ne.lookahead))return D;for($t===1&&(ve.adler=n(ve.adler,Pt,pt,0)),Ne.wrap=0,pt>=Ne.w_size&&($t===0&&(it(Ne.head),Ne.strstart=0,Ne.block_start=0,Ne.insert=0),Zi=new t.Buf8(Ne.w_size),t.arraySet(Zi,Pt,pt-Ne.w_size,Ne.w_size,0),Pt=Zi,pt=Ne.w_size),fi=ve.avail_in,kt=ve.next_in,Wt=ve.input,ve.avail_in=pt,ve.next_in=0,ve.input=Pt,ht(Ne);Ne.lookahead>=x;){vt=Ne.strstart,ut=Ne.lookahead-(x-1);do Ne.ins_h=(Ne.ins_h<<Ne.hash_shift^Ne.window[vt+x-1])&Ne.hash_mask,Ne.prev[vt&Ne.w_mask]=Ne.head[Ne.ins_h],Ne.head[Ne.ins_h]=vt,vt++;while(--ut);Ne.strstart=vt,Ne.lookahead=x-1,ht(Ne)}return Ne.strstart+=Ne.lookahead,Ne.block_start=Ne.strstart,Ne.insert=Ne.lookahead,Ne.lookahead=0,Ne.match_length=Ne.prev_length=x-1,Ne.match_available=0,ve.next_in=kt,ve.input=Wt,ve.avail_in=fi,Ne.wrap=$t,k}return deflate.deflateInit=Ke,deflate.deflateInit2=Qe,deflate.deflateReset=Le,deflate.deflateResetKeep=ye,deflate.deflateSetHeader=Ue,deflate.deflate=De,deflate.deflateEnd=Vt,deflate.deflateSetDictionary=At,deflate.deflateInfo="pako deflate (from Nodeca project)",deflate}var inflate={},inffast,hasRequiredInffast;function requireInffast(){if(hasRequiredInffast)return inffast;hasRequiredInffast=1;var t=30,e=12;return inffast=function(o,u){var l,m,y,E,C,k,A,D,P,R,B,F,j,N,Y,J,ie,ue,Q,ce,he,ke,L,d,v;l=o.state,m=o.next_in,d=o.input,y=m+(o.avail_in-5),E=o.next_out,v=o.output,C=E-(u-o.avail_out),k=E+(o.avail_out-257),A=l.dmax,D=l.wsize,P=l.whave,R=l.wnext,B=l.window,F=l.hold,j=l.bits,N=l.lencode,Y=l.distcode,J=(1<<l.lenbits)-1,ie=(1<<l.distbits)-1;e:do{j<15&&(F+=d[m++]<<j,j+=8,F+=d[m++]<<j,j+=8),ue=N[F&J];t:for(;;){if(Q=ue>>>24,F>>>=Q,j-=Q,Q=ue>>>16&255,Q===0)v[E++]=ue&65535;else if(Q&16){ce=ue&65535,Q&=15,Q&&(j<Q&&(F+=d[m++]<<j,j+=8),ce+=F&(1<<Q)-1,F>>>=Q,j-=Q),j<15&&(F+=d[m++]<<j,j+=8,F+=d[m++]<<j,j+=8),ue=Y[F&ie];i:for(;;){if(Q=ue>>>24,F>>>=Q,j-=Q,Q=ue>>>16&255,Q&16){if(he=ue&65535,Q&=15,j<Q&&(F+=d[m++]<<j,j+=8,j<Q&&(F+=d[m++]<<j,j+=8)),he+=F&(1<<Q)-1,he>A){o.msg="invalid distance too far back",l.mode=t;break e}if(F>>>=Q,j-=Q,Q=E-C,he>Q){if(Q=he-Q,Q>P&&l.sane){o.msg="invalid distance too far back",l.mode=t;break e}if(ke=0,L=B,R===0){if(ke+=D-Q,Q<ce){ce-=Q;do v[E++]=B[ke++];while(--Q);ke=E-he,L=v}}else if(R<Q){if(ke+=D+R-Q,Q-=R,Q<ce){ce-=Q;do v[E++]=B[ke++];while(--Q);if(ke=0,R<ce){Q=R,ce-=Q;do v[E++]=B[ke++];while(--Q);ke=E-he,L=v}}}else if(ke+=R-Q,Q<ce){ce-=Q;do v[E++]=B[ke++];while(--Q);ke=E-he,L=v}for(;ce>2;)v[E++]=L[ke++],v[E++]=L[ke++],v[E++]=L[ke++],ce-=3;ce&&(v[E++]=L[ke++],ce>1&&(v[E++]=L[ke++]))}else{ke=E-he;do v[E++]=v[ke++],v[E++]=v[ke++],v[E++]=v[ke++],ce-=3;while(ce>2);ce&&(v[E++]=v[ke++],ce>1&&(v[E++]=v[ke++]))}}else if(Q&64){o.msg="invalid distance code",l.mode=t;break e}else{ue=Y[(ue&65535)+(F&(1<<Q)-1)];continue i}break}}else if(Q&64)if(Q&32){l.mode=e;break e}else{o.msg="invalid literal/length code",l.mode=t;break e}else{ue=N[(ue&65535)+(F&(1<<Q)-1)];continue t}break}}while(m<y&&E<k);ce=j>>3,m-=ce,j-=ce<<3,F&=(1<<j)-1,o.next_in=m,o.next_out=E,o.avail_in=m<y?5+(y-m):5-(m-y),o.avail_out=E<k?257+(k-E):257-(E-k),l.hold=F,l.bits=j},inffast}var inftrees,hasRequiredInftrees;function requireInftrees(){if(hasRequiredInftrees)return inftrees;hasRequiredInftrees=1;var t=requireCommon(),e=15,n=852,o=592,u=0,l=1,m=2,y=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],E=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],C=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],k=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];return inftrees=function(D,P,R,B,F,j,N,Y){var J=Y.bits,ie=0,ue=0,Q=0,ce=0,he=0,ke=0,L=0,d=0,v=0,w=0,c,p,x,S,b,h=null,T=0,M,O=new t.Buf16(e+1),V=new t.Buf16(e+1),ee=null,Z=0,U,z,ne;for(ie=0;ie<=e;ie++)O[ie]=0;for(ue=0;ue<B;ue++)O[P[R+ue]]++;for(he=J,ce=e;ce>=1&&O[ce]===0;ce--);if(he>ce&&(he=ce),ce===0)return F[j++]=1<<24|64<<16|0,F[j++]=1<<24|64<<16|0,Y.bits=1,0;for(Q=1;Q<ce&&O[Q]===0;Q++);for(he<Q&&(he=Q),d=1,ie=1;ie<=e;ie++)if(d<<=1,d-=O[ie],d<0)return-1;if(d>0&&(D===u||ce!==1))return-1;for(V[1]=0,ie=1;ie<e;ie++)V[ie+1]=V[ie]+O[ie];for(ue=0;ue<B;ue++)P[R+ue]!==0&&(N[V[P[R+ue]]++]=ue);if(D===u?(h=ee=N,M=19):D===l?(h=y,T-=257,ee=E,Z-=257,M=256):(h=C,ee=k,M=-1),w=0,ue=0,ie=Q,b=j,ke=he,L=0,x=-1,v=1<<he,S=v-1,D===l&&v>n||D===m&&v>o)return 1;for(;;){U=ie-L,N[ue]<M?(z=0,ne=N[ue]):N[ue]>M?(z=ee[Z+N[ue]],ne=h[T+N[ue]]):(z=96,ne=0),c=1<<ie-L,p=1<<ke,Q=p;do p-=c,F[b+(w>>L)+p]=U<<24|z<<16|ne|0;while(p!==0);for(c=1<<ie-1;w&c;)c>>=1;if(c!==0?(w&=c-1,w+=c):w=0,ue++,--O[ie]===0){if(ie===ce)break;ie=P[R+N[ue]]}if(ie>he&&(w&S)!==x){for(L===0&&(L=he),b+=Q,ke=ie-L,d=1<<ke;ke+L<ce&&(d-=O[ke+L],!(d<=0));)ke++,d<<=1;if(v+=1<<ke,D===l&&v>n||D===m&&v>o)return 1;x=w&S,F[x]=he<<24|ke<<16|b-j|0}}return w!==0&&(F[b+w]=ie-L<<24|64<<16|0),Y.bits=he,0},inftrees}var hasRequiredInflate;function requireInflate(){if(hasRequiredInflate)return inflate;hasRequiredInflate=1;var t=requireCommon(),e=requireAdler32(),n=requireCrc32(),o=requireInffast(),u=requireInftrees(),l=0,m=1,y=2,E=4,C=5,k=6,A=0,D=1,P=2,R=-2,B=-3,F=-4,j=-5,N=8,Y=1,J=2,ie=3,ue=4,Q=5,ce=6,he=7,ke=8,L=9,d=10,v=11,w=12,c=13,p=14,x=15,S=16,b=17,h=18,T=19,M=20,O=21,V=22,ee=23,Z=24,U=25,z=26,ne=27,fe=28,me=29,de=30,je=31,lt=32,it=852,ot=592,Ct=15,nt=Ct;function Je(Qe){return(Qe>>>24&255)+(Qe>>>8&65280)+((Qe&65280)<<8)+((Qe&255)<<24)}function tt(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new t.Buf16(320),this.work=new t.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function rt(Qe){var Ke;return!Qe||!Qe.state?R:(Ke=Qe.state,Qe.total_in=Qe.total_out=Ke.total=0,Qe.msg="",Ke.wrap&&(Qe.adler=Ke.wrap&1),Ke.mode=Y,Ke.last=0,Ke.havedict=0,Ke.dmax=32768,Ke.head=null,Ke.hold=0,Ke.bits=0,Ke.lencode=Ke.lendyn=new t.Buf32(it),Ke.distcode=Ke.distdyn=new t.Buf32(ot),Ke.sane=1,Ke.back=-1,A)}function ht(Qe){var Ke;return!Qe||!Qe.state?R:(Ke=Qe.state,Ke.wsize=0,Ke.whave=0,Ke.wnext=0,rt(Qe))}function Ot(Qe,Ke){var De,Vt;return!Qe||!Qe.state||(Vt=Qe.state,Ke<0?(De=0,Ke=-Ke):(De=(Ke>>4)+1,Ke<48&&(Ke&=15)),Ke&&(Ke<8||Ke>15))?R:(Vt.window!==null&&Vt.wbits!==Ke&&(Vt.window=null),Vt.wrap=De,Vt.wbits=Ke,ht(Qe))}function Ve(Qe,Ke){var De,Vt;return Qe?(Vt=new tt,Qe.state=Vt,Vt.window=null,De=Ot(Qe,Ke),De!==A&&(Qe.state=null),De):R}function We(Qe){return Ve(Qe,nt)}var Gt=!0,wt,Et;function Yt(Qe){if(Gt){var Ke;for(wt=new t.Buf32(512),Et=new t.Buf32(32),Ke=0;Ke<144;)Qe.lens[Ke++]=8;for(;Ke<256;)Qe.lens[Ke++]=9;for(;Ke<280;)Qe.lens[Ke++]=7;for(;Ke<288;)Qe.lens[Ke++]=8;for(u(m,Qe.lens,0,288,wt,0,Qe.work,{bits:9}),Ke=0;Ke<32;)Qe.lens[Ke++]=5;u(y,Qe.lens,0,32,Et,0,Qe.work,{bits:5}),Gt=!1}Qe.lencode=wt,Qe.lenbits=9,Qe.distcode=Et,Qe.distbits=5}function Ce(Qe,Ke,De,Vt){var At,ve=Qe.state;return ve.window===null&&(ve.wsize=1<<ve.wbits,ve.wnext=0,ve.whave=0,ve.window=new t.Buf8(ve.wsize)),Vt>=ve.wsize?(t.arraySet(ve.window,Ke,De-ve.wsize,ve.wsize,0),ve.wnext=0,ve.whave=ve.wsize):(At=ve.wsize-ve.wnext,At>Vt&&(At=Vt),t.arraySet(ve.window,Ke,De-Vt,At,ve.wnext),Vt-=At,Vt?(t.arraySet(ve.window,Ke,De-Vt,Vt,0),ve.wnext=Vt,ve.whave=ve.wsize):(ve.wnext+=At,ve.wnext===ve.wsize&&(ve.wnext=0),ve.whave<ve.wsize&&(ve.whave+=At))),0}function te(Qe,Ke){var De,Vt,At,ve,Pt,pt,Ne,vt,ut,$t,fi,kt,Wt,Zi,Ut=0,Xt,Be,be,ge,oe,Ae,qe,bt,at=new t.Buf8(4),gt,ei,ii=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!Qe||!Qe.state||!Qe.output||!Qe.input&&Qe.avail_in!==0)return R;De=Qe.state,De.mode===w&&(De.mode=c),Pt=Qe.next_out,At=Qe.output,Ne=Qe.avail_out,ve=Qe.next_in,Vt=Qe.input,pt=Qe.avail_in,vt=De.hold,ut=De.bits,$t=pt,fi=Ne,bt=A;e:for(;;)switch(De.mode){case Y:if(De.wrap===0){De.mode=c;break}for(;ut<16;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(De.wrap&2&&vt===35615){De.check=0,at[0]=vt&255,at[1]=vt>>>8&255,De.check=n(De.check,at,2,0),vt=0,ut=0,De.mode=J;break}if(De.flags=0,De.head&&(De.head.done=!1),!(De.wrap&1)||(((vt&255)<<8)+(vt>>8))%31){Qe.msg="incorrect header check",De.mode=de;break}if((vt&15)!==N){Qe.msg="unknown compression method",De.mode=de;break}if(vt>>>=4,ut-=4,qe=(vt&15)+8,De.wbits===0)De.wbits=qe;else if(qe>De.wbits){Qe.msg="invalid window size",De.mode=de;break}De.dmax=1<<qe,Qe.adler=De.check=1,De.mode=vt&512?d:w,vt=0,ut=0;break;case J:for(;ut<16;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(De.flags=vt,(De.flags&255)!==N){Qe.msg="unknown compression method",De.mode=de;break}if(De.flags&57344){Qe.msg="unknown header flags set",De.mode=de;break}De.head&&(De.head.text=vt>>8&1),De.flags&512&&(at[0]=vt&255,at[1]=vt>>>8&255,De.check=n(De.check,at,2,0)),vt=0,ut=0,De.mode=ie;case ie:for(;ut<32;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}De.head&&(De.head.time=vt),De.flags&512&&(at[0]=vt&255,at[1]=vt>>>8&255,at[2]=vt>>>16&255,at[3]=vt>>>24&255,De.check=n(De.check,at,4,0)),vt=0,ut=0,De.mode=ue;case ue:for(;ut<16;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}De.head&&(De.head.xflags=vt&255,De.head.os=vt>>8),De.flags&512&&(at[0]=vt&255,at[1]=vt>>>8&255,De.check=n(De.check,at,2,0)),vt=0,ut=0,De.mode=Q;case Q:if(De.flags&1024){for(;ut<16;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}De.length=vt,De.head&&(De.head.extra_len=vt),De.flags&512&&(at[0]=vt&255,at[1]=vt>>>8&255,De.check=n(De.check,at,2,0)),vt=0,ut=0}else De.head&&(De.head.extra=null);De.mode=ce;case ce:if(De.flags&1024&&(kt=De.length,kt>pt&&(kt=pt),kt&&(De.head&&(qe=De.head.extra_len-De.length,De.head.extra||(De.head.extra=new Array(De.head.extra_len)),t.arraySet(De.head.extra,Vt,ve,kt,qe)),De.flags&512&&(De.check=n(De.check,Vt,kt,ve)),pt-=kt,ve+=kt,De.length-=kt),De.length))break e;De.length=0,De.mode=he;case he:if(De.flags&2048){if(pt===0)break e;kt=0;do qe=Vt[ve+kt++],De.head&&qe&&De.length<65536&&(De.head.name+=String.fromCharCode(qe));while(qe&&kt<pt);if(De.flags&512&&(De.check=n(De.check,Vt,kt,ve)),pt-=kt,ve+=kt,qe)break e}else De.head&&(De.head.name=null);De.length=0,De.mode=ke;case ke:if(De.flags&4096){if(pt===0)break e;kt=0;do qe=Vt[ve+kt++],De.head&&qe&&De.length<65536&&(De.head.comment+=String.fromCharCode(qe));while(qe&&kt<pt);if(De.flags&512&&(De.check=n(De.check,Vt,kt,ve)),pt-=kt,ve+=kt,qe)break e}else De.head&&(De.head.comment=null);De.mode=L;case L:if(De.flags&512){for(;ut<16;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(vt!==(De.check&65535)){Qe.msg="header crc mismatch",De.mode=de;break}vt=0,ut=0}De.head&&(De.head.hcrc=De.flags>>9&1,De.head.done=!0),Qe.adler=De.check=0,De.mode=w;break;case d:for(;ut<32;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}Qe.adler=De.check=Je(vt),vt=0,ut=0,De.mode=v;case v:if(De.havedict===0)return Qe.next_out=Pt,Qe.avail_out=Ne,Qe.next_in=ve,Qe.avail_in=pt,De.hold=vt,De.bits=ut,P;Qe.adler=De.check=1,De.mode=w;case w:if(Ke===C||Ke===k)break e;case c:if(De.last){vt>>>=ut&7,ut-=ut&7,De.mode=ne;break}for(;ut<3;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}switch(De.last=vt&1,vt>>>=1,ut-=1,vt&3){case 0:De.mode=p;break;case 1:if(Yt(De),De.mode=M,Ke===k){vt>>>=2,ut-=2;break e}break;case 2:De.mode=b;break;case 3:Qe.msg="invalid block type",De.mode=de}vt>>>=2,ut-=2;break;case p:for(vt>>>=ut&7,ut-=ut&7;ut<32;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if((vt&65535)!==(vt>>>16^65535)){Qe.msg="invalid stored block lengths",De.mode=de;break}if(De.length=vt&65535,vt=0,ut=0,De.mode=x,Ke===k)break e;case x:De.mode=S;case S:if(kt=De.length,kt){if(kt>pt&&(kt=pt),kt>Ne&&(kt=Ne),kt===0)break e;t.arraySet(At,Vt,ve,kt,Pt),pt-=kt,ve+=kt,Ne-=kt,Pt+=kt,De.length-=kt;break}De.mode=w;break;case b:for(;ut<14;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(De.nlen=(vt&31)+257,vt>>>=5,ut-=5,De.ndist=(vt&31)+1,vt>>>=5,ut-=5,De.ncode=(vt&15)+4,vt>>>=4,ut-=4,De.nlen>286||De.ndist>30){Qe.msg="too many length or distance symbols",De.mode=de;break}De.have=0,De.mode=h;case h:for(;De.have<De.ncode;){for(;ut<3;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}De.lens[ii[De.have++]]=vt&7,vt>>>=3,ut-=3}for(;De.have<19;)De.lens[ii[De.have++]]=0;if(De.lencode=De.lendyn,De.lenbits=7,gt={bits:De.lenbits},bt=u(l,De.lens,0,19,De.lencode,0,De.work,gt),De.lenbits=gt.bits,bt){Qe.msg="invalid code lengths set",De.mode=de;break}De.have=0,De.mode=T;case T:for(;De.have<De.nlen+De.ndist;){for(;Ut=De.lencode[vt&(1<<De.lenbits)-1],Xt=Ut>>>24,Be=Ut>>>16&255,be=Ut&65535,!(Xt<=ut);){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(be<16)vt>>>=Xt,ut-=Xt,De.lens[De.have++]=be;else{if(be===16){for(ei=Xt+2;ut<ei;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(vt>>>=Xt,ut-=Xt,De.have===0){Qe.msg="invalid bit length repeat",De.mode=de;break}qe=De.lens[De.have-1],kt=3+(vt&3),vt>>>=2,ut-=2}else if(be===17){for(ei=Xt+3;ut<ei;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}vt>>>=Xt,ut-=Xt,qe=0,kt=3+(vt&7),vt>>>=3,ut-=3}else{for(ei=Xt+7;ut<ei;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}vt>>>=Xt,ut-=Xt,qe=0,kt=11+(vt&127),vt>>>=7,ut-=7}if(De.have+kt>De.nlen+De.ndist){Qe.msg="invalid bit length repeat",De.mode=de;break}for(;kt--;)De.lens[De.have++]=qe}}if(De.mode===de)break;if(De.lens[256]===0){Qe.msg="invalid code -- missing end-of-block",De.mode=de;break}if(De.lenbits=9,gt={bits:De.lenbits},bt=u(m,De.lens,0,De.nlen,De.lencode,0,De.work,gt),De.lenbits=gt.bits,bt){Qe.msg="invalid literal/lengths set",De.mode=de;break}if(De.distbits=6,De.distcode=De.distdyn,gt={bits:De.distbits},bt=u(y,De.lens,De.nlen,De.ndist,De.distcode,0,De.work,gt),De.distbits=gt.bits,bt){Qe.msg="invalid distances set",De.mode=de;break}if(De.mode=M,Ke===k)break e;case M:De.mode=O;case O:if(pt>=6&&Ne>=258){Qe.next_out=Pt,Qe.avail_out=Ne,Qe.next_in=ve,Qe.avail_in=pt,De.hold=vt,De.bits=ut,o(Qe,fi),Pt=Qe.next_out,At=Qe.output,Ne=Qe.avail_out,ve=Qe.next_in,Vt=Qe.input,pt=Qe.avail_in,vt=De.hold,ut=De.bits,De.mode===w&&(De.back=-1);break}for(De.back=0;Ut=De.lencode[vt&(1<<De.lenbits)-1],Xt=Ut>>>24,Be=Ut>>>16&255,be=Ut&65535,!(Xt<=ut);){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(Be&&!(Be&240)){for(ge=Xt,oe=Be,Ae=be;Ut=De.lencode[Ae+((vt&(1<<ge+oe)-1)>>ge)],Xt=Ut>>>24,Be=Ut>>>16&255,be=Ut&65535,!(ge+Xt<=ut);){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}vt>>>=ge,ut-=ge,De.back+=ge}if(vt>>>=Xt,ut-=Xt,De.back+=Xt,De.length=be,Be===0){De.mode=z;break}if(Be&32){De.back=-1,De.mode=w;break}if(Be&64){Qe.msg="invalid literal/length code",De.mode=de;break}De.extra=Be&15,De.mode=V;case V:if(De.extra){for(ei=De.extra;ut<ei;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}De.length+=vt&(1<<De.extra)-1,vt>>>=De.extra,ut-=De.extra,De.back+=De.extra}De.was=De.length,De.mode=ee;case ee:for(;Ut=De.distcode[vt&(1<<De.distbits)-1],Xt=Ut>>>24,Be=Ut>>>16&255,be=Ut&65535,!(Xt<=ut);){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(!(Be&240)){for(ge=Xt,oe=Be,Ae=be;Ut=De.distcode[Ae+((vt&(1<<ge+oe)-1)>>ge)],Xt=Ut>>>24,Be=Ut>>>16&255,be=Ut&65535,!(ge+Xt<=ut);){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}vt>>>=ge,ut-=ge,De.back+=ge}if(vt>>>=Xt,ut-=Xt,De.back+=Xt,Be&64){Qe.msg="invalid distance code",De.mode=de;break}De.offset=be,De.extra=Be&15,De.mode=Z;case Z:if(De.extra){for(ei=De.extra;ut<ei;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}De.offset+=vt&(1<<De.extra)-1,vt>>>=De.extra,ut-=De.extra,De.back+=De.extra}if(De.offset>De.dmax){Qe.msg="invalid distance too far back",De.mode=de;break}De.mode=U;case U:if(Ne===0)break e;if(kt=fi-Ne,De.offset>kt){if(kt=De.offset-kt,kt>De.whave&&De.sane){Qe.msg="invalid distance too far back",De.mode=de;break}kt>De.wnext?(kt-=De.wnext,Wt=De.wsize-kt):Wt=De.wnext-kt,kt>De.length&&(kt=De.length),Zi=De.window}else Zi=At,Wt=Pt-De.offset,kt=De.length;kt>Ne&&(kt=Ne),Ne-=kt,De.length-=kt;do At[Pt++]=Zi[Wt++];while(--kt);De.length===0&&(De.mode=O);break;case z:if(Ne===0)break e;At[Pt++]=De.length,Ne--,De.mode=O;break;case ne:if(De.wrap){for(;ut<32;){if(pt===0)break e;pt--,vt|=Vt[ve++]<<ut,ut+=8}if(fi-=Ne,Qe.total_out+=fi,De.total+=fi,fi&&(Qe.adler=De.check=De.flags?n(De.check,At,fi,Pt-fi):e(De.check,At,fi,Pt-fi)),fi=Ne,(De.flags?vt:Je(vt))!==De.check){Qe.msg="incorrect data check",De.mode=de;break}vt=0,ut=0}De.mode=fe;case fe:if(De.wrap&&De.flags){for(;ut<32;){if(pt===0)break e;pt--,vt+=Vt[ve++]<<ut,ut+=8}if(vt!==(De.total&4294967295)){Qe.msg="incorrect length check",De.mode=de;break}vt=0,ut=0}De.mode=me;case me:bt=D;break e;case de:bt=B;break e;case je:return F;case lt:default:return R}return Qe.next_out=Pt,Qe.avail_out=Ne,Qe.next_in=ve,Qe.avail_in=pt,De.hold=vt,De.bits=ut,(De.wsize||fi!==Qe.avail_out&&De.mode<de&&(De.mode<ne||Ke!==E))&&Ce(Qe,Qe.output,Qe.next_out,fi-Qe.avail_out),$t-=Qe.avail_in,fi-=Qe.avail_out,Qe.total_in+=$t,Qe.total_out+=fi,De.total+=fi,De.wrap&&fi&&(Qe.adler=De.check=De.flags?n(De.check,At,fi,Qe.next_out-fi):e(De.check,At,fi,Qe.next_out-fi)),Qe.data_type=De.bits+(De.last?64:0)+(De.mode===w?128:0)+(De.mode===M||De.mode===x?256:0),($t===0&&fi===0||Ke===E)&&bt===A&&(bt=j),bt}function ye(Qe){if(!Qe||!Qe.state)return R;var Ke=Qe.state;return Ke.window&&(Ke.window=null),Qe.state=null,A}function Le(Qe,Ke){var De;return!Qe||!Qe.state||(De=Qe.state,!(De.wrap&2))?R:(De.head=Ke,Ke.done=!1,A)}function Ue(Qe,Ke){var De=Ke.length,Vt,At,ve;return!Qe||!Qe.state||(Vt=Qe.state,Vt.wrap!==0&&Vt.mode!==v)?R:Vt.mode===v&&(At=1,At=e(At,Ke,De,0),At!==Vt.check)?B:(ve=Ce(Qe,Ke,De,De),ve?(Vt.mode=je,F):(Vt.havedict=1,A))}return inflate.inflateReset=ht,inflate.inflateReset2=Ot,inflate.inflateResetKeep=rt,inflate.inflateInit=We,inflate.inflateInit2=Ve,inflate.inflate=te,inflate.inflateEnd=ye,inflate.inflateGetHeader=Le,inflate.inflateSetDictionary=Ue,inflate.inflateInfo="pako inflate (from Nodeca project)",inflate}var constants,hasRequiredConstants;function requireConstants(){return hasRequiredConstants||(hasRequiredConstants=1,constants={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}),constants}var hasRequiredBinding;function requireBinding(){return hasRequiredBinding||(hasRequiredBinding=1,function(t){var e=requireAssert$1(),n=requireZstream(),o=requireDeflate(),u=requireInflate(),l=requireConstants();for(var m in l)t[m]=l[m];t.NONE=0,t.DEFLATE=1,t.INFLATE=2,t.GZIP=3,t.GUNZIP=4,t.DEFLATERAW=5,t.INFLATERAW=6,t.UNZIP=7;var y=31,E=139;function C(k){if(typeof k!="number"||k<t.DEFLATE||k>t.UNZIP)throw new TypeError("Bad argument");this.dictionary=null,this.err=0,this.flush=0,this.init_done=!1,this.level=0,this.memLevel=0,this.mode=k,this.strategy=0,this.windowBits=0,this.write_in_progress=!1,this.pending_close=!1,this.gzip_id_bytes_read=0}C.prototype.close=function(){if(this.write_in_progress){this.pending_close=!0;return}this.pending_close=!1,e(this.init_done,"close before init"),e(this.mode<=t.UNZIP),this.mode===t.DEFLATE||this.mode===t.GZIP||this.mode===t.DEFLATERAW?o.deflateEnd(this.strm):(this.mode===t.INFLATE||this.mode===t.GUNZIP||this.mode===t.INFLATERAW||this.mode===t.UNZIP)&&u.inflateEnd(this.strm),this.mode=t.NONE,this.dictionary=null},C.prototype.write=function(k,A,D,P,R,B,F){return this._write(!0,k,A,D,P,R,B,F)},C.prototype.writeSync=function(k,A,D,P,R,B,F){return this._write(!1,k,A,D,P,R,B,F)},C.prototype._write=function(k,A,D,P,R,B,F,j){if(e.equal(arguments.length,8),e(this.init_done,"write before init"),e(this.mode!==t.NONE,"already finalized"),e.equal(!1,this.write_in_progress,"write already in progress"),e.equal(!1,this.pending_close,"close is pending"),this.write_in_progress=!0,e.equal(!1,A===void 0,"must provide flush value"),this.write_in_progress=!0,A!==t.Z_NO_FLUSH&&A!==t.Z_PARTIAL_FLUSH&&A!==t.Z_SYNC_FLUSH&&A!==t.Z_FULL_FLUSH&&A!==t.Z_FINISH&&A!==t.Z_BLOCK)throw new Error("Invalid flush value");if(D==null&&(D=Buffer$C.alloc(0),R=0,P=0),this.strm.avail_in=R,this.strm.input=D,this.strm.next_in=P,this.strm.avail_out=j,this.strm.output=B,this.strm.next_out=F,this.flush=A,!k)return this._process(),this._checkError()?this._afterSync():void 0;var N=this;return process$1.nextTick(function(){N._process(),N._after()}),this},C.prototype._afterSync=function(){var k=this.strm.avail_out,A=this.strm.avail_in;return this.write_in_progress=!1,[A,k]},C.prototype._process=function(){var k=null;switch(this.mode){case t.DEFLATE:case t.GZIP:case t.DEFLATERAW:this.err=o.deflate(this.strm,this.flush);break;case t.UNZIP:switch(this.strm.avail_in>0&&(k=this.strm.next_in),this.gzip_id_bytes_read){case 0:if(k===null)break;if(this.strm.input[k]===y){if(this.gzip_id_bytes_read=1,k++,this.strm.avail_in===1)break}else{this.mode=t.INFLATE;break}case 1:if(k===null)break;this.strm.input[k]===E?(this.gzip_id_bytes_read=2,this.mode=t.GUNZIP):this.mode=t.INFLATE;break;default:throw new Error("invalid number of gzip magic number bytes read")}case t.INFLATE:case t.GUNZIP:case t.INFLATERAW:for(this.err=u.inflate(this.strm,this.flush),this.err===t.Z_NEED_DICT&&this.dictionary&&(this.err=u.inflateSetDictionary(this.strm,this.dictionary),this.err===t.Z_OK?this.err=u.inflate(this.strm,this.flush):this.err===t.Z_DATA_ERROR&&(this.err=t.Z_NEED_DICT));this.strm.avail_in>0&&this.mode===t.GUNZIP&&this.err===t.Z_STREAM_END&&this.strm.next_in[0]!==0;)this.reset(),this.err=u.inflate(this.strm,this.flush);break;default:throw new Error("Unknown mode "+this.mode)}},C.prototype._checkError=function(){switch(this.err){case t.Z_OK:case t.Z_BUF_ERROR:if(this.strm.avail_out!==0&&this.flush===t.Z_FINISH)return this._error("unexpected end of file"),!1;break;case t.Z_STREAM_END:break;case t.Z_NEED_DICT:return this.dictionary==null?this._error("Missing dictionary"):this._error("Bad dictionary"),!1;default:return this._error("Zlib error"),!1}return!0},C.prototype._after=function(){if(this._checkError()){var k=this.strm.avail_out,A=this.strm.avail_in;this.write_in_progress=!1,this.callback(A,k),this.pending_close&&this.close()}},C.prototype._error=function(k){this.strm.msg&&(k=this.strm.msg),this.onerror(k,this.err),this.write_in_progress=!1,this.pending_close&&this.close()},C.prototype.init=function(k,A,D,P,R){e(arguments.length===4||arguments.length===5,"init(windowBits, level, memLevel, strategy, [dictionary])"),e(k>=8&&k<=15,"invalid windowBits"),e(A>=-1&&A<=9,"invalid compression level"),e(D>=1&&D<=9,"invalid memlevel"),e(P===t.Z_FILTERED||P===t.Z_HUFFMAN_ONLY||P===t.Z_RLE||P===t.Z_FIXED||P===t.Z_DEFAULT_STRATEGY,"invalid strategy"),this._init(A,k,D,P,R),this._setDictionary()},C.prototype.params=function(){throw new Error("deflateParams Not supported")},C.prototype.reset=function(){this._reset(),this._setDictionary()},C.prototype._init=function(k,A,D,P,R){switch(this.level=k,this.windowBits=A,this.memLevel=D,this.strategy=P,this.flush=t.Z_NO_FLUSH,this.err=t.Z_OK,(this.mode===t.GZIP||this.mode===t.GUNZIP)&&(this.windowBits+=16),this.mode===t.UNZIP&&(this.windowBits+=32),(this.mode===t.DEFLATERAW||this.mode===t.INFLATERAW)&&(this.windowBits=-1*this.windowBits),this.strm=new n,this.mode){case t.DEFLATE:case t.GZIP:case t.DEFLATERAW:this.err=o.deflateInit2(this.strm,this.level,t.Z_DEFLATED,this.windowBits,this.memLevel,this.strategy);break;case t.INFLATE:case t.GUNZIP:case t.INFLATERAW:case t.UNZIP:this.err=u.inflateInit2(this.strm,this.windowBits);break;default:throw new Error("Unknown mode "+this.mode)}this.err!==t.Z_OK&&this._error("Init error"),this.dictionary=R,this.write_in_progress=!1,this.init_done=!0},C.prototype._setDictionary=function(){if(this.dictionary!=null){switch(this.err=t.Z_OK,this.mode){case t.DEFLATE:case t.DEFLATERAW:this.err=o.deflateSetDictionary(this.strm,this.dictionary);break}this.err!==t.Z_OK&&this._error("Failed to set dictionary")}},C.prototype._reset=function(){switch(this.err=t.Z_OK,this.mode){case t.DEFLATE:case t.DEFLATERAW:case t.GZIP:this.err=o.deflateReset(this.strm);break;case t.INFLATE:case t.INFLATERAW:case t.GUNZIP:this.err=u.inflateReset(this.strm);break}this.err!==t.Z_OK&&this._error("Failed to reset stream")},t.Zlib=C}(binding)),binding}var hasRequiredLib$5;function requireLib$5(){return hasRequiredLib$5||(hasRequiredLib$5=1,function(t){var e=require$$0$2.Buffer,n=requireStreamBrowserify().Transform,o=requireBinding(),u=util$6,l=requireAssert$1().ok,m=require$$0$2.kMaxLength,y="Cannot create final Buffer. It would be larger than 0x"+m.toString(16)+" bytes";o.Z_MIN_WINDOWBITS=8,o.Z_MAX_WINDOWBITS=15,o.Z_DEFAULT_WINDOWBITS=15,o.Z_MIN_CHUNK=64,o.Z_MAX_CHUNK=1/0,o.Z_DEFAULT_CHUNK=16*1024,o.Z_MIN_MEMLEVEL=1,o.Z_MAX_MEMLEVEL=9,o.Z_DEFAULT_MEMLEVEL=8,o.Z_MIN_LEVEL=-1,o.Z_MAX_LEVEL=9,o.Z_DEFAULT_LEVEL=o.Z_DEFAULT_COMPRESSION;for(var E=Object.keys(o),C=0;C<E.length;C++){var k=E[C];k.match(/^Z/)&&Object.defineProperty(t,k,{enumerable:!0,value:o[k],writable:!1})}for(var A={Z_OK:o.Z_OK,Z_STREAM_END:o.Z_STREAM_END,Z_NEED_DICT:o.Z_NEED_DICT,Z_ERRNO:o.Z_ERRNO,Z_STREAM_ERROR:o.Z_STREAM_ERROR,Z_DATA_ERROR:o.Z_DATA_ERROR,Z_MEM_ERROR:o.Z_MEM_ERROR,Z_BUF_ERROR:o.Z_BUF_ERROR,Z_VERSION_ERROR:o.Z_VERSION_ERROR},D=Object.keys(A),P=0;P<D.length;P++){var R=D[P];A[A[R]]=R}Object.defineProperty(t,"codes",{enumerable:!0,value:Object.freeze(A),writable:!1}),t.Deflate=j,t.Inflate=N,t.Gzip=Y,t.Gunzip=J,t.DeflateRaw=ie,t.InflateRaw=ue,t.Unzip=Q,t.createDeflate=function(d){return new j(d)},t.createInflate=function(d){return new N(d)},t.createDeflateRaw=function(d){return new ie(d)},t.createInflateRaw=function(d){return new ue(d)},t.createGzip=function(d){return new Y(d)},t.createGunzip=function(d){return new J(d)},t.createUnzip=function(d){return new Q(d)},t.deflate=function(d,v,w){return typeof v=="function"&&(w=v,v={}),B(new j(v),d,w)},t.deflateSync=function(d,v){return F(new j(v),d)},t.gzip=function(d,v,w){return typeof v=="function"&&(w=v,v={}),B(new Y(v),d,w)},t.gzipSync=function(d,v){return F(new Y(v),d)},t.deflateRaw=function(d,v,w){return typeof v=="function"&&(w=v,v={}),B(new ie(v),d,w)},t.deflateRawSync=function(d,v){return F(new ie(v),d)},t.unzip=function(d,v,w){return typeof v=="function"&&(w=v,v={}),B(new Q(v),d,w)},t.unzipSync=function(d,v){return F(new Q(v),d)},t.inflate=function(d,v,w){return typeof v=="function"&&(w=v,v={}),B(new N(v),d,w)},t.inflateSync=function(d,v){return F(new N(v),d)},t.gunzip=function(d,v,w){return typeof v=="function"&&(w=v,v={}),B(new J(v),d,w)},t.gunzipSync=function(d,v){return F(new J(v),d)},t.inflateRaw=function(d,v,w){return typeof v=="function"&&(w=v,v={}),B(new ue(v),d,w)},t.inflateRawSync=function(d,v){return F(new ue(v),d)};function B(d,v,w){var c=[],p=0;d.on("error",S),d.on("end",b),d.end(v),x();function x(){for(var h;(h=d.read())!==null;)c.push(h),p+=h.length;d.once("readable",x)}function S(h){d.removeListener("end",b),d.removeListener("readable",x),w(h)}function b(){var h,T=null;p>=m?T=new RangeError(y):h=e.concat(c,p),c=[],d.close(),w(T,h)}}function F(d,v){if(typeof v=="string"&&(v=e.from(v)),!e.isBuffer(v))throw new TypeError("Not a string or buffer");var w=d._finishFlushFlag;return d._processChunk(v,w)}function j(d){if(!(this instanceof j))return new j(d);he.call(this,d,o.DEFLATE)}function N(d){if(!(this instanceof N))return new N(d);he.call(this,d,o.INFLATE)}function Y(d){if(!(this instanceof Y))return new Y(d);he.call(this,d,o.GZIP)}function J(d){if(!(this instanceof J))return new J(d);he.call(this,d,o.GUNZIP)}function ie(d){if(!(this instanceof ie))return new ie(d);he.call(this,d,o.DEFLATERAW)}function ue(d){if(!(this instanceof ue))return new ue(d);he.call(this,d,o.INFLATERAW)}function Q(d){if(!(this instanceof Q))return new Q(d);he.call(this,d,o.UNZIP)}function ce(d){return d===o.Z_NO_FLUSH||d===o.Z_PARTIAL_FLUSH||d===o.Z_SYNC_FLUSH||d===o.Z_FULL_FLUSH||d===o.Z_FINISH||d===o.Z_BLOCK}function he(d,v){var w=this;if(this._opts=d=d||{},this._chunkSize=d.chunkSize||t.Z_DEFAULT_CHUNK,n.call(this,d),d.flush&&!ce(d.flush))throw new Error("Invalid flush flag: "+d.flush);if(d.finishFlush&&!ce(d.finishFlush))throw new Error("Invalid flush flag: "+d.finishFlush);if(this._flushFlag=d.flush||o.Z_NO_FLUSH,this._finishFlushFlag=typeof d.finishFlush<"u"?d.finishFlush:o.Z_FINISH,d.chunkSize&&(d.chunkSize<t.Z_MIN_CHUNK||d.chunkSize>t.Z_MAX_CHUNK))throw new Error("Invalid chunk size: "+d.chunkSize);if(d.windowBits&&(d.windowBits<t.Z_MIN_WINDOWBITS||d.windowBits>t.Z_MAX_WINDOWBITS))throw new Error("Invalid windowBits: "+d.windowBits);if(d.level&&(d.level<t.Z_MIN_LEVEL||d.level>t.Z_MAX_LEVEL))throw new Error("Invalid compression level: "+d.level);if(d.memLevel&&(d.memLevel<t.Z_MIN_MEMLEVEL||d.memLevel>t.Z_MAX_MEMLEVEL))throw new Error("Invalid memLevel: "+d.memLevel);if(d.strategy&&d.strategy!=t.Z_FILTERED&&d.strategy!=t.Z_HUFFMAN_ONLY&&d.strategy!=t.Z_RLE&&d.strategy!=t.Z_FIXED&&d.strategy!=t.Z_DEFAULT_STRATEGY)throw new Error("Invalid strategy: "+d.strategy);if(d.dictionary&&!e.isBuffer(d.dictionary))throw new Error("Invalid dictionary: it should be a Buffer instance");this._handle=new o.Zlib(v);var c=this;this._hadError=!1,this._handle.onerror=function(S,b){ke(c),c._hadError=!0;var h=new Error(S);h.errno=b,h.code=t.codes[b],c.emit("error",h)};var p=t.Z_DEFAULT_COMPRESSION;typeof d.level=="number"&&(p=d.level);var x=t.Z_DEFAULT_STRATEGY;typeof d.strategy=="number"&&(x=d.strategy),this._handle.init(d.windowBits||t.Z_DEFAULT_WINDOWBITS,p,d.memLevel||t.Z_DEFAULT_MEMLEVEL,x,d.dictionary),this._buffer=e.allocUnsafe(this._chunkSize),this._offset=0,this._level=p,this._strategy=x,this.once("end",this.close),Object.defineProperty(this,"_closed",{get:function(){return!w._handle},configurable:!0,enumerable:!0})}u.inherits(he,n),he.prototype.params=function(d,v,w){if(d<t.Z_MIN_LEVEL||d>t.Z_MAX_LEVEL)throw new RangeError("Invalid compression level: "+d);if(v!=t.Z_FILTERED&&v!=t.Z_HUFFMAN_ONLY&&v!=t.Z_RLE&&v!=t.Z_FIXED&&v!=t.Z_DEFAULT_STRATEGY)throw new TypeError("Invalid strategy: "+v);if(this._level!==d||this._strategy!==v){var c=this;this.flush(o.Z_SYNC_FLUSH,function(){l(c._handle,"zlib binding closed"),c._handle.params(d,v),c._hadError||(c._level=d,c._strategy=v,w&&w())})}else process$1.nextTick(w)},he.prototype.reset=function(){return l(this._handle,"zlib binding closed"),this._handle.reset()},he.prototype._flush=function(d){this._transform(e.alloc(0),"",d)},he.prototype.flush=function(d,v){var w=this,c=this._writableState;(typeof d=="function"||d===void 0&&!v)&&(v=d,d=o.Z_FULL_FLUSH),c.ended?v&&process$1.nextTick(v):c.ending?v&&this.once("end",v):c.needDrain?v&&this.once("drain",function(){return w.flush(d,v)}):(this._flushFlag=d,this.write(e.alloc(0),"",v))},he.prototype.close=function(d){ke(this,d),process$1.nextTick(L,this)};function ke(d,v){v&&process$1.nextTick(v),d._handle&&(d._handle.close(),d._handle=null)}function L(d){d.emit("close")}he.prototype._transform=function(d,v,w){var c,p=this._writableState,x=p.ending||p.ended,S=x&&(!d||p.length===d.length);if(d!==null&&!e.isBuffer(d))return w(new Error("invalid input"));if(!this._handle)return w(new Error("zlib binding closed"));S?c=this._finishFlushFlag:(c=this._flushFlag,d.length>=p.length&&(this._flushFlag=this._opts.flush||o.Z_NO_FLUSH)),this._processChunk(d,c,w)},he.prototype._processChunk=function(d,v,w){var c=d&&d.length,p=this._chunkSize-this._offset,x=0,S=this,b=typeof w=="function";if(!b){var h=[],T=0,M;this.on("error",function(U){M=U}),l(this._handle,"zlib binding closed");do var O=this._handle.writeSync(v,d,x,c,this._buffer,this._offset,p);while(!this._hadError&&Z(O[0],O[1]));if(this._hadError)throw M;if(T>=m)throw ke(this),new RangeError(y);var V=e.concat(h,T);return ke(this),V}l(this._handle,"zlib binding closed");var ee=this._handle.write(v,d,x,c,this._buffer,this._offset,p);ee.buffer=d,ee.callback=Z;function Z(U,z){if(this&&(this.buffer=null,this.callback=null),!S._hadError){var ne=p-z;if(l(ne>=0,"have should not go down"),ne>0){var fe=S._buffer.slice(S._offset,S._offset+ne);S._offset+=ne,b?S.push(fe):(h.push(fe),T+=fe.length)}if((z===0||S._offset>=S._chunkSize)&&(p=S._chunkSize,S._offset=0,S._buffer=e.allocUnsafe(S._chunkSize)),z===0){if(x+=c-U,c=U,!b)return!0;var me=S._handle.write(v,d,x,c,S._buffer,S._offset,S._chunkSize);me.callback=Z,me.buffer=d;return}if(!b)return!1;w()}}},u.inherits(j,he),u.inherits(N,he),u.inherits(Y,he),u.inherits(J,he),u.inherits(ie,he),u.inherits(ue,he),u.inherits(Q,he)}(lib$5)),lib$5}var awsSign2={exports:{}},hasRequiredAwsSign2;function requireAwsSign2(){if(hasRequiredAwsSign2)return awsSign2.exports;hasRequiredAwsSign2=1;/*!
 *  Copyright 2010 LearnBoost <dev@learnboost.com>
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */var t=requireCryptoBrowserify(),e=require$$2$2.parse,n=["acl","location","logging","notification","partNumber","policy","requestPayment","torrent","uploadId","uploads","versionId","versioning","versions","website"];function o(A){return"AWS "+A.key+":"+l(A)}awsSign2.exports=o,awsSign2.exports.authorization=o;function u(A){return t.createHmac("sha1",A.secret).update(A.message).digest("base64")}awsSign2.exports.hmacSha1=u;function l(A){return A.message=y(A),u(A)}awsSign2.exports.sign=l;function m(A){return A.message=E(A),u(A)}awsSign2.exports.signQuery=m;function y(A){var D=A.amazonHeaders||"";D&&(D+=`
`);var P=[A.verb,A.md5,A.contentType,A.date?A.date.toUTCString():"",D+A.resource];return P.join(`
`)}awsSign2.exports.stringToSign=y;function E(A){return`GET


`+A.date+`
`+A.resource}awsSign2.exports.queryStringToSign=E;function C(A){for(var D=[],P=Object.keys(A),R=0,B=P.length;R<B;++R){var j=P[R],F=A[j],j=j.toLowerCase();j.indexOf("x-amz")===0&&D.push(j+":"+F)}return D.sort().join(`
`)}awsSign2.exports.canonicalizeHeaders=C;function k(A){var D=e(A,!0),P=D.pathname,R=[];return Object.keys(D.query).forEach(function(B){if(~n.indexOf(B)){var F=D.query[B]==""?"":"="+encodeURIComponent(D.query[B]);R.push(B+F)}}),P+(R.length?"?"+R.sort().join("&"):"")}return awsSign2.exports.canonicalizeResource=k,awsSign2.exports}var aws4={};const require$$1$1=getAugmentedNamespace(querystring$2);var lru,hasRequiredLru;function requireLru(){if(hasRequiredLru)return lru;hasRequiredLru=1,lru=function(o){return new t(o)};function t(o){this.capacity=o|0,this.map=Object.create(null),this.list=new e}t.prototype.get=function(o){var u=this.map[o];if(u!=null)return this.used(u),u.val},t.prototype.set=function(o,u){var l=this.map[o];if(l!=null)l.val=u;else{if(this.capacity||this.prune(),!this.capacity)return!1;l=new n(o,u),this.map[o]=l,this.capacity--}return this.used(l),!0},t.prototype.used=function(o){this.list.moveToFront(o)},t.prototype.prune=function(){var o=this.list.pop();o!=null&&(delete this.map[o.key],this.capacity++)};function e(){this.firstNode=null,this.lastNode=null}e.prototype.moveToFront=function(o){this.firstNode!=o&&(this.remove(o),this.firstNode==null?(this.firstNode=o,this.lastNode=o,o.prev=null,o.next=null):(o.prev=null,o.next=this.firstNode,o.next.prev=o,this.firstNode=o))},e.prototype.pop=function(){var o=this.lastNode;return o!=null&&this.remove(o),o},e.prototype.remove=function(o){this.firstNode==o?this.firstNode=o.next:o.prev!=null&&(o.prev.next=o.next),this.lastNode==o?this.lastNode=o.prev:o.next!=null&&(o.next.prev=o.prev)};function n(o,u){this.key=o,this.val=u,this.prev=null,this.next=null}return lru}var hasRequiredAws4;function requireAws4(){return hasRequiredAws4||(hasRequiredAws4=1,function(t){var e=t,n=require$$2$2,o=require$$1$1,u=requireCryptoBrowserify(),l=requireLru(),m=l(1e3);function y(P,R,B){return u.createHmac("sha256",P).update(R,"utf8").digest(B)}function E(P,R){return u.createHash("sha256").update(P,"utf8").digest(R)}function C(P){return P.replace(/[!'()*]/g,function(R){return"%"+R.charCodeAt(0).toString(16).toUpperCase()})}function k(P){return C(encodeURIComponent(P))}var A={authorization:!0,connection:!0,"x-amzn-trace-id":!0,"user-agent":!0,expect:!0,"presigned-expires":!0,range:!0};function D(P,R){typeof P=="string"&&(P=n.parse(P));var B=P.headers=Object.assign({},P.headers||{}),F=(!this.service||!this.region)&&this.matchHost(P.hostname||P.host||B.Host||B.host);this.request=P,this.credentials=R||this.defaultCredentials(),this.service=P.service||F[0]||"",this.region=P.region||F[1]||"us-east-1",this.service==="email"&&(this.service="ses"),!P.method&&P.body&&(P.method="POST"),!B.Host&&!B.host&&(B.Host=P.hostname||P.host||this.createHost(),P.port&&(B.Host+=":"+P.port)),!P.hostname&&!P.host&&(P.hostname=B.Host||B.host),this.isCodeCommitGit=this.service==="codecommit"&&P.method==="GIT",this.extraHeadersToIgnore=P.extraHeadersToIgnore||Object.create(null),this.extraHeadersToInclude=P.extraHeadersToInclude||Object.create(null)}D.prototype.matchHost=function(P){var R=(P||"").match(/([^\.]+)\.(?:([^\.]*)\.)?amazonaws\.com(\.cn)?$/),B=(R||[]).slice(1,3);if((B[1]==="es"||B[1]==="aoss")&&(B=B.reverse()),B[1]=="s3")B[0]="s3",B[1]="us-east-1";else for(var F=0;F<2;F++)if(/^s3-/.test(B[F])){B[1]=B[F].slice(3),B[0]="s3";break}return B},D.prototype.isSingleRegion=function(){return["s3","sdb"].indexOf(this.service)>=0&&this.region==="us-east-1"?!0:["cloudfront","ls","route53","iam","importexport","sts"].indexOf(this.service)>=0},D.prototype.createHost=function(){var P=this.isSingleRegion()?"":"."+this.region,R=this.service==="ses"?"email":this.service;return R+P+".amazonaws.com"},D.prototype.prepareRequest=function(){this.parsePath();var P=this.request,R=P.headers,B;P.signQuery?(this.parsedPath.query=B=this.parsedPath.query||{},this.credentials.sessionToken&&(B["X-Amz-Security-Token"]=this.credentials.sessionToken),this.service==="s3"&&!B["X-Amz-Expires"]&&(B["X-Amz-Expires"]=86400),B["X-Amz-Date"]?this.datetime=B["X-Amz-Date"]:B["X-Amz-Date"]=this.getDateTime(),B["X-Amz-Algorithm"]="AWS4-HMAC-SHA256",B["X-Amz-Credential"]=this.credentials.accessKeyId+"/"+this.credentialString(),B["X-Amz-SignedHeaders"]=this.signedHeaders()):(!P.doNotModifyHeaders&&!this.isCodeCommitGit&&(P.body&&!R["Content-Type"]&&!R["content-type"]&&(R["Content-Type"]="application/x-www-form-urlencoded; charset=utf-8"),P.body&&!R["Content-Length"]&&!R["content-length"]&&(R["Content-Length"]=Buffer$C.byteLength(P.body)),this.credentials.sessionToken&&!R["X-Amz-Security-Token"]&&!R["x-amz-security-token"]&&(R["X-Amz-Security-Token"]=this.credentials.sessionToken),this.service==="s3"&&!R["X-Amz-Content-Sha256"]&&!R["x-amz-content-sha256"]&&(R["X-Amz-Content-Sha256"]=E(this.request.body||"","hex")),R["X-Amz-Date"]||R["x-amz-date"]?this.datetime=R["X-Amz-Date"]||R["x-amz-date"]:R["X-Amz-Date"]=this.getDateTime()),delete R.Authorization,delete R.authorization)},D.prototype.sign=function(){return this.parsedPath||this.prepareRequest(),this.request.signQuery?this.parsedPath.query["X-Amz-Signature"]=this.signature():this.request.headers.Authorization=this.authHeader(),this.request.path=this.formatPath(),this.request},D.prototype.getDateTime=function(){if(!this.datetime){var P=this.request.headers,R=new Date(P.Date||P.date||new Date);this.datetime=R.toISOString().replace(/[:\-]|\.\d{3}/g,""),this.isCodeCommitGit&&(this.datetime=this.datetime.slice(0,-1))}return this.datetime},D.prototype.getDate=function(){return this.getDateTime().substr(0,8)},D.prototype.authHeader=function(){return["AWS4-HMAC-SHA256 Credential="+this.credentials.accessKeyId+"/"+this.credentialString(),"SignedHeaders="+this.signedHeaders(),"Signature="+this.signature()].join(", ")},D.prototype.signature=function(){var P=this.getDate(),R=[this.credentials.secretAccessKey,P,this.region,this.service].join(),B,F,j,N=m.get(R);return N||(B=y("AWS4"+this.credentials.secretAccessKey,P),F=y(B,this.region),j=y(F,this.service),N=y(j,"aws4_request"),m.set(R,N)),y(N,this.stringToSign(),"hex")},D.prototype.stringToSign=function(){return["AWS4-HMAC-SHA256",this.getDateTime(),this.credentialString(),E(this.canonicalString(),"hex")].join(`
`)},D.prototype.canonicalString=function(){this.parsedPath||this.prepareRequest();var P=this.parsedPath.path,R=this.parsedPath.query,B=this.request.headers,F="",j=this.service!=="s3",N=this.service==="s3"||this.request.doNotEncodePath,Y=this.service==="s3",J=this.service==="s3",ie;if(this.service==="s3"&&this.request.signQuery?ie="UNSIGNED-PAYLOAD":this.isCodeCommitGit?ie="":ie=B["X-Amz-Content-Sha256"]||B["x-amz-content-sha256"]||E(this.request.body||"","hex"),R){var ue=Object.keys(R).reduce(function(ce,he){return he&&(ce[k(he)]=Array.isArray(R[he])&&J?R[he][0]:R[he]),ce},{}),Q=[];Object.keys(ue).sort().forEach(function(ce){Array.isArray(ue[ce])?ue[ce].map(k).sort().forEach(function(he){Q.push(ce+"="+he)}):Q.push(ce+"="+k(ue[ce]))}),F=Q.join("&")}return P!=="/"&&(j&&(P=P.replace(/\/{2,}/g,"/")),P=P.split("/").reduce(function(ce,he){return j&&he===".."?ce.pop():(!j||he!==".")&&(N&&(he=decodeURIComponent(he.replace(/\+/g," "))),ce.push(k(he))),ce},[]).join("/"),P[0]!=="/"&&(P="/"+P),Y&&(P=P.replace(/%2F/g,"/"))),[this.request.method||"GET",P,F,this.canonicalHeaders()+`
`,this.signedHeaders(),ie].join(`
`)},D.prototype.filterHeaders=function(){var P=this.request.headers,R=this.extraHeadersToInclude,B=this.extraHeadersToIgnore;this.filteredHeaders=Object.keys(P).map(function(F){return[F.toLowerCase(),P[F]]}).filter(function(F){return R[F[0]]||A[F[0]]==null&&!B[F[0]]}).sort(function(F,j){return F[0]<j[0]?-1:1})},D.prototype.canonicalHeaders=function(){return this.filteredHeaders||this.filterHeaders(),this.filteredHeaders.map(function(P){return P[0]+":"+P[1].toString().trim().replace(/\s+/g," ")}).join(`
`)},D.prototype.signedHeaders=function(){return this.filteredHeaders||this.filterHeaders(),this.filteredHeaders.map(function(P){return P[0]}).join(";")},D.prototype.credentialString=function(){return[this.getDate(),this.region,this.service,"aws4_request"].join("/")},D.prototype.defaultCredentials=function(){var P=process$1.env;return{accessKeyId:P.AWS_ACCESS_KEY_ID||P.AWS_ACCESS_KEY,secretAccessKey:P.AWS_SECRET_ACCESS_KEY||P.AWS_SECRET_KEY,sessionToken:P.AWS_SESSION_TOKEN}},D.prototype.parsePath=function(){var P=this.request.path||"/";/[^0-9A-Za-z;,/?:@&=+$\-_.!~*'()#%]/.test(P)&&(P=encodeURI(decodeURI(P)));var R=P.indexOf("?"),B=null;R>=0&&(B=o.parse(P.slice(R+1)),P=P.slice(0,R)),this.parsedPath={path:P,query:B}},D.prototype.formatPath=function(){var P=this.parsedPath.path,R=this.parsedPath.query;return R?(R[""]!=null&&delete R[""],P+"?"+C(o.stringify(R))):P},e.RequestSigner=D,e.sign=function(P,R){return new D(P,R).sign()}}(aws4)),aws4}var assert_1,hasRequiredAssert;function requireAssert(){if(hasRequiredAssert)return assert_1;hasRequiredAssert=1;var t=requireAssert$1(),e=requireStreamBrowserify().Stream,n=util$6,o=/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;function u(k){return k.charAt(0).toUpperCase()+k.slice(1)}function l(k,A,D,P,R){throw new t.AssertionError({message:n.format("%s (%s) is required",k,A),actual:R===void 0?typeof P:R(P),expected:A,operator:D||"===",stackStartFunction:l.caller})}function m(k){return Object.prototype.toString.call(k).slice(8,-1)}function y(){}var E={bool:{check:function(k){return typeof k=="boolean"}},func:{check:function(k){return typeof k=="function"}},string:{check:function(k){return typeof k=="string"}},object:{check:function(k){return typeof k=="object"&&k!==null}},number:{check:function(k){return typeof k=="number"&&!isNaN(k)}},finite:{check:function(k){return typeof k=="number"&&!isNaN(k)&&isFinite(k)}},buffer:{check:function(k){return Buffer$C.isBuffer(k)},operator:"Buffer.isBuffer"},array:{check:function(k){return Array.isArray(k)},operator:"Array.isArray"},stream:{check:function(k){return k instanceof e},operator:"instanceof",actual:m},date:{check:function(k){return k instanceof Date},operator:"instanceof",actual:m},regexp:{check:function(k){return k instanceof RegExp},operator:"instanceof",actual:m},uuid:{check:function(k){return typeof k=="string"&&o.test(k)},operator:"isUUID"}};function C(k){var A=Object.keys(E),D;return process$1.env.NODE_NDEBUG?D=y:D=function(P,R){P||l(R,"true",P)},A.forEach(function(P){if(k){D[P]=y;return}var R=E[P];D[P]=function(B,F){R.check(B)||l(F,P,R.operator,B,R.actual)}}),A.forEach(function(P){var R="optional"+u(P);if(k){D[R]=y;return}var B=E[P];D[R]=function(F,j){F!=null&&(B.check(F)||l(j,P,B.operator,F,B.actual))}}),A.forEach(function(P){var R="arrayOf"+u(P);if(k){D[R]=y;return}var B=E[P],F="["+P+"]";D[R]=function(j,N){Array.isArray(j)||l(N,F,B.operator,j,B.actual);var Y;for(Y=0;Y<j.length;Y++)B.check(j[Y])||l(N,F,B.operator,j,B.actual)}}),A.forEach(function(P){var R="optionalArrayOf"+u(P);if(k){D[R]=y;return}var B=E[P],F="["+P+"]";D[R]=function(j,N){if(j!=null){Array.isArray(j)||l(N,F,B.operator,j,B.actual);var Y;for(Y=0;Y<j.length;Y++)B.check(j[Y])||l(N,F,B.operator,j,B.actual)}}}),Object.keys(t).forEach(function(P){if(P==="AssertionError"){D[P]=t[P];return}if(k){D[P]=y;return}D[P]=t[P]}),D._setExports=C,D}return assert_1=C(process$1.env.NODE_NDEBUG),assert_1}var safer_1,hasRequiredSafer;function requireSafer(){if(hasRequiredSafer)return safer_1;hasRequiredSafer=1;var t=require$$0$2,e=t.Buffer,n={},o;for(o in t)t.hasOwnProperty(o)&&(o==="SlowBuffer"||o==="Buffer"||(n[o]=t[o]));var u=n.Buffer={};for(o in e)e.hasOwnProperty(o)&&(o==="allocUnsafe"||o==="allocUnsafeSlow"||(u[o]=e[o]));if(n.Buffer.prototype=e.prototype,(!u.from||u.from===Uint8Array.from)&&(u.from=function(l,m,y){if(typeof l=="number")throw new TypeError('The "value" argument must not be of type number. Received type '+typeof l);if(l&&typeof l.length>"u")throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof l);return e(l,m,y)}),u.alloc||(u.alloc=function(l,m,y){if(typeof l!="number")throw new TypeError('The "size" argument must be of type number. Received type '+typeof l);if(l<0||l>=2*(1<<30))throw new RangeError('The value "'+l+'" is invalid for option "size"');var E=e(l);return!m||m.length===0?E.fill(0):typeof y=="string"?E.fill(m,y):E.fill(m),E}),!n.kStringMaxLength)try{n.kStringMaxLength=process$1.binding("buffer").kStringMaxLength}catch{}return n.constants||(n.constants={MAX_LENGTH:n.kMaxLength},n.kStringMaxLength&&(n.constants.MAX_STRING_LENGTH=n.kStringMaxLength)),safer_1=n,safer_1}var algs,hasRequiredAlgs;function requireAlgs(){if(hasRequiredAlgs)return algs;hasRequiredAlgs=1;var t=requireSafer().Buffer,e={dsa:{parts:["p","q","g","y"],sizePart:"p"},rsa:{parts:["e","n"],sizePart:"n"},ecdsa:{parts:["curve","Q"],sizePart:"Q"},ed25519:{parts:["A"],sizePart:"A"}};e.curve25519=e.ed25519;var n={dsa:{parts:["p","q","g","y","x"]},rsa:{parts:["n","e","d","iqmp","p","q"]},ecdsa:{parts:["curve","Q","d"]},ed25519:{parts:["A","k"]}};n.curve25519=n.ed25519;var o={md5:!0,sha1:!0,sha256:!0,sha384:!0,sha512:!0},u={nistp256:{size:256,pkcs8oid:"1.2.840.10045.3.1.7",p:t.from("00ffffffff 00000001 00000000 0000000000000000 ffffffff ffffffff ffffffff".replace(/ /g,""),"hex"),a:t.from("00FFFFFFFF 00000001 00000000 0000000000000000 FFFFFFFF FFFFFFFF FFFFFFFC".replace(/ /g,""),"hex"),b:t.from("5ac635d8 aa3a93e7 b3ebbd55 769886bc651d06b0 cc53b0f6 3bce3c3e 27d2604b".replace(/ /g,""),"hex"),s:t.from("00c49d3608 86e70493 6a6678e1 139d26b7819f7e90".replace(/ /g,""),"hex"),n:t.from("00ffffffff 00000000 ffffffff ffffffffbce6faad a7179e84 f3b9cac2 fc632551".replace(/ /g,""),"hex"),G:t.from("046b17d1f2 e12c4247 f8bce6e5 63a440f277037d81 2deb33a0 f4a13945 d898c2964fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e162bce3357 6b315ece cbb64068 37bf51f5".replace(/ /g,""),"hex")},nistp384:{size:384,pkcs8oid:"1.3.132.0.34",p:t.from("00ffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff fffffffeffffffff 00000000 00000000 ffffffff".replace(/ /g,""),"hex"),a:t.from("00FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFEFFFFFFFF 00000000 00000000 FFFFFFFC".replace(/ /g,""),"hex"),b:t.from("b3312fa7 e23ee7e4 988e056b e3f82d19181d9c6e fe814112 0314088f 5013875ac656398d 8a2ed19d 2a85c8ed d3ec2aef".replace(/ /g,""),"hex"),s:t.from("00a335926a a319a27a 1d00896a 6773a4827acdac73".replace(/ /g,""),"hex"),n:t.from("00ffffffff ffffffff ffffffff ffffffffffffffff ffffffff c7634d81 f4372ddf581a0db2 48b0a77a ecec196a ccc52973".replace(/ /g,""),"hex"),G:t.from("04aa87ca22 be8b0537 8eb1c71e f320ad746e1d3b62 8ba79b98 59f741e0 82542a385502f25d bf55296c 3a545e38 72760ab73617de4a 96262c6f 5d9e98bf 9292dc29f8f41dbd 289a147c e9da3113 b5f0b8c00a60b1ce 1d7e819d 7a431d7c 90ea0e5f".replace(/ /g,""),"hex")},nistp521:{size:521,pkcs8oid:"1.3.132.0.35",p:t.from("01ffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff ffffffffffff".replace(/ /g,""),"hex"),a:t.from("01FFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFC".replace(/ /g,""),"hex"),b:t.from("51953eb961 8e1c9a1f 929a21a0 b68540eea2da725b 99b315f3 b8b48991 8ef109e156193951 ec7e937b 1652c0bd 3bb1bf073573df88 3d2c34f1 ef451fd4 6b503f00".replace(/ /g,""),"hex"),s:t.from("00d09e8800 291cb853 96cc6717 393284aaa0da64ba".replace(/ /g,""),"hex"),n:t.from("01ffffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff fffffffa51868783 bf2f966b 7fcc0148 f709a5d03bb5c9b8 899c47ae bb6fb71e 91386409".replace(/ /g,""),"hex"),G:t.from("0400c6 858e06b7 0404e9cd 9e3ecb66 2395b4429c648139 053fb521 f828af60 6b4d3dbaa14b5e77 efe75928 fe1dc127 a2ffa8de3348b3c1 856a429b f97e7e31 c2e5bd660118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd998f54449 579b4468 17afbd17 273e662c97ee7299 5ef42640 c550b901 3fad0761353c7086 a272c240 88be9476 9fd16650".replace(/ /g,""),"hex")}};return algs={info:e,privInfo:n,hashAlgs:o,curves:u},algs}var errors$1,hasRequiredErrors$1;function requireErrors$1(){if(hasRequiredErrors$1)return errors$1;hasRequiredErrors$1=1,requireAssert();var t=util$6;function e(y,E){Error.captureStackTrace&&Error.captureStackTrace(this,e),this.name="FingerprintFormatError",this.fingerprint=y,this.format=E,this.message="Fingerprint format is not supported, or is invalid: ",y!==void 0&&(this.message+=" fingerprint = "+y),E!==void 0&&(this.message+=" format = "+E)}t.inherits(e,Error);function n(y){Error.captureStackTrace&&Error.captureStackTrace(this,n),this.name="InvalidAlgorithmError",this.algorithm=y,this.message='Algorithm "'+y+'" is not supported'}t.inherits(n,Error);function o(y,E,C){Error.captureStackTrace&&Error.captureStackTrace(this,o),this.name="KeyParseError",this.format=E,this.keyName=y,this.innerErr=C,this.message="Failed to parse "+y+" as a valid "+E+" format key: "+C.message}t.inherits(o,Error);function u(y,E,C){Error.captureStackTrace&&Error.captureStackTrace(this,u),this.name="SignatureParseError",this.type=y,this.format=E,this.innerErr=C,this.message="Failed to parse the given data as a "+y+" signature in "+E+" format: "+C.message}t.inherits(u,Error);function l(y,E,C){Error.captureStackTrace&&Error.captureStackTrace(this,l),this.name="CertificateParseError",this.format=E,this.certName=y,this.innerErr=C,this.message="Failed to parse "+y+" as a valid "+E+" format certificate: "+C.message}t.inherits(l,Error);function m(y,E){Error.captureStackTrace&&Error.captureStackTrace(this,m),this.name="KeyEncryptedError",this.format=E,this.keyName=y,this.message="The "+E+" format key "+y+" is encrypted (password-protected), and no passphrase was provided in `options`"}return t.inherits(m,Error),errors$1={FingerprintFormatError:e,InvalidAlgorithmError:n,KeyParseError:o,SignatureParseError:u,KeyEncryptedError:m,CertificateParseError:l},errors$1}var ber={exports:{}},errors,hasRequiredErrors;function requireErrors(){return hasRequiredErrors||(hasRequiredErrors=1,errors={newInvalidAsn1Error:function(t){var e=new Error;return e.name="InvalidAsn1Error",e.message=t||"",e}}),errors}var types,hasRequiredTypes;function requireTypes(){return hasRequiredTypes||(hasRequiredTypes=1,types={EOC:0,Boolean:1,Integer:2,BitString:3,OctetString:4,Null:5,OID:6,ObjectDescriptor:7,External:8,Real:9,Enumeration:10,PDV:11,Utf8String:12,RelativeOID:13,Sequence:16,Set:17,NumericString:18,PrintableString:19,T61String:20,VideotexString:21,IA5String:22,UTCTime:23,GeneralizedTime:24,GraphicString:25,VisibleString:26,GeneralString:28,UniversalString:29,CharacterString:30,BMPString:31,Constructor:32,Context:128}),types}var reader,hasRequiredReader;function requireReader(){if(hasRequiredReader)return reader;hasRequiredReader=1;var t=requireAssert$1(),e=requireSafer().Buffer,n=requireTypes(),o=requireErrors(),u=o.newInvalidAsn1Error;function l(m){if(!m||!e.isBuffer(m))throw new TypeError("data must be a node Buffer");this._buf=m,this._size=m.length,this._len=0,this._offset=0}return Object.defineProperty(l.prototype,"length",{enumerable:!0,get:function(){return this._len}}),Object.defineProperty(l.prototype,"offset",{enumerable:!0,get:function(){return this._offset}}),Object.defineProperty(l.prototype,"remain",{get:function(){return this._size-this._offset}}),Object.defineProperty(l.prototype,"buffer",{get:function(){return this._buf.slice(this._offset)}}),l.prototype.readByte=function(m){if(this._size-this._offset<1)return null;var y=this._buf[this._offset]&255;return m||(this._offset+=1),y},l.prototype.peek=function(){return this.readByte(!0)},l.prototype.readLength=function(m){if(m===void 0&&(m=this._offset),m>=this._size)return null;var y=this._buf[m++]&255;if(y===null)return null;if((y&128)===128){if(y&=127,y===0)throw u("Indefinite length not supported");if(y>4)throw u("encoding too long");if(this._size-m<y)return null;this._len=0;for(var E=0;E<y;E++)this._len=(this._len<<8)+(this._buf[m++]&255)}else this._len=y;return m},l.prototype.readSequence=function(m){var y=this.peek();if(y===null)return null;if(m!==void 0&&m!==y)throw u("Expected 0x"+m.toString(16)+": got 0x"+y.toString(16));var E=this.readLength(this._offset+1);return E===null?null:(this._offset=E,y)},l.prototype.readInt=function(){return this._readTag(n.Integer)},l.prototype.readBoolean=function(){return this._readTag(n.Boolean)!==0},l.prototype.readEnumeration=function(){return this._readTag(n.Enumeration)},l.prototype.readString=function(m,y){m||(m=n.OctetString);var E=this.peek();if(E===null)return null;if(E!==m)throw u("Expected 0x"+m.toString(16)+": got 0x"+E.toString(16));var C=this.readLength(this._offset+1);if(C===null||this.length>this._size-C)return null;if(this._offset=C,this.length===0)return y?e.alloc(0):"";var k=this._buf.slice(this._offset,this._offset+this.length);return this._offset+=this.length,y?k:k.toString("utf8")},l.prototype.readOID=function(m){m||(m=n.OID);var y=this.readString(m,!0);if(y===null)return null;for(var E=[],C=0,k=0;k<y.length;k++){var A=y[k]&255;C<<=7,C+=A&127,A&128||(E.push(C),C=0)}return C=E.shift(),E.unshift(C%40),E.unshift(C/40>>0),E.join(".")},l.prototype._readTag=function(m){t.ok(m!==void 0);var y=this.peek();if(y===null)return null;if(y!==m)throw u("Expected 0x"+m.toString(16)+": got 0x"+y.toString(16));var E=this.readLength(this._offset+1);if(E===null)return null;if(this.length>4)throw u("Integer too long: "+this.length);if(this.length>this._size-E)return null;this._offset=E;for(var C=this._buf[this._offset],k=0,A=0;A<this.length;A++)k<<=8,k|=this._buf[this._offset++]&255;return(C&128)===128&&A!==4&&(k-=1<<A*8),k>>0},reader=l,reader}var writer,hasRequiredWriter;function requireWriter(){if(hasRequiredWriter)return writer;hasRequiredWriter=1;var t=requireAssert$1(),e=requireSafer().Buffer,n=requireTypes(),o=requireErrors(),u=o.newInvalidAsn1Error,l={size:1024,growthFactor:8};function m(E,C){t.ok(E),t.equal(typeof E,"object"),t.ok(C),t.equal(typeof C,"object");var k=Object.getOwnPropertyNames(E);return k.forEach(function(A){if(!C[A]){var D=Object.getOwnPropertyDescriptor(E,A);Object.defineProperty(C,A,D)}}),C}function y(E){E=m(l,E||{}),this._buf=e.alloc(E.size||1024),this._size=this._buf.length,this._offset=0,this._options=E,this._seq=[]}return Object.defineProperty(y.prototype,"buffer",{get:function(){if(this._seq.length)throw u(this._seq.length+" unended sequence(s)");return this._buf.slice(0,this._offset)}}),y.prototype.writeByte=function(E){if(typeof E!="number")throw new TypeError("argument must be a Number");this._ensure(1),this._buf[this._offset++]=E},y.prototype.writeInt=function(E,C){if(typeof E!="number")throw new TypeError("argument must be a Number");typeof C!="number"&&(C=n.Integer);for(var k=4;(!(E&4286578688)||(E&4286578688)===-8388608)&&k>1;)k--,E<<=8;if(k>4)throw u("BER ints cannot be > 0xffffffff");for(this._ensure(2+k),this._buf[this._offset++]=C,this._buf[this._offset++]=k;k-- >0;)this._buf[this._offset++]=(E&4278190080)>>>24,E<<=8},y.prototype.writeNull=function(){this.writeByte(n.Null),this.writeByte(0)},y.prototype.writeEnumeration=function(E,C){if(typeof E!="number")throw new TypeError("argument must be a Number");return typeof C!="number"&&(C=n.Enumeration),this.writeInt(E,C)},y.prototype.writeBoolean=function(E,C){if(typeof E!="boolean")throw new TypeError("argument must be a Boolean");typeof C!="number"&&(C=n.Boolean),this._ensure(3),this._buf[this._offset++]=C,this._buf[this._offset++]=1,this._buf[this._offset++]=E?255:0},y.prototype.writeString=function(E,C){if(typeof E!="string")throw new TypeError("argument must be a string (was: "+typeof E+")");typeof C!="number"&&(C=n.OctetString);var k=e.byteLength(E);this.writeByte(C),this.writeLength(k),k&&(this._ensure(k),this._buf.write(E,this._offset),this._offset+=k)},y.prototype.writeBuffer=function(E,C){if(typeof C!="number")throw new TypeError("tag must be a number");if(!e.isBuffer(E))throw new TypeError("argument must be a buffer");this.writeByte(C),this.writeLength(E.length),this._ensure(E.length),E.copy(this._buf,this._offset,0,E.length),this._offset+=E.length},y.prototype.writeStringArray=function(E){if(!E instanceof Array)throw new TypeError("argument must be an Array[String]");var C=this;E.forEach(function(k){C.writeString(k)})},y.prototype.writeOID=function(E,C){if(typeof E!="string")throw new TypeError("argument must be a string");if(typeof C!="number"&&(C=n.OID),!/^([0-9]+\.){3,}[0-9]+$/.test(E))throw new Error("argument is not a valid OID string");function k(R,B){B<128?R.push(B):B<16384?(R.push(B>>>7|128),R.push(B&127)):B<2097152?(R.push(B>>>14|128),R.push((B>>>7|128)&255),R.push(B&127)):B<268435456?(R.push(B>>>21|128),R.push((B>>>14|128)&255),R.push((B>>>7|128)&255),R.push(B&127)):(R.push((B>>>28|128)&255),R.push((B>>>21|128)&255),R.push((B>>>14|128)&255),R.push((B>>>7|128)&255),R.push(B&127))}var A=E.split("."),D=[];D.push(parseInt(A[0],10)*40+parseInt(A[1],10)),A.slice(2).forEach(function(R){k(D,parseInt(R,10))});var P=this;this._ensure(2+D.length),this.writeByte(C),this.writeLength(D.length),D.forEach(function(R){P.writeByte(R)})},y.prototype.writeLength=function(E){if(typeof E!="number")throw new TypeError("argument must be a Number");if(this._ensure(4),E<=127)this._buf[this._offset++]=E;else if(E<=255)this._buf[this._offset++]=129,this._buf[this._offset++]=E;else if(E<=65535)this._buf[this._offset++]=130,this._buf[this._offset++]=E>>8,this._buf[this._offset++]=E;else if(E<=16777215)this._buf[this._offset++]=131,this._buf[this._offset++]=E>>16,this._buf[this._offset++]=E>>8,this._buf[this._offset++]=E;else throw u("Length too long (> 4 bytes)")},y.prototype.startSequence=function(E){typeof E!="number"&&(E=n.Sequence|n.Constructor),this.writeByte(E),this._seq.push(this._offset),this._ensure(3),this._offset+=3},y.prototype.endSequence=function(){var E=this._seq.pop(),C=E+3,k=this._offset-C;if(k<=127)this._shift(C,k,-2),this._buf[E]=k;else if(k<=255)this._shift(C,k,-1),this._buf[E]=129,this._buf[E+1]=k;else if(k<=65535)this._buf[E]=130,this._buf[E+1]=k>>8,this._buf[E+2]=k;else if(k<=16777215)this._shift(C,k,1),this._buf[E]=131,this._buf[E+1]=k>>16,this._buf[E+2]=k>>8,this._buf[E+3]=k;else throw u("Sequence too long")},y.prototype._shift=function(E,C,k){t.ok(E!==void 0),t.ok(C!==void 0),t.ok(k),this._buf.copy(this._buf,E+k,E,E+C),this._offset+=k},y.prototype._ensure=function(E){if(t.ok(E),this._size-this._offset<E){var C=this._size*this._options.growthFactor;C-this._offset<E&&(C+=E);var k=e.alloc(C);this._buf.copy(k,0,0,this._offset),this._buf=k,this._size=C}},writer=y,writer}var hasRequiredBer;function requireBer(){return hasRequiredBer||(hasRequiredBer=1,function(t){var e=requireErrors(),n=requireTypes(),o=requireReader(),u=requireWriter();t.exports={Reader:o,Writer:u};for(var l in n)n.hasOwnProperty(l)&&(t.exports[l]=n[l]);for(var m in e)e.hasOwnProperty(m)&&(t.exports[m]=e[m])}(ber)),ber.exports}var lib$4,hasRequiredLib$4;function requireLib$4(){if(hasRequiredLib$4)return lib$4;hasRequiredLib$4=1;var t=requireBer();return lib$4={Ber:t,BerReader:t.Reader,BerWriter:t.Writer},lib$4}var jsbn={exports:{}},hasRequiredJsbn;function requireJsbn(){return hasRequiredJsbn||(hasRequiredJsbn=1,function(t,e){(function(){var n,o=0xdeadbeefcafe,u=(o&16777215)==15715070;function l(xe,Ee,Ie){xe!=null&&(typeof xe=="number"?this.fromNumber(xe,Ee,Ie):Ee==null&&typeof xe!="string"?this.fromString(xe,256):this.fromString(xe,Ee))}function m(){return new l(null)}function y(xe,Ee,Ie,Xe,xt,Lt){for(;--Lt>=0;){var Ft=Ee*this[xe++]+Ie[Xe]+xt;xt=Math.floor(Ft/67108864),Ie[Xe++]=Ft&67108863}return xt}function E(xe,Ee,Ie,Xe,xt,Lt){for(var Ft=Ee&32767,jt=Ee>>15;--Lt>=0;){var si=this[xe]&32767,yi=this[xe++]>>15,vi=jt*si+yi*Ft;si=Ft*si+((vi&32767)<<15)+Ie[Xe]+(xt&1073741823),xt=(si>>>30)+(vi>>>15)+jt*yi+(xt>>>30),Ie[Xe++]=si&1073741823}return xt}function C(xe,Ee,Ie,Xe,xt,Lt){for(var Ft=Ee&16383,jt=Ee>>14;--Lt>=0;){var si=this[xe]&16383,yi=this[xe++]>>14,vi=jt*si+yi*Ft;si=Ft*si+((vi&16383)<<14)+Ie[Xe]+xt,xt=(si>>28)+(vi>>14)+jt*yi,Ie[Xe++]=si&268435455}return xt}var k=typeof navigator<"u";k&&u&&navigator.appName=="Microsoft Internet Explorer"?(l.prototype.am=E,n=30):k&&u&&navigator.appName!="Netscape"?(l.prototype.am=y,n=26):(l.prototype.am=C,n=28),l.prototype.DB=n,l.prototype.DM=(1<<n)-1,l.prototype.DV=1<<n;var A=52;l.prototype.FV=Math.pow(2,A),l.prototype.F1=A-n,l.prototype.F2=2*n-A;var D="0123456789abcdefghijklmnopqrstuvwxyz",P=new Array,R,B;for(R=48,B=0;B<=9;++B)P[R++]=B;for(R=97,B=10;B<36;++B)P[R++]=B;for(R=65,B=10;B<36;++B)P[R++]=B;function F(xe){return D.charAt(xe)}function j(xe,Ee){var Ie=P[xe.charCodeAt(Ee)];return Ie??-1}function N(xe){for(var Ee=this.t-1;Ee>=0;--Ee)xe[Ee]=this[Ee];xe.t=this.t,xe.s=this.s}function Y(xe){this.t=1,this.s=xe<0?-1:0,xe>0?this[0]=xe:xe<-1?this[0]=xe+this.DV:this.t=0}function J(xe){var Ee=m();return Ee.fromInt(xe),Ee}function ie(xe,Ee){var Ie;if(Ee==16)Ie=4;else if(Ee==8)Ie=3;else if(Ee==256)Ie=8;else if(Ee==2)Ie=1;else if(Ee==32)Ie=5;else if(Ee==4)Ie=2;else{this.fromRadix(xe,Ee);return}this.t=0,this.s=0;for(var Xe=xe.length,xt=!1,Lt=0;--Xe>=0;){var Ft=Ie==8?xe[Xe]&255:j(xe,Xe);if(Ft<0){xe.charAt(Xe)=="-"&&(xt=!0);continue}xt=!1,Lt==0?this[this.t++]=Ft:Lt+Ie>this.DB?(this[this.t-1]|=(Ft&(1<<this.DB-Lt)-1)<<Lt,this[this.t++]=Ft>>this.DB-Lt):this[this.t-1]|=Ft<<Lt,Lt+=Ie,Lt>=this.DB&&(Lt-=this.DB)}Ie==8&&xe[0]&128&&(this.s=-1,Lt>0&&(this[this.t-1]|=(1<<this.DB-Lt)-1<<Lt)),this.clamp(),xt&&l.ZERO.subTo(this,this)}function ue(){for(var xe=this.s&this.DM;this.t>0&&this[this.t-1]==xe;)--this.t}function Q(xe){if(this.s<0)return"-"+this.negate().toString(xe);var Ee;if(xe==16)Ee=4;else if(xe==8)Ee=3;else if(xe==2)Ee=1;else if(xe==32)Ee=5;else if(xe==4)Ee=2;else return this.toRadix(xe);var Ie=(1<<Ee)-1,Xe,xt=!1,Lt="",Ft=this.t,jt=this.DB-Ft*this.DB%Ee;if(Ft-- >0)for(jt<this.DB&&(Xe=this[Ft]>>jt)>0&&(xt=!0,Lt=F(Xe));Ft>=0;)jt<Ee?(Xe=(this[Ft]&(1<<jt)-1)<<Ee-jt,Xe|=this[--Ft]>>(jt+=this.DB-Ee)):(Xe=this[Ft]>>(jt-=Ee)&Ie,jt<=0&&(jt+=this.DB,--Ft)),Xe>0&&(xt=!0),xt&&(Lt+=F(Xe));return xt?Lt:"0"}function ce(){var xe=m();return l.ZERO.subTo(this,xe),xe}function he(){return this.s<0?this.negate():this}function ke(xe){var Ee=this.s-xe.s;if(Ee!=0)return Ee;var Ie=this.t;if(Ee=Ie-xe.t,Ee!=0)return this.s<0?-Ee:Ee;for(;--Ie>=0;)if((Ee=this[Ie]-xe[Ie])!=0)return Ee;return 0}function L(xe){var Ee=1,Ie;return(Ie=xe>>>16)!=0&&(xe=Ie,Ee+=16),(Ie=xe>>8)!=0&&(xe=Ie,Ee+=8),(Ie=xe>>4)!=0&&(xe=Ie,Ee+=4),(Ie=xe>>2)!=0&&(xe=Ie,Ee+=2),(Ie=xe>>1)!=0&&(xe=Ie,Ee+=1),Ee}function d(){return this.t<=0?0:this.DB*(this.t-1)+L(this[this.t-1]^this.s&this.DM)}function v(xe,Ee){var Ie;for(Ie=this.t-1;Ie>=0;--Ie)Ee[Ie+xe]=this[Ie];for(Ie=xe-1;Ie>=0;--Ie)Ee[Ie]=0;Ee.t=this.t+xe,Ee.s=this.s}function w(xe,Ee){for(var Ie=xe;Ie<this.t;++Ie)Ee[Ie-xe]=this[Ie];Ee.t=Math.max(this.t-xe,0),Ee.s=this.s}function c(xe,Ee){var Ie=xe%this.DB,Xe=this.DB-Ie,xt=(1<<Xe)-1,Lt=Math.floor(xe/this.DB),Ft=this.s<<Ie&this.DM,jt;for(jt=this.t-1;jt>=0;--jt)Ee[jt+Lt+1]=this[jt]>>Xe|Ft,Ft=(this[jt]&xt)<<Ie;for(jt=Lt-1;jt>=0;--jt)Ee[jt]=0;Ee[Lt]=Ft,Ee.t=this.t+Lt+1,Ee.s=this.s,Ee.clamp()}function p(xe,Ee){Ee.s=this.s;var Ie=Math.floor(xe/this.DB);if(Ie>=this.t){Ee.t=0;return}var Xe=xe%this.DB,xt=this.DB-Xe,Lt=(1<<Xe)-1;Ee[0]=this[Ie]>>Xe;for(var Ft=Ie+1;Ft<this.t;++Ft)Ee[Ft-Ie-1]|=(this[Ft]&Lt)<<xt,Ee[Ft-Ie]=this[Ft]>>Xe;Xe>0&&(Ee[this.t-Ie-1]|=(this.s&Lt)<<xt),Ee.t=this.t-Ie,Ee.clamp()}function x(xe,Ee){for(var Ie=0,Xe=0,xt=Math.min(xe.t,this.t);Ie<xt;)Xe+=this[Ie]-xe[Ie],Ee[Ie++]=Xe&this.DM,Xe>>=this.DB;if(xe.t<this.t){for(Xe-=xe.s;Ie<this.t;)Xe+=this[Ie],Ee[Ie++]=Xe&this.DM,Xe>>=this.DB;Xe+=this.s}else{for(Xe+=this.s;Ie<xe.t;)Xe-=xe[Ie],Ee[Ie++]=Xe&this.DM,Xe>>=this.DB;Xe-=xe.s}Ee.s=Xe<0?-1:0,Xe<-1?Ee[Ie++]=this.DV+Xe:Xe>0&&(Ee[Ie++]=Xe),Ee.t=Ie,Ee.clamp()}function S(xe,Ee){var Ie=this.abs(),Xe=xe.abs(),xt=Ie.t;for(Ee.t=xt+Xe.t;--xt>=0;)Ee[xt]=0;for(xt=0;xt<Xe.t;++xt)Ee[xt+Ie.t]=Ie.am(0,Xe[xt],Ee,xt,0,Ie.t);Ee.s=0,Ee.clamp(),this.s!=xe.s&&l.ZERO.subTo(Ee,Ee)}function b(xe){for(var Ee=this.abs(),Ie=xe.t=2*Ee.t;--Ie>=0;)xe[Ie]=0;for(Ie=0;Ie<Ee.t-1;++Ie){var Xe=Ee.am(Ie,Ee[Ie],xe,2*Ie,0,1);(xe[Ie+Ee.t]+=Ee.am(Ie+1,2*Ee[Ie],xe,2*Ie+1,Xe,Ee.t-Ie-1))>=Ee.DV&&(xe[Ie+Ee.t]-=Ee.DV,xe[Ie+Ee.t+1]=1)}xe.t>0&&(xe[xe.t-1]+=Ee.am(Ie,Ee[Ie],xe,2*Ie,0,1)),xe.s=0,xe.clamp()}function h(xe,Ee,Ie){var Xe=xe.abs();if(!(Xe.t<=0)){var xt=this.abs();if(xt.t<Xe.t){Ee!=null&&Ee.fromInt(0),Ie!=null&&this.copyTo(Ie);return}Ie==null&&(Ie=m());var Lt=m(),Ft=this.s,jt=xe.s,si=this.DB-L(Xe[Xe.t-1]);si>0?(Xe.lShiftTo(si,Lt),xt.lShiftTo(si,Ie)):(Xe.copyTo(Lt),xt.copyTo(Ie));var yi=Lt.t,vi=Lt[yi-1];if(vi!=0){var li=vi*(1<<this.F1)+(yi>1?Lt[yi-2]>>this.F2:0),Vi=this.FV/li,Ei=(1<<this.F1)/li,$i=1<<this.F2,xi=Ie.t,ir=xi-yi,Ji=Ee??m();for(Lt.dlShiftTo(ir,Ji),Ie.compareTo(Ji)>=0&&(Ie[Ie.t++]=1,Ie.subTo(Ji,Ie)),l.ONE.dlShiftTo(yi,Ji),Ji.subTo(Lt,Lt);Lt.t<yi;)Lt[Lt.t++]=0;for(;--ir>=0;){var ur=Ie[--xi]==vi?this.DM:Math.floor(Ie[xi]*Vi+(Ie[xi-1]+$i)*Ei);if((Ie[xi]+=Lt.am(0,ur,Ie,ir,0,yi))<ur)for(Lt.dlShiftTo(ir,Ji),Ie.subTo(Ji,Ie);Ie[xi]<--ur;)Ie.subTo(Ji,Ie)}Ee!=null&&(Ie.drShiftTo(yi,Ee),Ft!=jt&&l.ZERO.subTo(Ee,Ee)),Ie.t=yi,Ie.clamp(),si>0&&Ie.rShiftTo(si,Ie),Ft<0&&l.ZERO.subTo(Ie,Ie)}}}function T(xe){var Ee=m();return this.abs().divRemTo(xe,null,Ee),this.s<0&&Ee.compareTo(l.ZERO)>0&&xe.subTo(Ee,Ee),Ee}function M(xe){this.m=xe}function O(xe){return xe.s<0||xe.compareTo(this.m)>=0?xe.mod(this.m):xe}function V(xe){return xe}function ee(xe){xe.divRemTo(this.m,null,xe)}function Z(xe,Ee,Ie){xe.multiplyTo(Ee,Ie),this.reduce(Ie)}function U(xe,Ee){xe.squareTo(Ee),this.reduce(Ee)}M.prototype.convert=O,M.prototype.revert=V,M.prototype.reduce=ee,M.prototype.mulTo=Z,M.prototype.sqrTo=U;function z(){if(this.t<1)return 0;var xe=this[0];if(!(xe&1))return 0;var Ee=xe&3;return Ee=Ee*(2-(xe&15)*Ee)&15,Ee=Ee*(2-(xe&255)*Ee)&255,Ee=Ee*(2-((xe&65535)*Ee&65535))&65535,Ee=Ee*(2-xe*Ee%this.DV)%this.DV,Ee>0?this.DV-Ee:-Ee}function ne(xe){this.m=xe,this.mp=xe.invDigit(),this.mpl=this.mp&32767,this.mph=this.mp>>15,this.um=(1<<xe.DB-15)-1,this.mt2=2*xe.t}function fe(xe){var Ee=m();return xe.abs().dlShiftTo(this.m.t,Ee),Ee.divRemTo(this.m,null,Ee),xe.s<0&&Ee.compareTo(l.ZERO)>0&&this.m.subTo(Ee,Ee),Ee}function me(xe){var Ee=m();return xe.copyTo(Ee),this.reduce(Ee),Ee}function de(xe){for(;xe.t<=this.mt2;)xe[xe.t++]=0;for(var Ee=0;Ee<this.m.t;++Ee){var Ie=xe[Ee]&32767,Xe=Ie*this.mpl+((Ie*this.mph+(xe[Ee]>>15)*this.mpl&this.um)<<15)&xe.DM;for(Ie=Ee+this.m.t,xe[Ie]+=this.m.am(0,Xe,xe,Ee,0,this.m.t);xe[Ie]>=xe.DV;)xe[Ie]-=xe.DV,xe[++Ie]++}xe.clamp(),xe.drShiftTo(this.m.t,xe),xe.compareTo(this.m)>=0&&xe.subTo(this.m,xe)}function je(xe,Ee){xe.squareTo(Ee),this.reduce(Ee)}function lt(xe,Ee,Ie){xe.multiplyTo(Ee,Ie),this.reduce(Ie)}ne.prototype.convert=fe,ne.prototype.revert=me,ne.prototype.reduce=de,ne.prototype.mulTo=lt,ne.prototype.sqrTo=je;function it(){return(this.t>0?this[0]&1:this.s)==0}function ot(xe,Ee){if(xe>4294967295||xe<1)return l.ONE;var Ie=m(),Xe=m(),xt=Ee.convert(this),Lt=L(xe)-1;for(xt.copyTo(Ie);--Lt>=0;)if(Ee.sqrTo(Ie,Xe),(xe&1<<Lt)>0)Ee.mulTo(Xe,xt,Ie);else{var Ft=Ie;Ie=Xe,Xe=Ft}return Ee.revert(Ie)}function Ct(xe,Ee){var Ie;return xe<256||Ee.isEven()?Ie=new M(Ee):Ie=new ne(Ee),this.exp(xe,Ie)}l.prototype.copyTo=N,l.prototype.fromInt=Y,l.prototype.fromString=ie,l.prototype.clamp=ue,l.prototype.dlShiftTo=v,l.prototype.drShiftTo=w,l.prototype.lShiftTo=c,l.prototype.rShiftTo=p,l.prototype.subTo=x,l.prototype.multiplyTo=S,l.prototype.squareTo=b,l.prototype.divRemTo=h,l.prototype.invDigit=z,l.prototype.isEven=it,l.prototype.exp=ot,l.prototype.toString=Q,l.prototype.negate=ce,l.prototype.abs=he,l.prototype.compareTo=ke,l.prototype.bitLength=d,l.prototype.mod=T,l.prototype.modPowInt=Ct,l.ZERO=J(0),l.ONE=J(1);function nt(){var xe=m();return this.copyTo(xe),xe}function Je(){if(this.s<0){if(this.t==1)return this[0]-this.DV;if(this.t==0)return-1}else{if(this.t==1)return this[0];if(this.t==0)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]}function tt(){return this.t==0?this.s:this[0]<<24>>24}function rt(){return this.t==0?this.s:this[0]<<16>>16}function ht(xe){return Math.floor(Math.LN2*this.DB/Math.log(xe))}function Ot(){return this.s<0?-1:this.t<=0||this.t==1&&this[0]<=0?0:1}function Ve(xe){if(xe==null&&(xe=10),this.signum()==0||xe<2||xe>36)return"0";var Ee=this.chunkSize(xe),Ie=Math.pow(xe,Ee),Xe=J(Ie),xt=m(),Lt=m(),Ft="";for(this.divRemTo(Xe,xt,Lt);xt.signum()>0;)Ft=(Ie+Lt.intValue()).toString(xe).substr(1)+Ft,xt.divRemTo(Xe,xt,Lt);return Lt.intValue().toString(xe)+Ft}function We(xe,Ee){this.fromInt(0),Ee==null&&(Ee=10);for(var Ie=this.chunkSize(Ee),Xe=Math.pow(Ee,Ie),xt=!1,Lt=0,Ft=0,jt=0;jt<xe.length;++jt){var si=j(xe,jt);if(si<0){xe.charAt(jt)=="-"&&this.signum()==0&&(xt=!0);continue}Ft=Ee*Ft+si,++Lt>=Ie&&(this.dMultiply(Xe),this.dAddOffset(Ft,0),Lt=0,Ft=0)}Lt>0&&(this.dMultiply(Math.pow(Ee,Lt)),this.dAddOffset(Ft,0)),xt&&l.ZERO.subTo(this,this)}function Gt(xe,Ee,Ie){if(typeof Ee=="number")if(xe<2)this.fromInt(1);else for(this.fromNumber(xe,Ie),this.testBit(xe-1)||this.bitwiseTo(l.ONE.shiftLeft(xe-1),Ue,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(Ee);)this.dAddOffset(2,0),this.bitLength()>xe&&this.subTo(l.ONE.shiftLeft(xe-1),this);else{var Xe=new Array,xt=xe&7;Xe.length=(xe>>3)+1,Ee.nextBytes(Xe),xt>0?Xe[0]&=(1<<xt)-1:Xe[0]=0,this.fromString(Xe,256)}}function wt(){var xe=this.t,Ee=new Array;Ee[0]=this.s;var Ie=this.DB-xe*this.DB%8,Xe,xt=0;if(xe-- >0)for(Ie<this.DB&&(Xe=this[xe]>>Ie)!=(this.s&this.DM)>>Ie&&(Ee[xt++]=Xe|this.s<<this.DB-Ie);xe>=0;)Ie<8?(Xe=(this[xe]&(1<<Ie)-1)<<8-Ie,Xe|=this[--xe]>>(Ie+=this.DB-8)):(Xe=this[xe]>>(Ie-=8)&255,Ie<=0&&(Ie+=this.DB,--xe)),Xe&128&&(Xe|=-256),xt==0&&(this.s&128)!=(Xe&128)&&++xt,(xt>0||Xe!=this.s)&&(Ee[xt++]=Xe);return Ee}function Et(xe){return this.compareTo(xe)==0}function Yt(xe){return this.compareTo(xe)<0?this:xe}function Ce(xe){return this.compareTo(xe)>0?this:xe}function te(xe,Ee,Ie){var Xe,xt,Lt=Math.min(xe.t,this.t);for(Xe=0;Xe<Lt;++Xe)Ie[Xe]=Ee(this[Xe],xe[Xe]);if(xe.t<this.t){for(xt=xe.s&this.DM,Xe=Lt;Xe<this.t;++Xe)Ie[Xe]=Ee(this[Xe],xt);Ie.t=this.t}else{for(xt=this.s&this.DM,Xe=Lt;Xe<xe.t;++Xe)Ie[Xe]=Ee(xt,xe[Xe]);Ie.t=xe.t}Ie.s=Ee(this.s,xe.s),Ie.clamp()}function ye(xe,Ee){return xe&Ee}function Le(xe){var Ee=m();return this.bitwiseTo(xe,ye,Ee),Ee}function Ue(xe,Ee){return xe|Ee}function Qe(xe){var Ee=m();return this.bitwiseTo(xe,Ue,Ee),Ee}function Ke(xe,Ee){return xe^Ee}function De(xe){var Ee=m();return this.bitwiseTo(xe,Ke,Ee),Ee}function Vt(xe,Ee){return xe&~Ee}function At(xe){var Ee=m();return this.bitwiseTo(xe,Vt,Ee),Ee}function ve(){for(var xe=m(),Ee=0;Ee<this.t;++Ee)xe[Ee]=this.DM&~this[Ee];return xe.t=this.t,xe.s=~this.s,xe}function Pt(xe){var Ee=m();return xe<0?this.rShiftTo(-xe,Ee):this.lShiftTo(xe,Ee),Ee}function pt(xe){var Ee=m();return xe<0?this.lShiftTo(-xe,Ee):this.rShiftTo(xe,Ee),Ee}function Ne(xe){if(xe==0)return-1;var Ee=0;return xe&65535||(xe>>=16,Ee+=16),xe&255||(xe>>=8,Ee+=8),xe&15||(xe>>=4,Ee+=4),xe&3||(xe>>=2,Ee+=2),xe&1||++Ee,Ee}function vt(){for(var xe=0;xe<this.t;++xe)if(this[xe]!=0)return xe*this.DB+Ne(this[xe]);return this.s<0?this.t*this.DB:-1}function ut(xe){for(var Ee=0;xe!=0;)xe&=xe-1,++Ee;return Ee}function $t(){for(var xe=0,Ee=this.s&this.DM,Ie=0;Ie<this.t;++Ie)xe+=ut(this[Ie]^Ee);return xe}function fi(xe){var Ee=Math.floor(xe/this.DB);return Ee>=this.t?this.s!=0:(this[Ee]&1<<xe%this.DB)!=0}function kt(xe,Ee){var Ie=l.ONE.shiftLeft(xe);return this.bitwiseTo(Ie,Ee,Ie),Ie}function Wt(xe){return this.changeBit(xe,Ue)}function Zi(xe){return this.changeBit(xe,Vt)}function Ut(xe){return this.changeBit(xe,Ke)}function Xt(xe,Ee){for(var Ie=0,Xe=0,xt=Math.min(xe.t,this.t);Ie<xt;)Xe+=this[Ie]+xe[Ie],Ee[Ie++]=Xe&this.DM,Xe>>=this.DB;if(xe.t<this.t){for(Xe+=xe.s;Ie<this.t;)Xe+=this[Ie],Ee[Ie++]=Xe&this.DM,Xe>>=this.DB;Xe+=this.s}else{for(Xe+=this.s;Ie<xe.t;)Xe+=xe[Ie],Ee[Ie++]=Xe&this.DM,Xe>>=this.DB;Xe+=xe.s}Ee.s=Xe<0?-1:0,Xe>0?Ee[Ie++]=Xe:Xe<-1&&(Ee[Ie++]=this.DV+Xe),Ee.t=Ie,Ee.clamp()}function Be(xe){var Ee=m();return this.addTo(xe,Ee),Ee}function be(xe){var Ee=m();return this.subTo(xe,Ee),Ee}function ge(xe){var Ee=m();return this.multiplyTo(xe,Ee),Ee}function oe(){var xe=m();return this.squareTo(xe),xe}function Ae(xe){var Ee=m();return this.divRemTo(xe,Ee,null),Ee}function qe(xe){var Ee=m();return this.divRemTo(xe,null,Ee),Ee}function bt(xe){var Ee=m(),Ie=m();return this.divRemTo(xe,Ee,Ie),new Array(Ee,Ie)}function at(xe){this[this.t]=this.am(0,xe-1,this,0,0,this.t),++this.t,this.clamp()}function gt(xe,Ee){if(xe!=0){for(;this.t<=Ee;)this[this.t++]=0;for(this[Ee]+=xe;this[Ee]>=this.DV;)this[Ee]-=this.DV,++Ee>=this.t&&(this[this.t++]=0),++this[Ee]}}function ei(){}function ii(xe){return xe}function Bi(xe,Ee,Ie){xe.multiplyTo(Ee,Ie)}function hi(xe,Ee){xe.squareTo(Ee)}ei.prototype.convert=ii,ei.prototype.revert=ii,ei.prototype.mulTo=Bi,ei.prototype.sqrTo=hi;function Di(xe){return this.exp(xe,new ei)}function ni(xe,Ee,Ie){var Xe=Math.min(this.t+xe.t,Ee);for(Ie.s=0,Ie.t=Xe;Xe>0;)Ie[--Xe]=0;var xt;for(xt=Ie.t-this.t;Xe<xt;++Xe)Ie[Xe+this.t]=this.am(0,xe[Xe],Ie,Xe,0,this.t);for(xt=Math.min(xe.t,Ee);Xe<xt;++Xe)this.am(0,xe[Xe],Ie,Xe,0,Ee-Xe);Ie.clamp()}function pi(xe,Ee,Ie){--Ee;var Xe=Ie.t=this.t+xe.t-Ee;for(Ie.s=0;--Xe>=0;)Ie[Xe]=0;for(Xe=Math.max(Ee-this.t,0);Xe<xe.t;++Xe)Ie[this.t+Xe-Ee]=this.am(Ee-Xe,xe[Xe],Ie,0,0,this.t+Xe-Ee);Ie.clamp(),Ie.drShiftTo(1,Ie)}function Ii(xe){this.r2=m(),this.q3=m(),l.ONE.dlShiftTo(2*xe.t,this.r2),this.mu=this.r2.divide(xe),this.m=xe}function Ci(xe){if(xe.s<0||xe.t>2*this.m.t)return xe.mod(this.m);if(xe.compareTo(this.m)<0)return xe;var Ee=m();return xe.copyTo(Ee),this.reduce(Ee),Ee}function zi(xe){return xe}function qi(xe){for(xe.drShiftTo(this.m.t-1,this.r2),xe.t>this.m.t+1&&(xe.t=this.m.t+1,xe.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);xe.compareTo(this.r2)<0;)xe.dAddOffset(1,this.m.t+1);for(xe.subTo(this.r2,xe);xe.compareTo(this.m)>=0;)xe.subTo(this.m,xe)}function Ai(xe,Ee){xe.squareTo(Ee),this.reduce(Ee)}function Oi(xe,Ee,Ie){xe.multiplyTo(Ee,Ie),this.reduce(Ie)}Ii.prototype.convert=Ci,Ii.prototype.revert=zi,Ii.prototype.reduce=qi,Ii.prototype.mulTo=Oi,Ii.prototype.sqrTo=Ai;function ki(xe,Ee){var Ie=xe.bitLength(),Xe,xt=J(1),Lt;if(Ie<=0)return xt;Ie<18?Xe=1:Ie<48?Xe=3:Ie<144?Xe=4:Ie<768?Xe=5:Xe=6,Ie<8?Lt=new M(Ee):Ee.isEven()?Lt=new Ii(Ee):Lt=new ne(Ee);var Ft=new Array,jt=3,si=Xe-1,yi=(1<<Xe)-1;if(Ft[1]=Lt.convert(this),Xe>1){var vi=m();for(Lt.sqrTo(Ft[1],vi);jt<=yi;)Ft[jt]=m(),Lt.mulTo(vi,Ft[jt-2],Ft[jt]),jt+=2}var li=xe.t-1,Vi,Ei=!0,$i=m(),xi;for(Ie=L(xe[li])-1;li>=0;){for(Ie>=si?Vi=xe[li]>>Ie-si&yi:(Vi=(xe[li]&(1<<Ie+1)-1)<<si-Ie,li>0&&(Vi|=xe[li-1]>>this.DB+Ie-si)),jt=Xe;!(Vi&1);)Vi>>=1,--jt;if((Ie-=jt)<0&&(Ie+=this.DB,--li),Ei)Ft[Vi].copyTo(xt),Ei=!1;else{for(;jt>1;)Lt.sqrTo(xt,$i),Lt.sqrTo($i,xt),jt-=2;jt>0?Lt.sqrTo(xt,$i):(xi=xt,xt=$i,$i=xi),Lt.mulTo($i,Ft[Vi],xt)}for(;li>=0&&!(xe[li]&1<<Ie);)Lt.sqrTo(xt,$i),xi=xt,xt=$i,$i=xi,--Ie<0&&(Ie=this.DB-1,--li)}return Lt.revert(xt)}function Ti(xe){var Ee=this.s<0?this.negate():this.clone(),Ie=xe.s<0?xe.negate():xe.clone();if(Ee.compareTo(Ie)<0){var Xe=Ee;Ee=Ie,Ie=Xe}var xt=Ee.getLowestSetBit(),Lt=Ie.getLowestSetBit();if(Lt<0)return Ee;for(xt<Lt&&(Lt=xt),Lt>0&&(Ee.rShiftTo(Lt,Ee),Ie.rShiftTo(Lt,Ie));Ee.signum()>0;)(xt=Ee.getLowestSetBit())>0&&Ee.rShiftTo(xt,Ee),(xt=Ie.getLowestSetBit())>0&&Ie.rShiftTo(xt,Ie),Ee.compareTo(Ie)>=0?(Ee.subTo(Ie,Ee),Ee.rShiftTo(1,Ee)):(Ie.subTo(Ee,Ie),Ie.rShiftTo(1,Ie));return Lt>0&&Ie.lShiftTo(Lt,Ie),Ie}function wi(xe){if(xe<=0)return 0;var Ee=this.DV%xe,Ie=this.s<0?xe-1:0;if(this.t>0)if(Ee==0)Ie=this[0]%xe;else for(var Xe=this.t-1;Xe>=0;--Xe)Ie=(Ee*Ie+this[Xe])%xe;return Ie}function oi(xe){var Ee=xe.isEven();if(this.isEven()&&Ee||xe.signum()==0)return l.ZERO;for(var Ie=xe.clone(),Xe=this.clone(),xt=J(1),Lt=J(0),Ft=J(0),jt=J(1);Ie.signum()!=0;){for(;Ie.isEven();)Ie.rShiftTo(1,Ie),Ee?((!xt.isEven()||!Lt.isEven())&&(xt.addTo(this,xt),Lt.subTo(xe,Lt)),xt.rShiftTo(1,xt)):Lt.isEven()||Lt.subTo(xe,Lt),Lt.rShiftTo(1,Lt);for(;Xe.isEven();)Xe.rShiftTo(1,Xe),Ee?((!Ft.isEven()||!jt.isEven())&&(Ft.addTo(this,Ft),jt.subTo(xe,jt)),Ft.rShiftTo(1,Ft)):jt.isEven()||jt.subTo(xe,jt),jt.rShiftTo(1,jt);Ie.compareTo(Xe)>=0?(Ie.subTo(Xe,Ie),Ee&&xt.subTo(Ft,xt),Lt.subTo(jt,Lt)):(Xe.subTo(Ie,Xe),Ee&&Ft.subTo(xt,Ft),jt.subTo(Lt,jt))}if(Xe.compareTo(l.ONE)!=0)return l.ZERO;if(jt.compareTo(xe)>=0)return jt.subtract(xe);if(jt.signum()<0)jt.addTo(xe,jt);else return jt;return jt.signum()<0?jt.add(xe):jt}var zt=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],Qt=(1<<26)/zt[zt.length-1];function Si(xe){var Ee,Ie=this.abs();if(Ie.t==1&&Ie[0]<=zt[zt.length-1]){for(Ee=0;Ee<zt.length;++Ee)if(Ie[0]==zt[Ee])return!0;return!1}if(Ie.isEven())return!1;for(Ee=1;Ee<zt.length;){for(var Xe=zt[Ee],xt=Ee+1;xt<zt.length&&Xe<Qt;)Xe*=zt[xt++];for(Xe=Ie.modInt(Xe);Ee<xt;)if(Xe%zt[Ee++]==0)return!1}return Ie.millerRabin(xe)}function mi(xe){var Ee=this.subtract(l.ONE),Ie=Ee.getLowestSetBit();if(Ie<=0)return!1;var Xe=Ee.shiftRight(Ie);xe=xe+1>>1,xe>zt.length&&(xe=zt.length);for(var xt=m(),Lt=0;Lt<xe;++Lt){xt.fromInt(zt[Math.floor(Math.random()*zt.length)]);var Ft=xt.modPow(Xe,this);if(Ft.compareTo(l.ONE)!=0&&Ft.compareTo(Ee)!=0){for(var jt=1;jt++<Ie&&Ft.compareTo(Ee)!=0;)if(Ft=Ft.modPowInt(2,this),Ft.compareTo(l.ONE)==0)return!1;if(Ft.compareTo(Ee)!=0)return!1}}return!0}l.prototype.chunkSize=ht,l.prototype.toRadix=Ve,l.prototype.fromRadix=We,l.prototype.fromNumber=Gt,l.prototype.bitwiseTo=te,l.prototype.changeBit=kt,l.prototype.addTo=Xt,l.prototype.dMultiply=at,l.prototype.dAddOffset=gt,l.prototype.multiplyLowerTo=ni,l.prototype.multiplyUpperTo=pi,l.prototype.modInt=wi,l.prototype.millerRabin=mi,l.prototype.clone=nt,l.prototype.intValue=Je,l.prototype.byteValue=tt,l.prototype.shortValue=rt,l.prototype.signum=Ot,l.prototype.toByteArray=wt,l.prototype.equals=Et,l.prototype.min=Yt,l.prototype.max=Ce,l.prototype.and=Le,l.prototype.or=Qe,l.prototype.xor=De,l.prototype.andNot=At,l.prototype.not=ve,l.prototype.shiftLeft=Pt,l.prototype.shiftRight=pt,l.prototype.getLowestSetBit=vt,l.prototype.bitCount=$t,l.prototype.testBit=fi,l.prototype.setBit=Wt,l.prototype.clearBit=Zi,l.prototype.flipBit=Ut,l.prototype.add=Be,l.prototype.subtract=be,l.prototype.multiply=ge,l.prototype.divide=Ae,l.prototype.remainder=qe,l.prototype.divideAndRemainder=bt,l.prototype.modPow=ki,l.prototype.modInverse=oi,l.prototype.pow=Di,l.prototype.gcd=Ti,l.prototype.isProbablePrime=Si,l.prototype.square=oe,l.prototype.Barrett=Ii;var ai,gi,Hi;function or(xe){gi[Hi++]^=xe&255,gi[Hi++]^=xe>>8&255,gi[Hi++]^=xe>>16&255,gi[Hi++]^=xe>>24&255,Hi>=st&&(Hi-=st)}function nr(){or(new Date().getTime())}if(gi==null){gi=new Array,Hi=0;var Gi;if(typeof window<"u"&&window.crypto){if(window.crypto.getRandomValues){var Mt=new Uint8Array(32);for(window.crypto.getRandomValues(Mt),Gi=0;Gi<32;++Gi)gi[Hi++]=Mt[Gi]}else if(navigator.appName=="Netscape"&&navigator.appVersion<"5"){var er=window.crypto.random(32);for(Gi=0;Gi<er.length;++Gi)gi[Hi++]=er.charCodeAt(Gi)&255}}for(;Hi<st;)Gi=Math.floor(65536*Math.random()),gi[Hi++]=Gi>>>8,gi[Hi++]=Gi&255;Hi=0,nr()}function tr(){if(ai==null){for(nr(),ai=Ge(),ai.init(gi),Hi=0;Hi<gi.length;++Hi)gi[Hi]=0;Hi=0}return ai.next()}function br(xe){var Ee;for(Ee=0;Ee<xe.length;++Ee)xe[Ee]=tr()}function le(){}le.prototype.nextBytes=br;function we(){this.i=0,this.j=0,this.S=new Array}function $e(xe){var Ee,Ie,Xe;for(Ee=0;Ee<256;++Ee)this.S[Ee]=Ee;for(Ie=0,Ee=0;Ee<256;++Ee)Ie=Ie+this.S[Ee]+xe[Ee%xe.length]&255,Xe=this.S[Ee],this.S[Ee]=this.S[Ie],this.S[Ie]=Xe;this.i=0,this.j=0}function Oe(){var xe;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,xe=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=xe,this.S[xe+this.S[this.i]&255]}we.prototype.init=$e,we.prototype.next=Oe;function Ge(){return new we}var st=256;l.SecureRandom=le,l.BigInteger=l,t.exports=l}).call(commonjsGlobal$1)}(jsbn)),jsbn.exports}var ec,hasRequiredEc;function requireEc(){if(hasRequiredEc)return ec;hasRequiredEc=1;var t=requireJsbn().BigInteger,e=t.prototype.Barrett;function n(c,p){this.x=p,this.q=c}function o(c){return c==this?!0:this.q.equals(c.q)&&this.x.equals(c.x)}function u(){return this.x}function l(){return new n(this.q,this.x.negate().mod(this.q))}function m(c){return new n(this.q,this.x.add(c.toBigInteger()).mod(this.q))}function y(c){return new n(this.q,this.x.subtract(c.toBigInteger()).mod(this.q))}function E(c){return new n(this.q,this.x.multiply(c.toBigInteger()).mod(this.q))}function C(){return new n(this.q,this.x.square().mod(this.q))}function k(c){return new n(this.q,this.x.multiply(c.toBigInteger().modInverse(this.q)).mod(this.q))}n.prototype.equals=o,n.prototype.toBigInteger=u,n.prototype.negate=l,n.prototype.add=m,n.prototype.subtract=y,n.prototype.multiply=E,n.prototype.square=C,n.prototype.divide=k;function A(c,p,x,S){this.curve=c,this.x=p,this.y=x,S==null?this.z=t.ONE:this.z=S,this.zinv=null}function D(){this.zinv==null&&(this.zinv=this.z.modInverse(this.curve.q));var c=this.x.toBigInteger().multiply(this.zinv);return this.curve.reduce(c),this.curve.fromBigInteger(c)}function P(){this.zinv==null&&(this.zinv=this.z.modInverse(this.curve.q));var c=this.y.toBigInteger().multiply(this.zinv);return this.curve.reduce(c),this.curve.fromBigInteger(c)}function R(c){if(c==this)return!0;if(this.isInfinity())return c.isInfinity();if(c.isInfinity())return this.isInfinity();var p,x;return p=c.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(c.z)).mod(this.curve.q),p.equals(t.ZERO)?(x=c.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(c.z)).mod(this.curve.q),x.equals(t.ZERO)):!1}function B(){return this.x==null&&this.y==null?!0:this.z.equals(t.ZERO)&&!this.y.toBigInteger().equals(t.ZERO)}function F(){return new A(this.curve,this.x,this.y.negate(),this.z)}function j(c){if(this.isInfinity())return c;if(c.isInfinity())return this;var p=c.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(c.z)).mod(this.curve.q),x=c.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(c.z)).mod(this.curve.q);if(t.ZERO.equals(x))return t.ZERO.equals(p)?this.twice():this.curve.getInfinity();var S=new t("3"),b=this.x.toBigInteger(),h=this.y.toBigInteger();c.x.toBigInteger(),c.y.toBigInteger();var T=x.square(),M=T.multiply(x),O=b.multiply(T),V=p.square().multiply(this.z),ee=V.subtract(O.shiftLeft(1)).multiply(c.z).subtract(M).multiply(x).mod(this.curve.q),Z=O.multiply(S).multiply(p).subtract(h.multiply(M)).subtract(V.multiply(p)).multiply(c.z).add(p.multiply(M)).mod(this.curve.q),U=M.multiply(this.z).multiply(c.z).mod(this.curve.q);return new A(this.curve,this.curve.fromBigInteger(ee),this.curve.fromBigInteger(Z),U)}function N(){if(this.isInfinity())return this;if(this.y.toBigInteger().signum()==0)return this.curve.getInfinity();var c=new t("3"),p=this.x.toBigInteger(),x=this.y.toBigInteger(),S=x.multiply(this.z),b=S.multiply(x).mod(this.curve.q),h=this.curve.a.toBigInteger(),T=p.square().multiply(c);t.ZERO.equals(h)||(T=T.add(this.z.square().multiply(h))),T=T.mod(this.curve.q);var M=T.square().subtract(p.shiftLeft(3).multiply(b)).shiftLeft(1).multiply(S).mod(this.curve.q),O=T.multiply(c).multiply(p).subtract(b.shiftLeft(1)).shiftLeft(2).multiply(b).subtract(T.square().multiply(T)).mod(this.curve.q),V=S.square().multiply(S).shiftLeft(3).mod(this.curve.q);return new A(this.curve,this.curve.fromBigInteger(M),this.curve.fromBigInteger(O),V)}function Y(c){if(this.isInfinity())return this;if(c.signum()==0)return this.curve.getInfinity();var p=c,x=p.multiply(new t("3")),S=this.negate(),b=this,h;for(h=x.bitLength()-2;h>0;--h){b=b.twice();var T=x.testBit(h),M=p.testBit(h);T!=M&&(b=b.add(T?this:S))}return b}function J(c,p,x){var S;c.bitLength()>x.bitLength()?S=c.bitLength()-1:S=x.bitLength()-1;for(var b=this.curve.getInfinity(),h=this.add(p);S>=0;)b=b.twice(),c.testBit(S)?x.testBit(S)?b=b.add(h):b=b.add(this):x.testBit(S)&&(b=b.add(p)),--S;return b}A.prototype.getX=D,A.prototype.getY=P,A.prototype.equals=R,A.prototype.isInfinity=B,A.prototype.negate=F,A.prototype.add=j,A.prototype.twice=N,A.prototype.multiply=Y,A.prototype.multiplyTwo=J;function ie(c,p,x){this.q=c,this.a=this.fromBigInteger(p),this.b=this.fromBigInteger(x),this.infinity=new A(this,null,null),this.reducer=new e(this.q)}function ue(){return this.q}function Q(){return this.a}function ce(){return this.b}function he(c){return c==this?!0:this.q.equals(c.q)&&this.a.equals(c.a)&&this.b.equals(c.b)}function ke(){return this.infinity}function L(c){return new n(this.q,c)}function d(c){this.reducer.reduce(c)}function v(c){if(c.isInfinity())return"00";var p=c.getX().toBigInteger().toString(16),x=c.getY().toBigInteger().toString(16),S=this.getQ().toString(16).length;for(S%2!=0&&S++;p.length<S;)p="0"+p;for(;x.length<S;)x="0"+x;return"04"+p+x}ie.prototype.getQ=ue,ie.prototype.getA=Q,ie.prototype.getB=ce,ie.prototype.equals=he,ie.prototype.getInfinity=ke,ie.prototype.fromBigInteger=L,ie.prototype.reduce=d,ie.prototype.encodePointHex=v,ie.prototype.decodePointHex=function(c){var p;switch(parseInt(c.substr(0,2),16)){case 0:return this.infinity;case 2:p=!1;case 3:p==null&&(p=!0);var T=c.length-2,M=c.substr(2,T),x=this.fromBigInteger(new t(M,16)),S=x.multiply(x.square().add(this.getA())).add(this.getB()),b=S.sqrt();if(b==null)throw"Invalid point compression";var h=b.toBigInteger();return h.testBit(0)!=p&&(b=this.fromBigInteger(this.getQ().subtract(h))),new A(this,x,b);case 4:case 6:case 7:var T=(c.length-2)/2,M=c.substr(2,T),O=c.substr(T+2,T);return new A(this,this.fromBigInteger(new t(M,16)),this.fromBigInteger(new t(O,16)));default:return null}},ie.prototype.encodeCompressedPointHex=function(c){if(c.isInfinity())return"00";var p=c.getX().toBigInteger().toString(16),x=this.getQ().toString(16).length;for(x%2!=0&&x++;p.length<x;)p="0"+p;var S;return c.getY().toBigInteger().isEven()?S="02":S="03",S+p},n.prototype.getR=function(){if(this.r!=null)return this.r;this.r=null;var c=this.q.bitLength();if(c>128){var p=this.q.shiftRight(c-64);p.intValue()==-1&&(this.r=t.ONE.shiftLeft(c).subtract(this.q))}return this.r},n.prototype.modMult=function(c,p){return this.modReduce(c.multiply(p))},n.prototype.modReduce=function(c){if(this.getR()!=null){for(var p=q.bitLength();c.bitLength()>p+1;){var x=c.shiftRight(p),S=c.subtract(x.shiftLeft(p));this.getR().equals(t.ONE)||(x=x.multiply(this.getR())),c=x.add(S)}for(;c.compareTo(q)>=0;)c=c.subtract(q)}else c=c.mod(q);return c},n.prototype.sqrt=function(){if(!this.q.testBit(0))throw"unsupported";if(this.q.testBit(1)){var c=new n(this.q,this.x.modPow(this.q.shiftRight(2).add(t.ONE),this.q));return c.square().equals(this)?c:null}var p=this.q.subtract(t.ONE),x=p.shiftRight(1);if(!this.x.modPow(x,this.q).equals(t.ONE))return null;var S=p.shiftRight(2),b=S.shiftLeft(1).add(t.ONE),h=this.x,T=modDouble(modDouble(h)),M,O;do{var V;do V=new t(this.q.bitLength(),new SecureRandom);while(V.compareTo(this.q)>=0||!V.multiply(V).subtract(T).modPow(x,this.q).equals(p));var ee=this.lucasSequence(V,h,b);if(M=ee[0],O=ee[1],this.modMult(O,O).equals(T))return O.testBit(0)&&(O=O.add(q)),O=O.shiftRight(1),new n(q,O)}while(M.equals(t.ONE)||M.equals(p));return null},n.prototype.lucasSequence=function(c,p,x){for(var S=x.bitLength(),b=x.getLowestSetBit(),h=t.ONE,T=t.TWO,M=c,O=t.ONE,V=t.ONE,ee=S-1;ee>=b+1;--ee)O=this.modMult(O,V),x.testBit(ee)?(V=this.modMult(O,p),h=this.modMult(h,M),T=this.modReduce(M.multiply(T).subtract(c.multiply(O))),M=this.modReduce(M.multiply(M).subtract(V.shiftLeft(1)))):(V=O,h=this.modReduce(h.multiply(T).subtract(O)),M=this.modReduce(M.multiply(T).subtract(c.multiply(O))),T=this.modReduce(T.multiply(T).subtract(O.shiftLeft(1))));O=this.modMult(O,V),V=this.modMult(O,p),h=this.modReduce(h.multiply(T).subtract(O)),T=this.modReduce(M.multiply(T).subtract(c.multiply(O))),O=this.modMult(O,V);for(var ee=1;ee<=b;++ee)h=this.modMult(h,T),T=this.modReduce(T.multiply(T).subtract(O.shiftLeft(1))),O=this.modMult(O,O);return[h,T]};var w={ECCurveFp:ie,ECPointFp:A,ECFieldElementFp:n};return ec=w,ec}function commonjsRequire(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var naclFast={exports:{}},hasRequiredNaclFast;function requireNaclFast(){return hasRequiredNaclFast||(hasRequiredNaclFast=1,function(t){(function(e){var n=function(Be){var be,ge=new Float64Array(16);if(Be)for(be=0;be<Be.length;be++)ge[be]=Be[be];return ge},o=function(){throw new Error("no PRNG")},u=new Uint8Array(16),l=new Uint8Array(32);l[0]=9;var m=n(),y=n([1]),E=n([56129,1]),C=n([30883,4953,19914,30187,55467,16705,2637,112,59544,30585,16505,36039,65139,11119,27886,20995]),k=n([61785,9906,39828,60374,45398,33411,5274,224,53552,61171,33010,6542,64743,22239,55772,9222]),A=n([54554,36645,11616,51542,42930,38181,51040,26924,56412,64982,57905,49316,21502,52590,14035,8553]),D=n([26200,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214]),P=n([41136,18958,6951,50414,58488,44335,6150,12099,55207,15867,153,11085,57099,20417,9344,11139]);function R(Be,be,ge,oe){Be[be]=ge>>24&255,Be[be+1]=ge>>16&255,Be[be+2]=ge>>8&255,Be[be+3]=ge&255,Be[be+4]=oe>>24&255,Be[be+5]=oe>>16&255,Be[be+6]=oe>>8&255,Be[be+7]=oe&255}function B(Be,be,ge,oe,Ae){var qe,bt=0;for(qe=0;qe<Ae;qe++)bt|=Be[be+qe]^ge[oe+qe];return(1&bt-1>>>8)-1}function F(Be,be,ge,oe){return B(Be,be,ge,oe,16)}function j(Be,be,ge,oe){return B(Be,be,ge,oe,32)}function N(Be,be,ge,oe){for(var Ae=oe[0]&255|(oe[1]&255)<<8|(oe[2]&255)<<16|(oe[3]&255)<<24,qe=ge[0]&255|(ge[1]&255)<<8|(ge[2]&255)<<16|(ge[3]&255)<<24,bt=ge[4]&255|(ge[5]&255)<<8|(ge[6]&255)<<16|(ge[7]&255)<<24,at=ge[8]&255|(ge[9]&255)<<8|(ge[10]&255)<<16|(ge[11]&255)<<24,gt=ge[12]&255|(ge[13]&255)<<8|(ge[14]&255)<<16|(ge[15]&255)<<24,ei=oe[4]&255|(oe[5]&255)<<8|(oe[6]&255)<<16|(oe[7]&255)<<24,ii=be[0]&255|(be[1]&255)<<8|(be[2]&255)<<16|(be[3]&255)<<24,Bi=be[4]&255|(be[5]&255)<<8|(be[6]&255)<<16|(be[7]&255)<<24,hi=be[8]&255|(be[9]&255)<<8|(be[10]&255)<<16|(be[11]&255)<<24,Di=be[12]&255|(be[13]&255)<<8|(be[14]&255)<<16|(be[15]&255)<<24,ni=oe[8]&255|(oe[9]&255)<<8|(oe[10]&255)<<16|(oe[11]&255)<<24,pi=ge[16]&255|(ge[17]&255)<<8|(ge[18]&255)<<16|(ge[19]&255)<<24,Ii=ge[20]&255|(ge[21]&255)<<8|(ge[22]&255)<<16|(ge[23]&255)<<24,Ci=ge[24]&255|(ge[25]&255)<<8|(ge[26]&255)<<16|(ge[27]&255)<<24,zi=ge[28]&255|(ge[29]&255)<<8|(ge[30]&255)<<16|(ge[31]&255)<<24,qi=oe[12]&255|(oe[13]&255)<<8|(oe[14]&255)<<16|(oe[15]&255)<<24,Ai=Ae,Oi=qe,ki=bt,Ti=at,wi=gt,oi=ei,zt=ii,Qt=Bi,Si=hi,mi=Di,ai=ni,gi=pi,Hi=Ii,or=Ci,nr=zi,Gi=qi,Mt,er=0;er<20;er+=2)Mt=Ai+Hi|0,wi^=Mt<<7|Mt>>>25,Mt=wi+Ai|0,Si^=Mt<<9|Mt>>>23,Mt=Si+wi|0,Hi^=Mt<<13|Mt>>>19,Mt=Hi+Si|0,Ai^=Mt<<18|Mt>>>14,Mt=oi+Oi|0,mi^=Mt<<7|Mt>>>25,Mt=mi+oi|0,or^=Mt<<9|Mt>>>23,Mt=or+mi|0,Oi^=Mt<<13|Mt>>>19,Mt=Oi+or|0,oi^=Mt<<18|Mt>>>14,Mt=ai+zt|0,nr^=Mt<<7|Mt>>>25,Mt=nr+ai|0,ki^=Mt<<9|Mt>>>23,Mt=ki+nr|0,zt^=Mt<<13|Mt>>>19,Mt=zt+ki|0,ai^=Mt<<18|Mt>>>14,Mt=Gi+gi|0,Ti^=Mt<<7|Mt>>>25,Mt=Ti+Gi|0,Qt^=Mt<<9|Mt>>>23,Mt=Qt+Ti|0,gi^=Mt<<13|Mt>>>19,Mt=gi+Qt|0,Gi^=Mt<<18|Mt>>>14,Mt=Ai+Ti|0,Oi^=Mt<<7|Mt>>>25,Mt=Oi+Ai|0,ki^=Mt<<9|Mt>>>23,Mt=ki+Oi|0,Ti^=Mt<<13|Mt>>>19,Mt=Ti+ki|0,Ai^=Mt<<18|Mt>>>14,Mt=oi+wi|0,zt^=Mt<<7|Mt>>>25,Mt=zt+oi|0,Qt^=Mt<<9|Mt>>>23,Mt=Qt+zt|0,wi^=Mt<<13|Mt>>>19,Mt=wi+Qt|0,oi^=Mt<<18|Mt>>>14,Mt=ai+mi|0,gi^=Mt<<7|Mt>>>25,Mt=gi+ai|0,Si^=Mt<<9|Mt>>>23,Mt=Si+gi|0,mi^=Mt<<13|Mt>>>19,Mt=mi+Si|0,ai^=Mt<<18|Mt>>>14,Mt=Gi+nr|0,Hi^=Mt<<7|Mt>>>25,Mt=Hi+Gi|0,or^=Mt<<9|Mt>>>23,Mt=or+Hi|0,nr^=Mt<<13|Mt>>>19,Mt=nr+or|0,Gi^=Mt<<18|Mt>>>14;Ai=Ai+Ae|0,Oi=Oi+qe|0,ki=ki+bt|0,Ti=Ti+at|0,wi=wi+gt|0,oi=oi+ei|0,zt=zt+ii|0,Qt=Qt+Bi|0,Si=Si+hi|0,mi=mi+Di|0,ai=ai+ni|0,gi=gi+pi|0,Hi=Hi+Ii|0,or=or+Ci|0,nr=nr+zi|0,Gi=Gi+qi|0,Be[0]=Ai>>>0&255,Be[1]=Ai>>>8&255,Be[2]=Ai>>>16&255,Be[3]=Ai>>>24&255,Be[4]=Oi>>>0&255,Be[5]=Oi>>>8&255,Be[6]=Oi>>>16&255,Be[7]=Oi>>>24&255,Be[8]=ki>>>0&255,Be[9]=ki>>>8&255,Be[10]=ki>>>16&255,Be[11]=ki>>>24&255,Be[12]=Ti>>>0&255,Be[13]=Ti>>>8&255,Be[14]=Ti>>>16&255,Be[15]=Ti>>>24&255,Be[16]=wi>>>0&255,Be[17]=wi>>>8&255,Be[18]=wi>>>16&255,Be[19]=wi>>>24&255,Be[20]=oi>>>0&255,Be[21]=oi>>>8&255,Be[22]=oi>>>16&255,Be[23]=oi>>>24&255,Be[24]=zt>>>0&255,Be[25]=zt>>>8&255,Be[26]=zt>>>16&255,Be[27]=zt>>>24&255,Be[28]=Qt>>>0&255,Be[29]=Qt>>>8&255,Be[30]=Qt>>>16&255,Be[31]=Qt>>>24&255,Be[32]=Si>>>0&255,Be[33]=Si>>>8&255,Be[34]=Si>>>16&255,Be[35]=Si>>>24&255,Be[36]=mi>>>0&255,Be[37]=mi>>>8&255,Be[38]=mi>>>16&255,Be[39]=mi>>>24&255,Be[40]=ai>>>0&255,Be[41]=ai>>>8&255,Be[42]=ai>>>16&255,Be[43]=ai>>>24&255,Be[44]=gi>>>0&255,Be[45]=gi>>>8&255,Be[46]=gi>>>16&255,Be[47]=gi>>>24&255,Be[48]=Hi>>>0&255,Be[49]=Hi>>>8&255,Be[50]=Hi>>>16&255,Be[51]=Hi>>>24&255,Be[52]=or>>>0&255,Be[53]=or>>>8&255,Be[54]=or>>>16&255,Be[55]=or>>>24&255,Be[56]=nr>>>0&255,Be[57]=nr>>>8&255,Be[58]=nr>>>16&255,Be[59]=nr>>>24&255,Be[60]=Gi>>>0&255,Be[61]=Gi>>>8&255,Be[62]=Gi>>>16&255,Be[63]=Gi>>>24&255}function Y(Be,be,ge,oe){for(var Ae=oe[0]&255|(oe[1]&255)<<8|(oe[2]&255)<<16|(oe[3]&255)<<24,qe=ge[0]&255|(ge[1]&255)<<8|(ge[2]&255)<<16|(ge[3]&255)<<24,bt=ge[4]&255|(ge[5]&255)<<8|(ge[6]&255)<<16|(ge[7]&255)<<24,at=ge[8]&255|(ge[9]&255)<<8|(ge[10]&255)<<16|(ge[11]&255)<<24,gt=ge[12]&255|(ge[13]&255)<<8|(ge[14]&255)<<16|(ge[15]&255)<<24,ei=oe[4]&255|(oe[5]&255)<<8|(oe[6]&255)<<16|(oe[7]&255)<<24,ii=be[0]&255|(be[1]&255)<<8|(be[2]&255)<<16|(be[3]&255)<<24,Bi=be[4]&255|(be[5]&255)<<8|(be[6]&255)<<16|(be[7]&255)<<24,hi=be[8]&255|(be[9]&255)<<8|(be[10]&255)<<16|(be[11]&255)<<24,Di=be[12]&255|(be[13]&255)<<8|(be[14]&255)<<16|(be[15]&255)<<24,ni=oe[8]&255|(oe[9]&255)<<8|(oe[10]&255)<<16|(oe[11]&255)<<24,pi=ge[16]&255|(ge[17]&255)<<8|(ge[18]&255)<<16|(ge[19]&255)<<24,Ii=ge[20]&255|(ge[21]&255)<<8|(ge[22]&255)<<16|(ge[23]&255)<<24,Ci=ge[24]&255|(ge[25]&255)<<8|(ge[26]&255)<<16|(ge[27]&255)<<24,zi=ge[28]&255|(ge[29]&255)<<8|(ge[30]&255)<<16|(ge[31]&255)<<24,qi=oe[12]&255|(oe[13]&255)<<8|(oe[14]&255)<<16|(oe[15]&255)<<24,Ai=Ae,Oi=qe,ki=bt,Ti=at,wi=gt,oi=ei,zt=ii,Qt=Bi,Si=hi,mi=Di,ai=ni,gi=pi,Hi=Ii,or=Ci,nr=zi,Gi=qi,Mt,er=0;er<20;er+=2)Mt=Ai+Hi|0,wi^=Mt<<7|Mt>>>25,Mt=wi+Ai|0,Si^=Mt<<9|Mt>>>23,Mt=Si+wi|0,Hi^=Mt<<13|Mt>>>19,Mt=Hi+Si|0,Ai^=Mt<<18|Mt>>>14,Mt=oi+Oi|0,mi^=Mt<<7|Mt>>>25,Mt=mi+oi|0,or^=Mt<<9|Mt>>>23,Mt=or+mi|0,Oi^=Mt<<13|Mt>>>19,Mt=Oi+or|0,oi^=Mt<<18|Mt>>>14,Mt=ai+zt|0,nr^=Mt<<7|Mt>>>25,Mt=nr+ai|0,ki^=Mt<<9|Mt>>>23,Mt=ki+nr|0,zt^=Mt<<13|Mt>>>19,Mt=zt+ki|0,ai^=Mt<<18|Mt>>>14,Mt=Gi+gi|0,Ti^=Mt<<7|Mt>>>25,Mt=Ti+Gi|0,Qt^=Mt<<9|Mt>>>23,Mt=Qt+Ti|0,gi^=Mt<<13|Mt>>>19,Mt=gi+Qt|0,Gi^=Mt<<18|Mt>>>14,Mt=Ai+Ti|0,Oi^=Mt<<7|Mt>>>25,Mt=Oi+Ai|0,ki^=Mt<<9|Mt>>>23,Mt=ki+Oi|0,Ti^=Mt<<13|Mt>>>19,Mt=Ti+ki|0,Ai^=Mt<<18|Mt>>>14,Mt=oi+wi|0,zt^=Mt<<7|Mt>>>25,Mt=zt+oi|0,Qt^=Mt<<9|Mt>>>23,Mt=Qt+zt|0,wi^=Mt<<13|Mt>>>19,Mt=wi+Qt|0,oi^=Mt<<18|Mt>>>14,Mt=ai+mi|0,gi^=Mt<<7|Mt>>>25,Mt=gi+ai|0,Si^=Mt<<9|Mt>>>23,Mt=Si+gi|0,mi^=Mt<<13|Mt>>>19,Mt=mi+Si|0,ai^=Mt<<18|Mt>>>14,Mt=Gi+nr|0,Hi^=Mt<<7|Mt>>>25,Mt=Hi+Gi|0,or^=Mt<<9|Mt>>>23,Mt=or+Hi|0,nr^=Mt<<13|Mt>>>19,Mt=nr+or|0,Gi^=Mt<<18|Mt>>>14;Be[0]=Ai>>>0&255,Be[1]=Ai>>>8&255,Be[2]=Ai>>>16&255,Be[3]=Ai>>>24&255,Be[4]=oi>>>0&255,Be[5]=oi>>>8&255,Be[6]=oi>>>16&255,Be[7]=oi>>>24&255,Be[8]=ai>>>0&255,Be[9]=ai>>>8&255,Be[10]=ai>>>16&255,Be[11]=ai>>>24&255,Be[12]=Gi>>>0&255,Be[13]=Gi>>>8&255,Be[14]=Gi>>>16&255,Be[15]=Gi>>>24&255,Be[16]=zt>>>0&255,Be[17]=zt>>>8&255,Be[18]=zt>>>16&255,Be[19]=zt>>>24&255,Be[20]=Qt>>>0&255,Be[21]=Qt>>>8&255,Be[22]=Qt>>>16&255,Be[23]=Qt>>>24&255,Be[24]=Si>>>0&255,Be[25]=Si>>>8&255,Be[26]=Si>>>16&255,Be[27]=Si>>>24&255,Be[28]=mi>>>0&255,Be[29]=mi>>>8&255,Be[30]=mi>>>16&255,Be[31]=mi>>>24&255}function J(Be,be,ge,oe){N(Be,be,ge,oe)}function ie(Be,be,ge,oe){Y(Be,be,ge,oe)}var ue=new Uint8Array([101,120,112,97,110,100,32,51,50,45,98,121,116,101,32,107]);function Q(Be,be,ge,oe,Ae,qe,bt){var at=new Uint8Array(16),gt=new Uint8Array(64),ei,ii;for(ii=0;ii<16;ii++)at[ii]=0;for(ii=0;ii<8;ii++)at[ii]=qe[ii];for(;Ae>=64;){for(J(gt,at,bt,ue),ii=0;ii<64;ii++)Be[be+ii]=ge[oe+ii]^gt[ii];for(ei=1,ii=8;ii<16;ii++)ei=ei+(at[ii]&255)|0,at[ii]=ei&255,ei>>>=8;Ae-=64,be+=64,oe+=64}if(Ae>0)for(J(gt,at,bt,ue),ii=0;ii<Ae;ii++)Be[be+ii]=ge[oe+ii]^gt[ii];return 0}function ce(Be,be,ge,oe,Ae){var qe=new Uint8Array(16),bt=new Uint8Array(64),at,gt;for(gt=0;gt<16;gt++)qe[gt]=0;for(gt=0;gt<8;gt++)qe[gt]=oe[gt];for(;ge>=64;){for(J(bt,qe,Ae,ue),gt=0;gt<64;gt++)Be[be+gt]=bt[gt];for(at=1,gt=8;gt<16;gt++)at=at+(qe[gt]&255)|0,qe[gt]=at&255,at>>>=8;ge-=64,be+=64}if(ge>0)for(J(bt,qe,Ae,ue),gt=0;gt<ge;gt++)Be[be+gt]=bt[gt];return 0}function he(Be,be,ge,oe,Ae){var qe=new Uint8Array(32);ie(qe,oe,Ae,ue);for(var bt=new Uint8Array(8),at=0;at<8;at++)bt[at]=oe[at+16];return ce(Be,be,ge,bt,qe)}function ke(Be,be,ge,oe,Ae,qe,bt){var at=new Uint8Array(32);ie(at,qe,bt,ue);for(var gt=new Uint8Array(8),ei=0;ei<8;ei++)gt[ei]=qe[ei+16];return Q(Be,be,ge,oe,Ae,gt,at)}var L=function(Be){this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.leftover=0,this.fin=0;var be,ge,oe,Ae,qe,bt,at,gt;be=Be[0]&255|(Be[1]&255)<<8,this.r[0]=be&8191,ge=Be[2]&255|(Be[3]&255)<<8,this.r[1]=(be>>>13|ge<<3)&8191,oe=Be[4]&255|(Be[5]&255)<<8,this.r[2]=(ge>>>10|oe<<6)&7939,Ae=Be[6]&255|(Be[7]&255)<<8,this.r[3]=(oe>>>7|Ae<<9)&8191,qe=Be[8]&255|(Be[9]&255)<<8,this.r[4]=(Ae>>>4|qe<<12)&255,this.r[5]=qe>>>1&8190,bt=Be[10]&255|(Be[11]&255)<<8,this.r[6]=(qe>>>14|bt<<2)&8191,at=Be[12]&255|(Be[13]&255)<<8,this.r[7]=(bt>>>11|at<<5)&8065,gt=Be[14]&255|(Be[15]&255)<<8,this.r[8]=(at>>>8|gt<<8)&8191,this.r[9]=gt>>>5&127,this.pad[0]=Be[16]&255|(Be[17]&255)<<8,this.pad[1]=Be[18]&255|(Be[19]&255)<<8,this.pad[2]=Be[20]&255|(Be[21]&255)<<8,this.pad[3]=Be[22]&255|(Be[23]&255)<<8,this.pad[4]=Be[24]&255|(Be[25]&255)<<8,this.pad[5]=Be[26]&255|(Be[27]&255)<<8,this.pad[6]=Be[28]&255|(Be[29]&255)<<8,this.pad[7]=Be[30]&255|(Be[31]&255)<<8};L.prototype.blocks=function(Be,be,ge){for(var oe=this.fin?0:2048,Ae,qe,bt,at,gt,ei,ii,Bi,hi,Di,ni,pi,Ii,Ci,zi,qi,Ai,Oi,ki,Ti=this.h[0],wi=this.h[1],oi=this.h[2],zt=this.h[3],Qt=this.h[4],Si=this.h[5],mi=this.h[6],ai=this.h[7],gi=this.h[8],Hi=this.h[9],or=this.r[0],nr=this.r[1],Gi=this.r[2],Mt=this.r[3],er=this.r[4],tr=this.r[5],br=this.r[6],le=this.r[7],we=this.r[8],$e=this.r[9];ge>=16;)Ae=Be[be+0]&255|(Be[be+1]&255)<<8,Ti+=Ae&8191,qe=Be[be+2]&255|(Be[be+3]&255)<<8,wi+=(Ae>>>13|qe<<3)&8191,bt=Be[be+4]&255|(Be[be+5]&255)<<8,oi+=(qe>>>10|bt<<6)&8191,at=Be[be+6]&255|(Be[be+7]&255)<<8,zt+=(bt>>>7|at<<9)&8191,gt=Be[be+8]&255|(Be[be+9]&255)<<8,Qt+=(at>>>4|gt<<12)&8191,Si+=gt>>>1&8191,ei=Be[be+10]&255|(Be[be+11]&255)<<8,mi+=(gt>>>14|ei<<2)&8191,ii=Be[be+12]&255|(Be[be+13]&255)<<8,ai+=(ei>>>11|ii<<5)&8191,Bi=Be[be+14]&255|(Be[be+15]&255)<<8,gi+=(ii>>>8|Bi<<8)&8191,Hi+=Bi>>>5|oe,hi=0,Di=hi,Di+=Ti*or,Di+=wi*(5*$e),Di+=oi*(5*we),Di+=zt*(5*le),Di+=Qt*(5*br),hi=Di>>>13,Di&=8191,Di+=Si*(5*tr),Di+=mi*(5*er),Di+=ai*(5*Mt),Di+=gi*(5*Gi),Di+=Hi*(5*nr),hi+=Di>>>13,Di&=8191,ni=hi,ni+=Ti*nr,ni+=wi*or,ni+=oi*(5*$e),ni+=zt*(5*we),ni+=Qt*(5*le),hi=ni>>>13,ni&=8191,ni+=Si*(5*br),ni+=mi*(5*tr),ni+=ai*(5*er),ni+=gi*(5*Mt),ni+=Hi*(5*Gi),hi+=ni>>>13,ni&=8191,pi=hi,pi+=Ti*Gi,pi+=wi*nr,pi+=oi*or,pi+=zt*(5*$e),pi+=Qt*(5*we),hi=pi>>>13,pi&=8191,pi+=Si*(5*le),pi+=mi*(5*br),pi+=ai*(5*tr),pi+=gi*(5*er),pi+=Hi*(5*Mt),hi+=pi>>>13,pi&=8191,Ii=hi,Ii+=Ti*Mt,Ii+=wi*Gi,Ii+=oi*nr,Ii+=zt*or,Ii+=Qt*(5*$e),hi=Ii>>>13,Ii&=8191,Ii+=Si*(5*we),Ii+=mi*(5*le),Ii+=ai*(5*br),Ii+=gi*(5*tr),Ii+=Hi*(5*er),hi+=Ii>>>13,Ii&=8191,Ci=hi,Ci+=Ti*er,Ci+=wi*Mt,Ci+=oi*Gi,Ci+=zt*nr,Ci+=Qt*or,hi=Ci>>>13,Ci&=8191,Ci+=Si*(5*$e),Ci+=mi*(5*we),Ci+=ai*(5*le),Ci+=gi*(5*br),Ci+=Hi*(5*tr),hi+=Ci>>>13,Ci&=8191,zi=hi,zi+=Ti*tr,zi+=wi*er,zi+=oi*Mt,zi+=zt*Gi,zi+=Qt*nr,hi=zi>>>13,zi&=8191,zi+=Si*or,zi+=mi*(5*$e),zi+=ai*(5*we),zi+=gi*(5*le),zi+=Hi*(5*br),hi+=zi>>>13,zi&=8191,qi=hi,qi+=Ti*br,qi+=wi*tr,qi+=oi*er,qi+=zt*Mt,qi+=Qt*Gi,hi=qi>>>13,qi&=8191,qi+=Si*nr,qi+=mi*or,qi+=ai*(5*$e),qi+=gi*(5*we),qi+=Hi*(5*le),hi+=qi>>>13,qi&=8191,Ai=hi,Ai+=Ti*le,Ai+=wi*br,Ai+=oi*tr,Ai+=zt*er,Ai+=Qt*Mt,hi=Ai>>>13,Ai&=8191,Ai+=Si*Gi,Ai+=mi*nr,Ai+=ai*or,Ai+=gi*(5*$e),Ai+=Hi*(5*we),hi+=Ai>>>13,Ai&=8191,Oi=hi,Oi+=Ti*we,Oi+=wi*le,Oi+=oi*br,Oi+=zt*tr,Oi+=Qt*er,hi=Oi>>>13,Oi&=8191,Oi+=Si*Mt,Oi+=mi*Gi,Oi+=ai*nr,Oi+=gi*or,Oi+=Hi*(5*$e),hi+=Oi>>>13,Oi&=8191,ki=hi,ki+=Ti*$e,ki+=wi*we,ki+=oi*le,ki+=zt*br,ki+=Qt*tr,hi=ki>>>13,ki&=8191,ki+=Si*er,ki+=mi*Mt,ki+=ai*Gi,ki+=gi*nr,ki+=Hi*or,hi+=ki>>>13,ki&=8191,hi=(hi<<2)+hi|0,hi=hi+Di|0,Di=hi&8191,hi=hi>>>13,ni+=hi,Ti=Di,wi=ni,oi=pi,zt=Ii,Qt=Ci,Si=zi,mi=qi,ai=Ai,gi=Oi,Hi=ki,be+=16,ge-=16;this.h[0]=Ti,this.h[1]=wi,this.h[2]=oi,this.h[3]=zt,this.h[4]=Qt,this.h[5]=Si,this.h[6]=mi,this.h[7]=ai,this.h[8]=gi,this.h[9]=Hi},L.prototype.finish=function(Be,be){var ge=new Uint16Array(10),oe,Ae,qe,bt;if(this.leftover){for(bt=this.leftover,this.buffer[bt++]=1;bt<16;bt++)this.buffer[bt]=0;this.fin=1,this.blocks(this.buffer,0,16)}for(oe=this.h[1]>>>13,this.h[1]&=8191,bt=2;bt<10;bt++)this.h[bt]+=oe,oe=this.h[bt]>>>13,this.h[bt]&=8191;for(this.h[0]+=oe*5,oe=this.h[0]>>>13,this.h[0]&=8191,this.h[1]+=oe,oe=this.h[1]>>>13,this.h[1]&=8191,this.h[2]+=oe,ge[0]=this.h[0]+5,oe=ge[0]>>>13,ge[0]&=8191,bt=1;bt<10;bt++)ge[bt]=this.h[bt]+oe,oe=ge[bt]>>>13,ge[bt]&=8191;for(ge[9]-=8192,Ae=(oe^1)-1,bt=0;bt<10;bt++)ge[bt]&=Ae;for(Ae=~Ae,bt=0;bt<10;bt++)this.h[bt]=this.h[bt]&Ae|ge[bt];for(this.h[0]=(this.h[0]|this.h[1]<<13)&65535,this.h[1]=(this.h[1]>>>3|this.h[2]<<10)&65535,this.h[2]=(this.h[2]>>>6|this.h[3]<<7)&65535,this.h[3]=(this.h[3]>>>9|this.h[4]<<4)&65535,this.h[4]=(this.h[4]>>>12|this.h[5]<<1|this.h[6]<<14)&65535,this.h[5]=(this.h[6]>>>2|this.h[7]<<11)&65535,this.h[6]=(this.h[7]>>>5|this.h[8]<<8)&65535,this.h[7]=(this.h[8]>>>8|this.h[9]<<5)&65535,qe=this.h[0]+this.pad[0],this.h[0]=qe&65535,bt=1;bt<8;bt++)qe=(this.h[bt]+this.pad[bt]|0)+(qe>>>16)|0,this.h[bt]=qe&65535;Be[be+0]=this.h[0]>>>0&255,Be[be+1]=this.h[0]>>>8&255,Be[be+2]=this.h[1]>>>0&255,Be[be+3]=this.h[1]>>>8&255,Be[be+4]=this.h[2]>>>0&255,Be[be+5]=this.h[2]>>>8&255,Be[be+6]=this.h[3]>>>0&255,Be[be+7]=this.h[3]>>>8&255,Be[be+8]=this.h[4]>>>0&255,Be[be+9]=this.h[4]>>>8&255,Be[be+10]=this.h[5]>>>0&255,Be[be+11]=this.h[5]>>>8&255,Be[be+12]=this.h[6]>>>0&255,Be[be+13]=this.h[6]>>>8&255,Be[be+14]=this.h[7]>>>0&255,Be[be+15]=this.h[7]>>>8&255},L.prototype.update=function(Be,be,ge){var oe,Ae;if(this.leftover){for(Ae=16-this.leftover,Ae>ge&&(Ae=ge),oe=0;oe<Ae;oe++)this.buffer[this.leftover+oe]=Be[be+oe];if(ge-=Ae,be+=Ae,this.leftover+=Ae,this.leftover<16)return;this.blocks(this.buffer,0,16),this.leftover=0}if(ge>=16&&(Ae=ge-ge%16,this.blocks(Be,be,Ae),be+=Ae,ge-=Ae),ge){for(oe=0;oe<ge;oe++)this.buffer[this.leftover+oe]=Be[be+oe];this.leftover+=ge}};function d(Be,be,ge,oe,Ae,qe){var bt=new L(qe);return bt.update(ge,oe,Ae),bt.finish(Be,be),0}function v(Be,be,ge,oe,Ae,qe){var bt=new Uint8Array(16);return d(bt,0,ge,oe,Ae,qe),F(Be,be,bt,0)}function w(Be,be,ge,oe,Ae){var qe;if(ge<32)return-1;for(ke(Be,0,be,0,ge,oe,Ae),d(Be,16,Be,32,ge-32,Be),qe=0;qe<16;qe++)Be[qe]=0;return 0}function c(Be,be,ge,oe,Ae){var qe,bt=new Uint8Array(32);if(ge<32||(he(bt,0,32,oe,Ae),v(be,16,be,32,ge-32,bt)!==0))return-1;for(ke(Be,0,be,0,ge,oe,Ae),qe=0;qe<32;qe++)Be[qe]=0;return 0}function p(Be,be){var ge;for(ge=0;ge<16;ge++)Be[ge]=be[ge]|0}function x(Be){var be,ge,oe=1;for(be=0;be<16;be++)ge=Be[be]+oe+65535,oe=Math.floor(ge/65536),Be[be]=ge-oe*65536;Be[0]+=oe-1+37*(oe-1)}function S(Be,be,ge){for(var oe,Ae=~(ge-1),qe=0;qe<16;qe++)oe=Ae&(Be[qe]^be[qe]),Be[qe]^=oe,be[qe]^=oe}function b(Be,be){var ge,oe,Ae,qe=n(),bt=n();for(ge=0;ge<16;ge++)bt[ge]=be[ge];for(x(bt),x(bt),x(bt),oe=0;oe<2;oe++){for(qe[0]=bt[0]-65517,ge=1;ge<15;ge++)qe[ge]=bt[ge]-65535-(qe[ge-1]>>16&1),qe[ge-1]&=65535;qe[15]=bt[15]-32767-(qe[14]>>16&1),Ae=qe[15]>>16&1,qe[14]&=65535,S(bt,qe,1-Ae)}for(ge=0;ge<16;ge++)Be[2*ge]=bt[ge]&255,Be[2*ge+1]=bt[ge]>>8}function h(Be,be){var ge=new Uint8Array(32),oe=new Uint8Array(32);return b(ge,Be),b(oe,be),j(ge,0,oe,0)}function T(Be){var be=new Uint8Array(32);return b(be,Be),be[0]&1}function M(Be,be){var ge;for(ge=0;ge<16;ge++)Be[ge]=be[2*ge]+(be[2*ge+1]<<8);Be[15]&=32767}function O(Be,be,ge){for(var oe=0;oe<16;oe++)Be[oe]=be[oe]+ge[oe]}function V(Be,be,ge){for(var oe=0;oe<16;oe++)Be[oe]=be[oe]-ge[oe]}function ee(Be,be,ge){var oe,Ae,qe=0,bt=0,at=0,gt=0,ei=0,ii=0,Bi=0,hi=0,Di=0,ni=0,pi=0,Ii=0,Ci=0,zi=0,qi=0,Ai=0,Oi=0,ki=0,Ti=0,wi=0,oi=0,zt=0,Qt=0,Si=0,mi=0,ai=0,gi=0,Hi=0,or=0,nr=0,Gi=0,Mt=ge[0],er=ge[1],tr=ge[2],br=ge[3],le=ge[4],we=ge[5],$e=ge[6],Oe=ge[7],Ge=ge[8],st=ge[9],xe=ge[10],Ee=ge[11],Ie=ge[12],Xe=ge[13],xt=ge[14],Lt=ge[15];oe=be[0],qe+=oe*Mt,bt+=oe*er,at+=oe*tr,gt+=oe*br,ei+=oe*le,ii+=oe*we,Bi+=oe*$e,hi+=oe*Oe,Di+=oe*Ge,ni+=oe*st,pi+=oe*xe,Ii+=oe*Ee,Ci+=oe*Ie,zi+=oe*Xe,qi+=oe*xt,Ai+=oe*Lt,oe=be[1],bt+=oe*Mt,at+=oe*er,gt+=oe*tr,ei+=oe*br,ii+=oe*le,Bi+=oe*we,hi+=oe*$e,Di+=oe*Oe,ni+=oe*Ge,pi+=oe*st,Ii+=oe*xe,Ci+=oe*Ee,zi+=oe*Ie,qi+=oe*Xe,Ai+=oe*xt,Oi+=oe*Lt,oe=be[2],at+=oe*Mt,gt+=oe*er,ei+=oe*tr,ii+=oe*br,Bi+=oe*le,hi+=oe*we,Di+=oe*$e,ni+=oe*Oe,pi+=oe*Ge,Ii+=oe*st,Ci+=oe*xe,zi+=oe*Ee,qi+=oe*Ie,Ai+=oe*Xe,Oi+=oe*xt,ki+=oe*Lt,oe=be[3],gt+=oe*Mt,ei+=oe*er,ii+=oe*tr,Bi+=oe*br,hi+=oe*le,Di+=oe*we,ni+=oe*$e,pi+=oe*Oe,Ii+=oe*Ge,Ci+=oe*st,zi+=oe*xe,qi+=oe*Ee,Ai+=oe*Ie,Oi+=oe*Xe,ki+=oe*xt,Ti+=oe*Lt,oe=be[4],ei+=oe*Mt,ii+=oe*er,Bi+=oe*tr,hi+=oe*br,Di+=oe*le,ni+=oe*we,pi+=oe*$e,Ii+=oe*Oe,Ci+=oe*Ge,zi+=oe*st,qi+=oe*xe,Ai+=oe*Ee,Oi+=oe*Ie,ki+=oe*Xe,Ti+=oe*xt,wi+=oe*Lt,oe=be[5],ii+=oe*Mt,Bi+=oe*er,hi+=oe*tr,Di+=oe*br,ni+=oe*le,pi+=oe*we,Ii+=oe*$e,Ci+=oe*Oe,zi+=oe*Ge,qi+=oe*st,Ai+=oe*xe,Oi+=oe*Ee,ki+=oe*Ie,Ti+=oe*Xe,wi+=oe*xt,oi+=oe*Lt,oe=be[6],Bi+=oe*Mt,hi+=oe*er,Di+=oe*tr,ni+=oe*br,pi+=oe*le,Ii+=oe*we,Ci+=oe*$e,zi+=oe*Oe,qi+=oe*Ge,Ai+=oe*st,Oi+=oe*xe,ki+=oe*Ee,Ti+=oe*Ie,wi+=oe*Xe,oi+=oe*xt,zt+=oe*Lt,oe=be[7],hi+=oe*Mt,Di+=oe*er,ni+=oe*tr,pi+=oe*br,Ii+=oe*le,Ci+=oe*we,zi+=oe*$e,qi+=oe*Oe,Ai+=oe*Ge,Oi+=oe*st,ki+=oe*xe,Ti+=oe*Ee,wi+=oe*Ie,oi+=oe*Xe,zt+=oe*xt,Qt+=oe*Lt,oe=be[8],Di+=oe*Mt,ni+=oe*er,pi+=oe*tr,Ii+=oe*br,Ci+=oe*le,zi+=oe*we,qi+=oe*$e,Ai+=oe*Oe,Oi+=oe*Ge,ki+=oe*st,Ti+=oe*xe,wi+=oe*Ee,oi+=oe*Ie,zt+=oe*Xe,Qt+=oe*xt,Si+=oe*Lt,oe=be[9],ni+=oe*Mt,pi+=oe*er,Ii+=oe*tr,Ci+=oe*br,zi+=oe*le,qi+=oe*we,Ai+=oe*$e,Oi+=oe*Oe,ki+=oe*Ge,Ti+=oe*st,wi+=oe*xe,oi+=oe*Ee,zt+=oe*Ie,Qt+=oe*Xe,Si+=oe*xt,mi+=oe*Lt,oe=be[10],pi+=oe*Mt,Ii+=oe*er,Ci+=oe*tr,zi+=oe*br,qi+=oe*le,Ai+=oe*we,Oi+=oe*$e,ki+=oe*Oe,Ti+=oe*Ge,wi+=oe*st,oi+=oe*xe,zt+=oe*Ee,Qt+=oe*Ie,Si+=oe*Xe,mi+=oe*xt,ai+=oe*Lt,oe=be[11],Ii+=oe*Mt,Ci+=oe*er,zi+=oe*tr,qi+=oe*br,Ai+=oe*le,Oi+=oe*we,ki+=oe*$e,Ti+=oe*Oe,wi+=oe*Ge,oi+=oe*st,zt+=oe*xe,Qt+=oe*Ee,Si+=oe*Ie,mi+=oe*Xe,ai+=oe*xt,gi+=oe*Lt,oe=be[12],Ci+=oe*Mt,zi+=oe*er,qi+=oe*tr,Ai+=oe*br,Oi+=oe*le,ki+=oe*we,Ti+=oe*$e,wi+=oe*Oe,oi+=oe*Ge,zt+=oe*st,Qt+=oe*xe,Si+=oe*Ee,mi+=oe*Ie,ai+=oe*Xe,gi+=oe*xt,Hi+=oe*Lt,oe=be[13],zi+=oe*Mt,qi+=oe*er,Ai+=oe*tr,Oi+=oe*br,ki+=oe*le,Ti+=oe*we,wi+=oe*$e,oi+=oe*Oe,zt+=oe*Ge,Qt+=oe*st,Si+=oe*xe,mi+=oe*Ee,ai+=oe*Ie,gi+=oe*Xe,Hi+=oe*xt,or+=oe*Lt,oe=be[14],qi+=oe*Mt,Ai+=oe*er,Oi+=oe*tr,ki+=oe*br,Ti+=oe*le,wi+=oe*we,oi+=oe*$e,zt+=oe*Oe,Qt+=oe*Ge,Si+=oe*st,mi+=oe*xe,ai+=oe*Ee,gi+=oe*Ie,Hi+=oe*Xe,or+=oe*xt,nr+=oe*Lt,oe=be[15],Ai+=oe*Mt,Oi+=oe*er,ki+=oe*tr,Ti+=oe*br,wi+=oe*le,oi+=oe*we,zt+=oe*$e,Qt+=oe*Oe,Si+=oe*Ge,mi+=oe*st,ai+=oe*xe,gi+=oe*Ee,Hi+=oe*Ie,or+=oe*Xe,nr+=oe*xt,Gi+=oe*Lt,qe+=38*Oi,bt+=38*ki,at+=38*Ti,gt+=38*wi,ei+=38*oi,ii+=38*zt,Bi+=38*Qt,hi+=38*Si,Di+=38*mi,ni+=38*ai,pi+=38*gi,Ii+=38*Hi,Ci+=38*or,zi+=38*nr,qi+=38*Gi,Ae=1,oe=qe+Ae+65535,Ae=Math.floor(oe/65536),qe=oe-Ae*65536,oe=bt+Ae+65535,Ae=Math.floor(oe/65536),bt=oe-Ae*65536,oe=at+Ae+65535,Ae=Math.floor(oe/65536),at=oe-Ae*65536,oe=gt+Ae+65535,Ae=Math.floor(oe/65536),gt=oe-Ae*65536,oe=ei+Ae+65535,Ae=Math.floor(oe/65536),ei=oe-Ae*65536,oe=ii+Ae+65535,Ae=Math.floor(oe/65536),ii=oe-Ae*65536,oe=Bi+Ae+65535,Ae=Math.floor(oe/65536),Bi=oe-Ae*65536,oe=hi+Ae+65535,Ae=Math.floor(oe/65536),hi=oe-Ae*65536,oe=Di+Ae+65535,Ae=Math.floor(oe/65536),Di=oe-Ae*65536,oe=ni+Ae+65535,Ae=Math.floor(oe/65536),ni=oe-Ae*65536,oe=pi+Ae+65535,Ae=Math.floor(oe/65536),pi=oe-Ae*65536,oe=Ii+Ae+65535,Ae=Math.floor(oe/65536),Ii=oe-Ae*65536,oe=Ci+Ae+65535,Ae=Math.floor(oe/65536),Ci=oe-Ae*65536,oe=zi+Ae+65535,Ae=Math.floor(oe/65536),zi=oe-Ae*65536,oe=qi+Ae+65535,Ae=Math.floor(oe/65536),qi=oe-Ae*65536,oe=Ai+Ae+65535,Ae=Math.floor(oe/65536),Ai=oe-Ae*65536,qe+=Ae-1+37*(Ae-1),Ae=1,oe=qe+Ae+65535,Ae=Math.floor(oe/65536),qe=oe-Ae*65536,oe=bt+Ae+65535,Ae=Math.floor(oe/65536),bt=oe-Ae*65536,oe=at+Ae+65535,Ae=Math.floor(oe/65536),at=oe-Ae*65536,oe=gt+Ae+65535,Ae=Math.floor(oe/65536),gt=oe-Ae*65536,oe=ei+Ae+65535,Ae=Math.floor(oe/65536),ei=oe-Ae*65536,oe=ii+Ae+65535,Ae=Math.floor(oe/65536),ii=oe-Ae*65536,oe=Bi+Ae+65535,Ae=Math.floor(oe/65536),Bi=oe-Ae*65536,oe=hi+Ae+65535,Ae=Math.floor(oe/65536),hi=oe-Ae*65536,oe=Di+Ae+65535,Ae=Math.floor(oe/65536),Di=oe-Ae*65536,oe=ni+Ae+65535,Ae=Math.floor(oe/65536),ni=oe-Ae*65536,oe=pi+Ae+65535,Ae=Math.floor(oe/65536),pi=oe-Ae*65536,oe=Ii+Ae+65535,Ae=Math.floor(oe/65536),Ii=oe-Ae*65536,oe=Ci+Ae+65535,Ae=Math.floor(oe/65536),Ci=oe-Ae*65536,oe=zi+Ae+65535,Ae=Math.floor(oe/65536),zi=oe-Ae*65536,oe=qi+Ae+65535,Ae=Math.floor(oe/65536),qi=oe-Ae*65536,oe=Ai+Ae+65535,Ae=Math.floor(oe/65536),Ai=oe-Ae*65536,qe+=Ae-1+37*(Ae-1),Be[0]=qe,Be[1]=bt,Be[2]=at,Be[3]=gt,Be[4]=ei,Be[5]=ii,Be[6]=Bi,Be[7]=hi,Be[8]=Di,Be[9]=ni,Be[10]=pi,Be[11]=Ii,Be[12]=Ci,Be[13]=zi,Be[14]=qi,Be[15]=Ai}function Z(Be,be){ee(Be,be,be)}function U(Be,be){var ge=n(),oe;for(oe=0;oe<16;oe++)ge[oe]=be[oe];for(oe=253;oe>=0;oe--)Z(ge,ge),oe!==2&&oe!==4&&ee(ge,ge,be);for(oe=0;oe<16;oe++)Be[oe]=ge[oe]}function z(Be,be){var ge=n(),oe;for(oe=0;oe<16;oe++)ge[oe]=be[oe];for(oe=250;oe>=0;oe--)Z(ge,ge),oe!==1&&ee(ge,ge,be);for(oe=0;oe<16;oe++)Be[oe]=ge[oe]}function ne(Be,be,ge){var oe=new Uint8Array(32),Ae=new Float64Array(80),qe,bt,at=n(),gt=n(),ei=n(),ii=n(),Bi=n(),hi=n();for(bt=0;bt<31;bt++)oe[bt]=be[bt];for(oe[31]=be[31]&127|64,oe[0]&=248,M(Ae,ge),bt=0;bt<16;bt++)gt[bt]=Ae[bt],ii[bt]=at[bt]=ei[bt]=0;for(at[0]=ii[0]=1,bt=254;bt>=0;--bt)qe=oe[bt>>>3]>>>(bt&7)&1,S(at,gt,qe),S(ei,ii,qe),O(Bi,at,ei),V(at,at,ei),O(ei,gt,ii),V(gt,gt,ii),Z(ii,Bi),Z(hi,at),ee(at,ei,at),ee(ei,gt,Bi),O(Bi,at,ei),V(at,at,ei),Z(gt,at),V(ei,ii,hi),ee(at,ei,E),O(at,at,ii),ee(ei,ei,at),ee(at,ii,hi),ee(ii,gt,Ae),Z(gt,Bi),S(at,gt,qe),S(ei,ii,qe);for(bt=0;bt<16;bt++)Ae[bt+16]=at[bt],Ae[bt+32]=ei[bt],Ae[bt+48]=gt[bt],Ae[bt+64]=ii[bt];var Di=Ae.subarray(32),ni=Ae.subarray(16);return U(Di,Di),ee(ni,ni,Di),b(Be,ni),0}function fe(Be,be){return ne(Be,be,l)}function me(Be,be){return o(be,32),fe(Be,be)}function de(Be,be,ge){var oe=new Uint8Array(32);return ne(oe,ge,be),ie(Be,u,oe,ue)}var je=w,lt=c;function it(Be,be,ge,oe,Ae,qe){var bt=new Uint8Array(32);return de(bt,Ae,qe),je(Be,be,ge,oe,bt)}function ot(Be,be,ge,oe,Ae,qe){var bt=new Uint8Array(32);return de(bt,Ae,qe),lt(Be,be,ge,oe,bt)}var Ct=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function nt(Be,be,ge,oe){for(var Ae=new Int32Array(16),qe=new Int32Array(16),bt,at,gt,ei,ii,Bi,hi,Di,ni,pi,Ii,Ci,zi,qi,Ai,Oi,ki,Ti,wi,oi,zt,Qt,Si,mi,ai,gi,Hi=Be[0],or=Be[1],nr=Be[2],Gi=Be[3],Mt=Be[4],er=Be[5],tr=Be[6],br=Be[7],le=be[0],we=be[1],$e=be[2],Oe=be[3],Ge=be[4],st=be[5],xe=be[6],Ee=be[7],Ie=0;oe>=128;){for(wi=0;wi<16;wi++)oi=8*wi+Ie,Ae[wi]=ge[oi+0]<<24|ge[oi+1]<<16|ge[oi+2]<<8|ge[oi+3],qe[wi]=ge[oi+4]<<24|ge[oi+5]<<16|ge[oi+6]<<8|ge[oi+7];for(wi=0;wi<80;wi++)if(bt=Hi,at=or,gt=nr,ei=Gi,ii=Mt,Bi=er,hi=tr,Di=br,ni=le,pi=we,Ii=$e,Ci=Oe,zi=Ge,qi=st,Ai=xe,Oi=Ee,zt=br,Qt=Ee,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=(Mt>>>14|Ge<<18)^(Mt>>>18|Ge<<14)^(Ge>>>9|Mt<<23),Qt=(Ge>>>14|Mt<<18)^(Ge>>>18|Mt<<14)^(Mt>>>9|Ge<<23),Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,zt=Mt&er^~Mt&tr,Qt=Ge&st^~Ge&xe,Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,zt=Ct[wi*2],Qt=Ct[wi*2+1],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,zt=Ae[wi%16],Qt=qe[wi%16],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,ki=ai&65535|gi<<16,Ti=Si&65535|mi<<16,zt=ki,Qt=Ti,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=(Hi>>>28|le<<4)^(le>>>2|Hi<<30)^(le>>>7|Hi<<25),Qt=(le>>>28|Hi<<4)^(Hi>>>2|le<<30)^(Hi>>>7|le<<25),Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,zt=Hi&or^Hi&nr^or&nr,Qt=le&we^le&$e^we&$e,Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Di=ai&65535|gi<<16,Oi=Si&65535|mi<<16,zt=ei,Qt=Ci,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=ki,Qt=Ti,Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,ei=ai&65535|gi<<16,Ci=Si&65535|mi<<16,or=bt,nr=at,Gi=gt,Mt=ei,er=ii,tr=Bi,br=hi,Hi=Di,we=ni,$e=pi,Oe=Ii,Ge=Ci,st=zi,xe=qi,Ee=Ai,le=Oi,wi%16===15)for(oi=0;oi<16;oi++)zt=Ae[oi],Qt=qe[oi],Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Ae[(oi+9)%16],Qt=qe[(oi+9)%16],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,ki=Ae[(oi+1)%16],Ti=qe[(oi+1)%16],zt=(ki>>>1|Ti<<31)^(ki>>>8|Ti<<24)^ki>>>7,Qt=(Ti>>>1|ki<<31)^(Ti>>>8|ki<<24)^(Ti>>>7|ki<<25),Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,ki=Ae[(oi+14)%16],Ti=qe[(oi+14)%16],zt=(ki>>>19|Ti<<13)^(Ti>>>29|ki<<3)^ki>>>6,Qt=(Ti>>>19|ki<<13)^(ki>>>29|Ti<<3)^(Ti>>>6|ki<<26),Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Ae[oi]=ai&65535|gi<<16,qe[oi]=Si&65535|mi<<16;zt=Hi,Qt=le,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Be[0],Qt=be[0],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Be[0]=Hi=ai&65535|gi<<16,be[0]=le=Si&65535|mi<<16,zt=or,Qt=we,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Be[1],Qt=be[1],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Be[1]=or=ai&65535|gi<<16,be[1]=we=Si&65535|mi<<16,zt=nr,Qt=$e,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Be[2],Qt=be[2],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Be[2]=nr=ai&65535|gi<<16,be[2]=$e=Si&65535|mi<<16,zt=Gi,Qt=Oe,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Be[3],Qt=be[3],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Be[3]=Gi=ai&65535|gi<<16,be[3]=Oe=Si&65535|mi<<16,zt=Mt,Qt=Ge,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Be[4],Qt=be[4],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Be[4]=Mt=ai&65535|gi<<16,be[4]=Ge=Si&65535|mi<<16,zt=er,Qt=st,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Be[5],Qt=be[5],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Be[5]=er=ai&65535|gi<<16,be[5]=st=Si&65535|mi<<16,zt=tr,Qt=xe,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Be[6],Qt=be[6],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Be[6]=tr=ai&65535|gi<<16,be[6]=xe=Si&65535|mi<<16,zt=br,Qt=Ee,Si=Qt&65535,mi=Qt>>>16,ai=zt&65535,gi=zt>>>16,zt=Be[7],Qt=be[7],Si+=Qt&65535,mi+=Qt>>>16,ai+=zt&65535,gi+=zt>>>16,mi+=Si>>>16,ai+=mi>>>16,gi+=ai>>>16,Be[7]=br=ai&65535|gi<<16,be[7]=Ee=Si&65535|mi<<16,Ie+=128,oe-=128}return oe}function Je(Be,be,ge){var oe=new Int32Array(8),Ae=new Int32Array(8),qe=new Uint8Array(256),bt,at=ge;for(oe[0]=1779033703,oe[1]=3144134277,oe[2]=1013904242,oe[3]=2773480762,oe[4]=1359893119,oe[5]=2600822924,oe[6]=528734635,oe[7]=1541459225,Ae[0]=4089235720,Ae[1]=2227873595,Ae[2]=4271175723,Ae[3]=1595750129,Ae[4]=2917565137,Ae[5]=725511199,Ae[6]=4215389547,Ae[7]=327033209,nt(oe,Ae,be,ge),ge%=128,bt=0;bt<ge;bt++)qe[bt]=be[at-ge+bt];for(qe[ge]=128,ge=256-128*(ge<112?1:0),qe[ge-9]=0,R(qe,ge-8,at/536870912|0,at<<3),nt(oe,Ae,qe,ge),bt=0;bt<8;bt++)R(Be,8*bt,oe[bt],Ae[bt]);return 0}function tt(Be,be){var ge=n(),oe=n(),Ae=n(),qe=n(),bt=n(),at=n(),gt=n(),ei=n(),ii=n();V(ge,Be[1],Be[0]),V(ii,be[1],be[0]),ee(ge,ge,ii),O(oe,Be[0],Be[1]),O(ii,be[0],be[1]),ee(oe,oe,ii),ee(Ae,Be[3],be[3]),ee(Ae,Ae,k),ee(qe,Be[2],be[2]),O(qe,qe,qe),V(bt,oe,ge),V(at,qe,Ae),O(gt,qe,Ae),O(ei,oe,ge),ee(Be[0],bt,at),ee(Be[1],ei,gt),ee(Be[2],gt,at),ee(Be[3],bt,ei)}function rt(Be,be,ge){var oe;for(oe=0;oe<4;oe++)S(Be[oe],be[oe],ge)}function ht(Be,be){var ge=n(),oe=n(),Ae=n();U(Ae,be[2]),ee(ge,be[0],Ae),ee(oe,be[1],Ae),b(Be,oe),Be[31]^=T(ge)<<7}function Ot(Be,be,ge){var oe,Ae;for(p(Be[0],m),p(Be[1],y),p(Be[2],y),p(Be[3],m),Ae=255;Ae>=0;--Ae)oe=ge[Ae/8|0]>>(Ae&7)&1,rt(Be,be,oe),tt(be,Be),tt(Be,Be),rt(Be,be,oe)}function Ve(Be,be){var ge=[n(),n(),n(),n()];p(ge[0],A),p(ge[1],D),p(ge[2],y),ee(ge[3],A,D),Ot(Be,ge,be)}function We(Be,be,ge){var oe=new Uint8Array(64),Ae=[n(),n(),n(),n()],qe;for(ge||o(be,32),Je(oe,be,32),oe[0]&=248,oe[31]&=127,oe[31]|=64,Ve(Ae,oe),ht(Be,Ae),qe=0;qe<32;qe++)be[qe+32]=Be[qe];return 0}var Gt=new Float64Array([237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16]);function wt(Be,be){var ge,oe,Ae,qe;for(oe=63;oe>=32;--oe){for(ge=0,Ae=oe-32,qe=oe-12;Ae<qe;++Ae)be[Ae]+=ge-16*be[oe]*Gt[Ae-(oe-32)],ge=be[Ae]+128>>8,be[Ae]-=ge*256;be[Ae]+=ge,be[oe]=0}for(ge=0,Ae=0;Ae<32;Ae++)be[Ae]+=ge-(be[31]>>4)*Gt[Ae],ge=be[Ae]>>8,be[Ae]&=255;for(Ae=0;Ae<32;Ae++)be[Ae]-=ge*Gt[Ae];for(oe=0;oe<32;oe++)be[oe+1]+=be[oe]>>8,Be[oe]=be[oe]&255}function Et(Be){var be=new Float64Array(64),ge;for(ge=0;ge<64;ge++)be[ge]=Be[ge];for(ge=0;ge<64;ge++)Be[ge]=0;wt(Be,be)}function Yt(Be,be,ge,oe){var Ae=new Uint8Array(64),qe=new Uint8Array(64),bt=new Uint8Array(64),at,gt,ei=new Float64Array(64),ii=[n(),n(),n(),n()];Je(Ae,oe,32),Ae[0]&=248,Ae[31]&=127,Ae[31]|=64;var Bi=ge+64;for(at=0;at<ge;at++)Be[64+at]=be[at];for(at=0;at<32;at++)Be[32+at]=Ae[32+at];for(Je(bt,Be.subarray(32),ge+32),Et(bt),Ve(ii,bt),ht(Be,ii),at=32;at<64;at++)Be[at]=oe[at];for(Je(qe,Be,ge+64),Et(qe),at=0;at<64;at++)ei[at]=0;for(at=0;at<32;at++)ei[at]=bt[at];for(at=0;at<32;at++)for(gt=0;gt<32;gt++)ei[at+gt]+=qe[at]*Ae[gt];return wt(Be.subarray(32),ei),Bi}function Ce(Be,be){var ge=n(),oe=n(),Ae=n(),qe=n(),bt=n(),at=n(),gt=n();return p(Be[2],y),M(Be[1],be),Z(Ae,Be[1]),ee(qe,Ae,C),V(Ae,Ae,Be[2]),O(qe,Be[2],qe),Z(bt,qe),Z(at,bt),ee(gt,at,bt),ee(ge,gt,Ae),ee(ge,ge,qe),z(ge,ge),ee(ge,ge,Ae),ee(ge,ge,qe),ee(ge,ge,qe),ee(Be[0],ge,qe),Z(oe,Be[0]),ee(oe,oe,qe),h(oe,Ae)&&ee(Be[0],Be[0],P),Z(oe,Be[0]),ee(oe,oe,qe),h(oe,Ae)?-1:(T(Be[0])===be[31]>>7&&V(Be[0],m,Be[0]),ee(Be[3],Be[0],Be[1]),0)}function te(Be,be,ge,oe){var Ae,qe,bt=new Uint8Array(32),at=new Uint8Array(64),gt=[n(),n(),n(),n()],ei=[n(),n(),n(),n()];if(qe=-1,ge<64||Ce(ei,oe))return-1;for(Ae=0;Ae<ge;Ae++)Be[Ae]=be[Ae];for(Ae=0;Ae<32;Ae++)Be[Ae+32]=oe[Ae];if(Je(at,Be,ge),Et(at),Ot(gt,ei,at),Ve(ei,be.subarray(32)),tt(gt,ei),ht(bt,gt),ge-=64,j(be,0,bt,0)){for(Ae=0;Ae<ge;Ae++)Be[Ae]=0;return-1}for(Ae=0;Ae<ge;Ae++)Be[Ae]=be[Ae+64];return qe=ge,qe}var ye=32,Le=24,Ue=32,Qe=16,Ke=32,De=32,Vt=32,At=32,ve=32,Pt=Le,pt=Ue,Ne=Qe,vt=64,ut=32,$t=64,fi=32,kt=64;e.lowlevel={crypto_core_hsalsa20:ie,crypto_stream_xor:ke,crypto_stream:he,crypto_stream_salsa20_xor:Q,crypto_stream_salsa20:ce,crypto_onetimeauth:d,crypto_onetimeauth_verify:v,crypto_verify_16:F,crypto_verify_32:j,crypto_secretbox:w,crypto_secretbox_open:c,crypto_scalarmult:ne,crypto_scalarmult_base:fe,crypto_box_beforenm:de,crypto_box_afternm:je,crypto_box:it,crypto_box_open:ot,crypto_box_keypair:me,crypto_hash:Je,crypto_sign:Yt,crypto_sign_keypair:We,crypto_sign_open:te,crypto_secretbox_KEYBYTES:ye,crypto_secretbox_NONCEBYTES:Le,crypto_secretbox_ZEROBYTES:Ue,crypto_secretbox_BOXZEROBYTES:Qe,crypto_scalarmult_BYTES:Ke,crypto_scalarmult_SCALARBYTES:De,crypto_box_PUBLICKEYBYTES:Vt,crypto_box_SECRETKEYBYTES:At,crypto_box_BEFORENMBYTES:ve,crypto_box_NONCEBYTES:Pt,crypto_box_ZEROBYTES:pt,crypto_box_BOXZEROBYTES:Ne,crypto_sign_BYTES:vt,crypto_sign_PUBLICKEYBYTES:ut,crypto_sign_SECRETKEYBYTES:$t,crypto_sign_SEEDBYTES:fi,crypto_hash_BYTES:kt};function Wt(Be,be){if(Be.length!==ye)throw new Error("bad key size");if(be.length!==Le)throw new Error("bad nonce size")}function Zi(Be,be){if(Be.length!==Vt)throw new Error("bad public key size");if(be.length!==At)throw new Error("bad secret key size")}function Ut(){var Be,be;for(be=0;be<arguments.length;be++)if((Be=Object.prototype.toString.call(arguments[be]))!=="[object Uint8Array]")throw new TypeError("unexpected type "+Be+", use Uint8Array")}function Xt(Be){for(var be=0;be<Be.length;be++)Be[be]=0}e.util||(e.util={},e.util.decodeUTF8=e.util.encodeUTF8=e.util.encodeBase64=e.util.decodeBase64=function(){throw new Error("nacl.util moved into separate package: https://github.com/dchest/tweetnacl-util-js")}),e.randomBytes=function(Be){var be=new Uint8Array(Be);return o(be,Be),be},e.secretbox=function(Be,be,ge){Ut(Be,be,ge),Wt(ge,be);for(var oe=new Uint8Array(Ue+Be.length),Ae=new Uint8Array(oe.length),qe=0;qe<Be.length;qe++)oe[qe+Ue]=Be[qe];return w(Ae,oe,oe.length,be,ge),Ae.subarray(Qe)},e.secretbox.open=function(Be,be,ge){Ut(Be,be,ge),Wt(ge,be);for(var oe=new Uint8Array(Qe+Be.length),Ae=new Uint8Array(oe.length),qe=0;qe<Be.length;qe++)oe[qe+Qe]=Be[qe];return oe.length<32||c(Ae,oe,oe.length,be,ge)!==0?!1:Ae.subarray(Ue)},e.secretbox.keyLength=ye,e.secretbox.nonceLength=Le,e.secretbox.overheadLength=Qe,e.scalarMult=function(Be,be){if(Ut(Be,be),Be.length!==De)throw new Error("bad n size");if(be.length!==Ke)throw new Error("bad p size");var ge=new Uint8Array(Ke);return ne(ge,Be,be),ge},e.scalarMult.base=function(Be){if(Ut(Be),Be.length!==De)throw new Error("bad n size");var be=new Uint8Array(Ke);return fe(be,Be),be},e.scalarMult.scalarLength=De,e.scalarMult.groupElementLength=Ke,e.box=function(Be,be,ge,oe){var Ae=e.box.before(ge,oe);return e.secretbox(Be,be,Ae)},e.box.before=function(Be,be){Ut(Be,be),Zi(Be,be);var ge=new Uint8Array(ve);return de(ge,Be,be),ge},e.box.after=e.secretbox,e.box.open=function(Be,be,ge,oe){var Ae=e.box.before(ge,oe);return e.secretbox.open(Be,be,Ae)},e.box.open.after=e.secretbox.open,e.box.keyPair=function(){var Be=new Uint8Array(Vt),be=new Uint8Array(At);return me(Be,be),{publicKey:Be,secretKey:be}},e.box.keyPair.fromSecretKey=function(Be){if(Ut(Be),Be.length!==At)throw new Error("bad secret key size");var be=new Uint8Array(Vt);return fe(be,Be),{publicKey:be,secretKey:new Uint8Array(Be)}},e.box.publicKeyLength=Vt,e.box.secretKeyLength=At,e.box.sharedKeyLength=ve,e.box.nonceLength=Pt,e.box.overheadLength=e.secretbox.overheadLength,e.sign=function(Be,be){if(Ut(Be,be),be.length!==$t)throw new Error("bad secret key size");var ge=new Uint8Array(vt+Be.length);return Yt(ge,Be,Be.length,be),ge},e.sign.open=function(Be,be){if(arguments.length!==2)throw new Error("nacl.sign.open accepts 2 arguments; did you mean to use nacl.sign.detached.verify?");if(Ut(Be,be),be.length!==ut)throw new Error("bad public key size");var ge=new Uint8Array(Be.length),oe=te(ge,Be,Be.length,be);if(oe<0)return null;for(var Ae=new Uint8Array(oe),qe=0;qe<Ae.length;qe++)Ae[qe]=ge[qe];return Ae},e.sign.detached=function(Be,be){for(var ge=e.sign(Be,be),oe=new Uint8Array(vt),Ae=0;Ae<oe.length;Ae++)oe[Ae]=ge[Ae];return oe},e.sign.detached.verify=function(Be,be,ge){if(Ut(Be,be,ge),be.length!==vt)throw new Error("bad signature size");if(ge.length!==ut)throw new Error("bad public key size");var oe=new Uint8Array(vt+Be.length),Ae=new Uint8Array(vt+Be.length),qe;for(qe=0;qe<vt;qe++)oe[qe]=be[qe];for(qe=0;qe<Be.length;qe++)oe[qe+vt]=Be[qe];return te(Ae,oe,oe.length,ge)>=0},e.sign.keyPair=function(){var Be=new Uint8Array(ut),be=new Uint8Array($t);return We(Be,be),{publicKey:Be,secretKey:be}},e.sign.keyPair.fromSecretKey=function(Be){if(Ut(Be),Be.length!==$t)throw new Error("bad secret key size");for(var be=new Uint8Array(ut),ge=0;ge<be.length;ge++)be[ge]=Be[32+ge];return{publicKey:be,secretKey:new Uint8Array(Be)}},e.sign.keyPair.fromSeed=function(Be){if(Ut(Be),Be.length!==fi)throw new Error("bad seed size");for(var be=new Uint8Array(ut),ge=new Uint8Array($t),oe=0;oe<32;oe++)ge[oe]=Be[oe];return We(be,ge,!0),{publicKey:be,secretKey:ge}},e.sign.publicKeyLength=ut,e.sign.secretKeyLength=$t,e.sign.seedLength=fi,e.sign.signatureLength=vt,e.hash=function(Be){Ut(Be);var be=new Uint8Array(kt);return Je(be,Be,Be.length),be},e.hash.hashLength=kt,e.verify=function(Be,be){return Ut(Be,be),Be.length===0||be.length===0||Be.length!==be.length?!1:B(Be,0,be,0,Be.length)===0},e.setPRNG=function(Be){o=Be},function(){var Be=typeof self<"u"?self.crypto||self.msCrypto:null;if(Be&&Be.getRandomValues){var be=65536;e.setPRNG(function(ge,oe){var Ae,qe=new Uint8Array(oe);for(Ae=0;Ae<oe;Ae+=be)Be.getRandomValues(qe.subarray(Ae,Ae+Math.min(oe-Ae,be)));for(Ae=0;Ae<oe;Ae++)ge[Ae]=qe[Ae];Xt(qe)})}else typeof commonjsRequire<"u"&&(Be=requireCryptoBrowserify(),Be&&Be.randomBytes&&e.setPRNG(function(ge,oe){var Ae,qe=Be.randomBytes(oe);for(Ae=0;Ae<oe;Ae++)ge[Ae]=qe[Ae];Xt(qe)}))}()})(t.exports?t.exports:self.nacl=self.nacl||{})}(naclFast)),naclFast.exports}var utils$2,hasRequiredUtils$2;function requireUtils$2(){if(hasRequiredUtils$2)return utils$2;hasRequiredUtils$2=1,utils$2={bufferSplit:N,addRSAMissing:v,calculateDSAPublic:ke,calculateED25519Public:L,calculateX25519Public:d,mpNormalize:ue,mpDenormalize:Q,ecNormalize:Y,countZeros:j,assertCompatible:D,isCompatible:A,opensslKeyDeriv:B,opensshCipherInfo:c,publicFromPrivateECDSA:w,zeroPadToLength:ce,writeBitString:ie,readBitString:J,pbkdf2:F};var t=requireAssert(),e=requireSafer().Buffer,n=requirePrivateKey(),o=requireKey(),u=requireCryptoBrowserify(),l=requireAlgs(),m=requireLib$4(),y=requireEc(),E=requireJsbn().BigInteger,C=requireNaclFast(),k=3;function A(p,x,S){if(p===null||typeof p!="object")return!1;if(S===void 0&&(S=x.prototype._sshpkApiVersion),p instanceof x&&x.prototype._sshpkApiVersion[0]==S[0])return!0;for(var b=Object.getPrototypeOf(p),h=0;b.constructor.name!==x.name;)if(b=Object.getPrototypeOf(b),!b||++h>k)return!1;if(b.constructor.name!==x.name)return!1;var T=b._sshpkApiVersion;return T===void 0&&(T=x._oldVersionDetect(p)),!(T[0]!=S[0]||T[1]<S[1])}function D(p,x,S,b){if(b===void 0&&(b="object"),t.ok(p,b+" must not be null"),t.object(p,b+" must be an object"),S===void 0&&(S=x.prototype._sshpkApiVersion),!(p instanceof x&&x.prototype._sshpkApiVersion[0]==S[0])){for(var h=Object.getPrototypeOf(p),T=0;h.constructor.name!==x.name;)h=Object.getPrototypeOf(h),t.ok(h&&++T<=k,b+" must be a "+x.name+" instance");t.strictEqual(h.constructor.name,x.name,b+" must be a "+x.name+" instance");var M=h._sshpkApiVersion;M===void 0&&(M=x._oldVersionDetect(p)),t.ok(M[0]==S[0]&&M[1]>=S[1],b+" must be compatible with "+x.name+" klass version "+S[0]+"."+S[1])}}var P={"des-ede3-cbc":{key:24,iv:8},"aes-128-cbc":{key:16,iv:16},"aes-256-cbc":{key:32,iv:16}},R=8;function B(p,x,S,b){t.buffer(x,"salt"),t.buffer(S,"passphrase"),t.number(b,"iteration count");var h=P[p];t.object(h,"supported cipher"),x=x.slice(0,R);for(var T,M,O,V=e.alloc(0);V.length<h.key+h.iv;){O=[],M&&O.push(M),O.push(S),O.push(x),T=e.concat(O);for(var ee=0;ee<b;++ee)T=u.createHash("md5").update(T).digest();V=e.concat([V,T]),M=T}return{key:V.slice(0,h.key),iv:V.slice(h.key,h.key+h.iv)}}function F(p,x,S,b,h){var T=e.alloc(x.length+4);x.copy(T);for(var M=0,O=[],V=1;M<b;){var ee=Z(V++);M+=ee.length,O.push(ee)}return e.concat(O).slice(0,b);function Z(U){T.writeUInt32BE(U,T.length-4);var z=u.createHmac(p,h);z.update(T);for(var ne=z.digest(),fe=ne,me=1;me++<S;){z=u.createHmac(p,h),z.update(fe),fe=z.digest();for(var de=0;de<ne.length;++de)ne[de]^=fe[de]}return ne}}function j(p){for(var x=0,S=8;x<p.length;){var b=1<<S;if((p[x]&b)===b)break;S--,S<0&&(x++,S=8)}return x*8+(8-S)-1}function N(p,x){t.buffer(p),t.string(x);for(var S=[],b=0,h=0,T=0;T<p.length;++T)if(p[T]===x.charCodeAt(h)?++h:p[T]===x.charCodeAt(0)?h=1:h=0,h>=x.length){var M=T+1;S.push(p.slice(b,M-h)),b=M,h=0}return b<=p.length&&S.push(p.slice(b,p.length)),S}function Y(p,x){if(t.buffer(p),p[0]===0&&p[1]===4)return x?p:p.slice(1);if(p[0]===4){if(!x)return p}else{for(;p[0]===0;)p=p.slice(1);if(p[0]===2||p[0]===3)throw new Error("Compressed elliptic curve points are not supported");if(p[0]!==4)throw new Error("Not a valid elliptic curve point");if(!x)return p}var S=e.alloc(p.length+1);return S[0]=0,p.copy(S,1),S}function J(p,x){x===void 0&&(x=m.Ber.BitString);var S=p.readString(x,!0);return t.strictEqual(S[0],0,"bit strings with unused bits are not supported (0x"+S[0].toString(16)+")"),S.slice(1)}function ie(p,x,S){S===void 0&&(S=m.Ber.BitString);var b=e.alloc(x.length+1);b[0]=0,x.copy(b,1),p.writeBuffer(b,S)}function ue(p){for(t.buffer(p);p.length>1&&p[0]===0&&!(p[1]&128);)p=p.slice(1);if((p[0]&128)===128){var x=e.alloc(p.length+1);x[0]=0,p.copy(x,1),p=x}return p}function Q(p){for(t.buffer(p);p.length>1&&p[0]===0;)p=p.slice(1);return p}function ce(p,x){for(t.buffer(p),t.number(x);p.length>x;)t.equal(p[0],0),p=p.slice(1);for(;p.length<x;){var S=e.alloc(p.length+1);S[0]=0,p.copy(S,1),p=S}return p}function he(p){var x=e.from(p.toByteArray());return x=ue(x),x}function ke(p,x,S){t.buffer(p),t.buffer(x),t.buffer(S),p=new E(p),x=new E(x),S=new E(S);var b=p.modPow(S,x),h=he(b);return h}function L(p){t.buffer(p);var x=C.sign.keyPair.fromSeed(new Uint8Array(p));return e.from(x.publicKey)}function d(p){t.buffer(p);var x=C.box.keyPair.fromSeed(new Uint8Array(p));return e.from(x.publicKey)}function v(p){t.object(p),D(p,n,[1,1]);var x=new E(p.part.d.data),S;if(!p.part.dmodp){var b=new E(p.part.p.data),h=x.mod(b.subtract(1));S=he(h),p.part.dmodp={name:"dmodp",data:S},p.parts.push(p.part.dmodp)}if(!p.part.dmodq){var T=new E(p.part.q.data),M=x.mod(T.subtract(1));S=he(M),p.part.dmodq={name:"dmodq",data:S},p.parts.push(p.part.dmodq)}}function w(p,x){t.string(p,"curveName"),t.buffer(x);var S=l.curves[p],b=new E(S.p),h=new E(S.a),T=new E(S.b),M=new y.ECCurveFp(b,h,T),O=M.decodePointHex(S.G.toString("hex")),V=new E(ue(x)),ee=O.multiply(V);ee=e.from(M.encodePointHex(ee),"hex");var Z=[];Z.push({name:"curve",data:e.from(p)}),Z.push({name:"Q",data:ee});var U=new o({type:"ecdsa",curve:M,parts:Z});return U}function c(p){var x={};switch(p){case"3des-cbc":x.keySize=24,x.blockSize=8,x.opensslName="des-ede3-cbc";break;case"blowfish-cbc":x.keySize=16,x.blockSize=8,x.opensslName="bf-cbc";break;case"aes128-cbc":case"aes128-ctr":case"aes128-gcm@openssh.com":x.keySize=16,x.blockSize=16,x.opensslName="aes-128-"+p.slice(7,10);break;case"aes192-cbc":case"aes192-ctr":case"aes192-gcm@openssh.com":x.keySize=24,x.blockSize=16,x.opensslName="aes-192-"+p.slice(7,10);break;case"aes256-cbc":case"aes256-ctr":case"aes256-gcm@openssh.com":x.keySize=32,x.blockSize=16,x.opensslName="aes-256-"+p.slice(7,10);break;default:throw new Error('Unsupported openssl cipher "'+p+'"')}return x}return utils$2}var sshBuffer,hasRequiredSshBuffer;function requireSshBuffer(){if(hasRequiredSshBuffer)return sshBuffer;hasRequiredSshBuffer=1,sshBuffer=n;var t=requireAssert(),e=requireSafer().Buffer;function n(o){t.object(o,"options"),o.buffer!==void 0&&t.buffer(o.buffer,"options.buffer"),this._size=o.buffer?o.buffer.length:1024,this._buffer=o.buffer||e.alloc(this._size),this._offset=0}return n.prototype.toBuffer=function(){return this._buffer.slice(0,this._offset)},n.prototype.atEnd=function(){return this._offset>=this._buffer.length},n.prototype.remainder=function(){return this._buffer.slice(this._offset)},n.prototype.skip=function(o){this._offset+=o},n.prototype.expand=function(){this._size*=2;var o=e.alloc(this._size);this._buffer.copy(o,0),this._buffer=o},n.prototype.readPart=function(){return{data:this.readBuffer()}},n.prototype.readBuffer=function(){var o=this._buffer.readUInt32BE(this._offset);this._offset+=4,t.ok(this._offset+o<=this._buffer.length,"length out of bounds at +0x"+this._offset.toString(16)+" (data truncated?)");var u=this._buffer.slice(this._offset,this._offset+o);return this._offset+=o,u},n.prototype.readString=function(){return this.readBuffer().toString()},n.prototype.readCString=function(){for(var o=this._offset;o<this._buffer.length&&this._buffer[o]!==0;)o++;t.ok(o<this._buffer.length,"c string does not terminate");var u=this._buffer.slice(this._offset,o).toString();return this._offset=o+1,u},n.prototype.readInt=function(){var o=this._buffer.readUInt32BE(this._offset);return this._offset+=4,o},n.prototype.readInt64=function(){t.ok(this._offset+8<this._buffer.length,"buffer not long enough to read Int64");var o=this._buffer.slice(this._offset,this._offset+8);return this._offset+=8,o},n.prototype.readChar=function(){var o=this._buffer[this._offset++];return o},n.prototype.writeBuffer=function(o){for(;this._offset+4+o.length>this._size;)this.expand();this._buffer.writeUInt32BE(o.length,this._offset),this._offset+=4,o.copy(this._buffer,this._offset),this._offset+=o.length},n.prototype.writeString=function(o){this.writeBuffer(e.from(o,"utf8"))},n.prototype.writeCString=function(o){for(;this._offset+1+o.length>this._size;)this.expand();this._buffer.write(o,this._offset),this._offset+=o.length,this._buffer[this._offset++]=0},n.prototype.writeInt=function(o){for(;this._offset+4>this._size;)this.expand();this._buffer.writeUInt32BE(o,this._offset),this._offset+=4},n.prototype.writeInt64=function(o){if(t.buffer(o,"value"),o.length>8){for(var u=o.slice(0,o.length-8),l=0;l<u.length;++l)t.strictEqual(u[l],0,"must fit in 64 bits of precision");o=o.slice(o.length-8,o.length)}for(;this._offset+8>this._size;)this.expand();o.copy(this._buffer,this._offset),this._offset+=8},n.prototype.writeChar=function(o){for(;this._offset+1>this._size;)this.expand();this._buffer[this._offset++]=o},n.prototype.writePart=function(o){this.writeBuffer(o.data)},n.prototype.write=function(o){for(;this._offset+o.length>this._size;)this.expand();o.copy(this._buffer,this._offset),this._offset+=o.length},sshBuffer}var signature,hasRequiredSignature;function requireSignature(){if(hasRequiredSignature)return signature;hasRequiredSignature=1,signature=E;var t=requireAssert(),e=requireSafer().Buffer;requireAlgs(),requireCryptoBrowserify();var n=requireErrors$1(),o=requireUtils$2(),u=requireLib$4(),l=requireSshBuffer(),m=n.InvalidAlgorithmError,y=n.SignatureParseError;function E(P){t.object(P,"options"),t.arrayOfObject(P.parts,"options.parts"),t.string(P.type,"options.type");for(var R={},B=0;B<P.parts.length;++B){var F=P.parts[B];R[F.name]=F}this.type=P.type,this.hashAlgorithm=P.hashAlgo,this.curve=P.curve,this.parts=P.parts,this.part=R}E.prototype.toBuffer=function(P){P===void 0&&(P="asn1"),t.string(P,"format");var R,B="ssh-"+this.type;switch(this.type){case"rsa":switch(this.hashAlgorithm){case"sha256":B="rsa-sha2-256";break;case"sha512":B="rsa-sha2-512";break;case"sha1":case void 0:break;default:throw new Error("SSH signature format does not support hash algorithm "+this.hashAlgorithm)}return P==="ssh"?(R=new l({}),R.writeString(B),R.writePart(this.part.sig),R.toBuffer()):this.part.sig.data;case"ed25519":return P==="ssh"?(R=new l({}),R.writeString(B),R.writePart(this.part.sig),R.toBuffer()):this.part.sig.data;case"dsa":case"ecdsa":var F,j;if(P==="asn1"){var N=new u.BerWriter;return N.startSequence(),F=o.mpNormalize(this.part.r.data),j=o.mpNormalize(this.part.s.data),N.writeBuffer(F,u.Ber.Integer),N.writeBuffer(j,u.Ber.Integer),N.endSequence(),N.buffer}else if(P==="ssh"&&this.type==="dsa"){if(R=new l({}),R.writeString("ssh-dss"),F=this.part.r.data,F.length>20&&F[0]===0&&(F=F.slice(1)),j=this.part.s.data,j.length>20&&j[0]===0&&(j=j.slice(1)),this.hashAlgorithm&&this.hashAlgorithm!=="sha1"||F.length+j.length!==40)throw new Error("OpenSSH only supports DSA signatures with SHA1 hash");return R.writeBuffer(e.concat([F,j])),R.toBuffer()}else if(P==="ssh"&&this.type==="ecdsa"){var Y=new l({});F=this.part.r.data,Y.writeBuffer(F),Y.writePart(this.part.s),R=new l({});var J;F[0]===0&&(F=F.slice(1));var ie=F.length*8;return ie===256?J="nistp256":ie===384?J="nistp384":ie===528&&(J="nistp521"),R.writeString("ecdsa-sha2-"+J),R.writeBuffer(Y.toBuffer()),R.toBuffer()}throw new Error("Invalid signature format");default:throw new Error("Invalid signature data")}},E.prototype.toString=function(P){return t.optionalString(P,"format"),this.toBuffer(P).toString("base64")},E.parse=function(P,R,B){typeof P=="string"&&(P=e.from(P,"base64")),t.buffer(P,"data"),t.string(B,"format"),t.string(R,"type");var F={};F.type=R.toLowerCase(),F.parts=[];try{switch(t.ok(P.length>0,"signature must not be empty"),F.type){case"rsa":return C(P,R,B,F);case"ed25519":return C(P,R,B,F);case"dsa":case"ecdsa":return B==="asn1"?k(P,R,B,F):F.type==="dsa"?A(P,R,B,F):D(P,R,B,F);default:throw new m(R)}}catch(j){throw j instanceof m?j:new y(R,B,j)}};function C(P,R,B,F){if(B==="ssh"){try{var j=new l({buffer:P}),N=j.readString()}catch{}if(j!==void 0){var Y="SSH signature does not match expected type (expected "+R+", got "+N+")";switch(N){case"ssh-rsa":t.strictEqual(R,"rsa",Y),F.hashAlgo="sha1";break;case"rsa-sha2-256":t.strictEqual(R,"rsa",Y),F.hashAlgo="sha256";break;case"rsa-sha2-512":t.strictEqual(R,"rsa",Y),F.hashAlgo="sha512";break;case"ssh-ed25519":t.strictEqual(R,"ed25519",Y),F.hashAlgo="sha512";break;default:throw new Error("Unknown SSH signature type: "+N)}var J=j.readPart();return t.ok(j.atEnd(),"extra trailing bytes"),J.name="sig",F.parts.push(J),new E(F)}}return F.parts.push({name:"sig",data:P}),new E(F)}function k(P,R,B,F){var j=new u.BerReader(P);j.readSequence();var N=j.readString(u.Ber.Integer,!0),Y=j.readString(u.Ber.Integer,!0);return F.parts.push({name:"r",data:o.mpNormalize(N)}),F.parts.push({name:"s",data:o.mpNormalize(Y)}),new E(F)}function A(P,R,B,F){if(P.length!=40){var j=new l({buffer:P}),N=j.readBuffer();N.toString("ascii")==="ssh-dss"&&(N=j.readBuffer()),t.ok(j.atEnd(),"extra trailing bytes"),t.strictEqual(N.length,40,"invalid inner length"),P=N}return F.parts.push({name:"r",data:P.slice(0,20)}),F.parts.push({name:"s",data:P.slice(20,40)}),new E(F)}function D(P,R,B,F){var j=new l({buffer:P}),N,Y,J=j.readBuffer(),ie=J.toString("ascii");if(ie.slice(0,6)==="ecdsa-"){var ue=ie.split("-");switch(t.strictEqual(ue[0],"ecdsa"),t.strictEqual(ue[1],"sha2"),F.curve=ue[2],F.curve){case"nistp256":F.hashAlgo="sha256";break;case"nistp384":F.hashAlgo="sha384";break;case"nistp521":F.hashAlgo="sha512";break;default:throw new Error("Unsupported ECDSA curve: "+F.curve)}J=j.readBuffer(),t.ok(j.atEnd(),"extra trailing bytes on outer"),j=new l({buffer:J}),N=j.readPart()}else N={data:J};return Y=j.readPart(),t.ok(j.atEnd(),"extra trailing bytes"),N.name="r",Y.name="s",F.parts.push(N),F.parts.push(Y),new E(F)}return E.isSignature=function(P,R){return o.isCompatible(P,E,R)},E.prototype._sshpkApiVersion=[2,1],E._oldVersionDetect=function(P){return t.func(P.toBuffer),P.hasOwnProperty("hashAlgorithm")?[2,0]:[1,0]},signature}var eccJsbn={},sec,hasRequiredSec;function requireSec(){if(hasRequiredSec)return sec;hasRequiredSec=1;var t=requireJsbn().BigInteger,e=requireEc().ECCurveFp;function n(B,F,j,N){this.curve=B,this.g=F,this.n=j,this.h=N}function o(){return this.curve}function u(){return this.g}function l(){return this.n}function m(){return this.h}n.prototype.getCurve=o,n.prototype.getG=u,n.prototype.getN=l,n.prototype.getH=m;function y(B){return new t(B,16)}function E(){var B=y("FFFFFFFDFFFFFFFFFFFFFFFFFFFFFFFF"),F=y("FFFFFFFDFFFFFFFFFFFFFFFFFFFFFFFC"),j=y("E87579C11079F43DD824993C2CEE5ED3"),N=y("FFFFFFFE0000000075A30D1B9038A115"),Y=t.ONE,J=new e(B,F,j),ie=J.decodePointHex("04161FF7528B899B2D0C28607CA52C5B86CF5AC8395BAFEB13C02DA292DDED7A83");return new n(J,ie,N,Y)}function C(){var B=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFAC73"),F=t.ZERO,j=y("7"),N=y("0100000000000000000001B8FA16DFAB9ACA16B6B3"),Y=t.ONE,J=new e(B,F,j),ie=J.decodePointHex("043B4C382CE37AA192A4019E763036F4F5DD4D7EBB938CF935318FDCED6BC28286531733C3F03C4FEE");return new n(J,ie,N,Y)}function k(){var B=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFF"),F=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFC"),j=y("1C97BEFC54BD7A8B65ACF89F81D4D4ADC565FA45"),N=y("0100000000000000000001F4C8F927AED3CA752257"),Y=t.ONE,J=new e(B,F,j),ie=J.decodePointHex("044A96B5688EF573284664698968C38BB913CBFC8223A628553168947D59DCC912042351377AC5FB32");return new n(J,ie,N,Y)}function A(){var B=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFEE37"),F=t.ZERO,j=y("3"),N=y("FFFFFFFFFFFFFFFFFFFFFFFE26F2FC170F69466A74DEFD8D"),Y=t.ONE,J=new e(B,F,j),ie=J.decodePointHex("04DB4FF10EC057E9AE26B07D0280B7F4341DA5D1B1EAE06C7D9B2F2F6D9C5628A7844163D015BE86344082AA88D95E2F9D");return new n(J,ie,N,Y)}function D(){var B=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFF"),F=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFC"),j=y("64210519E59C80E70FA7E9AB72243049FEB8DEECC146B9B1"),N=y("FFFFFFFFFFFFFFFFFFFFFFFF99DEF836146BC9B1B4D22831"),Y=t.ONE,J=new e(B,F,j),ie=J.decodePointHex("04188DA80EB03090F67CBF20EB43A18800F4FF0AFD82FF101207192B95FFC8DA78631011ED6B24CDD573F977A11E794811");return new n(J,ie,N,Y)}function P(){var B=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF000000000000000000000001"),F=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFE"),j=y("B4050A850C04B3ABF54132565044B0B7D7BFD8BA270B39432355FFB4"),N=y("FFFFFFFFFFFFFFFFFFFFFFFFFFFF16A2E0B8F03E13DD29455C5C2A3D"),Y=t.ONE,J=new e(B,F,j),ie=J.decodePointHex("04B70E0CBD6BB4BF7F321390B94A03C1D356C21122343280D6115C1D21BD376388B5F723FB4C22DFE6CD4375A05A07476444D5819985007E34");return new n(J,ie,N,Y)}function R(){var B=y("FFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFF"),F=y("FFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFC"),j=y("5AC635D8AA3A93E7B3EBBD55769886BC651D06B0CC53B0F63BCE3C3E27D2604B"),N=y("FFFFFFFF00000000FFFFFFFFFFFFFFFFBCE6FAADA7179E84F3B9CAC2FC632551"),Y=t.ONE,J=new e(B,F,j),ie=J.decodePointHex("046B17D1F2E12C4247F8BCE6E563A440F277037D812DEB33A0F4A13945D898C2964FE342E2FE1A7F9B8EE7EB4A7C0F9E162BCE33576B315ECECBB6406837BF51F5");return new n(J,ie,N,Y)}return sec={secp128r1:E,secp160k1:C,secp160r1:k,secp192k1:A,secp192r1:D,secp224r1:P,secp256r1:R},sec}var hasRequiredEccJsbn;function requireEccJsbn(){if(hasRequiredEccJsbn)return eccJsbn;hasRequiredEccJsbn=1;var t=requireCryptoBrowserify(),e=requireJsbn().BigInteger;requireEc().ECPointFp;var n=requireSafer().Buffer;eccJsbn.ECCurves=requireSec();function o(u,l){return u.length>=l?u:o("0"+u,l)}return eccJsbn.ECKey=function(u,l,m){var y,E=u(),C=E.getN(),k=Math.floor(C.bitLength()/8);if(l)if(m){var u=E.getCurve();this.P=u.decodePointHex(l.toString("hex"))}else{if(l.length!=k)return!1;y=new e(l.toString("hex"),16)}else{var A=C.subtract(e.ONE),D=new e(t.randomBytes(C.bitLength()));y=D.mod(A).add(e.ONE),this.P=E.getG().multiply(y)}this.P&&(this.PublicKey=n.from(E.getCurve().encodeCompressedPointHex(this.P),"hex")),y&&(this.PrivateKey=n.from(o(y.toString(16),k*2),"hex"),this.deriveSharedSecret=function(P){if(!P||!P.P)return!1;var R=P.P.multiply(y);return n.from(o(R.getX().toBigInteger().toString(16),k*2),"hex")})},eccJsbn}var dhe,hasRequiredDhe;function requireDhe(){if(hasRequiredDhe)return dhe;hasRequiredDhe=1,dhe={DiffieHellman:A,generateECDSA:F,generateED25519:B};var t=requireAssert(),e=requireCryptoBrowserify(),n=requireSafer().Buffer,o=requireAlgs(),u=requireUtils$2(),l=requireNaclFast(),m=requireKey(),y=requirePrivateKey(),E=e.createECDH!==void 0;requireEccJsbn();var C=requireEc(),k=requireJsbn().BigInteger;function A(j){if(u.assertCompatible(j,m,[1,4],"key"),this._isPriv=y.isPrivateKey(j,[1,3]),this._algo=j.type,this._curve=j.curve,this._key=j,j.type==="dsa"){if(!E)throw new Error("Due to bugs in the node 0.10 crypto API, node 0.12.x or later is required to use DH");this._dh=e.createDiffieHellman(j.part.p.data,void 0,j.part.g.data,void 0),this._p=j.part.p,this._g=j.part.g,this._isPriv&&this._dh.setPrivateKey(j.part.x.data),this._dh.setPublicKey(j.part.y.data)}else if(j.type==="ecdsa"){if(!E){this._ecParams=new D(this._curve),this._isPriv&&(this._priv=new R(this._ecParams,j.part.d.data));return}var N={nistp256:"prime256v1",nistp384:"secp384r1",nistp521:"secp521r1"}[j.curve];if(this._dh=e.createECDH(N),typeof this._dh!="object"||typeof this._dh.setPrivateKey!="function"){E=!1,A.call(this,j);return}this._isPriv&&this._dh.setPrivateKey(j.part.d.data),this._dh.setPublicKey(j.part.Q.data)}else if(j.type==="curve25519")this._isPriv&&(u.assertCompatible(j,y,[1,5],"key"),this._priv=j.part.k.data);else throw new Error("DH not supported for "+j.type+" keys")}A.prototype.getPublicKey=function(){return this._isPriv?this._key.toPublic():this._key},A.prototype.getPrivateKey=function(){if(this._isPriv)return this._key},A.prototype.getKey=A.prototype.getPrivateKey,A.prototype._keyCheck=function(j,N){if(t.object(j,"key"),N||u.assertCompatible(j,y,[1,3],"key"),u.assertCompatible(j,m,[1,4],"key"),j.type!==this._algo)throw new Error("A "+j.type+" key cannot be used in "+this._algo+" Diffie-Hellman");if(j.curve!==this._curve)throw new Error("A key from the "+j.curve+" curve cannot be used with a "+this._curve+" Diffie-Hellman");j.type==="dsa"&&(t.deepEqual(j.part.p,this._p,"DSA key prime does not match"),t.deepEqual(j.part.g,this._g,"DSA key generator does not match"))},A.prototype.setKey=function(j){if(this._keyCheck(j),j.type==="dsa")this._dh.setPrivateKey(j.part.x.data),this._dh.setPublicKey(j.part.y.data);else if(j.type==="ecdsa")E?(this._dh.setPrivateKey(j.part.d.data),this._dh.setPublicKey(j.part.Q.data)):this._priv=new R(this._ecParams,j.part.d.data);else if(j.type==="curve25519"){var N=j.part.k;j.part.k||(N=j.part.r),this._priv=N.data,this._priv[0]===0&&(this._priv=this._priv.slice(1)),this._priv=this._priv.slice(0,32)}this._key=j,this._isPriv=!0},A.prototype.setPrivateKey=A.prototype.setKey,A.prototype.computeSecret=function(j){if(this._keyCheck(j,!0),!this._isPriv)throw new Error("DH exchange has not been initialized with a private key yet");var N;if(this._algo==="dsa")return this._dh.computeSecret(j.part.y.data);if(this._algo==="ecdsa")return E?this._dh.computeSecret(j.part.Q.data):(N=new P(this._ecParams,j.part.Q.data),this._priv.deriveSharedSecret(N));if(this._algo==="curve25519"){for(N=j.part.A.data;N[0]===0&&N.length>32;)N=N.slice(1);var Y=this._priv;t.strictEqual(N.length,32),t.strictEqual(Y.length,32);var J=l.box.before(new Uint8Array(N),new Uint8Array(Y));return n.from(J)}throw new Error("Invalid algorithm: "+this._algo)},A.prototype.generateKey=function(){var j=[],N,Y;if(this._algo==="dsa")return this._dh.generateKeys(),j.push({name:"p",data:this._p.data}),j.push({name:"q",data:this._key.part.q.data}),j.push({name:"g",data:this._g.data}),j.push({name:"y",data:this._dh.getPublicKey()}),j.push({name:"x",data:this._dh.getPrivateKey()}),this._key=new y({type:"dsa",parts:j}),this._isPriv=!0,this._key;if(this._algo==="ecdsa"){if(E)return this._dh.generateKeys(),j.push({name:"curve",data:n.from(this._curve)}),j.push({name:"Q",data:this._dh.getPublicKey()}),j.push({name:"d",data:this._dh.getPrivateKey()}),this._key=new y({type:"ecdsa",curve:this._curve,parts:j}),this._isPriv=!0,this._key;var J=this._ecParams.getN(),ie=new k(e.randomBytes(J.bitLength())),ue=J.subtract(k.ONE);return N=ie.mod(ue).add(k.ONE),Y=this._ecParams.getG().multiply(N),N=n.from(N.toByteArray()),Y=n.from(this._ecParams.getCurve().encodePointHex(Y),"hex"),this._priv=new R(this._ecParams,N),j.push({name:"curve",data:n.from(this._curve)}),j.push({name:"Q",data:Y}),j.push({name:"d",data:N}),this._key=new y({type:"ecdsa",curve:this._curve,parts:j}),this._isPriv=!0,this._key}else if(this._algo==="curve25519"){var Q=l.box.keyPair();return N=n.from(Q.secretKey),Y=n.from(Q.publicKey),N=n.concat([N,Y]),t.strictEqual(N.length,64),t.strictEqual(Y.length,32),j.push({name:"A",data:Y}),j.push({name:"k",data:N}),this._key=new y({type:"curve25519",parts:j}),this._isPriv=!0,this._key}throw new Error("Invalid algorithm: "+this._algo)},A.prototype.generateKeys=A.prototype.generateKey;function D(j){var N=o.curves[j];t.object(N);var Y=new k(N.p),J=new k(N.a),ie=new k(N.b),ue=new k(N.n),Q=k.ONE,ce=new C.ECCurveFp(Y,J,ie),he=ce.decodePointHex(N.G.toString("hex"));this.curve=ce,this.g=he,this.n=ue,this.h=Q}D.prototype.getCurve=function(){return this.curve},D.prototype.getG=function(){return this.g},D.prototype.getN=function(){return this.n},D.prototype.getH=function(){return this.h};function P(j,N){this._params=j,N[0]===0&&(N=N.slice(1)),this._pub=j.getCurve().decodePointHex(N.toString("hex"))}function R(j,N){this._params=j,this._priv=new k(u.mpNormalize(N))}R.prototype.deriveSharedSecret=function(j){t.ok(j instanceof P);var N=j._pub.multiply(this._priv);return n.from(N.getX().toBigInteger().toByteArray())};function B(){var j=l.sign.keyPair(),N=n.from(j.secretKey),Y=n.from(j.publicKey);t.strictEqual(N.length,64),t.strictEqual(Y.length,32);var J=[];J.push({name:"A",data:Y}),J.push({name:"k",data:N.slice(0,32)});var ie=new y({type:"ed25519",parts:J});return ie}function F(j){var N=[],Y;if(E){var J={nistp256:"prime256v1",nistp384:"secp384r1",nistp521:"secp521r1"}[j],ie=e.createECDH(J);return ie.generateKeys(),N.push({name:"curve",data:n.from(j)}),N.push({name:"Q",data:ie.getPublicKey()}),N.push({name:"d",data:ie.getPrivateKey()}),Y=new y({type:"ecdsa",curve:j,parts:N}),Y}else{var ue=new D(j),Q=ue.getN(),ce=Math.ceil((Q.bitLength()+64)/8),he=new k(e.randomBytes(ce)),ke=Q.subtract(k.ONE),L=he.mod(ke).add(k.ONE),d=ue.getG().multiply(L);return L=n.from(L.toByteArray()),d=n.from(ue.getCurve().encodePointHex(d),"hex"),N.push({name:"curve",data:n.from(j)}),N.push({name:"Q",data:d}),N.push({name:"d",data:L}),Y=new y({type:"ecdsa",curve:j,parts:N}),Y}}return dhe}var edCompat,hasRequiredEdCompat;function requireEdCompat(){if(hasRequiredEdCompat)return edCompat;hasRequiredEdCompat=1,edCompat={Verifier:m,Signer:y};var t=requireNaclFast(),e=requireStreamBrowserify(),n=util$6,o=requireAssert(),u=requireSafer().Buffer,l=requireSignature();function m(E,C){if(C.toLowerCase()!=="sha512")throw new Error("ED25519 only supports the use of SHA-512 hashes");this.key=E,this.chunks=[],e.Writable.call(this,{})}n.inherits(m,e.Writable),m.prototype._write=function(E,C,k){this.chunks.push(E),k()},m.prototype.update=function(E){typeof E=="string"&&(E=u.from(E,"binary")),this.chunks.push(E)},m.prototype.verify=function(E,C){var k;if(l.isSignature(E,[2,0])){if(E.type!=="ed25519")return!1;k=E.toBuffer("raw")}else if(typeof E=="string")k=u.from(E,"base64");else if(l.isSignature(E,[1,0]))throw new Error("signature was created by too old a version of sshpk and cannot be verified");return o.buffer(k),t.sign.detached.verify(new Uint8Array(u.concat(this.chunks)),new Uint8Array(k),new Uint8Array(this.key.part.A.data))};function y(E,C){if(C.toLowerCase()!=="sha512")throw new Error("ED25519 only supports the use of SHA-512 hashes");this.key=E,this.chunks=[],e.Writable.call(this,{})}return n.inherits(y,e.Writable),y.prototype._write=function(E,C,k){this.chunks.push(E),k()},y.prototype.update=function(E){typeof E=="string"&&(E=u.from(E,"binary")),this.chunks.push(E)},y.prototype.sign=function(){var E=t.sign.detached(new Uint8Array(u.concat(this.chunks)),new Uint8Array(u.concat([this.key.part.k.data,this.key.part.A.data]))),C=u.from(E),k=l.parse(C,"ed25519","raw");return k.hashAlgorithm="sha512",k},edCompat}var pkcs8,hasRequiredPkcs8;function requirePkcs8(){if(hasRequiredPkcs8)return pkcs8;hasRequiredPkcs8=1,pkcs8={read:E,readPkcs8:A,write:C,writePkcs8:ce,pkcs8ToBuffer:Q,readECDSACurve:F,writeECDSACurve:v};var t=requireAssert(),e=requireLib$4(),n=requireSafer().Buffer,o=requireAlgs(),u=requireUtils$2(),l=requireKey(),m=requirePrivateKey(),y=requirePem();function E(S,b){return y.read(S,b,"pkcs8")}function C(S,b){return y.write(S,b,"pkcs8")}function k(S,b){return t.strictEqual(S.peek(),e.Ber.Integer,b+" is not an Integer"),u.mpNormalize(S.readString(e.Ber.Integer,!0))}function A(S,b,h){h.peek()===e.Ber.Integer&&(t.strictEqual(b,"private","unexpected Integer at start of public key"),h.readString(e.Ber.Integer,!0)),h.readSequence();var T=h.offset+h.length,M=h.readOID();switch(M){case"1.2.840.113549.1.1.1":return h._offset=T,b==="public"?D(h):P(h);case"1.2.840.10040.4.1":return b==="public"?R(h):B(h);case"1.2.840.10045.2.1":return b==="public"?N(h):j(h);case"1.3.101.112":return b==="public"?Y(h):ie(h);case"1.3.101.110":return b==="public"?J(h):ue(h);default:throw new Error("Unknown key type OID "+M)}}function D(S){S.readSequence(e.Ber.BitString),S.readByte(),S.readSequence();var b=k(S,"modulus"),h=k(S,"exponent"),T={type:"rsa",source:S.originalInput,parts:[{name:"e",data:h},{name:"n",data:b}]};return new l(T)}function P(S){S.readSequence(e.Ber.OctetString),S.readSequence();var b=k(S,"version");t.equal(b[0],0,"unknown RSA private key version");var h=k(S,"modulus"),T=k(S,"public exponent"),M=k(S,"private exponent"),O=k(S,"prime1"),V=k(S,"prime2"),ee=k(S,"exponent1"),Z=k(S,"exponent2"),U=k(S,"iqmp"),z={type:"rsa",parts:[{name:"n",data:h},{name:"e",data:T},{name:"d",data:M},{name:"iqmp",data:U},{name:"p",data:O},{name:"q",data:V},{name:"dmodp",data:ee},{name:"dmodq",data:Z}]};return new m(z)}function R(S){S.readSequence();var b=k(S,"p"),h=k(S,"q"),T=k(S,"g");S.readSequence(e.Ber.BitString),S.readByte();var M=k(S,"y"),O={type:"dsa",parts:[{name:"p",data:b},{name:"q",data:h},{name:"g",data:T},{name:"y",data:M}]};return new l(O)}function B(S){S.readSequence();var b=k(S,"p"),h=k(S,"q"),T=k(S,"g");S.readSequence(e.Ber.OctetString);var M=k(S,"x"),O=u.calculateDSAPublic(T,b,M),V={type:"dsa",parts:[{name:"p",data:b},{name:"q",data:h},{name:"g",data:T},{name:"y",data:O},{name:"x",data:M}]};return new m(V)}function F(S){var b,h,T,M,O;if(S.peek()===e.Ber.OID){var V=S.readOID();for(h=Object.keys(o.curves),T=0;T<h.length;++T)if(M=h[T],O=o.curves[M],O.pkcs8oid===V){b=M;break}}else{S.readSequence();var ee=S.readString(e.Ber.Integer,!0);t.strictEqual(ee[0],1,"ECDSA key not version 1");var Z={};S.readSequence();var U=S.readOID();t.strictEqual(U,"1.2.840.10045.1.1","ECDSA key is not from a prime-field");var z=Z.p=u.mpNormalize(S.readString(e.Ber.Integer,!0));Z.size=z.length*8-u.countZeros(z),S.readSequence(),Z.a=u.mpNormalize(S.readString(e.Ber.OctetString,!0)),Z.b=u.mpNormalize(S.readString(e.Ber.OctetString,!0)),S.peek()===e.Ber.BitString&&(Z.s=S.readString(e.Ber.BitString,!0)),Z.G=S.readString(e.Ber.OctetString,!0),t.strictEqual(Z.G[0],4,"uncompressed G is required"),Z.n=u.mpNormalize(S.readString(e.Ber.Integer,!0)),Z.h=u.mpNormalize(S.readString(e.Ber.Integer,!0)),t.strictEqual(Z.h[0],1,"a cofactor=1 curve is required"),h=Object.keys(o.curves);var ne=Object.keys(Z);for(T=0;T<h.length;++T){M=h[T],O=o.curves[M];for(var fe=!0,me=0;me<ne.length;++me){var de=ne[me];if(O[de]!==void 0){if(typeof O[de]=="object"&&O[de].equals!==void 0){if(!O[de].equals(Z[de])){fe=!1;break}}else if(n.isBuffer(O[de])){if(O[de].toString("binary")!==Z[de].toString("binary")){fe=!1;break}}else if(O[de]!==Z[de]){fe=!1;break}}}if(fe){b=M;break}}}return b}function j(S){var b=F(S);t.string(b,"a known elliptic curve"),S.readSequence(e.Ber.OctetString),S.readSequence();var h=k(S,"version");t.equal(h[0],1,"unknown version of ECDSA key");var T=S.readString(e.Ber.OctetString,!0),M;if(S.peek()==160&&(S.readSequence(160),S._offset+=S.length),S.peek()==161&&(S.readSequence(161),M=S.readString(e.Ber.BitString,!0),M=u.ecNormalize(M)),M===void 0){var O=u.publicFromPrivateECDSA(b,T);M=O.part.Q.data}var V={type:"ecdsa",parts:[{name:"curve",data:n.from(b)},{name:"Q",data:M},{name:"d",data:T}]};return new m(V)}function N(S){var b=F(S);t.string(b,"a known elliptic curve");var h=S.readString(e.Ber.BitString,!0);h=u.ecNormalize(h);var T={type:"ecdsa",parts:[{name:"curve",data:n.from(b)},{name:"Q",data:h}]};return new l(T)}function Y(S){S.peek()===0&&S.readByte();var b=u.readBitString(S),h={type:"ed25519",parts:[{name:"A",data:u.zeroPadToLength(b,32)}]};return new l(h)}function J(S){var b=u.readBitString(S),h={type:"curve25519",parts:[{name:"A",data:u.zeroPadToLength(b,32)}]};return new l(h)}function ie(S){S.peek()===0&&S.readByte(),S.readSequence(e.Ber.OctetString);var b=S.readString(e.Ber.OctetString,!0);b=u.zeroPadToLength(b,32);for(var h,T;(T=S.peek())!==null;)T===(e.Ber.Context|1)?h=u.readBitString(S,T):(S.readSequence(T),S._offset+=S.length);h===void 0&&(h=u.calculateED25519Public(b));var M={type:"ed25519",parts:[{name:"A",data:u.zeroPadToLength(h,32)},{name:"k",data:u.zeroPadToLength(b,32)}]};return new m(M)}function ue(S){S.peek()===0&&S.readByte(),S.readSequence(e.Ber.OctetString);var b=S.readString(e.Ber.OctetString,!0);b=u.zeroPadToLength(b,32);var h=u.calculateX25519Public(b),T={type:"curve25519",parts:[{name:"A",data:u.zeroPadToLength(h,32)},{name:"k",data:u.zeroPadToLength(b,32)}]};return new m(T)}function Q(S){var b=new e.BerWriter;return ce(b,S),b.buffer}function ce(S,b){if(S.startSequence(),m.isPrivateKey(b)){var h=0;b.type==="ed25519"&&(h=1);var T=n.from([h]);S.writeBuffer(T,e.Ber.Integer)}switch(S.startSequence(),b.type){case"rsa":S.writeOID("1.2.840.113549.1.1.1"),m.isPrivateKey(b)?he(b,S):ke(b,S);break;case"dsa":S.writeOID("1.2.840.10040.4.1"),m.isPrivateKey(b)?L(b,S):d(b,S);break;case"ecdsa":S.writeOID("1.2.840.10045.2.1"),m.isPrivateKey(b)?c(b,S):w(b,S);break;case"ed25519":S.writeOID("1.3.101.112"),m.isPrivateKey(b)?x(b,S):p(b,S);break;default:throw new Error("Unsupported key type: "+b.type)}S.endSequence()}function he(S,b){b.writeNull(),b.endSequence(),b.startSequence(e.Ber.OctetString),b.startSequence();var h=n.from([0]);b.writeBuffer(h,e.Ber.Integer),b.writeBuffer(S.part.n.data,e.Ber.Integer),b.writeBuffer(S.part.e.data,e.Ber.Integer),b.writeBuffer(S.part.d.data,e.Ber.Integer),b.writeBuffer(S.part.p.data,e.Ber.Integer),b.writeBuffer(S.part.q.data,e.Ber.Integer),(!S.part.dmodp||!S.part.dmodq)&&u.addRSAMissing(S),b.writeBuffer(S.part.dmodp.data,e.Ber.Integer),b.writeBuffer(S.part.dmodq.data,e.Ber.Integer),b.writeBuffer(S.part.iqmp.data,e.Ber.Integer),b.endSequence(),b.endSequence()}function ke(S,b){b.writeNull(),b.endSequence(),b.startSequence(e.Ber.BitString),b.writeByte(0),b.startSequence(),b.writeBuffer(S.part.n.data,e.Ber.Integer),b.writeBuffer(S.part.e.data,e.Ber.Integer),b.endSequence(),b.endSequence()}function L(S,b){b.startSequence(),b.writeBuffer(S.part.p.data,e.Ber.Integer),b.writeBuffer(S.part.q.data,e.Ber.Integer),b.writeBuffer(S.part.g.data,e.Ber.Integer),b.endSequence(),b.endSequence(),b.startSequence(e.Ber.OctetString),b.writeBuffer(S.part.x.data,e.Ber.Integer),b.endSequence()}function d(S,b){b.startSequence(),b.writeBuffer(S.part.p.data,e.Ber.Integer),b.writeBuffer(S.part.q.data,e.Ber.Integer),b.writeBuffer(S.part.g.data,e.Ber.Integer),b.endSequence(),b.endSequence(),b.startSequence(e.Ber.BitString),b.writeByte(0),b.writeBuffer(S.part.y.data,e.Ber.Integer),b.endSequence()}function v(S,b){var h=o.curves[S.curve];if(h.pkcs8oid)b.writeOID(h.pkcs8oid);else{b.startSequence();var T=n.from([1]);b.writeBuffer(T,e.Ber.Integer),b.startSequence(),b.writeOID("1.2.840.10045.1.1"),b.writeBuffer(h.p,e.Ber.Integer),b.endSequence(),b.startSequence();var M=h.p;M[0]===0&&(M=M.slice(1)),b.writeBuffer(M,e.Ber.OctetString),b.writeBuffer(h.b,e.Ber.OctetString),b.writeBuffer(h.s,e.Ber.BitString),b.endSequence(),b.writeBuffer(h.G,e.Ber.OctetString),b.writeBuffer(h.n,e.Ber.Integer);var O=h.h;O||(O=n.from([1])),b.writeBuffer(O,e.Ber.Integer),b.endSequence()}}function w(S,b){v(S,b),b.endSequence();var h=u.ecNormalize(S.part.Q.data,!0);b.writeBuffer(h,e.Ber.BitString)}function c(S,b){v(S,b),b.endSequence(),b.startSequence(e.Ber.OctetString),b.startSequence();var h=n.from([1]);b.writeBuffer(h,e.Ber.Integer),b.writeBuffer(S.part.d.data,e.Ber.OctetString),b.startSequence(161);var T=u.ecNormalize(S.part.Q.data,!0);b.writeBuffer(T,e.Ber.BitString),b.endSequence(),b.endSequence(),b.endSequence()}function p(S,b){b.endSequence(),u.writeBitString(b,S.part.A.data)}function x(S,b){b.endSequence(),b.startSequence(e.Ber.OctetString);for(var h=u.mpNormalize(S.part.k.data);h.length>32&&h[0]===0;)h=h.slice(1);b.writeBuffer(h,e.Ber.OctetString),b.endSequence(),u.writeBitString(b,S.part.A.data,e.Ber.Context|1)}return pkcs8}var pkcs1,hasRequiredPkcs1;function requirePkcs1(){if(hasRequiredPkcs1)return pkcs1;hasRequiredPkcs1=1,pkcs1={read:k,readPkcs1:P,write:A,writePkcs1:ie};var t=requireAssert(),e=requireLib$4(),n=requireSafer().Buffer,o=requireAlgs(),u=requireUtils$2(),l=requireKey(),m=requirePrivateKey(),y=requirePem(),E=requirePkcs8(),C=E.readECDSACurve;function k(w,c){return y.read(w,c,"pkcs1")}function A(w,c){return y.write(w,c,"pkcs1")}function D(w,c){return t.strictEqual(w.peek(),e.Ber.Integer,c+" is not an Integer"),u.mpNormalize(w.readString(e.Ber.Integer,!0))}function P(w,c,p){switch(w){case"RSA":if(c==="public")return R(p);if(c==="private")return B(p);throw new Error("Unknown key type: "+c);case"DSA":if(c==="public")return N(p);if(c==="private")return F(p);throw new Error("Unknown key type: "+c);case"EC":case"ECDSA":if(c==="private")return J(p);if(c==="public")return Y(p);throw new Error("Unknown key type: "+c);case"EDDSA":case"EdDSA":if(c==="private")return j(p);throw new Error(c+" keys not supported with EdDSA");default:throw new Error("Unknown key algo: "+w)}}function R(w){var c=D(w,"modulus"),p=D(w,"exponent"),x={type:"rsa",parts:[{name:"e",data:p},{name:"n",data:c}]};return new l(x)}function B(w){var c=D(w,"version");t.strictEqual(c[0],0);var p=D(w,"modulus"),x=D(w,"public exponent"),S=D(w,"private exponent"),b=D(w,"prime1"),h=D(w,"prime2"),T=D(w,"exponent1"),M=D(w,"exponent2"),O=D(w,"iqmp"),V={type:"rsa",parts:[{name:"n",data:p},{name:"e",data:x},{name:"d",data:S},{name:"iqmp",data:O},{name:"p",data:b},{name:"q",data:h},{name:"dmodp",data:T},{name:"dmodq",data:M}]};return new m(V)}function F(w){var c=D(w,"version");t.strictEqual(c.readUInt8(0),0);var p=D(w,"p"),x=D(w,"q"),S=D(w,"g"),b=D(w,"y"),h=D(w,"x"),T={type:"dsa",parts:[{name:"p",data:p},{name:"q",data:x},{name:"g",data:S},{name:"y",data:b},{name:"x",data:h}]};return new m(T)}function j(w){var c=D(w,"version");t.strictEqual(c.readUInt8(0),1);var p=w.readString(e.Ber.OctetString,!0);w.readSequence(160);var x=w.readOID();t.strictEqual(x,"1.3.101.112","the ed25519 curve identifier"),w.readSequence(161);var S=u.readBitString(w),b={type:"ed25519",parts:[{name:"A",data:u.zeroPadToLength(S,32)},{name:"k",data:p}]};return new m(b)}function N(w){var c=D(w,"y"),p=D(w,"p"),x=D(w,"q"),S=D(w,"g"),b={type:"dsa",parts:[{name:"y",data:c},{name:"p",data:p},{name:"q",data:x},{name:"g",data:S}]};return new l(b)}function Y(w){w.readSequence();var c=w.readOID();t.strictEqual(c,"1.2.840.10045.2.1","must be ecPublicKey");for(var p=w.readOID(),x,S=Object.keys(o.curves),b=0;b<S.length;++b){var h=S[b],T=o.curves[h];if(T.pkcs8oid===p){x=h;break}}t.string(x,"a known ECDSA named curve");var M=w.readString(e.Ber.BitString,!0);M=u.ecNormalize(M);var O={type:"ecdsa",parts:[{name:"curve",data:n.from(x)},{name:"Q",data:M}]};return new l(O)}function J(w){var c=D(w,"version");t.strictEqual(c.readUInt8(0),1);var p=w.readString(e.Ber.OctetString,!0);w.readSequence(160);var x=C(w);t.string(x,"a known elliptic curve"),w.readSequence(161);var S=w.readString(e.Ber.BitString,!0);S=u.ecNormalize(S);var b={type:"ecdsa",parts:[{name:"curve",data:n.from(x)},{name:"Q",data:S},{name:"d",data:p}]};return new m(b)}function ie(w,c){switch(w.startSequence(),c.type){case"rsa":m.isPrivateKey(c)?Q(w,c):ue(w,c);break;case"dsa":m.isPrivateKey(c)?ce(w,c):he(w,c);break;case"ecdsa":m.isPrivateKey(c)?L(w,c):ke(w,c);break;case"ed25519":m.isPrivateKey(c)?d(w,c):v();break;default:throw new Error("Unknown key algo: "+c.type)}w.endSequence()}function ue(w,c){w.writeBuffer(c.part.n.data,e.Ber.Integer),w.writeBuffer(c.part.e.data,e.Ber.Integer)}function Q(w,c){var p=n.from([0]);w.writeBuffer(p,e.Ber.Integer),w.writeBuffer(c.part.n.data,e.Ber.Integer),w.writeBuffer(c.part.e.data,e.Ber.Integer),w.writeBuffer(c.part.d.data,e.Ber.Integer),w.writeBuffer(c.part.p.data,e.Ber.Integer),w.writeBuffer(c.part.q.data,e.Ber.Integer),(!c.part.dmodp||!c.part.dmodq)&&u.addRSAMissing(c),w.writeBuffer(c.part.dmodp.data,e.Ber.Integer),w.writeBuffer(c.part.dmodq.data,e.Ber.Integer),w.writeBuffer(c.part.iqmp.data,e.Ber.Integer)}function ce(w,c){var p=n.from([0]);w.writeBuffer(p,e.Ber.Integer),w.writeBuffer(c.part.p.data,e.Ber.Integer),w.writeBuffer(c.part.q.data,e.Ber.Integer),w.writeBuffer(c.part.g.data,e.Ber.Integer),w.writeBuffer(c.part.y.data,e.Ber.Integer),w.writeBuffer(c.part.x.data,e.Ber.Integer)}function he(w,c){w.writeBuffer(c.part.y.data,e.Ber.Integer),w.writeBuffer(c.part.p.data,e.Ber.Integer),w.writeBuffer(c.part.q.data,e.Ber.Integer),w.writeBuffer(c.part.g.data,e.Ber.Integer)}function ke(w,c){w.startSequence(),w.writeOID("1.2.840.10045.2.1");var p=c.part.curve.data.toString(),x=o.curves[p].pkcs8oid;t.string(x,"a known ECDSA named curve"),w.writeOID(x),w.endSequence();var S=u.ecNormalize(c.part.Q.data,!0);w.writeBuffer(S,e.Ber.BitString)}function L(w,c){var p=n.from([1]);w.writeBuffer(p,e.Ber.Integer),w.writeBuffer(c.part.d.data,e.Ber.OctetString),w.startSequence(160);var x=c.part.curve.data.toString(),S=o.curves[x].pkcs8oid;t.string(S,"a known ECDSA named curve"),w.writeOID(S),w.endSequence(),w.startSequence(161);var b=u.ecNormalize(c.part.Q.data,!0);w.writeBuffer(b,e.Ber.BitString),w.endSequence()}function d(w,c){var p=n.from([1]);w.writeBuffer(p,e.Ber.Integer),w.writeBuffer(c.part.k.data,e.Ber.OctetString),w.startSequence(160),w.writeOID("1.3.101.112"),w.endSequence(),w.startSequence(161),u.writeBitString(w,c.part.A.data),w.endSequence()}function v(w,c){throw new Error("Public keys are not supported for EdDSA PKCS#1")}return pkcs1}var rfc4253,hasRequiredRfc4253;function requireRfc4253(){if(hasRequiredRfc4253)return rfc4253;hasRequiredRfc4253=1,rfc4253={read:C.bind(void 0,!1,void 0),readType:C.bind(void 0,!1),write:k,readPartial:C.bind(void 0,!0),readInternal:C,keyTypeToAlg:E,algToKeyType:y};var t=requireAssert(),e=requireSafer().Buffer,n=requireAlgs(),o=requireUtils$2(),u=requireKey(),l=requirePrivateKey(),m=requireSshBuffer();function y(A){if(t.string(A),A==="ssh-dss")return"dsa";if(A==="ssh-rsa")return"rsa";if(A==="ssh-ed25519")return"ed25519";if(A==="ssh-curve25519")return"curve25519";if(A.match(/^ecdsa-sha2-/))return"ecdsa";throw new Error("Unknown algorithm "+A)}function E(A){if(t.object(A),A.type==="dsa")return"ssh-dss";if(A.type==="rsa")return"ssh-rsa";if(A.type==="ed25519")return"ssh-ed25519";if(A.type==="curve25519")return"ssh-curve25519";if(A.type==="ecdsa")return"ecdsa-sha2-"+A.part.curve.data.toString();throw new Error("Unknown key type "+A.type)}function C(A,D,P,R){typeof P=="string"&&(P=e.from(P)),t.buffer(P,"buf");var B={},F=B.parts=[],j=new m({buffer:P}),N=j.readString();t.ok(!j.atEnd(),"key must have at least one part"),B.type=y(N);var Y=n.info[B.type].parts.length;for(D&&D==="private"&&(Y=n.privInfo[B.type].parts.length);!j.atEnd()&&F.length<Y;)F.push(j.readPart());for(;!A&&!j.atEnd();)F.push(j.readPart());t.ok(F.length>=1,"key must have at least one part"),t.ok(A||j.atEnd(),"leftover bytes at end of key");var J=u,ie=n.info[B.type];if((D==="private"||ie.parts.length!==F.length)&&(ie=n.privInfo[B.type],J=l),t.strictEqual(ie.parts.length,F.length),B.type==="ecdsa"){var ue=/^ecdsa-sha2-(.+)$/.exec(N);t.ok(ue!==null),t.strictEqual(ue[1],F[0].data.toString())}for(var Q=!0,ce=0;ce<ie.parts.length;++ce){var he=F[ce];if(he.name=ie.parts[ce],B.type==="ed25519"&&he.name==="k"&&(he.data=he.data.slice(0,32)),he.name!=="curve"&&ie.normalize!==!1){var ke;B.type==="ed25519"?ke=o.zeroPadToLength(he.data,32):ke=o.mpNormalize(he.data),ke.toString("binary")!==he.data.toString("binary")&&(he.data=ke,Q=!1)}}return Q&&(B._rfc4253Cache=j.toBuffer()),A&&typeof A=="object"&&(A.remainder=j.remainder(),A.consumed=j._offset),new J(B)}function k(A,D){t.object(A);var P=E(A),R,B=n.info[A.type];l.isPrivateKey(A)&&(B=n.privInfo[A.type]);var F=B.parts,j=new m({});for(j.writeString(P),R=0;R<F.length;++R){var N=A.part[F[R]].data;B.normalize!==!1&&(A.type==="ed25519"?N=o.zeroPadToLength(N,32):N=o.mpNormalize(N)),A.type==="ed25519"&&F[R]==="k"&&(N=e.concat([N,A.part.A.data])),j.writeBuffer(N)}return j.toBuffer()}return rfc4253}var bcryptPbkdf,hasRequiredBcryptPbkdf;function requireBcryptPbkdf(){if(hasRequiredBcryptPbkdf)return bcryptPbkdf;hasRequiredBcryptPbkdf=1;var t=requireNaclFast().lowlevel.crypto_hash,e=0,n=function(){this.S=[new Uint32Array([3509652390,2564797868,805139163,3491422135,3101798381,1780907670,3128725573,4046225305,614570311,3012652279,134345442,2240740374,1667834072,1901547113,2757295779,4103290238,227898511,1921955416,1904987480,2182433518,2069144605,3260701109,2620446009,720527379,3318853667,677414384,3393288472,3101374703,2390351024,1614419982,1822297739,2954791486,3608508353,3174124327,2024746970,1432378464,3864339955,2857741204,1464375394,1676153920,1439316330,715854006,3033291828,289532110,2706671279,2087905683,3018724369,1668267050,732546397,1947742710,3462151702,2609353502,2950085171,1814351708,2050118529,680887927,999245976,1800124847,3300911131,1713906067,1641548236,4213287313,1216130144,1575780402,4018429277,3917837745,3693486850,3949271944,596196993,3549867205,258830323,2213823033,772490370,2760122372,1774776394,2652871518,566650946,4142492826,1728879713,2882767088,1783734482,3629395816,2517608232,2874225571,1861159788,326777828,3124490320,2130389656,2716951837,967770486,1724537150,2185432712,2364442137,1164943284,2105845187,998989502,3765401048,2244026483,1075463327,1455516326,1322494562,910128902,469688178,1117454909,936433444,3490320968,3675253459,1240580251,122909385,2157517691,634681816,4142456567,3825094682,3061402683,2540495037,79693498,3249098678,1084186820,1583128258,426386531,1761308591,1047286709,322548459,995290223,1845252383,2603652396,3431023940,2942221577,3202600964,3727903485,1712269319,422464435,3234572375,1170764815,3523960633,3117677531,1434042557,442511882,3600875718,1076654713,1738483198,4213154764,2393238008,3677496056,1014306527,4251020053,793779912,2902807211,842905082,4246964064,1395751752,1040244610,2656851899,3396308128,445077038,3742853595,3577915638,679411651,2892444358,2354009459,1767581616,3150600392,3791627101,3102740896,284835224,4246832056,1258075500,768725851,2589189241,3069724005,3532540348,1274779536,3789419226,2764799539,1660621633,3471099624,4011903706,913787905,3497959166,737222580,2514213453,2928710040,3937242737,1804850592,3499020752,2949064160,2386320175,2390070455,2415321851,4061277028,2290661394,2416832540,1336762016,1754252060,3520065937,3014181293,791618072,3188594551,3933548030,2332172193,3852520463,3043980520,413987798,3465142937,3030929376,4245938359,2093235073,3534596313,375366246,2157278981,2479649556,555357303,3870105701,2008414854,3344188149,4221384143,3956125452,2067696032,3594591187,2921233993,2428461,544322398,577241275,1471733935,610547355,4027169054,1432588573,1507829418,2025931657,3646575487,545086370,48609733,2200306550,1653985193,298326376,1316178497,3007786442,2064951626,458293330,2589141269,3591329599,3164325604,727753846,2179363840,146436021,1461446943,4069977195,705550613,3059967265,3887724982,4281599278,3313849956,1404054877,2845806497,146425753,1854211946]),new Uint32Array([1266315497,3048417604,3681880366,3289982499,290971e4,1235738493,2632868024,2414719590,3970600049,1771706367,1449415276,3266420449,422970021,1963543593,2690192192,3826793022,1062508698,1531092325,1804592342,2583117782,2714934279,4024971509,1294809318,4028980673,1289560198,2221992742,1669523910,35572830,157838143,1052438473,1016535060,1802137761,1753167236,1386275462,3080475397,2857371447,1040679964,2145300060,2390574316,1461121720,2956646967,4031777805,4028374788,33600511,2920084762,1018524850,629373528,3691585981,3515945977,2091462646,2486323059,586499841,988145025,935516892,3367335476,2599673255,2839830854,265290510,3972581182,2759138881,3795373465,1005194799,847297441,406762289,1314163512,1332590856,1866599683,4127851711,750260880,613907577,1450815602,3165620655,3734664991,3650291728,3012275730,3704569646,1427272223,778793252,1343938022,2676280711,2052605720,1946737175,3164576444,3914038668,3967478842,3682934266,1661551462,3294938066,4011595847,840292616,3712170807,616741398,312560963,711312465,1351876610,322626781,1910503582,271666773,2175563734,1594956187,70604529,3617834859,1007753275,1495573769,4069517037,2549218298,2663038764,504708206,2263041392,3941167025,2249088522,1514023603,1998579484,1312622330,694541497,2582060303,2151582166,1382467621,776784248,2618340202,3323268794,2497899128,2784771155,503983604,4076293799,907881277,423175695,432175456,1378068232,4145222326,3954048622,3938656102,3820766613,2793130115,2977904593,26017576,3274890735,3194772133,1700274565,1756076034,4006520079,3677328699,720338349,1533947780,354530856,688349552,3973924725,1637815568,332179504,3949051286,53804574,2852348879,3044236432,1282449977,3583942155,3416972820,4006381244,1617046695,2628476075,3002303598,1686838959,431878346,2686675385,1700445008,1080580658,1009431731,832498133,3223435511,2605976345,2271191193,2516031870,1648197032,4164389018,2548247927,300782431,375919233,238389289,3353747414,2531188641,2019080857,1475708069,455242339,2609103871,448939670,3451063019,1395535956,2413381860,1841049896,1491858159,885456874,4264095073,4001119347,1565136089,3898914787,1108368660,540939232,1173283510,2745871338,3681308437,4207628240,3343053890,4016749493,1699691293,1103962373,3625875870,2256883143,3830138730,1031889488,3479347698,1535977030,4236805024,3251091107,2132092099,1774941330,1199868427,1452454533,157007616,2904115357,342012276,595725824,1480756522,206960106,497939518,591360097,863170706,2375253569,3596610801,1814182875,2094937945,3421402208,1082520231,3463918190,2785509508,435703966,3908032597,1641649973,2842273706,3305899714,1510255612,2148256476,2655287854,3276092548,4258621189,236887753,3681803219,274041037,1734335097,3815195456,3317970021,1899903192,1026095262,4050517792,356393447,2410691914,3873677099,3682840055]),new Uint32Array([3913112168,2491498743,4132185628,2489919796,1091903735,1979897079,3170134830,3567386728,3557303409,857797738,1136121015,1342202287,507115054,2535736646,337727348,3213592640,1301675037,2528481711,1895095763,1721773893,3216771564,62756741,2142006736,835421444,2531993523,1442658625,3659876326,2882144922,676362277,1392781812,170690266,3921047035,1759253602,3611846912,1745797284,664899054,1329594018,3901205900,3045908486,2062866102,2865634940,3543621612,3464012697,1080764994,553557557,3656615353,3996768171,991055499,499776247,1265440854,648242737,3940784050,980351604,3713745714,1749149687,3396870395,4211799374,3640570775,1161844396,3125318951,1431517754,545492359,4268468663,3499529547,1437099964,2702547544,3433638243,2581715763,2787789398,1060185593,1593081372,2418618748,4260947970,69676912,2159744348,86519011,2512459080,3838209314,1220612927,3339683548,133810670,1090789135,1078426020,1569222167,845107691,3583754449,4072456591,1091646820,628848692,1613405280,3757631651,526609435,236106946,48312990,2942717905,3402727701,1797494240,859738849,992217954,4005476642,2243076622,3870952857,3732016268,765654824,3490871365,2511836413,1685915746,3888969200,1414112111,2273134842,3281911079,4080962846,172450625,2569994100,980381355,4109958455,2819808352,2716589560,2568741196,3681446669,3329971472,1835478071,660984891,3704678404,4045999559,3422617507,3040415634,1762651403,1719377915,3470491036,2693910283,3642056355,3138596744,1364962596,2073328063,1983633131,926494387,3423689081,2150032023,4096667949,1749200295,3328846651,309677260,2016342300,1779581495,3079819751,111262694,1274766160,443224088,298511866,1025883608,3806446537,1145181785,168956806,3641502830,3584813610,1689216846,3666258015,3200248200,1692713982,2646376535,4042768518,1618508792,1610833997,3523052358,4130873264,2001055236,3610705100,2202168115,4028541809,2961195399,1006657119,2006996926,3186142756,1430667929,3210227297,1314452623,4074634658,4101304120,2273951170,1399257539,3367210612,3027628629,1190975929,2062231137,2333990788,2221543033,2438960610,1181637006,548689776,2362791313,3372408396,3104550113,3145860560,296247880,1970579870,3078560182,3769228297,1714227617,3291629107,3898220290,166772364,1251581989,493813264,448347421,195405023,2709975567,677966185,3703036547,1463355134,2715995803,1338867538,1343315457,2802222074,2684532164,233230375,2599980071,2000651841,3277868038,1638401717,4028070440,3237316320,6314154,819756386,300326615,590932579,1405279636,3267499572,3150704214,2428286686,3959192993,3461946742,1862657033,1266418056,963775037,2089974820,2263052895,1917689273,448879540,3550394620,3981727096,150775221,3627908307,1303187396,508620638,2975983352,2726630617,1817252668,1876281319,1457606340,908771278,3720792119,3617206836,2455994898,1729034894,1080033504]),new Uint32Array([976866871,3556439503,2881648439,1522871579,1555064734,1336096578,3548522304,2579274686,3574697629,3205460757,3593280638,3338716283,3079412587,564236357,2993598910,1781952180,1464380207,3163844217,3332601554,1699332808,1393555694,1183702653,3581086237,1288719814,691649499,2847557200,2895455976,3193889540,2717570544,1781354906,1676643554,2592534050,3230253752,1126444790,2770207658,2633158820,2210423226,2615765581,2414155088,3127139286,673620729,2805611233,1269405062,4015350505,3341807571,4149409754,1057255273,2012875353,2162469141,2276492801,2601117357,993977747,3918593370,2654263191,753973209,36408145,2530585658,25011837,3520020182,2088578344,530523599,2918365339,1524020338,1518925132,3760827505,3759777254,1202760957,3985898139,3906192525,674977740,4174734889,2031300136,2019492241,3983892565,4153806404,3822280332,352677332,2297720250,60907813,90501309,3286998549,1016092578,2535922412,2839152426,457141659,509813237,4120667899,652014361,1966332200,2975202805,55981186,2327461051,676427537,3255491064,2882294119,3433927263,1307055953,942726286,933058658,2468411793,3933900994,4215176142,1361170020,2001714738,2830558078,3274259782,1222529897,1679025792,2729314320,3714953764,1770335741,151462246,3013232138,1682292957,1483529935,471910574,1539241949,458788160,3436315007,1807016891,3718408830,978976581,1043663428,3165965781,1927990952,4200891579,2372276910,3208408903,3533431907,1412390302,2931980059,4132332400,1947078029,3881505623,4168226417,2941484381,1077988104,1320477388,886195818,18198404,3786409e3,2509781533,112762804,3463356488,1866414978,891333506,18488651,661792760,1628790961,3885187036,3141171499,876946877,2693282273,1372485963,791857591,2686433993,3759982718,3167212022,3472953795,2716379847,445679433,3561995674,3504004811,3574258232,54117162,3331405415,2381918588,3769707343,4154350007,1140177722,4074052095,668550556,3214352940,367459370,261225585,2610173221,4209349473,3468074219,3265815641,314222801,3066103646,3808782860,282218597,3406013506,3773591054,379116347,1285071038,846784868,2669647154,3771962079,3550491691,2305946142,453669953,1268987020,3317592352,3279303384,3744833421,2610507566,3859509063,266596637,3847019092,517658769,3462560207,3443424879,370717030,4247526661,2224018117,4143653529,4112773975,2788324899,2477274417,1456262402,2901442914,1517677493,1846949527,2295493580,3734397586,2176403920,1280348187,1908823572,3871786941,846861322,1172426758,3287448474,3383383037,1655181056,3139813346,901632758,1897031941,2986607138,3066810236,3447102507,1393639104,373351379,950779232,625454576,3124240540,4148612726,2007998917,544563296,2244738638,2330496472,2058025392,1291430526,424198748,50039436,29584100,3605783033,2429876329,2791104160,1057563949,3255363231,3075367218,3463963227,1469046755,985887462])],this.P=new Uint32Array([608135816,2242054355,320440878,57701188,2752067618,698298832,137296536,3964562569,1160258022,953160567,3193202383,887688300,3232508343,3380367581,1065670069,3041331479,2450970073,2306472731])};function o(C,k,A){return(C[0][k[A+3]]+C[1][k[A+2]]^C[2][k[A+1]])+C[3][k[A]]}n.prototype.encipher=function(C,k){k===void 0&&(k=new Uint8Array(C.buffer),C.byteOffset!==0&&(k=k.subarray(C.byteOffset))),C[0]^=this.P[0];for(var A=1;A<16;A+=2)C[1]^=o(this.S,k,0)^this.P[A],C[0]^=o(this.S,k,4)^this.P[A+1];var D=C[0];C[0]=C[1]^this.P[17],C[1]=D},n.prototype.decipher=function(C){var k=new Uint8Array(C.buffer);C.byteOffset!==0&&(k=k.subarray(C.byteOffset)),C[0]^=this.P[17];for(var A=16;A>0;A-=2)C[1]^=o(this.S,k,0)^this.P[A],C[0]^=o(this.S,k,4)^this.P[A-1];var D=C[0];C[0]=C[1]^this.P[0],C[1]=D};function u(C,k){var A,D=0;for(A=0;A<4;A++,e++)e>=k&&(e=0),D=D<<8|C[e];return D}n.prototype.expand0state=function(C,k){var A=new Uint32Array(2),D,P,R=new Uint8Array(A.buffer);for(D=0,e=0;D<18;D++)this.P[D]^=u(C,k);for(e=0,D=0;D<18;D+=2)this.encipher(A,R),this.P[D]=A[0],this.P[D+1]=A[1];for(D=0;D<4;D++)for(P=0;P<256;P+=2)this.encipher(A,R),this.S[D][P]=A[0],this.S[D][P+1]=A[1]},n.prototype.expandstate=function(C,k,A,D){var P=new Uint32Array(2),R,B;for(R=0,e=0;R<18;R++)this.P[R]^=u(A,D);for(R=0,e=0;R<18;R+=2)P[0]^=u(C,k),P[1]^=u(C,k),this.encipher(P),this.P[R]=P[0],this.P[R+1]=P[1];for(R=0;R<4;R++)for(B=0;B<256;B+=2)P[0]^=u(C,k),P[1]^=u(C,k),this.encipher(P),this.S[R][B]=P[0],this.S[R][B+1]=P[1];e=0},n.prototype.enc=function(C,k){for(var A=0;A<k;A++)this.encipher(C.subarray(A*2))},n.prototype.dec=function(C,k){for(var A=0;A<k;A++)this.decipher(C.subarray(A*2))};var l=8,m=32;function y(C,k,A){var D=new n,P=new Uint32Array(l),R,B=new Uint8Array([79,120,121,99,104,114,111,109,97,116,105,99,66,108,111,119,102,105,115,104,83,119,97,116,68,121,110,97,109,105,116,101]);for(D.expandstate(k,64,C,64),R=0;R<64;R++)D.expand0state(k,64),D.expand0state(C,64);for(R=0;R<l;R++)P[R]=u(B,B.byteLength);for(R=0;R<64;R++)D.enc(P,P.byteLength/8);for(R=0;R<l;R++)A[4*R+3]=P[R]>>>24,A[4*R+2]=P[R]>>>16,A[4*R+1]=P[R]>>>8,A[4*R+0]=P[R]}function E(C,k,A,D,P,R,B){var F=new Uint8Array(64),j=new Uint8Array(64),N=new Uint8Array(m),Y=new Uint8Array(m),J=new Uint8Array(D+4),ie,ue,Q,ce,he,ke,L=R;if(B<1||k===0||D===0||R===0||R>N.byteLength*N.byteLength||D>1<<20)return-1;for(ce=Math.floor((R+N.byteLength-1)/N.byteLength),Q=Math.floor((R+ce-1)/ce),ie=0;ie<D;ie++)J[ie]=A[ie];for(t(F,C,k),ke=1;R>0;ke++){for(J[D+0]=ke>>>24,J[D+1]=ke>>>16,J[D+2]=ke>>>8,J[D+3]=ke,t(j,J,D+4),y(F,j,Y),ie=N.byteLength;ie--;)N[ie]=Y[ie];for(ie=1;ie<B;ie++)for(t(j,Y,Y.byteLength),y(F,j,Y),ue=0;ue<N.byteLength;ue++)N[ue]^=Y[ue];for(Q=Math.min(Q,R),ie=0;ie<Q&&(he=ie*ce+(ke-1),!(he>=L));ie++)P[he]=N[ie];R-=ie}return 0}return bcryptPbkdf={BLOCKS:l,HASHSIZE:m,hash:y,pbkdf:E},bcryptPbkdf}var sshPrivate,hasRequiredSshPrivate;function requireSshPrivate(){if(hasRequiredSshPrivate)return sshPrivate;hasRequiredSshPrivate=1,sshPrivate={read:k,readSSHPrivate:D,write:P};var t=requireAssert();requireLib$4();var e=requireSafer().Buffer;requireAlgs();var n=requireUtils$2(),o=requireCryptoBrowserify();requireKey();var u=requirePrivateKey(),l=requirePem(),m=requireRfc4253(),y=requireSshBuffer(),E=requireErrors$1(),C;function k(R,B){return l.read(R,B)}var A="openssh-key-v1";function D(R,B,F){B=new y({buffer:B});var j=B.readCString();t.strictEqual(j,A,"bad magic string");var N=B.readString(),Y=B.readString(),J=B.readBuffer(),ie=B.readInt();if(ie!==1)throw new Error("OpenSSH-format key file contains multiple keys: this is unsupported.");var ue=B.readBuffer();if(R==="public")return t.ok(B.atEnd(),"excess bytes left after key"),m.read(ue);var Q=B.readBuffer();t.ok(B.atEnd(),"excess bytes left after key");var ce=new y({buffer:J});switch(Y){case"none":if(N!=="none")throw new Error('OpenSSH-format key uses KDF "none" but specifies a cipher other than "none"');break;case"bcrypt":var he=ce.readBuffer(),ke=ce.readInt(),L=n.opensshCipherInfo(N);if(C===void 0&&(C=requireBcryptPbkdf()),typeof F.passphrase=="string"&&(F.passphrase=e.from(F.passphrase,"utf-8")),!e.isBuffer(F.passphrase))throw new E.KeyEncryptedError(F.filename,"OpenSSH");var d=new Uint8Array(F.passphrase),v=new Uint8Array(he),w=new Uint8Array(L.keySize+L.blockSize),c=C.pbkdf(d,d.length,v,v.length,w,w.length,ke);if(c!==0)throw new Error("bcrypt_pbkdf function returned failure, parameters invalid");w=e.from(w);var p=w.slice(0,L.keySize),x=w.slice(L.keySize,L.keySize+L.blockSize),S=o.createDecipheriv(L.opensslName,p,x);S.setAutoPadding(!1);var b,h=[];for(S.once("error",function(Z){throw Z.toString().indexOf("bad decrypt")!==-1?new Error("Incorrect passphrase supplied, could not decrypt key"):Z}),S.write(Q),S.end();(b=S.read())!==null;)h.push(b);Q=e.concat(h);break;default:throw new Error('OpenSSH-format key uses unknown KDF "'+Y+'"')}B=new y({buffer:Q});var T=B.readInt(),M=B.readInt();if(T!==M)throw new Error("Incorrect passphrase supplied, could not decrypt key");var O={},V=m.readInternal(O,"private",B.remainder());B.skip(O.consumed);var ee=B.readString();return V.comment=ee,V}function P(R,B){var F;u.isPrivateKey(R)?F=R.toPublic():F=R;var j="none",N="none",Y=e.alloc(0),J={blockSize:8},ie;B!==void 0&&(ie=B.passphrase,typeof ie=="string"&&(ie=e.from(ie,"utf-8")),ie!==void 0&&(t.buffer(ie,"options.passphrase"),t.optionalString(B.cipher,"options.cipher"),j=B.cipher,j===void 0&&(j="aes128-ctr"),J=n.opensshCipherInfo(j),N="bcrypt"));var ue;if(u.isPrivateKey(R)){ue=new y({});var Q=o.randomBytes(4).readUInt32BE(0);ue.writeInt(Q),ue.writeInt(Q),ue.write(R.toBuffer("rfc4253")),ue.writeString(R.comment||"");for(var ce=1;ue._offset%J.blockSize!==0;)ue.writeChar(ce++);ue=ue.toBuffer()}switch(N){case"none":break;case"bcrypt":var he=o.randomBytes(16),ke=16,L=new y({});L.writeBuffer(he),L.writeInt(ke),Y=L.toBuffer(),C===void 0&&(C=requireBcryptPbkdf());var d=new Uint8Array(ie),v=new Uint8Array(he),w=new Uint8Array(J.keySize+J.blockSize),c=C.pbkdf(d,d.length,v,v.length,w,w.length,ke);if(c!==0)throw new Error("bcrypt_pbkdf function returned failure, parameters invalid");w=e.from(w);var p=w.slice(0,J.keySize),x=w.slice(J.keySize,J.keySize+J.blockSize),S=o.createCipheriv(J.opensslName,p,x);S.setAutoPadding(!1);var b,h=[];for(S.once("error",function(z){throw z}),S.write(ue),S.end();(b=S.read())!==null;)h.push(b);ue=e.concat(h);break;default:throw new Error("Unsupported kdf "+N)}var T=new y({});T.writeCString(A),T.writeString(j),T.writeString(N),T.writeBuffer(Y),T.writeInt(1),T.writeBuffer(F.toBuffer("rfc4253")),ue&&T.writeBuffer(ue),T=T.toBuffer();var M;u.isPrivateKey(R)?M="OPENSSH PRIVATE KEY":M="OPENSSH PUBLIC KEY";var O=T.toString("base64"),V=O.length+O.length/70+18+16+M.length*2+10;T=e.alloc(V);var ee=0;ee+=T.write("-----BEGIN "+M+`-----
`,ee);for(var Z=0;Z<O.length;){var U=Z+70;U>O.length&&(U=O.length),ee+=T.write(O.slice(Z,U),ee),T[ee++]=10,Z=U}return ee+=T.write("-----END "+M+`-----
`,ee),T.slice(0,ee)}return sshPrivate}var pem,hasRequiredPem;function requirePem(){if(hasRequiredPem)return pem;hasRequiredPem=1,pem={read:F,write:j};var t=requireAssert(),e=requireLib$4(),n=requireCryptoBrowserify(),o=requireSafer().Buffer;requireAlgs();var u=requireUtils$2(),l=requireKey(),m=requirePrivateKey(),y=requirePkcs1(),E=requirePkcs8(),C=requireSshPrivate(),k=requireRfc4253(),A=requireErrors$1(),D="1.2.840.113549.1.5.13",P="1.2.840.113549.1.5.12",R={"1.2.840.113549.3.7":"3des-cbc","2.16.840.1.101.3.4.1.2":"aes128-cbc","2.16.840.1.101.3.4.1.42":"aes256-cbc"};Object.keys(R).forEach(function(N){});var B={"1.2.840.113549.2.7":"sha1","1.2.840.113549.2.9":"sha256","1.2.840.113549.2.11":"sha512"};Object.keys(B).forEach(function(N){});function F(N,Y,J){var ie=N;typeof N!="string"&&(t.buffer(N,"buf"),N=N.toString("ascii"));for(var ue=N.trim().split(/[\r\n]+/g),Q,ce=-1;!Q&&ce<ue.length;)Q=ue[++ce].match(/[-]+[ ]*BEGIN ([A-Z0-9][A-Za-z0-9]+ )?(PUBLIC|PRIVATE) KEY[ ]*[-]+/);t.ok(Q,"invalid PEM header");for(var he,ke=ue.length;!he&&ke>0;)he=ue[--ke].match(/[-]+[ ]*END ([A-Z0-9][A-Za-z0-9]+ )?(PUBLIC|PRIVATE) KEY[ ]*[-]+/);t.ok(he,"invalid PEM footer"),t.equal(Q[2],he[2]);var L=Q[2].toLowerCase(),d;Q[1]&&(t.equal(Q[1],he[1],"PEM header and footer mismatch"),d=Q[1].trim()),ue=ue.slice(ce,ke+1);for(var v={};ue=ue.slice(1),Q=ue[0].match(/^([A-Za-z0-9-]+): (.+)$/),!!Q;)v[Q[1].toLowerCase()]=Q[2];ue=ue.slice(0,-1).join(""),N=o.from(ue,"base64");var w,c,p;if(v["proc-type"]){var x=v["proc-type"].split(",");if(x[0]==="4"&&x[1]==="ENCRYPTED")if(typeof Y.passphrase=="string"&&(Y.passphrase=o.from(Y.passphrase,"utf-8")),o.isBuffer(Y.passphrase))x=v["dek-info"].split(","),t.ok(x.length===2),w=x[0].toLowerCase(),p=o.from(x[1],"hex"),c=u.opensslKeyDeriv(w,p,Y.passphrase,1).key;else throw new A.KeyEncryptedError(Y.filename,"PEM")}if(d&&d.toLowerCase()==="encrypted"){var S=new e.BerReader(N),b;S.readSequence(),S.readSequence(),b=S.offset+S.length;var h=S.readOID();if(h!==D)throw new Error("Unsupported PEM/PKCS8 encryption scheme: "+h);S.readSequence(),S.readSequence();var T=S.offset+S.length,M=S.readOID();if(M!==P)throw new Error("Unsupported PBES2 KDF: "+M);S.readSequence();var O=S.readString(e.Ber.OctetString,!0),V=S.readInt(),ee="sha1";if(S.offset<T){S.readSequence();var Z=S.readOID();if(ee=B[Z],ee===void 0)throw new Error("Unsupported PBKDF2 hash: "+Z)}S._offset=T,S.readSequence();var U=S.readOID();if(w=R[U],w===void 0)throw new Error("Unsupported PBES2 cipher: "+U);if(p=S.readString(e.Ber.OctetString,!0),S._offset=b,N=S.readString(e.Ber.OctetString,!0),typeof Y.passphrase=="string"&&(Y.passphrase=o.from(Y.passphrase,"utf-8")),!o.isBuffer(Y.passphrase))throw new A.KeyEncryptedError(Y.filename,"PEM");var z=u.opensshCipherInfo(w);w=z.opensslName,c=u.pbkdf2(ee,O,V,z.keySize,Y.passphrase),d=void 0}if(w&&c&&p){var ne=n.createDecipheriv(w,c,p),fe,me=[];for(ne.once("error",function(je){throw je.toString().indexOf("bad decrypt")!==-1?new Error("Incorrect passphrase supplied, could not decrypt key"):je}),ne.write(N),ne.end();(fe=ne.read())!==null;)me.push(fe);N=o.concat(me)}if(d&&d.toLowerCase()==="openssh")return C.readSSHPrivate(L,N,Y);if(d&&d.toLowerCase()==="ssh2")return k.readType(L,N,Y);var de=new e.BerReader(N);return de.originalInput=ie,de.readSequence(),d?(J&&t.strictEqual(J,"pkcs1"),y.readPkcs1(d,L,de)):(J&&t.strictEqual(J,"pkcs8"),E.readPkcs8(d,L,de))}function j(N,Y,J){t.object(N);var ie={ecdsa:"EC",rsa:"RSA",dsa:"DSA",ed25519:"EdDSA"}[N.type],ue,Q=new e.BerWriter;if(m.isPrivateKey(N))J&&J==="pkcs8"?(ue="PRIVATE KEY",E.writePkcs8(Q,N)):(J&&t.strictEqual(J,"pkcs1"),ue=ie+" PRIVATE KEY",y.writePkcs1(Q,N));else if(l.isKey(N))J&&J==="pkcs1"?(ue=ie+" PUBLIC KEY",y.writePkcs1(Q,N)):(J&&t.strictEqual(J,"pkcs8"),ue="PUBLIC KEY",E.writePkcs8(Q,N));else throw new Error("key is not a Key or PrivateKey");var ce=Q.buffer.toString("base64"),he=ce.length+ce.length/64+18+16+ue.length*2+10,ke=o.alloc(he),L=0;L+=ke.write("-----BEGIN "+ue+`-----
`,L);for(var d=0;d<ce.length;){var v=d+64;v>ce.length&&(v=ce.length),L+=ke.write(ce.slice(d,v),L),ke[L++]=10,d=v}return L+=ke.write("-----END "+ue+`-----
`,L),ke.slice(0,L)}return pem}var ssh,hasRequiredSsh;function requireSsh(){if(hasRequiredSsh)return ssh;hasRequiredSsh=1,ssh={read:m,write:y};var t=requireAssert(),e=requireSafer().Buffer,n=requireRfc4253();requireUtils$2();var o=requireKey();requirePrivateKey(),requireSshPrivate();var u=/^([a-z0-9-]+)[ \t]+([a-zA-Z0-9+\/]+[=]*)([ \t]+([^ \t][^\n]*[\n]*)?)?$/,l=/^([a-z0-9-]+)[ \t\n]+([a-zA-Z0-9+\/][a-zA-Z0-9+\/ \t\n=]*)([^a-zA-Z0-9+\/ \t\n=].*)?$/;function m(E,C){typeof E!="string"&&(t.buffer(E,"buf"),E=E.toString("ascii"));var k=E.trim().replace(/[\\\r]/g,""),A=k.match(u);A||(A=k.match(l)),t.ok(A,"key must match regex");var D=n.algToKeyType(A[1]),P=e.from(A[2],"base64"),R,B={};if(A[4])try{R=n.read(P)}catch{A=k.match(l),t.ok(A,"key must match regex"),P=e.from(A[2],"base64"),R=n.readInternal(B,"public",P)}else R=n.readInternal(B,"public",P);if(t.strictEqual(D,R.type),A[4]&&A[4].length>0)R.comment=A[4];else if(B.consumed){var F=A[2]+(A[3]?A[3]:""),j=Math.ceil(B.consumed/3)*4;F=F.slice(0,j-2).replace(/[^a-zA-Z0-9+\/=]/g,"")+F.slice(j-2);var N=B.consumed%3;for(N>0&&F.slice(j-1,j)!=="="&&j--;F.slice(j,j+1)==="=";)j++;var Y=F.slice(j);Y=Y.replace(/[\r\n]/g," ").replace(/^\s+/,""),Y.match(/^[a-zA-Z0-9]/)&&(R.comment=Y)}return R}function y(E,C){if(t.object(E),!o.isKey(E))throw new Error("Must be a public key");var k=[],A=n.keyTypeToAlg(E);k.push(A);var D=n.write(E);return k.push(D.toString("base64")),E.comment&&k.push(E.comment),e.from(k.join(" "))}return ssh}var dnssec,hasRequiredDnssec;function requireDnssec(){if(hasRequiredDnssec)return dnssec;hasRequiredDnssec=1,dnssec={read:y,write:F};var t=requireAssert(),e=requireSafer().Buffer,n=requireKey(),o=requirePrivateKey(),u=requireUtils$2();requireSshBuffer(),requireDhe();var l={"rsa-sha1":5,"rsa-sha256":8,"rsa-sha512":10,"ecdsa-p256-sha256":13,"ecdsa-p384-sha384":14},m={};Object.keys(l).forEach(function(j){m[l[j]]=j.toUpperCase()});function y(j,N){typeof j!="string"&&(t.buffer(j,"buf"),j=j.toString("ascii"));var Y=j.split(`
`);if(Y[0].match(/^Private-key-format\: v1/)){var J=Y[1].split(" "),ie=parseInt(J[1],10),ue=J[2];if(!m[ie])throw new Error("Unsupported algorithm: "+ue);return A(ie,Y.slice(2))}for(var Q=0;Y[Q].match(/^\;/);)Q++;if((Y[Q].match(/\. IN KEY /)||Y[Q].match(/\. IN DNSKEY /))&&Y[Q+1].length===0)return E(Y[Q]);throw new Error("Cannot parse dnssec key")}function E(j){var N=j.split(" "),Y=parseInt(N[5],10);if(!m[Y])throw new Error("Unsupported algorithm: "+Y);var J=N.slice(6,N.length).join(),ie=e.from(J,"base64");if(m[Y].match(/^RSA-/)){var ue=ie.readUInt8(0);if(ue!=3&&ue!=1)throw new Error("Cannot parse dnssec key: unsupported exponent length");var Q=ie.slice(1,ue+1);Q=u.mpNormalize(Q);var ce=ie.slice(1+ue);ce=u.mpNormalize(ce);var he={type:"rsa",parts:[]};return he.parts.push({name:"e",data:Q}),he.parts.push({name:"n",data:ce}),new n(he)}if(m[Y]==="ECDSA-P384-SHA384"||m[Y]==="ECDSA-P256-SHA256"){var ke="nistp384",L=384;m[Y].match(/^ECDSA-P256-SHA256/)&&(ke="nistp256",L=256);var d={type:"ecdsa",curve:ke,size:L,parts:[{name:"curve",data:e.from(ke)},{name:"Q",data:u.ecNormalize(ie)}]};return new n(d)}throw new Error("Unsupported algorithm: "+m[Y])}function C(j){return e.from(j.split(" ")[1],"base64")}function k(j){var N={};j.forEach(function(J){J.split(" ")[0]==="Modulus:"?N.n=C(J):J.split(" ")[0]==="PublicExponent:"?N.e=C(J):J.split(" ")[0]==="PrivateExponent:"?N.d=C(J):J.split(" ")[0]==="Prime1:"?N.p=C(J):J.split(" ")[0]==="Prime2:"?N.q=C(J):J.split(" ")[0]==="Exponent1:"?N.dmodp=C(J):J.split(" ")[0]==="Exponent2:"?N.dmodq=C(J):J.split(" ")[0]==="Coefficient:"&&(N.iqmp=C(J))});var Y={type:"rsa",parts:[{name:"e",data:u.mpNormalize(N.e)},{name:"n",data:u.mpNormalize(N.n)},{name:"d",data:u.mpNormalize(N.d)},{name:"p",data:u.mpNormalize(N.p)},{name:"q",data:u.mpNormalize(N.q)},{name:"dmodp",data:u.mpNormalize(N.dmodp)},{name:"dmodq",data:u.mpNormalize(N.dmodq)},{name:"iqmp",data:u.mpNormalize(N.iqmp)}]};return new o(Y)}function A(j,N){if(m[j].match(/^RSA-/))return k(N);if(m[j]==="ECDSA-P384-SHA384"||m[j]==="ECDSA-P256-SHA256"){var Y=e.from(N[0].split(" ")[1],"base64"),J="nistp384",ie=384;m[j]==="ECDSA-P256-SHA256"&&(J="nistp256",ie=256);var ue=u.publicFromPrivateECDSA(J,Y),Q=ue.part.Q.data,ce={type:"ecdsa",curve:J,size:ie,parts:[{name:"curve",data:e.from(J)},{name:"d",data:Y},{name:"Q",data:Q}]};return new o(ce)}throw new Error("Unsupported algorithm: "+m[j])}function D(j){var N=j.getFullYear()+"",Y=j.getMonth()+1,J=N+Y+j.getUTCDate();return J+=""+j.getUTCHours()+j.getUTCMinutes(),J+=j.getUTCSeconds(),J}function P(j){if(!j||!j.hashAlgo||j.hashAlgo==="sha1")return"5 (RSASHA1)";if(j.hashAlgo==="sha256")return"8 (RSASHA256)";if(j.hashAlgo==="sha512")return"10 (RSASHA512)";throw new Error("Unknown or unsupported hash: "+j.hashAlgo)}function R(j,N){(!j.part.dmodp||!j.part.dmodq)&&u.addRSAMissing(j);var Y="";Y+=`Private-key-format: v1.3
`,Y+="Algorithm: "+P(N)+`
`;var J=u.mpDenormalize(j.part.n.data);Y+="Modulus: "+J.toString("base64")+`
`;var ie=u.mpDenormalize(j.part.e.data);Y+="PublicExponent: "+ie.toString("base64")+`
`;var ue=u.mpDenormalize(j.part.d.data);Y+="PrivateExponent: "+ue.toString("base64")+`
`;var Q=u.mpDenormalize(j.part.p.data);Y+="Prime1: "+Q.toString("base64")+`
`;var ce=u.mpDenormalize(j.part.q.data);Y+="Prime2: "+ce.toString("base64")+`
`;var he=u.mpDenormalize(j.part.dmodp.data);Y+="Exponent1: "+he.toString("base64")+`
`;var ke=u.mpDenormalize(j.part.dmodq.data);Y+="Exponent2: "+ke.toString("base64")+`
`;var L=u.mpDenormalize(j.part.iqmp.data);Y+="Coefficient: "+L.toString("base64")+`
`;var d=new Date;return Y+="Created: "+D(d)+`
`,Y+="Publish: "+D(d)+`
`,Y+="Activate: "+D(d)+`
`,e.from(Y,"ascii")}function B(j,N){var Y="";if(Y+=`Private-key-format: v1.3
`,j.curve==="nistp256")Y+=`Algorithm: 13 (ECDSAP256SHA256)
`;else if(j.curve==="nistp384")Y+=`Algorithm: 14 (ECDSAP384SHA384)
`;else throw new Error("Unsupported curve");var J=j.part.d.data.toString("base64");Y+="PrivateKey: "+J+`
`;var ie=new Date;return Y+="Created: "+D(ie)+`
`,Y+="Publish: "+D(ie)+`
`,Y+="Activate: "+D(ie)+`
`,e.from(Y,"ascii")}function F(j,N){if(o.isPrivateKey(j)){if(j.type==="rsa")return R(j,N);if(j.type==="ecdsa")return B(j);throw new Error("Unsupported algorithm: "+j.type)}else throw n.isKey(j)?new Error('Format "dnssec" only supports writing private keys'):new Error("key is not a Key or PrivateKey")}return dnssec}var putty,hasRequiredPutty;function requirePutty(){if(hasRequiredPutty)return putty;hasRequiredPutty=1,putty={read:E,write:A};var t=requireAssert(),e=requireSafer().Buffer,n=requireRfc4253(),o=requireKey(),u=requireSshBuffer(),l=requireCryptoBrowserify(),m=requirePrivateKey(),y=requireErrors$1();function E(P,R){for(var B=P.toString("ascii").split(/[\r\n]+/),F=!1,j,N=0,Y;N<B.length;)if(j=k(B[N++]),j&&(Y={"putty-user-key-file-2":2,"putty-user-key-file-3":3}[j[0].toLowerCase()],Y)){F=!0;break}if(!F)throw new Error("No PuTTY format first line found");var J=j[1];j=k(B[N++]),t.equal(j[0].toLowerCase(),"encryption");var ie=j[1];j=k(B[N++]),t.equal(j[0].toLowerCase(),"comment");var ue=j[1];j=k(B[N++]),t.equal(j[0].toLowerCase(),"public-lines");var Q=parseInt(j[1],10);if(!isFinite(Q)||Q<0||Q>B.length)throw new Error("Invalid public-lines count");var ce=e.from(B.slice(N,N+Q).join(""),"base64"),he=n.algToKeyType(J),ke=n.read(ce);if(ke.type!==he)throw new Error("Outer key algorithm mismatch");if(N+=Q,B[N]){j=k(B[N++]),t.equal(j[0].toLowerCase(),"private-lines");var L=parseInt(j[1],10);if(!isFinite(L)||L<0||L>B.length)throw new Error("Invalid private-lines count");var d=e.from(B.slice(N,N+L).join(""),"base64");if(ie!=="none"&&Y===3)throw new Error("Encrypted keys arenot supported for PuTTY format version 3");if(ie==="aes256-cbc"){if(!R.passphrase)throw new y.KeyEncryptedError(R.filename,"PEM");var v=e.alloc(16,0),w=l.createDecipheriv("aes-256-cbc",C(R.passphrase),v);w.setAutoPadding(!1),d=e.concat([w.update(d),w.final()])}if(ke=new m(ke),ke.type!==he)throw new Error("Outer key algorithm mismatch");var c=new u({buffer:d}),p;if(J==="ssh-dss")p=[{name:"x",data:c.readBuffer()}];else if(J==="ssh-rsa")p=[{name:"d",data:c.readBuffer()},{name:"p",data:c.readBuffer()},{name:"q",data:c.readBuffer()},{name:"iqmp",data:c.readBuffer()}];else if(J.match(/^ecdsa-sha2-nistp/))p=[{name:"d",data:c.readBuffer()}];else if(J==="ssh-ed25519")p=[{name:"k",data:c.readBuffer()}];else throw new Error("Unsupported PPK key type: "+J);ke=new m({type:ke.type,parts:ke.parts.concat(p)})}return ke.comment=ue,ke}function C(P){var R=l.createHash("sha1").update(e.concat([e.from([0,0,0,0]),e.from(P)])).digest(),B=l.createHash("sha1").update(e.concat([e.from([0,0,0,1]),e.from(P)])).digest();return e.concat([R,B]).slice(0,32)}function k(P){var R=P.indexOf(":");if(R===-1)return null;var B=P.slice(0,R);for(++R;P[R]===" ";)++R;var F=P.slice(R);return[B,F]}function A(P,R){if(t.object(P),!o.isKey(P))throw new Error("Must be a public key");var B=n.keyTypeToAlg(P),F=n.write(P),j=P.comment||"",N=F.toString("base64"),Y=D(N);return Y.unshift("Public-Lines: "+Y.length),Y.unshift("Comment: "+j),Y.unshift("Encryption: none"),Y.unshift("PuTTY-User-Key-File-2: "+B),e.from(Y.join(`
`)+`
`)}function D(P,R){for(var B=[],F=0;F<P.length;)B.push(P.slice(F,F+64)),F+=64;return B}return putty}var auto,hasRequiredAuto;function requireAuto(){if(hasRequiredAuto)return auto;hasRequiredAuto=1,auto={read:E,write:P};var t=requireAssert(),e=requireSafer().Buffer;requireUtils$2(),requireKey(),requirePrivateKey();var n=requirePem(),o=requireSsh(),u=requireRfc4253(),l=requireDnssec(),m=requirePutty(),y="Private-key-format: v1";function E(R,B){if(typeof R=="string"){if(R.trim().match(/^[-]+[ ]*BEGIN/))return n.read(R,B);if(R.match(/^\s*ssh-[a-z]/)||R.match(/^\s*ecdsa-/))return o.read(R,B);if(R.match(/^putty-user-key-file-2:/i))return m.read(R,B);if(D(R))return l.read(R,B);R=e.from(R,"binary")}else{if(t.buffer(R),A(R))return n.read(R,B);if(k(R))return o.read(R,B);if(C(R))return m.read(R,B);if(D(R))return l.read(R,B)}if(R.readUInt32BE(0)<R.length)return u.read(R,B);throw new Error("Failed to auto-detect format of key")}function C(R){for(var B=0;B<R.length&&(R[B]===32||R[B]===10||R[B]===9);)++B;return B+22<=R.length&&R.slice(B,B+22).toString("ascii").toLowerCase()==="putty-user-key-file-2:"}function k(R){for(var B=0;B<R.length&&(R[B]===32||R[B]===10||R[B]===9);)++B;return B+4<=R.length&&R.slice(B,B+4).toString("ascii")==="ssh-"||B+6<=R.length&&R.slice(B,B+6).toString("ascii")==="ecdsa-"}function A(R){for(var B=0;B<R.length&&(R[B]===32||R[B]===10);)++B;if(R[B]!==45)return!1;for(;B<R.length&&R[B]===45;)++B;for(;B<R.length&&R[B]===32;)++B;return!(B+5>R.length||R.slice(B,B+5).toString("ascii")!=="BEGIN")}function D(R){if(R.length<=y.length)return!1;var B=R.slice(0,y.length);if(B.toString("ascii")===y)return!0;typeof R!="string"&&(R=R.toString("ascii"));for(var F=R.split(`
`),j=0;F[j].match(/^\;/);)j++;return!!(F[j].toString("ascii").match(/\. IN KEY /)||F[j].toString("ascii").match(/\. IN DNSKEY /))}function P(R,B){throw new Error('"auto" format cannot be used for writing')}return auto}var privateKey,hasRequiredPrivateKey;function requirePrivateKey(){if(hasRequiredPrivateKey)return privateKey;hasRequiredPrivateKey=1,privateKey=F;var t=requireAssert(),e=requireSafer().Buffer,n=requireAlgs(),o=requireCryptoBrowserify();requireFingerprint();var u=requireSignature(),l=requireErrors$1(),m=util$6,y=requireUtils$2(),E=requireDhe(),C=E.generateECDSA,k=E.generateED25519,A=requireEdCompat(),D=requireNaclFast(),P=requireKey();l.InvalidAlgorithmError;var R=l.KeyParseError;l.KeyEncryptedError;var B={};B.auto=requireAuto(),B.pem=requirePem(),B.pkcs1=requirePkcs1(),B.pkcs8=requirePkcs8(),B.rfc4253=requireRfc4253(),B["ssh-private"]=requireSshPrivate(),B.openssh=B["ssh-private"],B.ssh=B["ssh-private"],B.dnssec=requireDnssec(),B.putty=requirePutty();function F(j){t.object(j,"options"),P.call(this,j),this._pubCache=void 0}return m.inherits(F,P),F.formats=B,F.prototype.toBuffer=function(j,N){return j===void 0&&(j="pkcs1"),t.string(j,"format"),t.object(B[j],"formats[format]"),t.optionalObject(N,"options"),B[j].write(this,N)},F.prototype.hash=function(j,N){return this.toPublic().hash(j,N)},F.prototype.fingerprint=function(j,N){return this.toPublic().fingerprint(j,N)},F.prototype.toPublic=function(){if(this._pubCache)return this._pubCache;for(var j=n.info[this.type],N=[],Y=0;Y<j.parts.length;++Y){var J=j.parts[Y];N.push(this.part[J])}return this._pubCache=new P({type:this.type,source:this,parts:N}),this.comment&&(this._pubCache.comment=this.comment),this._pubCache},F.prototype.derive=function(j){t.string(j,"type");var N,Y,J;if(this.type==="ed25519"&&j==="curve25519")return N=this.part.k.data,N[0]===0&&(N=N.slice(1)),J=D.box.keyPair.fromSecretKey(new Uint8Array(N)),Y=e.from(J.publicKey),new F({type:"curve25519",parts:[{name:"A",data:y.mpNormalize(Y)},{name:"k",data:y.mpNormalize(N)}]});if(this.type==="curve25519"&&j==="ed25519")return N=this.part.k.data,N[0]===0&&(N=N.slice(1)),J=D.sign.keyPair.fromSeed(new Uint8Array(N)),Y=e.from(J.publicKey),new F({type:"ed25519",parts:[{name:"A",data:y.mpNormalize(Y)},{name:"k",data:y.mpNormalize(N)}]});throw new Error("Key derivation not supported from "+this.type+" to "+j)},F.prototype.createVerify=function(j){return this.toPublic().createVerify(j)},F.prototype.createSign=function(j){if(j===void 0&&(j=this.defaultHashAlgorithm()),t.string(j,"hash algorithm"),this.type==="ed25519"&&A!==void 0)return new A.Signer(this,j);if(this.type==="curve25519")throw new Error("Curve25519 keys are not suitable for signing or verification");var N,Y,J;try{Y=j.toUpperCase(),N=o.createSign(Y)}catch(he){J=he}(N===void 0||J instanceof Error&&J.message.match(/Unknown message digest/))&&(Y="RSA-",Y+=j.toUpperCase(),N=o.createSign(Y)),t.ok(N,"failed to create verifier");var ie=N.sign.bind(N),ue=this.toBuffer("pkcs1"),Q=this.type,ce=this.curve;return N.sign=function(){var he=ie(ue);return typeof he=="string"&&(he=e.from(he,"binary")),he=u.parse(he,Q,"asn1"),he.hashAlgorithm=j,he.curve=ce,he},N},F.parse=function(j,N,Y){typeof j!="string"&&t.buffer(j,"data"),N===void 0&&(N="auto"),t.string(N,"format"),typeof Y=="string"&&(Y={filename:Y}),t.optionalObject(Y,"options"),Y===void 0&&(Y={}),t.optionalString(Y.filename,"options.filename"),Y.filename===void 0&&(Y.filename="(unnamed)"),t.object(B[N],"formats[format]");try{var J=B[N].read(j,Y);return t.ok(J instanceof F,"key is not a private key"),J.comment||(J.comment=Y.filename),J}catch(ie){throw ie.name==="KeyEncryptedError"?ie:new R(Y.filename,N,ie)}},F.isPrivateKey=function(j,N){return y.isCompatible(j,F,N)},F.generate=function(j,N){switch(N===void 0&&(N={}),t.object(N,"options"),j){case"ecdsa":return N.curve===void 0&&(N.curve="nistp256"),t.string(N.curve,"options.curve"),C(N.curve);case"ed25519":return k();default:throw new Error('Key generation not supported with key type "'+j+'"')}},F.prototype._sshpkApiVersion=[1,6],F._oldVersionDetect=function(j){return t.func(j.toPublic),t.func(j.createSign),j.derive?[1,3]:j.defaultHashAlgorithm?[1,2]:j.formats.auto?[1,1]:[1,0]},privateKey}var identity,hasRequiredIdentity;function requireIdentity(){if(hasRequiredIdentity)return identity;hasRequiredIdentity=1,identity=y;var t=requireAssert();requireAlgs(),requireCryptoBrowserify(),requireFingerprint(),requireSignature(),requireErrors$1();var e=requireUtils$2(),n=requireLib$4(),o=requireSafer().Buffer,u=/^([*]|[a-z0-9][a-z0-9\-]{0,62})(?:\.([*]|[a-z0-9][a-z0-9\-]{0,62}))*$/i,l={};l.cn="2.5.4.3",l.o="2.5.4.10",l.ou="2.5.4.11",l.l="2.5.4.7",l.s="2.5.4.8",l.c="2.5.4.6",l.sn="2.5.4.4",l.postalCode="2.5.4.17",l.serialNumber="2.5.4.5",l.street="2.5.4.9",l.x500UniqueIdentifier="2.5.4.45",l.role="2.5.4.72",l.telephoneNumber="2.5.4.20",l.description="2.5.4.13",l.dc="0.9.2342.19200300.100.1.25",l.uid="0.9.2342.19200300.100.1.1",l.mail="0.9.2342.19200300.100.1.3",l.title="2.5.4.12",l.gn="2.5.4.42",l.initials="2.5.4.43",l.pseudonym="2.5.4.65",l.emailAddress="1.2.840.113549.1.9.1";var m={};Object.keys(l).forEach(function(A){m[l[A]]=A});function y(A){var D=this;if(t.object(A,"options"),t.arrayOfObject(A.components,"options.components"),this.components=A.components,this.componentLookup={},this.components.forEach(function(P){P.name&&!P.oid&&(P.oid=l[P.name]),P.oid&&!P.name&&(P.name=m[P.oid]),D.componentLookup[P.name]===void 0&&(D.componentLookup[P.name]=[]),D.componentLookup[P.name].push(P)}),this.componentLookup.cn&&this.componentLookup.cn.length>0&&(this.cn=this.componentLookup.cn[0].value),t.optionalString(A.type,"options.type"),A.type===void 0)this.components.length===1&&this.componentLookup.cn&&this.componentLookup.cn.length===1&&this.componentLookup.cn[0].value.match(u)?(this.type="host",this.hostname=this.componentLookup.cn[0].value):this.componentLookup.dc&&this.components.length===this.componentLookup.dc.length?(this.type="host",this.hostname=this.componentLookup.dc.map(function(P){return P.value}).join(".")):this.componentLookup.uid&&this.components.length===this.componentLookup.uid.length?(this.type="user",this.uid=this.componentLookup.uid[0].value):this.componentLookup.cn&&this.componentLookup.cn.length===1&&this.componentLookup.cn[0].value.match(u)?(this.type="host",this.hostname=this.componentLookup.cn[0].value):this.componentLookup.uid&&this.componentLookup.uid.length===1?(this.type="user",this.uid=this.componentLookup.uid[0].value):this.componentLookup.mail&&this.componentLookup.mail.length===1?(this.type="email",this.email=this.componentLookup.mail[0].value):this.componentLookup.cn&&this.componentLookup.cn.length===1?(this.type="user",this.uid=this.componentLookup.cn[0].value):this.type="unknown";else if(this.type=A.type,this.type==="host")this.hostname=A.hostname;else if(this.type==="user")this.uid=A.uid;else if(this.type==="email")this.email=A.email;else throw new Error("Unknown type "+this.type)}y.prototype.toString=function(){return this.components.map(function(A){var D=A.name.toUpperCase();D=D.replace(/=/g,"\\=");var P=A.value;return P=P.replace(/,/g,"\\,"),D+"="+P}).join(", ")},y.prototype.get=function(A,D){t.string(A,"name");var P=this.componentLookup[A];if(!(P===void 0||P.length===0)){if(!D&&P.length>1)throw new Error("Multiple values for attribute "+A);return D?P.map(function(R){return R.value}):P[0].value}},y.prototype.toArray=function(A){return this.components.map(function(D){return{name:D.name,value:D.value}})};var E=/[^a-zA-Z0-9 '(),+.\/:=?-]/,C=/[^\x00-\x7f]/;y.prototype.toAsn1=function(A,D){A.startSequence(D),this.components.forEach(function(P){if(A.startSequence(n.Ber.Constructor|n.Ber.Set),A.startSequence(),A.writeOID(P.oid),P.asn1type===n.Ber.Utf8String||P.value.match(C)){var R=o.from(P.value,"utf8");A.writeBuffer(R,n.Ber.Utf8String)}else if(P.asn1type===n.Ber.IA5String||P.value.match(E))A.writeString(P.value,n.Ber.IA5String);else{var B=n.Ber.PrintableString;P.asn1type!==void 0&&(B=P.asn1type),A.writeString(P.value,B)}A.endSequence(),A.endSequence()}),A.endSequence()};function k(A,D){if(A==="**"||D==="**")return!0;var P=A.split("."),R=D.split(".");if(P.length!==R.length)return!1;for(var B=0;B<P.length;++B)if(!(P[B]==="*"||R[B]==="*")&&P[B]!==R[B])return!1;return!0}return y.prototype.equals=function(A){if(!y.isIdentity(A,[1,0])||A.components.length!==this.components.length)return!1;for(var D=0;D<this.components.length;++D)if(this.components[D].oid!==A.components[D].oid||!k(this.components[D].value,A.components[D].value))return!1;return!0},y.forHost=function(A){return t.string(A,"hostname"),new y({type:"host",hostname:A,components:[{name:"cn",value:A}]})},y.forUser=function(A){return t.string(A,"uid"),new y({type:"user",uid:A,components:[{name:"uid",value:A}]})},y.forEmail=function(A){return t.string(A,"email"),new y({type:"email",email:A,components:[{name:"mail",value:A}]})},y.parseDN=function(A){t.string(A,"dn");for(var D=[""],P=0,R=A;R.length>0;){var B;if((B=/^,/.exec(R))!==null)D[++P]="",R=R.slice(B[0].length);else if((B=/^\\,/.exec(R))!==null)D[P]+=",",R=R.slice(B[0].length);else if((B=/^\\./.exec(R))!==null)D[P]+=B[0],R=R.slice(B[0].length);else if((B=/^[^\\,]+/.exec(R))!==null)D[P]+=B[0],R=R.slice(B[0].length);else throw new Error("Failed to parse DN")}var F=D.map(function(j){j=j.trim();for(var N=j.indexOf("=");N>0&&j.charAt(N-1)==="\\";)N=j.indexOf("=",N+1);if(N===-1)throw new Error("Failed to parse DN");var Y=j.slice(0,N).toLowerCase().replace(/\\=/g,"="),J=j.slice(N+1);return{name:Y,value:J}});return new y({components:F})},y.fromArray=function(A){return t.arrayOfObject(A,"components"),A.forEach(function(D){if(t.object(D,"component"),t.string(D.name,"component.name"),!o.isBuffer(D.value)&&typeof D.value!="string")throw new Error("Invalid component value")}),new y({components:A})},y.parseAsn1=function(A,D){var P=[];A.readSequence(D);for(var R=A.offset+A.length;A.offset<R;){A.readSequence(n.Ber.Constructor|n.Ber.Set);var B=A.offset+A.length;A.readSequence();var F=A.readOID(),j=A.peek(),N;switch(j){case n.Ber.PrintableString:case n.Ber.IA5String:case n.Ber.OctetString:case n.Ber.T61String:N=A.readString(j);break;case n.Ber.Utf8String:N=A.readString(j,!0),N=N.toString("utf8");break;case n.Ber.CharacterString:case n.Ber.BMPString:N=A.readString(j,!0),N=N.toString("utf16le");break;default:throw new Error("Unknown asn1 type "+j)}P.push({oid:F,asn1type:j,value:N}),A._offset=B}return A._offset=R,new y({components:P})},y.isIdentity=function(A,D){return e.isCompatible(A,y,D)},y.prototype._sshpkApiVersion=[1,0],y._oldVersionDetect=function(A){return[1,0]},identity}var opensshCert,hasRequiredOpensshCert;function requireOpensshCert(){if(hasRequiredOpensshCert)return opensshCert;hasRequiredOpensshCert=1,opensshCert={read:R,verify:A,sign:N,signAsync:Y,write:J,fromBuffer:B,toBuffer:ie};var t=requireAssert(),e=requireSshBuffer(),n=requireCryptoBrowserify(),o=requireSafer().Buffer,u=requireAlgs(),l=requireKey();requirePrivateKey();var m=requireIdentity(),y=requireRfc4253(),E=requireSignature(),C=requireUtils$2(),k=requireCertificate();function A(ce,he){return!1}var D={user:1,host:2};Object.keys(D).forEach(function(ce){D[D[ce]]=ce});var P=/^ecdsa-sha2-([^@-]+)-cert-v01@openssh.com$/;function R(ce,he){o.isBuffer(ce)&&(ce=ce.toString("ascii"));var ke=ce.trim().split(/[ \t\n]+/g);if(ke.length<2||ke.length>3)throw new Error("Not a valid SSH certificate line");var L=ke[0],d=ke[1];return d=o.from(d,"base64"),B(d,L)}function B(ce,he,ke){var L=new e({buffer:ce}),d=L.readString();if(he!==void 0&&d!==he)throw new Error("SSH certificate algorithm mismatch");he===void 0&&(he=d);var v={};v.signatures={},v.signatures.openssh={},v.signatures.openssh.nonce=L.readBuffer();var w={},c=w.parts=[];w.type=ue(he);for(var p=u.info[w.type].parts.length;c.length<p;)c.push(L.readPart());t.ok(c.length>=1,"key must have at least one part");var x=u.info[w.type];if(w.type==="ecdsa"){var S=P.exec(he);t.ok(S!==null),t.strictEqual(S[1],c[0].data.toString())}for(var b=0;b<x.parts.length;++b)if(c[b].name=x.parts[b],c[b].name!=="curve"&&x.normalize!==!1){var h=c[b];h.data=C.mpNormalize(h.data)}v.subjectKey=new l(w),v.serial=L.readInt64();var T=D[L.readInt()];t.string(T,"valid cert type"),v.signatures.openssh.keyId=L.readString();for(var M=[],O=L.readBuffer(),V=new e({buffer:O});!V.atEnd();)M.push(V.readString());M.length===0&&(M=["*"]),v.subjects=M.map(function(fe){if(T==="user")return m.forUser(fe);if(T==="host")return m.forHost(fe);throw new Error("Unknown identity type "+T)}),v.validFrom=F(L.readInt64()),v.validUntil=F(L.readInt64());for(var ee=[],Z=new e({buffer:L.readBuffer()}),U;!Z.atEnd();)U={critical:!0},U.name=Z.readString(),U.data=Z.readBuffer(),ee.push(U);for(Z=new e({buffer:L.readBuffer()});!Z.atEnd();)U={critical:!1},U.name=Z.readString(),U.data=Z.readBuffer(),ee.push(U);v.signatures.openssh.exts=ee,L.readBuffer();var z=L.readBuffer();v.issuerKey=y.read(z),v.issuer=m.forHost("**");var ne=L.readBuffer();return v.signatures.openssh.signature=E.parse(ne,v.issuerKey.type,"ssh"),ke!==void 0&&(ke.remainder=L.remainder(),ke.consumed=L._offset),new k(v)}function F(ce){var he=ce.readUInt32BE(0)*4294967296;he+=ce.readUInt32BE(4);var ke=new Date;return ke.setTime(he*1e3),ke.sourceInt64=ce,ke}function j(ce){if(ce.sourceInt64!==void 0)return ce.sourceInt64;var he=Math.round(ce.getTime()/1e3),ke=Math.floor(he/4294967296),L=Math.floor(he%4294967296),d=o.alloc(8);return d.writeUInt32BE(ke,0),d.writeUInt32BE(L,4),d}function N(ce,he){ce.signatures.openssh===void 0&&(ce.signatures.openssh={});try{var ke=ie(ce,!0)}catch{return delete ce.signatures.openssh,!1}var L=ce.signatures.openssh,d=void 0;(he.type==="rsa"||he.type==="dsa")&&(d="sha1");var v=he.createSign(d);return v.write(ke),L.signature=v.sign(),!0}function Y(ce,he,ke){ce.signatures.openssh===void 0&&(ce.signatures.openssh={});try{var L=ie(ce,!0)}catch(v){delete ce.signatures.openssh,ke(v);return}var d=ce.signatures.openssh;he(L,function(v,w){if(v){ke(v);return}try{w.toBuffer("ssh")}catch(c){ke(c);return}d.signature=w,ke()})}function J(ce,he){he===void 0&&(he={});var ke=ie(ce),L=Q(ce.subjectKey)+" "+ke.toString("base64");return he.comment&&(L=L+" "+he.comment),L}function ie(ce,he){t.object(ce.signatures.openssh,"signature for openssh format");var ke=ce.signatures.openssh;ke.nonce===void 0&&(ke.nonce=n.randomBytes(16));var L=new e({});L.writeString(Q(ce.subjectKey)),L.writeBuffer(ke.nonce);var d=ce.subjectKey,v=u.info[d.type];v.parts.forEach(function(S){L.writePart(d.part[S])}),L.writeInt64(ce.serial);var w=ce.subjects[0].type;t.notStrictEqual(w,"unknown"),ce.subjects.forEach(function(S){t.strictEqual(S.type,w)}),w=D[w],L.writeInt(w),ke.keyId===void 0&&(ke.keyId=ce.subjects[0].type+"_"+(ce.subjects[0].uid||ce.subjects[0].hostname)),L.writeString(ke.keyId);var c=new e({});ce.subjects.forEach(function(S){w===D.host?c.writeString(S.hostname):w===D.user&&c.writeString(S.uid)}),L.writeBuffer(c.toBuffer()),L.writeInt64(j(ce.validFrom)),L.writeInt64(j(ce.validUntil));var p=ke.exts;p===void 0&&(p=[]);var x=new e({});return p.forEach(function(S){S.critical===!0&&(x.writeString(S.name),x.writeBuffer(S.data))}),L.writeBuffer(x.toBuffer()),x=new e({}),p.forEach(function(S){S.critical!==!0&&(x.writeString(S.name),x.writeBuffer(S.data))}),L.writeBuffer(x.toBuffer()),L.writeBuffer(o.alloc(0)),c=y.write(ce.issuerKey),L.writeBuffer(c),he||L.writeBuffer(ke.signature.toBuffer("ssh")),L.toBuffer()}function ue(ce){if(ce==="ssh-rsa-cert-v01@openssh.com")return"rsa";if(ce==="ssh-dss-cert-v01@openssh.com")return"dsa";if(ce.match(P))return"ecdsa";if(ce==="ssh-ed25519-cert-v01@openssh.com")return"ed25519";throw new Error("Unsupported cert type "+ce)}function Q(ce){if(ce.type==="rsa")return"ssh-rsa-cert-v01@openssh.com";if(ce.type==="dsa")return"ssh-dss-cert-v01@openssh.com";if(ce.type==="ecdsa")return"ecdsa-sha2-"+ce.curve+"-cert-v01@openssh.com";if(ce.type==="ed25519")return"ssh-ed25519-cert-v01@openssh.com";throw new Error("Unsupported key type "+ce.type)}return opensshCert}var x509,hasRequiredX509;function requireX509(){if(hasRequiredX509)return x509;hasRequiredX509=1,x509={read:R,verify:C,sign:v,signAsync:w,write:c};var t=requireAssert(),e=requireLib$4(),n=requireSafer().Buffer;requireAlgs();var o=requireUtils$2();requireKey(),requirePrivateKey(),requirePem();var u=requireIdentity(),l=requireSignature(),m=requireCertificate(),y=requirePkcs8();function E(b,h){return t.strictEqual(b.peek(),e.Ber.Integer,h+" is not an Integer"),o.mpNormalize(b.readString(e.Ber.Integer,!0))}function C(b,h){var T=b.signatures.x509;t.object(T,"x509 signature");var M=T.algo.split("-");if(M[0]!==h.type)return!1;var O=T.cache;if(O===void 0){var V=new e.BerWriter;p(b,V),O=V.buffer}var ee=h.createVerify(M[1]);return ee.write(O),ee.verify(T.signature)}function k(b){return e.Ber.Context|e.Ber.Constructor|b}function A(b){return e.Ber.Context|b}var D={"rsa-md5":"1.2.840.113549.1.1.4","rsa-sha1":"1.2.840.113549.1.1.5","rsa-sha256":"1.2.840.113549.1.1.11","rsa-sha384":"1.2.840.113549.1.1.12","rsa-sha512":"1.2.840.113549.1.1.13","dsa-sha1":"1.2.840.10040.4.3","dsa-sha256":"2.16.840.1.101.3.4.3.2","ecdsa-sha1":"1.2.840.10045.4.1","ecdsa-sha256":"1.2.840.10045.4.3.2","ecdsa-sha384":"1.2.840.10045.4.3.3","ecdsa-sha512":"1.2.840.10045.4.3.4","ed25519-sha512":"1.3.101.112"};Object.keys(D).forEach(function(b){D[D[b]]=b}),D["1.3.14.3.2.3"]="rsa-md5",D["1.3.14.3.2.29"]="rsa-sha1";var P={issuerKeyId:"2.5.29.35",altName:"2.5.29.17",basicConstraints:"2.5.29.19",keyUsage:"2.5.29.15",extKeyUsage:"2.5.29.37"};function R(b,h){typeof b=="string"&&(b=n.from(b,"binary")),t.buffer(b,"buf");var T=new e.BerReader(b);if(T.readSequence(),Math.abs(T.length-T.remain)>1)throw new Error("DER sequence does not contain whole byte stream");var M=T.offset;T.readSequence();var O=T.offset+T.length,V=O;if(T.peek()===k(0)){T.readSequence(k(0));var ee=T.readInt();t.ok(ee<=3,"only x.509 versions up to v3 supported")}var Z={};Z.signatures={};var U=Z.signatures.x509={};U.extras={},Z.serial=E(T,"serial"),T.readSequence();var z=T.offset+T.length,ne=T.readOID(),fe=D[ne];if(fe===void 0)throw new Error("unknown signature algorithm "+ne);if(T._offset=z,Z.issuer=u.parseAsn1(T),T.readSequence(),Z.validFrom=B(T),Z.validUntil=B(T),Z.subjects=[u.parseAsn1(T)],T.readSequence(),z=T.offset+T.length,Z.subjectKey=y.readPkcs8(void 0,"public",T),T._offset=z,T.peek()===k(1)&&(T.readSequence(k(1)),U.extras.issuerUniqueID=b.slice(T.offset,T.offset+T.length),T._offset+=T.length),T.peek()===k(2)&&(T.readSequence(k(2)),U.extras.subjectUniqueID=b.slice(T.offset,T.offset+T.length),T._offset+=T.length),T.peek()===k(3)){T.readSequence(k(3));var me=T.offset+T.length;for(T.readSequence();T.offset<me;)ie(Z,b,T);t.strictEqual(T.offset,me)}t.strictEqual(T.offset,O),T.readSequence(),z=T.offset+T.length;var de=T.readOID(),je=D[de];if(je===void 0)throw new Error("unknown signature algorithm "+de);T._offset=z;var lt=T.readString(e.Ber.BitString,!0);lt[0]===0&&(lt=lt.slice(1));var it=je.split("-");return U.signature=l.parse(lt,it[0],"asn1"),U.signature.hashAlgorithm=it[1],U.algo=je,U.cache=b.slice(M,V),new m(Z)}function B(b){if(b.peek()===e.Ber.UTCTime)return Q(b.readString(e.Ber.UTCTime));if(b.peek()===e.Ber.GeneralizedTime)return he(b.readString(e.Ber.GeneralizedTime));throw new Error("Unsupported date format")}function F(b,h){h.getUTCFullYear()>=2050||h.getUTCFullYear()<1950?b.writeString(d(h),e.Ber.GeneralizedTime):b.writeString(L(h),e.Ber.UTCTime)}var j={OtherName:k(0),RFC822Name:A(1),DNSName:A(2),X400Address:k(3),DirectoryName:k(4),EDIPartyName:k(5),URI:A(6),IPAddress:A(7),OID:A(8)},N={serverAuth:"1.3.6.1.5.5.7.3.1",clientAuth:"1.3.6.1.5.5.7.3.2",codeSigning:"1.3.6.1.5.5.7.3.3",joyentDocker:"1.3.6.1.4.1.38678.1.4.1",joyentCmon:"1.3.6.1.4.1.38678.1.4.2"},Y={};Object.keys(N).forEach(function(b){Y[N[b]]=b});var J=["signature","identity","keyEncryption","encryption","keyAgreement","ca","crl"];function ie(b,h,T){T.readSequence();var M=T.offset+T.length,O=T.readOID(),V,ee=b.signatures.x509;ee.extras.exts||(ee.extras.exts=[]);var Z;switch(T.peek()===e.Ber.Boolean&&(Z=T.readBoolean()),O){case P.basicConstraints:T.readSequence(e.Ber.OctetString),T.readSequence();var U=T.offset+T.length,z=!1;T.peek()===e.Ber.Boolean&&(z=T.readBoolean()),b.purposes===void 0&&(b.purposes=[]),z===!0&&b.purposes.push("ca");var ne={oid:O,critical:Z};T.offset<U&&T.peek()===e.Ber.Integer&&(ne.pathLen=T.readInt()),ee.extras.exts.push(ne);break;case P.extKeyUsage:T.readSequence(e.Ber.OctetString),T.readSequence(),b.purposes===void 0&&(b.purposes=[]);for(var fe=T.offset+T.length;T.offset<fe;){var me=T.readOID();b.purposes.push(Y[me]||me)}b.purposes.indexOf("serverAuth")!==-1&&b.purposes.indexOf("clientAuth")===-1?b.subjects.forEach(function(Ct){Ct.type!=="host"&&(Ct.type="host",Ct.hostname=Ct.uid||Ct.email||Ct.components[0].value)}):b.purposes.indexOf("clientAuth")!==-1&&b.purposes.indexOf("serverAuth")===-1&&b.subjects.forEach(function(Ct){Ct.type!=="user"&&(Ct.type="user",Ct.uid=Ct.hostname||Ct.email||Ct.components[0].value)}),ee.extras.exts.push({oid:O,critical:Z});break;case P.keyUsage:T.readSequence(e.Ber.OctetString);var de=T.readString(e.Ber.BitString,!0),je=x(de,J);je.forEach(function(Ct){b.purposes===void 0&&(b.purposes=[]),b.purposes.indexOf(Ct)===-1&&b.purposes.push(Ct)}),ee.extras.exts.push({oid:O,critical:Z,bits:de});break;case P.altName:T.readSequence(e.Ber.OctetString),T.readSequence();for(var lt=T.offset+T.length;T.offset<lt;)switch(T.peek()){case j.OtherName:case j.EDIPartyName:T.readSequence(),T._offset+=T.length;break;case j.OID:T.readOID(j.OID);break;case j.RFC822Name:var it=T.readString(j.RFC822Name);V=u.forEmail(it),b.subjects[0].equals(V)||b.subjects.push(V);break;case j.DirectoryName:T.readSequence(j.DirectoryName),V=u.parseAsn1(T),b.subjects[0].equals(V)||b.subjects.push(V);break;case j.DNSName:var ot=T.readString(j.DNSName);V=u.forHost(ot),b.subjects[0].equals(V)||b.subjects.push(V);break;default:T.readString(T.peek());break}ee.extras.exts.push({oid:O,critical:Z});break;default:ee.extras.exts.push({oid:O,critical:Z,data:T.readString(e.Ber.OctetString,!0)});break}T._offset=M}var ue=/^([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})?Z$/;function Q(b){var h=b.match(ue);t.ok(h,"timestamps must be in UTC");var T=new Date,M=T.getUTCFullYear(),O=Math.floor(M/100)*100,V=parseInt(h[1],10);return M%100<50&&V>=60?V+=O-1:V+=O,T.setUTCFullYear(V,parseInt(h[2],10)-1,parseInt(h[3],10)),T.setUTCHours(parseInt(h[4],10),parseInt(h[5],10)),h[6]&&h[6].length>0&&T.setUTCSeconds(parseInt(h[6],10)),T}var ce=/^([0-9]{4})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})?Z$/;function he(b){var h=b.match(ce);t.ok(h);var T=new Date;return T.setUTCFullYear(parseInt(h[1],10),parseInt(h[2],10)-1,parseInt(h[3],10)),T.setUTCHours(parseInt(h[4],10),parseInt(h[5],10)),h[6]&&h[6].length>0&&T.setUTCSeconds(parseInt(h[6],10)),T}function ke(b,h){h===void 0&&(h=2);for(var T=""+b;T.length<h;)T="0"+T;return T}function L(b){var h="";return h+=ke(b.getUTCFullYear()%100),h+=ke(b.getUTCMonth()+1),h+=ke(b.getUTCDate()),h+=ke(b.getUTCHours()),h+=ke(b.getUTCMinutes()),h+=ke(b.getUTCSeconds()),h+="Z",h}function d(b){var h="";return h+=ke(b.getUTCFullYear(),4),h+=ke(b.getUTCMonth()+1),h+=ke(b.getUTCDate()),h+=ke(b.getUTCHours()),h+=ke(b.getUTCMinutes()),h+=ke(b.getUTCSeconds()),h+="Z",h}function v(b,h){b.signatures.x509===void 0&&(b.signatures.x509={});var T=b.signatures.x509;if(T.algo=h.type+"-"+h.defaultHashAlgorithm(),D[T.algo]===void 0)return!1;var M=new e.BerWriter;p(b,M);var O=M.buffer;T.cache=O;var V=h.createSign();return V.write(O),b.signatures.x509.signature=V.sign(),!0}function w(b,h,T){b.signatures.x509===void 0&&(b.signatures.x509={});var M=b.signatures.x509,O=new e.BerWriter;p(b,O);var V=O.buffer;M.cache=V,h(V,function(ee,Z){if(ee){T(ee);return}if(M.algo=Z.type+"-"+Z.hashAlgorithm,D[M.algo]===void 0){T(new Error('Invalid signing algorithm "'+M.algo+'"'));return}M.signature=Z,T()})}function c(b,h){var T=b.signatures.x509;t.object(T,"x509 signature");var M=new e.BerWriter;M.startSequence(),T.cache?(M._ensure(T.cache.length),T.cache.copy(M._buf,M._offset),M._offset+=T.cache.length):p(b,M),M.startSequence(),M.writeOID(D[T.algo]),T.algo.match(/^rsa-/)&&M.writeNull(),M.endSequence();var O=T.signature.toBuffer("asn1"),V=n.alloc(O.length+1);return V[0]=0,O.copy(V,1),M.writeBuffer(V,e.Ber.BitString),M.endSequence(),M.buffer}function p(b,h){var T=b.signatures.x509;t.object(T,"x509 signature"),h.startSequence(),h.startSequence(k(0)),h.writeInt(2),h.endSequence(),h.writeBuffer(o.mpNormalize(b.serial),e.Ber.Integer),h.startSequence(),h.writeOID(D[T.algo]),T.algo.match(/^rsa-/)&&h.writeNull(),h.endSequence(),b.issuer.toAsn1(h),h.startSequence(),F(h,b.validFrom),F(h,b.validUntil),h.endSequence();var M=b.subjects[0],O=b.subjects.slice(1);if(M.toAsn1(h),y.writePkcs8(h,b.subjectKey),T.extras&&T.extras.issuerUniqueID&&h.writeBuffer(T.extras.issuerUniqueID,k(1)),T.extras&&T.extras.subjectUniqueID&&h.writeBuffer(T.extras.subjectUniqueID,k(2)),O.length>0||M.type==="host"||b.purposes!==void 0&&b.purposes.length>0||T.extras&&T.extras.exts){h.startSequence(k(3)),h.startSequence();var V=[];b.purposes!==void 0&&b.purposes.length>0&&(V.push({oid:P.basicConstraints,critical:!0}),V.push({oid:P.keyUsage,critical:!0}),V.push({oid:P.extKeyUsage,critical:!0})),V.push({oid:P.altName}),T.extras&&T.extras.exts&&(V=T.extras.exts);for(var ee=0;ee<V.length;++ee){if(h.startSequence(),h.writeOID(V[ee].oid),V[ee].critical!==void 0&&h.writeBoolean(V[ee].critical),V[ee].oid===P.altName){h.startSequence(e.Ber.OctetString),h.startSequence(),M.type==="host"&&h.writeString(M.hostname,A(2));for(var Z=0;Z<O.length;++Z)O[Z].type==="host"?h.writeString(O[Z].hostname,j.DNSName):O[Z].type==="email"?h.writeString(O[Z].email,j.RFC822Name):(h.startSequence(j.DirectoryName),O[Z].toAsn1(h),h.endSequence());h.endSequence(),h.endSequence()}else if(V[ee].oid===P.basicConstraints){h.startSequence(e.Ber.OctetString),h.startSequence();var U=b.purposes.indexOf("ca")!==-1,z=V[ee].pathLen;h.writeBoolean(U),z!==void 0&&h.writeInt(z),h.endSequence(),h.endSequence()}else if(V[ee].oid===P.extKeyUsage)h.startSequence(e.Ber.OctetString),h.startSequence(),b.purposes.forEach(function(fe){if(fe!=="ca"&&J.indexOf(fe)===-1){var me=fe;N[fe]!==void 0&&(me=N[fe]),h.writeOID(me)}}),h.endSequence(),h.endSequence();else if(V[ee].oid===P.keyUsage){if(h.startSequence(e.Ber.OctetString),V[ee].bits!==void 0)h.writeBuffer(V[ee].bits,e.Ber.BitString);else{var ne=S(b.purposes,J);h.writeBuffer(ne,e.Ber.BitString)}h.endSequence()}else h.writeBuffer(V[ee].data,e.Ber.OctetString);h.endSequence()}h.endSequence(),h.endSequence()}h.endSequence()}function x(b,h){for(var T=8*(b.length-1)-b[0],M={},O=0;O<T;++O){var V=1+Math.floor(O/8),ee=7-O%8,Z=1<<ee,U=(b[V]&Z)!==0,z=h[O];U&&typeof z=="string"&&(M[z]=!0)}return Object.keys(M)}function S(b,h){var T=h.length,M=Math.ceil(T/8),O=M*8-T,V=n.alloc(1+M);V[0]=O;for(var ee=0;ee<T;++ee){var Z=1+Math.floor(ee/8),U=7-ee%8,z=1<<U,ne=h[ee];if(ne!==void 0){var fe=b.indexOf(ne)!==-1;fe&&(V[Z]|=z)}}return V}return x509}var x509Pem,hasRequiredX509Pem;function requireX509Pem(){if(hasRequiredX509Pem)return x509Pem;hasRequiredX509Pem=1;var t=requireX509();x509Pem={read:o,verify:t.verify,sign:t.sign,write:u};var e=requireAssert();requireLib$4();var n=requireSafer().Buffer;requireAlgs(),requireUtils$2(),requireKey(),requirePrivateKey(),requirePem(),requireIdentity(),requireSignature(),requireCertificate();function o(l,m){typeof l!="string"&&(e.buffer(l,"buf"),l=l.toString("ascii"));for(var y=l.trim().split(/[\r\n]+/g),E,C=-1;!E&&C<y.length;)E=y[++C].match(/[-]+[ ]*BEGIN CERTIFICATE[ ]*[-]+/);e.ok(E,"invalid PEM header");for(var k,A=y.length;!k&&A>0;)k=y[--A].match(/[-]+[ ]*END CERTIFICATE[ ]*[-]+/);e.ok(k,"invalid PEM footer"),y=y.slice(C,A+1);for(var D={};y=y.slice(1),E=y[0].match(/^([A-Za-z0-9-]+): (.+)$/),!!E;)D[E[1].toLowerCase()]=E[2];return y=y.slice(0,-1).join(""),l=n.from(y,"base64"),t.read(l,m)}function u(l,m){var y=t.write(l,m),E="CERTIFICATE",C=y.toString("base64"),k=C.length+C.length/64+18+16+E.length*2+10,A=n.alloc(k),D=0;D+=A.write("-----BEGIN "+E+`-----
`,D);for(var P=0;P<C.length;){var R=P+64;R>C.length&&(R=C.length),D+=A.write(C.slice(P,R),D),A[D++]=10,P=R}return D+=A.write("-----END "+E+`-----
`,D),A.slice(0,D)}return x509Pem}var certificate,hasRequiredCertificate;function requireCertificate(){if(hasRequiredCertificate)return certificate;hasRequiredCertificate=1,certificate=P;var t=requireAssert(),e=requireSafer().Buffer,n=requireAlgs(),o=requireCryptoBrowserify(),u=requireFingerprint();requireSignature();var l=requireErrors$1(),m=requireUtils$2(),y=requireKey(),E=requirePrivateKey(),C=requireIdentity(),k={};k.openssh=requireOpensshCert(),k.x509=requireX509(),k.pem=requireX509Pem();var A=l.CertificateParseError,D=l.InvalidAlgorithmError;function P(R){t.object(R,"options"),t.arrayOfObject(R.subjects,"options.subjects"),m.assertCompatible(R.subjects[0],C,[1,0],"options.subjects"),m.assertCompatible(R.subjectKey,y,[1,0],"options.subjectKey"),m.assertCompatible(R.issuer,C,[1,0],"options.issuer"),R.issuerKey!==void 0&&m.assertCompatible(R.issuerKey,y,[1,0],"options.issuerKey"),t.object(R.signatures,"options.signatures"),t.buffer(R.serial,"options.serial"),t.date(R.validFrom,"options.validFrom"),t.date(R.validUntil,"optons.validUntil"),t.optionalArrayOfString(R.purposes,"options.purposes"),this._hashCache={},this.subjects=R.subjects,this.issuer=R.issuer,this.subjectKey=R.subjectKey,this.issuerKey=R.issuerKey,this.signatures=R.signatures,this.serial=R.serial,this.validFrom=R.validFrom,this.validUntil=R.validUntil,this.purposes=R.purposes}return P.formats=k,P.prototype.toBuffer=function(R,B){return R===void 0&&(R="x509"),t.string(R,"format"),t.object(k[R],"formats[format]"),t.optionalObject(B,"options"),k[R].write(this,B)},P.prototype.toString=function(R,B){return R===void 0&&(R="pem"),this.toBuffer(R,B).toString()},P.prototype.fingerprint=function(R){R===void 0&&(R="sha256"),t.string(R,"algorithm");var B={type:"certificate",hash:this.hash(R),algorithm:R};return new u(B)},P.prototype.hash=function(R){if(t.string(R,"algorithm"),R=R.toLowerCase(),n.hashAlgs[R]===void 0)throw new D(R);if(this._hashCache[R])return this._hashCache[R];var B=o.createHash(R).update(this.toBuffer("x509")).digest();return this._hashCache[R]=B,B},P.prototype.isExpired=function(R){return R===void 0&&(R=new Date),!(R.getTime()>=this.validFrom.getTime()&&R.getTime()<this.validUntil.getTime())},P.prototype.isSignedBy=function(R){return m.assertCompatible(R,P,[1,0],"issuer"),!this.issuer.equals(R.subjects[0])||this.issuer.purposes&&this.issuer.purposes.length>0&&this.issuer.purposes.indexOf("ca")===-1?!1:this.isSignedByKey(R.subjectKey)},P.prototype.getExtension=function(R){t.string(R,"keyOrOid");var B=this.getExtensions().filter(function(F){return F.format==="x509"?F.oid===R:F.format==="openssh"?F.name===R:!1})[0];return B},P.prototype.getExtensions=function(){var R=[],B=this.signatures.x509;B&&B.extras&&B.extras.exts&&B.extras.exts.forEach(function(j){j.format="x509",R.push(j)});var F=this.signatures.openssh;return F&&F.exts&&F.exts.forEach(function(j){j.format="openssh",R.push(j)}),R},P.prototype.isSignedByKey=function(R){if(m.assertCompatible(R,y,[1,2],"issuerKey"),this.issuerKey!==void 0)return this.issuerKey.fingerprint("sha512").matches(R);var B=Object.keys(this.signatures)[0],F=k[B].verify(this,R);return F&&(this.issuerKey=R),F},P.prototype.signWith=function(R){m.assertCompatible(R,E,[1,2],"key");for(var B=Object.keys(k),F=!1,j=0;j<B.length;++j)if(B[j]!=="pem"){var N=k[B[j]].sign(this,R);N===!0&&(F=!0)}if(!F)throw new Error("Failed to sign the certificate for any available certificate formats")},P.createSelfSigned=function(R,B,F){var j;Array.isArray(R)?j=R:j=[R],t.arrayOfObject(j),j.forEach(function(ke){m.assertCompatible(ke,C,[1,0],"subject")}),m.assertCompatible(B,E,[1,2],"private key"),t.optionalObject(F,"options"),F===void 0&&(F={}),t.optionalObject(F.validFrom,"options.validFrom"),t.optionalObject(F.validUntil,"options.validUntil");var N=F.validFrom,Y=F.validUntil;if(N===void 0&&(N=new Date),Y===void 0){t.optionalNumber(F.lifetime,"options.lifetime");var J=F.lifetime;J===void 0&&(J=10*365*24*3600),Y=new Date,Y.setTime(Y.getTime()+J*1e3)}t.optionalBuffer(F.serial,"options.serial");var ie=F.serial;ie===void 0&&(ie=e.from("0000000000000001","hex"));var ue=F.purposes;if(ue===void 0&&(ue=[]),ue.indexOf("signature")===-1&&ue.push("signature"),ue.indexOf("ca")===-1&&ue.push("ca"),ue.indexOf("crl")===-1&&ue.push("crl"),ue.length<=3){var Q=j.filter(function(ke){return ke.type==="host"}),ce=j.filter(function(ke){return ke.type==="user"});Q.length>0&&ue.indexOf("serverAuth")===-1&&ue.push("serverAuth"),ce.length>0&&ue.indexOf("clientAuth")===-1&&ue.push("clientAuth"),(ce.length>0||Q.length>0)&&(ue.indexOf("keyAgreement")===-1&&ue.push("keyAgreement"),B.type==="rsa"&&ue.indexOf("encryption")===-1&&ue.push("encryption"))}var he=new P({subjects:j,issuer:j[0],subjectKey:B.toPublic(),issuerKey:B.toPublic(),signatures:{},serial:ie,validFrom:N,validUntil:Y,purposes:ue});return he.signWith(B),he},P.create=function(R,B,F,j,N){var Y;Array.isArray(R)?Y=R:Y=[R],t.arrayOfObject(Y),Y.forEach(function(d){m.assertCompatible(d,C,[1,0],"subject")}),m.assertCompatible(B,y,[1,0],"key"),E.isPrivateKey(B)&&(B=B.toPublic()),m.assertCompatible(F,C,[1,0],"issuer"),m.assertCompatible(j,E,[1,2],"issuer key"),t.optionalObject(N,"options"),N===void 0&&(N={}),t.optionalObject(N.validFrom,"options.validFrom"),t.optionalObject(N.validUntil,"options.validUntil");var J=N.validFrom,ie=N.validUntil;if(J===void 0&&(J=new Date),ie===void 0){t.optionalNumber(N.lifetime,"options.lifetime");var ue=N.lifetime;ue===void 0&&(ue=10*365*24*3600),ie=new Date,ie.setTime(ie.getTime()+ue*1e3)}t.optionalBuffer(N.serial,"options.serial");var Q=N.serial;Q===void 0&&(Q=e.from("0000000000000001","hex"));var ce=N.purposes;ce===void 0&&(ce=[]),ce.indexOf("signature")===-1&&ce.push("signature"),N.ca===!0&&(ce.indexOf("ca")===-1&&ce.push("ca"),ce.indexOf("crl")===-1&&ce.push("crl"));var he=Y.filter(function(d){return d.type==="host"}),ke=Y.filter(function(d){return d.type==="user"});he.length>0&&ce.indexOf("serverAuth")===-1&&ce.push("serverAuth"),ke.length>0&&ce.indexOf("clientAuth")===-1&&ce.push("clientAuth"),(ke.length>0||he.length>0)&&(ce.indexOf("keyAgreement")===-1&&ce.push("keyAgreement"),B.type==="rsa"&&ce.indexOf("encryption")===-1&&ce.push("encryption"));var L=new P({subjects:Y,issuer:F,subjectKey:B,issuerKey:j.toPublic(),signatures:{},serial:Q,validFrom:J,validUntil:ie,purposes:ce});return L.signWith(j),L},P.parse=function(R,B,F){typeof R!="string"&&t.buffer(R,"data"),B===void 0&&(B="auto"),t.string(B,"format"),typeof F=="string"&&(F={filename:F}),t.optionalObject(F,"options"),F===void 0&&(F={}),t.optionalString(F.filename,"options.filename"),F.filename===void 0&&(F.filename="(unnamed)"),t.object(k[B],"formats[format]");try{var j=k[B].read(R,F);return j}catch(N){throw new A(F.filename,B,N)}},P.isCertificate=function(R,B){return m.isCompatible(R,P,B)},P.prototype._sshpkApiVersion=[1,1],P._oldVersionDetect=function(R){return[1,0]},certificate}var fingerprint,hasRequiredFingerprint;function requireFingerprint(){if(hasRequiredFingerprint)return fingerprint;hasRequiredFingerprint=1,fingerprint=A;var t=requireAssert(),e=requireSafer().Buffer,n=requireAlgs(),o=requireCryptoBrowserify(),u=requireErrors$1(),l=requireKey(),m=requirePrivateKey(),y=requireCertificate(),E=requireUtils$2(),C=u.FingerprintFormatError,k=u.InvalidAlgorithmError;function A(j){if(t.object(j,"options"),t.string(j.type,"options.type"),t.buffer(j.hash,"options.hash"),t.string(j.algorithm,"options.algorithm"),this.algorithm=j.algorithm.toLowerCase(),n.hashAlgs[this.algorithm]!==!0)throw new k(this.algorithm);this.hash=j.hash,this.type=j.type,this.hashType=j.hashType}A.prototype.toString=function(j){switch(j===void 0&&(this.algorithm==="md5"||this.hashType==="spki"?j="hex":j="base64"),t.string(j),j){case"hex":return this.hashType==="spki"?this.hash.toString("hex"):R(this.hash.toString("hex"));case"base64":return this.hashType==="spki"?this.hash.toString("base64"):F(this.algorithm,this.hash.toString("base64"));default:throw new C(void 0,j)}},A.prototype.matches=function(j){t.object(j,"key or certificate"),this.type==="key"&&this.hashType!=="ssh"?(E.assertCompatible(j,l,[1,7],"key with spki"),m.isPrivateKey(j)&&E.assertCompatible(j,m,[1,6],"privatekey with spki support")):this.type==="key"?E.assertCompatible(j,l,[1,0],"key"):E.assertCompatible(j,y,[1,0],"certificate");var N=j.hash(this.algorithm,this.hashType),Y=o.createHash(this.algorithm).update(N).digest("base64");return this.hash2===void 0&&(this.hash2=o.createHash(this.algorithm).update(this.hash).digest("base64")),this.hash2===Y};var D=/^[A-Za-z0-9+\/=]+$/,P=/^[a-fA-F0-9]+$/;A.parse=function(j,N){t.string(j,"fingerprint");var Y,J,ie;Array.isArray(N)&&(ie=N,N={}),t.optionalObject(N,"options"),N===void 0&&(N={}),N.enAlgs!==void 0&&(ie=N.enAlgs),N.algorithms!==void 0&&(ie=N.algorithms),t.optionalArrayOfString(ie,"algorithms");var ue="ssh";N.hashType!==void 0&&(ue=N.hashType),t.string(ue,"options.hashType");var Q=j.split(":");if(Q.length==2){if(Y=Q[0].toLowerCase(),!D.test(Q[1]))throw new C(j);try{J=e.from(Q[1],"base64")}catch{throw new C(j)}}else if(Q.length>2){if(Y="md5",Q[0].toLowerCase()==="md5"&&(Q=Q.slice(1)),Q=Q.map(function(ce){for(;ce.length<2;)ce="0"+ce;if(ce.length>2)throw new C(j);return ce}),Q=Q.join(""),!P.test(Q)||Q.length%2!==0)throw new C(j);try{J=e.from(Q,"hex")}catch{throw new C(j)}}else{if(P.test(j))J=e.from(j,"hex");else if(D.test(j))J=e.from(j,"base64");else throw new C(j);switch(J.length){case 32:Y="sha256";break;case 16:Y="md5";break;case 20:Y="sha1";break;case 64:Y="sha512";break;default:throw new C(j)}N.hashType===void 0&&(ue="spki")}if(Y===void 0)throw new C(j);if(n.hashAlgs[Y]===void 0)throw new k(Y);if(ie!==void 0&&(ie=ie.map(function(ce){return ce.toLowerCase()}),ie.indexOf(Y)===-1))throw new k(Y);return new A({algorithm:Y,hash:J,type:N.type||"key",hashType:ue})};function R(j){return j.replace(/(.{2})(?=.)/g,"$1:")}function B(j){return j.replace(/=*$/,"")}function F(j,N){return j.toUpperCase()+":"+B(N)}return A.isFingerprint=function(j,N){return E.isCompatible(j,A,N)},A.prototype._sshpkApiVersion=[1,2],A._oldVersionDetect=function(j){return t.func(j.toString),t.func(j.matches),[1,0]},fingerprint}var key,hasRequiredKey;function requireKey(){if(hasRequiredKey)return key;hasRequiredKey=1,key=P;var t=requireAssert(),e=requireAlgs(),n=requireCryptoBrowserify(),o=requireFingerprint(),u=requireSignature(),l=requireDhe().DiffieHellman,m=requireErrors$1(),y=requireUtils$2(),E=requirePrivateKey(),C;try{C=requireEdCompat()}catch{}var k=m.InvalidAlgorithmError,A=m.KeyParseError,D={};D.auto=requireAuto(),D.pem=requirePem(),D.pkcs1=requirePkcs1(),D.pkcs8=requirePkcs8(),D.rfc4253=requireRfc4253(),D.ssh=requireSsh(),D["ssh-private"]=requireSshPrivate(),D.openssh=D["ssh-private"],D.dnssec=requireDnssec(),D.putty=requirePutty(),D.ppk=D.putty;function P(R){t.object(R,"options"),t.arrayOfObject(R.parts,"options.parts"),t.string(R.type,"options.type"),t.optionalString(R.comment,"options.comment");var B=e.info[R.type];if(typeof B!="object")throw new k(R.type);for(var F={},j=0;j<R.parts.length;++j){var N=R.parts[j];F[N.name]=N}this.type=R.type,this.parts=R.parts,this.part=F,this.comment=void 0,this.source=R.source,this._rfc4253Cache=R._rfc4253Cache,this._hashCache={};var Y;if(this.curve=void 0,this.type==="ecdsa"){var J=this.part.curve.data.toString();this.curve=J,Y=e.curves[J].size}else if(this.type==="ed25519"||this.type==="curve25519")Y=256,this.curve="curve25519";else{var ie=this.part[B.sizePart];Y=ie.data.length,Y=Y*8-y.countZeros(ie.data)}this.size=Y}return P.formats=D,P.prototype.toBuffer=function(R,B){return R===void 0&&(R="ssh"),t.string(R,"format"),t.object(D[R],"formats[format]"),t.optionalObject(B,"options"),R==="rfc4253"?(this._rfc4253Cache===void 0&&(this._rfc4253Cache=D.rfc4253.write(this)),this._rfc4253Cache):D[R].write(this,B)},P.prototype.toString=function(R,B){return this.toBuffer(R,B).toString()},P.prototype.hash=function(R,B){if(t.string(R,"algorithm"),t.optionalString(B,"type"),B===void 0&&(B="ssh"),R=R.toLowerCase(),e.hashAlgs[R]===void 0)throw new k(R);var F=R+"||"+B;if(this._hashCache[F])return this._hashCache[F];var j;if(B==="ssh")j=this.toBuffer("rfc4253");else if(B==="spki")j=D.pkcs8.pkcs8ToBuffer(this);else throw new Error("Hash type "+B+" not supported");var N=n.createHash(R).update(j).digest();return this._hashCache[F]=N,N},P.prototype.fingerprint=function(R,B){R===void 0&&(R="sha256"),B===void 0&&(B="ssh"),t.string(R,"algorithm"),t.string(B,"type");var F={type:"key",hash:this.hash(R,B),algorithm:R,hashType:B};return new o(F)},P.prototype.defaultHashAlgorithm=function(){var R="sha1";return this.type==="rsa"&&(R="sha256"),this.type==="dsa"&&this.size>1024&&(R="sha256"),this.type==="ed25519"&&(R="sha512"),this.type==="ecdsa"&&(this.size<=256?R="sha256":this.size<=384?R="sha384":R="sha512"),R},P.prototype.createVerify=function(R){if(R===void 0&&(R=this.defaultHashAlgorithm()),t.string(R,"hash algorithm"),this.type==="ed25519"&&C!==void 0)return new C.Verifier(this,R);if(this.type==="curve25519")throw new Error("Curve25519 keys are not suitable for signing or verification");var B,F,j;try{F=R.toUpperCase(),B=n.createVerify(F)}catch(ue){j=ue}(B===void 0||j instanceof Error&&j.message.match(/Unknown message digest/))&&(F="RSA-",F+=R.toUpperCase(),B=n.createVerify(F)),t.ok(B,"failed to create verifier");var N=B.verify.bind(B),Y=this.toBuffer("pkcs8"),J=this.curve,ie=this;return B.verify=function(ue,Q){if(u.isSignature(ue,[2,0]))return ue.type!==ie.type||ue.hashAlgorithm&&ue.hashAlgorithm!==R||ue.curve&&ie.type==="ecdsa"&&ue.curve!==J?!1:N(Y,ue.toBuffer("asn1"));if(typeof ue=="string"||Buffer$C.isBuffer(ue))return N(Y,ue,Q);throw u.isSignature(ue,[1,0])?new Error("signature was created by too old a version of sshpk and cannot be verified"):new TypeError("signature must be a string, Buffer, or Signature object")},B},P.prototype.createDiffieHellman=function(){if(this.type==="rsa")throw new Error("RSA keys do not support Diffie-Hellman");return new l(this)},P.prototype.createDH=P.prototype.createDiffieHellman,P.parse=function(R,B,F){typeof R!="string"&&t.buffer(R,"data"),B===void 0&&(B="auto"),t.string(B,"format"),typeof F=="string"&&(F={filename:F}),t.optionalObject(F,"options"),F===void 0&&(F={}),t.optionalString(F.filename,"options.filename"),F.filename===void 0&&(F.filename="(unnamed)"),t.object(D[B],"formats[format]");try{var j=D[B].read(R,F);return j instanceof E&&(j=j.toPublic()),j.comment||(j.comment=F.filename),j}catch(N){throw N.name==="KeyEncryptedError"?N:new A(F.filename,B,N)}},P.isKey=function(R,B){return y.isCompatible(R,P,B)},P.prototype._sshpkApiVersion=[1,7],P._oldVersionDetect=function(R){return t.func(R.toBuffer),t.func(R.fingerprint),R.createDH?[1,4]:R.defaultHashAlgorithm?[1,3]:R.formats.auto?[1,2]:R.formats.pkcs1?[1,1]:[1,0]},key}var lib$3,hasRequiredLib$3;function requireLib$3(){if(hasRequiredLib$3)return lib$3;hasRequiredLib$3=1;var t=requireKey(),e=requireFingerprint(),n=requireSignature(),o=requirePrivateKey(),u=requireCertificate(),l=requireIdentity(),m=requireErrors$1();return lib$3={Key:t,parseKey:t.parse,Fingerprint:e,parseFingerprint:e.parse,Signature:n,parseSignature:n.parse,PrivateKey:o,parsePrivateKey:o.parse,generatePrivateKey:o.generate,Certificate:u,parseCertificate:u.parse,createSelfSignedCertificate:u.createSelfSigned,createCertificate:u.create,Identity:l,identityFromDN:l.parseDN,identityForHost:l.forHost,identityForUser:l.forUser,identityForEmail:l.forEmail,identityFromArray:l.fromArray,FingerprintFormatError:m.FingerprintFormatError,InvalidAlgorithmError:m.InvalidAlgorithmError,KeyParseError:m.KeyParseError,SignatureParseError:m.SignatureParseError,KeyEncryptedError:m.KeyEncryptedError,CertificateParseError:m.CertificateParseError},lib$3}var utils$1,hasRequiredUtils$1;function requireUtils$1(){if(hasRequiredUtils$1)return utils$1;hasRequiredUtils$1=1;var t=requireAssert(),e=requireLib$3(),n=util$6,o={sha1:!0,sha256:!0,sha512:!0},u={rsa:!0,dsa:!0,ecdsa:!0};function l(E,C){Error.captureStackTrace&&Error.captureStackTrace(this,C||l),this.message=E,this.name=C.name}n.inherits(l,Error);function m(E){l.call(this,E,m)}n.inherits(m,l);function y(E){var C=E.toLowerCase().split("-");if(C.length!==2)throw new m(C[0].toUpperCase()+" is not a valid algorithm");if(C[0]!=="hmac"&&!u[C[0]])throw new m(C[0].toUpperCase()+" type keys are not supported");if(!o[C[1]])throw new m(C[1].toUpperCase()+" is not a supported hash algorithm");return C}return utils$1={HASH_ALGOS:o,PK_ALGOS:u,HttpSignatureError:l,InvalidAlgorithmError:m,validateAlgorithm:y,sshKeyToPEM:function(C){t.string(C,"ssh_key");var k=e.parseKey(C,"ssh");return k.toString("pem")},fingerprint:function(C){t.string(C,"ssh_key");var k=e.parseKey(C,"ssh");return k.fingerprint("md5").toString("hex")},pemToRsaSSHKey:function(C,k){t.equal("string",typeof C,"typeof pem");var A=e.parseKey(C,"pem");return A.comment=k,A.toString("ssh")}},utils$1}var parser,hasRequiredParser;function requireParser(){if(hasRequiredParser)return parser;hasRequiredParser=1;var t=requireAssert(),e=util$6,n=requireUtils$1();n.HASH_ALGOS,n.PK_ALGOS;var o=n.HttpSignatureError,u=n.InvalidAlgorithmError,l=n.validateAlgorithm,m={New:0,Params:1},y={Name:0,Quote:1,Value:2,Comma:3};function E(P){o.call(this,P,E)}e.inherits(E,o);function C(P){o.call(this,P,C)}e.inherits(C,o);function k(P){o.call(this,P,k)}e.inherits(k,o);function A(P){o.call(this,P,A)}e.inherits(A,o);function D(P){o.call(this,P,D)}return e.inherits(D,o),parser={parseRequest:function(R,B){t.object(R,"request"),t.object(R.headers,"request.headers"),B===void 0&&(B={}),B.headers===void 0&&(B.headers=[R.headers["x-date"]?"x-date":"date"]),t.object(B,"options"),t.arrayOfString(B.headers,"options.headers"),t.optionalFinite(B.clockSkew,"options.clockSkew");var F=B.authorizationHeaderName||"authorization";if(!R.headers[F])throw new A("no "+F+" header present in the request");B.clockSkew=B.clockSkew||300;var j=0,N=m.New,Y=y.Name,J="",ie="",ue={scheme:"",params:{},signingString:""},Q=R.headers[F];for(j=0;j<Q.length;j++){var ce=Q.charAt(j);switch(Number(N)){case m.New:ce!==" "?ue.scheme+=ce:N=m.Params;break;case m.Params:switch(Number(Y)){case y.Name:var he=ce.charCodeAt(0);if(he>=65&&he<=90||he>=97&&he<=122)J+=ce;else if(ce==="="){if(J.length===0)throw new C("bad param format");Y=y.Quote}else throw new C("bad param format");break;case y.Quote:if(ce==='"')ie="",Y=y.Value;else throw new C("bad param format");break;case y.Value:ce==='"'?(ue.params[J]=ie,Y=y.Comma):ie+=ce;break;case y.Comma:if(ce===",")J="",Y=y.Name;else throw new C("bad param format");break;default:throw new Error("Invalid substate")}break;default:throw new Error("Invalid substate")}}if(!ue.params.headers||ue.params.headers===""?R.headers["x-date"]?ue.params.headers=["x-date"]:ue.params.headers=["date"]:ue.params.headers=ue.params.headers.split(" "),!ue.scheme||ue.scheme!=="Signature")throw new C('scheme was not "Signature"');if(!ue.params.keyId)throw new C("keyId was not specified");if(!ue.params.algorithm)throw new C("algorithm was not specified");if(!ue.params.signature)throw new C("signature was not specified");ue.params.algorithm=ue.params.algorithm.toLowerCase();try{l(ue.params.algorithm)}catch(c){throw c instanceof u?new k(ue.params.algorithm+" is not supported"):c}for(j=0;j<ue.params.headers.length;j++){var ke=ue.params.headers[j].toLowerCase();if(ue.params.headers[j]=ke,ke==="request-line")if(!B.strict)ue.signingString+=R.method+" "+R.url+" HTTP/"+R.httpVersion;else throw new D("request-line is not a valid header with strict parsing enabled.");else if(ke==="(request-target)")ue.signingString+="(request-target): "+R.method.toLowerCase()+" "+R.url;else{var L=R.headers[ke];if(L===void 0)throw new A(ke+" was not in the request");ue.signingString+=ke+": "+L}j+1<ue.params.headers.length&&(ue.signingString+=`
`)}var d;if(R.headers.date||R.headers["x-date"]){R.headers["x-date"]?d=new Date(R.headers["x-date"]):d=new Date(R.headers.date);var v=new Date,w=Math.abs(v.getTime()-d.getTime());if(w>B.clockSkew*1e3)throw new E("clock skew of "+w/1e3+"s was greater than "+B.clockSkew+"s")}if(B.headers.forEach(function(c){if(ue.params.headers.indexOf(c.toLowerCase())<0)throw new A(c+" was not a signed header")}),B.algorithms&&B.algorithms.indexOf(ue.params.algorithm)===-1)throw new k(ue.params.algorithm+" is not a supported algorithm");return ue.algorithm=ue.params.algorithm.toUpperCase(),ue.keyId=ue.params.keyId,ue}},parser}var jsprim={},extsprintf={},hasRequiredExtsprintf;function requireExtsprintf(){if(hasRequiredExtsprintf)return extsprintf;hasRequiredExtsprintf=1;var t=requireAssert$1(),e=util$6;extsprintf.sprintf=n,extsprintf.printf=o,extsprintf.fprintf=u;function n(y){var E=["([^%]*)","%","(['\\-+ #0]*?)","([1-9]\\d*)?","(\\.([1-9]\\d*))?","[lhjztL]*?","([diouxXfFeEgGaAcCsSp%jr])"].join(""),C=new RegExp(E),k=Array.prototype.slice.call(arguments,1),A,D,P,R,B,F,j,N,Y,J="",ie=1;for(t.equal("string",typeof y);(Y=C.exec(y))!==null;){if(J+=Y[1],y=y.substring(Y[0].length),A=Y[2]||"",D=Y[3]||0,P=Y[4]||"",R=Y[6],B=!1,j=!1,F=" ",R=="%"){J+="%";continue}if(k.length===0)throw new Error("too few args to sprintf");if(N=k.shift(),ie++,A.match(/[\' #]/))throw new Error("unsupported flags: "+A);if(P.length>0)throw new Error("non-zero precision not supported");switch(A.match(/-/)&&(B=!0),A.match(/0/)&&(F="0"),A.match(/\+/)&&(j=!0),R){case"s":if(N==null)throw new Error("argument "+ie+": attempted to print undefined or null as a string");J+=l(F,D,B,N.toString());break;case"d":N=Math.floor(N);case"f":j=j&&N>0?"+":"",J+=j+l(F,D,B,N.toString());break;case"x":J+=l(F,D,B,N.toString(16));break;case"j":D===0&&(D=10),J+=e.inspect(N,!1,D);break;case"r":J+=m(N);break;default:throw new Error("unsupported conversion: "+R)}}return J+=y,J}function o(){var y=Array.prototype.slice.call(arguments);y.unshift(process$1.stdout),u.apply(null,y)}function u(y){var E=Array.prototype.slice.call(arguments,1);return y.write(n.apply(this,E))}function l(y,E,C,k){for(var A=k;A.length<E;)C?A+=y:A=y+A;return A}function m(y){var E;if(!(y instanceof Error))throw new Error(n("invalid type for %%r: %j",y));if(E="EXCEPTION: "+y.constructor.name+": "+y.stack,y.cause&&typeof y.cause=="function"){var C=y.cause();C&&(E+=`
Caused by: `+m(C))}return E}return extsprintf}var verror,hasRequiredVerror;function requireVerror(){if(hasRequiredVerror)return verror;hasRequiredVerror=1;var t=requireAssert(),e=util$6,n=requireExtsprintf(),o=util$3.isError,u=n.sprintf;verror=m,m.VError=m,m.SError=y,m.WError=C,m.MultiError=E;function l(k){var A,D,P,R,B;if(t.object(k,"args"),t.bool(k.strict,"args.strict"),t.array(k.argv,"args.argv"),A=k.argv,A.length===0)D={},P=[];else if(o(A[0]))D={cause:A[0]},P=A.slice(1);else if(typeof A[0]=="object"){D={};for(B in A[0])D[B]=A[0][B];P=A.slice(1)}else t.string(A[0],"first argument to VError, SError, or WError constructor must be a string, object, or Error"),D={},P=A;return t.object(D),!D.strict&&!k.strict&&(P=P.map(function(F){return F===null?"null":F===void 0?"undefined":F})),P.length===0?R="":R=u.apply(null,P),{options:D,shortmessage:R}}function m(){var k,A,D,P,R,B,F;if(k=Array.prototype.slice.call(arguments,0),!(this instanceof m))return A=Object.create(m.prototype),m.apply(A,arguments),A;if(D=l({argv:k,strict:!1}),D.options.name&&(t.string(D.options.name,`error's "name" must be a string`),this.name=D.options.name),this.jse_shortmsg=D.shortmessage,B=D.shortmessage,P=D.options.cause,P&&(t.ok(o(P),"cause is not an Error"),this.jse_cause=P,D.options.skipCauseMessage||(B+=": "+P.message)),this.jse_info={},D.options.info)for(F in D.options.info)this.jse_info[F]=D.options.info[F];return this.message=B,Error.call(this,B),Error.captureStackTrace&&(R=D.options.constructorOpt||this.constructor,Error.captureStackTrace(this,R)),this}e.inherits(m,Error),m.prototype.name="VError",m.prototype.toString=function(){var A=this.hasOwnProperty("name")&&this.name||this.constructor.name||this.constructor.prototype.name;return this.message&&(A+=": "+this.message),A},m.prototype.cause=function(){var A=m.cause(this);return A===null?void 0:A},m.cause=function(k){return t.ok(o(k),"err must be an Error"),o(k.jse_cause)?k.jse_cause:null},m.info=function(k){var A,D,P;if(t.ok(o(k),"err must be an Error"),D=m.cause(k),D!==null?A=m.info(D):A={},typeof k.jse_info=="object"&&k.jse_info!==null)for(P in k.jse_info)A[P]=k.jse_info[P];return A},m.findCauseByName=function(k,A){var D;for(t.ok(o(k),"err must be an Error"),t.string(A,"name"),t.ok(A.length>0,"name cannot be empty"),D=k;D!==null;D=m.cause(D))if(t.ok(o(D)),D.name==A)return D;return null},m.hasCauseWithName=function(k,A){return m.findCauseByName(k,A)!==null},m.fullStack=function(k){t.ok(o(k),"err must be an Error");var A=m.cause(k);return A?k.stack+`
caused by: `+m.fullStack(A):k.stack},m.errorFromList=function(k){return t.arrayOfObject(k,"errors"),k.length===0?null:(k.forEach(function(A){t.ok(o(A))}),k.length==1?k[0]:new E(k))},m.errorForEach=function(k,A){t.ok(o(k),"err must be an Error"),t.func(A,"func"),k instanceof E?k.errors().forEach(function(P){A(P)}):A(k)};function y(){var k,A,D,P;return k=Array.prototype.slice.call(arguments,0),this instanceof y?(D=l({argv:k,strict:!0}),P=D.options,m.call(this,P,"%s",D.shortmessage),this):(A=Object.create(y.prototype),y.apply(A,arguments),A)}e.inherits(y,m);function E(k){t.array(k,"list of errors"),t.ok(k.length>0,"must be at least one error"),this.ase_errors=k,m.call(this,{cause:k[0]},"first of %d error%s",k.length,k.length==1?"":"s")}e.inherits(E,m),E.prototype.name="MultiError",E.prototype.errors=function(){return this.ase_errors.slice(0)};function C(){var k,A,D,P;return k=Array.prototype.slice.call(arguments,0),this instanceof C?(D=l({argv:k,strict:!1}),P=D.options,P.skipCauseMessage=!0,m.call(this,P,"%s",D.shortmessage),this):(A=Object.create(C.prototype),C.apply(A,k),A)}return e.inherits(C,m),C.prototype.name="WError",C.prototype.toString=function(){var A=this.hasOwnProperty("name")&&this.name||this.constructor.name||this.constructor.prototype.name;return this.message&&(A+=": "+this.message),this.jse_cause&&this.jse_cause.message&&(A+="; caused by "+this.jse_cause.toString()),A},C.prototype.cause=function(A){return o(A)&&(this.jse_cause=A),this.jse_cause},verror}var validate$1={exports:{}},hasRequiredValidate$1;function requireValidate$1(){return hasRequiredValidate$1||(hasRequiredValidate$1=1,function(t){(function(e,n){t.exports?t.exports=n():e.jsonSchema=n()})(commonjsGlobal$1,function(){var e=o;e.Integer={type:"integer"};var n={String,Boolean,Number,Object,Array,Date};e.validate=o;function o(u,l){return o(u,l,{changing:!1})}e.checkPropertyChange=function(u,l,m){return o(u,l,{changing:m||"property"})};var o=e._validate=function(u,l,m){m||(m={});var y=m.changing;function E(D){return D.type||n[D.name]==D&&D.name.toLowerCase()}var C=[];function k(D,P,R,B){var F;R+=R?typeof B=="number"?"["+B+"]":typeof B>"u"?"":"."+B:B;function j(ce){C.push({property:R,message:ce})}if((typeof P!="object"||P instanceof Array)&&(R||typeof P!="function")&&!(P&&E(P)))return typeof P=="function"?D instanceof P||j("is not an instance of the class/constructor "+P.name):P&&j("Invalid schema/property definition "+P),null;y&&P.readonly&&j("is a readonly field, it can not be changed"),P.extends&&k(D,P.extends,R,B);function N(ce,he){if(ce){if(typeof ce=="string"&&ce!="any"&&(ce=="null"?he!==null:typeof he!=ce)&&!(he instanceof Array&&ce=="array")&&!(he instanceof Date&&ce=="date")&&!(ce=="integer"&&he%1===0))return[{property:R,message:he+" - "+typeof he+" value found, but a "+ce+" is required"}];if(ce instanceof Array){for(var ke=[],L=0;L<ce.length&&(ke=N(ce[L],he)).length;L++);if(ke.length)return ke}else if(typeof ce=="object"){var d=C;C=[],k(he,ce,R);var v=C;return C=d,v}}return[]}if(D===void 0)P.required&&j("is missing and it is required");else if(C=C.concat(N(E(P),D)),P.disallow&&!N(P.disallow,D).length&&j(" disallowed value was matched"),D!==null){if(D instanceof Array){if(P.items){var Y=P.items instanceof Array,J=P.items;for(B=0,F=D.length;B<F;B+=1)Y&&(J=P.items[B]),m.coerce&&(D[B]=m.coerce(D[B],J)),C.concat(k(D[B],J,R,B))}P.minItems&&D.length<P.minItems&&j("There must be a minimum of "+P.minItems+" in the array"),P.maxItems&&D.length>P.maxItems&&j("There must be a maximum of "+P.maxItems+" in the array")}else(P.properties||P.additionalProperties)&&C.concat(A(D,P.properties,R,P.additionalProperties));if(P.pattern&&typeof D=="string"&&!D.match(P.pattern)&&j("does not match the regex pattern "+P.pattern),P.maxLength&&typeof D=="string"&&D.length>P.maxLength&&j("may only be "+P.maxLength+" characters long"),P.minLength&&typeof D=="string"&&D.length<P.minLength&&j("must be at least "+P.minLength+" characters long"),typeof P.minimum<"u"&&typeof D==typeof P.minimum&&P.minimum>D&&j("must have a minimum value of "+P.minimum),typeof P.maximum<"u"&&typeof D==typeof P.maximum&&P.maximum<D&&j("must have a maximum value of "+P.maximum),P.enum){var ie=P.enum;F=ie.length;for(var ue,Q=0;Q<F;Q++)if(ie[Q]===D){ue=1;break}ue||j("does not have a value in the enumeration "+ie.join(", "))}typeof P.maxDecimal=="number"&&D.toString().match(new RegExp("\\.[0-9]{"+(P.maxDecimal+1)+",}"))&&j("may only have "+P.maxDecimal+" digits of decimal places")}return null}function A(D,P,R,B){if(typeof P=="object"){(typeof D!="object"||D instanceof Array)&&C.push({property:R,message:"an object is required"});for(var F in P)if(P.hasOwnProperty(F)&&F!="__proto__"&&F!="constructor"){var j=D.hasOwnProperty(F)?D[F]:void 0;if(j===void 0&&m.existingOnly)continue;var N=P[F];j===void 0&&N.default&&(j=D[F]=N.default),m.coerce&&F in D&&(j=D[F]=m.coerce(j,N)),k(j,N,R,F)}}for(F in D){if(D.hasOwnProperty(F)&&!(F.charAt(0)=="_"&&F.charAt(1)=="_")&&P&&!P[F]&&B===!1)if(m.filter){delete D[F];continue}else C.push({property:R,message:"The property "+F+" is not defined in the schema and the schema does not allow additional properties"});var Y=P&&P[F]&&P[F].requires;Y&&!(Y in D)&&C.push({property:R,message:"the presence of the property "+F+" requires that "+Y+" also be present"}),j=D[F],B&&(!(P&&typeof P=="object")||!(F in P))&&(m.coerce&&(j=D[F]=m.coerce(j,B)),k(j,B,R,F)),!y&&j&&j.$schema&&(C=C.concat(k(j,j.$schema,R,F)))}return C}return l&&k(u,l,"",y||""),!y&&u&&u.$schema&&k(u,u.$schema,"",""),{valid:!C.length,errors:C}};return e.mustBeValid=function(u){if(!u.valid)throw new TypeError(u.errors.map(function(l){return"for property "+l.property+": "+l.message}).join(`, 
`))},e})}(validate$1)),validate$1.exports}var hasRequiredJsprim;function requireJsprim(){if(hasRequiredJsprim)return jsprim;hasRequiredJsprim=1;var t=requireAssert(),e=requireExtsprintf(),n=requireVerror(),o=requireValidate$1();jsprim.deepCopy=u,jsprim.deepEqual=l,jsprim.isEmpty=m,jsprim.hasKey=y,jsprim.forEachKey=E,jsprim.pluck=C,jsprim.flattenObject=P,jsprim.flattenIter=A,jsprim.validateJsonObject=ne,jsprim.validateJsonObjectJS=ne,jsprim.randElt=fe,jsprim.extraProperties=nt,jsprim.mergeObjects=Je,jsprim.startsWith=R,jsprim.endsWith=B,jsprim.parseInteger=ee,jsprim.iso8601=F,jsprim.rfc1123=Y,jsprim.parseDateTime=J,jsprim.hrtimediff=de,jsprim.hrtimeDiff=de,jsprim.hrtimeAccum=ot,jsprim.hrtimeAdd=Ct,jsprim.hrtimeNanosec=je,jsprim.hrtimeMicrosec=lt,jsprim.hrtimeMillisec=it;function u(tt){var rt,ht,Ot="__deepCopy";if(tt&&tt[Ot])throw new Error("attempted deep copy of cyclic object");if(tt&&tt.constructor==Object){rt={},tt[Ot]=!0;for(ht in tt)ht!=Ot&&(rt[ht]=u(tt[ht]));return delete tt[Ot],rt}if(tt&&tt.constructor==Array){for(rt=[],tt[Ot]=!0,ht=0;ht<tt.length;ht++)rt.push(u(tt[ht]));return delete tt[Ot],rt}return tt}function l(tt,rt){if(typeof tt!=typeof rt)return!1;if(tt===null||rt===null||typeof tt!="object")return tt===rt;if(tt.constructor!=rt.constructor)return!1;var ht;for(ht in tt)if(!rt.hasOwnProperty(ht)||!l(tt[ht],rt[ht]))return!1;for(ht in rt)if(!tt.hasOwnProperty(ht))return!1;return!0}function m(tt){var rt;for(rt in tt)return!1;return!0}function y(tt,rt){return t.equal(typeof rt,"string"),Object.prototype.hasOwnProperty.call(tt,rt)}function E(tt,rt){for(var ht in tt)y(tt,ht)&&rt(ht,tt[ht])}function C(tt,rt){return t.equal(typeof rt,"string"),k(tt,rt)}function k(tt,rt){if(!(tt===null||typeof tt!="object")){if(tt.hasOwnProperty(rt))return tt[rt];var ht=rt.indexOf(".");if(ht!=-1){var Ot=rt.substr(0,ht);if(tt.hasOwnProperty(Ot))return k(tt[Ot],rt.substr(ht+1))}}}function A(tt,rt,ht){D(tt,rt,[],ht)}function D(tt,rt,ht,Ot){var Ve,We;if(rt===0){Ve=ht.slice(0),Ve.push(tt),Ot(Ve);return}t.ok(tt!==null),t.equal(typeof tt,"object"),t.equal(typeof rt,"number"),t.ok(rt>=0);for(We in tt)Ve=ht.slice(0),Ve.push(We),D(tt[We],rt-1,Ve,Ot)}function P(tt,rt){if(rt===0)return[tt];t.ok(tt!==null),t.equal(typeof tt,"object"),t.equal(typeof rt,"number"),t.ok(rt>=0);var ht=[],Ot;for(Ot in tt)P(tt[Ot],rt-1).forEach(function(Ve){ht.push([Ot].concat(Ve))});return ht}function R(tt,rt){return tt.substr(0,rt.length)==rt}function B(tt,rt){return tt.substr(tt.length-rt.length,rt.length)==rt}function F(tt){return typeof tt=="number"&&(tt=new Date(tt)),t.ok(tt.constructor===Date),e.sprintf("%4d-%02d-%02dT%02d:%02d:%02d.%03dZ",tt.getUTCFullYear(),tt.getUTCMonth()+1,tt.getUTCDate(),tt.getUTCHours(),tt.getUTCMinutes(),tt.getUTCSeconds(),tt.getUTCMilliseconds())}var j=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],N=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"];function Y(tt){return e.sprintf("%s, %02d %s %04d %02d:%02d:%02d GMT",N[tt.getUTCDay()],tt.getUTCDate(),j[tt.getUTCMonth()],tt.getUTCFullYear(),tt.getUTCHours(),tt.getUTCMinutes(),tt.getUTCSeconds())}function J(tt){var rt=+tt;return isNaN(rt)?new Date(tt):new Date(rt)}var ie=Number.MAX_SAFE_INTEGER||9007199254740991,ue=Number.MIN_SAFE_INTEGER||-9007199254740991,Q={base:10,allowSign:!0,allowPrefix:!1,allowTrailing:!1,allowImprecise:!1,trimWhitespace:!1,leadingZeroIsOctal:!1},ce=48,he=57,ke=65,L=66,d=79,v=84,w=88,c=90,p=97,x=98,S=111,b=116,h=120,T=122,M=48,O=55,V=87;function ee(tt,rt){t.string(tt,"str"),t.optionalObject(rt,"options");var ht=!1,Ot=Q;rt&&(ht=y(rt,"base"),Ot=Je(Ot,rt),t.number(Ot.base,"options.base"),t.ok(Ot.base>=2,"options.base >= 2"),t.ok(Ot.base<=36,"options.base <= 36"),t.bool(Ot.allowSign,"options.allowSign"),t.bool(Ot.allowPrefix,"options.allowPrefix"),t.bool(Ot.allowTrailing,"options.allowTrailing"),t.bool(Ot.allowImprecise,"options.allowImprecise"),t.bool(Ot.trimWhitespace,"options.trimWhitespace"),t.bool(Ot.leadingZeroIsOctal,"options.leadingZeroIsOctal"),Ot.leadingZeroIsOctal&&t.ok(!ht,'"base" and "leadingZeroIsOctal" are mutually exclusive'));var Ve,We=-1,Gt=Ot.base,wt,Et=1,Yt=0,Ce=0,te=tt.length;if(Ot.trimWhitespace)for(;Ce<te&&U(tt.charCodeAt(Ce));)++Ce;for(Ot.allowSign&&(tt[Ce]==="-"?(Ce+=1,Et=-1):tt[Ce]==="+"&&(Ce+=1)),tt[Ce]==="0"&&(Ot.allowPrefix&&(We=z(tt.charCodeAt(Ce+1)),We!==-1&&(!ht||We===Gt)&&(Gt=We,Ce+=2)),We===-1&&Ot.leadingZeroIsOctal&&(Gt=8)),wt=Ce;Ce<te&&(Ve=Z(tt.charCodeAt(Ce)),Ve!==-1&&Ve<Gt);++Ce)Yt*=Gt,Yt+=Ve;if(wt===Ce)return new Error("invalid number: "+JSON.stringify(tt));if(Ot.trimWhitespace)for(;Ce<te&&U(tt.charCodeAt(Ce));)++Ce;if(Ce<te&&!Ot.allowTrailing)return new Error("trailing characters after number: "+JSON.stringify(tt.slice(Ce)));if(Yt===0)return 0;var ye=Yt*Et;return!Ot.allowImprecise&&(Yt>ie||ye<ue)?new Error("number is outside of the supported range: "+JSON.stringify(tt.slice(wt,Ce))):ye}function Z(tt){return tt>=ce&&tt<=he?tt-M:tt>=ke&&tt<=c?tt-O:tt>=p&&tt<=T?tt-V:-1}function U(tt){return tt===32||tt>=9&&tt<=13||tt===160||tt===5760||tt===6158||tt>=8192&&tt<=8202||tt===8232||tt===8233||tt===8239||tt===8287||tt===12288||tt===65279}function z(tt){return tt===x||tt===L?2:tt===S||tt===d?8:tt===b||tt===v?10:tt===h||tt===w?16:-1}function ne(tt,rt){var ht=o.validate(rt,tt);if(ht.errors.length===0)return null;var Ot=ht.errors[0],Ve=Ot.property,We=Ot.message.toLowerCase(),Gt,wt;(Gt=We.indexOf("the property "))!=-1&&(wt=We.indexOf(" is not defined in the schema and the schema does not allow additional properties"))!=-1&&(Gt+=13,Ve===""?Ve=We.substr(Gt,wt-Gt):Ve=Ve+"."+We.substr(Gt,wt-Gt),We="unsupported property");var Et=new n.VError('property "%s": %s',Ve,We);return Et.jsv_details=Ot,Et}function fe(tt){return t.ok(Array.isArray(tt)&&tt.length>0,"randElt argument must be a non-empty array"),tt[Math.floor(Math.random()*tt.length)]}function me(tt){t.ok(tt[0]>=0&&tt[1]>=0,"negative numbers not allowed in hrtimes"),t.ok(tt[1]<1e9,"nanoseconds column overflow")}function de(tt,rt){me(tt),me(rt),t.ok(tt[0]>rt[0]||tt[0]==rt[0]&&tt[1]>=rt[1],"negative differences not allowed");var ht=[tt[0]-rt[0],0];return tt[1]>=rt[1]?ht[1]=tt[1]-rt[1]:(ht[0]--,ht[1]=1e9-(rt[1]-tt[1])),ht}function je(tt){return me(tt),Math.floor(tt[0]*1e9+tt[1])}function lt(tt){return me(tt),Math.floor(tt[0]*1e6+tt[1]/1e3)}function it(tt){return me(tt),Math.floor(tt[0]*1e3+tt[1]/1e6)}function ot(tt,rt){return me(tt),me(rt),tt[1]+=rt[1],tt[1]>=1e9&&(tt[0]++,tt[1]-=1e9),tt[0]+=rt[0],tt}function Ct(tt,rt){me(tt);var ht=[tt[0],tt[1]];return ot(ht,rt)}function nt(tt,rt){t.ok(typeof tt=="object"&&tt!==null,"obj argument must be a non-null object"),t.ok(Array.isArray(rt),"allowed argument must be an array of strings");for(var ht=0;ht<rt.length;ht++)t.ok(typeof rt[ht]=="string","allowed argument must be an array of strings");return Object.keys(tt).filter(function(Ot){return rt.indexOf(Ot)===-1})}function Je(tt,rt,ht){var Ot,Ve;if(Ot={},ht)for(Ve in ht)Ot[Ve]=ht[Ve];if(tt)for(Ve in tt)Ot[Ve]=tt[Ve];if(rt)for(Ve in rt)Ot[Ve]=rt[Ve];return Ot}return jsprim}var signer,hasRequiredSigner;function requireSigner(){if(hasRequiredSigner)return signer;hasRequiredSigner=1;var t=requireAssert(),e=requireCryptoBrowserify();requireStreamHttp();var n=util$6,o=requireLib$3(),u=requireJsprim(),l=requireUtils$1(),m=util$6.format,y=l.HASH_ALGOS,E=l.PK_ALGOS,C=l.InvalidAlgorithmError,k=l.HttpSignatureError,A=l.validateAlgorithm,D='Signature keyId="%s",algorithm="%s",headers="%s",signature="%s"';function P(F){k.call(this,F,P)}n.inherits(P,k);function R(F){k.call(this,F,R)}n.inherits(R,k);function B(F){t.object(F,"options");var j=[];if(F.algorithm!==void 0&&(t.string(F.algorithm,"options.algorithm"),j=A(F.algorithm)),this.rs_alg=j,F.sign!==void 0)t.func(F.sign,"options.sign"),this.rs_signFunc=F.sign;else if(j[0]==="hmac"&&F.key!==void 0){if(t.string(F.keyId,"options.keyId"),this.rs_keyId=F.keyId,typeof F.key!="string"&&!Buffer$C.isBuffer(F.key))throw new TypeError("options.key for HMAC must be a string or Buffer");this.rs_signer=e.createHmac(j[1].toUpperCase(),F.key),this.rs_signer.sign=function(){var Y=this.digest("base64");return{hashAlgorithm:j[1],toString:function(){return Y}}}}else if(F.key!==void 0){var N=F.key;if((typeof N=="string"||Buffer$C.isBuffer(N))&&(N=o.parsePrivateKey(N)),t.ok(o.PrivateKey.isPrivateKey(N,[1,2]),"options.key must be a sshpk.PrivateKey"),this.rs_key=N,t.string(F.keyId,"options.keyId"),this.rs_keyId=F.keyId,!E[N.type])throw new C(N.type.toUpperCase()+" type keys are not supported");if(j[0]!==void 0&&N.type!==j[0])throw new C("options.key must be a "+j[0].toUpperCase()+" key, was given a "+N.type.toUpperCase()+" key instead");this.rs_signer=N.createSign(j[1])}else throw new TypeError("options.sign (func) or options.key is required");this.rs_headers=[],this.rs_lines=[]}return B.prototype.writeHeader=function(F,j){if(t.string(F,"header"),F=F.toLowerCase(),t.string(j,"value"),this.rs_headers.push(F),this.rs_signFunc)this.rs_lines.push(F+": "+j);else{var N=F+": "+j;this.rs_headers.length>0&&(N=`
`+N),this.rs_signer.update(N)}return j},B.prototype.writeDateHeader=function(){return this.writeHeader("date",u.rfc1123(new Date))},B.prototype.writeTarget=function(F,j){t.string(F,"method"),t.string(j,"path"),F=F.toLowerCase(),this.writeHeader("(request-target)",F+" "+j)},B.prototype.sign=function(F){if(t.func(F,"callback"),this.rs_headers.length<1)throw new Error("At least one header must be signed");var j,N;if(this.rs_signFunc){var Y=this.rs_lines.join(`
`),J=this;this.rs_signFunc(Y,function(Q,ce){if(Q){F(Q);return}try{t.object(ce,"signature"),t.string(ce.keyId,"signature.keyId"),t.string(ce.algorithm,"signature.algorithm"),t.string(ce.signature,"signature.signature"),j=A(ce.algorithm),N=m(D,ce.keyId,ce.algorithm,J.rs_headers.join(" "),ce.signature)}catch(he){F(he);return}F(null,N)})}else{try{var ie=this.rs_signer.sign()}catch(Q){F(Q);return}j=(this.rs_alg[0]||this.rs_key.type)+"-"+ie.hashAlgorithm;var ue=ie.toString();N=m(D,this.rs_keyId,j,this.rs_headers.join(" "),ue),F(null,N)}},signer={isSigner:function(F){return typeof F=="object"&&F instanceof B},createSigner:function(j){return new B(j)},signRequest:function(j,N){t.object(j,"request"),t.object(N,"options"),t.optionalString(N.algorithm,"options.algorithm"),t.string(N.keyId,"options.keyId"),t.optionalArrayOfString(N.headers,"options.headers"),t.optionalString(N.httpVersion,"options.httpVersion"),j.getHeader("Date")||j.setHeader("Date",u.rfc1123(new Date)),N.headers||(N.headers=["date"]),N.httpVersion||(N.httpVersion="1.1");var Y=[];N.algorithm&&(N.algorithm=N.algorithm.toLowerCase(),Y=A(N.algorithm));var J,ie="";for(J=0;J<N.headers.length;J++){if(typeof N.headers[J]!="string")throw new TypeError("options.headers must be an array of Strings");var ue=N.headers[J].toLowerCase();if(ue==="request-line")if(!N.strict)ie+=j.method+" "+j.path+" HTTP/"+N.httpVersion;else throw new R("request-line is not a valid header with strict parsing enabled.");else if(ue==="(request-target)")ie+="(request-target): "+j.method.toLowerCase()+" "+j.path;else{var Q=j.getHeader(ue);if(Q===void 0||Q==="")throw new P(ue+" was not in the request");ie+=ue+": "+Q}J+1<N.headers.length&&(ie+=`
`)}j.hasOwnProperty("_stringToSign")&&(j._stringToSign=ie);var ce;if(Y[0]==="hmac"){if(typeof N.key!="string"&&!Buffer$C.isBuffer(N.key))throw new TypeError("options.key must be a string or Buffer");var he=e.createHmac(Y[1].toUpperCase(),N.key);he.update(ie),ce=he.digest("base64")}else{var ke=N.key;if((typeof ke=="string"||Buffer$C.isBuffer(ke))&&(ke=o.parsePrivateKey(N.key)),t.ok(o.PrivateKey.isPrivateKey(ke,[1,2]),"options.key must be a sshpk.PrivateKey"),!E[ke.type])throw new C(ke.type.toUpperCase()+" type keys are not supported");if(Y[0]!==void 0&&ke.type!==Y[0])throw new C("options.key must be a "+Y[0].toUpperCase()+" key, was given a "+ke.type.toUpperCase()+" key instead");var L=ke.createSign(Y[1]);L.update(ie);var d=L.sign();if(!y[d.hashAlgorithm])throw new C(d.hashAlgorithm.toUpperCase()+" is not a supported hash algorithm");N.algorithm=ke.type+"-"+d.hashAlgorithm,ce=d.toString(),t.notStrictEqual(ce,"","empty signature produced")}var v=N.authorizationHeaderName||"Authorization";return j.setHeader(v,m(D,N.keyId,N.algorithm,N.headers.join(" "),ce)),!0}},signer}var verify,hasRequiredVerify;function requireVerify(){if(hasRequiredVerify)return verify;hasRequiredVerify=1;var t=requireAssert(),e=requireCryptoBrowserify(),n=requireLib$3(),o=requireUtils$1();o.HASH_ALGOS,o.PK_ALGOS,o.InvalidAlgorithmError,o.HttpSignatureError;var u=o.validateAlgorithm;return verify={verifySignature:function(m,y){t.object(m,"parsedSignature"),(typeof y=="string"||Buffer$C.isBuffer(y))&&(y=n.parseKey(y)),t.ok(n.Key.isKey(y,[1,1]),"pubkey must be a sshpk.Key");var E=u(m.algorithm);if(E[0]==="hmac"||E[0]!==y.type)return!1;var C=y.createVerify(E[1]);return C.update(m.signingString),C.verify(m.params.signature,"base64")},verifyHMAC:function(m,y){t.object(m,"parsedHMAC"),t.string(y,"secret");var E=u(m.algorithm);if(E[0]!=="hmac")return!1;var C=E[1].toUpperCase(),k=e.createHmac(C,y);k.update(m.signingString);var A=e.createHmac(C,y);A.update(k.digest()),A=A.digest();var D=e.createHmac(C,y);return D.update(new Buffer$C(m.params.signature,"base64")),D=D.digest(),typeof A=="string"?A===D:Buffer$C.isBuffer(A)&&!A.equals?A.toString("binary")===D.toString("binary"):A.equals(D)}},verify}var lib$2,hasRequiredLib$2;function requireLib$2(){if(hasRequiredLib$2)return lib$2;hasRequiredLib$2=1;var t=requireParser(),e=requireSigner(),n=requireVerify(),o=requireUtils$1();return lib$2={parse:t.parseRequest,parseRequest:t.parseRequest,sign:e.signRequest,signRequest:e.signRequest,createSigner:e.createSigner,isSigner:e.isSigner,sshKeyToPEM:o.sshKeyToPEM,sshKeyFingerprint:o.fingerprint,pemToRsaSSHKey:o.pemToRsaSSHKey,verify:n.verifySignature,verifySignature:n.verifySignature,verifyHMAC:n.verifyHMAC},lib$2}var caseless={exports:{}},hasRequiredCaseless;function requireCaseless(){if(hasRequiredCaseless)return caseless.exports;hasRequiredCaseless=1;function t(e){this.dict=e||{}}return t.prototype.set=function(e,n,o){if(typeof e=="object")for(var u in e)this.set(u,e[u],n);else{typeof o>"u"&&(o=!0);var l=this.has(e);return!o&&l?this.dict[l]=this.dict[l]+","+n:this.dict[l||e]=n,l}},t.prototype.has=function(o){for(var n=Object.keys(this.dict),o=o.toLowerCase(),u=0;u<n.length;u++)if(n[u].toLowerCase()===o)return n[u];return!1},t.prototype.get=function(e){e=e.toLowerCase();var n,o,u=this.dict;return Object.keys(u).forEach(function(l){o=l.toLowerCase(),e===o&&(n=u[l])}),n},t.prototype.swap=function(e){var n=this.has(e);if(n!==e){if(!n)throw new Error('There is no header than matches "'+e+'"');this.dict[e]=this.dict[n],delete this.dict[n]}},t.prototype.del=function(e){var n=this.has(e);return delete this.dict[n||e]},caseless.exports=function(e){return new t(e)},caseless.exports.httpify=function(e,n){var o=new t(n);return e.setHeader=function(u,l,m){if(!(typeof l>"u"))return o.set(u,l,m)},e.hasHeader=function(u){return o.has(u)},e.getHeader=function(u){return o.get(u)},e.removeHeader=function(u){return o.del(u)},e.headers=o.dict,o},caseless.exports}var foreverAgent,hasRequiredForeverAgent;function requireForeverAgent(){if(hasRequiredForeverAgent)return foreverAgent;hasRequiredForeverAgent=1,foreverAgent=m,m.SSL=y;var t=util$6,e=requireStreamHttp().Agent,n=require$$1$5,o=require$$1$5,u=requireHttpsBrowserify().Agent;function l(C,k){var A="";return typeof C=="string"?A=C+":"+k:A=C.host+":"+C.port+":"+(C.localAddress?C.localAddress+":":":"),A}function m(C){var k=this;k.options=C||{},k.requests={},k.sockets={},k.freeSockets={},k.maxSockets=k.options.maxSockets||e.defaultMaxSockets,k.minSockets=k.options.minSockets||m.defaultMinSockets,k.on("free",function(A,D,P){var R=l(D,P);if(k.requests[R]&&k.requests[R].length)k.requests[R].shift().onSocket(A);else if(k.sockets[R].length<k.minSockets){k.freeSockets[R]||(k.freeSockets[R]=[]),k.freeSockets[R].push(A);var B=function(){A.destroy()};A._onIdleError=B,A.on("error",B)}else A.destroy()})}t.inherits(m,e),m.defaultMinSockets=5,m.prototype.createConnection=n.createConnection,m.prototype.addRequestNoreuse=e.prototype.addRequest,m.prototype.addRequest=function(C,k,A){var D=l(k,A);if(typeof k!="string"){var P=k;A=P.port,k=P.host}if(this.freeSockets[D]&&this.freeSockets[D].length>0&&!C.useChunkedEncodingByDefault){var R=this.freeSockets[D].pop();R.removeListener("error",R._onIdleError),delete R._onIdleError,C._reusedSocket=!0,C.onSocket(R)}else this.addRequestNoreuse(C,k,A)},m.prototype.removeSocket=function(C,k,A,D){if(this.sockets[k]){var P=this.sockets[k].indexOf(C);P!==-1&&this.sockets[k].splice(P,1)}else this.sockets[k]&&this.sockets[k].length===0&&(delete this.sockets[k],delete this.requests[k]);if(this.freeSockets[k]){var P=this.freeSockets[k].indexOf(C);P!==-1&&(this.freeSockets[k].splice(P,1),this.freeSockets[k].length===0&&delete this.freeSockets[k])}this.requests[k]&&this.requests[k].length&&this.createSocket(k,A,D).emit("free")};function y(C){m.call(this,C)}t.inherits(y,m),y.prototype.createConnection=E,y.prototype.addRequestNoreuse=u.prototype.addRequest;function E(C,k,A){return typeof C=="object"?A=C:typeof k=="object"?A=k:typeof A=="object"?A=A:A={},typeof C=="number"&&(A.port=C),typeof k=="string"&&(A.host=k),o.connect(A)}return foreverAgent}var browser,hasRequiredBrowser;function requireBrowser(){return hasRequiredBrowser||(hasRequiredBrowser=1,browser=typeof self=="object"?self.FormData:window.FormData),browser}var isstream={exports:{}},hasRequiredIsstream;function requireIsstream(){if(hasRequiredIsstream)return isstream.exports;hasRequiredIsstream=1;var t=requireStreamBrowserify();function e(l){return l instanceof t.Stream}function n(l){return e(l)&&typeof l._read=="function"&&typeof l._readableState=="object"}function o(l){return e(l)&&typeof l._write=="function"&&typeof l._writableState=="object"}function u(l){return n(l)&&o(l)}return isstream.exports=e,isstream.exports.isReadable=n,isstream.exports.isWritable=o,isstream.exports.isDuplex=u,isstream.exports}var isTypedarray,hasRequiredIsTypedarray;function requireIsTypedarray(){if(hasRequiredIsTypedarray)return isTypedarray;hasRequiredIsTypedarray=1,isTypedarray=n,n.strict=o,n.loose=u;var t=Object.prototype.toString,e={"[object Int8Array]":!0,"[object Int16Array]":!0,"[object Int32Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Uint16Array]":!0,"[object Uint32Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0};function n(l){return o(l)||u(l)}function o(l){return l instanceof Int8Array||l instanceof Int16Array||l instanceof Int32Array||l instanceof Uint8Array||l instanceof Uint8ClampedArray||l instanceof Uint16Array||l instanceof Uint32Array||l instanceof Float32Array||l instanceof Float64Array}function u(l){return e[t.call(l)]}return isTypedarray}var getProxyFromURI_1,hasRequiredGetProxyFromURI;function requireGetProxyFromURI(){if(hasRequiredGetProxyFromURI)return getProxyFromURI_1;hasRequiredGetProxyFromURI=1;function t(u){return u.replace(/^\.*/,".").toLowerCase()}function e(u){u=u.trim().toLowerCase();var l=u.split(":",2),m=t(l[0]),y=l[1],E=u.indexOf(":")>-1;return{hostname:m,port:y,hasPort:E}}function n(u,l){var m=u.port||(u.protocol==="https:"?"443":"80"),y=t(u.hostname),E=l.split(",");return E.map(e).some(function(C){var k=y.indexOf(C.hostname),A=k>-1&&k===y.length-C.hostname.length;return C.hasPort?m===C.port&&A:A})}function o(u){var l=process$1.env.NO_PROXY||process$1.env.no_proxy||"";return l==="*"||l!==""&&n(u,l)?null:u.protocol==="http:"?process$1.env.HTTP_PROXY||process$1.env.http_proxy||null:u.protocol==="https:"&&(process$1.env.HTTPS_PROXY||process$1.env.https_proxy||process$1.env.HTTP_PROXY||process$1.env.http_proxy)||null}return getProxyFromURI_1=o,getProxyFromURI_1}var querystring={},utils,hasRequiredUtils;function requireUtils(){if(hasRequiredUtils)return utils;hasRequiredUtils=1;var t=Object.prototype.hasOwnProperty,e=function(){for(var A=[],D=0;D<256;++D)A.push("%"+((D<16?"0":"")+D.toString(16)).toUpperCase());return A}(),n=function(D){for(var P;D.length;){var R=D.pop();if(P=R.obj[R.prop],Array.isArray(P)){for(var B=[],F=0;F<P.length;++F)typeof P[F]<"u"&&B.push(P[F]);R.obj[R.prop]=B}}return P},o=function(D,P){for(var R=P&&P.plainObjects?Object.create(null):{},B=0;B<D.length;++B)typeof D[B]<"u"&&(R[B]=D[B]);return R},u=function A(D,P,R){if(!P)return D;if(typeof P!="object"){if(Array.isArray(D))D.push(P);else if(D&&typeof D=="object")(R&&(R.plainObjects||R.allowPrototypes)||!t.call(Object.prototype,P))&&(D[P]=!0);else return[D,P];return D}if(!D||typeof D!="object")return[D].concat(P);var B=D;return Array.isArray(D)&&!Array.isArray(P)&&(B=o(D,R)),Array.isArray(D)&&Array.isArray(P)?(P.forEach(function(F,j){if(t.call(D,j)){var N=D[j];N&&typeof N=="object"&&F&&typeof F=="object"?D[j]=A(N,F,R):D.push(F)}else D[j]=F}),D):Object.keys(P).reduce(function(F,j){var N=P[j];return t.call(F,j)?F[j]=A(F[j],N,R):F[j]=N,F},B)},l=function(D,P){return Object.keys(P).reduce(function(R,B){return R[B]=P[B],R},D)},m=function(A){try{return decodeURIComponent(A.replace(/\+/g," "))}catch{return A}},y=function(D){if(D.length===0)return D;for(var P=typeof D=="string"?D:String(D),R="",B=0;B<P.length;++B){var F=P.charCodeAt(B);if(F===45||F===46||F===95||F===126||F>=48&&F<=57||F>=65&&F<=90||F>=97&&F<=122){R+=P.charAt(B);continue}if(F<128){R=R+e[F];continue}if(F<2048){R=R+(e[192|F>>6]+e[128|F&63]);continue}if(F<55296||F>=57344){R=R+(e[224|F>>12]+e[128|F>>6&63]+e[128|F&63]);continue}B+=1,F=65536+((F&1023)<<10|P.charCodeAt(B)&1023),R+=e[240|F>>18]+e[128|F>>12&63]+e[128|F>>6&63]+e[128|F&63]}return R},E=function(D){for(var P=[{obj:{o:D},prop:"o"}],R=[],B=0;B<P.length;++B)for(var F=P[B],j=F.obj[F.prop],N=Object.keys(j),Y=0;Y<N.length;++Y){var J=N[Y],ie=j[J];typeof ie=="object"&&ie!==null&&R.indexOf(ie)===-1&&(P.push({obj:j,prop:J}),R.push(ie))}return n(P)},C=function(D){return Object.prototype.toString.call(D)==="[object RegExp]"},k=function(D){return D===null||typeof D>"u"?!1:!!(D.constructor&&D.constructor.isBuffer&&D.constructor.isBuffer(D))};return utils={arrayToObject:o,assign:l,compact:E,decode:m,encode:y,isBuffer:k,isRegExp:C,merge:u},utils}var formats,hasRequiredFormats$1;function requireFormats$1(){if(hasRequiredFormats$1)return formats;hasRequiredFormats$1=1;var t=String.prototype.replace,e=/%20/g;return formats={default:"RFC3986",formatters:{RFC1738:function(n){return t.call(n,e,"+")},RFC3986:function(n){return String(n)}},RFC1738:"RFC1738",RFC3986:"RFC3986"},formats}var stringify_1,hasRequiredStringify;function requireStringify(){if(hasRequiredStringify)return stringify_1;hasRequiredStringify=1;var t=requireUtils(),e=requireFormats$1(),n={brackets:function(k){return k+"[]"},indices:function(k,A){return k+"["+A+"]"},repeat:function(k){return k}},o=Array.isArray,u=Array.prototype.push,l=function(C,k){u.apply(C,o(k)?k:[k])},m=Date.prototype.toISOString,y={delimiter:"&",encode:!0,encoder:t.encode,encodeValuesOnly:!1,serializeDate:function(k){return m.call(k)},skipNulls:!1,strictNullHandling:!1},E=function C(k,A,D,P,R,B,F,j,N,Y,J,ie){var ue=k;if(typeof F=="function"?ue=F(A,ue):ue instanceof Date&&(ue=Y(ue)),ue===null){if(P)return B&&!ie?B(A,y.encoder):A;ue=""}if(typeof ue=="string"||typeof ue=="number"||typeof ue=="boolean"||t.isBuffer(ue)){if(B){var Q=ie?A:B(A,y.encoder);return[J(Q)+"="+J(B(ue,y.encoder))]}return[J(A)+"="+J(String(ue))]}var ce=[];if(typeof ue>"u")return ce;var he;if(o(F))he=F;else{var ke=Object.keys(ue);he=j?ke.sort(j):ke}for(var L=0;L<he.length;++L){var d=he[L];R&&ue[d]===null||(o(ue)?l(ce,C(ue[d],D(A,d),D,P,R,B,F,j,N,Y,J,ie)):l(ce,C(ue[d],A+(N?"."+d:"["+d+"]"),D,P,R,B,F,j,N,Y,J,ie)))}return ce};return stringify_1=function(C,k){var A=C,D=k?t.assign({},k):{};if(D.encoder!==null&&typeof D.encoder<"u"&&typeof D.encoder!="function")throw new TypeError("Encoder has to be a function.");var P=typeof D.delimiter>"u"?y.delimiter:D.delimiter,R=typeof D.strictNullHandling=="boolean"?D.strictNullHandling:y.strictNullHandling,B=typeof D.skipNulls=="boolean"?D.skipNulls:y.skipNulls,F=typeof D.encode=="boolean"?D.encode:y.encode,j=typeof D.encoder=="function"?D.encoder:y.encoder,N=typeof D.sort=="function"?D.sort:null,Y=typeof D.allowDots>"u"?!1:D.allowDots,J=typeof D.serializeDate=="function"?D.serializeDate:y.serializeDate,ie=typeof D.encodeValuesOnly=="boolean"?D.encodeValuesOnly:y.encodeValuesOnly;if(typeof D.format>"u")D.format=e.default;else if(!Object.prototype.hasOwnProperty.call(e.formatters,D.format))throw new TypeError("Unknown format option provided.");var ue=e.formatters[D.format],Q,ce;typeof D.filter=="function"?(ce=D.filter,A=ce("",A)):o(D.filter)&&(ce=D.filter,Q=ce);var he=[];if(typeof A!="object"||A===null)return"";var ke;D.arrayFormat in n?ke=D.arrayFormat:"indices"in D?ke=D.indices?"indices":"repeat":ke="indices";var L=n[ke];Q||(Q=Object.keys(A)),N&&Q.sort(N);for(var d=0;d<Q.length;++d){var v=Q[d];B&&A[v]===null||l(he,E(A[v],v,L,R,B,F?j:null,ce,N,Y,J,ue,ie))}var w=he.join(P),c=D.addQueryPrefix===!0?"?":"";return w.length>0?c+w:""},stringify_1}var parse,hasRequiredParse;function requireParse(){if(hasRequiredParse)return parse;hasRequiredParse=1;var t=requireUtils(),e=Object.prototype.hasOwnProperty,n={allowDots:!1,allowPrototypes:!1,arrayLimit:20,decoder:t.decode,delimiter:"&",depth:5,parameterLimit:1e3,plainObjects:!1,strictNullHandling:!1},o=function(y,E){for(var C={},k=E.ignoreQueryPrefix?y.replace(/^\?/,""):y,A=E.parameterLimit===1/0?void 0:E.parameterLimit,D=k.split(E.delimiter,A),P=0;P<D.length;++P){var R=D[P],B=R.indexOf("]="),F=B===-1?R.indexOf("="):B+1,j,N;F===-1?(j=E.decoder(R,n.decoder),N=E.strictNullHandling?null:""):(j=E.decoder(R.slice(0,F),n.decoder),N=E.decoder(R.slice(F+1),n.decoder)),e.call(C,j)?C[j]=[].concat(C[j]).concat(N):C[j]=N}return C},u=function(m,y,E){for(var C=y,k=m.length-1;k>=0;--k){var A,D=m[k];if(D==="[]"&&E.parseArrays)A=[].concat(C);else{A=E.plainObjects?Object.create(null):{};var P=D.charAt(0)==="["&&D.charAt(D.length-1)==="]"?D.slice(1,-1):D,R=parseInt(P,10);!E.parseArrays&&P===""?A={0:C}:!isNaN(R)&&D!==P&&String(R)===P&&R>=0&&E.parseArrays&&R<=E.arrayLimit?(A=[],A[R]=C):P!=="__proto__"&&(A[P]=C)}C=A}return C},l=function(y,E,C){if(y){var k=C.allowDots?y.replace(/\.([^.[]+)/g,"[$1]"):y,A=/(\[[^[\]]*])/,D=/(\[[^[\]]*])/g,P=A.exec(k),R=P?k.slice(0,P.index):k,B=[];if(R){if(!C.plainObjects&&e.call(Object.prototype,R)&&!C.allowPrototypes)return;B.push(R)}for(var F=0;(P=D.exec(k))!==null&&F<C.depth;){if(F+=1,!C.plainObjects&&e.call(Object.prototype,P[1].slice(1,-1))&&!C.allowPrototypes)return;B.push(P[1])}return P&&B.push("["+k.slice(P.index)+"]"),u(B,E,C)}};return parse=function(m,y){var E=y?t.assign({},y):{};if(E.decoder!==null&&E.decoder!==void 0&&typeof E.decoder!="function")throw new TypeError("Decoder has to be a function.");if(E.ignoreQueryPrefix=E.ignoreQueryPrefix===!0,E.delimiter=typeof E.delimiter=="string"||t.isRegExp(E.delimiter)?E.delimiter:n.delimiter,E.depth=typeof E.depth=="number"?E.depth:n.depth,E.arrayLimit=typeof E.arrayLimit=="number"?E.arrayLimit:n.arrayLimit,E.parseArrays=E.parseArrays!==!1,E.decoder=typeof E.decoder=="function"?E.decoder:n.decoder,E.allowDots=typeof E.allowDots=="boolean"?E.allowDots:n.allowDots,E.plainObjects=typeof E.plainObjects=="boolean"?E.plainObjects:n.plainObjects,E.allowPrototypes=typeof E.allowPrototypes=="boolean"?E.allowPrototypes:n.allowPrototypes,E.parameterLimit=typeof E.parameterLimit=="number"?E.parameterLimit:n.parameterLimit,E.strictNullHandling=typeof E.strictNullHandling=="boolean"?E.strictNullHandling:n.strictNullHandling,m===""||m===null||typeof m>"u")return E.plainObjects?Object.create(null):{};for(var C=typeof m=="string"?o(m,E):m,k=E.plainObjects?Object.create(null):{},A=Object.keys(C),D=0;D<A.length;++D){var P=A[D],R=l(P,C[P],E);k=t.merge(k,R,E)}return t.compact(k)},parse}var lib$1,hasRequiredLib$1;function requireLib$1(){if(hasRequiredLib$1)return lib$1;hasRequiredLib$1=1;var t=requireStringify(),e=requireParse(),n=requireFormats$1();return lib$1={formats:n,parse:e,stringify:t},lib$1}var hasRequiredQuerystring;function requireQuerystring(){if(hasRequiredQuerystring)return querystring;hasRequiredQuerystring=1;var t=requireLib$1(),e=require$$1$1;function n(o){this.request=o,this.lib=null,this.useQuerystring=null,this.parseOptions=null,this.stringifyOptions=null}return n.prototype.init=function(o){this.lib||(this.useQuerystring=o.useQuerystring,this.lib=this.useQuerystring?e:t,this.parseOptions=o.qsParseOptions||{},this.stringifyOptions=o.qsStringifyOptions||{})},n.prototype.stringify=function(o){return this.useQuerystring?this.rfc3986(this.lib.stringify(o,this.stringifyOptions.sep||null,this.stringifyOptions.eq||null,this.stringifyOptions)):this.lib.stringify(o,this.stringifyOptions)},n.prototype.parse=function(o){return this.useQuerystring?this.lib.parse(o,this.parseOptions.sep||null,this.parseOptions.eq||null,this.parseOptions):this.lib.parse(o,this.parseOptions)},n.prototype.rfc3986=function(o){return o.replace(/[!'()*]/g,function(u){return"%"+u.charCodeAt(0).toString(16).toUpperCase()})},n.prototype.unescape=e.unescape,querystring.Querystring=n,querystring}var har={},promise={},uri_all={exports:{}};/** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */var hasRequiredUri_all;function requireUri_all(){return hasRequiredUri_all||(hasRequiredUri_all=1,function(t,e){(function(n,o){o(e)})(commonjsGlobal$1,function(n){function o(){for(var be=arguments.length,ge=Array(be),oe=0;oe<be;oe++)ge[oe]=arguments[oe];if(ge.length>1){ge[0]=ge[0].slice(0,-1);for(var Ae=ge.length-1,qe=1;qe<Ae;++qe)ge[qe]=ge[qe].slice(1,-1);return ge[Ae]=ge[Ae].slice(1),ge.join("")}else return ge[0]}function u(be){return"(?:"+be+")"}function l(be){return be===void 0?"undefined":be===null?"null":Object.prototype.toString.call(be).split(" ").pop().split("]").shift().toLowerCase()}function m(be){return be.toUpperCase()}function y(be){return be!=null?be instanceof Array?be:typeof be.length!="number"||be.split||be.setInterval||be.call?[be]:Array.prototype.slice.call(be):[]}function E(be,ge){var oe=be;if(ge)for(var Ae in ge)oe[Ae]=ge[Ae];return oe}function C(be){var ge="[A-Za-z]",oe="[0-9]",Ae=o(oe,"[A-Fa-f]"),qe=u(u("%[EFef]"+Ae+"%"+Ae+Ae+"%"+Ae+Ae)+"|"+u("%[89A-Fa-f]"+Ae+"%"+Ae+Ae)+"|"+u("%"+Ae+Ae)),bt="[\\:\\/\\?\\#\\[\\]\\@]",at="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",gt=o(bt,at),ei=be?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",ii=be?"[\\uE000-\\uF8FF]":"[]",Bi=o(ge,oe,"[\\-\\.\\_\\~]",ei);u(ge+o(ge,oe,"[\\+\\-\\.]")+"*"),u(u(qe+"|"+o(Bi,at,"[\\:]"))+"*");var hi=u(u("25[0-5]")+"|"+u("2[0-4]"+oe)+"|"+u("1"+oe+oe)+"|"+u("0?[1-9]"+oe)+"|0?0?"+oe),Di=u(hi+"\\."+hi+"\\."+hi+"\\."+hi),ni=u(Ae+"{1,4}"),pi=u(u(ni+"\\:"+ni)+"|"+Di),Ii=u(u(ni+"\\:")+"{6}"+pi),Ci=u("\\:\\:"+u(ni+"\\:")+"{5}"+pi),zi=u(u(ni)+"?\\:\\:"+u(ni+"\\:")+"{4}"+pi),qi=u(u(u(ni+"\\:")+"{0,1}"+ni)+"?\\:\\:"+u(ni+"\\:")+"{3}"+pi),Ai=u(u(u(ni+"\\:")+"{0,2}"+ni)+"?\\:\\:"+u(ni+"\\:")+"{2}"+pi),Oi=u(u(u(ni+"\\:")+"{0,3}"+ni)+"?\\:\\:"+ni+"\\:"+pi),ki=u(u(u(ni+"\\:")+"{0,4}"+ni)+"?\\:\\:"+pi),Ti=u(u(u(ni+"\\:")+"{0,5}"+ni)+"?\\:\\:"+ni),wi=u(u(u(ni+"\\:")+"{0,6}"+ni)+"?\\:\\:"),oi=u([Ii,Ci,zi,qi,Ai,Oi,ki,Ti,wi].join("|")),zt=u(u(Bi+"|"+qe)+"+");u("[vV]"+Ae+"+\\."+o(Bi,at,"[\\:]")+"+"),u(u(qe+"|"+o(Bi,at))+"*");var Qt=u(qe+"|"+o(Bi,at,"[\\:\\@]"));return u(u(qe+"|"+o(Bi,at,"[\\@]"))+"+"),u(u(Qt+"|"+o("[\\/\\?]",ii))+"*"),{NOT_SCHEME:new RegExp(o("[^]",ge,oe,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(o("[^\\%\\:]",Bi,at),"g"),NOT_HOST:new RegExp(o("[^\\%\\[\\]\\:]",Bi,at),"g"),NOT_PATH:new RegExp(o("[^\\%\\/\\:\\@]",Bi,at),"g"),NOT_PATH_NOSCHEME:new RegExp(o("[^\\%\\/\\@]",Bi,at),"g"),NOT_QUERY:new RegExp(o("[^\\%]",Bi,at,"[\\:\\@\\/\\?]",ii),"g"),NOT_FRAGMENT:new RegExp(o("[^\\%]",Bi,at,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(o("[^]",Bi,at),"g"),UNRESERVED:new RegExp(Bi,"g"),OTHER_CHARS:new RegExp(o("[^\\%]",Bi,gt),"g"),PCT_ENCODED:new RegExp(qe,"g"),IPV4ADDRESS:new RegExp("^("+Di+")$"),IPV6ADDRESS:new RegExp("^\\[?("+oi+")"+u(u("\\%25|\\%(?!"+Ae+"{2})")+"("+zt+")")+"?\\]?$")}}var k=C(!1),A=C(!0),D=function(){function be(ge,oe){var Ae=[],qe=!0,bt=!1,at=void 0;try{for(var gt=ge[Symbol.iterator](),ei;!(qe=(ei=gt.next()).done)&&(Ae.push(ei.value),!(oe&&Ae.length===oe));qe=!0);}catch(ii){bt=!0,at=ii}finally{try{!qe&&gt.return&&gt.return()}finally{if(bt)throw at}}return Ae}return function(ge,oe){if(Array.isArray(ge))return ge;if(Symbol.iterator in Object(ge))return be(ge,oe);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),P=function(be){if(Array.isArray(be)){for(var ge=0,oe=Array(be.length);ge<be.length;ge++)oe[ge]=be[ge];return oe}else return Array.from(be)},R=2147483647,B=36,F=1,j=26,N=38,Y=700,J=72,ie=128,ue="-",Q=/^xn--/,ce=/[^\0-\x7E]/,he=/[\x2E\u3002\uFF0E\uFF61]/g,ke={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},L=B-F,d=Math.floor,v=String.fromCharCode;function w(be){throw new RangeError(ke[be])}function c(be,ge){for(var oe=[],Ae=be.length;Ae--;)oe[Ae]=ge(be[Ae]);return oe}function p(be,ge){var oe=be.split("@"),Ae="";oe.length>1&&(Ae=oe[0]+"@",be=oe[1]),be=be.replace(he,".");var qe=be.split("."),bt=c(qe,ge).join(".");return Ae+bt}function x(be){for(var ge=[],oe=0,Ae=be.length;oe<Ae;){var qe=be.charCodeAt(oe++);if(qe>=55296&&qe<=56319&&oe<Ae){var bt=be.charCodeAt(oe++);(bt&64512)==56320?ge.push(((qe&1023)<<10)+(bt&1023)+65536):(ge.push(qe),oe--)}else ge.push(qe)}return ge}var S=function(ge){return String.fromCodePoint.apply(String,P(ge))},b=function(ge){return ge-48<10?ge-22:ge-65<26?ge-65:ge-97<26?ge-97:B},h=function(ge,oe){return ge+22+75*(ge<26)-((oe!=0)<<5)},T=function(ge,oe,Ae){var qe=0;for(ge=Ae?d(ge/Y):ge>>1,ge+=d(ge/oe);ge>L*j>>1;qe+=B)ge=d(ge/L);return d(qe+(L+1)*ge/(ge+N))},M=function(ge){var oe=[],Ae=ge.length,qe=0,bt=ie,at=J,gt=ge.lastIndexOf(ue);gt<0&&(gt=0);for(var ei=0;ei<gt;++ei)ge.charCodeAt(ei)>=128&&w("not-basic"),oe.push(ge.charCodeAt(ei));for(var ii=gt>0?gt+1:0;ii<Ae;){for(var Bi=qe,hi=1,Di=B;;Di+=B){ii>=Ae&&w("invalid-input");var ni=b(ge.charCodeAt(ii++));(ni>=B||ni>d((R-qe)/hi))&&w("overflow"),qe+=ni*hi;var pi=Di<=at?F:Di>=at+j?j:Di-at;if(ni<pi)break;var Ii=B-pi;hi>d(R/Ii)&&w("overflow"),hi*=Ii}var Ci=oe.length+1;at=T(qe-Bi,Ci,Bi==0),d(qe/Ci)>R-bt&&w("overflow"),bt+=d(qe/Ci),qe%=Ci,oe.splice(qe++,0,bt)}return String.fromCodePoint.apply(String,oe)},O=function(ge){var oe=[];ge=x(ge);var Ae=ge.length,qe=ie,bt=0,at=J,gt=!0,ei=!1,ii=void 0;try{for(var Bi=ge[Symbol.iterator](),hi;!(gt=(hi=Bi.next()).done);gt=!0){var Di=hi.value;Di<128&&oe.push(v(Di))}}catch(Gi){ei=!0,ii=Gi}finally{try{!gt&&Bi.return&&Bi.return()}finally{if(ei)throw ii}}var ni=oe.length,pi=ni;for(ni&&oe.push(ue);pi<Ae;){var Ii=R,Ci=!0,zi=!1,qi=void 0;try{for(var Ai=ge[Symbol.iterator](),Oi;!(Ci=(Oi=Ai.next()).done);Ci=!0){var ki=Oi.value;ki>=qe&&ki<Ii&&(Ii=ki)}}catch(Gi){zi=!0,qi=Gi}finally{try{!Ci&&Ai.return&&Ai.return()}finally{if(zi)throw qi}}var Ti=pi+1;Ii-qe>d((R-bt)/Ti)&&w("overflow"),bt+=(Ii-qe)*Ti,qe=Ii;var wi=!0,oi=!1,zt=void 0;try{for(var Qt=ge[Symbol.iterator](),Si;!(wi=(Si=Qt.next()).done);wi=!0){var mi=Si.value;if(mi<qe&&++bt>R&&w("overflow"),mi==qe){for(var ai=bt,gi=B;;gi+=B){var Hi=gi<=at?F:gi>=at+j?j:gi-at;if(ai<Hi)break;var or=ai-Hi,nr=B-Hi;oe.push(v(h(Hi+or%nr,0))),ai=d(or/nr)}oe.push(v(h(ai,0))),at=T(bt,Ti,pi==ni),bt=0,++pi}}}catch(Gi){oi=!0,zt=Gi}finally{try{!wi&&Qt.return&&Qt.return()}finally{if(oi)throw zt}}++bt,++qe}return oe.join("")},V=function(ge){return p(ge,function(oe){return Q.test(oe)?M(oe.slice(4).toLowerCase()):oe})},ee=function(ge){return p(ge,function(oe){return ce.test(oe)?"xn--"+O(oe):oe})},Z={version:"2.1.0",ucs2:{decode:x,encode:S},decode:M,encode:O,toASCII:ee,toUnicode:V},U={};function z(be){var ge=be.charCodeAt(0),oe=void 0;return ge<16?oe="%0"+ge.toString(16).toUpperCase():ge<128?oe="%"+ge.toString(16).toUpperCase():ge<2048?oe="%"+(ge>>6|192).toString(16).toUpperCase()+"%"+(ge&63|128).toString(16).toUpperCase():oe="%"+(ge>>12|224).toString(16).toUpperCase()+"%"+(ge>>6&63|128).toString(16).toUpperCase()+"%"+(ge&63|128).toString(16).toUpperCase(),oe}function ne(be){for(var ge="",oe=0,Ae=be.length;oe<Ae;){var qe=parseInt(be.substr(oe+1,2),16);if(qe<128)ge+=String.fromCharCode(qe),oe+=3;else if(qe>=194&&qe<224){if(Ae-oe>=6){var bt=parseInt(be.substr(oe+4,2),16);ge+=String.fromCharCode((qe&31)<<6|bt&63)}else ge+=be.substr(oe,6);oe+=6}else if(qe>=224){if(Ae-oe>=9){var at=parseInt(be.substr(oe+4,2),16),gt=parseInt(be.substr(oe+7,2),16);ge+=String.fromCharCode((qe&15)<<12|(at&63)<<6|gt&63)}else ge+=be.substr(oe,9);oe+=9}else ge+=be.substr(oe,3),oe+=3}return ge}function fe(be,ge){function oe(Ae){var qe=ne(Ae);return qe.match(ge.UNRESERVED)?qe:Ae}return be.scheme&&(be.scheme=String(be.scheme).replace(ge.PCT_ENCODED,oe).toLowerCase().replace(ge.NOT_SCHEME,"")),be.userinfo!==void 0&&(be.userinfo=String(be.userinfo).replace(ge.PCT_ENCODED,oe).replace(ge.NOT_USERINFO,z).replace(ge.PCT_ENCODED,m)),be.host!==void 0&&(be.host=String(be.host).replace(ge.PCT_ENCODED,oe).toLowerCase().replace(ge.NOT_HOST,z).replace(ge.PCT_ENCODED,m)),be.path!==void 0&&(be.path=String(be.path).replace(ge.PCT_ENCODED,oe).replace(be.scheme?ge.NOT_PATH:ge.NOT_PATH_NOSCHEME,z).replace(ge.PCT_ENCODED,m)),be.query!==void 0&&(be.query=String(be.query).replace(ge.PCT_ENCODED,oe).replace(ge.NOT_QUERY,z).replace(ge.PCT_ENCODED,m)),be.fragment!==void 0&&(be.fragment=String(be.fragment).replace(ge.PCT_ENCODED,oe).replace(ge.NOT_FRAGMENT,z).replace(ge.PCT_ENCODED,m)),be}function me(be){return be.replace(/^0*(.*)/,"$1")||"0"}function de(be,ge){var oe=be.match(ge.IPV4ADDRESS)||[],Ae=D(oe,2),qe=Ae[1];return qe?qe.split(".").map(me).join("."):be}function je(be,ge){var oe=be.match(ge.IPV6ADDRESS)||[],Ae=D(oe,3),qe=Ae[1],bt=Ae[2];if(qe){for(var at=qe.toLowerCase().split("::").reverse(),gt=D(at,2),ei=gt[0],ii=gt[1],Bi=ii?ii.split(":").map(me):[],hi=ei.split(":").map(me),Di=ge.IPV4ADDRESS.test(hi[hi.length-1]),ni=Di?7:8,pi=hi.length-ni,Ii=Array(ni),Ci=0;Ci<ni;++Ci)Ii[Ci]=Bi[Ci]||hi[pi+Ci]||"";Di&&(Ii[ni-1]=de(Ii[ni-1],ge));var zi=Ii.reduce(function(Ti,wi,oi){if(!wi||wi==="0"){var zt=Ti[Ti.length-1];zt&&zt.index+zt.length===oi?zt.length++:Ti.push({index:oi,length:1})}return Ti},[]),qi=zi.sort(function(Ti,wi){return wi.length-Ti.length})[0],Ai=void 0;if(qi&&qi.length>1){var Oi=Ii.slice(0,qi.index),ki=Ii.slice(qi.index+qi.length);Ai=Oi.join(":")+"::"+ki.join(":")}else Ai=Ii.join(":");return bt&&(Ai+="%"+bt),Ai}else return be}var lt=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,it="".match(/(){0}/)[1]===void 0;function ot(be){var ge=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},oe={},Ae=ge.iri!==!1?A:k;ge.reference==="suffix"&&(be=(ge.scheme?ge.scheme+":":"")+"//"+be);var qe=be.match(lt);if(qe){it?(oe.scheme=qe[1],oe.userinfo=qe[3],oe.host=qe[4],oe.port=parseInt(qe[5],10),oe.path=qe[6]||"",oe.query=qe[7],oe.fragment=qe[8],isNaN(oe.port)&&(oe.port=qe[5])):(oe.scheme=qe[1]||void 0,oe.userinfo=be.indexOf("@")!==-1?qe[3]:void 0,oe.host=be.indexOf("//")!==-1?qe[4]:void 0,oe.port=parseInt(qe[5],10),oe.path=qe[6]||"",oe.query=be.indexOf("?")!==-1?qe[7]:void 0,oe.fragment=be.indexOf("#")!==-1?qe[8]:void 0,isNaN(oe.port)&&(oe.port=be.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?qe[4]:void 0)),oe.host&&(oe.host=je(de(oe.host,Ae),Ae)),oe.scheme===void 0&&oe.userinfo===void 0&&oe.host===void 0&&oe.port===void 0&&!oe.path&&oe.query===void 0?oe.reference="same-document":oe.scheme===void 0?oe.reference="relative":oe.fragment===void 0?oe.reference="absolute":oe.reference="uri",ge.reference&&ge.reference!=="suffix"&&ge.reference!==oe.reference&&(oe.error=oe.error||"URI is not a "+ge.reference+" reference.");var bt=U[(ge.scheme||oe.scheme||"").toLowerCase()];if(!ge.unicodeSupport&&(!bt||!bt.unicodeSupport)){if(oe.host&&(ge.domainHost||bt&&bt.domainHost))try{oe.host=Z.toASCII(oe.host.replace(Ae.PCT_ENCODED,ne).toLowerCase())}catch(at){oe.error=oe.error||"Host's domain name can not be converted to ASCII via punycode: "+at}fe(oe,k)}else fe(oe,Ae);bt&&bt.parse&&bt.parse(oe,ge)}else oe.error=oe.error||"URI can not be parsed.";return oe}function Ct(be,ge){var oe=ge.iri!==!1?A:k,Ae=[];return be.userinfo!==void 0&&(Ae.push(be.userinfo),Ae.push("@")),be.host!==void 0&&Ae.push(je(de(String(be.host),oe),oe).replace(oe.IPV6ADDRESS,function(qe,bt,at){return"["+bt+(at?"%25"+at:"")+"]"})),(typeof be.port=="number"||typeof be.port=="string")&&(Ae.push(":"),Ae.push(String(be.port))),Ae.length?Ae.join(""):void 0}var nt=/^\.\.?\//,Je=/^\/\.(\/|$)/,tt=/^\/\.\.(\/|$)/,rt=/^\/?(?:.|\n)*?(?=\/|$)/;function ht(be){for(var ge=[];be.length;)if(be.match(nt))be=be.replace(nt,"");else if(be.match(Je))be=be.replace(Je,"/");else if(be.match(tt))be=be.replace(tt,"/"),ge.pop();else if(be==="."||be==="..")be="";else{var oe=be.match(rt);if(oe){var Ae=oe[0];be=be.slice(Ae.length),ge.push(Ae)}else throw new Error("Unexpected dot segment condition")}return ge.join("")}function Ot(be){var ge=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},oe=ge.iri?A:k,Ae=[],qe=U[(ge.scheme||be.scheme||"").toLowerCase()];if(qe&&qe.serialize&&qe.serialize(be,ge),be.host&&!oe.IPV6ADDRESS.test(be.host)){if(ge.domainHost||qe&&qe.domainHost)try{be.host=ge.iri?Z.toUnicode(be.host):Z.toASCII(be.host.replace(oe.PCT_ENCODED,ne).toLowerCase())}catch(gt){be.error=be.error||"Host's domain name can not be converted to "+(ge.iri?"Unicode":"ASCII")+" via punycode: "+gt}}fe(be,oe),ge.reference!=="suffix"&&be.scheme&&(Ae.push(be.scheme),Ae.push(":"));var bt=Ct(be,ge);if(bt!==void 0&&(ge.reference!=="suffix"&&Ae.push("//"),Ae.push(bt),be.path&&be.path.charAt(0)!=="/"&&Ae.push("/")),be.path!==void 0){var at=be.path;!ge.absolutePath&&(!qe||!qe.absolutePath)&&(at=ht(at)),bt===void 0&&(at=at.replace(/^\/\//,"/%2F")),Ae.push(at)}return be.query!==void 0&&(Ae.push("?"),Ae.push(be.query)),be.fragment!==void 0&&(Ae.push("#"),Ae.push(be.fragment)),Ae.join("")}function Ve(be,ge){var oe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Ae=arguments[3],qe={};return Ae||(be=ot(Ot(be,oe),oe),ge=ot(Ot(ge,oe),oe)),oe=oe||{},!oe.tolerant&&ge.scheme?(qe.scheme=ge.scheme,qe.userinfo=ge.userinfo,qe.host=ge.host,qe.port=ge.port,qe.path=ht(ge.path||""),qe.query=ge.query):(ge.userinfo!==void 0||ge.host!==void 0||ge.port!==void 0?(qe.userinfo=ge.userinfo,qe.host=ge.host,qe.port=ge.port,qe.path=ht(ge.path||""),qe.query=ge.query):(ge.path?(ge.path.charAt(0)==="/"?qe.path=ht(ge.path):((be.userinfo!==void 0||be.host!==void 0||be.port!==void 0)&&!be.path?qe.path="/"+ge.path:be.path?qe.path=be.path.slice(0,be.path.lastIndexOf("/")+1)+ge.path:qe.path=ge.path,qe.path=ht(qe.path)),qe.query=ge.query):(qe.path=be.path,ge.query!==void 0?qe.query=ge.query:qe.query=be.query),qe.userinfo=be.userinfo,qe.host=be.host,qe.port=be.port),qe.scheme=be.scheme),qe.fragment=ge.fragment,qe}function We(be,ge,oe){var Ae=E({scheme:"null"},oe);return Ot(Ve(ot(be,Ae),ot(ge,Ae),Ae,!0),Ae)}function Gt(be,ge){return typeof be=="string"?be=Ot(ot(be,ge),ge):l(be)==="object"&&(be=ot(Ot(be,ge),ge)),be}function wt(be,ge,oe){return typeof be=="string"?be=Ot(ot(be,oe),oe):l(be)==="object"&&(be=Ot(be,oe)),typeof ge=="string"?ge=Ot(ot(ge,oe),oe):l(ge)==="object"&&(ge=Ot(ge,oe)),be===ge}function Et(be,ge){return be&&be.toString().replace(!ge||!ge.iri?k.ESCAPE:A.ESCAPE,z)}function Yt(be,ge){return be&&be.toString().replace(!ge||!ge.iri?k.PCT_ENCODED:A.PCT_ENCODED,ne)}var Ce={scheme:"http",domainHost:!0,parse:function(ge,oe){return ge.host||(ge.error=ge.error||"HTTP URIs must have a host."),ge},serialize:function(ge,oe){var Ae=String(ge.scheme).toLowerCase()==="https";return(ge.port===(Ae?443:80)||ge.port==="")&&(ge.port=void 0),ge.path||(ge.path="/"),ge}},te={scheme:"https",domainHost:Ce.domainHost,parse:Ce.parse,serialize:Ce.serialize};function ye(be){return typeof be.secure=="boolean"?be.secure:String(be.scheme).toLowerCase()==="wss"}var Le={scheme:"ws",domainHost:!0,parse:function(ge,oe){var Ae=ge;return Ae.secure=ye(Ae),Ae.resourceName=(Ae.path||"/")+(Ae.query?"?"+Ae.query:""),Ae.path=void 0,Ae.query=void 0,Ae},serialize:function(ge,oe){if((ge.port===(ye(ge)?443:80)||ge.port==="")&&(ge.port=void 0),typeof ge.secure=="boolean"&&(ge.scheme=ge.secure?"wss":"ws",ge.secure=void 0),ge.resourceName){var Ae=ge.resourceName.split("?"),qe=D(Ae,2),bt=qe[0],at=qe[1];ge.path=bt&&bt!=="/"?bt:void 0,ge.query=at,ge.resourceName=void 0}return ge.fragment=void 0,ge}},Ue={scheme:"wss",domainHost:Le.domainHost,parse:Le.parse,serialize:Le.serialize},Qe={},Ke="[A-Za-z0-9\\-\\.\\_\\~\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]",De="[0-9A-Fa-f]",Vt=u(u("%[EFef]"+De+"%"+De+De+"%"+De+De)+"|"+u("%[89A-Fa-f]"+De+"%"+De+De)+"|"+u("%"+De+De)),At="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",ve="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",Pt=o(ve,'[\\"\\\\]'),pt="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",Ne=new RegExp(Ke,"g"),vt=new RegExp(Vt,"g"),ut=new RegExp(o("[^]",At,"[\\.]",'[\\"]',Pt),"g"),$t=new RegExp(o("[^]",Ke,pt),"g"),fi=$t;function kt(be){var ge=ne(be);return ge.match(Ne)?ge:be}var Wt={scheme:"mailto",parse:function(ge,oe){var Ae=ge,qe=Ae.to=Ae.path?Ae.path.split(","):[];if(Ae.path=void 0,Ae.query){for(var bt=!1,at={},gt=Ae.query.split("&"),ei=0,ii=gt.length;ei<ii;++ei){var Bi=gt[ei].split("=");switch(Bi[0]){case"to":for(var hi=Bi[1].split(","),Di=0,ni=hi.length;Di<ni;++Di)qe.push(hi[Di]);break;case"subject":Ae.subject=Yt(Bi[1],oe);break;case"body":Ae.body=Yt(Bi[1],oe);break;default:bt=!0,at[Yt(Bi[0],oe)]=Yt(Bi[1],oe);break}}bt&&(Ae.headers=at)}Ae.query=void 0;for(var pi=0,Ii=qe.length;pi<Ii;++pi){var Ci=qe[pi].split("@");if(Ci[0]=Yt(Ci[0]),oe.unicodeSupport)Ci[1]=Yt(Ci[1],oe).toLowerCase();else try{Ci[1]=Z.toASCII(Yt(Ci[1],oe).toLowerCase())}catch(zi){Ae.error=Ae.error||"Email address's domain name can not be converted to ASCII via punycode: "+zi}qe[pi]=Ci.join("@")}return Ae},serialize:function(ge,oe){var Ae=ge,qe=y(ge.to);if(qe){for(var bt=0,at=qe.length;bt<at;++bt){var gt=String(qe[bt]),ei=gt.lastIndexOf("@"),ii=gt.slice(0,ei).replace(vt,kt).replace(vt,m).replace(ut,z),Bi=gt.slice(ei+1);try{Bi=oe.iri?Z.toUnicode(Bi):Z.toASCII(Yt(Bi,oe).toLowerCase())}catch(pi){Ae.error=Ae.error||"Email address's domain name can not be converted to "+(oe.iri?"Unicode":"ASCII")+" via punycode: "+pi}qe[bt]=ii+"@"+Bi}Ae.path=qe.join(",")}var hi=ge.headers=ge.headers||{};ge.subject&&(hi.subject=ge.subject),ge.body&&(hi.body=ge.body);var Di=[];for(var ni in hi)hi[ni]!==Qe[ni]&&Di.push(ni.replace(vt,kt).replace(vt,m).replace($t,z)+"="+hi[ni].replace(vt,kt).replace(vt,m).replace(fi,z));return Di.length&&(Ae.query=Di.join("&")),Ae}},Zi=/^([^\:]+)\:(.*)/,Ut={scheme:"urn",parse:function(ge,oe){var Ae=ge.path&&ge.path.match(Zi),qe=ge;if(Ae){var bt=oe.scheme||qe.scheme||"urn",at=Ae[1].toLowerCase(),gt=Ae[2],ei=bt+":"+(oe.nid||at),ii=U[ei];qe.nid=at,qe.nss=gt,qe.path=void 0,ii&&(qe=ii.parse(qe,oe))}else qe.error=qe.error||"URN can not be parsed.";return qe},serialize:function(ge,oe){var Ae=oe.scheme||ge.scheme||"urn",qe=ge.nid,bt=Ae+":"+(oe.nid||qe),at=U[bt];at&&(ge=at.serialize(ge,oe));var gt=ge,ei=ge.nss;return gt.path=(qe||oe.nid)+":"+ei,gt}},Xt=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,Be={scheme:"urn:uuid",parse:function(ge,oe){var Ae=ge;return Ae.uuid=Ae.nss,Ae.nss=void 0,!oe.tolerant&&(!Ae.uuid||!Ae.uuid.match(Xt))&&(Ae.error=Ae.error||"UUID is not valid."),Ae},serialize:function(ge,oe){var Ae=ge;return Ae.nss=(ge.uuid||"").toLowerCase(),Ae}};U[Ce.scheme]=Ce,U[te.scheme]=te,U[Le.scheme]=Le,U[Ue.scheme]=Ue,U[Wt.scheme]=Wt,U[Ut.scheme]=Ut,U[Be.scheme]=Be,n.SCHEMES=U,n.pctEncChar=z,n.pctDecChars=ne,n.parse=ot,n.removeDotSegments=ht,n.serialize=Ot,n.resolveComponents=Ve,n.resolve=We,n.normalize=Gt,n.equal=wt,n.escapeComponent=Et,n.unescapeComponent=Yt,Object.defineProperty(n,"__esModule",{value:!0})})}(uri_all,uri_all.exports)),uri_all.exports}var fastDeepEqual,hasRequiredFastDeepEqual;function requireFastDeepEqual(){return hasRequiredFastDeepEqual||(hasRequiredFastDeepEqual=1,fastDeepEqual=function t(e,n){if(e===n)return!0;if(e&&n&&typeof e=="object"&&typeof n=="object"){if(e.constructor!==n.constructor)return!1;var o,u,l;if(Array.isArray(e)){if(o=e.length,o!=n.length)return!1;for(u=o;u--!==0;)if(!t(e[u],n[u]))return!1;return!0}if(e.constructor===RegExp)return e.source===n.source&&e.flags===n.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===n.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===n.toString();if(l=Object.keys(e),o=l.length,o!==Object.keys(n).length)return!1;for(u=o;u--!==0;)if(!Object.prototype.hasOwnProperty.call(n,l[u]))return!1;for(u=o;u--!==0;){var m=l[u];if(!t(e[m],n[m]))return!1}return!0}return e!==e&&n!==n}),fastDeepEqual}var ucs2length,hasRequiredUcs2length;function requireUcs2length(){return hasRequiredUcs2length||(hasRequiredUcs2length=1,ucs2length=function(e){for(var n=0,o=e.length,u=0,l;u<o;)n++,l=e.charCodeAt(u++),l>=55296&&l<=56319&&u<o&&(l=e.charCodeAt(u),(l&64512)==56320&&u++);return n}),ucs2length}var util,hasRequiredUtil;function requireUtil(){if(hasRequiredUtil)return util;hasRequiredUtil=1,util={copy:t,checkDataType:e,checkDataTypes:n,coerceToTypes:u,toHash:l,getProperty:E,escapeQuotes:C,equal:requireFastDeepEqual(),ucs2length:requireUcs2length(),varOccurences:k,varReplace:A,schemaHasRules:D,schemaHasRulesExcept:P,schemaUnknownRules:R,toQuotedString:B,getPathExpr:F,getPath:j,getData:J,unescapeFragment:ue,unescapeJsonPointer:he,escapeFragment:Q,escapeJsonPointer:ce};function t(ke,L){L=L||{};for(var d in ke)L[d]=ke[d];return L}function e(ke,L,d,v){var w=v?" !== ":" === ",c=v?" || ":" && ",p=v?"!":"",x=v?"":"!";switch(ke){case"null":return L+w+"null";case"array":return p+"Array.isArray("+L+")";case"object":return"("+p+L+c+"typeof "+L+w+'"object"'+c+x+"Array.isArray("+L+"))";case"integer":return"(typeof "+L+w+'"number"'+c+x+"("+L+" % 1)"+c+L+w+L+(d?c+p+"isFinite("+L+")":"")+")";case"number":return"(typeof "+L+w+'"'+ke+'"'+(d?c+p+"isFinite("+L+")":"")+")";default:return"typeof "+L+w+'"'+ke+'"'}}function n(ke,L,d){switch(ke.length){case 1:return e(ke[0],L,d,!0);default:var v="",w=l(ke);w.array&&w.object&&(v=w.null?"(":"(!"+L+" || ",v+="typeof "+L+' !== "object")',delete w.null,delete w.array,delete w.object),w.number&&delete w.integer;for(var c in w)v+=(v?" && ":"")+e(c,L,d,!0);return v}}var o=l(["string","number","integer","boolean","null"]);function u(ke,L){if(Array.isArray(L)){for(var d=[],v=0;v<L.length;v++){var w=L[v];(o[w]||ke==="array"&&w==="array")&&(d[d.length]=w)}if(d.length)return d}else{if(o[L])return[L];if(ke==="array"&&L==="array")return["array"]}}function l(ke){for(var L={},d=0;d<ke.length;d++)L[ke[d]]=!0;return L}var m=/^[a-z$_][a-z$_0-9]*$/i,y=/'|\\/g;function E(ke){return typeof ke=="number"?"["+ke+"]":m.test(ke)?"."+ke:"['"+C(ke)+"']"}function C(ke){return ke.replace(y,"\\$&").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\f/g,"\\f").replace(/\t/g,"\\t")}function k(ke,L){L+="[^0-9]";var d=ke.match(new RegExp(L,"g"));return d?d.length:0}function A(ke,L,d){return L+="([^0-9])",d=d.replace(/\$/g,"$$$$"),ke.replace(new RegExp(L,"g"),d+"$1")}function D(ke,L){if(typeof ke=="boolean")return!ke;for(var d in ke)if(L[d])return!0}function P(ke,L,d){if(typeof ke=="boolean")return!ke&&d!="not";for(var v in ke)if(v!=d&&L[v])return!0}function R(ke,L){if(typeof ke!="boolean"){for(var d in ke)if(!L[d])return d}}function B(ke){return"'"+C(ke)+"'"}function F(ke,L,d,v){var w=d?"'/' + "+L+(v?"":".replace(/~/g, '~0').replace(/\\//g, '~1')"):v?"'[' + "+L+" + ']'":"'[\\'' + "+L+" + '\\']'";return ie(ke,w)}function j(ke,L,d){var v=B(d?"/"+ce(L):E(L));return ie(ke,v)}var N=/^\/(?:[^~]|~0|~1)*$/,Y=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function J(ke,L,d){var v,w,c,p;if(ke==="")return"rootData";if(ke[0]=="/"){if(!N.test(ke))throw new Error("Invalid JSON-pointer: "+ke);w=ke,c="rootData"}else{if(p=ke.match(Y),!p)throw new Error("Invalid JSON-pointer: "+ke);if(v=+p[1],w=p[2],w=="#"){if(v>=L)throw new Error("Cannot access property/index "+v+" levels up, current level is "+L);return d[L-v]}if(v>L)throw new Error("Cannot access data "+v+" levels up, current level is "+L);if(c="data"+(L-v||""),!w)return c}for(var x=c,S=w.split("/"),b=0;b<S.length;b++){var h=S[b];h&&(c+=E(he(h)),x+=" && "+c)}return x}function ie(ke,L){return ke=='""'?L:(ke+" + "+L).replace(/([^\\])' \+ '/g,"$1")}function ue(ke){return he(decodeURIComponent(ke))}function Q(ke){return encodeURIComponent(ce(ke))}function ce(ke){return ke.replace(/~/g,"~0").replace(/\//g,"~1")}function he(ke){return ke.replace(/~1/g,"/").replace(/~0/g,"~")}return util}var schema_obj,hasRequiredSchema_obj;function requireSchema_obj(){if(hasRequiredSchema_obj)return schema_obj;hasRequiredSchema_obj=1;var t=requireUtil();schema_obj=e;function e(n){t.copy(n,this)}return schema_obj}var jsonSchemaTraverse={exports:{}},hasRequiredJsonSchemaTraverse;function requireJsonSchemaTraverse(){if(hasRequiredJsonSchemaTraverse)return jsonSchemaTraverse.exports;hasRequiredJsonSchemaTraverse=1;var t=jsonSchemaTraverse.exports=function(o,u,l){typeof u=="function"&&(l=u,u={}),l=u.cb||l;var m=typeof l=="function"?l:l.pre||function(){},y=l.post||function(){};e(u,m,y,o,"",o)};t.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0},t.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},t.propsKeywords={definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},t.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function e(o,u,l,m,y,E,C,k,A,D){if(m&&typeof m=="object"&&!Array.isArray(m)){u(m,y,E,C,k,A,D);for(var P in m){var R=m[P];if(Array.isArray(R)){if(P in t.arrayKeywords)for(var B=0;B<R.length;B++)e(o,u,l,R[B],y+"/"+P+"/"+B,E,y,P,m,B)}else if(P in t.propsKeywords){if(R&&typeof R=="object")for(var F in R)e(o,u,l,R[F],y+"/"+P+"/"+n(F),E,y,P,m,F)}else(P in t.keywords||o.allKeys&&!(P in t.skipKeywords))&&e(o,u,l,R,y+"/"+P,E,y,P,m)}l(m,y,E,C,k,A,D)}}function n(o){return o.replace(/~/g,"~0").replace(/\//g,"~1")}return jsonSchemaTraverse.exports}var resolve_1,hasRequiredResolve;function requireResolve(){if(hasRequiredResolve)return resolve_1;hasRequiredResolve=1;var t=requireUri_all(),e=requireFastDeepEqual(),n=requireUtil(),o=requireSchema_obj(),u=requireJsonSchemaTraverse();resolve_1=l,l.normalizeId=j,l.fullPath=R,l.url=N,l.ids=Y,l.inlineRef=A,l.schema=m;function l(J,ie,ue){var Q=this._refs[ue];if(typeof Q=="string")if(this._refs[Q])Q=this._refs[Q];else return l.call(this,J,ie,Q);if(Q=Q||this._schemas[ue],Q instanceof o)return A(Q.schema,this._opts.inlineRefs)?Q.schema:Q.validate||this._compile(Q);var ce=m.call(this,ie,ue),he,ke,L;return ce&&(he=ce.schema,ie=ce.root,L=ce.baseId),he instanceof o?ke=he.validate||J.call(this,he.schema,ie,void 0,L):he!==void 0&&(ke=A(he,this._opts.inlineRefs)?he:J.call(this,he,ie,void 0,L)),ke}function m(J,ie){var ue=t.parse(ie),Q=B(ue),ce=R(this._getId(J.schema));if(Object.keys(J.schema).length===0||Q!==ce){var he=j(Q),ke=this._refs[he];if(typeof ke=="string")return y.call(this,J,ke,ue);if(ke instanceof o)ke.validate||this._compile(ke),J=ke;else if(ke=this._schemas[he],ke instanceof o){if(ke.validate||this._compile(ke),he==j(ie))return{schema:ke,root:J,baseId:ce};J=ke}else return;if(!J.schema)return;ce=R(this._getId(J.schema))}return C.call(this,ue,ce,J.schema,J)}function y(J,ie,ue){var Q=m.call(this,J,ie);if(Q){var ce=Q.schema,he=Q.baseId;J=Q.root;var ke=this._getId(ce);return ke&&(he=N(he,ke)),C.call(this,ue,he,ce,J)}}var E=n.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function C(J,ie,ue,Q){if(J.fragment=J.fragment||"",J.fragment.slice(0,1)=="/"){for(var ce=J.fragment.split("/"),he=1;he<ce.length;he++){var ke=ce[he];if(ke){if(ke=n.unescapeFragment(ke),ue=ue[ke],ue===void 0)break;var L;if(!E[ke]&&(L=this._getId(ue),L&&(ie=N(ie,L)),ue.$ref)){var d=N(ie,ue.$ref),v=m.call(this,Q,d);v&&(ue=v.schema,Q=v.root,ie=v.baseId)}}}if(ue!==void 0&&ue!==Q.schema)return{schema:ue,root:Q,baseId:ie}}}var k=n.toHash(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum"]);function A(J,ie){if(ie===!1)return!1;if(ie===void 0||ie===!0)return D(J);if(ie)return P(J)<=ie}function D(J){var ie;if(Array.isArray(J)){for(var ue=0;ue<J.length;ue++)if(ie=J[ue],typeof ie=="object"&&!D(ie))return!1}else for(var Q in J)if(Q=="$ref"||(ie=J[Q],typeof ie=="object"&&!D(ie)))return!1;return!0}function P(J){var ie=0,ue;if(Array.isArray(J)){for(var Q=0;Q<J.length;Q++)if(ue=J[Q],typeof ue=="object"&&(ie+=P(ue)),ie==1/0)return 1/0}else for(var ce in J){if(ce=="$ref")return 1/0;if(k[ce])ie++;else if(ue=J[ce],typeof ue=="object"&&(ie+=P(ue)+1),ie==1/0)return 1/0}return ie}function R(J,ie){ie!==!1&&(J=j(J));var ue=t.parse(J);return B(ue)}function B(J){return t.serialize(J).split("#")[0]+"#"}var F=/#\/?$/;function j(J){return J?J.replace(F,""):""}function N(J,ie){return ie=j(ie),t.resolve(J,ie)}function Y(J){var ie=j(this._getId(J)),ue={"":ie},Q={"":R(ie,!1)},ce={},he=this;return u(J,{allKeys:!0},function(ke,L,d,v,w,c,p){if(L!==""){var x=he._getId(ke),S=ue[v],b=Q[v]+"/"+w;if(p!==void 0&&(b+="/"+(typeof p=="number"?p:n.escapeFragment(p))),typeof x=="string"){x=S=j(S?t.resolve(S,x):x);var h=he._refs[x];if(typeof h=="string"&&(h=he._refs[h]),h&&h.schema){if(!e(ke,h.schema))throw new Error('id "'+x+'" resolves to more than one schema')}else if(x!=j(b))if(x[0]=="#"){if(ce[x]&&!e(ke,ce[x]))throw new Error('id "'+x+'" resolves to more than one schema');ce[x]=ke}else he._refs[x]=b}ue[L]=S,Q[L]=b}}),ce}return resolve_1}var error_classes,hasRequiredError_classes;function requireError_classes(){if(hasRequiredError_classes)return error_classes;hasRequiredError_classes=1;var t=requireResolve();error_classes={Validation:o(e),MissingRef:o(n)};function e(u){this.message="validation failed",this.errors=u,this.ajv=this.validation=!0}n.message=function(u,l){return"can't resolve reference "+l+" from id "+u};function n(u,l,m){this.message=m||n.message(u,l),this.missingRef=t.url(u,l),this.missingSchema=t.normalizeId(t.fullPath(this.missingRef))}function o(u){return u.prototype=Object.create(Error.prototype),u.prototype.constructor=u,u}return error_classes}var fastJsonStableStringify,hasRequiredFastJsonStableStringify;function requireFastJsonStableStringify(){return hasRequiredFastJsonStableStringify||(hasRequiredFastJsonStableStringify=1,fastJsonStableStringify=function(t,e){e||(e={}),typeof e=="function"&&(e={cmp:e});var n=typeof e.cycles=="boolean"?e.cycles:!1,o=e.cmp&&function(l){return function(m){return function(y,E){var C={key:y,value:m[y]},k={key:E,value:m[E]};return l(C,k)}}}(e.cmp),u=[];return function l(m){if(m&&m.toJSON&&typeof m.toJSON=="function"&&(m=m.toJSON()),m!==void 0){if(typeof m=="number")return isFinite(m)?""+m:"null";if(typeof m!="object")return JSON.stringify(m);var y,E;if(Array.isArray(m)){for(E="[",y=0;y<m.length;y++)y&&(E+=","),E+=l(m[y])||"null";return E+"]"}if(m===null)return"null";if(u.indexOf(m)!==-1){if(n)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var C=u.push(m)-1,k=Object.keys(m).sort(o&&o(m));for(E="",y=0;y<k.length;y++){var A=k[y],D=l(m[A]);D&&(E&&(E+=","),E+=JSON.stringify(A)+":"+D)}return u.splice(C,1),"{"+E+"}"}}(t)}),fastJsonStableStringify}var validate,hasRequiredValidate;function requireValidate(){return hasRequiredValidate||(hasRequiredValidate=1,validate=function(e,n,o){var u="",l=e.schema.$async===!0,m=e.util.schemaHasRulesExcept(e.schema,e.RULES.all,"$ref"),y=e.self._getId(e.schema);if(e.opts.strictKeywords){var E=e.util.schemaUnknownRules(e.schema,e.RULES.keywords);if(E){var C="unknown keyword: "+E;if(e.opts.strictKeywords==="log")e.logger.warn(C);else throw new Error(C)}}if(e.isTop&&(u+=" var validate = ",l&&(e.async=!0,u+="async "),u+="function(data, dataPath, parentData, parentDataProperty, rootData) { 'use strict'; ",y&&(e.opts.sourceCode||e.opts.processCode)&&(u+=" "+("/*# sourceURL="+y+" */")+" ")),typeof e.schema=="boolean"||!(m||e.schema.$ref)){var n="false schema",k=e.level,A=e.dataLevel,D=e.schema[n],P=e.schemaPath+e.util.getProperty(n),R=e.errSchemaPath+"/"+n,ie=!e.opts.allErrors,ce,B="data"+(A||""),J="valid"+k;if(e.schema===!1){e.isTop?ie=!0:u+=" var "+J+" = false; ";var F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(ce||"false schema")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(R)+" , params: {} ",e.opts.messages!==!1&&(u+=" , message: 'boolean schema is false' "),e.opts.verbose&&(u+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+B+" "),u+=" } "):u+=" {} ";var j=u;u=F.pop(),!e.compositeRule&&ie?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else e.isTop?l?u+=" return data; ":u+=" validate.errors = null; return true; ":u+=" var "+J+" = true; ";return e.isTop&&(u+=" }; return validate; "),u}if(e.isTop){var N=e.isTop,k=e.level=0,A=e.dataLevel=0,B="data";if(e.rootId=e.resolve.fullPath(e.self._getId(e.root.schema)),e.baseId=e.baseId||e.rootId,delete e.isTop,e.dataPathArr=[""],e.schema.default!==void 0&&e.opts.useDefaults&&e.opts.strictDefaults){var Y="default is ignored in the schema root";if(e.opts.strictDefaults==="log")e.logger.warn(Y);else throw new Error(Y)}u+=" var vErrors = null; ",u+=" var errors = 0;     ",u+=" if (rootData === undefined) rootData = data; "}else{var k=e.level,A=e.dataLevel,B="data"+(A||"");if(y&&(e.baseId=e.resolve.url(e.baseId,y)),l&&!e.async)throw new Error("async schema in sync schema");u+=" var errs_"+k+" = errors;"}var J="valid"+k,ie=!e.opts.allErrors,ue="",Q="",ce,he=e.schema.type,ke=Array.isArray(he);if(he&&e.opts.nullable&&e.schema.nullable===!0&&(ke?he.indexOf("null")==-1&&(he=he.concat("null")):he!="null"&&(he=[he,"null"],ke=!0)),ke&&he.length==1&&(he=he[0],ke=!1),e.schema.$ref&&m){if(e.opts.extendRefs=="fail")throw new Error('$ref: validation keywords used in schema at path "'+e.errSchemaPath+'" (see option extendRefs)');e.opts.extendRefs!==!0&&(m=!1,e.logger.warn('$ref: keywords ignored in schema at path "'+e.errSchemaPath+'"'))}if(e.schema.$comment&&e.opts.$comment&&(u+=" "+e.RULES.all.$comment.code(e,"$comment")),he){if(e.opts.coerceTypes)var L=e.util.coerceToTypes(e.opts.coerceTypes,he);var d=e.RULES.types[he];if(L||ke||d===!0||d&&!Je(d)){var P=e.schemaPath+".type",R=e.errSchemaPath+"/type",P=e.schemaPath+".type",R=e.errSchemaPath+"/type",v=ke?"checkDataTypes":"checkDataType";if(u+=" if ("+e.util[v](he,B,e.opts.strictNumbers,!0)+") { ",L){var w="dataType"+k,c="coerced"+k;u+=" var "+w+" = typeof "+B+"; var "+c+" = undefined; ",e.opts.coerceTypes=="array"&&(u+=" if ("+w+" == 'object' && Array.isArray("+B+") && "+B+".length == 1) { "+B+" = "+B+"[0]; "+w+" = typeof "+B+"; if ("+e.util.checkDataType(e.schema.type,B,e.opts.strictNumbers)+") "+c+" = "+B+"; } "),u+=" if ("+c+" !== undefined) ; ";var p=L;if(p)for(var x,S=-1,b=p.length-1;S<b;)x=p[S+=1],x=="string"?u+=" else if ("+w+" == 'number' || "+w+" == 'boolean') "+c+" = '' + "+B+"; else if ("+B+" === null) "+c+" = ''; ":x=="number"||x=="integer"?(u+=" else if ("+w+" == 'boolean' || "+B+" === null || ("+w+" == 'string' && "+B+" && "+B+" == +"+B+" ",x=="integer"&&(u+=" && !("+B+" % 1)"),u+=")) "+c+" = +"+B+"; "):x=="boolean"?u+=" else if ("+B+" === 'false' || "+B+" === 0 || "+B+" === null) "+c+" = false; else if ("+B+" === 'true' || "+B+" === 1) "+c+" = true; ":x=="null"?u+=" else if ("+B+" === '' || "+B+" === 0 || "+B+" === false) "+c+" = null; ":e.opts.coerceTypes=="array"&&x=="array"&&(u+=" else if ("+w+" == 'string' || "+w+" == 'number' || "+w+" == 'boolean' || "+B+" == null) "+c+" = ["+B+"]; ");u+=" else {   ";var F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(ce||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(R)+" , params: { type: '",ke?u+=""+he.join(","):u+=""+he,u+="' } ",e.opts.messages!==!1&&(u+=" , message: 'should be ",ke?u+=""+he.join(","):u+=""+he,u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+P+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+B+" "),u+=" } "):u+=" {} ";var j=u;u=F.pop(),!e.compositeRule&&ie?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } if ("+c+" !== undefined) {  ";var h=A?"data"+(A-1||""):"parentData",T=A?e.dataPathArr[A]:"parentDataProperty";u+=" "+B+" = "+c+"; ",A||(u+="if ("+h+" !== undefined)"),u+=" "+h+"["+T+"] = "+c+"; } "}else{var F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(ce||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(R)+" , params: { type: '",ke?u+=""+he.join(","):u+=""+he,u+="' } ",e.opts.messages!==!1&&(u+=" , message: 'should be ",ke?u+=""+he.join(","):u+=""+he,u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+P+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+B+" "),u+=" } "):u+=" {} ";var j=u;u=F.pop(),!e.compositeRule&&ie?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}u+=" } "}}if(e.schema.$ref&&!m)u+=" "+e.RULES.all.$ref.code(e,"$ref")+" ",ie&&(u+=" } if (errors === ",N?u+="0":u+="errs_"+k,u+=") { ",Q+="}");else{var M=e.RULES;if(M){for(var d,O=-1,V=M.length-1;O<V;)if(d=M[O+=1],Je(d)){if(d.type&&(u+=" if ("+e.util.checkDataType(d.type,B,e.opts.strictNumbers)+") { "),e.opts.useDefaults){if(d.type=="object"&&e.schema.properties){var D=e.schema.properties,ee=Object.keys(D),Z=ee;if(Z)for(var U,z=-1,ne=Z.length-1;z<ne;){U=Z[z+=1];var fe=D[U];if(fe.default!==void 0){var me=B+e.util.getProperty(U);if(e.compositeRule){if(e.opts.strictDefaults){var Y="default is ignored for: "+me;if(e.opts.strictDefaults==="log")e.logger.warn(Y);else throw new Error(Y)}}else u+=" if ("+me+" === undefined ",e.opts.useDefaults=="empty"&&(u+=" || "+me+" === null || "+me+" === '' "),u+=" ) "+me+" = ",e.opts.useDefaults=="shared"?u+=" "+e.useDefault(fe.default)+" ":u+=" "+JSON.stringify(fe.default)+" ",u+="; "}}}else if(d.type=="array"&&Array.isArray(e.schema.items)){var de=e.schema.items;if(de){for(var fe,S=-1,je=de.length-1;S<je;)if(fe=de[S+=1],fe.default!==void 0){var me=B+"["+S+"]";if(e.compositeRule){if(e.opts.strictDefaults){var Y="default is ignored for: "+me;if(e.opts.strictDefaults==="log")e.logger.warn(Y);else throw new Error(Y)}}else u+=" if ("+me+" === undefined ",e.opts.useDefaults=="empty"&&(u+=" || "+me+" === null || "+me+" === '' "),u+=" ) "+me+" = ",e.opts.useDefaults=="shared"?u+=" "+e.useDefault(fe.default)+" ":u+=" "+JSON.stringify(fe.default)+" ",u+="; "}}}}var lt=d.rules;if(lt){for(var it,ot=-1,Ct=lt.length-1;ot<Ct;)if(it=lt[ot+=1],tt(it)){var nt=it.code(e,it.keyword,d.type);nt&&(u+=" "+nt+" ",ie&&(ue+="}"))}}if(ie&&(u+=" "+ue+" ",ue=""),d.type&&(u+=" } ",he&&he===d.type&&!L)){u+=" else { ";var P=e.schemaPath+".type",R=e.errSchemaPath+"/type",F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(ce||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(R)+" , params: { type: '",ke?u+=""+he.join(","):u+=""+he,u+="' } ",e.opts.messages!==!1&&(u+=" , message: 'should be ",ke?u+=""+he.join(","):u+=""+he,u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+P+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+B+" "),u+=" } "):u+=" {} ";var j=u;u=F.pop(),!e.compositeRule&&ie?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } "}ie&&(u+=" if (errors === ",N?u+="0":u+="errs_"+k,u+=") { ",Q+="}")}}}ie&&(u+=" "+Q+" "),N?(l?(u+=" if (errors === 0) return data;           ",u+=" else throw new ValidationError(vErrors); "):(u+=" validate.errors = vErrors; ",u+=" return errors === 0;       "),u+=" }; return validate;"):u+=" var "+J+" = errors === errs_"+k+";";function Je(ht){for(var Ot=ht.rules,Ve=0;Ve<Ot.length;Ve++)if(tt(Ot[Ve]))return!0}function tt(ht){return e.schema[ht.keyword]!==void 0||ht.implements&&rt(ht)}function rt(ht){for(var Ot=ht.implements,Ve=0;Ve<Ot.length;Ve++)if(e.schema[Ot[Ve]]!==void 0)return!0}return u}),validate}var compile_1,hasRequiredCompile;function requireCompile(){if(hasRequiredCompile)return compile_1;hasRequiredCompile=1;var t=requireResolve(),e=requireUtil(),n=requireError_classes(),o=requireFastJsonStableStringify(),u=requireValidate(),l=e.ucs2length,m=requireFastDeepEqual(),y=n.Validation;compile_1=E;function E(j,N,Y,J){var ie=this,ue=this._opts,Q=[void 0],ce={},he=[],ke={},L=[],d={},v=[];N=N||{schema:j,refVal:Q,refs:ce};var w=C.call(this,j,N,J),c=this._compilations[w.index];if(w.compiling)return c.callValidate=h;var p=this._formats,x=this.RULES;try{var S=T(j,N,Y,J);c.validate=S;var b=c.callValidate;return b&&(b.schema=S.schema,b.errors=null,b.refs=S.refs,b.refVal=S.refVal,b.root=S.root,b.$async=S.$async,ue.sourceCode&&(b.source=S.source)),S}finally{k.call(this,j,N,J)}function h(){var fe=c.validate,me=fe.apply(this,arguments);return h.errors=fe.errors,me}function T(fe,me,de,je){var lt=!me||me&&me.schema==fe;if(me.schema!=N.schema)return E.call(ie,fe,me,de,je);var it=fe.$async===!0,ot=u({isTop:!0,schema:fe,isRoot:lt,baseId:je,root:me,schemaPath:"",errSchemaPath:"#",errorPath:'""',MissingRefError:n.MissingRef,RULES:x,validate:u,util:e,resolve:t,resolveRef:M,usePattern:U,useDefault:z,useCustomRule:ne,opts:ue,formats:p,logger:ie.logger,self:ie});ot=F(Q,R)+F(he,D)+F(L,P)+F(v,B)+ot,ue.processCode&&(ot=ue.processCode(ot,fe));var Ct;try{var nt=new Function("self","RULES","formats","root","refVal","defaults","customRules","equal","ucs2length","ValidationError",ot);Ct=nt(ie,x,p,N,Q,L,v,m,l,y),Q[0]=Ct}catch(Je){throw ie.logger.error("Error compiling schema, function code:",ot),Je}return Ct.schema=fe,Ct.errors=null,Ct.refs=ce,Ct.refVal=Q,Ct.root=lt?Ct:me,it&&(Ct.$async=!0),ue.sourceCode===!0&&(Ct.source={code:ot,patterns:he,defaults:L}),Ct}function M(fe,me,de){me=t.url(fe,me);var je=ce[me],lt,it;if(je!==void 0)return lt=Q[je],it="refVal["+je+"]",Z(lt,it);if(!de&&N.refs){var ot=N.refs[me];if(ot!==void 0)return lt=N.refVal[ot],it=O(me,lt),Z(lt,it)}it=O(me);var Ct=t.call(ie,T,N,me);if(Ct===void 0){var nt=Y&&Y[me];nt&&(Ct=t.inlineRef(nt,ue.inlineRefs)?nt:E.call(ie,nt,N,Y,fe))}if(Ct===void 0)V(me);else return ee(me,Ct),Z(Ct,it)}function O(fe,me){var de=Q.length;return Q[de]=me,ce[fe]=de,"refVal"+de}function V(fe){delete ce[fe]}function ee(fe,me){var de=ce[fe];Q[de]=me}function Z(fe,me){return typeof fe=="object"||typeof fe=="boolean"?{code:me,schema:fe,inline:!0}:{code:me,$async:fe&&!!fe.$async}}function U(fe){var me=ke[fe];return me===void 0&&(me=ke[fe]=he.length,he[me]=fe),"pattern"+me}function z(fe){switch(typeof fe){case"boolean":case"number":return""+fe;case"string":return e.toQuotedString(fe);case"object":if(fe===null)return"null";var me=o(fe),de=d[me];return de===void 0&&(de=d[me]=L.length,L[de]=fe),"default"+de}}function ne(fe,me,de,je){if(ie._opts.validateSchema!==!1){var lt=fe.definition.dependencies;if(lt&&!lt.every(function(Ot){return Object.prototype.hasOwnProperty.call(de,Ot)}))throw new Error("parent schema must have all required keywords: "+lt.join(","));var it=fe.definition.validateSchema;if(it){var ot=it(me);if(!ot){var Ct="keyword schema is invalid: "+ie.errorsText(it.errors);if(ie._opts.validateSchema=="log")ie.logger.error(Ct);else throw new Error(Ct)}}}var nt=fe.definition.compile,Je=fe.definition.inline,tt=fe.definition.macro,rt;if(nt)rt=nt.call(ie,me,de,je);else if(tt)rt=tt.call(ie,me,de,je),ue.validateSchema!==!1&&ie.validateSchema(rt,!0);else if(Je)rt=Je.call(ie,je,fe.keyword,me,de);else if(rt=fe.definition.validate,!rt)return;if(rt===void 0)throw new Error('custom keyword "'+fe.keyword+'"failed to compile');var ht=v.length;return v[ht]=rt,{code:"customRule"+ht,validate:rt}}}function C(j,N,Y){var J=A.call(this,j,N,Y);return J>=0?{index:J,compiling:!0}:(J=this._compilations.length,this._compilations[J]={schema:j,root:N,baseId:Y},{index:J,compiling:!1})}function k(j,N,Y){var J=A.call(this,j,N,Y);J>=0&&this._compilations.splice(J,1)}function A(j,N,Y){for(var J=0;J<this._compilations.length;J++){var ie=this._compilations[J];if(ie.schema==j&&ie.root==N&&ie.baseId==Y)return J}return-1}function D(j,N){return"var pattern"+j+" = new RegExp("+e.toQuotedString(N[j])+");"}function P(j){return"var default"+j+" = defaults["+j+"];"}function R(j,N){return N[j]===void 0?"":"var refVal"+j+" = refVal["+j+"];"}function B(j){return"var customRule"+j+" = customRules["+j+"];"}function F(j,N){if(!j.length)return"";for(var Y="",J=0;J<j.length;J++)Y+=N(J,j);return Y}return compile_1}var cache={exports:{}},hasRequiredCache;function requireCache(){if(hasRequiredCache)return cache.exports;hasRequiredCache=1;var t=cache.exports=function(){this._cache={}};return t.prototype.put=function(n,o){this._cache[n]=o},t.prototype.get=function(n){return this._cache[n]},t.prototype.del=function(n){delete this._cache[n]},t.prototype.clear=function(){this._cache={}},cache.exports}var formats_1,hasRequiredFormats;function requireFormats(){if(hasRequiredFormats)return formats_1;hasRequiredFormats=1;var t=requireUtil(),e=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,n=[0,31,28,31,30,31,30,31,31,30,31,30,31],o=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i,u=/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,l=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,m=/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,y=/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,E=/^(?:(?:http[s\u017F]?|ftp):\/\/)(?:(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+(?::(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?@)?(?:(?!10(?:\.[0-9]{1,3}){3})(?!127(?:\.[0-9]{1,3}){3})(?!169\.254(?:\.[0-9]{1,3}){2})(?!192\.168(?:\.[0-9]{1,3}){2})(?!172\.(?:1[6-9]|2[0-9]|3[01])(?:\.[0-9]{1,3}){2})(?:[1-9][0-9]?|1[0-9][0-9]|2[01][0-9]|22[0-3])(?:\.(?:1?[0-9]{1,2}|2[0-4][0-9]|25[0-5])){2}(?:\.(?:[1-9][0-9]?|1[0-9][0-9]|2[0-4][0-9]|25[0-4]))|(?:(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)(?:\.(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)*(?:\.(?:(?:[a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]){2,})))(?::[0-9]{2,5})?(?:\/(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?$/i,C=/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,k=/^(?:\/(?:[^~/]|~0|~1)*)*$/,A=/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,D=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;formats_1=P;function P(Q){return Q=Q=="full"?"full":"fast",t.copy(P[Q])}P.fast={date:/^\d\d\d\d-[0-1]\d-[0-3]\d$/,time:/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,"date-time":/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,"uri-template":y,url:E,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i,hostname:u,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:ue,uuid:C,"json-pointer":k,"json-pointer-uri-fragment":A,"relative-json-pointer":D},P.full={date:B,time:F,"date-time":N,uri:J,"uri-reference":m,"uri-template":y,url:E,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:u,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:ue,uuid:C,"json-pointer":k,"json-pointer-uri-fragment":A,"relative-json-pointer":D};function R(Q){return Q%4===0&&(Q%100!==0||Q%400===0)}function B(Q){var ce=Q.match(e);if(!ce)return!1;var he=+ce[1],ke=+ce[2],L=+ce[3];return ke>=1&&ke<=12&&L>=1&&L<=(ke==2&&R(he)?29:n[ke])}function F(Q,ce){var he=Q.match(o);if(!he)return!1;var ke=he[1],L=he[2],d=he[3],v=he[5];return(ke<=23&&L<=59&&d<=59||ke==23&&L==59&&d==60)&&(!ce||v)}var j=/t|\s/i;function N(Q){var ce=Q.split(j);return ce.length==2&&B(ce[0])&&F(ce[1],!0)}var Y=/\/|:/;function J(Q){return Y.test(Q)&&l.test(Q)}var ie=/[^\\]\\Z/;function ue(Q){if(ie.test(Q))return!1;try{return new RegExp(Q),!0}catch{return!1}}return formats_1}var ref,hasRequiredRef;function requireRef(){return hasRequiredRef||(hasRequiredRef=1,ref=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.errSchemaPath+"/"+n,C=!e.opts.allErrors,k="data"+(m||""),A="valid"+l,D,P;if(y=="#"||y=="#/")e.isRoot?(D=e.async,P="validate"):(D=e.root.schema.$async===!0,P="root.refVal[0]");else{var R=e.resolveRef(e.baseId,y,e.isRoot);if(R===void 0){var B=e.MissingRefError.message(e.baseId,y);if(e.opts.missingRefs=="fail"){e.logger.error(B);var F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '$ref' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(E)+" , params: { ref: '"+e.util.escapeQuotes(y)+"' } ",e.opts.messages!==!1&&(u+=" , message: 'can\\'t resolve reference "+e.util.escapeQuotes(y)+"' "),e.opts.verbose&&(u+=" , schema: "+e.util.toQuotedString(y)+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+k+" "),u+=" } "):u+=" {} ";var j=u;u=F.pop(),!e.compositeRule&&C?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",C&&(u+=" if (false) { ")}else if(e.opts.missingRefs=="ignore")e.logger.warn(B),C&&(u+=" if (true) { ");else throw new e.MissingRefError(e.baseId,y,B)}else if(R.inline){var N=e.util.copy(e);N.level++;var Y="valid"+N.level;N.schema=R.schema,N.schemaPath="",N.errSchemaPath=y;var J=e.validate(N).replace(/validate\.schema/g,R.code);u+=" "+J+" ",C&&(u+=" if ("+Y+") { ")}else D=R.$async===!0||e.async&&R.$async!==!1,P=R.code}if(P){var F=F||[];F.push(u),u="",e.opts.passContext?u+=" "+P+".call(this, ":u+=" "+P+"( ",u+=" "+k+", (dataPath || '')",e.errorPath!='""'&&(u+=" + "+e.errorPath);var ie=m?"data"+(m-1||""):"parentData",ue=m?e.dataPathArr[m]:"parentDataProperty";u+=" , "+ie+" , "+ue+", rootData)  ";var Q=u;if(u=F.pop(),D){if(!e.async)throw new Error("async schema referenced by sync schema");C&&(u+=" var "+A+"; "),u+=" try { await "+Q+"; ",C&&(u+=" "+A+" = true; "),u+=" } catch (e) { if (!(e instanceof ValidationError)) throw e; if (vErrors === null) vErrors = e.errors; else vErrors = vErrors.concat(e.errors); errors = vErrors.length; ",C&&(u+=" "+A+" = false; "),u+=" } ",C&&(u+=" if ("+A+") { ")}else u+=" if (!"+Q+") { if (vErrors === null) vErrors = "+P+".errors; else vErrors = vErrors.concat("+P+".errors); errors = vErrors.length; } ",C&&(u+=" else { ")}return u}),ref}var allOf,hasRequiredAllOf;function requireAllOf(){return hasRequiredAllOf||(hasRequiredAllOf=1,allOf=function(e,n,o){var u=" ",l=e.schema[n],m=e.schemaPath+e.util.getProperty(n),y=e.errSchemaPath+"/"+n,E=!e.opts.allErrors,C=e.util.copy(e),k="";C.level++;var A="valid"+C.level,D=C.baseId,P=!0,R=l;if(R)for(var B,F=-1,j=R.length-1;F<j;)B=R[F+=1],(e.opts.strictKeywords?typeof B=="object"&&Object.keys(B).length>0||B===!1:e.util.schemaHasRules(B,e.RULES.all))&&(P=!1,C.schema=B,C.schemaPath=m+"["+F+"]",C.errSchemaPath=y+"/"+F,u+="  "+e.validate(C)+" ",C.baseId=D,E&&(u+=" if ("+A+") { ",k+="}"));return E&&(P?u+=" if (true) { ":u+=" "+k.slice(0,-1)+" "),u}),allOf}var anyOf,hasRequiredAnyOf;function requireAnyOf(){return hasRequiredAnyOf||(hasRequiredAnyOf=1,anyOf=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P="errs__"+l,R=e.util.copy(e),B="";R.level++;var F="valid"+R.level,j=y.every(function(ce){return e.opts.strictKeywords?typeof ce=="object"&&Object.keys(ce).length>0||ce===!1:e.util.schemaHasRules(ce,e.RULES.all)});if(j){var N=R.baseId;u+=" var "+P+" = errors; var "+D+" = false;  ";var Y=e.compositeRule;e.compositeRule=R.compositeRule=!0;var J=y;if(J)for(var ie,ue=-1,Q=J.length-1;ue<Q;)ie=J[ue+=1],R.schema=ie,R.schemaPath=E+"["+ue+"]",R.errSchemaPath=C+"/"+ue,u+="  "+e.validate(R)+" ",R.baseId=N,u+=" "+D+" = "+D+" || "+F+"; if (!"+D+") { ",B+="}";e.compositeRule=R.compositeRule=Y,u+=" "+B+" if (!"+D+") {   var err =   ",e.createErrors!==!1?(u+=" { keyword: 'anyOf' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: {} ",e.opts.messages!==!1&&(u+=" , message: 'should match some schema in anyOf' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&k&&(e.async?u+=" throw new ValidationError(vErrors); ":u+=" validate.errors = vErrors; return false; "),u+=" } else {  errors = "+P+"; if (vErrors !== null) { if ("+P+") vErrors.length = "+P+"; else vErrors = null; } ",e.opts.allErrors&&(u+=" } ")}else k&&(u+=" if (true) { ");return u}),anyOf}var comment,hasRequiredComment;function requireComment(){return hasRequiredComment||(hasRequiredComment=1,comment=function(e,n,o){var u=" ",l=e.schema[n],m=e.errSchemaPath+"/"+n;e.opts.allErrors;var y=e.util.toQuotedString(l);return e.opts.$comment===!0?u+=" console.log("+y+");":typeof e.opts.$comment=="function"&&(u+=" self._opts.$comment("+y+", "+e.util.toQuotedString(m)+", validate.root.schema);"),u}),comment}var _const,hasRequired_const;function require_const(){return hasRequired_const||(hasRequired_const=1,_const=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P=e.opts.$data&&y&&y.$data;P&&(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; "),P||(u+=" var schema"+l+" = validate.schema"+E+";"),u+="var "+D+" = equal("+A+", schema"+l+"); if (!"+D+") {   ";var R=R||[];R.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'const' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { allowedValue: schema"+l+" } ",e.opts.messages!==!1&&(u+=" , message: 'should be equal to constant' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var B=u;return u=R.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+B+"]); ":u+=" validate.errors = ["+B+"]; return false; ":u+=" var err = "+B+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" }",k&&(u+=" else { "),u}),_const}var contains,hasRequiredContains;function requireContains(){return hasRequiredContains||(hasRequiredContains=1,contains=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P="errs__"+l,R=e.util.copy(e),B="";R.level++;var F="valid"+R.level,j="i"+l,N=R.dataLevel=e.dataLevel+1,Y="data"+N,J=e.baseId,ie=e.opts.strictKeywords?typeof y=="object"&&Object.keys(y).length>0||y===!1:e.util.schemaHasRules(y,e.RULES.all);if(u+="var "+P+" = errors;var "+D+";",ie){var ue=e.compositeRule;e.compositeRule=R.compositeRule=!0,R.schema=y,R.schemaPath=E,R.errSchemaPath=C,u+=" var "+F+" = false; for (var "+j+" = 0; "+j+" < "+A+".length; "+j+"++) { ",R.errorPath=e.util.getPathExpr(e.errorPath,j,e.opts.jsonPointers,!0);var Q=A+"["+j+"]";R.dataPathArr[N]=j;var ce=e.validate(R);R.baseId=J,e.util.varOccurences(ce,Y)<2?u+=" "+e.util.varReplace(ce,Y,Q)+" ":u+=" var "+Y+" = "+Q+"; "+ce+" ",u+=" if ("+F+") break; }  ",e.compositeRule=R.compositeRule=ue,u+=" "+B+" if (!"+F+") {"}else u+=" if ("+A+".length == 0) {";var he=he||[];he.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'contains' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: {} ",e.opts.messages!==!1&&(u+=" , message: 'should contain a valid item' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var ke=u;return u=he.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+ke+"]); ":u+=" validate.errors = ["+ke+"]; return false; ":u+=" var err = "+ke+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } else { ",ie&&(u+="  errors = "+P+"; if (vErrors !== null) { if ("+P+") vErrors.length = "+P+"; else vErrors = null; } "),e.opts.allErrors&&(u+=" } "),u}),contains}var dependencies,hasRequiredDependencies;function requireDependencies(){return hasRequiredDependencies||(hasRequiredDependencies=1,dependencies=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="errs__"+l,P=e.util.copy(e),R="";P.level++;var B="valid"+P.level,F={},j={},N=e.opts.ownProperties;for(ue in y)if(ue!="__proto__"){var Y=y[ue],J=Array.isArray(Y)?j:F;J[ue]=Y}u+="var "+D+" = errors;";var ie=e.errorPath;u+="var missing"+l+";";for(var ue in j)if(J=j[ue],J.length){if(u+=" if ( "+A+e.util.getProperty(ue)+" !== undefined ",N&&(u+=" && Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(ue)+"') "),k){u+=" && ( ";var Q=J;if(Q)for(var ce,he=-1,ke=Q.length-1;he<ke;){ce=Q[he+=1],he&&(u+=" || ");var L=e.util.getProperty(ce),d=A+L;u+=" ( ( "+d+" === undefined ",N&&(u+=" || ! Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(ce)+"') "),u+=") && (missing"+l+" = "+e.util.toQuotedString(e.opts.jsonPointers?ce:L)+") ) "}u+=")) {  ";var v="missing"+l,w="' + "+v+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.opts.jsonPointers?e.util.getPathExpr(ie,v,!0):ie+" + "+v);var c=c||[];c.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { property: '"+e.util.escapeQuotes(ue)+"', missingProperty: '"+w+"', depsCount: "+J.length+", deps: '"+e.util.escapeQuotes(J.length==1?J[0]:J.join(", "))+"' } ",e.opts.messages!==!1&&(u+=" , message: 'should have ",J.length==1?u+="property "+e.util.escapeQuotes(J[0]):u+="properties "+e.util.escapeQuotes(J.join(", ")),u+=" when property "+e.util.escapeQuotes(ue)+" is present' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var p=u;u=c.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+p+"]); ":u+=" validate.errors = ["+p+"]; return false; ":u+=" var err = "+p+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else{u+=" ) { ";var x=J;if(x)for(var ce,S=-1,b=x.length-1;S<b;){ce=x[S+=1];var L=e.util.getProperty(ce),w=e.util.escapeQuotes(ce),d=A+L;e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPath(ie,ce,e.opts.jsonPointers)),u+=" if ( "+d+" === undefined ",N&&(u+=" || ! Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(ce)+"') "),u+=") {  var err =   ",e.createErrors!==!1?(u+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { property: '"+e.util.escapeQuotes(ue)+"', missingProperty: '"+w+"', depsCount: "+J.length+", deps: '"+e.util.escapeQuotes(J.length==1?J[0]:J.join(", "))+"' } ",e.opts.messages!==!1&&(u+=" , message: 'should have ",J.length==1?u+="property "+e.util.escapeQuotes(J[0]):u+="properties "+e.util.escapeQuotes(J.join(", ")),u+=" when property "+e.util.escapeQuotes(ue)+" is present' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}u+=" }   ",k&&(R+="}",u+=" else { ")}e.errorPath=ie;var h=P.baseId;for(var ue in F){var Y=F[ue];(e.opts.strictKeywords?typeof Y=="object"&&Object.keys(Y).length>0||Y===!1:e.util.schemaHasRules(Y,e.RULES.all))&&(u+=" "+B+" = true; if ( "+A+e.util.getProperty(ue)+" !== undefined ",N&&(u+=" && Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(ue)+"') "),u+=") { ",P.schema=Y,P.schemaPath=E+e.util.getProperty(ue),P.errSchemaPath=C+"/"+e.util.escapeFragment(ue),u+="  "+e.validate(P)+" ",P.baseId=h,u+=" }  ",k&&(u+=" if ("+B+") { ",R+="}"))}return k&&(u+="   "+R+" if ("+D+" == errors) {"),u}),dependencies}var _enum,hasRequired_enum;function require_enum(){return hasRequired_enum||(hasRequired_enum=1,_enum=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P=e.opts.$data&&y&&y.$data;P&&(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ");var R="i"+l,B="schema"+l;P||(u+=" var "+B+" = validate.schema"+E+";"),u+="var "+D+";",P&&(u+=" if (schema"+l+" === undefined) "+D+" = true; else if (!Array.isArray(schema"+l+")) "+D+" = false; else {"),u+=""+D+" = false;for (var "+R+"=0; "+R+"<"+B+".length; "+R+"++) if (equal("+A+", "+B+"["+R+"])) { "+D+" = true; break; }",P&&(u+="  }  "),u+=" if (!"+D+") {   ";var F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'enum' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { allowedValues: schema"+l+" } ",e.opts.messages!==!1&&(u+=" , message: 'should be equal to one of the allowed values' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var j=u;return u=F.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" }",k&&(u+=" else { "),u}),_enum}var format,hasRequiredFormat;function requireFormat(){return hasRequiredFormat||(hasRequiredFormat=1,format=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||"");if(e.opts.format===!1)return k&&(u+=" if (true) { "),u;var D=e.opts.$data&&y&&y.$data,P;D?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",P="schema"+l):P=y;var R=e.opts.unknownFormats,B=Array.isArray(R);if(D){var F="format"+l,j="isObject"+l,N="formatType"+l;u+=" var "+F+" = formats["+P+"]; var "+j+" = typeof "+F+" == 'object' && !("+F+" instanceof RegExp) && "+F+".validate; var "+N+" = "+j+" && "+F+".type || 'string'; if ("+j+") { ",e.async&&(u+=" var async"+l+" = "+F+".async; "),u+=" "+F+" = "+F+".validate; } if (  ",D&&(u+=" ("+P+" !== undefined && typeof "+P+" != 'string') || "),u+=" (",R!="ignore"&&(u+=" ("+P+" && !"+F+" ",B&&(u+=" && self._opts.unknownFormats.indexOf("+P+") == -1 "),u+=") || "),u+=" ("+F+" && "+N+" == '"+o+"' && !(typeof "+F+" == 'function' ? ",e.async?u+=" (async"+l+" ? await "+F+"("+A+") : "+F+"("+A+")) ":u+=" "+F+"("+A+") ",u+=" : "+F+".test("+A+"))))) {"}else{var F=e.formats[y];if(!F){if(R=="ignore")return e.logger.warn('unknown format "'+y+'" ignored in schema at path "'+e.errSchemaPath+'"'),k&&(u+=" if (true) { "),u;if(B&&R.indexOf(y)>=0)return k&&(u+=" if (true) { "),u;throw new Error('unknown format "'+y+'" is used in schema at path "'+e.errSchemaPath+'"')}var j=typeof F=="object"&&!(F instanceof RegExp)&&F.validate,N=j&&F.type||"string";if(j){var Y=F.async===!0;F=F.validate}if(N!=o)return k&&(u+=" if (true) { "),u;if(Y){if(!e.async)throw new Error("async format in sync schema");var J="formats"+e.util.getProperty(y)+".validate";u+=" if (!(await "+J+"("+A+"))) { "}else{u+=" if (! ";var J="formats"+e.util.getProperty(y);j&&(J+=".validate"),typeof F=="function"?u+=" "+J+"("+A+") ":u+=" "+J+".test("+A+") ",u+=") { "}}var ie=ie||[];ie.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'format' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { format:  ",D?u+=""+P:u+=""+e.util.toQuotedString(y),u+="  } ",e.opts.messages!==!1&&(u+=` , message: 'should match format "`,D?u+="' + "+P+" + '":u+=""+e.util.escapeQuotes(y),u+=`"' `),e.opts.verbose&&(u+=" , schema:  ",D?u+="validate.schema"+E:u+=""+e.util.toQuotedString(y),u+="         , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var ue=u;return u=ie.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+ue+"]); ":u+=" validate.errors = ["+ue+"]; return false; ":u+=" var err = "+ue+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } ",k&&(u+=" else { "),u}),format}var _if,hasRequired_if;function require_if(){return hasRequired_if||(hasRequired_if=1,_if=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P="errs__"+l,R=e.util.copy(e);R.level++;var B="valid"+R.level,F=e.schema.then,j=e.schema.else,N=F!==void 0&&(e.opts.strictKeywords?typeof F=="object"&&Object.keys(F).length>0||F===!1:e.util.schemaHasRules(F,e.RULES.all)),Y=j!==void 0&&(e.opts.strictKeywords?typeof j=="object"&&Object.keys(j).length>0||j===!1:e.util.schemaHasRules(j,e.RULES.all)),J=R.baseId;if(N||Y){var ie;R.createErrors=!1,R.schema=y,R.schemaPath=E,R.errSchemaPath=C,u+=" var "+P+" = errors; var "+D+" = true;  ";var ue=e.compositeRule;e.compositeRule=R.compositeRule=!0,u+="  "+e.validate(R)+" ",R.baseId=J,R.createErrors=!0,u+="  errors = "+P+"; if (vErrors !== null) { if ("+P+") vErrors.length = "+P+"; else vErrors = null; }  ",e.compositeRule=R.compositeRule=ue,N?(u+=" if ("+B+") {  ",R.schema=e.schema.then,R.schemaPath=e.schemaPath+".then",R.errSchemaPath=e.errSchemaPath+"/then",u+="  "+e.validate(R)+" ",R.baseId=J,u+=" "+D+" = "+B+"; ",N&&Y?(ie="ifClause"+l,u+=" var "+ie+" = 'then'; "):ie="'then'",u+=" } ",Y&&(u+=" else { ")):u+=" if (!"+B+") { ",Y&&(R.schema=e.schema.else,R.schemaPath=e.schemaPath+".else",R.errSchemaPath=e.errSchemaPath+"/else",u+="  "+e.validate(R)+" ",R.baseId=J,u+=" "+D+" = "+B+"; ",N&&Y?(ie="ifClause"+l,u+=" var "+ie+" = 'else'; "):ie="'else'",u+=" } "),u+=" if (!"+D+") {   var err =   ",e.createErrors!==!1?(u+=" { keyword: 'if' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { failingKeyword: "+ie+" } ",e.opts.messages!==!1&&(u+=` , message: 'should match "' + `+ie+` + '" schema' `),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&k&&(e.async?u+=" throw new ValidationError(vErrors); ":u+=" validate.errors = vErrors; return false; "),u+=" }   ",k&&(u+=" else { ")}else k&&(u+=" if (true) { ");return u}),_if}var items,hasRequiredItems;function requireItems(){return hasRequiredItems||(hasRequiredItems=1,items=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P="errs__"+l,R=e.util.copy(e),B="";R.level++;var F="valid"+R.level,j="i"+l,N=R.dataLevel=e.dataLevel+1,Y="data"+N,J=e.baseId;if(u+="var "+P+" = errors;var "+D+";",Array.isArray(y)){var ie=e.schema.additionalItems;if(ie===!1){u+=" "+D+" = "+A+".length <= "+y.length+"; ";var ue=C;C=e.errSchemaPath+"/additionalItems",u+="  if (!"+D+") {   ";var Q=Q||[];Q.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'additionalItems' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { limit: "+y.length+" } ",e.opts.messages!==!1&&(u+=" , message: 'should NOT have more than "+y.length+" items' "),e.opts.verbose&&(u+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var ce=u;u=Q.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+ce+"]); ":u+=" validate.errors = ["+ce+"]; return false; ":u+=" var err = "+ce+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } ",C=ue,k&&(B+="}",u+=" else { ")}var he=y;if(he){for(var ke,L=-1,d=he.length-1;L<d;)if(ke=he[L+=1],e.opts.strictKeywords?typeof ke=="object"&&Object.keys(ke).length>0||ke===!1:e.util.schemaHasRules(ke,e.RULES.all)){u+=" "+F+" = true; if ("+A+".length > "+L+") { ";var v=A+"["+L+"]";R.schema=ke,R.schemaPath=E+"["+L+"]",R.errSchemaPath=C+"/"+L,R.errorPath=e.util.getPathExpr(e.errorPath,L,e.opts.jsonPointers,!0),R.dataPathArr[N]=L;var w=e.validate(R);R.baseId=J,e.util.varOccurences(w,Y)<2?u+=" "+e.util.varReplace(w,Y,v)+" ":u+=" var "+Y+" = "+v+"; "+w+" ",u+=" }  ",k&&(u+=" if ("+F+") { ",B+="}")}}if(typeof ie=="object"&&(e.opts.strictKeywords?typeof ie=="object"&&Object.keys(ie).length>0||ie===!1:e.util.schemaHasRules(ie,e.RULES.all))){R.schema=ie,R.schemaPath=e.schemaPath+".additionalItems",R.errSchemaPath=e.errSchemaPath+"/additionalItems",u+=" "+F+" = true; if ("+A+".length > "+y.length+") {  for (var "+j+" = "+y.length+"; "+j+" < "+A+".length; "+j+"++) { ",R.errorPath=e.util.getPathExpr(e.errorPath,j,e.opts.jsonPointers,!0);var v=A+"["+j+"]";R.dataPathArr[N]=j;var w=e.validate(R);R.baseId=J,e.util.varOccurences(w,Y)<2?u+=" "+e.util.varReplace(w,Y,v)+" ":u+=" var "+Y+" = "+v+"; "+w+" ",k&&(u+=" if (!"+F+") break; "),u+=" } }  ",k&&(u+=" if ("+F+") { ",B+="}")}}else if(e.opts.strictKeywords?typeof y=="object"&&Object.keys(y).length>0||y===!1:e.util.schemaHasRules(y,e.RULES.all)){R.schema=y,R.schemaPath=E,R.errSchemaPath=C,u+="  for (var "+j+" = 0; "+j+" < "+A+".length; "+j+"++) { ",R.errorPath=e.util.getPathExpr(e.errorPath,j,e.opts.jsonPointers,!0);var v=A+"["+j+"]";R.dataPathArr[N]=j;var w=e.validate(R);R.baseId=J,e.util.varOccurences(w,Y)<2?u+=" "+e.util.varReplace(w,Y,v)+" ":u+=" var "+Y+" = "+v+"; "+w+" ",k&&(u+=" if (!"+F+") break; "),u+=" }"}return k&&(u+=" "+B+" if ("+P+" == errors) {"),u}),items}var _limit,hasRequired_limit;function require_limit(){return hasRequired_limit||(hasRequired_limit=1,_limit=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,J,A="data"+(m||""),D=e.opts.$data&&y&&y.$data,P;D?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",P="schema"+l):P=y;var R=n=="maximum",B=R?"exclusiveMaximum":"exclusiveMinimum",F=e.schema[B],j=e.opts.$data&&F&&F.$data,N=R?"<":">",Y=R?">":"<",J=void 0;if(!(D||typeof y=="number"||y===void 0))throw new Error(n+" must be number");if(!(j||F===void 0||typeof F=="number"||typeof F=="boolean"))throw new Error(B+" must be number or boolean");if(j){var ie=e.util.getData(F.$data,m,e.dataPathArr),ue="exclusive"+l,Q="exclType"+l,ce="exclIsNumber"+l,he="op"+l,ke="' + "+he+" + '";u+=" var schemaExcl"+l+" = "+ie+"; ",ie="schemaExcl"+l,u+=" var "+ue+"; var "+Q+" = typeof "+ie+"; if ("+Q+" != 'boolean' && "+Q+" != 'undefined' && "+Q+" != 'number') { ";var J=B,L=L||[];L.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(J||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: {} ",e.opts.messages!==!1&&(u+=" , message: '"+B+" should be boolean' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var d=u;u=L.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+d+"]); ":u+=" validate.errors = ["+d+"]; return false; ":u+=" var err = "+d+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } else if ( ",D&&(u+=" ("+P+" !== undefined && typeof "+P+" != 'number') || "),u+=" "+Q+" == 'number' ? ( ("+ue+" = "+P+" === undefined || "+ie+" "+N+"= "+P+") ? "+A+" "+Y+"= "+ie+" : "+A+" "+Y+" "+P+" ) : ( ("+ue+" = "+ie+" === true) ? "+A+" "+Y+"= "+P+" : "+A+" "+Y+" "+P+" ) || "+A+" !== "+A+") { var op"+l+" = "+ue+" ? '"+N+"' : '"+N+"='; ",y===void 0&&(J=B,C=e.errSchemaPath+"/"+B,P=ie,D=j)}else{var ce=typeof F=="number",ke=N;if(ce&&D){var he="'"+ke+"'";u+=" if ( ",D&&(u+=" ("+P+" !== undefined && typeof "+P+" != 'number') || "),u+=" ( "+P+" === undefined || "+F+" "+N+"= "+P+" ? "+A+" "+Y+"= "+F+" : "+A+" "+Y+" "+P+" ) || "+A+" !== "+A+") { "}else{ce&&y===void 0?(ue=!0,J=B,C=e.errSchemaPath+"/"+B,P=F,Y+="="):(ce&&(P=Math[R?"min":"max"](F,y)),F===(ce?P:!0)?(ue=!0,J=B,C=e.errSchemaPath+"/"+B,Y+="="):(ue=!1,ke+="="));var he="'"+ke+"'";u+=" if ( ",D&&(u+=" ("+P+" !== undefined && typeof "+P+" != 'number') || "),u+=" "+A+" "+Y+" "+P+" || "+A+" !== "+A+") { "}}J=J||n;var L=L||[];L.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(J||"_limit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { comparison: "+he+", limit: "+P+", exclusive: "+ue+" } ",e.opts.messages!==!1&&(u+=" , message: 'should be "+ke+" ",D?u+="' + "+P:u+=""+P+"'"),e.opts.verbose&&(u+=" , schema:  ",D?u+="validate.schema"+E:u+=""+y,u+="         , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var d=u;return u=L.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+d+"]); ":u+=" validate.errors = ["+d+"]; return false; ":u+=" var err = "+d+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } ",k&&(u+=" else { "),u}),_limit}var _limitItems,hasRequired_limitItems;function require_limitItems(){return hasRequired_limitItems||(hasRequired_limitItems=1,_limitItems=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,B,A="data"+(m||""),D=e.opts.$data&&y&&y.$data,P;if(D?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",P="schema"+l):P=y,!(D||typeof y=="number"))throw new Error(n+" must be number");var R=n=="maxItems"?">":"<";u+="if ( ",D&&(u+=" ("+P+" !== undefined && typeof "+P+" != 'number') || "),u+=" "+A+".length "+R+" "+P+") { ";var B=n,F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(B||"_limitItems")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { limit: "+P+" } ",e.opts.messages!==!1&&(u+=" , message: 'should NOT have ",n=="maxItems"?u+="more":u+="fewer",u+=" than ",D?u+="' + "+P+" + '":u+=""+y,u+=" items' "),e.opts.verbose&&(u+=" , schema:  ",D?u+="validate.schema"+E:u+=""+y,u+="         , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var j=u;return u=F.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+="} ",k&&(u+=" else { "),u}),_limitItems}var _limitLength,hasRequired_limitLength;function require_limitLength(){return hasRequired_limitLength||(hasRequired_limitLength=1,_limitLength=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,B,A="data"+(m||""),D=e.opts.$data&&y&&y.$data,P;if(D?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",P="schema"+l):P=y,!(D||typeof y=="number"))throw new Error(n+" must be number");var R=n=="maxLength"?">":"<";u+="if ( ",D&&(u+=" ("+P+" !== undefined && typeof "+P+" != 'number') || "),e.opts.unicode===!1?u+=" "+A+".length ":u+=" ucs2length("+A+") ",u+=" "+R+" "+P+") { ";var B=n,F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(B||"_limitLength")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { limit: "+P+" } ",e.opts.messages!==!1&&(u+=" , message: 'should NOT be ",n=="maxLength"?u+="longer":u+="shorter",u+=" than ",D?u+="' + "+P+" + '":u+=""+y,u+=" characters' "),e.opts.verbose&&(u+=" , schema:  ",D?u+="validate.schema"+E:u+=""+y,u+="         , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var j=u;return u=F.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+="} ",k&&(u+=" else { "),u}),_limitLength}var _limitProperties,hasRequired_limitProperties;function require_limitProperties(){return hasRequired_limitProperties||(hasRequired_limitProperties=1,_limitProperties=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,B,A="data"+(m||""),D=e.opts.$data&&y&&y.$data,P;if(D?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",P="schema"+l):P=y,!(D||typeof y=="number"))throw new Error(n+" must be number");var R=n=="maxProperties"?">":"<";u+="if ( ",D&&(u+=" ("+P+" !== undefined && typeof "+P+" != 'number') || "),u+=" Object.keys("+A+").length "+R+" "+P+") { ";var B=n,F=F||[];F.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(B||"_limitProperties")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { limit: "+P+" } ",e.opts.messages!==!1&&(u+=" , message: 'should NOT have ",n=="maxProperties"?u+="more":u+="fewer",u+=" than ",D?u+="' + "+P+" + '":u+=""+y,u+=" properties' "),e.opts.verbose&&(u+=" , schema:  ",D?u+="validate.schema"+E:u+=""+y,u+="         , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var j=u;return u=F.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+j+"]); ":u+=" validate.errors = ["+j+"]; return false; ":u+=" var err = "+j+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+="} ",k&&(u+=" else { "),u}),_limitProperties}var multipleOf,hasRequiredMultipleOf;function requireMultipleOf(){return hasRequiredMultipleOf||(hasRequiredMultipleOf=1,multipleOf=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D=e.opts.$data&&y&&y.$data,P;if(D?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",P="schema"+l):P=y,!(D||typeof y=="number"))throw new Error(n+" must be number");u+="var division"+l+";if (",D&&(u+=" "+P+" !== undefined && ( typeof "+P+" != 'number' || "),u+=" (division"+l+" = "+A+" / "+P+", ",e.opts.multipleOfPrecision?u+=" Math.abs(Math.round(division"+l+") - division"+l+") > 1e-"+e.opts.multipleOfPrecision+" ":u+=" division"+l+" !== parseInt(division"+l+") ",u+=" ) ",D&&(u+="  )  "),u+=" ) {   ";var R=R||[];R.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'multipleOf' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { multipleOf: "+P+" } ",e.opts.messages!==!1&&(u+=" , message: 'should be multiple of ",D?u+="' + "+P:u+=""+P+"'"),e.opts.verbose&&(u+=" , schema:  ",D?u+="validate.schema"+E:u+=""+y,u+="         , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var B=u;return u=R.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+B+"]); ":u+=" validate.errors = ["+B+"]; return false; ":u+=" var err = "+B+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+="} ",k&&(u+=" else { "),u}),multipleOf}var not,hasRequiredNot;function requireNot(){return hasRequiredNot||(hasRequiredNot=1,not=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="errs__"+l,P=e.util.copy(e);P.level++;var R="valid"+P.level;if(e.opts.strictKeywords?typeof y=="object"&&Object.keys(y).length>0||y===!1:e.util.schemaHasRules(y,e.RULES.all)){P.schema=y,P.schemaPath=E,P.errSchemaPath=C,u+=" var "+D+" = errors;  ";var B=e.compositeRule;e.compositeRule=P.compositeRule=!0,P.createErrors=!1;var F;P.opts.allErrors&&(F=P.opts.allErrors,P.opts.allErrors=!1),u+=" "+e.validate(P)+" ",P.createErrors=!0,F&&(P.opts.allErrors=F),e.compositeRule=P.compositeRule=B,u+=" if ("+R+") {   ";var j=j||[];j.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'not' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: {} ",e.opts.messages!==!1&&(u+=" , message: 'should NOT be valid' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var N=u;u=j.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+N+"]); ":u+=" validate.errors = ["+N+"]; return false; ":u+=" var err = "+N+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } else {  errors = "+D+"; if (vErrors !== null) { if ("+D+") vErrors.length = "+D+"; else vErrors = null; } ",e.opts.allErrors&&(u+=" } ")}else u+="  var err =   ",e.createErrors!==!1?(u+=" { keyword: 'not' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: {} ",e.opts.messages!==!1&&(u+=" , message: 'should NOT be valid' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",k&&(u+=" if (false) { ");return u}),not}var oneOf,hasRequiredOneOf;function requireOneOf(){return hasRequiredOneOf||(hasRequiredOneOf=1,oneOf=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P="errs__"+l,R=e.util.copy(e),B="";R.level++;var F="valid"+R.level,j=R.baseId,N="prevValid"+l,Y="passingSchemas"+l;u+="var "+P+" = errors , "+N+" = false , "+D+" = false , "+Y+" = null; ";var J=e.compositeRule;e.compositeRule=R.compositeRule=!0;var ie=y;if(ie)for(var ue,Q=-1,ce=ie.length-1;Q<ce;)ue=ie[Q+=1],(e.opts.strictKeywords?typeof ue=="object"&&Object.keys(ue).length>0||ue===!1:e.util.schemaHasRules(ue,e.RULES.all))?(R.schema=ue,R.schemaPath=E+"["+Q+"]",R.errSchemaPath=C+"/"+Q,u+="  "+e.validate(R)+" ",R.baseId=j):u+=" var "+F+" = true; ",Q&&(u+=" if ("+F+" && "+N+") { "+D+" = false; "+Y+" = ["+Y+", "+Q+"]; } else { ",B+="}"),u+=" if ("+F+") { "+D+" = "+N+" = true; "+Y+" = "+Q+"; }";return e.compositeRule=R.compositeRule=J,u+=""+B+"if (!"+D+") {   var err =   ",e.createErrors!==!1?(u+=" { keyword: 'oneOf' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { passingSchemas: "+Y+" } ",e.opts.messages!==!1&&(u+=" , message: 'should match exactly one schema in oneOf' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&k&&(e.async?u+=" throw new ValidationError(vErrors); ":u+=" validate.errors = vErrors; return false; "),u+="} else {  errors = "+P+"; if (vErrors !== null) { if ("+P+") vErrors.length = "+P+"; else vErrors = null; }",e.opts.allErrors&&(u+=" } "),u}),oneOf}var pattern,hasRequiredPattern;function requirePattern(){return hasRequiredPattern||(hasRequiredPattern=1,pattern=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D=e.opts.$data&&y&&y.$data,P;D?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",P="schema"+l):P=y;var R=D?"(new RegExp("+P+"))":e.usePattern(y);u+="if ( ",D&&(u+=" ("+P+" !== undefined && typeof "+P+" != 'string') || "),u+=" !"+R+".test("+A+") ) {   ";var B=B||[];B.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'pattern' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { pattern:  ",D?u+=""+P:u+=""+e.util.toQuotedString(y),u+="  } ",e.opts.messages!==!1&&(u+=` , message: 'should match pattern "`,D?u+="' + "+P+" + '":u+=""+e.util.escapeQuotes(y),u+=`"' `),e.opts.verbose&&(u+=" , schema:  ",D?u+="validate.schema"+E:u+=""+e.util.toQuotedString(y),u+="         , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var F=u;return u=B.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+F+"]); ":u+=" validate.errors = ["+F+"]; return false; ":u+=" var err = "+F+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+="} ",k&&(u+=" else { "),u}),pattern}var properties$l,hasRequiredProperties;function requireProperties(){return hasRequiredProperties||(hasRequiredProperties=1,properties$l=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="errs__"+l,P=e.util.copy(e),R="";P.level++;var B="valid"+P.level,F="key"+l,j="idx"+l,N=P.dataLevel=e.dataLevel+1,Y="data"+N,J="dataProperties"+l,ie=Object.keys(y||{}).filter(S),ue=e.schema.patternProperties||{},Q=Object.keys(ue).filter(S),ce=e.schema.additionalProperties,he=ie.length||Q.length,ke=ce===!1,L=typeof ce=="object"&&Object.keys(ce).length,d=e.opts.removeAdditional,v=ke||L||d,w=e.opts.ownProperties,c=e.baseId,p=e.schema.required;if(p&&!(e.opts.$data&&p.$data)&&p.length<e.opts.loopRequired)var x=e.util.toHash(p);function S(wt){return wt!=="__proto__"}if(u+="var "+D+" = errors;var "+B+" = true;",w&&(u+=" var "+J+" = undefined;"),v){if(w?u+=" "+J+" = "+J+" || Object.keys("+A+"); for (var "+j+"=0; "+j+"<"+J+".length; "+j+"++) { var "+F+" = "+J+"["+j+"]; ":u+=" for (var "+F+" in "+A+") { ",he){if(u+=" var isAdditional"+l+" = !(false ",ie.length)if(ie.length>8)u+=" || validate.schema"+E+".hasOwnProperty("+F+") ";else{var b=ie;if(b)for(var h,T=-1,M=b.length-1;T<M;)h=b[T+=1],u+=" || "+F+" == "+e.util.toQuotedString(h)+" "}if(Q.length){var O=Q;if(O)for(var V,ee=-1,Z=O.length-1;ee<Z;)V=O[ee+=1],u+=" || "+e.usePattern(V)+".test("+F+") "}u+=" ); if (isAdditional"+l+") { "}if(d=="all")u+=" delete "+A+"["+F+"]; ";else{var U=e.errorPath,z="' + "+F+" + '";if(e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPathExpr(e.errorPath,F,e.opts.jsonPointers)),ke)if(d)u+=" delete "+A+"["+F+"]; ";else{u+=" "+B+" = false; ";var ne=C;C=e.errSchemaPath+"/additionalProperties";var fe=fe||[];fe.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'additionalProperties' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { additionalProperty: '"+z+"' } ",e.opts.messages!==!1&&(u+=" , message: '",e.opts._errorDataPathProperty?u+="is an invalid additional property":u+="should NOT have additional properties",u+="' "),e.opts.verbose&&(u+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var me=u;u=fe.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+me+"]); ":u+=" validate.errors = ["+me+"]; return false; ":u+=" var err = "+me+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",C=ne,k&&(u+=" break; ")}else if(L)if(d=="failing"){u+=" var "+D+" = errors;  ";var de=e.compositeRule;e.compositeRule=P.compositeRule=!0,P.schema=ce,P.schemaPath=e.schemaPath+".additionalProperties",P.errSchemaPath=e.errSchemaPath+"/additionalProperties",P.errorPath=e.opts._errorDataPathProperty?e.errorPath:e.util.getPathExpr(e.errorPath,F,e.opts.jsonPointers);var je=A+"["+F+"]";P.dataPathArr[N]=F;var lt=e.validate(P);P.baseId=c,e.util.varOccurences(lt,Y)<2?u+=" "+e.util.varReplace(lt,Y,je)+" ":u+=" var "+Y+" = "+je+"; "+lt+" ",u+=" if (!"+B+") { errors = "+D+"; if (validate.errors !== null) { if (errors) validate.errors.length = errors; else validate.errors = null; } delete "+A+"["+F+"]; }  ",e.compositeRule=P.compositeRule=de}else{P.schema=ce,P.schemaPath=e.schemaPath+".additionalProperties",P.errSchemaPath=e.errSchemaPath+"/additionalProperties",P.errorPath=e.opts._errorDataPathProperty?e.errorPath:e.util.getPathExpr(e.errorPath,F,e.opts.jsonPointers);var je=A+"["+F+"]";P.dataPathArr[N]=F;var lt=e.validate(P);P.baseId=c,e.util.varOccurences(lt,Y)<2?u+=" "+e.util.varReplace(lt,Y,je)+" ":u+=" var "+Y+" = "+je+"; "+lt+" ",k&&(u+=" if (!"+B+") break; ")}e.errorPath=U}he&&(u+=" } "),u+=" }  ",k&&(u+=" if ("+B+") { ",R+="}")}var it=e.opts.useDefaults&&!e.compositeRule;if(ie.length){var ot=ie;if(ot)for(var h,Ct=-1,nt=ot.length-1;Ct<nt;){h=ot[Ct+=1];var Je=y[h];if(e.opts.strictKeywords?typeof Je=="object"&&Object.keys(Je).length>0||Je===!1:e.util.schemaHasRules(Je,e.RULES.all)){var tt=e.util.getProperty(h),je=A+tt,rt=it&&Je.default!==void 0;P.schema=Je,P.schemaPath=E+tt,P.errSchemaPath=C+"/"+e.util.escapeFragment(h),P.errorPath=e.util.getPath(e.errorPath,h,e.opts.jsonPointers),P.dataPathArr[N]=e.util.toQuotedString(h);var lt=e.validate(P);if(P.baseId=c,e.util.varOccurences(lt,Y)<2){lt=e.util.varReplace(lt,Y,je);var ht=je}else{var ht=Y;u+=" var "+Y+" = "+je+"; "}if(rt)u+=" "+lt+" ";else{if(x&&x[h]){u+=" if ( "+ht+" === undefined ",w&&(u+=" || ! Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(h)+"') "),u+=") { "+B+" = false; ";var U=e.errorPath,ne=C,Ot=e.util.escapeQuotes(h);e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPath(U,h,e.opts.jsonPointers)),C=e.errSchemaPath+"/required";var fe=fe||[];fe.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { missingProperty: '"+Ot+"' } ",e.opts.messages!==!1&&(u+=" , message: '",e.opts._errorDataPathProperty?u+="is a required property":u+="should have required property \\'"+Ot+"\\'",u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var me=u;u=fe.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+me+"]); ":u+=" validate.errors = ["+me+"]; return false; ":u+=" var err = "+me+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",C=ne,e.errorPath=U,u+=" } else { "}else k?(u+=" if ( "+ht+" === undefined ",w&&(u+=" || ! Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(h)+"') "),u+=") { "+B+" = true; } else { "):(u+=" if ("+ht+" !== undefined ",w&&(u+=" &&   Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(h)+"') "),u+=" ) { ");u+=" "+lt+" } "}}k&&(u+=" if ("+B+") { ",R+="}")}}if(Q.length){var Ve=Q;if(Ve)for(var V,We=-1,Gt=Ve.length-1;We<Gt;){V=Ve[We+=1];var Je=ue[V];if(e.opts.strictKeywords?typeof Je=="object"&&Object.keys(Je).length>0||Je===!1:e.util.schemaHasRules(Je,e.RULES.all)){P.schema=Je,P.schemaPath=e.schemaPath+".patternProperties"+e.util.getProperty(V),P.errSchemaPath=e.errSchemaPath+"/patternProperties/"+e.util.escapeFragment(V),w?u+=" "+J+" = "+J+" || Object.keys("+A+"); for (var "+j+"=0; "+j+"<"+J+".length; "+j+"++) { var "+F+" = "+J+"["+j+"]; ":u+=" for (var "+F+" in "+A+") { ",u+=" if ("+e.usePattern(V)+".test("+F+")) { ",P.errorPath=e.util.getPathExpr(e.errorPath,F,e.opts.jsonPointers);var je=A+"["+F+"]";P.dataPathArr[N]=F;var lt=e.validate(P);P.baseId=c,e.util.varOccurences(lt,Y)<2?u+=" "+e.util.varReplace(lt,Y,je)+" ":u+=" var "+Y+" = "+je+"; "+lt+" ",k&&(u+=" if (!"+B+") break; "),u+=" } ",k&&(u+=" else "+B+" = true; "),u+=" }  ",k&&(u+=" if ("+B+") { ",R+="}")}}}return k&&(u+=" "+R+" if ("+D+" == errors) {"),u}),properties$l}var propertyNames,hasRequiredPropertyNames;function requirePropertyNames(){return hasRequiredPropertyNames||(hasRequiredPropertyNames=1,propertyNames=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="errs__"+l,P=e.util.copy(e),R="";P.level++;var B="valid"+P.level;if(u+="var "+D+" = errors;",e.opts.strictKeywords?typeof y=="object"&&Object.keys(y).length>0||y===!1:e.util.schemaHasRules(y,e.RULES.all)){P.schema=y,P.schemaPath=E,P.errSchemaPath=C;var F="key"+l,j="idx"+l,N="i"+l,Y="' + "+F+" + '",J=P.dataLevel=e.dataLevel+1,ie="data"+J,ue="dataProperties"+l,Q=e.opts.ownProperties,ce=e.baseId;Q&&(u+=" var "+ue+" = undefined; "),Q?u+=" "+ue+" = "+ue+" || Object.keys("+A+"); for (var "+j+"=0; "+j+"<"+ue+".length; "+j+"++) { var "+F+" = "+ue+"["+j+"]; ":u+=" for (var "+F+" in "+A+") { ",u+=" var startErrs"+l+" = errors; ";var he=F,ke=e.compositeRule;e.compositeRule=P.compositeRule=!0;var L=e.validate(P);P.baseId=ce,e.util.varOccurences(L,ie)<2?u+=" "+e.util.varReplace(L,ie,he)+" ":u+=" var "+ie+" = "+he+"; "+L+" ",e.compositeRule=P.compositeRule=ke,u+=" if (!"+B+") { for (var "+N+"=startErrs"+l+"; "+N+"<errors; "+N+"++) { vErrors["+N+"].propertyName = "+F+"; }   var err =   ",e.createErrors!==!1?(u+=" { keyword: 'propertyNames' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { propertyName: '"+Y+"' } ",e.opts.messages!==!1&&(u+=" , message: 'property name \\'"+Y+"\\' is invalid' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&k&&(e.async?u+=" throw new ValidationError(vErrors); ":u+=" validate.errors = vErrors; return false; "),k&&(u+=" break; "),u+=" } }"}return k&&(u+=" "+R+" if ("+D+" == errors) {"),u}),propertyNames}var required$h,hasRequiredRequired;function requireRequired(){return hasRequiredRequired||(hasRequiredRequired=1,required$h=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P=e.opts.$data&&y&&y.$data;P&&(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ");var R="schema"+l;if(!P)if(y.length<e.opts.loopRequired&&e.schema.properties&&Object.keys(e.schema.properties).length){var B=[],F=y;if(F)for(var j,N=-1,Y=F.length-1;N<Y;){j=F[N+=1];var J=e.schema.properties[j];J&&(e.opts.strictKeywords?typeof J=="object"&&Object.keys(J).length>0||J===!1:e.util.schemaHasRules(J,e.RULES.all))||(B[B.length]=j)}}else var B=y;if(P||B.length){var ie=e.errorPath,ue=P||B.length>=e.opts.loopRequired,Q=e.opts.ownProperties;if(k)if(u+=" var missing"+l+"; ",ue){P||(u+=" var "+R+" = validate.schema"+E+"; ");var ce="i"+l,he="schema"+l+"["+ce+"]",ke="' + "+he+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPathExpr(ie,he,e.opts.jsonPointers)),u+=" var "+D+" = true; ",P&&(u+=" if (schema"+l+" === undefined) "+D+" = true; else if (!Array.isArray(schema"+l+")) "+D+" = false; else {"),u+=" for (var "+ce+" = 0; "+ce+" < "+R+".length; "+ce+"++) { "+D+" = "+A+"["+R+"["+ce+"]] !== undefined ",Q&&(u+=" &&   Object.prototype.hasOwnProperty.call("+A+", "+R+"["+ce+"]) "),u+="; if (!"+D+") break; } ",P&&(u+="  }  "),u+="  if (!"+D+") {   ";var L=L||[];L.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { missingProperty: '"+ke+"' } ",e.opts.messages!==!1&&(u+=" , message: '",e.opts._errorDataPathProperty?u+="is a required property":u+="should have required property \\'"+ke+"\\'",u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var d=u;u=L.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+d+"]); ":u+=" validate.errors = ["+d+"]; return false; ":u+=" var err = "+d+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } else { "}else{u+=" if ( ";var v=B;if(v)for(var w,ce=-1,c=v.length-1;ce<c;){w=v[ce+=1],ce&&(u+=" || ");var p=e.util.getProperty(w),x=A+p;u+=" ( ( "+x+" === undefined ",Q&&(u+=" || ! Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(w)+"') "),u+=") && (missing"+l+" = "+e.util.toQuotedString(e.opts.jsonPointers?w:p)+") ) "}u+=") {  ";var he="missing"+l,ke="' + "+he+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.opts.jsonPointers?e.util.getPathExpr(ie,he,!0):ie+" + "+he);var L=L||[];L.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { missingProperty: '"+ke+"' } ",e.opts.messages!==!1&&(u+=" , message: '",e.opts._errorDataPathProperty?u+="is a required property":u+="should have required property \\'"+ke+"\\'",u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var d=u;u=L.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+d+"]); ":u+=" validate.errors = ["+d+"]; return false; ":u+=" var err = "+d+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } else { "}else if(ue){P||(u+=" var "+R+" = validate.schema"+E+"; ");var ce="i"+l,he="schema"+l+"["+ce+"]",ke="' + "+he+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPathExpr(ie,he,e.opts.jsonPointers)),P&&(u+=" if ("+R+" && !Array.isArray("+R+")) {  var err =   ",e.createErrors!==!1?(u+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { missingProperty: '"+ke+"' } ",e.opts.messages!==!1&&(u+=" , message: '",e.opts._errorDataPathProperty?u+="is a required property":u+="should have required property \\'"+ke+"\\'",u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } else if ("+R+" !== undefined) { "),u+=" for (var "+ce+" = 0; "+ce+" < "+R+".length; "+ce+"++) { if ("+A+"["+R+"["+ce+"]] === undefined ",Q&&(u+=" || ! Object.prototype.hasOwnProperty.call("+A+", "+R+"["+ce+"]) "),u+=") {  var err =   ",e.createErrors!==!1?(u+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { missingProperty: '"+ke+"' } ",e.opts.messages!==!1&&(u+=" , message: '",e.opts._errorDataPathProperty?u+="is a required property":u+="should have required property \\'"+ke+"\\'",u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } } ",P&&(u+="  }  ")}else{var S=B;if(S)for(var w,b=-1,h=S.length-1;b<h;){w=S[b+=1];var p=e.util.getProperty(w),ke=e.util.escapeQuotes(w),x=A+p;e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPath(ie,w,e.opts.jsonPointers)),u+=" if ( "+x+" === undefined ",Q&&(u+=" || ! Object.prototype.hasOwnProperty.call("+A+", '"+e.util.escapeQuotes(w)+"') "),u+=") {  var err =   ",e.createErrors!==!1?(u+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { missingProperty: '"+ke+"' } ",e.opts.messages!==!1&&(u+=" , message: '",e.opts._errorDataPathProperty?u+="is a required property":u+="should have required property \\'"+ke+"\\'",u+="' "),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}e.errorPath=ie}else k&&(u+=" if (true) {");return u}),required$h}var uniqueItems,hasRequiredUniqueItems;function requireUniqueItems(){return hasRequiredUniqueItems||(hasRequiredUniqueItems=1,uniqueItems=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A="data"+(m||""),D="valid"+l,P=e.opts.$data&&y&&y.$data,R;if(P?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",R="schema"+l):R=y,(y||P)&&e.opts.uniqueItems!==!1){P&&(u+=" var "+D+"; if ("+R+" === false || "+R+" === undefined) "+D+" = true; else if (typeof "+R+" != 'boolean') "+D+" = false; else { "),u+=" var i = "+A+".length , "+D+" = true , j; if (i > 1) { ";var B=e.schema.items&&e.schema.items.type,F=Array.isArray(B);if(!B||B=="object"||B=="array"||F&&(B.indexOf("object")>=0||B.indexOf("array")>=0))u+=" outer: for (;i--;) { for (j = i; j--;) { if (equal("+A+"[i], "+A+"[j])) { "+D+" = false; break outer; } } } ";else{u+=" var itemIndices = {}, item; for (;i--;) { var item = "+A+"[i]; ";var j="checkDataType"+(F?"s":"");u+=" if ("+e.util[j](B,"item",e.opts.strictNumbers,!0)+") continue; ",F&&(u+=` if (typeof item == 'string') item = '"' + item; `),u+=" if (typeof itemIndices[item] == 'number') { "+D+" = false; j = itemIndices[item]; break; } itemIndices[item] = i; } "}u+=" } ",P&&(u+="  }  "),u+=" if (!"+D+") {   ";var N=N||[];N.push(u),u="",e.createErrors!==!1?(u+=" { keyword: 'uniqueItems' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { i: i, j: j } ",e.opts.messages!==!1&&(u+=" , message: 'should NOT have duplicate items (items ## ' + j + ' and ' + i + ' are identical)' "),e.opts.verbose&&(u+=" , schema:  ",P?u+="validate.schema"+E:u+=""+y,u+="         , parentSchema: validate.schema"+e.schemaPath+" , data: "+A+" "),u+=" } "):u+=" {} ";var Y=u;u=N.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+Y+"]); ":u+=" validate.errors = ["+Y+"]; return false; ":u+=" var err = "+Y+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u+=" } ",k&&(u+=" else { ")}else k&&(u+=" if (true) { ");return u}),uniqueItems}var dotjs,hasRequiredDotjs;function requireDotjs(){return hasRequiredDotjs||(hasRequiredDotjs=1,dotjs={$ref:requireRef(),allOf:requireAllOf(),anyOf:requireAnyOf(),$comment:requireComment(),const:require_const(),contains:requireContains(),dependencies:requireDependencies(),enum:require_enum(),format:requireFormat(),if:require_if(),items:requireItems(),maximum:require_limit(),minimum:require_limit(),maxItems:require_limitItems(),minItems:require_limitItems(),maxLength:require_limitLength(),minLength:require_limitLength(),maxProperties:require_limitProperties(),minProperties:require_limitProperties(),multipleOf:requireMultipleOf(),not:requireNot(),oneOf:requireOneOf(),pattern:requirePattern(),properties:requireProperties(),propertyNames:requirePropertyNames(),required:requireRequired(),uniqueItems:requireUniqueItems(),validate:requireValidate()}),dotjs}var rules,hasRequiredRules;function requireRules(){if(hasRequiredRules)return rules;hasRequiredRules=1;var t=requireDotjs(),e=requireUtil().toHash;return rules=function(){var o=[{type:"number",rules:[{maximum:["exclusiveMaximum"]},{minimum:["exclusiveMinimum"]},"multipleOf","format"]},{type:"string",rules:["maxLength","minLength","pattern","format"]},{type:"array",rules:["maxItems","minItems","items","contains","uniqueItems"]},{type:"object",rules:["maxProperties","minProperties","required","dependencies","propertyNames",{properties:["additionalProperties","patternProperties"]}]},{rules:["$ref","const","enum","not","anyOf","oneOf","allOf","if"]}],u=["type","$comment"],l=["$schema","$id","id","$data","$async","title","description","default","definitions","examples","readOnly","writeOnly","contentMediaType","contentEncoding","additionalItems","then","else"],m=["number","integer","string","array","object","boolean","null"];return o.all=e(u),o.types=e(m),o.forEach(function(y){y.rules=y.rules.map(function(E){var C;if(typeof E=="object"){var k=Object.keys(E)[0];C=E[k],E=k,C.forEach(function(D){u.push(D),o.all[D]=!0})}u.push(E);var A=o.all[E]={keyword:E,code:t[E],implements:C};return A}),o.all.$comment={keyword:"$comment",code:t.$comment},y.type&&(o.types[y.type]=y)}),o.keywords=e(u.concat(l)),o.custom={},o},rules}var data,hasRequiredData;function requireData(){if(hasRequiredData)return data;hasRequiredData=1;var t=["multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","additionalItems","maxItems","minItems","uniqueItems","maxProperties","minProperties","required","additionalProperties","enum","format","const"];return data=function(e,n){for(var o=0;o<n.length;o++){e=JSON.parse(JSON.stringify(e));var u=n[o].split("/"),l=e,m;for(m=1;m<u.length;m++)l=l[u[m]];for(m=0;m<t.length;m++){var y=t[m],E=l[y];E&&(l[y]={anyOf:[E,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]})}}return e},data}var async,hasRequiredAsync;function requireAsync(){if(hasRequiredAsync)return async;hasRequiredAsync=1;var t=requireError_classes().MissingRef;async=e;function e(n,o,u){var l=this;if(typeof this._opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");typeof o=="function"&&(u=o,o=void 0);var m=y(n).then(function(){var C=l._addSchema(n,void 0,o);return C.validate||E(C)});return u&&m.then(function(C){u(null,C)},u),m;function y(C){var k=C.$schema;return k&&!l.getSchema(k)?e.call(l,{$ref:k},!0):Promise.resolve()}function E(C){try{return l._compile(C)}catch(A){if(A instanceof t)return k(A);throw A}function k(A){var D=A.missingSchema;if(B(D))throw new Error("Schema "+D+" is loaded but "+A.missingRef+" cannot be resolved");var P=l._loadingSchemas[D];return P||(P=l._loadingSchemas[D]=l._opts.loadSchema(D),P.then(R,R)),P.then(function(F){if(!B(D))return y(F).then(function(){B(D)||l.addSchema(F,D,void 0,o)})}).then(function(){return E(C)});function R(){delete l._loadingSchemas[D]}function B(F){return l._refs[F]||l._schemas[F]}}}}return async}var custom,hasRequiredCustom;function requireCustom(){return hasRequiredCustom||(hasRequiredCustom=1,custom=function(e,n,o){var u=" ",l=e.level,m=e.dataLevel,y=e.schema[n],E=e.schemaPath+e.util.getProperty(n),C=e.errSchemaPath+"/"+n,k=!e.opts.allErrors,A,D="data"+(m||""),P="valid"+l,R="errs__"+l,B=e.opts.$data&&y&&y.$data,F;B?(u+=" var schema"+l+" = "+e.util.getData(y.$data,m,e.dataPathArr)+"; ",F="schema"+l):F=y;var j=this,N="definition"+l,Y=j.definition,J="",ie,ue,Q,ce,he;if(B&&Y.$data){he="keywordValidate"+l;var ke=Y.validateSchema;u+=" var "+N+" = RULES.custom['"+n+"'].definition; var "+he+" = "+N+".validate;"}else{if(ce=e.useCustomRule(j,y,e.schema,e),!ce)return;F="validate.schema"+E,he=ce.code,ie=Y.compile,ue=Y.inline,Q=Y.macro}var L=he+".errors",d="i"+l,v="ruleErr"+l,w=Y.async;if(w&&!e.async)throw new Error("async keyword in sync schema");if(ue||Q||(u+=""+L+" = null;"),u+="var "+R+" = errors;var "+P+";",B&&Y.$data&&(J+="}",u+=" if ("+F+" === undefined) { "+P+" = true; } else { ",ke&&(J+="}",u+=" "+P+" = "+N+".validateSchema("+F+"); if ("+P+") { ")),ue)Y.statements?u+=" "+ce.validate+" ":u+=" "+P+" = "+ce.validate+"; ";else if(Q){var c=e.util.copy(e),J="";c.level++;var p="valid"+c.level;c.schema=ce.validate,c.schemaPath="";var x=e.compositeRule;e.compositeRule=c.compositeRule=!0;var S=e.validate(c).replace(/validate\.schema/g,he);e.compositeRule=c.compositeRule=x,u+=" "+S}else{var b=b||[];b.push(u),u="",u+="  "+he+".call( ",e.opts.passContext?u+="this":u+="self",ie||Y.schema===!1?u+=" , "+D+" ":u+=" , "+F+" , "+D+" , validate.schema"+e.schemaPath+" ",u+=" , (dataPath || '')",e.errorPath!='""'&&(u+=" + "+e.errorPath);var h=m?"data"+(m-1||""):"parentData",T=m?e.dataPathArr[m]:"parentDataProperty";u+=" , "+h+" , "+T+" , rootData )  ";var M=u;u=b.pop(),Y.errors===!1?(u+=" "+P+" = ",w&&(u+="await "),u+=""+M+"; "):w?(L="customErrors"+l,u+=" var "+L+" = null; try { "+P+" = await "+M+"; } catch (e) { "+P+" = false; if (e instanceof ValidationError) "+L+" = e.errors; else throw e; } "):u+=" "+L+" = null; "+P+" = "+M+"; "}if(Y.modifying&&(u+=" if ("+h+") "+D+" = "+h+"["+T+"];"),u+=""+J,Y.valid)k&&(u+=" if (true) { ");else{u+=" if ( ",Y.valid===void 0?(u+=" !",Q?u+=""+p:u+=""+P):u+=" "+!Y.valid+" ",u+=") { ",A=j.keyword;var b=b||[];b.push(u),u="";var b=b||[];b.push(u),u="",e.createErrors!==!1?(u+=" { keyword: '"+(A||"custom")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { keyword: '"+j.keyword+"' } ",e.opts.messages!==!1&&(u+=` , message: 'should pass "`+j.keyword+`" keyword validation' `),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+D+" "),u+=" } "):u+=" {} ";var O=u;u=b.pop(),!e.compositeRule&&k?e.async?u+=" throw new ValidationError(["+O+"]); ":u+=" validate.errors = ["+O+"]; return false; ":u+=" var err = "+O+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";var V=u;u=b.pop(),ue?Y.errors?Y.errors!="full"&&(u+="  for (var "+d+"="+R+"; "+d+"<errors; "+d+"++) { var "+v+" = vErrors["+d+"]; if ("+v+".dataPath === undefined) "+v+".dataPath = (dataPath || '') + "+e.errorPath+"; if ("+v+".schemaPath === undefined) { "+v+'.schemaPath = "'+C+'"; } ',e.opts.verbose&&(u+=" "+v+".schema = "+F+"; "+v+".data = "+D+"; "),u+=" } "):Y.errors===!1?u+=" "+V+" ":(u+=" if ("+R+" == errors) { "+V+" } else {  for (var "+d+"="+R+"; "+d+"<errors; "+d+"++) { var "+v+" = vErrors["+d+"]; if ("+v+".dataPath === undefined) "+v+".dataPath = (dataPath || '') + "+e.errorPath+"; if ("+v+".schemaPath === undefined) { "+v+'.schemaPath = "'+C+'"; } ',e.opts.verbose&&(u+=" "+v+".schema = "+F+"; "+v+".data = "+D+"; "),u+=" } } "):Q?(u+="   var err =   ",e.createErrors!==!1?(u+=" { keyword: '"+(A||"custom")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(C)+" , params: { keyword: '"+j.keyword+"' } ",e.opts.messages!==!1&&(u+=` , message: 'should pass "`+j.keyword+`" keyword validation' `),e.opts.verbose&&(u+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+D+" "),u+=" } "):u+=" {} ",u+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&k&&(e.async?u+=" throw new ValidationError(vErrors); ":u+=" validate.errors = vErrors; return false; ")):Y.errors===!1?u+=" "+V+" ":(u+=" if (Array.isArray("+L+")) { if (vErrors === null) vErrors = "+L+"; else vErrors = vErrors.concat("+L+"); errors = vErrors.length;  for (var "+d+"="+R+"; "+d+"<errors; "+d+"++) { var "+v+" = vErrors["+d+"]; if ("+v+".dataPath === undefined) "+v+".dataPath = (dataPath || '') + "+e.errorPath+";  "+v+'.schemaPath = "'+C+'";  ',e.opts.verbose&&(u+=" "+v+".schema = "+F+"; "+v+".data = "+D+"; "),u+=" } } else { "+V+" } "),u+=" } ",k&&(u+=" else { ")}return u}),custom}const $schema$k="http://json-schema.org/draft-07/schema#",$id$k="http://json-schema.org/draft-07/schema#",title$1="Core schema meta-schema",definitions$1={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type$i=["object","boolean"],properties$k={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},require$$13$1={$schema:$schema$k,$id:$id$k,title:title$1,definitions:definitions$1,type:type$i,properties:properties$k,default:!0};var definition_schema,hasRequiredDefinition_schema;function requireDefinition_schema(){if(hasRequiredDefinition_schema)return definition_schema;hasRequiredDefinition_schema=1;var t=require$$13$1;return definition_schema={$id:"https://github.com/ajv-validator/ajv/blob/master/lib/definition_schema.js",definitions:{simpleTypes:t.definitions.simpleTypes},type:"object",dependencies:{schema:["validate"],$data:["validate"],statements:["inline"],valid:{not:{required:["macro"]}}},properties:{type:t.properties.type,schema:{type:"boolean"},statements:{type:"boolean"},dependencies:{type:"array",items:{type:"string"}},metaSchema:{type:"object"},modifying:{type:"boolean"},valid:{type:"boolean"},$data:{type:"boolean"},async:{type:"boolean"},errors:{anyOf:[{type:"boolean"},{const:"full"}]}}},definition_schema}var keyword,hasRequiredKeyword;function requireKeyword(){if(hasRequiredKeyword)return keyword;hasRequiredKeyword=1;var t=/^[a-z_$][a-z0-9_$-]*$/i,e=requireCustom(),n=requireDefinition_schema();keyword={add:o,get:u,remove:l,validate:m};function o(y,E){var C=this.RULES;if(C.keywords[y])throw new Error("Keyword "+y+" is already defined");if(!t.test(y))throw new Error("Keyword "+y+" is not a valid identifier");if(E){this.validateKeyword(E,!0);var k=E.type;if(Array.isArray(k))for(var A=0;A<k.length;A++)P(y,k[A],E);else P(y,k,E);var D=E.metaSchema;D&&(E.$data&&this._opts.$data&&(D={anyOf:[D,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]}),E.validateSchema=this.compile(D,!0))}C.keywords[y]=C.all[y]=!0;function P(R,B,F){for(var j,N=0;N<C.length;N++){var Y=C[N];if(Y.type==B){j=Y;break}}j||(j={type:B,rules:[]},C.push(j));var J={keyword:R,definition:F,custom:!0,code:e,implements:F.implements};j.rules.push(J),C.custom[R]=J}return this}function u(y){var E=this.RULES.custom[y];return E?E.definition:this.RULES.keywords[y]||!1}function l(y){var E=this.RULES;delete E.keywords[y],delete E.all[y],delete E.custom[y];for(var C=0;C<E.length;C++)for(var k=E[C].rules,A=0;A<k.length;A++)if(k[A].keyword==y){k.splice(A,1);break}return this}function m(y,E){m.errors=null;var C=this._validateKeyword=this._validateKeyword||this.compile(n,!0);if(C(y))return!0;if(m.errors=C.errors,E)throw new Error("custom keyword definition is invalid: "+this.errorsText(C.errors));return!1}return keyword}const $schema$j="http://json-schema.org/draft-07/schema#",$id$j="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description="Meta-schema for $data reference (JSON Schema extension proposal)",type$h="object",required$g=["$data"],properties$j={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties=!1,require$$12$1={$schema:$schema$j,$id:$id$j,description,type:type$h,required:required$g,properties:properties$j,additionalProperties};var ajv,hasRequiredAjv;function requireAjv(){if(hasRequiredAjv)return ajv;hasRequiredAjv=1;var t=requireCompile(),e=requireResolve(),n=requireCache(),o=requireSchema_obj(),u=requireFastJsonStableStringify(),l=requireFormats(),m=requireRules(),y=requireData(),E=requireUtil();ajv=R,R.prototype.validate=B,R.prototype.compile=F,R.prototype.addSchema=j,R.prototype.addMetaSchema=N,R.prototype.validateSchema=Y,R.prototype.getSchema=ie,R.prototype.removeSchema=ce,R.prototype.addFormat=x,R.prototype.errorsText=p,R.prototype._addSchema=ke,R.prototype._compile=L,R.prototype.compileAsync=requireAsync();var C=requireKeyword();R.prototype.addKeyword=C.add,R.prototype.getKeyword=C.get,R.prototype.removeKeyword=C.remove,R.prototype.validateKeyword=C.validate;var k=requireError_classes();R.ValidationError=k.Validation,R.MissingRefError=k.MissingRef,R.$dataMetaSchema=y;var A="http://json-schema.org/draft-07/schema",D=["removeAdditional","useDefaults","coerceTypes","strictDefaults"],P=["/properties"];function R(Z){if(!(this instanceof R))return new R(Z);Z=this._opts=E.copy(Z)||{},V(this),this._schemas={},this._refs={},this._fragments={},this._formats=l(Z.format),this._cache=Z.cache||new n,this._loadingSchemas={},this._compilations=[],this.RULES=m(),this._getId=d(Z),Z.loopRequired=Z.loopRequired||1/0,Z.errorDataPath=="property"&&(Z._errorDataPathProperty=!0),Z.serialize===void 0&&(Z.serialize=u),this._metaOpts=O(this),Z.formats&&h(this),Z.keywords&&T(this),S(this),typeof Z.meta=="object"&&this.addMetaSchema(Z.meta),Z.nullable&&this.addKeyword("nullable",{metaSchema:{type:"boolean"}}),b(this)}function B(Z,U){var z;if(typeof Z=="string"){if(z=this.getSchema(Z),!z)throw new Error('no schema with key or ref "'+Z+'"')}else{var ne=this._addSchema(Z);z=ne.validate||this._compile(ne)}var fe=z(U);return z.$async!==!0&&(this.errors=z.errors),fe}function F(Z,U){var z=this._addSchema(Z,void 0,U);return z.validate||this._compile(z)}function j(Z,U,z,ne){if(Array.isArray(Z)){for(var fe=0;fe<Z.length;fe++)this.addSchema(Z[fe],void 0,z,ne);return this}var me=this._getId(Z);if(me!==void 0&&typeof me!="string")throw new Error("schema id must be string");return U=e.normalizeId(U||me),M(this,U),this._schemas[U]=this._addSchema(Z,z,ne,!0),this}function N(Z,U,z){return this.addSchema(Z,U,z,!0),this}function Y(Z,U){var z=Z.$schema;if(z!==void 0&&typeof z!="string")throw new Error("$schema must be a string");if(z=z||this._opts.defaultMeta||J(this),!z)return this.logger.warn("meta-schema not available"),this.errors=null,!0;var ne=this.validate(z,Z);if(!ne&&U){var fe="schema is invalid: "+this.errorsText();if(this._opts.validateSchema=="log")this.logger.error(fe);else throw new Error(fe)}return ne}function J(Z){var U=Z._opts.meta;return Z._opts.defaultMeta=typeof U=="object"?Z._getId(U)||U:Z.getSchema(A)?A:void 0,Z._opts.defaultMeta}function ie(Z){var U=Q(this,Z);switch(typeof U){case"object":return U.validate||this._compile(U);case"string":return this.getSchema(U);case"undefined":return ue(this,Z)}}function ue(Z,U){var z=e.schema.call(Z,{schema:{}},U);if(z){var ne=z.schema,fe=z.root,me=z.baseId,de=t.call(Z,ne,fe,void 0,me);return Z._fragments[U]=new o({ref:U,fragment:!0,schema:ne,root:fe,baseId:me,validate:de}),de}}function Q(Z,U){return U=e.normalizeId(U),Z._schemas[U]||Z._refs[U]||Z._fragments[U]}function ce(Z){if(Z instanceof RegExp)return he(this,this._schemas,Z),he(this,this._refs,Z),this;switch(typeof Z){case"undefined":return he(this,this._schemas),he(this,this._refs),this._cache.clear(),this;case"string":var U=Q(this,Z);return U&&this._cache.del(U.cacheKey),delete this._schemas[Z],delete this._refs[Z],this;case"object":var z=this._opts.serialize,ne=z?z(Z):Z;this._cache.del(ne);var fe=this._getId(Z);fe&&(fe=e.normalizeId(fe),delete this._schemas[fe],delete this._refs[fe])}return this}function he(Z,U,z){for(var ne in U){var fe=U[ne];!fe.meta&&(!z||z.test(ne))&&(Z._cache.del(fe.cacheKey),delete U[ne])}}function ke(Z,U,z,ne){if(typeof Z!="object"&&typeof Z!="boolean")throw new Error("schema should be object or boolean");var fe=this._opts.serialize,me=fe?fe(Z):Z,de=this._cache.get(me);if(de)return de;ne=ne||this._opts.addUsedSchema!==!1;var je=e.normalizeId(this._getId(Z));je&&ne&&M(this,je);var lt=this._opts.validateSchema!==!1&&!U,it;lt&&!(it=je&&je==e.normalizeId(Z.$schema))&&this.validateSchema(Z,!0);var ot=e.ids.call(this,Z),Ct=new o({id:je,schema:Z,localRefs:ot,cacheKey:me,meta:z});return je[0]!="#"&&ne&&(this._refs[je]=Ct),this._cache.put(me,Ct),lt&&it&&this.validateSchema(Z,!0),Ct}function L(Z,U){if(Z.compiling)return Z.validate=fe,fe.schema=Z.schema,fe.errors=null,fe.root=U||fe,Z.schema.$async===!0&&(fe.$async=!0),fe;Z.compiling=!0;var z;Z.meta&&(z=this._opts,this._opts=this._metaOpts);var ne;try{ne=t.call(this,Z.schema,U,Z.localRefs)}catch(me){throw delete Z.validate,me}finally{Z.compiling=!1,Z.meta&&(this._opts=z)}return Z.validate=ne,Z.refs=ne.refs,Z.refVal=ne.refVal,Z.root=ne.root,ne;function fe(){var me=Z.validate,de=me.apply(this,arguments);return fe.errors=me.errors,de}}function d(Z){switch(Z.schemaId){case"auto":return c;case"id":return v;default:return w}}function v(Z){return Z.$id&&this.logger.warn("schema $id ignored",Z.$id),Z.id}function w(Z){return Z.id&&this.logger.warn("schema id ignored",Z.id),Z.$id}function c(Z){if(Z.$id&&Z.id&&Z.$id!=Z.id)throw new Error("schema $id is different from id");return Z.$id||Z.id}function p(Z,U){if(Z=Z||this.errors,!Z)return"No errors";U=U||{};for(var z=U.separator===void 0?", ":U.separator,ne=U.dataVar===void 0?"data":U.dataVar,fe="",me=0;me<Z.length;me++){var de=Z[me];de&&(fe+=ne+de.dataPath+" "+de.message+z)}return fe.slice(0,-z.length)}function x(Z,U){return typeof U=="string"&&(U=new RegExp(U)),this._formats[Z]=U,this}function S(Z){var U;if(Z._opts.$data&&(U=require$$12$1,Z.addMetaSchema(U,U.$id,!0)),Z._opts.meta!==!1){var z=require$$13$1;Z._opts.$data&&(z=y(z,P)),Z.addMetaSchema(z,A,!0),Z._refs["http://json-schema.org/schema"]=A}}function b(Z){var U=Z._opts.schemas;if(U)if(Array.isArray(U))Z.addSchema(U);else for(var z in U)Z.addSchema(U[z],z)}function h(Z){for(var U in Z._opts.formats){var z=Z._opts.formats[U];Z.addFormat(U,z)}}function T(Z){for(var U in Z._opts.keywords){var z=Z._opts.keywords[U];Z.addKeyword(U,z)}}function M(Z,U){if(Z._schemas[U]||Z._refs[U])throw new Error('schema with key or id "'+U+'" already exists')}function O(Z){for(var U=E.copy(Z._opts),z=0;z<D.length;z++)delete U[D[z]];return U}function V(Z){var U=Z._opts.logger;if(U===!1)Z.logger={log:ee,warn:ee,error:ee};else{if(U===void 0&&(U=console),!(typeof U=="object"&&U.log&&U.warn&&U.error))throw new Error("logger must implement log, warn and error methods");Z.logger=U}}function ee(){}return ajv}var error,hasRequiredError;function requireError(){if(hasRequiredError)return error;hasRequiredError=1;function t(e){var n="validation failed";this.name="HARError",this.message=n,this.errors=e,typeof Error.captureStackTrace=="function"?Error.captureStackTrace(this,this.constructor):this.stack=new Error(n).stack}return t.prototype=Error.prototype,error=t,error}const $id$i="afterRequest.json#",$schema$i="http://json-schema.org/draft-06/schema#",type$g="object",optional$4=!0,required$f=["lastAccess","eTag","hitCount"],properties$i={expires:{type:"string",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))?"},lastAccess:{type:"string",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))?"},eTag:{type:"string"},hitCount:{type:"integer"},comment:{type:"string"}},require$$0={$id:$id$i,$schema:$schema$i,type:type$g,optional:optional$4,required:required$f,properties:properties$i},$id$h="beforeRequest.json#",$schema$h="http://json-schema.org/draft-06/schema#",type$f="object",optional$3=!0,required$e=["lastAccess","eTag","hitCount"],properties$h={expires:{type:"string",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))?"},lastAccess:{type:"string",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))?"},eTag:{type:"string"},hitCount:{type:"integer"},comment:{type:"string"}},require$$1={$id:$id$h,$schema:$schema$h,type:type$f,optional:optional$3,required:required$e,properties:properties$h},$id$g="browser.json#",$schema$g="http://json-schema.org/draft-06/schema#",type$e="object",required$d=["name","version"],properties$g={name:{type:"string"},version:{type:"string"},comment:{type:"string"}},require$$2={$id:$id$g,$schema:$schema$g,type:type$e,required:required$d,properties:properties$g},$id$f="cache.json#",$schema$f="http://json-schema.org/draft-06/schema#",properties$f={beforeRequest:{oneOf:[{type:"null"},{$ref:"beforeRequest.json#"}]},afterRequest:{oneOf:[{type:"null"},{$ref:"afterRequest.json#"}]},comment:{type:"string"}},require$$3$1={$id:$id$f,$schema:$schema$f,properties:properties$f},$id$e="content.json#",$schema$e="http://json-schema.org/draft-06/schema#",type$d="object",required$c=["size","mimeType"],properties$e={size:{type:"integer"},compression:{type:"integer"},mimeType:{type:"string"},text:{type:"string"},encoding:{type:"string"},comment:{type:"string"}},require$$4={$id:$id$e,$schema:$schema$e,type:type$d,required:required$c,properties:properties$e},$id$d="cookie.json#",$schema$d="http://json-schema.org/draft-06/schema#",type$c="object",required$b=["name","value"],properties$d={name:{type:"string"},value:{type:"string"},path:{type:"string"},domain:{type:"string"},expires:{type:["string","null"],format:"date-time"},httpOnly:{type:"boolean"},secure:{type:"boolean"},comment:{type:"string"}},require$$5={$id:$id$d,$schema:$schema$d,type:type$c,required:required$b,properties:properties$d},$id$c="creator.json#",$schema$c="http://json-schema.org/draft-06/schema#",type$b="object",required$a=["name","version"],properties$c={name:{type:"string"},version:{type:"string"},comment:{type:"string"}},require$$6={$id:$id$c,$schema:$schema$c,type:type$b,required:required$a,properties:properties$c},$id$b="entry.json#",$schema$b="http://json-schema.org/draft-06/schema#",type$a="object",optional$2=!0,required$9=["startedDateTime","time","request","response","cache","timings"],properties$b={pageref:{type:"string"},startedDateTime:{type:"string",format:"date-time",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))"},time:{type:"number",min:0},request:{$ref:"request.json#"},response:{$ref:"response.json#"},cache:{$ref:"cache.json#"},timings:{$ref:"timings.json#"},serverIPAddress:{type:"string",oneOf:[{format:"ipv4"},{format:"ipv6"}]},connection:{type:"string"},comment:{type:"string"}},require$$7={$id:$id$b,$schema:$schema$b,type:type$a,optional:optional$2,required:required$9,properties:properties$b},$id$a="har.json#",$schema$a="http://json-schema.org/draft-06/schema#",type$9="object",required$8=["log"],properties$a={log:{$ref:"log.json#"}},require$$8={$id:$id$a,$schema:$schema$a,type:type$9,required:required$8,properties:properties$a},$id$9="header.json#",$schema$9="http://json-schema.org/draft-06/schema#",type$8="object",required$7=["name","value"],properties$9={name:{type:"string"},value:{type:"string"},comment:{type:"string"}},require$$9={$id:$id$9,$schema:$schema$9,type:type$8,required:required$7,properties:properties$9},$id$8="log.json#",$schema$8="http://json-schema.org/draft-06/schema#",type$7="object",required$6=["version","creator","entries"],properties$8={version:{type:"string"},creator:{$ref:"creator.json#"},browser:{$ref:"browser.json#"},pages:{type:"array",items:{$ref:"page.json#"}},entries:{type:"array",items:{$ref:"entry.json#"}},comment:{type:"string"}},require$$10={$id:$id$8,$schema:$schema$8,type:type$7,required:required$6,properties:properties$8},$id$7="page.json#",$schema$7="http://json-schema.org/draft-06/schema#",type$6="object",optional$1=!0,required$5=["startedDateTime","id","title","pageTimings"],properties$7={startedDateTime:{type:"string",format:"date-time",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))"},id:{type:"string",unique:!0},title:{type:"string"},pageTimings:{$ref:"pageTimings.json#"},comment:{type:"string"}},require$$11={$id:$id$7,$schema:$schema$7,type:type$6,optional:optional$1,required:required$5,properties:properties$7},$id$6="pageTimings.json#",$schema$6="http://json-schema.org/draft-06/schema#",type$5="object",properties$6={onContentLoad:{type:"number",min:-1},onLoad:{type:"number",min:-1},comment:{type:"string"}},require$$12={$id:$id$6,$schema:$schema$6,type:type$5,properties:properties$6},$id$5="postData.json#",$schema$5="http://json-schema.org/draft-06/schema#",type$4="object",optional=!0,required$4=["mimeType"],properties$5={mimeType:{type:"string"},text:{type:"string"},params:{type:"array",required:["name"],properties:{name:{type:"string"},value:{type:"string"},fileName:{type:"string"},contentType:{type:"string"},comment:{type:"string"}}},comment:{type:"string"}},require$$13={$id:$id$5,$schema:$schema$5,type:type$4,optional,required:required$4,properties:properties$5},$id$4="query.json#",$schema$4="http://json-schema.org/draft-06/schema#",type$3="object",required$3=["name","value"],properties$4={name:{type:"string"},value:{type:"string"},comment:{type:"string"}},require$$14={$id:$id$4,$schema:$schema$4,type:type$3,required:required$3,properties:properties$4},$id$3="request.json#",$schema$3="http://json-schema.org/draft-06/schema#",type$2="object",required$2=["method","url","httpVersion","cookies","headers","queryString","headersSize","bodySize"],properties$3={method:{type:"string"},url:{type:"string",format:"uri"},httpVersion:{type:"string"},cookies:{type:"array",items:{$ref:"cookie.json#"}},headers:{type:"array",items:{$ref:"header.json#"}},queryString:{type:"array",items:{$ref:"query.json#"}},postData:{$ref:"postData.json#"},headersSize:{type:"integer"},bodySize:{type:"integer"},comment:{type:"string"}},require$$15={$id:$id$3,$schema:$schema$3,type:type$2,required:required$2,properties:properties$3},$id$2="response.json#",$schema$2="http://json-schema.org/draft-06/schema#",type$1="object",required$1=["status","statusText","httpVersion","cookies","headers","content","redirectURL","headersSize","bodySize"],properties$2={status:{type:"integer"},statusText:{type:"string"},httpVersion:{type:"string"},cookies:{type:"array",items:{$ref:"cookie.json#"}},headers:{type:"array",items:{$ref:"header.json#"}},content:{$ref:"content.json#"},redirectURL:{type:"string"},headersSize:{type:"integer"},bodySize:{type:"integer"},comment:{type:"string"}},require$$16={$id:$id$2,$schema:$schema$2,type:type$1,required:required$1,properties:properties$2},$id$1="timings.json#",$schema$1="http://json-schema.org/draft-06/schema#",required=["send","wait","receive"],properties$1={dns:{type:"number",min:-1},connect:{type:"number",min:-1},blocked:{type:"number",min:-1},send:{type:"number",min:-1},wait:{type:"number",min:-1},receive:{type:"number",min:-1},ssl:{type:"number",min:-1},comment:{type:"string"}},require$$17={$id:$id$1,$schema:$schema$1,required,properties:properties$1};var lib,hasRequiredLib;function requireLib(){return hasRequiredLib||(hasRequiredLib=1,lib={afterRequest:require$$0,beforeRequest:require$$1,browser:require$$2,cache:require$$3$1,content:require$$4,cookie:require$$5,creator:require$$6,entry:require$$7,har:require$$8,header:require$$9,log:require$$10,page:require$$11,pageTimings:require$$12,postData:require$$13,query:require$$14,request:require$$15,response:require$$16,timings:require$$17}),lib}const $schema="http://json-schema.org/draft-06/schema#",$id="http://json-schema.org/draft-06/schema#",title="Core schema meta-schema",definitions={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type=["object","boolean"],properties={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},title:{type:"string"},description:{type:"string"},default:{},examples:{type:"array",items:{}},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:{}},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:{},enum:{type:"array",minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},require$$3={$schema,$id,title,definitions,type,properties,default:{}};var hasRequiredPromise;function requirePromise(){if(hasRequiredPromise)return promise;hasRequiredPromise=1;var t=requireAjv(),e=requireError(),n=requireLib(),o;function u(){var m=new t({allErrors:!0});return m.addMetaSchema(require$$3),m.addSchema(n),m}function l(m,y){y=y||{},o=o||u();var E=o.getSchema(m+".json");return new Promise(function(C,k){var A=E(y);A?C(y):k(new e(E.errors))})}return promise.afterRequest=function(m){return l("afterRequest",m)},promise.beforeRequest=function(m){return l("beforeRequest",m)},promise.browser=function(m){return l("browser",m)},promise.cache=function(m){return l("cache",m)},promise.content=function(m){return l("content",m)},promise.cookie=function(m){return l("cookie",m)},promise.creator=function(m){return l("creator",m)},promise.entry=function(m){return l("entry",m)},promise.har=function(m){return l("har",m)},promise.header=function(m){return l("header",m)},promise.log=function(m){return l("log",m)},promise.page=function(m){return l("page",m)},promise.pageTimings=function(m){return l("pageTimings",m)},promise.postData=function(m){return l("postData",m)},promise.query=function(m){return l("query",m)},promise.request=function(m){return l("request",m)},promise.response=function(m){return l("response",m)},promise.timings=function(m){return l("timings",m)},promise}var hasRequiredHar;function requireHar(){if(hasRequiredHar)return har;hasRequiredHar=1;var t=require$$1$5,e=require$$1$1,n=requirePromise(),o=extend$1;function u(l){this.request=l}return u.prototype.reducer=function(l,m){if(l[m.name]===void 0)return l[m.name]=m.value,l;var y=[l[m.name],m.value];return l[m.name]=y,l},u.prototype.prep=function(l){if(l.queryObj={},l.headersObj={},l.postData.jsonObj=!1,l.postData.paramsObj=!1,l.queryString&&l.queryString.length&&(l.queryObj=l.queryString.reduce(this.reducer,{})),l.headers&&l.headers.length&&(l.headersObj=l.headers.reduceRight(function(E,C){return E[C.name]=C.value,E},{})),l.cookies&&l.cookies.length){var m=l.cookies.map(function(E){return E.name+"="+E.value});m.length&&(l.headersObj.cookie=m.join("; "))}function y(E){return E.some(function(C){return l.postData.mimeType.indexOf(C)===0})}if(y(["multipart/mixed","multipart/related","multipart/form-data","multipart/alternative"]))l.postData.mimeType="multipart/form-data";else if(y(["application/x-www-form-urlencoded"]))l.postData.params?(l.postData.paramsObj=l.postData.params.reduce(this.reducer,{}),l.postData.text=e.stringify(l.postData.paramsObj)):l.postData.text="";else if(y(["text/json","text/x-json","application/json","application/x-json"])&&(l.postData.mimeType="application/json",l.postData.text))try{l.postData.jsonObj=JSON.parse(l.postData.text)}catch(E){this.request.debug(E),l.postData.mimeType="text/plain"}return l},u.prototype.options=function(l){if(!l.har)return l;var m={};if(o(m,l.har),m.log&&m.log.entries&&(m=m.log.entries[0]),m.url=m.url||l.url||l.uri||l.baseUrl||"/",m.httpVersion=m.httpVersion||"HTTP/1.1",m.queryString=m.queryString||[],m.headers=m.headers||[],m.cookies=m.cookies||[],m.postData=m.postData||{},m.postData.mimeType=m.postData.mimeType||"application/octet-stream",m.bodySize=0,m.headersSize=0,m.postData.size=0,!n.request(m))return l;var y=this.prep(m);y.url&&(l.url=y.url),y.method&&(l.method=y.method),Object.keys(y.queryObj).length&&(l.qs=y.queryObj),Object.keys(y.headersObj).length&&(l.headers=y.headersObj);function E(C){return y.postData.mimeType.indexOf(C)===0}return E("application/x-www-form-urlencoded")?l.form=y.postData.paramsObj:E("application/json")?y.postData.jsonObj&&(l.body=y.postData.jsonObj,l.json=!0):E("multipart/form-data")?(l.formData={},y.postData.params.forEach(function(C){var k={};if(!C.fileName&&!C.contentType){l.formData[C.name]=C.value;return}C.fileName&&!C.value?k.value=t.createReadStream(C.fileName):C.value&&(k.value=C.value),C.fileName&&(k.options={filename:C.fileName,contentType:C.contentType?C.contentType:null}),l.formData[C.name]=k})):y.postData.text&&(l.body=y.postData.text),l},har.Har=u,har}var auth={},rngBrowser={exports:{}},hasRequiredRngBrowser;function requireRngBrowser(){if(hasRequiredRngBrowser)return rngBrowser.exports;hasRequiredRngBrowser=1;var t=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof window.msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto);if(t){var e=new Uint8Array(16);rngBrowser.exports=function(){return t(e),e}}else{var n=new Array(16);rngBrowser.exports=function(){for(var u=0,l;u<16;u++)u&3||(l=Math.random()*4294967296),n[u]=l>>>((u&3)<<3)&255;return n}}return rngBrowser.exports}var bytesToUuid_1,hasRequiredBytesToUuid;function requireBytesToUuid(){if(hasRequiredBytesToUuid)return bytesToUuid_1;hasRequiredBytesToUuid=1;for(var t=[],e=0;e<256;++e)t[e]=(e+256).toString(16).substr(1);function n(o,u){var l=u||0,m=t;return[m[o[l++]],m[o[l++]],m[o[l++]],m[o[l++]],"-",m[o[l++]],m[o[l++]],"-",m[o[l++]],m[o[l++]],"-",m[o[l++]],m[o[l++]],"-",m[o[l++]],m[o[l++]],m[o[l++]],m[o[l++]],m[o[l++]],m[o[l++]]].join("")}return bytesToUuid_1=n,bytesToUuid_1}var v4_1,hasRequiredV4;function requireV4(){if(hasRequiredV4)return v4_1;hasRequiredV4=1;var t=requireRngBrowser(),e=requireBytesToUuid();function n(o,u,l){var m=u&&l||0;typeof o=="string"&&(u=o==="binary"?new Array(16):null,o=null),o=o||{};var y=o.random||(o.rng||t)();if(y[6]=y[6]&15|64,y[8]=y[8]&63|128,u)for(var E=0;E<16;++E)u[m+E]=y[E];return u||e(y)}return v4_1=n,v4_1}var hasRequiredAuth;function requireAuth(){if(hasRequiredAuth)return auth;hasRequiredAuth=1;var t=requireCaseless(),e=requireV4(),n=helpers$1,o=n.md5,u=n.toBase64;function l(m){this.request=m,this.hasAuth=!1,this.sentAuth=!1,this.bearerToken=null,this.user=null,this.pass=null}return l.prototype.basic=function(m,y,E){var C=this;(typeof m!="string"||y!==void 0&&typeof y!="string")&&C.request.emit("error",new Error("auth() received invalid user or password")),C.user=m,C.pass=y,C.hasAuth=!0;var k=m+":"+(y||"");if(E||typeof E>"u"){var A="Basic "+u(k);return C.sentAuth=!0,A}},l.prototype.bearer=function(m,y){var E=this;if(E.bearerToken=m,E.hasAuth=!0,y||typeof y>"u"){typeof m=="function"&&(m=m());var C="Bearer "+(m||"");return E.sentAuth=!0,C}},l.prototype.digest=function(m,y,E){for(var C=this,k={},A=/([a-z0-9_-]+)=(?:"([^"]+)"|([a-z0-9_-]+))/gi;;){var D=A.exec(E);if(!D)break;k[D[1]]=D[2]||D[3]}var P=function(ue,Q,ce,he,ke,L){var d=o(Q+":"+ce+":"+he);return ue&&ue.toLowerCase()==="md5-sess"?o(d+":"+ke+":"+L):d},R=/(^|,)\s*auth\s*($|,)/.test(k.qop)&&"auth",B=R&&"00000001",F=R&&e().replace(/-/g,""),j=P(k.algorithm,C.user,k.realm,C.pass,k.nonce,F),N=o(m+":"+y),Y=o(R?j+":"+k.nonce+":"+B+":"+F+":"+R+":"+N:j+":"+k.nonce+":"+N),J={username:C.user,realm:k.realm,nonce:k.nonce,uri:y,qop:R,response:Y,nc:B,cnonce:F,algorithm:k.algorithm,opaque:k.opaque};E=[];for(var ie in J)J[ie]&&(ie==="qop"||ie==="nc"||ie==="algorithm"?E.push(ie+"="+J[ie]):E.push(ie+'="'+J[ie]+'"'));return E="Digest "+E.join(", "),C.sentAuth=!0,E},l.prototype.onRequest=function(m,y,E,C){var k=this,A=k.request,D;C===void 0&&m===void 0?k.request.emit("error",new Error("no auth mechanism defined")):C!==void 0?D=k.bearer(C,E):D=k.basic(m,y,E),D&&A.setHeader("authorization",D)},l.prototype.onResponse=function(m){var y=this,E=y.request;if(!y.hasAuth||y.sentAuth)return null;var C=t(m.headers),k=C.get("www-authenticate"),A=k&&k.split(" ")[0].toLowerCase();switch(E.debug("reauth",A),A){case"basic":return y.basic(y.user,y.pass,!0);case"bearer":return y.bearer(y.bearerToken,!0);case"digest":return y.digest(E.method,E.path,k)}},auth.Auth=l,auth}var oauth={},oauthSign={},hasRequiredOauthSign;function requireOauthSign(){if(hasRequiredOauthSign)return oauthSign;hasRequiredOauthSign=1;var t=requireCryptoBrowserify();function e(D,P,R){return t.createHmac(R,D).update(P).digest("base64")}function n(D,P){return t.createSign("RSA-SHA1").update(P).sign(D,"base64")}function o(D){return encodeURIComponent(D).replace(/!/g,"%21").replace(/\*/g,"%2A").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/'/g,"%27")}function u(D){var P,R,B=[];for(P in D)if(R=D[P],Array.isArray(R))for(var F=0;F<R.length;F++)B.push([P,R[F]]);else if(typeof R=="object")for(var j in R)B.push([P+"["+j+"]",R[j]]);else B.push([P,R]);return B}function l(D,P){return D>P?1:D<P?-1:0}function m(D,P,R){var B=u(R).map(function(j){return[o(j[0]),o(j[1]||"")]}).sort(function(j,N){return l(j[0],N[0])||l(j[1],N[1])}).map(function(j){return j.join("=")}).join("&"),F=[o(D?D.toUpperCase():"GET"),o(P),o(B)].join("&");return F}function y(D,P,R,B,F){var j=m(D,P,R),N=[B||"",F||""].map(o).join("&");return e(N,j,"sha1")}function E(D,P,R,B,F){var j=m(D,P,R),N=[B||"",F||""].map(o).join("&");return e(N,j,"sha256")}function C(D,P,R,B,F){var j=m(D,P,R),N=B||"";return n(N,j)}function k(D,P){var R=[D||"",P||""].map(o).join("&");return R}function A(D,P,R,B,F,j){var N,Y=1;switch(D){case"RSA-SHA1":N=C;break;case"HMAC-SHA1":N=y;break;case"HMAC-SHA256":N=E;break;case"PLAINTEXT":N=k,Y=4;break;default:throw new Error("Signature method not supported: "+D)}return N.apply(null,[].slice.call(arguments,Y))}return oauthSign.hmacsign=y,oauthSign.hmacsign256=E,oauthSign.rsasign=C,oauthSign.plaintext=k,oauthSign.sign=A,oauthSign.rfc3986=o,oauthSign.generateBase=m,oauthSign}var hasRequiredOauth;function requireOauth(){if(hasRequiredOauth)return oauth;hasRequiredOauth=1;var t=require$$2$2,e=requireLib$1(),n=requireCaseless(),o=requireV4(),u=requireOauthSign(),l=requireCryptoBrowserify(),m=safeBufferExports$1.Buffer;function y(E){this.request=E,this.params=null}return y.prototype.buildParams=function(E,C,k,A,D,P){var R={};for(var B in E)R["oauth_"+B]=E[B];R.oauth_version||(R.oauth_version="1.0"),R.oauth_timestamp||(R.oauth_timestamp=Math.floor(Date.now()/1e3).toString()),R.oauth_nonce||(R.oauth_nonce=o().replace(/-/g,"")),R.oauth_signature_method||(R.oauth_signature_method="HMAC-SHA1");var F=R.oauth_consumer_secret||R.oauth_private_key;delete R.oauth_consumer_secret,delete R.oauth_private_key;var j=R.oauth_token_secret;delete R.oauth_token_secret;var N=R.oauth_realm;delete R.oauth_realm,delete R.oauth_transport_method;var Y=C.protocol+"//"+C.host+C.pathname,J=P.parse([].concat(A,D,P.stringify(R)).join("&"));return R.oauth_signature=u.sign(R.oauth_signature_method,k,Y,J,F,j),N&&(R.realm=N),R},y.prototype.buildBodyHash=function(E,C){["HMAC-SHA1","RSA-SHA1"].indexOf(E.signature_method||"HMAC-SHA1")<0&&this.request.emit("error",new Error("oauth: "+E.signature_method+" signature_method not supported with body_hash signing."));var k=l.createHash("sha1");k.update(C||"");var A=k.digest("hex");return m.from(A,"hex").toString("base64")},y.prototype.concatParams=function(E,C,k){k=k||"";var A=Object.keys(E).filter(function(D){return D!=="realm"&&D!=="oauth_signature"}).sort();return E.realm&&A.splice(0,0,"realm"),A.push("oauth_signature"),A.map(function(D){return D+"="+k+u.rfc3986(E[D])+k}).join(C)},y.prototype.onRequest=function(E){var C=this;C.params=E;var k=C.request.uri||{},A=C.request.method||"",D=n(C.request.headers),P=C.request.body||"",R=C.request.qsLib||e,B,F,j=D.get("content-type")||"",N="application/x-www-form-urlencoded",Y=E.transport_method||"header";j.slice(0,N.length)===N&&(j=N,B=P),k.query&&(F=k.query),Y==="body"&&(A!=="POST"||j!==N)&&C.request.emit("error",new Error("oauth: transport_method of body requires POST and content-type "+N)),!B&&typeof E.body_hash=="boolean"&&(E.body_hash=C.buildBodyHash(E,C.request.body.toString()));var J=C.buildParams(E,k,A,F,B,R);switch(Y){case"header":C.request.setHeader("Authorization","OAuth "+C.concatParams(J,",",'"'));break;case"query":var ie=C.request.uri.href+=(F?"&":"?")+C.concatParams(J,"&");C.request.uri=t.parse(ie),C.request.path=C.request.uri.path;break;case"body":C.request.body=(B?B+"&":"")+C.concatParams(J,"&");break;default:C.request.emit("error",new Error("oauth: transport_method invalid"))}},oauth.OAuth=y,oauth}var hawk={},hasRequiredHawk;function requireHawk(){return hasRequiredHawk||(hasRequiredHawk=1,function(t){var e=requireCryptoBrowserify();function n(u){var l=(u+1)*6,m=e.randomBytes(Math.ceil(l/8)),y=m.toString("base64").replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"");return y.slice(0,u)}function o(u,l,m){var y=e.createHash(l);return y.update(`hawk.1.payload
`),y.update((m?m.split(";")[0].trim().toLowerCase():"")+`
`),y.update(u||""),y.update(`
`),y.digest("base64")}t.calculateMac=function(u,l){var m=`hawk.1.header
`+l.ts+`
`+l.nonce+`
`+(l.method||"").toUpperCase()+`
`+l.resource+`
`+l.host.toLowerCase()+`
`+l.port+`
`+(l.hash||"")+`
`;l.ext&&(m=m+l.ext.replace("\\","\\\\").replace(`
`,"\\n")),m=m+`
`,l.app&&(m=m+l.app+`
`+(l.dlg||"")+`
`);var y=e.createHmac(u.algorithm,u.key).update(m),E=y.digest("base64");return E},t.header=function(u,l,m){var y=m.timestamp||Math.floor((Date.now()+(m.localtimeOffsetMsec||0))/1e3),E=m.credentials;if(!E||!E.id||!E.key||!E.algorithm||["sha1","sha256"].indexOf(E.algorithm)===-1)return"";var C={ts:y,nonce:m.nonce||n(6),method:l,resource:u.pathname+(u.search||""),host:u.hostname,port:u.port||(u.protocol==="http:"?80:443),hash:m.hash,ext:m.ext,app:m.app,dlg:m.dlg};!C.hash&&(m.payload||m.payload==="")&&(C.hash=o(m.payload,E.algorithm,m.contentType));var k=t.calculateMac(E,C),A=C.ext!==null&&C.ext!==void 0&&C.ext!=="",D='Hawk id="'+E.id+'", ts="'+C.ts+'", nonce="'+C.nonce+(C.hash?'", hash="'+C.hash:"")+(A?'", ext="'+C.ext.replace(/\\/g,"\\\\").replace(/"/g,'\\"'):"")+'", mac="'+k+'"';return C.app&&(D=D+', app="'+C.app+(C.dlg?'", dlg="'+C.dlg:"")+'"'),D}}(hawk)),hawk}var multipart={},delayed_stream,hasRequiredDelayed_stream;function requireDelayed_stream(){if(hasRequiredDelayed_stream)return delayed_stream;hasRequiredDelayed_stream=1;var t=requireStreamBrowserify().Stream,e=util$6;delayed_stream=n;function n(){this.source=null,this.dataSize=0,this.maxDataSize=1024*1024,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}return e.inherits(n,t),n.create=function(o,u){var l=new this;u=u||{};for(var m in u)l[m]=u[m];l.source=o;var y=o.emit;return o.emit=function(){return l._handleEmit(arguments),y.apply(o,arguments)},o.on("error",function(){}),l.pauseStream&&o.pause(),l},Object.defineProperty(n.prototype,"readable",{configurable:!0,enumerable:!0,get:function(){return this.source.readable}}),n.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)},n.prototype.resume=function(){this._released||this.release(),this.source.resume()},n.prototype.pause=function(){this.source.pause()},n.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach((function(o){this.emit.apply(this,o)}).bind(this)),this._bufferedEvents=[]},n.prototype.pipe=function(){var o=t.prototype.pipe.apply(this,arguments);return this.resume(),o},n.prototype._handleEmit=function(o){if(this._released){this.emit.apply(this,o);return}o[0]==="data"&&(this.dataSize+=o[1].length,this._checkIfMaxDataSizeExceeded()),this._bufferedEvents.push(o)},n.prototype._checkIfMaxDataSizeExceeded=function(){if(!this._maxDataSizeExceeded&&!(this.dataSize<=this.maxDataSize)){this._maxDataSizeExceeded=!0;var o="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(o))}},delayed_stream}var combined_stream,hasRequiredCombined_stream;function requireCombined_stream(){if(hasRequiredCombined_stream)return combined_stream;hasRequiredCombined_stream=1;var t=util$6,e=requireStreamBrowserify().Stream,n=requireDelayed_stream();combined_stream=o;function o(){this.writable=!1,this.readable=!0,this.dataSize=0,this.maxDataSize=2*1024*1024,this.pauseStreams=!0,this._released=!1,this._streams=[],this._currentStream=null,this._insideLoop=!1,this._pendingNext=!1}return t.inherits(o,e),o.create=function(u){var l=new this;u=u||{};for(var m in u)l[m]=u[m];return l},o.isStreamLike=function(u){return typeof u!="function"&&typeof u!="string"&&typeof u!="boolean"&&typeof u!="number"&&!Buffer$C.isBuffer(u)},o.prototype.append=function(u){var l=o.isStreamLike(u);if(l){if(!(u instanceof n)){var m=n.create(u,{maxDataSize:1/0,pauseStream:this.pauseStreams});u.on("data",this._checkDataSize.bind(this)),u=m}this._handleErrors(u),this.pauseStreams&&u.pause()}return this._streams.push(u),this},o.prototype.pipe=function(u,l){return e.prototype.pipe.call(this,u,l),this.resume(),u},o.prototype._getNext=function(){if(this._currentStream=null,this._insideLoop){this._pendingNext=!0;return}this._insideLoop=!0;try{do this._pendingNext=!1,this._realGetNext();while(this._pendingNext)}finally{this._insideLoop=!1}},o.prototype._realGetNext=function(){var u=this._streams.shift();if(typeof u>"u"){this.end();return}if(typeof u!="function"){this._pipeNext(u);return}var l=u;l((function(m){var y=o.isStreamLike(m);y&&(m.on("data",this._checkDataSize.bind(this)),this._handleErrors(m)),this._pipeNext(m)}).bind(this))},o.prototype._pipeNext=function(u){this._currentStream=u;var l=o.isStreamLike(u);if(l){u.on("end",this._getNext.bind(this)),u.pipe(this,{end:!1});return}var m=u;this.write(m),this._getNext()},o.prototype._handleErrors=function(u){var l=this;u.on("error",function(m){l._emitError(m)})},o.prototype.write=function(u){this.emit("data",u)},o.prototype.pause=function(){this.pauseStreams&&(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function"&&this._currentStream.pause(),this.emit("pause"))},o.prototype.resume=function(){this._released||(this._released=!0,this.writable=!0,this._getNext()),this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function"&&this._currentStream.resume(),this.emit("resume")},o.prototype.end=function(){this._reset(),this.emit("end")},o.prototype.destroy=function(){this._reset(),this.emit("close")},o.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null},o.prototype._checkDataSize=function(){if(this._updateDataSize(),!(this.dataSize<=this.maxDataSize)){var u="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(u))}},o.prototype._updateDataSize=function(){this.dataSize=0;var u=this;this._streams.forEach(function(l){l.dataSize&&(u.dataSize+=l.dataSize)}),this._currentStream&&this._currentStream.dataSize&&(this.dataSize+=this._currentStream.dataSize)},o.prototype._emitError=function(u){this._reset(),this.emit("error",u)},combined_stream}var hasRequiredMultipart;function requireMultipart(){if(hasRequiredMultipart)return multipart;hasRequiredMultipart=1;var t=requireV4(),e=requireCombined_stream(),n=requireIsstream(),o=safeBufferExports$1.Buffer;function u(l){this.request=l,this.boundary=t(),this.chunked=!1,this.body=null}return u.prototype.isChunked=function(l){var m=this,y=!1,E=l.data||l;return E.forEach||m.request.emit("error",new Error("Argument error, options.multipart.")),l.chunked!==void 0&&(y=l.chunked),m.request.getHeader("transfer-encoding")==="chunked"&&(y=!0),y||E.forEach(function(C){typeof C.body>"u"&&m.request.emit("error",new Error("Body attribute missing in multipart.")),n(C.body)&&(y=!0)}),y},u.prototype.setHeaders=function(l){var m=this;l&&!m.request.hasHeader("transfer-encoding")&&m.request.setHeader("transfer-encoding","chunked");var y=m.request.getHeader("content-type");!y||y.indexOf("multipart")===-1?m.request.setHeader("content-type","multipart/related; boundary="+m.boundary):y.indexOf("boundary")!==-1?m.boundary=y.replace(/.*boundary=([^\s;]+).*/,"$1"):m.request.setHeader("content-type",y+"; boundary="+m.boundary)},u.prototype.build=function(l,m){var y=this,E=m?new e:[];function C(k){return typeof k=="number"&&(k=k.toString()),m?E.append(k):E.push(o.from(k))}return y.request.preambleCRLF&&C(`\r
`),l.forEach(function(k){var A="--"+y.boundary+`\r
`;Object.keys(k).forEach(function(D){D!=="body"&&(A+=D+": "+k[D]+`\r
`)}),A+=`\r
`,C(A),C(k.body),C(`\r
`)}),C("--"+y.boundary+"--"),y.request.postambleCRLF&&C(`\r
`),E},u.prototype.onRequest=function(l){var m=this,y=m.isChunked(l),E=l.data||l;m.setHeaders(y),m.chunked=y,m.body=m.build(E,y)},multipart.Multipart=u,multipart}var redirect={},hasRequiredRedirect;function requireRedirect(){if(hasRequiredRedirect)return redirect;hasRequiredRedirect=1;var t=require$$2$2,e=/^https?:/;function n(o){this.request=o,this.followRedirect=!0,this.followRedirects=!0,this.followAllRedirects=!1,this.followOriginalHttpMethod=!1,this.allowRedirect=function(){return!0},this.maxRedirects=10,this.redirects=[],this.redirectsFollowed=0,this.removeRefererHeader=!1}return n.prototype.onRequest=function(o){var u=this;o.maxRedirects!==void 0&&(u.maxRedirects=o.maxRedirects),typeof o.followRedirect=="function"&&(u.allowRedirect=o.followRedirect),o.followRedirect!==void 0&&(u.followRedirects=!!o.followRedirect),o.followAllRedirects!==void 0&&(u.followAllRedirects=o.followAllRedirects),(u.followRedirects||u.followAllRedirects)&&(u.redirects=u.redirects||[]),o.removeRefererHeader!==void 0&&(u.removeRefererHeader=o.removeRefererHeader),o.followOriginalHttpMethod!==void 0&&(u.followOriginalHttpMethod=o.followOriginalHttpMethod)},n.prototype.redirectTo=function(o){var u=this,l=u.request,m=null;if(o.statusCode>=300&&o.statusCode<400&&o.caseless.has("location")){var y=o.caseless.get("location");if(l.debug("redirect",y),u.followAllRedirects)m=y;else if(u.followRedirects)switch(l.method){case"PATCH":case"PUT":case"POST":case"DELETE":break;default:m=y;break}}else if(o.statusCode===401){var E=l._auth.onResponse(o);E&&(l.setHeader("authorization",E),m=l.uri)}return m},n.prototype.onResponse=function(o){var u=this,l=u.request,m=u.redirectTo(o);if(!m||!u.allowRedirect.call(l,o))return!1;if(l.debug("redirect to",m),o.resume&&o.resume(),u.redirectsFollowed>=u.maxRedirects)return l.emit("error",new Error("Exceeded maxRedirects. Probably stuck in a redirect loop "+l.uri.href)),!1;u.redirectsFollowed+=1,e.test(m)||(m=t.resolve(l.uri.href,m));var y=l.uri;return l.uri=t.parse(m),l.uri.protocol!==y.protocol&&delete l.agent,u.redirects.push({statusCode:o.statusCode,redirectUri:m}),u.followAllRedirects&&l.method!=="HEAD"&&o.statusCode!==401&&o.statusCode!==307&&(l.method=u.followOriginalHttpMethod?l.method:"GET"),delete l.src,delete l.req,delete l._started,o.statusCode!==401&&o.statusCode!==307&&(delete l.body,delete l._form,l.headers&&(l.removeHeader("host"),l.removeHeader("content-type"),l.removeHeader("content-length"),l.uri.hostname!==l.originalHost.split(":")[0]&&l.removeHeader("authorization"))),u.removeRefererHeader||l.setHeader("referer",y.href),l.emit("redirect"),l.init(),!0},redirect.Redirect=n,redirect}var tunnel={},tunnelAgent={},hasRequiredTunnelAgent;function requireTunnelAgent(){if(hasRequiredTunnelAgent)return tunnelAgent;hasRequiredTunnelAgent=1;var t=require$$1$5,e=requireStreamHttp(),n=requireHttpsBrowserify(),o=requireEvents(),u=requireAssert$1(),l=util$6,m=safeBufferExports$1.Buffer;tunnelAgent.httpOverHttp=y,tunnelAgent.httpsOverHttp=E,tunnelAgent.httpOverHttps=C,tunnelAgent.httpsOverHttps=k;function y(B){var F=new A(B);return F.request=e.request,F}function E(B){var F=new A(B);return F.request=e.request,F.createSocket=D,F.defaultPort=443,F}function C(B){var F=new A(B);return F.request=n.request,F}function k(B){var F=new A(B);return F.request=n.request,F.createSocket=D,F.defaultPort=443,F}function A(B){var F=this;F.options=B||{},F.proxyOptions=F.options.proxy||{},F.maxSockets=F.options.maxSockets||e.Agent.defaultMaxSockets,F.requests=[],F.sockets=[],F.on("free",function(N,Y,J){for(var ie=0,ue=F.requests.length;ie<ue;++ie){var Q=F.requests[ie];if(Q.host===Y&&Q.port===J){F.requests.splice(ie,1),Q.request.onSocket(N);return}}N.destroy(),F.removeSocket(N)})}l.inherits(A,o.EventEmitter),A.prototype.addRequest=function(F,j){var N=this;if(typeof j=="string"&&(j={host:j,port:arguments[2],path:arguments[3]}),N.sockets.length>=this.maxSockets){N.requests.push({host:j.host,port:j.port,request:F});return}N.createConnection({host:j.host,port:j.port,request:F})},A.prototype.createConnection=function(F){var j=this;j.createSocket(F,function(N){N.on("free",Y),N.on("close",J),N.on("agentRemove",J),F.request.onSocket(N);function Y(){j.emit("free",N,F.host,F.port)}function J(ie){j.removeSocket(N),N.removeListener("free",Y),N.removeListener("close",J),N.removeListener("agentRemove",J)}})},A.prototype.createSocket=function(F,j){var N=this,Y={};N.sockets.push(Y);var J=P({},N.proxyOptions,{method:"CONNECT",path:F.host+":"+F.port,agent:!1});J.proxyAuth&&(J.headers=J.headers||{},J.headers["Proxy-Authorization"]="Basic "+m.from(J.proxyAuth).toString("base64")),R("making CONNECT request");var ie=N.request(J);ie.useChunkedEncodingByDefault=!1,ie.once("response",ue),ie.once("upgrade",Q),ie.once("connect",ce),ie.once("error",he),ie.end();function ue(ke){ke.upgrade=!0}function Q(ke,L,d){process$1.nextTick(function(){ce(ke,L,d)})}function ce(ke,L,d){if(ie.removeAllListeners(),L.removeAllListeners(),ke.statusCode===200)u.equal(d.length,0),R("tunneling connection has established"),N.sockets[N.sockets.indexOf(Y)]=L,j(L);else{R("tunneling socket could not be established, statusCode=%d",ke.statusCode);var v=new Error("tunneling socket could not be established, statusCode="+ke.statusCode);v.code="ECONNRESET",F.request.emit("error",v),N.removeSocket(Y)}}function he(ke){ie.removeAllListeners(),R(`tunneling socket could not be established, cause=%s
`,ke.message,ke.stack);var L=new Error("tunneling socket could not be established, cause="+ke.message);L.code="ECONNRESET",F.request.emit("error",L),N.removeSocket(Y)}},A.prototype.removeSocket=function(F){var j=this.sockets.indexOf(F);if(j!==-1){this.sockets.splice(j,1);var N=this.requests.shift();N&&this.createConnection(N)}};function D(B,F){var j=this;A.prototype.createSocket.call(j,B,function(N){var Y=t.connect(0,P({},j.options,{servername:B.host,socket:N}));j.sockets[j.sockets.indexOf(N)]=Y,F(Y)})}function P(B){for(var F=1,j=arguments.length;F<j;++F){var N=arguments[F];if(typeof N=="object")for(var Y=Object.keys(N),J=0,ie=Y.length;J<ie;++J){var ue=Y[J];N[ue]!==void 0&&(B[ue]=N[ue])}}return B}var R;return process$1.env.NODE_DEBUG&&/\btunnel\b/.test(process$1.env.NODE_DEBUG)?R=function(){var B=Array.prototype.slice.call(arguments);typeof B[0]=="string"?B[0]="TUNNEL: "+B[0]:B.unshift("TUNNEL:"),console.error.apply(console,B)}:R=function(){},tunnelAgent.debug=R,tunnelAgent}var hasRequiredTunnel;function requireTunnel(){if(hasRequiredTunnel)return tunnel;hasRequiredTunnel=1;var t=require$$2$2,e=requireTunnelAgent(),n=["accept","accept-charset","accept-encoding","accept-language","accept-ranges","cache-control","content-encoding","content-language","content-location","content-md5","content-range","content-type","connection","date","expect","max-forwards","pragma","referer","te","user-agent","via"],o=["proxy-authorization"];function u(k){var A=k.port,D=k.protocol,P=k.hostname+":";return A?P+=A:D==="https:"?P+="443":P+="80",P}function l(k,A){var D=A.reduce(function(P,R){return P[R.toLowerCase()]=!0,P},{});return Object.keys(k).filter(function(P){return D[P.toLowerCase()]}).reduce(function(P,R){return P[R]=k[R],P},{})}function m(k,A){var D=k.proxy,P={proxy:{host:D.hostname,port:+D.port,proxyAuth:D.auth,headers:A},headers:k.headers,ca:k.ca,cert:k.cert,key:k.key,passphrase:k.passphrase,pfx:k.pfx,ciphers:k.ciphers,rejectUnauthorized:k.rejectUnauthorized,secureOptions:k.secureOptions,secureProtocol:k.secureProtocol};return P}function y(k,A){var D=k.protocol==="https:"?"https":"http",P=A.protocol==="https:"?"Https":"Http";return[D,P].join("Over")}function E(k){var A=k.uri,D=k.proxy,P=y(A,D);return e[P]}function C(k){this.request=k,this.proxyHeaderWhiteList=n,this.proxyHeaderExclusiveList=[],typeof k.tunnel<"u"&&(this.tunnelOverride=k.tunnel)}return C.prototype.isEnabled=function(){var k=this,A=k.request;return typeof k.tunnelOverride<"u"?k.tunnelOverride:A.uri.protocol==="https:"},C.prototype.setup=function(k){var A=this,D=A.request;if(k=k||{},typeof D.proxy=="string"&&(D.proxy=t.parse(D.proxy)),!D.proxy||!D.tunnel)return!1;k.proxyHeaderWhiteList&&(A.proxyHeaderWhiteList=k.proxyHeaderWhiteList),k.proxyHeaderExclusiveList&&(A.proxyHeaderExclusiveList=k.proxyHeaderExclusiveList);var P=A.proxyHeaderExclusiveList.concat(o),R=A.proxyHeaderWhiteList.concat(P),B=l(D.headers,R);B.host=u(D.uri),P.forEach(D.removeHeader,D);var F=E(D),j=m(D,B);return D.agent=F(j),!0},C.defaultProxyHeaderWhiteList=n,C.defaultProxyHeaderExclusiveList=o,tunnel.Tunnel=C,tunnel}var performanceNow={exports:{}},hasRequiredPerformanceNow;function requirePerformanceNow(){return hasRequiredPerformanceNow||(hasRequiredPerformanceNow=1,(function(){var t,e,n,o,u,l;typeof performance<"u"&&performance!==null&&performance.now?performanceNow.exports=function(){return performance.now()}:typeof process$1<"u"&&process$1!==null&&process$1.hrtime?(performanceNow.exports=function(){return(t()-u)/1e6},e=process$1.hrtime,t=function(){var m;return m=e(),m[0]*1e9+m[1]},o=t(),l=process$1.uptime()*1e9,u=o-l):Date.now?(performanceNow.exports=function(){return Date.now()-n},n=Date.now()):(performanceNow.exports=function(){return new Date().getTime()-n},n=new Date().getTime())}).call(commonjsGlobal$1)),performanceNow.exports}var request$2,hasRequiredRequest;function requireRequest(){if(hasRequiredRequest)return request$2;hasRequiredRequest=1;var t=requireStreamHttp(),e=requireHttpsBrowserify(),n=require$$2$2,o=util$6,u=requireStreamBrowserify(),l=requireLib$5(),m=requireAwsSign2(),y=requireAws4(),E=requireLib$2(),C=mimeTypes,k=requireCaseless(),A=requireForeverAgent(),D=requireBrowser(),P=extend$1,R=requireIsstream(),B=requireIsTypedarray().strict,F=helpers$1,j=cookies$1,N=requireGetProxyFromURI(),Y=requireQuerystring().Querystring,J=requireHar().Har,ie=requireAuth().Auth,ue=requireOauth().OAuth,Q=requireHawk(),ce=requireMultipart().Multipart,he=requireRedirect().Redirect,ke=requireTunnel().Tunnel,L=requirePerformanceNow(),d=safeBufferExports$1.Buffer,v=F.safeStringify,w=F.isReadStream,c=F.toBase64,p=F.defer,x=F.copy,S=F.version,b=j.jar(),h={};function T(U,z){var ne={};for(var fe in z){var me=U.indexOf(fe)===-1;me&&(ne[fe]=z[fe])}return ne}function M(U,z){var ne={};for(var fe in z){var me=U.indexOf(fe)!==-1,de=typeof z[fe]=="function";me&&de||(ne[fe]=z[fe])}return ne}function O(){var U=this;return{uri:U.uri,method:U.method,headers:U.headers}}function V(){var U=this;return{statusCode:U.statusCode,body:U.body,headers:U.headers,request:O.call(U.request)}}function ee(U){var z=this;U.har&&(z._har=new J(z),U=z._har.options(U)),u.Stream.call(z);var ne=Object.keys(ee.prototype),fe=T(ne,U);P(z,fe),U=M(ne,U),z.readable=!0,z.writable=!0,U.method&&(z.explicitMethod=!0),z._qs=new Y(z),z._auth=new ie(z),z._oauth=new ue(z),z._multipart=new ce(z),z._redirect=new he(z),z._tunnel=new ke(z),z.init(U)}o.inherits(ee,u.Stream),ee.debug=process$1.env.NODE_DEBUG&&/\brequest\b/.test(process$1.env.NODE_DEBUG);function Z(){ee.debug&&console.error("REQUEST %s",o.format.apply(o,arguments))}return ee.prototype.debug=Z,ee.prototype.init=function(U){var z=this;U||(U={}),z.headers=z.headers?x(z.headers):{};for(var ne in z.headers)typeof z.headers[ne]>"u"&&delete z.headers[ne];if(k.httpify(z,z.headers),z.method||(z.method=U.method||"GET"),z.localAddress||(z.localAddress=U.localAddress),z._qs.init(U),Z(U),!z.pool&&z.pool!==!1&&(z.pool=h),z.dests=z.dests||[],z.__isRequestRequest=!0,!z._callback&&z.callback&&(z._callback=z.callback,z.callback=function(){z._callbackCalled||(z._callbackCalled=!0,z._callback.apply(z,arguments))},z.on("error",z.callback.bind()),z.on("complete",z.callback.bind(z,null))),!z.uri&&z.url&&(z.uri=z.url,delete z.url),z.baseUrl){if(typeof z.baseUrl!="string")return z.emit("error",new Error("options.baseUrl must be a string"));if(typeof z.uri!="string")return z.emit("error",new Error("options.uri must be a string when using options.baseUrl"));if(z.uri.indexOf("//")===0||z.uri.indexOf("://")!==-1)return z.emit("error",new Error("options.uri must be a path when using options.baseUrl"));var fe=z.baseUrl.lastIndexOf("/")===z.baseUrl.length-1,me=z.uri.indexOf("/")===0;fe&&me?z.uri=z.baseUrl+z.uri.slice(1):fe||me?z.uri=z.baseUrl+z.uri:z.uri===""?z.uri=z.baseUrl:z.uri=z.baseUrl+"/"+z.uri,delete z.baseUrl}if(!z.uri)return z.emit("error",new Error("options.uri is a required argument"));if(typeof z.uri=="string"&&(z.uri=n.parse(z.uri)),z.uri.href||(z.uri.href=n.format(z.uri)),z.uri.protocol==="unix:")return z.emit("error",new Error("`unix://` URL scheme is no longer supported. Please use the format `http://unix:SOCKET:PATH`"));if(z.uri.host==="unix"&&z.enableUnixSocket(),z.strictSSL===!1&&(z.rejectUnauthorized=!1),z.uri.pathname||(z.uri.pathname="/"),!(z.uri.host||z.uri.hostname&&z.uri.port)&&!z.uri.isUnix){var de=n.format(z.uri),je='Invalid URI "'+de+'"';return Object.keys(U).length===0&&(je+=". This can be caused by a crappy redirection."),z.abort(),z.emit("error",new Error(je))}if(z.hasOwnProperty("proxy")||(z.proxy=N(z.uri)),z.tunnel=z._tunnel.isEnabled(),z.proxy&&z._tunnel.setup(U),z._redirect.onRequest(U),z.setHost=!1,!z.hasHeader("host")){var lt=z.originalHostHeaderName||"host";z.setHeader(lt,z.uri.host),z.uri.port&&(z.uri.port==="80"&&z.uri.protocol==="http:"||z.uri.port==="443"&&z.uri.protocol==="https:")&&z.setHeader(lt,z.uri.hostname),z.setHost=!0}if(z.jar(z._jar||U.jar),z.uri.port||(z.uri.protocol==="http:"?z.uri.port=80:z.uri.protocol==="https:"&&(z.uri.port=443)),z.proxy&&!z.tunnel?(z.port=z.proxy.port,z.host=z.proxy.hostname):(z.port=z.uri.port,z.host=z.uri.hostname),U.form&&z.form(U.form),U.formData){var it=U.formData,ot=z.form(),Ct=function(Yt,Ce){Ce&&Ce.hasOwnProperty("value")&&Ce.hasOwnProperty("options")?ot.append(Yt,Ce.value,Ce.options):ot.append(Yt,Ce)};for(var nt in it)if(it.hasOwnProperty(nt)){var Je=it[nt];if(Je instanceof Array)for(var tt=0;tt<Je.length;tt++)Ct(nt,Je[tt]);else Ct(nt,Je)}}if(U.qs&&z.qs(U.qs),z.uri.path?z.path=z.uri.path:z.path=z.uri.pathname+(z.uri.search||""),z.path.length===0&&(z.path="/"),U.aws&&z.aws(U.aws),U.hawk&&z.hawk(U.hawk),U.httpSignature&&z.httpSignature(U.httpSignature),U.auth&&(Object.prototype.hasOwnProperty.call(U.auth,"username")&&(U.auth.user=U.auth.username),Object.prototype.hasOwnProperty.call(U.auth,"password")&&(U.auth.pass=U.auth.password),z.auth(U.auth.user,U.auth.pass,U.auth.sendImmediately,U.auth.bearer)),z.gzip&&!z.hasHeader("accept-encoding")&&z.setHeader("accept-encoding","gzip, deflate"),z.uri.auth&&!z.hasHeader("authorization")){var rt=z.uri.auth.split(":").map(function(Yt){return z._qs.unescape(Yt)});z.auth(rt[0],rt.slice(1).join(":"),!0)}if(!z.tunnel&&z.proxy&&z.proxy.auth&&!z.hasHeader("proxy-authorization")){var ht=z.proxy.auth.split(":").map(function(Yt){return z._qs.unescape(Yt)}),Ot="Basic "+c(ht.join(":"));z.setHeader("proxy-authorization",Ot)}z.proxy&&!z.tunnel&&(z.path=z.uri.protocol+"//"+z.uri.host+z.path),U.json&&z.json(U.json),U.multipart&&z.multipart(U.multipart),U.time&&(z.timing=!0,z.elapsedTime=z.elapsedTime||0);function Ve(){if(B(z.body)&&(z.body=d.from(z.body)),!z.hasHeader("content-length")){var Yt;typeof z.body=="string"?Yt=d.byteLength(z.body):Array.isArray(z.body)?Yt=z.body.reduce(function(Ce,te){return Ce+te.length},0):Yt=z.body.length,Yt?z.setHeader("content-length",Yt):z.emit("error",new Error("Argument error, options.body."))}}z.body&&!R(z.body)&&Ve(),U.oauth?z.oauth(U.oauth):z._oauth.params&&z.hasHeader("authorization")&&z.oauth(z._oauth.params);var We=z.proxy&&!z.tunnel?z.proxy.protocol:z.uri.protocol,Gt={"http:":t,"https:":e},wt=z.httpModules||{};if(z.httpModule=wt[We]||Gt[We],!z.httpModule)return z.emit("error",new Error("Invalid protocol: "+We));if(U.ca&&(z.ca=U.ca),!z.agent)if(U.agentOptions&&(z.agentOptions=U.agentOptions),U.agentClass)z.agentClass=U.agentClass;else if(U.forever){var Et=S();Et.major===0&&Et.minor<=10?z.agentClass=We==="http:"?A:A.SSL:(z.agentClass=z.httpModule.Agent,z.agentOptions=z.agentOptions||{},z.agentOptions.keepAlive=!0)}else z.agentClass=z.httpModule.Agent;z.pool===!1?z.agent=!1:z.agent=z.agent||z.getNewAgent(),z.on("pipe",function(Yt){if(z.ntick&&z._started&&z.emit("error",new Error("You cannot pipe to this stream after the outbound request has started.")),z.src=Yt,w(Yt))z.hasHeader("content-type")||z.setHeader("content-type",C.lookup(Yt.path));else{if(Yt.headers)for(var Ce in Yt.headers)z.hasHeader(Ce)||z.setHeader(Ce,Yt.headers[Ce]);z._json&&!z.hasHeader("content-type")&&z.setHeader("content-type","application/json"),Yt.method&&!z.explicitMethod&&(z.method=Yt.method)}}),p(function(){if(!z._aborted){var Yt=function(){if(z._form&&(z._auth.hasAuth?z._auth.hasAuth&&z._auth.sentAuth&&z._form.pipe(z):z._form.pipe(z)),z._multipart&&z._multipart.chunked&&z._multipart.body.pipe(z),z.body)R(z.body)?z.body.pipe(z):(Ve(),Array.isArray(z.body)?z.body.forEach(function(Ce){z.write(Ce)}):z.write(z.body),z.end());else if(z.requestBodyStream)console.warn("options.requestBodyStream is deprecated, please pass the request object to stream.pipe."),z.requestBodyStream.pipe(z);else if(!z.src){if(z._auth.hasAuth&&!z._auth.sentAuth){z.end();return}z.method!=="GET"&&typeof z.method<"u"&&z.setHeader("content-length",0),z.end()}};z._form&&!z.hasHeader("content-length")?(z.setHeader(z._form.getHeaders(),!0),z._form.getLength(function(Ce,te){!Ce&&!isNaN(te)&&z.setHeader("content-length",te),Yt()})):Yt(),z.ntick=!0}})},ee.prototype.getNewAgent=function(){var U=this,z=U.agentClass,ne={};if(U.agentOptions)for(var fe in U.agentOptions)ne[fe]=U.agentOptions[fe];U.ca&&(ne.ca=U.ca),U.ciphers&&(ne.ciphers=U.ciphers),U.secureProtocol&&(ne.secureProtocol=U.secureProtocol),U.secureOptions&&(ne.secureOptions=U.secureOptions),typeof U.rejectUnauthorized<"u"&&(ne.rejectUnauthorized=U.rejectUnauthorized),U.cert&&U.key&&(ne.key=U.key,ne.cert=U.cert),U.pfx&&(ne.pfx=U.pfx),U.passphrase&&(ne.passphrase=U.passphrase);var me="";z!==U.httpModule.Agent&&(me+=z.name);var de=U.proxy;typeof de=="string"&&(de=n.parse(de));var je=de&&de.protocol==="https:"||this.uri.protocol==="https:";return je&&(ne.ca&&(me&&(me+=":"),me+=ne.ca),typeof ne.rejectUnauthorized<"u"&&(me&&(me+=":"),me+=ne.rejectUnauthorized),ne.cert&&(me&&(me+=":"),me+=ne.cert.toString("ascii")+ne.key.toString("ascii")),ne.pfx&&(me&&(me+=":"),me+=ne.pfx.toString("ascii")),ne.ciphers&&(me&&(me+=":"),me+=ne.ciphers),ne.secureProtocol&&(me&&(me+=":"),me+=ne.secureProtocol),ne.secureOptions&&(me&&(me+=":"),me+=ne.secureOptions)),U.pool===h&&!me&&Object.keys(ne).length===0&&U.httpModule.globalAgent?U.httpModule.globalAgent:(me=U.uri.protocol+me,U.pool[me]||(U.pool[me]=new z(ne),U.pool.maxSockets&&(U.pool[me].maxSockets=U.pool.maxSockets)),U.pool[me])},ee.prototype.start=function(){var U=this;if(U.timing)var z=new Date().getTime(),ne=L();if(!U._aborted){U._started=!0,U.method=U.method||"GET",U.href=U.uri.href,U.src&&U.src.stat&&U.src.stat.size&&!U.hasHeader("content-length")&&U.setHeader("content-length",U.src.stat.size),U._aws&&U.aws(U._aws,!0);var fe=x(U);delete fe.auth,Z("make request",U.uri.href),delete fe.timeout;try{U.req=U.httpModule.request(fe)}catch(de){U.emit("error",de);return}U.timing&&(U.startTime=z,U.startTimeNow=ne,U.timings={});var me;U.timeout&&!U.timeoutTimer&&(U.timeout<0?me=0:typeof U.timeout=="number"&&isFinite(U.timeout)&&(me=U.timeout)),U.req.on("response",U.onRequestResponse.bind(U)),U.req.on("error",U.onRequestError.bind(U)),U.req.on("drain",function(){U.emit("drain")}),U.req.on("socket",function(de){var je=de._connecting||de.connecting;if(U.timing&&(U.timings.socket=L()-U.startTimeNow,je)){var lt=function(){U.timings.lookup=L()-U.startTimeNow},it=function(){U.timings.connect=L()-U.startTimeNow};de.once("lookup",lt),de.once("connect",it),U.req.once("error",function(){de.removeListener("lookup",lt),de.removeListener("connect",it)})}var ot=function(){U.req.setTimeout(me,function(){if(U.req){U.abort();var nt=new Error("ESOCKETTIMEDOUT");nt.code="ESOCKETTIMEDOUT",nt.connect=!1,U.emit("error",nt)}})};if(me!==void 0)if(je){var Ct=function(){de.removeListener("connect",Ct),U.clearTimeout(),ot()};de.on("connect",Ct),U.req.on("error",function(nt){de.removeListener("connect",Ct)}),U.timeoutTimer=setTimeout(function(){de.removeListener("connect",Ct),U.abort();var nt=new Error("ETIMEDOUT");nt.code="ETIMEDOUT",nt.connect=!0,U.emit("error",nt)},me)}else ot();U.emit("socket",de)}),U.emit("request",U.req)}},ee.prototype.onRequestError=function(U){var z=this;if(!z._aborted){if(z.req&&z.req._reusedSocket&&U.code==="ECONNRESET"&&z.agent.addRequestNoreuse){z.agent={addRequest:z.agent.addRequestNoreuse.bind(z.agent)},z.start(),z.req.end();return}z.clearTimeout(),z.emit("error",U)}},ee.prototype.onRequestResponse=function(U){var z=this;if(z.timing&&(z.timings.response=L()-z.startTimeNow),Z("onRequestResponse",z.uri.href,U.statusCode,U.headers),U.on("end",function(){z.timing&&(z.timings.end=L()-z.startTimeNow,U.timingStart=z.startTime,z.timings.socket||(z.timings.socket=0),z.timings.lookup||(z.timings.lookup=z.timings.socket),z.timings.connect||(z.timings.connect=z.timings.lookup),z.timings.response||(z.timings.response=z.timings.connect),Z("elapsed time",z.timings.end),z.elapsedTime+=Math.round(z.timings.end),U.elapsedTime=z.elapsedTime,U.timings=z.timings,U.timingPhases={wait:z.timings.socket,dns:z.timings.lookup-z.timings.socket,tcp:z.timings.connect-z.timings.lookup,firstByte:z.timings.response-z.timings.connect,download:z.timings.end-z.timings.response,total:z.timings.end}),Z("response end",z.uri.href,U.statusCode,U.headers)}),z._aborted){Z("aborted",z.uri.href),U.resume();return}if(z.response=U,U.request=z,U.toJSON=V,z.httpModule===e&&z.strictSSL&&(!U.hasOwnProperty("socket")||!U.socket.authorized)){Z("strict ssl error",z.uri.href);var ne=U.hasOwnProperty("socket")?U.socket.authorizationError:z.uri.href+" does not support SSL";z.emit("error",new Error("SSL Error: "+ne));return}z.originalHost=z.getHeader("host"),z.originalHostHeaderName||(z.originalHostHeaderName=z.hasHeader("host")),z.setHost&&z.removeHeader("host"),z.clearTimeout();var fe=z._jar&&z._jar.setCookie?z._jar:b,me=function(Ct){try{fe.setCookie(Ct,z.uri.href,{ignoreError:!0})}catch(nt){z.emit("error",nt)}};if(U.caseless=k(U.headers),U.caseless.has("set-cookie")&&!z._disableCookies){var de=U.caseless.has("set-cookie");Array.isArray(U.headers[de])?U.headers[de].forEach(me):me(U.headers[de])}if(!z._redirect.onResponse(U)){{U.on("close",function(){z._ended||z.response.emit("end")}),U.once("end",function(){z._ended=!0});var je=function(Ct){return z.method==="HEAD"||Ct>=100&&Ct<200||Ct===204||Ct===304},lt;if(z.gzip&&!je(U.statusCode)){var it=U.headers["content-encoding"]||"identity";it=it.trim().toLowerCase();var ot={flush:l.Z_SYNC_FLUSH,finishFlush:l.Z_SYNC_FLUSH};it==="gzip"?(lt=l.createGunzip(ot),U.pipe(lt)):it==="deflate"?(lt=l.createInflate(ot),U.pipe(lt)):(it!=="identity"&&Z("ignoring unrecognized Content-Encoding "+it),lt=U)}else lt=U;z.encoding&&(z.dests.length!==0?console.error("Ignoring encoding parameter as this stream is being piped to another stream which makes the encoding option invalid."):lt.setEncoding(z.encoding)),z._paused&&lt.pause(),z.responseContent=lt,z.emit("response",U),z.dests.forEach(function(Ct){z.pipeDest(Ct)}),lt.on("data",function(Ct){z.timing&&!z.responseStarted&&(z.responseStartTime=new Date().getTime(),U.responseStartTime=z.responseStartTime),z._destdata=!0,z.emit("data",Ct)}),lt.once("end",function(Ct){z.emit("end",Ct)}),lt.on("error",function(Ct){z.emit("error",Ct)}),lt.on("close",function(){z.emit("close")}),z.callback?z.readResponseBody(U):z.on("end",function(){if(z._aborted){Z("aborted",z.uri.href);return}z.emit("complete",U)})}Z("finish init function",z.uri.href)}},ee.prototype.readResponseBody=function(U){var z=this;Z("reading response's body");var ne=[],fe=0,me=[];z.on("data",function(de){d.isBuffer(de)?de.length&&(fe+=de.length,ne.push(de)):me.push(de)}),z.on("end",function(){if(Z("end event",z.uri.href),z._aborted){Z("aborted",z.uri.href),ne=[],fe=0;return}if(fe?(Z("has body",z.uri.href,fe),U.body=d.concat(ne,fe),z.encoding!==null&&(U.body=U.body.toString(z.encoding)),ne=[],fe=0):me.length&&(z.encoding==="utf8"&&me[0].length>0&&me[0][0]==="\uFEFF"&&(me[0]=me[0].substring(1)),U.body=me.join("")),z._json)try{U.body=JSON.parse(U.body,z._jsonReviver)}catch{Z("invalid JSON received",z.uri.href)}Z("emitting complete",z.uri.href),typeof U.body>"u"&&!z._json&&(U.body=z.encoding===null?d.alloc(0):""),z.emit("complete",U,U.body)})},ee.prototype.abort=function(){var U=this;U._aborted=!0,U.req?U.req.abort():U.response&&U.response.destroy(),U.clearTimeout(),U.emit("abort")},ee.prototype.pipeDest=function(U){var z=this,ne=z.response;if(U.headers&&!U.headersSent){if(ne.caseless.has("content-type")){var fe=ne.caseless.has("content-type");U.setHeader?U.setHeader(fe,ne.headers[fe]):U.headers[fe]=ne.headers[fe]}if(ne.caseless.has("content-length")){var me=ne.caseless.has("content-length");U.setHeader?U.setHeader(me,ne.headers[me]):U.headers[me]=ne.headers[me]}}if(U.setHeader&&!U.headersSent){for(var de in ne.headers)(!z.gzip||de!=="content-encoding")&&U.setHeader(de,ne.headers[de]);U.statusCode=ne.statusCode}z.pipefilter&&z.pipefilter(ne,U)},ee.prototype.qs=function(U,z){var ne=this,fe;!z&&ne.uri.query?fe=ne._qs.parse(ne.uri.query):fe={};for(var me in U)fe[me]=U[me];var de=ne._qs.stringify(fe);return de===""||(ne.uri=n.parse(ne.uri.href.split("?")[0]+"?"+de),ne.url=ne.uri,ne.path=ne.uri.path,ne.uri.host==="unix"&&ne.enableUnixSocket()),ne},ee.prototype.form=function(U){var z=this;return U?(/^application\/x-www-form-urlencoded\b/.test(z.getHeader("content-type"))||z.setHeader("content-type","application/x-www-form-urlencoded"),z.body=typeof U=="string"?z._qs.rfc3986(U.toString("utf8")):z._qs.stringify(U).toString("utf8"),z):(z._form=new D,z._form.on("error",function(ne){ne.message="form-data: "+ne.message,z.emit("error",ne),z.abort()}),z._form)},ee.prototype.multipart=function(U){var z=this;return z._multipart.onRequest(U),z._multipart.chunked||(z.body=z._multipart.body),z},ee.prototype.json=function(U){var z=this;return z.hasHeader("accept")||z.setHeader("accept","application/json"),typeof z.jsonReplacer=="function"&&(z._jsonReplacer=z.jsonReplacer),z._json=!0,typeof U=="boolean"?z.body!==void 0&&(/^application\/x-www-form-urlencoded\b/.test(z.getHeader("content-type"))?z.body=z._qs.rfc3986(z.body):z.body=v(z.body,z._jsonReplacer),z.hasHeader("content-type")||z.setHeader("content-type","application/json")):(z.body=v(U,z._jsonReplacer),z.hasHeader("content-type")||z.setHeader("content-type","application/json")),typeof z.jsonReviver=="function"&&(z._jsonReviver=z.jsonReviver),z},ee.prototype.getHeader=function(U,z){var ne=this,fe,me,de;return z||(z=ne.headers),Object.keys(z).forEach(function(je){je.length===U.length&&(me=new RegExp(U,"i"),de=je.match(me),de&&(fe=z[je]))}),fe},ee.prototype.enableUnixSocket=function(){var U=this.uri.path.split(":"),z=U[0],ne=U[1];this.socketPath=z,this.uri.pathname=ne,this.uri.path=ne,this.uri.host=z,this.uri.hostname=z,this.uri.isUnix=!0},ee.prototype.auth=function(U,z,ne,fe){var me=this;return me._auth.onRequest(U,z,ne,fe),me},ee.prototype.aws=function(U,z){var ne=this;if(!z)return ne._aws=U,ne;if(U.sign_version===4||U.sign_version==="4"){var fe={host:ne.uri.host,path:ne.uri.path,method:ne.method,headers:ne.headers,body:ne.body};U.service&&(fe.service=U.service);var me=y.sign(fe,{accessKeyId:U.key,secretAccessKey:U.secret,sessionToken:U.session});ne.setHeader("authorization",me.headers.Authorization),ne.setHeader("x-amz-date",me.headers["X-Amz-Date"]),me.headers["X-Amz-Security-Token"]&&ne.setHeader("x-amz-security-token",me.headers["X-Amz-Security-Token"])}else{var de=new Date;ne.setHeader("date",de.toUTCString());var je={key:U.key,secret:U.secret,verb:ne.method.toUpperCase(),date:de,contentType:ne.getHeader("content-type")||"",md5:ne.getHeader("content-md5")||"",amazonHeaders:m.canonicalizeHeaders(ne.headers)},lt=ne.uri.path;U.bucket&&lt?je.resource="/"+U.bucket+lt:U.bucket&&!lt?je.resource="/"+U.bucket:!U.bucket&&lt?je.resource=lt:!U.bucket&&!lt&&(je.resource="/"),je.resource=m.canonicalizeResource(je.resource),ne.setHeader("authorization",m.authorization(je))}return ne},ee.prototype.httpSignature=function(U){var z=this;return E.signRequest({getHeader:function(ne){return z.getHeader(ne,z.headers)},setHeader:function(ne,fe){z.setHeader(ne,fe)},method:z.method,path:z.path},U),Z("httpSignature authorization",z.getHeader("authorization")),z},ee.prototype.hawk=function(U){var z=this;z.setHeader("Authorization",Q.header(z.uri,z.method,U))},ee.prototype.oauth=function(U){var z=this;return z._oauth.onRequest(U),z},ee.prototype.jar=function(U){var z=this,ne;if(z._redirect.redirectsFollowed===0&&(z.originalCookieHeader=z.getHeader("cookie")),!U)ne=!1,z._disableCookies=!0;else{var fe=U.getCookieString?U:b,me=z.uri.href;fe&&(ne=fe.getCookieString(me))}return ne&&ne.length&&(z.originalCookieHeader?z.setHeader("cookie",z.originalCookieHeader+"; "+ne):z.setHeader("cookie",ne)),z._jar=U,z},ee.prototype.pipe=function(U,z){var ne=this;if(ne.response)if(ne._destdata)ne.emit("error",new Error("You cannot pipe after data has been emitted from the response."));else if(ne._ended)ne.emit("error",new Error("You cannot pipe after the response has been ended."));else return u.Stream.prototype.pipe.call(ne,U,z),ne.pipeDest(U),U;else return ne.dests.push(U),u.Stream.prototype.pipe.call(ne,U,z),U},ee.prototype.write=function(){var U=this;if(!U._aborted&&(U._started||U.start(),U.req))return U.req.write.apply(U.req,arguments)},ee.prototype.end=function(U){var z=this;z._aborted||(U&&z.write(U),z._started||z.start(),z.req&&z.req.end())},ee.prototype.pause=function(){var U=this;U.responseContent?U.responseContent.pause.apply(U.responseContent,arguments):U._paused=!0},ee.prototype.resume=function(){var U=this;U.responseContent?U.responseContent.resume.apply(U.responseContent,arguments):U._paused=!1},ee.prototype.destroy=function(){var U=this;this.clearTimeout(),U._ended?U.response&&U.response.destroy():U.end()},ee.prototype.clearTimeout=function(){this.timeoutTimer&&(clearTimeout(this.timeoutTimer),this.timeoutTimer=null)},ee.defaultProxyHeaderWhiteList=ke.defaultProxyHeaderWhiteList.slice(),ee.defaultProxyHeaderExclusiveList=ke.defaultProxyHeaderExclusiveList.slice(),ee.prototype.toJSON=O,request$2=ee,request$2}var extend=extend$1,cookies=cookies$1,helpers=helpers$1,paramsHaveRequestBody=helpers.paramsHaveRequestBody;function initParams(t,e,n){typeof e=="function"&&(n=e);var o={};return e!==null&&typeof e=="object"?extend(o,e,{uri:t}):typeof t=="string"?extend(o,{uri:t}):extend(o,t),o.callback=n||o.callback,o}function request$1(t,e,n){if(typeof t>"u")throw new Error("undefined is not a valid uri or options object.");var o=initParams(t,e,n);if(o.method==="HEAD"&&paramsHaveRequestBody(o))throw new Error("HTTP HEAD requests MUST NOT include a request body.");return new request$1.Request(o)}function verbFunc(t){var e=t.toUpperCase();return function(n,o,u){var l=initParams(n,o,u);return l.method=e,request$1(l,l.callback)}}request$1.get=verbFunc("get"),request$1.head=verbFunc("head"),request$1.options=verbFunc("options"),request$1.post=verbFunc("post"),request$1.put=verbFunc("put"),request$1.patch=verbFunc("patch"),request$1.del=verbFunc("delete"),request$1.delete=verbFunc("delete"),request$1.jar=function(t){return cookies.jar(t)},request$1.cookie=function(t){return cookies.parse(t)};function wrapRequestMethod(t,e,n,o){return function(u,l,m){var y=initParams(u,l,m),E={};return extend(!0,E,e,y),E.pool=y.pool||e.pool,o&&(E.method=o.toUpperCase()),typeof n=="function"&&(t=n),t(E,E.callback)}}request$1.defaults=function(t,e){var n=this;t=t||{},typeof t=="function"&&(e=t,t={});var o=wrapRequestMethod(n,t,e),u=["get","head","post","put","patch","del","delete"];return u.forEach(function(l){o[l]=wrapRequestMethod(n[l],t,e,l)}),o.cookie=wrapRequestMethod(n.cookie,t,e),o.jar=n.jar,o.defaults=n.defaults,o},request$1.forever=function(t,e){var n={};return e&&extend(n,e),t&&(n.agentOptions=t),n.forever=!0,request$1.defaults(n)};var request_1=request$1;request$1.Request=requireRequest(),request$1.initParams=initParams,Object.defineProperty(request$1,"debug",{enumerable:!0,get:function(){return request$1.Request.debug},set:function(t){request$1.Request.debug=t}});var sha1$1={exports:{}},crypt={exports:{}};(function(){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e={rotl:function(n,o){return n<<o|n>>>32-o},rotr:function(n,o){return n<<32-o|n>>>o},endian:function(n){if(n.constructor==Number)return e.rotl(n,8)&16711935|e.rotl(n,24)&4278255360;for(var o=0;o<n.length;o++)n[o]=e.endian(n[o]);return n},randomBytes:function(n){for(var o=[];n>0;n--)o.push(Math.floor(Math.random()*256));return o},bytesToWords:function(n){for(var o=[],u=0,l=0;u<n.length;u++,l+=8)o[l>>>5]|=n[u]<<24-l%32;return o},wordsToBytes:function(n){for(var o=[],u=0;u<n.length*32;u+=8)o.push(n[u>>>5]>>>24-u%32&255);return o},bytesToHex:function(n){for(var o=[],u=0;u<n.length;u++)o.push((n[u]>>>4).toString(16)),o.push((n[u]&15).toString(16));return o.join("")},hexToBytes:function(n){for(var o=[],u=0;u<n.length;u+=2)o.push(parseInt(n.substr(u,2),16));return o},bytesToBase64:function(n){for(var o=[],u=0;u<n.length;u+=3)for(var l=n[u]<<16|n[u+1]<<8|n[u+2],m=0;m<4;m++)u*8+m*6<=n.length*8?o.push(t.charAt(l>>>6*(3-m)&63)):o.push("=");return o.join("")},base64ToBytes:function(n){n=n.replace(/[^A-Z0-9+\/]/ig,"");for(var o=[],u=0,l=0;u<n.length;l=++u%4)l!=0&&o.push((t.indexOf(n.charAt(u-1))&Math.pow(2,-2*l+8)-1)<<l*2|t.indexOf(n.charAt(u))>>>6-l*2);return o}};crypt.exports=e})();var cryptExports=crypt.exports,charenc={utf8:{stringToBytes:function(t){return charenc.bin.stringToBytes(unescape(encodeURIComponent(t)))},bytesToString:function(t){return decodeURIComponent(escape(charenc.bin.bytesToString(t)))}},bin:{stringToBytes:function(t){for(var e=[],n=0;n<t.length;n++)e.push(t.charCodeAt(n)&255);return e},bytesToString:function(t){for(var e=[],n=0;n<t.length;n++)e.push(String.fromCharCode(t[n]));return e.join("")}}},charenc_1=charenc;(function(){var t=cryptExports,e=charenc_1.utf8,n=charenc_1.bin,o=function(l){l.constructor==String?l=e.stringToBytes(l):typeof Buffer$C<"u"&&typeof Buffer$C.isBuffer=="function"&&Buffer$C.isBuffer(l)?l=Array.prototype.slice.call(l,0):Array.isArray(l)||(l=l.toString());var m=t.bytesToWords(l),y=l.length*8,E=[],C=1732584193,k=-271733879,A=-1732584194,D=271733878,P=-1009589776;m[y>>5]|=128<<24-y%32,m[(y+64>>>9<<4)+15]=y;for(var R=0;R<m.length;R+=16){for(var B=C,F=k,j=A,N=D,Y=P,J=0;J<80;J++){if(J<16)E[J]=m[R+J];else{var ie=E[J-3]^E[J-8]^E[J-14]^E[J-16];E[J]=ie<<1|ie>>>31}var ue=(C<<5|C>>>27)+P+(E[J]>>>0)+(J<20?(k&A|~k&D)+1518500249:J<40?(k^A^D)+1859775393:J<60?(k&A|k&D|A&D)-1894007588:(k^A^D)-899497514);P=D,D=A,A=k<<30|k>>>2,k=C,C=ue}C+=B,k+=F,A+=j,D+=N,P+=Y}return[C,k,A,D,P]},u=function(l,m){var y=t.wordsToBytes(o(l));return m&&m.asBytes?y:m&&m.asString?n.bytesToString(y):t.bytesToHex(y)};u._blocksize=16,u._digestsize=20,sha1$1.exports=u})();var sha1Exports=sha1$1.exports,php2js$1={rawurlencode:function(t){return t=(t+"").toString(),encodeURIComponent(t).replace(/!/g,"%21").replace(/'/g,"%27").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/\*/g,"%2A").replace(/\+/g," ")},http_build_query:function(t,e,n){var o,u,l=[],m=function(E,C,k){var A,D=[];if(C===!0?C="1":C===!1&&(C="0"),C!=null)if(typeof C=="object"){for(A in C)C[A]!=null&&D.push(m(E+"["+A+"]",C[A],k));return D.join(k)}else{if(typeof C!="function")return php2js$1.urlencode(E)+"="+php2js$1.urlencode(C);throw new Error("There was an error processing for http_build_query().")}else return""};n||(n="&");for(u in t){o=t[u],e&&!isNaN(u)&&(u=String(e)+u);var y=m(u,o,n);y!==""&&l.push(y)}return l.join(n)},urlencode:function(t){return t=(t+"").toString(),encodeURIComponent(t).replace(/!/g,"%21").replace(/'/g,"%27").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/\*/g,"%2A").replace(/%20/g,"+")}},php2js_1=php2js$1,request=request_1,sha1=sha1Exports,php2js=php2js_1,APIConfig={url:"http://api.jwplatform.com/v1/videos/create",key:"",secret:"",format:"json",kit:"php-1.4"},jwplayer$1={makeRequest:function(t,e){request({url:t,method:"GET",headers:{"Content-Type":"MyContentType","Custom-Header":"Custom Value"}},e)},setArguments:function(t,e){t.api_nonce=Math.floor(Math.random()*1e8),t.api_timestamp=Math.floor(Date.now()/1e3),t.api_key=APIConfig.key,t.api_format=APIConfig.format,t.api_kit=APIConfig.kit;var n={};Object.keys(t).sort().forEach(function(l){n[l]=t[l]});var o="";Object.keys(n).forEach(function(l){o!=""&&(o+="&"),o+=php2js.rawurlencode(l)+"="+php2js.rawurlencode(n[l])}),t.api_signature=sha1(o+APIConfig.secret);var u=APIConfig.url+"?"+php2js.http_build_query(t,"","&");jwplayer$1.makeRequest(u,e)}},jwplayer_1=jwplayer$1;const JwpPlayerWidget=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){var n={},o=jwplayer_1.Player(this.$[0]),u=!1,l=!0;typeof this.video>"u"&&(this.video=this.media.video),n.file=this.video,n.primary="flash",n.fallback=!1,n.controls=!1,n.width=this.width,this.height&&(n.height=this.height),this.autostart,this.url_transform&&(n.file=this.url_transform(n.file));var m=this.media;m.on("setcurrenttime",function(E){u=l,o.seek(E/1e3)}),m.on("setvolume",function(E){o.setVolume(Math.floor(E*100)),m.volume=E}),m.on("setmuted",function(E){o.setMute(E),m.muted=E}),m.on("setplay",function(){o.play(!0),m.paused=!1}),m.on("setpause",function(){o.pause(!0),m.paused=!0});function y(){m.muted=o.getMute(),m.volume=o.getVolume()/100}n.events={onReady:function(){y(),m.currentTime=new t.Model.Time(1e3*o.getPosition()||0),m.trigger("loadedmetadata")},onTime:function(E){u?(o.pause(!0),u=!1):l&&o.getState()==="PLAYING"&&(l=!1,m.trigger("play")),m.trigger("timeupdate",new t.Model.Time(E.position*1e3))},onPlay:function(){u||(l=!1,m.trigger("play"))},onPause:function(){l=!0,m.trigger("pause")},onSeek:function(){m.trigger("seeked")},onMute:function(E){m.muted=E.mute,m.trigger("volumechange")},onVolume:function(E){m.volume=E.volume/100,m.trigger("volumechange")}},o=o.setup(n),this.jwplayer=o}},Fi(e,"defaults",{}),e},latestAnnotationStyles={},LatestAnnotation=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}importUsers(){if(!this.source.users_data){this.usernames=Array();var n=this,o=this.getWidgetAnnotations(),u="";return o.forEach(function(l){n.usernames.indexOf(l.creator)==-1&&n.usernames.push(l.creator)}),this.usernames.forEach(function(l){u+=l+","}),u=u.substring(0,u.length-1),_url=mustache.render(this.api_users_endpoint,{usernames_list_string:encodeURIComponent(u),usernames_list_length:this.usernames.length}),jQuery.ajax({async:!1,url:_url,type:"GET",success:function(l){n.source.users_data=l.objects},error:function(l,m,y){console.log(l),console.log(m),console.log(y)}})}}draw(){var n=this;this.renderTemplate(),this.annotationContainer_$=this.$.find(".Ldt-LatestAnnotation"),this.selectable_annotations&&(this.onMdpEvent("AnnotationsList.refresh",function(){n.getWidgetAnnotations().forEach(function(o){o.off("click"),o.on("click",function(){var u={},l="",m=this.source.users_data.filter(function(y){return y.username==o.creator});m.length==0?u.username=o.creator:u=m[0],l=n.make_name_string_function(u),_html=mustache.render(n.annotationTemplate,{annotation_created:o.created.toLocaleDateString()+", "+o.created.toLocaleTimeString(),annotation_creator:l,annotation_title:o.title,annotation_content:o.description,copy_and_edit_button:n.copy_and_edit_button,button_text:n.l10n.copy_and_edit}),n.annotationContainer_$.html(_html),n.selectedAnnotation=!0})})}),this.segments=n.source.getAnnotationsByTypeTitle(this.segments_annotation_type),this.segments.forEach(function(o){o.on("click",function(){n.selectedAnnotation=!1})}),this.currentSegment=!1),this.onMediaEvent("timeupdate",function(){n.refresh()}),this.onMediaEvent("settimerange",function(o){n.refresh(o)}),this.starts_hidden?(this.visible=!0,this.hide()):(this.visible=!1,this.show()),this.selectedAnnotation=!1,this.player.trigger("AnnotationsList.refresh"),this.refresh()}refresh(n){n=typeof n<"u"?n:!1;var o=this;if(this.hide_without_segment){if(!n&&!this.media.getTimeRange()){var u=this.media.getCurrentTime(),l=this.segments.filter(function(R){return u>=R.begin&&u<=R.end});l.length==0?(this.currentSegment=!1,this.selectedAnnotation=!1):this.currentSegment=l[0]}else{var m=n?n[0]:this.media.getTimeRange()[0],y=n?n[1]:this.media.getTimeRange()[1];if(!this.currentSegment||this.currentSegment.begin!=m||this.currentSegment.end!=y){var l=this.segments.filter(function(B){return B.begin==m&&B.end==y});l.length>0&&(this.selectedAnnotation=!1,this.currentSegment=l[0])}}this.currentSegment?this.visible||this.show():this.visible&&this.hide()}if(this.visible&&!this.selectedAnnotation){var E=this.getWidgetAnnotations();this.filter_by_segment&&(this.currentSegment?E=E.filter(function(R){return _annotationTime=(R.begin+R.end)/2,o.currentSegment.begin<=_annotationTime&&o.currentSegment.end>=_annotationTime}):E=E.filter(function(R){return!1})),E=E.sortBy(function(R){return R.created});var C=!1,k="",A="",D={};if(E.length!=0)C=E.pop(),_users=this.source.users_data.filter(function(R){return R.username==C.creator}),_users.length==0?D.username=C.creator:D=_users[0],A=this.make_name_string_function(D),k=mustache.render(this.annotationTemplate,{annotation_created:C.created.toLocaleDateString()+", "+C.created.toLocaleTimeString(),annotation_creator:A,annotation_title:C.title,annotation_content:C.description,copy_and_edit_button:this.copy_and_edit_button,button_text:this.l10n.copy_and_edit});else{var P=this.l10n.empty;this.empty_message&&(P=this.empty_message),k="<div class='Ldt-LatestAnnotation-Element Ldt-LatestAnnotation-NoAnnotation'>"+P+"</div>"}this.annotationContainer_$.html(k)}this.copy_and_edit_button&&(this.copyAndEditButton_$=this.$.find(".Ldt-LatestAnnotation-CopyEditButton"),this.copyAndEditButton_$.click(this.functionWrapper("copy_and_edit")))}copy_and_edit(){this.player.trigger("CreateAnnotation.show"),this.hide_annotations_list&&this.player.trigger("AnnotationsList.hide"),annotationText=jQuery(".Ldt-LatestAnnotation-Content").get(0).innerHTML,jQuery(".Ldt-CreateAnnotation-Description").removeClass("empty"),jQuery(".Ldt-CreateAnnotation-Description").val(annotationText)}hide(){this.visible&&(this.visible=!1,this.$.find(".Ldt-LatestAnnotation-header").hide(),this.annotationContainer_$.hide())}show(){this.visible||(this.visible=!0,this.$.find(".Ldt-LatestAnnotation-header").show(),this.annotationContainer_$.show())}},Fi(e,"defaults",{pre_draw_callback:function(){return this.importUsers()},from_user:!1,filter_by_segment:!1,segments_annotation_type:"chap",hide_without_segment:!1,annotation_type:"contribution",show_only_annotation_from_user:!1,copy_and_edit_button:!1,hide_annotations_list:!1,selectable_annotations:!1,empty_message:!1,starts_hidden:!1,show_header:!1,custom_header:!1,make_name_string_function:function(n){return n.username?n.username:"Anonymous"}}),Fi(e,"messages",{fr:{copy_and_edit:"Copier et Editer",empty:"Aucune annotation à afficher",header:"Dernière annotation"},en:{copy_and_edit:"Copy and Edit",empty:"No annotation to display",header:"Last annotation"}}),Fi(e,"template","{{#show_header}}<p class='Ldt-LatestAnnotation-header'>{{#custom_header}}{{custom_header}}{{/custom_header}}{{^custom_header}}{{l10n.header}}{{/custom_header}}</p>{{/show_header}}<div class='Ldt-LatestAnnotation'></div>"),Fi(e,"annotationTemplate","<div class='Ldt-LatestAnnotation-Box'>{{#copy_and_edit_button}}<div class='Ldt-LatestAnnotation-CopyEditButton'>{{button_text}}</div>{{/copy_and_edit_button}}<div class='Ldt-LatestAnnotation-Element Ldt-LatestAnnotation-CreationDate'>{{{annotation_created}}}</div><div class='Ldt-LatestAnnotation-Element Ldt-LatestAnnotation-Title'>{{{annotation_creator}}}{{#annotation_title}}: {{{annotation_title}}}{{/annotation_title}}</div><div class='Ldt-LatestAnnotation-Element Ldt-LatestAnnotation-Content'>{{{annotation_content}}}</div></div>"),e},mashupPlayerStyles={},MashupPlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.is_mashup=!0}draw(){var n=this,o=this.media,u=null,l=null,m,y,E=0,C=!1,k,A,D=o.getMedias();o.paused=!this.autostart&&!this.autoplay;function P(){E>=o.duration&&(o.paused||(o.paused=!0,o.trigger("pause")),E=0);var j=o.getAnnotationAtTime(E);if(typeof j>"u"){u&&(u.pause(),o.paused||(o.paused=!0,o.trigger("pause")));return}if(j!==l){l=j,m=l.annotation.begin.milliseconds,y=l.annotation.end.milliseconds,A=m-l.begin.milliseconds,u=l.getMedia();for(var N=0;N<D.length;N++)D[N].id!==u.id?(n.split_screen||D[N].hide(),D[N].pause()):D[N].show();var Y=[],J=o.getAnnotations().filter(function(ie){return ie.begin>=l.end&&ie.getMedia()!==u});_$1(J).each(function(ie){var ue=ie.getMedia();_$1(Y).indexOf(ue.id)===-1&&(Y.push(ue.id),ue.setCurrentTime(ie.annotation.begin.getSeconds()),ue.seeking=!0)})}u.setCurrentTime(E+A),u.seeking=!0,o.paused||(u.play(),C=!0,k.show()),o.trigger("timeupdate",new t.Model.Time(E))}this.height||(this.height=Math.floor(this.width/this.aspect_ratio),this.$.css({height:this.height})),this.$.css({background:this.background});var R=Math.ceil(Math.sqrt(D.length)),B=this.split_screen?this.width/R:this.width,F=this.split_screen?this.height/R:this.height;_$1(D).each(function(j,N){var Y=jQuery('<div class="Ldt-MashupPlayer-Media"><div class="Ldt-MashupPlayer-Subwidget"></div></div>');Y.css({top:n.split_screen?F*Math.floor(N/R):0,left:n.split_screen?B*(N%R):0,height:F,width:B,display:n.split_screen?"block":"none"}),n.$.append(Y),n.insertSubwidget(Y.find(".Ldt-MashupPlayer-Subwidget"),_$1({type:n.player_type,media_id:j.id,height:F,width:B,url_transform:n.url_transform}).extend(n.player_options)),j.loadedMetadata=!1,j.show=function(){Y.show()},j.hide=function(){Y.hide()},j.on("loadedmetadata",function(){j.loadedMetadata=!0;for(var J=!0,ie=0;ie<D.length;ie++)J=J&&D[ie].loadedMetadata;J&&(k.fadeOut(),P(),o.trigger("loadedmetadata"))}),j.on("timeupdate",function(J){!o.paused&&j===u&&!j.seeking&&(J<y?J>=m?E=J-A:(E=m-A,j.setCurrentTime(m)):(E=y-A,j.pause(),P()),o.trigger("timeupdate",new t.Model.Time(E)))}),j.on("seeked",function(){j.seeking=!1,j===u&&C&&(C=!1,k.hide())}),j.on("play",function(){j===u&&o.trigger("play")}),j.on("pause",function(){j===u&&o.trigger("pause")}),j.on("volumechange",function(){o.muted=j.muted,o.volume=j.volume,o.trigger("volumechange")})}),k=jQuery('<div class="Ldt-MashupPlayer-Waiting"></div>'),this.$.append(k),o.on("setcurrenttime",function(j){E=j,P()}),o.on("setvolume",function(j){for(var N=0;N<D.length;N++)D[N].setVolume(j);o.volume=j}),o.on("setmuted",function(j){for(var N=0;N<D.length;N++)D[N].setMuted(j);o.muted=j}),o.on("setplay",function(){o.paused=!1,P()}),o.on("setpause",function(){o.paused=!0,u&&u.pause()}),o.on("loadedmetadata",P)}},Fi(e,"defaults",{aspect_ratio:14/9,split_screen:!1,player_type:"PopcornPlayer",background:"#000000"}),e},Mediafragment=function(t){return class extends t.Widgets.Widget{constructor(e,n){if(super(e,n),this.last_hash_key="",this.last_hash_value="",this.last_extra_key="",this.last_extra_value="",window.onhashchange=this.functionWrapper("goToHash"),typeof window.addEventListener<"u"){var o=this;window.addEventListener("message",function(u){/^#/.test(u.data)&&o.setWindowHash(u.data)})}this.onMdpEvent("Mediafragment.setHashToAnnotation","setHashToAnnotation"),this.blocked=!1}draw(){this.onMediaEvent("setpause","setHashToTime");var e=this;this.getWidgetAnnotations().forEach(function(n){n.on("click",function(){e.setHashToAnnotation(n)})}),this.media.loadedMetadata?this.goToHash():this.onMediaEvent("loadedmetadata","goToHash")}setWindowHash(e){typeof window.history<"u"&&typeof window.history.replaceState<"u"?window.history.replaceState({},"",e):document.location.hash=e}getLastHash(){var e=document.location.hash.replace(/^#/,"").split("&");return e=_$1(e).filter(function(n){return n&&!/^(id|t)=/.test(n)}),this.last_hash_key&&e.push(this.last_hash_key+"="+this.last_hash_value),this.last_extra_key&&e.push(this.last_extra_key+"="+this.last_extra_value),"#"+e.join("&")}goToHash(){if(document.location.hash!==this.getLastHash())for(var e=document.location.hash.replace(/^#/,"").split("&"),n=0;n<e.length;n++){var o=e[n].split("=");if(o[0]=="id"||o[0]=="t"){if(this.last_hash_key=o[0],this.last_hash_value=o[1],this.last_hash_key=="id"){var u=this.source.getElement(this.last_hash_value);if(typeof u<"u")this.media.setCurrentTime(u.begin);else continue}this.last_hash_key=="t"&&this.media.setCurrentTime(1e3*this.last_hash_value);break}}}setHashToAnnotation(e){this.setHash("id",e.id,"t",e.begin/1e3)}setHashToTime(){this.setHash("t",this.media.getCurrentTime().getSeconds())}setHash(e,n,o,u){if(!this.blocked&&(this.last_hash_key!==e||this.last_hash_value!==n)){this.last_hash_key=e,this.last_hash_value=n,this.last_extra_key=o,this.last_extra_value=u;var l=this.getLastHash();this.setWindowHash(l),window.parent!==window&&window.parent.postMessage(l,"*"),this.block()}}unblock(){typeof this.blockTimeout<"u"&&window.clearTimeout(this.blockTimeout),this.blockTimeout=void 0,this.blocked=!1}block(){typeof this.blockTimeout<"u"&&window.clearTimeout(this.blockTimeout),this.blocked=!0,this.blockTimeout=window.setTimeout(this.functionWrapper("unblock"),1500)}}},mediaListStyles={},MediaList=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.lastMedia=!1}onSearch(n){this.searchString=typeof n<"u"?n:"";var o=this.refresh(!0);this.searchString&&(o?this.player.trigger("search.matchFound"):this.player.trigger("search.noMatchFound"))}draw(){this.$.addClass("Ldt-MediaListWidget"),this.renderTemplate();var n=this;typeof this.media.getMedias=="function"&&this.media.on("enter-annotation",function(o){n.redraw(o.getMedia())}),this.redraw()}getSegments(n){var o=this,u=this.$.width()/n.duration.milliseconds;return this.getWidgetAnnotations().filter(function(l){return l.getMedia().id==n.id}).map(function(l){var m=l.type=l.annotation;return{left:u*m.begin,width:u*(m.end-m.begin),color:typeof m.color<"u"&&m.color?m.color:o.default_color}})}redraw(n){if(typeof n<"u"){this.$.find(".Ldt-MediaList-Other h2").html(this.l10n.other_media),this.$.find(".Ldt-MediaList-NowPlaying").show(),this.$.find(".Ldt-MediaList-Now-Thumbnail").attr("src",n.thumbnail||this.default_thumbnail),this.$.find(".Ldt-MediaList-Now-Title a").html(n.title),this.$.find(".Ldt-MediaList-Now-Description").html(n.description);var o=n.url||mustache.render(this.media_url_template,{media:n.id});this.$.find(".Ldt-MediaList-NowContainer a").attr("href",o);var u=mustache.render(this.mediaViewTemplate,{segments:this.getSegments(n)});this.$.find(".Ldt-MediaList-Now-MediaView").html(u)}else this.$.find(".Ldt-MediaList-Other h2").html(this.l10n.all_media),this.$.find(".Ldt-MediaList-NowPlaying").hide();var l=this,m=this.source.getMedias().filter(function(E){return E.id!==l.lastMedia});if(m.length){this.$.find(".Ldt-MediaList-Other").show();var y=m.map(function(E){return mustache.render(l.mediaTemplate,{thumbnail:E.thumbnail||l.default_thumbnail,url:E.url||mustache.render(l.media_url_template,{media:E.id}),title:E.title,description:E.description,segments:l.getSegments(E)})}).join("");this.$.find(".Ldt-MediaList-OtherList").html(y)}else this.$.find(".Ldt-MediaList-Other").hide()}},Fi(e,"messages",{fr:{now_playing:"Vidéo en cours",all_media:"Toutes les vidéos",other_media:"Autres vidéos"},en:{now_playing:"Now playing",all_media:"All videos",other_media:"Other videos"}}),Fi(e,"defaults",{default_thumbnail:"https://ldt.iri.centrepompidou.fr/static/site/ldt/css/imgs/video_sequence.png",media_url_template:"https://ldt.iri.centrepompidou.fr/ldtplatform/ldt/front/player/{{media}}/",default_color:"#000080"}),Fi(e,"template",'<div class="Ldt-MediaList-NowPlaying"><h2>{{l10n.now_playing}}</h2><hr /><div class="Ldt-MediaList-NowContainer"><div class="Ldt-MediaList-Now-ThumbContainer"><a href="" target="_blank"><img class="Ldt-MediaList-Now-Thumbnail" src="" /></a></div><h3 class="Ldt-MediaList-Now-Title"><a href="" target="_blank"></a></h3><p class="Ldt-MediaList-Now-Description"></p><div class="Ldt-MediaList-Now-MediaView"></div></div></div><div class="Ldt-MediaList-Other"><h2></h2><hr /><ul class="Ldt-MediaList-OtherList"></ul></div>'),Fi(e,"mediaViewTemplate",'<div class="Ldt-MediaList-MediaView-Background"></div>{{#segments}}<div class="Ldt-MediaList-Segment" style="background: {{color}}; left: {{left}}px; width: {{width}}px;"></div>{{/segments}}'),Fi(e,"mediaTemplate",'<li class="Ldt-MediaList-OtherList-li"><div class="Ldt-MediaList-Other-ThumbContainer"><a href="{{url}}" target="_blank"><img class="Ldt-MediaList-Other-Thumbnail" src="{{thumbnail}}" /></a></div><h3 class="Ldt-MediaList-Other-Title"><a href="{{url}}" target="_blank">{{title}}</a></h3><p class="Ldt-MediaList-Other-Description">{{description}}</p><div class="Ldt-MediaList-Other-MediaView">'+MediaList.mediaViewTemplate+"</div></li>"),e},noteTakingStyles={},NoteTaking=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){var n=this,o,u=jQuery;n.renderTemplate(),o=n.$.find(".Ldt-NoteTaking-Text");function l(){u(o).val(window.localStorage[n.editable_storage])}function m(){window.localStorage[n.editable_storage]=u(o).val()}window.localStorage[n.editable_storage]&&l(),u.fn.insertAtCaret=function(E){return this.each(function(){if(this.selectionStart!==void 0){var C=this.selectionStart,k=this.selectionEnd,A=this.scrollTop;this.value=this.value.substring(0,C)+E+this.value.substring(k,this.value.length),this.focus(),this.selectionStart=C+E.length,this.selectionEnd=C+E.length,this.scrollTop=A}else this.value+=E,this.focus(),this.value=this.value})};function y(E,C){var k=E.selectionStart;return E.value.substring(k-C,k+C)}u(o).keydown(function(E){if(E.keyCode==13&&(E.ctrlKey||E.metaKey)){E.preventDefault();var C=/\[([\d:]+)\]/.exec(y(o[0],8));C?n.media.setCurrentTime(t.timestamp2ms(C[1])):(u(o).insertAtCaret("["+new t.Model.Time(n.media.getCurrentTime()).toString()+"]"),m())}}).on("input",function(E){m()}).on("dblclick",function(E){var C=/\[([\d:]+)\]/.exec(y(o[0],8));C&&(E.preventDefault(),n.media.setCurrentTime(t.timestamp2ms(C[1])))})}},Fi(e,"defaults",{editable_storage:""}),Fi(e,"template",'<textarea class="Ldt-NoteTaking-Text"></textarea>'),e},placeholderPlayerStyles={},PlaceholderPlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){this.renderTemplate();var n=!0,o=0,u=new t.Model.Time(0),l=this.media,m=this.$.find(".Ldt-PlaceholderPlayer");function y(){n||(u=new t.Model.Time(new Date().valueOf()-o),u<=l.duration?(l.trigger("timeupdate",u),setTimeout(y,100)):(u=l.duration,l.pause())),m.text(u.toString(!0))}l.on("setcurrenttime",function(E){o=new Date().valueOf()-E,u=new t.Model.Time(E),l.trigger("seeked"),l.trigger("timeupdate",u),m.text(u.toString(!0))}),l.on("setplay",function(){n=!1,o=new Date().valueOf()-u,l.trigger("play"),y()}),l.on("setpause",function(){n=!0,l.trigger("pause"),y()}),l.trigger("loadedmetadata"),l.trigger("setcurrenttime",0),this.autostart&&l.trigger("setplay")}},Fi(e,"defaults",{autostart:!1}),Fi(e,"template",'<div class="Ldt-PlaceholderPlayer">(loading)</div>'),e},polemicStyles={},Polemic=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}getPolemics(n){return(typeof n>"u"||!n)&&(n=this.default_version),this.polemics.constructor===Array?this.polemics:this.polemics[n]}drawNoStackgraph(n,o){var u=this;if(this.is_stackgraph=!1,n){let m=function(y,E,j,k,A){var D=mustache.render('<div class="Ldt-Polemic-TweetDiv Ldt-TraceMe" trace-info="annotation-id:{{id}}, media-id:{{media_id}}, polemic:{{polemic}}, time:{{time}}" polemic-color="{{color}}" tweet-title="{{title}}" annotation-id="{{id}}" style="width: {{width}}px; height: {{height}}px; top: {{top}}px; left: {{left}}px; background: {{color}}"></div>',{id:A.id,media_id:u.source.currentMedia.id,polemic:j,left:y,top:E,color:k,width:u.element_width-1,height:u.element_height,title:A.title,time:A.begin.toString()}),P=jQuery(D);P.on("mouseover",function(){A.trigger("select")}).on("mouseout",function(){A.trigger("unselect")}).on("click",function(){return A.trigger("click"),!1}),t.attachDndData(P,{title:A.title,description:A.description,image:A.thumbnail,uri:typeof A.url<"u"?A.url:document.location.href.replace(/#.*$/,"")+"#id="+A.id,text:"["+A.begin.toString()+"] "+A.title});for(var R=[],B=A.content&&A.content.polemic_version||u.default_version,F=u.getPolemics(B)||[],j,N,Y=0;Y<F.length;Y++)j=F[Y],N=t.Model.regexpFromTextOrArray(j.keywords),N.test(A.description)&&R.push(j.color);A.on("select",function(){u.tooltip&&u.tooltip.show(+Math.floor(y+(u.element_width-1)/2),+E,A.title,R.length>1?R:k),u.$tweets.each(function(){var J=jQuery(this);J.css("opacity",J.attr("annotation-id")==A.id?1:.3)})}),A.on("unselect",function(){u.tooltip&&u.tooltip.hide(),u.$tweets.css("opacity",1)}),A.on("found",function(){P.css({background:u.foundcolor,opacity:1})}),A.on("not-found",function(){P.css({background:k,opacity:.3})}),u.$zone.append(P)};this.height=(2+n)*this.element_height,this.$zone.css({width:this.width+"px",height:this.height+"px",position:"relative"});var l=0;_$1(o).forEach(function(y){var E=u.height;y.annotations.forEach(function(C){E-=u.element_height,m(l,E,"none",u.defaultcolor,C)}),_$1(y.polemicStacks).forEach(function(C){var k=C.polemicDef.color,A=C.polemicDef.name;C.annotations.forEach(function(D){E-=u.element_height,m(l,E,A,k,D)})}),l+=u.element_width}),this.$tweets=this.$.find(".Ldt-Polemic-TweetDiv"),this.source.getAnnotations().on("search-cleared",function(){u.$tweets.each(function(){var y=jQuery(this);y.css({background:y.attr("polemic-color"),opacity:1})})})}else this.$zone.hide()}drawStackgraph(n,o){this.is_stackgraph=!0;var u=this;this.height=(2+this.max_elements)*this.element_height,this.$zone.css({width:this.width+"px",height:this.height+"px",position:"relative"});var l=0,m="",y=this.max_elements*this.element_height/n;function E(C,k,A,D,P,R,B,F){m+=mustache.render('<div class="Ldt-Polemic-TweetDiv Ldt-TraceMe" trace-info="annotation-block, media-id={{media_id}}, polemic={{polemic}}, time:{{begin}}" pos-x="{{posx}}" pos-y="{{top}}" annotation-counts="{{nums}}" begin-time="{{begin}}" end-time="{{end}}" style="width: {{width}}px; height: {{height}}px; top: {{top}}px; left: {{left}}px; background: {{color}}"></div>',{nums:P,posx:Math.floor(C+(u.element_width-1)/2),media_id:u.source.currentMedia.id,polemic:F,left:C,top:k,color:D,width:u.element_width-1,height:A,begin:R,end:B})}_$1(o).forEach(function(C){var k=u.height,A=C.annotations.length+"|"+u.defaultcolor+","+_$1(C.polemicStacks).map(function(P){return P.annotations.length+"|"+P.polemicDef.color}).join(",");if(C.annotations.length){var D=Math.ceil(y*C.annotations.length);k-=D,E(l,k,D,u.defaultcolor,A,C.begin,C.end,"none")}_$1(C.polemicStacks).forEach(function(P){if(P.annotations.length){var R=P.polemicDef.color,B=P.polemicDef.name,F=Math.ceil(y*P.annotations.length);k-=F,E(l,k,F,R,A,C.begin,C.end,B)}}),l+=u.element_width}),this.$zone.append(m),this.$tweets=this.$.find(".Ldt-Polemic-TweetDiv"),this.$tweets.mouseover(function(){var C=jQuery(this),k=C.attr("annotation-counts").split(","),A="<p>"+u.l10n.from_+C.attr("begin-time")+u.l10n._to_+C.attr("end-time")+"</p>";A=_$1.reduce(k,function(D,P){var R=P.split("|");return D+='<div class="Ldt-Tooltip-AltColor" style="background: '+R[1]+'"></div><p>'+R[0]+u.l10n._annotations+"</p>",D},A),u.tooltip&&u.tooltip.show(+C.attr("pos-x"),+C.attr("pos-y"),A)}).mouseout(function(){u.tooltip&&u.tooltip.hide()})}draw(){this.onMediaEvent("timeupdate","onTimeupdate"),this.$zone=jQuery("<div>"),this.$zone.addClass("Ldt-Polemic"),this.$.append(this.$zone),this.$elapsed=jQuery("<div>").css({background:"#cccccc",position:"absolute",top:0,left:0,width:0,height:"100%"}),this.$zone.append(this.$elapsed);for(var n=[],o=Math.floor(this.width/this.element_width),u=this.source.getDuration(),l=0,m=this.getWidgetAnnotations(),y=this,E=0;E<o;E++){var C=new t.Model.Time(E*u/o),k=new t.Model.Time((E+1)*u/o),A=0,D={begin:C.toString(),end:k.toString(),annotations:m.filter(function(P){return P.begin>=C&&P.begin<k}),polemicStacks:{}};D.annotations=D.annotations.filter(function(P){for(var R=P.content&&P.content.polemic_version||y.default_version,B=y.getPolemics(R)||[],F,j,N,Y,J=!0,ie=0;ie<B.length;ie++)F=B[ie],Y=t.Model.regexpFromTextOrArray(F.keywords),Y.test(P.description)&&(j=R+"_"+F.name,N=D.polemicStacks[j]||(D.polemicStacks[j]={polemicDef:F,annotations:[]}),N.annotations.push(P),J=!1,A++);return J}),A+=D.annotations.length,l=Math.max(l,A),n.push(D)}l<this.max_elements?this.drawNoStackgraph(l,n):this.drawStackgraph(l,n),this.$position=jQuery("<div>").addClass("Ldt-Polemic-Position"),this.$zone.append(this.$position),this.$zone.on("click",function(P){var R=P.pageX-y.$zone.offset().left;y.media.setCurrentTime(y.media.duration*R/y.width)}),this.$.append('<div class="Ldt-Polemic-Tooltip"></div>'),this.insertSubwidget(this.$.find(".Ldt-Polemic-Tooltip"),{type:"Tooltip",min_x:0,max_x:this.width},"tooltip")}onTimeupdate(n){var o=Math.floor(this.width*n/this.media.duration);this.$elapsed.css({width:o+"px"}),this.$position.css({left:o+"px"})}},Fi(e,"messages",{fr:{from_:"de ",_to_:" à ",_annotations:" annotation(s)"},en:{from_:"from ",_to_:" to ",_annotations:" annotation(s)"}}),Fi(e,"defaults",{element_width:5,element_height:5,max_elements:20,annotation_type:"tweet",defaultcolor:"#585858",foundcolor:"#fc00ff",default_version:"1",polemics:{1:[{name:"OK",keywords:["++"],color:"#1D973D"},{name:"KO",keywords:["--"],color:"#CE0A15"},{name:"REF",keywords:["==","http://"],color:"#C5A62D"},{name:"Q",keywords:["?"],color:"#036AAE"}],2:[{name:"OK",keywords:["++"],color:"#1D973D"},{name:"KO",keywords:["!!"],color:"#CE0A15"},{name:"REF",keywords:["==","http://"],color:"#C5A62D"},{name:"Q",keywords:["?"],color:"#036AAE"}]}}),e},PopcornPlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){typeof this.video>"u"&&(this.video=this.media.video),this.url_transform&&(this.video=this.url_transform(this.video));var n=this.video;if(/^(https?:\/\/)?(www\.)?youtube\.com/.test(this.video)){for(var o=this.video.split(/[?&]/),u={},l=1;l<o.length;l++){var m=o[l].split("=");u[m[0]]=decodeURIComponent(m[1])}u.controls=0,u.modestbranding=1,(this.autostart||this.autoplay)&&(u.autoplay=1),n=o[0]+"?"+jQuery.param(u)}var y=global$1.Popcorn.smart("#"+this.container,n);(this.autostart||this.autoplay)&&y.autoplay(!0);var E=this.media;E.on("setcurrenttime",function(k){y.currentTime(k/1e3)}),E.on("setvolume",function(k){y.volume(k),E.volume=k}),E.on("setmuted",function(k){y.muted(k),E.muted=k}),E.on("setplay",function(){y.play()}),E.on("setpause",function(){y.pause()}),E.on("settimerange",function(k){E.timeRange=k;try{(E.getCurrentTime()>k[0]||E.getCurrentTime()<k)&&y.currentTime(k[0]/1e3)}catch{}}),E.on("resettimerange",function(){E.timeRange=!1});function C(){E.muted=y.muted(),E.volume=y.volume()}y.on("loadedmetadata",function(){C(),E.trigger("loadedmetadata"),E.trigger("volumechange")}),y.on("timeupdate",function(){E.trigger("timeupdate",new t.Model.Time(1e3*y.currentTime()))}),y.on("volumechange",function(){C(),E.trigger("volumechange")}),y.on("play",function(k){E.trigger("play")}),y.on("pause",function(){E.trigger("pause")}),y.on("seeked",function(){E.trigger("seeked")})}},Fi(e,"defaults",{}),e},quizStyles={},Quiz=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}update(n){var o=this;if(this.quiz_activated&&this.correct[n.id]!=1&&this.correct[n.id]!=0){o.quiz_displayed=!0,this.media.pause(),this.annotation=n;var u=n.content.data.question,l=n.content.data.answers,m=n.content.data.resource;jQuery(".Ldt-Quiz-Votes").hide(),jQuery(".Ldt-Pause-Add-Question").hide(),jQuery(".Ldt-Quiz-Container .Ldt-Quiz-Title").html(u);var y=0,E=mustache.render('<span class="Ldt-Quiz-Correct-Answer">{{ correctness.0 }}</span> / <span class="Ldt-Quiz-Incorrect-Answer">{{ correctness.1 }}</span>',{correctness:this.globalScore()});jQuery(".Ldt-Quiz-Index").html(mustache.render("Q{{index}}/{{total}}",{index:n.number+1,total:this.totalAmount})),jQuery(".Ldt-Quiz-Score").html(E),this.question=new t.Widgets.UniqueChoiceQuestion(n),this.resource=new t.Widgets.UniqueChoiceQuestion(m),n.content.data.type=="multiple_choice"?(this.question=new t.Widgets.MultipleChoiceQuestion(n),this.resource=new t.Widgets.MultipleChoiceQuestion(m)):n.content.data.type=="unique_choice"&&(this.question=new t.Widgets.UniqueChoiceQuestion(n),this.resource=new t.Widgets.UniqueChoiceQuestion(m));var C="";for(y=0;y<l.length;y++)C+='<div class="quiz-question-block"><p>'+this.question.renderQuizTemplate(l[y],y)+'<span class="quiz-question-label">'+l[y].content+"</span></p></div>";var k="";m!=null&&(k='<div class="quiz-resource-block" id="resource" >'+m+"</div>"),jQuery(".Ldt-Quiz-Questions").html(k+C),jQuery(".Ldt-Quiz-Overlay").fadeIn(),jQuery(".Ldt-Quiz-Submit").fadeIn(),jQuery(".quiz-question-label").click(function(){var A=jQuery(this).siblings("input");A.prop("checked")&&A.prop("type")=="radio"?o.answer():A.prop("checked",!A.prop("checked"))}),jQuery(".Ldt-Quiz-Submit-Skip-Link").click({media:this.media},function(A){o.hide(),o.player.trigger("QuizCreator.skip"),A.data.media.play()})}}hide(){var n=this;jQuery(".Ldt-Quiz-Votes").hide(),jQuery(".Ldt-Quiz-Overlay").hide(),jQuery(".Ldt-Pause-Add-Question").hide(),n.quiz_displayed=!1}answer(){var n=this;function o(A){return(A||"").replace(/\s(\d+:\d+)/,function(D,P){return' <a href="#t='+t.timestamp2ms(P)/1e3+'">'+P+"</a>"})}var u=n.annotation.content.data.answers,l=0,m=0,y=[];n.$.find(".Ldt-Quiz-Question-Check").each(function(A){var D=jQuery(this).is(":checked");y.push(D?1:0);var P=u[l];P.correct&&!D||!P.correct&&D?(m+=1,jQuery(this).parents(".quiz-question-block").append('<div class="quiz-question-feedback quiz-question-incorrect-feedback">'+o(P.feedback)+"</div>")):jQuery(this).parents(".quiz-question-block").append('<div class="quiz-question-feedback quiz-question-correct-feedback">'+o(P.feedback)+"</div>"),l++}),m?(jQuery(".Ldt-Quiz-Result").html("Mauvaise réponse"),jQuery(".Ldt-Quiz-Result").css({"background-color":"red"}),this.correct[this.annotation.id]=0):(jQuery(".Ldt-Quiz-Result").html("Bonne réponse !"),jQuery(".Ldt-Quiz-Result").css({"background-color":"green"}),this.correct[this.annotation.id]=1),jQuery(".Ldt-Quiz-Result").animate({height:"100%"},500,"linear",function(){jQuery(".Ldt-Quiz-Result").delay(2e3).animate({height:"0%"},500)});var E=this.annotation.number+1,C=this.globalScore(),k="";k+='<span class="Ldt-Quiz-Correct-Answer">'+C[0]+'</span> / <span class="Ldt-Quiz-Incorrect-Answer">'+C[1]+"</span>",jQuery(".Ldt-Quiz-Index").html("Q"+E+"/"+this.totalAmount),jQuery(".Ldt-Quiz-Score").html(k),this.submit(this.user,this.userid,this.annotation.id,m?"wrong_answer":"right_answer",y.join("")),jQuery(".Ldt-Quiz-Submit").fadeOut(400,function(){jQuery(".Ldt-Quiz-Votes").show()})}globalScore(){var n=_.values(this.correct),o=n.filter(function(l){return l==1}).length,u=n.filter(function(l){return l==0}).length;return[o,u]}refresh(){var n=this.getWidgetAnnotations().sortBy(function(u){return u.begin}),o=this;o.totalAmount=n.length,o.number=0,o.correct={},o.keys={},n.forEach(function(u){o.correct[u.id]=-1,o.keys[o.number]=u.id,u.number=o.number++})}draw(){var n=this;n.quiz_displayed=!1,this.onMediaEvent("enter-annotation",function(o){var u=n.getWidgetAnnotations().filter(function(l){return l===o});u.number===void 0&&n.refresh(),u.length&&n.update(u[0])}),this.onMdpEvent("Quiz.activate",function(){n.quiz_activated=!0}),this.onMdpEvent("Quiz.deactivate",function(){n.quiz_activated=!1,n.hide()}),this.onMdpEvent("Quiz.hide",function(){n.hide()}),this.onMdpEvent("Quiz.refresh",function(){n.refresh()}),this.onMediaEvent("pause",function(){n.quiz_displayed||jQuery(".Ldt-Pause-Add-Question").show()}),this.onMediaEvent("play",function(){jQuery(".Ldt-Pause-Add-Question").hide()}),n.overlay=jQuery("<div class='Ldt-Quiz-Overlay'></div>").appendTo(jQuery("#"+n.container)),n.PauseAddQuestion=jQuery("<div class='Ldt-Pause-Add-Question' title='Ajoutez une question !'>").on("click",function(){n.player.trigger("QuizCreator.create")}).appendTo(jQuery("#"+n.container)),n.overlay.html(this.template),jQuery(".Ldt-Quiz-Overlay").hide(),jQuery(".Ldt-Quiz-Submit input").click(function(){n.answer()}),jQuery(".Ldt-Quiz-Submit-Skip-Link").click({media:this.media},function(o){n.submit(n.user,n.userid,n.annotation.id,"skipped_answer",0),n.hide(),n.player.trigger("QuizCreator.skip"),o.data.media.play()}),jQuery('.Ldt-Quiz-Votes-Buttons input[type="button"], .Ldt-Quiz-Votes-Buttons a').click({media:this.media},function(o){var u,l;jQuery(this).hasClass("Ldt-Quiz-Vote-Useful")?(u="useful",l=1):jQuery(this).hasClass("Ldt-Quiz-Vote-Useless")?(u="useless",l=-1,jQuery(".Ldt-Ctrl-Quiz-Create").addClass("button_highlight").delay(5e3).queue(function(){jQuery(this).removeClass("button_highlight").dequeue()})):(u="skipped_vote",l=0),n.submit(n.user,n.userid,n.annotation.id,u,l),o.data.media.play(),n.hide(),jQuery(".Ldt-Pause-Add-Question").hide(),n.player.trigger("QuizCreator.skip")}),n.refresh()}},Fi(e,"defaults",{quiz_activated:!0,api_serializer:"ldt_annotate",analytics_api:"",api_method:"POST",user:"",userid:""}),Fi(e,"template",'<div class="Ldt-Quiz-Container"><div class="Ldt-Quiz-Header">  <div class="Ldt-Quiz-Index"></div><div class="Ldt-Quiz-Score"></div></div><div class="Ldt-Quiz-Content">  <h1 class="Ldt-Quiz-Title">{{question}}</h1>  <div class="Ldt-Quiz-Questions">  </div></div><div class="Ldt-Quiz-Footer">  <div class="Ldt-Quiz-Votes">      <span class="Ldt-Quiz-Votes-Question">Avez-vous trouvé cette question utile ?</span>      <div class="Ldt-Quiz-Votes-Buttons">          <div class="Ldt-Quiz-Vote-Skip-Block"><a href="#" class="Ldt-Quiz-Vote-Skip">Passer</a></div>          <div><input type="button" value="Non" class="Ldt-Quiz-Vote-Useless" /></div>          <div><input type="button" value="Oui" class="Ldt-Quiz-Vote-Useful" /></div>      </div>  </div>  <div class="Ldt-Quiz-Submit">      <div class="Ldt-Quiz-Submit-Button"><input type="button" value="Valider" /></div>      <div class="Ldt-Quiz-Submit-Skip-Link"><a href="#">Passer</a></div><div style="clear:both;"></div>  </div>  <div class="Ldt-Quiz-Result">Bonne réponse</div></div></div>'),Fi(e,"annotationTemplate",""),e},UniqueChoiceQuestion=function(t){return class extends t.Widgets.Widget{constructor(e){this.annotation=e}renderQuizTemplate(e,n){return'<input type="radio" class="quiz-question Ldt-Quiz-Question-Check Ldt-Quiz-Question-Check-'+n+'" name="question" data-question="'+n+'" value="'+n+'" />'}renderTemplate(e,n){var o=this.generateUid();return'<input type="radio" id="'+o+'" class="quiz-question-edition Ldt-Quiz-Question-Check Ldt-Quiz-Question-Check-'+n+'" name="question" data-question="'+n+'" value="'+n+'" /><label for="'+o+'" title="Veuillez sélectionner la réponse correcte"></label>'}renderFullTemplate(e,n){var o=e&&e.correct?"checked":"",u=this.generateUid();return'<input type="radio" id="'+u+'" '+o+' class="quiz-question-edition Ldt-Quiz-Question-Check Ldt-Quiz-Question-Check-'+n+'" name="question" data-question="'+n+'" value="'+n+'" /><label for="'+u+'"></label>'}}},MultipleChoiceQuestion=function(t){return class extends t.Widgets.Widget{constructor(e){this.annotation=e}renderQuizTemplate(e,n){return'<input type="checkbox" class="quiz-question Ldt-Quiz-Question-Check Ldt-Quiz-Question-Check-'+n+'" name="question['+n+']" data-question="'+n+'" value="'+n+'" /> '}renderTemplate(e,n){var o=this.generateUid();return'<input type="checkbox" id="'+o+'" class="quiz-question-edition Ldt-Quiz-Question-Check" name="question['+n+']" data-question="'+n+'" value="'+n+'" /><label for="'+o+'" title="Veuillez sélectionner la ou les réponses correctes"></label>'}renderFullTemplate(e,n){var o=e&&e.correct?"checked":"",u=this.generateUid();return'<input type="checkbox" id="'+u+'" '+o+' class="quiz-question-edition Ldt-Quiz-Question-Check" name="question['+n+']" data-question="'+n+'" value="'+n+'" /><label for="'+u+'"></label> '}submit(e,n,o,u,l){var m=this,y=mustache.render(this.analytics_api,{id:this.source.projectId}),E={username:e,useruuid:n,subject:o,property:u,value:l,session:m.session_id};jQuery.ajax({url:y,type:this.api_method,contentType:"application/json",data:JSON.stringify(E),success:function(C){},error:function(C,k,A){t.log("Error when sending annotation",A)}})}}},quizCreatorStyles={},QuizCreator=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}skip(){this.$.find(".Ldt-QuizCreator-Time").val(""),this.$.find(".Ldt-QuizCreator-Question-Area").val(""),this.$.find(".Ldt-QuizCreator-Resource-Area").val(""),this.$.find(".Ldt-QuizCreator-Questions-Block").html(""),this.current_annotation=void 0}nbAnswers(){var n=this.$.find(".Ldt-QuizCreator-Questions-Answer").length;return n}draw(){var n=this;this.onMediaEvent("timeupdate",function(o){n.setBegin(o)}),this.onMdpEvent("QuizCreator.show",function(){n.setBegin(n.media.currentTime)}),this.onMdpEvent("QuizCreator.create",function(){n.skip(),n.setBegin(n.media.currentTime)}),this.onMdpEvent("QuizCreator.skip",function(){n.skip()}),this.onMdpEvent("QuizCreator.edit",function(o){n.skip(),n.addQuestion(o)}),this.$.on("click",".Ldt-QuizCreator-Remove",function(){jQuery(this).parents(".Ldt-QuizCreator-Questions-Answer").remove()}),this.begin=new t.Model.Time,this.end=this.source.getDuration(),this.answers=[],this.renderTemplate(),this.question=new t.Widgets.UniqueChoiceQuestion,this.$.find(".Ldt-QuizCreator-Question-Type").bind("change",this.functionWrapper("onQuestionTypeChange")),this.$.find(".Ldt-QuizCreator-Question-Add").bind("click",this.functionWrapper("onQuestionAdd")),this.$.find(".Ldt-QuizCreator-Question-Save").bind("click",this.functionWrapper("onSave")),this.$.find(".Ldt-QuizCreator-Time").keyup(function(){var o=n.$.find(".Ldt-QuizCreator-Time").val();n.begin=t.timestamp2ms(o),n.end=n.begin+1e3}),this.onMediaEvent("timeupdate",function(o){n.getDescription()&&n.setBegin(o)})}getDescription(){return this.$.find(".Ldt-QuizCreator-Question-Area").val().trim()}addQuestion(n,o){var u=this;n.content.data.type=="multiple_choice"?this.question=new t.Widgets.MultipleChoiceQuestion(n):n.content.data.type=="unique_choice"&&(this.question=new t.Widgets.UniqueChoiceQuestion(n));var l=n.content.data.answers;this.answers=[],this.$.find(".Ldt-QuizCreator-Time").val(n.begin),this.$.find(".Ldt-QuizCreator-Question-Area").val(n.content.data.question),this.$.find(".Ldt-QuizCreator-Resource-Area").val(n.content.data.resource),this.$.find(".Ldt-QuizCreator-Questions-Block").html(""),l.forEach(function(m){u.onQuestionAdd(null,m)}),u.current_annotation=n}onQuestionTypeChange(n){var o=this.$.find(".Ldt-QuizCreator-Question-Type"),u=o.val(),l=this;switch(u){case"unique_choice":this.question=new t.Widgets.UniqueChoiceQuestion;break;case"multiple_choice":this.question=new t.Widgets.MultipleChoiceQuestion;break}var m="";l.$.find(".Ldt-QuizCreator-Questions-Block").html(m),this.pauseOnWrite()}onQuestionAdd(n,o){var u='<div class="Ldt-QuizCreator-Questions-Answer">Réponse <div class="Ldt-QuizCreator-Questions-Answer-Correct">'+this.question.renderFullTemplate(o,this.nbAnswers())+'</div><br /><div class="Ldt-QuizCreator-Questions-Answer-Content"><input type="text" class="Ldt-QuizCreator-Answer-Content" data-question="'+this.nbAnswers()+'" id="question'+this.nbAnswers()+'"'+(o?' value="'+o.content+'"':"")+'/><br />Commentaire <br/><textarea class="Ldt-QuizCreator-Answer-Feedback" data-question="'+this.nbAnswers()+'" id="feedback'+this.nbAnswers()+'">'+(o?o.feedback:"")+'</textarea></div><div class="Ldt-QuizCreator-Questions-Answer-Delete"><div class="Ldt-QuizCreator-Remove">&nbsp;</div></div></div>';this.$.find(".Ldt-QuizCreator-Questions-Block").append(u),this.$.find(".Ldt-QuizCreator-Answer-Content").last().focus(),this.pauseOnWrite()}pauseOnWrite(){this.pause_on_write&&!this.media.getPaused()&&this.media.pause()}setBegin(n){this.begin=new t.Model.Time(n||0),this.end=this.begin+500,this.$.find(".Ldt-QuizCreator-Time").val(this.begin.toString())}get_local_annotation(n){return this.player.getLocalAnnotation(n)}save_local_annotations(){this.player.saveLocalAnnotations(),this.source.merge(this.player.localSource)}delete_local_annotation(n){this.source.getAnnotations().removeId(n),this.player.deleteLocalAnnotation(n),this.current_annotation=void 0,this.refresh(!0)}show(){this.$.find(".Ldt-QuizCreator-Question-Area").focus()}hide(){this.$.find(".Ldt-QuizCreator-Questions-Block").html(""),this.$.find(".Ldt-QuizCreator-Question-Area").val(""),this.$.find(".Ldt-QuizCreator-Resource-Area").val(""),this.$.find(".Ldt-QuizCreator-Time").val("")}onSave(n,o){var u=!1;if(this.nbAnswers()<=0)return alert("Vous devez spécifier au moins une réponse à votre question !"),!1;if(!this.$.find(".quiz-question-edition:checked").length)return alert("Vous n'avez pas indiqué de bonne réponse."),!1;var l;if(this.current_annotation)u=!1,l=this.current_annotation;else{u=!0;var m=this.source.getAnnotationTypes().searchByTitle(this.annotation_type,!0),y=m.length?m[0]:new t.Model.AnnotationType(!1,this.player.localSource);m.length||(y.dont_send_id=!0,y.title=this.annotation_type),l=new t.Model.Annotation(!1,this.player.localSource),l.created=new Date,l.creator=this.creator_name,l.setAnnotationType(y.id),this.player.localSource.getMedias().push(this.source.currentMedia),l.setMedia(this.source.currentMedia.id)}l.setBeginEnd(this.begin,this.end),l.modified=new Date,l.contributor=this.creator_name,l.description=this.getDescription(),l.title=l.description,l.content={},l.content.data={},l.content.data.type=this.$.find(".Ldt-QuizCreator-Question-Type").val(),l.content.data.question=l.description,l.content.data.resource=this.$.find(".Ldt-QuizCreator-Resource-Area").val(),l.content.data.answers=jQuery.makeArray(jQuery(".Ldt-QuizCreator-Questions-Answer").map(function(E){return{content:jQuery(this).find(".Ldt-QuizCreator-Answer-Content").val(),feedback:jQuery(this).find(".Ldt-QuizCreator-Answer-Feedback").val(),correct:jQuery(this).find(".Ldt-Quiz-Question-Check").is(":checked")}})),this.current_annotation=l,u?(this.player.addLocalAnnotation(l),this.source.merge([l]),this.player.trigger("Annotation.create",l)):(this.player.saveLocalAnnotations(),this.player.trigger("Annotation.update",l)),this.player.trigger("AnnotationsList.update"),this.player.trigger("Quiz.refresh")}},Fi(e,"defaults",{creator_name:"",tags:!1,tag_titles:!1,pause_on_write:!0,annotation_type:"Quiz",api_serializer:"ldt_annotate",api_endpoint_template:"",api_method:"POST"}),Fi(e,"messages",{en:{},fr:{}}),Fi(e,"template",'<div class="Ldt-QuizCreator-Ui Ldt-TraceMe"><div class="Ldt-QuizCreator-Question-Form"><textarea class="Ldt-QuizCreator-Question-Area" placeholder="Votre question"></textarea><br /><textarea class="Ldt-QuizCreator-Resource-Area" placeholder="Ressources (lien vers une image, etc.)"></textarea><br /></div><p>Type de question  <select name="type" class="Ldt-QuizCreator-Question-Type"><option value="unique_choice">Choix unique</option><option value="multiple_choice">Choix multiple</option></select> à <input type="text" placeholder="hh:mm:ss" size="6" class="Ldt-QuizCreator-Time" /><div class="Ldt-QuizCreator-Questions-Block"></div><div>  <button class="Ldt-QuizCreator-Question-Add">Ajouter une réponse</button><hr>  <button class="Ldt-QuizCreator-Question-Save">Sauvegarder</button></div></div>'),e},segmentsStyles={},Segments=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}do_draw(n){this.width!=this.$.parent().width()&&this.scale_to_parent&&(this.width=this.$.parent().width(),this.$.css({width:this.width+"px"}));var o=this,u=this.getWidgetAnnotations().filter(function(k){return k.getDuration()>0&&k.getMedia().id==o.media.id}),l=this.width/this.source.getDuration(),m=this.$.find(".Ldt-Segments-List"),y=[],E=1;function C(k,A,D,P){function R(F){return Math.floor(240*(1-P)+F*P)}for(var B=(65536*R(k)+256*R(A)+R(D)).toString(16);B.length<6;)B="0"+B;return"#"+B}n&&this.$.find(".Ldt-Segments-Segment").remove(),u.forEach(function(k,A){var D=k.begin*l,P=k.getDuration()*l,R=Math.floor(D+P/2),B=k.title+(k.description?"<br/>"+k.description:""),F=_$1(y).find(function(L){return!_$1(L.annotations).find(function(d){return d.begin<k.end&&d.end>k.begin})});F||(F={index:y.length,annotations:[]},y.push(F)),F.annotations.push(k);var j=(1-o.overlap)*F.index*o.line_height,N=typeof k.color<"u"&&k.color?k.color:o.colors[A%o.colors.length],Y=parseInt(N.substr(1,2),16),J=parseInt(N.substr(3,2),16),ie=parseInt(N.substr(5,2),16),ue=C(Y,J,ie,.5),Q=C(Y,J,ie,.2),ce={color:N,medcolor:ue,lowcolor:Q,text:(k.creator?k.creator+" : ":"")+B.replace(/(\n|\r|\r\n)/gm," ").replace(/(^.{120,140})[\s].+$/m,"$1&hellip;"),left:D,width:P,top:j,height:o.line_height-1,id:k.id,media_id:k.getMedia().id,from:k.begin.toString(),to:k.end.toString()},he=mustache.render(o.constructor.annotationTemplate,ce),ke=jQuery(he);ke.on("mouseover",function(){k.trigger("select")}).on("mouseout",function(){k.trigger("unselect")}).on("click",function(){o.use_timerange&&(o.media.getTimeRange()?o.media.getTimeRange()[0]==k.begin||o.media.getTimeRange()[1]==k.end?(o.media.resetTimeRange(),o.$segments.each(function(){var L=jQuery(this);L.css("background",Q).removeClass("selected"),k.trigger("select")})):(o.media.setCurrentTime(k.begin),o.media.setTimeRange(k.begin,k.end),o.media.play(),o.$segments.each(function(){var L=jQuery(this);L.css("background",Q).removeClass("selected")}),ke.css("background",o.selected_color).addClass("selected")):(o.media.setCurrentTime(k.begin),o.media.setTimeRange(k.begin,k.end),o.media.play(),o.$segments.each(function(){var L=jQuery(this);L.css("background",Q).removeClass("selected")}),ke.css("background",o.selected_color).addClass("selected"))),k.trigger("click")}).appendTo(m),t.attachDndData(ke,{title:k.title,description:k.description,uri:typeof k.url<"u"?k.url:document.location.href.replace(/#.*$/,"")+"#id="+k.id,image:k.thumbnail,text:"["+k.begin.toString()+"] "+k.title}),k.on("select",function(){o.$segments.each(function(){var L=jQuery(this);L.css({background:L.hasClass("found")?o.faded_found_color:L.attr("data-low-color")}),L.css({background:L.hasClass("selected")?o.faded_selected_color:L.attr("data-low-color")})}),ke.css({background:ke.hasClass("found")?o.found_color:N,background:ke.hasClass("selected")?o.selected_color:N,"z-index":++E}),o.tooltip&&o.tooltip.show(R,j,ce.text,ce.color)}),k.on("unselect",function(){o.tooltip&&o.tooltip.hide(),o.$segments.each(function(){var L=jQuery(this);L.css("background",L.hasClass("found")?o.found_color:L.attr("data-medium-color")),L.css("background",L.hasClass("selected")?o.selected_color:L.attr("data-medium-color"))})}),k.on("found",function(){ke.css("background",o.found_color).addClass("found")}),k.on("not-found",function(){ke.css("background",Q).removeClass("found")})}),this.onMediaEvent("resettimerange",function(){o.$segments.each(function(){var k=jQuery(this);k.removeClass("selected")})}),this.$.css({width:this.width+"px",height:((1-this.overlap)*y.length+this.overlap)*this.line_height+"px",background:this.background,margin:"1px 0"}),this.$segments=this.$.find(".Ldt-Segments-Segment")}draw(){var n=this;n.onMediaEvent("timeupdate","onTimeupdate"),n.renderTemplate(),n.do_draw(),this.no_tooltip||n.insertSubwidget(n.$.find(".Ldt-Segments-Tooltip"),{type:"Tooltip",min_x:0,max_x:this.width},"tooltip"),n.source.getAnnotations().on("search",function(){searching=!0}),n.source.getAnnotations().on("search-cleared",function(){searching=!1,_this.$segments.each(function(){var o=jQuery(this);o.css("background",o.attr("data-medium-color")).removeClass("found")})}),this.$.on("resize",function(){n.do_draw(!0)})}onTimeupdate(n){var o=Math.floor(this.width*n/this.media.duration);this.$.find(".Ldt-Segments-Position").css({left:o+"px"})}},Fi(e,"defaults",{annotation_type:"chap",colors:["#1f77b4","#aec7e8","#ff7f0e","#ffbb78","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5","#8c564b","#c49c94","#e377c2","#f7b6d2","#7f7f7f","#c7c7c7","#bcbd22","#dbdb8d","#17becf","#9edae5"],line_height:8,background:"#e0e0e0",overlap:.25,found_color:"#FF00FC",faded_found_color:"#ff80fc",selected_color:"#74d600",faded_selected_color:"#baf9b5",no_tooltip:!1,use_timerange:!1,scale_to_parent:!0}),Fi(e,"template",'<div class="Ldt-Segments-List"></div><div class="Ldt-Segments-Position"></div><div class="Ldt-Segments-Tooltip"></div>'),Fi(e,"annotationTemplate",'<div class="Ldt-Segments-Segment Ldt-TraceMe" trace-info="segment-id:{{id}}, media-id:{{media_id}}, from:{{from}}, to:{{to}}" segment-text="{{text}}"style="top:{{top}}px; height:{{height}}px; left:{{left}}px; width:{{width}}px; background:{{medcolor}}" data-base-color="{{color}}" data-low-color="{{lowcolor}}" data-medium-color="{{medcolor}}"></div>'),e},shortcutsStyles={},Shortcuts=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){var n=this;Mousetrap.bindGlobal("ctrl+space",function(o){return o.preventDefault(),n.media.getPaused()?n.media.play():n.media.pause(),!1}),Mousetrap.bindGlobal("ctrl+left",function(o){return o.preventDefault(),n.media.setCurrentTime(Math.max(0,n.media.getCurrentTime()-n.time_increment)),!1}),Mousetrap.bindGlobal("ctrl+shift+left",function(o){return o.preventDefault(),n.media.setCurrentTime(Math.max(0,n.media.getCurrentTime()-5*n.time_increment)),!1}),Mousetrap.bindGlobal("ctrl+right",function(o){return o.preventDefault(),n.media.setCurrentTime(Math.min(n.media.duration,n.media.getCurrentTime()+n.time_increment)),!1}),Mousetrap.bindGlobal("ctrl+shift+right",function(o){return o.preventDefault(),n.media.setCurrentTime(Math.min(n.media.duration,n.media.getCurrentTime()+5*n.time_increment)),!1}),Mousetrap.bindGlobal("ctrl+a",function(o){return o.preventDefault(),n.player.trigger("CreateAnnotation.toggle"),!1})}},Fi(e,"defaults",{time_increment:2e3}),e},sliceStyles={},Slice=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.sliding=!1}draw(){this.renderTemplate(),this.$slider=this.$.find(".Ldt-Slice"),this.show_arrow&&this.insertSubwidget(this.$.find(".Ldt-Slice-Arrow"),{type:"Arrow"},"arrow"),this.min=0,this.max=this.media.duration.valueOf();var n=this,o;this.$slider.slider({range:!0,values:[0,this.max],min:0,max:this.max,change:function(u,l){n.arrow&&n.arrow.moveToTime((l.values[0]+l.values[1])/2),n.onBoundsChanged&&n.onBoundsChanged(l.values[0],l.values[1])},start:function(){n.sliding=!0,n.media.getPaused()||n.media.pause(),o=n.media.getCurrentTime()},slide:function(u,l){n.media.setCurrentTime(l.value)},stop:function(){n.sliding=!1,n.media.setCurrentTime(o)}}),this.$slider.find(".ui-slider-handle:first").addClass("Ldt-Slice-left-handle"),this.$slider.find(".ui-slider-handle:last").addClass("Ldt-Slice-right-handle"),this.getWidgetAnnotations().forEach(function(u){u.on("enter",function(){n.setBounds(u.begin,u.end)})}),this.player.on("annotation-click",function(u){n.setBounds(u.begin,u.end)})}setBounds(n,o){this.$slider.slider("values",[n,o])}show(){this.$slider.show()}hide(){this.$slider.hide()}},Fi(e,"defaults",{show_arrow:!1}),Fi(e,"template",'<div class="Ldt-Slice"></div>{{#show_arrow}}<div class="Ldt-Slice-Arrow"></div>{{/show_arrow}}'),e},slidePreviewStyles={},SlidePreview=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){this.getWidgetAnnotations().sortBy(function(u){return u.begin});var n=this;n.renderTemplate();var o=n.$.find(".Ldt-SlidePreview-Slides");this.getWidgetAnnotations().forEach(function(u){var l={id:u.id,content:t.textFieldHtml(u.title),begin:u.begin.toString(),ms:u.begin.milliseconds,thumbnail:u.thumbnail},m=mustache.render(n.annotationTemplate,l),y=jQuery(m);o.append(y)}),n.$.on("click",".Ldt-SlidePreview-Item",function(){n.media.setCurrentTime(Number(this.dataset.timecode))})}},Fi(e,"defaults",{annotation_type:"Slides"}),Fi(e,"template",'<div class="Ldt-SlidePreview-Container"><div class="Ldt-SlidePreview-Slides"></div></div>'),Fi(e,"annotationTemplate",'<div data-id="{{ id }}" data-timecode="{{ ms }}" class="Ldt-SlidePreview-Item"><img title="{{ begin }} - {{ atitle }}" class="Ldt-AnnotationsList-Thumbnail" src="{{ thumbnail }}"></div>'),e},sliderStyles={},Slider=function(t){var e;return e=class extends t.Widgets.Widget{constructor(o,u){super(o,u);Fi(this,"calculateHandleCss",function(o){return{height:2+o+"px",width:2+o+"px","margin-left":-Math.ceil(2+o/2)+"px"}})}draw(){this.renderTemplate(),this.$time=this.$.find(".Ldt-Slider-Time"),this.$slider=this.$.find(".Ldt-Slider");var o=this;this.$slider.slider({range:"min",value:0,min:0,max:this.source.getDuration().milliseconds,slide:function(u,l){o.media.setCurrentTime(l.value),o.player.trigger("Mediafragment.setHashToTime")}}),this.$handle=this.$slider.find(".ui-slider-handle"),this.onMediaEvent("timeupdate","onTimeupdate"),this.onMdpEvent("Player.MouseOver","onMouseover"),this.onMdpEvent("Player.MouseOut","onMouseout"),this.minimize_timeout&&(this.$slider.css(this.calculateSliderCss(this.minimized_height)),this.$handle.css(this.calculateHandleCss(this.minimized_height)),this.maximized=!1,this.timeoutId=!1),this.$slider.mouseover(function(){o.$time.show(),o.onMouseover()}).mouseout(this.functionWrapper("onMouseout")).mousemove(function(u){var l=u.pageX-o.$.offset().left,m=new t.Model.Time(o.media.duration*l/o.width);o.$time.text(m.toString()).css("left",l)})}onTimeupdate(o){this.$slider.slider("value",o),this.player.trigger("Arrow.updatePosition",{widget:this.type,time:o})}onMouseover(){this.minimize_timeout&&(this.timeoutId&&(window.clearTimeout(this.timeoutId),this.timeoutId=!1),this.maximized||(this.animateToHeight(this.maximized_height),this.maximized=!0))}onMouseout(){if(this.$time.hide(),this.minimize_timeout){this.timeoutId&&(window.clearTimeout(this.timeoutId),this.timeoutId=!1);var o=this;this.timeoutId=window.setTimeout(function(){o.maximized&&(o.animateToHeight(o.minimized_height),o.maximized=!1),o.timeoutId=!1},this.minimize_timeout)}}animateToHeight(o){this.$slider.stop().animate(this.calculateSliderCss(o),500,function(){jQuery(this).css("overflow","visible")}),this.$handle.stop().animate(this.calculateHandleCss(o),500,function(){jQuery(this).css("overflow","visible")})}calculateSliderCss(o){return{height:o+"px","margin-top":this.minimized_height-o+"px"}}},Fi(e,"defaults",{minimized_height:4,maximized_height:4,minimize_timeout:1500}),Fi(e,"template",'<div class="Ldt-Slider"></div><div class="Ldt-Slider-Time">00:00</div>'),e},slideVideoPlayerStyles={},SlideVideoPlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(o,u){super(o,u);Fi(this,"template",'<div class="Ldt-SlideVideoPlayer">  <div class="Ldt-SlideVideoPlayer-slide Ldt-SlideVideoPlayer-panel">  </div>  <div class="Ldt-SlideVideoPlayer-video Ldt-SlideVideoPlayer-panel">  </div></div>')}draw(){var o=this;o.renderTemplate(),this.insertSubwidget(o.$.find(".Ldt-SlideVideoPlayer-panel.Ldt-SlideVideoPlayer-slide"),{type:"ImageDisplay",annotation_type:o.annotation_type},"slide"),this.insertSubwidget(o.$.find(".Ldt-SlideVideoPlayer-panel.Ldt-SlideVideoPlayer-video"),{type:o.playerModule,video:o.video,width:"100%",url_transform:o.url_transform},"player"),o.mode=="pip"?(o.$.find(".Ldt-SlideVideoPlayer-panel").append('<div class="Ldt-SlideVideoPlayer-pip-menu"><div class="Ldt-SlideVideoPlayer-pip-menu-toggle"></div></div>'),o.$.on("click",".Ldt-SlideVideoPlayer-pip-menu-toggle",function(){o.toggleMainDisplay()}),window.setTimeout(function(){o.setMainDisplay("video")},1500)):window.setTimeout(function(){o.$.find(".Ldt-SlideVideoPlayer").touchSplit({orientation:screen.height>screen.width?"vertical":"horizontal",leftMin:20,topMin:20})},1500)}toggleMainDisplay(){this.$.find(".Ldt-SlideVideoPlayer-panel.Ldt-SlideVideoPlayer-video").hasClass("Ldt-SlideVideoPlayer-pip-main")?this.setMainDisplay("slides"):this.setMainDisplay("video")}setMainDisplay(o){var u=this.$.find(".Ldt-SlideVideoPlayer-panel.Ldt-SlideVideoPlayer-video"),l=this.$.find(".Ldt-SlideVideoPlayer-panel.Ldt-SlideVideoPlayer-slide");if(o=="slides"){var m=u;u=l,l=m}u.removeClass("Ldt-SlideVideoPlayer-pip-pip").addClass("Ldt-SlideVideoPlayer-pip-main"),l.removeClass("Ldt-SlideVideoPlayer-pip-main").addClass("Ldt-SlideVideoPlayer-pip-pip")}},Fi(e,"defaults",{playerModule:"HtmlPlayer",mode:"sidebyside"}),e},socialStyles={},Social=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){this.renderTemplate(),this.clipId=_$1.uniqueId("Ldt-Social-CopyBtn-"),this.$.find(".Ldt-Social-CopyBtn").attr("id",this.clipId);var n=this;this.$.find(".Ldt-Social-Url").click(function(){return n.toggleCopy(),!1}).on("dragstart",function(o){o.originalEvent.dataTransfer.setData("text/x-iri-title",n.text),o.originalEvent.dataTransfer.setData("text/x-iri-uri",n.url)}),this.$.find(".Ldt-Social-Input").focus(function(){this.select()}),this.$.find(".Ldt-Social-Ext").click(function(){return window.open(jQuery(this).attr("href"),"_blank","height=300,width=450,left=100,top=100,toolbar=0,menubar=0,status=0,location=0"),!1}),this.updateUrls(this.url,this.text)}toggleCopy(){var n=this.$.find(".Ldt-Social-UrlPop");n.toggle(),this.$.find(".Ldt-Social-Input").val(this.url).focus()}updateUrls(n,o){this.url=n,this.text=o,this.$.find(".Ldt-Social-Fb").attr("href","http://www.facebook.com/share.php?"+jQuery.param({u:n,t:o})),this.$.find(".Ldt-Social-Twitter").attr("href","https://twitter.com/intent/tweet?"+jQuery.param({url:n,text:o})),this.$.find(".Ldt-Social-Gplus").attr("href","https://plus.google.com/share?"+jQuery.param({url:n,title:o})),this.$.find(".Ldt-Social-Mail").attr("href","mailto:?"+jQuery.param({subject:o,body:o+": "+n}))}},Fi(e,"defaults",{text:"",url:"",show_url:!0,show_twitter:!0,show_fb:!0,show_gplus:!0,show_mail:!0}),Fi(e,"template",'<span class="Ldt-Social">{{#show_url}}<div class="Ldt-Social-Url-Container"><a href="#" draggable="true" target="_blank" class="Ldt-Social-Square Ldt-Social-Url Ldt-TraceMe" title="{{l10n.share_link}}"></a><div class="Ldt-Social-UrlPop"><input class="Ldt-Social-Input"/></div></div>{{/show_url}}{{#show_fb}}<a href="#" target="_blank" class="Ldt-Social-Fb Ldt-Social-Ext Ldt-TraceMe" title="{{l10n.share_on}} Facebook"></a>{{/show_fb}}{{#show_twitter}}<a href="#" target="_blank" class="Ldt-Social-Twitter Ldt-Social-Ext Ldt-TraceMe" title="{{l10n.share_on}} Twitter"></a>{{/show_twitter}}{{#show_gplus}}<a href="#" target="_blank" class="Ldt-Social-Gplus Ldt-Social-Ext Ldt-TraceMe" title="{{l10n.share_on}} Google+"></a>{{/show_gplus}}{{#show_mail}}<a href="#" target="_blank" class="Ldt-Social-Mail Ldt-TraceMe" title="{{l10n.share_mail}}"></a>{{/show_mail}}</span>'),Fi(e,"messages",{fr:{share_on:"Partager sur",share_mail:"Envoyer par courriel",share_link:"Partager le lien hypertexte",copy:"Copier"},en:{share_on:"Share on",share_mail:"Share by e-mail",share_link:"Share hypertext link",copy:"Copy"}}),e},Sparkline=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){for(var n=[],o=this.source.getDuration(),u=0,l=this.getWidgetAnnotations(),m=0;m<this.slice_count;m++){var y=m*o/this.slice_count,E=(m+1)*o/this.slice_count,C=0;l.forEach(function(F){if(F.begin<E&&F.end>=y){var j=F.getDuration().milliseconds;j?C+=(Math.min(F.end,E)-Math.max(F.begin,y))/j:C+=1}}),u=Math.max(u,C),n.push(C)}if(u){this.paper=new Raphael(this.$[0],this.width,this.height);var k=(this.height-this.margin)/u,A=this.width/this.slice_count,D=this,P=_$1(n).map(function(F){return D.margin+D.height-k*F}).value(),R=_$1(P).reduce(function(F,j,N){return F+(N?"C"+N*A+" "+P[N-1]+" "+N*A+" "+j+" "+(N+.5)*A+" "+j:"M0 "+j+"L"+.5*A+" "+j)},"")+"L"+this.width+" "+P[P.length-1],B=R+"L"+this.width+" "+this.height+"L0 "+this.height;this.paper.path(B).attr({stroke:"none",fill:this.fillColor}),this.paper.path(R).attr({fill:"none",stroke:this.lineColor,"stroke-width":this.lineWidth}),this.rectangleProgress=this.paper.rect(0,0,0,this.height).attr({stroke:"none",fill:"#808080",opacity:.3}),this.ligneProgress=this.paper.path("M0 0L0 "+this.height).attr({stroke:"#ff00ff","line-width":2}),this.$.click(function(F){var j=F.pageX-D.$.offset().left;D.media.setCurrentTime(D.media.duration*j/D.width)}),this.onMediaEvent("timeupdate","onTimeupdate")}}onTimeupdate(n){var o=Math.floor(this.width*n/this.media.duration);this.rectangleProgress.attr({width:o}),this.ligneProgress.attr({path:"M"+o+" 0L"+o+" "+this.height})}},Fi(e,"defaults",{lineColor:"#7492b4",fillColor:"#aeaeb8",lineWidth:2,slice_count:20,height:50,margin:5}),e},SpelSyncHtml=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),console.log("Calling IriSP.Widget's constructor from IriSP.HelloWorldWidget")}draw(){this.renderTemplate();var n=this.$.find("iframe")[0],o=this.src.replace(/#.*$/,"");this.getWidgetAnnotations().forEach(function(u){u.on("enter",function(){u.content&&u.content.data&&u.content.data.ref_text&&(n.src=o+"#"+u.content.data.ref_text)})})}},Fi(e,"defaults",{src:"about:blank"}),Fi(e,"template",'<div class="Ldt-SpelSyncHtml"><iframe src="{{src}}" {{#width}}width="{{width}}"{{/width}} {{#height}}height="{{height}}"{{/height}}</div>'),e},tagcloudStyles={},Tagcloud=function(t){var e;return e=class extends t.Widgets.Widget{constructor(o,u){super(o,u);Fi(this,"stopword_lists",{fr:["aussi","avec","aux","bien","car","cette","comme","dans","des","donc","dont","elle","encore","entre","est","être","eux","faire","fait","http","ici","ils","les","leur","leurs","mais","mes","même","mon","notre","non","nos","nous","ont","par","pas","peu","peut","plus","pour","quand","que","qui","quoi","sans","ses","son","sont","sur","tes","très","the","ton","tous","tout","une","votre","vos","vous"],en:["about","again","are","and","because","being","but","can","done","have","for","from","get","here","http","like","more","one","our","she","that","the","their","then","there","they","this","very","what","when","where","who","why","will","with","www","you","your"]});this.stopwords=_$1.uniq([].concat(this.custom_stopwords).concat(this.stopword_lists[this.stopword_language]))}draw(){if(this.segment_annotation_type){var o=this;this.source.getAnnotationsByTypeTitle(this.segment_annotation_type).forEach(function(u){u.on("enter",function(){o.redraw(u.begin,u.end)})})}else this.redraw()}redraw(o,u){var l=/https?:\/\/[0-9a-zA-Z\.%\/-_]+/g,m={},y=this,E=this.getWidgetAnnotations();if(!this.include_titles&&!this.include_descriptions)var C=/[^\.&;,'"!\?\d\(\)\+\[\]\\\…\-«»\/]{3,}/g;else var C=/[^\s\.&;,'"!\?\d\(\)\+\[\]\\\…\-«»:\/]{3,}/g;if(typeof o<"u"&&typeof u<"u"&&(E=E.filter(function(P){return P.begin>=o&&P.end<=u})),this.remove_zero_duration&&(E=E.filter(function(P){return P.getDuration()>0})),E.forEach(function(P){var R=(y.include_titles?P.title:"")+" "+(y.include_descriptions?P.description:"")+" "+(y.include_tag_texts?P.getTagTexts():"");_$1(R.toLowerCase().replace(l,"").match(C)).each(function(B){B=B.trim(),_$1(y.stopwords).indexOf(B)==-1&&(!y.exclude_pattern||!y.exclude_pattern.test(B))&&(m[B]=1+(m[B]||0))})}),m=_$1(m).chain().map(function(P,R){return{word:R,count:P}}).filter(function(P){return P.count>y.min_count}).sortBy(function(P){return-P.count}).first(this.tag_count).value(),m&&m.length){var k=m[0].count,A=Math.min(m[m.length-1].count,k-1),D=(this.max_font_size-this.min_font_size)/Math.sqrt(k-A);_$1(m).each(function(P){P.size=Math.floor(y.min_font_size+D*Math.sqrt(P.count-A))})}this.$.html(mustache.render(this.constructor.template,{words:m})),this.$.find(".Ldt-Tagcloud-item").click(function(){var P=jQuery(this).attr("content");y.source.getAnnotations().searchByTags(P)}),this.source.getAnnotations().on("search",this.functionWrapper("onSearch")),this.source.getAnnotations().on("search-cleared",this.functionWrapper("onSearch"))}onSearch(o){if(o=typeof o<"u"?o:"",o)var u=t.Model.regexpFromTextOrArray(o);this.$.find(".Ldt-Tagcloud-item").each(function(){var l=jQuery(this),m=l.attr("content");o?l.html(m.replace(u,'<span class="Ldt-Tagcloud-active">$1</span>')):l.html(m)})}},Fi(e,"template",'<div class="Ldt-Tagcloud-Container"><ul class="Ldt-Tagcloud-List">{{#words}}<li class="Ldt-Tagcloud-item Ldt-TraceMe" trace-info="tag:{{word}}" content="{{word}}" style="font-size: {{size}}px">{{word}}</li>{{/words}}</ul></div>'),Fi(e,"defaults",{include_titles:!0,include_descriptions:!0,include_tag_texts:!0,tag_count:30,stopword_language:"fr",custom_stopwords:[],exclude_pattern:!1,annotation_type:!1,segment_annotation_type:!1,min_font_size:10,max_font_size:26,min_count:2,remove_zero_duration:!1}),e},Title=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){this.renderTemplate()}},Fi(e,"defaults",{media_title:!1}),Fi(e,"template",'<div class="Ldt-TitleWidget"><h2>{{#media_title}}{{media.title}}{{/media_title}}{{^media_title}}{{source.title}}{{/media_title}}</h2></div>'),e},tooltipStyles={},Tooltip=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){const n=this;this.renderTemplate(),this.$.parent().css({position:"relative"}),this.$tooltip=this.$.find(".Ldt-Tooltip"),this.$tip=this.$.find(".Ldt-Tooltip-Tip"),this.$sw=this.$.find(".Ldt-Tooltip-Border-SW"),this.$se=this.$.find(".Ldt-Tooltip-Border-SE"),this.__halfWidth=Math.floor((this.$.find(".Ldt-Tooltip-Main").width()||192)/2),this.__borderWidth=this.$.find(".Ldt-Tooltip-Border-Left").width(),this.__tipDelta=this.__halfWidth-Math.floor(this.$tip.width()/2),this.__maxShift=this.__tipDelta-this.__borderWidth,this.$.mouseover(function(){n.$tooltip.hide()}),this.hide()}show(n,o,u,l){if(typeof l<"u")if(typeof l=="string")this.$.find(".Ldt-Tooltip-Color").html(""),this.$.find(".Ldt-Tooltip-Color").show().css("background-color",l),this.$.find(".Ldt-Tooltip-Color").show().css("height","");else{var m=this.$.find(".Ldt-Tooltip-Color");m.html(""),m.show();for(var y=0;y<l.length;y++)m.append('<div style="float: left; height: 10px; width: 10px; background-color: '+l[y]+'">');this.$.find(".Ldt-Tooltip-Color").css("height",l.length*10+"px")}else this.$.find(".Ldt-Tooltip-Color").hide();this.$.find(".Ldt-Tooltip-Text").html(u),this.$tooltip.show();var E=0;typeof this.min_x<"u"&&n-this.__halfWidth<this.min_x&&(E=Math.max(n-this.__halfWidth-this.min_x,-this.__maxShift)),typeof this.max_x<"u"&&+n+this.__halfWidth>this.max_x&&(E=Math.min(+n+this.__halfWidth-this.max_x,this.__maxShift)),this.$tooltip.css({left:n-E+"px",top:o+"px"}),this.$tip.css({left:this.__tipDelta+E+"px"}),this.$sw.css({width:this.__tipDelta+E-this.__borderWidth+"px"}),this.$se.css({width:this.__tipDelta-E-this.__borderWidth+"px"})}hide(){this.$tooltip.hide()}},Fi(e,"defaults",{}),Fi(e,"template",'<div class="Ldt-Tooltip"><div class="Ldt-Tooltip-Main"><div class="Ldt-Tooltip-Corner-NW"></div><div class="Ldt-Tooltip-Border-Top"></div><div class="Ldt-Tooltip-Corner-NE"></div><div class="Ldt-Tooltip-Border-Left"></div><div class="Ldt-Tooltip-Border-Right"></div><div class="Ldt-Tooltip-Corner-SW"></div><div class="Ldt-Tooltip-Border-SW"></div><div class="Ldt-Tooltip-Tip"></div><div class="Ldt-Tooltip-Border-SE"></div><div class="Ldt-Tooltip-Corner-SE"></div><div class="Ldt-Tooltip-Inner"><div class="Ldt-Tooltip-Color"></div><p class="Ldt-Tooltip-Text"></p></div></div></div>'),e},transcriptStyles={},Transcript=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){var n=this.getWidgetAnnotations(),o=this,u;if(o.renderTemplate(),u=o.$.find(".Ldt-TranscriptWidget"),o.use_vtt_track){var l=o.player.widgets.filter(function(y){return y.type=="HtmlPlayer"});if(l){var m=l[0].$.find("video")[0];m.addEventListener("loadedmetadata",function(){var y=m.textTracks[0],E=y.cues,C=1;Array.prototype.forEach.apply(E,[function(k){k.id="cue"+C;var A=mustache.render(o.annotationTemplate,{id:k.id,content:k.text,begin:1e3*k.startTime,end:1e3*k.endTime});C+=1;var D=jQuery(A);u.append(D)}]),y.addEventListener("cuechange",function(){var k=y.activeCues;k.length>0&&(o.$.find(".Ldt-Transcript-Annotation.active").removeClass("active"),Array.prototype.forEach.apply(k,[function(A){o.$.find("#"+A.id).addClass("active")}]))},!1),u.on("click",".Ldt-Transcript-Annotation",function(){o.media.setCurrentTime(this.dataset.begin)})})}else console.log("cannot find a video object")}else n.forEach(function(y){var E={id:y.id,content:t.textFieldHtml(y.title),begin:y.begin.toString(),end:y.end.toString()},C=mustache.render(o.annotationTemplate,E),k=jQuery(C);u.append(k)})}},Fi(e,"defaults",{annotation_type:"Caption",use_vtt_track:!1}),Fi(e,"template",'<div class="Ldt-TranscriptWidget"></div>'),Fi(e,"annotationTemplate",'<span data-begin="{{ begin }}" data-end="{{ end }}" data-id="{{ id }}" class="Ldt-Transcript-Annotation">{{ content }}</span>  '),e},tweetStyles={},Tweet=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o),this.lastAnnotation=!1}draw(){this.renderTemplate(),this.pinned=this.pin_at_start;var n=this;this.$.find(".Ldt-Tweet-Pin").click(function(){n.pinned=!n.pinned;var o=jQuery(this);n.pinned?(o.addClass("active").attr("title",n.l10n.dont_keep_visible),n.cancelTimeout()):(o.removeClass("active").attr("title",n.l10n.keep_visible),n.hideTimeout())}),this.$.find(".Ldt-Tweet-Close").click(function(){n.hide()}),this.$.hide(),this.getWidgetAnnotations().forEach(function(o){o.on("click",function(){n.show(o)})})}show(n){if(typeof n<"u"&&typeof n.source<"u"){var o=[[/#(\w+)/gm,function(D){return'<a href="http://twitter.com/search?q=%23'+D[1]+'" target="_blank">'},"</a>"]],u=_$1(n.source.entities.urls).sortBy(function(D){return D.indices[0]}),l=0,m="";_$1(u).each(function(D){D.indices[0]>=l&&(m+=n.source.text.substring(l,D.indices[0]),m+=typeof D.expanded_url<"u"&&D.expanded_url!==null?D.expanded_url:D.url,l=D.indices[1])}),m+=n.source.text.substring(l);for(var y=0;y<this.polemics.length;y++){var E=t.Model.regexpFromTextOrArray(this.polemics[y].keywords);o.push([E,'<span style="background: '+this.polemics[y].color+'">',"</span>"])}var E=n.found&&_this.source.getAnnotations().regexp||!1,C=n.source.user?n.source.user.profile_image_url:n.source.profile_image_url,k=n.source.user?n.source.user.screen_name:n.source.from_user,A=n.source.user?n.source.user.name:n.source.from_user_name;this.$.find(".Ldt-Tweet-Avatar").attr("src",C),this.$.find(".Ldt-Tweet-ScreenName").html("@"+k),this.$.find(".Ldt-Tweet-ProfileLink").attr("href","https://twitter.com/"+k),this.$.find(".Ldt-Tweet-FullName").html(A),this.$.find(".Ldt-Tweet-Contents").html(t.textFieldHtml(m,E,o)),this.$.find(".Ldt-Tweet-Time").html(this.l10n.original_time+new Date(n.source.created_at).toLocaleTimeString()+" / "+this.l10n.video_time+n.begin.toString()),this.$.find(".Ldt-Tweet-Retweet").attr("href","https://twitter.com/intent/retweet?tweet_id="+n.source.id_str),this.$.find(".Ldt-Tweet-Reply").attr("href","https://twitter.com/intent/tweet?in_reply_to="+n.source.id_str),this.$.find(".Ldt-Tweet-Original").attr("href","https://twitter.com/"+k+"/status/"+n.source.id_str),this.player.trigger("Annotation.minimize"),this.$.slideDown(),this.cancelTimeout(),this.pinned||this.hideTimeout()}else this.hide()}hide(){this.player.trigger("Annotation.maximize"),this.$.slideUp(),this.cancelTimeout()}cancelTimeout(){typeof this.hide_timer<"u"&&(window.clearTimeout(this.hide_timer),this.hide_timer=void 0)}hideTimeout(){this.cancelTimeout(),this.hide_timer=window.setTimeout(this.functionWrapper("hide"),this.hide_timeout)}},Fi(e,"defaults",{hide_timeout:1e4,polemics:[{keywords:["++"],color:"#30d765"},{keywords:["--"],color:"#f51123"},{keywords:["=="],color:"#f1e24a"},{keywords:["??"],color:"#05aae6"}],annotation_type:"tweet",pin_at_start:!1}),Fi(e,"messages",{fr:{retweet:"Retweeter",reply:"Répondre",keep_visible:"Empêcher la fermeture automatique",dont_keep_visible:"Permettre la fermeture automatique",close_widget:"Fermer l'affichage du tweet",original_time:"Heure d'envoi : ",video_time:"Temps de la vidéo : ",show_original:"Voir l'original"},en:{retweet:"Retweet",reply:"Reply",keep_visible:"Keep visible",dont_keep_visible:"Don't keep visible",close_widget:"Close tweet display",original_time:"Tweet sent at: ",video_time:"Video time: ",show_original:"Show original"}}),Fi(e,"template",'<div class="Ldt-Tweet-Widget"><div class="Ldt-Tweet-Inner"><div class="Ldt-Tweet-PinClose-Buttons"><a href="#" class="Ldt-Tweet-Pin Ldt-TraceMe{{#pin_at_start}} active" title="{{l10n.dont_keep_visible}}{{/pin_at_start}}{{^pin_at_start}}" title="{{l10n.keep_visible}}{{/pin_at_start}}"></a><a href="#" class="Ldt-Tweet-Close Ldt-TraceMe" title="{{l10n.close_widget}}"></a></div><div class="Ldt-Tweet-AvatarContainer"><a href="#" class="Ldt-Tweet-ProfileLink" target="_blank"><img src="" class="Ldt-Tweet-Avatar"/></a></div><h3><a href="#" class="Ldt-Tweet-ProfileLink Ldt-Tweet-ScreenName" target="_blank"></a> (<span class="Ldt-Tweet-FullName"></span>)</h3><p class="Ldt-Tweet-Contents"></p><div class="Ldt-Tweet-Bottom"><span class="Ldt-Tweet-Time"></span><a class="Ldt-Tweet-Original" href="" target="_blank">{{l10n.show_original}}</a><a href="" target="_blank" class="Ldt-Tweet-Retweet"><div class="Ldt-Tweet-Icon"></div>{{l10n.retweet}}</a><a href="" target="_blank" class="Ldt-Tweet-Reply"><div class="Ldt-Tweet-Icon"></div>{{l10n.reply}}</a></div></div></div>'),e},AutoPlayer=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){typeof this.video>"u"&&(this.video=this.media.video);var n=["live","provider","autostart","streamer","video","height","width","url_transform"],o={},u=[{regexp:/\.(mp4|m4v|mp3)$/,type:"AdaptivePlayer"},{regexp:/\.(ogg|ogv|webm)$/,type:"HtmlPlayer"},{regexp:/^(https?:\/\/)?(www\.)?youtube\.com/,type:"VideojsPlayer"},{regexp:/^(https?:\/\/)?(www\.)?vimeo\.com/,type:"VideojsPlayer"},{regexp:/^(https?:\/\/)?(www\.)?dailymotion\.com/,type:"DailymotionPlayer"}];if(this.video){for(var l=0;l<u.length;l++)if(u[l].regexp.test(this.video.toLowerCase())){o.type=u[l].type;break}}if(typeof o.type>"u"&&(o.type=this.default_type),o.type==="AdaptivePlayer"){var m=document.createElement("video").canPlayType('video/mp4; codecs="avc1.42E01E"');o.type=m!=="no"?"HtmlPlayer":"JwpPlayer"}for(var l=0;l<n.length;l++)typeof this[n[l]]<"u"&&(o[n[l]]=this[n[l]]);this.insertSubwidget(this.$,o)}},Fi(e,"defaults",{default_type:"HtmlPlayer"}),e},MultiSegments=function(t){var e;return e=class extends t.Widgets.Widget{constructor(n,o){super(n,o)}draw(){var n=this,o=[],u=null,l={},m={};_$1(this).each(function(y,E){/^segments_/.test(E)&&(l[E.replace(/^segments_/,"")]=y),/^annotation_/.test(E)&&(m[E.replace(/^annotation_/,"")]=y)}),this.source.getAnnotationTypes().forEach(function(y){var E=y.getAnnotations().filter(function(A){return A.getDuration()>0&&A.getMedia().id==n.media.id});if(E.length){var C=!1,k={segmentWidget:jQuery("<div>"),annotationWidget:jQuery("<div>"),hasSegmentsNow:function(){var A=n.media.getCurrentTime();return!!E.filter(function(D){return D.begin<=A&&D.end>A}).length},hide:function(){C&&(C=!1,this.annotationWidget.slideUp())},show:function(){C||(C=!0,this.annotationWidget.slideDown())}};k.segmentWidget.addClass("Ldt-MultiSegments-Segment").appendTo(n.$),n.show_all||k.segmentWidget.on("mouseenter",function(){k.hasSegmentsNow()&&(u=k)}),k.annotationWidget.addClass("Ldt-MultiSegments-Annotation").appendTo(n.$).hide(),n.insertSubwidget(k.segmentWidget,_$1({type:"Segments",annotation_type:y,width:"100%"}).extend(l).value()),n.insertSubwidget(k.annotationWidget,_$1({type:"Annotation",annotation_type:y,width:"100%"}).extend(m).value()),o.push(k)}}),jQuery(document).on("click",".Ldt-Segments-Segment",function(y){!n.show_all&&u&&!u.hasSegmentsNow()&&(u=void 0),_$1(o).each(function(E){jQuery(y.target).parent().parent()[0]==E.segmentWidget[0]?(u=E,E.show()):E.hide()})})}},Fi(e,"defaults",{annotation_show_arrow:!0,annotation_start_minimized:!1,annotation_show_annotation_type:!0,show_all:!1}),e};function widgets(t){return{AdaptivePlayer:AdaptivePlayer(t),AutoPlayer:AutoPlayer(t),HelloWorld:HelloWorld(t),Annotation:Annotation(t),AnnotationsController:AnnotationsController(t),AnnotationsList:AnnotationsList(t),Arrow:Arrow(t),Controller:Controller(t),CreateAnnotation:CreateAnnotation(t),CurrentSegmentInfobox:CurrentSegmentInfobox(t),DailymotionPlayer:DailymotionPlayer(t),EnrichedPlan:EnrichedPlan(t),Highlighter:Highlighter(t),HtmlMashupPlayer:HtmlMashupPlayer(t),HtmlPlayer:HtmlPlayer(t),ImageDisplay:ImageDisplay(t),JwpPlayer:JwpPlayerWidget(t),LatestAnnotation:LatestAnnotation(t),MashupPlayer:MashupPlayer(t),Mediafragment:Mediafragment(t),MediaList:MediaList(t),MultiSegments:MultiSegments(t),NoteTaking:NoteTaking(t),PlaceholderPlayer:PlaceholderPlayer(t),Polemic:Polemic(t),PopcornPlayer:PopcornPlayer(t),Quiz:Quiz(t),UniqueChoiceQuestion:UniqueChoiceQuestion(t),MultipleChoiceQuestion:MultipleChoiceQuestion(t),QuizCreator:QuizCreator(t),Segments:Segments(t),Shortcuts:Shortcuts(t),Slice:Slice(t),SlidePreview:SlidePreview(t),Slider:Slider(t),SlideVideoPlayer:SlideVideoPlayer(t),Social:Social(t),Sparkline:Sparkline(t),SpelSyncHtml:SpelSyncHtml(t),Tagcloud:Tagcloud(t),Title:Title(t),Tooltip:Tooltip(t),Transcript:Transcript(t),Tweet:Tweet(t),VideojsPlayer:VideojsPlayerWidget(t),styles:{annotationStyles,helloWorldStyles,annotationsControllerStyles,annotationsListStyles,controllerStyles,createAnnotationStyles,currentSegmentInfoboxStyles,enrichedPlanStyles,highlighterStyles,imageDisplayStyles,latestAnnotationStyles,mashupPlayerStyles,mediaListStyles,noteTakingStyles,placeholderPlayerStyles,polemicStyles,quizStyles,quizCreatorStyles,segmentsStyles,shortcutsStyles,sliceStyles,slidePreviewStyles,sliderStyles,slideVideoPlayerStyles,socialStyles,tagcloudStyles,tooltipStyles,transcriptStyles,tweetStyles,videojsStyles}}}typeof window.IriSP>"u"&&(window.IriSP=IriSP$1),IriSP$1.Model=Model(IriSP$1),IriSP$1.htmlPlayer=htmlPlayer,Object.assign(IriSP$1,utils$s(IriSP$1)),IriSP$1.iFrameUpdater=iFrameUpdater,IriSP$1.serializers=serializers(IriSP$1),Object.assign(IriSP$1,defaults()),metadataplayer(IriSP$1),IriSP$1.Widgets=widgetsBase(IriSP$1),Object.assign(IriSP$1.Widgets,widgets(IriSP$1));const main={IriSP:IriSP$1,style};return main});
//# sourceMappingURL=LdtPlayer-core.js.map
