ranuts 0.1.0-alpha.13 → 0.1.0-alpha.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/utils/dom.d.ts +1 -0
- package/dist/src/utils/index.js +13 -2
- package/dist/src/utils/visual/graphics/graphics.d.ts +5 -5
- package/dist/src/utils/visual/graphics/graphicsData.d.ts +3 -3
- package/dist/src/utils/visual/graphics/graphicsGeometry.d.ts +3 -3
- package/dist/src/utils/visual/shape/shape.d.ts +2 -2
- package/dist/tsconfig.json +0 -1
- package/dist/umd/index.umd.cjs +1 -1
- package/dist/umd/utils/utils.umd.cjs +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).ranuts_utils={})}(this,(function(e){"use strict";var t=Object.defineProperty,n=(e,n,i)=>((e,n,i)=>n in e?t(e,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[n]=i)(e,"symbol"!=typeof n?n+"":n,i);const i={172351395:{name:"EBML",type:"Container"},646:{name:"EBMLVersion",type:"Uint"},759:{name:"EBMLReadVersion",type:"Uint"},754:{name:"EBMLMaxIDLength",type:"Uint"},755:{name:"EBMLMaxSizeLength",type:"Uint"},642:{name:"DocType",type:"String"},647:{name:"DocTypeVersion",type:"Uint"},645:{name:"DocTypeReadVersion",type:"Uint"},108:{name:"Void",type:"Binary"},63:{name:"CRC-32",type:"Binary"},190023271:{name:"SignatureSlot",type:"Container"},16010:{name:"SignatureAlgo",type:"Uint"},16026:{name:"SignatureHash",type:"Uint"},16037:{name:"SignaturePublicKey",type:"Binary"},16053:{name:"Signature",type:"Binary"},15963:{name:"SignatureElements",type:"Container"},15995:{name:"SignatureElementList",type:"Container"},9522:{name:"SignedElement",type:"Binary"},139690087:{name:"Segment",type:"Container"},21863284:{name:"SeekHead",type:"Container"},3515:{name:"Seek",type:"Container"},5035:{name:"SeekID",type:"Binary"},5036:{name:"SeekPosition",type:"Uint"},88713574:{name:"Info",type:"Container"},13220:{name:"SegmentUID",type:"Binary"},13188:{name:"SegmentFilename",type:"String"},1882403:{name:"PrevUID",type:"Binary"},1868715:{name:"PrevFilename",type:"String"},2013475:{name:"NextUID",type:"Binary"},1999803:{name:"NextFilename",type:"String"},1092:{name:"SegmentFamily",type:"Binary"},10532:{name:"ChapterTranslate",type:"Container"},10748:{name:"ChapterTranslateEditionUID",type:"Uint"},10687:{name:"ChapterTranslateCodec",type:"Uint"},10661:{name:"ChapterTranslateID",type:"Binary"},710577:{name:"TimecodeScale",type:"Uint"},1161:{name:"Duration",type:"Float"},1121:{name:"DateUTC",type:"Date"},15273:{name:"Title",type:"String"},3456:{name:"MuxingApp",type:"String"},5953:{name:"WritingApp",type:"String"},103:{name:"Timecode",type:"Uint"},6228:{name:"SilentTracks",type:"Container"},6359:{name:"SilentTrackNumber",type:"Uint"},39:{name:"Position",type:"Uint"},43:{name:"PrevSize",type:"Uint"},35:{name:"SimpleBlock",type:"Binary"},32:{name:"BlockGroup",type:"Container"},33:{name:"Block",type:"Binary"},34:{name:"BlockVirtual",type:"Binary"},13729:{name:"BlockAdditions",type:"Container"},38:{name:"BlockMore",type:"Container"},110:{name:"BlockAddID",type:"Uint"},37:{name:"BlockAdditional",type:"Binary"},27:{name:"BlockDuration",type:"Uint"},122:{name:"ReferencePriority",type:"Uint"},123:{name:"ReferenceBlock",type:"Int"},125:{name:"ReferenceVirtual",type:"Int"},36:{name:"CodecState",type:"Binary"},13730:{name:"DiscardPadding",type:"Int"},14:{name:"Slices",type:"Container"},104:{name:"TimeSlice",type:"Container"},76:{name:"LaceNumber",type:"Uint"},77:{name:"FrameNumber",type:"Uint"},75:{name:"BlockAdditionID",type:"Uint"},78:{name:"Delay",type:"Uint"},79:{name:"SliceDuration",type:"Uint"},72:{name:"ReferenceFrame",type:"Container"},73:{name:"ReferenceOffset",type:"Uint"},74:{name:"ReferenceTimeCode",type:"Uint"},47:{name:"EncryptedBlock",type:"Binary"},106212971:{name:"Tracks",type:"Container"},46:{name:"TrackEntry",type:"Container"},87:{name:"TrackNumber",type:"Uint"},13253:{name:"TrackUID",type:"Uint"},3:{name:"TrackType",type:"Uint"},57:{name:"FlagEnabled",type:"Uint"},8:{name:"FlagDefault",type:"Uint"},5546:{name:"FlagForced",type:"Uint"},28:{name:"FlagLacing",type:"Uint"},11751:{name:"MinCache",type:"Uint"},11768:{name:"MaxCache",type:"Uint"},254851:{name:"DefaultDuration",type:"Uint"},216698:{name:"DefaultDecodedFieldDuration",type:"Uint"},209231:{name:"TrackTimecodeScale",type:"Float"},4991:{name:"TrackOffset",type:"Int"},5614:{name:"MaxBlockAdditionID",type:"Uint"},4974:{name:"Name",type:"String"},177564:{name:"Language",type:"String"},6:{name:"CodecID",type:"String"},9122:{name:"CodecPrivate",type:"Binary"},362120:{name:"CodecName",type:"String"},13382:{name:"AttachmentLink",type:"Uint"},1742487:{name:"CodecSettings",type:"String"},1785920:{name:"CodecInfoURL",type:"String"},438848:{name:"CodecDownloadURL",type:"String"},42:{name:"CodecDecodeAll",type:"Uint"},12203:{name:"TrackOverlay",type:"Uint"},5802:{name:"CodecDelay",type:"Uint"},5819:{name:"SeekPreRoll",type:"Uint"},9764:{name:"TrackTranslate",type:"Container"},9980:{name:"TrackTranslateEditionUID",type:"Uint"},9919:{name:"TrackTranslateCodec",type:"Uint"},9893:{name:"TrackTranslateTrackID",type:"Binary"},96:{name:"Video",type:"Container"},26:{name:"FlagInterlaced",type:"Uint"},5048:{name:"StereoMode",type:"Uint"},5056:{name:"AlphaMode",type:"Uint"},5049:{name:"OldStereoMode",type:"Uint"},48:{name:"PixelWidth",type:"Uint"},58:{name:"PixelHeight",type:"Uint"},5290:{name:"PixelCropBottom",type:"Uint"},5307:{name:"PixelCropTop",type:"Uint"},5324:{name:"PixelCropLeft",type:"Uint"},5341:{name:"PixelCropRight",type:"Uint"},5296:{name:"DisplayWidth",type:"Uint"},5306:{name:"DisplayHeight",type:"Uint"},5298:{name:"DisplayUnit",type:"Uint"},5299:{name:"AspectRatioType",type:"Uint"},963876:{name:"ColourSpace",type:"Binary"},1029411:{name:"GammaValue",type:"Float"},230371:{name:"FrameRate",type:"Float"},97:{name:"Audio",type:"Container"},53:{name:"SamplingFrequency",type:"Float"},14517:{name:"OutputSamplingFrequency",type:"Float"},31:{name:"Channels",type:"Uint"},15739:{name:"ChannelPositions",type:"Binary"},8804:{name:"BitDepth",type:"Uint"},98:{name:"TrackOperation",type:"Container"},99:{name:"TrackCombinePlanes",type:"Container"},100:{name:"TrackPlane",type:"Container"},101:{name:"TrackPlaneUID",type:"Uint"},102:{name:"TrackPlaneType",type:"Uint"},105:{name:"TrackJoinBlocks",type:"Container"},109:{name:"TrackJoinUID",type:"Uint"},64:{name:"TrickTrackUID",type:"Uint"},65:{name:"TrickTrackSegmentUID",type:"Binary"},70:{name:"TrickTrackFlag",type:"Uint"},71:{name:"TrickMasterTrackUID",type:"Uint"},68:{name:"TrickMasterTrackSegmentUID",type:"Binary"},11648:{name:"ContentEncodings",type:"Container"},8768:{name:"ContentEncoding",type:"Container"},4145:{name:"ContentEncodingOrder",type:"Uint"},4146:{name:"ContentEncodingScope",type:"Uint"},4147:{name:"ContentEncodingType",type:"Uint"},4148:{name:"ContentCompression",type:"Container"},596:{name:"ContentCompAlgo",type:"Uint"},597:{name:"ContentCompSettings",type:"Binary"},4149:{name:"ContentEncryption",type:"Container"},2017:{name:"ContentEncAlgo",type:"Uint"},2018:{name:"ContentEncKeyID",type:"Binary"},2019:{name:"ContentSignature",type:"Binary"},2020:{name:"ContentSigKeyID",type:"Binary"},2021:{name:"ContentSigAlgo",type:"Uint"},2022:{name:"ContentSigHashAlgo",type:"Uint"},206814059:{name:"Cues",type:"Container"},59:{name:"CuePoint",type:"Container"},51:{name:"CueTime",type:"Uint"},55:{name:"CueTrackPositions",type:"Container"},119:{name:"CueTrack",type:"Uint"},113:{name:"CueClusterPosition",type:"Uint"},112:{name:"CueRelativePosition",type:"Uint"},50:{name:"CueDuration",type:"Uint"},4984:{name:"CueBlockNumber",type:"Uint"},106:{name:"CueCodecState",type:"Uint"},91:{name:"CueReference",type:"Container"},22:{name:"CueRefTime",type:"Uint"},23:{name:"CueRefCluster",type:"Uint"},4959:{name:"CueRefNumber",type:"Uint"},107:{name:"CueRefCodecState",type:"Uint"},155296873:{name:"Attachments",type:"Container"},8615:{name:"AttachedFile",type:"Container"},1662:{name:"FileDescription",type:"String"},1646:{name:"FileName",type:"String"},1632:{name:"FileMimeType",type:"String"},1628:{name:"FileData",type:"Binary"},1710:{name:"FileUID",type:"Uint"},1653:{name:"FileReferral",type:"Binary"},1633:{name:"FileUsedStartTime",type:"Uint"},1634:{name:"FileUsedEndTime",type:"Uint"},4433776:{name:"Chapters",type:"Container"},1465:{name:"EditionEntry",type:"Container"},1468:{name:"EditionUID",type:"Uint"},1469:{name:"EditionFlagHidden",type:"Uint"},1499:{name:"EditionFlagDefault",type:"Uint"},1501:{name:"EditionFlagOrdered",type:"Uint"},54:{name:"ChapterAtom",type:"Container"},13252:{name:"ChapterUID",type:"Uint"},5716:{name:"ChapterStringUID",type:"String"},17:{name:"ChapterTimeStart",type:"Uint"},18:{name:"ChapterTimeEnd",type:"Uint"},24:{name:"ChapterFlagHidden",type:"Uint"},1432:{name:"ChapterFlagEnabled",type:"Uint"},11879:{name:"ChapterSegmentUID",type:"Binary"},11964:{name:"ChapterSegmentEditionUID",type:"Uint"},9155:{name:"ChapterPhysicalEquiv",type:"Uint"},15:{name:"ChapterTrack",type:"Container"},9:{name:"ChapterTrackNumber",type:"Uint"},0:{name:"ChapterDisplay",type:"Container"},5:{name:"ChapString",type:"String"},892:{name:"ChapLanguage",type:"String"},894:{name:"ChapCountry",type:"String"},10564:{name:"ChapProcess",type:"Container"},10581:{name:"ChapProcessCodecID",type:"Uint"},1293:{name:"ChapProcessPrivate",type:"Binary"},10513:{name:"ChapProcessCommand",type:"Container"},10530:{name:"ChapProcessTime",type:"Uint"},10547:{name:"ChapProcessData",type:"Binary"},39109479:{name:"Tags",type:"Container"},13171:{name:"Tag",type:"Container"},9152:{name:"Targets",type:"Container"},10442:{name:"TargetTypeValue",type:"Uint"},9162:{name:"TargetType",type:"String"},9157:{name:"TagTrackUID",type:"Uint"},9161:{name:"TagEditionUID",type:"Uint"},9156:{name:"TagChapterUID",type:"Uint"},9158:{name:"TagAttachmentUID",type:"Uint"},10184:{name:"SimpleTag",type:"Container"},1443:{name:"TagName",type:"String"},1146:{name:"TagLanguage",type:"String"},1156:{name:"TagDefault",type:"Uint"},1159:{name:"TagString",type:"String"},1157:{name:"TagBinary",type:"Binary"}};class a{constructor(e="Unknown",t="Unknown"){n(this,"source"),n(this,"data"),this.name=e,this.type=t}updateBySource(){}setSource(e){this.source=e,this.updateBySource()}updateByData(){}setData(e){this.data=e,this.updateByData()}}function o(e){return e.length%2==1?"0"+e:e}class r extends a{constructor(e,t){super(e,t||"Uint")}updateBySource(){this.data="";for(let e=0;e<this.source.length;e++){const t=this.source[e].toString(16);this.data+=o(t)}}updateByData(){const e=this.data.length/2;this.source=new Uint8Array(e);for(let t=0;t<e;t++){const e=this.data.substr(2*t,2);this.source[t]=parseInt(e,16)}}getValue(){return parseInt(this.data,16)}setValue(e){this.setData(o(e.toString(16)))}}class s extends a{constructor(e,t){super(e,t||"Float")}getFloatArrayType(){return this.source&&4===this.source.length?Float32Array:Float64Array}updateBySource(){const e=this.source.reverse(),t=new(this.getFloatArrayType())(e.buffer);this.data=t[0]}updateByData(){const e=new(this.getFloatArrayType())([this.data]),t=new Uint8Array(e.buffer);this.source=t.reverse()}getValue(){return this.data}setValue(e){this.setData(e)}}class p extends a{constructor(e,t){super(e,t||"Container"),n(this,"offset",0),n(this,"data",[])}readByte(){return this.source[this.offset++]}readUint(){const e=this.readByte(),t=8-e.toString(2).length;let n=e-(1<<7-t);for(let i=0;i<t;i++)n*=256,n+=this.readByte();return n}updateBySource(){let e;for(this.data=[],this.offset=0;this.offset<this.source.length;this.offset=e){const t=this.readUint(),n=this.readUint();e=Math.min(this.offset+n,this.source.length);const o=this.source.slice(this.offset,e),c=i[t]||{name:"Unknown",type:"Unknown"};let l=a;switch(c.type){case"Container":l=p;break;case"Uint":l=r;break;case"Float":l=s}const d=new l(c.name,c.type);d.setSource(o),this.data.push({id:t,idHex:t.toString(16),data:d})}}writeUint(e,t=!1){let n=1,i=128;for(;e>=i&&n<8;)n++,i*=128;if(!t){let t=i+e;for(let e=n-1;e>=0;e--){const n=t%256;this.source[this.offset+e]=n,t=(t-n)/256}}this.offset+=n}writeSections(e=!1){this.offset=0;for(let t=0;t<this.data.length;t++){const n=this.data[t],i=n.data.source,a=i.length;this.writeUint(n.id,e),this.writeUint(a,e),e||this.source.set(i,this.offset),this.offset+=a}return this.offset}updateByData(){const e=this.writeSections(!0);this.source=new Uint8Array(e),this.writeSections()}getSectionById(e){for(let t=0;t<this.data.length;t++){const n=this.data[t];if(n.id===e)return n.data}}}class c extends p{constructor(e){super("File","File"),this.setSource(e)}fixDuration(e){const t=this.getSectionById(139690087);if(!t)return!1;const n=t.getSectionById(88713574);if(!n)return!1;const i=n.getSectionById(710577);if(!i)return!1;let a=n.getSectionById(1161);if(a){if(!(a.getValue()<=0))return!1;a.setValue(e)}else a=new s("Duration","Float"),a.setValue(e),n.data.push({id:1161,data:a});return i.setValue(1e6),n.updateByData(),t.updateByData(),this.updateByData(),!0}toBlob(e="video/webm"){return new Blob([this.source.buffer],{type:e})}}const l=()=>{};var d=(e=>(e.IPAD="ipad",e.ANDROID="android",e.IPhONE="iphone",e.PC="pc",e))(d||{});const m=()=>{if("undefined"!=typeof window){const e=navigator.userAgent.toLowerCase();return/ipad|ipod/.test(e)?"ipad":/android/.test(e)?"android":/iphone/.test(e)?"iphone":"pc"}return"pc"},h="undefined"!=typeof window,u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",f="ARRAYBUFFER not supported by this environment",g="UINT8ARRAY not supported by this environment";function v(e,t,n,i){let a,o,r;const s=t||[0],p=(n=n||0)>>>3,c=-1===i?3:0;for(a=0;a<e.length;a+=1)r=a+p,o=r>>>2,s.length<=o&&s.push(0),s[o]|=e[a]<<8*(c+i*(r%4));return{value:s,binLen:8*e.length+n}}function w(e,t,n){switch(t){case"UTF8":case"UTF16BE":case"UTF16LE":break;default:throw new Error("encoding must be UTF8, UTF16BE, or UTF16LE")}switch(e){case"HEX":return function(e,t,i){return function(e,t,n,i){let a,o,r,s;if(0!=e.length%2)throw new Error("String of HEX type must be in byte increments");const p=t||[0],c=(n=n||0)>>>3,l=-1===i?3:0;for(a=0;a<e.length;a+=2){if(o=parseInt(e.substr(a,2),16),isNaN(o))throw new Error("String of HEX type contains invalid characters");for(s=(a>>>1)+c,r=s>>>2;p.length<=r;)p.push(0);p[r]|=o<<8*(l+i*(s%4))}return{value:p,binLen:4*e.length+n}}(e,t,i,n)};case"TEXT":return function(e,i,a){return function(e,t,n,i,a){let o,r,s,p,c,l,d,m,h=0;const u=n||[0],f=(i=i||0)>>>3;if("UTF8"===t)for(d=-1===a?3:0,s=0;s<e.length;s+=1)for(o=e.charCodeAt(s),r=[],128>o?r.push(o):2048>o?(r.push(192|o>>>6),r.push(128|63&o)):55296>o||57344<=o?r.push(224|o>>>12,128|o>>>6&63,128|63&o):(s+=1,o=65536+((1023&o)<<10|1023&e.charCodeAt(s)),r.push(240|o>>>18,128|o>>>12&63,128|o>>>6&63,128|63&o)),p=0;p<r.length;p+=1){for(l=h+f,c=l>>>2;u.length<=c;)u.push(0);u[c]|=r[p]<<8*(d+a*(l%4)),h+=1}else for(d=-1===a?2:0,m="UTF16LE"===t&&1!==a||"UTF16LE"!==t&&1===a,s=0;s<e.length;s+=1){for(o=e.charCodeAt(s),!0===m&&(p=255&o,o=p<<8|o>>>8),l=h+f,c=l>>>2;u.length<=c;)u.push(0);u[c]|=o<<8*(d+a*(l%4)),h+=2}return{value:u,binLen:8*h+i}}(e,t,i,a,n)};case"B64":return function(e,t,i){return function(e,t,n,i){let a,o,r,s,p,c,l,d=0;const m=t||[0],h=(n=n||0)>>>3,f=-1===i?3:0,g=e.indexOf("=");if(-1===e.search(/^[a-z\d=+/]+$/i))throw new Error("Invalid character in base-64 string");if(e=e.replace(/=/g,""),-1!==g&&g<e.length)throw new Error("Invalid '=' found in base-64 string");for(o=0;o<e.length;o+=4){for(p=e.substr(o,4),s=0,r=0;r<p.length;r+=1)a=u.indexOf(p.charAt(r)),s|=a<<18-6*r;for(r=0;r<p.length-1;r+=1){for(l=d+h,c=l>>>2;m.length<=c;)m.push(0);m[c]|=(s>>>16-8*r&255)<<8*(f+i*(l%4)),d+=1}}return{value:m,binLen:8*d+n}}(e,t,i,n)};case"BYTES":return function(e,t,i){return function(e,t,n,i){let a,o,r,s;const p=t||[0],c=(n=n||0)>>>3,l=-1===i?3:0;for(o=0;o<e.length;o+=1)a=e.charCodeAt(o),s=o+c,r=s>>>2,p.length<=r&&p.push(0),p[r]|=a<<8*(l+i*(s%4));return{value:p,binLen:8*e.length+n}}(e,t,i,n)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(i){throw new Error(f)}return function(e,t,i){return function(e,t,n,i){return v(new Uint8Array(e),t,n,i)}(e,t,i,n)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(i){throw new Error(g)}return function(e,t,i){return v(e,t,i,n)};default:throw new Error("format must be HEX, TEXT, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function x(e,t,n,i){switch(e){case"HEX":return function(e){return function(e,t,n,i){const a="0123456789abcdef";let o,r,s="";const p=t/8,c=-1===n?3:0;for(o=0;o<p;o+=1)r=e[o>>>2]>>>8*(c+n*(o%4)),s+=a.charAt(r>>>4&15)+a.charAt(15&r);return i.outputUpper?s.toUpperCase():s}(e,t,n,i)};case"B64":return function(e){return function(e,t,n,i){let a,o,r,s,p,c="";const l=t/8,d=-1===n?3:0;for(a=0;a<l;a+=3)for(s=a+1<l?e[a+1>>>2]:0,p=a+2<l?e[a+2>>>2]:0,r=(e[a>>>2]>>>8*(d+n*(a%4))&255)<<16|(s>>>8*(d+n*((a+1)%4))&255)<<8|p>>>8*(d+n*((a+2)%4))&255,o=0;o<4;o+=1)c+=8*a+6*o<=t?u.charAt(r>>>6*(3-o)&63):i.b64Pad;return c}(e,t,n,i)};case"BYTES":return function(e){return function(e,t,n){let i,a,o="";const r=t/8,s=-1===n?3:0;for(i=0;i<r;i+=1)a=e[i>>>2]>>>8*(s+n*(i%4))&255,o+=String.fromCharCode(a);return o}(e,t,n)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(a){throw new Error(f)}return function(e){return function(e,t,n){let i;const a=t/8,o=new ArrayBuffer(a),r=new Uint8Array(o),s=-1===n?3:0;for(i=0;i<a;i+=1)r[i]=e[i>>>2]>>>8*(s+n*(i%4))&255;return o}(e,t,n)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(a){throw new Error(g)}return function(e){return function(e,t,n){let i;const a=t/8,o=-1===n?3:0,r=new Uint8Array(a);for(i=0;i<a;i+=1)r[i]=e[i>>>2]>>>8*(o+n*(i%4))&255;return r}(e,t,n)};default:throw new Error("format must be HEX, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}const y=4294967296,b=[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],k=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428],C=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],S="Chosen SHA variant is not supported",A="Cannot set numRounds with MAC";function O(e,t){let n,i;const a=e.binLen>>>3,o=t.binLen>>>3,r=a<<3,s=4-a<<3;if(a%4!=0){for(n=0;n<o;n+=4)i=a+n>>>2,e.value[i]|=t.value[n>>>2]<<r,e.value.push(0),e.value[i+1]|=t.value[n>>>2]>>>s;return(e.value.length<<2)-4>=o+a&&e.value.pop(),{value:e.value,binLen:e.binLen+t.binLen}}return{value:e.value.concat(t.value),binLen:e.binLen+t.binLen}}function U(e){const t={outputUpper:!1,b64Pad:"=",outputLen:-1},n=e||{},i="Output length must be a multiple of 8";if(t.outputUpper=n.outputUpper||!1,n.b64Pad&&(t.b64Pad=n.b64Pad),n.outputLen){if(n.outputLen%8!=0)throw new Error(i);t.outputLen=n.outputLen}else if(n.shakeLen){if(n.shakeLen%8!=0)throw new Error(i);t.outputLen=n.shakeLen}if("boolean"!=typeof t.outputUpper)throw new Error("Invalid outputUpper formatting option");if("string"!=typeof t.b64Pad)throw new Error("Invalid b64Pad formatting option");return t}function E(e,t,n,i){const a=e+" must include a value and format";if(!t){if(!i)throw new Error(a);return i}if(void 0===t.value||!t.format)throw new Error(a);return w(t.format,t.encoding||"UTF8",n)(t.value)}class T{constructor(e,t,i){n(this,"shaVariant"),n(this,"inputFormat"),n(this,"utfType"),n(this,"numRounds"),n(this,"keyWithIPad"),n(this,"keyWithOPad"),n(this,"remainder"),n(this,"remainderLen"),n(this,"updateCalled"),n(this,"processedLen"),n(this,"macKeySet");const a=i||{};if(this.inputFormat=t,this.utfType=a.encoding||"UTF8",this.numRounds=a.numRounds||1,isNaN(this.numRounds)||this.numRounds!==parseInt(this.numRounds,10)||1>this.numRounds)throw new Error("numRounds must a integer >= 1");this.shaVariant=e,this.remainder=[],this.remainderLen=0,this.updateCalled=!1,this.processedLen=0,this.macKeySet=!1,this.keyWithIPad=[],this.keyWithOPad=[]}update(e){let t,n=0;const i=this.variantBlockSize>>>5,a=this.converterFunc(e,this.remainder,this.remainderLen),o=a.binLen,r=a.value,s=o>>>5;for(t=0;t<s;t+=i)n+this.variantBlockSize<=o&&(this.intermediateState=this.roundFunc(r.slice(t,t+i),this.intermediateState),n+=this.variantBlockSize);return this.processedLen+=n,this.remainder=r.slice(n>>>5),this.remainderLen=o%this.variantBlockSize,this.updateCalled=!0,this}getHash(e,t){let n,i,a=this.outputBinLen;const o=U(t);if(this.isVariableLen){if(-1===o.outputLen)throw new Error("Output length must be specified in options");a=o.outputLen}const r=x(e,a,this.bigEndianMod,o);if(this.macKeySet&&this.getMAC)return r(this.getMAC(o));for(i=this.finalizeFunc(this.remainder.slice(),this.remainderLen,this.processedLen,this.stateCloneFunc(this.intermediateState),a),n=1;n<this.numRounds;n+=1)this.isVariableLen&&a%32!=0&&(i[i.length-1]&=16777215>>>24-a%32),i=this.finalizeFunc(i,a,0,this.newStateFunc(this.shaVariant),a);return r(i)}setHMACKey(e,t,n){if(!this.HMACSupported)throw new Error("Variant does not support HMAC");if(this.updateCalled)throw new Error("Cannot set MAC key after calling update");const i=w(t,(n||{}).encoding||"UTF8",this.bigEndianMod);this._setHMACKey(i(e))}_setHMACKey(e){const t=this.variantBlockSize>>>3,n=t/4-1;let i;if(1!==this.numRounds)throw new Error(A);if(this.macKeySet)throw new Error("MAC key already set");for(t<e.binLen/8&&(e.value=this.finalizeFunc(e.value,e.binLen,0,this.newStateFunc(this.shaVariant),this.outputBinLen));e.value.length<=n;)e.value.push(0);for(i=0;i<=n;i+=1)this.keyWithIPad[i]=909522486^e.value[i],this.keyWithOPad[i]=1549556828^e.value[i];this.intermediateState=this.roundFunc(this.keyWithIPad,this.intermediateState),this.processedLen=this.variantBlockSize,this.macKeySet=!0}getHMAC(e,t){const n=U(t);return x(e,this.outputBinLen,this.bigEndianMod,n)(this._getHMAC())}_getHMAC(){let e;if(!this.macKeySet)throw new Error("Cannot call getHMAC without first setting MAC key");const t=this.finalizeFunc(this.remainder.slice(),this.remainderLen,this.processedLen,this.stateCloneFunc(this.intermediateState),this.outputBinLen);return e=this.roundFunc(this.keyWithOPad,this.newStateFunc(this.shaVariant)),e=this.finalizeFunc(t,this.outputBinLen,this.variantBlockSize,e,this.outputBinLen),e}}function B(e,t){return e<<t|e>>>32-t}function M(e,t){return e>>>t|e<<32-t}function L(e,t){return e>>>t}function F(e,t,n){return e^t^n}function R(e,t,n){return e&t^~e&n}function H(e,t,n){return e&t^e&n^t&n}function z(e){return M(e,2)^M(e,13)^M(e,22)}function D(e,t){const n=(65535&e)+(65535&t);return(65535&(e>>>16)+(t>>>16)+(n>>>16))<<16|65535&n}function j(e,t,n,i){const a=(65535&e)+(65535&t)+(65535&n)+(65535&i);return(65535&(e>>>16)+(t>>>16)+(n>>>16)+(i>>>16)+(a>>>16))<<16|65535&a}function P(e,t,n,i,a){const o=(65535&e)+(65535&t)+(65535&n)+(65535&i)+(65535&a);return(65535&(e>>>16)+(t>>>16)+(n>>>16)+(i>>>16)+(a>>>16)+(o>>>16))<<16|65535&o}function I(e){return M(e,7)^M(e,18)^L(e,3)}function q(e){return M(e,6)^M(e,11)^M(e,25)}function N(e){return[1732584193,4023233417,2562383102,271733878,3285377520]}function K(e,t){let n,i,a,o,r,s,p;const c=[];for(n=t[0],i=t[1],a=t[2],o=t[3],r=t[4],p=0;p<80;p+=1)c[p]=p<16?e[p]:B(c[p-3]^c[p-8]^c[p-14]^c[p-16],1),s=p<20?P(B(n,5),R(i,a,o),r,1518500249,c[p]):p<40?P(B(n,5),F(i,a,o),r,1859775393,c[p]):p<60?P(B(n,5),H(i,a,o),r,2400959708,c[p]):P(B(n,5),F(i,a,o),r,3395469782,c[p]),r=o,o=a,a=B(i,30),i=n,n=s;return t[0]=D(n,t[0]),t[1]=D(i,t[1]),t[2]=D(a,t[2]),t[3]=D(o,t[3]),t[4]=D(r,t[4]),t}function $(e,t,n,i){let a;const o=15+(t+65>>>9<<4),r=t+n;for(;e.length<=o;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[o]=4294967295&r,e[o-1]=r/y|0,a=0;a<e.length;a+=16)i=K(e.slice(a,a+16),i);return i}let V=class extends T{constructor(e,t,i){if("SHA-1"!==e)throw new Error(S);super(e,t,i),n(this,"intermediateState"),n(this,"variantBlockSize"),n(this,"bigEndianMod"),n(this,"outputBinLen"),n(this,"isVariableLen"),n(this,"HMACSupported"),n(this,"converterFunc"),n(this,"roundFunc"),n(this,"finalizeFunc"),n(this,"stateCloneFunc"),n(this,"newStateFunc"),n(this,"getMAC");const a=i||{};this.HMACSupported=!0,this.getMAC=this._getHMAC,this.bigEndianMod=-1,this.converterFunc=w(this.inputFormat,this.utfType,this.bigEndianMod),this.roundFunc=K,this.stateCloneFunc=function(e){return e.slice()},this.newStateFunc=N,this.finalizeFunc=$,this.intermediateState=[1732584193,4023233417,2562383102,271733878,3285377520],this.variantBlockSize=512,this.outputBinLen=160,this.isVariableLen=!1,a.hmacKey&&this._setHMACKey(E("hmacKey",a.hmacKey,this.bigEndianMod))}};function _(e){let t;return t="SHA-224"===e?k.slice():C.slice(),t}function Y(e,t){let n,i,a,o,r,s,p,c,l,d,m;const h=[];for(n=t[0],i=t[1],a=t[2],o=t[3],r=t[4],s=t[5],p=t[6],c=t[7],m=0;m<64;m+=1)h[m]=m<16?e[m]:j(M(u=h[m-2],17)^M(u,19)^L(u,10),h[m-7],I(h[m-15]),h[m-16]),l=P(c,q(r),R(r,s,p),b[m],h[m]),d=D(z(n),H(n,i,a)),c=p,p=s,s=r,r=D(o,l),o=a,a=i,i=n,n=D(l,d);var u;return t[0]=D(n,t[0]),t[1]=D(i,t[1]),t[2]=D(a,t[2]),t[3]=D(o,t[3]),t[4]=D(r,t[4]),t[5]=D(s,t[5]),t[6]=D(p,t[6]),t[7]=D(c,t[7]),t}let X=class extends T{constructor(e,t,i){if("SHA-224"!==e&&"SHA-256"!==e)throw new Error(S);super(e,t,i),n(this,"intermediateState"),n(this,"variantBlockSize"),n(this,"bigEndianMod"),n(this,"outputBinLen"),n(this,"isVariableLen"),n(this,"HMACSupported"),n(this,"converterFunc"),n(this,"roundFunc"),n(this,"finalizeFunc"),n(this,"stateCloneFunc"),n(this,"newStateFunc"),n(this,"getMAC");const a=i||{};this.getMAC=this._getHMAC,this.HMACSupported=!0,this.bigEndianMod=-1,this.converterFunc=w(this.inputFormat,this.utfType,this.bigEndianMod),this.roundFunc=Y,this.stateCloneFunc=function(e){return e.slice()},this.newStateFunc=_,this.finalizeFunc=function(t,n,i,a){return function(e,t,n,i,a){let o,r;const s=15+(t+65>>>9<<4),p=t+n;for(;e.length<=s;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[s]=4294967295&p,e[s-1]=p/y|0,o=0;o<e.length;o+=16)i=Y(e.slice(o,o+16),i);return r="SHA-224"===a?[i[0],i[1],i[2],i[3],i[4],i[5],i[6]]:i,r}(t,n,i,a,e)},this.intermediateState=_(e),this.variantBlockSize=512,this.outputBinLen="SHA-224"===e?224:256,this.isVariableLen=!1,a.hmacKey&&this._setHMACKey(E("hmacKey",a.hmacKey,this.bigEndianMod))}};class W{constructor(e,t){n(this,"highOrder"),n(this,"lowOrder"),this.highOrder=e,this.lowOrder=t}}function G(e,t){let n;return t>32?(n=64-t,new W(e.lowOrder<<t|e.highOrder>>>n,e.highOrder<<t|e.lowOrder>>>n)):0!==t?(n=32-t,new W(e.highOrder<<t|e.lowOrder>>>n,e.lowOrder<<t|e.highOrder>>>n)):e}function J(e,t){let n;return t<32?(n=32-t,new W(e.highOrder>>>t|e.lowOrder<<n,e.lowOrder>>>t|e.highOrder<<n)):(n=64-t,new W(e.lowOrder>>>t|e.highOrder<<n,e.highOrder>>>t|e.lowOrder<<n))}function Q(e,t){return new W(e.highOrder>>>t,e.lowOrder>>>t|e.highOrder<<32-t)}function Z(e,t,n){return new W(e.highOrder&t.highOrder^e.highOrder&n.highOrder^t.highOrder&n.highOrder,e.lowOrder&t.lowOrder^e.lowOrder&n.lowOrder^t.lowOrder&n.lowOrder)}function ee(e){const t=J(e,28),n=J(e,34),i=J(e,39);return new W(t.highOrder^n.highOrder^i.highOrder,t.lowOrder^n.lowOrder^i.lowOrder)}function te(e,t){let n,i;n=(65535&e.lowOrder)+(65535&t.lowOrder),i=(e.lowOrder>>>16)+(t.lowOrder>>>16)+(n>>>16);const a=(65535&i)<<16|65535&n;n=(65535&e.highOrder)+(65535&t.highOrder)+(i>>>16),i=(e.highOrder>>>16)+(t.highOrder>>>16)+(n>>>16);return new W((65535&i)<<16|65535&n,a)}function ne(e,t,n,i){let a,o;a=(65535&e.lowOrder)+(65535&t.lowOrder)+(65535&n.lowOrder)+(65535&i.lowOrder),o=(e.lowOrder>>>16)+(t.lowOrder>>>16)+(n.lowOrder>>>16)+(i.lowOrder>>>16)+(a>>>16);const r=(65535&o)<<16|65535&a;a=(65535&e.highOrder)+(65535&t.highOrder)+(65535&n.highOrder)+(65535&i.highOrder)+(o>>>16),o=(e.highOrder>>>16)+(t.highOrder>>>16)+(n.highOrder>>>16)+(i.highOrder>>>16)+(a>>>16);return new W((65535&o)<<16|65535&a,r)}function ie(e,t,n,i,a){let o,r;o=(65535&e.lowOrder)+(65535&t.lowOrder)+(65535&n.lowOrder)+(65535&i.lowOrder)+(65535&a.lowOrder),r=(e.lowOrder>>>16)+(t.lowOrder>>>16)+(n.lowOrder>>>16)+(i.lowOrder>>>16)+(a.lowOrder>>>16)+(o>>>16);const s=(65535&r)<<16|65535&o;o=(65535&e.highOrder)+(65535&t.highOrder)+(65535&n.highOrder)+(65535&i.highOrder)+(65535&a.highOrder)+(r>>>16),r=(e.highOrder>>>16)+(t.highOrder>>>16)+(n.highOrder>>>16)+(i.highOrder>>>16)+(a.highOrder>>>16)+(o>>>16);return new W((65535&r)<<16|65535&o,s)}function ae(e,t){return new W(e.highOrder^t.highOrder,e.lowOrder^t.lowOrder)}function oe(e){const t=J(e,19),n=J(e,61),i=Q(e,6);return new W(t.highOrder^n.highOrder^i.highOrder,t.lowOrder^n.lowOrder^i.lowOrder)}function re(e){const t=J(e,1),n=J(e,8),i=Q(e,7);return new W(t.highOrder^n.highOrder^i.highOrder,t.lowOrder^n.lowOrder^i.lowOrder)}function se(e){const t=J(e,14),n=J(e,18),i=J(e,41);return new W(t.highOrder^n.highOrder^i.highOrder,t.lowOrder^n.lowOrder^i.lowOrder)}const pe=[new W(b[0],3609767458),new W(b[1],602891725),new W(b[2],3964484399),new W(b[3],2173295548),new W(b[4],4081628472),new W(b[5],3053834265),new W(b[6],2937671579),new W(b[7],3664609560),new W(b[8],2734883394),new W(b[9],1164996542),new W(b[10],1323610764),new W(b[11],3590304994),new W(b[12],4068182383),new W(b[13],991336113),new W(b[14],633803317),new W(b[15],3479774868),new W(b[16],2666613458),new W(b[17],944711139),new W(b[18],2341262773),new W(b[19],2007800933),new W(b[20],1495990901),new W(b[21],1856431235),new W(b[22],3175218132),new W(b[23],2198950837),new W(b[24],3999719339),new W(b[25],766784016),new W(b[26],2566594879),new W(b[27],3203337956),new W(b[28],1034457026),new W(b[29],2466948901),new W(b[30],3758326383),new W(b[31],168717936),new W(b[32],1188179964),new W(b[33],1546045734),new W(b[34],1522805485),new W(b[35],2643833823),new W(b[36],2343527390),new W(b[37],1014477480),new W(b[38],1206759142),new W(b[39],344077627),new W(b[40],1290863460),new W(b[41],3158454273),new W(b[42],3505952657),new W(b[43],106217008),new W(b[44],3606008344),new W(b[45],1432725776),new W(b[46],1467031594),new W(b[47],851169720),new W(b[48],3100823752),new W(b[49],1363258195),new W(b[50],3750685593),new W(b[51],3785050280),new W(b[52],3318307427),new W(b[53],3812723403),new W(b[54],2003034995),new W(b[55],3602036899),new W(b[56],1575990012),new W(b[57],1125592928),new W(b[58],2716904306),new W(b[59],442776044),new W(b[60],593698344),new W(b[61],3733110249),new W(b[62],2999351573),new W(b[63],3815920427),new W(3391569614,3928383900),new W(3515267271,566280711),new W(3940187606,3454069534),new W(4118630271,4000239992),new W(116418474,1914138554),new W(174292421,2731055270),new W(289380356,3203993006),new W(460393269,320620315),new W(685471733,587496836),new W(852142971,1086792851),new W(1017036298,365543100),new W(1126000580,2618297676),new W(1288033470,3409855158),new W(1501505948,4234509866),new W(1607167915,987167468),new W(1816402316,1246189591)];function ce(e){return"SHA-384"===e?[new W(3418070365,k[0]),new W(1654270250,k[1]),new W(2438529370,k[2]),new W(355462360,k[3]),new W(1731405415,k[4]),new W(41048885895,k[5]),new W(3675008525,k[6]),new W(1203062813,k[7])]:[new W(C[0],4089235720),new W(C[1],2227873595),new W(C[2],4271175723),new W(C[3],1595750129),new W(C[4],2917565137),new W(C[5],725511199),new W(C[6],4215389547),new W(C[7],327033209)]}function le(e,t){let n,i,a,o,r,s,p,c,l,d,m,h;const u=[];for(n=t[0],i=t[1],a=t[2],o=t[3],r=t[4],s=t[5],p=t[6],c=t[7],m=0;m<80;m+=1)m<16?(h=2*m,u[m]=new W(e[h],e[h+1])):u[m]=ne(oe(u[m-2]),u[m-7],re(u[m-15]),u[m-16]),l=ie(c,se(r),(g=s,v=p,new W((f=r).highOrder&g.highOrder^~f.highOrder&v.highOrder,f.lowOrder&g.lowOrder^~f.lowOrder&v.lowOrder)),pe[m],u[m]),d=te(ee(n),Z(n,i,a)),c=p,p=s,s=r,r=te(o,l),o=a,a=i,i=n,n=te(l,d);var f,g,v;return t[0]=te(n,t[0]),t[1]=te(i,t[1]),t[2]=te(a,t[2]),t[3]=te(o,t[3]),t[4]=te(r,t[4]),t[5]=te(s,t[5]),t[6]=te(p,t[6]),t[7]=te(c,t[7]),t}let de=class extends T{constructor(e,t,i){if("SHA-384"!==e&&"SHA-512"!==e)throw new Error(S);super(e,t,i),n(this,"intermediateState"),n(this,"variantBlockSize"),n(this,"bigEndianMod"),n(this,"outputBinLen"),n(this,"isVariableLen"),n(this,"HMACSupported"),n(this,"converterFunc"),n(this,"roundFunc"),n(this,"finalizeFunc"),n(this,"stateCloneFunc"),n(this,"newStateFunc"),n(this,"getMAC");const a=i||{};this.getMAC=this._getHMAC,this.HMACSupported=!0,this.bigEndianMod=-1,this.converterFunc=w(this.inputFormat,this.utfType,this.bigEndianMod),this.roundFunc=le,this.stateCloneFunc=function(e){return e.slice()},this.newStateFunc=ce,this.finalizeFunc=function(t,n,i,a){return function(e,t,n,i,a){let o,r;const s=31+(t+129>>>10<<5),p=t+n;for(;e.length<=s;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[s]=4294967295&p,e[s-1]=p/y|0,o=0;o<e.length;o+=32)i=le(e.slice(o,o+32),i);return r="SHA-384"===a?[i[0].highOrder,i[0].lowOrder,i[1].highOrder,i[1].lowOrder,i[2].highOrder,i[2].lowOrder,i[3].highOrder,i[3].lowOrder,i[4].highOrder,i[4].lowOrder,i[5].highOrder,i[5].lowOrder]:[i[0].highOrder,i[0].lowOrder,i[1].highOrder,i[1].lowOrder,i[2].highOrder,i[2].lowOrder,i[3].highOrder,i[3].lowOrder,i[4].highOrder,i[4].lowOrder,i[5].highOrder,i[5].lowOrder,i[6].highOrder,i[6].lowOrder,i[7].highOrder,i[7].lowOrder],r}(t,n,i,a,e)},this.intermediateState=ce(e),this.variantBlockSize=1024,this.outputBinLen="SHA-384"===e?384:512,this.isVariableLen=!1,a.hmacKey&&this._setHMACKey(E("hmacKey",a.hmacKey,this.bigEndianMod))}};const me=[new W(0,1),new W(0,32898),new W(2147483648,32906),new W(2147483648,2147516416),new W(0,32907),new W(0,2147483649),new W(2147483648,2147516545),new W(2147483648,32777),new W(0,138),new W(0,136),new W(0,2147516425),new W(0,2147483658),new W(0,2147516555),new W(2147483648,139),new W(2147483648,32905),new W(2147483648,32771),new W(2147483648,32770),new W(2147483648,128),new W(0,32778),new W(2147483648,2147483658),new W(2147483648,2147516545),new W(2147483648,32896),new W(0,2147483649),new W(2147483648,2147516424)],he=[[0,36,3,41,18],[1,44,10,45,2],[62,6,43,15,61],[28,55,25,21,56],[27,20,39,8,14]];function ue(e){let t;const n=[];for(t=0;t<5;t+=1)n[t]=[new W(0,0),new W(0,0),new W(0,0),new W(0,0),new W(0,0)];return n}function fe(e){let t;const n=[];for(t=0;t<5;t+=1)n[t]=e[t].slice();return n}function ge(e,t){let n,i,a,o;const r=[],s=[];if(null!=e)for(i=0;i<e.length;i+=2)t[(i>>>1)%5][(i>>>1)/5|0]=ae(t[(i>>>1)%5][(i>>>1)/5|0],new W(e[i+1],e[i]));for(n=0;n<24;n+=1){for(o=ue(),i=0;i<5;i+=1)r[i]=(p=t[i][0],c=t[i][1],l=t[i][2],d=t[i][3],m=t[i][4],new W(p.highOrder^c.highOrder^l.highOrder^d.highOrder^m.highOrder,p.lowOrder^c.lowOrder^l.lowOrder^d.lowOrder^m.lowOrder));for(i=0;i<5;i+=1)s[i]=ae(r[(i+4)%5],G(r[(i+1)%5],1));for(i=0;i<5;i+=1)for(a=0;a<5;a+=1)t[i][a]=ae(t[i][a],s[i]);for(i=0;i<5;i+=1)for(a=0;a<5;a+=1)o[a][(2*i+3*a)%5]=G(t[i][a],he[i][a]);for(i=0;i<5;i+=1)for(a=0;a<5;a+=1)t[i][a]=ae(o[i][a],new W(~o[(i+1)%5][a].highOrder&o[(i+2)%5][a].highOrder,~o[(i+1)%5][a].lowOrder&o[(i+2)%5][a].lowOrder));t[0][0]=ae(t[0][0],me[n])}var p,c,l,d,m;return t}function ve(e){let t,n,i=0;const a=[0,0],o=[4294967295&e,e/y&2097151];for(t=6;t>=0;t--)n=o[t>>2]>>>8*t&255,0===n&&0===i||(a[i+1>>2]|=n<<8*(i+1),i+=1);return i=0!==i?i:1,a[0]|=i,{value:i+1>4?a:[a[0]],binLen:8+8*i}}function we(e){return O(ve(e.binLen),e)}function xe(e,t){let n,i=ve(t);i=O(i,e);const a=t>>>2,o=(a-i.value.length%a)%a;for(n=0;n<o;n++)i.value.push(0);return i.value}let ye=class extends T{constructor(e,t,i){let a=6,o=0;super(e,t,i),n(this,"intermediateState"),n(this,"variantBlockSize"),n(this,"bigEndianMod"),n(this,"outputBinLen"),n(this,"isVariableLen"),n(this,"HMACSupported"),n(this,"converterFunc"),n(this,"roundFunc"),n(this,"finalizeFunc"),n(this,"stateCloneFunc"),n(this,"newStateFunc"),n(this,"getMAC");const r=i||{};if(1!==this.numRounds){if(r.kmacKey||r.hmacKey)throw new Error(A);if("CSHAKE128"===this.shaVariant||"CSHAKE256"===this.shaVariant)throw new Error("Cannot set numRounds for CSHAKE variants")}switch(this.bigEndianMod=1,this.converterFunc=w(this.inputFormat,this.utfType,this.bigEndianMod),this.roundFunc=ge,this.stateCloneFunc=fe,this.newStateFunc=ue,this.intermediateState=ue(),this.isVariableLen=!1,e){case"SHA3-224":this.variantBlockSize=o=1152,this.outputBinLen=224,this.HMACSupported=!0,this.getMAC=this._getHMAC;break;case"SHA3-256":this.variantBlockSize=o=1088,this.outputBinLen=256,this.HMACSupported=!0,this.getMAC=this._getHMAC;break;case"SHA3-384":this.variantBlockSize=o=832,this.outputBinLen=384,this.HMACSupported=!0,this.getMAC=this._getHMAC;break;case"SHA3-512":this.variantBlockSize=o=576,this.outputBinLen=512,this.HMACSupported=!0,this.getMAC=this._getHMAC;break;case"SHAKE128":a=31,this.variantBlockSize=o=1344,this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=null;break;case"SHAKE256":a=31,this.variantBlockSize=o=1088,this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=null;break;case"KMAC128":a=4,this.variantBlockSize=o=1344,this._initializeKMAC(i),this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=this._getKMAC;break;case"KMAC256":a=4,this.variantBlockSize=o=1088,this._initializeKMAC(i),this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=this._getKMAC;break;case"CSHAKE128":this.variantBlockSize=o=1344,a=this._initializeCSHAKE(i),this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=null;break;case"CSHAKE256":this.variantBlockSize=o=1088,a=this._initializeCSHAKE(i),this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=null;break;default:throw new Error(S)}this.finalizeFunc=function(e,t,n,i,r){return function(e,t,n,i,a,o,r){let s,p,c=0;const l=[],d=a>>>5,m=t>>>5;for(s=0;s<m&&t>=a;s+=d)i=ge(e.slice(s,s+d),i),t-=a;for(e=e.slice(s),t%=a;e.length<d;)e.push(0);for(s=t>>>3,e[s>>2]^=o<<s%4*8,e[d-1]^=2147483648,i=ge(e,i);32*l.length<r&&(p=i[c%5][c/5|0],l.push(p.lowOrder),!(32*l.length>=r));)l.push(p.highOrder),c+=1,0==64*c%a&&(ge(null,i),c=0);return l}(e,t,0,i,o,a,r)},r.hmacKey&&this._setHMACKey(E("hmacKey",r.hmacKey,this.bigEndianMod))}_initializeCSHAKE(e,t){const n=function(e){const t=e||{};return{funcName:E("funcName",t.funcName,1,{value:[],binLen:0}),customization:E("Customization",t.customization,1,{value:[],binLen:0})}}(e||{});t&&(n.funcName=t);const i=O(we(n.funcName),we(n.customization));if(0!==n.customization.binLen||0!==n.funcName.binLen){const e=xe(i,this.variantBlockSize>>>3);for(let t=0;t<e.length;t+=this.variantBlockSize>>>5)this.intermediateState=this.roundFunc(e.slice(t,t+(this.variantBlockSize>>>5)),this.intermediateState),this.processedLen+=this.variantBlockSize;return 4}return 31}_initializeKMAC(e){const t=function(e){const t=e||{};return{kmacKey:E("kmacKey",t.kmacKey,1),funcName:{value:[1128353099],binLen:32},customization:E("Customization",t.customization,1,{value:[],binLen:0})}}(e||{});this._initializeCSHAKE(e,t.funcName);const n=xe(we(t.kmacKey),this.variantBlockSize>>>3);for(let i=0;i<n.length;i+=this.variantBlockSize>>>5)this.intermediateState=this.roundFunc(n.slice(i,i+(this.variantBlockSize>>>5)),this.intermediateState),this.processedLen+=this.variantBlockSize;this.macKeySet=!0}_getKMAC(e){const t=O({value:this.remainder.slice(),binLen:this.remainderLen},function(e){let t,n,i=0;const a=[0,0],o=[4294967295&e,e/y&2097151];for(t=6;t>=0;t--)n=o[t>>2]>>>8*t&255,0===n&&0===i||(a[i>>2]|=n<<8*i,i+=1);return i=0!==i?i:1,a[i>>2]|=i<<8*i,{value:i+1>4?a:[a[0]],binLen:8+8*i}}(e.outputLen));return this.finalizeFunc(t.value,t.binLen,this.processedLen,this.stateCloneFunc(this.intermediateState),e.outputLen)}};class be{constructor(e,t,i){if(n(this,"shaObj"),"SHA-1"===e)this.shaObj=new V(e,t,i);else if("SHA-224"===e||"SHA-256"===e)this.shaObj=new X(e,t,i);else if("SHA-384"===e||"SHA-512"===e)this.shaObj=new de(e,t,i);else{if("SHA3-224"!==e&&"SHA3-256"!==e&&"SHA3-384"!==e&&"SHA3-512"!==e&&"SHAKE128"!==e&&"SHAKE256"!==e&&"CSHAKE128"!==e&&"CSHAKE256"!==e&&"KMAC128"!==e&&"KMAC256"!==e)throw new Error(S);this.shaObj=new ye(e,t,i)}}update(e){return this.shaObj.update(e),this}getHash(e,t){return this.shaObj.getHash(e,t)}setHMACKey(e,t,n){this.shaObj.setHMACKey(e,t,n)}getHMAC(e,t){return this.shaObj.getHMAC(e,t)}}function ke(e){return e<10?`0${e}`:e}const Ce=()=>{if("undefined"!=typeof document)return performance.now();if("undefined"!=typeof process){const[e,t]=process.hrtime();return 1e3*e+t/1e6}return Date.now()},Se=e=>"[object String]"===toString.call(e);function Ae(e=8){const t="ABCDEFGHJKMNPQRSTWXYZabcdefhijkmnprstwxyz2345678";let n="";for(let i=0;i<e;i++)n+=t.charAt(Math.floor(48*Math.random()));return`${Date.now()}-${n}`}const Oe=(e,t={})=>{const{urlencoded:n=!0}=t,i=String.prototype.trim.call(e);return n?decodeURIComponent(i).replace(/"|'/g,""):i.replace(/"|'/g,"")},Ue=e=>{const t=document.cookie.split("; ");for(let n=0;n<t.length;n++){const i=t[n].split("=");if(i[0]===e)return decodeURIComponent(i[1])}return""},Ee=e=>{if("undefined"!=typeof window){if(e&&Se(e));else{const e=/\w(\.trunk|\.neibu|\.release|test)\./.exec(window.location.hostname);e&&e[1]}return"//log.chaxus.com"}};const Te=()=>"undefined"!=typeof window?{width:window.innerWidth,height:window.innerHeight}:{width:0,height:0},Be=/(?:[^\x21\x25\x26-\x3B\x3D\x3F-\x5B\x5D\x5F\x7E]|%(?:[^\da-f]|[\da-f][^\da-f]|$))+/gi,Me=/(^|[^\uD800-\uDBFF])[\uDC00-\uDFFF]|[\uD800-\uDBFF]([^\uDC00-\uDFFF]|$)/g;const Le=e=>new Promise(((t,n)=>{const i=new Image,a=(new Date).getTime();i.src=e||`https://github.com/favicon.ico?d=${a}`,i.onload=()=>{const e=(new Date).getTime();t(e-a)},i.onerror=e=>{n(e)}})),Fe=(e,...t)=>n=>new Promise(((i,a)=>{setTimeout((async()=>{try{const n=await e(...t);i(n)}catch(n){a(n)}}),n)})),Re=Math.round;class He{constructor(e){n(this,"r"),n(this,"g"),n(this,"b"),this.r=e[0],this.g=e[1],this.b=e[2]}toString(){return`rgb(${this.r},${this.g},${this.b})`}}class ze extends He{constructor(e){super(e),n(this,"a"),this.a=e[3]}toString(){return`rgba(${this.r},${this.g},${this.b},${this.a})`}}class De{constructor(e){n(this,"h"),n(this,"s"),n(this,"l"),this.h=e[0],this.s=e[1],this.l=e[2]}toString(){return`hsl(${this.h},${this.s}%,${this.l}%)`}}class je extends De{constructor(e){super(e),n(this,"a"),this.a=e[3]}toString(){return`hsla(${this.h},${this.s}%,${this.l}%,${this.a})`}}class Pe{constructor(e,t=0,i=0,a=1){if(n(this,"r"),n(this,"g"),n(this,"b"),n(this,"a"),n(this,"rgb"),n(this,"rgba"),n(this,"hex"),n(this,"hsl"),n(this,"hsla"),n(this,"h"),n(this,"s"),n(this,"l"),"string"==typeof e){let n=e;"#"!==n.charAt(0)&&(n="#"+n),n.length<7&&(n="#"+n[1]+n[1]+n[2]+n[2]+n[3]+n[3]),[e,t,i]=Ie(n)}else e instanceof Array&&(a=e[3]||a,i=e[2],t=e[1],e=e[0]);this.r=Number(e),this.g=Number(t),this.b=Number(i),this.a=a,this.rgb=new He([this.r,this.g,this.b]),this.rgba=new ze([this.r,this.g,this.b,this.a]),this.hex=Ne(this.r,this.g,this.b),this.hsl=new De(Ke(this.r,this.g,this.b)),this.h=this.hsl.h,this.s=this.hsl.s,this.l=this.hsl.l,this.hsla=new je([this.h,this.s,this.l,this.a])}setHue(e){this.h=e,this.hsl.h=e,this.hsla.h=e,this.updateFromHsl()}setSat(e){this.s=e,this.hsl.s=e,this.hsla.s=e,this.updateFromHsl()}setLum(e){this.l=e,this.hsl.l=e,this.hsla.l=e,this.updateFromHsl()}setAlpha(e){this.a=e,this.hsla.a=e,this.rgba.a=e}updateFromHsl(){this.rgb=new He(Ve(this.h,this.s,this.l)),this.r=this.rgb.r,this.g=this.rgb.g,this.b=this.rgb.b,this.rgba.r=this.rgb.r,this.rgba.g=this.rgb.g,this.rgba.b=this.rgb.b,this.hex=Ne([this.r,this.g,this.b])}}const Ie=function(e){const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]:null},qe=function(e){const t=e.toString(16);return 1===t.length?"0"+t:t},Ne=function(e,t=0,n=0){return e instanceof Array&&(n=e[2],t=e[1],e=e[0]),"#"+qe(e)+qe(t)+qe(n)},Ke=function(e,t=0,n=0){e instanceof Array&&(n=e[2],t=e[1],e=e[0]);let i,a,o,r=0;e/=255,t/=255,n/=255;const s=Math.max(e,t,n),p=Math.min(e,t,n);if(a=(s+p)/2,s===p)r=i=0;else{switch(o=s-p,i=a>.5?o/(2-s-p):o/(s+p),s){case e:r=(t-n)/o+(t<n?6:0);break;case t:r=(n-e)/o+2;break;case n:r=(e-t)/o+4}r/=6}return r=Re(360*r),i=Re(100*i),a=Re(100*a),[r,i,a]},$e=function(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e},Ve=function(e,t,n){let i,a,o,r,s;return e instanceof Array&&(n=e[2],t=e[1],e=e[0]),e=Number(e)/360,t=Number(t)/100,n=Number(n)/100,0===t?i=a=o=n:(r=n<.5?n*(1+t):n+t-n*t,s=2*n-r,i=$e(s,r,e+1/3),a=$e(s,r,e),o=$e(s,r,e-1/3)),[Re(255*i),Re(255*a),Re(255*o)]},_e=function(e,t,n){let i=0,a=0,o=0;if(0===n)return[0,0,0];t/=100,n/=100,e/=60;const r=Math.floor(e),s=e-r,p=n*(1-t),c=n*(1-t*s),l=n*(1-t*(1-s));return 0===r?(i=n,a=l,o=p):1===r?(i=c,a=n,o=p):2===r?(i=p,a=n,o=l):3===r?(i=p,a=c,o=n):4===r?(i=l,a=p,o=n):5===r&&(i=n,a=p,o=c),i=Math.floor(255*i),a=Math.floor(255*a),o=Math.floor(255*o),[i,a,o]},Ye=_e,Xe=function(e,t,n){return Ke(_e(e,t,n))};const We=e=>{let t,n=!1;return(...i)=>(n||(t="function"==typeof e?e(...i):e,n=!0,e=void 0),t)};function Ge(e={}){if("object"!=typeof e)throw new TypeError("param must be object");return Object.entries(e).reduce(((e,[t,n])=>(void 0===n||null==n||e.append(decodeURIComponent(t),decodeURIComponent(n)),e)),new URLSearchParams).toString()}function Je(e,t,n,i){if(void 0!==e&&(t in e||i)){const i=n(e[t]);"function"==typeof i&&(e[t]=i)}}const Qe=(e,t)=>{const n=Object.getOwnPropertyDescriptors(t);for(const i of Object.keys(n)){const t=n[i];if(t.get){const n=t.get;Object.defineProperty(e,i,{configurable:!1,enumerable:!0,get:We(n)})}else{if("object"!=typeof t.value)throw new Error("Exposed values must be either a getter or an nested object");Object.defineProperty(e,i,{configurable:!1,enumerable:!0,writable:!1,value:Qe({},t.value)})}}return Object.freeze(e)},Ze=(e=l)=>{["log","info","warn","error","assert"].forEach((t=>{Je(console,t,(n=>function(...i){n&&(e(t,...i),n.apply(console,i))}))}))},et=/["'&<>]/;const tt=["svg","path","g","circle","rect","line","polyline","polygon","ellipse","text","tspan","textPath","defs","marker","radialGradient","stop","linearGradient","clipPath","mask","pattern","image","use","symbol","foreignObject","feGaussianBlur","feColorMatrix"];class nt{constructor(e,t){n(this,"listener"),n(this,"element"),n(this,"create",((e,t)=>tt.includes(e)?document.createElementNS("http://www.w3.org/2000/svg",e,t):document.createElement(e,t))),n(this,"setAttribute",((e,t)=>(this.element.setAttribute(e,t),this))),n(this,"removeAttribute",(e=>(this.element.removeAttribute(e),this))),n(this,"append",(e=>(this.element.appendChild(e),this))),n(this,"remove",(e=>(this.element.removeChild(e),this))),n(this,"setTextContent",(e=>(this.element.textContent=e,this))),n(this,"setStyle",((e,t)=>(this.element.style.setProperty(e,t),this))),n(this,"addChild",(e=>{if(Array.isArray(e)){const t=document.createDocumentFragment();e.forEach((e=>t.appendChild(e.element))),this.element.appendChild(t)}else this.element.appendChild(e.element);return this})),n(this,"listen",((e,t,n)=>{let i=this.listener.get(e);i||(i=new Map,this.listener.set(e,i));const a=i.get(t.name);return a===t&&console.warn(`${a.name} listener has been added to ${e} event, please remove it first.`),this.element.addEventListener(e,t,n),i.set(t.name,t),this})),n(this,"clearListener",((e,t,n)=>{this.element.removeEventListener(e,t,n);const i=this.listener.get(e);return i?i.delete(t.name):console.warn(`No ${e} event listener has been added.`),this})),n(this,"clearAllListener",(()=>{for(const[e,t]of this.listener){for(const[n,i]of t)this.element.removeEventListener(e,i),t.delete(n);this.listener.delete(e)}return this})),this.element=this.create(e,t),this.listener=new Map}}const it=(e=l)=>{"undefined"!=typeof window&&(window.addEventListener("unhandledrejection",(t=>{e(t)}),!0),window.addEventListener("error",(t=>(e(t),!1)),!0))},at=new Map([[".ez","application/andrew-inset"],[".aw","application/applixware"],[".txt","text/plain"],[".ez","application/andrew-inset"],[".aw","application/applixware"],[".atom","application/atom+xml"],[".atomcat","application/atomcat+xml"],[".atomsvc","application/atomsvc+xml"],[".ccxml","application/ccxml+xml"],[".cu","application/cu-seeme"],[".davmount","application/davmount+xml"],[".ecma","application/ecmascript"],[".emma","application/emma+xml"],[".epub","application/epub+zip"],[".pfr","application/font-tdpfr"],[".stk","application/hyperstudio"],[".jar","application/java-archive"],[".ser","application/java-serialized-object"],[".class","application/java-vm"],[".js","application/javascript"],[".ts","application/javascript"],[".json","application/json"],[".lostxml","application/lost+xml"],[".hqx","application/mac-binhex40"],[".cpt","application/mac-compactpro"],[".mrc","application/marc"],[".ma,","application/mathematica"],[".nb","application/mathematica"],[".mb","application/mathematica"],[".mathml","application/mathml+xml"],[".mbox","application/mbox"],[".mscml","application/mediaservercontrol+xml"],[".mp4s","application/mp4"],[".doc","application/msword"],[".dot","application/msword"],[".mxf","application/mxf"],[".oda","application/oda"],[".opf","application/oebps-package+xml"],[".ogx","application/ogg"],[".onetoc","application/onenote"],[".onetoc2","application/onenote"],[".onetmp","application/onenote"],[".onepkg","application/onenote"],[".xer","application/patch-ops-error+xml"],[".pdf","application/pdf"],[".pgp","application/pgp-encrypted"],[".asc","application/pgp-signature"],[".sig","application/pgp-signature"],[".prf","application/pics-rules"],[".p10","application/pkcs10"],[".p7c","application/pkcs7-mime"],[".p7m","application/pkcs7-mime"],[".p7s","application/pkcs7-signature"],[".cer","application/pkix-cert"],[".crl","application/pkix-crl"],[".pkipath","application/pkix-pkipath"],[".pki","application/pkixcmp"],[".pls","application/pls+xml"],[".ai","application/postscript"],[".eps","application/postscript"],[".ps","application/postscript"],[".cww","application/prs.cww"],[".rdf","application/rdf+xml"],[".rif","application/reginfo+xml"],[".rnc","application/relax-ng-compact-syntax"],[".rl","application/resource-lists+xml"],[".rld","application/resource-lists-diff+xml"],[".rs","application/rls-services+xml"],[".rsd","application/rsd+xml"],[".rss","application/rss+xml"],[".rtf","application/rtf"],[".sbml","application/sbml+xml"],[".scq","application/scvp-cv-request"],[".scs","application/scvp-cv-response"],[".spq","application/scvp-vp-request"],[".spp","application/scvp-vp-response"],[".sdp","application/sdp"],[".setpay","application/set-payment-initiation"],[".setreg","application/set-registration-initiation"],[".shf","application/shf+xml"],[".smil","application/smil+xml"],[".smi","application/smil+xml"],[".rq","application/sparql-query"],[".srx","application/sparql-results+xml"],[".gram","application/srgs"],[".grxml","application/srgs+xml"],[".ssml","application/ssml+xml"],[".plb","application/vnd.3gpp.pic-bw-large"],[".psb","application/vnd.3gpp.pic-bw-small"],[".pvb","application/vnd.3gpp.pic-bw-var"],[".tcap","application/vnd.3gpp2.tcap"],[".pwn","application/vnd.3m.post-it-notes"],[".aso","application/vnd.accpac.simply.aso"],[".imp","application/vnd.accpac.simply.imp"],[".acu","application/vnd.acucobol"],[".atc","application/vnd.acucorp"],[".acutc","application/vnd.acucorp"],[".air","application/vnd.adobe.air-application-installer-package+zip"],[".xdp","application/vnd.adobe.xdp+xml"],[".xfdf","application/vnd.adobe.xfdf"],[".azf","application/vnd.airzip.filesecure.azf"],[".azs","application/vnd.airzip.filesecure.azs"],[".azw","application/vnd.amazon.ebook"],[".acc","application/vnd.americandynamics.acc"],[".ami","application/vnd.amiga.ami"],[".apk","application/vnd.android.package-archive"],[".cii","application/vnd.anser-web-certificate-issue-initiation"],[".fti","application/vnd.anser-web-funds-transfer-initiation"],[".atx","application/vnd.antix.game-component"],[".mpkg","application/vnd.apple.installer+xml"],[".swi","application/vnd.arastra.swi"],[".aep","application/vnd.audiograph"],[".mpm","application/vnd.blueice.multipass"],[".bmi","application/vnd.bmi"],[".rep","application/vnd.businessobjects"],[".cdxml","application/vnd.chemdraw+xml"],[".mmd","application/vnd.chipnuts.karaoke-mmd"],[".cdy","application/vnd.cinderella"],[".cla","application/vnd.claymore"],[".c4u","application/vnd.clonk.c4group"],[".c4p","application/vnd.clonk.c4group"],[".c4f","application/vnd.clonk.c4group"],[".c4d","application/vnd.clonk.c4group"],[".c4g","application/vnd.clonk.c4group"],[".csp","application/vnd.commonspace"],[".cdbcmsg","application/vnd.contact.cmsg"],[".cmc","application/vnd.cosmocaller"],[".clkx","application/vnd.crick.clicker"],[".clkk","application/vnd.crick.clicker.keyboard"],[".clkp","application/vnd.crick.clicker.palette"],[".clkt","application/vnd.crick.clicker.template"],[".clkw","application/vnd.crick.clicker.wordbank"],[".wbs","application/vnd.criticaltools.wbs+xml"],[".pml","application/vnd.ctc-posml"],[".ppd","application/vnd.cups-ppd"],[".car","application/vnd.curl.car"],[".pcurl","application/vnd.curl.pcurl"],[".rdz","application/vnd.data-vision.rdz"],[".fe_launch","application/vnd.denovo.fcselayout-link"],[".dna","application/vnd.dna"],[".mlp","application/vnd.dolby.mlp"],[".dpg","application/vnd.dpgraph"],[".dfac","application/vnd.dreamfactory"],[".geo","application/vnd.dynageo"],[".mag","application/vnd.ecowin.chart"],[".nml","application/vnd.enliven"],[".esf","application/vnd.epson.esf"],[".msf","application/vnd.epson.msf"],[".qam","application/vnd.epson.quickanime"],[".slt","application/vnd.epson.salt"],[".ssf","application/vnd.epson.ssf"],[".et3","application/vnd.eszigno3+xml"],[".es3","application/vnd.eszigno3+xml"],[".ez2","application/vnd.ezpix-album"],[".ez3","application/vnd.ezpix-package"],[".fdf","application/vnd.fdf"],[".mseed","application/vnd.fdsn.mseed"],[".dataless","application/vnd.fdsn.seed"],[".seed","application/vnd.fdsn.seed"],[".gph","application/vnd.flographit"],[".ftc","application/vnd.fluxtime.clip"],[".fm","application/vnd.framemaker"],[".frame","application/vnd.framemaker"],[".maker","application/vnd.framemaker"],[".book","application/vnd.framemaker"],[".fnc","application/vnd.frogans.fnc"],[".ltf","application/vnd.frogans.ltf"],[".fsc","application/vnd.fsc.weblaunch"],[".oas","application/vnd.fujitsu.oasys"],[".oa2","application/vnd.fujitsu.oasys2"],[".oa3","application/vnd.fujitsu.oasys3"],[".fg5","application/vnd.fujitsu.oasysgp"],[".bh2","application/vnd.fujitsu.oasysprs"],[".ddd","application/vnd.fujixerox.ddd"],[".xdw","application/vnd.fujixerox.docuworks"],[".xbd","application/vnd.fujixerox.docuworks.binder"],[".fzs","application/vnd.fuzzysheet"],[".txd","application/vnd.genomatix.tuxedo"],[".ggb","application/vnd.geogebra.file"],[".ggt","application/vnd.geogebra.tool"],[".gre","application/vnd.geometry-explorer"],[".gex","application/vnd.geometry-explorer"],[".gmx","application/vnd.gmx"],[".kml","application/vnd.google-earth.kml+xml"],[".kmz","application/vnd.google-earth.kmz"],[".gqf","application/vnd.grafeq"],[".gqs","application/vnd.grafeq"],[".gac","application/vnd.groove-account"],[".ghf","application/vnd.groove-help"],[".gim","application/vnd.groove-identity-message"],[".grv","application/vnd.groove-injector"],[".gtm","application/vnd.groove-tool-message"],[".tpl","application/vnd.groove-tool-template"],[".vcg","application/vnd.groove-vcard"],[".zmm","application/vnd.handheld-entertainment+xml"],[".hbci","application/vnd.hbci"],[".les","application/vnd.hhe.lesson-player"],[".hpgl","application/vnd.hp-hpgl"],[".hpid","application/vnd.hp-hpid"],[".hps","application/vnd.hp-hps"],[".jlt","application/vnd.hp-jlyt"],[".pcl","application/vnd.hp-pcl"],[".pclxl","application/vnd.hp-pclxl"],[".sfd-hdstx","application/vnd.hydrostatix.sof-data"],[".x3d","application/vnd.hzn-3d-crossword"],[".mpy","application/vnd.ibm.minipay"],[".afp","application/vnd.ibm.modcap"],[".listafp","application/vnd.ibm.modcap"],[".list3820","application/vnd.ibm.modcap"],[".irm","application/vnd.ibm.rights-management"],[".sc","application/vnd.ibm.secure-container"],[".icm","application/vnd.iccprofile"],[".icc","application/vnd.iccprofile"],[".igl","application/vnd.igloader"],[".ivp","application/vnd.immervision-ivp"],[".ivu","application/vnd.immervision-ivu"],[".xpw","application/vnd.intercon.formnet"],[".xpx","application/vnd.intercon.formnet"],[".qbo","application/vnd.intu.qbo"],[".qfx","application/vnd.intu.qfx"],[".rcprofile","application/vnd.ipunplugged.rcprofile"],[".irp","application/vnd.irepository.package+xml"],[".xpr","application/vnd.is-xpr"],[".jam","application/vnd.jam"],[".rms","application/vnd.jcp.javame.midlet-rms"],[".jisp","application/vnd.jisp"],[".joda","application/vnd.joost.joda-archive"],[".ktz","application/vnd.kahootz"],[".ktr","application/vnd.kahootz"],[".karbon","application/vnd.kde.karbon"],[".chrt","application/vnd.kde.kchart"],[".kfo","application/vnd.kde.kformula"],[".flw","application/vnd.kde.kivio"],[".kon","application/vnd.kde.kontour"],[".kpt","application/vnd.kde.kpresenter"],[".kpr","application/vnd.kde.kpresenter"],[".ksp","application/vnd.kde.kspread"],[".kwd","application/vnd.kde.kword"],[".kwt","application/vnd.kde.kword"],[".htke","application/vnd.kenameaapp"],[".kia","application/vnd.kidspiration"],[".kne","application/vnd.kinar"],[".knp","application/vnd.kinar"],[".skp","application/vnd.koan"],[".skd","application/vnd.koan"],[".skt","application/vnd.koan"],[".skm","application/vnd.koan"],[".sse","application/vnd.kodak-descriptor"],[".lbd","application/vnd.llamagraphics.life-balance.desktop"],[".lbe","application/vnd.llamagraphics.life-balance.exchange+xml"],[".123","application/vnd.lotus-1-2-3"],[".apr","application/vnd.lotus-approach"],[".pre","application/vnd.lotus-freelance"],[".nsf","application/vnd.lotus-notes"],[".org","application/vnd.lotus-organizer"],[".scm","application/vnd.lotus-screencam"],[".lwp","application/vnd.lotus-wordpro"],[".portpkg","application/vnd.macports.portpkg"],[".mcd","application/vnd.mcd"],[".mc1","application/vnd.medcalcdata"],[".cdkey","application/vnd.mediastation.cdkey"],[".mwf","application/vnd.mfer"],[".mfm","application/vnd.mfmp"],[".flo","application/vnd.micrografx.flo"],[".igx","application/vnd.micrografx.igx"],[".mif","application/vnd.mif"],[".daf","application/vnd.mobius.daf"],[".dis","application/vnd.mobius.dis"],[".mbk","application/vnd.mobius.mbk"],[".mqy","application/vnd.mobius.mqy"],[".msl","application/vnd.mobius.msl"],[".plc","application/vnd.mobius.plc"],[".txf","application/vnd.mobius.txf"],[".mpn","application/vnd.mophun.application"],[".mpc","application/vnd.mophun.certificate"],[".xul","application/vnd.mozilla.xul+xml"],[".cil","application/vnd.ms-artgalry"],[".cab","application/vnd.ms-cab-compressed"],[".xls","application/vnd.ms-excel"],[".xlm","application/vnd.ms-excel"],[".xla","application/vnd.ms-excel"],[".xlc","application/vnd.ms-excel"],[".xlt","application/vnd.ms-excel"],[".xlw","application/vnd.ms-excel"],[".xlam","application/vnd.ms-excel.addin.macroenabled.12"],[".xlsb","application/vnd.ms-excel.sheet.binary.macroenabled.12"],[".xlsm","application/vnd.ms-excel.sheet.macroenabled.12"],[".xltm","application/vnd.ms-excel.template.macroenabled.12"],[".eot","application/vnd.ms-fontobject"],[".chm","application/vnd.ms-htmlhelp"],[".ims","application/vnd.ms-ims"],[".lrm","application/vnd.ms-lrm"],[".cat","application/vnd.ms-pki.seccat"],[".stl","application/vnd.ms-pki.stl"],[".pot","application/vnd.ms-powerpoint"],[".pps","application/vnd.ms-powerpoint"],[".ppt","application/vnd.ms-powerpoint"],[".ppam","application/vnd.ms-powerpoint.addin.macroenabled.12"],[".pptm","application/vnd.ms-powerpoint.presentation.macroenabled.12"],[".sldm","application/vnd.ms-powerpoint.slide.macroenabled.12"],[".ppsm","application/vnd.ms-powerpoint.slideshow.macroenabled.12"],[".potm","application/vnd.ms-powerpoint.template.macroenabled.12"],[".mpp","application/vnd.ms-project"],[".mpt","application/vnd.ms-project"],[".docm","application/vnd.ms-word.document.macroenabled.12"],[".dotm","application/vnd.ms-word.template.macroenabled.12"],[".wdb","application/vnd.ms-works"],[".wcm","application/vnd.ms-works"],[".wks","application/vnd.ms-works"],[".wps","application/vnd.ms-works"],[".wpl","application/vnd.ms-wpl"],[".xps","application/vnd.ms-xpsdocument"],[".mseq","application/vnd.mseq"],[".mus","application/vnd.musician"],[".msty","application/vnd.muvee.style"],[".nlu","application/vnd.neurolanguage.nlu"],[".nnd","application/vnd.noblenet-directory"],[".nns","application/vnd.noblenet-sealer"],[".nnw","application/vnd.noblenet-web"],[".ngdat","application/vnd.nokia.n-gage.data"],[".n-gage","application/vnd.nokia.n-gage.symbian.install"],[".rpst","application/vnd.nokia.radio-preset"],[".rpss","application/vnd.nokia.radio-presets"],[".edm","application/vnd.novadigm.edm"],[".edx","application/vnd.novadigm.edx"],[".ext","application/vnd.novadigm.ext"],[".odc","application/vnd.oasis.opendocument.chart"],[".otc","application/vnd.oasis.opendocument.chart-template"],[".odb","application/vnd.oasis.opendocument.database"],[".odf","application/vnd.oasis.opendocument.formula"],[".odft","application/vnd.oasis.opendocument.formula-template"],[".odg","application/vnd.oasis.opendocument.graphics"],[".otg","application/vnd.oasis.opendocument.graphics-template"],[".odi","application/vnd.oasis.opendocument.image"],[".oti","application/vnd.oasis.opendocument.image-template"],[".odp","application/vnd.oasis.opendocument.presentation"],[".ods","application/vnd.oasis.opendocument.spreadsheet"],[".ots","application/vnd.oasis.opendocument.spreadsheet-template"],[".odt","application/vnd.oasis.opendocument.text"],[".otm","application/vnd.oasis.opendocument.text-master"],[".ott","application/vnd.oasis.opendocument.text-template"],[".oth","application/vnd.oasis.opendocument.text-web"],[".xo","application/vnd.olpc-sugar"],[".dd2","application/vnd.oma.dd2+xml"],[".oxt","application/vnd.openofficeorg.extension"],[".pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],[".sldx","application/vnd.openxmlformats-officedocument.presentationml.slide"],[".ppsx","application/vnd.openxmlformats-officedocument.presentationml.slideshow"],[".potx","application/vnd.openxmlformats-officedocument.presentationml.template"],[".xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],[".xltx","application/vnd.openxmlformats-officedocument.spreadsheetml.template"],[".docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],[".dotx","application/vnd.openxmlformats-officedocument.wordprocessingml.template"],[".dp","application/vnd.osgi.dp"],[".oprc","application/vnd.palm"],[".pqa","application/vnd.palm"],[".pdb","application/vnd.palm"],[".str","application/vnd.pg.format"],[".ei6","application/vnd.pg.osasli"],[".efif","application/vnd.picsel"],[".plf","application/vnd.pocketlearn"],[".pbd","application/vnd.powerbuilder6"],[".box","application/vnd.previewsystems.box"],[".mgz","application/vnd.proteus.magazine"],[".qps","application/vnd.publishare-delta-tree"],[".ptid","application/vnd.pvi.ptid1"],[".qxd","application/vnd.quark.quarkxpress"],[".qxt","application/vnd.quark.quarkxpress"],[".qwd","application/vnd.quark.quarkxpress"],[".qwt","application/vnd.quark.quarkxpress"],[".qxl","application/vnd.quark.quarkxpress"],[".qxb","application/vnd.quark.quarkxpress"],[".mxl","application/vnd.recordare.musicxml"],[".musicxml","application/vnd.recordare.musicxml+xml"],[".cod","application/vnd.rim.cod"],[".rm","application/vnd.rn-realmedia"],[".link66","application/vnd.route66.link66+xml"],[".see","application/vnd.seemail"],[".sema","application/vnd.sema"],[".semd","application/vnd.semd"],[".semf","application/vnd.semf"],[".ifm","application/vnd.shana.informed.formdata"],[".itp","application/vnd.shana.informed.formtemplate"],[".iif","application/vnd.shana.informed.interchange"],[".ipk","application/vnd.shana.informed.package"],[".twds","application/vnd.simtech-mindmapper"],[".twd","application/vnd.simtech-mindmapper"],[".mmf","application/vnd.smaf"],[".teacher","application/vnd.smart.teacher"],[".sdkm","application/vnd.solent.sdkm+xml"],[".sdkd","application/vnd.solent.sdkm+xml"],[".dxp","application/vnd.spotfire.dxp"],[".sfs","application/vnd.spotfire.sfs"],[".sdc","application/vnd.stardivision.calc"],[".sda","application/vnd.stardivision.draw"],[".sdd","application/vnd.stardivision.impress"],[".smf","application/vnd.stardivision.math"],[".sdw","application/vnd.stardivision.writer"],[".vor","application/vnd.stardivision.writer"],[".sgl","application/vnd.stardivision.writer-global"],[".sxc","application/vnd.sun.xml.calc"],[".stc","application/vnd.sun.xml.calc.template"],[".sxd","application/vnd.sun.xml.draw"],[".std","application/vnd.sun.xml.draw.template"],[".sxi","application/vnd.sun.xml.impress"],[".sti","application/vnd.sun.xml.impress.template"],[".sxm","application/vnd.sun.xml.math"],[".sxw","application/vnd.sun.xml.writer"],[".sxg","application/vnd.sun.xml.writer.global"],[".stw","application/vnd.sun.xml.writer.template"],[".susp","application/vnd.sus-calendar"],[".sus","application/vnd.sus-calendar"],[".svd","application/vnd.svd"],[".sis","application/vnd.symbian.install"],[".sisx","application/vnd.symbian.install"],[".xsm","application/vnd.syncml+xml"],[".bdm","application/vnd.syncml.dm+wbxml"],[".xdm","application/vnd.syncml.dm+xml"],[".tao","application/vnd.tao.intent-module-archive"],[".tmo","application/vnd.tmobile-livetv"],[".tpt","application/vnd.trid.tpt"],[".mxs","application/vnd.triscape.mxs"],[".tra","application/vnd.trueapp"],[".ufdl","application/vnd.ufdl"],[".ufd","application/vnd.ufdl"],[".utz","application/vnd.uiq.theme"],[".umj","application/vnd.umajin"],[".unityweb","application/vnd.unity"],[".uoml","application/vnd.uoml+xml"],[".vcx","application/vnd.vcx"],[".vsw","application/vnd.visio"],[".vss","application/vnd.visio"],[".vst","application/vnd.visio"],[".vsd","application/vnd.visio"],[".vis","application/vnd.visionary"],[".vsf","application/vnd.vsf"],[".wbxml","application/vnd.wap.wbxml"],[".wmlc","application/vnd.wap.wmlc"],[".wmlsc","application/vnd.wap.wmlscriptc"],[".wtb","application/vnd.webturbo"],[".wpd","application/vnd.wordperfect"],[".wqd","application/vnd.wqd"],[".stf","application/vnd.wt.stf"],[".xar","application/vnd.xara"],[".xfdl","application/vnd.xfdl"],[".hvd","application/vnd.yamaha.hv-dic"],[".hvs","application/vnd.yamaha.hv-script"],[".hvp","application/vnd.yamaha.hv-voice"],[".osf","application/vnd.yamaha.openscoreformat"],[".osfpvg","application/vnd.yamaha.openscoreformat.osfpvg+xml"],[".saf","application/vnd.yamaha.smaf-audio"],[".spf","application/vnd.yamaha.smaf-phrase"],[".cmp","application/vnd.yellowriver-custom-menu"],[".zir","application/vnd.zul"],[".zirz","application/vnd.zul"],[".zaz","application/vnd.zzazz.deck+xml"],[".vxml","application/voicexml+xml"],[".hlp","application/winhlp"],[".wsdl","application/wsdl+xml"],[".wspolicy","application/wspolicy+xml"],[".abw","application/x-abiword"],[".ace","application/x-ace-compressed"],[".aab","application/x-authorware-bin"],[".x32","application/x-authorware-bin"],[".u32","application/x-authorware-bin"],[".vox","application/x-authorware-bin"],[".aam","application/x-authorware-map"],[".aas","application/x-authorware-seg"],[".bcpio","application/x-bcpio"],[".torrent","application/x-bittorrent"],[".bz","application/x-bzip"],[".bz2","application/x-bzip2"],[".boz","application/x-bzip2"],[".vcd","application/x-cdlink"],[".chat","application/x-chat"],[".pgn","application/x-chess-pgn"],[".cpio","application/x-cpio"],[".csh","application/x-csh"],[".deb","application/x-debian-package"],[".udeb","application/x-debian-package"],[".swa","application/x-director"],[".w3d","application/x-director"],[".fgd","application/x-director"],[".cxt","application/x-director"],[".cct","application/x-director"],[".cst","application/x-director"],[".dxr","application/x-director"],[".dcr","application/x-director"],[".dir","application/x-director"],[".wad","application/x-doom"],[".ncx","application/x-dtbncx+xml"],[".dtb","application/x-dtbook+xml"],[".res","application/x-dtbresource+xml"],[".dvi","application/x-dvi"],[".bdf","application/x-font-bdf"],[".gsf","application/x-font-ghostscript"],[".psf","application/x-font-linux-psf"],[".otf","application/x-font-otf"],[".pcf","application/x-font-pcf"],[".snf","application/x-font-snf"],[".ttf","application/x-font-ttf"],[".ttc","application/x-font-ttf"],[".woff","application/font-woff"],[".pfa","application/x-font-type1"],[".pfb","application/x-font-type1"],[".pfm","application/x-font-type1"],[".afm","application/x-font-type1"],[".spl","application/x-futuresplash"],[".gnumeric","application/x-gnumeric"],[".gtar","application/x-gtar"],[".hdf","application/x-hdf"],[".jnlp","application/x-java-jnlp-file"],[".latex","application/x-latex"],[".prc","application/x-mobipocket-ebook"],[".mobi","application/x-mobipocket-ebook"],[".application","application/x-ms-application"],[".wmd","application/x-ms-wmd"],[".wmz","application/x-ms-wmz"],[".xbap","application/x-ms-xbap"],[".mdb","application/x-msaccess"],[".obd","application/x-msbinder"],[".crd","application/x-mscardfile"],[".clp","application/x-msclip"],[".msi","application/x-msdownload"],[".bat","application/x-msdownload"],[".com","application/x-msdownload"],[".dll","application/x-msdownload"],[".exe","application/x-msdownload"],[".mvb","application/x-msmediaview"],[".m13","application/x-msmediaview"],[".m14","application/x-msmediaview"],[".wmf","application/x-msmetafile"],[".mny","application/x-msmoney"],[".pub","application/x-mspublisher"],[".scd","application/x-msschedule"],[".trm","application/x-msterminal"],[".wri","application/x-mswrite"],[".nc","application/x-netcdf"],[".cdf","application/x-netcdf"],[".p12","application/x-pkcs12"],[".pfx","application/x-pkcs12"],[".p7b","application/x-pkcs7-certificates"],[".spc","application/x-pkcs7-certificates"],[".p7r","application/x-pkcs7-certreqresp"],[".rar","application/x-rar-compressed"],[".sh","application/x-sh"],[".shar","application/x-shar"],[".swf","application/x-shockwave-flash"],[".xap","application/x-silverlight-app"],[".sit","application/x-stuffit"],[".sitx","application/x-stuffitx"],[".sv4cpio","application/x-sv4cpio"],[".sv4crc","application/x-sv4crc"],[".tar","application/x-tar"],[".tcl","application/x-tcl"],[".tex","application/x-tex"],[".tfm","application/x-tex-tfm"],[".texinfo","application/x-texinfo"],[".texi","application/x-texinfo"],[".ustar","application/x-ustar"],[".src","application/x-wais-source"],[".der","application/x-x509-ca-cert"],[".crt","application/x-x509-ca-cert"],[".fig","application/x-xfig"],[".xpi","application/x-xpinstall"],[".xenc","application/xenc+xml"],[".xhtml","application/xhtml+xml"],[".xht","application/xhtml+xml"],[".xsl","application/xml"],[".xml","application/xml"],[".dtd","application/xml-dtd"],[".xop","application/xop+xml"],[".xslt","application/xslt+xml"],[".xspf","application/xspf+xml"],[".xvm","application/xv+xml"],[".xvml","application/xv+xml"],[".xhvml","application/xv+xml"],[".mxml","application/xv+xml"],[".zip","application/zip"],[".adp","audio/adpcm"],[".au","audio/basic"],[".snd","audio/basic"],[".mid","audio/midi"],[".midi","audio/midi"],[".kar","audio/midi"],[".rmi","audio/midi"],[".mp4a","audio/mp4"],[".m4a","audio/mp4a-latm"],[".m4p","audio/mp4a-latm"],[".m3a","audio/mpeg"],[".m2a","audio/mpeg"],[".mp3","audio/mpeg"],[".mp2a","audio/mpeg"],[".mp2","audio/mpeg"],[".mpga","audio/mpeg"],[".spx","audio/ogg"],[".ogg","audio/ogg"],[".oga","audio/ogg"],[".eol","audio/vnd.digital-winds"],[".dts","audio/vnd.dts"],[".dtshd","audio/vnd.dts.hd"],[".lvp","audio/vnd.lucent.voice"],[".pya","audio/vnd.ms-playready.media.pya"],[".ecelp4800","audio/vnd.nuera.ecelp4800"],[".ecelp7470","audio/vnd.nuera.ecelp7470"],[".ecelp9600","audio/vnd.nuera.ecelp9600"],[".aac","audio/x-aac"],[".aif","audio/x-aiff"],[".aiff","audio/x-aiff"],[".aif","audio/x-aiff"],[".m3u","audio/x-mpegurl"],[".wax","audio/x-ms-wax"],[".wma","audio/x-ms-wma"],[".ram","audio/x-pn-realaudio"],[".ra","audio/x-pn-realaudio"],[".rmp","audio/x-pn-realaudio-plugin"],[".wav","audio/x-wav"],[".cdx","chemical/x-cdx"],[".cif","chemical/x-cif"],[".cmdf","chemical/x-cmdf"],[".cml","chemical/x-cml"],[".csml","chemical/x-csml"],[".xyz","chemical/x-xyz"],[".bmp","image/bmp"],[".cgm","image/cgm"],[".g3","image/g3fax"],[".gif","image/gif"],[".ief","image/ief"],[".jp2","image/jp2"],[".jpeg","image/jpeg"],[".jpg","image/jpeg"],[".jpe","image/jpeg"],[".pict","image/pict"],[".pic","image/pict"],[".pct","image/pict"],[".png","image/png"],[".btif","image/prs.btif"],[".svg","image/svg+xml"],[".svgz","image/svg+xml"],[".tiff","image/tiff"],[".tif","image/tiff"],[".psd","image/vnd.adobe.photoshop"],[".djvu","image/vnd.djvu"],[".djv","image/vnd.djvu"],[".dwg","image/vnd.dwg"],[".dxf","image/vnd.dxf"],[".fbs","image/vnd.fastbidsheet"],[".fpx","image/vnd.fpx"],[".fst","image/vnd.fst"],[".mmr","image/vnd.fujixerox.edmics-mmr"],[".rlc","image/vnd.fujixerox.edmics-rlc"],[".mdi","image/vnd.ms-modi"],[".npx","image/vnd.net-fpx"],[".wbmp","image/vnd.wap.wbmp"],[".xif","image/vnd.xiff"],[".ras","image/x-cmu-raster"],[".cmx","image/x-cmx"],[".fh","image/x-freehand"],[".fhc","image/x-freehand"],[".fh4","image/x-freehand"],[".fh5","image/x-freehand"],[".fh7","image/x-freehand"],[".ico","image/x-icon"],[".pntg","image/x-macpaint"],[".pnt","image/x-macpaint"],[".mac","image/x-macpaint"],[".pcx","image/x-pcx"],[".pic","image/x-pict"],[".pct","image/x-pict"],[".pnm","image/x-portable-anymap"],[".pbm","image/x-portable-bitmap"],[".pgm","image/x-portable-graymap"],[".ppm","image/x-portable-pixmap"],[".qtif","image/x-quicktime"],[".qti","image/x-quicktime"],[".rgb","image/x-rgb"],[".xbm","image/x-xbitmap"],[".xpm","image/x-xpixmap"],[".xwd","image/x-xwindowdump"],[".eml","message/rfc822"],[".mime","message/rfc822"],[".igs","model/iges"],[".iges","model/iges"],[".msh","model/mesh"],[".mesh","model/mesh"],[".silo","model/mesh"],[".dwf","model/vnd.dwf"],[".gdl","model/vnd.gdl"],[".gtw","model/vnd.gtw"],[".mts","model/vnd.mts"],[".vtu","model/vnd.vtu"],[".wrl","model/vrml"],[".vrml","model/vrml"],[".ics","text/calendar"],[".ifb","text/calendar"],[".css","text/css"],[".csv","text/csv"],[".html","text/html"],[".htm","text/html"],[".txt","text/plain"],[".text","text/plain"],[".conf","text/plain"],[".def","text/plain"],[".list","text/plain"],[".log","text/plain"],[".in","text/plain"],[".dsc","text/prs.lines.tag"],[".rtx","text/richtext"],[".sgml","text/sgml"],[".sgm","text/sgml"],[".tsv","text/tab-separated-values"],[".t","text/troff"],[".tr","text/troff"],[".roff","text/troff"],[".man","text/troff"],[".me","text/troff"],[".ms","text/troff"],[".uri","text/uri-list"],[".uris","text/uri-list"],[".urls","text/uri-list"],[".curl","text/vnd.curl"],[".dcurl","text/vnd.curl.dcurl"],[".scurl","text/vnd.curl.scurl"],[".mcurl","text/vnd.curl.mcurl"],[".fly","text/vnd.fly"],[".flx","text/vnd.fmi.flexstor"],[".gv","text/vnd.graphviz"],[".3dml","text/vnd.in3d.3dml"],[".spot","text/vnd.in3d.spot"],[".jad","text/vnd.sun.j2me.app-descriptor"],[".wml","text/vnd.wap.wml"],[".wmls","text/vnd.wap.wmlscript"],[".s","text/x-asm"],[".asm","text/x-asm"],[".c","text/x-c"],[".cc","text/x-c"],[".cxx","text/x-c"],[".cpp","text/x-c"],[".h","text/x-c"],[".hh","text/x-c"],[".dic","text/x-c"],[".f","text/x-fortran"],[".for","text/x-fortran"],[".f77","text/x-fortran"],[".f90","text/x-fortran"],[".p","text/x-pascal"],[".pas","text/x-pascal"],[".java","text/x-java-source"],[".etx","text/x-setext"],[".uu","text/x-uuencode"],[".vcs","text/x-vcalendar"],[".vcf","text/x-vcard"],[".3gp","video/3gpp"],[".3g2","video/3gpp2"],[".h261","video/h261"],[".h263","video/h263"],[".h264","video/h264"],[".jpgv","video/jpeg"],[".jpm","video/jpm"],[".jpgm","video/jpm"],[".mj2","video/mj2"],[".mjp2","video/mj2"],[".mp4","video/mp4"],[".mp4v","video/mp4"],[".mpg4","video/mp4"],[".m4v","video/mp4"],[".mkv","video/x-matroska"],[".mk3d","video/x-matroska"],[".mka","video/x-matroska"],[".mks","video/x-matroska"],[".webm","video/webm"],[".mpeg","video/mpeg"],[".mpg","video/mpeg"],[".mpe","video/mpeg"],[".m1v","video/mpeg"],[".m2v","video/mpeg"],[".ogv","video/ogg"],[".qt","video/quicktime"],[".mov","video/quicktime"],[".fvt","video/vnd.fvt"],[".mxu","video/vnd.mpegurl"],[".m4u","video/vnd.mpegurl"],[".pyv","video/vnd.ms-playready.media.pyv"],[".viv","video/vnd.vivo"],[".dv","video/x-dv"],[".dif","video/x-dv"],[".f4v","video/x-f4v"],[".fli","video/x-fli"],[".flv","video/x-flv"],[".m4v","video/x-m4v"],[".asf","video/x-ms-asf"],[".asx","video/x-ms-asf"],[".wm","video/x-ms-wm"],[".wmv","video/x-ms-wmv"],[".wmx","video/x-ms-wmx"],[".wvx","video/x-ms-wvx"],[".avi","video/x-msvideo"],[".movie","video/x-sgi-movie"],[".ice","x-conference/x-cooltalk"],[".indd","application/x-indesign"],[".dat","application/octet-stream"],[".gz","application/x-gzip"],[".tgz","application/x-tar"],[".tar","application/x-tar"],[".epub","application/epub+zip"],[".mobi","application/x-mobipocket-ebook"],["README","text/plain"],["LICENSE","text/plain"],["COPYING","text/plain"],["TODO","text/plain"],["ABOUT","text/plain"],["AUTHORS","text/plain"],["CONTRIBUTORS","text/plain"],["manifest","text/cache-manifest"],[".manifest","text/cache-manifest"],[".mf","text/cache-manifest"],[".appcache","text/cache-manifest"]]);function ot(){if("undefined"!=typeof window){const[e]=performance.getEntriesByType("navigation"),[t={},n={}]=performance.getEntriesByType("paint"),{startTime:i}=t,{startTime:a}=n,{domainLookupEnd:o,domainLookupStart:r,connectEnd:s,connectStart:p,secureConnectionStart:c,loadEventStart:l,domInteractive:d,domContentLoadedEventEnd:m,duration:h,responseStart:u,requestStart:f,responseEnd:g,fetchStart:v,transferSize:w,encodedBodySize:x,redirectEnd:y,redirectStart:b,redirectCount:k}=e;return{dnsSearch:o-r,tcpConnect:s-p,sslConnect:s-c,request:u-f,response:g-u,parseDomTree:d-g,resource:l-m,domReady:m-v,interactive:d-v,complete:l-v,httpHead:w-x,redirect:k,redirectTime:y-b,duration:h,fp:i,fcp:a}}}const rt=({url:e="",type:t="application/json; charset=UTF-8",payload:n={}})=>{const i=e||Ee();return"undefined"!=typeof navigator?(({url:e="",type:t="application/json; charset=UTF-8",payload:n={}})=>{const i=e||Ee();if(navigator.sendBeacon&&i){const e=new Blob([JSON.stringify(n)],{type:t});return navigator.sendBeacon(i,e)}})({url:i,type:t,payload:n}):(({url:e="",payload:t={}})=>{const n=e||Ee();if("undefined"!=typeof document&&n){const e=new Image;e.width=1,e.height=1,e.src=`${n}?${Ge(t)}`}})({url:i,payload:n})};function st(e={}){if("undefined"!=typeof window){const{width:t,height:n}=Te();return Object.assign({},{id:Ae(),path:window.location.href,time:Date.now(),referrer:document.referrer,ip:window.returnCitySN||{cid:"",cip:"",cname:""},userId:Ue("chaxus_prod"),ratio:`${t}x${n}`,userAgent:window.navigator.userAgent},e)}return{}}const pt=(e={})=>{if("undefined"!=typeof window){const{requestHook:t=l,responseHook:n=l,errorHook:i=l}=e;Je(window,"fetch",(e=>(a,o)=>(t(a,o),e.apply(window,[a,o]).then((e=>(n(a,o,e),e))).catch((e=>{throw i(a,e),e})))))}},ct=(e={})=>{if("undefined"!=typeof window){const t=XMLHttpRequest.prototype,{requestHook:n=l,responseHook:i=l,errorHook:a=l}=e;Je(t,"open",(e=>function(...t){n(t),e.apply(this,t)}));Je(t,"send",(e=>function(...t){this.addEventListener("loadend",(function(){i(this)})),this.addEventListener("error",(function(){a(this)})),e.apply(this,t)}))}},lt=(e,t=300)=>{let n;return function(){const i=this,a=arguments;n||(n=setTimeout((()=>{n=null,e.apply(i,a)}),t))}};const dt=new Map([[100,"Continue"],[101,"Switching Protocols"],[102,"Processing"],[103,"Early Hints"],[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,"Too Early"],[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"]]),mt={message:dt,code:function(e){const t=new Map;for(const[n,i]of e)t.set(i.toLowerCase(),n);return t}(dt),codes:function(e){const t=[];for(const[n,i]of e)t.push(n);return t}(dt),redirect:{300:!0,301:!0,302:!0,303:!0,305:!0,307:!0,308:!0},empty:{204:!0,205:!0,304:!0},retry:{502:!0,503:!0,504:!0}};function ht(e){if(!mt.message.has(e))throw new Error("invalid status code: "+e);return mt.message.get(e)}const ut=class{constructor(){n(this,"getDecimalLength",(e=>{const[t,n]=e.toString().split(".");return n?n.length:0})),n(this,"amend",((e,t=15)=>parseFloat(Number(e).toPrecision(t)))),n(this,"power",((e,t)=>Math.pow(10,Math.max(this.getDecimalLength(e),this.getDecimalLength(t)))))}};n(ut,"handleMethod",((e,t)=>{const n=new ut,{power:i,amend:a}=n,o=i(e,t),r=a(e*o),s=a(t*o);return e=>{switch(e){case"+":return(r+s)/o;case"-":return(r-s)/o;case"*":return r*s/(o*o);case"/":return r/s}}})),n(ut,"add",((e,t)=>ut.handleMethod(e,t)("+"))),n(ut,"divide",((e,t)=>ut.handleMethod(e,t)("/"))),n(ut,"multiply",((e,t)=>ut.handleMethod(e,t)("*"))),n(ut,"subtract",((e,t)=>ut.handleMethod(e,t)("-")));let ft=ut;const gt="NEW_LISTENER";e.AudioRecorder=class{constructor(){n(this,"startTime"),n(this,"chunks"),n(this,"mediaRecorder"),n(this,"blob"),this.startTime=Date.now(),this.chunks=[],navigator.mediaDevices.getUserMedia({audio:!0}).then((e=>{this.init(e)})).catch((e=>{}))}init(e){var t,n;const i=function(){const e=["audio/webm","audio/mp4","audio/ogg","audio/wav","audio/aac"];for(let t=0;t<e.length;t++)if(MediaRecorder.isTypeSupported(e[t]))return e[t]}();this.mediaRecorder=new MediaRecorder(e,{mimeType:i}),null==(t=this.mediaRecorder)||t.addEventListener("dataavailable",(async e=>{var t;if(e.data.size>0&&this.chunks.push(e.data),"inactive"===(null==(t=this.mediaRecorder)?void 0:t.state)){const e=Date.now()-this.startTime;this.blob=new Blob(this.chunks,{type:i}),"audio/webm"===i&&(this.blob=await((e,t,n="video/webm")=>new Promise(((i,a)=>{try{const o=new FileReader;o.addEventListener("loadend",(()=>{try{const a=o.result,r=new c(new Uint8Array(a));r.fixDuration(t)?i(r.toBlob(n)):i(e)}catch(r){a(r)}})),o.addEventListener("error",(()=>a())),o.readAsArrayBuffer(e)}catch(o){a(o)}})))(this.blob,e,this.blob.type)),this.chunks=[]}})),null==(n=this.mediaRecorder)||n.start()}start(){var e;return"paused"===(null==(e=this.mediaRecorder)?void 0:e.state)&&this.mediaRecorder.resume(),this.mediaRecorder}pause(){var e;return"recording"===(null==(e=this.mediaRecorder)?void 0:e.state)&&this.mediaRecorder.pause(),this.mediaRecorder}stop(){var e;return null==(e=this.mediaRecorder)||e.stop(),this.blob}},e.Chain=nt,e.Color=Pe,e.ColorScheme=class{constructor(e,t){n(this,"palette"),this.palette=[],void 0===t&&e instanceof Array?this.createFromColors(e):this.createFromAngles(e,t)}createFromColors(e){for(const t in e)Object.prototype.hasOwnProperty.call(e,t)&&this.palette.push(new Pe(e[t]));return this.palette}createFromAngles(e,t){this.palette.push(new Pe(e));for(const n in t)if(Object.prototype.hasOwnProperty.call(t,n)){const e=(Number(this.palette[0].h)+t[n])%360;this.palette.push(new Pe(Ve(e,Number(this.palette[0].s),Number(this.palette[0].l))))}return this.palette}static Compl(e){return new this(e,[180])}static Triad(e){return new this(e,[120,240])}static Tetrad(e){return new this(e,[60,180,240])}static Analog(e){return new this(e,[-45,45])}static Split(e){return new this(e,[150,210])}static Accent(e){return new this(e,[-45,45,180])}},e.FMT={bold:["[1m","[22m"],dim:["[2m","[22m"],reset:["[0m","[0m"],italic:["[3m","[23m"],underline:["[4m","[24m"],inverse:["[7m","[27m"],hidden:["[8m","[28m"],strikethrough:["[9m","[29m"],black:["[30m","[39m"],red:["[31m","[39m"],green:["[32m","[39m"],yellow:["[33m","[39m"],blue:["[34m","[39m"],magenta:["[35m","[39m"],cyan:["[36m","[39m"],white:["[37m","[39m"],gray:["[90m","[39m"],bgBlack:["[40m","[49m"],bgRed:["[41m","[49m"],bgGreen:["[42m","[49m"],bgYellow:["[43m","[49m"],bgBlue:["[44m","[49m"],bgMagenta:["[45m","[49m"],bgCyan:["[46m","[49m"],bgWhite:["[47m","[49m"]},e.Hsl=De,e.Hsla=je,e.Mathjs=ft,e.MimeType=at,e.Monitor=class{constructor(){n(this,"init",(()=>{this.reportClick(),this.reportError(),this.reportFetch(),this.reportPerformance(),this.reportXhr()})),this.initialize()}reportPerformance(){const e=ot(),t=st();rt({payload:{...e,...t}})}log(e){rt({payload:e})}reportClick(){const e=lt(rt),t=st();((e=l)=>{"undefined"!=typeof document&&document.addEventListener("click",(function(t){e(t)}),!0)})((n=>{const{pageX:i,pageY:a,screenX:o,screenY:r,type:s}=n;e({payload:{...t,data:{pageX:i,pageY:a,screenX:o,screenY:r,type:s},type:"click"}})}))}reportXhr(){const e=lt(rt),t=st();ct({requestHook:(...n)=>{e({payload:{...t,data:{...n},type:"xhrRequest"}})},responseHook:(...n)=>{e({payload:{...t,data:{...n},type:"xhrResponse"}})},errorHook:(...n)=>{e({payload:{...t,data:{...n},type:"xhrError"}})}})}reportFetch(){const e=lt(rt),t=st();pt({requestHook:(...n)=>{e({payload:{...t,data:{...n},type:"fetchRequest"}})},responseHook:(...n)=>{e({payload:{...t,data:{...n},type:"fetchResponse"}})},errorHook:(...n)=>{e({payload:{...t,data:{...n},type:"fetchError"}})}})}reportError(){const e=lt(rt),t=st();it(((...n)=>{e({payload:{...t,data:{...n},type:"error"}})}))}reportConsole(){const e=lt(rt),t=st();Ze(((...n)=>{e({payload:{...t,data:{...n},type:"console"}})}))}initialize(){"undefined"==typeof window||window.ranlog||(window.ranlog=!0,this.init()),"undefined"==typeof process||process.ranlog||(process.ranlog=!0,this.init())}},e.QuestQueue=class{constructor({simultaneous:e,total:t}){n(this,"current"),n(this,"queue"),n(this,"simultaneous"),n(this,"executed"),n(this,"total"),n(this,"add",(e=>{if("function"!=typeof e)return;this.queue.push((()=>new Promise(((t,n)=>{this.current++,e().then(t).catch(n).finally((()=>{this.current--,this.running()}))}))))})),n(this,"running",(()=>new Promise(((e,t)=>{if(this.current<=this.simultaneous&&this.queue.length){const n=this.queue.pop();n&&n().then(e).catch(t).finally((()=>{this.executed++}))}else e({})})))),n(this,"allSettled",(()=>{let e=0;return new Promise(((t,n)=>{const i=[];if(this.current<this.simultaneous&&this.queue.length){const a=this.queue.pop();e++,a&&a().then((n=>{i[e]=n,t(n)})).catch((t=>{i[e]=t,n(t)})).finally((()=>{this.executed++}))}this.executed>=this.total&&t(i)}))})),this.current=0,this.queue=[],this.simultaneous=e,this.executed=0,this.total=t}},e.Rgb=He,e.Rgba=ze,e.SyncHook=class{constructor(){n(this,"_events"),n(this,"tap",((e,t)=>{this._events[e]&&e!==Symbol.for(gt)&&this.call(Symbol.for(gt),e);const n=this._events[e]||[];return"function"==typeof t?n.push({name:e,callback:t}):n.push(t),this._events[e]=n,this})),n(this,"call",((e,...t)=>{(this._events[e]||[]).forEach((e=>{const{callback:n}=e;n(...t)}))})),n(this,"callSync",(async(e,...t)=>{const n=this._events[e]||[];for(const i of n){const{callback:e}=i;await e(...t)}})),n(this,"once",((e,t)=>{let n;if("function"==typeof t)n={name:e,callback:(...i)=>{t(...i),this.off(e,n)},initialCallback:t};else{const{callback:i}=t;n={name:e,callback:(...t)=>{i(...t),this.off(e,n)},initialCallback:i}}return this.tap(e,n),this})),n(this,"off",((e,t)=>{const n=(this._events[e]||[]).filter((e=>{if("function"==typeof t)return e.callback!==t&&e.initialCallback!==t;{const{callback:n}=t;return e.callback!==n&&e.initialCallback!==n}}));return this._events[e]=n,this})),this._events={}}},e.TOTP=class{static generate(e,t){const n={digits:6,algorithm:"SHA-1",period:30,timestamp:Date.now(),...t},i=Math.floor(n.timestamp/1e3),a=this.leftpad(this.dec2hex(Math.floor(i/n.period)),16,"0"),o=new be(n.algorithm,"HEX");o.setHMACKey(this.base32tohex(e),"HEX"),o.update(a);const r=o.getHMAC("HEX"),s=this.hex2dec(r.substring(r.length-1));let p=(this.hex2dec(r.substr(2*s,8))&this.hex2dec("7fffffff"))+"";const c=Math.max(p.length-n.digits,0);p=p.substring(c,c+n.digits);return{otp:p,expires:Math.ceil((n.timestamp+1)/(1e3*n.period))*n.period*1e3}}static hex2dec(e){return parseInt(e,16)}static dec2hex(e){return(e<15.5?"0":"")+Math.round(e).toString(16)}static base32tohex(e){let t="",n="";const i=e.replace(/=+$/,"");for(let a=0;a<i.length;a++){const n="ABCDEFGHIJKLMNOPQRSTUVWXYZ234567".indexOf(e.charAt(a).toUpperCase());if(-1===n)throw new Error("Invalid base32 character in key");t+=this.leftpad(n.toString(2),5,"0")}for(let a=0;a+8<=t.length;a+=8){const e=t.substr(a,8);n+=this.leftpad(parseInt(e,2).toString(16),2,"0")}return n}static leftpad(e,t,n){return t+1>=e.length&&(e=Array(t+1-e.length).join(n)+e),e}},e.addClassToElement=(e,t)=>{if("undefined"==typeof document)return;const n=e.classList;n.contains(t)||n.add(t)},e.appendUrl=function(e,t={}){let n=e;0===n.indexOf("//")&&(n=n.replace("//","https://"));const i=new URL(n);return t&&Object.keys(t).forEach((e=>{t[e]&&i.searchParams.set(e,t[e])})),i.href},e.audioVendor=()=>new Promise(((e,t)=>{h||t("window is undefined");const n=new(window.OfflineAudioContext||window.webkitOfflineAudioContext)(1,44100,44100),i=n.createOscillator();i.type="triangle",i.frequency.setValueAtTime(1e4,n.currentTime);const a=n.createDynamicsCompressor();!function(e,t){if(Array.prototype.forEach&&e.forEach===Array.prototype.forEach)e.forEach(t);else if(e.length===+e.length)for(let n=0,i=e.length;n<i;n++)t(e[n],n,e);else for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&t(e[n],Number(n),e)}([["threshold",-50],["knee",40],["ratio",12],["reduction",-20],["attack",0],["release",.25]],(function(e){if(a[e[0]]&&"number"!=typeof a[e[0]]){const{setValueAtTime:t}=a[e[0]];t(e[1],n.currentTime)}})),i.connect(a),a.connect(n.destination),i.start(0),n.startRendering();const o=setTimeout((function(){return n.oncomplete=()=>{},t("audioTimeout"),"audioTimeout"}),100);n.oncomplete=n=>{try{clearTimeout(o);const t=n.renderedBuffer.getChannelData(0).slice(4500,5e3).reduce((function(e,t){return e+Math.abs(t)}),0).toString();return i.disconnect(),a.disconnect(),e(t),t}catch(r){return void t(r)}}})),e.canvasVendor=()=>{const e=document.createElement("canvas"),t=e.getContext("2d"),n="BrowserLeaks,com <canvas> 1.0";if(!t)return null;t.textBaseline="top",t.font="14px 'Arial'",t.textBaseline="alphabetic",t.fillStyle="#f60",t.fillRect(125,1,62,20),t.fillStyle="#069",t.fillText(n,2,15),t.fillStyle="rgba(102, 204, 0, 0.7)",t.fillText(n,4,17);return e.toDataURL()},e.changeHumpToLowerCase=function(e){const t=e.split("");return e=t.map((e=>e.toUpperCase()===e?"_"+e.toLowerCase():e)).join("")},e.clearBr=(e="")=>0===e.length?"":e.replace(/\s+/g,"").replace(/<\/?.+?>/g,"").replace(/[\r\n]/g,""),e.clearStr=Oe,e.componentToHex=qe,e.compose=function(e){if(!Array.isArray(e))throw new TypeError("Middleware stack must be an array!");for(const t of e)if("function"!=typeof t)throw new TypeError("Middleware must be composed of functions!");return function(t,n){let i=-1;return function a(o){if(o<=i)return Promise.reject(new Error("next() called multiple times"));i=o;let r=e[o];o===e.length&&n&&(r=n);if(!r)return Promise.resolve();try{return Promise.resolve(r(t,a.bind(null,o+1)))}catch(s){return Promise.reject(s)}}(0)}},e.connection=()=>{if("undefined"!=typeof window)return window.navigator.connection},e.convertImageToBase64=e=>new Promise(((t,n)=>{const i=new FileReader;i.onload=function(){t({success:!0,data:i.result,message:""})},i.onerror=e=>{n({success:!1,data:e,message:""})},i.readAsDataURL(e)})),e.create=(e,t)=>new nt(e,t),e.createData=st,e.createDocumentFragment=e=>{if("undefined"==typeof document)return;const t=document.createDocumentFragment();return e.forEach((e=>t.appendChild(e))),t},e.createObjectURL=async e=>{if("string"==typeof e)return e;if(e instanceof Blob)return URL.createObjectURL(e);if(e instanceof ArrayBuffer)return URL.createObjectURL(new Blob([e]));if(e instanceof Response){const t=await e.blob();return URL.createObjectURL(t)}return e},e.currentDevice=m,e.debounce=(e,t=500)=>{let n;return(...i)=>{clearTimeout(n),n=setTimeout((()=>{e.apply(void 0,i)}),t)}},e.durationHandler=Fe,e.encodeUrl=function(e){return String(e).replace(Me,"$1�$2").replace(Be,encodeURI)},e.escapeHtml=function(e){const t=""+e,n=et.exec(t);if(!n)return t;let i,a="",o=0,r=0;for(o=n.index;o<t.length;o++){switch(t.charCodeAt(o)){case 34:i=""";break;case 38:i="&";break;case 39:i="'";break;case 60:i="<";break;case 62:i=">";break;default:continue}r!==o&&(a+=t.substring(r,o)),r=o+1,a+=i}return r!==o?a+t.substring(r,o):a},e.filterObj=(e,t)=>{const n={};return Object.keys(e).forEach((i=>{t.includes(i)||(n[i]=e[i])})),n},e.formatJson=(e,t=()=>{})=>{let n="",i=0;let a=((e,t=e=>{})=>{let n="";if("[object String]"!==Object.prototype.toString.call(e))try{n=JSON.stringify(e)}catch(i){t(i)}else try{e="string"==typeof e?e.replace(/(')/g,'"'):JSON.stringify(e),n=JSON.stringify(JSON.parse(e))}catch(i){t(i)}return n})(e,t);if(!a)return a;const o=[];let r=null,s=null,p=[];return a=a.replace(/([{}])/g,"\r\n$1\r\n"),a=a.replace(/([[\]])/g,"\r\n$1\r\n"),a=a.replace(/(,)/g,"$1\r\n"),a=a.replace(/(\r\n\r\n)/g,"\r\n"),a=a.replace(/\r\n,/g,","),p=a.split("\r\n"),p.forEach((function(e,t){var n;const i=e.match(/"/g)&&(null==(n=e.match(/"/g))?void 0:n.length)||0;i%2&&!r&&(r=t),i%2&&r&&r!==t&&(s=t),r&&s&&(o.push({start:r,end:s}),r=null,s=null)})),o.reverse().forEach((function(e,t){const n=p.slice(e.start,e.end+1);p.splice(e.start,e.end+1-e.start,n.join(""))})),a=p.join("\r\n"),a=a.replace(/:\r\n\{/g,":{"),a=a.replace(/:\r\n\[/g,":["),p=a.split("\r\n"),p.forEach((function(e,t){let a=0,o=0,r="";for(e.match(/\{$/)||e.match(/\[$/)?o+=1:e.match(/\}$/)||e.match(/\]$/)||e.match(/\},$/)||e.match(/\],$/)?0!==i&&(i-=1):o=0,a=0;a<i;a++)r+=" ";n+=r+e+"\r\n",i+=o})),n.trim()},e.generateThrottle=()=>{let e;return function(t,n=300){return function(...i){e&&(clearTimeout(e),e=void 0);const a=this;e||(e=setTimeout((()=>{t.apply(a,i),clearTimeout(e),e=void 0}),n))}}},e.getAllQueryString=e=>{if("undefined"!=typeof window){const t={},n=e||window.location.href;if(n.split("?")[1]){n.split("?")[1].split("&").forEach((e=>{const[n,i]=e.split("=");n&&i&&(t[n]=decodeURIComponent(i))}))}return t}return{}},e.getCookie=Ue,e.getCookieByName=function(e){if("undefined"!=typeof window){const t=document.cookie.match(new RegExp(`(^| )${e}(?:=([^;]*))?(;|$)`));if(t&&t[2])return t[2]}return""},e.getFrame=(e=10)=>{const t=[];let n,i=0;return new Promise((a=>{const o=()=>{const r=Ce(),s=r-i;if(0!==i&&t.push(s),i=r,t.length>e){const i=t.reduce(((e,t)=>e+t));a(1/(i/e)),cancelAnimationFrame(n)}n=requestAnimationFrame(o)};t.length<=e&&(n=requestAnimationFrame(o))}))},e.getHost=Ee,e.getMime=function(e){const t=(""+e).trim().toLowerCase();let n=t.lastIndexOf(".");const i=~n?t.substring(++n):t;return at.get(`.${i}`)||at.get(i)},e.getPerformance=ot,e.getPixelRatio=e=>{const t=e.backingStorePixelRatio||e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||1;return(h&&window.devicePixelRatio||1)/t},e.getStatus=function(e){if("number"==typeof e)return ht(e);if("string"!=typeof e)throw new TypeError("code must be a number or string");const t=parseInt(e,10);return!isNaN(t)&&mt.codes.includes(t)?ht(t):function(e){const t=e.toLowerCase();if(mt.code.has(t),!mt.code.has(t))throw new Error('invalid status message: "'+e+'"');return mt.code.get(t)}(e)},e.getWindow=Te,e.handleConsole=Ze,e.handleError=it,e.handleFetchHook=pt,e.hexToRgb=Ie,e.hsbToRgb=_e,e.hslToRgb=Ve,e.hsvToHsl=Xe,e.hsvToRgb=Ye,e.hue2rgb=$e,e.imageRequest=Le,e.isBangDevice=()=>{if(!h)return!1;const e=/iphone/i.test(window.navigator.userAgent),t=window.devicePixelRatio&&2===window.devicePixelRatio,n=window.devicePixelRatio&&3===window.devicePixelRatio,i=360===window.screen.width&&780===window.screen.height,a=375===window.screen.width&&812===window.screen.height,o=390===window.screen.width&&844===window.screen.height,r=414===window.screen.width&&896===window.screen.height,s=428===window.screen.width&&926===window.screen.height;switch(!0){case e&&n&&i:case e&&n&&a:case e&&n&&o:case e&&t&&r:case e&&n&&r:case e&&n&&s:return!0;default:return!1}},e.isClient=h,e.isImageSize=(e,t,n)=>new Promise(((i,a)=>{h||a("window is undefined");const o=window.URL||window.webkitURL,r=new Image;r.onload=function(){let e=!1;t&&(e=r.width===t),n&&(e=r.height===n),o.revokeObjectURL(r.src),i(e)},r.src=o.createObjectURL(e)})),e.isMobile=()=>{if(!h)return!1;const e=window.navigator.userAgent;return!!/Android|webOS|iPhone|iPod|iPad|BlackBerry/i.test(e)},e.isString=Se,e.isWeiXin=()=>{if(h){return window.navigator.userAgent.toLowerCase().includes("micromessenger")}return!1},e.localStorageGetItem=e=>h&&localStorage.getItem(e)||"",e.localStorageSetItem=(e,t)=>{h&&localStorage.setItem(e,t)},e.mathjs=function e(t,n,i){function a(e){const[t,n]=e.toString().split(".");return n?n.length:0}const o=(e,t=15)=>parseFloat(Number(e).toPrecision(t)),r=Math.pow(10,Math.max(a(t),a(i)));let s=0;switch(t=o(t*r),i=o(i*r),n){case"+":s=(t+i)/r;break;case"-":s=(t-i)/r;break;case"*":s=t*i/(r*r);break;case"/":s=t/i}return s=o(s),{result:s,next:(t,n)=>e(s,t,n)}},e.memoize=We,e.merge=(e,t)=>{if(e&&t)for(const n in t)e[n]=t[n];return e},e.mergeExports=Qe,e.networkSpeed=async e=>{const{url:t,duration:n=3e3,count:i=5}=e;let a=0,o=0;const r=[];for(let s=0;s<i;s++){const e=Fe(Le,t),i=await e(n);r.push(i)}return a=Math.max(...r)-Math.min(...r),o=r.reduce(((e,t)=>e+t))/r.length,{ping:o,jitter:a}},e.noop=l,e.perToNum=(e="")=>{if(0===e.length)return 0;if(e.endsWith("%")){const t=Number(e.replace("%",""));return t>1?t/100:t}return Number(e)},e.performanceTime=Ce,e.querystring=Ge,e.randomColor=function(){const e="#"+Math.random().toString(16).slice(2,8);return new Pe(e)},e.randomString=Ae,e.range=(e,t=0,n=1)=>Math.min(n,Math.max(t,e)),e.removeClassToElement=(e,t)=>{if("undefined"==typeof document)return;const n=e.classList;n.contains(t)&&n.remove(t)},e.removeGhosting=e=>{const t=document.createElement("img");t.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",t.width=0,t.height=0,t.style.opacity="0",e.dataTransfer&&e.dataTransfer.setDragImage(t,0,0)},e.replaceOld=Je,e.report=rt,e.requestAnimation=e=>{if(!h)return;let t=!1;return function(){const n=this,i=arguments;t||(window.requestAnimationFrame((function(){e.apply(n,i),t=!1})),t=!0)}},e.requestUrlToBuffer=(e,t)=>new Promise((function(n,i){const a=new XMLHttpRequest;a.open(t.method||"GET",e,!0),a.responseType=t.responseType||"arraybuffer",a.onload=function(){200===a.status?n({success:!0,data:a.response,message:""}):i({success:!1,data:a.status,message:`The request status is${a.status}`})},a.onerror=function(e){i({success:!1,data:e,message:""})},a.onprogress=e=>{t.onProgress&&t.onProgress(e)},a.withCredentials=t.withCredentials||!1,t.headers&&Object.keys(t.headers).forEach((function(e){var n;(null==(n=t.headers)?void 0:n[e])&&a.setRequestHeader(e,t.headers[e])})),a.send(t.body)})),e.retain=(e=l)=>{const t=()=>{e(),h&&window.removeEventListener("popstate",t)};h&&window.history.pushState(null,"",window.location.href),setTimeout((()=>{h&&window.addEventListener("popstate",t)}),500)},e.rgbToHex=Ne,e.rgbToHsb=function(e,t,n){let i,a,o=0;e/=255,t/=255,n/=255;const r=Math.max(e,t,n),s=Math.min(e,t,n);a=r;const p=r-s;if(i=0===r?0:p/r,r===s)o=0;else{switch(r){case e:o=(t-n)/p+(t<n?6:0);break;case t:o=(n-e)/p+2;break;case n:o=(e-t)/p+4}o/=6}return o=Re(360*o),i=Re(100*i),a=Re(100*a),[o,i,a]},e.rgbToHsl=Ke,e.scriptOnLoad=(e,t,n)=>{const i=(e=Array.isArray(e)?e:[e]).map((e=>{let n;if(/\w*.css$/.test(e)){const t=document.createElement("link");t.type="text/css",t.rel="stylesheet",t.href=e,n=t}else n=document.createElement("script"),n.type="text/javascript",n.src=e;const i=document.getElementsByTagName("body")[0];return(t||i).appendChild(n),new Promise((e=>{n.onload=()=>{e()}}))}));return new Promise((e=>{Promise.all(i).then((()=>{"function"==typeof n&&n(),e()}))}))},e.setAttributeByGlobal=(e,t)=>{"undefined"!=typeof window&&(window[e]=t),"undefined"!=typeof global&&(global[e]=t)},e.setFontSize2html=(e=375)=>{let t=e;const{documentElement:n}=document,i=window.matchMedia("(orientation: portrait)");let a,o=667/375;function r(){const e=!i.matches;let a=window.screen.width,r=window.screen.height;a<r&&([a,r]=[r,a]);let s=n.clientWidth,p=r;s/p>=o?(s=p*o,n.classList.remove("adjustHeight"),n.classList.add("adjustWidth")):(p=s/o,n.classList.remove("adjustWidth"),n.classList.add("adjustHeight"));let c=s/t*16;e&&(c/=o),n.style.fontSize=`${c}px`;const l=window.getComputedStyle(n).fontSize.replace("px","")||0;c!==l&&(n.style.fontSize=c/Number(l)*c+"px")}m()===d.IPAD&&(o=1024/768,t=768),window.addEventListener("resize",(function(){clearTimeout(a),a=setTimeout(r,300)}),!1),window.addEventListener("pageshow",(function(e){e.persisted&&(clearTimeout(a),a=setTimeout(r,300))}),!1),window.addEventListener("orientationchange",(function(){r()}),!1),r()},e.setMime=(e,t)=>(at.set(e,t),at),e.status=mt,e.str2Xml=(e,t="text/xml")=>{if(window.DOMParser)return(new window.DOMParser).parseFromString(e,t).documentElement;if(void 0!==window.ActiveXObject){const t=new window.ActiveXObject("Microsoft.XMLDOM");return t.async="false",t.loadXML(e),t}},e.strParse=(e="",t="",n="")=>{const i={},a=e.split(t);return a.length>0&&a.forEach((e=>{const[t="",a=""]=e.split(n);Oe(t)&&(i[Oe(t)]=Oe(a))})),i},e.throttle=lt,e.timeFormat=e=>{if(0===e)return"00:00";if(!e)return"";const t=Math.trunc(e/3600),n=Math.trunc(e%3600/60),i=ke(Math.trunc(e-3600*t-60*n));return 0===t?`${ke(n)}:${i}`:`${ke(t)}:${ke(n)}:${i}`},e.timestampToTime=function(e){let t=new Date;return e&&(t=new Date(e)),t.format=(e="YYYY-MM-DD HH:mm:ss")=>{const n=t.getFullYear(),i=ke(t.getMonth()+1),a=ke(t.getDate()),o=ke(t.getHours()),r=ke(t.getMinutes()),s=ke(t.getSeconds());return e.replace(/Y+/gi,`${n}`).replace(/M+/g,`${i}`).replace(/D+/gi,`${a}`).replace(/H+/gi,`${o}`).replace(/m+/g,`${r}`).replace(/S+/gi,`${s}`)},t},e.webglVendor=()=>{const e=document.createElement("canvas").getContext("webgl2");return e?function(e){const t=e.getExtension("WEBGL_debug_renderer_info");return t?{vendor:e.getParameter(t.UNMASKED_VENDOR_WEBGL),renderer:e.getParameter(t.UNMASKED_RENDERER_WEBGL)}:null}(e):null},Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})}));
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).ranuts_utils={})}(this,(function(e){"use strict";var t=Object.defineProperty,n=(e,n,i)=>((e,n,i)=>n in e?t(e,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[n]=i)(e,"symbol"!=typeof n?n+"":n,i);const i={172351395:{name:"EBML",type:"Container"},646:{name:"EBMLVersion",type:"Uint"},759:{name:"EBMLReadVersion",type:"Uint"},754:{name:"EBMLMaxIDLength",type:"Uint"},755:{name:"EBMLMaxSizeLength",type:"Uint"},642:{name:"DocType",type:"String"},647:{name:"DocTypeVersion",type:"Uint"},645:{name:"DocTypeReadVersion",type:"Uint"},108:{name:"Void",type:"Binary"},63:{name:"CRC-32",type:"Binary"},190023271:{name:"SignatureSlot",type:"Container"},16010:{name:"SignatureAlgo",type:"Uint"},16026:{name:"SignatureHash",type:"Uint"},16037:{name:"SignaturePublicKey",type:"Binary"},16053:{name:"Signature",type:"Binary"},15963:{name:"SignatureElements",type:"Container"},15995:{name:"SignatureElementList",type:"Container"},9522:{name:"SignedElement",type:"Binary"},139690087:{name:"Segment",type:"Container"},21863284:{name:"SeekHead",type:"Container"},3515:{name:"Seek",type:"Container"},5035:{name:"SeekID",type:"Binary"},5036:{name:"SeekPosition",type:"Uint"},88713574:{name:"Info",type:"Container"},13220:{name:"SegmentUID",type:"Binary"},13188:{name:"SegmentFilename",type:"String"},1882403:{name:"PrevUID",type:"Binary"},1868715:{name:"PrevFilename",type:"String"},2013475:{name:"NextUID",type:"Binary"},1999803:{name:"NextFilename",type:"String"},1092:{name:"SegmentFamily",type:"Binary"},10532:{name:"ChapterTranslate",type:"Container"},10748:{name:"ChapterTranslateEditionUID",type:"Uint"},10687:{name:"ChapterTranslateCodec",type:"Uint"},10661:{name:"ChapterTranslateID",type:"Binary"},710577:{name:"TimecodeScale",type:"Uint"},1161:{name:"Duration",type:"Float"},1121:{name:"DateUTC",type:"Date"},15273:{name:"Title",type:"String"},3456:{name:"MuxingApp",type:"String"},5953:{name:"WritingApp",type:"String"},103:{name:"Timecode",type:"Uint"},6228:{name:"SilentTracks",type:"Container"},6359:{name:"SilentTrackNumber",type:"Uint"},39:{name:"Position",type:"Uint"},43:{name:"PrevSize",type:"Uint"},35:{name:"SimpleBlock",type:"Binary"},32:{name:"BlockGroup",type:"Container"},33:{name:"Block",type:"Binary"},34:{name:"BlockVirtual",type:"Binary"},13729:{name:"BlockAdditions",type:"Container"},38:{name:"BlockMore",type:"Container"},110:{name:"BlockAddID",type:"Uint"},37:{name:"BlockAdditional",type:"Binary"},27:{name:"BlockDuration",type:"Uint"},122:{name:"ReferencePriority",type:"Uint"},123:{name:"ReferenceBlock",type:"Int"},125:{name:"ReferenceVirtual",type:"Int"},36:{name:"CodecState",type:"Binary"},13730:{name:"DiscardPadding",type:"Int"},14:{name:"Slices",type:"Container"},104:{name:"TimeSlice",type:"Container"},76:{name:"LaceNumber",type:"Uint"},77:{name:"FrameNumber",type:"Uint"},75:{name:"BlockAdditionID",type:"Uint"},78:{name:"Delay",type:"Uint"},79:{name:"SliceDuration",type:"Uint"},72:{name:"ReferenceFrame",type:"Container"},73:{name:"ReferenceOffset",type:"Uint"},74:{name:"ReferenceTimeCode",type:"Uint"},47:{name:"EncryptedBlock",type:"Binary"},106212971:{name:"Tracks",type:"Container"},46:{name:"TrackEntry",type:"Container"},87:{name:"TrackNumber",type:"Uint"},13253:{name:"TrackUID",type:"Uint"},3:{name:"TrackType",type:"Uint"},57:{name:"FlagEnabled",type:"Uint"},8:{name:"FlagDefault",type:"Uint"},5546:{name:"FlagForced",type:"Uint"},28:{name:"FlagLacing",type:"Uint"},11751:{name:"MinCache",type:"Uint"},11768:{name:"MaxCache",type:"Uint"},254851:{name:"DefaultDuration",type:"Uint"},216698:{name:"DefaultDecodedFieldDuration",type:"Uint"},209231:{name:"TrackTimecodeScale",type:"Float"},4991:{name:"TrackOffset",type:"Int"},5614:{name:"MaxBlockAdditionID",type:"Uint"},4974:{name:"Name",type:"String"},177564:{name:"Language",type:"String"},6:{name:"CodecID",type:"String"},9122:{name:"CodecPrivate",type:"Binary"},362120:{name:"CodecName",type:"String"},13382:{name:"AttachmentLink",type:"Uint"},1742487:{name:"CodecSettings",type:"String"},1785920:{name:"CodecInfoURL",type:"String"},438848:{name:"CodecDownloadURL",type:"String"},42:{name:"CodecDecodeAll",type:"Uint"},12203:{name:"TrackOverlay",type:"Uint"},5802:{name:"CodecDelay",type:"Uint"},5819:{name:"SeekPreRoll",type:"Uint"},9764:{name:"TrackTranslate",type:"Container"},9980:{name:"TrackTranslateEditionUID",type:"Uint"},9919:{name:"TrackTranslateCodec",type:"Uint"},9893:{name:"TrackTranslateTrackID",type:"Binary"},96:{name:"Video",type:"Container"},26:{name:"FlagInterlaced",type:"Uint"},5048:{name:"StereoMode",type:"Uint"},5056:{name:"AlphaMode",type:"Uint"},5049:{name:"OldStereoMode",type:"Uint"},48:{name:"PixelWidth",type:"Uint"},58:{name:"PixelHeight",type:"Uint"},5290:{name:"PixelCropBottom",type:"Uint"},5307:{name:"PixelCropTop",type:"Uint"},5324:{name:"PixelCropLeft",type:"Uint"},5341:{name:"PixelCropRight",type:"Uint"},5296:{name:"DisplayWidth",type:"Uint"},5306:{name:"DisplayHeight",type:"Uint"},5298:{name:"DisplayUnit",type:"Uint"},5299:{name:"AspectRatioType",type:"Uint"},963876:{name:"ColourSpace",type:"Binary"},1029411:{name:"GammaValue",type:"Float"},230371:{name:"FrameRate",type:"Float"},97:{name:"Audio",type:"Container"},53:{name:"SamplingFrequency",type:"Float"},14517:{name:"OutputSamplingFrequency",type:"Float"},31:{name:"Channels",type:"Uint"},15739:{name:"ChannelPositions",type:"Binary"},8804:{name:"BitDepth",type:"Uint"},98:{name:"TrackOperation",type:"Container"},99:{name:"TrackCombinePlanes",type:"Container"},100:{name:"TrackPlane",type:"Container"},101:{name:"TrackPlaneUID",type:"Uint"},102:{name:"TrackPlaneType",type:"Uint"},105:{name:"TrackJoinBlocks",type:"Container"},109:{name:"TrackJoinUID",type:"Uint"},64:{name:"TrickTrackUID",type:"Uint"},65:{name:"TrickTrackSegmentUID",type:"Binary"},70:{name:"TrickTrackFlag",type:"Uint"},71:{name:"TrickMasterTrackUID",type:"Uint"},68:{name:"TrickMasterTrackSegmentUID",type:"Binary"},11648:{name:"ContentEncodings",type:"Container"},8768:{name:"ContentEncoding",type:"Container"},4145:{name:"ContentEncodingOrder",type:"Uint"},4146:{name:"ContentEncodingScope",type:"Uint"},4147:{name:"ContentEncodingType",type:"Uint"},4148:{name:"ContentCompression",type:"Container"},596:{name:"ContentCompAlgo",type:"Uint"},597:{name:"ContentCompSettings",type:"Binary"},4149:{name:"ContentEncryption",type:"Container"},2017:{name:"ContentEncAlgo",type:"Uint"},2018:{name:"ContentEncKeyID",type:"Binary"},2019:{name:"ContentSignature",type:"Binary"},2020:{name:"ContentSigKeyID",type:"Binary"},2021:{name:"ContentSigAlgo",type:"Uint"},2022:{name:"ContentSigHashAlgo",type:"Uint"},206814059:{name:"Cues",type:"Container"},59:{name:"CuePoint",type:"Container"},51:{name:"CueTime",type:"Uint"},55:{name:"CueTrackPositions",type:"Container"},119:{name:"CueTrack",type:"Uint"},113:{name:"CueClusterPosition",type:"Uint"},112:{name:"CueRelativePosition",type:"Uint"},50:{name:"CueDuration",type:"Uint"},4984:{name:"CueBlockNumber",type:"Uint"},106:{name:"CueCodecState",type:"Uint"},91:{name:"CueReference",type:"Container"},22:{name:"CueRefTime",type:"Uint"},23:{name:"CueRefCluster",type:"Uint"},4959:{name:"CueRefNumber",type:"Uint"},107:{name:"CueRefCodecState",type:"Uint"},155296873:{name:"Attachments",type:"Container"},8615:{name:"AttachedFile",type:"Container"},1662:{name:"FileDescription",type:"String"},1646:{name:"FileName",type:"String"},1632:{name:"FileMimeType",type:"String"},1628:{name:"FileData",type:"Binary"},1710:{name:"FileUID",type:"Uint"},1653:{name:"FileReferral",type:"Binary"},1633:{name:"FileUsedStartTime",type:"Uint"},1634:{name:"FileUsedEndTime",type:"Uint"},4433776:{name:"Chapters",type:"Container"},1465:{name:"EditionEntry",type:"Container"},1468:{name:"EditionUID",type:"Uint"},1469:{name:"EditionFlagHidden",type:"Uint"},1499:{name:"EditionFlagDefault",type:"Uint"},1501:{name:"EditionFlagOrdered",type:"Uint"},54:{name:"ChapterAtom",type:"Container"},13252:{name:"ChapterUID",type:"Uint"},5716:{name:"ChapterStringUID",type:"String"},17:{name:"ChapterTimeStart",type:"Uint"},18:{name:"ChapterTimeEnd",type:"Uint"},24:{name:"ChapterFlagHidden",type:"Uint"},1432:{name:"ChapterFlagEnabled",type:"Uint"},11879:{name:"ChapterSegmentUID",type:"Binary"},11964:{name:"ChapterSegmentEditionUID",type:"Uint"},9155:{name:"ChapterPhysicalEquiv",type:"Uint"},15:{name:"ChapterTrack",type:"Container"},9:{name:"ChapterTrackNumber",type:"Uint"},0:{name:"ChapterDisplay",type:"Container"},5:{name:"ChapString",type:"String"},892:{name:"ChapLanguage",type:"String"},894:{name:"ChapCountry",type:"String"},10564:{name:"ChapProcess",type:"Container"},10581:{name:"ChapProcessCodecID",type:"Uint"},1293:{name:"ChapProcessPrivate",type:"Binary"},10513:{name:"ChapProcessCommand",type:"Container"},10530:{name:"ChapProcessTime",type:"Uint"},10547:{name:"ChapProcessData",type:"Binary"},39109479:{name:"Tags",type:"Container"},13171:{name:"Tag",type:"Container"},9152:{name:"Targets",type:"Container"},10442:{name:"TargetTypeValue",type:"Uint"},9162:{name:"TargetType",type:"String"},9157:{name:"TagTrackUID",type:"Uint"},9161:{name:"TagEditionUID",type:"Uint"},9156:{name:"TagChapterUID",type:"Uint"},9158:{name:"TagAttachmentUID",type:"Uint"},10184:{name:"SimpleTag",type:"Container"},1443:{name:"TagName",type:"String"},1146:{name:"TagLanguage",type:"String"},1156:{name:"TagDefault",type:"Uint"},1159:{name:"TagString",type:"String"},1157:{name:"TagBinary",type:"Binary"}};class a{constructor(e="Unknown",t="Unknown"){n(this,"source"),n(this,"data"),this.name=e,this.type=t}updateBySource(){}setSource(e){this.source=e,this.updateBySource()}updateByData(){}setData(e){this.data=e,this.updateByData()}}function o(e){return e.length%2==1?"0"+e:e}class r extends a{constructor(e,t){super(e,t||"Uint")}updateBySource(){this.data="";for(let e=0;e<this.source.length;e++){const t=this.source[e].toString(16);this.data+=o(t)}}updateByData(){const e=this.data.length/2;this.source=new Uint8Array(e);for(let t=0;t<e;t++){const e=this.data.substr(2*t,2);this.source[t]=parseInt(e,16)}}getValue(){return parseInt(this.data,16)}setValue(e){this.setData(o(e.toString(16)))}}class s extends a{constructor(e,t){super(e,t||"Float")}getFloatArrayType(){return this.source&&4===this.source.length?Float32Array:Float64Array}updateBySource(){const e=this.source.reverse(),t=new(this.getFloatArrayType())(e.buffer);this.data=t[0]}updateByData(){const e=new(this.getFloatArrayType())([this.data]),t=new Uint8Array(e.buffer);this.source=t.reverse()}getValue(){return this.data}setValue(e){this.setData(e)}}class p extends a{constructor(e,t){super(e,t||"Container"),n(this,"offset",0),n(this,"data",[])}readByte(){return this.source[this.offset++]}readUint(){const e=this.readByte(),t=8-e.toString(2).length;let n=e-(1<<7-t);for(let i=0;i<t;i++)n*=256,n+=this.readByte();return n}updateBySource(){let e;for(this.data=[],this.offset=0;this.offset<this.source.length;this.offset=e){const t=this.readUint(),n=this.readUint();e=Math.min(this.offset+n,this.source.length);const o=this.source.slice(this.offset,e),c=i[t]||{name:"Unknown",type:"Unknown"};let l=a;switch(c.type){case"Container":l=p;break;case"Uint":l=r;break;case"Float":l=s}const d=new l(c.name,c.type);d.setSource(o),this.data.push({id:t,idHex:t.toString(16),data:d})}}writeUint(e,t=!1){let n=1,i=128;for(;e>=i&&n<8;)n++,i*=128;if(!t){let t=i+e;for(let e=n-1;e>=0;e--){const n=t%256;this.source[this.offset+e]=n,t=(t-n)/256}}this.offset+=n}writeSections(e=!1){this.offset=0;for(let t=0;t<this.data.length;t++){const n=this.data[t],i=n.data.source,a=i.length;this.writeUint(n.id,e),this.writeUint(a,e),e||this.source.set(i,this.offset),this.offset+=a}return this.offset}updateByData(){const e=this.writeSections(!0);this.source=new Uint8Array(e),this.writeSections()}getSectionById(e){for(let t=0;t<this.data.length;t++){const n=this.data[t];if(n.id===e)return n.data}}}class c extends p{constructor(e){super("File","File"),this.setSource(e)}fixDuration(e){const t=this.getSectionById(139690087);if(!t)return!1;const n=t.getSectionById(88713574);if(!n)return!1;const i=n.getSectionById(710577);if(!i)return!1;let a=n.getSectionById(1161);if(a){if(!(a.getValue()<=0))return!1;a.setValue(e)}else a=new s("Duration","Float"),a.setValue(e),n.data.push({id:1161,data:a});return i.setValue(1e6),n.updateByData(),t.updateByData(),this.updateByData(),!0}toBlob(e="video/webm"){return new Blob([this.source.buffer],{type:e})}}const l=()=>{};var d=(e=>(e.IPAD="ipad",e.ANDROID="android",e.IPhONE="iphone",e.PC="pc",e))(d||{});const m=()=>{if("undefined"!=typeof window){const e=navigator.userAgent.toLowerCase();return/ipad|ipod/.test(e)?"ipad":/android/.test(e)?"android":/iphone/.test(e)?"iphone":"pc"}return"pc"},h="undefined"!=typeof window,u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",f="ARRAYBUFFER not supported by this environment",g="UINT8ARRAY not supported by this environment";function v(e,t,n,i){let a,o,r;const s=t||[0],p=(n=n||0)>>>3,c=-1===i?3:0;for(a=0;a<e.length;a+=1)r=a+p,o=r>>>2,s.length<=o&&s.push(0),s[o]|=e[a]<<8*(c+i*(r%4));return{value:s,binLen:8*e.length+n}}function w(e,t,n){switch(t){case"UTF8":case"UTF16BE":case"UTF16LE":break;default:throw new Error("encoding must be UTF8, UTF16BE, or UTF16LE")}switch(e){case"HEX":return function(e,t,i){return function(e,t,n,i){let a,o,r,s;if(0!=e.length%2)throw new Error("String of HEX type must be in byte increments");const p=t||[0],c=(n=n||0)>>>3,l=-1===i?3:0;for(a=0;a<e.length;a+=2){if(o=parseInt(e.substr(a,2),16),isNaN(o))throw new Error("String of HEX type contains invalid characters");for(s=(a>>>1)+c,r=s>>>2;p.length<=r;)p.push(0);p[r]|=o<<8*(l+i*(s%4))}return{value:p,binLen:4*e.length+n}}(e,t,i,n)};case"TEXT":return function(e,i,a){return function(e,t,n,i,a){let o,r,s,p,c,l,d,m,h=0;const u=n||[0],f=(i=i||0)>>>3;if("UTF8"===t)for(d=-1===a?3:0,s=0;s<e.length;s+=1)for(o=e.charCodeAt(s),r=[],128>o?r.push(o):2048>o?(r.push(192|o>>>6),r.push(128|63&o)):55296>o||57344<=o?r.push(224|o>>>12,128|o>>>6&63,128|63&o):(s+=1,o=65536+((1023&o)<<10|1023&e.charCodeAt(s)),r.push(240|o>>>18,128|o>>>12&63,128|o>>>6&63,128|63&o)),p=0;p<r.length;p+=1){for(l=h+f,c=l>>>2;u.length<=c;)u.push(0);u[c]|=r[p]<<8*(d+a*(l%4)),h+=1}else for(d=-1===a?2:0,m="UTF16LE"===t&&1!==a||"UTF16LE"!==t&&1===a,s=0;s<e.length;s+=1){for(o=e.charCodeAt(s),!0===m&&(p=255&o,o=p<<8|o>>>8),l=h+f,c=l>>>2;u.length<=c;)u.push(0);u[c]|=o<<8*(d+a*(l%4)),h+=2}return{value:u,binLen:8*h+i}}(e,t,i,a,n)};case"B64":return function(e,t,i){return function(e,t,n,i){let a,o,r,s,p,c,l,d=0;const m=t||[0],h=(n=n||0)>>>3,f=-1===i?3:0,g=e.indexOf("=");if(-1===e.search(/^[a-z\d=+/]+$/i))throw new Error("Invalid character in base-64 string");if(e=e.replace(/=/g,""),-1!==g&&g<e.length)throw new Error("Invalid '=' found in base-64 string");for(o=0;o<e.length;o+=4){for(p=e.substr(o,4),s=0,r=0;r<p.length;r+=1)a=u.indexOf(p.charAt(r)),s|=a<<18-6*r;for(r=0;r<p.length-1;r+=1){for(l=d+h,c=l>>>2;m.length<=c;)m.push(0);m[c]|=(s>>>16-8*r&255)<<8*(f+i*(l%4)),d+=1}}return{value:m,binLen:8*d+n}}(e,t,i,n)};case"BYTES":return function(e,t,i){return function(e,t,n,i){let a,o,r,s;const p=t||[0],c=(n=n||0)>>>3,l=-1===i?3:0;for(o=0;o<e.length;o+=1)a=e.charCodeAt(o),s=o+c,r=s>>>2,p.length<=r&&p.push(0),p[r]|=a<<8*(l+i*(s%4));return{value:p,binLen:8*e.length+n}}(e,t,i,n)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(i){throw new Error(f)}return function(e,t,i){return function(e,t,n,i){return v(new Uint8Array(e),t,n,i)}(e,t,i,n)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(i){throw new Error(g)}return function(e,t,i){return v(e,t,i,n)};default:throw new Error("format must be HEX, TEXT, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function x(e,t,n,i){switch(e){case"HEX":return function(e){return function(e,t,n,i){const a="0123456789abcdef";let o,r,s="";const p=t/8,c=-1===n?3:0;for(o=0;o<p;o+=1)r=e[o>>>2]>>>8*(c+n*(o%4)),s+=a.charAt(r>>>4&15)+a.charAt(15&r);return i.outputUpper?s.toUpperCase():s}(e,t,n,i)};case"B64":return function(e){return function(e,t,n,i){let a,o,r,s,p,c="";const l=t/8,d=-1===n?3:0;for(a=0;a<l;a+=3)for(s=a+1<l?e[a+1>>>2]:0,p=a+2<l?e[a+2>>>2]:0,r=(e[a>>>2]>>>8*(d+n*(a%4))&255)<<16|(s>>>8*(d+n*((a+1)%4))&255)<<8|p>>>8*(d+n*((a+2)%4))&255,o=0;o<4;o+=1)c+=8*a+6*o<=t?u.charAt(r>>>6*(3-o)&63):i.b64Pad;return c}(e,t,n,i)};case"BYTES":return function(e){return function(e,t,n){let i,a,o="";const r=t/8,s=-1===n?3:0;for(i=0;i<r;i+=1)a=e[i>>>2]>>>8*(s+n*(i%4))&255,o+=String.fromCharCode(a);return o}(e,t,n)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(a){throw new Error(f)}return function(e){return function(e,t,n){let i;const a=t/8,o=new ArrayBuffer(a),r=new Uint8Array(o),s=-1===n?3:0;for(i=0;i<a;i+=1)r[i]=e[i>>>2]>>>8*(s+n*(i%4))&255;return o}(e,t,n)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(a){throw new Error(g)}return function(e){return function(e,t,n){let i;const a=t/8,o=-1===n?3:0,r=new Uint8Array(a);for(i=0;i<a;i+=1)r[i]=e[i>>>2]>>>8*(o+n*(i%4))&255;return r}(e,t,n)};default:throw new Error("format must be HEX, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}const y=4294967296,b=[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],k=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428],C=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],S="Chosen SHA variant is not supported",A="Cannot set numRounds with MAC";function O(e,t){let n,i;const a=e.binLen>>>3,o=t.binLen>>>3,r=a<<3,s=4-a<<3;if(a%4!=0){for(n=0;n<o;n+=4)i=a+n>>>2,e.value[i]|=t.value[n>>>2]<<r,e.value.push(0),e.value[i+1]|=t.value[n>>>2]>>>s;return(e.value.length<<2)-4>=o+a&&e.value.pop(),{value:e.value,binLen:e.binLen+t.binLen}}return{value:e.value.concat(t.value),binLen:e.binLen+t.binLen}}function U(e){const t={outputUpper:!1,b64Pad:"=",outputLen:-1},n=e||{},i="Output length must be a multiple of 8";if(t.outputUpper=n.outputUpper||!1,n.b64Pad&&(t.b64Pad=n.b64Pad),n.outputLen){if(n.outputLen%8!=0)throw new Error(i);t.outputLen=n.outputLen}else if(n.shakeLen){if(n.shakeLen%8!=0)throw new Error(i);t.outputLen=n.shakeLen}if("boolean"!=typeof t.outputUpper)throw new Error("Invalid outputUpper formatting option");if("string"!=typeof t.b64Pad)throw new Error("Invalid b64Pad formatting option");return t}function E(e,t,n,i){const a=e+" must include a value and format";if(!t){if(!i)throw new Error(a);return i}if(void 0===t.value||!t.format)throw new Error(a);return w(t.format,t.encoding||"UTF8",n)(t.value)}class T{constructor(e,t,i){n(this,"shaVariant"),n(this,"inputFormat"),n(this,"utfType"),n(this,"numRounds"),n(this,"keyWithIPad"),n(this,"keyWithOPad"),n(this,"remainder"),n(this,"remainderLen"),n(this,"updateCalled"),n(this,"processedLen"),n(this,"macKeySet");const a=i||{};if(this.inputFormat=t,this.utfType=a.encoding||"UTF8",this.numRounds=a.numRounds||1,isNaN(this.numRounds)||this.numRounds!==parseInt(this.numRounds,10)||1>this.numRounds)throw new Error("numRounds must a integer >= 1");this.shaVariant=e,this.remainder=[],this.remainderLen=0,this.updateCalled=!1,this.processedLen=0,this.macKeySet=!1,this.keyWithIPad=[],this.keyWithOPad=[]}update(e){let t,n=0;const i=this.variantBlockSize>>>5,a=this.converterFunc(e,this.remainder,this.remainderLen),o=a.binLen,r=a.value,s=o>>>5;for(t=0;t<s;t+=i)n+this.variantBlockSize<=o&&(this.intermediateState=this.roundFunc(r.slice(t,t+i),this.intermediateState),n+=this.variantBlockSize);return this.processedLen+=n,this.remainder=r.slice(n>>>5),this.remainderLen=o%this.variantBlockSize,this.updateCalled=!0,this}getHash(e,t){let n,i,a=this.outputBinLen;const o=U(t);if(this.isVariableLen){if(-1===o.outputLen)throw new Error("Output length must be specified in options");a=o.outputLen}const r=x(e,a,this.bigEndianMod,o);if(this.macKeySet&&this.getMAC)return r(this.getMAC(o));for(i=this.finalizeFunc(this.remainder.slice(),this.remainderLen,this.processedLen,this.stateCloneFunc(this.intermediateState),a),n=1;n<this.numRounds;n+=1)this.isVariableLen&&a%32!=0&&(i[i.length-1]&=16777215>>>24-a%32),i=this.finalizeFunc(i,a,0,this.newStateFunc(this.shaVariant),a);return r(i)}setHMACKey(e,t,n){if(!this.HMACSupported)throw new Error("Variant does not support HMAC");if(this.updateCalled)throw new Error("Cannot set MAC key after calling update");const i=w(t,(n||{}).encoding||"UTF8",this.bigEndianMod);this._setHMACKey(i(e))}_setHMACKey(e){const t=this.variantBlockSize>>>3,n=t/4-1;let i;if(1!==this.numRounds)throw new Error(A);if(this.macKeySet)throw new Error("MAC key already set");for(t<e.binLen/8&&(e.value=this.finalizeFunc(e.value,e.binLen,0,this.newStateFunc(this.shaVariant),this.outputBinLen));e.value.length<=n;)e.value.push(0);for(i=0;i<=n;i+=1)this.keyWithIPad[i]=909522486^e.value[i],this.keyWithOPad[i]=1549556828^e.value[i];this.intermediateState=this.roundFunc(this.keyWithIPad,this.intermediateState),this.processedLen=this.variantBlockSize,this.macKeySet=!0}getHMAC(e,t){const n=U(t);return x(e,this.outputBinLen,this.bigEndianMod,n)(this._getHMAC())}_getHMAC(){let e;if(!this.macKeySet)throw new Error("Cannot call getHMAC without first setting MAC key");const t=this.finalizeFunc(this.remainder.slice(),this.remainderLen,this.processedLen,this.stateCloneFunc(this.intermediateState),this.outputBinLen);return e=this.roundFunc(this.keyWithOPad,this.newStateFunc(this.shaVariant)),e=this.finalizeFunc(t,this.outputBinLen,this.variantBlockSize,e,this.outputBinLen),e}}function B(e,t){return e<<t|e>>>32-t}function M(e,t){return e>>>t|e<<32-t}function L(e,t){return e>>>t}function F(e,t,n){return e^t^n}function R(e,t,n){return e&t^~e&n}function H(e,t,n){return e&t^e&n^t&n}function z(e){return M(e,2)^M(e,13)^M(e,22)}function D(e,t){const n=(65535&e)+(65535&t);return(65535&(e>>>16)+(t>>>16)+(n>>>16))<<16|65535&n}function j(e,t,n,i){const a=(65535&e)+(65535&t)+(65535&n)+(65535&i);return(65535&(e>>>16)+(t>>>16)+(n>>>16)+(i>>>16)+(a>>>16))<<16|65535&a}function P(e,t,n,i,a){const o=(65535&e)+(65535&t)+(65535&n)+(65535&i)+(65535&a);return(65535&(e>>>16)+(t>>>16)+(n>>>16)+(i>>>16)+(a>>>16)+(o>>>16))<<16|65535&o}function I(e){return M(e,7)^M(e,18)^L(e,3)}function q(e){return M(e,6)^M(e,11)^M(e,25)}function N(e){return[1732584193,4023233417,2562383102,271733878,3285377520]}function K(e,t){let n,i,a,o,r,s,p;const c=[];for(n=t[0],i=t[1],a=t[2],o=t[3],r=t[4],p=0;p<80;p+=1)c[p]=p<16?e[p]:B(c[p-3]^c[p-8]^c[p-14]^c[p-16],1),s=p<20?P(B(n,5),R(i,a,o),r,1518500249,c[p]):p<40?P(B(n,5),F(i,a,o),r,1859775393,c[p]):p<60?P(B(n,5),H(i,a,o),r,2400959708,c[p]):P(B(n,5),F(i,a,o),r,3395469782,c[p]),r=o,o=a,a=B(i,30),i=n,n=s;return t[0]=D(n,t[0]),t[1]=D(i,t[1]),t[2]=D(a,t[2]),t[3]=D(o,t[3]),t[4]=D(r,t[4]),t}function $(e,t,n,i){let a;const o=15+(t+65>>>9<<4),r=t+n;for(;e.length<=o;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[o]=4294967295&r,e[o-1]=r/y|0,a=0;a<e.length;a+=16)i=K(e.slice(a,a+16),i);return i}let V=class extends T{constructor(e,t,i){if("SHA-1"!==e)throw new Error(S);super(e,t,i),n(this,"intermediateState"),n(this,"variantBlockSize"),n(this,"bigEndianMod"),n(this,"outputBinLen"),n(this,"isVariableLen"),n(this,"HMACSupported"),n(this,"converterFunc"),n(this,"roundFunc"),n(this,"finalizeFunc"),n(this,"stateCloneFunc"),n(this,"newStateFunc"),n(this,"getMAC");const a=i||{};this.HMACSupported=!0,this.getMAC=this._getHMAC,this.bigEndianMod=-1,this.converterFunc=w(this.inputFormat,this.utfType,this.bigEndianMod),this.roundFunc=K,this.stateCloneFunc=function(e){return e.slice()},this.newStateFunc=N,this.finalizeFunc=$,this.intermediateState=[1732584193,4023233417,2562383102,271733878,3285377520],this.variantBlockSize=512,this.outputBinLen=160,this.isVariableLen=!1,a.hmacKey&&this._setHMACKey(E("hmacKey",a.hmacKey,this.bigEndianMod))}};function _(e){let t;return t="SHA-224"===e?k.slice():C.slice(),t}function Y(e,t){let n,i,a,o,r,s,p,c,l,d,m;const h=[];for(n=t[0],i=t[1],a=t[2],o=t[3],r=t[4],s=t[5],p=t[6],c=t[7],m=0;m<64;m+=1)h[m]=m<16?e[m]:j(M(u=h[m-2],17)^M(u,19)^L(u,10),h[m-7],I(h[m-15]),h[m-16]),l=P(c,q(r),R(r,s,p),b[m],h[m]),d=D(z(n),H(n,i,a)),c=p,p=s,s=r,r=D(o,l),o=a,a=i,i=n,n=D(l,d);var u;return t[0]=D(n,t[0]),t[1]=D(i,t[1]),t[2]=D(a,t[2]),t[3]=D(o,t[3]),t[4]=D(r,t[4]),t[5]=D(s,t[5]),t[6]=D(p,t[6]),t[7]=D(c,t[7]),t}let X=class extends T{constructor(e,t,i){if("SHA-224"!==e&&"SHA-256"!==e)throw new Error(S);super(e,t,i),n(this,"intermediateState"),n(this,"variantBlockSize"),n(this,"bigEndianMod"),n(this,"outputBinLen"),n(this,"isVariableLen"),n(this,"HMACSupported"),n(this,"converterFunc"),n(this,"roundFunc"),n(this,"finalizeFunc"),n(this,"stateCloneFunc"),n(this,"newStateFunc"),n(this,"getMAC");const a=i||{};this.getMAC=this._getHMAC,this.HMACSupported=!0,this.bigEndianMod=-1,this.converterFunc=w(this.inputFormat,this.utfType,this.bigEndianMod),this.roundFunc=Y,this.stateCloneFunc=function(e){return e.slice()},this.newStateFunc=_,this.finalizeFunc=function(t,n,i,a){return function(e,t,n,i,a){let o,r;const s=15+(t+65>>>9<<4),p=t+n;for(;e.length<=s;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[s]=4294967295&p,e[s-1]=p/y|0,o=0;o<e.length;o+=16)i=Y(e.slice(o,o+16),i);return r="SHA-224"===a?[i[0],i[1],i[2],i[3],i[4],i[5],i[6]]:i,r}(t,n,i,a,e)},this.intermediateState=_(e),this.variantBlockSize=512,this.outputBinLen="SHA-224"===e?224:256,this.isVariableLen=!1,a.hmacKey&&this._setHMACKey(E("hmacKey",a.hmacKey,this.bigEndianMod))}};class W{constructor(e,t){n(this,"highOrder"),n(this,"lowOrder"),this.highOrder=e,this.lowOrder=t}}function G(e,t){let n;return t>32?(n=64-t,new W(e.lowOrder<<t|e.highOrder>>>n,e.highOrder<<t|e.lowOrder>>>n)):0!==t?(n=32-t,new W(e.highOrder<<t|e.lowOrder>>>n,e.lowOrder<<t|e.highOrder>>>n)):e}function J(e,t){let n;return t<32?(n=32-t,new W(e.highOrder>>>t|e.lowOrder<<n,e.lowOrder>>>t|e.highOrder<<n)):(n=64-t,new W(e.lowOrder>>>t|e.highOrder<<n,e.highOrder>>>t|e.lowOrder<<n))}function Q(e,t){return new W(e.highOrder>>>t,e.lowOrder>>>t|e.highOrder<<32-t)}function Z(e,t,n){return new W(e.highOrder&t.highOrder^e.highOrder&n.highOrder^t.highOrder&n.highOrder,e.lowOrder&t.lowOrder^e.lowOrder&n.lowOrder^t.lowOrder&n.lowOrder)}function ee(e){const t=J(e,28),n=J(e,34),i=J(e,39);return new W(t.highOrder^n.highOrder^i.highOrder,t.lowOrder^n.lowOrder^i.lowOrder)}function te(e,t){let n,i;n=(65535&e.lowOrder)+(65535&t.lowOrder),i=(e.lowOrder>>>16)+(t.lowOrder>>>16)+(n>>>16);const a=(65535&i)<<16|65535&n;n=(65535&e.highOrder)+(65535&t.highOrder)+(i>>>16),i=(e.highOrder>>>16)+(t.highOrder>>>16)+(n>>>16);return new W((65535&i)<<16|65535&n,a)}function ne(e,t,n,i){let a,o;a=(65535&e.lowOrder)+(65535&t.lowOrder)+(65535&n.lowOrder)+(65535&i.lowOrder),o=(e.lowOrder>>>16)+(t.lowOrder>>>16)+(n.lowOrder>>>16)+(i.lowOrder>>>16)+(a>>>16);const r=(65535&o)<<16|65535&a;a=(65535&e.highOrder)+(65535&t.highOrder)+(65535&n.highOrder)+(65535&i.highOrder)+(o>>>16),o=(e.highOrder>>>16)+(t.highOrder>>>16)+(n.highOrder>>>16)+(i.highOrder>>>16)+(a>>>16);return new W((65535&o)<<16|65535&a,r)}function ie(e,t,n,i,a){let o,r;o=(65535&e.lowOrder)+(65535&t.lowOrder)+(65535&n.lowOrder)+(65535&i.lowOrder)+(65535&a.lowOrder),r=(e.lowOrder>>>16)+(t.lowOrder>>>16)+(n.lowOrder>>>16)+(i.lowOrder>>>16)+(a.lowOrder>>>16)+(o>>>16);const s=(65535&r)<<16|65535&o;o=(65535&e.highOrder)+(65535&t.highOrder)+(65535&n.highOrder)+(65535&i.highOrder)+(65535&a.highOrder)+(r>>>16),r=(e.highOrder>>>16)+(t.highOrder>>>16)+(n.highOrder>>>16)+(i.highOrder>>>16)+(a.highOrder>>>16)+(o>>>16);return new W((65535&r)<<16|65535&o,s)}function ae(e,t){return new W(e.highOrder^t.highOrder,e.lowOrder^t.lowOrder)}function oe(e){const t=J(e,19),n=J(e,61),i=Q(e,6);return new W(t.highOrder^n.highOrder^i.highOrder,t.lowOrder^n.lowOrder^i.lowOrder)}function re(e){const t=J(e,1),n=J(e,8),i=Q(e,7);return new W(t.highOrder^n.highOrder^i.highOrder,t.lowOrder^n.lowOrder^i.lowOrder)}function se(e){const t=J(e,14),n=J(e,18),i=J(e,41);return new W(t.highOrder^n.highOrder^i.highOrder,t.lowOrder^n.lowOrder^i.lowOrder)}const pe=[new W(b[0],3609767458),new W(b[1],602891725),new W(b[2],3964484399),new W(b[3],2173295548),new W(b[4],4081628472),new W(b[5],3053834265),new W(b[6],2937671579),new W(b[7],3664609560),new W(b[8],2734883394),new W(b[9],1164996542),new W(b[10],1323610764),new W(b[11],3590304994),new W(b[12],4068182383),new W(b[13],991336113),new W(b[14],633803317),new W(b[15],3479774868),new W(b[16],2666613458),new W(b[17],944711139),new W(b[18],2341262773),new W(b[19],2007800933),new W(b[20],1495990901),new W(b[21],1856431235),new W(b[22],3175218132),new W(b[23],2198950837),new W(b[24],3999719339),new W(b[25],766784016),new W(b[26],2566594879),new W(b[27],3203337956),new W(b[28],1034457026),new W(b[29],2466948901),new W(b[30],3758326383),new W(b[31],168717936),new W(b[32],1188179964),new W(b[33],1546045734),new W(b[34],1522805485),new W(b[35],2643833823),new W(b[36],2343527390),new W(b[37],1014477480),new W(b[38],1206759142),new W(b[39],344077627),new W(b[40],1290863460),new W(b[41],3158454273),new W(b[42],3505952657),new W(b[43],106217008),new W(b[44],3606008344),new W(b[45],1432725776),new W(b[46],1467031594),new W(b[47],851169720),new W(b[48],3100823752),new W(b[49],1363258195),new W(b[50],3750685593),new W(b[51],3785050280),new W(b[52],3318307427),new W(b[53],3812723403),new W(b[54],2003034995),new W(b[55],3602036899),new W(b[56],1575990012),new W(b[57],1125592928),new W(b[58],2716904306),new W(b[59],442776044),new W(b[60],593698344),new W(b[61],3733110249),new W(b[62],2999351573),new W(b[63],3815920427),new W(3391569614,3928383900),new W(3515267271,566280711),new W(3940187606,3454069534),new W(4118630271,4000239992),new W(116418474,1914138554),new W(174292421,2731055270),new W(289380356,3203993006),new W(460393269,320620315),new W(685471733,587496836),new W(852142971,1086792851),new W(1017036298,365543100),new W(1126000580,2618297676),new W(1288033470,3409855158),new W(1501505948,4234509866),new W(1607167915,987167468),new W(1816402316,1246189591)];function ce(e){return"SHA-384"===e?[new W(3418070365,k[0]),new W(1654270250,k[1]),new W(2438529370,k[2]),new W(355462360,k[3]),new W(1731405415,k[4]),new W(41048885895,k[5]),new W(3675008525,k[6]),new W(1203062813,k[7])]:[new W(C[0],4089235720),new W(C[1],2227873595),new W(C[2],4271175723),new W(C[3],1595750129),new W(C[4],2917565137),new W(C[5],725511199),new W(C[6],4215389547),new W(C[7],327033209)]}function le(e,t){let n,i,a,o,r,s,p,c,l,d,m,h;const u=[];for(n=t[0],i=t[1],a=t[2],o=t[3],r=t[4],s=t[5],p=t[6],c=t[7],m=0;m<80;m+=1)m<16?(h=2*m,u[m]=new W(e[h],e[h+1])):u[m]=ne(oe(u[m-2]),u[m-7],re(u[m-15]),u[m-16]),l=ie(c,se(r),(g=s,v=p,new W((f=r).highOrder&g.highOrder^~f.highOrder&v.highOrder,f.lowOrder&g.lowOrder^~f.lowOrder&v.lowOrder)),pe[m],u[m]),d=te(ee(n),Z(n,i,a)),c=p,p=s,s=r,r=te(o,l),o=a,a=i,i=n,n=te(l,d);var f,g,v;return t[0]=te(n,t[0]),t[1]=te(i,t[1]),t[2]=te(a,t[2]),t[3]=te(o,t[3]),t[4]=te(r,t[4]),t[5]=te(s,t[5]),t[6]=te(p,t[6]),t[7]=te(c,t[7]),t}let de=class extends T{constructor(e,t,i){if("SHA-384"!==e&&"SHA-512"!==e)throw new Error(S);super(e,t,i),n(this,"intermediateState"),n(this,"variantBlockSize"),n(this,"bigEndianMod"),n(this,"outputBinLen"),n(this,"isVariableLen"),n(this,"HMACSupported"),n(this,"converterFunc"),n(this,"roundFunc"),n(this,"finalizeFunc"),n(this,"stateCloneFunc"),n(this,"newStateFunc"),n(this,"getMAC");const a=i||{};this.getMAC=this._getHMAC,this.HMACSupported=!0,this.bigEndianMod=-1,this.converterFunc=w(this.inputFormat,this.utfType,this.bigEndianMod),this.roundFunc=le,this.stateCloneFunc=function(e){return e.slice()},this.newStateFunc=ce,this.finalizeFunc=function(t,n,i,a){return function(e,t,n,i,a){let o,r;const s=31+(t+129>>>10<<5),p=t+n;for(;e.length<=s;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[s]=4294967295&p,e[s-1]=p/y|0,o=0;o<e.length;o+=32)i=le(e.slice(o,o+32),i);return r="SHA-384"===a?[i[0].highOrder,i[0].lowOrder,i[1].highOrder,i[1].lowOrder,i[2].highOrder,i[2].lowOrder,i[3].highOrder,i[3].lowOrder,i[4].highOrder,i[4].lowOrder,i[5].highOrder,i[5].lowOrder]:[i[0].highOrder,i[0].lowOrder,i[1].highOrder,i[1].lowOrder,i[2].highOrder,i[2].lowOrder,i[3].highOrder,i[3].lowOrder,i[4].highOrder,i[4].lowOrder,i[5].highOrder,i[5].lowOrder,i[6].highOrder,i[6].lowOrder,i[7].highOrder,i[7].lowOrder],r}(t,n,i,a,e)},this.intermediateState=ce(e),this.variantBlockSize=1024,this.outputBinLen="SHA-384"===e?384:512,this.isVariableLen=!1,a.hmacKey&&this._setHMACKey(E("hmacKey",a.hmacKey,this.bigEndianMod))}};const me=[new W(0,1),new W(0,32898),new W(2147483648,32906),new W(2147483648,2147516416),new W(0,32907),new W(0,2147483649),new W(2147483648,2147516545),new W(2147483648,32777),new W(0,138),new W(0,136),new W(0,2147516425),new W(0,2147483658),new W(0,2147516555),new W(2147483648,139),new W(2147483648,32905),new W(2147483648,32771),new W(2147483648,32770),new W(2147483648,128),new W(0,32778),new W(2147483648,2147483658),new W(2147483648,2147516545),new W(2147483648,32896),new W(0,2147483649),new W(2147483648,2147516424)],he=[[0,36,3,41,18],[1,44,10,45,2],[62,6,43,15,61],[28,55,25,21,56],[27,20,39,8,14]];function ue(e){let t;const n=[];for(t=0;t<5;t+=1)n[t]=[new W(0,0),new W(0,0),new W(0,0),new W(0,0),new W(0,0)];return n}function fe(e){let t;const n=[];for(t=0;t<5;t+=1)n[t]=e[t].slice();return n}function ge(e,t){let n,i,a,o;const r=[],s=[];if(null!=e)for(i=0;i<e.length;i+=2)t[(i>>>1)%5][(i>>>1)/5|0]=ae(t[(i>>>1)%5][(i>>>1)/5|0],new W(e[i+1],e[i]));for(n=0;n<24;n+=1){for(o=ue(),i=0;i<5;i+=1)r[i]=(p=t[i][0],c=t[i][1],l=t[i][2],d=t[i][3],m=t[i][4],new W(p.highOrder^c.highOrder^l.highOrder^d.highOrder^m.highOrder,p.lowOrder^c.lowOrder^l.lowOrder^d.lowOrder^m.lowOrder));for(i=0;i<5;i+=1)s[i]=ae(r[(i+4)%5],G(r[(i+1)%5],1));for(i=0;i<5;i+=1)for(a=0;a<5;a+=1)t[i][a]=ae(t[i][a],s[i]);for(i=0;i<5;i+=1)for(a=0;a<5;a+=1)o[a][(2*i+3*a)%5]=G(t[i][a],he[i][a]);for(i=0;i<5;i+=1)for(a=0;a<5;a+=1)t[i][a]=ae(o[i][a],new W(~o[(i+1)%5][a].highOrder&o[(i+2)%5][a].highOrder,~o[(i+1)%5][a].lowOrder&o[(i+2)%5][a].lowOrder));t[0][0]=ae(t[0][0],me[n])}var p,c,l,d,m;return t}function ve(e){let t,n,i=0;const a=[0,0],o=[4294967295&e,e/y&2097151];for(t=6;t>=0;t--)n=o[t>>2]>>>8*t&255,0===n&&0===i||(a[i+1>>2]|=n<<8*(i+1),i+=1);return i=0!==i?i:1,a[0]|=i,{value:i+1>4?a:[a[0]],binLen:8+8*i}}function we(e){return O(ve(e.binLen),e)}function xe(e,t){let n,i=ve(t);i=O(i,e);const a=t>>>2,o=(a-i.value.length%a)%a;for(n=0;n<o;n++)i.value.push(0);return i.value}let ye=class extends T{constructor(e,t,i){let a=6,o=0;super(e,t,i),n(this,"intermediateState"),n(this,"variantBlockSize"),n(this,"bigEndianMod"),n(this,"outputBinLen"),n(this,"isVariableLen"),n(this,"HMACSupported"),n(this,"converterFunc"),n(this,"roundFunc"),n(this,"finalizeFunc"),n(this,"stateCloneFunc"),n(this,"newStateFunc"),n(this,"getMAC");const r=i||{};if(1!==this.numRounds){if(r.kmacKey||r.hmacKey)throw new Error(A);if("CSHAKE128"===this.shaVariant||"CSHAKE256"===this.shaVariant)throw new Error("Cannot set numRounds for CSHAKE variants")}switch(this.bigEndianMod=1,this.converterFunc=w(this.inputFormat,this.utfType,this.bigEndianMod),this.roundFunc=ge,this.stateCloneFunc=fe,this.newStateFunc=ue,this.intermediateState=ue(),this.isVariableLen=!1,e){case"SHA3-224":this.variantBlockSize=o=1152,this.outputBinLen=224,this.HMACSupported=!0,this.getMAC=this._getHMAC;break;case"SHA3-256":this.variantBlockSize=o=1088,this.outputBinLen=256,this.HMACSupported=!0,this.getMAC=this._getHMAC;break;case"SHA3-384":this.variantBlockSize=o=832,this.outputBinLen=384,this.HMACSupported=!0,this.getMAC=this._getHMAC;break;case"SHA3-512":this.variantBlockSize=o=576,this.outputBinLen=512,this.HMACSupported=!0,this.getMAC=this._getHMAC;break;case"SHAKE128":a=31,this.variantBlockSize=o=1344,this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=null;break;case"SHAKE256":a=31,this.variantBlockSize=o=1088,this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=null;break;case"KMAC128":a=4,this.variantBlockSize=o=1344,this._initializeKMAC(i),this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=this._getKMAC;break;case"KMAC256":a=4,this.variantBlockSize=o=1088,this._initializeKMAC(i),this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=this._getKMAC;break;case"CSHAKE128":this.variantBlockSize=o=1344,a=this._initializeCSHAKE(i),this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=null;break;case"CSHAKE256":this.variantBlockSize=o=1088,a=this._initializeCSHAKE(i),this.outputBinLen=-1,this.isVariableLen=!0,this.HMACSupported=!1,this.getMAC=null;break;default:throw new Error(S)}this.finalizeFunc=function(e,t,n,i,r){return function(e,t,n,i,a,o,r){let s,p,c=0;const l=[],d=a>>>5,m=t>>>5;for(s=0;s<m&&t>=a;s+=d)i=ge(e.slice(s,s+d),i),t-=a;for(e=e.slice(s),t%=a;e.length<d;)e.push(0);for(s=t>>>3,e[s>>2]^=o<<s%4*8,e[d-1]^=2147483648,i=ge(e,i);32*l.length<r&&(p=i[c%5][c/5|0],l.push(p.lowOrder),!(32*l.length>=r));)l.push(p.highOrder),c+=1,0==64*c%a&&(ge(null,i),c=0);return l}(e,t,0,i,o,a,r)},r.hmacKey&&this._setHMACKey(E("hmacKey",r.hmacKey,this.bigEndianMod))}_initializeCSHAKE(e,t){const n=function(e){const t=e||{};return{funcName:E("funcName",t.funcName,1,{value:[],binLen:0}),customization:E("Customization",t.customization,1,{value:[],binLen:0})}}(e||{});t&&(n.funcName=t);const i=O(we(n.funcName),we(n.customization));if(0!==n.customization.binLen||0!==n.funcName.binLen){const e=xe(i,this.variantBlockSize>>>3);for(let t=0;t<e.length;t+=this.variantBlockSize>>>5)this.intermediateState=this.roundFunc(e.slice(t,t+(this.variantBlockSize>>>5)),this.intermediateState),this.processedLen+=this.variantBlockSize;return 4}return 31}_initializeKMAC(e){const t=function(e){const t=e||{};return{kmacKey:E("kmacKey",t.kmacKey,1),funcName:{value:[1128353099],binLen:32},customization:E("Customization",t.customization,1,{value:[],binLen:0})}}(e||{});this._initializeCSHAKE(e,t.funcName);const n=xe(we(t.kmacKey),this.variantBlockSize>>>3);for(let i=0;i<n.length;i+=this.variantBlockSize>>>5)this.intermediateState=this.roundFunc(n.slice(i,i+(this.variantBlockSize>>>5)),this.intermediateState),this.processedLen+=this.variantBlockSize;this.macKeySet=!0}_getKMAC(e){const t=O({value:this.remainder.slice(),binLen:this.remainderLen},function(e){let t,n,i=0;const a=[0,0],o=[4294967295&e,e/y&2097151];for(t=6;t>=0;t--)n=o[t>>2]>>>8*t&255,0===n&&0===i||(a[i>>2]|=n<<8*i,i+=1);return i=0!==i?i:1,a[i>>2]|=i<<8*i,{value:i+1>4?a:[a[0]],binLen:8+8*i}}(e.outputLen));return this.finalizeFunc(t.value,t.binLen,this.processedLen,this.stateCloneFunc(this.intermediateState),e.outputLen)}};class be{constructor(e,t,i){if(n(this,"shaObj"),"SHA-1"===e)this.shaObj=new V(e,t,i);else if("SHA-224"===e||"SHA-256"===e)this.shaObj=new X(e,t,i);else if("SHA-384"===e||"SHA-512"===e)this.shaObj=new de(e,t,i);else{if("SHA3-224"!==e&&"SHA3-256"!==e&&"SHA3-384"!==e&&"SHA3-512"!==e&&"SHAKE128"!==e&&"SHAKE256"!==e&&"CSHAKE128"!==e&&"CSHAKE256"!==e&&"KMAC128"!==e&&"KMAC256"!==e)throw new Error(S);this.shaObj=new ye(e,t,i)}}update(e){return this.shaObj.update(e),this}getHash(e,t){return this.shaObj.getHash(e,t)}setHMACKey(e,t,n){this.shaObj.setHMACKey(e,t,n)}getHMAC(e,t){return this.shaObj.getHMAC(e,t)}}function ke(e){return e<10?`0${e}`:e}const Ce=()=>{if("undefined"!=typeof document)return performance.now();if("undefined"!=typeof process){const[e,t]=process.hrtime();return 1e3*e+t/1e6}return Date.now()},Se=e=>"[object String]"===toString.call(e);function Ae(e=8){const t="ABCDEFGHJKMNPQRSTWXYZabcdefhijkmnprstwxyz2345678";let n="";for(let i=0;i<e;i++)n+=t.charAt(Math.floor(48*Math.random()));return`${Date.now()}-${n}`}const Oe=(e,t={})=>{const{urlencoded:n=!0}=t,i=String.prototype.trim.call(e);return n?decodeURIComponent(i).replace(/"|'/g,""):i.replace(/"|'/g,"")},Ue=e=>{const t=document.cookie.split("; ");for(let n=0;n<t.length;n++){const i=t[n].split("=");if(i[0]===e)return decodeURIComponent(i[1])}return""},Ee=e=>{if("undefined"!=typeof window){if(e&&Se(e));else{const e=/\w(\.trunk|\.neibu|\.release|test)\./.exec(window.location.hostname);e&&e[1]}return"//log.chaxus.com"}};const Te=()=>"undefined"!=typeof window?{width:window.innerWidth,height:window.innerHeight}:{width:0,height:0},Be=/(?:[^\x21\x25\x26-\x3B\x3D\x3F-\x5B\x5D\x5F\x7E]|%(?:[^\da-f]|[\da-f][^\da-f]|$))+/gi,Me=/(^|[^\uD800-\uDBFF])[\uDC00-\uDFFF]|[\uD800-\uDBFF]([^\uDC00-\uDFFF]|$)/g;const Le=e=>new Promise(((t,n)=>{const i=new Image,a=(new Date).getTime();i.src=e||`https://github.com/favicon.ico?d=${a}`,i.onload=()=>{const e=(new Date).getTime();t(e-a)},i.onerror=e=>{n(e)}})),Fe=(e,...t)=>n=>new Promise(((i,a)=>{setTimeout((async()=>{try{const n=await e(...t);i(n)}catch(n){a(n)}}),n)})),Re=Math.round;class He{constructor(e){n(this,"r"),n(this,"g"),n(this,"b"),this.r=e[0],this.g=e[1],this.b=e[2]}toString(){return`rgb(${this.r},${this.g},${this.b})`}}class ze extends He{constructor(e){super(e),n(this,"a"),this.a=e[3]}toString(){return`rgba(${this.r},${this.g},${this.b},${this.a})`}}class De{constructor(e){n(this,"h"),n(this,"s"),n(this,"l"),this.h=e[0],this.s=e[1],this.l=e[2]}toString(){return`hsl(${this.h},${this.s}%,${this.l}%)`}}class je extends De{constructor(e){super(e),n(this,"a"),this.a=e[3]}toString(){return`hsla(${this.h},${this.s}%,${this.l}%,${this.a})`}}class Pe{constructor(e,t=0,i=0,a=1){if(n(this,"r"),n(this,"g"),n(this,"b"),n(this,"a"),n(this,"rgb"),n(this,"rgba"),n(this,"hex"),n(this,"hsl"),n(this,"hsla"),n(this,"h"),n(this,"s"),n(this,"l"),"string"==typeof e){let n=e;"#"!==n.charAt(0)&&(n="#"+n),n.length<7&&(n="#"+n[1]+n[1]+n[2]+n[2]+n[3]+n[3]),[e,t,i]=Ie(n)}else e instanceof Array&&(a=e[3]||a,i=e[2],t=e[1],e=e[0]);this.r=Number(e),this.g=Number(t),this.b=Number(i),this.a=a,this.rgb=new He([this.r,this.g,this.b]),this.rgba=new ze([this.r,this.g,this.b,this.a]),this.hex=Ne(this.r,this.g,this.b),this.hsl=new De(Ke(this.r,this.g,this.b)),this.h=this.hsl.h,this.s=this.hsl.s,this.l=this.hsl.l,this.hsla=new je([this.h,this.s,this.l,this.a])}setHue(e){this.h=e,this.hsl.h=e,this.hsla.h=e,this.updateFromHsl()}setSat(e){this.s=e,this.hsl.s=e,this.hsla.s=e,this.updateFromHsl()}setLum(e){this.l=e,this.hsl.l=e,this.hsla.l=e,this.updateFromHsl()}setAlpha(e){this.a=e,this.hsla.a=e,this.rgba.a=e}updateFromHsl(){this.rgb=new He(Ve(this.h,this.s,this.l)),this.r=this.rgb.r,this.g=this.rgb.g,this.b=this.rgb.b,this.rgba.r=this.rgb.r,this.rgba.g=this.rgb.g,this.rgba.b=this.rgb.b,this.hex=Ne([this.r,this.g,this.b])}}const Ie=function(e){const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]:null},qe=function(e){const t=e.toString(16);return 1===t.length?"0"+t:t},Ne=function(e,t=0,n=0){return e instanceof Array&&(n=e[2],t=e[1],e=e[0]),"#"+qe(e)+qe(t)+qe(n)},Ke=function(e,t=0,n=0){e instanceof Array&&(n=e[2],t=e[1],e=e[0]);let i,a,o,r=0;e/=255,t/=255,n/=255;const s=Math.max(e,t,n),p=Math.min(e,t,n);if(a=(s+p)/2,s===p)r=i=0;else{switch(o=s-p,i=a>.5?o/(2-s-p):o/(s+p),s){case e:r=(t-n)/o+(t<n?6:0);break;case t:r=(n-e)/o+2;break;case n:r=(e-t)/o+4}r/=6}return r=Re(360*r),i=Re(100*i),a=Re(100*a),[r,i,a]},$e=function(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e},Ve=function(e,t,n){let i,a,o,r,s;return e instanceof Array&&(n=e[2],t=e[1],e=e[0]),e=Number(e)/360,t=Number(t)/100,n=Number(n)/100,0===t?i=a=o=n:(r=n<.5?n*(1+t):n+t-n*t,s=2*n-r,i=$e(s,r,e+1/3),a=$e(s,r,e),o=$e(s,r,e-1/3)),[Re(255*i),Re(255*a),Re(255*o)]},_e=function(e,t,n){let i=0,a=0,o=0;if(0===n)return[0,0,0];t/=100,n/=100,e/=60;const r=Math.floor(e),s=e-r,p=n*(1-t),c=n*(1-t*s),l=n*(1-t*(1-s));return 0===r?(i=n,a=l,o=p):1===r?(i=c,a=n,o=p):2===r?(i=p,a=n,o=l):3===r?(i=p,a=c,o=n):4===r?(i=l,a=p,o=n):5===r&&(i=n,a=p,o=c),i=Math.floor(255*i),a=Math.floor(255*a),o=Math.floor(255*o),[i,a,o]},Ye=_e,Xe=function(e,t,n){return Ke(_e(e,t,n))};const We=e=>{let t,n=!1;return(...i)=>(n||(t="function"==typeof e?e(...i):e,n=!0,e=void 0),t)};function Ge(e={}){if("object"!=typeof e)throw new TypeError("param must be object");return Object.entries(e).reduce(((e,[t,n])=>(void 0===n||null==n||e.append(decodeURIComponent(t),decodeURIComponent(n)),e)),new URLSearchParams).toString()}function Je(e,t,n,i){if(void 0!==e&&(t in e||i)){const i=n(e[t]);"function"==typeof i&&(e[t]=i)}}const Qe=(e,t)=>{const n=Object.getOwnPropertyDescriptors(t);for(const i of Object.keys(n)){const t=n[i];if(t.get){const n=t.get;Object.defineProperty(e,i,{configurable:!1,enumerable:!0,get:We(n)})}else{if("object"!=typeof t.value)throw new Error("Exposed values must be either a getter or an nested object");Object.defineProperty(e,i,{configurable:!1,enumerable:!0,writable:!1,value:Qe({},t.value)})}}return Object.freeze(e)},Ze=(e=l)=>{["log","info","warn","error","assert"].forEach((t=>{Je(console,t,(n=>function(...i){n&&(e(t,...i),n.apply(console,i))}))}))},et=/["'&<>]/;const tt=["svg","path","g","circle","rect","line","polyline","polygon","ellipse","text","tspan","textPath","defs","marker","radialGradient","stop","linearGradient","clipPath","mask","pattern","image","use","symbol","foreignObject","feGaussianBlur","feColorMatrix"];class nt{constructor(e,t){n(this,"listener"),n(this,"element"),n(this,"create",((e,t)=>tt.includes(e)?document.createElementNS("http://www.w3.org/2000/svg",e,t):document.createElement(e,t))),n(this,"setAttribute",((e,t)=>(this.element.setAttribute(e,t),this))),n(this,"removeAttribute",(e=>(this.element.removeAttribute(e),this))),n(this,"append",(e=>(this.element.appendChild(e),this))),n(this,"remove",(e=>(this.element.removeChild(e),this))),n(this,"setTextContent",(e=>(this.element.textContent=e,this))),n(this,"setStyle",((e,t)=>(this.element.style.setProperty(e,t),this))),n(this,"addElementByType",((e,t)=>{e instanceof nt&&t.appendChild(e.element),e instanceof HTMLElement&&t.appendChild(e)})),n(this,"addChild",(e=>{if(Array.isArray(e)){const t=document.createDocumentFragment();e.forEach((e=>{this.addElementByType(e,t)})),this.element.appendChild(t)}else this.addElementByType(e,this.element);return this})),n(this,"listen",((e,t,n)=>{let i=this.listener.get(e);i||(i=new Map,this.listener.set(e,i));const a=i.get(t.name);return a===t&&console.warn(`${a.name} listener has been added to ${e} event, please remove it first.`),this.element.addEventListener(e,t,n),i.set(t.name,t),this})),n(this,"clearListener",((e,t,n)=>{this.element.removeEventListener(e,t,n);const i=this.listener.get(e);return i?i.delete(t.name):console.warn(`No ${e} event listener has been added.`),this})),n(this,"clearAllListener",(()=>{for(const[e,t]of this.listener){for(const[n,i]of t)this.element.removeEventListener(e,i),t.delete(n);this.listener.delete(e)}return this})),this.element=this.create(e,t),this.listener=new Map}}const it=(e=l)=>{"undefined"!=typeof window&&(window.addEventListener("unhandledrejection",(t=>{e(t)}),!0),window.addEventListener("error",(t=>(e(t),!1)),!0))},at=new Map([[".ez","application/andrew-inset"],[".aw","application/applixware"],[".txt","text/plain"],[".ez","application/andrew-inset"],[".aw","application/applixware"],[".atom","application/atom+xml"],[".atomcat","application/atomcat+xml"],[".atomsvc","application/atomsvc+xml"],[".ccxml","application/ccxml+xml"],[".cu","application/cu-seeme"],[".davmount","application/davmount+xml"],[".ecma","application/ecmascript"],[".emma","application/emma+xml"],[".epub","application/epub+zip"],[".pfr","application/font-tdpfr"],[".stk","application/hyperstudio"],[".jar","application/java-archive"],[".ser","application/java-serialized-object"],[".class","application/java-vm"],[".js","application/javascript"],[".ts","application/javascript"],[".json","application/json"],[".lostxml","application/lost+xml"],[".hqx","application/mac-binhex40"],[".cpt","application/mac-compactpro"],[".mrc","application/marc"],[".ma,","application/mathematica"],[".nb","application/mathematica"],[".mb","application/mathematica"],[".mathml","application/mathml+xml"],[".mbox","application/mbox"],[".mscml","application/mediaservercontrol+xml"],[".mp4s","application/mp4"],[".doc","application/msword"],[".dot","application/msword"],[".mxf","application/mxf"],[".oda","application/oda"],[".opf","application/oebps-package+xml"],[".ogx","application/ogg"],[".onetoc","application/onenote"],[".onetoc2","application/onenote"],[".onetmp","application/onenote"],[".onepkg","application/onenote"],[".xer","application/patch-ops-error+xml"],[".pdf","application/pdf"],[".pgp","application/pgp-encrypted"],[".asc","application/pgp-signature"],[".sig","application/pgp-signature"],[".prf","application/pics-rules"],[".p10","application/pkcs10"],[".p7c","application/pkcs7-mime"],[".p7m","application/pkcs7-mime"],[".p7s","application/pkcs7-signature"],[".cer","application/pkix-cert"],[".crl","application/pkix-crl"],[".pkipath","application/pkix-pkipath"],[".pki","application/pkixcmp"],[".pls","application/pls+xml"],[".ai","application/postscript"],[".eps","application/postscript"],[".ps","application/postscript"],[".cww","application/prs.cww"],[".rdf","application/rdf+xml"],[".rif","application/reginfo+xml"],[".rnc","application/relax-ng-compact-syntax"],[".rl","application/resource-lists+xml"],[".rld","application/resource-lists-diff+xml"],[".rs","application/rls-services+xml"],[".rsd","application/rsd+xml"],[".rss","application/rss+xml"],[".rtf","application/rtf"],[".sbml","application/sbml+xml"],[".scq","application/scvp-cv-request"],[".scs","application/scvp-cv-response"],[".spq","application/scvp-vp-request"],[".spp","application/scvp-vp-response"],[".sdp","application/sdp"],[".setpay","application/set-payment-initiation"],[".setreg","application/set-registration-initiation"],[".shf","application/shf+xml"],[".smil","application/smil+xml"],[".smi","application/smil+xml"],[".rq","application/sparql-query"],[".srx","application/sparql-results+xml"],[".gram","application/srgs"],[".grxml","application/srgs+xml"],[".ssml","application/ssml+xml"],[".plb","application/vnd.3gpp.pic-bw-large"],[".psb","application/vnd.3gpp.pic-bw-small"],[".pvb","application/vnd.3gpp.pic-bw-var"],[".tcap","application/vnd.3gpp2.tcap"],[".pwn","application/vnd.3m.post-it-notes"],[".aso","application/vnd.accpac.simply.aso"],[".imp","application/vnd.accpac.simply.imp"],[".acu","application/vnd.acucobol"],[".atc","application/vnd.acucorp"],[".acutc","application/vnd.acucorp"],[".air","application/vnd.adobe.air-application-installer-package+zip"],[".xdp","application/vnd.adobe.xdp+xml"],[".xfdf","application/vnd.adobe.xfdf"],[".azf","application/vnd.airzip.filesecure.azf"],[".azs","application/vnd.airzip.filesecure.azs"],[".azw","application/vnd.amazon.ebook"],[".acc","application/vnd.americandynamics.acc"],[".ami","application/vnd.amiga.ami"],[".apk","application/vnd.android.package-archive"],[".cii","application/vnd.anser-web-certificate-issue-initiation"],[".fti","application/vnd.anser-web-funds-transfer-initiation"],[".atx","application/vnd.antix.game-component"],[".mpkg","application/vnd.apple.installer+xml"],[".swi","application/vnd.arastra.swi"],[".aep","application/vnd.audiograph"],[".mpm","application/vnd.blueice.multipass"],[".bmi","application/vnd.bmi"],[".rep","application/vnd.businessobjects"],[".cdxml","application/vnd.chemdraw+xml"],[".mmd","application/vnd.chipnuts.karaoke-mmd"],[".cdy","application/vnd.cinderella"],[".cla","application/vnd.claymore"],[".c4u","application/vnd.clonk.c4group"],[".c4p","application/vnd.clonk.c4group"],[".c4f","application/vnd.clonk.c4group"],[".c4d","application/vnd.clonk.c4group"],[".c4g","application/vnd.clonk.c4group"],[".csp","application/vnd.commonspace"],[".cdbcmsg","application/vnd.contact.cmsg"],[".cmc","application/vnd.cosmocaller"],[".clkx","application/vnd.crick.clicker"],[".clkk","application/vnd.crick.clicker.keyboard"],[".clkp","application/vnd.crick.clicker.palette"],[".clkt","application/vnd.crick.clicker.template"],[".clkw","application/vnd.crick.clicker.wordbank"],[".wbs","application/vnd.criticaltools.wbs+xml"],[".pml","application/vnd.ctc-posml"],[".ppd","application/vnd.cups-ppd"],[".car","application/vnd.curl.car"],[".pcurl","application/vnd.curl.pcurl"],[".rdz","application/vnd.data-vision.rdz"],[".fe_launch","application/vnd.denovo.fcselayout-link"],[".dna","application/vnd.dna"],[".mlp","application/vnd.dolby.mlp"],[".dpg","application/vnd.dpgraph"],[".dfac","application/vnd.dreamfactory"],[".geo","application/vnd.dynageo"],[".mag","application/vnd.ecowin.chart"],[".nml","application/vnd.enliven"],[".esf","application/vnd.epson.esf"],[".msf","application/vnd.epson.msf"],[".qam","application/vnd.epson.quickanime"],[".slt","application/vnd.epson.salt"],[".ssf","application/vnd.epson.ssf"],[".et3","application/vnd.eszigno3+xml"],[".es3","application/vnd.eszigno3+xml"],[".ez2","application/vnd.ezpix-album"],[".ez3","application/vnd.ezpix-package"],[".fdf","application/vnd.fdf"],[".mseed","application/vnd.fdsn.mseed"],[".dataless","application/vnd.fdsn.seed"],[".seed","application/vnd.fdsn.seed"],[".gph","application/vnd.flographit"],[".ftc","application/vnd.fluxtime.clip"],[".fm","application/vnd.framemaker"],[".frame","application/vnd.framemaker"],[".maker","application/vnd.framemaker"],[".book","application/vnd.framemaker"],[".fnc","application/vnd.frogans.fnc"],[".ltf","application/vnd.frogans.ltf"],[".fsc","application/vnd.fsc.weblaunch"],[".oas","application/vnd.fujitsu.oasys"],[".oa2","application/vnd.fujitsu.oasys2"],[".oa3","application/vnd.fujitsu.oasys3"],[".fg5","application/vnd.fujitsu.oasysgp"],[".bh2","application/vnd.fujitsu.oasysprs"],[".ddd","application/vnd.fujixerox.ddd"],[".xdw","application/vnd.fujixerox.docuworks"],[".xbd","application/vnd.fujixerox.docuworks.binder"],[".fzs","application/vnd.fuzzysheet"],[".txd","application/vnd.genomatix.tuxedo"],[".ggb","application/vnd.geogebra.file"],[".ggt","application/vnd.geogebra.tool"],[".gre","application/vnd.geometry-explorer"],[".gex","application/vnd.geometry-explorer"],[".gmx","application/vnd.gmx"],[".kml","application/vnd.google-earth.kml+xml"],[".kmz","application/vnd.google-earth.kmz"],[".gqf","application/vnd.grafeq"],[".gqs","application/vnd.grafeq"],[".gac","application/vnd.groove-account"],[".ghf","application/vnd.groove-help"],[".gim","application/vnd.groove-identity-message"],[".grv","application/vnd.groove-injector"],[".gtm","application/vnd.groove-tool-message"],[".tpl","application/vnd.groove-tool-template"],[".vcg","application/vnd.groove-vcard"],[".zmm","application/vnd.handheld-entertainment+xml"],[".hbci","application/vnd.hbci"],[".les","application/vnd.hhe.lesson-player"],[".hpgl","application/vnd.hp-hpgl"],[".hpid","application/vnd.hp-hpid"],[".hps","application/vnd.hp-hps"],[".jlt","application/vnd.hp-jlyt"],[".pcl","application/vnd.hp-pcl"],[".pclxl","application/vnd.hp-pclxl"],[".sfd-hdstx","application/vnd.hydrostatix.sof-data"],[".x3d","application/vnd.hzn-3d-crossword"],[".mpy","application/vnd.ibm.minipay"],[".afp","application/vnd.ibm.modcap"],[".listafp","application/vnd.ibm.modcap"],[".list3820","application/vnd.ibm.modcap"],[".irm","application/vnd.ibm.rights-management"],[".sc","application/vnd.ibm.secure-container"],[".icm","application/vnd.iccprofile"],[".icc","application/vnd.iccprofile"],[".igl","application/vnd.igloader"],[".ivp","application/vnd.immervision-ivp"],[".ivu","application/vnd.immervision-ivu"],[".xpw","application/vnd.intercon.formnet"],[".xpx","application/vnd.intercon.formnet"],[".qbo","application/vnd.intu.qbo"],[".qfx","application/vnd.intu.qfx"],[".rcprofile","application/vnd.ipunplugged.rcprofile"],[".irp","application/vnd.irepository.package+xml"],[".xpr","application/vnd.is-xpr"],[".jam","application/vnd.jam"],[".rms","application/vnd.jcp.javame.midlet-rms"],[".jisp","application/vnd.jisp"],[".joda","application/vnd.joost.joda-archive"],[".ktz","application/vnd.kahootz"],[".ktr","application/vnd.kahootz"],[".karbon","application/vnd.kde.karbon"],[".chrt","application/vnd.kde.kchart"],[".kfo","application/vnd.kde.kformula"],[".flw","application/vnd.kde.kivio"],[".kon","application/vnd.kde.kontour"],[".kpt","application/vnd.kde.kpresenter"],[".kpr","application/vnd.kde.kpresenter"],[".ksp","application/vnd.kde.kspread"],[".kwd","application/vnd.kde.kword"],[".kwt","application/vnd.kde.kword"],[".htke","application/vnd.kenameaapp"],[".kia","application/vnd.kidspiration"],[".kne","application/vnd.kinar"],[".knp","application/vnd.kinar"],[".skp","application/vnd.koan"],[".skd","application/vnd.koan"],[".skt","application/vnd.koan"],[".skm","application/vnd.koan"],[".sse","application/vnd.kodak-descriptor"],[".lbd","application/vnd.llamagraphics.life-balance.desktop"],[".lbe","application/vnd.llamagraphics.life-balance.exchange+xml"],[".123","application/vnd.lotus-1-2-3"],[".apr","application/vnd.lotus-approach"],[".pre","application/vnd.lotus-freelance"],[".nsf","application/vnd.lotus-notes"],[".org","application/vnd.lotus-organizer"],[".scm","application/vnd.lotus-screencam"],[".lwp","application/vnd.lotus-wordpro"],[".portpkg","application/vnd.macports.portpkg"],[".mcd","application/vnd.mcd"],[".mc1","application/vnd.medcalcdata"],[".cdkey","application/vnd.mediastation.cdkey"],[".mwf","application/vnd.mfer"],[".mfm","application/vnd.mfmp"],[".flo","application/vnd.micrografx.flo"],[".igx","application/vnd.micrografx.igx"],[".mif","application/vnd.mif"],[".daf","application/vnd.mobius.daf"],[".dis","application/vnd.mobius.dis"],[".mbk","application/vnd.mobius.mbk"],[".mqy","application/vnd.mobius.mqy"],[".msl","application/vnd.mobius.msl"],[".plc","application/vnd.mobius.plc"],[".txf","application/vnd.mobius.txf"],[".mpn","application/vnd.mophun.application"],[".mpc","application/vnd.mophun.certificate"],[".xul","application/vnd.mozilla.xul+xml"],[".cil","application/vnd.ms-artgalry"],[".cab","application/vnd.ms-cab-compressed"],[".xls","application/vnd.ms-excel"],[".xlm","application/vnd.ms-excel"],[".xla","application/vnd.ms-excel"],[".xlc","application/vnd.ms-excel"],[".xlt","application/vnd.ms-excel"],[".xlw","application/vnd.ms-excel"],[".xlam","application/vnd.ms-excel.addin.macroenabled.12"],[".xlsb","application/vnd.ms-excel.sheet.binary.macroenabled.12"],[".xlsm","application/vnd.ms-excel.sheet.macroenabled.12"],[".xltm","application/vnd.ms-excel.template.macroenabled.12"],[".eot","application/vnd.ms-fontobject"],[".chm","application/vnd.ms-htmlhelp"],[".ims","application/vnd.ms-ims"],[".lrm","application/vnd.ms-lrm"],[".cat","application/vnd.ms-pki.seccat"],[".stl","application/vnd.ms-pki.stl"],[".pot","application/vnd.ms-powerpoint"],[".pps","application/vnd.ms-powerpoint"],[".ppt","application/vnd.ms-powerpoint"],[".ppam","application/vnd.ms-powerpoint.addin.macroenabled.12"],[".pptm","application/vnd.ms-powerpoint.presentation.macroenabled.12"],[".sldm","application/vnd.ms-powerpoint.slide.macroenabled.12"],[".ppsm","application/vnd.ms-powerpoint.slideshow.macroenabled.12"],[".potm","application/vnd.ms-powerpoint.template.macroenabled.12"],[".mpp","application/vnd.ms-project"],[".mpt","application/vnd.ms-project"],[".docm","application/vnd.ms-word.document.macroenabled.12"],[".dotm","application/vnd.ms-word.template.macroenabled.12"],[".wdb","application/vnd.ms-works"],[".wcm","application/vnd.ms-works"],[".wks","application/vnd.ms-works"],[".wps","application/vnd.ms-works"],[".wpl","application/vnd.ms-wpl"],[".xps","application/vnd.ms-xpsdocument"],[".mseq","application/vnd.mseq"],[".mus","application/vnd.musician"],[".msty","application/vnd.muvee.style"],[".nlu","application/vnd.neurolanguage.nlu"],[".nnd","application/vnd.noblenet-directory"],[".nns","application/vnd.noblenet-sealer"],[".nnw","application/vnd.noblenet-web"],[".ngdat","application/vnd.nokia.n-gage.data"],[".n-gage","application/vnd.nokia.n-gage.symbian.install"],[".rpst","application/vnd.nokia.radio-preset"],[".rpss","application/vnd.nokia.radio-presets"],[".edm","application/vnd.novadigm.edm"],[".edx","application/vnd.novadigm.edx"],[".ext","application/vnd.novadigm.ext"],[".odc","application/vnd.oasis.opendocument.chart"],[".otc","application/vnd.oasis.opendocument.chart-template"],[".odb","application/vnd.oasis.opendocument.database"],[".odf","application/vnd.oasis.opendocument.formula"],[".odft","application/vnd.oasis.opendocument.formula-template"],[".odg","application/vnd.oasis.opendocument.graphics"],[".otg","application/vnd.oasis.opendocument.graphics-template"],[".odi","application/vnd.oasis.opendocument.image"],[".oti","application/vnd.oasis.opendocument.image-template"],[".odp","application/vnd.oasis.opendocument.presentation"],[".ods","application/vnd.oasis.opendocument.spreadsheet"],[".ots","application/vnd.oasis.opendocument.spreadsheet-template"],[".odt","application/vnd.oasis.opendocument.text"],[".otm","application/vnd.oasis.opendocument.text-master"],[".ott","application/vnd.oasis.opendocument.text-template"],[".oth","application/vnd.oasis.opendocument.text-web"],[".xo","application/vnd.olpc-sugar"],[".dd2","application/vnd.oma.dd2+xml"],[".oxt","application/vnd.openofficeorg.extension"],[".pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],[".sldx","application/vnd.openxmlformats-officedocument.presentationml.slide"],[".ppsx","application/vnd.openxmlformats-officedocument.presentationml.slideshow"],[".potx","application/vnd.openxmlformats-officedocument.presentationml.template"],[".xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],[".xltx","application/vnd.openxmlformats-officedocument.spreadsheetml.template"],[".docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],[".dotx","application/vnd.openxmlformats-officedocument.wordprocessingml.template"],[".dp","application/vnd.osgi.dp"],[".oprc","application/vnd.palm"],[".pqa","application/vnd.palm"],[".pdb","application/vnd.palm"],[".str","application/vnd.pg.format"],[".ei6","application/vnd.pg.osasli"],[".efif","application/vnd.picsel"],[".plf","application/vnd.pocketlearn"],[".pbd","application/vnd.powerbuilder6"],[".box","application/vnd.previewsystems.box"],[".mgz","application/vnd.proteus.magazine"],[".qps","application/vnd.publishare-delta-tree"],[".ptid","application/vnd.pvi.ptid1"],[".qxd","application/vnd.quark.quarkxpress"],[".qxt","application/vnd.quark.quarkxpress"],[".qwd","application/vnd.quark.quarkxpress"],[".qwt","application/vnd.quark.quarkxpress"],[".qxl","application/vnd.quark.quarkxpress"],[".qxb","application/vnd.quark.quarkxpress"],[".mxl","application/vnd.recordare.musicxml"],[".musicxml","application/vnd.recordare.musicxml+xml"],[".cod","application/vnd.rim.cod"],[".rm","application/vnd.rn-realmedia"],[".link66","application/vnd.route66.link66+xml"],[".see","application/vnd.seemail"],[".sema","application/vnd.sema"],[".semd","application/vnd.semd"],[".semf","application/vnd.semf"],[".ifm","application/vnd.shana.informed.formdata"],[".itp","application/vnd.shana.informed.formtemplate"],[".iif","application/vnd.shana.informed.interchange"],[".ipk","application/vnd.shana.informed.package"],[".twds","application/vnd.simtech-mindmapper"],[".twd","application/vnd.simtech-mindmapper"],[".mmf","application/vnd.smaf"],[".teacher","application/vnd.smart.teacher"],[".sdkm","application/vnd.solent.sdkm+xml"],[".sdkd","application/vnd.solent.sdkm+xml"],[".dxp","application/vnd.spotfire.dxp"],[".sfs","application/vnd.spotfire.sfs"],[".sdc","application/vnd.stardivision.calc"],[".sda","application/vnd.stardivision.draw"],[".sdd","application/vnd.stardivision.impress"],[".smf","application/vnd.stardivision.math"],[".sdw","application/vnd.stardivision.writer"],[".vor","application/vnd.stardivision.writer"],[".sgl","application/vnd.stardivision.writer-global"],[".sxc","application/vnd.sun.xml.calc"],[".stc","application/vnd.sun.xml.calc.template"],[".sxd","application/vnd.sun.xml.draw"],[".std","application/vnd.sun.xml.draw.template"],[".sxi","application/vnd.sun.xml.impress"],[".sti","application/vnd.sun.xml.impress.template"],[".sxm","application/vnd.sun.xml.math"],[".sxw","application/vnd.sun.xml.writer"],[".sxg","application/vnd.sun.xml.writer.global"],[".stw","application/vnd.sun.xml.writer.template"],[".susp","application/vnd.sus-calendar"],[".sus","application/vnd.sus-calendar"],[".svd","application/vnd.svd"],[".sis","application/vnd.symbian.install"],[".sisx","application/vnd.symbian.install"],[".xsm","application/vnd.syncml+xml"],[".bdm","application/vnd.syncml.dm+wbxml"],[".xdm","application/vnd.syncml.dm+xml"],[".tao","application/vnd.tao.intent-module-archive"],[".tmo","application/vnd.tmobile-livetv"],[".tpt","application/vnd.trid.tpt"],[".mxs","application/vnd.triscape.mxs"],[".tra","application/vnd.trueapp"],[".ufdl","application/vnd.ufdl"],[".ufd","application/vnd.ufdl"],[".utz","application/vnd.uiq.theme"],[".umj","application/vnd.umajin"],[".unityweb","application/vnd.unity"],[".uoml","application/vnd.uoml+xml"],[".vcx","application/vnd.vcx"],[".vsw","application/vnd.visio"],[".vss","application/vnd.visio"],[".vst","application/vnd.visio"],[".vsd","application/vnd.visio"],[".vis","application/vnd.visionary"],[".vsf","application/vnd.vsf"],[".wbxml","application/vnd.wap.wbxml"],[".wmlc","application/vnd.wap.wmlc"],[".wmlsc","application/vnd.wap.wmlscriptc"],[".wtb","application/vnd.webturbo"],[".wpd","application/vnd.wordperfect"],[".wqd","application/vnd.wqd"],[".stf","application/vnd.wt.stf"],[".xar","application/vnd.xara"],[".xfdl","application/vnd.xfdl"],[".hvd","application/vnd.yamaha.hv-dic"],[".hvs","application/vnd.yamaha.hv-script"],[".hvp","application/vnd.yamaha.hv-voice"],[".osf","application/vnd.yamaha.openscoreformat"],[".osfpvg","application/vnd.yamaha.openscoreformat.osfpvg+xml"],[".saf","application/vnd.yamaha.smaf-audio"],[".spf","application/vnd.yamaha.smaf-phrase"],[".cmp","application/vnd.yellowriver-custom-menu"],[".zir","application/vnd.zul"],[".zirz","application/vnd.zul"],[".zaz","application/vnd.zzazz.deck+xml"],[".vxml","application/voicexml+xml"],[".hlp","application/winhlp"],[".wsdl","application/wsdl+xml"],[".wspolicy","application/wspolicy+xml"],[".abw","application/x-abiword"],[".ace","application/x-ace-compressed"],[".aab","application/x-authorware-bin"],[".x32","application/x-authorware-bin"],[".u32","application/x-authorware-bin"],[".vox","application/x-authorware-bin"],[".aam","application/x-authorware-map"],[".aas","application/x-authorware-seg"],[".bcpio","application/x-bcpio"],[".torrent","application/x-bittorrent"],[".bz","application/x-bzip"],[".bz2","application/x-bzip2"],[".boz","application/x-bzip2"],[".vcd","application/x-cdlink"],[".chat","application/x-chat"],[".pgn","application/x-chess-pgn"],[".cpio","application/x-cpio"],[".csh","application/x-csh"],[".deb","application/x-debian-package"],[".udeb","application/x-debian-package"],[".swa","application/x-director"],[".w3d","application/x-director"],[".fgd","application/x-director"],[".cxt","application/x-director"],[".cct","application/x-director"],[".cst","application/x-director"],[".dxr","application/x-director"],[".dcr","application/x-director"],[".dir","application/x-director"],[".wad","application/x-doom"],[".ncx","application/x-dtbncx+xml"],[".dtb","application/x-dtbook+xml"],[".res","application/x-dtbresource+xml"],[".dvi","application/x-dvi"],[".bdf","application/x-font-bdf"],[".gsf","application/x-font-ghostscript"],[".psf","application/x-font-linux-psf"],[".otf","application/x-font-otf"],[".pcf","application/x-font-pcf"],[".snf","application/x-font-snf"],[".ttf","application/x-font-ttf"],[".ttc","application/x-font-ttf"],[".woff","application/font-woff"],[".pfa","application/x-font-type1"],[".pfb","application/x-font-type1"],[".pfm","application/x-font-type1"],[".afm","application/x-font-type1"],[".spl","application/x-futuresplash"],[".gnumeric","application/x-gnumeric"],[".gtar","application/x-gtar"],[".hdf","application/x-hdf"],[".jnlp","application/x-java-jnlp-file"],[".latex","application/x-latex"],[".prc","application/x-mobipocket-ebook"],[".mobi","application/x-mobipocket-ebook"],[".application","application/x-ms-application"],[".wmd","application/x-ms-wmd"],[".wmz","application/x-ms-wmz"],[".xbap","application/x-ms-xbap"],[".mdb","application/x-msaccess"],[".obd","application/x-msbinder"],[".crd","application/x-mscardfile"],[".clp","application/x-msclip"],[".msi","application/x-msdownload"],[".bat","application/x-msdownload"],[".com","application/x-msdownload"],[".dll","application/x-msdownload"],[".exe","application/x-msdownload"],[".mvb","application/x-msmediaview"],[".m13","application/x-msmediaview"],[".m14","application/x-msmediaview"],[".wmf","application/x-msmetafile"],[".mny","application/x-msmoney"],[".pub","application/x-mspublisher"],[".scd","application/x-msschedule"],[".trm","application/x-msterminal"],[".wri","application/x-mswrite"],[".nc","application/x-netcdf"],[".cdf","application/x-netcdf"],[".p12","application/x-pkcs12"],[".pfx","application/x-pkcs12"],[".p7b","application/x-pkcs7-certificates"],[".spc","application/x-pkcs7-certificates"],[".p7r","application/x-pkcs7-certreqresp"],[".rar","application/x-rar-compressed"],[".sh","application/x-sh"],[".shar","application/x-shar"],[".swf","application/x-shockwave-flash"],[".xap","application/x-silverlight-app"],[".sit","application/x-stuffit"],[".sitx","application/x-stuffitx"],[".sv4cpio","application/x-sv4cpio"],[".sv4crc","application/x-sv4crc"],[".tar","application/x-tar"],[".tcl","application/x-tcl"],[".tex","application/x-tex"],[".tfm","application/x-tex-tfm"],[".texinfo","application/x-texinfo"],[".texi","application/x-texinfo"],[".ustar","application/x-ustar"],[".src","application/x-wais-source"],[".der","application/x-x509-ca-cert"],[".crt","application/x-x509-ca-cert"],[".fig","application/x-xfig"],[".xpi","application/x-xpinstall"],[".xenc","application/xenc+xml"],[".xhtml","application/xhtml+xml"],[".xht","application/xhtml+xml"],[".xsl","application/xml"],[".xml","application/xml"],[".dtd","application/xml-dtd"],[".xop","application/xop+xml"],[".xslt","application/xslt+xml"],[".xspf","application/xspf+xml"],[".xvm","application/xv+xml"],[".xvml","application/xv+xml"],[".xhvml","application/xv+xml"],[".mxml","application/xv+xml"],[".zip","application/zip"],[".adp","audio/adpcm"],[".au","audio/basic"],[".snd","audio/basic"],[".mid","audio/midi"],[".midi","audio/midi"],[".kar","audio/midi"],[".rmi","audio/midi"],[".mp4a","audio/mp4"],[".m4a","audio/mp4a-latm"],[".m4p","audio/mp4a-latm"],[".m3a","audio/mpeg"],[".m2a","audio/mpeg"],[".mp3","audio/mpeg"],[".mp2a","audio/mpeg"],[".mp2","audio/mpeg"],[".mpga","audio/mpeg"],[".spx","audio/ogg"],[".ogg","audio/ogg"],[".oga","audio/ogg"],[".eol","audio/vnd.digital-winds"],[".dts","audio/vnd.dts"],[".dtshd","audio/vnd.dts.hd"],[".lvp","audio/vnd.lucent.voice"],[".pya","audio/vnd.ms-playready.media.pya"],[".ecelp4800","audio/vnd.nuera.ecelp4800"],[".ecelp7470","audio/vnd.nuera.ecelp7470"],[".ecelp9600","audio/vnd.nuera.ecelp9600"],[".aac","audio/x-aac"],[".aif","audio/x-aiff"],[".aiff","audio/x-aiff"],[".aif","audio/x-aiff"],[".m3u","audio/x-mpegurl"],[".wax","audio/x-ms-wax"],[".wma","audio/x-ms-wma"],[".ram","audio/x-pn-realaudio"],[".ra","audio/x-pn-realaudio"],[".rmp","audio/x-pn-realaudio-plugin"],[".wav","audio/x-wav"],[".cdx","chemical/x-cdx"],[".cif","chemical/x-cif"],[".cmdf","chemical/x-cmdf"],[".cml","chemical/x-cml"],[".csml","chemical/x-csml"],[".xyz","chemical/x-xyz"],[".bmp","image/bmp"],[".cgm","image/cgm"],[".g3","image/g3fax"],[".gif","image/gif"],[".ief","image/ief"],[".jp2","image/jp2"],[".jpeg","image/jpeg"],[".jpg","image/jpeg"],[".jpe","image/jpeg"],[".pict","image/pict"],[".pic","image/pict"],[".pct","image/pict"],[".png","image/png"],[".btif","image/prs.btif"],[".svg","image/svg+xml"],[".svgz","image/svg+xml"],[".tiff","image/tiff"],[".tif","image/tiff"],[".psd","image/vnd.adobe.photoshop"],[".djvu","image/vnd.djvu"],[".djv","image/vnd.djvu"],[".dwg","image/vnd.dwg"],[".dxf","image/vnd.dxf"],[".fbs","image/vnd.fastbidsheet"],[".fpx","image/vnd.fpx"],[".fst","image/vnd.fst"],[".mmr","image/vnd.fujixerox.edmics-mmr"],[".rlc","image/vnd.fujixerox.edmics-rlc"],[".mdi","image/vnd.ms-modi"],[".npx","image/vnd.net-fpx"],[".wbmp","image/vnd.wap.wbmp"],[".xif","image/vnd.xiff"],[".ras","image/x-cmu-raster"],[".cmx","image/x-cmx"],[".fh","image/x-freehand"],[".fhc","image/x-freehand"],[".fh4","image/x-freehand"],[".fh5","image/x-freehand"],[".fh7","image/x-freehand"],[".ico","image/x-icon"],[".pntg","image/x-macpaint"],[".pnt","image/x-macpaint"],[".mac","image/x-macpaint"],[".pcx","image/x-pcx"],[".pic","image/x-pict"],[".pct","image/x-pict"],[".pnm","image/x-portable-anymap"],[".pbm","image/x-portable-bitmap"],[".pgm","image/x-portable-graymap"],[".ppm","image/x-portable-pixmap"],[".qtif","image/x-quicktime"],[".qti","image/x-quicktime"],[".rgb","image/x-rgb"],[".xbm","image/x-xbitmap"],[".xpm","image/x-xpixmap"],[".xwd","image/x-xwindowdump"],[".eml","message/rfc822"],[".mime","message/rfc822"],[".igs","model/iges"],[".iges","model/iges"],[".msh","model/mesh"],[".mesh","model/mesh"],[".silo","model/mesh"],[".dwf","model/vnd.dwf"],[".gdl","model/vnd.gdl"],[".gtw","model/vnd.gtw"],[".mts","model/vnd.mts"],[".vtu","model/vnd.vtu"],[".wrl","model/vrml"],[".vrml","model/vrml"],[".ics","text/calendar"],[".ifb","text/calendar"],[".css","text/css"],[".csv","text/csv"],[".html","text/html"],[".htm","text/html"],[".txt","text/plain"],[".text","text/plain"],[".conf","text/plain"],[".def","text/plain"],[".list","text/plain"],[".log","text/plain"],[".in","text/plain"],[".dsc","text/prs.lines.tag"],[".rtx","text/richtext"],[".sgml","text/sgml"],[".sgm","text/sgml"],[".tsv","text/tab-separated-values"],[".t","text/troff"],[".tr","text/troff"],[".roff","text/troff"],[".man","text/troff"],[".me","text/troff"],[".ms","text/troff"],[".uri","text/uri-list"],[".uris","text/uri-list"],[".urls","text/uri-list"],[".curl","text/vnd.curl"],[".dcurl","text/vnd.curl.dcurl"],[".scurl","text/vnd.curl.scurl"],[".mcurl","text/vnd.curl.mcurl"],[".fly","text/vnd.fly"],[".flx","text/vnd.fmi.flexstor"],[".gv","text/vnd.graphviz"],[".3dml","text/vnd.in3d.3dml"],[".spot","text/vnd.in3d.spot"],[".jad","text/vnd.sun.j2me.app-descriptor"],[".wml","text/vnd.wap.wml"],[".wmls","text/vnd.wap.wmlscript"],[".s","text/x-asm"],[".asm","text/x-asm"],[".c","text/x-c"],[".cc","text/x-c"],[".cxx","text/x-c"],[".cpp","text/x-c"],[".h","text/x-c"],[".hh","text/x-c"],[".dic","text/x-c"],[".f","text/x-fortran"],[".for","text/x-fortran"],[".f77","text/x-fortran"],[".f90","text/x-fortran"],[".p","text/x-pascal"],[".pas","text/x-pascal"],[".java","text/x-java-source"],[".etx","text/x-setext"],[".uu","text/x-uuencode"],[".vcs","text/x-vcalendar"],[".vcf","text/x-vcard"],[".3gp","video/3gpp"],[".3g2","video/3gpp2"],[".h261","video/h261"],[".h263","video/h263"],[".h264","video/h264"],[".jpgv","video/jpeg"],[".jpm","video/jpm"],[".jpgm","video/jpm"],[".mj2","video/mj2"],[".mjp2","video/mj2"],[".mp4","video/mp4"],[".mp4v","video/mp4"],[".mpg4","video/mp4"],[".m4v","video/mp4"],[".mkv","video/x-matroska"],[".mk3d","video/x-matroska"],[".mka","video/x-matroska"],[".mks","video/x-matroska"],[".webm","video/webm"],[".mpeg","video/mpeg"],[".mpg","video/mpeg"],[".mpe","video/mpeg"],[".m1v","video/mpeg"],[".m2v","video/mpeg"],[".ogv","video/ogg"],[".qt","video/quicktime"],[".mov","video/quicktime"],[".fvt","video/vnd.fvt"],[".mxu","video/vnd.mpegurl"],[".m4u","video/vnd.mpegurl"],[".pyv","video/vnd.ms-playready.media.pyv"],[".viv","video/vnd.vivo"],[".dv","video/x-dv"],[".dif","video/x-dv"],[".f4v","video/x-f4v"],[".fli","video/x-fli"],[".flv","video/x-flv"],[".m4v","video/x-m4v"],[".asf","video/x-ms-asf"],[".asx","video/x-ms-asf"],[".wm","video/x-ms-wm"],[".wmv","video/x-ms-wmv"],[".wmx","video/x-ms-wmx"],[".wvx","video/x-ms-wvx"],[".avi","video/x-msvideo"],[".movie","video/x-sgi-movie"],[".ice","x-conference/x-cooltalk"],[".indd","application/x-indesign"],[".dat","application/octet-stream"],[".gz","application/x-gzip"],[".tgz","application/x-tar"],[".tar","application/x-tar"],[".epub","application/epub+zip"],[".mobi","application/x-mobipocket-ebook"],["README","text/plain"],["LICENSE","text/plain"],["COPYING","text/plain"],["TODO","text/plain"],["ABOUT","text/plain"],["AUTHORS","text/plain"],["CONTRIBUTORS","text/plain"],["manifest","text/cache-manifest"],[".manifest","text/cache-manifest"],[".mf","text/cache-manifest"],[".appcache","text/cache-manifest"]]);function ot(){if("undefined"!=typeof window){const[e]=performance.getEntriesByType("navigation"),[t={},n={}]=performance.getEntriesByType("paint"),{startTime:i}=t,{startTime:a}=n,{domainLookupEnd:o,domainLookupStart:r,connectEnd:s,connectStart:p,secureConnectionStart:c,loadEventStart:l,domInteractive:d,domContentLoadedEventEnd:m,duration:h,responseStart:u,requestStart:f,responseEnd:g,fetchStart:v,transferSize:w,encodedBodySize:x,redirectEnd:y,redirectStart:b,redirectCount:k}=e;return{dnsSearch:o-r,tcpConnect:s-p,sslConnect:s-c,request:u-f,response:g-u,parseDomTree:d-g,resource:l-m,domReady:m-v,interactive:d-v,complete:l-v,httpHead:w-x,redirect:k,redirectTime:y-b,duration:h,fp:i,fcp:a}}}const rt=({url:e="",type:t="application/json; charset=UTF-8",payload:n={}})=>{const i=e||Ee();return"undefined"!=typeof navigator?(({url:e="",type:t="application/json; charset=UTF-8",payload:n={}})=>{const i=e||Ee();if(navigator.sendBeacon&&i){const e=new Blob([JSON.stringify(n)],{type:t});return navigator.sendBeacon(i,e)}})({url:i,type:t,payload:n}):(({url:e="",payload:t={}})=>{const n=e||Ee();if("undefined"!=typeof document&&n){const e=new Image;e.width=1,e.height=1,e.src=`${n}?${Ge(t)}`}})({url:i,payload:n})};function st(e={}){if("undefined"!=typeof window){const{width:t,height:n}=Te();return Object.assign({},{id:Ae(),path:window.location.href,time:Date.now(),referrer:document.referrer,ip:window.returnCitySN||{cid:"",cip:"",cname:""},userId:Ue("chaxus_prod"),ratio:`${t}x${n}`,userAgent:window.navigator.userAgent},e)}return{}}const pt=(e={})=>{if("undefined"!=typeof window){const{requestHook:t=l,responseHook:n=l,errorHook:i=l}=e;Je(window,"fetch",(e=>(a,o)=>(t(a,o),e.apply(window,[a,o]).then((e=>(n(a,o,e),e))).catch((e=>{throw i(a,e),e})))))}},ct=(e={})=>{if("undefined"!=typeof window){const t=XMLHttpRequest.prototype,{requestHook:n=l,responseHook:i=l,errorHook:a=l}=e;Je(t,"open",(e=>function(...t){n(t),e.apply(this,t)}));Je(t,"send",(e=>function(...t){this.addEventListener("loadend",(function(){i(this)})),this.addEventListener("error",(function(){a(this)})),e.apply(this,t)}))}},lt=(e,t=300)=>{let n;return function(){const i=this,a=arguments;n||(n=setTimeout((()=>{n=null,e.apply(i,a)}),t))}};const dt=new Map([[100,"Continue"],[101,"Switching Protocols"],[102,"Processing"],[103,"Early Hints"],[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,"Too Early"],[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"]]),mt={message:dt,code:function(e){const t=new Map;for(const[n,i]of e)t.set(i.toLowerCase(),n);return t}(dt),codes:function(e){const t=[];for(const[n,i]of e)t.push(n);return t}(dt),redirect:{300:!0,301:!0,302:!0,303:!0,305:!0,307:!0,308:!0},empty:{204:!0,205:!0,304:!0},retry:{502:!0,503:!0,504:!0}};function ht(e){if(!mt.message.has(e))throw new Error("invalid status code: "+e);return mt.message.get(e)}const ut=class{constructor(){n(this,"getDecimalLength",(e=>{const[t,n]=e.toString().split(".");return n?n.length:0})),n(this,"amend",((e,t=15)=>parseFloat(Number(e).toPrecision(t)))),n(this,"power",((e,t)=>Math.pow(10,Math.max(this.getDecimalLength(e),this.getDecimalLength(t)))))}};n(ut,"handleMethod",((e,t)=>{const n=new ut,{power:i,amend:a}=n,o=i(e,t),r=a(e*o),s=a(t*o);return e=>{switch(e){case"+":return(r+s)/o;case"-":return(r-s)/o;case"*":return r*s/(o*o);case"/":return r/s}}})),n(ut,"add",((e,t)=>ut.handleMethod(e,t)("+"))),n(ut,"divide",((e,t)=>ut.handleMethod(e,t)("/"))),n(ut,"multiply",((e,t)=>ut.handleMethod(e,t)("*"))),n(ut,"subtract",((e,t)=>ut.handleMethod(e,t)("-")));let ft=ut;const gt="NEW_LISTENER";e.AudioRecorder=class{constructor(){n(this,"startTime"),n(this,"chunks"),n(this,"mediaRecorder"),n(this,"blob"),this.startTime=Date.now(),this.chunks=[],navigator.mediaDevices.getUserMedia({audio:!0}).then((e=>{this.init(e)})).catch((e=>{}))}init(e){var t,n;const i=function(){const e=["audio/webm","audio/mp4","audio/ogg","audio/wav","audio/aac"];for(let t=0;t<e.length;t++)if(MediaRecorder.isTypeSupported(e[t]))return e[t]}();this.mediaRecorder=new MediaRecorder(e,{mimeType:i}),null==(t=this.mediaRecorder)||t.addEventListener("dataavailable",(async e=>{var t;if(e.data.size>0&&this.chunks.push(e.data),"inactive"===(null==(t=this.mediaRecorder)?void 0:t.state)){const e=Date.now()-this.startTime;this.blob=new Blob(this.chunks,{type:i}),"audio/webm"===i&&(this.blob=await((e,t,n="video/webm")=>new Promise(((i,a)=>{try{const o=new FileReader;o.addEventListener("loadend",(()=>{try{const a=o.result,r=new c(new Uint8Array(a));r.fixDuration(t)?i(r.toBlob(n)):i(e)}catch(r){a(r)}})),o.addEventListener("error",(()=>a())),o.readAsArrayBuffer(e)}catch(o){a(o)}})))(this.blob,e,this.blob.type)),this.chunks=[]}})),null==(n=this.mediaRecorder)||n.start()}start(){var e;return"paused"===(null==(e=this.mediaRecorder)?void 0:e.state)&&this.mediaRecorder.resume(),this.mediaRecorder}pause(){var e;return"recording"===(null==(e=this.mediaRecorder)?void 0:e.state)&&this.mediaRecorder.pause(),this.mediaRecorder}stop(){var e;return null==(e=this.mediaRecorder)||e.stop(),this.blob}},e.Chain=nt,e.Color=Pe,e.ColorScheme=class{constructor(e,t){n(this,"palette"),this.palette=[],void 0===t&&e instanceof Array?this.createFromColors(e):this.createFromAngles(e,t)}createFromColors(e){for(const t in e)Object.prototype.hasOwnProperty.call(e,t)&&this.palette.push(new Pe(e[t]));return this.palette}createFromAngles(e,t){this.palette.push(new Pe(e));for(const n in t)if(Object.prototype.hasOwnProperty.call(t,n)){const e=(Number(this.palette[0].h)+t[n])%360;this.palette.push(new Pe(Ve(e,Number(this.palette[0].s),Number(this.palette[0].l))))}return this.palette}static Compl(e){return new this(e,[180])}static Triad(e){return new this(e,[120,240])}static Tetrad(e){return new this(e,[60,180,240])}static Analog(e){return new this(e,[-45,45])}static Split(e){return new this(e,[150,210])}static Accent(e){return new this(e,[-45,45,180])}},e.FMT={bold:["[1m","[22m"],dim:["[2m","[22m"],reset:["[0m","[0m"],italic:["[3m","[23m"],underline:["[4m","[24m"],inverse:["[7m","[27m"],hidden:["[8m","[28m"],strikethrough:["[9m","[29m"],black:["[30m","[39m"],red:["[31m","[39m"],green:["[32m","[39m"],yellow:["[33m","[39m"],blue:["[34m","[39m"],magenta:["[35m","[39m"],cyan:["[36m","[39m"],white:["[37m","[39m"],gray:["[90m","[39m"],bgBlack:["[40m","[49m"],bgRed:["[41m","[49m"],bgGreen:["[42m","[49m"],bgYellow:["[43m","[49m"],bgBlue:["[44m","[49m"],bgMagenta:["[45m","[49m"],bgCyan:["[46m","[49m"],bgWhite:["[47m","[49m"]},e.Hsl=De,e.Hsla=je,e.Mathjs=ft,e.MimeType=at,e.Monitor=class{constructor(){n(this,"init",(()=>{this.reportClick(),this.reportError(),this.reportFetch(),this.reportPerformance(),this.reportXhr()})),this.initialize()}reportPerformance(){const e=ot(),t=st();rt({payload:{...e,...t}})}log(e){rt({payload:e})}reportClick(){const e=lt(rt),t=st();((e=l)=>{"undefined"!=typeof document&&document.addEventListener("click",(function(t){e(t)}),!0)})((n=>{const{pageX:i,pageY:a,screenX:o,screenY:r,type:s}=n;e({payload:{...t,data:{pageX:i,pageY:a,screenX:o,screenY:r,type:s},type:"click"}})}))}reportXhr(){const e=lt(rt),t=st();ct({requestHook:(...n)=>{e({payload:{...t,data:{...n},type:"xhrRequest"}})},responseHook:(...n)=>{e({payload:{...t,data:{...n},type:"xhrResponse"}})},errorHook:(...n)=>{e({payload:{...t,data:{...n},type:"xhrError"}})}})}reportFetch(){const e=lt(rt),t=st();pt({requestHook:(...n)=>{e({payload:{...t,data:{...n},type:"fetchRequest"}})},responseHook:(...n)=>{e({payload:{...t,data:{...n},type:"fetchResponse"}})},errorHook:(...n)=>{e({payload:{...t,data:{...n},type:"fetchError"}})}})}reportError(){const e=lt(rt),t=st();it(((...n)=>{e({payload:{...t,data:{...n},type:"error"}})}))}reportConsole(){const e=lt(rt),t=st();Ze(((...n)=>{e({payload:{...t,data:{...n},type:"console"}})}))}initialize(){"undefined"==typeof window||window.ranlog||(window.ranlog=!0,this.init()),"undefined"==typeof process||process.ranlog||(process.ranlog=!0,this.init())}},e.QuestQueue=class{constructor({simultaneous:e,total:t}){n(this,"current"),n(this,"queue"),n(this,"simultaneous"),n(this,"executed"),n(this,"total"),n(this,"add",(e=>{if("function"!=typeof e)return;this.queue.push((()=>new Promise(((t,n)=>{this.current++,e().then(t).catch(n).finally((()=>{this.current--,this.running()}))}))))})),n(this,"running",(()=>new Promise(((e,t)=>{if(this.current<=this.simultaneous&&this.queue.length){const n=this.queue.pop();n&&n().then(e).catch(t).finally((()=>{this.executed++}))}else e({})})))),n(this,"allSettled",(()=>{let e=0;return new Promise(((t,n)=>{const i=[];if(this.current<this.simultaneous&&this.queue.length){const a=this.queue.pop();e++,a&&a().then((n=>{i[e]=n,t(n)})).catch((t=>{i[e]=t,n(t)})).finally((()=>{this.executed++}))}this.executed>=this.total&&t(i)}))})),this.current=0,this.queue=[],this.simultaneous=e,this.executed=0,this.total=t}},e.Rgb=He,e.Rgba=ze,e.SyncHook=class{constructor(){n(this,"_events"),n(this,"tap",((e,t)=>{this._events[e]&&e!==Symbol.for(gt)&&this.call(Symbol.for(gt),e);const n=this._events[e]||[];return"function"==typeof t?n.push({name:e,callback:t}):n.push(t),this._events[e]=n,this})),n(this,"call",((e,...t)=>{(this._events[e]||[]).forEach((e=>{const{callback:n}=e;n(...t)}))})),n(this,"callSync",(async(e,...t)=>{const n=this._events[e]||[];for(const i of n){const{callback:e}=i;await e(...t)}})),n(this,"once",((e,t)=>{let n;if("function"==typeof t)n={name:e,callback:(...i)=>{t(...i),this.off(e,n)},initialCallback:t};else{const{callback:i}=t;n={name:e,callback:(...t)=>{i(...t),this.off(e,n)},initialCallback:i}}return this.tap(e,n),this})),n(this,"off",((e,t)=>{const n=(this._events[e]||[]).filter((e=>{if("function"==typeof t)return e.callback!==t&&e.initialCallback!==t;{const{callback:n}=t;return e.callback!==n&&e.initialCallback!==n}}));return this._events[e]=n,this})),this._events={}}},e.TOTP=class{static generate(e,t){const n={digits:6,algorithm:"SHA-1",period:30,timestamp:Date.now(),...t},i=Math.floor(n.timestamp/1e3),a=this.leftpad(this.dec2hex(Math.floor(i/n.period)),16,"0"),o=new be(n.algorithm,"HEX");o.setHMACKey(this.base32tohex(e),"HEX"),o.update(a);const r=o.getHMAC("HEX"),s=this.hex2dec(r.substring(r.length-1));let p=(this.hex2dec(r.substr(2*s,8))&this.hex2dec("7fffffff"))+"";const c=Math.max(p.length-n.digits,0);p=p.substring(c,c+n.digits);return{otp:p,expires:Math.ceil((n.timestamp+1)/(1e3*n.period))*n.period*1e3}}static hex2dec(e){return parseInt(e,16)}static dec2hex(e){return(e<15.5?"0":"")+Math.round(e).toString(16)}static base32tohex(e){let t="",n="";const i=e.replace(/=+$/,"");for(let a=0;a<i.length;a++){const n="ABCDEFGHIJKLMNOPQRSTUVWXYZ234567".indexOf(e.charAt(a).toUpperCase());if(-1===n)throw new Error("Invalid base32 character in key");t+=this.leftpad(n.toString(2),5,"0")}for(let a=0;a+8<=t.length;a+=8){const e=t.substr(a,8);n+=this.leftpad(parseInt(e,2).toString(16),2,"0")}return n}static leftpad(e,t,n){return t+1>=e.length&&(e=Array(t+1-e.length).join(n)+e),e}},e.addClassToElement=(e,t)=>{if("undefined"==typeof document)return;const n=e.classList;n.contains(t)||n.add(t)},e.appendUrl=function(e,t={}){let n=e;0===n.indexOf("//")&&(n=n.replace("//","https://"));const i=new URL(n);return t&&Object.keys(t).forEach((e=>{t[e]&&i.searchParams.set(e,t[e])})),i.href},e.audioVendor=()=>new Promise(((e,t)=>{h||t("window is undefined");const n=new(window.OfflineAudioContext||window.webkitOfflineAudioContext)(1,44100,44100),i=n.createOscillator();i.type="triangle",i.frequency.setValueAtTime(1e4,n.currentTime);const a=n.createDynamicsCompressor();!function(e,t){if(Array.prototype.forEach&&e.forEach===Array.prototype.forEach)e.forEach(t);else if(e.length===+e.length)for(let n=0,i=e.length;n<i;n++)t(e[n],n,e);else for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&t(e[n],Number(n),e)}([["threshold",-50],["knee",40],["ratio",12],["reduction",-20],["attack",0],["release",.25]],(function(e){if(a[e[0]]&&"number"!=typeof a[e[0]]){const{setValueAtTime:t}=a[e[0]];t(e[1],n.currentTime)}})),i.connect(a),a.connect(n.destination),i.start(0),n.startRendering();const o=setTimeout((function(){return n.oncomplete=()=>{},t("audioTimeout"),"audioTimeout"}),100);n.oncomplete=n=>{try{clearTimeout(o);const t=n.renderedBuffer.getChannelData(0).slice(4500,5e3).reduce((function(e,t){return e+Math.abs(t)}),0).toString();return i.disconnect(),a.disconnect(),e(t),t}catch(r){return void t(r)}}})),e.canvasVendor=()=>{const e=document.createElement("canvas"),t=e.getContext("2d"),n="BrowserLeaks,com <canvas> 1.0";if(!t)return null;t.textBaseline="top",t.font="14px 'Arial'",t.textBaseline="alphabetic",t.fillStyle="#f60",t.fillRect(125,1,62,20),t.fillStyle="#069",t.fillText(n,2,15),t.fillStyle="rgba(102, 204, 0, 0.7)",t.fillText(n,4,17);return e.toDataURL()},e.changeHumpToLowerCase=function(e){const t=e.split("");return e=t.map((e=>e.toUpperCase()===e?"_"+e.toLowerCase():e)).join("")},e.clearBr=(e="")=>0===e.length?"":e.replace(/\s+/g,"").replace(/<\/?.+?>/g,"").replace(/[\r\n]/g,""),e.clearStr=Oe,e.componentToHex=qe,e.compose=function(e){if(!Array.isArray(e))throw new TypeError("Middleware stack must be an array!");for(const t of e)if("function"!=typeof t)throw new TypeError("Middleware must be composed of functions!");return function(t,n){let i=-1;return function a(o){if(o<=i)return Promise.reject(new Error("next() called multiple times"));i=o;let r=e[o];o===e.length&&n&&(r=n);if(!r)return Promise.resolve();try{return Promise.resolve(r(t,a.bind(null,o+1)))}catch(s){return Promise.reject(s)}}(0)}},e.connection=()=>{if("undefined"!=typeof window)return window.navigator.connection},e.convertImageToBase64=e=>new Promise(((t,n)=>{const i=new FileReader;i.onload=function(){t({success:!0,data:i.result,message:""})},i.onerror=e=>{n({success:!1,data:e,message:""})},i.readAsDataURL(e)})),e.create=(e,t)=>new nt(e,t),e.createData=st,e.createDocumentFragment=e=>{if("undefined"==typeof document)return;const t=document.createDocumentFragment();return e.forEach((e=>t.appendChild(e))),t},e.createObjectURL=async e=>{if("string"==typeof e)return e;if(e instanceof Blob)return URL.createObjectURL(e);if(e instanceof ArrayBuffer)return URL.createObjectURL(new Blob([e]));if(e instanceof Response){const t=await e.blob();return URL.createObjectURL(t)}return e},e.currentDevice=m,e.debounce=(e,t=500)=>{let n;return(...i)=>{clearTimeout(n),n=setTimeout((()=>{e.apply(void 0,i)}),t)}},e.durationHandler=Fe,e.encodeUrl=function(e){return String(e).replace(Me,"$1�$2").replace(Be,encodeURI)},e.escapeHtml=function(e){const t=""+e,n=et.exec(t);if(!n)return t;let i,a="",o=0,r=0;for(o=n.index;o<t.length;o++){switch(t.charCodeAt(o)){case 34:i=""";break;case 38:i="&";break;case 39:i="'";break;case 60:i="<";break;case 62:i=">";break;default:continue}r!==o&&(a+=t.substring(r,o)),r=o+1,a+=i}return r!==o?a+t.substring(r,o):a},e.filterObj=(e,t)=>{const n={};return Object.keys(e).forEach((i=>{t.includes(i)||(n[i]=e[i])})),n},e.formatJson=(e,t=()=>{})=>{let n="",i=0;let a=((e,t=e=>{})=>{let n="";if("[object String]"!==Object.prototype.toString.call(e))try{n=JSON.stringify(e)}catch(i){t(i)}else try{e="string"==typeof e?e.replace(/(')/g,'"'):JSON.stringify(e),n=JSON.stringify(JSON.parse(e))}catch(i){t(i)}return n})(e,t);if(!a)return a;const o=[];let r=null,s=null,p=[];return a=a.replace(/([{}])/g,"\r\n$1\r\n"),a=a.replace(/([[\]])/g,"\r\n$1\r\n"),a=a.replace(/(,)/g,"$1\r\n"),a=a.replace(/(\r\n\r\n)/g,"\r\n"),a=a.replace(/\r\n,/g,","),p=a.split("\r\n"),p.forEach((function(e,t){var n;const i=e.match(/"/g)&&(null==(n=e.match(/"/g))?void 0:n.length)||0;i%2&&!r&&(r=t),i%2&&r&&r!==t&&(s=t),r&&s&&(o.push({start:r,end:s}),r=null,s=null)})),o.reverse().forEach((function(e,t){const n=p.slice(e.start,e.end+1);p.splice(e.start,e.end+1-e.start,n.join(""))})),a=p.join("\r\n"),a=a.replace(/:\r\n\{/g,":{"),a=a.replace(/:\r\n\[/g,":["),p=a.split("\r\n"),p.forEach((function(e,t){let a=0,o=0,r="";for(e.match(/\{$/)||e.match(/\[$/)?o+=1:e.match(/\}$/)||e.match(/\]$/)||e.match(/\},$/)||e.match(/\],$/)?0!==i&&(i-=1):o=0,a=0;a<i;a++)r+=" ";n+=r+e+"\r\n",i+=o})),n.trim()},e.generateThrottle=()=>{let e;return function(t,n=300){return function(...i){e&&(clearTimeout(e),e=void 0);const a=this;e||(e=setTimeout((()=>{t.apply(a,i),clearTimeout(e),e=void 0}),n))}}},e.getAllQueryString=e=>{if("undefined"!=typeof window){const t={},n=e||window.location.href;if(n.split("?")[1]){n.split("?")[1].split("&").forEach((e=>{const[n,i]=e.split("=");n&&i&&(t[n]=decodeURIComponent(i))}))}return t}return{}},e.getCookie=Ue,e.getCookieByName=function(e){if("undefined"!=typeof window){const t=document.cookie.match(new RegExp(`(^| )${e}(?:=([^;]*))?(;|$)`));if(t&&t[2])return t[2]}return""},e.getFrame=(e=10)=>{const t=[];let n,i=0;return new Promise((a=>{const o=()=>{const r=Ce(),s=r-i;if(0!==i&&t.push(s),i=r,t.length>e){const i=t.reduce(((e,t)=>e+t));a(1/(i/e)),cancelAnimationFrame(n)}n=requestAnimationFrame(o)};t.length<=e&&(n=requestAnimationFrame(o))}))},e.getHost=Ee,e.getMime=function(e){const t=(""+e).trim().toLowerCase();let n=t.lastIndexOf(".");const i=~n?t.substring(++n):t;return at.get(`.${i}`)||at.get(i)},e.getPerformance=ot,e.getPixelRatio=e=>{const t=e.backingStorePixelRatio||e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||1;return(h&&window.devicePixelRatio||1)/t},e.getStatus=function(e){if("number"==typeof e)return ht(e);if("string"!=typeof e)throw new TypeError("code must be a number or string");const t=parseInt(e,10);return!isNaN(t)&&mt.codes.includes(t)?ht(t):function(e){const t=e.toLowerCase();if(mt.code.has(t),!mt.code.has(t))throw new Error('invalid status message: "'+e+'"');return mt.code.get(t)}(e)},e.getWindow=Te,e.handleConsole=Ze,e.handleError=it,e.handleFetchHook=pt,e.hexToRgb=Ie,e.hsbToRgb=_e,e.hslToRgb=Ve,e.hsvToHsl=Xe,e.hsvToRgb=Ye,e.hue2rgb=$e,e.imageRequest=Le,e.isBangDevice=()=>{if(!h)return!1;const e=/iphone/i.test(window.navigator.userAgent),t=window.devicePixelRatio&&2===window.devicePixelRatio,n=window.devicePixelRatio&&3===window.devicePixelRatio,i=360===window.screen.width&&780===window.screen.height,a=375===window.screen.width&&812===window.screen.height,o=390===window.screen.width&&844===window.screen.height,r=414===window.screen.width&&896===window.screen.height,s=428===window.screen.width&&926===window.screen.height;switch(!0){case e&&n&&i:case e&&n&&a:case e&&n&&o:case e&&t&&r:case e&&n&&r:case e&&n&&s:return!0;default:return!1}},e.isClient=h,e.isImageSize=(e,t,n)=>new Promise(((i,a)=>{h||a("window is undefined");const o=window.URL||window.webkitURL,r=new Image;r.onload=function(){let e=!1;t&&(e=r.width===t),n&&(e=r.height===n),o.revokeObjectURL(r.src),i(e)},r.src=o.createObjectURL(e)})),e.isMobile=()=>{if(!h)return!1;const e=window.navigator.userAgent;return!!/Android|webOS|iPhone|iPod|iPad|BlackBerry/i.test(e)},e.isString=Se,e.isWeiXin=()=>{if(h){return window.navigator.userAgent.toLowerCase().includes("micromessenger")}return!1},e.localStorageGetItem=e=>h&&localStorage.getItem(e)||"",e.localStorageSetItem=(e,t)=>{h&&localStorage.setItem(e,t)},e.mathjs=function e(t,n,i){function a(e){const[t,n]=e.toString().split(".");return n?n.length:0}const o=(e,t=15)=>parseFloat(Number(e).toPrecision(t)),r=Math.pow(10,Math.max(a(t),a(i)));let s=0;switch(t=o(t*r),i=o(i*r),n){case"+":s=(t+i)/r;break;case"-":s=(t-i)/r;break;case"*":s=t*i/(r*r);break;case"/":s=t/i}return s=o(s),{result:s,next:(t,n)=>e(s,t,n)}},e.memoize=We,e.merge=(e,t)=>{if(e&&t)for(const n in t)e[n]=t[n];return e},e.mergeExports=Qe,e.networkSpeed=async e=>{const{url:t,duration:n=3e3,count:i=5}=e;let a=0,o=0;const r=[];for(let s=0;s<i;s++){const e=Fe(Le,t),i=await e(n);r.push(i)}return a=Math.max(...r)-Math.min(...r),o=r.reduce(((e,t)=>e+t))/r.length,{ping:o,jitter:a}},e.noop=l,e.perToNum=(e="")=>{if(0===e.length)return 0;if(e.endsWith("%")){const t=Number(e.replace("%",""));return t>1?t/100:t}return Number(e)},e.performanceTime=Ce,e.querystring=Ge,e.randomColor=function(){const e="#"+Math.random().toString(16).slice(2,8);return new Pe(e)},e.randomString=Ae,e.range=(e,t=0,n=1)=>Math.min(n,Math.max(t,e)),e.removeClassToElement=(e,t)=>{if("undefined"==typeof document)return;const n=e.classList;n.contains(t)&&n.remove(t)},e.removeGhosting=e=>{const t=document.createElement("img");t.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",t.width=0,t.height=0,t.style.opacity="0",e.dataTransfer&&e.dataTransfer.setDragImage(t,0,0)},e.replaceOld=Je,e.report=rt,e.requestAnimation=e=>{if(!h)return;let t=!1;return function(){const n=this,i=arguments;t||(window.requestAnimationFrame((function(){e.apply(n,i),t=!1})),t=!0)}},e.requestUrlToBuffer=(e,t)=>new Promise((function(n,i){const a=new XMLHttpRequest;a.open(t.method||"GET",e,!0),a.responseType=t.responseType||"arraybuffer",a.onload=function(){200===a.status?n({success:!0,data:a.response,message:""}):i({success:!1,data:a.status,message:`The request status is${a.status}`})},a.onerror=function(e){i({success:!1,data:e,message:""})},a.onprogress=e=>{t.onProgress&&t.onProgress(e)},a.withCredentials=t.withCredentials||!1,t.headers&&Object.keys(t.headers).forEach((function(e){var n;(null==(n=t.headers)?void 0:n[e])&&a.setRequestHeader(e,t.headers[e])})),a.send(t.body)})),e.retain=(e=l)=>{const t=()=>{e(),h&&window.removeEventListener("popstate",t)};h&&window.history.pushState(null,"",window.location.href),setTimeout((()=>{h&&window.addEventListener("popstate",t)}),500)},e.rgbToHex=Ne,e.rgbToHsb=function(e,t,n){let i,a,o=0;e/=255,t/=255,n/=255;const r=Math.max(e,t,n),s=Math.min(e,t,n);a=r;const p=r-s;if(i=0===r?0:p/r,r===s)o=0;else{switch(r){case e:o=(t-n)/p+(t<n?6:0);break;case t:o=(n-e)/p+2;break;case n:o=(e-t)/p+4}o/=6}return o=Re(360*o),i=Re(100*i),a=Re(100*a),[o,i,a]},e.rgbToHsl=Ke,e.scriptOnLoad=(e,t,n)=>{const i=(e=Array.isArray(e)?e:[e]).map((e=>{let n;if(/\w*.css$/.test(e)){const t=document.createElement("link");t.type="text/css",t.rel="stylesheet",t.href=e,n=t}else n=document.createElement("script"),n.type="text/javascript",n.src=e;const i=document.getElementsByTagName("body")[0];return(t||i).appendChild(n),new Promise((e=>{n.onload=()=>{e()}}))}));return new Promise((e=>{Promise.all(i).then((()=>{"function"==typeof n&&n(),e()}))}))},e.setAttributeByGlobal=(e,t)=>{"undefined"!=typeof window&&(window[e]=t),"undefined"!=typeof global&&(global[e]=t)},e.setFontSize2html=(e=375)=>{let t=e;const{documentElement:n}=document,i=window.matchMedia("(orientation: portrait)");let a,o=667/375;function r(){const e=!i.matches;let a=window.screen.width,r=window.screen.height;a<r&&([a,r]=[r,a]);let s=n.clientWidth,p=r;s/p>=o?(s=p*o,n.classList.remove("adjustHeight"),n.classList.add("adjustWidth")):(p=s/o,n.classList.remove("adjustWidth"),n.classList.add("adjustHeight"));let c=s/t*16;e&&(c/=o),n.style.fontSize=`${c}px`;const l=window.getComputedStyle(n).fontSize.replace("px","")||0;c!==l&&(n.style.fontSize=c/Number(l)*c+"px")}m()===d.IPAD&&(o=1024/768,t=768),window.addEventListener("resize",(function(){clearTimeout(a),a=setTimeout(r,300)}),!1),window.addEventListener("pageshow",(function(e){e.persisted&&(clearTimeout(a),a=setTimeout(r,300))}),!1),window.addEventListener("orientationchange",(function(){r()}),!1),r()},e.setMime=(e,t)=>(at.set(e,t),at),e.status=mt,e.str2Xml=(e,t="text/xml")=>{if(window.DOMParser)return(new window.DOMParser).parseFromString(e,t).documentElement;if(void 0!==window.ActiveXObject){const t=new window.ActiveXObject("Microsoft.XMLDOM");return t.async="false",t.loadXML(e),t}},e.strParse=(e="",t="",n="")=>{const i={},a=e.split(t);return a.length>0&&a.forEach((e=>{const[t="",a=""]=e.split(n);Oe(t)&&(i[Oe(t)]=Oe(a))})),i},e.throttle=lt,e.timeFormat=e=>{if(0===e)return"00:00";if(!e)return"";const t=Math.trunc(e/3600),n=Math.trunc(e%3600/60),i=ke(Math.trunc(e-3600*t-60*n));return 0===t?`${ke(n)}:${i}`:`${ke(t)}:${ke(n)}:${i}`},e.timestampToTime=function(e){let t=new Date;return e&&(t=new Date(e)),t.format=(e="YYYY-MM-DD HH:mm:ss")=>{const n=t.getFullYear(),i=ke(t.getMonth()+1),a=ke(t.getDate()),o=ke(t.getHours()),r=ke(t.getMinutes()),s=ke(t.getSeconds());return e.replace(/Y+/gi,`${n}`).replace(/M+/g,`${i}`).replace(/D+/gi,`${a}`).replace(/H+/gi,`${o}`).replace(/m+/g,`${r}`).replace(/S+/gi,`${s}`)},t},e.webglVendor=()=>{const e=document.createElement("canvas").getContext("webgl2");return e?function(e){const t=e.getExtension("WEBGL_debug_renderer_info");return t?{vendor:e.getParameter(t.UNMASKED_VENDOR_WEBGL),renderer:e.getParameter(t.UNMASKED_RENDERER_WEBGL)}:null}(e):null},Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})}));
|