|
|
(window.webpackJsonp=window.webpackJsonp||[]).push([[94,3,5,7,8,17,18],{"+NIl":
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./node_modules/codemirror/mode/stex/stex.js ***!
|
|
|
\***************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){!function(t){"use strict";t.defineMode("stex",(function(t,e){function r(t,e){t.cmdState.push(e)}function n(t){return t.cmdState.length>0?t.cmdState[t.cmdState.length-1]:null}function i(t,e,r){return function(){this.name=t,this.bracketNo=0,this.style=e,this.styles=r,this.argument=null,this.styleIdentifier=function(){return this.styles[this.bracketNo-1]||null},this.openBracket=function(){return this.bracketNo++,"bracket"},this.closeBracket=function(){}}}var o={};function a(t,e){t.f=e}function s(t,e){var i;if(t.match(/^\\[a-zA-Z@]+/)){var s=t.current().slice(1);return r(e,i=new(i=o.hasOwnProperty(s)?o[s]:o.DEFAULT)),a(e,l),i.style}if(t.match(/^\\[$&%#{}_]/))return"tag";if(t.match(/^\\[,;!\/\\]/))return"tag";if(t.match("\\["))return a(e,(function(t,e){return A(t,e,"\\]")})),"keyword";if(t.match("\\("))return a(e,(function(t,e){return A(t,e,"\\)")})),"keyword";if(t.match("$$"))return a(e,(function(t,e){return A(t,e,"$$")})),"keyword";if(t.match("$"))return a(e,(function(t,e){return A(t,e,"$")})),"keyword";var c=t.next();return"%"==c?(t.skipToEnd(),"comment"):"}"==c||"]"==c?(i=n(e))?(i.closeBracket(c),a(e,l),"bracket"):"error":"{"==c||"["==c?(r(e,i=new(i=o.DEFAULT)),"bracket"):/\d/.test(c)?(t.eatWhile(/[\w.%]/),"atom"):(t.eatWhile(/[\w\-_]/),"begin"==(i=function(t){for(var e=t.cmdState,r=e.length-1;r>=0;r--){var n=e[r];if("DEFAULT"!=n.name)return n}return{styleIdentifier:function(){return null}}}(e)).name&&(i.argument=t.current()),i.styleIdentifier())}function A(t,e,r){if(t.eatSpace())return null;if(r&&t.match(r))return a(e,s),"keyword";if(t.match(/^\\[a-zA-Z@]+/))return"tag";if(t.match(/^[a-zA-Z]+/))return"variable-2";if(t.match(/^\\[$&%#{}_]/))return"tag";if(t.match(/^\\[,;!\/]/))return"tag";if(t.match(/^[\^_&]/))return"tag";if(t.match(/^[+\-<>|=,\/@!*:;'"`~#?]/))return null;if(t.match(/^(\d+\.\d*|\d*\.\d+|\d+)/))return"number";var n=t.next();return"{"==n||"}"==n||"["==n||"]"==n||"("==n||")"==n?"bracket":"%"==n?(t.skipToEnd(),"comment"):"error"}function l(t,e){var r=t.peek();return"{"==r||"["==r?(n(e).openBracket(r),t.eat(r),a(e,s),"bracket"):/[ \t\r]/.test(r)?(t.eat(r),null):(a(e,s),function(t){var e=t.cmdState.pop();e&&e.closeBracket()}(e),s(t,e))}return o.importmodule=i("importmodule","tag",["string","builtin"]),o.documentclass=i("documentclass","tag",["","atom"]),o.usepackage=i("usepackage","tag",["atom"]),o.begin=i("begin","tag",["atom"]),o.end=i("end","tag",["atom"]),o.label=i("label","tag",["atom"]),o.ref=i("ref","tag",["atom"]),o.eqref=i("eqref","tag",["atom"]),o.cite=i("cite","tag",["atom"]),o.bibitem=i("bibitem","tag",["atom"]),o.Bibitem=i("Bibitem","tag",["atom"]),o.RBibitem=i("RBibitem","tag",["atom"]),o.DEFAULT=function(){this.name="DEFAULT",this.style="tag",this.styleIdentifier=this.openBracket=this.closeBracket=function(){}},{startState:function(){return{cmdState:[],f:e.inMathMode?function(t,e){return A(t,e)}:s}},copyState:function(t){return{cmdState:t.cmdState.slice(),f:t.f}},token:function(t,e){return e.f(t,e)},blankLine:function(t){t.f=s,t.cmdState.length=0},lineComment:"%"}})),t.defineMIME("text/x-stex","stex"),t.defineMIME("text/x-latex","stex")}(r(/*! ../../lib/codemirror */"VrN/"))},"06Qe":
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/vml/core.js ***!
|
|
|
\**********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n,i=r(/*! ../core/env */"ItGF"),o="urn:schemas-microsoft-com:vml",a="undefined"==typeof window?null:window,s=!1,A=a&&a.document;if(A&&!i.canvasSupported)try{!A.namespaces.zrvml&&A.namespaces.add("zrvml",o),n=function(t){return A.createElement("<zrvml:"+t+' class="zrvml">')}}catch(t){n=function(t){return A.createElement("<"+t+' xmlns="'+o+'" class="zrvml">')}}e.doc=A,e.createNode=function(t){return n(t)},e.initVML=function(){if(!s&&A){s=!0;var t=A.styleSheets;t.length<31?A.createStyleSheet().addRule(".zrvml","behavior:url(#default#VML)"):t[0].addRule(".zrvml","behavior:url(#default#VML)")}}},"0s+r":
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/Handler.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./core/util */"bYtY"),i=r(/*! ./core/vector */"QBsz"),o=r(/*! ./mixin/Draggable */"y23F"),a=r(/*! ./mixin/Eventful */"H6uX"),s=r(/*! ./core/event */"YH21"),A=r(/*! ./core/GestureMgr */"C0SR");function l(){s.stop(this.event)}function c(){}c.prototype.dispose=function(){};var u=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],h=function(t,e,r,n){a.call(this),this.storage=t,this.painter=e,this.painterRoot=n,r=r||new c,this.proxy=null,this._hovered={},this._lastTouchMoment,this._lastX,this._lastY,this._gestureMgr,o.call(this),this.setHandlerProxy(r)};function d(t,e,r){if(t[t.rectHover?"rectContain":"contain"](e,r)){for(var n,i=t;i;){if(i.clipPath&&!i.clipPath.contain(e,r))return!1;i.silent&&(n=!0),i=i.parent}return!n||"silent"}return!1}function f(t,e,r){var n=t.painter;return e<0||e>n.getWidth()||r<0||r>n.getHeight()}h.prototype={constructor:h,setHandlerProxy:function(t){this.proxy&&this.proxy.dispose(),t&&(n.each(u,(function(e){t.on&&t.on(e,this[e],this)}),this),t.handler=this),this.proxy=t},mousemove:function(t){var e=t.zrX,r=t.zrY,n=f(this,e,r),i=this._hovered,o=i.target;o&&!o.__zr&&(o=(i=this.findHover(i.x,i.y)).target);var a=this._hovered=n?{x:e,y:r}:this.findHover(e,r),s=a.target,A=this.proxy;A.setCursor&&A.setCursor(s?s.cursor:"default"),o&&s!==o&&this.dispatchToElement(i,"mouseout",t),this.dispatchToElement(a,"mousemove",t),s&&s!==o&&this.dispatchToElement(a,"mouseover",t)},mouseout:function(t){var e=t.zrEventControl,r=t.zrIsToLocalDOM;"only_globalout"!==e&&this.dispatchToElement(this._hovered,"mouseout",t),"no_globalout"!==e&&!r&&this.trigger("globalout",{type:"globalout",event:t})},resize:function(t){this._hovered={}},dispatch:function(t,e){var r=this[t];r&&r.call(this,e)},dispose:function(){this.proxy.dispose(),this.storage=this.proxy=this.painter=null},setCursorStyle:function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},dispatchToElement:function(t,e,r){var n=(t=t||{}).target;if(!n||!n.silent){for(var i="on"+e,o=function(t,e,r){return{type:t,event:r,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:r.zrX,offsetY:r.zrY,gestureEvent:r.gestureEvent,pinchX:r.pinchX,pinchY:r.pinchY,pinchScale:r.pinchScale,wheelDelta:r.zrDelta,zrByTouch:r.zrByTouch,which:r.which,stop:l}}(e,t,r);n&&(n[i]&&(o.cancelBubble=n[i].call(n,o)),n.trigger(e,o),n=n.parent,!o.cancelBubble););o.cancelBubble||(this.trigger(e,o),this.painter&&this.painter.eachOtherLayer((function(t){"function"==typeof t[i]&&t[i].call(t,o),t.trigger&&t.trigger(e,o)})))}},findHover:function(t,e,r){for(var n=this.storage.getDisplayList(),i={x:t,y:e},o=n.length-1;o>=0;o--){var a;if(n[o]!==r&&!n[o].ignore&&(a=d(n[o],t,e))&&(!i.topTarget&&(i.topTarget=n[o]),"silent"!==a)){i.target=n[o];break}}return i},processGesture:function(t,e){this._gestureMgr||(this._gestureMgr=new A);var r=this._gestureMgr;"start"===e&&r.clear();var n=r.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if("end"===e&&r.clear(),n){var i=n.type;t.gestureEvent=i,this.dispatchToElement({target:n.target},i,n.event)}}},n.each(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],(function(t){h.prototype[t]=function(e){var r,n,o=e.zrX,a=e.zrY,s=f(this,o,a);if("mouseup"===t&&s||(n=(r=this.findHover(o,a)).target),"mousedown"===t)this._downEl=n,this._downPoint=[e.zrX,e.zrY],this._upEl=n;else if("mouseup"===t)this._upEl=n;else if("click"===t){if(this._downEl!==this._upEl||!this._downPoint||i.dist(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(r,t,e)}})),n.mixin(h,a),n.mixin(h,o);var p=h;t.exports=p},"19Vz":
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./node_modules/codemirror/addon/display/placeholder.js ***!
|
|
|
\**************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){!function(t){function e(t){t.state.placeholder&&(t.state.placeholder.parentNode.removeChild(t.state.placeholder),t.state.placeholder=null)}function r(t){e(t);var r=t.state.placeholder=document.createElement("pre");r.style.cssText="height: 0; overflow: visible",r.style.direction=t.getOption("direction"),r.className="CodeMirror-placeholder CodeMirror-line-like";var n=t.getOption("placeholder");"string"==typeof n&&(n=document.createTextNode(n)),r.appendChild(n),t.display.lineSpace.insertBefore(r,t.display.lineSpace.firstChild)}function n(t){o(t)&&r(t)}function i(t){var n=t.getWrapperElement(),i=o(t);n.className=n.className.replace(" CodeMirror-empty","")+(i?" CodeMirror-empty":""),i?r(t):e(t)}function o(t){return 1===t.lineCount()&&""===t.getLine(0)}t.defineOption("placeholder","",(function(o,a,s){var A=s&&s!=t.Init;if(a&&!A)o.on("blur",n),o.on("change",i),o.on("swapDoc",i),t.on(o.getInputField(),"compositionupdate",o.state.placeholderCompose=function(){!function(t){setTimeout((function(){var n=!1,i=t.getInputField();"TEXTAREA"==i.nodeName?n=!i.value:1==t.lineCount()&&(n=!/[^\u200b]/.test(i.querySelector(".CodeMirror-line").textContent)),n?r(t):e(t)}),20)}(o)}),i(o);else if(!a&&A){o.off("blur",n),o.off("change",i),o.off("swapDoc",i),t.off(o.getInputField(),"compositionupdate",o.state.placeholderCompose),e(o);var l=o.getWrapperElement();l.className=l.className.replace(" CodeMirror-empty","")}a&&!o.hasFocus()&&n(o)}))}(r(/*! ../../lib/codemirror */"VrN/"))},"1Jh7":
|
|
|
/*!************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Polyline.js ***!
|
|
|
\************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt"),i=r(/*! ../helper/poly */"T6xi"),o=n.extend({type:"polyline",shape:{points:null,smooth:!1,smoothConstraint:null},style:{stroke:"#000",fill:null},buildPath:function(t,e){i.buildPath(t,e,!1)}});t.exports=o},"1MYJ":
|
|
|
/*!**********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/CompoundPath.js ***!
|
|
|
\**********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./Path */"y+Vt"),i=n.extend({type:"compound",shape:{paths:null},_updatePathDirty:function(){for(var t=this.__dirtyPath,e=this.shape.paths,r=0;r<e.length;r++)t=t||e[r].__dirtyPath;this.__dirtyPath=t,this.__dirty=this.__dirty||t},beforeBrush:function(){this._updatePathDirty();for(var t=this.shape.paths||[],e=this.getGlobalScale(),r=0;r<t.length;r++)t[r].path||t[r].createPathProxy(),t[r].path.setScale(e[0],e[1],t[r].segmentIgnoreThreshold)},buildPath:function(t,e){for(var r=e.paths||[],n=0;n<r.length;n++)r[n].buildPath(t,r[n].shape,!0)},afterBrush:function(){for(var t=this.shape.paths||[],e=0;e<t.length;e++)t[e].__dirtyPath=!1},getBoundingRect:function(){return this._updatePathDirty(),n.prototype.getBoundingRect.call(this)}});t.exports=i},"1RvN":
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/LRU.js ***!
|
|
|
\**********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=function(){this.head=null,this.tail=null,this._len=0},n=r.prototype;n.insert=function(t){var e=new i(t);return this.insertEntry(e),e},n.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},n.remove=function(t){var e=t.prev,r=t.next;e?e.next=r:this.head=r,r?r.prev=e:this.tail=e,t.next=t.prev=null,this._len--},n.len=function(){return this._len},n.clear=function(){this.head=this.tail=null,this._len=0};var i=function(t){this.value=t,this.next,this.prev},o=function(t){this._list=new r,this._map={},this._maxSize=t||10,this._lastRemovedEntry=null},a=o.prototype;a.put=function(t,e){var r=this._list,n=this._map,o=null;if(null==n[t]){var a=r.len(),s=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var A=r.head;r.remove(A),delete n[A.key],o=A.value,this._lastRemovedEntry=A}s?s.value=e:s=new i(e),s.key=t,r.insertEntry(s),n[t]=s}return o},a.get=function(t){var e=this._map[t],r=this._list;if(null!=e)return e!==r.tail&&(r.remove(e),r.insertEntry(e)),e.value},a.clear=function(){this._list.clear(),this._map={}};var s=o;t.exports=s},"1bdT":
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/Element.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./core/guid */"3gBT"),i=r(/*! ./mixin/Eventful */"H6uX"),o=r(/*! ./mixin/Transformable */"DN4a"),a=r(/*! ./mixin/Animatable */"vWvF"),s=r(/*! ./core/util */"bYtY"),A=function(t){o.call(this,t),i.call(this,t),a.call(this,t),this.id=t.id||n()};A.prototype={type:"element",name:"",__zr:null,ignore:!1,clipPath:null,isGroup:!1,drift:function(t,e){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0}var r=this.transform;r||(r=this.transform=[1,0,0,1,0,0]),r[4]+=t,r[5]+=e,this.decomposeTransform(),this.dirty(!1)},beforeUpdate:function(){},afterUpdate:function(){},update:function(){this.updateTransform()},traverse:function(t,e){},attrKV:function(t,e){if("position"===t||"scale"===t||"origin"===t){if(e){var r=this[t];r||(r=this[t]=[]),r[0]=e[0],r[1]=e[1]}}else this[t]=e},hide:function(){this.ignore=!0,this.__zr&&this.__zr.refresh()},show:function(){this.ignore=!1,this.__zr&&this.__zr.refresh()},attr:function(t,e){if("string"==typeof t)this.attrKV(t,e);else if(s.isObject(t))for(var r in t)t.hasOwnProperty(r)&&this.attrKV(r,t[r]);return this.dirty(!1),this},setClipPath:function(t){var e=this.__zr;e&&t.addSelfToZr(e),this.clipPath&&this.clipPath!==t&&this.removeClipPath(),this.clipPath=t,t.__zr=e,t.__clipTarget=this,this.dirty(!1)},removeClipPath:function(){var t=this.clipPath;t&&(t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__clipTarget=null,this.clipPath=null,this.dirty(!1))},addSelfToZr:function(t){this.__zr=t;var e=this.animators;if(e)for(var r=0;r<e.length;r++)t.animation.addAnimator(e[r]);this.clipPath&&this.clipPath.addSelfToZr(t)},removeSelfFromZr:function(t){this.__zr=null;var e=this.animators;if(e)for(var r=0;r<e.length;r++)t.animation.removeAnimator(e[r]);this.clipPath&&this.clipPath.removeSelfFromZr(t)}},s.mixin(A,a),s.mixin(A,o),s.mixin(A,i);var l=A;t.exports=l},"1eCo":
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/codemirror/mode/xml/xml.js ***!
|
|
|
\*************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){!function(t){"use strict";var e={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},r={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};t.defineMode("xml",(function(n,i){var o,a,s=n.indentUnit,A={},l=i.htmlMode?e:r;for(var c in l)A[c]=l[c];for(var c in i)A[c]=i[c];function u(t,e){function r(r){return e.tokenize=r,r(t,e)}var n=t.next();return"<"==n?t.eat("!")?t.eat("[")?t.match("CDATA[")?r(d("atom","]]>")):null:t.match("--")?r(d("comment","--\x3e")):t.match("DOCTYPE",!0,!0)?(t.eatWhile(/[\w\._\-]/),r(function t(e){return function(r,n){for(var i;null!=(i=r.next());){if("<"==i)return n.tokenize=t(e+1),n.tokenize(r,n);if(">"==i){if(1==e){n.tokenize=u;break}return n.tokenize=t(e-1),n.tokenize(r,n)}}return"meta"}}(1))):null:t.eat("?")?(t.eatWhile(/[\w\._\-]/),e.tokenize=d("meta","?>"),"meta"):(o=t.eat("/")?"closeTag":"openTag",e.tokenize=h,"tag bracket"):"&"==n?(t.eat("#")?t.eat("x")?t.eatWhile(/[a-fA-F\d]/)&&t.eat(";"):t.eatWhile(/[\d]/)&&t.eat(";"):t.eatWhile(/[\w\.\-:]/)&&t.eat(";"))?"atom":"error":(t.eatWhile(/[^&<]/),null)}function h(t,e){var r,n,i=t.next();if(">"==i||"/"==i&&t.eat(">"))return e.tokenize=u,o=">"==i?"endTag":"selfcloseTag","tag bracket";if("="==i)return o="equals",null;if("<"==i){e.tokenize=u,e.state=m,e.tagName=e.tagStart=null;var a=e.tokenize(t,e);return a?a+" tag error":"tag error"}return/[\'\"]/.test(i)?(e.tokenize=(r=i,(n=function(t,e){for(;!t.eol();)if(t.next()==r){e.tokenize=h;break}return"string"}).isInAttribute=!0,n),e.stringStartCol=t.column(),e.tokenize(t,e)):(t.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function d(t,e){return function(r,n){for(;!r.eol();){if(r.match(e)){n.tokenize=u;break}r.next()}return t}}function f(t,e,r){this.prev=t.context,this.tagName=e,this.indent=t.indented,this.startOfLine=r,(A.doNotIndent.hasOwnProperty(e)||t.context&&t.context.noIndent)&&(this.noIndent=!0)}function p(t){t.context&&(t.context=t.context.prev)}function g(t,e){for(var r;;){if(!t.context)return;if(r=t.context.tagName,!A.contextGrabbers.hasOwnProperty(r)||!A.contextGrabbers[r].hasOwnProperty(e))return;p(t)}}function m(t,e,r){return"openTag"==t?(r.tagStart=e.column(),v):"closeTag"==t?y:m}function v(t,e,r){return"word"==t?(r.tagName=e.current(),a="tag",C):A.allowMissingTagName&&"endTag"==t?(a="tag bracket",C(t,0,r)):(a="error",v)}function y(t,e,r){if("word"==t){var n=e.current();return r.context&&r.context.tagName!=n&&A.implicitlyClosed.hasOwnProperty(r.context.tagName)&&p(r),r.context&&r.context.tagName==n||!1===A.matchClosing?(a="tag",w):(a="tag error",b)}return A.allowMissingTagName&&"endTag"==t?(a="tag bracket",w(t,0,r)):(a="error",b)}function w(t,e,r){return"endTag"!=t?(a="error",w):(p(r),m)}function b(t,e,r){return a="error",w(t,0,r)}function C(t,e,r){if("word"==t)return a="attribute",B;if("endTag"==t||"selfcloseTag"==t){var n=r.tagName,i=r.tagStart;return r.tagName=r.tagStart=null,"selfcloseTag"==t||A.autoSelfClosers.hasOwnProperty(n)?g(r,n):(g(r,n),r.context=new f(r,n,i==r.indented)),m}return a="error",C}function B(t,e,r){return"equals"==t?x:(A.allowMissing||(a="error"),C(t,0,r))}function x(t,e,r){return"string"==t?E:"word"==t&&A.allowUnquoted?(a="string",C):(a="error",C(t,0,r))}function E(t,e,r){return"string"==t?E:C(t,0,r)}return u.isInText=!0,{startState:function(t){var e={tokenize:u,state:m,indented:t||0,tagName:null,tagStart:null,context:null};return null!=t&&(e.baseIndent=t),e},token:function(t,e){if(!e.tagName&&t.sol()&&(e.indented=t.indentation()),t.eatSpace())return null;o=null;var r=e.tokenize(t,e);return(r||o)&&"comment"!=r&&(a=null,e.state=e.state(o||r,t,e),a&&(r="error"==a?r+" error":a)),r},indent:function(e,r,n){var i=e.context;if(e.tokenize.isInAttribute)return e.tagStart==e.indented?e.stringStartCol+1:e.indented+s;if(i&&i.noIndent)return t.Pass;if(e.tokenize!=h&&e.tokenize!=u)return n?n.match(/^(\s*)/)[0].length:0;if(e.tagName)return!1!==A.multilineTagIndentPastTag?e.tagStart+e.tagName.length+2:e.tagStart+s*(A.multilineTagIndentFactor||1);if(A.alignCDATA&&/<!\[CDATA\[/.test(r))return 0;var o=r&&/^<(\/)?([\w_:\.-]*)/.exec(r);if(o&&o[1])for(;i;){if(i.tagName==o[2]){i=i.prev;break}if(!A.implicitlyClosed.hasOwnProperty(i.tagName))break;i=i.prev}else if(o)for(;i;){var a=A.contextGrabbers[i.tagName];if(!a||!a.hasOwnProperty(o[2]))break;i=i.prev}for(;i&&i.prev&&!i.startOfLine;)i=i.prev;return i?i.indent+s:e.baseIndent||0},electricInput:/<\/[\s\w:]+>$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:A.htmlMode?"html":"xml",helperType:A.htmlMode?"html":"xml",skipAttribute:function(t){t.state==x&&(t.state=C)},xmlCurrentTag:function(t){return t.tagName?{name:t.tagName,close:"closeTag"==t.type}:null},xmlCurrentContext:function(t){for(var e=[],r=t.context;r;r=r.prev)r.tagName&&e.push(r.tagName);return e.reverse()}}})),t.defineMIME("text/xml","xml"),t.defineMIME("application/xml","xml"),t.mimeModes.hasOwnProperty("text/html")||t.defineMIME("text/html",{name:"xml",htmlMode:!0})}(r(/*! ../../lib/codemirror */"VrN/"))},"1eJ8":
|
|
|
/*!*****************************************************************************************************!*\
|
|
|
!*** ./src/pages/Classrooms/Lists/ShixunHomeworks/Comment/components/ShixunStaticItem.less?modules ***!
|
|
|
\*****************************************************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){t.exports={md:"md___1fRow"}},"1j5w":
|
|
|
/*!*******************************************************!*\
|
|
|
!*** ./node_modules/rc-menu/es/index.js + 11 modules ***!
|
|
|
\*******************************************************/
|
|
|
/*! exports provided: SubMenu, Item, MenuItem, MenuItemGroup, ItemGroup, Divider, default */
|
|
|
/*! exports used: Divider, Item, ItemGroup, SubMenu, default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createSuper.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/extends.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/typeof.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/mini-store/esm/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/omit.js/es/index.js (<- Module is referenced from these modules with unsupported syntax: ./node_modules/antd/lib/button/button.js (referenced with cjs require), ./node_modules/antd/lib/input/Input.js (referenced with cjs require), ./node_modules/antd/lib/input/Password.js (referenced with cjs require), ./node_modules/antd/lib/input/TextArea.js (referenced with cjs require)) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-motion/es/index.js (<- Module is referenced from these modules with unsupported syntax: ./node_modules/antd/lib/button/LoadingIcon.js (referenced with cjs require)) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-trigger/es/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/KeyCode.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/createChainedFunction.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/warning.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react-dom/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/resize-observer-polyfill/dist/ResizeObserver.es.js (<- Module uses injected variables (global)) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/shallowequal/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r.d(e,"d",(function(){return at})),r.d(e,"b",(function(){return wt})),r.d(e,"c",(function(){return Ct})),r.d(e,"a",(function(){return xt}));var n=r("VTBJ"),i=r("1OyB"),o=r("vuIU"),a=r("JX7q"),s=r("Ji7U"),A=r("LK+K"),l=r("q1tI"),c=r("I8Z2"),u=r("BGR+"),h=r("wx14"),d=r("rePB"),f=r("4IlW"),p=r("2GS6"),g=r("Gytx"),m=r.n(g),v=r("TSYQ"),y=r.n(v),w=r("U8pU"),b=r("ODXe"),C=/iPhone/i,B=/iPod/i,x=/iPad/i,E=/\bAndroid(?:.+)Mobile\b/i,S=/Android/i,k=/\bAndroid(?:.+)SD4930UR\b/i,T=/\bAndroid(?:.+)(?:KF[A-Z]{2,4})\b/i,F=/Windows Phone/i,L=/\bWindows(?:.+)ARM\b/i,I=/BlackBerry/i,_=/BB10/i,U=/Opera Mini/i,O=/\b(CriOS|Chrome)(?:.+)Mobile/i,D=/Mobile(?:.+)Firefox\b/i;function Q(t,e){return t.test(e)}function M(t){var e=t||("undefined"!=typeof navigator?navigator.userAgent:""),r=e.split("[FBAN");if(void 0!==r[1]){var n=r;e=Object(b.a)(n,1)[0]}if(void 0!==(r=e.split("Twitter"))[1]){var i=r;e=Object(b.a)(i,1)[0]}var o={apple:{phone:Q(C,e)&&!Q(F,e),ipod:Q(B,e),tablet:!Q(C,e)&&Q(x,e)&&!Q(F,e),device:(Q(C,e)||Q(B,e)||Q(x,e))&&!Q(F,e)},amazon:{phone:Q(k,e),tablet:!Q(k,e)&&Q(T,e),device:Q(k,e)||Q(T,e)},android:{phone:!Q(F,e)&&Q(k,e)||!Q(F,e)&&Q(E,e),tablet:!Q(F,e)&&!Q(k,e)&&!Q(E,e)&&(Q(T,e)||Q(S,e)),device:!Q(F,e)&&(Q(k,e)||Q(T,e)||Q(E,e)||Q(S,e))||Q(/\bokhttp\b/i,e)},windows:{phone:Q(F,e),tablet:Q(L,e),device:Q(F,e)||Q(L,e)},other:{blackberry:Q(I,e),blackberry10:Q(_,e),opera:Q(U,e),firefox:Q(D,e),chrome:Q(O,e),device:Q(I,e)||Q(_,e)||Q(U,e)||Q(D,e)||Q(O,e)},any:null,phone:null,tablet:null};return o.any=o.apple.device||o.android.device||o.windows.device||o.other.device,o.phone=o.apple.phone||o.android.phone||o.windows.phone,o.tablet=o.apple.tablet||o.android.tablet||o.windows.tablet,o}var R=Object(n.a)(Object(n.a)({},M()),{},{isMobile:M});function P(){}function H(t,e,r){var n=e||"";return t.key||"".concat(n,"item_").concat(r)}function N(t){return"".concat(t,"-menu-")}function K(t,e){var r=-1;l.Children.forEach(t,(function(t){r+=1,t&&t.type&&t.type.isMenuItemGroup?l.Children.forEach(t.props.children,(function(t){e(t,r+=1)})):e(t,r)}))}var j=["defaultSelectedKeys","selectedKeys","defaultOpenKeys","openKeys","mode","getPopupContainer","onSelect","onDeselect","onDestroy","openTransitionName","openAnimation","subMenuOpenDelay","subMenuCloseDelay","forceSubMenuRender","triggerSubMenuAction","level","selectable","multiple","onOpenChange","visible","focusable","defaultActiveFirst","prefixCls","inlineIndent","parentMenu","title","rootPrefixCls","eventKey","active","onItemHover","onTitleMouseEnter","onTitleMouseLeave","onTitleClick","popupAlign","popupOffset","isOpen","renderMenuItem","manualRef","subMenuKey","disabled","index","isSelected","store","activeKey","builtinPlacements","overflowedIndicator","motion","attribute","value","popupClassName","inlineCollapsed","menu","theme","itemIcon","expandIcon"],G=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=t&&"function"==typeof t.getBoundingClientRect&&t.getBoundingClientRect().width;if(r){if(e){var n=getComputedStyle(t),i=n.marginLeft,o=n.marginRight;r+=+i.replace("px","")+ +o.replace("px","")}r=+r.toFixed(6)}return r||0},V=function(t,e,r){t&&"object"===Object(w.a)(t.style)&&(t.style[e]=r)},z=r("KQm4"),W=r("Ff2n"),Y=r("i8i4"),X=r("bdgK"),q=r("uciX"),J=r("8XRh"),Z={adjustX:1,adjustY:1},$={topLeft:{points:["bl","tl"],overflow:Z,offset:[0,-7]},bottomLeft:{points:["tl","bl"],overflow:Z,offset:[0,7]},leftTop:{points:["tr","tl"],overflow:Z,offset:[-4,0]},rightTop:{points:["tl","tr"],overflow:Z,offset:[4,0]}},tt={topLeft:{points:["bl","tl"],overflow:Z,offset:[0,-7]},bottomLeft:{points:["tl","bl"],overflow:Z,offset:[0,7]},rightTop:{points:["tr","tl"],overflow:Z,offset:[-4,0]},leftTop:{points:["tl","tr"],overflow:Z,offset:[4,0]}},et=0,rt={horizontal:"bottomLeft",vertical:"rightTop","vertical-left":"rightTop","vertical-right":"leftTop"},nt=function(t,e,r){var i=N(e),o=t.getState();t.setState({defaultActiveFirst:Object(n.a)(Object(n.a)({},o.defaultActiveFirst),{},Object(d.a)({},i,r))})},it=function(t){Object(s.a)(r,t);var e=Object(A.a)(r);function r(t){var o;Object(i.a)(this,r),(o=e.call(this,t)).onDestroy=function(t){o.props.onDestroy(t)},o.onKeyDown=function(t){var e=t.keyCode,r=o.menuInstance,n=o.props,i=n.isOpen,a=n.store;if(e===f.a.ENTER)return o.onTitleClick(t),nt(a,o.props.eventKey,!0),!0;if(e===f.a.RIGHT)return i?r.onKeyDown(t):(o.triggerOpenChange(!0),nt(a,o.props.eventKey,!0)),!0;if(e===f.a.LEFT){var s;if(!i)return;return(s=r.onKeyDown(t))||(o.triggerOpenChange(!1),s=!0),s}return!i||e!==f.a.UP&&e!==f.a.DOWN?void 0:r.onKeyDown(t)},o.onOpenChange=function(t){o.props.onOpenChange(t)},o.onPopupVisibleChange=function(t){o.triggerOpenChange(t,t?"mouseenter":"mouseleave")},o.onMouseEnter=function(t){var e=o.props,r=e.eventKey,n=e.onMouseEnter,i=e.store;nt(i,o.props.eventKey,!1),n({key:r,domEvent:t})},o.onMouseLeave=function(t){var e=o.props,r=e.parentMenu,n=e.eventKey,i=e.onMouseLeave;r.subMenuInstance=Object(a.a)(o),i({key:n,domEvent:t})},o.onTitleMouseEnter=function(t){var e=o.props,r=e.eventKey,n=e.onItemHover,i=e.onTitleMouseEnter;n({key:r,hover:!0}),i({key:r,domEvent:t})},o.onTitleMouseLeave=function(t){var e=o.props,r=e.parentMenu,n=e.eventKey,i=e.onItemHover,s=e.onTitleMouseLeave;r.subMenuInstance=Object(a.a)(o),i({key:n,hover:!1}),s({key:n,domEvent:t})},o.onTitleClick=function(t){var e=Object(a.a)(o).props;e.onTitleClick({key:e.eventKey,domEvent:t}),"hover"!==e.triggerSubMenuAction&&(o.triggerOpenChange(!e.isOpen,"click"),nt(e.store,o.props.eventKey,!1))},o.onSubMenuClick=function(t){"function"==typeof o.props.onClick&&o.props.onClick(o.addKeyPath(t))},o.onSelect=function(t){o.props.onSelect(t)},o.onDeselect=function(t){o.props.onDeselect(t)},o.getPrefixCls=function(){return"".concat(o.props.rootPrefixCls,"-submenu")},o.getActiveClassName=function(){return"".concat(o.getPrefixCls(),"-active")},o.getDisabledClassName=function(){return"".concat(o.getPrefixCls(),"-disabled")},o.getSelectedClassName=function(){return"".concat(o.getPrefixCls(),"-selected")},o.getOpenClassName=function(){return"".concat(o.props.rootPrefixCls,"-submenu-open")},o.saveMenuInstance=function(t){o.menuInstance=t},o.addKeyPath=function(t){return Object(n.a)(Object(n.a)({},t),{},{keyPath:(t.keyPath||[]).concat(o.props.eventKey)})},o.triggerOpenChange=function(t,e){var r=o.props.eventKey,n=function(){o.onOpenChange({key:r,item:Object(a.a)(o),trigger:e,open:t})};"mouseenter"===e?o.mouseenterTimeout=setTimeout((function(){n()}),0):n()},o.isChildrenSelected=function(){var t={find:!1};return function t(e,r,n){e&&!n.find&&l.Children.forEach(e,(function(e){if(e){var i=e.type;if(!i||!(i.isSubMenu||i.isMenuItem||i.isMenuItemGroup))return;-1!==r.indexOf(e.key)?n.find=!0:e.props.children&&t(e.props.children,r,n)}}))}(o.props.children,o.props.selectedKeys,t),t.find},o.isOpen=function(){return-1!==o.props.openKeys.indexOf(o.props.eventKey)},o.adjustWidth=function(){if(o.subMenuTitle&&o.menuInstance){var t=Y.findDOMNode(o.menuInstance);t.offsetWidth>=o.subMenuTitle.offsetWidth||(t.style.minWidth="".concat(o.subMenuTitle.offsetWidth,"px"))}},o.saveSubMenuTitle=function(t){o.subMenuTitle=t},o.getBaseProps=function(){var t=Object(a.a)(o).props;return{mode:"horizontal"===t.mode?"vertical":t.mode,visible:o.props.isOpen,level:t.level+1,inlineIndent:t.inlineIndent,focusable:!1,onClick:o.onSubMenuClick,onSelect:o.onSelect,onDeselect:o.onDeselect,onDestroy:o.onDestroy,selectedKeys:t.selectedKeys,eventKey:"".concat(t.eventKey,"-menu-"),openKeys:t.openKeys,motion:t.motion,onOpenChange:o.onOpenChange,subMenuOpenDelay:t.subMenuOpenDelay,parentMenu:Object(a.a)(o),subMenuCloseDelay:t.subMenuCloseDelay,forceSubMenuRender:t.forceSubMenuRender,triggerSubMenuAction:t.triggerSubMenuAction,builtinPlacements:t.builtinPlacements,defaultActiveFirst:t.store.getState().defaultActiveFirst[N(t.eventKey)],multiple:t.multiple,prefixCls:t.rootPrefixCls,id:o.internalMenuId,manualRef:o.saveMenuInstance,itemIcon:t.itemIcon,expandIcon:t.expandIcon,direction:t.direction}},o.getMotion=function(t,e){var r=Object(a.a)(o).haveRendered,i=o.props,s=i.motion,A=i.rootPrefixCls;return Object(n.a)(Object(n.a)({},s),{},{leavedClassName:"".concat(A,"-hidden"),removeOnLeave:!1,motionAppear:r||!e||"inline"!==t})};var s=t.store,A=t.eventKey,c=s.getState().defaultActiveFirst;o.isRootMenu=!1;var u=!1;return c&&(u=c[A]),nt(s,A,u),o}return Object(o.a)(r,[{key:"componentDidMount",value:function(){this.componentDidUpdate()}},{key:"componentDidUpdate",value:function(){var t=this,e=this.props,r=e.mode,n=e.parentMenu,i=e.manualRef;i&&i(this),"horizontal"===r&&n.isRootMenu&&this.props.isOpen&&(this.minWidthTimeout=setTimeout((function(){return t.adjustWidth()}),0))}},{key:"componentWillUnmount",value:function(){var t=this.props,e=t.onDestroy,r=t.eventKey;e&&e(r),this.minWidthTimeout&&clearTimeout(this.minWidthTimeout),this.mouseenterTimeout&&clearTimeout(this.mouseenterTimeout)}},{key:"renderChildren",value:function(t){var e=this,r=this.getBaseProps(),n=this.getMotion(r.mode,r.visible);if(this.haveRendered=!0,this.haveOpened=this.haveOpened||r.visible||r.forceSubMenuRender,!this.haveOpened)return l.createElement("div",null);var i=r.direction;return l.createElement(J.default,Object.assign({visible:r.visible},n),(function(n){var o=n.className,a=n.style,s=y()("".concat(r.prefixCls,"-sub"),o,Object(d.a)({},"".concat(r.prefixCls,"-rtl"),"rtl"===i));return l.createElement(ft,Object.assign({},r,{id:e.internalMenuId,className:s,style:a}),t)}))}},{key:"render",value:function(){var t,e=Object(n.a)({},this.props),r=e.isOpen,i=this.getPrefixCls(),o="inline"===e.mode,a=y()(i,"".concat(i,"-").concat(e.mode),(t={},Object(d.a)(t,e.className,!!e.className),Object(d.a)(t,this.getOpenClassName(),r),Object(d.a)(t,this.getActiveClassName(),e.active||r&&!o),Object(d.a)(t,this.getDisabledClassName(),e.disabled),Object(d.a)(t,this.getSelectedClassName(),this.isChildrenSelected()),t));this.internalMenuId||(e.eventKey?this.internalMenuId="".concat(e.eventKey,"$Menu"):(et+=1,this.internalMenuId="$__$".concat(et,"$Menu")));var s={},A={},c={};e.disabled||(s={onMouseLeave:this.onMouseLeave,onMouseEnter:this.onMouseEnter},A={onClick:this.onTitleClick},c={onMouseEnter:this.onTitleMouseEnter,onMouseLeave:this.onTitleMouseLeave});var u={},h=e.direction;o&&("rtl"===h?u.paddingRight=e.inlineIndent*e.level:u.paddingLeft=e.inlineIndent*e.level);var f={};this.props.isOpen&&(f={"aria-owns":this.internalMenuId});var p=null;"horizontal"!==e.mode&&(p=this.props.expandIcon,"function"==typeof this.props.expandIcon&&(p=l.createElement(this.props.expandIcon,Object(n.a)({},this.props))));var g=l.createElement("div",Object.assign({ref:this.saveSubMenuTitle,style:u,className:"".concat(i,"-title"),role:"button"},c,A,{"aria-expanded":r},f,{"aria-haspopup":"true",title:"string"==typeof e.title?e.title:void 0}),e.title,p||l.createElement("i",{className:"".concat(i,"-arrow")})),m=this.renderChildren(e.children),v=e.parentMenu.isRootMenu?e.parentMenu.props.getPopupContainer:function(t){return t.parentNode},w=rt[e.mode],b=e.popupOffset?{offset:e.popupOffset}:{},C="inline"===e.mode?"":e.popupClassName;C+="rtl"===h?" ".concat(i,"-rtl"):"";var B=e.disabled,x=e.triggerSubMenuAction,E=e.subMenuOpenDelay,S=e.forceSubMenuRender,k=e.subMenuCloseDelay,T=e.builtinPlacements;j.forEach((function(t){return delete e[t]})),delete e.onClick;var F="rtl"===h?Object.assign({},tt,T):Object.assign({},$,T);return delete e.direction,l.createElement("li",Object.assign({},e,s,{className:a,role:"menuitem"}),o&&g,o&&m,!o&&l.createElement(q.a,{prefixCls:i,popupClassName:y()("".concat(i,"-popup"),C),getPopupContainer:v,builtinPlacements:F,popupPlacement:w,popupVisible:r,popupAlign:b,popup:m,action:B?[]:[x],mouseEnterDelay:E,mouseLeaveDelay:k,onPopupVisibleChange:this.onPopupVisibleChange,forceRender:S},g))}}]),r}(l.Component);it.defaultProps={onMouseEnter:P,onMouseLeave:P,onTitleMouseEnter:P,onTitleMouseLeave:P,onTitleClick:P,manualRef:P,mode:"vertical",title:""};var ot=Object(c.b)((function(t,e){var r=t.openKeys,n=t.activeKey,i=t.selectedKeys,o=e.eventKey,a=e.subMenuKey;return{isOpen:r.indexOf(o)>-1,active:n[a]===o,selectedKeys:i}}))(it);ot.isSubMenu=!0;var at=ot,st=function(t){Object(s.a)(r,t);var e=Object(A.a)(r);function r(){var t;return Object(i.a)(this,r),(t=e.apply(this,arguments)).resizeObserver=null,t.mutationObserver=null,t.originalTotalWidth=0,t.overflowedItems=[],t.menuItemSizes=[],t.cancelFrameId=null,t.state={lastVisibleIndex:void 0},t.getMenuItemNodes=function(){var e=t.props.prefixCls,r=Y.findDOMNode(Object(a.a)(t));return r?[].slice.call(r.children).filter((function(t){return t.className.split(" ").indexOf("".concat(e,"-overflowed-submenu"))<0})):[]},t.getOverflowedSubMenuItem=function(e,r,i){var o=t.props,a=o.overflowedIndicator,s=o.level,A=o.mode,c=o.prefixCls,u=o.theme;if(1!==s||"horizontal"!==A)return null;var h=t.props.children[0].props,d=(h.children,h.title,h.style),f=Object(W.a)(h,["children","title","style"]),p=Object(n.a)({},d),g="".concat(e,"-overflowed-indicator"),m="".concat(e,"-overflowed-indicator");0===r.length&&!0!==i?p=Object(n.a)(Object(n.a)({},p),{},{display:"none"}):i&&(p=Object(n.a)(Object(n.a)({},p),{},{visibility:"hidden",position:"absolute"}),g="".concat(g,"-placeholder"),m="".concat(m,"-placeholder"));var v=u?"".concat(c,"-").concat(u):"",y={};return j.forEach((function(t){void 0!==f[t]&&(y[t]=f[t])})),l.createElement(at,Object.assign({title:a,className:"".concat(c,"-overflowed-submenu"),popupClassName:v},y,{key:g,eventKey:m,disabled:!1,style:p}),r)},t.setChildrenWidthAndResize=function(){if("horizontal"===t.props.mode){var e=Y.findDOMNode(Object(a.a)(t));if(e){var r=e.children;if(r&&0!==r.length){var n=e.children[r.length-1];V(n,"display","inline-block");var i=t.getMenuItemNodes(),o=i.filter((function(t){return t.className.split(" ").indexOf("menuitem-overflowed")>=0}));o.forEach((function(t){V(t,"display","inline-block")})),t.menuItemSizes=i.map((function(t){return G(t,!0)})),o.forEach((function(t){V(t,"display","none")})),t.overflowedIndicatorWidth=G(e.children[e.children.length-1],!0),t.originalTotalWidth=t.menuItemSizes.reduce((function(t,e){return t+e}),0),t.handleResize(),V(n,"display","none")}}}},t.handleResize=function(){if("horizontal"===t.props.mode){var e=Y.findDOMNode(Object(a.a)(t));if(e){var r=G(e);t.overflowedItems=[];var n,i=0;t.originalTotalWidth>r+.5&&(n=-1,t.menuItemSizes.forEach((function(e){(i+=e)+t.overflowedIndicatorWidth<=r&&(n+=1)}))),t.setState({lastVisibleIndex:n})}}},t}return Object(o.a)(r,[{key:"componentDidMount",value:function(){var t=this;if(this.setChildrenWidthAndResize(),1===this.props.level&&"horizontal"===this.props.mode){var e=Y.findDOMNode(this);if(!e)return;this.resizeObserver=new X.default((function(e){e.forEach((function(){var e=t.cancelFrameId;cancelAnimationFrame(e),t.cancelFrameId=requestAnimationFrame(t.setChildrenWidthAndResize)}))})),[].slice.call(e.children).concat(e).forEach((function(e){t.resizeObserver.observe(e)})),"undefined"!=typeof MutationObserver&&(this.mutationObserver=new MutationObserver((function(){t.resizeObserver.disconnect(),[].slice.call(e.children).concat(e).forEach((function(e){t.resizeObserver.observe(e)})),t.setChildrenWidthAndResize()})),this.mutationObserver.observe(e,{attributes:!1,childList:!0,subTree:!1}))}}},{key:"componentWillUnmount",value:function(){this.resizeObserver&&this.resizeObserver.disconnect(),this.mutationObserver&&this.mutationObserver.disconnect(),cancelAnimationFrame(this.cancelFrameId)}},{key:"renderChildren",value:function(t){var e=this,r=this.state.lastVisibleIndex;return(t||[]).reduce((function(n,i,o){var a=i;if("horizontal"===e.props.mode){var s=e.getOverflowedSubMenuItem(i.props.eventKey,[]);void 0!==r&&-1!==e.props.className.indexOf("".concat(e.props.prefixCls,"-root"))&&(o>r&&(a=l.cloneElement(i,{style:{display:"none"},eventKey:"".concat(i.props.eventKey,"-hidden"),className:"".concat("menuitem-overflowed")})),o===r+1&&(e.overflowedItems=t.slice(r+1).map((function(t){return l.cloneElement(t,{key:t.props.eventKey,mode:"vertical-left"})})),s=e.getOverflowedSubMenuItem(i.props.eventKey,e.overflowedItems)));var A=[].concat(Object(z.a)(n),[s,a]);return o===t.length-1&&A.push(e.getOverflowedSubMenuItem(i.props.eventKey,[],!0)),A}return[].concat(Object(z.a)(n),[a])}),[])}},{key:"render",value:function(){var t=this.props,e=(t.visible,t.prefixCls,t.overflowedIndicator,t.mode,t.level,t.tag),r=t.children,n=(t.theme,Object(W.a)(t,["visible","prefixCls","overflowedIndicator","mode","level","tag","children","theme"])),i=e;return l.createElement(i,Object.assign({},n),this.renderChildren(r))}}]),r}(l.Component);st.defaultProps={tag:"div",className:""};var At=st;function lt(t,e,r){var i=t.getState();t.setState({activeKey:Object(n.a)(Object(n.a)({},i.activeKey),{},Object(d.a)({},e,r))})}function ct(t){return t.eventKey||"0-menu-"}function ut(t,e){var r,n=e,i=t.children,o=t.eventKey;if(n&&(K(i,(function(t,e){t&&t.props&&!t.props.disabled&&n===H(t,o,e)&&(r=!0)})),r))return n;return n=null,t.defaultActiveFirst?(K(i,(function(t,e){n||!t||t.props.disabled||(n=H(t,o,e))})),n):n}function ht(t){if(t){var e=this.instanceArray.indexOf(t);-1!==e?this.instanceArray[e]=t:this.instanceArray.push(t)}}var dt=function(t){Object(s.a)(r,t);var e=Object(A.a)(r);function r(t){var o;return Object(i.a)(this,r),(o=e.call(this,t)).onKeyDown=function(t,e){var r,n=t.keyCode;if(o.getFlatInstanceArray().forEach((function(e){e&&e.props.active&&e.onKeyDown&&(r=e.onKeyDown(t))})),r)return 1;var i=null;return n!==f.a.UP&&n!==f.a.DOWN||(i=o.step(n===f.a.UP?-1:1)),i?(t.preventDefault(),lt(o.props.store,ct(o.props),i.props.eventKey),"function"==typeof e&&e(i),1):void 0},o.onItemHover=function(t){var e=t.key,r=t.hover;lt(o.props.store,ct(o.props),r?e:null)},o.onDeselect=function(t){o.props.onDeselect(t)},o.onSelect=function(t){o.props.onSelect(t)},o.onClick=function(t){o.props.onClick(t)},o.onOpenChange=function(t){o.props.onOpenChange(t)},o.onDestroy=function(t){o.props.onDestroy(t)},o.getFlatInstanceArray=function(){return o.instanceArray},o.step=function(t){var e=o.getFlatInstanceArray(),r=o.props.store.getState().activeKey[ct(o.props)],n=e.length;if(!n)return null;t<0&&(e=e.concat().reverse());var i=-1;if(e.every((function(t,e){return!t||t.props.eventKey!==r||(i=e,!1)})),o.props.defaultActiveFirst||-1===i||(a=e.slice(i,n-1)).length&&!a.every((function(t){return!!t.props.disabled}))){var a,s=(i+1)%n,A=s;do{var l=e[A];if(l&&!l.props.disabled)return l;A=(A+1)%n}while(A!==s);return null}},o.renderCommonMenuItem=function(t,e,r){var i=o.props.store.getState(),s=Object(a.a)(o).props,A=H(t,s.eventKey,e),c=t.props;if(!c||"string"==typeof t.type)return t;var u=A===i.activeKey,h=Object(n.a)(Object(n.a)({mode:c.mode||s.mode,level:s.level,inlineIndent:s.inlineIndent,renderMenuItem:o.renderMenuItem,rootPrefixCls:s.prefixCls,index:e,parentMenu:s.parentMenu,manualRef:c.disabled?void 0:Object(p.a)(t.ref,ht.bind(Object(a.a)(o))),eventKey:A,active:!c.disabled&&u,multiple:s.multiple,onClick:function(t){(c.onClick||P)(t),o.onClick(t)},onItemHover:o.onItemHover,motion:s.motion,subMenuOpenDelay:s.subMenuOpenDelay,subMenuCloseDelay:s.subMenuCloseDelay,forceSubMenuRender:s.forceSubMenuRender,onOpenChange:o.onOpenChange,onDeselect:o.onDeselect,onSelect:o.onSelect,builtinPlacements:s.builtinPlacements,itemIcon:c.itemIcon||o.props.itemIcon,expandIcon:c.expandIcon||o.props.expandIcon},r),{},{direction:s.direction});return("inline"===s.mode||R.any)&&(h.triggerSubMenuAction="click"),l.cloneElement(t,h)},o.renderMenuItem=function(t,e,r){if(!t)return null;var n=o.props.store.getState(),i={openKeys:n.openKeys,selectedKeys:n.selectedKeys,triggerSubMenuAction:o.props.triggerSubMenuAction,subMenuKey:r};return o.renderCommonMenuItem(t,e,i)},t.store.setState({activeKey:Object(n.a)(Object(n.a)({},t.store.getState().activeKey),{},Object(d.a)({},t.eventKey,ut(t,t.activeKey)))}),o.instanceArray=[],o}return Object(o.a)(r,[{key:"componentDidMount",value:function(){this.props.manualRef&&this.props.manualRef(this)}},{key:"shouldComponentUpdate",value:function(t){return this.props.visible||t.visible||this.props.className!==t.className||!m()(this.props.style,t.style)}},{key:"componentDidUpdate",value:function(t){var e=this.props,r="activeKey"in e?e.activeKey:e.store.getState().activeKey[ct(e)],n=ut(e,r);if(n!==r)lt(e.store,ct(e),n);else if("activeKey"in t){n!==ut(t,t.activeKey)&<(e.store,ct(e),n)}}},{key:"render",value:function(){var t=this,e=Object(h.a)({},this.props);this.instanceArray=[];var r={className:y()(e.prefixCls,e.className,"".concat(e.prefixCls,"-").concat(e.mode)),role:e.role||"menu"};e.id&&(r.id=e.id),e.focusable&&(r.tabIndex=0,r.onKeyDown=this.onKeyDown);var n=e.prefixCls,i=e.eventKey,o=e.visible,a=e.level,s=e.mode,A=e.overflowedIndicator,c=e.theme;return j.forEach((function(t){return delete e[t]})),delete e.onClick,l.createElement(At,Object.assign({},e,{prefixCls:n,mode:s,tag:"ul",level:a,theme:c,visible:o,overflowedIndicator:A},r),l.Children.map(e.children,(function(e,r){return t.renderMenuItem(e,r,i||"0-menu-")})))}}]),r}(l.Component);dt.defaultProps={prefixCls:"rc-menu",className:"",mode:"vertical",level:1,inlineIndent:24,visible:!0,focusable:!0,style:{},manualRef:P};var ft=Object(c.b)()(dt),pt=r("Kwbf");function gt(t,e,r){var n=t.prefixCls,i=t.motion,o=t.defaultMotions,a=void 0===o?{}:o,s=t.openAnimation,A=t.openTransitionName,l=e.switchingModeFromInline;if(i)return i;if("object"===Object(w.a)(s)&&s)Object(pt.a)(!1,"Object type of `openAnimation` is removed. Please use `motion` instead.");else if("string"==typeof s)return{motionName:"".concat(n,"-open-").concat(s)};if(A)return{motionName:A};var c=a[r];return c||(l?null:a.other)}var mt=function(t){Object(s.a)(r,t);var e=Object(A.a)(r);function r(t){var o;Object(i.a)(this,r),(o=e.call(this,t)).inlineOpenKeys=[],o.onSelect=function(t){var e=Object(a.a)(o).props;if(e.selectable){var r=o.store.getState().selectedKeys,i=t.key;r=e.multiple?r.concat([i]):[i],"selectedKeys"in e||o.store.setState({selectedKeys:r}),e.onSelect(Object(n.a)(Object(n.a)({},t),{},{selectedKeys:r}))}},o.onClick=function(t){var e=o.getRealMenuMode(),r=Object(a.a)(o),n=r.store,i=r.props.onOpenChange;"inline"===e||"openKeys"in o.props||(n.setState({openKeys:[]}),i([])),o.props.onClick(t)},o.onKeyDown=function(t,e){o.innerMenu.getWrappedInstance().onKeyDown(t,e)},o.onOpenChange=function(t){var e=Object(a.a)(o).props,r=o.store.getState().openKeys.concat(),n=!1,i=function(t){var e=!1;if(t.open)(e=-1===r.indexOf(t.key))&&r.push(t.key);else{var i=r.indexOf(t.key);(e=-1!==i)&&r.splice(i,1)}n=n||e};Array.isArray(t)?t.forEach(i):i(t),n&&("openKeys"in o.props||o.store.setState({openKeys:r}),e.onOpenChange(r))},o.onDeselect=function(t){var e=Object(a.a)(o).props;if(e.selectable){var r=o.store.getState().selectedKeys.concat(),i=t.key,s=r.indexOf(i);-1!==s&&r.splice(s,1),"selectedKeys"in e||o.store.setState({selectedKeys:r}),e.onDeselect(Object(n.a)(Object(n.a)({},t),{},{selectedKeys:r}))}},o.onMouseEnter=function(t){o.restoreModeVerticalFromInline();var e=o.props.onMouseEnter;e&&e(t)},o.onTransitionEnd=function(t){var e="width"===t.propertyName&&t.target===t.currentTarget,r=t.target.className,n="[object SVGAnimatedString]"===Object.prototype.toString.call(r)?r.animVal:r,i="font-size"===t.propertyName&&n.indexOf("anticon")>=0;(e||i)&&o.restoreModeVerticalFromInline()},o.setInnerMenu=function(t){o.innerMenu=t},o.isRootMenu=!0;var s=t.defaultSelectedKeys,A=t.defaultOpenKeys;return"selectedKeys"in t&&(s=t.selectedKeys||[]),"openKeys"in t&&(A=t.openKeys||[]),o.store=Object(c.c)({selectedKeys:s,openKeys:A,activeKey:{"0-menu-":ut(t,t.activeKey)}}),o.state={switchingModeFromInline:!1},o}return Object(o.a)(r,[{key:"componentDidMount",value:function(){this.updateMiniStore(),this.updateMenuDisplay()}},{key:"componentDidUpdate",value:function(t){this.updateOpentKeysWhenSwitchMode(t),this.updateMiniStore();var e=this.props,r=e.siderCollapsed,n=e.inlineCollapsed,i=e.onOpenChange;(!t.inlineCollapsed&&n||!t.siderCollapsed&&r)&&i([]),this.updateMenuDisplay()}},{key:"updateOpentKeysWhenSwitchMode",value:function(t){var e=this.props,r=this.store,n=this.inlineOpenKeys,i=r.getState(),o={};"inline"===t.mode&&"inline"!==e.mode&&this.setState({switchingModeFromInline:!0}),"openKeys"in e||((e.inlineCollapsed&&!t.inlineCollapsed||e.siderCollapsed&&!t.siderCollapsed)&&(this.setState({switchingModeFromInline:!0}),this.inlineOpenKeys=i.openKeys.concat(),o.openKeys=[]),(!e.inlineCollapsed&&t.inlineCollapsed||!e.siderCollapsed&&t.siderCollapsed)&&(o.openKeys=n,this.inlineOpenKeys=[])),Object.keys(o).length&&r.setState(o)}},{key:"updateMenuDisplay",value:function(){var t=this.props.collapsedWidth,e=this.store,r=this.prevOpenKeys;this.getInlineCollapsed()&&(0===t||"0"===t||"0px"===t)?(this.prevOpenKeys=e.getState().openKeys.concat(),this.store.setState({openKeys:[]})):r&&(this.store.setState({openKeys:r}),this.prevOpenKeys=null)}},{key:"getRealMenuMode",value:function(){var t=this.props.mode,e=this.state.switchingModeFromInline,r=this.getInlineCollapsed();return e&&r?"inline":r?"vertical":t}},{key:"getInlineCollapsed",value:function(){var t=this.props,e=t.inlineCollapsed,r=t.siderCollapsed;return void 0!==r?r:e}},{key:"restoreModeVerticalFromInline",value:function(){this.state.switchingModeFromInline&&this.setState({switchingModeFromInline:!1})}},{key:"updateMiniStore",value:function(){"selectedKeys"in this.props&&this.store.setState({selectedKeys:this.props.selectedKeys||[]}),"openKeys"in this.props&&this.store.setState({openKeys:this.props.openKeys||[]})}},{key:"render",value:function(){var t=Object(n.a)({},Object(u.default)(this.props,["collapsedWidth","siderCollapsed","defaultMotions"])),e=this.getRealMenuMode();return t.className+=" ".concat(t.prefixCls,"-root"),"rtl"===t.direction&&(t.className+=" ".concat(t.prefixCls,"-rtl")),delete(t=Object(n.a)(Object(n.a)({},t),{},{mode:e,onClick:this.onClick,onOpenChange:this.onOpenChange,onDeselect:this.onDeselect,onSelect:this.onSelect,onMouseEnter:this.onMouseEnter,onTransitionEnd:this.onTransitionEnd,parentMenu:this,motion:gt(this.props,this.state,e)})).openAnimation,delete t.openTransitionName,l.createElement(c.a,{store:this.store},l.createElement(ft,Object.assign({},t,{ref:this.setInnerMenu}),this.props.children))}}]),r}(l.Component);mt.defaultProps={selectable:!0,onClick:P,onSelect:P,onOpenChange:P,onDeselect:P,defaultSelectedKeys:[],defaultOpenKeys:[],subMenuOpenDelay:.1,subMenuCloseDelay:.1,triggerSubMenuAction:"hover",prefixCls:"rc-menu",className:"",mode:"vertical",style:{},builtinPlacements:{},overflowedIndicator:l.createElement("span",null,"···")};var vt=mt,yt=function(t){Object(s.a)(r,t);var e=Object(A.a)(r);function r(){var t;return Object(i.a)(this,r),(t=e.apply(this,arguments)).onKeyDown=function(e){if(e.keyCode===f.a.ENTER)return t.onClick(e),!0},t.onMouseLeave=function(e){var r=t.props,n=r.eventKey,i=r.onItemHover,o=r.onMouseLeave;i({key:n,hover:!1}),o({key:n,domEvent:e})},t.onMouseEnter=function(e){var r=t.props,n=r.eventKey,i=r.onItemHover,o=r.onMouseEnter;i({key:n,hover:!0}),o({key:n,domEvent:e})},t.onClick=function(e){var r=t.props,n=r.eventKey,i=r.multiple,o=r.onClick,s=r.onSelect,A=r.onDeselect,l=r.isSelected,c={key:n,keyPath:[n],item:Object(a.a)(t),domEvent:e};o(c),i?l?A(c):s(c):l||s(c)},t.saveNode=function(e){t.node=e},t}return Object(o.a)(r,[{key:"componentDidMount",value:function(){this.callRef()}},{key:"componentDidUpdate",value:function(){this.callRef()}},{key:"componentWillUnmount",value:function(){var t=this.props;t.onDestroy&&t.onDestroy(t.eventKey)}},{key:"getPrefixCls",value:function(){return"".concat(this.props.rootPrefixCls,"-item")}},{key:"getActiveClassName",value:function(){return"".concat(this.getPrefixCls(),"-active")}},{key:"getSelectedClassName",value:function(){return"".concat(this.getPrefixCls(),"-selected")}},{key:"getDisabledClassName",value:function(){return"".concat(this.getPrefixCls(),"-disabled")}},{key:"callRef",value:function(){this.props.manualRef&&this.props.manualRef(this)}},{key:"render",value:function(){var t,e=Object(n.a)({},this.props),r=y()(this.getPrefixCls(),e.className,(t={},Object(d.a)(t,this.getActiveClassName(),!e.disabled&&e.active),Object(d.a)(t,this.getSelectedClassName(),e.isSelected),Object(d.a)(t,this.getDisabledClassName(),e.disabled),t)),i=Object(n.a)(Object(n.a)({},e.attribute),{},{title:"string"==typeof e.title?e.title:void 0,className:r,role:e.role||"menuitem","aria-disabled":e.disabled});"option"===e.role?i=Object(n.a)(Object(n.a)({},i),{},{role:"option","aria-selected":e.isSelected}):null!==e.role&&"none"!==e.role||(i.role="none");var o={onClick:e.disabled?null:this.onClick,onMouseLeave:e.disabled?null:this.onMouseLeave,onMouseEnter:e.disabled?null:this.onMouseEnter},a=Object(n.a)({},e.style);"inline"===e.mode&&("rtl"===e.direction?a.paddingRight=e.inlineIndent*e.level:a.paddingLeft=e.inlineIndent*e.level),j.forEach((function(t){return delete e[t]})),delete e.direction;var s=this.props.itemIcon;return"function"==typeof this.props.itemIcon&&(s=l.createElement(this.props.itemIcon,this.props)),l.createElement("li",Object.assign({},Object(u.default)(e,["onClick","onMouseEnter","onMouseLeave","onSelect"]),i,o,{style:a,ref:this.saveNode}),e.children,s)}}]),r}(l.Component);yt.isMenuItem=!0,yt.defaultProps={onSelect:P,onMouseEnter:P,onMouseLeave:P,manualRef:P};var wt=Object(c.b)((function(t,e){var r=t.activeKey,n=t.selectedKeys,i=e.eventKey;return{active:r[e.subMenuKey]===i,isSelected:-1!==n.indexOf(i)}}))(yt),bt=function(t){Object(s.a)(r,t);var e=Object(A.a)(r);function r(){var t;return Object(i.a)(this,r),(t=e.apply(this,arguments)).renderInnerMenuItem=function(e){var r=t.props;return(0,r.renderMenuItem)(e,r.index,t.props.subMenuKey)},t}return Object(o.a)(r,[{key:"render",value:function(){var t=Object(h.a)({},this.props),e=t.className,r=void 0===e?"":e,n=t.rootPrefixCls,i="".concat(n,"-item-group-title"),o="".concat(n,"-item-group-list"),a=t.title,s=t.children;return j.forEach((function(e){return delete t[e]})),delete t.onClick,delete t.direction,l.createElement("li",Object.assign({},t,{className:"".concat(r," ").concat(n,"-item-group")}),l.createElement("div",{className:i,title:"string"==typeof a?a:void 0},a),l.createElement("ul",{className:o},l.Children.map(s,this.renderInnerMenuItem)))}}]),r}(l.Component);bt.isMenuItemGroup=!0,bt.defaultProps={disabled:!0};var Ct=bt,Bt=function(t){var e=t.className,r=t.rootPrefixCls,n=t.style;return l.createElement("li",{className:"".concat(e," ").concat(r,"-item-divider"),style:n})};Bt.defaultProps={disabled:!0,className:"",style:{}};var xt=Bt;e.e=vt},"24YM":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/size-sensor/lib/constant.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SensorTabIndex=e.SensorClassName=e.SizeSensorId=void 0;e.SizeSensorId="size-sensor-id";e.SensorClassName="size-sensor-object";e.SensorTabIndex="-1"},"2DNl":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/path.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/PathProxy */"IMiH"),i=r(/*! ./line */"loD1"),o=r(/*! ./cubic */"59Ip"),a=r(/*! ./quadratic */"aKvl"),s=r(/*! ./arc */"n1HI"),A=r(/*! ./util */"hX1E").normalizeRadian,l=r(/*! ../core/curve */"Sj9i"),c=r(/*! ./windingLine */"hyiK"),u=n.CMD,h=2*Math.PI;var d=[-1,-1,-1],f=[-1,-1];function p(t,e,r,n,i,o,a,s,A,c){if(c>e&&c>n&&c>o&&c>s||c<e&&c<n&&c<o&&c<s)return 0;var u,h=l.cubicRootAt(e,n,o,s,c,d);if(0===h)return 0;for(var p,g,m=0,v=-1,y=0;y<h;y++){var w=d[y],b=0===w||1===w?.5:1;l.cubicAt(t,r,i,a,w)<A||(v<0&&(v=l.cubicExtrema(e,n,o,s,f),f[1]<f[0]&&v>1&&(u=void 0,u=f[0],f[0]=f[1],f[1]=u),p=l.cubicAt(e,n,o,s,f[0]),v>1&&(g=l.cubicAt(e,n,o,s,f[1]))),2===v?w<f[0]?m+=p<e?b:-b:w<f[1]?m+=g<p?b:-b:m+=s<g?b:-b:w<f[0]?m+=p<e?b:-b:m+=s<p?b:-b)}return m}function g(t,e,r,n,i,o,a,s){if(s>e&&s>n&&s>o||s<e&&s<n&&s<o)return 0;var A=l.quadraticRootAt(e,n,o,s,d);if(0===A)return 0;var c=l.quadraticExtremum(e,n,o);if(c>=0&&c<=1){for(var u=0,h=l.quadraticAt(e,n,o,c),f=0;f<A;f++){var p=0===d[f]||1===d[f]?.5:1;l.quadraticAt(t,r,i,d[f])<a||(d[f]<c?u+=h<e?p:-p:u+=o<h?p:-p)}return u}p=0===d[0]||1===d[0]?.5:1;return l.quadraticAt(t,r,i,d[0])<a?0:o<e?p:-p}function m(t,e,r,n,i,o,a,s){if((s-=e)>r||s<-r)return 0;var l=Math.sqrt(r*r-s*s);d[0]=-l,d[1]=l;var c=Math.abs(n-i);if(c<1e-4)return 0;if(c%h<1e-4){n=0,i=h;var u=o?1:-1;return a>=d[0]+t&&a<=d[1]+t?u:0}if(o){l=n;n=A(i),i=A(l)}else n=A(n),i=A(i);n>i&&(i+=h);for(var f=0,p=0;p<2;p++){var g=d[p];if(g+t>a){var m=Math.atan2(s,g);u=o?1:-1;m<0&&(m=h+m),(m>=n&&m<=i||m+h>=n&&m+h<=i)&&(m>Math.PI/2&&m<1.5*Math.PI&&(u=-u),f+=u)}}return f}function v(t,e,r,n,A){for(var l,h,d=0,f=0,v=0,y=0,w=0,b=0;b<t.length;){var C=t[b++];switch(C===u.M&&b>1&&(r||(d+=c(f,v,y,w,n,A))),1===b&&(y=f=t[b],w=v=t[b+1]),C){case u.M:f=y=t[b++],v=w=t[b++];break;case u.L:if(r){if(i.containStroke(f,v,t[b],t[b+1],e,n,A))return!0}else d+=c(f,v,t[b],t[b+1],n,A)||0;f=t[b++],v=t[b++];break;case u.C:if(r){if(o.containStroke(f,v,t[b++],t[b++],t[b++],t[b++],t[b],t[b+1],e,n,A))return!0}else d+=p(f,v,t[b++],t[b++],t[b++],t[b++],t[b],t[b+1],n,A)||0;f=t[b++],v=t[b++];break;case u.Q:if(r){if(a.containStroke(f,v,t[b++],t[b++],t[b],t[b+1],e,n,A))return!0}else d+=g(f,v,t[b++],t[b++],t[b],t[b+1],n,A)||0;f=t[b++],v=t[b++];break;case u.A:var B=t[b++],x=t[b++],E=t[b++],S=t[b++],k=t[b++],T=t[b++];b+=1;var F=1-t[b++],L=Math.cos(k)*E+B,I=Math.sin(k)*S+x;b>1?d+=c(f,v,L,I,n,A):(y=L,w=I);var _=(n-B)*S/E+B;if(r){if(s.containStroke(B,x,S,k,k+T,F,e,_,A))return!0}else d+=m(B,x,S,k,k+T,F,_,A);f=Math.cos(k+T)*E+B,v=Math.sin(k+T)*S+x;break;case u.R:y=f=t[b++],w=v=t[b++];L=y+t[b++],I=w+t[b++];if(r){if(i.containStroke(y,w,L,w,e,n,A)||i.containStroke(L,w,L,I,e,n,A)||i.containStroke(L,I,y,I,e,n,A)||i.containStroke(y,I,y,w,e,n,A))return!0}else d+=c(L,w,L,I,n,A),d+=c(y,I,y,w,n,A);break;case u.Z:if(r){if(i.containStroke(f,v,y,w,e,n,A))return!0}else d+=c(f,v,y,w,n,A);f=y,v=w}}return r||(l=v,h=w,Math.abs(l-h)<1e-4)||(d+=c(f,v,y,w,n,A)||0),0!==d}e.contain=function(t,e,r){return v(t,0,!1,e,r)},e.containStroke=function(t,e,r,n){return v(t,e,!0,r,n)}},"2fw6":
|
|
|
/*!**********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Circle.js ***!
|
|
|
\**********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt").extend({type:"circle",shape:{cx:0,cy:0,r:0},buildPath:function(t,e,r){r&&t.moveTo(e.cx+e.r,e.cy),t.arc(e.cx,e.cy,e.r,0,2*Math.PI,!0)}});t.exports=n},"3C/r":
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/Pattern.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=function(t,e){this.image=t,this.repeat=e,this.type="pattern"};r.prototype.getCanvasPattern=function(t){return t.createPattern(this.image,this.repeat||"repeat")};var n=r;t.exports=n},"3CBa":
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/svg/Painter.js ***!
|
|
|
\*************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./core */"hydK").createElement,i=r(/*! ../core/util */"bYtY"),o=r(/*! ../core/log */"SUKs"),a=r(/*! ../graphic/Path */"y+Vt"),s=r(/*! ../graphic/Image */"Dagg"),A=r(/*! ../graphic/Text */"dqUG"),l=r(/*! ../core/arrayDiff2 */"DBLp"),c=r(/*! ./helper/GradientManager */"sW+o"),u=r(/*! ./helper/ClippathManager */"n6Mw"),h=r(/*! ./helper/ShadowManager */"vKoX"),d=r(/*! ./graphic */"P47w"),f=d.path,p=d.image,g=d.text;function m(t){return parseInt(t,10)}function v(t,e){return e&&t&&e.parentNode!==t}function y(t,e,r){if(v(t,e)&&r){var n=r.nextSibling;n?t.insertBefore(e,n):t.appendChild(e)}}function w(t,e){if(v(t,e)){var r=t.firstChild;r?t.insertBefore(e,r):t.appendChild(e)}}function b(t,e){e&&t&&e.parentNode===t&&t.removeChild(e)}function C(t){return t.__textSvgEl}function B(t){return t.__svgEl}var x=function(t,e,r,o){this.root=t,this.storage=e,this._opts=r=i.extend({},r||{});var a=n("svg");a.setAttribute("xmlns","http://www.w3.org/2000/svg"),a.setAttribute("version","1.1"),a.setAttribute("baseProfile","full"),a.style.cssText="user-select:none;position:absolute;left:0;top:0;";var s=n("g");a.appendChild(s);var A=n("g");a.appendChild(A),this.gradientManager=new c(o,A),this.clipPathManager=new u(o,A),this.shadowManager=new h(o,A);var l=document.createElement("div");l.style.cssText="overflow:hidden;position:relative",this._svgDom=a,this._svgRoot=A,this._backgroundRoot=s,this._viewport=l,t.appendChild(l),l.appendChild(a),this.resize(r.width,r.height),this._visibleList=[]};x.prototype={constructor:x,getType:function(){return"svg"},getViewportRoot:function(){return this._viewport},getSvgDom:function(){return this._svgDom},getSvgRoot:function(){return this._svgRoot},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(){var t=this.storage.getDisplayList(!0);this._paintList(t)},setBackgroundColor:function(t){this._backgroundRoot&&this._backgroundNode&&this._backgroundRoot.removeChild(this._backgroundNode);var e=n("rect");e.setAttribute("width",this.getWidth()),e.setAttribute("height",this.getHeight()),e.setAttribute("x",0),e.setAttribute("y",0),e.setAttribute("id",0),e.style.fill=t,this._backgroundRoot.appendChild(e),this._backgroundNode=e},_paintList:function(t){this.gradientManager.markAllUnused(),this.clipPathManager.markAllUnused(),this.shadowManager.markAllUnused();var e,r,n=this._svgRoot,i=this._visibleList,o=t.length,c=[];for(e=0;e<o;e++){var u=t[e],h=(r=u)instanceof a?f:r instanceof s?p:r instanceof A?g:f,d=B(u)||C(u);u.invisible||(u.__dirty&&(h&&h.brush(u),this.clipPathManager.update(u),u.style&&(this.gradientManager.update(u.style.fill),this.gradientManager.update(u.style.stroke),this.shadowManager.update(d,u)),u.__dirty=!1),c.push(u))}var m,v=l(i,c);for(e=0;e<v.length;e++){if((S=v[e]).removed)for(var x=0;x<S.count;x++){d=B(u=i[S.indices[x]]);var E=C(u);b(n,d),b(n,E)}}for(e=0;e<v.length;e++){var S;if((S=v[e]).added)for(x=0;x<S.count;x++){d=B(u=c[S.indices[x]]),E=C(u);m?y(n,d,m):w(n,d),d?y(n,E,d):m?y(n,E,m):w(n,E),y(n,E,d),m=E||d||m,this.gradientManager.addWithoutUpdate(d||E,u),this.shadowManager.addWithoutUpdate(d||E,u),this.clipPathManager.markUsed(u)}else if(!S.removed)for(x=0;x<S.count;x++){d=B(u=c[S.indices[x]]),E=C(u),d=B(u),E=C(u);this.gradientManager.markUsed(u),this.gradientManager.addWithoutUpdate(d||E,u),this.shadowManager.markUsed(u),this.shadowManager.addWithoutUpdate(d||E,u),this.clipPathManager.markUsed(u),E&&y(n,E,d),m=d||E||m}}this.gradientManager.removeUnused(),this.clipPathManager.removeUnused(),this.shadowManager.removeUnused(),this._visibleList=c},_getDefs:function(t){var e,r=this._svgDom;return 0===(e=r.getElementsByTagName("defs")).length?t?((e=r.insertBefore(n("defs"),r.firstChild)).contains||(e.contains=function(t){var r=e.children;if(!r)return!1;for(var n=r.length-1;n>=0;--n)if(r[n]===t)return!0;return!1}),e):null:e[0]},resize:function(t,e){var r=this._viewport;r.style.display="none";var n=this._opts;if(null!=t&&(n.width=t),null!=e&&(n.height=e),t=this._getSize(0),e=this._getSize(1),r.style.display="",this._width!==t||this._height!==e){this._width=t,this._height=e;var i=r.style;i.width=t+"px",i.height=e+"px";var o=this._svgDom;o.setAttribute("width",t),o.setAttribute("height",e)}this._backgroundNode&&(this._backgroundNode.setAttribute("width",t),this._backgroundNode.setAttribute("height",e))},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,r=["width","height"][t],n=["clientWidth","clientHeight"][t],i=["paddingLeft","paddingTop"][t],o=["paddingRight","paddingBottom"][t];if(null!=e[r]&&"auto"!==e[r])return parseFloat(e[r]);var a=this.root,s=document.defaultView.getComputedStyle(a);return(a[n]||m(s[r])||m(a.style[r]))-(m(s[i])||0)-(m(s[o])||0)|0},dispose:function(){this.root.innerHTML="",this._svgRoot=this._backgroundRoot=this._svgDom=this._backgroundNode=this._viewport=this.storage=null},clear:function(){this._viewport&&this.root.removeChild(this._viewport)},toDataURL:function(){return this.refresh(),"data:image/svg+xml;charset=UTF-8,"+encodeURIComponent(this._svgDom.outerHTML.replace(/></g,">\n\r<"))}},i.each(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","pathToImage"],(function(t){var e;x.prototype[t]=(e=t,function(){o('In SVG mode painter not support method "'+e+'"')})}));var E=x;t.exports=E},"3e3G":
|
|
|
/*!************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/RadialGradient.js ***!
|
|
|
\************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/util */"bYtY"),i=r(/*! ./Gradient */"QuXc"),o=function(t,e,r,n,o){this.x=null==t?.5:t,this.y=null==e?.5:e,this.r=null==r?.5:r,this.type="radial",this.global=o||!1,i.call(this,n)};o.prototype={constructor:o},n.inherits(o,i);var a=o;t.exports=a},"3gBT":
|
|
|
/*!***********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/guid.js ***!
|
|
|
\***********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=2311;t.exports=function(){return r++}},"49sm":
|
|
|
/*!***************************************!*\
|
|
|
!*** ./node_modules/isarray/index.js ***!
|
|
|
\***************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r={}.toString;t.exports=Array.isArray||function(t){return"[object Array]"==r.call(t)}},"4fz+":
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/container/Group.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/util */"bYtY"),i=r(/*! ../Element */"1bdT"),o=r(/*! ../core/BoundingRect */"mFDi"),a=function(t){for(var e in t=t||{},i.call(this,t),t)t.hasOwnProperty(e)&&(this[e]=t[e]);this._children=[],this.__storage=null,this.__dirty=!0};a.prototype={constructor:a,isGroup:!0,type:"group",silent:!1,children:function(){return this._children.slice()},childAt:function(t){return this._children[t]},childOfName:function(t){for(var e=this._children,r=0;r<e.length;r++)if(e[r].name===t)return e[r]},childCount:function(){return this._children.length},add:function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},addBefore:function(t,e){if(t&&t!==this&&t.parent!==this&&e&&e.parent===this){var r=this._children,n=r.indexOf(e);n>=0&&(r.splice(n,0,t),this._doAdd(t))}return this},_doAdd:function(t){t.parent&&t.parent.remove(t),t.parent=this;var e=this.__storage,r=this.__zr;e&&e!==t.__storage&&(e.addToStorage(t),t instanceof a&&t.addChildrenToStorage(e)),r&&r.refresh()},remove:function(t){var e=this.__zr,r=this.__storage,i=this._children,o=n.indexOf(i,t);return o<0||(i.splice(o,1),t.parent=null,r&&(r.delFromStorage(t),t instanceof a&&t.delChildrenFromStorage(r)),e&&e.refresh()),this},removeAll:function(){var t,e,r=this._children,n=this.__storage;for(e=0;e<r.length;e++)t=r[e],n&&(n.delFromStorage(t),t instanceof a&&t.delChildrenFromStorage(n)),t.parent=null;return r.length=0,this},eachChild:function(t,e){for(var r=this._children,n=0;n<r.length;n++){var i=r[n];t.call(e,i,n)}return this},traverse:function(t,e){for(var r=0;r<this._children.length;r++){var n=this._children[r];t.call(e,n),"group"===n.type&&n.traverse(t,e)}return this},addChildrenToStorage:function(t){for(var e=0;e<this._children.length;e++){var r=this._children[e];t.addToStorage(r),r instanceof a&&r.addChildrenToStorage(t)}},delChildrenFromStorage:function(t){for(var e=0;e<this._children.length;e++){var r=this._children[e];t.delFromStorage(r),r instanceof a&&r.delChildrenFromStorage(t)}},dirty:function(){return this.__dirty=!0,this.__zr&&this.__zr.refresh(),this},getBoundingRect:function(t){for(var e=null,r=new o(0,0,0,0),n=t||this._children,i=[],a=0;a<n.length;a++){var s=n[a];if(!s.ignore&&!s.invisible){var A=s.getBoundingRect(),l=s.getLocalTransform(i);l?(r.copy(A),r.applyTransform(l),(e=e||r.clone()).union(r)):(e=e||A.clone()).union(A)}}return e||r}},n.inherits(a,i);var s=a;t.exports=s},"4mN7":
|
|
|
/*!***********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/bbox.js ***!
|
|
|
\***********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./vector */"QBsz"),i=r(/*! ./curve */"Sj9i"),o=Math.min,a=Math.max,s=Math.sin,A=Math.cos,l=2*Math.PI,c=n.create(),u=n.create(),h=n.create();var d=[],f=[];e.fromPoints=function(t,e,r){if(0!==t.length){var n,i=t[0],s=i[0],A=i[0],l=i[1],c=i[1];for(n=1;n<t.length;n++)i=t[n],s=o(s,i[0]),A=a(A,i[0]),l=o(l,i[1]),c=a(c,i[1]);e[0]=s,e[1]=l,r[0]=A,r[1]=c}},e.fromLine=function(t,e,r,n,i,s){i[0]=o(t,r),i[1]=o(e,n),s[0]=a(t,r),s[1]=a(e,n)},e.fromCubic=function(t,e,r,n,s,A,l,c,u,h){var p,g=i.cubicExtrema,m=i.cubicAt,v=g(t,r,s,l,d);for(u[0]=1/0,u[1]=1/0,h[0]=-1/0,h[1]=-1/0,p=0;p<v;p++){var y=m(t,r,s,l,d[p]);u[0]=o(y,u[0]),h[0]=a(y,h[0])}for(v=g(e,n,A,c,f),p=0;p<v;p++){var w=m(e,n,A,c,f[p]);u[1]=o(w,u[1]),h[1]=a(w,h[1])}u[0]=o(t,u[0]),h[0]=a(t,h[0]),u[0]=o(l,u[0]),h[0]=a(l,h[0]),u[1]=o(e,u[1]),h[1]=a(e,h[1]),u[1]=o(c,u[1]),h[1]=a(c,h[1])},e.fromQuadratic=function(t,e,r,n,s,A,l,c){var u=i.quadraticExtremum,h=i.quadraticAt,d=a(o(u(t,r,s),1),0),f=a(o(u(e,n,A),1),0),p=h(t,r,s,d),g=h(e,n,A,f);l[0]=o(t,s,p),l[1]=o(e,A,g),c[0]=a(t,s,p),c[1]=a(e,A,g)},e.fromArc=function(t,e,r,i,o,a,d,f,p){var g=n.min,m=n.max,v=Math.abs(o-a);if(v%l<1e-4&&v>1e-4)return f[0]=t-r,f[1]=e-i,p[0]=t+r,void(p[1]=e+i);if(c[0]=A(o)*r+t,c[1]=s(o)*i+e,u[0]=A(a)*r+t,u[1]=s(a)*i+e,g(f,c,u),m(p,c,u),(o%=l)<0&&(o+=l),(a%=l)<0&&(a+=l),o>a&&!d?a+=l:o<a&&d&&(o+=l),d){var y=a;a=o,o=y}for(var w=0;w<a;w+=Math.PI/2)w>o&&(h[0]=A(w)*r+t,h[1]=s(w)*i+e,g(f,h,f),m(p,h,p))}},"55Ip":
|
|
|
/*!***************************************************************!*\
|
|
|
!*** ./node_modules/react-router-dom/esm/react-router-dom.js ***!
|
|
|
\***************************************************************/
|
|
|
/*! exports provided: MemoryRouter, Prompt, Redirect, Route, Router, StaticRouter, Switch, generatePath, matchPath, useHistory, useLocation, useParams, useRouteMatch, withRouter, BrowserRouter, HashRouter, Link, NavLink */
|
|
|
/*! exports used: Link, NavLink */function(t,e,r){"use strict";r.d(e,"a",(function(){return g})),r.d(e,"b",(function(){return y}));var n=r(/*! react-router */"Ty5D"),i=r(/*! @babel/runtime/helpers/esm/inheritsLoose */"dI71"),o=r(/*! react */"q1tI"),a=r.n(o),s=r(/*! history */"YS25"),A=(r(/*! prop-types */"17x9"),r(/*! @babel/runtime/helpers/esm/extends */"wx14")),l=r(/*! @babel/runtime/helpers/esm/objectWithoutPropertiesLoose */"zLVn"),c=r(/*! tiny-invariant */"9R94");a.a.Component;a.a.Component;var u=function(t,e){return"function"==typeof t?t(e):t},h=function(t,e){return"string"==typeof t?Object(s.c)(t,null,null,e):t},d=function(t){return t},f=a.a.forwardRef;void 0===f&&(f=d);var p=f((function(t,e){var r=t.innerRef,n=t.navigate,i=t.onClick,o=Object(l.a)(t,["innerRef","navigate","onClick"]),s=o.target,c=Object(A.a)({},o,{onClick:function(t){try{i&&i(t)}catch(e){throw t.preventDefault(),e}t.defaultPrevented||0!==t.button||s&&"_self"!==s||function(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}(t)||(t.preventDefault(),n())}});return c.ref=d!==f&&e||r,a.a.createElement("a",c)}));var g=f((function(t,e){var r=t.component,i=void 0===r?p:r,o=t.replace,s=t.to,g=t.innerRef,m=Object(l.a)(t,["component","replace","to","innerRef"]);return a.a.createElement(n.e.Consumer,null,(function(t){t||Object(c.a)(!1);var r=t.history,n=h(u(s,t.location),t.location),l=n?r.createHref(n):"",p=Object(A.a)({},m,{href:l,navigate:function(){var e=u(s,t.location);(o?r.replace:r.push)(e)}});return d!==f?p.ref=e||g:p.innerRef=g,a.a.createElement(i,p)}))})),m=function(t){return t},v=a.a.forwardRef;void 0===v&&(v=m);var y=v((function(t,e){var r=t["aria-current"],i=void 0===r?"page":r,o=t.activeClassName,s=void 0===o?"active":o,d=t.activeStyle,f=t.className,p=t.exact,y=t.isActive,w=t.location,b=t.sensitive,C=t.strict,B=t.style,x=t.to,E=t.innerRef,S=Object(l.a)(t,["aria-current","activeClassName","activeStyle","className","exact","isActive","location","sensitive","strict","style","to","innerRef"]);return a.a.createElement(n.e.Consumer,null,(function(t){t||Object(c.a)(!1);var r=w||t.location,o=h(u(x,r),r),l=o.pathname,k=l&&l.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1"),T=k?Object(n.f)(r.pathname,{path:k,exact:p,sensitive:b,strict:C}):null,F=!!(y?y(T,r):T),L=F?function(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return e.filter((function(t){return t})).join(" ")}(f,s):f,I=F?Object(A.a)({},B,{},d):B,_=Object(A.a)({"aria-current":F&&i||null,className:L,style:I,to:o},S);return m!==v?_.ref=e||E:_.innerRef=E,a.a.createElement(g,_)}))}))},"59Ip":
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/cubic.js ***!
|
|
|
\***************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/curve */"Sj9i");e.containStroke=function(t,e,r,i,o,a,s,A,l,c,u){if(0===l)return!1;var h=l;return!(u>e+h&&u>i+h&&u>a+h&&u>A+h||u<e-h&&u<i-h&&u<a-h&&u<A-h||c>t+h&&c>r+h&&c>o+h&&c>s+h||c<t-h&&c<r-h&&c<o-h&&c<s-h)&&n.cubicProjectPoint(t,e,r,i,o,a,s,A,c,u,null)<=h/2}},"5gs/":
|
|
|
/*!**********************************************************************************!*\
|
|
|
!*** ./src/pages/Classrooms/Lists/ShixunHomeworks/Comment/index.tsx + 5 modules ***!
|
|
|
\**********************************************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@ant-design/icons/es/icons/ArrowLeftOutlined.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@ant-design/icons/es/icons/DeleteOutlined.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@ant-design/icons/es/icons/ExclamationCircleOutlined.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@ant-design/icons/es/icons/SolutionOutlined.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/extends.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/toArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Classrooms/Lists/ShixunHomeworks/Comment/components/ShixunStaticItem.less?modules (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Classrooms/Lists/ShixunHomeworks/Comment/index.less?modules (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/.umi-production/core/umiExports.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/PreviewAll/index.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/RenderHtml/index.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/markdown-editor/index.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/monaco-editor/index.jsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Classrooms/Lists/ShixunHomeworks/Detail/components/WorkList/components/Redo.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/service/shixunHomeworks.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/authority.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/env.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/fetch.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/util.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/breadcrumb/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/breadcrumb/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/button/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/button/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/col/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/col/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/divider/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/divider/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/form/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/form/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input-number/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input-number/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/message/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/message/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/modal/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/modal/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/row/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/row/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/select/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/select/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/skeleton/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/skeleton/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/table/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/table/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/echarts-for-react/lib/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/html2pdf.js/dist/html2pdf.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/jszip/dist/jszip.min.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/moment/moment.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react-router-dom/esm/react-router-dom.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react-router/esm/react-router.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r.r(e);var n,i=r("0Owb"),o=(r("cWXX"),r("/ezw")),a=(r("g9YV"),r("wCAj")),s=(r("/zsF"),r("PArb")),A=(r("14J3"),r("BMrR")),l=(r("+L6B"),r("2/Rp")),c=(r("jCWc"),r("kPKH")),u=(r("sPJy"),r("bE4q")),h=(r("miYZ"),r("tsqr")),d=(r("2qtc"),r("kLXV")),f=r("9og8"),p=r("Pv/L"),g=r("k1fw"),m=r("tJVT"),v=r("PpiC"),y=r("WmNS"),w=r.n(y),b=r("q1tI"),C=r.n(b),B=r("wd/R"),x=r.n(B),E=r("xOOu"),S=r.n(E),k=r("Ty5D"),T=r("9kvl"),F=r("55Ip"),L=r("jhfD"),I=r("CTES"),_=r("RCxd"),U=r("/MfK"),O=r("m3rI"),D=r("xKgJ"),Q=r("1vsH"),M=r("cVA7"),R=r.n(M),P=r("z9Ch"),H=r.n(P),N={normal:{opacity:.8,shadowBlur:10,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0, 0, 0, 0)",color:"#2e65ad"}},K=Object(T.a)((function(t){var e=t.shixunHomeworks,r=t.loading;return{shixunHomeworks:e,globalSetting:t.globalSetting,loading:r.effects}}))((function(t){var e,r,n,i,o,a,s,l,u,h,d,f,p=t.shixunHomeworks,g=(t.globalSetting,t.loading,t.dispatch,Object(k.i)(),Object(k.h)()),v=Object(b.useState)([]),y=Object(m.a)(v,2),w=(y[0],y[1],Object(b.useState)(g.query.tabs||0)),B=Object(m.a)(w,2),x=(B[0],B[1],p.shixunWorkReport),E=(null===(e=x.echart_data)||void 0===e?void 0:e.efficiency_list.length)-parseInt(null===(r=x.echart_data)||void 0===r?void 0:r.myself_eff[0]);return C.a.createElement(C.a.Fragment,null,C.a.createElement("aside",{className:"ml60 pr30"},C.a.createElement(A.a,null,C.a.createElement(c.a,{flex:"800px"},C.a.createElement(R.a,{style:{width:750,height:580},option:{title:{text:"学习效率",subtext:"学习效率=log(实训总得分/实训总耗时)"},backgroundColor:"#fff",color:["#dd4444","#fec42c","#80F1BE"],grid:{left:"3%",right:"9%",bottom:"3%",containLabel:!0},tooltip:{showDelay:0,formatter:function(t){var e;return t.name===x.username?"姓名:"+x.username+"<br/>学号: "+x.user_id+"<br/>效率:"+(null===(e=x.echart_data)||void 0===e?void 0:e.myself_eff[1]):t.name+":"+t.value+" "},axisPointer:{show:!0,type:"cross",lineStyle:{type:"dashed",width:1}}},xAxis:[{type:"value",name:"学生位置",nameTextStyle:{color:"#000",fontSize:12},scale:!0,axisLabel:{formatter:""},axisTick:{show:!1},splitLine:{show:!1}}],yAxis:[{type:"value",name:" ",nameGap:20,nameTextStyle:{color:"#000",fontSize:12},scale:!0,axisLabel:{formatter:"{value}"},splitLine:{show:!1}}],series:[{name:"",type:"scatter",data:null===(h=x.echart_data)||void 0===h?void 0:h.efficiency_list,itemStyle:{normal:{color:"#2e65ad"}},markArea:{silent:!0,itemStyle:{normal:{color:"transparent",borderWidth:1,borderType:"dashed"}},data:[[{name:"学习效率分布区间",xAxis:"min",yAxis:"min"},{xAxis:"max",yAxis:"max"}]]},markPoint:{data:[{name:x.username,xAxis:E,yAxis:null===(d=x.echart_data)||void 0===d?void 0:d.myself_eff[1],value:null===(f=x.echart_data)||void 0===f?void 0:f.myself_eff[1]}],itemStyle:{normal:{color:"#c23531"}}},markLine:{lineStyle:{normal:{type:"solid",color:"#ff6800"}},data:[{type:"average",name:"中位值"}]}}]}})),C.a.createElement(c.a,{flex:"1"},C.a.createElement("aside",{className:H.a.rightInfo},C.a.createElement("ul",null,C.a.createElement("li",null,C.a.createElement("span",null,"姓名")," ",C.a.createElement("span",{className:"ml30"},x.username)),C.a.createElement("li",null,C.a.createElement("span",null,"学号")," ",C.a.createElement("span",{className:"ml30"},x.student_id||"--")),C.a.createElement("li",null,C.a.createElement("span",null,"学习效率")," ",C.a.createElement("span",{className:"ml30 c-orange"},null===(n=x.echart_data)||void 0===n?void 0:n.myself_eff[1])),C.a.createElement("li",null,C.a.createElement("span",null,"当前排名")," ",C.a.createElement("span",{className:"ml30 c-orange"},null===(i=x.echart_data)||void 0===i?void 0:i.myself_eff[0]))),C.a.createElement("p",null,"1个小圆点代表1个学生的学习效率",C.a.createElement("br",null),"红色水滴表示当前学生的学习效率值",C.a.createElement("br",null),"小圆点越高,学习效率越高",C.a.createElement("br",null),"橙色横向箭头:中位值,表示整个课堂学生表现的平均值"))))),C.a.createElement("aside",{className:"ml60 pr30"},C.a.createElement(A.a,null,C.a.createElement(c.a,{flex:"800px"},C.a.createElement(R.a,{style:{width:750,height:580},option:{title:{text:"能力值",subtext:"能力值(实训获得经验值/实训评测次数)"},backgroundColor:"#fff",color:["#dd4444","#fec42c","#80F1BE"],grid:{x:"10%",x2:150,y:"18%",y2:"10%"},tooltip:{padding:10,backgroundColor:"#222",borderColor:"#777",borderWidth:1,formatter:function(t){var e;if(t.value,t.name===x.username)return"姓名:"+x.username+"<br/>学号: "+x.user_id+"<br/>得分:"+(null===(e=x.echart_data)||void 0===e?void 0:e.myself_object[1])}},xAxis:{type:"value",name:"log(实训的总时间)",nameGap:16,nameTextStyle:{color:"#000",fontSize:14},splitLine:{show:!1},axisLine:{lineStyle:{color:"#000"}}},yAxis:{type:"value",name:" ",nameLocation:"end",nameGap:20,nameTextStyle:{color:"#000",fontSize:12},axisLine:{lineStyle:{color:"#000"}},splitLine:{show:!1}},series:[{name:"能力",type:"scatter",itemStyle:N,data:null===(a=x.echart_data)||void 0===a?void 0:a.consume_list,symbolSize:function(t){return Math.round(t[2])},markPoint:{data:[{name:x.username,xAxis:null===(s=x.echart_data)||void 0===s?void 0:s.myself_object[0],yAxis:null===(l=x.echart_data)||void 0===l?void 0:l.myself_object[1],value:null===(u=x.echart_data)||void 0===u?void 0:u.myself_object[1]}],itemStyle:{normal:{color:"#c23531"}}}}]}})),C.a.createElement(c.a,{flex:"1"},C.a.createElement("aside",{className:H.a.rightInfo},C.a.createElement("ul",null,C.a.createElement("li",null,C.a.createElement("span",null,"姓名")," ",C.a.createElement("span",{className:"ml30"},x.username)),C.a.createElement("li",null,C.a.createElement("span",null,"学号")," ",C.a.createElement("span",{className:"ml30"},x.student_id||"--")),C.a.createElement("li",null,C.a.createElement("span",null,"能力")," ",C.a.createElement("span",{className:"ml30 c-orange"},null===(o=x.echart_data)||void 0===o?void 0:o.myself_object[1]))),C.a.createElement("p",null,"1个小圆点代表1个学生的能力值",C.a.createElement("br",null),"红色水滴表示当前学生的能力值",C.a.createElement("br",null),"小圆圈越大,评测次数越少",C.a.createElement("br",null)))))))})),j=(r("giR+"),r("fyUT")),G=function(t){var e=t.defaultValue,r=t.onBlur,n=t.max,i=t.className,o=void 0===i?"game-score":i,a=Object(b.useState)(e),s=Object(m.a)(a,2),A=s[0],l=s[1];return Object(b.useEffect)((function(){l(e)}),[e]),C.a.createElement(j.a,{max:n,min:0,className:o,value:A,onChange:function(t){l(t)},onBlur:function(){A!==e&&r(A>n?n:A)}})},V=(r("OaEy"),r("2fM7")),z=r("ZW9T"),W=r("Ot1p"),Y=r("1eJ8"),X=r.n(Y),q=V.a.Option,J={selectOnLineNumbers:!0,readOnly:!0,minimap:{enabled:!1},scrollBeyondLastLine:!1,enableSplitViewResizing:!1,roundedSelection:!1,renderIndicators:!1,useShadows:!1};function Z(t,e){switch(e.type){case n.SET_PATH:return Object(g.a)(Object(g.a)({},t),{},{selectedPath:e.payload});case n.GET_PASSED_CONTENT:return Object(g.a)(Object(g.a)({},t),{},{passedContent:e.payload});default:throw new Error}}!function(t){t[t.SET_PATH=0]="SET_PATH",t[t.GET_PASSED_CONTENT=1]="GET_PASSED_CONTENT"}(n||(n={}));var $=function(t){var e,r,i,o,a=t.path,s=(t.game_id,t.onPathChange,t.autoHeight),A=t.diff_code_count,l=t.data,c=a.split(";").filter((function(t){return!!t})),u=Object(b.useReducer)(Z,{selectedPath:c[0],passedContent:{language:"python",content:""}}),h=Object(m.a)(u,2),d=h[0],f=h[1],p=d.selectedPath,g=d.passedContent;return C.a.createElement(C.a.Fragment,null,C.a.createElement("h2",null," ",C.a.createElement("span",null,"最后通关的代码"),A&&C.a.createElement("span",{style:{marginLeft:"50px"}},"代码修改行数 ",A),C.a.createElement("span",null,C.a.createElement(V.a,{style:{width:200},value:p,onChange:function(t){f({type:n.SET_PATH,payload:t})}}," ",c.map((function(t){return C.a.createElement(q,{key:t,value:t},t)}))," "))," "),"md"===(null==p?void 0:p.split(".")[1])&&C.a.createElement(W.a,{height:300,autoHeight:s,defaultValue:(null==l||null===(e=l.filter((function(t){return t.path===p})))||void 0===e||null===(r=e[0])||void 0===r?void 0:r.content)||"",className:X.a.md}),"md"!==(null==p?void 0:p.split(".")[1])&&C.a.createElement(z.b,{height:300,language:g.language,value:(null==l||null===(i=l.filter((function(t){return t.path===p})))||void 0===i||null===(o=i[0])||void 0===o?void 0:o.content)||"",autoHeight:s,theme:"default",options:J}))},tt=r("ErOA"),et=Object(T.a)((function(t){var e=t.shixunHomeworks,r=t.loading;return{shixunHomeworks:e,globalSetting:t.globalSetting,loading:r.effects}}))((function(t){var e=t.shixunHomeworks,r=t.autoHeight,n=t.dispatch,i=e.shixunWorkReport,o=i.stage_list,s=i.work_id,A=Object(k.i)(),l=Object(D.c)(),c=[{title:"评测次数",dataIndex:"position",width:120},{title:"详细信息",dataIndex:"output_detail"}];function u(){return(u=Object(f.a)(w.a.mark((function t(e,r){var i,a;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=o[e].challenge_id,t.next=3,n({type:"shixunHomeworks/changeScore",payload:{categoryId:A.homeworkId,type:"report",score:r,challenge_id:i}});case 3:return a=t.sent,t.next=6,n({type:"shixunHomeworks/getShixunWorkReport",payload:Object(g.a)({},A)});case 6:0===a.status&&h.b.success("操作成功");case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function d(t,e){return Object(tt.c)("student_works/".concat(s,"/rep_passed_content.json"),{path:e,game_id:t})}var p=Object(Q.n)(5,i.shixun_detail);return C.a.createElement(C.a.Fragment,null,null==p?void 0:p.map((function(t,e){return C.a.createElement("div",{key:e},t.map((function(t,n){var i;return C.a.createElement("aside",{className:"pl30 pr30",key:n},C.a.createElement("div",{className:"".concat(H.a.shixunTitle," mt10")},C.a.createElement("div",null,C.a.createElement("span",{className:"fa fa-code "}),C.a.createElement("strong",{className:"c-black"},"第",5*e+n+1,"关 ",C.a.createElement(F.a,{className:"c-black",to:"/tasks/".concat(t.game_identifier)},t.subject))),l?C.a.createElement("span",null,"调分:",C.a.createElement(G,{className:"game-score",max:o[n].game_score_full,defaultValue:o[n].game_score,onBlur:function(t){!function(t,e){u.apply(this,arguments)}(n,t)}})):null),C.a.createElement("div",{className:"font16 mt10"},0===t.st&&0===t.complete_status&&"本关暂未通过,无通关代码",0===t.st&&0!==t.complete_status&&(t.path?C.a.createElement("aside",{className:H.a.shixunWrp},C.a.createElement($,{autoHeight:r,path:t.path,game_id:t.id,data:t.game_codes,diff_code_count:t.diff_code_count,onPathChange:d})):"已通关,无代码展示"),1===t.st&&(0===t.complete_status?"本关暂未通过,无通关代码":"已通关,无代码展示")),C.a.createElement("aside",{className:"mt10 font16"},null!==(i=t.outputs)&&void 0!==i&&i.length?C.a.createElement(a.a,{columns:c,pagination:{hideOnSinglePage:!0},dataSource:t.outputs}):"本关无评测记录"))})))})))})),rt=(r("5NDa"),r("5rEg")),nt=(r("y8nQ"),r("Vl3Y")),it=Object(T.a)((function(t){return{shixunHomeworks:t.shixunHomeworks}}))((function(t){var e=t.shixunHomeworks,r=t.dispatch,n=(Object(v.a)(t,["shixunHomeworks","dispatch"]),Object(k.i)()),i=Object(b.useState)(!1),o=Object(m.a)(i,2),a=o[0],s=o[1],A=nt.a.useForm(),l=Object(m.a)(A,1)[0];Object(b.useEffect)((function(){var t,r,n,i;"更改点评"===e.actionTabs.key&&l.setFieldsValue({comment:null===(t=e.actionTabs.selectArrs)||void 0===t||null===(r=t.data)||void 0===r?void 0:r.work_comment,hidden_comment:null===(n=e.actionTabs.selectArrs)||void 0===n||null===(i=n.data)||void 0===i?void 0:i.work_comment_hidden})}),[e.actionTabs.key]);var c=function(){var t=Object(f.a)(w.a.mark((function t(){var e;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e=l.getFieldValue(),t.next=3,Object(tt.a)("/api/student_works/".concat(n.homeworkId,"/shixun_work_comment.json"),{method:"post",body:{hidden_comment:e.hidden_comment,comment:e.comment}});case 3:0===t.sent.status&&(h.b.success("评阅成功"),l.resetFields(),r({type:"shixunHomeworks/setActionTabs",payload:{}}),r({type:"shixunHomeworks/getShixunWorkReport",payload:Object(g.a)({},n)}));case 5:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();return C.a.createElement(C.a.Fragment,null,C.a.createElement(d.a,{centered:!0,title:"更改点评",visible:"更改点评"===e.actionTabs.key,okText:"确定",cancelText:"取消",onOk:Object(f.a)(w.a.mark((function t(){var e;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=l.getFieldValue(),"{}"===JSON.stringify(e)||""===e.hidden_comment&&""===e.comment?s(!0):c();case 2:case"end":return t.stop()}}),t)}))),onCancel:function(){r({type:"shixunHomeworks/setActionTabs",payload:{}})}},C.a.createElement(nt.a,{form:l,onChange:function(){a&&s(!1)}},C.a.createElement("p",null,"学生和课堂老师可见"),C.a.createElement(nt.a.Item,{name:"comment"},C.a.createElement(rt.a.TextArea,{placeholder:"请输入评阅内容",rows:8})),C.a.createElement("p",null,"仅课堂老师可见"),C.a.createElement(nt.a.Item,{name:"hidden_comment"},C.a.createElement(rt.a.TextArea,{placeholder:"请输入评阅内容",rows:8}))),a&&C.a.createElement("p",{className:"c-red"},"评阅内容至少有一个不为空")))})),ot=r("Xm8N"),at=r("9Bee"),st=r("XYT7"),At=r("1n7x"),lt=r.n(At),ct=r("p5ED");e.default=Object(T.a)((function(t){var e=t.shixunHomeworks,r=t.loading;return{shixunHomeworks:e,globalSetting:t.globalSetting,loading:r.effects}}))((function(t){var e,r,n,y,B,E=t.shixunHomeworks,M=(t.globalSetting,t.loading,t.dispatch),R=Object(v.a)(t,["shixunHomeworks","globalSetting","loading","dispatch"]),P=Object(b.useState)(Object(g.a)({},Object(k.i)())),N=Object(m.a)(P,2),j=N[0],V=N[1],z=Object(k.i)(),W=Object(b.useState)([]),Y=(Object(p.a)(W),Object(b.useState)({last:!1})),X=Object(m.a)(Y,2),q=X[0],J=X[1],Z=Object(b.useState)({last:!1}),$=Object(m.a)(Z,2),tt=$[0],rt=$[1],nt=Object(b.useRef)(),At=Object(b.useRef)(),ut=Object(b.useState)(!1),ht=Object(m.a)(ut,2),dt=ht[0],ft=ht[1],pt=Object(b.useState)(!1),gt=Object(m.a)(pt,2),mt=gt[0],vt=gt[1],yt=Object(b.useState)(!1),wt=Object(m.a)(yt,2),bt=wt[0],Ct=wt[1],Bt=E.shixunWorkReport,xt=Object(D.c)(),Et=Object(b.useState)(new S.a),St=Object(m.a)(Et,2),kt=St[0],Tt=St[1],Ft=Object(b.useState)(0),Lt=Object(m.a)(Ft,2),It=(Lt[0],Lt[1],Object(b.useState)([])),_t=Object(m.a)(It,2),Ut=_t[0],Ot=_t[1],Dt=Object(b.useState)(!1),Qt=Object(m.a)(Dt,2),Mt=Qt[0],Rt=Qt[1],Pt=Object(b.useState)(!1),Ht=Object(m.a)(Pt,2),Nt=Ht[0],Kt=Ht[1],jt=Object(b.useState)({name:"",filename:"",type:"",className:"",data:"",close:!0,hasMask:!0,style:{position:"fixed",zIndex:9999,background:"rgba(0,0,0,.7)"},monacoEditor:{value:"",language:"",theme:"vs",options:{readOnly:!0}}}),Gt=Object(m.a)(jt,2),Vt=Gt[0],zt=Gt[1];Object(b.useEffect)((function(){return M({type:"globalSetting/footerToggle",payload:!1}),function(){M({type:"globalSetting/footerToggle",payload:!0})}}),[]),Object(b.useEffect)((function(){"导出实训报告"===E.actionTabs.key&&Ut.length>0&&Jt("all")}),[Ut]),Object(b.useEffect)((function(){V(Object(g.a)({},z))}),[R.location.pathname]);var Wt=function(){document.body.scrollIntoView()};function Yt(){return Xt.apply(this,arguments)}function Xt(){return(Xt=Object(f.a)(w.a.mark((function t(){var e,r,n,i,o,a,s;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=JSON.parse(sessionStorage.all_student_works_params||"{}"),t.next=3,M({type:"shixunHomeworks/getAllStudentWorks",payload:Object(g.a)(Object(g.a)({},j),n)});case 3:i=t.sent,Ot(i.all_student_works),(o=null===(e=i.all_student_works)||void 0===e?void 0:e.map((function(t){return String(t.student_work_id)})).indexOf(j.homeworkId))===(null===(r=i.all_student_works)||void 0===r?void 0:r.length)-1?J({last:!0}):J(null===(a=i.all_student_works)||void 0===a?void 0:a[o+1]),rt(0===o?{last:!0}:null===(s=i.all_student_works)||void 0===s?void 0:s[o-1]);case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}var qt=function(){document.querySelectorAll("canvas").forEach((function(t){(!t.clientWidth||!t.clientHeight)&&t.remove()}))},Jt=function(){var t=Object(f.a)(w.a.mark((function t(e){var r,n,i,o,a,s;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(a=function(){return(a=Object(f.a)(w.a.mark((function t(){var e;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,M({type:"shixunHomeworks/getShixunWorkReport",payload:{homeworkId:Ut[r].student_work_id}});case 2:e=t.sent,Wt(),r++,setTimeout(Object(f.a)(w.a.mark((function t(){var a,s,A,l,c,u,h;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:qt(),s=kt.folder("".concat(null==e?void 0:e.username)),A=document.querySelector("#export-all").children,l=lt()(),c=w.a.mark((function t(e){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,l.set(i).from(A[e]).toContainer().toCanvas().toPdf().get("pdf").then(function(){var t=Object(f.a)(w.a.mark((function t(r){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e<A.length-1)){t.next=3;break}return t.next=3,r.addPage();case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());case 2:case"end":return t.stop()}}),t)})),u=0;case 6:if(!(u<A.length)){t.next=11;break}return t.delegateYield(c(u),"t0",8);case 8:u++,t.next=6;break;case 11:s.file("".concat(Ut[r-1].student_work_user_name).concat(r,".pdf"),l.output("blob")),h=s.folder("代码文件"),null==e||null===(a=e.shixun_detail)||void 0===a||a.map((function(t,e){var r,n=h.folder("第".concat(e+1,"关-").concat(t.subject,"-").concat(t.id));null==t||null===(r=t.game_codes)||void 0===r||r.map((function(t){n.file("".concat(t.filename,".txt"),null==t?void 0:t.content)}))})),n.update({content:C.a.createElement("div",null,"当前进度: ",C.a.createElement("span",{className:"c-blue"},r),"/",null==Ut?void 0:Ut.length,C.a.createElement("br",null),"请勿关闭浏览器窗口")}),r==(null==Ut?void 0:Ut.length)?(n.destroy(),Zt()):o();case 16:case"end":return t.stop()}}),t)}))),2200);case 6:case"end":return t.stop()}}),t)})))).apply(this,arguments)},o=function(){return a.apply(this,arguments)},r=0,n=d.a.info({width:460,title:C.a.createElement("div",null,"正在导出实训报告,",C.a.createElement("span",{className:"c-red"},"请勿关闭或操作当前浏览器窗口")),content:C.a.createElement("div",null,"当前进度: ",C.a.createElement("span",{className:"c-blue"},r+1),"/","all"!==e?1:null==Ut?void 0:Ut.length,C.a.createElement("br",null),"请勿关闭浏览器窗口"),maskClosable:!1,className:H.a.modal,onOk:function(){}}),i={margin:[0,0],filename:"".concat(Bt.username,".pdf"),html2canvas:{useCORS:!0,letterRendering:!0},jsPDF:{unit:"mm",format:"a4",orientation:"landscape"}},!("all"!==e||(null==Ut?void 0:Ut.length)<2)){t.next=12;break}return t.delegateYield(w.a.mark((function t(){var e,r,o,a,s,A,l;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:qt(),Wt(),r=At.current.children,o=lt()(),a=kt.folder("".concat(null==Bt?void 0:Bt.username)),s=w.a.mark((function t(e){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,o.set(i).from(r[e]).toContainer().toCanvas().toPdf().get("pdf").then(function(){var t=Object(f.a)(w.a.mark((function t(n){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e<r.length-1)){t.next=3;break}return t.next=3,n.addPage();case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());case 2:case"end":return t.stop()}}),t)})),A=0;case 7:if(!(A<r.length)){t.next=12;break}return t.delegateYield(s(A),"t0",9);case 9:A++,t.next=7;break;case 12:return ft(!1),a.file("".concat(Bt.username,".pdf"),o.output("blob"),{base64:!1}),l=a.folder("代码文件"),null==Bt||null===(e=Bt.shixun_detail)||void 0===e||e.map((function(t,e){var r,n=l.folder("第".concat(e+1,"关-").concat(t.subject,"-").concat(t.id));null==t||null===(r=t.game_codes)||void 0===r||r.map((function(t){n.file("".concat(t.filename,".txt"),null==t?void 0:t.content)}))})),n.destroy(),Zt(),t.abrupt("return",{v:void 0});case 19:case"end":return t.stop()}}),t)}))(),"t0",7);case 7:if("object"!=typeof(s=t.t0)){t.next=10;break}return t.abrupt("return",s.v);case 10:t.next=13;break;case 12:o();case 13:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),Zt=function(){kt.generateAsync({type:"blob"}).then((function(t){var e=document.createElement("a");e.href=window.URL.createObjectURL(t),e.download=Bt.course_name+".zip",document.body.appendChild(e);var r=document.createEvent("MouseEvents");r.initEvent("click",!1,!1),e.dispatchEvent(r),document.body.removeChild(e),Tt(new S.a)})),Ct(!1)};Object(b.useEffect)((function(){$t()}),[j.homeworkId]);var $t=function(){var t=Object(f.a)(w.a.mark((function t(){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return vt(!0),t.next=3,M({type:"shixunHomeworks/getShixunWorkReport",payload:Object(g.a)({},j)});case 3:vt(!1),Object(D.c)()&&Yt();case 5:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),te=[{title:"关卡",dataIndex:"name",render:function(t,e,r){return r+1}},{title:"任务名称",dataIndex:"name"},{title:"开启时间",dataIndex:"open_time"},{title:"代码修改行数",dataIndex:"diff_code_count",render:function(t,e,r){return t||"- -"}},{title:"评测次数",dataIndex:"evaluate_count"},{title:"完成时间",dataIndex:"finished_time"},{title:"实训耗时",dataIndex:"time_consuming"},{title:"是否查看答案",dataIndex:"view_answer",render:function(t){return t?"是":"否"}},{title:"经验值",dataIndex:"experience",render:function(t,e){return C.a.createElement("div",null,C.a.createElement("span",{className:"c-green"},e.myself_experience),"/",t)}},{title:"关卡得分",dataIndex:"game_score",render:function(t,e){return C.a.createElement("div",null,C.a.createElement("span",{className:"c-green"},t),"/",e.game_score_full)}},{title:"调分",dataIndex:"game_score",render:function(t,e){return xt?C.a.createElement(G,{max:e.game_score_full,defaultValue:parseFloat(t),onBlur:function(){var t=Object(f.a)(w.a.mark((function t(r){var n;return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,M({type:"shixunHomeworks/changeScore",payload:{categoryId:j.homeworkId,type:"report",score:r,challenge_id:e.challenge_id}});case 2:return n=t.sent,t.next=5,M({type:"shixunHomeworks/getShixunWorkReport",payload:Object(g.a)({},j)});case 5:0===n.status&&h.b.success("操作成功");case 6:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()}):t}}],ee=function(t){M({type:"shixunHomeworks/setActionTabs",payload:{key:"",type:2}}),setTimeout((function(){"next"===t?T.d.push("/classrooms/".concat(j.coursesId,"/shixun_homework/").concat(j.categoryId,"/").concat(null==q?void 0:q.student_work_id,"/comment")):T.d.push("/classrooms/".concat(j.coursesId,"/shixun_homework/").concat(j.categoryId,"/").concat(null==tt?void 0:tt.student_work_id,"/comment"))}),200)};return C.a.createElement("section",{className:"bg-fafafa mb100",style:{position:"sticky",top:0}},C.a.createElement("div",{className:"edu-container mt10"},C.a.createElement(o.a,{loading:mt,active:!0,avatar:{size:40},paragraph:{rows:5}},C.a.createElement("div",{className:"edu-container"},Bt.course_id&&C.a.createElement("section",{className:"animated fadeIn"},C.a.createElement("aside",{className:""},Bt.category&&C.a.createElement(u.a,{separator:">"},C.a.createElement(u.a.Item,null,C.a.createElement(F.a,{to:"/classrooms/".concat(Bt.course_id,"/shixun_homework")},Bt.course_name)),C.a.createElement(u.a.Item,null,C.a.createElement(F.a,{to:"/classrooms/".concat(Bt.course_id,"/shixun_homework/").concat(Bt.category.main?"":Bt.category.category_id)},Bt.category.category_name)),C.a.createElement(u.a.Item,null,C.a.createElement(F.a,{to:"/classrooms/".concat(Bt.course_id,"/shixun_homework/").concat(Bt.homework_common_id,"/detail")},"作业详情")),C.a.createElement(u.a.Item,null,Bt.username))),C.a.createElement("aside",{className:[H.a.title1,"mt20"].join(" ")},C.a.createElement(A.a,{align:"middle"},C.a.createElement(c.a,{flex:1},C.a.createElement(F.a,{to:"/classrooms/".concat(Bt.course_id,"/shixun_homework/").concat(Bt.homework_common_id,"/detail")},C.a.createElement(L.a,{className:"font16 c-black"})),C.a.createElement("strong",{className:"font20 ml5"},Bt.shixun_name),C.a.createElement(Q.k,{temporary:!0,status:Bt.homework_status})),C.a.createElement(c.a,{className:H.a.title1_right},Bt.view_tpi&&C.a.createElement(l.a,null,C.a.createElement("span",{className:"iconfont icon-yijiandianping mr5"}),C.a.createElement(F.a,{className:"c-black",target:"_blank",to:"/tasks/".concat(null==Bt||null===(e=Bt.shixun_detail)||void 0===e||null===(r=e[0])||void 0===r?void 0:r.game_identifier)},"查看学员实训")),Object(D.c)()&&!1===Bt.homework_end&&!!Bt.myshixun_id&&C.a.createElement(l.a,{className:"ml10",onClick:Object(f.a)(w.a.mark((function t(){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,M({type:"shixunHomeworks/setActionTabs",payload:{key:"打回重做",selectArrs:{myshixun_identifier:Bt.myshixun_identifier}}});case 2:case"end":return t.stop()}}),t)})))},C.a.createElement("span",{className:"iconfont icon-dahuizhongzuo3x mr5"}),"打回重做"),C.a.createElement(l.a,{className:"ml10",onClick:function(){return Jt("")},loading:dt},C.a.createElement("span",{className:"iconfont icon-daochu mr5"}),"导出实训报告"),Object(D.c)()&&(null==Ut?void 0:Ut.length)>1&&C.a.createElement(l.a,{className:"ml10",onClick:function(){return Jt("all")}},C.a.createElement("span",{className:"iconfont icon-daochu mr5"}),"导出全部学生实训报告"))))),C.a.createElement("aside",{className:"mt30 relative"})),C.a.createElement("aside",{className:"edu-container bg-white",ref:nt},C.a.createElement("div",{id:"export-all",ref:At},C.a.createElement("div",{id:"export-all-1"},C.a.createElement("div",{className:H.a.title},C.a.createElement("h1",null,"总体评价"),C.a.createElement("div",null,Object(D.c)()&&C.a.createElement(l.a,{className:"mr20",type:"primary",onClick:function(){M({type:"shixunHomeworks/setActionTabs",payload:{key:"更改点评",selectArrs:{myshixun_identifier:Bt.user_id,data:Object(g.a)({},Bt)}}})}},C.a.createElement(I.a,null),Bt.has_shixun_work_comment?"更改点评":"点评作业"))),C.a.createElement(s.a,{style:{marginTop:0}}),C.a.createElement(A.a,{className:"pl30 pr30"},C.a.createElement(c.a,null,C.a.createElement("img",{className:H.a.userPic,src:"".concat(O.a.IMG_SERVER,"/images/").concat(Bt.image_url),alt:Bt.username})),C.a.createElement(c.a,null,C.a.createElement("span",{className:"font16 ml40"},Bt.username),C.a.createElement(Q.e,{status:Bt.compelete_status}),C.a.createElement("ul",{className:H.a.userInfo},C.a.createElement("li",null,"学号:",Bt.student_id||"--"),C.a.createElement("li",null,"分班:",Bt.group_name||"--"),C.a.createElement("br",null),C.a.createElement("li",null,"截止前完成关卡:",C.a.createElement("span",{className:"c-red"},Bt.complete_count),"/",C.a.createElement("span",{className:"c-red"},Bt.challenges_count)),C.a.createElement("li",null,"最新完成关卡:",C.a.createElement("span",{className:"c-red"},Bt.current_complete_count||"-"),"/",C.a.createElement("span",{className:"c-red"},Bt.challenges_count)),C.a.createElement("li",null,"完成效率:",Bt&&null===Bt.efficiency?"--":Bt&&Bt.efficiency),C.a.createElement("li",null,"课堂最高完成效率:",Bt&&null===Bt.max_efficiency?"--":Bt&&Bt.max_efficiency))),C.a.createElement("ul",{className:[H.a.listItem,"mt10"].join(" ")},C.a.createElement("li",null,C.a.createElement("strong",null,"通关时间"),C.a.createElement("div",{className:"c-light-black mt20"},Bt&&null===Bt.passed_time||Bt&&"--"===Bt.passed_time?"--":x()(Bt&&Bt.passed_time).format("YYYY-MM-DD HH:mm"))),C.a.createElement("li",null,C.a.createElement("strong",null,"计时规则",C.a.createElement("i",{onClick:function(t){t.stopPropagation(),t.preventDefault(),Rt(!0)},style:{marginLeft:4,color:"#145DFF",fontSize:16,cursor:"pointer"},className:"iconfont icon-tishixiaowenhao"})),C.a.createElement("div",{className:"c-light-black mt20"},null==Bt?void 0:Bt.human_training_time_rules)),C.a.createElement("li",null,C.a.createElement("strong",null,"实训总耗时",C.a.createElement("i",{onClick:function(t){t.stopPropagation(),t.preventDefault(),Kt(!0)},style:{marginLeft:4,color:"#145DFF",fontSize:16,cursor:"pointer"},className:"iconfont icon-tishixiaowenhao"})),C.a.createElement("div",{className:"c-light-black mt20"},Bt.time_consuming)),C.a.createElement("li",null,C.a.createElement("strong",null,"评测次数"),C.a.createElement("div",{className:"mt20"},Bt.evaluate_count)),(null==Bt?void 0:Bt.eff_score_full)&&C.a.createElement(C.a.Fragment,null,C.a.createElement("li",null,C.a.createElement("strong",null,"关卡得分"),C.a.createElement("div",{className:"mt20"},C.a.createElement("span",{className:"c-orange"},Bt.challenge_score),"/",C.a.createElement("span",{className:"c-light-black"},Bt.challenge_score_full))),C.a.createElement("li",null,C.a.createElement("strong",null,"效率分"),C.a.createElement("div",{className:"mt20"},C.a.createElement("span",{className:"c-orange"},Bt.eff_score),"/",C.a.createElement("span",{className:"c-light-black"},Bt.eff_score_full)))),C.a.createElement("li",null,C.a.createElement("strong",null,"迟交扣分"),C.a.createElement("div",{className:"mt20"},C.a.createElement("span",null,Bt.late_penalty||"- -"))),C.a.createElement("li",null,C.a.createElement("strong",null,"最终成绩"),C.a.createElement("div",{className:"mt20"},C.a.createElement("span",{className:"c-orange"},Bt.work_score),"/",C.a.createElement("span",{className:"c-light-black"},Bt.all_work_score))),C.a.createElement("li",null,C.a.createElement("strong",null,"总评"),C.a.createElement("div",{className:"mt20"},C.a.createElement("span",{className:"c-orange"},Bt.overall_appraisal))))),C.a.createElement(s.a,{style:{margin:0}}),(Bt.work_comment_hidden||Bt.work_comment)&&C.a.createElement("div",null,C.a.createElement(A.a,{align:"middle"},C.a.createElement(c.a,{flex:1},C.a.createElement("h1",{className:H.a.title},"点评内容")),C.a.createElement(c.a,{className:"pr30"},Object(D.c)()&&C.a.createElement(l.a,{onClick:Object(f.a)(w.a.mark((function t(){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:d.a.confirm({centered:!0,okText:"确定",cancelText:"取消",title:"提示",icon:C.a.createElement(_.a,null),content:"是否确认删除?",onOk:function(){return Object(f.a)(w.a.mark((function t(){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(st.m)({comment_id:Bt.comment_id,homeworkId:j.homeworkId});case 2:0===t.sent.status&&(h.b.success("删除成功"),M({type:"shixunHomeworks/getShixunWorkReport",payload:Object(g.a)({},j)}));case 4:case"end":return t.stop()}}),t)})))()}});case 1:case"end":return t.stop()}}),t)})))},C.a.createElement(U.a,null),"删除"))),C.a.createElement(s.a,{style:{margin:0}}),Bt.work_comment&&C.a.createElement("aside",{className:"pl30 pr30 mt20"},C.a.createElement("span",{className:"c-light-black font12"},"# 学生和课堂老师可见"),C.a.createElement("br",null),C.a.createElement(at.a,{value:Bt.work_comment})),Bt.work_comment_hidden&&C.a.createElement("aside",{className:"pl30 pr30 mt20"},C.a.createElement("span",{className:"c-light-black font12"},"# 仅课堂老师可见"),C.a.createElement("br",null),C.a.createElement(at.a,{value:Bt.work_comment_hidden}))),(null==Bt?void 0:Bt.allow_experiment_report)&&C.a.createElement(C.a.Fragment,null,C.a.createElement("h1",{className:H.a.title},"实验报告"),C.a.createElement("aside",{className:"pl30 pr30"},C.a.createElement(at.a,{className:H.a.reportContent,value:(null==Bt||null===(n=Bt.experiment_report)||void 0===n?void 0:n.content)||"暂未上传实验报告"}),null==Bt||null===(y=Bt.experiment_report)||void 0===y||null===(B=y.attachments)||void 0===B?void 0:B.map((function(t){return C.a.createElement(A.a,{key:t.id},C.a.createElement("a",{onClick:function(){["office","pdf","image","other","video","audio","download"].includes(t.file_type)?zt(Object(g.a)(Object(g.a)({},Vt),{},{filename:t.name,type:t.file_type,data:O.a.API_SERVER+t.url})):h.b.info("当前类型暂不支持预览")}},t.title)," ",C.a.createElement("a",{href:"".concat(O.a.API_SERVER).concat(t.url),download:!0,style:{marginLeft:20}},"下载"))})))),C.a.createElement("h1",{className:H.a.title},"阶段成绩"),C.a.createElement("aside",{className:"pl30 pr30"},C.a.createElement(a.a,{dataSource:Bt.stage_list,pagination:!1,columns:te})),(null==Bt?void 0:Bt.work_description)&&C.a.createElement(C.a.Fragment,null,C.a.createElement("h1",{className:H.a.title},"个人总结"),C.a.createElement("aside",{className:"pl30 pr30"},C.a.createElement(at.a,{value:null==Bt?void 0:Bt.work_description}))),C.a.createElement("h1",{className:H.a.title},"图形统计"),C.a.createElement(K,null),C.a.createElement("h1",{className:H.a.title},"实训详情")),C.a.createElement(et,{autoHeight:bt}))),Object(D.c)()&&C.a.createElement("aside",{className:"".concat(H.a.footerBar," ").concat(dt?H.a.footerBarStatic:"")},C.a.createElement("aside",{className:"edu-container"},C.a.createElement(A.a,{align:"middle"},C.a.createElement(c.a,{flex:"1"},C.a.createElement(F.a,{className:H.a.exitComment,to:"/classrooms/".concat(j.coursesId,"/shixun_homework/").concat(j.categoryId,"/detail")},"返回列表")),C.a.createElement(c.a,{flex:"1",className:"tr"},C.a.createElement(l.a,{type:"default",disabled:null==tt?void 0:tt.last,onClick:function(){return ee()}},"上一个"),C.a.createElement(l.a,{type:"default",style:{marginLeft:"20px",marginRight:"20px"},disabled:null==q?void 0:q.last,onClick:function(){return ee("next")}},"下一个"),Object(D.c)()&&C.a.createElement(l.a,{type:"primary",onClick:Object(f.a)(w.a.mark((function t(){return w.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:M({type:"shixunHomeworks/setActionTabs",payload:{key:"更改点评",selectArrs:{myshixun_identifier:Bt.user_id,data:Object(g.a)({},Bt)}}});case 1:case"end":return t.stop()}}),t)})))},"点评作业"))))))),C.a.createElement(it,null),C.a.createElement(ot.a,null),C.a.createElement(d.a,{visible:Mt,width:860,centered:!0,onCancel:function(){Rt(!1)},title:"计时规则说明",footer:null},C.a.createElement("div",{style:{color:"#333333",fontWeight:400}},C.a.createElement("span",{style:{fontWeight:500}},"1、页面停留时长"),C.a.createElement("br",null),C.a.createElement("span",null,"学生进入关卡的答题页面开始计时,直至学生关卡评测通过,则计时结束;"),C.a.createElement("br",null),C.a.createElement("span",null," 学生进入关卡的答题页面开始计时,若学生关闭/退出答题页面,则计时暂停,再次进入答题页面时开始累计计时直至评测通过,则计时结束;"),C.a.createElement("span",{style:{color:"#FA6400",display:"flex",height:34,alignItems:"center"}}," 可能会造成时长评估与实际做题能力不符的情况 "),C.a.createElement("span",null,"a、学生进入关卡看完题后,退出答题页面完成代码设计,再复制进平台答题页面进行评测,无法评估学生的学习和思考时间。")),C.a.createElement("div",{style:{color:"#333333",marginTop:20,fontWeight:400}},C.a.createElement("span",{style:{fontWeight:500}},"2、关卡总耗时"),C.a.createElement("br",null),C.a.createElement("span",{style:{}},"学生第一次进入关卡答题页面开始计时,直至该关卡评测通过,则计时结束。 "),C.a.createElement("br",null),C.a.createElement("span",null," 另,即使关卡闯关过程中,学生退出/关闭答题页面,也将持续计时,直至该关卡通过。"),C.a.createElement("span",{style:{color:"#FA6400",display:"flex",height:44,paddingTop:10}}," 可能会造成时长评估与实际做题能力不符的情况 "),C.a.createElement("span",null,"a、学生从其他同学处看到题目后,完成代码设计,再进入关卡答题页面,将已完成的代码复制至平台进行评测;"),C.a.createElement("br",null),C.a.createElement("span",null,"b、学生第一次打开关卡后,因为某种原因离开页面,时隔多日才再次进入平台闯关,就会导致学生关卡总耗时过长;")),C.a.createElement("div",{style:{color:"#333333",marginTop:20,fontWeight:400}},C.a.createElement("span",{style:{fontWeight:500}},"3、即时通关时长"),C.a.createElement("br",null),C.a.createElement("span",{style:{}},"从老师发布的实训作业开始时间,开始计时,直至学生实训通关(包括迟交通关),结束计时。如果学生未通关,则该生的闯关耗时为老师设置的实训开始时间至实训截止时间,如果老师开启了补交,则该生的闯关耗时为实训开始时间至实训补交截止时间。")),C.a.createElement("div",{style:{color:"#333333",marginTop:20,fontWeight:400}},C.a.createElement("span",{style:{fontWeight:500}},"规则目的"),C.a.createElement("br",null),C.a.createElement("span",{style:{}},"鼓励学生在实训作业发布的第一时间,计时登录平台完成实训作业的通关。"))),C.a.createElement(ct.a,Object(i.a)({},Vt,{onClose:function(){zt(Object(g.a)(Object(g.a)({},Vt),{},{type:""}))}})),C.a.createElement(d.a,{visible:Nt,title:"实训总耗时说明",centered:!0,footer:null,onCancel:function(){Kt(!1)},width:600},C.a.createElement("div",{style:{fontWeight:400,color:"#333333"}},C.a.createElement("div",null,"1、当计时规则为“",C.a.createElement("span",{style:{color:"#145DFF"}},"页面停留时长"),"”时,实训总耗时为所有关卡耗时相加之和;"),C.a.createElement("div",{style:{margin:"20px 0px"}},"2、当计时规则为“",C.a.createElement("span",{style:{color:"#145DFF"}},"关卡总耗时"),"”时,实训总耗时为所有关卡耗时相加之和;"),C.a.createElement("div",null,"3、当计时规则为“",C.a.createElement("span",{style:{color:"#145DFF"}},"即时通关时长"),"”时,实训总耗时为实训发布时间至实训通关时间,当学生未通关时,实训总耗时为实训发布时间至实训截止时间。"))))}))},"6+eU":
|
|
|
/*!************************************************************!*\
|
|
|
!*** ./node_modules/rc-pagination/es/index.js + 4 modules ***!
|
|
|
\************************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createSuper.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/extends.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-pagination/es/locale/zh_CN.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r.d(e,"a",(function(){return x}));var n=r("wx14"),i=r("rePB"),o=r("VTBJ"),a=r("1OyB"),s=r("vuIU"),A=r("Ji7U"),l=r("LK+K"),c=r("q1tI"),u=r.n(c),h=r("TSYQ"),d=r.n(h),f=function(t){var e,r="".concat(t.rootPrefixCls,"-item"),n=d()(r,"".concat(r,"-").concat(t.page),(e={},Object(i.a)(e,"".concat(r,"-active"),t.active),Object(i.a)(e,t.className,!!t.className),Object(i.a)(e,"".concat(r,"-disabled"),!t.page),e));return u.a.createElement("li",{title:t.showTitle?t.page:null,className:n,onClick:function(){t.onClick(t.page)},onKeyPress:function(e){t.onKeyPress(e,t.onClick,t.page)},tabIndex:"0"},t.itemRender(t.page,"page",u.a.createElement("a",{rel:"nofollow"},t.page)))},p=13,g=38,m=40,v=function(t){Object(A.a)(r,t);var e=Object(l.a)(r);function r(){var t;Object(a.a)(this,r);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return(t=e.call.apply(e,[this].concat(i))).state={goInputText:""},t.buildOptionText=function(e){return"".concat(e," ").concat(t.props.locale.items_per_page)},t.changeSize=function(e){t.props.changeSize(Number(e))},t.handleChange=function(e){t.setState({goInputText:e.target.value})},t.handleBlur=function(e){var r=t.props,n=r.goButton,i=r.quickGo,o=r.rootPrefixCls,a=t.state.goInputText;n||""===a||e.relatedTarget&&(e.relatedTarget.className.indexOf("".concat(o,"-prev"))>=0||e.relatedTarget.className.indexOf("".concat(o,"-next"))>=0)||(t.setState({goInputText:""}),i(t.getValidValue()))},t.go=function(e){""!==t.state.goInputText&&(e.keyCode!==p&&"click"!==e.type||(t.setState({goInputText:""}),t.props.quickGo(t.getValidValue())))},t}return Object(s.a)(r,[{key:"getValidValue",value:function(){var t=this.state,e=t.goInputText,r=t.current;return!e||isNaN(e)?r:Number(e)}},{key:"getPageSizeOptions",value:function(){var t=this.props,e=t.pageSize,r=t.pageSizeOptions;return r.some((function(t){return t.toString()===e.toString()}))?r:r.concat([e.toString()]).sort((function(t,e){return(isNaN(Number(t))?0:Number(t))-(isNaN(Number(e))?0:Number(e))}))}},{key:"render",value:function(){var t=this,e=this.props,r=e.pageSize,n=e.locale,i=e.rootPrefixCls,o=e.changeSize,a=e.quickGo,s=e.goButton,A=e.selectComponentClass,l=e.buildOptionText,c=e.selectPrefixCls,h=e.disabled,d=this.state.goInputText,f="".concat(i,"-options"),p=A,g=null,m=null,v=null;if(!o&&!a)return null;var y=this.getPageSizeOptions();if(o&&p){var w=y.map((function(e,r){return u.a.createElement(p.Option,{key:r,value:e.toString()},(l||t.buildOptionText)(e))}));g=u.a.createElement(p,{disabled:h,prefixCls:c,showSearch:!1,className:"".concat(f,"-size-changer"),optionLabelProp:"children",dropdownMatchSelectWidth:!1,value:(r||y[0]).toString(),onChange:this.changeSize,getPopupContainer:function(t){return t.parentNode}},w)}return a&&(s&&(v="boolean"==typeof s?u.a.createElement("button",{type:"button",onClick:this.go,onKeyUp:this.go,disabled:h,className:"".concat(f,"-quick-jumper-button")},n.jump_to_confirm):u.a.createElement("span",{onClick:this.go,onKeyUp:this.go},s)),m=u.a.createElement("div",{className:"".concat(f,"-quick-jumper")},n.jump_to,u.a.createElement("input",{disabled:h,type:"text",value:d,onChange:this.handleChange,onKeyUp:this.go,onBlur:this.handleBlur}),n.page,v)),u.a.createElement("li",{className:"".concat(f)},g,m)}}]),r}(u.a.Component);v.defaultProps={pageSizeOptions:["10","20","50","100"]};var y=v,w=r("N2Kk");function b(){}function C(t,e,r){var n=void 0===t?e.pageSize:t;return Math.floor((r.total-1)/n)+1}var B=function(t){Object(A.a)(r,t);var e=Object(l.a)(r);function r(t){var n;Object(a.a)(this,r),(n=e.call(this,t)).getJumpPrevPage=function(){return Math.max(1,n.state.current-(n.props.showLessItems?3:5))},n.getJumpNextPage=function(){return Math.min(C(void 0,n.state,n.props),n.state.current+(n.props.showLessItems?3:5))},n.getItemIcon=function(t,e){var r=n.props.prefixCls,i=t||u.a.createElement("button",{type:"button","aria-label":e,className:"".concat(r,"-item-link")});return"function"==typeof t&&(i=u.a.createElement(t,Object(o.a)({},n.props))),i},n.savePaginationNode=function(t){n.paginationNode=t},n.isValid=function(t){return"number"==typeof(e=t)&&isFinite(e)&&Math.floor(e)===e&&t!==n.state.current;var e},n.shouldDisplayQuickJumper=function(){var t=n.props,e=t.showQuickJumper,r=t.pageSize;return!(t.total<=r)&&e},n.handleKeyDown=function(t){t.keyCode!==g&&t.keyCode!==m||t.preventDefault()},n.handleKeyUp=function(t){var e=n.getValidValue(t);e!==n.state.currentInputValue&&n.setState({currentInputValue:e}),t.keyCode===p?n.handleChange(e):t.keyCode===g?n.handleChange(e-1):t.keyCode===m&&n.handleChange(e+1)},n.changePageSize=function(t){var e=n.state.current,r=C(t,n.state,n.props);e=e>r?r:e,0===r&&(e=n.state.current),"number"==typeof t&&("pageSize"in n.props||n.setState({pageSize:t}),"current"in n.props||n.setState({current:e,currentInputValue:e})),n.props.onShowSizeChange(e,t),"onChange"in n.props&&n.props.onChange&&n.props.onChange(e,t)},n.handleChange=function(t){var e=n.props.disabled,r=t;if(n.isValid(r)&&!e){var i=C(void 0,n.state,n.props);r>i?r=i:r<1&&(r=1),"current"in n.props||n.setState({current:r,currentInputValue:r});var o=n.state.pageSize;return n.props.onChange(r,o),r}return n.state.current},n.prev=function(){n.hasPrev()&&n.handleChange(n.state.current-1)},n.next=function(){n.hasNext()&&n.handleChange(n.state.current+1)},n.jumpPrev=function(){n.handleChange(n.getJumpPrevPage())},n.jumpNext=function(){n.handleChange(n.getJumpNextPage())},n.hasPrev=function(){return n.state.current>1},n.hasNext=function(){return n.state.current<C(void 0,n.state,n.props)},n.runIfEnter=function(t,e){if("Enter"===t.key||13===t.charCode){for(var r=arguments.length,n=new Array(r>2?r-2:0),i=2;i<r;i++)n[i-2]=arguments[i];e.apply(void 0,n)}},n.runIfEnterPrev=function(t){n.runIfEnter(t,n.prev)},n.runIfEnterNext=function(t){n.runIfEnter(t,n.next)},n.runIfEnterJumpPrev=function(t){n.runIfEnter(t,n.jumpPrev)},n.runIfEnterJumpNext=function(t){n.runIfEnter(t,n.jumpNext)},n.handleGoTO=function(t){t.keyCode!==p&&"click"!==t.type||n.handleChange(n.state.currentInputValue)};var i=t.onChange!==b;"current"in t&&!i&&console.warn("Warning: You provided a `current` prop to a Pagination component without an `onChange` handler. This will render a read-only component.");var s=t.defaultCurrent;"current"in t&&(s=t.current);var A=t.defaultPageSize;return"pageSize"in t&&(A=t.pageSize),s=Math.min(s,C(A,void 0,t)),n.state={current:s,currentInputValue:s,pageSize:A},n}return Object(s.a)(r,[{key:"componentDidUpdate",value:function(t,e){var r=this.props.prefixCls;if(e.current!==this.state.current&&this.paginationNode){var n=this.paginationNode.querySelector(".".concat(r,"-item-").concat(e.current));n&&document.activeElement===n&&n.blur()}}},{key:"getValidValue",value:function(t){var e=t.target.value,r=C(void 0,this.state,this.props),n=this.state.currentInputValue;return""===e?e:isNaN(Number(e))?n:e>=r?r:Number(e)}},{key:"getShowSizeChanger",value:function(){var t=this.props,e=t.showSizeChanger,r=t.total,n=t.totalBoundaryShowSizeChanger;return void 0!==e?e:r>n}},{key:"renderPrev",value:function(t){var e=this.props,r=e.prevIcon,n=(0,e.itemRender)(t,"prev",this.getItemIcon(r,"prev page")),i=!this.hasPrev();return Object(c.isValidElement)(n)?Object(c.cloneElement)(n,{disabled:i}):n}},{key:"renderNext",value:function(t){var e=this.props,r=e.nextIcon,n=(0,e.itemRender)(t,"next",this.getItemIcon(r,"next page")),i=!this.hasNext();return Object(c.isValidElement)(n)?Object(c.cloneElement)(n,{disabled:i}):n}},{key:"render",value:function(){var t=this,e=this.props,r=e.prefixCls,o=e.className,a=e.style,s=e.disabled,A=e.hideOnSinglePage,l=e.total,h=e.locale,p=e.showQuickJumper,g=e.showLessItems,m=e.showTitle,v=e.showTotal,w=e.simple,b=e.itemRender,B=e.showPrevNextJumpers,x=e.jumpPrevIcon,E=e.jumpNextIcon,S=e.selectComponentClass,k=e.selectPrefixCls,T=e.pageSizeOptions,F=this.state,L=F.current,I=F.pageSize,_=F.currentInputValue;if(!0===A&&l<=I)return null;var U=C(void 0,this.state,this.props),O=[],D=null,Q=null,M=null,R=null,P=null,H=p&&p.goButton,N=g?1:2,K=L-1>0?L-1:0,j=L+1<U?L+1:U,G=Object.keys(this.props).reduce((function(e,r){return"data-"!==r.substr(0,5)&&"aria-"!==r.substr(0,5)&&"role"!==r||(e[r]=t.props[r]),e}),{});if(w)return H&&(P="boolean"==typeof H?u.a.createElement("button",{type:"button",onClick:this.handleGoTO,onKeyUp:this.handleGoTO},h.jump_to_confirm):u.a.createElement("span",{onClick:this.handleGoTO,onKeyUp:this.handleGoTO},H),P=u.a.createElement("li",{title:m?"".concat(h.jump_to).concat(L,"/").concat(U):null,className:"".concat(r,"-simple-pager")},P)),u.a.createElement("ul",Object(n.a)({className:d()(r,"".concat(r,"-simple"),Object(i.a)({},"".concat(r,"-disabled"),s),o),style:a,ref:this.savePaginationNode},G),u.a.createElement("li",{title:m?h.prev_page:null,onClick:this.prev,tabIndex:this.hasPrev()?0:null,onKeyPress:this.runIfEnterPrev,className:d()("".concat(r,"-prev"),Object(i.a)({},"".concat(r,"-disabled"),!this.hasPrev())),"aria-disabled":!this.hasPrev()},this.renderPrev(K)),u.a.createElement("li",{title:m?"".concat(L,"/").concat(U):null,className:"".concat(r,"-simple-pager")},u.a.createElement("input",{type:"text",value:_,disabled:s,onKeyDown:this.handleKeyDown,onKeyUp:this.handleKeyUp,onChange:this.handleKeyUp,size:"3"}),u.a.createElement("span",{className:"".concat(r,"-slash")},"/"),U),u.a.createElement("li",{title:m?h.next_page:null,onClick:this.next,tabIndex:this.hasPrev()?0:null,onKeyPress:this.runIfEnterNext,className:d()("".concat(r,"-next"),Object(i.a)({},"".concat(r,"-disabled"),!this.hasNext())),"aria-disabled":!this.hasNext()},this.renderNext(j)),P);if(U<=3+2*N){var V={locale:h,rootPrefixCls:r,onClick:this.handleChange,onKeyPress:this.runIfEnter,showTitle:m,itemRender:b};U||O.push(u.a.createElement(f,Object(n.a)({},V,{key:"noPager",page:U,className:"".concat(r,"-disabled")})));for(var z=1;z<=U;z+=1){var W=L===z;O.push(u.a.createElement(f,Object(n.a)({},V,{key:z,page:z,active:W})))}}else{var Y=g?h.prev_3:h.prev_5,X=g?h.next_3:h.next_5;B&&(D=u.a.createElement("li",{title:m?Y:null,key:"prev",onClick:this.jumpPrev,tabIndex:"0",onKeyPress:this.runIfEnterJumpPrev,className:d()("".concat(r,"-jump-prev"),Object(i.a)({},"".concat(r,"-jump-prev-custom-icon"),!!x))},b(this.getJumpPrevPage(),"jump-prev",this.getItemIcon(x,"prev page"))),Q=u.a.createElement("li",{title:m?X:null,key:"next",tabIndex:"0",onClick:this.jumpNext,onKeyPress:this.runIfEnterJumpNext,className:d()("".concat(r,"-jump-next"),Object(i.a)({},"".concat(r,"-jump-next-custom-icon"),!!E))},b(this.getJumpNextPage(),"jump-next",this.getItemIcon(E,"next page")))),R=u.a.createElement(f,{locale:h,last:!0,rootPrefixCls:r,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:U,page:U,active:!1,showTitle:m,itemRender:b}),M=u.a.createElement(f,{locale:h,rootPrefixCls:r,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:1,page:1,active:!1,showTitle:m,itemRender:b});var q=Math.max(1,L-N),J=Math.min(L+N,U);L-1<=N&&(J=1+2*N),U-L<=N&&(q=U-2*N);for(var Z=q;Z<=J;Z+=1){var $=L===Z;O.push(u.a.createElement(f,{locale:h,rootPrefixCls:r,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:Z,page:Z,active:$,showTitle:m,itemRender:b}))}L-1>=2*N&&3!==L&&(O[0]=Object(c.cloneElement)(O[0],{className:"".concat(r,"-item-after-jump-prev")}),O.unshift(D)),U-L>=2*N&&L!==U-2&&(O[O.length-1]=Object(c.cloneElement)(O[O.length-1],{className:"".concat(r,"-item-before-jump-next")}),O.push(Q)),1!==q&&O.unshift(M),J!==U&&O.push(R)}var tt=null;v&&(tt=u.a.createElement("li",{className:"".concat(r,"-total-text")},v(l,[0===l?0:(L-1)*I+1,L*I>l?l:L*I])));var et=!this.hasPrev()||!U,rt=!this.hasNext()||!U;return u.a.createElement("ul",Object(n.a)({className:d()(r,o,Object(i.a)({},"".concat(r,"-disabled"),s)),style:a,unselectable:"unselectable",ref:this.savePaginationNode},G),tt,u.a.createElement("li",{title:m?h.prev_page:null,onClick:this.prev,tabIndex:et?null:0,onKeyPress:this.runIfEnterPrev,className:d()("".concat(r,"-prev"),Object(i.a)({},"".concat(r,"-disabled"),et)),"aria-disabled":et},this.renderPrev(K)),O,u.a.createElement("li",{title:m?h.next_page:null,onClick:this.next,tabIndex:rt?null:0,onKeyPress:this.runIfEnterNext,className:d()("".concat(r,"-next"),Object(i.a)({},"".concat(r,"-disabled"),rt)),"aria-disabled":rt},this.renderNext(j)),u.a.createElement(y,{disabled:s,locale:h,rootPrefixCls:r,selectComponentClass:S,selectPrefixCls:k,changeSize:this.getShowSizeChanger()?this.changePageSize:null,current:L,pageSize:I,pageSizeOptions:T,quickGo:this.shouldDisplayQuickJumper()?this.handleChange:null,goButton:H}))}}],[{key:"getDerivedStateFromProps",value:function(t,e){var r={};if("current"in t&&(r.current=t.current,t.current!==e.current&&(r.currentInputValue=r.current)),"pageSize"in t&&t.pageSize!==e.pageSize){var n=e.current,i=C(t.pageSize,e,t);n=n>i?i:n,"current"in t||(r.current=n,r.currentInputValue=n),r.pageSize=t.pageSize}return r}}]),r}(u.a.Component);B.defaultProps={defaultCurrent:1,total:0,defaultPageSize:10,onChange:b,className:"",selectPrefixCls:"rc-select",prefixCls:"rc-pagination",selectComponentClass:null,hideOnSinglePage:!1,showPrevNextJumpers:!0,showQuickJumper:!1,showLessItems:!1,showTitle:!0,onShowSizeChange:b,locale:w.a,style:{},itemRender:function(t,e,r){return r},totalBoundaryShowSizeChanger:50};var x=B},"6GrX":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/text.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/BoundingRect */"mFDi"),i=r(/*! ../graphic/helper/image */"Xnb7"),o=r(/*! ../core/util */"bYtY"),a=o.getContext,s=o.extend,A=o.retrieve2,l=o.retrieve3,c=o.trim,u={},h=0,d=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g,f={};function p(t,e){var r=t+":"+(e=e||"12px sans-serif");if(u[r])return u[r];for(var n=(t+"").split("\n"),i=0,o=0,a=n.length;o<a;o++)i=Math.max(x(n[o],e).width,i);return h>5e3&&(h=0,u={}),h++,u[r]=i,i}function g(t,e,r){return"right"===r?t-=e:"center"===r&&(t-=e/2),t}function m(t,e,r){return"middle"===r?t-=e/2:"bottom"===r&&(t-=e),t}function v(t,e,r){var n=e.textPosition,i=e.textDistance,o=r.x,a=r.y;i=i||0;var s=r.height,A=r.width,l=s/2,c="left",u="top";switch(n){case"left":o-=i,a+=l,c="right",u="middle";break;case"right":o+=i+A,a+=l,u="middle";break;case"top":o+=A/2,a-=i,c="center",u="bottom";break;case"bottom":o+=A/2,a+=s+i,c="center";break;case"inside":o+=A/2,a+=l,c="center",u="middle";break;case"insideLeft":o+=i,a+=l,u="middle";break;case"insideRight":o+=A-i,a+=l,c="right",u="middle";break;case"insideTop":o+=A/2,a+=i,c="center";break;case"insideBottom":o+=A/2,a+=s-i,c="center",u="bottom";break;case"insideTopLeft":o+=i,a+=i;break;case"insideTopRight":o+=A-i,a+=i,c="right";break;case"insideBottomLeft":o+=i,a+=s-i,u="bottom";break;case"insideBottomRight":o+=A-i,a+=s-i,c="right",u="bottom"}return(t=t||{}).x=o,t.y=a,t.textAlign=c,t.textVerticalAlign=u,t}function y(t,e,r,n,i){if(!e)return"";var o=(t+"").split("\n");i=w(e,r,n,i);for(var a=0,s=o.length;a<s;a++)o[a]=b(o[a],i);return o.join("\n")}function w(t,e,r,n){(n=s({},n)).font=e;r=A(r,"...");n.maxIterations=A(n.maxIterations,2);var i=n.minChar=A(n.minChar,0);n.cnCharWidth=p("国",e);var o=n.ascCharWidth=p("a",e);n.placeholder=A(n.placeholder,"");for(var a=t=Math.max(0,t-1),l=0;l<i&&a>=o;l++)a-=o;var c=p(r,e);return c>a&&(r="",c=0),a=t-c,n.ellipsis=r,n.ellipsisWidth=c,n.contentWidth=a,n.containerWidth=t,n}function b(t,e){var r=e.containerWidth,n=e.font,i=e.contentWidth;if(!r)return"";var o=p(t,n);if(o<=r)return t;for(var a=0;;a++){if(o<=i||a>=e.maxIterations){t+=e.ellipsis;break}var s=0===a?C(t,i,e.ascCharWidth,e.cnCharWidth):o>0?Math.floor(t.length*i/o):0;o=p(t=t.substr(0,s),n)}return""===t&&(t=e.placeholder),t}function C(t,e,r,n){for(var i=0,o=0,a=t.length;o<a&&i<e;o++){var s=t.charCodeAt(o);i+=0<=s&&s<=127?r:n}return o}function B(t){return p("国",t)}function x(t,e){return f.measureText(t,e)}function E(t,e,r,n,i){null!=t&&(t+="");var o=A(n,B(e)),a=t?t.split("\n"):[],s=a.length*o,l=s,c=!0;if(r&&(l+=r[0]+r[2]),t&&i){c=!1;var u=i.outerHeight,h=i.outerWidth;if(null!=u&&l>u)t="",a=[];else if(null!=h)for(var d=w(h-(r?r[1]+r[3]:0),e,i.ellipsis,{minChar:i.minChar,placeholder:i.placeholder}),f=0,p=a.length;f<p;f++)a[f]=b(a[f],d)}return{lines:a,height:s,outerHeight:l,lineHeight:o,canCacheByTextString:c}}function S(t,e){var r={lines:[],width:0,height:0};if(null!=t&&(t+=""),!t)return r;for(var n,o=d.lastIndex=0;null!=(n=d.exec(t));){var a=n.index;a>o&&k(r,t.substring(o,a)),k(r,n[2],n[1]),o=d.lastIndex}o<t.length&&k(r,t.substring(o,t.length));var s=r.lines,c=0,u=0,h=[],f=e.textPadding,g=e.truncate,m=g&&g.outerWidth,v=g&&g.outerHeight;f&&(null!=m&&(m-=f[1]+f[3]),null!=v&&(v-=f[0]+f[2]));for(var w=0;w<s.length;w++){for(var b=s[w],C=0,x=0,E=0;E<b.tokens.length;E++){var S=(M=b.tokens[E]).styleName&&e.rich[M.styleName]||{},T=M.textPadding=S.textPadding,F=M.font=S.font||e.font,L=M.textHeight=A(S.textHeight,B(F));if(T&&(L+=T[0]+T[2]),M.height=L,M.lineHeight=l(S.textLineHeight,e.textLineHeight,L),M.textAlign=S&&S.textAlign||e.textAlign,M.textVerticalAlign=S&&S.textVerticalAlign||"middle",null!=v&&c+M.lineHeight>v)return{lines:[],width:0,height:0};M.textWidth=p(M.text,F);var I=S.textWidth,_=null==I||"auto"===I;if("string"==typeof I&&"%"===I.charAt(I.length-1))M.percentWidth=I,h.push(M),I=0;else{if(_){I=M.textWidth;var U=S.textBackgroundColor,O=U&&U.image;O&&(O=i.findExistImage(O),i.isImageReady(O)&&(I=Math.max(I,O.width*L/O.height)))}var D=T?T[1]+T[3]:0;I+=D;var Q=null!=m?m-x:null;null!=Q&&Q<I&&(!_||Q<D?(M.text="",M.textWidth=I=0):(M.text=y(M.text,Q-D,F,g.ellipsis,{minChar:g.minChar}),M.textWidth=p(M.text,F),I=M.textWidth+D))}x+=M.width=I,S&&(C=Math.max(C,M.lineHeight))}b.width=x,b.lineHeight=C,c+=C,u=Math.max(u,x)}r.outerWidth=r.width=A(e.textWidth,u),r.outerHeight=r.height=A(e.textHeight,c),f&&(r.outerWidth+=f[1]+f[3],r.outerHeight+=f[0]+f[2]);for(w=0;w<h.length;w++){var M,R=(M=h[w]).percentWidth;M.width=parseInt(R,10)/100*u}return r}function k(t,e,r){for(var n=""===e,i=e.split("\n"),o=t.lines,a=0;a<i.length;a++){var s=i[a],A={styleName:r,text:s,isLineHolder:!s&&!n};if(a)o.push({tokens:[A]});else{var l=(o[o.length-1]||(o[0]={tokens:[]})).tokens,c=l.length;1===c&&l[0].isLineHolder?l[0]=A:(s||!c||n)&&l.push(A)}}}f.measureText=function(t,e){var r=a();return r.font=e||"12px sans-serif",r.measureText(t)},e.DEFAULT_FONT="12px sans-serif",e.$override=function(t,e){f[t]=e},e.getWidth=p,e.getBoundingRect=function(t,e,r,i,o,a,s,A){return s?function(t,e,r,i,o,a,s,A){var l=S(t,{rich:s,truncate:A,font:e,textAlign:r,textPadding:o,textLineHeight:a}),c=l.outerWidth,u=l.outerHeight,h=g(0,c,r),d=m(0,u,i);return new n(h,d,c,u)}(t,e,r,i,o,a,s,A):function(t,e,r,i,o,a,s){var A=E(t,e,o,a,s),l=p(t,e);o&&(l+=o[1]+o[3]);var c=A.outerHeight,u=g(0,l,r),h=m(0,c,i),d=new n(u,h,l,c);return d.lineHeight=A.lineHeight,d}(t,e,r,i,o,a,A)},e.adjustTextX=g,e.adjustTextY=m,e.calculateTextPosition=v,e.adjustTextPositionOnRect=function(t,e,r){return v({},{textPosition:t,textDistance:r},e)},e.truncateText=y,e.getLineHeight=B,e.measureText=x,e.parsePlainText=E,e.parseRichText=S,e.makeFont=function(t){var e=(t.fontSize||t.fontFamily)&&[t.fontStyle,t.fontWeight,(t.fontSize||12)+"px",t.fontFamily||"sans-serif"].join(" ");return e&&c(e)||t.textFont||t.font}},"6RRn":
|
|
|
/*!*******************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/index.js ***!
|
|
|
\*******************************************/
|
|
|
/*! exports provided: Summary, Column, ColumnGroup, INTERNAL_COL_DEFINE, default */
|
|
|
/*! exports used: INTERNAL_COL_DEFINE, Summary, default */function(t,e,r){"use strict";var n=r(/*! ./Table */"wCXF"),i=r(/*! ./Footer */"n6Qo");r.d(e,"b",(function(){return i.a}));r(/*! ./sugar/Column */"IBYe"),r(/*! ./sugar/ColumnGroup */"6eGT");var o=r(/*! ./utils/legacyUtil */"hW8S");r.d(e,"a",(function(){return o.a})),e.c=n.b},"6eGT":
|
|
|
/*!*******************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/sugar/ColumnGroup.js ***!
|
|
|
\*******************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";e.a=function(t){return null}},"6fms":
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/vml/Painter.js ***!
|
|
|
\*************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/log */"SUKs"),i=r(/*! ./core */"06Qe"),o=r(/*! ../core/util */"bYtY").each;function a(t){return parseInt(t,10)}function s(t,e){i.initVML(),this.root=t,this.storage=e;var r=document.createElement("div"),n=document.createElement("div");r.style.cssText="display:inline-block;overflow:hidden;position:relative;width:300px;height:150px;",n.style.cssText="position:absolute;left:0;top:0;",t.appendChild(r),this._vmlRoot=n,this._vmlViewport=r,this.resize();var o=e.delFromStorage,a=e.addToStorage;e.delFromStorage=function(t){o.call(e,t),t&&t.onRemove&&t.onRemove(n)},e.addToStorage=function(t){t.onAdd&&t.onAdd(n),a.call(e,t)},this._firstPaint=!0}s.prototype={constructor:s,getType:function(){return"vml"},getViewportRoot:function(){return this._vmlViewport},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(){var t=this.storage.getDisplayList(!0,!0);this._paintList(t)},_paintList:function(t){for(var e=this._vmlRoot,r=0;r<t.length;r++){var n=t[r];n.invisible||n.ignore?(n.__alreadyNotVisible||n.onRemove(e),n.__alreadyNotVisible=!0):(n.__alreadyNotVisible&&n.onAdd(e),n.__alreadyNotVisible=!1,n.__dirty&&(n.beforeBrush&&n.beforeBrush(),(n.brushVML||n.brush).call(n,e),n.afterBrush&&n.afterBrush())),n.__dirty=!1}this._firstPaint&&(this._vmlViewport.appendChild(e),this._firstPaint=!1)},resize:function(t,e){t=null==t?this._getWidth():t,e=null==e?this._getHeight():e;if(this._width!==t||this._height!==e){this._width=t,this._height=e;var r=this._vmlViewport.style;r.width=t+"px",r.height=e+"px"}},dispose:function(){this.root.innerHTML="",this._vmlRoot=this._vmlViewport=this.storage=null},getWidth:function(){return this._width},getHeight:function(){return this._height},clear:function(){this._vmlViewport&&this.root.removeChild(this._vmlViewport)},_getWidth:function(){var t=this.root,e=t.currentStyle;return(t.clientWidth||a(e.width))-a(e.paddingLeft)-a(e.paddingRight)|0},_getHeight:function(){var t=this.root,e=t.currentStyle;return(t.clientHeight||a(e.height))-a(e.paddingTop)-a(e.paddingBottom)|0}},o(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","toDataURL","pathToImage"],(function(t){var e;s.prototype[t]=(e=t,function(){n('In IE8.0 VML mode painter not support method "'+e+'"')})}));var A=s;t.exports=A},"7Cbv":
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./node_modules/uuid/dist/esm-browser/v4.js + 4 modules ***!
|
|
|
\**************************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";var n="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto),i=new Uint8Array(16);function o(){if(!n)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return n(i)}var a=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;for(var s=function(t){return"string"==typeof t&&a.test(t)},A=[],l=0;l<256;++l)A.push((l+256).toString(16).substr(1));var c=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=(A[t[e+0]]+A[t[e+1]]+A[t[e+2]]+A[t[e+3]]+"-"+A[t[e+4]]+A[t[e+5]]+"-"+A[t[e+6]]+A[t[e+7]]+"-"+A[t[e+8]]+A[t[e+9]]+"-"+A[t[e+10]]+A[t[e+11]]+A[t[e+12]]+A[t[e+13]]+A[t[e+14]]+A[t[e+15]]).toLowerCase();if(!s(r))throw TypeError("Stringified UUID is invalid");return r};e.a=function(t,e,r){var n=(t=t||{}).random||(t.rng||o)();if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,e){r=r||0;for(var i=0;i<16;++i)e[r+i]=n[i];return e}return c(n)}},"7SHv":
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/Painter.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./config */"LPTA").devicePixelRatio,i=r(/*! ./core/util */"bYtY"),o=r(/*! ./core/log */"SUKs"),a=r(/*! ./core/BoundingRect */"mFDi"),s=r(/*! ./core/timsort */"BPZU"),A=r(/*! ./Layer */"Xmg4"),l=r(/*! ./animation/requestAnimationFrame */"mLcG"),c=r(/*! ./graphic/Image */"Dagg"),u=r(/*! ./core/env */"ItGF");function h(t){return parseInt(t,10)}var d=new a(0,0,0,0),f=new a(0,0,0,0);var p=function(t,e,r){this.type="canvas";var o=!t.nodeName||"CANVAS"===t.nodeName.toUpperCase();this._opts=r=i.extend({},r||{}),this.dpr=r.devicePixelRatio||n,this._singleCanvas=o,this.root=t;var a=t.style;a&&(a["-webkit-tap-highlight-color"]="transparent",a["-webkit-user-select"]=a["user-select"]=a["-webkit-touch-callout"]="none",t.innerHTML=""),this.storage=e;var s=this._zlevelList=[],l=this._layers={};if(this._layerConfig={},this._needsManuallyCompositing=!1,o){var c=t.width,u=t.height;null!=r.width&&(c=r.width),null!=r.height&&(u=r.height),this.dpr=r.devicePixelRatio||1,t.width=c*this.dpr,t.height=u*this.dpr,this._width=c,this._height=u;var h=new A(t,this,this.dpr);h.__builtin__=!0,h.initContext(),l[314159]=h,h.zlevel=314159,s.push(314159),this._domRoot=t}else{this._width=this._getSize(0),this._height=this._getSize(1);var d=this._domRoot=function(t,e){var r=document.createElement("div");return r.style.cssText=["position:relative","width:"+t+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",r}(this._width,this._height);t.appendChild(d)}this._hoverlayer=null,this._hoverElements=[]};p.prototype={constructor:p,getType:function(){return"canvas"},isSingleCanvas:function(){return this._singleCanvas},getViewportRoot:function(){return this._domRoot},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(t){var e=this.storage.getDisplayList(!0),r=this._zlevelList;this._redrawId=Math.random(),this._paintList(e,t,this._redrawId);for(var n=0;n<r.length;n++){var i=r[n],o=this._layers[i];if(!o.__builtin__&&o.refresh){var a=0===n?this._backgroundColor:null;o.refresh(a)}}return this.refreshHover(),this},addHover:function(t,e){if(!t.__hoverMir){var r=new t.constructor({style:t.style,shape:t.shape,z:t.z,z2:t.z2,silent:t.silent});return r.__from=t,t.__hoverMir=r,e&&r.setStyle(e),this._hoverElements.push(r),r}},removeHover:function(t){var e=t.__hoverMir,r=this._hoverElements,n=i.indexOf(r,e);n>=0&&r.splice(n,1),t.__hoverMir=null},clearHover:function(t){for(var e=this._hoverElements,r=0;r<e.length;r++){var n=e[r].__from;n&&(n.__hoverMir=null)}e.length=0},refreshHover:function(){var t=this._hoverElements,e=t.length,r=this._hoverlayer;if(r&&r.clear(),e){s(t,this.storage.displayableSortFunc),r||(r=this._hoverlayer=this.getLayer(1e5));var n={};r.ctx.save();for(var i=0;i<e;){var o=t[i],a=o.__from;a&&a.__zr?(i++,a.invisible||(o.transform=a.transform,o.invTransform=a.invTransform,o.__clipPaths=a.__clipPaths,this._doPaintEl(o,r,!0,n))):(t.splice(i,1),a.__hoverMir=null,e--)}r.ctx.restore()}},getHoverLayer:function(){return this.getLayer(1e5)},_paintList:function(t,e,r){if(this._redrawId===r){e=e||!1,this._updateLayerStatus(t);var n=this._doPaintList(t,e);if(this._needsManuallyCompositing&&this._compositeManually(),!n){var i=this;l((function(){i._paintList(t,e,r)}))}}},_compositeManually:function(){var t=this.getLayer(314159).ctx,e=this._domRoot.width,r=this._domRoot.height;t.clearRect(0,0,e,r),this.eachBuiltinLayer((function(n){n.virtual&&t.drawImage(n.dom,0,0,e,r)}))},_doPaintList:function(t,e){for(var r=[],n=0;n<this._zlevelList.length;n++){var o=this._zlevelList[n];(A=this._layers[o]).__builtin__&&A!==this._hoverlayer&&(A.__dirty||e)&&r.push(A)}for(var a=!0,s=0;s<r.length;s++){var A,l=(A=r[s]).ctx,c={};l.save();var h=e?A.__startIndex:A.__drawIndex,d=!e&&A.incremental&&Date.now,f=d&&Date.now(),p=A.zlevel===this._zlevelList[0]?this._backgroundColor:null;if(A.__startIndex===A.__endIndex)A.clear(!1,p);else if(h===A.__startIndex){var g=t[h];g.incremental&&g.notClear&&!e||A.clear(!1,p)}-1===h&&(console.error("For some unknown reason. drawIndex is -1"),h=A.__startIndex);for(var m=h;m<A.__endIndex;m++){var v=t[m];if(this._doPaintEl(v,A,e,c),v.__dirty=v.__dirtyText=!1,d)if(Date.now()-f>15)break}A.__drawIndex=m,A.__drawIndex<A.__endIndex&&(a=!1),c.prevElClipPaths&&l.restore(),l.restore()}return u.wxa&&i.each(this._layers,(function(t){t&&t.ctx&&t.ctx.draw&&t.ctx.draw()})),a},_doPaintEl:function(t,e,r,n){var i=e.ctx,o=t.transform;if((e.__dirty||r)&&!t.invisible&&0!==t.style.opacity&&(!o||o[0]||o[3])&&(!t.culling||!function(t,e,r){return d.copy(t.getBoundingRect()),t.transform&&d.applyTransform(t.transform),f.width=e,f.height=r,!d.intersect(f)}(t,this._width,this._height))){var a=t.__clipPaths,s=n.prevElClipPaths;s&&!function(t,e){if(t===e)return!1;if(!t||!e||t.length!==e.length)return!0;for(var r=0;r<t.length;r++)if(t[r]!==e[r])return!0;return!1}(a,s)||(s&&(i.restore(),n.prevElClipPaths=null,n.prevEl=null),a&&(i.save(),function(t,e){for(var r=0;r<t.length;r++){var n=t[r];n.setTransform(e),e.beginPath(),n.buildPath(e,n.shape),e.clip(),n.restoreTransform(e)}}(a,i),n.prevElClipPaths=a)),t.beforeBrush&&t.beforeBrush(i),t.brush(i,n.prevEl||null),n.prevEl=t,t.afterBrush&&t.afterBrush(i)}},getLayer:function(t,e){this._singleCanvas&&!this._needsManuallyCompositing&&(t=314159);var r=this._layers[t];return r||((r=new A("zr_"+t,this,this.dpr)).zlevel=t,r.__builtin__=!0,this._layerConfig[t]?i.merge(r,this._layerConfig[t],!0):this._layerConfig[t-.01]&&i.merge(r,this._layerConfig[t-.01],!0),e&&(r.virtual=e),this.insertLayer(t,r),r.initContext()),r},insertLayer:function(t,e){var r=this._layers,n=this._zlevelList,i=n.length,a=null,s=-1,A=this._domRoot;if(r[t])o("ZLevel "+t+" has been used already");else if(function(t){return!!t&&(!!t.__builtin__||"function"==typeof t.resize&&"function"==typeof t.refresh)}(e)){if(i>0&&t>n[0]){for(s=0;s<i-1&&!(n[s]<t&&n[s+1]>t);s++);a=r[n[s]]}if(n.splice(s+1,0,t),r[t]=e,!e.virtual)if(a){var l=a.dom;l.nextSibling?A.insertBefore(e.dom,l.nextSibling):A.appendChild(e.dom)}else A.firstChild?A.insertBefore(e.dom,A.firstChild):A.appendChild(e.dom)}else o("Layer of zlevel "+t+" is not valid")},eachLayer:function(t,e){var r,n,i=this._zlevelList;for(n=0;n<i.length;n++)r=i[n],t.call(e,this._layers[r],r)},eachBuiltinLayer:function(t,e){var r,n,i,o=this._zlevelList;for(i=0;i<o.length;i++)n=o[i],(r=this._layers[n]).__builtin__&&t.call(e,r,n)},eachOtherLayer:function(t,e){var r,n,i,o=this._zlevelList;for(i=0;i<o.length;i++)n=o[i],(r=this._layers[n]).__builtin__||t.call(e,r,n)},getLayers:function(){return this._layers},_updateLayerStatus:function(t){function e(t){i&&(i.__endIndex!==t&&(i.__dirty=!0),i.__endIndex=t)}if(this.eachBuiltinLayer((function(t,e){t.__dirty=t.__used=!1})),this._singleCanvas)for(var r=1;r<t.length;r++){if((s=t[r]).zlevel!==t[r-1].zlevel||s.incremental){this._needsManuallyCompositing=!0;break}}var n,i=null,a=0;for(r=0;r<t.length;r++){var s,A,l=(s=t[r]).zlevel;n!==l&&(n=l,a=0),s.incremental?((A=this.getLayer(l+.001,this._needsManuallyCompositing)).incremental=!0,a=1):A=this.getLayer(l+(a>0?.01:0),this._needsManuallyCompositing),A.__builtin__||o("ZLevel "+l+" has been used by unkown layer "+A.id),A!==i&&(A.__used=!0,A.__startIndex!==r&&(A.__dirty=!0),A.__startIndex=r,A.incremental?A.__drawIndex=-1:A.__drawIndex=r,e(r),i=A),s.__dirty&&(A.__dirty=!0,A.incremental&&A.__drawIndex<0&&(A.__drawIndex=r))}e(r),this.eachBuiltinLayer((function(t,e){!t.__used&&t.getElementCount()>0&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)}))},clear:function(){return this.eachBuiltinLayer(this._clearLayer),this},_clearLayer:function(t){t.clear()},setBackgroundColor:function(t){this._backgroundColor=t},configLayer:function(t,e){if(e){var r=this._layerConfig;r[t]?i.merge(r[t],e,!0):r[t]=e;for(var n=0;n<this._zlevelList.length;n++){var o=this._zlevelList[n];if(o===t||o===t+.01){var a=this._layers[o];i.merge(a,r[t],!0)}}}},delLayer:function(t){var e=this._layers,r=this._zlevelList,n=e[t];n&&(n.dom.parentNode.removeChild(n.dom),delete e[t],r.splice(i.indexOf(r,t),1))},resize:function(t,e){if(this._domRoot.style){var r=this._domRoot;r.style.display="none";var n=this._opts;if(null!=t&&(n.width=t),null!=e&&(n.height=e),t=this._getSize(0),e=this._getSize(1),r.style.display="",this._width!==t||e!==this._height){for(var o in r.style.width=t+"px",r.style.height=e+"px",this._layers)this._layers.hasOwnProperty(o)&&this._layers[o].resize(t,e);i.each(this._progressiveLayers,(function(r){r.resize(t,e)})),this.refresh(!0)}this._width=t,this._height=e}else{if(null==t||null==e)return;this._width=t,this._height=e,this.getLayer(314159).resize(t,e)}return this},clearLayer:function(t){var e=this._layers[t];e&&e.clear()},dispose:function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},getRenderedCanvas:function(t){if(t=t||{},this._singleCanvas&&!this._compositeManually)return this._layers[314159].dom;var e=new A("image",this,t.pixelRatio||this.dpr);if(e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor),t.pixelRatio<=this.dpr){this.refresh();var r=e.dom.width,n=e.dom.height,i=e.ctx;this.eachLayer((function(t){t.__builtin__?i.drawImage(t.dom,0,0,r,n):t.renderToCanvas&&(e.ctx.save(),t.renderToCanvas(e.ctx),e.ctx.restore())}))}else for(var o={},a=this.storage.getDisplayList(!0),s=0;s<a.length;s++){var l=a[s];this._doPaintEl(l,e,!0,o)}return e.dom},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,r=["width","height"][t],n=["clientWidth","clientHeight"][t],i=["paddingLeft","paddingTop"][t],o=["paddingRight","paddingBottom"][t];if(null!=e[r]&&"auto"!==e[r])return parseFloat(e[r]);var a=this.root,s=document.defaultView.getComputedStyle(a);return(a[n]||h(s[r])||h(a.style[r]))-(h(s[i])||0)-(h(s[o])||0)|0},pathToImage:function(t,e){e=e||this.dpr;var r=document.createElement("canvas"),n=r.getContext("2d"),i=t.getBoundingRect(),o=t.style,a=o.shadowBlur*e,s=o.shadowOffsetX*e,A=o.shadowOffsetY*e,l=o.hasStroke()?o.lineWidth:0,u=Math.max(l/2,-s+a),h=Math.max(l/2,s+a),d=Math.max(l/2,-A+a),f=Math.max(l/2,A+a),p=i.width+u+h,g=i.height+d+f;r.width=p*e,r.height=g*e,n.scale(e,e),n.clearRect(0,0,p,g),n.dpr=e;var m={position:t.position,rotation:t.rotation,scale:t.scale};t.position=[u-i.x,d-i.y],t.rotation=0,t.scale=[1,1],t.updateTransform(),t&&t.brush(n);var v=new c({style:{x:0,y:0,image:r}});return null!=m.position&&(v.position=t.position=m.position),null!=m.rotation&&(v.rotation=t.rotation=m.rotation),null!=m.scale&&(v.scale=t.scale=m.scale),v}};var g=p;t.exports=g},"7ahc":
|
|
|
/*!*************************************************************!*\
|
|
|
!*** ./src/components/markdown-editor/code-block/index.tsx ***!
|
|
|
\*************************************************************/
|
|
|
/*! exports provided: default, MyCodeMirror */
|
|
|
/*! exports used: MyCodeMirror, default */function(t,e,r){"use strict";r.d(e,"a",(function(){return g}));var n=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2 */"k1fw"),i=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/extends */"0Owb"),o=(r(/*! antd/es/button/style */"+L6B"),r(/*! antd/es/button */"2/Rp")),a=(r(/*! antd/es/form/style */"y8nQ"),r(/*! antd/es/form */"Vl3Y")),s=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray */"tJVT"),A=(r(/*! antd/es/select/style */"OaEy"),r(/*! antd/es/select */"2fM7")),l=r(/*! react */"q1tI"),c=r.n(l),u=r(/*! codemirror */"VrN/"),h=r.n(u),d=(r(/*! codemirror/lib/codemirror.css */"p77/"),r(/*! codemirror/theme/blackboard.css */"c5Ni"),A.a.Option),f={labelCol:{span:4},wrapperCol:{span:20}},p={asp:["ASP","vbscript"],actionscript:["ActionScript(3.0)/Flash/Flex","clike"],bash:["Bash/Bat","shell"],css:["CSS","css"],c:["C","clike"],cpp:["C++","clike"],csharp:["C#","clike"],coffeescript:["CoffeeScript","coffeescript"],d:["D","d"],dart:["Dart","dart"],delphi:["Delphi/Pascal","pascal"],erlang:["Erlang","erlang"],go:["Golang","go"],groovy:["Groovy","groovy"],html:["HTML","text/html"],java:["Java","clike"],json:["JSON","text/json"],javascript:["Javascript","javascript"],lua:["Lua","lua"],less:["LESS","css"],markdown:["Markdown","gfm"],"objective-c":["Objective-C","clike"],php:["PHP","php"],perl:["Perl","perl"],python:["Python","python"],r:["R","r"],rst:["reStructedText","rst"],ruby:["Ruby","ruby"],sql:["SQL","sql"],sass:["SASS/SCSS","sass"],shell:["Shell","shell"],scala:["Scala","clike"],swift:["Swift","clike"],vb:["VB/VBScript","vb"],xml:["XML","text/xml"],yaml:["YAML","yaml"]};function g(t){var e=t.value,r=t.onChange,i=t.mode,o=t.options,a=void 0===o?{}:o,A=Object(l.useRef)(),u=Object(l.useState)(),d=Object(s.a)(u,2),f=d[0],p=d[1];return Object(l.useEffect)((function(){if(f){function t(t){var e=t.getValue();r&&r(e)}return f.on("change",t),function(){f.off("change",t)}}}),[f,r]),Object(l.useEffect)((function(){f&&f.setOption("mode",i)}),[f,i]),Object(l.useEffect)((function(){f&&(e===f.getValue()&&""!==e||setTimeout((function(){f.setValue(e||" ")}),300))}),[f,e]),Object(l.useEffect)((function(){if(A.current&&!f){var t=h.a.fromTextArea(A.current,Object(n.a)({mode:i,lineNumbers:!0,lineWrapping:!0,autoCloseBrackets:!0,tabSize:4,autofocus:!0,autoCloseTags:!0,matchBrackets:!0,styleActiveLine:!0},a));p(t)}}),[A.current,f]),c.a.createElement("div",{className:"my-codemirror-container"},c.a.createElement("textarea",{ref:A}))}e.b=function(t){var e=t.callback,r=t.onCancel,n=Object(l.useState)("python"),u=Object(s.a)(n,2),h=u[0],m=u[1];return c.a.createElement(a.a,Object(i.a)({},f,{className:"code-block-panel",initialValues:{language:"python",content:""},onFinish:function(t){e(t)}}),c.a.createElement(a.a.Item,{label:"代码语言",name:"language"},c.a.createElement(A.a,{onChange:function(t){m(p[t][1])}},Object.keys(p).map((function(t){return c.a.createElement(d,{key:t,value:t},p[t][0])})))),c.a.createElement(a.a.Item,{label:"代码内容",name:"content",rules:[{required:!0,message:"请输入代码内容"}]},c.a.createElement(g,{mode:h})),c.a.createElement("div",{className:"flex-container flex-end"},c.a.createElement(o.a,{type:"primary",htmlType:"submit",style:{marginRight:10}},"确定"),c.a.createElement(o.a,{type:"ghost",onClick:r},"取消")))}},"7ixt":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/rc-tooltip/es/placements.js ***!
|
|
|
\**************************************************/
|
|
|
/*! exports provided: placements, default */
|
|
|
/*! exports used: placements */function(t,e,r){"use strict";r.d(e,"a",(function(){return o}));var n={adjustX:1,adjustY:1},i=[0,0],o={left:{points:["cr","cl"],overflow:n,offset:[-4,0],targetOffset:i},right:{points:["cl","cr"],overflow:n,offset:[4,0],targetOffset:i},top:{points:["bc","tc"],overflow:n,offset:[0,-4],targetOffset:i},bottom:{points:["tc","bc"],overflow:n,offset:[0,4],targetOffset:i},topLeft:{points:["bl","tl"],overflow:n,offset:[0,-4],targetOffset:i},leftTop:{points:["tr","tl"],overflow:n,offset:[-4,0],targetOffset:i},topRight:{points:["br","tr"],overflow:n,offset:[0,-4],targetOffset:i},rightTop:{points:["tl","tr"],overflow:n,offset:[4,0],targetOffset:i},bottomRight:{points:["tr","br"],overflow:n,offset:[0,4],targetOffset:i},rightBottom:{points:["bl","br"],overflow:n,offset:[4,0],targetOffset:i},bottomLeft:{points:["tl","bl"],overflow:n,offset:[0,4],targetOffset:i},leftBottom:{points:["br","bl"],overflow:n,offset:[-4,0],targetOffset:i}}},"7oTu":
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/tool/transformPath.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/PathProxy */"IMiH"),i=r(/*! ../core/vector */"QBsz").applyTransform,o=n.CMD,a=[[],[],[]],s=Math.sqrt,A=Math.atan2;t.exports=function(t,e){var r,n,l,c,u,h=t.data,d=o.M,f=o.C,p=o.L,g=o.R,m=o.A,v=o.Q;for(l=0,c=0;l<h.length;){switch(r=h[l++],c=l,n=0,r){case d:case p:n=1;break;case f:n=3;break;case v:n=2;break;case m:var y=e[4],w=e[5],b=s(e[0]*e[0]+e[1]*e[1]),C=s(e[2]*e[2]+e[3]*e[3]),B=A(-e[1]/C,e[0]/b);h[l]*=b,h[l++]+=y,h[l]*=C,h[l++]+=w,h[l++]*=b,h[l++]*=C,h[l++]+=B,h[l++]+=B,c=l+=2;break;case g:x[0]=h[l++],x[1]=h[l++],i(x,x,e),h[c++]=x[0],h[c++]=x[1],x[0]+=h[l++],x[1]+=h[l++],i(x,x,e),h[c++]=x[0],h[c++]=x[1]}for(u=0;u<n;u++){var x;(x=a[u])[0]=h[l++],x[1]=h[l++],i(x,x,e),h[c++]=x[0],h[c++]=x[1]}}}},"815F":
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./node_modules/rc-tree/es/utils/treeUtil.js ***!
|
|
|
\***************************************************/
|
|
|
/*! exports provided: getKey, warningWithoutKey, convertTreeToData, flattenTreeData, traverseDataNodes, convertDataToEntities, getTreeNodeProps, convertNodePropsToEventData */
|
|
|
/*! exports used: convertDataToEntities, convertNodePropsToEventData, convertTreeToData, flattenTreeData, getKey, getTreeNodeProps */function(t,e,r){"use strict";r.d(e,"e",(function(){return l})),r.d(e,"c",(function(){return c})),r.d(e,"d",(function(){return u})),r.d(e,"a",(function(){return d})),r.d(e,"f",(function(){return f})),r.d(e,"b",(function(){return p}));var n=r(/*! @babel/runtime/helpers/esm/toConsumableArray */"KQm4"),i=r(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ"),o=r(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),a=r(/*! rc-util/es/Children/toArray */"Zm9Q"),s=r(/*! rc-util/es/warning */"Kwbf"),A=r(/*! ../util */"OZM5");function l(t,e){return null!=t?t:e}function c(t){return function t(e){return Object(a.a)(e).map((function(e){if(!Object(A.i)(e))return Object(s.a)(!e,"Tree/TreeNode can only accept TreeNode as children."),null;var r=e.key,n=e.props,a=n.children,l=Object(o.a)(n,["children"]),c=Object(i.a)({key:r},l),u=t(a);return u.length&&(c.children=u),c})).filter((function(t){return t}))}(t)}function u(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=new Set(!0===e?[]:e),o=[];function a(t){var s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return t.map((function(c,u){var h=Object(A.h)(s?s.pos:"0",u),d=l(c.key,h),f=Object(i.a)(Object(i.a)({},c),{},{parent:s,pos:h,children:null,data:c,isStart:[].concat(Object(n.a)(s?s.isStart:[]),[0===u]),isEnd:[].concat(Object(n.a)(s?s.isEnd:[]),[u===t.length-1])});return o.push(f),!0===e||r.has(d)?f.children=a(c.children||[],f):f.children=[],f}))}return a(t),o}function h(t,e,r){var n;r?"string"==typeof r?n=function(t){return t[r]}:"function"==typeof r&&(n=function(t){return r(t)}):n=function(t,e){return l(t.key,e)},function r(i,o,a){var s=i?i.children:t,l=i?Object(A.h)(a.pos,o):"0";if(i){var c=n(i,l),u={node:i,index:o,pos:l,key:c,parentPos:a.node?a.pos:null,level:a.level+1};e(u)}s&&s.forEach((function(t,e){r(t,e,{node:i,pos:l,level:a?a.level+1:-1})}))}(null)}function d(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e.initWrapper,n=e.processEntity,i=e.onProcessFinished,o=arguments.length>2?arguments[2]:void 0,a={},s={},A={posEntities:a,keyEntities:s};return r&&(A=r(A)||A),h(t,(function(t){var e=t.node,r=t.index,i=t.pos,o=t.key,c=t.parentPos,u={node:e,index:r,key:o,pos:i,level:t.level},h=l(o,i);a[i]=u,s[h]=u,u.parent=a[c],u.parent&&(u.parent.children=u.parent.children||[],u.parent.children.push(u)),n&&n(u,A)}),o),i&&i(A),A}function f(t,e){var r=e.expandedKeys,n=e.selectedKeys,i=e.loadedKeys,o=e.loadingKeys,a=e.checkedKeys,s=e.halfCheckedKeys,A=e.dragOverNodeKey,l=e.dropPosition,c=e.keyEntities[t];return{eventKey:t,expanded:-1!==r.indexOf(t),selected:-1!==n.indexOf(t),loaded:-1!==i.indexOf(t),loading:-1!==o.indexOf(t),checked:-1!==a.indexOf(t),halfChecked:-1!==s.indexOf(t),pos:String(c?c.pos:""),dragOver:A===t&&0===l,dragOverGapTop:A===t&&-1===l,dragOverGapBottom:A===t&&1===l}}function p(t){var e=t.data,r=t.expanded,n=t.selected,o=t.checked,a=t.loaded,A=t.loading,l=t.halfChecked,c=t.dragOver,u=t.dragOverGapTop,h=t.dragOverGapBottom,d=t.pos,f=t.active,p=Object(i.a)(Object(i.a)({},e),{},{expanded:r,selected:n,checked:o,loaded:a,loading:A,halfChecked:l,dragOver:c,dragOverGapTop:u,dragOverGapBottom:h,pos:d,active:f});return"props"in p||Object.defineProperty(p,"props",{get:function(){return Object(s.a)(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),t}}),p}},"8EBN":
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./node_modules/codemirror/mode/meta.js ***!
|
|
|
\**********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){!function(t){"use strict";t.modeInfo=[{name:"APL",mime:"text/apl",mode:"apl",ext:["dyalog","apl"]},{name:"PGP",mimes:["application/pgp","application/pgp-encrypted","application/pgp-keys","application/pgp-signature"],mode:"asciiarmor",ext:["asc","pgp","sig"]},{name:"ASN.1",mime:"text/x-ttcn-asn",mode:"asn.1",ext:["asn","asn1"]},{name:"Asterisk",mime:"text/x-asterisk",mode:"asterisk",file:/^extensions\.conf$/i},{name:"Brainfuck",mime:"text/x-brainfuck",mode:"brainfuck",ext:["b","bf"]},{name:"C",mime:"text/x-csrc",mode:"clike",ext:["c","h","ino"]},{name:"C++",mime:"text/x-c++src",mode:"clike",ext:["cpp","c++","cc","cxx","hpp","h++","hh","hxx"],alias:["cpp"]},{name:"Cobol",mime:"text/x-cobol",mode:"cobol",ext:["cob","cpy"]},{name:"C#",mime:"text/x-csharp",mode:"clike",ext:["cs"],alias:["csharp","cs"]},{name:"Clojure",mime:"text/x-clojure",mode:"clojure",ext:["clj","cljc","cljx"]},{name:"ClojureScript",mime:"text/x-clojurescript",mode:"clojure",ext:["cljs"]},{name:"Closure Stylesheets (GSS)",mime:"text/x-gss",mode:"css",ext:["gss"]},{name:"CMake",mime:"text/x-cmake",mode:"cmake",ext:["cmake","cmake.in"],file:/^CMakeLists\.txt$/},{name:"CoffeeScript",mimes:["application/vnd.coffeescript","text/coffeescript","text/x-coffeescript"],mode:"coffeescript",ext:["coffee"],alias:["coffee","coffee-script"]},{name:"Common Lisp",mime:"text/x-common-lisp",mode:"commonlisp",ext:["cl","lisp","el"],alias:["lisp"]},{name:"Cypher",mime:"application/x-cypher-query",mode:"cypher",ext:["cyp","cypher"]},{name:"Cython",mime:"text/x-cython",mode:"python",ext:["pyx","pxd","pxi"]},{name:"Crystal",mime:"text/x-crystal",mode:"crystal",ext:["cr"]},{name:"CSS",mime:"text/css",mode:"css",ext:["css"]},{name:"CQL",mime:"text/x-cassandra",mode:"sql",ext:["cql"]},{name:"D",mime:"text/x-d",mode:"d",ext:["d"]},{name:"Dart",mimes:["application/dart","text/x-dart"],mode:"dart",ext:["dart"]},{name:"diff",mime:"text/x-diff",mode:"diff",ext:["diff","patch"]},{name:"Django",mime:"text/x-django",mode:"django"},{name:"Dockerfile",mime:"text/x-dockerfile",mode:"dockerfile",file:/^Dockerfile$/},{name:"DTD",mime:"application/xml-dtd",mode:"dtd",ext:["dtd"]},{name:"Dylan",mime:"text/x-dylan",mode:"dylan",ext:["dylan","dyl","intr"]},{name:"EBNF",mime:"text/x-ebnf",mode:"ebnf"},{name:"ECL",mime:"text/x-ecl",mode:"ecl",ext:["ecl"]},{name:"edn",mime:"application/edn",mode:"clojure",ext:["edn"]},{name:"Eiffel",mime:"text/x-eiffel",mode:"eiffel",ext:["e"]},{name:"Elm",mime:"text/x-elm",mode:"elm",ext:["elm"]},{name:"Embedded Javascript",mime:"application/x-ejs",mode:"htmlembedded",ext:["ejs"]},{name:"Embedded Ruby",mime:"application/x-erb",mode:"htmlembedded",ext:["erb"]},{name:"Erlang",mime:"text/x-erlang",mode:"erlang",ext:["erl"]},{name:"Esper",mime:"text/x-esper",mode:"sql"},{name:"Factor",mime:"text/x-factor",mode:"factor",ext:["factor"]},{name:"FCL",mime:"text/x-fcl",mode:"fcl"},{name:"Forth",mime:"text/x-forth",mode:"forth",ext:["forth","fth","4th"]},{name:"Fortran",mime:"text/x-fortran",mode:"fortran",ext:["f","for","f77","f90","f95"]},{name:"F#",mime:"text/x-fsharp",mode:"mllike",ext:["fs"],alias:["fsharp"]},{name:"Gas",mime:"text/x-gas",mode:"gas",ext:["s"]},{name:"Gherkin",mime:"text/x-feature",mode:"gherkin",ext:["feature"]},{name:"GitHub Flavored Markdown",mime:"text/x-gfm",mode:"gfm",file:/^(readme|contributing|history)\.md$/i},{name:"Go",mime:"text/x-go",mode:"go",ext:["go"]},{name:"Groovy",mime:"text/x-groovy",mode:"groovy",ext:["groovy","gradle"],file:/^Jenkinsfile$/},{name:"HAML",mime:"text/x-haml",mode:"haml",ext:["haml"]},{name:"Haskell",mime:"text/x-haskell",mode:"haskell",ext:["hs"]},{name:"Haskell (Literate)",mime:"text/x-literate-haskell",mode:"haskell-literate",ext:["lhs"]},{name:"Haxe",mime:"text/x-haxe",mode:"haxe",ext:["hx"]},{name:"HXML",mime:"text/x-hxml",mode:"haxe",ext:["hxml"]},{name:"ASP.NET",mime:"application/x-aspx",mode:"htmlembedded",ext:["aspx"],alias:["asp","aspx"]},{name:"HTML",mime:"text/html",mode:"htmlmixed",ext:["html","htm","handlebars","hbs"],alias:["xhtml"]},{name:"HTTP",mime:"message/http",mode:"http"},{name:"IDL",mime:"text/x-idl",mode:"idl",ext:["pro"]},{name:"Pug",mime:"text/x-pug",mode:"pug",ext:["jade","pug"],alias:["jade"]},{name:"Java",mime:"text/x-java",mode:"clike",ext:["java"]},{name:"Java Server Pages",mime:"application/x-jsp",mode:"htmlembedded",ext:["jsp"],alias:["jsp"]},{name:"JavaScript",mimes:["text/javascript","text/ecmascript","application/javascript","application/x-javascript","application/ecmascript"],mode:"javascript",ext:["js"],alias:["ecmascript","js","node"]},{name:"JSON",mimes:["application/json","application/x-json"],mode:"javascript",ext:["json","map"],alias:["json5"]},{name:"JSON-LD",mime:"application/ld+json",mode:"javascript",ext:["jsonld"],alias:["jsonld"]},{name:"JSX",mime:"text/jsx",mode:"jsx",ext:["jsx"]},{name:"Jinja2",mime:"text/jinja2",mode:"jinja2",ext:["j2","jinja","jinja2"]},{name:"Julia",mime:"text/x-julia",mode:"julia",ext:["jl"]},{name:"Kotlin",mime:"text/x-kotlin",mode:"clike",ext:["kt"]},{name:"LESS",mime:"text/x-less",mode:"css",ext:["less"]},{name:"LiveScript",mime:"text/x-livescript",mode:"livescript",ext:["ls"],alias:["ls"]},{name:"Lua",mime:"text/x-lua",mode:"lua",ext:["lua"]},{name:"Markdown",mime:"text/x-markdown",mode:"markdown",ext:["markdown","md","mkd"]},{name:"mIRC",mime:"text/mirc",mode:"mirc"},{name:"MariaDB SQL",mime:"text/x-mariadb",mode:"sql"},{name:"Mathematica",mime:"text/x-mathematica",mode:"mathematica",ext:["m","nb","wl","wls"]},{name:"Modelica",mime:"text/x-modelica",mode:"modelica",ext:["mo"]},{name:"MUMPS",mime:"text/x-mumps",mode:"mumps",ext:["mps"]},{name:"MS SQL",mime:"text/x-mssql",mode:"sql"},{name:"mbox",mime:"application/mbox",mode:"mbox",ext:["mbox"]},{name:"MySQL",mime:"text/x-mysql",mode:"sql"},{name:"Nginx",mime:"text/x-nginx-conf",mode:"nginx",file:/nginx.*\.conf$/i},{name:"NSIS",mime:"text/x-nsis",mode:"nsis",ext:["nsh","nsi"]},{name:"NTriples",mimes:["application/n-triples","application/n-quads","text/n-triples"],mode:"ntriples",ext:["nt","nq"]},{name:"Objective-C",mime:"text/x-objectivec",mode:"clike",ext:["m"],alias:["objective-c","objc"]},{name:"Objective-C++",mime:"text/x-objectivec++",mode:"clike",ext:["mm"],alias:["objective-c++","objc++"]},{name:"OCaml",mime:"text/x-ocaml",mode:"mllike",ext:["ml","mli","mll","mly"]},{name:"Octave",mime:"text/x-octave",mode:"octave",ext:["m"]},{name:"Oz",mime:"text/x-oz",mode:"oz",ext:["oz"]},{name:"Pascal",mime:"text/x-pascal",mode:"pascal",ext:["p","pas"]},{name:"PEG.js",mime:"null",mode:"pegjs",ext:["jsonld"]},{name:"Perl",mime:"text/x-perl",mode:"perl",ext:["pl","pm"]},{name:"PHP",mimes:["text/x-php","application/x-httpd-php","application/x-httpd-php-open"],mode:"php",ext:["php","php3","php4","php5","php7","phtml"]},{name:"Pig",mime:"text/x-pig",mode:"pig",ext:["pig"]},{name:"Plain Text",mime:"text/plain",mode:"null",ext:["txt","text","conf","def","list","log"]},{name:"PLSQL",mime:"text/x-plsql",mode:"sql",ext:["pls"]},{name:"PostgreSQL",mime:"text/x-pgsql",mode:"sql"},{name:"PowerShell",mime:"application/x-powershell",mode:"powershell",ext:["ps1","psd1","psm1"]},{name:"Properties files",mime:"text/x-properties",mode:"properties",ext:["properties","ini","in"],alias:["ini","properties"]},{name:"ProtoBuf",mime:"text/x-protobuf",mode:"protobuf",ext:["proto"]},{name:"Python",mime:"text/x-python",mode:"python",ext:["BUILD","bzl","py","pyw"],file:/^(BUCK|BUILD)$/},{name:"Puppet",mime:"text/x-puppet",mode:"puppet",ext:["pp"]},{name:"Q",mime:"text/x-q",mode:"q",ext:["q"]},{name:"R",mime:"text/x-rsrc",mode:"r",ext:["r","R"],alias:["rscript"]},{name:"reStructuredText",mime:"text/x-rst",mode:"rst",ext:["rst"],alias:["rst"]},{name:"RPM Changes",mime:"text/x-rpm-changes",mode:"rpm"},{name:"RPM Spec",mime:"text/x-rpm-spec",mode:"rpm",ext:["spec"]},{name:"Ruby",mime:"text/x-ruby",mode:"ruby",ext:["rb"],alias:["jruby","macruby","rake","rb","rbx"]},{name:"Rust",mime:"text/x-rustsrc",mode:"rust",ext:["rs"]},{name:"SAS",mime:"text/x-sas",mode:"sas",ext:["sas"]},{name:"Sass",mime:"text/x-sass",mode:"sass",ext:["sass"]},{name:"Scala",mime:"text/x-scala",mode:"clike",ext:["scala"]},{name:"Scheme",mime:"text/x-scheme",mode:"scheme",ext:["scm","ss"]},{name:"SCSS",mime:"text/x-scss",mode:"css",ext:["scss"]},{name:"Shell",mimes:["text/x-sh","application/x-sh"],mode:"shell",ext:["sh","ksh","bash"],alias:["bash","sh","zsh"],file:/^PKGBUILD$/},{name:"Sieve",mime:"application/sieve",mode:"sieve",ext:["siv","sieve"]},{name:"Slim",mimes:["text/x-slim","application/x-slim"],mode:"slim",ext:["slim"]},{name:"Smalltalk",mime:"text/x-stsrc",mode:"smalltalk",ext:["st"]},{name:"Smarty",mime:"text/x-smarty",mode:"smarty",ext:["tpl"]},{name:"Solr",mime:"text/x-solr",mode:"solr"},{name:"SML",mime:"text/x-sml",mode:"mllike",ext:["sml","sig","fun","smackspec"]},{name:"Soy",mime:"text/x-soy",mode:"soy",ext:["soy"],alias:["closure template"]},{name:"SPARQL",mime:"application/sparql-query",mode:"sparql",ext:["rq","sparql"],alias:["sparul"]},{name:"Spreadsheet",mime:"text/x-spreadsheet",mode:"spreadsheet",alias:["excel","formula"]},{name:"SQL",mime:"text/x-sql",mode:"sql",ext:["sql"]},{name:"SQLite",mime:"text/x-sqlite",mode:"sql"},{name:"Squirrel",mime:"text/x-squirrel",mode:"clike",ext:["nut"]},{name:"Stylus",mime:"text/x-styl",mode:"stylus",ext:["styl"]},{name:"Swift",mime:"text/x-swift",mode:"swift",ext:["swift"]},{name:"sTeX",mime:"text/x-stex",mode:"stex"},{name:"LaTeX",mime:"text/x-latex",mode:"stex",ext:["text","ltx","tex"],alias:["tex"]},{name:"SystemVerilog",mime:"text/x-systemverilog",mode:"verilog",ext:["v","sv","svh"]},{name:"Tcl",mime:"text/x-tcl",mode:"tcl",ext:["tcl"]},{name:"Textile",mime:"text/x-textile",mode:"textile",ext:["textile"]},{name:"TiddlyWiki",mime:"text/x-tiddlywiki",mode:"tiddlywiki"},{name:"Tiki wiki",mime:"text/tiki",mode:"tiki"},{name:"TOML",mime:"text/x-toml",mode:"toml",ext:["toml"]},{name:"Tornado",mime:"text/x-tornado",mode:"tornado"},{name:"troff",mime:"text/troff",mode:"troff",ext:["1","2","3","4","5","6","7","8","9"]},{name:"TTCN",mime:"text/x-ttcn",mode:"ttcn",ext:["ttcn","ttcn3","ttcnpp"]},{name:"TTCN_CFG",mime:"text/x-ttcn-cfg",mode:"ttcn-cfg",ext:["cfg"]},{name:"Turtle",mime:"text/turtle",mode:"turtle",ext:["ttl"]},{name:"TypeScript",mime:"application/typescript",mode:"javascript",ext:["ts"],alias:["ts"]},{name:"TypeScript-JSX",mime:"text/typescript-jsx",mode:"jsx",ext:["tsx"],alias:["tsx"]},{name:"Twig",mime:"text/x-twig",mode:"twig"},{name:"Web IDL",mime:"text/x-webidl",mode:"webidl",ext:["webidl"]},{name:"VB.NET",mime:"text/x-vb",mode:"vb",ext:["vb"]},{name:"VBScript",mime:"text/vbscript",mode:"vbscript",ext:["vbs"]},{name:"Velocity",mime:"text/velocity",mode:"velocity",ext:["vtl"]},{name:"Verilog",mime:"text/x-verilog",mode:"verilog",ext:["v"]},{name:"VHDL",mime:"text/x-vhdl",mode:"vhdl",ext:["vhd","vhdl"]},{name:"Vue.js Component",mimes:["script/x-vue","text/x-vue"],mode:"vue",ext:["vue"]},{name:"XML",mimes:["application/xml","text/xml"],mode:"xml",ext:["xml","xsl","xsd","svg"],alias:["rss","wsdl","xsd"]},{name:"XQuery",mime:"application/xquery",mode:"xquery",ext:["xy","xquery"]},{name:"Yacas",mime:"text/x-yacas",mode:"yacas",ext:["ys"]},{name:"YAML",mimes:["text/x-yaml","text/yaml"],mode:"yaml",ext:["yaml","yml"],alias:["yml"]},{name:"Z80",mime:"text/x-z80",mode:"z80",ext:["z80"]},{name:"mscgen",mime:"text/x-mscgen",mode:"mscgen",ext:["mscgen","mscin","msc"]},{name:"xu",mime:"text/x-xu",mode:"mscgen",ext:["xu"]},{name:"msgenny",mime:"text/x-msgenny",mode:"mscgen",ext:["msgenny"]},{name:"WebAssembly",mime:"text/webassembly",mode:"wast",ext:["wat","wast"]}];for(var e=0;e<t.modeInfo.length;e++){var r=t.modeInfo[e];r.mimes&&(r.mime=r.mimes[0])}t.findModeByMIME=function(e){e=e.toLowerCase();for(var r=0;r<t.modeInfo.length;r++){var n=t.modeInfo[r];if(n.mime==e)return n;if(n.mimes)for(var i=0;i<n.mimes.length;i++)if(n.mimes[i]==e)return n}return/\+xml$/.test(e)?t.findModeByMIME("application/xml"):/\+json$/.test(e)?t.findModeByMIME("application/json"):void 0},t.findModeByExtension=function(e){e=e.toLowerCase();for(var r=0;r<t.modeInfo.length;r++){var n=t.modeInfo[r];if(n.ext)for(var i=0;i<n.ext.length;i++)if(n.ext[i]==e)return n}},t.findModeByFileName=function(e){for(var r=0;r<t.modeInfo.length;r++){var n=t.modeInfo[r];if(n.file&&n.file.test(e))return n}var i=e.lastIndexOf("."),o=i>-1&&e.substring(i+1,e.length);if(o)return t.findModeByExtension(o)},t.findModeByName=function(e){e=e.toLowerCase();for(var r=0;r<t.modeInfo.length;r++){var n=t.modeInfo[r];if(n.name.toLowerCase()==e)return n;if(n.alias)for(var i=0;i<n.alias.length;i++)if(n.alias[i].toLowerCase()==e)return n}}}(r(/*! ../lib/codemirror */"VrN/"))},"8XDt":
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/vml/vml.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){r(/*! ./graphic */"qH13"),(0,r(/*! ../zrender */"aX58").registerPainter)("vml",r(/*! ./Painter */"6fms"))},"8hTe":
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./src/components/RenderHtml/index.less?modules ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){t.exports={button:"button___1wy9m"}},"9Bee":
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./src/components/RenderHtml/index.tsx + 3 modules ***!
|
|
|
\*********************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/RenderHtml/index.less?modules (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/PreviewAll/index.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/env.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/fetch.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/button/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/button/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/space/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/space/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/hls.js/dist/hls.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/katex/dist/katex.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/marked/lib/marked.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/marked/src/helpers.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r("DYRE");var n=r("zeV3"),i=(r("+L6B"),r("2/Rp")),o=r("k1fw"),a=r("9og8"),s=r("tJVT"),A=r("WmNS"),l=r.n(A),c=r("q1tI"),u=r.n(c),h=(r("vg9a"),r("DlQD")),d=r.n(h),f=r("rUJ1");var p=[],g=["<ul>"],m=new d.a.Renderer,v=/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/;function y(){p.length=0,g=["<ul>"]}var w={overflow:"hidden",WebkitBoxOrient:"vertical",display:"-webkit-box",WebkitLineClamp:2};function b(){return function t(e,r,n,i){if(r>=e.length||e[r].level<=n)return r;var o=e[r];i.push("<li><a href='#"+o.anchor+"'>"+o.text+"</a>");var a=[];return r=t(e,++r,o.level,a),a.length>0&&(i.push("<ul>"),a.forEach((function(t){i.push(t)})),i.push("</ul>")),i.push("</li>"),r=t(e,r,n,i)}(p,0,0,g),g.push("</ul>"),g.join("")}var C={heading:function(t){var e=v.exec(t);if(e)return{type:"heading",raw:e[0],depth:e[1].length,text:e[2]}},fences:function(t){var e=this.rules.block.fences.exec(t);if(e){var r=e[0],n=function(t,e){var r=t.match(/^(\s+)(?:```)/);if(null===r)return e;var n=r[1];return e.split("\n").map((function(t){var e=t.match(/^\s+/);return null===e?t:Object(s.a)(e,1)[0].length>=n.length?t.slice(n.length):t})).join("\n")}(r,e[3]||""),i=e[2]?e[2].trim():e[2];if(["latex","katex","math"].indexOf(i)>=0){var o=E(),a=n;n=o,S[o]={type:"block",expression:a}}return{type:"code",raw:r,lang:i,text:n}}}},B=/(?:\${2})([^\n`]+?)(?:\${2})/gi,x=0,E=function(){return"__special_katext_id_".concat(x++,"__")},S={};function k(){x=0,S={}}function T(t){return t=t.replace(B,(function(t,e){var r=E();return S[r]={type:"inline",expression:e},r}))}var F=m.listitem;m.listitem=function(t){return F(T(t))};var L=m.paragraph;m.paragraph=function(t){return L(T(t))};var I=m.tablecell;m.tablecell=function(t,e){return I(T(t),e)},m.code=function(t,e,r){var n=(e||"").match(/\S*/)[0];return n?["latex","katex","math"].indexOf(n)>=0?"<p class='editormd-tex'>".concat(t,"</p>"):'<pre class="prettyprint linenums"><code class="language-'.concat(e,'">').concat(r?t:Object(f.escape)(t,!0),"</code></pre>\n"):'<pre class="prettyprint linenums"><code>'+(r?t:Object(f.escape)(t,!0))+"</code></pre>"},m.heading=function(t,e,r){var n=this.options.headerPrefix+r.toLowerCase().replace(/[^\w\\u4e00-\\u9fa5]]+/g,"-");return p.push({anchor:n,level:e,text:t}),"<h"+e+' id="'+n+'">'+t+"</h"+e+">"},d.a.setOptions({silent:!0,gfm:!0,pedantic:!1}),d.a.use({tokenizer:C,renderer:m});var _=d.a,U=(r("SJMd"),r("ulZh")),O=r.n(U),D=r("m3rI"),Q=r("Oy/b"),M=r("p5ED"),R=r("ErOA"),P=function(t,e){return(P=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])})(t,e)};function H(t,e){function r(){this.constructor=t}P(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}function N(t,e,r,n){return new(r||(r=Promise))((function(i,o){function a(t){try{A(n.next(t))}catch(t){o(t)}}function s(t){try{A(n.throw(t))}catch(t){o(t)}}function A(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(a,s)}A((n=n.apply(t,e||[])).next())}))}function K(t,e){var r,n,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(i=2&o[0]?n.return:o[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;switch(n=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,n=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=e.call(t,a)}catch(t){o=[6,t],n=0}finally{r=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}function j(){for(var t=0,e=0,r=arguments.length;e<r;e++)t+=arguments[e].length;var n=Array(t),i=0;for(e=0;e<r;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)n[i]=o[a];return n}var G=function(){function t(){}return t.createDefs=function(){return document.createElementNS("http://www.w3.org/2000/svg","defs")},t.setAttributes=function(t,e){for(var r=0,n=e;r<n.length;r++){var i=n[r],o=i[0],a=i[1];t.setAttribute(o,a)}},t.createRect=function(e,r,n){var i=document.createElementNS("http://www.w3.org/2000/svg","rect");return i.setAttribute("width",e.toString()),i.setAttribute("height",r.toString()),n&&t.setAttributes(i,n),i},t.createLine=function(e,r,n,i,o){var a=document.createElementNS("http://www.w3.org/2000/svg","line");return a.setAttribute("x1",e.toString()),a.setAttribute("y1",r.toString()),a.setAttribute("x2",n.toString()),a.setAttribute("y2",i.toString()),o&&t.setAttributes(a,o),a},t.createPolygon=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","polygon");return n.setAttribute("points",e),r&&t.setAttributes(n,r),n},t.createCircle=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","circle");return n.setAttribute("cx",(e/2).toString()),n.setAttribute("cy",(e/2).toString()),n.setAttribute("r",e.toString()),r&&t.setAttributes(n,r),n},t.createEllipse=function(e,r,n){var i=document.createElementNS("http://www.w3.org/2000/svg","ellipse");return i.setAttribute("cx",(e/2).toString()),i.setAttribute("cy",(r/2).toString()),i.setAttribute("rx",(e/2).toString()),i.setAttribute("ry",(r/2).toString()),n&&t.setAttributes(i,n),i},t.createGroup=function(e){var r=document.createElementNS("http://www.w3.org/2000/svg","g");return e&&t.setAttributes(r,e),r},t.createTransform=function(){return document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGTransform()},t.createMarker=function(e,r,n,i,o,a,s){var A=document.createElementNS("http://www.w3.org/2000/svg","marker");return t.setAttributes(A,[["id",e],["orient",r],["markerWidth",n.toString()],["markerHeight",i.toString()],["refX",o.toString()],["refY",a.toString()]]),A.appendChild(s),A},t.createText=function(e){var r=document.createElementNS("http://www.w3.org/2000/svg","text");return r.setAttribute("x","0"),r.setAttribute("y","0"),e&&t.setAttributes(r,e),r},t.createTSpan=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","tspan");return n.textContent=e,r&&t.setAttributes(n,r),n},t.createImage=function(e){var r=document.createElementNS("http://www.w3.org/2000/svg","image");return e&&t.setAttributes(r,e),r},t.createPoint=function(t,e){var r=document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGPoint();return r.x=t,r.y=e,r},t.createPath=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","path");return n.setAttribute("d",e),r&&t.setAttributes(n,r),n},t}(),V=function(){function t(){}return t.addKey=function(e){t.key=e},Object.defineProperty(t,"isLicensed",{get:function(){return!!t.key&&new RegExp(/^MJS2-[A-Z][0-9]{3}-[A-Z][0-9]{3}-[0-9]{4}$/,"i").test(t.key)},enumerable:!1,configurable:!0}),t}(),z=function(){function t(){this.naturalSize=!1,this.imageType="image/png",this.markersOnly=!1}return t.prototype.rasterize=function(t,e,r){var n=this;return new Promise((function(i){var o=void 0!==r?r:document.createElement("canvas");null===t&&(n.markersOnly=!0,n.naturalSize=!1);var a=document.createElementNS("http://www.w3.org/2000/svg","svg");a.setAttribute("xmlns","http://www.w3.org/2000/svg"),a.setAttribute("width",e.width.baseVal.valueAsString),a.setAttribute("height",e.height.baseVal.valueAsString),a.setAttribute("viewBox","0 0 "+e.viewBox.baseVal.width.toString()+" "+e.viewBox.baseVal.height.toString()),a.innerHTML=e.innerHTML,!0===n.naturalSize?(a.width.baseVal.value=t.naturalWidth,a.height.baseVal.value=t.naturalHeight):void 0!==n.width&&void 0!==n.height&&(a.width.baseVal.value=n.width,a.height.baseVal.value=n.height),o.width=a.width.baseVal.value,o.height=a.height.baseVal.value;var s=a.outerHTML,A=o.getContext("2d");!0!==n.markersOnly&&A.drawImage(t,0,0,o.width,o.height);var l=window.URL,c=new Image(o.width,o.height);c.setAttribute("crossOrigin","anonymous");var u=new Blob([s],{type:"image/svg+xml"}),h=l.createObjectURL(u);c.onload=function(){A.drawImage(c,0,0),l.revokeObjectURL(h);var t=o.toDataURL(n.imageType,n.imageQuality);i(t)},c.src=h}))},t}(),W=function(){},Y=function(){function t(t){this._classNamePrefixBase="__markerjs2_",this.classes=[],this.rules=[],this.settings=this.defaultSettings,this._classNamePrefix=this._classNamePrefixBase+"_"+t+"_"}return Object.defineProperty(t.prototype,"classNamePrefixBase",{get:function(){return this._classNamePrefixBase},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"classNamePrefix",{get:function(){return this._classNamePrefix},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"defaultSettings",{get:function(){return{canvasBackgroundColor:"#ffffff",toolbarBackgroundColor:"#111111",toolbarBackgroundHoverColor:"#333333",toolbarColor:"#eeeeee",toolbarHeight:40,toolboxColor:"#eeeeee",toolboxAccentColor:"#3080c3",undoButtonVisible:!0,redoButtonVisible:!1,zoomButtonVisible:!1,zoomOutButtonVisible:!1,clearButtonVisible:!1,resultButtonBlockVisible:!0,logoPosition:"left"}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fadeInAnimationClassName",{get:function(){return this.classNamePrefix+"fade_in"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fadeOutAnimationClassName",{get:function(){return this.classNamePrefix+"fade_out"},enumerable:!1,configurable:!0}),t.prototype.addClass=function(t){return void 0===this.styleSheet&&this.addStyleSheet(),t.name=""+this.classNamePrefix+t.localName,this.classes.push(t),this.styleSheet.sheet.insertRule("."+t.name+" {"+t.style+"}",this.styleSheet.sheet.cssRules.length),t},t.prototype.addRule=function(t){void 0===this.styleSheet&&this.addStyleSheet(),this.rules.push(t),this.styleSheet.sheet.insertRule(t.selector+" {"+t.style+"}",this.styleSheet.sheet.cssRules.length)},t.prototype.addStyleSheet=function(){var t;this.styleSheet=document.createElement("style"),(null!==(t=this.styleSheetRoot)&&void 0!==t?t:document.head).appendChild(this.styleSheet),this.addRule(new X("."+this.classNamePrefix+" h3","font-family: sans-serif")),this.addRule(new X("@keyframes "+this.classNamePrefix+"_fade_in_animation_frames","\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n ")),this.addRule(new X("@keyframes "+this.classNamePrefix+"_fade_out_animation_frames","\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n }\n ")),this.addClass(new q("fade_in","\n animation-duration: 0.3s;\n animation-name: "+this.classNamePrefix+"_fade_in_animation_frames;\n ")),this.addClass(new q("fade_out","\n animation-duration: 0.3s;\n animation-name: "+this.classNamePrefix+"_fade_out_animation_frames;\n "))},t.prototype.removeStyleSheet=function(){var t;this.styleSheet&&((null!==(t=this.styleSheetRoot)&&void 0!==t?t:document.head).removeChild(this.styleSheet),this.styleSheet=void 0)},t}(),X=function(t,e){this.selector=t,this.style=e},q=function(t,e){this.localName=t,this.style=e},J=function(){function t(t,e,r,n,i){this.buttons=[],this.markerButtons=[],this.buttonClickListeners=[],this.markerjsContainer=t,this.displayMode=e,this.markerItems=r,this.uiStyleSettings=n,this.styles=i,this.addStyles(),this.adjustLayout=this.adjustLayout.bind(this),this.overflowButtonClicked=this.overflowButtonClicked.bind(this),this.setCurrentMarker=this.setCurrentMarker.bind(this)}return t.prototype.show=function(t){var e=this;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=t,this.uiContainer.className=this.toolbarStyleClass.name+" "+this.styles.fadeInAnimationClassName+" "+(this.uiStyleSettings.toolbarStyleColorsClassName?this.uiStyleSettings.toolbarStyleColorsClassName:this.toolbarStyleColorsClass.name);var r=document.createElement("div");r.className=this.toolbarBlockStyleClass.name,r.style.whiteSpace="nowrap",this.uiContainer.appendChild(r),this.addActionButton(r,'<svg viewBox="0 0 24 24"><path d="M10.07 14.27a.997.997 0 011.33.48l2.3 4.99 1.8-.85-2.31-4.98c-.24-.5-.02-1.1.48-1.33l.28-.08 2.3-.45L8 5.12V15.9l1.82-1.47.25-.16m3.57 7.7a.99.99 0 01-1.33-.47l-2.18-4.74-2.51 2.02c-.17.14-.38.22-.62.22a1 1 0 01-1-1V3a1 1 0 011-1c.24 0 .47.09.64.23l.01-.01 11.49 9.64a1.001 1.001 0 01-.44 1.75l-3.16.62 2.2 4.73c.26.5.02 1.09-.48 1.32l-3.62 1.69z"/></svg>',"select"),this.addActionButton(r,'<svg viewBox="0 0 24 24"><path d="M9 3v1H4v2h1v13a2 2 0 002 2h10a2 2 0 002-2V6h1V4h-5V3H9M7 6h10v13H7V6m2 2v9h2V8H9m4 0v9h2V8h-2z"/></svg>',"delete"),this.uiStyleSettings.clearButtonVisible&&this.addActionButton(r,'<svg viewBox="0 0 24 24"><path d="M19.36 2.72l1.42 1.42-5.72 5.71c1.07 1.54 1.22 3.39.32 4.59L9.06 8.12c1.2-.9 3.05-.75 4.59.32l5.71-5.72M5.93 17.57c-2.01-2.01-3.24-4.41-3.58-6.65l4.88-2.09 7.44 7.44-2.09 4.88c-2.24-.34-4.64-1.57-6.65-3.58z"/></svg>',"clear"),this.uiStyleSettings.undoButtonVisible&&this.addActionButton(r,'<svg viewBox="0 0 24 24"><path d="M12.5 8c-2.65 0-5.05 1-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"/></svg>',"undo"),this.uiStyleSettings.redoButtonVisible&&this.addActionButton(r,'<svg viewBox="0 0 24 24"><path d="M18.4 10.6C16.55 9 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16a8.002 8.002 0 017.6-5.5c1.95 0 3.73.72 5.12 1.88L13 16h9V7l-3.6 3.6z"/></svg>',"redo"),this.uiStyleSettings.zoomButtonVisible&&this.addActionButton(r,'<svg viewBox="0 0 24 24"><path d="M15.5 14l5 5-1.5 1.5-5-5v-.79l-.27-.28A6.471 6.471 0 019.5 16 6.5 6.5 0 013 9.5 6.5 6.5 0 019.5 3 6.5 6.5 0 0116 9.5c0 1.61-.59 3.09-1.57 4.23l.28.27h.79m-6 0C12 14 14 12 14 9.5S12 5 9.5 5 5 7 5 9.5 7 14 9.5 14m2.5-4h-2v2H9v-2H7V9h2V7h1v2h2v1z"/></svg>',"zoom"),this.uiStyleSettings.zoomButtonVisible&&this.uiStyleSettings.zoomOutButtonVisible&&this.addActionButton(r,'<svg viewBox="0 0 24 24"><path d="M15.5 14h-.79l-.28-.27A6.471 6.471 0 0016 9.5 6.5 6.5 0 009.5 3 6.5 6.5 0 003 9.5 6.5 6.5 0 009.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 5 1.5-1.5-5-5m-6 0C7 14 5 12 5 9.5S7 5 9.5 5 14 7 14 9.5 12 14 9.5 14M7 9h5v1H7V9z"/></svg>',"zoom-out"),this.uiStyleSettings.notesButtonVisible&&this.addActionButton(r,'<svg viewBox="0 0 24 24"><path d="M18.13 12l1.26-1.26c.44-.44 1-.68 1.61-.74V9l-6-6H5c-1.11 0-2 .89-2 2v14a2 2 0 002 2h6v-1.87l.13-.13H5V5h7v7h6.13M14 4.5l5.5 5.5H14V4.5m5.13 9.33l2.04 2.04L15.04 22H13v-2.04l6.13-6.13m3.72.36l-.98.98-2.04-2.04.98-.98c.19-.2.52-.2.72 0l1.32 1.32c.2.2.2.53 0 .72z"/></svg>',"notes"),this.markerButtonBlock=document.createElement("div"),this.markerButtonBlock.className=this.toolbarBlockStyleClass.name,this.markerButtonBlock.style.flexGrow="2",this.markerButtonBlock.style.textAlign="center",this.uiContainer.appendChild(this.markerButtonBlock),this.markerButtonOverflowBlock=document.createElement("div"),this.markerButtonOverflowBlock.className=this.toolbarOverflowBlockStyleClass.name+" "+(this.uiStyleSettings.toolbarOverflowBlockStyleColorsClassName?this.uiStyleSettings.toolbarOverflowBlockStyleColorsClassName:this.toolbarOverflowBlockStyleColorsClass.name),this.markerButtonOverflowBlock.style.display="none",this.uiContainer.appendChild(this.markerButtonOverflowBlock),this.markerItems&&(this.markerItems.forEach((function(t){var r=document.createElement("div");r.className=""+e.toolbarButtonStyleClass.name,r.setAttribute("data-type-name",t.typeName),r.innerHTML=t.icon,r.addEventListener("click",(function(){e.markerToolbarButtonClicked(r,t)})),e.buttons.push(r),e.markerButtons.push(r)})),this.overflowButton=document.createElement("div"),this.overflowButton.className=this.toolbarButtonStyleClass.name+" "+(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name),this.overflowButton.innerHTML='<svg viewBox="0 0 24 24"><path d="M12 16a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2m0-6a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2m0-6a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2z"/></svg>',this.overflowButton.addEventListener("click",this.overflowButtonClicked),this.markerButtonBlock.appendChild(this.overflowButton));var n=document.createElement("div");n.className=this.toolbarBlockStyleClass.name,n.style.whiteSpace="nowrap",n.style.display=!1!==this.uiStyleSettings.resultButtonBlockVisible?"":"none",this.uiContainer.appendChild(n),this.addActionButton(n,'<svg viewBox="0 0 24 24"><path d="M9 20.42l-6.21-6.21 2.83-2.83L9 14.77l9.88-9.89 2.83 2.83L9 20.42z"/></svg>',"render"),this.addActionButton(n,'<svg viewBox="0 0 24 24"><path d="M20 6.91L17.09 4 12 9.09 6.91 4 4 6.91 9.09 12 4 17.09 6.91 20 12 14.91 17.09 20 20 17.09 14.91 12 20 6.91z"/></svg>',"close"),this.markerjsContainer.appendChild(this.uiContainer),this.setSelectMode(),this.setCurrentMarker(),this.adjustLayout()},t.prototype.addButtonClickListener=function(t){this.buttonClickListeners.push(t)},t.prototype.removeButtonClickListener=function(t){this.buttonClickListeners.indexOf(t)>-1&&this.buttonClickListeners.splice(this.buttonClickListeners.indexOf(t),1)},t.prototype.setSelectMode=function(){this.resetButtonStyles(),this.setActiveButton(this.buttons[0])},t.prototype.adjustLayout=function(){if(this.markerButtons&&this.markerButtons.length>0){var t=Math.floor(this.markerButtonBlock.clientWidth/this.uiStyleSettings.toolbarHeight)-1;this.markerButtonBlock.innerHTML="",this.markerButtonOverflowBlock.innerHTML="";for(var e=0;e<this.markerButtons.length;e++)e<t||e===t&&this.markerButtons.length-1===t?this.markerButtonBlock.appendChild(this.markerButtons[e]):(e===t&&this.markerButtonBlock.appendChild(this.overflowButton),this.markerButtonOverflowBlock.appendChild(this.markerButtons[e]))}},t.prototype.overflowButtonClicked=function(){"none"!==this.markerButtonOverflowBlock.style.display?(this.markerButtonOverflowBlock.className=this.markerButtonOverflowBlock.className.replace(this.styles.fadeInAnimationClassName,""),this.markerButtonOverflowBlock.style.display="none"):(this.markerButtonOverflowBlock.className+=" "+this.styles.fadeInAnimationClassName,this.markerButtonOverflowBlock.style.top=this.uiContainer.offsetTop+this.overflowButton.offsetHeight+"px",this.markerButtonOverflowBlock.style.right=this.uiContainer.offsetWidth-this.overflowButton.offsetLeft-this.overflowButton.offsetWidth+2*this.uiContainer.offsetLeft+"px",this.markerButtonOverflowBlock.style.display="inline-block")},t.prototype.resetButtonStyles=function(){var t=this;this.buttons.forEach((function(e){e.className=e.className.replace(t.uiStyleSettings.toolbarButtonStyleColorsClassName?t.uiStyleSettings.toolbarButtonStyleColorsClassName:t.toolbarButtonStyleColorsClass.name,"").trim(),e.className=e.className.replace(t.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?t.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:t.toolbarActiveButtonStyleColorsClass.name,"").trim(),e.className+=" "+(t.uiStyleSettings.toolbarButtonStyleColorsClassName?t.uiStyleSettings.toolbarButtonStyleColorsClassName:t.toolbarButtonStyleColorsClass.name)}))},t.prototype.addActionButton=function(t,e,r){var n=this,i=document.createElement("div");switch(i.className=""+this.toolbarButtonStyleClass.name,i.innerHTML=e,i.setAttribute("data-action",r),i.addEventListener("click",(function(){n.actionToolbarButtonClicked(i,r)})),r){case"select":i.style.fill=this.uiStyleSettings.selectButtonColor;break;case"delete":case"clear":i.style.fill=this.uiStyleSettings.deleteButtonColor;break;case"undo":case"redo":i.style.fill=this.uiStyleSettings.selectButtonColor;break;case"render":i.style.fill=this.uiStyleSettings.okButtonColor;break;case"close":i.style.fill=this.uiStyleSettings.closeButtonColor}t.appendChild(i),this.buttons.push(i)},t.prototype.addStyles=function(){this.toolbarStyleClass=this.styles.addClass(new q("toolbar","\n width: 100%;\n flex-shrink: 0;\n display: flex;\n flex-direction: row;\n justify-content: space-between; \n height: "+this.uiStyleSettings.toolbarHeight+"px;\n box-sizing: content-box;\n "+("inline"===this.displayMode?"border-top-left-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+"\n "+("inline"===this.displayMode?"border-top-right-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+"\n overflow: hidden;\n ")),this.toolbarStyleColorsClass=this.styles.addClass(new q("toolbar_colors","\n background-color: "+this.uiStyleSettings.toolbarBackgroundColor+";\n box-shadow: 0px 3px rgba(33, 33, 33, 0.1);\n ")),this.toolbarBlockStyleClass=this.styles.addClass(new q("toolbar-block","\n display: inline-block;\n box-sizing: content-box;\n ")),this.toolbarOverflowBlockStyleClass=this.styles.addClass(new q("toolbar-overflow-block","\n position: absolute;\n top: "+this.uiStyleSettings.toolbarHeight+"px;\n max-width: "+2*this.uiStyleSettings.toolbarHeight+"px;\n z-index: 10;\n box-sizing: content-box;\n ")),this.toolbarOverflowBlockStyleColorsClass=this.styles.addClass(new q("toolbar-overflow-block_colors","\n background-color: "+this.uiStyleSettings.toolbarBackgroundColor+";\n "));var t=this.uiStyleSettings.toolbarHeight/4;this.toolbarButtonStyleClass=this.styles.addClass(new q("toolbar_button","\n display: inline-block;\n width: "+(this.uiStyleSettings.toolbarHeight-2*t)+"px;\n height: "+(this.uiStyleSettings.toolbarHeight-2*t)+"px;\n padding: "+t+"px;\n box-sizing: content-box;\n ")),this.toolbarButtonStyleColorsClass=this.styles.addClass(new q("toolbar_button_colors","\n fill: "+this.uiStyleSettings.toolbarColor+";\n ")),this.toolbarActiveButtonStyleColorsClass=this.styles.addClass(new q("toolbar_active_button","\n fill: "+this.uiStyleSettings.toolbarColor+";\n background-color: "+this.uiStyleSettings.toolbarBackgroundHoverColor+"\n ")),this.styles.addRule(new X("."+this.toolbarButtonStyleClass.name+" svg","\n height: "+this.uiStyleSettings.toolbarHeight/2+"px;\n ")),this.styles.addRule(new X("."+this.toolbarButtonStyleColorsClass.name+":hover","\n background-color: "+this.uiStyleSettings.toolbarBackgroundHoverColor+"\n "))},t.prototype.markerToolbarButtonClicked=function(t,e){this.setActiveButton(t),this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach((function(t){return t("marker",e)})),this.markerButtonOverflowBlock.style.display="none"},t.prototype.actionToolbarButtonClicked=function(t,e){this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach((function(t){return t("action",e)})),this.markerButtonOverflowBlock.style.display="none",this.setActiveButton(this.buttons[0])},t.prototype.setActiveButton=function(t){this.resetButtonStyles(),t.className=t.className.replace(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,"").trim(),t.className+=" "+(this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name)},t.prototype.setActiveMarkerButton=function(t){var e=this.markerButtons.find((function(e){return e.getAttribute("data-type-name")===t}));e&&this.setActiveButton(e)},t.prototype.setCurrentMarker=function(t){var e=this;this.currentMarker=t,this.buttons.filter((function(t){return/delete|notes/.test(t.getAttribute("data-action"))})).forEach((function(t){void 0===e.currentMarker?(t.style.fillOpacity="0.4",t.style.pointerEvents="none"):(t.style.fillOpacity="1",t.style.pointerEvents="all")}))},t}(),Z=function(){function t(t,e,r,n){this.panels=[],this.panelButtons=[],this.markerjsContainer=t,this.displayMode=e,this.uiStyleSettings=r,this.styles=n,this.panelButtonClick=this.panelButtonClick.bind(this),this.addStyles()}return t.prototype.addStyles=function(){var t;this.toolboxStyleClass=this.styles.addClass(new q("toolbox","\n width: 100%;\n flex-shrink: 0;\n display: flex;\n flex-direction: column;\n font-family: sans-serif;\n "+("popup"===this.displayMode?"height:"+2.5*this.uiStyleSettings.toolbarHeight+"px;":"")+"\n box-sizing: content-box;\n "+("popup"===this.displayMode?"background-color: "+this.uiStyleSettings.canvasBackgroundColor+";":"")+"\n "+("inline"===this.displayMode?"border-bottom-left-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+"\n "+("inline"===this.displayMode?"border-bottom-right-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+"\n overflow: hidden;\n ")),this.toolboxStyleColorsClass=this.styles.addClass(new q("toolbox_colors","\n color: "+this.uiStyleSettings.toolboxColor+";\n "));var e=this.uiStyleSettings.toolbarHeight/4;this.toolboxButtonRowStyleClass=this.styles.addClass(new q("toolbox-button-row","\n display: flex;\n cursor: default;\n box-sizing: content-box;\n ")),this.toolboxButtonRowStyleColorsClass=this.styles.addClass(new q("toolbox-button-row_colors","\n background-color: "+this.uiStyleSettings.toolbarBackgroundColor+";\n ")),this.toolboxPanelRowStyleClass=this.styles.addClass(new q("toolbox-panel-row","\n display: flex;\n "+("inline"===this.displayMode?"position: absolute;":"")+"\n "+("inline"===this.displayMode?"bottom: "+this.uiStyleSettings.toolbarHeight+"px;":"")+"\n cursor: default;\n height: "+1.5*this.uiStyleSettings.toolbarHeight+"px;\n "+("inline"===this.displayMode?"width: 100%;":"")+"\n box-sizing: content-box;\n ")),this.toolboxPanelRowStyleColorsClass=this.styles.addClass(new q("toolbox-panel-row_colors","\n background-color: "+(null!==(t=this.uiStyleSettings.toolboxBackgroundColor)&&void 0!==t?t:this.uiStyleSettings.toolbarBackgroundHoverColor)+";\n ")),this.toolboxButtonStyleClass=this.styles.addClass(new q("toolbox_button","\n display: inline-block;\n width: "+(this.uiStyleSettings.toolbarHeight-2*e)+"px;\n height: "+(this.uiStyleSettings.toolbarHeight-2*e)+"px;\n padding: "+e+"px;\n box-sizing: content-box;\n ")),this.toolboxButtonStyleColorsClass=this.styles.addClass(new q("toolbox-button_colors","\n fill: "+this.uiStyleSettings.toolbarColor+";\n ")),this.toolboxActiveButtonStyleColorsClass=this.styles.addClass(new q("toolbox-active-button_colors","\n background-color: "+this.uiStyleSettings.toolbarBackgroundHoverColor+";\n fill: "+this.uiStyleSettings.toolbarColor+";\n ")),this.styles.addRule(new X("."+this.toolboxButtonStyleColorsClass.name+":hover","\n background-color: "+this.uiStyleSettings.toolbarBackgroundHoverColor+"\n ")),this.styles.addRule(new X("."+this.toolboxButtonStyleClass.name+" svg","\n height: "+this.uiStyleSettings.toolbarHeight/2+"px;\n "))},t.prototype.show=function(t){var e;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=t,this.uiContainer.className=this.toolboxStyleClass.name+" "+(null!==(e=this.uiStyleSettings.toolboxStyleColorsClassName)&&void 0!==e?e:this.toolboxStyleColorsClass.name),this.markerjsContainer.appendChild(this.uiContainer)},t.prototype.setPanelButtons=function(t){var e,r,n=this;this.panels=t,void 0!==this.uiContainer&&(this.uiContainer.innerHTML="",this.panelRow=document.createElement("div"),this.panelRow.className=this.toolboxPanelRowStyleClass.name+" "+(null!==(e=this.uiStyleSettings.toolboxPanelRowStyleColorsClassName)&&void 0!==e?e:this.toolboxPanelRowStyleColorsClass.name),this.uiContainer.appendChild(this.panelRow),this.buttonRow=document.createElement("div"),this.buttonRow.className=this.toolboxButtonRowStyleClass.name+" "+(null!==(r=this.uiStyleSettings.toolboxButtonRowStyleColorsClassName)&&void 0!==r?r:this.toolboxButtonRowStyleColorsClass.name)+" ",this.uiContainer.appendChild(this.buttonRow),this.panelButtons.splice(0),this.panels.forEach((function(t){var e;t.uiStyleSettings=n.uiStyleSettings;var r=document.createElement("div");r.className=n.toolboxButtonStyleClass.name+" "+(null!==(e=n.uiStyleSettings.toolboxButtonStyleColorsClassName)&&void 0!==e?e:n.toolboxButtonStyleColorsClass.name),r.innerHTML=t.icon,r.title=t.title,r.addEventListener("click",(function(){n.panelButtonClick(t)})),n.panelButtons.push(r),n.buttonRow.appendChild(r)})),"inline"===this.displayMode?this.panelRow.style.display="none":this.panelRow.style.visibility="hidden")},t.prototype.panelButtonClick=function(t){var e=this,r=-1;if(t!==this.activePanel){r=this.panels.indexOf(t),this.panelRow.innerHTML="";var n=t.getUi();n.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.panelRow.appendChild(n),this.panelRow.style.display="flex",this.panelRow.style.visibility="visible",this.panelRow.className=this.panelRow.className.replace(this.styles.fadeOutAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeInAnimationClassName,this.activePanel=t}else this.activePanel=void 0,this.panelRow.className=this.panelRow.className.replace(this.styles.fadeInAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeOutAnimationClassName,setTimeout((function(){"inline"===e.displayMode?e.panelRow.style.display="none":e.panelRow.style.visibility="hidden"}),200);this.panelButtons.forEach((function(t,n){var i,o;t.className=e.toolboxButtonStyleClass.name+" "+(n===r?""+(null!==(i=e.uiStyleSettings.toolboxActiveButtonStyleColorsClassName)&&void 0!==i?i:e.toolboxActiveButtonStyleColorsClass.name):""+(null!==(o=e.uiStyleSettings.toolboxButtonStyleColorsClassName)&&void 0!==o?o:e.toolboxButtonStyleColorsClass.name))}))},t}(),$=function(t,e){this.title=t,this.icon=e},tt=function(t){function e(e,r,n,i){var o=t.call(this,e,i||'<svg viewBox="0 0 24 24"><path d="M17.5 12a1.5 1.5 0 01-1.5-1.5A1.5 1.5 0 0117.5 9a1.5 1.5 0 011.5 1.5 1.5 1.5 0 01-1.5 1.5m-3-4A1.5 1.5 0 0113 6.5 1.5 1.5 0 0114.5 5 1.5 1.5 0 0116 6.5 1.5 1.5 0 0114.5 8m-5 0A1.5 1.5 0 018 6.5 1.5 1.5 0 019.5 5 1.5 1.5 0 0111 6.5 1.5 1.5 0 019.5 8m-3 4A1.5 1.5 0 015 10.5 1.5 1.5 0 016.5 9 1.5 1.5 0 018 10.5 1.5 1.5 0 016.5 12M12 3a9 9 0 00-9 9 9 9 0 009 9 1.5 1.5 0 001.5-1.5c0-.39-.15-.74-.39-1-.23-.27-.38-.62-.38-1a1.5 1.5 0 011.5-1.5H16a5 5 0 005-5c0-4.42-4.03-8-9-8z"/></svg>')||this;return o.colors=[],o.addTransparent=!1,o.colorBoxes=[],o.colors=r,o.currentColor=n,o.setCurrentColor=o.setCurrentColor.bind(o),o.getColorBox=o.getColorBox.bind(o),o}return H(e,t),e.prototype.getUi=function(){var t=this,e=document.createElement("div");return e.style.overflow="hidden",e.style.whiteSpace="nowrap",this.colors.forEach((function(r){var n=t.getColorBox(r);e.appendChild(n),t.colorBoxes.push(n)})),e},e.prototype.getColorBox=function(t){var e=this,r=this.uiStyleSettings.toolbarHeight/4,n=this.uiStyleSettings.toolbarHeight-r,i=document.createElement("div");i.style.display="inline-block",i.style.boxSizing="content-box",i.style.width=n-2+"px",i.style.height=n-2+"px",i.style.padding="1px",i.style.marginRight="2px",i.style.marginBottom="2px",i.style.borderWidth="2px",i.style.borderStyle="solid",i.style.borderRadius=(n+2)/2+"px",i.style.borderColor=t===this.currentColor?this.uiStyleSettings.toolboxAccentColor:"transparent",i.addEventListener("click",(function(){e.setCurrentColor(t,i)}));var o=document.createElement("div");return o.style.display="inline-block",o.style.width=n-2+"px",o.style.height=n-2+"px",o.style.backgroundColor=t,o.style.borderRadius=n/2+"px","transparent"===t&&(o.style.fill=this.uiStyleSettings.toolboxAccentColor,o.innerHTML='<svg viewBox="0 0 24 24">\n <path d="M2,5.27L3.28,4L20,20.72L18.73,22L15.65,18.92C14.5,19.3 13.28,19.5 12,19.5C7,19.5 2.73,16.39 1,12C1.69,10.24 2.79,8.69 4.19,7.46L2,5.27M12,9A3,3 0 0,1 15,12C15,12.35 14.94,12.69 14.83,13L11,9.17C11.31,9.06 11.65,9 12,9M12,4.5C17,4.5 21.27,7.61 23,12C22.18,14.08 20.79,15.88 19,17.19L17.58,15.76C18.94,14.82 20.06,13.54 20.82,12C19.17,8.64 15.76,6.5 12,6.5C10.91,6.5 9.84,6.68 8.84,7L7.3,5.47C8.74,4.85 10.33,4.5 12,4.5M3.18,12C4.83,15.36 8.24,17.5 12,17.5C12.69,17.5 13.37,17.43 14,17.29L11.72,15C10.29,14.85 9.15,13.71 9,12.28L5.6,8.87C4.61,9.72 3.78,10.78 3.18,12Z" />\n </svg>'),i.appendChild(o),i},e.prototype.setCurrentColor=function(t,e){var r=this;this.currentColor=t,this.colorBoxes.forEach((function(t){t.style.borderColor=t===e?r.uiStyleSettings.toolboxAccentColor:"transparent"})),this.onColorChanged&&this.onColorChanged(t)},e}($),et=function(){function t(t,e,r){this._state="new",this._isSelected=!1,this._container=t,this._overlayContainer=e,this.globalSettings=r,this.stateChanged=this.stateChanged.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this)}return Object.defineProperty(t.prototype,"typeName",{get:function(){return Object.getPrototypeOf(this).constructor.typeName},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"container",{get:function(){return this._container},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"overlayContainer",{get:function(){return this._overlayContainer},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"state",{get:function(){return this._state},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"toolboxPanels",{get:function(){return[]},enumerable:!1,configurable:!0}),t.prototype.ownsTarget=function(t){return!1},Object.defineProperty(t.prototype,"isSelected",{get:function(){return this._isSelected},enumerable:!1,configurable:!0}),t.prototype.select=function(){this.container.style.cursor="move",this._isSelected=!0,this.manipulationStartState=this.getState()},t.prototype.deselect=function(){this.container.style.cursor="default",this._isSelected=!1,this.stateChanged()},t.prototype.pointerDown=function(t,e){},t.prototype.dblClick=function(t,e){},t.prototype.manipulate=function(t){},t.prototype.pointerUp=function(t){this.stateChanged()},t.prototype.dispose=function(){},t.prototype.addMarkerVisualToContainer=function(t){this.container.childNodes.length>0?this.container.insertBefore(t,this.container.childNodes[0]):this.container.appendChild(t)},t.prototype.getState=function(){return{typeName:t.typeName,state:this.state,notes:this.notes}},t.prototype.restoreState=function(t){this._state=t.state,this.notes=t.notes},t.prototype.scale=function(t,e){},t.prototype.colorChanged=function(t){this.onColorChanged&&this.onColorChanged(t),this.stateChanged()},t.prototype.fillColorChanged=function(t){this.onFillColorChanged&&this.onFillColorChanged(t),this.stateChanged()},t.prototype.stateChanged=function(){if(this.onStateChanged&&"creating"!==this.state&&"new"!==this.state){var t=this.getState();void 0!==this.manipulationStartState&&(this.manipulationStartState.state="select"),t.state="select",JSON.stringify(this.manipulationStartState)!=JSON.stringify(t)&&this.onStateChanged(this)}},t.typeName="MarkerBase",t}(),rt=function(){function t(){this.findGripByVisual=this.findGripByVisual.bind(this)}return t.prototype.findGripByVisual=function(t){return this.topLeft.ownsTarget(t)?this.topLeft:this.topCenter.ownsTarget(t)?this.topCenter:this.topRight.ownsTarget(t)?this.topRight:this.centerLeft.ownsTarget(t)?this.centerLeft:this.centerRight.ownsTarget(t)?this.centerRight:this.bottomLeft.ownsTarget(t)?this.bottomLeft:this.bottomCenter.ownsTarget(t)?this.bottomCenter:this.bottomRight.ownsTarget(t)?this.bottomRight:void 0},t}(),nt=function(){function t(){this.GRIP_SIZE=10,this.visual=G.createGroup(),this.visual.appendChild(G.createCircle(1.5*this.GRIP_SIZE,[["fill","transparent"]])),this.visual.appendChild(G.createCircle(this.GRIP_SIZE,[["fill","#cccccc"],["fill-opacity","0.7"],["stroke","#333333"],["stroke-width","2"],["stroke-opacity","0.7"]]))}return t.prototype.ownsTarget=function(t){return t===this.visual||t===this.visual.childNodes[0]||t===this.visual.childNodes[1]},t}(),it=function(){function t(){}return t.toITransformMatrix=function(t){return{a:t.a,b:t.b,c:t.c,d:t.d,e:t.e,f:t.f}},t.toSVGMatrix=function(t,e){return t.a=e.a,t.b=e.b,t.c=e.c,t.d=e.d,t.e=e.e,t.f=e.f,t},t}(),ot=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.left=0,i.top=0,i.width=0,i.height=0,i.defaultSize={x:50,y:20},i.offsetX=0,i.offsetY=0,i.rotationAngle=0,i.CB_DISTANCE=10,i._suppressMarkerCreateEvent=!1,i.container.transform.baseVal.appendItem(G.createTransform()),i.setupControlBox(),i}return H(e,t),Object.defineProperty(e.prototype,"centerX",{get:function(){return this.left+this.width/2},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"centerY",{get:function(){return this.top+this.height/2},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"visual",{get:function(){return this._visual},set:function(t){this._visual=t;var e=G.createTransform();this._visual.transform.baseVal.appendItem(e)},enumerable:!1,configurable:!0}),e.prototype.ownsTarget=function(e){return!!t.prototype.ownsTarget.call(this,e)||!!(void 0!==this.controlGrips.findGripByVisual(e)||void 0!==this.rotatorGrip&&this.rotatorGrip.ownsTarget(e))},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),"new"===this.state&&(this.left=e.x,this.top=e.y),this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.manipulationStartWidth=this.width,this.manipulationStartHeight=this.height;var n=this.unrotatePoint(e);if(this.manipulationStartX=n.x,this.manipulationStartY=n.y,this.offsetX=n.x-this.left,this.offsetY=n.y-this.top,"new"!==this.state)if(this.select(),this.activeGrip=this.controlGrips.findGripByVisual(r),void 0!==this.activeGrip)this._state="resize";else if(void 0!==this.rotatorGrip&&this.rotatorGrip.ownsTarget(r)){this.activeGrip=this.rotatorGrip;var i=this.rotatePoint({x:this.centerX,y:this.centerY});this.left=i.x-this.width/2,this.top=i.y-this.height/2,this.moveVisual({x:this.left,y:this.top});var o=this.container.transform.baseVal.getItem(0);o.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(o,0),this.adjustControlBox(),this._state="rotate"}else this._state="move"},e.prototype.pointerUp=function(e){var r=this.state;t.prototype.pointerUp.call(this,e),"creating"===this.state&&this.width<10&&this.height<10?(this.width=this.defaultSize.x,this.height=this.defaultSize.y):this.manipulate(e),this._state="select","creating"===r&&this.onMarkerCreated&&!1===this._suppressMarkerCreateEvent&&this.onMarkerCreated(this)},e.prototype.moveVisual=function(t){this.visual.style.transform="translate("+t.x+"px, "+t.y+"px)"},e.prototype.manipulate=function(t){var e=this.unrotatePoint(t);"creating"===this.state?this.resize(t):"move"===this.state?(this.left=this.manipulationStartLeft+(e.x-this.manipulationStartLeft)-this.offsetX,this.top=this.manipulationStartTop+(e.y-this.manipulationStartTop)-this.offsetY,this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()):"resize"===this.state?this.resize(e):"rotate"===this.state&&this.rotate(t)},e.prototype.resize=function(t){var e=this.manipulationStartLeft,r=this.manipulationStartWidth,n=this.manipulationStartTop,i=this.manipulationStartHeight;switch(this.activeGrip){case this.controlGrips.bottomLeft:case this.controlGrips.centerLeft:case this.controlGrips.topLeft:e=this.manipulationStartLeft+t.x-this.manipulationStartX,r=this.manipulationStartWidth+this.manipulationStartLeft-e;break;case this.controlGrips.bottomRight:case this.controlGrips.centerRight:case this.controlGrips.topRight:case void 0:r=this.manipulationStartWidth+t.x-this.manipulationStartX}switch(this.activeGrip){case this.controlGrips.topCenter:case this.controlGrips.topLeft:case this.controlGrips.topRight:n=this.manipulationStartTop+t.y-this.manipulationStartY,i=this.manipulationStartHeight+this.manipulationStartTop-n;break;case this.controlGrips.bottomCenter:case this.controlGrips.bottomLeft:case this.controlGrips.bottomRight:case void 0:i=this.manipulationStartHeight+t.y-this.manipulationStartY}r>=0?(this.left=e,this.width=r):(this.left=e+r,this.width=-r),i>=0?(this.top=n,this.height=i):(this.top=n+i,this.height=-i),this.setSize()},e.prototype.setSize=function(){this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()},e.prototype.rotate=function(t){if(Math.abs(t.x-this.centerX)>.1){var e=Math.sign(t.x-this.centerX);this.rotationAngle=180*Math.atan((t.y-this.centerY)/(t.x-this.centerX))/Math.PI+90*e,this.applyRotation()}},e.prototype.applyRotation=function(){var t=this.container.transform.baseVal.getItem(0);t.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(t,0)},e.prototype.rotatePoint=function(t){if(0===this.rotationAngle)return t;var e=this.container.getCTM(),r=G.createPoint(t.x,t.y);return{x:(r=r.matrixTransform(e)).x,y:r.y}},e.prototype.unrotatePoint=function(t){if(0===this.rotationAngle)return t;var e=this.container.getCTM();e=e.inverse();var r=G.createPoint(t.x,t.y);return{x:(r=r.matrixTransform(e)).x,y:r.y}},e.prototype.select=function(){t.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},e.prototype.deselect=function(){t.prototype.deselect.call(this),this.controlBox.style.display="none"},e.prototype.setupControlBox=function(){this.controlBox=G.createGroup();var t=G.createTransform();t.setTranslate(-this.CB_DISTANCE/2,-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.appendItem(t),this.container.appendChild(this.controlBox),this.controlRect=G.createRect(this.width+this.CB_DISTANCE,this.height+this.CB_DISTANCE,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"],["fill","transparent"],["pointer-events","none"]]),this.controlBox.appendChild(this.controlRect),!0!==this.globalSettings.disableRotation&&(this.rotatorGripLine=G.createLine((this.width+2*this.CB_DISTANCE)/2,this.top-this.CB_DISTANCE,(this.width+2*this.CB_DISTANCE)/2,this.top-3*this.CB_DISTANCE,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.controlBox.appendChild(this.rotatorGripLine)),this.controlGrips=new rt,this.addControlGrips(),this.controlBox.style.display="none"},e.prototype.adjustControlBox=function(){var t=this.controlBox.transform.baseVal.getItem(0);t.setTranslate(this.left-this.CB_DISTANCE/2,this.top-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.replaceItem(t,0),this.controlRect.setAttribute("width",(this.width+this.CB_DISTANCE).toString()),this.controlRect.setAttribute("height",(this.height+this.CB_DISTANCE).toString()),void 0!==this.rotatorGripLine&&(this.rotatorGripLine.setAttribute("x1",((this.width+this.CB_DISTANCE)/2).toString()),this.rotatorGripLine.setAttribute("y1",(-this.CB_DISTANCE/2).toString()),this.rotatorGripLine.setAttribute("x2",((this.width+this.CB_DISTANCE)/2).toString()),this.rotatorGripLine.setAttribute("y2",(3*-this.CB_DISTANCE).toString())),this.positionGrips()},e.prototype.addControlGrips=function(){this.controlGrips.topLeft=this.createGrip(),this.controlGrips.topCenter=this.createGrip(),this.controlGrips.topRight=this.createGrip(),this.controlGrips.centerLeft=this.createGrip(),this.controlGrips.centerRight=this.createGrip(),this.controlGrips.bottomLeft=this.createGrip(),this.controlGrips.bottomCenter=this.createGrip(),this.controlGrips.bottomRight=this.createGrip(),!0!==this.globalSettings.disableRotation&&(this.rotatorGrip=this.createGrip()),this.positionGrips()},e.prototype.createGrip=function(){var t=new nt;return t.visual.transform.baseVal.appendItem(G.createTransform()),this.controlBox.appendChild(t.visual),t},e.prototype.positionGrips=function(){var t=this.controlGrips.topLeft.GRIP_SIZE,e=-t/2,r=e,n=(this.width+this.CB_DISTANCE)/2-t/2,i=(this.height+this.CB_DISTANCE)/2-t/2,o=this.height+this.CB_DISTANCE-t/2,a=this.width+this.CB_DISTANCE-t/2;this.positionGrip(this.controlGrips.topLeft.visual,e,r),this.positionGrip(this.controlGrips.topCenter.visual,n,r),this.positionGrip(this.controlGrips.topRight.visual,a,r),this.positionGrip(this.controlGrips.centerLeft.visual,e,i),this.positionGrip(this.controlGrips.centerRight.visual,a,i),this.positionGrip(this.controlGrips.bottomLeft.visual,e,o),this.positionGrip(this.controlGrips.bottomCenter.visual,n,o),this.positionGrip(this.controlGrips.bottomRight.visual,a,o),void 0!==this.rotatorGrip&&this.positionGrip(this.rotatorGrip.visual,n,r-3*this.CB_DISTANCE)},e.prototype.positionGrip=function(t,e,r){var n=t.transform.baseVal.getItem(0);n.setTranslate(e,r),t.transform.baseVal.replaceItem(n,0)},e.prototype.hideControlBox=function(){this.controlBox.style.display="none"},e.prototype.showControlBox=function(){this.controlBox.style.display=""},e.prototype.getState=function(){return Object.assign({left:this.left,top:this.top,width:this.width,height:this.height,rotationAngle:this.rotationAngle,visualTransformMatrix:it.toITransformMatrix(this.visual.transform.baseVal.getItem(0).matrix),containerTransformMatrix:it.toITransformMatrix(this.container.transform.baseVal.getItem(0).matrix)},t.prototype.getState.call(this))},e.prototype.restoreState=function(e){t.prototype.restoreState.call(this,e);var r=e;this.left=r.left,this.top=r.top,this.width=r.width,this.height=r.height,this.rotationAngle=r.rotationAngle,this.visual.transform.baseVal.getItem(0).setMatrix(it.toSVGMatrix(this.visual.transform.baseVal.getItem(0).matrix,r.visualTransformMatrix)),this.container.transform.baseVal.getItem(0).setMatrix(it.toSVGMatrix(this.container.transform.baseVal.getItem(0).matrix,r.containerTransformMatrix))},e.prototype.scale=function(e,r){t.prototype.scale.call(this,e,r);var n=this.rotatePoint({x:this.left,y:this.top}),i=this.unrotatePoint({x:n.x*e,y:n.y*r});this.left=i.x,this.top=i.y,this.width=this.width*e,this.height=this.height*r,this.adjustControlBox()},e}(et),at=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.fillColor="transparent",i.strokeColor="transparent",i.strokeWidth=0,i.strokeDasharray="",i.opacity=1,i.setStrokeColor=i.setStrokeColor.bind(i),i.setFillColor=i.setFillColor.bind(i),i.setStrokeWidth=i.setStrokeWidth.bind(i),i.setStrokeDasharray=i.setStrokeDasharray.bind(i),i.createVisual=i.createVisual.bind(i),i}return H(e,t),e.prototype.ownsTarget=function(e){return!(!t.prototype.ownsTarget.call(this,e)&&e!==this.visual)},e.prototype.createVisual=function(){this.visual=G.createRect(1,1,[["fill",this.fillColor],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray],["opacity",this.opacity.toString()]]),this.addMarkerVisualToContainer(this.visual)},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),"new"===this.state&&(this.createVisual(),this.moveVisual(e),this._state="creating")},e.prototype.manipulate=function(e){t.prototype.manipulate.call(this,e)},e.prototype.resize=function(e){t.prototype.resize.call(this,e),this.setSize()},e.prototype.setSize=function(){t.prototype.setSize.call(this),G.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]])},e.prototype.pointerUp=function(e){t.prototype.pointerUp.call(this,e),this.setSize()},e.prototype.setStrokeColor=function(t){this.strokeColor=t,this.visual&&G.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(t),this.stateChanged()},e.prototype.setFillColor=function(t){this.fillColor=t,this.visual&&G.setAttributes(this.visual,[["fill",this.fillColor]]),this.stateChanged()},e.prototype.setStrokeWidth=function(t){this.strokeWidth=t,this.visual&&G.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},e.prototype.setStrokeDasharray=function(t){this.strokeDasharray=t,this.visual&&G.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},e.prototype.getState=function(){return Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},t.prototype.getState.call(this))},e.prototype.restoreState=function(e){var r=e;this.fillColor=r.fillColor,this.strokeColor=r.strokeColor,this.strokeWidth=r.strokeWidth,this.strokeDasharray=r.strokeDasharray,this.opacity=r.opacity,this.createVisual(),t.prototype.restoreState.call(this,e),this.setSize()},e.prototype.scale=function(e,r){t.prototype.scale.call(this,e,r),this.setSize()},e.title="Rectangle marker",e}(ot),st=function(t){function e(e,r,n,i){var o=t.call(this,e,i||'<svg viewBox="0 0 24 24"><path d="M3 17h18v-2H3v2m0 3h18v-1H3v1m0-7h18v-3H3v3m0-9v4h18V4H3z"/></svg>')||this;return o.widths=[],o.widthBoxes=[],o.widths=r,o.currentWidth=n,o.setCurrentWidth=o.setCurrentWidth.bind(o),o}return H(e,t),e.prototype.getUi=function(){var t=this,e=document.createElement("div");return e.style.display="flex",e.style.overflow="hidden",e.style.flexGrow="2",this.widths.forEach((function(r){var n=document.createElement("div");n.style.display="flex",n.style.flexGrow="2",n.style.alignItems="center",n.style.justifyContent="space-between",n.style.padding="5px",n.style.borderWidth="2px",n.style.borderStyle="solid",n.style.borderColor=r===t.currentWidth?t.uiStyleSettings.toolboxAccentColor:"transparent",n.addEventListener("click",(function(){t.setCurrentWidth(r,n)})),e.appendChild(n);var i=document.createElement("div");i.innerText=r.toString(),i.style.marginRight="5px",n.appendChild(i);var o=document.createElement("div");o.style.minHeight="20px",o.style.flexGrow="2",o.style.display="flex",o.style.alignItems="center";var a=document.createElement("hr");a.style.minWidth="20px",a.style.border="0px",a.style.borderTop=r+"px solid "+t.uiStyleSettings.toolboxColor,a.style.flexGrow="2",o.appendChild(a),n.appendChild(o),t.widthBoxes.push(n)})),e},e.prototype.setCurrentWidth=function(t,e){var r=this;this.currentWidth=t,this.widthBoxes.forEach((function(t){t.style.borderColor=t===e?r.uiStyleSettings.toolboxAccentColor:"transparent"})),this.onWidthChanged&&this.onWidthChanged(this.currentWidth)},e}($),At=function(t){function e(e,r,n,i){var o=t.call(this,e,i||'<svg viewBox="0 0 24 24"><path d="M3 16h5v-2H3v2m6.5 0h5v-2h-5v2m6.5 0h5v-2h-5v2M3 20h2v-2H3v2m4 0h2v-2H7v2m4 0h2v-2h-2v2m4 0h2v-2h-2v2m4 0h2v-2h-2v2M3 12h8v-2H3v2m10 0h8v-2h-8v2M3 4v4h18V4H3z"/></svg>')||this;return o.styles=[],o.styleBoxes=[],o.styles=r,o.currentStyle=n,o.setCurrentStyle=o.setCurrentStyle.bind(o),o}return H(e,t),e.prototype.getUi=function(){var t=this,e=document.createElement("div");return e.style.display="flex",e.style.overflow="hidden",e.style.flexGrow="2",this.styles.forEach((function(r){var n=document.createElement("div");n.style.display="flex",n.style.alignItems="center",n.style.justifyContent="space-between",n.style.padding="5px",n.style.borderWidth="2px",n.style.borderStyle="solid",n.style.overflow="hidden",n.style.maxWidth=100/t.styles.length-5+"%",n.style.borderColor=r===t.currentStyle?t.uiStyleSettings.toolboxAccentColor:"transparent",n.addEventListener("click",(function(){t.setCurrentStyle(r,n)})),e.appendChild(n);var i=document.createElement("div");i.style.minHeight="20px",i.style.flexGrow="2",i.style.overflow="hidden";var o='<svg width="100" height="20">\n <line x1="0" y1="10" x2="100" y2="10" stroke="'+t.uiStyleSettings.toolboxColor+'" stroke-width="3" '+(""!==r?'stroke-dasharray="'+r+'"':"")+" />\n </svg>";i.innerHTML=o,n.appendChild(i),t.styleBoxes.push(n)})),e},e.prototype.setCurrentStyle=function(t,e){var r=this;this.currentStyle=t,this.styleBoxes.forEach((function(t){t.style.borderColor=t===e?r.uiStyleSettings.toolboxAccentColor:"transparent"})),this.onStyleChanged&&this.onStyleChanged(this.currentStyle)},e}($),lt=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.strokeColor=n.defaultColor,i.strokeWidth=n.defaultStrokeWidth,i.strokeDasharray=n.defaultStrokeDasharray,i.strokePanel=new tt("Line color",n.defaultColorSet,n.defaultColor),i.strokePanel.onColorChanged=i.setStrokeColor,i.strokeWidthPanel=new st("Line width",n.defaultStrokeWidths,n.defaultStrokeWidth),i.strokeWidthPanel.onWidthChanged=i.setStrokeWidth,i.strokeStylePanel=new At("Line style",n.defaultStrokeDasharrays,n.defaultStrokeDasharray),i.strokeStylePanel.onStyleChanged=i.setStrokeDasharray,i}return H(e,t),Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=t.prototype.getState.call(this);return r.typeName=e.typeName,r},e.typeName="FrameMarker",e.title="Frame marker",e.icon='<svg viewBox="0 0 24 24"><path d="M4 6v13h16V6H4m14 11H6V8h12v9z"/></svg>',e}(at),ct=function(){this.defaultColorSet=["#EF4444","#10B981","#2563EB","#FFFF00","#7C3AED","#F472B6","#000000","#FFFFFF"],this.defaultColor=this.defaultColorSet[0],this.defaultFillColor=this.defaultColorSet[0],this.defaultStrokeColor=this.defaultColorSet[7],this.defaultHighlightColor=this.defaultColorSet[3],this.defaultStrokeWidth=3,this.defaultStrokeDasharray="",this.defaultHighlightOpacity=.5,this.defaultFontFamily="Helvetica, Arial, sans-serif",this.defaultStrokeWidths=[1,2,3,5,10],this.defaultStrokeDasharrays=["","3","12 3","9 6 3 6"],this.defaultOpacitySteps=[.1,.25,.5,.75,1],this.displayMode="inline",this.defaultFontFamilies=['Times, "Times New Roman", serif',"Helvetica, Arial, sans-serif",'Courier, "Courier New", monospace',"cursive","fantasy"],this.popupMargin=30,this.newFreehandMarkerOnPointerUp=!1,this.defaultColorsFollowCurrentColors=!1,this.freehandPixelRatio=1,this.disableRotation=!1},ut=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.x1=0,i.y1=0,i.x2=0,i.y2=0,i.defaultLength=50,i.manipulationStartX=0,i.manipulationStartY=0,i.manipulationStartX1=0,i.manipulationStartY1=0,i.manipulationStartX2=0,i.manipulationStartY2=0,i.setupControlBox(),i}return H(e,t),e.prototype.ownsTarget=function(e){return!!t.prototype.ownsTarget.call(this,e)||!(!this.grip1.ownsTarget(e)&&!this.grip2.ownsTarget(e))},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),this.manipulationStartX=e.x,this.manipulationStartY=e.y,"new"===this.state&&(this.x1=e.x,this.y1=e.y,this.x2=e.x,this.y2=e.y),this.manipulationStartX1=this.x1,this.manipulationStartY1=this.y1,this.manipulationStartX2=this.x2,this.manipulationStartY2=this.y2,"new"!==this.state&&(this.select(),this.grip1.ownsTarget(r)?this.activeGrip=this.grip1:this.grip2.ownsTarget(r)?this.activeGrip=this.grip2:this.activeGrip=void 0,this.activeGrip?this._state="resize":this._state="move")},e.prototype.pointerUp=function(e){var r=this.state;t.prototype.pointerUp.call(this,e),"creating"===this.state&&Math.abs(this.x1-this.x2)<10&&Math.abs(this.y1-this.y2)<10?(this.x2=this.x1+this.defaultLength,this.adjustVisual(),this.adjustControlBox()):this.manipulate(e),this._state="select","creating"===r&&this.onMarkerCreated&&this.onMarkerCreated(this)},e.prototype.adjustVisual=function(){},e.prototype.manipulate=function(t){"creating"===this.state?this.resize(t):"move"===this.state?(this.x1=this.manipulationStartX1+t.x-this.manipulationStartX,this.y1=this.manipulationStartY1+t.y-this.manipulationStartY,this.x2=this.manipulationStartX2+t.x-this.manipulationStartX,this.y2=this.manipulationStartY2+t.y-this.manipulationStartY,this.adjustVisual(),this.adjustControlBox()):"resize"===this.state&&this.resize(t)},e.prototype.resize=function(t){switch(this.activeGrip){case this.grip1:this.x1=t.x,this.y1=t.y;break;case this.grip2:case void 0:this.x2=t.x,this.y2=t.y}this.adjustVisual(),this.adjustControlBox()},e.prototype.select=function(){t.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},e.prototype.deselect=function(){t.prototype.deselect.call(this),this.controlBox.style.display="none"},e.prototype.setupControlBox=function(){this.controlBox=G.createGroup(),this.container.appendChild(this.controlBox),this.addControlGrips(),this.controlBox.style.display="none"},e.prototype.adjustControlBox=function(){this.positionGrips()},e.prototype.addControlGrips=function(){this.grip1=this.createGrip(),this.grip2=this.createGrip(),this.positionGrips()},e.prototype.createGrip=function(){var t=new nt;return t.visual.transform.baseVal.appendItem(G.createTransform()),this.controlBox.appendChild(t.visual),t},e.prototype.positionGrips=function(){var t=this.grip1.GRIP_SIZE;this.positionGrip(this.grip1.visual,this.x1-t/2,this.y1-t/2),this.positionGrip(this.grip2.visual,this.x2-t/2,this.y2-t/2)},e.prototype.positionGrip=function(t,e,r){var n=t.transform.baseVal.getItem(0);n.setTranslate(e,r),t.transform.baseVal.replaceItem(n,0)},e.prototype.getState=function(){return Object.assign({x1:this.x1,y1:this.y1,x2:this.x2,y2:this.y2},t.prototype.getState.call(this))},e.prototype.restoreState=function(e){t.prototype.restoreState.call(this,e);var r=e;this.x1=r.x1,this.y1=r.y1,this.x2=r.x2,this.y2=r.y2},e.prototype.scale=function(e,r){t.prototype.scale.call(this,e,r),this.x1=this.x1*e,this.y1=this.y1*r,this.x2=this.x2*e,this.y2=this.y2*r,this.adjustVisual(),this.adjustControlBox()},e}(et),ht=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.strokeColor="transparent",i.strokeWidth=0,i.strokeDasharray="",i.setStrokeColor=i.setStrokeColor.bind(i),i.setStrokeWidth=i.setStrokeWidth.bind(i),i.setStrokeDasharray=i.setStrokeDasharray.bind(i),i.strokeColor=n.defaultColor,i.strokeWidth=n.defaultStrokeWidth,i.strokeDasharray=n.defaultStrokeDasharray,i.strokePanel=new tt("Line color",n.defaultColorSet,n.defaultColor),i.strokePanel.onColorChanged=i.setStrokeColor,i.strokeWidthPanel=new st("Line width",n.defaultStrokeWidths,n.defaultStrokeWidth),i.strokeWidthPanel.onWidthChanged=i.setStrokeWidth,i.strokeStylePanel=new At("Line style",n.defaultStrokeDasharrays,n.defaultStrokeDasharray),i.strokeStylePanel.onStyleChanged=i.setStrokeDasharray,i}return H(e,t),e.prototype.ownsTarget=function(e){return!(!t.prototype.ownsTarget.call(this,e)&&e!==this.visual&&e!==this.selectorLine&&e!==this.visibleLine)},e.prototype.createVisual=function(){this.visual=G.createGroup(),this.selectorLine=G.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()]]),this.visibleLine=G.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.visual.appendChild(this.selectorLine),this.visual.appendChild(this.visibleLine),this.addMarkerVisualToContainer(this.visual)},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),"new"===this.state&&(this.createVisual(),this.adjustVisual(),this._state="creating")},e.prototype.adjustVisual=function(){this.selectorLine&&this.visibleLine&&(this.selectorLine.setAttribute("x1",this.x1.toString()),this.selectorLine.setAttribute("y1",this.y1.toString()),this.selectorLine.setAttribute("x2",this.x2.toString()),this.selectorLine.setAttribute("y2",this.y2.toString()),this.visibleLine.setAttribute("x1",this.x1.toString()),this.visibleLine.setAttribute("y1",this.y1.toString()),this.visibleLine.setAttribute("x2",this.x2.toString()),this.visibleLine.setAttribute("y2",this.y2.toString()),G.setAttributes(this.visibleLine,[["stroke",this.strokeColor]]),G.setAttributes(this.visibleLine,[["stroke-width",this.strokeWidth.toString()]]),G.setAttributes(this.visibleLine,[["stroke-dasharray",this.strokeDasharray.toString()]]))},e.prototype.setStrokeColor=function(t){this.strokeColor=t,this.adjustVisual(),this.colorChanged(t)},e.prototype.setStrokeWidth=function(t){this.strokeWidth=t,this.adjustVisual()},e.prototype.setStrokeDasharray=function(t){this.strokeDasharray=t,this.adjustVisual(),this.stateChanged()},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray},t.prototype.getState.call(this));return r.typeName=e.typeName,r},e.prototype.restoreState=function(e){t.prototype.restoreState.call(this,e);var r=e;this.strokeColor=r.strokeColor,this.strokeWidth=r.strokeWidth,this.strokeDasharray=r.strokeDasharray,this.createVisual(),this.adjustVisual()},e.typeName="LineMarker",e.title="Line marker",e.icon='<svg viewBox="0 0 24 24"><path d="M19 13H5v-2h14v2z"/></svg>',e}(ut),dt=function(t){function e(e,r,n,i){var o=t.call(this,e,i||'<svg viewBox="0 0 24 24"><path d="M17 8h3v12h1v1h-4v-1h1v-3h-4l-1.5 3H14v1h-4v-1h1l6-12m1 1l-3.5 7H18V9M5 3h5c1.11 0 2 .89 2 2v11H9v-5H6v5H3V5c0-1.11.89-2 2-2m1 2v4h3V5H6z"/></svg>')||this;return o.fonts=[],o.fontBoxes=[],o.fonts=r,o.currentFont=n,o.setCurrentFont=o.setCurrentFont.bind(o),o}return H(e,t),e.prototype.getUi=function(){var t=this,e=document.createElement("div");return e.style.overflow="hidden",e.style.flexGrow="2",this.fonts.forEach((function(r){var n=document.createElement("div");n.style.display="inline-block",n.style.alignItems="center",n.style.justifyContent="space-between",n.style.padding="5px",n.style.borderWidth="2px",n.style.borderStyle="solid",n.style.overflow="hidden",n.style.maxWidth=100/t.fonts.length-5+"%",n.style.borderColor=r===t.currentFont?t.uiStyleSettings.toolboxAccentColor:"transparent",n.addEventListener("click",(function(){t.setCurrentFont(r,n)})),e.appendChild(n);var i=document.createElement("div");i.style.display="flex",i.style.minHeight="20px",i.style.flexGrow="2",i.style.fontFamily=r,i.style.overflow="hidden";var o=document.createElement("div");o.style.whiteSpace="nowrap",o.style.overflow="hidden",o.style.textOverflow="ellipsis",o.innerHTML="The quick brown fox jumps over the lazy dog",i.appendChild(o),n.appendChild(i),t.fontBoxes.push(n)})),e},e.prototype.setCurrentFont=function(t,e){var r=this;this.currentFont=t,this.fontBoxes.forEach((function(t){t.style.borderColor=t===e?r.uiStyleSettings.toolboxAccentColor:"transparent"})),this.onFontChanged&&this.onFontChanged(this.currentFont)},e}($),ft=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.color="transparent",i.padding=5,i.DEFAULT_TEXT="your text here",i.text=i.DEFAULT_TEXT,i.isMoved=!1,i.color=n.defaultColor,i.fontFamily=n.defaultFontFamily,i.defaultSize={x:100,y:30},i.setColor=i.setColor.bind(i),i.setFont=i.setFont.bind(i),i.renderText=i.renderText.bind(i),i.sizeText=i.sizeText.bind(i),i.textEditDivClicked=i.textEditDivClicked.bind(i),i.showTextEditor=i.showTextEditor.bind(i),i.setSize=i.setSize.bind(i),i.positionTextEditor=i.positionTextEditor.bind(i),i.colorPanel=new tt("Color",n.defaultColorSet,n.defaultColor),i.colorPanel.onColorChanged=i.setColor,i.fontFamilyPanel=new dt("Font",n.defaultFontFamilies,n.defaultFontFamily),i.fontFamilyPanel.onFontChanged=i.setFont,i}return H(e,t),e.prototype.ownsTarget=function(e){if(t.prototype.ownsTarget.call(this,e)||e===this.visual||e===this.textElement||e===this.bgRectangle)return!0;var r=!1;return this.textElement.childNodes.forEach((function(t){t===e&&(r=!0)})),r},e.prototype.createVisual=function(){this.visual=G.createGroup(),this.bgRectangle=G.createRect(1,1,[["fill","transparent"]]),this.visual.appendChild(this.bgRectangle),this.textElement=G.createText([["fill",this.color],["font-family",this.fontFamily],["font-size","16px"],["x","0"],["y","0"]]),this.textElement.transform.baseVal.appendItem(G.createTransform()),this.textElement.transform.baseVal.appendItem(G.createTransform()),this.visual.appendChild(this.textElement),this.addMarkerVisualToContainer(this.visual),this.renderText()},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),this.isMoved=!1,this.pointerDownPoint=e,this.pointerDownTimestamp=Date.now(),"new"===this.state&&(this.createVisual(),this.moveVisual(e),this._state="creating")},e.prototype.renderText=function(){var t=this;if(this.textElement){for(;this.textElement.lastChild;)this.textElement.removeChild(this.textElement.lastChild);this.text.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/).forEach((function(e){t.textElement.appendChild(G.createTSpan(""===e.trim()?" ":e.trim(),[["x","0"],["dy","1.2em"]]))})),setTimeout(this.sizeText,10)}},e.prototype.getTextScale=function(){var t=this.textElement.getBBox(),e=1;if(t.width>0&&t.height>0){var r=(1*this.width-this.width*this.padding*2/100)/t.width,n=(1*this.height-this.height*this.padding*2/100)/t.height;e=Math.min(r,n)}return e},e.prototype.getTextPosition=function(t){var e=this.textElement.getBBox(),r=0,n=0;return e.width>0&&e.height>0&&(r=(this.width-e.width*t)/2,n=this.height/2-e.height*t/2),{x:r,y:n}},e.prototype.sizeText=function(){var t=this.textElement.getBBox(),e=this.getTextScale(),r=this.getTextPosition(e);r.y-=t.y*e,navigator.userAgent.indexOf("Edge/")>-1?this.textElement.style.transform="translate("+r.x+"px, "+r.y+"px) scale("+e+", "+e+")":(this.textElement.transform.baseVal.getItem(0).setTranslate(r.x,r.y),this.textElement.transform.baseVal.getItem(1).setScale(e,e))},e.prototype.manipulate=function(e){t.prototype.manipulate.call(this,e),void 0!==this.pointerDownPoint&&(this.isMoved=Math.abs(e.x-this.pointerDownPoint.x)>5||Math.abs(e.y-this.pointerDownPoint.y)>5)},e.prototype.resize=function(e){t.prototype.resize.call(this,e),this.isMoved=!0,this.setSize(),this.sizeText()},e.prototype.setSize=function(){t.prototype.setSize.call(this),this.visual&&this.bgRectangle&&(G.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),G.setAttributes(this.bgRectangle,[["width",this.width.toString()],["height",this.height.toString()]]))},e.prototype.pointerUp=function(e){var r=this.state;"creating"===r&&(this._suppressMarkerCreateEvent=!0),t.prototype.pointerUp.call(this,e),this.setSize(),("creating"===r||!this.isMoved&&Date.now()-this.pointerDownTimestamp>500)&&this.showTextEditor(),this.pointerDownPoint=void 0},e.prototype.showTextEditor=function(){var t=this;this._state="edit",this.overlayContainer.innerHTML="",this.textEditDiv=document.createElement("div"),this.textEditDiv.style.flexGrow="2",this.textEditDiv.style.alignItems="center",this.textEditDiv.style.justifyContent="center",this.textEditDiv.style.pointerEvents="auto",this.textEditDiv.style.overflow="hidden",this.textEditor=document.createElement("div"),this.textEditor.style.position="absolute",this.textEditor.style.fontFamily=this.fontFamily,this.textEditor.style.lineHeight="1em",this.textEditor.innerText=this.text,this.textEditor.contentEditable="true",this.textEditor.style.color=this.color,this.textEditor.style.whiteSpace="pre",this.positionTextEditor(),this.textEditor.addEventListener("pointerup",(function(t){t.stopPropagation()})),this.textEditor.addEventListener("input",(function(){for(var e=Number.parseFloat(t.textEditor.style.fontSize);t.textEditor.clientWidth>=Number.parseInt(t.textEditor.style.maxWidth)&&e>.9;)e-=.1,t.textEditor.style.fontSize=Math.max(e,.9)+"em"})),this.textEditor.addEventListener("keyup",(function(t){t.cancelBubble=!0})),this.textEditor.addEventListener("paste",(function(t){if(t.clipboardData){var e=t.clipboardData.getData("text"),r=window.getSelection();if(!r.rangeCount)return!1;r.deleteFromDocument(),r.getRangeAt(0).insertNode(document.createTextNode(e)),t.preventDefault()}})),this.textEditDiv.addEventListener("pointerup",(function(){t.textEditDivClicked(t.textEditor.innerText)})),this.textEditDiv.appendChild(this.textEditor),this.overlayContainer.appendChild(this.textEditDiv),this.hideVisual(),this.textEditor.focus(),document.execCommand("selectAll")},e.prototype.positionTextEditor=function(){if("edit"===this.state)if(void 0===this.textEditor)this.showTextEditor();else{this.textElement.style.display="";var t=this.getTextScale(),e=this.rotatePoint({x:this.left+this.width/2,y:this.top+this.height/2}),r=this.textElement.getBBox(),n={x:r.width*t,y:r.height*t};e.x-=n.x/2,e.y-=n.y/2,this.textEditor.style.top=e.y+"px",this.textEditor.style.left=e.x+"px",this.textEditor.style.maxWidth=this.overlayContainer.offsetWidth-e.x+"px",this.textEditor.style.fontSize=Math.max(16*t,12)+"px",this.textElement.style.display="none"}},e.prototype.textEditDivClicked=function(t){this.text=t.trim(),this.overlayContainer.innerHTML="",this.renderText(),this.showVisual(),this._suppressMarkerCreateEvent&&(this._suppressMarkerCreateEvent=!1,this.onMarkerCreated&&this.onMarkerCreated(this)),this.stateChanged()},e.prototype.select=function(){t.prototype.select.call(this),"edit"===this.state&&this.textEditDivClicked(this.textEditor.innerText)},e.prototype.deselect=function(){"edit"===this.state&&this.textEditDivClicked(this.textEditor.innerText),t.prototype.deselect.call(this)},e.prototype.dblClick=function(e,r){t.prototype.dblClick.call(this,e,r),this.showTextEditor()},e.prototype.setColor=function(t){this.textElement&&G.setAttributes(this.textElement,[["fill",t]]),this.color=t,this.textEditor&&(this.textEditor.style.color=this.color),this.colorChanged(t)},e.prototype.setFont=function(t){this.textElement&&G.setAttributes(this.textElement,[["font-family",t]]),this.fontFamily=t,this.textEditor&&(this.textEditor.style.fontFamily=this.fontFamily),this.renderText(),this.stateChanged()},e.prototype.hideVisual=function(){this.textElement.style.display="none",this.hideControlBox()},e.prototype.showVisual=function(){"edit"===this.state&&(this._state="select"),this.textElement.style.display="",this.showControlBox()},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=Object.assign({color:this.color,fontFamily:this.fontFamily,padding:this.padding,text:this.text},t.prototype.getState.call(this));return r.typeName=e.typeName,r},e.prototype.restoreState=function(e){var r=e;this.color=r.color,this.fontFamily=r.fontFamily,this.padding=r.padding,this.text=r.text,this.createVisual(),t.prototype.restoreState.call(this,e),this.setSize()},e.prototype.scale=function(e,r){t.prototype.scale.call(this,e,r),this.setSize(),this.sizeText(),this.positionTextEditor()},e.typeName="TextMarker",e.title="Text marker",e.icon='<svg viewBox="0 0 24 24"><path d="M9.6 14L12 7.7l2.4 6.3M11 5L5.5 19h2.2l1.1-3H15l1.1 3h2.2L13 5h-2z"/></svg>',e}(ot),pt=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.color="transparent",i.lineWidth=3,i.drawing=!1,i.pixelRatio=1,i.color=n.defaultColor,i.lineWidth=n.defaultStrokeWidth,i.pixelRatio=n.freehandPixelRatio,i.setColor=i.setColor.bind(i),i.addCanvas=i.addCanvas.bind(i),i.finishCreation=i.finishCreation.bind(i),i.setLineWidth=i.setLineWidth.bind(i),i.colorPanel=new tt("Color",n.defaultColorSet,n.defaultColor),i.colorPanel.onColorChanged=i.setColor,i.lineWidthPanel=new st("Line width",n.defaultStrokeWidths,n.defaultStrokeWidth),i.lineWidthPanel.onWidthChanged=i.setLineWidth,i}return H(e,t),e.prototype.ownsTarget=function(e){return!(!t.prototype.ownsTarget.call(this,e)&&e!==this.visual&&e!==this.drawingImage)},e.prototype.createVisual=function(){this.visual=G.createGroup(),this.drawingImage=G.createImage(),this.visual.appendChild(this.drawingImage);var t=G.createTransform();this.visual.transform.baseVal.appendItem(t),this.addMarkerVisualToContainer(this.visual)},e.prototype.pointerDown=function(e,r){"new"===this.state&&(this.addCanvas(),this.createVisual(),this._state="creating"),"creating"===this.state?(this.canvasContext.strokeStyle=this.color,this.canvasContext.lineWidth=this.lineWidth,this.canvasContext.beginPath(),this.canvasContext.moveTo(e.x,e.y),this.drawing=!0):t.prototype.pointerDown.call(this,e,r)},e.prototype.manipulate=function(e){"creating"===this.state?this.drawing&&(this.canvasContext.lineTo(e.x,e.y),this.canvasContext.stroke()):t.prototype.manipulate.call(this,e)},e.prototype.resize=function(e){t.prototype.resize.call(this,e),G.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),G.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]])},e.prototype.pointerUp=function(e){"creating"===this._state?this.drawing&&(this.canvasContext.closePath(),this.drawing=!1,this.globalSettings.newFreehandMarkerOnPointerUp&&this.finishCreation()):t.prototype.pointerUp.call(this,e)},e.prototype.addCanvas=function(){this.overlayContainer.innerHTML="",this.canvasElement=document.createElement("canvas"),this.canvasElement.width=this.overlayContainer.clientWidth*this.pixelRatio,this.canvasElement.height=this.overlayContainer.clientHeight*this.pixelRatio,this.canvasContext=this.canvasElement.getContext("2d"),this.canvasContext.scale(this.pixelRatio,this.pixelRatio),this.overlayContainer.appendChild(this.canvasElement)},e.prototype.select=function(){"creating"===this.state&&this.finishCreation(),t.prototype.select.call(this)},e.prototype.deselect=function(){"creating"===this.state&&this.finishCreation(),t.prototype.deselect.call(this)},e.prototype.finishCreation=function(){for(var t=this.canvasContext.getImageData(0,0,this.canvasElement.width,this.canvasElement.height),e=[this.canvasElement.width+1,this.canvasElement.height+1,-1,-1],r=e[0],n=e[1],i=e[2],o=e[3],a=!1,s=0;s<this.canvasElement.height;s++)for(var A=0;A<this.canvasElement.width;A++)t.data[s*this.canvasElement.width*4+4*A+3]>0&&(a=!0,s<n&&(n=s),A<r&&(r=A),s>o&&(o=s),A>i&&(i=A));if(a){this.left=r/this.pixelRatio,this.top=n/this.pixelRatio,this.width=(i-r)/this.pixelRatio,this.height=(o-n)/this.pixelRatio;var l=document.createElement("canvas");l.width=i-r,l.height=o-n,l.getContext("2d").putImageData(this.canvasContext.getImageData(r,n,i-r,o-n),0,0),this.drawingImgUrl=l.toDataURL("image/png"),this.setDrawingImage(),this._state="select",this.onMarkerCreated&&this.onMarkerCreated(this)}this.overlayContainer.innerHTML=""},e.prototype.setDrawingImage=function(){G.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]]),G.setAttributes(this.drawingImage,[["href",this.drawingImgUrl]]),this.moveVisual({x:this.left,y:this.top})},e.prototype.setColor=function(t){this.color=t,this.colorChanged(t)},e.prototype.setLineWidth=function(t){this.lineWidth=t},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return"new"===this.state||"creating"===this.state?[this.colorPanel,this.lineWidthPanel]:[]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=Object.assign({drawingImgUrl:this.drawingImgUrl},t.prototype.getState.call(this));return r.typeName=e.typeName,r},e.prototype.restoreState=function(e){this.createVisual(),t.prototype.restoreState.call(this,e),this.drawingImgUrl=e.drawingImgUrl,this.setDrawingImage()},e.prototype.scale=function(e,r){t.prototype.scale.call(this,e,r),this.setDrawingImage()},e.typeName="FreehandMarker",e.title="Freehand marker",e.icon='<svg viewBox="0 0 24 24"><path d="M9.75 20.85c1.78-.7 1.39-2.63.49-3.85-.89-1.25-2.12-2.11-3.36-2.94A9.817 9.817 0 014.54 12c-.28-.33-.85-.94-.27-1.06.59-.12 1.61.46 2.13.68.91.38 1.81.82 2.65 1.34l1.01-1.7C8.5 10.23 6.5 9.32 4.64 9.05c-1.06-.16-2.18.06-2.54 1.21-.32.99.19 1.99.77 2.77 1.37 1.83 3.5 2.71 5.09 4.29.34.33.75.72.95 1.18.21.44.16.47-.31.47-1.24 0-2.79-.97-3.8-1.61l-1.01 1.7c1.53.94 4.09 2.41 5.96 1.79m11.09-15.6c.22-.22.22-.58 0-.79l-1.3-1.3a.562.562 0 00-.78 0l-1.02 1.02 2.08 2.08M11 10.92V13h2.08l6.15-6.15-2.08-2.08L11 10.92z"/></svg>',e}(ot),gt=function(t){function e(e,r,n){var i=t.call(this,e,n||'<svg viewBox="0 0 24 24"><path d="M8 14v4l-6-6 6-6v4h8V6l6 6-6 6v-4H8z"/></svg>')||this;return i.typeBoxes=[],i.currentType=r,i.setCurrentType=i.setCurrentType.bind(i),i}return H(e,t),e.prototype.getUi=function(){var t=this,e=document.createElement("div");e.style.display="flex",e.style.overflow="hidden",e.style.flexGrow="2";for(var r=function(r){var i="both";switch(r){case 0:i="both";break;case 1:i="start";break;case 2:i="end";break;case 3:i="none"}var o=document.createElement("div");if(o.style.display="flex",o.style.flexGrow="2",o.style.alignItems="center",o.style.justifyContent="space-between",o.style.padding="5px",o.style.borderWidth="2px",o.style.borderStyle="solid",o.style.borderColor=i===n.currentType?n.uiStyleSettings.toolboxAccentColor:"transparent",o.addEventListener("click",(function(){t.setCurrentType(i,o)})),e.appendChild(o),"both"===i||"start"===i){var a=document.createElement("div");a.style.display="flex",a.style.alignItems="center",a.style.minHeight="20px",a.innerHTML='<svg viewBox="0 0 10 10" width="10" height="10" xmlns="http://www.w3.org/2000/svg">\n <polygon points="0,5 10,0 10,10" fill="'+(void 0!==n.uiStyleSettings?n.uiStyleSettings.toolboxColor:"#eeeeee")+'" />\n </svg>',a.style.marginLeft="5px",o.appendChild(a)}var s=document.createElement("div");s.style.display="flex",s.style.alignItems="center",s.style.minHeight="20px",s.style.flexGrow="2";var A=document.createElement("hr");if(A.style.minWidth="20px",A.style.border="0px",A.style.borderTop="3px solid "+(void 0!==n.uiStyleSettings?n.uiStyleSettings.toolboxColor:"#eeeeee"),A.style.flexGrow="2",s.appendChild(A),o.appendChild(s),"both"===i||"end"===i){var l=document.createElement("div");l.style.display="flex",l.style.alignItems="center",l.style.minHeight="20px",l.innerHTML='<svg viewBox="0 0 10 10" width="10" height="10" xmlns="http://www.w3.org/2000/svg">\n <polygon points="0,0 10,5 0,10" fill="'+(void 0!==n.uiStyleSettings?n.uiStyleSettings.toolboxColor:"#eeeeee")+'" />\n </svg>',l.style.marginRight="5px",o.appendChild(l)}n.typeBoxes.push(o)},n=this,i=0;i<4;i++)r(i);return e},e.prototype.setCurrentType=function(t,e){var r=this;this.currentType=t,this.typeBoxes.forEach((function(t){t.style.borderColor=t===e?void 0!==r.uiStyleSettings?r.uiStyleSettings.toolboxAccentColor:"#3080c3":"transparent"})),this.onArrowTypeChanged&&this.onArrowTypeChanged(this.currentType)},e}($),mt=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.arrowType="end",i.arrowBaseHeight=10,i.arrowBaseWidth=10,i.getArrowPoints=i.getArrowPoints.bind(i),i.setArrowType=i.setArrowType.bind(i),i.arrowTypePanel=new gt("Arrow type","end"),i.arrowTypePanel.onArrowTypeChanged=i.setArrowType,i}return H(e,t),e.prototype.ownsTarget=function(e){return!(!t.prototype.ownsTarget.call(this,e)&&e!==this.arrow1&&e!==this.arrow2)},e.prototype.getArrowPoints=function(t,e){var r=this.arrowBaseWidth+2*this.strokeWidth,n=this.arrowBaseHeight+2*this.strokeWidth;return t-r/2+","+(e+n/2)+" "+t+","+(e-n/2)+" "+(t+r/2)+","+(e+n/2)},e.prototype.createTips=function(){this.arrow1=G.createPolygon(this.getArrowPoints(this.x1,this.y1),[["fill",this.strokeColor]]),this.arrow1.transform.baseVal.appendItem(G.createTransform()),this.visual.appendChild(this.arrow1),this.arrow2=G.createPolygon(this.getArrowPoints(this.x2,this.y2),[["fill",this.strokeColor]]),this.arrow2.transform.baseVal.appendItem(G.createTransform()),this.visual.appendChild(this.arrow2)},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),"creating"===this.state&&this.createTips()},e.prototype.adjustVisual=function(){if(t.prototype.adjustVisual.call(this),this.arrow1&&this.arrow2&&(this.arrow1.style.display="both"===this.arrowType||"start"===this.arrowType?"":"none",this.arrow2.style.display="both"===this.arrowType||"end"===this.arrowType?"":"none",G.setAttributes(this.arrow1,[["points",this.getArrowPoints(this.x1,this.y1)],["fill",this.strokeColor]]),G.setAttributes(this.arrow2,[["points",this.getArrowPoints(this.x2,this.y2)],["fill",this.strokeColor]]),Math.abs(this.x1-this.x2)>.1)){var e=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2),r=this.arrow1.transform.baseVal.getItem(0);r.setRotate(e,this.x1,this.y1),this.arrow1.transform.baseVal.replaceItem(r,0);var n=this.arrow2.transform.baseVal.getItem(0);n.setRotate(e+180,this.x2,this.y2),this.arrow2.transform.baseVal.replaceItem(n,0)}},e.prototype.setArrowType=function(t){this.arrowType=t,this.adjustVisual(),this.stateChanged()},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel,this.arrowTypePanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=Object.assign({arrowType:this.arrowType},t.prototype.getState.call(this));return r.typeName=e.typeName,r},e.prototype.restoreState=function(e){t.prototype.restoreState.call(this,e);var r=e;this.arrowType=r.arrowType,this.createTips(),this.adjustVisual()},e.typeName="ArrowMarker",e.title="Arrow marker",e.icon='<svg viewBox="0 0 24 24"><path d="M19 6.41L17.59 5 7 15.59V9H5v10h10v-2H8.41L19 6.41z"/></svg>',e}(ht),vt=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.fillColor=n.defaultFillColor,i.strokeWidth=0,i.fillPanel=new tt("Color",n.defaultColorSet,n.defaultFillColor),i.fillPanel.onColorChanged=i.setFillColor,i}return H(e,t),Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.fillPanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=t.prototype.getState.call(this);return r.typeName=e.typeName,r},e.typeName="CoverMarker",e.title="Cover marker",e.icon='<svg viewBox="0 0 24 24"><path d="M4 6v13h16V6H4z"/></svg>',e}(at),yt=function(t){function e(e,r,n,i){var o=t.call(this,e,i||'<svg viewBox="0 0 24 24"><path d="M17.66 8L12 2.35 6.34 8A8.02 8.02 0 004 13.64c0 2 .78 4.11 2.34 5.67a7.99 7.99 0 0011.32 0c1.56-1.56 2.34-3.67 2.34-5.67S19.22 9.56 17.66 8M6 14c0-2 .62-3.27 1.76-4.4L12 5.27l4.24 4.38C17.38 10.77 18 12 18 14H6z"/></svg>')||this;return o.opacities=[],o.opacityBoxes=[],o.opacities=r,o.currentOpacity=n,o.setCurrentOpacity=o.setCurrentOpacity.bind(o),o}return H(e,t),e.prototype.getUi=function(){var t=this,e=document.createElement("div");return e.style.display="flex",e.style.overflow="hidden",e.style.flexGrow="2",e.style.justifyContent="space-between",this.opacities.forEach((function(r){var n=document.createElement("div");n.style.display="flex",n.style.alignItems="center",n.style.justifyContent="center",n.style.padding="5px",n.style.borderWidth="2px",n.style.borderStyle="solid",n.style.borderColor=r===t.currentOpacity?t.uiStyleSettings.toolboxAccentColor:"transparent",n.addEventListener("click",(function(){t.setCurrentOpacity(r,n)})),e.appendChild(n);var i=document.createElement("div");i.innerText=100*r+"%",n.appendChild(i),t.opacityBoxes.push(n)})),e},e.prototype.setCurrentOpacity=function(t,e){var r=this;this.currentOpacity=t,this.opacityBoxes.forEach((function(t){t.style.borderColor=t===e?r.uiStyleSettings.toolboxAccentColor:"transparent"})),this.onOpacityChanged&&this.onOpacityChanged(this.currentOpacity)},e}($),wt=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.setOpacity=i.setOpacity.bind(i),i.fillColor=n.defaultHighlightColor,i.strokeWidth=0,i.opacity=n.defaultHighlightOpacity,i.fillPanel=new tt("Color",n.defaultColorSet,i.fillColor),i.fillPanel.onColorChanged=i.setFillColor,i.opacityPanel=new yt("Opacity",n.defaultOpacitySteps,i.opacity),i.opacityPanel.onOpacityChanged=i.setOpacity,i}return H(e,t),e.prototype.setOpacity=function(t){this.opacity=t,this.visual&&G.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.fillPanel,this.opacityPanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=t.prototype.getState.call(this);return r.typeName=e.typeName,r},e.typeName="HighlightMarker",e.title="Highlight marker",e.icon='<svg viewBox="0 0 24 24"><path d="M18.5 1.15c-.53 0-1.04.19-1.43.58l-5.81 5.82 5.65 5.65 5.82-5.81c.77-.78.77-2.04 0-2.83l-2.84-2.83c-.39-.39-.89-.58-1.39-.58M10.3 8.5l-5.96 5.96c-.78.78-.78 2.04.02 2.85C3.14 18.54 1.9 19.77.67 21h5.66l.86-.86c.78.76 2.03.75 2.81-.02l5.95-5.96"/></svg>',e}(vt),bt='<svg viewBox="0 0 24 24"><path d="M19 11.5s-2 2.17-2 3.5a2 2 0 002 2 2 2 0 002-2c0-1.33-2-3.5-2-3.5M5.21 10L10 5.21 14.79 10m1.77-1.06L7.62 0 6.21 1.41l2.38 2.38-5.15 5.15c-.59.56-.59 1.53 0 2.12l5.5 5.5c.29.29.68.44 1.06.44s.77-.15 1.06-.44l5.5-5.5c.59-.59.59-1.56 0-2.12z"/></svg>',Ct=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.bgColor="transparent",i.tipPosition={x:0,y:0},i.tipBase1Position={x:0,y:0},i.tipBase2Position={x:0,y:0},i.tipMoving=!1,i.color=n.defaultStrokeColor,i.bgColor=n.defaultFillColor,i.fontFamily=n.defaultFontFamily,i.defaultSize={x:100,y:30},i.setBgColor=i.setBgColor.bind(i),i.getTipPoints=i.getTipPoints.bind(i),i.positionTip=i.positionTip.bind(i),i.setTipPoints=i.setTipPoints.bind(i),i.colorPanel=new tt("Text color",n.defaultColorSet,i.color,'<svg viewBox="0 0 24 24"><path d="M9.62 12L12 5.67 14.37 12M11 3L5.5 17h2.25l1.12-3h6.25l1.13 3h2.25L13 3h-2z"/></svg>'),i.colorPanel.onColorChanged=i.setColor,i.bgColorPanel=new tt("Fill color",n.defaultColorSet,i.bgColor,bt),i.bgColorPanel.onColorChanged=i.setBgColor,i.fontFamilyPanel=new dt("Font",n.defaultFontFamilies,n.defaultFontFamily),i.fontFamilyPanel.onFontChanged=i.setFont,i.tipGrip=new nt,i.tipGrip.visual.transform.baseVal.appendItem(G.createTransform()),i.controlBox.appendChild(i.tipGrip.visual),i}return H(e,t),e.prototype.ownsTarget=function(e){return t.prototype.ownsTarget.call(this,e)||this.tipGrip.ownsTarget(e)||this.tip===e},e.prototype.createTip=function(){G.setAttributes(this.bgRectangle,[["fill",this.bgColor],["rx","10px"]]),this.tip=G.createPolygon(this.getTipPoints(),[["fill",this.bgColor]]),this.visual.appendChild(this.tip)},e.prototype.pointerDown=function(e,r){"new"===this.state&&t.prototype.pointerDown.call(this,e,r),"creating"===this.state?this.createTip():this.tipGrip.ownsTarget(r)?(this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.tipMoving=!0):t.prototype.pointerDown.call(this,e,r)},e.prototype.pointerUp=function(e){if(this.tipMoving)this.tipMoving=!1,this.isMoved=!0,t.prototype.pointerUp.call(this,e);else{var r="creating"===this.state;t.prototype.pointerUp.call(this,e),this.setTipPoints(r),this.positionTip()}},e.prototype.manipulate=function(e){if(this.tipMoving){var r=this.unrotatePoint(e);this.tipPosition={x:r.x-this.manipulationStartLeft,y:r.y-this.manipulationStartTop},this.positionTip()}else t.prototype.manipulate.call(this,e)},e.prototype.setBgColor=function(t){this.bgRectangle&&this.tip&&(G.setAttributes(this.bgRectangle,[["fill",t]]),G.setAttributes(this.tip,[["fill",t]])),this.bgColor=t,this.fillColorChanged(t)},e.prototype.getTipPoints=function(){return this.setTipPoints("creating"===this.state),this.tipBase1Position.x+","+this.tipBase1Position.y+" "+this.tipBase2Position.x+","+this.tipBase2Position.y+" "+this.tipPosition.x+","+this.tipPosition.y},e.prototype.setTipPoints=function(t){void 0===t&&(t=!1);var e=Math.min(this.height/2,15),r=this.height/5;t&&(this.tipPosition={x:e+r/2,y:this.height+20});var n=Math.atan(this.height/2/(this.width/2));this.tipPosition.x<this.width/2&&this.tipPosition.y<this.height/2?n<Math.atan((this.height/2-this.tipPosition.y)/(this.width/2-this.tipPosition.x))?(r=this.width/5,e=Math.min(this.width/2,15),this.tipBase1Position={x:e,y:0},this.tipBase2Position={x:e+r,y:0}):(this.tipBase1Position={x:0,y:e},this.tipBase2Position={x:0,y:e+r}):this.tipPosition.x>=this.width/2&&this.tipPosition.y<this.height/2?n<Math.atan((this.height/2-this.tipPosition.y)/(this.tipPosition.x-this.width/2))?(r=this.width/5,e=Math.min(this.width/2,15),this.tipBase1Position={x:this.width-e-r,y:0},this.tipBase2Position={x:this.width-e,y:0}):(this.tipBase1Position={x:this.width,y:e},this.tipBase2Position={x:this.width,y:e+r}):this.tipPosition.x>=this.width/2&&this.tipPosition.y>=this.height/2?n<Math.atan((this.tipPosition.y-this.height/2)/(this.tipPosition.x-this.width/2))?(r=this.width/5,e=Math.min(this.width/2,15),this.tipBase1Position={x:this.width-e-r,y:this.height},this.tipBase2Position={x:this.width-e,y:this.height}):(this.tipBase1Position={x:this.width,y:this.height-e-r},this.tipBase2Position={x:this.width,y:this.height-e}):n<Math.atan((this.tipPosition.y-this.height/2)/(this.width/2-this.tipPosition.x))?(r=this.width/5,e=Math.min(this.width/2,15),this.tipBase1Position={x:e,y:this.height},this.tipBase2Position={x:e+r,y:this.height}):(this.tipBase1Position={x:0,y:this.height-e},this.tipBase2Position={x:0,y:this.height-e-r})},e.prototype.resize=function(e){t.prototype.resize.call(this,e),this.positionTip()},e.prototype.positionTip=function(){G.setAttributes(this.tip,[["points",this.getTipPoints()]]);var t=this.tipGrip.visual.transform.baseVal.getItem(0);t.setTranslate(this.tipPosition.x,this.tipPosition.y),this.tipGrip.visual.transform.baseVal.replaceItem(t,0)},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.bgColorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),e.prototype.select=function(){this.positionTip(),t.prototype.select.call(this)},e.prototype.getState=function(){var r=Object.assign({bgColor:this.bgColor,tipPosition:this.tipPosition},t.prototype.getState.call(this));return r.typeName=e.typeName,r},e.prototype.restoreState=function(e){var r=e;this.bgColor=r.bgColor,this.tipPosition=r.tipPosition,t.prototype.restoreState.call(this,e),this.createTip(),this.setTipPoints()},e.prototype.scale=function(e,r){t.prototype.scale.call(this,e,r),this.tipPosition={x:this.tipPosition.x*e,y:this.tipPosition.y*r},this.positionTip()},e.typeName="CalloutMarker",e.title="Callout marker",e.icon='<svg viewBox="0 0 24 24"><path d="M4 2h16a2 2 0 012 2v12a2 2 0 01-2 2h-4l-4 4-4-4H4a2 2 0 01-2-2V4a2 2 0 012-2m0 2v12h4.83L12 19.17 15.17 16H20V4H4m2 3h12v2H6V7m0 4h10v2H6v-2z"/></svg>',e}(ft),Bt=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.fillColor="transparent",i.strokeColor="transparent",i.strokeWidth=0,i.strokeDasharray="",i.opacity=1,i.strokeColor=n.defaultColor,i.strokeWidth=n.defaultStrokeWidth,i.strokeDasharray=n.defaultStrokeDasharray,i.fillColor=n.defaultFillColor,i.setStrokeColor=i.setStrokeColor.bind(i),i.setFillColor=i.setFillColor.bind(i),i.setStrokeWidth=i.setStrokeWidth.bind(i),i.setStrokeDasharray=i.setStrokeDasharray.bind(i),i.setOpacity=i.setOpacity.bind(i),i.createVisual=i.createVisual.bind(i),i.strokePanel=new tt("Line color",j(n.defaultColorSet,["transparent"]),n.defaultColor),i.strokePanel.onColorChanged=i.setStrokeColor,i.fillPanel=new tt("Fill color",j(n.defaultColorSet,["transparent"]),i.fillColor,bt),i.fillPanel.onColorChanged=i.setFillColor,i.strokeWidthPanel=new st("Line width",n.defaultStrokeWidths,n.defaultStrokeWidth),i.strokeWidthPanel.onWidthChanged=i.setStrokeWidth,i.strokeStylePanel=new At("Line style",n.defaultStrokeDasharrays,n.defaultStrokeDasharray),i.strokeStylePanel.onStyleChanged=i.setStrokeDasharray,i.opacityPanel=new yt("Opacity",n.defaultOpacitySteps,i.opacity),i.opacityPanel.onOpacityChanged=i.setOpacity,i}return H(e,t),e.prototype.ownsTarget=function(e){return!(!t.prototype.ownsTarget.call(this,e)&&e!==this.visual)},e.prototype.createVisual=function(){this.visual=G.createEllipse(this.width/2,this.height/2,[["fill",this.fillColor],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray],["opacity",this.opacity.toString()]]),this.addMarkerVisualToContainer(this.visual)},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),"new"===this.state&&(this.createVisual(),this.moveVisual(e),this._state="creating")},e.prototype.manipulate=function(e){t.prototype.manipulate.call(this,e)},e.prototype.resize=function(e){t.prototype.resize.call(this,e),this.setSize()},e.prototype.setSize=function(){t.prototype.setSize.call(this),G.setAttributes(this.visual,[["cx",(this.width/2).toString()],["cy",(this.height/2).toString()],["rx",(this.width/2).toString()],["ry",(this.height/2).toString()]])},e.prototype.pointerUp=function(e){t.prototype.pointerUp.call(this,e),this.setSize()},e.prototype.setStrokeColor=function(t){this.strokeColor=t,this.visual&&G.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(t),this.stateChanged()},e.prototype.setFillColor=function(t){this.fillColor=t,this.visual&&G.setAttributes(this.visual,[["fill",this.fillColor]]),this.fillColorChanged(t),this.stateChanged()},e.prototype.setStrokeWidth=function(t){this.strokeWidth=t,this.visual&&G.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},e.prototype.setStrokeDasharray=function(t){this.strokeDasharray=t,this.visual&&G.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},e.prototype.setOpacity=function(t){this.opacity=t,this.visual&&G.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.fillPanel,this.strokeWidthPanel,this.strokeStylePanel,this.opacityPanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},t.prototype.getState.call(this));return r.typeName=e.typeName,r},e.prototype.restoreState=function(e){var r=e;this.fillColor=r.fillColor,this.strokeColor=r.strokeColor,this.strokeWidth=r.strokeWidth,this.strokeDasharray=r.strokeDasharray,this.opacity=r.opacity,this.createVisual(),t.prototype.restoreState.call(this,e),this.setSize()},e.prototype.scale=function(e,r){t.prototype.scale.call(this,e,r),this.setSize()},e.typeName="EllipseMarker",e.title="Ellipse marker",e.icon='<svg viewBox="0 0 24 24"><path d="M12 4C6.5 4 2 7.58 2 12s4.5 8 10 8 10-3.58 10-8-4.5-8-10-8z"/></svg>',e}(ot),xt=function(t){function e(e,r,n){return t.call(this,e,r,n)||this}return H(e,t),Object.defineProperty(e.prototype,"tipLength",{get:function(){return 10+3*this.strokeWidth},enumerable:!1,configurable:!0}),e.prototype.ownsTarget=function(e){return!(!t.prototype.ownsTarget.call(this,e)&&e!==this.tip1&&e!==this.tip2)},e.prototype.createTips=function(){this.tip1=G.createLine(this.x1-this.tipLength/2,this.y1,this.x1+this.tipLength/2,this.y1,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.tip1.transform.baseVal.appendItem(G.createTransform()),this.visual.appendChild(this.tip1),this.tip2=G.createLine(this.x2-this.tipLength/2,this.y2,this.x2+this.tipLength/2,this.y2,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.tip2.transform.baseVal.appendItem(G.createTransform()),this.visual.appendChild(this.tip2)},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),"creating"===this.state&&this.createTips()},e.prototype.adjustVisual=function(){if(t.prototype.adjustVisual.call(this),this.tip1&&this.tip2&&(G.setAttributes(this.tip1,[["x1",(this.x1-this.tipLength/2).toString()],["y1",this.y1.toString()],["x2",(this.x1+this.tipLength/2).toString()],["y2",this.y1.toString()],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),G.setAttributes(this.tip2,[["x1",(this.x2-this.tipLength/2).toString()],["y1",this.y2.toString()],["x2",(this.x2+this.tipLength/2).toString()],["y2",this.y2.toString()],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),Math.abs(this.x1-this.x2)>.1)){var e=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2),r=this.tip1.transform.baseVal.getItem(0);r.setRotate(e,this.x1,this.y1),this.tip1.transform.baseVal.replaceItem(r,0);var n=this.tip2.transform.baseVal.getItem(0);n.setRotate(e+180,this.x2,this.y2),this.tip2.transform.baseVal.replaceItem(n,0)}},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=t.prototype.getState.call(this);return r.typeName=e.typeName,r},e.prototype.restoreState=function(e){t.prototype.restoreState.call(this,e),this.createTips(),this.adjustVisual()},e.typeName="MeasurementMarker",e.title="Measurement marker",e.icon='<svg viewBox="0 0 24 24"><path d="M1.39 18.36l1.77-1.76L4.58 18l1.06-1.05-1.42-1.41 1.42-1.42 2.47 2.48 1.06-1.06-2.47-2.48 1.41-1.41 1.42 1.41L10.59 12l-1.42-1.41 1.42-1.42 2.47 2.48 1.06-1.06-2.47-2.48 1.41-1.41 1.41 1.41 1.07-1.06-1.42-1.41 1.42-1.42L18 6.7l1.07-1.06-2.47-2.48 1.76-1.77 4.25 4.25L5.64 22.61l-4.25-4.25z"/></svg>',e}(ht),Et=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.strokePanel.colors=n.defaultColorSet,i.fillColor="transparent",i}return H(e,t),Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=t.prototype.getState.call(this);return r.typeName=e.typeName,r},e.typeName="EllipseFrameMarker",e.title="Ellipse frame marker",e.icon='<svg viewBox="0 0 24 24"><path d="M12 6c4.41 0 8 2.69 8 6s-3.59 6-8 6-8-2.69-8-6 3.59-6 8-6m0-2C6.5 4 2 7.58 2 12s4.5 8 10 8 10-3.58 10-8-4.5-8-10-8z"/></svg>',e}(Bt),St=function(){function t(){this.undoStack=[],this.redoStack=[]}return Object.defineProperty(t.prototype,"isUndoPossible",{get:function(){return this.undoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRedoPossible",{get:function(){return this.redoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"undoStepCount",{get:function(){return this.undoStack.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"redoStepCount",{get:function(){return this.redoStack.length},enumerable:!1,configurable:!0}),t.prototype.addUndoStep=function(t){0!==this.undoStack.length&&JSON.stringify(this.undoStack[this.undoStack.length-1])===JSON.stringify(t)||(this.undoStack.push(t),JSON.stringify(this.lastRedoStep)!==JSON.stringify(t)&&this.redoStack.splice(0,this.redoStack.length))},t.prototype.replaceLastUndoStep=function(t){this.undoStack.length>0&&(this.undoStack[this.undoStack.length-1]=t)},t.prototype.getLastUndoStep=function(){return this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0},t.prototype.undo=function(){if(this.undoStack.length>1){var t=this.undoStack.pop();return void 0!==t&&this.redoStack.push(t),this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0}},t.prototype.redo=function(){return this.lastRedoStep=this.redoStack.pop(),this.lastRedoStep},t}(),kt=function(t){function e(e,r,n){var i=t.call(this,e,r,n)||this;return i.strokeColor="transparent",i.strokeWidth=0,i.strokeDasharray="",i.curveX=0,i.curveY=0,i.manipulationStartCurveX=0,i.manipulationStartCurveY=0,i.setStrokeColor=i.setStrokeColor.bind(i),i.setStrokeWidth=i.setStrokeWidth.bind(i),i.setStrokeDasharray=i.setStrokeDasharray.bind(i),i.positionGrips=i.positionGrips.bind(i),i.addControlGrips=i.addControlGrips.bind(i),i.adjustVisual=i.adjustVisual.bind(i),i.setupControlBox=i.setupControlBox.bind(i),i.resize=i.resize.bind(i),i.strokeColor=n.defaultColor,i.strokeWidth=n.defaultStrokeWidth,i.strokeDasharray=n.defaultStrokeDasharray,i.strokePanel=new tt("Line color",n.defaultColorSet,n.defaultColor),i.strokePanel.onColorChanged=i.setStrokeColor,i.strokeWidthPanel=new st("Line width",n.defaultStrokeWidths,n.defaultStrokeWidth),i.strokeWidthPanel.onWidthChanged=i.setStrokeWidth,i.strokeStylePanel=new At("Line style",n.defaultStrokeDasharrays,n.defaultStrokeDasharray),i.strokeStylePanel.onStyleChanged=i.setStrokeDasharray,i}return H(e,t),e.prototype.ownsTarget=function(e){return!(!t.prototype.ownsTarget.call(this,e)&&e!==this.visual&&e!==this.selectorCurve&&e!==this.visibleCurve&&!this.curveGrip.ownsTarget(e))},e.prototype.getPathD=function(){return"M "+this.x1+" "+this.y1+" Q "+this.curveX+" "+this.curveY+", "+this.x2+" "+this.y2},e.prototype.createVisual=function(){this.visual=G.createGroup(),this.selectorCurve=G.createPath(this.getPathD(),[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()],["fill","transparent"]]),this.visibleCurve=G.createPath(this.getPathD(),[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["fill","transparent"]]),this.visual.appendChild(this.selectorCurve),this.visual.appendChild(this.visibleCurve),this.addMarkerVisualToContainer(this.visual)},e.prototype.pointerDown=function(e,r){t.prototype.pointerDown.call(this,e,r),this.manipulationStartCurveX=this.curveX,this.manipulationStartCurveY=this.curveY,"new"===this.state&&(this.curveX=e.x,this.curveY=e.y),"new"===this.state?(this.createVisual(),this.adjustVisual(),this._state="creating"):this.curveGrip.ownsTarget(r)&&(this.activeGrip=this.curveGrip,this._state="resize")},e.prototype.adjustVisual=function(){this.selectorCurve&&this.visibleCurve&&(this.selectorCurve.setAttribute("d",this.getPathD()),this.visibleCurve.setAttribute("d",this.getPathD()),G.setAttributes(this.visibleCurve,[["stroke",this.strokeColor]]),G.setAttributes(this.visibleCurve,[["stroke-width",this.strokeWidth.toString()]]),G.setAttributes(this.visibleCurve,[["stroke-dasharray",this.strokeDasharray.toString()]]))},e.prototype.setupControlBox=function(){t.prototype.setupControlBox.call(this),this.curveControlLine1=G.createLine(this.x1,this.y1,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.curveControlLine2=G.createLine(this.x2,this.y2,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.controlBox.insertBefore(this.curveControlLine1,this.controlBox.firstChild),this.controlBox.insertBefore(this.curveControlLine2,this.controlBox.firstChild)},e.prototype.addControlGrips=function(){this.curveGrip=this.createGrip(),this.curveX=0,this.curveY=0,t.prototype.addControlGrips.call(this)},e.prototype.positionGrips=function(){t.prototype.positionGrips.call(this);var e=this.curveGrip.GRIP_SIZE;this.positionGrip(this.curveGrip.visual,this.curveX-e/2,this.curveY-e/2),this.curveControlLine1&&this.curveControlLine2&&(this.curveControlLine1.setAttribute("x1",this.x1.toString()),this.curveControlLine1.setAttribute("y1",this.y1.toString()),this.curveControlLine1.setAttribute("x2",this.curveX.toString()),this.curveControlLine1.setAttribute("y2",this.curveY.toString()),this.curveControlLine2.setAttribute("x1",this.x2.toString()),this.curveControlLine2.setAttribute("y1",this.y2.toString()),this.curveControlLine2.setAttribute("x2",this.curveX.toString()),this.curveControlLine2.setAttribute("y2",this.curveY.toString()))},e.prototype.manipulate=function(e){"move"===this.state&&(this.curveX=this.manipulationStartCurveX+e.x-this.manipulationStartX,this.curveY=this.manipulationStartCurveY+e.y-this.manipulationStartY),t.prototype.manipulate.call(this,e)},e.prototype.resize=function(e){this.activeGrip===this.curveGrip&&(this.curveX=e.x,this.curveY=e.y),t.prototype.resize.call(this,e),"creating"===this.state&&(this.curveX=this.x1+(this.x2-this.x1)/2,this.curveY=this.y1+(this.y2-this.y1)/2)},e.prototype.setStrokeColor=function(t){this.strokeColor=t,this.adjustVisual(),this.colorChanged(t)},e.prototype.setStrokeWidth=function(t){this.strokeWidth=t,this.adjustVisual()},e.prototype.setStrokeDasharray=function(t){this.strokeDasharray=t,this.adjustVisual()},e.prototype.scale=function(e,r){this.curveX=this.curveX*e,this.curveY=this.curveY*r,t.prototype.scale.call(this,e,r)},Object.defineProperty(e.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),e.prototype.getState=function(){var r=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,curveX:this.curveX,curveY:this.curveY},t.prototype.getState.call(this));return r.typeName=e.typeName,r},e.prototype.restoreState=function(e){t.prototype.restoreState.call(this,e);var r=e;this.strokeColor=r.strokeColor,this.strokeWidth=r.strokeWidth,this.strokeDasharray=r.strokeDasharray,this.curveX=r.curveX,this.curveY=r.curveY,this.createVisual(),this.adjustVisual()},e.typeName="CurveMarker",e.title="Curve marker",e.icon='<svg viewBox="0 0 24 24"><path d="M18.5 2A1.5 1.5 0 0120 3.5 1.5 1.5 0 0118.5 5c-.23 0-.45-.05-.65-.15l-3.69 3.7.34.45c2.19-1.26 4.76-2 7.5-2l1 .03v2.01L22 9c-2.58 0-5 .75-7 2.04A3.96 3.96 0 0111.04 15C9.75 17 9 19.42 9 22l.04 1H7.03L7 22c0-2.74.74-5.31 2-7.5l-.45-.34-3.7 3.69c.1.2.15.42.15.65A1.5 1.5 0 013.5 20 1.5 1.5 0 012 18.5 1.5 1.5 0 013.5 17c.23 0 .45.05.65.15l3.69-3.7C7.31 12.78 7 11.92 7 11a4 4 0 014-4c.92 0 1.78.31 2.45.84l3.7-3.69c-.1-.2-.15-.42-.15-.65A1.5 1.5 0 0118.5 2M11 9a2 2 0 00-2 2 2 2 0 002 2 2 2 0 002-2 2 2 0 00-2-2z"/></svg>',e}(ut),Tt=function(){function t(t,e){void 0===e&&(e=!1),this.cancelable=!1,this._defaultPrevented=!1,this.markerArea=t,this.cancelable=e}return Object.defineProperty(t.prototype,"defaultPrevented",{get:function(){return this._defaultPrevented},enumerable:!1,configurable:!0}),t.prototype.preventDefault=function(){this._defaultPrevented=!0},t}(),Ft=function(t){function e(e,r,n){var i=t.call(this,e,!1)||this;return i.dataUrl=r,i.state=n,i}return H(e,t),e}(Tt),Lt=function(t){function e(e,r,n){void 0===n&&(n=!1);var i=t.call(this,e,n)||this;return i.marker=r,i}return H(e,t),e}(Tt),It=function(){function t(){this.render=[],this.beforeclose=[],this.close=[],this.show=[],this.restorestate=[],this.statechange=[],this.markerselect=[],this.markerdeselect=[],this.markercreating=[],this.markercreate=[],this.markerbeforedelete=[],this.markerdelete=[],this.markerchange=[],this.focus=[],this.blur=[]}return t.prototype.addEventListener=function(t,e){this[t].push(e)},t.prototype.removeEventListener=function(t,e){var r=this[t].indexOf(e);r>-1&&this[t].splice(r,1)},t}(),_t=function(){function t(e){this.touchPoints=0,this._availableMarkerTypes=this.DEFAULT_MARKER_TYPES,this.mode="select",this.markers=[],this.isDragging=!1,this.renderEventListeners=[],this.closeEventListeners=[],this.settings=new ct,this._isOpen=!1,this.undoRedoManager=new St,this.renderAtNaturalSize=!1,this.renderImageType="image/png",this.renderMarkersOnly=!1,this.zoomSteps=[1,1.5,2,4],this._zoomLevel=1,this._isResizing=!1,this.prevPanPoint={x:0,y:0},this.eventListeners=new It,this._silentRenderMode=!1,this._isFocused=!1,this._instanceNo=t.instanceCounter++,this.styles=new Y(this.instanceNo),this.uiStyleSettings=this.styles.settings,this.target=e,this.targetRoot=document.body,this.width=e.clientWidth,this.height=e.clientHeight,this.styles.removeStyleSheet(),this.open=this.open.bind(this),this.setTopLeft=this.setTopLeft.bind(this),this.toolbarButtonClicked=this.toolbarButtonClicked.bind(this),this.createNewMarker=this.createNewMarker.bind(this),this.addNewMarker=this.addNewMarker.bind(this),this.markerCreated=this.markerCreated.bind(this),this.setCurrentMarker=this.setCurrentMarker.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onDblClick=this.onDblClick.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.onPointerOut=this.onPointerOut.bind(this),this.onKeyUp=this.onKeyUp.bind(this),this.overrideOverflow=this.overrideOverflow.bind(this),this.restoreOverflow=this.restoreOverflow.bind(this),this.close=this.close.bind(this),this.closeUI=this.closeUI.bind(this),this.addCloseEventListener=this.addCloseEventListener.bind(this),this.removeCloseEventListener=this.removeCloseEventListener.bind(this),this.addRenderEventListener=this.addRenderEventListener.bind(this),this.removeRenderEventListener=this.removeRenderEventListener.bind(this),this.clientToLocalCoordinates=this.clientToLocalCoordinates.bind(this),this.onWindowResize=this.onWindowResize.bind(this),this.deleteSelectedMarker=this.deleteSelectedMarker.bind(this),this.setWindowHeight=this.setWindowHeight.bind(this),this.removeMarker=this.removeMarker.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this),this.onPopupTargetResize=this.onPopupTargetResize.bind(this),this.showNotesEditor=this.showNotesEditor.bind(this),this.hideNotesEditor=this.hideNotesEditor.bind(this),this.stepZoom=this.stepZoom.bind(this),this.focus=this.focus.bind(this),this.blur=this.blur.bind(this),this.markerStateChanged=this.markerStateChanged.bind(this),this.switchToSelectMode=this.switchToSelectMode.bind(this),this.addDefs=this.addDefs.bind(this),this.addDefsToImage=this.addDefsToImage.bind(this)}return Object.defineProperty(t.prototype,"ALL_MARKER_TYPES",{get:function(){return[lt,pt,mt,ft,Et,Bt,wt,Ct,xt,vt,ht,kt]},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"DEFAULT_MARKER_TYPES",{get:function(){return[lt,pt,mt,ft,Bt,wt,Ct]},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"BASIC_MARKER_TYPES",{get:function(){return[lt,pt,mt,ft,wt]},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"availableMarkerTypes",{get:function(){return this._availableMarkerTypes},set:function(t){var e=this;this._availableMarkerTypes.splice(0),t.forEach((function(t){if("string"==typeof t){var r=e.ALL_MARKER_TYPES.find((function(e){return e.typeName===t}));void 0!==r&&e._availableMarkerTypes.push(r)}else e._availableMarkerTypes.push(t)}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentMarker",{get:function(){return this._currentMarker},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isOpen",{get:function(){return this._isOpen},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isUndoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isUndoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRedoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isRedoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"zoomLevel",{get:function(){return this._zoomLevel},set:function(t){this._zoomLevel=t,this.editorCanvas&&this.contentDiv&&(this.editorCanvas.style.transform="scale("+this._zoomLevel+")",this.contentDiv.scrollTo({left:(this.editorCanvas.clientWidth*this._zoomLevel-this.contentDiv.clientWidth)/2,top:(this.editorCanvas.clientHeight*this._zoomLevel-this.contentDiv.clientHeight)/2}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"instanceNo",{get:function(){return this._instanceNo},enumerable:!1,configurable:!0}),t.prototype.open=function(){this.setupResizeObserver(),this.setEditingTarget(),this.setTopLeft(),this.initMarkerCanvas(),this.initOverlay(),this.attachEvents(),"popup"===this.settings.displayMode&&this.onPopupTargetResize(),V.isLicensed||this.addLogo(),this._isOpen=!0,this._isFocused=!0},t.prototype.show=function(){var t=this;void 0===this.styles.styleSheetRoot&&void 0!==W.styleSheetRoot&&(this.styles.styleSheetRoot=W.styleSheetRoot),this.setWindowHeight(),this.showUI(),this.open(),this.eventListeners.show.forEach((function(e){return e(new Tt(t))}))},t.prototype.render=function(){return N(this,void 0,void 0,(function(){var t;return K(this,(function(e){switch(e.label){case 0:return this.setCurrentMarker(),(t=new z).naturalSize=this.renderAtNaturalSize,t.imageType=this.renderImageType,t.imageQuality=this.renderImageQuality,t.markersOnly=this.renderMarkersOnly,t.width=this.renderWidth,t.height=this.renderHeight,[4,t.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 1:return e.sent(),[4,t.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 2:return[2,e.sent()]}}))}))},t.prototype.close=function(t){var e=this;if(void 0===t&&(t=!1),this.isOpen){var r=!1;t||this.eventListeners.beforeclose.forEach((function(t){var n=new Tt(e,!0);t(n),n.defaultPrevented&&(r=!0)})),r||(this.coverDiv&&this.closeUI(),this.targetObserver&&this.targetObserver.unobserve(this.target),"popup"===this.settings.displayMode&&window.removeEventListener("resize",this.setWindowHeight),this.eventListeners.close.forEach((function(t){return t(new Tt(e))})),this.detachEvents(),this._isOpen=!1)}},t.prototype.addMarkersToToolbar=function(){for(var t,e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];(t=this._availableMarkerTypes).push.apply(t,e)},t.prototype.addRenderEventListener=function(t){this.addEventListener("render",(function(e){t(e.dataUrl,e.state)}))},t.prototype.removeRenderEventListener=function(t){},t.prototype.addCloseEventListener=function(t){this.addEventListener("close",(function(){t()}))},t.prototype.removeCloseEventListener=function(t){},t.prototype.setupResizeObserver=function(){var t=this;"inline"===this.settings.displayMode?window.ResizeObserver&&(this.targetObserver=new ResizeObserver((function(){t.resize(t.target.clientWidth,t.target.clientHeight)})),this.targetObserver.observe(this.target)):"popup"===this.settings.displayMode&&(window.ResizeObserver&&(this.targetObserver=new ResizeObserver((function(){return t.onPopupTargetResize()})),this.targetObserver.observe(this.editorCanvas)),window.addEventListener("resize",this.setWindowHeight))},t.prototype.onPopupTargetResize=function(){var t=1*this.target.clientWidth/this.target.clientHeight,e=this.editorCanvas.clientWidth/t>this.editorCanvas.clientHeight?this.editorCanvas.clientHeight*t:this.editorCanvas.clientWidth,r=e<this.editorCanvas.clientWidth?this.editorCanvas.clientHeight:this.editorCanvas.clientWidth/t;this.resize(e,r)},t.prototype.setWindowHeight=function(){this.windowHeight=window.innerHeight},t.prototype.resize=function(t,e){this._isResizing=!0;var r=t/this.imageWidth,n=e/this.imageHeight;this.imageWidth=Math.round(t),this.imageHeight=Math.round(e),this.target instanceof HTMLImageElement&&this.editingTarget instanceof HTMLImageElement&&(this.editingTarget.src=this.target.src),this.editingTarget.width=this.imageWidth,this.editingTarget.height=this.imageHeight,this.editingTarget.style.width=this.imageWidth+"px",this.editingTarget.style.height=this.imageHeight+"px",this.markerImage.setAttribute("width",this.imageWidth.toString()),this.markerImage.setAttribute("height",this.imageHeight.toString()),this.markerImage.setAttribute("viewBox","0 0 "+this.imageWidth.toString()+" "+this.imageHeight.toString()),this.markerImageHolder.style.width=this.imageWidth+"px",this.markerImageHolder.style.height=this.imageHeight+"px",this.overlayContainer.style.width=this.imageWidth+"px",this.overlayContainer.style.height=this.imageHeight+"px","popup"!==this.settings.displayMode?this.coverDiv.style.width=this.imageWidth.toString()+"px":(this.setTopLeft(),this.positionMarkerImage()),void 0!==this.toolbar&&this.toolbar.adjustLayout(),this.positionLogo(),this.scaleMarkers(r,n),this._isResizing=!1},t.prototype.scaleMarkers=function(t,e){var r,n=this;this._currentMarker&&this._currentMarker instanceof ft?this._currentMarker.scale(t,e):(r=this._currentMarker,this.setCurrentMarker()),this.markers.forEach((function(r){r!==n._currentMarker&&r.scale(t,e)})),void 0!==r&&this.setCurrentMarker(r)},t.prototype.setEditingTarget=function(){this.imageWidth=Math.round(this.target.clientWidth),this.imageHeight=Math.round(this.target.clientHeight),this.target instanceof HTMLImageElement&&this.editingTarget instanceof HTMLImageElement&&(this.editingTarget.src=this.target.src),this.editingTarget.width=this.imageWidth,this.editingTarget.height=this.imageHeight,this.editingTarget.style.width=this.imageWidth+"px",this.editingTarget.style.height=this.imageHeight+"px"},t.prototype.setTopLeft=function(){var t=this.editingTarget.getBoundingClientRect(),e=this.editorCanvas.getBoundingClientRect();this.left=t.left-e.left,this.top=t.top-e.top},t.prototype.initMarkerCanvas=function(){this.markerImageHolder=document.createElement("div"),this.markerImageHolder.style.setProperty("touch-action","pinch-zoom"),this.markerImage=document.createElementNS("http://www.w3.org/2000/svg","svg"),this.markerImage.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.markerImage.setAttribute("width",this.imageWidth.toString()),this.markerImage.setAttribute("height",this.imageHeight.toString()),this.markerImage.setAttribute("viewBox","0 0 "+this.imageWidth.toString()+" "+this.imageHeight.toString()),this.markerImage.style.pointerEvents="auto",this.markerImageHolder.style.position="absolute",this.markerImageHolder.style.width=this.imageWidth+"px",this.markerImageHolder.style.height=this.imageHeight+"px",this.markerImageHolder.style.transformOrigin="top left",this.positionMarkerImage(),this.markerImageHolder.appendChild(this.markerImage),this.editorCanvas.appendChild(this.markerImageHolder)},t.prototype.addDefs=function(){for(var t,e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];this.defs=G.createDefs(),this.addDefsToImage(),(t=this.defs).append.apply(t,e)},t.prototype.addDefsToImage=function(){this.defs&&this.markerImage.insertBefore(this.defs,this.markerImage.firstChild)},t.prototype.initOverlay=function(){this.overlayContainer=document.createElement("div"),this.overlayContainer.style.position="absolute",this.overlayContainer.style.left="0px",this.overlayContainer.style.top="0px",this.overlayContainer.style.width=this.imageWidth+"px",this.overlayContainer.style.height=this.imageHeight+"px",this.overlayContainer.style.display="flex",this.markerImageHolder.appendChild(this.overlayContainer)},t.prototype.positionMarkerImage=function(){this.markerImageHolder.style.top=this.top/this.zoomLevel+"px",this.markerImageHolder.style.left=this.left/this.zoomLevel+"px"},t.prototype.attachEvents=function(){this.markerImage.addEventListener("pointerdown",this.onPointerDown),this.markerImage.addEventListener("dblclick",this.onDblClick),this.attachWindowEvents()},t.prototype.attachWindowEvents=function(){window.addEventListener("pointermove",this.onPointerMove),window.addEventListener("pointerup",this.onPointerUp),window.addEventListener("pointercancel",this.onPointerOut),window.addEventListener("pointerout",this.onPointerOut),window.addEventListener("pointerleave",this.onPointerUp),window.addEventListener("resize",this.onWindowResize),window.addEventListener("keyup",this.onKeyUp)},t.prototype.detachEvents=function(){this.markerImage.removeEventListener("pointerdown",this.onPointerDown),this.markerImage.removeEventListener("dblclick",this.onDblClick),this.detachWindowEvents()},t.prototype.detachWindowEvents=function(){window.removeEventListener("pointermove",this.onPointerMove),window.removeEventListener("pointerup",this.onPointerUp),window.removeEventListener("pointercancel",this.onPointerOut),window.removeEventListener("pointerout",this.onPointerOut),window.removeEventListener("pointerleave",this.onPointerUp),window.removeEventListener("resize",this.onWindowResize),window.removeEventListener("keyup",this.onKeyUp)},t.prototype.addLogo=function(){this.logoUI=document.createElement("div"),this.logoUI.style.display="inline-block",this.logoUI.style.margin="0px",this.logoUI.style.padding="0px",this.logoUI.style.fill="#333333";var t=document.createElement("a");t.href="https://markerjs.com/",t.target="_blank",t.innerHTML='<svg viewBox="0 0 112 96" xmlns="http://www.w3.org/2000/svg" fill-rule="evenodd" clip-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="1.414"><path fill="#e5f20d" fill-opacity=".647" d="M0 40.386h111.96V95.62H0z"/><path d="M93.61 61.452c0 .987-.328 1.831-.987 2.53-.657.7-1.52 1.048-2.591 1.048-1.481 0-2.222-.74-2.222-2.22 0-16.617-.533-29.347-1.604-38.192-1.068-8.842-2.92-13.265-5.552-13.265-4.443 0-10.94 15.509-19.497 46.52v.124c0 .987-.328 1.831-.987 2.53-.657.7-1.52 1.048-2.592 1.048-1.48 0-2.22-.74-2.22-2.22 0-3.29.165-8.392.493-15.302.33-7.732.494-13.82.494-18.262 0-6.17-.186-10.55-.556-13.142-.37-2.591-1.172-3.887-2.406-3.887-2.796 0-6.333 5.12-10.612 15.363C38.494 34.367 34.01 46.44 29.32 60.34l-1.11 3.209a5.714 5.714 0 01-1.42 2.097c-.617.578-1.295.864-2.036.864-.987 0-1.644-.081-1.974-.247-.328-.162-.533-.656-.617-1.48-.41-4.03-.74-9.418-.987-16.165-.163-1.728-.329-4.566-.494-8.515-.822-13.901-1.562-23.3-2.221-28.196-.657-4.893-.987-7.628-.987-8.205 0-.657.33-1.44.987-2.345.659-.903 1.276-1.357 1.85-1.357 1.319 0 2.387.947 3.21 2.838.411.906.863 4.526 1.357 10.859.493 6.335.905 14.19 1.233 23.568l.617 18.88c4.527-13.983 9.216-26.673 14.068-38.068C45.65 6.686 50.093.988 54.123.988c2.715 0 4.566 1.974 5.553 5.923.987 3.949 1.481 9.667 1.481 17.152 0 3.949-.081 9.625-.247 17.029l-.123 5.676c3.373-11.762 6.725-21.634 10.057-29.615 3.331-7.979 6.685-11.97 10.056-11.97 8.475 0 12.71 18.757 12.71 56.269z" fill-rule="nonzero"/></svg>',t.title="Powered by marker.js",t.style.display="grid",t.style.alignItems="center",t.style.justifyItems="center",t.style.padding="3px",t.style.width="20px",t.style.height="20px",this.logoUI.appendChild(t),this.editorCanvas.appendChild(this.logoUI),this.logoUI.style.position="absolute",this.logoUI.style.pointerEvents="all",this.positionLogo()},t.prototype.positionLogo=function(){this.logoUI&&("right"!==this.uiStyleSettings.logoPosition?this.logoUI.style.left=this.markerImageHolder.offsetLeft+10+"px":this.logoUI.style.left=this.markerImageHolder.offsetLeft+this.markerImageHolder.offsetWidth-this.logoUI.clientWidth-10+"px",this.logoUI.style.top=this.markerImageHolder.offsetTop+this.markerImageHolder.offsetHeight-this.logoUI.clientHeight-10+"px")},t.prototype.overrideOverflow=function(){this.scrollXState=window.scrollX,this.scrollYState=window.scrollY,this.bodyOverflowState=document.body.style.overflow,window.scroll({top:0,left:0}),document.body.style.overflow="hidden"},t.prototype.restoreOverflow=function(){document.body.style.overflow=this.bodyOverflowState,window.scroll({top:this.scrollYState,left:this.scrollXState})},t.prototype.showUI=function(){switch("popup"===this.settings.displayMode&&this.overrideOverflow(),this.coverDiv=document.createElement("div"),this.coverDiv.style.visibility=this._silentRenderMode?"hidden":"visible",this.coverDiv.className=this.styles.classNamePrefixBase+" "+this.styles.classNamePrefix,this.coverDiv.style.fontSize="16px",this.coverDiv.style.userSelect="none",this.settings.displayMode){case"inline":this.coverDiv.style.position="absolute";var t=this.target.getClientRects().item(0).y>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=t+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px",this.coverDiv.style.width=this.target.offsetWidth.toString()+"px",this.coverDiv.style.zIndex=void 0!==this.uiStyleSettings.zIndex?this.uiStyleSettings.zIndex:"5";break;case"popup":this.coverDiv.style.position="absolute",this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=window.innerHeight+"px",this.coverDiv.style.backgroundColor="rgba(0, 0, 0, 0.75)",this.coverDiv.style.zIndex=void 0!==this.uiStyleSettings.zIndex?this.uiStyleSettings.zIndex:"1000",this.coverDiv.style.display="flex"}this.targetRoot.appendChild(this.coverDiv),this.uiDiv=document.createElement("div"),this.uiDiv.style.display="flex",this.uiDiv.style.flexDirection="column",this.uiDiv.style.flexGrow="2",this.uiDiv.style.margin="popup"===this.settings.displayMode?this.settings.popupMargin+"px":"0px",this.uiDiv.style.border="0px",this.coverDiv.appendChild(this.uiDiv),this.toolbar=new J(this.uiDiv,this.settings.displayMode,this._availableMarkerTypes,this.uiStyleSettings,this.styles),this.toolbar.addButtonClickListener(this.toolbarButtonClicked),this.toolbar.show(this._silentRenderMode||this.uiStyleSettings.hideToolbar?"hidden":"visible"),this.contentDiv=document.createElement("div"),this.contentDiv.style.display="flex",this.contentDiv.style.flexDirection="row",this.contentDiv.style.flexGrow="2",this.contentDiv.style.flexShrink="1","popup"===this.settings.displayMode&&(this.contentDiv.style.backgroundColor=this.uiStyleSettings.canvasBackgroundColor,this.contentDiv.style.maxHeight=this.windowHeight-2*this.settings.popupMargin-3.5*this.uiStyleSettings.toolbarHeight+"px",this.contentDiv.style.maxWidth="calc(100vw - "+2*this.settings.popupMargin+"px)"),this.contentDiv.style.overflow="auto",this.uiDiv.appendChild(this.contentDiv),this.editorCanvas=document.createElement("div"),this.editorCanvas.style.flexGrow="2",this.editorCanvas.style.flexShrink="1",this.editorCanvas.style.position="relative",this.editorCanvas.style.overflow="hidden",this.editorCanvas.style.display="flex","popup"===this.settings.displayMode&&(this.editorCanvas.style.alignItems="center",this.editorCanvas.style.justifyContent="center"),this.editorCanvas.style.pointerEvents="none",this.editorCanvas.style.transformOrigin="left top",this.editorCanvas.style.transform="scale("+this.zoomLevel+")",this.contentDiv.appendChild(this.editorCanvas),this.editingTarget=this.target instanceof HTMLImageElement?document.createElement("img"):document.createElement("canvas"),this.target.getClientRects().item(0).y<this.styles.settings.toolbarHeight&&(this.editingTarget.style.marginTop=this.target.offsetTop-this.styles.settings.toolbarHeight+"px"),this.editorCanvas.appendChild(this.editingTarget),this.toolbox=new Z(this.uiDiv,this.settings.displayMode,this.uiStyleSettings,this.styles),this.toolbox.show(this._silentRenderMode||this.uiStyleSettings.hideToolbox?"hidden":"visible")},t.prototype.closeUI=function(){"popup"===this.settings.displayMode&&this.restoreOverflow(),this.targetRoot.removeChild(this.coverDiv)},t.prototype.removeMarker=function(t){this.markerImage.removeChild(t.container),this.markers.indexOf(t)>-1&&this.markers.splice(this.markers.indexOf(t),1),t.dispose()},t.prototype.switchToSelectMode=function(){this.mode="select",this.hideNotesEditor(),void 0!==this._currentMarker&&("new"!==this._currentMarker.state?this._currentMarker.select():(this.removeMarker(this._currentMarker),this.setCurrentMarker(),this.markerImage.style.cursor="default"),this.addUndoStep())},t.prototype.toolbarButtonClicked=function(t,e){if("marker"===t&&void 0!==e)this.createNewMarker(e);else if("action"===t)switch(e){case"select":this.switchToSelectMode(),this.switchToSelectMode();break;case"delete":this.deleteSelectedMarker();break;case"clear":this.clear();break;case"undo":this.undo();break;case"redo":this.redo();break;case"zoom":this.stepZoom();break;case"zoom-out":this.zoomLevel=1;break;case"notes":void 0===this.notesArea?(this.switchToSelectMode(),this.zoomLevel=1,this.showNotesEditor()):this.switchToSelectMode();break;case"close":this.close();break;case"render":this.switchToSelectMode(),this.startRenderAndClose()}},t.prototype.deleteSelectedMarker=function(){var t=this;if(void 0!==this._currentMarker){var e=!1;if(this.eventListeners.markerbeforedelete.forEach((function(r){var n=new Lt(t,t._currentMarker,!0);r(n),n.defaultPrevented&&(e=!0)})),!e){var r=this._currentMarker;this._currentMarker.dispose(),this.markerImage.removeChild(this._currentMarker.container),this.markers.splice(this.markers.indexOf(this._currentMarker),1),this.setCurrentMarker(),this.addUndoStep(),this.eventListeners.markerdelete.forEach((function(e){return e(new Lt(t,r))}))}}},t.prototype.clear=function(){var t=this,e=!1;if(this.markers.length>0&&(this.eventListeners.markerbeforedelete.forEach((function(r){var n=new Lt(t,void 0,!0);r(n),n.defaultPrevented&&(e=!0)})),!e)){this.setCurrentMarker();for(var r=function(e){var r=n.markers[e];n.setCurrentMarker(n.markers[e]),n._currentMarker.dispose(),n.markerImage.removeChild(n._currentMarker.container),n.markers.splice(n.markers.indexOf(n._currentMarker),1),n.eventListeners.markerdelete.forEach((function(e){return e(new Lt(t,r))}))},n=this,i=this.markers.length-1;i>=0;i--)r(i);this.addUndoStep()}},Object.defineProperty(t.prototype,"isNotesAreaOpen",{get:function(){return void 0!==this.notesArea},enumerable:!1,configurable:!0}),t.prototype.showNotesEditor=function(){var t;void 0!==this._currentMarker&&(this.overlayContainer.innerHTML="",this.notesArea=document.createElement("textarea"),this.notesArea.className=this.uiStyleSettings.notesAreaStyleClassName,this.notesArea.style.pointerEvents="auto",this.notesArea.style.alignSelf="stretch",this.notesArea.style.width="100%",this.notesArea.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.notesArea.value=null!==(t=this._currentMarker.notes)&&void 0!==t?t:"",this.overlayContainer.appendChild(this.notesArea))},t.prototype.hideNotesEditor=function(){this.isNotesAreaOpen&&(void 0!==this._currentMarker&&(this._currentMarker.notes=""!==this.notesArea.value.trim()?this.notesArea.value:void 0),this.overlayContainer.removeChild(this.notesArea),this.notesArea=void 0)},t.prototype.selectLastMarker=function(){this.markers.length>0?this.setCurrentMarker(this.markers[this.markers.length-1]):this.setCurrentMarker()},t.prototype.addUndoStep=function(){var t=this;if(void 0===this._currentMarker||"edit"!==this._currentMarker.state){var e=this.getState(),r=this.undoRedoManager.getLastUndoStep();if(!r||r.width===e.width&&r.height===e.height){var n=this.undoRedoManager.undoStepCount;this.undoRedoManager.addUndoStep(e),n<this.undoRedoManager.undoStepCount&&this.eventListeners.statechange.forEach((function(e){return e(new Tt(t))}))}else this.undoRedoManager.replaceLastUndoStep(e),this.eventListeners.statechange.forEach((function(e){return e(new Tt(t))}))}},t.prototype.undo=function(){this.switchToSelectMode(),this.addUndoStep(),this.undoStep()},t.prototype.undoStep=function(){var t=this,e=this.undoRedoManager.undo();void 0!==e&&(this.restoreState(e),this.addDefsToImage(),this.selectLastMarker(),this.eventListeners.statechange.forEach((function(e){return e(new Tt(t))})))},t.prototype.redo=function(){this.switchToSelectMode(),this.redoStep()},t.prototype.redoStep=function(){var t=this,e=this.undoRedoManager.redo();void 0!==e&&(this.restoreState(e),this.addDefsToImage(),this.selectLastMarker(),this.eventListeners.statechange.forEach((function(e){return e(new Tt(t))})))},t.prototype.stepZoom=function(){var t=this.zoomSteps.indexOf(this.zoomLevel);this.zoomLevel=t<this.zoomSteps.length-1?this.zoomSteps[t+1]:this.zoomSteps[0]},t.prototype.panTo=function(t){this.contentDiv.scrollBy({left:this.prevPanPoint.x-t.x,top:this.prevPanPoint.y-t.y}),this.prevPanPoint=t},t.prototype.startRenderAndClose=function(){return N(this,void 0,void 0,(function(){var t,e,r=this;return K(this,(function(n){switch(n.label){case 0:return[4,this.render()];case 1:return t=n.sent(),e=this.getState(),this.eventListeners.render.forEach((function(n){return n(new Ft(r,t,e))})),this.close(!0),[2]}}))}))},t.prototype.getState=function(t){!0===t&&this.setCurrentMarker();var e={width:this.imageWidth,height:this.imageHeight,markers:[]};return this.markers.forEach((function(t){return e.markers.push(t.getState())})),e},t.prototype.restoreState=function(t){var e=this;for(this.markers.splice(0);this.markerImage.lastChild;)this.markerImage.removeChild(this.markerImage.lastChild);t.markers.forEach((function(t){var r=e._availableMarkerTypes.find((function(e){return e.typeName===t.typeName}));if(void 0!==r){var n=e.addNewMarker(r);n.restoreState(t),e.markers.push(n)}})),t.width&&t.height&&(t.width!==this.imageWidth||t.height!==this.imageHeight)&&this.scaleMarkers(this.imageWidth/t.width,this.imageHeight/t.height),this.eventListeners.restorestate.forEach((function(t){return t(new Tt(e))}))},t.prototype.addNewMarker=function(t){var e=G.createGroup();return this.markerImage.appendChild(e),new t(e,this.overlayContainer,this.settings)},t.prototype.createNewMarker=function(t){var e,r=this;(e="string"==typeof t?this._availableMarkerTypes.find((function(e){return e.typeName===t})):t)&&(this.setCurrentMarker(),this.addUndoStep(),this._currentMarker=this.addNewMarker(e),this._currentMarker.onMarkerCreated=this.markerCreated,this._currentMarker.onColorChanged=this.colorChanged,this._currentMarker.onFillColorChanged=this.fillColorChanged,this._currentMarker.onStateChanged=this.markerStateChanged,this.markerImage.style.cursor="crosshair",this.toolbar.setActiveMarkerButton(e.typeName),this.toolbox.setPanelButtons(this._currentMarker.toolboxPanels),this.eventListeners.markercreating.forEach((function(t){return t(new Lt(r,r._currentMarker))})))},t.prototype.markerCreated=function(t){var e=this;this.mode="select",this.markerImage.style.cursor="default",this.markers.push(t),this.setCurrentMarker(t),t instanceof pt&&this.settings.newFreehandMarkerOnPointerUp?this.createNewMarker(pt):this.toolbar.setSelectMode(),this.addUndoStep(),this.eventListeners.markercreate.forEach((function(t){return t(new Lt(e,e._currentMarker))}))},t.prototype.colorChanged=function(t){this.settings.defaultColorsFollowCurrentColors&&(this.settings.defaultColor=t,this.settings.defaultStrokeColor=t)},t.prototype.fillColorChanged=function(t){this.settings.defaultColorsFollowCurrentColors&&(this.settings.defaultFillColor=t)},t.prototype.markerStateChanged=function(t){var e=this;this.eventListeners.markerchange.forEach((function(r){return r(new Lt(e,t))}))},t.prototype.setCurrentMarker=function(t){var e=this;this._currentMarker!==t&&void 0!==this._currentMarker&&(this._currentMarker.deselect(),this.toolbar.setCurrentMarker(),this.toolbox.setPanelButtons([]),this._isResizing||this.eventListeners.markerdeselect.forEach((function(t){return t(new Lt(e,e._currentMarker))}))),this._currentMarker=t,void 0===this._currentMarker||this._currentMarker.isSelected||("new"!==this._currentMarker.state&&this._currentMarker.select(),this.toolbar.setCurrentMarker(this._currentMarker),this.toolbox.setPanelButtons(this._currentMarker.toolboxPanels),this._isResizing||this.eventListeners.markerselect.forEach((function(t){return t(new Lt(e,e._currentMarker))})))},t.prototype.onPointerDown=function(t){if(this._isFocused||this.focus(),this.touchPoints++,1===this.touchPoints||"touch"!==t.pointerType)if(void 0===this._currentMarker||"new"!==this._currentMarker.state&&"creating"!==this._currentMarker.state){if("select"===this.mode){var e=this.markers.find((function(e){return e.ownsTarget(t.target)}));void 0!==e?(this.setCurrentMarker(e),this.isDragging=!0,this._currentMarker.pointerDown(this.clientToLocalCoordinates(t.clientX,t.clientY),t.target)):(this.setCurrentMarker(),this.isDragging=!0,this.prevPanPoint={x:t.clientX,y:t.clientY})}}else this.isDragging=!0,this._currentMarker.pointerDown(this.clientToLocalCoordinates(t.clientX,t.clientY))},t.prototype.onDblClick=function(t){if(this._isFocused||this.focus(),"select"===this.mode){var e=this.markers.find((function(e){return e.ownsTarget(t.target)}));void 0!==e&&e!==this._currentMarker&&this.setCurrentMarker(e),void 0!==this._currentMarker?this._currentMarker.dblClick(this.clientToLocalCoordinates(t.clientX,t.clientY),t.target):this.setCurrentMarker()}},t.prototype.onPointerMove=function(t){1!==this.touchPoints&&"touch"===t.pointerType||(void 0!==this._currentMarker||this.isDragging)&&(void 0!==this._currentMarker&&"edit"===this._currentMarker.state||t.preventDefault(),void 0!==this._currentMarker?this._currentMarker.manipulate(this.clientToLocalCoordinates(t.clientX,t.clientY)):this.zoomLevel>1&&this.panTo({x:t.clientX,y:t.clientY}))},t.prototype.onPointerUp=function(t){this.touchPoints>0&&this.touchPoints--,0===this.touchPoints&&this.isDragging&&void 0!==this._currentMarker&&this._currentMarker.pointerUp(this.clientToLocalCoordinates(t.clientX,t.clientY)),this.isDragging=!1,this.addUndoStep()},t.prototype.onPointerOut=function(){this.touchPoints>0&&this.touchPoints--},t.prototype.onKeyUp=function(t){void 0===this._currentMarker||void 0!==this.notesArea||"Delete"!==t.key&&"Backspace"!==t.key||this.deleteSelectedMarker()},t.prototype.clientToLocalCoordinates=function(t,e){var r=this.markerImage.getBoundingClientRect();return{x:(t-r.left)/this.zoomLevel,y:(e-r.top)/this.zoomLevel}},t.prototype.onWindowResize=function(){this.positionUI()},t.prototype.positionUI=function(){switch(this.setTopLeft(),this.settings.displayMode){case"inline":var t=this.target.getClientRects().item(0).y>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=t+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px";break;case"popup":this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=this.windowHeight+"px",this.contentDiv.style.maxHeight=this.windowHeight-2*this.settings.popupMargin-3.5*this.styles.settings.toolbarHeight+"px"}this.positionMarkerImage(),this.positionLogo()},t.prototype.addLicenseKey=function(t){V.addKey(t)},t.prototype.addEventListener=function(t,e){this.eventListeners.addEventListener(t,e)},t.prototype.removeEventListener=function(t,e){this.eventListeners.removeEventListener(t,e)},t.prototype.renderState=function(t){this._silentRenderMode=!0,this.settings.displayMode="inline",this.isOpen||this.show(),this.restoreState(t),this.startRenderAndClose(),this._silentRenderMode=!1},Object.defineProperty(t.prototype,"isFocused",{get:function(){return this._isFocused},enumerable:!1,configurable:!0}),t.prototype.focus=function(){var t=this;this._isFocused||(this.attachWindowEvents(),this._isFocused=!0,void 0!==this._previousCurrentMarker&&this.setCurrentMarker(this._previousCurrentMarker),this.eventListeners.focus.forEach((function(e){return e(new Tt(t))})))},t.prototype.blur=function(){var t=this;this._isFocused&&(this.detachWindowEvents(),this._isFocused=!1,this._previousCurrentMarker=this._currentMarker,this.setCurrentMarker(),this.eventListeners.blur.forEach((function(e){return e(new Tt(t))})))},t.instanceCounter=0,t}(),Ut=function(t,e){return(Ut=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])})(t,e)};
|
|
|
/* **********************************
|
|
|
cropro version 1.2.0
|
|
|
@license SEE LICENSE IN LICENSE
|
|
|
|
|
|
copyright Alan Mendelevich
|
|
|
see README and LICENSE for details
|
|
|
********************************** */
|
|
|
/*! *****************************************************************************
|
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
|
purpose with or without fee is hereby granted.
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
|
***************************************************************************** */function Ot(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function r(){this.constructor=t}Ut(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}function Dt(t,e,r,n){return new(r||(r=Promise))((function(i,o){function a(t){try{A(n.next(t))}catch(t){o(t)}}function s(t){try{A(n.throw(t))}catch(t){o(t)}}function A(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(a,s)}A((n=n.apply(t,e||[])).next())}))}function Qt(t,e){var r,n,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(i=2&o[0]?n.return:o[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;switch(n=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,n=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=e.call(t,a)}catch(t){o=[6,t],n=0}finally{r=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}var Mt=function(){function t(){}return t.addKey=function(e){t.key=e},Object.defineProperty(t,"isLicensed",{get:function(){return!!t.key&&new RegExp(/^CRPR-[A-Z][0-9]{3}-[A-Z][0-9]{3}-[0-9]{4}$/,"i").test(t.key)},enumerable:!1,configurable:!0}),t}(),Rt=function(){function t(){}return t.createDefs=function(){return document.createElementNS("http://www.w3.org/2000/svg","defs")},t.setAttributes=function(t,e){for(var r=0,n=e;r<n.length;r++){var i=n[r],o=i[0],a=i[1];t.setAttribute(o,a)}},t.createRect=function(e,r,n){var i=document.createElementNS("http://www.w3.org/2000/svg","rect");return i.setAttribute("width",e.toString()),i.setAttribute("height",r.toString()),n&&t.setAttributes(i,n),i},t.createLine=function(e,r,n,i,o){var a=document.createElementNS("http://www.w3.org/2000/svg","line");return a.setAttribute("x1",e.toString()),a.setAttribute("y1",r.toString()),a.setAttribute("x2",n.toString()),a.setAttribute("y2",i.toString()),o&&t.setAttributes(a,o),a},t.createPolygon=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","polygon");return n.setAttribute("points",e),r&&t.setAttributes(n,r),n},t.createCircle=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","circle");return n.setAttribute("cx",(e/2).toString()),n.setAttribute("cy",(e/2).toString()),n.setAttribute("r",e.toString()),r&&t.setAttributes(n,r),n},t.createEllipse=function(e,r,n){var i=document.createElementNS("http://www.w3.org/2000/svg","ellipse");return i.setAttribute("cx",(e/2).toString()),i.setAttribute("cy",(r/2).toString()),i.setAttribute("rx",(e/2).toString()),i.setAttribute("ry",(r/2).toString()),n&&t.setAttributes(i,n),i},t.createGroup=function(e){var r=document.createElementNS("http://www.w3.org/2000/svg","g");return e&&t.setAttributes(r,e),r},t.createTransform=function(){return document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGTransform()},t.createMarker=function(e,r,n,i,o,a,s){var A=document.createElementNS("http://www.w3.org/2000/svg","marker");return t.setAttributes(A,[["id",e],["orient",r],["markerWidth",n.toString()],["markerHeight",i.toString()],["refX",o.toString()],["refY",a.toString()]]),A.appendChild(s),A},t.createText=function(e){var r=document.createElementNS("http://www.w3.org/2000/svg","text");return r.setAttribute("x","0"),r.setAttribute("y","0"),e&&t.setAttributes(r,e),r},t.createTSpan=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","tspan");return n.textContent=e,r&&t.setAttributes(n,r),n},t.createImage=function(e){var r=document.createElementNS("http://www.w3.org/2000/svg","image");return e&&t.setAttributes(r,e),r},t.createPoint=function(t,e){var r=document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGPoint();return r.x=t,r.y=e,r},t.createPath=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","path");return n.setAttribute("d",e),r&&t.setAttributes(n,r),n},t.createElement=function(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg",e);return r&&t.setAttributes(n,r),n},t.getHollowRectanglePath=function(t,e,r,n,i,o,a,s){return"M"+t+","+e+"V"+(e+n)+"H"+(t+r)+"V"+e+"H"+i+"V"+o+"H"+(i+a)+"V"+(o+s)+"H"+i+"V"+e+"Z"},t}(),Pt=function(){function t(t){this._classNamePrefixBase="__cropro_",this.classes=[],this.rules=[],this.settings=this.defaultSettings,this._classNamePrefix=this._classNamePrefixBase+"_"+t+"_"}return Object.defineProperty(t.prototype,"classNamePrefixBase",{get:function(){return this._classNamePrefixBase},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"classNamePrefix",{get:function(){return this._classNamePrefix},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"defaultSettings",{get:function(){return{canvasBackgroundColor:"#333333",toolbarBackgroundColor:"#111111",toolbarBackgroundHoverColor:"#333333",toolbarBackgroundActiveColor:"#282828",toolbarColor:"#eeeeee",cropShadeColor:"#ffffff",cropFrameColor:"#ffffff",gripColor:"#333333",gripFillColor:"#cccccc",toolbarHeight:40}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fadeInAnimationClassName",{get:function(){return this.classNamePrefix+"_fade_in"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fadeOutAnimationClassName",{get:function(){return this.classNamePrefix+"_fade_out"},enumerable:!1,configurable:!0}),t.prototype.addClass=function(t){return void 0===this.styleSheet&&this.addStyleSheet(),t.name=""+this.classNamePrefix+t.localName,this.classes.push(t),this.styleSheet.sheet.insertRule("."+t.name+" {"+t.style+"}",this.styleSheet.sheet.cssRules.length),t},t.prototype.addRule=function(t){void 0===this.styleSheet&&this.addStyleSheet(),this.rules.push(t),this.styleSheet.sheet.insertRule(t.selector+" {"+t.style+"}",this.styleSheet.sheet.cssRules.length)},t.prototype.addStyleSheet=function(){var t;this.styleSheet=document.createElement("style"),(null!==(t=this.styleSheetRoot)&&void 0!==t?t:document.head).appendChild(this.styleSheet),this.addRule(new Ht("."+this.classNamePrefix+" h3","font-family: sans-serif")),this.addRule(new Ht("@keyframes "+this.classNamePrefix+"_fade_in_animation_frames","\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n ")),this.addRule(new Ht("@keyframes "+this.classNamePrefix+"_fade_out_animation_frames","\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n }\n ")),this.addClass(new Nt("_fade_in","\n animation-duration: 0.3s;\n animation-name: "+this.classNamePrefix+"_fade_in_animation_frames;\n ")),this.addClass(new Nt("_fade_out","\n animation-duration: 0.3s;\n animation-name: "+this.classNamePrefix+"_fade_out_animation_frames;\n "))},t.prototype.removeStyleSheet=function(){var t;this.styleSheet&&((null!==(t=this.styleSheetRoot)&&void 0!==t?t:document.head).removeChild(this.styleSheet),this.styleSheet=void 0)},t}(),Ht=function(t,e){this.selector=t,this.style=e},Nt=function(t,e){this.localName=t,this.style=e},Kt=function(){function t(){this.blocks=[],this.display=""}return t.prototype.addButtonBlock=function(t){t.className=this.blockClassName,t.buttonClassName=this.buttonClassName,t.buttonColorsClassName=this.buttonColorsClassName,t.buttonActiveColorsClassName=this.buttonActiveColorsClassName,this.blocks.push(t)},t.prototype.addElementBlock=function(t){void 0===t.className&&(t.className=this.blockClassName),this.blocks.push(t)},t.prototype.getUI=function(){var t=document.createElement("div");return t.className=this.className+" "+this.colorsClassName+" "+this.fadeInClassName,t.style.display=this.display,this.blocks.forEach((function(e){return t.appendChild(e.getUI())})),t},t}(),jt=function(){function t(){}return t.prototype.getUI=function(){var t=document.createElement("div");if(t.className=this.className,void 0!==this.minWidth&&(t.style.minWidth=this.minWidth),void 0!==this.contentAlign)switch(this.contentAlign){case"start":t.style.justifyContent="flex-start";break;case"center":t.style.justifyContent="center";break;case"end":t.style.justifyContent="flex-end"}return t.style.whiteSpace="nowrap",t},t}(),Gt=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.buttons=[],e}return Ot(e,t),e.prototype.addButton=function(t){t.className=this.buttonClassName,t.colorsClassName=this.buttonColorsClassName,t.activeColorsClassName=this.buttonActiveColorsClassName,this.buttons.push(t)},e.prototype.getUI=function(){var e=t.prototype.getUI.call(this);return this.buttons.forEach((function(t){return e.appendChild(t.getUI())})),e},e}(jt),Vt=function(){function t(t,e){this._isActive=!1,this._isHidden=!1,this._icon=t,this.title=e,this.uiContainer=document.createElement("div"),this.adjustClassName=this.adjustClassName.bind(this)}return Object.defineProperty(t.prototype,"icon",{get:function(){return this._icon},set:function(t){this._icon=t,this.buttonContainer.innerHTML=this._icon},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isActive",{get:function(){return this._isActive},set:function(t){this._isActive=t,this.adjustClassName()},enumerable:!1,configurable:!0}),t.prototype.getUI=function(){var t=this;return this.buttonContainer=document.createElement("div"),this.buttonContainer.title=this.title,this.buttonContainer.className=this.className+" "+this.colorsClassName,this.adjustClassName(),this.buttonContainer.innerHTML=this._icon,this.onClick&&this.buttonContainer.addEventListener("click",(function(){return t.onClick()})),this.uiContainer.appendChild(this.buttonContainer),this.uiContainer.style.display=this._isHidden?"none":"inline-block",this.uiContainer},t.prototype.adjustClassName=function(){this.activeColorsClassName&&(this._isActive&&this.buttonContainer.className.indexOf(this.activeColorsClassName)<0?this.buttonContainer.className+=" "+this.activeColorsClassName:this._isActive||(this.buttonContainer.className=this.buttonContainer.className.replace(this.activeColorsClassName,"")))},t.prototype.hide=function(){this._isHidden=!0},t}(),zt=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.elements=[],e}return Ot(e,t),e.prototype.addElement=function(t){this.elements.push(t)},e.prototype.getUI=function(){var e=t.prototype.getUI.call(this);return this.elements.forEach((function(t){return e.appendChild(t)})),e},e}(jt),Wt=function(){function t(t,e){this.horizontal=t,this.vertical=e}return Object.defineProperty(t.prototype,"ratio",{get:function(){return 1*this.horizontal/this.vertical},enumerable:!1,configurable:!0}),t.prototype.getVerticalLength=function(t){return t/this.ratio},t.prototype.getHorizontalLength=function(t){return t*this.ratio},t}(),Yt=function(){function t(){}return t.getIcon=function(t,e){if(t>0&&e>0){var r=new Wt(t,e),n=r.ratio>=1?20:r.getHorizontalLength(20),i=r.ratio<1?20:r.getVerticalLength(20),o=document.createElementNS("http://www.w3.org/2000/svg","svg");o.setAttribute("xmlns","http://www.w3.org/2000/svg"),o.setAttribute("viewBox","0 0 24 24"),document.body.appendChild(o);var a=Rt.createDefs();o.appendChild(a);var s=Rt.createElement("clipPath",[["id","text-bg-clip"]]);a.appendChild(s);var A=Rt.createPath(Rt.getHollowRectanglePath((24-n)/2,(24-i)/2,n,i,(24-n)/2+2,(24-i)/2+2,n-4,i-4));o.appendChild(A);var l=Rt.createText([["x","0"],["y","0"],["font-size","7px"],["font-family","monospace"]]);l.appendChild(Rt.createTSpan(t+":"+e)),o.appendChild(l);var c=l.getBBox();Rt.setAttributes(l,[["x",((24-c.width)/2).toString()],["y",((24-c.height)/2-c.y).toString()]]);var u=Rt.createPath(Rt.getHollowRectanglePath(0,0,24,24,(24-Math.ceil(c.width))/2,(24-Math.ceil(c.height))/2,Math.ceil(c.width),Math.ceil(c.height)));return s.appendChild(u),Rt.setAttributes(A,[["clip-path","url(#text-bg-clip)"]]),document.body.removeChild(o),o.outerHTML}return'<svg viewBox="0 0 24 24"><path d="M19 12h-2v3h-3v2h5v-5M7 9h3V7H5v5h2V9m14-6H3a2 2 0 00-2 2v14a2 2 0 002 2h18a2 2 0 002-2V5a2 2 0 00-2-2m0 16H3V5h18v14z"/></svg>'},t}(),Xt=function(t){function e(e,r,n){var i=t.call(this,e,r)||this;return i.isDropdownOpen=!1,i.onClick=i.dropdownButtonClicked,i.dropdownButtons=n,i}return Ot(e,t),e.prototype.setupDropdown=function(){var t=this;this.dropdownBlock=document.createElement("div"),this.dropdownBlock.className=this.dropdownClassName+" "+this.dropdownColorsClassName,this.dropdownBlock.style.display="none",this.dropdownButtons.forEach((function(e){e.className=t.className,e.colorsClassName=t.colorsClassName,t.dropdownBlock.appendChild(e.getUI())})),this.uiContainer.appendChild(this.dropdownBlock)},e.prototype.positionDropdown=function(){this.dropdownBlock.style.left=this.uiContainer.clientLeft+"px",this.dropdownBlock.style.top=this.uiContainer.clientTop+this.uiContainer.clientHeight+"px"},e.prototype.dropdownButtonClicked=function(){void 0===this.dropdownBlock&&this.setupDropdown(),this.isDropdownOpen=!this.isDropdownOpen,this.toggleDropdown()},e.prototype.toggleDropdown=function(){this.positionDropdown(),this.dropdownBlock.style.display=this.isDropdownOpen?"inline-block":"none"},e.prototype.showDropdown=function(){this.isDropdownOpen=!0,this.toggleDropdown()},e.prototype.hideDropdown=function(){this.isDropdownOpen=!1,this.toggleDropdown()},e}(Vt),qt=function(){function t(t,e){this.GRIP_SIZE=10,this.color=t,this.fillColor=e,this.visual=Rt.createGroup(),this.visual.appendChild(Rt.createCircle(1.5*this.GRIP_SIZE,[["fill","transparent"]])),this.visual.appendChild(Rt.createCircle(this.GRIP_SIZE,[["fill",this.fillColor],["fill-opacity","0.9"],["stroke",this.color],["stroke-width","2"],["stroke-opacity","0.7"]]))}return t.prototype.ownsTarget=function(t){return t===this.visual||t===this.visual.childNodes[0]||t===this.visual.childNodes[1]},t.prototype.setCenter=function(t,e){this.visual.childNodes.forEach((function(r){return Rt.setAttributes(r,[["cx",t.toString()],["cy",e.toString()]])}))},t}(),Jt=function(){function t(t,e,r,n){this.isMoving=!1,this._isGridVisible=!0,this.numberOfGridLines=2,this.horizontalGridLines=[],this.verticalGridLines=[],this._zoomFactor=1,this.cropRectChanged=!1,this.canvasWidth=t,this.canvasHeight=e,this.margin=r,this.container=n,this.attachEvents=this.attachEvents.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.resize=this.resize.bind(this),this.adjustCropRect=this.adjustCropRect.bind(this),this.scaleCanvas=this.scaleCanvas.bind(this),this.getRescaledRect=this.getRescaledRect.bind(this)}return Object.defineProperty(t.prototype,"aspectRatio",{get:function(){return this._aspectRatio},set:function(t){this._aspectRatio=t,this.adjustCropRect(),this.setCropRectangle(this.cropRect)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isGridVisible",{get:function(){return this._isGridVisible},set:function(t){this._isGridVisible=t,this.gridContainer&&Rt.setAttributes(this.gridContainer,[["display",this._isGridVisible?"":"none"]])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"zoomFactor",{get:function(){return this._zoomFactor},set:function(t){this._zoomFactor=t,this.setCropRectangle(this.cropRect)},enumerable:!1,configurable:!0}),t.prototype.open=function(){var t=this;this.cropShadeElement=Rt.createPath("M0,0Z",[["fill",this.cropShadeColor],["fill-opacity","0.8"]]),this.container.appendChild(this.cropShadeElement),this.gridContainer=Rt.createGroup([["display",this.isGridVisible?"":"none"]]),this.container.appendChild(this.gridContainer);for(var e=0;e<this.numberOfGridLines;e++)this.horizontalGridLines.push(Rt.createLine(0,0,0,0,[["stroke",this.cropFrameColor],["stroke-width","1"],["stroke-dasharray","3 1"],["opacity","0.7"]])),this.verticalGridLines.push(Rt.createLine(0,0,0,0,[["stroke",this.cropFrameColor],["stroke-width","1"],["stroke-dasharray","3 1"],["opacity","0.7"]]));this.horizontalGridLines.forEach((function(e){return t.gridContainer.appendChild(e)})),this.verticalGridLines.forEach((function(e){return t.gridContainer.appendChild(e)})),this.cropRectElement=Rt.createRect(0,0,[["stroke",this.cropFrameColor],["stroke-width","3"],["fill","transparent"]]),this.container.appendChild(this.cropRectElement),this.topLeftGrip=new qt(this.gripColor,this.gripFillColor),this.container.appendChild(this.topLeftGrip.visual),this.topRightGrip=new qt(this.gripColor,this.gripFillColor),this.container.appendChild(this.topRightGrip.visual),this.bottomLeftGrip=new qt(this.gripColor,this.gripFillColor),this.container.appendChild(this.bottomLeftGrip.visual),this.bottomRightGrip=new qt(this.gripColor,this.gripFillColor),this.container.appendChild(this.bottomRightGrip.visual),this.attachEvents()},t.prototype.setCropRectangle=function(t){this.cropRect=t;var e=Object.assign({},this.cropRect);1!==this.zoomFactor&&(e.width=this.cropRect.width*this.zoomFactor,e.height=this.cropRect.height*this.zoomFactor,e.x=this.cropRect.height/this.cropRect.width<this.canvasHeight/this.canvasWidth?this.margin:this.margin+this.canvasWidth/2-e.width/2,e.y=this.cropRect.height/this.cropRect.width>this.canvasHeight/this.canvasWidth?this.margin:this.margin+this.canvasHeight/2-e.height/2),Rt.setAttributes(this.cropRectElement,[["x",e.x.toString()],["y",e.y.toString()],["width",e.width.toString()],["height",e.height.toString()]]);var r=e.height/(this.numberOfGridLines+1);this.horizontalGridLines.forEach((function(t,n){var i=e.y+r*(n+1);Rt.setAttributes(t,[["x1",""+e.x],["y1",""+i],["x2",""+(e.x+e.width)],["y2",""+i]])}));var n=e.width/(this.numberOfGridLines+1);this.verticalGridLines.forEach((function(t,r){var i=e.x+n*(r+1);Rt.setAttributes(t,[["x1",""+i],["y1",""+e.y],["x2",""+i],["y2",""+(e.y+e.height)]])})),Rt.setAttributes(this.cropShadeElement,[["d",Rt.getHollowRectanglePath(0,0,this.canvasWidth+2*this.margin,this.canvasHeight+2*this.margin,e.x,e.y,e.width,e.height)]]),this.topLeftGrip.setCenter(e.x,e.y),this.topRightGrip.setCenter(e.x+e.width,e.y),this.bottomLeftGrip.setCenter(e.x,e.y+e.height),this.bottomRightGrip.setCenter(e.x+e.width,e.y+e.height),this.cropRectChanged&&this.onCropChange&&(this.cropRectChanged=!1,this.onCropChange(this.cropRect)),this.cropRectChanged=!1},t.prototype.attachEvents=function(){this.container.style.touchAction="none",this.container.addEventListener("pointerdown",this.onPointerDown),this.container.addEventListener("pointermove",this.onPointerMove),this.container.addEventListener("pointerup",this.onPointerUp)},t.prototype.clientToLocalCoordinates=function(t,e){var r=this.container.getBoundingClientRect();return{x:t-r.left+this.margin,y:e-r.top+this.margin}},t.prototype.onPointerDown=function(t){this.container.setPointerCapture(t.pointerId),this.previousPoint=this.clientToLocalCoordinates(t.clientX,t.clientY),this.cropRectElement===t.target?this.isMoving=!0:this.topLeftGrip.ownsTarget(t.target)?this.activeGrip=this.topLeftGrip:this.bottomLeftGrip.ownsTarget(t.target)?this.activeGrip=this.bottomLeftGrip:this.topRightGrip.ownsTarget(t.target)?this.activeGrip=this.topRightGrip:this.bottomRightGrip.ownsTarget(t.target)&&(this.activeGrip=this.bottomRightGrip)},t.prototype.onPointerMove=function(t){if(this.isMoving)this.move(this.clientToLocalCoordinates(t.clientX,t.clientY));else if(this.activeGrip){var e=this.clientToLocalCoordinates(t.clientX,t.clientY);this.resize(e)}t.preventDefault()},t.prototype.onPointerUp=function(t){this.activeGrip=void 0,this.isMoving=!1,this.container.releasePointerCapture(t.pointerId)},t.prototype.move=function(t){var e=t.x-this.previousPoint.x,r=t.y-this.previousPoint.y;1!==this.zoomFactor&&(e=-e/this.zoomFactor,r=-r/this.zoomFactor),this.cropRect.x=Math.min(Math.max(this.margin,this.cropRect.x+e),this.canvasWidth-this.cropRect.width+this.margin),this.cropRect.y=Math.min(Math.max(this.margin,this.cropRect.y+r),this.canvasHeight-this.cropRect.height+this.margin),this.onCropChange?(this.cropRectChanged=!0,this.onCropChange(this.cropRect)):this.setCropRectangle(this.cropRect),this.previousPoint=t},t.prototype.resize=function(t){var e=Object.assign({},this.cropRect),r=t.x-this.previousPoint.x,n=t.y-this.previousPoint.y;switch(this.activeGrip){case this.bottomLeftGrip:case this.topLeftGrip:e.x+r<this.margin&&(r=this.margin-e.x),e.x+=r,e.width=this.cropRect.x+this.cropRect.width-e.x;break;case this.bottomRightGrip:case this.topRightGrip:e.width+r>this.canvasWidth*this.zoomFactor&&(r=this.canvasWidth*this.zoomFactor-e.width),e.width+=r}switch(this.activeGrip){case this.topLeftGrip:case this.topRightGrip:this.aspectRatio?(e.y=this.cropRect.y-(this.activeGrip===this.topLeftGrip?-1:1)*this.aspectRatio.getVerticalLength(r),e.height=this.aspectRatio.getVerticalLength(e.width)):(e.y+=n,e.height=this.cropRect.y+this.cropRect.height-e.y);break;case this.bottomLeftGrip:case this.bottomRightGrip:this.aspectRatio?e.height=this.aspectRatio.getVerticalLength(e.width):e.height+=n}e.width<10&&(e.x=this.cropRect.x,e.width=10),e.height<10&&(e.y=this.cropRect.y,e.height=10),this.previousPoint=t,e.x>=this.margin&&e.y>=this.margin&&e.x-this.margin+e.width<=this.canvasWidth&&e.y-this.margin+e.height<=this.canvasHeight&&(this.cropRect=e,this.onCropChange?(this.cropRectChanged=!0,this.onCropChange(this.cropRect)):this.setCropRectangle(this.cropRect))},t.prototype.adjustCropRect=function(){if(this.aspectRatio&&Math.round(this.cropRect.height)!==Math.round(this.aspectRatio.getVerticalLength(this.cropRect.width))){var t=this.cropRect.x+this.cropRect.width/2,e=this.cropRect.y+this.cropRect.height/2,r=this.aspectRatio.getHorizontalLength(this.cropRect.height),n=this.aspectRatio.getVerticalLength(this.cropRect.width);r/this.canvasWidth<n/this.canvasHeight?this.cropRect.width=r:this.cropRect.height=n,this.cropRect.width>this.canvasWidth&&(this.cropRect.height/=this.cropRect.width/this.canvasWidth,this.cropRect.width=this.canvasWidth),this.cropRect.height>this.canvasHeight&&(this.cropRect.width/=this.cropRect.height/this.canvasHeight,this.cropRect.height=this.canvasHeight),this.cropRect.x=t-this.cropRect.width/2,this.cropRect.y=e-this.cropRect.height/2,this.cropRect.x+this.cropRect.width>this.margin+this.canvasWidth&&(this.cropRect.x=this.margin+this.canvasWidth-this.cropRect.width),this.cropRect.y+this.cropRect.height>this.margin+this.canvasHeight&&(this.cropRect.y=this.margin+this.canvasHeight-this.cropRect.height),this.cropRect.x=Math.max(this.cropRect.x,this.margin),this.cropRect.y=Math.max(this.cropRect.y,this.margin)}},t.prototype.getRescaledRect=function(t,e,r,n,i,o){var a=r/t,s=n/e;return{x:(i.x-o)*a+o,y:(i.y-o)*s+o,width:i.width*a,height:i.height*s}},t.prototype.scaleCanvas=function(t,e){var r=this.getRescaledRect(this.canvasWidth,this.canvasHeight,t,e,this.cropRect,this.margin);this.canvasWidth=t,this.canvasHeight=e,this.onCropChange&&this.onCropChange(r),this.setCropRectangle(r)},t}(),Zt=function(){function t(t){this._angle=0,this.isDragging=!1,this.width=401,this.height=24,this.title=t,this.uiContainer=document.createElement("div"),this.getUI=this.getUI.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.setAngleLabel=this.setAngleLabel.bind(this),this.positionScaleShape=this.positionScaleShape.bind(this)}return Object.defineProperty(t.prototype,"angle",{get:function(){return this._angle},set:function(t){this._angle=t,this.setAngleLabel(),this.positionScaleShape()},enumerable:!1,configurable:!0}),t.prototype.getUI=function(){return this.controlContainer=document.createElement("div"),this.controlContainer.title=this.title,this.controlContainer.className=this.className+" "+this.colorsClassName,this.controlContainer.appendChild(this.getVisual()),this.controlContainer.addEventListener("pointerdown",this.onPointerDown),this.controlContainer.addEventListener("pointermove",this.onPointerMove),this.controlContainer.addEventListener("pointerup",this.onPointerUp),this.uiContainer.appendChild(this.controlContainer),this.uiContainer.style.display="inline-block",this.uiContainer.style.touchAction="none",this.setAngleLabel(),this.positionScaleShape(),this.uiContainer},t.prototype.onPointerDown=function(t){this.controlContainer.setPointerCapture(t.pointerId),this.isDragging=!0,this.previousPoint={x:t.clientX,y:t.clientY}},t.prototype.onPointerMove=function(t){this.isDragging&&(this.onAngleChange&&this.onAngleChange((t.clientX-this.previousPoint.x)/5),this.previousPoint.x=t.clientX)},t.prototype.onPointerUp=function(t){this.isDragging&&this.onAngleChange&&this.onAngleChange((t.clientX-this.previousPoint.x)/5),this.isDragging=!1,this.controlContainer.releasePointerCapture(t.pointerId)},t.prototype.setAngleLabel=function(){if(this.angleLabelText){this.angleLabelText.innerHTML=""+Math.round(this._angle);var t=this.angleLabelText.getBBox();Rt.setAttributes(this.angleLabelElement,[["x",((this.width-t.width)/2).toString()],["y",(this.height/2).toString()]])}},t.prototype.positionScaleShape=function(){if(this.scaleShape){var t=this.scaleShape.transform.baseVal.getItem(0);t.setTranslate(this._angle%5*5-25,0),this.scaleShape.transform.baseVal.replaceItem(t,0)}},t.prototype.getVisual=function(){var t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("xmlns","http://www.w3.org/2000/svg"),t.setAttribute("width",this.width+"px"),t.setAttribute("height",this.height+"px"),t.setAttribute("viewBox","0 0 "+this.width+" "+this.height),t.style.flexShrink="0",document.body.appendChild(t);for(var e="M0,"+(this.height-1)+" v"+-this.height/3+"h1v"+this.height/3,r=1;r<=this.width/5+10;r++){var n=r%5==0?this.height/3:this.height/6;e+="h4v"+-n+"h1v"+n}e+="v1H0Z",this.scaleShape=Rt.createPath(e);var i=Rt.createTransform();this.scaleShape.transform.baseVal.appendItem(i),t.appendChild(this.scaleShape),this.angleLabelElement=Rt.createText([["x","0"],["y","0"],["font-size","10px"],["font-family","monospace"]]),this.angleLabelText=Rt.createTSpan(""),this.angleLabelElement.appendChild(this.angleLabelText);var o=Rt.createTSpan("");return o.innerHTML="°",this.angleLabelElement.appendChild(o),t.appendChild(this.angleLabelElement),document.body.removeChild(t),t},t}(),$t=function(){function t(){this.naturalSize=!1,this.imageType="image/png"}return t.prototype.rasterize=function(t,e,r,n,i,o,a){var s=this;return new Promise((function(A){var l=document.createElement("canvas");l.width=t.width.baseVal.value-2*n,l.height=t.height.baseVal.value-2*n;var c=1,u=1;!0===s.naturalSize?(c=e.naturalWidth/(t.width.baseVal.value-2*n)/o,u=e.naturalHeight/(t.height.baseVal.value-2*n)/a,l.width=e.naturalWidth/o,l.height=e.naturalHeight/a):void 0!==s.width&&void 0!==s.height&&(c=s.width/r.width,u=s.height/r.height,l.width*=c,l.height*=u);var h=l.getContext("2d");h.translate(l.width/2,l.height/2),h.rotate(i*Math.PI/180),h.scale(o,a),h.translate(-l.width/2,-l.height/2),h.drawImage(e,0,0,l.width,l.height);var d=document.createElement("canvas");d.width=r.width*c,d.height=r.height*u,d.getContext("2d").putImageData(h.getImageData((r.x-n)*c,(r.y-n)*u,r.width*c,r.height*u),0,0),A(d.toDataURL(s.imageType,s.imageQuality))}))},t}(),te=function(){function t(e){this._zoomToCropEnabled=!0,this.zoomFactor=1,this.flippedHorizontally=!1,this.flippedVertically=!1,this._isGridVisible=!0,this._gridLines=2,this._rotationAngle=0,this.scaleFactor=1,this.renderEventListeners=[],this.closeEventListeners=[],this._isOpen=!1,this.CANVAS_MARGIN=20,this.renderAtNaturalSize=!1,this.renderImageType="image/png",this.displayMode="inline",this.popupMargin=30,this.toolbarHeight=40,this.aspectRatios=[{horizontal:0,vertical:0},{horizontal:4,vertical:3},{horizontal:3,vertical:2},{horizontal:16,vertical:9},{horizontal:1,vertical:1},{horizontal:3,vertical:4},{horizontal:2,vertical:3},{horizontal:9,vertical:16}],this._instanceNo=t.instanceCounter++,this.styles=new Pt(this.instanceNo),this.target=e,this.targetRoot=document.body,this.open=this.open.bind(this),this.setTopLeft=this.setTopLeft.bind(this),this.overrideOverflow=this.overrideOverflow.bind(this),this.restoreOverflow=this.restoreOverflow.bind(this),this.close=this.close.bind(this),this.closeUI=this.closeUI.bind(this),this.addCloseEventListener=this.addCloseEventListener.bind(this),this.removeCloseEventListener=this.removeCloseEventListener.bind(this),this.addRenderEventListener=this.addRenderEventListener.bind(this),this.removeRenderEventListener=this.removeRenderEventListener.bind(this),this.clientToLocalCoordinates=this.clientToLocalCoordinates.bind(this),this.onWindowResize=this.onWindowResize.bind(this),this.setWindowHeight=this.setWindowHeight.bind(this),this.rotateBy=this.rotateBy.bind(this),this.applyRotation=this.applyRotation.bind(this),this.cropRectChanged=this.cropRectChanged.bind(this),this.zoomToCrop=this.zoomToCrop.bind(this),this.unzoomFromCrop=this.unzoomFromCrop.bind(this),this.rotateLeftButtonClicked=this.rotateLeftButtonClicked.bind(this),this.rotateRightButtonClicked=this.rotateRightButtonClicked.bind(this),this.flipHorizontallyButtonClicked=this.flipHorizontallyButtonClicked.bind(this),this.flipVerticallyButtonClicked=this.flipVerticallyButtonClicked.bind(this),this.applyFlip=this.applyFlip.bind(this),this.startRenderAndClose=this.startRenderAndClose.bind(this),this.render=this.render.bind(this),this.onPopupResize=this.onPopupResize.bind(this),this.applyAspectRatio=this.applyAspectRatio.bind(this)}return Object.defineProperty(t.prototype,"instanceNo",{get:function(){return this._instanceNo},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"zoomToCropEnabled",{get:function(){return this._zoomToCropEnabled},set:function(t){this._zoomToCropEnabled=t,t?this.zoomToCrop():this.unzoomFromCrop()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isGridVisible",{get:function(){return this._isGridVisible},set:function(t){this._isGridVisible=t,this.cropLayer&&(this.cropLayer.isGridVisible=this._isGridVisible)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"gridLines",{get:function(){return this._gridLines},set:function(t){this._gridLines=t,this.cropLayer&&(this.cropLayer.numberOfGridLines=this._gridLines)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rotationAngle",{get:function(){return this._rotationAngle},set:function(t){this._rotationAngle=t,this.straightener&&(this.straightener.angle=this._rotationAngle)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"paddedImageWidth",{get:function(){return this.imageWidth+2*this.CANVAS_MARGIN},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"paddedImageHeight",{get:function(){return this.imageHeight+2*this.CANVAS_MARGIN},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isOpen",{get:function(){return this._isOpen},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"aspectRatio",{get:function(){var t;return null!==(t=this._aspectRatio)&&void 0!==t?t:this.aspectRatios[0]},set:function(t){this._aspectRatio=t},enumerable:!1,configurable:!0}),t.prototype.open=function(){this.imageWidth=Math.round(this.target.clientWidth),this.imageHeight=Math.round(this.target.clientHeight),this.setupResizeObserver(),this.initCropCanvas(),this.setEditingTarget(),this.setTopLeft(),this.initCropLayer(),this.attachEvents(),this.applyAspectRatio(),"popup"===this.displayMode&&this.onPopupResize(),this._isOpen=!0},t.prototype.show=function(){this.showUI(),this.open()},t.prototype.close=function(t){void 0===t&&(t=!1),this.isOpen&&(this.coverDiv&&this.closeUI(),this.targetObserver&&this.targetObserver.unobserve(this.target),"popup"===this.displayMode&&window.removeEventListener("resize",this.setWindowHeight),t||this.closeEventListeners.forEach((function(t){return t()})),this._isOpen=!1)},t.prototype.addRenderEventListener=function(t){this.renderEventListeners.push(t)},t.prototype.removeRenderEventListener=function(t){this.renderEventListeners.indexOf(t)>-1&&this.renderEventListeners.splice(this.renderEventListeners.indexOf(t),1)},t.prototype.addCloseEventListener=function(t){this.closeEventListeners.push(t)},t.prototype.removeCloseEventListener=function(t){this.closeEventListeners.indexOf(t)>-1&&this.closeEventListeners.splice(this.closeEventListeners.indexOf(t),1)},t.prototype.setupResizeObserver=function(){var t=this;"inline"===this.displayMode?window.ResizeObserver&&(this.targetObserver=new ResizeObserver((function(){t.resize(t.target.clientWidth,t.target.clientHeight)})),this.targetObserver.observe(this.target)):"popup"===this.displayMode&&(window.ResizeObserver&&(this.targetObserver=new ResizeObserver(this.onPopupResize),this.targetObserver.observe(this.contentDiv)),window.addEventListener("resize",this.setWindowHeight))},t.prototype.onPopupResize=function(){if(this.contentDiv.clientWidth>0&&this.contentDiv.clientHeight>0){var t=1*this.target.clientWidth/this.target.clientHeight,e=this.contentDiv.clientWidth/t>this.contentDiv.clientHeight?(this.contentDiv.clientHeight-2*this.CANVAS_MARGIN)*t:this.contentDiv.clientWidth-2*this.CANVAS_MARGIN,r=e+2*this.CANVAS_MARGIN<this.contentDiv.clientWidth?this.contentDiv.clientHeight-2*this.CANVAS_MARGIN:(this.contentDiv.clientWidth-2*this.CANVAS_MARGIN)/t;this.resize(e,r)}},t.prototype.setWindowHeight=function(){this.windowHeight=window.innerHeight},t.prototype.setEditingTargetSize=function(){this.editorCanvas.style.width=this.imageWidth+2*this.CANVAS_MARGIN+"px",this.editorCanvas.style.height=this.imageHeight+2*this.CANVAS_MARGIN+"px",Rt.setAttributes(this.editingTarget,[["width",""+this.imageWidth],["height",""+this.imageHeight]]),this.editingTarget.style.transformOrigin=this.imageWidth/2+"px "+this.imageHeight/2+"px"},t.prototype.resize=function(t,e){this.imageWidth=Math.round(t),this.imageHeight=Math.round(e),this.setEditingTargetSize(),this.cropImage.setAttribute("width",this.paddedImageWidth.toString()),this.cropImage.setAttribute("height",this.paddedImageHeight.toString()),this.cropImage.setAttribute("viewBox","0 0 "+this.paddedImageWidth.toString()+" "+this.paddedImageHeight.toString()),this.cropImageHolder.style.width=this.paddedImageWidth+"px",this.cropImageHolder.style.height=this.paddedImageHeight+"px","popup"!==this.displayMode?this.coverDiv.style.width=this.paddedImageWidth+"px":(this.setTopLeft(),this.positionCropImage()),this.cropLayer.scaleCanvas(this.imageWidth,this.imageHeight),this.applyRotation()},t.prototype.setEditingTarget=function(){var t=document.createElement("canvas");t.width=this.target.naturalWidth,t.height=this.target.naturalHeight,t.getContext("2d").drawImage(this.target,0,0,this.target.naturalWidth,this.target.naturalHeight);var e=t.toDataURL();Rt.setAttributes(this.editingTarget,[["href",e]]),this.setEditingTargetSize()},t.prototype.setTopLeft=function(){var t=this.target.getBoundingClientRect(),e=this.editorCanvas.getBoundingClientRect();this.left=t.left-e.left-this.CANVAS_MARGIN,this.top=t.top-e.top-this.CANVAS_MARGIN},t.prototype.initCropCanvas=function(){this.cropImageHolder=document.createElement("div"),this.cropImageHolder.style.setProperty("touch-action","none"),this.cropImageHolder.style.setProperty("-ms-touch-action","none"),this.cropImage=document.createElementNS("http://www.w3.org/2000/svg","svg"),this.cropImage.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.cropImage.setAttribute("width",this.paddedImageWidth.toString()),this.cropImage.setAttribute("height",this.paddedImageHeight.toString()),this.cropImage.setAttribute("viewBox","0 0 "+this.paddedImageWidth.toString()+" "+this.paddedImageHeight.toString()),this.cropImage.style.pointerEvents="auto",this.cropImageHolder.style.width=this.paddedImageWidth+"px",this.cropImageHolder.style.height=this.paddedImageHeight+"px",this.cropImageHolder.style.transformOrigin="top left",this.positionCropImage(),this.defs=Rt.createDefs(),this.cropImage.appendChild(this.defs),this.editingTarget=Rt.createImage([["href",""]]),this.editingTarget.style.transformOrigin=this.imageWidth/2+"px "+this.imageHeight/2+"px",this.editingTargetRotationContainer=Rt.createGroup(),this.editingTargetRotationScaleContainer=Rt.createGroup(),this.editingTargetRotationScaleContainer.appendChild(this.editingTarget),this.editingTargetRotationContainer.appendChild(this.editingTargetRotationScaleContainer);var t=Rt.createTransform();this.editingTargetRotationContainer.transform.baseVal.appendItem(t);var e=Rt.createTransform();this.editingTargetRotationScaleContainer.transform.baseVal.appendItem(e),this.editingTargetContainer=Rt.createGroup(),this.editingTargetContainer.style.transform="translate("+this.CANVAS_MARGIN+"px, "+this.CANVAS_MARGIN+"px)",this.editingTargetContainer.appendChild(this.editingTargetRotationContainer),this.cropImage.appendChild(this.editingTargetContainer),this.cropImageHolder.appendChild(this.cropImage),this.editorCanvas.appendChild(this.cropImageHolder)},t.prototype.positionCropImage=function(){this.cropImageHolder.style.top=this.top+"px",this.cropImageHolder.style.left=this.left+"px"},t.prototype.initCropLayer=function(){this.cropRect={x:this.CANVAS_MARGIN,y:this.CANVAS_MARGIN,width:this.imageWidth,height:this.imageHeight},this.cropLayerContainer=Rt.createGroup(),this.cropImage.appendChild(this.cropLayerContainer),this.cropLayer=new Jt(this.imageWidth,this.imageHeight,this.CANVAS_MARGIN,this.cropLayerContainer),this.cropLayer.onCropChange=this.cropRectChanged,this.cropLayer.numberOfGridLines=this.gridLines,this.cropLayer.isGridVisible=this.isGridVisible,this.cropLayer.cropShadeColor=this.styles.settings.cropShadeColor,this.cropLayer.cropFrameColor=this.styles.settings.cropFrameColor,this.cropLayer.gripColor=this.styles.settings.gripColor,this.cropLayer.gripFillColor=this.styles.settings.gripFillColor,this.cropLayer.open(),this.cropLayer.setCropRectangle(this.cropRect),this.zoomToCropEnabled&&this.zoomToCrop()},t.prototype.zoomToCrop=function(){if(this.cropRect){var t=this.cropRect.x-this.CANVAS_MARGIN+this.cropRect.width/2,e=this.cropRect.y-this.CANVAS_MARGIN+this.cropRect.height/2;this.zoomFactor=Math.min(this.imageWidth/this.cropRect.width,this.imageHeight/this.cropRect.height),this.editingTargetContainer&&this.cropLayer&&(this.editingTargetContainer.style.transformOrigin=t+"px "+e+"px",this.editingTargetContainer.style.transform="translate("+(this.imageWidth/2-t+this.CANVAS_MARGIN)+"px,"+(this.imageHeight/2-e+this.CANVAS_MARGIN)+"px) scale("+this.zoomFactor+")",this.cropLayer.zoomFactor=this.zoomFactor)}},t.prototype.unzoomFromCrop=function(){this.zoomFactor=1,this.editingTargetContainer&&this.cropLayer&&(this.editingTargetContainer.style.transformOrigin="center",this.editingTargetContainer.style.transform="translate("+this.CANVAS_MARGIN+"px, "+this.CANVAS_MARGIN+"px) scale(1)",this.cropLayer.zoomFactor=this.zoomFactor)},t.prototype.cropRectChanged=function(t){this.cropRect=t,this.zoomToCropEnabled?this.zoomToCrop():this.cropLayer.zoomFactor=1},t.prototype.attachEvents=function(){window.addEventListener("resize",this.onWindowResize)},t.prototype.overrideOverflow=function(){this.scrollXState=window.scrollX,this.scrollYState=window.scrollY,this.bodyOverflowState=document.body.style.overflow,window.scroll({top:0,left:0}),document.body.style.overflow="hidden"},t.prototype.restoreOverflow=function(){document.body.style.overflow=this.bodyOverflowState,window.scroll({top:this.scrollYState,left:this.scrollXState})},t.prototype.showUI=function(){switch(this.addStyles(),"popup"===this.displayMode&&this.overrideOverflow(),this.coverDiv=document.createElement("div"),this.coverDiv.className=this.styles.classNamePrefixBase+" "+this.styles.classNamePrefix,this.coverDiv.style.fontSize="16px",this.displayMode){case"inline":this.coverDiv.style.position="absolute";var t=this.styles.settings.hideTopToolbar?0:this.toolbarHeight,e=this.target.offsetTop>t+this.CANVAS_MARGIN?this.target.offsetTop-(t+this.CANVAS_MARGIN):0;this.coverDiv.style.top=e+"px",this.coverDiv.style.left=(this.target.offsetLeft>this.CANVAS_MARGIN?this.target.offsetLeft-this.CANVAS_MARGIN:0)+"px",this.coverDiv.style.width=this.target.offsetWidth+this.CANVAS_MARGIN+"px",this.coverDiv.style.zIndex=void 0!==this.styles.settings.zIndex?this.styles.settings.zIndex:"5";break;case"popup":this.coverDiv.style.position="absolute",this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=window.innerHeight+"px",this.coverDiv.style.backgroundColor="rgba(0, 0, 0, 0.75)",this.coverDiv.style.zIndex=void 0!==this.styles.settings.zIndex?this.styles.settings.zIndex:"1000",this.coverDiv.style.display="flex"}this.targetRoot.appendChild(this.coverDiv),this.uiDiv=document.createElement("div"),this.uiDiv.style.display="flex",this.uiDiv.style.flexDirection="column",this.uiDiv.style.flexGrow="2",this.uiDiv.style.margin="popup"===this.displayMode?this.popupMargin+"px":"0px",this.uiDiv.style.border="0px",this.coverDiv.appendChild(this.uiDiv),this.addToolbars(),this.uiDiv.appendChild(this.topToolbar.getUI()),this.contentDiv=document.createElement("div"),this.contentDiv.style.display="flex",this.contentDiv.style.alignItems="center",this.contentDiv.style.flexDirection="row",this.contentDiv.style.flexGrow="2",this.contentDiv.style.flexShrink="1",this.contentDiv.style.overflow="hidden",this.contentDiv.style.backgroundColor=this.styles.settings.canvasBackgroundColor,"popup"===this.displayMode&&(this.contentDiv.style.maxHeight="calc(100vh - "+(2*this.popupMargin+2*this.toolbarHeight)+"px)",this.contentDiv.style.maxWidth="calc(100vw - "+2*this.popupMargin+"px)"),this.uiDiv.appendChild(this.contentDiv),this.editorCanvas=document.createElement("div"),this.editorCanvas.style.flexGrow="2",this.editorCanvas.style.flexShrink="1",this.editorCanvas.style.position="relative",this.editorCanvas.style.overflow="hidden",this.editorCanvas.style.display="flex","popup"===this.displayMode&&(this.editorCanvas.style.alignItems="center",this.editorCanvas.style.justifyContent="center"),this.editorCanvas.style.pointerEvents="none",this.contentDiv.appendChild(this.editorCanvas),this.uiDiv.appendChild(this.bottomToolbar.getUI()),this.straightener.angle=this.rotationAngle},t.prototype.addToolbars=function(){this.addTopToolbar(),this.addBottomToolbar()},t.prototype.addTopToolbar=function(){var t=this;this.topToolbar=new Kt,this.topToolbar.display=this.styles.settings.hideTopToolbar?"none":"",this.topToolbar.className=this.toolbarStyleClass.name,this.topToolbar.colorsClassName=this.styles.settings.toolbarStyleColorsClassName?this.styles.settings.toolbarStyleColorsClassName:this.toolbarStyleColorsClass.name,this.topToolbar.fadeInClassName=this.styles.fadeInAnimationClassName,this.topToolbar.blockClassName=this.toolbarBlockStyleClass.name,this.topToolbar.buttonClassName=this.toolbarButtonStyleClass.name,this.topToolbar.buttonColorsClassName=this.styles.settings.toolbarButtonStyleColorsClassName?this.styles.settings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,this.topToolbar.buttonActiveColorsClassName=this.styles.settings.toolbarActiveButtonStyleColorsClassName?this.styles.settings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name;var e=new Gt;e.minWidth=3*this.toolbarHeight+"px",this.topToolbar.addButtonBlock(e);var r=[];this.aspectRatios.forEach((function(e){var n=new Vt(Yt.getIcon(e.horizontal,e.vertical),0===e.horizontal&&0===e.vertical?"FREE":e.horizontal+":"+e.vertical);n.onClick=function(){return t.ratioButtonClicked(e)},r.push(n)})),this.aspectRatioButton=new Xt(Yt.getIcon(0,0),"Aspect ratio",r),this.aspectRatioButton.dropdownClassName=this.toolbarDropdownStyleClass.name,this.aspectRatioButton.dropdownColorsClassName=this.styles.settings.toolbarDropdownStyleColorsClassName?this.styles.settings.toolbarDropdownStyleColorsClassName:this.toolbarDropdownStyleColorsClass.name,e.addButton(this.aspectRatioButton),this.aspectRatios.length<2&&this.aspectRatioButton.hide();var n=new Vt('<svg viewBox="0 0 24 24"><path d="M10 4v4h4V4h-4m6 0v4h4V4h-4m0 6v4h4v-4h-4m0 6v4h4v-4h-4m-2 4v-4h-4v4h4m-6 0v-4H4v4h4m0-6v-4H4v4h4m0-6V4H4v4h4m2 6h4v-4h-4v4M4 2h16a2 2 0 012 2v16a2 2 0 01-2 2H4c-1.08 0-2-.9-2-2V4a2 2 0 012-2z"/></svg>',"Toggle grid");n.isActive=this.isGridVisible,n.onClick=function(){t.isGridVisible=!t.isGridVisible,n.isActive=t.isGridVisible},e.addButton(n);var i=new Vt('<svg viewBox="0 0 24 24"><path d="M15.5 14l5 5-1.5 1.5-5-5v-.79l-.27-.28A6.471 6.471 0 019.5 16 6.5 6.5 0 013 9.5 6.5 6.5 0 019.5 3 6.5 6.5 0 0116 9.5c0 1.61-.59 3.09-1.57 4.23l.28.27h.79m-6 0C12 14 14 12 14 9.5S12 5 9.5 5 5 7 5 9.5 7 14 9.5 14m2.5-4h-2v2H9v-2H7V9h2V7h1v2h2v1z"/></svg>',"Zoom to selection");if(i.isActive=this.zoomToCropEnabled,i.onClick=function(){t.zoomToCropEnabled=!t.zoomToCropEnabled,i.isActive=t.zoomToCropEnabled},e.addButton(i),!Mt.isLicensed){var o=new zt;this.topToolbar.addElementBlock(o);var a=document.createElement("div");a.className=this.topToolbar.buttonClassName+" "+this.topToolbar.buttonColorsClassName;var s=document.createElement("a");s.style.color="currentColor",s.href="https://markerjs.com/products/cropro",s.target="_blank",s.innerHTML='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" fill-rule="evenodd" clip-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="2"><path d="M16.326 14.895c0 1.126-.558 1.688-1.673 1.688H9.931c-1.116 0-1.674-.562-1.674-1.688V3.733c0-1.126.558-1.688 1.674-1.688h4.722c1.115 0 1.673.562 1.673 1.688v2.899h-1.957V3.793h-4.124v11.042h4.124v-3.242h1.957v3.302z" fill="currentColor"/><path d="M15.94 7.364a.783.783 0 00-1.065-.304l-11.01 6.126a.783.783 0 00-.303 1.065l4.498 8.085a.783.783 0 001.065.304l11.01-6.126a.783.783 0 00.303-1.065L15.94 7.364zM5.311 14.173l3.737 6.718 9.641-5.364-3.737-6.718-9.641 5.364z" fill="#eef762"/></svg>',a.appendChild(s),o.addElement(a)}var A=new Gt;A.minWidth=3*this.toolbarHeight+"px",A.contentAlign="end",this.topToolbar.addButtonBlock(A);var l=new Vt('<svg viewBox="0 0 24 24"><path d="M9 20.42l-6.21-6.21 2.83-2.83L9 14.77l9.88-9.89 2.83 2.83L9 20.42z"/></svg>',"OK");l.onClick=this.startRenderAndClose,A.addButton(l),this.styles.settings.toolbarOkButtonStyleColorsClassName&&(l.colorsClassName=this.styles.settings.toolbarOkButtonStyleColorsClassName);var c=new Vt('<svg viewBox="0 0 24 24"><path d="M20 6.91L17.09 4 12 9.09 6.91 4 4 6.91 9.09 12 4 17.09 6.91 20 12 14.91 17.09 20 20 17.09 14.91 12 20 6.91z"/></svg>',"Close");c.onClick=this.close,A.addButton(c),this.styles.settings.toolbarCloseButtonStyleColorsClassName&&(c.colorsClassName=this.styles.settings.toolbarCloseButtonStyleColorsClassName)},t.prototype.addBottomToolbar=function(){var t=this;this.bottomToolbar=new Kt,this.bottomToolbar.display=this.styles.settings.hideBottomToolbar?"none":"",this.bottomToolbar.className=this.toolbarStyleClass.name,this.bottomToolbar.colorsClassName=this.styles.settings.toolbarStyleColorsClassName?this.styles.settings.toolbarStyleColorsClassName:this.toolbarStyleColorsClass.name,this.bottomToolbar.fadeInClassName=this.styles.fadeInAnimationClassName,this.bottomToolbar.blockClassName=this.toolbarBlockStyleClass.name,this.bottomToolbar.buttonClassName=this.toolbarButtonStyleClass.name,this.bottomToolbar.buttonColorsClassName=this.styles.settings.toolbarButtonStyleColorsClassName?this.styles.settings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,this.bottomToolbar.buttonActiveColorsClassName=this.styles.settings.toolbarActiveButtonStyleColorsClassName?this.styles.settings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name;var e=new Gt;e.minWidth=2*this.toolbarHeight+"px",this.bottomToolbar.addButtonBlock(e);var r=new Vt('<svg viewBox="0 0 24 24"><path d="M13 4.07V1L8.45 5.55 13 10V6.09c2.84.48 5 2.94 5 5.91s-2.16 5.43-5 5.91v2.02c3.95-.49 7-3.85 7-7.93s-3.05-7.44-7-7.93M7.1 18.32c1.16.9 2.51 1.44 3.9 1.61V17.9c-.87-.15-1.71-.49-2.46-1.03L7.1 18.32M6.09 13H4.07c.17 1.39.72 2.73 1.62 3.89l1.41-1.42c-.52-.75-.87-1.59-1.01-2.47m1.02-4.47L5.7 7.11C4.8 8.27 4.24 9.61 4.07 11h2.02c.14-.87.49-1.72 1.02-2.47z"/></svg>',"Rotate left");r.onClick=this.rotateLeftButtonClicked,e.addButton(r);var n=new Vt('<svg viewBox="0 0 24 24"><path d="M16.89 15.5l1.42 1.39c.9-1.16 1.45-2.5 1.62-3.89h-2.02c-.14.87-.48 1.72-1.02 2.5M13 17.9v2.02c1.39-.17 2.74-.71 3.9-1.61l-1.44-1.44c-.75.54-1.59.89-2.46 1.03m6.93-6.9a7.906 7.906 0 00-1.62-3.89l-1.42 1.42c.54.75.88 1.6 1.02 2.47m-2.36-5.45L11 1v3.07C7.06 4.56 4 7.92 4 12s3.05 7.44 7 7.93v-2.02c-2.84-.48-5-2.94-5-5.91s2.16-5.43 5-5.91V10l4.55-4.45z"/></svg>',"Rotate right");n.onClick=this.rotateRightButtonClicked,e.addButton(n);var i=new zt;i.className=this.toolbarStraightenerBlockStyleClass.name,this.bottomToolbar.addElementBlock(i),this.straightener=new Zt("Straighten"),this.straightener.className=this.toolbarStraightenerStyleClass.name,this.straightener.colorsClassName=this.styles.settings.toolbarStraightenerColorsClassName?this.styles.settings.toolbarStraightenerColorsClassName:this.toolbarStraightenerStyleColorsClass.name,this.straightener.onAngleChange=function(e){t.rotateBy(e),t.straightener.angle=t.rotationAngle},i.addElement(this.straightener.getUI());var o=new Gt;o.minWidth=2*this.toolbarHeight+"px",o.contentAlign="end",this.bottomToolbar.addButtonBlock(o);var a=new Vt('<svg viewBox="0 0 24 24"><path d="M15 21h2v-2h-2m4-10h2V7h-2M3 5v14c0 1.1.9 2 2 2h4v-2H5V5h4V3H5c-1.1 0-2 .9-2 2m16-2v2h2c0-1.1-.9-2-2-2m-8 20h2V1h-2m8 16h2v-2h-2M15 5h2V3h-2m4 10h2v-2h-2m0 10c1.1 0 2-.9 2-2h-2z"/></svg>',"Flip horizontal");a.onClick=this.flipHorizontallyButtonClicked,o.addButton(a);var s=new Vt('<svg viewBox="0 0 24 24"><path d="M3 15v2h2v-2m10 4v2h2v-2m2-16H5c-1.1 0-2 .9-2 2v4h2V5h14v4h2V5c0-1.1-.9-2-2-2m2 16h-2v2c1.1 0 2-.9 2-2M1 11v2h22v-2M7 19v2h2v-2m10-4v2h2v-2m-10 4v2h2v-2M3 19c0 1.1.9 2 2 2v-2z"/></svg>',"Flip vertical");s.onClick=this.flipVerticallyButtonClicked,o.addButton(s)},t.prototype.ratioButtonClicked=function(t){this.aspectRatio=t,this.applyAspectRatio(),this.aspectRatioButton.hideDropdown()},t.prototype.applyAspectRatio=function(){this.setCropLayerAspectRatio(),this.aspectRatioButton.icon=Yt.getIcon(this.aspectRatio.horizontal,this.aspectRatio.vertical)},t.prototype.setCropLayerAspectRatio=function(){this.cropLayer&&(this.aspectRatio&&0!==this.aspectRatio.horizontal&&0!==this.aspectRatio.vertical?this.cropLayer.aspectRatio=new Wt(this.aspectRatio.horizontal,this.aspectRatio.vertical):this.cropLayer.aspectRatio=void 0)},t.prototype.closeUI=function(){"popup"===this.displayMode&&this.restoreOverflow(),this.targetRoot.removeChild(this.coverDiv)},t.prototype.getState=function(){return{width:this.imageWidth,height:this.imageHeight,rotationAngle:this.rotationAngle,flippedHorizontally:this.flippedHorizontally,flippedVertically:this.flippedVertically,cropRect:Object.assign({},this.cropRect)}},t.prototype.restoreState=function(t){if(t){var e=this.cropLayer.getRescaledRect(t.width,t.height,this.imageWidth,this.imageHeight,t.cropRect,this.CANVAS_MARGIN);this.cropLayer.setCropRectangle(e),this.cropRectChanged(e),this.flippedHorizontally=t.flippedHorizontally,this.flippedVertically=t.flippedVertically,this.applyFlip(),this.rotationAngle=t.rotationAngle,this.applyRotation()}},t.prototype.clientToLocalCoordinates=function(t,e){var r=this.cropImage.getBoundingClientRect();return{x:t-r.left,y:e-r.top}},t.prototype.onWindowResize=function(){this.positionUI()},t.prototype.positionUI=function(){switch(this.setTopLeft(),this.displayMode){case"inline":var t=this.target.offsetTop>this.toolbarHeight?this.target.offsetTop-this.toolbarHeight:0;this.coverDiv.style.top=t+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px";break;case"popup":this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=this.windowHeight+"px",this.contentDiv.style.maxHeight="calc(100vh - "+(2*this.popupMargin+2*this.toolbarHeight)+"px)"}this.positionCropImage()},t.prototype.rotateLeftButtonClicked=function(){var t=this.rotationAngle-90;this.rotationAngle%90!=0&&(t+=this.rotationAngle>=0?90-this.rotationAngle%90:-this.rotationAngle%90),this.rotateTo(t)},t.prototype.rotateRightButtonClicked=function(){var t=this.rotationAngle+90;this.rotationAngle%90!=0&&(t-=this.rotationAngle>=0?this.rotationAngle%90:90+this.rotationAngle%90),this.rotateTo(t)},t.prototype.rotateTo=function(t){t=(t=t>180?t-360:t)<=-180?t+360:t,this.rotationAngle=t,this.applyRotation()},t.prototype.rotateBy=function(t){this.rotateTo((this.rotationAngle+t)%360)},t.prototype.applyRotation=function(){var t=this.zoomToCropEnabled;this.zoomToCropEnabled=!1,this.editingTargetRotationScaleContainer.style.transformOrigin=this.imageWidth/2+"px "+this.imageHeight/2+"px",this.editingTargetRotationScaleContainer.style.transform="scale(1)";var e=this.editingTargetRotationContainer.transform.baseVal.getItem(0);e.setRotate(this.rotationAngle,this.imageWidth/2,this.imageHeight/2),this.editingTargetRotationContainer.transform.baseVal.replaceItem(e,0);var r=this.editingTarget.getBoundingClientRect();this.scaleFactor=Math.min(this.imageWidth/r.width,this.imageHeight/r.height),this.editingTargetRotationScaleContainer.style.transform="scale("+this.scaleFactor+")",this.zoomToCropEnabled=t},t.prototype.flipHorizontallyButtonClicked=function(){this.flippedHorizontally=!this.flippedHorizontally,this.applyFlip()},t.prototype.flipVerticallyButtonClicked=function(){this.flippedVertically=!this.flippedVertically,this.applyFlip()},t.prototype.applyFlip=function(){this.editingTarget.style.transform="scale("+(this.flippedHorizontally?-1:1)+","+(this.flippedVertically?-1:1)+")"},t.prototype.startRenderAndClose=function(){return Dt(this,void 0,void 0,(function(){var t,e;return Qt(this,(function(r){switch(r.label){case 0:return[4,this.render()];case 1:return t=r.sent(),e=this.getState(),this.renderEventListeners.forEach((function(r){return r(t,e)})),this.close(!0),[2]}}))}))},t.prototype.render=function(){return Dt(this,void 0,void 0,(function(){var t;return Qt(this,(function(e){switch(e.label){case 0:return(t=new $t).naturalSize=this.renderAtNaturalSize,t.imageType=this.renderImageType,t.imageQuality=this.renderImageQuality,t.width=this.renderWidth,t.height=this.renderHeight,this.unzoomFromCrop(),Rt.setAttributes(this.cropLayerContainer,[["display","none"]]),[4,t.rasterize(this.cropImage,this.target,{x:this.cropRect.x,y:this.cropRect.y,width:this.cropRect.width,height:this.cropRect.height},this.CANVAS_MARGIN,this.rotationAngle,this.scaleFactor*(this.flippedHorizontally?-1:1),this.scaleFactor*(this.flippedVertically?-1:1))];case 1:return e.sent(),[4,t.rasterize(this.cropImage,this.target,{x:this.cropRect.x,y:this.cropRect.y,width:this.cropRect.width,height:this.cropRect.height},this.CANVAS_MARGIN,this.rotationAngle,this.scaleFactor*(this.flippedHorizontally?-1:1),this.scaleFactor*(this.flippedVertically?-1:1))];case 2:return[2,e.sent()]}}))}))},t.prototype.addStyles=function(){this.toolbarStyleClass=this.styles.addClass(new Nt("toolbar","\n width: "+("inline"===this.displayMode?"100%":"calc(100vw - "+2*this.popupMargin+"px)")+";\n flex-shrink: 0;\n display: flex;\n flex-direction: row;\n justify-content: space-between; \n height: "+this.toolbarHeight+"px;\n box-sizing: content-box;\n overflow: hidden;\n line-height: 0px;\n ")),this.toolbarStyleColorsClass=this.styles.addClass(new Nt("toolbar_colors","\n background-color: "+this.styles.settings.toolbarBackgroundColor+";\n ")),this.toolbarBlockStyleClass=this.styles.addClass(new Nt("toolbar-block","\n display: flex;\n align-items: center;\n box-sizing: content-box;\n "));var t=this.toolbarHeight/4;this.toolbarButtonStyleClass=this.styles.addClass(new Nt("toolbar_button","\n display: inline-block;\n width: "+(this.toolbarHeight-2*t)+"px;\n height: "+(this.toolbarHeight-2*t)+"px;\n padding: "+t+"px;\n cursor: default;\n user-select: none;\n box-sizing: content-box;\n ")),this.toolbarButtonStyleColorsClass=this.styles.addClass(new Nt("toolbar_button_colors","\n color: "+this.styles.settings.toolbarColor+";\n fill: currentColor;\n ")),this.toolbarActiveButtonStyleColorsClass=this.styles.addClass(new Nt("toolbar_active_button","\n color: "+this.styles.settings.toolbarColor+";\n fill: currentColor;\n background-color: "+this.styles.settings.toolbarBackgroundActiveColor+"\n ")),this.styles.addRule(new Ht("."+this.toolbarButtonStyleClass.name+" svg","\n height: "+this.toolbarHeight/2+"px;\n ")),this.styles.addRule(new Ht("."+this.toolbarButtonStyleColorsClass.name+":hover","\n background-color: "+this.styles.settings.toolbarBackgroundHoverColor+"\n ")),this.toolbarDropdownStyleClass=this.styles.addClass(new Nt("toolbar_dropdown","\n position: absolute;\n max-width: "+4*this.toolbarHeight+"px;\n z-index: 20;\n white-space: normal;\n box-sizing: content-box;\n box-shadow: 3px 3px rgba(33, 33, 33, 0.1);\n margin: "+("inline"===this.displayMode?"0":this.popupMargin)+"px;\n line-height: 0px;\n ")),this.toolbarDropdownStyleColorsClass=this.styles.addClass(new Nt("toolbar_dropdown_colors","\n background-color: "+this.styles.settings.toolbarBackgroundColor+";\n ")),this.toolbarStraightenerBlockStyleClass=this.styles.addClass(new Nt("toolbar_straightener_block","\n display: flex;\n overflow: hidden;\n justify-content: center;\n -webkit-mask-image: linear-gradient(90deg, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 30%, rgba(0,0,0,1) 70%, rgba(0,0,0,0) 100%);\n ")),this.toolbarStraightenerStyleClass=this.styles.addClass(new Nt("toolbar_straightener","\n display: flex;\n overflow: hidden;\n justify-content: center;\n height: "+(this.toolbarHeight-2*t)+"px;\n padding: "+t+"px;\n cursor: default;\n user-select: none;\n box-sizing: content-box;\n ")),this.toolbarStraightenerStyleColorsClass=this.styles.addClass(new Nt("toolbar_straightener_colors","\n color: "+this.styles.settings.toolbarColor+";\n fill: currentColor;\n "))},t.instanceCounter=0,t}(),ee=r("8hTe"),re=r.n(ee),ne=/<pre[^>]*>/g;e.a=function(t){var e=t.value,r=void 0===e?"":e,A=t.edit,h=void 0!==A&&A,d=t.className,f=t.showTextOnly,p=t.showLines,g=t.replaces,m=t.zoomImg,v=t.hasMask,C=t.style,B=void 0===C?{}:C,x=t.stylesPrev,E=void 0===x?{}:x,T=String(r),F=Object(c.useRef)(),L=Object(c.useRef)(),I=Object(c.useState)(""),U=Object(s.a)(I,2),P=U[0],H=U[1],N=Object(c.useState)("office"),K=Object(s.a)(N,2),j=K[0],G=K[1],V=Object(c.useMemo)((function(){try{T=(T=T.replace(/\(\s+\/api\/attachments\/|\(\/api\/attachments\/|\(\/attachments\/download\//g,"("+D.a.API_SERVER+"/api/attachments/").replace(/\"\/api\/attachments\/|\"\/attachments\/download\//g,'"'+D.a.API_SERVER+"/api/attachments/").replace(/\(\s+\/files\/uploads\/|\"\/files\/uploads\//g,'"'+D.a.API_SERVER+"/files/uploads/").replaceAll("http://video.educoder","https://video.educoder").replaceAll("http://www.educoder.net/api","https://data.educoder.net/api").replaceAll("https://www.educoder.net/api","https://data.educoder.net/api").replace(/\r\n/g,"\n")).replace(new RegExp("(?<!\\n)\\n(?!\\n)","g")," \n")}catch(t){}var t=_(T),e=S;if(T.match(/\[TOC\]/)&&(t=t.replace("<p>[TOC]</p>",b()),y()),t=(t=t.replace(/(__special_katext_id_\d+__)/g,(function(t,r){var n=e[r],i=n.type,o=n.expression;return Object(Q.renderToString)(function(t){var e=document.createElement("div");return e.innerHTML=t,0===e.childNodes.length?"":e.childNodes[0].nodeValue}(o)||"",{displayMode:"block"===i,throwOnError:!1,output:"html"})}))).replace(/▁/g,"▁▁▁"),k(),f){var r=document.createElement("div");return r.innerHTML=t,r.innerText}return setTimeout((function(){return Y()}),500),t}),[T]),z=Object(c.useRef)();function W(t){var e=t.target;if("IMG"===e.tagName.toUpperCase()){if(m){var r=e.getAttribute("src");H(r),G("image")}}else if("A"===e.tagName.toUpperCase()){var n=e.getAttribute("href");if(n.indexOf("office")>-1)t.preventDefault(),H(n),G("office");else if(n.indexOf("application/pdf")>-1)t.preventDefault(),H(n),G("pdf");else if(n.indexOf("type=text")>-1)t.preventDefault(),H(n),G("html");else if(n.startsWith("#")){t.preventDefault();var i=document.getElementById(n.replace("#",""));i&&i.scrollIntoView(!0)}}}w.WebkitLineClamp=p,p&&(B=Object(o.a)(Object(o.a)({},B),w));var Y=function(){var t,e=null===(t=z.current)||void 0===t?void 0:t.querySelectorAll("video");null==e||e.forEach((function(t){if(t.oncontextmenu=function(){return!1},t.src.indexOf(".m3u8")>-1)if(t.canPlayType("application/vnd.apple.mpegurl"));else if(O.a.isSupported()){var e=new O.a;e.loadSource(t.src),e.attachMedia(t)}}))};Object(c.useEffect)((function(){if(z.current&&V&&V.match(ne)&&window.PR.prettyPrint(),z.current)return z.current.addEventListener("click",W),function(){z.current.removeEventListener("click",W),k(),y()}}),[V,z.current,W]);return u.a.createElement("div",{style:{position:"relative"}},u.a.createElement("div",{ref:z,style:Object(o.a)({},B),className:"".concat(d||""," markdown-body ").concat(re.a.mdBody),onMouseOver:function(t){h&&("IMG"===t.target.nodeName?(F.current.style.display="flex",F.current.style.width=t.target.clientWidth+"px",F.current.style.height=t.target.clientHeight+"px",F.current.style.top=t.target.offsetTop+"px",F.current.style.left=t.target.offsetLeft+"px",L.current.src=t.target.getAttribute("src")):F.current.style.display="none")},dangerouslySetInnerHTML:{__html:V}}),u.a.createElement("div",{ref:F,className:re.a.button},u.a.createElement(n.a,null,u.a.createElement(i.a,{onClick:function(){return(t=new te(L.current)).displayMode="popup",t.addRenderEventListener(function(){var t=Object(a.a)(l.a.mark((function t(e){var r;return l.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return F.current.style.display="none",t.next=3,Object(R.a)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:"educoder.png",file:e}});case 3:null!=(r=t.sent)&&r.id&&g(L.current.getAttribute("src").replace(D.a.API_SERVER,""),"/api/attachments/".concat(null==r?void 0:r.id,"?type=").concat(r.content_type));case 5:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()),void t.show();var t}},"裁剪"),u.a.createElement(i.a,{onClick:function(){return(t=new _t(L.current)).settings.displayMode="popup",t.addEventListener("render",function(){var t=Object(a.a)(l.a.mark((function t(e){var r;return l.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(F.current.style.display="none",!L.current){t.next=6;break}return t.next=4,Object(R.a)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:"educoder.png",file:e.dataUrl}});case 4:null!=(r=t.sent)&&r.id&&g(L.current.getAttribute("src").replace(D.a.API_SERVER,""),"/api/attachments/".concat(null==r?void 0:r.id,"?type=").concat(r.content_type));case 6:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()),t.show(),void(window.markerArea=t);var t}},"编辑"))),u.a.createElement("img",{ref:L,src:"https://ali-cdn.educoder.net/images/avatars/PortalImage/170?t=1659681136",alt:"sample",crossOrigin:"anonymous",style:{maxWidth:"90%",opacity:0,position:"absolute",zIndex:-1}}),u.a.createElement(M.a,{close:!0,data:P,hasMask:v,type:null!=P&&P.length?j:"",style:Object(o.a)({},E),onClose:function(){return H("")}}))}},"9VGf":
|
|
|
/*!****************************************!*\
|
|
|
!*** ./src/components/useInterval.tsx ***!
|
|
|
\****************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";r.d(e,"a",(function(){return i}));var n=r(/*! react */"q1tI");function i(t,e){var r=Object(n.useRef)();Object(n.useEffect)((function(){r.current=t})),Object(n.useEffect)((function(){if(null!==e){var t=setInterval((function(){r.current()}),e);return function(){return clearInterval(t)}}}),[e])}},BPZU:
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/timsort.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){function r(t,e,r,n){var i=e+1;if(i===r)return 1;if(n(t[i++],t[e])<0){for(;i<r&&n(t[i],t[i-1])<0;)i++;!function(t,e,r){r--;for(;e<r;){var n=t[e];t[e++]=t[r],t[r--]=n}}(t,e,i)}else for(;i<r&&n(t[i],t[i-1])>=0;)i++;return i-e}function n(t,e,r,n,i){for(n===e&&n++;n<r;n++){for(var o,a=t[n],s=e,A=n;s<A;)i(a,t[o=s+A>>>1])<0?A=o:s=o+1;var l=n-s;switch(l){case 3:t[s+3]=t[s+2];case 2:t[s+2]=t[s+1];case 1:t[s+1]=t[s];break;default:for(;l>0;)t[s+l]=t[s+l-1],l--}t[s]=a}}function i(t,e,r,n,i,o){var a=0,s=0,A=1;if(o(t,e[r+i])>0){for(s=n-i;A<s&&o(t,e[r+i+A])>0;)a=A,(A=1+(A<<1))<=0&&(A=s);A>s&&(A=s),a+=i,A+=i}else{for(s=i+1;A<s&&o(t,e[r+i-A])<=0;)a=A,(A=1+(A<<1))<=0&&(A=s);A>s&&(A=s);var l=a;a=i-A,A=i-l}for(a++;a<A;){var c=a+(A-a>>>1);o(t,e[r+c])>0?a=c+1:A=c}return A}function o(t,e,r,n,i,o){var a=0,s=0,A=1;if(o(t,e[r+i])<0){for(s=i+1;A<s&&o(t,e[r+i-A])<0;)a=A,(A=1+(A<<1))<=0&&(A=s);A>s&&(A=s);var l=a;a=i-A,A=i-l}else{for(s=n-i;A<s&&o(t,e[r+i+A])>=0;)a=A,(A=1+(A<<1))<=0&&(A=s);A>s&&(A=s),a+=i,A+=i}for(a++;a<A;){var c=a+(A-a>>>1);o(t,e[r+c])<0?A=c:a=c+1}return A}function a(t,e){var r,n,a,s=7,A=0;r=t.length;var l=[];function c(r){var c=n[r],u=a[r],h=n[r+1],d=a[r+1];a[r]=u+d,r===A-3&&(n[r+1]=n[r+2],a[r+1]=a[r+2]),A--;var f=o(t[h],t,c,u,0,e);c+=f,0!==(u-=f)&&0!==(d=i(t[c+u-1],t,h,d,d-1,e))&&(u<=d?function(r,n,a,A){var c=0;for(c=0;c<n;c++)l[c]=t[r+c];var u=0,h=a,d=r;if(t[d++]=t[h++],0==--A){for(c=0;c<n;c++)t[d+c]=l[u+c];return}if(1===n){for(c=0;c<A;c++)t[d+c]=t[h+c];return void(t[d+A]=l[u])}var f,p,g,m=s;for(;;){f=0,p=0,g=!1;do{if(e(t[h],l[u])<0){if(t[d++]=t[h++],p++,f=0,0==--A){g=!0;break}}else if(t[d++]=l[u++],f++,p=0,1==--n){g=!0;break}}while((f|p)<m);if(g)break;do{if(0!==(f=o(t[h],l,u,n,0,e))){for(c=0;c<f;c++)t[d+c]=l[u+c];if(d+=f,u+=f,(n-=f)<=1){g=!0;break}}if(t[d++]=t[h++],0==--A){g=!0;break}if(0!==(p=i(l[u],t,h,A,0,e))){for(c=0;c<p;c++)t[d+c]=t[h+c];if(d+=p,h+=p,0===(A-=p)){g=!0;break}}if(t[d++]=l[u++],1==--n){g=!0;break}m--}while(f>=7||p>=7);if(g)break;m<0&&(m=0),m+=2}if((s=m)<1&&(s=1),1===n){for(c=0;c<A;c++)t[d+c]=t[h+c];t[d+A]=l[u]}else{if(0===n)throw new Error;for(c=0;c<n;c++)t[d+c]=l[u+c]}}(c,u,h,d):function(r,n,a,A){var c=0;for(c=0;c<A;c++)l[c]=t[a+c];var u=r+n-1,h=A-1,d=a+A-1,f=0,p=0;if(t[d--]=t[u--],0==--n){for(f=d-(A-1),c=0;c<A;c++)t[f+c]=l[c];return}if(1===A){for(p=(d-=n)+1,f=(u-=n)+1,c=n-1;c>=0;c--)t[p+c]=t[f+c];return void(t[d]=l[h])}var g=s;for(;;){var m=0,v=0,y=!1;do{if(e(l[h],t[u])<0){if(t[d--]=t[u--],m++,v=0,0==--n){y=!0;break}}else if(t[d--]=l[h--],v++,m=0,1==--A){y=!0;break}}while((m|v)<g);if(y)break;do{if(0!==(m=n-o(l[h],t,r,n,n-1,e))){for(n-=m,p=(d-=m)+1,f=(u-=m)+1,c=m-1;c>=0;c--)t[p+c]=t[f+c];if(0===n){y=!0;break}}if(t[d--]=l[h--],1==--A){y=!0;break}if(0!==(v=A-i(t[u],l,0,A,A-1,e))){for(A-=v,p=(d-=v)+1,f=(h-=v)+1,c=0;c<v;c++)t[p+c]=l[f+c];if(A<=1){y=!0;break}}if(t[d--]=t[u--],0==--n){y=!0;break}g--}while(m>=7||v>=7);if(y)break;g<0&&(g=0),g+=2}(s=g)<1&&(s=1);if(1===A){for(p=(d-=n)+1,f=(u-=n)+1,c=n-1;c>=0;c--)t[p+c]=t[f+c];t[d]=l[h]}else{if(0===A)throw new Error;for(f=d-(A-1),c=0;c<A;c++)t[f+c]=l[c]}}(c,u,h,d))}n=[],a=[],this.mergeRuns=function(){for(;A>1;){var t=A-2;if(t>=1&&a[t-1]<=a[t]+a[t+1]||t>=2&&a[t-2]<=a[t]+a[t-1])a[t-1]<a[t+1]&&t--;else if(a[t]>a[t+1])break;c(t)}},this.forceMergeRuns=function(){for(;A>1;){var t=A-2;t>0&&a[t-1]<a[t+1]&&t--,c(t)}},this.pushRun=function(t,e){n[A]=t,a[A]=e,A+=1}}t.exports=function(t,e,i,o){i||(i=0),o||(o=t.length);var s=o-i;if(!(s<2)){var A=0;if(s<32)n(t,i,o,i+(A=r(t,i,o,e)),e);else{var l=new a(t,e),c=function(t){for(var e=0;t>=32;)e|=1&t,t>>=1;return t+e}(s);do{if((A=r(t,i,o,e))<c){var u=s;u>c&&(u=c),n(t,i,i+u,i+A,e),A=u}l.pushRun(i,A),l.mergeRuns(),s-=A,i+=A}while(0!==s);l.forceMergeRuns()}}}},BU3w:
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./node_modules/rc-util/es/Dom/dynamicCSS.js ***!
|
|
|
\***************************************************/
|
|
|
/*! exports provided: injectCSS, updateCSS */
|
|
|
/*! exports used: updateCSS */function(t,e,r){"use strict";r.d(e,"a",(function(){return s}));var n=r(/*! ./canUseDom */"MNnm");function i(t){return t.attachTo?t.attachTo:document.querySelector("head")||document.body}function o(t){var e,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!Object(n.a)())return null;var o,a=document.createElement("style");(null===(e=r.csp)||void 0===e?void 0:e.nonce)&&(a.nonce=null===(o=r.csp)||void 0===o?void 0:o.nonce);a.innerHTML=t;var s=i(r),A=s.firstChild;return r.prepend&&s.prepend?s.prepend(a):r.prepend&&A?s.insertBefore(a,A):s.appendChild(a),a}var a=new Map;function s(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=i(r);if(!a.has(n)){var s=o("",r),A=s.parentNode;a.set(n,A),A.removeChild(s)}var l=Array.from(a.get(n).children).find((function(t){return"STYLE"===t.tagName&&t["rc-util-key"]===e}));if(l){var c,u,h;if((null===(c=r.csp)||void 0===c?void 0:c.nonce)&&l.nonce!==(null===(u=r.csp)||void 0===u?void 0:u.nonce))l.nonce=null===(h=r.csp)||void 0===h?void 0:h.nonce;return l.innerHTML!==t&&(l.innerHTML=t),l}var d=o(t,r);return d["rc-util-key"]=e,d}},Bd2K:
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/codemirror/addon/edit/closetag.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){!function(t){t.defineOption("autoCloseTags",!1,(function(a,s,A){if(A!=t.Init&&A&&a.removeKeyMap("autoCloseTags"),s){var l={name:"autoCloseTags"};"object"==typeof s&&!1===s.whenClosing||(l["'/'"]=function(e){return function(e){return e.getOption("disableInput")?t.Pass:n(e,!0)}(e)}),"object"==typeof s&&!1===s.whenOpening||(l["'>'"]=function(n){return function(n){if(n.getOption("disableInput"))return t.Pass;for(var a=n.listSelections(),s=[],A=n.getOption("autoCloseTags"),l=0;l<a.length;l++){if(!a[l].empty())return t.Pass;var c=a[l].head,u=n.getTokenAt(c),h=t.innerMode(n.getMode(),u.state),d=h.state,f=h.mode.xmlCurrentTag&&h.mode.xmlCurrentTag(d),p=f&&f.name;if(!p)return t.Pass;var g="html"==h.mode.configuration,m="object"==typeof A&&A.dontCloseTags||g&&e,v="object"==typeof A&&A.indentTags||g&&r;u.end>c.ch&&(p=p.slice(0,p.length-u.end+c.ch));var y=p.toLowerCase();if(!p||"string"==u.type&&(u.end!=c.ch||!/[\"\']/.test(u.string.charAt(u.string.length-1))||1==u.string.length)||"tag"==u.type&&f.close||u.string.indexOf("/")==c.ch-u.start-1||m&&i(m,y)>-1||o(n,h.mode.xmlCurrentContext&&h.mode.xmlCurrentContext(d)||[],p,c,!0))return t.Pass;var w="object"==typeof A&&A.emptyTags;if(w&&i(w,p)>-1)s[l]={text:"/>",newPos:t.Pos(c.line,c.ch+2)};else{var b=v&&i(v,y)>-1;s[l]={indent:b,text:">"+(b?"\n\n":"")+"</"+p+">",newPos:b?t.Pos(c.line+1,0):t.Pos(c.line,c.ch+1)}}}var C="object"==typeof A&&A.dontIndentOnAutoClose;for(l=a.length-1;l>=0;l--){var B=s[l];n.replaceRange(B.text,a[l].head,a[l].anchor,"+insert");var x=n.listSelections().slice(0);x[l]={head:B.newPos,anchor:B.newPos},n.setSelections(x),!C&&B.indent&&(n.indentLine(B.newPos.line,null,!0),n.indentLine(B.newPos.line+1,null,!0))}}(n)}),a.addKeyMap(l)}}));var e=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],r=["applet","blockquote","body","button","div","dl","fieldset","form","frameset","h1","h2","h3","h4","h5","h6","head","html","iframe","layer","legend","object","ol","p","select","table","ul"];function n(e,r){for(var n=e.listSelections(),i=[],a=r?"/":"</",s=e.getOption("autoCloseTags"),A="object"==typeof s&&s.dontIndentOnSlash,l=0;l<n.length;l++){if(!n[l].empty())return t.Pass;var c=n[l].head,u=e.getTokenAt(c),h=t.innerMode(e.getMode(),u.state),d=h.state;if(r&&("string"==u.type||"<"!=u.string.charAt(0)||u.start!=c.ch-1))return t.Pass;var f,p="xml"!=h.mode.name&&"htmlmixed"==e.getMode().name;if(p&&"javascript"==h.mode.name)f=a+"script";else if(p&&"css"==h.mode.name)f=a+"style";else{var g=h.mode.xmlCurrentContext&&h.mode.xmlCurrentContext(d);if(!g||g.length&&o(e,g,g[g.length-1],c))return t.Pass;f=a+g[g.length-1]}">"!=e.getLine(c.line).charAt(u.end)&&(f+=">"),i[l]=f}if(e.replaceSelections(i),n=e.listSelections(),!A)for(l=0;l<n.length;l++)(l==n.length-1||n[l].head.line<n[l+1].head.line)&&e.indentLine(n[l].head.line)}function i(t,e){if(t.indexOf)return t.indexOf(e);for(var r=0,n=t.length;r<n;++r)if(t[r]==e)return r;return-1}function o(e,r,n,i,o){if(!t.scanForClosingTag)return!1;var a=Math.min(e.lastLine()+1,i.line+500),s=t.scanForClosingTag(e,i,null,a);if(!s||s.tag!=n)return!1;for(var A=o?1:0,l=r.length-1;l>=0&&r[l]==n;l--)++A;for(i=s.to,l=1;l<A;l++){var c=t.scanForClosingTag(e,i,null,a);if(!c||c.tag!=n)return!1;i=c.to}return!0}t.commands.closeTag=function(t){return n(t)}}(r(/*! ../../lib/codemirror */"VrN/"),r(/*! ../fold/xml-fold */"osHv"))},BjJ7:
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/pages/tasks/util.js ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: isCompileOk, getTreeData, processTreeData, debounce, isProd, apiPref */
|
|
|
/*! exports used: apiPref, debounce, getTreeData, isCompileOk, processTreeData */function(t,e,r){"use strict";function n(t){var e=!0;if(t.length>0){for(var r=0;r<t.length;r++)if(0==t[r].compile_success||!t[r].compile_success){e=!1;break}}else e=!1;return e}function i(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=[],n=0;n<t.length;n++){var i=t[n],o=e?"".concat(e,"/").concat(i.name):"".concat(i.name);r.push({title:i.name,isLeaf:"tree"!==i.type,key:o})}return r}function o(t,e,r){for(var n=0;n<t.length;n++){var i=t[n];if(i.key===e){i.children=r;break}i.children&&o(i.children,e,r)}return t}function a(t,e,r){var n;return function(){var i=this,o=arguments,a=function(){n=null,r||t.apply(i,o)},s=r&&!n;clearTimeout(n),n=setTimeout(a,e),s&&t.apply(i,o)}}r.d(e,"d",(function(){return n})),r.d(e,"c",(function(){return i})),r.d(e,"e",(function(){return o})),r.d(e,"b",(function(){return a})),r.d(e,"a",(function(){return s}));var s=r(/*! @/utils/env */"m3rI").a.API_SERVER},BlVb:
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/polygon.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./windingLine */"hyiK");function i(t,e){return Math.abs(t-e)<1e-8}e.contain=function(t,e,r){var o=0,a=t[0];if(!a)return!1;for(var s=1;s<t.length;s++){var A=t[s];o+=n(a[0],a[1],A[0],A[1],e,r),a=A}var l=t[0];return i(a[0],l[0])&&i(a[1],l[1])||(o+=n(a[0],a[1],l[0],l[1],e,r)),0!==o}},Bq2U:
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/animation/Animator.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./Clip */"RDYZ"),i=r(/*! ../tool/color */"Qe9p"),o=r(/*! ../core/util */"bYtY").isArrayLike,a=Array.prototype.slice;function s(t,e){return t[e]}function A(t,e,r){t[e]=r}function l(t,e,r){return(e-t)*r+t}function c(t,e,r){return r>.5?e:t}function u(t,e,r,n,i){var o=t.length;if(1===i)for(var a=0;a<o;a++)n[a]=l(t[a],e[a],r);else{var s=o&&t[0].length;for(a=0;a<o;a++)for(var A=0;A<s;A++)n[a][A]=l(t[a][A],e[a][A],r)}}function h(t,e,r){var n=t.length,i=e.length;if(n!==i)if(n>i)t.length=i;else for(var o=n;o<i;o++)t.push(1===r?e[o]:a.call(e[o]));var s=t[0]&&t[0].length;for(o=0;o<t.length;o++)if(1===r)isNaN(t[o])&&(t[o]=e[o]);else for(var A=0;A<s;A++)isNaN(t[o][A])&&(t[o][A]=e[o][A])}function d(t,e,r){if(t===e)return!0;var n=t.length;if(n!==e.length)return!1;if(1===r){for(var i=0;i<n;i++)if(t[i]!==e[i])return!1}else{var o=t[0].length;for(i=0;i<n;i++)for(var a=0;a<o;a++)if(t[i][a]!==e[i][a])return!1}return!0}function f(t,e,r,n,i,o,a,s,A){var l=t.length;if(1===A)for(var c=0;c<l;c++)s[c]=p(t[c],e[c],r[c],n[c],i,o,a);else{var u=t[0].length;for(c=0;c<l;c++)for(var h=0;h<u;h++)s[c][h]=p(t[c][h],e[c][h],r[c][h],n[c][h],i,o,a)}}function p(t,e,r,n,i,o,a){var s=.5*(r-t),A=.5*(n-e);return(2*(e-r)+s+A)*a+(-3*(e-r)-2*s-A)*o+s*i+e}function g(t){if(o(t)){var e=t.length;if(o(t[0])){for(var r=[],n=0;n<e;n++)r.push(a.call(t[n]));return r}return a.call(t)}return t}function m(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}function v(t,e,r,a,s,A){var g=t._getter,v=t._setter,y="spline"===e,w=a.length;if(w){var b,C=a[0].value,B=o(C),x=!1,E=!1,S=B?function(t){var e=t[t.length-1].value;return o(e&&e[0])?2:1}(a):0;a.sort((function(t,e){return t.time-e.time})),b=a[w-1].time;for(var k=[],T=[],F=a[0].value,L=!0,I=0;I<w;I++){k.push(a[I].time/b);var _=a[I].value;if(B&&d(_,F,S)||!B&&_===F||(L=!1),F=_,"string"==typeof _){var U=i.parse(_);U?(_=U,x=!0):E=!0}T.push(_)}if(A||!L){var O=T[w-1];for(I=0;I<w-1;I++)B?h(T[I],O,S):!isNaN(T[I])||isNaN(O)||E||x||(T[I]=O);B&&h(g(t._target,s),O,S);var D,Q,M,R,P,H=0,N=0;if(x)var K=[0,0,0,0];var j=new n({target:t._target,life:b,loop:t._loop,delay:t._delay,onframe:function(t,e){var r;if(e<0)r=0;else if(e<N){for(r=Math.min(H+1,w-1);r>=0&&!(k[r]<=e);r--);r=Math.min(r,w-2)}else{for(r=H;r<w&&!(k[r]>e);r++);r=Math.min(r-1,w-2)}H=r,N=e;var n=k[r+1]-k[r];if(0!==n)if(D=(e-k[r])/n,y)if(M=T[r],Q=T[0===r?r:r-1],R=T[r>w-2?w-1:r+1],P=T[r>w-3?w-1:r+2],B)f(Q,M,R,P,D,D*D,D*D*D,g(t,s),S);else{if(x)i=f(Q,M,R,P,D,D*D,D*D*D,K,1),i=m(K);else{if(E)return c(M,R,D);i=p(Q,M,R,P,D,D*D,D*D*D)}v(t,s,i)}else if(B)u(T[r],T[r+1],D,g(t,s),S);else{var i;if(x)u(T[r],T[r+1],D,K,1),i=m(K);else{if(E)return c(T[r],T[r+1],D);i=l(T[r],T[r+1],D)}v(t,s,i)}},ondestroy:r});return e&&"spline"!==e&&(j.easing=e),j}}}var y=function(t,e,r,n){this._tracks={},this._target=t,this._loop=e||!1,this._getter=r||s,this._setter=n||A,this._clipCount=0,this._delay=0,this._doneList=[],this._onframeList=[],this._clipList=[]};y.prototype={when:function(t,e){var r=this._tracks;for(var n in e)if(e.hasOwnProperty(n)){if(!r[n]){r[n]=[];var i=this._getter(this._target,n);if(null==i)continue;0!==t&&r[n].push({time:0,value:g(i)})}r[n].push({time:t,value:e[n]})}return this},during:function(t){return this._onframeList.push(t),this},pause:function(){for(var t=0;t<this._clipList.length;t++)this._clipList[t].pause();this._paused=!0},resume:function(){for(var t=0;t<this._clipList.length;t++)this._clipList[t].resume();this._paused=!1},isPaused:function(){return!!this._paused},_doneCallback:function(){this._tracks={},this._clipList.length=0;for(var t=this._doneList,e=t.length,r=0;r<e;r++)t[r].call(this)},start:function(t,e){var r,n=this,i=0,o=function(){--i||n._doneCallback()};for(var a in this._tracks)if(this._tracks.hasOwnProperty(a)){var s=v(this,t,o,this._tracks[a],a,e);s&&(this._clipList.push(s),i++,this.animation&&this.animation.addClip(s),r=s)}if(r){var A=r.onframe;r.onframe=function(t,e){A(t,e);for(var r=0;r<n._onframeList.length;r++)n._onframeList[r](t,e)}}return i||this._doneCallback(),this},stop:function(t){for(var e=this._clipList,r=this.animation,n=0;n<e.length;n++){var i=e[n];t&&i.onframe(this._target,1),r&&r.removeClip(i)}e.length=0},delay:function(t){return this._delay=t,this},done:function(t){return t&&this._doneList.push(t),this},getClips:function(){return this._clipList}};var w=y;t.exports=w},"C+DQ":
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./src/components/markdown-editor/css/iconfont.css ***!
|
|
|
\*********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){},C0SR:
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/GestureMgr.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./event */"YH21"),i=function(){this._track=[]};function o(t){var e=t[1][0]-t[0][0],r=t[1][1]-t[0][1];return Math.sqrt(e*e+r*r)}i.prototype={constructor:i,recognize:function(t,e,r){return this._doTrack(t,e,r),this._recognize(t)},clear:function(){return this._track.length=0,this},_doTrack:function(t,e,r){var i=t.touches;if(i){for(var o={points:[],touches:[],target:e,event:t},a=0,s=i.length;a<s;a++){var A=i[a],l=n.clientToLocal(r,A,{});o.points.push([l.zrX,l.zrY]),o.touches.push(A)}this._track.push(o)}},_recognize:function(t){for(var e in a)if(a.hasOwnProperty(e)){var r=a[e](this._track,t);if(r)return r}}};var a={pinch:function(t,e){var r=t.length;if(r){var n,i=(t[r-1]||{}).points,a=(t[r-2]||{}).points||i;if(a&&a.length>1&&i&&i.length>1){var s=o(i)/o(a);!isFinite(s)&&(s=1),e.pinchScale=s;var A=[((n=i)[0][0]+n[1][0])/2,(n[0][1]+n[1][1])/2];return e.pinchX=A[0],e.pinchY=A[1],{type:"pinch",target:t[0].target,event:e}}}}},s=i;t.exports=s},D1Df:
|
|
|
/*!************************************************!*\
|
|
|
!*** ./node_modules/qrcode.react/lib/index.js ***!
|
|
|
\************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";function n(t){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(){return(i=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}function o(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function a(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?o(r,!0).forEach((function(e){g(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):o(r).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function s(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}function A(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function c(t,e,r){return e&&l(t.prototype,e),r&&l(t,r),t}function u(t,e){return!e||"object"!==n(e)&&"function"!=typeof e?d(t):e}function h(t){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function d(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function f(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&p(t,e)}function p(t,e){return(p=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function g(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var m=r(/*! react */"q1tI"),v=(r(/*! prop-types */"17x9"),r(/*! qr.js/lib/QRCode */"H38U")),y=r(/*! qr.js/lib/ErrorCorrectLevel */"aRTE");function w(t){for(var e="",r=0;r<t.length;r++){var n=t.charCodeAt(r);n<128?e+=String.fromCharCode(n):n<2048?(e+=String.fromCharCode(192|n>>6),e+=String.fromCharCode(128|63&n)):n<55296||n>=57344?(e+=String.fromCharCode(224|n>>12),e+=String.fromCharCode(128|n>>6&63),e+=String.fromCharCode(128|63&n)):(r++,n=65536+((1023&n)<<10|1023&t.charCodeAt(r)),e+=String.fromCharCode(240|n>>18),e+=String.fromCharCode(128|n>>12&63),e+=String.fromCharCode(128|n>>6&63),e+=String.fromCharCode(128|63&n))}return e}var b={size:128,level:"L",bgColor:"#FFFFFF",fgColor:"#000000",includeMargin:!1};function C(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=[];return t.forEach((function(t,n){var i=null;t.forEach((function(o,a){if(!o&&null!==i)return r.push("M".concat(i+e," ").concat(n+e,"h").concat(a-i,"v1H").concat(i+e,"z")),void(i=null);if(a!==t.length-1)o&&null===i&&(i=a);else{if(!o)return;null===i?r.push("M".concat(a+e,",").concat(n+e," h1v1H").concat(a+e,"z")):r.push("M".concat(i+e,",").concat(n+e," h").concat(a+1-i,"v1H").concat(i+e,"z"))}}))})),r.join("")}function B(t,e){return t.slice().map((function(t,r){return r<e.y||r>=e.y+e.h?t:t.map((function(t,r){return(r<e.x||r>=e.x+e.w)&&t}))}))}function x(t,e){var r=t.imageSettings,n=t.size,i=t.includeMargin;if(null==r)return null;var o=i?4:0,a=e.length+2*o,s=Math.floor(.1*n),A=a/n,l=(r.width||s)*A,c=(r.height||s)*A,u=null==r.x?e.length/2-l/2:r.x*A,h=null==r.y?e.length/2-c/2:r.y*A,d=null;if(r.excavate){var f=Math.floor(u),p=Math.floor(h);d={x:f,y:p,w:Math.ceil(l+u-f),h:Math.ceil(c+h-p)}}return{x:u,y:h,h:c,w:l,excavation:d}}var E=function(){try{(new Path2D).addPath(new Path2D)}catch(t){return!1}return!0}(),S=function(t){function e(){var t,r;A(this,e);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return g(d(r=u(this,(t=h(e)).call.apply(t,[this].concat(i)))),"_canvas",void 0),g(d(r),"_image",void 0),g(d(r),"state",{imgLoaded:!1}),g(d(r),"handleImageLoad",(function(){r.setState({imgLoaded:!0})})),r}return f(e,t),c(e,[{key:"componentDidMount",value:function(){this.update()}},{key:"componentDidUpdate",value:function(){this.update()}},{key:"update",value:function(){var t=this.props,e=t.value,r=t.size,n=t.level,i=t.bgColor,o=t.fgColor,a=t.includeMargin,s=t.imageSettings,A=new v(-1,y[n]);if(A.addData(w(e)),A.make(),null!=this._canvas){var l=this._canvas,c=l.getContext("2d");if(!c)return;var u=A.modules;if(null===u)return;var h=a?4:0,d=u.length+2*h,f=x(this.props,u);null!=s&&null!=f&&null!=f.excavation&&(u=B(u,f.excavation));var p=window.devicePixelRatio||1;l.height=l.width=r*p;var g=r/d*p;c.scale(g,g),c.fillStyle=i,c.fillRect(0,0,d,d),c.fillStyle=o,E?c.fill(new Path2D(C(u,h))):u.forEach((function(t,e){t.forEach((function(t,r){t&&c.fillRect(r+h,e+h,1,1)}))})),this.state.imgLoaded&&this._image&&null!=f&&c.drawImage(this._image,f.x+h,f.y+h,f.w,f.h)}}},{key:"render",value:function(){var t=this,e=this.props,r=(e.value,e.size),n=(e.level,e.bgColor,e.fgColor,e.style),o=(e.includeMargin,e.imageSettings),A=s(e,["value","size","level","bgColor","fgColor","style","includeMargin","imageSettings"]),l=a({height:r,width:r},n),c=null,u=o&&o.src;return null!=o&&null!=u&&(c=m.createElement("img",{src:u,style:{display:"none"},onLoad:this.handleImageLoad,ref:function(e){return t._image=e}})),m.createElement(m.Fragment,null,m.createElement("canvas",i({style:l,height:r,width:r,ref:function(e){return t._canvas=e}},A)),c)}}]),e}(m.PureComponent);g(S,"defaultProps",b);var k=function(t){function e(){return A(this,e),u(this,h(e).apply(this,arguments))}return f(e,t),c(e,[{key:"render",value:function(){var t=this.props,e=t.value,r=t.size,n=t.level,o=t.bgColor,a=t.fgColor,A=t.includeMargin,l=t.imageSettings,c=s(t,["value","size","level","bgColor","fgColor","includeMargin","imageSettings"]),u=new v(-1,y[n]);u.addData(w(e)),u.make();var h=u.modules;if(null===h)return null;var d=A?4:0,f=h.length+2*d,p=x(this.props,h),g=null;null!=l&&null!=p&&(null!=p.excavation&&(h=B(h,p.excavation)),g=m.createElement("image",{xlinkHref:l.src,height:p.h,width:p.w,x:p.x+d,y:p.y+d,preserveAspectRatio:"none"}));var b=C(h,d);return m.createElement("svg",i({shapeRendering:"crispEdges",height:r,width:r,viewBox:"0 0 ".concat(f," ").concat(f)},c),m.createElement("path",{fill:o,d:"M0,0 h".concat(f,"v").concat(f,"H0z")}),m.createElement("path",{fill:a,d:b}),g)}}]),e}(m.PureComponent);g(k,"defaultProps",b);var T=function(t){var e=t.renderAs,r=s(t,["renderAs"]),n="svg"===e?k:S;return m.createElement(n,r)};T.defaultProps=a({renderAs:"canvas"},b),t.exports=T},DBLp:
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/arrayDiff2.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){function r(){}function n(t,e,r,n){for(var i=0,o=e.length,a=0,s=0;i<o;i++){var A=e[i];if(A.removed){for(l=[],c=s;c<s+A.count;c++)l.push(c);A.indices=l,s+=A.count}else{for(var l=[],c=a;c<a+A.count;c++)l.push(c);A.indices=l,a+=A.count,A.added||(s+=A.count)}}return e}r.prototype={diff:function(t,e,r){r||(r=function(t,e){return t===e}),this.equals=r;var i=this;t=t.slice();var o=(e=e.slice()).length,a=t.length,s=1,A=o+a,l=[{newPos:-1,components:[]}],c=this.extractCommon(l[0],e,t,0);if(l[0].newPos+1>=o&&c+1>=a){for(var u=[],h=0;h<e.length;h++)u.push(h);return[{indices:u,count:e.length}]}function d(){for(var r=-1*s;r<=s;r+=2){var A,c=l[r-1],u=l[r+1],h=(u?u.newPos:0)-r;c&&(l[r-1]=void 0);var d=c&&c.newPos+1<o,f=u&&0<=h&&h<a;if(d||f){if(!d||f&&c.newPos<u.newPos?(A={newPos:(p=u).newPos,components:p.components.slice(0)},i.pushComponent(A.components,void 0,!0)):((A=c).newPos++,i.pushComponent(A.components,!0,void 0)),h=i.extractCommon(A,e,t,r),A.newPos+1>=o&&h+1>=a)return n(i,A.components,e,t);l[r]=A}else l[r]=void 0}var p;s++}for(;s<=A;){var f=d();if(f)return f}},pushComponent:function(t,e,r){var n=t[t.length-1];n&&n.added===e&&n.removed===r?t[t.length-1]={count:n.count+1,added:e,removed:r}:t.push({count:1,added:e,removed:r})},extractCommon:function(t,e,r,n){for(var i=e.length,o=r.length,a=t.newPos,s=a-n,A=0;a+1<i&&s+1<o&&this.equals(e[a+1],r[s+1]);)a++,s++,A++;return A&&t.components.push({count:A}),t.newPos=a,s},tokenize:function(t){return t.slice()},join:function(t){return t.slice()}};var i=new r;t.exports=function(t,e,r){return i.diff(t,e,r)}},DN4a:
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/mixin/Transformable.js ***!
|
|
|
\*********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/matrix */"Fofx"),i=r(/*! ../core/vector */"QBsz"),o=n.identity;function a(t){return t>5e-5||t<-5e-5}var s=function(t){(t=t||{}).position||(this.position=[0,0]),null==t.rotation&&(this.rotation=0),t.scale||(this.scale=[1,1]),this.origin=this.origin||null},A=s.prototype;A.transform=null,A.needLocalTransform=function(){return a(this.rotation)||a(this.position[0])||a(this.position[1])||a(this.scale[0]-1)||a(this.scale[1]-1)};var l=[];A.updateTransform=function(){var t=this.parent,e=t&&t.transform,r=this.needLocalTransform(),i=this.transform;if(r||e){i=i||n.create(),r?this.getLocalTransform(i):o(i),e&&(r?n.mul(i,t.transform,i):n.copy(i,t.transform)),this.transform=i;var a=this.globalScaleRatio;if(null!=a&&1!==a){this.getGlobalScale(l);var s=l[0]<0?-1:1,A=l[1]<0?-1:1,c=((l[0]-s)*a+s)/l[0]||0,u=((l[1]-A)*a+A)/l[1]||0;i[0]*=c,i[1]*=c,i[2]*=u,i[3]*=u}this.invTransform=this.invTransform||n.create(),n.invert(this.invTransform,i)}else i&&o(i)},A.getLocalTransform=function(t){return s.getLocalTransform(this,t)},A.setTransform=function(t){var e=this.transform,r=t.dpr||1;e?t.setTransform(r*e[0],r*e[1],r*e[2],r*e[3],r*e[4],r*e[5]):t.setTransform(r,0,0,r,0,0)},A.restoreTransform=function(t){var e=t.dpr||1;t.setTransform(e,0,0,e,0,0)};var c=[],u=n.create();A.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],r=t[2]*t[2]+t[3]*t[3],n=this.position,i=this.scale;a(e-1)&&(e=Math.sqrt(e)),a(r-1)&&(r=Math.sqrt(r)),t[0]<0&&(e=-e),t[3]<0&&(r=-r),n[0]=t[4],n[1]=t[5],i[0]=e,i[1]=r,this.rotation=Math.atan2(-t[1]/r,t[0]/e)}},A.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(n.mul(c,t.invTransform,e),e=c);var r=this.origin;r&&(r[0]||r[1])&&(u[4]=r[0],u[5]=r[1],n.mul(c,e,u),c[4]-=r[0],c[5]-=r[1],e=c),this.setLocalTransform(e)}},A.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},A.transformCoordToLocal=function(t,e){var r=[t,e],n=this.invTransform;return n&&i.applyTransform(r,r,n),r},A.transformCoordToGlobal=function(t,e){var r=[t,e],n=this.transform;return n&&i.applyTransform(r,r,n),r},s.getLocalTransform=function(t,e){o(e=e||[]);var r=t.origin,i=t.scale||[1,1],a=t.rotation||0,s=t.position||[0,0];return r&&(e[4]-=r[0],e[5]-=r[1]),n.scale(e,e,i),a&&n.rotate(e,e,a),r&&(e[4]+=r[0],e[5]+=r[1]),e[4]+=s[0],e[5]+=s[1],e};var h=s;t.exports=h},Dagg:
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/Image.js ***!
|
|
|
\***************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./Displayable */"Gev7"),i=r(/*! ../core/BoundingRect */"mFDi"),o=r(/*! ../core/util */"bYtY"),a=r(/*! ./helper/image */"Xnb7");function s(t){n.call(this,t)}s.prototype={constructor:s,type:"image",brush:function(t,e){var r=this.style,n=r.image;r.bind(t,this,e);var i=this._image=a.createOrUpdateImage(n,this._image,this,this.onload);if(i&&a.isImageReady(i)){var o=r.x||0,s=r.y||0,A=r.width,l=r.height,c=i.width/i.height;if(null==A&&null!=l?A=l*c:null==l&&null!=A?l=A/c:null==A&&null==l&&(A=i.width,l=i.height),this.setTransform(t),r.sWidth&&r.sHeight){var u=r.sx||0,h=r.sy||0;t.drawImage(i,u,h,r.sWidth,r.sHeight,o,s,A,l)}else if(r.sx&&r.sy){var d=A-(u=r.sx),f=l-(h=r.sy);t.drawImage(i,u,h,d,f,o,s,A,l)}else t.drawImage(i,o,s,A,l);null!=r.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))}},getBoundingRect:function(){var t=this.style;return this._rect||(this._rect=new i(t.x||0,t.y||0,t.width||0,t.height||0)),this._rect}},o.inherits(s,n);var A=s;t.exports=A},DlQD:
|
|
|
/*!*******************************************!*\
|
|
|
!*** ./node_modules/marked/lib/marked.js ***!
|
|
|
\*******************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){t.exports=function(){"use strict";function t(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function e(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function r(t,r){var n;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(n=function(t,r){if(t){if("string"==typeof t)return e(t,r);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?e(t,r):void 0}}(t))||r&&t&&"number"==typeof t.length){n&&(t=n);var i=0;return function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=t[Symbol.iterator]()).next.bind(n)}var n=function(t,e){return t(e={exports:{}},e.exports),e.exports}((function(t){function e(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}t.exports={defaults:{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1},getDefaults:e,changeDefaults:function(e){t.exports.defaults=e}}})),i=(n.defaults,n.getDefaults,n.changeDefaults,/[&<>"']/),o=/[&<>"']/g,a=/[<>"']|&(?!#?\w+;)/,s=/[<>"']|&(?!#?\w+;)/g,A={"&":"&","<":"<",">":">",'"':""","'":"'"},l=function(t){return A[t]},c=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function u(t){return t.replace(c,(function(t,e){return"colon"===(e=e.toLowerCase())?":":"#"===e.charAt(0)?"x"===e.charAt(1)?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""}))}var h=/(^|[^\[])\^/g,d=/[^\w:]/g,f=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i,p={},g=/^[^:]+:\/*[^/]*$/,m=/^([^:]+:)[\s\S]*$/,v=/^([^:]+:\/*[^/]*)[\s\S]*$/;function y(t,e){p[" "+t]||(g.test(t)?p[" "+t]=t+"/":p[" "+t]=w(t,"/",!0));var r=-1===(t=p[" "+t]).indexOf(":");return"//"===e.substring(0,2)?r?e:t.replace(m,"$1")+e:"/"===e.charAt(0)?r?e:t.replace(v,"$1")+e:t+e}function w(t,e,r){var n=t.length;if(0===n)return"";for(var i=0;i<n;){var o=t.charAt(n-i-1);if(o!==e||r){if(o===e||!r)break;i++}else i++}return t.substr(0,n-i)}var b=function(t,e){if(e){if(i.test(t))return t.replace(o,l)}else if(a.test(t))return t.replace(s,l);return t},C=u,B=function(t,e){t=t.source||t,e=e||"";var r={replace:function(e,n){return n=(n=n.source||n).replace(h,"$1"),t=t.replace(e,n),r},getRegex:function(){return new RegExp(t,e)}};return r},x=function(t,e,r){if(t){var n;try{n=decodeURIComponent(u(r)).replace(d,"").toLowerCase()}catch(t){return null}if(0===n.indexOf("javascript:")||0===n.indexOf("vbscript:")||0===n.indexOf("data:"))return null}e&&!f.test(r)&&(r=y(e,r));try{r=encodeURI(r).replace(/%25/g,"%")}catch(t){return null}return r},E={exec:function(){}},S=function(t){for(var e,r,n=1;n<arguments.length;n++)for(r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t},k=function(t,e){var r=t.replace(/\|/g,(function(t,e,r){for(var n=!1,i=e;--i>=0&&"\\"===r[i];)n=!n;return n?"|":" |"})).split(/ \|/),n=0;if(r.length>e)r.splice(e);else for(;r.length<e;)r.push("");for(;n<r.length;n++)r[n]=r[n].trim().replace(/\\\|/g,"|");return r},T=w,F=function(t,e){if(-1===t.indexOf(e[1]))return-1;for(var r=t.length,n=0,i=0;i<r;i++)if("\\"===t[i])i++;else if(t[i]===e[0])n++;else if(t[i]===e[1]&&--n<0)return i;return-1},L=function(t){t&&t.sanitize&&!t.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")},I=n.defaults,_=T,U=k,O=b,D=F;function Q(t,e,r){var n=e.href,i=e.title?O(e.title):null,o=t[1].replace(/\\([\[\]])/g,"$1");return"!"!==t[0].charAt(0)?{type:"link",raw:r,href:n,title:i,text:o}:{type:"image",raw:r,href:n,title:i,text:O(o)}}var M=function(){function t(t){this.options=t||I}var e=t.prototype;return e.space=function(t){var e=this.rules.block.newline.exec(t);if(e)return e[0].length>1?{type:"space",raw:e[0]}:{raw:"\n"}},e.code=function(t,e){var r=this.rules.block.code.exec(t);if(r){var n=e[e.length-1];if(n&&"paragraph"===n.type)return{raw:r[0],text:r[0].trimRight()};var i=r[0].replace(/^ {4}/gm,"");return{type:"code",raw:r[0],codeBlockStyle:"indented",text:this.options.pedantic?i:_(i,"\n")}}},e.fences=function(t){var e=this.rules.block.fences.exec(t);if(e){var r=e[0],n=function(t,e){var r=t.match(/^(\s+)(?:```)/);if(null===r)return e;var n=r[1];return e.split("\n").map((function(t){var e=t.match(/^\s+/);return null===e?t:e[0].length>=n.length?t.slice(n.length):t})).join("\n")}(r,e[3]||"");return{type:"code",raw:r,lang:e[2]?e[2].trim():e[2],text:n}}},e.heading=function(t){var e=this.rules.block.heading.exec(t);if(e)return{type:"heading",raw:e[0],depth:e[1].length,text:e[2]}},e.nptable=function(t){var e=this.rules.block.nptable.exec(t);if(e){var r={type:"table",header:U(e[1].replace(/^ *| *\| *$/g,"")),align:e[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:e[3]?e[3].replace(/\n$/,"").split("\n"):[],raw:e[0]};if(r.header.length===r.align.length){var n,i=r.align.length;for(n=0;n<i;n++)/^ *-+: *$/.test(r.align[n])?r.align[n]="right":/^ *:-+: *$/.test(r.align[n])?r.align[n]="center":/^ *:-+ *$/.test(r.align[n])?r.align[n]="left":r.align[n]=null;for(i=r.cells.length,n=0;n<i;n++)r.cells[n]=U(r.cells[n],r.header.length);return r}}},e.hr=function(t){var e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:e[0]}},e.blockquote=function(t){var e=this.rules.block.blockquote.exec(t);if(e){var r=e[0].replace(/^ *> ?/gm,"");return{type:"blockquote",raw:e[0],text:r}}},e.list=function(t){var e=this.rules.block.list.exec(t);if(e){for(var r,n,i,o,a,s,A,l=e[0],c=e[2],u=c.length>1,h=")"===c[c.length-1],d={type:"list",raw:l,ordered:u,start:u?+c.slice(0,-1):"",loose:!1,items:[]},f=e[0].match(this.rules.block.item),p=!1,g=f.length,m=0;m<g;m++)l=r=f[m],n=r.length,~(r=r.replace(/^ *([*+-]|\d+[.)]) */,"")).indexOf("\n ")&&(n-=r.length,r=this.options.pedantic?r.replace(/^ {1,4}/gm,""):r.replace(new RegExp("^ {1,"+n+"}","gm"),"")),m!==g-1&&(i=this.rules.block.bullet.exec(f[m+1])[0],(u?1===i.length||!h&&")"===i[i.length-1]:i.length>1||this.options.smartLists&&i!==c)&&(o=f.slice(m+1).join("\n"),d.raw=d.raw.substring(0,d.raw.length-o.length),m=g-1)),a=p||/\n\n(?!\s*$)/.test(r),m!==g-1&&(p="\n"===r.charAt(r.length-1),a||(a=p)),a&&(d.loose=!0),A=void 0,(s=/^\[[ xX]\] /.test(r))&&(A=" "!==r[1],r=r.replace(/^\[[ xX]\] +/,"")),d.items.push({type:"list_item",raw:l,task:s,checked:A,loose:a,text:r});return d}},e.html=function(t){var e=this.rules.block.html.exec(t);if(e)return{type:this.options.sanitize?"paragraph":"html",raw:e[0],pre:!this.options.sanitizer&&("pre"===e[1]||"script"===e[1]||"style"===e[1]),text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(e[0]):O(e[0]):e[0]}},e.def=function(t){var e=this.rules.block.def.exec(t);if(e)return e[3]&&(e[3]=e[3].substring(1,e[3].length-1)),{tag:e[1].toLowerCase().replace(/\s+/g," "),raw:e[0],href:e[2],title:e[3]}},e.table=function(t){var e=this.rules.block.table.exec(t);if(e){var r={type:"table",header:U(e[1].replace(/^ *| *\| *$/g,"")),align:e[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:e[3]?e[3].replace(/\n$/,"").split("\n"):[]};if(r.header.length===r.align.length){r.raw=e[0];var n,i=r.align.length;for(n=0;n<i;n++)/^ *-+: *$/.test(r.align[n])?r.align[n]="right":/^ *:-+: *$/.test(r.align[n])?r.align[n]="center":/^ *:-+ *$/.test(r.align[n])?r.align[n]="left":r.align[n]=null;for(i=r.cells.length,n=0;n<i;n++)r.cells[n]=U(r.cells[n].replace(/^ *\| *| *\| *$/g,""),r.header.length);return r}}},e.lheading=function(t){var e=this.rules.block.lheading.exec(t);if(e)return{type:"heading",raw:e[0],depth:"="===e[2].charAt(0)?1:2,text:e[1]}},e.paragraph=function(t){var e=this.rules.block.paragraph.exec(t);if(e)return{type:"paragraph",raw:e[0],text:"\n"===e[1].charAt(e[1].length-1)?e[1].slice(0,-1):e[1]}},e.text=function(t,e){var r=this.rules.block.text.exec(t);if(r){var n=e[e.length-1];return n&&"text"===n.type?{raw:r[0],text:r[0]}:{type:"text",raw:r[0],text:r[0]}}},e.escape=function(t){var e=this.rules.inline.escape.exec(t);if(e)return{type:"escape",raw:e[0],text:O(e[1])}},e.tag=function(t,e,r){var n=this.rules.inline.tag.exec(t);if(n)return!e&&/^<a /i.test(n[0])?e=!0:e&&/^<\/a>/i.test(n[0])&&(e=!1),!r&&/^<(pre|code|kbd|script)(\s|>)/i.test(n[0])?r=!0:r&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(n[0])&&(r=!1),{type:this.options.sanitize?"text":"html",raw:n[0],inLink:e,inRawBlock:r,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(n[0]):O(n[0]):n[0]}},e.link=function(t){var e=this.rules.inline.link.exec(t);if(e){var r=D(e[2],"()");if(r>-1){var n=(0===e[0].indexOf("!")?5:4)+e[1].length+r;e[2]=e[2].substring(0,r),e[0]=e[0].substring(0,n).trim(),e[3]=""}var i=e[2],o="";if(this.options.pedantic){var a=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(i);a?(i=a[1],o=a[3]):o=""}else o=e[3]?e[3].slice(1,-1):"";return Q(e,{href:(i=i.trim().replace(/^<([\s\S]*)>$/,"$1"))?i.replace(this.rules.inline._escapes,"$1"):i,title:o?o.replace(this.rules.inline._escapes,"$1"):o},e[0])}},e.reflink=function(t,e){var r;if((r=this.rules.inline.reflink.exec(t))||(r=this.rules.inline.nolink.exec(t))){var n=(r[2]||r[1]).replace(/\s+/g," ");if(!(n=e[n.toLowerCase()])||!n.href){var i=r[0].charAt(0);return{type:"text",raw:i,text:i}}return Q(r,n,r[0])}},e.strong=function(t,e,r){void 0===r&&(r="");var n=this.rules.inline.strong.start.exec(t);if(n&&(!n[1]||n[1]&&(""===r||this.rules.inline.punctuation.exec(r)))){e=e.slice(-1*t.length);var i,o="**"===n[0]?this.rules.inline.strong.endAst:this.rules.inline.strong.endUnd;for(o.lastIndex=0;null!=(n=o.exec(e));)if(i=this.rules.inline.strong.middle.exec(e.slice(0,n.index+3)))return{type:"strong",raw:t.slice(0,i[0].length),text:t.slice(2,i[0].length-2)}}},e.em=function(t,e,r){void 0===r&&(r="");var n=this.rules.inline.em.start.exec(t);if(n&&(!n[1]||n[1]&&(""===r||this.rules.inline.punctuation.exec(r)))){e=e.slice(-1*t.length);var i,o="*"===n[0]?this.rules.inline.em.endAst:this.rules.inline.em.endUnd;for(o.lastIndex=0;null!=(n=o.exec(e));)if(i=this.rules.inline.em.middle.exec(e.slice(0,n.index+2)))return{type:"em",raw:t.slice(0,i[0].length),text:t.slice(1,i[0].length-1)}}},e.codespan=function(t){var e=this.rules.inline.code.exec(t);if(e){var r=e[2].replace(/\n/g," "),n=/[^ ]/.test(r),i=r.startsWith(" ")&&r.endsWith(" ");return n&&i&&(r=r.substring(1,r.length-1)),r=O(r,!0),{type:"codespan",raw:e[0],text:r}}},e.br=function(t){var e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}},e.del=function(t){var e=this.rules.inline.del.exec(t);if(e)return{type:"del",raw:e[0],text:e[1]}},e.autolink=function(t,e){var r,n,i=this.rules.inline.autolink.exec(t);if(i)return n="@"===i[2]?"mailto:"+(r=O(this.options.mangle?e(i[1]):i[1])):r=O(i[1]),{type:"link",raw:i[0],text:r,href:n,tokens:[{type:"text",raw:r,text:r}]}},e.url=function(t,e){var r;if(r=this.rules.inline.url.exec(t)){var n,i;if("@"===r[2])i="mailto:"+(n=O(this.options.mangle?e(r[0]):r[0]));else{var o;do{o=r[0],r[0]=this.rules.inline._backpedal.exec(r[0])[0]}while(o!==r[0]);n=O(r[0]),i="www."===r[1]?"http://"+n:n}return{type:"link",raw:r[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}}},e.inlineText=function(t,e,r){var n,i=this.rules.inline.text.exec(t);if(i)return n=e?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(i[0]):O(i[0]):i[0]:O(this.options.smartypants?r(i[0]):i[0]),{type:"text",raw:i[0],text:n}},t}(),R=E,P=B,H=S,N={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?:\n+|$)|$)/,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6}) +([^\n]*?)(?: +#+)? *(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3})(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|<![A-Z][\\s\\S]*?>\\n*|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>\\n*|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$)|</(?!script|pre|style)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *<?([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,nptable:R,table:R,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/};N.def=P(N.def).replace("label",N._label).replace("title",N._title).getRegex(),N.bullet=/(?:[*+-]|\d{1,9}[.)])/,N.item=/^( *)(bull) ?[^\n]*(?:\n(?!\1bull ?)[^\n]*)*/,N.item=P(N.item,"gm").replace(/bull/g,N.bullet).getRegex(),N.list=P(N.list).replace(/bull/g,N.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+N.def.source+")").getRegex(),N._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",N._comment=/<!--(?!-?>)[\s\S]*?-->/,N.html=P(N.html,"i").replace("comment",N._comment).replace("tag",N._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),N.paragraph=P(N._paragraph).replace("hr",N.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",N._tag).getRegex(),N.blockquote=P(N.blockquote).replace("paragraph",N.paragraph).getRegex(),N.normal=H({},N),N.gfm=H({},N.normal,{nptable:"^ *([^|\\n ].*\\|.*)\\n *([-:]+ *\\|[-| :]*)(?:\\n((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)",table:"^ *\\|(.+)\\n *\\|?( *[-:]+[-| :]*)(?:\\n *((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),N.gfm.nptable=P(N.gfm.nptable).replace("hr",N.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",N._tag).getRegex(),N.gfm.table=P(N.gfm.table).replace("hr",N.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",N._tag).getRegex(),N.pedantic=H({},N.normal,{html:P("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",N._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,fences:R,paragraph:P(N.normal._paragraph).replace("hr",N.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",N.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var K={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:R,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/,nolink:/^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",strong:{start:/^(?:(\*\*(?=[*punctuation]))|\*\*)(?![\s])|__/,middle:/^\*\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*\*$|^__(?![\s])((?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?)__$/,endAst:/[^punctuation\s]\*\*(?!\*)|[punctuation]\*\*(?!\*)(?:(?=[punctuation\s]|$))/,endUnd:/[^\s]__(?!_)(?:(?=[punctuation\s])|$)/},em:{start:/^(?:(\*(?=[punctuation]))|\*)(?![*\s])|_/,middle:/^\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*$|^_(?![_\s])(?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?_$/,endAst:/[^punctuation\s]\*(?!\*)|[punctuation]\*(?!\*)(?:(?=[punctuation\s]|$))/,endUnd:/[^\s]_(?!_)(?:(?=[punctuation\s])|$)/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:R,text:/^(`+|[^`])(?:[\s\S]*?(?:(?=[\\<!\[`*]|\b_|$)|[^ ](?= {2,}\n))|(?= {2,}\n))/,punctuation:/^([\s*punctuation])/,_punctuation:"!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~"};K.punctuation=P(K.punctuation).replace(/punctuation/g,K._punctuation).getRegex(),K._blockSkip="\\[[^\\]]*?\\]\\([^\\)]*?\\)|`[^`]*?`|<[^>]*?>",K._overlapSkip="__[^_]*?__|\\*\\*\\[^\\*\\]*?\\*\\*",K.em.start=P(K.em.start).replace(/punctuation/g,K._punctuation).getRegex(),K.em.middle=P(K.em.middle).replace(/punctuation/g,K._punctuation).replace(/overlapSkip/g,K._overlapSkip).getRegex(),K.em.endAst=P(K.em.endAst,"g").replace(/punctuation/g,K._punctuation).getRegex(),K.em.endUnd=P(K.em.endUnd,"g").replace(/punctuation/g,K._punctuation).getRegex(),K.strong.start=P(K.strong.start).replace(/punctuation/g,K._punctuation).getRegex(),K.strong.middle=P(K.strong.middle).replace(/punctuation/g,K._punctuation).replace(/blockSkip/g,K._blockSkip).getRegex(),K.strong.endAst=P(K.strong.endAst,"g").replace(/punctuation/g,K._punctuation).getRegex(),K.strong.endUnd=P(K.strong.endUnd,"g").replace(/punctuation/g,K._punctuation).getRegex(),K.blockSkip=P(K._blockSkip,"g").getRegex(),K.overlapSkip=P(K._overlapSkip,"g").getRegex(),K._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,K._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,K._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,K.autolink=P(K.autolink).replace("scheme",K._scheme).replace("email",K._email).getRegex(),K._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,K.tag=P(K.tag).replace("comment",N._comment).replace("attribute",K._attribute).getRegex(),K._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,K._href=/<(?:\\[<>]?|[^\s<>\\])*>|[^\s\x00-\x1f]*/,K._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,K.link=P(K.link).replace("label",K._label).replace("href",K._href).replace("title",K._title).getRegex(),K.reflink=P(K.reflink).replace("label",K._label).getRegex(),K.reflinkSearch=P(K.reflinkSearch,"g").replace("reflink",K.reflink).replace("nolink",K.nolink).getRegex(),K.normal=H({},K),K.pedantic=H({},K.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:P(/^!?\[(label)\]\((.*?)\)/).replace("label",K._label).getRegex(),reflink:P(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",K._label).getRegex()}),K.gfm=H({},K.normal,{escape:P(K.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^~+(?=\S)([\s\S]*?\S)~+/,text:/^(`+|[^`])(?:[\s\S]*?(?:(?=[\\<!\[`*~]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@))|(?= {2,}\n|[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@))/}),K.gfm.url=P(K.gfm.url,"i").replace("email",K.gfm._extended_email).getRegex(),K.breaks=H({},K.gfm,{br:P(K.br).replace("{2,}","*").getRegex(),text:P(K.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()});var j={block:N,inline:K},G=n.defaults,V=j.block,z=j.inline;function W(t){return t.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…")}function Y(t){var e,r,n="",i=t.length;for(e=0;e<i;e++)r=t.charCodeAt(e),Math.random()>.5&&(r="x"+r.toString(16)),n+="&#"+r+";";return n}var X=function(){function e(t){this.tokens=[],this.tokens.links=Object.create(null),this.options=t||G,this.options.tokenizer=this.options.tokenizer||new M,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options;var e={block:V.normal,inline:z.normal};this.options.pedantic?(e.block=V.pedantic,e.inline=z.pedantic):this.options.gfm&&(e.block=V.gfm,this.options.breaks?e.inline=z.breaks:e.inline=z.gfm),this.tokenizer.rules=e}e.lex=function(t,r){return new e(r).lex(t)};var r,n,i,o=e.prototype;return o.lex=function(t){return t=t.replace(/\r\n|\r/g,"\n").replace(/\t/g," "),this.blockTokens(t,this.tokens,!0),this.inline(this.tokens),this.tokens},o.blockTokens=function(t,e,r){var n,i,o,a;for(void 0===e&&(e=[]),void 0===r&&(r=!0),t=t.replace(/^ +$/gm,"");t;)if(n=this.tokenizer.space(t))t=t.substring(n.raw.length),n.type&&e.push(n);else if(n=this.tokenizer.code(t,e))t=t.substring(n.raw.length),n.type?e.push(n):((a=e[e.length-1]).raw+="\n"+n.raw,a.text+="\n"+n.text);else if(n=this.tokenizer.fences(t))t=t.substring(n.raw.length),e.push(n);else if(n=this.tokenizer.heading(t))t=t.substring(n.raw.length),e.push(n);else if(n=this.tokenizer.nptable(t))t=t.substring(n.raw.length),e.push(n);else if(n=this.tokenizer.hr(t))t=t.substring(n.raw.length),e.push(n);else if(n=this.tokenizer.blockquote(t))t=t.substring(n.raw.length),n.tokens=this.blockTokens(n.text,[],r),e.push(n);else if(n=this.tokenizer.list(t)){for(t=t.substring(n.raw.length),o=n.items.length,i=0;i<o;i++)n.items[i].tokens=this.blockTokens(n.items[i].text,[],!1);e.push(n)}else if(n=this.tokenizer.html(t))t=t.substring(n.raw.length),e.push(n);else if(r&&(n=this.tokenizer.def(t)))t=t.substring(n.raw.length),this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title});else if(n=this.tokenizer.table(t))t=t.substring(n.raw.length),e.push(n);else if(n=this.tokenizer.lheading(t))t=t.substring(n.raw.length),e.push(n);else if(r&&(n=this.tokenizer.paragraph(t)))t=t.substring(n.raw.length),e.push(n);else if(n=this.tokenizer.text(t,e))t=t.substring(n.raw.length),n.type?e.push(n):((a=e[e.length-1]).raw+="\n"+n.raw,a.text+="\n"+n.text);else if(t){var s="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(s);break}throw new Error(s)}return e},o.inline=function(t){var e,r,n,i,o,a,s=t.length;for(e=0;e<s;e++)switch((a=t[e]).type){case"paragraph":case"text":case"heading":a.tokens=[],this.inlineTokens(a.text,a.tokens);break;case"table":for(a.tokens={header:[],cells:[]},i=a.header.length,r=0;r<i;r++)a.tokens.header[r]=[],this.inlineTokens(a.header[r],a.tokens.header[r]);for(i=a.cells.length,r=0;r<i;r++)for(o=a.cells[r],a.tokens.cells[r]=[],n=0;n<o.length;n++)a.tokens.cells[r][n]=[],this.inlineTokens(o[n],a.tokens.cells[r][n]);break;case"blockquote":this.inline(a.tokens);break;case"list":for(i=a.items.length,r=0;r<i;r++)this.inline(a.items[r].tokens)}return t},o.inlineTokens=function(t,e,r,n,i){var o;void 0===e&&(e=[]),void 0===r&&(r=!1),void 0===n&&(n=!1),void 0===i&&(i="");var a,s=t;if(this.tokens.links){var A=Object.keys(this.tokens.links);if(A.length>0)for(;null!=(a=this.tokenizer.rules.inline.reflinkSearch.exec(s));)A.includes(a[0].slice(a[0].lastIndexOf("[")+1,-1))&&(s=s.slice(0,a.index)+"["+"a".repeat(a[0].length-2)+"]"+s.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(a=this.tokenizer.rules.inline.blockSkip.exec(s));)s=s.slice(0,a.index)+"["+"a".repeat(a[0].length-2)+"]"+s.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;t;)if(o=this.tokenizer.escape(t))t=t.substring(o.raw.length),e.push(o);else if(o=this.tokenizer.tag(t,r,n))t=t.substring(o.raw.length),r=o.inLink,n=o.inRawBlock,e.push(o);else if(o=this.tokenizer.link(t))t=t.substring(o.raw.length),"link"===o.type&&(o.tokens=this.inlineTokens(o.text,[],!0,n)),e.push(o);else if(o=this.tokenizer.reflink(t,this.tokens.links))t=t.substring(o.raw.length),"link"===o.type&&(o.tokens=this.inlineTokens(o.text,[],!0,n)),e.push(o);else if(o=this.tokenizer.strong(t,s,i))t=t.substring(o.raw.length),o.tokens=this.inlineTokens(o.text,[],r,n),e.push(o);else if(o=this.tokenizer.em(t,s,i))t=t.substring(o.raw.length),o.tokens=this.inlineTokens(o.text,[],r,n),e.push(o);else if(o=this.tokenizer.codespan(t))t=t.substring(o.raw.length),e.push(o);else if(o=this.tokenizer.br(t))t=t.substring(o.raw.length),e.push(o);else if(o=this.tokenizer.del(t))t=t.substring(o.raw.length),o.tokens=this.inlineTokens(o.text,[],r,n),e.push(o);else if(o=this.tokenizer.autolink(t,Y))t=t.substring(o.raw.length),e.push(o);else if(r||!(o=this.tokenizer.url(t,Y))){if(o=this.tokenizer.inlineText(t,n,W))t=t.substring(o.raw.length),i=o.raw.slice(-1),e.push(o);else if(t){var l="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(l);break}throw new Error(l)}}else t=t.substring(o.raw.length),e.push(o);return e},r=e,i=[{key:"rules",get:function(){return{block:V,inline:z}}}],(n=null)&&t(r.prototype,n),i&&t(r,i),e}(),q=n.defaults,J=x,Z=b,$=function(){function t(t){this.options=t||q}var e=t.prototype;return e.code=function(t,e,r){var n=(e||"").match(/\S*/)[0];if(this.options.highlight){var i=this.options.highlight(t,n);null!=i&&i!==t&&(r=!0,t=i)}return n?'<pre><code class="'+this.options.langPrefix+Z(n,!0)+'">'+(r?t:Z(t,!0))+"</code></pre>\n":"<pre><code>"+(r?t:Z(t,!0))+"</code></pre>\n"},e.blockquote=function(t){return"<blockquote>\n"+t+"</blockquote>\n"},e.html=function(t){return t},e.heading=function(t,e,r,n){return this.options.headerIds?"<h"+e+' id="'+this.options.headerPrefix+n.slug(r)+'">'+t+"</h"+e+">\n":"<h"+e+">"+t+"</h"+e+">\n"},e.hr=function(){return this.options.xhtml?"<hr/>\n":"<hr>\n"},e.list=function(t,e,r){var n=e?"ol":"ul";return"<"+n+(e&&1!==r?' start="'+r+'"':"")+">\n"+t+"</"+n+">\n"},e.listitem=function(t){return"<li>"+t+"</li>\n"},e.checkbox=function(t){return"<input "+(t?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "},e.paragraph=function(t){return"<p>"+t+"</p>\n"},e.table=function(t,e){return e&&(e="<tbody>"+e+"</tbody>"),"<table>\n<thead>\n"+t+"</thead>\n"+e+"</table>\n"},e.tablerow=function(t){return"<tr>\n"+t+"</tr>\n"},e.tablecell=function(t,e){var r=e.header?"th":"td";return(e.align?"<"+r+' align="'+e.align+'">':"<"+r+">")+t+"</"+r+">\n"},e.strong=function(t){return"<strong>"+t+"</strong>"},e.em=function(t){return"<em>"+t+"</em>"},e.codespan=function(t){return"<code>"+t+"</code>"},e.br=function(){return this.options.xhtml?"<br/>":"<br>"},e.del=function(t){return"<del>"+t+"</del>"},e.link=function(t,e,r){if(null===(t=J(this.options.sanitize,this.options.baseUrl,t)))return r;var n='<a href="'+Z(t)+'"';return e&&(n+=' title="'+e+'"'),n+=">"+r+"</a>"},e.image=function(t,e,r){if(null===(t=J(this.options.sanitize,this.options.baseUrl,t)))return r;var n='<img src="'+t+'" alt="'+r+'"';return e&&(n+=' title="'+e+'"'),n+=this.options.xhtml?"/>":">"},e.text=function(t){return t},t}(),tt=function(){function t(){}var e=t.prototype;return e.strong=function(t){return t},e.em=function(t){return t},e.codespan=function(t){return t},e.del=function(t){return t},e.html=function(t){return t},e.text=function(t){return t},e.link=function(t,e,r){return""+r},e.image=function(t,e,r){return""+r},e.br=function(){return""},t}(),et=function(){function t(){this.seen={}}return t.prototype.slug=function(t){var e=t.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-");if(this.seen.hasOwnProperty(e)){var r=e;do{this.seen[r]++,e=r+"-"+this.seen[r]}while(this.seen.hasOwnProperty(e))}return this.seen[e]=0,e},t}(),rt=n.defaults,nt=C,it=function(){function t(t){this.options=t||rt,this.options.renderer=this.options.renderer||new $,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new tt,this.slugger=new et}t.parse=function(e,r){return new t(r).parse(e)};var e=t.prototype;return e.parse=function(t,e){void 0===e&&(e=!0);var r,n,i,o,a,s,A,l,c,u,h,d,f,p,g,m,v,y,w="",b=t.length;for(r=0;r<b;r++)switch((u=t[r]).type){case"space":continue;case"hr":w+=this.renderer.hr();continue;case"heading":w+=this.renderer.heading(this.parseInline(u.tokens),u.depth,nt(this.parseInline(u.tokens,this.textRenderer)),this.slugger);continue;case"code":w+=this.renderer.code(u.text,u.lang,u.escaped);continue;case"table":for(l="",A="",o=u.header.length,n=0;n<o;n++)A+=this.renderer.tablecell(this.parseInline(u.tokens.header[n]),{header:!0,align:u.align[n]});for(l+=this.renderer.tablerow(A),c="",o=u.cells.length,n=0;n<o;n++){for(A="",a=(s=u.tokens.cells[n]).length,i=0;i<a;i++)A+=this.renderer.tablecell(this.parseInline(s[i]),{header:!1,align:u.align[i]});c+=this.renderer.tablerow(A)}w+=this.renderer.table(l,c);continue;case"blockquote":c=this.parse(u.tokens),w+=this.renderer.blockquote(c);continue;case"list":for(h=u.ordered,d=u.start,f=u.loose,o=u.items.length,c="",n=0;n<o;n++)m=(g=u.items[n]).checked,v=g.task,p="",g.task&&(y=this.renderer.checkbox(m),f?g.tokens.length>0&&"text"===g.tokens[0].type?(g.tokens[0].text=y+" "+g.tokens[0].text,g.tokens[0].tokens&&g.tokens[0].tokens.length>0&&"text"===g.tokens[0].tokens[0].type&&(g.tokens[0].tokens[0].text=y+" "+g.tokens[0].tokens[0].text)):g.tokens.unshift({type:"text",text:y}):p+=y),p+=this.parse(g.tokens,f),c+=this.renderer.listitem(p,v,m);w+=this.renderer.list(c,h,d);continue;case"html":w+=this.renderer.html(u.text);continue;case"paragraph":w+=this.renderer.paragraph(this.parseInline(u.tokens));continue;case"text":for(c=u.tokens?this.parseInline(u.tokens):u.text;r+1<b&&"text"===t[r+1].type;)c+="\n"+((u=t[++r]).tokens?this.parseInline(u.tokens):u.text);w+=e?this.renderer.paragraph(c):c;continue;default:var C='Token with "'+u.type+'" type was not found.';if(this.options.silent)return void console.error(C);throw new Error(C)}return w},e.parseInline=function(t,e){e=e||this.renderer;var r,n,i="",o=t.length;for(r=0;r<o;r++)switch((n=t[r]).type){case"escape":i+=e.text(n.text);break;case"html":i+=e.html(n.text);break;case"link":i+=e.link(n.href,n.title,this.parseInline(n.tokens,e));break;case"image":i+=e.image(n.href,n.title,n.text);break;case"strong":i+=e.strong(this.parseInline(n.tokens,e));break;case"em":i+=e.em(this.parseInline(n.tokens,e));break;case"codespan":i+=e.codespan(n.text);break;case"br":i+=e.br();break;case"del":i+=e.del(this.parseInline(n.tokens,e));break;case"text":i+=e.text(n.text);break;default:var a='Token with "'+n.type+'" type was not found.';if(this.options.silent)return void console.error(a);throw new Error(a)}return i},t}(),ot=S,at=L,st=b,At=n.getDefaults,lt=n.changeDefaults,ct=n.defaults;function ut(t,e,r){if(null==t)throw new Error("marked(): input parameter is undefined or null");if("string"!=typeof t)throw new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected");if("function"==typeof e&&(r=e,e=null),e=ot({},ut.defaults,e||{}),at(e),r){var n,i=e.highlight;try{n=X.lex(t,e)}catch(t){return r(t)}var o=function(t){var o;if(!t)try{o=it.parse(n,e)}catch(e){t=e}return e.highlight=i,t?r(t):r(null,o)};if(!i||i.length<3)return o();if(delete e.highlight,!n.length)return o();var a=0;return ut.walkTokens(n,(function(t){"code"===t.type&&(a++,setTimeout((function(){i(t.text,t.lang,(function(e,r){if(e)return o(e);null!=r&&r!==t.text&&(t.text=r,t.escaped=!0),0==--a&&o()}))}),0))})),void(0===a&&o())}try{var s=X.lex(t,e);return e.walkTokens&&ut.walkTokens(s,e.walkTokens),it.parse(s,e)}catch(t){if(t.message+="\nPlease report this to https://github.com/markedjs/marked.",e.silent)return"<p>An error occurred:</p><pre>"+st(t.message+"",!0)+"</pre>";throw t}}return ut.options=ut.setOptions=function(t){return ot(ut.defaults,t),lt(ut.defaults),ut},ut.getDefaults=At,ut.defaults=ct,ut.use=function(t){var e=ot({},t);if(t.renderer&&function(){var r=ut.defaults.renderer||new $,n=function(e){var n=r[e];r[e]=function(){for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];var s=t.renderer[e].apply(r,o);return!1===s&&(s=n.apply(r,o)),s}};for(var i in t.renderer)n(i);e.renderer=r}(),t.tokenizer&&function(){var r=ut.defaults.tokenizer||new M,n=function(e){var n=r[e];r[e]=function(){for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];var s=t.tokenizer[e].apply(r,o);return!1===s&&(s=n.apply(r,o)),s}};for(var i in t.tokenizer)n(i);e.tokenizer=r}(),t.walkTokens){var r=ut.defaults.walkTokens;e.walkTokens=function(e){t.walkTokens(e),r&&r(e)}}ut.setOptions(e)},ut.walkTokens=function(t,e){for(var n,i=r(t);!(n=i()).done;){var o=n.value;switch(e(o),o.type){case"table":for(var a,s=r(o.tokens.header);!(a=s()).done;){var A=a.value;ut.walkTokens(A,e)}for(var l,c=r(o.tokens.cells);!(l=c()).done;)for(var u,h=r(l.value);!(u=h()).done;){var d=u.value;ut.walkTokens(d,e)}break;case"list":ut.walkTokens(o.items,e);break;default:o.tokens&&ut.walkTokens(o.tokens,e)}}},ut.Parser=it,ut.parser=it.parse,ut.Renderer=$,ut.TextRenderer=tt,ut.Lexer=X,ut.lexer=X.lex,ut.Tokenizer=M,ut.Slugger=et,ut.parse=ut,ut}()},ELLl:
|
|
|
/*!*************************************************************!*\
|
|
|
!*** ./node_modules/codemirror/addon/edit/closebrackets.js ***!
|
|
|
\*************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){!function(t){var e={pairs:"()[]{}''\"\"",closeBefore:")]}'\":;>",triples:"",explode:"[]{}"},r=t.Pos;function n(t,r){return"pairs"==r&&"string"==typeof t?t:"object"==typeof t&&null!=t[r]?t[r]:e[r]}t.defineOption("autoCloseBrackets",!1,(function(e,r,a){a&&a!=t.Init&&(e.removeKeyMap(i),e.state.closeBrackets=null),r&&(o(n(r,"pairs")),e.state.closeBrackets=r,e.addKeyMap(i))}));var i={Backspace:function(e){var i=s(e);if(!i||e.getOption("disableInput"))return t.Pass;for(var o=n(i,"pairs"),a=e.listSelections(),l=0;l<a.length;l++){if(!a[l].empty())return t.Pass;var c=A(e,a[l].head);if(!c||o.indexOf(c)%2!=0)return t.Pass}for(l=a.length-1;l>=0;l--){var u=a[l].head;e.replaceRange("",r(u.line,u.ch-1),r(u.line,u.ch+1),"+delete")}},Enter:function(e){var r=s(e),i=r&&n(r,"explode");if(!i||e.getOption("disableInput"))return t.Pass;for(var o=e.listSelections(),a=0;a<o.length;a++){if(!o[a].empty())return t.Pass;var l=A(e,o[a].head);if(!l||i.indexOf(l)%2!=0)return t.Pass}e.operation((function(){var t=e.lineSeparator()||"\n";e.replaceSelection(t+t,null),e.execCommand("goCharLeft"),o=e.listSelections();for(var r=0;r<o.length;r++){var n=o[r].head.line;e.indentLine(n,null,!0),e.indentLine(n+1,null,!0)}}))}};function o(t){for(var e=0;e<t.length;e++){var r=t.charAt(e),n="'"+r+"'";i[n]||(i[n]=a(r))}}function a(e){return function(i){return function(e,i){var o=s(e);if(!o||e.getOption("disableInput"))return t.Pass;var a=n(o,"pairs"),A=a.indexOf(i);if(-1==A)return t.Pass;for(var c,u=n(o,"closeBefore"),h=n(o,"triples"),d=a.charAt(A+1)==i,f=e.listSelections(),p=A%2==0,g=0;g<f.length;g++){var m,v=f[g],y=v.head,w=e.getRange(y,r(y.line,y.ch+1));if(p&&!v.empty())m="surround";else if(!d&&p||w!=i)if(d&&y.ch>1&&h.indexOf(i)>=0&&e.getRange(r(y.line,y.ch-2),y)==i+i){if(y.ch>2&&/\bstring/.test(e.getTokenTypeAt(r(y.line,y.ch-2))))return t.Pass;m="addFour"}else if(d){var b=0==y.ch?" ":e.getRange(r(y.line,y.ch-1),y);if(t.isWordChar(w)||b==i||t.isWordChar(b))return t.Pass;m="both"}else{if(!p||!(0===w.length||/\s/.test(w)||u.indexOf(w)>-1))return t.Pass;m="both"}else m=d&&l(e,y)?"both":h.indexOf(i)>=0&&e.getRange(y,r(y.line,y.ch+3))==i+i+i?"skipThree":"skip";if(c){if(c!=m)return t.Pass}else c=m}var C=A%2?a.charAt(A-1):i,B=A%2?i:a.charAt(A+1);e.operation((function(){if("skip"==c)e.execCommand("goCharRight");else if("skipThree"==c)for(var n=0;n<3;n++)e.execCommand("goCharRight");else if("surround"==c){var i=e.getSelections();for(n=0;n<i.length;n++)i[n]=C+i[n]+B;for(e.replaceSelections(i,"around"),i=e.listSelections().slice(),n=0;n<i.length;n++)i[n]=(o=i[n],a=void 0,a=t.cmpPos(o.anchor,o.head)>0,{anchor:new r(o.anchor.line,o.anchor.ch+(a?-1:1)),head:new r(o.head.line,o.head.ch+(a?1:-1))});e.setSelections(i)}else"both"==c?(e.replaceSelection(C+B,null),e.triggerElectric(C+B),e.execCommand("goCharLeft")):"addFour"==c&&(e.replaceSelection(C+C+C+C,"before"),e.execCommand("goCharRight"));var o,a}))}(i,e)}}function s(t){var e=t.state.closeBrackets;return!e||e.override?e:t.getModeAt(t.getCursor()).closeBrackets||e}function A(t,e){var n=t.getRange(r(e.line,e.ch-1),r(e.line,e.ch+1));return 2==n.length?n:null}function l(t,e){var n=t.getTokenAt(r(e.line,e.ch+1));return/\bstring/.test(n.type)&&n.start==e.ch&&(0==e.ch||!/\bstring/.test(t.getTokenTypeAt(e)))}o(e.pairs+"`")}(r(/*! ../../lib/codemirror */"VrN/"))},Fofx:
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/matrix.js ***!
|
|
|
\*************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r="undefined"==typeof Float32Array?Array:Float32Array;function n(){var t=new r(6);return i(t),t}function i(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function o(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t}e.create=n,e.identity=i,e.copy=o,e.mul=function(t,e,r){var n=e[0]*r[0]+e[2]*r[1],i=e[1]*r[0]+e[3]*r[1],o=e[0]*r[2]+e[2]*r[3],a=e[1]*r[2]+e[3]*r[3],s=e[0]*r[4]+e[2]*r[5]+e[4],A=e[1]*r[4]+e[3]*r[5]+e[5];return t[0]=n,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=A,t},e.translate=function(t,e,r){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4]+r[0],t[5]=e[5]+r[1],t},e.rotate=function(t,e,r){var n=e[0],i=e[2],o=e[4],a=e[1],s=e[3],A=e[5],l=Math.sin(r),c=Math.cos(r);return t[0]=n*c+a*l,t[1]=-n*l+a*c,t[2]=i*c+s*l,t[3]=-i*l+c*s,t[4]=c*o+l*A,t[5]=c*A-l*o,t},e.scale=function(t,e,r){var n=r[0],i=r[1];return t[0]=e[0]*n,t[1]=e[1]*i,t[2]=e[2]*n,t[3]=e[3]*i,t[4]=e[4]*n,t[5]=e[5]*i,t},e.invert=function(t,e){var r=e[0],n=e[2],i=e[4],o=e[1],a=e[3],s=e[5],A=r*a-o*n;return A?(A=1/A,t[0]=a*A,t[1]=-o*A,t[2]=-n*A,t[3]=r*A,t[4]=(n*s-a*i)*A,t[5]=(o*i-r*s)*A,t):null},e.clone=function(t){var e=n();return o(e,t),e}},FxDU:
|
|
|
/*!*******************************************************!*\
|
|
|
!*** ./node_modules/size-sensor/lib/sensors/index.js ***!
|
|
|
\*******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createSensor=void 0;var n=r(/*! ./object */"QO+J"),i=r(/*! ./resizeObserver */"j5sG"),o="undefined"!=typeof ResizeObserver?i.createSensor:n.createSensor;e.createSensor=o},Gev7:
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/Displayable.js ***!
|
|
|
\*********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/util */"bYtY"),i=r(/*! ./Style */"K2GJ"),o=r(/*! ../Element */"1bdT"),a=r(/*! ./mixin/RectText */"ni6a");function s(t){for(var e in t=t||{},o.call(this,t),t)t.hasOwnProperty(e)&&"style"!==e&&(this[e]=t[e]);this.style=new i(t.style,this),this._rect=null,this.__clipPaths=null}s.prototype={constructor:s,type:"displayable",__dirty:!0,invisible:!1,z:0,z2:0,zlevel:0,draggable:!1,dragging:!1,silent:!1,culling:!1,cursor:"pointer",rectHover:!1,progressive:!1,incremental:!1,globalScaleRatio:1,beforeBrush:function(t){},afterBrush:function(t){},brush:function(t,e){},getBoundingRect:function(){},contain:function(t,e){return this.rectContain(t,e)},traverse:function(t,e){t.call(e,this)},rectContain:function(t,e){var r=this.transformCoordToLocal(t,e);return this.getBoundingRect().contain(r[0],r[1])},dirty:function(){this.__dirty=this.__dirtyText=!0,this._rect=null,this.__zr&&this.__zr.refresh()},animateStyle:function(t){return this.animate("style",t)},attrKV:function(t,e){"style"!==t?o.prototype.attrKV.call(this,t,e):this.style.set(e)},setStyle:function(t,e){return this.style.set(t,e),this.dirty(!1),this},useStyle:function(t){return this.style=new i(t,this),this.dirty(!1),this},calculateTextPosition:null},n.inherits(s,o),n.mixin(s,a);var A=s;t.exports=A},Gytx:
|
|
|
/*!********************************************!*\
|
|
|
!*** ./node_modules/shallowequal/index.js ***!
|
|
|
\********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){t.exports=function(t,e,r,n){var i=r?r.call(n,t,e):void 0;if(void 0!==i)return!!i;if(t===e)return!0;if("object"!=typeof t||!t||"object"!=typeof e||!e)return!1;var o=Object.keys(t),a=Object.keys(e);if(o.length!==a.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(e),A=0;A<o.length;A++){var l=o[A];if(!s(l))return!1;var c=t[l],u=e[l];if(!1===(i=r?r.call(n,c,u,l):void 0)||void 0===i&&c!==u)return!1}return!0}},H38U:
|
|
|
/*!******************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/QRCode.js ***!
|
|
|
\******************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./8BitByte */"f4xo"),i=r(/*! ./RSBlock */"rcnY"),o=r(/*! ./BitBuffer */"wU8J"),a=r(/*! ./util */"Iq15"),s=r(/*! ./Polynomial */"dWSS");function A(t,e){this.typeNumber=t,this.errorCorrectLevel=e,this.modules=null,this.moduleCount=0,this.dataCache=null,this.dataList=[]}var l=A.prototype;l.addData=function(t){var e=new n(t);this.dataList.push(e),this.dataCache=null},l.isDark=function(t,e){if(t<0||this.moduleCount<=t||e<0||this.moduleCount<=e)throw new Error(t+","+e);return this.modules[t][e]},l.getModuleCount=function(){return this.moduleCount},l.make=function(){if(this.typeNumber<1){var t=1;for(t=1;t<40;t++){for(var e=i.getRSBlocks(t,this.errorCorrectLevel),r=new o,n=0,s=0;s<e.length;s++)n+=e[s].dataCount;for(s=0;s<this.dataList.length;s++){var A=this.dataList[s];r.put(A.mode,4),r.put(A.getLength(),a.getLengthInBits(A.mode,t)),A.write(r)}if(r.getLengthInBits()<=8*n)break}this.typeNumber=t}this.makeImpl(!1,this.getBestMaskPattern())},l.makeImpl=function(t,e){this.moduleCount=4*this.typeNumber+17,this.modules=new Array(this.moduleCount);for(var r=0;r<this.moduleCount;r++){this.modules[r]=new Array(this.moduleCount);for(var n=0;n<this.moduleCount;n++)this.modules[r][n]=null}this.setupPositionProbePattern(0,0),this.setupPositionProbePattern(this.moduleCount-7,0),this.setupPositionProbePattern(0,this.moduleCount-7),this.setupPositionAdjustPattern(),this.setupTimingPattern(),this.setupTypeInfo(t,e),this.typeNumber>=7&&this.setupTypeNumber(t),null==this.dataCache&&(this.dataCache=A.createData(this.typeNumber,this.errorCorrectLevel,this.dataList)),this.mapData(this.dataCache,e)},l.setupPositionProbePattern=function(t,e){for(var r=-1;r<=7;r++)if(!(t+r<=-1||this.moduleCount<=t+r))for(var n=-1;n<=7;n++)e+n<=-1||this.moduleCount<=e+n||(this.modules[t+r][e+n]=0<=r&&r<=6&&(0==n||6==n)||0<=n&&n<=6&&(0==r||6==r)||2<=r&&r<=4&&2<=n&&n<=4)},l.getBestMaskPattern=function(){for(var t=0,e=0,r=0;r<8;r++){this.makeImpl(!0,r);var n=a.getLostPoint(this);(0==r||t>n)&&(t=n,e=r)}return e},l.createMovieClip=function(t,e,r){var n=t.createEmptyMovieClip(e,r);this.make();for(var i=0;i<this.modules.length;i++)for(var o=1*i,a=0;a<this.modules[i].length;a++){var s=1*a;this.modules[i][a]&&(n.beginFill(0,100),n.moveTo(s,o),n.lineTo(s+1,o),n.lineTo(s+1,o+1),n.lineTo(s,o+1),n.endFill())}return n},l.setupTimingPattern=function(){for(var t=8;t<this.moduleCount-8;t++)null==this.modules[t][6]&&(this.modules[t][6]=t%2==0);for(var e=8;e<this.moduleCount-8;e++)null==this.modules[6][e]&&(this.modules[6][e]=e%2==0)},l.setupPositionAdjustPattern=function(){for(var t=a.getPatternPosition(this.typeNumber),e=0;e<t.length;e++)for(var r=0;r<t.length;r++){var n=t[e],i=t[r];if(null==this.modules[n][i])for(var o=-2;o<=2;o++)for(var s=-2;s<=2;s++)this.modules[n+o][i+s]=-2==o||2==o||-2==s||2==s||0==o&&0==s}},l.setupTypeNumber=function(t){for(var e=a.getBCHTypeNumber(this.typeNumber),r=0;r<18;r++){var n=!t&&1==(e>>r&1);this.modules[Math.floor(r/3)][r%3+this.moduleCount-8-3]=n}for(r=0;r<18;r++){n=!t&&1==(e>>r&1);this.modules[r%3+this.moduleCount-8-3][Math.floor(r/3)]=n}},l.setupTypeInfo=function(t,e){for(var r=this.errorCorrectLevel<<3|e,n=a.getBCHTypeInfo(r),i=0;i<15;i++){var o=!t&&1==(n>>i&1);i<6?this.modules[i][8]=o:i<8?this.modules[i+1][8]=o:this.modules[this.moduleCount-15+i][8]=o}for(i=0;i<15;i++){o=!t&&1==(n>>i&1);i<8?this.modules[8][this.moduleCount-i-1]=o:i<9?this.modules[8][15-i-1+1]=o:this.modules[8][15-i-1]=o}this.modules[this.moduleCount-8][8]=!t},l.mapData=function(t,e){for(var r=-1,n=this.moduleCount-1,i=7,o=0,s=this.moduleCount-1;s>0;s-=2)for(6==s&&s--;;){for(var A=0;A<2;A++)if(null==this.modules[n][s-A]){var l=!1;o<t.length&&(l=1==(t[o]>>>i&1)),a.getMask(e,n,s-A)&&(l=!l),this.modules[n][s-A]=l,-1==--i&&(o++,i=7)}if((n+=r)<0||this.moduleCount<=n){n-=r,r=-r;break}}},A.PAD0=236,A.PAD1=17,A.createData=function(t,e,r){for(var n=i.getRSBlocks(t,e),s=new o,l=0;l<r.length;l++){var c=r[l];s.put(c.mode,4),s.put(c.getLength(),a.getLengthInBits(c.mode,t)),c.write(s)}var u=0;for(l=0;l<n.length;l++)u+=n[l].dataCount;if(s.getLengthInBits()>8*u)throw new Error("code length overflow. ("+s.getLengthInBits()+">"+8*u+")");for(s.getLengthInBits()+4<=8*u&&s.put(0,4);s.getLengthInBits()%8!=0;)s.putBit(!1);for(;!(s.getLengthInBits()>=8*u||(s.put(A.PAD0,8),s.getLengthInBits()>=8*u));)s.put(A.PAD1,8);return A.createBytes(s,n)},A.createBytes=function(t,e){for(var r=0,n=0,i=0,o=new Array(e.length),A=new Array(e.length),l=0;l<e.length;l++){var c=e[l].dataCount,u=e[l].totalCount-c;n=Math.max(n,c),i=Math.max(i,u),o[l]=new Array(c);for(var h=0;h<o[l].length;h++)o[l][h]=255&t.buffer[h+r];r+=c;var d=a.getErrorCorrectPolynomial(u),f=new s(o[l],d.getLength()-1).mod(d);A[l]=new Array(d.getLength()-1);for(h=0;h<A[l].length;h++){var p=h+f.getLength()-A[l].length;A[l][h]=p>=0?f.get(p):0}}var g=0;for(h=0;h<e.length;h++)g+=e[h].totalCount;var m=new Array(g),v=0;for(h=0;h<n;h++)for(l=0;l<e.length;l++)h<o[l].length&&(m[v++]=o[l][h]);for(h=0;h<i;h++)for(l=0;l<e.length;l++)h<A[l].length&&(m[v++]=A[l][h]);return m},t.exports=A},H6uX:
|
|
|
/*!****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/mixin/Eventful.js ***!
|
|
|
\****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=Array.prototype.slice,n=function(t){this._$handlers={},this._$eventProcessor=t};function i(t,e,r,n,i,o){var a=t._$handlers;if("function"==typeof r&&(i=n,n=r,r=null),!n||!e)return t;r=function(t,e){var r=t._$eventProcessor;return null!=e&&r&&r.normalizeQuery&&(e=r.normalizeQuery(e)),e}(t,r),a[e]||(a[e]=[]);for(var s=0;s<a[e].length;s++)if(a[e][s].h===n)return t;var A={h:n,one:o,query:r,ctx:i||t,callAtLast:n.zrEventfulCallAtLast},l=a[e].length-1,c=a[e][l];return c&&c.callAtLast?a[e].splice(l,0,A):a[e].push(A),t}n.prototype={constructor:n,one:function(t,e,r,n){return i(this,t,e,r,n,!0)},on:function(t,e,r,n){return i(this,t,e,r,n,!1)},isSilent:function(t){var e=this._$handlers;return!e[t]||!e[t].length},off:function(t,e){var r=this._$handlers;if(!t)return this._$handlers={},this;if(e){if(r[t]){for(var n=[],i=0,o=r[t].length;i<o;i++)r[t][i].h!==e&&n.push(r[t][i]);r[t]=n}r[t]&&0===r[t].length&&delete r[t]}else delete r[t];return this},trigger:function(t){var e=this._$handlers[t],n=this._$eventProcessor;if(e){var i=arguments,o=i.length;o>3&&(i=r.call(i,1));for(var a=e.length,s=0;s<a;){var A=e[s];if(n&&n.filter&&null!=A.query&&!n.filter(t,A.query))s++;else{switch(o){case 1:A.h.call(A.ctx);break;case 2:A.h.call(A.ctx,i[1]);break;case 3:A.h.call(A.ctx,i[1],i[2]);break;default:A.h.apply(A.ctx,i)}A.one?(e.splice(s,1),a--):s++}}}return n&&n.afterTrigger&&n.afterTrigger(t),this},triggerWithContext:function(t){var e=this._$handlers[t],n=this._$eventProcessor;if(e){var i=arguments,o=i.length;o>4&&(i=r.call(i,1,i.length-1));for(var a=i[i.length-1],s=e.length,A=0;A<s;){var l=e[A];if(n&&n.filter&&null!=l.query&&!n.filter(t,l.query))A++;else{switch(o){case 1:l.h.call(a);break;case 2:l.h.call(a,i[1]);break;case 3:l.h.call(a,i[1],i[2]);break;default:l.h.apply(a,i)}l.one?(e.splice(A,1),s--):A++}}}return n&&n.afterTrigger&&n.afterTrigger(t),this}};var o=n;t.exports=o},H7XF:
|
|
|
/*!*****************************************!*\
|
|
|
!*** ./node_modules/base64-js/index.js ***!
|
|
|
\*****************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";e.byteLength=function(t){var e=l(t),r=e[0],n=e[1];return 3*(r+n)/4-n},e.toByteArray=function(t){var e,r,n=l(t),a=n[0],s=n[1],A=new o(function(t,e,r){return 3*(e+r)/4-r}(0,a,s)),c=0,u=s>0?a-4:a;for(r=0;r<u;r+=4)e=i[t.charCodeAt(r)]<<18|i[t.charCodeAt(r+1)]<<12|i[t.charCodeAt(r+2)]<<6|i[t.charCodeAt(r+3)],A[c++]=e>>16&255,A[c++]=e>>8&255,A[c++]=255&e;2===s&&(e=i[t.charCodeAt(r)]<<2|i[t.charCodeAt(r+1)]>>4,A[c++]=255&e);1===s&&(e=i[t.charCodeAt(r)]<<10|i[t.charCodeAt(r+1)]<<4|i[t.charCodeAt(r+2)]>>2,A[c++]=e>>8&255,A[c++]=255&e);return A},e.fromByteArray=function(t){for(var e,r=t.length,i=r%3,o=[],a=0,s=r-i;a<s;a+=16383)o.push(c(t,a,a+16383>s?s:a+16383));1===i?(e=t[r-1],o.push(n[e>>2]+n[e<<4&63]+"==")):2===i&&(e=(t[r-2]<<8)+t[r-1],o.push(n[e>>10]+n[e>>4&63]+n[e<<2&63]+"="));return o.join("")};for(var n=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,A=a.length;s<A;++s)n[s]=a[s],i[a.charCodeAt(s)]=s;function l(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");return-1===r&&(r=e),[r,r===e?0:4-r%4]}function c(t,e,r){for(var i,o,a=[],s=e;s<r;s+=3)i=(t[s]<<16&16711680)+(t[s+1]<<8&65280)+(255&t[s+2]),a.push(n[(o=i)>>18&63]+n[o>>12&63]+n[o>>6&63]+n[63&o]);return a.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},HDXh:
|
|
|
/*!*********************************************************************!*\
|
|
|
!*** ./node_modules/node-libs-browser/node_modules/buffer/index.js ***!
|
|
|
\*********************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";(function(t){
|
|
|
/*!
|
|
|
* The buffer module from node.js, for the browser.
|
|
|
*
|
|
|
* @author Feross Aboukhadijeh <http://feross.org>
|
|
|
* @license MIT
|
|
|
*/
|
|
|
var n=r(/*! base64-js */"H7XF"),i=r(/*! ieee754 */"kVK+"),o=r(/*! isarray */"49sm");function a(){return A.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(t,e){if(a()<e)throw new RangeError("Invalid typed array length");return A.TYPED_ARRAY_SUPPORT?(t=new Uint8Array(e)).__proto__=A.prototype:(null===t&&(t=new A(e)),t.length=e),t}function A(t,e,r){if(!(A.TYPED_ARRAY_SUPPORT||this instanceof A))return new A(t,e,r);if("number"==typeof t){if("string"==typeof e)throw new Error("If encoding is specified then the first argument must be a string");return u(this,t)}return l(this,t,e,r)}function l(t,e,r,n){if("number"==typeof e)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&e instanceof ArrayBuffer?function(t,e,r,n){if(e.byteLength,r<0||e.byteLength<r)throw new RangeError("'offset' is out of bounds");if(e.byteLength<r+(n||0))throw new RangeError("'length' is out of bounds");e=void 0===r&&void 0===n?new Uint8Array(e):void 0===n?new Uint8Array(e,r):new Uint8Array(e,r,n);A.TYPED_ARRAY_SUPPORT?(t=e).__proto__=A.prototype:t=h(t,e);return t}(t,e,r,n):"string"==typeof e?function(t,e,r){"string"==typeof r&&""!==r||(r="utf8");if(!A.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var n=0|f(e,r),i=(t=s(t,n)).write(e,r);i!==n&&(t=t.slice(0,i));return t}(t,e,r):function(t,e){if(A.isBuffer(e)){var r=0|d(e.length);return 0===(t=s(t,r)).length||e.copy(t,0,0,r),t}if(e){if("undefined"!=typeof ArrayBuffer&&e.buffer instanceof ArrayBuffer||"length"in e)return"number"!=typeof e.length||(n=e.length)!=n?s(t,0):h(t,e);if("Buffer"===e.type&&o(e.data))return h(t,e.data)}var n;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(t,e)}function c(t){if("number"!=typeof t)throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function u(t,e){if(c(e),t=s(t,e<0?0:0|d(e)),!A.TYPED_ARRAY_SUPPORT)for(var r=0;r<e;++r)t[r]=0;return t}function h(t,e){var r=e.length<0?0:0|d(e.length);t=s(t,r);for(var n=0;n<r;n+=1)t[n]=255&e[n];return t}function d(t){if(t>=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|t}function f(t,e){if(A.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var n=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return H(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return N(t).length;default:if(n)return H(t).length;e=(""+e).toLowerCase(),n=!0}}function p(t,e,r){var n=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return F(this,e,r);case"utf8":case"utf-8":return S(this,e,r);case"ascii":return k(this,e,r);case"latin1":case"binary":return T(this,e,r);case"base64":return E(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return L(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function g(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function m(t,e,r,n,i){if(0===t.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(i)return-1;r=t.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof e&&(e=A.from(e,n)),A.isBuffer(e))return 0===e.length?-1:v(t,e,r,n,i);if("number"==typeof e)return e&=255,A.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):v(t,[e],r,n,i);throw new TypeError("val must be string, number or Buffer")}function v(t,e,r,n,i){var o,a=1,s=t.length,A=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return-1;a=2,s/=2,A/=2,r/=2}function l(t,e){return 1===a?t[e]:t.readUInt16BE(e*a)}if(i){var c=-1;for(o=r;o<s;o++)if(l(t,o)===l(e,-1===c?0:o-c)){if(-1===c&&(c=o),o-c+1===A)return c*a}else-1!==c&&(o-=o-c),c=-1}else for(r+A>s&&(r=s-A),o=r;o>=0;o--){for(var u=!0,h=0;h<A;h++)if(l(t,o+h)!==l(e,h)){u=!1;break}if(u)return o}return-1}function y(t,e,r,n){r=Number(r)||0;var i=t.length-r;n?(n=Number(n))>i&&(n=i):n=i;var o=e.length;if(o%2!=0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var a=0;a<n;++a){var s=parseInt(e.substr(2*a,2),16);if(isNaN(s))return a;t[r+a]=s}return a}function w(t,e,r,n){return K(H(e,t.length-r),t,r,n)}function b(t,e,r,n){return K(function(t){for(var e=[],r=0;r<t.length;++r)e.push(255&t.charCodeAt(r));return e}(e),t,r,n)}function C(t,e,r,n){return b(t,e,r,n)}function B(t,e,r,n){return K(N(e),t,r,n)}function x(t,e,r,n){return K(function(t,e){for(var r,n,i,o=[],a=0;a<t.length&&!((e-=2)<0);++a)r=t.charCodeAt(a),n=r>>8,i=r%256,o.push(i),o.push(n);return o}(e,t.length-r),t,r,n)}function E(t,e,r){return 0===e&&r===t.length?n.fromByteArray(t):n.fromByteArray(t.slice(e,r))}function S(t,e,r){r=Math.min(t.length,r);for(var n=[],i=e;i<r;){var o,a,s,A,l=t[i],c=null,u=l>239?4:l>223?3:l>191?2:1;if(i+u<=r)switch(u){case 1:l<128&&(c=l);break;case 2:128==(192&(o=t[i+1]))&&(A=(31&l)<<6|63&o)>127&&(c=A);break;case 3:o=t[i+1],a=t[i+2],128==(192&o)&&128==(192&a)&&(A=(15&l)<<12|(63&o)<<6|63&a)>2047&&(A<55296||A>57343)&&(c=A);break;case 4:o=t[i+1],a=t[i+2],s=t[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(A=(15&l)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&A<1114112&&(c=A)}null===c?(c=65533,u=1):c>65535&&(c-=65536,n.push(c>>>10&1023|55296),c=56320|1023&c),n.push(c),i+=u}return function(t){var e=t.length;if(e<=4096)return String.fromCharCode.apply(String,t);var r="",n=0;for(;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=4096));return r}(n)}e.Buffer=A,e.SlowBuffer=function(t){+t!=t&&(t=0);return A.alloc(+t)},e.INSPECT_MAX_BYTES=50,A.TYPED_ARRAY_SUPPORT=void 0!==t.TYPED_ARRAY_SUPPORT?t.TYPED_ARRAY_SUPPORT:function(){try{var t=new Uint8Array(1);return t.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===t.foo()&&"function"==typeof t.subarray&&0===t.subarray(1,1).byteLength}catch(t){return!1}}(),e.kMaxLength=a(),A.poolSize=8192,A._augment=function(t){return t.__proto__=A.prototype,t},A.from=function(t,e,r){return l(null,t,e,r)},A.TYPED_ARRAY_SUPPORT&&(A.prototype.__proto__=Uint8Array.prototype,A.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&A[Symbol.species]===A&&Object.defineProperty(A,Symbol.species,{value:null,configurable:!0})),A.alloc=function(t,e,r){return function(t,e,r,n){return c(e),e<=0?s(t,e):void 0!==r?"string"==typeof n?s(t,e).fill(r,n):s(t,e).fill(r):s(t,e)}(null,t,e,r)},A.allocUnsafe=function(t){return u(null,t)},A.allocUnsafeSlow=function(t){return u(null,t)},A.isBuffer=function(t){return!(null==t||!t._isBuffer)},A.compare=function(t,e){if(!A.isBuffer(t)||!A.isBuffer(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var r=t.length,n=e.length,i=0,o=Math.min(r,n);i<o;++i)if(t[i]!==e[i]){r=t[i],n=e[i];break}return r<n?-1:n<r?1:0},A.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},A.concat=function(t,e){if(!o(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return A.alloc(0);var r;if(void 0===e)for(e=0,r=0;r<t.length;++r)e+=t[r].length;var n=A.allocUnsafe(e),i=0;for(r=0;r<t.length;++r){var a=t[r];if(!A.isBuffer(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(n,i),i+=a.length}return n},A.byteLength=f,A.prototype._isBuffer=!0,A.prototype.swap16=function(){var t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var e=0;e<t;e+=2)g(this,e,e+1);return this},A.prototype.swap32=function(){var t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var e=0;e<t;e+=4)g(this,e,e+3),g(this,e+1,e+2);return this},A.prototype.swap64=function(){var t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var e=0;e<t;e+=8)g(this,e,e+7),g(this,e+1,e+6),g(this,e+2,e+5),g(this,e+3,e+4);return this},A.prototype.toString=function(){var t=0|this.length;return 0===t?"":0===arguments.length?S(this,0,t):p.apply(this,arguments)},A.prototype.equals=function(t){if(!A.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t||0===A.compare(this,t)},A.prototype.inspect=function(){var t="",r=e.INSPECT_MAX_BYTES;return this.length>0&&(t=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(t+=" ... ")),"<Buffer "+t+">"},A.prototype.compare=function(t,e,r,n,i){if(!A.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),e<0||r>t.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&e>=r)return 0;if(n>=i)return-1;if(e>=r)return 1;if(this===t)return 0;for(var o=(i>>>=0)-(n>>>=0),a=(r>>>=0)-(e>>>=0),s=Math.min(o,a),l=this.slice(n,i),c=t.slice(e,r),u=0;u<s;++u)if(l[u]!==c[u]){o=l[u],a=c[u];break}return o<a?-1:a<o?1:0},A.prototype.includes=function(t,e,r){return-1!==this.indexOf(t,e,r)},A.prototype.indexOf=function(t,e,r){return m(this,t,e,r,!0)},A.prototype.lastIndexOf=function(t,e,r){return m(this,t,e,r,!1)},A.prototype.write=function(t,e,r,n){if(void 0===e)n="utf8",r=this.length,e=0;else if(void 0===r&&"string"==typeof e)n=e,r=this.length,e=0;else{if(!isFinite(e))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");e|=0,isFinite(r)?(r|=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-e;if((void 0===r||r>i)&&(r=i),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return y(this,t,e,r);case"utf8":case"utf-8":return w(this,t,e,r);case"ascii":return b(this,t,e,r);case"latin1":case"binary":return C(this,t,e,r);case"base64":return B(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return x(this,t,e,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},A.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function k(t,e,r){var n="";r=Math.min(t.length,r);for(var i=e;i<r;++i)n+=String.fromCharCode(127&t[i]);return n}function T(t,e,r){var n="";r=Math.min(t.length,r);for(var i=e;i<r;++i)n+=String.fromCharCode(t[i]);return n}function F(t,e,r){var n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);for(var i="",o=e;o<r;++o)i+=P(t[o]);return i}function L(t,e,r){for(var n=t.slice(e,r),i="",o=0;o<n.length;o+=2)i+=String.fromCharCode(n[o]+256*n[o+1]);return i}function I(t,e,r){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}function _(t,e,r,n,i,o){if(!A.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||e<o)throw new RangeError('"value" argument is out of bounds');if(r+n>t.length)throw new RangeError("Index out of range")}function U(t,e,r,n){e<0&&(e=65535+e+1);for(var i=0,o=Math.min(t.length-r,2);i<o;++i)t[r+i]=(e&255<<8*(n?i:1-i))>>>8*(n?i:1-i)}function O(t,e,r,n){e<0&&(e=4294967295+e+1);for(var i=0,o=Math.min(t.length-r,4);i<o;++i)t[r+i]=e>>>8*(n?i:3-i)&255}function D(t,e,r,n,i,o){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function Q(t,e,r,n,o){return o||D(t,0,r,4),i.write(t,e,r,n,23,4),r+4}function M(t,e,r,n,o){return o||D(t,0,r,8),i.write(t,e,r,n,52,8),r+8}A.prototype.slice=function(t,e){var r,n=this.length;if((t=~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),(e=void 0===e?n:~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),e<t&&(e=t),A.TYPED_ARRAY_SUPPORT)(r=this.subarray(t,e)).__proto__=A.prototype;else{var i=e-t;r=new A(i,void 0);for(var o=0;o<i;++o)r[o]=this[o+t]}return r},A.prototype.readUIntLE=function(t,e,r){t|=0,e|=0,r||I(t,e,this.length);for(var n=this[t],i=1,o=0;++o<e&&(i*=256);)n+=this[t+o]*i;return n},A.prototype.readUIntBE=function(t,e,r){t|=0,e|=0,r||I(t,e,this.length);for(var n=this[t+--e],i=1;e>0&&(i*=256);)n+=this[t+--e]*i;return n},A.prototype.readUInt8=function(t,e){return e||I(t,1,this.length),this[t]},A.prototype.readUInt16LE=function(t,e){return e||I(t,2,this.length),this[t]|this[t+1]<<8},A.prototype.readUInt16BE=function(t,e){return e||I(t,2,this.length),this[t]<<8|this[t+1]},A.prototype.readUInt32LE=function(t,e){return e||I(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},A.prototype.readUInt32BE=function(t,e){return e||I(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},A.prototype.readIntLE=function(t,e,r){t|=0,e|=0,r||I(t,e,this.length);for(var n=this[t],i=1,o=0;++o<e&&(i*=256);)n+=this[t+o]*i;return n>=(i*=128)&&(n-=Math.pow(2,8*e)),n},A.prototype.readIntBE=function(t,e,r){t|=0,e|=0,r||I(t,e,this.length);for(var n=e,i=1,o=this[t+--n];n>0&&(i*=256);)o+=this[t+--n]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*e)),o},A.prototype.readInt8=function(t,e){return e||I(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},A.prototype.readInt16LE=function(t,e){e||I(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},A.prototype.readInt16BE=function(t,e){e||I(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},A.prototype.readInt32LE=function(t,e){return e||I(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},A.prototype.readInt32BE=function(t,e){return e||I(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},A.prototype.readFloatLE=function(t,e){return e||I(t,4,this.length),i.read(this,t,!0,23,4)},A.prototype.readFloatBE=function(t,e){return e||I(t,4,this.length),i.read(this,t,!1,23,4)},A.prototype.readDoubleLE=function(t,e){return e||I(t,8,this.length),i.read(this,t,!0,52,8)},A.prototype.readDoubleBE=function(t,e){return e||I(t,8,this.length),i.read(this,t,!1,52,8)},A.prototype.writeUIntLE=function(t,e,r,n){(t=+t,e|=0,r|=0,n)||_(this,t,e,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[e]=255&t;++o<r&&(i*=256);)this[e+o]=t/i&255;return e+r},A.prototype.writeUIntBE=function(t,e,r,n){(t=+t,e|=0,r|=0,n)||_(this,t,e,r,Math.pow(2,8*r)-1,0);var i=r-1,o=1;for(this[e+i]=255&t;--i>=0&&(o*=256);)this[e+i]=t/o&255;return e+r},A.prototype.writeUInt8=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,1,255,0),A.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&t,e+1},A.prototype.writeUInt16LE=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,2,65535,0),A.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):U(this,t,e,!0),e+2},A.prototype.writeUInt16BE=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,2,65535,0),A.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):U(this,t,e,!1),e+2},A.prototype.writeUInt32LE=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,4,4294967295,0),A.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):O(this,t,e,!0),e+4},A.prototype.writeUInt32BE=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,4,4294967295,0),A.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):O(this,t,e,!1),e+4},A.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e|=0,!n){var i=Math.pow(2,8*r-1);_(this,t,e,r,i-1,-i)}var o=0,a=1,s=0;for(this[e]=255&t;++o<r&&(a*=256);)t<0&&0===s&&0!==this[e+o-1]&&(s=1),this[e+o]=(t/a>>0)-s&255;return e+r},A.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e|=0,!n){var i=Math.pow(2,8*r-1);_(this,t,e,r,i-1,-i)}var o=r-1,a=1,s=0;for(this[e+o]=255&t;--o>=0&&(a*=256);)t<0&&0===s&&0!==this[e+o+1]&&(s=1),this[e+o]=(t/a>>0)-s&255;return e+r},A.prototype.writeInt8=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,1,127,-128),A.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=255&t,e+1},A.prototype.writeInt16LE=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,2,32767,-32768),A.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):U(this,t,e,!0),e+2},A.prototype.writeInt16BE=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,2,32767,-32768),A.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):U(this,t,e,!1),e+2},A.prototype.writeInt32LE=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,4,2147483647,-2147483648),A.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):O(this,t,e,!0),e+4},A.prototype.writeInt32BE=function(t,e,r){return t=+t,e|=0,r||_(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),A.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):O(this,t,e,!1),e+4},A.prototype.writeFloatLE=function(t,e,r){return Q(this,t,e,!0,r)},A.prototype.writeFloatBE=function(t,e,r){return Q(this,t,e,!1,r)},A.prototype.writeDoubleLE=function(t,e,r){return M(this,t,e,!0,r)},A.prototype.writeDoubleBE=function(t,e,r){return M(this,t,e,!1,r)},A.prototype.copy=function(t,e,r,n){if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===t.length||0===this.length)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);var i,o=n-r;if(this===t&&r<e&&e<n)for(i=o-1;i>=0;--i)t[i+e]=this[i+r];else if(o<1e3||!A.TYPED_ARRAY_SUPPORT)for(i=0;i<o;++i)t[i+e]=this[i+r];else Uint8Array.prototype.set.call(t,this.subarray(r,r+o),e);return o},A.prototype.fill=function(t,e,r,n){if("string"==typeof t){if("string"==typeof e?(n=e,e=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),1===t.length){var i=t.charCodeAt(0);i<256&&(t=i)}if(void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!A.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else"number"==typeof t&&(t&=255);if(e<0||this.length<e||this.length<r)throw new RangeError("Out of range index");if(r<=e)return this;var o;if(e>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(o=e;o<r;++o)this[o]=t;else{var a=A.isBuffer(t)?t:H(new A(t,n).toString()),s=a.length;for(o=0;o<r-e;++o)this[o+e]=a[o%s]}return this};var R=/[^+\/0-9A-Za-z-_]/g;function P(t){return t<16?"0"+t.toString(16):t.toString(16)}function H(t,e){var r;e=e||1/0;for(var n=t.length,i=null,o=[],a=0;a<n;++a){if((r=t.charCodeAt(a))>55295&&r<57344){if(!i){if(r>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(a+1===n){(e-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(e-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(e-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((e-=1)<0)break;o.push(r)}else if(r<2048){if((e-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function N(t){return n.toByteArray(function(t){if((t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(R,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function K(t,e,r,n){for(var i=0;i<n&&!(i+r>=e.length||i>=t.length);++i)e[i+r]=t[i];return i}}).call(this,r(/*! ./../../../@umijs/deps/compiled/webpack/4/global.js */"IyRk"))},HmJG:
|
|
|
/*!****************************************************************!*\
|
|
|
!*** ./src/components/markdown-editor/upload-image/index.less ***!
|
|
|
\****************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){},I8Z2:
|
|
|
/*!**********************************************************!*\
|
|
|
!*** ./node_modules/mini-store/esm/index.js + 3 modules ***!
|
|
|
\**********************************************************/
|
|
|
/*! exports provided: Provider, connect, create */
|
|
|
/*! exports used: Provider, connect, create */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/shallowequal/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r.d(e,"a",(function(){return s})),r.d(e,"b",(function(){return p})),r.d(e,"c",(function(){return m}));var n,i=r("q1tI"),o=(n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}),a=i.createContext(null),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.render=function(){return i.createElement(a.Provider,{value:this.props.store},this.props.children)},e}(i.Component),A=r("Gytx"),l=r.n(A),c=r("2mql"),u=r.n(c),h=function(){var t=function(e,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),d=function(){return(d=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++)for(var i in e=arguments[r])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)};var f=function(){return{}};function p(t,e){void 0===e&&(e={});var r=!!t,n=t||f;return function(o){var s=function(e){function s(t,r){var i=e.call(this,t,r)||this;return i.unsubscribe=null,i.handleChange=function(){if(i.unsubscribe){var t=n(i.store.getState(),i.props);i.setState({subscribed:t})}},i.store=i.context,i.state={subscribed:n(i.store.getState(),t),store:i.store,props:t},i}return h(s,e),s.getDerivedStateFromProps=function(e,r){return t&&2===t.length&&e!==r.props?{subscribed:n(r.store.getState(),e),props:e}:{props:e}},s.prototype.componentDidMount=function(){this.trySubscribe()},s.prototype.componentWillUnmount=function(){this.tryUnsubscribe()},s.prototype.shouldComponentUpdate=function(t,e){return!l()(this.props,t)||!l()(this.state.subscribed,e.subscribed)},s.prototype.trySubscribe=function(){r&&(this.unsubscribe=this.store.subscribe(this.handleChange),this.handleChange())},s.prototype.tryUnsubscribe=function(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=null)},s.prototype.render=function(){var t=d(d(d({},this.props),this.state.subscribed),{store:this.store});return i.createElement(o,d({},t,{ref:this.props.miniStoreForwardedRef}))},s.displayName="Connect("+function(t){return t.displayName||t.name||"Component"}(o)+")",s.contextType=a,s}(i.Component);if(e.forwardRef){var A=i.forwardRef((function(t,e){return i.createElement(s,d({},t,{miniStoreForwardedRef:e}))}));return u()(A,o)}return u()(s,o)}}var g=function(){return(g=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++)for(var i in e=arguments[r])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)};function m(t){var e=t,r=[];return{setState:function(t){e=g(g({},e),t);for(var n=0;n<r.length;n++)r[n]()},getState:function(){return e},subscribe:function(t){return r.push(t),function(){var e=r.indexOf(t);r.splice(e,1)}}}}},IBYe:
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/sugar/Column.js ***!
|
|
|
\**************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";e.a=function(t){return null}},IMiH:
|
|
|
/*!****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/PathProxy.js ***!
|
|
|
\****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./curve */"Sj9i"),i=r(/*! ./vector */"QBsz"),o=r(/*! ./bbox */"4mN7"),a=r(/*! ./BoundingRect */"mFDi"),s=r(/*! ../config */"LPTA").devicePixelRatio,A={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},l=[],c=[],u=[],h=[],d=Math.min,f=Math.max,p=Math.cos,g=Math.sin,m=Math.sqrt,v=Math.abs,y="undefined"!=typeof Float32Array,w=function(t){this._saveData=!t,this._saveData&&(this.data=[]),this._ctx=null};w.prototype={constructor:w,_xi:0,_yi:0,_x0:0,_y0:0,_ux:0,_uy:0,_len:0,_lineDash:null,_dashOffset:0,_dashIdx:0,_dashSum:0,setScale:function(t,e,r){r=r||0,this._ux=v(r/s/t)||0,this._uy=v(r/s/e)||0},getContext:function(){return this._ctx},beginPath:function(t){return this._ctx=t,t&&t.beginPath(),t&&(this.dpr=t.dpr),this._saveData&&(this._len=0),this._lineDash&&(this._lineDash=null,this._dashOffset=0),this},moveTo:function(t,e){return this.addData(A.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},lineTo:function(t,e){var r=v(t-this._xi)>this._ux||v(e-this._yi)>this._uy||this._len<5;return this.addData(A.L,t,e),this._ctx&&r&&(this._needsDash()?this._dashedLineTo(t,e):this._ctx.lineTo(t,e)),r&&(this._xi=t,this._yi=e),this},bezierCurveTo:function(t,e,r,n,i,o){return this.addData(A.C,t,e,r,n,i,o),this._ctx&&(this._needsDash()?this._dashedBezierTo(t,e,r,n,i,o):this._ctx.bezierCurveTo(t,e,r,n,i,o)),this._xi=i,this._yi=o,this},quadraticCurveTo:function(t,e,r,n){return this.addData(A.Q,t,e,r,n),this._ctx&&(this._needsDash()?this._dashedQuadraticTo(t,e,r,n):this._ctx.quadraticCurveTo(t,e,r,n)),this._xi=r,this._yi=n,this},arc:function(t,e,r,n,i,o){return this.addData(A.A,t,e,r,r,n,i-n,0,o?0:1),this._ctx&&this._ctx.arc(t,e,r,n,i,o),this._xi=p(i)*r+t,this._yi=g(i)*r+e,this},arcTo:function(t,e,r,n,i){return this._ctx&&this._ctx.arcTo(t,e,r,n,i),this},rect:function(t,e,r,n){return this._ctx&&this._ctx.rect(t,e,r,n),this.addData(A.R,t,e,r,n),this},closePath:function(){this.addData(A.Z);var t=this._ctx,e=this._x0,r=this._y0;return t&&(this._needsDash()&&this._dashedLineTo(e,r),t.closePath()),this._xi=e,this._yi=r,this},fill:function(t){t&&t.fill(),this.toStatic()},stroke:function(t){t&&t.stroke(),this.toStatic()},setLineDash:function(t){if(t instanceof Array){this._lineDash=t,this._dashIdx=0;for(var e=0,r=0;r<t.length;r++)e+=t[r];this._dashSum=e}return this},setLineDashOffset:function(t){return this._dashOffset=t,this},len:function(){return this._len},setData:function(t){var e=t.length;this.data&&this.data.length===e||!y||(this.data=new Float32Array(e));for(var r=0;r<e;r++)this.data[r]=t[r];this._len=e},appendPath:function(t){t instanceof Array||(t=[t]);for(var e=t.length,r=0,n=this._len,i=0;i<e;i++)r+=t[i].len();y&&this.data instanceof Float32Array&&(this.data=new Float32Array(n+r));for(i=0;i<e;i++)for(var o=t[i].data,a=0;a<o.length;a++)this.data[n++]=o[a];this._len=n},addData:function(t){if(this._saveData){var e=this.data;this._len+arguments.length>e.length&&(this._expandData(),e=this.data);for(var r=0;r<arguments.length;r++)e[this._len++]=arguments[r];this._prevCmd=t}},_expandData:function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e<this._len;e++)t[e]=this.data[e];this.data=t}},_needsDash:function(){return this._lineDash},_dashedLineTo:function(t,e){var r,n,i=this._dashSum,o=this._dashOffset,a=this._lineDash,s=this._ctx,A=this._xi,l=this._yi,c=t-A,u=e-l,h=m(c*c+u*u),p=A,g=l,v=a.length;for(o<0&&(o=i+o),p-=(o%=i)*(c/=h),g-=o*(u/=h);c>0&&p<=t||c<0&&p>=t||0===c&&(u>0&&g<=e||u<0&&g>=e);)p+=c*(r=a[n=this._dashIdx]),g+=u*r,this._dashIdx=(n+1)%v,c>0&&p<A||c<0&&p>A||u>0&&g<l||u<0&&g>l||s[n%2?"moveTo":"lineTo"](c>=0?d(p,t):f(p,t),u>=0?d(g,e):f(g,e));c=p-t,u=g-e,this._dashOffset=-m(c*c+u*u)},_dashedBezierTo:function(t,e,r,i,o,a){var s,A,l,c,u,h=this._dashSum,d=this._dashOffset,f=this._lineDash,p=this._ctx,g=this._xi,v=this._yi,y=n.cubicAt,w=0,b=this._dashIdx,C=f.length,B=0;for(d<0&&(d=h+d),d%=h,s=0;s<1;s+=.1)A=y(g,t,r,o,s+.1)-y(g,t,r,o,s),l=y(v,e,i,a,s+.1)-y(v,e,i,a,s),w+=m(A*A+l*l);for(;b<C&&!((B+=f[b])>d);b++);for(s=(B-d)/w;s<=1;)c=y(g,t,r,o,s),u=y(v,e,i,a,s),b%2?p.moveTo(c,u):p.lineTo(c,u),s+=f[b]/w,b=(b+1)%C;b%2!=0&&p.lineTo(o,a),A=o-c,l=a-u,this._dashOffset=-m(A*A+l*l)},_dashedQuadraticTo:function(t,e,r,n){var i=r,o=n;r=(r+2*t)/3,n=(n+2*e)/3,t=(this._xi+2*t)/3,e=(this._yi+2*e)/3,this._dashedBezierTo(t,e,r,n,i,o)},toStatic:function(){var t=this.data;t instanceof Array&&(t.length=this._len,y&&(this.data=new Float32Array(t)))},getBoundingRect:function(){l[0]=l[1]=u[0]=u[1]=Number.MAX_VALUE,c[0]=c[1]=h[0]=h[1]=-Number.MAX_VALUE;for(var t=this.data,e=0,r=0,n=0,s=0,d=0;d<t.length;){var f=t[d++];switch(1===d&&(n=e=t[d],s=r=t[d+1]),f){case A.M:e=n=t[d++],r=s=t[d++],u[0]=n,u[1]=s,h[0]=n,h[1]=s;break;case A.L:o.fromLine(e,r,t[d],t[d+1],u,h),e=t[d++],r=t[d++];break;case A.C:o.fromCubic(e,r,t[d++],t[d++],t[d++],t[d++],t[d],t[d+1],u,h),e=t[d++],r=t[d++];break;case A.Q:o.fromQuadratic(e,r,t[d++],t[d++],t[d],t[d+1],u,h),e=t[d++],r=t[d++];break;case A.A:var m=t[d++],v=t[d++],y=t[d++],w=t[d++],b=t[d++],C=t[d++]+b;d+=1;var B=1-t[d++];1===d&&(n=p(b)*y+m,s=g(b)*w+v),o.fromArc(m,v,y,w,b,C,B,u,h),e=p(C)*y+m,r=g(C)*w+v;break;case A.R:n=e=t[d++],s=r=t[d++];var x=t[d++],E=t[d++];o.fromLine(n,s,n+x,s+E,u,h);break;case A.Z:e=n,r=s}i.min(l,l,u),i.max(c,c,h)}return 0===d&&(l[0]=l[1]=c[0]=c[1]=0),new a(l[0],l[1],c[0]-l[0],c[1]-l[1])},rebuildPath:function(t){for(var e,r,n,i,o,a,s=this.data,l=this._ux,c=this._uy,u=this._len,h=0;h<u;){var d=s[h++];switch(1===h&&(e=n=s[h],r=i=s[h+1]),d){case A.M:e=n=s[h++],r=i=s[h++],t.moveTo(n,i);break;case A.L:o=s[h++],a=s[h++],(v(o-n)>l||v(a-i)>c||h===u-1)&&(t.lineTo(o,a),n=o,i=a);break;case A.C:t.bezierCurveTo(s[h++],s[h++],s[h++],s[h++],s[h++],s[h++]),n=s[h-2],i=s[h-1];break;case A.Q:t.quadraticCurveTo(s[h++],s[h++],s[h++],s[h++]),n=s[h-2],i=s[h-1];break;case A.A:var f=s[h++],m=s[h++],y=s[h++],w=s[h++],b=s[h++],C=s[h++],B=s[h++],x=s[h++],E=y>w?y:w,S=y>w?1:y/w,k=y>w?w/y:1,T=b+C;Math.abs(y-w)>.001?(t.translate(f,m),t.rotate(B),t.scale(S,k),t.arc(0,0,E,b,T,1-x),t.scale(1/S,1/k),t.rotate(-B),t.translate(-f,-m)):t.arc(f,m,E,b,T,1-x),1===h&&(e=p(b)*y+f,r=g(b)*w+m),n=p(T)*y+f,i=g(T)*w+m;break;case A.R:e=n=s[h],r=i=s[h+1],t.rect(s[h++],s[h++],s[h++],s[h++]);break;case A.Z:t.closePath(),n=e,i=r}}}},w.CMD=A;var b=w;t.exports=b},Iq15:
|
|
|
/*!****************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/util.js ***!
|
|
|
\****************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./mode */"nVVt"),i=r(/*! ./Polynomial */"dWSS"),o=r(/*! ./math */"dQei"),a=0,s=1,A=2,l=3,c=4,u=5,h=6,d=7,f={PATTERN_POSITION_TABLE:[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],G15:1335,G18:7973,G15_MASK:21522,getBCHTypeInfo:function(t){for(var e=t<<10;f.getBCHDigit(e)-f.getBCHDigit(f.G15)>=0;)e^=f.G15<<f.getBCHDigit(e)-f.getBCHDigit(f.G15);return(t<<10|e)^f.G15_MASK},getBCHTypeNumber:function(t){for(var e=t<<12;f.getBCHDigit(e)-f.getBCHDigit(f.G18)>=0;)e^=f.G18<<f.getBCHDigit(e)-f.getBCHDigit(f.G18);return t<<12|e},getBCHDigit:function(t){for(var e=0;0!=t;)e++,t>>>=1;return e},getPatternPosition:function(t){return f.PATTERN_POSITION_TABLE[t-1]},getMask:function(t,e,r){switch(t){case a:return(e+r)%2==0;case s:return e%2==0;case A:return r%3==0;case l:return(e+r)%3==0;case c:return(Math.floor(e/2)+Math.floor(r/3))%2==0;case u:return e*r%2+e*r%3==0;case h:return(e*r%2+e*r%3)%2==0;case d:return(e*r%3+(e+r)%2)%2==0;default:throw new Error("bad maskPattern:"+t)}},getErrorCorrectPolynomial:function(t){for(var e=new i([1],0),r=0;r<t;r++)e=e.multiply(new i([1,o.gexp(r)],0));return e},getLengthInBits:function(t,e){if(1<=e&&e<10)switch(t){case n.MODE_NUMBER:return 10;case n.MODE_ALPHA_NUM:return 9;case n.MODE_8BIT_BYTE:case n.MODE_KANJI:return 8;default:throw new Error("mode:"+t)}else if(e<27)switch(t){case n.MODE_NUMBER:return 12;case n.MODE_ALPHA_NUM:return 11;case n.MODE_8BIT_BYTE:return 16;case n.MODE_KANJI:return 10;default:throw new Error("mode:"+t)}else{if(!(e<41))throw new Error("type:"+e);switch(t){case n.MODE_NUMBER:return 14;case n.MODE_ALPHA_NUM:return 13;case n.MODE_8BIT_BYTE:return 16;case n.MODE_KANJI:return 12;default:throw new Error("mode:"+t)}}},getLostPoint:function(t){for(var e=t.getModuleCount(),r=0,n=0;n<e;n++)for(var i=0;i<e;i++){for(var o=0,a=t.isDark(n,i),s=-1;s<=1;s++)if(!(n+s<0||e<=n+s))for(var A=-1;A<=1;A++)i+A<0||e<=i+A||0==s&&0==A||a==t.isDark(n+s,i+A)&&o++;o>5&&(r+=3+o-5)}for(n=0;n<e-1;n++)for(i=0;i<e-1;i++){var l=0;t.isDark(n,i)&&l++,t.isDark(n+1,i)&&l++,t.isDark(n,i+1)&&l++,t.isDark(n+1,i+1)&&l++,0!=l&&4!=l||(r+=3)}for(n=0;n<e;n++)for(i=0;i<e-6;i++)t.isDark(n,i)&&!t.isDark(n,i+1)&&t.isDark(n,i+2)&&t.isDark(n,i+3)&&t.isDark(n,i+4)&&!t.isDark(n,i+5)&&t.isDark(n,i+6)&&(r+=40);for(i=0;i<e;i++)for(n=0;n<e-6;n++)t.isDark(n,i)&&!t.isDark(n+1,i)&&t.isDark(n+2,i)&&t.isDark(n+3,i)&&t.isDark(n+4,i)&&!t.isDark(n+5,i)&&t.isDark(n+6,i)&&(r+=40);var c=0;for(i=0;i<e;i++)for(n=0;n<e;n++)t.isDark(n,i)&&c++;return r+=10*(Math.abs(100*c/e/e-50)/5)}};t.exports=f},ItGF:
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/env.js ***!
|
|
|
\**********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r="object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?{browser:{},os:{},node:!1,wxa:!0,canvasSupported:!0,svgSupported:!1,touchEventsSupported:!0,domSupported:!1}:"undefined"==typeof document&&"undefined"!=typeof self?{browser:{},os:{},node:!1,worker:!0,canvasSupported:!0,domSupported:!1}:"undefined"==typeof navigator?{browser:{},os:{},node:!0,worker:!1,canvasSupported:!0,svgSupported:!0,domSupported:!1}:function(t){var e={},r=t.match(/Firefox\/([\d.]+)/),n=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),i=t.match(/Edge\/([\d.]+)/),o=/micromessenger/i.test(t);r&&(e.firefox=!0,e.version=r[1]);n&&(e.ie=!0,e.version=n[1]);i&&(e.edge=!0,e.version=i[1]);o&&(e.weChat=!0);return{browser:e,os:{},node:!1,canvasSupported:!!document.createElement("canvas").getContext,svgSupported:"undefined"!=typeof SVGRect,touchEventsSupported:"ontouchstart"in window&&!e.ie&&!e.edge,pointerEventsSupported:"onpointerdown"in window&&(e.edge||e.ie&&e.version>=11),domSupported:"undefined"!=typeof document}}(navigator.userAgent);t.exports=r},K2GJ:
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/Style.js ***!
|
|
|
\***************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./helper/fixShadow */"fW2E"),i=r(/*! ./constant */"gut8").ContextCachedBy,o=[["shadowBlur",0],["shadowOffsetX",0],["shadowOffsetY",0],["shadowColor","#000"],["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]],a=function(t){this.extendFrom(t,!1)};function s(t,e,r){var n=null==e.x?0:e.x,i=null==e.x2?1:e.x2,o=null==e.y?0:e.y,a=null==e.y2?0:e.y2;return e.global||(n=n*r.width+r.x,i=i*r.width+r.x,o=o*r.height+r.y,a=a*r.height+r.y),n=isNaN(n)?0:n,i=isNaN(i)?1:i,o=isNaN(o)?0:o,a=isNaN(a)?0:a,t.createLinearGradient(n,o,i,a)}function A(t,e,r){var n=r.width,i=r.height,o=Math.min(n,i),a=null==e.x?.5:e.x,s=null==e.y?.5:e.y,A=null==e.r?.5:e.r;return e.global||(a=a*n+r.x,s=s*i+r.y,A*=o),t.createRadialGradient(a,s,0,a,s,A)}for(var l=a.prototype={constructor:a,fill:"#000",stroke:null,opacity:1,fillOpacity:null,strokeOpacity:null,lineDash:null,lineDashOffset:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,lineWidth:1,strokeNoScale:!1,text:null,font:null,textFont:null,fontStyle:null,fontWeight:null,fontSize:null,fontFamily:null,textTag:null,textFill:"#000",textStroke:null,textWidth:null,textHeight:null,textStrokeWidth:0,textLineHeight:null,textPosition:"inside",textRect:null,textOffset:null,textAlign:null,textVerticalAlign:null,textDistance:5,textShadowColor:"transparent",textShadowBlur:0,textShadowOffsetX:0,textShadowOffsetY:0,textBoxShadowColor:"transparent",textBoxShadowBlur:0,textBoxShadowOffsetX:0,textBoxShadowOffsetY:0,transformText:!1,textRotation:0,textOrigin:null,textBackgroundColor:null,textBorderColor:null,textBorderWidth:0,textBorderRadius:0,textPadding:null,rich:null,truncate:null,blend:null,bind:function(t,e,r){var a=r&&r.style,s=!a||t.__attrCachedBy!==i.STYLE_BIND;t.__attrCachedBy=i.STYLE_BIND;for(var A=0;A<o.length;A++){var l=o[A],c=l[0];(s||this[c]!==a[c])&&(t[c]=n(t,c,this[c]||l[1]))}if((s||this.fill!==a.fill)&&(t.fillStyle=this.fill),(s||this.stroke!==a.stroke)&&(t.strokeStyle=this.stroke),(s||this.opacity!==a.opacity)&&(t.globalAlpha=null==this.opacity?1:this.opacity),(s||this.blend!==a.blend)&&(t.globalCompositeOperation=this.blend||"source-over"),this.hasStroke()){var u=this.lineWidth;t.lineWidth=u/(this.strokeNoScale&&e&&e.getLineScale?e.getLineScale():1)}},hasFill:function(){var t=this.fill;return null!=t&&"none"!==t},hasStroke:function(){var t=this.stroke;return null!=t&&"none"!==t&&this.lineWidth>0},extendFrom:function(t,e){if(t)for(var r in t)!t.hasOwnProperty(r)||!0!==e&&(!1===e?this.hasOwnProperty(r):null==t[r])||(this[r]=t[r])},set:function(t,e){"string"==typeof t?this[t]=e:this.extendFrom(t,!0)},clone:function(){var t=new this.constructor;return t.extendFrom(this,!0),t},getGradient:function(t,e,r){for(var n=("radial"===e.type?A:s)(t,e,r),i=e.colorStops,o=0;o<i.length;o++)n.addColorStop(i[o].offset,i[o].color);return n}},c=0;c<o.length;c++){var u=o[c];u[0]in l||(l[u[0]]=u[1])}a.getGradient=l.getGradient;var h=a;t.exports=h},LPTA:
|
|
|
/*!********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/config.js ***!
|
|
|
\********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=1;"undefined"!=typeof window&&(r=Math.max(window.devicePixelRatio||1,1));var n=r;e.debugMode=0,e.devicePixelRatio=n},LdHM:
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/rc-select/es/index.js + 6 modules ***!
|
|
|
\********************************************************/
|
|
|
/*! exports provided: Option, OptGroup, default */
|
|
|
/*! exports used: OptGroup, Option, default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createSuper.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/typeof.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-select/es/TransBtn.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-select/es/generate.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-select/es/utils/commonUtil.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-select/es/utils/valueUtil.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/Children/toArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/KeyCode.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/hooks/useMemo.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/pickAttrs.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/warning.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-virtual-list/es/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r.d(e,"b",(function(){return b})),r.d(e,"a",(function(){return B}));var n=r("1OyB"),i=r("vuIU"),o=r("Ji7U"),a=r("LK+K"),s=r("q1tI"),A=r("rePB"),l=r("Ff2n"),c=r("ODXe"),u=r("4IlW"),h=r("bX4T"),d=r("YrtM"),f=r("TSYQ"),p=r.n(f),g=r("+nKL"),m=r("8OUc"),v=s.forwardRef((function(t,e){var r=t.prefixCls,n=t.id,i=t.flattenOptions,o=t.childrenAsData,a=t.values,f=t.searchValue,v=t.multiple,y=t.defaultActiveFirstOption,w=t.height,b=t.itemHeight,C=t.notFoundContent,B=t.open,x=t.menuItemSelectedIcon,E=t.virtual,S=t.onSelect,k=t.onToggleOpen,T=t.onActiveValue,F=t.onScroll,L=t.onMouseEnter,I="".concat(r,"-item"),_=Object(d.a)((function(){return i}),[B,i],(function(t,e){return e[0]&&t[1]!==e[1]})),U=s.useRef(null),O=function(t){t.preventDefault()},D=function(t){U.current&&U.current.scrollTo({index:t})},Q=function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=_.length,n=0;n<r;n+=1){var i=(t+n*e+r)%r,o=_[i],a=o.group,s=o.data;if(!a&&!s.disabled)return i}return-1},M=s.useState((function(){return Q(0)})),R=Object(c.a)(M,2),P=R[0],H=R[1],N=function(t){H(t);var e=_[t];e?T(e.data.value,t):T(null,-1)};s.useEffect((function(){N(!1!==y?Q(0):-1)}),[_.length,f]),s.useEffect((function(){var t=setTimeout((function(){if(!v&&B&&1===a.size){var t=Array.from(a)[0],e=_.findIndex((function(e){return e.data.value===t}));N(e),D(e)}}));return function(){return clearTimeout(t)}}),[B]);var K=function(t){void 0!==t&&S(t,{selected:!a.has(t)}),v||k(!1)};if(s.useImperativeHandle(e,(function(){return{onKeyDown:function(t){var e=t.which;switch(e){case u.a.UP:case u.a.DOWN:var r=0;if(e===u.a.UP?r=-1:e===u.a.DOWN&&(r=1),0!==r){var n=Q(P+r,r);D(n),N(n)}break;case u.a.ENTER:var i=_[P];i&&!i.data.disabled?K(i.data.value):K(void 0),B&&t.preventDefault();break;case u.a.ESC:k(!1)}},onKeyUp:function(){},scrollTo:function(t){D(t)}}})),0===_.length)return s.createElement("div",{role:"listbox",id:"".concat(n,"_list"),className:"".concat(I,"-empty"),onMouseDown:O},C);function j(t){var e=_[t];if(!e)return null;var r=e.data||{},i=r.value,A=r.label,l=r.children,c=Object(h.a)(r,!0),u=o?l:A;return e?s.createElement("div",Object.assign({"aria-label":"string"==typeof u?u:null},c,{key:t,role:"option",id:"".concat(n,"_list_").concat(t),"aria-selected":a.has(i)}),i):null}return s.createElement(s.Fragment,null,s.createElement("div",{role:"listbox",id:"".concat(n,"_list"),style:{height:0,width:0,overflow:"hidden"}},j(P-1),j(P),j(P+1)),s.createElement(g.a,{itemKey:"key",ref:U,data:_,height:w,itemHeight:b,fullHeight:!1,onMouseDown:O,onScroll:F,virtual:E,onMouseEnter:L},(function(t,e){var r,n=t.group,i=t.groupOption,c=t.data,u=c.label,h=c.key;if(n)return s.createElement("div",{className:p()(I,"".concat(I,"-group"))},void 0!==u?u:h);var d=c.disabled,f=c.value,g=c.title,v=c.children,y=c.style,w=c.className,b=Object(l.a)(c,["disabled","value","title","children","style","className"]),C=a.has(f),B="".concat(I,"-option"),E=p()(I,B,w,(r={},Object(A.a)(r,"".concat(B,"-grouped"),i),Object(A.a)(r,"".concat(B,"-active"),P===e&&!d),Object(A.a)(r,"".concat(B,"-disabled"),d),Object(A.a)(r,"".concat(B,"-selected"),C),r)),S=o?v:u,k=!x||"function"==typeof x||C;return s.createElement("div",Object.assign({},b,{"aria-selected":C,className:E,title:g,onMouseMove:function(){P===e||d||N(e)},onClick:function(){d||K(f)},style:y}),s.createElement("div",{className:"".concat(B,"-content")},S||f),s.isValidElement(x)||C,k&&s.createElement(m.a,{className:"".concat(I,"-option-state"),customizeIcon:x,customizeIconProps:{isSelected:C}},C?"✓":null))})))}));v.displayName="OptionList";var y=v,w=function(){return null};w.isSelectOption=!0;var b=w,C=function(){return null};C.isSelectOptGroup=!0;var B=C,x=r("VTBJ"),E=r("Zm9Q");function S(t){var e=t.key,r=t.props,n=r.children,i=r.value,o=Object(l.a)(r,["children","value"]);return Object(x.a)({key:e,value:void 0!==i?i:e,children:n},o)}function k(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return Object(E.a)(t).map((function(t,r){if(!s.isValidElement(t)||!t.type)return null;var n=t.type.isSelectOptGroup,i=t.key,o=t.props,a=o.children,A=Object(l.a)(o,["children"]);return e||!n?S(t):Object(x.a)(Object(x.a)({key:"__RC_SELECT_GRP__".concat(null===i?r:i,"__"),label:i},A),{},{options:k(a)})})).filter((function(t){return t}))}var T=r("2Qr1"),F=r("qNPg"),L=r("U8pU"),I=r("Kwbf"),_=r("WKfj");var U=function(t){var e=t.mode,r=t.options,n=t.children,i=t.backfill,o=t.allowClear,a=t.placeholder,A=t.getInputElement,l=t.showSearch,c=t.onSearch,u=t.defaultOpen,h=t.autoFocus,d=t.labelInValue,f=t.value,p=t.inputValue,g=t.optionLabelProp,m="multiple"===e||"tags"===e,v=void 0!==l?l:m||"combobox"===e,y=r||k(n);if(Object(I.a)("tags"!==e||y.every((function(t){return!t.disabled})),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),"tags"===e||"combobox"===e){var w=y.some((function(t){return t.options?t.options.some((function(t){return"number"==typeof("value"in t?t.value:t.key)})):"number"==typeof("value"in t?t.value:t.key)}));Object(I.a)(!w,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(Object(I.a)("combobox"!==e||!g,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),Object(I.a)("combobox"===e||!i,"`backfill` only works with `combobox` mode."),Object(I.a)("combobox"===e||!A,"`getInputElement` only work with `combobox` mode."),Object(I.b)("combobox"!==e||!A||!o||!a,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),c&&!v&&"combobox"!==e&&"tags"!==e&&Object(I.a)(!1,"`onSearch` should work with `showSearch` instead of use alone."),Object(I.b)(!u||h,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),null!=f){var b=Object(_.d)(f);Object(I.a)(!d||b.every((function(t){return"object"===Object(L.a)(t)&&("key"in t||"value"in t)})),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),Object(I.a)(!m||Array.isArray(f),"`value` should be array when `mode` is `multiple` or `tags`")}if(n){var C=null;Object(E.a)(n).some((function(t){if(!s.isValidElement(t)||!t.type)return!1;var e=t.type;return!e.isSelectOption&&(e.isSelectOptGroup?!Object(E.a)(t.props.children).every((function(e){return!(s.isValidElement(e)&&t.type&&!e.type.isSelectOption)||(C=e.type,!1)})):(C=e,!0))})),C&&Object(I.a)(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(C.displayName||C.name||C,"`.")),Object(I.a)(void 0===p,"`inputValue` is deprecated, please use `searchValue` instead.")}},O=Object(F.a)({prefixCls:"rc-select",components:{optionList:y},convertChildrenToData:k,flattenOptions:T.d,getLabeledValue:T.e,filterOptions:T.b,isValueDisabled:T.g,findValueOption:T.c,warningProps:U,fillOptionsWithMissingValue:T.a}),D=function(t){Object(o.a)(r,t);var e=Object(a.a)(r);function r(){var t;return Object(n.a)(this,r),(t=e.apply(this,arguments)).selectRef=s.createRef(),t.focus=function(){t.selectRef.current.focus()},t.blur=function(){t.selectRef.current.blur()},t}return Object(i.a)(r,[{key:"render",value:function(){return s.createElement(O,Object.assign({ref:this.selectRef},this.props))}}]),r}(s.Component);D.Option=b,D.OptGroup=B;var Q=D;e.c=Q},M8RZ:
|
|
|
/*!**********************************!*\
|
|
|
!*** ./src/components/modal.tsx ***!
|
|
|
\**********************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";r.d(e,"a",(function(){return c}));var n=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/classCallCheck */"fWQN"),i=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/createClass */"mtLc"),o=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/inherits */"yKVA"),a=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/createSuper */"879j"),s=r(/*! react */"q1tI"),A=r.n(s),l=r(/*! react-dom */"i8i4"),c=function(t){Object(o.a)(r,t);var e=Object(a.a)(r);function r(t){var i;Object(n.a)(this,r),i=e.call(this,t);var o=window.document;return i.node=o.createElement("div"),o.body.appendChild(i.node),i}return Object(i.a)(r,[{key:"render",value:function(){var t=this.props.children;return Object(l.createPortal)(t,this.node)}},{key:"componentWillUnmount",value:function(){window.document.body.removeChild(this.node)}}]),r}(A.a.Component)},MEGo:
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/tool/parseSVG.js ***!
|
|
|
\***************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../container/Group */"4fz+"),i=r(/*! ../graphic/Image */"Dagg"),o=r(/*! ../graphic/Text */"dqUG"),a=r(/*! ../graphic/shape/Circle */"2fw6"),s=r(/*! ../graphic/shape/Rect */"x6Kt"),A=r(/*! ../graphic/shape/Ellipse */"rmlV"),l=r(/*! ../graphic/shape/Line */"yxFR"),c=r(/*! ../graphic/Path */"y+Vt"),u=r(/*! ../graphic/shape/Polygon */"h7HQ"),h=r(/*! ../graphic/shape/Polyline */"1Jh7"),d=r(/*! ../graphic/LinearGradient */"SKnc"),f=r(/*! ../graphic/Style */"K2GJ"),p=r(/*! ../core/matrix */"Fofx"),g=r(/*! ./path */"NC18").createFromString,m=r(/*! ../core/util */"bYtY"),v=m.isString,y=m.extend,w=m.defaults,b=m.trim,C=m.each,B=/[\s,]+/;function x(t){v(t)&&(t=(new DOMParser).parseFromString(t,"text/xml"));for(9===t.nodeType&&(t=t.firstChild);"svg"!==t.nodeName.toLowerCase()||1!==t.nodeType;)t=t.nextSibling;return t}function E(){this._defs={},this._root=null,this._isDefine=!1,this._isText=!1}E.prototype.parse=function(t,e){e=e||{};var r=x(t);if(!r)throw new Error("Illegal svg");var i=new n;this._root=i;var o=r.getAttribute("viewBox")||"",a=parseFloat(r.getAttribute("width")||e.width),A=parseFloat(r.getAttribute("height")||e.height);isNaN(a)&&(a=null),isNaN(A)&&(A=null),I(r,i,null,!0);for(var l,c,u=r.firstChild;u;)this._parseNode(u,i),u=u.nextSibling;if(o){var h=b(o).split(B);h.length>=4&&(l={x:parseFloat(h[0]||0),y:parseFloat(h[1]||0),width:parseFloat(h[2]),height:parseFloat(h[3])})}if(l&&null!=a&&null!=A&&(c=Q(l,a,A),!e.ignoreViewBox)){var d=i;(i=new n).add(d),d.scale=c.scale.slice(),d.position=c.position.slice()}return e.ignoreRootClip||null==a||null==A||i.setClipPath(new s({shape:{x:0,y:0,width:a,height:A}})),{root:i,width:a,height:A,viewBoxRect:l,viewBoxTransform:c}},E.prototype._parseNode=function(t,e){var r,n,i=t.nodeName.toLowerCase();if("defs"===i?this._isDefine=!0:"text"===i&&(this._isText=!0),this._isDefine){if(n=k[i]){var o=n.call(this,t),a=t.getAttribute("id");a&&(this._defs[a]=o)}}else(n=S[i])&&(r=n.call(this,t,e),e.add(r));for(var s=t.firstChild;s;)1===s.nodeType&&this._parseNode(s,r),3===s.nodeType&&this._isText&&this._parseText(s,r),s=s.nextSibling;"defs"===i?this._isDefine=!1:"text"===i&&(this._isText=!1)},E.prototype._parseText=function(t,e){if(1===t.nodeType){var r=t.getAttribute("dx")||0,n=t.getAttribute("dy")||0;this._textX+=parseFloat(r),this._textY+=parseFloat(n)}var i=new o({style:{text:t.textContent,transformText:!0},position:[this._textX||0,this._textY||0]});T(e,i),I(t,i,this._defs);var a=i.style.fontSize;a&&a<9&&(i.style.fontSize=9,i.scale=i.scale||[1,1],i.scale[0]*=a/9,i.scale[1]*=a/9);var s=i.getBoundingRect();return this._textX+=s.width,e.add(i),i};var S={g:function(t,e){var r=new n;return T(e,r),I(t,r,this._defs),r},rect:function(t,e){var r=new s;return T(e,r),I(t,r,this._defs),r.setShape({x:parseFloat(t.getAttribute("x")||0),y:parseFloat(t.getAttribute("y")||0),width:parseFloat(t.getAttribute("width")||0),height:parseFloat(t.getAttribute("height")||0)}),r},circle:function(t,e){var r=new a;return T(e,r),I(t,r,this._defs),r.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),r:parseFloat(t.getAttribute("r")||0)}),r},line:function(t,e){var r=new l;return T(e,r),I(t,r,this._defs),r.setShape({x1:parseFloat(t.getAttribute("x1")||0),y1:parseFloat(t.getAttribute("y1")||0),x2:parseFloat(t.getAttribute("x2")||0),y2:parseFloat(t.getAttribute("y2")||0)}),r},ellipse:function(t,e){var r=new A;return T(e,r),I(t,r,this._defs),r.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),rx:parseFloat(t.getAttribute("rx")||0),ry:parseFloat(t.getAttribute("ry")||0)}),r},polygon:function(t,e){var r=t.getAttribute("points");r&&(r=F(r));var n=new u({shape:{points:r||[]}});return T(e,n),I(t,n,this._defs),n},polyline:function(t,e){var r=new c;T(e,r),I(t,r,this._defs);var n=t.getAttribute("points");return n&&(n=F(n)),new h({shape:{points:n||[]}})},image:function(t,e){var r=new i;return T(e,r),I(t,r,this._defs),r.setStyle({image:t.getAttribute("xlink:href"),x:t.getAttribute("x"),y:t.getAttribute("y"),width:t.getAttribute("width"),height:t.getAttribute("height")}),r},text:function(t,e){var r=t.getAttribute("x")||0,i=t.getAttribute("y")||0,o=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0;this._textX=parseFloat(r)+parseFloat(o),this._textY=parseFloat(i)+parseFloat(a);var s=new n;return T(e,s),I(t,s,this._defs),s},tspan:function(t,e){var r=t.getAttribute("x"),i=t.getAttribute("y");null!=r&&(this._textX=parseFloat(r)),null!=i&&(this._textY=parseFloat(i));var o=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0,s=new n;return T(e,s),I(t,s,this._defs),this._textX+=o,this._textY+=a,s},path:function(t,e){var r=t.getAttribute("d")||"",n=g(r);return T(e,n),I(t,n,this._defs),n}},k={lineargradient:function(t){var e=parseInt(t.getAttribute("x1")||0,10),r=parseInt(t.getAttribute("y1")||0,10),n=parseInt(t.getAttribute("x2")||10,10),i=parseInt(t.getAttribute("y2")||0,10),o=new d(e,r,n,i);return function(t,e){var r=t.firstChild;for(;r;){if(1===r.nodeType){var n=r.getAttribute("offset");n=n.indexOf("%")>0?parseInt(n,10)/100:n?parseFloat(n):0;var i=r.getAttribute("stop-color")||"#000000";e.addColorStop(n,i)}r=r.nextSibling}}(t,o),o},radialgradient:function(t){}};function T(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),w(e.__inheritedStyle,t.__inheritedStyle))}function F(t){for(var e=b(t).split(B),r=[],n=0;n<e.length;n+=2){var i=parseFloat(e[n]),o=parseFloat(e[n+1]);r.push([i,o])}return r}var L={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-align":"textAlign","alignment-baseline":"textBaseline"};function I(t,e,r,n){var i=e.__inheritedStyle||{},o="text"===e.type;if(1===t.nodeType&&(function(t,e){var r=t.getAttribute("transform");if(r){r=r.replace(/,/g," ");var n=null,i=[];r.replace(O,(function(t,e,r){i.push(e,r)}));for(var o=i.length-1;o>0;o-=2){var a=i[o],s=i[o-1];switch(n=n||p.create(),s){case"translate":a=b(a).split(B),p.translate(n,n,[parseFloat(a[0]),parseFloat(a[1]||0)]);break;case"scale":a=b(a).split(B),p.scale(n,n,[parseFloat(a[0]),parseFloat(a[1]||a[0])]);break;case"rotate":a=b(a).split(B),p.rotate(n,n,parseFloat(a[0]));break;case"skew":a=b(a).split(B),console.warn("Skew transform is not supported yet");break;case"matrix":a=b(a).split(B);n[0]=parseFloat(a[0]),n[1]=parseFloat(a[1]),n[2]=parseFloat(a[2]),n[3]=parseFloat(a[3]),n[4]=parseFloat(a[4]),n[5]=parseFloat(a[5])}}e.setLocalTransform(n)}}(t,e),y(i,function(t){var e=t.getAttribute("style"),r={};if(!e)return r;var n,i={};D.lastIndex=0;for(;null!=(n=D.exec(e));)i[n[1]]=n[2];for(var o in L)L.hasOwnProperty(o)&&null!=i[o]&&(r[L[o]]=i[o]);return r}(t)),!n))for(var a in L)if(L.hasOwnProperty(a)){var s=t.getAttribute(a);null!=s&&(i[L[a]]=s)}var A=o?"textFill":"fill",l=o?"textStroke":"stroke";e.style=e.style||new f;var c=e.style;null!=i.fill&&c.set(A,U(i.fill,r)),null!=i.stroke&&c.set(l,U(i.stroke,r)),C(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],(function(t){var e="lineWidth"===t&&o?"textStrokeWidth":t;null!=i[t]&&c.set(e,parseFloat(i[t]))})),i.textBaseline&&"auto"!==i.textBaseline||(i.textBaseline="alphabetic"),"alphabetic"===i.textBaseline&&(i.textBaseline="bottom"),"start"===i.textAlign&&(i.textAlign="left"),"end"===i.textAlign&&(i.textAlign="right"),C(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign","textBaseline"],(function(t){null!=i[t]&&c.set(t,i[t])})),i.lineDash&&(e.style.lineDash=b(i.lineDash).split(B)),c[l]&&"none"!==c[l]&&(e[l]=!0),e.__inheritedStyle=i}var _=/url\(\s*#(.*?)\)/;function U(t,e){var r=e&&t&&t.match(_);return r?e[b(r[1])]:t}var O=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.e,]*)\)/g;var D=/([^\s:;]+)\s*:\s*([^:;]+)/g;function Q(t,e,r){var n=e/t.width,i=r/t.height,o=Math.min(n,i);return{scale:[o,o],position:[-(t.x+t.width/2)*o+e/2,-(t.y+t.height/2)*o+r/2]}}e.parseXML=x,e.makeViewBoxTransform=Q,e.parseSVG=function(t,e){return(new E).parse(t,e)}},MKOG:
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/animation/Animation.js ***!
|
|
|
\*********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/util */"bYtY"),i=r(/*! ../core/event */"YH21").Dispatcher,o=r(/*! ./requestAnimationFrame */"mLcG"),a=r(/*! ./Animator */"Bq2U"),s=function(t){t=t||{},this.stage=t.stage||{},this.onframe=t.onframe||function(){},this._clips=[],this._running=!1,this._time,this._pausedTime,this._pauseStart,this._paused=!1,i.call(this)};s.prototype={constructor:s,addClip:function(t){this._clips.push(t)},addAnimator:function(t){t.animation=this;for(var e=t.getClips(),r=0;r<e.length;r++)this.addClip(e[r])},removeClip:function(t){var e=n.indexOf(this._clips,t);e>=0&&this._clips.splice(e,1)},removeAnimator:function(t){for(var e=t.getClips(),r=0;r<e.length;r++)this.removeClip(e[r]);t.animation=null},_update:function(){for(var t=(new Date).getTime()-this._pausedTime,e=t-this._time,r=this._clips,n=r.length,i=[],o=[],a=0;a<n;a++){var s=r[a],A=s.step(t,e);A&&(i.push(A),o.push(s))}for(a=0;a<n;)r[a]._needsRemove?(r[a]=r[n-1],r.pop(),n--):a++;n=i.length;for(a=0;a<n;a++)o[a].fire(i[a]);this._time=t,this.onframe(e),this.trigger("frame",e),this.stage.update&&this.stage.update()},_startLoop:function(){var t=this;this._running=!0,o((function e(){t._running&&(o(e),!t._paused&&t._update())}))},start:function(){this._time=(new Date).getTime(),this._pausedTime=0,this._startLoop()},stop:function(){this._running=!1},pause:function(){this._paused||(this._pauseStart=(new Date).getTime(),this._paused=!0)},resume:function(){this._paused&&(this._pausedTime+=(new Date).getTime()-this._pauseStart,this._paused=!1)},clear:function(){this._clips=[]},isFinished:function(){return!this._clips.length},animate:function(t,e){var r=new a(t,(e=e||{}).loop,e.getter,e.setter);return this.addAnimator(r),r}},n.mixin(s,i);var A=s;t.exports=A},NC18:
|
|
|
/*!***********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/tool/path.js ***!
|
|
|
\***********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../graphic/Path */"y+Vt"),i=r(/*! ../core/PathProxy */"IMiH"),o=r(/*! ./transformPath */"7oTu"),a=Math.sqrt,s=Math.sin,A=Math.cos,l=Math.PI,c=function(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])},u=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(c(t)*c(e))},h=function(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(u(t,e))};function d(t,e,r,n,i,o,c,d,f,p,g){var m=f*(l/180),v=A(m)*(t-r)/2+s(m)*(e-n)/2,y=-1*s(m)*(t-r)/2+A(m)*(e-n)/2,w=v*v/(c*c)+y*y/(d*d);w>1&&(c*=a(w),d*=a(w));var b=(i===o?-1:1)*a((c*c*(d*d)-c*c*(y*y)-d*d*(v*v))/(c*c*(y*y)+d*d*(v*v)))||0,C=b*c*y/d,B=b*-d*v/c,x=(t+r)/2+A(m)*C-s(m)*B,E=(e+n)/2+s(m)*C+A(m)*B,S=h([1,0],[(v-C)/c,(y-B)/d]),k=[(v-C)/c,(y-B)/d],T=[(-1*v-C)/c,(-1*y-B)/d],F=h(k,T);u(k,T)<=-1&&(F=l),u(k,T)>=1&&(F=0),0===o&&F>0&&(F-=2*l),1===o&&F<0&&(F+=2*l),g.addData(p,x,E,c,d,S,F,m,o)}var f=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,p=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function g(t,e){var r=function(t){if(!t)return new i;for(var e,r=0,n=0,o=r,a=n,s=new i,A=i.CMD,l=t.match(f),c=0;c<l.length;c++){for(var u,h=l[c],g=h.charAt(0),m=h.match(p)||[],v=m.length,y=0;y<v;y++)m[y]=parseFloat(m[y]);for(var w=0;w<v;){var b,C,B,x,E,S,k,T=r,F=n;switch(g){case"l":r+=m[w++],n+=m[w++],u=A.L,s.addData(u,r,n);break;case"L":r=m[w++],n=m[w++],u=A.L,s.addData(u,r,n);break;case"m":r+=m[w++],n+=m[w++],u=A.M,s.addData(u,r,n),o=r,a=n,g="l";break;case"M":r=m[w++],n=m[w++],u=A.M,s.addData(u,r,n),o=r,a=n,g="L";break;case"h":r+=m[w++],u=A.L,s.addData(u,r,n);break;case"H":r=m[w++],u=A.L,s.addData(u,r,n);break;case"v":n+=m[w++],u=A.L,s.addData(u,r,n);break;case"V":n=m[w++],u=A.L,s.addData(u,r,n);break;case"C":u=A.C,s.addData(u,m[w++],m[w++],m[w++],m[w++],m[w++],m[w++]),r=m[w-2],n=m[w-1];break;case"c":u=A.C,s.addData(u,m[w++]+r,m[w++]+n,m[w++]+r,m[w++]+n,m[w++]+r,m[w++]+n),r+=m[w-2],n+=m[w-1];break;case"S":b=r,C=n;var L=s.len(),I=s.data;e===A.C&&(b+=r-I[L-4],C+=n-I[L-3]),u=A.C,T=m[w++],F=m[w++],r=m[w++],n=m[w++],s.addData(u,b,C,T,F,r,n);break;case"s":b=r,C=n;L=s.len(),I=s.data;e===A.C&&(b+=r-I[L-4],C+=n-I[L-3]),u=A.C,T=r+m[w++],F=n+m[w++],r+=m[w++],n+=m[w++],s.addData(u,b,C,T,F,r,n);break;case"Q":T=m[w++],F=m[w++],r=m[w++],n=m[w++],u=A.Q,s.addData(u,T,F,r,n);break;case"q":T=m[w++]+r,F=m[w++]+n,r+=m[w++],n+=m[w++],u=A.Q,s.addData(u,T,F,r,n);break;case"T":b=r,C=n;L=s.len(),I=s.data;e===A.Q&&(b+=r-I[L-4],C+=n-I[L-3]),r=m[w++],n=m[w++],u=A.Q,s.addData(u,b,C,r,n);break;case"t":b=r,C=n;L=s.len(),I=s.data;e===A.Q&&(b+=r-I[L-4],C+=n-I[L-3]),r+=m[w++],n+=m[w++],u=A.Q,s.addData(u,b,C,r,n);break;case"A":B=m[w++],x=m[w++],E=m[w++],S=m[w++],k=m[w++],d(T=r,F=n,r=m[w++],n=m[w++],S,k,B,x,E,u=A.A,s);break;case"a":B=m[w++],x=m[w++],E=m[w++],S=m[w++],k=m[w++],d(T=r,F=n,r+=m[w++],n+=m[w++],S,k,B,x,E,u=A.A,s)}}"z"!==g&&"Z"!==g||(u=A.Z,s.addData(u),r=o,n=a),e=u}return s.toStatic(),s}(t);return(e=e||{}).buildPath=function(t){if(t.setData){t.setData(r.data),(e=t.getContext())&&t.rebuildPath(e)}else{var e=t;r.rebuildPath(e)}},e.applyTransform=function(t){o(r,t),this.dirty(!0)},e}e.createFromString=function(t,e){return new n(g(t,e))},e.extendFromString=function(t,e){return n.extend(g(t,e))},e.mergePath=function(t,e){for(var r=[],i=t.length,o=0;o<i;o++){var a=t[o];a.path||a.createPathProxy(),a.__dirtyPath&&a.buildPath(a.path,a.shape,!0),r.push(a.path)}var s=new n(e);return s.createPathProxy(),s.buildPath=function(t){t.appendPath(r);var e=t.getContext();e&&t.rebuildPath(e)},s}},NohK:
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/size-sensor/lib/debounce.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;e.default=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:60,r=null;return function(){for(var n=this,i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];clearTimeout(r),r=setTimeout((function(){t.apply(n,o)}),e)}}},NvD2:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/rc-tree/es/utils/conductUtil.js ***!
|
|
|
\******************************************************/
|
|
|
/*! exports provided: isCheckDisabled, conductCheck */
|
|
|
/*! exports used: conductCheck */function(t,e,r){"use strict";r.d(e,"a",(function(){return a}));var n=r(/*! rc-util/es/warning */"Kwbf");function i(t,e){var r=new Set;return t.forEach((function(t){e.has(t)||r.add(t)})),r}function o(t){var e=t||{},r=e.disabled,n=e.disableCheckbox,i=e.checkable;return!(!r&&!n)||!1===i}function a(t,e,r,a){var s,A=[];s=a||o;var l=new Set(t.filter((function(t){var e=!!r[t];return e||A.push(t),e}))),c=new Map,u=0;return Object.keys(r).forEach((function(t){var e=r[t],n=e.level,i=c.get(n);i||(i=new Set,c.set(n,i)),i.add(e),u=Math.max(u,n)})),Object(n.a)(!A.length,"Tree missing follow keys: ".concat(A.slice(0,100).map((function(t){return"'".concat(t,"'")})).join(", "))),!0===e?function(t,e,r,n){for(var o=new Set(t),a=new Set,s=0;s<=r;s+=1){(e.get(s)||new Set).forEach((function(t){var e=t.key,r=t.node,i=t.children,a=void 0===i?[]:i;o.has(e)&&!n(r)&&a.filter((function(t){return!n(t.node)})).forEach((function(t){o.add(t.key)}))}))}for(var A=new Set,l=r;l>=0;l-=1){(e.get(l)||new Set).forEach((function(t){var e=t.parent,r=t.node;if(!n(r)&&t.parent&&!A.has(t.parent.key))if(n(t.parent.node))A.add(e.key);else{var i=!0,s=!1;(e.children||[]).filter((function(t){return!n(t.node)})).forEach((function(t){var e=t.key,r=o.has(e);i&&!r&&(i=!1),s||!r&&!a.has(e)||(s=!0)})),i&&o.add(e.key),s&&a.add(e.key),A.add(e.key)}}))}return{checkedKeys:Array.from(o),halfCheckedKeys:Array.from(i(a,o))}}(l,c,u,s):function(t,e,r,n,o){for(var a=new Set(t),s=new Set(e),A=0;A<=n;A+=1){(r.get(A)||new Set).forEach((function(t){var e=t.key,r=t.node,n=t.children,i=void 0===n?[]:n;a.has(e)||s.has(e)||o(r)||i.filter((function(t){return!o(t.node)})).forEach((function(t){a.delete(t.key)}))}))}s=new Set;for(var l=new Set,c=n;c>=0;c-=1){(r.get(c)||new Set).forEach((function(t){var e=t.parent,r=t.node;if(!o(r)&&t.parent&&!l.has(t.parent.key))if(o(t.parent.node))l.add(e.key);else{var n=!0,i=!1;(e.children||[]).filter((function(t){return!o(t.node)})).forEach((function(t){var e=t.key,r=a.has(e);n&&!r&&(n=!1),i||!r&&!s.has(e)||(i=!0)})),n||a.delete(e.key),i&&s.add(e.key),l.add(e.key)}}))}return{checkedKeys:Array.from(a),halfCheckedKeys:Array.from(i(s,a))}}(l,e.halfCheckedKeys,c,u,s)}},OLES:
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./node_modules/rc-tooltip/es/index.js + 2 modules ***!
|
|
|
\*********************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/typeof.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-tooltip/es/placements.js because of ./node_modules/antd/es/tooltip/placements.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-trigger/es/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";var n=r("U8pU"),i=r("VTBJ"),o=r("Ff2n"),a=r("q1tI"),s=r("uciX"),A=r("7ixt"),l=function(t){var e=t.overlay,r=t.prefixCls,n=t.id,i=t.overlayInnerStyle;return a.createElement("div",{className:"".concat(r,"-inner"),id:n,role:"tooltip",style:i},"function"==typeof e?e():e)},c=Object(a.forwardRef)((function(t,e){var r=t.overlayClassName,c=t.trigger,u=void 0===c?["hover"]:c,h=t.mouseEnterDelay,d=void 0===h?0:h,f=t.mouseLeaveDelay,p=void 0===f?.1:f,g=t.overlayStyle,m=t.prefixCls,v=void 0===m?"rc-tooltip":m,y=t.children,w=t.onVisibleChange,b=t.afterVisibleChange,C=t.transitionName,B=t.animation,x=t.placement,E=void 0===x?"right":x,S=t.align,k=void 0===S?{}:S,T=t.destroyTooltipOnHide,F=void 0!==T&&T,L=t.defaultVisible,I=t.getTooltipContainer,_=t.overlayInnerStyle,U=Object(o.a)(t,["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle"]),O=Object(a.useRef)(null);Object(a.useImperativeHandle)(e,(function(){return O.current}));var D=Object(i.a)({},U);"visible"in t&&(D.popupVisible=t.visible);var Q=!1,M=!1;if("boolean"==typeof F)Q=F;else if(F&&"object"===Object(n.a)(F)){var R=F.keepParent;Q=!0===R,M=!1===R}return a.createElement(s.a,Object.assign({popupClassName:r,prefixCls:v,popup:function(){var e=t.arrowContent,r=void 0===e?null:e,n=t.overlay,i=t.id;return[a.createElement("div",{className:"".concat(v,"-arrow"),key:"arrow"},r),a.createElement(l,{key:"content",prefixCls:v,id:i,overlay:n,overlayInnerStyle:_})]},action:u,builtinPlacements:A.a,popupPlacement:E,ref:O,popupAlign:k,getPopupContainer:I,onPopupVisibleChange:w,afterPopupVisibleChange:b,popupTransitionName:C,popupAnimation:B,defaultPopupVisible:L,destroyPopupOnHide:Q,autoDestroy:M,mouseLeaveDelay:p,popupStyle:g,mouseEnterDelay:d},D),y)}));e.a=c},OS9S:
|
|
|
/*!********************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/IncrementalDisplayable.js ***!
|
|
|
\********************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/util */"bYtY").inherits,i=r(/*! ./Displayable */"Gev7"),o=r(/*! ../core/BoundingRect */"mFDi");function a(t){i.call(this,t),this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.notClear=!0}a.prototype.incremental=!0,a.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.dirty(),this.notClear=!1},a.prototype.addDisplayable=function(t,e){e?this._temporaryDisplayables.push(t):this._displayables.push(t),this.dirty()},a.prototype.addDisplayables=function(t,e){e=e||!1;for(var r=0;r<t.length;r++)this.addDisplayable(t[r],e)},a.prototype.eachPendingDisplayable=function(t){for(var e=this._cursor;e<this._displayables.length;e++)t&&t(this._displayables[e]);for(e=0;e<this._temporaryDisplayables.length;e++)t&&t(this._temporaryDisplayables[e])},a.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++){(e=this._displayables[t]).parent=this,e.update(),e.parent=null}for(t=0;t<this._temporaryDisplayables.length;t++){var e;(e=this._temporaryDisplayables[t]).parent=this,e.update(),e.parent=null}},a.prototype.brush=function(t,e){for(var r=this._cursor;r<this._displayables.length;r++){(n=this._displayables[r]).beforeBrush&&n.beforeBrush(t),n.brush(t,r===this._cursor?null:this._displayables[r-1]),n.afterBrush&&n.afterBrush(t)}this._cursor=r;for(r=0;r<this._temporaryDisplayables.length;r++){var n;(n=this._temporaryDisplayables[r]).beforeBrush&&n.beforeBrush(t),n.brush(t,0===r?null:this._temporaryDisplayables[r-1]),n.afterBrush&&n.afterBrush(t)}this._temporaryDisplayables=[],this.notClear=!0};var s=[];a.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new o(1/0,1/0,-1/0,-1/0),e=0;e<this._displayables.length;e++){var r=this._displayables[e],n=r.getBoundingRect().clone();r.needLocalTransform()&&n.applyTransform(r.getLocalTransform(s)),t.union(n)}this._rect=t}return this._rect},a.prototype.contain=function(t,e){var r=this.transformCoordToLocal(t,e);if(this.getBoundingRect().contain(r[0],r[1]))for(var n=0;n<this._displayables.length;n++){if(this._displayables[n].contain(t,e))return!0}return!1},n(a,i);var A=a;t.exports=A},OZM5:
|
|
|
/*!*****************************************!*\
|
|
|
!*** ./node_modules/rc-tree/es/util.js ***!
|
|
|
\*****************************************/
|
|
|
/*! exports provided: arrDel, arrAdd, posToArr, getPosition, isTreeNode, getDragNodesKeys, calcDropPosition, calcSelectedKeys, convertDataToTree, parseCheckedKeys, conductExpandParent, getDataAndAria */
|
|
|
/*! exports used: arrAdd, arrDel, calcDropPosition, calcSelectedKeys, conductExpandParent, getDataAndAria, getDragNodesKeys, getPosition, isTreeNode, parseCheckedKeys, posToArr */function(t,e,r){"use strict";r.d(e,"b",(function(){return a})),r.d(e,"a",(function(){return s})),r.d(e,"k",(function(){return A})),r.d(e,"h",(function(){return l})),r.d(e,"i",(function(){return c})),r.d(e,"g",(function(){return u})),r.d(e,"c",(function(){return h})),r.d(e,"d",(function(){return d})),r.d(e,"j",(function(){return f})),r.d(e,"e",(function(){return p})),r.d(e,"f",(function(){return g}));var n=r(/*! @babel/runtime/helpers/esm/toConsumableArray */"KQm4"),i=r(/*! @babel/runtime/helpers/esm/typeof */"U8pU"),o=(r(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),r(/*! react */"q1tI"),r(/*! rc-util/es/warning */"Kwbf"));r(/*! ./TreeNode */"WaYH");function a(t,e){var r=t.slice(),n=r.indexOf(e);return n>=0&&r.splice(n,1),r}function s(t,e){var r=t.slice();return-1===r.indexOf(e)&&r.push(e),r}function A(t){return t.split("-")}function l(t,e){return"".concat(t,"-").concat(e)}function c(t){return t&&t.type&&t.type.isTreeNode}function u(t,e){var r=[t];return function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];e.forEach((function(e){var n=e.key,i=e.children;r.push(n),t(i)}))}(e[t].children),r}function h(t,e){var r=t.clientY,n=e.selectHandle.getBoundingClientRect(),i=n.top,o=n.bottom,a=n.height,s=Math.max(.25*a,2);return r<=i+s?-1:r>=o-s?1:0}function d(t,e){if(t)return e.multiple?t.slice():t.length?[t[0]]:t}function f(t){if(!t)return null;var e;if(Array.isArray(t))e={checkedKeys:t,halfCheckedKeys:void 0};else{if("object"!==Object(i.a)(t))return Object(o.a)(!1,"`checkedKeys` is not an array or an object"),null;e={checkedKeys:t.checked||void 0,halfCheckedKeys:t.halfChecked||void 0}}return e}function p(t,e){var r=new Set;return(t||[]).forEach((function(t){!function t(n){if(!r.has(n)){var i=e[n];if(i){r.add(n);var o=i.parent;i.node.disabled||o&&t(o.key)}}}(t)})),Object(n.a)(r)}function g(t){var e={};return Object.keys(t).forEach((function(r){(r.startsWith("data-")||r.startsWith("aria-"))&&(e[r]=t[r])})),e}},Ot1p:
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./src/components/markdown-editor/index.tsx + 6 modules ***!
|
|
|
\**************************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/defineProperty.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/extends.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/RenderHtml/index.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/markdown-editor/code-block/index.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/modal.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/components/useInterval.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/pages/tasks/util.js because of ./src/pages/tasks/index.jsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/env.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/fetch.ts */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./src/utils/util.tsx */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/button/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/button/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/form/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/form/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input-number/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input-number/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/message/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/message/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/modal/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/modal/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/popover/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/popover/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/radio/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/radio/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/codemirror/lib/codemirror.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/qrcode.react/lib/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/resize-observer-polyfill/dist/ResizeObserver.es.js (<- Module uses injected variables (global)) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/uuid/dist/esm-browser/v4.js */function(t,e,r){"use strict";r("2qtc");var n=r("kLXV"),i=r("rAM+"),o=(r("miYZ"),r("tsqr")),a=r("9og8"),s=r("tJVT"),A=r("jrin"),l=r("WmNS"),c=r.n(l),u=r("q1tI"),h=r.n(u),d=r("VrN/"),f=r.n(d),p=r("bdgK"),g=(r("p77/"),r("Bd2K"),r("ELLl"),r("19Vz"),r("lZu9"),r("+NIl"),r("kSUc"),r("9Bee")),m=function(t){var e=t.value,r=void 0===e?"":e,n=(t.className,t.showTextOnly,t.showLines,t.style,Object(u.useMemo)((function(){return""}),[r]));return h.a.createElement(h.a.Fragment,null,h.a.createElement("div",{dangerouslySetInnerHTML:{__html:n}}))},v=(r("Q9mQ"),r("diRs")),y=r("0Owb"),w=(r("dejd"),r("C+DQ"),r("D1Df")),b=r.n(w),C=r("1vsH"),B=r("m3rI"),x=[{title:"粗体",icon:"icon-bold",actionName:"bold"},{title:"斜体",icon:"icon-italic",actionName:"italic"},"|",{title:"无序列表",icon:"icon-unorder-list",actionName:"list-ul"},{title:"有序列表",icon:"icon-order-list",actionName:"list-ol"},"|",{title:"行内代码",icon:"icon-code",actionName:"code"},{title:"代码块(多语言风格)",icon:"icon-file-code",actionName:"code-block"},{title:"链接",icon:"icon-link",actionName:"link"},"|",{title:"行内公式",icon:"icon-sum",actionName:"inline-latex"},{title:"多行公式",icon:"icon-formula",actionName:"latex"},"|",{title:"添加图片",icon:"icon-picture",actionName:"upload-image"},{title:"表格",icon:"icon-table",actionName:"add-table"},"|",{title:"换行",icon:"icon-minus",actionName:"line-break"},{title:"清空",icon:"icon-eraser",actionName:"eraser"}];function E(t){var e=t.onActionCallback,r=t.title,n=t.icon,i=t.actionName,o=t.className,a=void 0===o?"":o,s=t.children;return h.a.createElement("a",{title:r,className:a,onClick:function(){e(i)}},h.a.createElement("i",{className:"md-iconfont ".concat(n)}),s)}var S=function(t){var e=t.watch,r=t.showNullButton,n=t.onActionCallback,i=t.fullScreen,o=t.insertTemp,a=t.hidetoolBar,s=t.uuid,A=t.setOpenPhones,l=Object(C.E)("_educoder_session_login"),c=Object(C.E)("_educoder_session"),u=[].concat(x,[{title:"".concat(e?"关闭实时预览":"开启实时预览"),icon:"".concat(e?"icon-eye-slash":"icon-eye"),actionName:"trigger-watch"}]);return h.a.createElement("ul",{className:"markdown-toolbar-container"},!a&&u.map((function(t,e){return h.a.createElement("li",{key:e},t.actionName?h.a.createElement(E,Object(y.a)({},t,{onActionCallback:n})):h.a.createElement("span",{className:"v-line"}))})),r?h.a.createElement("li",null,h.a.createElement(E,{icon:"icon-edit",className:"btn-null",title:"增加填空",actionName:"add-null-ch",onActionCallback:n},h.a.createElement("span",{className:"fill-tip"},"点击插入\b填空项"))):null,o&&h.a.createElement("li",null,h.a.createElement(E,{icon:"icon-edit",className:"btn-null",title:"插入模板",actionName:"inster-template-".concat(o),onActionCallback:n},h.a.createElement("span",{className:"fill-tip"},"插入模板"))),h.a.createElement("li",null,h.a.createElement(v.a,{title:"打开手机扫一扫",content:h.a.createElement("div",null,h.a.createElement("span",{style:{display:"none"}},"test----",location.origin+"/upload.html?_educoder_session_login="+l+"&_educoder_session="+c+"&key="+s+"&api="+encodeURIComponent(B.a.API_SERVER)),h.a.createElement(b.a,{size:150,fgColor:"#000",value:location.origin+"/upload.html?_educoder_session_login="+l+"&_educoder_session="+c+"&key="+s+"&api="+encodeURIComponent(B.a.API_SERVER)}))},h.a.createElement("span",{className:"fill-tip",onMouseOver:function(){return A(!0)}},"手机上传文件"))),h.a.createElement("li",{className:"btn-full-screen"},h.a.createElement(E,{icon:"".concat(i?"icon-shrink":"icon-enlarge"),title:i?"关闭全屏":"开启全屏",actionName:"trigger-full-screen",onActionCallback:n})))},k=r("M8RZ"),T=(r("+L6B"),r("2/Rp")),F=(r("y8nQ"),r("Vl3Y")),L=(r("5NDa"),r("5rEg")),I={labelCol:{span:4},wrapperCol:{span:20}},_=function(t){var e=t.callback,r=t.onCancel;return h.a.createElement(F.a,Object(y.a)({},I,{initialValues:{link:"http://",title:""},className:"link-panel",onFinish:function(t){e(t)}}),h.a.createElement(F.a.Item,{label:"链接地址",name:"link",rules:[{required:!0,message:"请输入链接地址"}]},h.a.createElement(L.a,null)),h.a.createElement(F.a.Item,{label:"链接标题",name:"title",rules:[{required:!0,message:"请输入链接标题"}]},h.a.createElement(L.a,null)),h.a.createElement("div",{className:"flex-container flex-end"},h.a.createElement(T.a,{type:"primary",htmlType:"submit",style:{marginRight:10}},"确定"),h.a.createElement(T.a,{type:"ghost",onClick:r},"取消")))},U=r("7ahc"),O=r("k1fw"),D=(r("HmJG"),r("BjJ7")),Q=F.a.useForm,M={width:280,marginRight:10},R={labelCol:{span:5},wrapperCol:{span:19}},P=function(t){var e=t.callback,r=t.onCancel,n=Q(),i=Object(s.a)(n,1)[0],o=Object(u.useRef)();function a(t,e){i.setFieldsValue({src:"/api/attachments/".concat(t.id,"?type=").concat(t.content_type),type:e.type})}return h.a.createElement(F.a,Object(y.a)({form:i},R,{className:"upload-image-panel",onFinish:function(t){e(Object(O.a)(Object(O.a)({},t),{},{name:o.current}))}}),h.a.createElement(F.a.Item,{label:"文件地址",required:!0},h.a.createElement("div",{className:"flex-container"},h.a.createElement(F.a.Item,{noStyle:!0,name:"src",rules:[{required:!0,message:"请输入文件地址"}]},h.a.createElement(L.a,{style:M})),h.a.createElement(H,{onFileChange:function(t){var e=t.target.files[0];o.current=e.name,N(e,a)}}))),h.a.createElement(F.a.Item,{label:"文件描述",name:"alt"},h.a.createElement(L.a,{style:{width:264}})),h.a.createElement(F.a.Item,{style:{textAlign:"right"}},h.a.createElement(T.a,{type:"primary",htmlType:"submit",style:{marginRight:10}},"确定"),h.a.createElement(T.a,{type:"ghost",onClick:r},"取消")))};function H(t){var e=t.onFileChange;return h.a.createElement("a",{className:"upload-button"},"本地上传",h.a.createElement("input",{type:"file",onChange:e}))}function N(t,e){if(!t)throw new String("没有文件");var r=new FormData;r.append("editormd-image-file",t),r.append("file_param_name","editormd-image-file"),r.append("byxhr","true");var n=new window.XMLHttpRequest;n.withCredentials=!0,n.addEventListener("load",(function(r){e(JSON.parse(r.target.responseText),t)}),!1),n.addEventListener("error",(function(t){console.error(t)}),!1),n.open("POST","".concat(D.a,"/api/attachments.json")),n.send(r)}r("giR+");var K,j,G=r("fyUT"),V=(r("7Kak"),r("9yH6")),z=V.a.Group,W={margin:"0 8px"},Y=function(t){var e=t.callback,r=t.onCancel;return h.a.createElement(F.a,{className:"add-table-panel",initialValues:{row:3,col:2,align:"default"},onFinish:function(t){e(t)}},h.a.createElement("div",{className:"flex-container"},h.a.createElement("span",{style:W},"单元格数:"),h.a.createElement("span",{style:W},"行数"),h.a.createElement(F.a.Item,{name:"row",rules:[{required:!0,message:"请输入行数"}]},h.a.createElement(G.a,null)),h.a.createElement("span",{style:W},"列数"),h.a.createElement(F.a.Item,{name:"col",rules:[{required:!0,message:"请输入列数"}]},h.a.createElement(G.a,null))),h.a.createElement("div",{className:"flex-container",style:{marginTop:12}},h.a.createElement("span",{style:W},"对齐方式:"),h.a.createElement(F.a.Item,{name:"align"},h.a.createElement(z,null,h.a.createElement(V.a,{value:"default"},h.a.createElement("i",{className:"fa fa-align-justify"})),h.a.createElement(V.a,{value:"left"},h.a.createElement("i",{className:"fa fa-align-left"})),h.a.createElement(V.a,{value:"center"},h.a.createElement("i",{className:"fa fa-align-center"})),h.a.createElement(V.a,{value:"right"},h.a.createElement("i",{className:"fa fa-align-right"}))))),h.a.createElement("div",{className:"flex-container flex-end"},h.a.createElement(T.a,{type:"primary",htmlType:"submit",style:{marginRight:10}},"确定"),h.a.createElement(T.a,{type:"ghost",onClick:r},"取消")))},X=r("ErOA"),q=r("7Cbv"),J="------------",Z={default:J,left:":".concat(J),center:":".concat(J,":"),right:"".concat(J,":")},$=r("9VGf");function tt(t){return/^\d+$/.test(t)?"".concat(t,"px"):t}var et=navigator.platform.toUpperCase().indexOf("MAC")>=0?"Cmd":"Ctrl",rt=["pptm","pptx","ppt","pot","pps","ppa","potx","ppsx","ppam","pptm","potm","ppsm","doc","docx","dot","dotx","docm","dotm","xls","xlsx","csv","xlt","xla","xltx","xlsm","xltm","xlam","xlsb"],nt=(K={},Object(A.a)(K,et+"-B","bold"),Object(A.a)(K,et+"-I","italic"),K),it=(j={},Object(A.a)(j,"link","添加链接"),Object(A.a)(j,"code-block","添加代码块"),Object(A.a)(j,"upload-image","添加文件"),Object(A.a)(j,"add-table","添加表格"),j);e.a=function(t){var e=t.defaultValue,r=void 0===e?"":e,l=t.onChange,d=t.width,v=void 0===d?"100%":d,y=t.height,w=void 0===y?400:y,b=t.miniToolbar,C=void 0!==b&&b,x=t.isFocus,E=void 0!==x&&x,T=t.watch,F=t.insertTemp,L=t.mode,I=void 0===L?"markdown":L,O=t.id,D=void 0===O?"markdown-editor-id":O,Q=t.showResizeBar,M=void 0!==Q&&Q,R=t.noStorage,H=void 0!==R&&R,K=t.showNullButton,j=void 0!==K&&K,G=t.hidetoolBar,V=void 0!==G&&G,z=t.fullScreen,W=void 0!==z&&z,J=t.onBlur,et=t.onCMBeforeChange,ot=t.onFullScreen,at=t.className,st=void 0===at?"":at,At=t.disablePaste,lt=void 0!==At&&At,ct=t.placeholder,ut=void 0===ct?"":ct,ht=t.values,dt=void 0===ht?"":ht,ft=Object(u.useState)(null),pt=Object(s.a)(ft,2),gt=pt[0],mt=pt[1],vt=Object(u.useState)(r),yt=Object(s.a)(vt,2),wt=yt[0],bt=yt[1],Ct=Object(u.useState)(T),Bt=Object(s.a)(Ct,2),xt=Bt[0],Et=Bt[1],St=Object(u.useState)(W),kt=Object(s.a)(St,2),Tt=kt[0],Ft=kt[1],Lt=Object(u.useState)(""),It=Object(s.a)(Lt,2),_t=It[0],Ut=It[1],Ot=Object(u.useState)(0),Dt=Object(s.a)(Ot,2),Qt=Dt[0],Mt=Dt[1],Rt=Object(u.useState)(w),Pt=Object(s.a)(Rt,2),Ht=Pt[0],Nt=Pt[1],Kt=Object(u.useState)(!1),jt=Object(s.a)(Kt,2),Gt=(jt[0],jt[1]),Vt=Object(u.useRef)(Object(q.a)()),zt=Object(u.useRef)(!1),Wt=Object(u.useRef)(),Yt=Object(u.useRef)(),Xt=Object(u.useRef)(),qt=Object(u.useRef)(),Jt=Object(u.useRef)(),Zt=function(){var t=Object(a.a)(c.a.mark((function t(){var e,r;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(X.a)("/api/attachments/distinct_hash_val.json",{method:"post",body:{hash_val:Vt.current}});case 2:null!=(r=t.sent)&&null!==(e=r.attachments)&&void 0!==e&&e.length&&(console.log("cm:",gt,Yt),r.attachments.map((function(t){t.content_type.indexOf("image")>-1?gt.replaceSelection(".concat(t.content_type,")")):t.content_type.indexOf("video")>-1?gt.replaceSelection('<video width="100%" controls src="'.concat(B.a.API_SERVER,"/api/attachments/").concat(data.id,'"></video>')):t.content_type.indexOf("pdf")>-1?gt.replaceSelection('<a href="'.concat(B.a.API_SERVER,"/api/attachments/").concat(t.id,"?type=").concat(t.content_type,'&disposition=inline" target="_blank">').concat(t.name,"</a>")):gt.replaceSelection("[".concat(t.name,"](").concat(B.a.API_SERVER,"/api/attachments/").concat(t.id,"?type=").concat(t.content_type,")"))})));case 4:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();Object(u.useEffect)((function(){bt(dt),null==gt||gt.setValue(dt)}),[dt]),Object(u.useEffect)((function(){null==ot||ot(Tt)}),[Tt]),Object(u.useEffect)((function(){if(Yt.current){var t=f.a.fromTextArea(Yt.current,{mode:I,lineNumbers:!C,lineWrapping:!0,value:r,autoCloseTags:!0,autoCloseBrackets:!0});function e(e,r){if(!lt){var n=r.clipboardData;if(n){var i=n.types.toString(),a=n.items;if("Files"===i||n.types.indexOf("Files")>-1){if(r.preventDefault(),"stex"==I)return;try{var s,A=a[1];"file"===(null===(s=a[0])||void 0===s?void 0:s.kind)&&(A=a[0]);var l=A.getAsFile(),c=l.name.split(".").pop();N(l,(function(e){var r,n,i;e.id?(null==l||null===(r=l.type)||void 0===r?void 0:r.indexOf("image"))>-1?t.replaceSelection(".concat(e.content_type,")")):(null==l||null===(n=l.type)||void 0===n?void 0:n.indexOf("video"))>-1?t.replaceSelection('<video width="100%" controls src="'.concat(B.a.API_SERVER,"/api/attachments/").concat(e.id,'"></video>')):(null==l||null===(i=l.type)||void 0===i?void 0:i.indexOf("pdf"))>-1?t.replaceSelection('<a href="'.concat(B.a.API_SERVER,"/api/attachments/").concat(e.id,"?type=").concat(l.type,'&disposition=inline" target="_blank">').concat(l.name,"</a>")):rt.includes(c)?t.replaceSelection('<a href="'.concat(B.a.API_SERVER,"/api/attachments/").concat(e.id,'?type=office&disposition=inline" target="_blank">').concat(l.name,"</a>")):t.replaceSelection("[".concat(l.name,"](").concat(B.a.API_SERVER,"/api/attachments/").concat(e.id,"?type=").concat(e.content_type,")")):401===(null==e?void 0:e.status)&&(document.location.href="/user/login")}))}catch(r){o.b.warn("请使用chrome浏览器粘贴")}return!0}return!0}return!0}r.preventDefault()}return E&&t.focus(),t.on("paste",e),t.on("dragleave",(function(t,e){Xt.current.classList.remove("mouse-hover-md")})),t.on("dragover",(function(t,e){Xt.current.classList.add("mouse-hover-md")})),t.on("drop",(function(e,r){var n;if(Xt.current.classList.add("mouse-hover-md"),(n=r.dataTransfer.files).length>0){r.preventDefault(),r.stopPropagation();for(var i=function(e){var r=n[e],i=r.name.split(".").pop();N(r,(function(e){var n,o,a;e.id?(null==r||null===(n=r.type)||void 0===n?void 0:n.indexOf("image"))>-1?t.replaceSelection(".concat(e.content_type,")")):(null==r||null===(o=r.type)||void 0===o?void 0:o.indexOf("video"))>-1?t.replaceSelection('<video width="100%" controls src="'.concat(B.a.API_SERVER,"/api/attachments/").concat(e.id,'"></video>')):(null==r||null===(a=r.type)||void 0===a?void 0:a.indexOf("pdf"))>-1?t.replaceSelection('<a href="'.concat(B.a.API_SERVER,"/api/attachments/").concat(e.id,"?type=").concat(r.type,'&disposition=inline" target="_blank">').concat(r.name,"</a>")):rt.includes(i)?t.replaceSelection('<a href="'.concat(B.a.API_SERVER,"/api/attachments/").concat(e.id,'?type=office&disposition=inline" target="_blank">').concat(r.name,"</a>")):t.replaceSelection("[".concat(r.name,"](").concat(B.a.API_SERVER,"/api/attachments/").concat(e.id,"?type=").concat(e.content_type,")")):401===(null==e?void 0:e.status)&&(document.location.href="/user/login")}))},o=0;o<n.length;o++)i(o)}})),mt(t),function(){t.off("paste",e)}}}),[]);var $t=Object(u.useCallback)((function(){Xt.current}),[Ht,Xt,Tt]);Object(u.useEffect)((function(){if(gt){var t=function(){var t=new p.default((function(t){var e,r=Object(i.a)(t);try{for(r.s();!(e=r.n()).done;){var n=e.value;(n.target.offsetHeight>0||n.target.offsetWidth>0)&&($t(),gt.setSize("100%","100%"),gt.refresh())}}catch(t){r.e(t)}finally{r.f()}}));return t.observe(Yt.current.parentElement),t}();return function(){t.unobserve(Yt.current.parentElement)}}}),[gt,$t]),Object(u.useEffect)((function(){if(gt){for(var t=[],e=function(){var e=n[r],i=(o=Object(s.a)(e,2))[0],a=o[1],l=Object(A.a)({},i,(function(){te(a)}));t.push(l),gt.addKeyMap(l)},r=0,n=Object.entries(nt);r<n.length;r++){var o;e()}return Wt.current=setInterval((function(){zt.current&&Zt()}),4e3),function(){clearInterval(Wt.current);var e,r=Object(i.a)(t);try{for(r.s();!(e=r.n()).done;){var n=e.value;gt.removeKeyMap(n)}}catch(t){r.e(t)}finally{r.f()}}}}),[gt]),Object(u.useEffect)((function(){W!==Tt&&Ft(W)}),[W]),Object($.a)((function(){if(!H&&Qt>0){var t=(new Date).getTime(),e=window.sessionStorage.getItem(D);t>=Qt+1e4&&(!e||e!==wt)&&(window.sessionStorage.setItem(D,wt),Gt(!0))}}),1e4),Object(u.useEffect)((function(){Et(T)}),[gt,T]),Object(u.useEffect)((function(){gt&&E&>.focus()}),[gt,E]),Object(u.useEffect)((function(){if(xt&>){var t=gt.getScrollerElement();function e(t){var e=t.target;if(Jt.current){var r=e.scrollTop/e.scrollHeight;Jt.current.scrollTop=Jt.current.scrollHeight*r}}return t.addEventListener("scroll",e),function(){t.removeEventListener("scroll",e)}}}),[gt,xt]),Object(u.useEffect)((function(){if(gt&&et){function t(t,e){et(t,e)}return gt.on("beforeChange",t),function(){gt.off("beforeChange",t)}}}),[gt,et]),Object(u.useEffect)((function(){if(gt&&J){function t(){J(gt.getValue())}return gt.on("blur",t),function(){gt.off("blur",t)}}}),[gt,J]),Object(u.useEffect)((function(){if(gt){function t(t){var e=t.getValue();bt(e),Mt((new Date).getTime()),t.getScrollerElement().dispatchEvent(new CustomEvent("scroll")),l&&l(e)}return gt.on("change",t),function(){gt.off("change",t)}}}),[gt,l]),Object(u.useEffect)((function(){gt&&(null==r?(gt.setValue(""),bt("")):r!==gt.getValue()&&(gt.setValue(r),bt(r),gt.setCursor(gt.lineCount(),0)))}),[gt,r]);var te=Object(u.useCallback)((function(t){var e=gt.getCursor(),r=gt.getSelection(),n=r.split("\n");switch(t){case"bold":return gt.replaceSelection("**"+r+"**"),""===r&>.setCursor(e.line,e.ch+2),gt.focus();case"italic":return gt.replaceSelection("*"+r+"*"),""===r&>.setCursor(e.line,e.ch+1),gt.focus();case"code":return gt.replaceSelection("`"+r+"`"),""===r&>.setCursor(e.line,e.ch+1),gt.focus();case"inline-latex":return gt.replaceSelection("`$$"+r+"$$`"),""===r&>.setCursor(e.line,e.ch+3),gt.focus();case"latex":return gt.replaceSelection("```latex\n"+r+"\n```"),gt.setCursor(e.line+1,r.length+1),gt.focus();case"line-break":return gt.replaceSelection("<br/>\n"),gt.focus();case"list-ul":return""===r?gt.replaceSelection("- "+r):gt.replaceSelection(n.map((function(t){return""===t?"":"- ".concat(t)})).join("\n")),gt.focus();case"list-ol":return""===r?gt.replaceSelection("1. "+r):gt.replaceSelection(n.map((function(t,e){return""===t?"":"".concat(e+1,". ").concat(t)})).join("\n")),gt.focus();case"add-null-ch":return""===r&>.setCursor(e.line,e.ch+1),gt.replaceSelection("▁"),gt.focus();case"inster-template-1":return""===r&>.setCursor(e.line,e.ch),gt.replaceSelection("\n**模板标题**\n模板正文内容,可输入文本内容和粘贴图片等操作"),gt.focus();case"eraser":return gt.setValue(""),gt.focus();case"trigger-watch":return Et(!xt),gt.focus();case"trigger-full-screen":return Ft(!Tt),gt.focus();case"link":return void Ut("link");case"code-block":return void Ut("code-block");case"upload-image":return void Ut("upload-image");case"add-table":return void Ut("add-table");default:throw new Error}}),[gt,xt,Tt]),ee=Object(u.useCallback)((function(t){switch(Ut(""),_t){case"link":var e=t.title,r=t.link;return gt.replaceSelection("[".concat(e,"](").concat(r,")")),gt.focus();case"code-block":var n=t.language,i=t.content;return gt.replaceSelection(["```"+n,i,"```"].join("\n")),gt.focus();case"upload-image":var o=t.src,a=t.alt,s=t.name;return o.indexOf("type=image")>-1?gt.replaceSelection(".concat(o,' "').concat(a||"",'" )')):o.indexOf("type=application/pdf")>-1?gt.replaceSelection('<a href="'.concat(o,'&disposition=inline" target="_blank">').concat(s,"</a>")):gt.replaceSelection('<a href="'.concat(o,'" target="_blank">').concat(s,"</a>")),gt.focus();case"add-table":for(var A=t.row,l=t.col,c=t.align,u="\n",h=0;h<A;h++){for(var d=[],f=[],p=0;p<l;p++)1===h&&f.push(Z[c]),d.push(" ");1===h&&(u+="| ".concat(f.join(" | ")," |\n")),u+="| ".concat(d.join(1===l?"":" | ")," |\n")}return gt.replaceSelection(u+"\n"),gt.focus();default:throw new Error}}),[gt,_t]),re=Object(u.useMemo)((function(){switch(_t){case"link":return h.a.createElement(_,{callback:ee,onCancel:ne});case"code-block":return h.a.createElement(U.b,{callback:ee,onCancel:ne});case"upload-image":return h.a.createElement(P,{callback:ee,onCancel:ne});case"add-table":return h.a.createElement(Y,{callback:ee,onCancel:ne});default:return null}}),[_t]);function ne(){Ut("")}Object(u.useEffect)((function(){if(qt.current){var t=qt.current,e=!1,r=0;function n(t){e=!0,r=t.pageY}function i(){e=!1}function o(t){if(e){var n=t.pageY-r;n<0&&(n=0),n>300&&(n=300),Nt(w+n+"px")}}return t.addEventListener("mousedown",n),document.addEventListener("mousemove",o),document.addEventListener("mouseup",i),function(){t.removeEventListener("mousedown",n),document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",i)}}}),[gt,qt]),Object(u.useEffect)((function(){Nt(w)}),[w]);var ie={width:tt(v),height:tt(Ht)};Object(u.useMemo)((function(){if(Qt){var t=new Date(Qt),e=t.getHours(),r=t.getMinutes(),n=t.getSeconds();return r=r<10?"0"+r:r,n=n<10?"0"+n:n,"".concat(e=e<10?"0"+e:e,":").concat(r,":").concat(n)}return 0}),[Qt]);return h.a.createElement(u.Fragment,null,h.a.createElement("div",{className:"markdown-editor-wrapper",ref:Xt},h.a.createElement("div",{className:"markdown-editor-container ".concat(st," ").concat(xt?"on-preview":""," ").concat(C?"mini":""," ").concat(Tt?"full-screen":""),style:ie},h.a.createElement(S,{insertTemp:F,watch:xt,fullScreen:Tt,showNullButton:j,onActionCallback:te,hidetoolBar:V,uuid:Vt.current,setOpenPhones:function(){zt.current=!0}}),h.a.createElement("div",{className:"markdown-editor-body"},h.a.createElement("div",{className:"codemirror-container"},h.a.createElement("textarea",{ref:Yt,placeholder:ut})),xt?h.a.createElement("div",{ref:Jt,className:"preview-container"},"stex"===I&&h.a.createElement(m,{value:wt}),"stex"!==I&&h.a.createElement(g.a,{edit:!0,value:wt,replaces:function(t,e){var r=gt.getValue();r=r.replace(t,e),bt(r),null==gt||gt.setValue(r)}})):null))),M?h.a.createElement("a",{ref:qt,className:"editor-resize"}):null,h.a.createElement(k.a,null,it[_t]?h.a.createElement(n.a,{centered:!0,title:it[_t],visible:!0,onCancel:ne,footer:null},re):null))}},P47w:
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/svg/graphic.js ***!
|
|
|
\*************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./core */"hydK").createElement,i=r(/*! ../core/PathProxy */"IMiH"),o=r(/*! ../core/BoundingRect */"mFDi"),a=r(/*! ../core/matrix */"Fofx"),s=r(/*! ../contain/text */"6GrX"),A=r(/*! ../graphic/helper/text */"pzxd"),l=r(/*! ../graphic/Text */"dqUG"),c=i.CMD,u=Array.prototype.join,h=Math.round,d=Math.sin,f=Math.cos,p=Math.PI,g=2*Math.PI,m=180/p;function v(t){return h(1e4*t)/1e4}function y(t){return t<1e-4&&t>-1e-4}function w(t,e){e&&b(t,"transform","matrix("+u.call(e,",")+")")}function b(t,e,r){(!r||"linear"!==r.type&&"radial"!==r.type)&&t.setAttribute(e,r)}function C(t,e,r,n){if(function(t,e){var r=e?t.textFill:t.fill;return null!=r&&"none"!==r}(e,r)){var i=r?e.textFill:e.fill;b(t,"fill",i="transparent"===i?"none":i),b(t,"fill-opacity",null!=e.fillOpacity?e.fillOpacity*e.opacity:e.opacity)}else b(t,"fill","none");if(function(t,e){var r=e?t.textStroke:t.stroke;return null!=r&&"none"!==r}(e,r)){var o=r?e.textStroke:e.stroke;b(t,"stroke",o="transparent"===o?"none":o),b(t,"stroke-width",(r?e.textStrokeWidth:e.lineWidth)/(!r&&e.strokeNoScale?n.getLineScale():1)),b(t,"paint-order",r?"stroke":"fill"),b(t,"stroke-opacity",null!=e.strokeOpacity?e.strokeOpacity:e.opacity),e.lineDash?(b(t,"stroke-dasharray",e.lineDash.join(",")),b(t,"stroke-dashoffset",h(e.lineDashOffset||0))):b(t,"stroke-dasharray",""),e.lineCap&&b(t,"stroke-linecap",e.lineCap),e.lineJoin&&b(t,"stroke-linejoin",e.lineJoin),e.miterLimit&&b(t,"stroke-miterlimit",e.miterLimit)}else b(t,"stroke","none")}var B={};B.brush=function(t){var e=t.style,r=t.__svgEl;r||(r=n("path"),t.__svgEl=r),t.path||t.createPathProxy();var i=t.path;if(t.__dirtyPath){i.beginPath(),i.subPixelOptimize=!1,t.buildPath(i,t.shape),t.__dirtyPath=!1;var o=function(t){for(var e=[],r=t.data,n=t.len(),i=0;i<n;){var o="",a=0;switch(r[i++]){case c.M:o="M",a=2;break;case c.L:o="L",a=2;break;case c.Q:o="Q",a=4;break;case c.C:o="C",a=6;break;case c.A:var s=r[i++],A=r[i++],l=r[i++],u=r[i++],w=r[i++],b=r[i++],C=r[i++],B=r[i++],x=Math.abs(b),E=y(x-g)||(B?b>=g:-b>=g),S=b>0?b%g:b%g+g,k=!1;k=!!E||!y(x)&&S>=p==!!B;var T=v(s+l*f(w)),F=v(A+u*d(w));E&&(b=B?g-1e-4:1e-4-g,k=!0,9===i&&e.push("M",T,F));var L=v(s+l*f(w+b)),I=v(A+u*d(w+b));e.push("A",v(l),v(u),h(C*m),+k,+B,L,I);break;case c.Z:o="Z";break;case c.R:L=v(r[i++]),I=v(r[i++]);var _=v(r[i++]),U=v(r[i++]);e.push("M",L,I,"L",L+_,I,"L",L+_,I+U,"L",L,I+U,"L",L,I)}o&&e.push(o);for(var O=0;O<a;O++)e.push(v(r[i++]))}return e.join(" ")}(i);o.indexOf("NaN")<0&&b(r,"d",o)}C(r,e,!1,t),w(r,t.transform),null!=e.text?L(t,t.getBoundingRect()):_(t)};var x={brush:function(t){var e=t.style,r=e.image;r instanceof HTMLImageElement&&(r=r.src);if(r){var i=e.x||0,o=e.y||0,a=e.width,s=e.height,A=t.__svgEl;A||(A=n("image"),t.__svgEl=A),r!==t.__imageSrc&&(!function(t,e,r){t.setAttributeNS("http://www.w3.org/1999/xlink",e,r)}(A,"href",r),t.__imageSrc=r),b(A,"width",a),b(A,"height",s),b(A,"x",i),b(A,"y",o),w(A,t.transform),null!=e.text?L(t,t.getBoundingRect()):_(t)}}},E={},S=new o,k={},T=[],F={left:"start",right:"end",center:"middle",middle:"middle"},L=function(t,e){var r=t.style,i=t.transform,o=t instanceof l||r.transformText;t.__dirty&&A.normalizeTextStyle(r,!0);var c=r.text;if(null!=c&&(c+=""),A.needDrawText(c,r)){null==c&&(c=""),!o&&i&&(S.copy(e),S.applyTransform(i),e=S);var u=t.__textSvgEl;u||(u=n("text"),t.__textSvgEl=u);var h=u.style,d=r.font||s.DEFAULT_FONT,f=u.__computedFont;d!==u.__styleFont&&(h.font=u.__styleFont=d,f=u.__computedFont=h.font);var p=r.textPadding,g=r.textLineHeight,m=t.__textCotentBlock;m&&!t.__dirtyText||(m=t.__textCotentBlock=s.parsePlainText(c,f,p,g,r.truncate));var v=m.outerHeight,y=m.lineHeight;A.getBoxPosition(k,t,r,e);var b=k.baseX,B=k.baseY,x=k.textAlign||"left",E=k.textVerticalAlign;!function(t,e,r,n,i,o,s){a.identity(T),e&&r&&a.copy(T,r);var A=n.textRotation;if(i&&A){var l=n.textOrigin;"center"===l?(o=i.width/2+i.x,s=i.height/2+i.y):l&&(o=l[0]+i.x,s=l[1]+i.y),T[4]-=o,T[5]-=s,a.rotate(T,T,A),T[4]+=o,T[5]+=s}w(t,T)}(u,o,i,r,e,b,B);var F=b,L=s.adjustTextY(B,v,E);p&&(F=function(t,e,r){return"right"===e?t-r[1]:"center"===e?t+r[3]/2-r[1]/2:t+r[3]}(b,x,p),L+=p[0]),L+=y/2,C(u,r,!0,t);var _=m.canCacheByTextString,U=t.__tspanList||(t.__tspanList=[]),O=U.length;if(_&&t.__canCacheByTextString&&t.__text===c){if(t.__dirtyText&&O)for(var D=0;D<O;++D)I(U[D],x,F,L+D*y)}else{t.__text=c,t.__canCacheByTextString=_;var Q=m.lines,M=Q.length;for(D=0;D<M;D++){var R=U[D],P=Q[D];R?R.__zrText!==P&&(R.innerHTML="",R.appendChild(document.createTextNode(P))):(R=U[D]=n("tspan"),u.appendChild(R),R.appendChild(document.createTextNode(P))),I(R,x,F,L+D*y)}if(O>M){for(;D<O;D++)u.removeChild(U[D]);U.length=M}}}};function I(t,e,r,n){b(t,"dominant-baseline","middle"),b(t,"text-anchor",F[e]),b(t,"x",r),b(t,"y",n)}function _(t){t&&t.__textSvgEl&&(t.__textSvgEl.parentNode&&t.__textSvgEl.parentNode.removeChild(t.__textSvgEl),t.__textSvgEl=null,t.__tspanList=[],t.__text=null)}E.drawRectText=L,E.brush=function(t){null!=t.style.text?L(t,!1):_(t)},e.path=B,e.image=x,e.text=E},P4Qj:
|
|
|
/*!****************************************************!*\
|
|
|
!*** ./node_modules/size-sensor/lib/sensorPool.js ***!
|
|
|
\****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.removeSensor=e.getSensor=void 0;var n,i=(n=r(/*! ./id */"chpo"))&&n.__esModule?n:{default:n},o=r(/*! ./sensors */"FxDU"),a=r(/*! ./constant */"24YM");var s={};e.getSensor=function(t){var e=t.getAttribute(a.SizeSensorId);if(e&&s[e])return s[e];var r=(0,i.default)();t.setAttribute(a.SizeSensorId,r);var n=(0,o.createSensor)(t);return s[r]=n,n};e.removeSensor=function(t){var e=t.element.getAttribute(a.SizeSensorId);t.element.removeAttribute(a.SizeSensorId),t.destroy(),e&&s[e]&&delete s[e]}},QBsz:
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/vector.js ***!
|
|
|
\*************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r="undefined"==typeof Float32Array?Array:Float32Array;function n(t){return Math.sqrt(o(t))}var i=n;function o(t){return t[0]*t[0]+t[1]*t[1]}var a=o;function s(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}var A=s;function l(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}var c=l;e.create=function(t,e){var n=new r(2);return null==t&&(t=0),null==e&&(e=0),n[0]=t,n[1]=e,n},e.copy=function(t,e){return t[0]=e[0],t[1]=e[1],t},e.clone=function(t){var e=new r(2);return e[0]=t[0],e[1]=t[1],e},e.set=function(t,e,r){return t[0]=e,t[1]=r,t},e.add=function(t,e,r){return t[0]=e[0]+r[0],t[1]=e[1]+r[1],t},e.scaleAndAdd=function(t,e,r,n){return t[0]=e[0]+r[0]*n,t[1]=e[1]+r[1]*n,t},e.sub=function(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t},e.len=n,e.length=i,e.lenSquare=o,e.lengthSquare=a,e.mul=function(t,e,r){return t[0]=e[0]*r[0],t[1]=e[1]*r[1],t},e.div=function(t,e,r){return t[0]=e[0]/r[0],t[1]=e[1]/r[1],t},e.dot=function(t,e){return t[0]*e[0]+t[1]*e[1]},e.scale=function(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t},e.normalize=function(t,e){var r=n(e);return 0===r?(t[0]=0,t[1]=0):(t[0]=e[0]/r,t[1]=e[1]/r),t},e.distance=s,e.dist=A,e.distanceSquare=l,e.distSquare=c,e.negate=function(t,e){return t[0]=-e[0],t[1]=-e[1],t},e.lerp=function(t,e,r,n){return t[0]=e[0]+n*(r[0]-e[0]),t[1]=e[1]+n*(r[1]-e[1]),t},e.applyTransform=function(t,e,r){var n=e[0],i=e[1];return t[0]=r[0]*n+r[2]*i+r[4],t[1]=r[1]*n+r[3]*i+r[5],t},e.min=function(t,e,r){return t[0]=Math.min(e[0],r[0]),t[1]=Math.min(e[1],r[1]),t},e.max=function(t,e,r){return t[0]=Math.max(e[0],r[0]),t[1]=Math.max(e[1],r[1]),t}},"QO+J":
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/size-sensor/lib/sensors/object.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createSensor=void 0;var n,i=(n=r(/*! ../debounce */"NohK"))&&n.__esModule?n:{default:n},o=r(/*! ../constant */"24YM");e.createSensor=function(t){var e=void 0,r=[],n=(0,i.default)((function(){r.forEach((function(e){e(t)}))})),a=function(){e&&e.parentNode&&(e.contentDocument&&e.contentDocument.defaultView.removeEventListener("resize",n),e.parentNode.removeChild(e),e=void 0,r=[])};return{element:t,bind:function(i){e||(e=function(){"static"===getComputedStyle(t).position&&(t.style.position="relative");var e=document.createElement("object");return e.onload=function(){e.contentDocument.defaultView.addEventListener("resize",n),n()},e.style.display="block",e.style.position="absolute",e.style.top="0",e.style.left="0",e.style.height="100%",e.style.width="100%",e.style.overflow="hidden",e.style.pointerEvents="none",e.style.zIndex="-1",e.style.opacity="0",e.setAttribute("class",o.SensorClassName),e.setAttribute("tabindex",o.SensorTabIndex),e.type="text/html",t.appendChild(e),e.data="about:blank",e}()),-1===r.indexOf(i)&&r.push(i)},destroy:a,unbind:function(t){var n=r.indexOf(t);-1!==n&&r.splice(n,1),0===r.length&&e&&a()}}}},Qe9p:
|
|
|
/*!************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/tool/color.js ***!
|
|
|
\************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/LRU */"1RvN"),i={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function o(t){return(t=Math.round(t))<0?0:t>255?255:t}function a(t){return t<0?0:t>1?1:t}function s(t){return t.length&&"%"===t.charAt(t.length-1)?o(parseFloat(t)/100*255):o(parseInt(t,10))}function A(t){return t.length&&"%"===t.charAt(t.length-1)?a(parseFloat(t)/100):a(parseFloat(t))}function l(t,e,r){return r<0?r+=1:r>1&&(r-=1),6*r<1?t+(e-t)*r*6:2*r<1?e:3*r<2?t+(e-t)*(2/3-r)*6:t}function c(t,e,r){return t+(e-t)*r}function u(t,e,r,n,i){return t[0]=e,t[1]=r,t[2]=n,t[3]=i,t}function h(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var d=new n(20),f=null;function p(t,e){f&&h(f,e),f=d.put(t,f||e.slice())}function g(t,e){if(t){e=e||[];var r=d.get(t);if(r)return h(e,r);var n,o=(t+="").replace(/ /g,"").toLowerCase();if(o in i)return h(e,i[o]),p(t,e),e;if("#"===o.charAt(0))return 4===o.length?(n=parseInt(o.substr(1),16))>=0&&n<=4095?(u(e,(3840&n)>>4|(3840&n)>>8,240&n|(240&n)>>4,15&n|(15&n)<<4,1),p(t,e),e):void u(e,0,0,0,1):7===o.length?(n=parseInt(o.substr(1),16))>=0&&n<=16777215?(u(e,(16711680&n)>>16,(65280&n)>>8,255&n,1),p(t,e),e):void u(e,0,0,0,1):void 0;var a=o.indexOf("("),l=o.indexOf(")");if(-1!==a&&l+1===o.length){var c=o.substr(0,a),f=o.substr(a+1,l-(a+1)).split(","),g=1;switch(c){case"rgba":if(4!==f.length)return void u(e,0,0,0,1);g=A(f.pop());case"rgb":return 3!==f.length?void u(e,0,0,0,1):(u(e,s(f[0]),s(f[1]),s(f[2]),g),p(t,e),e);case"hsla":return 4!==f.length?void u(e,0,0,0,1):(f[3]=A(f[3]),m(f,e),p(t,e),e);case"hsl":return 3!==f.length?void u(e,0,0,0,1):(m(f,e),p(t,e),e);default:return}}u(e,0,0,0,1)}}function m(t,e){var r=(parseFloat(t[0])%360+360)%360/360,n=A(t[1]),i=A(t[2]),a=i<=.5?i*(n+1):i+n-i*n,s=2*i-a;return u(e=e||[],o(255*l(s,a,r+1/3)),o(255*l(s,a,r)),o(255*l(s,a,r-1/3)),1),4===t.length&&(e[3]=t[3]),e}function v(t,e,r){if(e&&e.length&&t>=0&&t<=1){r=r||[];var n=t*(e.length-1),i=Math.floor(n),s=Math.ceil(n),A=e[i],l=e[s],u=n-i;return r[0]=o(c(A[0],l[0],u)),r[1]=o(c(A[1],l[1],u)),r[2]=o(c(A[2],l[2],u)),r[3]=a(c(A[3],l[3],u)),r}}var y=v;function w(t,e,r){if(e&&e.length&&t>=0&&t<=1){var n=t*(e.length-1),i=Math.floor(n),s=Math.ceil(n),A=g(e[i]),l=g(e[s]),u=n-i,h=C([o(c(A[0],l[0],u)),o(c(A[1],l[1],u)),o(c(A[2],l[2],u)),a(c(A[3],l[3],u))],"rgba");return r?{color:h,leftIndex:i,rightIndex:s,value:n}:h}}var b=w;function C(t,e){if(t&&t.length){var r=t[0]+","+t[1]+","+t[2];return"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(r+=","+t[3]),e+"("+r+")"}}e.parse=g,e.lift=function(t,e){var r=g(t);if(r){for(var n=0;n<3;n++)r[n]=e<0?r[n]*(1-e)|0:(255-r[n])*e+r[n]|0,r[n]>255?r[n]=255:t[n]<0&&(r[n]=0);return C(r,4===r.length?"rgba":"rgb")}},e.toHex=function(t){var e=g(t);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)},e.fastLerp=v,e.fastMapToColor=y,e.lerp=w,e.mapToColor=b,e.modifyHSL=function(t,e,r,n){if(t=g(t))return t=function(t){if(t){var e,r,n=t[0]/255,i=t[1]/255,o=t[2]/255,a=Math.min(n,i,o),s=Math.max(n,i,o),A=s-a,l=(s+a)/2;if(0===A)e=0,r=0;else{r=l<.5?A/(s+a):A/(2-s-a);var c=((s-n)/6+A/2)/A,u=((s-i)/6+A/2)/A,h=((s-o)/6+A/2)/A;n===s?e=h-u:i===s?e=1/3+c-h:o===s&&(e=2/3+u-c),e<0&&(e+=1),e>1&&(e-=1)}var d=[360*e,r,l];return null!=t[3]&&d.push(t[3]),d}}(t),null!=e&&(t[0]=(i=e,(i=Math.round(i))<0?0:i>360?360:i)),null!=r&&(t[1]=A(r)),null!=n&&(t[2]=A(n)),C(m(t),"rgba");var i},e.modifyAlpha=function(t,e){if((t=g(t))&&null!=e)return t[3]=a(e),C(t,"rgba")},e.stringify=C},QuXc:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/Gradient.js ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=function(t){this.colorStops=t||[]};r.prototype={constructor:r,addColorStop:function(t,e){this.colorStops.push({offset:t,color:e})}};var n=r;t.exports=n},RDYZ:
|
|
|
/*!****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/animation/Clip.js ***!
|
|
|
\****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./easing */"dMvE");function i(t){this._target=t.target,this._life=t.life||1e3,this._delay=t.delay||0,this._initialized=!1,this.loop=null!=t.loop&&t.loop,this.gap=t.gap||0,this.easing=t.easing||"Linear",this.onframe=t.onframe,this.ondestroy=t.ondestroy,this.onrestart=t.onrestart,this._pausedTime=0,this._paused=!1}i.prototype={constructor:i,step:function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),this._paused)this._pausedTime+=e;else{var r=(t-this._startTime-this._pausedTime)/this._life;if(!(r<0)){r=Math.min(r,1);var i=this.easing,o="string"==typeof i?n[i]:i,a="function"==typeof o?o(r):r;return this.fire("frame",a),1===r?this.loop?(this.restart(t),"restart"):(this._needsRemove=!0,"destroy"):null}}},restart:function(t){var e=(t-this._startTime-this._pausedTime)%this._life;this._startTime=t-e+this.gap,this._pausedTime=0,this._needsRemove=!1},fire:function(t,e){this[t="on"+t]&&this[t](this._target,e)},pause:function(){this._paused=!0},resume:function(){this._paused=!1}};var o=i;t.exports=o},RXMa:
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Ring.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt").extend({type:"ring",shape:{cx:0,cy:0,r:0,r0:0},buildPath:function(t,e){var r=e.cx,n=e.cy,i=2*Math.PI;t.moveTo(r+e.r,n),t.arc(r,n,e.r,0,i,!1),t.moveTo(r+e.r0,n),t.arc(r,n,e.r0,0,i,!0)}});t.exports=n},"SA+Z":
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/@babel/runtime/helpers/toArray.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./arrayWithHoles.js */"wTVA"),i=r(/*! ./iterableToArray.js */"EbDI"),o=r(/*! ./unsupportedIterableToArray.js */"ZhPi"),a=r(/*! ./nonIterableRest.js */"wkBT");t.exports=function(t){return n(t)||i(t)||o(t)||a()},t.exports.__esModule=!0,t.exports.default=t.exports},SJMd:
|
|
|
/*!****************************************************!*\
|
|
|
!*** ./node_modules/code-prettify/src/prettify.js ***!
|
|
|
\****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){window.PR_SHOULD_USE_CONTINUATION=!0,function(){var t=window,e=["break,continue,do,else,for,if,return,while"],r=[[e,"auto,case,char,const,default,double,enum,extern,float,goto,inline,int,long,register,restrict,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],n=[r,"alignas,alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,delegate,dynamic_cast,explicit,export,friend,generic,late_check,mutable,namespace,noexcept,noreturn,nullptr,property,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],i=[r,"abstract,assert,boolean,byte,extends,finally,final,implements,import,instanceof,interface,null,native,package,strictfp,super,synchronized,throws,transient"],o=[r,"abstract,add,alias,as,ascending,async,await,base,bool,by,byte,checked,decimal,delegate,descending,dynamic,event,finally,fixed,foreach,from,get,global,group,implicit,in,interface,internal,into,is,join,let,lock,null,object,out,override,orderby,params,partial,readonly,ref,remove,sbyte,sealed,select,set,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,value,var,virtual,where,yield"],a=[r,"abstract,async,await,constructor,debugger,enum,eval,export,function,get,implements,instanceof,interface,let,null,set,undefined,var,with,yield,Infinity,NaN"],s="caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",A=[e,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],l=[e,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],c=[e,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],u=/^(DIR|FILE|array|vector|(de|priority_)?queue|(forward_)?list|stack|(const_)?(reverse_)?iterator|(unordered_)?(multi)?(set|map)|bitset|u?(int|float)\d*)\b/;function h(t,e,r,n,i){if(r){var o={sourceNode:t,pre:1,langExtension:null,numberLines:null,sourceCode:r,spans:null,basePos:e,decorations:null};n(o),i.push.apply(i,o.decorations)}}var d=/\S/;function f(t){for(var e=void 0,r=t.firstChild;r;r=r.nextSibling){var n=r.nodeType;e=1===n?e?t:r:3===n&&d.test(r.nodeValue)?t:e}return e===t?void 0:e}function p(t,e){var r,n={};!function(){for(var i=t.concat(e),o=[],a={},s=0,A=i.length;s<A;++s){var l=i[s],c=l[3];if(c)for(var u=c.length;--u>=0;)n[c.charAt(u)]=l;var h=l[1],d=""+h;a.hasOwnProperty(d)||(o.push(h),a[d]=null)}o.push(/[\0-\uffff]/),r=function(t){for(var e=0,r=!1,n=!1,i=0,o=t.length;i<o;++i){if((h=t[i]).ignoreCase)n=!0;else if(/[a-z]/i.test(h.source.replace(/\\u[0-9a-f]{4}|\\x[0-9a-f]{2}|\\[^ux]/gi,""))){r=!0,n=!1;break}}var a={b:8,t:9,n:10,v:11,f:12,r:13};function s(t){var e=t.charCodeAt(0);if(92!==e)return e;var r=t.charAt(1);return(e=a[r])||("0"<=r&&r<="7"?parseInt(t.substring(1),8):"u"===r||"x"===r?parseInt(t.substring(2),16):t.charCodeAt(1))}function A(t){if(t<32)return(t<16?"\\x0":"\\x")+t.toString(16);var e=String.fromCharCode(t);return"\\"===e||"-"===e||"]"===e||"^"===e?"\\"+e:e}function l(t){var e=t.substring(1,t.length-1).match(new RegExp("\\\\u[0-9A-Fa-f]{4}|\\\\x[0-9A-Fa-f]{2}|\\\\[0-3][0-7]{0,2}|\\\\[0-7]{1,2}|\\\\[\\s\\S]|-|[^-\\\\]","g")),r=[],n="^"===e[0],i=["["];n&&i.push("^");for(var o=n?1:0,a=e.length;o<a;++o){var l=e[o];if(/\\[bdsw]/i.test(l))i.push(l);else{var c,u=s(l);o+2<a&&"-"===e[o+1]?(c=s(e[o+2]),o+=2):c=u,r.push([u,c]),c<65||u>122||(c<65||u>90||r.push([32|Math.max(65,u),32|Math.min(c,90)]),c<97||u>122||r.push([-33&Math.max(97,u),-33&Math.min(c,122)]))}}r.sort((function(t,e){return t[0]-e[0]||e[1]-t[1]}));var h=[],d=[];for(o=0;o<r.length;++o){(f=r[o])[0]<=d[1]+1?d[1]=Math.max(d[1],f[1]):h.push(d=f)}for(o=0;o<h.length;++o){var f=h[o];i.push(A(f[0])),f[1]>f[0]&&(f[1]+1>f[0]&&i.push("-"),i.push(A(f[1])))}return i.push("]"),i.join("")}function c(t){for(var n=t.source.match(new RegExp("(?:\\[(?:[^\\x5C\\x5D]|\\\\[\\s\\S])*\\]|\\\\u[A-Fa-f0-9]{4}|\\\\x[A-Fa-f0-9]{2}|\\\\[0-9]+|\\\\[^ux0-9]|\\(\\?[:!=]|[\\(\\)\\^]|[^\\x5B\\x5C\\(\\)\\^]+)","g")),i=n.length,o=[],a=0,s=0;a<i;++a){if("("===(u=n[a]))++s;else if("\\"===u.charAt(0)){(c=+u.substring(1))&&(c<=s?o[c]=-1:n[a]=A(c))}}for(a=1;a<o.length;++a)-1===o[a]&&(o[a]=++e);for(a=0,s=0;a<i;++a){if("("===(u=n[a]))o[++s]||(n[a]="(?:");else if("\\"===u.charAt(0)){var c;(c=+u.substring(1))&&c<=s&&(n[a]="\\"+o[c])}}for(a=0;a<i;++a)"^"===n[a]&&"^"!==n[a+1]&&(n[a]="");if(t.ignoreCase&&r)for(a=0;a<i;++a){var u,h=(u=n[a]).charAt(0);u.length>=2&&"["===h?n[a]=l(u):"\\"!==h&&(n[a]=u.replace(/[a-zA-Z]/g,(function(t){var e=t.charCodeAt(0);return"["+String.fromCharCode(-33&e,32|e)+"]"})))}return n.join("")}var u=[];for(i=0,o=t.length;i<o;++i){var h;if((h=t[i]).global||h.multiline)throw new Error(""+h);u.push("(?:"+c(h)+")")}return new RegExp(u.join("|"),n?"gi":"g")}(o)}();var i=e.length,o=function(t){for(var a=t.sourceCode,s=t.basePos,A=t.sourceNode,l=[s,"pln"],c=0,u=a.match(r)||[],d={},f=0,p=u.length;f<p;++f){var g,m=u[f],v=d[m],y=void 0;if("string"==typeof v)g=!1;else{var w=n[m.charAt(0)];if(w)y=m.match(w[1]),v=w[0];else{for(var C=0;C<i;++C)if(w=e[C],y=m.match(w[1])){v=w[0];break}y||(v="pln")}!(g=v.length>=5&&"lang-"===v.substring(0,5))||y&&"string"==typeof y[1]||(g=!1,v="src"),g||(d[m]=v)}var B=c;if(c+=m.length,g){var x=y[1],E=m.indexOf(x),S=E+x.length;y[2]&&(E=(S=m.length-y[2].length)-x.length);var k=v.substring(5);h(A,s+B,m.substring(0,E),o,l),h(A,s+B+E,x,b(k,x),l),h(A,s+B+S,m.substring(S),o,l)}else l.push(s+B,v)}t.decorations=l};return o}function g(t){var e=[],r=[];t.tripleQuotedStrings?e.push(["str",/^(?:\'\'\'(?:[^\'\\]|\\[\s\S]|\'{1,2}(?=[^\']))*(?:\'\'\'|$)|\"\"\"(?:[^\"\\]|\\[\s\S]|\"{1,2}(?=[^\"]))*(?:\"\"\"|$)|\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$))/,null,"'\""]):t.multiLineStrings?e.push(["str",/^(?:\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$)|\`(?:[^\\\`]|\\[\s\S])*(?:\`|$))/,null,"'\"`"]):e.push(["str",/^(?:\'(?:[^\\\'\r\n]|\\.)*(?:\'|$)|\"(?:[^\\\"\r\n]|\\.)*(?:\"|$))/,null,"\"'"]),t.verbatimStrings&&r.push(["str",/^@\"(?:[^\"]|\"\")*(?:\"|$)/,null]);var n=t.hashComments;n&&(t.cStyleComments?(n>1?e.push(["com",/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,null,"#"]):e.push(["com",/^#(?:(?:define|e(?:l|nd)if|else|error|ifn?def|include|line|pragma|undef|warning)\b|[^\r\n]*)/,null,"#"]),r.push(["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h(?:h|pp|\+\+)?|[a-z]\w*)>/,null])):e.push(["com",/^#[^\r\n]*/,null,"#"])),t.cStyleComments&&(r.push(["com",/^\/\/[^\r\n]*/,null]),r.push(["com",/^\/\*[\s\S]*?(?:\*\/|$)/,null]));var i=t.regexLiterals;if(i){var o=i>1?"":"\n\r",a=o?".":"[\\S\\s]",s="/(?=[^/*"+o+"])(?:[^/\\x5B\\x5C"+o+"]|\\x5C"+a+"|\\x5B(?:[^\\x5C\\x5D"+o+"]|\\x5C"+a+")*(?:\\x5D|$))+/";r.push(["lang-regex",RegExp("^(?:^^\\.?|[+-]|[!=]=?=?|\\#|%=?|&&?=?|\\(|\\*=?|[+\\-]=|->|\\/=?|::?|<<?=?|>>?>?=?|,|;|\\?|@|\\[|~|{|\\^\\^?=?|\\|\\|?=?|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*("+s+")")])}var A=t.types;A&&r.push(["typ",A]);var l=(""+t.keywords).replace(/^ | $/g,"");l.length&&r.push(["kwd",new RegExp("^(?:"+l.replace(/[\s,]+/g,"|")+")\\b"),null]),e.push(["pln",/^\s+/,null," \r\n\t "]);var c="^.[^\\s\\w.$@'\"`/\\\\]*";return t.regexLiterals&&(c+="(?!s*/)"),r.push(["lit",/^@[a-z_$][a-z_$@0-9]*/i,null],["typ",/^(?:[@_]?[A-Z]+[a-z][A-Za-z_$@0-9]*|\w+_t\b)/,null],["pln",/^[a-z_$][a-z_$@0-9]*/i,null],["lit",new RegExp("^(?:0x[a-f0-9]+|(?:\\d(?:_\\d+)*\\d*(?:\\.\\d*)?|\\.\\d\\+)(?:e[+\\-]?\\d+)?)[a-z]*","i"),null,"0123456789"],["pln",/^\\[\s\S]?/,null],["pun",new RegExp(c),null]),p(e,r)}var m=g({keywords:[n,o,i,a,s,A,l,c],hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0});function v(t,e,r){for(var n=/(?:^|\s)nocode(?:\s|$)/,i=/\r\n?|\n/,o=t.ownerDocument,a=o.createElement("li");t.firstChild;)a.appendChild(t.firstChild);var s=[a];function A(t){var e=t.nodeType;if(1!=e||n.test(t.className)){if((3==e||4==e)&&r){var a=t.nodeValue,s=a.match(i);if(s){var c=a.substring(0,s.index);t.nodeValue=c;var u=a.substring(s.index+s[0].length);if(u)t.parentNode.insertBefore(o.createTextNode(u),t.nextSibling);l(t),c||t.parentNode.removeChild(t)}}}else if("br"===t.nodeName)l(t),t.parentNode&&t.parentNode.removeChild(t);else for(var h=t.firstChild;h;h=h.nextSibling)A(h)}function l(t){for(;!t.nextSibling;)if(!(t=t.parentNode))return;for(var e,r=function t(e,r){var n=r?e.cloneNode(!1):e,i=e.parentNode;if(i){var o=t(i,1),a=e.nextSibling;o.appendChild(n);for(var s=a;s;s=a)a=s.nextSibling,o.appendChild(s)}return n}(t.nextSibling,0);(e=r.parentNode)&&1===e.nodeType;)r=e;s.push(r)}for(var c=0;c<s.length;++c)A(s[c]);e===(0|e)&&s[0].setAttribute("value",e);var u=o.createElement("ol");u.className="linenums";for(var h=Math.max(0,e-1|0)||0,d=(c=0,s.length);c<d;++c)(a=s[c]).className="L"+(c+h)%10,a.firstChild||a.appendChild(o.createTextNode(" ")),u.appendChild(a);t.appendChild(u)}var y={};function w(e,r){for(var n=r.length;--n>=0;){var i=r[n];y.hasOwnProperty(i)?t.console&&console.warn("cannot override language handler %s",i):y[i]=e}}function b(t,e){return t&&y.hasOwnProperty(t)||(t=/^\s*</.test(e)?"default-markup":"default-code"),y[t]}function C(e){var r,n,i,o,a,s,A,l=e.langExtension;try{var c=(r=e.sourceNode,n=e.pre,i=/(?:^|\s)nocode(?:\s|$)/,o=[],a=0,s=[],A=0,function t(e){var r=e.nodeType;if(1==r){if(i.test(e.className))return;for(var l=e.firstChild;l;l=l.nextSibling)t(l);var c=e.nodeName.toLowerCase();"br"!==c&&"li"!==c||(o[A]="\n",s[A<<1]=a++,s[A++<<1|1]=e)}else if(3==r||4==r){var u=e.nodeValue;u.length&&(u=n?u.replace(/\r\n?/g,"\n"):u.replace(/[ \t\r\n]+/g," "),o[A]=u,s[A<<1]=a,a+=u.length,s[A++<<1|1]=e)}}(r),{sourceCode:o.join("").replace(/\n$/,""),spans:s}),u=c.sourceCode;e.sourceCode=u,e.spans=c.spans,e.basePos=0,b(l,u)(e),function(t){var e=/\bMSIE\s(\d+)/.exec(navigator.userAgent);e=e&&+e[1]<=8;var r,n,i=/\n/g,o=t.sourceCode,a=o.length,s=0,A=t.spans,l=A.length,c=0,u=t.decorations,h=u.length,d=0;for(u[h]=a,n=r=0;n<h;)u[n]!==u[n+2]?(u[r++]=u[n++],u[r++]=u[n++]):n+=2;for(h=r,n=r=0;n<h;){for(var f=u[n],p=u[n+1],g=n+2;g+2<=h&&u[g+1]===p;)g+=2;u[r++]=f,u[r++]=p,n=g}h=u.length=r;var m=t.sourceNode,v="";m&&(v=m.style.display,m.style.display="none");try{for(;c<l;){A[c];var y,w=A[c+2]||a,b=u[d+2]||a,C=(g=Math.min(w,b),A[c+1]);if(1!==C.nodeType&&(y=o.substring(s,g))){e&&(y=y.replace(i,"\r")),C.nodeValue=y;var B=C.ownerDocument,x=B.createElement("span");x.className=u[d+1];var E=C.parentNode;E.replaceChild(x,C),x.appendChild(C),s<w&&(A[c+1]=C=B.createTextNode(o.substring(g,w)),E.insertBefore(C,x.nextSibling))}(s=g)>=w&&(c+=2),s>=b&&(d+=2)}}finally{m&&(m.style.display=v)}}(e)}catch(e){t.console&&console.log(e&&e.stack||e)}}function B(t,e,r){var n=r||!1,i=e||null,o=document.createElement("div");return o.innerHTML="<pre>"+t+"</pre>",o=o.firstChild,n&&v(o,n,!0),C({langExtension:i,numberLines:n,sourceNode:o,pre:1,sourceCode:null,basePos:null,spans:null,decorations:null}),o.innerHTML}function x(e,r){var n=r||document.body,i=n.ownerDocument||document;function o(t){return n.getElementsByTagName(t)}for(var a=[o("pre"),o("code"),o("xmp")],s=[],A=0;A<a.length;++A)for(var l=0,c=a[A].length;l<c;++l)s.push(a[A][l]);a=null;var u=Date;u.now||(u={now:function(){return+new Date}});var h=0,d=/\blang(?:uage)?-([\w.]+)(?!\S)/,p=/\bprettyprint\b/,g=/\bprettyprinted\b/,m=/pre|xmp/i,y=/^code$/i,w=/^(?:pre|code|xmp)$/i,b={};!function r(){for(var n=t.PR_SHOULD_USE_CONTINUATION?u.now()+250:1/0;h<s.length&&u.now()<n;h++){for(var o=s[h],a=b,A=o;A=A.previousSibling;){var l=A.nodeType,c=(7===l||8===l)&&A.nodeValue;if(c?!/^\??prettify\b/.test(c):3!==l||/\S/.test(A.nodeValue))break;if(c){a={},c.replace(/\b(\w+)=([\w:.%+-]+)/g,(function(t,e,r){a[e]=r}));break}}var B=o.className;if((a!==b||p.test(B))&&!g.test(B)){for(var x=!1,E=o.parentNode;E;E=E.parentNode){var S=E.tagName;if(w.test(S)&&E.className&&p.test(E.className)){x=!0;break}}if(!x){o.className+=" prettyprinted";var k,T,F=a.lang;if(!F)!(F=B.match(d))&&(k=f(o))&&y.test(k.tagName)&&(F=k.className.match(d)),F&&(F=F[1]);if(m.test(o.tagName))T=1;else{var L=o.currentStyle,I=i.defaultView,_=L?L.whiteSpace:I&&I.getComputedStyle?I.getComputedStyle(o,null).getPropertyValue("white-space"):0;T=_&&"pre"===_.substring(0,3)}var U=a.linenums;(U="true"===U||+U)||(U=!!(U=B.match(/\blinenums\b(?::(\d+))?/))&&(!U[1]||!U[1].length||+U[1])),U&&v(o,U,T),C({langExtension:F,sourceNode:o,numberLines:U,pre:T,sourceCode:null,basePos:null,spans:null,decorations:null})}}}h<s.length?t.setTimeout(r,250):"function"==typeof e&&e()}()}w(m,["default-code"]),w(p([],[["pln",/^[^<?]+/],["dec",/^<!\w[^>]*(?:>|$)/],["com",/^<\!--[\s\S]*?(?:-\->|$)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],["pun",/^(?:<[%?]|[%?]>)/],["lang-",/^<xmp\b[^>]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-js",/^<script\b[^>]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^<style\b[^>]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]),w(p([["pln",/^[\s]+/,null," \t\r\n"],["atv",/^(?:\"[^\"]*\"?|\'[^\']*\'?)/,null,"\"'"]],[["tag",/^^<\/?[a-z](?:[\w.:-]*\w)?|\/?>$/i],["atn",/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^>\'\"\s]*(?:[^>\'\"\s\/]|\/(?=\s)))/],["pun",/^[=<>\/]+/],["lang-js",/^on\w+\s*=\s*\"([^\"]+)\"/i],["lang-js",/^on\w+\s*=\s*\'([^\']+)\'/i],["lang-js",/^on\w+\s*=\s*([^\"\'>\s]+)/i],["lang-css",/^style\s*=\s*\"([^\"]+)\"/i],["lang-css",/^style\s*=\s*\'([^\']+)\'/i],["lang-css",/^style\s*=\s*([^\"\'>\s]+)/i]]),["in.tag"]),w(p([],[["atv",/^[\s\S]+/]]),["uq.val"]),w(g({keywords:n,hashComments:!0,cStyleComments:!0,types:u}),["c","cc","cpp","cxx","cyc","m"]),w(g({keywords:"null,true,false"}),["json"]),w(g({keywords:o,hashComments:!0,cStyleComments:!0,verbatimStrings:!0,types:u}),["cs"]),w(g({keywords:i,cStyleComments:!0}),["java"]),w(g({keywords:c,hashComments:!0,multiLineStrings:!0}),["bash","bsh","csh","sh"]),w(g({keywords:A,hashComments:!0,multiLineStrings:!0,tripleQuotedStrings:!0}),["cv","py","python"]),w(g({keywords:s,hashComments:!0,multiLineStrings:!0,regexLiterals:2}),["perl","pl","pm"]),w(g({keywords:l,hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["rb","ruby"]),w(g({keywords:a,cStyleComments:!0,regexLiterals:!0}),["javascript","js","ts","typescript"]),w(g({keywords:"all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,throw,true,try,unless,until,when,while,yes",hashComments:3,cStyleComments:!0,multilineStrings:!0,tripleQuotedStrings:!0,regexLiterals:!0}),["coffee"]),w(p([],[["str",/^[\s\S]+/]]),["regex"]);var E=t.PR={createSimpleLexer:p,registerLangHandler:w,sourceDecorator:g,PR_ATTRIB_NAME:"atn",PR_ATTRIB_VALUE:"atv",PR_COMMENT:"com",PR_DECLARATION:"dec",PR_KEYWORD:"kwd",PR_LITERAL:"lit",PR_NOCODE:"nocode",PR_PLAIN:"pln",PR_PUNCTUATION:"pun",PR_SOURCE:"src",PR_STRING:"str",PR_TAG:"tag",PR_TYPE:"typ",prettyPrintOne:B,prettyPrint:x},S=t.define;"function"==typeof S&&S.amd&&S("google-code-prettify",[],(function(){return E}))}()},SKnc:
|
|
|
/*!************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/LinearGradient.js ***!
|
|
|
\************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/util */"bYtY"),i=r(/*! ./Gradient */"QuXc"),o=function(t,e,r,n,o,a){this.x=null==t?0:t,this.y=null==e?0:e,this.x2=null==r?1:r,this.y2=null==n?0:n,this.type="linear",this.global=a||!1,i.call(this,o)};o.prototype={constructor:o},n.inherits(o,i);var a=o;t.exports=a},SUKs:
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/log.js ***!
|
|
|
\**********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=function(){};1===r(/*! ../config */"LPTA").debugMode&&(n=console.error);var i=n;t.exports=i},Sj9i:
|
|
|
/*!************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/curve.js ***!
|
|
|
\************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./vector */"QBsz"),i=n.create,o=n.distSquare,a=Math.pow,s=Math.sqrt,A=s(3),l=i(),c=i(),u=i();function h(t){return t>-1e-8&&t<1e-8}function d(t){return t>1e-8||t<-1e-8}function f(t,e,r,n,i){var o=1-i;return o*o*(o*t+3*i*e)+i*i*(i*n+3*o*r)}function p(t,e,r,n){var i=1-n;return i*(i*t+2*n*e)+n*n*r}e.cubicAt=f,e.cubicDerivativeAt=function(t,e,r,n,i){var o=1-i;return 3*(((e-t)*o+2*(r-e)*i)*o+(n-r)*i*i)},e.cubicRootAt=function(t,e,r,n,i,o){var l=n+3*(e-r)-t,c=3*(r-2*e+t),u=3*(e-t),d=t-i,f=c*c-3*l*u,p=c*u-9*l*d,g=u*u-3*c*d,m=0;if(h(f)&&h(p)){if(h(c))o[0]=0;else(T=-u/c)>=0&&T<=1&&(o[m++]=T)}else{var v=p*p-4*f*g;if(h(v)){var y=p/f,w=-y/2;(T=-c/l+y)>=0&&T<=1&&(o[m++]=T),w>=0&&w<=1&&(o[m++]=w)}else if(v>0){var b=s(v),C=f*c+1.5*l*(-p+b),B=f*c+1.5*l*(-p-b);(T=(-c-((C=C<0?-a(-C,1/3):a(C,1/3))+(B=B<0?-a(-B,1/3):a(B,1/3))))/(3*l))>=0&&T<=1&&(o[m++]=T)}else{var x=(2*f*c-3*l*p)/(2*s(f*f*f)),E=Math.acos(x)/3,S=s(f),k=Math.cos(E),T=(-c-2*S*k)/(3*l),F=(w=(-c+S*(k+A*Math.sin(E)))/(3*l),(-c+S*(k-A*Math.sin(E)))/(3*l));T>=0&&T<=1&&(o[m++]=T),w>=0&&w<=1&&(o[m++]=w),F>=0&&F<=1&&(o[m++]=F)}}return m},e.cubicExtrema=function(t,e,r,n,i){var o=6*r-12*e+6*t,a=9*e+3*n-3*t-9*r,A=3*e-3*t,l=0;if(h(a)){if(d(o))(u=-A/o)>=0&&u<=1&&(i[l++]=u)}else{var c=o*o-4*a*A;if(h(c))i[0]=-o/(2*a);else if(c>0){var u,f=s(c),p=(-o-f)/(2*a);(u=(-o+f)/(2*a))>=0&&u<=1&&(i[l++]=u),p>=0&&p<=1&&(i[l++]=p)}}return l},e.cubicSubdivide=function(t,e,r,n,i,o){var a=(e-t)*i+t,s=(r-e)*i+e,A=(n-r)*i+r,l=(s-a)*i+a,c=(A-s)*i+s,u=(c-l)*i+l;o[0]=t,o[1]=a,o[2]=l,o[3]=u,o[4]=u,o[5]=c,o[6]=A,o[7]=n},e.cubicProjectPoint=function(t,e,r,n,i,a,A,h,d,p,g){var m,v,y,w,b,C=.005,B=1/0;l[0]=d,l[1]=p;for(var x=0;x<1;x+=.05)c[0]=f(t,r,i,A,x),c[1]=f(e,n,a,h,x),(w=o(l,c))<B&&(m=x,B=w);B=1/0;for(var E=0;E<32&&!(C<1e-4);E++)v=m-C,y=m+C,c[0]=f(t,r,i,A,v),c[1]=f(e,n,a,h,v),w=o(c,l),v>=0&&w<B?(m=v,B=w):(u[0]=f(t,r,i,A,y),u[1]=f(e,n,a,h,y),b=o(u,l),y<=1&&b<B?(m=y,B=b):C*=.5);return g&&(g[0]=f(t,r,i,A,m),g[1]=f(e,n,a,h,m)),s(B)},e.quadraticAt=p,e.quadraticDerivativeAt=function(t,e,r,n){return 2*((1-n)*(e-t)+n*(r-e))},e.quadraticRootAt=function(t,e,r,n,i){var o=t-2*e+r,a=2*(e-t),A=t-n,l=0;if(h(o)){if(d(a))(u=-A/a)>=0&&u<=1&&(i[l++]=u)}else{var c=a*a-4*o*A;if(h(c))(u=-a/(2*o))>=0&&u<=1&&(i[l++]=u);else if(c>0){var u,f=s(c),p=(-a-f)/(2*o);(u=(-a+f)/(2*o))>=0&&u<=1&&(i[l++]=u),p>=0&&p<=1&&(i[l++]=p)}}return l},e.quadraticExtremum=function(t,e,r){var n=t+r-2*e;return 0===n?.5:(t-e)/n},e.quadraticSubdivide=function(t,e,r,n,i){var o=(e-t)*n+t,a=(r-e)*n+e,s=(a-o)*n+o;i[0]=t,i[1]=o,i[2]=s,i[3]=s,i[4]=a,i[5]=r},e.quadraticProjectPoint=function(t,e,r,n,i,a,A,h,d){var f,g=.005,m=1/0;l[0]=A,l[1]=h;for(var v=0;v<1;v+=.05){c[0]=p(t,r,i,v),c[1]=p(e,n,a,v),(C=o(l,c))<m&&(f=v,m=C)}m=1/0;for(var y=0;y<32&&!(g<1e-4);y++){var w=f-g,b=f+g;c[0]=p(t,r,i,w),c[1]=p(e,n,a,w);var C=o(c,l);if(w>=0&&C<m)f=w,m=C;else{u[0]=p(t,r,i,b),u[1]=p(e,n,a,b);var B=o(u,l);b<=1&&B<m?(f=b,m=B):g*=.5}}return d&&(d[0]=p(t,r,i,f),d[1]=p(e,n,a,f)),s(m)}},SqI9:
|
|
|
/*!**********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Sector.js ***!
|
|
|
\**********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt"),i=r(/*! ../helper/fixClipWithShadow */"iXp4"),o=n.extend({type:"sector",shape:{cx:0,cy:0,r0:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},brush:i(n.prototype.brush),buildPath:function(t,e){var r=e.cx,n=e.cy,i=Math.max(e.r0||0,0),o=Math.max(e.r,0),a=e.startAngle,s=e.endAngle,A=e.clockwise,l=Math.cos(a),c=Math.sin(a);t.moveTo(l*i+r,c*i+n),t.lineTo(l*o+r,c*o+n),t.arc(r,n,o,a,s,!A),t.lineTo(Math.cos(s)*i+r,Math.sin(s)*i+n),0!==i&&t.arc(r,n,i,s,a,A),t.closePath()}});t.exports=o},SrGk:
|
|
|
/*!**********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/svg/helper/Definable.js ***!
|
|
|
\**********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core */"hydK").createElement,i=r(/*! ../../core/util */"bYtY"),o=r(/*! ../../graphic/Path */"y+Vt"),a=r(/*! ../../graphic/Image */"Dagg"),s=r(/*! ../../graphic/Text */"dqUG"),A=r(/*! ../graphic */"P47w"),l=A.path,c=A.image,u=A.text;function h(t,e,r,n,i){this._zrId=t,this._svgRoot=e,this._tagNames="string"==typeof r?[r]:r,this._markLabel=n,this._domName=i||"_dom",this.nextId=0}h.prototype.createElement=n,h.prototype.getDefs=function(t){var e=this._svgRoot,r=this._svgRoot.getElementsByTagName("defs");return 0===r.length?t?((r=e.insertBefore(this.createElement("defs"),e.firstChild)).contains||(r.contains=function(t){var e=r.children;if(!e)return!1;for(var n=e.length-1;n>=0;--n)if(e[n]===t)return!0;return!1}),r):null:r[0]},h.prototype.update=function(t,e){if(t){var r=this.getDefs(!1);if(t[this._domName]&&r.contains(t[this._domName]))"function"==typeof e&&e(t);else{var n=this.add(t);n&&(t[this._domName]=n)}}},h.prototype.addDom=function(t){this.getDefs(!0).appendChild(t)},h.prototype.removeDom=function(t){var e=this.getDefs(!1);e&&t[this._domName]&&(e.removeChild(t[this._domName]),t[this._domName]=null)},h.prototype.getDoms=function(){var t=this.getDefs(!1);if(!t)return[];var e=[];return i.each(this._tagNames,(function(r){var n=t.getElementsByTagName(r);e=e.concat([].slice.call(n))})),e},h.prototype.markAllUnused=function(){var t=this.getDoms(),e=this;i.each(t,(function(t){t[e._markLabel]="0"}))},h.prototype.markUsed=function(t){t&&(t[this._markLabel]="1")},h.prototype.removeUnused=function(){var t=this.getDefs(!1);if(t){var e=this.getDoms(),r=this;i.each(e,(function(e){"1"!==e[r._markLabel]&&t.removeChild(e)}))}},h.prototype.getSvgProxy=function(t){return t instanceof o?l:t instanceof a?c:t instanceof s?u:l},h.prototype.getTextSvgElement=function(t){return t.__textSvgEl},h.prototype.getSvgElement=function(t){return t.__svgEl};var d=h;t.exports=d},T6xi:
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/poly.js ***!
|
|
|
\*********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./smoothSpline */"YgsL"),i=r(/*! ./smoothBezier */"nCxF");e.buildPath=function(t,e,r){var o=e.points,a=e.smooth;if(o&&o.length>=2){if(a&&"spline"!==a){var s=i(o,a,r,e.smoothConstraint);t.moveTo(o[0][0],o[0][1]);for(var A=o.length,l=0;l<(r?A:A-1);l++){var c=s[2*l],u=s[2*l+1],h=o[(l+1)%A];t.bezierCurveTo(c[0],c[1],u[0],u[1],h[0],h[1])}}else{"spline"===a&&(o=n(o,r)),t.moveTo(o[0][0],o[0][1]);l=1;for(var d=o.length;l<d;l++)t.lineTo(o[l][0],o[l][1])}r&&t.closePath()}}},VpOo:
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/roundRect.js ***!
|
|
|
\**************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){e.buildPath=function(t,e){var r,n,i,o,a,s=e.x,A=e.y,l=e.width,c=e.height,u=e.r;l<0&&(s+=l,l=-l),c<0&&(A+=c,c=-c),"number"==typeof u?r=n=i=o=u:u instanceof Array?1===u.length?r=n=i=o=u[0]:2===u.length?(r=i=u[0],n=o=u[1]):3===u.length?(r=u[0],n=o=u[1],i=u[2]):(r=u[0],n=u[1],i=u[2],o=u[3]):r=n=i=o=0,r+n>l&&(r*=l/(a=r+n),n*=l/a),i+o>l&&(i*=l/(a=i+o),o*=l/a),n+i>c&&(n*=c/(a=n+i),i*=c/a),r+o>c&&(r*=c/(a=r+o),o*=c/a),t.moveTo(s+r,A),t.lineTo(s+l-n,A),0!==n&&t.arc(s+l-n,A+n,n,-Math.PI/2,0),t.lineTo(s+l,A+c-i),0!==i&&t.arc(s+l-i,A+c-i,i,0,Math.PI/2),t.lineTo(s+o,A+c),0!==o&&t.arc(s+o,A+c-o,o,Math.PI/2,Math.PI),t.lineTo(s,A+r),0!==r&&t.arc(s+r,A+r,r,Math.PI,1.5*Math.PI)}},"VrN/":
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./node_modules/codemirror/lib/codemirror.js ***!
|
|
|
\***************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){t.exports=function(){"use strict";var t=navigator.userAgent,e=navigator.platform,r=/gecko\/\d/i.test(t),n=/MSIE \d/.test(t),i=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(t),o=/Edge\/(\d+)/.exec(t),a=n||i||o,s=a&&(n?document.documentMode||6:+(o||i)[1]),A=!o&&/WebKit\//.test(t),l=A&&/Qt\/\d+\.\d+/.test(t),c=!o&&/Chrome\//.test(t),u=/Opera\//.test(t),h=/Apple Computer/.test(navigator.vendor),d=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(t),f=/PhantomJS/.test(t),p=!o&&/AppleWebKit/.test(t)&&/Mobile\/\w+/.test(t),g=/Android/.test(t),m=p||g||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(t),v=p||/Mac/.test(e),y=/\bCrOS\b/.test(t),w=/win/i.test(e),b=u&&t.match(/Version\/(\d*\.\d*)/);b&&(b=Number(b[1])),b&&b>=15&&(u=!1,A=!0);var C=v&&(l||u&&(null==b||b<12.11)),B=r||a&&s>=9;function x(t){return new RegExp("(^|\\s)"+t+"(?:$|\\s)\\s*")}var E,S=function(t,e){var r=t.className,n=x(e).exec(r);if(n){var i=r.slice(n.index+n[0].length);t.className=r.slice(0,n.index)+(i?n[1]+i:"")}};function k(t){for(var e=t.childNodes.length;e>0;--e)t.removeChild(t.firstChild);return t}function T(t,e){return k(t).appendChild(e)}function F(t,e,r,n){var i=document.createElement(t);if(r&&(i.className=r),n&&(i.style.cssText=n),"string"==typeof e)i.appendChild(document.createTextNode(e));else if(e)for(var o=0;o<e.length;++o)i.appendChild(e[o]);return i}function L(t,e,r,n){var i=F(t,e,r,n);return i.setAttribute("role","presentation"),i}function I(t,e){if(3==e.nodeType&&(e=e.parentNode),t.contains)return t.contains(e);do{if(11==e.nodeType&&(e=e.host),e==t)return!0}while(e=e.parentNode)}function _(){var t;try{t=document.activeElement}catch(e){t=document.body||null}for(;t&&t.shadowRoot&&t.shadowRoot.activeElement;)t=t.shadowRoot.activeElement;return t}function U(t,e){var r=t.className;x(e).test(r)||(t.className+=(r?" ":"")+e)}function O(t,e){for(var r=t.split(" "),n=0;n<r.length;n++)r[n]&&!x(r[n]).test(e)&&(e+=" "+r[n]);return e}E=document.createRange?function(t,e,r,n){var i=document.createRange();return i.setEnd(n||t,r),i.setStart(t,e),i}:function(t,e,r){var n=document.body.createTextRange();try{n.moveToElementText(t.parentNode)}catch(t){return n}return n.collapse(!0),n.moveEnd("character",r),n.moveStart("character",e),n};var D=function(t){t.select()};function Q(t){var e=Array.prototype.slice.call(arguments,1);return function(){return t.apply(null,e)}}function M(t,e,r){for(var n in e||(e={}),t)!t.hasOwnProperty(n)||!1===r&&e.hasOwnProperty(n)||(e[n]=t[n]);return e}function R(t,e,r,n,i){null==e&&-1==(e=t.search(/[^\s\u00a0]/))&&(e=t.length);for(var o=n||0,a=i||0;;){var s=t.indexOf("\t",o);if(s<0||s>=e)return a+(e-o);a+=s-o,a+=r-a%r,o=s+1}}p?D=function(t){t.selectionStart=0,t.selectionEnd=t.value.length}:a&&(D=function(t){try{t.select()}catch(t){}});var P=function(){this.id=null,this.f=null,this.time=0,this.handler=Q(this.onTimeout,this)};function H(t,e){for(var r=0;r<t.length;++r)if(t[r]==e)return r;return-1}P.prototype.onTimeout=function(t){t.id=0,t.time<=+new Date?t.f():setTimeout(t.handler,t.time-+new Date)},P.prototype.set=function(t,e){this.f=e;var r=+new Date+t;(!this.id||r<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,t),this.time=r)};var N={toString:function(){return"CodeMirror.Pass"}},K={scroll:!1},j={origin:"*mouse"},G={origin:"+move"};function V(t,e,r){for(var n=0,i=0;;){var o=t.indexOf("\t",n);-1==o&&(o=t.length);var a=o-n;if(o==t.length||i+a>=e)return n+Math.min(a,e-i);if(i+=o-n,n=o+1,(i+=r-i%r)>=e)return n}}var z=[""];function W(t){for(;z.length<=t;)z.push(Y(z)+" ");return z[t]}function Y(t){return t[t.length-1]}function X(t,e){for(var r=[],n=0;n<t.length;n++)r[n]=e(t[n],n);return r}function q(){}function J(t,e){var r;return Object.create?r=Object.create(t):(q.prototype=t,r=new q),e&&M(e,r),r}var Z=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function $(t){return/\w/.test(t)||t>""&&(t.toUpperCase()!=t.toLowerCase()||Z.test(t))}function tt(t,e){return e?!!(e.source.indexOf("\\w")>-1&&$(t))||e.test(t):$(t)}function et(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e])return!1;return!0}var rt=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function nt(t){return t.charCodeAt(0)>=768&&rt.test(t)}function it(t,e,r){for(;(r<0?e>0:e<t.length)&&nt(t.charAt(e));)e+=r;return e}function ot(t,e,r){for(var n=e>r?-1:1;;){if(e==r)return e;var i=(e+r)/2,o=n<0?Math.ceil(i):Math.floor(i);if(o==e)return t(o)?e:r;t(o)?r=o:e=o+n}}var at=null;function st(t,e,r){var n;at=null;for(var i=0;i<t.length;++i){var o=t[i];if(o.from<e&&o.to>e)return i;o.to==e&&(o.from!=o.to&&"before"==r?n=i:at=i),o.from==e&&(o.from!=o.to&&"before"!=r?n=i:at=i)}return null!=n?n:at}var At=function(){var t=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,e=/[stwN]/,r=/[LRr]/,n=/[Lb1n]/,i=/[1n]/;function o(t,e,r){this.level=t,this.from=e,this.to=r}return function(a,s){var A="ltr"==s?"L":"R";if(0==a.length||"ltr"==s&&!t.test(a))return!1;for(var l,c=a.length,u=[],h=0;h<c;++h)u.push((l=a.charCodeAt(h))<=247?"bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN".charAt(l):1424<=l&&l<=1524?"R":1536<=l&&l<=1785?"nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111".charAt(l-1536):1774<=l&&l<=2220?"r":8192<=l&&l<=8203?"w":8204==l?"b":"L");for(var d=0,f=A;d<c;++d){var p=u[d];"m"==p?u[d]=f:f=p}for(var g=0,m=A;g<c;++g){var v=u[g];"1"==v&&"r"==m?u[g]="n":r.test(v)&&(m=v,"r"==v&&(u[g]="R"))}for(var y=1,w=u[0];y<c-1;++y){var b=u[y];"+"==b&&"1"==w&&"1"==u[y+1]?u[y]="1":","!=b||w!=u[y+1]||"1"!=w&&"n"!=w||(u[y]=w),w=b}for(var C=0;C<c;++C){var B=u[C];if(","==B)u[C]="N";else if("%"==B){var x=void 0;for(x=C+1;x<c&&"%"==u[x];++x);for(var E=C&&"!"==u[C-1]||x<c&&"1"==u[x]?"1":"N",S=C;S<x;++S)u[S]=E;C=x-1}}for(var k=0,T=A;k<c;++k){var F=u[k];"L"==T&&"1"==F?u[k]="L":r.test(F)&&(T=F)}for(var L=0;L<c;++L)if(e.test(u[L])){var I=void 0;for(I=L+1;I<c&&e.test(u[I]);++I);for(var _="L"==(L?u[L-1]:A),U=_==("L"==(I<c?u[I]:A))?_?"L":"R":A,O=L;O<I;++O)u[O]=U;L=I-1}for(var D,Q=[],M=0;M<c;)if(n.test(u[M])){var R=M;for(++M;M<c&&n.test(u[M]);++M);Q.push(new o(0,R,M))}else{var P=M,H=Q.length,N="rtl"==s?1:0;for(++M;M<c&&"L"!=u[M];++M);for(var K=P;K<M;)if(i.test(u[K])){P<K&&(Q.splice(H,0,new o(1,P,K)),H+=N);var j=K;for(++K;K<M&&i.test(u[K]);++K);Q.splice(H,0,new o(2,j,K)),H+=N,P=K}else++K;P<M&&Q.splice(H,0,new o(1,P,M))}return"ltr"==s&&(1==Q[0].level&&(D=a.match(/^\s+/))&&(Q[0].from=D[0].length,Q.unshift(new o(0,0,D[0].length))),1==Y(Q).level&&(D=a.match(/\s+$/))&&(Y(Q).to-=D[0].length,Q.push(new o(0,c-D[0].length,c)))),"rtl"==s?Q.reverse():Q}}();function lt(t,e){var r=t.order;return null==r&&(r=t.order=At(t.text,e)),r}var ct=[],ut=function(t,e,r){if(t.addEventListener)t.addEventListener(e,r,!1);else if(t.attachEvent)t.attachEvent("on"+e,r);else{var n=t._handlers||(t._handlers={});n[e]=(n[e]||ct).concat(r)}};function ht(t,e){return t._handlers&&t._handlers[e]||ct}function dt(t,e,r){if(t.removeEventListener)t.removeEventListener(e,r,!1);else if(t.detachEvent)t.detachEvent("on"+e,r);else{var n=t._handlers,i=n&&n[e];if(i){var o=H(i,r);o>-1&&(n[e]=i.slice(0,o).concat(i.slice(o+1)))}}}function ft(t,e){var r=ht(t,e);if(r.length)for(var n=Array.prototype.slice.call(arguments,2),i=0;i<r.length;++i)r[i].apply(null,n)}function pt(t,e,r){return"string"==typeof e&&(e={type:e,preventDefault:function(){this.defaultPrevented=!0}}),ft(t,r||e.type,t,e),bt(e)||e.codemirrorIgnore}function gt(t){var e=t._handlers&&t._handlers.cursorActivity;if(e)for(var r=t.curOp.cursorActivityHandlers||(t.curOp.cursorActivityHandlers=[]),n=0;n<e.length;++n)-1==H(r,e[n])&&r.push(e[n])}function mt(t,e){return ht(t,e).length>0}function vt(t){t.prototype.on=function(t,e){ut(this,t,e)},t.prototype.off=function(t,e){dt(this,t,e)}}function yt(t){t.preventDefault?t.preventDefault():t.returnValue=!1}function wt(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0}function bt(t){return null!=t.defaultPrevented?t.defaultPrevented:0==t.returnValue}function Ct(t){yt(t),wt(t)}function Bt(t){return t.target||t.srcElement}function xt(t){var e=t.which;return null==e&&(1&t.button?e=1:2&t.button?e=3:4&t.button&&(e=2)),v&&t.ctrlKey&&1==e&&(e=3),e}var Et,St,kt=function(){if(a&&s<9)return!1;var t=F("div");return"draggable"in t||"dragDrop"in t}();function Tt(t){if(null==Et){var e=F("span","");T(t,F("span",[e,document.createTextNode("x")])),0!=t.firstChild.offsetHeight&&(Et=e.offsetWidth<=1&&e.offsetHeight>2&&!(a&&s<8))}var r=Et?F("span",""):F("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return r.setAttribute("cm-text",""),r}function Ft(t){if(null!=St)return St;var e=T(t,document.createTextNode("AخA")),r=E(e,0,1).getBoundingClientRect(),n=E(e,1,2).getBoundingClientRect();return k(t),!(!r||r.left==r.right)&&(St=n.right-r.right<3)}var Lt,It=3!="\n\nb".split(/\n/).length?function(t){for(var e=0,r=[],n=t.length;e<=n;){var i=t.indexOf("\n",e);-1==i&&(i=t.length);var o=t.slice(e,"\r"==t.charAt(i-1)?i-1:i),a=o.indexOf("\r");-1!=a?(r.push(o.slice(0,a)),e+=a+1):(r.push(o),e=i+1)}return r}:function(t){return t.split(/\r\n?|\n/)},_t=window.getSelection?function(t){try{return t.selectionStart!=t.selectionEnd}catch(t){return!1}}:function(t){var e;try{e=t.ownerDocument.selection.createRange()}catch(t){}return!(!e||e.parentElement()!=t)&&0!=e.compareEndPoints("StartToEnd",e)},Ut="oncopy"in(Lt=F("div"))||(Lt.setAttribute("oncopy","return;"),"function"==typeof Lt.oncopy),Ot=null,Dt={},Qt={};function Mt(t,e){arguments.length>2&&(e.dependencies=Array.prototype.slice.call(arguments,2)),Dt[t]=e}function Rt(t){if("string"==typeof t&&Qt.hasOwnProperty(t))t=Qt[t];else if(t&&"string"==typeof t.name&&Qt.hasOwnProperty(t.name)){var e=Qt[t.name];"string"==typeof e&&(e={name:e}),(t=J(e,t)).name=e.name}else{if("string"==typeof t&&/^[\w\-]+\/[\w\-]+\+xml$/.test(t))return Rt("application/xml");if("string"==typeof t&&/^[\w\-]+\/[\w\-]+\+json$/.test(t))return Rt("application/json")}return"string"==typeof t?{name:t}:t||{name:"null"}}function Pt(t,e){e=Rt(e);var r=Dt[e.name];if(!r)return Pt(t,"text/plain");var n=r(t,e);if(Ht.hasOwnProperty(e.name)){var i=Ht[e.name];for(var o in i)i.hasOwnProperty(o)&&(n.hasOwnProperty(o)&&(n["_"+o]=n[o]),n[o]=i[o])}if(n.name=e.name,e.helperType&&(n.helperType=e.helperType),e.modeProps)for(var a in e.modeProps)n[a]=e.modeProps[a];return n}var Ht={};function Nt(t,e){M(e,Ht.hasOwnProperty(t)?Ht[t]:Ht[t]={})}function Kt(t,e){if(!0===e)return e;if(t.copyState)return t.copyState(e);var r={};for(var n in e){var i=e[n];i instanceof Array&&(i=i.concat([])),r[n]=i}return r}function jt(t,e){for(var r;t.innerMode&&(r=t.innerMode(e))&&r.mode!=t;)e=r.state,t=r.mode;return r||{mode:t,state:e}}function Gt(t,e,r){return!t.startState||t.startState(e,r)}var Vt=function(t,e,r){this.pos=this.start=0,this.string=t,this.tabSize=e||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=r};function zt(t,e){if((e-=t.first)<0||e>=t.size)throw new Error("There is no line "+(e+t.first)+" in the document.");for(var r=t;!r.lines;)for(var n=0;;++n){var i=r.children[n],o=i.chunkSize();if(e<o){r=i;break}e-=o}return r.lines[e]}function Wt(t,e,r){var n=[],i=e.line;return t.iter(e.line,r.line+1,(function(t){var o=t.text;i==r.line&&(o=o.slice(0,r.ch)),i==e.line&&(o=o.slice(e.ch)),n.push(o),++i})),n}function Yt(t,e,r){var n=[];return t.iter(e,r,(function(t){n.push(t.text)})),n}function Xt(t,e){var r=e-t.height;if(r)for(var n=t;n;n=n.parent)n.height+=r}function qt(t){if(null==t.parent)return null;for(var e=t.parent,r=H(e.lines,t),n=e.parent;n;e=n,n=n.parent)for(var i=0;n.children[i]!=e;++i)r+=n.children[i].chunkSize();return r+e.first}function Jt(t,e){var r=t.first;t:do{for(var n=0;n<t.children.length;++n){var i=t.children[n],o=i.height;if(e<o){t=i;continue t}e-=o,r+=i.chunkSize()}return r}while(!t.lines);for(var a=0;a<t.lines.length;++a){var s=t.lines[a].height;if(e<s)break;e-=s}return r+a}function Zt(t,e){return e>=t.first&&e<t.first+t.size}function $t(t,e){return String(t.lineNumberFormatter(e+t.firstLineNumber))}function te(t,e,r){if(void 0===r&&(r=null),!(this instanceof te))return new te(t,e,r);this.line=t,this.ch=e,this.sticky=r}function ee(t,e){return t.line-e.line||t.ch-e.ch}function re(t,e){return t.sticky==e.sticky&&0==ee(t,e)}function ne(t){return te(t.line,t.ch)}function ie(t,e){return ee(t,e)<0?e:t}function oe(t,e){return ee(t,e)<0?t:e}function ae(t,e){return Math.max(t.first,Math.min(e,t.first+t.size-1))}function se(t,e){if(e.line<t.first)return te(t.first,0);var r=t.first+t.size-1;return e.line>r?te(r,zt(t,r).text.length):function(t,e){var r=t.ch;return null==r||r>e?te(t.line,e):r<0?te(t.line,0):t}(e,zt(t,e.line).text.length)}function Ae(t,e){for(var r=[],n=0;n<e.length;n++)r[n]=se(t,e[n]);return r}Vt.prototype.eol=function(){return this.pos>=this.string.length},Vt.prototype.sol=function(){return this.pos==this.lineStart},Vt.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Vt.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},Vt.prototype.eat=function(t){var e=this.string.charAt(this.pos);if("string"==typeof t?e==t:e&&(t.test?t.test(e):t(e)))return++this.pos,e},Vt.prototype.eatWhile=function(t){for(var e=this.pos;this.eat(t););return this.pos>e},Vt.prototype.eatSpace=function(){for(var t=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>t},Vt.prototype.skipToEnd=function(){this.pos=this.string.length},Vt.prototype.skipTo=function(t){var e=this.string.indexOf(t,this.pos);if(e>-1)return this.pos=e,!0},Vt.prototype.backUp=function(t){this.pos-=t},Vt.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=R(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?R(this.string,this.lineStart,this.tabSize):0)},Vt.prototype.indentation=function(){return R(this.string,null,this.tabSize)-(this.lineStart?R(this.string,this.lineStart,this.tabSize):0)},Vt.prototype.match=function(t,e,r){if("string"!=typeof t){var n=this.string.slice(this.pos).match(t);return n&&n.index>0?null:(n&&!1!==e&&(this.pos+=n[0].length),n)}var i=function(t){return r?t.toLowerCase():t};if(i(this.string.substr(this.pos,t.length))==i(t))return!1!==e&&(this.pos+=t.length),!0},Vt.prototype.current=function(){return this.string.slice(this.start,this.pos)},Vt.prototype.hideFirstChars=function(t,e){this.lineStart+=t;try{return e()}finally{this.lineStart-=t}},Vt.prototype.lookAhead=function(t){var e=this.lineOracle;return e&&e.lookAhead(t)},Vt.prototype.baseToken=function(){var t=this.lineOracle;return t&&t.baseToken(this.pos)};var le=function(t,e){this.state=t,this.lookAhead=e},ce=function(t,e,r,n){this.state=e,this.doc=t,this.line=r,this.maxLookAhead=n||0,this.baseTokens=null,this.baseTokenPos=1};function ue(t,e,r,n){var i=[t.state.modeGen],o={};we(t,e.text,t.doc.mode,r,(function(t,e){return i.push(t,e)}),o,n);for(var a=r.state,s=function(n){r.baseTokens=i;var s=t.state.overlays[n],A=1,l=0;r.state=!0,we(t,e.text,s.mode,r,(function(t,e){for(var r=A;l<t;){var n=i[A];n>t&&i.splice(A,1,t,i[A+1],n),A+=2,l=Math.min(t,n)}if(e)if(s.opaque)i.splice(r,A-r,t,"overlay "+e),A=r+2;else for(;r<A;r+=2){var o=i[r+1];i[r+1]=(o?o+" ":"")+"overlay "+e}}),o),r.state=a,r.baseTokens=null,r.baseTokenPos=1},A=0;A<t.state.overlays.length;++A)s(A);return{styles:i,classes:o.bgClass||o.textClass?o:null}}function he(t,e,r){if(!e.styles||e.styles[0]!=t.state.modeGen){var n=de(t,qt(e)),i=e.text.length>t.options.maxHighlightLength&&Kt(t.doc.mode,n.state),o=ue(t,e,n);i&&(n.state=i),e.stateAfter=n.save(!i),e.styles=o.styles,o.classes?e.styleClasses=o.classes:e.styleClasses&&(e.styleClasses=null),r===t.doc.highlightFrontier&&(t.doc.modeFrontier=Math.max(t.doc.modeFrontier,++t.doc.highlightFrontier))}return e.styles}function de(t,e,r){var n=t.doc,i=t.display;if(!n.mode.startState)return new ce(n,!0,e);var o=function(t,e,r){for(var n,i,o=t.doc,a=r?-1:e-(t.doc.mode.innerMode?1e3:100),s=e;s>a;--s){if(s<=o.first)return o.first;var A=zt(o,s-1),l=A.stateAfter;if(l&&(!r||s+(l instanceof le?l.lookAhead:0)<=o.modeFrontier))return s;var c=R(A.text,null,t.options.tabSize);(null==i||n>c)&&(i=s-1,n=c)}return i}(t,e,r),a=o>n.first&&zt(n,o-1).stateAfter,s=a?ce.fromSaved(n,a,o):new ce(n,Gt(n.mode),o);return n.iter(o,e,(function(r){fe(t,r.text,s);var n=s.line;r.stateAfter=n==e-1||n%5==0||n>=i.viewFrom&&n<i.viewTo?s.save():null,s.nextLine()})),r&&(n.modeFrontier=s.line),s}function fe(t,e,r,n){var i=t.doc.mode,o=new Vt(e,t.options.tabSize,r);for(o.start=o.pos=n||0,""==e&&pe(i,r.state);!o.eol();)ge(i,o,r.state),o.start=o.pos}function pe(t,e){if(t.blankLine)return t.blankLine(e);if(t.innerMode){var r=jt(t,e);return r.mode.blankLine?r.mode.blankLine(r.state):void 0}}function ge(t,e,r,n){for(var i=0;i<10;i++){n&&(n[0]=jt(t,r).mode);var o=t.token(e,r);if(e.pos>e.start)return o}throw new Error("Mode "+t.name+" failed to advance stream.")}ce.prototype.lookAhead=function(t){var e=this.doc.getLine(this.line+t);return null!=e&&t>this.maxLookAhead&&(this.maxLookAhead=t),e},ce.prototype.baseToken=function(t){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=t;)this.baseTokenPos+=2;var e=this.baseTokens[this.baseTokenPos+1];return{type:e&&e.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-t}},ce.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},ce.fromSaved=function(t,e,r){return e instanceof le?new ce(t,Kt(t.mode,e.state),r,e.lookAhead):new ce(t,Kt(t.mode,e),r)},ce.prototype.save=function(t){var e=!1!==t?Kt(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new le(e,this.maxLookAhead):e};var me=function(t,e,r){this.start=t.start,this.end=t.pos,this.string=t.current(),this.type=e||null,this.state=r};function ve(t,e,r,n){var i,o,a=t.doc,s=a.mode,A=zt(a,(e=se(a,e)).line),l=de(t,e.line,r),c=new Vt(A.text,t.options.tabSize,l);for(n&&(o=[]);(n||c.pos<e.ch)&&!c.eol();)c.start=c.pos,i=ge(s,c,l.state),n&&o.push(new me(c,i,Kt(a.mode,l.state)));return n?o:new me(c,i,l.state)}function ye(t,e){if(t)for(;;){var r=t.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!r)break;t=t.slice(0,r.index)+t.slice(r.index+r[0].length);var n=r[1]?"bgClass":"textClass";null==e[n]?e[n]=r[2]:new RegExp("(?:^|\\s)"+r[2]+"(?:$|\\s)").test(e[n])||(e[n]+=" "+r[2])}return t}function we(t,e,r,n,i,o,a){var s=r.flattenSpans;null==s&&(s=t.options.flattenSpans);var A,l=0,c=null,u=new Vt(e,t.options.tabSize,n),h=t.options.addModeClass&&[null];for(""==e&&ye(pe(r,n.state),o);!u.eol();){if(u.pos>t.options.maxHighlightLength?(s=!1,a&&fe(t,e,n,u.pos),u.pos=e.length,A=null):A=ye(ge(r,u,n.state,h),o),h){var d=h[0].name;d&&(A="m-"+(A?d+" "+A:d))}if(!s||c!=A){for(;l<u.start;)i(l=Math.min(u.start,l+5e3),c);c=A}u.start=u.pos}for(;l<u.pos;){var f=Math.min(u.pos,l+5e3);i(f,c),l=f}}var be=!1,Ce=!1;function Be(t,e,r){this.marker=t,this.from=e,this.to=r}function xe(t,e){if(t)for(var r=0;r<t.length;++r){var n=t[r];if(n.marker==e)return n}}function Ee(t,e){for(var r,n=0;n<t.length;++n)t[n]!=e&&(r||(r=[])).push(t[n]);return r}function Se(t,e){if(e.full)return null;var r=Zt(t,e.from.line)&&zt(t,e.from.line).markedSpans,n=Zt(t,e.to.line)&&zt(t,e.to.line).markedSpans;if(!r&&!n)return null;var i=e.from.ch,o=e.to.ch,a=0==ee(e.from,e.to),s=function(t,e,r){var n;if(t)for(var i=0;i<t.length;++i){var o=t[i],a=o.marker;if(null==o.from||(a.inclusiveLeft?o.from<=e:o.from<e)||o.from==e&&"bookmark"==a.type&&(!r||!o.marker.insertLeft)){var s=null==o.to||(a.inclusiveRight?o.to>=e:o.to>e);(n||(n=[])).push(new Be(a,o.from,s?null:o.to))}}return n}(r,i,a),A=function(t,e,r){var n;if(t)for(var i=0;i<t.length;++i){var o=t[i],a=o.marker;if(null==o.to||(a.inclusiveRight?o.to>=e:o.to>e)||o.from==e&&"bookmark"==a.type&&(!r||o.marker.insertLeft)){var s=null==o.from||(a.inclusiveLeft?o.from<=e:o.from<e);(n||(n=[])).push(new Be(a,s?null:o.from-e,null==o.to?null:o.to-e))}}return n}(n,o,a),l=1==e.text.length,c=Y(e.text).length+(l?i:0);if(s)for(var u=0;u<s.length;++u){var h=s[u];if(null==h.to){var d=xe(A,h.marker);d?l&&(h.to=null==d.to?null:d.to+c):h.to=i}}if(A)for(var f=0;f<A.length;++f){var p=A[f];null!=p.to&&(p.to+=c),null==p.from?xe(s,p.marker)||(p.from=c,l&&(s||(s=[])).push(p)):(p.from+=c,l&&(s||(s=[])).push(p))}s&&(s=ke(s)),A&&A!=s&&(A=ke(A));var g=[s];if(!l){var m,v=e.text.length-2;if(v>0&&s)for(var y=0;y<s.length;++y)null==s[y].to&&(m||(m=[])).push(new Be(s[y].marker,null,null));for(var w=0;w<v;++w)g.push(m);g.push(A)}return g}function ke(t){for(var e=0;e<t.length;++e){var r=t[e];null!=r.from&&r.from==r.to&&!1!==r.marker.clearWhenEmpty&&t.splice(e--,1)}return t.length?t:null}function Te(t){var e=t.markedSpans;if(e){for(var r=0;r<e.length;++r)e[r].marker.detachLine(t);t.markedSpans=null}}function Fe(t,e){if(e){for(var r=0;r<e.length;++r)e[r].marker.attachLine(t);t.markedSpans=e}}function Le(t){return t.inclusiveLeft?-1:0}function Ie(t){return t.inclusiveRight?1:0}function _e(t,e){var r=t.lines.length-e.lines.length;if(0!=r)return r;var n=t.find(),i=e.find(),o=ee(n.from,i.from)||Le(t)-Le(e);if(o)return-o;var a=ee(n.to,i.to)||Ie(t)-Ie(e);return a||e.id-t.id}function Ue(t,e){var r,n=Ce&&t.markedSpans;if(n)for(var i=void 0,o=0;o<n.length;++o)(i=n[o]).marker.collapsed&&null==(e?i.from:i.to)&&(!r||_e(r,i.marker)<0)&&(r=i.marker);return r}function Oe(t){return Ue(t,!0)}function De(t){return Ue(t,!1)}function Qe(t,e){var r,n=Ce&&t.markedSpans;if(n)for(var i=0;i<n.length;++i){var o=n[i];o.marker.collapsed&&(null==o.from||o.from<e)&&(null==o.to||o.to>e)&&(!r||_e(r,o.marker)<0)&&(r=o.marker)}return r}function Me(t,e,r,n,i){var o=zt(t,e),a=Ce&&o.markedSpans;if(a)for(var s=0;s<a.length;++s){var A=a[s];if(A.marker.collapsed){var l=A.marker.find(0),c=ee(l.from,r)||Le(A.marker)-Le(i),u=ee(l.to,n)||Ie(A.marker)-Ie(i);if(!(c>=0&&u<=0||c<=0&&u>=0)&&(c<=0&&(A.marker.inclusiveRight&&i.inclusiveLeft?ee(l.to,r)>=0:ee(l.to,r)>0)||c>=0&&(A.marker.inclusiveRight&&i.inclusiveLeft?ee(l.from,n)<=0:ee(l.from,n)<0)))return!0}}}function Re(t){for(var e;e=Oe(t);)t=e.find(-1,!0).line;return t}function Pe(t,e){var r=zt(t,e),n=Re(r);return r==n?e:qt(n)}function He(t,e){if(e>t.lastLine())return e;var r,n=zt(t,e);if(!Ne(t,n))return e;for(;r=De(n);)n=r.find(1,!0).line;return qt(n)+1}function Ne(t,e){var r=Ce&&e.markedSpans;if(r)for(var n=void 0,i=0;i<r.length;++i)if((n=r[i]).marker.collapsed){if(null==n.from)return!0;if(!n.marker.widgetNode&&0==n.from&&n.marker.inclusiveLeft&&Ke(t,e,n))return!0}}function Ke(t,e,r){if(null==r.to){var n=r.marker.find(1,!0);return Ke(t,n.line,xe(n.line.markedSpans,r.marker))}if(r.marker.inclusiveRight&&r.to==e.text.length)return!0;for(var i=void 0,o=0;o<e.markedSpans.length;++o)if((i=e.markedSpans[o]).marker.collapsed&&!i.marker.widgetNode&&i.from==r.to&&(null==i.to||i.to!=r.from)&&(i.marker.inclusiveLeft||r.marker.inclusiveRight)&&Ke(t,e,i))return!0}function je(t){for(var e=0,r=(t=Re(t)).parent,n=0;n<r.lines.length;++n){var i=r.lines[n];if(i==t)break;e+=i.height}for(var o=r.parent;o;o=(r=o).parent)for(var a=0;a<o.children.length;++a){var s=o.children[a];if(s==r)break;e+=s.height}return e}function Ge(t){if(0==t.height)return 0;for(var e,r=t.text.length,n=t;e=Oe(n);){var i=e.find(0,!0);n=i.from.line,r+=i.from.ch-i.to.ch}for(n=t;e=De(n);){var o=e.find(0,!0);r-=n.text.length-o.from.ch,r+=(n=o.to.line).text.length-o.to.ch}return r}function Ve(t){var e=t.display,r=t.doc;e.maxLine=zt(r,r.first),e.maxLineLength=Ge(e.maxLine),e.maxLineChanged=!0,r.iter((function(t){var r=Ge(t);r>e.maxLineLength&&(e.maxLineLength=r,e.maxLine=t)}))}var ze=function(t,e,r){this.text=t,Fe(this,e),this.height=r?r(this):1};function We(t){t.parent=null,Te(t)}ze.prototype.lineNo=function(){return qt(this)},vt(ze);var Ye={},Xe={};function qe(t,e){if(!t||/^\s*$/.test(t))return null;var r=e.addModeClass?Xe:Ye;return r[t]||(r[t]=t.replace(/\S+/g,"cm-$&"))}function Je(t,e){var r=L("span",null,null,A?"padding-right: .1px":null),n={pre:L("pre",[r],"CodeMirror-line"),content:r,col:0,pos:0,cm:t,trailingSpace:!1,splitSpaces:t.getOption("lineWrapping")};e.measure={};for(var i=0;i<=(e.rest?e.rest.length:0);i++){var o=i?e.rest[i-1]:e.line,a=void 0;n.pos=0,n.addToken=$e,Ft(t.display.measure)&&(a=lt(o,t.doc.direction))&&(n.addToken=tr(n.addToken,a)),n.map=[],rr(o,n,he(t,o,e!=t.display.externalMeasured&&qt(o))),o.styleClasses&&(o.styleClasses.bgClass&&(n.bgClass=O(o.styleClasses.bgClass,n.bgClass||"")),o.styleClasses.textClass&&(n.textClass=O(o.styleClasses.textClass,n.textClass||""))),0==n.map.length&&n.map.push(0,0,n.content.appendChild(Tt(t.display.measure))),0==i?(e.measure.map=n.map,e.measure.cache={}):((e.measure.maps||(e.measure.maps=[])).push(n.map),(e.measure.caches||(e.measure.caches=[])).push({}))}if(A){var s=n.content.lastChild;(/\bcm-tab\b/.test(s.className)||s.querySelector&&s.querySelector(".cm-tab"))&&(n.content.className="cm-tab-wrap-hack")}return ft(t,"renderLine",t,e.line,n.pre),n.pre.className&&(n.textClass=O(n.pre.className,n.textClass||"")),n}function Ze(t){var e=F("span","•","cm-invalidchar");return e.title="\\u"+t.charCodeAt(0).toString(16),e.setAttribute("aria-label",e.title),e}function $e(t,e,r,n,i,o,A){if(e){var l,c=t.splitSpaces?function(t,e){if(t.length>1&&!/ /.test(t))return t;for(var r=e,n="",i=0;i<t.length;i++){var o=t.charAt(i);" "!=o||!r||i!=t.length-1&&32!=t.charCodeAt(i+1)||(o=" "),n+=o,r=" "==o}return n}(e,t.trailingSpace):e,u=t.cm.state.specialChars,h=!1;if(u.test(e)){l=document.createDocumentFragment();for(var d=0;;){u.lastIndex=d;var f=u.exec(e),p=f?f.index-d:e.length-d;if(p){var g=document.createTextNode(c.slice(d,d+p));a&&s<9?l.appendChild(F("span",[g])):l.appendChild(g),t.map.push(t.pos,t.pos+p,g),t.col+=p,t.pos+=p}if(!f)break;d+=p+1;var m=void 0;if("\t"==f[0]){var v=t.cm.options.tabSize,y=v-t.col%v;(m=l.appendChild(F("span",W(y),"cm-tab"))).setAttribute("role","presentation"),m.setAttribute("cm-text","\t"),t.col+=y}else"\r"==f[0]||"\n"==f[0]?((m=l.appendChild(F("span","\r"==f[0]?"␍":"","cm-invalidchar"))).setAttribute("cm-text",f[0]),t.col+=1):((m=t.cm.options.specialCharPlaceholder(f[0])).setAttribute("cm-text",f[0]),a&&s<9?l.appendChild(F("span",[m])):l.appendChild(m),t.col+=1);t.map.push(t.pos,t.pos+1,m),t.pos++}}else t.col+=e.length,l=document.createTextNode(c),t.map.push(t.pos,t.pos+e.length,l),a&&s<9&&(h=!0),t.pos+=e.length;if(t.trailingSpace=32==c.charCodeAt(e.length-1),r||n||i||h||o||A){var w=r||"";n&&(w+=n),i&&(w+=i);var b=F("span",[l],w,o);if(A)for(var C in A)A.hasOwnProperty(C)&&"style"!=C&&"class"!=C&&b.setAttribute(C,A[C]);return t.content.appendChild(b)}t.content.appendChild(l)}}function tr(t,e){return function(r,n,i,o,a,s,A){i=i?i+" cm-force-border":"cm-force-border";for(var l=r.pos,c=l+n.length;;){for(var u=void 0,h=0;h<e.length&&!((u=e[h]).to>l&&u.from<=l);h++);if(u.to>=c)return t(r,n,i,o,a,s,A);t(r,n.slice(0,u.to-l),i,o,null,s,A),o=null,n=n.slice(u.to-l),l=u.to}}}function er(t,e,r,n){var i=!n&&r.widgetNode;i&&t.map.push(t.pos,t.pos+e,i),!n&&t.cm.display.input.needsContentAttribute&&(i||(i=t.content.appendChild(document.createElement("span"))),i.setAttribute("cm-marker",r.id)),i&&(t.cm.display.input.setUneditable(i),t.content.appendChild(i)),t.pos+=e,t.trailingSpace=!1}function rr(t,e,r){var n=t.markedSpans,i=t.text,o=0;if(n)for(var a,s,A,l,c,u,h,d=i.length,f=0,p=1,g="",m=0;;){if(m==f){A=l=c=s="",h=null,u=null,m=1/0;for(var v=[],y=void 0,w=0;w<n.length;++w){var b=n[w],C=b.marker;if("bookmark"==C.type&&b.from==f&&C.widgetNode)v.push(C);else if(b.from<=f&&(null==b.to||b.to>f||C.collapsed&&b.to==f&&b.from==f)){if(null!=b.to&&b.to!=f&&m>b.to&&(m=b.to,l=""),C.className&&(A+=" "+C.className),C.css&&(s=(s?s+";":"")+C.css),C.startStyle&&b.from==f&&(c+=" "+C.startStyle),C.endStyle&&b.to==m&&(y||(y=[])).push(C.endStyle,b.to),C.title&&((h||(h={})).title=C.title),C.attributes)for(var B in C.attributes)(h||(h={}))[B]=C.attributes[B];C.collapsed&&(!u||_e(u.marker,C)<0)&&(u=b)}else b.from>f&&m>b.from&&(m=b.from)}if(y)for(var x=0;x<y.length;x+=2)y[x+1]==m&&(l+=" "+y[x]);if(!u||u.from==f)for(var E=0;E<v.length;++E)er(e,0,v[E]);if(u&&(u.from||0)==f){if(er(e,(null==u.to?d+1:u.to)-f,u.marker,null==u.from),null==u.to)return;u.to==f&&(u=!1)}}if(f>=d)break;for(var S=Math.min(d,m);;){if(g){var k=f+g.length;if(!u){var T=k>S?g.slice(0,S-f):g;e.addToken(e,T,a?a+A:A,c,f+T.length==m?l:"",s,h)}if(k>=S){g=g.slice(S-f),f=S;break}f=k,c=""}g=i.slice(o,o=r[p++]),a=qe(r[p++],e.cm.options)}}else for(var F=1;F<r.length;F+=2)e.addToken(e,i.slice(o,o=r[F]),qe(r[F+1],e.cm.options))}function nr(t,e,r){this.line=e,this.rest=function(t){for(var e,r;e=De(t);)t=e.find(1,!0).line,(r||(r=[])).push(t);return r}(e),this.size=this.rest?qt(Y(this.rest))-r+1:1,this.node=this.text=null,this.hidden=Ne(t,e)}function ir(t,e,r){for(var n,i=[],o=e;o<r;o=n){var a=new nr(t.doc,zt(t.doc,o),o);n=o+a.size,i.push(a)}return i}var or=null,ar=null;function sr(t,e){var r=ht(t,e);if(r.length){var n,i=Array.prototype.slice.call(arguments,2);or?n=or.delayedCallbacks:ar?n=ar:(n=ar=[],setTimeout(Ar,0));for(var o=function(t){n.push((function(){return r[t].apply(null,i)}))},a=0;a<r.length;++a)o(a)}}function Ar(){var t=ar;ar=null;for(var e=0;e<t.length;++e)t[e]()}function lr(t,e,r,n){for(var i=0;i<e.changes.length;i++){var o=e.changes[i];"text"==o?hr(t,e):"gutter"==o?fr(t,e,r,n):"class"==o?dr(t,e):"widget"==o&&pr(t,e,n)}e.changes=null}function cr(t){return t.node==t.text&&(t.node=F("div",null,null,"position: relative"),t.text.parentNode&&t.text.parentNode.replaceChild(t.node,t.text),t.node.appendChild(t.text),a&&s<8&&(t.node.style.zIndex=2)),t.node}function ur(t,e){var r=t.display.externalMeasured;return r&&r.line==e.line?(t.display.externalMeasured=null,e.measure=r.measure,r.built):Je(t,e)}function hr(t,e){var r=e.text.className,n=ur(t,e);e.text==e.node&&(e.node=n.pre),e.text.parentNode.replaceChild(n.pre,e.text),e.text=n.pre,n.bgClass!=e.bgClass||n.textClass!=e.textClass?(e.bgClass=n.bgClass,e.textClass=n.textClass,dr(t,e)):r&&(e.text.className=r)}function dr(t,e){!function(t,e){var r=e.bgClass?e.bgClass+" "+(e.line.bgClass||""):e.line.bgClass;if(r&&(r+=" CodeMirror-linebackground"),e.background)r?e.background.className=r:(e.background.parentNode.removeChild(e.background),e.background=null);else if(r){var n=cr(e);e.background=n.insertBefore(F("div",null,r),n.firstChild),t.display.input.setUneditable(e.background)}}(t,e),e.line.wrapClass?cr(e).className=e.line.wrapClass:e.node!=e.text&&(e.node.className="");var r=e.textClass?e.textClass+" "+(e.line.textClass||""):e.line.textClass;e.text.className=r||""}function fr(t,e,r,n){if(e.gutter&&(e.node.removeChild(e.gutter),e.gutter=null),e.gutterBackground&&(e.node.removeChild(e.gutterBackground),e.gutterBackground=null),e.line.gutterClass){var i=cr(e);e.gutterBackground=F("div",null,"CodeMirror-gutter-background "+e.line.gutterClass,"left: "+(t.options.fixedGutter?n.fixedPos:-n.gutterTotalWidth)+"px; width: "+n.gutterTotalWidth+"px"),t.display.input.setUneditable(e.gutterBackground),i.insertBefore(e.gutterBackground,e.text)}var o=e.line.gutterMarkers;if(t.options.lineNumbers||o){var a=cr(e),s=e.gutter=F("div",null,"CodeMirror-gutter-wrapper","left: "+(t.options.fixedGutter?n.fixedPos:-n.gutterTotalWidth)+"px");if(t.display.input.setUneditable(s),a.insertBefore(s,e.text),e.line.gutterClass&&(s.className+=" "+e.line.gutterClass),!t.options.lineNumbers||o&&o["CodeMirror-linenumbers"]||(e.lineNumber=s.appendChild(F("div",$t(t.options,r),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+n.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+t.display.lineNumInnerWidth+"px"))),o)for(var A=0;A<t.display.gutterSpecs.length;++A){var l=t.display.gutterSpecs[A].className,c=o.hasOwnProperty(l)&&o[l];c&&s.appendChild(F("div",[c],"CodeMirror-gutter-elt","left: "+n.gutterLeft[l]+"px; width: "+n.gutterWidth[l]+"px"))}}}function pr(t,e,r){e.alignable&&(e.alignable=null);for(var n=x("CodeMirror-linewidget"),i=e.node.firstChild,o=void 0;i;i=o)o=i.nextSibling,n.test(i.className)&&e.node.removeChild(i);mr(t,e,r)}function gr(t,e,r,n){var i=ur(t,e);return e.text=e.node=i.pre,i.bgClass&&(e.bgClass=i.bgClass),i.textClass&&(e.textClass=i.textClass),dr(t,e),fr(t,e,r,n),mr(t,e,n),e.node}function mr(t,e,r){if(vr(t,e.line,e,r,!0),e.rest)for(var n=0;n<e.rest.length;n++)vr(t,e.rest[n],e,r,!1)}function vr(t,e,r,n,i){if(e.widgets)for(var o=cr(r),a=0,s=e.widgets;a<s.length;++a){var A=s[a],l=F("div",[A.node],"CodeMirror-linewidget"+(A.className?" "+A.className:""));A.handleMouseEvents||l.setAttribute("cm-ignore-events","true"),yr(A,l,r,n),t.display.input.setUneditable(l),i&&A.above?o.insertBefore(l,r.gutter||r.text):o.appendChild(l),sr(A,"redraw")}}function yr(t,e,r,n){if(t.noHScroll){(r.alignable||(r.alignable=[])).push(e);var i=n.wrapperWidth;e.style.left=n.fixedPos+"px",t.coverGutter||(i-=n.gutterTotalWidth,e.style.paddingLeft=n.gutterTotalWidth+"px"),e.style.width=i+"px"}t.coverGutter&&(e.style.zIndex=5,e.style.position="relative",t.noHScroll||(e.style.marginLeft=-n.gutterTotalWidth+"px"))}function wr(t){if(null!=t.height)return t.height;var e=t.doc.cm;if(!e)return 0;if(!I(document.body,t.node)){var r="position: relative;";t.coverGutter&&(r+="margin-left: -"+e.display.gutters.offsetWidth+"px;"),t.noHScroll&&(r+="width: "+e.display.wrapper.clientWidth+"px;"),T(e.display.measure,F("div",[t.node],null,r))}return t.height=t.node.parentNode.offsetHeight}function br(t,e){for(var r=Bt(e);r!=t.wrapper;r=r.parentNode)if(!r||1==r.nodeType&&"true"==r.getAttribute("cm-ignore-events")||r.parentNode==t.sizer&&r!=t.mover)return!0}function Cr(t){return t.lineSpace.offsetTop}function Br(t){return t.mover.offsetHeight-t.lineSpace.offsetHeight}function xr(t){if(t.cachedPaddingH)return t.cachedPaddingH;var e=T(t.measure,F("pre","x","CodeMirror-line-like")),r=window.getComputedStyle?window.getComputedStyle(e):e.currentStyle,n={left:parseInt(r.paddingLeft),right:parseInt(r.paddingRight)};return isNaN(n.left)||isNaN(n.right)||(t.cachedPaddingH=n),n}function Er(t){return 50-t.display.nativeBarWidth}function Sr(t){return t.display.scroller.clientWidth-Er(t)-t.display.barWidth}function kr(t){return t.display.scroller.clientHeight-Er(t)-t.display.barHeight}function Tr(t,e,r){if(t.line==e)return{map:t.measure.map,cache:t.measure.cache};for(var n=0;n<t.rest.length;n++)if(t.rest[n]==e)return{map:t.measure.maps[n],cache:t.measure.caches[n]};for(var i=0;i<t.rest.length;i++)if(qt(t.rest[i])>r)return{map:t.measure.maps[i],cache:t.measure.caches[i],before:!0}}function Fr(t,e,r,n){return _r(t,Ir(t,e),r,n)}function Lr(t,e){if(e>=t.display.viewFrom&&e<t.display.viewTo)return t.display.view[cn(t,e)];var r=t.display.externalMeasured;return r&&e>=r.lineN&&e<r.lineN+r.size?r:void 0}function Ir(t,e){var r=qt(e),n=Lr(t,r);n&&!n.text?n=null:n&&n.changes&&(lr(t,n,r,on(t)),t.curOp.forceUpdate=!0),n||(n=function(t,e){var r=qt(e=Re(e)),n=t.display.externalMeasured=new nr(t.doc,e,r);n.lineN=r;var i=n.built=Je(t,n);return n.text=i.pre,T(t.display.lineMeasure,i.pre),n}(t,e));var i=Tr(n,e,r);return{line:e,view:n,rect:null,map:i.map,cache:i.cache,before:i.before,hasHeights:!1}}function _r(t,e,r,n,i){e.before&&(r=-1);var o,A=r+(n||"");return e.cache.hasOwnProperty(A)?o=e.cache[A]:(e.rect||(e.rect=e.view.text.getBoundingClientRect()),e.hasHeights||(function(t,e,r){var n=t.options.lineWrapping,i=n&&Sr(t);if(!e.measure.heights||n&&e.measure.width!=i){var o=e.measure.heights=[];if(n){e.measure.width=i;for(var a=e.text.firstChild.getClientRects(),s=0;s<a.length-1;s++){var A=a[s],l=a[s+1];Math.abs(A.bottom-l.bottom)>2&&o.push((A.bottom+l.top)/2-r.top)}}o.push(r.bottom-r.top)}}(t,e.view,e.rect),e.hasHeights=!0),(o=function(t,e,r,n){var i,o=Dr(e.map,r,n),A=o.node,l=o.start,c=o.end,u=o.collapse;if(3==A.nodeType){for(var h=0;h<4;h++){for(;l&&nt(e.line.text.charAt(o.coverStart+l));)--l;for(;o.coverStart+c<o.coverEnd&&nt(e.line.text.charAt(o.coverStart+c));)++c;if((i=a&&s<9&&0==l&&c==o.coverEnd-o.coverStart?A.parentNode.getBoundingClientRect():Qr(E(A,l,c).getClientRects(),n)).left||i.right||0==l)break;c=l,l-=1,u="right"}a&&s<11&&(i=function(t,e){if(!window.screen||null==screen.logicalXDPI||screen.logicalXDPI==screen.deviceXDPI||!function(t){if(null!=Ot)return Ot;var e=T(t,F("span","x")),r=e.getBoundingClientRect(),n=E(e,0,1).getBoundingClientRect();return Ot=Math.abs(r.left-n.left)>1}(t))return e;var r=screen.logicalXDPI/screen.deviceXDPI,n=screen.logicalYDPI/screen.deviceYDPI;return{left:e.left*r,right:e.right*r,top:e.top*n,bottom:e.bottom*n}}(t.display.measure,i))}else{var d;l>0&&(u=n="right"),i=t.options.lineWrapping&&(d=A.getClientRects()).length>1?d["right"==n?d.length-1:0]:A.getBoundingClientRect()}if(a&&s<9&&!l&&(!i||!i.left&&!i.right)){var f=A.parentNode.getClientRects()[0];i=f?{left:f.left,right:f.left+nn(t.display),top:f.top,bottom:f.bottom}:Or}for(var p=i.top-e.rect.top,g=i.bottom-e.rect.top,m=(p+g)/2,v=e.view.measure.heights,y=0;y<v.length-1&&!(m<v[y]);y++);var w=y?v[y-1]:0,b=v[y],C={left:("right"==u?i.right:i.left)-e.rect.left,right:("left"==u?i.left:i.right)-e.rect.left,top:w,bottom:b};return i.left||i.right||(C.bogus=!0),t.options.singleCursorHeightPerLine||(C.rtop=p,C.rbottom=g),C}(t,e,r,n)).bogus||(e.cache[A]=o)),{left:o.left,right:o.right,top:i?o.rtop:o.top,bottom:i?o.rbottom:o.bottom}}var Ur,Or={left:0,right:0,top:0,bottom:0};function Dr(t,e,r){for(var n,i,o,a,s,A,l=0;l<t.length;l+=3)if(s=t[l],A=t[l+1],e<s?(i=0,o=1,a="left"):e<A?o=1+(i=e-s):(l==t.length-3||e==A&&t[l+3]>e)&&(i=(o=A-s)-1,e>=A&&(a="right")),null!=i){if(n=t[l+2],s==A&&r==(n.insertLeft?"left":"right")&&(a=r),"left"==r&&0==i)for(;l&&t[l-2]==t[l-3]&&t[l-1].insertLeft;)n=t[2+(l-=3)],a="left";if("right"==r&&i==A-s)for(;l<t.length-3&&t[l+3]==t[l+4]&&!t[l+5].insertLeft;)n=t[(l+=3)+2],a="right";break}return{node:n,start:i,end:o,collapse:a,coverStart:s,coverEnd:A}}function Qr(t,e){var r=Or;if("left"==e)for(var n=0;n<t.length&&(r=t[n]).left==r.right;n++);else for(var i=t.length-1;i>=0&&(r=t[i]).left==r.right;i--);return r}function Mr(t){if(t.measure&&(t.measure.cache={},t.measure.heights=null,t.rest))for(var e=0;e<t.rest.length;e++)t.measure.caches[e]={}}function Rr(t){t.display.externalMeasure=null,k(t.display.lineMeasure);for(var e=0;e<t.display.view.length;e++)Mr(t.display.view[e])}function Pr(t){Rr(t),t.display.cachedCharWidth=t.display.cachedTextHeight=t.display.cachedPaddingH=null,t.options.lineWrapping||(t.display.maxLineChanged=!0),t.display.lineNumChars=null}function Hr(){return c&&g?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function Nr(){return c&&g?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function Kr(t){var e=0;if(t.widgets)for(var r=0;r<t.widgets.length;++r)t.widgets[r].above&&(e+=wr(t.widgets[r]));return e}function jr(t,e,r,n,i){if(!i){var o=Kr(e);r.top+=o,r.bottom+=o}if("line"==n)return r;n||(n="local");var a=je(e);if("local"==n?a+=Cr(t.display):a-=t.display.viewOffset,"page"==n||"window"==n){var s=t.display.lineSpace.getBoundingClientRect();a+=s.top+("window"==n?0:Nr());var A=s.left+("window"==n?0:Hr());r.left+=A,r.right+=A}return r.top+=a,r.bottom+=a,r}function Gr(t,e,r){if("div"==r)return e;var n=e.left,i=e.top;if("page"==r)n-=Hr(),i-=Nr();else if("local"==r||!r){var o=t.display.sizer.getBoundingClientRect();n+=o.left,i+=o.top}var a=t.display.lineSpace.getBoundingClientRect();return{left:n-a.left,top:i-a.top}}function Vr(t,e,r,n,i){return n||(n=zt(t.doc,e.line)),jr(t,n,Fr(t,n,e.ch,i),r)}function zr(t,e,r,n,i,o){function a(e,a){var s=_r(t,i,e,a?"right":"left",o);return a?s.left=s.right:s.right=s.left,jr(t,n,s,r)}n=n||zt(t.doc,e.line),i||(i=Ir(t,n));var s=lt(n,t.doc.direction),A=e.ch,l=e.sticky;if(A>=n.text.length?(A=n.text.length,l="before"):A<=0&&(A=0,l="after"),!s)return a("before"==l?A-1:A,"before"==l);function c(t,e,r){return a(r?t-1:t,1==s[e].level!=r)}var u=st(s,A,l),h=at,d=c(A,u,"before"==l);return null!=h&&(d.other=c(A,h,"before"!=l)),d}function Wr(t,e){var r=0;e=se(t.doc,e),t.options.lineWrapping||(r=nn(t.display)*e.ch);var n=zt(t.doc,e.line),i=je(n)+Cr(t.display);return{left:r,right:r,top:i,bottom:i+n.height}}function Yr(t,e,r,n,i){var o=te(t,e,r);return o.xRel=i,n&&(o.outside=n),o}function Xr(t,e,r){var n=t.doc;if((r+=t.display.viewOffset)<0)return Yr(n.first,0,null,-1,-1);var i=Jt(n,r),o=n.first+n.size-1;if(i>o)return Yr(n.first+n.size-1,zt(n,o).text.length,null,1,1);e<0&&(e=0);for(var a=zt(n,i);;){var s=$r(t,a,i,e,r),A=Qe(a,s.ch+(s.xRel>0||s.outside>0?1:0));if(!A)return s;var l=A.find(1);if(l.line==i)return l;a=zt(n,i=l.line)}}function qr(t,e,r,n){n-=Kr(e);var i=e.text.length,o=ot((function(e){return _r(t,r,e-1).bottom<=n}),i,0);return{begin:o,end:i=ot((function(e){return _r(t,r,e).top>n}),o,i)}}function Jr(t,e,r,n){return r||(r=Ir(t,e)),qr(t,e,r,jr(t,e,_r(t,r,n),"line").top)}function Zr(t,e,r,n){return!(t.bottom<=r)&&(t.top>r||(n?t.left:t.right)>e)}function $r(t,e,r,n,i){i-=je(e);var o=Ir(t,e),a=Kr(e),s=0,A=e.text.length,l=!0,c=lt(e,t.doc.direction);if(c){var u=(t.options.lineWrapping?en:tn)(t,e,r,o,c,n,i);s=(l=1!=u.level)?u.from:u.to-1,A=l?u.to:u.from-1}var h,d,f=null,p=null,g=ot((function(e){var r=_r(t,o,e);return r.top+=a,r.bottom+=a,!!Zr(r,n,i,!1)&&(r.top<=i&&r.left<=n&&(f=e,p=r),!0)}),s,A),m=!1;if(p){var v=n-p.left<p.right-n,y=v==l;g=f+(y?0:1),d=y?"after":"before",h=v?p.left:p.right}else{l||g!=A&&g!=s||g++,d=0==g?"after":g==e.text.length?"before":_r(t,o,g-(l?1:0)).bottom+a<=i==l?"after":"before";var w=zr(t,te(r,g,d),"line",e,o);h=w.left,m=i<w.top?-1:i>=w.bottom?1:0}return Yr(r,g=it(e.text,g,1),d,m,n-h)}function tn(t,e,r,n,i,o,a){var s=ot((function(s){var A=i[s],l=1!=A.level;return Zr(zr(t,te(r,l?A.to:A.from,l?"before":"after"),"line",e,n),o,a,!0)}),0,i.length-1),A=i[s];if(s>0){var l=1!=A.level,c=zr(t,te(r,l?A.from:A.to,l?"after":"before"),"line",e,n);Zr(c,o,a,!0)&&c.top>a&&(A=i[s-1])}return A}function en(t,e,r,n,i,o,a){var s=qr(t,e,n,a),A=s.begin,l=s.end;/\s/.test(e.text.charAt(l-1))&&l--;for(var c=null,u=null,h=0;h<i.length;h++){var d=i[h];if(!(d.from>=l||d.to<=A)){var f=_r(t,n,1!=d.level?Math.min(l,d.to)-1:Math.max(A,d.from)).right,p=f<o?o-f+1e9:f-o;(!c||u>p)&&(c=d,u=p)}}return c||(c=i[i.length-1]),c.from<A&&(c={from:A,to:c.to,level:c.level}),c.to>l&&(c={from:c.from,to:l,level:c.level}),c}function rn(t){if(null!=t.cachedTextHeight)return t.cachedTextHeight;if(null==Ur){Ur=F("pre",null,"CodeMirror-line-like");for(var e=0;e<49;++e)Ur.appendChild(document.createTextNode("x")),Ur.appendChild(F("br"));Ur.appendChild(document.createTextNode("x"))}T(t.measure,Ur);var r=Ur.offsetHeight/50;return r>3&&(t.cachedTextHeight=r),k(t.measure),r||1}function nn(t){if(null!=t.cachedCharWidth)return t.cachedCharWidth;var e=F("span","xxxxxxxxxx"),r=F("pre",[e],"CodeMirror-line-like");T(t.measure,r);var n=e.getBoundingClientRect(),i=(n.right-n.left)/10;return i>2&&(t.cachedCharWidth=i),i||10}function on(t){for(var e=t.display,r={},n={},i=e.gutters.clientLeft,o=e.gutters.firstChild,a=0;o;o=o.nextSibling,++a){var s=t.display.gutterSpecs[a].className;r[s]=o.offsetLeft+o.clientLeft+i,n[s]=o.clientWidth}return{fixedPos:an(e),gutterTotalWidth:e.gutters.offsetWidth,gutterLeft:r,gutterWidth:n,wrapperWidth:e.wrapper.clientWidth}}function an(t){return t.scroller.getBoundingClientRect().left-t.sizer.getBoundingClientRect().left}function sn(t){var e=rn(t.display),r=t.options.lineWrapping,n=r&&Math.max(5,t.display.scroller.clientWidth/nn(t.display)-3);return function(i){if(Ne(t.doc,i))return 0;var o=0;if(i.widgets)for(var a=0;a<i.widgets.length;a++)i.widgets[a].height&&(o+=i.widgets[a].height);return r?o+(Math.ceil(i.text.length/n)||1)*e:o+e}}function An(t){var e=t.doc,r=sn(t);e.iter((function(t){var e=r(t);e!=t.height&&Xt(t,e)}))}function ln(t,e,r,n){var i=t.display;if(!r&&"true"==Bt(e).getAttribute("cm-not-content"))return null;var o,a,s=i.lineSpace.getBoundingClientRect();try{o=e.clientX-s.left,a=e.clientY-s.top}catch(t){return null}var A,l=Xr(t,o,a);if(n&&l.xRel>0&&(A=zt(t.doc,l.line).text).length==l.ch){var c=R(A,A.length,t.options.tabSize)-A.length;l=te(l.line,Math.max(0,Math.round((o-xr(t.display).left)/nn(t.display))-c))}return l}function cn(t,e){if(e>=t.display.viewTo)return null;if((e-=t.display.viewFrom)<0)return null;for(var r=t.display.view,n=0;n<r.length;n++)if((e-=r[n].size)<0)return n}function un(t,e,r,n){null==e&&(e=t.doc.first),null==r&&(r=t.doc.first+t.doc.size),n||(n=0);var i=t.display;if(n&&r<i.viewTo&&(null==i.updateLineNumbers||i.updateLineNumbers>e)&&(i.updateLineNumbers=e),t.curOp.viewChanged=!0,e>=i.viewTo)Ce&&Pe(t.doc,e)<i.viewTo&&dn(t);else if(r<=i.viewFrom)Ce&&He(t.doc,r+n)>i.viewFrom?dn(t):(i.viewFrom+=n,i.viewTo+=n);else if(e<=i.viewFrom&&r>=i.viewTo)dn(t);else if(e<=i.viewFrom){var o=fn(t,r,r+n,1);o?(i.view=i.view.slice(o.index),i.viewFrom=o.lineN,i.viewTo+=n):dn(t)}else if(r>=i.viewTo){var a=fn(t,e,e,-1);a?(i.view=i.view.slice(0,a.index),i.viewTo=a.lineN):dn(t)}else{var s=fn(t,e,e,-1),A=fn(t,r,r+n,1);s&&A?(i.view=i.view.slice(0,s.index).concat(ir(t,s.lineN,A.lineN)).concat(i.view.slice(A.index)),i.viewTo+=n):dn(t)}var l=i.externalMeasured;l&&(r<l.lineN?l.lineN+=n:e<l.lineN+l.size&&(i.externalMeasured=null))}function hn(t,e,r){t.curOp.viewChanged=!0;var n=t.display,i=t.display.externalMeasured;if(i&&e>=i.lineN&&e<i.lineN+i.size&&(n.externalMeasured=null),!(e<n.viewFrom||e>=n.viewTo)){var o=n.view[cn(t,e)];if(null!=o.node){var a=o.changes||(o.changes=[]);-1==H(a,r)&&a.push(r)}}}function dn(t){t.display.viewFrom=t.display.viewTo=t.doc.first,t.display.view=[],t.display.viewOffset=0}function fn(t,e,r,n){var i,o=cn(t,e),a=t.display.view;if(!Ce||r==t.doc.first+t.doc.size)return{index:o,lineN:r};for(var s=t.display.viewFrom,A=0;A<o;A++)s+=a[A].size;if(s!=e){if(n>0){if(o==a.length-1)return null;i=s+a[o].size-e,o++}else i=s-e;e+=i,r+=i}for(;Pe(t.doc,r)!=r;){if(o==(n<0?0:a.length-1))return null;r+=n*a[o-(n<0?1:0)].size,o+=n}return{index:o,lineN:r}}function pn(t){for(var e=t.display.view,r=0,n=0;n<e.length;n++){var i=e[n];i.hidden||i.node&&!i.changes||++r}return r}function gn(t){t.display.input.showSelection(t.display.input.prepareSelection())}function mn(t,e){void 0===e&&(e=!0);for(var r=t.doc,n={},i=n.cursors=document.createDocumentFragment(),o=n.selection=document.createDocumentFragment(),a=0;a<r.sel.ranges.length;a++)if(e||a!=r.sel.primIndex){var s=r.sel.ranges[a];if(!(s.from().line>=t.display.viewTo||s.to().line<t.display.viewFrom)){var A=s.empty();(A||t.options.showCursorWhenSelecting)&&vn(t,s.head,i),A||wn(t,s,o)}}return n}function vn(t,e,r){var n=zr(t,e,"div",null,null,!t.options.singleCursorHeightPerLine),i=r.appendChild(F("div"," ","CodeMirror-cursor"));if(i.style.left=n.left+"px",i.style.top=n.top+"px",i.style.height=Math.max(0,n.bottom-n.top)*t.options.cursorHeight+"px",n.other){var o=r.appendChild(F("div"," ","CodeMirror-cursor CodeMirror-secondarycursor"));o.style.display="",o.style.left=n.other.left+"px",o.style.top=n.other.top+"px",o.style.height=.85*(n.other.bottom-n.other.top)+"px"}}function yn(t,e){return t.top-e.top||t.left-e.left}function wn(t,e,r){var n=t.display,i=t.doc,o=document.createDocumentFragment(),a=xr(t.display),s=a.left,A=Math.max(n.sizerWidth,Sr(t)-n.sizer.offsetLeft)-a.right,l="ltr"==i.direction;function c(t,e,r,n){e<0&&(e=0),e=Math.round(e),n=Math.round(n),o.appendChild(F("div",null,"CodeMirror-selected","position: absolute; left: "+t+"px;\n top: "+e+"px; width: "+(null==r?A-t:r)+"px;\n height: "+(n-e)+"px"))}function u(e,r,n){var o,a,u=zt(i,e),h=u.text.length;function d(r,n){return Vr(t,te(e,r),"div",u,n)}function f(e,r,n){var i=Jr(t,u,null,e),o="ltr"==r==("after"==n)?"left":"right";return d("after"==n?i.begin:i.end-(/\s/.test(u.text.charAt(i.end-1))?2:1),o)[o]}var p=lt(u,i.direction);return function(t,e,r,n){if(!t)return n(e,r,"ltr",0);for(var i=!1,o=0;o<t.length;++o){var a=t[o];(a.from<r&&a.to>e||e==r&&a.to==e)&&(n(Math.max(a.from,e),Math.min(a.to,r),1==a.level?"rtl":"ltr",o),i=!0)}i||n(e,r,"ltr")}(p,r||0,null==n?h:n,(function(t,e,i,u){var g="ltr"==i,m=d(t,g?"left":"right"),v=d(e-1,g?"right":"left"),y=null==r&&0==t,w=null==n&&e==h,b=0==u,C=!p||u==p.length-1;if(v.top-m.top<=3){var B=(l?w:y)&&C,x=(l?y:w)&&b?s:(g?m:v).left,E=B?A:(g?v:m).right;c(x,m.top,E-x,m.bottom)}else{var S,k,T,F;g?(S=l&&y&&b?s:m.left,k=l?A:f(t,i,"before"),T=l?s:f(e,i,"after"),F=l&&w&&C?A:v.right):(S=l?f(t,i,"before"):s,k=!l&&y&&b?A:m.right,T=!l&&w&&C?s:v.left,F=l?f(e,i,"after"):A),c(S,m.top,k-S,m.bottom),m.bottom<v.top&&c(s,m.bottom,null,v.top),c(T,v.top,F-T,v.bottom)}(!o||yn(m,o)<0)&&(o=m),yn(v,o)<0&&(o=v),(!a||yn(m,a)<0)&&(a=m),yn(v,a)<0&&(a=v)})),{start:o,end:a}}var h=e.from(),d=e.to();if(h.line==d.line)u(h.line,h.ch,d.ch);else{var f=zt(i,h.line),p=zt(i,d.line),g=Re(f)==Re(p),m=u(h.line,h.ch,g?f.text.length+1:null).end,v=u(d.line,g?0:null,d.ch).start;g&&(m.top<v.top-2?(c(m.right,m.top,null,m.bottom),c(s,v.top,v.left,v.bottom)):c(m.right,m.top,v.left-m.right,m.bottom)),m.bottom<v.top&&c(s,m.bottom,null,v.top)}r.appendChild(o)}function bn(t){if(t.state.focused){var e=t.display;clearInterval(e.blinker);var r=!0;e.cursorDiv.style.visibility="",t.options.cursorBlinkRate>0?e.blinker=setInterval((function(){t.hasFocus()||En(t),e.cursorDiv.style.visibility=(r=!r)?"":"hidden"}),t.options.cursorBlinkRate):t.options.cursorBlinkRate<0&&(e.cursorDiv.style.visibility="hidden")}}function Cn(t){t.state.focused||(t.display.input.focus(),xn(t))}function Bn(t){t.state.delayingBlurEvent=!0,setTimeout((function(){t.state.delayingBlurEvent&&(t.state.delayingBlurEvent=!1,En(t))}),100)}function xn(t,e){t.state.delayingBlurEvent&&(t.state.delayingBlurEvent=!1),"nocursor"!=t.options.readOnly&&(t.state.focused||(ft(t,"focus",t,e),t.state.focused=!0,U(t.display.wrapper,"CodeMirror-focused"),t.curOp||t.display.selForContextMenu==t.doc.sel||(t.display.input.reset(),A&&setTimeout((function(){return t.display.input.reset(!0)}),20)),t.display.input.receivedFocus()),bn(t))}function En(t,e){t.state.delayingBlurEvent||(t.state.focused&&(ft(t,"blur",t,e),t.state.focused=!1,S(t.display.wrapper,"CodeMirror-focused")),clearInterval(t.display.blinker),setTimeout((function(){t.state.focused||(t.display.shift=!1)}),150))}function Sn(t){for(var e=t.display,r=e.lineDiv.offsetTop,n=0;n<e.view.length;n++){var i=e.view[n],o=t.options.lineWrapping,A=void 0,l=0;if(!i.hidden){if(a&&s<8){var c=i.node.offsetTop+i.node.offsetHeight;A=c-r,r=c}else{var u=i.node.getBoundingClientRect();A=u.bottom-u.top,!o&&i.text.firstChild&&(l=i.text.firstChild.getBoundingClientRect().right-u.left-1)}var h=i.line.height-A;if((h>.005||h<-.005)&&(Xt(i.line,A),kn(i.line),i.rest))for(var d=0;d<i.rest.length;d++)kn(i.rest[d]);if(l>t.display.sizerWidth){var f=Math.ceil(l/nn(t.display));f>t.display.maxLineLength&&(t.display.maxLineLength=f,t.display.maxLine=i.line,t.display.maxLineChanged=!0)}}}}function kn(t){if(t.widgets)for(var e=0;e<t.widgets.length;++e){var r=t.widgets[e],n=r.node.parentNode;n&&(r.height=n.offsetHeight)}}function Tn(t,e,r){var n=r&&null!=r.top?Math.max(0,r.top):t.scroller.scrollTop;n=Math.floor(n-Cr(t));var i=r&&null!=r.bottom?r.bottom:n+t.wrapper.clientHeight,o=Jt(e,n),a=Jt(e,i);if(r&&r.ensure){var s=r.ensure.from.line,A=r.ensure.to.line;s<o?(o=s,a=Jt(e,je(zt(e,s))+t.wrapper.clientHeight)):Math.min(A,e.lastLine())>=a&&(o=Jt(e,je(zt(e,A))-t.wrapper.clientHeight),a=A)}return{from:o,to:Math.max(a,o+1)}}function Fn(t,e){var r=t.display,n=rn(t.display);e.top<0&&(e.top=0);var i=t.curOp&&null!=t.curOp.scrollTop?t.curOp.scrollTop:r.scroller.scrollTop,o=kr(t),a={};e.bottom-e.top>o&&(e.bottom=e.top+o);var s=t.doc.height+Br(r),A=e.top<n,l=e.bottom>s-n;if(e.top<i)a.scrollTop=A?0:e.top;else if(e.bottom>i+o){var c=Math.min(e.top,(l?s:e.bottom)-o);c!=i&&(a.scrollTop=c)}var u=t.options.fixedGutter?0:r.gutters.offsetWidth,h=t.curOp&&null!=t.curOp.scrollLeft?t.curOp.scrollLeft:r.scroller.scrollLeft-u,d=Sr(t)-r.gutters.offsetWidth,f=e.right-e.left>d;return f&&(e.right=e.left+d),e.left<10?a.scrollLeft=0:e.left<h?a.scrollLeft=Math.max(0,e.left+u-(f?0:10)):e.right>d+h-3&&(a.scrollLeft=e.right+(f?0:10)-d),a}function Ln(t,e){null!=e&&(Un(t),t.curOp.scrollTop=(null==t.curOp.scrollTop?t.doc.scrollTop:t.curOp.scrollTop)+e)}function In(t){Un(t);var e=t.getCursor();t.curOp.scrollToPos={from:e,to:e,margin:t.options.cursorScrollMargin}}function _n(t,e,r){null==e&&null==r||Un(t),null!=e&&(t.curOp.scrollLeft=e),null!=r&&(t.curOp.scrollTop=r)}function Un(t){var e=t.curOp.scrollToPos;e&&(t.curOp.scrollToPos=null,On(t,Wr(t,e.from),Wr(t,e.to),e.margin))}function On(t,e,r,n){var i=Fn(t,{left:Math.min(e.left,r.left),top:Math.min(e.top,r.top)-n,right:Math.max(e.right,r.right),bottom:Math.max(e.bottom,r.bottom)+n});_n(t,i.scrollLeft,i.scrollTop)}function Dn(t,e){Math.abs(t.doc.scrollTop-e)<2||(r||Ai(t,{top:e}),Qn(t,e,!0),r&&Ai(t),ni(t,100))}function Qn(t,e,r){e=Math.max(0,Math.min(t.display.scroller.scrollHeight-t.display.scroller.clientHeight,e)),(t.display.scroller.scrollTop!=e||r)&&(t.doc.scrollTop=e,t.display.scrollbars.setScrollTop(e),t.display.scroller.scrollTop!=e&&(t.display.scroller.scrollTop=e))}function Mn(t,e,r,n){e=Math.max(0,Math.min(e,t.display.scroller.scrollWidth-t.display.scroller.clientWidth)),(r?e==t.doc.scrollLeft:Math.abs(t.doc.scrollLeft-e)<2)&&!n||(t.doc.scrollLeft=e,ui(t),t.display.scroller.scrollLeft!=e&&(t.display.scroller.scrollLeft=e),t.display.scrollbars.setScrollLeft(e))}function Rn(t){var e=t.display,r=e.gutters.offsetWidth,n=Math.round(t.doc.height+Br(t.display));return{clientHeight:e.scroller.clientHeight,viewHeight:e.wrapper.clientHeight,scrollWidth:e.scroller.scrollWidth,clientWidth:e.scroller.clientWidth,viewWidth:e.wrapper.clientWidth,barLeft:t.options.fixedGutter?r:0,docHeight:n,scrollHeight:n+Er(t)+e.barHeight,nativeBarWidth:e.nativeBarWidth,gutterWidth:r}}var Pn=function(t,e,r){this.cm=r;var n=this.vert=F("div",[F("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),i=this.horiz=F("div",[F("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");n.tabIndex=i.tabIndex=-1,t(n),t(i),ut(n,"scroll",(function(){n.clientHeight&&e(n.scrollTop,"vertical")})),ut(i,"scroll",(function(){i.clientWidth&&e(i.scrollLeft,"horizontal")})),this.checkedZeroWidth=!1,a&&s<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Pn.prototype.update=function(t){var e=t.scrollWidth>t.clientWidth+1,r=t.scrollHeight>t.clientHeight+1,n=t.nativeBarWidth;if(r){this.vert.style.display="block",this.vert.style.bottom=e?n+"px":"0";var i=t.viewHeight-(e?n:0);this.vert.firstChild.style.height=Math.max(0,t.scrollHeight-t.clientHeight+i)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(e){this.horiz.style.display="block",this.horiz.style.right=r?n+"px":"0",this.horiz.style.left=t.barLeft+"px";var o=t.viewWidth-t.barLeft-(r?n:0);this.horiz.firstChild.style.width=Math.max(0,t.scrollWidth-t.clientWidth+o)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&t.clientHeight>0&&(0==n&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:r?n:0,bottom:e?n:0}},Pn.prototype.setScrollLeft=function(t){this.horiz.scrollLeft!=t&&(this.horiz.scrollLeft=t),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Pn.prototype.setScrollTop=function(t){this.vert.scrollTop!=t&&(this.vert.scrollTop=t),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Pn.prototype.zeroWidthHack=function(){var t=v&&!d?"12px":"18px";this.horiz.style.height=this.vert.style.width=t,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new P,this.disableVert=new P},Pn.prototype.enableZeroWidthBar=function(t,e,r){t.style.pointerEvents="auto",e.set(1e3,(function n(){var i=t.getBoundingClientRect();("vert"==r?document.elementFromPoint(i.right-1,(i.top+i.bottom)/2):document.elementFromPoint((i.right+i.left)/2,i.bottom-1))!=t?t.style.pointerEvents="none":e.set(1e3,n)}))},Pn.prototype.clear=function(){var t=this.horiz.parentNode;t.removeChild(this.horiz),t.removeChild(this.vert)};var Hn=function(){};function Nn(t,e){e||(e=Rn(t));var r=t.display.barWidth,n=t.display.barHeight;Kn(t,e);for(var i=0;i<4&&r!=t.display.barWidth||n!=t.display.barHeight;i++)r!=t.display.barWidth&&t.options.lineWrapping&&Sn(t),Kn(t,Rn(t)),r=t.display.barWidth,n=t.display.barHeight}function Kn(t,e){var r=t.display,n=r.scrollbars.update(e);r.sizer.style.paddingRight=(r.barWidth=n.right)+"px",r.sizer.style.paddingBottom=(r.barHeight=n.bottom)+"px",r.heightForcer.style.borderBottom=n.bottom+"px solid transparent",n.right&&n.bottom?(r.scrollbarFiller.style.display="block",r.scrollbarFiller.style.height=n.bottom+"px",r.scrollbarFiller.style.width=n.right+"px"):r.scrollbarFiller.style.display="",n.bottom&&t.options.coverGutterNextToScrollbar&&t.options.fixedGutter?(r.gutterFiller.style.display="block",r.gutterFiller.style.height=n.bottom+"px",r.gutterFiller.style.width=e.gutterWidth+"px"):r.gutterFiller.style.display=""}Hn.prototype.update=function(){return{bottom:0,right:0}},Hn.prototype.setScrollLeft=function(){},Hn.prototype.setScrollTop=function(){},Hn.prototype.clear=function(){};var jn={native:Pn,null:Hn};function Gn(t){t.display.scrollbars&&(t.display.scrollbars.clear(),t.display.scrollbars.addClass&&S(t.display.wrapper,t.display.scrollbars.addClass)),t.display.scrollbars=new jn[t.options.scrollbarStyle]((function(e){t.display.wrapper.insertBefore(e,t.display.scrollbarFiller),ut(e,"mousedown",(function(){t.state.focused&&setTimeout((function(){return t.display.input.focus()}),0)})),e.setAttribute("cm-not-content","true")}),(function(e,r){"horizontal"==r?Mn(t,e):Dn(t,e)}),t),t.display.scrollbars.addClass&&U(t.display.wrapper,t.display.scrollbars.addClass)}var Vn=0;function zn(t){var e;t.curOp={cm:t,viewChanged:!1,startHeight:t.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Vn},e=t.curOp,or?or.ops.push(e):e.ownsGroup=or={ops:[e],delayedCallbacks:[]}}function Wn(t){var e=t.curOp;e&&function(t,e){var r=t.ownsGroup;if(r)try{!function(t){var e=t.delayedCallbacks,r=0;do{for(;r<e.length;r++)e[r].call(null);for(var n=0;n<t.ops.length;n++){var i=t.ops[n];if(i.cursorActivityHandlers)for(;i.cursorActivityCalled<i.cursorActivityHandlers.length;)i.cursorActivityHandlers[i.cursorActivityCalled++].call(null,i.cm)}}while(r<e.length)}(r)}finally{or=null,e(r)}}(e,(function(t){for(var e=0;e<t.ops.length;e++)t.ops[e].cm.curOp=null;!function(t){for(var e=t.ops,r=0;r<e.length;r++)Yn(e[r]);for(var n=0;n<e.length;n++)Xn(e[n]);for(var i=0;i<e.length;i++)qn(e[i]);for(var o=0;o<e.length;o++)Jn(e[o]);for(var a=0;a<e.length;a++)Zn(e[a])}(t)}))}function Yn(t){var e=t.cm,r=e.display;!function(t){var e=t.display;!e.scrollbarsClipped&&e.scroller.offsetWidth&&(e.nativeBarWidth=e.scroller.offsetWidth-e.scroller.clientWidth,e.heightForcer.style.height=Er(t)+"px",e.sizer.style.marginBottom=-e.nativeBarWidth+"px",e.sizer.style.borderRightWidth=Er(t)+"px",e.scrollbarsClipped=!0)}(e),t.updateMaxLine&&Ve(e),t.mustUpdate=t.viewChanged||t.forceUpdate||null!=t.scrollTop||t.scrollToPos&&(t.scrollToPos.from.line<r.viewFrom||t.scrollToPos.to.line>=r.viewTo)||r.maxLineChanged&&e.options.lineWrapping,t.update=t.mustUpdate&&new oi(e,t.mustUpdate&&{top:t.scrollTop,ensure:t.scrollToPos},t.forceUpdate)}function Xn(t){t.updatedDisplay=t.mustUpdate&&ai(t.cm,t.update)}function qn(t){var e=t.cm,r=e.display;t.updatedDisplay&&Sn(e),t.barMeasure=Rn(e),r.maxLineChanged&&!e.options.lineWrapping&&(t.adjustWidthTo=Fr(e,r.maxLine,r.maxLine.text.length).left+3,e.display.sizerWidth=t.adjustWidthTo,t.barMeasure.scrollWidth=Math.max(r.scroller.clientWidth,r.sizer.offsetLeft+t.adjustWidthTo+Er(e)+e.display.barWidth),t.maxScrollLeft=Math.max(0,r.sizer.offsetLeft+t.adjustWidthTo-Sr(e))),(t.updatedDisplay||t.selectionChanged)&&(t.preparedSelection=r.input.prepareSelection())}function Jn(t){var e=t.cm;null!=t.adjustWidthTo&&(e.display.sizer.style.minWidth=t.adjustWidthTo+"px",t.maxScrollLeft<e.doc.scrollLeft&&Mn(e,Math.min(e.display.scroller.scrollLeft,t.maxScrollLeft),!0),e.display.maxLineChanged=!1);var r=t.focus&&t.focus==_();t.preparedSelection&&e.display.input.showSelection(t.preparedSelection,r),(t.updatedDisplay||t.startHeight!=e.doc.height)&&Nn(e,t.barMeasure),t.updatedDisplay&&ci(e,t.barMeasure),t.selectionChanged&&bn(e),e.state.focused&&t.updateInput&&e.display.input.reset(t.typing),r&&Cn(t.cm)}function Zn(t){var e=t.cm,r=e.display,n=e.doc;t.updatedDisplay&&si(e,t.update),null==r.wheelStartX||null==t.scrollTop&&null==t.scrollLeft&&!t.scrollToPos||(r.wheelStartX=r.wheelStartY=null),null!=t.scrollTop&&Qn(e,t.scrollTop,t.forceScroll),null!=t.scrollLeft&&Mn(e,t.scrollLeft,!0,!0),t.scrollToPos&&function(t,e){if(!pt(t,"scrollCursorIntoView")){var r=t.display,n=r.sizer.getBoundingClientRect(),i=null;if(e.top+n.top<0?i=!0:e.bottom+n.top>(window.innerHeight||document.documentElement.clientHeight)&&(i=!1),null!=i&&!f){var o=F("div","",null,"position: absolute;\n top: "+(e.top-r.viewOffset-Cr(t.display))+"px;\n height: "+(e.bottom-e.top+Er(t)+r.barHeight)+"px;\n left: "+e.left+"px; width: "+Math.max(2,e.right-e.left)+"px;");t.display.lineSpace.appendChild(o),o.scrollIntoView(i),t.display.lineSpace.removeChild(o)}}}(e,function(t,e,r,n){var i;null==n&&(n=0),t.options.lineWrapping||e!=r||(r="before"==(e=e.ch?te(e.line,"before"==e.sticky?e.ch-1:e.ch,"after"):e).sticky?te(e.line,e.ch+1,"before"):e);for(var o=0;o<5;o++){var a=!1,s=zr(t,e),A=r&&r!=e?zr(t,r):s,l=Fn(t,i={left:Math.min(s.left,A.left),top:Math.min(s.top,A.top)-n,right:Math.max(s.left,A.left),bottom:Math.max(s.bottom,A.bottom)+n}),c=t.doc.scrollTop,u=t.doc.scrollLeft;if(null!=l.scrollTop&&(Dn(t,l.scrollTop),Math.abs(t.doc.scrollTop-c)>1&&(a=!0)),null!=l.scrollLeft&&(Mn(t,l.scrollLeft),Math.abs(t.doc.scrollLeft-u)>1&&(a=!0)),!a)break}return i}(e,se(n,t.scrollToPos.from),se(n,t.scrollToPos.to),t.scrollToPos.margin));var i=t.maybeHiddenMarkers,o=t.maybeUnhiddenMarkers;if(i)for(var a=0;a<i.length;++a)i[a].lines.length||ft(i[a],"hide");if(o)for(var s=0;s<o.length;++s)o[s].lines.length&&ft(o[s],"unhide");r.wrapper.offsetHeight&&(n.scrollTop=e.display.scroller.scrollTop),t.changeObjs&&ft(e,"changes",e,t.changeObjs),t.update&&t.update.finish()}function $n(t,e){if(t.curOp)return e();zn(t);try{return e()}finally{Wn(t)}}function ti(t,e){return function(){if(t.curOp)return e.apply(t,arguments);zn(t);try{return e.apply(t,arguments)}finally{Wn(t)}}}function ei(t){return function(){if(this.curOp)return t.apply(this,arguments);zn(this);try{return t.apply(this,arguments)}finally{Wn(this)}}}function ri(t){return function(){var e=this.cm;if(!e||e.curOp)return t.apply(this,arguments);zn(e);try{return t.apply(this,arguments)}finally{Wn(e)}}}function ni(t,e){t.doc.highlightFrontier<t.display.viewTo&&t.state.highlight.set(e,Q(ii,t))}function ii(t){var e=t.doc;if(!(e.highlightFrontier>=t.display.viewTo)){var r=+new Date+t.options.workTime,n=de(t,e.highlightFrontier),i=[];e.iter(n.line,Math.min(e.first+e.size,t.display.viewTo+500),(function(o){if(n.line>=t.display.viewFrom){var a=o.styles,s=o.text.length>t.options.maxHighlightLength?Kt(e.mode,n.state):null,A=ue(t,o,n,!0);s&&(n.state=s),o.styles=A.styles;var l=o.styleClasses,c=A.classes;c?o.styleClasses=c:l&&(o.styleClasses=null);for(var u=!a||a.length!=o.styles.length||l!=c&&(!l||!c||l.bgClass!=c.bgClass||l.textClass!=c.textClass),h=0;!u&&h<a.length;++h)u=a[h]!=o.styles[h];u&&i.push(n.line),o.stateAfter=n.save(),n.nextLine()}else o.text.length<=t.options.maxHighlightLength&&fe(t,o.text,n),o.stateAfter=n.line%5==0?n.save():null,n.nextLine();if(+new Date>r)return ni(t,t.options.workDelay),!0})),e.highlightFrontier=n.line,e.modeFrontier=Math.max(e.modeFrontier,n.line),i.length&&$n(t,(function(){for(var e=0;e<i.length;e++)hn(t,i[e],"text")}))}}var oi=function(t,e,r){var n=t.display;this.viewport=e,this.visible=Tn(n,t.doc,e),this.editorIsHidden=!n.wrapper.offsetWidth,this.wrapperHeight=n.wrapper.clientHeight,this.wrapperWidth=n.wrapper.clientWidth,this.oldDisplayWidth=Sr(t),this.force=r,this.dims=on(t),this.events=[]};function ai(t,e){var r=t.display,n=t.doc;if(e.editorIsHidden)return dn(t),!1;if(!e.force&&e.visible.from>=r.viewFrom&&e.visible.to<=r.viewTo&&(null==r.updateLineNumbers||r.updateLineNumbers>=r.viewTo)&&r.renderedView==r.view&&0==pn(t))return!1;hi(t)&&(dn(t),e.dims=on(t));var i=n.first+n.size,o=Math.max(e.visible.from-t.options.viewportMargin,n.first),a=Math.min(i,e.visible.to+t.options.viewportMargin);r.viewFrom<o&&o-r.viewFrom<20&&(o=Math.max(n.first,r.viewFrom)),r.viewTo>a&&r.viewTo-a<20&&(a=Math.min(i,r.viewTo)),Ce&&(o=Pe(t.doc,o),a=He(t.doc,a));var s=o!=r.viewFrom||a!=r.viewTo||r.lastWrapHeight!=e.wrapperHeight||r.lastWrapWidth!=e.wrapperWidth;!function(t,e,r){var n=t.display;0==n.view.length||e>=n.viewTo||r<=n.viewFrom?(n.view=ir(t,e,r),n.viewFrom=e):(n.viewFrom>e?n.view=ir(t,e,n.viewFrom).concat(n.view):n.viewFrom<e&&(n.view=n.view.slice(cn(t,e))),n.viewFrom=e,n.viewTo<r?n.view=n.view.concat(ir(t,n.viewTo,r)):n.viewTo>r&&(n.view=n.view.slice(0,cn(t,r)))),n.viewTo=r}(t,o,a),r.viewOffset=je(zt(t.doc,r.viewFrom)),t.display.mover.style.top=r.viewOffset+"px";var l=pn(t);if(!s&&0==l&&!e.force&&r.renderedView==r.view&&(null==r.updateLineNumbers||r.updateLineNumbers>=r.viewTo))return!1;var c=function(t){if(t.hasFocus())return null;var e=_();if(!e||!I(t.display.lineDiv,e))return null;var r={activeElt:e};if(window.getSelection){var n=window.getSelection();n.anchorNode&&n.extend&&I(t.display.lineDiv,n.anchorNode)&&(r.anchorNode=n.anchorNode,r.anchorOffset=n.anchorOffset,r.focusNode=n.focusNode,r.focusOffset=n.focusOffset)}return r}(t);return l>4&&(r.lineDiv.style.display="none"),function(t,e,r){var n=t.display,i=t.options.lineNumbers,o=n.lineDiv,a=o.firstChild;function s(e){var r=e.nextSibling;return A&&v&&t.display.currentWheelTarget==e?e.style.display="none":e.parentNode.removeChild(e),r}for(var l=n.view,c=n.viewFrom,u=0;u<l.length;u++){var h=l[u];if(h.hidden);else if(h.node&&h.node.parentNode==o){for(;a!=h.node;)a=s(a);var d=i&&null!=e&&e<=c&&h.lineNumber;h.changes&&(H(h.changes,"gutter")>-1&&(d=!1),lr(t,h,c,r)),d&&(k(h.lineNumber),h.lineNumber.appendChild(document.createTextNode($t(t.options,c)))),a=h.node.nextSibling}else{var f=gr(t,h,c,r);o.insertBefore(f,a)}c+=h.size}for(;a;)a=s(a)}(t,r.updateLineNumbers,e.dims),l>4&&(r.lineDiv.style.display=""),r.renderedView=r.view,function(t){if(t&&t.activeElt&&t.activeElt!=_()&&(t.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(t.activeElt.nodeName)&&t.anchorNode&&I(document.body,t.anchorNode)&&I(document.body,t.focusNode))){var e=window.getSelection(),r=document.createRange();r.setEnd(t.anchorNode,t.anchorOffset),r.collapse(!1),e.removeAllRanges(),e.addRange(r),e.extend(t.focusNode,t.focusOffset)}}(c),k(r.cursorDiv),k(r.selectionDiv),r.gutters.style.height=r.sizer.style.minHeight=0,s&&(r.lastWrapHeight=e.wrapperHeight,r.lastWrapWidth=e.wrapperWidth,ni(t,400)),r.updateLineNumbers=null,!0}function si(t,e){for(var r=e.viewport,n=!0;;n=!1){if(n&&t.options.lineWrapping&&e.oldDisplayWidth!=Sr(t))n&&(e.visible=Tn(t.display,t.doc,r));else if(r&&null!=r.top&&(r={top:Math.min(t.doc.height+Br(t.display)-kr(t),r.top)}),e.visible=Tn(t.display,t.doc,r),e.visible.from>=t.display.viewFrom&&e.visible.to<=t.display.viewTo)break;if(!ai(t,e))break;Sn(t);var i=Rn(t);gn(t),Nn(t,i),ci(t,i),e.force=!1}e.signal(t,"update",t),t.display.viewFrom==t.display.reportedViewFrom&&t.display.viewTo==t.display.reportedViewTo||(e.signal(t,"viewportChange",t,t.display.viewFrom,t.display.viewTo),t.display.reportedViewFrom=t.display.viewFrom,t.display.reportedViewTo=t.display.viewTo)}function Ai(t,e){var r=new oi(t,e);if(ai(t,r)){Sn(t),si(t,r);var n=Rn(t);gn(t),Nn(t,n),ci(t,n),r.finish()}}function li(t){var e=t.gutters.offsetWidth;t.sizer.style.marginLeft=e+"px"}function ci(t,e){t.display.sizer.style.minHeight=e.docHeight+"px",t.display.heightForcer.style.top=e.docHeight+"px",t.display.gutters.style.height=e.docHeight+t.display.barHeight+Er(t)+"px"}function ui(t){var e=t.display,r=e.view;if(e.alignWidgets||e.gutters.firstChild&&t.options.fixedGutter){for(var n=an(e)-e.scroller.scrollLeft+t.doc.scrollLeft,i=e.gutters.offsetWidth,o=n+"px",a=0;a<r.length;a++)if(!r[a].hidden){t.options.fixedGutter&&(r[a].gutter&&(r[a].gutter.style.left=o),r[a].gutterBackground&&(r[a].gutterBackground.style.left=o));var s=r[a].alignable;if(s)for(var A=0;A<s.length;A++)s[A].style.left=o}t.options.fixedGutter&&(e.gutters.style.left=n+i+"px")}}function hi(t){if(!t.options.lineNumbers)return!1;var e=t.doc,r=$t(t.options,e.first+e.size-1),n=t.display;if(r.length!=n.lineNumChars){var i=n.measure.appendChild(F("div",[F("div",r)],"CodeMirror-linenumber CodeMirror-gutter-elt")),o=i.firstChild.offsetWidth,a=i.offsetWidth-o;return n.lineGutter.style.width="",n.lineNumInnerWidth=Math.max(o,n.lineGutter.offsetWidth-a)+1,n.lineNumWidth=n.lineNumInnerWidth+a,n.lineNumChars=n.lineNumInnerWidth?r.length:-1,n.lineGutter.style.width=n.lineNumWidth+"px",li(t.display),!0}return!1}function di(t,e){for(var r=[],n=!1,i=0;i<t.length;i++){var o=t[i],a=null;if("string"!=typeof o&&(a=o.style,o=o.className),"CodeMirror-linenumbers"==o){if(!e)continue;n=!0}r.push({className:o,style:a})}return e&&!n&&r.push({className:"CodeMirror-linenumbers",style:null}),r}function fi(t){var e=t.gutters,r=t.gutterSpecs;k(e),t.lineGutter=null;for(var n=0;n<r.length;++n){var i=r[n],o=i.className,a=i.style,s=e.appendChild(F("div",null,"CodeMirror-gutter "+o));a&&(s.style.cssText=a),"CodeMirror-linenumbers"==o&&(t.lineGutter=s,s.style.width=(t.lineNumWidth||1)+"px")}e.style.display=r.length?"":"none",li(t)}function pi(t){fi(t.display),un(t),ui(t)}function gi(t,e,n,i){var o=this;this.input=n,o.scrollbarFiller=F("div",null,"CodeMirror-scrollbar-filler"),o.scrollbarFiller.setAttribute("cm-not-content","true"),o.gutterFiller=F("div",null,"CodeMirror-gutter-filler"),o.gutterFiller.setAttribute("cm-not-content","true"),o.lineDiv=L("div",null,"CodeMirror-code"),o.selectionDiv=F("div",null,null,"position: relative; z-index: 1"),o.cursorDiv=F("div",null,"CodeMirror-cursors"),o.measure=F("div",null,"CodeMirror-measure"),o.lineMeasure=F("div",null,"CodeMirror-measure"),o.lineSpace=L("div",[o.measure,o.lineMeasure,o.selectionDiv,o.cursorDiv,o.lineDiv],null,"position: relative; outline: none");var l=L("div",[o.lineSpace],"CodeMirror-lines");o.mover=F("div",[l],null,"position: relative"),o.sizer=F("div",[o.mover],"CodeMirror-sizer"),o.sizerWidth=null,o.heightForcer=F("div",null,null,"position: absolute; height: 50px; width: 1px;"),o.gutters=F("div",null,"CodeMirror-gutters"),o.lineGutter=null,o.scroller=F("div",[o.sizer,o.heightForcer,o.gutters],"CodeMirror-scroll"),o.scroller.setAttribute("tabIndex","-1"),o.wrapper=F("div",[o.scrollbarFiller,o.gutterFiller,o.scroller],"CodeMirror"),a&&s<8&&(o.gutters.style.zIndex=-1,o.scroller.style.paddingRight=0),A||r&&m||(o.scroller.draggable=!0),t&&(t.appendChild?t.appendChild(o.wrapper):t(o.wrapper)),o.viewFrom=o.viewTo=e.first,o.reportedViewFrom=o.reportedViewTo=e.first,o.view=[],o.renderedView=null,o.externalMeasured=null,o.viewOffset=0,o.lastWrapHeight=o.lastWrapWidth=0,o.updateLineNumbers=null,o.nativeBarWidth=o.barHeight=o.barWidth=0,o.scrollbarsClipped=!1,o.lineNumWidth=o.lineNumInnerWidth=o.lineNumChars=null,o.alignWidgets=!1,o.cachedCharWidth=o.cachedTextHeight=o.cachedPaddingH=null,o.maxLine=null,o.maxLineLength=0,o.maxLineChanged=!1,o.wheelDX=o.wheelDY=o.wheelStartX=o.wheelStartY=null,o.shift=!1,o.selForContextMenu=null,o.activeTouch=null,o.gutterSpecs=di(i.gutters,i.lineNumbers),fi(o),n.init(o)}oi.prototype.signal=function(t,e){mt(t,e)&&this.events.push(arguments)},oi.prototype.finish=function(){for(var t=0;t<this.events.length;t++)ft.apply(null,this.events[t])};var mi=0,vi=null;function yi(t){var e=t.wheelDeltaX,r=t.wheelDeltaY;return null==e&&t.detail&&t.axis==t.HORIZONTAL_AXIS&&(e=t.detail),null==r&&t.detail&&t.axis==t.VERTICAL_AXIS?r=t.detail:null==r&&(r=t.wheelDelta),{x:e,y:r}}function wi(t){var e=yi(t);return e.x*=vi,e.y*=vi,e}function bi(t,e){var n=yi(e),i=n.x,o=n.y,a=t.display,s=a.scroller,l=s.scrollWidth>s.clientWidth,c=s.scrollHeight>s.clientHeight;if(i&&l||o&&c){if(o&&v&&A)t:for(var h=e.target,d=a.view;h!=s;h=h.parentNode)for(var f=0;f<d.length;f++)if(d[f].node==h){t.display.currentWheelTarget=h;break t}if(i&&!r&&!u&&null!=vi)return o&&c&&Dn(t,Math.max(0,s.scrollTop+o*vi)),Mn(t,Math.max(0,s.scrollLeft+i*vi)),(!o||o&&c)&&yt(e),void(a.wheelStartX=null);if(o&&null!=vi){var p=o*vi,g=t.doc.scrollTop,m=g+a.wrapper.clientHeight;p<0?g=Math.max(0,g+p-50):m=Math.min(t.doc.height,m+p+50),Ai(t,{top:g,bottom:m})}mi<20&&(null==a.wheelStartX?(a.wheelStartX=s.scrollLeft,a.wheelStartY=s.scrollTop,a.wheelDX=i,a.wheelDY=o,setTimeout((function(){if(null!=a.wheelStartX){var t=s.scrollLeft-a.wheelStartX,e=s.scrollTop-a.wheelStartY,r=e&&a.wheelDY&&e/a.wheelDY||t&&a.wheelDX&&t/a.wheelDX;a.wheelStartX=a.wheelStartY=null,r&&(vi=(vi*mi+r)/(mi+1),++mi)}}),200)):(a.wheelDX+=i,a.wheelDY+=o))}}a?vi=-.53:r?vi=15:c?vi=-.7:h&&(vi=-1/3);var Ci=function(t,e){this.ranges=t,this.primIndex=e};Ci.prototype.primary=function(){return this.ranges[this.primIndex]},Ci.prototype.equals=function(t){if(t==this)return!0;if(t.primIndex!=this.primIndex||t.ranges.length!=this.ranges.length)return!1;for(var e=0;e<this.ranges.length;e++){var r=this.ranges[e],n=t.ranges[e];if(!re(r.anchor,n.anchor)||!re(r.head,n.head))return!1}return!0},Ci.prototype.deepCopy=function(){for(var t=[],e=0;e<this.ranges.length;e++)t[e]=new Bi(ne(this.ranges[e].anchor),ne(this.ranges[e].head));return new Ci(t,this.primIndex)},Ci.prototype.somethingSelected=function(){for(var t=0;t<this.ranges.length;t++)if(!this.ranges[t].empty())return!0;return!1},Ci.prototype.contains=function(t,e){e||(e=t);for(var r=0;r<this.ranges.length;r++){var n=this.ranges[r];if(ee(e,n.from())>=0&&ee(t,n.to())<=0)return r}return-1};var Bi=function(t,e){this.anchor=t,this.head=e};function xi(t,e,r){var n=t&&t.options.selectionsMayTouch,i=e[r];e.sort((function(t,e){return ee(t.from(),e.from())})),r=H(e,i);for(var o=1;o<e.length;o++){var a=e[o],s=e[o-1],A=ee(s.to(),a.from());if(n&&!a.empty()?A>0:A>=0){var l=oe(s.from(),a.from()),c=ie(s.to(),a.to()),u=s.empty()?a.from()==a.head:s.from()==s.head;o<=r&&--r,e.splice(--o,2,new Bi(u?c:l,u?l:c))}}return new Ci(e,r)}function Ei(t,e){return new Ci([new Bi(t,e||t)],0)}function Si(t){return t.text?te(t.from.line+t.text.length-1,Y(t.text).length+(1==t.text.length?t.from.ch:0)):t.to}function ki(t,e){if(ee(t,e.from)<0)return t;if(ee(t,e.to)<=0)return Si(e);var r=t.line+e.text.length-(e.to.line-e.from.line)-1,n=t.ch;return t.line==e.to.line&&(n+=Si(e).ch-e.to.ch),te(r,n)}function Ti(t,e){for(var r=[],n=0;n<t.sel.ranges.length;n++){var i=t.sel.ranges[n];r.push(new Bi(ki(i.anchor,e),ki(i.head,e)))}return xi(t.cm,r,t.sel.primIndex)}function Fi(t,e,r){return t.line==e.line?te(r.line,t.ch-e.ch+r.ch):te(r.line+(t.line-e.line),t.ch)}function Li(t){t.doc.mode=Pt(t.options,t.doc.modeOption),Ii(t)}function Ii(t){t.doc.iter((function(t){t.stateAfter&&(t.stateAfter=null),t.styles&&(t.styles=null)})),t.doc.modeFrontier=t.doc.highlightFrontier=t.doc.first,ni(t,100),t.state.modeGen++,t.curOp&&un(t)}function _i(t,e){return 0==e.from.ch&&0==e.to.ch&&""==Y(e.text)&&(!t.cm||t.cm.options.wholeLineUpdateBefore)}function Ui(t,e,r,n){function i(t){return r?r[t]:null}function o(t,r,i){!function(t,e,r,n){t.text=e,t.stateAfter&&(t.stateAfter=null),t.styles&&(t.styles=null),null!=t.order&&(t.order=null),Te(t),Fe(t,r);var i=n?n(t):1;i!=t.height&&Xt(t,i)}(t,r,i,n),sr(t,"change",t,e)}function a(t,e){for(var r=[],o=t;o<e;++o)r.push(new ze(l[o],i(o),n));return r}var s=e.from,A=e.to,l=e.text,c=zt(t,s.line),u=zt(t,A.line),h=Y(l),d=i(l.length-1),f=A.line-s.line;if(e.full)t.insert(0,a(0,l.length)),t.remove(l.length,t.size-l.length);else if(_i(t,e)){var p=a(0,l.length-1);o(u,u.text,d),f&&t.remove(s.line,f),p.length&&t.insert(s.line,p)}else if(c==u)if(1==l.length)o(c,c.text.slice(0,s.ch)+h+c.text.slice(A.ch),d);else{var g=a(1,l.length-1);g.push(new ze(h+c.text.slice(A.ch),d,n)),o(c,c.text.slice(0,s.ch)+l[0],i(0)),t.insert(s.line+1,g)}else if(1==l.length)o(c,c.text.slice(0,s.ch)+l[0]+u.text.slice(A.ch),i(0)),t.remove(s.line+1,f);else{o(c,c.text.slice(0,s.ch)+l[0],i(0)),o(u,h+u.text.slice(A.ch),d);var m=a(1,l.length-1);f>1&&t.remove(s.line+1,f-1),t.insert(s.line+1,m)}sr(t,"change",t,e)}function Oi(t,e,r){!function t(n,i,o){if(n.linked)for(var a=0;a<n.linked.length;++a){var s=n.linked[a];if(s.doc!=i){var A=o&&s.sharedHist;r&&!A||(e(s.doc,A),t(s.doc,n,A))}}}(t,null,!0)}function Di(t,e){if(e.cm)throw new Error("This document is already in use.");t.doc=e,e.cm=t,An(t),Li(t),Qi(t),t.options.lineWrapping||Ve(t),t.options.mode=e.modeOption,un(t)}function Qi(t){("rtl"==t.doc.direction?U:S)(t.display.lineDiv,"CodeMirror-rtl")}function Mi(t){this.done=[],this.undone=[],this.undoDepth=1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=t||1}function Ri(t,e){var r={from:ne(e.from),to:Si(e),text:Wt(t,e.from,e.to)};return ji(t,r,e.from.line,e.to.line+1),Oi(t,(function(t){return ji(t,r,e.from.line,e.to.line+1)}),!0),r}function Pi(t){for(;t.length&&Y(t).ranges;)t.pop()}function Hi(t,e,r,n){var i=t.history;i.undone.length=0;var o,a,s=+new Date;if((i.lastOp==n||i.lastOrigin==e.origin&&e.origin&&("+"==e.origin.charAt(0)&&i.lastModTime>s-(t.cm?t.cm.options.historyEventDelay:500)||"*"==e.origin.charAt(0)))&&(o=function(t,e){return e?(Pi(t.done),Y(t.done)):t.done.length&&!Y(t.done).ranges?Y(t.done):t.done.length>1&&!t.done[t.done.length-2].ranges?(t.done.pop(),Y(t.done)):void 0}(i,i.lastOp==n)))a=Y(o.changes),0==ee(e.from,e.to)&&0==ee(e.from,a.to)?a.to=Si(e):o.changes.push(Ri(t,e));else{var A=Y(i.done);for(A&&A.ranges||Ki(t.sel,i.done),o={changes:[Ri(t,e)],generation:i.generation},i.done.push(o);i.done.length>i.undoDepth;)i.done.shift(),i.done[0].ranges||i.done.shift()}i.done.push(r),i.generation=++i.maxGeneration,i.lastModTime=i.lastSelTime=s,i.lastOp=i.lastSelOp=n,i.lastOrigin=i.lastSelOrigin=e.origin,a||ft(t,"historyAdded")}function Ni(t,e,r,n){var i=t.history,o=n&&n.origin;r==i.lastSelOp||o&&i.lastSelOrigin==o&&(i.lastModTime==i.lastSelTime&&i.lastOrigin==o||function(t,e,r,n){var i=e.charAt(0);return"*"==i||"+"==i&&r.ranges.length==n.ranges.length&&r.somethingSelected()==n.somethingSelected()&&new Date-t.history.lastSelTime<=(t.cm?t.cm.options.historyEventDelay:500)}(t,o,Y(i.done),e))?i.done[i.done.length-1]=e:Ki(e,i.done),i.lastSelTime=+new Date,i.lastSelOrigin=o,i.lastSelOp=r,n&&!1!==n.clearRedo&&Pi(i.undone)}function Ki(t,e){var r=Y(e);r&&r.ranges&&r.equals(t)||e.push(t)}function ji(t,e,r,n){var i=e["spans_"+t.id],o=0;t.iter(Math.max(t.first,r),Math.min(t.first+t.size,n),(function(r){r.markedSpans&&((i||(i=e["spans_"+t.id]={}))[o]=r.markedSpans),++o}))}function Gi(t){if(!t)return null;for(var e,r=0;r<t.length;++r)t[r].marker.explicitlyCleared?e||(e=t.slice(0,r)):e&&e.push(t[r]);return e?e.length?e:null:t}function Vi(t,e){var r=function(t,e){var r=e["spans_"+t.id];if(!r)return null;for(var n=[],i=0;i<e.text.length;++i)n.push(Gi(r[i]));return n}(t,e),n=Se(t,e);if(!r)return n;if(!n)return r;for(var i=0;i<r.length;++i){var o=r[i],a=n[i];if(o&&a)t:for(var s=0;s<a.length;++s){for(var A=a[s],l=0;l<o.length;++l)if(o[l].marker==A.marker)continue t;o.push(A)}else a&&(r[i]=a)}return r}function zi(t,e,r){for(var n=[],i=0;i<t.length;++i){var o=t[i];if(o.ranges)n.push(r?Ci.prototype.deepCopy.call(o):o);else{var a=o.changes,s=[];n.push({changes:s});for(var A=0;A<a.length;++A){var l=a[A],c=void 0;if(s.push({from:l.from,to:l.to,text:l.text}),e)for(var u in l)(c=u.match(/^spans_(\d+)$/))&&H(e,Number(c[1]))>-1&&(Y(s)[u]=l[u],delete l[u])}}}return n}function Wi(t,e,r,n){if(n){var i=t.anchor;if(r){var o=ee(e,i)<0;o!=ee(r,i)<0?(i=e,e=r):o!=ee(e,r)<0&&(e=r)}return new Bi(i,e)}return new Bi(r||e,e)}function Yi(t,e,r,n,i){null==i&&(i=t.cm&&(t.cm.display.shift||t.extend)),$i(t,new Ci([Wi(t.sel.primary(),e,r,i)],0),n)}function Xi(t,e,r){for(var n=[],i=t.cm&&(t.cm.display.shift||t.extend),o=0;o<t.sel.ranges.length;o++)n[o]=Wi(t.sel.ranges[o],e[o],null,i);$i(t,xi(t.cm,n,t.sel.primIndex),r)}function qi(t,e,r,n){var i=t.sel.ranges.slice(0);i[e]=r,$i(t,xi(t.cm,i,t.sel.primIndex),n)}function Ji(t,e,r,n){$i(t,Ei(e,r),n)}function Zi(t,e,r){var n=t.history.done,i=Y(n);i&&i.ranges?(n[n.length-1]=e,to(t,e,r)):$i(t,e,r)}function $i(t,e,r){to(t,e,r),Ni(t,t.sel,t.cm?t.cm.curOp.id:NaN,r)}function to(t,e,r){(mt(t,"beforeSelectionChange")||t.cm&&mt(t.cm,"beforeSelectionChange"))&&(e=function(t,e,r){var n={ranges:e.ranges,update:function(e){this.ranges=[];for(var r=0;r<e.length;r++)this.ranges[r]=new Bi(se(t,e[r].anchor),se(t,e[r].head))},origin:r&&r.origin};return ft(t,"beforeSelectionChange",t,n),t.cm&&ft(t.cm,"beforeSelectionChange",t.cm,n),n.ranges!=e.ranges?xi(t.cm,n.ranges,n.ranges.length-1):e}(t,e,r));var n=r&&r.bias||(ee(e.primary().head,t.sel.primary().head)<0?-1:1);eo(t,no(t,e,n,!0)),r&&!1===r.scroll||!t.cm||In(t.cm)}function eo(t,e){e.equals(t.sel)||(t.sel=e,t.cm&&(t.cm.curOp.updateInput=1,t.cm.curOp.selectionChanged=!0,gt(t.cm)),sr(t,"cursorActivity",t))}function ro(t){eo(t,no(t,t.sel,null,!1))}function no(t,e,r,n){for(var i,o=0;o<e.ranges.length;o++){var a=e.ranges[o],s=e.ranges.length==t.sel.ranges.length&&t.sel.ranges[o],A=oo(t,a.anchor,s&&s.anchor,r,n),l=oo(t,a.head,s&&s.head,r,n);(i||A!=a.anchor||l!=a.head)&&(i||(i=e.ranges.slice(0,o)),i[o]=new Bi(A,l))}return i?xi(t.cm,i,e.primIndex):e}function io(t,e,r,n,i){var o=zt(t,e.line);if(o.markedSpans)for(var a=0;a<o.markedSpans.length;++a){var s=o.markedSpans[a],A=s.marker,l="selectLeft"in A?!A.selectLeft:A.inclusiveLeft,c="selectRight"in A?!A.selectRight:A.inclusiveRight;if((null==s.from||(l?s.from<=e.ch:s.from<e.ch))&&(null==s.to||(c?s.to>=e.ch:s.to>e.ch))){if(i&&(ft(A,"beforeCursorEnter"),A.explicitlyCleared)){if(o.markedSpans){--a;continue}break}if(!A.atomic)continue;if(r){var u=A.find(n<0?1:-1),h=void 0;if((n<0?c:l)&&(u=ao(t,u,-n,u&&u.line==e.line?o:null)),u&&u.line==e.line&&(h=ee(u,r))&&(n<0?h<0:h>0))return io(t,u,e,n,i)}var d=A.find(n<0?-1:1);return(n<0?l:c)&&(d=ao(t,d,n,d.line==e.line?o:null)),d?io(t,d,e,n,i):null}}return e}function oo(t,e,r,n,i){var o=n||1,a=io(t,e,r,o,i)||!i&&io(t,e,r,o,!0)||io(t,e,r,-o,i)||!i&&io(t,e,r,-o,!0);return a||(t.cantEdit=!0,te(t.first,0))}function ao(t,e,r,n){return r<0&&0==e.ch?e.line>t.first?se(t,te(e.line-1)):null:r>0&&e.ch==(n||zt(t,e.line)).text.length?e.line<t.first+t.size-1?te(e.line+1,0):null:new te(e.line,e.ch+r)}function so(t){t.setSelection(te(t.firstLine(),0),te(t.lastLine()),K)}function Ao(t,e,r){var n={canceled:!1,from:e.from,to:e.to,text:e.text,origin:e.origin,cancel:function(){return n.canceled=!0}};return r&&(n.update=function(e,r,i,o){e&&(n.from=se(t,e)),r&&(n.to=se(t,r)),i&&(n.text=i),void 0!==o&&(n.origin=o)}),ft(t,"beforeChange",t,n),t.cm&&ft(t.cm,"beforeChange",t.cm,n),n.canceled?(t.cm&&(t.cm.curOp.updateInput=2),null):{from:n.from,to:n.to,text:n.text,origin:n.origin}}function lo(t,e,r){if(t.cm){if(!t.cm.curOp)return ti(t.cm,lo)(t,e,r);if(t.cm.state.suppressEdits)return}if(!(mt(t,"beforeChange")||t.cm&&mt(t.cm,"beforeChange"))||(e=Ao(t,e,!0))){var n=be&&!r&&function(t,e,r){var n=null;if(t.iter(e.line,r.line+1,(function(t){if(t.markedSpans)for(var e=0;e<t.markedSpans.length;++e){var r=t.markedSpans[e].marker;!r.readOnly||n&&-1!=H(n,r)||(n||(n=[])).push(r)}})),!n)return null;for(var i=[{from:e,to:r}],o=0;o<n.length;++o)for(var a=n[o],s=a.find(0),A=0;A<i.length;++A){var l=i[A];if(!(ee(l.to,s.from)<0||ee(l.from,s.to)>0)){var c=[A,1],u=ee(l.from,s.from),h=ee(l.to,s.to);(u<0||!a.inclusiveLeft&&!u)&&c.push({from:l.from,to:s.from}),(h>0||!a.inclusiveRight&&!h)&&c.push({from:s.to,to:l.to}),i.splice.apply(i,c),A+=c.length-3}}return i}(t,e.from,e.to);if(n)for(var i=n.length-1;i>=0;--i)co(t,{from:n[i].from,to:n[i].to,text:i?[""]:e.text,origin:e.origin});else co(t,e)}}function co(t,e){if(1!=e.text.length||""!=e.text[0]||0!=ee(e.from,e.to)){var r=Ti(t,e);Hi(t,e,r,t.cm?t.cm.curOp.id:NaN),fo(t,e,r,Se(t,e));var n=[];Oi(t,(function(t,r){r||-1!=H(n,t.history)||(vo(t.history,e),n.push(t.history)),fo(t,e,null,Se(t,e))}))}}function uo(t,e,r){var n=t.cm&&t.cm.state.suppressEdits;if(!n||r){for(var i,o=t.history,a=t.sel,s="undo"==e?o.done:o.undone,A="undo"==e?o.undone:o.done,l=0;l<s.length&&(i=s[l],r?!i.ranges||i.equals(t.sel):i.ranges);l++);if(l!=s.length){for(o.lastOrigin=o.lastSelOrigin=null;;){if(!(i=s.pop()).ranges){if(n)return void s.push(i);break}if(Ki(i,A),r&&!i.equals(t.sel))return void $i(t,i,{clearRedo:!1});a=i}var c=[];Ki(a,A),A.push({changes:c,generation:o.generation}),o.generation=i.generation||++o.maxGeneration;for(var u=mt(t,"beforeChange")||t.cm&&mt(t.cm,"beforeChange"),h=function(r){var n=i.changes[r];if(n.origin=e,u&&!Ao(t,n,!1))return s.length=0,{};c.push(Ri(t,n));var o=r?Ti(t,n):Y(s);fo(t,n,o,Vi(t,n)),!r&&t.cm&&t.cm.scrollIntoView({from:n.from,to:Si(n)});var a=[];Oi(t,(function(t,e){e||-1!=H(a,t.history)||(vo(t.history,n),a.push(t.history)),fo(t,n,null,Vi(t,n))}))},d=i.changes.length-1;d>=0;--d){var f=h(d);if(f)return f.v}}}}function ho(t,e){if(0!=e&&(t.first+=e,t.sel=new Ci(X(t.sel.ranges,(function(t){return new Bi(te(t.anchor.line+e,t.anchor.ch),te(t.head.line+e,t.head.ch))})),t.sel.primIndex),t.cm)){un(t.cm,t.first,t.first-e,e);for(var r=t.cm.display,n=r.viewFrom;n<r.viewTo;n++)hn(t.cm,n,"gutter")}}function fo(t,e,r,n){if(t.cm&&!t.cm.curOp)return ti(t.cm,fo)(t,e,r,n);if(e.to.line<t.first)ho(t,e.text.length-1-(e.to.line-e.from.line));else if(!(e.from.line>t.lastLine())){if(e.from.line<t.first){var i=e.text.length-1-(t.first-e.from.line);ho(t,i),e={from:te(t.first,0),to:te(e.to.line+i,e.to.ch),text:[Y(e.text)],origin:e.origin}}var o=t.lastLine();e.to.line>o&&(e={from:e.from,to:te(o,zt(t,o).text.length),text:[e.text[0]],origin:e.origin}),e.removed=Wt(t,e.from,e.to),r||(r=Ti(t,e)),t.cm?function(t,e,r){var n=t.doc,i=t.display,o=e.from,a=e.to,s=!1,A=o.line;t.options.lineWrapping||(A=qt(Re(zt(n,o.line))),n.iter(A,a.line+1,(function(t){if(t==i.maxLine)return s=!0,!0}))),n.sel.contains(e.from,e.to)>-1&>(t),Ui(n,e,r,sn(t)),t.options.lineWrapping||(n.iter(A,o.line+e.text.length,(function(t){var e=Ge(t);e>i.maxLineLength&&(i.maxLine=t,i.maxLineLength=e,i.maxLineChanged=!0,s=!1)})),s&&(t.curOp.updateMaxLine=!0)),function(t,e){if(t.modeFrontier=Math.min(t.modeFrontier,e),!(t.highlightFrontier<e-10)){for(var r=t.first,n=e-1;n>r;n--){var i=zt(t,n).stateAfter;if(i&&(!(i instanceof le)||n+i.lookAhead<e)){r=n+1;break}}t.highlightFrontier=Math.min(t.highlightFrontier,r)}}(n,o.line),ni(t,400);var l=e.text.length-(a.line-o.line)-1;e.full?un(t):o.line!=a.line||1!=e.text.length||_i(t.doc,e)?un(t,o.line,a.line+1,l):hn(t,o.line,"text");var c=mt(t,"changes"),u=mt(t,"change");if(u||c){var h={from:o,to:a,text:e.text,removed:e.removed,origin:e.origin};u&&sr(t,"change",t,h),c&&(t.curOp.changeObjs||(t.curOp.changeObjs=[])).push(h)}t.display.selForContextMenu=null}(t.cm,e,n):Ui(t,e,n),to(t,r,K),t.cantEdit&&oo(t,te(t.firstLine(),0))&&(t.cantEdit=!1)}}function po(t,e,r,n,i){var o;n||(n=r),ee(n,r)<0&&(r=(o=[n,r])[0],n=o[1]),"string"==typeof e&&(e=t.splitLines(e)),lo(t,{from:r,to:n,text:e,origin:i})}function go(t,e,r,n){r<t.line?t.line+=n:e<t.line&&(t.line=e,t.ch=0)}function mo(t,e,r,n){for(var i=0;i<t.length;++i){var o=t[i],a=!0;if(o.ranges){o.copied||((o=t[i]=o.deepCopy()).copied=!0);for(var s=0;s<o.ranges.length;s++)go(o.ranges[s].anchor,e,r,n),go(o.ranges[s].head,e,r,n)}else{for(var A=0;A<o.changes.length;++A){var l=o.changes[A];if(r<l.from.line)l.from=te(l.from.line+n,l.from.ch),l.to=te(l.to.line+n,l.to.ch);else if(e<=l.to.line){a=!1;break}}a||(t.splice(0,i+1),i=0)}}}function vo(t,e){var r=e.from.line,n=e.to.line,i=e.text.length-(n-r)-1;mo(t.done,r,n,i),mo(t.undone,r,n,i)}function yo(t,e,r,n){var i=e,o=e;return"number"==typeof e?o=zt(t,ae(t,e)):i=qt(e),null==i?null:(n(o,i)&&t.cm&&hn(t.cm,i,r),o)}function wo(t){this.lines=t,this.parent=null;for(var e=0,r=0;r<t.length;++r)t[r].parent=this,e+=t[r].height;this.height=e}function bo(t){this.children=t;for(var e=0,r=0,n=0;n<t.length;++n){var i=t[n];e+=i.chunkSize(),r+=i.height,i.parent=this}this.size=e,this.height=r,this.parent=null}Bi.prototype.from=function(){return oe(this.anchor,this.head)},Bi.prototype.to=function(){return ie(this.anchor,this.head)},Bi.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch},wo.prototype={chunkSize:function(){return this.lines.length},removeInner:function(t,e){for(var r=t,n=t+e;r<n;++r){var i=this.lines[r];this.height-=i.height,We(i),sr(i,"delete")}this.lines.splice(t,e)},collapse:function(t){t.push.apply(t,this.lines)},insertInner:function(t,e,r){this.height+=r,this.lines=this.lines.slice(0,t).concat(e).concat(this.lines.slice(t));for(var n=0;n<e.length;++n)e[n].parent=this},iterN:function(t,e,r){for(var n=t+e;t<n;++t)if(r(this.lines[t]))return!0}},bo.prototype={chunkSize:function(){return this.size},removeInner:function(t,e){this.size-=e;for(var r=0;r<this.children.length;++r){var n=this.children[r],i=n.chunkSize();if(t<i){var o=Math.min(e,i-t),a=n.height;if(n.removeInner(t,o),this.height-=a-n.height,i==o&&(this.children.splice(r--,1),n.parent=null),0==(e-=o))break;t=0}else t-=i}if(this.size-e<25&&(this.children.length>1||!(this.children[0]instanceof wo))){var s=[];this.collapse(s),this.children=[new wo(s)],this.children[0].parent=this}},collapse:function(t){for(var e=0;e<this.children.length;++e)this.children[e].collapse(t)},insertInner:function(t,e,r){this.size+=e.length,this.height+=r;for(var n=0;n<this.children.length;++n){var i=this.children[n],o=i.chunkSize();if(t<=o){if(i.insertInner(t,e,r),i.lines&&i.lines.length>50){for(var a=i.lines.length%25+25,s=a;s<i.lines.length;){var A=new wo(i.lines.slice(s,s+=25));i.height-=A.height,this.children.splice(++n,0,A),A.parent=this}i.lines=i.lines.slice(0,a),this.maybeSpill()}break}t-=o}},maybeSpill:function(){if(!(this.children.length<=10)){var t=this;do{var e=new bo(t.children.splice(t.children.length-5,5));if(t.parent){t.size-=e.size,t.height-=e.height;var r=H(t.parent.children,t);t.parent.children.splice(r+1,0,e)}else{var n=new bo(t.children);n.parent=t,t.children=[n,e],t=n}e.parent=t.parent}while(t.children.length>10);t.parent.maybeSpill()}},iterN:function(t,e,r){for(var n=0;n<this.children.length;++n){var i=this.children[n],o=i.chunkSize();if(t<o){var a=Math.min(e,o-t);if(i.iterN(t,a,r))return!0;if(0==(e-=a))break;t=0}else t-=o}}};var Co=function(t,e,r){if(r)for(var n in r)r.hasOwnProperty(n)&&(this[n]=r[n]);this.doc=t,this.node=e};function Bo(t,e,r){je(e)<(t.curOp&&t.curOp.scrollTop||t.doc.scrollTop)&&Ln(t,r)}Co.prototype.clear=function(){var t=this.doc.cm,e=this.line.widgets,r=this.line,n=qt(r);if(null!=n&&e){for(var i=0;i<e.length;++i)e[i]==this&&e.splice(i--,1);e.length||(r.widgets=null);var o=wr(this);Xt(r,Math.max(0,r.height-o)),t&&($n(t,(function(){Bo(t,r,-o),hn(t,n,"widget")})),sr(t,"lineWidgetCleared",t,this,n))}},Co.prototype.changed=function(){var t=this,e=this.height,r=this.doc.cm,n=this.line;this.height=null;var i=wr(this)-e;i&&(Ne(this.doc,n)||Xt(n,n.height+i),r&&$n(r,(function(){r.curOp.forceUpdate=!0,Bo(r,n,i),sr(r,"lineWidgetChanged",r,t,qt(n))})))},vt(Co);var xo=0,Eo=function(t,e){this.lines=[],this.type=e,this.doc=t,this.id=++xo};function So(t,e,r,n,i){if(n&&n.shared)return function(t,e,r,n,i){(n=M(n)).shared=!1;var o=[So(t,e,r,n,i)],a=o[0],s=n.widgetNode;return Oi(t,(function(t){s&&(n.widgetNode=s.cloneNode(!0)),o.push(So(t,se(t,e),se(t,r),n,i));for(var A=0;A<t.linked.length;++A)if(t.linked[A].isParent)return;a=Y(o)})),new ko(o,a)}(t,e,r,n,i);if(t.cm&&!t.cm.curOp)return ti(t.cm,So)(t,e,r,n,i);var o=new Eo(t,i),a=ee(e,r);if(n&&M(n,o,!1),a>0||0==a&&!1!==o.clearWhenEmpty)return o;if(o.replacedWith&&(o.collapsed=!0,o.widgetNode=L("span",[o.replacedWith],"CodeMirror-widget"),n.handleMouseEvents||o.widgetNode.setAttribute("cm-ignore-events","true"),n.insertLeft&&(o.widgetNode.insertLeft=!0)),o.collapsed){if(Me(t,e.line,e,r,o)||e.line!=r.line&&Me(t,r.line,e,r,o))throw new Error("Inserting collapsed marker partially overlapping an existing one");Ce=!0}o.addToHistory&&Hi(t,{from:e,to:r,origin:"markText"},t.sel,NaN);var s,A=e.line,l=t.cm;if(t.iter(A,r.line+1,(function(t){l&&o.collapsed&&!l.options.lineWrapping&&Re(t)==l.display.maxLine&&(s=!0),o.collapsed&&A!=e.line&&Xt(t,0),function(t,e){t.markedSpans=t.markedSpans?t.markedSpans.concat([e]):[e],e.marker.attachLine(t)}(t,new Be(o,A==e.line?e.ch:null,A==r.line?r.ch:null)),++A})),o.collapsed&&t.iter(e.line,r.line+1,(function(e){Ne(t,e)&&Xt(e,0)})),o.clearOnEnter&&ut(o,"beforeCursorEnter",(function(){return o.clear()})),o.readOnly&&(be=!0,(t.history.done.length||t.history.undone.length)&&t.clearHistory()),o.collapsed&&(o.id=++xo,o.atomic=!0),l){if(s&&(l.curOp.updateMaxLine=!0),o.collapsed)un(l,e.line,r.line+1);else if(o.className||o.startStyle||o.endStyle||o.css||o.attributes||o.title)for(var c=e.line;c<=r.line;c++)hn(l,c,"text");o.atomic&&ro(l.doc),sr(l,"markerAdded",l,o)}return o}Eo.prototype.clear=function(){if(!this.explicitlyCleared){var t=this.doc.cm,e=t&&!t.curOp;if(e&&zn(t),mt(this,"clear")){var r=this.find();r&&sr(this,"clear",r.from,r.to)}for(var n=null,i=null,o=0;o<this.lines.length;++o){var a=this.lines[o],s=xe(a.markedSpans,this);t&&!this.collapsed?hn(t,qt(a),"text"):t&&(null!=s.to&&(i=qt(a)),null!=s.from&&(n=qt(a))),a.markedSpans=Ee(a.markedSpans,s),null==s.from&&this.collapsed&&!Ne(this.doc,a)&&t&&Xt(a,rn(t.display))}if(t&&this.collapsed&&!t.options.lineWrapping)for(var A=0;A<this.lines.length;++A){var l=Re(this.lines[A]),c=Ge(l);c>t.display.maxLineLength&&(t.display.maxLine=l,t.display.maxLineLength=c,t.display.maxLineChanged=!0)}null!=n&&t&&this.collapsed&&un(t,n,i+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,t&&ro(t.doc)),t&&sr(t,"markerCleared",t,this,n,i),e&&Wn(t),this.parent&&this.parent.clear()}},Eo.prototype.find=function(t,e){var r,n;null==t&&"bookmark"==this.type&&(t=1);for(var i=0;i<this.lines.length;++i){var o=this.lines[i],a=xe(o.markedSpans,this);if(null!=a.from&&(r=te(e?o:qt(o),a.from),-1==t))return r;if(null!=a.to&&(n=te(e?o:qt(o),a.to),1==t))return n}return r&&{from:r,to:n}},Eo.prototype.changed=function(){var t=this,e=this.find(-1,!0),r=this,n=this.doc.cm;e&&n&&$n(n,(function(){var i=e.line,o=qt(e.line),a=Lr(n,o);if(a&&(Mr(a),n.curOp.selectionChanged=n.curOp.forceUpdate=!0),n.curOp.updateMaxLine=!0,!Ne(r.doc,i)&&null!=r.height){var s=r.height;r.height=null;var A=wr(r)-s;A&&Xt(i,i.height+A)}sr(n,"markerChanged",n,t)}))},Eo.prototype.attachLine=function(t){if(!this.lines.length&&this.doc.cm){var e=this.doc.cm.curOp;e.maybeHiddenMarkers&&-1!=H(e.maybeHiddenMarkers,this)||(e.maybeUnhiddenMarkers||(e.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(t)},Eo.prototype.detachLine=function(t){if(this.lines.splice(H(this.lines,t),1),!this.lines.length&&this.doc.cm){var e=this.doc.cm.curOp;(e.maybeHiddenMarkers||(e.maybeHiddenMarkers=[])).push(this)}},vt(Eo);var ko=function(t,e){this.markers=t,this.primary=e;for(var r=0;r<t.length;++r)t[r].parent=this};function To(t){return t.findMarks(te(t.first,0),t.clipPos(te(t.lastLine())),(function(t){return t.parent}))}function Fo(t){for(var e=function(e){var r=t[e],n=[r.primary.doc];Oi(r.primary.doc,(function(t){return n.push(t)}));for(var i=0;i<r.markers.length;i++){var o=r.markers[i];-1==H(n,o.doc)&&(o.parent=null,r.markers.splice(i--,1))}},r=0;r<t.length;r++)e(r)}ko.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var t=0;t<this.markers.length;++t)this.markers[t].clear();sr(this,"clear")}},ko.prototype.find=function(t,e){return this.primary.find(t,e)},vt(ko);var Lo=0,Io=function(t,e,r,n,i){if(!(this instanceof Io))return new Io(t,e,r,n,i);null==r&&(r=0),bo.call(this,[new wo([new ze("",null)])]),this.first=r,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=r;var o=te(r,0);this.sel=Ei(o),this.history=new Mi(null),this.id=++Lo,this.modeOption=e,this.lineSep=n,this.direction="rtl"==i?"rtl":"ltr",this.extend=!1,"string"==typeof t&&(t=this.splitLines(t)),Ui(this,{from:o,to:o,text:t}),$i(this,Ei(o),K)};Io.prototype=J(bo.prototype,{constructor:Io,iter:function(t,e,r){r?this.iterN(t-this.first,e-t,r):this.iterN(this.first,this.first+this.size,t)},insert:function(t,e){for(var r=0,n=0;n<e.length;++n)r+=e[n].height;this.insertInner(t-this.first,e,r)},remove:function(t,e){this.removeInner(t-this.first,e)},getValue:function(t){var e=Yt(this,this.first,this.first+this.size);return!1===t?e:e.join(t||this.lineSeparator())},setValue:ri((function(t){var e=te(this.first,0),r=this.first+this.size-1;lo(this,{from:e,to:te(r,zt(this,r).text.length),text:this.splitLines(t),origin:"setValue",full:!0},!0),this.cm&&_n(this.cm,0,0),$i(this,Ei(e),K)})),replaceRange:function(t,e,r,n){po(this,t,e=se(this,e),r=r?se(this,r):e,n)},getRange:function(t,e,r){var n=Wt(this,se(this,t),se(this,e));return!1===r?n:n.join(r||this.lineSeparator())},getLine:function(t){var e=this.getLineHandle(t);return e&&e.text},getLineHandle:function(t){if(Zt(this,t))return zt(this,t)},getLineNumber:function(t){return qt(t)},getLineHandleVisualStart:function(t){return"number"==typeof t&&(t=zt(this,t)),Re(t)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(t){return se(this,t)},getCursor:function(t){var e=this.sel.primary();return null==t||"head"==t?e.head:"anchor"==t?e.anchor:"end"==t||"to"==t||!1===t?e.to():e.from()},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:ri((function(t,e,r){Ji(this,se(this,"number"==typeof t?te(t,e||0):t),null,r)})),setSelection:ri((function(t,e,r){Ji(this,se(this,t),se(this,e||t),r)})),extendSelection:ri((function(t,e,r){Yi(this,se(this,t),e&&se(this,e),r)})),extendSelections:ri((function(t,e){Xi(this,Ae(this,t),e)})),extendSelectionsBy:ri((function(t,e){Xi(this,Ae(this,X(this.sel.ranges,t)),e)})),setSelections:ri((function(t,e,r){if(t.length){for(var n=[],i=0;i<t.length;i++)n[i]=new Bi(se(this,t[i].anchor),se(this,t[i].head));null==e&&(e=Math.min(t.length-1,this.sel.primIndex)),$i(this,xi(this.cm,n,e),r)}})),addSelection:ri((function(t,e,r){var n=this.sel.ranges.slice(0);n.push(new Bi(se(this,t),se(this,e||t))),$i(this,xi(this.cm,n,n.length-1),r)})),getSelection:function(t){for(var e,r=this.sel.ranges,n=0;n<r.length;n++){var i=Wt(this,r[n].from(),r[n].to());e=e?e.concat(i):i}return!1===t?e:e.join(t||this.lineSeparator())},getSelections:function(t){for(var e=[],r=this.sel.ranges,n=0;n<r.length;n++){var i=Wt(this,r[n].from(),r[n].to());!1!==t&&(i=i.join(t||this.lineSeparator())),e[n]=i}return e},replaceSelection:function(t,e,r){for(var n=[],i=0;i<this.sel.ranges.length;i++)n[i]=t;this.replaceSelections(n,e,r||"+input")},replaceSelections:ri((function(t,e,r){for(var n=[],i=this.sel,o=0;o<i.ranges.length;o++){var a=i.ranges[o];n[o]={from:a.from(),to:a.to(),text:this.splitLines(t[o]),origin:r}}for(var s=e&&"end"!=e&&function(t,e,r){for(var n=[],i=te(t.first,0),o=i,a=0;a<e.length;a++){var s=e[a],A=Fi(s.from,i,o),l=Fi(Si(s),i,o);if(i=s.to,o=l,"around"==r){var c=t.sel.ranges[a],u=ee(c.head,c.anchor)<0;n[a]=new Bi(u?l:A,u?A:l)}else n[a]=new Bi(A,A)}return new Ci(n,t.sel.primIndex)}(this,n,e),A=n.length-1;A>=0;A--)lo(this,n[A]);s?Zi(this,s):this.cm&&In(this.cm)})),undo:ri((function(){uo(this,"undo")})),redo:ri((function(){uo(this,"redo")})),undoSelection:ri((function(){uo(this,"undo",!0)})),redoSelection:ri((function(){uo(this,"redo",!0)})),setExtending:function(t){this.extend=t},getExtending:function(){return this.extend},historySize:function(){for(var t=this.history,e=0,r=0,n=0;n<t.done.length;n++)t.done[n].ranges||++e;for(var i=0;i<t.undone.length;i++)t.undone[i].ranges||++r;return{undo:e,redo:r}},clearHistory:function(){var t=this;this.history=new Mi(this.history.maxGeneration),Oi(this,(function(e){return e.history=t.history}),!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(t){return t&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(t){return this.history.generation==(t||this.cleanGeneration)},getHistory:function(){return{done:zi(this.history.done),undone:zi(this.history.undone)}},setHistory:function(t){var e=this.history=new Mi(this.history.maxGeneration);e.done=zi(t.done.slice(0),null,!0),e.undone=zi(t.undone.slice(0),null,!0)},setGutterMarker:ri((function(t,e,r){return yo(this,t,"gutter",(function(t){var n=t.gutterMarkers||(t.gutterMarkers={});return n[e]=r,!r&&et(n)&&(t.gutterMarkers=null),!0}))})),clearGutter:ri((function(t){var e=this;this.iter((function(r){r.gutterMarkers&&r.gutterMarkers[t]&&yo(e,r,"gutter",(function(){return r.gutterMarkers[t]=null,et(r.gutterMarkers)&&(r.gutterMarkers=null),!0}))}))})),lineInfo:function(t){var e;if("number"==typeof t){if(!Zt(this,t))return null;if(e=t,!(t=zt(this,t)))return null}else if(null==(e=qt(t)))return null;return{line:e,handle:t,text:t.text,gutterMarkers:t.gutterMarkers,textClass:t.textClass,bgClass:t.bgClass,wrapClass:t.wrapClass,widgets:t.widgets}},addLineClass:ri((function(t,e,r){return yo(this,t,"gutter"==e?"gutter":"class",(function(t){var n="text"==e?"textClass":"background"==e?"bgClass":"gutter"==e?"gutterClass":"wrapClass";if(t[n]){if(x(r).test(t[n]))return!1;t[n]+=" "+r}else t[n]=r;return!0}))})),removeLineClass:ri((function(t,e,r){return yo(this,t,"gutter"==e?"gutter":"class",(function(t){var n="text"==e?"textClass":"background"==e?"bgClass":"gutter"==e?"gutterClass":"wrapClass",i=t[n];if(!i)return!1;if(null==r)t[n]=null;else{var o=i.match(x(r));if(!o)return!1;var a=o.index+o[0].length;t[n]=i.slice(0,o.index)+(o.index&&a!=i.length?" ":"")+i.slice(a)||null}return!0}))})),addLineWidget:ri((function(t,e,r){return function(t,e,r,n){var i=new Co(t,r,n),o=t.cm;return o&&i.noHScroll&&(o.display.alignWidgets=!0),yo(t,e,"widget",(function(e){var r=e.widgets||(e.widgets=[]);if(null==i.insertAt?r.push(i):r.splice(Math.min(r.length-1,Math.max(0,i.insertAt)),0,i),i.line=e,o&&!Ne(t,e)){var n=je(e)<t.scrollTop;Xt(e,e.height+wr(i)),n&&Ln(o,i.height),o.curOp.forceUpdate=!0}return!0})),o&&sr(o,"lineWidgetAdded",o,i,"number"==typeof e?e:qt(e)),i}(this,t,e,r)})),removeLineWidget:function(t){t.clear()},markText:function(t,e,r){return So(this,se(this,t),se(this,e),r,r&&r.type||"range")},setBookmark:function(t,e){var r={replacedWith:e&&(null==e.nodeType?e.widget:e),insertLeft:e&&e.insertLeft,clearWhenEmpty:!1,shared:e&&e.shared,handleMouseEvents:e&&e.handleMouseEvents};return So(this,t=se(this,t),t,r,"bookmark")},findMarksAt:function(t){var e=[],r=zt(this,(t=se(this,t)).line).markedSpans;if(r)for(var n=0;n<r.length;++n){var i=r[n];(null==i.from||i.from<=t.ch)&&(null==i.to||i.to>=t.ch)&&e.push(i.marker.parent||i.marker)}return e},findMarks:function(t,e,r){t=se(this,t),e=se(this,e);var n=[],i=t.line;return this.iter(t.line,e.line+1,(function(o){var a=o.markedSpans;if(a)for(var s=0;s<a.length;s++){var A=a[s];null!=A.to&&i==t.line&&t.ch>=A.to||null==A.from&&i!=t.line||null!=A.from&&i==e.line&&A.from>=e.ch||r&&!r(A.marker)||n.push(A.marker.parent||A.marker)}++i})),n},getAllMarks:function(){var t=[];return this.iter((function(e){var r=e.markedSpans;if(r)for(var n=0;n<r.length;++n)null!=r[n].from&&t.push(r[n].marker)})),t},posFromIndex:function(t){var e,r=this.first,n=this.lineSeparator().length;return this.iter((function(i){var o=i.text.length+n;if(o>t)return e=t,!0;t-=o,++r})),se(this,te(r,e))},indexFromPos:function(t){var e=(t=se(this,t)).ch;if(t.line<this.first||t.ch<0)return 0;var r=this.lineSeparator().length;return this.iter(this.first,t.line,(function(t){e+=t.text.length+r})),e},copy:function(t){var e=new Io(Yt(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return e.scrollTop=this.scrollTop,e.scrollLeft=this.scrollLeft,e.sel=this.sel,e.extend=!1,t&&(e.history.undoDepth=this.history.undoDepth,e.setHistory(this.getHistory())),e},linkedDoc:function(t){t||(t={});var e=this.first,r=this.first+this.size;null!=t.from&&t.from>e&&(e=t.from),null!=t.to&&t.to<r&&(r=t.to);var n=new Io(Yt(this,e,r),t.mode||this.modeOption,e,this.lineSep,this.direction);return t.sharedHist&&(n.history=this.history),(this.linked||(this.linked=[])).push({doc:n,sharedHist:t.sharedHist}),n.linked=[{doc:this,isParent:!0,sharedHist:t.sharedHist}],function(t,e){for(var r=0;r<e.length;r++){var n=e[r],i=n.find(),o=t.clipPos(i.from),a=t.clipPos(i.to);if(ee(o,a)){var s=So(t,o,a,n.primary,n.primary.type);n.markers.push(s),s.parent=n}}}(n,To(this)),n},unlinkDoc:function(t){if(t instanceof ka&&(t=t.doc),this.linked)for(var e=0;e<this.linked.length;++e)if(this.linked[e].doc==t){this.linked.splice(e,1),t.unlinkDoc(this),Fo(To(this));break}if(t.history==this.history){var r=[t.id];Oi(t,(function(t){return r.push(t.id)}),!0),t.history=new Mi(null),t.history.done=zi(this.history.done,r),t.history.undone=zi(this.history.undone,r)}},iterLinkedDocs:function(t){Oi(this,t)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(t){return this.lineSep?t.split(this.lineSep):It(t)},lineSeparator:function(){return this.lineSep||"\n"},setDirection:ri((function(t){var e;"rtl"!=t&&(t="ltr"),t!=this.direction&&(this.direction=t,this.iter((function(t){return t.order=null})),this.cm&&$n(e=this.cm,(function(){Qi(e),un(e)})))}))}),Io.prototype.eachLine=Io.prototype.iter;var _o=0;function Uo(t){var e=this;if(Oo(e),!pt(e,t)&&!br(e.display,t)){yt(t),a&&(_o=+new Date);var r=ln(e,t,!0),n=t.dataTransfer.files;if(r&&!e.isReadOnly())if(n&&n.length&&window.FileReader&&window.File)for(var i=n.length,o=Array(i),s=0,A=function(){++s==i&&ti(e,(function(){var t={from:r=se(e.doc,r),to:r,text:e.doc.splitLines(o.filter((function(t){return null!=t})).join(e.doc.lineSeparator())),origin:"paste"};lo(e.doc,t),Zi(e.doc,Ei(se(e.doc,r),se(e.doc,Si(t))))}))()},l=function(t,r){if(e.options.allowDropFileTypes&&-1==H(e.options.allowDropFileTypes,t.type))A();else{var n=new FileReader;n.onerror=function(){return A()},n.onload=function(){var t=n.result;/[\x00-\x08\x0e-\x1f]{2}/.test(t)||(o[r]=t),A()},n.readAsText(t)}},c=0;c<n.length;c++)l(n[c],c);else{if(e.state.draggingText&&e.doc.sel.contains(r)>-1)return e.state.draggingText(t),void setTimeout((function(){return e.display.input.focus()}),20);try{var u=t.dataTransfer.getData("Text");if(u){var h;if(e.state.draggingText&&!e.state.draggingText.copy&&(h=e.listSelections()),to(e.doc,Ei(r,r)),h)for(var d=0;d<h.length;++d)po(e.doc,"",h[d].anchor,h[d].head,"drag");e.replaceSelection(u,"around","paste"),e.display.input.focus()}}catch(t){}}}}function Oo(t){t.display.dragCursor&&(t.display.lineSpace.removeChild(t.display.dragCursor),t.display.dragCursor=null)}function Do(t){if(document.getElementsByClassName){for(var e=document.getElementsByClassName("CodeMirror"),r=[],n=0;n<e.length;n++){var i=e[n].CodeMirror;i&&r.push(i)}r.length&&r[0].operation((function(){for(var e=0;e<r.length;e++)t(r[e])}))}}var Qo=!1;function Mo(){var t;Qo||(ut(window,"resize",(function(){null==t&&(t=setTimeout((function(){t=null,Do(Ro)}),100))})),ut(window,"blur",(function(){return Do(En)})),Qo=!0)}function Ro(t){var e=t.display;e.cachedCharWidth=e.cachedTextHeight=e.cachedPaddingH=null,e.scrollbarsClipped=!1,t.setSize()}for(var Po={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Mod",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},Ho=0;Ho<10;Ho++)Po[Ho+48]=Po[Ho+96]=String(Ho);for(var No=65;No<=90;No++)Po[No]=String.fromCharCode(No);for(var Ko=1;Ko<=12;Ko++)Po[Ko+111]=Po[Ko+63235]="F"+Ko;var jo={};function Go(t){var e,r,n,i,o=t.split(/-(?!$)/);t=o[o.length-1];for(var a=0;a<o.length-1;a++){var s=o[a];if(/^(cmd|meta|m)$/i.test(s))i=!0;else if(/^a(lt)?$/i.test(s))e=!0;else if(/^(c|ctrl|control)$/i.test(s))r=!0;else{if(!/^s(hift)?$/i.test(s))throw new Error("Unrecognized modifier name: "+s);n=!0}}return e&&(t="Alt-"+t),r&&(t="Ctrl-"+t),i&&(t="Cmd-"+t),n&&(t="Shift-"+t),t}function Vo(t){var e={};for(var r in t)if(t.hasOwnProperty(r)){var n=t[r];if(/^(name|fallthrough|(de|at)tach)$/.test(r))continue;if("..."==n){delete t[r];continue}for(var i=X(r.split(" "),Go),o=0;o<i.length;o++){var a=void 0,s=void 0;o==i.length-1?(s=i.join(" "),a=n):(s=i.slice(0,o+1).join(" "),a="...");var A=e[s];if(A){if(A!=a)throw new Error("Inconsistent bindings for "+s)}else e[s]=a}delete t[r]}for(var l in e)t[l]=e[l];return t}function zo(t,e,r,n){var i=(e=qo(e)).call?e.call(t,n):e[t];if(!1===i)return"nothing";if("..."===i)return"multi";if(null!=i&&r(i))return"handled";if(e.fallthrough){if("[object Array]"!=Object.prototype.toString.call(e.fallthrough))return zo(t,e.fallthrough,r,n);for(var o=0;o<e.fallthrough.length;o++){var a=zo(t,e.fallthrough[o],r,n);if(a)return a}}}function Wo(t){var e="string"==typeof t?t:Po[t.keyCode];return"Ctrl"==e||"Alt"==e||"Shift"==e||"Mod"==e}function Yo(t,e,r){var n=t;return e.altKey&&"Alt"!=n&&(t="Alt-"+t),(C?e.metaKey:e.ctrlKey)&&"Ctrl"!=n&&(t="Ctrl-"+t),(C?e.ctrlKey:e.metaKey)&&"Mod"!=n&&(t="Cmd-"+t),!r&&e.shiftKey&&"Shift"!=n&&(t="Shift-"+t),t}function Xo(t,e){if(u&&34==t.keyCode&&t.char)return!1;var r=Po[t.keyCode];return null!=r&&!t.altGraphKey&&(3==t.keyCode&&t.code&&(r=t.code),Yo(r,t,e))}function qo(t){return"string"==typeof t?jo[t]:t}function Jo(t,e){for(var r=t.doc.sel.ranges,n=[],i=0;i<r.length;i++){for(var o=e(r[i]);n.length&&ee(o.from,Y(n).to)<=0;){var a=n.pop();if(ee(a.from,o.from)<0){o.from=a.from;break}}n.push(o)}$n(t,(function(){for(var e=n.length-1;e>=0;e--)po(t.doc,"",n[e].from,n[e].to,"+delete");In(t)}))}function Zo(t,e,r){var n=it(t.text,e+r,r);return n<0||n>t.text.length?null:n}function $o(t,e,r){var n=Zo(t,e.ch,r);return null==n?null:new te(e.line,n,r<0?"after":"before")}function ta(t,e,r,n,i){if(t){"rtl"==e.doc.direction&&(i=-i);var o=lt(r,e.doc.direction);if(o){var a,s=i<0?Y(o):o[0],A=i<0==(1==s.level)?"after":"before";if(s.level>0||"rtl"==e.doc.direction){var l=Ir(e,r);a=i<0?r.text.length-1:0;var c=_r(e,l,a).top;a=ot((function(t){return _r(e,l,t).top==c}),i<0==(1==s.level)?s.from:s.to-1,a),"before"==A&&(a=Zo(r,a,1))}else a=i<0?s.to:s.from;return new te(n,a,A)}}return new te(n,i<0?r.text.length:0,i<0?"before":"after")}jo.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},jo.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},jo.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},jo.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},jo.default=v?jo.macDefault:jo.pcDefault;var ea={selectAll:so,singleSelection:function(t){return t.setSelection(t.getCursor("anchor"),t.getCursor("head"),K)},killLine:function(t){return Jo(t,(function(e){if(e.empty()){var r=zt(t.doc,e.head.line).text.length;return e.head.ch==r&&e.head.line<t.lastLine()?{from:e.head,to:te(e.head.line+1,0)}:{from:e.head,to:te(e.head.line,r)}}return{from:e.from(),to:e.to()}}))},deleteLine:function(t){return Jo(t,(function(e){return{from:te(e.from().line,0),to:se(t.doc,te(e.to().line+1,0))}}))},delLineLeft:function(t){return Jo(t,(function(t){return{from:te(t.from().line,0),to:t.from()}}))},delWrappedLineLeft:function(t){return Jo(t,(function(e){var r=t.charCoords(e.head,"div").top+5;return{from:t.coordsChar({left:0,top:r},"div"),to:e.from()}}))},delWrappedLineRight:function(t){return Jo(t,(function(e){var r=t.charCoords(e.head,"div").top+5,n=t.coordsChar({left:t.display.lineDiv.offsetWidth+100,top:r},"div");return{from:e.from(),to:n}}))},undo:function(t){return t.undo()},redo:function(t){return t.redo()},undoSelection:function(t){return t.undoSelection()},redoSelection:function(t){return t.redoSelection()},goDocStart:function(t){return t.extendSelection(te(t.firstLine(),0))},goDocEnd:function(t){return t.extendSelection(te(t.lastLine()))},goLineStart:function(t){return t.extendSelectionsBy((function(e){return ra(t,e.head.line)}),{origin:"+move",bias:1})},goLineStartSmart:function(t){return t.extendSelectionsBy((function(e){return na(t,e.head)}),{origin:"+move",bias:1})},goLineEnd:function(t){return t.extendSelectionsBy((function(e){return function(t,e){var r=zt(t.doc,e),n=function(t){for(var e;e=De(t);)t=e.find(1,!0).line;return t}(r);return n!=r&&(e=qt(n)),ta(!0,t,r,e,-1)}(t,e.head.line)}),{origin:"+move",bias:-1})},goLineRight:function(t){return t.extendSelectionsBy((function(e){var r=t.cursorCoords(e.head,"div").top+5;return t.coordsChar({left:t.display.lineDiv.offsetWidth+100,top:r},"div")}),G)},goLineLeft:function(t){return t.extendSelectionsBy((function(e){var r=t.cursorCoords(e.head,"div").top+5;return t.coordsChar({left:0,top:r},"div")}),G)},goLineLeftSmart:function(t){return t.extendSelectionsBy((function(e){var r=t.cursorCoords(e.head,"div").top+5,n=t.coordsChar({left:0,top:r},"div");return n.ch<t.getLine(n.line).search(/\S/)?na(t,e.head):n}),G)},goLineUp:function(t){return t.moveV(-1,"line")},goLineDown:function(t){return t.moveV(1,"line")},goPageUp:function(t){return t.moveV(-1,"page")},goPageDown:function(t){return t.moveV(1,"page")},goCharLeft:function(t){return t.moveH(-1,"char")},goCharRight:function(t){return t.moveH(1,"char")},goColumnLeft:function(t){return t.moveH(-1,"column")},goColumnRight:function(t){return t.moveH(1,"column")},goWordLeft:function(t){return t.moveH(-1,"word")},goGroupRight:function(t){return t.moveH(1,"group")},goGroupLeft:function(t){return t.moveH(-1,"group")},goWordRight:function(t){return t.moveH(1,"word")},delCharBefore:function(t){return t.deleteH(-1,"codepoint")},delCharAfter:function(t){return t.deleteH(1,"char")},delWordBefore:function(t){return t.deleteH(-1,"word")},delWordAfter:function(t){return t.deleteH(1,"word")},delGroupBefore:function(t){return t.deleteH(-1,"group")},delGroupAfter:function(t){return t.deleteH(1,"group")},indentAuto:function(t){return t.indentSelection("smart")},indentMore:function(t){return t.indentSelection("add")},indentLess:function(t){return t.indentSelection("subtract")},insertTab:function(t){return t.replaceSelection("\t")},insertSoftTab:function(t){for(var e=[],r=t.listSelections(),n=t.options.tabSize,i=0;i<r.length;i++){var o=r[i].from(),a=R(t.getLine(o.line),o.ch,n);e.push(W(n-a%n))}t.replaceSelections(e)},defaultTab:function(t){t.somethingSelected()?t.indentSelection("add"):t.execCommand("insertTab")},transposeChars:function(t){return $n(t,(function(){for(var e=t.listSelections(),r=[],n=0;n<e.length;n++)if(e[n].empty()){var i=e[n].head,o=zt(t.doc,i.line).text;if(o)if(i.ch==o.length&&(i=new te(i.line,i.ch-1)),i.ch>0)i=new te(i.line,i.ch+1),t.replaceRange(o.charAt(i.ch-1)+o.charAt(i.ch-2),te(i.line,i.ch-2),i,"+transpose");else if(i.line>t.doc.first){var a=zt(t.doc,i.line-1).text;a&&(i=new te(i.line,1),t.replaceRange(o.charAt(0)+t.doc.lineSeparator()+a.charAt(a.length-1),te(i.line-1,a.length-1),i,"+transpose"))}r.push(new Bi(i,i))}t.setSelections(r)}))},newlineAndIndent:function(t){return $n(t,(function(){for(var e=t.listSelections(),r=e.length-1;r>=0;r--)t.replaceRange(t.doc.lineSeparator(),e[r].anchor,e[r].head,"+input");e=t.listSelections();for(var n=0;n<e.length;n++)t.indentLine(e[n].from().line,null,!0);In(t)}))},openLine:function(t){return t.replaceSelection("\n","start")},toggleOverwrite:function(t){return t.toggleOverwrite()}};function ra(t,e){var r=zt(t.doc,e),n=Re(r);return n!=r&&(e=qt(n)),ta(!0,t,n,e,1)}function na(t,e){var r=ra(t,e.line),n=zt(t.doc,r.line),i=lt(n,t.doc.direction);if(!i||0==i[0].level){var o=Math.max(r.ch,n.text.search(/\S/)),a=e.line==r.line&&e.ch<=o&&e.ch;return te(r.line,a?0:o,r.sticky)}return r}function ia(t,e,r){if("string"==typeof e&&!(e=ea[e]))return!1;t.display.input.ensurePolled();var n=t.display.shift,i=!1;try{t.isReadOnly()&&(t.state.suppressEdits=!0),r&&(t.display.shift=!1),i=e(t)!=N}finally{t.display.shift=n,t.state.suppressEdits=!1}return i}var oa=new P;function aa(t,e,r,n){var i=t.state.keySeq;if(i){if(Wo(e))return"handled";if(/\'$/.test(e)?t.state.keySeq=null:oa.set(50,(function(){t.state.keySeq==i&&(t.state.keySeq=null,t.display.input.reset())})),sa(t,i+" "+e,r,n))return!0}return sa(t,e,r,n)}function sa(t,e,r,n){var i=function(t,e,r){for(var n=0;n<t.state.keyMaps.length;n++){var i=zo(e,t.state.keyMaps[n],r,t);if(i)return i}return t.options.extraKeys&&zo(e,t.options.extraKeys,r,t)||zo(e,t.options.keyMap,r,t)}(t,e,n);return"multi"==i&&(t.state.keySeq=e),"handled"==i&&sr(t,"keyHandled",t,e,r),"handled"!=i&&"multi"!=i||(yt(r),bn(t)),!!i}function Aa(t,e){var r=Xo(e,!0);return!!r&&(e.shiftKey&&!t.state.keySeq?aa(t,"Shift-"+r,e,(function(e){return ia(t,e,!0)}))||aa(t,r,e,(function(e){if("string"==typeof e?/^go[A-Z]/.test(e):e.motion)return ia(t,e)})):aa(t,r,e,(function(e){return ia(t,e)})))}var la=null;function ca(t){var e=this;if(!(t.target&&t.target!=e.display.input.getField()||(e.curOp.focus=_(),pt(e,t)))){a&&s<11&&27==t.keyCode&&(t.returnValue=!1);var n=t.keyCode;e.display.shift=16==n||t.shiftKey;var i=Aa(e,t);u&&(la=i?n:null,i||88!=n||Ut||!(v?t.metaKey:t.ctrlKey)||e.replaceSelection("",null,"cut")),r&&!v&&!i&&46==n&&t.shiftKey&&!t.ctrlKey&&document.execCommand&&document.execCommand("cut"),18!=n||/\bCodeMirror-crosshair\b/.test(e.display.lineDiv.className)||function(t){var e=t.display.lineDiv;function r(t){18!=t.keyCode&&t.altKey||(S(e,"CodeMirror-crosshair"),dt(document,"keyup",r),dt(document,"mouseover",r))}U(e,"CodeMirror-crosshair"),ut(document,"keyup",r),ut(document,"mouseover",r)}(e)}}function ua(t){16==t.keyCode&&(this.doc.sel.shift=!1),pt(this,t)}function ha(t){var e=this;if(!(t.target&&t.target!=e.display.input.getField()||br(e.display,t)||pt(e,t)||t.ctrlKey&&!t.altKey||v&&t.metaKey)){var r=t.keyCode,n=t.charCode;if(u&&r==la)return la=null,void yt(t);if(!u||t.which&&!(t.which<10)||!Aa(e,t)){var i=String.fromCharCode(null==n?r:n);"\b"!=i&&(function(t,e,r){return aa(t,"'"+r+"'",e,(function(e){return ia(t,e,!0)}))}(e,t,i)||e.display.input.onKeyPress(t))}}}var da,fa,pa=function(t,e,r){this.time=t,this.pos=e,this.button=r};function ga(t){var e=this,r=e.display;if(!(pt(e,t)||r.activeTouch&&r.input.supportsTouch()))if(r.input.ensurePolled(),r.shift=t.shiftKey,br(r,t))A||(r.scroller.draggable=!1,setTimeout((function(){return r.scroller.draggable=!0}),100));else if(!ya(e,t)){var n=ln(e,t),i=xt(t),o=n?function(t,e){var r=+new Date;return fa&&fa.compare(r,t,e)?(da=fa=null,"triple"):da&&da.compare(r,t,e)?(fa=new pa(r,t,e),da=null,"double"):(da=new pa(r,t,e),fa=null,"single")}(n,i):"single";window.focus(),1==i&&e.state.selectingText&&e.state.selectingText(t),n&&function(t,e,r,n,i){var o="Click";return"double"==n?o="Double"+o:"triple"==n&&(o="Triple"+o),aa(t,Yo(o=(1==e?"Left":2==e?"Middle":"Right")+o,i),i,(function(e){if("string"==typeof e&&(e=ea[e]),!e)return!1;var n=!1;try{t.isReadOnly()&&(t.state.suppressEdits=!0),n=e(t,r)!=N}finally{t.state.suppressEdits=!1}return n}))}(e,i,n,o,t)||(1==i?n?function(t,e,r,n){a?setTimeout(Q(Cn,t),0):t.curOp.focus=_();var i,o=function(t,e,r){var n=t.getOption("configureMouse"),i=n?n(t,e,r):{};if(null==i.unit){var o=y?r.shiftKey&&r.metaKey:r.altKey;i.unit=o?"rectangle":"single"==e?"char":"double"==e?"word":"line"}return(null==i.extend||t.doc.extend)&&(i.extend=t.doc.extend||r.shiftKey),null==i.addNew&&(i.addNew=v?r.metaKey:r.ctrlKey),null==i.moveOnDrag&&(i.moveOnDrag=!(v?r.altKey:r.ctrlKey)),i}(t,r,n),l=t.doc.sel;t.options.dragDrop&&kt&&!t.isReadOnly()&&"single"==r&&(i=l.contains(e))>-1&&(ee((i=l.ranges[i]).from(),e)<0||e.xRel>0)&&(ee(i.to(),e)>0||e.xRel<0)?function(t,e,r,n){var i=t.display,o=!1,l=ti(t,(function(e){A&&(i.scroller.draggable=!1),t.state.draggingText=!1,dt(i.wrapper.ownerDocument,"mouseup",l),dt(i.wrapper.ownerDocument,"mousemove",c),dt(i.scroller,"dragstart",u),dt(i.scroller,"drop",l),o||(yt(e),n.addNew||Yi(t.doc,r,null,null,n.extend),A&&!h||a&&9==s?setTimeout((function(){i.wrapper.ownerDocument.body.focus({preventScroll:!0}),i.input.focus()}),20):i.input.focus())})),c=function(t){o=o||Math.abs(e.clientX-t.clientX)+Math.abs(e.clientY-t.clientY)>=10},u=function(){return o=!0};A&&(i.scroller.draggable=!0),t.state.draggingText=l,l.copy=!n.moveOnDrag,i.scroller.dragDrop&&i.scroller.dragDrop(),ut(i.wrapper.ownerDocument,"mouseup",l),ut(i.wrapper.ownerDocument,"mousemove",c),ut(i.scroller,"dragstart",u),ut(i.scroller,"drop",l),Bn(t),setTimeout((function(){return i.input.focus()}),20)}(t,n,e,o):function(t,e,r,n){var i=t.display,o=t.doc;yt(e);var a,s,A=o.sel,l=A.ranges;if(n.addNew&&!n.extend?(s=o.sel.contains(r),a=s>-1?l[s]:new Bi(r,r)):(a=o.sel.primary(),s=o.sel.primIndex),"rectangle"==n.unit)n.addNew||(a=new Bi(r,r)),r=ln(t,e,!0,!0),s=-1;else{var c=ma(t,r,n.unit);a=n.extend?Wi(a,c.anchor,c.head,n.extend):c}n.addNew?-1==s?(s=l.length,$i(o,xi(t,l.concat([a]),s),{scroll:!1,origin:"*mouse"})):l.length>1&&l[s].empty()&&"char"==n.unit&&!n.extend?($i(o,xi(t,l.slice(0,s).concat(l.slice(s+1)),0),{scroll:!1,origin:"*mouse"}),A=o.sel):qi(o,s,a,j):(s=0,$i(o,new Ci([a],0),j),A=o.sel);var u=r;function h(e){if(0!=ee(u,e))if(u=e,"rectangle"==n.unit){for(var i=[],l=t.options.tabSize,c=R(zt(o,r.line).text,r.ch,l),h=R(zt(o,e.line).text,e.ch,l),d=Math.min(c,h),f=Math.max(c,h),p=Math.min(r.line,e.line),g=Math.min(t.lastLine(),Math.max(r.line,e.line));p<=g;p++){var m=zt(o,p).text,v=V(m,d,l);d==f?i.push(new Bi(te(p,v),te(p,v))):m.length>v&&i.push(new Bi(te(p,v),te(p,V(m,f,l))))}i.length||i.push(new Bi(r,r)),$i(o,xi(t,A.ranges.slice(0,s).concat(i),s),{origin:"*mouse",scroll:!1}),t.scrollIntoView(e)}else{var y,w=a,b=ma(t,e,n.unit),C=w.anchor;ee(b.anchor,C)>0?(y=b.head,C=oe(w.from(),b.anchor)):(y=b.anchor,C=ie(w.to(),b.head));var B=A.ranges.slice(0);B[s]=function(t,e){var r=e.anchor,n=e.head,i=zt(t.doc,r.line);if(0==ee(r,n)&&r.sticky==n.sticky)return e;var o=lt(i);if(!o)return e;var a=st(o,r.ch,r.sticky),s=o[a];if(s.from!=r.ch&&s.to!=r.ch)return e;var A,l=a+(s.from==r.ch==(1!=s.level)?0:1);if(0==l||l==o.length)return e;if(n.line!=r.line)A=(n.line-r.line)*("ltr"==t.doc.direction?1:-1)>0;else{var c=st(o,n.ch,n.sticky),u=c-a||(n.ch-r.ch)*(1==s.level?-1:1);A=c==l-1||c==l?u<0:u>0}var h=o[l+(A?-1:0)],d=A==(1==h.level),f=d?h.from:h.to,p=d?"after":"before";return r.ch==f&&r.sticky==p?e:new Bi(new te(r.line,f,p),n)}(t,new Bi(se(o,C),y)),$i(o,xi(t,B,s),j)}}var d=i.wrapper.getBoundingClientRect(),f=0;function p(e){t.state.selectingText=!1,f=1/0,e&&(yt(e),i.input.focus()),dt(i.wrapper.ownerDocument,"mousemove",g),dt(i.wrapper.ownerDocument,"mouseup",m),o.history.lastSelOrigin=null}var g=ti(t,(function(e){0!==e.buttons&&xt(e)?function e(r){var a=++f,s=ln(t,r,!0,"rectangle"==n.unit);if(s)if(0!=ee(s,u)){t.curOp.focus=_(),h(s);var A=Tn(i,o);(s.line>=A.to||s.line<A.from)&&setTimeout(ti(t,(function(){f==a&&e(r)})),150)}else{var l=r.clientY<d.top?-20:r.clientY>d.bottom?20:0;l&&setTimeout(ti(t,(function(){f==a&&(i.scroller.scrollTop+=l,e(r))})),50)}}(e):p(e)})),m=ti(t,p);t.state.selectingText=m,ut(i.wrapper.ownerDocument,"mousemove",g),ut(i.wrapper.ownerDocument,"mouseup",m)}(t,n,e,o)}(e,n,o,t):Bt(t)==r.scroller&&yt(t):2==i?(n&&Yi(e.doc,n),setTimeout((function(){return r.input.focus()}),20)):3==i&&(B?e.display.input.onContextMenu(t):Bn(e)))}}function ma(t,e,r){if("char"==r)return new Bi(e,e);if("word"==r)return t.findWordAt(e);if("line"==r)return new Bi(te(e.line,0),se(t.doc,te(e.line+1,0)));var n=r(t,e);return new Bi(n.from,n.to)}function va(t,e,r,n){var i,o;if(e.touches)i=e.touches[0].clientX,o=e.touches[0].clientY;else try{i=e.clientX,o=e.clientY}catch(t){return!1}if(i>=Math.floor(t.display.gutters.getBoundingClientRect().right))return!1;n&&yt(e);var a=t.display,s=a.lineDiv.getBoundingClientRect();if(o>s.bottom||!mt(t,r))return bt(e);o-=s.top-a.viewOffset;for(var A=0;A<t.display.gutterSpecs.length;++A){var l=a.gutters.childNodes[A];if(l&&l.getBoundingClientRect().right>=i)return ft(t,r,t,Jt(t.doc,o),t.display.gutterSpecs[A].className,e),bt(e)}}function ya(t,e){return va(t,e,"gutterClick",!0)}function wa(t,e){br(t.display,e)||function(t,e){return!!mt(t,"gutterContextMenu")&&va(t,e,"gutterContextMenu",!1)}(t,e)||pt(t,e,"contextmenu")||B||t.display.input.onContextMenu(e)}function ba(t){t.display.wrapper.className=t.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+t.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Pr(t)}pa.prototype.compare=function(t,e,r){return this.time+400>t&&0==ee(e,this.pos)&&r==this.button};var Ca={toString:function(){return"CodeMirror.Init"}},Ba={},xa={};function Ea(t,e,r){if(!e!=!(r&&r!=Ca)){var n=t.display.dragFunctions,i=e?ut:dt;i(t.display.scroller,"dragstart",n.start),i(t.display.scroller,"dragenter",n.enter),i(t.display.scroller,"dragover",n.over),i(t.display.scroller,"dragleave",n.leave),i(t.display.scroller,"drop",n.drop)}}function Sa(t){t.options.lineWrapping?(U(t.display.wrapper,"CodeMirror-wrap"),t.display.sizer.style.minWidth="",t.display.sizerWidth=null):(S(t.display.wrapper,"CodeMirror-wrap"),Ve(t)),An(t),un(t),Pr(t),setTimeout((function(){return Nn(t)}),100)}function ka(t,e){var r=this;if(!(this instanceof ka))return new ka(t,e);this.options=e=e?M(e):{},M(Ba,e,!1);var n=e.value;"string"==typeof n?n=new Io(n,e.mode,null,e.lineSeparator,e.direction):e.mode&&(n.modeOption=e.mode),this.doc=n;var i=new ka.inputStyles[e.inputStyle](this),o=this.display=new gi(t,n,i,e);for(var l in o.wrapper.CodeMirror=this,ba(this),e.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),Gn(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new P,keySeq:null,specialChars:null},e.autofocus&&!m&&o.input.focus(),a&&s<11&&setTimeout((function(){return r.display.input.reset(!0)}),20),function(t){var e=t.display;ut(e.scroller,"mousedown",ti(t,ga)),ut(e.scroller,"dblclick",a&&s<11?ti(t,(function(e){if(!pt(t,e)){var r=ln(t,e);if(r&&!ya(t,e)&&!br(t.display,e)){yt(e);var n=t.findWordAt(r);Yi(t.doc,n.anchor,n.head)}}})):function(e){return pt(t,e)||yt(e)}),ut(e.scroller,"contextmenu",(function(e){return wa(t,e)})),ut(e.input.getField(),"contextmenu",(function(r){e.scroller.contains(r.target)||wa(t,r)}));var r,n={end:0};function i(){e.activeTouch&&(r=setTimeout((function(){return e.activeTouch=null}),1e3),(n=e.activeTouch).end=+new Date)}function o(t,e){if(null==e.left)return!0;var r=e.left-t.left,n=e.top-t.top;return r*r+n*n>400}ut(e.scroller,"touchstart",(function(i){if(!pt(t,i)&&!function(t){if(1!=t.touches.length)return!1;var e=t.touches[0];return e.radiusX<=1&&e.radiusY<=1}(i)&&!ya(t,i)){e.input.ensurePolled(),clearTimeout(r);var o=+new Date;e.activeTouch={start:o,moved:!1,prev:o-n.end<=300?n:null},1==i.touches.length&&(e.activeTouch.left=i.touches[0].pageX,e.activeTouch.top=i.touches[0].pageY)}})),ut(e.scroller,"touchmove",(function(){e.activeTouch&&(e.activeTouch.moved=!0)})),ut(e.scroller,"touchend",(function(r){var n=e.activeTouch;if(n&&!br(e,r)&&null!=n.left&&!n.moved&&new Date-n.start<300){var a,s=t.coordsChar(e.activeTouch,"page");a=!n.prev||o(n,n.prev)?new Bi(s,s):!n.prev.prev||o(n,n.prev.prev)?t.findWordAt(s):new Bi(te(s.line,0),se(t.doc,te(s.line+1,0))),t.setSelection(a.anchor,a.head),t.focus(),yt(r)}i()})),ut(e.scroller,"touchcancel",i),ut(e.scroller,"scroll",(function(){e.scroller.clientHeight&&(Dn(t,e.scroller.scrollTop),Mn(t,e.scroller.scrollLeft,!0),ft(t,"scroll",t))})),ut(e.scroller,"mousewheel",(function(e){return bi(t,e)})),ut(e.scroller,"DOMMouseScroll",(function(e){return bi(t,e)})),ut(e.wrapper,"scroll",(function(){return e.wrapper.scrollTop=e.wrapper.scrollLeft=0})),e.dragFunctions={enter:function(e){pt(t,e)||Ct(e)},over:function(e){pt(t,e)||(function(t,e){var r=ln(t,e);if(r){var n=document.createDocumentFragment();vn(t,r,n),t.display.dragCursor||(t.display.dragCursor=F("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),t.display.lineSpace.insertBefore(t.display.dragCursor,t.display.cursorDiv)),T(t.display.dragCursor,n)}}(t,e),Ct(e))},start:function(e){return function(t,e){if(a&&(!t.state.draggingText||+new Date-_o<100))Ct(e);else if(!pt(t,e)&&!br(t.display,e)&&(e.dataTransfer.setData("Text",t.getSelection()),e.dataTransfer.effectAllowed="copyMove",e.dataTransfer.setDragImage&&!h)){var r=F("img",null,null,"position: fixed; left: 0; top: 0;");r.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",u&&(r.width=r.height=1,t.display.wrapper.appendChild(r),r._top=r.offsetTop),e.dataTransfer.setDragImage(r,0,0),u&&r.parentNode.removeChild(r)}}(t,e)},drop:ti(t,Uo),leave:function(e){pt(t,e)||Oo(t)}};var A=e.input.getField();ut(A,"keyup",(function(e){return ua.call(t,e)})),ut(A,"keydown",ti(t,ca)),ut(A,"keypress",ti(t,ha)),ut(A,"focus",(function(e){return xn(t,e)})),ut(A,"blur",(function(e){return En(t,e)}))}(this),Mo(),zn(this),this.curOp.forceUpdate=!0,Di(this,n),e.autofocus&&!m||this.hasFocus()?setTimeout((function(){r.hasFocus()&&!r.state.focused&&xn(r)}),20):En(this),xa)xa.hasOwnProperty(l)&&xa[l](this,e[l],Ca);hi(this),e.finishInit&&e.finishInit(this);for(var c=0;c<Ta.length;++c)Ta[c](this);Wn(this),A&&e.lineWrapping&&"optimizelegibility"==getComputedStyle(o.lineDiv).textRendering&&(o.lineDiv.style.textRendering="auto")}ka.defaults=Ba,ka.optionHandlers=xa;var Ta=[];function Fa(t,e,r,n){var i,o=t.doc;null==r&&(r="add"),"smart"==r&&(o.mode.indent?i=de(t,e).state:r="prev");var a=t.options.tabSize,s=zt(o,e),A=R(s.text,null,a);s.stateAfter&&(s.stateAfter=null);var l,c=s.text.match(/^\s*/)[0];if(n||/\S/.test(s.text)){if("smart"==r&&((l=o.mode.indent(i,s.text.slice(c.length),s.text))==N||l>150)){if(!n)return;r="prev"}}else l=0,r="not";"prev"==r?l=e>o.first?R(zt(o,e-1).text,null,a):0:"add"==r?l=A+t.options.indentUnit:"subtract"==r?l=A-t.options.indentUnit:"number"==typeof r&&(l=A+r),l=Math.max(0,l);var u="",h=0;if(t.options.indentWithTabs)for(var d=Math.floor(l/a);d;--d)h+=a,u+="\t";if(h<l&&(u+=W(l-h)),u!=c)return po(o,u,te(e,0),te(e,c.length),"+input"),s.stateAfter=null,!0;for(var f=0;f<o.sel.ranges.length;f++){var p=o.sel.ranges[f];if(p.head.line==e&&p.head.ch<c.length){var g=te(e,c.length);qi(o,f,new Bi(g,g));break}}}ka.defineInitHook=function(t){return Ta.push(t)};var La=null;function Ia(t){La=t}function _a(t,e,r,n,i){var o=t.doc;t.display.shift=!1,n||(n=o.sel);var a=+new Date-200,s="paste"==i||t.state.pasteIncoming>a,A=It(e),l=null;if(s&&n.ranges.length>1)if(La&&La.text.join("\n")==e){if(n.ranges.length%La.text.length==0){l=[];for(var c=0;c<La.text.length;c++)l.push(o.splitLines(La.text[c]))}}else A.length==n.ranges.length&&t.options.pasteLinesPerSelection&&(l=X(A,(function(t){return[t]})));for(var u=t.curOp.updateInput,h=n.ranges.length-1;h>=0;h--){var d=n.ranges[h],f=d.from(),p=d.to();d.empty()&&(r&&r>0?f=te(f.line,f.ch-r):t.state.overwrite&&!s?p=te(p.line,Math.min(zt(o,p.line).text.length,p.ch+Y(A).length)):s&&La&&La.lineWise&&La.text.join("\n")==A.join("\n")&&(f=p=te(f.line,0)));var g={from:f,to:p,text:l?l[h%l.length]:A,origin:i||(s?"paste":t.state.cutIncoming>a?"cut":"+input")};lo(t.doc,g),sr(t,"inputRead",t,g)}e&&!s&&Oa(t,e),In(t),t.curOp.updateInput<2&&(t.curOp.updateInput=u),t.curOp.typing=!0,t.state.pasteIncoming=t.state.cutIncoming=-1}function Ua(t,e){var r=t.clipboardData&&t.clipboardData.getData("Text");if(r)return t.preventDefault(),e.isReadOnly()||e.options.disableInput||$n(e,(function(){return _a(e,r,0,null,"paste")})),!0}function Oa(t,e){if(t.options.electricChars&&t.options.smartIndent)for(var r=t.doc.sel,n=r.ranges.length-1;n>=0;n--){var i=r.ranges[n];if(!(i.head.ch>100||n&&r.ranges[n-1].head.line==i.head.line)){var o=t.getModeAt(i.head),a=!1;if(o.electricChars){for(var s=0;s<o.electricChars.length;s++)if(e.indexOf(o.electricChars.charAt(s))>-1){a=Fa(t,i.head.line,"smart");break}}else o.electricInput&&o.electricInput.test(zt(t.doc,i.head.line).text.slice(0,i.head.ch))&&(a=Fa(t,i.head.line,"smart"));a&&sr(t,"electricInput",t,i.head.line)}}}function Da(t){for(var e=[],r=[],n=0;n<t.doc.sel.ranges.length;n++){var i=t.doc.sel.ranges[n].head.line,o={anchor:te(i,0),head:te(i+1,0)};r.push(o),e.push(t.getRange(o.anchor,o.head))}return{text:e,ranges:r}}function Qa(t,e,r,n){t.setAttribute("autocorrect",r?"":"off"),t.setAttribute("autocapitalize",n?"":"off"),t.setAttribute("spellcheck",!!e)}function Ma(){var t=F("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none"),e=F("div",[t],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return A?t.style.width="1000px":t.setAttribute("wrap","off"),p&&(t.style.border="1px solid black"),Qa(t),e}function Ra(t,e,r,n,i){var o=e,a=r,s=zt(t,e.line),A=i&&"rtl"==t.direction?-r:r;function l(o){var a,l;if("codepoint"==n){var c=s.text.charCodeAt(e.ch+(n>0?0:-1));a=isNaN(c)?null:new te(e.line,Math.max(0,Math.min(s.text.length,e.ch+r*(c>=55296&&c<56320?2:1))),-r)}else a=i?function(t,e,r,n){var i=lt(e,t.doc.direction);if(!i)return $o(e,r,n);r.ch>=e.text.length?(r.ch=e.text.length,r.sticky="before"):r.ch<=0&&(r.ch=0,r.sticky="after");var o=st(i,r.ch,r.sticky),a=i[o];if("ltr"==t.doc.direction&&a.level%2==0&&(n>0?a.to>r.ch:a.from<r.ch))return $o(e,r,n);var s,A=function(t,r){return Zo(e,t instanceof te?t.ch:t,r)},l=function(r){return t.options.lineWrapping?(s=s||Ir(t,e),Jr(t,e,s,r)):{begin:0,end:e.text.length}},c=l("before"==r.sticky?A(r,-1):r.ch);if("rtl"==t.doc.direction||1==a.level){var u=1==a.level==n<0,h=A(r,u?1:-1);if(null!=h&&(u?h<=a.to&&h<=c.end:h>=a.from&&h>=c.begin)){var d=u?"before":"after";return new te(r.line,h,d)}}var f=function(t,e,n){for(var o=function(t,e){return e?new te(r.line,A(t,1),"before"):new te(r.line,t,"after")};t>=0&&t<i.length;t+=e){var a=i[t],s=e>0==(1!=a.level),l=s?n.begin:A(n.end,-1);if(a.from<=l&&l<a.to)return o(l,s);if(l=s?a.from:A(a.to,-1),n.begin<=l&&l<n.end)return o(l,s)}},p=f(o+n,n,c);if(p)return p;var g=n>0?c.end:A(c.begin,-1);return null==g||n>0&&g==e.text.length||!(p=f(n>0?0:i.length-1,n,l(g)))?null:p}(t.cm,s,e,r):$o(s,e,r);if(null==a){if(o||(l=e.line+A)<t.first||l>=t.first+t.size||(e=new te(l,e.ch,e.sticky),!(s=zt(t,l))))return!1;e=ta(i,t.cm,s,e.line,A)}else e=a;return!0}if("char"==n||"codepoint"==n)l();else if("column"==n)l(!0);else if("word"==n||"group"==n)for(var c=null,u="group"==n,h=t.cm&&t.cm.getHelper(e,"wordChars"),d=!0;!(r<0)||l(!d);d=!1){var f=s.text.charAt(e.ch)||"\n",p=tt(f,h)?"w":u&&"\n"==f?"n":!u||/\s/.test(f)?null:"p";if(!u||d||p||(p="s"),c&&c!=p){r<0&&(r=1,l(),e.sticky="after");break}if(p&&(c=p),r>0&&!l(!d))break}var g=oo(t,e,o,a,!0);return re(o,g)&&(g.hitSide=!0),g}function Pa(t,e,r,n){var i,o,a=t.doc,s=e.left;if("page"==n){var A=Math.min(t.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),l=Math.max(A-.5*rn(t.display),3);i=(r>0?e.bottom:e.top)+r*l}else"line"==n&&(i=r>0?e.bottom+3:e.top-3);for(;(o=Xr(t,s,i)).outside;){if(r<0?i<=0:i>=a.height){o.hitSide=!0;break}i+=5*r}return o}var Ha=function(t){this.cm=t,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new P,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};function Na(t,e){var r=Lr(t,e.line);if(!r||r.hidden)return null;var n=zt(t.doc,e.line),i=Tr(r,n,e.line),o=lt(n,t.doc.direction),a="left";o&&(a=st(o,e.ch)%2?"right":"left");var s=Dr(i.map,e.ch,a);return s.offset="right"==s.collapse?s.end:s.start,s}function Ka(t,e){return e&&(t.bad=!0),t}function ja(t,e,r){var n;if(e==t.display.lineDiv){if(!(n=t.display.lineDiv.childNodes[r]))return Ka(t.clipPos(te(t.display.viewTo-1)),!0);e=null,r=0}else for(n=e;;n=n.parentNode){if(!n||n==t.display.lineDiv)return null;if(n.parentNode&&n.parentNode==t.display.lineDiv)break}for(var i=0;i<t.display.view.length;i++){var o=t.display.view[i];if(o.node==n)return Ga(o,e,r)}}function Ga(t,e,r){var n=t.text.firstChild,i=!1;if(!e||!I(n,e))return Ka(te(qt(t.line),0),!0);if(e==n&&(i=!0,e=n.childNodes[r],r=0,!e)){var o=t.rest?Y(t.rest):t.line;return Ka(te(qt(o),o.text.length),i)}var a=3==e.nodeType?e:null,s=e;for(a||1!=e.childNodes.length||3!=e.firstChild.nodeType||(a=e.firstChild,r&&(r=a.nodeValue.length));s.parentNode!=n;)s=s.parentNode;var A=t.measure,l=A.maps;function c(e,r,n){for(var i=-1;i<(l?l.length:0);i++)for(var o=i<0?A.map:l[i],a=0;a<o.length;a+=3){var s=o[a+2];if(s==e||s==r){var c=qt(i<0?t.line:t.rest[i]),u=o[a]+n;return(n<0||s!=e)&&(u=o[a+(n?1:0)]),te(c,u)}}}var u=c(a,s,r);if(u)return Ka(u,i);for(var h=s.nextSibling,d=a?a.nodeValue.length-r:0;h;h=h.nextSibling){if(u=c(h,h.firstChild,0))return Ka(te(u.line,u.ch-d),i);d+=h.textContent.length}for(var f=s.previousSibling,p=r;f;f=f.previousSibling){if(u=c(f,f.firstChild,-1))return Ka(te(u.line,u.ch+p),i);p+=f.textContent.length}}Ha.prototype.init=function(t){var e=this,r=this,n=r.cm,i=r.div=t.lineDiv;function o(t){for(var e=t.target;e;e=e.parentNode){if(e==i)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(e.className))break}return!1}function a(t){if(o(t)&&!pt(n,t)){if(n.somethingSelected())Ia({lineWise:!1,text:n.getSelections()}),"cut"==t.type&&n.replaceSelection("",null,"cut");else{if(!n.options.lineWiseCopyCut)return;var e=Da(n);Ia({lineWise:!0,text:e.text}),"cut"==t.type&&n.operation((function(){n.setSelections(e.ranges,0,K),n.replaceSelection("",null,"cut")}))}if(t.clipboardData){t.clipboardData.clearData();var a=La.text.join("\n");if(t.clipboardData.setData("Text",a),t.clipboardData.getData("Text")==a)return void t.preventDefault()}var s=Ma(),A=s.firstChild;n.display.lineSpace.insertBefore(s,n.display.lineSpace.firstChild),A.value=La.text.join("\n");var l=document.activeElement;D(A),setTimeout((function(){n.display.lineSpace.removeChild(s),l.focus(),l==i&&r.showPrimarySelection()}),50)}}Qa(i,n.options.spellcheck,n.options.autocorrect,n.options.autocapitalize),ut(i,"paste",(function(t){!o(t)||pt(n,t)||Ua(t,n)||s<=11&&setTimeout(ti(n,(function(){return e.updateFromDOM()})),20)})),ut(i,"compositionstart",(function(t){e.composing={data:t.data,done:!1}})),ut(i,"compositionupdate",(function(t){e.composing||(e.composing={data:t.data,done:!1})})),ut(i,"compositionend",(function(t){e.composing&&(t.data!=e.composing.data&&e.readFromDOMSoon(),e.composing.done=!0)})),ut(i,"touchstart",(function(){return r.forceCompositionEnd()})),ut(i,"input",(function(){e.composing||e.readFromDOMSoon()})),ut(i,"copy",a),ut(i,"cut",a)},Ha.prototype.screenReaderLabelChanged=function(t){t?this.div.setAttribute("aria-label",t):this.div.removeAttribute("aria-label")},Ha.prototype.prepareSelection=function(){var t=mn(this.cm,!1);return t.focus=document.activeElement==this.div,t},Ha.prototype.showSelection=function(t,e){t&&this.cm.display.view.length&&((t.focus||e)&&this.showPrimarySelection(),this.showMultipleSelections(t))},Ha.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},Ha.prototype.showPrimarySelection=function(){var t=this.getSelection(),e=this.cm,n=e.doc.sel.primary(),i=n.from(),o=n.to();if(e.display.viewTo==e.display.viewFrom||i.line>=e.display.viewTo||o.line<e.display.viewFrom)t.removeAllRanges();else{var a=ja(e,t.anchorNode,t.anchorOffset),s=ja(e,t.focusNode,t.focusOffset);if(!a||a.bad||!s||s.bad||0!=ee(oe(a,s),i)||0!=ee(ie(a,s),o)){var A=e.display.view,l=i.line>=e.display.viewFrom&&Na(e,i)||{node:A[0].measure.map[2],offset:0},c=o.line<e.display.viewTo&&Na(e,o);if(!c){var u=A[A.length-1].measure,h=u.maps?u.maps[u.maps.length-1]:u.map;c={node:h[h.length-1],offset:h[h.length-2]-h[h.length-3]}}if(l&&c){var d,f=t.rangeCount&&t.getRangeAt(0);try{d=E(l.node,l.offset,c.offset,c.node)}catch(t){}d&&(!r&&e.state.focused?(t.collapse(l.node,l.offset),d.collapsed||(t.removeAllRanges(),t.addRange(d))):(t.removeAllRanges(),t.addRange(d)),f&&null==t.anchorNode?t.addRange(f):r&&this.startGracePeriod()),this.rememberSelection()}else t.removeAllRanges()}}},Ha.prototype.startGracePeriod=function(){var t=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout((function(){t.gracePeriod=!1,t.selectionChanged()&&t.cm.operation((function(){return t.cm.curOp.selectionChanged=!0}))}),20)},Ha.prototype.showMultipleSelections=function(t){T(this.cm.display.cursorDiv,t.cursors),T(this.cm.display.selectionDiv,t.selection)},Ha.prototype.rememberSelection=function(){var t=this.getSelection();this.lastAnchorNode=t.anchorNode,this.lastAnchorOffset=t.anchorOffset,this.lastFocusNode=t.focusNode,this.lastFocusOffset=t.focusOffset},Ha.prototype.selectionInEditor=function(){var t=this.getSelection();if(!t.rangeCount)return!1;var e=t.getRangeAt(0).commonAncestorContainer;return I(this.div,e)},Ha.prototype.focus=function(){"nocursor"!=this.cm.options.readOnly&&(this.selectionInEditor()&&document.activeElement==this.div||this.showSelection(this.prepareSelection(),!0),this.div.focus())},Ha.prototype.blur=function(){this.div.blur()},Ha.prototype.getField=function(){return this.div},Ha.prototype.supportsTouch=function(){return!0},Ha.prototype.receivedFocus=function(){var t=this;this.selectionInEditor()?this.pollSelection():$n(this.cm,(function(){return t.cm.curOp.selectionChanged=!0})),this.polling.set(this.cm.options.pollInterval,(function e(){t.cm.state.focused&&(t.pollSelection(),t.polling.set(t.cm.options.pollInterval,e))}))},Ha.prototype.selectionChanged=function(){var t=this.getSelection();return t.anchorNode!=this.lastAnchorNode||t.anchorOffset!=this.lastAnchorOffset||t.focusNode!=this.lastFocusNode||t.focusOffset!=this.lastFocusOffset},Ha.prototype.pollSelection=function(){if(null==this.readDOMTimeout&&!this.gracePeriod&&this.selectionChanged()){var t=this.getSelection(),e=this.cm;if(g&&c&&this.cm.display.gutterSpecs.length&&function(t){for(var e=t;e;e=e.parentNode)if(/CodeMirror-gutter-wrapper/.test(e.className))return!0;return!1}(t.anchorNode))return this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),void this.focus();if(!this.composing){this.rememberSelection();var r=ja(e,t.anchorNode,t.anchorOffset),n=ja(e,t.focusNode,t.focusOffset);r&&n&&$n(e,(function(){$i(e.doc,Ei(r,n),K),(r.bad||n.bad)&&(e.curOp.selectionChanged=!0)}))}}},Ha.prototype.pollContent=function(){null!=this.readDOMTimeout&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var t,e,r,n=this.cm,i=n.display,o=n.doc.sel.primary(),a=o.from(),s=o.to();if(0==a.ch&&a.line>n.firstLine()&&(a=te(a.line-1,zt(n.doc,a.line-1).length)),s.ch==zt(n.doc,s.line).text.length&&s.line<n.lastLine()&&(s=te(s.line+1,0)),a.line<i.viewFrom||s.line>i.viewTo-1)return!1;a.line==i.viewFrom||0==(t=cn(n,a.line))?(e=qt(i.view[0].line),r=i.view[0].node):(e=qt(i.view[t].line),r=i.view[t-1].node.nextSibling);var A,l,c=cn(n,s.line);if(c==i.view.length-1?(A=i.viewTo-1,l=i.lineDiv.lastChild):(A=qt(i.view[c+1].line)-1,l=i.view[c+1].node.previousSibling),!r)return!1;for(var u=n.doc.splitLines(function(t,e,r,n,i){var o="",a=!1,s=t.doc.lineSeparator(),A=!1;function l(){a&&(o+=s,A&&(o+=s),a=A=!1)}function c(t){t&&(l(),o+=t)}function u(e){if(1==e.nodeType){var r=e.getAttribute("cm-text");if(r)return void c(r);var o,h=e.getAttribute("cm-marker");if(h){var d=t.findMarks(te(n,0),te(i+1,0),(g=+h,function(t){return t.id==g}));return void(d.length&&(o=d[0].find(0))&&c(Wt(t.doc,o.from,o.to).join(s)))}if("false"==e.getAttribute("contenteditable"))return;var f=/^(pre|div|p|li|table|br)$/i.test(e.nodeName);if(!/^br$/i.test(e.nodeName)&&0==e.textContent.length)return;f&&l();for(var p=0;p<e.childNodes.length;p++)u(e.childNodes[p]);/^(pre|p)$/i.test(e.nodeName)&&(A=!0),f&&(a=!0)}else 3==e.nodeType&&c(e.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "));var g}for(;u(e),e!=r;)e=e.nextSibling,A=!1;return o}(n,r,l,e,A)),h=Wt(n.doc,te(e,0),te(A,zt(n.doc,A).text.length));u.length>1&&h.length>1;)if(Y(u)==Y(h))u.pop(),h.pop(),A--;else{if(u[0]!=h[0])break;u.shift(),h.shift(),e++}for(var d=0,f=0,p=u[0],g=h[0],m=Math.min(p.length,g.length);d<m&&p.charCodeAt(d)==g.charCodeAt(d);)++d;for(var v=Y(u),y=Y(h),w=Math.min(v.length-(1==u.length?d:0),y.length-(1==h.length?d:0));f<w&&v.charCodeAt(v.length-f-1)==y.charCodeAt(y.length-f-1);)++f;if(1==u.length&&1==h.length&&e==a.line)for(;d&&d>a.ch&&v.charCodeAt(v.length-f-1)==y.charCodeAt(y.length-f-1);)d--,f++;u[u.length-1]=v.slice(0,v.length-f).replace(/^\u200b+/,""),u[0]=u[0].slice(d).replace(/\u200b+$/,"");var b=te(e,d),C=te(A,h.length?Y(h).length-f:0);return u.length>1||u[0]||ee(b,C)?(po(n.doc,u,b,C,"+input"),!0):void 0},Ha.prototype.ensurePolled=function(){this.forceCompositionEnd()},Ha.prototype.reset=function(){this.forceCompositionEnd()},Ha.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Ha.prototype.readFromDOMSoon=function(){var t=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout((function(){if(t.readDOMTimeout=null,t.composing){if(!t.composing.done)return;t.composing=null}t.updateFromDOM()}),80))},Ha.prototype.updateFromDOM=function(){var t=this;!this.cm.isReadOnly()&&this.pollContent()||$n(this.cm,(function(){return un(t.cm)}))},Ha.prototype.setUneditable=function(t){t.contentEditable="false"},Ha.prototype.onKeyPress=function(t){0==t.charCode||this.composing||(t.preventDefault(),this.cm.isReadOnly()||ti(this.cm,_a)(this.cm,String.fromCharCode(null==t.charCode?t.keyCode:t.charCode),0))},Ha.prototype.readOnlyChanged=function(t){this.div.contentEditable=String("nocursor"!=t)},Ha.prototype.onContextMenu=function(){},Ha.prototype.resetPosition=function(){},Ha.prototype.needsContentAttribute=!0;var Va=function(t){this.cm=t,this.prevInput="",this.pollingFast=!1,this.polling=new P,this.hasSelection=!1,this.composing=null};Va.prototype.init=function(t){var e=this,r=this,n=this.cm;this.createField(t);var i=this.textarea;function o(t){if(!pt(n,t)){if(n.somethingSelected())Ia({lineWise:!1,text:n.getSelections()});else{if(!n.options.lineWiseCopyCut)return;var e=Da(n);Ia({lineWise:!0,text:e.text}),"cut"==t.type?n.setSelections(e.ranges,null,K):(r.prevInput="",i.value=e.text.join("\n"),D(i))}"cut"==t.type&&(n.state.cutIncoming=+new Date)}}t.wrapper.insertBefore(this.wrapper,t.wrapper.firstChild),p&&(i.style.width="0px"),ut(i,"input",(function(){a&&s>=9&&e.hasSelection&&(e.hasSelection=null),r.poll()})),ut(i,"paste",(function(t){pt(n,t)||Ua(t,n)||(n.state.pasteIncoming=+new Date,r.fastPoll())})),ut(i,"cut",o),ut(i,"copy",o),ut(t.scroller,"paste",(function(e){if(!br(t,e)&&!pt(n,e)){if(!i.dispatchEvent)return n.state.pasteIncoming=+new Date,void r.focus();var o=new Event("paste");o.clipboardData=e.clipboardData,i.dispatchEvent(o)}})),ut(t.lineSpace,"selectstart",(function(e){br(t,e)||yt(e)})),ut(i,"compositionstart",(function(){var t=n.getCursor("from");r.composing&&r.composing.range.clear(),r.composing={start:t,range:n.markText(t,n.getCursor("to"),{className:"CodeMirror-composing"})}})),ut(i,"compositionend",(function(){r.composing&&(r.poll(),r.composing.range.clear(),r.composing=null)}))},Va.prototype.createField=function(t){this.wrapper=Ma(),this.textarea=this.wrapper.firstChild},Va.prototype.screenReaderLabelChanged=function(t){t?this.textarea.setAttribute("aria-label",t):this.textarea.removeAttribute("aria-label")},Va.prototype.prepareSelection=function(){var t=this.cm,e=t.display,r=t.doc,n=mn(t);if(t.options.moveInputWithCursor){var i=zr(t,r.sel.primary().head,"div"),o=e.wrapper.getBoundingClientRect(),a=e.lineDiv.getBoundingClientRect();n.teTop=Math.max(0,Math.min(e.wrapper.clientHeight-10,i.top+a.top-o.top)),n.teLeft=Math.max(0,Math.min(e.wrapper.clientWidth-10,i.left+a.left-o.left))}return n},Va.prototype.showSelection=function(t){var e=this.cm.display;T(e.cursorDiv,t.cursors),T(e.selectionDiv,t.selection),null!=t.teTop&&(this.wrapper.style.top=t.teTop+"px",this.wrapper.style.left=t.teLeft+"px")},Va.prototype.reset=function(t){if(!this.contextMenuPending&&!this.composing){var e=this.cm;if(e.somethingSelected()){this.prevInput="";var r=e.getSelection();this.textarea.value=r,e.state.focused&&D(this.textarea),a&&s>=9&&(this.hasSelection=r)}else t||(this.prevInput=this.textarea.value="",a&&s>=9&&(this.hasSelection=null))}},Va.prototype.getField=function(){return this.textarea},Va.prototype.supportsTouch=function(){return!1},Va.prototype.focus=function(){if("nocursor"!=this.cm.options.readOnly&&(!m||_()!=this.textarea))try{this.textarea.focus()}catch(t){}},Va.prototype.blur=function(){this.textarea.blur()},Va.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Va.prototype.receivedFocus=function(){this.slowPoll()},Va.prototype.slowPoll=function(){var t=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,(function(){t.poll(),t.cm.state.focused&&t.slowPoll()}))},Va.prototype.fastPoll=function(){var t=!1,e=this;e.pollingFast=!0,e.polling.set(20,(function r(){e.poll()||t?(e.pollingFast=!1,e.slowPoll()):(t=!0,e.polling.set(60,r))}))},Va.prototype.poll=function(){var t=this,e=this.cm,r=this.textarea,n=this.prevInput;if(this.contextMenuPending||!e.state.focused||_t(r)&&!n&&!this.composing||e.isReadOnly()||e.options.disableInput||e.state.keySeq)return!1;var i=r.value;if(i==n&&!e.somethingSelected())return!1;if(a&&s>=9&&this.hasSelection===i||v&&/[\uf700-\uf7ff]/.test(i))return e.display.input.reset(),!1;if(e.doc.sel==e.display.selForContextMenu){var o=i.charCodeAt(0);if(8203!=o||n||(n=""),8666==o)return this.reset(),this.cm.execCommand("undo")}for(var A=0,l=Math.min(n.length,i.length);A<l&&n.charCodeAt(A)==i.charCodeAt(A);)++A;return $n(e,(function(){_a(e,i.slice(A),n.length-A,null,t.composing?"*compose":null),i.length>1e3||i.indexOf("\n")>-1?r.value=t.prevInput="":t.prevInput=i,t.composing&&(t.composing.range.clear(),t.composing.range=e.markText(t.composing.start,e.getCursor("to"),{className:"CodeMirror-composing"}))})),!0},Va.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Va.prototype.onKeyPress=function(){a&&s>=9&&(this.hasSelection=null),this.fastPoll()},Va.prototype.onContextMenu=function(t){var e=this,r=e.cm,n=r.display,i=e.textarea;e.contextMenuPending&&e.contextMenuPending();var o=ln(r,t),l=n.scroller.scrollTop;if(o&&!u){r.options.resetSelectionOnContextMenu&&-1==r.doc.sel.contains(o)&&ti(r,$i)(r.doc,Ei(o),K);var c,h=i.style.cssText,d=e.wrapper.style.cssText,f=e.wrapper.offsetParent.getBoundingClientRect();if(e.wrapper.style.cssText="position: static",i.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(t.clientY-f.top-5)+"px; left: "+(t.clientX-f.left-5)+"px;\n z-index: 1000; background: "+(a?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);",A&&(c=window.scrollY),n.input.focus(),A&&window.scrollTo(null,c),n.input.reset(),r.somethingSelected()||(i.value=e.prevInput=" "),e.contextMenuPending=m,n.selForContextMenu=r.doc.sel,clearTimeout(n.detectingSelectAll),a&&s>=9&&g(),B){Ct(t);var p=function(){dt(window,"mouseup",p),setTimeout(m,20)};ut(window,"mouseup",p)}else setTimeout(m,50)}function g(){if(null!=i.selectionStart){var t=r.somethingSelected(),o=""+(t?i.value:"");i.value="⇚",i.value=o,e.prevInput=t?"":"",i.selectionStart=1,i.selectionEnd=o.length,n.selForContextMenu=r.doc.sel}}function m(){if(e.contextMenuPending==m&&(e.contextMenuPending=!1,e.wrapper.style.cssText=d,i.style.cssText=h,a&&s<9&&n.scrollbars.setScrollTop(n.scroller.scrollTop=l),null!=i.selectionStart)){(!a||a&&s<9)&&g();var t=0,o=function(){n.selForContextMenu==r.doc.sel&&0==i.selectionStart&&i.selectionEnd>0&&""==e.prevInput?ti(r,so)(r):t++<10?n.detectingSelectAll=setTimeout(o,500):(n.selForContextMenu=null,n.input.reset())};n.detectingSelectAll=setTimeout(o,200)}}},Va.prototype.readOnlyChanged=function(t){t||this.reset(),this.textarea.disabled="nocursor"==t,this.textarea.readOnly=!!t},Va.prototype.setUneditable=function(){},Va.prototype.needsContentAttribute=!1,function(t){var e=t.optionHandlers;function r(r,n,i,o){t.defaults[r]=n,i&&(e[r]=o?function(t,e,r){r!=Ca&&i(t,e,r)}:i)}t.defineOption=r,t.Init=Ca,r("value","",(function(t,e){return t.setValue(e)}),!0),r("mode",null,(function(t,e){t.doc.modeOption=e,Li(t)}),!0),r("indentUnit",2,Li,!0),r("indentWithTabs",!1),r("smartIndent",!0),r("tabSize",4,(function(t){Ii(t),Pr(t),un(t)}),!0),r("lineSeparator",null,(function(t,e){if(t.doc.lineSep=e,e){var r=[],n=t.doc.first;t.doc.iter((function(t){for(var i=0;;){var o=t.text.indexOf(e,i);if(-1==o)break;i=o+e.length,r.push(te(n,o))}n++}));for(var i=r.length-1;i>=0;i--)po(t.doc,e,r[i],te(r[i].line,r[i].ch+e.length))}})),r("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200c\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,(function(t,e,r){t.state.specialChars=new RegExp(e.source+(e.test("\t")?"":"|\t"),"g"),r!=Ca&&t.refresh()})),r("specialCharPlaceholder",Ze,(function(t){return t.refresh()}),!0),r("electricChars",!0),r("inputStyle",m?"contenteditable":"textarea",(function(){throw new Error("inputStyle can not (yet) be changed in a running editor")}),!0),r("spellcheck",!1,(function(t,e){return t.getInputField().spellcheck=e}),!0),r("autocorrect",!1,(function(t,e){return t.getInputField().autocorrect=e}),!0),r("autocapitalize",!1,(function(t,e){return t.getInputField().autocapitalize=e}),!0),r("rtlMoveVisually",!w),r("wholeLineUpdateBefore",!0),r("theme","default",(function(t){ba(t),pi(t)}),!0),r("keyMap","default",(function(t,e,r){var n=qo(e),i=r!=Ca&&qo(r);i&&i.detach&&i.detach(t,n),n.attach&&n.attach(t,i||null)})),r("extraKeys",null),r("configureMouse",null),r("lineWrapping",!1,Sa,!0),r("gutters",[],(function(t,e){t.display.gutterSpecs=di(e,t.options.lineNumbers),pi(t)}),!0),r("fixedGutter",!0,(function(t,e){t.display.gutters.style.left=e?an(t.display)+"px":"0",t.refresh()}),!0),r("coverGutterNextToScrollbar",!1,(function(t){return Nn(t)}),!0),r("scrollbarStyle","native",(function(t){Gn(t),Nn(t),t.display.scrollbars.setScrollTop(t.doc.scrollTop),t.display.scrollbars.setScrollLeft(t.doc.scrollLeft)}),!0),r("lineNumbers",!1,(function(t,e){t.display.gutterSpecs=di(t.options.gutters,e),pi(t)}),!0),r("firstLineNumber",1,pi,!0),r("lineNumberFormatter",(function(t){return t}),pi,!0),r("showCursorWhenSelecting",!1,gn,!0),r("resetSelectionOnContextMenu",!0),r("lineWiseCopyCut",!0),r("pasteLinesPerSelection",!0),r("selectionsMayTouch",!1),r("readOnly",!1,(function(t,e){"nocursor"==e&&(En(t),t.display.input.blur()),t.display.input.readOnlyChanged(e)})),r("screenReaderLabel",null,(function(t,e){e=""===e?null:e,t.display.input.screenReaderLabelChanged(e)})),r("disableInput",!1,(function(t,e){e||t.display.input.reset()}),!0),r("dragDrop",!0,Ea),r("allowDropFileTypes",null),r("cursorBlinkRate",530),r("cursorScrollMargin",0),r("cursorHeight",1,gn,!0),r("singleCursorHeightPerLine",!0,gn,!0),r("workTime",100),r("workDelay",100),r("flattenSpans",!0,Ii,!0),r("addModeClass",!1,Ii,!0),r("pollInterval",100),r("undoDepth",200,(function(t,e){return t.doc.history.undoDepth=e})),r("historyEventDelay",1250),r("viewportMargin",10,(function(t){return t.refresh()}),!0),r("maxHighlightLength",1e4,Ii,!0),r("moveInputWithCursor",!0,(function(t,e){e||t.display.input.resetPosition()})),r("tabindex",null,(function(t,e){return t.display.input.getField().tabIndex=e||""})),r("autofocus",null),r("direction","ltr",(function(t,e){return t.doc.setDirection(e)}),!0),r("phrases",null)}(ka),function(t){var e=t.optionHandlers,r=t.helpers={};t.prototype={constructor:t,focus:function(){window.focus(),this.display.input.focus()},setOption:function(t,r){var n=this.options,i=n[t];n[t]==r&&"mode"!=t||(n[t]=r,e.hasOwnProperty(t)&&ti(this,e[t])(this,r,i),ft(this,"optionChange",this,t))},getOption:function(t){return this.options[t]},getDoc:function(){return this.doc},addKeyMap:function(t,e){this.state.keyMaps[e?"push":"unshift"](qo(t))},removeKeyMap:function(t){for(var e=this.state.keyMaps,r=0;r<e.length;++r)if(e[r]==t||e[r].name==t)return e.splice(r,1),!0},addOverlay:ei((function(e,r){var n=e.token?e:t.getMode(this.options,e);if(n.startState)throw new Error("Overlays may not be stateful.");!function(t,e,r){for(var n=0,i=r(e);n<t.length&&r(t[n])<=i;)n++;t.splice(n,0,e)}(this.state.overlays,{mode:n,modeSpec:e,opaque:r&&r.opaque,priority:r&&r.priority||0},(function(t){return t.priority})),this.state.modeGen++,un(this)})),removeOverlay:ei((function(t){for(var e=this.state.overlays,r=0;r<e.length;++r){var n=e[r].modeSpec;if(n==t||"string"==typeof t&&n.name==t)return e.splice(r,1),this.state.modeGen++,void un(this)}})),indentLine:ei((function(t,e,r){"string"!=typeof e&&"number"!=typeof e&&(e=null==e?this.options.smartIndent?"smart":"prev":e?"add":"subtract"),Zt(this.doc,t)&&Fa(this,t,e,r)})),indentSelection:ei((function(t){for(var e=this.doc.sel.ranges,r=-1,n=0;n<e.length;n++){var i=e[n];if(i.empty())i.head.line>r&&(Fa(this,i.head.line,t,!0),r=i.head.line,n==this.doc.sel.primIndex&&In(this));else{var o=i.from(),a=i.to(),s=Math.max(r,o.line);r=Math.min(this.lastLine(),a.line-(a.ch?0:1))+1;for(var A=s;A<r;++A)Fa(this,A,t);var l=this.doc.sel.ranges;0==o.ch&&e.length==l.length&&l[n].from().ch>0&&qi(this.doc,n,new Bi(o,l[n].to()),K)}}})),getTokenAt:function(t,e){return ve(this,t,e)},getLineTokens:function(t,e){return ve(this,te(t),e,!0)},getTokenTypeAt:function(t){t=se(this.doc,t);var e,r=he(this,zt(this.doc,t.line)),n=0,i=(r.length-1)/2,o=t.ch;if(0==o)e=r[2];else for(;;){var a=n+i>>1;if((a?r[2*a-1]:0)>=o)i=a;else{if(!(r[2*a+1]<o)){e=r[2*a+2];break}n=a+1}}var s=e?e.indexOf("overlay "):-1;return s<0?e:0==s?null:e.slice(0,s-1)},getModeAt:function(e){var r=this.doc.mode;return r.innerMode?t.innerMode(r,this.getTokenAt(e).state).mode:r},getHelper:function(t,e){return this.getHelpers(t,e)[0]},getHelpers:function(t,e){var n=[];if(!r.hasOwnProperty(e))return n;var i=r[e],o=this.getModeAt(t);if("string"==typeof o[e])i[o[e]]&&n.push(i[o[e]]);else if(o[e])for(var a=0;a<o[e].length;a++){var s=i[o[e][a]];s&&n.push(s)}else o.helperType&&i[o.helperType]?n.push(i[o.helperType]):i[o.name]&&n.push(i[o.name]);for(var A=0;A<i._global.length;A++){var l=i._global[A];l.pred(o,this)&&-1==H(n,l.val)&&n.push(l.val)}return n},getStateAfter:function(t,e){var r=this.doc;return de(this,(t=ae(r,null==t?r.first+r.size-1:t))+1,e).state},cursorCoords:function(t,e){var r=this.doc.sel.primary();return zr(this,null==t?r.head:"object"==typeof t?se(this.doc,t):t?r.from():r.to(),e||"page")},charCoords:function(t,e){return Vr(this,se(this.doc,t),e||"page")},coordsChar:function(t,e){return Xr(this,(t=Gr(this,t,e||"page")).left,t.top)},lineAtHeight:function(t,e){return t=Gr(this,{top:t,left:0},e||"page").top,Jt(this.doc,t+this.display.viewOffset)},heightAtLine:function(t,e,r){var n,i=!1;if("number"==typeof t){var o=this.doc.first+this.doc.size-1;t<this.doc.first?t=this.doc.first:t>o&&(t=o,i=!0),n=zt(this.doc,t)}else n=t;return jr(this,n,{top:0,left:0},e||"page",r||i).top+(i?this.doc.height-je(n):0)},defaultTextHeight:function(){return rn(this.display)},defaultCharWidth:function(){return nn(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(t,e,r,n,i){var o,a,s,A=this.display,l=(t=zr(this,se(this.doc,t))).bottom,c=t.left;if(e.style.position="absolute",e.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(e),A.sizer.appendChild(e),"over"==n)l=t.top;else if("above"==n||"near"==n){var u=Math.max(A.wrapper.clientHeight,this.doc.height),h=Math.max(A.sizer.clientWidth,A.lineSpace.clientWidth);("above"==n||t.bottom+e.offsetHeight>u)&&t.top>e.offsetHeight?l=t.top-e.offsetHeight:t.bottom+e.offsetHeight<=u&&(l=t.bottom),c+e.offsetWidth>h&&(c=h-e.offsetWidth)}e.style.top=l+"px",e.style.left=e.style.right="","right"==i?(c=A.sizer.clientWidth-e.offsetWidth,e.style.right="0px"):("left"==i?c=0:"middle"==i&&(c=(A.sizer.clientWidth-e.offsetWidth)/2),e.style.left=c+"px"),r&&(o=this,a={left:c,top:l,right:c+e.offsetWidth,bottom:l+e.offsetHeight},null!=(s=Fn(o,a)).scrollTop&&Dn(o,s.scrollTop),null!=s.scrollLeft&&Mn(o,s.scrollLeft))},triggerOnKeyDown:ei(ca),triggerOnKeyPress:ei(ha),triggerOnKeyUp:ua,triggerOnMouseDown:ei(ga),execCommand:function(t){if(ea.hasOwnProperty(t))return ea[t].call(null,this)},triggerElectric:ei((function(t){Oa(this,t)})),findPosH:function(t,e,r,n){var i=1;e<0&&(i=-1,e=-e);for(var o=se(this.doc,t),a=0;a<e&&!(o=Ra(this.doc,o,i,r,n)).hitSide;++a);return o},moveH:ei((function(t,e){var r=this;this.extendSelectionsBy((function(n){return r.display.shift||r.doc.extend||n.empty()?Ra(r.doc,n.head,t,e,r.options.rtlMoveVisually):t<0?n.from():n.to()}),G)})),deleteH:ei((function(t,e){var r=this.doc.sel,n=this.doc;r.somethingSelected()?n.replaceSelection("",null,"+delete"):Jo(this,(function(r){var i=Ra(n,r.head,t,e,!1);return t<0?{from:i,to:r.head}:{from:r.head,to:i}}))})),findPosV:function(t,e,r,n){var i=1,o=n;e<0&&(i=-1,e=-e);for(var a=se(this.doc,t),s=0;s<e;++s){var A=zr(this,a,"div");if(null==o?o=A.left:A.left=o,(a=Pa(this,A,i,r)).hitSide)break}return a},moveV:ei((function(t,e){var r=this,n=this.doc,i=[],o=!this.display.shift&&!n.extend&&n.sel.somethingSelected();if(n.extendSelectionsBy((function(a){if(o)return t<0?a.from():a.to();var s=zr(r,a.head,"div");null!=a.goalColumn&&(s.left=a.goalColumn),i.push(s.left);var A=Pa(r,s,t,e);return"page"==e&&a==n.sel.primary()&&Ln(r,Vr(r,A,"div").top-s.top),A}),G),i.length)for(var a=0;a<n.sel.ranges.length;a++)n.sel.ranges[a].goalColumn=i[a]})),findWordAt:function(t){var e=zt(this.doc,t.line).text,r=t.ch,n=t.ch;if(e){var i=this.getHelper(t,"wordChars");"before"!=t.sticky&&n!=e.length||!r?++n:--r;for(var o=e.charAt(r),a=tt(o,i)?function(t){return tt(t,i)}:/\s/.test(o)?function(t){return/\s/.test(t)}:function(t){return!/\s/.test(t)&&!tt(t)};r>0&&a(e.charAt(r-1));)--r;for(;n<e.length&&a(e.charAt(n));)++n}return new Bi(te(t.line,r),te(t.line,n))},toggleOverwrite:function(t){null!=t&&t==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?U(this.display.cursorDiv,"CodeMirror-overwrite"):S(this.display.cursorDiv,"CodeMirror-overwrite"),ft(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==_()},isReadOnly:function(){return!(!this.options.readOnly&&!this.doc.cantEdit)},scrollTo:ei((function(t,e){_n(this,t,e)})),getScrollInfo:function(){var t=this.display.scroller;return{left:t.scrollLeft,top:t.scrollTop,height:t.scrollHeight-Er(this)-this.display.barHeight,width:t.scrollWidth-Er(this)-this.display.barWidth,clientHeight:kr(this),clientWidth:Sr(this)}},scrollIntoView:ei((function(t,e){null==t?(t={from:this.doc.sel.primary().head,to:null},null==e&&(e=this.options.cursorScrollMargin)):"number"==typeof t?t={from:te(t,0),to:null}:null==t.from&&(t={from:t,to:null}),t.to||(t.to=t.from),t.margin=e||0,null!=t.from.line?function(t,e){Un(t),t.curOp.scrollToPos=e}(this,t):On(this,t.from,t.to,t.margin)})),setSize:ei((function(t,e){var r=this,n=function(t){return"number"==typeof t||/^\d+$/.test(String(t))?t+"px":t};null!=t&&(this.display.wrapper.style.width=n(t)),null!=e&&(this.display.wrapper.style.height=n(e)),this.options.lineWrapping&&Rr(this);var i=this.display.viewFrom;this.doc.iter(i,this.display.viewTo,(function(t){if(t.widgets)for(var e=0;e<t.widgets.length;e++)if(t.widgets[e].noHScroll){hn(r,i,"widget");break}++i})),this.curOp.forceUpdate=!0,ft(this,"refresh",this)})),operation:function(t){return $n(this,t)},startOperation:function(){return zn(this)},endOperation:function(){return Wn(this)},refresh:ei((function(){var t=this.display.cachedTextHeight;un(this),this.curOp.forceUpdate=!0,Pr(this),_n(this,this.doc.scrollLeft,this.doc.scrollTop),li(this.display),(null==t||Math.abs(t-rn(this.display))>.5||this.options.lineWrapping)&&An(this),ft(this,"refresh",this)})),swapDoc:ei((function(t){var e=this.doc;return e.cm=null,this.state.selectingText&&this.state.selectingText(),Di(this,t),Pr(this),this.display.input.reset(),_n(this,t.scrollLeft,t.scrollTop),this.curOp.forceScroll=!0,sr(this,"swapDoc",this,e),e})),phrase:function(t){var e=this.options.phrases;return e&&Object.prototype.hasOwnProperty.call(e,t)?e[t]:t},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},vt(t),t.registerHelper=function(e,n,i){r.hasOwnProperty(e)||(r[e]=t[e]={_global:[]}),r[e][n]=i},t.registerGlobalHelper=function(e,n,i,o){t.registerHelper(e,n,o),r[e]._global.push({pred:i,val:o})}}(ka);var za="iter insert remove copy getEditor constructor".split(" ");for(var Wa in Io.prototype)Io.prototype.hasOwnProperty(Wa)&&H(za,Wa)<0&&(ka.prototype[Wa]=function(t){return function(){return t.apply(this.doc,arguments)}}(Io.prototype[Wa]));return vt(Io),ka.inputStyles={textarea:Va,contenteditable:Ha},ka.defineMode=function(t){ka.defaults.mode||"null"==t||(ka.defaults.mode=t),Mt.apply(this,arguments)},ka.defineMIME=function(t,e){Qt[t]=e},ka.defineMode("null",(function(){return{token:function(t){return t.skipToEnd()}}})),ka.defineMIME("text/plain","null"),ka.defineExtension=function(t,e){ka.prototype[t]=e},ka.defineDocExtension=function(t,e){Io.prototype[t]=e},ka.fromTextArea=function(t,e){if((e=e?M(e):{}).value=t.value,!e.tabindex&&t.tabIndex&&(e.tabindex=t.tabIndex),!e.placeholder&&t.placeholder&&(e.placeholder=t.placeholder),null==e.autofocus){var r=_();e.autofocus=r==t||null!=t.getAttribute("autofocus")&&r==document.body}function n(){t.value=s.getValue()}var i;if(t.form&&(ut(t.form,"submit",n),!e.leaveSubmitMethodAlone)){var o=t.form;i=o.submit;try{var a=o.submit=function(){n(),o.submit=i,o.submit(),o.submit=a}}catch(t){}}e.finishInit=function(r){r.save=n,r.getTextArea=function(){return t},r.toTextArea=function(){r.toTextArea=isNaN,n(),t.parentNode.removeChild(r.getWrapperElement()),t.style.display="",t.form&&(dt(t.form,"submit",n),e.leaveSubmitMethodAlone||"function"!=typeof t.form.submit||(t.form.submit=i))}},t.style.display="none";var s=ka((function(e){return t.parentNode.insertBefore(e,t.nextSibling)}),e);return s},function(t){t.off=dt,t.on=ut,t.wheelEventPixels=wi,t.Doc=Io,t.splitLines=It,t.countColumn=R,t.findColumn=V,t.isWordChar=$,t.Pass=N,t.signal=ft,t.Line=ze,t.changeEnd=Si,t.scrollbarModel=jn,t.Pos=te,t.cmpPos=ee,t.modes=Dt,t.mimeModes=Qt,t.resolveMode=Rt,t.getMode=Pt,t.modeExtensions=Ht,t.extendMode=Nt,t.copyState=Kt,t.startState=Gt,t.innerMode=jt,t.commands=ea,t.keyMap=jo,t.keyName=Xo,t.isModifierKey=Wo,t.lookupKey=zo,t.normalizeKeyMap=Vo,t.StringStream=Vt,t.SharedTextMarker=ko,t.TextMarker=Eo,t.LineWidget=Co,t.e_preventDefault=yt,t.e_stopPropagation=wt,t.e_stop=Ct,t.addClass=U,t.contains=I,t.rmClass=S,t.keyNames=Po}(ka),ka.version="5.58.2",ka}()},WaYH:
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./node_modules/rc-tree/es/TreeNode.js + 1 modules ***!
|
|
|
\*********************************************************/
|
|
|
/*! exports provided: InternalTreeNode, default */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createSuper.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-tree/es/contextTypes.js because of ./node_modules/rc-tree/es/Tree.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-tree/es/util.js because of ./node_modules/antd/es/table/hooks/useSelection.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-tree/es/utils/treeUtil.js because of ./node_modules/antd/es/table/hooks/useSelection.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";var n=r("rePB"),i=r("Ff2n"),o=r("VTBJ"),a=r("1OyB"),s=r("vuIU"),A=r("JX7q"),l=r("Ji7U"),c=r("LK+K"),u=r("q1tI"),h=r("TSYQ"),d=r.n(h),f=r("sboe"),p=r("OZM5"),g=function(t){var e=t.prefixCls,r=t.level,i=t.isStart,o=t.isEnd;if(!r)return null;for(var a="".concat(e,"-indent-unit"),s=[],A=0;A<r;A+=1){var l;s.push(u.createElement("span",{key:A,className:d()(a,(l={},Object(n.a)(l,"".concat(a,"-start"),i[A+1]),Object(n.a)(l,"".concat(a,"-end"),o[A+1]),Object(n.a)(l,"".concat(a,"-end-first-level"),!A&&o[0]),l))}))}return u.createElement("span",{"aria-hidden":"true",className:"".concat(e,"-indent")},s)},m=r("815F"),v=function(t){Object(l.a)(r,t);var e=Object(c.a)(r);function r(){var t;return Object(a.a)(this,r),(t=e.apply(this,arguments)).state={dragNodeHighlight:!1},t.onSelectorClick=function(e){(0,t.props.context.onNodeClick)(e,Object(m.b)(t.props)),t.isSelectable()?t.onSelect(e):t.onCheck(e)},t.onSelectorDoubleClick=function(e){(0,t.props.context.onNodeDoubleClick)(e,Object(m.b)(t.props))},t.onSelect=function(e){if(!t.isDisabled()){var r=t.props.context.onNodeSelect;e.preventDefault(),r(e,Object(m.b)(t.props))}},t.onCheck=function(e){if(!t.isDisabled()){var r=t.props,n=r.disableCheckbox,i=r.checked,o=t.props.context.onNodeCheck;if(t.isCheckable()&&!n){e.preventDefault();var a=!i;o(e,Object(m.b)(t.props),a)}}},t.onMouseEnter=function(e){(0,t.props.context.onNodeMouseEnter)(e,Object(m.b)(t.props))},t.onMouseLeave=function(e){(0,t.props.context.onNodeMouseLeave)(e,Object(m.b)(t.props))},t.onContextMenu=function(e){(0,t.props.context.onNodeContextMenu)(e,Object(m.b)(t.props))},t.onDragStart=function(e){var r=t.props.context.onNodeDragStart;e.stopPropagation(),t.setState({dragNodeHighlight:!0}),r(e,Object(A.a)(t));try{e.dataTransfer.setData("text/plain","")}catch(t){}},t.onDragEnter=function(e){var r=t.props.context.onNodeDragEnter;e.preventDefault(),e.stopPropagation(),r(e,Object(A.a)(t))},t.onDragOver=function(e){var r=t.props.context.onNodeDragOver;e.preventDefault(),e.stopPropagation(),r(e,Object(A.a)(t))},t.onDragLeave=function(e){var r=t.props.context.onNodeDragLeave;e.stopPropagation(),r(e,Object(A.a)(t))},t.onDragEnd=function(e){var r=t.props.context.onNodeDragEnd;e.stopPropagation(),t.setState({dragNodeHighlight:!1}),r(e,Object(A.a)(t))},t.onDrop=function(e){var r=t.props.context.onNodeDrop;e.preventDefault(),e.stopPropagation(),t.setState({dragNodeHighlight:!1}),r(e,Object(A.a)(t))},t.onExpand=function(e){(0,t.props.context.onNodeExpand)(e,Object(m.b)(t.props))},t.setSelectHandle=function(e){t.selectHandle=e},t.getNodeState=function(){var e=t.props.expanded;return t.isLeaf()?null:e?"open":"close"},t.hasChildren=function(){var e=t.props.eventKey;return!!((t.props.context.keyEntities[e]||{}).children||[]).length},t.isLeaf=function(){var e=t.props,r=e.isLeaf,n=e.loaded,i=t.props.context.loadData,o=t.hasChildren();return!1!==r&&(r||!i&&!o||i&&n&&!o)},t.isDisabled=function(){var e=t.props.disabled;return!(!t.props.context.disabled&&!e)},t.isCheckable=function(){var e=t.props.checkable,r=t.props.context.checkable;return!(!r||!1===e)&&r},t.syncLoadData=function(e){var r=e.expanded,n=e.loading,i=e.loaded,o=t.props.context,a=o.loadData,s=o.onNodeLoad;n||a&&r&&!t.isLeaf()&&(t.hasChildren()||i||s(Object(m.b)(t.props)))},t.renderSwitcher=function(){var e=t.props,r=e.expanded,n=e.switcherIcon,i=t.props.context,a=i.prefixCls,s=i.switcherIcon,A=n||s;if(t.isLeaf())return u.createElement("span",{className:d()("".concat(a,"-switcher"),"".concat(a,"-switcher-noop"))},"function"==typeof A?A(Object(o.a)(Object(o.a)({},t.props),{},{isLeaf:!0})):A);var l=d()("".concat(a,"-switcher"),"".concat(a,"-switcher_").concat(r?"open":"close"));return u.createElement("span",{onClick:t.onExpand,className:l},"function"==typeof A?A(Object(o.a)(Object(o.a)({},t.props),{},{isLeaf:!1})):A)},t.renderCheckbox=function(){var e=t.props,r=e.checked,n=e.halfChecked,i=e.disableCheckbox,o=t.props.context.prefixCls,a=t.isDisabled(),s=t.isCheckable();if(!s)return null;var A="boolean"!=typeof s?s:null;return u.createElement("span",{className:d()("".concat(o,"-checkbox"),r&&"".concat(o,"-checkbox-checked"),!r&&n&&"".concat(o,"-checkbox-indeterminate"),(a||i)&&"".concat(o,"-checkbox-disabled")),onClick:t.onCheck},A)},t.renderIcon=function(){var e=t.props.loading,r=t.props.context.prefixCls;return u.createElement("span",{className:d()("".concat(r,"-iconEle"),"".concat(r,"-icon__").concat(t.getNodeState()||"docu"),e&&"".concat(r,"-icon_loading"))})},t.renderSelector=function(){var e,r,n=t.state.dragNodeHighlight,i=t.props,o=i.title,a=i.selected,s=i.icon,A=i.loading,l=i.data,c=t.props.context,h=c.prefixCls,f=c.showIcon,p=c.icon,g=c.draggable,m=c.loadData,v=c.titleRender,y=t.isDisabled(),w="".concat(h,"-node-content-wrapper");if(f){var b=s||p;e=b?u.createElement("span",{className:d()("".concat(h,"-iconEle"),"".concat(h,"-icon__customize"))},"function"==typeof b?b(t.props):b):t.renderIcon()}else m&&A&&(e=t.renderIcon());r="function"==typeof o?o(l):v?v(l):o;var C=u.createElement("span",{className:"".concat(h,"-title")},r);return u.createElement("span",{ref:t.setSelectHandle,title:"string"==typeof o?o:"",className:d()("".concat(w),"".concat(w,"-").concat(t.getNodeState()||"normal"),!y&&(a||n)&&"".concat(h,"-node-selected"),!y&&g&&"draggable"),draggable:!y&&g||void 0,"aria-grabbed":!y&&g||void 0,onMouseEnter:t.onMouseEnter,onMouseLeave:t.onMouseLeave,onContextMenu:t.onContextMenu,onClick:t.onSelectorClick,onDoubleClick:t.onSelectorDoubleClick,onDragStart:g?t.onDragStart:void 0},e,C)},t}return Object(s.a)(r,[{key:"componentDidMount",value:function(){this.syncLoadData(this.props)}},{key:"componentDidUpdate",value:function(){this.syncLoadData(this.props)}},{key:"isSelectable",value:function(){var t=this.props.selectable,e=this.props.context.selectable;return"boolean"==typeof t?t:e}},{key:"render",value:function(){var t,e=this.props,r=e.eventKey,o=e.className,a=e.style,s=e.dragOver,A=e.dragOverGapTop,l=e.dragOverGapBottom,c=e.isLeaf,h=e.isStart,f=e.isEnd,v=e.expanded,y=e.selected,w=e.checked,b=e.halfChecked,C=e.loading,B=e.domRef,x=e.active,E=e.onMouseMove,S=Object(i.a)(e,["eventKey","className","style","dragOver","dragOverGapTop","dragOverGapBottom","isLeaf","isStart","isEnd","expanded","selected","checked","halfChecked","loading","domRef","active","onMouseMove"]),k=this.props.context,T=k.prefixCls,F=k.filterTreeNode,L=k.draggable,I=k.keyEntities,_=this.isDisabled(),U=Object(p.f)(S),O=(I[r]||{}).level,D=f[f.length-1];return u.createElement("div",Object.assign({ref:B,className:d()(o,"".concat(T,"-treenode"),(t={},Object(n.a)(t,"".concat(T,"-treenode-disabled"),_),Object(n.a)(t,"".concat(T,"-treenode-switcher-").concat(v?"open":"close"),!c),Object(n.a)(t,"".concat(T,"-treenode-checkbox-checked"),w),Object(n.a)(t,"".concat(T,"-treenode-checkbox-indeterminate"),b),Object(n.a)(t,"".concat(T,"-treenode-selected"),y),Object(n.a)(t,"".concat(T,"-treenode-loading"),C),Object(n.a)(t,"".concat(T,"-treenode-active"),x),Object(n.a)(t,"".concat(T,"-treenode-leaf-last"),D),Object(n.a)(t,"drag-over",!_&&s),Object(n.a)(t,"drag-over-gap-top",!_&&A),Object(n.a)(t,"drag-over-gap-bottom",!_&&l),Object(n.a)(t,"filter-node",F&&F(Object(m.b)(this.props))),t)),style:a,onDragEnter:L?this.onDragEnter:void 0,onDragOver:L?this.onDragOver:void 0,onDragLeave:L?this.onDragLeave:void 0,onDrop:L?this.onDrop:void 0,onDragEnd:L?this.onDragEnd:void 0,onMouseMove:E},U),u.createElement(g,{prefixCls:T,level:O,isStart:h,isEnd:f}),this.renderSwitcher(),this.renderCheckbox(),this.renderSelector())}}]),r}(u.Component),y=function(t){return u.createElement(f.a.Consumer,null,(function(e){return u.createElement(v,Object.assign({},t,{context:e}))}))};y.displayName="TreeNode",y.defaultProps={title:"---"},y.isTreeNode=1;e.a=y},Xm8N:
|
|
|
/*!***************************************************************************************************!*\
|
|
|
!*** ./src/pages/Classrooms/Lists/ShixunHomeworks/Detail/components/WorkList/components/Redo.tsx ***!
|
|
|
\***************************************************************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";r(/*! antd/es/modal/style */"2qtc");var n=r(/*! antd/es/modal */"kLXV"),i=(r(/*! antd/es/message/style */"miYZ"),r(/*! antd/es/message */"tsqr")),o=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator */"9og8"),a=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties */"PpiC"),s=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator */"WmNS"),A=r.n(s),l=r(/*! react */"q1tI"),c=r.n(l),u=r(/*! @/utils/fetch */"ErOA"),h=r(/*! umi */"Ty5D"),d=r(/*! umi */"9kvl");e.a=Object(d.a)((function(t){return{shixunHomeworks:t.shixunHomeworks}}))((function(t){var e=t.shixunHomeworks,r=t.dispatch,s=(Object(a.a)(t,["shixunHomeworks","dispatch"]),Object(h.i)());return c.a.createElement(n.a,{centered:!0,title:"提示",visible:"打回重做"===e.actionTabs.key,okText:"确定",cancelText:"取消",onOk:Object(o.a)(A.a.mark((function t(){var n,o,a,l;return A.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(u.a)("/api/myshixuns/".concat(e.actionTabs.selectArrs.myshixun_identifier,"/reset_my_game.json"),{method:"GET",params:{course_id:s.coursesId}});case 2:(n=t.sent).shixun_identifier&&(i.b.success("操作成功"),r({type:"shixunHomeworks/setActionTabs",payload:{}}),l=null==n||null===(o=n.new_works)||void 0===o||null===(a=o.find((function(t){return"".concat(t.homework_common_id)===s.categoryId})))||void 0===a?void 0:a.id,d.d.replace("/classrooms/".concat(s.coursesId,"/shixun_homework/").concat(s.categoryId,"/").concat(l,"/comment")));case 4:case"end":return t.stop()}}),t)}))),onCancel:function(){r({type:"shixunHomeworks/setActionTabs",payload:{}})}},c.a.createElement("p",null,"该作业将被打回重做,学生实训记录将被清空!"),c.a.createElement("p",null,"确定打回?"))}))},Xmg4:
|
|
|
/*!*******************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/Layer.js ***!
|
|
|
\*******************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./core/util */"bYtY"),i=r(/*! ./config */"LPTA").devicePixelRatio,o=r(/*! ./graphic/Style */"K2GJ"),a=r(/*! ./graphic/Pattern */"3C/r");function s(){return!1}function A(t,e,r){var i=n.createCanvas(),o=e.getWidth(),a=e.getHeight(),s=i.style;return s&&(s.position="absolute",s.left=0,s.top=0,s.width=o+"px",s.height=a+"px",i.setAttribute("data-zr-dom-id",t)),i.width=o*r,i.height=a*r,i}var l=function(t,e,r){var o;r=r||i,"string"==typeof t?o=A(t,e,r):n.isObject(t)&&(t=(o=t).id),this.id=t,this.dom=o;var a=o.style;a&&(o.onselectstart=s,a["-webkit-user-select"]="none",a["user-select"]="none",a["-webkit-touch-callout"]="none",a["-webkit-tap-highlight-color"]="rgba(0,0,0,0)",a.padding=0,a.margin=0,a["border-width"]=0),this.domBack=null,this.ctxBack=null,this.painter=e,this.config=null,this.clearColor=0,this.motionBlur=!1,this.lastFrameAlpha=.7,this.dpr=r};l.prototype={constructor:l,__dirty:!0,__used:!1,__drawIndex:0,__startIndex:0,__endIndex:0,incremental:!1,getElementCount:function(){return this.__endIndex-this.__startIndex},initContext:function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},createBackBuffer:function(){var t=this.dpr;this.domBack=A("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),1!==t&&this.ctxBack.scale(t,t)},resize:function(t,e){var r=this.dpr,n=this.dom,i=n.style,o=this.domBack;i&&(i.width=t+"px",i.height=e+"px"),n.width=t*r,n.height=e*r,o&&(o.width=t*r,o.height=e*r,1!==r&&this.ctxBack.scale(r,r))},clear:function(t,e){var r,n=this.dom,i=this.ctx,s=n.width,A=n.height,l=(e=e||this.clearColor,this.motionBlur&&!t),c=this.lastFrameAlpha,u=this.dpr;(l&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(n,0,0,s/u,A/u)),i.clearRect(0,0,s,A),e&&"transparent"!==e)&&(e.colorStops?(r=e.__canvasGradient||o.getGradient(i,e,{x:0,y:0,width:s,height:A}),e.__canvasGradient=r):e.image&&(r=a.prototype.getCanvasPattern.call(e,i)),i.save(),i.fillStyle=r||e,i.fillRect(0,0,s,A),i.restore());if(l){var h=this.domBack;i.save(),i.globalAlpha=c,i.drawImage(h,0,0,s,A),i.restore()}}};var c=l;t.exports=c},Xnb7:
|
|
|
/*!**********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/image.js ***!
|
|
|
\**********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=new(r(/*! ../../core/LRU */"1RvN"))(50);function i(){var t=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e<t.pending.length;e++){var r=t.pending[e],n=r.cb;n&&n(this,r.cbPayload),r.hostEl.dirty()}t.pending.length=0}function o(t){return t&&t.width&&t.height}e.findExistImage=function(t){if("string"==typeof t){var e=n.get(t);return e&&e.image}return t},e.createOrUpdateImage=function(t,e,r,a,s){if(t){if("string"==typeof t){if(e&&e.__zrImageSrc===t||!r)return e;var A=n.get(t),l={hostEl:r,cb:a,cbPayload:s};return A?!o(e=A.image)&&A.pending.push(l):((e=new Image).onload=e.onerror=i,n.put(t,e.__cachedImgObj={image:e,pending:[l]}),e.src=e.__zrImageSrc=t),e}return t}return e},e.isImageReady=o},Y1PL:
|
|
|
/*!**********************************************************!*\
|
|
|
!*** ./node_modules/rc-textarea/es/index.js + 7 modules ***!
|
|
|
\**********************************************************/
|
|
|
/*! exports provided: ResizableTextArea, default */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createSuper.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/extends.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/Children/toArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/Dom/findDOMNode.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/omit.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/ref.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/warning.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/resize-observer-polyfill/dist/ResizeObserver.es.js (<- Module uses injected variables (global)) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/shallowequal/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r.r(e),r.d(e,"ResizableTextArea",(function(){return U}));var n=r("wx14"),i=r("1OyB"),o=r("vuIU"),a=r("Ji7U"),s=r("LK+K"),A=r("q1tI"),l=r("VTBJ"),c=r("rePB"),u=r("Zm9Q"),h=(r("Kwbf"),r("c+Xe")),d=r("m+aA"),f=r("bdgK"),p=new Map;var g=new f.default((function(t){t.forEach((function(t){var e,r=t.target;null===(e=p.get(r))||void 0===e||e.forEach((function(t){return t(r)}))}))}));var m=function(t){Object(a.a)(r,t);var e=Object(s.a)(r);function r(){return Object(i.a)(this,r),e.apply(this,arguments)}return Object(o.a)(r,[{key:"render",value:function(){return this.props.children}}]),r}(A.Component),v=A.createContext(null);function y(t){var e=t.children,r=t.disabled,n=A.useRef(null),i=A.useRef(null),o=A.useContext(v),a=A.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),s=A.isValidElement(e)&&Object(h.c)(e),c=s?e.ref:null,u=A.useMemo((function(){return Object(h.a)(c,n)}),[c,n]),f=A.useRef(t);f.current=t;var y=A.useCallback((function(t){var e=f.current,r=e.onResize,n=e.data,i=t.getBoundingClientRect(),s=i.width,A=i.height,c=t.offsetWidth,u=t.offsetHeight,h=Math.floor(s),d=Math.floor(A);if(a.current.width!==h||a.current.height!==d||a.current.offsetWidth!==c||a.current.offsetHeight!==u){var p={width:h,height:d,offsetWidth:c,offsetHeight:u};a.current=p;var g=c===Math.round(s)?s:c,m=u===Math.round(A)?A:u,v=Object(l.a)(Object(l.a)({},p),{},{offsetWidth:g,offsetHeight:m});null==o||o(v,t,n),r&&Promise.resolve().then((function(){r(v,t)}))}}),[]);return A.useEffect((function(){var t,e,o=Object(d.a)(n.current)||Object(d.a)(i.current);return o&&!r&&(t=o,e=y,p.has(t)||(p.set(t,new Set),g.observe(t)),p.get(t).add(e)),function(){return function(t,e){p.has(t)&&(p.get(t).delete(e),p.get(t).size||(g.unobserve(t),p.delete(t)))}(o,y)}}),[n.current,r]),A.createElement(m,{ref:i},s?A.cloneElement(e,{ref:u}):e)}function w(t){var e=t.children;return Object(u.a)(e).map((function(e,r){var i=(null==e?void 0:e.key)||"".concat("rc-observer-key","-").concat(r);return A.createElement(y,Object(n.a)({},t,{key:i}),e)}))}w.Collection=function(t){var e=t.children,r=t.onBatchResize,n=A.useRef(0),i=A.useRef([]),o=A.useContext(v),a=A.useCallback((function(t,e,a){n.current+=1;var s=n.current;i.current.push({size:t,element:e,data:a}),Promise.resolve().then((function(){s===n.current&&(null==r||r(i.current),i.current=[])})),null==o||o(t,e,a)}),[r,o]);return A.createElement(v.Provider,{value:a},e)};var b,C=w,B=r("bT9E"),x=r("TSYQ"),E=r.n(x),S="\n min-height:0 !important;\n max-height:none !important;\n height:0 !important;\n visibility:hidden !important;\n overflow:hidden !important;\n position:absolute !important;\n z-index:-1000 !important;\n top:0 !important;\n right:0 !important\n",k=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","font-variant","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing","word-break"],T={};function F(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=t.getAttribute("id")||t.getAttribute("data-reactid")||t.getAttribute("name");if(e&&T[r])return T[r];var n=window.getComputedStyle(t),i=n.getPropertyValue("box-sizing")||n.getPropertyValue("-moz-box-sizing")||n.getPropertyValue("-webkit-box-sizing"),o=parseFloat(n.getPropertyValue("padding-bottom"))+parseFloat(n.getPropertyValue("padding-top")),a=parseFloat(n.getPropertyValue("border-bottom-width"))+parseFloat(n.getPropertyValue("border-top-width")),s=k.map((function(t){return"".concat(t,":").concat(n.getPropertyValue(t))})).join(";"),A={sizingStyle:s,paddingSize:o,borderSize:a,boxSizing:i};return e&&r&&(T[r]=A),A}var L,I=r("Gytx"),_=r.n(I);!function(t){t[t.NONE=0]="NONE",t[t.RESIZING=1]="RESIZING",t[t.RESIZED=2]="RESIZED"}(L||(L={}));var U=function(t){Object(a.a)(r,t);var e=Object(s.a)(r);function r(t){var o;return Object(i.a)(this,r),(o=e.call(this,t)).nextFrameActionId=void 0,o.resizeFrameId=void 0,o.textArea=void 0,o.saveTextArea=function(t){o.textArea=t},o.handleResize=function(t){var e=o.state.resizeStatus,r=o.props,n=r.autoSize,i=r.onResize;e===L.NONE&&("function"==typeof i&&i(t),n&&o.resizeOnNextFrame())},o.resizeOnNextFrame=function(){cancelAnimationFrame(o.nextFrameActionId),o.nextFrameActionId=requestAnimationFrame(o.resizeTextarea)},o.resizeTextarea=function(){var t=o.props.autoSize;if(t&&o.textArea){var e=t.minRows,r=t.maxRows,n=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;b||((b=document.createElement("textarea")).setAttribute("tab-index","-1"),b.setAttribute("aria-hidden","true"),document.body.appendChild(b)),t.getAttribute("wrap")?b.setAttribute("wrap",t.getAttribute("wrap")):b.removeAttribute("wrap");var i=F(t,e),o=i.paddingSize,a=i.borderSize,s=i.boxSizing,A=i.sizingStyle;b.setAttribute("style","".concat(A,";").concat(S)),b.value=t.value||t.placeholder||"";var l,c=Number.MIN_SAFE_INTEGER,u=Number.MAX_SAFE_INTEGER,h=b.scrollHeight;if("border-box"===s?h+=a:"content-box"===s&&(h-=o),null!==r||null!==n){b.value=" ";var d=b.scrollHeight-o;null!==r&&(c=d*r,"border-box"===s&&(c=c+o+a),h=Math.max(c,h)),null!==n&&(u=d*n,"border-box"===s&&(u=u+o+a),l=h>u?"":"hidden",h=Math.min(u,h))}return{height:h,minHeight:c,maxHeight:u,overflowY:l,resize:"none"}}(o.textArea,!1,e,r);o.setState({textareaStyles:n,resizeStatus:L.RESIZING},(function(){cancelAnimationFrame(o.resizeFrameId),o.resizeFrameId=requestAnimationFrame((function(){o.setState({resizeStatus:L.RESIZED},(function(){o.resizeFrameId=requestAnimationFrame((function(){o.setState({resizeStatus:L.NONE}),o.fixFirefoxAutoScroll()}))}))}))}))}},o.renderTextArea=function(){var t=o.props,e=t.prefixCls,r=void 0===e?"rc-textarea":e,i=t.autoSize,a=t.onResize,s=t.className,u=t.disabled,h=o.state,d=h.textareaStyles,f=h.resizeStatus,p=Object(B.a)(o.props,["prefixCls","onPressEnter","autoSize","defaultValue","onResize"]),g=E()(r,s,Object(c.a)({},"".concat(r,"-disabled"),u));"value"in p&&(p.value=p.value||"");var m=Object(l.a)(Object(l.a)(Object(l.a)({},o.props.style),d),f===L.RESIZING?{overflowX:"hidden",overflowY:"hidden"}:null);return A.createElement(C,{onResize:o.handleResize,disabled:!(i||a)},A.createElement("textarea",Object(n.a)({},p,{className:g,style:m,ref:o.saveTextArea})))},o.state={textareaStyles:{},resizeStatus:L.NONE},o}return Object(o.a)(r,[{key:"componentDidUpdate",value:function(t){t.value===this.props.value&&_()(t.autoSize,this.props.autoSize)||this.resizeTextarea()}},{key:"componentWillUnmount",value:function(){cancelAnimationFrame(this.nextFrameActionId),cancelAnimationFrame(this.resizeFrameId)}},{key:"fixFirefoxAutoScroll",value:function(){try{if(document.activeElement===this.textArea){var t=this.textArea.selectionStart,e=this.textArea.selectionEnd;this.textArea.setSelectionRange(t,e)}}catch(t){}}},{key:"render",value:function(){return this.renderTextArea()}}]),r}(A.Component),O=function(t){Object(a.a)(r,t);var e=Object(s.a)(r);function r(t){var n;Object(i.a)(this,r),(n=e.call(this,t)).resizableTextArea=void 0,n.focus=function(){n.resizableTextArea.textArea.focus()},n.saveTextArea=function(t){n.resizableTextArea=t},n.handleChange=function(t){var e=n.props.onChange;n.setValue(t.target.value,(function(){n.resizableTextArea.resizeTextarea()})),e&&e(t)},n.handleKeyDown=function(t){var e=n.props,r=e.onPressEnter,i=e.onKeyDown;13===t.keyCode&&r&&r(t),i&&i(t)};var o=void 0===t.value||null===t.value?t.defaultValue:t.value;return n.state={value:o},n}return Object(o.a)(r,[{key:"setValue",value:function(t,e){"value"in this.props||this.setState({value:t},e)}},{key:"blur",value:function(){this.resizableTextArea.textArea.blur()}},{key:"render",value:function(){return A.createElement(U,Object(n.a)({},this.props,{value:this.state.value,onKeyDown:this.handleKeyDown,onChange:this.handleChange,ref:this.saveTextArea}))}}],[{key:"getDerivedStateFromProps",value:function(t){return"value"in t?{value:t.value}:null}}]),r}(A.Component);e.default=O},YH21:
|
|
|
/*!************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/event.js ***!
|
|
|
\************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../mixin/Eventful */"H6uX");e.Dispatcher=n;var i=r(/*! ./env */"ItGF"),o=r(/*! ./dom */"Ze12"),a=o.isCanvasEl,s=o.transformCoordWithViewport,A="undefined"!=typeof window&&!!window.addEventListener,l=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,c=[];function u(t,e,r,n){return r=r||{},n||!i.canvasSupported?h(t,e,r):i.browser.firefox&&null!=e.layerX&&e.layerX!==e.offsetX?(r.zrX=e.layerX,r.zrY=e.layerY):null!=e.offsetX?(r.zrX=e.offsetX,r.zrY=e.offsetY):h(t,e,r),r}function h(t,e,r){if(i.domSupported&&t.getBoundingClientRect){var n=e.clientX,o=e.clientY;if(a(t)){var A=t.getBoundingClientRect();return r.zrX=n-A.left,void(r.zrY=o-A.top)}if(s(c,t,n,o))return r.zrX=c[0],void(r.zrY=c[1])}r.zrX=r.zrY=0}function d(t){return t||window.event}var f=A?function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0}:function(t){t.returnValue=!1,t.cancelBubble=!0};e.clientToLocal=u,e.getNativeEvent=d,e.normalizeEvent=function(t,e,r){if(null!=(e=d(e)).zrX)return e;var n=e.type;if(n&&n.indexOf("touch")>=0){var i="touchend"!==n?e.targetTouches[0]:e.changedTouches[0];i&&u(t,i,e,r)}else u(t,e,e,r),e.zrDelta=e.wheelDelta?e.wheelDelta/120:-(e.detail||0)/3;var o=e.button;return null==e.which&&void 0!==o&&l.test(e.type)&&(e.which=1&o?1:2&o?3:4&o?2:0),e},e.addEventListener=function(t,e,r,n){A?t.addEventListener(e,r,n):t.attachEvent("on"+e,r)},e.removeEventListener=function(t,e,r,n){A?t.removeEventListener(e,r,n):t.detachEvent("on"+e,r)},e.stop=f,e.isMiddleOrRightButtonOnMouseUpDown=function(t){return 2===t.which||3===t.which},e.notLeftMouse=function(t){return t.which>1}},YgsL:
|
|
|
/*!*****************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/smoothSpline.js ***!
|
|
|
\*****************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../../core/vector */"QBsz").distance;function i(t,e,r,n,i,o,a){var s=.5*(r-t),A=.5*(n-e);return(2*(e-r)+s+A)*a+(-3*(e-r)-2*s-A)*o+s*i+e}t.exports=function(t,e){for(var r=t.length,o=[],a=0,s=1;s<r;s++)a+=n(t[s-1],t[s]);var A=a/2;for(A=A<r?r:A,s=0;s<A;s++){var l,c,u,h=s/(A-1)*(e?r:r-1),d=Math.floor(h),f=h-d,p=t[d%r];e?(l=t[(d-1+r)%r],c=t[(d+1)%r],u=t[(d+2)%r]):(l=t[0===d?d:d-1],c=t[d>r-2?r-1:d+1],u=t[d>r-3?r-1:d+2]);var g=f*f,m=f*g;o.push([i(l[0],p[0],c[0],u[0],f,g,m),i(l[1],p[1],c[1],u[1],f,g,m)])}return o}},ZW9T:
|
|
|
/*!************************************************************!*\
|
|
|
!*** ./src/components/monaco-editor/index.jsx + 1 modules ***!
|
|
|
\************************************************************/
|
|
|
/*! exports provided: getLanguageByMirrorName, default, DiffEditor */
|
|
|
/*! exports used: DiffEditor, default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/message/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/message/style/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/resize-observer-polyfill/dist/ResizeObserver.es.js (<- Module uses injected variables (global)) */function(t,e,r){"use strict";r.d(e,"a",(function(){return m}));var n=r("k1fw"),i=(r("miYZ"),r("tsqr")),o=r("rAM+"),a=r("tJVT"),s=r("PpiC"),A=r("q1tI"),l=r.n(A),c=r("bdgK");function u(t,e,r,i,o){var a=e.getWordUntilPosition(r),s={startLineNumber:r.lineNumber,endLineNumber:r.lineNumber,startColumn:a.startColumn,endColumn:a.endColumn},A=i.map((function(e){return{label:e,kind:t.languages.CompletionItemKind.Keyword,insertText:e,insertTextRules:t.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:s}}));return o.map((function(t){A.push(Object(n.a)(Object(n.a)({},t),{},{range:s}))})),A}r("LvDl");function h(t){return/^\d+$/.test(t)?"".concat(t,"px"):t}function d(){}var f={"Python3.6":"python","Python2.7":"python",Dynamips:"cpp",Java:"java",Web:"php",Html:"html",Hive:"sql",Hadoop:"java",SDL:"cpp",PHP:"php",Matlab:"python",Git:"python",Python:"python","C/C++":"cpp","C++":"cpp",C:"cpp",Ruby:"ruby",Shell:"shell",JavaScript:"javascript",Perl6:"perl",Kotlin:"kotlin",Elixir:"elixir",Android:"java",JavaWeb:"java",Go:"go",Spark:"sql",MachineLearning:"python",Verilog:"xml","Verilog/VNC":"xml",Docker:"dockerfile","C#":"csharp",SQLite3:"sql",Oracle:"sql",Vhdl:"vhdl",R:"r",Swift:"swift",SQLServer:"mysql",MySQL:"mysql",Mongo:"sql",PostgreSql:"pgsql",Hbase:"powershell",Sqoop:"sql",Nasm:"cpp",Kafka:"java",Flink:"java",Sml:"javascript",OpenGL:"cpp",Perl5:"perl",Orange:"python"};function p(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=t;if(Array.isArray(t)){for(var r=0;r<t.length;r++){var n=f[t[r]];if(n)return n}return e[0]}return f[e]||e}var g=null;e.b=function(t){var e=t.width,f=void 0===e?"100%":e,m=t.height,v=void 0===m?"100%":m,y=t.value,w=t.language,b=void 0===w?"javascript":w,C=t.style,B=void 0===C?{}:C,x=t.options,E=void 0===x?{}:x,S=t.overrideServices,k=void 0===S?{}:S,T=t.theme,F=void 0===T?"vs-dark":T,L=t.onEditBlur,I=t.onSave,_=t.autoHeight,U=void 0!==_&&_,O=t.forbidCopy,D=void 0!==O&&O,Q=t.onChange,M=void 0===Q?d:Q,R=t.editorDidMount,P=void 0===R?d:R,H=t.onFocus,N=void 0===H?d:H,K=t.filename,j=void 0===K?"educoder.txt":K,G=(Object(s.a)(t,["width","height","value","language","style","options","overrideServices","theme","onEditBlur","onSave","autoHeight","forbidCopy","onChange","editorDidMount","onFocus","filename"]),Object(A.useRef)()),V=Object(A.useRef)({}),z=Object(A.useRef)(),W=Object(A.useRef)(!1),Y=Object(A.useRef)(),X=Object(A.useState)(!1),q=Object(a.a)(X,2),J=q[0],Z=q[1];function $(){i.b.warn(decodeURIComponent("该任务关卡设置了禁止复制粘贴,请手动输入代码。"))}function tt(){var t=V.current.instance;if(t){var e=t.getSelection(),r=V.current.pastePos||{},n=new g.Range(r.startLineNumber||e.endLineNumber,r.startColumn||e.endColumn,r.endLineNumber||e.endLineNumber,r.endColumn||e.endColumn);setTimeout((function(){t.executeEdits("",[{range:n,text:""}])}),300)}}function et(t){(window.navigator.platform.match("Mac")?t.metaKey:t.ctrlKey)&&83==t.keyCode&&(t.preventDefault(),I())}Object(A.useEffect)((function(){z.current&&clearTimeout(z.current),z.current=setTimeout((function(){!function(){var t=V.current.instance;if(null!=y&&t&&J){var e=t.getModel();e&&y!==e.getValue()&&(!0,e.setValue(y),t.layout(),!1)}}()}),500)}),[y,J,V.current]);var rt=function(){if(U&&V.current.instance){var t=V.current.instance.getContentHeight();ct(t<v?v:t)}else ct(v)};function nt(t,e){var r,n,i=window.URL||window.webkitURL||window,o=new Blob([e]),a=document.createElementNS("http://www.w3.org/1999/xhtml","a");a.href=i.createObjectURL(o),a.download=t,r=a,(n=document.createEvent("MouseEvents")).initMouseEvent("click",!0,!1,window,0,0,0,0,0,!1,!1,!1,!1,0,null),r.dispatchEvent(n)}Object(A.useEffect)((function(){rt()}),[rt]),Object(A.useEffect)((function(){G.current&&!J&&r.e(/*! import() | monaco-editor */27).then(r.t.bind(null,/*! monaco-editor/esm/vs/editor/editor.api.js */"M/lh",7)).then((function(t){try{g=t,V.current.instance=g.editor.create(G.current,{value:y,language:p(b),theme:F,requireConfig:{"vs/nls":{availableLanguages:{"*":"zh-cn"}}},wordWrap:!0},k);var e=V.current.instance;if(P(e,g),setTimeout((function(){rt(),V.current.instance.addAction({id:"d123123",label:"Download File",contextMenuGroupId:"9_cutcopypaste",run:function(){nt(j||"educoder.txt",e.getValue())}})}),500),V.current.subscription=e.onDidChangeModelContent((function(t){W.current?clearTimeout(Y.current):(rt(),M(e.getValue(),t)),Y.current=setTimeout((function(){W.current=!1}),500)})),window.Monaco||function(t){var e={label:"ifelse",kind:t.languages.CompletionItemKind.Method,insertText:["if (${1:condition}) {","\t$0","} else {","\t","}"].join("\n"),insertTextRules:t.languages.CompletionItemInsertTextRule.InsertAsSnippet},r=["auto","break","case","char","const","continue","default","do","double","else","enum","extern","float","for","goto","if","int","long","register","return","short","signed","sizeof","static","struct","switch","typedef","union","unsigned","void","volatile","while","inline","restrict","_Bool","_Complex","_Imaginary","_Alignas","_Alignof","_Atomic","_Static_assert","_Noreturn","_Thread_local","_Generic"];t.languages.registerCompletionItemProvider("cpp",{provideCompletionItems:function(n,i){return{suggestions:u(t,n,i,r,[e])}}});var n=["False","None","True","and","as","assert","break","class","continue","def","del","elif","else","except","finally","for","from","global","if","import","in","is","lambda","nonlocal","not","or","pass","raise","return","try","while","with","yield"];t.languages.registerCompletionItemProvider("python",{provideCompletionItems:function(e,r){var i=[{label:"print",kind:t.languages.CompletionItemKind.Snippet,insertText:["print($0)"].join("\n"),insertTextRules:t.languages.CompletionItemInsertTextRule.InsertAsSnippet}];return{suggestions:u(t,e,r,n,i)}}});var i=["abstract","assert","boolean","break","byte","case","catch","char","class","const","continue","default","do","double","else","enum","extends","final","finally","float","for","goto","if","implements","import","instance of","int","interface","long","native","new","package","private","protected","public","return","strictfp","short","static","super","switch","synchronized","this","throw","throws","transient","try","void","volatile","while"];t.languages.registerCompletionItemProvider("java",{provideCompletionItems:function(r,n){var o=[e,{label:"main",kind:t.languages.CompletionItemKind.Snippet,insertText:["public static void main(String[] args) {","\t$0","}"].join("\n"),insertTextRules:t.languages.CompletionItemInsertTextRule.InsertAsSnippet},{label:"System.out.print",kind:t.languages.CompletionItemKind.Snippet,insertText:["System.out.print($0)"].join("\n"),insertTextRules:t.languages.CompletionItemInsertTextRule.InsertAsSnippet}];return{suggestions:u(t,r,n,i,o)}}})}(g),D&&(e.addCommand(g.KeyMod.CtrlCmd|g.KeyMod.Shift|g.KeyCode.KEY_V,(function(){return $(),null})),e.addCommand(g.KeyMod.CtrlCmd|g.KeyCode.KEY_C,(function(){return $(),null}))),window.Monaco=g,L&&e.onDidBlurEditorWidget((function(){L(e.getValue())})),N&&e.onDidFocusEditorText((function(){N(e.getValue())})),D){e.addCommand(g.KeyMod.CtrlCmd|g.KeyCode.KEY_V,(function(){return $(),null})),e.onDidPaste((function(t){V.current.pastePos=t}));try{window.addEventListener("paste",tt)}catch(t){}}var r=function(){var t;return G.current&&(t=new c.default((function(t){var e,r=Object(o.a)(t);try{for(r.s();!(e=r.n()).done;){var n=e.value;(n.target.offsetHeight>0||n.target.offsetWidth>0)&&V.current.instance.layout()}}catch(t){r.e(t)}finally{r.f()}}))).observe(G.current),t}();return Z(!0),function(){var t=V.current.instance;t.dispose();var e=t.getModel();e&&e.dispose(),V.current.subscription&&V.current.subscription.dispose(),D&&window.removeEventListener("paste",tt),r.unobserve(G.current)}}catch(t){}}))}),[]),Object(A.useEffect)((function(){if(V.current.instance&&J)return document.addEventListener("keydown",et,!1),function(){document.removeEventListener("keydown",et)}}),[I,J]),Object(A.useEffect)((function(){var t=V.current.instance;if(t&&J){var e=p(b);g.editor.setModelLanguage(t.getModel(),e),console.log("language:",b,t.getModel(),e)}}),[b,J]),Object(A.useEffect)((function(){V.current.instance&&J&&g.editor.setTheme(F)}),[F,J]),Object(A.useEffect)((function(){var t=V.current.instance;t&&J&&(t.updateOptions(Object(n.a)({},E)),setTimeout((function(){t.getModel().updateOptions(Object(n.a)({},E))}),200))}),[JSON.stringify(E),J]),Object(A.useEffect)((function(){var t=V.current.instance;t&&J&&t.layout()}),[f,v,J]);var it=Object(A.useState)(h(f)),ot=Object(a.a)(it,2),at=ot[0],st=(ot[1],Object(A.useState)(h(v))),At=Object(a.a)(st,2),lt=At[0],ct=At[1],ut=Object(n.a)(Object(n.a)({},B),{},{width:at,height:lt});return l.a.createElement("div",{className:"my-monaco-editor",ref:G,style:ut})};function m(t){var e=t.width,i=void 0===e?"100%":e,s=t.height,u=void 0===s?"100%":s,d=t.original,f=t.modified,p=t.language,m=t.options,v=void 0===m?{}:m,y=Object(A.useRef)(),w=Object(A.useState)(null),b=Object(a.a)(w,2),C=b[0],B=b[1];Object(A.useEffect)((function(){y.current&&r.e(/*! import() | monaco-editor */27).then(r.t.bind(null,/*! monaco-editor/esm/vs/editor/editor.api.js */"M/lh",7)).then((function(t){var e=(g=t).editor.createDiffEditor(y.current,Object(n.a)(Object(n.a)({enableSplitViewResizing:!1,scrollBeyondLastLine:!1,roundedSelection:!1,renderIndicators:!1,useShadows:!1,horizontal:"hidden",lineNumbers:"off",ignoreTrimWhitespace:!1,followsCaret:!0,ignoreCharChanges:!0,minimap:{enabled:!1},readOnly:!0},v),{},{wordWrap:!0}));B(e);var r=function(t){var e;return y.current&&(e=new c.default((function(e){var r,n=Object(o.a)(e);try{for(n.s();!(r=n.n()).done;){var i=r.value;(i.target.offsetHeight>0||i.target.offsetWidth>0)&&t.layout()}}catch(t){n.e(t)}finally{n.f()}}))).observe(y.current),e}(e);return function(){e.dispose();var t=e.getModel();t&&t.dispose(),r.unobserve(y.current)}}))}),[]),Object(A.useEffect)((function(){C&&C.setModel({original:g.editor.createModel(d,p),modified:g.editor.createModel(f,p)})}),[d,f,p,C]);var x={width:h(i),height:h(u)};return l.a.createElement("div",{className:"my-diff-editor",ref:y,style:x})}},Ze12:
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/dom.js ***!
|
|
|
\**********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./env */"ItGF"),i=r(/*! ./fourPointsTransform */"hOwI").buildTransformer,o=[];function a(t,e,r,o,a){if(e.getBoundingClientRect&&n.domSupported&&!s(e)){var A=e.___zrEVENTSAVED||(e.___zrEVENTSAVED={}),l=function(t,e,r){for(var n=r?"invTrans":"trans",o=e[n],a=e.srcCoords,s=!0,A=[],l=[],c=0;c<4;c++){var u=t[c].getBoundingClientRect(),h=2*c,d=u.left,f=u.top;A.push(d,f),s=s&&a&&d===a[h]&&f===a[h+1],l.push(t[c].offsetLeft,t[c].offsetTop)}return s&&o?o:(e.srcCoords=A,e[n]=r?i(l,A):i(A,l))}(function(t,e){var r=e.markers;if(r)return r;r=e.markers=[];for(var n=["left","right"],i=["top","bottom"],o=0;o<4;o++){var a=document.createElement("div"),s=a.style,A=o%2,l=(o>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",n[A]+":0",i[l]+":0",n[1-A]+":auto",i[1-l]+":auto",""].join("!important;"),t.appendChild(a),r.push(a)}return r}(e,A),A,a);if(l)return l(t,r,o),!0}return!1}function s(t){return"CANVAS"===t.nodeName.toUpperCase()}e.transformLocalCoord=function(t,e,r,n,i){return a(o,e,n,i,!0)&&a(t,r,o[0],o[1])},e.transformCoordWithViewport=a,e.isCanvasEl=s},ZpRC:
|
|
|
/*!*************************************************************************!*\
|
|
|
!*** ./node_modules/scroll-into-view-if-needed/es/index.js + 1 modules ***!
|
|
|
\*************************************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";function n(t){return"object"==typeof t&&null!=t&&1===t.nodeType}function i(t,e){return(!e||"hidden"!==t)&&"visible"!==t&&"clip"!==t}function o(t,e){if(t.clientHeight<t.scrollHeight||t.clientWidth<t.scrollWidth){var r=getComputedStyle(t,null);return i(r.overflowY,e)||i(r.overflowX,e)||function(t){var e=function(t){if(!t.ownerDocument||!t.ownerDocument.defaultView)return null;try{return t.ownerDocument.defaultView.frameElement}catch(t){return null}}(t);return!!e&&(e.clientHeight<t.scrollHeight||e.clientWidth<t.scrollWidth)}(t)}return!1}function a(t,e,r,n,i,o,a,s){return o<t&&a>e||o>t&&a<e?0:o<=t&&s<=r||a>=e&&s>=r?o-t-n:a>e&&s<r||o<t&&s>r?a-e+i:0}var s=function(t,e){var r=window,i=e.scrollMode,s=e.block,A=e.inline,l=e.boundary,c=e.skipOverflowHiddenElements,u="function"==typeof l?l:function(t){return t!==l};if(!n(t))throw new TypeError("Invalid target");for(var h=document.scrollingElement||document.documentElement,d=[],f=t;n(f)&&u(f);){if((f=f.parentElement)===h){d.push(f);break}null!=f&&f===document.body&&o(f)&&!o(document.documentElement)||null!=f&&o(f,c)&&d.push(f)}for(var p=r.visualViewport?r.visualViewport.width:innerWidth,g=r.visualViewport?r.visualViewport.height:innerHeight,m=window.scrollX||pageXOffset,v=window.scrollY||pageYOffset,y=t.getBoundingClientRect(),w=y.height,b=y.width,C=y.top,B=y.right,x=y.bottom,E=y.left,S="start"===s||"nearest"===s?C:"end"===s?x:C+w/2,k="center"===A?E+b/2:"end"===A?B:E,T=[],F=0;F<d.length;F++){var L=d[F],I=L.getBoundingClientRect(),_=I.height,U=I.width,O=I.top,D=I.right,Q=I.bottom,M=I.left;if("if-needed"===i&&C>=0&&E>=0&&x<=g&&B<=p&&C>=O&&x<=Q&&E>=M&&B<=D)return T;var R=getComputedStyle(L),P=parseInt(R.borderLeftWidth,10),H=parseInt(R.borderTopWidth,10),N=parseInt(R.borderRightWidth,10),K=parseInt(R.borderBottomWidth,10),j=0,G=0,V="offsetWidth"in L?L.offsetWidth-L.clientWidth-P-N:0,z="offsetHeight"in L?L.offsetHeight-L.clientHeight-H-K:0;if(h===L)j="start"===s?S:"end"===s?S-g:"nearest"===s?a(v,v+g,g,H,K,v+S,v+S+w,w):S-g/2,G="start"===A?k:"center"===A?k-p/2:"end"===A?k-p:a(m,m+p,p,P,N,m+k,m+k+b,b),j=Math.max(0,j+v),G=Math.max(0,G+m);else{j="start"===s?S-O-H:"end"===s?S-Q+K+z:"nearest"===s?a(O,Q,_,H,K+z,S,S+w,w):S-(O+_/2)+z/2,G="start"===A?k-M-P:"center"===A?k-(M+U/2)+V/2:"end"===A?k-D+N+V:a(M,D,U,P,N+V,k,k+b,b);var W=L.scrollLeft,Y=L.scrollTop;S+=Y-(j=Math.max(0,Math.min(Y+j,L.scrollHeight-_+z))),k+=W-(G=Math.max(0,Math.min(W+G,L.scrollWidth-U+V)))}T.push({el:L,top:j,left:G})}return T};function A(t){return t===Object(t)&&0!==Object.keys(t).length}e.a=function(t,e){var r=!t.ownerDocument.documentElement.contains(t);if(A(e)&&"function"==typeof e.behavior)return e.behavior(r?[]:s(t,e));if(!r){var n=function(t){return!1===t?{block:"end",inline:"nearest"}:A(t)?t:{block:"start",inline:"nearest"}}(e);return function(t,e){void 0===e&&(e="auto");var r="scrollBehavior"in document.body.style;t.forEach((function(t){var n=t.el,i=t.top,o=t.left;n.scroll&&r?n.scroll({top:i,left:o,behavior:e}):(n.scrollTop=i,n.scrollLeft=o)}))}(s(t,n),n.behavior)}}},aKvl:
|
|
|
/*!*******************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/quadratic.js ***!
|
|
|
\*******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/curve */"Sj9i").quadraticProjectPoint;e.containStroke=function(t,e,r,i,o,a,s,A,l){if(0===s)return!1;var c=s;return!(l>e+c&&l>i+c&&l>a+c||l<e-c&&l<i-c&&l<a-c||A>t+c&&A>r+c&&A>o+c||A<t-c&&A<r-c&&A<o-c)&&n(t,e,r,i,o,a,A,l,null)<=c/2}},aRTE:
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/ErrorCorrectLevel.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){t.exports={L:1,M:0,Q:3,H:2}},aX58:
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/zrender.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./core/guid */"3gBT"),i=r(/*! ./core/env */"ItGF"),o=r(/*! ./core/util */"bYtY"),a=r(/*! ./Handler */"0s+r"),s=r(/*! ./Storage */"r6Bn"),A=r(/*! ./Painter */"7SHv"),l=r(/*! ./animation/Animation */"MKOG"),c=r(/*! ./dom/HandlerProxy */"zarK"),u=!i.canvasSupported,h={canvas:A},d={};var f=function(t,e,r){r=r||{},this.dom=e,this.id=t;var n=this,A=new s,d=r.renderer;if(u){if(!h.vml)throw new Error("You need to require 'zrender/vml/vml' to support IE8");d="vml"}else d&&h[d]||(d="canvas");var f=new h[d](e,A,r,t);this.storage=A,this.painter=f;var p=i.node||i.worker?null:new c(f.getViewportRoot(),f.root);this.handler=new a(A,f,p,f.root),this.animation=new l({stage:{update:o.bind(this.flush,this)}}),this.animation.start(),this._needsRefresh;var g=A.delFromStorage,m=A.addToStorage;A.delFromStorage=function(t){g.call(A,t),t&&t.removeSelfFromZr(n)},A.addToStorage=function(t){m.call(A,t),t.addSelfToZr(n)}};f.prototype={constructor:f,getId:function(){return this.id},add:function(t){this.storage.addRoot(t),this._needsRefresh=!0},remove:function(t){this.storage.delRoot(t),this._needsRefresh=!0},configLayer:function(t,e){this.painter.configLayer&&this.painter.configLayer(t,e),this._needsRefresh=!0},setBackgroundColor:function(t){this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this._needsRefresh=!0},refreshImmediately:function(){this._needsRefresh=this._needsRefreshHover=!1,this.painter.refresh(),this._needsRefresh=this._needsRefreshHover=!1},refresh:function(){this._needsRefresh=!0},flush:function(){var t;this._needsRefresh&&(t=!0,this.refreshImmediately()),this._needsRefreshHover&&(t=!0,this.refreshHoverImmediately()),t&&this.trigger("rendered")},addHover:function(t,e){if(this.painter.addHover){var r=this.painter.addHover(t,e);return this.refreshHover(),r}},removeHover:function(t){this.painter.removeHover&&(this.painter.removeHover(t),this.refreshHover())},clearHover:function(){this.painter.clearHover&&(this.painter.clearHover(),this.refreshHover())},refreshHover:function(){this._needsRefreshHover=!0},refreshHoverImmediately:function(){this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.refreshHover()},resize:function(t){t=t||{},this.painter.resize(t.width,t.height),this.handler.resize()},clearAnimation:function(){this.animation.clear()},getWidth:function(){return this.painter.getWidth()},getHeight:function(){return this.painter.getHeight()},pathToImage:function(t,e){return this.painter.pathToImage(t,e)},setCursorStyle:function(t){this.handler.setCursorStyle(t)},findHover:function(t,e){return this.handler.findHover(t,e)},on:function(t,e,r){this.handler.on(t,e,r)},off:function(t,e){this.handler.off(t,e)},trigger:function(t,e){this.handler.trigger(t,e)},clear:function(){this.storage.delRoot(),this.painter.clear()},dispose:function(){var t;this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,t=this.id,delete d[t]}},e.version="4.3.1",e.init=function(t,e){var r=new f(n(),t,e);return d[r.id]=r,r},e.dispose=function(t){if(t)t.dispose();else{for(var e in d)d.hasOwnProperty(e)&&d[e].dispose();d={}}return this},e.getInstance=function(t){return d[t]},e.registerPainter=function(t,e){h[t]=e}},bT9E:
|
|
|
/*!*****************************************!*\
|
|
|
!*** ./node_modules/rc-util/es/omit.js ***!
|
|
|
\*****************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";r.d(e,"a",(function(){return i}));var n=r(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ");function i(t,e){var r=Object(n.a)({},t);return Array.isArray(e)&&e.forEach((function(t){delete r[t]})),r}},bYtY:
|
|
|
/*!***********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/util.js ***!
|
|
|
\***********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1,"[object CanvasPattern]":1,"[object Image]":1,"[object Canvas]":1},n={"[object Int8Array]":1,"[object Uint8Array]":1,"[object Uint8ClampedArray]":1,"[object Int16Array]":1,"[object Uint16Array]":1,"[object Int32Array]":1,"[object Uint32Array]":1,"[object Float32Array]":1,"[object Float64Array]":1},i=Object.prototype.toString,o=Array.prototype,a=o.forEach,s=o.filter,A=o.slice,l=o.map,c=o.reduce,u={};function h(t){if(null==t||"object"!=typeof t)return t;var e=t,o=i.call(t);if("[object Array]"===o){if(!B(t)){e=[];for(var a=0,s=t.length;a<s;a++)e[a]=h(t[a])}}else if(n[o]){if(!B(t)){var A=t.constructor;if(t.constructor.from)e=A.from(t);else{e=new A(t.length);for(a=0,s=t.length;a<s;a++)e[a]=h(t[a])}}}else if(!r[o]&&!B(t)&&!C(t))for(var l in e={},t)t.hasOwnProperty(l)&&(e[l]=h(t[l]));return e}function d(t,e,r){if(!w(e)||!w(t))return r?h(e):t;for(var n in e)if(e.hasOwnProperty(n)){var i=t[n],o=e[n];!w(o)||!w(i)||y(o)||y(i)||C(o)||C(i)||b(o)||b(i)||B(o)||B(i)?!r&&n in t||(t[n]=h(e[n])):d(i,o,r)}return t}function f(t,e,r){for(var n in e)e.hasOwnProperty(n)&&(r?null!=e[n]:null==t[n])&&(t[n]=e[n]);return t}var p,g=function(){return u.createCanvas()};function m(t,e,r){if(t&&e)if(t.forEach&&t.forEach===a)t.forEach(e,r);else if(t.length===+t.length)for(var n=0,i=t.length;n<i;n++)e.call(r,t[n],n,t);else for(var o in t)t.hasOwnProperty(o)&&e.call(r,t[o],o,t)}function v(t,e){var r=A.call(arguments,2);return function(){return t.apply(e,r.concat(A.call(arguments)))}}function y(t){return"[object Array]"===i.call(t)}function w(t){var e=typeof t;return"function"===e||!!t&&"object"===e}function b(t){return!!r[i.call(t)]}function C(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}u.createCanvas=function(){return document.createElement("canvas")};function B(t){return t.__ec_primitive__}function x(t){var e=y(t);this.data={};var r=this;function n(t,n){e?r.set(t,n):r.set(n,t)}t instanceof x?t.each(n):t&&m(t,n)}x.prototype={constructor:x,get:function(t){return this.data.hasOwnProperty(t)?this.data[t]:null},set:function(t,e){return this.data[t]=e},each:function(t,e){for(var r in void 0!==e&&(t=v(t,e)),this.data)this.data.hasOwnProperty(r)&&t(this.data[r],r)},removeKey:function(t){delete this.data[t]}},e.$override=function(t,e){"createCanvas"===t&&(p=null),u[t]=e},e.clone=h,e.merge=d,e.mergeAll=function(t,e){for(var r=t[0],n=1,i=t.length;n<i;n++)r=d(r,t[n],e);return r},e.extend=function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);return t},e.defaults=f,e.createCanvas=g,e.getContext=function(){return p||(p=g().getContext("2d")),p},e.indexOf=function(t,e){if(t){if(t.indexOf)return t.indexOf(e);for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r}return-1},e.inherits=function(t,e){var r=t.prototype;function n(){}for(var i in n.prototype=e.prototype,t.prototype=new n,r)r.hasOwnProperty(i)&&(t.prototype[i]=r[i]);t.prototype.constructor=t,t.superClass=e},e.mixin=function(t,e,r){f(t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,r)},e.isArrayLike=function(t){if(t)return"string"!=typeof t&&"number"==typeof t.length},e.each=m,e.map=function(t,e,r){if(t&&e){if(t.map&&t.map===l)return t.map(e,r);for(var n=[],i=0,o=t.length;i<o;i++)n.push(e.call(r,t[i],i,t));return n}},e.reduce=function(t,e,r,n){if(t&&e){if(t.reduce&&t.reduce===c)return t.reduce(e,r,n);for(var i=0,o=t.length;i<o;i++)r=e.call(n,r,t[i],i,t);return r}},e.filter=function(t,e,r){if(t&&e){if(t.filter&&t.filter===s)return t.filter(e,r);for(var n=[],i=0,o=t.length;i<o;i++)e.call(r,t[i],i,t)&&n.push(t[i]);return n}},e.find=function(t,e,r){if(t&&e)for(var n=0,i=t.length;n<i;n++)if(e.call(r,t[n],n,t))return t[n]},e.bind=v,e.curry=function(t){var e=A.call(arguments,1);return function(){return t.apply(this,e.concat(A.call(arguments)))}},e.isArray=y,e.isFunction=function(t){return"function"==typeof t},e.isString=function(t){return"[object String]"===i.call(t)},e.isObject=w,e.isBuiltInObject=b,e.isTypedArray=function(t){return!!n[i.call(t)]},e.isDom=C,e.eqNaN=function(t){return t!=t},e.retrieve=function(t){for(var e=0,r=arguments.length;e<r;e++)if(null!=arguments[e])return arguments[e]},e.retrieve2=function(t,e){return null!=t?t:e},e.retrieve3=function(t,e,r){return null!=t?t:null!=e?e:r},e.slice=function(){return Function.call.apply(A,arguments)},e.normalizeCssArray=function(t){if("number"==typeof t)return[t,t,t,t];var e=t.length;return 2===e?[t[0],t[1],t[0],t[1]]:3===e?[t[0],t[1],t[2],t[1]]:t},e.assert=function(t,e){if(!t)throw new Error(e)},e.trim=function(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")},e.setAsPrimitive=function(t){t.__ec_primitive__=!0},e.isPrimitive=B,e.createHashMap=function(t){return new x(t)},e.concatArray=function(t,e){for(var r=new t.constructor(t.length+e.length),n=0;n<t.length;n++)r[n]=t[n];var i=t.length;for(n=0;n<e.length;n++)r[n+i]=e[n];return r},e.noop=function(){}},biw7:
|
|
|
/*!**********************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/context/TableContext.js ***!
|
|
|
\**********************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";var n=r(/*! react */"q1tI"),i=n.createContext(null);e.a=i},c5Ni:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/codemirror/theme/blackboard.css ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){},chpo:
|
|
|
/*!********************************************!*\
|
|
|
!*** ./node_modules/size-sensor/lib/id.js ***!
|
|
|
\********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=1;e.default=function(){return"".concat(n++)}},crp1:
|
|
|
/*!********************************************!*\
|
|
|
!*** ./node_modules/fflate/esm/browser.js ***!
|
|
|
\********************************************/
|
|
|
/*! exports provided: Deflate, AsyncDeflate, deflate, deflateSync, Inflate, AsyncInflate, inflate, inflateSync, Gzip, AsyncGzip, gzip, gzipSync, Gunzip, AsyncGunzip, gunzip, gunzipSync, Zlib, AsyncZlib, zlib, zlibSync, Unzlib, AsyncUnzlib, unzlib, unzlibSync, compress, AsyncCompress, compressSync, Compress, Decompress, AsyncDecompress, decompress, decompressSync, strToU8, strFromU8, zip, zipSync, unzip, unzipSync */
|
|
|
/*! exports used: unzlibSync, zlibSync */function(t,e,r){"use strict";r.d(e,"b",(function(){return Y})),r.d(e,"a",(function(){return X}));var n=Uint8Array,i=Uint16Array,o=Uint32Array,a=new n([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),s=new n([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),A=new n([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),l=function(t,e){for(var r=new i(31),n=0;n<31;++n)r[n]=e+=1<<t[n-1];var a=new o(r[30]);for(n=1;n<30;++n)for(var s=r[n];s<r[n+1];++s)a[s]=s-r[n]<<5|n;return[r,a]},c=l(a,2),u=c[0],h=c[1];u[28]=258,h[258]=28;for(var d=l(s,0),f=d[0],p=d[1],g=new i(32768),m=0;m<32768;++m){var v=(43690&m)>>>1|(21845&m)<<1;v=(61680&(v=(52428&v)>>>2|(13107&v)<<2))>>>4|(3855&v)<<4,g[m]=((65280&v)>>>8|(255&v)<<8)>>>1}var y=function(t,e,r){for(var n=t.length,o=0,a=new i(e);o<n;++o)++a[t[o]-1];var s,A=new i(e);for(o=0;o<e;++o)A[o]=A[o-1]+a[o-1]<<1;if(r){s=new i(1<<e);var l=15-e;for(o=0;o<n;++o)if(t[o])for(var c=o<<4|t[o],u=e-t[o],h=A[t[o]-1]++<<u,d=h|(1<<u)-1;h<=d;++h)s[g[h]>>>l]=c}else for(s=new i(n),o=0;o<n;++o)s[o]=g[A[t[o]-1]++]>>>15-t[o];return s},w=new n(288);for(m=0;m<144;++m)w[m]=8;for(m=144;m<256;++m)w[m]=9;for(m=256;m<280;++m)w[m]=7;for(m=280;m<288;++m)w[m]=8;var b=new n(32);for(m=0;m<32;++m)b[m]=5;var C=y(w,9,0),B=y(w,9,1),x=y(b,5,0),E=y(b,5,1),S=function(t){for(var e=t[0],r=1;r<t.length;++r)t[r]>e&&(e=t[r]);return e},k=function(t,e,r){var n=e/8>>0;return(t[n]|t[n+1]<<8)>>>(7&e)&r},T=function(t,e){var r=e/8>>0;return(t[r]|t[r+1]<<8|t[r+2]<<16)>>>(7&e)},F=function(t){return(t/8>>0)+(7&t&&1)},L=function(t,e,r){(null==e||e<0)&&(e=0),(null==r||r>t.length)&&(r=t.length);var a=new(t instanceof i?i:t instanceof o?o:n)(r-e);return a.set(t.subarray(e,r)),a},I=function(t,e,r){var i=t.length,o=!e||r,l=!r||r.i;r||(r={}),e||(e=new n(3*i));var c=function(t){var r=e.length;if(t>r){var i=new n(Math.max(2*r,t));i.set(e),e=i}},h=r.f||0,d=r.p||0,p=r.b||0,g=r.l,m=r.d,v=r.m,w=r.n,b=8*i;do{if(!g){r.f=h=k(t,d,1);var C=k(t,d+1,3);if(d+=3,!C){var x=t[(N=F(d)+4)-4]|t[N-3]<<8,I=N+x;if(I>i){if(l)throw"unexpected EOF";break}o&&c(p+x),e.set(t.subarray(N,I),p),r.b=p+=x,r.p=d=8*I;continue}if(1==C)g=B,m=E,v=9,w=5;else{if(2!=C)throw"invalid block type";var _=k(t,d,31)+257,U=k(t,d+10,15)+4,O=_+k(t,d+5,31)+1;d+=14;for(var D=new n(O),Q=new n(19),M=0;M<U;++M)Q[A[M]]=k(t,d+3*M,7);d+=3*U;var R=S(Q),P=(1<<R)-1;if(!l&&d+O*(R+7)>b)break;var H=y(Q,R,1);for(M=0;M<O;){var N,K=H[k(t,d,P)];if(d+=15&K,(N=K>>>4)<16)D[M++]=N;else{var j=0,G=0;for(16==N?(G=3+k(t,d,3),d+=2,j=D[M-1]):17==N?(G=3+k(t,d,7),d+=3):18==N&&(G=11+k(t,d,127),d+=7);G--;)D[M++]=j}}var V=D.subarray(0,_),z=D.subarray(_);v=S(V),w=S(z),g=y(V,v,1),m=y(z,w,1)}if(d>b)throw"unexpected EOF"}o&&c(p+131072);for(var W=(1<<v)-1,Y=(1<<w)-1,X=v+w+18;l||d+X<b;){var q=(j=g[T(t,d)&W])>>>4;if((d+=15&j)>b)throw"unexpected EOF";if(!j)throw"invalid length/literal";if(q<256)e[p++]=q;else{if(256==q){g=null;break}var J=q-254;if(q>264){var Z=a[M=q-257];J=k(t,d,(1<<Z)-1)+u[M],d+=Z}var $=m[T(t,d)&Y],tt=$>>>4;if(!$)throw"invalid distance";d+=15&$;z=f[tt];if(tt>3){Z=s[tt];z+=T(t,d)&(1<<Z)-1,d+=Z}if(d>b)throw"unexpected EOF";o&&c(p+131072);for(var et=p+J;p<et;p+=4)e[p]=e[p-z],e[p+1]=e[p+1-z],e[p+2]=e[p+2-z],e[p+3]=e[p+3-z];p=et}}r.l=g,r.p=d,r.b=p,g&&(h=1,r.m=v,r.d=m,r.n=w)}while(!h);return p==e.length?e:L(e,0,p)},_=function(t,e,r){r<<=7&e;var n=e/8>>0;t[n]|=r,t[n+1]|=r>>>8},U=function(t,e,r){r<<=7&e;var n=e/8>>0;t[n]|=r,t[n+1]|=r>>>8,t[n+2]|=r>>>16},O=function(t,e){for(var r=[],o=0;o<t.length;++o)t[o]&&r.push({s:o,f:t[o]});var a=r.length,s=r.slice();if(!a)return[new n(0),0];if(1==a){var A=new n(r[0].s+1);return A[r[0].s]=1,[A,1]}r.sort((function(t,e){return t.f-e.f})),r.push({s:-1,f:25001});var l=r[0],c=r[1],u=0,h=1,d=2;for(r[0]={s:-1,f:l.f+c.f,l:l,r:c};h!=a-1;)l=r[r[u].f<r[d].f?u++:d++],c=r[u!=h&&r[u].f<r[d].f?u++:d++],r[h++]={s:-1,f:l.f+c.f,l:l,r:c};var f=s[0].s;for(o=1;o<a;++o)s[o].s>f&&(f=s[o].s);var p=new i(f+1),g=D(r[h-1],p,0);if(g>e){o=0;var m=0,v=g-e,y=1<<v;for(s.sort((function(t,e){return p[e.s]-p[t.s]||t.f-e.f}));o<a;++o){var w=s[o].s;if(!(p[w]>e))break;m+=y-(1<<g-p[w]),p[w]=e}for(m>>>=v;m>0;){var b=s[o].s;p[b]<e?m-=1<<e-p[b]++-1:++o}for(;o>=0&&m;--o){var C=s[o].s;p[C]==e&&(--p[C],++m)}g=e}return[new n(p),g]},D=function(t,e,r){return-1==t.s?Math.max(D(t.l,e,r+1),D(t.r,e,r+1)):e[t.s]=r},Q=function(t){for(var e=t.length;e&&!t[--e];);for(var r=new i(++e),n=0,o=t[0],a=1,s=function(t){r[n++]=t},A=1;A<=e;++A)if(t[A]==o&&A!=e)++a;else{if(!o&&a>2){for(;a>138;a-=138)s(32754);a>2&&(s(a>10?a-11<<5|28690:a-3<<5|12305),a=0)}else if(a>3){for(s(o),--a;a>6;a-=6)s(8304);a>2&&(s(a-3<<5|8208),a=0)}for(;a--;)s(o);a=1,o=t[A]}return[r.subarray(0,n),e]},M=function(t,e){for(var r=0,n=0;n<e.length;++n)r+=t[n]*e[n];return r},R=function(t,e,r){var n=r.length,i=F(e+2);t[i]=255&n,t[i+1]=n>>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var o=0;o<n;++o)t[i+o+4]=r[o];return 8*(i+4+n)},P=function(t,e,r,n,o,l,c,u,h,d,f){_(e,f++,r),++o[256];for(var p=O(o,15),g=p[0],m=p[1],v=O(l,15),B=v[0],E=v[1],S=Q(g),k=S[0],T=S[1],F=Q(B),L=F[0],I=F[1],D=new i(19),P=0;P<k.length;++P)D[31&k[P]]++;for(P=0;P<L.length;++P)D[31&L[P]]++;for(var H=O(D,7),N=H[0],K=H[1],j=19;j>4&&!N[A[j-1]];--j);var G,V,z,W,Y=d+5<<3,X=M(o,w)+M(l,b)+c,q=M(o,g)+M(l,B)+c+14+3*j+M(D,N)+(2*D[16]+3*D[17]+7*D[18]);if(Y<=X&&Y<=q)return R(e,f,t.subarray(h,h+d));if(_(e,f,1+(q<X)),f+=2,q<X){G=y(g,m,0),V=g,z=y(B,E,0),W=B;var J=y(N,K,0);_(e,f,T-257),_(e,f+5,I-1),_(e,f+10,j-4),f+=14;for(P=0;P<j;++P)_(e,f+3*P,N[A[P]]);f+=3*j;for(var Z=[k,L],$=0;$<2;++$){var tt=Z[$];for(P=0;P<tt.length;++P){var et=31&tt[P];_(e,f,J[et]),f+=N[et],et>15&&(_(e,f,tt[P]>>>5&127),f+=tt[P]>>>12)}}}else G=C,V=w,z=x,W=b;for(P=0;P<u;++P)if(n[P]>255){et=n[P]>>>18&31;U(e,f,G[et+257]),f+=V[et+257],et>7&&(_(e,f,n[P]>>>23&31),f+=a[et]);var rt=31&n[P];U(e,f,z[rt]),f+=W[rt],rt>3&&(U(e,f,n[P]>>>5&8191),f+=s[rt])}else U(e,f,G[n[P]]),f+=V[n[P]];return U(e,f,G[256]),f+V[256]},H=new o([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),N=new n(0),K=function(t,e,r,A,l,c){var u=t.length,d=new n(A+u+5*(1+Math.floor(u/7e3))+l),f=d.subarray(A,d.length-l),g=0;if(!e||u<8)for(var m=0;m<=u;m+=65535){var v=m+65535;v<u?g=R(f,g,t.subarray(m,v)):(f[m]=c,g=R(f,g,t.subarray(m,u)))}else{for(var y=H[e-1],w=y>>>13,b=8191&y,C=(1<<r)-1,B=new i(32768),x=new i(C+1),E=Math.ceil(r/3),S=2*E,k=function(e){return(t[e]^t[e+1]<<E^t[e+2]<<S)&C},T=new o(25e3),I=new i(288),_=new i(32),U=0,O=0,D=(m=0,0),Q=0,M=0;m<u;++m){var K=k(m),j=32767&m,G=x[K];if(B[j]=G,x[K]=j,Q<=m){var V=u-m;if((U>7e3||D>24576)&&V>423){g=P(t,f,0,T,I,_,O,D,M,m-M,g),D=U=O=0,M=m;for(var z=0;z<286;++z)I[z]=0;for(z=0;z<30;++z)_[z]=0}var W=2,Y=0,X=b,q=j-G&32767;if(V>2&&K==k(m-q))for(var J=Math.min(w,V)-1,Z=Math.min(32767,m),$=Math.min(258,V);q<=Z&&--X&&j!=G;){if(t[m+W]==t[m+W-q]){for(var tt=0;tt<$&&t[m+tt]==t[m+tt-q];++tt);if(tt>W){if(W=tt,Y=q,tt>J)break;var et=Math.min(q,tt-2),rt=0;for(z=0;z<et;++z){var nt=m-q+z+32768&32767,it=nt-B[nt]+32768&32767;it>rt&&(rt=it,G=nt)}}}q+=(j=G)-(G=B[j])+32768&32767}if(Y){T[D++]=268435456|h[W]<<18|p[Y];var ot=31&h[W],at=31&p[Y];O+=a[ot]+s[at],++I[257+ot],++_[at],Q=m+W,++U}else T[D++]=t[m],++I[t[m]]}}g=P(t,f,c,T,I,_,O,D,M,m-M,g),c||(g=R(f,g,N))}return L(d,0,A+F(g)+l)},j=function(){var t=1,e=0;return{p:function(r){for(var n=t,i=e,o=r.length,a=0;a!=o;){for(var s=Math.min(a+5552,o);a<s;++a)i+=n+=r[a];n%=65521,i%=65521}t=n,e=i},d:function(){return(t>>>8<<16|(255&e)<<8|e>>>8)+2*((255&t)<<23)}}},G=function(t,e,r,n,i){return K(t,null==e.level?6:e.level,null==e.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(t.length)))):12+e.mem,r,n,!i)},V=function(t,e,r){for(;r;++e)t[e]=r,r>>>=8},z=function(t,e){var r=e.level,n=0==r?0:r<6?1:9==r?3:2;t[0]=120,t[1]=n<<6|(n?32-2*n:1)},W=function(t){if(8!=(15&t[0])||t[0]>>>4>7||(t[0]<<8|t[1])%31)throw"invalid zlib data";if(32&t[1])throw"invalid zlib data: preset dictionaries not supported"};function Y(t,e){void 0===e&&(e={});var r=j();r.p(t);var n=G(t,e,2,4);return z(n,e),V(n,n.length-4,r.d()),n}function X(t,e){return I((W(t),t.subarray(2,-4)),e)}},dMvE:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/animation/easing.js ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(2-Math.pow(2,-10*(t-1)))},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var e,r=.1;return 0===t?0:1===t?1:(!r||r<1?(r=1,e=.1):e=.4*Math.asin(1/r)/(2*Math.PI),-r*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4))},elasticOut:function(t){var e,r=.1;return 0===t?0:1===t?1:(!r||r<1?(r=1,e=.1):e=.4*Math.asin(1/r)/(2*Math.PI),r*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/.4)+1)},elasticInOut:function(t){var e,r=.1,n=.4;return 0===t?0:1===t?1:(!r||r<1?(r=1,e=.1):e=n*Math.asin(1/r)/(2*Math.PI),(t*=2)<1?r*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/n)*-.5:r*Math.pow(2,-10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/n)*.5+1)},backIn:function(t){var e=1.70158;return t*t*((e+1)*t-e)},backOut:function(t){var e=1.70158;return--t*t*((e+1)*t+e)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?t*t*((e+1)*t-e)*.5:.5*((t-=2)*t*((e+1)*t+e)+2)},bounceIn:function(t){return 1-r.bounceOut(1-t)},bounceOut:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return t<.5?.5*r.bounceIn(2*t):.5*r.bounceOut(2*t-1)+.5}},n=r;t.exports=n},dQei:
|
|
|
/*!****************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/math.js ***!
|
|
|
\****************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){for(var r={glog:function(t){if(t<1)throw new Error("glog("+t+")");return r.LOG_TABLE[t]},gexp:function(t){for(;t<0;)t+=255;for(;t>=256;)t-=255;return r.EXP_TABLE[t]},EXP_TABLE:new Array(256),LOG_TABLE:new Array(256)},n=0;n<8;n++)r.EXP_TABLE[n]=1<<n;for(n=8;n<256;n++)r.EXP_TABLE[n]=r.EXP_TABLE[n-4]^r.EXP_TABLE[n-5]^r.EXP_TABLE[n-6]^r.EXP_TABLE[n-8];for(n=0;n<255;n++)r.LOG_TABLE[r.EXP_TABLE[n]]=n;t.exports=r},dWSS:
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/Polynomial.js ***!
|
|
|
\**********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./math */"dQei");function i(t,e){if(null==t.length)throw new Error(t.length+"/"+e);for(var r=0;r<t.length&&0==t[r];)r++;this.num=new Array(t.length-r+e);for(var n=0;n<t.length-r;n++)this.num[n]=t[n+r]}i.prototype={get:function(t){return this.num[t]},getLength:function(){return this.num.length},multiply:function(t){for(var e=new Array(this.getLength()+t.getLength()-1),r=0;r<this.getLength();r++)for(var o=0;o<t.getLength();o++)e[r+o]^=n.gexp(n.glog(this.get(r))+n.glog(t.get(o)));return new i(e,0)},mod:function(t){if(this.getLength()-t.getLength()<0)return this;for(var e=n.glog(this.get(0))-n.glog(t.get(0)),r=new Array(this.getLength()),o=0;o<this.getLength();o++)r[o]=this.get(o);for(o=0;o<t.getLength();o++)r[o]^=n.gexp(n.glog(t.get(o))+e);return new i(r,0).mod(t)}},t.exports=i},dejd:
|
|
|
/*!***********************************************************!*\
|
|
|
!*** ./src/components/markdown-editor/toolbar/index.less ***!
|
|
|
\***********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){},dmUQ:
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./node_modules/rc-input-number/es/index.js + 1 modules ***!
|
|
|
\**************************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/KeyCode.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";var n=r("Ff2n"),i=r("rePB"),o=r("1OyB"),a=r("vuIU"),s=r("Ji7U"),A=r("md7G"),l=r("foSv"),c=r("q1tI"),u=r.n(c),h=r("TSYQ"),d=r.n(h),f=r("4IlW");function p(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function g(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?p(Object(r),!0).forEach((function(e){Object(i.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):p(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function m(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var r,n=Object(l.a)(t);if(e){var i=Object(l.a)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return Object(A.a)(this,r)}}function v(){}function y(t){t.preventDefault()}var w=Number.MAX_SAFE_INTEGER||Math.pow(2,53)-1,b=function(t){return null!=t},C=function(t,e){return e===t||"number"==typeof e&&"number"==typeof t&&isNaN(e)&&isNaN(t)},B=function(t){Object(s.a)(r,t);var e=m(r);function r(t){var n;Object(o.a)(this,r),(n=e.call(this,t)).onKeyDown=function(t){var e=n.props,r=e.onKeyDown,i=e.onPressEnter;if(t.keyCode===f.a.UP){var o=n.getRatio(t);n.up(t,o,null),n.stop()}else if(t.keyCode===f.a.DOWN){var a=n.getRatio(t);n.down(t,a,null),n.stop()}else t.keyCode===f.a.ENTER&&i&&i(t);if(n.recordCursorPosition(),n.lastKeyCode=t.keyCode,r){for(var s=arguments.length,A=new Array(s>1?s-1:0),l=1;l<s;l++)A[l-1]=arguments[l];r.apply(void 0,[t].concat(A))}},n.onKeyUp=function(t){var e=n.props.onKeyUp;if(n.stop(),n.recordCursorPosition(),e){for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];e.apply(void 0,[t].concat(i))}},n.onChange=function(t){var e=n.props.onChange;n.state.focused&&(n.inputting=!0),n.rawInput=n.props.parser(n.getValueFromEvent(t)),n.setState({inputValue:n.rawInput}),e(n.toNumber(n.rawInput))},n.onMouseUp=function(){var t=n.props.onMouseUp;n.recordCursorPosition(),t&&t.apply(void 0,arguments)},n.onFocus=function(){var t;n.setState({focused:!0}),(t=n.props).onFocus.apply(t,arguments)},n.onBlur=function(){var t=n.props.onBlur;n.inputting=!1,n.setState({focused:!1});var e=n.getCurrentValidValue(n.state.inputValue),r=n.setValue(e,v);if(t){var i=n.input.value,o=n.getInputDisplayValue({focus:!1,value:r});n.input.value=o?Number(o):o,t.apply(void 0,arguments),n.input.value=i}},n.getRatio=function(t){var e=1;return t.metaKey||t.ctrlKey?e=.1:t.shiftKey&&(e=10),e},n.getFullNum=function(t){return isNaN(t)?t:/e/i.test(String(t))?Number(t).toFixed(18).replace(/\.?0+$/,""):t},n.getPrecision=function(t){if(b(n.props.precision))return n.props.precision;var e=String(t);if(e.indexOf("e-")>=0)return parseInt(e.slice(e.indexOf("e-")+2),10);var r=0;return e.indexOf(".")>=0&&(r=e.length-e.indexOf(".")-1),r},n.getInputDisplayValue=function(t){var e,r=t||n.state,i=r.focused,o=r.inputValue,a=r.value;null==(e=i?o:n.toPrecisionAsStep(a))&&(e="");var s=n.formatWrapper(e);return b(n.props.decimalSeparator)&&(s=s.toString().replace(".",n.props.decimalSeparator)),s},n.recordCursorPosition=function(){try{n.cursorStart=n.input.selectionStart,n.cursorEnd=n.input.selectionEnd,n.currentValue=n.input.value,n.cursorBefore=n.input.value.substring(0,n.cursorStart),n.cursorAfter=n.input.value.substring(n.cursorEnd)}catch(t){}},n.restoreByAfter=function(t){if(void 0===t)return!1;var e=n.input.value,r=e.lastIndexOf(t);if(-1===r)return!1;var i=n.cursorBefore.length;return n.lastKeyCode===f.a.DELETE&&n.cursorBefore.charAt(i-1)===t[0]?(n.fixCaret(i,i),!0):r+t.length===e.length&&(n.fixCaret(r,r),!0)},n.partRestoreByAfter=function(t){return void 0!==t&&Array.prototype.some.call(t,(function(e,r){var i=t.substring(r);return n.restoreByAfter(i)}))},n.isNotCompleteNumber=function(t){return isNaN(t)||""===t||null===t||t&&t.toString().indexOf(".")===t.toString().length-1},n.stop=function(){n.autoStepTimer&&clearTimeout(n.autoStepTimer)},n.down=function(t,e,r){n.pressingUpOrDown=!0,n.step("down",t,e,r)},n.up=function(t,e,r){n.pressingUpOrDown=!0,n.step("up",t,e,r)},n.saveInput=function(t){n.input=t};var i=t.value;void 0===i&&(i=t.defaultValue),n.state={focused:t.autoFocus};var a=n.getValidValue(n.toNumber(i));return n.state=g(g({},n.state),{},{inputValue:n.toPrecisionAsStep(a),value:a}),n}return Object(a.a)(r,[{key:"componentDidMount",value:function(){this.componentDidUpdate(null)}},{key:"componentDidUpdate",value:function(t){var e=this.props,r=e.value,n=e.onChange,i=e.max,o=e.min,a=this.state.focused;if(t){if(!C(t.value,r)||!C(t.max,i)||!C(t.min,o)){var s,A=a?r:this.getValidValue(r);s=this.pressingUpOrDown?A:this.inputting?this.rawInput:this.toPrecisionAsStep(A),this.setState({value:A,inputValue:s})}var l="value"in this.props?r:this.state.value;"max"in this.props&&t.max!==i&&"number"==typeof l&&l>i&&n&&n(i),"min"in this.props&&t.min!==o&&"number"==typeof l&&l<o&&n&&n(o)}try{if(void 0!==this.cursorStart&&this.state.focused)if(this.partRestoreByAfter(this.cursorAfter)||this.state.value===this.props.value){if(this.currentValue===this.input.value)switch(this.lastKeyCode){case f.a.BACKSPACE:this.fixCaret(this.cursorStart-1,this.cursorStart-1);break;case f.a.DELETE:this.fixCaret(this.cursorStart+1,this.cursorStart+1)}}else{var c=this.cursorStart+1;this.cursorAfter?this.lastKeyCode===f.a.BACKSPACE?c=this.cursorStart-1:this.lastKeyCode===f.a.DELETE&&(c=this.cursorStart):c=this.input.value.length,this.fixCaret(c,c)}}catch(t){}this.lastKeyCode=null,this.pressingUpOrDown&&this.props.focusOnUpDown&&this.state.focused&&document.activeElement!==this.input&&this.focus()}},{key:"componentWillUnmount",value:function(){this.stop()}},{key:"getCurrentValidValue",value:function(t){var e=t;return e=""===e?"":this.isNotCompleteNumber(parseFloat(e))?this.state.value:this.getValidValue(e),this.toNumber(e)}},{key:"getValueFromEvent",value:function(t){var e=t.target.value.trim().replace(/。/g,".");return b(this.props.decimalSeparator)&&(e=e.replace(this.props.decimalSeparator,".")),e}},{key:"getValidValue",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.props.min,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.props.max,n=parseFloat(t);return isNaN(n)?t:(n<e&&(n=e),n>r&&(n=r),n)}},{key:"setValue",value:function(t,e){var r=this.props.precision,n=this.isNotCompleteNumber(parseFloat(t))?null:parseFloat(t),i=this.state.value,o=void 0===i?null:i,a=this.state.inputValue,s=void 0===a?null:a,A="number"==typeof n?n.toFixed(r):"".concat(n),l=n!==o||A!=="".concat(s);return"value"in this.props?(s=this.toPrecisionAsStep(this.state.value),this.setState({inputValue:s},e)):this.setState({value:n,inputValue:this.toPrecisionAsStep(t)},e),l&&this.props.onChange(n),n}},{key:"getMaxPrecision",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=this.props,n=r.precision,i=r.step;if(b(n))return n;var o=this.getPrecision(e),a=this.getPrecision(i),s=this.getPrecision(t);return t?Math.max(s,o+a):o+a}},{key:"getPrecisionFactor",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=this.getMaxPrecision(t,e);return Math.pow(10,r)}},{key:"focus",value:function(){this.input.focus(),this.recordCursorPosition()}},{key:"blur",value:function(){this.input.blur()}},{key:"select",value:function(){this.input.select()}},{key:"formatWrapper",value:function(t){return this.props.formatter?this.props.formatter(t):t}},{key:"toPrecisionAsStep",value:function(t){if(this.isNotCompleteNumber(t)||""===t)return t;var e=Math.abs(this.getMaxPrecision(t));return isNaN(e)?t.toString():Number(t).toFixed(e)}},{key:"toNumber",value:function(t){var e=this.props.precision,r=this.state.focused,n=t&&t.length>16&&r;return this.isNotCompleteNumber(t)||n?t:b(e)?Math.round(t*Math.pow(10,e))/Math.pow(10,e):Number(t)}},{key:"upStep",value:function(t,e){var r=this.props.step,n=this.getPrecisionFactor(t,e),i=Math.abs(this.getMaxPrecision(t,e)),o=((n*t+n*r*e)/n).toFixed(i);return this.toNumber(o)}},{key:"downStep",value:function(t,e){var r=this.props.step,n=this.getPrecisionFactor(t,e),i=Math.abs(this.getMaxPrecision(t,e)),o=((n*t-n*r*e)/n).toFixed(i);return this.toNumber(o)}},{key:"step",value:function(t,e){var r=this,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,i=arguments.length>3?arguments[3]:void 0;this.stop(),e&&(e.persist(),e.preventDefault());var o=this.props;if(!o.disabled){var a=this.getCurrentValidValue(this.state.inputValue)||0;if(!this.isNotCompleteNumber(a)){var s=this["".concat(t,"Step")](a,n),A=s>o.max||s<o.min;s>o.max?s=o.max:s<o.min&&(s=o.min),this.setValue(s,null),this.setState({focused:!0},(function(){r.pressingUpOrDown=!1})),A||(this.autoStepTimer=setTimeout((function(){r[t](e,n,!0)}),i?200:600))}}}},{key:"fixCaret",value:function(t,e){if(void 0!==t&&void 0!==e&&this.input&&this.input.value)try{var r=this.input.selectionStart,n=this.input.selectionEnd;t===r&&e===n||this.input.setSelectionRange(t,e)}catch(t){}}},{key:"render",value:function(){var t,e=this.props,r=e.prefixCls,o=e.disabled,a=e.readOnly,s=e.useTouch,A=e.autoComplete,l=e.upHandler,c=e.downHandler,h=e.className,f=e.max,p=e.min,g=e.style,m=e.title,w=e.onMouseEnter,b=e.onMouseLeave,C=e.onMouseOver,B=e.onMouseOut,x=e.required,E=e.onClick,S=e.tabIndex,k=e.type,T=e.placeholder,F=e.id,L=e.inputMode,I=e.pattern,_=e.step,U=e.maxLength,O=e.autoFocus,D=e.name,Q=e.onPaste,M=e.onInput,R=Object(n.a)(e,["prefixCls","disabled","readOnly","useTouch","autoComplete","upHandler","downHandler","className","max","min","style","title","onMouseEnter","onMouseLeave","onMouseOver","onMouseOut","required","onClick","tabIndex","type","placeholder","id","inputMode","pattern","step","maxLength","autoFocus","name","onPaste","onInput"]),P=this.state,H=P.value,N=P.focused,K=d()(r,(t={},Object(i.a)(t,h,!!h),Object(i.a)(t,"".concat(r,"-disabled"),o),Object(i.a)(t,"".concat(r,"-focused"),N),t)),j={};Object.keys(R).forEach((function(t){"data-"!==t.substr(0,5)&&"aria-"!==t.substr(0,5)&&"role"!==t||(j[t]=R[t])}));var G=!a&&!o,V=this.getInputDisplayValue(null),z=(H||0===H)&&(isNaN(H)||Number(H)>=f)||o||a,W=(H||0===H)&&(isNaN(H)||Number(H)<=p)||o||a,Y=d()("".concat(r,"-handler"),"".concat(r,"-handler-up"),Object(i.a)({},"".concat(r,"-handler-up-disabled"),z)),X=d()("".concat(r,"-handler"),"".concat(r,"-handler-down"),Object(i.a)({},"".concat(r,"-handler-down-disabled"),W)),q=s?{onTouchStart:z?v:this.up,onTouchEnd:this.stop}:{onMouseDown:z?v:this.up,onMouseUp:this.stop,onMouseLeave:this.stop},J=s?{onTouchStart:W?v:this.down,onTouchEnd:this.stop}:{onMouseDown:W?v:this.down,onMouseUp:this.stop,onMouseLeave:this.stop};return u.a.createElement("div",{className:K,style:g,title:m,onMouseEnter:w,onMouseLeave:b,onMouseOver:C,onMouseOut:B,onFocus:function(){return null},onBlur:function(){return null}},u.a.createElement("div",{className:"".concat(r,"-handler-wrap")},u.a.createElement("span",Object.assign({unselectable:"on"},q,{role:"button","aria-label":"Increase Value","aria-disabled":z,className:Y}),l||u.a.createElement("span",{unselectable:"on",className:"".concat(r,"-handler-up-inner"),onClick:y})),u.a.createElement("span",Object.assign({unselectable:"on"},J,{role:"button","aria-label":"Decrease Value","aria-disabled":W,className:X}),c||u.a.createElement("span",{unselectable:"on",className:"".concat(r,"-handler-down-inner"),onClick:y}))),u.a.createElement("div",{className:"".concat(r,"-input-wrap")},u.a.createElement("input",Object.assign({role:"spinbutton","aria-valuemin":p,"aria-valuemax":f,"aria-valuenow":H,required:x,type:k,placeholder:T,onPaste:Q,onClick:E,onMouseUp:this.onMouseUp,className:"".concat(r,"-input"),tabIndex:S,autoComplete:A,onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:G?this.onKeyDown:v,onKeyUp:G?this.onKeyUp:v,autoFocus:O,maxLength:U,readOnly:a,disabled:o,max:f,min:p,step:_,name:D,title:m,id:F,onChange:this.onChange,ref:this.saveInput,value:this.getFullNum(V),pattern:I,inputMode:L,onInput:M},j))))}}]),r}(u.a.Component);B.defaultProps={focusOnUpDown:!0,useTouch:!1,prefixCls:"rc-input-number",max:w,min:-w,step:1,style:{},onChange:v,onKeyDown:v,onPressEnter:v,onFocus:v,onBlur:v,parser:function(t){return t.replace(/[^\w.-]+/g,"")},required:!1,autoComplete:"off"};var x=B;e.a=x},dqUG:
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/Text.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./Displayable */"Gev7"),i=r(/*! ../core/util */"bYtY"),o=r(/*! ../contain/text */"6GrX"),a=r(/*! ./helper/text */"pzxd"),s=r(/*! ./constant */"gut8").ContextCachedBy,A=function(t){n.call(this,t)};A.prototype={constructor:A,type:"text",brush:function(t,e){var r=this.style;this.__dirty&&a.normalizeTextStyle(r,!0),r.fill=r.stroke=r.shadowBlur=r.shadowColor=r.shadowOffsetX=r.shadowOffsetY=null;var n=r.text;null!=n&&(n+=""),a.needDrawText(n,r)?(this.setTransform(t),a.renderText(this,t,n,r,null,e),this.restoreTransform(t)):t.__attrCachedBy=s.NONE},getBoundingRect:function(){var t=this.style;if(this.__dirty&&a.normalizeTextStyle(t,!0),!this._rect){var e=t.text;null!=e?e+="":e="";var r=o.getBoundingRect(t.text+"",t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.textLineHeight,t.rich);if(r.x+=t.x||0,r.y+=t.y||0,a.getStroke(t.textStroke,t.textStrokeWidth)){var n=t.textStrokeWidth;r.x-=n/2,r.y-=n/2,r.width+=n,r.height+=n}this._rect=r}return this._rect}},i.inherits(A,n);var l=A;t.exports=l},f4xo:
|
|
|
/*!********************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/8BitByte.js ***!
|
|
|
\********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./mode */"nVVt");function i(t){this.mode=n.MODE_8BIT_BYTE,this.data=t}i.prototype={getLength:function(t){return this.data.length},write:function(t){for(var e=0;e<this.data.length;e++)t.put(this.data.charCodeAt(e),8)}},t.exports=i},fW2E:
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/fixShadow.js ***!
|
|
|
\**************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r={shadowBlur:1,shadowOffsetX:1,shadowOffsetY:1,textShadowBlur:1,textShadowOffsetX:1,textShadowOffsetY:1,textBoxShadowBlur:1,textBoxShadowOffsetX:1,textBoxShadowOffsetY:1};t.exports=function(t,e,n){return r.hasOwnProperty(e)?n*t.dpr:n}},fyJ8:
|
|
|
/*!************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/Cell/index.js ***!
|
|
|
\************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";var n=r(/*! @babel/runtime/helpers/esm/defineProperty */"rePB"),i=r(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ"),o=r(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),a=r(/*! @babel/runtime/helpers/esm/typeof */"U8pU"),s=r(/*! react */"q1tI"),A=r(/*! classnames */"TSYQ"),l=r.n(A),c=r(/*! rc-util/es/ref */"c+Xe"),u=r(/*! ../utils/valueUtil */"sR1s");var h=s.forwardRef((function(t,e){var r,A,h,d=t.prefixCls,f=t.className,p=t.record,g=t.index,m=t.dataIndex,v=t.render,y=t.children,w=t.component,b=void 0===w?"td":w,C=t.colSpan,B=t.rowSpan,x=t.fixLeft,E=t.fixRight,S=t.firstFixLeft,k=t.lastFixLeft,T=t.firstFixRight,F=t.lastFixRight,L=t.appendNode,I=t.additionalProps,_=void 0===I?{}:I,U=t.ellipsis,O=t.align,D=t.rowType,Q=t.isSticky,M="".concat(d,"-cell");if(y)h=y;else{var R=Object(u.b)(p,m);if(h=R,v){var P=v(R,p,g);!function(t){return t&&"object"===Object(a.a)(t)&&!Array.isArray(t)&&!s.isValidElement(t)}(P)?h=P:(h=P.children,A=P.props)}}"object"!==Object(a.a)(h)||Array.isArray(h)||s.isValidElement(h)||(h=null),U&&(k||T)&&(h=s.createElement("span",{className:"".concat(M,"-content")},h));var H=A||{},N=H.colSpan,K=H.rowSpan,j=H.style,G=H.className,V=Object(o.a)(H,["colSpan","rowSpan","style","className"]),z=void 0!==N?N:C,W=void 0!==K?K:B;if(0===z||0===W)return null;var Y={},X="number"==typeof x,q="number"==typeof E;X&&(Y.position="sticky",Y.left=x),q&&(Y.position="sticky",Y.right=E);var J,Z={};O&&(Z.textAlign=O);var $=!0===U?{showTitle:!0}:U;$&&($.showTitle||"header"===D)&&("string"==typeof h||"number"==typeof h?J=h.toString():s.isValidElement(h)&&"string"==typeof h.props.children&&(J=h.props.children));var tt,et=Object(i.a)(Object(i.a)(Object(i.a)({title:J},V),_),{},{colSpan:z&&1!==z?z:null,rowSpan:W&&1!==W?W:null,className:l()(M,f,(r={},Object(n.a)(r,"".concat(M,"-fix-left"),X),Object(n.a)(r,"".concat(M,"-fix-left-first"),S),Object(n.a)(r,"".concat(M,"-fix-left-last"),k),Object(n.a)(r,"".concat(M,"-fix-right"),q),Object(n.a)(r,"".concat(M,"-fix-right-first"),T),Object(n.a)(r,"".concat(M,"-fix-right-last"),F),Object(n.a)(r,"".concat(M,"-ellipsis"),U),Object(n.a)(r,"".concat(M,"-with-append"),L),Object(n.a)(r,"".concat(M,"-fix-sticky"),(X||q)&&Q),r),_.className,G),style:Object(i.a)(Object(i.a)(Object(i.a)(Object(i.a)({},_.style),Z),Y),j),ref:(tt=b,"string"==typeof tt||Object(c.c)(tt)?e:null)});return s.createElement(b,Object.assign({},et),L,h)}));h.displayName="Cell";var d=s.memo(h,(function(t,e){return!!e.shouldCellUpdate&&!e.shouldCellUpdate(e.record,t.record)}));e.a=d},gut8:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/constant.js ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){e.ContextCachedBy={NONE:0,STYLE_BIND:1,PLAIN_TEXT:2},e.WILL_BE_RESTORED=9},h7HQ:
|
|
|
/*!***********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Polygon.js ***!
|
|
|
\***********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt"),i=r(/*! ../helper/poly */"T6xi"),o=n.extend({type:"polygon",shape:{points:null,smooth:!1,smoothConstraint:null},buildPath:function(t,e){i.buildPath(t,e,!0)}});t.exports=o},hOwI:
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/fourPointsTransform.js ***!
|
|
|
\**************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=Math.log(2);function n(t,e,i,o,a,s){var A=o+"-"+a,l=t.length;if(s.hasOwnProperty(A))return s[A];if(1===e){var c=Math.round(Math.log((1<<l)-1&~a)/r);return t[i][c]}for(var u=o|1<<i,h=i+1;o&1<<h;)h++;for(var d=0,f=0,p=0;f<l;f++){var g=1<<f;g&a||(d+=(p%2?-1:1)*t[i][f]*n(t,e-1,h,u,a|g,s),p++)}return s[A]=d,d}e.buildTransformer=function(t,e){var r=[[t[0],t[1],1,0,0,0,-e[0]*t[0],-e[0]*t[1]],[0,0,0,t[0],t[1],1,-e[1]*t[0],-e[1]*t[1]],[t[2],t[3],1,0,0,0,-e[2]*t[2],-e[2]*t[3]],[0,0,0,t[2],t[3],1,-e[3]*t[2],-e[3]*t[3]],[t[4],t[5],1,0,0,0,-e[4]*t[4],-e[4]*t[5]],[0,0,0,t[4],t[5],1,-e[5]*t[4],-e[5]*t[5]],[t[6],t[7],1,0,0,0,-e[6]*t[6],-e[6]*t[7]],[0,0,0,t[6],t[7],1,-e[7]*t[6],-e[7]*t[7]]],i={},o=n(r,8,0,0,0,i);if(0!==o){for(var a=[],s=0;s<8;s++)for(var A=0;A<8;A++)null==a[A]&&(a[A]=0),a[A]+=((s+A)%2?-1:1)*n(r,7,0===s?1:0,1<<s,1<<A,i)/o*e[s];return function(t,e,r){var n=e*a[6]+r*a[7]+1;t[0]=(e*a[0]+r*a[1]+a[2])/n,t[1]=(e*a[3]+r*a[4]+a[5])/n}}}},hW8S:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/utils/legacyUtil.js ***!
|
|
|
\******************************************************/
|
|
|
/*! exports provided: INTERNAL_COL_DEFINE, getExpandableProps, getDataAndAriaProps */
|
|
|
/*! exports used: INTERNAL_COL_DEFINE, getDataAndAriaProps, getExpandableProps */function(t,e,r){"use strict";r.d(e,"a",(function(){return o})),r.d(e,"c",(function(){return a})),r.d(e,"b",(function(){return s}));var n=r(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ"),i=r(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),o=(r(/*! rc-util/es/warning */"Kwbf"),"RC_TABLE_INTERNAL_COL_DEFINE");function a(t){var e=t.expandable,r=Object(i.a)(t,["expandable"]);return"expandable"in t?Object(n.a)(Object(n.a)({},r),e):r}function s(t){return Object.keys(t).reduce((function(e,r){return"data-"!==r.substr(0,5)&&"aria-"!==r.substr(0,5)||(e[r]=t[r]),e}),{})}},hX1E:
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/util.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=2*Math.PI;e.normalizeRadian=function(t){return(t%=r)<0&&(t+=r),t}},hydK:
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/svg/core.js ***!
|
|
|
\**********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){e.createElement=function(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}},hyiK:
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/windingLine.js ***!
|
|
|
\*********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){t.exports=function(t,e,r,n,i,o){if(o>e&&o>n||o<e&&o<n)return 0;if(n===e)return 0;var a=n<e?1:-1,s=(o-e)/(n-e);1!==s&&0!==s||(a=n<e?.5:-.5);var A=s*(r-t)+t;return A===i?1/0:A>i?a:0}},iXp4:
|
|
|
/*!**********************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/fixClipWithShadow.js ***!
|
|
|
\**********************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../../core/env */"ItGF"),i=[["shadowBlur",0],["shadowColor","#000"],["shadowOffsetX",0],["shadowOffsetY",0]];t.exports=function(t){return n.browser.ie&&n.browser.version>=11?function(){var e,r=this.__clipPaths,n=this.style;if(r)for(var o=0;o<r.length;o++){var a=r[o],s=a&&a.shape,A=a&&a.type;if(s&&("sector"===A&&s.startAngle===s.endAngle||"rect"===A&&(!s.width||!s.height))){for(var l=0;l<i.length;l++)i[l][2]=n[i[l][0]],n[i[l][0]]=i[l][1];e=!0;break}}if(t.apply(this,arguments),e)for(l=0;l<i.length;l++)n[i[l][0]]=i[l][2]}:t}},j5sG:
|
|
|
/*!****************************************************************!*\
|
|
|
!*** ./node_modules/size-sensor/lib/sensors/resizeObserver.js ***!
|
|
|
\****************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createSensor=void 0;var n,i=(n=r(/*! ../debounce */"NohK"))&&n.__esModule?n:{default:n};e.createSensor=function(t){var e=void 0,r=[],n=(0,i.default)((function(){r.forEach((function(e){e(t)}))})),o=function(){e.disconnect(),r=[],e=void 0};return{element:t,bind:function(i){var o;e||((o=new ResizeObserver(n)).observe(t),n(),e=o),-1===r.indexOf(i)&&r.push(i)},destroy:o,unbind:function(t){var n=r.indexOf(t);-1!==n&&r.splice(n,1),0===r.length&&e&&o()}}}},jTL6:
|
|
|
/*!*******************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Arc.js ***!
|
|
|
\*******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt").extend({type:"arc",shape:{cx:0,cy:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},style:{stroke:"#000",fill:null},buildPath:function(t,e){var r=e.cx,n=e.cy,i=Math.max(e.r,0),o=e.startAngle,a=e.endAngle,s=e.clockwise,A=Math.cos(o),l=Math.sin(o);t.moveTo(A*i+r,l*i+n),t.arc(r,n,i,o,a,!s)}});t.exports=n},juDX:
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/svg/svg.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){r(/*! ./graphic */"P47w"),(0,r(/*! ../zrender */"aX58").registerPainter)("svg",r(/*! ./Painter */"3CBa"))},kSUc:
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./src/components/markdown-editor/index.less ***!
|
|
|
\***************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){},"kVK+":
|
|
|
/*!***************************************!*\
|
|
|
!*** ./node_modules/ieee754/index.js ***!
|
|
|
\***************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){
|
|
|
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
|
e.read=function(t,e,r,n,i){var o,a,s=8*i-n-1,A=(1<<s)-1,l=A>>1,c=-7,u=r?i-1:0,h=r?-1:1,d=t[e+u];for(u+=h,o=d&(1<<-c)-1,d>>=-c,c+=s;c>0;o=256*o+t[e+u],u+=h,c-=8);for(a=o&(1<<-c)-1,o>>=-c,c+=n;c>0;a=256*a+t[e+u],u+=h,c-=8);if(0===o)o=1-l;else{if(o===A)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),o-=l}return(d?-1:1)*a*Math.pow(2,o-n)},e.write=function(t,e,r,n,i,o){var a,s,A,l=8*o-i-1,c=(1<<l)-1,u=c>>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:o-1,f=n?1:-1,p=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,a=c):(a=Math.floor(Math.log(e)/Math.LN2),e*(A=Math.pow(2,-a))<1&&(a--,A*=2),(e+=a+u>=1?h/A:h*Math.pow(2,1-u))*A>=2&&(a++,A/=2),a+u>=c?(s=0,a=c):a+u>=1?(s=(e*A-1)*Math.pow(2,i),a+=u):(s=e*Math.pow(2,u-1)*Math.pow(2,i),a=0));i>=8;t[r+d]=255&s,d+=f,s/=256,i-=8);for(a=a<<i|s,l+=i;l>0;t[r+d]=255&a,d+=f,a/=256,l-=8);t[r+d-f]|=128*p}},lZu9:
|
|
|
/*!***********************************************************!*\
|
|
|
!*** ./node_modules/codemirror/mode/markdown/markdown.js ***!
|
|
|
\***********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){!function(t){"use strict";t.defineMode("markdown",(function(e,r){var n=t.getMode(e,"text/html"),i="null"==n.name;void 0===r.highlightFormatting&&(r.highlightFormatting=!1),void 0===r.maxBlockquoteDepth&&(r.maxBlockquoteDepth=0),void 0===r.taskLists&&(r.taskLists=!1),void 0===r.strikethrough&&(r.strikethrough=!1),void 0===r.emoji&&(r.emoji=!1),void 0===r.fencedCodeBlockHighlighting&&(r.fencedCodeBlockHighlighting=!0),void 0===r.fencedCodeBlockDefaultMode&&(r.fencedCodeBlockDefaultMode="text/plain"),void 0===r.xml&&(r.xml=!0),void 0===r.tokenTypeOverrides&&(r.tokenTypeOverrides={});var o={header:"header",code:"comment",quote:"quote",list1:"variable-2",list2:"variable-3",list3:"keyword",hr:"hr",image:"image",imageAltText:"image-alt-text",imageMarker:"image-marker",formatting:"formatting",linkInline:"link",linkEmail:"link",linkText:"link",linkHref:"string",em:"em",strong:"strong",strikethrough:"strikethrough",emoji:"builtin"};for(var a in o)o.hasOwnProperty(a)&&r.tokenTypeOverrides[a]&&(o[a]=r.tokenTypeOverrides[a]);var s=/^([*\-_])(?:\s*\1){2,}\s*$/,A=/^(?:[*\-+]|^[0-9]+([.)]))\s+/,l=/^\[(x| )\](?=\s)/i,c=r.allowAtxHeaderWithoutSpace?/^(#+)/:/^(#+)(?: |$)/,u=/^ {0,3}(?:\={1,}|-{2,})\s*$/,h=/^[^#!\[\]*_\\<>` "'(~:]+/,d=/^(~~~+|```+)[ \t]*([\w\/+#-]*)[^\n`]*$/,f=/^\s*\[[^\]]+?\]:.*$/,p=/[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E42\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC9\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDF3C-\uDF3E]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]/;function g(t,e,r){return e.f=e.inline=r,r(t,e)}function m(t,e,r){return e.f=e.block=r,r(t,e)}function v(e){if(e.linkTitle=!1,e.linkHref=!1,e.linkText=!1,e.em=!1,e.strong=!1,e.strikethrough=!1,e.quote=0,e.indentedCode=!1,e.f==w){var r=i;if(!r){var o=t.innerMode(n,e.htmlState);r="xml"==o.mode.name&&null===o.state.tagStart&&!o.state.context&&o.state.tokenize.isInText}r&&(e.f=x,e.block=y,e.htmlState=null)}return e.trailingSpace=0,e.trailingSpaceNewLine=!1,e.prevLine=e.thisLine,e.thisLine={stream:null},null}function y(n,i){var a,h=n.column()===i.indentation,p=!(a=i.prevLine.stream)||!/\S/.test(a.string),m=i.indentedCode,v=i.prevLine.hr,y=!1!==i.list,w=(i.listStack[i.listStack.length-1]||0)+3;i.indentedCode=!1;var B=i.indentation;if(null===i.indentationDiff&&(i.indentationDiff=i.indentation,y)){for(i.list=null;B<i.listStack[i.listStack.length-1];)i.listStack.pop(),i.listStack.length?i.indentation=i.listStack[i.listStack.length-1]:i.list=!1;!1!==i.list&&(i.indentationDiff=B-i.listStack[i.listStack.length-1])}var x=!(p||v||i.prevLine.header||y&&m||i.prevLine.fencedCodeEnd),E=(!1===i.list||v||p)&&i.indentation<=w&&n.match(s),S=null;if(i.indentationDiff>=4&&(m||i.prevLine.fencedCodeEnd||i.prevLine.header||p))return n.skipToEnd(),i.indentedCode=!0,o.code;if(n.eatSpace())return null;if(h&&i.indentation<=w&&(S=n.match(c))&&S[1].length<=6)return i.quote=0,i.header=S[1].length,i.thisLine.header=!0,r.highlightFormatting&&(i.formatting="header"),i.f=i.inline,C(i);if(i.indentation<=w&&n.eat(">"))return i.quote=h?1:i.quote+1,r.highlightFormatting&&(i.formatting="quote"),n.eatSpace(),C(i);if(!E&&!i.setext&&h&&i.indentation<=w&&(S=n.match(A))){var k=S[1]?"ol":"ul";return i.indentation=B+n.current().length,i.list=!0,i.quote=0,i.listStack.push(i.indentation),i.em=!1,i.strong=!1,i.code=!1,i.strikethrough=!1,r.taskLists&&n.match(l,!1)&&(i.taskList=!0),i.f=i.inline,r.highlightFormatting&&(i.formatting=["list","list-"+k]),C(i)}return h&&i.indentation<=w&&(S=n.match(d,!0))?(i.quote=0,i.fencedEndRE=new RegExp(S[1]+"+ *$"),i.localMode=r.fencedCodeBlockHighlighting&&function(r){if(t.findModeByName){var n=t.findModeByName(r);n&&(r=n.mime||n.mimes[0])}var i=t.getMode(e,r);return"null"==i.name?null:i}(S[2]||r.fencedCodeBlockDefaultMode),i.localMode&&(i.localState=t.startState(i.localMode)),i.f=i.block=b,r.highlightFormatting&&(i.formatting="code-block"),i.code=-1,C(i)):i.setext||!(x&&y||i.quote||!1!==i.list||i.code||E||f.test(n.string))&&(S=n.lookAhead(1))&&(S=S.match(u))?(i.setext?(i.header=i.setext,i.setext=0,n.skipToEnd(),r.highlightFormatting&&(i.formatting="header")):(i.header="="==S[0].charAt(0)?1:2,i.setext=i.header),i.thisLine.header=!0,i.f=i.inline,C(i)):E?(n.skipToEnd(),i.hr=!0,i.thisLine.hr=!0,o.hr):"["===n.peek()?g(n,i,T):g(n,i,i.inline)}function w(e,r){var o=n.token(e,r.htmlState);if(!i){var a=t.innerMode(n,r.htmlState);("xml"==a.mode.name&&null===a.state.tagStart&&!a.state.context&&a.state.tokenize.isInText||r.md_inside&&e.current().indexOf(">")>-1)&&(r.f=x,r.block=y,r.htmlState=null)}return o}function b(t,e){var n,i=e.listStack[e.listStack.length-1]||0,a=e.indentation<i,s=i+3;return e.fencedEndRE&&e.indentation<=s&&(a||t.match(e.fencedEndRE))?(r.highlightFormatting&&(e.formatting="code-block"),a||(n=C(e)),e.localMode=e.localState=null,e.block=y,e.f=x,e.fencedEndRE=null,e.code=0,e.thisLine.fencedCodeEnd=!0,a?m(t,e,e.block):n):e.localMode?e.localMode.token(t,e.localState):(t.skipToEnd(),o.code)}function C(t){var e=[];if(t.formatting){e.push(o.formatting),"string"==typeof t.formatting&&(t.formatting=[t.formatting]);for(var n=0;n<t.formatting.length;n++)e.push(o.formatting+"-"+t.formatting[n]),"header"===t.formatting[n]&&e.push(o.formatting+"-"+t.formatting[n]+"-"+t.header),"quote"===t.formatting[n]&&(!r.maxBlockquoteDepth||r.maxBlockquoteDepth>=t.quote?e.push(o.formatting+"-"+t.formatting[n]+"-"+t.quote):e.push("error"))}if(t.taskOpen)return e.push("meta"),e.length?e.join(" "):null;if(t.taskClosed)return e.push("property"),e.length?e.join(" "):null;if(t.linkHref?e.push(o.linkHref,"url"):(t.strong&&e.push(o.strong),t.em&&e.push(o.em),t.strikethrough&&e.push(o.strikethrough),t.emoji&&e.push(o.emoji),t.linkText&&e.push(o.linkText),t.code&&e.push(o.code),t.image&&e.push(o.image),t.imageAltText&&e.push(o.imageAltText,"link"),t.imageMarker&&e.push(o.imageMarker)),t.header&&e.push(o.header,o.header+"-"+t.header),t.quote&&(e.push(o.quote),!r.maxBlockquoteDepth||r.maxBlockquoteDepth>=t.quote?e.push(o.quote+"-"+t.quote):e.push(o.quote+"-"+r.maxBlockquoteDepth)),!1!==t.list){var i=(t.listStack.length-1)%3;i?1===i?e.push(o.list2):e.push(o.list3):e.push(o.list1)}return t.trailingSpaceNewLine?e.push("trailing-space-new-line"):t.trailingSpace&&e.push("trailing-space-"+(t.trailingSpace%2?"a":"b")),e.length?e.join(" "):null}function B(t,e){if(t.match(h,!0))return C(e)}function x(e,i){var a=i.text(e,i);if(void 0!==a)return a;if(i.list)return i.list=null,C(i);if(i.taskList)return" "===e.match(l,!0)[1]?i.taskOpen=!0:i.taskClosed=!0,r.highlightFormatting&&(i.formatting="task"),i.taskList=!1,C(i);if(i.taskOpen=!1,i.taskClosed=!1,i.header&&e.match(/^#+$/,!0))return r.highlightFormatting&&(i.formatting="header"),C(i);var s=e.next();if(i.linkTitle){i.linkTitle=!1;var A=s;"("===s&&(A=")");var c="^\\s*(?:[^"+(A=(A+"").replace(/([.?*+^\[\]\\(){}|-])/g,"\\$1"))+"\\\\]+|\\\\\\\\|\\\\.)"+A;if(e.match(new RegExp(c),!0))return o.linkHref}if("`"===s){var u=i.formatting;r.highlightFormatting&&(i.formatting="code"),e.eatWhile("`");var h=e.current().length;if(0!=i.code||i.quote&&1!=h){if(h==i.code){var d=C(i);return i.code=0,d}return i.formatting=u,C(i)}return i.code=h,C(i)}if(i.code)return C(i);if("\\"===s&&(e.next(),r.highlightFormatting)){var f=C(i),g=o.formatting+"-escape";return f?f+" "+g:g}if("!"===s&&e.match(/\[[^\]]*\] ?(?:\(|\[)/,!1))return i.imageMarker=!0,i.image=!0,r.highlightFormatting&&(i.formatting="image"),C(i);if("["===s&&i.imageMarker&&e.match(/[^\]]*\](\(.*?\)| ?\[.*?\])/,!1))return i.imageMarker=!1,i.imageAltText=!0,r.highlightFormatting&&(i.formatting="image"),C(i);if("]"===s&&i.imageAltText){r.highlightFormatting&&(i.formatting="image");var f=C(i);return i.imageAltText=!1,i.image=!1,i.inline=i.f=S,f}if("["===s&&!i.image)return i.linkText&&e.match(/^.*?\]/)||(i.linkText=!0,r.highlightFormatting&&(i.formatting="link")),C(i);if("]"===s&&i.linkText){r.highlightFormatting&&(i.formatting="link");var f=C(i);return i.linkText=!1,i.inline=i.f=e.match(/\(.*?\)| ?\[.*?\]/,!1)?S:x,f}if("<"===s&&e.match(/^(https?|ftps?):\/\/(?:[^\\>]|\\.)+>/,!1))return i.f=i.inline=E,r.highlightFormatting&&(i.formatting="link"),(f=C(i))?f+=" ":f="",f+o.linkInline;if("<"===s&&e.match(/^[^> \\]+@(?:[^\\>]|\\.)+>/,!1))return i.f=i.inline=E,r.highlightFormatting&&(i.formatting="link"),(f=C(i))?f+=" ":f="",f+o.linkEmail;if(r.xml&&"<"===s&&e.match(/^(!--|\?|!\[CDATA\[|[a-z][a-z0-9-]*(?:\s+[a-z_:.\-]+(?:\s*=\s*[^>]+)?)*\s*(?:>|$))/i,!1)){var v=e.string.indexOf(">",e.pos);if(-1!=v){var y=e.string.substring(e.start,v);/markdown\s*=\s*('|"){0,1}1('|"){0,1}/.test(y)&&(i.md_inside=!0)}return e.backUp(1),i.htmlState=t.startState(n),m(e,i,w)}if(r.xml&&"<"===s&&e.match(/^\/\w*?>/))return i.md_inside=!1,"tag";if("*"===s||"_"===s){for(var b=1,B=1==e.pos?" ":e.string.charAt(e.pos-2);b<3&&e.eat(s);)b++;var k=e.peek()||" ",T=!/\s/.test(k)&&(!p.test(k)||/\s/.test(B)||p.test(B)),F=!/\s/.test(B)&&(!p.test(B)||/\s/.test(k)||p.test(k)),L=null,I=null;if(b%2&&(i.em||!T||"*"!==s&&F&&!p.test(B)?i.em!=s||!F||"*"!==s&&T&&!p.test(k)||(L=!1):L=!0),b>1&&(i.strong||!T||"*"!==s&&F&&!p.test(B)?i.strong!=s||!F||"*"!==s&&T&&!p.test(k)||(I=!1):I=!0),null!=I||null!=L)return r.highlightFormatting&&(i.formatting=null==L?"strong":null==I?"em":"strong em"),!0===L&&(i.em=s),!0===I&&(i.strong=s),d=C(i),!1===L&&(i.em=!1),!1===I&&(i.strong=!1),d}else if(" "===s&&(e.eat("*")||e.eat("_"))){if(" "===e.peek())return C(i);e.backUp(1)}if(r.strikethrough)if("~"===s&&e.eatWhile(s)){if(i.strikethrough)return r.highlightFormatting&&(i.formatting="strikethrough"),d=C(i),i.strikethrough=!1,d;if(e.match(/^[^\s]/,!1))return i.strikethrough=!0,r.highlightFormatting&&(i.formatting="strikethrough"),C(i)}else if(" "===s&&e.match(/^~~/,!0)){if(" "===e.peek())return C(i);e.backUp(2)}if(r.emoji&&":"===s&&e.match(/^(?:[a-z_\d+][a-z_\d+-]*|\-[a-z_\d+][a-z_\d+-]*):/)){i.emoji=!0,r.highlightFormatting&&(i.formatting="emoji");var _=C(i);return i.emoji=!1,_}return" "===s&&(e.match(/^ +$/,!1)?i.trailingSpace++:i.trailingSpace&&(i.trailingSpaceNewLine=!0)),C(i)}function E(t,e){if(">"===t.next()){e.f=e.inline=x,r.highlightFormatting&&(e.formatting="link");var n=C(e);return n?n+=" ":n="",n+o.linkInline}return t.match(/^[^>]+/,!0),o.linkInline}function S(t,e){if(t.eatSpace())return null;var n,i=t.next();return"("===i||"["===i?(e.f=e.inline=(n="("===i?")":"]",function(t,e){if(t.next()===n){e.f=e.inline=x,r.highlightFormatting&&(e.formatting="link-string");var i=C(e);return e.linkHref=!1,i}return t.match(k[n]),e.linkHref=!0,C(e)}),r.highlightFormatting&&(e.formatting="link-string"),e.linkHref=!0,C(e)):"error"}var k={")":/^(?:[^\\\(\)]|\\.|\((?:[^\\\(\)]|\\.)*\))*?(?=\))/,"]":/^(?:[^\\\[\]]|\\.|\[(?:[^\\\[\]]|\\.)*\])*?(?=\])/};function T(t,e){return t.match(/^([^\]\\]|\\.)*\]:/,!1)?(e.f=F,t.next(),r.highlightFormatting&&(e.formatting="link"),e.linkText=!0,C(e)):g(t,e,x)}function F(t,e){if(t.match(/^\]:/,!0)){e.f=e.inline=L,r.highlightFormatting&&(e.formatting="link");var n=C(e);return e.linkText=!1,n}return t.match(/^([^\]\\]|\\.)+/,!0),o.linkText}function L(t,e){return t.eatSpace()?null:(t.match(/^[^\s]+/,!0),void 0===t.peek()?e.linkTitle=!0:t.match(/^(?:\s+(?:"(?:[^"\\]|\\\\|\\.)+"|'(?:[^'\\]|\\\\|\\.)+'|\((?:[^)\\]|\\\\|\\.)+\)))?/,!0),e.f=e.inline=x,o.linkHref+" url")}var I={startState:function(){return{f:y,prevLine:{stream:null},thisLine:{stream:null},block:y,htmlState:null,indentation:0,inline:x,text:B,formatting:!1,linkText:!1,linkHref:!1,linkTitle:!1,code:0,em:!1,strong:!1,header:0,setext:0,hr:!1,taskList:!1,list:!1,listStack:[],quote:0,trailingSpace:0,trailingSpaceNewLine:!1,strikethrough:!1,emoji:!1,fencedEndRE:null}},copyState:function(e){return{f:e.f,prevLine:e.prevLine,thisLine:e.thisLine,block:e.block,htmlState:e.htmlState&&t.copyState(n,e.htmlState),indentation:e.indentation,localMode:e.localMode,localState:e.localMode?t.copyState(e.localMode,e.localState):null,inline:e.inline,text:e.text,formatting:!1,linkText:e.linkText,linkTitle:e.linkTitle,linkHref:e.linkHref,code:e.code,em:e.em,strong:e.strong,strikethrough:e.strikethrough,emoji:e.emoji,header:e.header,setext:e.setext,hr:e.hr,taskList:e.taskList,list:e.list,listStack:e.listStack.slice(0),quote:e.quote,indentedCode:e.indentedCode,trailingSpace:e.trailingSpace,trailingSpaceNewLine:e.trailingSpaceNewLine,md_inside:e.md_inside,fencedEndRE:e.fencedEndRE}},token:function(t,e){if(e.formatting=!1,t!=e.thisLine.stream){if(e.header=0,e.hr=!1,t.match(/^\s*$/,!0))return v(e),null;if(e.prevLine=e.thisLine,e.thisLine={stream:t},e.taskList=!1,e.trailingSpace=0,e.trailingSpaceNewLine=!1,!e.localState&&(e.f=e.block,e.f!=w)){var r=t.match(/^\s*/,!0)[0].replace(/\t/g," ").length;if(e.indentation=r,e.indentationDiff=null,r>0)return null}}return e.f(t,e)},innerMode:function(t){return t.block==w?{state:t.htmlState,mode:n}:t.localState?{state:t.localState,mode:t.localMode}:{state:t,mode:I}},indent:function(e,r,i){return e.block==w&&n.indent?n.indent(e.htmlState,r,i):e.localState&&e.localMode.indent?e.localMode.indent(e.localState,r,i):t.Pass},blankLine:v,getType:C,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",closeBrackets:"()[]{}''\"\"``",fold:"markdown"};return I}),"xml"),t.defineMIME("text/markdown","markdown"),t.defineMIME("text/x-markdown","markdown")}(r(/*! ../../lib/codemirror */"VrN/"),r(/*! ../xml/xml */"1eCo"),r(/*! ../meta */"8EBN"))},loD1:
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/line.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){e.containStroke=function(t,e,r,n,i,o,a){if(0===i)return!1;var s=i,A=0;if(a>e+s&&a>n+s||a<e-s&&a<n-s||o>t+s&&o>r+s||o<t-s&&o<r-s)return!1;if(t===r)return Math.abs(o-t)<=s/2;var l=(A=(e-n)/(t-r))*o-a+(t*n-r*e)/(t-r);return l*l/(A*A+1)<=s/2*s/2}},mFDi:
|
|
|
/*!*******************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/core/BoundingRect.js ***!
|
|
|
\*******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n,i,o,a,s=r(/*! ./vector */"QBsz"),A=r(/*! ./matrix */"Fofx"),l=s.applyTransform,c=Math.min,u=Math.max;function h(t,e,r,n){r<0&&(t+=r,r=-r),n<0&&(e+=n,n=-n),this.x=t,this.y=e,this.width=r,this.height=n}h.prototype={constructor:h,union:function(t){var e=c(t.x,this.x),r=c(t.y,this.y);this.width=u(t.x+t.width,this.x+this.width)-e,this.height=u(t.y+t.height,this.y+this.height)-r,this.x=e,this.y=r},applyTransform:(n=[],i=[],o=[],a=[],function(t){if(t){n[0]=o[0]=this.x,n[1]=a[1]=this.y,i[0]=a[0]=this.x+this.width,i[1]=o[1]=this.y+this.height,l(n,n,t),l(i,i,t),l(o,o,t),l(a,a,t),this.x=c(n[0],i[0],o[0],a[0]),this.y=c(n[1],i[1],o[1],a[1]);var e=u(n[0],i[0],o[0],a[0]),r=u(n[1],i[1],o[1],a[1]);this.width=e-this.x,this.height=r-this.y}}),calculateTransform:function(t){var e=this,r=t.width/e.width,n=t.height/e.height,i=A.create();return A.translate(i,i,[-e.x,-e.y]),A.scale(i,i,[r,n]),A.translate(i,i,[t.x,t.y]),i},intersect:function(t){if(!t)return!1;t instanceof h||(t=h.create(t));var e=this,r=e.x,n=e.x+e.width,i=e.y,o=e.y+e.height,a=t.x,s=t.x+t.width,A=t.y,l=t.y+t.height;return!(n<a||s<r||o<A||l<i)},contain:function(t,e){return t>=this.x&&t<=this.x+this.width&&e>=this.y&&e<=this.y+this.height},clone:function(){return new h(this.x,this.y,this.width,this.height)},copy:function(t){this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height},plain:function(){return{x:this.x,y:this.y,width:this.width,height:this.height}}},h.create=function(t){return new h(t.x,t.y,t.width,t.height)};var d=h;t.exports=d},mLcG:
|
|
|
/*!*********************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/animation/requestAnimationFrame.js ***!
|
|
|
\*********************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r="undefined"!=typeof window&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){setTimeout(t,16)};t.exports=r},n1HI:
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/contain/arc.js ***!
|
|
|
\*************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./util */"hX1E").normalizeRadian,i=2*Math.PI;e.containStroke=function(t,e,r,o,a,s,A,l,c){if(0===A)return!1;var u=A;l-=t,c-=e;var h=Math.sqrt(l*l+c*c);if(h-u>r||h+u<r)return!1;if(Math.abs(o-a)%i<1e-4)return!0;if(s){var d=o;o=n(a),a=n(d)}else o=n(o),a=n(a);o>a&&(a+=i);var f=Math.atan2(c,l);return f<0&&(f+=i),f>=o&&f<=a||f+i>=o&&f+i<=a}},n6Mw:
|
|
|
/*!****************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/svg/helper/ClippathManager.js ***!
|
|
|
\****************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./Definable */"SrGk"),i=r(/*! ../../core/util */"bYtY"),o=r(/*! ../../core/matrix */"Fofx");function a(t,e){n.call(this,t,e,"clipPath","__clippath_in_use__")}i.inherits(a,n),a.prototype.update=function(t){var e=this.getSvgElement(t);e&&this.updateDom(e,t.__clipPaths,!1);var r=this.getTextSvgElement(t);r&&this.updateDom(r,t.__clipPaths,!0),this.markUsed(t)},a.prototype.updateDom=function(t,e,r){if(e&&e.length>0){var n,i,a=this.getDefs(!0),s=e[0],A=r?"_textDom":"_dom";s[A]?(i=s[A].getAttribute("id"),n=s[A],a.contains(n)||a.appendChild(n)):(i="zr"+this._zrId+"-clip-"+this.nextId,++this.nextId,(n=this.createElement("clipPath")).setAttribute("id",i),a.appendChild(n),s[A]=n);var l=this.getSvgProxy(s);if(s.transform&&s.parent.invTransform&&!r){var c=Array.prototype.slice.call(s.transform);o.mul(s.transform,s.parent.invTransform,s.transform),l.brush(s),s.transform=c}else l.brush(s);var u=this.getSvgElement(s);n.innerHTML="",n.appendChild(u.cloneNode()),t.setAttribute("clip-path","url(#"+i+")"),e.length>1&&this.updateDom(n,e.slice(1),r)}else t&&t.setAttribute("clip-path","none")},a.prototype.markUsed=function(t){var e=this;t.__clipPaths&&i.each(t.__clipPaths,(function(t){t._dom&&n.prototype.markUsed.call(e,t._dom),t._textDom&&n.prototype.markUsed.call(e,t._textDom)}))};var s=a;t.exports=s},n6Qo:
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/Footer/index.js + 2 modules ***!
|
|
|
\**************************************************************/
|
|
|
/*! exports provided: default, FooterComponents */
|
|
|
/*! exports used: FooterComponents, default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/Cell/index.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/context/TableContext.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r.d(e,"a",(function(){return a}));var n=r("q1tI"),i=r("biw7"),o=r("fyJ8");e.b=function(t){var e=t.children,r=n.useContext(i.a).prefixCls;return n.createElement("tfoot",{className:"".concat(r,"-summary")},e)};var a={Cell:function(t){var e=t.className,r=t.index,a=t.children,s=t.colSpan,A=t.rowSpan,l=n.useContext(i.a),c=l.prefixCls,u=l.fixedInfoList[r];return n.createElement(o.a,Object.assign({className:e,index:r,component:"td",prefixCls:c,record:null,dataIndex:null,render:function(){return{children:a,props:{colSpan:s,rowSpan:A}}}},u))},Row:function(t){return n.createElement("tr",Object.assign({},t))}}},nCxF:
|
|
|
/*!*****************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/smoothBezier.js ***!
|
|
|
\*****************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../../core/vector */"QBsz"),i=n.min,o=n.max,a=n.scale,s=n.distance,A=n.add,l=n.clone,c=n.sub;t.exports=function(t,e,r,n){var u,h,d,f,p=[],g=[],m=[],v=[];if(n){d=[1/0,1/0],f=[-1/0,-1/0];for(var y=0,w=t.length;y<w;y++)i(d,d,t[y]),o(f,f,t[y]);i(d,d,n[0]),o(f,f,n[1])}for(y=0,w=t.length;y<w;y++){var b=t[y];if(r)u=t[y?y-1:w-1],h=t[(y+1)%w];else{if(0===y||y===w-1){p.push(l(t[y]));continue}u=t[y-1],h=t[y+1]}c(g,h,u),a(g,g,e);var C=s(b,u),B=s(b,h),x=C+B;0!==x&&(C/=x,B/=x),a(m,g,-C),a(v,g,B);var E=A([],b,m),S=A([],b,v);n&&(o(E,E,d),i(E,E,f),o(S,S,d),i(S,S,f)),p.push(E),p.push(S)}return r&&p.push(p.shift()),p}},nPnh:
|
|
|
/*!*********************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/subPixelOptimize.js ***!
|
|
|
\*********************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){var r=Math.round;function n(t,e,n){if(!e)return t;var i=r(2*t);return(i+r(e))%2==0?i/2:(i+(n?1:-1))/2}e.subPixelOptimizeLine=function(t,e,i){if(e){var o=e.x1,a=e.x2,s=e.y1,A=e.y2;t.x1=o,t.x2=a,t.y1=s,t.y2=A;var l=i&&i.lineWidth;l&&(r(2*o)===r(2*a)&&(t.x1=t.x2=n(o,l,!0)),r(2*s)===r(2*A)&&(t.y1=t.y2=n(s,l,!0)))}},e.subPixelOptimizeRect=function(t,e,r){if(e){var i=e.x,o=e.y,a=e.width,s=e.height;t.x=i,t.y=o,t.width=a,t.height=s;var A=r&&r.lineWidth;A&&(t.x=n(i,A,!0),t.y=n(o,A,!0),t.width=Math.max(n(i+a,A,!1)-t.x,0===a?0:1),t.height=Math.max(n(o+s,A,!1)-t.y,0===s?0:1))}},e.subPixelOptimize=n},nVVt:
|
|
|
/*!****************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/mode.js ***!
|
|
|
\****************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){t.exports={MODE_NUMBER:1,MODE_ALPHA_NUM:2,MODE_8BIT_BYTE:4,MODE_KANJI:8}},ni6a:
|
|
|
/*!************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/mixin/RectText.js ***!
|
|
|
\************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../helper/text */"pzxd"),i=r(/*! ../../core/BoundingRect */"mFDi"),o=r(/*! ../constant */"gut8").WILL_BE_RESTORED,a=new i,s=function(){};s.prototype={constructor:s,drawRectText:function(t,e){var r=this.style;e=r.textRect||e,this.__dirty&&n.normalizeTextStyle(r,!0);var i=r.text;if(null!=i&&(i+=""),n.needDrawText(i,r)){t.save();var s=this.transform;r.transformText?this.setTransform(t):s&&(a.copy(e),a.applyTransform(s),e=a),n.renderText(this,t,i,r,e,o),t.restore()}}};var A=s;t.exports=A},osHv:
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/codemirror/addon/fold/xml-fold.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){!function(t){"use strict";var e=t.Pos;function r(t,e){return t.line-e.line||t.ch-e.ch}var n="A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",i=new RegExp("<(/?)(["+n+"]["+n+"-:.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*)","g");function o(t,e,r,n){this.line=e,this.ch=r,this.cm=t,this.text=t.getLine(e),this.min=n?Math.max(n.from,t.firstLine()):t.firstLine(),this.max=n?Math.min(n.to-1,t.lastLine()):t.lastLine()}function a(t,r){var n=t.cm.getTokenTypeAt(e(t.line,r));return n&&/\btag\b/.test(n)}function s(t){if(!(t.line>=t.max))return t.ch=0,t.text=t.cm.getLine(++t.line),!0}function A(t){if(!(t.line<=t.min))return t.text=t.cm.getLine(--t.line),t.ch=t.text.length,!0}function l(t){for(;;){var e=t.text.indexOf(">",t.ch);if(-1==e){if(s(t))continue;return}if(a(t,e+1)){var r=t.text.lastIndexOf("/",e),n=r>-1&&!/\S/.test(t.text.slice(r+1,e));return t.ch=e+1,n?"selfClose":"regular"}t.ch=e+1}}function c(t){for(;;){var e=t.ch?t.text.lastIndexOf("<",t.ch-1):-1;if(-1==e){if(A(t))continue;return}if(a(t,e+1)){i.lastIndex=e,t.ch=e;var r=i.exec(t.text);if(r&&r.index==e)return r}else t.ch=e}}function u(t){for(;;){i.lastIndex=t.ch;var e=i.exec(t.text);if(!e){if(s(t))continue;return}if(a(t,e.index+1))return t.ch=e.index+e[0].length,e;t.ch=e.index+1}}function h(t){for(;;){var e=t.ch?t.text.lastIndexOf(">",t.ch-1):-1;if(-1==e){if(A(t))continue;return}if(a(t,e+1)){var r=t.text.lastIndexOf("/",e),n=r>-1&&!/\S/.test(t.text.slice(r+1,e));return t.ch=e+1,n?"selfClose":"regular"}t.ch=e}}function d(t,r){for(var n=[];;){var i,o=u(t),a=t.line,s=t.ch-(o?o[0].length:0);if(!o||!(i=l(t)))return;if("selfClose"!=i)if(o[1]){for(var A=n.length-1;A>=0;--A)if(n[A]==o[2]){n.length=A;break}if(A<0&&(!r||r==o[2]))return{tag:o[2],from:e(a,s),to:e(t.line,t.ch)}}else n.push(o[2])}}function f(t,r){for(var n=[];;){var i=h(t);if(!i)return;if("selfClose"!=i){var o=t.line,a=t.ch,s=c(t);if(!s)return;if(s[1])n.push(s[2]);else{for(var A=n.length-1;A>=0;--A)if(n[A]==s[2]){n.length=A;break}if(A<0&&(!r||r==s[2]))return{tag:s[2],from:e(t.line,t.ch),to:e(o,a)}}}else c(t)}}t.registerHelper("fold","xml",(function(t,n){for(var i=new o(t,n.line,0);;){var a=u(i);if(!a||i.line!=n.line)return;var s=l(i);if(!s)return;if(!a[1]&&"selfClose"!=s){var A=e(i.line,i.ch),c=d(i,a[2]);return c&&r(c.from,A)>0?{from:A,to:c.from}:null}}})),t.findMatchingTag=function(t,n,i){var a=new o(t,n.line,n.ch,i);if(-1!=a.text.indexOf(">")||-1!=a.text.indexOf("<")){var s=l(a),A=s&&e(a.line,a.ch),u=s&&c(a);if(s&&u&&!(r(a,n)>0)){var h={from:e(a.line,a.ch),to:A,tag:u[2]};return"selfClose"==s?{open:h,close:null,at:"open"}:u[1]?{open:f(a,u[2]),close:h,at:"close"}:{open:h,close:d(a=new o(t,A.line,A.ch,i),u[2]),at:"open"}}}},t.findEnclosingTag=function(t,e,r,n){for(var i=new o(t,e.line,e.ch,r);;){var a=f(i,n);if(!a)break;var s=d(new o(t,e.line,e.ch,r),a.tag);if(s)return{open:a,close:s}}},t.scanForClosingTag=function(t,e,r,n){return d(new o(t,e.line,e.ch,n?{from:0,to:n}:null),r)}}(r(/*! ../../lib/codemirror */"VrN/"))},p5ED:
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./src/components/PreviewAll/index.tsx ***!
|
|
|
\*********************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";r(/*! antd/es/button/style */"+L6B");var n=r(/*! antd/es/button */"2/Rp"),i=(r(/*! antd/es/tooltip/style */"5Dmo"),r(/*! antd/es/tooltip */"3S7+")),o=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2 */"k1fw"),a=r(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray */"tJVT"),s=r(/*! react */"q1tI"),A=r.n(s),l=r(/*! ./index.less?modules */"vHTk"),c=r.n(l),u=r(/*! @ant-design/icons */"yEEn"),h=r(/*! @/components/monaco-editor */"ZW9T"),d=r(/*! @/utils/util */"1vsH");e.a=function(t){var e=t.name,r=t.data,l=(t.theme,t.type),f=t.filename,p=t.monacoEditor,g=t.className,m=t.style,v=t.close,y=t.onClose,w=t.hasMask,b=Object(s.useState)("https://view.officeapps.live.com/op/view.aspx?src=http://testgs.educoder.net//rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBCZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--03541f6234b93d7ac3b2d84e7eb0e6594a952945/1.ppt"),C=Object(a.a)(b,2),B=(C[0],C[1],Object(s.useState)("")),x=Object(a.a)(B,2),E=(x[0],x[1]),S=Object(s.useRef)();f&&(p.filename=f),Object(s.useEffect)((function(){var t,e,r=null===(t=document.cookie)||void 0===t||null===(e=t.replace(/\s/g,""))||void 0===e?void 0:e.split(";");null==r||r.map((function(t){var e=t.split("=");"_educoder_session"===e[0]&&E(e[1])}))}),[]);var k=function(){r.startsWith("http")||r.startsWith("/")?T():Object(d.x)(f||"educoder",r,f)},T=function(){Object(d.v)(f||e,r)};return console.log("data:",r,"fileanme:",f," name:",e),A.a.createElement("div",{style:Object(o.a)({},m||{}),className:"".concat(w&&c.a.bgBlack," ").concat(l?c.a.wrp:"hide")},v&&A.a.createElement("div",{className:c.a.close,ref:S},A.a.createElement(i.a,{title:"点击下载此文件",getPopupContainer:function(){return S.current}},A.a.createElement("span",{onClick:T},A.a.createElement("i",{className:"icon-quxiaozhiding"}))),A.a.createElement(i.a,{title:"关闭",getPopupContainer:function(){return S.current}},A.a.createElement("span",{className:"",onClick:y},A.a.createElement("i",{className:"icon-guanbi1"})))),A.a.createElement("div",{className:"".concat(c.a[g]," ").concat(g," ").concat(c.a.monaco," ").concat("txt"===l?"show":"hide")},"txt"===l&&A.a.createElement(h.b,p)),"audio"===l&&A.a.createElement("audio",{src:"".concat(null!=r&&r.startsWith("/")||(null==r?void 0:r.indexOf("https://"))>-1?r:"data:audio/mp3;base64,").concat(r),autoPlay:!0}),"video"===l&&A.a.createElement(A.a.Fragment,null,null!=r&&r.startsWith("/")?A.a.createElement("video",{controls:!0,src:"".concat(r),autoPlay:!0}):A.a.createElement("video",{controls:!0,src:"data:video/mp4;base64,".concat(r),autoPlay:!0})),"html"===l&&A.a.createElement("iframe",{src:r+"&disposition=inline"}),"pdf"===l&&A.a.createElement("embed",{className:c.a.embed,src:r}),"pdfeditor"===l&&A.a.createElement("div",null,A.a.createElement("iframe",{src:"https://a1office.co/solutions/editor/pdf-editor/查重文档1-8839d79b81e8bda0d298ca058913ab88.pdf"}),A.a.createElement("div",{style:{position:"absolute",left:"1px",top:"1px",width:180,height:60,background:"#f9f9f9"}})),"image"===l&&A.a.createElement(A.a.Fragment,null,A.a.createElement("img",{src:"".concat(null!=r&&r.startsWith("/")||(null==r?void 0:r.indexOf("https://"))>-1?"":"data:image/png;base64,").concat(r)})),"other"===l&&A.a.createElement("div",null,A.a.createElement(n.a,{type:"primary",size:"large",onClick:k},A.a.createElement(u.a,null),"点击下载")),("download"===l||"office"===l)&&A.a.createElement(n.a,{type:"primary",size:"large",onClick:k},A.a.createElement(u.a,null),"点击下载"))}},"p77/":
|
|
|
/*!****************************************************!*\
|
|
|
!*** ./node_modules/codemirror/lib/codemirror.css ***!
|
|
|
\****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){},pzxd:
|
|
|
/*!*********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/helper/text.js ***!
|
|
|
\*********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../../core/util */"bYtY"),i=n.retrieve2,o=n.retrieve3,a=n.each,s=n.normalizeCssArray,A=n.isString,l=n.isObject,c=r(/*! ../../contain/text */"6GrX"),u=r(/*! ./roundRect */"VpOo"),h=r(/*! ./image */"Xnb7"),d=r(/*! ./fixShadow */"fW2E"),f=r(/*! ../constant */"gut8"),p=f.ContextCachedBy,g=f.WILL_BE_RESTORED,m=c.DEFAULT_FONT,v={left:1,right:1,center:1},y={top:1,bottom:1,middle:1},w=[["textShadowBlur","shadowBlur",0],["textShadowOffsetX","shadowOffsetX",0],["textShadowOffsetY","shadowOffsetY",0],["textShadowColor","shadowColor","transparent"]],b={},C={};function B(t){if(t){t.font=c.makeFont(t);var e=t.textAlign;"middle"===e&&(e="center"),t.textAlign=null==e||v[e]?e:"left";var r=t.textVerticalAlign||t.textBaseline;"center"===r&&(r="middle"),t.textVerticalAlign=null==r||y[r]?r:"top",t.textPadding&&(t.textPadding=s(t.textPadding))}}function x(t,e,r,n,i){if(r&&e.textRotation){var o=e.textOrigin;"center"===o?(n=r.width/2+r.x,i=r.height/2+r.y):o&&(n=o[0]+r.x,i=o[1]+r.y),t.translate(n,i),t.rotate(-e.textRotation),t.translate(-n,-i)}}function E(t,e,r,n,a,s,A,l){var c=n.rich[r.styleName]||{};c.text=r.text;var u=r.textVerticalAlign,h=s+a/2;"top"===u?h=s+r.height/2:"bottom"===u&&(h=s+a-r.height/2),!r.isLineHolder&&S(c)&&k(t,e,c,"right"===l?A-r.width:"center"===l?A-r.width/2:A,h-r.height/2,r.width,r.height);var d=r.textPadding;d&&(A=O(A,l,d),h-=r.height/2-d[2]-r.textHeight/2),L(e,"shadowBlur",o(c.textShadowBlur,n.textShadowBlur,0)),L(e,"shadowColor",c.textShadowColor||n.textShadowColor||"transparent"),L(e,"shadowOffsetX",o(c.textShadowOffsetX,n.textShadowOffsetX,0)),L(e,"shadowOffsetY",o(c.textShadowOffsetY,n.textShadowOffsetY,0)),L(e,"textAlign",l),L(e,"textBaseline","middle"),L(e,"font",r.font||m);var f=I(c.textStroke||n.textStroke,g),p=_(c.textFill||n.textFill),g=i(c.textStrokeWidth,n.textStrokeWidth);f&&(L(e,"lineWidth",g),L(e,"strokeStyle",f),e.strokeText(r.text,A,h)),p&&(L(e,"fillStyle",p),e.fillText(r.text,A,h))}function S(t){return!!(t.textBackgroundColor||t.textBorderWidth&&t.textBorderColor)}function k(t,e,r,n,i,o,a){var s=r.textBackgroundColor,c=r.textBorderWidth,d=r.textBorderColor,f=A(s);if(L(e,"shadowBlur",r.textBoxShadowBlur||0),L(e,"shadowColor",r.textBoxShadowColor||"transparent"),L(e,"shadowOffsetX",r.textBoxShadowOffsetX||0),L(e,"shadowOffsetY",r.textBoxShadowOffsetY||0),f||c&&d){e.beginPath();var p=r.textBorderRadius;p?u.buildPath(e,{x:n,y:i,width:o,height:a,r:p}):e.rect(n,i,o,a),e.closePath()}if(f)if(L(e,"fillStyle",s),null!=r.fillOpacity){var g=e.globalAlpha;e.globalAlpha=r.fillOpacity*r.opacity,e.fill(),e.globalAlpha=g}else e.fill();else if(l(s)){var m=s.image;(m=h.createOrUpdateImage(m,null,t,T,s))&&h.isImageReady(m)&&e.drawImage(m,n,i,o,a)}if(c&&d)if(L(e,"lineWidth",c),L(e,"strokeStyle",d),null!=r.strokeOpacity){g=e.globalAlpha;e.globalAlpha=r.strokeOpacity*r.opacity,e.stroke(),e.globalAlpha=g}else e.stroke()}function T(t,e){e.image=t}function F(t,e,r,n){var i=r.x||0,o=r.y||0,a=r.textAlign,s=r.textVerticalAlign;if(n){var A=r.textPosition;if(A instanceof Array)i=n.x+U(A[0],n.width),o=n.y+U(A[1],n.height);else{var l=e&&e.calculateTextPosition?e.calculateTextPosition(b,r,n):c.calculateTextPosition(b,r,n);i=l.x,o=l.y,a=a||l.textAlign,s=s||l.textVerticalAlign}var u=r.textOffset;u&&(i+=u[0],o+=u[1])}return(t=t||{}).baseX=i,t.baseY=o,t.textAlign=a,t.textVerticalAlign=s,t}function L(t,e,r){return t[e]=d(t,e,r),t[e]}function I(t,e){return null==t||e<=0||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function _(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function U(t,e){return"string"==typeof t?t.lastIndexOf("%")>=0?parseFloat(t)/100*e:parseFloat(t):t}function O(t,e,r){return"right"===e?t-r[1]:"center"===e?t+r[3]/2-r[1]/2:t+r[3]}e.normalizeTextStyle=function(t){return B(t),a(t.rich,B),t},e.renderText=function(t,e,r,n,i,o){n.rich?function(t,e,r,n,i,o){o!==g&&(e.__attrCachedBy=p.NONE);var a=t.__textCotentBlock;a&&!t.__dirtyText||(a=t.__textCotentBlock=c.parseRichText(r,n));!function(t,e,r,n,i){var o=r.width,a=r.outerWidth,s=r.outerHeight,A=n.textPadding,l=F(C,t,n,i),u=l.baseX,h=l.baseY,d=l.textAlign,f=l.textVerticalAlign;x(e,n,i,u,h);var p=c.adjustTextX(u,a,d),g=c.adjustTextY(h,s,f),m=p,v=g;A&&(m+=A[3],v+=A[0]);var y=m+o;S(n)&&k(t,e,n,p,g,a,s);for(var w=0;w<r.lines.length;w++){for(var b,B=r.lines[w],T=B.tokens,L=T.length,I=B.lineHeight,_=B.width,U=0,O=m,D=y,Q=L-1;U<L&&(!(b=T[U]).textAlign||"left"===b.textAlign);)E(t,e,b,n,I,v,O,"left"),_-=b.width,O+=b.width,U++;for(;Q>=0&&"right"===(b=T[Q]).textAlign;)E(t,e,b,n,I,v,D,"right"),_-=b.width,D-=b.width,Q--;for(O+=(o-(O-m)-(y-D)-_)/2;U<=Q;)b=T[U],E(t,e,b,n,I,v,O+b.width/2,"center"),O+=b.width,U++;v+=I}}(t,e,a,n,i)}(t,e,r,n,i,o):function(t,e,r,n,i,o){"use strict";var a,s=S(n),A=!1,l=e.__attrCachedBy===p.PLAIN_TEXT;o!==g?(o&&(a=o.style,A=!s&&l&&a),e.__attrCachedBy=s?p.NONE:p.PLAIN_TEXT):l&&(e.__attrCachedBy=p.NONE);var u=n.font||m;A&&u===(a.font||m)||(e.font=u);var h=t.__computedFont;t.__styleFont!==u&&(t.__styleFont=u,h=t.__computedFont=e.font);var f=n.textPadding,v=n.textLineHeight,y=t.__textCotentBlock;y&&!t.__dirtyText||(y=t.__textCotentBlock=c.parsePlainText(r,h,f,v,n.truncate));var b=y.outerHeight,B=y.lines,E=y.lineHeight,T=F(C,t,n,i),L=T.baseX,U=T.baseY,D=T.textAlign||"left",Q=T.textVerticalAlign;x(e,n,i,L,U);var M=c.adjustTextY(U,b,Q),R=L,P=M;if(s||f){var H=c.getWidth(r,h);f&&(H+=f[1]+f[3]);var N=c.adjustTextX(L,H,D);s&&k(t,e,n,N,M,H,b),f&&(R=O(L,D,f),P+=f[0])}e.textAlign=D,e.textBaseline="middle",e.globalAlpha=n.opacity||1;for(var K=0;K<w.length;K++){var j=w[K],G=j[0],V=j[1],z=n[G];A&&z===a[G]||(e[V]=d(e,V,z||j[2]))}P+=E/2;var W=n.textStrokeWidth,Y=A?a.textStrokeWidth:null,X=!A||W!==Y,q=!A||X||n.textStroke!==a.textStroke,J=I(n.textStroke,W),Z=_(n.textFill);J&&(X&&(e.lineWidth=W),q&&(e.strokeStyle=J));Z&&(A&&n.textFill===a.textFill||(e.fillStyle=Z));if(1===B.length)J&&e.strokeText(B[0],R,P),Z&&e.fillText(B[0],R,P);else for(K=0;K<B.length;K++)J&&e.strokeText(B[K],R,P),Z&&e.fillText(B[K],R,P),P+=E}(t,e,r,n,i,o)},e.getBoxPosition=F,e.getStroke=I,e.getFill=_,e.parsePercent=U,e.needDrawText=function(t,e){return null!=t&&(t||e.textBackgroundColor||e.textBorderWidth&&e.textBorderColor||e.textPadding)}},qH13:
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/vml/graphic.js ***!
|
|
|
\*************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../core/env */"ItGF"),i=r(/*! ../core/vector */"QBsz").applyTransform,o=r(/*! ../core/BoundingRect */"mFDi"),a=r(/*! ../tool/color */"Qe9p"),s=r(/*! ../contain/text */"6GrX"),A=r(/*! ../graphic/helper/text */"pzxd"),l=r(/*! ../graphic/mixin/RectText */"ni6a"),c=r(/*! ../graphic/Displayable */"Gev7"),u=r(/*! ../graphic/Image */"Dagg"),h=r(/*! ../graphic/Text */"dqUG"),d=r(/*! ../graphic/Path */"y+Vt"),f=r(/*! ../core/PathProxy */"IMiH"),p=r(/*! ../graphic/Gradient */"QuXc"),g=r(/*! ./core */"06Qe"),m=f.CMD,v=Math.round,y=Math.sqrt,w=Math.abs,b=Math.cos,C=Math.sin,B=Math.max;if(!n.canvasSupported){var x=21600,E=x/2,S=function(t){t.style.cssText="position:absolute;left:0;top:0;width:1px;height:1px;",t.coordsize=x+","+x,t.coordorigin="0,0"},k=function(t,e,r){return"rgb("+[t,e,r].join(",")+")"},T=function(t,e){e&&t&&e.parentNode!==t&&t.appendChild(e)},F=function(t,e){e&&t&&e.parentNode===t&&t.removeChild(e)},L=function(t,e,r){return 1e5*(parseFloat(t)||0)+1e3*(parseFloat(e)||0)+r},I=A.parsePercent,_=function(t,e,r){var n=a.parse(e);r=+r,isNaN(r)&&(r=1),n&&(t.color=k(n[0],n[1],n[2]),t.opacity=r*n[3])},U=function(t,e,r,n){var o="fill"===e,s=t.getElementsByTagName(e)[0];null!=r[e]&&"none"!==r[e]&&(o||!o&&r.lineWidth)?(t[o?"filled":"stroked"]="true",r[e]instanceof p&&F(t,s),s||(s=g.createNode(e)),o?function(t,e,r){var n,o,s=e.fill;if(null!=s)if(s instanceof p){var A,l=0,c=[0,0],u=0,h=1,d=r.getBoundingRect(),f=d.width,g=d.height;if("linear"===s.type){A="gradient";var m=r.transform,v=[s.x*f,s.y*g],y=[s.x2*f,s.y2*g];m&&(i(v,v,m),i(y,y,m));var w=y[0]-v[0],b=y[1]-v[1];(l=180*Math.atan2(w,b)/Math.PI)<0&&(l+=360),l<1e-6&&(l=0)}else{A="gradientradial";v=[s.x*f,s.y*g],m=r.transform;var C=r.scale,E=f,S=g;c=[(v[0]-d.x)/E,(v[1]-d.y)/S],m&&i(v,v,m),E/=C[0]*x,S/=C[1]*x;var T=B(E,S);u=0/T,h=2*s.r/T-u}var F=s.colorStops.slice();F.sort((function(t,e){return t.offset-e.offset}));for(var L=F.length,I=[],U=[],O=0;O<L;O++){var D=F[O],Q=(n=D.color,o=void 0,o=a.parse(n),[k(o[0],o[1],o[2]),o[3]]);U.push(D.offset*h+u+" "+Q[0]),0!==O&&O!==L-1||I.push(Q)}if(L>=2){var M=I[0][0],R=I[1][0],P=I[0][1]*e.opacity,H=I[1][1]*e.opacity;t.type=A,t.method="none",t.focus="100%",t.angle=l,t.color=M,t.color2=R,t.colors=U.join(","),t.opacity=H,t.opacity2=P}"radial"===A&&(t.focusposition=c.join(","))}else _(t,s,e.opacity)}(s,r,n):function(t,e){e.lineDash&&(t.dashstyle=e.lineDash.join(" ")),null==e.stroke||e.stroke instanceof p||_(t,e.stroke,e.opacity)}(s,r),T(t,s)):(t[o?"filled":"stroked"]="false",F(t,s))},O=[[],[],[]];d.prototype.brushVML=function(t){var e=this.style,r=this._vmlEl;r||(r=g.createNode("shape"),S(r),this._vmlEl=r),U(r,"fill",e,this),U(r,"stroke",e,this);var n=this.transform,o=null!=n,a=r.getElementsByTagName("stroke")[0];if(a){var s=e.lineWidth;if(o&&!e.strokeNoScale){var A=n[0]*n[3]-n[1]*n[2];s*=y(w(A))}a.weight=s+"px"}var l=this.path||(this.path=new f);this.__dirtyPath&&(l.beginPath(),l.subPixelOptimize=!1,this.buildPath(l,this.shape),l.toStatic(),this.__dirtyPath=!1),r.path=function(t,e){var r,n,o,a,s,A,l=m.M,c=m.C,u=m.L,h=m.A,d=m.Q,f=[],p=t.data,g=t.len();for(a=0;a<g;){switch(n="",r=0,o=p[a++]){case l:n=" m ",r=1,s=p[a++],A=p[a++],O[0][0]=s,O[0][1]=A;break;case u:n=" l ",r=1,s=p[a++],A=p[a++],O[0][0]=s,O[0][1]=A;break;case d:case c:n=" c ",r=3;var w,B,S=p[a++],k=p[a++],T=p[a++],F=p[a++];o===d?(w=T,B=F,T=(T+2*S)/3,F=(F+2*k)/3,S=(s+2*S)/3,k=(A+2*k)/3):(w=p[a++],B=p[a++]),O[0][0]=S,O[0][1]=k,O[1][0]=T,O[1][1]=F,O[2][0]=w,O[2][1]=B,s=w,A=B;break;case h:var L=0,I=0,_=1,U=1,D=0;e&&(L=e[4],I=e[5],_=y(e[0]*e[0]+e[1]*e[1]),U=y(e[2]*e[2]+e[3]*e[3]),D=Math.atan2(-e[1]/U,e[0]/_));var Q=p[a++],M=p[a++],R=p[a++],P=p[a++],H=p[a++]+D,N=p[a++]+H+D;a++;var K=p[a++],j=Q+b(H)*R,G=M+C(H)*P,V=(S=Q+b(N)*R,k=M+C(N)*P,K?" wa ":" at ");Math.abs(j-S)<1e-4&&(Math.abs(N-H)>.01?K&&(j+=.0125):Math.abs(G-M)<1e-4?K&&j<Q||!K&&j>Q?k-=.0125:k+=.0125:K&&G<M||!K&&G>M?S+=.0125:S-=.0125),f.push(V,v(((Q-R)*_+L)*x-E),",",v(((M-P)*U+I)*x-E),",",v(((Q+R)*_+L)*x-E),",",v(((M+P)*U+I)*x-E),",",v((j*_+L)*x-E),",",v((G*U+I)*x-E),",",v((S*_+L)*x-E),",",v((k*U+I)*x-E)),s=S,A=k;break;case m.R:var z=O[0],W=O[1];z[0]=p[a++],z[1]=p[a++],W[0]=z[0]+p[a++],W[1]=z[1]+p[a++],e&&(i(z,z,e),i(W,W,e)),z[0]=v(z[0]*x-E),W[0]=v(W[0]*x-E),z[1]=v(z[1]*x-E),W[1]=v(W[1]*x-E),f.push(" m ",z[0],",",z[1]," l ",W[0],",",z[1]," l ",W[0],",",W[1]," l ",z[0],",",W[1]);break;case m.Z:f.push(" x ")}if(r>0){f.push(n);for(var Y=0;Y<r;Y++){var X=O[Y];e&&i(X,X,e),f.push(v(X[0]*x-E),",",v(X[1]*x-E),Y<r-1?",":"")}}}return f.join("")}(l,this.transform),r.style.zIndex=L(this.zlevel,this.z,this.z2),T(t,r),null!=e.text?this.drawRectText(t,this.getBoundingRect()):this.removeRectText(t)},d.prototype.onRemove=function(t){F(t,this._vmlEl),this.removeRectText(t)},d.prototype.onAdd=function(t){T(t,this._vmlEl),this.appendRectText(t)};u.prototype.brushVML=function(t){var e,r,n,o=this.style,a=o.image;if("object"==typeof(n=a)&&n.tagName&&"IMG"===n.tagName.toUpperCase()){var s=a.src;if(s===this._imageSrc)e=this._imageWidth,r=this._imageHeight;else{var A=a.runtimeStyle,l=A.width,c=A.height;A.width="auto",A.height="auto",e=a.width,r=a.height,A.width=l,A.height=c,this._imageSrc=s,this._imageWidth=e,this._imageHeight=r}a=s}else a===this._imageSrc&&(e=this._imageWidth,r=this._imageHeight);if(a){var u=o.x||0,h=o.y||0,d=o.width,f=o.height,p=o.sWidth,m=o.sHeight,w=o.sx||0,b=o.sy||0,C=p&&m,x=this._vmlEl;x||(x=g.doc.createElement("div"),S(x),this._vmlEl=x);var E,k=x.style,F=!1,I=1,_=1;if(this.transform&&(E=this.transform,I=y(E[0]*E[0]+E[1]*E[1]),_=y(E[2]*E[2]+E[3]*E[3]),F=E[1]||E[2]),F){var U=[u,h],O=[u+d,h],D=[u,h+f],Q=[u+d,h+f];i(U,U,E),i(O,O,E),i(D,D,E),i(Q,Q,E);var M=B(U[0],O[0],D[0],Q[0]),R=B(U[1],O[1],D[1],Q[1]),P=[];P.push("M11=",E[0]/I,",","M12=",E[2]/_,",","M21=",E[1]/I,",","M22=",E[3]/_,",","Dx=",v(u*I+E[4]),",","Dy=",v(h*_+E[5])),k.padding="0 "+v(M)+"px "+v(R)+"px 0",k.filter="progid:DXImageTransform.Microsoft.Matrix("+P.join("")+", SizingMethod=clip)"}else E&&(u=u*I+E[4],h=h*_+E[5]),k.filter="",k.left=v(u)+"px",k.top=v(h)+"px";var H=this._imageEl,N=this._cropEl;H||(H=g.doc.createElement("div"),this._imageEl=H);var K=H.style;if(C){if(e&&r)K.width=v(I*e*d/p)+"px",K.height=v(_*r*f/m)+"px";else{var j=new Image,G=this;j.onload=function(){j.onload=null,e=j.width,r=j.height,K.width=v(I*e*d/p)+"px",K.height=v(_*r*f/m)+"px",G._imageWidth=e,G._imageHeight=r,G._imageSrc=a},j.src=a}N||((N=g.doc.createElement("div")).style.overflow="hidden",this._cropEl=N);var V=N.style;V.width=v((d+w*d/p)*I),V.height=v((f+b*f/m)*_),V.filter="progid:DXImageTransform.Microsoft.Matrix(Dx="+-w*d/p*I+",Dy="+-b*f/m*_+")",N.parentNode||x.appendChild(N),H.parentNode!==N&&N.appendChild(H)}else K.width=v(I*d)+"px",K.height=v(_*f)+"px",x.appendChild(H),N&&N.parentNode&&(x.removeChild(N),this._cropEl=null);var z="",W=o.opacity;W<1&&(z+=".Alpha(opacity="+v(100*W)+") "),z+="progid:DXImageTransform.Microsoft.AlphaImageLoader(src="+a+", SizingMethod=scale)",K.filter=z,x.style.zIndex=L(this.zlevel,this.z,this.z2),T(t,x),null!=o.text&&this.drawRectText(t,this.getBoundingRect())}},u.prototype.onRemove=function(t){F(t,this._vmlEl),this._vmlEl=null,this._cropEl=null,this._imageEl=null,this.removeRectText(t)},u.prototype.onAdd=function(t){T(t,this._vmlEl),this.appendRectText(t)};var D,Q={},M=0,R=document.createElement("div");s.$override("measureText",(function(t,e){var r=g.doc;D||((D=r.createElement("div")).style.cssText="position:absolute;top:-20000px;left:0;padding:0;margin:0;border:none;white-space:pre;",g.doc.body.appendChild(D));try{D.style.font=e}catch(t){}return D.innerHTML="",D.appendChild(r.createTextNode(t)),{width:D.offsetWidth}}));for(var P=new o,H=function(t,e,r,n){var o=this.style;this.__dirty&&A.normalizeTextStyle(o,!0);var a=o.text;if(null!=a&&(a+=""),a){if(o.rich){var l=s.parseRichText(a,o);a=[];for(var c=0;c<l.lines.length;c++){for(var u=l.lines[c].tokens,h=[],d=0;d<u.length;d++)h.push(u[d].text);a.push(h.join(""))}a=a.join("\n")}var f,p,m=o.textAlign,y=o.textVerticalAlign,w=function(t){var e=Q[t];if(!e){M>100&&(M=0,Q={});var r,n=R.style;try{n.font=t,r=n.fontFamily.split(",")[0]}catch(t){}e={style:n.fontStyle||"normal",variant:n.fontVariant||"normal",weight:n.fontWeight||"normal",size:0|parseFloat(n.fontSize||12),family:r||"Microsoft YaHei"},Q[t]=e,M++}return e}(o.font),b=w.style+" "+w.variant+" "+w.weight+" "+w.size+'px "'+w.family+'"';r=r||s.getBoundingRect(a,b,m,y,o.textPadding,o.textLineHeight);var C=this.transform;if(C&&!n&&(P.copy(e),P.applyTransform(C),e=P),n)f=e.x,p=e.y;else{var B=o.textPosition;if(B instanceof Array)f=e.x+I(B[0],e.width),p=e.y+I(B[1],e.height),m=m||"left";else{var x=this.calculateTextPosition?this.calculateTextPosition({},o,e):s.calculateTextPosition({},o,e);f=x.x,p=x.y,m=m||x.textAlign,y=y||x.textVerticalAlign}}f=s.adjustTextX(f,r.width,m),p=s.adjustTextY(p,r.height,y),p+=r.height/2;var E,k,F,_=g.createNode,O=this._textVmlEl;O?k=(E=(F=O.firstChild).nextSibling).nextSibling:(O=_("line"),E=_("path"),k=_("textpath"),F=_("skew"),k.style["v-text-align"]="left",S(O),E.textpathok=!0,k.on=!0,O.from="0 0",O.to="1000 0.05",T(O,F),T(O,E),T(O,k),this._textVmlEl=O);var D=[f,p],H=O.style;C&&n?(i(D,D,C),F.on=!0,F.matrix=C[0].toFixed(3)+","+C[2].toFixed(3)+","+C[1].toFixed(3)+","+C[3].toFixed(3)+",0,0",F.offset=(v(D[0])||0)+","+(v(D[1])||0),F.origin="0 0",H.left="0px",H.top="0px"):(F.on=!1,H.left=v(f)+"px",H.top=v(p)+"px"),k.string=String(a).replace(/&/g,"&").replace(/"/g,""");try{k.style.font=b}catch(t){}U(O,"fill",{fill:o.textFill,opacity:o.opacity},this),U(O,"stroke",{stroke:o.textStroke,opacity:o.opacity,lineDash:o.lineDash||null},this),O.style.zIndex=L(this.zlevel,this.z,this.z2),T(t,O)}},N=function(t){F(t,this._textVmlEl),this._textVmlEl=null},K=function(t){T(t,this._textVmlEl)},j=[l,c,u,d,h],G=0;G<j.length;G++){var V=j[G].prototype;V.drawRectText=H,V.removeRectText=N,V.appendRectText=K}h.prototype.brushVML=function(t){var e=this.style;null!=e.text?this.drawRectText(t,{x:e.x||0,y:e.y||0,width:0,height:0},this.getBoundingRect(),!0):this.removeRectText(t)},h.prototype.onRemove=function(t){this.removeRectText(t)},h.prototype.onAdd=function(t){this.appendRectText(t)}}},r6Bn:
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/Storage.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./core/util */"bYtY"),i=r(/*! ./core/env */"ItGF"),o=r(/*! ./container/Group */"4fz+"),a=r(/*! ./core/timsort */"BPZU");function s(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}var A=function(){this._roots=[],this._displayList=[],this._displayListLen=0};A.prototype={constructor:A,traverse:function(t,e){for(var r=0;r<this._roots.length;r++)this._roots[r].traverse(t,e)},getDisplayList:function(t,e){return e=e||!1,t&&this.updateDisplayList(e),this._displayList},updateDisplayList:function(t){this._displayListLen=0;for(var e=this._roots,r=this._displayList,n=0,o=e.length;n<o;n++)this._updateAndAddDisplayable(e[n],null,t);r.length=this._displayListLen,i.canvasSupported&&a(r,s)},_updateAndAddDisplayable:function(t,e,r){if(!t.ignore||r){t.beforeUpdate(),t.__dirty&&t.update(),t.afterUpdate();var n=t.clipPath;if(n){e=e?e.slice():[];for(var i=n,o=t;i;)i.parent=o,i.updateTransform(),e.push(i),o=i,i=i.clipPath}if(t.isGroup){for(var a=t._children,s=0;s<a.length;s++){var A=a[s];t.__dirty&&(A.__dirty=!0),this._updateAndAddDisplayable(A,e,r)}t.__dirty=!1}else t.__clipPaths=e,this._displayList[this._displayListLen++]=t}},addRoot:function(t){t.__storage!==this&&(t instanceof o&&t.addChildrenToStorage(this),this.addToStorage(t),this._roots.push(t))},delRoot:function(t){if(null==t){for(var e=0;e<this._roots.length;e++){var r=this._roots[e];r instanceof o&&r.delChildrenFromStorage(this)}return this._roots=[],this._displayList=[],void(this._displayListLen=0)}if(t instanceof Array){e=0;for(var i=t.length;e<i;e++)this.delRoot(t[e])}else{var a=n.indexOf(this._roots,t);a>=0&&(this.delFromStorage(t),this._roots.splice(a,1),t instanceof o&&t.delChildrenFromStorage(this))}},addToStorage:function(t){return t&&(t.__storage=this,t.dirty(!1)),this},delFromStorage:function(t){return t&&(t.__storage=null),this},dispose:function(){this._renderList=this._roots=null},displayableSortFunc:s};var l=A;t.exports=l},rA99:
|
|
|
/*!***************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/BezierCurve.js ***!
|
|
|
\***************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt"),i=r(/*! ../../core/vector */"QBsz"),o=r(/*! ../../core/curve */"Sj9i"),a=o.quadraticSubdivide,s=o.cubicSubdivide,A=o.quadraticAt,l=o.cubicAt,c=o.quadraticDerivativeAt,u=o.cubicDerivativeAt,h=[];function d(t,e,r){var n=t.cpx2,i=t.cpy2;return null===n||null===i?[(r?u:l)(t.x1,t.cpx1,t.cpx2,t.x2,e),(r?u:l)(t.y1,t.cpy1,t.cpy2,t.y2,e)]:[(r?c:A)(t.x1,t.cpx1,t.x2,e),(r?c:A)(t.y1,t.cpy1,t.y2,e)]}var f=n.extend({type:"bezier-curve",shape:{x1:0,y1:0,x2:0,y2:0,cpx1:0,cpy1:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var r=e.x1,n=e.y1,i=e.x2,o=e.y2,A=e.cpx1,l=e.cpy1,c=e.cpx2,u=e.cpy2,d=e.percent;0!==d&&(t.moveTo(r,n),null==c||null==u?(d<1&&(a(r,A,i,d,h),A=h[1],i=h[2],a(n,l,o,d,h),l=h[1],o=h[2]),t.quadraticCurveTo(A,l,i,o)):(d<1&&(s(r,A,c,i,d,h),A=h[1],c=h[2],i=h[3],s(n,l,u,o,d,h),l=h[1],u=h[2],o=h[3]),t.bezierCurveTo(A,l,c,u,i,o)))},pointAt:function(t){return d(this.shape,t,!1)},tangentAt:function(t){var e=d(this.shape,t,!0);return i.normalize(e,e)}});t.exports=f},"rAM+":
|
|
|
/*!*******************************************************************************************************************!*\
|
|
|
!*** ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js ***!
|
|
|
\*******************************************************************************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";r.d(e,"a",(function(){return i}));var n=r(/*! @babel/runtime/helpers/esm/unsupportedIterableToArray */"Qw5x");function i(t,e){var r;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(r=Object(n.a)(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var i=0,o=function(){};return{s:o,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,A=!1;return{s:function(){r=t[Symbol.iterator]()},n:function(){var t=r.next();return s=t.done,t},e:function(t){A=!0,a=t},f:function(){try{s||null==r.return||r.return()}finally{if(A)throw a}}}}},rUJ1:
|
|
|
/*!********************************************!*\
|
|
|
!*** ./node_modules/marked/src/helpers.js ***!
|
|
|
\********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: escape */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){const r=/[&<>"']/,n=/[&<>"']/g,i=/[<>"']|&(?!#?\w+;)/,o=/[<>"']|&(?!#?\w+;)/g,a={"&":"&","<":"<",">":">",'"':""","'":"'"},s=t=>a[t];const A=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function l(t){return t.replace(A,(t,e)=>"colon"===(e=e.toLowerCase())?":":"#"===e.charAt(0)?"x"===e.charAt(1)?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):"")}const c=/(^|[^\[])\^/g;const u=/[^\w:]/g,h=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;const d={},f=/^[^:]+:\/*[^/]*$/,p=/^([^:]+:)[\s\S]*$/,g=/^([^:]+:\/*[^/]*)[\s\S]*$/;function m(t,e){d[" "+t]||(f.test(t)?d[" "+t]=t+"/":d[" "+t]=v(t,"/",!0));const r=-1===(t=d[" "+t]).indexOf(":");return"//"===e.substring(0,2)?r?e:t.replace(p,"$1")+e:"/"===e.charAt(0)?r?e:t.replace(g,"$1")+e:t+e}function v(t,e,r){const n=t.length;if(0===n)return"";let i=0;for(;i<n;){const o=t.charAt(n-i-1);if(o!==e||r){if(o===e||!r)break;i++}else i++}return t.substr(0,n-i)}t.exports={escape:function(t,e){if(e){if(r.test(t))return t.replace(n,s)}else if(i.test(t))return t.replace(o,s);return t},unescape:l,edit:function(t,e){t=t.source||t,e=e||"";const r={replace:(e,n)=>(n=(n=n.source||n).replace(c,"$1"),t=t.replace(e,n),r),getRegex:()=>new RegExp(t,e)};return r},cleanUrl:function(t,e,r){if(t){let t;try{t=decodeURIComponent(l(r)).replace(u,"").toLowerCase()}catch(t){return null}if(0===t.indexOf("javascript:")||0===t.indexOf("vbscript:")||0===t.indexOf("data:"))return null}e&&!h.test(r)&&(r=m(e,r));try{r=encodeURI(r).replace(/%25/g,"%")}catch(t){return null}return r},resolveUrl:m,noopTest:{exec:function(){}},merge:function(t){let e,r,n=1;for(;n<arguments.length;n++)for(r in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t},splitCells:function(t,e){const r=t.replace(/\|/g,(t,e,r)=>{let n=!1,i=e;for(;--i>=0&&"\\"===r[i];)n=!n;return n?"|":" |"}).split(/ \|/);let n=0;if(r.length>e)r.splice(e);else for(;r.length<e;)r.push("");for(;n<r.length;n++)r[n]=r[n].trim().replace(/\\\|/g,"|");return r},rtrim:v,findClosingBracket:function(t,e){if(-1===t.indexOf(e[1]))return-1;const r=t.length;let n=0,i=0;for(;i<r;i++)if("\\"===t[i])i++;else if(t[i]===e[0])n++;else if(t[i]===e[1]&&(n--,n<0))return i;return-1},checkSanitizeDeprecation:function(t){t&&t.sanitize&&!t.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}}},rcnY:
|
|
|
/*!*******************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/RSBlock.js ***!
|
|
|
\*******************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./ErrorCorrectLevel */"aRTE");function i(t,e){this.totalCount=t,this.dataCount=e}i.RS_BLOCK_TABLE=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16],[4,101,81],[1,80,50,4,81,51],[4,50,22,4,51,23],[3,36,12,8,37,13],[2,116,92,2,117,93],[6,58,36,2,59,37],[4,46,20,6,47,21],[7,42,14,4,43,15],[4,133,107],[8,59,37,1,60,38],[8,44,20,4,45,21],[12,33,11,4,34,12],[3,145,115,1,146,116],[4,64,40,5,65,41],[11,36,16,5,37,17],[11,36,12,5,37,13],[5,109,87,1,110,88],[5,65,41,5,66,42],[5,54,24,7,55,25],[11,36,12],[5,122,98,1,123,99],[7,73,45,3,74,46],[15,43,19,2,44,20],[3,45,15,13,46,16],[1,135,107,5,136,108],[10,74,46,1,75,47],[1,50,22,15,51,23],[2,42,14,17,43,15],[5,150,120,1,151,121],[9,69,43,4,70,44],[17,50,22,1,51,23],[2,42,14,19,43,15],[3,141,113,4,142,114],[3,70,44,11,71,45],[17,47,21,4,48,22],[9,39,13,16,40,14],[3,135,107,5,136,108],[3,67,41,13,68,42],[15,54,24,5,55,25],[15,43,15,10,44,16],[4,144,116,4,145,117],[17,68,42],[17,50,22,6,51,23],[19,46,16,6,47,17],[2,139,111,7,140,112],[17,74,46],[7,54,24,16,55,25],[34,37,13],[4,151,121,5,152,122],[4,75,47,14,76,48],[11,54,24,14,55,25],[16,45,15,14,46,16],[6,147,117,4,148,118],[6,73,45,14,74,46],[11,54,24,16,55,25],[30,46,16,2,47,17],[8,132,106,4,133,107],[8,75,47,13,76,48],[7,54,24,22,55,25],[22,45,15,13,46,16],[10,142,114,2,143,115],[19,74,46,4,75,47],[28,50,22,6,51,23],[33,46,16,4,47,17],[8,152,122,4,153,123],[22,73,45,3,74,46],[8,53,23,26,54,24],[12,45,15,28,46,16],[3,147,117,10,148,118],[3,73,45,23,74,46],[4,54,24,31,55,25],[11,45,15,31,46,16],[7,146,116,7,147,117],[21,73,45,7,74,46],[1,53,23,37,54,24],[19,45,15,26,46,16],[5,145,115,10,146,116],[19,75,47,10,76,48],[15,54,24,25,55,25],[23,45,15,25,46,16],[13,145,115,3,146,116],[2,74,46,29,75,47],[42,54,24,1,55,25],[23,45,15,28,46,16],[17,145,115],[10,74,46,23,75,47],[10,54,24,35,55,25],[19,45,15,35,46,16],[17,145,115,1,146,116],[14,74,46,21,75,47],[29,54,24,19,55,25],[11,45,15,46,46,16],[13,145,115,6,146,116],[14,74,46,23,75,47],[44,54,24,7,55,25],[59,46,16,1,47,17],[12,151,121,7,152,122],[12,75,47,26,76,48],[39,54,24,14,55,25],[22,45,15,41,46,16],[6,151,121,14,152,122],[6,75,47,34,76,48],[46,54,24,10,55,25],[2,45,15,64,46,16],[17,152,122,4,153,123],[29,74,46,14,75,47],[49,54,24,10,55,25],[24,45,15,46,46,16],[4,152,122,18,153,123],[13,74,46,32,75,47],[48,54,24,14,55,25],[42,45,15,32,46,16],[20,147,117,4,148,118],[40,75,47,7,76,48],[43,54,24,22,55,25],[10,45,15,67,46,16],[19,148,118,6,149,119],[18,75,47,31,76,48],[34,54,24,34,55,25],[20,45,15,61,46,16]],i.getRSBlocks=function(t,e){var r=i.getRsBlockTable(t,e);if(null==r)throw new Error("bad rs block @ typeNumber:"+t+"/errorCorrectLevel:"+e);for(var n=r.length/3,o=new Array,a=0;a<n;a++)for(var s=r[3*a+0],A=r[3*a+1],l=r[3*a+2],c=0;c<s;c++)o.push(new i(A,l));return o},i.getRsBlockTable=function(t,e){switch(e){case n.L:return i.RS_BLOCK_TABLE[4*(t-1)+0];case n.M:return i.RS_BLOCK_TABLE[4*(t-1)+1];case n.Q:return i.RS_BLOCK_TABLE[4*(t-1)+2];case n.H:return i.RS_BLOCK_TABLE[4*(t-1)+3];default:return}},t.exports=i},rmlV:
|
|
|
/*!***********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Ellipse.js ***!
|
|
|
\***********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt").extend({type:"ellipse",shape:{cx:0,cy:0,rx:0,ry:0},buildPath:function(t,e){var r=.5522848,n=e.cx,i=e.cy,o=e.rx,a=e.ry,s=o*r,A=a*r;t.moveTo(n-o,i),t.bezierCurveTo(n-o,i-A,n-s,i-a,n,i-a),t.bezierCurveTo(n+s,i-a,n+o,i-A,n+o,i),t.bezierCurveTo(n+o,i+A,n+s,i+a,n,i+a),t.bezierCurveTo(n-s,i+a,n-o,i+A,n-o,i),t.closePath()}});t.exports=n},sR1s:
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/utils/valueUtil.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! exports provided: getPathValue, getColumnsKey, mergeObject, validateValue */
|
|
|
/*! exports used: getColumnsKey, getPathValue, mergeObject, validateValue */function(t,e,r){"use strict";r.d(e,"b",(function(){return o})),r.d(e,"a",(function(){return a})),r.d(e,"c",(function(){return s})),r.d(e,"d",(function(){return A}));var n=r(/*! @babel/runtime/helpers/esm/typeof */"U8pU");function i(t){return null==t?[]:Array.isArray(t)?t:[t]}function o(t,e){if(!e&&"number"!=typeof e)return t;for(var r=i(e),n=t,o=0;o<r.length;o+=1){if(!n)return null;n=n[r[o]]}return n}function a(t){var e=[],r={};return t.forEach((function(t){for(var n=t||{},o=n.key,a=n.dataIndex,s=o||i(a).join("-")||"RC_TABLE_KEY";r[s];)s="".concat(s,"_next");r[s]=!0,e.push(s)})),e}function s(){var t={};function e(t,r){r&&Object.keys(r).forEach((function(i){var o=r[i];o&&"object"===Object(n.a)(o)?(t[i]=t[i]||{},e(t[i],o)):t[i]=o}))}for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return i.forEach((function(r){e(t,r)})),t}function A(t){return null!=t}},"sW+o":
|
|
|
/*!****************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/svg/helper/GradientManager.js ***!
|
|
|
\****************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./Definable */"SrGk"),i=r(/*! ../../core/util */"bYtY"),o=r(/*! ../../core/log */"SUKs"),a=r(/*! ../../tool/color */"Qe9p");function s(t,e){n.call(this,t,e,["linearGradient","radialGradient"],"__gradient_in_use__")}i.inherits(s,n),s.prototype.addWithoutUpdate=function(t,e){if(e&&e.style){var r=this;i.each(["fill","stroke"],(function(n){if(e.style[n]&&("linear"===e.style[n].type||"radial"===e.style[n].type)){var i,o=e.style[n],a=r.getDefs(!0);o._dom?(i=o._dom,a.contains(o._dom)||r.addDom(i)):i=r.add(o),r.markUsed(e);var s=i.getAttribute("id");t.setAttribute(n,"url(#"+s+")")}}))}},s.prototype.add=function(t){var e;if("linear"===t.type)e=this.createElement("linearGradient");else{if("radial"!==t.type)return o("Illegal gradient type."),null;e=this.createElement("radialGradient")}return t.id=t.id||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-gradient-"+t.id),this.updateDom(t,e),this.addDom(e),e},s.prototype.update=function(t){var e=this;n.prototype.update.call(this,t,(function(){var r=t.type,n=t._dom.tagName;"linear"===r&&"linearGradient"===n||"radial"===r&&"radialGradient"===n?e.updateDom(t,t._dom):(e.removeDom(t),e.add(t))}))},s.prototype.updateDom=function(t,e){if("linear"===t.type)e.setAttribute("x1",t.x),e.setAttribute("y1",t.y),e.setAttribute("x2",t.x2),e.setAttribute("y2",t.y2);else{if("radial"!==t.type)return void o("Illegal gradient type.");e.setAttribute("cx",t.x),e.setAttribute("cy",t.y),e.setAttribute("r",t.r)}t.global?e.setAttribute("gradientUnits","userSpaceOnUse"):e.setAttribute("gradientUnits","objectBoundingBox"),e.innerHTML="";for(var r=t.colorStops,n=0,i=r.length;n<i;++n){var s=this.createElement("stop");s.setAttribute("offset",100*r[n].offset+"%");var A=r[n].color;if(A.indexOf(!1)){var l=a.parse(A)[3],c=a.toHex(A);s.setAttribute("stop-color","#"+c),s.setAttribute("stop-opacity",l)}else s.setAttribute("stop-color",r[n].color);e.appendChild(s)}t._dom=e},s.prototype.markUsed=function(t){if(t.style){var e=t.style.fill;e&&e._dom&&n.prototype.markUsed.call(this,e._dom),(e=t.style.stroke)&&e._dom&&n.prototype.markUsed.call(this,e._dom)}};var A=s;t.exports=A},sboe:
|
|
|
/*!*************************************************!*\
|
|
|
!*** ./node_modules/rc-tree/es/contextTypes.js ***!
|
|
|
\*************************************************/
|
|
|
/*! exports provided: TreeContext */
|
|
|
/*! exports used: TreeContext */function(t,e,r){"use strict";r.d(e,"a",(function(){return i}));var n=r(/*! react */"q1tI"),i=n.createContext(null)},t23M:
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/rc-resize-observer/es/index.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! exports provided: default */
|
|
|
/*! exports used: default */function(t,e,r){"use strict";var n=r(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ"),i=r(/*! @babel/runtime/helpers/esm/classCallCheck */"1OyB"),o=r(/*! @babel/runtime/helpers/esm/createClass */"vuIU"),a=r(/*! @babel/runtime/helpers/esm/inherits */"Ji7U"),s=r(/*! @babel/runtime/helpers/esm/createSuper */"LK+K"),A=r(/*! react */"q1tI"),l=r(/*! rc-util/es/Dom/findDOMNode */"m+aA"),c=r(/*! rc-util/es/Children/toArray */"Zm9Q"),u=r(/*! rc-util/es/warning */"Kwbf"),h=r(/*! rc-util/es/ref */"c+Xe"),d=r(/*! resize-observer-polyfill */"bdgK"),f=function(t){Object(a.a)(r,t);var e=Object(s.a)(r);function r(){var t;return Object(i.a)(this,r),(t=e.apply(this,arguments)).resizeObserver=null,t.childNode=null,t.currentElement=null,t.state={width:0,height:0,offsetHeight:0,offsetWidth:0},t.onResize=function(e){var r=t.props.onResize,i=e[0].target,o=i.getBoundingClientRect(),a=o.width,s=o.height,A=i.offsetWidth,l=i.offsetHeight,c=Math.floor(a),u=Math.floor(s);if(t.state.width!==c||t.state.height!==u||t.state.offsetWidth!==A||t.state.offsetHeight!==l){var h={width:c,height:u,offsetWidth:A,offsetHeight:l};t.setState(h),r&&Promise.resolve().then((function(){r(Object(n.a)(Object(n.a)({},h),{},{offsetWidth:A,offsetHeight:l}))}))}},t.setChildNode=function(e){t.childNode=e},t}return Object(o.a)(r,[{key:"componentDidMount",value:function(){this.onComponentUpdated()}},{key:"componentDidUpdate",value:function(){this.onComponentUpdated()}},{key:"componentWillUnmount",value:function(){this.destroyObserver()}},{key:"onComponentUpdated",value:function(){if(this.props.disabled)this.destroyObserver();else{var t=Object(l.a)(this.childNode||this);t!==this.currentElement&&(this.destroyObserver(),this.currentElement=t),!this.resizeObserver&&t&&(this.resizeObserver=new d.default(this.onResize),this.resizeObserver.observe(t))}}},{key:"destroyObserver",value:function(){this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=null)}},{key:"render",value:function(){var t=this.props.children,e=Object(c.a)(t);if(e.length>1)Object(u.a)(!1,"Find more than one child node with `children` in ResizeObserver. Will only observe first one.");else if(0===e.length)return Object(u.a)(!1,"`children` of ResizeObserver is empty. Nothing is in observe."),null;var r=e[0];if(A.isValidElement(r)&&Object(h.c)(r)){var n=r.ref;e[0]=A.cloneElement(r,{ref:Object(h.a)(n,this.setChildNode)})}return 1===e.length?e[0]:e.map((function(t,e){return!A.isValidElement(t)||"key"in t&&null!==t.key?t:A.cloneElement(t,{key:"".concat("rc-observer-key","-").concat(e)})}))}}]),r}(A.Component);f.displayName="ResizeObserver",e.a=f},u3os:
|
|
|
/*!***********************************************!*\
|
|
|
!*** ./node_modules/size-sensor/lib/index.js ***!
|
|
|
\***********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ver=e.clear=e.bind=void 0;var n=r(/*! ./sensorPool */"P4Qj");e.bind=function(t,e){var r=(0,n.getSensor)(t);return r.bind(e),function(){r.unbind(e)}};e.clear=function(t){var e=(0,n.getSensor)(t);(0,n.removeSensor)(e)};e.ver="1.0.1"},ulZh:
|
|
|
/*!*****************************************!*\
|
|
|
!*** ./node_modules/hls.js/dist/hls.js ***!
|
|
|
\*****************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n;"undefined"!=typeof window&&(n=function(){return function(t){var e={};function r(n){if(e[n])return e[n].exports;var i=e[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)r.d(n,i,function(e){return t[e]}.bind(null,i));return n},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="/dist/",r(r.s="./src/hls.ts")}({"./node_modules/eventemitter3/index.js":
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/eventemitter3/index.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */function(t,e,r){"use strict";var n=Object.prototype.hasOwnProperty,i="~";function o(){}function a(t,e,r){this.fn=t,this.context=e,this.once=r||!1}function s(t,e,r,n,o){if("function"!=typeof r)throw new TypeError("The listener must be a function");var s=new a(r,n||t,o),A=i?i+e:e;return t._events[A]?t._events[A].fn?t._events[A]=[t._events[A],s]:t._events[A].push(s):(t._events[A]=s,t._eventsCount++),t}function A(t,e){0==--t._eventsCount?t._events=new o:delete t._events[e]}function l(){this._events=new o,this._eventsCount=0}Object.create&&(o.prototype=Object.create(null),(new o).__proto__||(i=!1)),l.prototype.eventNames=function(){var t,e,r=[];if(0===this._eventsCount)return r;for(e in t=this._events)n.call(t,e)&&r.push(i?e.slice(1):e);return Object.getOwnPropertySymbols?r.concat(Object.getOwnPropertySymbols(t)):r},l.prototype.listeners=function(t){var e=i?i+t:t,r=this._events[e];if(!r)return[];if(r.fn)return[r.fn];for(var n=0,o=r.length,a=new Array(o);n<o;n++)a[n]=r[n].fn;return a},l.prototype.listenerCount=function(t){var e=i?i+t:t,r=this._events[e];return r?r.fn?1:r.length:0},l.prototype.emit=function(t,e,r,n,o,a){var s=i?i+t:t;if(!this._events[s])return!1;var A,l,c=this._events[s],u=arguments.length;if(c.fn){switch(c.once&&this.removeListener(t,c.fn,void 0,!0),u){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,e),!0;case 3:return c.fn.call(c.context,e,r),!0;case 4:return c.fn.call(c.context,e,r,n),!0;case 5:return c.fn.call(c.context,e,r,n,o),!0;case 6:return c.fn.call(c.context,e,r,n,o,a),!0}for(l=1,A=new Array(u-1);l<u;l++)A[l-1]=arguments[l];c.fn.apply(c.context,A)}else{var h,d=c.length;for(l=0;l<d;l++)switch(c[l].once&&this.removeListener(t,c[l].fn,void 0,!0),u){case 1:c[l].fn.call(c[l].context);break;case 2:c[l].fn.call(c[l].context,e);break;case 3:c[l].fn.call(c[l].context,e,r);break;case 4:c[l].fn.call(c[l].context,e,r,n);break;default:if(!A)for(h=1,A=new Array(u-1);h<u;h++)A[h-1]=arguments[h];c[l].fn.apply(c[l].context,A)}}return!0},l.prototype.on=function(t,e,r){return s(this,t,e,r,!1)},l.prototype.once=function(t,e,r){return s(this,t,e,r,!0)},l.prototype.removeListener=function(t,e,r,n){var o=i?i+t:t;if(!this._events[o])return this;if(!e)return A(this,o),this;var a=this._events[o];if(a.fn)a.fn!==e||n&&!a.once||r&&a.context!==r||A(this,o);else{for(var s=0,l=[],c=a.length;s<c;s++)(a[s].fn!==e||n&&!a[s].once||r&&a[s].context!==r)&&l.push(a[s]);l.length?this._events[o]=1===l.length?l[0]:l:A(this,o)}return this},l.prototype.removeAllListeners=function(t){var e;return t?(e=i?i+t:t,this._events[e]&&A(this,e)):(this._events=new o,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prefixed=i,l.EventEmitter=l,t.exports=l},"./node_modules/url-toolkit/src/url-toolkit.js":
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/url-toolkit/src/url-toolkit.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! no static exports found */function(t,e,r){var n,i,o,a,s;n=/^((?:[a-zA-Z0-9+\-.]+:)?)(\/\/[^\/?#]*)?((?:[^\/?#]*\/)*[^;?#]*)?(;[^?#]*)?(\?[^#]*)?(#[^]*)?$/,i=/^([^\/?#]*)([^]*)$/,o=/(?:\/|^)\.(?=\/)/g,a=/(?:\/|^)\.\.\/(?!\.\.\/)[^\/]*(?=\/)/g,s={buildAbsoluteURL:function(t,e,r){if(r=r||{},t=t.trim(),!(e=e.trim())){if(!r.alwaysNormalize)return t;var n=s.parseURL(t);if(!n)throw new Error("Error trying to parse base URL.");return n.path=s.normalizePath(n.path),s.buildURLFromParts(n)}var o=s.parseURL(e);if(!o)throw new Error("Error trying to parse relative URL.");if(o.scheme)return r.alwaysNormalize?(o.path=s.normalizePath(o.path),s.buildURLFromParts(o)):e;var a=s.parseURL(t);if(!a)throw new Error("Error trying to parse base URL.");if(!a.netLoc&&a.path&&"/"!==a.path[0]){var A=i.exec(a.path);a.netLoc=A[1],a.path=A[2]}a.netLoc&&!a.path&&(a.path="/");var l={scheme:a.scheme,netLoc:o.netLoc,path:null,params:o.params,query:o.query,fragment:o.fragment};if(!o.netLoc&&(l.netLoc=a.netLoc,"/"!==o.path[0]))if(o.path){var c=a.path,u=c.substring(0,c.lastIndexOf("/")+1)+o.path;l.path=s.normalizePath(u)}else l.path=a.path,o.params||(l.params=a.params,o.query||(l.query=a.query));return null===l.path&&(l.path=r.alwaysNormalize?s.normalizePath(o.path):o.path),s.buildURLFromParts(l)},parseURL:function(t){var e=n.exec(t);return e?{scheme:e[1]||"",netLoc:e[2]||"",path:e[3]||"",params:e[4]||"",query:e[5]||"",fragment:e[6]||""}:null},normalizePath:function(t){for(t=t.split("").reverse().join("").replace(o,"");t.length!==(t=t.replace(a,"")).length;);return t.split("").reverse().join("")},buildURLFromParts:function(t){return t.scheme+t.netLoc+t.path+t.params+t.query+t.fragment}},t.exports=s},"./node_modules/webworkify-webpack/index.js":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/webworkify-webpack/index.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */function(t,e,r){function n(t){var e={};function r(n){if(e[n])return e[n].exports;var i=e[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}r.m=t,r.c=e,r.i=function(t){return t},r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:n})},r.r=function(t){Object.defineProperty(t,"__esModule",{value:!0})},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="/",r.oe=function(t){throw console.error(t),t};var n=r(r.s=ENTRY_MODULE);return n.default||n}function i(t){return(t+"").replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}function o(t,e,n){var o={};o[n]=[];var a=e.toString(),s=a.match(/^function\s?\w*\(\w+,\s*\w+,\s*(\w+)\)/);if(!s)return o;for(var A,l=s[1],c=new RegExp("(\\\\n|\\W)"+i(l)+"\\(\\s*(/\\*.*?\\*/)?\\s*.*?([\\.|\\-|\\+|\\w|/|@]+).*?\\)","g");A=c.exec(a);)"dll-reference"!==A[3]&&o[n].push(A[3]);for(c=new RegExp("\\("+i(l)+'\\("(dll-reference\\s([\\.|\\-|\\+|\\w|/|@]+))"\\)\\)\\(\\s*(/\\*.*?\\*/)?\\s*.*?([\\.|\\-|\\+|\\w|/|@]+).*?\\)',"g");A=c.exec(a);)t[A[2]]||(o[n].push(A[1]),t[A[2]]=r(A[1]).m),o[A[2]]=o[A[2]]||[],o[A[2]].push(A[4]);for(var u,h=Object.keys(o),d=0;d<h.length;d++)for(var f=0;f<o[h[d]].length;f++)u=o[h[d]][f],isNaN(1*u)||(o[h[d]][f]=1*o[h[d]][f]);return o}function a(t){return Object.keys(t).reduce((function(e,r){return e||t[r].length>0}),!1)}t.exports=function(t,e){e=e||{};var i={main:r.m},s=e.all?{main:Object.keys(i.main)}:function(t,e){for(var r={main:[e]},n={main:[]},i={main:{}};a(r);)for(var s=Object.keys(r),A=0;A<s.length;A++){var l=s[A],c=r[l].pop();if(i[l]=i[l]||{},!i[l][c]&&t[l][c]){i[l][c]=!0,n[l]=n[l]||[],n[l].push(c);for(var u=o(t,t[l][c],l),h=Object.keys(u),d=0;d<h.length;d++)r[h[d]]=r[h[d]]||[],r[h[d]]=r[h[d]].concat(u[h[d]])}}return n}(i,t),A="";Object.keys(s).filter((function(t){return"main"!==t})).forEach((function(t){for(var e=0;s[t][e];)e++;s[t].push(e),i[t][e]="(function(module, exports, __webpack_require__) { module.exports = __webpack_require__; })",A=A+"var "+t+" = ("+n.toString().replace("ENTRY_MODULE",JSON.stringify(e))+")({"+s[t].map((function(e){return JSON.stringify(e)+": "+i[t][e].toString()})).join(",")+"});\n"})),A=A+"new (("+n.toString().replace("ENTRY_MODULE",JSON.stringify(t))+")({"+s.main.map((function(t){return JSON.stringify(t)+": "+i.main[t].toString()})).join(",")+"}))(self);";var l=new window.Blob([A],{type:"text/javascript"});if(e.bare)return l;var c=(window.URL||window.webkitURL||window.mozURL||window.msURL).createObjectURL(l),u=new window.Worker(c);return u.objectURL=c,u}},"./src/config.ts":
|
|
|
/*!***********************!*\
|
|
|
!*** ./src/config.ts ***!
|
|
|
\***********************/
|
|
|
/*! exports provided: hlsDefaultConfig, mergeConfig, enableStreamingMode */function(t,e,r){"use strict";r.r(e),r.d(e,"hlsDefaultConfig",(function(){return B})),r.d(e,"mergeConfig",(function(){return x})),r.d(e,"enableStreamingMode",(function(){return E}));var n=r(/*! ./controller/abr-controller */"./src/controller/abr-controller.ts"),i=r(/*! ./controller/audio-stream-controller */"./src/controller/audio-stream-controller.ts"),o=r(/*! ./controller/audio-track-controller */"./src/controller/audio-track-controller.ts"),a=r(/*! ./controller/subtitle-stream-controller */"./src/controller/subtitle-stream-controller.ts"),s=r(/*! ./controller/subtitle-track-controller */"./src/controller/subtitle-track-controller.ts"),A=r(/*! ./controller/buffer-controller */"./src/controller/buffer-controller.ts"),l=r(/*! ./controller/timeline-controller */"./src/controller/timeline-controller.ts"),c=r(/*! ./controller/cap-level-controller */"./src/controller/cap-level-controller.ts"),u=r(/*! ./controller/fps-controller */"./src/controller/fps-controller.ts"),h=r(/*! ./controller/eme-controller */"./src/controller/eme-controller.ts"),d=r(/*! ./controller/cmcd-controller */"./src/controller/cmcd-controller.ts"),f=r(/*! ./utils/xhr-loader */"./src/utils/xhr-loader.ts"),p=r(/*! ./utils/fetch-loader */"./src/utils/fetch-loader.ts"),g=r(/*! ./utils/cues */"./src/utils/cues.ts"),m=r(/*! ./utils/mediakeys-helper */"./src/utils/mediakeys-helper.ts"),v=r(/*! ./utils/logger */"./src/utils/logger.ts");function y(){return(y=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}function w(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function b(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?w(Object(r),!0).forEach((function(e){C(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):w(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function C(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var B=b(b({autoStartLoad:!0,startPosition:-1,defaultAudioCodec:void 0,debug:!1,capLevelOnFPSDrop:!1,capLevelToPlayerSize:!1,initialLiveManifestSize:1,maxBufferLength:30,backBufferLength:1/0,maxBufferSize:6e7,maxBufferHole:.1,highBufferWatchdogPeriod:2,nudgeOffset:.1,nudgeMaxRetry:3,maxFragLookUpTolerance:.25,liveSyncDurationCount:3,liveMaxLatencyDurationCount:1/0,liveSyncDuration:void 0,liveMaxLatencyDuration:void 0,maxLiveSyncPlaybackRate:1,liveDurationInfinity:!1,liveBackBufferLength:null,maxMaxBufferLength:600,enableWorker:!0,enableSoftwareAES:!0,manifestLoadingTimeOut:1e4,manifestLoadingMaxRetry:1,manifestLoadingRetryDelay:1e3,manifestLoadingMaxRetryTimeout:64e3,startLevel:void 0,levelLoadingTimeOut:1e4,levelLoadingMaxRetry:4,levelLoadingRetryDelay:1e3,levelLoadingMaxRetryTimeout:64e3,fragLoadingTimeOut:2e4,fragLoadingMaxRetry:6,fragLoadingRetryDelay:1e3,fragLoadingMaxRetryTimeout:64e3,startFragPrefetch:!1,fpsDroppedMonitoringPeriod:5e3,fpsDroppedMonitoringThreshold:.2,appendErrorMaxRetry:3,loader:f.default,fLoader:void 0,pLoader:void 0,xhrSetup:void 0,licenseXhrSetup:void 0,licenseResponseCallback:void 0,abrController:n.default,bufferController:A.default,capLevelController:c.default,fpsController:u.default,stretchShortVideoTrack:!1,maxAudioFramesDrift:1,forceKeyFrameOnDiscontinuity:!0,abrEwmaFastLive:3,abrEwmaSlowLive:9,abrEwmaFastVoD:3,abrEwmaSlowVoD:9,abrEwmaDefaultEstimate:5e5,abrBandWidthFactor:.95,abrBandWidthUpFactor:.7,abrMaxWithRealBitrate:!1,maxStarvationDelay:4,maxLoadingDelay:4,minAutoBitrate:0,emeEnabled:!1,widevineLicenseUrl:void 0,drmSystemOptions:{},requestMediaKeySystemAccessFunc:m.requestMediaKeySystemAccess,testBandwidth:!0,progressive:!1,lowLatencyMode:!0,cmcd:void 0},{cueHandler:g.default,enableCEA708Captions:!0,enableWebVTT:!0,enableIMSC1:!0,captionsTextTrack1Label:"English",captionsTextTrack1LanguageCode:"en",captionsTextTrack2Label:"Spanish",captionsTextTrack2LanguageCode:"es",captionsTextTrack3Label:"Unknown CC",captionsTextTrack3LanguageCode:"",captionsTextTrack4Label:"Unknown CC",captionsTextTrack4LanguageCode:"",renderTextTracksNatively:!0}),{},{subtitleStreamController:a.SubtitleStreamController,subtitleTrackController:s.default,timelineController:l.TimelineController,audioStreamController:i.default,audioTrackController:o.default,emeController:h.default,cmcdController:d.default});function x(t,e){if((e.liveSyncDurationCount||e.liveMaxLatencyDurationCount)&&(e.liveSyncDuration||e.liveMaxLatencyDuration))throw new Error("Illegal hls.js config: don't mix up liveSyncDurationCount/liveMaxLatencyDurationCount and liveSyncDuration/liveMaxLatencyDuration");if(void 0!==e.liveMaxLatencyDurationCount&&(void 0===e.liveSyncDurationCount||e.liveMaxLatencyDurationCount<=e.liveSyncDurationCount))throw new Error('Illegal hls.js config: "liveMaxLatencyDurationCount" must be greater than "liveSyncDurationCount"');if(void 0!==e.liveMaxLatencyDuration&&(void 0===e.liveSyncDuration||e.liveMaxLatencyDuration<=e.liveSyncDuration))throw new Error('Illegal hls.js config: "liveMaxLatencyDuration" must be greater than "liveSyncDuration"');return y({},t,e)}function E(t){var e=t.loader;e!==p.default&&e!==f.default?(v.logger.log("[config]: Custom loader detected, cannot enable progressive streaming"),t.progressive=!1):Object(p.fetchSupported)()&&(t.loader=p.default,t.progressive=!0,t.enableSoftwareAES=!0,v.logger.log("[config]: Progressive streaming enabled, using FetchLoader"))}},"./src/controller/abr-controller.ts":
|
|
|
/*!******************************************!*\
|
|
|
!*** ./src/controller/abr-controller.ts ***!
|
|
|
\******************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../utils/ewma-bandwidth-estimator */"./src/utils/ewma-bandwidth-estimator.ts"),o=r(/*! ../events */"./src/events.ts"),a=r(/*! ../utils/buffer-helper */"./src/utils/buffer-helper.ts"),s=r(/*! ../errors */"./src/errors.ts"),A=r(/*! ../types/loader */"./src/types/loader.ts"),l=r(/*! ../utils/logger */"./src/utils/logger.ts");function c(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var u=function(){function t(t){this.hls=void 0,this.lastLoadedFragLevel=0,this._nextAutoLevel=-1,this.timer=void 0,this.onCheck=this._abandonRulesCheck.bind(this),this.fragCurrent=null,this.partCurrent=null,this.bitrateTestDelay=0,this.bwEstimator=void 0,this.hls=t;var e=t.config;this.bwEstimator=new i.default(e.abrEwmaSlowVoD,e.abrEwmaFastVoD,e.abrEwmaDefaultEstimate),this.registerListeners()}var e,r,u,h=t.prototype;return h.registerListeners=function(){var t=this.hls;t.on(o.Events.FRAG_LOADING,this.onFragLoading,this),t.on(o.Events.FRAG_LOADED,this.onFragLoaded,this),t.on(o.Events.FRAG_BUFFERED,this.onFragBuffered,this),t.on(o.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.on(o.Events.ERROR,this.onError,this)},h.unregisterListeners=function(){var t=this.hls;t.off(o.Events.FRAG_LOADING,this.onFragLoading,this),t.off(o.Events.FRAG_LOADED,this.onFragLoaded,this),t.off(o.Events.FRAG_BUFFERED,this.onFragBuffered,this),t.off(o.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.off(o.Events.ERROR,this.onError,this)},h.destroy=function(){this.unregisterListeners(),this.clearTimer(),this.hls=this.onCheck=null,this.fragCurrent=this.partCurrent=null},h.onFragLoading=function(t,e){var r,n=e.frag;n.type===A.PlaylistLevelType.MAIN&&(this.timer||(this.fragCurrent=n,this.partCurrent=null!=(r=e.part)?r:null,this.timer=self.setInterval(this.onCheck,100)))},h.onLevelLoaded=function(t,e){var r=this.hls.config;e.details.live?this.bwEstimator.update(r.abrEwmaSlowLive,r.abrEwmaFastLive):this.bwEstimator.update(r.abrEwmaSlowVoD,r.abrEwmaFastVoD)},h._abandonRulesCheck=function(){var t=this.fragCurrent,e=this.partCurrent,r=this.hls,i=r.autoLevelEnabled,s=r.config,A=r.media;if(t&&A){var c=e?e.stats:t.stats,u=e?e.duration:t.duration;if(c.aborted)return l.logger.warn("frag loader destroy or aborted, disarm abandonRules"),this.clearTimer(),void(this._nextAutoLevel=-1);if(i&&!A.paused&&A.playbackRate&&A.readyState){var h=performance.now()-c.loading.start,d=Math.abs(A.playbackRate);if(!(h<=500*u/d)){var f=r.levels,p=r.minAutoLevel,g=f[t.level],m=c.total||Math.max(c.loaded,Math.round(u*g.maxBitrate/8)),v=Math.max(1,c.bwEstimate?c.bwEstimate/8:1e3*c.loaded/h),y=(m-c.loaded)/v,w=A.currentTime,b=(a.BufferHelper.bufferInfo(A,w,s.maxBufferHole).end-w)/d;if(!(b>=2*u/d||y<=b)){var C,B=Number.POSITIVE_INFINITY;for(C=t.level-1;C>p&&!((B=u*f[C].maxBitrate/(6.4*v))<b);C--);if(!(B>=y)){var x=this.bwEstimator.getEstimate();l.logger.warn("Fragment "+t.sn+(e?" part "+e.index:"")+" of level "+t.level+" is loading too slowly and will cause an underbuffer; aborting and switching to level "+C+"\n Current BW estimate: "+(Object(n.isFiniteNumber)(x)?(x/1024).toFixed(3):"Unknown")+" Kb/s\n Estimated load time for current fragment: "+y.toFixed(3)+" s\n Estimated load time for the next fragment: "+B.toFixed(3)+" s\n Time to underbuffer: "+b.toFixed(3)+" s"),r.nextLoadLevel=C,this.bwEstimator.sample(h,c.loaded),this.clearTimer(),t.loader&&(this.fragCurrent=this.partCurrent=null,t.loader.abort()),r.trigger(o.Events.FRAG_LOAD_EMERGENCY_ABORTED,{frag:t,part:e,stats:c})}}}}}},h.onFragLoaded=function(t,e){var r=e.frag,i=e.part;if(r.type===A.PlaylistLevelType.MAIN&&Object(n.isFiniteNumber)(r.sn)){var a=i?i.stats:r.stats,s=i?i.duration:r.duration;if(this.clearTimer(),this.lastLoadedFragLevel=r.level,this._nextAutoLevel=-1,this.hls.config.abrMaxWithRealBitrate){var l=this.hls.levels[r.level],c=(l.loaded?l.loaded.bytes:0)+a.loaded,u=(l.loaded?l.loaded.duration:0)+s;l.loaded={bytes:c,duration:u},l.realBitrate=Math.round(8*c/u)}if(r.bitrateTest){var h={stats:a,frag:r,part:i,id:r.type};this.onFragBuffered(o.Events.FRAG_BUFFERED,h),r.bitrateTest=!1}}},h.onFragBuffered=function(t,e){var r=e.frag,n=e.part,i=n?n.stats:r.stats;if(!i.aborted&&r.type===A.PlaylistLevelType.MAIN&&"initSegment"!==r.sn){var o=i.parsing.end-i.loading.start;this.bwEstimator.sample(o,i.loaded),i.bwEstimate=this.bwEstimator.getEstimate(),r.bitrateTest?this.bitrateTestDelay=o/1e3:this.bitrateTestDelay=0}},h.onError=function(t,e){switch(e.details){case s.ErrorDetails.FRAG_LOAD_ERROR:case s.ErrorDetails.FRAG_LOAD_TIMEOUT:this.clearTimer()}},h.clearTimer=function(){self.clearInterval(this.timer),this.timer=void 0},h.getNextABRAutoLevel=function(){var t=this.fragCurrent,e=this.partCurrent,r=this.hls,n=r.maxAutoLevel,i=r.config,o=r.minAutoLevel,s=r.media,A=e?e.duration:t?t.duration:0,c=s?s.currentTime:0,u=s&&0!==s.playbackRate?Math.abs(s.playbackRate):1,h=this.bwEstimator?this.bwEstimator.getEstimate():i.abrEwmaDefaultEstimate,d=(a.BufferHelper.bufferInfo(s,c,i.maxBufferHole).end-c)/u,f=this.findBestLevel(h,o,n,d,i.abrBandWidthFactor,i.abrBandWidthUpFactor);if(f>=0)return f;l.logger.trace((d?"rebuffering expected":"buffer is empty")+", finding optimal quality level");var p=A?Math.min(A,i.maxStarvationDelay):i.maxStarvationDelay,g=i.abrBandWidthFactor,m=i.abrBandWidthUpFactor;if(!d){var v=this.bitrateTestDelay;v&&(p=(A?Math.min(A,i.maxLoadingDelay):i.maxLoadingDelay)-v,l.logger.trace("bitrate test took "+Math.round(1e3*v)+"ms, set first fragment max fetchDuration to "+Math.round(1e3*p)+" ms"),g=m=1)}return f=this.findBestLevel(h,o,n,d+p,g,m),Math.max(f,0)},h.findBestLevel=function(t,e,r,n,i,o){for(var a,s=this.fragCurrent,A=this.partCurrent,c=this.lastLoadedFragLevel,u=this.hls.levels,h=u[c],d=!(null==h||null===(a=h.details)||void 0===a||!a.live),f=null==h?void 0:h.codecSet,p=A?A.duration:s?s.duration:0,g=r;g>=e;g--){var m=u[g];if(m&&(!f||m.codecSet===f)){var v=m.details,y=(A?null==v?void 0:v.partTarget:null==v?void 0:v.averagetargetduration)||p,w=void 0;w=g<=c?i*t:o*t;var b=u[g].maxBitrate,C=b*y/w;if(l.logger.trace("level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: "+g+"/"+Math.round(w)+"/"+b+"/"+y+"/"+n+"/"+C),w>b&&(!C||d&&!this.bitrateTestDelay||C<n))return g}}return-1},e=t,(r=[{key:"nextAutoLevel",get:function(){var t=this._nextAutoLevel,e=this.bwEstimator;if(!(-1===t||e&&e.canEstimate()))return t;var r=this.getNextABRAutoLevel();return-1!==t&&(r=Math.min(t,r)),r},set:function(t){this._nextAutoLevel=t}}])&&c(e.prototype,r),u&&c(e,u),t}();e.default=u},"./src/controller/audio-stream-controller.ts":
|
|
|
/*!***************************************************!*\
|
|
|
!*** ./src/controller/audio-stream-controller.ts ***!
|
|
|
\***************************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ./base-stream-controller */"./src/controller/base-stream-controller.ts"),o=r(/*! ../events */"./src/events.ts"),a=r(/*! ../utils/buffer-helper */"./src/utils/buffer-helper.ts"),s=r(/*! ./fragment-tracker */"./src/controller/fragment-tracker.ts"),A=r(/*! ../types/level */"./src/types/level.ts"),l=r(/*! ../types/loader */"./src/types/loader.ts"),c=r(/*! ../loader/fragment */"./src/loader/fragment.ts"),u=r(/*! ../demux/chunk-cache */"./src/demux/chunk-cache.ts"),h=r(/*! ../demux/transmuxer-interface */"./src/demux/transmuxer-interface.ts"),d=r(/*! ../types/transmuxer */"./src/types/transmuxer.ts"),f=r(/*! ./fragment-finders */"./src/controller/fragment-finders.ts"),p=r(/*! ../utils/discontinuities */"./src/utils/discontinuities.ts"),g=r(/*! ../errors */"./src/errors.ts"),m=r(/*! ../utils/logger */"./src/utils/logger.ts");function v(){return(v=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}function y(t,e){return(y=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var w=function(t){var e,r;function w(e,r){var n;return(n=t.call(this,e,r,"[audio-stream-controller]")||this).videoBuffer=null,n.videoTrackCC=-1,n.waitingVideoCC=-1,n.audioSwitch=!1,n.trackId=-1,n.waitingData=null,n.mainDetails=null,n.bufferFlushed=!1,n._registerListeners(),n}r=t,(e=w).prototype=Object.create(r.prototype),e.prototype.constructor=e,y(e,r);var b=w.prototype;return b.onHandlerDestroying=function(){this._unregisterListeners(),this.mainDetails=null},b._registerListeners=function(){var t=this.hls;t.on(o.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.on(o.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.on(o.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.on(o.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.on(o.Events.AUDIO_TRACKS_UPDATED,this.onAudioTracksUpdated,this),t.on(o.Events.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),t.on(o.Events.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),t.on(o.Events.ERROR,this.onError,this),t.on(o.Events.BUFFER_RESET,this.onBufferReset,this),t.on(o.Events.BUFFER_CREATED,this.onBufferCreated,this),t.on(o.Events.BUFFER_FLUSHED,this.onBufferFlushed,this),t.on(o.Events.INIT_PTS_FOUND,this.onInitPtsFound,this),t.on(o.Events.FRAG_BUFFERED,this.onFragBuffered,this)},b._unregisterListeners=function(){var t=this.hls;t.off(o.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.off(o.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.off(o.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.off(o.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.off(o.Events.AUDIO_TRACKS_UPDATED,this.onAudioTracksUpdated,this),t.off(o.Events.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),t.off(o.Events.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),t.off(o.Events.ERROR,this.onError,this),t.off(o.Events.BUFFER_RESET,this.onBufferReset,this),t.off(o.Events.BUFFER_CREATED,this.onBufferCreated,this),t.off(o.Events.BUFFER_FLUSHED,this.onBufferFlushed,this),t.off(o.Events.INIT_PTS_FOUND,this.onInitPtsFound,this),t.off(o.Events.FRAG_BUFFERED,this.onFragBuffered,this)},b.onInitPtsFound=function(t,e){var r=e.frag,n=e.id,o=e.initPTS;if("main"===n){var a=r.cc;this.initPTS[r.cc]=o,this.log("InitPTS for cc: "+a+" found from main: "+o),this.videoTrackCC=a,this.state===i.State.WAITING_INIT_PTS&&this.tick()}},b.startLoad=function(t){if(!this.levels)return this.startPosition=t,void(this.state=i.State.STOPPED);var e=this.lastCurrentTime;this.stopLoad(),this.setInterval(100),this.fragLoadError=0,e>0&&-1===t?(this.log("Override startPosition with lastCurrentTime @"+e.toFixed(3)),this.state=i.State.IDLE):(this.loadedmetadata=!1,this.state=i.State.WAITING_TRACK),this.nextLoadPosition=this.startPosition=this.lastCurrentTime=t,this.tick()},b.doTick=function(){switch(this.state){case i.State.IDLE:this.doTickIdle();break;case i.State.WAITING_TRACK:var e,r=this.levels,n=this.trackId,o=null==r||null===(e=r[n])||void 0===e?void 0:e.details;if(o){if(this.waitForCdnTuneIn(o))break;this.state=i.State.WAITING_INIT_PTS}break;case i.State.FRAG_LOADING_WAITING_RETRY:var s,A=performance.now(),l=this.retryDate;(!l||A>=l||null!==(s=this.media)&&void 0!==s&&s.seeking)&&(this.log("RetryDate reached, switch back to IDLE state"),this.state=i.State.IDLE);break;case i.State.WAITING_INIT_PTS:var c=this.waitingData;if(c){var u=c.frag,h=c.part,d=c.cache,p=c.complete;if(void 0!==this.initPTS[u.cc]){this.waitingData=null,this.waitingVideoCC=-1,this.state=i.State.FRAG_LOADING;var g={frag:u,part:h,payload:d.flush(),networkDetails:null};this._handleFragmentLoadProgress(g),p&&t.prototype._handleFragmentLoadComplete.call(this,g)}else if(this.videoTrackCC!==this.waitingVideoCC)m.logger.log("Waiting fragment cc ("+u.cc+") cancelled because video is at cc "+this.videoTrackCC),this.clearWaitingFragment();else{var v=this.getLoadPosition(),y=a.BufferHelper.bufferInfo(this.mediaBuffer,v,this.config.maxBufferHole);Object(f.fragmentWithinToleranceTest)(y.end,this.config.maxFragLookUpTolerance,u)<0&&(m.logger.log("Waiting fragment cc ("+u.cc+") @ "+u.start+" cancelled because another fragment at "+y.end+" is needed"),this.clearWaitingFragment())}}else this.state=i.State.IDLE}this.onTickEnd()},b.clearWaitingFragment=function(){var t=this.waitingData;t&&(this.fragmentTracker.removeFragment(t.frag),this.waitingData=null,this.waitingVideoCC=-1,this.state=i.State.IDLE)},b.onTickEnd=function(){var t=this.media;if(t&&t.readyState){var e=(this.mediaBuffer?this.mediaBuffer:t).buffered;!this.loadedmetadata&&e.length&&(this.loadedmetadata=!0),this.lastCurrentTime=t.currentTime}},b.doTickIdle=function(){var t,e,r=this.hls,n=this.levels,a=this.media,s=this.trackId,A=r.config;if(n&&n[s]&&(a||!this.startFragRequested&&A.startFragPrefetch)){var u=n[s].details;if(!u||u.live&&this.levelLastLoaded!==s||this.waitForCdnTuneIn(u))this.state=i.State.WAITING_TRACK;else{this.bufferFlushed&&(this.bufferFlushed=!1,this.afterBufferFlushed(this.mediaBuffer?this.mediaBuffer:this.media,c.ElementaryStreamTypes.AUDIO,l.PlaylistLevelType.AUDIO));var h=this.getFwdBufferInfo(this.mediaBuffer?this.mediaBuffer:this.media,l.PlaylistLevelType.AUDIO);if(null!==h){var d=h.len,f=this.getMaxBufferLength(),p=this.audioSwitch;if(!(d>=f)||p){if(!p&&this._streamEnded(h,u))return r.trigger(o.Events.BUFFER_EOS,{type:"audio"}),void(this.state=i.State.ENDED);var g=u.fragments[0].start,m=h.end;if(p){var v=this.getLoadPosition();m=v,u.PTSKnown&&v<g&&(h.end>g||h.nextStart)&&(this.log("Alt audio track ahead of main track, seek to start of alt audio track"),a.currentTime=g+.05)}var y=this.getNextFragment(m,u);y?"identity"!==(null===(t=y.decryptdata)||void 0===t?void 0:t.keyFormat)||null!==(e=y.decryptdata)&&void 0!==e&&e.key?this.loadFragment(y,u,m):this.loadKey(y,u):this.bufferFlushed=!0}}}}},b.getMaxBufferLength=function(){var e=t.prototype.getMaxBufferLength.call(this),r=this.getFwdBufferInfo(this.videoBuffer?this.videoBuffer:this.media,l.PlaylistLevelType.MAIN);return null===r?e:Math.max(e,r.len)},b.onMediaDetaching=function(){this.videoBuffer=null,t.prototype.onMediaDetaching.call(this)},b.onAudioTracksUpdated=function(t,e){var r=e.audioTracks;this.resetTransmuxer(),this.levels=r.map((function(t){return new A.Level(t)}))},b.onAudioTrackSwitching=function(t,e){var r=!!e.url;this.trackId=e.id;var n=this.fragCurrent;null!=n&&n.loader&&n.loader.abort(),this.fragCurrent=null,this.clearWaitingFragment(),r?this.setInterval(100):this.resetTransmuxer(),r?(this.audioSwitch=!0,this.state=i.State.IDLE):this.state=i.State.STOPPED,this.tick()},b.onManifestLoading=function(){this.mainDetails=null,this.fragmentTracker.removeAllFragments(),this.startPosition=this.lastCurrentTime=0,this.bufferFlushed=!1},b.onLevelLoaded=function(t,e){this.mainDetails=e.details},b.onAudioTrackLoaded=function(t,e){var r,n=this.levels,o=e.details,a=e.id;if(n){this.log("Track "+a+" loaded ["+o.startSN+","+o.endSN+"],duration:"+o.totalduration);var s=n[a],A=0;if(o.live||null!==(r=s.details)&&void 0!==r&&r.live){var l=this.mainDetails;if(o.fragments[0]||(o.deltaUpdateFailed=!0),o.deltaUpdateFailed||!l)return;!s.details&&o.hasProgramDateTime&&l.hasProgramDateTime?(Object(p.alignMediaPlaylistByPDT)(o,l),A=o.fragments[0].start):A=this.alignPlaylists(o,s.details)}s.details=o,this.levelLastLoaded=a,this.startFragRequested||!this.mainDetails&&o.live||this.setStartPosition(s.details,A),this.state!==i.State.WAITING_TRACK||this.waitForCdnTuneIn(o)||(this.state=i.State.IDLE),this.tick()}else this.warn("Audio tracks were reset while loading level "+a)},b._handleFragmentLoadProgress=function(t){var e,r=t.frag,n=t.part,o=t.payload,a=this.config,s=this.trackId,A=this.levels;if(A){var c=A[s];console.assert(c,"Audio track is defined on fragment load progress");var f=c.details;console.assert(f,"Audio track details are defined on fragment load progress");var p=a.defaultAudioCodec||c.audioCodec||"mp4a.40.2",g=this.transmuxer;g||(g=this.transmuxer=new h.default(this.hls,l.PlaylistLevelType.AUDIO,this._handleTransmuxComplete.bind(this),this._handleTransmuxerFlush.bind(this)));var v=this.initPTS[r.cc],y=null===(e=r.initSegment)||void 0===e?void 0:e.data;if(void 0!==v){var w=n?n.index:-1,b=-1!==w,C=new d.ChunkMetadata(r.level,r.sn,r.stats.chunkCount,o.byteLength,w,b);g.push(o,y,p,"",r,n,f.totalduration,!1,C,v)}else m.logger.log("Unknown video PTS for cc "+r.cc+", waiting for video PTS before demuxing audio frag "+r.sn+" of ["+f.startSN+" ,"+f.endSN+"],track "+s),(this.waitingData=this.waitingData||{frag:r,part:n,cache:new u.default,complete:!1}).cache.push(new Uint8Array(o)),this.waitingVideoCC=this.videoTrackCC,this.state=i.State.WAITING_INIT_PTS}else this.warn("Audio tracks were reset while fragment load was in progress. Fragment "+r.sn+" of level "+r.level+" will not be buffered")},b._handleFragmentLoadComplete=function(e){this.waitingData?this.waitingData.complete=!0:t.prototype._handleFragmentLoadComplete.call(this,e)},b.onBufferReset=function(){this.mediaBuffer=this.videoBuffer=null,this.loadedmetadata=!1},b.onBufferCreated=function(t,e){var r=e.tracks.audio;r&&(this.mediaBuffer=r.buffer),e.tracks.video&&(this.videoBuffer=e.tracks.video.buffer)},b.onFragBuffered=function(t,e){var r=e.frag,n=e.part;r.type===l.PlaylistLevelType.AUDIO&&(this.fragContextChanged(r)?this.warn("Fragment "+r.sn+(n?" p: "+n.index:"")+" of level "+r.level+" finished buffering, but was aborted. state: "+this.state+", audioSwitch: "+this.audioSwitch):("initSegment"!==r.sn&&(this.fragPrevious=r,this.audioSwitch&&(this.audioSwitch=!1,this.hls.trigger(o.Events.AUDIO_TRACK_SWITCHED,{id:this.trackId}))),this.fragBufferedComplete(r,n)))},b.onError=function(e,r){switch(r.details){case g.ErrorDetails.FRAG_LOAD_ERROR:case g.ErrorDetails.FRAG_LOAD_TIMEOUT:case g.ErrorDetails.KEY_LOAD_ERROR:case g.ErrorDetails.KEY_LOAD_TIMEOUT:this.onFragmentOrKeyLoadError(l.PlaylistLevelType.AUDIO,r);break;case g.ErrorDetails.AUDIO_TRACK_LOAD_ERROR:case g.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:this.state!==i.State.ERROR&&this.state!==i.State.STOPPED&&(this.state=r.fatal?i.State.ERROR:i.State.IDLE,this.warn(r.details+" while loading frag, switching to "+this.state+" state"));break;case g.ErrorDetails.BUFFER_FULL_ERROR:if("audio"===r.parent&&(this.state===i.State.PARSING||this.state===i.State.PARSED)){var n=!0,o=this.getFwdBufferInfo(this.mediaBuffer,l.PlaylistLevelType.AUDIO);o&&o.len>.5&&(n=!this.reduceMaxBufferLength(o.len)),n&&(this.warn("Buffer full error also media.currentTime is not buffered, flush audio buffer"),this.fragCurrent=null,t.prototype.flushMainBuffer.call(this,0,Number.POSITIVE_INFINITY,"audio")),this.resetLoadingState()}}},b.onBufferFlushed=function(t,e){e.type===c.ElementaryStreamTypes.AUDIO&&(this.bufferFlushed=!0)},b._handleTransmuxComplete=function(t){var e,r="audio",n=this.hls,a=t.remuxResult,s=t.chunkMeta,A=this.getCurrentContext(s);if(!A)return this.warn("The loading context changed while buffering fragment "+s.sn+" of level "+s.level+". This chunk will not be buffered."),void this.resetLiveStartWhenNotLoaded(s.level);var l=A.frag,u=A.part,h=a.audio,d=a.text,f=a.id3,p=a.initSegment;if(!this.fragContextChanged(l)){if(this.state=i.State.PARSING,this.audioSwitch&&h&&this.completeAudioSwitch(),null!=p&&p.tracks&&(this._bufferInitSegment(p.tracks,l,s),n.trigger(o.Events.FRAG_PARSING_INIT_SEGMENT,{frag:l,id:r,tracks:p.tracks})),h){var g=h.startPTS,m=h.endPTS,y=h.startDTS,w=h.endDTS;u&&(u.elementaryStreams[c.ElementaryStreamTypes.AUDIO]={startPTS:g,endPTS:m,startDTS:y,endDTS:w}),l.setElementaryStreamInfo(c.ElementaryStreamTypes.AUDIO,g,m,y,w),this.bufferFragmentData(h,l,u,s)}if(null!=f&&null!==(e=f.samples)&&void 0!==e&&e.length){var b=v({frag:l,id:r},f);n.trigger(o.Events.FRAG_PARSING_METADATA,b)}if(d){var C=v({frag:l,id:r},d);n.trigger(o.Events.FRAG_PARSING_USERDATA,C)}}},b._bufferInitSegment=function(t,e,r){if(this.state===i.State.PARSING){t.video&&delete t.video;var n=t.audio;if(n){n.levelCodec=n.codec,n.id="audio",this.log("Init audio buffer, container:"+n.container+", codecs[parsed]=["+n.codec+"]"),this.hls.trigger(o.Events.BUFFER_CODECS,t);var a=n.initSegment;if(null!=a&&a.byteLength){var s={type:"audio",frag:e,part:null,chunkMeta:r,parent:e.type,data:a};this.hls.trigger(o.Events.BUFFER_APPENDING,s)}this.tick()}}},b.loadFragment=function(e,r,o){var a=this.fragmentTracker.getState(e);this.fragCurrent=e,(this.audioSwitch||a===s.FragmentState.NOT_LOADED||a===s.FragmentState.PARTIAL)&&("initSegment"===e.sn?this._loadInitSegment(e):r.live&&!Object(n.isFiniteNumber)(this.initPTS[e.cc])?(this.log("Waiting for video PTS in continuity counter "+e.cc+" of live stream before loading audio fragment "+e.sn+" of level "+this.trackId),this.state=i.State.WAITING_INIT_PTS):(this.startFragRequested=!0,t.prototype.loadFragment.call(this,e,r,o)))},b.completeAudioSwitch=function(){var e=this.hls,r=this.media,n=this.trackId;r&&(this.log("Switching audio track : flushing all audio"),t.prototype.flushMainBuffer.call(this,0,Number.POSITIVE_INFINITY,"audio")),this.audioSwitch=!1,e.trigger(o.Events.AUDIO_TRACK_SWITCHED,{id:n})},w}(i.default);e.default=w},"./src/controller/audio-track-controller.ts":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./src/controller/audio-track-controller.ts ***!
|
|
|
\**************************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../events */"./src/events.ts"),i=r(/*! ../errors */"./src/errors.ts"),o=r(/*! ./base-playlist-controller */"./src/controller/base-playlist-controller.ts"),a=r(/*! ../types/loader */"./src/types/loader.ts");function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function A(t,e){return(A=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var l=function(t){var e,r;function o(e){var r;return(r=t.call(this,e,"[audio-track-controller]")||this).tracks=[],r.groupId=null,r.tracksInGroup=[],r.trackId=-1,r.trackName="",r.selectDefaultTrack=!0,r.registerListeners(),r}r=t,(e=o).prototype=Object.create(r.prototype),e.prototype.constructor=e,A(e,r);var l,c,u,h=o.prototype;return h.registerListeners=function(){var t=this.hls;t.on(n.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.on(n.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.on(n.Events.LEVEL_LOADING,this.onLevelLoading,this),t.on(n.Events.LEVEL_SWITCHING,this.onLevelSwitching,this),t.on(n.Events.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),t.on(n.Events.ERROR,this.onError,this)},h.unregisterListeners=function(){var t=this.hls;t.off(n.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.off(n.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.off(n.Events.LEVEL_LOADING,this.onLevelLoading,this),t.off(n.Events.LEVEL_SWITCHING,this.onLevelSwitching,this),t.off(n.Events.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),t.off(n.Events.ERROR,this.onError,this)},h.destroy=function(){this.unregisterListeners(),this.tracks.length=0,this.tracksInGroup.length=0,t.prototype.destroy.call(this)},h.onManifestLoading=function(){this.tracks=[],this.groupId=null,this.tracksInGroup=[],this.trackId=-1,this.trackName="",this.selectDefaultTrack=!0},h.onManifestParsed=function(t,e){this.tracks=e.audioTracks||[]},h.onAudioTrackLoaded=function(t,e){var r=e.id,n=e.details,i=this.tracksInGroup[r];if(i){var o=i.details;i.details=e.details,this.log("audioTrack "+r+" loaded ["+n.startSN+"-"+n.endSN+"]"),r===this.trackId&&(this.retryCount=0,this.playlistLoaded(r,e,o))}else this.warn("Invalid audio track id "+r)},h.onLevelLoading=function(t,e){this.switchLevel(e.level)},h.onLevelSwitching=function(t,e){this.switchLevel(e.level)},h.switchLevel=function(t){var e=this.hls.levels[t];if(null!=e&&e.audioGroupIds){var r=e.audioGroupIds[e.urlId];if(this.groupId!==r){this.groupId=r;var i=this.tracks.filter((function(t){return!r||t.groupId===r}));this.selectDefaultTrack&&!i.some((function(t){return t.default}))&&(this.selectDefaultTrack=!1),this.tracksInGroup=i;var o={audioTracks:i};this.log("Updating audio tracks, "+i.length+' track(s) found in "'+r+'" group-id'),this.hls.trigger(n.Events.AUDIO_TRACKS_UPDATED,o),this.selectInitialTrack()}}},h.onError=function(e,r){t.prototype.onError.call(this,e,r),!r.fatal&&r.context&&r.context.type===a.PlaylistContextType.AUDIO_TRACK&&r.context.id===this.trackId&&r.context.groupId===this.groupId&&this.retryLoadingOrFail(r)},h.setAudioTrack=function(t){var e=this.tracksInGroup;if(t<0||t>=e.length)this.warn("Invalid id passed to audio-track controller");else{this.clearTimer();var r=e[this.trackId];this.log("Now switching to audio-track index "+t);var i=e[t],o=i.id,a=i.groupId,s=void 0===a?"":a,A=i.name,l=i.type,c=i.url;if(this.trackId=t,this.trackName=A,this.selectDefaultTrack=!1,this.hls.trigger(n.Events.AUDIO_TRACK_SWITCHING,{id:o,groupId:s,name:A,type:l,url:c}),!i.details||i.details.live){var u=this.switchParams(i.url,null==r?void 0:r.details);this.loadPlaylist(u)}}},h.selectInitialTrack=function(){var t=this.tracksInGroup;console.assert(t.length,"Initial audio track should be selected when tracks are known");var e=this.trackName,r=this.findTrackId(e)||this.findTrackId();-1!==r?this.setAudioTrack(r):(this.warn("No track found for running audio group-ID: "+this.groupId),this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.MEDIA_ERROR,details:i.ErrorDetails.AUDIO_TRACK_LOAD_ERROR,fatal:!0}))},h.findTrackId=function(t){for(var e=this.tracksInGroup,r=0;r<e.length;r++){var n=e[r];if((!this.selectDefaultTrack||n.default)&&(!t||t===n.name))return n.id}return-1},h.loadPlaylist=function(t){var e=this.tracksInGroup[this.trackId];if(this.shouldLoadTrack(e)){var r=e.id,i=e.groupId,o=e.url;if(t)try{o=t.addDirectives(o)}catch(t){this.warn("Could not construct new URL with HLS Delivery Directives: "+t)}this.log("loading audio-track playlist for id: "+r),this.clearTimer(),this.hls.trigger(n.Events.AUDIO_TRACK_LOADING,{url:o,id:r,groupId:i,deliveryDirectives:t||null})}},l=o,(c=[{key:"audioTracks",get:function(){return this.tracksInGroup}},{key:"audioTrack",get:function(){return this.trackId},set:function(t){this.selectDefaultTrack=!1,this.setAudioTrack(t)}}])&&s(l.prototype,c),u&&s(l,u),o}(o.default);e.default=l},"./src/controller/base-playlist-controller.ts":
|
|
|
/*!****************************************************!*\
|
|
|
!*** ./src/controller/base-playlist-controller.ts ***!
|
|
|
\****************************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return A}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../types/level */"./src/types/level.ts"),o=r(/*! ./level-helper */"./src/controller/level-helper.ts"),a=r(/*! ../utils/logger */"./src/utils/logger.ts"),s=r(/*! ../errors */"./src/errors.ts"),A=function(){function t(t,e){this.hls=void 0,this.timer=-1,this.canLoad=!1,this.retryCount=0,this.log=void 0,this.warn=void 0,this.log=a.logger.log.bind(a.logger,e+":"),this.warn=a.logger.warn.bind(a.logger,e+":"),this.hls=t}var e=t.prototype;return e.destroy=function(){this.clearTimer(),this.hls=this.log=this.warn=null},e.onError=function(t,e){e.fatal&&e.type===s.ErrorTypes.NETWORK_ERROR&&this.clearTimer()},e.clearTimer=function(){clearTimeout(this.timer),this.timer=-1},e.startLoad=function(){this.canLoad=!0,this.retryCount=0,this.loadPlaylist()},e.stopLoad=function(){this.canLoad=!1,this.clearTimer()},e.switchParams=function(t,e){var r=null==e?void 0:e.renditionReports;if(r)for(var o=0;o<r.length;o++){var a=r[o],s=""+a.URI;if(s===t.substr(-s.length)){var A=parseInt(a["LAST-MSN"]),l=parseInt(a["LAST-PART"]);if(e&&this.hls.config.lowLatencyMode){var c=Math.min(e.age-e.partTarget,e.targetduration);void 0!==l&&c>e.partTarget&&(l+=1)}if(Object(n.isFiniteNumber)(A))return new i.HlsUrlParameters(A,Object(n.isFiniteNumber)(l)?l:void 0,i.HlsSkip.No)}}},e.loadPlaylist=function(t){},e.shouldLoadTrack=function(t){return this.canLoad&&t&&!!t.url&&(!t.details||t.details.live)},e.playlistLoaded=function(t,e,r){var n=this,i=e.details,a=e.stats,s=a.loading.end?Math.max(0,self.performance.now()-a.loading.end):0;if(i.advancedDateTime=Date.now()-s,i.live||null!=r&&r.live){if(i.reloaded(r),r&&this.log("live playlist "+t+" "+(i.advanced?"REFRESHED "+i.lastPartSn+"-"+i.lastPartIndex:"MISSED")),r&&i.fragments.length>0&&Object(o.mergeDetails)(r,i),!this.canLoad||!i.live)return;var A,l=void 0,c=void 0;if(i.canBlockReload&&i.endSN&&i.advanced){var u=this.hls.config.lowLatencyMode,h=i.lastPartSn,d=i.endSN,f=i.lastPartIndex,p=h===d;-1!==f?(l=p?d+1:h,c=p?u?0:f:f+1):l=d+1;var g=i.age,m=g+i.ageHeader,v=Math.min(m-i.partTarget,1.5*i.targetduration);if(v>0){if(r&&v>r.tuneInGoal)this.warn("CDN Tune-in goal increased from: "+r.tuneInGoal+" to: "+v+" with playlist age: "+i.age),v=0;else{var y=Math.floor(v/i.targetduration);l+=y,void 0!==c&&(c+=Math.round(v%i.targetduration/i.partTarget)),this.log("CDN Tune-in age: "+i.ageHeader+"s last advanced "+g.toFixed(2)+"s goal: "+v+" skip sn "+y+" to part "+c)}i.tuneInGoal=v}if(A=this.getDeliveryDirectives(i,e.deliveryDirectives,l,c),u||!p)return void this.loadPlaylist(A)}else A=this.getDeliveryDirectives(i,e.deliveryDirectives,l,c);var w=Object(o.computeReloadInterval)(i,a);void 0!==l&&i.canBlockReload&&(w-=i.partTarget||1),this.log("reload live playlist "+t+" in "+Math.round(w)+" ms"),this.timer=self.setTimeout((function(){return n.loadPlaylist(A)}),w)}else this.clearTimer()},e.getDeliveryDirectives=function(t,e,r,n){var o=Object(i.getSkipValue)(t,r);return null!=e&&e.skip&&t.deltaUpdateFailed&&(r=e.msn,n=e.part,o=i.HlsSkip.No),new i.HlsUrlParameters(r,n,o)},e.retryLoadingOrFail=function(t){var e,r=this,n=this.hls.config,i=this.retryCount<n.levelLoadingMaxRetry;if(i)if(this.retryCount++,t.details.indexOf("LoadTimeOut")>-1&&null!==(e=t.context)&&void 0!==e&&e.deliveryDirectives)this.warn("retry playlist loading #"+this.retryCount+' after "'+t.details+'"'),this.loadPlaylist();else{var o=Math.min(Math.pow(2,this.retryCount)*n.levelLoadingRetryDelay,n.levelLoadingMaxRetryTimeout);this.timer=self.setTimeout((function(){return r.loadPlaylist()}),o),this.warn("retry playlist loading #"+this.retryCount+" in "+o+' ms after "'+t.details+'"')}else this.warn('cannot recover from error "'+t.details+'"'),this.clearTimer(),t.fatal=!0;return i},t}()},"./src/controller/base-stream-controller.ts":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./src/controller/base-stream-controller.ts ***!
|
|
|
\**************************************************/
|
|
|
/*! exports provided: State, default */function(t,e,r){"use strict";r.r(e),r.d(e,"State",(function(){return b})),r.d(e,"default",(function(){return C}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../task-loop */"./src/task-loop.ts"),o=r(/*! ./fragment-tracker */"./src/controller/fragment-tracker.ts"),a=r(/*! ../utils/buffer-helper */"./src/utils/buffer-helper.ts"),s=r(/*! ../utils/logger */"./src/utils/logger.ts"),A=r(/*! ../events */"./src/events.ts"),l=r(/*! ../errors */"./src/errors.ts"),c=r(/*! ../types/transmuxer */"./src/types/transmuxer.ts"),u=r(/*! ../utils/mp4-tools */"./src/utils/mp4-tools.ts"),h=r(/*! ../utils/discontinuities */"./src/utils/discontinuities.ts"),d=r(/*! ./fragment-finders */"./src/controller/fragment-finders.ts"),f=r(/*! ./level-helper */"./src/controller/level-helper.ts"),p=r(/*! ../loader/fragment-loader */"./src/loader/fragment-loader.ts"),g=r(/*! ../crypt/decrypter */"./src/crypt/decrypter.ts"),m=r(/*! ../utils/time-ranges */"./src/utils/time-ranges.ts"),v=r(/*! ../types/loader */"./src/types/loader.ts");function y(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function w(t,e){return(w=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var b={STOPPED:"STOPPED",IDLE:"IDLE",KEY_LOADING:"KEY_LOADING",FRAG_LOADING:"FRAG_LOADING",FRAG_LOADING_WAITING_RETRY:"FRAG_LOADING_WAITING_RETRY",WAITING_TRACK:"WAITING_TRACK",PARSING:"PARSING",PARSED:"PARSED",BACKTRACKING:"BACKTRACKING",ENDED:"ENDED",ERROR:"ERROR",WAITING_INIT_PTS:"WAITING_INIT_PTS",WAITING_LEVEL:"WAITING_LEVEL"},C=function(t){var e,r;function i(e,r,n){var i;return(i=t.call(this)||this).hls=void 0,i.fragPrevious=null,i.fragCurrent=null,i.fragmentTracker=void 0,i.transmuxer=null,i._state=b.STOPPED,i.media=void 0,i.mediaBuffer=void 0,i.config=void 0,i.bitrateTest=!1,i.lastCurrentTime=0,i.nextLoadPosition=0,i.startPosition=0,i.loadedmetadata=!1,i.fragLoadError=0,i.retryDate=0,i.levels=null,i.fragmentLoader=void 0,i.levelLastLoaded=null,i.startFragRequested=!1,i.decrypter=void 0,i.initPTS=[],i.onvseeking=null,i.onvended=null,i.logPrefix="",i.log=void 0,i.warn=void 0,i.logPrefix=n,i.log=s.logger.log.bind(s.logger,n+":"),i.warn=s.logger.warn.bind(s.logger,n+":"),i.hls=e,i.fragmentLoader=new p.default(e.config),i.fragmentTracker=r,i.config=e.config,i.decrypter=new g.default(e,e.config),e.on(A.Events.KEY_LOADED,i.onKeyLoaded,function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(i)),i}r=t,(e=i).prototype=Object.create(r.prototype),e.prototype.constructor=e,w(e,r);var C,B,x,E=i.prototype;return E.doTick=function(){this.onTickEnd()},E.onTickEnd=function(){},E.startLoad=function(t){},E.stopLoad=function(){this.fragmentLoader.abort();var t=this.fragCurrent;t&&this.fragmentTracker.removeFragment(t),this.resetTransmuxer(),this.fragCurrent=null,this.fragPrevious=null,this.clearInterval(),this.clearNextTick(),this.state=b.STOPPED},E._streamEnded=function(t,e){var r=this.fragCurrent,n=this.fragmentTracker;if(!e.live&&r&&r.sn===e.endSN&&!t.nextStart){var i=n.getState(r);return i===o.FragmentState.PARTIAL||i===o.FragmentState.OK}return!1},E.onMediaAttached=function(t,e){var r=this.media=this.mediaBuffer=e.media;this.onvseeking=this.onMediaSeeking.bind(this),this.onvended=this.onMediaEnded.bind(this),r.addEventListener("seeking",this.onvseeking),r.addEventListener("ended",this.onvended);var n=this.config;this.levels&&n.autoStartLoad&&this.state===b.STOPPED&&this.startLoad(n.startPosition)},E.onMediaDetaching=function(){var t=this.media;null!=t&&t.ended&&(this.log("MSE detaching and video ended, reset startPosition"),this.startPosition=this.lastCurrentTime=0),t&&(t.removeEventListener("seeking",this.onvseeking),t.removeEventListener("ended",this.onvended),this.onvseeking=this.onvended=null),this.media=this.mediaBuffer=null,this.loadedmetadata=!1,this.fragmentTracker.removeAllFragments(),this.stopLoad()},E.onMediaSeeking=function(){var t=this.config,e=this.fragCurrent,r=this.media,i=this.mediaBuffer,o=this.state,s=r?r.currentTime:0,A=a.BufferHelper.bufferInfo(i||r,s,t.maxBufferHole);if(this.log("media seeking to "+(Object(n.isFiniteNumber)(s)?s.toFixed(3):s)+", state: "+o),o===b.ENDED)this.resetLoadingState();else if(e&&!A.len){var l=t.maxFragLookUpTolerance,c=e.start-l,u=s>e.start+e.duration+l;(s<c||u)&&(u&&e.loader&&(this.log("seeking outside of buffer while fragment load in progress, cancel fragment load"),e.loader.abort()),this.resetLoadingState())}r&&(this.lastCurrentTime=s),this.loadedmetadata||A.len||(this.nextLoadPosition=this.startPosition=s),this.tickImmediate()},E.onMediaEnded=function(){this.startPosition=this.lastCurrentTime=0},E.onKeyLoaded=function(t,e){if(this.state===b.KEY_LOADING&&e.frag===this.fragCurrent&&this.levels){this.state=b.IDLE;var r=this.levels[e.frag.level].details;r&&this.loadFragment(e.frag,r,e.frag.start)}},E.onHandlerDestroying=function(){this.stopLoad(),t.prototype.onHandlerDestroying.call(this)},E.onHandlerDestroyed=function(){this.state=b.STOPPED,this.hls.off(A.Events.KEY_LOADED,this.onKeyLoaded,this),this.fragmentLoader&&this.fragmentLoader.destroy(),this.decrypter&&this.decrypter.destroy(),this.hls=this.log=this.warn=this.decrypter=this.fragmentLoader=this.fragmentTracker=null,t.prototype.onHandlerDestroyed.call(this)},E.loadKey=function(t,e){this.log("Loading key for "+t.sn+" of ["+e.startSN+"-"+e.endSN+"], "+("[stream-controller]"===this.logPrefix?"level":"track")+" "+t.level),this.state=b.KEY_LOADING,this.fragCurrent=t,this.hls.trigger(A.Events.KEY_LOADING,{frag:t})},E.loadFragment=function(t,e,r){this._loadFragForPlayback(t,e,r)},E._loadFragForPlayback=function(t,e,r){var n=this;this._doFragLoad(t,e,r,(function(e){if(n.fragContextChanged(t))return n.warn("Fragment "+t.sn+(e.part?" p: "+e.part.index:"")+" of level "+t.level+" was dropped during download."),void n.fragmentTracker.removeFragment(t);t.stats.chunkCount++,n._handleFragmentLoadProgress(e)})).then((function(e){if(e){n.fragLoadError=0;var r=n.state;if(!n.fragContextChanged(t))return"payload"in e&&(n.log("Loaded fragment "+t.sn+" of level "+t.level),n.hls.trigger(A.Events.FRAG_LOADED,e),n.state===b.BACKTRACKING)?(n.fragmentTracker.backtrack(t,e),void n.resetFragmentLoading(t)):void n._handleFragmentLoadComplete(e);(r===b.FRAG_LOADING||r===b.BACKTRACKING||!n.fragCurrent&&r===b.PARSING)&&(n.fragmentTracker.removeFragment(t),n.state=b.IDLE)}})).catch((function(e){n.warn(e),n.resetFragmentLoading(t)}))},E.flushMainBuffer=function(t,e,r){if(void 0===r&&(r=null),t-e){var n={startOffset:t,endOffset:e,type:r};this.fragLoadError=0,this.hls.trigger(A.Events.BUFFER_FLUSHING,n)}},E._loadInitSegment=function(t){var e=this;this._doFragLoad(t).then((function(r){if(!r||e.fragContextChanged(t)||!e.levels)throw new Error("init load aborted");return r})).then((function(r){var n=e.hls,i=r.payload,o=t.decryptdata;if(i&&i.byteLength>0&&o&&o.key&&o.iv&&"AES-128"===o.method){var a=self.performance.now();return e.decrypter.webCryptoDecrypt(new Uint8Array(i),o.key.buffer,o.iv.buffer).then((function(e){var i=self.performance.now();return n.trigger(A.Events.FRAG_DECRYPTED,{frag:t,payload:e,stats:{tstart:a,tdecrypt:i}}),r.payload=e,r}))}return r})).then((function(r){var n=e.fragCurrent,i=e.hls,o=e.levels;if(!o)throw new Error("init load aborted, missing levels");var a=o[t.level].details;console.assert(a,"Level details are defined when init segment is loaded");var s=t.stats;e.state=b.IDLE,e.fragLoadError=0,t.data=new Uint8Array(r.payload),s.parsing.start=s.buffering.start=self.performance.now(),s.parsing.end=s.buffering.end=self.performance.now(),r.frag===n&&i.trigger(A.Events.FRAG_BUFFERED,{stats:s,frag:n,part:null,id:t.type}),e.tick()})).catch((function(r){e.warn(r),e.resetFragmentLoading(t)}))},E.fragContextChanged=function(t){var e=this.fragCurrent;return!t||!e||t.level!==e.level||t.sn!==e.sn||t.urlId!==e.urlId},E.fragBufferedComplete=function(t,e){var r=this.mediaBuffer?this.mediaBuffer:this.media;this.log("Buffered "+t.type+" sn: "+t.sn+(e?" part: "+e.index:"")+" of "+("[stream-controller]"===this.logPrefix?"level":"track")+" "+t.level+" "+m.default.toString(a.BufferHelper.getBuffered(r))),this.state=b.IDLE,this.tick()},E._handleFragmentLoadComplete=function(t){var e=this.transmuxer;if(e){var r=t.frag,n=t.part,i=t.partsLoaded,o=!i||0===i.length||i.some((function(t){return!t})),a=new c.ChunkMetadata(r.level,r.sn,r.stats.chunkCount+1,0,n?n.index:-1,!o);e.flush(a)}},E._handleFragmentLoadProgress=function(t){},E._doFragLoad=function(t,e,r,i){var o=this;if(void 0===r&&(r=null),!this.levels)throw new Error("frag load aborted, missing levels");if(r=Math.max(t.start,r||0),this.config.lowLatencyMode&&e){var a=e.partList;if(a&&i){r>t.end&&e.fragmentHint&&(t=e.fragmentHint);var s=this.getNextPart(a,t,r);if(s>-1){var l=a[s];return this.log("Loading part sn: "+t.sn+" p: "+l.index+" cc: "+t.cc+" of playlist ["+e.startSN+"-"+e.endSN+"] parts [0-"+s+"-"+(a.length-1)+"] "+("[stream-controller]"===this.logPrefix?"level":"track")+": "+t.level+", target: "+parseFloat(r.toFixed(3))),this.nextLoadPosition=l.start+l.duration,this.state=b.FRAG_LOADING,this.hls.trigger(A.Events.FRAG_LOADING,{frag:t,part:a[s],targetBufferTime:r}),this.doFragPartsLoad(t,a,s,i).catch((function(t){return o.handleFragLoadError(t)}))}if(!t.url||this.loadedEndOfParts(a,r))return Promise.resolve(null)}}return this.log("Loading fragment "+t.sn+" cc: "+t.cc+" "+(e?"of ["+e.startSN+"-"+e.endSN+"] ":"")+("[stream-controller]"===this.logPrefix?"level":"track")+": "+t.level+", target: "+parseFloat(r.toFixed(3))),Object(n.isFiniteNumber)(t.sn)&&!this.bitrateTest&&(this.nextLoadPosition=t.start+t.duration),this.state=b.FRAG_LOADING,this.hls.trigger(A.Events.FRAG_LOADING,{frag:t,targetBufferTime:r}),this.fragmentLoader.load(t,i).catch((function(t){return o.handleFragLoadError(t)}))},E.doFragPartsLoad=function(t,e,r,n){var i=this;return new Promise((function(o,a){var s=[];!function r(l){var c=e[l];i.fragmentLoader.loadPart(t,c,n).then((function(n){s[c.index]=n;var a=n.part;i.hls.trigger(A.Events.FRAG_LOADED,n);var u=e[l+1];if(!u||u.fragment!==t)return o({frag:t,part:a,partsLoaded:s});r(l+1)})).catch(a)}(r)}))},E.handleFragLoadError=function(t){var e=t.data;return e&&e.details===l.ErrorDetails.INTERNAL_ABORTED?this.handleFragLoadAborted(e.frag,e.part):this.hls.trigger(A.Events.ERROR,e),null},E._handleTransmuxerFlush=function(t){var e=this.getCurrentContext(t);if(e&&this.state===b.PARSING){var r=e.frag,n=e.part,i=e.level,o=self.performance.now();r.stats.parsing.end=o,n&&(n.stats.parsing.end=o),this.updateLevelTiming(r,n,i,t.partial)}else this.fragCurrent||(this.state=b.IDLE)},E.getCurrentContext=function(t){var e=this.levels,r=t.level,n=t.sn,i=t.part;if(!e||!e[r])return this.warn("Levels object was unset while buffering fragment "+n+" of level "+r+". The current chunk will not be buffered."),null;var o=e[r],a=i>-1?Object(f.getPartWith)(o,n,i):null,s=a?a.fragment:Object(f.getFragmentWithSN)(o,n,this.fragCurrent);return s?{frag:s,part:a,level:o}:null},E.bufferFragmentData=function(t,e,r,n){if(t&&this.state===b.PARSING){var i=t.data1,o=t.data2,a=i;if(i&&o&&(a=Object(u.appendUint8Array)(i,o)),a&&a.length){var s={type:t.type,frag:e,part:r,chunkMeta:n,parent:e.type,data:a};this.hls.trigger(A.Events.BUFFER_APPENDING,s),t.dropped&&t.independent&&!r&&this.flushBufferGap(e)}}},E.flushBufferGap=function(t){var e=this.media;if(e)if(a.BufferHelper.isBuffered(e,e.currentTime)){var r=e.currentTime,n=a.BufferHelper.bufferInfo(e,r,0),i=t.duration,o=Math.min(2*this.config.maxFragLookUpTolerance,.25*i),s=Math.max(Math.min(t.start-o,n.end-o),r+o);t.start-s>o&&this.flushMainBuffer(s,t.start)}else this.flushMainBuffer(0,t.start)},E.getFwdBufferInfo=function(t,e){var r=this.config,i=this.getLoadPosition();if(!Object(n.isFiniteNumber)(i))return null;var o=a.BufferHelper.bufferInfo(t,i,r.maxBufferHole);if(0===o.len&&void 0!==o.nextStart){var s=this.fragmentTracker.getBufferedFrag(i,e);if(s&&o.nextStart<s.end)return a.BufferHelper.bufferInfo(t,i,Math.max(o.nextStart,r.maxBufferHole))}return o},E.getMaxBufferLength=function(t){var e,r=this.config;return e=t?Math.max(8*r.maxBufferSize/t,r.maxBufferLength):r.maxBufferLength,Math.min(e,r.maxMaxBufferLength)},E.reduceMaxBufferLength=function(t){var e=this.config,r=t||e.maxBufferLength;return e.maxMaxBufferLength>=r&&(e.maxMaxBufferLength/=2,this.warn("Reduce max buffer length to "+e.maxMaxBufferLength+"s"),!0)},E.getNextFragment=function(t,e){var r,n,i=e.fragments,o=i.length;if(!o)return null;var a,s=this.config,A=i[0].start;if(e.live){var l=s.initialLiveManifestSize;if(o<l)return this.warn("Not enough fragments to start playback (have: "+o+", need: "+l+")"),null;e.PTSKnown||this.startFragRequested||-1!==this.startPosition||(a=this.getInitialLiveFragment(e,i),this.startPosition=a?this.hls.liveSyncPosition||a.start:t)}else t<=A&&(a=i[0]);if(!a){var c=s.lowLatencyMode?e.partEnd:e.fragmentEnd;a=this.getFragmentAtPosition(t,c,e)}return null===(r=a)||void 0===r||!r.initSegment||null!==(n=a)&&void 0!==n&&n.initSegment.data||this.bitrateTest||(a=a.initSegment),a},E.getNextPart=function(t,e,r){for(var n=-1,i=!1,o=!0,a=0,s=t.length;a<s;a++){var A=t[a];if(o=o&&!A.independent,n>-1&&r<A.start)break;var l=A.loaded;!l&&(i||A.independent||o)&&A.fragment===e&&(n=a),i=l}return n},E.loadedEndOfParts=function(t,e){var r=t[t.length-1];return r&&e>r.start&&r.loaded},E.getInitialLiveFragment=function(t,e){var r=this.fragPrevious,n=null;if(r){if(t.hasProgramDateTime&&(this.log("Live playlist, switching playlist, load frag with same PDT: "+r.programDateTime),n=Object(d.findFragmentByPDT)(e,r.endProgramDateTime,this.config.maxFragLookUpTolerance)),!n){var i=r.sn+1;if(i>=t.startSN&&i<=t.endSN){var o=e[i-t.startSN];r.cc===o.cc&&(n=o,this.log("Live playlist, switching playlist, load frag with next SN: "+n.sn))}n||(n=Object(d.findFragWithCC)(e,r.cc))&&this.log("Live playlist, switching playlist, load frag with same CC: "+n.sn)}}else{var a=this.hls.liveSyncPosition;null!==a&&(n=this.getFragmentAtPosition(a,this.bitrateTest?t.fragmentEnd:t.edge,t))}return n},E.getFragmentAtPosition=function(t,e,r){var n,i=this.config,a=this.fragPrevious,s=r.fragments,A=r.endSN,l=r.fragmentHint,c=i.maxFragLookUpTolerance,u=!!(i.lowLatencyMode&&r.partList&&l);if(u&&l&&!this.bitrateTest&&(s=s.concat(l),A=l.sn),t<e){var h=t>e-c?0:c;n=Object(d.findFragmentByPTS)(a,s,t,h)}else n=s[s.length-1];if(n){var f=n.sn-r.startSN,p=a&&n.level===a.level,g=s[f+1];if(this.fragmentTracker.getState(n)===o.FragmentState.BACKTRACKED){n=null;for(var m=f;s[m]&&this.fragmentTracker.getState(s[m])===o.FragmentState.BACKTRACKED;)n=a?s[m--]:s[--m];n||(n=g)}else a&&n.sn===a.sn&&!u&&p&&(n.sn<A&&this.fragmentTracker.getState(g)!==o.FragmentState.OK?(this.log("SN "+n.sn+" just loaded, load next one: "+g.sn),n=g):n=null)}return n},E.synchronizeToLiveEdge=function(t){var e=this.config,r=this.media;if(r){var n=this.hls.liveSyncPosition,i=r.currentTime,o=t.fragments[0].start,a=t.edge,s=i>=o-e.maxFragLookUpTolerance&&i<=a;if(null!==n&&r.duration>n&&(i<n||!s)){var A=void 0!==e.liveMaxLatencyDuration?e.liveMaxLatencyDuration:e.liveMaxLatencyDurationCount*t.targetduration;(!s&&r.readyState<4||i<a-A)&&(this.loadedmetadata||(this.nextLoadPosition=n),r.readyState&&(this.warn("Playback: "+i.toFixed(3)+" is located too far from the end of live sliding playlist: "+a+", reset currentTime to : "+n.toFixed(3)),r.currentTime=n))}}},E.alignPlaylists=function(t,e){var r=this.levels,i=this.levelLastLoaded,o=this.fragPrevious,a=null!==i?r[i]:null,s=t.fragments.length;if(!s)return this.warn("No fragments in live playlist"),0;var A=t.fragments[0].start,l=!e,c=t.alignedSliding&&Object(n.isFiniteNumber)(A);if(l||!c&&!A){Object(h.alignStream)(o,a,t);var u=t.fragments[0].start;return this.log("Live playlist sliding: "+u.toFixed(2)+" start-sn: "+(e?e.startSN:"na")+"->"+t.startSN+" prev-sn: "+(o?o.sn:"na")+" fragments: "+s),u}return A},E.waitForCdnTuneIn=function(t){return t.live&&t.canBlockReload&&t.tuneInGoal>Math.max(t.partHoldBack,3*t.partTarget)},E.setStartPosition=function(t,e){var r=this.startPosition;if(r<e&&(r=-1),-1===r||-1===this.lastCurrentTime){var i=t.startTimeOffset;Object(n.isFiniteNumber)(i)?(r=e+i,i<0&&(r+=t.totalduration),r=Math.min(Math.max(e,r),e+t.totalduration),this.log("Start time offset "+i+" found in playlist, adjust startPosition to "+r),this.startPosition=r):t.live?r=this.hls.liveSyncPosition||e:this.startPosition=r=0,this.lastCurrentTime=r}this.nextLoadPosition=r},E.getLoadPosition=function(){var t=this.media,e=0;return this.loadedmetadata&&t?e=t.currentTime:this.nextLoadPosition&&(e=this.nextLoadPosition),e},E.handleFragLoadAborted=function(t,e){this.transmuxer&&"initSegment"!==t.sn&&t.stats.aborted&&(this.warn("Fragment "+t.sn+(e?" part"+e.index:"")+" of level "+t.level+" was aborted"),this.resetFragmentLoading(t))},E.resetFragmentLoading=function(t){this.fragCurrent&&this.fragContextChanged(t)||(this.state=b.IDLE)},E.onFragmentOrKeyLoadError=function(t,e){if(!e.fatal){var r=e.frag;if(r&&r.type===t){var n=this.fragCurrent;console.assert(n&&r.sn===n.sn&&r.level===n.level&&r.urlId===n.urlId,"Frag load error must match current frag to retry");var i=this.config;if(this.fragLoadError+1<=i.fragLoadingMaxRetry){if(this.resetLiveStartWhenNotLoaded(r.level))return;var o=Math.min(Math.pow(2,this.fragLoadError)*i.fragLoadingRetryDelay,i.fragLoadingMaxRetryTimeout);this.warn("Fragment "+r.sn+" of "+t+" "+r.level+" failed to load, retrying in "+o+"ms"),this.retryDate=self.performance.now()+o,this.fragLoadError++,this.state=b.FRAG_LOADING_WAITING_RETRY}else e.levelRetry?(t===v.PlaylistLevelType.AUDIO&&(this.fragCurrent=null),this.fragLoadError=0,this.state=b.IDLE):(s.logger.error(e.details+" reaches max retry, redispatch as fatal ..."),e.fatal=!0,this.hls.stopLoad(),this.state=b.ERROR)}}},E.afterBufferFlushed=function(t,e,r){if(t){var n=a.BufferHelper.getBuffered(t);this.fragmentTracker.detectEvictedFragments(e,n,r),this.state===b.ENDED&&this.resetLoadingState()}},E.resetLoadingState=function(){this.fragCurrent=null,this.fragPrevious=null,this.state=b.IDLE},E.resetLiveStartWhenNotLoaded=function(t){if(!this.loadedmetadata){this.startFragRequested=!1;var e=this.levels?this.levels[t].details:null;if(null!=e&&e.live)return this.startPosition=-1,this.setStartPosition(e,0),this.resetLoadingState(),!0;this.nextLoadPosition=this.startPosition}return!1},E.updateLevelTiming=function(t,e,r,n){var i=this,o=r.details;console.assert(!!o,"level.details must be defined"),Object.keys(t.elementaryStreams).reduce((function(e,a){var s=t.elementaryStreams[a];if(s){var l=s.endPTS-s.startPTS;if(l<=0)return i.warn("Could not parse fragment "+t.sn+" "+a+" duration reliably ("+l+") resetting transmuxer to fallback to playlist timing"),i.resetTransmuxer(),e||!1;var c=n?0:Object(f.updateFragPTSDTS)(o,t,s.startPTS,s.endPTS,s.startDTS,s.endDTS);return i.hls.trigger(A.Events.LEVEL_PTS_UPDATED,{details:o,level:r,drift:c,type:a,frag:t,start:s.startPTS,end:s.endPTS}),!0}return e}),!1)?(this.state=b.PARSED,this.hls.trigger(A.Events.FRAG_PARSED,{frag:t,part:e})):this.resetLoadingState()},E.resetTransmuxer=function(){this.transmuxer&&(this.transmuxer.destroy(),this.transmuxer=null)},C=i,(B=[{key:"state",get:function(){return this._state},set:function(t){var e=this._state;e!==t&&(this._state=t,this.log(e+"->"+t))}}])&&y(C.prototype,B),x&&y(C,x),i}(i.default)},"./src/controller/buffer-controller.ts":
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./src/controller/buffer-controller.ts ***!
|
|
|
\*********************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return d}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../utils/logger */"./src/utils/logger.ts"),a=r(/*! ../errors */"./src/errors.ts"),s=r(/*! ../utils/buffer-helper */"./src/utils/buffer-helper.ts"),A=r(/*! ../utils/mediasource-helper */"./src/utils/mediasource-helper.ts"),l=r(/*! ../loader/fragment */"./src/loader/fragment.ts"),c=r(/*! ./buffer-operation-queue */"./src/controller/buffer-operation-queue.ts"),u=Object(A.getMediaSource)(),h=/([ha]vc.)(?:\.[^.,]+)+/,d=function(){function t(t){var e=this;this.details=null,this._objectUrl=null,this.operationQueue=void 0,this.listeners=void 0,this.hls=void 0,this.bufferCodecEventsExpected=0,this._bufferCodecEventsTotal=0,this.media=null,this.mediaSource=null,this.appendError=0,this.tracks={},this.pendingTracks={},this.sourceBuffer=void 0,this._onMediaSourceOpen=function(){var t=e.hls,r=e.media,n=e.mediaSource;o.logger.log("[buffer-controller]: Media source opened"),r&&(e.updateMediaElementDuration(),t.trigger(i.Events.MEDIA_ATTACHED,{media:r})),n&&n.removeEventListener("sourceopen",e._onMediaSourceOpen),e.checkPendingTracks()},this._onMediaSourceClose=function(){o.logger.log("[buffer-controller]: Media source closed")},this._onMediaSourceEnded=function(){o.logger.log("[buffer-controller]: Media source ended")},this.hls=t,this._initSourceBuffer(),this.registerListeners()}var e=t.prototype;return e.hasSourceTypes=function(){return this.getSourceBufferTypes().length>0||Object.keys(this.pendingTracks).length>0},e.destroy=function(){this.unregisterListeners(),this.details=null},e.registerListeners=function(){var t=this.hls;t.on(i.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),t.on(i.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.on(i.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.on(i.Events.BUFFER_RESET,this.onBufferReset,this),t.on(i.Events.BUFFER_APPENDING,this.onBufferAppending,this),t.on(i.Events.BUFFER_CODECS,this.onBufferCodecs,this),t.on(i.Events.BUFFER_EOS,this.onBufferEos,this),t.on(i.Events.BUFFER_FLUSHING,this.onBufferFlushing,this),t.on(i.Events.LEVEL_UPDATED,this.onLevelUpdated,this),t.on(i.Events.FRAG_PARSED,this.onFragParsed,this),t.on(i.Events.FRAG_CHANGED,this.onFragChanged,this)},e.unregisterListeners=function(){var t=this.hls;t.off(i.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),t.off(i.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.off(i.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.off(i.Events.BUFFER_RESET,this.onBufferReset,this),t.off(i.Events.BUFFER_APPENDING,this.onBufferAppending,this),t.off(i.Events.BUFFER_CODECS,this.onBufferCodecs,this),t.off(i.Events.BUFFER_EOS,this.onBufferEos,this),t.off(i.Events.BUFFER_FLUSHING,this.onBufferFlushing,this),t.off(i.Events.LEVEL_UPDATED,this.onLevelUpdated,this),t.off(i.Events.FRAG_PARSED,this.onFragParsed,this),t.off(i.Events.FRAG_CHANGED,this.onFragChanged,this)},e._initSourceBuffer=function(){this.sourceBuffer={},this.operationQueue=new c.default(this.sourceBuffer),this.listeners={audio:[],video:[],audiovideo:[]}},e.onManifestParsed=function(t,e){var r=2;(e.audio&&!e.video||!e.altAudio)&&(r=1),this.bufferCodecEventsExpected=this._bufferCodecEventsTotal=r,this.details=null,o.logger.log(this.bufferCodecEventsExpected+" bufferCodec event(s) expected")},e.onMediaAttaching=function(t,e){var r=this.media=e.media;if(r&&u){var n=this.mediaSource=new u;n.addEventListener("sourceopen",this._onMediaSourceOpen),n.addEventListener("sourceended",this._onMediaSourceEnded),n.addEventListener("sourceclose",this._onMediaSourceClose),r.src=self.URL.createObjectURL(n),this._objectUrl=r.src}},e.onMediaDetaching=function(){var t=this.media,e=this.mediaSource,r=this._objectUrl;if(e){if(o.logger.log("[buffer-controller]: media source detaching"),"open"===e.readyState)try{e.endOfStream()}catch(t){o.logger.warn("[buffer-controller]: onMediaDetaching: "+t.message+" while calling endOfStream")}this.onBufferReset(),e.removeEventListener("sourceopen",this._onMediaSourceOpen),e.removeEventListener("sourceended",this._onMediaSourceEnded),e.removeEventListener("sourceclose",this._onMediaSourceClose),t&&(r&&self.URL.revokeObjectURL(r),t.src===r?(t.removeAttribute("src"),t.load()):o.logger.warn("[buffer-controller]: media.src was changed by a third party - skip cleanup")),this.mediaSource=null,this.media=null,this._objectUrl=null,this.bufferCodecEventsExpected=this._bufferCodecEventsTotal,this.pendingTracks={},this.tracks={}}this.hls.trigger(i.Events.MEDIA_DETACHED,void 0)},e.onBufferReset=function(){var t=this;this.getSourceBufferTypes().forEach((function(e){var r=t.sourceBuffer[e];try{r&&(t.removeBufferListeners(e),t.mediaSource&&t.mediaSource.removeSourceBuffer(r),t.sourceBuffer[e]=void 0)}catch(t){o.logger.warn("[buffer-controller]: Failed to reset the "+e+" buffer",t)}})),this._initSourceBuffer()},e.onBufferCodecs=function(t,e){var r=this,n=this.getSourceBufferTypes().length;Object.keys(e).forEach((function(t){if(n){var i=r.tracks[t];if(i&&"function"==typeof i.buffer.changeType){var o=e[t],a=o.codec,s=o.levelCodec,A=o.container;if((i.levelCodec||i.codec).replace(h,"$1")!==(s||a).replace(h,"$1")){var l=A+";codecs="+(s||a);r.appendChangeType(t,l)}}}else r.pendingTracks[t]=e[t]})),n||(this.bufferCodecEventsExpected=Math.max(this.bufferCodecEventsExpected-1,0),this.mediaSource&&"open"===this.mediaSource.readyState&&this.checkPendingTracks())},e.appendChangeType=function(t,e){var r=this,n=this.operationQueue,i={execute:function(){var i=r.sourceBuffer[t];i&&(o.logger.log("[buffer-controller]: changing "+t+" sourceBuffer type to "+e),i.changeType(e)),n.shiftAndExecuteNext(t)},onStart:function(){},onComplete:function(){},onError:function(e){o.logger.warn("[buffer-controller]: Failed to change "+t+" SourceBuffer type",e)}};n.append(i,t)},e.onBufferAppending=function(t,e){var r=this,n=this.hls,A=this.operationQueue,l=this.tracks,c=e.data,u=e.type,h=e.frag,d=e.part,f=e.chunkMeta,p=f.buffering[u],g=self.performance.now();p.start=g;var m=h.stats.buffering,v=d?d.stats.buffering:null;0===m.start&&(m.start=g),v&&0===v.start&&(v.start=g);var y=l.audio,w="audio"===u&&1===f.id&&"audio/mpeg"===(null==y?void 0:y.container),b={execute:function(){if(p.executeStart=self.performance.now(),w){var t=r.sourceBuffer[u];if(t){var e=h.start-t.timestampOffset;Math.abs(e)>=.1&&(o.logger.log("[buffer-controller]: Updating audio SourceBuffer timestampOffset to "+h.start+" (delta: "+e+") sn: "+h.sn+")"),t.timestampOffset=h.start)}}r.appendExecutor(c,u)},onStart:function(){},onComplete:function(){var t=self.performance.now();p.executeEnd=p.end=t,0===m.first&&(m.first=t),v&&0===v.first&&(v.first=t);var e=r.sourceBuffer,n={};for(var o in e)n[o]=s.BufferHelper.getBuffered(e[o]);r.appendError=0,r.hls.trigger(i.Events.BUFFER_APPENDED,{type:u,frag:h,part:d,chunkMeta:f,parent:h.type,timeRanges:n})},onError:function(t){o.logger.error("[buffer-controller]: Error encountered while trying to append to the "+u+" SourceBuffer",t);var e={type:a.ErrorTypes.MEDIA_ERROR,parent:h.type,details:a.ErrorDetails.BUFFER_APPEND_ERROR,err:t,fatal:!1};t.code===DOMException.QUOTA_EXCEEDED_ERR?e.details=a.ErrorDetails.BUFFER_FULL_ERROR:(r.appendError++,e.details=a.ErrorDetails.BUFFER_APPEND_ERROR,r.appendError>n.config.appendErrorMaxRetry&&(o.logger.error("[buffer-controller]: Failed "+n.config.appendErrorMaxRetry+" times to append segment in sourceBuffer"),e.fatal=!0)),n.trigger(i.Events.ERROR,e)}};A.append(b,u)},e.onBufferFlushing=function(t,e){var r=this,n=this.operationQueue,a=function(t){return{execute:r.removeExecutor.bind(r,t,e.startOffset,e.endOffset),onStart:function(){},onComplete:function(){r.hls.trigger(i.Events.BUFFER_FLUSHED,{type:t})},onError:function(e){o.logger.warn("[buffer-controller]: Failed to remove from "+t+" SourceBuffer",e)}}};e.type?n.append(a(e.type),e.type):this.getSourceBufferTypes().forEach((function(t){n.append(a(t),t)}))},e.onFragParsed=function(t,e){var r=this,n=e.frag,a=e.part,s=[],A=a?a.elementaryStreams:n.elementaryStreams;A[l.ElementaryStreamTypes.AUDIOVIDEO]?s.push("audiovideo"):(A[l.ElementaryStreamTypes.AUDIO]&&s.push("audio"),A[l.ElementaryStreamTypes.VIDEO]&&s.push("video")),0===s.length&&o.logger.warn("Fragments must have at least one ElementaryStreamType set. type: "+n.type+" level: "+n.level+" sn: "+n.sn),this.blockBuffers((function(){var t=self.performance.now();n.stats.buffering.end=t,a&&(a.stats.buffering.end=t);var e=a?a.stats:n.stats;r.hls.trigger(i.Events.FRAG_BUFFERED,{frag:n,part:a,stats:e,id:n.type})}),s)},e.onFragChanged=function(t,e){this.flushBackBuffer()},e.onBufferEos=function(t,e){var r=this;this.getSourceBufferTypes().reduce((function(t,n){var i=r.sourceBuffer[n];return e.type&&e.type!==n||i&&!i.ended&&(i.ended=!0,o.logger.log("[buffer-controller]: "+n+" sourceBuffer now EOS")),t&&!(i&&!i.ended)}),!0)&&this.blockBuffers((function(){var t=r.mediaSource;t&&"open"===t.readyState&&t.endOfStream()}))},e.onLevelUpdated=function(t,e){var r=e.details;r.fragments.length&&(this.details=r,this.getSourceBufferTypes().length?this.blockBuffers(this.updateMediaElementDuration.bind(this)):this.updateMediaElementDuration())},e.flushBackBuffer=function(){var t=this.hls,e=this.details,r=this.media,o=this.sourceBuffer;if(r&&null!==e){var a=this.getSourceBufferTypes();if(a.length){var A=e.live&&null!==t.config.liveBackBufferLength?t.config.liveBackBufferLength:t.config.backBufferLength;if(Object(n.isFiniteNumber)(A)&&!(A<0)){var l=r.currentTime,c=e.levelTargetDuration,u=Math.max(A,c),h=Math.floor(l/c)*c-u;a.forEach((function(r){var n=o[r];if(n){var a=s.BufferHelper.getBuffered(n);a.length>0&&h>a.start(0)&&(t.trigger(i.Events.BACK_BUFFER_REACHED,{bufferEnd:h}),e.live&&t.trigger(i.Events.LIVE_BACK_BUFFER_REACHED,{bufferEnd:h}),t.trigger(i.Events.BUFFER_FLUSHING,{startOffset:0,endOffset:h,type:r}))}}))}}}},e.updateMediaElementDuration=function(){if(this.details&&this.media&&this.mediaSource&&"open"===this.mediaSource.readyState){var t=this.details,e=this.hls,r=this.media,i=this.mediaSource,a=t.fragments[0].start+t.totalduration,s=r.duration,A=Object(n.isFiniteNumber)(i.duration)?i.duration:0;t.live&&e.config.liveDurationInfinity?(o.logger.log("[buffer-controller]: Media Source duration is set to Infinity"),i.duration=1/0,this.updateSeekableRange(t)):(a>A&&a>s||!Object(n.isFiniteNumber)(s))&&(o.logger.log("[buffer-controller]: Updating Media Source duration to "+a.toFixed(3)),i.duration=a)}},e.updateSeekableRange=function(t){var e=this.mediaSource,r=t.fragments;if(r.length&&t.live&&null!=e&&e.setLiveSeekableRange){var n=Math.max(0,r[0].start),i=Math.max(n,n+t.totalduration);e.setLiveSeekableRange(n,i)}},e.checkPendingTracks=function(){var t=this.bufferCodecEventsExpected,e=this.operationQueue,r=this.pendingTracks,n=Object.keys(r).length;if(n&&!t||2===n){this.createSourceBuffers(r),this.pendingTracks={};var o=this.getSourceBufferTypes();if(0===o.length)return void this.hls.trigger(i.Events.ERROR,{type:a.ErrorTypes.MEDIA_ERROR,details:a.ErrorDetails.BUFFER_INCOMPATIBLE_CODECS_ERROR,fatal:!0,reason:"could not create source buffer for media codec(s)"});o.forEach((function(t){e.executeNext(t)}))}},e.createSourceBuffers=function(t){var e=this.sourceBuffer,r=this.mediaSource;if(!r)throw Error("createSourceBuffers called when mediaSource was null");var n=0;for(var s in t)if(!e[s]){var A=t[s];if(!A)throw Error("source buffer exists for track "+s+", however track does not");var l=A.levelCodec||A.codec,c=A.container+";codecs="+l;o.logger.log("[buffer-controller]: creating sourceBuffer("+c+")");try{var u=e[s]=r.addSourceBuffer(c),h=s;this.addBufferListener(h,"updatestart",this._onSBUpdateStart),this.addBufferListener(h,"updateend",this._onSBUpdateEnd),this.addBufferListener(h,"error",this._onSBUpdateError),this.tracks[s]={buffer:u,codec:l,container:A.container,levelCodec:A.levelCodec,id:A.id},n++}catch(t){o.logger.error("[buffer-controller]: error while trying to add sourceBuffer: "+t.message),this.hls.trigger(i.Events.ERROR,{type:a.ErrorTypes.MEDIA_ERROR,details:a.ErrorDetails.BUFFER_ADD_CODEC_ERROR,fatal:!1,error:t,mimeType:c})}}n&&this.hls.trigger(i.Events.BUFFER_CREATED,{tracks:this.tracks})},e._onSBUpdateStart=function(t){this.operationQueue.current(t).onStart()},e._onSBUpdateEnd=function(t){var e=this.operationQueue;e.current(t).onComplete(),e.shiftAndExecuteNext(t)},e._onSBUpdateError=function(t,e){o.logger.error("[buffer-controller]: "+t+" SourceBuffer error",e),this.hls.trigger(i.Events.ERROR,{type:a.ErrorTypes.MEDIA_ERROR,details:a.ErrorDetails.BUFFER_APPENDING_ERROR,fatal:!1});var r=this.operationQueue.current(t);r&&r.onError(e)},e.removeExecutor=function(t,e,r){var i=this.media,a=this.mediaSource,s=this.operationQueue,A=this.sourceBuffer[t];if(!i||!a||!A)return o.logger.warn("[buffer-controller]: Attempting to remove from the "+t+" SourceBuffer, but it does not exist"),void s.shiftAndExecuteNext(t);var l=Object(n.isFiniteNumber)(i.duration)?i.duration:1/0,c=Object(n.isFiniteNumber)(a.duration)?a.duration:1/0,u=Math.max(0,e),h=Math.min(r,l,c);h>u?(o.logger.log("[buffer-controller]: Removing ["+u+","+h+"] from the "+t+" SourceBuffer"),console.assert(!A.updating,t+" sourceBuffer must not be updating"),A.remove(u,h)):s.shiftAndExecuteNext(t)},e.appendExecutor=function(t,e){var r=this.operationQueue,n=this.sourceBuffer[e];if(!n)return o.logger.warn("[buffer-controller]: Attempting to append to the "+e+" SourceBuffer, but it does not exist"),void r.shiftAndExecuteNext(e);n.ended=!1,console.assert(!n.updating,e+" sourceBuffer must not be updating"),n.appendBuffer(t)},e.blockBuffers=function(t,e){var r=this;if(void 0===e&&(e=this.getSourceBufferTypes()),!e.length)return o.logger.log("[buffer-controller]: Blocking operation requested, but no SourceBuffers exist"),void Promise.resolve(t);var n=this.operationQueue,i=e.map((function(t){return n.appendBlocker(t)}));Promise.all(i).then((function(){t(),e.forEach((function(t){var e=r.sourceBuffer[t];e&&e.updating||n.shiftAndExecuteNext(t)}))}))},e.getSourceBufferTypes=function(){return Object.keys(this.sourceBuffer)},e.addBufferListener=function(t,e,r){var n=this.sourceBuffer[t];if(n){var i=r.bind(this,t);this.listeners[t].push({event:e,listener:i}),n.addEventListener(e,i)}},e.removeBufferListeners=function(t){var e=this.sourceBuffer[t];e&&this.listeners[t].forEach((function(t){e.removeEventListener(t.event,t.listener)}))},t}()},"./src/controller/buffer-operation-queue.ts":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./src/controller/buffer-operation-queue.ts ***!
|
|
|
\**************************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return i}));var n=r(/*! ../utils/logger */"./src/utils/logger.ts"),i=function(){function t(t){this.buffers=void 0,this.queues={video:[],audio:[],audiovideo:[]},this.buffers=t}var e=t.prototype;return e.append=function(t,e){var r=this.queues[e];r.push(t),1===r.length&&this.buffers[e]&&this.executeNext(e)},e.insertAbort=function(t,e){this.queues[e].unshift(t),this.executeNext(e)},e.appendBlocker=function(t){var e,r=new Promise((function(t){e=t})),n={execute:e,onStart:function(){},onComplete:function(){},onError:function(){}};return this.append(n,t),r},e.executeNext=function(t){var e=this.buffers,r=this.queues,i=e[t],o=r[t];if(o.length){var a=o[0];try{a.execute()}catch(e){n.logger.warn("[buffer-operation-queue]: Unhandled exception executing the current operation"),a.onError(e),i&&i.updating||(o.shift(),this.executeNext(t))}}},e.shiftAndExecuteNext=function(t){this.queues[t].shift(),this.executeNext(t)},e.current=function(t){return this.queues[t][0]},t}()},"./src/controller/cap-level-controller.ts":
|
|
|
/*!************************************************!*\
|
|
|
!*** ./src/controller/cap-level-controller.ts ***!
|
|
|
\************************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../events */"./src/events.ts");function i(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var o=function(){function t(t){this.autoLevelCapping=void 0,this.firstLevel=void 0,this.media=void 0,this.restrictedLevels=void 0,this.timer=void 0,this.hls=void 0,this.streamController=void 0,this.clientRect=void 0,this.hls=t,this.autoLevelCapping=Number.POSITIVE_INFINITY,this.firstLevel=-1,this.media=null,this.restrictedLevels=[],this.timer=void 0,this.clientRect=null,this.registerListeners()}var e,r,o,a=t.prototype;return a.setStreamController=function(t){this.streamController=t},a.destroy=function(){this.unregisterListener(),this.hls.config.capLevelToPlayerSize&&this.stopCapping(),this.media=null,this.clientRect=null,this.hls=this.streamController=null},a.registerListeners=function(){var t=this.hls;t.on(n.Events.FPS_DROP_LEVEL_CAPPING,this.onFpsDropLevelCapping,this),t.on(n.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),t.on(n.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.on(n.Events.BUFFER_CODECS,this.onBufferCodecs,this),t.on(n.Events.MEDIA_DETACHING,this.onMediaDetaching,this)},a.unregisterListener=function(){var t=this.hls;t.off(n.Events.FPS_DROP_LEVEL_CAPPING,this.onFpsDropLevelCapping,this),t.off(n.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),t.off(n.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.off(n.Events.BUFFER_CODECS,this.onBufferCodecs,this),t.off(n.Events.MEDIA_DETACHING,this.onMediaDetaching,this)},a.onFpsDropLevelCapping=function(e,r){t.isLevelAllowed(r.droppedLevel,this.restrictedLevels)&&this.restrictedLevels.push(r.droppedLevel)},a.onMediaAttaching=function(t,e){this.media=e.media instanceof HTMLVideoElement?e.media:null},a.onManifestParsed=function(t,e){var r=this.hls;this.restrictedLevels=[],this.firstLevel=e.firstLevel,r.config.capLevelToPlayerSize&&e.video&&this.startCapping()},a.onBufferCodecs=function(t,e){this.hls.config.capLevelToPlayerSize&&e.video&&this.startCapping()},a.onMediaDetaching=function(){this.stopCapping()},a.detectPlayerSize=function(){if(this.media&&this.mediaHeight>0&&this.mediaWidth>0){var t=this.hls.levels;if(t.length){var e=this.hls;e.autoLevelCapping=this.getMaxLevel(t.length-1),e.autoLevelCapping>this.autoLevelCapping&&this.streamController&&this.streamController.nextLevelSwitch(),this.autoLevelCapping=e.autoLevelCapping}}},a.getMaxLevel=function(e){var r=this,n=this.hls.levels;if(!n.length)return-1;var i=n.filter((function(n,i){return t.isLevelAllowed(i,r.restrictedLevels)&&i<=e}));return this.clientRect=null,t.getMaxLevelByMediaSize(i,this.mediaWidth,this.mediaHeight)},a.startCapping=function(){this.timer||(this.autoLevelCapping=Number.POSITIVE_INFINITY,this.hls.firstLevel=this.getMaxLevel(this.firstLevel),self.clearInterval(this.timer),this.timer=self.setInterval(this.detectPlayerSize.bind(this),1e3),this.detectPlayerSize())},a.stopCapping=function(){this.restrictedLevels=[],this.firstLevel=-1,this.autoLevelCapping=Number.POSITIVE_INFINITY,this.timer&&(self.clearInterval(this.timer),this.timer=void 0)},a.getDimensions=function(){if(this.clientRect)return this.clientRect;var t=this.media,e={width:0,height:0};if(t){var r=t.getBoundingClientRect();e.width=r.width,e.height=r.height,e.width||e.height||(e.width=r.right-r.left||t.width||0,e.height=r.bottom-r.top||t.height||0)}return this.clientRect=e,e},t.isLevelAllowed=function(t,e){return void 0===e&&(e=[]),-1===e.indexOf(t)},t.getMaxLevelByMediaSize=function(t,e,r){if(!t||!t.length)return-1;for(var n,i,o=t.length-1,a=0;a<t.length;a+=1){var s=t[a];if((s.width>=e||s.height>=r)&&(n=s,!(i=t[a+1])||n.width!==i.width||n.height!==i.height)){o=a;break}}return o},e=t,o=[{key:"contentScaleFactor",get:function(){var t=1;try{t=self.devicePixelRatio}catch(t){}return t}}],(r=[{key:"mediaWidth",get:function(){return this.getDimensions().width*t.contentScaleFactor}},{key:"mediaHeight",get:function(){return this.getDimensions().height*t.contentScaleFactor}}])&&i(e.prototype,r),o&&i(e,o),t}();e.default=o},"./src/controller/cmcd-controller.ts":
|
|
|
/*!*******************************************!*\
|
|
|
!*** ./src/controller/cmcd-controller.ts ***!
|
|
|
\*******************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return h}));var n=r(/*! ../events */"./src/events.ts"),i=r(/*! ../types/cmcd */"./src/types/cmcd.ts"),o=r(/*! ../utils/buffer-helper */"./src/utils/buffer-helper.ts"),a=r(/*! ../utils/logger */"./src/utils/logger.ts");function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function A(t,e,r){return e&&s(t.prototype,e),r&&s(t,r),t}function l(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(r)return(r=r.call(t)).next.bind(r);if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return c(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?c(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0;return function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function c(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function u(){return(u=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}var h=function(){function t(e){var r=this;this.hls=void 0,this.config=void 0,this.media=void 0,this.sid=void 0,this.cid=void 0,this.useHeaders=!1,this.initialized=!1,this.starved=!1,this.buffering=!0,this.audioBuffer=void 0,this.videoBuffer=void 0,this.onWaiting=function(){r.initialized&&(r.starved=!0),r.buffering=!0},this.onPlaying=function(){r.initialized||(r.initialized=!0),r.buffering=!1},this.applyPlaylistData=function(t){try{r.apply(t,{ot:i.CMCDObjectType.MANIFEST,su:!r.initialized})}catch(t){a.logger.warn("Could not generate manifest CMCD data.",t)}},this.applyFragmentData=function(t){try{var e=t.frag,n=r.hls.levels[e.level],o=r.getObjectType(e),s={d:1e3*e.duration,ot:o};o!==i.CMCDObjectType.VIDEO&&o!==i.CMCDObjectType.AUDIO&&o!=i.CMCDObjectType.MUXED||(s.br=n.bitrate/1e3,s.tb=r.getTopBandwidth(o),s.bl=r.getBufferLength(o)),r.apply(t,s)}catch(t){a.logger.warn("Could not generate segment CMCD data.",t)}},this.hls=e;var n=this.config=e.config,o=n.cmcd;null!=o&&(n.pLoader=this.createPlaylistLoader(),n.fLoader=this.createFragmentLoader(),this.sid=o.sessionId||t.uuid(),this.cid=o.contentId,this.useHeaders=!0===o.useHeaders,this.registerListeners())}var e=t.prototype;return e.registerListeners=function(){var t=this.hls;t.on(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.on(n.Events.MEDIA_DETACHED,this.onMediaDetached,this),t.on(n.Events.BUFFER_CREATED,this.onBufferCreated,this)},e.unregisterListeners=function(){var t=this.hls;t.off(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.off(n.Events.MEDIA_DETACHED,this.onMediaDetached,this),t.off(n.Events.BUFFER_CREATED,this.onBufferCreated,this),this.onMediaDetached()},e.destroy=function(){this.unregisterListeners(),this.hls=this.config=this.audioBuffer=this.videoBuffer=null},e.onMediaAttached=function(t,e){this.media=e.media,this.media.addEventListener("waiting",this.onWaiting),this.media.addEventListener("playing",this.onPlaying)},e.onMediaDetached=function(){this.media&&(this.media.removeEventListener("waiting",this.onWaiting),this.media.removeEventListener("playing",this.onPlaying),this.media=null)},e.onBufferCreated=function(t,e){var r,n;this.audioBuffer=null===(r=e.tracks.audio)||void 0===r?void 0:r.buffer,this.videoBuffer=null===(n=e.tracks.video)||void 0===n?void 0:n.buffer},e.createData=function(){var t;return{v:i.CMCDVersion,sf:i.CMCDStreamingFormat.HLS,sid:this.sid,cid:this.cid,pr:null===(t=this.media)||void 0===t?void 0:t.playbackRate,mtp:this.hls.bandwidthEstimate/1e3}},e.apply=function(e,r){void 0===r&&(r={}),u(r,this.createData());var n=r.ot===i.CMCDObjectType.INIT||r.ot===i.CMCDObjectType.VIDEO||r.ot===i.CMCDObjectType.MUXED;if(this.starved&&n&&(r.bs=!0,r.su=!0,this.starved=!1),null==r.su&&(r.su=this.buffering),this.useHeaders){var o=t.toHeaders(r);if(!Object.keys(o).length)return;e.headers||(e.headers={}),u(e.headers,o)}else{var a=t.toQuery(r);if(!a)return;e.url=t.appendQueryToUri(e.url,a)}},e.getObjectType=function(t){var e=t.type;return"subtitle"===e?i.CMCDObjectType.TIMED_TEXT:"initSegment"===t.sn?i.CMCDObjectType.INIT:"audio"===e?i.CMCDObjectType.AUDIO:"main"===e?this.hls.audioTracks.length?i.CMCDObjectType.VIDEO:i.CMCDObjectType.MUXED:void 0},e.getTopBandwidth=function(t){for(var e,r=0,n=l(t===i.CMCDObjectType.AUDIO?this.hls.audioTracks:this.hls.levels);!(e=n()).done;){var o=e.value;o.bitrate>r&&(r=o.bitrate)}return r>0?r:NaN},e.getBufferLength=function(t){var e=this.hls.media,r=t===i.CMCDObjectType.AUDIO?this.audioBuffer:this.videoBuffer;return r&&e?1e3*o.BufferHelper.bufferInfo(r,e.currentTime,this.config.maxBufferHole).len:NaN},e.createPlaylistLoader=function(){var t=this.config.pLoader,e=this.applyPlaylistData,r=t||this.config.loader;return function(){function t(t){this.loader=void 0,this.loader=new r(t)}var n=t.prototype;return n.destroy=function(){this.loader.destroy()},n.abort=function(){this.loader.abort()},n.load=function(t,r,n){e(t),this.loader.load(t,r,n)},A(t,[{key:"stats",get:function(){return this.loader.stats}},{key:"context",get:function(){return this.loader.context}}]),t}()},e.createFragmentLoader=function(){var t=this.config.fLoader,e=this.applyFragmentData,r=t||this.config.loader;return function(){function t(t){this.loader=void 0,this.loader=new r(t)}var n=t.prototype;return n.destroy=function(){this.loader.destroy()},n.abort=function(){this.loader.abort()},n.load=function(t,r,n){e(t),this.loader.load(t,r,n)},A(t,[{key:"stats",get:function(){return this.loader.stats}},{key:"context",get:function(){return this.loader.context}}]),t}()},t.uuid=function(){var t=URL.createObjectURL(new Blob),e=t.toString();return URL.revokeObjectURL(t),e.substr(e.lastIndexOf("/")+1)},t.serialize=function(t){for(var e,r=[],n=function(t){return!Number.isNaN(t)&&null!=t&&""!==t&&!1!==t},i=function(t){return Math.round(t)},o=function(t){return 100*i(t/100)},a={br:i,d:i,bl:o,dl:o,mtp:o,nor:function(t){return encodeURIComponent(t)},rtp:o,tb:i},s=l(Object.keys(t||{}).sort());!(e=s()).done;){var A=e.value,c=t[A];if(n(c)&&!("v"===A&&1===c||"pr"==A&&1===c)){var u=a[A];u&&(c=u(c));var h=typeof c,d=void 0;d="ot"===A||"sf"===A||"st"===A?A+"="+c:"boolean"===h?A:"number"===h?A+"="+c:A+"="+JSON.stringify(c),r.push(d)}}return r.join(",")},t.toHeaders=function(e){for(var r={},n=["Object","Request","Session","Status"],i=[{},{},{},{}],o={br:0,d:0,ot:0,tb:0,bl:1,dl:1,mtp:1,nor:1,nrr:1,su:1,cid:2,pr:2,sf:2,sid:2,st:2,v:2,bs:3,rtp:3},a=0,s=Object.keys(e);a<s.length;a++){var A=s[a];i[null!=o[A]?o[A]:1][A]=e[A]}for(var l=0;l<i.length;l++){var c=t.serialize(i[l]);c&&(r["CMCD-"+n[l]]=c)}return r},t.toQuery=function(e){return"CMCD="+encodeURIComponent(t.serialize(e))},t.appendQueryToUri=function(t,e){if(!e)return t;var r=t.includes("?")?"&":"?";return""+t+r+e},t}()},"./src/controller/eme-controller.ts":
|
|
|
/*!******************************************!*\
|
|
|
!*** ./src/controller/eme-controller.ts ***!
|
|
|
\******************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../events */"./src/events.ts"),i=r(/*! ../errors */"./src/errors.ts"),o=r(/*! ../utils/logger */"./src/utils/logger.ts"),a=r(/*! ../utils/mediakeys-helper */"./src/utils/mediakeys-helper.ts");function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var A=function(){function t(t){this.hls=void 0,this._widevineLicenseUrl=void 0,this._licenseXhrSetup=void 0,this._licenseResponseCallback=void 0,this._emeEnabled=void 0,this._requestMediaKeySystemAccess=void 0,this._drmSystemOptions=void 0,this._config=void 0,this._mediaKeysList=[],this._media=null,this._hasSetMediaKeys=!1,this._requestLicenseFailureCount=0,this.mediaKeysPromise=null,this._onMediaEncrypted=this.onMediaEncrypted.bind(this),this.hls=t,this._config=t.config,this._widevineLicenseUrl=this._config.widevineLicenseUrl,this._licenseXhrSetup=this._config.licenseXhrSetup,this._licenseResponseCallback=this._config.licenseResponseCallback,this._emeEnabled=this._config.emeEnabled,this._requestMediaKeySystemAccess=this._config.requestMediaKeySystemAccessFunc,this._drmSystemOptions=this._config.drmSystemOptions,this._registerListeners()}var e,r,A,l=t.prototype;return l.destroy=function(){this._unregisterListeners(),this.hls=this._onMediaEncrypted=null,this._requestMediaKeySystemAccess=null},l._registerListeners=function(){this.hls.on(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),this.hls.on(n.Events.MEDIA_DETACHED,this.onMediaDetached,this),this.hls.on(n.Events.MANIFEST_PARSED,this.onManifestParsed,this)},l._unregisterListeners=function(){this.hls.off(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),this.hls.off(n.Events.MEDIA_DETACHED,this.onMediaDetached,this),this.hls.off(n.Events.MANIFEST_PARSED,this.onManifestParsed,this)},l.getLicenseServerUrl=function(t){switch(t){case a.KeySystems.WIDEVINE:if(!this._widevineLicenseUrl)break;return this._widevineLicenseUrl}throw new Error('no license server URL configured for key-system "'+t+'"')},l._attemptKeySystemAccess=function(t,e,r){var n=this,i=function(t,e,r,n){switch(t){case a.KeySystems.WIDEVINE:return function(t,e,r){var n={audioCapabilities:[],videoCapabilities:[]};return t.forEach((function(t){n.audioCapabilities.push({contentType:'audio/mp4; codecs="'+t+'"',robustness:r.audioRobustness||""})})),e.forEach((function(t){n.videoCapabilities.push({contentType:'video/mp4; codecs="'+t+'"',robustness:r.videoRobustness||""})})),[n]}(e,r,n);default:throw new Error("Unknown key-system: "+t)}}(t,e,r,this._drmSystemOptions);o.logger.log("Requesting encrypted media key-system access");var s=this.requestMediaKeySystemAccess(t,i);this.mediaKeysPromise=s.then((function(e){return n._onMediaKeySystemAccessObtained(t,e)})),s.catch((function(e){o.logger.error('Failed to obtain key-system "'+t+'" access:',e)}))},l._onMediaKeySystemAccessObtained=function(t,e){var r=this;o.logger.log('Access for key-system "'+t+'" obtained');var n={mediaKeysSessionInitialized:!1,mediaKeySystemAccess:e,mediaKeySystemDomain:t};this._mediaKeysList.push(n);var i=Promise.resolve().then((function(){return e.createMediaKeys()})).then((function(e){return n.mediaKeys=e,o.logger.log('Media-keys created for key-system "'+t+'"'),r._onMediaKeysCreated(),e}));return i.catch((function(t){o.logger.error("Failed to create media-keys:",t)})),i},l._onMediaKeysCreated=function(){var t=this;this._mediaKeysList.forEach((function(e){e.mediaKeysSession||(e.mediaKeysSession=e.mediaKeys.createSession(),t._onNewMediaKeySession(e.mediaKeysSession))}))},l._onNewMediaKeySession=function(t){var e=this;o.logger.log("New key-system session "+t.sessionId),t.addEventListener("message",(function(r){e._onKeySessionMessage(t,r.message)}),!1)},l._onKeySessionMessage=function(t,e){o.logger.log("Got EME message event, creating license request"),this._requestLicense(e,(function(e){o.logger.log("Received license data (length: "+(e?e.byteLength:e)+"), updating key-session"),t.update(e)}))},l.onMediaEncrypted=function(t){var e=this;if(o.logger.log('Media is encrypted using "'+t.initDataType+'" init data type'),!this.mediaKeysPromise)return o.logger.error("Fatal: Media is encrypted but no CDM access or no keys have been requested"),void this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_NO_KEYS,fatal:!0});var r=function(r){e._media&&(e._attemptSetMediaKeys(r),e._generateRequestWithPreferredKeySession(t.initDataType,t.initData))};this.mediaKeysPromise.then(r).catch(r)},l._attemptSetMediaKeys=function(t){if(!this._media)throw new Error("Attempted to set mediaKeys without first attaching a media element");if(!this._hasSetMediaKeys){var e=this._mediaKeysList[0];if(!e||!e.mediaKeys)return o.logger.error("Fatal: Media is encrypted but no CDM access or no keys have been obtained yet"),void this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_NO_KEYS,fatal:!0});o.logger.log("Setting keys for encrypted media"),this._media.setMediaKeys(e.mediaKeys),this._hasSetMediaKeys=!0}},l._generateRequestWithPreferredKeySession=function(t,e){var r=this,a=this._mediaKeysList[0];if(!a)return o.logger.error("Fatal: Media is encrypted but not any key-system access has been obtained yet"),void this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_NO_ACCESS,fatal:!0});if(a.mediaKeysSessionInitialized)o.logger.warn("Key-Session already initialized but requested again");else{var s=a.mediaKeysSession;if(!s)return o.logger.error("Fatal: Media is encrypted but no key-session existing"),void this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_NO_SESSION,fatal:!0});if(!e)return o.logger.warn("Fatal: initData required for generating a key session is null"),void this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_NO_INIT_DATA,fatal:!0});o.logger.log('Generating key-session request for "'+t+'" init data type'),a.mediaKeysSessionInitialized=!0,s.generateRequest(t,e).then((function(){o.logger.debug("Key-session generation succeeded")})).catch((function(t){o.logger.error("Error generating key-session request:",t),r.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_NO_SESSION,fatal:!1})}))}},l._createLicenseXhr=function(t,e,r){var n=new XMLHttpRequest;n.responseType="arraybuffer",n.onreadystatechange=this._onLicenseRequestReadyStageChange.bind(this,n,t,e,r);var i=this._licenseXhrSetup;if(i)try{i.call(this.hls,n,t),i=void 0}catch(t){o.logger.error(t)}try{n.readyState||n.open("POST",t,!0),i&&i.call(this.hls,n,t)}catch(t){throw new Error("issue setting up KeySystem license XHR "+t)}return n},l._onLicenseRequestReadyStageChange=function(t,e,r,a){switch(t.readyState){case 4:if(200===t.status){this._requestLicenseFailureCount=0,o.logger.log("License request succeeded");var s=t.response,A=this._licenseResponseCallback;if(A)try{s=A.call(this.hls,t,e)}catch(t){o.logger.error(t)}a(s)}else{if(o.logger.error("License Request XHR failed ("+e+"). Status: "+t.status+" ("+t.statusText+")"),this._requestLicenseFailureCount++,this._requestLicenseFailureCount>3)return void this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_LICENSE_REQUEST_FAILED,fatal:!0});var l=3-this._requestLicenseFailureCount+1;o.logger.warn("Retrying license request, "+l+" attempts left"),this._requestLicense(r,a)}}},l._generateLicenseRequestChallenge=function(t,e){switch(t.mediaKeySystemDomain){case a.KeySystems.WIDEVINE:return e}throw new Error("unsupported key-system: "+t.mediaKeySystemDomain)},l._requestLicense=function(t,e){o.logger.log("Requesting content license for key-system");var r=this._mediaKeysList[0];if(!r)return o.logger.error("Fatal error: Media is encrypted but no key-system access has been obtained yet"),void this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_NO_ACCESS,fatal:!0});try{var a=this.getLicenseServerUrl(r.mediaKeySystemDomain),s=this._createLicenseXhr(a,t,e);o.logger.log("Sending license request to URL: "+a);var A=this._generateLicenseRequestChallenge(r,t);s.send(A)}catch(t){o.logger.error("Failure requesting DRM license: "+t),this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.KEY_SYSTEM_ERROR,details:i.ErrorDetails.KEY_SYSTEM_LICENSE_REQUEST_FAILED,fatal:!0})}},l.onMediaAttached=function(t,e){if(this._emeEnabled){var r=e.media;this._media=r,r.addEventListener("encrypted",this._onMediaEncrypted)}},l.onMediaDetached=function(){var t=this._media,e=this._mediaKeysList;t&&(t.removeEventListener("encrypted",this._onMediaEncrypted),this._media=null,this._mediaKeysList=[],Promise.all(e.map((function(t){if(t.mediaKeysSession)return t.mediaKeysSession.close().catch((function(){}))}))).then((function(){return t.setMediaKeys(null)})).catch((function(){})))},l.onManifestParsed=function(t,e){if(this._emeEnabled){var r=e.levels.map((function(t){return t.audioCodec})).filter((function(t){return!!t})),n=e.levels.map((function(t){return t.videoCodec})).filter((function(t){return!!t}));this._attemptKeySystemAccess(a.KeySystems.WIDEVINE,r,n)}},e=t,(r=[{key:"requestMediaKeySystemAccess",get:function(){if(!this._requestMediaKeySystemAccess)throw new Error("No requestMediaKeySystemAccess function configured");return this._requestMediaKeySystemAccess}}])&&s(e.prototype,r),A&&s(e,A),t}();e.default=A},"./src/controller/fps-controller.ts":
|
|
|
/*!******************************************!*\
|
|
|
!*** ./src/controller/fps-controller.ts ***!
|
|
|
\******************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../events */"./src/events.ts"),i=r(/*! ../utils/logger */"./src/utils/logger.ts"),o=function(){function t(t){this.hls=void 0,this.isVideoPlaybackQualityAvailable=!1,this.timer=void 0,this.media=null,this.lastTime=void 0,this.lastDroppedFrames=0,this.lastDecodedFrames=0,this.streamController=void 0,this.hls=t,this.registerListeners()}var e=t.prototype;return e.setStreamController=function(t){this.streamController=t},e.registerListeners=function(){this.hls.on(n.Events.MEDIA_ATTACHING,this.onMediaAttaching,this)},e.unregisterListeners=function(){this.hls.off(n.Events.MEDIA_ATTACHING,this.onMediaAttaching)},e.destroy=function(){this.timer&&clearInterval(this.timer),this.unregisterListeners(),this.isVideoPlaybackQualityAvailable=!1,this.media=null},e.onMediaAttaching=function(t,e){var r=this.hls.config;if(r.capLevelOnFPSDrop){var n=e.media instanceof self.HTMLVideoElement?e.media:null;this.media=n,n&&"function"==typeof n.getVideoPlaybackQuality&&(this.isVideoPlaybackQualityAvailable=!0),self.clearInterval(this.timer),this.timer=self.setInterval(this.checkFPSInterval.bind(this),r.fpsDroppedMonitoringPeriod)}},e.checkFPS=function(t,e,r){var o=performance.now();if(e){if(this.lastTime){var a=o-this.lastTime,s=r-this.lastDroppedFrames,A=e-this.lastDecodedFrames,l=1e3*s/a,c=this.hls;if(c.trigger(n.Events.FPS_DROP,{currentDropped:s,currentDecoded:A,totalDroppedFrames:r}),l>0&&s>c.config.fpsDroppedMonitoringThreshold*A){var u=c.currentLevel;i.logger.warn("drop FPS ratio greater than max allowed value for currentLevel: "+u),u>0&&(-1===c.autoLevelCapping||c.autoLevelCapping>=u)&&(u-=1,c.trigger(n.Events.FPS_DROP_LEVEL_CAPPING,{level:u,droppedLevel:c.currentLevel}),c.autoLevelCapping=u,this.streamController.nextLevelSwitch())}}this.lastTime=o,this.lastDroppedFrames=r,this.lastDecodedFrames=e}},e.checkFPSInterval=function(){var t=this.media;if(t)if(this.isVideoPlaybackQualityAvailable){var e=t.getVideoPlaybackQuality();this.checkFPS(t,e.totalVideoFrames,e.droppedVideoFrames)}else this.checkFPS(t,t.webkitDecodedFrameCount,t.webkitDroppedFrameCount)},t}();e.default=o},"./src/controller/fragment-finders.ts":
|
|
|
/*!********************************************!*\
|
|
|
!*** ./src/controller/fragment-finders.ts ***!
|
|
|
\********************************************/
|
|
|
/*! exports provided: findFragmentByPDT, findFragmentByPTS, fragmentWithinToleranceTest, pdtWithinToleranceTest, findFragWithCC */function(t,e,r){"use strict";r.r(e),r.d(e,"findFragmentByPDT",(function(){return o})),r.d(e,"findFragmentByPTS",(function(){return a})),r.d(e,"fragmentWithinToleranceTest",(function(){return s})),r.d(e,"pdtWithinToleranceTest",(function(){return A})),r.d(e,"findFragWithCC",(function(){return l}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../utils/binary-search */"./src/utils/binary-search.ts");function o(t,e,r){if(null===e||!Array.isArray(t)||!t.length||!Object(n.isFiniteNumber)(e))return null;if(e<(t[0].programDateTime||0))return null;if(e>=(t[t.length-1].endProgramDateTime||0))return null;r=r||0;for(var i=0;i<t.length;++i){var o=t[i];if(A(e,r,o))return o}return null}function a(t,e,r,n){void 0===r&&(r=0),void 0===n&&(n=0);var o=null;if(t?o=e[t.sn-e[0].sn+1]||null:0===r&&0===e[0].start&&(o=e[0]),o&&0===s(r,n,o))return o;var a=i.default.search(e,s.bind(null,r,n));return a||o}function s(t,e,r){void 0===t&&(t=0),void 0===e&&(e=0);var n=Math.min(e,r.duration+(r.deltaPTS?r.deltaPTS:0));return r.start+r.duration-n<=t?1:r.start-n>t&&r.start?-1:0}function A(t,e,r){var n=1e3*Math.min(e,r.duration+(r.deltaPTS?r.deltaPTS:0));return(r.endProgramDateTime||0)-n>t}function l(t,e){return i.default.search(t,(function(t){return t.cc<e?1:t.cc>e?-1:0}))}},"./src/controller/fragment-tracker.ts":
|
|
|
/*!********************************************!*\
|
|
|
!*** ./src/controller/fragment-tracker.ts ***!
|
|
|
\********************************************/
|
|
|
/*! exports provided: FragmentState, FragmentTracker */function(t,e,r){"use strict";r.r(e),r.d(e,"FragmentState",(function(){return n})),r.d(e,"FragmentTracker",(function(){return a}));var n,i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../types/loader */"./src/types/loader.ts");!function(t){t.NOT_LOADED="NOT_LOADED",t.BACKTRACKED="BACKTRACKED",t.APPENDING="APPENDING",t.PARTIAL="PARTIAL",t.OK="OK"}(n||(n={}));var a=function(){function t(t){this.activeFragment=null,this.activeParts=null,this.fragments=Object.create(null),this.timeRanges=Object.create(null),this.bufferPadding=.2,this.hls=void 0,this.hls=t,this._registerListeners()}var e=t.prototype;return e._registerListeners=function(){var t=this.hls;t.on(i.Events.BUFFER_APPENDED,this.onBufferAppended,this),t.on(i.Events.FRAG_BUFFERED,this.onFragBuffered,this),t.on(i.Events.FRAG_LOADED,this.onFragLoaded,this)},e._unregisterListeners=function(){var t=this.hls;t.off(i.Events.BUFFER_APPENDED,this.onBufferAppended,this),t.off(i.Events.FRAG_BUFFERED,this.onFragBuffered,this),t.off(i.Events.FRAG_LOADED,this.onFragLoaded,this)},e.destroy=function(){this._unregisterListeners(),this.fragments=this.timeRanges=null},e.getAppendedFrag=function(t,e){if(e===o.PlaylistLevelType.MAIN){var r=this.activeFragment,n=this.activeParts;if(!r)return null;if(n)for(var i=n.length;i--;){var a=n[i],s=a?a.end:r.appendedPTS;if(a.start<=t&&void 0!==s&&t<=s)return i>9&&(this.activeParts=n.slice(i-9)),a}else if(r.start<=t&&void 0!==r.appendedPTS&&t<=r.appendedPTS)return r}return this.getBufferedFrag(t,e)},e.getBufferedFrag=function(t,e){for(var r=this.fragments,n=Object.keys(r),i=n.length;i--;){var o=r[n[i]];if((null==o?void 0:o.body.type)===e&&o.buffered){var a=o.body;if(a.start<=t&&t<=a.end)return a}}return null},e.detectEvictedFragments=function(t,e,r){var n=this;Object.keys(this.fragments).forEach((function(i){var o=n.fragments[i];if(o)if(o.buffered){var a=o.range[t];a&&a.time.some((function(t){var r=!n.isTimeBuffered(t.startPTS,t.endPTS,e);return r&&n.removeFragment(o.body),r}))}else o.body.type===r&&n.removeFragment(o.body)}))},e.detectPartialFragments=function(t){var e=this,r=this.timeRanges,n=t.frag,i=t.part;if(r&&"initSegment"!==n.sn){var o=A(n),a=this.fragments[o];a&&(Object.keys(r).forEach((function(t){var o=n.elementaryStreams[t];if(o){var s=r[t],A=null!==i||!0===o.partial;a.range[t]=e.getBufferedTimes(n,i,A,s)}})),a.backtrack=a.loaded=null,Object.keys(a.range).length?a.buffered=!0:this.removeFragment(a.body))}},e.fragBuffered=function(t){var e=A(t),r=this.fragments[e];r&&(r.backtrack=r.loaded=null,r.buffered=!0)},e.getBufferedTimes=function(t,e,r,n){for(var i={time:[],partial:r},o=e?e.start:t.start,a=e?e.end:t.end,s=t.minEndPTS||a,A=t.maxStartPTS||o,l=0;l<n.length;l++){var c=n.start(l)-this.bufferPadding,u=n.end(l)+this.bufferPadding;if(A>=c&&s<=u){i.time.push({startPTS:Math.max(o,n.start(l)),endPTS:Math.min(a,n.end(l))});break}if(o<u&&a>c)i.partial=!0,i.time.push({startPTS:Math.max(o,n.start(l)),endPTS:Math.min(a,n.end(l))});else if(a<=c)break}return i},e.getPartialFragment=function(t){var e,r,n,i=null,o=0,a=this.bufferPadding,A=this.fragments;return Object.keys(A).forEach((function(l){var c=A[l];c&&s(c)&&(r=c.body.start-a,n=c.body.end+a,t>=r&&t<=n&&(e=Math.min(t-r,n-t),o<=e&&(i=c.body,o=e)))})),i},e.getState=function(t){var e=A(t),r=this.fragments[e];return r?r.buffered?s(r)?n.PARTIAL:n.OK:r.backtrack?n.BACKTRACKED:n.APPENDING:n.NOT_LOADED},e.backtrack=function(t,e){var r=A(t),n=this.fragments[r];if(!n||n.backtrack)return null;var i=n.backtrack=e||n.loaded;return n.loaded=null,i},e.getBacktrackData=function(t){var e=A(t),r=this.fragments[e];if(r){var n,i=r.backtrack;if(null!=i&&null!==(n=i.payload)&&void 0!==n&&n.byteLength)return i;this.removeFragment(t)}return null},e.isTimeBuffered=function(t,e,r){for(var n,i,o=0;o<r.length;o++){if(n=r.start(o)-this.bufferPadding,i=r.end(o)+this.bufferPadding,t>=n&&e<=i)return!0;if(e<=n)return!1}return!1},e.onFragLoaded=function(t,e){var r=e.frag,n=e.part;if("initSegment"!==r.sn&&!r.bitrateTest&&!n){var i=A(r);this.fragments[i]={body:r,loaded:e,backtrack:null,buffered:!1,range:Object.create(null)}}},e.onBufferAppended=function(t,e){var r=this,n=e.frag,i=e.part,a=e.timeRanges;if(n.type===o.PlaylistLevelType.MAIN)if(this.activeFragment=n,i){var s=this.activeParts;s||(this.activeParts=s=[]),s.push(i)}else this.activeParts=null;this.timeRanges=a,Object.keys(a).forEach((function(t){var e=a[t];if(r.detectEvictedFragments(t,e),!i)for(var o=0;o<e.length;o++)n.appendedPTS=Math.max(e.end(o),n.appendedPTS||0)}))},e.onFragBuffered=function(t,e){this.detectPartialFragments(e)},e.hasFragment=function(t){var e=A(t);return!!this.fragments[e]},e.removeFragmentsInRange=function(t,e,r){var n=this;Object.keys(this.fragments).forEach((function(i){var o=n.fragments[i];if(o&&o.buffered){var a=o.body;a.type===r&&a.start<e&&a.end>t&&n.removeFragment(a)}}))},e.removeFragment=function(t){var e=A(t);t.stats.loaded=0,t.clearElementaryStreamInfo(),delete this.fragments[e]},e.removeAllFragments=function(){this.fragments=Object.create(null),this.activeFragment=null,this.activeParts=null},t}();function s(t){var e,r;return t.buffered&&((null===(e=t.range.video)||void 0===e?void 0:e.partial)||(null===(r=t.range.audio)||void 0===r?void 0:r.partial))}function A(t){return t.type+"_"+t.level+"_"+t.urlId+"_"+t.sn}},"./src/controller/gap-controller.ts":
|
|
|
/*!******************************************!*\
|
|
|
!*** ./src/controller/gap-controller.ts ***!
|
|
|
\******************************************/
|
|
|
/*! exports provided: STALL_MINIMUM_DURATION_MS, MAX_START_GAP_JUMP, SKIP_BUFFER_HOLE_STEP_SECONDS, SKIP_BUFFER_RANGE_START, default */function(t,e,r){"use strict";r.r(e),r.d(e,"STALL_MINIMUM_DURATION_MS",(function(){return s})),r.d(e,"MAX_START_GAP_JUMP",(function(){return A})),r.d(e,"SKIP_BUFFER_HOLE_STEP_SECONDS",(function(){return l})),r.d(e,"SKIP_BUFFER_RANGE_START",(function(){return c})),r.d(e,"default",(function(){return u}));var n=r(/*! ../utils/buffer-helper */"./src/utils/buffer-helper.ts"),i=r(/*! ../errors */"./src/errors.ts"),o=r(/*! ../events */"./src/events.ts"),a=r(/*! ../utils/logger */"./src/utils/logger.ts"),s=250,A=2,l=.1,c=.05,u=function(){function t(t,e,r,n){this.config=void 0,this.media=void 0,this.fragmentTracker=void 0,this.hls=void 0,this.nudgeRetry=0,this.stallReported=!1,this.stalled=null,this.moved=!1,this.seeking=!1,this.config=t,this.media=e,this.fragmentTracker=r,this.hls=n}var e=t.prototype;return e.destroy=function(){this.hls=this.fragmentTracker=this.media=null},e.poll=function(t){var e=this.config,r=this.media,i=this.stalled,o=r.currentTime,l=r.seeking,c=this.seeking&&!l,u=!this.seeking&&l;if(this.seeking=l,o===t){if((u||c)&&(this.stalled=null),!r.paused&&!r.ended&&0!==r.playbackRate&&n.BufferHelper.getBuffered(r).length){var h=n.BufferHelper.bufferInfo(r,o,0),d=h.len>0,f=h.nextStart||0;if(d||f){if(l){var p=h.len>A,g=!f||f-o>A&&!this.fragmentTracker.getPartialFragment(o);if(p||g)return;this.moved=!1}if(!this.moved&&null!==this.stalled){var m,v=Math.max(f,h.start||0)-o,y=this.hls.levels?this.hls.levels[this.hls.currentLevel]:null,w=(null==y||null===(m=y.details)||void 0===m?void 0:m.live)?2*y.details.targetduration:A;if(v>0&&v<=w)return void this._trySkipBufferHole(null)}var b=self.performance.now();if(null!==i){var C=b-i;!l&&C>=s&&this._reportStall(h.len);var B=n.BufferHelper.bufferInfo(r,o,e.maxBufferHole);this._tryFixBufferStall(B,C)}else this.stalled=b}}}else if(this.moved=!0,null!==i){if(this.stallReported){var x=self.performance.now()-i;a.logger.warn("playback not stuck anymore @"+o+", after "+Math.round(x)+"ms"),this.stallReported=!1}this.stalled=null,this.nudgeRetry=0}},e._tryFixBufferStall=function(t,e){var r=this.config,n=this.fragmentTracker,i=this.media.currentTime,o=n.getPartialFragment(i);o&&this._trySkipBufferHole(o)||t.len>r.maxBufferHole&&e>1e3*r.highBufferWatchdogPeriod&&(a.logger.warn("Trying to nudge playhead over buffer-hole"),this.stalled=null,this._tryNudgeBuffer())},e._reportStall=function(t){var e=this.hls,r=this.media;this.stallReported||(this.stallReported=!0,a.logger.warn("Playback stalling at @"+r.currentTime+" due to low buffer (buffer="+t+")"),e.trigger(o.Events.ERROR,{type:i.ErrorTypes.MEDIA_ERROR,details:i.ErrorDetails.BUFFER_STALLED_ERROR,fatal:!1,buffer:t}))},e._trySkipBufferHole=function(t){for(var e=this.config,r=this.hls,s=this.media,A=s.currentTime,u=0,h=n.BufferHelper.getBuffered(s),d=0;d<h.length;d++){var f=h.start(d);if(A+e.maxBufferHole>=u&&A<f){var p=Math.max(f+c,s.currentTime+l);return a.logger.warn("skipping hole, adjusting currentTime from "+A+" to "+p),this.moved=!0,this.stalled=null,s.currentTime=p,t&&r.trigger(o.Events.ERROR,{type:i.ErrorTypes.MEDIA_ERROR,details:i.ErrorDetails.BUFFER_SEEK_OVER_HOLE,fatal:!1,reason:"fragment loaded with buffer holes, seeking from "+A+" to "+p,frag:t}),p}u=h.end(d)}return 0},e._tryNudgeBuffer=function(){var t=this.config,e=this.hls,r=this.media,n=r.currentTime,s=(this.nudgeRetry||0)+1;if(this.nudgeRetry=s,s<t.nudgeMaxRetry){var A=n+s*t.nudgeOffset;a.logger.warn("Nudging 'currentTime' from "+n+" to "+A),r.currentTime=A,e.trigger(o.Events.ERROR,{type:i.ErrorTypes.MEDIA_ERROR,details:i.ErrorDetails.BUFFER_NUDGE_ON_STALL,fatal:!1})}else a.logger.error("Playhead still not moving while enough data buffered @"+n+" after "+t.nudgeMaxRetry+" nudges"),e.trigger(o.Events.ERROR,{type:i.ErrorTypes.MEDIA_ERROR,details:i.ErrorDetails.BUFFER_STALLED_ERROR,fatal:!0})},t}()},"./src/controller/id3-track-controller.ts":
|
|
|
/*!************************************************!*\
|
|
|
!*** ./src/controller/id3-track-controller.ts ***!
|
|
|
\************************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../events */"./src/events.ts"),i=r(/*! ../utils/texttrack-utils */"./src/utils/texttrack-utils.ts"),o=r(/*! ../demux/id3 */"./src/demux/id3.ts"),a=function(){function t(t){this.hls=void 0,this.id3Track=null,this.media=null,this.hls=t,this._registerListeners()}var e=t.prototype;return e.destroy=function(){this._unregisterListeners()},e._registerListeners=function(){var t=this.hls;t.on(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.on(n.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.on(n.Events.FRAG_PARSING_METADATA,this.onFragParsingMetadata,this),t.on(n.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)},e._unregisterListeners=function(){var t=this.hls;t.off(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.off(n.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.off(n.Events.FRAG_PARSING_METADATA,this.onFragParsingMetadata,this),t.off(n.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)},e.onMediaAttached=function(t,e){this.media=e.media},e.onMediaDetaching=function(){this.id3Track&&(Object(i.clearCurrentCues)(this.id3Track),this.id3Track=null,this.media=null)},e.getID3Track=function(t){if(this.media){for(var e=0;e<t.length;e++){var r=t[e];if("metadata"===r.kind&&"id3"===r.label)return Object(i.sendAddTrackEvent)(r,this.media),r}return this.media.addTextTrack("metadata","id3")}},e.onFragParsingMetadata=function(t,e){if(this.media){var r=e.frag,n=e.samples;this.id3Track||(this.id3Track=this.getID3Track(this.media.textTracks),this.id3Track.mode="hidden");for(var i=self.WebKitDataCue||self.VTTCue||self.TextTrackCue,a=0;a<n.length;a++){var s=o.getID3Frames(n[a].data);if(s){var A=n[a].pts,l=a<n.length-1?n[a+1].pts:r.end;l-A<=0&&(l=A+.25);for(var c=0;c<s.length;c++){var u=s[c];if(!o.isTimeStampFrame(u)){var h=new i(A,l,"");h.value=u,this.id3Track.addCue(h)}}}}}},e.onBufferFlushing=function(t,e){var r=e.startOffset,n=e.endOffset,o=e.type;if(!o||"audio"===o){var a=this.id3Track;a&&Object(i.removeCuesInRange)(a,r,n)}},t}();e.default=a},"./src/controller/latency-controller.ts":
|
|
|
/*!**********************************************!*\
|
|
|
!*** ./src/controller/latency-controller.ts ***!
|
|
|
\**********************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return s}));var n=r(/*! ../errors */"./src/errors.ts"),i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../utils/logger */"./src/utils/logger.ts");function a(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var s=function(){function t(t){var e=this;this.hls=void 0,this.config=void 0,this.media=null,this.levelDetails=null,this.currentTime=0,this.stallCount=0,this._latency=null,this.timeupdateHandler=function(){return e.timeupdate()},this.hls=t,this.config=t.config,this.registerListeners()}var e,r,s,A=t.prototype;return A.destroy=function(){this.unregisterListeners(),this.onMediaDetaching(),this.levelDetails=null,this.hls=this.timeupdateHandler=null},A.registerListeners=function(){this.hls.on(i.Events.MEDIA_ATTACHED,this.onMediaAttached,this),this.hls.on(i.Events.MEDIA_DETACHING,this.onMediaDetaching,this),this.hls.on(i.Events.MANIFEST_LOADING,this.onManifestLoading,this),this.hls.on(i.Events.LEVEL_UPDATED,this.onLevelUpdated,this),this.hls.on(i.Events.ERROR,this.onError,this)},A.unregisterListeners=function(){this.hls.off(i.Events.MEDIA_ATTACHED,this.onMediaAttached),this.hls.off(i.Events.MEDIA_DETACHING,this.onMediaDetaching),this.hls.off(i.Events.MANIFEST_LOADING,this.onManifestLoading),this.hls.off(i.Events.LEVEL_UPDATED,this.onLevelUpdated),this.hls.off(i.Events.ERROR,this.onError)},A.onMediaAttached=function(t,e){this.media=e.media,this.media.addEventListener("timeupdate",this.timeupdateHandler)},A.onMediaDetaching=function(){this.media&&(this.media.removeEventListener("timeupdate",this.timeupdateHandler),this.media=null)},A.onManifestLoading=function(){this.levelDetails=null,this._latency=null,this.stallCount=0},A.onLevelUpdated=function(t,e){var r=e.details;this.levelDetails=r,r.advanced&&this.timeupdate(),!r.live&&this.media&&this.media.removeEventListener("timeupdate",this.timeupdateHandler)},A.onError=function(t,e){e.details===n.ErrorDetails.BUFFER_STALLED_ERROR&&(this.stallCount++,o.logger.warn("[playback-rate-controller]: Stall detected, adjusting target latency"))},A.timeupdate=function(){var t=this.media,e=this.levelDetails;if(t&&e){this.currentTime=t.currentTime;var r=this.computeLatency();if(null!==r){this._latency=r;var n=this.config,i=n.lowLatencyMode,o=n.maxLiveSyncPlaybackRate;if(i&&1!==o){var a=this.targetLatency;if(null!==a){var s=r-a,A=s<Math.min(this.maxLatency,a+e.targetduration);if(e.live&&A&&s>.05&&this.forwardBufferLength>1){var l=Math.min(2,Math.max(1,o)),c=Math.round(2/(1+Math.exp(-.75*s-this.edgeStalled))*20)/20;t.playbackRate=Math.min(l,Math.max(1,c))}else 1!==t.playbackRate&&0!==t.playbackRate&&(t.playbackRate=1)}}}}},A.estimateLiveEdge=function(){var t=this.levelDetails;return null===t?null:t.edge+t.age},A.computeLatency=function(){var t=this.estimateLiveEdge();return null===t?null:t-this.currentTime},e=t,(r=[{key:"latency",get:function(){return this._latency||0}},{key:"maxLatency",get:function(){var t=this.config,e=this.levelDetails;return void 0!==t.liveMaxLatencyDuration?t.liveMaxLatencyDuration:e?t.liveMaxLatencyDurationCount*e.targetduration:0}},{key:"targetLatency",get:function(){var t=this.levelDetails;if(null===t)return null;var e=t.holdBack,r=t.partHoldBack,n=t.targetduration,i=this.config,o=i.liveSyncDuration,a=i.liveSyncDurationCount,s=i.lowLatencyMode,A=this.hls.userConfig,l=s&&r||e;(A.liveSyncDuration||A.liveSyncDurationCount||0===l)&&(l=void 0!==o?o:a*n);var c=n;return l+Math.min(1*this.stallCount,c)}},{key:"liveSyncPosition",get:function(){var t=this.estimateLiveEdge(),e=this.targetLatency,r=this.levelDetails;if(null===t||null===e||null===r)return null;var n=r.edge,i=t-e-this.edgeStalled,o=n-r.totalduration,a=n-(this.config.lowLatencyMode&&r.partTarget||r.targetduration);return Math.min(Math.max(o,i),a)}},{key:"drift",get:function(){var t=this.levelDetails;return null===t?1:t.drift}},{key:"edgeStalled",get:function(){var t=this.levelDetails;if(null===t)return 0;var e=3*(this.config.lowLatencyMode&&t.partTarget||t.targetduration);return Math.max(t.age-e,0)}},{key:"forwardBufferLength",get:function(){var t=this.media,e=this.levelDetails;if(!t||!e)return 0;var r=t.buffered.length;return r?t.buffered.end(r-1):e.edge-this.currentTime}}])&&a(e.prototype,r),s&&a(e,s),t}()},"./src/controller/level-controller.ts":
|
|
|
/*!********************************************!*\
|
|
|
!*** ./src/controller/level-controller.ts ***!
|
|
|
\********************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return f}));var n=r(/*! ../types/level */"./src/types/level.ts"),i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../errors */"./src/errors.ts"),a=r(/*! ../utils/codecs */"./src/utils/codecs.ts"),s=r(/*! ./level-helper */"./src/controller/level-helper.ts"),A=r(/*! ./base-playlist-controller */"./src/controller/base-playlist-controller.ts"),l=r(/*! ../types/loader */"./src/types/loader.ts");function c(){return(c=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}function u(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function h(t,e){return(h=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var d=/chrome|firefox/.test(navigator.userAgent.toLowerCase()),f=function(t){var e,r;function A(e){var r;return(r=t.call(this,e,"[level-controller]")||this)._levels=[],r._firstLevel=-1,r._startLevel=void 0,r.currentLevelIndex=-1,r.manualLevelIndex=-1,r.onParsedComplete=void 0,r._registerListeners(),r}r=t,(e=A).prototype=Object.create(r.prototype),e.prototype.constructor=e,h(e,r);var f,p,g,m=A.prototype;return m._registerListeners=function(){var t=this.hls;t.on(i.Events.MANIFEST_LOADED,this.onManifestLoaded,this),t.on(i.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.on(i.Events.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),t.on(i.Events.FRAG_LOADED,this.onFragLoaded,this),t.on(i.Events.ERROR,this.onError,this)},m._unregisterListeners=function(){var t=this.hls;t.off(i.Events.MANIFEST_LOADED,this.onManifestLoaded,this),t.off(i.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.off(i.Events.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),t.off(i.Events.FRAG_LOADED,this.onFragLoaded,this),t.off(i.Events.ERROR,this.onError,this)},m.destroy=function(){this._unregisterListeners(),this.manualLevelIndex=-1,this._levels.length=0,t.prototype.destroy.call(this)},m.startLoad=function(){this._levels.forEach((function(t){t.loadError=0})),t.prototype.startLoad.call(this)},m.onManifestLoaded=function(t,e){var r,A,l=[],c=[],u=[],h={},f=!1,p=!1,g=!1;if(e.levels.forEach((function(t){var e=t.attrs;f=f||!(!t.width||!t.height),p=p||!!t.videoCodec,g=g||!!t.audioCodec,d&&t.audioCodec&&-1!==t.audioCodec.indexOf("mp4a.40.34")&&(t.audioCodec=void 0);var r=t.bitrate+"-"+t.attrs.RESOLUTION+"-"+t.attrs.CODECS;(A=h[r])?A.url.push(t.url):(A=new n.Level(t),h[r]=A,l.push(A)),e&&(e.AUDIO&&Object(s.addGroupId)(A,"audio",e.AUDIO),e.SUBTITLES&&Object(s.addGroupId)(A,"text",e.SUBTITLES))})),(f||p)&&g&&(l=l.filter((function(t){var e=t.videoCodec,r=t.width,n=t.height;return!!e||!(!r||!n)}))),l=l.filter((function(t){var e=t.audioCodec,r=t.videoCodec;return(!e||Object(a.isCodecSupportedInMp4)(e,"audio"))&&(!r||Object(a.isCodecSupportedInMp4)(r,"video"))})),e.audioTracks&&(c=e.audioTracks.filter((function(t){return!t.audioCodec||Object(a.isCodecSupportedInMp4)(t.audioCodec,"audio")})),Object(s.assignTrackIdsByGroup)(c)),e.subtitles&&(u=e.subtitles,Object(s.assignTrackIdsByGroup)(u)),l.length>0){r=l[0].bitrate,l.sort((function(t,e){return t.bitrate-e.bitrate})),this._levels=l;for(var m=0;m<l.length;m++)if(l[m].bitrate===r){this._firstLevel=m,this.log("manifest loaded, "+l.length+" level(s) found, first bitrate: "+r);break}var v=g&&!p,y={levels:l,audioTracks:c,subtitleTracks:u,firstLevel:this._firstLevel,stats:e.stats,audio:g,video:p,altAudio:!v&&c.some((function(t){return!!t.url}))};this.hls.trigger(i.Events.MANIFEST_PARSED,y),(this.hls.config.autoStartLoad||this.hls.forceStartLoad)&&this.hls.startLoad(this.hls.config.startPosition)}else this.hls.trigger(i.Events.ERROR,{type:o.ErrorTypes.MEDIA_ERROR,details:o.ErrorDetails.MANIFEST_INCOMPATIBLE_CODECS_ERROR,fatal:!0,url:e.url,reason:"no level with compatible codecs found in manifest"})},m.onError=function(e,r){if(t.prototype.onError.call(this,e,r),!r.fatal){var n=r.context,i=this._levels[this.currentLevelIndex];if(n&&(n.type===l.PlaylistContextType.AUDIO_TRACK&&i.audioGroupIds&&n.groupId===i.audioGroupIds[i.urlId]||n.type===l.PlaylistContextType.SUBTITLE_TRACK&&i.textGroupIds&&n.groupId===i.textGroupIds[i.urlId]))this.redundantFailover(this.currentLevelIndex);else{var a,s=!1,A=!0;switch(r.details){case o.ErrorDetails.FRAG_LOAD_ERROR:case o.ErrorDetails.FRAG_LOAD_TIMEOUT:case o.ErrorDetails.KEY_LOAD_ERROR:case o.ErrorDetails.KEY_LOAD_TIMEOUT:if(r.frag){var c=this._levels[r.frag.level];c?(c.fragmentError++,c.fragmentError>this.hls.config.fragLoadingMaxRetry&&(a=r.frag.level)):a=r.frag.level}break;case o.ErrorDetails.LEVEL_LOAD_ERROR:case o.ErrorDetails.LEVEL_LOAD_TIMEOUT:n&&(n.deliveryDirectives&&(A=!1),a=n.level),s=!0;break;case o.ErrorDetails.REMUX_ALLOC_ERROR:a=r.level,s=!0}void 0!==a&&this.recoverLevel(r,a,s,A)}}},m.recoverLevel=function(t,e,r,n){var i=t.details,o=this._levels[e];if(o.loadError++,r){if(!this.retryLoadingOrFail(t))return void(this.currentLevelIndex=-1);t.levelRetry=!0}if(n){var a=o.url.length;if(a>1&&o.loadError<a)t.levelRetry=!0,this.redundantFailover(e);else if(-1===this.manualLevelIndex){var s=0===e?this._levels.length-1:e-1;this.currentLevelIndex!==s&&0===this._levels[s].loadError&&(this.warn(i+": switch to "+s),t.levelRetry=!0,this.hls.nextAutoLevel=s)}}},m.redundantFailover=function(t){var e=this._levels[t],r=e.url.length;if(r>1){var n=(e.urlId+1)%r;this.warn("Switching to redundant URL-id "+n),this._levels.forEach((function(t){t.urlId=n})),this.level=t}},m.onFragLoaded=function(t,e){var r=e.frag;if(void 0!==r&&r.type===l.PlaylistLevelType.MAIN){var n=this._levels[r.level];void 0!==n&&(n.fragmentError=0,n.loadError=0)}},m.onLevelLoaded=function(t,e){var r,n,i=e.level,o=e.details,a=this._levels[i];if(!a)return this.warn("Invalid level index "+i),void(null!==(n=e.deliveryDirectives)&&void 0!==n&&n.skip&&(o.deltaUpdateFailed=!0));i===this.currentLevelIndex?(0===a.fragmentError&&(a.loadError=0,this.retryCount=0),this.playlistLoaded(i,e,a.details)):null!==(r=e.deliveryDirectives)&&void 0!==r&&r.skip&&(o.deltaUpdateFailed=!0)},m.onAudioTrackSwitched=function(t,e){var r=this.hls.levels[this.currentLevelIndex];if(r&&r.audioGroupIds){for(var n=-1,i=this.hls.audioTracks[e.id].groupId,o=0;o<r.audioGroupIds.length;o++)if(r.audioGroupIds[o]===i){n=o;break}n!==r.urlId&&(r.urlId=n,this.startLoad())}},m.loadPlaylist=function(t){var e=this.currentLevelIndex,r=this._levels[e];if(this.canLoad&&r&&r.url.length>0){var n=r.urlId,o=r.url[n];if(t)try{o=t.addDirectives(o)}catch(t){this.warn("Could not construct new URL with HLS Delivery Directives: "+t)}this.log("Attempt loading level index "+e+(t?" at sn "+t.msn+" part "+t.part:"")+" with URL-id "+n+" "+o),this.clearTimer(),this.hls.trigger(i.Events.LEVEL_LOADING,{url:o,level:e,id:n,deliveryDirectives:t||null})}},m.removeLevel=function(t,e){var r=function(t,r){return r!==e},n=this._levels.filter((function(n,i){return i!==t||n.url.length>1&&void 0!==e&&(n.url=n.url.filter(r),n.audioGroupIds&&(n.audioGroupIds=n.audioGroupIds.filter(r)),n.textGroupIds&&(n.textGroupIds=n.textGroupIds.filter(r)),n.urlId=0,!0)})).map((function(t,e){var r=t.details;return null!=r&&r.fragments&&r.fragments.forEach((function(t){t.level=e})),t}));this._levels=n,this.hls.trigger(i.Events.LEVELS_UPDATED,{levels:n})},f=A,(p=[{key:"levels",get:function(){return 0===this._levels.length?null:this._levels}},{key:"level",get:function(){return this.currentLevelIndex},set:function(t){var e,r=this._levels;if(0!==r.length&&(this.currentLevelIndex!==t||null===(e=r[t])||void 0===e||!e.details)){if(t<0||t>=r.length){var n=t<0;if(this.hls.trigger(i.Events.ERROR,{type:o.ErrorTypes.OTHER_ERROR,details:o.ErrorDetails.LEVEL_SWITCH_ERROR,level:t,fatal:n,reason:"invalid level idx"}),n)return;t=Math.min(t,r.length-1)}this.clearTimer();var a=this.currentLevelIndex,s=r[a],A=r[t];this.log("switching to level "+t+" from "+a),this.currentLevelIndex=t;var l=c({},A,{level:t,maxBitrate:A.maxBitrate,uri:A.uri,urlId:A.urlId});delete l._urlId,this.hls.trigger(i.Events.LEVEL_SWITCHING,l);var u=A.details;if(!u||u.live){var h=this.switchParams(A.uri,null==s?void 0:s.details);this.loadPlaylist(h)}}}},{key:"manualLevel",get:function(){return this.manualLevelIndex},set:function(t){this.manualLevelIndex=t,void 0===this._startLevel&&(this._startLevel=t),-1!==t&&(this.level=t)}},{key:"firstLevel",get:function(){return this._firstLevel},set:function(t){this._firstLevel=t}},{key:"startLevel",get:function(){if(void 0===this._startLevel){var t=this.hls.config.startLevel;return void 0!==t?t:this._firstLevel}return this._startLevel},set:function(t){this._startLevel=t}},{key:"nextLoadLevel",get:function(){return-1!==this.manualLevelIndex?this.manualLevelIndex:this.hls.nextAutoLevel},set:function(t){this.level=t,-1===this.manualLevelIndex&&(this.hls.nextAutoLevel=t)}}])&&u(f.prototype,p),g&&u(f,g),A}(A.default)},"./src/controller/level-helper.ts":
|
|
|
/*!****************************************!*\
|
|
|
!*** ./src/controller/level-helper.ts ***!
|
|
|
\****************************************/
|
|
|
/*! exports provided: addGroupId, assignTrackIdsByGroup, updatePTS, updateFragPTSDTS, mergeDetails, mapPartIntersection, mapFragmentIntersection, adjustSliding, addSliding, computeReloadInterval, getFragmentWithSN, getPartWith */function(t,e,r){"use strict";r.r(e),r.d(e,"addGroupId",(function(){return o})),r.d(e,"assignTrackIdsByGroup",(function(){return a})),r.d(e,"updatePTS",(function(){return s})),r.d(e,"updateFragPTSDTS",(function(){return l})),r.d(e,"mergeDetails",(function(){return c})),r.d(e,"mapPartIntersection",(function(){return u})),r.d(e,"mapFragmentIntersection",(function(){return h})),r.d(e,"adjustSliding",(function(){return d})),r.d(e,"addSliding",(function(){return f})),r.d(e,"computeReloadInterval",(function(){return p})),r.d(e,"getFragmentWithSN",(function(){return g})),r.d(e,"getPartWith",(function(){return m}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../utils/logger */"./src/utils/logger.ts");function o(t,e,r){switch(e){case"audio":t.audioGroupIds||(t.audioGroupIds=[]),t.audioGroupIds.push(r);break;case"text":t.textGroupIds||(t.textGroupIds=[]),t.textGroupIds.push(r)}}function a(t){var e={};t.forEach((function(t){var r=t.groupId||"";t.id=e[r]=e[r]||0,e[r]++}))}function s(t,e,r){A(t[e],t[r])}function A(t,e){var r=e.startPTS;if(Object(n.isFiniteNumber)(r)){var i,o=0;e.sn>t.sn?(o=r-t.start,i=t):(o=t.start-r,i=e),i.duration!==o&&(i.duration=o)}else e.sn>t.sn?t.cc===e.cc&&t.minEndPTS?e.start=t.start+(t.minEndPTS-t.start):e.start=t.start+t.duration:e.start=Math.max(t.start-e.duration,0)}function l(t,e,r,o,a,s){o-r<=0&&(i.logger.warn("Fragment should have a positive duration",e),o=r+e.duration,s=a+e.duration);var l=r,c=o,u=e.startPTS,h=e.endPTS;if(Object(n.isFiniteNumber)(u)){var d=Math.abs(u-r);Object(n.isFiniteNumber)(e.deltaPTS)?e.deltaPTS=Math.max(d,e.deltaPTS):e.deltaPTS=d,l=Math.max(r,u),r=Math.min(r,u),a=Math.min(a,e.startDTS),c=Math.min(o,h),o=Math.max(o,h),s=Math.max(s,e.endDTS)}e.duration=o-r;var f=r-e.start;e.appendedPTS=o,e.start=e.startPTS=r,e.maxStartPTS=l,e.startDTS=a,e.endPTS=o,e.minEndPTS=c,e.endDTS=s;var p,g=e.sn;if(!t||g<t.startSN||g>t.endSN)return 0;var m=g-t.startSN,v=t.fragments;for(v[m]=e,p=m;p>0;p--)A(v[p],v[p-1]);for(p=m;p<v.length-1;p++)A(v[p],v[p+1]);return t.fragmentHint&&A(v[v.length-1],t.fragmentHint),t.PTSKnown=t.alignedSliding=!0,f}function c(t,e){for(var r=null,o=t.fragments,a=o.length-1;a>=0;a--){var s=o[a].initSegment;if(s){r=s;break}}t.fragmentHint&&delete t.fragmentHint.endPTS;var A,c=0;if(h(t,e,(function(t,i){t.relurl&&(c=t.cc-i.cc),Object(n.isFiniteNumber)(t.startPTS)&&Object(n.isFiniteNumber)(t.endPTS)&&(i.start=i.startPTS=t.startPTS,i.startDTS=t.startDTS,i.appendedPTS=t.appendedPTS,i.maxStartPTS=t.maxStartPTS,i.endPTS=t.endPTS,i.endDTS=t.endDTS,i.minEndPTS=t.minEndPTS,i.duration=t.endPTS-t.startPTS,i.duration&&(A=i),e.PTSKnown=e.alignedSliding=!0),i.elementaryStreams=t.elementaryStreams,i.loader=t.loader,i.stats=t.stats,i.urlId=t.urlId,t.initSegment&&(i.initSegment=t.initSegment,r=t.initSegment)})),r&&(e.fragmentHint?e.fragments.concat(e.fragmentHint):e.fragments).forEach((function(t){var e;t.initSegment&&t.initSegment.relurl!==(null===(e=r)||void 0===e?void 0:e.relurl)||(t.initSegment=r)})),e.skippedSegments&&(e.deltaUpdateFailed=e.fragments.some((function(t){return!t})),e.deltaUpdateFailed)){i.logger.warn("[level-helper] Previous playlist missing segments skipped in delta playlist");for(var f=e.skippedSegments;f--;)e.fragments.shift();e.startSN=e.fragments[0].sn,e.startCC=e.fragments[0].cc}var p=e.fragments;if(c){i.logger.warn("discontinuity sliding from playlist, take drift into account");for(var g=0;g<p.length;g++)p[g].cc+=c}e.skippedSegments&&(e.startCC=e.fragments[0].cc),u(t.partList,e.partList,(function(t,e){e.elementaryStreams=t.elementaryStreams,e.stats=t.stats})),A?l(e,A,A.startPTS,A.endPTS,A.startDTS,A.endDTS):d(t,e),p.length&&(e.totalduration=e.edge-p[0].start),e.driftStartTime=t.driftStartTime,e.driftStart=t.driftStart;var m=e.advancedDateTime;if(e.advanced&&m){var v=e.edge;e.driftStart||(e.driftStartTime=m,e.driftStart=v),e.driftEndTime=m,e.driftEnd=v}else e.driftEndTime=t.driftEndTime,e.driftEnd=t.driftEnd,e.advancedDateTime=t.advancedDateTime}function u(t,e,r){if(t&&e)for(var n=0,i=0,o=t.length;i<=o;i++){var a=t[i],s=e[i+n];a&&s&&a.index===s.index&&a.fragment.sn===s.fragment.sn?r(a,s):n--}}function h(t,e,r){for(var n=e.skippedSegments,i=Math.max(t.startSN,e.startSN)-e.startSN,o=(t.fragmentHint?1:0)+(n?e.endSN:Math.min(t.endSN,e.endSN))-e.startSN,a=e.startSN-t.startSN,s=e.fragmentHint?e.fragments.concat(e.fragmentHint):e.fragments,A=t.fragmentHint?t.fragments.concat(t.fragmentHint):t.fragments,l=i;l<=o;l++){var c=A[a+l],u=s[l];n&&!u&&l<n&&(u=e.fragments[l]=c),c&&u&&r(c,u)}}function d(t,e){var r=e.startSN+e.skippedSegments-t.startSN,n=t.fragments;r<0||r>=n.length||f(e,n[r].start)}function f(t,e){if(e){for(var r=t.fragments,n=t.skippedSegments;n<r.length;n++)r[n].start+=e;t.fragmentHint&&(t.fragmentHint.start+=e)}}function p(t,e){var r,n=1e3*t.levelTargetDuration,i=n/2,o=t.age,a=o>0&&o<3*n,s=e.loading.end-e.loading.start,A=t.availabilityDelay;if(!1===t.updated)if(a){var l=333*t.misses;r=Math.max(Math.min(i,2*s),l),t.availabilityDelay=(t.availabilityDelay||0)+r}else r=i;else a?(A=Math.min(A||n/2,o),t.availabilityDelay=A,r=A+n-o):r=n-s;return Math.round(r)}function g(t,e,r){if(!t||!t.details)return null;var n=t.details,i=n.fragments[e-n.startSN];return i||((i=n.fragmentHint)&&i.sn===e?i:e<n.startSN&&r&&r.sn===e?r:null)}function m(t,e,r){if(!t||!t.details)return null;var n=t.details.partList;if(n)for(var i=n.length;i--;){var o=n[i];if(o.index===r&&o.fragment.sn===e)return o}return null}},"./src/controller/stream-controller.ts":
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./src/controller/stream-controller.ts ***!
|
|
|
\*********************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return v}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ./base-stream-controller */"./src/controller/base-stream-controller.ts"),o=r(/*! ../is-supported */"./src/is-supported.ts"),a=r(/*! ../events */"./src/events.ts"),s=r(/*! ../utils/buffer-helper */"./src/utils/buffer-helper.ts"),A=r(/*! ./fragment-tracker */"./src/controller/fragment-tracker.ts"),l=r(/*! ../types/loader */"./src/types/loader.ts"),c=r(/*! ../loader/fragment */"./src/loader/fragment.ts"),u=r(/*! ../demux/transmuxer-interface */"./src/demux/transmuxer-interface.ts"),h=r(/*! ../types/transmuxer */"./src/types/transmuxer.ts"),d=r(/*! ./gap-controller */"./src/controller/gap-controller.ts"),f=r(/*! ../errors */"./src/errors.ts"),p=r(/*! ../utils/logger */"./src/utils/logger.ts");function g(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function m(t,e){return(m=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var v=function(t){var e,r;function v(e,r){var n;return(n=t.call(this,e,r,"[stream-controller]")||this).audioCodecSwap=!1,n.gapController=null,n.level=-1,n._forceStartLoad=!1,n.altAudio=!1,n.audioOnly=!1,n.fragPlaying=null,n.onvplaying=null,n.onvseeked=null,n.fragLastKbps=0,n.stalled=!1,n.couldBacktrack=!1,n.audioCodecSwitch=!1,n.videoBuffer=null,n._registerListeners(),n}r=t,(e=v).prototype=Object.create(r.prototype),e.prototype.constructor=e,m(e,r);var y,w,b,C=v.prototype;return C._registerListeners=function(){var t=this.hls;t.on(a.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.on(a.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.on(a.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.on(a.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.on(a.Events.LEVEL_LOADING,this.onLevelLoading,this),t.on(a.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.on(a.Events.FRAG_LOAD_EMERGENCY_ABORTED,this.onFragLoadEmergencyAborted,this),t.on(a.Events.ERROR,this.onError,this),t.on(a.Events.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),t.on(a.Events.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),t.on(a.Events.BUFFER_CREATED,this.onBufferCreated,this),t.on(a.Events.BUFFER_FLUSHED,this.onBufferFlushed,this),t.on(a.Events.LEVELS_UPDATED,this.onLevelsUpdated,this),t.on(a.Events.FRAG_BUFFERED,this.onFragBuffered,this)},C._unregisterListeners=function(){var t=this.hls;t.off(a.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.off(a.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.off(a.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.off(a.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.off(a.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.off(a.Events.FRAG_LOAD_EMERGENCY_ABORTED,this.onFragLoadEmergencyAborted,this),t.off(a.Events.ERROR,this.onError,this),t.off(a.Events.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),t.off(a.Events.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),t.off(a.Events.BUFFER_CREATED,this.onBufferCreated,this),t.off(a.Events.BUFFER_FLUSHED,this.onBufferFlushed,this),t.off(a.Events.LEVELS_UPDATED,this.onLevelsUpdated,this),t.off(a.Events.FRAG_BUFFERED,this.onFragBuffered,this)},C.onHandlerDestroying=function(){this._unregisterListeners(),this.onMediaDetaching()},C.startLoad=function(t){if(this.levels){var e=this.lastCurrentTime,r=this.hls;if(this.stopLoad(),this.setInterval(100),this.level=-1,this.fragLoadError=0,!this.startFragRequested){var n=r.startLevel;-1===n&&(r.config.testBandwidth?(n=0,this.bitrateTest=!0):n=r.nextAutoLevel),this.level=r.nextLoadLevel=n,this.loadedmetadata=!1}e>0&&-1===t&&(this.log("Override startPosition with lastCurrentTime @"+e.toFixed(3)),t=e),this.state=i.State.IDLE,this.nextLoadPosition=this.startPosition=this.lastCurrentTime=t,this.tick()}else this._forceStartLoad=!0,this.state=i.State.STOPPED},C.stopLoad=function(){this._forceStartLoad=!1,t.prototype.stopLoad.call(this)},C.doTick=function(){switch(this.state){case i.State.IDLE:this.doTickIdle();break;case i.State.WAITING_LEVEL:var t,e=this.levels,r=this.level,n=null==e||null===(t=e[r])||void 0===t?void 0:t.details;if(n&&(!n.live||this.levelLastLoaded===this.level)){if(this.waitForCdnTuneIn(n))break;this.state=i.State.IDLE;break}break;case i.State.FRAG_LOADING_WAITING_RETRY:var o,a=self.performance.now(),s=this.retryDate;(!s||a>=s||null!==(o=this.media)&&void 0!==o&&o.seeking)&&(this.log("retryDate reached, switch back to IDLE state"),this.state=i.State.IDLE)}this.onTickEnd()},C.onTickEnd=function(){t.prototype.onTickEnd.call(this),this.checkBuffer(),this.checkFragmentChanged()},C.doTickIdle=function(){var t,e,r=this.hls,n=this.levelLastLoaded,o=this.levels,s=this.media,u=r.config,h=r.nextLoadLevel;if(null!==n&&(s||!this.startFragRequested&&u.startFragPrefetch)&&(!this.altAudio||!this.audioOnly)&&o&&o[h]){var d=o[h];this.level=r.nextLoadLevel=h;var f=d.details;if(!f||this.state===i.State.WAITING_LEVEL||f.live&&this.levelLastLoaded!==h)this.state=i.State.WAITING_LEVEL;else{var p=this.getFwdBufferInfo(this.mediaBuffer?this.mediaBuffer:s,l.PlaylistLevelType.MAIN);if(null!==p&&!(p.len>=this.getMaxBufferLength(d.maxBitrate))){if(this._streamEnded(p,f)){var g={};return this.altAudio&&(g.type="video"),this.hls.trigger(a.Events.BUFFER_EOS,g),void(this.state=i.State.ENDED)}var m=p.end,v=this.getNextFragment(m,f);if(this.couldBacktrack&&!this.fragPrevious&&v&&"initSegment"!==v.sn){var y=v.sn-f.startSN;y>1&&(v=f.fragments[y-1],this.fragmentTracker.removeFragment(v))}if(v&&this.fragmentTracker.getState(v)===A.FragmentState.OK&&this.nextLoadPosition>m){var w=this.audioOnly&&!this.altAudio?c.ElementaryStreamTypes.AUDIO:c.ElementaryStreamTypes.VIDEO;this.afterBufferFlushed(s,w,l.PlaylistLevelType.MAIN),v=this.getNextFragment(this.nextLoadPosition,f)}v&&(!v.initSegment||v.initSegment.data||this.bitrateTest||(v=v.initSegment),"identity"!==(null===(t=v.decryptdata)||void 0===t?void 0:t.keyFormat)||null!==(e=v.decryptdata)&&void 0!==e&&e.key?this.loadFragment(v,f,m):this.loadKey(v,f))}}}},C.loadFragment=function(e,r,n){var i,o=this.fragmentTracker.getState(e);if(this.fragCurrent=e,o===A.FragmentState.BACKTRACKED){var a=this.fragmentTracker.getBacktrackData(e);if(a)return this._handleFragmentLoadProgress(a),void this._handleFragmentLoadComplete(a);o=A.FragmentState.NOT_LOADED}o===A.FragmentState.NOT_LOADED||o===A.FragmentState.PARTIAL?"initSegment"===e.sn?this._loadInitSegment(e):this.bitrateTest?(e.bitrateTest=!0,this.log("Fragment "+e.sn+" of level "+e.level+" is being downloaded to test bitrate and will not be buffered"),this._loadBitrateTestFrag(e)):(this.startFragRequested=!0,t.prototype.loadFragment.call(this,e,r,n)):o===A.FragmentState.APPENDING?this.reduceMaxBufferLength(e.duration)&&this.fragmentTracker.removeFragment(e):0===(null===(i=this.media)||void 0===i?void 0:i.buffered.length)&&this.fragmentTracker.removeAllFragments()},C.getAppendedFrag=function(t){var e=this.fragmentTracker.getAppendedFrag(t,l.PlaylistLevelType.MAIN);return e&&"fragment"in e?e.fragment:e},C.getBufferedFrag=function(t){return this.fragmentTracker.getBufferedFrag(t,l.PlaylistLevelType.MAIN)},C.followingBufferedFrag=function(t){return t?this.getBufferedFrag(t.end+.5):null},C.immediateLevelSwitch=function(){this.abortCurrentFrag(),this.flushMainBuffer(0,Number.POSITIVE_INFINITY)},C.nextLevelSwitch=function(){var t=this.levels,e=this.media;if(null!=e&&e.readyState){var r,n=this.getAppendedFrag(e.currentTime);if(n&&n.start>1&&this.flushMainBuffer(0,n.start-1),!e.paused&&t){var i=t[this.hls.nextLoadLevel],o=this.fragLastKbps;r=o&&this.fragCurrent?this.fragCurrent.duration*i.maxBitrate/(1e3*o)+1:0}else r=0;var a=this.getBufferedFrag(e.currentTime+r);if(a){var s=this.followingBufferedFrag(a);if(s){this.abortCurrentFrag();var A=s.maxStartPTS?s.maxStartPTS:s.start,l=s.duration,c=Math.max(a.end,A+Math.min(Math.max(l-this.config.maxFragLookUpTolerance,.5*l),.75*l));this.flushMainBuffer(c,Number.POSITIVE_INFINITY)}}}},C.abortCurrentFrag=function(){var t=this.fragCurrent;this.fragCurrent=null,null!=t&&t.loader&&t.loader.abort(),this.state===i.State.KEY_LOADING&&(this.state=i.State.IDLE),this.nextLoadPosition=this.getLoadPosition()},C.flushMainBuffer=function(e,r){t.prototype.flushMainBuffer.call(this,e,r,this.altAudio?"video":null)},C.onMediaAttached=function(e,r){t.prototype.onMediaAttached.call(this,e,r);var n=r.media;this.onvplaying=this.onMediaPlaying.bind(this),this.onvseeked=this.onMediaSeeked.bind(this),n.addEventListener("playing",this.onvplaying),n.addEventListener("seeked",this.onvseeked),this.gapController=new d.default(this.config,n,this.fragmentTracker,this.hls)},C.onMediaDetaching=function(){var e=this.media;e&&(e.removeEventListener("playing",this.onvplaying),e.removeEventListener("seeked",this.onvseeked),this.onvplaying=this.onvseeked=null,this.videoBuffer=null),this.fragPlaying=null,this.gapController&&(this.gapController.destroy(),this.gapController=null),t.prototype.onMediaDetaching.call(this)},C.onMediaPlaying=function(){this.tick()},C.onMediaSeeked=function(){var t=this.media,e=t?t.currentTime:null;Object(n.isFiniteNumber)(e)&&this.log("Media seeked to "+e.toFixed(3)),this.tick()},C.onManifestLoading=function(){this.log("Trigger BUFFER_RESET"),this.hls.trigger(a.Events.BUFFER_RESET,void 0),this.fragmentTracker.removeAllFragments(),this.couldBacktrack=this.stalled=!1,this.startPosition=this.lastCurrentTime=0,this.fragPlaying=null},C.onManifestParsed=function(t,e){var r,n=!1,i=!1;e.levels.forEach((function(t){(r=t.audioCodec)&&(-1!==r.indexOf("mp4a.40.2")&&(n=!0),-1!==r.indexOf("mp4a.40.5")&&(i=!0))})),this.audioCodecSwitch=n&&i&&!Object(o.changeTypeSupported)(),this.audioCodecSwitch&&this.log("Both AAC/HE-AAC audio found in levels; declaring level codec as HE-AAC"),this.levels=e.levels,this.startFragRequested=!1},C.onLevelLoading=function(t,e){var r=this.levels;if(r&&this.state===i.State.IDLE){var n=r[e.level];(!n.details||n.details.live&&this.levelLastLoaded!==e.level||this.waitForCdnTuneIn(n.details))&&(this.state=i.State.WAITING_LEVEL)}},C.onLevelLoaded=function(t,e){var r,n=this.levels,o=e.level,s=e.details,A=s.totalduration;if(n){this.log("Level "+o+" loaded ["+s.startSN+","+s.endSN+"], cc ["+s.startCC+", "+s.endCC+"] duration:"+A);var l=this.fragCurrent;!l||this.state!==i.State.FRAG_LOADING&&this.state!==i.State.FRAG_LOADING_WAITING_RETRY||l.level!==e.level&&l.loader&&(this.state=i.State.IDLE,l.loader.abort());var c=n[o],u=0;if(s.live||null!==(r=c.details)&&void 0!==r&&r.live){if(s.fragments[0]||(s.deltaUpdateFailed=!0),s.deltaUpdateFailed)return;u=this.alignPlaylists(s,c.details)}if(c.details=s,this.levelLastLoaded=o,this.hls.trigger(a.Events.LEVEL_UPDATED,{details:s,level:o}),this.state===i.State.WAITING_LEVEL){if(this.waitForCdnTuneIn(s))return;this.state=i.State.IDLE}this.startFragRequested?s.live&&this.synchronizeToLiveEdge(s):this.setStartPosition(s,u),this.tick()}else this.warn("Levels were reset while loading level "+o)},C._handleFragmentLoadProgress=function(t){var e,r=t.frag,n=t.part,i=t.payload,o=this.levels;if(o){var a=o[r.level],s=a.details;if(s){var A=a.videoCodec,c=s.PTSKnown||!s.live,d=null===(e=r.initSegment)||void 0===e?void 0:e.data,f=this._getAudioCodec(a),p=this.transmuxer=this.transmuxer||new u.default(this.hls,l.PlaylistLevelType.MAIN,this._handleTransmuxComplete.bind(this),this._handleTransmuxerFlush.bind(this)),g=n?n.index:-1,m=-1!==g,v=new h.ChunkMetadata(r.level,r.sn,r.stats.chunkCount,i.byteLength,g,m),y=this.initPTS[r.cc];p.push(i,d,f,A,r,n,s.totalduration,c,v,y)}else this.warn("Dropping fragment "+r.sn+" of level "+r.level+" after level details were reset")}else this.warn("Levels were reset while fragment load was in progress. Fragment "+r.sn+" of level "+r.level+" will not be buffered")},C.onAudioTrackSwitching=function(t,e){var r=this.altAudio,n=!!e.url,i=e.id;if(!n){if(this.mediaBuffer!==this.media){this.log("Switching on main audio, use media.buffered to schedule main fragment loading"),this.mediaBuffer=this.media;var o=this.fragCurrent;null!=o&&o.loader&&(this.log("Switching to main audio track, cancel main fragment load"),o.loader.abort()),this.resetTransmuxer(),this.resetLoadingState()}else this.audioOnly&&this.resetTransmuxer();var s=this.hls;r&&s.trigger(a.Events.BUFFER_FLUSHING,{startOffset:0,endOffset:Number.POSITIVE_INFINITY,type:"audio"}),s.trigger(a.Events.AUDIO_TRACK_SWITCHED,{id:i})}},C.onAudioTrackSwitched=function(t,e){var r=e.id,n=!!this.hls.audioTracks[r].url;if(n){var i=this.videoBuffer;i&&this.mediaBuffer!==i&&(this.log("Switching on alternate audio, use video.buffered to schedule main fragment loading"),this.mediaBuffer=i)}this.altAudio=n,this.tick()},C.onBufferCreated=function(t,e){var r,n,i=e.tracks,o=!1;for(var a in i){var s=i[a];if("main"===s.id){if(n=a,r=s,"video"===a){var A=i[a];A&&(this.videoBuffer=A.buffer)}}else o=!0}o&&r?(this.log("Alternate track found, use "+n+".buffered to schedule main fragment loading"),this.mediaBuffer=r.buffer):this.mediaBuffer=this.media},C.onFragBuffered=function(t,e){var r=e.frag,n=e.part;if(!r||r.type===l.PlaylistLevelType.MAIN){if(this.fragContextChanged(r))return this.warn("Fragment "+r.sn+(n?" p: "+n.index:"")+" of level "+r.level+" finished buffering, but was aborted. state: "+this.state),void(this.state===i.State.PARSED&&(this.state=i.State.IDLE));var o=n?n.stats:r.stats;this.fragLastKbps=Math.round(8*o.total/(o.buffering.end-o.loading.first)),"initSegment"!==r.sn&&(this.fragPrevious=r),this.fragBufferedComplete(r,n)}},C.onError=function(t,e){switch(e.details){case f.ErrorDetails.FRAG_LOAD_ERROR:case f.ErrorDetails.FRAG_LOAD_TIMEOUT:case f.ErrorDetails.KEY_LOAD_ERROR:case f.ErrorDetails.KEY_LOAD_TIMEOUT:this.onFragmentOrKeyLoadError(l.PlaylistLevelType.MAIN,e);break;case f.ErrorDetails.LEVEL_LOAD_ERROR:case f.ErrorDetails.LEVEL_LOAD_TIMEOUT:this.state!==i.State.ERROR&&(e.fatal?(this.warn(""+e.details),this.state=i.State.ERROR):e.levelRetry||this.state!==i.State.WAITING_LEVEL||(this.state=i.State.IDLE));break;case f.ErrorDetails.BUFFER_FULL_ERROR:if("main"===e.parent&&(this.state===i.State.PARSING||this.state===i.State.PARSED)){var r=!0,n=this.getFwdBufferInfo(this.media,l.PlaylistLevelType.MAIN);n&&n.len>.5&&(r=!this.reduceMaxBufferLength(n.len)),r&&(this.warn("buffer full error also media.currentTime is not buffered, flush main"),this.immediateLevelSwitch()),this.resetLoadingState()}}},C.checkBuffer=function(){var t=this.media,e=this.gapController;if(t&&e&&t.readyState){var r=s.BufferHelper.getBuffered(t);!this.loadedmetadata&&r.length?(this.loadedmetadata=!0,this.seekToStartPos()):e.poll(this.lastCurrentTime),this.lastCurrentTime=t.currentTime}},C.onFragLoadEmergencyAborted=function(){this.state=i.State.IDLE,this.loadedmetadata||(this.startFragRequested=!1,this.nextLoadPosition=this.startPosition),this.tickImmediate()},C.onBufferFlushed=function(t,e){var r=e.type;if(r!==c.ElementaryStreamTypes.AUDIO||this.audioOnly&&!this.altAudio){var n=(r===c.ElementaryStreamTypes.VIDEO?this.videoBuffer:this.mediaBuffer)||this.media;this.afterBufferFlushed(n,r,l.PlaylistLevelType.MAIN)}},C.onLevelsUpdated=function(t,e){this.levels=e.levels},C.swapAudioCodec=function(){this.audioCodecSwap=!this.audioCodecSwap},C.seekToStartPos=function(){var t=this.media,e=t.currentTime,r=this.startPosition;if(r>=0&&e<r){if(t.seeking)return void p.logger.log("could not seek to "+r+", already seeking at "+e);var n=s.BufferHelper.getBuffered(t),i=(n.length?n.start(0):0)-r;i>0&&(i<this.config.maxBufferHole||i<this.config.maxFragLookUpTolerance)&&(p.logger.log("adjusting start position by "+i+" to match buffer start"),r+=i,this.startPosition=r),this.log("seek to target start position "+r+" from current time "+e),t.currentTime=r}},C._getAudioCodec=function(t){var e=this.config.defaultAudioCodec||t.audioCodec;return this.audioCodecSwap&&e&&(this.log("Swapping audio codec"),e=-1!==e.indexOf("mp4a.40.5")?"mp4a.40.2":"mp4a.40.5"),e},C._loadBitrateTestFrag=function(t){var e=this;this._doFragLoad(t).then((function(r){var n=e.hls;if(r&&!n.nextLoadLevel&&!e.fragContextChanged(t)){e.fragLoadError=0,e.state=i.State.IDLE,e.startFragRequested=!1,e.bitrateTest=!1;var o=t.stats;o.parsing.start=o.parsing.end=o.buffering.start=o.buffering.end=self.performance.now(),n.trigger(a.Events.FRAG_LOADED,r)}}))},C._handleTransmuxComplete=function(t){var e,r="main",o=this.hls,s=t.remuxResult,A=t.chunkMeta,l=this.getCurrentContext(A);if(!l)return this.warn("The loading context changed while buffering fragment "+A.sn+" of level "+A.level+". This chunk will not be buffered."),void this.resetLiveStartWhenNotLoaded(A.level);var u=l.frag,h=l.part,d=l.level,f=s.video,p=s.text,g=s.id3,m=s.initSegment,v=this.altAudio?void 0:s.audio;if(!this.fragContextChanged(u)){if(this.state=i.State.PARSING,m){m.tracks&&(this._bufferInitSegment(d,m.tracks,u,A),o.trigger(a.Events.FRAG_PARSING_INIT_SEGMENT,{frag:u,id:r,tracks:m.tracks}));var y=m.initPTS,w=m.timescale;Object(n.isFiniteNumber)(y)&&(this.initPTS[u.cc]=y,o.trigger(a.Events.INIT_PTS_FOUND,{frag:u,id:r,initPTS:y,timescale:w}))}if(f&&!1!==s.independent){if(d.details){var b=f.startPTS,C=f.endPTS,B=f.startDTS,x=f.endDTS;if(h)h.elementaryStreams[f.type]={startPTS:b,endPTS:C,startDTS:B,endDTS:x};else if(f.firstKeyFrame&&f.independent&&(this.couldBacktrack=!0),f.dropped&&f.independent){if(this.getLoadPosition()+this.config.maxBufferHole<b)return void this.backtrack(u);u.setElementaryStreamInfo(f.type,u.start,C,u.start,x,!0)}u.setElementaryStreamInfo(f.type,b,C,B,x),this.bufferFragmentData(f,u,h,A)}}else if(!1===s.independent)return void this.backtrack(u);if(v){var E=v.startPTS,S=v.endPTS,k=v.startDTS,T=v.endDTS;h&&(h.elementaryStreams[c.ElementaryStreamTypes.AUDIO]={startPTS:E,endPTS:S,startDTS:k,endDTS:T}),u.setElementaryStreamInfo(c.ElementaryStreamTypes.AUDIO,E,S,k,T),this.bufferFragmentData(v,u,h,A)}if(null!=g&&null!==(e=g.samples)&&void 0!==e&&e.length){var F={frag:u,id:r,samples:g.samples};o.trigger(a.Events.FRAG_PARSING_METADATA,F)}if(p){var L={frag:u,id:r,samples:p.samples};o.trigger(a.Events.FRAG_PARSING_USERDATA,L)}}},C._bufferInitSegment=function(t,e,r,n){var o=this;if(this.state===i.State.PARSING){this.audioOnly=!!e.audio&&!e.video,this.altAudio&&!this.audioOnly&&delete e.audio;var s=e.audio,A=e.video,l=e.audiovideo;if(s){var c=t.audioCodec,u=navigator.userAgent.toLowerCase();this.audioCodecSwitch&&(c&&(c=-1!==c.indexOf("mp4a.40.5")?"mp4a.40.2":"mp4a.40.5"),1!==s.metadata.channelCount&&-1===u.indexOf("firefox")&&(c="mp4a.40.5")),-1!==u.indexOf("android")&&"audio/mpeg"!==s.container&&(c="mp4a.40.2",this.log("Android: force audio codec to "+c)),t.audioCodec&&t.audioCodec!==c&&this.log('Swapping manifest audio codec "'+t.audioCodec+'" for "'+c+'"'),s.levelCodec=c,s.id="main",this.log("Init audio buffer, container:"+s.container+", codecs[selected/level/parsed]=["+(c||"")+"/"+(t.audioCodec||"")+"/"+s.codec+"]")}A&&(A.levelCodec=t.videoCodec,A.id="main",this.log("Init video buffer, container:"+A.container+", codecs[level/parsed]=["+(t.videoCodec||"")+"/"+A.codec+"]")),l&&this.log("Init audiovideo buffer, container:"+l.container+", codecs[level/parsed]=["+(t.attrs.CODECS||"")+"/"+l.codec+"]"),this.hls.trigger(a.Events.BUFFER_CODECS,e),Object.keys(e).forEach((function(t){var i=e[t].initSegment;null!=i&&i.byteLength&&o.hls.trigger(a.Events.BUFFER_APPENDING,{type:t,data:i,frag:r,part:null,chunkMeta:n,parent:r.type})})),this.tick()}},C.backtrack=function(t){this.couldBacktrack=!0,this.resetTransmuxer(),this.flushBufferGap(t);var e=this.fragmentTracker.backtrack(t);this.fragPrevious=null,this.nextLoadPosition=t.start,e?this.resetFragmentLoading(t):this.state=i.State.BACKTRACKING},C.checkFragmentChanged=function(){var t=this.media,e=null;if(t&&t.readyState>1&&!1===t.seeking){var r=t.currentTime;if(s.BufferHelper.isBuffered(t,r)?e=this.getAppendedFrag(r):s.BufferHelper.isBuffered(t,r+.1)&&(e=this.getAppendedFrag(r+.1)),e){var n=this.fragPlaying,i=e.level;n&&e.sn===n.sn&&n.level===i&&e.urlId===n.urlId||(this.hls.trigger(a.Events.FRAG_CHANGED,{frag:e}),n&&n.level===i||this.hls.trigger(a.Events.LEVEL_SWITCHED,{level:i}),this.fragPlaying=e)}}},y=v,(w=[{key:"nextLevel",get:function(){var t=this.nextBufferedFrag;return t?t.level:-1}},{key:"currentLevel",get:function(){var t=this.media;if(t){var e=this.getAppendedFrag(t.currentTime);if(e)return e.level}return-1}},{key:"nextBufferedFrag",get:function(){var t=this.media;if(t){var e=this.getAppendedFrag(t.currentTime);return this.followingBufferedFrag(e)}return null}},{key:"forceStartLoad",get:function(){return this._forceStartLoad}}])&&g(y.prototype,w),b&&g(y,b),v}(i.default)},"./src/controller/subtitle-stream-controller.ts":
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./src/controller/subtitle-stream-controller.ts ***!
|
|
|
\******************************************************/
|
|
|
/*! exports provided: SubtitleStreamController */function(t,e,r){"use strict";r.r(e),r.d(e,"SubtitleStreamController",(function(){return p}));var n=r(/*! ../events */"./src/events.ts"),i=r(/*! ../utils/logger */"./src/utils/logger.ts"),o=r(/*! ../utils/buffer-helper */"./src/utils/buffer-helper.ts"),a=r(/*! ./fragment-finders */"./src/controller/fragment-finders.ts"),s=r(/*! ../utils/discontinuities */"./src/utils/discontinuities.ts"),A=r(/*! ./level-helper */"./src/controller/level-helper.ts"),l=r(/*! ./fragment-tracker */"./src/controller/fragment-tracker.ts"),c=r(/*! ./base-stream-controller */"./src/controller/base-stream-controller.ts"),u=r(/*! ../types/loader */"./src/types/loader.ts"),h=r(/*! ../types/level */"./src/types/level.ts");function d(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function f(t,e){return(f=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var p=function(t){var e,r;function p(e,r){var n;return(n=t.call(this,e,r,"[subtitle-stream-controller]")||this).levels=[],n.currentTrackId=-1,n.tracksBuffered=[],n.mainDetails=null,n._registerListeners(),n}r=t,(e=p).prototype=Object.create(r.prototype),e.prototype.constructor=e,f(e,r);var g,m,v,y=p.prototype;return y.onHandlerDestroying=function(){this._unregisterListeners(),this.mainDetails=null},y._registerListeners=function(){var t=this.hls;t.on(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.on(n.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.on(n.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.on(n.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.on(n.Events.ERROR,this.onError,this),t.on(n.Events.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),t.on(n.Events.SUBTITLE_TRACK_SWITCH,this.onSubtitleTrackSwitch,this),t.on(n.Events.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),t.on(n.Events.SUBTITLE_FRAG_PROCESSED,this.onSubtitleFragProcessed,this),t.on(n.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)},y._unregisterListeners=function(){var t=this.hls;t.off(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.off(n.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.off(n.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.off(n.Events.LEVEL_LOADED,this.onLevelLoaded,this),t.off(n.Events.ERROR,this.onError,this),t.off(n.Events.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),t.off(n.Events.SUBTITLE_TRACK_SWITCH,this.onSubtitleTrackSwitch,this),t.off(n.Events.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),t.off(n.Events.SUBTITLE_FRAG_PROCESSED,this.onSubtitleFragProcessed,this),t.off(n.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)},y.startLoad=function(){this.stopLoad(),this.state=c.State.IDLE,this.setInterval(500),this.tick()},y.onManifestLoading=function(){this.mainDetails=null,this.fragmentTracker.removeAllFragments()},y.onLevelLoaded=function(t,e){this.mainDetails=e.details},y.onSubtitleFragProcessed=function(t,e){var r=e.frag,n=e.success;if(this.fragPrevious=r,this.state=c.State.IDLE,n){var i=this.tracksBuffered[this.currentTrackId];if(i){for(var o,a=r.start,s=0;s<i.length;s++)if(a>=i[s].start&&a<=i[s].end){o=i[s];break}var A=r.start+r.duration;o?o.end=A:(o={start:a,end:A},i.push(o)),this.fragmentTracker.fragBuffered(r)}}},y.onBufferFlushing=function(t,e){var r=e.startOffset,n=e.endOffset;if(0===r&&n!==Number.POSITIVE_INFINITY){var i=this.currentTrackId,o=this.levels;if(!o.length||!o[i]||!o[i].details)return;var a=n-o[i].details.targetduration;if(a<=0)return;e.endOffsetSubtitles=Math.max(0,a),this.tracksBuffered.forEach((function(t){for(var e=0;e<t.length;)if(t[e].end<=a)t.shift();else{if(!(t[e].start<a))break;t[e].start=a,e++}})),this.fragmentTracker.removeFragmentsInRange(r,a,u.PlaylistLevelType.SUBTITLE)}},y.onError=function(t,e){var r,n=e.frag;n&&n.type===u.PlaylistLevelType.SUBTITLE&&(null!==(r=this.fragCurrent)&&void 0!==r&&r.loader&&this.fragCurrent.loader.abort(),this.state=c.State.IDLE)},y.onSubtitleTracksUpdated=function(t,e){var r=this,n=e.subtitleTracks;this.tracksBuffered=[],this.levels=n.map((function(t){return new h.Level(t)})),this.fragmentTracker.removeAllFragments(),this.fragPrevious=null,this.levels.forEach((function(t){r.tracksBuffered[t.id]=[]})),this.mediaBuffer=null},y.onSubtitleTrackSwitch=function(t,e){if(this.currentTrackId=e.id,this.levels.length&&-1!==this.currentTrackId){var r=this.levels[this.currentTrackId];null!=r&&r.details?this.mediaBuffer=this.mediaBufferTimeRanges:this.mediaBuffer=null,r&&this.setInterval(500)}else this.clearInterval()},y.onSubtitleTrackLoaded=function(t,e){var r,n=e.details,i=e.id,o=this.currentTrackId,l=this.levels;if(l.length){var u=l[o];if(!(i>=l.length||i!==o)&&u){if(this.mediaBuffer=this.mediaBufferTimeRanges,n.live||null!==(r=u.details)&&void 0!==r&&r.live){var h=this.mainDetails;if(n.deltaUpdateFailed||!h)return;var d=h.fragments[0];u.details?0===this.alignPlaylists(n,u.details)&&d&&Object(A.addSliding)(n,d.start):n.hasProgramDateTime&&h.hasProgramDateTime?Object(s.alignMediaPlaylistByPDT)(n,h):d&&Object(A.addSliding)(n,d.start)}u.details=n,this.levelLastLoaded=i,this.tick(),n.live&&!this.fragCurrent&&this.media&&this.state===c.State.IDLE&&(Object(a.findFragmentByPTS)(null,n.fragments,this.media.currentTime,0)||(this.warn("Subtitle playlist not aligned with playback"),u.details=void 0))}}},y._handleFragmentLoadComplete=function(t){var e=t.frag,r=t.payload,i=e.decryptdata,o=this.hls;if(!this.fragContextChanged(e)&&r&&r.byteLength>0&&i&&i.key&&i.iv&&"AES-128"===i.method){var a=performance.now();this.decrypter.webCryptoDecrypt(new Uint8Array(r),i.key.buffer,i.iv.buffer).then((function(t){var r=performance.now();o.trigger(n.Events.FRAG_DECRYPTED,{frag:e,payload:t,stats:{tstart:a,tdecrypt:r}})}))}},y.doTick=function(){if(this.media){if(this.state===c.State.IDLE){var t,e=this.currentTrackId,r=this.levels;if(!r.length||!r[e]||!r[e].details)return;var s=r[e].details,A=s.targetduration,u=this.config,h=this.media,d=o.BufferHelper.bufferedInfo(this.mediaBufferTimeRanges,h.currentTime-A,u.maxBufferHole),f=d.end;if(d.len>this.getMaxBufferLength()+A)return;console.assert(s,"Subtitle track details are defined on idle subtitle stream controller tick");var p,g=s.fragments,m=g.length,v=s.edge,y=this.fragPrevious;if(f<v){var w=u.maxFragLookUpTolerance;y&&s.hasProgramDateTime&&(p=Object(a.findFragmentByPDT)(g,y.endProgramDateTime,w)),p||!(p=Object(a.findFragmentByPTS)(y,g,f,w))&&y&&y.start<g[0].start&&(p=g[0])}else p=g[m-1];null!==(t=p)&&void 0!==t&&t.encrypted?(i.logger.log("Loading key for "+p.sn),this.state=c.State.KEY_LOADING,this.hls.trigger(n.Events.KEY_LOADING,{frag:p})):p&&this.fragmentTracker.getState(p)===l.FragmentState.NOT_LOADED&&this.loadFragment(p,s,f)}}else this.state=c.State.IDLE},y.loadFragment=function(e,r,n){this.fragCurrent=e,t.prototype.loadFragment.call(this,e,r,n)},g=p,(m=[{key:"mediaBufferTimeRanges",get:function(){return this.tracksBuffered[this.currentTrackId]||[]}}])&&d(g.prototype,m),v&&d(g,v),p}(c.default)},"./src/controller/subtitle-track-controller.ts":
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./src/controller/subtitle-track-controller.ts ***!
|
|
|
\*****************************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../events */"./src/events.ts"),i=r(/*! ../utils/texttrack-utils */"./src/utils/texttrack-utils.ts"),o=r(/*! ./base-playlist-controller */"./src/controller/base-playlist-controller.ts"),a=r(/*! ../types/loader */"./src/types/loader.ts");function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function A(t,e){return(A=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var l=function(t){var e,r;function o(e){var r;return(r=t.call(this,e,"[subtitle-track-controller]")||this).media=null,r.tracks=[],r.groupId=null,r.tracksInGroup=[],r.trackId=-1,r.selectDefaultTrack=!0,r.queuedDefaultTrack=-1,r.trackChangeListener=function(){return r.onTextTracksChanged()},r.asyncPollTrackChange=function(){return r.pollTrackChange(0)},r.useTextTrackPolling=!1,r.subtitlePollingInterval=-1,r.subtitleDisplay=!0,r.registerListeners(),r}r=t,(e=o).prototype=Object.create(r.prototype),e.prototype.constructor=e,A(e,r);var l,u,h,d=o.prototype;return d.destroy=function(){this.unregisterListeners(),this.tracks.length=0,this.tracksInGroup.length=0,this.trackChangeListener=this.asyncPollTrackChange=null,t.prototype.destroy.call(this)},d.registerListeners=function(){var t=this.hls;t.on(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.on(n.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.on(n.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.on(n.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.on(n.Events.LEVEL_LOADING,this.onLevelLoading,this),t.on(n.Events.LEVEL_SWITCHING,this.onLevelSwitching,this),t.on(n.Events.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),t.on(n.Events.ERROR,this.onError,this)},d.unregisterListeners=function(){var t=this.hls;t.off(n.Events.MEDIA_ATTACHED,this.onMediaAttached,this),t.off(n.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.off(n.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.off(n.Events.MANIFEST_PARSED,this.onManifestParsed,this),t.off(n.Events.LEVEL_LOADING,this.onLevelLoading,this),t.off(n.Events.LEVEL_SWITCHING,this.onLevelSwitching,this),t.off(n.Events.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),t.off(n.Events.ERROR,this.onError,this)},d.onMediaAttached=function(t,e){this.media=e.media,this.media&&(this.queuedDefaultTrack>-1&&(this.subtitleTrack=this.queuedDefaultTrack,this.queuedDefaultTrack=-1),this.useTextTrackPolling=!(this.media.textTracks&&"onchange"in this.media.textTracks),this.useTextTrackPolling?this.pollTrackChange(500):this.media.textTracks.addEventListener("change",this.asyncPollTrackChange))},d.pollTrackChange=function(t){self.clearInterval(this.subtitlePollingInterval),this.subtitlePollingInterval=self.setInterval(this.trackChangeListener,t)},d.onMediaDetaching=function(){this.media&&(self.clearInterval(this.subtitlePollingInterval),this.useTextTrackPolling||this.media.textTracks.removeEventListener("change",this.asyncPollTrackChange),this.trackId>-1&&(this.queuedDefaultTrack=this.trackId),c(this.media.textTracks).forEach((function(t){Object(i.clearCurrentCues)(t)})),this.subtitleTrack=-1,this.media=null)},d.onManifestLoading=function(){this.tracks=[],this.groupId=null,this.tracksInGroup=[],this.trackId=-1,this.selectDefaultTrack=!0},d.onManifestParsed=function(t,e){this.tracks=e.subtitleTracks},d.onSubtitleTrackLoaded=function(t,e){var r=e.id,n=e.details,i=this.trackId,o=this.tracksInGroup[i];if(o){var a=o.details;o.details=e.details,this.log("subtitle track "+r+" loaded ["+n.startSN+"-"+n.endSN+"]"),r===this.trackId&&(this.retryCount=0,this.playlistLoaded(r,e,a))}else this.warn("Invalid subtitle track id "+r)},d.onLevelLoading=function(t,e){this.switchLevel(e.level)},d.onLevelSwitching=function(t,e){this.switchLevel(e.level)},d.switchLevel=function(t){var e=this.hls.levels[t];if(null!=e&&e.textGroupIds){var r=e.textGroupIds[e.urlId];if(this.groupId!==r){var i=this.tracksInGroup?this.tracksInGroup[this.trackId]:void 0,o=this.tracks.filter((function(t){return!r||t.groupId===r}));this.tracksInGroup=o;var a=this.findTrackId(null==i?void 0:i.name)||this.findTrackId();this.groupId=r;var s={subtitleTracks:o};this.log("Updating subtitle tracks, "+o.length+' track(s) found in "'+r+'" group-id'),this.hls.trigger(n.Events.SUBTITLE_TRACKS_UPDATED,s),-1!==a&&this.setSubtitleTrack(a,i)}}},d.findTrackId=function(t){for(var e=this.tracksInGroup,r=0;r<e.length;r++){var n=e[r];if((!this.selectDefaultTrack||n.default)&&(!t||t===n.name))return n.id}return-1},d.onError=function(e,r){t.prototype.onError.call(this,e,r),!r.fatal&&r.context&&r.context.type===a.PlaylistContextType.SUBTITLE_TRACK&&r.context.id===this.trackId&&r.context.groupId===this.groupId&&this.retryLoadingOrFail(r)},d.loadPlaylist=function(t){var e=this.tracksInGroup[this.trackId];if(this.shouldLoadTrack(e)){var r=e.id,i=e.groupId,o=e.url;if(t)try{o=t.addDirectives(o)}catch(t){this.warn("Could not construct new URL with HLS Delivery Directives: "+t)}this.log("Loading subtitle playlist for id "+r),this.hls.trigger(n.Events.SUBTITLE_TRACK_LOADING,{url:o,id:r,groupId:i,deliveryDirectives:t||null})}},d.toggleTrackModes=function(t){var e=this,r=this.media,n=this.subtitleDisplay,i=this.trackId;if(r){var o=c(r.textTracks),a=o.filter((function(t){return t.groupId===e.groupId}));if(-1===t)[].slice.call(o).forEach((function(t){t.mode="disabled"}));else{var s=a[i];s&&(s.mode="disabled")}var A=a[t];A&&(A.mode=n?"showing":"hidden")}},d.setSubtitleTrack=function(t,e){var r,i=this.tracksInGroup;if(this.media){if(this.trackId!==t&&this.toggleTrackModes(t),!(this.trackId===t&&(-1===t||null!==(r=i[t])&&void 0!==r&&r.details)||t<-1||t>=i.length)){this.clearTimer();var o=i[t];if(this.log("Switching to subtitle track "+t),this.trackId=t,o){var a=o.id,s=o.groupId,A=void 0===s?"":s,l=o.name,c=o.type,u=o.url;this.hls.trigger(n.Events.SUBTITLE_TRACK_SWITCH,{id:a,groupId:A,name:l,type:c,url:u});var h=this.switchParams(o.url,null==e?void 0:e.details);this.loadPlaylist(h)}else this.hls.trigger(n.Events.SUBTITLE_TRACK_SWITCH,{id:t})}}else this.queuedDefaultTrack=t},d.onTextTracksChanged=function(){if(this.useTextTrackPolling||self.clearInterval(this.subtitlePollingInterval),this.media&&this.hls.config.renderTextTracksNatively){for(var t=-1,e=c(this.media.textTracks),r=0;r<e.length;r++)if("hidden"===e[r].mode)t=r;else if("showing"===e[r].mode){t=r;break}this.subtitleTrack!==t&&(this.subtitleTrack=t)}},l=o,(u=[{key:"subtitleTracks",get:function(){return this.tracksInGroup}},{key:"subtitleTrack",get:function(){return this.trackId},set:function(t){this.selectDefaultTrack=!1;var e=this.tracksInGroup?this.tracksInGroup[this.trackId]:void 0;this.setSubtitleTrack(t,e)}}])&&s(l.prototype,u),h&&s(l,h),o}(o.default);function c(t){for(var e=[],r=0;r<t.length;r++){var n=t[r];"subtitles"===n.kind&&n.label&&e.push(t[r])}return e}e.default=l},"./src/controller/timeline-controller.ts":
|
|
|
/*!***********************************************!*\
|
|
|
!*** ./src/controller/timeline-controller.ts ***!
|
|
|
\***********************************************/
|
|
|
/*! exports provided: TimelineController */function(t,e,r){"use strict";r.r(e),r.d(e,"TimelineController",(function(){return h}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../utils/cea-608-parser */"./src/utils/cea-608-parser.ts"),a=r(/*! ../utils/output-filter */"./src/utils/output-filter.ts"),s=r(/*! ../utils/webvtt-parser */"./src/utils/webvtt-parser.ts"),A=r(/*! ../utils/texttrack-utils */"./src/utils/texttrack-utils.ts"),l=r(/*! ../utils/imsc1-ttml-parser */"./src/utils/imsc1-ttml-parser.ts"),c=r(/*! ../types/loader */"./src/types/loader.ts"),u=r(/*! ../utils/logger */"./src/utils/logger.ts"),h=function(){function t(t){if(this.hls=void 0,this.media=null,this.config=void 0,this.enabled=!0,this.Cues=void 0,this.textTracks=[],this.tracks=[],this.initPTS=[],this.timescale=[],this.unparsedVttFrags=[],this.captionsTracks={},this.nonNativeCaptionsTracks={},this.cea608Parser1=void 0,this.cea608Parser2=void 0,this.lastSn=-1,this.lastPartIndex=-1,this.prevCC=-1,this.vttCCs={ccOffset:0,presentationOffset:0,0:{start:0,prevCC:-1,new:!1}},this.captionsProperties=void 0,this.hls=t,this.config=t.config,this.Cues=t.config.cueHandler,this.captionsProperties={textTrack1:{label:this.config.captionsTextTrack1Label,languageCode:this.config.captionsTextTrack1LanguageCode},textTrack2:{label:this.config.captionsTextTrack2Label,languageCode:this.config.captionsTextTrack2LanguageCode},textTrack3:{label:this.config.captionsTextTrack3Label,languageCode:this.config.captionsTextTrack3LanguageCode},textTrack4:{label:this.config.captionsTextTrack4Label,languageCode:this.config.captionsTextTrack4LanguageCode}},this.config.enableCEA708Captions){var e=new a.default(this,"textTrack1"),r=new a.default(this,"textTrack2"),n=new a.default(this,"textTrack3"),s=new a.default(this,"textTrack4");this.cea608Parser1=new o.default(1,e,r),this.cea608Parser2=new o.default(3,n,s)}t.on(i.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),t.on(i.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.on(i.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.on(i.Events.MANIFEST_LOADED,this.onManifestLoaded,this),t.on(i.Events.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),t.on(i.Events.FRAG_LOADING,this.onFragLoading,this),t.on(i.Events.FRAG_LOADED,this.onFragLoaded,this),t.on(i.Events.FRAG_PARSING_USERDATA,this.onFragParsingUserdata,this),t.on(i.Events.FRAG_DECRYPTED,this.onFragDecrypted,this),t.on(i.Events.INIT_PTS_FOUND,this.onInitPtsFound,this),t.on(i.Events.SUBTITLE_TRACKS_CLEARED,this.onSubtitleTracksCleared,this),t.on(i.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)}var e=t.prototype;return e.destroy=function(){var t=this.hls;t.off(i.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),t.off(i.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.off(i.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.off(i.Events.MANIFEST_LOADED,this.onManifestLoaded,this),t.off(i.Events.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),t.off(i.Events.FRAG_LOADING,this.onFragLoading,this),t.off(i.Events.FRAG_LOADED,this.onFragLoaded,this),t.off(i.Events.FRAG_PARSING_USERDATA,this.onFragParsingUserdata,this),t.off(i.Events.FRAG_DECRYPTED,this.onFragDecrypted,this),t.off(i.Events.INIT_PTS_FOUND,this.onInitPtsFound,this),t.off(i.Events.SUBTITLE_TRACKS_CLEARED,this.onSubtitleTracksCleared,this),t.off(i.Events.BUFFER_FLUSHING,this.onBufferFlushing,this),this.hls=this.config=this.cea608Parser1=this.cea608Parser2=null},e.addCues=function(t,e,r,n,o){for(var a,s,A,l,c=!1,u=o.length;u--;){var h=o[u],d=(a=h[0],s=h[1],A=e,l=r,Math.min(s,l)-Math.max(a,A));if(d>=0&&(h[0]=Math.min(h[0],e),h[1]=Math.max(h[1],r),c=!0,d/(r-e)>.5))return}if(c||o.push([e,r]),this.config.renderTextTracksNatively){var f=this.captionsTracks[t];this.Cues.newCue(f,e,r,n)}else{var p=this.Cues.newCue(null,e,r,n);this.hls.trigger(i.Events.CUES_PARSED,{type:"captions",cues:p,track:t})}},e.onInitPtsFound=function(t,e){var r=this,n=e.frag,o=e.id,a=e.initPTS,s=e.timescale,A=this.unparsedVttFrags;"main"===o&&(this.initPTS[n.cc]=a,this.timescale[n.cc]=s),A.length&&(this.unparsedVttFrags=[],A.forEach((function(t){r.onFragLoaded(i.Events.FRAG_LOADED,t)})))},e.getExistingTrack=function(t){var e=this.media;if(e)for(var r=0;r<e.textTracks.length;r++){var n=e.textTracks[r];if(n[t])return n}return null},e.createCaptionsTrack=function(t){this.config.renderTextTracksNatively?this.createNativeTrack(t):this.createNonNativeTrack(t)},e.createNativeTrack=function(t){if(!this.captionsTracks[t]){var e=this.captionsProperties,r=this.captionsTracks,n=this.media,i=e[t],o=i.label,a=i.languageCode,s=this.getExistingTrack(t);if(s)r[t]=s,Object(A.clearCurrentCues)(r[t]),Object(A.sendAddTrackEvent)(r[t],n);else{var l=this.createTextTrack("captions",o,a);l&&(l[t]=!0,r[t]=l)}}},e.createNonNativeTrack=function(t){if(!this.nonNativeCaptionsTracks[t]){var e=this.captionsProperties[t];if(e){var r={_id:t,label:e.label,kind:"captions",default:!!e.media&&!!e.media.default,closedCaptions:e.media};this.nonNativeCaptionsTracks[t]=r,this.hls.trigger(i.Events.NON_NATIVE_TEXT_TRACKS_FOUND,{tracks:[r]})}}},e.createTextTrack=function(t,e,r){var n=this.media;if(n)return n.addTextTrack(t,e,r)},e.onMediaAttaching=function(t,e){this.media=e.media,this._cleanTracks()},e.onMediaDetaching=function(){var t=this.captionsTracks;Object.keys(t).forEach((function(e){Object(A.clearCurrentCues)(t[e]),delete t[e]})),this.nonNativeCaptionsTracks={}},e.onManifestLoading=function(){this.lastSn=-1,this.lastPartIndex=-1,this.prevCC=-1,this.vttCCs={ccOffset:0,presentationOffset:0,0:{start:0,prevCC:-1,new:!1}},this._cleanTracks(),this.tracks=[],this.captionsTracks={},this.nonNativeCaptionsTracks={},this.textTracks=[],this.unparsedVttFrags=this.unparsedVttFrags||[],this.initPTS=[],this.timescale=[],this.cea608Parser1&&this.cea608Parser2&&(this.cea608Parser1.reset(),this.cea608Parser2.reset())},e._cleanTracks=function(){var t=this.media;if(t){var e=t.textTracks;if(e)for(var r=0;r<e.length;r++)Object(A.clearCurrentCues)(e[r])}},e.onSubtitleTracksUpdated=function(t,e){var r=this;this.textTracks=[];var n=e.subtitleTracks||[],o=n.some((function(t){return t.textCodec===l.IMSC1_CODEC}));if(this.config.enableWebVTT||o&&this.config.enableIMSC1){var a=this.tracks&&n&&this.tracks.length===n.length;if(this.tracks=n||[],this.config.renderTextTracksNatively){var s=this.media?this.media.textTracks:[];this.tracks.forEach((function(t,e){var n;if(e<s.length){for(var i=null,o=0;o<s.length;o++)if(d(s[o],t)){i=s[o];break}i&&(n=i)}n?Object(A.clearCurrentCues)(n):(n=r.createTextTrack("subtitles",t.name,t.lang))&&(n.mode="disabled"),n&&(n.groupId=t.groupId,r.textTracks.push(n))}))}else if(!a&&this.tracks&&this.tracks.length){var c=this.tracks.map((function(t){return{label:t.name,kind:t.type.toLowerCase(),default:t.default,subtitleTrack:t}}));this.hls.trigger(i.Events.NON_NATIVE_TEXT_TRACKS_FOUND,{tracks:c})}}},e.onManifestLoaded=function(t,e){var r=this;this.config.enableCEA708Captions&&e.captions&&e.captions.forEach((function(t){var e=/(?:CC|SERVICE)([1-4])/.exec(t.instreamId);if(e){var n="textTrack"+e[1],i=r.captionsProperties[n];i&&(i.label=t.name,t.lang&&(i.languageCode=t.lang),i.media=t)}}))},e.onFragLoading=function(t,e){var r=this.cea608Parser1,n=this.cea608Parser2,i=this.lastSn,o=this.lastPartIndex;if(this.enabled&&r&&n&&e.frag.type===c.PlaylistLevelType.MAIN){var a,s,A=e.frag.sn,l=null!=(a=null==e||null===(s=e.part)||void 0===s?void 0:s.index)?a:-1;A===i+1||A===i&&l===o+1||(r.reset(),n.reset()),this.lastSn=A,this.lastPartIndex=l}},e.onFragLoaded=function(t,e){var r=e.frag,o=e.payload,a=this.initPTS,s=this.unparsedVttFrags;if(r.type===c.PlaylistLevelType.SUBTITLE)if(o.byteLength){if(!Object(n.isFiniteNumber)(a[r.cc]))return s.push(e),void(a.length&&this.hls.trigger(i.Events.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:r,error:new Error("Missing initial subtitle PTS")}));var A=r.decryptdata;if(null==A||null==A.key||"AES-128"!==A.method){var u=this.tracks[r.level],h=this.vttCCs;h[r.cc]||(h[r.cc]={start:r.start,prevCC:this.prevCC,new:!0},this.prevCC=r.cc),u&&u.textCodec===l.IMSC1_CODEC?this._parseIMSC1(r,o):this._parseVTTs(r,o,h)}}else this.hls.trigger(i.Events.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:r,error:new Error("Empty subtitle payload")})},e._parseIMSC1=function(t,e){var r=this,n=this.hls;Object(l.parseIMSC1)(e,this.initPTS[t.cc],this.timescale[t.cc],(function(e){r._appendCues(e,t.level),n.trigger(i.Events.SUBTITLE_FRAG_PROCESSED,{success:!0,frag:t})}),(function(e){u.logger.log("Failed to parse IMSC1: "+e),n.trigger(i.Events.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:t,error:e})}))},e._parseVTTs=function(t,e,r){var n=this,o=this.hls;Object(s.parseWebVTT)(e,this.initPTS[t.cc],this.timescale[t.cc],r,t.cc,t.start,(function(e){n._appendCues(e,t.level),o.trigger(i.Events.SUBTITLE_FRAG_PROCESSED,{success:!0,frag:t})}),(function(r){n._fallbackToIMSC1(t,e),u.logger.log("Failed to parse VTT cue: "+r),o.trigger(i.Events.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:t,error:r})}))},e._fallbackToIMSC1=function(t,e){var r=this,n=this.tracks[t.level];n.textCodec||Object(l.parseIMSC1)(e,this.initPTS[t.cc],this.timescale[t.cc],(function(){n.textCodec=l.IMSC1_CODEC,r._parseIMSC1(t,e)}),(function(){n.textCodec="wvtt"}))},e._appendCues=function(t,e){var r=this.hls;if(this.config.renderTextTracksNatively){var n=this.textTracks[e];if("disabled"===n.mode)return;t.forEach((function(t){return Object(A.addCueToTrack)(n,t)}))}else{var o=this.tracks[e].default?"default":"subtitles"+e;r.trigger(i.Events.CUES_PARSED,{type:"subtitles",cues:t,track:o})}},e.onFragDecrypted=function(t,e){var r=e.frag;if(r.type===c.PlaylistLevelType.SUBTITLE){if(!Object(n.isFiniteNumber)(this.initPTS[r.cc]))return void this.unparsedVttFrags.push(e);this.onFragLoaded(i.Events.FRAG_LOADED,e)}},e.onSubtitleTracksCleared=function(){this.tracks=[],this.captionsTracks={}},e.onFragParsingUserdata=function(t,e){var r=this.cea608Parser1,n=this.cea608Parser2;if(this.enabled&&r&&n)for(var i=0;i<e.samples.length;i++){var o=e.samples[i].bytes;if(o){var a=this.extractCea608Data(o);r.addData(e.samples[i].pts,a[0]),n.addData(e.samples[i].pts,a[1])}}},e.onBufferFlushing=function(t,e){var r=e.startOffset,n=e.endOffset,i=e.endOffsetSubtitles,o=e.type,a=this.media;if(a&&!(a.currentTime<n)){if(!o||"video"===o){var s=this.captionsTracks;Object.keys(s).forEach((function(t){return Object(A.removeCuesInRange)(s[t],r,n)}))}if(this.config.renderTextTracksNatively&&0===r&&void 0!==i){var l=this.textTracks;Object.keys(l).forEach((function(t){return Object(A.removeCuesInRange)(l[t],r,i)}))}}},e.extractCea608Data=function(t){for(var e=31&t[0],r=2,n=[[],[]],i=0;i<e;i++){var o=t[r++],a=127&t[r++],s=127&t[r++],A=3&o;0===a&&0===s||0!=(4&o)&&(0!==A&&1!==A||(n[A].push(a),n[A].push(s)))}return n},t}();function d(t,e){return t&&t.label===e.name&&!(t.textTrack1||t.textTrack2)}},"./src/crypt/aes-crypto.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/crypt/aes-crypto.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return n}));var n=function(){function t(t,e){this.subtle=void 0,this.aesIV=void 0,this.subtle=t,this.aesIV=e}return t.prototype.decrypt=function(t,e){return this.subtle.decrypt({name:"AES-CBC",iv:this.aesIV},e,t)},t}()},"./src/crypt/aes-decryptor.ts":
|
|
|
/*!************************************!*\
|
|
|
!*** ./src/crypt/aes-decryptor.ts ***!
|
|
|
\************************************/
|
|
|
/*! exports provided: removePadding, default */function(t,e,r){"use strict";r.r(e),r.d(e,"removePadding",(function(){return i})),r.d(e,"default",(function(){return o}));var n=r(/*! ../utils/typed-array */"./src/utils/typed-array.ts");function i(t){var e=t.byteLength,r=e&&new DataView(t.buffer).getUint8(e-1);return r?Object(n.sliceUint8)(t,0,e-r):t}var o=function(){function t(){this.rcon=[0,1,2,4,8,16,32,64,128,27,54],this.subMix=[new Uint32Array(256),new Uint32Array(256),new Uint32Array(256),new Uint32Array(256)],this.invSubMix=[new Uint32Array(256),new Uint32Array(256),new Uint32Array(256),new Uint32Array(256)],this.sBox=new Uint32Array(256),this.invSBox=new Uint32Array(256),this.key=new Uint32Array(0),this.ksRows=0,this.keySize=0,this.keySchedule=void 0,this.invKeySchedule=void 0,this.initTable()}var e=t.prototype;return e.uint8ArrayToUint32Array_=function(t){for(var e=new DataView(t),r=new Uint32Array(4),n=0;n<4;n++)r[n]=e.getUint32(4*n);return r},e.initTable=function(){var t=this.sBox,e=this.invSBox,r=this.subMix,n=r[0],i=r[1],o=r[2],a=r[3],s=this.invSubMix,A=s[0],l=s[1],c=s[2],u=s[3],h=new Uint32Array(256),d=0,f=0,p=0;for(p=0;p<256;p++)h[p]=p<128?p<<1:p<<1^283;for(p=0;p<256;p++){var g=f^f<<1^f<<2^f<<3^f<<4;g=g>>>8^255&g^99,t[d]=g,e[g]=d;var m=h[d],v=h[m],y=h[v],w=257*h[g]^16843008*g;n[d]=w<<24|w>>>8,i[d]=w<<16|w>>>16,o[d]=w<<8|w>>>24,a[d]=w,w=16843009*y^65537*v^257*m^16843008*d,A[g]=w<<24|w>>>8,l[g]=w<<16|w>>>16,c[g]=w<<8|w>>>24,u[g]=w,d?(d=m^h[h[h[y^m]]],f^=h[h[f]]):d=f=1}},e.expandKey=function(t){for(var e=this.uint8ArrayToUint32Array_(t),r=!0,n=0;n<e.length&&r;)r=e[n]===this.key[n],n++;if(!r){this.key=e;var i=this.keySize=e.length;if(4!==i&&6!==i&&8!==i)throw new Error("Invalid aes key size="+i);var o,a,s,A,l=this.ksRows=4*(i+6+1),c=this.keySchedule=new Uint32Array(l),u=this.invKeySchedule=new Uint32Array(l),h=this.sBox,d=this.rcon,f=this.invSubMix,p=f[0],g=f[1],m=f[2],v=f[3];for(o=0;o<l;o++)o<i?s=c[o]=e[o]:(A=s,o%i==0?(A=h[(A=A<<8|A>>>24)>>>24]<<24|h[A>>>16&255]<<16|h[A>>>8&255]<<8|h[255&A],A^=d[o/i|0]<<24):i>6&&o%i==4&&(A=h[A>>>24]<<24|h[A>>>16&255]<<16|h[A>>>8&255]<<8|h[255&A]),c[o]=s=(c[o-i]^A)>>>0);for(a=0;a<l;a++)o=l-a,A=3&a?c[o]:c[o-4],u[a]=a<4||o<=4?A:p[h[A>>>24]]^g[h[A>>>16&255]]^m[h[A>>>8&255]]^v[h[255&A]],u[a]=u[a]>>>0}},e.networkToHostOrderSwap=function(t){return t<<24|(65280&t)<<8|(16711680&t)>>8|t>>>24},e.decrypt=function(t,e,r){for(var n,i,o,a,s,A,l,c,u,h,d,f,p,g,m=this.keySize+6,v=this.invKeySchedule,y=this.invSBox,w=this.invSubMix,b=w[0],C=w[1],B=w[2],x=w[3],E=this.uint8ArrayToUint32Array_(r),S=E[0],k=E[1],T=E[2],F=E[3],L=new Int32Array(t),I=new Int32Array(L.length),_=this.networkToHostOrderSwap;e<L.length;){for(u=_(L[e]),h=_(L[e+1]),d=_(L[e+2]),f=_(L[e+3]),s=u^v[0],A=f^v[1],l=d^v[2],c=h^v[3],p=4,g=1;g<m;g++)n=b[s>>>24]^C[A>>16&255]^B[l>>8&255]^x[255&c]^v[p],i=b[A>>>24]^C[l>>16&255]^B[c>>8&255]^x[255&s]^v[p+1],o=b[l>>>24]^C[c>>16&255]^B[s>>8&255]^x[255&A]^v[p+2],a=b[c>>>24]^C[s>>16&255]^B[A>>8&255]^x[255&l]^v[p+3],s=n,A=i,l=o,c=a,p+=4;n=y[s>>>24]<<24^y[A>>16&255]<<16^y[l>>8&255]<<8^y[255&c]^v[p],i=y[A>>>24]<<24^y[l>>16&255]<<16^y[c>>8&255]<<8^y[255&s]^v[p+1],o=y[l>>>24]<<24^y[c>>16&255]<<16^y[s>>8&255]<<8^y[255&A]^v[p+2],a=y[c>>>24]<<24^y[s>>16&255]<<16^y[A>>8&255]<<8^y[255&l]^v[p+3],I[e]=_(n^S),I[e+1]=_(a^k),I[e+2]=_(o^T),I[e+3]=_(i^F),S=u,k=h,T=d,F=f,e+=4}return I.buffer},t}()},"./src/crypt/decrypter.ts":
|
|
|
/*!********************************!*\
|
|
|
!*** ./src/crypt/decrypter.ts ***!
|
|
|
\********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return l}));var n=r(/*! ./aes-crypto */"./src/crypt/aes-crypto.ts"),i=r(/*! ./fast-aes-key */"./src/crypt/fast-aes-key.ts"),o=r(/*! ./aes-decryptor */"./src/crypt/aes-decryptor.ts"),a=r(/*! ../utils/logger */"./src/utils/logger.ts"),s=r(/*! ../utils/mp4-tools */"./src/utils/mp4-tools.ts"),A=r(/*! ../utils/typed-array */"./src/utils/typed-array.ts"),l=function(){function t(t,e,r){var n=(void 0===r?{}:r).removePKCS7Padding,i=void 0===n||n;if(this.logEnabled=!0,this.observer=void 0,this.config=void 0,this.removePKCS7Padding=void 0,this.subtle=null,this.softwareDecrypter=null,this.key=null,this.fastAesKey=null,this.remainderData=null,this.currentIV=null,this.currentResult=null,this.observer=t,this.config=e,this.removePKCS7Padding=i,i)try{var o=self.crypto;o&&(this.subtle=o.subtle||o.webkitSubtle)}catch(t){}null===this.subtle&&(this.config.enableSoftwareAES=!0)}var e=t.prototype;return e.destroy=function(){this.observer=null},e.isSync=function(){return this.config.enableSoftwareAES},e.flush=function(){var t=this.currentResult;if(t){var e=new Uint8Array(t);return this.reset(),this.removePKCS7Padding?Object(o.removePadding)(e):e}this.reset()},e.reset=function(){this.currentResult=null,this.currentIV=null,this.remainderData=null,this.softwareDecrypter&&(this.softwareDecrypter=null)},e.decrypt=function(t,e,r,n){if(this.config.enableSoftwareAES){this.softwareDecrypt(new Uint8Array(t),e,r);var i=this.flush();i&&n(i.buffer)}else this.webCryptoDecrypt(new Uint8Array(t),e,r).then(n)},e.softwareDecrypt=function(t,e,r){var n=this.currentIV,i=this.currentResult,a=this.remainderData;this.logOnce("JS AES decrypt"),a&&(t=Object(s.appendUint8Array)(a,t),this.remainderData=null);var l=this.getValidChunk(t);if(!l.length)return null;n&&(r=n);var c=this.softwareDecrypter;c||(c=this.softwareDecrypter=new o.default),c.expandKey(e);var u=i;return this.currentResult=c.decrypt(l.buffer,0,r),this.currentIV=Object(A.sliceUint8)(l,-16).buffer,u||null},e.webCryptoDecrypt=function(t,e,r){var o=this,a=this.subtle;return this.key===e&&this.fastAesKey||(this.key=e,this.fastAesKey=new i.default(a,e)),this.fastAesKey.expandKey().then((function(e){return a?new n.default(a,r).decrypt(t.buffer,e):Promise.reject(new Error("web crypto not initialized"))})).catch((function(n){return o.onWebCryptoError(n,t,e,r)}))},e.onWebCryptoError=function(t,e,r,n){return a.logger.warn("[decrypter.ts]: WebCrypto Error, disable WebCrypto API:",t),this.config.enableSoftwareAES=!0,this.logEnabled=!0,this.softwareDecrypt(e,r,n)},e.getValidChunk=function(t){var e=t,r=t.length-t.length%16;return r!==t.length&&(e=Object(A.sliceUint8)(t,0,r),this.remainderData=Object(A.sliceUint8)(t,r)),e},e.logOnce=function(t){this.logEnabled&&(a.logger.log("[decrypter.ts]: "+t),this.logEnabled=!1)},t}()},"./src/crypt/fast-aes-key.ts":
|
|
|
/*!***********************************!*\
|
|
|
!*** ./src/crypt/fast-aes-key.ts ***!
|
|
|
\***********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return n}));var n=function(){function t(t,e){this.subtle=void 0,this.key=void 0,this.subtle=t,this.key=e}return t.prototype.expandKey=function(){return this.subtle.importKey("raw",this.key,{name:"AES-CBC"},!1,["encrypt","decrypt"])},t}()},"./src/demux/aacdemuxer.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/demux/aacdemuxer.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ./base-audio-demuxer */"./src/demux/base-audio-demuxer.ts"),i=r(/*! ./adts */"./src/demux/adts.ts"),o=r(/*! ../utils/logger */"./src/utils/logger.ts"),a=r(/*! ../demux/id3 */"./src/demux/id3.ts");function s(t,e){return(s=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var A=function(t){var e,r;function n(e,r){var n;return(n=t.call(this)||this).observer=void 0,n.config=void 0,n.observer=e,n.config=r,n}r=t,(e=n).prototype=Object.create(r.prototype),e.prototype.constructor=e,s(e,r);var A=n.prototype;return A.resetInitSegment=function(e,r,n){t.prototype.resetInitSegment.call(this,e,r,n),this._audioTrack={container:"audio/adts",type:"audio",id:2,pid:-1,sequenceNumber:0,isAAC:!0,samples:[],manifestCodec:e,duration:n,inputTimeScale:9e4,dropped:0}},n.probe=function(t){if(!t)return!1;for(var e=(a.getID3Data(t,0)||[]).length,r=t.length;e<r;e++)if(i.probe(t,e))return o.logger.log("ADTS sync word found !"),!0;return!1},A.canParse=function(t,e){return i.canParse(t,e)},A.appendFrame=function(t,e,r){i.initTrackConfig(t,this.observer,e,r,t.manifestCodec);var n=i.appendFrame(t,e,r,this.initPTS,this.frameIndex);if(n&&0===n.missing)return n},n}(n.default);A.minProbeByteLength=9,e.default=A},"./src/demux/adts.ts":
|
|
|
/*!***************************!*\
|
|
|
!*** ./src/demux/adts.ts ***!
|
|
|
\***************************/
|
|
|
/*! exports provided: getAudioConfig, isHeaderPattern, getHeaderLength, getFullFrameLength, canGetFrameLength, isHeader, canParse, probe, initTrackConfig, getFrameDuration, parseFrameHeader, appendFrame */function(t,e,r){"use strict";r.r(e),r.d(e,"getAudioConfig",(function(){return a})),r.d(e,"isHeaderPattern",(function(){return s})),r.d(e,"getHeaderLength",(function(){return A})),r.d(e,"getFullFrameLength",(function(){return l})),r.d(e,"canGetFrameLength",(function(){return c})),r.d(e,"isHeader",(function(){return u})),r.d(e,"canParse",(function(){return h})),r.d(e,"probe",(function(){return d})),r.d(e,"initTrackConfig",(function(){return f})),r.d(e,"getFrameDuration",(function(){return p})),r.d(e,"parseFrameHeader",(function(){return g})),r.d(e,"appendFrame",(function(){return m}));var n=r(/*! ../utils/logger */"./src/utils/logger.ts"),i=r(/*! ../errors */"./src/errors.ts"),o=r(/*! ../events */"./src/events.ts");function a(t,e,r,a){var s,A,l,c,u=navigator.userAgent.toLowerCase(),h=a,d=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];s=1+((192&e[r+2])>>>6);var f=(60&e[r+2])>>>2;if(!(f>d.length-1))return l=(1&e[r+2])<<2,l|=(192&e[r+3])>>>6,n.logger.log("manifest codec:"+a+", ADTS type:"+s+", samplingIndex:"+f),/firefox/i.test(u)?f>=6?(s=5,c=new Array(4),A=f-3):(s=2,c=new Array(2),A=f):-1!==u.indexOf("android")?(s=2,c=new Array(2),A=f):(s=5,c=new Array(4),a&&(-1!==a.indexOf("mp4a.40.29")||-1!==a.indexOf("mp4a.40.5"))||!a&&f>=6?A=f-3:((a&&-1!==a.indexOf("mp4a.40.2")&&(f>=6&&1===l||/vivaldi/i.test(u))||!a&&1===l)&&(s=2,c=new Array(2)),A=f)),c[0]=s<<3,c[0]|=(14&f)>>1,c[1]|=(1&f)<<7,c[1]|=l<<3,5===s&&(c[1]|=(14&A)>>1,c[2]=(1&A)<<7,c[2]|=8,c[3]=0),{config:c,samplerate:d[f],channelCount:l,codec:"mp4a.40."+s,manifestCodec:h};t.trigger(o.Events.ERROR,{type:i.ErrorTypes.MEDIA_ERROR,details:i.ErrorDetails.FRAG_PARSING_ERROR,fatal:!0,reason:"invalid ADTS sampling index:"+f})}function s(t,e){return 255===t[e]&&240==(246&t[e+1])}function A(t,e){return 1&t[e+1]?7:9}function l(t,e){return(3&t[e+3])<<11|t[e+4]<<3|(224&t[e+5])>>>5}function c(t,e){return e+5<t.length}function u(t,e){return e+1<t.length&&s(t,e)}function h(t,e){return c(t,e)&&s(t,e)&&l(t,e)<=t.length-e}function d(t,e){if(u(t,e)){var r=A(t,e);if(e+r>=t.length)return!1;var n=l(t,e);if(n<=r)return!1;var i=e+n;return i===t.length||u(t,i)}return!1}function f(t,e,r,i,o){if(!t.samplerate){var s=a(e,r,i,o);if(!s)return;t.config=s.config,t.samplerate=s.samplerate,t.channelCount=s.channelCount,t.codec=s.codec,t.manifestCodec=s.manifestCodec,n.logger.log("parsed codec:"+t.codec+", rate:"+s.samplerate+", channels:"+s.channelCount)}}function p(t){return 9216e4/t}function g(t,e,r,n,i){var o=A(t,e),a=l(t,e);if((a-=o)>0)return{headerLength:o,frameLength:a,stamp:r+n*i}}function m(t,e,r,n,i){var o=g(e,r,n,i,p(t.samplerate));if(o){var a,s=o.frameLength,A=o.headerLength,l=o.stamp,c=A+s,u=Math.max(0,r+c-e.length);u?(a=new Uint8Array(c-A)).set(e.subarray(r+A,e.length),0):a=e.subarray(r+A,r+c);var h={unit:a,pts:l};return u||t.samples.push(h),{sample:h,length:c,missing:u}}}},"./src/demux/base-audio-demuxer.ts":
|
|
|
/*!*****************************************!*\
|
|
|
!*** ./src/demux/base-audio-demuxer.ts ***!
|
|
|
\*****************************************/
|
|
|
/*! exports provided: initPTSFn, default */function(t,e,r){"use strict";r.r(e),r.d(e,"initPTSFn",(function(){return l}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../demux/id3 */"./src/demux/id3.ts"),o=r(/*! ./dummy-demuxed-track */"./src/demux/dummy-demuxed-track.ts"),a=r(/*! ../utils/mp4-tools */"./src/utils/mp4-tools.ts"),s=r(/*! ../utils/typed-array */"./src/utils/typed-array.ts"),A=function(){function t(){this._audioTrack=void 0,this._id3Track=void 0,this.frameIndex=0,this.cachedData=null,this.initPTS=null}var e=t.prototype;return e.resetInitSegment=function(t,e,r){this._id3Track={type:"id3",id:3,pid:-1,inputTimeScale:9e4,sequenceNumber:0,samples:[],dropped:0}},e.resetTimeStamp=function(){},e.resetContiguity=function(){},e.canParse=function(t,e){return!1},e.appendFrame=function(t,e,r){},e.demux=function(t,e){this.cachedData&&(t=Object(a.appendUint8Array)(this.cachedData,t),this.cachedData=null);var r,n,A=i.getID3Data(t,0),c=A?A.length:0,u=this._audioTrack,h=this._id3Track,d=A?i.getTimeStamp(A):void 0,f=t.length;for(0!==this.frameIndex&&null!==this.initPTS||(this.initPTS=l(d,e)),A&&A.length>0&&h.samples.push({pts:this.initPTS,dts:this.initPTS,data:A}),n=this.initPTS;c<f;){if(this.canParse(t,c)){var p=this.appendFrame(u,t,c);p?(this.frameIndex++,n=p.sample.pts,r=c+=p.length):c=f}else i.canParse(t,c)?(A=i.getID3Data(t,c),h.samples.push({pts:n,dts:n,data:A}),r=c+=A.length):c++;if(c===f&&r!==f){var g=Object(s.sliceUint8)(t,r);this.cachedData?this.cachedData=Object(a.appendUint8Array)(this.cachedData,g):this.cachedData=g}}return{audioTrack:u,avcTrack:Object(o.dummyTrack)(),id3Track:h,textTrack:Object(o.dummyTrack)()}},e.demuxSampleAes=function(t,e,r){return Promise.reject(new Error("["+this+"] This demuxer does not support Sample-AES decryption"))},e.flush=function(t){var e=this.cachedData;return e&&(this.cachedData=null,this.demux(e,0)),this.frameIndex=0,{audioTrack:this._audioTrack,avcTrack:Object(o.dummyTrack)(),id3Track:this._id3Track,textTrack:Object(o.dummyTrack)()}},e.destroy=function(){},t}(),l=function(t,e){return Object(n.isFiniteNumber)(t)?90*t:9e4*e};e.default=A},"./src/demux/chunk-cache.ts":
|
|
|
/*!**********************************!*\
|
|
|
!*** ./src/demux/chunk-cache.ts ***!
|
|
|
\**********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return n}));var n=function(){function t(){this.chunks=[],this.dataLength=0}var e=t.prototype;return e.push=function(t){this.chunks.push(t),this.dataLength+=t.length},e.flush=function(){var t,e=this.chunks,r=this.dataLength;return e.length?(t=1===e.length?e[0]:function(t,e){for(var r=new Uint8Array(e),n=0,i=0;i<t.length;i++){var o=t[i];r.set(o,n),n+=o.length}return r}(e,r),this.reset(),t):new Uint8Array(0)},e.reset=function(){this.chunks.length=0,this.dataLength=0},t}()},"./src/demux/dummy-demuxed-track.ts":
|
|
|
/*!******************************************!*\
|
|
|
!*** ./src/demux/dummy-demuxed-track.ts ***!
|
|
|
\******************************************/
|
|
|
/*! exports provided: dummyTrack */function(t,e,r){"use strict";function n(){return{type:"",id:-1,pid:-1,inputTimeScale:9e4,sequenceNumber:-1,samples:[],dropped:0}}r.r(e),r.d(e,"dummyTrack",(function(){return n}))},"./src/demux/exp-golomb.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/demux/exp-golomb.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../utils/logger */"./src/utils/logger.ts"),i=function(){function t(t){this.data=void 0,this.bytesAvailable=void 0,this.word=void 0,this.bitsAvailable=void 0,this.data=t,this.bytesAvailable=t.byteLength,this.word=0,this.bitsAvailable=0}var e=t.prototype;return e.loadWord=function(){var t=this.data,e=this.bytesAvailable,r=t.byteLength-e,n=new Uint8Array(4),i=Math.min(4,e);if(0===i)throw new Error("no bytes available");n.set(t.subarray(r,r+i)),this.word=new DataView(n.buffer).getUint32(0),this.bitsAvailable=8*i,this.bytesAvailable-=i},e.skipBits=function(t){var e;this.bitsAvailable>t?(this.word<<=t,this.bitsAvailable-=t):(t-=this.bitsAvailable,t-=(e=t>>3)>>3,this.bytesAvailable-=e,this.loadWord(),this.word<<=t,this.bitsAvailable-=t)},e.readBits=function(t){var e=Math.min(this.bitsAvailable,t),r=this.word>>>32-e;return t>32&&n.logger.error("Cannot read more than 32 bits at a time"),this.bitsAvailable-=e,this.bitsAvailable>0?this.word<<=e:this.bytesAvailable>0&&this.loadWord(),(e=t-e)>0&&this.bitsAvailable?r<<e|this.readBits(e):r},e.skipLZ=function(){var t;for(t=0;t<this.bitsAvailable;++t)if(0!=(this.word&2147483648>>>t))return this.word<<=t,this.bitsAvailable-=t,t;return this.loadWord(),t+this.skipLZ()},e.skipUEG=function(){this.skipBits(1+this.skipLZ())},e.skipEG=function(){this.skipBits(1+this.skipLZ())},e.readUEG=function(){var t=this.skipLZ();return this.readBits(t+1)-1},e.readEG=function(){var t=this.readUEG();return 1&t?1+t>>>1:-1*(t>>>1)},e.readBoolean=function(){return 1===this.readBits(1)},e.readUByte=function(){return this.readBits(8)},e.readUShort=function(){return this.readBits(16)},e.readUInt=function(){return this.readBits(32)},e.skipScalingList=function(t){for(var e=8,r=8,n=0;n<t;n++)0!==r&&(r=(e+this.readEG()+256)%256),e=0===r?e:r},e.readSPS=function(){var t,e,r,n=0,i=0,o=0,a=0,s=this.readUByte.bind(this),A=this.readBits.bind(this),l=this.readUEG.bind(this),c=this.readBoolean.bind(this),u=this.skipBits.bind(this),h=this.skipEG.bind(this),d=this.skipUEG.bind(this),f=this.skipScalingList.bind(this);s();var p=s();if(A(5),u(3),s(),d(),100===p||110===p||122===p||244===p||44===p||83===p||86===p||118===p||128===p){var g=l();if(3===g&&u(1),d(),d(),u(1),c())for(e=3!==g?8:12,r=0;r<e;r++)c()&&f(r<6?16:64)}d();var m=l();if(0===m)l();else if(1===m)for(u(1),h(),h(),t=l(),r=0;r<t;r++)h();d(),u(1);var v=l(),y=l(),w=A(1);0===w&&u(1),u(1),c()&&(n=l(),i=l(),o=l(),a=l());var b=[1,1];if(c()&&c())switch(s()){case 1:b=[1,1];break;case 2:b=[12,11];break;case 3:b=[10,11];break;case 4:b=[16,11];break;case 5:b=[40,33];break;case 6:b=[24,11];break;case 7:b=[20,11];break;case 8:b=[32,11];break;case 9:b=[80,33];break;case 10:b=[18,11];break;case 11:b=[15,11];break;case 12:b=[64,33];break;case 13:b=[160,99];break;case 14:b=[4,3];break;case 15:b=[3,2];break;case 16:b=[2,1];break;case 255:b=[s()<<8|s(),s()<<8|s()]}return{width:Math.ceil(16*(v+1)-2*n-2*i),height:(2-w)*(y+1)*16-(w?2:4)*(o+a),pixelRatio:b}},e.readSliceType=function(){return this.readUByte(),this.readUEG(),this.readUEG()},t}();e.default=i},"./src/demux/id3.ts":
|
|
|
/*!**************************!*\
|
|
|
!*** ./src/demux/id3.ts ***!
|
|
|
\**************************/
|
|
|
/*! exports provided: isHeader, isFooter, getID3Data, canParse, getTimeStamp, isTimeStampFrame, getID3Frames, decodeFrame, utf8ArrayToStr, testables */function(t,e,r){"use strict";r.r(e),r.d(e,"isHeader",(function(){return i})),r.d(e,"isFooter",(function(){return o})),r.d(e,"getID3Data",(function(){return a})),r.d(e,"canParse",(function(){return A})),r.d(e,"getTimeStamp",(function(){return l})),r.d(e,"isTimeStampFrame",(function(){return c})),r.d(e,"getID3Frames",(function(){return h})),r.d(e,"decodeFrame",(function(){return d})),r.d(e,"utf8ArrayToStr",(function(){return v})),r.d(e,"testables",(function(){return y}));var n,i=function(t,e){return e+10<=t.length&&73===t[e]&&68===t[e+1]&&51===t[e+2]&&t[e+3]<255&&t[e+4]<255&&t[e+6]<128&&t[e+7]<128&&t[e+8]<128&&t[e+9]<128},o=function(t,e){return e+10<=t.length&&51===t[e]&&68===t[e+1]&&73===t[e+2]&&t[e+3]<255&&t[e+4]<255&&t[e+6]<128&&t[e+7]<128&&t[e+8]<128&&t[e+9]<128},a=function(t,e){for(var r=e,n=0;i(t,e);)n+=10,n+=s(t,e+6),o(t,e+10)&&(n+=10),e+=n;if(n>0)return t.subarray(r,r+n)},s=function(t,e){var r=0;return r=(127&t[e])<<21,r|=(127&t[e+1])<<14,r|=(127&t[e+2])<<7,r|=127&t[e+3]},A=function(t,e){return i(t,e)&&s(t,e+6)+10<=t.length-e},l=function(t){for(var e=h(t),r=0;r<e.length;r++){var n=e[r];if(c(n))return m(n)}},c=function(t){return t&&"PRIV"===t.key&&"com.apple.streaming.transportStreamTimestamp"===t.info},u=function(t){var e=String.fromCharCode(t[0],t[1],t[2],t[3]),r=s(t,4);return{type:e,size:r,data:t.subarray(10,10+r)}},h=function(t){for(var e=0,r=[];i(t,e);){for(var n=s(t,e+6),a=(e+=10)+n;e+8<a;){var A=u(t.subarray(e)),l=d(A);l&&r.push(l),e+=A.size+10}o(t,e)&&(e+=10)}return r},d=function(t){return"PRIV"===t.type?f(t):"W"===t.type[0]?g(t):p(t)},f=function(t){if(!(t.size<2)){var e=v(t.data,!0),r=new Uint8Array(t.data.subarray(e.length+1));return{key:t.type,info:e,data:r.buffer}}},p=function(t){if(!(t.size<2)){if("TXXX"===t.type){var e=1,r=v(t.data.subarray(e),!0);e+=r.length+1;var n=v(t.data.subarray(e));return{key:t.type,info:r,data:n}}var i=v(t.data.subarray(1));return{key:t.type,data:i}}},g=function(t){if("WXXX"===t.type){if(t.size<2)return;var e=1,r=v(t.data.subarray(e),!0);e+=r.length+1;var n=v(t.data.subarray(e));return{key:t.type,info:r,data:n}}var i=v(t.data);return{key:t.type,data:i}},m=function(t){if(8===t.data.byteLength){var e=new Uint8Array(t.data),r=1&e[3],n=(e[4]<<23)+(e[5]<<15)+(e[6]<<7)+e[7];return n/=45,r&&(n+=47721858.84),Math.round(n)}},v=function(t,e){void 0===e&&(e=!1);var r=w();if(r){var n=r.decode(t);if(e){var i=n.indexOf("\0");return-1!==i?n.substring(0,i):n}return n.replace(/\0/g,"")}for(var o,a,s,A=t.length,l="",c=0;c<A;){if(0===(o=t[c++])&&e)return l;if(0!==o&&3!==o)switch(o>>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:l+=String.fromCharCode(o);break;case 12:case 13:a=t[c++],l+=String.fromCharCode((31&o)<<6|63&a);break;case 14:a=t[c++],s=t[c++],l+=String.fromCharCode((15&o)<<12|(63&a)<<6|(63&s)<<0)}}return l},y={decodeTextFrame:p};function w(){return n||void 0===self.TextDecoder||(n=new self.TextDecoder("utf-8")),n}},"./src/demux/mp3demuxer.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/demux/mp3demuxer.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ./base-audio-demuxer */"./src/demux/base-audio-demuxer.ts"),i=r(/*! ../demux/id3 */"./src/demux/id3.ts"),o=r(/*! ../utils/logger */"./src/utils/logger.ts"),a=r(/*! ./mpegaudio */"./src/demux/mpegaudio.ts");function s(t,e){return(s=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var A=function(t){var e,r;function n(){return t.apply(this,arguments)||this}r=t,(e=n).prototype=Object.create(r.prototype),e.prototype.constructor=e,s(e,r);var A=n.prototype;return A.resetInitSegment=function(e,r,n){t.prototype.resetInitSegment.call(this,e,r,n),this._audioTrack={container:"audio/mpeg",type:"audio",id:2,pid:-1,sequenceNumber:0,isAAC:!1,samples:[],manifestCodec:e,duration:n,inputTimeScale:9e4,dropped:0}},n.probe=function(t){if(!t)return!1;for(var e=(i.getID3Data(t,0)||[]).length,r=t.length;e<r;e++)if(a.probe(t,e))return o.logger.log("MPEG Audio sync word found !"),!0;return!1},A.canParse=function(t,e){return a.canParse(t,e)},A.appendFrame=function(t,e,r){if(null!==this.initPTS)return a.appendFrame(t,e,r,this.initPTS,this.frameIndex)},n}(n.default);A.minProbeByteLength=4,e.default=A},"./src/demux/mp4demuxer.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/demux/mp4demuxer.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../utils/mp4-tools */"./src/utils/mp4-tools.ts"),i=r(/*! ./dummy-demuxed-track */"./src/demux/dummy-demuxed-track.ts"),o=function(){function t(t,e){this.remainderData=null,this.config=void 0,this.config=e}var e=t.prototype;return e.resetTimeStamp=function(){},e.resetInitSegment=function(){},e.resetContiguity=function(){},t.probe=function(t){return Object(n.findBox)({data:t,start:0,end:Math.min(t.length,16384)},["moof"]).length>0},e.demux=function(t){var e=t,r=Object(i.dummyTrack)();if(this.config.progressive){this.remainderData&&(e=Object(n.appendUint8Array)(this.remainderData,t));var o=Object(n.segmentValidRange)(e);this.remainderData=o.remainder,r.samples=o.valid||new Uint8Array}else r.samples=e;return{audioTrack:Object(i.dummyTrack)(),avcTrack:r,id3Track:Object(i.dummyTrack)(),textTrack:Object(i.dummyTrack)()}},e.flush=function(){var t=Object(i.dummyTrack)();return t.samples=this.remainderData||new Uint8Array,this.remainderData=null,{audioTrack:Object(i.dummyTrack)(),avcTrack:t,id3Track:Object(i.dummyTrack)(),textTrack:Object(i.dummyTrack)()}},e.demuxSampleAes=function(t,e,r){return Promise.reject(new Error("The MP4 demuxer does not support SAMPLE-AES decryption"))},e.destroy=function(){},t}();o.minProbeByteLength=1024,e.default=o},"./src/demux/mpegaudio.ts":
|
|
|
/*!********************************!*\
|
|
|
!*** ./src/demux/mpegaudio.ts ***!
|
|
|
\********************************/
|
|
|
/*! exports provided: appendFrame, parseHeader, isHeaderPattern, isHeader, canParse, probe */function(t,e,r){"use strict";r.r(e),r.d(e,"appendFrame",(function(){return A})),r.d(e,"parseHeader",(function(){return l})),r.d(e,"isHeaderPattern",(function(){return c})),r.d(e,"isHeader",(function(){return u})),r.d(e,"canParse",(function(){return h})),r.d(e,"probe",(function(){return d}));var n=null,i=[32,64,96,128,160,192,224,256,288,320,352,384,416,448,32,48,56,64,80,96,112,128,160,192,224,256,320,384,32,40,48,56,64,80,96,112,128,160,192,224,256,320,32,48,56,64,80,96,112,128,144,160,176,192,224,256,8,16,24,32,40,48,56,64,80,96,112,128,144,160],o=[44100,48e3,32e3,22050,24e3,16e3,11025,12e3,8e3],a=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],s=[0,1,1,4];function A(t,e,r,n,i){if(!(r+24>e.length)){var o=l(e,r);if(o&&r+o.frameLength<=e.length){var a=n+i*(9e4*o.samplesPerFrame/o.sampleRate),s={unit:e.subarray(r,r+o.frameLength),pts:a,dts:a};return t.config=[],t.channelCount=o.channelCount,t.samplerate=o.sampleRate,t.samples.push(s),{sample:s,length:o.frameLength,missing:0}}}}function l(t,e){var r=t[e+1]>>3&3,A=t[e+1]>>1&3,l=t[e+2]>>4&15,c=t[e+2]>>2&3;if(1!==r&&0!==l&&15!==l&&3!==c){var u=t[e+2]>>1&1,h=t[e+3]>>6,d=1e3*i[14*(3===r?3-A:3===A?3:4)+l-1],f=o[3*(3===r?0:2===r?1:2)+c],p=3===h?1:2,g=a[r][A],m=s[A],v=8*g*m,y=Math.floor(g*d/f+u)*m;if(null===n){var w=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);n=w?parseInt(w[1]):0}return!!n&&n<=87&&2===A&&d>=224e3&&0===h&&(t[e+3]=128|t[e+3]),{sampleRate:f,channelCount:p,frameLength:y,samplesPerFrame:v}}}function c(t,e){return 255===t[e]&&224==(224&t[e+1])&&0!=(6&t[e+1])}function u(t,e){return e+1<t.length&&c(t,e)}function h(t,e){return c(t,e)&&4<=t.length-e}function d(t,e){if(e+1<t.length&&c(t,e)){var r=l(t,e),n=4;null!=r&&r.frameLength&&(n=r.frameLength);var i=e+n;return i===t.length||u(t,i)}return!1}},"./src/demux/sample-aes.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/demux/sample-aes.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../crypt/decrypter */"./src/crypt/decrypter.ts"),i=r(/*! ./tsdemuxer */"./src/demux/tsdemuxer.ts"),o=function(){function t(t,e,r){this.keyData=void 0,this.decrypter=void 0,this.keyData=r,this.decrypter=new n.default(t,e,{removePKCS7Padding:!1})}var e=t.prototype;return e.decryptBuffer=function(t,e){this.decrypter.decrypt(t,this.keyData.key.buffer,this.keyData.iv.buffer,e)},e.decryptAacSample=function(t,e,r,n){var i=t[e].unit,o=i.subarray(16,i.length-i.length%16),a=o.buffer.slice(o.byteOffset,o.byteOffset+o.length),s=this;this.decryptBuffer(a,(function(o){var a=new Uint8Array(o);i.set(a,16),n||s.decryptAacSamples(t,e+1,r)}))},e.decryptAacSamples=function(t,e,r){for(;;e++){if(e>=t.length)return void r();if(!(t[e].unit.length<32)){var n=this.decrypter.isSync();if(this.decryptAacSample(t,e,r,n),!n)return}}},e.getAvcEncryptedData=function(t){for(var e=16*Math.floor((t.length-48)/160)+16,r=new Int8Array(e),n=0,i=32;i<=t.length-16;i+=160,n+=16)r.set(t.subarray(i,i+16),n);return r},e.getAvcDecryptedUnit=function(t,e){for(var r=new Uint8Array(e),n=0,i=32;i<=t.length-16;i+=160,n+=16)t.set(r.subarray(n,n+16),i);return t},e.decryptAvcSample=function(t,e,r,n,o,a){var s=Object(i.discardEPB)(o.data),A=this.getAvcEncryptedData(s),l=this;this.decryptBuffer(A.buffer,(function(i){o.data=l.getAvcDecryptedUnit(s,i),a||l.decryptAvcSamples(t,e,r+1,n)}))},e.decryptAvcSamples=function(t,e,r,n){if(t instanceof Uint8Array)throw new Error("Cannot decrypt samples of type Uint8Array");for(;;e++,r=0){if(e>=t.length)return void n();for(var i=t[e].units;!(r>=i.length);r++){var o=i[r];if(!(o.data.length<=48||1!==o.type&&5!==o.type)){var a=this.decrypter.isSync();if(this.decryptAvcSample(t,e,r,n,o,a),!a)return}}}},t}();e.default=o},"./src/demux/transmuxer-interface.ts":
|
|
|
/*!*******************************************!*\
|
|
|
!*** ./src/demux/transmuxer-interface.ts ***!
|
|
|
\*******************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return u}));var n=r(/*! webworkify-webpack */"./node_modules/webworkify-webpack/index.js"),i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../demux/transmuxer */"./src/demux/transmuxer.ts"),a=r(/*! ../utils/logger */"./src/utils/logger.ts"),s=r(/*! ../errors */"./src/errors.ts"),A=r(/*! ../utils/mediasource-helper */"./src/utils/mediasource-helper.ts"),l=r(/*! eventemitter3 */"./node_modules/eventemitter3/index.js"),c=Object(A.getMediaSource)()||{isTypeSupported:function(){return!1}},u=function(){function t(t,e,r,A){var u=this;this.hls=void 0,this.id=void 0,this.observer=void 0,this.frag=null,this.part=null,this.worker=void 0,this.onwmsg=void 0,this.transmuxer=null,this.onTransmuxComplete=void 0,this.onFlush=void 0,this.hls=t,this.id=e,this.onTransmuxComplete=r,this.onFlush=A;var h=t.config,d=function(e,r){(r=r||{}).frag=u.frag,r.id=u.id,t.trigger(e,r)};this.observer=new l.EventEmitter,this.observer.on(i.Events.FRAG_DECRYPTED,d),this.observer.on(i.Events.ERROR,d);var f={mp4:c.isTypeSupported("video/mp4"),mpeg:c.isTypeSupported("audio/mpeg"),mp3:c.isTypeSupported('audio/mp4; codecs="mp3"')},p=navigator.vendor;if(h.enableWorker&&"undefined"!=typeof Worker){var g;a.logger.log("demuxing in webworker");try{g=this.worker=n(/*! ../demux/transmuxer-worker.ts */"./src/demux/transmuxer-worker.ts"),this.onwmsg=this.onWorkerMessage.bind(this),g.addEventListener("message",this.onwmsg),g.onerror=function(e){t.trigger(i.Events.ERROR,{type:s.ErrorTypes.OTHER_ERROR,details:s.ErrorDetails.INTERNAL_EXCEPTION,fatal:!0,event:"demuxerWorker",error:new Error(e.message+" ("+e.filename+":"+e.lineno+")")})},g.postMessage({cmd:"init",typeSupported:f,vendor:p,id:e,config:JSON.stringify(h)})}catch(t){a.logger.warn("Error in worker:",t),a.logger.error("Error while initializing DemuxerWorker, fallback to inline"),g&&self.URL.revokeObjectURL(g.objectURL),this.transmuxer=new o.default(this.observer,f,h,p,e),this.worker=null}}else this.transmuxer=new o.default(this.observer,f,h,p,e)}var e=t.prototype;return e.destroy=function(){var t=this.worker;if(t)t.removeEventListener("message",this.onwmsg),t.terminate(),this.worker=null;else{var e=this.transmuxer;e&&(e.destroy(),this.transmuxer=null)}var r=this.observer;r&&r.removeAllListeners(),this.observer=null},e.push=function(t,e,r,n,i,s,A,l,c,u){var h=this;c.transmuxing.start=self.performance.now();var d=this.transmuxer,f=this.worker,p=s?s.start:i.start,g=i.decryptdata,m=this.frag,v=!(m&&i.cc===m.cc),y=!(m&&c.level===m.level),w=m?c.sn-m.sn:-1,b=this.part?c.part-this.part.index:1,C=!y&&(1===w||0===w&&1===b),B=self.performance.now();(y||w||0===i.stats.parsing.start)&&(i.stats.parsing.start=B),!s||!b&&C||(s.stats.parsing.start=B);var x=new o.TransmuxState(v,C,l,y,p);if(!C||v){a.logger.log("[transmuxer-interface, "+i.type+"]: Starting new transmux session for sn: "+c.sn+" p: "+c.part+" level: "+c.level+" id: "+c.id+"\n discontinuity: "+v+"\n trackSwitch: "+y+"\n contiguous: "+C+"\n accurateTimeOffset: "+l+"\n timeOffset: "+p);var E=new o.TransmuxConfig(r,n,e,A,u);this.configureTransmuxer(E)}if(this.frag=i,this.part=s,f)f.postMessage({cmd:"demux",data:t,decryptdata:g,chunkMeta:c,state:x},t instanceof ArrayBuffer?[t]:[]);else if(d){var S=d.push(t,g,c,x);Object(o.isPromise)(S)?S.then((function(t){h.handleTransmuxComplete(t)})):this.handleTransmuxComplete(S)}},e.flush=function(t){var e=this;t.transmuxing.start=self.performance.now();var r=this.transmuxer,n=this.worker;if(n)n.postMessage({cmd:"flush",chunkMeta:t});else if(r){var i=r.flush(t);Object(o.isPromise)(i)?i.then((function(r){e.handleFlushResult(r,t)})):this.handleFlushResult(i,t)}},e.handleFlushResult=function(t,e){var r=this;t.forEach((function(t){r.handleTransmuxComplete(t)})),this.onFlush(e)},e.onWorkerMessage=function(t){var e=t.data,r=this.hls;switch(e.event){case"init":self.URL.revokeObjectURL(this.worker.objectURL);break;case"transmuxComplete":this.handleTransmuxComplete(e.data);break;case"flush":this.onFlush(e.data);break;default:e.data=e.data||{},e.data.frag=this.frag,e.data.id=this.id,r.trigger(e.event,e.data)}},e.configureTransmuxer=function(t){var e=this.worker,r=this.transmuxer;e?e.postMessage({cmd:"configure",config:t}):r&&r.configure(t)},e.handleTransmuxComplete=function(t){t.chunkMeta.transmuxing.end=self.performance.now(),this.onTransmuxComplete(t)},t}()},"./src/demux/transmuxer-worker.ts":
|
|
|
/*!****************************************!*\
|
|
|
!*** ./src/demux/transmuxer-worker.ts ***!
|
|
|
\****************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return s}));var n=r(/*! ../demux/transmuxer */"./src/demux/transmuxer.ts"),i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../utils/logger */"./src/utils/logger.ts"),a=r(/*! eventemitter3 */"./node_modules/eventemitter3/index.js");function s(t){var e=new a.EventEmitter,r=function(e,r){t.postMessage({event:e,data:r})};e.on(i.Events.FRAG_DECRYPTED,r),e.on(i.Events.ERROR,r),t.addEventListener("message",(function(i){var a=i.data;switch(a.cmd){case"init":var s=JSON.parse(a.config);t.transmuxer=new n.default(e,a.typeSupported,s,a.vendor,a.id),Object(o.enableLogs)(s.debug),r("init",null);break;case"configure":t.transmuxer.configure(a.config);break;case"demux":var l=t.transmuxer.push(a.data,a.decryptdata,a.chunkMeta,a.state);Object(n.isPromise)(l)?l.then((function(e){A(t,e)})):A(t,l);break;case"flush":var u=a.chunkMeta,h=t.transmuxer.flush(u);Object(n.isPromise)(h)?h.then((function(e){c(t,e,u)})):c(t,h,u)}}))}function A(t,e){if((r=e.remuxResult).audio||r.video||r.text||r.id3||r.initSegment){var r,n=[],i=e.remuxResult,o=i.audio,a=i.video;o&&l(n,o),a&&l(n,a),t.postMessage({event:"transmuxComplete",data:e},n)}}function l(t,e){e.data1&&t.push(e.data1.buffer),e.data2&&t.push(e.data2.buffer)}function c(t,e,r){e.forEach((function(e){A(t,e)})),t.postMessage({event:"flush",data:r})}},"./src/demux/transmuxer.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/demux/transmuxer.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default, isPromise, TransmuxConfig, TransmuxState */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return v})),r.d(e,"isPromise",(function(){return w})),r.d(e,"TransmuxConfig",(function(){return b})),r.d(e,"TransmuxState",(function(){return C}));var n,i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../errors */"./src/errors.ts"),a=r(/*! ../crypt/decrypter */"./src/crypt/decrypter.ts"),s=r(/*! ../demux/aacdemuxer */"./src/demux/aacdemuxer.ts"),A=r(/*! ../demux/mp4demuxer */"./src/demux/mp4demuxer.ts"),l=r(/*! ../demux/tsdemuxer */"./src/demux/tsdemuxer.ts"),c=r(/*! ../demux/mp3demuxer */"./src/demux/mp3demuxer.ts"),u=r(/*! ../remux/mp4-remuxer */"./src/remux/mp4-remuxer.ts"),h=r(/*! ../remux/passthrough-remuxer */"./src/remux/passthrough-remuxer.ts"),d=r(/*! ./chunk-cache */"./src/demux/chunk-cache.ts"),f=r(/*! ../utils/mp4-tools */"./src/utils/mp4-tools.ts"),p=r(/*! ../utils/logger */"./src/utils/logger.ts");try{n=self.performance.now.bind(self.performance)}catch(t){p.logger.debug("Unable to use Performance API on this environment"),n=self.Date.now}var g=[{demux:l.default,remux:u.default},{demux:A.default,remux:h.default},{demux:s.default,remux:u.default},{demux:c.default,remux:u.default}],m=1024;g.forEach((function(t){var e=t.demux;m=Math.max(m,e.minProbeByteLength)}));var v=function(){function t(t,e,r,n,i){this.observer=void 0,this.typeSupported=void 0,this.config=void 0,this.vendor=void 0,this.id=void 0,this.demuxer=void 0,this.remuxer=void 0,this.decrypter=void 0,this.probe=void 0,this.decryptionPromise=null,this.transmuxConfig=void 0,this.currentTransmuxState=void 0,this.cache=new d.default,this.observer=t,this.typeSupported=e,this.config=r,this.vendor=n,this.id=i}var e=t.prototype;return e.configure=function(t){this.transmuxConfig=t,this.decrypter&&this.decrypter.reset()},e.push=function(t,e,r,i){var o=this,a=r.transmuxing;a.executeStart=n();var s=new Uint8Array(t),A=this.cache,l=this.config,c=this.currentTransmuxState,u=this.transmuxConfig;i&&(this.currentTransmuxState=i);var h=function(t,e){var r=null;return t.byteLength>0&&null!=e&&null!=e.key&&null!==e.iv&&null!=e.method&&(r=e),r}(s,e);if(h&&"AES-128"===h.method){var d=this.getDecrypter();if(!l.enableSoftwareAES)return this.decryptionPromise=d.webCryptoDecrypt(s,h.key.buffer,h.iv.buffer).then((function(t){var e=o.push(t,null,r);return o.decryptionPromise=null,e})),this.decryptionPromise;var p=d.softwareDecrypt(s,h.key.buffer,h.iv.buffer);if(!p)return a.executeEnd=n(),y(r);s=new Uint8Array(p)}var g=i||c,m=g.contiguous,v=g.discontinuity,w=g.trackSwitch,b=g.accurateTimeOffset,C=g.timeOffset,B=u.audioCodec,x=u.videoCodec,E=u.defaultInitPts,S=u.duration,k=u.initSegmentData;if((v||w)&&this.resetInitSegment(k,B,x,S),v&&this.resetInitialTimestamp(E),m||this.resetContiguity(),this.needsProbing(s,v,w)){if(A.dataLength){var T=A.flush();s=Object(f.appendUint8Array)(T,s)}this.configureTransmuxer(s,u)}var F=this.transmux(s,h,C,b,r),L=this.currentTransmuxState;return L.contiguous=!0,L.discontinuity=!1,L.trackSwitch=!1,a.executeEnd=n(),F},e.flush=function(t){var e=this,r=t.transmuxing;r.executeStart=n();var a=this.decrypter,s=this.cache,A=this.currentTransmuxState,l=this.decryptionPromise;if(l)return l.then((function(){return e.flush(t)}));var c=[],u=A.timeOffset;if(a){var h=a.flush();h&&c.push(this.push(h,null,t))}var d=s.dataLength;s.reset();var f=this.demuxer,p=this.remuxer;if(!f||!p)return d>=m&&this.observer.emit(i.Events.ERROR,i.Events.ERROR,{type:o.ErrorTypes.MEDIA_ERROR,details:o.ErrorDetails.FRAG_PARSING_ERROR,fatal:!0,reason:"no demux matching with content found"}),r.executeEnd=n(),[y(t)];var g=f.flush(u);return w(g)?g.then((function(r){return e.flushRemux(c,r,t),c})):(this.flushRemux(c,g,t),c)},e.flushRemux=function(t,e,r){var i=e.audioTrack,o=e.avcTrack,a=e.id3Track,s=e.textTrack,A=this.currentTransmuxState,l=A.accurateTimeOffset,c=A.timeOffset;p.logger.log("[transmuxer.ts]: Flushed fragment "+r.sn+(r.part>-1?" p: "+r.part:"")+" of level "+r.level);var u=this.remuxer.remux(i,o,a,s,c,l,!0,this.id);t.push({remuxResult:u,chunkMeta:r}),r.transmuxing.executeEnd=n()},e.resetInitialTimestamp=function(t){var e=this.demuxer,r=this.remuxer;e&&r&&(e.resetTimeStamp(t),r.resetTimeStamp(t))},e.resetContiguity=function(){var t=this.demuxer,e=this.remuxer;t&&e&&(t.resetContiguity(),e.resetNextTimestamp())},e.resetInitSegment=function(t,e,r,n){var i=this.demuxer,o=this.remuxer;i&&o&&(i.resetInitSegment(e,r,n),o.resetInitSegment(t,e,r))},e.destroy=function(){this.demuxer&&(this.demuxer.destroy(),this.demuxer=void 0),this.remuxer&&(this.remuxer.destroy(),this.remuxer=void 0)},e.transmux=function(t,e,r,n,i){return e&&"SAMPLE-AES"===e.method?this.transmuxSampleAes(t,e,r,n,i):this.transmuxUnencrypted(t,r,n,i)},e.transmuxUnencrypted=function(t,e,r,n){var i=this.demuxer.demux(t,e,!1,!this.config.progressive),o=i.audioTrack,a=i.avcTrack,s=i.id3Track,A=i.textTrack;return{remuxResult:this.remuxer.remux(o,a,s,A,e,r,!1,this.id),chunkMeta:n}},e.transmuxSampleAes=function(t,e,r,n,i){var o=this;return this.demuxer.demuxSampleAes(t,e,r).then((function(t){return{remuxResult:o.remuxer.remux(t.audioTrack,t.avcTrack,t.id3Track,t.textTrack,r,n,!1,o.id),chunkMeta:i}}))},e.configureTransmuxer=function(t,e){for(var r,n=this.config,i=this.observer,o=this.typeSupported,a=this.vendor,s=e.audioCodec,l=e.defaultInitPts,c=e.duration,u=e.initSegmentData,d=e.videoCodec,f=0,m=g.length;f<m;f++)if(g[f].demux.probe(t)){r=g[f];break}r||(p.logger.warn("Failed to find demuxer by probing frag, treating as mp4 passthrough"),r={demux:A.default,remux:h.default});var v=this.demuxer,y=this.remuxer,w=r.remux,b=r.demux;y&&y instanceof w||(this.remuxer=new w(i,n,o,a)),v&&v instanceof b||(this.demuxer=new b(i,n,o),this.probe=b.probe),this.resetInitSegment(u,s,d,c),this.resetInitialTimestamp(l)},e.needsProbing=function(t,e,r){return!this.demuxer||!this.remuxer||e||r},e.getDecrypter=function(){var t=this.decrypter;return t||(t=this.decrypter=new a.default(this.observer,this.config)),t},t}(),y=function(t){return{remuxResult:{},chunkMeta:t}};function w(t){return"then"in t&&t.then instanceof Function}var b=function(t,e,r,n,i){this.audioCodec=void 0,this.videoCodec=void 0,this.initSegmentData=void 0,this.duration=void 0,this.defaultInitPts=void 0,this.audioCodec=t,this.videoCodec=e,this.initSegmentData=r,this.duration=n,this.defaultInitPts=i},C=function(t,e,r,n,i){this.discontinuity=void 0,this.contiguous=void 0,this.accurateTimeOffset=void 0,this.trackSwitch=void 0,this.timeOffset=void 0,this.discontinuity=t,this.contiguous=e,this.accurateTimeOffset=r,this.trackSwitch=n,this.timeOffset=i}},"./src/demux/tsdemuxer.ts":
|
|
|
/*!********************************!*\
|
|
|
!*** ./src/demux/tsdemuxer.ts ***!
|
|
|
\********************************/
|
|
|
/*! exports provided: discardEPB, default */function(t,e,r){"use strict";r.r(e),r.d(e,"discardEPB",(function(){return w}));var n=r(/*! ./adts */"./src/demux/adts.ts"),i=r(/*! ./mpegaudio */"./src/demux/mpegaudio.ts"),o=r(/*! ./exp-golomb */"./src/demux/exp-golomb.ts"),a=r(/*! ./id3 */"./src/demux/id3.ts"),s=r(/*! ./sample-aes */"./src/demux/sample-aes.ts"),A=r(/*! ../events */"./src/events.ts"),l=r(/*! ../utils/mp4-tools */"./src/utils/mp4-tools.ts"),c=r(/*! ../utils/logger */"./src/utils/logger.ts"),u=r(/*! ../errors */"./src/errors.ts"),h={video:1,audio:2,id3:3,text:4},d=function(){function t(t,e,r){this.observer=void 0,this.config=void 0,this.typeSupported=void 0,this.sampleAes=null,this.pmtParsed=!1,this.audioCodec=void 0,this.videoCodec=void 0,this._duration=0,this.aacLastPTS=null,this._initPTS=null,this._initDTS=null,this._pmtId=-1,this._avcTrack=void 0,this._audioTrack=void 0,this._id3Track=void 0,this._txtTrack=void 0,this.aacOverFlow=null,this.avcSample=null,this.remainderData=null,this.observer=t,this.config=e,this.typeSupported=r}t.probe=function(e){var r=t.syncOffset(e);return!(r<0||(r&&c.logger.warn("MPEG2-TS detected but first sync word found @ offset "+r+", junk ahead ?"),0))},t.syncOffset=function(t){for(var e=Math.min(1e3,t.length-564),r=0;r<e;){if(71===t[r]&&71===t[r+188]&&71===t[r+376])return r;r++}return-1},t.createTrack=function(t,e){return{container:"video"===t||"audio"===t?"video/mp2t":void 0,type:t,id:h[t],pid:-1,inputTimeScale:9e4,sequenceNumber:0,samples:[],dropped:0,duration:"audio"===t?e:void 0}};var e=t.prototype;return e.resetInitSegment=function(e,r,n){this.pmtParsed=!1,this._pmtId=-1,this._avcTrack=t.createTrack("video",n),this._audioTrack=t.createTrack("audio",n),this._id3Track=t.createTrack("id3",n),this._txtTrack=t.createTrack("text",n),this._audioTrack.isAAC=!0,this.aacOverFlow=null,this.aacLastPTS=null,this.avcSample=null,this.audioCodec=e,this.videoCodec=r,this._duration=n},e.resetTimeStamp=function(){},e.resetContiguity=function(){var t=this._audioTrack,e=this._avcTrack,r=this._id3Track;t&&(t.pesData=null),e&&(e.pesData=null),r&&(r.pesData=null),this.aacOverFlow=null,this.aacLastPTS=null},e.demux=function(e,r,n,i){var o;void 0===n&&(n=!1),void 0===i&&(i=!1),n||(this.sampleAes=null);var a=this._avcTrack,s=this._audioTrack,h=this._id3Track,d=a.pid,f=a.pesData,v=s.pid,y=h.pid,w=s.pesData,b=h.pesData,C=!1,B=this.pmtParsed,x=this._pmtId,E=e.length;if(this.remainderData&&(E=(e=Object(l.appendUint8Array)(this.remainderData,e)).length,this.remainderData=null),E<188&&!i)return this.remainderData=e,{audioTrack:s,avcTrack:a,id3Track:h,textTrack:this._txtTrack};var S=Math.max(0,t.syncOffset(e));(E-=(E+S)%188)<e.byteLength&&!i&&(this.remainderData=new Uint8Array(e.buffer,E,e.buffer.byteLength-E));for(var k=S;k<E;k+=188)if(71===e[k]){var T=!!(64&e[k+1]),F=((31&e[k+1])<<8)+e[k+2],L=void 0;if((48&e[k+3])>>4>1){if((L=k+5+e[k+4])===k+188)continue}else L=k+4;switch(F){case d:T&&(f&&(o=m(f))&&this.parseAVCPES(o,!1),f={data:[],size:0}),f&&(f.data.push(e.subarray(L,k+188)),f.size+=k+188-L);break;case v:T&&(w&&(o=m(w))&&(s.isAAC?this.parseAACPES(o):this.parseMPEGPES(o)),w={data:[],size:0}),w&&(w.data.push(e.subarray(L,k+188)),w.size+=k+188-L);break;case y:T&&(b&&(o=m(b))&&this.parseID3PES(o),b={data:[],size:0}),b&&(b.data.push(e.subarray(L,k+188)),b.size+=k+188-L);break;case 0:T&&(L+=e[L]+1),x=this._pmtId=p(e,L);break;case x:T&&(L+=e[L]+1);var I=g(e,L,!0===this.typeSupported.mpeg||!0===this.typeSupported.mp3,n);(d=I.avc)>0&&(a.pid=d),(v=I.audio)>0&&(s.pid=v,s.isAAC=I.isAAC),(y=I.id3)>0&&(h.pid=y),C&&!B&&(c.logger.log("reparse from beginning"),C=!1,k=S-188),B=this.pmtParsed=!0;break;case 17:case 8191:break;default:C=!0}}else this.observer.emit(A.Events.ERROR,A.Events.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.FRAG_PARSING_ERROR,fatal:!1,reason:"TS packet did not start with 0x47"});a.pesData=f,s.pesData=w,h.pesData=b;var _={audioTrack:s,avcTrack:a,id3Track:h,textTrack:this._txtTrack};return i&&this.extractRemainingSamples(_),_},e.flush=function(){var t,e=this.remainderData;return this.remainderData=null,t=e?this.demux(e,-1,!1,!0):{audioTrack:this._audioTrack,avcTrack:this._avcTrack,textTrack:this._txtTrack,id3Track:this._id3Track},this.extractRemainingSamples(t),this.sampleAes?this.decrypt(t,this.sampleAes):t},e.extractRemainingSamples=function(t){var e,r=t.audioTrack,n=t.avcTrack,i=t.id3Track,o=n.pesData,a=r.pesData,s=i.pesData;o&&(e=m(o))?(this.parseAVCPES(e,!0),n.pesData=null):n.pesData=o,a&&(e=m(a))?(r.isAAC?this.parseAACPES(e):this.parseMPEGPES(e),r.pesData=null):(null!=a&&a.size&&c.logger.log("last AAC PES packet truncated,might overlap between fragments"),r.pesData=a),s&&(e=m(s))?(this.parseID3PES(e),i.pesData=null):i.pesData=s},e.demuxSampleAes=function(t,e,r){var n=this.demux(t,r,!0,!this.config.progressive),i=this.sampleAes=new s.default(this.observer,this.config,e);return this.decrypt(n,i)},e.decrypt=function(t,e){return new Promise((function(r){var n=t.audioTrack,i=t.avcTrack;n.samples&&n.isAAC?e.decryptAacSamples(n.samples,0,(function(){i.samples?e.decryptAvcSamples(i.samples,0,0,(function(){r(t)})):r(t)})):i.samples&&e.decryptAvcSamples(i.samples,0,0,(function(){r(t)}))}))},e.destroy=function(){this._initPTS=this._initDTS=null,this._duration=0},e.parseAVCPES=function(t,e){var r,n=this,i=this._avcTrack,s=this.parseAVCNALu(t.data),A=this.avcSample,l=!1;t.data=null,A&&s.length&&!i.audFound&&(v(A,i),A=this.avcSample=f(!1,t.pts,t.dts,"")),s.forEach((function(e){switch(e.type){case 1:r=!0,A||(A=n.avcSample=f(!0,t.pts,t.dts,"")),A.frame=!0;var s=e.data;if(l&&s.length>4){var c=new o.default(s).readSliceType();2!==c&&4!==c&&7!==c&&9!==c||(A.key=!0)}break;case 5:r=!0,A||(A=n.avcSample=f(!0,t.pts,t.dts,"")),A.key=!0,A.frame=!0;break;case 6:r=!0;var u=new o.default(w(e.data));u.readUByte();for(var h=0,d=0,p=!1,g=0;!p&&u.bytesAvailable>1;){h=0;do{h+=g=u.readUByte()}while(255===g);d=0;do{d+=g=u.readUByte()}while(255===g);if(4===h&&0!==u.bytesAvailable){if(p=!0,181===u.readUByte()&&49===u.readUShort()&&1195456820===u.readUInt()&&3===u.readUByte()){for(var m=u.readUByte(),b=31&m,C=[m,u.readUByte()],B=0;B<b;B++)C.push(u.readUByte()),C.push(u.readUByte()),C.push(u.readUByte());y(n._txtTrack.samples,{type:3,pts:t.pts,bytes:C})}}else if(5===h&&0!==u.bytesAvailable){if(p=!0,d>16){for(var x=[],E=0;E<16;E++)x.push(u.readUByte().toString(16)),3!==E&&5!==E&&7!==E&&9!==E||x.push("-");for(var S=d-16,k=new Uint8Array(S),T=0;T<S;T++)k[T]=u.readUByte();y(n._txtTrack.samples,{pts:t.pts,payloadType:h,uuid:x.join(""),userData:Object(a.utf8ArrayToStr)(k),userDataBytes:k})}}else if(d<u.bytesAvailable)for(var F=0;F<d;F++)u.readUByte()}break;case 7:if(r=!0,l=!0,!i.sps){var L=new o.default(e.data).readSPS();i.width=L.width,i.height=L.height,i.pixelRatio=L.pixelRatio,i.sps=[e.data],i.duration=n._duration;for(var I=e.data.subarray(1,4),_="avc1.",U=0;U<3;U++){var O=I[U].toString(16);O.length<2&&(O="0"+O),_+=O}i.codec=_}break;case 8:r=!0,i.pps||(i.pps=[e.data]);break;case 9:r=!1,i.audFound=!0,A&&v(A,i),A=n.avcSample=f(!1,t.pts,t.dts,"");break;case 12:r=!1;break;default:r=!1,A&&(A.debug+="unknown NAL "+e.type+" ")}A&&r&&A.units.push(e)})),e&&A&&(v(A,i),this.avcSample=null)},e.getLastNalUnit=function(){var t,e,r=this.avcSample;if(!r||0===r.units.length){var n=this._avcTrack.samples;r=n[n.length-1]}if(null!==(t=r)&&void 0!==t&&t.units){var i=r.units;e=i[i.length-1]}return e},e.parseAVCNALu=function(t){var e,r,n=t.byteLength,i=this._avcTrack,o=i.naluState||0,a=o,s=[],A=0,l=-1,c=0;for(-1===o&&(l=0,c=31&t[0],o=0,A=1);A<n;)if(e=t[A++],o)if(1!==o)if(e)if(1===e){if(l>=0){var u={data:t.subarray(l,A-o-1),type:c};s.push(u)}else{var h=this.getLastNalUnit();if(h&&(a&&A<=4-a&&h.state&&(h.data=h.data.subarray(0,h.data.byteLength-a)),(r=A-o-1)>0)){var d=new Uint8Array(h.data.byteLength+r);d.set(h.data,0),d.set(t.subarray(0,r),h.data.byteLength),h.data=d,h.state=0}}A<n?(l=A,c=31&t[A],o=0):o=-1}else o=0;else o=3;else o=e?0:2;else o=e?0:1;if(l>=0&&o>=0){var f={data:t.subarray(l,n),type:c,state:o};s.push(f)}if(0===s.length){var p=this.getLastNalUnit();if(p){var g=new Uint8Array(p.data.byteLength+t.byteLength);g.set(p.data,0),g.set(t,p.data.byteLength),p.data=g}}return i.naluState=o,s},e.parseAACPES=function(t){var e,r,i,o,a,s=0,l=this._audioTrack,h=this.aacOverFlow,d=t.data;if(h){this.aacOverFlow=null;var f=h.sample.unit.byteLength,p=Math.min(h.missing,f),g=f-p;h.sample.unit.set(d.subarray(0,p),g),l.samples.push(h.sample),s=h.missing}for(e=s,r=d.length;e<r-1&&!n.isHeader(d,e);e++);if(e===s||(e<r-1?(i="AAC PES did not start with ADTS header,offset:"+e,o=!1):(i="no ADTS header found in AAC PES",o=!0),c.logger.warn("parsing error:"+i),this.observer.emit(A.Events.ERROR,A.Events.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.FRAG_PARSING_ERROR,fatal:o,reason:i}),!o)){if(n.initTrackConfig(l,this.observer,d,e,this.audioCodec),void 0!==t.pts)a=t.pts;else{if(!h)return void c.logger.warn("[tsdemuxer]: AAC PES unknown PTS");var m=n.getFrameDuration(l.samplerate);a=h.sample.pts+m}for(var v=0;e<r;){if(n.isHeader(d,e)){if(e+5<r){var y=n.appendFrame(l,d,e,a,v);if(y){if(!y.missing){e+=y.length,v++;continue}this.aacOverFlow=y}}break}e++}}},e.parseMPEGPES=function(t){var e=t.data,r=e.length,n=0,o=0,a=t.pts;if(void 0!==a)for(;o<r;)if(i.isHeader(e,o)){var s=i.appendFrame(this._audioTrack,e,o,a,n);if(!s)break;o+=s.length,n++}else o++;else c.logger.warn("[tsdemuxer]: MPEG PES unknown PTS")},e.parseID3PES=function(t){void 0!==t.pts?this._id3Track.samples.push(t):c.logger.warn("[tsdemuxer]: ID3 PES unknown PTS")},t}();function f(t,e,r,n){return{key:t,frame:!1,pts:e,dts:r,units:[],debug:n,length:0}}function p(t,e){return(31&t[e+10])<<8|t[e+11]}function g(t,e,r,n){var i={audio:-1,avc:-1,id3:-1,isAAC:!0},o=e+3+((15&t[e+1])<<8|t[e+2])-4;for(e+=12+((15&t[e+10])<<8|t[e+11]);e<o;){var a=(31&t[e+1])<<8|t[e+2];switch(t[e]){case 207:if(!n){c.logger.log("ADTS AAC with AES-128-CBC frame encryption found in unencrypted stream");break}case 15:-1===i.audio&&(i.audio=a);break;case 21:-1===i.id3&&(i.id3=a);break;case 219:if(!n){c.logger.log("H.264 with AES-128-CBC slice encryption found in unencrypted stream");break}case 27:-1===i.avc&&(i.avc=a);break;case 3:case 4:r?-1===i.audio&&(i.audio=a,i.isAAC=!1):c.logger.log("MPEG audio found, not supported in this browser");break;case 36:c.logger.warn("Unsupported HEVC stream type found")}e+=5+((15&t[e+3])<<8|t[e+4])}return i}function m(t){var e,r,n,i,o,a=0,s=t.data;if(!t||0===t.size)return null;for(;s[0].length<19&&s.length>1;){var A=new Uint8Array(s[0].length+s[1].length);A.set(s[0]),A.set(s[1],s[0].length),s[0]=A,s.splice(1,1)}if(1===((e=s[0])[0]<<16)+(e[1]<<8)+e[2]){if((r=(e[4]<<8)+e[5])&&r>t.size-6)return null;var l=e[7];192&l&&(i=536870912*(14&e[9])+4194304*(255&e[10])+16384*(254&e[11])+128*(255&e[12])+(254&e[13])/2,64&l?i-(o=536870912*(14&e[14])+4194304*(255&e[15])+16384*(254&e[16])+128*(255&e[17])+(254&e[18])/2)>54e5&&(c.logger.warn(Math.round((i-o)/9e4)+"s delta between PTS and DTS, align them"),i=o):o=i);var u=(n=e[8])+9;if(t.size<=u)return null;t.size-=u;for(var h=new Uint8Array(t.size),d=0,f=s.length;d<f;d++){var p=(e=s[d]).byteLength;if(u){if(u>p){u-=p;continue}e=e.subarray(u),p-=u,u=0}h.set(e,a),a+=p}return r&&(r-=n+3),{data:h,pts:i,dts:o,len:r}}return null}function v(t,e){if(t.units.length&&t.frame){if(void 0===t.pts){var r=e.samples,n=r.length;if(!n)return void e.dropped++;var i=r[n-1];t.pts=i.pts,t.dts=i.dts}e.samples.push(t)}t.debug.length&&c.logger.log(t.pts+"/"+t.dts+":"+t.debug)}function y(t,e){var r=t.length;if(r>0){if(e.pts>=t[r-1].pts)t.push(e);else for(var n=r-1;n>=0;n--)if(e.pts<t[n].pts){t.splice(n,0,e);break}}else t.push(e)}function w(t){for(var e=t.byteLength,r=[],n=1;n<e-2;)0===t[n]&&0===t[n+1]&&3===t[n+2]?(r.push(n+2),n+=2):n++;if(0===r.length)return t;var i=e-r.length,o=new Uint8Array(i),a=0;for(n=0;n<i;a++,n++)a===r[0]&&(a++,r.shift()),o[n]=t[a];return o}d.minProbeByteLength=188,e.default=d},"./src/errors.ts":
|
|
|
/*!***********************!*\
|
|
|
!*** ./src/errors.ts ***!
|
|
|
\***********************/
|
|
|
/*! exports provided: ErrorTypes, ErrorDetails */function(t,e,r){"use strict";var n,i;r.r(e),r.d(e,"ErrorTypes",(function(){return n})),r.d(e,"ErrorDetails",(function(){return i})),function(t){t.NETWORK_ERROR="networkError",t.MEDIA_ERROR="mediaError",t.KEY_SYSTEM_ERROR="keySystemError",t.MUX_ERROR="muxError",t.OTHER_ERROR="otherError"}(n||(n={})),function(t){t.KEY_SYSTEM_NO_KEYS="keySystemNoKeys",t.KEY_SYSTEM_NO_ACCESS="keySystemNoAccess",t.KEY_SYSTEM_NO_SESSION="keySystemNoSession",t.KEY_SYSTEM_LICENSE_REQUEST_FAILED="keySystemLicenseRequestFailed",t.KEY_SYSTEM_NO_INIT_DATA="keySystemNoInitData",t.MANIFEST_LOAD_ERROR="manifestLoadError",t.MANIFEST_LOAD_TIMEOUT="manifestLoadTimeOut",t.MANIFEST_PARSING_ERROR="manifestParsingError",t.MANIFEST_INCOMPATIBLE_CODECS_ERROR="manifestIncompatibleCodecsError",t.LEVEL_EMPTY_ERROR="levelEmptyError",t.LEVEL_LOAD_ERROR="levelLoadError",t.LEVEL_LOAD_TIMEOUT="levelLoadTimeOut",t.LEVEL_SWITCH_ERROR="levelSwitchError",t.AUDIO_TRACK_LOAD_ERROR="audioTrackLoadError",t.AUDIO_TRACK_LOAD_TIMEOUT="audioTrackLoadTimeOut",t.SUBTITLE_LOAD_ERROR="subtitleTrackLoadError",t.SUBTITLE_TRACK_LOAD_TIMEOUT="subtitleTrackLoadTimeOut",t.FRAG_LOAD_ERROR="fragLoadError",t.FRAG_LOAD_TIMEOUT="fragLoadTimeOut",t.FRAG_DECRYPT_ERROR="fragDecryptError",t.FRAG_PARSING_ERROR="fragParsingError",t.REMUX_ALLOC_ERROR="remuxAllocError",t.KEY_LOAD_ERROR="keyLoadError",t.KEY_LOAD_TIMEOUT="keyLoadTimeOut",t.BUFFER_ADD_CODEC_ERROR="bufferAddCodecError",t.BUFFER_INCOMPATIBLE_CODECS_ERROR="bufferIncompatibleCodecsError",t.BUFFER_APPEND_ERROR="bufferAppendError",t.BUFFER_APPENDING_ERROR="bufferAppendingError",t.BUFFER_STALLED_ERROR="bufferStalledError",t.BUFFER_FULL_ERROR="bufferFullError",t.BUFFER_SEEK_OVER_HOLE="bufferSeekOverHole",t.BUFFER_NUDGE_ON_STALL="bufferNudgeOnStall",t.INTERNAL_EXCEPTION="internalException",t.INTERNAL_ABORTED="aborted",t.UNKNOWN="unknown"}(i||(i={}))},"./src/events.ts":
|
|
|
/*!***********************!*\
|
|
|
!*** ./src/events.ts ***!
|
|
|
\***********************/
|
|
|
/*! exports provided: Events */function(t,e,r){"use strict";var n;r.r(e),r.d(e,"Events",(function(){return n})),function(t){t.MEDIA_ATTACHING="hlsMediaAttaching",t.MEDIA_ATTACHED="hlsMediaAttached",t.MEDIA_DETACHING="hlsMediaDetaching",t.MEDIA_DETACHED="hlsMediaDetached",t.BUFFER_RESET="hlsBufferReset",t.BUFFER_CODECS="hlsBufferCodecs",t.BUFFER_CREATED="hlsBufferCreated",t.BUFFER_APPENDING="hlsBufferAppending",t.BUFFER_APPENDED="hlsBufferAppended",t.BUFFER_EOS="hlsBufferEos",t.BUFFER_FLUSHING="hlsBufferFlushing",t.BUFFER_FLUSHED="hlsBufferFlushed",t.MANIFEST_LOADING="hlsManifestLoading",t.MANIFEST_LOADED="hlsManifestLoaded",t.MANIFEST_PARSED="hlsManifestParsed",t.LEVEL_SWITCHING="hlsLevelSwitching",t.LEVEL_SWITCHED="hlsLevelSwitched",t.LEVEL_LOADING="hlsLevelLoading",t.LEVEL_LOADED="hlsLevelLoaded",t.LEVEL_UPDATED="hlsLevelUpdated",t.LEVEL_PTS_UPDATED="hlsLevelPtsUpdated",t.LEVELS_UPDATED="hlsLevelsUpdated",t.AUDIO_TRACKS_UPDATED="hlsAudioTracksUpdated",t.AUDIO_TRACK_SWITCHING="hlsAudioTrackSwitching",t.AUDIO_TRACK_SWITCHED="hlsAudioTrackSwitched",t.AUDIO_TRACK_LOADING="hlsAudioTrackLoading",t.AUDIO_TRACK_LOADED="hlsAudioTrackLoaded",t.SUBTITLE_TRACKS_UPDATED="hlsSubtitleTracksUpdated",t.SUBTITLE_TRACKS_CLEARED="hlsSubtitleTracksCleared",t.SUBTITLE_TRACK_SWITCH="hlsSubtitleTrackSwitch",t.SUBTITLE_TRACK_LOADING="hlsSubtitleTrackLoading",t.SUBTITLE_TRACK_LOADED="hlsSubtitleTrackLoaded",t.SUBTITLE_FRAG_PROCESSED="hlsSubtitleFragProcessed",t.CUES_PARSED="hlsCuesParsed",t.NON_NATIVE_TEXT_TRACKS_FOUND="hlsNonNativeTextTracksFound",t.INIT_PTS_FOUND="hlsInitPtsFound",t.FRAG_LOADING="hlsFragLoading",t.FRAG_LOAD_EMERGENCY_ABORTED="hlsFragLoadEmergencyAborted",t.FRAG_LOADED="hlsFragLoaded",t.FRAG_DECRYPTED="hlsFragDecrypted",t.FRAG_PARSING_INIT_SEGMENT="hlsFragParsingInitSegment",t.FRAG_PARSING_USERDATA="hlsFragParsingUserdata",t.FRAG_PARSING_METADATA="hlsFragParsingMetadata",t.FRAG_PARSED="hlsFragParsed",t.FRAG_BUFFERED="hlsFragBuffered",t.FRAG_CHANGED="hlsFragChanged",t.FPS_DROP="hlsFpsDrop",t.FPS_DROP_LEVEL_CAPPING="hlsFpsDropLevelCapping",t.ERROR="hlsError",t.DESTROYING="hlsDestroying",t.KEY_LOADING="hlsKeyLoading",t.KEY_LOADED="hlsKeyLoaded",t.LIVE_BACK_BUFFER_REACHED="hlsLiveBackBufferReached",t.BACK_BUFFER_REACHED="hlsBackBufferReached"}(n||(n={}))},"./src/hls.ts":
|
|
|
/*!********************!*\
|
|
|
!*** ./src/hls.ts ***!
|
|
|
\********************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return v}));var n=r(/*! url-toolkit */"./node_modules/url-toolkit/src/url-toolkit.js"),i=r(/*! ./loader/playlist-loader */"./src/loader/playlist-loader.ts"),o=r(/*! ./loader/key-loader */"./src/loader/key-loader.ts"),a=r(/*! ./controller/id3-track-controller */"./src/controller/id3-track-controller.ts"),s=r(/*! ./controller/latency-controller */"./src/controller/latency-controller.ts"),A=r(/*! ./controller/level-controller */"./src/controller/level-controller.ts"),l=r(/*! ./controller/fragment-tracker */"./src/controller/fragment-tracker.ts"),c=r(/*! ./controller/stream-controller */"./src/controller/stream-controller.ts"),u=r(/*! ./is-supported */"./src/is-supported.ts"),h=r(/*! ./utils/logger */"./src/utils/logger.ts"),d=r(/*! ./config */"./src/config.ts"),f=r(/*! eventemitter3 */"./node_modules/eventemitter3/index.js"),p=r(/*! ./events */"./src/events.ts"),g=r(/*! ./errors */"./src/errors.ts");function m(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var v=function(){function t(e){void 0===e&&(e={}),this.config=void 0,this.userConfig=void 0,this.coreComponents=void 0,this.networkControllers=void 0,this._emitter=new f.EventEmitter,this._autoLevelCapping=void 0,this.abrController=void 0,this.bufferController=void 0,this.capLevelController=void 0,this.latencyController=void 0,this.levelController=void 0,this.streamController=void 0,this.audioTrackController=void 0,this.subtitleTrackController=void 0,this.emeController=void 0,this.cmcdController=void 0,this._media=null,this.url=null;var r=this.config=Object(d.mergeConfig)(t.DefaultConfig,e);this.userConfig=e,Object(h.enableLogs)(r.debug),this._autoLevelCapping=-1,r.progressive&&Object(d.enableStreamingMode)(r);var n=r.abrController,u=r.bufferController,p=r.capLevelController,g=r.fpsController,m=this.abrController=new n(this),v=this.bufferController=new u(this),y=this.capLevelController=new p(this),w=new g(this),b=new i.default(this),C=new o.default(this),B=new a.default(this),x=this.levelController=new A.default(this),E=new l.FragmentTracker(this),S=this.streamController=new c.default(this,E);y.setStreamController(S),w.setStreamController(S);var k=[x,S];this.networkControllers=k;var T=[b,C,m,v,y,w,B,E];this.audioTrackController=this.createController(r.audioTrackController,null,k),this.createController(r.audioStreamController,E,k),this.subtitleTrackController=this.createController(r.subtitleTrackController,null,k),this.createController(r.subtitleStreamController,E,k),this.createController(r.timelineController,null,T),this.emeController=this.createController(r.emeController,null,T),this.cmcdController=this.createController(r.cmcdController,null,T),this.latencyController=this.createController(s.default,null,T),this.coreComponents=T}t.isSupported=function(){return Object(u.isSupported)()};var e,r,v,y=t.prototype;return y.createController=function(t,e,r){if(t){var n=e?new t(this,e):new t(this);return r&&r.push(n),n}return null},y.on=function(t,e,r){void 0===r&&(r=this),this._emitter.on(t,e,r)},y.once=function(t,e,r){void 0===r&&(r=this),this._emitter.once(t,e,r)},y.removeAllListeners=function(t){this._emitter.removeAllListeners(t)},y.off=function(t,e,r,n){void 0===r&&(r=this),this._emitter.off(t,e,r,n)},y.listeners=function(t){return this._emitter.listeners(t)},y.emit=function(t,e,r){return this._emitter.emit(t,e,r)},y.trigger=function(t,e){if(this.config.debug)return this.emit(t,t,e);try{return this.emit(t,t,e)}catch(e){h.logger.error("An internal error happened while handling event "+t+'. Error message: "'+e.message+'". Here is a stacktrace:',e),this.trigger(p.Events.ERROR,{type:g.ErrorTypes.OTHER_ERROR,details:g.ErrorDetails.INTERNAL_EXCEPTION,fatal:!1,event:t,error:e})}return!1},y.listenerCount=function(t){return this._emitter.listenerCount(t)},y.destroy=function(){h.logger.log("destroy"),this.trigger(p.Events.DESTROYING,void 0),this.detachMedia(),this.removeAllListeners(),this._autoLevelCapping=-1,this.url=null,this.networkControllers.forEach((function(t){return t.destroy()})),this.networkControllers.length=0,this.coreComponents.forEach((function(t){return t.destroy()})),this.coreComponents.length=0},y.attachMedia=function(t){h.logger.log("attachMedia"),this._media=t,this.trigger(p.Events.MEDIA_ATTACHING,{media:t})},y.detachMedia=function(){h.logger.log("detachMedia"),this.trigger(p.Events.MEDIA_DETACHING,void 0),this._media=null},y.loadSource=function(t){this.stopLoad();var e=this.media,r=this.url,i=this.url=n.buildAbsoluteURL(self.location.href,t,{alwaysNormalize:!0});h.logger.log("loadSource:"+i),e&&r&&r!==i&&this.bufferController.hasSourceTypes()&&(this.detachMedia(),this.attachMedia(e)),this.trigger(p.Events.MANIFEST_LOADING,{url:t})},y.startLoad=function(t){void 0===t&&(t=-1),h.logger.log("startLoad("+t+")"),this.networkControllers.forEach((function(e){e.startLoad(t)}))},y.stopLoad=function(){h.logger.log("stopLoad"),this.networkControllers.forEach((function(t){t.stopLoad()}))},y.swapAudioCodec=function(){h.logger.log("swapAudioCodec"),this.streamController.swapAudioCodec()},y.recoverMediaError=function(){h.logger.log("recoverMediaError");var t=this._media;this.detachMedia(),t&&this.attachMedia(t)},y.removeLevel=function(t,e){void 0===e&&(e=0),this.levelController.removeLevel(t,e)},e=t,v=[{key:"version",get:function(){return"1.1.2"}},{key:"Events",get:function(){return p.Events}},{key:"ErrorTypes",get:function(){return g.ErrorTypes}},{key:"ErrorDetails",get:function(){return g.ErrorDetails}},{key:"DefaultConfig",get:function(){return t.defaultConfig?t.defaultConfig:d.hlsDefaultConfig},set:function(e){t.defaultConfig=e}}],(r=[{key:"levels",get:function(){var t=this.levelController.levels;return t||[]}},{key:"currentLevel",get:function(){return this.streamController.currentLevel},set:function(t){h.logger.log("set currentLevel:"+t),this.loadLevel=t,this.abrController.clearTimer(),this.streamController.immediateLevelSwitch()}},{key:"nextLevel",get:function(){return this.streamController.nextLevel},set:function(t){h.logger.log("set nextLevel:"+t),this.levelController.manualLevel=t,this.streamController.nextLevelSwitch()}},{key:"loadLevel",get:function(){return this.levelController.level},set:function(t){h.logger.log("set loadLevel:"+t),this.levelController.manualLevel=t}},{key:"nextLoadLevel",get:function(){return this.levelController.nextLoadLevel},set:function(t){this.levelController.nextLoadLevel=t}},{key:"firstLevel",get:function(){return Math.max(this.levelController.firstLevel,this.minAutoLevel)},set:function(t){h.logger.log("set firstLevel:"+t),this.levelController.firstLevel=t}},{key:"startLevel",get:function(){return this.levelController.startLevel},set:function(t){h.logger.log("set startLevel:"+t),-1!==t&&(t=Math.max(t,this.minAutoLevel)),this.levelController.startLevel=t}},{key:"capLevelToPlayerSize",get:function(){return this.config.capLevelToPlayerSize},set:function(t){var e=!!t;e!==this.config.capLevelToPlayerSize&&(e?this.capLevelController.startCapping():(this.capLevelController.stopCapping(),this.autoLevelCapping=-1,this.streamController.nextLevelSwitch()),this.config.capLevelToPlayerSize=e)}},{key:"autoLevelCapping",get:function(){return this._autoLevelCapping},set:function(t){this._autoLevelCapping!==t&&(h.logger.log("set autoLevelCapping:"+t),this._autoLevelCapping=t)}},{key:"bandwidthEstimate",get:function(){var t=this.abrController.bwEstimator;return t?t.getEstimate():NaN}},{key:"autoLevelEnabled",get:function(){return-1===this.levelController.manualLevel}},{key:"manualLevel",get:function(){return this.levelController.manualLevel}},{key:"minAutoLevel",get:function(){var t=this.levels,e=this.config.minAutoBitrate;if(!t)return 0;for(var r=t.length,n=0;n<r;n++)if(t[n].maxBitrate>e)return n;return 0}},{key:"maxAutoLevel",get:function(){var t=this.levels,e=this.autoLevelCapping;return-1===e&&t&&t.length?t.length-1:e}},{key:"nextAutoLevel",get:function(){return Math.min(Math.max(this.abrController.nextAutoLevel,this.minAutoLevel),this.maxAutoLevel)},set:function(t){this.abrController.nextAutoLevel=Math.max(this.minAutoLevel,t)}},{key:"audioTracks",get:function(){var t=this.audioTrackController;return t?t.audioTracks:[]}},{key:"audioTrack",get:function(){var t=this.audioTrackController;return t?t.audioTrack:-1},set:function(t){var e=this.audioTrackController;e&&(e.audioTrack=t)}},{key:"subtitleTracks",get:function(){var t=this.subtitleTrackController;return t?t.subtitleTracks:[]}},{key:"subtitleTrack",get:function(){var t=this.subtitleTrackController;return t?t.subtitleTrack:-1},set:function(t){var e=this.subtitleTrackController;e&&(e.subtitleTrack=t)}},{key:"media",get:function(){return this._media}},{key:"subtitleDisplay",get:function(){var t=this.subtitleTrackController;return!!t&&t.subtitleDisplay},set:function(t){var e=this.subtitleTrackController;e&&(e.subtitleDisplay=t)}},{key:"lowLatencyMode",get:function(){return this.config.lowLatencyMode},set:function(t){this.config.lowLatencyMode=t}},{key:"liveSyncPosition",get:function(){return this.latencyController.liveSyncPosition}},{key:"latency",get:function(){return this.latencyController.latency}},{key:"maxLatency",get:function(){return this.latencyController.maxLatency}},{key:"targetLatency",get:function(){return this.latencyController.targetLatency}},{key:"drift",get:function(){return this.latencyController.drift}},{key:"forceStartLoad",get:function(){return this.streamController.forceStartLoad}}])&&m(e.prototype,r),v&&m(e,v),t}();v.defaultConfig=void 0},"./src/is-supported.ts":
|
|
|
/*!*****************************!*\
|
|
|
!*** ./src/is-supported.ts ***!
|
|
|
\*****************************/
|
|
|
/*! exports provided: isSupported, changeTypeSupported */function(t,e,r){"use strict";r.r(e),r.d(e,"isSupported",(function(){return o})),r.d(e,"changeTypeSupported",(function(){return a}));var n=r(/*! ./utils/mediasource-helper */"./src/utils/mediasource-helper.ts");function i(){return self.SourceBuffer||self.WebKitSourceBuffer}function o(){var t=Object(n.getMediaSource)();if(!t)return!1;var e=i(),r=t&&"function"==typeof t.isTypeSupported&&t.isTypeSupported('video/mp4; codecs="avc1.42E01E,mp4a.40.2"'),o=!e||e.prototype&&"function"==typeof e.prototype.appendBuffer&&"function"==typeof e.prototype.remove;return!!r&&!!o}function a(){var t,e=i();return"function"==typeof(null==e||null===(t=e.prototype)||void 0===t?void 0:t.changeType)}},"./src/loader/fragment-loader.ts":
|
|
|
/*!***************************************!*\
|
|
|
!*** ./src/loader/fragment-loader.ts ***!
|
|
|
\***************************************/
|
|
|
/*! exports provided: default, LoadError */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return u})),r.d(e,"LoadError",(function(){return d}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../errors */"./src/errors.ts");function o(t){var e="function"==typeof Map?new Map:void 0;return(o=function(t){if(null===t||(r=t,-1===Function.toString.call(r).indexOf("[native code]")))return t;var r;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==e){if(e.has(t))return e.get(t);e.set(t,n)}function n(){return a(t,arguments,l(this).constructor)}return n.prototype=Object.create(t.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),A(n,t)})(t)}function a(t,e,r){return(a=s()?Reflect.construct:function(t,e,r){var n=[null];n.push.apply(n,e);var i=new(Function.bind.apply(t,n));return r&&A(i,r.prototype),i}).apply(null,arguments)}function s(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function A(t,e){return(A=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function l(t){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var c=Math.pow(2,17),u=function(){function t(t){this.config=void 0,this.loader=null,this.partLoadTimeout=-1,this.config=t}var e=t.prototype;return e.destroy=function(){this.loader&&(this.loader.destroy(),this.loader=null)},e.abort=function(){this.loader&&this.loader.abort()},e.load=function(t,e){var r=this,n=t.url;if(!n)return Promise.reject(new d({type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.FRAG_LOAD_ERROR,fatal:!1,frag:t,networkDetails:null},"Fragment does not have a "+(n?"part list":"url")));this.abort();var o=this.config,a=o.fLoader,s=o.loader;return new Promise((function(n,A){r.loader&&r.loader.destroy();var l=r.loader=t.loader=a?new a(o):new s(o),u=h(t),f={timeout:o.fragLoadingTimeOut,maxRetry:0,retryDelay:0,maxRetryDelay:o.fragLoadingMaxRetryTimeout,highWaterMark:c};t.stats=l.stats,l.load(u,f,{onSuccess:function(e,i,o,a){r.resetLoader(t,l),n({frag:t,part:null,payload:e.data,networkDetails:a})},onError:function(e,n,o){r.resetLoader(t,l),A(new d({type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.FRAG_LOAD_ERROR,fatal:!1,frag:t,response:e,networkDetails:o}))},onAbort:function(e,n,o){r.resetLoader(t,l),A(new d({type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.INTERNAL_ABORTED,fatal:!1,frag:t,networkDetails:o}))},onTimeout:function(e,n,o){r.resetLoader(t,l),A(new d({type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.FRAG_LOAD_TIMEOUT,fatal:!1,frag:t,networkDetails:o}))},onProgress:function(r,n,i,o){e&&e({frag:t,part:null,payload:i,networkDetails:o})}})}))},e.loadPart=function(t,e,r){var n=this;this.abort();var o=this.config,a=o.fLoader,s=o.loader;return new Promise((function(A,l){n.loader&&n.loader.destroy();var u=n.loader=t.loader=a?new a(o):new s(o),f=h(t,e),p={timeout:o.fragLoadingTimeOut,maxRetry:0,retryDelay:0,maxRetryDelay:o.fragLoadingMaxRetryTimeout,highWaterMark:c};e.stats=u.stats,u.load(f,p,{onSuccess:function(i,o,a,s){n.resetLoader(t,u),n.updateStatsFromPart(t,e);var l={frag:t,part:e,payload:i.data,networkDetails:s};r(l),A(l)},onError:function(r,o,a){n.resetLoader(t,u),l(new d({type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.FRAG_LOAD_ERROR,fatal:!1,frag:t,part:e,response:r,networkDetails:a}))},onAbort:function(r,o,a){t.stats.aborted=e.stats.aborted,n.resetLoader(t,u),l(new d({type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.INTERNAL_ABORTED,fatal:!1,frag:t,part:e,networkDetails:a}))},onTimeout:function(r,o,a){n.resetLoader(t,u),l(new d({type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.FRAG_LOAD_TIMEOUT,fatal:!1,frag:t,part:e,networkDetails:a}))}})}))},e.updateStatsFromPart=function(t,e){var r=t.stats,n=e.stats,i=n.total;if(r.loaded+=n.loaded,i){var o=Math.round(t.duration/e.duration),a=Math.min(Math.round(r.loaded/i),o),s=(o-a)*Math.round(r.loaded/a);r.total=r.loaded+s}else r.total=Math.max(r.loaded,r.total);var A=r.loading,l=n.loading;A.start?A.first+=l.first-l.start:(A.start=l.start,A.first=l.first),A.end=l.end},e.resetLoader=function(t,e){t.loader=null,this.loader===e&&(self.clearTimeout(this.partLoadTimeout),this.loader=null),e.destroy()},t}();function h(t,e){void 0===e&&(e=null);var r=e||t,i={frag:t,part:e,responseType:"arraybuffer",url:r.url,headers:{},rangeStart:0,rangeEnd:0},o=r.byteRangeStartOffset,a=r.byteRangeEndOffset;return Object(n.isFiniteNumber)(o)&&Object(n.isFiniteNumber)(a)&&(i.rangeStart=o,i.rangeEnd=a),i}var d=function(t){var e,r;function n(e){for(var r,n=arguments.length,i=new Array(n>1?n-1:0),o=1;o<n;o++)i[o-1]=arguments[o];return(r=t.call.apply(t,[this].concat(i))||this).data=void 0,r.data=e,r}return r=t,(e=n).prototype=Object.create(r.prototype),e.prototype.constructor=e,A(e,r),n}(o(Error))},"./src/loader/fragment.ts":
|
|
|
/*!********************************!*\
|
|
|
!*** ./src/loader/fragment.ts ***!
|
|
|
\********************************/
|
|
|
/*! exports provided: ElementaryStreamTypes, BaseSegment, Fragment, Part */function(t,e,r){"use strict";r.r(e),r.d(e,"ElementaryStreamTypes",(function(){return n})),r.d(e,"BaseSegment",(function(){return d})),r.d(e,"Fragment",(function(){return f})),r.d(e,"Part",(function(){return p}));var n,i=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),o=r(/*! url-toolkit */"./node_modules/url-toolkit/src/url-toolkit.js"),a=r(/*! ../utils/logger */"./src/utils/logger.ts"),s=r(/*! ./level-key */"./src/loader/level-key.ts"),A=r(/*! ./load-stats */"./src/loader/load-stats.ts");function l(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,c(t,e)}function c(t,e){return(c=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function u(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function h(t,e,r){return e&&u(t.prototype,e),r&&u(t,r),t}!function(t){t.AUDIO="audio",t.VIDEO="video",t.AUDIOVIDEO="audiovideo"}(n||(n={}));var d=function(){function t(t){var e;this._byteRange=null,this._url=null,this.baseurl=void 0,this.relurl=void 0,this.elementaryStreams=((e={})[n.AUDIO]=null,e[n.VIDEO]=null,e[n.AUDIOVIDEO]=null,e),this.baseurl=t}return t.prototype.setByteRange=function(t,e){var r=t.split("@",2),n=[];1===r.length?n[0]=e?e.byteRangeEndOffset:0:n[0]=parseInt(r[1]),n[1]=parseInt(r[0])+n[0],this._byteRange=n},h(t,[{key:"byteRange",get:function(){return this._byteRange?this._byteRange:[]}},{key:"byteRangeStartOffset",get:function(){return this.byteRange[0]}},{key:"byteRangeEndOffset",get:function(){return this.byteRange[1]}},{key:"url",get:function(){return!this._url&&this.baseurl&&this.relurl&&(this._url=Object(o.buildAbsoluteURL)(this.baseurl,this.relurl,{alwaysNormalize:!0})),this._url||""},set:function(t){this._url=t}}]),t}(),f=function(t){function e(e,r){var n;return(n=t.call(this,r)||this)._decryptdata=null,n.rawProgramDateTime=null,n.programDateTime=null,n.tagList=[],n.duration=0,n.sn=0,n.levelkey=void 0,n.type=void 0,n.loader=null,n.level=-1,n.cc=0,n.startPTS=void 0,n.endPTS=void 0,n.appendedPTS=void 0,n.startDTS=void 0,n.endDTS=void 0,n.start=0,n.deltaPTS=void 0,n.maxStartPTS=void 0,n.minEndPTS=void 0,n.stats=new A.LoadStats,n.urlId=0,n.data=void 0,n.bitrateTest=!1,n.title=null,n.initSegment=null,n.type=e,n}l(e,t);var r=e.prototype;return r.createInitializationVector=function(t){for(var e=new Uint8Array(16),r=12;r<16;r++)e[r]=t>>8*(15-r)&255;return e},r.setDecryptDataFromLevelKey=function(t,e){var r=t;return"AES-128"===(null==t?void 0:t.method)&&t.uri&&!t.iv&&((r=s.LevelKey.fromURI(t.uri)).method=t.method,r.iv=this.createInitializationVector(e),r.keyFormat="identity"),r},r.setElementaryStreamInfo=function(t,e,r,n,i,o){void 0===o&&(o=!1);var a=this.elementaryStreams,s=a[t];s?(s.startPTS=Math.min(s.startPTS,e),s.endPTS=Math.max(s.endPTS,r),s.startDTS=Math.min(s.startDTS,n),s.endDTS=Math.max(s.endDTS,i)):a[t]={startPTS:e,endPTS:r,startDTS:n,endDTS:i,partial:o}},r.clearElementaryStreamInfo=function(){var t=this.elementaryStreams;t[n.AUDIO]=null,t[n.VIDEO]=null,t[n.AUDIOVIDEO]=null},h(e,[{key:"decryptdata",get:function(){if(!this.levelkey&&!this._decryptdata)return null;if(!this._decryptdata&&this.levelkey){var t=this.sn;"number"!=typeof t&&(this.levelkey&&"AES-128"===this.levelkey.method&&!this.levelkey.iv&&a.logger.warn('missing IV for initialization segment with method="'+this.levelkey.method+'" - compliance issue'),t=0),this._decryptdata=this.setDecryptDataFromLevelKey(this.levelkey,t)}return this._decryptdata}},{key:"end",get:function(){return this.start+this.duration}},{key:"endProgramDateTime",get:function(){if(null===this.programDateTime)return null;if(!Object(i.isFiniteNumber)(this.programDateTime))return null;var t=Object(i.isFiniteNumber)(this.duration)?this.duration:0;return this.programDateTime+1e3*t}},{key:"encrypted",get:function(){var t;return!(null===(t=this.decryptdata)||void 0===t||!t.keyFormat||!this.decryptdata.uri)}}]),e}(d),p=function(t){function e(e,r,n,i,o){var a;(a=t.call(this,n)||this).fragOffset=0,a.duration=0,a.gap=!1,a.independent=!1,a.relurl=void 0,a.fragment=void 0,a.index=void 0,a.stats=new A.LoadStats,a.duration=e.decimalFloatingPoint("DURATION"),a.gap=e.bool("GAP"),a.independent=e.bool("INDEPENDENT"),a.relurl=e.enumeratedString("URI"),a.fragment=r,a.index=i;var s=e.enumeratedString("BYTERANGE");return s&&a.setByteRange(s,o),o&&(a.fragOffset=o.fragOffset+o.duration),a}return l(e,t),h(e,[{key:"start",get:function(){return this.fragment.start+this.fragOffset}},{key:"end",get:function(){return this.start+this.duration}},{key:"loaded",get:function(){var t=this.elementaryStreams;return!!(t.audio||t.video||t.audiovideo)}}]),e}(d)},"./src/loader/key-loader.ts":
|
|
|
/*!**********************************!*\
|
|
|
!*** ./src/loader/key-loader.ts ***!
|
|
|
\**********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return a}));var n=r(/*! ../events */"./src/events.ts"),i=r(/*! ../errors */"./src/errors.ts"),o=r(/*! ../utils/logger */"./src/utils/logger.ts"),a=function(){function t(t){this.hls=void 0,this.loaders={},this.decryptkey=null,this.decrypturl=null,this.hls=t,this._registerListeners()}var e=t.prototype;return e._registerListeners=function(){this.hls.on(n.Events.KEY_LOADING,this.onKeyLoading,this)},e._unregisterListeners=function(){this.hls.off(n.Events.KEY_LOADING,this.onKeyLoading)},e.destroy=function(){for(var t in this._unregisterListeners(),this.loaders){var e=this.loaders[t];e&&e.destroy()}this.loaders={}},e.onKeyLoading=function(t,e){var r=e.frag,i=r.type,a=this.loaders[i];if(r.decryptdata){var s=r.decryptdata.uri;if(s!==this.decrypturl||null===this.decryptkey){var A=this.hls.config;if(a&&(o.logger.warn("abort previous key loader for type:"+i),a.abort()),!s)return void o.logger.warn("key uri is falsy");var l=A.loader,c=r.loader=this.loaders[i]=new l(A);this.decrypturl=s,this.decryptkey=null;var u={url:s,frag:r,responseType:"arraybuffer"},h={timeout:A.fragLoadingTimeOut,maxRetry:0,retryDelay:A.fragLoadingRetryDelay,maxRetryDelay:A.fragLoadingMaxRetryTimeout,highWaterMark:0},d={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this)};c.load(u,h,d)}else this.decryptkey&&(r.decryptdata.key=this.decryptkey,this.hls.trigger(n.Events.KEY_LOADED,{frag:r}))}else o.logger.warn("Missing decryption data on fragment in onKeyLoading")},e.loadsuccess=function(t,e,r){var i=r.frag;i.decryptdata?(this.decryptkey=i.decryptdata.key=new Uint8Array(t.data),i.loader=null,delete this.loaders[i.type],this.hls.trigger(n.Events.KEY_LOADED,{frag:i})):o.logger.error("after key load, decryptdata unset")},e.loaderror=function(t,e){var r=e.frag,o=r.loader;o&&o.abort(),delete this.loaders[r.type],this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.KEY_LOAD_ERROR,fatal:!1,frag:r,response:t})},e.loadtimeout=function(t,e){var r=e.frag,o=r.loader;o&&o.abort(),delete this.loaders[r.type],this.hls.trigger(n.Events.ERROR,{type:i.ErrorTypes.NETWORK_ERROR,details:i.ErrorDetails.KEY_LOAD_TIMEOUT,fatal:!1,frag:r})},t}()},"./src/loader/level-details.ts":
|
|
|
/*!*************************************!*\
|
|
|
!*** ./src/loader/level-details.ts ***!
|
|
|
\*************************************/
|
|
|
/*! exports provided: LevelDetails */function(t,e,r){"use strict";r.r(e),r.d(e,"LevelDetails",(function(){return o}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts");function i(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var o=function(){function t(t){this.PTSKnown=!1,this.alignedSliding=!1,this.averagetargetduration=void 0,this.endCC=0,this.endSN=0,this.fragments=void 0,this.fragmentHint=void 0,this.partList=null,this.live=!0,this.ageHeader=0,this.advancedDateTime=void 0,this.updated=!0,this.advanced=!0,this.availabilityDelay=void 0,this.misses=0,this.needSidxRanges=!1,this.startCC=0,this.startSN=0,this.startTimeOffset=null,this.targetduration=0,this.totalduration=0,this.type=null,this.url=void 0,this.m3u8="",this.version=null,this.canBlockReload=!1,this.canSkipUntil=0,this.canSkipDateRanges=!1,this.skippedSegments=0,this.recentlyRemovedDateranges=void 0,this.partHoldBack=0,this.holdBack=0,this.partTarget=0,this.preloadHint=void 0,this.renditionReports=void 0,this.tuneInGoal=0,this.deltaUpdateFailed=void 0,this.driftStartTime=0,this.driftEndTime=0,this.driftStart=0,this.driftEnd=0,this.fragments=[],this.url=t}var e,r,o;return t.prototype.reloaded=function(t){if(!t)return this.advanced=!0,void(this.updated=!0);var e=this.lastPartSn-t.lastPartSn,r=this.lastPartIndex-t.lastPartIndex;this.updated=this.endSN!==t.endSN||!!r||!!e,this.advanced=this.endSN>t.endSN||e>0||0===e&&r>0,this.updated||this.advanced?this.misses=Math.floor(.6*t.misses):this.misses=t.misses+1,this.availabilityDelay=t.availabilityDelay},e=t,(r=[{key:"hasProgramDateTime",get:function(){return!!this.fragments.length&&Object(n.isFiniteNumber)(this.fragments[this.fragments.length-1].programDateTime)}},{key:"levelTargetDuration",get:function(){return this.averagetargetduration||this.targetduration||10}},{key:"drift",get:function(){var t=this.driftEndTime-this.driftStartTime;return t>0?1e3*(this.driftEnd-this.driftStart)/t:1}},{key:"edge",get:function(){return this.partEnd||this.fragmentEnd}},{key:"partEnd",get:function(){var t;return null!==(t=this.partList)&&void 0!==t&&t.length?this.partList[this.partList.length-1].end:this.fragmentEnd}},{key:"fragmentEnd",get:function(){var t;return null!==(t=this.fragments)&&void 0!==t&&t.length?this.fragments[this.fragments.length-1].end:0}},{key:"age",get:function(){return this.advancedDateTime?Math.max(Date.now()-this.advancedDateTime,0)/1e3:0}},{key:"lastPartIndex",get:function(){var t;return null!==(t=this.partList)&&void 0!==t&&t.length?this.partList[this.partList.length-1].index:-1}},{key:"lastPartSn",get:function(){var t;return null!==(t=this.partList)&&void 0!==t&&t.length?this.partList[this.partList.length-1].fragment.sn:this.endSN}}])&&i(e.prototype,r),o&&i(e,o),t}()},"./src/loader/level-key.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/loader/level-key.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: LevelKey */function(t,e,r){"use strict";r.r(e),r.d(e,"LevelKey",(function(){return o}));var n=r(/*! url-toolkit */"./node_modules/url-toolkit/src/url-toolkit.js");function i(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var o=function(){function t(t,e){this._uri=null,this.method=null,this.keyFormat=null,this.keyFormatVersions=null,this.keyID=null,this.key=null,this.iv=null,this._uri=e?Object(n.buildAbsoluteURL)(t,e,{alwaysNormalize:!0}):t}var e,r,o;return t.fromURL=function(e,r){return new t(e,r)},t.fromURI=function(e){return new t(e)},e=t,(r=[{key:"uri",get:function(){return this._uri}}])&&i(e.prototype,r),o&&i(e,o),t}()},"./src/loader/load-stats.ts":
|
|
|
/*!**********************************!*\
|
|
|
!*** ./src/loader/load-stats.ts ***!
|
|
|
\**********************************/
|
|
|
/*! exports provided: LoadStats */function(t,e,r){"use strict";r.r(e),r.d(e,"LoadStats",(function(){return n}));var n=function(){this.aborted=!1,this.loaded=0,this.retry=0,this.total=0,this.chunkCount=0,this.bwEstimate=0,this.loading={start:0,first:0,end:0},this.parsing={start:0,end:0},this.buffering={start:0,first:0,end:0}}},"./src/loader/m3u8-parser.ts":
|
|
|
/*!***********************************!*\
|
|
|
!*** ./src/loader/m3u8-parser.ts ***!
|
|
|
\***********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return g}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! url-toolkit */"./node_modules/url-toolkit/src/url-toolkit.js"),o=r(/*! ./fragment */"./src/loader/fragment.ts"),a=r(/*! ./level-details */"./src/loader/level-details.ts"),s=r(/*! ./level-key */"./src/loader/level-key.ts"),A=r(/*! ../utils/attr-list */"./src/utils/attr-list.ts"),l=r(/*! ../utils/logger */"./src/utils/logger.ts"),c=r(/*! ../utils/codecs */"./src/utils/codecs.ts"),u=/#EXT-X-STREAM-INF:([^\r\n]*)(?:[\r\n](?:#[^\r\n]*)?)*([^\r\n]+)|#EXT-X-SESSION-DATA:([^\r\n]*)[\r\n]+/g,h=/#EXT-X-MEDIA:(.*)/g,d=new RegExp([/#EXTINF:\s*(\d*(?:\.\d+)?)(?:,(.*)\s+)?/.source,/(?!#) *(\S[\S ]*)/.source,/#EXT-X-BYTERANGE:*(.+)/.source,/#EXT-X-PROGRAM-DATE-TIME:(.+)/.source,/#.*/.source].join("|"),"g"),f=new RegExp([/#(EXTM3U)/.source,/#EXT-X-(PLAYLIST-TYPE):(.+)/.source,/#EXT-X-(MEDIA-SEQUENCE): *(\d+)/.source,/#EXT-X-(SKIP):(.+)/.source,/#EXT-X-(TARGETDURATION): *(\d+)/.source,/#EXT-X-(KEY):(.+)/.source,/#EXT-X-(START):(.+)/.source,/#EXT-X-(ENDLIST)/.source,/#EXT-X-(DISCONTINUITY-SEQ)UENCE: *(\d+)/.source,/#EXT-X-(DIS)CONTINUITY/.source,/#EXT-X-(VERSION):(\d+)/.source,/#EXT-X-(MAP):(.+)/.source,/#EXT-X-(SERVER-CONTROL):(.+)/.source,/#EXT-X-(PART-INF):(.+)/.source,/#EXT-X-(GAP)/.source,/#EXT-X-(BITRATE):\s*(\d+)/.source,/#EXT-X-(PART):(.+)/.source,/#EXT-X-(PRELOAD-HINT):(.+)/.source,/#EXT-X-(RENDITION-REPORT):(.+)/.source,/(#)([^:]*):(.*)/.source,/(#)(.*)(?:.*)\r?\n?/.source].join("|")),p=/\.(mp4|m4s|m4v|m4a)$/i,g=function(){function t(){}return t.findGroup=function(t,e){for(var r=0;r<t.length;r++){var n=t[r];if(n.id===e)return n}},t.convertAVC1ToAVCOTI=function(t){var e=t.split(".");if(e.length>2){var r=e.shift()+".";return r+=parseInt(e.shift()).toString(16),r+=("000"+parseInt(e.shift()).toString(16)).substr(-4)}return t},t.resolve=function(t,e){return i.buildAbsoluteURL(e,t,{alwaysNormalize:!0})},t.parseMasterPlaylist=function(e,r){var n,i=[],o={},a=!1;for(u.lastIndex=0;null!=(n=u.exec(e));)if(n[1]){var s=new A.AttrList(n[1]),l={attrs:s,bitrate:s.decimalInteger("AVERAGE-BANDWIDTH")||s.decimalInteger("BANDWIDTH"),name:s.NAME,url:t.resolve(n[2],r)},c=s.decimalResolution("RESOLUTION");c&&(l.width=c.width,l.height=c.height),m((s.CODECS||"").split(/[ ,]+/).filter((function(t){return t})),l),l.videoCodec&&-1!==l.videoCodec.indexOf("avc1")&&(l.videoCodec=t.convertAVC1ToAVCOTI(l.videoCodec)),i.push(l)}else if(n[3]){var h=new A.AttrList(n[3]);h["DATA-ID"]&&(a=!0,o[h["DATA-ID"]]=h)}return{levels:i,sessionData:a?o:null}},t.parseMasterPlaylistMedia=function(e,r,n,i){var o;void 0===i&&(i=[]);var a=[],s=0;for(h.lastIndex=0;null!==(o=h.exec(e));){var l=new A.AttrList(o[1]);if(l.TYPE===n){var c={attrs:l,bitrate:0,id:s++,groupId:l["GROUP-ID"],instreamId:l["INSTREAM-ID"],name:l.NAME||l.LANGUAGE||"",type:n,default:l.bool("DEFAULT"),autoselect:l.bool("AUTOSELECT"),forced:l.bool("FORCED"),lang:l.LANGUAGE,url:l.URI?t.resolve(l.URI,r):""};if(i.length){var u=t.findGroup(i,c.groupId)||i[0];v(c,u,"audioCodec"),v(c,u,"textCodec")}a.push(c)}}return a},t.parseLevelPlaylist=function(t,e,r,c,u){var h,g,m,v=new a.LevelDetails(e),w=v.fragments,b=null,C=0,B=0,x=0,E=0,S=null,k=new o.Fragment(c,e),T=-1,F=!1;for(d.lastIndex=0,v.m3u8=t;null!==(h=d.exec(t));){F&&(F=!1,(k=new o.Fragment(c,e)).start=x,k.sn=C,k.cc=E,k.level=r,b&&(k.initSegment=b,k.rawProgramDateTime=b.rawProgramDateTime));var L=h[1];if(L){k.duration=parseFloat(L);var I=(" "+h[2]).slice(1);k.title=I||null,k.tagList.push(I?["INF",L,I]:["INF",L])}else if(h[3])Object(n.isFiniteNumber)(k.duration)&&(k.start=x,m&&(k.levelkey=m),k.sn=C,k.level=r,k.cc=E,k.urlId=u,w.push(k),k.relurl=(" "+h[3]).slice(1),y(k,S),S=k,x+=k.duration,C++,B=0,F=!0);else if(h[4]){var _=(" "+h[4]).slice(1);S?k.setByteRange(_,S):k.setByteRange(_)}else if(h[5])k.rawProgramDateTime=(" "+h[5]).slice(1),k.tagList.push(["PROGRAM-DATE-TIME",k.rawProgramDateTime]),-1===T&&(T=w.length);else{if(!(h=h[0].match(f))){l.logger.warn("No matches on slow regex match for level playlist!");continue}for(g=1;g<h.length&&void 0===h[g];g++);var U=(" "+h[g]).slice(1),O=(" "+h[g+1]).slice(1),D=h[g+2]?(" "+h[g+2]).slice(1):"";switch(U){case"PLAYLIST-TYPE":v.type=O.toUpperCase();break;case"MEDIA-SEQUENCE":C=v.startSN=parseInt(O);break;case"SKIP":var Q=new A.AttrList(O),M=Q.decimalInteger("SKIPPED-SEGMENTS");if(Object(n.isFiniteNumber)(M)){v.skippedSegments=M;for(var R=M;R--;)w.unshift(null);C+=M}var P=Q.enumeratedString("RECENTLY-REMOVED-DATERANGES");P&&(v.recentlyRemovedDateranges=P.split("\t"));break;case"TARGETDURATION":v.targetduration=parseFloat(O);break;case"VERSION":v.version=parseInt(O);break;case"EXTM3U":break;case"ENDLIST":v.live=!1;break;case"#":(O||D)&&k.tagList.push(D?[O,D]:[O]);break;case"DIS":E++;case"GAP":k.tagList.push([U]);break;case"BITRATE":k.tagList.push([U,O]);break;case"DISCONTINUITY-SEQ":E=parseInt(O);break;case"KEY":var H,N=new A.AttrList(O),K=N.enumeratedString("METHOD"),j=N.URI,G=N.hexadecimalInteger("IV"),V=N.enumeratedString("KEYFORMATVERSIONS"),z=N.enumeratedString("KEYID"),W=null!=(H=N.enumeratedString("KEYFORMAT"))?H:"identity";if(["com.apple.streamingkeydelivery","com.microsoft.playready","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed","com.widevine"].indexOf(W)>-1){l.logger.warn("Keyformat "+W+" is not supported from the manifest");continue}if("identity"!==W)continue;K&&(m=s.LevelKey.fromURL(e,j),j&&["AES-128","SAMPLE-AES","SAMPLE-AES-CENC"].indexOf(K)>=0&&(m.method=K,m.keyFormat=W,z&&(m.keyID=z),V&&(m.keyFormatVersions=V),m.iv=G));break;case"START":var Y=new A.AttrList(O).decimalFloatingPoint("TIME-OFFSET");Object(n.isFiniteNumber)(Y)&&(v.startTimeOffset=Y);break;case"MAP":var X=new A.AttrList(O);k.relurl=X.URI,X.BYTERANGE&&k.setByteRange(X.BYTERANGE),k.level=r,k.sn="initSegment",m&&(k.levelkey=m),k.initSegment=null,b=k,F=!0;break;case"SERVER-CONTROL":var q=new A.AttrList(O);v.canBlockReload=q.bool("CAN-BLOCK-RELOAD"),v.canSkipUntil=q.optionalFloat("CAN-SKIP-UNTIL",0),v.canSkipDateRanges=v.canSkipUntil>0&&q.bool("CAN-SKIP-DATERANGES"),v.partHoldBack=q.optionalFloat("PART-HOLD-BACK",0),v.holdBack=q.optionalFloat("HOLD-BACK",0);break;case"PART-INF":var J=new A.AttrList(O);v.partTarget=J.decimalFloatingPoint("PART-TARGET");break;case"PART":var Z=v.partList;Z||(Z=v.partList=[]);var $=B>0?Z[Z.length-1]:void 0,tt=B++,et=new o.Part(new A.AttrList(O),k,e,tt,$);Z.push(et),k.duration+=et.duration;break;case"PRELOAD-HINT":var rt=new A.AttrList(O);v.preloadHint=rt;break;case"RENDITION-REPORT":var nt=new A.AttrList(O);v.renditionReports=v.renditionReports||[],v.renditionReports.push(nt);break;default:l.logger.warn("line parsed but not handled: "+h)}}}S&&!S.relurl?(w.pop(),x-=S.duration,v.partList&&(v.fragmentHint=S)):v.partList&&(y(k,S),k.cc=E,v.fragmentHint=k);var it=w.length,ot=w[0],at=w[it-1];if((x+=v.skippedSegments*v.targetduration)>0&&it&&at){v.averagetargetduration=x/it;var st=at.sn;v.endSN="initSegment"!==st?st:0,ot&&(v.startCC=ot.cc,ot.initSegment||v.fragments.every((function(t){return t.relurl&&(e=t.relurl,p.test(null!=(r=null===(n=i.parseURL(e))||void 0===n?void 0:n.path)?r:""));var e,r,n}))&&(l.logger.warn("MP4 fragments found but no init segment (probably no MAP, incomplete M3U8), trying to fetch SIDX"),(k=new o.Fragment(c,e)).relurl=at.relurl,k.level=r,k.sn="initSegment",ot.initSegment=k,v.needSidxRanges=!0))}else v.endSN=0,v.startCC=0;return v.fragmentHint&&(x+=v.fragmentHint.duration),v.totalduration=x,v.endCC=E,T>0&&function(t,e){for(var r=t[e],n=e;n--;){var i=t[n];if(!i)return;i.programDateTime=r.programDateTime-1e3*i.duration,r=i}}(w,T),v},t}();function m(t,e){["video","audio","text"].forEach((function(r){var n=t.filter((function(t){return Object(c.isCodecType)(t,r)}));if(n.length){var i=n.filter((function(t){return 0===t.lastIndexOf("avc1",0)||0===t.lastIndexOf("mp4a",0)}));e[r+"Codec"]=i.length>0?i[0]:n[0],t=t.filter((function(t){return-1===n.indexOf(t)}))}})),e.unknownCodecs=t}function v(t,e,r){var n=e[r];n&&(t[r]=n)}function y(t,e){t.rawProgramDateTime?t.programDateTime=Date.parse(t.rawProgramDateTime):null!=e&&e.programDateTime&&(t.programDateTime=e.endProgramDateTime),Object(n.isFiniteNumber)(t.programDateTime)||(t.programDateTime=null,t.rawProgramDateTime=null)}},"./src/loader/playlist-loader.ts":
|
|
|
/*!***************************************!*\
|
|
|
!*** ./src/loader/playlist-loader.ts ***!
|
|
|
\***************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../events */"./src/events.ts"),o=r(/*! ../errors */"./src/errors.ts"),a=r(/*! ../utils/logger */"./src/utils/logger.ts"),s=r(/*! ../utils/mp4-tools */"./src/utils/mp4-tools.ts"),A=r(/*! ./m3u8-parser */"./src/loader/m3u8-parser.ts"),l=r(/*! ../types/loader */"./src/types/loader.ts"),c=r(/*! ../utils/attr-list */"./src/utils/attr-list.ts");function u(t,e){var r=t.url;return void 0!==r&&0!==r.indexOf("data:")||(r=e.url),r}var h=function(){function t(t){this.hls=void 0,this.loaders=Object.create(null),this.hls=t,this.registerListeners()}var e=t.prototype;return e.registerListeners=function(){var t=this.hls;t.on(i.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.on(i.Events.LEVEL_LOADING,this.onLevelLoading,this),t.on(i.Events.AUDIO_TRACK_LOADING,this.onAudioTrackLoading,this),t.on(i.Events.SUBTITLE_TRACK_LOADING,this.onSubtitleTrackLoading,this)},e.unregisterListeners=function(){var t=this.hls;t.off(i.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.off(i.Events.LEVEL_LOADING,this.onLevelLoading,this),t.off(i.Events.AUDIO_TRACK_LOADING,this.onAudioTrackLoading,this),t.off(i.Events.SUBTITLE_TRACK_LOADING,this.onSubtitleTrackLoading,this)},e.createInternalLoader=function(t){var e=this.hls.config,r=e.pLoader,n=e.loader,i=new(r||n)(e);return t.loader=i,this.loaders[t.type]=i,i},e.getInternalLoader=function(t){return this.loaders[t.type]},e.resetInternalLoader=function(t){this.loaders[t]&&delete this.loaders[t]},e.destroyInternalLoaders=function(){for(var t in this.loaders){var e=this.loaders[t];e&&e.destroy(),this.resetInternalLoader(t)}},e.destroy=function(){this.unregisterListeners(),this.destroyInternalLoaders()},e.onManifestLoading=function(t,e){var r=e.url;this.load({id:null,groupId:null,level:0,responseType:"text",type:l.PlaylistContextType.MANIFEST,url:r,deliveryDirectives:null})},e.onLevelLoading=function(t,e){var r=e.id,n=e.level,i=e.url,o=e.deliveryDirectives;this.load({id:r,groupId:null,level:n,responseType:"text",type:l.PlaylistContextType.LEVEL,url:i,deliveryDirectives:o})},e.onAudioTrackLoading=function(t,e){var r=e.id,n=e.groupId,i=e.url,o=e.deliveryDirectives;this.load({id:r,groupId:n,level:null,responseType:"text",type:l.PlaylistContextType.AUDIO_TRACK,url:i,deliveryDirectives:o})},e.onSubtitleTrackLoading=function(t,e){var r=e.id,n=e.groupId,i=e.url,o=e.deliveryDirectives;this.load({id:r,groupId:n,level:null,responseType:"text",type:l.PlaylistContextType.SUBTITLE_TRACK,url:i,deliveryDirectives:o})},e.load=function(t){var e,r,n,i,o,s,A=this.hls.config,c=this.getInternalLoader(t);if(c){var u=c.context;if(u&&u.url===t.url)return void a.logger.trace("[playlist-loader]: playlist request ongoing");a.logger.log("[playlist-loader]: aborting previous loader for type: "+t.type),c.abort()}switch(t.type){case l.PlaylistContextType.MANIFEST:r=A.manifestLoadingMaxRetry,n=A.manifestLoadingTimeOut,i=A.manifestLoadingRetryDelay,o=A.manifestLoadingMaxRetryTimeout;break;case l.PlaylistContextType.LEVEL:case l.PlaylistContextType.AUDIO_TRACK:case l.PlaylistContextType.SUBTITLE_TRACK:r=0,n=A.levelLoadingTimeOut;break;default:r=A.levelLoadingMaxRetry,n=A.levelLoadingTimeOut,i=A.levelLoadingRetryDelay,o=A.levelLoadingMaxRetryTimeout}if(c=this.createInternalLoader(t),null!==(e=t.deliveryDirectives)&&void 0!==e&&e.part&&(t.type===l.PlaylistContextType.LEVEL&&null!==t.level?s=this.hls.levels[t.level].details:t.type===l.PlaylistContextType.AUDIO_TRACK&&null!==t.id?s=this.hls.audioTracks[t.id].details:t.type===l.PlaylistContextType.SUBTITLE_TRACK&&null!==t.id&&(s=this.hls.subtitleTracks[t.id].details),s)){var h=s.partTarget,d=s.targetduration;h&&d&&(n=Math.min(1e3*Math.max(3*h,.8*d),n))}var f={timeout:n,maxRetry:r,retryDelay:i,maxRetryDelay:o,highWaterMark:0},p={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this)};c.load(t,f,p)},e.loadsuccess=function(t,e,r,n){if(void 0===n&&(n=null),r.isSidxRequest)return this.handleSidxRequest(t,r),void this.handlePlaylistLoaded(t,e,r,n);this.resetInternalLoader(r.type);var i=t.data;0===i.indexOf("#EXTM3U")?(e.parsing.start=performance.now(),i.indexOf("#EXTINF:")>0||i.indexOf("#EXT-X-TARGETDURATION:")>0?this.handleTrackOrLevelPlaylist(t,e,r,n):this.handleMasterPlaylist(t,e,r,n)):this.handleManifestParsingError(t,r,"no EXTM3U delimiter",n)},e.loaderror=function(t,e,r){void 0===r&&(r=null),this.handleNetworkError(e,r,!1,t)},e.loadtimeout=function(t,e,r){void 0===r&&(r=null),this.handleNetworkError(e,r,!0)},e.handleMasterPlaylist=function(t,e,r,n){var o=this.hls,s=t.data,l=u(t,r),h=A.default.parseMasterPlaylist(s,l),d=h.levels,f=h.sessionData;if(d.length){var p=d.map((function(t){return{id:t.attrs.AUDIO,audioCodec:t.audioCodec}})),g=d.map((function(t){return{id:t.attrs.SUBTITLES,textCodec:t.textCodec}})),m=A.default.parseMasterPlaylistMedia(s,l,"AUDIO",p),v=A.default.parseMasterPlaylistMedia(s,l,"SUBTITLES",g),y=A.default.parseMasterPlaylistMedia(s,l,"CLOSED-CAPTIONS");m.length&&(m.some((function(t){return!t.url}))||!d[0].audioCodec||d[0].attrs.AUDIO||(a.logger.log("[playlist-loader]: audio codec signaled in quality level, but no embedded audio track signaled, create one"),m.unshift({type:"main",name:"main",default:!1,autoselect:!1,forced:!1,id:-1,attrs:new c.AttrList({}),bitrate:0,url:""}))),o.trigger(i.Events.MANIFEST_LOADED,{levels:d,audioTracks:m,subtitles:v,captions:y,url:l,stats:e,networkDetails:n,sessionData:f})}else this.handleManifestParsingError(t,r,"no level found in manifest",n)},e.handleTrackOrLevelPlaylist=function(t,e,r,a){var s=this.hls,h=r.id,d=r.level,f=r.type,p=u(t,r),g=Object(n.isFiniteNumber)(h)?h:0,m=Object(n.isFiniteNumber)(d)?d:g,v=function(t){switch(t.type){case l.PlaylistContextType.AUDIO_TRACK:return l.PlaylistLevelType.AUDIO;case l.PlaylistContextType.SUBTITLE_TRACK:return l.PlaylistLevelType.SUBTITLE;default:return l.PlaylistLevelType.MAIN}}(r),y=A.default.parseLevelPlaylist(t.data,p,m,v,g);if(y.fragments.length){if(f===l.PlaylistContextType.MANIFEST){var w={attrs:new c.AttrList({}),bitrate:0,details:y,name:"",url:p};s.trigger(i.Events.MANIFEST_LOADED,{levels:[w],audioTracks:[],url:p,stats:e,networkDetails:a,sessionData:null})}if(e.parsing.end=performance.now(),y.needSidxRanges){var b,C=null===(b=y.fragments[0].initSegment)||void 0===b?void 0:b.url;this.load({url:C,isSidxRequest:!0,type:f,level:d,levelDetails:y,id:h,groupId:null,rangeStart:0,rangeEnd:2048,responseType:"arraybuffer",deliveryDirectives:null})}else r.levelDetails=y,this.handlePlaylistLoaded(t,e,r,a)}else s.trigger(i.Events.ERROR,{type:o.ErrorTypes.NETWORK_ERROR,details:o.ErrorDetails.LEVEL_EMPTY_ERROR,fatal:!1,url:p,reason:"no fragments found in level",level:"number"==typeof r.level?r.level:void 0})},e.handleSidxRequest=function(t,e){var r=Object(s.parseSegmentIndex)(new Uint8Array(t.data));if(r){var n=r.references,i=e.levelDetails;n.forEach((function(t,e){var n=t.info,o=i.fragments[e];0===o.byteRange.length&&o.setByteRange(String(1+n.end-n.start)+"@"+String(n.start)),o.initSegment&&o.initSegment.setByteRange(String(r.moovEndOffset)+"@0")}))}},e.handleManifestParsingError=function(t,e,r,n){this.hls.trigger(i.Events.ERROR,{type:o.ErrorTypes.NETWORK_ERROR,details:o.ErrorDetails.MANIFEST_PARSING_ERROR,fatal:e.type===l.PlaylistContextType.MANIFEST,url:t.url,reason:r,response:t,context:e,networkDetails:n})},e.handleNetworkError=function(t,e,r,n){void 0===r&&(r=!1),a.logger.warn("[playlist-loader]: A network "+(r?"timeout":"error")+" occurred while loading "+t.type+" level: "+t.level+" id: "+t.id+' group-id: "'+t.groupId+'"');var s=o.ErrorDetails.UNKNOWN,A=!1,c=this.getInternalLoader(t);switch(t.type){case l.PlaylistContextType.MANIFEST:s=r?o.ErrorDetails.MANIFEST_LOAD_TIMEOUT:o.ErrorDetails.MANIFEST_LOAD_ERROR,A=!0;break;case l.PlaylistContextType.LEVEL:s=r?o.ErrorDetails.LEVEL_LOAD_TIMEOUT:o.ErrorDetails.LEVEL_LOAD_ERROR,A=!1;break;case l.PlaylistContextType.AUDIO_TRACK:s=r?o.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:o.ErrorDetails.AUDIO_TRACK_LOAD_ERROR,A=!1;break;case l.PlaylistContextType.SUBTITLE_TRACK:s=r?o.ErrorDetails.SUBTITLE_TRACK_LOAD_TIMEOUT:o.ErrorDetails.SUBTITLE_LOAD_ERROR,A=!1}c&&this.resetInternalLoader(t.type);var u={type:o.ErrorTypes.NETWORK_ERROR,details:s,fatal:A,url:t.url,loader:c,context:t,networkDetails:e};n&&(u.response=n),this.hls.trigger(i.Events.ERROR,u)},e.handlePlaylistLoaded=function(t,e,r,n){var o=r.type,a=r.level,s=r.id,A=r.groupId,c=r.loader,u=r.levelDetails,h=r.deliveryDirectives;if(null!=u&&u.targetduration){if(c)switch(u.live&&(c.getCacheAge&&(u.ageHeader=c.getCacheAge()||0),c.getCacheAge&&!isNaN(u.ageHeader)||(u.ageHeader=0)),o){case l.PlaylistContextType.MANIFEST:case l.PlaylistContextType.LEVEL:this.hls.trigger(i.Events.LEVEL_LOADED,{details:u,level:a||0,id:s||0,stats:e,networkDetails:n,deliveryDirectives:h});break;case l.PlaylistContextType.AUDIO_TRACK:this.hls.trigger(i.Events.AUDIO_TRACK_LOADED,{details:u,id:s||0,groupId:A||"",stats:e,networkDetails:n,deliveryDirectives:h});break;case l.PlaylistContextType.SUBTITLE_TRACK:this.hls.trigger(i.Events.SUBTITLE_TRACK_LOADED,{details:u,id:s||0,groupId:A||"",stats:e,networkDetails:n,deliveryDirectives:h})}}else this.handleManifestParsingError(t,r,"invalid target duration",n)},t}();e.default=h},"./src/polyfills/number.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/polyfills/number.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: isFiniteNumber, MAX_SAFE_INTEGER */function(t,e,r){"use strict";r.r(e),r.d(e,"isFiniteNumber",(function(){return n})),r.d(e,"MAX_SAFE_INTEGER",(function(){return i}));var n=Number.isFinite||function(t){return"number"==typeof t&&isFinite(t)},i=Number.MAX_SAFE_INTEGER||9007199254740991},"./src/remux/aac-helper.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/remux/aac-helper.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=function(){function t(){}return t.getSilentFrame=function(t,e){switch(t){case"mp4a.40.2":if(1===e)return new Uint8Array([0,200,0,128,35,128]);if(2===e)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===e)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===e)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===e)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);if(6===e)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,0,178,0,32,8,224]);break;default:if(1===e)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===e)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(3===e)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}},t}();e.default=n},"./src/remux/mp4-generator.ts":
|
|
|
/*!************************************!*\
|
|
|
!*** ./src/remux/mp4-generator.ts ***!
|
|
|
\************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=Math.pow(2,32)-1,i=function(){function t(){}return t.init=function(){var e;for(e in t.types={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],".mp3":[],mvex:[],mvhd:[],pasp:[],sdtp:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[],smhd:[]},t.types)t.types.hasOwnProperty(e)&&(t.types[e]=[e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2),e.charCodeAt(3)]);var r=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),n=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]);t.HDLR_TYPES={video:r,audio:n};var i=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),o=new Uint8Array([0,0,0,0,0,0,0,0]);t.STTS=t.STSC=t.STCO=o,t.STSZ=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),t.VMHD=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),t.SMHD=new Uint8Array([0,0,0,0,0,0,0,0]),t.STSD=new Uint8Array([0,0,0,0,0,0,0,1]);var a=new Uint8Array([105,115,111,109]),s=new Uint8Array([97,118,99,49]),A=new Uint8Array([0,0,0,1]);t.FTYP=t.box(t.types.ftyp,a,A,a,s),t.DINF=t.box(t.types.dinf,t.box(t.types.dref,i))},t.box=function(t){for(var e=8,r=arguments.length,n=new Array(r>1?r-1:0),i=1;i<r;i++)n[i-1]=arguments[i];for(var o=n.length,a=o;o--;)e+=n[o].byteLength;var s=new Uint8Array(e);for(s[0]=e>>24&255,s[1]=e>>16&255,s[2]=e>>8&255,s[3]=255&e,s.set(t,4),o=0,e=8;o<a;o++)s.set(n[o],e),e+=n[o].byteLength;return s},t.hdlr=function(e){return t.box(t.types.hdlr,t.HDLR_TYPES[e])},t.mdat=function(e){return t.box(t.types.mdat,e)},t.mdhd=function(e,r){r*=e;var i=Math.floor(r/(n+1)),o=Math.floor(r%(n+1));return t.box(t.types.mdhd,new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,e>>24&255,e>>16&255,e>>8&255,255&e,i>>24,i>>16&255,i>>8&255,255&i,o>>24,o>>16&255,o>>8&255,255&o,85,196,0,0]))},t.mdia=function(e){return t.box(t.types.mdia,t.mdhd(e.timescale,e.duration),t.hdlr(e.type),t.minf(e))},t.mfhd=function(e){return t.box(t.types.mfhd,new Uint8Array([0,0,0,0,e>>24,e>>16&255,e>>8&255,255&e]))},t.minf=function(e){return"audio"===e.type?t.box(t.types.minf,t.box(t.types.smhd,t.SMHD),t.DINF,t.stbl(e)):t.box(t.types.minf,t.box(t.types.vmhd,t.VMHD),t.DINF,t.stbl(e))},t.moof=function(e,r,n){return t.box(t.types.moof,t.mfhd(e),t.traf(n,r))},t.moov=function(e){for(var r=e.length,n=[];r--;)n[r]=t.trak(e[r]);return t.box.apply(null,[t.types.moov,t.mvhd(e[0].timescale,e[0].duration)].concat(n).concat(t.mvex(e)))},t.mvex=function(e){for(var r=e.length,n=[];r--;)n[r]=t.trex(e[r]);return t.box.apply(null,[t.types.mvex].concat(n))},t.mvhd=function(e,r){r*=e;var i=Math.floor(r/(n+1)),o=Math.floor(r%(n+1)),a=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,e>>24&255,e>>16&255,e>>8&255,255&e,i>>24,i>>16&255,i>>8&255,255&i,o>>24,o>>16&255,o>>8&255,255&o,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return t.box(t.types.mvhd,a)},t.sdtp=function(e){var r,n,i=e.samples||[],o=new Uint8Array(4+i.length);for(r=0;r<i.length;r++)n=i[r].flags,o[r+4]=n.dependsOn<<4|n.isDependedOn<<2|n.hasRedundancy;return t.box(t.types.sdtp,o)},t.stbl=function(e){return t.box(t.types.stbl,t.stsd(e),t.box(t.types.stts,t.STTS),t.box(t.types.stsc,t.STSC),t.box(t.types.stsz,t.STSZ),t.box(t.types.stco,t.STCO))},t.avc1=function(e){var r,n,i,o=[],a=[];for(r=0;r<e.sps.length;r++)i=(n=e.sps[r]).byteLength,o.push(i>>>8&255),o.push(255&i),o=o.concat(Array.prototype.slice.call(n));for(r=0;r<e.pps.length;r++)i=(n=e.pps[r]).byteLength,a.push(i>>>8&255),a.push(255&i),a=a.concat(Array.prototype.slice.call(n));var s=t.box(t.types.avcC,new Uint8Array([1,o[3],o[4],o[5],255,224|e.sps.length].concat(o).concat([e.pps.length]).concat(a))),A=e.width,l=e.height,c=e.pixelRatio[0],u=e.pixelRatio[1];return t.box(t.types.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,A>>8&255,255&A,l>>8&255,255&l,0,72,0,0,0,72,0,0,0,0,0,0,0,1,18,100,97,105,108,121,109,111,116,105,111,110,47,104,108,115,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),s,t.box(t.types.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])),t.box(t.types.pasp,new Uint8Array([c>>24,c>>16&255,c>>8&255,255&c,u>>24,u>>16&255,u>>8&255,255&u])))},t.esds=function(t){var e=t.config.length;return new Uint8Array([0,0,0,0,3,23+e,0,1,0,4,15+e,64,21,0,0,0,0,0,0,0,0,0,0,0,5].concat([e]).concat(t.config).concat([6,1,2]))},t.mp4a=function(e){var r=e.samplerate;return t.box(t.types.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,e.channelCount,0,16,0,0,0,0,r>>8&255,255&r,0,0]),t.box(t.types.esds,t.esds(e)))},t.mp3=function(e){var r=e.samplerate;return t.box(t.types[".mp3"],new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,e.channelCount,0,16,0,0,0,0,r>>8&255,255&r,0,0]))},t.stsd=function(e){return"audio"===e.type?e.isAAC||"mp3"!==e.codec?t.box(t.types.stsd,t.STSD,t.mp4a(e)):t.box(t.types.stsd,t.STSD,t.mp3(e)):t.box(t.types.stsd,t.STSD,t.avc1(e))},t.tkhd=function(e){var r=e.id,i=e.duration*e.timescale,o=e.width,a=e.height,s=Math.floor(i/(n+1)),A=Math.floor(i%(n+1));return t.box(t.types.tkhd,new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,r>>24&255,r>>16&255,r>>8&255,255&r,0,0,0,0,s>>24,s>>16&255,s>>8&255,255&s,A>>24,A>>16&255,A>>8&255,255&A,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,o>>8&255,255&o,0,0,a>>8&255,255&a,0,0]))},t.traf=function(e,r){var i=t.sdtp(e),o=e.id,a=Math.floor(r/(n+1)),s=Math.floor(r%(n+1));return t.box(t.types.traf,t.box(t.types.tfhd,new Uint8Array([0,0,0,0,o>>24,o>>16&255,o>>8&255,255&o])),t.box(t.types.tfdt,new Uint8Array([1,0,0,0,a>>24,a>>16&255,a>>8&255,255&a,s>>24,s>>16&255,s>>8&255,255&s])),t.trun(e,i.length+16+20+8+16+8+8),i)},t.trak=function(e){return e.duration=e.duration||4294967295,t.box(t.types.trak,t.tkhd(e),t.mdia(e))},t.trex=function(e){var r=e.id;return t.box(t.types.trex,new Uint8Array([0,0,0,0,r>>24,r>>16&255,r>>8&255,255&r,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))},t.trun=function(e,r){var n,i,o,a,s,A,l=e.samples||[],c=l.length,u=12+16*c,h=new Uint8Array(u);for(r+=8+u,h.set([0,0,15,1,c>>>24&255,c>>>16&255,c>>>8&255,255&c,r>>>24&255,r>>>16&255,r>>>8&255,255&r],0),n=0;n<c;n++)o=(i=l[n]).duration,a=i.size,s=i.flags,A=i.cts,h.set([o>>>24&255,o>>>16&255,o>>>8&255,255&o,a>>>24&255,a>>>16&255,a>>>8&255,255&a,s.isLeading<<2|s.dependsOn,s.isDependedOn<<6|s.hasRedundancy<<4|s.paddingValue<<1|s.isNonSync,61440&s.degradPrio,15&s.degradPrio,A>>>24&255,A>>>16&255,A>>>8&255,255&A],12+16*n);return t.box(t.types.trun,h)},t.initSegment=function(e){t.types||t.init();var r=t.moov(e),n=new Uint8Array(t.FTYP.byteLength+r.byteLength);return n.set(t.FTYP),n.set(r,t.FTYP.byteLength),n},t}();i.types=void 0,i.HDLR_TYPES=void 0,i.STTS=void 0,i.STSC=void 0,i.STCO=void 0,i.STSZ=void 0,i.VMHD=void 0,i.SMHD=void 0,i.STSD=void 0,i.FTYP=void 0,i.DINF=void 0,e.default=i},"./src/remux/mp4-remuxer.ts":
|
|
|
/*!**********************************!*\
|
|
|
!*** ./src/remux/mp4-remuxer.ts ***!
|
|
|
\**********************************/
|
|
|
/*! exports provided: default, normalizePts */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return p})),r.d(e,"normalizePts",(function(){return g}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ./aac-helper */"./src/remux/aac-helper.ts"),o=r(/*! ./mp4-generator */"./src/remux/mp4-generator.ts"),a=r(/*! ../events */"./src/events.ts"),s=r(/*! ../errors */"./src/errors.ts"),A=r(/*! ../utils/logger */"./src/utils/logger.ts"),l=r(/*! ../types/loader */"./src/types/loader.ts"),c=r(/*! ../utils/timescale-conversion */"./src/utils/timescale-conversion.ts");function u(){return(u=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}var h=null,d=null,f=!1,p=function(){function t(t,e,r,n){if(void 0===n&&(n=""),this.observer=void 0,this.config=void 0,this.typeSupported=void 0,this.ISGenerated=!1,this._initPTS=void 0,this._initDTS=void 0,this.nextAvcDts=null,this.nextAudioPts=null,this.isAudioContiguous=!1,this.isVideoContiguous=!1,this.observer=t,this.config=e,this.typeSupported=r,this.ISGenerated=!1,null===h){var i=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);h=i?parseInt(i[1]):0}if(null===d){var o=navigator.userAgent.match(/Safari\/(\d+)/i);d=o?parseInt(o[1]):0}f=!!h&&h<75||!!d&&d<600}var e=t.prototype;return e.destroy=function(){},e.resetTimeStamp=function(t){A.logger.log("[mp4-remuxer]: initPTS & initDTS reset"),this._initPTS=this._initDTS=t},e.resetNextTimestamp=function(){A.logger.log("[mp4-remuxer]: reset next timestamp"),this.isVideoContiguous=!1,this.isAudioContiguous=!1},e.resetInitSegment=function(){A.logger.log("[mp4-remuxer]: ISGenerated flag reset"),this.ISGenerated=!1},e.getVideoStartPts=function(t){var e=!1,r=t.reduce((function(t,r){var n=r.pts-t;return n<-4294967296?(e=!0,g(t,r.pts)):n>0?t:r.pts}),t[0].pts);return e&&A.logger.debug("PTS rollover detected"),r},e.remux=function(t,e,r,n,i,o,a,s){var c,u,h,d,f,p,m=i,v=i,y=t.pid>-1,w=e.pid>-1,b=e.samples.length,C=t.samples.length>0,B=b>1;if((!y||C)&&(!w||B)||this.ISGenerated||a){this.ISGenerated||(h=this.generateIS(t,e,i));var x=this.isVideoContiguous,E=-1;if(B&&(E=function(t){for(var e=0;e<t.length;e++)if(t[e].key)return e;return-1}(e.samples),!x&&this.config.forceKeyFrameOnDiscontinuity))if(p=!0,E>0){A.logger.warn("[mp4-remuxer]: Dropped "+E+" out of "+b+" video samples due to a missing keyframe");var S=this.getVideoStartPts(e.samples);e.samples=e.samples.slice(E),e.dropped+=E,v+=(e.samples[0].pts-S)/(e.timescale||9e4)}else-1===E&&(A.logger.warn("[mp4-remuxer]: No keyframe found out of "+b+" video samples"),p=!1);if(this.ISGenerated){if(C&&B){var k=this.getVideoStartPts(e.samples),T=(g(t.samples[0].pts,k)-k)/e.inputTimeScale;m+=Math.max(0,T),v+=Math.max(0,-T)}if(C){if(t.samplerate||(A.logger.warn("[mp4-remuxer]: regenerate InitSegment as audio detected"),h=this.generateIS(t,e,i)),u=this.remuxAudio(t,m,this.isAudioContiguous,o,w||B||s===l.PlaylistLevelType.AUDIO?v:void 0),B){var F=u?u.endPTS-u.startPTS:0;e.inputTimeScale||(A.logger.warn("[mp4-remuxer]: regenerate InitSegment as video detected"),h=this.generateIS(t,e,i)),c=this.remuxVideo(e,v,x,F)}}else B&&(c=this.remuxVideo(e,v,x,0));c&&(c.firstKeyFrame=E,c.independent=-1!==E)}}return this.ISGenerated&&(r.samples.length&&(f=this.remuxID3(r,i)),n.samples.length&&(d=this.remuxText(n,i))),{audio:u,video:c,initSegment:h,independent:p,text:d,id3:f}},e.generateIS=function(t,e,r){var i,a,s,A=t.samples,l=e.samples,c=this.typeSupported,u={},h=!Object(n.isFiniteNumber)(this._initPTS),d="audio/mp4";if(h&&(i=a=1/0),t.config&&A.length&&(t.timescale=t.samplerate,t.isAAC||(c.mpeg?(d="audio/mpeg",t.codec=""):c.mp3&&(t.codec="mp3")),u.audio={id:"audio",container:d,codec:t.codec,initSegment:!t.isAAC&&c.mpeg?new Uint8Array(0):o.default.initSegment([t]),metadata:{channelCount:t.channelCount}},h&&(s=t.inputTimeScale,i=a=A[0].pts-Math.round(s*r))),e.sps&&e.pps&&l.length&&(e.timescale=e.inputTimeScale,u.video={id:"main",container:"video/mp4",codec:e.codec,initSegment:o.default.initSegment([e]),metadata:{width:e.width,height:e.height}},h)){s=e.inputTimeScale;var f=this.getVideoStartPts(l),p=Math.round(s*r);a=Math.min(a,g(l[0].dts,f)-p),i=Math.min(i,f-p)}if(Object.keys(u).length)return this.ISGenerated=!0,h&&(this._initPTS=i,this._initDTS=a),{tracks:u,initPTS:i,timescale:s}},e.remuxVideo=function(t,e,r,n){var i,l,d,p=t.inputTimeScale,v=t.samples,y=[],w=v.length,b=this._initPTS,C=this.nextAvcDts,B=8,x=Number.POSITIVE_INFINITY,E=Number.NEGATIVE_INFINITY,S=0,k=!1;r&&null!==C||(C=e*p-(v[0].pts-g(v[0].dts,v[0].pts)));for(var T=0;T<w;T++){var F=v[T];F.pts=g(F.pts-b,C),F.dts=g(F.dts-b,C),F.dts>F.pts&&(S=Math.max(Math.min(S,F.pts-F.dts),-18e3)),F.dts<v[T>0?T-1:T].dts&&(k=!0)}k&&v.sort((function(t,e){var r=t.dts-e.dts,n=t.pts-e.pts;return r||n})),l=v[0].dts,d=v[v.length-1].dts;var L=Math.round((d-l)/(w-1));if(S<0){if(S<-2*L){A.logger.warn("PTS < DTS detected in video samples, offsetting DTS from PTS by "+Object(c.toMsFromMpegTsClock)(-L,!0)+" ms");for(var I=S,_=0;_<w;_++)v[_].dts=I=Math.max(I,v[_].pts-L),v[_].pts=Math.max(I,v[_].pts)}else{A.logger.warn("PTS < DTS detected in video samples, shifting DTS by "+Object(c.toMsFromMpegTsClock)(S,!0)+" ms to overcome this issue");for(var U=0;U<w;U++)v[U].dts=v[U].dts+S}l=v[0].dts}if(r){var O=l-C,D=O>L;if(D||O<-1){D?A.logger.warn("AVC: "+Object(c.toMsFromMpegTsClock)(O,!0)+" ms ("+O+"dts) hole between fragments detected, filling it"):A.logger.warn("AVC: "+Object(c.toMsFromMpegTsClock)(-O,!0)+" ms ("+O+"dts) overlapping between fragments detected"),l=C;var Q=v[0].pts-O;v[0].dts=l,v[0].pts=Q,A.logger.log("Video: First PTS/DTS adjusted: "+Object(c.toMsFromMpegTsClock)(Q,!0)+"/"+Object(c.toMsFromMpegTsClock)(l,!0)+", delta: "+Object(c.toMsFromMpegTsClock)(O,!0)+" ms")}}f&&(l=Math.max(0,l));for(var M=0,R=0,P=0;P<w;P++){for(var H=v[P],N=H.units,K=N.length,j=0,G=0;G<K;G++)j+=N[G].data.length;R+=j,M+=K,H.length=j,H.dts=Math.max(H.dts,l),H.pts=Math.max(H.pts,H.dts,0),x=Math.min(H.pts,x),E=Math.max(H.pts,E)}d=v[w-1].dts;var V,z=R+4*M+8;try{V=new Uint8Array(z)}catch(t){return void this.observer.emit(a.Events.ERROR,a.Events.ERROR,{type:s.ErrorTypes.MUX_ERROR,details:s.ErrorDetails.REMUX_ALLOC_ERROR,fatal:!1,bytes:z,reason:"fail allocating video mdat "+z})}var W=new DataView(V.buffer);W.setUint32(0,z),V.set(o.default.types.mdat,4);for(var Y=0;Y<w;Y++){for(var X=v[Y],q=X.units,J=0,Z=0,$=q.length;Z<$;Z++){var tt=q[Z],et=tt.data,rt=tt.data.byteLength;W.setUint32(B,rt),B+=4,V.set(et,B),B+=rt,J+=4+rt}if(Y<w-1)i=v[Y+1].dts-X.dts;else{var nt=this.config,it=X.dts-v[Y>0?Y-1:Y].dts;if(nt.stretchShortVideoTrack&&null!==this.nextAudioPts){var ot=Math.floor(nt.maxBufferHole*p),at=(n?x+n*p:this.nextAudioPts)-X.pts;at>ot?((i=at-it)<0&&(i=it),A.logger.log("[mp4-remuxer]: It is approximately "+at/90+" ms to the next segment; using duration "+i/90+" ms for the last video frame.")):i=it}else i=it}var st=Math.round(X.pts-X.dts);y.push(new m(X.key,i,J,st))}if(y.length&&h&&h<70){var At=y[0].flags;At.dependsOn=2,At.isNonSync=0}console.assert(void 0!==i,"mp4SampleDuration must be computed"),this.nextAvcDts=C=d+i,this.isVideoContiguous=!0;var lt={data1:o.default.moof(t.sequenceNumber++,l,u({},t,{samples:y})),data2:V,startPTS:x/p,endPTS:(E+i)/p,startDTS:l/p,endDTS:C/p,type:"video",hasAudio:!1,hasVideo:!0,nb:y.length,dropped:t.dropped};return t.samples=[],t.dropped=0,console.assert(V.length,"MDAT length must not be zero"),lt},e.remuxAudio=function(t,e,r,n,l){var c=t.inputTimeScale,h=c/(t.samplerate?t.samplerate:c),d=t.isAAC?1024:1152,f=d*h,p=this._initPTS,v=!t.isAAC&&this.typeSupported.mpeg,y=[],w=t.samples,b=v?0:8,C=this.nextAudioPts||-1,B=e*c;if(this.isAudioContiguous=r=r||w.length&&C>0&&(n&&Math.abs(B-C)<9e3||Math.abs(g(w[0].pts-p,B)-C)<20*f),w.forEach((function(t){t.pts=g(t.pts-p,B)})),!r||C<0){if(!(w=w.filter((function(t){return t.pts>=0}))).length)return;C=0===l?0:n?Math.max(0,B):w[0].pts}if(t.isAAC)for(var x=void 0!==l,E=this.config.maxAudioFramesDrift,S=0,k=C;S<w.length;S++){var T=w[S],F=T.pts,L=F-k,I=Math.abs(1e3*L/c);if(L<=-E*f&&x)0===S&&(A.logger.warn("Audio frame @ "+(F/c).toFixed(3)+"s overlaps nextAudioPts by "+Math.round(1e3*L/c)+" ms."),this.nextAudioPts=C=k=F);else if(L>=E*f&&I<1e4&&x){var _=Math.round(L/f);(k=F-_*f)<0&&(_--,k+=f),0===S&&(this.nextAudioPts=C=k),A.logger.warn("[mp4-remuxer]: Injecting "+_+" audio frame @ "+(k/c).toFixed(3)+"s due to "+Math.round(1e3*L/c)+" ms gap.");for(var U=0;U<_;U++){var O=Math.max(k,0),D=i.default.getSilentFrame(t.manifestCodec||t.codec,t.channelCount);D||(A.logger.log("[mp4-remuxer]: Unable to get silent frame for given audio codec; duplicating last frame instead."),D=T.unit.subarray()),w.splice(S,0,{unit:D,pts:O}),k+=f,S++}}T.pts=k,k+=f}for(var Q,M=null,R=null,P=0,H=w.length;H--;)P+=w[H].unit.byteLength;for(var N=0,K=w.length;N<K;N++){var j=w[N],G=j.unit,V=j.pts;if(null!==R)y[N-1].duration=Math.round((V-R)/h);else{if(r&&t.isAAC&&(V=C),M=V,!(P>0))return;P+=b;try{Q=new Uint8Array(P)}catch(t){return void this.observer.emit(a.Events.ERROR,a.Events.ERROR,{type:s.ErrorTypes.MUX_ERROR,details:s.ErrorDetails.REMUX_ALLOC_ERROR,fatal:!1,bytes:P,reason:"fail allocating audio mdat "+P})}v||(new DataView(Q.buffer).setUint32(0,P),Q.set(o.default.types.mdat,4))}Q.set(G,b);var z=G.byteLength;b+=z,y.push(new m(!0,d,z,0)),R=V}var W=y.length;if(W){var Y=y[y.length-1];this.nextAudioPts=C=R+h*Y.duration;var X=v?new Uint8Array(0):o.default.moof(t.sequenceNumber++,M/h,u({},t,{samples:y}));t.samples=[];var q=M/c,J=C/c,Z={data1:X,data2:Q,startPTS:q,endPTS:J,startDTS:q,endDTS:J,type:"audio",hasAudio:!0,hasVideo:!1,nb:W};return this.isAudioContiguous=!0,console.assert(Q.length,"MDAT length must not be zero"),Z}},e.remuxEmptyAudio=function(t,e,r,n){var o=t.inputTimeScale,a=o/(t.samplerate?t.samplerate:o),s=this.nextAudioPts,l=(null!==s?s:n.startDTS*o)+this._initDTS,c=n.endDTS*o+this._initDTS,u=1024*a,h=Math.ceil((c-l)/u),d=i.default.getSilentFrame(t.manifestCodec||t.codec,t.channelCount);if(A.logger.warn("[mp4-remuxer]: remux empty Audio"),d){for(var f=[],p=0;p<h;p++){var g=l+p*u;f.push({unit:d,pts:g,dts:g})}return t.samples=f,this.remuxAudio(t,e,r,!1)}A.logger.trace("[mp4-remuxer]: Unable to remuxEmptyAudio since we were unable to get a silent frame for given audio codec")},e.remuxID3=function(t,e){var r=t.samples.length;if(r){for(var n=t.inputTimeScale,i=this._initPTS,o=this._initDTS,a=0;a<r;a++){var s=t.samples[a];s.pts=g(s.pts-i,e*n)/n,s.dts=g(s.dts-o,e*n)/n}var A=t.samples;return t.samples=[],{samples:A}}},e.remuxText=function(t,e){var r=t.samples.length;if(r){for(var n=t.inputTimeScale,i=this._initPTS,o=0;o<r;o++){var a=t.samples[o];a.pts=g(a.pts-i,e*n)/n}t.samples.sort((function(t,e){return t.pts-e.pts}));var s=t.samples;return t.samples=[],{samples:s}}},t}();function g(t,e){var r;if(null===e)return t;for(r=e<t?-8589934592:8589934592;Math.abs(t-e)>4294967296;)t+=r;return t}var m=function(t,e,r,n){this.size=void 0,this.duration=void 0,this.cts=void 0,this.flags=void 0,this.duration=e,this.size=r,this.cts=n,this.flags=new v(t)},v=function(t){this.isLeading=0,this.isDependedOn=0,this.hasRedundancy=0,this.degradPrio=0,this.dependsOn=1,this.isNonSync=1,this.dependsOn=t?2:1,this.isNonSync=t?0:1}},"./src/remux/passthrough-remuxer.ts":
|
|
|
/*!******************************************!*\
|
|
|
!*** ./src/remux/passthrough-remuxer.ts ***!
|
|
|
\******************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../utils/mp4-tools */"./src/utils/mp4-tools.ts"),o=r(/*! ../loader/fragment */"./src/loader/fragment.ts"),a=r(/*! ../utils/logger */"./src/utils/logger.ts"),s=function(){function t(){this.emitInitSegment=!1,this.audioCodec=void 0,this.videoCodec=void 0,this.initData=void 0,this.initPTS=void 0,this.initTracks=void 0,this.lastEndDTS=null}var e=t.prototype;return e.destroy=function(){},e.resetTimeStamp=function(t){this.initPTS=t,this.lastEndDTS=null},e.resetNextTimestamp=function(){this.lastEndDTS=null},e.resetInitSegment=function(t,e,r){this.audioCodec=e,this.videoCodec=r,this.generateInitSegment(t),this.emitInitSegment=!0},e.generateInitSegment=function(t){var e=this.audioCodec,r=this.videoCodec;if(!t||!t.byteLength)return this.initTracks=void 0,void(this.initData=void 0);var n=this.initData=Object(i.parseInitSegment)(t);e||(e=l(n.audio,o.ElementaryStreamTypes.AUDIO)),r||(r=l(n.video,o.ElementaryStreamTypes.VIDEO));var s={};n.audio&&n.video?s.audiovideo={container:"video/mp4",codec:e+","+r,initSegment:t,id:"main"}:n.audio?s.audio={container:"audio/mp4",codec:e,initSegment:t,id:"audio"}:n.video?s.video={container:"video/mp4",codec:r,initSegment:t,id:"main"}:a.logger.warn("[passthrough-remuxer.ts]: initSegment does not contain moov or trak boxes."),this.initTracks=s},e.remux=function(t,e,r,o,s){var l=this.initPTS,c=this.lastEndDTS,u={audio:void 0,video:void 0,text:o,id3:r,initSegment:void 0};Object(n.isFiniteNumber)(c)||(c=this.lastEndDTS=s||0);var h=e.samples;if(!h||!h.length)return u;var d={initPTS:void 0,timescale:1},f=this.initData;if(f&&f.length||(this.generateInitSegment(h),f=this.initData),!f||!f.length)return a.logger.warn("[passthrough-remuxer.ts]: Failed to generate initSegment."),u;this.emitInitSegment&&(d.tracks=this.initTracks,this.emitInitSegment=!1),Object(n.isFiniteNumber)(l)||(this.initPTS=d.initPTS=l=A(f,h,c));var p=Object(i.getDuration)(h,f),g=c,m=p+g;Object(i.offsetStartDTS)(f,h,l),p>0?this.lastEndDTS=m:(a.logger.warn("Duration parsed from mp4 should be greater than zero"),this.resetNextTimestamp());var v=!!f.audio,y=!!f.video,w="";v&&(w+="audio"),y&&(w+="video");var b={data1:h,startPTS:g,startDTS:g,endPTS:m,endDTS:m,type:w,hasAudio:v,hasVideo:y,nb:1,dropped:0};return u.audio="audio"===b.type?b:void 0,u.video="audio"!==b.type?b:void 0,u.text=o,u.id3=r,u.initSegment=d,u},t}(),A=function(t,e,r){return Object(i.getStartDTS)(t,e)-r};function l(t,e){var r=null==t?void 0:t.codec;return r&&r.length>4?r:"hvc1"===r?"hvc1.1.c.L120.90":"av01"===r?"av01.0.04M.08":"avc1"===r||e===o.ElementaryStreamTypes.VIDEO?"avc1.42e01e":"mp4a.40.5"}e.default=s},"./src/task-loop.ts":
|
|
|
/*!**************************!*\
|
|
|
!*** ./src/task-loop.ts ***!
|
|
|
\**************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return n}));var n=function(){function t(){this._boundTick=void 0,this._tickTimer=null,this._tickInterval=null,this._tickCallCount=0,this._boundTick=this.tick.bind(this)}var e=t.prototype;return e.destroy=function(){this.onHandlerDestroying(),this.onHandlerDestroyed()},e.onHandlerDestroying=function(){this.clearNextTick(),this.clearInterval()},e.onHandlerDestroyed=function(){},e.hasInterval=function(){return!!this._tickInterval},e.hasNextTick=function(){return!!this._tickTimer},e.setInterval=function(t){return!this._tickInterval&&(this._tickInterval=self.setInterval(this._boundTick,t),!0)},e.clearInterval=function(){return!!this._tickInterval&&(self.clearInterval(this._tickInterval),this._tickInterval=null,!0)},e.clearNextTick=function(){return!!this._tickTimer&&(self.clearTimeout(this._tickTimer),this._tickTimer=null,!0)},e.tick=function(){this._tickCallCount++,1===this._tickCallCount&&(this.doTick(),this._tickCallCount>1&&this.tickImmediate(),this._tickCallCount=0)},e.tickImmediate=function(){this.clearNextTick(),this._tickTimer=self.setTimeout(this._boundTick,0)},e.doTick=function(){},t}()},"./src/types/cmcd.ts":
|
|
|
/*!***************************!*\
|
|
|
!*** ./src/types/cmcd.ts ***!
|
|
|
\***************************/
|
|
|
/*! exports provided: CMCDVersion, CMCDObjectType, CMCDStreamingFormat, CMCDStreamType */function(t,e,r){"use strict";r.r(e),r.d(e,"CMCDVersion",(function(){return a})),r.d(e,"CMCDObjectType",(function(){return n})),r.d(e,"CMCDStreamingFormat",(function(){return i})),r.d(e,"CMCDStreamType",(function(){return o}));var n,i,o,a=1;!function(t){t.MANIFEST="m",t.AUDIO="a",t.VIDEO="v",t.MUXED="av",t.INIT="i",t.CAPTION="c",t.TIMED_TEXT="tt",t.KEY="k",t.OTHER="o"}(n||(n={})),function(t){t.DASH="d",t.HLS="h",t.SMOOTH="s",t.OTHER="o"}(i||(i={})),function(t){t.VOD="v",t.LIVE="l"}(o||(o={}))},"./src/types/level.ts":
|
|
|
/*!****************************!*\
|
|
|
!*** ./src/types/level.ts ***!
|
|
|
\****************************/
|
|
|
/*! exports provided: HlsSkip, getSkipValue, HlsUrlParameters, Level */function(t,e,r){"use strict";function n(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var i;function o(t,e){var r=t.canSkipUntil,n=t.canSkipDateRanges,o=t.endSN;return r&&(void 0!==e?e-o:0)<r?n?i.v2:i.Yes:i.No}r.r(e),r.d(e,"HlsSkip",(function(){return i})),r.d(e,"getSkipValue",(function(){return o})),r.d(e,"HlsUrlParameters",(function(){return a})),r.d(e,"Level",(function(){return s})),function(t){t.No="",t.Yes="YES",t.v2="v2"}(i||(i={}));var a=function(){function t(t,e,r){this.msn=void 0,this.part=void 0,this.skip=void 0,this.msn=t,this.part=e,this.skip=r}return t.prototype.addDirectives=function(t){var e=new self.URL(t);return void 0!==this.msn&&e.searchParams.set("_HLS_msn",this.msn.toString()),void 0!==this.part&&e.searchParams.set("_HLS_part",this.part.toString()),this.skip&&e.searchParams.set("_HLS_skip",this.skip),e.toString()},t}(),s=function(){function t(t){this.attrs=void 0,this.audioCodec=void 0,this.bitrate=void 0,this.codecSet=void 0,this.height=void 0,this.id=void 0,this.name=void 0,this.videoCodec=void 0,this.width=void 0,this.unknownCodecs=void 0,this.audioGroupIds=void 0,this.details=void 0,this.fragmentError=0,this.loadError=0,this.loaded=void 0,this.realBitrate=0,this.textGroupIds=void 0,this.url=void 0,this._urlId=0,this.url=[t.url],this.attrs=t.attrs,this.bitrate=t.bitrate,t.details&&(this.details=t.details),this.id=t.id||0,this.name=t.name,this.width=t.width||0,this.height=t.height||0,this.audioCodec=t.audioCodec,this.videoCodec=t.videoCodec,this.unknownCodecs=t.unknownCodecs,this.codecSet=[t.videoCodec,t.audioCodec].filter((function(t){return t})).join(",").replace(/\.[^.,]+/g,"")}var e,r,i;return e=t,(r=[{key:"maxBitrate",get:function(){return Math.max(this.realBitrate,this.bitrate)}},{key:"uri",get:function(){return this.url[this._urlId]||""}},{key:"urlId",get:function(){return this._urlId},set:function(t){var e=t%this.url.length;this._urlId!==e&&(this.details=void 0,this._urlId=e)}}])&&n(e.prototype,r),i&&n(e,i),t}()},"./src/types/loader.ts":
|
|
|
/*!*****************************!*\
|
|
|
!*** ./src/types/loader.ts ***!
|
|
|
\*****************************/
|
|
|
/*! exports provided: PlaylistContextType, PlaylistLevelType */function(t,e,r){"use strict";var n,i;r.r(e),r.d(e,"PlaylistContextType",(function(){return n})),r.d(e,"PlaylistLevelType",(function(){return i})),function(t){t.MANIFEST="manifest",t.LEVEL="level",t.AUDIO_TRACK="audioTrack",t.SUBTITLE_TRACK="subtitleTrack"}(n||(n={})),function(t){t.MAIN="main",t.AUDIO="audio",t.SUBTITLE="subtitle"}(i||(i={}))},"./src/types/transmuxer.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/types/transmuxer.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: ChunkMetadata */function(t,e,r){"use strict";r.r(e),r.d(e,"ChunkMetadata",(function(){return n}));var n=function(t,e,r,n,i,o){void 0===n&&(n=0),void 0===i&&(i=-1),void 0===o&&(o=!1),this.level=void 0,this.sn=void 0,this.part=void 0,this.id=void 0,this.size=void 0,this.partial=void 0,this.transmuxing={start:0,executeStart:0,executeEnd:0,end:0},this.buffering={audio:{start:0,executeStart:0,executeEnd:0,end:0},video:{start:0,executeStart:0,executeEnd:0,end:0},audiovideo:{start:0,executeStart:0,executeEnd:0,end:0}},this.level=t,this.sn=e,this.id=r,this.size=n,this.part=i,this.partial=o}},"./src/utils/attr-list.ts":
|
|
|
/*!********************************!*\
|
|
|
!*** ./src/utils/attr-list.ts ***!
|
|
|
\********************************/
|
|
|
/*! exports provided: AttrList */function(t,e,r){"use strict";r.r(e),r.d(e,"AttrList",(function(){return o}));var n=/^(\d+)x(\d+)$/,i=/\s*(.+?)\s*=((?:\".*?\")|.*?)(?:,|$)/g,o=function(){function t(e){for(var r in"string"==typeof e&&(e=t.parseAttrList(e)),e)e.hasOwnProperty(r)&&(this[r]=e[r])}var e=t.prototype;return e.decimalInteger=function(t){var e=parseInt(this[t],10);return e>Number.MAX_SAFE_INTEGER?1/0:e},e.hexadecimalInteger=function(t){if(this[t]){var e=(this[t]||"0x").slice(2);e=(1&e.length?"0":"")+e;for(var r=new Uint8Array(e.length/2),n=0;n<e.length/2;n++)r[n]=parseInt(e.slice(2*n,2*n+2),16);return r}return null},e.hexadecimalIntegerAsNumber=function(t){var e=parseInt(this[t],16);return e>Number.MAX_SAFE_INTEGER?1/0:e},e.decimalFloatingPoint=function(t){return parseFloat(this[t])},e.optionalFloat=function(t,e){var r=this[t];return r?parseFloat(r):e},e.enumeratedString=function(t){return this[t]},e.bool=function(t){return"YES"===this[t]},e.decimalResolution=function(t){var e=n.exec(this[t]);if(null!==e)return{width:parseInt(e[1],10),height:parseInt(e[2],10)}},t.parseAttrList=function(t){var e,r={};for(i.lastIndex=0;null!==(e=i.exec(t));){var n=e[2];0===n.indexOf('"')&&n.lastIndexOf('"')===n.length-1&&(n=n.slice(1,-1)),r[e[1]]=n}return r},t}()},"./src/utils/binary-search.ts":
|
|
|
/*!************************************!*\
|
|
|
!*** ./src/utils/binary-search.ts ***!
|
|
|
\************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),e.default={search:function(t,e){for(var r=0,n=t.length-1,i=null,o=null;r<=n;){var a=e(o=t[i=(r+n)/2|0]);if(a>0)r=i+1;else{if(!(a<0))return o;n=i-1}}return null}}},"./src/utils/buffer-helper.ts":
|
|
|
/*!************************************!*\
|
|
|
!*** ./src/utils/buffer-helper.ts ***!
|
|
|
\************************************/
|
|
|
/*! exports provided: BufferHelper */function(t,e,r){"use strict";r.r(e),r.d(e,"BufferHelper",(function(){return o}));var n=r(/*! ./logger */"./src/utils/logger.ts"),i={length:0,start:function(){return 0},end:function(){return 0}},o=function(){function t(){}return t.isBuffered=function(e,r){try{if(e)for(var n=t.getBuffered(e),i=0;i<n.length;i++)if(r>=n.start(i)&&r<=n.end(i))return!0}catch(t){}return!1},t.bufferInfo=function(e,r,n){try{if(e){var i,o=t.getBuffered(e),a=[];for(i=0;i<o.length;i++)a.push({start:o.start(i),end:o.end(i)});return this.bufferedInfo(a,r,n)}}catch(t){}return{len:0,start:r,end:r,nextStart:void 0}},t.bufferedInfo=function(t,e,r){e=Math.max(0,e),t.sort((function(t,e){var r=t.start-e.start;return r||e.end-t.end}));var n=[];if(r)for(var i=0;i<t.length;i++){var o=n.length;if(o){var a=n[o-1].end;t[i].start-a<r?t[i].end>a&&(n[o-1].end=t[i].end):n.push(t[i])}else n.push(t[i])}else n=t;for(var s,A=0,l=e,c=e,u=0;u<n.length;u++){var h=n[u].start,d=n[u].end;if(e+r>=h&&e<d)l=h,A=(c=d)-e;else if(e+r<h){s=h;break}}return{len:A,start:l||0,end:c||0,nextStart:s}},t.getBuffered=function(t){try{return t.buffered}catch(t){return n.logger.log("failed to get media.buffered",t),i}},t}()},"./src/utils/cea-608-parser.ts":
|
|
|
/*!*************************************!*\
|
|
|
!*** ./src/utils/cea-608-parser.ts ***!
|
|
|
\*************************************/
|
|
|
/*! exports provided: Row, CaptionScreen, default */function(t,e,r){"use strict";r.r(e),r.d(e,"Row",(function(){return g})),r.d(e,"CaptionScreen",(function(){return m}));var n,i=r(/*! ../utils/logger */"./src/utils/logger.ts"),o={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,128:174,129:176,130:189,131:191,132:8482,133:162,134:163,135:9834,136:224,137:32,138:232,139:226,140:234,141:238,142:244,143:251,144:193,145:201,146:211,147:218,148:220,149:252,150:8216,151:161,152:42,153:8217,154:9473,155:169,156:8480,157:8226,158:8220,159:8221,160:192,161:194,162:199,163:200,164:202,165:203,166:235,167:206,168:207,169:239,170:212,171:217,172:249,173:219,174:171,175:187,176:195,177:227,178:205,179:204,180:236,181:210,182:242,183:213,184:245,185:123,186:125,187:92,188:94,189:95,190:124,191:8764,192:196,193:228,194:214,195:246,196:223,197:165,198:164,199:9475,200:197,201:229,202:216,203:248,204:9487,205:9491,206:9495,207:9499},a=function(t){var e=t;return o.hasOwnProperty(t)&&(e=o[t]),String.fromCharCode(e)},s={17:1,18:3,21:5,22:7,23:9,16:11,19:12,20:14},A={17:2,18:4,21:6,22:8,23:10,19:13,20:15},l={25:1,26:3,29:5,30:7,31:9,24:11,27:12,28:14},c={25:2,26:4,29:6,30:8,31:10,27:13,28:15},u=["white","green","blue","cyan","red","yellow","magenta","black","transparent"];!function(t){t[t.ERROR=0]="ERROR",t[t.TEXT=1]="TEXT",t[t.WARNING=2]="WARNING",t[t.INFO=2]="INFO",t[t.DEBUG=3]="DEBUG",t[t.DATA=3]="DATA"}(n||(n={}));var h=function(){function t(){this.time=null,this.verboseLevel=n.ERROR}return t.prototype.log=function(t,e){this.verboseLevel>=t&&i.logger.log(this.time+" ["+t+"] "+e)},t}(),d=function(t){for(var e=[],r=0;r<t.length;r++)e.push(t[r].toString(16));return e},f=function(){function t(t,e,r,n,i){this.foreground=void 0,this.underline=void 0,this.italics=void 0,this.background=void 0,this.flash=void 0,this.foreground=t||"white",this.underline=e||!1,this.italics=r||!1,this.background=n||"black",this.flash=i||!1}var e=t.prototype;return e.reset=function(){this.foreground="white",this.underline=!1,this.italics=!1,this.background="black",this.flash=!1},e.setStyles=function(t){for(var e=["foreground","underline","italics","background","flash"],r=0;r<e.length;r++){var n=e[r];t.hasOwnProperty(n)&&(this[n]=t[n])}},e.isDefault=function(){return"white"===this.foreground&&!this.underline&&!this.italics&&"black"===this.background&&!this.flash},e.equals=function(t){return this.foreground===t.foreground&&this.underline===t.underline&&this.italics===t.italics&&this.background===t.background&&this.flash===t.flash},e.copy=function(t){this.foreground=t.foreground,this.underline=t.underline,this.italics=t.italics,this.background=t.background,this.flash=t.flash},e.toString=function(){return"color="+this.foreground+", underline="+this.underline+", italics="+this.italics+", background="+this.background+", flash="+this.flash},t}(),p=function(){function t(t,e,r,n,i,o){this.uchar=void 0,this.penState=void 0,this.uchar=t||" ",this.penState=new f(e,r,n,i,o)}var e=t.prototype;return e.reset=function(){this.uchar=" ",this.penState.reset()},e.setChar=function(t,e){this.uchar=t,this.penState.copy(e)},e.setPenState=function(t){this.penState.copy(t)},e.equals=function(t){return this.uchar===t.uchar&&this.penState.equals(t.penState)},e.copy=function(t){this.uchar=t.uchar,this.penState.copy(t.penState)},e.isEmpty=function(){return" "===this.uchar&&this.penState.isDefault()},t}(),g=function(){function t(t){this.chars=void 0,this.pos=void 0,this.currPenState=void 0,this.cueStartTime=void 0,this.logger=void 0,this.chars=[];for(var e=0;e<100;e++)this.chars.push(new p);this.logger=t,this.pos=0,this.currPenState=new f}var e=t.prototype;return e.equals=function(t){for(var e=!0,r=0;r<100;r++)if(!this.chars[r].equals(t.chars[r])){e=!1;break}return e},e.copy=function(t){for(var e=0;e<100;e++)this.chars[e].copy(t.chars[e])},e.isEmpty=function(){for(var t=!0,e=0;e<100;e++)if(!this.chars[e].isEmpty()){t=!1;break}return t},e.setCursor=function(t){this.pos!==t&&(this.pos=t),this.pos<0?(this.logger.log(n.DEBUG,"Negative cursor position "+this.pos),this.pos=0):this.pos>100&&(this.logger.log(n.DEBUG,"Too large cursor position "+this.pos),this.pos=100)},e.moveCursor=function(t){var e=this.pos+t;if(t>1)for(var r=this.pos+1;r<e+1;r++)this.chars[r].setPenState(this.currPenState);this.setCursor(e)},e.backSpace=function(){this.moveCursor(-1),this.chars[this.pos].setChar(" ",this.currPenState)},e.insertChar=function(t){t>=144&&this.backSpace();var e=a(t);this.pos>=100?this.logger.log(n.ERROR,"Cannot insert "+t.toString(16)+" ("+e+") at position "+this.pos+". Skipping it!"):(this.chars[this.pos].setChar(e,this.currPenState),this.moveCursor(1))},e.clearFromPos=function(t){var e;for(e=t;e<100;e++)this.chars[e].reset()},e.clear=function(){this.clearFromPos(0),this.pos=0,this.currPenState.reset()},e.clearToEndOfRow=function(){this.clearFromPos(this.pos)},e.getTextString=function(){for(var t=[],e=!0,r=0;r<100;r++){var n=this.chars[r].uchar;" "!==n&&(e=!1),t.push(n)}return e?"":t.join("")},e.setPenStyles=function(t){this.currPenState.setStyles(t),this.chars[this.pos].setPenState(this.currPenState)},t}(),m=function(){function t(t){this.rows=void 0,this.currRow=void 0,this.nrRollUpRows=void 0,this.lastOutputScreen=void 0,this.logger=void 0,this.rows=[];for(var e=0;e<15;e++)this.rows.push(new g(t));this.logger=t,this.currRow=14,this.nrRollUpRows=null,this.lastOutputScreen=null,this.reset()}var e=t.prototype;return e.reset=function(){for(var t=0;t<15;t++)this.rows[t].clear();this.currRow=14},e.equals=function(t){for(var e=!0,r=0;r<15;r++)if(!this.rows[r].equals(t.rows[r])){e=!1;break}return e},e.copy=function(t){for(var e=0;e<15;e++)this.rows[e].copy(t.rows[e])},e.isEmpty=function(){for(var t=!0,e=0;e<15;e++)if(!this.rows[e].isEmpty()){t=!1;break}return t},e.backSpace=function(){this.rows[this.currRow].backSpace()},e.clearToEndOfRow=function(){this.rows[this.currRow].clearToEndOfRow()},e.insertChar=function(t){this.rows[this.currRow].insertChar(t)},e.setPen=function(t){this.rows[this.currRow].setPenStyles(t)},e.moveCursor=function(t){this.rows[this.currRow].moveCursor(t)},e.setCursor=function(t){this.logger.log(n.INFO,"setCursor: "+t),this.rows[this.currRow].setCursor(t)},e.setPAC=function(t){this.logger.log(n.INFO,"pacData = "+JSON.stringify(t));var e=t.row-1;if(this.nrRollUpRows&&e<this.nrRollUpRows-1&&(e=this.nrRollUpRows-1),this.nrRollUpRows&&this.currRow!==e){for(var r=0;r<15;r++)this.rows[r].clear();var i=this.currRow+1-this.nrRollUpRows,o=this.lastOutputScreen;if(o){var a=o.rows[i].cueStartTime,s=this.logger.time;if(a&&null!==s&&a<s)for(var A=0;A<this.nrRollUpRows;A++)this.rows[e-this.nrRollUpRows+A+1].copy(o.rows[i+A])}}this.currRow=e;var l=this.rows[this.currRow];if(null!==t.indent){var c=t.indent,u=Math.max(c-1,0);l.setCursor(t.indent),t.color=l.chars[u].penState.foreground}var h={foreground:t.color,underline:t.underline,italics:t.italics,background:"black",flash:!1};this.setPen(h)},e.setBkgData=function(t){this.logger.log(n.INFO,"bkgData = "+JSON.stringify(t)),this.backSpace(),this.setPen(t),this.insertChar(32)},e.setRollUpRows=function(t){this.nrRollUpRows=t},e.rollUp=function(){if(null!==this.nrRollUpRows){this.logger.log(n.TEXT,this.getDisplayText());var t=this.currRow+1-this.nrRollUpRows,e=this.rows.splice(t,1)[0];e.clear(),this.rows.splice(this.currRow,0,e),this.logger.log(n.INFO,"Rolling up")}else this.logger.log(n.DEBUG,"roll_up but nrRollUpRows not set yet")},e.getDisplayText=function(t){t=t||!1;for(var e=[],r="",n=-1,i=0;i<15;i++){var o=this.rows[i].getTextString();o&&(n=i+1,t?e.push("Row "+n+": '"+o+"'"):e.push(o.trim()))}return e.length>0&&(r=t?"["+e.join(" | ")+"]":e.join("\n")),r},e.getTextAndFormat=function(){return this.rows},t}(),v=function(){function t(t,e,r){this.chNr=void 0,this.outputFilter=void 0,this.mode=void 0,this.verbose=void 0,this.displayedMemory=void 0,this.nonDisplayedMemory=void 0,this.lastOutputScreen=void 0,this.currRollUpRow=void 0,this.writeScreen=void 0,this.cueStartTime=void 0,this.logger=void 0,this.chNr=t,this.outputFilter=e,this.mode=null,this.verbose=0,this.displayedMemory=new m(r),this.nonDisplayedMemory=new m(r),this.lastOutputScreen=new m(r),this.currRollUpRow=this.displayedMemory.rows[14],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null,this.logger=r}var e=t.prototype;return e.reset=function(){this.mode=null,this.displayedMemory.reset(),this.nonDisplayedMemory.reset(),this.lastOutputScreen.reset(),this.outputFilter.reset(),this.currRollUpRow=this.displayedMemory.rows[14],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null},e.getHandler=function(){return this.outputFilter},e.setHandler=function(t){this.outputFilter=t},e.setPAC=function(t){this.writeScreen.setPAC(t)},e.setBkgData=function(t){this.writeScreen.setBkgData(t)},e.setMode=function(t){t!==this.mode&&(this.mode=t,this.logger.log(n.INFO,"MODE="+t),"MODE_POP-ON"===this.mode?this.writeScreen=this.nonDisplayedMemory:(this.writeScreen=this.displayedMemory,this.writeScreen.reset()),"MODE_ROLL-UP"!==this.mode&&(this.displayedMemory.nrRollUpRows=null,this.nonDisplayedMemory.nrRollUpRows=null),this.mode=t)},e.insertChars=function(t){for(var e=0;e<t.length;e++)this.writeScreen.insertChar(t[e]);var r=this.writeScreen===this.displayedMemory?"DISP":"NON_DISP";this.logger.log(n.INFO,r+": "+this.writeScreen.getDisplayText(!0)),"MODE_PAINT-ON"!==this.mode&&"MODE_ROLL-UP"!==this.mode||(this.logger.log(n.TEXT,"DISPLAYED: "+this.displayedMemory.getDisplayText(!0)),this.outputDataUpdate())},e.ccRCL=function(){this.logger.log(n.INFO,"RCL - Resume Caption Loading"),this.setMode("MODE_POP-ON")},e.ccBS=function(){this.logger.log(n.INFO,"BS - BackSpace"),"MODE_TEXT"!==this.mode&&(this.writeScreen.backSpace(),this.writeScreen===this.displayedMemory&&this.outputDataUpdate())},e.ccAOF=function(){},e.ccAON=function(){},e.ccDER=function(){this.logger.log(n.INFO,"DER- Delete to End of Row"),this.writeScreen.clearToEndOfRow(),this.outputDataUpdate()},e.ccRU=function(t){this.logger.log(n.INFO,"RU("+t+") - Roll Up"),this.writeScreen=this.displayedMemory,this.setMode("MODE_ROLL-UP"),this.writeScreen.setRollUpRows(t)},e.ccFON=function(){this.logger.log(n.INFO,"FON - Flash On"),this.writeScreen.setPen({flash:!0})},e.ccRDC=function(){this.logger.log(n.INFO,"RDC - Resume Direct Captioning"),this.setMode("MODE_PAINT-ON")},e.ccTR=function(){this.logger.log(n.INFO,"TR"),this.setMode("MODE_TEXT")},e.ccRTD=function(){this.logger.log(n.INFO,"RTD"),this.setMode("MODE_TEXT")},e.ccEDM=function(){this.logger.log(n.INFO,"EDM - Erase Displayed Memory"),this.displayedMemory.reset(),this.outputDataUpdate(!0)},e.ccCR=function(){this.logger.log(n.INFO,"CR - Carriage Return"),this.writeScreen.rollUp(),this.outputDataUpdate(!0)},e.ccENM=function(){this.logger.log(n.INFO,"ENM - Erase Non-displayed Memory"),this.nonDisplayedMemory.reset()},e.ccEOC=function(){if(this.logger.log(n.INFO,"EOC - End Of Caption"),"MODE_POP-ON"===this.mode){var t=this.displayedMemory;this.displayedMemory=this.nonDisplayedMemory,this.nonDisplayedMemory=t,this.writeScreen=this.nonDisplayedMemory,this.logger.log(n.TEXT,"DISP: "+this.displayedMemory.getDisplayText())}this.outputDataUpdate(!0)},e.ccTO=function(t){this.logger.log(n.INFO,"TO("+t+") - Tab Offset"),this.writeScreen.moveCursor(t)},e.ccMIDROW=function(t){var e={flash:!1};if(e.underline=t%2==1,e.italics=t>=46,e.italics)e.foreground="white";else{var r=Math.floor(t/2)-16;e.foreground=["white","green","blue","cyan","red","yellow","magenta"][r]}this.logger.log(n.INFO,"MIDROW: "+JSON.stringify(e)),this.writeScreen.setPen(e)},e.outputDataUpdate=function(t){void 0===t&&(t=!1);var e=this.logger.time;null!==e&&this.outputFilter&&(null!==this.cueStartTime||this.displayedMemory.isEmpty()?this.displayedMemory.equals(this.lastOutputScreen)||(this.outputFilter.newCue(this.cueStartTime,e,this.lastOutputScreen),t&&this.outputFilter.dispatchCue&&this.outputFilter.dispatchCue(),this.cueStartTime=this.displayedMemory.isEmpty()?null:e):this.cueStartTime=e,this.lastOutputScreen.copy(this.displayedMemory))},e.cueSplitAtTime=function(t){this.outputFilter&&(this.displayedMemory.isEmpty()||(this.outputFilter.newCue&&this.outputFilter.newCue(this.cueStartTime,t,this.displayedMemory),this.cueStartTime=t))},t}(),y=function(){function t(t,e,r){this.channels=void 0,this.currentChannel=0,this.cmdHistory=void 0,this.logger=void 0;var n=new h;this.channels=[null,new v(t,e,n),new v(t+1,r,n)],this.cmdHistory={a:null,b:null},this.logger=n}var e=t.prototype;return e.getHandler=function(t){return this.channels[t].getHandler()},e.setHandler=function(t,e){this.channels[t].setHandler(e)},e.addData=function(t,e){var r,i,o,a=!1;this.logger.time=t;for(var s=0;s<e.length;s+=2)if(i=127&e[s],o=127&e[s+1],0!==i||0!==o){if(this.logger.log(n.DATA,"["+d([e[s],e[s+1]])+"] -> ("+d([i,o])+")"),(r=this.parseCmd(i,o))||(r=this.parseMidrow(i,o)),r||(r=this.parsePAC(i,o)),r||(r=this.parseBackgroundAttributes(i,o)),!r&&(a=this.parseChars(i,o))){var A=this.currentChannel;A&&A>0?this.channels[A].insertChars(a):this.logger.log(n.WARNING,"No channel found yet. TEXT-MODE?")}r||a||this.logger.log(n.WARNING,"Couldn't parse cleaned data "+d([i,o])+" orig: "+d([e[s],e[s+1]]))}},e.parseCmd=function(t,e){var r=this.cmdHistory;if(!((20===t||28===t||21===t||29===t)&&e>=32&&e<=47||(23===t||31===t)&&e>=33&&e<=35))return!1;if(b(t,e,r))return w(null,null,r),this.logger.log(n.DEBUG,"Repeated command ("+d([t,e])+") is dropped"),!0;var i=20===t||21===t||23===t?1:2,o=this.channels[i];return 20===t||21===t||28===t||29===t?32===e?o.ccRCL():33===e?o.ccBS():34===e?o.ccAOF():35===e?o.ccAON():36===e?o.ccDER():37===e?o.ccRU(2):38===e?o.ccRU(3):39===e?o.ccRU(4):40===e?o.ccFON():41===e?o.ccRDC():42===e?o.ccTR():43===e?o.ccRTD():44===e?o.ccEDM():45===e?o.ccCR():46===e?o.ccENM():47===e&&o.ccEOC():o.ccTO(e-32),w(t,e,r),this.currentChannel=i,!0},e.parseMidrow=function(t,e){var r=0;if((17===t||25===t)&&e>=32&&e<=47){if((r=17===t?1:2)!==this.currentChannel)return this.logger.log(n.ERROR,"Mismatch channel in midrow parsing"),!1;var i=this.channels[r];return!!i&&(i.ccMIDROW(e),this.logger.log(n.DEBUG,"MIDROW ("+d([t,e])+")"),!0)}return!1},e.parsePAC=function(t,e){var r,n=this.cmdHistory;if(!((t>=17&&t<=23||t>=25&&t<=31)&&e>=64&&e<=127||(16===t||24===t)&&e>=64&&e<=95))return!1;if(b(t,e,n))return w(null,null,n),!0;var i=t<=23?1:2;r=e>=64&&e<=95?1===i?s[t]:l[t]:1===i?A[t]:c[t];var o=this.channels[i];return!!o&&(o.setPAC(this.interpretPAC(r,e)),w(t,e,n),this.currentChannel=i,!0)},e.interpretPAC=function(t,e){var r,n={color:null,italics:!1,indent:null,underline:!1,row:t};return r=e>95?e-96:e-64,n.underline=1==(1&r),r<=13?n.color=["white","green","blue","cyan","red","yellow","magenta","white"][Math.floor(r/2)]:r<=15?(n.italics=!0,n.color="white"):n.indent=4*Math.floor((r-16)/2),n},e.parseChars=function(t,e){var r,i,o=null,s=null;if(t>=25?(r=2,s=t-8):(r=1,s=t),s>=17&&s<=19?(i=17===s?e+80:18===s?e+112:e+144,this.logger.log(n.INFO,"Special char '"+a(i)+"' in channel "+r),o=[i]):t>=32&&t<=127&&(o=0===e?[t]:[t,e]),o){var A=d(o);this.logger.log(n.DEBUG,"Char codes = "+A.join(",")),w(t,e,this.cmdHistory)}return o},e.parseBackgroundAttributes=function(t,e){var r;if(!((16===t||24===t)&&e>=32&&e<=47||(23===t||31===t)&&e>=45&&e<=47))return!1;var n={};16===t||24===t?(r=Math.floor((e-32)/2),n.background=u[r],e%2==1&&(n.background=n.background+"_semi")):45===e?n.background="transparent":(n.foreground="black",47===e&&(n.underline=!0));var i=t<=23?1:2;return this.channels[i].setBkgData(n),w(t,e,this.cmdHistory),!0},e.reset=function(){for(var t=0;t<Object.keys(this.channels).length;t++){var e=this.channels[t];e&&e.reset()}this.cmdHistory={a:null,b:null}},e.cueSplitAtTime=function(t){for(var e=0;e<this.channels.length;e++){var r=this.channels[e];r&&r.cueSplitAtTime(t)}},t}();function w(t,e,r){r.a=t,r.b=e}function b(t,e,r){return r.a===t&&r.b===e}e.default=y},"./src/utils/codecs.ts":
|
|
|
/*!*****************************!*\
|
|
|
!*** ./src/utils/codecs.ts ***!
|
|
|
\*****************************/
|
|
|
/*! exports provided: isCodecType, isCodecSupportedInMp4 */function(t,e,r){"use strict";r.r(e),r.d(e,"isCodecType",(function(){return i})),r.d(e,"isCodecSupportedInMp4",(function(){return o}));var n={audio:{a3ds:!0,"ac-3":!0,"ac-4":!0,alac:!0,alaw:!0,dra1:!0,"dts+":!0,"dts-":!0,dtsc:!0,dtse:!0,dtsh:!0,"ec-3":!0,enca:!0,g719:!0,g726:!0,m4ae:!0,mha1:!0,mha2:!0,mhm1:!0,mhm2:!0,mlpa:!0,mp4a:!0,"raw ":!0,Opus:!0,samr:!0,sawb:!0,sawp:!0,sevc:!0,sqcp:!0,ssmv:!0,twos:!0,ulaw:!0},video:{avc1:!0,avc2:!0,avc3:!0,avc4:!0,avcp:!0,av01:!0,drac:!0,dvav:!0,dvhe:!0,encv:!0,hev1:!0,hvc1:!0,mjp2:!0,mp4v:!0,mvc1:!0,mvc2:!0,mvc3:!0,mvc4:!0,resv:!0,rv60:!0,s263:!0,svc1:!0,svc2:!0,"vc-1":!0,vp08:!0,vp09:!0},text:{stpp:!0,wvtt:!0}};function i(t,e){var r=n[e];return!!r&&!0===r[t.slice(0,4)]}function o(t,e){return MediaSource.isTypeSupported((e||"video")+'/mp4;codecs="'+t+'"')}},"./src/utils/cues.ts":
|
|
|
/*!***************************!*\
|
|
|
!*** ./src/utils/cues.ts ***!
|
|
|
\***************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ./vttparser */"./src/utils/vttparser.ts"),i=r(/*! ./webvtt-parser */"./src/utils/webvtt-parser.ts"),o=r(/*! ./texttrack-utils */"./src/utils/texttrack-utils.ts"),a=/\s/,s={newCue:function(t,e,r,s){for(var A,l,c,u,h,d=[],f=self.VTTCue||self.TextTrackCue,p=0;p<s.rows.length;p++)if(c=!0,u=0,h="",!(A=s.rows[p]).isEmpty()){for(var g=0;g<A.chars.length;g++)a.test(A.chars[g].uchar)&&c?u++:(h+=A.chars[g].uchar,c=!1);A.cueStartTime=e,e===r&&(r+=1e-4),u>=16?u--:u++;var m=Object(n.fixLineBreaks)(h.trim()),v=Object(i.generateCueId)(e,r,m);t&&t.cues&&t.cues.getCueById(v)||((l=new f(e,r,m)).id=v,l.line=p+1,l.align="left",l.position=10+Math.min(80,10*Math.floor(8*u/32)),d.push(l))}return t&&d.length&&(d.sort((function(t,e){return"auto"===t.line||"auto"===e.line?0:t.line>8&&e.line>8?e.line-t.line:t.line-e.line})),d.forEach((function(e){return Object(o.addCueToTrack)(t,e)}))),d}};e.default=s},"./src/utils/discontinuities.ts":
|
|
|
/*!**************************************!*\
|
|
|
!*** ./src/utils/discontinuities.ts ***!
|
|
|
\**************************************/
|
|
|
/*! exports provided: findFirstFragWithCC, shouldAlignOnDiscontinuities, findDiscontinuousReferenceFrag, adjustSlidingStart, alignStream, alignPDT, alignFragmentByPDTDelta, alignMediaPlaylistByPDT */function(t,e,r){"use strict";r.r(e),r.d(e,"findFirstFragWithCC",(function(){return a})),r.d(e,"shouldAlignOnDiscontinuities",(function(){return s})),r.d(e,"findDiscontinuousReferenceFrag",(function(){return A})),r.d(e,"adjustSlidingStart",(function(){return c})),r.d(e,"alignStream",(function(){return u})),r.d(e,"alignPDT",(function(){return h})),r.d(e,"alignFragmentByPDTDelta",(function(){return d})),r.d(e,"alignMediaPlaylistByPDT",(function(){return f}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ./logger */"./src/utils/logger.ts"),o=r(/*! ../controller/level-helper */"./src/controller/level-helper.ts");function a(t,e){for(var r=null,n=0,i=t.length;n<i;n++){var o=t[n];if(o&&o.cc===e){r=o;break}}return r}function s(t,e,r){return!(!e.details||!(r.endCC>r.startCC||t&&t.cc<r.startCC))}function A(t,e){var r=t.fragments,n=e.fragments;if(n.length&&r.length){var o=a(r,n[0].cc);if(o&&(!o||o.startPTS))return o;i.logger.log("No frag in previous level to align on")}else i.logger.log("No fragments to align")}function l(t,e){if(t){var r=t.start+e;t.start=t.startPTS=r,t.endPTS=r+t.duration}}function c(t,e){for(var r=e.fragments,n=0,i=r.length;n<i;n++)l(r[n],t);e.fragmentHint&&l(e.fragmentHint,t),e.alignedSliding=!0}function u(t,e,r){e&&(function(t,e,r){if(s(t,r,e)){var o=A(r.details,e);o&&Object(n.isFiniteNumber)(o.start)&&(i.logger.log("Adjusting PTS using last level due to CC increase within current level "+e.url),c(o.start,e))}}(t,r,e),!r.alignedSliding&&e.details&&h(r,e.details),r.alignedSliding||!e.details||r.skippedSegments||Object(o.adjustSliding)(e.details,r))}function h(t,e){if(e.fragments.length&&t.hasProgramDateTime&&e.hasProgramDateTime){var r=e.fragments[0].programDateTime,o=t.fragments[0].programDateTime,a=(o-r)/1e3+e.fragments[0].start;a&&Object(n.isFiniteNumber)(a)&&(i.logger.log("Adjusting PTS using programDateTime delta "+(o-r)+"ms, sliding:"+a.toFixed(3)+" "+t.url+" "),c(a,t))}}function d(t,e){var r=t.programDateTime;if(r){var n=(r-e)/1e3;t.start=t.startPTS=n,t.endPTS=n+t.duration}}function f(t,e){if(e.fragments.length&&t.hasProgramDateTime&&e.hasProgramDateTime){var r=e.fragments[0].programDateTime-1e3*e.fragments[0].start;t.fragments.forEach((function(t){d(t,r)})),t.fragmentHint&&d(t.fragmentHint,r),t.alignedSliding=!0}}},"./src/utils/ewma-bandwidth-estimator.ts":
|
|
|
/*!***********************************************!*\
|
|
|
!*** ./src/utils/ewma-bandwidth-estimator.ts ***!
|
|
|
\***********************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../utils/ewma */"./src/utils/ewma.ts"),i=function(){function t(t,e,r){this.defaultEstimate_=void 0,this.minWeight_=void 0,this.minDelayMs_=void 0,this.slow_=void 0,this.fast_=void 0,this.defaultEstimate_=r,this.minWeight_=.001,this.minDelayMs_=50,this.slow_=new n.default(t),this.fast_=new n.default(e)}var e=t.prototype;return e.update=function(t,e){var r=this.slow_,i=this.fast_;this.slow_.halfLife!==t&&(this.slow_=new n.default(t,r.getEstimate(),r.getTotalWeight())),this.fast_.halfLife!==e&&(this.fast_=new n.default(e,i.getEstimate(),i.getTotalWeight()))},e.sample=function(t,e){var r=(t=Math.max(t,this.minDelayMs_))/1e3,n=8*e/r;this.fast_.sample(r,n),this.slow_.sample(r,n)},e.canEstimate=function(){var t=this.fast_;return t&&t.getTotalWeight()>=this.minWeight_},e.getEstimate=function(){return this.canEstimate()?Math.min(this.fast_.getEstimate(),this.slow_.getEstimate()):this.defaultEstimate_},e.destroy=function(){},t}();e.default=i},"./src/utils/ewma.ts":
|
|
|
/*!***************************!*\
|
|
|
!*** ./src/utils/ewma.ts ***!
|
|
|
\***************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=function(){function t(t,e,r){void 0===e&&(e=0),void 0===r&&(r=0),this.halfLife=void 0,this.alpha_=void 0,this.estimate_=void 0,this.totalWeight_=void 0,this.halfLife=t,this.alpha_=t?Math.exp(Math.log(.5)/t):0,this.estimate_=e,this.totalWeight_=r}var e=t.prototype;return e.sample=function(t,e){var r=Math.pow(this.alpha_,t);this.estimate_=e*(1-r)+r*this.estimate_,this.totalWeight_+=t},e.getTotalWeight=function(){return this.totalWeight_},e.getEstimate=function(){if(this.alpha_){var t=1-Math.pow(this.alpha_,this.totalWeight_);if(t)return this.estimate_/t}return this.estimate_},t}();e.default=n},"./src/utils/fetch-loader.ts":
|
|
|
/*!***********************************!*\
|
|
|
!*** ./src/utils/fetch-loader.ts ***!
|
|
|
\***********************************/
|
|
|
/*! exports provided: fetchSupported, default */function(t,e,r){"use strict";r.r(e),r.d(e,"fetchSupported",(function(){return h}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ../loader/load-stats */"./src/loader/load-stats.ts"),o=r(/*! ../demux/chunk-cache */"./src/demux/chunk-cache.ts");function a(t){var e="function"==typeof Map?new Map:void 0;return(a=function(t){if(null===t||(r=t,-1===Function.toString.call(r).indexOf("[native code]")))return t;var r;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==e){if(e.has(t))return e.get(t);e.set(t,n)}function n(){return s(t,arguments,c(this).constructor)}return n.prototype=Object.create(t.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),l(n,t)})(t)}function s(t,e,r){return(s=A()?Reflect.construct:function(t,e,r){var n=[null];n.push.apply(n,e);var i=new(Function.bind.apply(t,n));return r&&l(i,r.prototype),i}).apply(null,arguments)}function A(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function l(t,e){return(l=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function c(t){return(c=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function u(){return(u=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}function h(){if(self.fetch&&self.AbortController&&self.ReadableStream&&self.Request)try{return new self.ReadableStream({}),!0}catch(t){}return!1}var d=function(){function t(t){this.fetchSetup=void 0,this.requestTimeout=void 0,this.request=void 0,this.response=void 0,this.controller=void 0,this.context=void 0,this.config=null,this.callbacks=null,this.stats=void 0,this.loader=null,this.fetchSetup=t.fetchSetup||f,this.controller=new self.AbortController,this.stats=new i.LoadStats}var e=t.prototype;return e.destroy=function(){this.loader=this.callbacks=null,this.abortInternal()},e.abortInternal=function(){var t=this.response;t&&t.ok||(this.stats.aborted=!0,this.controller.abort())},e.abort=function(){var t;this.abortInternal(),null!==(t=this.callbacks)&&void 0!==t&&t.onAbort&&this.callbacks.onAbort(this.stats,this.context,this.response)},e.load=function(t,e,r){var i=this,o=this.stats;if(o.loading.start)throw new Error("Loader can only be used once.");o.loading.start=self.performance.now();var a=function(t,e){var r={method:"GET",mode:"cors",credentials:"same-origin",signal:e,headers:new self.Headers(u({},t.headers))};return t.rangeEnd&&r.headers.set("Range","bytes="+t.rangeStart+"-"+String(t.rangeEnd-1)),r}(t,this.controller.signal),s=r.onProgress,A="arraybuffer"===t.responseType,l=A?"byteLength":"length";this.context=t,this.config=e,this.callbacks=r,this.request=this.fetchSetup(t,a),self.clearTimeout(this.requestTimeout),this.requestTimeout=self.setTimeout((function(){i.abortInternal(),r.onTimeout(o,t,i.response)}),e.timeout),self.fetch(this.request).then((function(r){if(i.response=i.loader=r,!r.ok){var a=r.status,l=r.statusText;throw new p(l||"fetch, bad network response",a,r)}return o.loading.first=Math.max(self.performance.now(),o.loading.start),o.total=parseInt(r.headers.get("Content-Length")||"0"),s&&Object(n.isFiniteNumber)(e.highWaterMark)?i.loadProgressively(r,o,t,e.highWaterMark,s):A?r.arrayBuffer():r.text()})).then((function(a){var A=i.response;self.clearTimeout(i.requestTimeout),o.loading.end=Math.max(self.performance.now(),o.loading.first),o.loaded=o.total=a[l];var c={url:A.url,data:a};s&&!Object(n.isFiniteNumber)(e.highWaterMark)&&s(o,t,a,A),r.onSuccess(c,o,t,A)})).catch((function(e){if(self.clearTimeout(i.requestTimeout),!o.aborted){var n=e.code||0;r.onError({code:n,text:e.message},t,e.details)}}))},e.getCacheAge=function(){var t=null;if(this.response){var e=this.response.headers.get("age");t=e?parseFloat(e):null}return t},e.loadProgressively=function(t,e,r,n,i){void 0===n&&(n=0);var a=new o.default,s=t.body.getReader();return function o(){return s.read().then((function(s){if(s.done)return a.dataLength&&i(e,r,a.flush(),t),Promise.resolve(new ArrayBuffer(0));var A=s.value,l=A.length;return e.loaded+=l,l<n||a.dataLength?(a.push(A),a.dataLength>=n&&i(e,r,a.flush(),t)):i(e,r,A,t),o()})).catch((function(){return Promise.reject()}))}()},t}();function f(t,e){return new self.Request(t.url,e)}var p=function(t){var e,r;function n(e,r,n){var i;return(i=t.call(this,e)||this).code=void 0,i.details=void 0,i.code=r,i.details=n,i}return r=t,(e=n).prototype=Object.create(r.prototype),e.prototype.constructor=e,l(e,r),n}(a(Error));e.default=d},"./src/utils/imsc1-ttml-parser.ts":
|
|
|
/*!****************************************!*\
|
|
|
!*** ./src/utils/imsc1-ttml-parser.ts ***!
|
|
|
\****************************************/
|
|
|
/*! exports provided: IMSC1_CODEC, parseIMSC1 */function(t,e,r){"use strict";r.r(e),r.d(e,"IMSC1_CODEC",(function(){return c})),r.d(e,"parseIMSC1",(function(){return f}));var n=r(/*! ./mp4-tools */"./src/utils/mp4-tools.ts"),i=r(/*! ./vttparser */"./src/utils/vttparser.ts"),o=r(/*! ./vttcue */"./src/utils/vttcue.ts"),a=r(/*! ../demux/id3 */"./src/demux/id3.ts"),s=r(/*! ./timescale-conversion */"./src/utils/timescale-conversion.ts"),A=r(/*! ./webvtt-parser */"./src/utils/webvtt-parser.ts");function l(){return(l=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}var c="stpp.ttml.im1t",u=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,h=/^(\d*(?:\.\d*)?)(h|m|s|ms|f|t)$/,d={left:"start",center:"center",right:"end",start:"start",end:"end"};function f(t,e,r,i,c){var u=Object(n.findBox)(new Uint8Array(t),["mdat"]);if(0!==u.length){var h=u[0],f=Object(a.utf8ArrayToStr)(new Uint8Array(t,h.start,h.end-h.start)),w=Object(s.toTimescaleFromScale)(e,1,r);try{i(function(t,e){var r=(new DOMParser).parseFromString(t,"text/xml").getElementsByTagName("tt")[0];if(!r)throw new Error("Invalid ttml");var n={frameRate:30,subFrameRate:1,frameRateMultiplier:0,tickRate:0},i=Object.keys(n).reduce((function(t,e){return t[e]=r.getAttribute("ttp:"+e)||n[e],t}),{}),a="preserve"!==r.getAttribute("xml:space"),s=g(p(r,"styling","style")),c=g(p(r,"layout","region")),u=p(r,"body","[begin]");return[].map.call(u,(function(t){var r=function t(e,r){return[].slice.call(e.childNodes).reduce((function(e,n,i){var o;return"br"===n.nodeName&&i?e+"\n":null!==(o=n.childNodes)&&void 0!==o&&o.length?t(n,r):r?e+n.textContent.trim().replace(/\s+/g," "):e+n.textContent}),"")}(t,a);if(!r||!t.hasAttribute("begin"))return null;var n=y(t.getAttribute("begin"),i),u=y(t.getAttribute("dur"),i),h=y(t.getAttribute("end"),i);if(null===n)throw v(t);if(null===h){if(null===u)throw v(t);h=n+u}var f=new o.default(n-e,h-e,r);f.id=Object(A.generateCueId)(f.startTime,f.endTime,f.text);var p=c[t.getAttribute("region")],g=s[t.getAttribute("style")];f.position=10,f.size=80;var w=function(t,e){var r="http://www.w3.org/ns/ttml#styling";return["displayAlign","textAlign","color","backgroundColor","fontSize","fontFamily"].reduce((function(n,i){var o=m(e,r,i)||m(t,r,i);return o&&(n[i]=o),n}),{})}(p,g),b=w.textAlign;if(b){var C=d[b];C&&(f.lineAlign=C),f.align=b}return l(f,w),f})).filter((function(t){return null!==t}))}(f,w))}catch(t){c(t)}}else c(new Error("Could not parse IMSC1 mdat"))}function p(t,e,r){var n=t.getElementsByTagName(e)[0];return n?[].slice.call(n.querySelectorAll(r)):[]}function g(t){return t.reduce((function(t,e){var r=e.getAttribute("xml:id");return r&&(t[r]=e),t}),{})}function m(t,e,r){return t.hasAttributeNS(e,r)?t.getAttributeNS(e,r):null}function v(t){return new Error("Could not parse ttml timestamp "+t)}function y(t,e){if(!t)return null;var r=Object(i.parseTimeStamp)(t);return null===r&&(u.test(t)?r=function(t,e){var r=u.exec(t),n=(0|r[4])+(0|r[5])/e.subFrameRate;return 3600*(0|r[1])+60*(0|r[2])+(0|r[3])+n/e.frameRate}(t,e):h.test(t)&&(r=function(t,e){var r=h.exec(t),n=Number(r[1]);switch(r[2]){case"h":return 3600*n;case"m":return 60*n;case"ms":return 1e3*n;case"f":return n/e.frameRate;case"t":return n/e.tickRate}return n}(t,e))),r}},"./src/utils/logger.ts":
|
|
|
/*!*****************************!*\
|
|
|
!*** ./src/utils/logger.ts ***!
|
|
|
\*****************************/
|
|
|
/*! exports provided: enableLogs, logger */function(t,e,r){"use strict";r.r(e),r.d(e,"enableLogs",(function(){return s})),r.d(e,"logger",(function(){return A}));var n=function(){},i={trace:n,debug:n,log:n,warn:n,info:n,error:n},o=i;function a(t){var e=self.console[t];return e?e.bind(self.console,"["+t+"] >"):n}function s(t){if(self.console&&!0===t||"object"==typeof t){!function(t){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];r.forEach((function(e){o[e]=t[e]?t[e].bind(t):a(e)}))}(t,"debug","log","info","warn","error");try{o.log()}catch(t){o=i}}else o=i}var A=i},"./src/utils/mediakeys-helper.ts":
|
|
|
/*!***************************************!*\
|
|
|
!*** ./src/utils/mediakeys-helper.ts ***!
|
|
|
\***************************************/
|
|
|
/*! exports provided: KeySystems, requestMediaKeySystemAccess */function(t,e,r){"use strict";var n;r.r(e),r.d(e,"KeySystems",(function(){return n})),r.d(e,"requestMediaKeySystemAccess",(function(){return i})),function(t){t.WIDEVINE="com.widevine.alpha",t.PLAYREADY="com.microsoft.playready"}(n||(n={}));var i="undefined"!=typeof self&&self.navigator&&self.navigator.requestMediaKeySystemAccess?self.navigator.requestMediaKeySystemAccess.bind(self.navigator):null},"./src/utils/mediasource-helper.ts":
|
|
|
/*!*****************************************!*\
|
|
|
!*** ./src/utils/mediasource-helper.ts ***!
|
|
|
\*****************************************/
|
|
|
/*! exports provided: getMediaSource */function(t,e,r){"use strict";function n(){return self.MediaSource||self.WebKitMediaSource}r.r(e),r.d(e,"getMediaSource",(function(){return n}))},"./src/utils/mp4-tools.ts":
|
|
|
/*!********************************!*\
|
|
|
!*** ./src/utils/mp4-tools.ts ***!
|
|
|
\********************************/
|
|
|
/*! exports provided: bin2str, readUint16, readUint32, writeUint32, findBox, parseSegmentIndex, parseInitSegment, getStartDTS, getDuration, computeRawDurationFromSamples, offsetStartDTS, segmentValidRange, appendUint8Array */function(t,e,r){"use strict";r.r(e),r.d(e,"bin2str",(function(){return s})),r.d(e,"readUint16",(function(){return A})),r.d(e,"readUint32",(function(){return l})),r.d(e,"writeUint32",(function(){return c})),r.d(e,"findBox",(function(){return u})),r.d(e,"parseSegmentIndex",(function(){return h})),r.d(e,"parseInitSegment",(function(){return d})),r.d(e,"getStartDTS",(function(){return f})),r.d(e,"getDuration",(function(){return p})),r.d(e,"computeRawDurationFromSamples",(function(){return g})),r.d(e,"offsetStartDTS",(function(){return m})),r.d(e,"segmentValidRange",(function(){return v})),r.d(e,"appendUint8Array",(function(){return y}));var n=r(/*! ./typed-array */"./src/utils/typed-array.ts"),i=r(/*! ../loader/fragment */"./src/loader/fragment.ts"),o=Math.pow(2,32)-1,a=[].push;function s(t){return String.fromCharCode.apply(null,t)}function A(t,e){"data"in t&&(e+=t.start,t=t.data);var r=t[e]<<8|t[e+1];return r<0?65536+r:r}function l(t,e){"data"in t&&(e+=t.start,t=t.data);var r=t[e]<<24|t[e+1]<<16|t[e+2]<<8|t[e+3];return r<0?4294967296+r:r}function c(t,e,r){"data"in t&&(e+=t.start,t=t.data),t[e]=r>>24,t[e+1]=r>>16&255,t[e+2]=r>>8&255,t[e+3]=255&r}function u(t,e){var r,n,i,o=[];if(!e.length)return o;"data"in t?(r=t.data,n=t.start,i=t.end):(n=0,i=(r=t).byteLength);for(var A=n;A<i;){var c=l(r,A),h=c>1?A+c:i;if(s(r.subarray(A+4,A+8))===e[0])if(1===e.length)o.push({data:r,start:A+8,end:h});else{var d=u({data:r,start:A+8,end:h},e.slice(1));d.length&&a.apply(o,d)}A=h}return o}function h(t){var e=u(t,["moov"])[0],r=e?e.end:null,n=u(t,["sidx"]);if(!n||!n[0])return null;var i=[],o=n[0],a=o.data[0],s=0===a?8:16,c=l(o,s);s+=4,s+=0===a?8:16,s+=2;var h=o.end+0,d=A(o,s);s+=2;for(var f=0;f<d;f++){var p=s,g=l(o,p);p+=4;var m=2147483647&g;if(1==(2147483648&g)>>>31)return console.warn("SIDX has hierarchical references (not supported)"),null;var v=l(o,p);p+=4,i.push({referenceSize:m,subsegmentDuration:v,info:{duration:v/c,start:h,end:h+m-1}}),h+=m,s=p+=4}return{earliestPresentationTime:0,timescale:c,version:a,referencesCount:d,references:i,moovEndOffset:r}}function d(t){for(var e=[],r=u(t,["moov","trak"]),n=0;n<r.length;n++){var o=r[n],a=u(o,["tkhd"])[0];if(a){var A=a.data[a.start],c=0===A?12:20,h=l(a,c),d=u(o,["mdia","mdhd"])[0];if(d){var f=l(d,c=0===(A=d.data[d.start])?12:20),p=u(o,["mdia","hdlr"])[0];if(p){var g=s(p.data.subarray(p.start+8,p.start+12)),m={soun:i.ElementaryStreamTypes.AUDIO,vide:i.ElementaryStreamTypes.VIDEO}[g];if(m){var v=u(o,["mdia","minf","stbl","stsd"])[0],y=void 0;v&&(y=s(v.data.subarray(v.start+12,v.start+16))),e[h]={timescale:f,type:m},e[m]={timescale:f,id:h,codec:y}}}}}}return u(t,["moov","mvex","trex"]).forEach((function(t){var r=l(t,4),n=e[r];n&&(n.default={duration:l(t,12),flags:l(t,20)})})),e}function f(t,e){return u(e,["moof","traf"]).reduce((function(e,r){var n=u(r,["tfdt"])[0],i=n.data[n.start],o=u(r,["tfhd"]).reduce((function(e,r){var o=l(r,4),a=t[o];if(a){var s=l(n,4);1===i&&(s*=Math.pow(2,32),s+=l(n,8));var A=s/(a.timescale||9e4);if(isFinite(A)&&(null===e||A<e))return A}return e}),null);return null!==o&&isFinite(o)&&(null===e||o<e)?o:e}),null)||0}function p(t,e){for(var r=0,n=0,o=0,a=u(t,["moof","traf"]),s=0;s<a.length;s++){var A=a[s],c=u(A,["tfhd"])[0],d=e[l(c,4)];if(d){var f=d.default,p=l(c,0)|(null==f?void 0:f.flags),m=null==f?void 0:f.duration;8&p&&(m=l(c,2&p?12:8));for(var v=d.timescale||9e4,y=u(A,["trun"]),w=0;w<y.length;w++)r=m?m*l(y[w],4):g(y[w]),d.type===i.ElementaryStreamTypes.VIDEO?n+=r/v:d.type===i.ElementaryStreamTypes.AUDIO&&(o+=r/v)}}if(0===n&&0===o){var b=h(t);if(null!=b&&b.references)return b.references.reduce((function(t,e){return t+e.info.duration||0}),0)}return n||o}function g(t){var e=l(t,0),r=8;1&e&&(r+=4),4&e&&(r+=4);for(var n=0,i=l(t,4),o=0;o<i;o++)256&e&&(n+=l(t,r),r+=4),512&e&&(r+=4),1024&e&&(r+=4),2048&e&&(r+=4);return n}function m(t,e,r){u(e,["moof","traf"]).forEach((function(e){u(e,["tfhd"]).forEach((function(n){var i=l(n,4),a=t[i];if(a){var s=a.timescale||9e4;u(e,["tfdt"]).forEach((function(t){var e=t.data[t.start],n=l(t,4);if(0===e)c(t,4,n-r*s);else{n*=Math.pow(2,32),n+=l(t,8),n-=r*s,n=Math.max(n,0);var i=Math.floor(n/(o+1)),a=Math.floor(n%(o+1));c(t,4,i),c(t,8,a)}}))}}))}))}function v(t){var e={valid:null,remainder:null},r=u(t,["moof"]);if(!r)return e;if(r.length<2)return e.remainder=t,e;var i=r[r.length-1];return e.valid=Object(n.sliceUint8)(t,0,i.start-8),e.remainder=Object(n.sliceUint8)(t,i.start-8),e}function y(t,e){var r=new Uint8Array(t.length+e.length);return r.set(t),r.set(e,t.length),r}},"./src/utils/output-filter.ts":
|
|
|
/*!************************************!*\
|
|
|
!*** ./src/utils/output-filter.ts ***!
|
|
|
\************************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),r.d(e,"default",(function(){return n}));var n=function(){function t(t,e){this.timelineController=void 0,this.cueRanges=[],this.trackName=void 0,this.startTime=null,this.endTime=null,this.screen=null,this.timelineController=t,this.trackName=e}var e=t.prototype;return e.dispatchCue=function(){null!==this.startTime&&(this.timelineController.addCues(this.trackName,this.startTime,this.endTime,this.screen,this.cueRanges),this.startTime=null)},e.newCue=function(t,e,r){(null===this.startTime||this.startTime>t)&&(this.startTime=t),this.endTime=e,this.screen=r,this.timelineController.createCaptionsTrack(this.trackName)},e.reset=function(){this.cueRanges=[]},t}()},"./src/utils/texttrack-utils.ts":
|
|
|
/*!**************************************!*\
|
|
|
!*** ./src/utils/texttrack-utils.ts ***!
|
|
|
\**************************************/
|
|
|
/*! exports provided: sendAddTrackEvent, addCueToTrack, clearCurrentCues, removeCuesInRange, getCuesInRange */function(t,e,r){"use strict";r.r(e),r.d(e,"sendAddTrackEvent",(function(){return i})),r.d(e,"addCueToTrack",(function(){return o})),r.d(e,"clearCurrentCues",(function(){return a})),r.d(e,"removeCuesInRange",(function(){return s})),r.d(e,"getCuesInRange",(function(){return A}));var n=r(/*! ./logger */"./src/utils/logger.ts");function i(t,e){var r;try{r=new Event("addtrack")}catch(t){(r=document.createEvent("Event")).initEvent("addtrack",!1,!1)}r.track=t,e.dispatchEvent(r)}function o(t,e){var r=t.mode;if("disabled"===r&&(t.mode="hidden"),t.cues&&!t.cues.getCueById(e.id))try{if(t.addCue(e),!t.cues.getCueById(e.id))throw new Error("addCue is failed for: "+e)}catch(r){n.logger.debug("[texttrack-utils]: "+r);var i=new self.TextTrackCue(e.startTime,e.endTime,e.text);i.id=e.id,t.addCue(i)}"disabled"===r&&(t.mode=r)}function a(t){var e=t.mode;if("disabled"===e&&(t.mode="hidden"),t.cues)for(var r=t.cues.length;r--;)t.removeCue(t.cues[r]);"disabled"===e&&(t.mode=e)}function s(t,e,r){var n=t.mode;if("disabled"===n&&(t.mode="hidden"),t.cues&&t.cues.length>0)for(var i=A(t.cues,e,r),o=0;o<i.length;o++)t.removeCue(i[o]);"disabled"===n&&(t.mode=n)}function A(t,e,r){var n=[],i=function(t,e){if(e<t[0].startTime)return 0;var r=t.length-1;if(e>t[r].endTime)return-1;for(var n=0,i=r;n<=i;){var o=Math.floor((i+n)/2);if(e<t[o].startTime)i=o-1;else{if(!(e>t[o].startTime&&n<r))return o;n=o+1}}return t[n].startTime-e<e-t[i].startTime?n:i}(t,e);if(i>-1)for(var o=i,a=t.length;o<a;o++){var s=t[o];if(s.startTime>=e&&s.endTime<=r)n.push(s);else if(s.startTime>r)return n}return n}},"./src/utils/time-ranges.ts":
|
|
|
/*!**********************************!*\
|
|
|
!*** ./src/utils/time-ranges.ts ***!
|
|
|
\**********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),e.default={toString:function(t){for(var e="",r=t.length,n=0;n<r;n++)e+="["+t.start(n).toFixed(3)+","+t.end(n).toFixed(3)+"]";return e}}},"./src/utils/timescale-conversion.ts":
|
|
|
/*!*******************************************!*\
|
|
|
!*** ./src/utils/timescale-conversion.ts ***!
|
|
|
\*******************************************/
|
|
|
/*! exports provided: toTimescaleFromBase, toTimescaleFromScale, toMsFromMpegTsClock, toMpegTsClockFromTimescale */function(t,e,r){"use strict";function n(t,e,r,n){void 0===r&&(r=1),void 0===n&&(n=!1);var i=t*e*r;return n?Math.round(i):i}function i(t,e,r,i){return void 0===r&&(r=1),void 0===i&&(i=!1),n(t,e,1/r,i)}function o(t,e){return void 0===e&&(e=!1),n(t,1e3,1/9e4,e)}function a(t,e){return void 0===e&&(e=1),n(t,9e4,1/e)}r.r(e),r.d(e,"toTimescaleFromBase",(function(){return n})),r.d(e,"toTimescaleFromScale",(function(){return i})),r.d(e,"toMsFromMpegTsClock",(function(){return o})),r.d(e,"toMpegTsClockFromTimescale",(function(){return a}))},"./src/utils/typed-array.ts":
|
|
|
/*!**********************************!*\
|
|
|
!*** ./src/utils/typed-array.ts ***!
|
|
|
\**********************************/
|
|
|
/*! exports provided: sliceUint8 */function(t,e,r){"use strict";function n(t,e,r){return Uint8Array.prototype.slice?t.slice(e,r):new Uint8Array(Array.prototype.slice.call(t,e,r))}r.r(e),r.d(e,"sliceUint8",(function(){return n}))},"./src/utils/vttcue.ts":
|
|
|
/*!*****************************!*\
|
|
|
!*** ./src/utils/vttcue.ts ***!
|
|
|
\*****************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e),e.default=function(){if("undefined"!=typeof self&&self.VTTCue)return self.VTTCue;var t=["","lr","rl"],e=["start","middle","end","left","right"];function r(t,e){if("string"!=typeof e)return!1;if(!Array.isArray(t))return!1;var r=e.toLowerCase();return!!~t.indexOf(r)&&r}function n(t){return r(e,t)}function i(t){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];for(var i=1;i<arguments.length;i++){var o=arguments[i];for(var a in o)t[a]=o[a]}return t}function o(e,o,a){var s=this,A={enumerable:!0};s.hasBeenReset=!1;var l="",c=!1,u=e,h=o,d=a,f=null,p="",g=!0,m="auto",v="start",y=50,w="middle",b=50,C="middle";Object.defineProperty(s,"id",i({},A,{get:function(){return l},set:function(t){l=""+t}})),Object.defineProperty(s,"pauseOnExit",i({},A,{get:function(){return c},set:function(t){c=!!t}})),Object.defineProperty(s,"startTime",i({},A,{get:function(){return u},set:function(t){if("number"!=typeof t)throw new TypeError("Start time must be set to a number.");u=t,this.hasBeenReset=!0}})),Object.defineProperty(s,"endTime",i({},A,{get:function(){return h},set:function(t){if("number"!=typeof t)throw new TypeError("End time must be set to a number.");h=t,this.hasBeenReset=!0}})),Object.defineProperty(s,"text",i({},A,{get:function(){return d},set:function(t){d=""+t,this.hasBeenReset=!0}})),Object.defineProperty(s,"region",i({},A,{get:function(){return f},set:function(t){f=t,this.hasBeenReset=!0}})),Object.defineProperty(s,"vertical",i({},A,{get:function(){return p},set:function(e){var n=function(e){return r(t,e)}(e);if(!1===n)throw new SyntaxError("An invalid or illegal string was specified.");p=n,this.hasBeenReset=!0}})),Object.defineProperty(s,"snapToLines",i({},A,{get:function(){return g},set:function(t){g=!!t,this.hasBeenReset=!0}})),Object.defineProperty(s,"line",i({},A,{get:function(){return m},set:function(t){if("number"!=typeof t&&"auto"!==t)throw new SyntaxError("An invalid number or illegal string was specified.");m=t,this.hasBeenReset=!0}})),Object.defineProperty(s,"lineAlign",i({},A,{get:function(){return v},set:function(t){var e=n(t);if(!e)throw new SyntaxError("An invalid or illegal string was specified.");v=e,this.hasBeenReset=!0}})),Object.defineProperty(s,"position",i({},A,{get:function(){return y},set:function(t){if(t<0||t>100)throw new Error("Position must be between 0 and 100.");y=t,this.hasBeenReset=!0}})),Object.defineProperty(s,"positionAlign",i({},A,{get:function(){return w},set:function(t){var e=n(t);if(!e)throw new SyntaxError("An invalid or illegal string was specified.");w=e,this.hasBeenReset=!0}})),Object.defineProperty(s,"size",i({},A,{get:function(){return b},set:function(t){if(t<0||t>100)throw new Error("Size must be between 0 and 100.");b=t,this.hasBeenReset=!0}})),Object.defineProperty(s,"align",i({},A,{get:function(){return C},set:function(t){var e=n(t);if(!e)throw new SyntaxError("An invalid or illegal string was specified.");C=e,this.hasBeenReset=!0}})),s.displayState=void 0}return o.prototype.getCueAsHTML=function(){return self.WebVTT.convertCueToDOMTree(self,this.text)},o}()},"./src/utils/vttparser.ts":
|
|
|
/*!********************************!*\
|
|
|
!*** ./src/utils/vttparser.ts ***!
|
|
|
\********************************/
|
|
|
/*! exports provided: parseTimeStamp, fixLineBreaks, VTTParser */function(t,e,r){"use strict";r.r(e),r.d(e,"parseTimeStamp",(function(){return o})),r.d(e,"fixLineBreaks",(function(){return u})),r.d(e,"VTTParser",(function(){return h}));var n=r(/*! ./vttcue */"./src/utils/vttcue.ts"),i=function(){function t(){}return t.prototype.decode=function(t,e){if(!t)return"";if("string"!=typeof t)throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(t))},t}();function o(t){function e(t,e,r,n){return 3600*(0|t)+60*(0|e)+(0|r)+parseFloat(n||0)}var r=t.match(/^(?:(\d+):)?(\d{2}):(\d{2})(\.\d+)?/);return r?parseFloat(r[2])>59?e(r[2],r[3],0,r[4]):e(r[1],r[2],r[3],r[4]):null}var a=function(){function t(){this.values=Object.create(null)}var e=t.prototype;return e.set=function(t,e){this.get(t)||""===e||(this.values[t]=e)},e.get=function(t,e,r){return r?this.has(t)?this.values[t]:e[r]:this.has(t)?this.values[t]:e},e.has=function(t){return t in this.values},e.alt=function(t,e,r){for(var n=0;n<r.length;++n)if(e===r[n]){this.set(t,e);break}},e.integer=function(t,e){/^-?\d+$/.test(e)&&this.set(t,parseInt(e,10))},e.percent=function(t,e){if(/^([\d]{1,3})(\.[\d]*)?%$/.test(e)){var r=parseFloat(e);if(r>=0&&r<=100)return this.set(t,r),!0}return!1},t}();function s(t,e,r,n){var i=n?t.split(n):[t];for(var o in i)if("string"==typeof i[o]){var a=i[o].split(r);2===a.length&&e(a[0],a[1])}}var A=new n.default(0,0,""),l="middle"===A.align?"middle":"center";function c(t,e,r){var n=t;function i(){var e=o(t);if(null===e)throw new Error("Malformed timestamp: "+n);return t=t.replace(/^[^\sa-zA-Z-]+/,""),e}function c(){t=t.replace(/^\s+/,"")}if(c(),e.startTime=i(),c(),"--\x3e"!==t.substr(0,3))throw new Error("Malformed time stamp (time stamps must be separated by '--\x3e'): "+n);t=t.substr(3),c(),e.endTime=i(),c(),function(t,e){var n=new a;s(t,(function(t,e){var i;switch(t){case"region":for(var o=r.length-1;o>=0;o--)if(r[o].id===e){n.set(t,r[o].region);break}break;case"vertical":n.alt(t,e,["rl","lr"]);break;case"line":i=e.split(","),n.integer(t,i[0]),n.percent(t,i[0])&&n.set("snapToLines",!1),n.alt(t,i[0],["auto"]),2===i.length&&n.alt("lineAlign",i[1],["start",l,"end"]);break;case"position":i=e.split(","),n.percent(t,i[0]),2===i.length&&n.alt("positionAlign",i[1],["start",l,"end","line-left","line-right","auto"]);break;case"size":n.percent(t,e);break;case"align":n.alt(t,e,["start",l,"end","left","right"])}}),/:/,/\s/),e.region=n.get("region",null),e.vertical=n.get("vertical","");var i=n.get("line","auto");"auto"===i&&-1===A.line&&(i=-1),e.line=i,e.lineAlign=n.get("lineAlign","start"),e.snapToLines=n.get("snapToLines",!0),e.size=n.get("size",100),e.align=n.get("align",l);var o=n.get("position","auto");"auto"===o&&50===A.position&&(o="start"===e.align||"left"===e.align?0:"end"===e.align||"right"===e.align?100:50),e.position=o}(t,e)}function u(t){return t.replace(/<br(?: \/)?>/gi,"\n")}var h=function(){function t(){this.state="INITIAL",this.buffer="",this.decoder=new i,this.regionList=[],this.cue=null,this.oncue=void 0,this.onparsingerror=void 0,this.onflush=void 0}var e=t.prototype;return e.parse=function(t){var e=this;function r(){var t=e.buffer,r=0;for(t=u(t);r<t.length&&"\r"!==t[r]&&"\n"!==t[r];)++r;var n=t.substr(0,r);return"\r"===t[r]&&++r,"\n"===t[r]&&++r,e.buffer=t.substr(r),n}t&&(e.buffer+=e.decoder.decode(t,{stream:!0}));try{var i="";if("INITIAL"===e.state){if(!/\r\n|\n/.test(e.buffer))return this;var o=(i=r()).match(/^()?WEBVTT([ \t].*)?$/);if(!o||!o[0])throw new Error("Malformed WebVTT signature.");e.state="HEADER"}for(var a=!1;e.buffer;){if(!/\r\n|\n/.test(e.buffer))return this;switch(a?a=!1:i=r(),e.state){case"HEADER":/:/.test(i)?s(i,(function(t,e){}),/:/):i||(e.state="ID");continue;case"NOTE":i||(e.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(i)){e.state="NOTE";break}if(!i)continue;if(e.cue=new n.default(0,0,""),e.state="CUE",-1===i.indexOf("--\x3e")){e.cue.id=i;continue}case"CUE":if(!e.cue){e.state="BADCUE";continue}try{c(i,e.cue,e.regionList)}catch(t){e.cue=null,e.state="BADCUE";continue}e.state="CUETEXT";continue;case"CUETEXT":var A=-1!==i.indexOf("--\x3e");if(!i||A&&(a=!0)){e.oncue&&e.cue&&e.oncue(e.cue),e.cue=null,e.state="ID";continue}if(null===e.cue)continue;e.cue.text&&(e.cue.text+="\n"),e.cue.text+=i;continue;case"BADCUE":i||(e.state="ID")}}}catch(t){"CUETEXT"===e.state&&e.cue&&e.oncue&&e.oncue(e.cue),e.cue=null,e.state="INITIAL"===e.state?"BADWEBVTT":"BADCUE"}return this},e.flush=function(){try{if((this.cue||"HEADER"===this.state)&&(this.buffer+="\n\n",this.parse()),"INITIAL"===this.state||"BADWEBVTT"===this.state)throw new Error("Malformed WebVTT signature.")}catch(t){this.onparsingerror&&this.onparsingerror(t)}return this.onflush&&this.onflush(),this},t}()},"./src/utils/webvtt-parser.ts":
|
|
|
/*!************************************!*\
|
|
|
!*** ./src/utils/webvtt-parser.ts ***!
|
|
|
\************************************/
|
|
|
/*! exports provided: generateCueId, parseWebVTT */function(t,e,r){"use strict";r.r(e),r.d(e,"generateCueId",(function(){return u})),r.d(e,"parseWebVTT",(function(){return h}));var n=r(/*! ./src/polyfills/number */"./src/polyfills/number.ts"),i=r(/*! ./vttparser */"./src/utils/vttparser.ts"),o=r(/*! ../demux/id3 */"./src/demux/id3.ts"),a=r(/*! ./timescale-conversion */"./src/utils/timescale-conversion.ts"),s=r(/*! ../remux/mp4-remuxer */"./src/remux/mp4-remuxer.ts"),A=/\r\n|\n\r|\n|\r/g,l=function(t,e,r){return void 0===r&&(r=0),t.substr(r,e.length)===e},c=function(t){for(var e=5381,r=t.length;r;)e=33*e^t.charCodeAt(--r);return(e>>>0).toString()};function u(t,e,r){return c(t.toString())+c(e.toString())+c(r)}function h(t,e,r,c,h,d,f,p){var g,m=new i.VTTParser,v=Object(o.utf8ArrayToStr)(new Uint8Array(t)).trim().replace(A,"\n").split("\n"),y=[],w=Object(a.toMpegTsClockFromTimescale)(e,r),b="00:00.000",C=0,B=0,x=!0,E=!1;m.oncue=function(t){var e=c[h],r=c.ccOffset,n=(C-w)/9e4;if(null!=e&&e.new&&(void 0!==B?r=c.ccOffset=e.start:function(t,e,r){var n=t[e],i=t[n.prevCC];if(!i||!i.new&&n.new)return t.ccOffset=t.presentationOffset=n.start,void(n.new=!1);for(;null!==(o=i)&&void 0!==o&&o.new;){var o;t.ccOffset+=n.start-i.start,n.new=!1,i=t[(n=i).prevCC]}t.presentationOffset=r}(c,h,n)),n&&(r=n-c.presentationOffset),E){var i=t.endTime-t.startTime,o=Object(s.normalizePts)(9e4*(t.startTime+r-B),9e4*d)/9e4;t.startTime=o,t.endTime=o+i}var a=t.text.trim();t.text=decodeURIComponent(encodeURIComponent(a)),t.id||(t.id=u(t.startTime,t.endTime,a)),t.endTime>0&&y.push(t)},m.onparsingerror=function(t){g=t},m.onflush=function(){g?p(g):f(y)},v.forEach((function(t){if(x){if(l(t,"X-TIMESTAMP-MAP=")){x=!1,E=!0,t.substr(16).split(",").forEach((function(t){l(t,"LOCAL:")?b=t.substr(6):l(t,"MPEGTS:")&&(C=parseInt(t.substr(7)))}));try{B=function(t){var e=parseInt(t.substr(-3)),r=parseInt(t.substr(-6,2)),i=parseInt(t.substr(-9,2)),o=t.length>9?parseInt(t.substr(0,t.indexOf(":"))):0;if(!(Object(n.isFiniteNumber)(e)&&Object(n.isFiniteNumber)(r)&&Object(n.isFiniteNumber)(i)&&Object(n.isFiniteNumber)(o)))throw Error("Malformed X-TIMESTAMP-MAP: Local:"+t);return e+=1e3*r,e+=6e4*i,e+=36e5*o}(b)/1e3}catch(t){E=!1,g=t}return}""===t&&(x=!1)}m.parse(t+"\n")})),m.flush()}},"./src/utils/xhr-loader.ts":
|
|
|
/*!*********************************!*\
|
|
|
!*** ./src/utils/xhr-loader.ts ***!
|
|
|
\*********************************/
|
|
|
/*! exports provided: default */function(t,e,r){"use strict";r.r(e);var n=r(/*! ../utils/logger */"./src/utils/logger.ts"),i=r(/*! ../loader/load-stats */"./src/loader/load-stats.ts"),o=/^age:\s*[\d.]+\s*$/m,a=function(){function t(t){this.xhrSetup=void 0,this.requestTimeout=void 0,this.retryTimeout=void 0,this.retryDelay=void 0,this.config=null,this.callbacks=null,this.context=void 0,this.loader=null,this.stats=void 0,this.xhrSetup=t?t.xhrSetup:null,this.stats=new i.LoadStats,this.retryDelay=0}var e=t.prototype;return e.destroy=function(){this.callbacks=null,this.abortInternal(),this.loader=null,this.config=null},e.abortInternal=function(){var t=this.loader;self.clearTimeout(this.requestTimeout),self.clearTimeout(this.retryTimeout),t&&(t.onreadystatechange=null,t.onprogress=null,4!==t.readyState&&(this.stats.aborted=!0,t.abort()))},e.abort=function(){var t;this.abortInternal(),null!==(t=this.callbacks)&&void 0!==t&&t.onAbort&&this.callbacks.onAbort(this.stats,this.context,this.loader)},e.load=function(t,e,r){if(this.stats.loading.start)throw new Error("Loader can only be used once.");this.stats.loading.start=self.performance.now(),this.context=t,this.config=e,this.callbacks=r,this.retryDelay=e.retryDelay,this.loadInternal()},e.loadInternal=function(){var t=this.config,e=this.context;if(t){var r=this.loader=new self.XMLHttpRequest,n=this.stats;n.loading.first=0,n.loaded=0;var i=this.xhrSetup;try{if(i)try{i(r,e.url)}catch(t){r.open("GET",e.url,!0),i(r,e.url)}r.readyState||r.open("GET",e.url,!0);var o=this.context.headers;if(o)for(var a in o)r.setRequestHeader(a,o[a])}catch(t){return void this.callbacks.onError({code:r.status,text:t.message},e,r)}e.rangeEnd&&r.setRequestHeader("Range","bytes="+e.rangeStart+"-"+(e.rangeEnd-1)),r.onreadystatechange=this.readystatechange.bind(this),r.onprogress=this.loadprogress.bind(this),r.responseType=e.responseType,self.clearTimeout(this.requestTimeout),this.requestTimeout=self.setTimeout(this.loadtimeout.bind(this),t.timeout),r.send()}},e.readystatechange=function(){var t=this.context,e=this.loader,r=this.stats;if(t&&e){var i=e.readyState,o=this.config;if(!r.aborted&&i>=2)if(self.clearTimeout(this.requestTimeout),0===r.loading.first&&(r.loading.first=Math.max(self.performance.now(),r.loading.start)),4===i){e.onreadystatechange=null,e.onprogress=null;var a=e.status;if(a>=200&&a<300){var s,A;if(r.loading.end=Math.max(self.performance.now(),r.loading.first),A="arraybuffer"===t.responseType?(s=e.response).byteLength:(s=e.responseText).length,r.loaded=r.total=A,!this.callbacks)return;var l=this.callbacks.onProgress;if(l&&l(r,t,s,e),!this.callbacks)return;var c={url:e.responseURL,data:s};this.callbacks.onSuccess(c,r,t,e)}else r.retry>=o.maxRetry||a>=400&&a<499?(n.logger.error(a+" while loading "+t.url),this.callbacks.onError({code:a,text:e.statusText},t,e)):(n.logger.warn(a+" while loading "+t.url+", retrying in "+this.retryDelay+"..."),this.abortInternal(),this.loader=null,self.clearTimeout(this.retryTimeout),this.retryTimeout=self.setTimeout(this.loadInternal.bind(this),this.retryDelay),this.retryDelay=Math.min(2*this.retryDelay,o.maxRetryDelay),r.retry++)}else self.clearTimeout(this.requestTimeout),this.requestTimeout=self.setTimeout(this.loadtimeout.bind(this),o.timeout)}},e.loadtimeout=function(){n.logger.warn("timeout while loading "+this.context.url);var t=this.callbacks;t&&(this.abortInternal(),t.onTimeout(this.stats,this.context,this.loader))},e.loadprogress=function(t){var e=this.stats;e.loaded=t.loaded,t.lengthComputable&&(e.total=t.total)},e.getCacheAge=function(){var t=null;if(this.loader&&o.test(this.loader.getAllResponseHeaders())){var e=this.loader.getResponseHeader("age");t=e?parseFloat(e):null}return t},t}();e.default=a}}).default},t.exports=n())},vHTk:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./src/components/PreviewAll/index.less?modules ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){t.exports={wrp:"wrp___z2l1F",bgBlack:"bgBlack___3ezfX",monaco:"monaco___1ypjT",darkBlue:"darkBlue___2ViJc",close:"close___3q-z4",embed:"embed___3dQqc"}},vKoX:
|
|
|
/*!**************************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/svg/helper/ShadowManager.js ***!
|
|
|
\**************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./Definable */"SrGk");function i(t,e){n.call(this,t,e,["filter"],"__filter_in_use__","_shadowDom")}function o(t){return t&&(t.shadowBlur||t.shadowOffsetX||t.shadowOffsetY||t.textShadowBlur||t.textShadowOffsetX||t.textShadowOffsetY)}r(/*! ../../core/util */"bYtY").inherits(i,n),i.prototype.addWithoutUpdate=function(t,e){if(e&&o(e.style)){var r;if(e._shadowDom)r=e._shadowDom,this.getDefs(!0).contains(e._shadowDom)||this.addDom(r);else r=this.add(e);this.markUsed(e);var n=r.getAttribute("id");t.style.filter="url(#"+n+")"}},i.prototype.add=function(t){var e=this.createElement("filter");return t._shadowDomId=t._shadowDomId||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-shadow-"+t._shadowDomId),this.updateDom(t,e),this.addDom(e),e},i.prototype.update=function(t,e){if(o(e.style)){var r=this;n.prototype.update.call(this,e,(function(){r.updateDom(e,e._shadowDom)}))}else this.remove(t,e)},i.prototype.remove=function(t,e){null!=e._shadowDomId&&(this.removeDom(t),t.style.filter="")},i.prototype.updateDom=function(t,e){var r=e.getElementsByTagName("feDropShadow");r=0===r.length?this.createElement("feDropShadow"):r[0];var n,i,o,a,s=t.style,A=t.scale&&t.scale[0]||1,l=t.scale&&t.scale[1]||1;if(s.shadowBlur||s.shadowOffsetX||s.shadowOffsetY)n=s.shadowOffsetX||0,i=s.shadowOffsetY||0,o=s.shadowBlur,a=s.shadowColor;else{if(!s.textShadowBlur)return void this.removeDom(e,s);n=s.textShadowOffsetX||0,i=s.textShadowOffsetY||0,o=s.textShadowBlur,a=s.textShadowColor}r.setAttribute("dx",n/A),r.setAttribute("dy",i/l),r.setAttribute("flood-color",a);var c=o/2/A+" "+o/2/l;r.setAttribute("stdDeviation",c),e.setAttribute("x","-100%"),e.setAttribute("y","-100%"),e.setAttribute("width",Math.ceil(o/2*200)+"%"),e.setAttribute("height",Math.ceil(o/2*200)+"%"),e.appendChild(r),t._shadowDom=e},i.prototype.markUsed=function(t){t._shadowDom&&n.prototype.markUsed.call(this,t._shadowDom)};var a=i;t.exports=a},vWvF:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/mixin/Animatable.js ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../animation/Animator */"Bq2U"),i=r(/*! ../core/log */"SUKs"),o=r(/*! ../core/util */"bYtY"),a=o.isString,s=o.isFunction,A=o.isObject,l=o.isArrayLike,c=o.indexOf,u=function(){this.animators=[]};function h(t,e,r,n,i,o,c,u){a(n)?(o=i,i=n,n=0):s(i)?(o=i,i="linear",n=0):s(n)?(o=n,n=0):s(r)?(o=r,r=500):r||(r=500),t.stopAnimation(),function t(e,r,n,i,o,a,s){var c={},u=0;for(var h in i)i.hasOwnProperty(h)&&(null!=n[h]?A(i[h])&&!l(i[h])?t(e,r?r+"."+h:h,n[h],i[h],o,a,s):(s?(c[h]=n[h],d(e,r,h,i[h])):c[h]=i[h],u++):null==i[h]||s||d(e,r,h,i[h]));u>0&&e.animate(r,!1).when(null==o?500:o,c).delay(a||0)}(t,"",t,e,r,n,u);var h=t.animators.slice(),f=h.length;function p(){--f||o&&o()}f||o&&o();for(var g=0;g<h.length;g++)h[g].done(p).start(i,c)}function d(t,e,r,n){if(e){var i={};i[e]={},i[e][r]=n,t.attr(i)}else t.attr(r,n)}u.prototype={constructor:u,animate:function(t,e){var r,o=!1,a=this,s=this.__zr;if(t){var A=t.split("."),l=a;o="shape"===A[0];for(var u=0,h=A.length;u<h;u++)l&&(l=l[A[u]]);l&&(r=l)}else r=a;if(r){var d=a.animators,f=new n(r,e);return f.during((function(t){a.dirty(o)})).done((function(){d.splice(c(d,f),1)})),d.push(f),s&&s.animation.addAnimator(f),f}i('Property "'+t+'" is not existed in element '+a.id)},stopAnimation:function(t){for(var e=this.animators,r=e.length,n=0;n<r;n++)e[n].stop(t);return e.length=0,this},animateTo:function(t,e,r,n,i,o){h(this,t,e,r,n,i,o)},animateFrom:function(t,e,r,n,i,o){h(this,t,e,r,n,i,o,!0)}};var f=u;t.exports=f},wCXF:
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/Table.js + 17 modules ***!
|
|
|
\********************************************************/
|
|
|
/*! exports provided: INTERNAL_HOOKS, default */
|
|
|
/*! exports used: INTERNAL_HOOKS, default */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/typeof.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/raf/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-resize-observer/es/index.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/Cell/index.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/Footer/index.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/context/TableContext.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/hooks/useColumns.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/sugar/Column.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/sugar/ColumnGroup.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/utils/legacyUtil.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/utils/valueUtil.js because of ./node_modules/antd/es/table/Table.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/Dom/addEventListener.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/Dom/css.js because of ./node_modules/rc-image/es/Image.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/getScrollBarSize.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/ref.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/warning.js */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */
|
|
|
/*! ModuleConcatenation bailout: Cannot concat with ./node_modules/shallowequal/index.js (<- Module is not an ECMAScript module) */function(t,e,r){"use strict";r.d(e,"a",(function(){return Z}));var n=r("rePB"),i=r("VTBJ"),o=r("KQm4"),a=r("U8pU"),s=r("ODXe"),A=r("q1tI"),l=r("TSYQ"),c=r.n(l),u=r("Gytx"),h=r.n(u),d=r("Kwbf"),f=r("t23M"),p=r("qx4F"),g=r("6eGT"),m=r("IBYe"),v=r("Ff2n"),y=r("c+Xe"),w=r("fyJ8"),b=r("biw7");function C(t,e,r,n,i){var o,a,s=r[t]||{},A=r[e]||{};"left"===s.fixed?o=n.left[t]:"right"===A.fixed&&(a=n.right[e]);var l=!1,c=!1,u=!1,h=!1,d=r[e+1],f=r[t-1];if("rtl"===i){if(void 0!==o)h=!(f&&"left"===f.fixed);else if(void 0!==a){u=!(d&&"right"===d.fixed)}}else if(void 0!==o){l=!(d&&"left"===d.fixed)}else if(void 0!==a){c=!(f&&"right"===f.fixed)}return{fixLeft:o,fixRight:a,lastFixLeft:l,firstFixRight:c,lastFixRight:u,firstFixLeft:h,isSticky:n.isSticky}}var B=r("sR1s");function x(t){var e,r=t.cells,n=t.stickyOffsets,i=t.flattenColumns,o=t.rowComponent,a=t.cellComponent,s=t.onHeaderRow,l=t.index,c=A.useContext(b.a),u=c.prefixCls,h=c.direction;s&&(e=s(r.map((function(t){return t.column})),l));var d=Object(B.a)(r.map((function(t){return t.column})));return A.createElement(o,Object.assign({},e),r.map((function(t,e){var r,o=t.column,s=C(t.colStart,t.colEnd,i,n,h);return o&&o.onHeaderCell&&(r=t.column.onHeaderCell(o)),A.createElement(w.a,Object.assign({},t,{ellipsis:o.ellipsis,align:o.align,component:a,prefixCls:u,key:d[e]},s,{additionalProps:r,rowType:"header"}))})))}x.displayName="HeaderRow";var E=x;var S=function(t){var e=t.stickyOffsets,r=t.columns,n=t.flattenColumns,i=t.onHeaderRow,o=A.useContext(b.a),a=o.prefixCls,s=o.getComponent,l=A.useMemo((function(){return function(t){var e=[];!function t(r,n){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;e[i]=e[i]||[];var o=n,a=r.filter(Boolean).map((function(r){var n={key:r.key,className:r.className||"",children:r.title,column:r,colStart:o},a=1,s=r.children;return s&&s.length>0&&(a=t(s,o,i+1).reduce((function(t,e){return t+e}),0),n.hasSubColumns=!0),"colSpan"in r&&(a=r.colSpan),"rowSpan"in r&&(n.rowSpan=r.rowSpan),n.colSpan=a,n.colEnd=n.colStart+a-1,e[i].push(n),o+=a,a}));return a}(t,0);for(var r=e.length,n=function(t){e[t].forEach((function(e){"rowSpan"in e||e.hasSubColumns||(e.rowSpan=r-t)}))},i=0;i<r;i+=1)n(i);return e}(r)}),[r]),c=s(["header","wrapper"],"thead"),u=s(["header","row"],"tr"),h=s(["header","cell"],"th");return A.createElement(c,{className:"".concat(a,"-thead")},l.map((function(t,r){return A.createElement(E,{key:r,flattenColumns:n,cells:t,stickyOffsets:e,rowComponent:u,cellComponent:h,onHeaderRow:i,index:r})})))},k=r("hW8S");var T=function(t){for(var e=t.colWidths,r=t.columns,n=[],i=!1,o=(t.columCount||r.length)-1;o>=0;o-=1){var a=e[o],s=r&&r[o],l=s&&s[k.a];(a||l||i)&&(n.unshift(A.createElement("col",Object.assign({key:o,style:{width:a,minWidth:a}},l))),i=!0)}return A.createElement("colgroup",null,n)};var F=A.forwardRef((function(t,e){var r=t.noData,a=t.columns,s=t.flattenColumns,l=t.colWidths,u=t.columCount,h=t.stickyOffsets,d=t.direction,f=t.fixHeader,p=t.offsetHeader,g=t.stickyClassName,m=t.onScroll,w=Object(v.a)(t,["noData","columns","flattenColumns","colWidths","columCount","stickyOffsets","direction","fixHeader","offsetHeader","stickyClassName","onScroll"]),C=A.useContext(b.a),B=C.prefixCls,x=C.scrollbarSize,E=C.isSticky,k=E&&!f?0:x,F=A.useRef(null),L=A.useCallback((function(t){Object(y.b)(e,t),Object(y.b)(F,t)}),[]);A.useEffect((function(){var t;function e(t){var e=t.currentTarget,r=t.deltaX;r&&(m({currentTarget:e,scrollLeft:e.scrollLeft+r}),t.preventDefault())}return null===(t=F.current)||void 0===t||t.addEventListener("wheel",e),function(){var t;null===(t=F.current)||void 0===t||t.removeEventListener("wheel",e)}}),[]);var I=s[s.length-1],_={fixed:I?I.fixed:null,onHeaderCell:function(){return{className:"".concat(B,"-cell-scrollbar")}}},U=Object(A.useMemo)((function(){return k?[].concat(Object(o.a)(a),[_]):a}),[k,a]),O=Object(A.useMemo)((function(){return k?[].concat(Object(o.a)(s),[_]):s}),[k,s]),D=Object(A.useMemo)((function(){var t=h.right,e=h.left;return Object(i.a)(Object(i.a)({},h),{},{left:"rtl"===d?[].concat(Object(o.a)(e.map((function(t){return t+k}))),[0]):e,right:"rtl"===d?t:[].concat(Object(o.a)(t.map((function(t){return t+k}))),[0]),isSticky:E})}),[k,h,E]),Q=function(t,e){return Object(A.useMemo)((function(){for(var r=[],n=0;n<e;n+=1){var i=t[n];if(void 0===i)return null;r[n]=i}return r}),[t.join("_"),e])}(l,u);return A.createElement("div",{style:Object(i.a)({overflow:"hidden"},E?{top:p}:{}),ref:L,className:c()("".concat(B,"-header"),Object(n.a)({},g,!!g))},A.createElement("table",{style:{tableLayout:"fixed",visibility:r||Q?null:"hidden"}},A.createElement(T,{colWidths:Q?[].concat(Object(o.a)(Q),[k]):[],columCount:u+1,columns:O}),A.createElement(S,Object.assign({},w,{stickyOffsets:D,columns:U,flattenColumns:O}))))}));F.displayName="FixedHeader";var L=F,I=A.createContext(null);var _=function(t){var e=t.prefixCls,r=t.children,n=t.component,i=t.cellComponent,o=t.fixHeader,a=t.fixColumn,s=t.horizonScroll,l=t.className,c=t.expanded,u=t.componentWidth,h=t.colSpan,d=A.useContext(b.a).scrollbarSize;return A.useMemo((function(){var t=r;return a&&(t=A.createElement("div",{style:{width:u-(o?d:0),position:"sticky",left:0,overflow:"hidden"},className:"".concat(e,"-expanded-row-fixed")},t)),A.createElement(n,{className:l,style:{display:c?null:"none"}},A.createElement(w.a,{component:i,prefixCls:e,colSpan:h},t))}),[r,n,o,s,l,c,u,h,d])};function U(t){var e=t.className,r=t.style,n=t.record,o=t.index,a=t.rowKey,l=t.getRowKey,u=t.rowExpandable,h=t.expandedKeys,d=t.onRow,f=t.indent,p=void 0===f?0:f,g=t.rowComponent,m=t.cellComponent,v=t.childrenColumnName,y=A.useContext(b.a),C=y.prefixCls,x=y.fixedInfoList,E=A.useContext(I),S=E.fixHeader,k=E.fixColumn,T=E.horizonScroll,F=E.componentWidth,L=E.flattenColumns,O=E.expandableType,D=E.expandRowByClick,Q=E.onTriggerExpand,M=E.rowClassName,R=E.expandedRowClassName,P=E.indentSize,H=E.expandIcon,N=E.expandedRowRender,K=E.expandIconColumnIndex,j=A.useState(!1),G=Object(s.a)(j,2),V=G[0],z=G[1],W=h&&h.has(t.recordKey);A.useEffect((function(){W&&z(!0)}),[W]);var Y,X="row"===O&&(!u||u(n)),q="nest"===O,J=v&&n&&n[v],Z=X||q;d&&(Y=d(n,o));var $;"string"==typeof M?$=M:"function"==typeof M&&($=M(n,o,p));var tt,et,rt=Object(B.a)(L),nt=A.createElement(g,Object.assign({},Y,{"data-row-key":a,className:c()(e,"".concat(C,"-row"),"".concat(C,"-row-level-").concat(p),$,Y&&Y.className),style:Object(i.a)(Object(i.a)({},r),Y?Y.style:null),onClick:function(t){if(D&&Z&&Q(n,t),Y&&Y.onClick){for(var e,r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];(e=Y).onClick.apply(e,[t].concat(i))}}}),L.map((function(t,e){var r,i,a=t.render,s=t.dataIndex,l=t.className,c=rt[e],u=x[e];return e===(K||0)&&q&&(r=A.createElement(A.Fragment,null,A.createElement("span",{style:{paddingLeft:"".concat(P*p,"px")},className:"".concat(C,"-row-indent indent-level-").concat(p)}),H({prefixCls:C,expanded:W,expandable:J,record:n,onExpand:Q}))),t.onCell&&(i=t.onCell(n,o)),A.createElement(w.a,Object.assign({className:l,ellipsis:t.ellipsis,align:t.align,component:m,prefixCls:C,key:c,record:n,index:o,dataIndex:s,render:a,shouldCellUpdate:t.shouldCellUpdate},u,{appendNode:r,additionalProps:i}))})));if(X&&(V||W)){var it=N(n,o,p+1,W),ot=R&&R(n,o,p);tt=A.createElement(_,{expanded:W,className:c()("".concat(C,"-expanded-row"),"".concat(C,"-expanded-row-level-").concat(p+1),ot),prefixCls:C,fixHeader:S,fixColumn:k,horizonScroll:T,component:g,componentWidth:F,cellComponent:m,colSpan:L.length},it)}return J&&W&&(et=(n[v]||[]).map((function(e,r){var n=l(e,r);return A.createElement(U,Object.assign({},t,{key:n,rowKey:n,record:e,recordKey:n,index:r,indent:p+1}))}))),A.createElement(A.Fragment,null,nt,tt,et)}U.displayName="BodyRow";var O=U,D=A.createContext(null);function Q(t){var e=t.columnKey,r=t.onColumnResize,n=A.useRef();return A.useEffect((function(){n.current&&r(e,n.current.offsetWidth)}),[]),A.createElement(f.a,{onResize:function(t){var n=t.offsetWidth;r(e,n)}},A.createElement("td",{ref:n,style:{padding:0,border:0,height:0}},A.createElement("div",{style:{height:0,overflow:"hidden"}}," ")))}var M=A.memo((function(t){var e=t.data,r=t.getRowKey,n=t.measureColumnWidth,i=t.expandedKeys,o=t.onRow,a=t.rowExpandable,s=t.emptyNode,l=t.childrenColumnName,c=A.useContext(D).onColumnResize,u=A.useContext(b.a),h=u.prefixCls,d=u.getComponent,f=A.useContext(I),p=f.fixHeader,g=f.horizonScroll,m=f.flattenColumns,v=f.componentWidth;return A.useMemo((function(){var t,u=d(["body","wrapper"],"tbody"),f=d(["body","row"],"tr"),y=d(["body","cell"],"td");t=e.length?e.map((function(t,e){var n=r(t,e);return A.createElement(O,{key:n,rowKey:n,record:t,recordKey:n,index:e,rowComponent:f,cellComponent:y,expandedKeys:i,onRow:o,getRowKey:r,rowExpandable:a,childrenColumnName:l})})):A.createElement(_,{expanded:!0,className:"".concat(h,"-placeholder"),prefixCls:h,fixHeader:p,fixColumn:g,horizonScroll:g,component:f,componentWidth:v,cellComponent:y,colSpan:m.length},s);var w=Object(B.a)(m);return A.createElement(u,{className:"".concat(h,"-tbody")},n&&A.createElement("tr",{"aria-hidden":"true",className:"".concat(h,"-measure-row"),style:{height:0}},w.map((function(t){return A.createElement(Q,{key:t,columnKey:t,onColumnResize:c})}))),t)}),[e,h,o,n,i,r,d,v,s,m])}));M.displayName="Body";var R=M,P=r("wRmb"),H=r("xEkU"),N=r.n(H);function K(t){var e=Object(A.useRef)(t),r=Object(A.useState)({}),n=Object(s.a)(r,2)[1],i=Object(A.useRef)(null),o=Object(A.useRef)([]);return Object(A.useEffect)((function(){return function(){N.a.cancel(i.current)}}),[]),[e.current,function(t){null===i.current&&(o.current=[],i.current=N()((function(){o.current.forEach((function(t){e.current=t(e.current)})),i.current=null,n({})}))),o.current.push(t)}]}var j=function(t,e,r){return Object(A.useMemo)((function(){for(var n=[],i=[],o=0,a=0,s=0;s<e;s+=1)if("rtl"===r){i[s]=a,a+=t[s]||0;var A=e-s-1;n[A]=o,o+=t[A]||0}else{n[s]=o,o+=t[s]||0;var l=e-s-1;i[l]=a,a+=t[l]||0}return{left:n,right:i}}),[t,e,r])};var G=function(t){var e=t.className,r=t.children;return A.createElement("div",{className:e},r)},V=r("n6Qo");function z(t){var e,r=t.prefixCls,i=t.record,o=t.onExpand,a=t.expanded,s=t.expandable,l="".concat(r,"-row-expand-icon");if(!s)return A.createElement("span",{className:c()(l,"".concat(r,"-row-spaced"))});return A.createElement("span",{className:c()(l,(e={},Object(n.a)(e,"".concat(r,"-row-expanded"),a),Object(n.a)(e,"".concat(r,"-row-collapsed"),!a),e)),onClick:function(t){o(i,t),t.stopPropagation()}})}var W=r("zT1h"),Y=r("y0+3"),X=A.forwardRef((function(t,e){var r,o,a=t.scrollBodyRef,l=t.onScroll,u=t.offsetScroll,h=A.useContext(b.a).prefixCls,d=(null===(r=a.current)||void 0===r?void 0:r.scrollWidth)||0,f=(null===(o=a.current)||void 0===o?void 0:o.clientWidth)||0,g=d&&f*(f/d),m=A.useRef(),v=K({scrollLeft:0,isHiddenScrollBar:!1}),y=Object(s.a)(v,2),w=y[0],C=y[1],B=A.useRef({delta:0,x:0}),x=A.useState(!1),E=Object(s.a)(x,2),S=E[0],k=E[1],T=function(){k(!1)},F=function(t){var e,r=(t||(null===(e=window)||void 0===e?void 0:e.event)).buttons;if(S&&0!==r){var n=B.current.x+t.pageX-B.current.x-B.current.delta;n<=0&&(n=0),n+g>=f&&(n=f-g),l({scrollLeft:n/f*(d+2)}),B.current.x=t.pageX}else S&&k(!1)},L=function(){var t=Object(Y.b)(a.current).top,e=t+a.current.offsetHeight,r=document.documentElement.scrollTop+window.innerHeight;e-Object(p.a)()<=r||t>=r-u?C((function(t){return Object(i.a)(Object(i.a)({},t),{},{isHiddenScrollBar:!0})})):C((function(t){return Object(i.a)(Object(i.a)({},t),{},{isHiddenScrollBar:!1})}))},I=function(t){C((function(e){return Object(i.a)(Object(i.a)({},e),{},{scrollLeft:t/d*f||0})}))};return A.useImperativeHandle(e,(function(){return{setScrollLeft:I}})),A.useEffect((function(){var t=Object(W.a)(document.body,"mouseup",T,!1),e=Object(W.a)(document.body,"mousemove",F,!1);return L(),function(){t.remove(),e.remove()}}),[g,S]),A.useEffect((function(){var t=Object(W.a)(window,"scroll",L,!1),e=Object(W.a)(window,"resize",L,!1);return function(){t.remove(),e.remove()}}),[]),A.useEffect((function(){w.isHiddenScrollBar||C((function(t){var e,r;return Object(i.a)(Object(i.a)({},t),{},{scrollLeft:a.current.scrollLeft/(null===(e=a.current)||void 0===e?void 0:e.scrollWidth)*(null===(r=a.current)||void 0===r?void 0:r.clientWidth)})}))}),[w.isHiddenScrollBar]),d<=f||!g||w.isHiddenScrollBar?null:A.createElement("div",{style:{height:Object(p.a)(),width:f,bottom:u},className:"".concat(h,"-sticky-scroll")},A.createElement("div",{onMouseDown:function(t){t.persist(),B.current.delta=t.pageX-w.scrollLeft,B.current.x=0,k(!0),t.preventDefault()},ref:m,className:c()("".concat(h,"-sticky-scroll-bar"),Object(n.a)({},"".concat(h,"-sticky-scroll-bar-active"),S)),style:{width:"".concat(g,"px"),transform:"translate3d(".concat(w.scrollLeft,"px, 0, 0)")}}))}));var q=[],J={},Z="rc-table-internal-hook",$=A.memo((function(t){return t.children}),(function(t,e){return!!h()(t.props,e.props)&&(t.pingLeft!==e.pingLeft||t.pingRight!==e.pingRight)}));function tt(t){var e,r=t.prefixCls,l=t.className,u=t.rowClassName,h=t.style,g=t.data,m=t.rowKey,v=t.scroll,y=t.tableLayout,w=t.direction,x=t.title,E=t.footer,F=t.summary,_=t.id,U=t.showHeader,O=t.components,Q=t.emptyText,M=t.onRow,H=t.onHeaderRow,N=t.internalHooks,W=t.transformColumns,Y=t.internalRefs,tt=t.sticky,et=g||q,rt=!!et.length,nt=A.useState(0),it=Object(s.a)(nt,2),ot=it[0],at=it[1];A.useEffect((function(){at(Object(p.a)())}));var st,At,lt,ct=A.useMemo((function(){return Object(B.c)(O,{})}),[O]),ut=A.useCallback((function(t,e){return Object(B.b)(ct,t)||e}),[ct]),ht=A.useMemo((function(){return"function"==typeof m?m:function(t){return t&&t[m]}}),[m]),dt=Object(k.c)(t),ft=dt.expandIcon,pt=dt.expandedRowKeys,gt=dt.defaultExpandedRowKeys,mt=dt.defaultExpandAllRows,vt=dt.expandedRowRender,yt=dt.onExpand,wt=dt.onExpandedRowsChange,bt=dt.expandRowByClick,Ct=dt.rowExpandable,Bt=dt.expandIconColumnIndex,xt=dt.expandedRowClassName,Et=dt.childrenColumnName,St=dt.indentSize,kt=ft||z,Tt=Et||"children",Ft=A.useMemo((function(){return vt?"row":!!(t.expandable&&N===Z&&t.expandable.__PARENT_RENDER_ICON__||et.some((function(t){return t&&"object"===Object(a.a)(t)&&t[Tt]})))&&"nest"}),[!!vt,et]),Lt=A.useState((function(){return gt||(mt?function(t,e,r){var n=[];return function t(i){(i||[]).forEach((function(i,o){n.push(e(i,o)),t(i[r])}))}(t),n}(et,ht,Tt):[])})),It=Object(s.a)(Lt,2),_t=It[0],Ut=It[1],Ot=A.useMemo((function(){return new Set(pt||_t||[])}),[pt,_t]),Dt=A.useCallback((function(t){var e,r=ht(t,et.indexOf(t)),n=Ot.has(r);n?(Ot.delete(r),e=Object(o.a)(Ot)):e=[].concat(Object(o.a)(Ot),[r]),Ut(e),yt&&yt(!n,t),wt&&wt(e)}),[ht,Ot,et,yt,wt]),Qt=A.useState(0),Mt=Object(s.a)(Qt,2),Rt=Mt[0],Pt=Mt[1],Ht=Object(P.b)(Object(i.a)(Object(i.a)(Object(i.a)({},t),dt),{},{expandable:!!vt,expandedKeys:Ot,getRowKey:ht,onTriggerExpand:Dt,expandIcon:kt,expandIconColumnIndex:Bt,direction:w}),N===Z?W:null),Nt=Object(s.a)(Ht,2),Kt=Nt[0],jt=Nt[1],Gt=A.useMemo((function(){return{columns:Kt,flattenColumns:jt}}),[Kt,jt]),Vt=A.useRef(),zt=A.useRef(),Wt=A.useRef(),Yt=A.useState(!1),Xt=Object(s.a)(Yt,2),qt=Xt[0],Jt=Xt[1],Zt=A.useState(!1),$t=Object(s.a)(Zt,2),te=$t[0],ee=$t[1],re=K(new Map),ne=Object(s.a)(re,2),ie=ne[0],oe=ne[1],ae=Object(B.a)(jt).map((function(t){return ie.get(t)})),se=A.useMemo((function(){return ae}),[ae.join("_")]),Ae=j(se,jt.length,w),le=v&&Object(B.d)(v.y),ce=v&&Object(B.d)(v.x),ue=ce&&jt.some((function(t){return t.fixed})),he=A.useRef(),de=function(t,e){return A.useMemo((function(){var r=!!t;return{isSticky:r,stickyClassName:r?"".concat(e,"-sticky-header"):"",offsetHeader:"object"===Object(a.a)(t)&&t.offsetHeader||0,offsetScroll:"object"===Object(a.a)(t)&&t.offsetScroll||0}}),[t,e])}(tt,r),fe=de.isSticky,pe=de.offsetHeader,ge=de.offsetScroll,me=de.stickyClassName;le&&(At={overflowY:"scroll",maxHeight:v.y}),ce&&(st={overflowX:"auto"},le||(At={overflowY:"hidden"}),lt={width:!0===v.x?"auto":v.x,minWidth:"100%"});var ve=A.useCallback((function(t,e){oe((function(r){var n=new Map(r);return n.set(t,e),n}))}),[]),ye=function(t){var e=Object(A.useRef)(t),r=Object(A.useRef)(null);function n(){window.clearTimeout(r.current)}return Object(A.useEffect)((function(){return n}),[]),[function(t){e.current=t,n(),r.current=window.setTimeout((function(){e.current=null,r.current=null}),100)},function(){return e.current}]}(null),we=Object(s.a)(ye,2),be=we[0],Ce=we[1];function Be(t,e){e&&("function"==typeof e?e(t):e.scrollLeft!==t&&(e.scrollLeft=t))}var xe=function(t){var e,r=t.currentTarget,n=t.scrollLeft,i="number"==typeof n?n:r.scrollLeft,o=r||J;Ce()&&Ce()!==o||(be(o),Be(i,zt.current),Be(i,Wt.current),Be(i,null===(e=he.current)||void 0===e?void 0:e.setScrollLeft));if(r){var a=r.scrollWidth,s=r.clientWidth;Jt(i>0),ee(i<a-s)}},Ee=function(){Wt.current&&xe({currentTarget:Wt.current})};A.useEffect((function(){return Ee}),[]),A.useEffect((function(){ce&&Ee()}),[ce]),A.useEffect((function(){N===Z&&Y&&(Y.body.current=Wt.current)}));var Se,ke,Te=ut(["table"],"table"),Fe=A.useMemo((function(){return y||(ue?"max-content"===v.x?"auto":"fixed":le||jt.some((function(t){return t.ellipsis}))?"fixed":"auto")}),[le,ue,jt,y]),Le={colWidths:se,columCount:jt.length,stickyOffsets:Ae,onHeaderRow:H,fixHeader:le},Ie=A.useMemo((function(){return rt?null:"function"==typeof Q?Q():Q}),[rt,Q]),_e=A.createElement(R,{data:et,measureColumnWidth:le||ce||fe,expandedKeys:Ot,rowExpandable:Ct,getRowKey:ht,onRow:M,emptyNode:Ie,childrenColumnName:Tt}),Ue=A.createElement(T,{colWidths:jt.map((function(t){return t.width})),columns:jt}),Oe=F&&A.createElement(V.b,null,F(et)),De=ut(["body"]);le||fe?("function"==typeof De?(ke=De(et,{scrollbarSize:ot,ref:Wt,onScroll:xe}),Le.colWidths=jt.map((function(t,e){var r=t.width,n=e===Kt.length-1?r-ot:r;return"number"!=typeof n||Number.isNaN(n)?(Object(d.a)(!1,"When use `components.body` with render props. Each column should have a fixed value."),0):n}))):ke=A.createElement("div",{style:Object(i.a)(Object(i.a)({},st),At),onScroll:xe,ref:Wt,className:c()("".concat(r,"-body"))},A.createElement(Te,{style:Object(i.a)(Object(i.a)({},lt),{},{tableLayout:Fe})},Ue,_e,Oe),fe&&A.createElement(X,{ref:he,offsetScroll:ge,scrollBodyRef:Wt,onScroll:xe})),Se=A.createElement(A.Fragment,null,!1!==U&&A.createElement(L,Object.assign({noData:!et.length},Le,Gt,{direction:w,offsetHeader:pe,stickyClassName:me,ref:zt,onScroll:xe})),ke)):Se=A.createElement("div",{style:Object(i.a)(Object(i.a)({},st),At),className:c()("".concat(r,"-content")),onScroll:xe,ref:Wt},A.createElement(Te,{style:Object(i.a)(Object(i.a)({},lt),{},{tableLayout:Fe})},Ue,!1!==U&&A.createElement(S,Object.assign({},Le,Gt)),_e,Oe));var Qe=Object(k.b)(t),Me=A.createElement("div",Object.assign({className:c()(r,l,(e={},Object(n.a)(e,"".concat(r,"-rtl"),"rtl"===w),Object(n.a)(e,"".concat(r,"-ping-left"),qt),Object(n.a)(e,"".concat(r,"-ping-right"),te),Object(n.a)(e,"".concat(r,"-layout-fixed"),"fixed"===y),Object(n.a)(e,"".concat(r,"-fixed-header"),le),Object(n.a)(e,"".concat(r,"-fixed-column"),ue),Object(n.a)(e,"".concat(r,"-scroll-horizontal"),ce),Object(n.a)(e,"".concat(r,"-has-fix-left"),jt[0]&&jt[0].fixed),Object(n.a)(e,"".concat(r,"-has-fix-right"),jt[jt.length-1]&&"right"===jt[jt.length-1].fixed),e)),style:h,id:_,ref:Vt},Qe),A.createElement($,{pingLeft:qt,pingRight:te,props:Object(i.a)(Object(i.a)({},t),{},{stickyOffsets:Ae,mergedExpandedKeys:Ot})},x&&A.createElement(G,{className:"".concat(r,"-title")},x(et)),A.createElement("div",{className:"".concat(r,"-container")},Se),E&&A.createElement(G,{className:"".concat(r,"-footer")},E(et))));ce&&(Me=A.createElement(f.a,{onResize:function(t){var e=t.width;Ee(),Pt(Vt.current?Vt.current.offsetWidth:e)}},Me));var Re=A.useMemo((function(){return{prefixCls:r,getComponent:ut,scrollbarSize:ot,direction:w,fixedInfoList:jt.map((function(t,e){return C(e,e,jt,Ae,w)})),isSticky:fe}}),[r,ut,ot,w,jt,Ae,w,fe]),Pe=A.useMemo((function(){return Object(i.a)(Object(i.a)({},Gt),{},{tableLayout:Fe,rowClassName:u,expandedRowClassName:xt,componentWidth:Rt,fixHeader:le,fixColumn:ue,horizonScroll:ce,expandIcon:kt,expandableType:Ft,expandRowByClick:bt,expandedRowRender:vt,onTriggerExpand:Dt,expandIconColumnIndex:Bt,indentSize:St})}),[Gt,Fe,u,xt,Rt,le,ue,ce,kt,Ft,bt,vt,Dt,Bt,St]),He=A.useMemo((function(){return{onColumnResize:ve}}),[ve]);return A.createElement(b.a.Provider,{value:Re},A.createElement(I.Provider,{value:Pe},A.createElement(D.Provider,{value:He},Me)))}tt.Column=m.a,tt.ColumnGroup=g.a,tt.Summary=V.a,tt.defaultProps={rowKey:"key",prefixCls:"rc-table",emptyText:function(){return"No Data"}};e.b=tt},wOnQ:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/html2canvas/dist/html2canvas.js ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){
|
|
|
/*!
|
|
|
* html2canvas 1.4.1 <https://html2canvas.hertzen.com>
|
|
|
* Copyright (c) 2022 Niklas von Hertzen <https://hertzen.com>
|
|
|
* Released under MIT License
|
|
|
*/
|
|
|
t.exports=function(){"use strict";
|
|
|
/*! *****************************************************************************
|
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
|
purpose with or without fee is hereby granted.
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
|
***************************************************************************** */var t=function(e,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])})(e,r)};function e(e,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}var r=function(){return(r=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++)for(var i in e=arguments[r])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)};function n(t,e,r,n){return new(r||(r=Promise))((function(i,o){function a(t){try{A(n.next(t))}catch(t){o(t)}}function s(t){try{A(n.throw(t))}catch(t){o(t)}}function A(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(a,s)}A((n=n.apply(t,e||[])).next())}))}function i(t,e){var r,n,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(i=2&o[0]?n.return:o[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;switch(n=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,n=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=e.call(t,a)}catch(t){o=[6,t],n=0}finally{r=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}function o(t,e,r){if(r||2===arguments.length)for(var n,i=0,o=e.length;i<o;i++)!n&&i in e||(n||(n=Array.prototype.slice.call(e,0,i)),n[i]=e[i]);return t.concat(n||e)}for(var a=function(){function t(t,e,r,n){this.left=t,this.top=e,this.width=r,this.height=n}return t.prototype.add=function(e,r,n,i){return new t(this.left+e,this.top+r,this.width+n,this.height+i)},t.fromClientRect=function(e,r){return new t(r.left+e.windowBounds.left,r.top+e.windowBounds.top,r.width,r.height)},t.fromDOMRectList=function(e,r){var n=Array.from(r).find((function(t){return 0!==t.width}));return n?new t(n.left+e.windowBounds.left,n.top+e.windowBounds.top,n.width,n.height):t.EMPTY},t.EMPTY=new t(0,0,0,0),t}(),s=function(t,e){return a.fromClientRect(t,e.getBoundingClientRect())},A=function(t){for(var e=[],r=0,n=t.length;r<n;){var i=t.charCodeAt(r++);if(i>=55296&&i<=56319&&r<n){var o=t.charCodeAt(r++);56320==(64512&o)?e.push(((1023&i)<<10)+(1023&o)+65536):(e.push(i),r--)}else e.push(i)}return e},l=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if(String.fromCodePoint)return String.fromCodePoint.apply(String,t);var r=t.length;if(!r)return"";for(var n=[],i=-1,o="";++i<r;){var a=t[i];a<=65535?n.push(a):(a-=65536,n.push(55296+(a>>10),a%1024+56320)),(i+1===r||n.length>16384)&&(o+=String.fromCharCode.apply(String,n),n.length=0)}return o},c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",u="undefined"==typeof Uint8Array?[]:new Uint8Array(256),h=0;h<c.length;h++)u[c.charCodeAt(h)]=h;for(var d="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",f="undefined"==typeof Uint8Array?[]:new Uint8Array(256),p=0;p<d.length;p++)f[d.charCodeAt(p)]=p;for(var g=function(t,e,r){return t.slice?t.slice(e,r):new Uint16Array(Array.prototype.slice.call(t,e,r))},m=function(){function t(t,e,r,n,i,o){this.initialValue=t,this.errorValue=e,this.highStart=r,this.highValueIndex=n,this.index=i,this.data=o}return t.prototype.get=function(t){var e;if(t>=0){if(t<55296||t>56319&&t<=65535)return e=((e=this.index[t>>5])<<2)+(31&t),this.data[e];if(t<=65535)return e=((e=this.index[2048+(t-55296>>5)])<<2)+(31&t),this.data[e];if(t<this.highStart)return e=2080+(t>>11),e=this.index[e],e+=t>>5&63,e=((e=this.index[e])<<2)+(31&t),this.data[e];if(t<=1114111)return this.data[this.highValueIndex]}return this.errorValue},t}(),v="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",y="undefined"==typeof Uint8Array?[]:new Uint8Array(256),w=0;w<v.length;w++)y[v.charCodeAt(w)]=w;var b=10,C=13,B=15,x=17,E=18,S=19,k=20,T=21,F=22,L=24,I=25,_=26,U=27,O=28,D=30,Q=32,M=33,R=34,P=35,H=37,N=38,K=39,j=40,G=42,V=[9001,65288],z=function(t,e){var r,n,i,o=function(t){var e,r,n,i,o,a=.75*t.length,s=t.length,A=0;"="===t[t.length-1]&&(a--,"="===t[t.length-2]&&a--);var l="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&&void 0!==Uint8Array.prototype.slice?new ArrayBuffer(a):new Array(a),c=Array.isArray(l)?l:new Uint8Array(l);for(e=0;e<s;e+=4)r=f[t.charCodeAt(e)],n=f[t.charCodeAt(e+1)],i=f[t.charCodeAt(e+2)],o=f[t.charCodeAt(e+3)],c[A++]=r<<2|n>>4,c[A++]=(15&n)<<4|i>>2,c[A++]=(3&i)<<6|63&o;return l}(t),a=Array.isArray(o)?function(t){for(var e=t.length,r=[],n=0;n<e;n+=4)r.push(t[n+3]<<24|t[n+2]<<16|t[n+1]<<8|t[n]);return r}(o):new Uint32Array(o),s=Array.isArray(o)?function(t){for(var e=t.length,r=[],n=0;n<e;n+=2)r.push(t[n+1]<<8|t[n]);return r}(o):new Uint16Array(o),A=g(s,12,a[4]/2),l=2===a[5]?g(s,(24+a[4])/2):(r=a,n=Math.ceil((24+a[4])/4),r.slice?r.slice(n,i):new Uint32Array(Array.prototype.slice.call(r,n,i)));return new m(a[0],a[1],a[2],a[3],A,l)}("KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF8AZwBgAGgAcQB5AHUAfQCFAI0AlQCdAKIAqgCyALoAYABoAGAAaABgAGgAwgDKAGAAaADGAM4A0wDbAOEA6QDxAPkAAQEJAQ8BFwF1AH0AHAEkASwBNAE6AUIBQQFJAVEBWQFhAWgBcAF4ATAAgAGGAY4BlQGXAZ8BpwGvAbUBvQHFAc0B0wHbAeMB6wHxAfkBAQIJAvEBEQIZAiECKQIxAjgCQAJGAk4CVgJeAmQCbAJ0AnwCgQKJApECmQKgAqgCsAK4ArwCxAIwAMwC0wLbAjAA4wLrAvMC+AIAAwcDDwMwABcDHQMlAy0DNQN1AD0DQQNJA0kDSQNRA1EDVwNZA1kDdQB1AGEDdQBpA20DdQN1AHsDdQCBA4kDkQN1AHUAmQOhA3UAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AKYDrgN1AHUAtgO+A8YDzgPWAxcD3gPjA+sD8wN1AHUA+wMDBAkEdQANBBUEHQQlBCoEFwMyBDgEYABABBcDSARQBFgEYARoBDAAcAQzAXgEgASIBJAEdQCXBHUAnwSnBK4EtgS6BMIEyAR1AHUAdQB1AHUAdQCVANAEYABgAGAAYABgAGAAYABgANgEYADcBOQEYADsBPQE/AQEBQwFFAUcBSQFLAU0BWQEPAVEBUsFUwVbBWAAYgVgAGoFcgV6BYIFigWRBWAAmQWfBaYFYABgAGAAYABgAKoFYACxBbAFuQW6BcEFwQXHBcEFwQXPBdMF2wXjBeoF8gX6BQIGCgYSBhoGIgYqBjIGOgZgAD4GRgZMBmAAUwZaBmAAYABgAGAAYABgAGAAYABgAGAAYABgAGIGYABpBnAGYABgAGAAYABgAGAAYABgAGAAYAB4Bn8GhQZgAGAAYAB1AHcDFQSLBmAAYABgAJMGdQA9A3UAmwajBqsGqwaVALMGuwbDBjAAywbSBtIG1QbSBtIG0gbSBtIG0gbdBuMG6wbzBvsGAwcLBxMHAwcbByMHJwcsBywHMQcsB9IGOAdAB0gHTgfSBkgHVgfSBtIG0gbSBtIG0gbSBtIG0gbSBiwHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdgAGAALAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdbB2MHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB2kH0gZwB64EdQB1AHUAdQB1AHUAdQB1AHUHfQdgAIUHjQd1AHUAlQedB2AAYAClB6sHYACzB7YHvgfGB3UAzgfWBzMB3gfmB1EB7gf1B/0HlQENAQUIDQh1ABUIHQglCBcDLQg1CD0IRQhNCEEDUwh1AHUAdQBbCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIcAh3CHoIMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIgggwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAALAcsBywHLAcsBywHLAcsBywHLAcsB4oILAcsB44I0gaWCJ4Ipgh1AHUAqgiyCHUAdQB1AHUAdQB1AHUAdQB1AHUAtwh8AXUAvwh1AMUIyQjRCNkI4AjoCHUAdQB1AO4I9gj+CAYJDgkTCS0HGwkjCYIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiAAIAAAAFAAYABgAGIAXwBgAHEAdQBFAJUAogCyAKAAYABgAEIA4ABGANMA4QDxAMEBDwE1AFwBLAE6AQEBUQF4QkhCmEKoQrhCgAHIQsAB0MLAAcABwAHAAeDC6ABoAHDCwMMAAcABwAHAAdDDGMMAAcAB6MM4wwjDWMNow3jDaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAEjDqABWw6bDqABpg6gAaABoAHcDvwOPA+gAaABfA/8DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DpcPAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcAB9cPKwkyCToJMAB1AHUAdQBCCUoJTQl1AFUJXAljCWcJawkwADAAMAAwAHMJdQB2CX4JdQCECYoJjgmWCXUAngkwAGAAYABxAHUApgn3A64JtAl1ALkJdQDACTAAMAAwADAAdQB1AHUAdQB1AHUAdQB1AHUAowYNBMUIMAAwADAAMADICcsJ0wnZCRUE4QkwAOkJ8An4CTAAMAB1AAAKvwh1AAgKDwoXCh8KdQAwACcKLgp1ADYKqAmICT4KRgowADAAdQB1AE4KMAB1AFYKdQBeCnUAZQowADAAMAAwADAAMAAwADAAMAAVBHUAbQowADAAdQC5CXUKMAAwAHwBxAijBogEMgF9CoQKiASMCpQKmgqIBKIKqgquCogEDQG2Cr4KxgrLCjAAMADTCtsKCgHjCusK8Qr5CgELMAAwADAAMAB1AIsECQsRC3UANAEZCzAAMAAwADAAMAB1ACELKQswAHUANAExCzkLdQBBC0kLMABRC1kLMAAwADAAMAAwADAAdQBhCzAAMAAwAGAAYABpC3ELdwt/CzAAMACHC4sLkwubC58Lpwt1AK4Ltgt1APsDMAAwADAAMAAwADAAMAAwAL4LwwvLC9IL1wvdCzAAMADlC+kL8Qv5C/8LSQswADAAMAAwADAAMAAwADAAMAAHDDAAMAAwADAAMAAODBYMHgx1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1ACYMMAAwADAAdQB1AHUALgx1AHUAdQB1AHUAdQA2DDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AD4MdQBGDHUAdQB1AHUAdQB1AEkMdQB1AHUAdQB1AFAMMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQBYDHUAdQB1AF8MMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUA+wMVBGcMMAAwAHwBbwx1AHcMfwyHDI8MMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAYABgAJcMMAAwADAAdQB1AJ8MlQClDDAAMACtDCwHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB7UMLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AA0EMAC9DDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAsBywHLAcsBywHLAcsBywHLQcwAMEMyAwsBywHLAcsBywHLAcsBywHLAcsBywHzAwwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1ANQM2QzhDDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMABgAGAAYABgAGAAYABgAOkMYADxDGAA+AwADQYNYABhCWAAYAAODTAAMAAwADAAFg1gAGAAHg37AzAAMAAwADAAYABgACYNYAAsDTQNPA1gAEMNPg1LDWAAYABgAGAAYABgAGAAYABgAGAAUg1aDYsGVglhDV0NcQBnDW0NdQ15DWAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAlQCBDZUAiA2PDZcNMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAnw2nDTAAMAAwADAAMAAwAHUArw23DTAAMAAwADAAMAAwADAAMAAwADAAMAB1AL8NMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAB1AHUAdQB1AHUAdQDHDTAAYABgAM8NMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAA1w11ANwNMAAwAD0B5A0wADAAMAAwADAAMADsDfQN/A0EDgwOFA4wABsOMAAwADAAMAAwADAAMAAwANIG0gbSBtIG0gbSBtIG0gYjDigOwQUuDsEFMw7SBjoO0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGQg5KDlIOVg7SBtIGXg5lDm0OdQ7SBtIGfQ6EDooOjQ6UDtIGmg6hDtIG0gaoDqwO0ga0DrwO0gZgAGAAYADEDmAAYAAkBtIGzA5gANIOYADaDokO0gbSBt8O5w7SBu8O0gb1DvwO0gZgAGAAxA7SBtIG0gbSBtIGYABgAGAAYAAED2AAsAUMD9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGFA8sBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAccD9IGLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHJA8sBywHLAcsBywHLAccDywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywPLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAc0D9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAccD9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGFA8sBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHPA/SBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gYUD0QPlQCVAJUAMAAwADAAMACVAJUAlQCVAJUAlQCVAEwPMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAA//8EAAQABAAEAAQABAAEAAQABAANAAMAAQABAAIABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQACgATABcAHgAbABoAHgAXABYAEgAeABsAGAAPABgAHABLAEsASwBLAEsASwBLAEsASwBLABgAGAAeAB4AHgATAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABYAGwASAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWAA0AEQAeAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAFAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAJABYAGgAbABsAGwAeAB0AHQAeAE8AFwAeAA0AHgAeABoAGwBPAE8ADgBQAB0AHQAdAE8ATwAXAE8ATwBPABYAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAFAAUABQAFAAUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAB4AHgAeAFAATwBAAE8ATwBPAEAATwBQAFAATwBQAB4AHgAeAB4AHgAeAB0AHQAdAB0AHgAdAB4ADgBQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgBQAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAJAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAkACQAJAAkACQAJAAkABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAFAAHgAeAB4AKwArAFAAUABQAFAAGABQACsAKwArACsAHgAeAFAAHgBQAFAAUAArAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUAAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAYAA0AKwArAB4AHgAbACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAB4ABAAEAB4ABAAEABMABAArACsAKwArACsAKwArACsAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAKwArACsAKwBWAFYAVgBWAB4AHgArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AGgAaABoAGAAYAB4AHgAEAAQABAAEAAQABAAEAAQABAAEAAQAEwAEACsAEwATAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABLAEsASwBLAEsASwBLAEsASwBLABoAGQAZAB4AUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABMAUAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABABQAFAABAAEAB4ABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUAAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAFAABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQAUABQAB4AHgAYABMAUAArACsABAAbABsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAFAABAAEAAQABAAEAFAABAAEAAQAUAAEAAQABAAEAAQAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArACsAHgArAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAUAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEAA0ADQBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUAArACsAKwBQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABABQACsAKwArACsAKwArACsAKwAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUAAaABoAUABQAFAAUABQAEwAHgAbAFAAHgAEACsAKwAEAAQABAArAFAAUABQAFAAUABQACsAKwArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQACsAUABQACsAKwAEACsABAAEAAQABAAEACsAKwArACsABAAEACsAKwAEAAQABAArACsAKwAEACsAKwArACsAKwArACsAUABQAFAAUAArAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLAAQABABQAFAAUAAEAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAArACsAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AGwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAKwArACsAKwArAAQABAAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAAQAUAArAFAAUABQAFAAUABQACsAKwArAFAAUABQACsAUABQAFAAUAArACsAKwBQAFAAKwBQACsAUABQACsAKwArAFAAUAArACsAKwBQAFAAUAArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArAAQABAAEAAQABAArACsAKwAEAAQABAArAAQABAAEAAQAKwArAFAAKwArACsAKwArACsABAArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAHgAeAB4AHgAeAB4AGwAeACsAKwArACsAKwAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAUABQAFAAKwArACsAKwArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwAOAFAAUABQAFAAUABQAFAAHgBQAAQABAAEAA4AUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAKwArAAQAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAKwArACsAKwArACsAUAArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAFAABAAEAAQABAAEAAQABAArAAQABAAEACsABAAEAAQABABQAB4AKwArACsAKwBQAFAAUAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQABoAUABQAFAAUABQAFAAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQACsAUAArACsAUABQAFAAUABQAFAAUAArACsAKwAEACsAKwArACsABAAEAAQABAAEAAQAKwAEACsABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArAAQABAAeACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAXAAqACoAKgAqACoAKgAqACsAKwArACsAGwBcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAeAEsASwBLAEsASwBLAEsASwBLAEsADQANACsAKwArACsAKwBcAFwAKwBcACsAXABcAFwAXABcACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAXAArAFwAXABcAFwAXABcAFwAXABcAFwAKgBcAFwAKgAqACoAKgAqACoAKgAqACoAXAArACsAXABcAFwAXABcACsAXAArACoAKgAqACoAKgAqACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwBcAFwAXABcAFAADgAOAA4ADgAeAA4ADgAJAA4ADgANAAkAEwATABMAEwATAAkAHgATAB4AHgAeAAQABAAeAB4AHgAeAB4AHgBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQAFAADQAEAB4ABAAeAAQAFgARABYAEQAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAAQABAAEAAQADQAEAAQAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAA0ADQAeAB4AHgAeAB4AHgAEAB4AHgAeAB4AHgAeACsAHgAeAA4ADgANAA4AHgAeAB4AHgAeAAkACQArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgBcAEsASwBLAEsASwBLAEsASwBLAEsADQANAB4AHgAeAB4AXABcAFwAXABcAFwAKgAqACoAKgBcAFwAXABcACoAKgAqAFwAKgAqACoAXABcACoAKgAqACoAKgAqACoAXABcAFwAKgAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqAFwAKgBLAEsASwBLAEsASwBLAEsASwBLACoAKgAqACoAKgAqAFAAUABQAFAAUABQACsAUAArACsAKwArACsAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgBQAFAAUABQAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAKwBQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsABAAEAAQAHgANAB4AHgAeAB4AHgAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUAArACsADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWABEAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQANAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAANAA0AKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUAArAAQABAArACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqAA0ADQAVAFwADQAeAA0AGwBcACoAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwAeAB4AEwATAA0ADQAOAB4AEwATAB4ABAAEAAQACQArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAHgArACsAKwATABMASwBLAEsASwBLAEsASwBLAEsASwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAXABcAFwAXABcACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAXAArACsAKwAqACoAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsAHgAeAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKwAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKwArAAQASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACoAKgAqACoAKgAqACoAXAAqACoAKgAqACoAKgArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABABQAFAAUABQAFAAUABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwANAA0AHgANAA0ADQANAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAEAAQAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwAeAB4AHgAeAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArAA0ADQANAA0ADQBLAEsASwBLAEsASwBLAEsASwBLACsAKwArAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUAAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAAQAUABQAFAAUABQAFAABABQAFAABAAEAAQAUAArACsAKwArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAKwBQACsAUAArAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgBQAB4AHgAeAFAAUABQACsAHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQACsAKwAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQACsAHgAeAB4AHgAeAB4AHgAOAB4AKwANAA0ADQANAA0ADQANAAkADQANAA0ACAAEAAsABAAEAA0ACQANAA0ADAAdAB0AHgAXABcAFgAXABcAFwAWABcAHQAdAB4AHgAUABQAFAANAAEAAQAEAAQABAAEAAQACQAaABoAGgAaABoAGgAaABoAHgAXABcAHQAVABUAHgAeAB4AHgAeAB4AGAAWABEAFQAVABUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ADQAeAA0ADQANAA0AHgANAA0ADQAHAB4AHgAeAB4AKwAEAAQABAAEAAQABAAEAAQABAAEAFAAUAArACsATwBQAFAAUABQAFAAHgAeAB4AFgARAE8AUABPAE8ATwBPAFAAUABQAFAAUAAeAB4AHgAWABEAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArABsAGwAbABsAGwAbABsAGgAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGgAbABsAGwAbABoAGwAbABoAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAHgAeAFAAGgAeAB0AHgBQAB4AGgAeAB4AHgAeAB4AHgAeAB4AHgBPAB4AUAAbAB4AHgBQAFAAUABQAFAAHgAeAB4AHQAdAB4AUAAeAFAAHgBQAB4AUABPAFAAUAAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAHgBQAFAAUABQAE8ATwBQAFAAUABQAFAATwBQAFAATwBQAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAFAAUABQAFAATwBPAE8ATwBPAE8ATwBPAE8ATwBQAFAAUABQAFAAUABQAFAAUAAeAB4AUABQAFAAUABPAB4AHgArACsAKwArAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB4AHQAdAB4AHgAeAB0AHQAeAB4AHQAeAB4AHgAdAB4AHQAbABsAHgAdAB4AHgAeAB4AHQAeAB4AHQAdAB0AHQAeAB4AHQAeAB0AHgAdAB0AHQAdAB0AHQAeAB0AHgAeAB4AHgAeAB0AHQAdAB0AHgAeAB4AHgAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB4AHgAeAB0AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHgAeAB0AHQAdAB0AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAeAB4AHgAdAB4AHgAeAB4AHgAeAB4AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABYAEQAWABEAHgAeAB4AHgAeAB4AHQAeAB4AHgAeAB4AHgAeACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAWABEAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAFAAHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAeAB4AHQAdAB0AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHQAdAB4AHgAeAB4AHQAdAB0AHgAeAB0AHgAeAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlAB4AHQAdAB4AHgAdAB4AHgAeAB4AHQAdAB4AHgAeAB4AJQAlAB0AHQAlAB4AJQAlACUAIAAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAeAB4AHgAeAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHgAdAB0AHQAeAB0AJQAdAB0AHgAdAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAdAB0AHQAdACUAHgAlACUAJQAdACUAJQAdAB0AHQAlACUAHQAdACUAHQAdACUAJQAlAB4AHQAeAB4AHgAeAB0AHQAlAB0AHQAdAB0AHQAdACUAJQAlACUAJQAdACUAJQAgACUAHQAdACUAJQAlACUAJQAlACUAJQAeAB4AHgAlACUAIAAgACAAIAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AFwAXABcAFwAXABcAHgATABMAJQAeAB4AHgAWABEAFgARABYAEQAWABEAFgARABYAEQAWABEATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABYAEQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAWABEAFgARABYAEQAWABEAFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFgARABYAEQAWABEAFgARABYAEQAWABEAFgARABYAEQAWABEAFgARABYAEQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAWABEAFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAEAAQABAAeAB4AKwArACsAKwArABMADQANAA0AUAATAA0AUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUAANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAA0ADQANAA0ADQANAA0ADQAeAA0AFgANAB4AHgAXABcAHgAeABcAFwAWABEAFgARABYAEQAWABEADQANAA0ADQATAFAADQANAB4ADQANAB4AHgAeAB4AHgAMAAwADQANAA0AHgANAA0AFgANAA0ADQANAA0ADQANAA0AHgANAB4ADQANAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArAA0AEQARACUAJQBHAFcAVwAWABEAFgARABYAEQAWABEAFgARACUAJQAWABEAFgARABYAEQAWABEAFQAWABEAEQAlAFcAVwBXAFcAVwBXAFcAVwBXAAQABAAEAAQABAAEACUAVwBXAFcAVwA2ACUAJQBXAFcAVwBHAEcAJQAlACUAKwBRAFcAUQBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFEAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBRAFcAUQBXAFEAVwBXAFcAVwBXAFcAUQBXAFcAVwBXAFcAVwBRAFEAKwArAAQABAAVABUARwBHAFcAFQBRAFcAUQBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBRAFcAVwBXAFcAVwBXAFEAUQBXAFcAVwBXABUAUQBHAEcAVwArACsAKwArACsAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwAlACUAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACsAKwArACsAKwArACsAKwArACsAKwArAFEAUQBRAFEAUQBRAFEAUQBRAFEAUQBRAFEAUQBRAFEAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBPAE8ATwBPAE8ATwBPAE8AJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQAlAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAEcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAADQATAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABLAEsASwBLAEsASwBLAEsASwBLAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAABAAEAAQABAAeAAQABAAEAAQABAAEAAQABAAEAAQAHgBQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUABQAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAeAA0ADQANAA0ADQArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAB4AHgAeAB4AHgAeAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAAQAUABQAFAABABQAFAAUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAeAB4AHgAeAAQAKwArACsAUABQAFAAUABQAFAAHgAeABoAHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAADgAOABMAEwArACsAKwArACsAKwArACsABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwANAA0ASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUAAeAB4AHgBQAA4AUABQAAQAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArAB4AWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYACsAKwArAAQAHgAeAB4AHgAeAB4ADQANAA0AHgAeAB4AHgArAFAASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArAB4AHgBcAFwAXABcAFwAKgBcAFwAXABcAFwAXABcAFwAXABcAEsASwBLAEsASwBLAEsASwBLAEsAXABcAFwAXABcACsAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAFAAUABQAAQAUABQAFAAUABQAFAAUABQAAQABAArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAHgANAA0ADQBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAXAAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAKgAqACoAXABcACoAKgBcAFwAXABcAFwAKgAqAFwAKgBcACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcACoAKgBQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAA0ADQBQAFAAUAAEAAQAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQADQAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAVABVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBUAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVACsAKwArACsAKwArACsAKwArACsAKwArAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAKwArACsAKwBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAKwArACsAKwAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAKwArACsAKwArAFYABABWAFYAVgBWAFYAVgBWAFYAVgBWAB4AVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgArAFYAVgBWAFYAVgArAFYAKwBWAFYAKwBWAFYAKwBWAFYAVgBWAFYAVgBWAFYAVgBWAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAEQAWAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAaAB4AKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAGAARABEAGAAYABMAEwAWABEAFAArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACUAJQAlACUAJQAWABEAFgARABYAEQAWABEAFgARABYAEQAlACUAFgARACUAJQAlACUAJQAlACUAEQAlABEAKwAVABUAEwATACUAFgARABYAEQAWABEAJQAlACUAJQAlACUAJQAlACsAJQAbABoAJQArACsAKwArAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAcAKwATACUAJQAbABoAJQAlABYAEQAlACUAEQAlABEAJQBXAFcAVwBXAFcAVwBXAFcAVwBXABUAFQAlACUAJQATACUAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXABYAJQARACUAJQAlAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAWACUAEQAlABYAEQARABYAEQARABUAVwBRAFEAUQBRAFEAUQBRAFEAUQBRAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAEcARwArACsAVwBXAFcAVwBXAFcAKwArAFcAVwBXAFcAVwBXACsAKwBXAFcAVwBXAFcAVwArACsAVwBXAFcAKwArACsAGgAbACUAJQAlABsAGwArAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAAQAB0AKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsADQANAA0AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAA0AUABQAFAAUAArACsAKwArAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwArAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwBQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAUABQAFAAUABQAAQABAAEACsABAAEACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAKwBQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAA0ADQANAA0ADQANAA0ADQAeACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAArACsAKwArAFAAUABQAFAAUAANAA0ADQANAA0ADQAUACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsADQANAA0ADQANAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArAAQABAANACsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAB4AHgAeAB4AHgArACsAKwArACsAKwAEAAQABAAEAAQABAAEAA0ADQAeAB4AHgAeAB4AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsASwBLAEsASwBLAEsASwBLAEsASwANAA0ADQANAFAABAAEAFAAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAeAA4AUAArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAADQANAB4ADQAEAAQABAAEAB4ABAAEAEsASwBLAEsASwBLAEsASwBLAEsAUAAOAFAADQANAA0AKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAANAA0AHgANAA0AHgAEACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAA0AKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsABAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsABAAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAUAArACsAKwArACsAKwAEACsAKwArACsAKwBQAFAAUABQAFAABAAEACsAKwAEAAQABAAEAAQABAAEACsAKwArAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAAQABABQAFAAUABQAA0ADQANAA0AHgBLAEsASwBLAEsASwBLAEsASwBLAA0ADQArAB4ABABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUAAeAFAAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABAAEAAQADgANAA0AEwATAB4AHgAeAA0ADQANAA0ADQANAA0ADQANAA0ADQANAA0ADQANAFAAUABQAFAABAAEACsAKwAEAA0ADQAeAFAAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKwArACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBcAFwADQANAA0AKgBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAKwArAFAAKwArAFAAUABQAFAAUABQAFAAUAArAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQAKwAEAAQAKwArAAQABAAEAAQAUAAEAFAABAAEAA0ADQANACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABABQAA4AUAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAFAABAAEAAQABAAOAB4ADQANAA0ADQAOAB4ABAArACsAKwArACsAKwArACsAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAA0ADQANAFAADgAOAA4ADQANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAAQABAAEAFAADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAOABMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAArACsAKwAEACsABAAEACsABAAEAAQABAAEAAQABABQAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAaABoAGgAaAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABIAEgAQwBDAEMAUABQAFAAUABDAFAAUABQAEgAQwBIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABDAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAJAAkACQAJAAkACQAJABYAEQArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwANAA0AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAANACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAA0ADQANAB4AHgAeAB4AHgAeAFAAUABQAFAADQAeACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAA0AHgAeACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAARwBHABUARwAJACsAKwArACsAKwArACsAKwArACsAKwAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUQBRAFEAKwArACsAKwArACsAKwArACsAKwArACsAKwBRAFEAUQBRACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAHgAEAAQADQAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQABAAEAAQABAAeAB4AHgAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABAAEAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQAHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwBQAFAAKwArAFAAKwArAFAAUAArACsAUABQAFAAUAArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAUAArAFAAUABQAFAAUABQAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAHgAeAFAAUABQAFAAUAArAFAAKwArACsAUABQAFAAUABQAFAAUAArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeACsAKwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4ABAAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAHgAeAA0ADQANAA0AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArAAQABAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwBQAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArABsAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAB4AHgAeAB4ABAAEAAQABAAEAAQABABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArABYAFgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAGgBQAFAAUAAaAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUAArACsAKwArACsAKwBQACsAKwArACsAUAArAFAAKwBQACsAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUAArAFAAKwBQACsAUAArAFAAUAArAFAAKwArAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAKwBQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8AJQAlACUAHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB4AHgAeACUAJQAlAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAlACUAJQAlACUAHgAlACUAJQAlACUAIAAgACAAJQAlACAAJQAlACAAIAAgACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACEAIQAhACEAIQAlACUAIAAgACUAJQAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAIAAlACUAJQAlACAAIAAgACUAIAAgACAAJQAlACUAJQAlACUAJQAgACUAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAlAB4AJQAeACUAJQAlACUAJQAgACUAJQAlACUAHgAlAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACAAIAAgACUAJQAlACAAIAAgACAAIAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABcAFwAXABUAFQAVAB4AHgAeAB4AJQAlACUAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAgACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAgACUAJQAgACUAJQAlACUAJQAlACUAJQAgACAAIAAgACAAIAAgACAAJQAlACUAJQAlACUAIAAlACUAJQAlACUAJQAlACUAJQAgACAAIAAgACAAIAAgACAAIAAgACUAJQAgACAAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAgACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAlACAAIAAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAgACAAIAAlACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACUAVwBXACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAA=="),W=[D,36],Y=[1,2,3,5],X=[b,8],q=[U,_],J=Y.concat(X),Z=[N,K,j,R,P],$=[B,C],tt=function(t,e,r,n){var i=n[r];if(Array.isArray(t)?-1!==t.indexOf(i):t===i)for(var o=r;o<=n.length;){if((A=n[++o])===e)return!0;if(A!==b)break}if(i===b)for(o=r;o>0;){var a=n[--o];if(Array.isArray(t)?-1!==t.indexOf(a):t===a)for(var s=r;s<=n.length;){var A;if((A=n[++s])===e)return!0;if(A!==b)break}if(a!==b)break}return!1},et=function(t,e){for(var r=t;r>=0;){var n=e[r];if(n!==b)return n;r--}return 0},rt=function(t,e,r,n,i){if(0===r[n])return"×";var o=n-1;if(Array.isArray(i)&&!0===i[o])return"×";var a=o-1,s=o+1,A=e[o],l=a>=0?e[a]:0,c=e[s];if(2===A&&3===c)return"×";if(-1!==Y.indexOf(A))return"!";if(-1!==Y.indexOf(c))return"×";if(-1!==X.indexOf(c))return"×";if(8===et(o,e))return"÷";if(11===z.get(t[o]))return"×";if((A===Q||A===M)&&11===z.get(t[s]))return"×";if(7===A||7===c)return"×";if(9===A)return"×";if(-1===[b,C,B].indexOf(A)&&9===c)return"×";if(-1!==[x,E,S,L,O].indexOf(c))return"×";if(et(o,e)===F)return"×";if(tt(23,F,o,e))return"×";if(tt([x,E],T,o,e))return"×";if(tt(12,12,o,e))return"×";if(A===b)return"÷";if(23===A||23===c)return"×";if(16===c||16===A)return"÷";if(-1!==[C,B,T].indexOf(c)||14===A)return"×";if(36===l&&-1!==$.indexOf(A))return"×";if(A===O&&36===c)return"×";if(c===k)return"×";if(-1!==W.indexOf(c)&&A===I||-1!==W.indexOf(A)&&c===I)return"×";if(A===U&&-1!==[H,Q,M].indexOf(c)||-1!==[H,Q,M].indexOf(A)&&c===_)return"×";if(-1!==W.indexOf(A)&&-1!==q.indexOf(c)||-1!==q.indexOf(A)&&-1!==W.indexOf(c))return"×";if(-1!==[U,_].indexOf(A)&&(c===I||-1!==[F,B].indexOf(c)&&e[s+1]===I)||-1!==[F,B].indexOf(A)&&c===I||A===I&&-1!==[I,O,L].indexOf(c))return"×";if(-1!==[I,O,L,x,E].indexOf(c))for(var u=o;u>=0;){if((h=e[u])===I)return"×";if(-1===[O,L].indexOf(h))break;u--}if(-1!==[U,_].indexOf(c))for(u=-1!==[x,E].indexOf(A)?a:o;u>=0;){var h;if((h=e[u])===I)return"×";if(-1===[O,L].indexOf(h))break;u--}if(N===A&&-1!==[N,K,R,P].indexOf(c)||-1!==[K,R].indexOf(A)&&-1!==[K,j].indexOf(c)||-1!==[j,P].indexOf(A)&&c===j)return"×";if(-1!==Z.indexOf(A)&&-1!==[k,_].indexOf(c)||-1!==Z.indexOf(c)&&A===U)return"×";if(-1!==W.indexOf(A)&&-1!==W.indexOf(c))return"×";if(A===L&&-1!==W.indexOf(c))return"×";if(-1!==W.concat(I).indexOf(A)&&c===F&&-1===V.indexOf(t[s])||-1!==W.concat(I).indexOf(c)&&A===E)return"×";if(41===A&&41===c){for(var d=r[o],f=1;d>0&&41===e[--d];)f++;if(f%2!=0)return"×"}return A===Q&&c===M?"×":"÷"},nt=function(t,e){e||(e={lineBreak:"normal",wordBreak:"normal"});var r=function(t,e){void 0===e&&(e="strict");var r=[],n=[],i=[];return t.forEach((function(t,o){var a=z.get(t);if(a>50?(i.push(!0),a-=50):i.push(!1),-1!==["normal","auto","loose"].indexOf(e)&&-1!==[8208,8211,12316,12448].indexOf(t))return n.push(o),r.push(16);if(4===a||11===a){if(0===o)return n.push(o),r.push(D);var s=r[o-1];return-1===J.indexOf(s)?(n.push(n[o-1]),r.push(s)):(n.push(o),r.push(D))}return n.push(o),31===a?r.push("strict"===e?T:H):a===G||29===a?r.push(D):43===a?t>=131072&&t<=196605||t>=196608&&t<=262141?r.push(H):r.push(D):void r.push(a)})),[n,r,i]}(t,e.lineBreak),n=r[0],i=r[1],o=r[2];return"break-all"!==e.wordBreak&&"break-word"!==e.wordBreak||(i=i.map((function(t){return-1!==[I,D,G].indexOf(t)?H:t}))),[n,i,"keep-all"===e.wordBreak?o.map((function(e,r){return e&&t[r]>=19968&&t[r]<=40959})):void 0]},it=function(){function t(t,e,r,n){this.codePoints=t,this.required="!"===e,this.start=r,this.end=n}return t.prototype.slice=function(){return l.apply(void 0,this.codePoints.slice(this.start,this.end))},t}(),ot=function(t){return t>=48&&t<=57},at=function(t){return ot(t)||t>=65&&t<=70||t>=97&&t<=102},st=function(t){return 10===t||9===t||32===t},At=function(t){return function(t){return function(t){return t>=97&&t<=122}(t)||function(t){return t>=65&&t<=90}(t)}(t)||function(t){return t>=128}(t)||95===t},lt=function(t){return At(t)||ot(t)||45===t},ct=function(t){return t>=0&&t<=8||11===t||t>=14&&t<=31||127===t},ut=function(t,e){return 92===t&&10!==e},ht=function(t,e,r){return 45===t?At(e)||ut(e,r):!!At(t)||!(92!==t||!ut(t,e))},dt=function(t,e,r){return 43===t||45===t?!!ot(e)||46===e&&ot(r):ot(46===t?e:t)},ft=function(t){var e=0,r=1;43!==t[e]&&45!==t[e]||(45===t[e]&&(r=-1),e++);for(var n=[];ot(t[e]);)n.push(t[e++]);var i=n.length?parseInt(l.apply(void 0,n),10):0;46===t[e]&&e++;for(var o=[];ot(t[e]);)o.push(t[e++]);var a=o.length,s=a?parseInt(l.apply(void 0,o),10):0;69!==t[e]&&101!==t[e]||e++;var A=1;43!==t[e]&&45!==t[e]||(45===t[e]&&(A=-1),e++);for(var c=[];ot(t[e]);)c.push(t[e++]);var u=c.length?parseInt(l.apply(void 0,c),10):0;return r*(i+s*Math.pow(10,-a))*Math.pow(10,A*u)},pt={type:2},gt={type:3},mt={type:4},vt={type:13},yt={type:8},wt={type:21},bt={type:9},Ct={type:10},Bt={type:11},xt={type:12},Et={type:14},St={type:23},kt={type:1},Tt={type:25},Ft={type:24},Lt={type:26},It={type:27},_t={type:28},Ut={type:29},Ot={type:31},Dt={type:32},Qt=function(){function t(){this._value=[]}return t.prototype.write=function(t){this._value=this._value.concat(A(t))},t.prototype.read=function(){for(var t=[],e=this.consumeToken();e!==Dt;)t.push(e),e=this.consumeToken();return t},t.prototype.consumeToken=function(){var t=this.consumeCodePoint();switch(t){case 34:return this.consumeStringToken(34);case 35:var e=this.peekCodePoint(0),r=this.peekCodePoint(1),n=this.peekCodePoint(2);if(lt(e)||ut(r,n)){var i=ht(e,r,n)?2:1;return{type:5,value:this.consumeName(),flags:i}}break;case 36:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),vt;break;case 39:return this.consumeStringToken(39);case 40:return pt;case 41:return gt;case 42:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Et;break;case 43:if(dt(t,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(t),this.consumeNumericToken();break;case 44:return mt;case 45:var o=t,a=this.peekCodePoint(0),s=this.peekCodePoint(1);if(dt(o,a,s))return this.reconsumeCodePoint(t),this.consumeNumericToken();if(ht(o,a,s))return this.reconsumeCodePoint(t),this.consumeIdentLikeToken();if(45===a&&62===s)return this.consumeCodePoint(),this.consumeCodePoint(),Ft;break;case 46:if(dt(t,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(t),this.consumeNumericToken();break;case 47:if(42===this.peekCodePoint(0))for(this.consumeCodePoint();;){var A=this.consumeCodePoint();if(42===A&&47===(A=this.consumeCodePoint()))return this.consumeToken();if(-1===A)return this.consumeToken()}break;case 58:return Lt;case 59:return It;case 60:if(33===this.peekCodePoint(0)&&45===this.peekCodePoint(1)&&45===this.peekCodePoint(2))return this.consumeCodePoint(),this.consumeCodePoint(),Tt;break;case 64:var c=this.peekCodePoint(0),u=this.peekCodePoint(1),h=this.peekCodePoint(2);if(ht(c,u,h))return{type:7,value:this.consumeName()};break;case 91:return _t;case 92:if(ut(t,this.peekCodePoint(0)))return this.reconsumeCodePoint(t),this.consumeIdentLikeToken();break;case 93:return Ut;case 61:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),yt;break;case 123:return Bt;case 125:return xt;case 117:case 85:var d=this.peekCodePoint(0),f=this.peekCodePoint(1);return 43!==d||!at(f)&&63!==f||(this.consumeCodePoint(),this.consumeUnicodeRangeToken()),this.reconsumeCodePoint(t),this.consumeIdentLikeToken();case 124:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),bt;if(124===this.peekCodePoint(0))return this.consumeCodePoint(),wt;break;case 126:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Ct;break;case-1:return Dt}return st(t)?(this.consumeWhiteSpace(),Ot):ot(t)?(this.reconsumeCodePoint(t),this.consumeNumericToken()):At(t)?(this.reconsumeCodePoint(t),this.consumeIdentLikeToken()):{type:6,value:l(t)}},t.prototype.consumeCodePoint=function(){var t=this._value.shift();return void 0===t?-1:t},t.prototype.reconsumeCodePoint=function(t){this._value.unshift(t)},t.prototype.peekCodePoint=function(t){return t>=this._value.length?-1:this._value[t]},t.prototype.consumeUnicodeRangeToken=function(){for(var t=[],e=this.consumeCodePoint();at(e)&&t.length<6;)t.push(e),e=this.consumeCodePoint();for(var r=!1;63===e&&t.length<6;)t.push(e),e=this.consumeCodePoint(),r=!0;if(r)return{type:30,start:parseInt(l.apply(void 0,t.map((function(t){return 63===t?48:t}))),16),end:parseInt(l.apply(void 0,t.map((function(t){return 63===t?70:t}))),16)};var n=parseInt(l.apply(void 0,t),16);if(45===this.peekCodePoint(0)&&at(this.peekCodePoint(1))){this.consumeCodePoint(),e=this.consumeCodePoint();for(var i=[];at(e)&&i.length<6;)i.push(e),e=this.consumeCodePoint();return{type:30,start:n,end:parseInt(l.apply(void 0,i),16)}}return{type:30,start:n,end:n}},t.prototype.consumeIdentLikeToken=function(){var t=this.consumeName();return"url"===t.toLowerCase()&&40===this.peekCodePoint(0)?(this.consumeCodePoint(),this.consumeUrlToken()):40===this.peekCodePoint(0)?(this.consumeCodePoint(),{type:19,value:t}):{type:20,value:t}},t.prototype.consumeUrlToken=function(){var t=[];if(this.consumeWhiteSpace(),-1===this.peekCodePoint(0))return{type:22,value:""};var e=this.peekCodePoint(0);if(39===e||34===e){var r=this.consumeStringToken(this.consumeCodePoint());return 0===r.type&&(this.consumeWhiteSpace(),-1===this.peekCodePoint(0)||41===this.peekCodePoint(0))?(this.consumeCodePoint(),{type:22,value:r.value}):(this.consumeBadUrlRemnants(),St)}for(;;){var n=this.consumeCodePoint();if(-1===n||41===n)return{type:22,value:l.apply(void 0,t)};if(st(n))return this.consumeWhiteSpace(),-1===this.peekCodePoint(0)||41===this.peekCodePoint(0)?(this.consumeCodePoint(),{type:22,value:l.apply(void 0,t)}):(this.consumeBadUrlRemnants(),St);if(34===n||39===n||40===n||ct(n))return this.consumeBadUrlRemnants(),St;if(92===n){if(!ut(n,this.peekCodePoint(0)))return this.consumeBadUrlRemnants(),St;t.push(this.consumeEscapedCodePoint())}else t.push(n)}},t.prototype.consumeWhiteSpace=function(){for(;st(this.peekCodePoint(0));)this.consumeCodePoint()},t.prototype.consumeBadUrlRemnants=function(){for(;;){var t=this.consumeCodePoint();if(41===t||-1===t)return;ut(t,this.peekCodePoint(0))&&this.consumeEscapedCodePoint()}},t.prototype.consumeStringSlice=function(t){for(var e="";t>0;){var r=Math.min(5e4,t);e+=l.apply(void 0,this._value.splice(0,r)),t-=r}return this._value.shift(),e},t.prototype.consumeStringToken=function(t){for(var e="",r=0;;){var n=this._value[r];if(-1===n||void 0===n||n===t)return{type:0,value:e+=this.consumeStringSlice(r)};if(10===n)return this._value.splice(0,r),kt;if(92===n){var i=this._value[r+1];-1!==i&&void 0!==i&&(10===i?(e+=this.consumeStringSlice(r),r=-1,this._value.shift()):ut(n,i)&&(e+=this.consumeStringSlice(r),e+=l(this.consumeEscapedCodePoint()),r=-1))}r++}},t.prototype.consumeNumber=function(){var t=[],e=4,r=this.peekCodePoint(0);for(43!==r&&45!==r||t.push(this.consumeCodePoint());ot(this.peekCodePoint(0));)t.push(this.consumeCodePoint());r=this.peekCodePoint(0);var n=this.peekCodePoint(1);if(46===r&&ot(n))for(t.push(this.consumeCodePoint(),this.consumeCodePoint()),e=8;ot(this.peekCodePoint(0));)t.push(this.consumeCodePoint());r=this.peekCodePoint(0),n=this.peekCodePoint(1);var i=this.peekCodePoint(2);if((69===r||101===r)&&((43===n||45===n)&&ot(i)||ot(n)))for(t.push(this.consumeCodePoint(),this.consumeCodePoint()),e=8;ot(this.peekCodePoint(0));)t.push(this.consumeCodePoint());return[ft(t),e]},t.prototype.consumeNumericToken=function(){var t=this.consumeNumber(),e=t[0],r=t[1],n=this.peekCodePoint(0),i=this.peekCodePoint(1),o=this.peekCodePoint(2);return ht(n,i,o)?{type:15,number:e,flags:r,unit:this.consumeName()}:37===n?(this.consumeCodePoint(),{type:16,number:e,flags:r}):{type:17,number:e,flags:r}},t.prototype.consumeEscapedCodePoint=function(){var t=this.consumeCodePoint();if(at(t)){for(var e=l(t);at(this.peekCodePoint(0))&&e.length<6;)e+=l(this.consumeCodePoint());st(this.peekCodePoint(0))&&this.consumeCodePoint();var r=parseInt(e,16);return 0===r||function(t){return t>=55296&&t<=57343}(r)||r>1114111?65533:r}return-1===t?65533:t},t.prototype.consumeName=function(){for(var t="";;){var e=this.consumeCodePoint();if(lt(e))t+=l(e);else{if(!ut(e,this.peekCodePoint(0)))return this.reconsumeCodePoint(e),t;t+=l(this.consumeEscapedCodePoint())}}},t}(),Mt=function(){function t(t){this._tokens=t}return t.create=function(e){var r=new Qt;return r.write(e),new t(r.read())},t.parseValue=function(e){return t.create(e).parseComponentValue()},t.parseValues=function(e){return t.create(e).parseComponentValues()},t.prototype.parseComponentValue=function(){for(var t=this.consumeToken();31===t.type;)t=this.consumeToken();if(32===t.type)throw new SyntaxError("Error parsing CSS component value, unexpected EOF");this.reconsumeToken(t);var e=this.consumeComponentValue();do{t=this.consumeToken()}while(31===t.type);if(32===t.type)return e;throw new SyntaxError("Error parsing CSS component value, multiple values found when expecting only one")},t.prototype.parseComponentValues=function(){for(var t=[];;){var e=this.consumeComponentValue();if(32===e.type)return t;t.push(e),t.push()}},t.prototype.consumeComponentValue=function(){var t=this.consumeToken();switch(t.type){case 11:case 28:case 2:return this.consumeSimpleBlock(t.type);case 19:return this.consumeFunction(t)}return t},t.prototype.consumeSimpleBlock=function(t){for(var e={type:t,values:[]},r=this.consumeToken();;){if(32===r.type||zt(r,t))return e;this.reconsumeToken(r),e.values.push(this.consumeComponentValue()),r=this.consumeToken()}},t.prototype.consumeFunction=function(t){for(var e={name:t.value,values:[],type:18};;){var r=this.consumeToken();if(32===r.type||3===r.type)return e;this.reconsumeToken(r),e.values.push(this.consumeComponentValue())}},t.prototype.consumeToken=function(){var t=this._tokens.shift();return void 0===t?Dt:t},t.prototype.reconsumeToken=function(t){this._tokens.unshift(t)},t}(),Rt=function(t){return 15===t.type},Pt=function(t){return 17===t.type},Ht=function(t){return 20===t.type},Nt=function(t){return 0===t.type},Kt=function(t,e){return Ht(t)&&t.value===e},jt=function(t){return 31!==t.type},Gt=function(t){return 31!==t.type&&4!==t.type},Vt=function(t){var e=[],r=[];return t.forEach((function(t){if(4===t.type){if(0===r.length)throw new Error("Error parsing function args, zero tokens for arg");return e.push(r),void(r=[])}31!==t.type&&r.push(t)})),r.length&&e.push(r),e},zt=function(t,e){return 11===e&&12===t.type||28===e&&29===t.type||2===e&&3===t.type},Wt=function(t){return 17===t.type||15===t.type},Yt=function(t){return 16===t.type||Wt(t)},Xt=function(t){return t.length>1?[t[0],t[1]]:[t[0]]},qt={type:17,number:0,flags:4},Jt={type:16,number:50,flags:4},Zt={type:16,number:100,flags:4},$t=function(t,e,r){var n=t[0],i=t[1];return[te(n,e),te(void 0!==i?i:n,r)]},te=function(t,e){if(16===t.type)return t.number/100*e;if(Rt(t))switch(t.unit){case"rem":case"em":return 16*t.number;case"px":default:return t.number}return t.number},ee=function(t,e){if(15===e.type)switch(e.unit){case"deg":return Math.PI*e.number/180;case"grad":return Math.PI/200*e.number;case"rad":return e.number;case"turn":return 2*Math.PI*e.number}throw new Error("Unsupported angle type")},re=function(t){return 15===t.type&&("deg"===t.unit||"grad"===t.unit||"rad"===t.unit||"turn"===t.unit)},ne=function(t){switch(t.filter(Ht).map((function(t){return t.value})).join(" ")){case"to bottom right":case"to right bottom":case"left top":case"top left":return[qt,qt];case"to top":case"bottom":return ie(0);case"to bottom left":case"to left bottom":case"right top":case"top right":return[qt,Zt];case"to right":case"left":return ie(90);case"to top left":case"to left top":case"right bottom":case"bottom right":return[Zt,Zt];case"to bottom":case"top":return ie(180);case"to top right":case"to right top":case"left bottom":case"bottom left":return[Zt,qt];case"to left":case"right":return ie(270)}return 0},ie=function(t){return Math.PI*t/180},oe=function(t,e){if(18===e.type){var r=fe[e.name];if(void 0===r)throw new Error('Attempting to parse an unsupported color function "'+e.name+'"');return r(t,e.values)}if(5===e.type){if(3===e.value.length){var n=e.value.substring(0,1),i=e.value.substring(1,2),o=e.value.substring(2,3);return Ae(parseInt(n+n,16),parseInt(i+i,16),parseInt(o+o,16),1)}if(4===e.value.length){n=e.value.substring(0,1),i=e.value.substring(1,2),o=e.value.substring(2,3);var a=e.value.substring(3,4);return Ae(parseInt(n+n,16),parseInt(i+i,16),parseInt(o+o,16),parseInt(a+a,16)/255)}if(6===e.value.length)return n=e.value.substring(0,2),i=e.value.substring(2,4),o=e.value.substring(4,6),Ae(parseInt(n,16),parseInt(i,16),parseInt(o,16),1);if(8===e.value.length)return n=e.value.substring(0,2),i=e.value.substring(2,4),o=e.value.substring(4,6),a=e.value.substring(6,8),Ae(parseInt(n,16),parseInt(i,16),parseInt(o,16),parseInt(a,16)/255)}if(20===e.type){var s=ge[e.value.toUpperCase()];if(void 0!==s)return s}return ge.TRANSPARENT},ae=function(t){return 0==(255&t)},se=function(t){var e=255&t,r=255&t>>8,n=255&t>>16,i=255&t>>24;return e<255?"rgba("+i+","+n+","+r+","+e/255+")":"rgb("+i+","+n+","+r+")"},Ae=function(t,e,r,n){return(t<<24|e<<16|r<<8|Math.round(255*n)<<0)>>>0},le=function(t,e){if(17===t.type)return t.number;if(16===t.type){var r=3===e?1:255;return 3===e?t.number/100*r:Math.round(t.number/100*r)}return 0},ce=function(t,e){var r=e.filter(Gt);if(3===r.length){var n=r.map(le),i=n[0],o=n[1],a=n[2];return Ae(i,o,a,1)}if(4===r.length){var s=r.map(le),A=(i=s[0],o=s[1],a=s[2],s[3]);return Ae(i,o,a,A)}return 0};function ue(t,e,r){return r<0&&(r+=1),r>=1&&(r-=1),r<1/6?(e-t)*r*6+t:r<.5?e:r<2/3?6*(e-t)*(2/3-r)+t:t}var he,de=function(t,e){var r=e.filter(Gt),n=r[0],i=r[1],o=r[2],a=r[3],s=(17===n.type?ie(n.number):ee(t,n))/(2*Math.PI),A=Yt(i)?i.number/100:0,l=Yt(o)?o.number/100:0,c=void 0!==a&&Yt(a)?te(a,1):1;if(0===A)return Ae(255*l,255*l,255*l,1);var u=l<=.5?l*(A+1):l+A-l*A,h=2*l-u,d=ue(h,u,s+1/3),f=ue(h,u,s),p=ue(h,u,s-1/3);return Ae(255*d,255*f,255*p,c)},fe={hsl:de,hsla:de,rgb:ce,rgba:ce},pe=function(t,e){return oe(t,Mt.create(e).parseComponentValue())},ge={ALICEBLUE:4042850303,ANTIQUEWHITE:4209760255,AQUA:16777215,AQUAMARINE:2147472639,AZURE:4043309055,BEIGE:4126530815,BISQUE:4293182719,BLACK:255,BLANCHEDALMOND:4293643775,BLUE:65535,BLUEVIOLET:2318131967,BROWN:2771004159,BURLYWOOD:3736635391,CADETBLUE:1604231423,CHARTREUSE:2147418367,CHOCOLATE:3530104575,CORAL:4286533887,CORNFLOWERBLUE:1687547391,CORNSILK:4294499583,CRIMSON:3692313855,CYAN:16777215,DARKBLUE:35839,DARKCYAN:9145343,DARKGOLDENROD:3095837695,DARKGRAY:2846468607,DARKGREEN:6553855,DARKGREY:2846468607,DARKKHAKI:3182914559,DARKMAGENTA:2332068863,DARKOLIVEGREEN:1433087999,DARKORANGE:4287365375,DARKORCHID:2570243327,DARKRED:2332033279,DARKSALMON:3918953215,DARKSEAGREEN:2411499519,DARKSLATEBLUE:1211993087,DARKSLATEGRAY:793726975,DARKSLATEGREY:793726975,DARKTURQUOISE:13554175,DARKVIOLET:2483082239,DEEPPINK:4279538687,DEEPSKYBLUE:12582911,DIMGRAY:1768516095,DIMGREY:1768516095,DODGERBLUE:512819199,FIREBRICK:2988581631,FLORALWHITE:4294635775,FORESTGREEN:579543807,FUCHSIA:4278255615,GAINSBORO:3705462015,GHOSTWHITE:4177068031,GOLD:4292280575,GOLDENROD:3668254975,GRAY:2155905279,GREEN:8388863,GREENYELLOW:2919182335,GREY:2155905279,HONEYDEW:4043305215,HOTPINK:4285117695,INDIANRED:3445382399,INDIGO:1258324735,IVORY:4294963455,KHAKI:4041641215,LAVENDER:3873897215,LAVENDERBLUSH:4293981695,LAWNGREEN:2096890111,LEMONCHIFFON:4294626815,LIGHTBLUE:2916673279,LIGHTCORAL:4034953471,LIGHTCYAN:3774873599,LIGHTGOLDENRODYELLOW:4210742015,LIGHTGRAY:3553874943,LIGHTGREEN:2431553791,LIGHTGREY:3553874943,LIGHTPINK:4290167295,LIGHTSALMON:4288707327,LIGHTSEAGREEN:548580095,LIGHTSKYBLUE:2278488831,LIGHTSLATEGRAY:2005441023,LIGHTSLATEGREY:2005441023,LIGHTSTEELBLUE:2965692159,LIGHTYELLOW:4294959359,LIME:16711935,LIMEGREEN:852308735,LINEN:4210091775,MAGENTA:4278255615,MAROON:2147483903,MEDIUMAQUAMARINE:1724754687,MEDIUMBLUE:52735,MEDIUMORCHID:3126187007,MEDIUMPURPLE:2473647103,MEDIUMSEAGREEN:1018393087,MEDIUMSLATEBLUE:2070474495,MEDIUMSPRINGGREEN:16423679,MEDIUMTURQUOISE:1221709055,MEDIUMVIOLETRED:3340076543,MIDNIGHTBLUE:421097727,MINTCREAM:4127193855,MISTYROSE:4293190143,MOCCASIN:4293178879,NAVAJOWHITE:4292783615,NAVY:33023,OLDLACE:4260751103,OLIVE:2155872511,OLIVEDRAB:1804477439,ORANGE:4289003775,ORANGERED:4282712319,ORCHID:3664828159,PALEGOLDENROD:4008225535,PALEGREEN:2566625535,PALETURQUOISE:2951671551,PALEVIOLETRED:3681588223,PAPAYAWHIP:4293907967,PEACHPUFF:4292524543,PERU:3448061951,PINK:4290825215,PLUM:3718307327,POWDERBLUE:2967529215,PURPLE:2147516671,REBECCAPURPLE:1714657791,RED:4278190335,ROSYBROWN:3163525119,ROYALBLUE:1097458175,SADDLEBROWN:2336560127,SALMON:4202722047,SANDYBROWN:4104413439,SEAGREEN:780883967,SEASHELL:4294307583,SIENNA:2689740287,SILVER:3233857791,SKYBLUE:2278484991,SLATEBLUE:1784335871,SLATEGRAY:1887473919,SLATEGREY:1887473919,SNOW:4294638335,SPRINGGREEN:16744447,STEELBLUE:1182971135,TAN:3535047935,TEAL:8421631,THISTLE:3636451583,TOMATO:4284696575,TRANSPARENT:0,TURQUOISE:1088475391,VIOLET:4001558271,WHEAT:4125012991,WHITE:4294967295,WHITESMOKE:4126537215,YELLOW:4294902015,YELLOWGREEN:2597139199},me={name:"background-clip",initialValue:"border-box",prefix:!1,type:1,parse:function(t,e){return e.map((function(t){if(Ht(t))switch(t.value){case"padding-box":return 1;case"content-box":return 2}return 0}))}},ve={name:"background-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},ye=function(t,e){var r=oe(t,e[0]),n=e[1];return n&&Yt(n)?{color:r,stop:n}:{color:r,stop:null}},we=function(t,e){var r=t[0],n=t[t.length-1];null===r.stop&&(r.stop=qt),null===n.stop&&(n.stop=Zt);for(var i=[],o=0,a=0;a<t.length;a++){var s=t[a].stop;if(null!==s){var A=te(s,e);A>o?i.push(A):i.push(o),o=A}else i.push(null)}var l=null;for(a=0;a<i.length;a++){var c=i[a];if(null===c)null===l&&(l=a);else if(null!==l){for(var u=a-l,h=(c-i[l-1])/(u+1),d=1;d<=u;d++)i[l+d-1]=h*d;l=null}}return t.map((function(t,r){return{color:t.color,stop:Math.max(Math.min(1,i[r]/e),0)}}))},be=function(t,e,r){var n="number"==typeof t?t:function(t,e,r){var n=e/2,i=r/2,o=te(t[0],e)-n,a=i-te(t[1],r);return(Math.atan2(a,o)+2*Math.PI)%(2*Math.PI)}(t,e,r),i=Math.abs(e*Math.sin(n))+Math.abs(r*Math.cos(n)),o=e/2,a=r/2,s=i/2,A=Math.sin(n-Math.PI/2)*s,l=Math.cos(n-Math.PI/2)*s;return[i,o-l,o+l,a-A,a+A]},Ce=function(t,e){return Math.sqrt(t*t+e*e)},Be=function(t,e,r,n,i){return[[0,0],[0,e],[t,0],[t,e]].reduce((function(t,e){var o=e[0],a=e[1],s=Ce(r-o,n-a);return(i?s<t.optimumDistance:s>t.optimumDistance)?{optimumCorner:e,optimumDistance:s}:t}),{optimumDistance:i?1/0:-1/0,optimumCorner:null}).optimumCorner},xe=function(t,e){var r=ie(180),n=[];return Vt(e).forEach((function(e,i){if(0===i){var o=e[0];if(20===o.type&&-1!==["top","left","right","bottom"].indexOf(o.value))return void(r=ne(e));if(re(o))return void(r=(ee(t,o)+ie(270))%ie(360))}var a=ye(t,e);n.push(a)})),{angle:r,stops:n,type:1}},Ee=function(t,e){var r=0,n=3,i=[],o=[];return Vt(e).forEach((function(e,a){var s=!0;if(0===a?s=e.reduce((function(t,e){if(Ht(e))switch(e.value){case"center":return o.push(Jt),!1;case"top":case"left":return o.push(qt),!1;case"right":case"bottom":return o.push(Zt),!1}else if(Yt(e)||Wt(e))return o.push(e),!1;return t}),s):1===a&&(s=e.reduce((function(t,e){if(Ht(e))switch(e.value){case"circle":return r=0,!1;case"ellipse":return r=1,!1;case"contain":case"closest-side":return n=0,!1;case"farthest-side":return n=1,!1;case"closest-corner":return n=2,!1;case"cover":case"farthest-corner":return n=3,!1}else if(Wt(e)||Yt(e))return Array.isArray(n)||(n=[]),n.push(e),!1;return t}),s)),s){var A=ye(t,e);i.push(A)}})),{size:n,shape:r,stops:i,position:o,type:2}},Se=function(t,e){if(22===e.type){var r={url:e.value,type:0};return t.cache.addImage(e.value),r}if(18===e.type){var n=ke[e.name];if(void 0===n)throw new Error('Attempting to parse an unsupported image function "'+e.name+'"');return n(t,e.values)}throw new Error("Unsupported image type "+e.type)},ke={"linear-gradient":function(t,e){var r=ie(180),n=[];return Vt(e).forEach((function(e,i){if(0===i){var o=e[0];if(20===o.type&&"to"===o.value)return void(r=ne(e));if(re(o))return void(r=ee(t,o))}var a=ye(t,e);n.push(a)})),{angle:r,stops:n,type:1}},"-moz-linear-gradient":xe,"-ms-linear-gradient":xe,"-o-linear-gradient":xe,"-webkit-linear-gradient":xe,"radial-gradient":function(t,e){var r=0,n=3,i=[],o=[];return Vt(e).forEach((function(e,a){var s=!0;if(0===a){var A=!1;s=e.reduce((function(t,e){if(A)if(Ht(e))switch(e.value){case"center":return o.push(Jt),t;case"top":case"left":return o.push(qt),t;case"right":case"bottom":return o.push(Zt),t}else(Yt(e)||Wt(e))&&o.push(e);else if(Ht(e))switch(e.value){case"circle":return r=0,!1;case"ellipse":return r=1,!1;case"at":return A=!0,!1;case"closest-side":return n=0,!1;case"cover":case"farthest-side":return n=1,!1;case"contain":case"closest-corner":return n=2,!1;case"farthest-corner":return n=3,!1}else if(Wt(e)||Yt(e))return Array.isArray(n)||(n=[]),n.push(e),!1;return t}),s)}if(s){var l=ye(t,e);i.push(l)}})),{size:n,shape:r,stops:i,position:o,type:2}},"-moz-radial-gradient":Ee,"-ms-radial-gradient":Ee,"-o-radial-gradient":Ee,"-webkit-radial-gradient":Ee,"-webkit-gradient":function(t,e){var r=ie(180),n=[],i=1;return Vt(e).forEach((function(e,r){var o=e[0];if(0===r){if(Ht(o)&&"linear"===o.value)return void(i=1);if(Ht(o)&&"radial"===o.value)return void(i=2)}if(18===o.type)if("from"===o.name){var a=oe(t,o.values[0]);n.push({stop:qt,color:a})}else if("to"===o.name)a=oe(t,o.values[0]),n.push({stop:Zt,color:a});else if("color-stop"===o.name){var s=o.values.filter(Gt);if(2===s.length){a=oe(t,s[1]);var A=s[0];Pt(A)&&n.push({stop:{type:16,number:100*A.number,flags:A.flags},color:a})}}})),1===i?{angle:(r+ie(180))%ie(360),stops:n,type:i}:{size:3,shape:0,stops:n,position:[],type:i}}},Te={name:"background-image",initialValue:"none",type:1,prefix:!1,parse:function(t,e){if(0===e.length)return[];var r=e[0];return 20===r.type&&"none"===r.value?[]:e.filter((function(t){return Gt(t)&&function(t){return!(20===t.type&&"none"===t.value||18===t.type&&!ke[t.name])}(t)})).map((function(e){return Se(t,e)}))}},Fe={name:"background-origin",initialValue:"border-box",prefix:!1,type:1,parse:function(t,e){return e.map((function(t){if(Ht(t))switch(t.value){case"padding-box":return 1;case"content-box":return 2}return 0}))}},Le={name:"background-position",initialValue:"0% 0%",type:1,prefix:!1,parse:function(t,e){return Vt(e).map((function(t){return t.filter(Yt)})).map(Xt)}},Ie={name:"background-repeat",initialValue:"repeat",prefix:!1,type:1,parse:function(t,e){return Vt(e).map((function(t){return t.filter(Ht).map((function(t){return t.value})).join(" ")})).map(_e)}},_e=function(t){switch(t){case"no-repeat":return 1;case"repeat-x":case"repeat no-repeat":return 2;case"repeat-y":case"no-repeat repeat":return 3;case"repeat":default:return 0}};!function(t){t.AUTO="auto",t.CONTAIN="contain",t.COVER="cover"}(he||(he={}));var Ue,Oe={name:"background-size",initialValue:"0",prefix:!1,type:1,parse:function(t,e){return Vt(e).map((function(t){return t.filter(De)}))}},De=function(t){return Ht(t)||Yt(t)},Qe=function(t){return{name:"border-"+t+"-color",initialValue:"transparent",prefix:!1,type:3,format:"color"}},Me=Qe("top"),Re=Qe("right"),Pe=Qe("bottom"),He=Qe("left"),Ne=function(t){return{name:"border-radius-"+t,initialValue:"0 0",prefix:!1,type:1,parse:function(t,e){return Xt(e.filter(Yt))}}},Ke=Ne("top-left"),je=Ne("top-right"),Ge=Ne("bottom-right"),Ve=Ne("bottom-left"),ze=function(t){return{name:"border-"+t+"-style",initialValue:"solid",prefix:!1,type:2,parse:function(t,e){switch(e){case"none":return 0;case"dashed":return 2;case"dotted":return 3;case"double":return 4}return 1}}},We=ze("top"),Ye=ze("right"),Xe=ze("bottom"),qe=ze("left"),Je=function(t){return{name:"border-"+t+"-width",initialValue:"0",type:0,prefix:!1,parse:function(t,e){return Rt(e)?e.number:0}}},Ze=Je("top"),$e=Je("right"),tr=Je("bottom"),er=Je("left"),rr={name:"color",initialValue:"transparent",prefix:!1,type:3,format:"color"},nr={name:"direction",initialValue:"ltr",prefix:!1,type:2,parse:function(t,e){switch(e){case"rtl":return 1;case"ltr":default:return 0}}},ir={name:"display",initialValue:"inline-block",prefix:!1,type:1,parse:function(t,e){return e.filter(Ht).reduce((function(t,e){return t|or(e.value)}),0)}},or=function(t){switch(t){case"block":case"-webkit-box":return 2;case"inline":return 4;case"run-in":return 8;case"flow":return 16;case"flow-root":return 32;case"table":return 64;case"flex":case"-webkit-flex":return 128;case"grid":case"-ms-grid":return 256;case"ruby":return 512;case"subgrid":return 1024;case"list-item":return 2048;case"table-row-group":return 4096;case"table-header-group":return 8192;case"table-footer-group":return 16384;case"table-row":return 32768;case"table-cell":return 65536;case"table-column-group":return 131072;case"table-column":return 262144;case"table-caption":return 524288;case"ruby-base":return 1048576;case"ruby-text":return 2097152;case"ruby-base-container":return 4194304;case"ruby-text-container":return 8388608;case"contents":return 16777216;case"inline-block":return 33554432;case"inline-list-item":return 67108864;case"inline-table":return 134217728;case"inline-flex":return 268435456;case"inline-grid":return 536870912}return 0},ar={name:"float",initialValue:"none",prefix:!1,type:2,parse:function(t,e){switch(e){case"left":return 1;case"right":return 2;case"inline-start":return 3;case"inline-end":return 4}return 0}},sr={name:"letter-spacing",initialValue:"0",prefix:!1,type:0,parse:function(t,e){return 20===e.type&&"normal"===e.value?0:17===e.type||15===e.type?e.number:0}};!function(t){t.NORMAL="normal",t.STRICT="strict"}(Ue||(Ue={}));var Ar,lr={name:"line-break",initialValue:"normal",prefix:!1,type:2,parse:function(t,e){switch(e){case"strict":return Ue.STRICT;case"normal":default:return Ue.NORMAL}}},cr={name:"line-height",initialValue:"normal",prefix:!1,type:4},ur=function(t,e){return Ht(t)&&"normal"===t.value?1.2*e:17===t.type?e*t.number:Yt(t)?te(t,e):e},hr={name:"list-style-image",initialValue:"none",type:0,prefix:!1,parse:function(t,e){return 20===e.type&&"none"===e.value?null:Se(t,e)}},dr={name:"list-style-position",initialValue:"outside",prefix:!1,type:2,parse:function(t,e){switch(e){case"inside":return 0;case"outside":default:return 1}}},fr={name:"list-style-type",initialValue:"none",prefix:!1,type:2,parse:function(t,e){switch(e){case"disc":return 0;case"circle":return 1;case"square":return 2;case"decimal":return 3;case"cjk-decimal":return 4;case"decimal-leading-zero":return 5;case"lower-roman":return 6;case"upper-roman":return 7;case"lower-greek":return 8;case"lower-alpha":return 9;case"upper-alpha":return 10;case"arabic-indic":return 11;case"armenian":return 12;case"bengali":return 13;case"cambodian":return 14;case"cjk-earthly-branch":return 15;case"cjk-heavenly-stem":return 16;case"cjk-ideographic":return 17;case"devanagari":return 18;case"ethiopic-numeric":return 19;case"georgian":return 20;case"gujarati":return 21;case"gurmukhi":case"hebrew":return 22;case"hiragana":return 23;case"hiragana-iroha":return 24;case"japanese-formal":return 25;case"japanese-informal":return 26;case"kannada":return 27;case"katakana":return 28;case"katakana-iroha":return 29;case"khmer":return 30;case"korean-hangul-formal":return 31;case"korean-hanja-formal":return 32;case"korean-hanja-informal":return 33;case"lao":return 34;case"lower-armenian":return 35;case"malayalam":return 36;case"mongolian":return 37;case"myanmar":return 38;case"oriya":return 39;case"persian":return 40;case"simp-chinese-formal":return 41;case"simp-chinese-informal":return 42;case"tamil":return 43;case"telugu":return 44;case"thai":return 45;case"tibetan":return 46;case"trad-chinese-formal":return 47;case"trad-chinese-informal":return 48;case"upper-armenian":return 49;case"disclosure-open":return 50;case"disclosure-closed":return 51;case"none":default:return-1}}},pr=function(t){return{name:"margin-"+t,initialValue:"0",prefix:!1,type:4}},gr=pr("top"),mr=pr("right"),vr=pr("bottom"),yr=pr("left"),wr={name:"overflow",initialValue:"visible",prefix:!1,type:1,parse:function(t,e){return e.filter(Ht).map((function(t){switch(t.value){case"hidden":return 1;case"scroll":return 2;case"clip":return 3;case"auto":return 4;case"visible":default:return 0}}))}},br={name:"overflow-wrap",initialValue:"normal",prefix:!1,type:2,parse:function(t,e){switch(e){case"break-word":return"break-word";case"normal":default:return"normal"}}},Cr=function(t){return{name:"padding-"+t,initialValue:"0",prefix:!1,type:3,format:"length-percentage"}},Br=Cr("top"),xr=Cr("right"),Er=Cr("bottom"),Sr=Cr("left"),kr={name:"text-align",initialValue:"left",prefix:!1,type:2,parse:function(t,e){switch(e){case"right":return 2;case"center":case"justify":return 1;case"left":default:return 0}}},Tr={name:"position",initialValue:"static",prefix:!1,type:2,parse:function(t,e){switch(e){case"relative":return 1;case"absolute":return 2;case"fixed":return 3;case"sticky":return 4}return 0}},Fr={name:"text-shadow",initialValue:"none",type:1,prefix:!1,parse:function(t,e){return 1===e.length&&Kt(e[0],"none")?[]:Vt(e).map((function(e){for(var r={color:ge.TRANSPARENT,offsetX:qt,offsetY:qt,blur:qt},n=0,i=0;i<e.length;i++){var o=e[i];Wt(o)?(0===n?r.offsetX=o:1===n?r.offsetY=o:r.blur=o,n++):r.color=oe(t,o)}return r}))}},Lr={name:"text-transform",initialValue:"none",prefix:!1,type:2,parse:function(t,e){switch(e){case"uppercase":return 2;case"lowercase":return 1;case"capitalize":return 3}return 0}},Ir={name:"transform",initialValue:"none",prefix:!0,type:0,parse:function(t,e){if(20===e.type&&"none"===e.value)return null;if(18===e.type){var r=_r[e.name];if(void 0===r)throw new Error('Attempting to parse an unsupported transform function "'+e.name+'"');return r(e.values)}return null}},_r={matrix:function(t){var e=t.filter((function(t){return 17===t.type})).map((function(t){return t.number}));return 6===e.length?e:null},matrix3d:function(t){var e=t.filter((function(t){return 17===t.type})).map((function(t){return t.number})),r=e[0],n=e[1];e[2],e[3];var i=e[4],o=e[5];e[6],e[7],e[8],e[9],e[10],e[11];var a=e[12],s=e[13];return e[14],e[15],16===e.length?[r,n,i,o,a,s]:null}},Ur={type:16,number:50,flags:4},Or=[Ur,Ur],Dr={name:"transform-origin",initialValue:"50% 50%",prefix:!0,type:1,parse:function(t,e){var r=e.filter(Yt);return 2!==r.length?Or:[r[0],r[1]]}},Qr={name:"visible",initialValue:"none",prefix:!1,type:2,parse:function(t,e){switch(e){case"hidden":return 1;case"collapse":return 2;case"visible":default:return 0}}};!function(t){t.NORMAL="normal",t.BREAK_ALL="break-all",t.KEEP_ALL="keep-all"}(Ar||(Ar={}));for(var Mr={name:"word-break",initialValue:"normal",prefix:!1,type:2,parse:function(t,e){switch(e){case"break-all":return Ar.BREAK_ALL;case"keep-all":return Ar.KEEP_ALL;case"normal":default:return Ar.NORMAL}}},Rr={name:"z-index",initialValue:"auto",prefix:!1,type:0,parse:function(t,e){if(20===e.type)return{auto:!0,order:0};if(Pt(e))return{auto:!1,order:e.number};throw new Error("Invalid z-index number parsed")}},Pr=function(t,e){if(15===e.type)switch(e.unit.toLowerCase()){case"s":return 1e3*e.number;case"ms":return e.number}throw new Error("Unsupported time type")},Hr={name:"opacity",initialValue:"1",type:0,prefix:!1,parse:function(t,e){return Pt(e)?e.number:1}},Nr={name:"text-decoration-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Kr={name:"text-decoration-line",initialValue:"none",prefix:!1,type:1,parse:function(t,e){return e.filter(Ht).map((function(t){switch(t.value){case"underline":return 1;case"overline":return 2;case"line-through":return 3;case"none":return 4}return 0})).filter((function(t){return 0!==t}))}},jr={name:"font-family",initialValue:"",prefix:!1,type:1,parse:function(t,e){var r=[],n=[];return e.forEach((function(t){switch(t.type){case 20:case 0:r.push(t.value);break;case 17:r.push(t.number.toString());break;case 4:n.push(r.join(" ")),r.length=0}})),r.length&&n.push(r.join(" ")),n.map((function(t){return-1===t.indexOf(" ")?t:"'"+t+"'"}))}},Gr={name:"font-size",initialValue:"0",prefix:!1,type:3,format:"length"},Vr={name:"font-weight",initialValue:"normal",type:0,prefix:!1,parse:function(t,e){if(Pt(e))return e.number;if(Ht(e))switch(e.value){case"bold":return 700;case"normal":default:return 400}return 400}},zr={name:"font-variant",initialValue:"none",type:1,prefix:!1,parse:function(t,e){return e.filter(Ht).map((function(t){return t.value}))}},Wr={name:"font-style",initialValue:"normal",prefix:!1,type:2,parse:function(t,e){switch(e){case"oblique":return"oblique";case"italic":return"italic";case"normal":default:return"normal"}}},Yr=function(t,e){return 0!=(t&e)},Xr={name:"content",initialValue:"none",type:1,prefix:!1,parse:function(t,e){if(0===e.length)return[];var r=e[0];return 20===r.type&&"none"===r.value?[]:e}},qr={name:"counter-increment",initialValue:"none",prefix:!0,type:1,parse:function(t,e){if(0===e.length)return null;var r=e[0];if(20===r.type&&"none"===r.value)return null;for(var n=[],i=e.filter(jt),o=0;o<i.length;o++){var a=i[o],s=i[o+1];if(20===a.type){var A=s&&Pt(s)?s.number:1;n.push({counter:a.value,increment:A})}}return n}},Jr={name:"counter-reset",initialValue:"none",prefix:!0,type:1,parse:function(t,e){if(0===e.length)return[];for(var r=[],n=e.filter(jt),i=0;i<n.length;i++){var o=n[i],a=n[i+1];if(Ht(o)&&"none"!==o.value){var s=a&&Pt(a)?a.number:0;r.push({counter:o.value,reset:s})}}return r}},Zr={name:"duration",initialValue:"0s",prefix:!1,type:1,parse:function(t,e){return e.filter(Rt).map((function(e){return Pr(t,e)}))}},$r={name:"quotes",initialValue:"none",prefix:!0,type:1,parse:function(t,e){if(0===e.length)return null;var r=e[0];if(20===r.type&&"none"===r.value)return null;var n=[],i=e.filter(Nt);if(i.length%2!=0)return null;for(var o=0;o<i.length;o+=2){var a=i[o].value,s=i[o+1].value;n.push({open:a,close:s})}return n}},tn=function(t,e,r){if(!t)return"";var n=t[Math.min(e,t.length-1)];return n?r?n.open:n.close:""},en={name:"box-shadow",initialValue:"none",type:1,prefix:!1,parse:function(t,e){return 1===e.length&&Kt(e[0],"none")?[]:Vt(e).map((function(e){for(var r={color:255,offsetX:qt,offsetY:qt,blur:qt,spread:qt,inset:!1},n=0,i=0;i<e.length;i++){var o=e[i];Kt(o,"inset")?r.inset=!0:Wt(o)?(0===n?r.offsetX=o:1===n?r.offsetY=o:2===n?r.blur=o:r.spread=o,n++):r.color=oe(t,o)}return r}))}},rn={name:"paint-order",initialValue:"normal",prefix:!1,type:1,parse:function(t,e){var r=[];return e.filter(Ht).forEach((function(t){switch(t.value){case"stroke":r.push(1);break;case"fill":r.push(0);break;case"markers":r.push(2)}})),[0,1,2].forEach((function(t){-1===r.indexOf(t)&&r.push(t)})),r}},nn={name:"-webkit-text-stroke-color",initialValue:"currentcolor",prefix:!1,type:3,format:"color"},on={name:"-webkit-text-stroke-width",initialValue:"0",type:0,prefix:!1,parse:function(t,e){return Rt(e)?e.number:0}},an=function(){function t(t,e){var r,n;this.animationDuration=ln(t,Zr,e.animationDuration),this.backgroundClip=ln(t,me,e.backgroundClip),this.backgroundColor=ln(t,ve,e.backgroundColor),this.backgroundImage=ln(t,Te,e.backgroundImage),this.backgroundOrigin=ln(t,Fe,e.backgroundOrigin),this.backgroundPosition=ln(t,Le,e.backgroundPosition),this.backgroundRepeat=ln(t,Ie,e.backgroundRepeat),this.backgroundSize=ln(t,Oe,e.backgroundSize),this.borderTopColor=ln(t,Me,e.borderTopColor),this.borderRightColor=ln(t,Re,e.borderRightColor),this.borderBottomColor=ln(t,Pe,e.borderBottomColor),this.borderLeftColor=ln(t,He,e.borderLeftColor),this.borderTopLeftRadius=ln(t,Ke,e.borderTopLeftRadius),this.borderTopRightRadius=ln(t,je,e.borderTopRightRadius),this.borderBottomRightRadius=ln(t,Ge,e.borderBottomRightRadius),this.borderBottomLeftRadius=ln(t,Ve,e.borderBottomLeftRadius),this.borderTopStyle=ln(t,We,e.borderTopStyle),this.borderRightStyle=ln(t,Ye,e.borderRightStyle),this.borderBottomStyle=ln(t,Xe,e.borderBottomStyle),this.borderLeftStyle=ln(t,qe,e.borderLeftStyle),this.borderTopWidth=ln(t,Ze,e.borderTopWidth),this.borderRightWidth=ln(t,$e,e.borderRightWidth),this.borderBottomWidth=ln(t,tr,e.borderBottomWidth),this.borderLeftWidth=ln(t,er,e.borderLeftWidth),this.boxShadow=ln(t,en,e.boxShadow),this.color=ln(t,rr,e.color),this.direction=ln(t,nr,e.direction),this.display=ln(t,ir,e.display),this.float=ln(t,ar,e.cssFloat),this.fontFamily=ln(t,jr,e.fontFamily),this.fontSize=ln(t,Gr,e.fontSize),this.fontStyle=ln(t,Wr,e.fontStyle),this.fontVariant=ln(t,zr,e.fontVariant),this.fontWeight=ln(t,Vr,e.fontWeight),this.letterSpacing=ln(t,sr,e.letterSpacing),this.lineBreak=ln(t,lr,e.lineBreak),this.lineHeight=ln(t,cr,e.lineHeight),this.listStyleImage=ln(t,hr,e.listStyleImage),this.listStylePosition=ln(t,dr,e.listStylePosition),this.listStyleType=ln(t,fr,e.listStyleType),this.marginTop=ln(t,gr,e.marginTop),this.marginRight=ln(t,mr,e.marginRight),this.marginBottom=ln(t,vr,e.marginBottom),this.marginLeft=ln(t,yr,e.marginLeft),this.opacity=ln(t,Hr,e.opacity);var i=ln(t,wr,e.overflow);this.overflowX=i[0],this.overflowY=i[i.length>1?1:0],this.overflowWrap=ln(t,br,e.overflowWrap),this.paddingTop=ln(t,Br,e.paddingTop),this.paddingRight=ln(t,xr,e.paddingRight),this.paddingBottom=ln(t,Er,e.paddingBottom),this.paddingLeft=ln(t,Sr,e.paddingLeft),this.paintOrder=ln(t,rn,e.paintOrder),this.position=ln(t,Tr,e.position),this.textAlign=ln(t,kr,e.textAlign),this.textDecorationColor=ln(t,Nr,null!==(r=e.textDecorationColor)&&void 0!==r?r:e.color),this.textDecorationLine=ln(t,Kr,null!==(n=e.textDecorationLine)&&void 0!==n?n:e.textDecoration),this.textShadow=ln(t,Fr,e.textShadow),this.textTransform=ln(t,Lr,e.textTransform),this.transform=ln(t,Ir,e.transform),this.transformOrigin=ln(t,Dr,e.transformOrigin),this.visibility=ln(t,Qr,e.visibility),this.webkitTextStrokeColor=ln(t,nn,e.webkitTextStrokeColor),this.webkitTextStrokeWidth=ln(t,on,e.webkitTextStrokeWidth),this.wordBreak=ln(t,Mr,e.wordBreak),this.zIndex=ln(t,Rr,e.zIndex)}return t.prototype.isVisible=function(){return this.display>0&&this.opacity>0&&0===this.visibility},t.prototype.isTransparent=function(){return ae(this.backgroundColor)},t.prototype.isTransformed=function(){return null!==this.transform},t.prototype.isPositioned=function(){return 0!==this.position},t.prototype.isPositionedWithZIndex=function(){return this.isPositioned()&&!this.zIndex.auto},t.prototype.isFloating=function(){return 0!==this.float},t.prototype.isInlineLevel=function(){return Yr(this.display,4)||Yr(this.display,33554432)||Yr(this.display,268435456)||Yr(this.display,536870912)||Yr(this.display,67108864)||Yr(this.display,134217728)},t}(),sn=function(t,e){this.content=ln(t,Xr,e.content),this.quotes=ln(t,$r,e.quotes)},An=function(t,e){this.counterIncrement=ln(t,qr,e.counterIncrement),this.counterReset=ln(t,Jr,e.counterReset)},ln=function(t,e,r){var n=new Qt,i=null!=r?r.toString():e.initialValue;n.write(i);var o=new Mt(n.read());switch(e.type){case 2:var a=o.parseComponentValue();return e.parse(t,Ht(a)?a.value:e.initialValue);case 0:return e.parse(t,o.parseComponentValue());case 1:return e.parse(t,o.parseComponentValues());case 4:return o.parseComponentValue();case 3:switch(e.format){case"angle":return ee(t,o.parseComponentValue());case"color":return oe(t,o.parseComponentValue());case"image":return Se(t,o.parseComponentValue());case"length":var s=o.parseComponentValue();return Wt(s)?s:qt;case"length-percentage":var A=o.parseComponentValue();return Yt(A)?A:qt;case"time":return Pr(t,o.parseComponentValue())}}},cn=function(t,e){var r=function(t){switch(t.getAttribute("data-html2canvas-debug")){case"all":return 1;case"clone":return 2;case"parse":return 3;case"render":return 4;default:return 0}}(t);return 1===r||e===r},un=function(t,e){this.context=t,this.textNodes=[],this.elements=[],this.flags=0,cn(e,3),this.styles=new an(t,window.getComputedStyle(e,null)),ui(e)&&(this.styles.animationDuration.some((function(t){return t>0}))&&(e.style.animationDuration="0s"),null!==this.styles.transform&&(e.style.transform="none")),this.bounds=s(this.context,e),cn(e,4)&&(this.flags|=16)},hn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",dn="undefined"==typeof Uint8Array?[]:new Uint8Array(256),fn=0;fn<hn.length;fn++)dn[hn.charCodeAt(fn)]=fn;for(var pn=function(t,e,r){return t.slice?t.slice(e,r):new Uint16Array(Array.prototype.slice.call(t,e,r))},gn=function(){function t(t,e,r,n,i,o){this.initialValue=t,this.errorValue=e,this.highStart=r,this.highValueIndex=n,this.index=i,this.data=o}return t.prototype.get=function(t){var e;if(t>=0){if(t<55296||t>56319&&t<=65535)return e=((e=this.index[t>>5])<<2)+(31&t),this.data[e];if(t<=65535)return e=((e=this.index[2048+(t-55296>>5)])<<2)+(31&t),this.data[e];if(t<this.highStart)return e=2080+(t>>11),e=this.index[e],e+=t>>5&63,e=((e=this.index[e])<<2)+(31&t),this.data[e];if(t<=1114111)return this.data[this.highValueIndex]}return this.errorValue},t}(),mn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",vn="undefined"==typeof Uint8Array?[]:new Uint8Array(256),yn=0;yn<mn.length;yn++)vn[mn.charCodeAt(yn)]=yn;var wn,bn=8,Cn=9,Bn=11,xn=12,En=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if(String.fromCodePoint)return String.fromCodePoint.apply(String,t);var r=t.length;if(!r)return"";for(var n=[],i=-1,o="";++i<r;){var a=t[i];a<=65535?n.push(a):(a-=65536,n.push(55296+(a>>10),a%1024+56320)),(i+1===r||n.length>16384)&&(o+=String.fromCharCode.apply(String,n),n.length=0)}return o},Sn=function(t,e){var r,n,i,o=function(t){var e,r,n,i,o,a=.75*t.length,s=t.length,A=0;"="===t[t.length-1]&&(a--,"="===t[t.length-2]&&a--);var l="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&&void 0!==Uint8Array.prototype.slice?new ArrayBuffer(a):new Array(a),c=Array.isArray(l)?l:new Uint8Array(l);for(e=0;e<s;e+=4)r=dn[t.charCodeAt(e)],n=dn[t.charCodeAt(e+1)],i=dn[t.charCodeAt(e+2)],o=dn[t.charCodeAt(e+3)],c[A++]=r<<2|n>>4,c[A++]=(15&n)<<4|i>>2,c[A++]=(3&i)<<6|63&o;return l}(t),a=Array.isArray(o)?function(t){for(var e=t.length,r=[],n=0;n<e;n+=4)r.push(t[n+3]<<24|t[n+2]<<16|t[n+1]<<8|t[n]);return r}(o):new Uint32Array(o),s=Array.isArray(o)?function(t){for(var e=t.length,r=[],n=0;n<e;n+=2)r.push(t[n+1]<<8|t[n]);return r}(o):new Uint16Array(o),A=pn(s,12,a[4]/2),l=2===a[5]?pn(s,(24+a[4])/2):(r=a,n=Math.ceil((24+a[4])/4),r.slice?r.slice(n,i):new Uint32Array(Array.prototype.slice.call(r,n,i)));return new gn(a[0],a[1],a[2],a[3],A,l)}("AAAAAAAAAAAAEA4AGBkAAFAaAAACAAAAAAAIABAAGAAwADgACAAQAAgAEAAIABAACAAQAAgAEAAIABAACAAQAAgAEAAIABAAQABIAEQATAAIABAACAAQAAgAEAAIABAAVABcAAgAEAAIABAACAAQAGAAaABwAHgAgACIAI4AlgAIABAAmwCjAKgAsAC2AL4AvQDFAMoA0gBPAVYBWgEIAAgACACMANoAYgFkAWwBdAF8AX0BhQGNAZUBlgGeAaMBlQGWAasBswF8AbsBwwF0AcsBYwHTAQgA2wG/AOMBdAF8AekB8QF0AfkB+wHiAHQBfAEIAAMC5gQIAAsCEgIIAAgAFgIeAggAIgIpAggAMQI5AkACygEIAAgASAJQAlgCYAIIAAgACAAKBQoFCgUTBRMFGQUrBSsFCAAIAAgACAAIAAgACAAIAAgACABdAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABoAmgCrwGvAQgAbgJ2AggAHgEIAAgACADnAXsCCAAIAAgAgwIIAAgACAAIAAgACACKAggAkQKZAggAPADJAAgAoQKkAqwCsgK6AsICCADJAggA0AIIAAgACAAIANYC3gIIAAgACAAIAAgACABAAOYCCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAkASoB+QIEAAgACAA8AEMCCABCBQgACABJBVAFCAAIAAgACAAIAAgACAAIAAgACABTBVoFCAAIAFoFCABfBWUFCAAIAAgACAAIAAgAbQUIAAgACAAIAAgACABzBXsFfQWFBYoFigWKBZEFigWKBYoFmAWfBaYFrgWxBbkFCAAIAAgACAAIAAgACAAIAAgACAAIAMEFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAMgFCADQBQgACAAIAAgACAAIAAgACAAIAAgACAAIAO4CCAAIAAgAiQAIAAgACABAAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAD0AggACAD8AggACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIANYFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAMDvwAIAAgAJAIIAAgACAAIAAgACAAIAAgACwMTAwgACAB9BOsEGwMjAwgAKwMyAwsFYgE3A/MEPwMIAEUDTQNRAwgAWQOsAGEDCAAIAAgACAAIAAgACABpAzQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFIQUoBSwFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABtAwgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABMAEwACAAIAAgACAAIABgACAAIAAgACAC/AAgACAAyAQgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACAAIAAwAAgACAAIAAgACAAIAAgACAAIAAAARABIAAgACAAIABQASAAIAAgAIABwAEAAjgCIABsAqAC2AL0AigDQAtwC+IJIQqVAZUBWQqVAZUBlQGVAZUBlQGrC5UBlQGVAZUBlQGVAZUBlQGVAXsKlQGVAbAK6wsrDGUMpQzlDJUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAfAKAAuZA64AtwCJALoC6ADwAAgAuACgA/oEpgO6AqsD+AAIAAgAswMIAAgACAAIAIkAuwP5AfsBwwPLAwgACAAIAAgACADRA9kDCAAIAOED6QMIAAgACAAIAAgACADuA/YDCAAIAP4DyQAIAAgABgQIAAgAXQAOBAgACAAIAAgACAAIABMECAAIAAgACAAIAAgACAD8AAQBCAAIAAgAGgQiBCoECAExBAgAEAEIAAgACAAIAAgACAAIAAgACAAIAAgACAA4BAgACABABEYECAAIAAgATAQYAQgAVAQIAAgACAAIAAgACAAIAAgACAAIAFoECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAOQEIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAB+BAcACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAEABhgSMBAgACAAIAAgAlAQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAwAEAAQABAADAAMAAwADAAQABAAEAAQABAAEAAQABHATAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAdQMIAAgACAAIAAgACAAIAMkACAAIAAgAfQMIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACFA4kDCAAIAAgACAAIAOcBCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAIcDCAAIAAgACAAIAAgACAAIAAgACAAIAJEDCAAIAAgACADFAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABgBAgAZgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAbAQCBXIECAAIAHkECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABAAJwEQACjBKoEsgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAC6BMIECAAIAAgACAAIAAgACABmBAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAxwQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAGYECAAIAAgAzgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBd0FXwUIAOIF6gXxBYoF3gT5BQAGCAaKBYoFigWKBYoFigWKBYoFigWKBYoFigXWBIoFigWKBYoFigWKBYoFigWKBYsFEAaKBYoFigWKBYoFigWKBRQGCACKBYoFigWKBQgACAAIANEECAAIABgGigUgBggAJgYIAC4GMwaKBYoF0wQ3Bj4GigWKBYoFigWKBYoFigWKBYoFigWKBYoFigUIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWLBf///////wQABAAEAAQABAAEAAQABAAEAAQAAwAEAAQAAgAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAQADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAUAAAAFAAUAAAAFAAUAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUAAQAAAAUABQAFAAUABQAFAAAAAAAFAAUAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAFAAUAAQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUABQAFAAAABwAHAAcAAAAHAAcABwAFAAEAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAcABwAFAAUAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAAAAQABAAAAAAAAAAAAAAAFAAUABQAFAAAABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABwAHAAcAAAAHAAcAAAAAAAUABQAHAAUAAQAHAAEABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABwABAAUABQAFAAUAAAAAAAAAAAAAAAEAAQABAAEAAQABAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABQANAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAEAAQABAAEAAQABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAABQAHAAUABQAFAAAAAAAAAAcABQAFAAUABQAFAAQABAAEAAQABAAEAAQABAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUAAAAFAAUABQAFAAUAAAAFAAUABQAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAAAAAAAAAAAAUABQAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAUAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABwAHAAcABwAFAAcABwAAAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAUABwAHAAUABQAFAAUAAAAAAAcABwAAAAAABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAABQAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAABwAHAAcABQAFAAAAAAAAAAAABQAFAAAAAAAFAAUABQAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAFAAUABQAFAAUAAAAFAAUABwAAAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAFAAUABwAFAAUABQAFAAAAAAAHAAcAAAAAAAcABwAFAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABwAAAAAAAAAHAAcABwAAAAcABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAABQAHAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAcABwAAAAUABQAFAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABQAHAAcABQAHAAcAAAAFAAcABwAAAAcABwAFAAUAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAFAAcABwAFAAUABQAAAAUAAAAHAAcABwAHAAcABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAHAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAABwAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAUAAAAFAAAAAAAAAAAABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUABQAFAAUAAAAFAAUAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABwAFAAUABQAFAAUABQAAAAUABQAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABQAFAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABQAFAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAHAAUABQAFAAUABQAFAAUABwAHAAcABwAHAAcABwAHAAUABwAHAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABwAHAAcABwAFAAUABwAHAAcAAAAAAAAAAAAHAAcABQAHAAcABwAHAAcABwAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAHAAUABQAFAAUABQAFAAUAAAAFAAAABQAAAAAABQAFAAUABQAFAAUABQAFAAcABwAHAAcABwAHAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAUABQAFAAUABQAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABwAFAAcABwAHAAcABwAFAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAUABQAFAAUABwAHAAUABQAHAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABQAFAAcABwAHAAUABwAFAAUABQAHAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAUABQAFAAUABQAFAAUABQAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAcABQAFAAUABQAFAAUABQAAAAAAAAAAAAUAAAAAAAAAAAAAAAAABQAAAAAABwAFAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUAAAAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAABQAAAAAAAAAFAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAUABQAHAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAHAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABwAFAAUABQAFAAcABwAFAAUABwAHAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAcABwAFAAUABwAHAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAFAAUABQAAAAAABQAFAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAFAAcABwAAAAAAAAAAAAAABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAFAAcABwAFAAcABwAAAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAFAAUABQAAAAUABQAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABwAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABQAFAAUABQAFAAUABQAFAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAHAAcABQAHAAUABQAAAAAAAAAAAAAAAAAFAAAABwAHAAcABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAcABwAAAAAABwAHAAAAAAAHAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABwAHAAUABQAFAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABQAFAAUABQAFAAUABwAFAAcABwAFAAcABQAFAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABQAFAAUABQAAAAAABwAHAAcABwAFAAUABwAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAHAAUABQAFAAUABQAFAAUABQAHAAcABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAFAAcABwAFAAUABQAFAAUABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAcABwAFAAUABQAFAAcABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABQAHAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAAAAAAFAAUABwAHAAcABwAFAAAAAAAAAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABwAHAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAHAAUABQAFAAUABQAFAAUABwAFAAUABwAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAAAAAAAABQAAAAUABQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAHAAcAAAAFAAUAAAAHAAcABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAAAAAAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAUABQAFAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAABQAFAAUABQAFAAUABQAAAAUABQAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAFAAUABQAFAAUADgAOAA4ADgAOAA4ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAAAAAAAAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAMAAwADAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkAAAAAAAAAAAAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAAAAAAAAAAAAsADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwACwAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAADgAOAA4AAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAAAA4ADgAOAA4ADgAOAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAA4AAAAOAAAAAAAAAAAAAAAAAA4AAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAADgAAAAAAAAAAAA4AAAAOAAAAAAAAAAAADgAOAA4AAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAAAAA4ADgAOAA4ADgAOAA4ADgAOAAAADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4AAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAOAA4ADgAOAA4ADgAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAA="),kn=function(t){return Sn.get(t)},Tn=function(t,e,r){var n=r-2,i=e[n],o=e[r-1],a=e[r];if(2===o&&3===a)return"×";if(2===o||3===o||4===o)return"÷";if(2===a||3===a||4===a)return"÷";if(o===bn&&-1!==[bn,Cn,Bn,xn].indexOf(a))return"×";if(!(o!==Bn&&o!==Cn||a!==Cn&&10!==a))return"×";if((o===xn||10===o)&&10===a)return"×";if(13===a||5===a)return"×";if(7===a)return"×";if(1===o)return"×";if(13===o&&14===a){for(;5===i;)i=e[--n];if(14===i)return"×"}if(15===o&&15===a){for(var s=0;15===i;)s++,i=e[--n];if(s%2==0)return"×"}return"÷"},Fn=function(t){var e=function(t){for(var e=[],r=0,n=t.length;r<n;){var i=t.charCodeAt(r++);if(i>=55296&&i<=56319&&r<n){var o=t.charCodeAt(r++);56320==(64512&o)?e.push(((1023&i)<<10)+(1023&o)+65536):(e.push(i),r--)}else e.push(i)}return e}(t),r=e.length,n=0,i=0,o=e.map(kn);return{next:function(){if(n>=r)return{done:!0,value:null};for(var t="×";n<r&&"×"===(t=Tn(0,o,++n)););if("×"!==t||n===r){var a=En.apply(null,e.slice(i,n));return i=n,{value:a,done:!1}}return{done:!0,value:null}}}},Ln=function(t){return 0===t[0]&&255===t[1]&&0===t[2]&&255===t[3]},In=function(t,e,r,n,i){var o="http://www.w3.org/2000/svg",a=document.createElementNS(o,"svg"),s=document.createElementNS(o,"foreignObject");return a.setAttributeNS(null,"width",t.toString()),a.setAttributeNS(null,"height",e.toString()),s.setAttributeNS(null,"width","100%"),s.setAttributeNS(null,"height","100%"),s.setAttributeNS(null,"x",r.toString()),s.setAttributeNS(null,"y",n.toString()),s.setAttributeNS(null,"externalResourcesRequired","true"),a.appendChild(s),s.appendChild(i),a},_n=function(t){return new Promise((function(e,r){var n=new Image;n.onload=function(){return e(n)},n.onerror=r,n.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent((new XMLSerializer).serializeToString(t))}))},Un={get SUPPORT_RANGE_BOUNDS(){var t=function(t){if(t.createRange){var e=t.createRange();if(e.getBoundingClientRect){var r=t.createElement("boundtest");r.style.height="123px",r.style.display="block",t.body.appendChild(r),e.selectNode(r);var n=e.getBoundingClientRect(),i=Math.round(n.height);if(t.body.removeChild(r),123===i)return!0}}return!1}(document);return Object.defineProperty(Un,"SUPPORT_RANGE_BOUNDS",{value:t}),t},get SUPPORT_WORD_BREAKING(){var t=Un.SUPPORT_RANGE_BOUNDS&&function(t){var e=t.createElement("boundtest");e.style.width="50px",e.style.display="block",e.style.fontSize="12px",e.style.letterSpacing="0px",e.style.wordSpacing="0px",t.body.appendChild(e);var r=t.createRange();e.innerHTML="function"==typeof"".repeat?"👨".repeat(10):"";var n=e.firstChild,i=A(n.data).map((function(t){return l(t)})),o=0,a={},s=i.every((function(t,e){r.setStart(n,o),r.setEnd(n,o+t.length);var i=r.getBoundingClientRect();o+=t.length;var s=i.x>a.x||i.y>a.y;return a=i,0===e||s}));return t.body.removeChild(e),s}(document);return Object.defineProperty(Un,"SUPPORT_WORD_BREAKING",{value:t}),t},get SUPPORT_SVG_DRAWING(){var t=function(t){var e=new Image,r=t.createElement("canvas"),n=r.getContext("2d");if(!n)return!1;e.src="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg'></svg>";try{n.drawImage(e,0,0),r.toDataURL()}catch(t){return!1}return!0}(document);return Object.defineProperty(Un,"SUPPORT_SVG_DRAWING",{value:t}),t},get SUPPORT_FOREIGNOBJECT_DRAWING(){var t="function"==typeof Array.from&&"function"==typeof window.fetch?function(t){var e=t.createElement("canvas");e.width=100,e.height=100;var r=e.getContext("2d");if(!r)return Promise.reject(!1);r.fillStyle="rgb(0, 255, 0)",r.fillRect(0,0,100,100);var n=new Image,i=e.toDataURL();n.src=i;var o=In(100,100,0,0,n);return r.fillStyle="red",r.fillRect(0,0,100,100),_n(o).then((function(e){r.drawImage(e,0,0);var n=r.getImageData(0,0,100,100).data;r.fillStyle="red",r.fillRect(0,0,100,100);var o=t.createElement("div");return o.style.backgroundImage="url("+i+")",o.style.height="100px",Ln(n)?_n(In(100,100,0,0,o)):Promise.reject(!1)})).then((function(t){return r.drawImage(t,0,0),Ln(r.getImageData(0,0,100,100).data)})).catch((function(){return!1}))}(document):Promise.resolve(!1);return Object.defineProperty(Un,"SUPPORT_FOREIGNOBJECT_DRAWING",{value:t}),t},get SUPPORT_CORS_IMAGES(){var t=void 0!==(new Image).crossOrigin;return Object.defineProperty(Un,"SUPPORT_CORS_IMAGES",{value:t}),t},get SUPPORT_RESPONSE_TYPE(){var t="string"==typeof(new XMLHttpRequest).responseType;return Object.defineProperty(Un,"SUPPORT_RESPONSE_TYPE",{value:t}),t},get SUPPORT_CORS_XHR(){var t="withCredentials"in new XMLHttpRequest;return Object.defineProperty(Un,"SUPPORT_CORS_XHR",{value:t}),t},get SUPPORT_NATIVE_TEXT_SEGMENTATION(){var t=!("undefined"==typeof Intl||!Intl.Segmenter);return Object.defineProperty(Un,"SUPPORT_NATIVE_TEXT_SEGMENTATION",{value:t}),t}},On=function(t,e){this.text=t,this.bounds=e},Dn=function(t,e){var r=e.ownerDocument;if(r){var n=r.createElement("html2canvaswrapper");n.appendChild(e.cloneNode(!0));var i=e.parentNode;if(i){i.replaceChild(n,e);var o=s(t,n);return n.firstChild&&i.replaceChild(n.firstChild,n),o}}return a.EMPTY},Qn=function(t,e,r){var n=t.ownerDocument;if(!n)throw new Error("Node has no owner document");var i=n.createRange();return i.setStart(t,e),i.setEnd(t,e+r),i},Mn=function(t){if(Un.SUPPORT_NATIVE_TEXT_SEGMENTATION){var e=new Intl.Segmenter(void 0,{granularity:"grapheme"});return Array.from(e.segment(t)).map((function(t){return t.segment}))}return function(t){for(var e,r=Fn(t),n=[];!(e=r.next()).done;)e.value&&n.push(e.value.slice());return n}(t)},Rn=function(t,e){return 0!==e.letterSpacing?Mn(t):function(t,e){if(Un.SUPPORT_NATIVE_TEXT_SEGMENTATION){var r=new Intl.Segmenter(void 0,{granularity:"word"});return Array.from(r.segment(t)).map((function(t){return t.segment}))}return Hn(t,e)}(t,e)},Pn=[32,160,4961,65792,65793,4153,4241],Hn=function(t,e){for(var r,n=function(t,e){var r=A(t),n=nt(r,e),i=n[0],o=n[1],a=n[2],s=r.length,l=0,c=0;return{next:function(){if(c>=s)return{done:!0,value:null};for(var t="×";c<s&&"×"===(t=rt(r,o,i,++c,a)););if("×"!==t||c===s){var e=new it(r,t,l,c);return l=c,{value:e,done:!1}}return{done:!0,value:null}}}}(t,{lineBreak:e.lineBreak,wordBreak:"break-word"===e.overflowWrap?"break-word":e.wordBreak}),i=[],o=function(){if(r.value){var t=r.value.slice(),e=A(t),n="";e.forEach((function(t){-1===Pn.indexOf(t)?n+=l(t):(n.length&&i.push(n),i.push(l(t)),n="")})),n.length&&i.push(n)}};!(r=n.next()).done;)o();return i},Nn=function(t,e,r){this.text=Kn(e.data,r.textTransform),this.textBounds=function(t,e,r,n){var i=Rn(e,r),o=[],s=0;return i.forEach((function(e){if(r.textDecorationLine.length||e.trim().length>0)if(Un.SUPPORT_RANGE_BOUNDS){var i=Qn(n,s,e.length).getClientRects();if(i.length>1){var A=Mn(e),l=0;A.forEach((function(e){o.push(new On(e,a.fromDOMRectList(t,Qn(n,l+s,e.length).getClientRects()))),l+=e.length}))}else o.push(new On(e,a.fromDOMRectList(t,i)))}else{var c=n.splitText(e.length);o.push(new On(e,Dn(t,n))),n=c}else Un.SUPPORT_RANGE_BOUNDS||(n=n.splitText(e.length));s+=e.length})),o}(t,this.text,r,e)},Kn=function(t,e){switch(e){case 1:return t.toLowerCase();case 3:return t.replace(jn,Gn);case 2:return t.toUpperCase();default:return t}},jn=/(^|\s|:|-|\(|\))([a-z])/g,Gn=function(t,e,r){return t.length>0?e+r.toUpperCase():t},Vn=function(t){function r(e,r){var n=t.call(this,e,r)||this;return n.src=r.currentSrc||r.src,n.intrinsicWidth=r.naturalWidth,n.intrinsicHeight=r.naturalHeight,n.context.cache.addImage(n.src),n}return e(r,t),r}(un),zn=function(t){function r(e,r){var n=t.call(this,e,r)||this;return n.canvas=r,n.intrinsicWidth=r.width,n.intrinsicHeight=r.height,n}return e(r,t),r}(un),Wn=function(t){function r(e,r){var n=t.call(this,e,r)||this,i=new XMLSerializer,o=s(e,r);return r.setAttribute("width",o.width+"px"),r.setAttribute("height",o.height+"px"),n.svg="data:image/svg+xml,"+encodeURIComponent(i.serializeToString(r)),n.intrinsicWidth=r.width.baseVal.value,n.intrinsicHeight=r.height.baseVal.value,n.context.cache.addImage(n.svg),n}return e(r,t),r}(un),Yn=function(t){function r(e,r){var n=t.call(this,e,r)||this;return n.value=r.value,n}return e(r,t),r}(un),Xn=function(t){function r(e,r){var n=t.call(this,e,r)||this;return n.start=r.start,n.reversed="boolean"==typeof r.reversed&&!0===r.reversed,n}return e(r,t),r}(un),qn=[{type:15,flags:0,unit:"px",number:3}],Jn=[{type:16,flags:0,number:50}],Zn="password",$n=function(t){function r(e,r){var n,i,o,s=t.call(this,e,r)||this;switch(s.type=r.type.toLowerCase(),s.checked=r.checked,s.value=0===(i=(n=r).type===Zn?new Array(n.value.length+1).join("•"):n.value).length?n.placeholder||"":i,"checkbox"!==s.type&&"radio"!==s.type||(s.styles.backgroundColor=3739148031,s.styles.borderTopColor=s.styles.borderRightColor=s.styles.borderBottomColor=s.styles.borderLeftColor=2779096575,s.styles.borderTopWidth=s.styles.borderRightWidth=s.styles.borderBottomWidth=s.styles.borderLeftWidth=1,s.styles.borderTopStyle=s.styles.borderRightStyle=s.styles.borderBottomStyle=s.styles.borderLeftStyle=1,s.styles.backgroundClip=[0],s.styles.backgroundOrigin=[0],s.bounds=(o=s.bounds).width>o.height?new a(o.left+(o.width-o.height)/2,o.top,o.height,o.height):o.width<o.height?new a(o.left,o.top+(o.height-o.width)/2,o.width,o.width):o),s.type){case"checkbox":s.styles.borderTopRightRadius=s.styles.borderTopLeftRadius=s.styles.borderBottomRightRadius=s.styles.borderBottomLeftRadius=qn;break;case"radio":s.styles.borderTopRightRadius=s.styles.borderTopLeftRadius=s.styles.borderBottomRightRadius=s.styles.borderBottomLeftRadius=Jn}return s}return e(r,t),r}(un),ti=function(t){function r(e,r){var n=t.call(this,e,r)||this,i=r.options[r.selectedIndex||0];return n.value=i&&i.text||"",n}return e(r,t),r}(un),ei=function(t){function r(e,r){var n=t.call(this,e,r)||this;return n.value=r.value,n}return e(r,t),r}(un),ri=function(t){function r(e,r){var n=t.call(this,e,r)||this;n.src=r.src,n.width=parseInt(r.width,10)||0,n.height=parseInt(r.height,10)||0,n.backgroundColor=n.styles.backgroundColor;try{if(r.contentWindow&&r.contentWindow.document&&r.contentWindow.document.documentElement){n.tree=ai(e,r.contentWindow.document.documentElement);var i=r.contentWindow.document.documentElement?pe(e,getComputedStyle(r.contentWindow.document.documentElement).backgroundColor):ge.TRANSPARENT,o=r.contentWindow.document.body?pe(e,getComputedStyle(r.contentWindow.document.body).backgroundColor):ge.TRANSPARENT;n.backgroundColor=ae(i)?ae(o)?n.styles.backgroundColor:o:i}}catch(t){}return n}return e(r,t),r}(un),ni=["OL","UL","MENU"],ii=function(t,e,r,n){for(var i=e.firstChild,o=void 0;i;i=o)if(o=i.nextSibling,li(i)&&i.data.trim().length>0)r.textNodes.push(new Nn(t,i,r.styles));else if(ci(i))if(Ei(i)&&i.assignedNodes)i.assignedNodes().forEach((function(e){return ii(t,e,r,n)}));else{var a=oi(t,i);a.styles.isVisible()&&(si(i,a,n)?a.flags|=4:Ai(a.styles)&&(a.flags|=2),-1!==ni.indexOf(i.tagName)&&(a.flags|=8),r.elements.push(a),i.slot,i.shadowRoot?ii(t,i.shadowRoot,a,n):Bi(i)||gi(i)||xi(i)||ii(t,i,a,n))}},oi=function(t,e){return wi(e)?new Vn(t,e):vi(e)?new zn(t,e):gi(e)?new Wn(t,e):di(e)?new Yn(t,e):fi(e)?new Xn(t,e):pi(e)?new $n(t,e):xi(e)?new ti(t,e):Bi(e)?new ei(t,e):bi(e)?new ri(t,e):new un(t,e)},ai=function(t,e){var r=oi(t,e);return r.flags|=4,ii(t,e,r,r),r},si=function(t,e,r){return e.styles.isPositionedWithZIndex()||e.styles.opacity<1||e.styles.isTransformed()||mi(t)&&r.styles.isTransparent()},Ai=function(t){return t.isPositioned()||t.isFloating()},li=function(t){return t.nodeType===Node.TEXT_NODE},ci=function(t){return t.nodeType===Node.ELEMENT_NODE},ui=function(t){return ci(t)&&void 0!==t.style&&!hi(t)},hi=function(t){return"object"==typeof t.className},di=function(t){return"LI"===t.tagName},fi=function(t){return"OL"===t.tagName},pi=function(t){return"INPUT"===t.tagName},gi=function(t){return"svg"===t.tagName},mi=function(t){return"BODY"===t.tagName},vi=function(t){return"CANVAS"===t.tagName},yi=function(t){return"VIDEO"===t.tagName},wi=function(t){return"IMG"===t.tagName},bi=function(t){return"IFRAME"===t.tagName},Ci=function(t){return"STYLE"===t.tagName},Bi=function(t){return"TEXTAREA"===t.tagName},xi=function(t){return"SELECT"===t.tagName},Ei=function(t){return"SLOT"===t.tagName},Si=function(t){return t.tagName.indexOf("-")>0},ki=function(){function t(){this.counters={}}return t.prototype.getCounterValue=function(t){var e=this.counters[t];return e&&e.length?e[e.length-1]:1},t.prototype.getCounterValues=function(t){var e=this.counters[t];return e||[]},t.prototype.pop=function(t){var e=this;t.forEach((function(t){return e.counters[t].pop()}))},t.prototype.parse=function(t){var e=this,r=t.counterIncrement,n=t.counterReset,i=!0;null!==r&&r.forEach((function(t){var r=e.counters[t.counter];r&&0!==t.increment&&(i=!1,r.length||r.push(1),r[Math.max(0,r.length-1)]+=t.increment)}));var o=[];return i&&n.forEach((function(t){var r=e.counters[t.counter];o.push(t.counter),r||(r=e.counters[t.counter]=[]),r.push(t.reset)})),o},t}(),Ti={integers:[1e3,900,500,400,100,90,50,40,10,9,5,4,1],values:["M","CM","D","CD","C","XC","L","XL","X","IX","V","IV","I"]},Fi={integers:[9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["Ք","Փ","Ւ","Ց","Ր","Տ","Վ","Ս","Ռ","Ջ","Պ","Չ","Ո","Շ","Ն","Յ","Մ","Ճ","Ղ","Ձ","Հ","Կ","Ծ","Խ","Լ","Ի","Ժ","Թ","Ը","Է","Զ","Ե","Դ","Գ","Բ","Ա"]},Li={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,400,300,200,100,90,80,70,60,50,40,30,20,19,18,17,16,15,10,9,8,7,6,5,4,3,2,1],values:["י׳","ט׳","ח׳","ז׳","ו׳","ה׳","ד׳","ג׳","ב׳","א׳","ת","ש","ר","ק","צ","פ","ע","ס","נ","מ","ל","כ","יט","יח","יז","טז","טו","י","ט","ח","ז","ו","ה","ד","ג","ב","א"]},Ii={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["ჵ","ჰ","ჯ","ჴ","ხ","ჭ","წ","ძ","ც","ჩ","შ","ყ","ღ","ქ","ფ","ჳ","ტ","ს","რ","ჟ","პ","ო","ჲ","ნ","მ","ლ","კ","ი","თ","ჱ","ზ","ვ","ე","დ","გ","ბ","ა"]},_i=function(t,e,r,n,i,o){return t<e||t>r?Mi(t,i,o.length>0):n.integers.reduce((function(e,r,i){for(;t>=r;)t-=r,e+=n.values[i];return e}),"")+o},Ui=function(t,e,r,n){var i="";do{r||t--,i=n(t)+i,t/=e}while(t*e>=e);return i},Oi=function(t,e,r,n,i){var o=r-e+1;return(t<0?"-":"")+(Ui(Math.abs(t),o,n,(function(t){return l(Math.floor(t%o)+e)}))+i)},Di=function(t,e,r){void 0===r&&(r=". ");var n=e.length;return Ui(Math.abs(t),n,!1,(function(t){return e[Math.floor(t%n)]}))+r},Qi=function(t,e,r,n,i,o){if(t<-9999||t>9999)return Mi(t,4,i.length>0);var a=Math.abs(t),s=i;if(0===a)return e[0]+s;for(var A=0;a>0&&A<=4;A++){var l=a%10;0===l&&Yr(o,1)&&""!==s?s=e[l]+s:l>1||1===l&&0===A||1===l&&1===A&&Yr(o,2)||1===l&&1===A&&Yr(o,4)&&t>100||1===l&&A>1&&Yr(o,8)?s=e[l]+(A>0?r[A-1]:"")+s:1===l&&A>0&&(s=r[A-1]+s),a=Math.floor(a/10)}return(t<0?n:"")+s},Mi=function(t,e,r){var n=r?". ":"",i=r?"、":"",o=r?", ":"",a=r?" ":"";switch(e){case 0:return"•"+a;case 1:return"◦"+a;case 2:return"◾"+a;case 5:var s=Oi(t,48,57,!0,n);return s.length<4?"0"+s:s;case 4:return Di(t,"〇一二三四五六七八九",i);case 6:return _i(t,1,3999,Ti,3,n).toLowerCase();case 7:return _i(t,1,3999,Ti,3,n);case 8:return Oi(t,945,969,!1,n);case 9:return Oi(t,97,122,!1,n);case 10:return Oi(t,65,90,!1,n);case 11:return Oi(t,1632,1641,!0,n);case 12:case 49:return _i(t,1,9999,Fi,3,n);case 35:return _i(t,1,9999,Fi,3,n).toLowerCase();case 13:return Oi(t,2534,2543,!0,n);case 14:case 30:return Oi(t,6112,6121,!0,n);case 15:return Di(t,"子丑寅卯辰巳午未申酉戌亥",i);case 16:return Di(t,"甲乙丙丁戊己庚辛壬癸",i);case 17:case 48:return Qi(t,"零一二三四五六七八九","十百千萬","負",i,14);case 47:return Qi(t,"零壹貳參肆伍陸柒捌玖","拾佰仟萬","負",i,15);case 42:return Qi(t,"零一二三四五六七八九","十百千萬","负",i,14);case 41:return Qi(t,"零壹贰叁肆伍陆柒捌玖","拾佰仟萬","负",i,15);case 26:return Qi(t,"〇一二三四五六七八九","十百千万","マイナス",i,0);case 25:return Qi(t,"零壱弐参四伍六七八九","拾百千万","マイナス",i,7);case 31:return Qi(t,"영일이삼사오육칠팔구","십백천만","마이너스",o,7);case 33:return Qi(t,"零一二三四五六七八九","十百千萬","마이너스",o,0);case 32:return Qi(t,"零壹貳參四五六七八九","拾百千","마이너스",o,7);case 18:return Oi(t,2406,2415,!0,n);case 20:return _i(t,1,19999,Ii,3,n);case 21:return Oi(t,2790,2799,!0,n);case 22:return Oi(t,2662,2671,!0,n);case 22:return _i(t,1,10999,Li,3,n);case 23:return Di(t,"あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわゐゑをん");case 24:return Di(t,"いろはにほへとちりぬるをわかよたれそつねならむうゐのおくやまけふこえてあさきゆめみしゑひもせす");case 27:return Oi(t,3302,3311,!0,n);case 28:return Di(t,"アイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワヰヱヲン",i);case 29:return Di(t,"イロハニホヘトチリヌルヲワカヨタレソツネナラムウヰノオクヤマケフコエテアサキユメミシヱヒモセス",i);case 34:return Oi(t,3792,3801,!0,n);case 37:return Oi(t,6160,6169,!0,n);case 38:return Oi(t,4160,4169,!0,n);case 39:return Oi(t,2918,2927,!0,n);case 40:return Oi(t,1776,1785,!0,n);case 43:return Oi(t,3046,3055,!0,n);case 44:return Oi(t,3174,3183,!0,n);case 45:return Oi(t,3664,3673,!0,n);case 46:return Oi(t,3872,3881,!0,n);case 3:default:return Oi(t,48,57,!0,n)}},Ri=function(){function t(t,e,r){if(this.context=t,this.options=r,this.scrolledElements=[],this.referenceElement=e,this.counters=new ki,this.quoteDepth=0,!e.ownerDocument)throw new Error("Cloned element does not have an owner document");this.documentElement=this.cloneNode(e.ownerDocument.documentElement,!1)}return t.prototype.toIFrame=function(t,e){var r=this,o=Hi(t,e);if(!o.contentWindow)return Promise.reject("Unable to find iframe window");var a=t.defaultView.pageXOffset,s=t.defaultView.pageYOffset,A=o.contentWindow,l=A.document,c=ji(o).then((function(){return n(r,void 0,void 0,(function(){var t,r;return i(this,(function(n){switch(n.label){case 0:return this.scrolledElements.forEach(Yi),A&&(A.scrollTo(e.left,e.top),!/(iPad|iPhone|iPod)/g.test(navigator.userAgent)||A.scrollY===e.top&&A.scrollX===e.left||(this.context.logger.warn("Unable to restore scroll position for cloned document"),this.context.windowBounds=this.context.windowBounds.add(A.scrollX-e.left,A.scrollY-e.top,0,0))),t=this.options.onclone,void 0===(r=this.clonedReferenceElement)?[2,Promise.reject("Error finding the "+this.referenceElement.nodeName+" in the cloned document")]:l.fonts&&l.fonts.ready?[4,l.fonts.ready]:[3,2];case 1:n.sent(),n.label=2;case 2:return/(AppleWebKit)/g.test(navigator.userAgent)?[4,Ki(l)]:[3,4];case 3:n.sent(),n.label=4;case 4:return"function"==typeof t?[2,Promise.resolve().then((function(){return t(l,r)})).then((function(){return o}))]:[2,o]}}))}))}));return l.open(),l.write(zi(document.doctype)+"<html></html>"),Wi(this.referenceElement.ownerDocument,a,s),l.replaceChild(l.adoptNode(this.documentElement),l.documentElement),l.close(),c},t.prototype.createElementClone=function(t){if(cn(t,2),vi(t))return this.createCanvasClone(t);if(yi(t))return this.createVideoClone(t);if(Ci(t))return this.createStyleClone(t);var e=t.cloneNode(!1);return wi(e)&&(wi(t)&&t.currentSrc&&t.currentSrc!==t.src&&(e.src=t.currentSrc,e.srcset=""),"lazy"===e.loading&&(e.loading="eager")),Si(e)?this.createCustomElementClone(e):e},t.prototype.createCustomElementClone=function(t){var e=document.createElement("html2canvascustomelement");return Vi(t.style,e),e},t.prototype.createStyleClone=function(t){try{var e=t.sheet;if(e&&e.cssRules){var r=[].slice.call(e.cssRules,0).reduce((function(t,e){return e&&"string"==typeof e.cssText?t+e.cssText:t}),""),n=t.cloneNode(!1);return n.textContent=r,n}}catch(t){if(this.context.logger.error("Unable to access cssRules property",t),"SecurityError"!==t.name)throw t}return t.cloneNode(!1)},t.prototype.createCanvasClone=function(t){var e;if(this.options.inlineImages&&t.ownerDocument){var r=t.ownerDocument.createElement("img");try{return r.src=t.toDataURL(),r}catch(e){this.context.logger.info("Unable to inline canvas contents, canvas is tainted",t)}}var n=t.cloneNode(!1);try{n.width=t.width,n.height=t.height;var i=t.getContext("2d"),o=n.getContext("2d");if(o)if(!this.options.allowTaint&&i)o.putImageData(i.getImageData(0,0,t.width,t.height),0,0);else{var a=null!==(e=t.getContext("webgl2"))&&void 0!==e?e:t.getContext("webgl");if(a){var s=a.getContextAttributes();!1===(null==s?void 0:s.preserveDrawingBuffer)&&this.context.logger.warn("Unable to clone WebGL context as it has preserveDrawingBuffer=false",t)}o.drawImage(t,0,0)}return n}catch(e){this.context.logger.info("Unable to clone canvas as it is tainted",t)}return n},t.prototype.createVideoClone=function(t){var e=t.ownerDocument.createElement("canvas");e.width=t.offsetWidth,e.height=t.offsetHeight;var r=e.getContext("2d");try{return r&&(r.drawImage(t,0,0,e.width,e.height),this.options.allowTaint||r.getImageData(0,0,e.width,e.height)),e}catch(e){this.context.logger.info("Unable to clone video as it is tainted",t)}var n=t.ownerDocument.createElement("canvas");return n.width=t.offsetWidth,n.height=t.offsetHeight,n},t.prototype.appendChildNode=function(t,e,r){ci(e)&&("SCRIPT"===e.tagName||e.hasAttribute("data-html2canvas-ignore")||"function"==typeof this.options.ignoreElements&&this.options.ignoreElements(e))||this.options.copyStyles&&ci(e)&&Ci(e)||t.appendChild(this.cloneNode(e,r))},t.prototype.cloneChildNodes=function(t,e,r){for(var n=this,i=t.shadowRoot?t.shadowRoot.firstChild:t.firstChild;i;i=i.nextSibling)if(ci(i)&&Ei(i)&&"function"==typeof i.assignedNodes){var o=i.assignedNodes();o.length&&o.forEach((function(t){return n.appendChildNode(e,t,r)}))}else this.appendChildNode(e,i,r)},t.prototype.cloneNode=function(t,e){if(li(t))return document.createTextNode(t.data);if(!t.ownerDocument)return t.cloneNode(!1);var r=t.ownerDocument.defaultView;if(r&&ci(t)&&(ui(t)||hi(t))){var n=this.createElementClone(t);n.style.transitionProperty="none";var i=r.getComputedStyle(t),o=r.getComputedStyle(t,":before"),a=r.getComputedStyle(t,":after");this.referenceElement===t&&ui(n)&&(this.clonedReferenceElement=n),mi(n)&&Ji(n);var s=this.counters.parse(new An(this.context,i)),A=this.resolvePseudoContent(t,n,o,wn.BEFORE);Si(t)&&(e=!0),yi(t)||this.cloneChildNodes(t,n,e),A&&n.insertBefore(A,n.firstChild);var l=this.resolvePseudoContent(t,n,a,wn.AFTER);return l&&n.appendChild(l),this.counters.pop(s),(i&&(this.options.copyStyles||hi(t))&&!bi(t)||e)&&Vi(i,n),0===t.scrollTop&&0===t.scrollLeft||this.scrolledElements.push([n,t.scrollLeft,t.scrollTop]),(Bi(t)||xi(t))&&(Bi(n)||xi(n))&&(n.value=t.value),n}return t.cloneNode(!1)},t.prototype.resolvePseudoContent=function(t,e,r,n){var i=this;if(r){var o=r.content,a=e.ownerDocument;if(a&&o&&"none"!==o&&"-moz-alt-content"!==o&&"none"!==r.display){this.counters.parse(new An(this.context,r));var s=new sn(this.context,r),A=a.createElement("html2canvaspseudoelement");Vi(r,A),s.content.forEach((function(e){if(0===e.type)A.appendChild(a.createTextNode(e.value));else if(22===e.type){var r=a.createElement("img");r.src=e.value,r.style.opacity="1",A.appendChild(r)}else if(18===e.type){if("attr"===e.name){var n=e.values.filter(Ht);n.length&&A.appendChild(a.createTextNode(t.getAttribute(n[0].value)||""))}else if("counter"===e.name){var o=e.values.filter(Gt),l=o[0],c=o[1];if(l&&Ht(l)){var u=i.counters.getCounterValue(l.value),h=c&&Ht(c)?fr.parse(i.context,c.value):3;A.appendChild(a.createTextNode(Mi(u,h,!1)))}}else if("counters"===e.name){var d=e.values.filter(Gt),f=(l=d[0],d[1]);if(c=d[2],l&&Ht(l)){var p=i.counters.getCounterValues(l.value),g=c&&Ht(c)?fr.parse(i.context,c.value):3,m=f&&0===f.type?f.value:"",v=p.map((function(t){return Mi(t,g,!1)})).join(m);A.appendChild(a.createTextNode(v))}}}else if(20===e.type)switch(e.value){case"open-quote":A.appendChild(a.createTextNode(tn(s.quotes,i.quoteDepth++,!0)));break;case"close-quote":A.appendChild(a.createTextNode(tn(s.quotes,--i.quoteDepth,!1)));break;default:A.appendChild(a.createTextNode(e.value))}})),A.className=Xi+" "+qi;var l=n===wn.BEFORE?" "+Xi:" "+qi;return hi(e)?e.className.baseValue+=l:e.className+=l,A}}},t.destroy=function(t){return!!t.parentNode&&(t.parentNode.removeChild(t),!0)},t}();!function(t){t[t.BEFORE=0]="BEFORE",t[t.AFTER=1]="AFTER"}(wn||(wn={}));var Pi,Hi=function(t,e){var r=t.createElement("iframe");return r.className="html2canvas-container",r.style.visibility="hidden",r.style.position="fixed",r.style.left="-10000px",r.style.top="0px",r.style.border="0",r.width=e.width.toString(),r.height=e.height.toString(),r.scrolling="no",r.setAttribute("data-html2canvas-ignore","true"),t.body.appendChild(r),r},Ni=function(t){return new Promise((function(e){t.complete?e():t.src?(t.onload=e,t.onerror=e):e()}))},Ki=function(t){return Promise.all([].slice.call(t.images,0).map(Ni))},ji=function(t){return new Promise((function(e,r){var n=t.contentWindow;if(!n)return r("No window assigned for iframe");var i=n.document;n.onload=t.onload=function(){n.onload=t.onload=null;var r=setInterval((function(){i.body.childNodes.length>0&&"complete"===i.readyState&&(clearInterval(r),e(t))}),50)}}))},Gi=["all","d","content"],Vi=function(t,e){for(var r=t.length-1;r>=0;r--){var n=t.item(r);-1===Gi.indexOf(n)&&e.style.setProperty(n,t.getPropertyValue(n))}return e},zi=function(t){var e="";return t&&(e+="<!DOCTYPE ",t.name&&(e+=t.name),t.internalSubset&&(e+=t.internalSubset),t.publicId&&(e+='"'+t.publicId+'"'),t.systemId&&(e+='"'+t.systemId+'"'),e+=">"),e},Wi=function(t,e,r){t&&t.defaultView&&(e!==t.defaultView.pageXOffset||r!==t.defaultView.pageYOffset)&&t.defaultView.scrollTo(e,r)},Yi=function(t){var e=t[0],r=t[1],n=t[2];e.scrollLeft=r,e.scrollTop=n},Xi="___html2canvas___pseudoelement_before",qi="___html2canvas___pseudoelement_after",Ji=function(t){Zi(t,"."+Xi+':before{\n content: "" !important;\n display: none !important;\n}\n .'+qi+':after{\n content: "" !important;\n display: none !important;\n}')},Zi=function(t,e){var r=t.ownerDocument;if(r){var n=r.createElement("style");n.textContent=e,t.appendChild(n)}},$i=function(){function t(){}return t.getOrigin=function(e){var r=t._link;return r?(r.href=e,r.href=r.href,r.protocol+r.hostname+r.port):"about:blank"},t.isSameOrigin=function(e){return t.getOrigin(e)===t._origin},t.setContext=function(e){t._link=e.document.createElement("a"),t._origin=t.getOrigin(e.location.href)},t._origin="about:blank",t}(),to=function(){function t(t,e){this.context=t,this._options=e,this._cache={}}return t.prototype.addImage=function(t){var e=Promise.resolve();return this.has(t)?e:so(t)||io(t)?((this._cache[t]=this.loadImage(t)).catch((function(){})),e):e},t.prototype.match=function(t){return this._cache[t]},t.prototype.loadImage=function(t){return n(this,void 0,void 0,(function(){var e,r,n,o,a=this;return i(this,(function(i){switch(i.label){case 0:return e=$i.isSameOrigin(t),r=!oo(t)&&!0===this._options.useCORS&&Un.SUPPORT_CORS_IMAGES&&!e,n=!oo(t)&&!e&&!so(t)&&"string"==typeof this._options.proxy&&Un.SUPPORT_CORS_XHR&&!r,e||!1!==this._options.allowTaint||oo(t)||so(t)||n||r?(o=t,n?[4,this.proxy(o)]:[3,2]):[2];case 1:o=i.sent(),i.label=2;case 2:return this.context.logger.debug("Added image "+t.substring(0,256)),[4,new Promise((function(t,e){var n=new Image;n.onload=function(){return t(n)},n.onerror=e,(ao(o)||r)&&(n.crossOrigin="anonymous"),n.src=o,!0===n.complete&&setTimeout((function(){return t(n)}),500),a._options.imageTimeout>0&&setTimeout((function(){return e("Timed out ("+a._options.imageTimeout+"ms) loading image")}),a._options.imageTimeout)}))];case 3:return[2,i.sent()]}}))}))},t.prototype.has=function(t){return void 0!==this._cache[t]},t.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},t.prototype.proxy=function(t){var e=this,r=this._options.proxy;if(!r)throw new Error("No proxy defined");var n=t.substring(0,256);return new Promise((function(i,o){var a=Un.SUPPORT_RESPONSE_TYPE?"blob":"text",s=new XMLHttpRequest;s.onload=function(){if(200===s.status)if("text"===a)i(s.response);else{var t=new FileReader;t.addEventListener("load",(function(){return i(t.result)}),!1),t.addEventListener("error",(function(t){return o(t)}),!1),t.readAsDataURL(s.response)}else o("Failed to proxy resource "+n+" with status code "+s.status)},s.onerror=o;var A=r.indexOf("?")>-1?"&":"?";if(s.open("GET",""+r+A+"url="+encodeURIComponent(t)+"&responseType="+a),"text"!==a&&s instanceof XMLHttpRequest&&(s.responseType=a),e._options.imageTimeout){var l=e._options.imageTimeout;s.timeout=l,s.ontimeout=function(){return o("Timed out ("+l+"ms) proxying "+n)}}s.send()}))},t}(),eo=/^data:image\/svg\+xml/i,ro=/^data:image\/.*;base64,/i,no=/^data:image\/.*/i,io=function(t){return Un.SUPPORT_SVG_DRAWING||!Ao(t)},oo=function(t){return no.test(t)},ao=function(t){return ro.test(t)},so=function(t){return"blob"===t.substr(0,4)},Ao=function(t){return"svg"===t.substr(-3).toLowerCase()||eo.test(t)},lo=function(){function t(t,e){this.type=0,this.x=t,this.y=e}return t.prototype.add=function(e,r){return new t(this.x+e,this.y+r)},t}(),co=function(t,e,r){return new lo(t.x+(e.x-t.x)*r,t.y+(e.y-t.y)*r)},uo=function(){function t(t,e,r,n){this.type=1,this.start=t,this.startControl=e,this.endControl=r,this.end=n}return t.prototype.subdivide=function(e,r){var n=co(this.start,this.startControl,e),i=co(this.startControl,this.endControl,e),o=co(this.endControl,this.end,e),a=co(n,i,e),s=co(i,o,e),A=co(a,s,e);return r?new t(this.start,n,a,A):new t(A,s,o,this.end)},t.prototype.add=function(e,r){return new t(this.start.add(e,r),this.startControl.add(e,r),this.endControl.add(e,r),this.end.add(e,r))},t.prototype.reverse=function(){return new t(this.end,this.endControl,this.startControl,this.start)},t}(),ho=function(t){return 1===t.type},fo=function(t){var e=t.styles,r=t.bounds,n=$t(e.borderTopLeftRadius,r.width,r.height),i=n[0],o=n[1],a=$t(e.borderTopRightRadius,r.width,r.height),s=a[0],A=a[1],l=$t(e.borderBottomRightRadius,r.width,r.height),c=l[0],u=l[1],h=$t(e.borderBottomLeftRadius,r.width,r.height),d=h[0],f=h[1],p=[];p.push((i+s)/r.width),p.push((d+c)/r.width),p.push((o+f)/r.height),p.push((A+u)/r.height);var g=Math.max.apply(Math,p);g>1&&(i/=g,o/=g,s/=g,A/=g,c/=g,u/=g,d/=g,f/=g);var m=r.width-s,v=r.height-u,y=r.width-c,w=r.height-f,b=e.borderTopWidth,C=e.borderRightWidth,B=e.borderBottomWidth,x=e.borderLeftWidth,E=te(e.paddingTop,t.bounds.width),S=te(e.paddingRight,t.bounds.width),k=te(e.paddingBottom,t.bounds.width),T=te(e.paddingLeft,t.bounds.width);this.topLeftBorderDoubleOuterBox=i>0||o>0?po(r.left+x/3,r.top+b/3,i-x/3,o-b/3,Pi.TOP_LEFT):new lo(r.left+x/3,r.top+b/3),this.topRightBorderDoubleOuterBox=i>0||o>0?po(r.left+m,r.top+b/3,s-C/3,A-b/3,Pi.TOP_RIGHT):new lo(r.left+r.width-C/3,r.top+b/3),this.bottomRightBorderDoubleOuterBox=c>0||u>0?po(r.left+y,r.top+v,c-C/3,u-B/3,Pi.BOTTOM_RIGHT):new lo(r.left+r.width-C/3,r.top+r.height-B/3),this.bottomLeftBorderDoubleOuterBox=d>0||f>0?po(r.left+x/3,r.top+w,d-x/3,f-B/3,Pi.BOTTOM_LEFT):new lo(r.left+x/3,r.top+r.height-B/3),this.topLeftBorderDoubleInnerBox=i>0||o>0?po(r.left+2*x/3,r.top+2*b/3,i-2*x/3,o-2*b/3,Pi.TOP_LEFT):new lo(r.left+2*x/3,r.top+2*b/3),this.topRightBorderDoubleInnerBox=i>0||o>0?po(r.left+m,r.top+2*b/3,s-2*C/3,A-2*b/3,Pi.TOP_RIGHT):new lo(r.left+r.width-2*C/3,r.top+2*b/3),this.bottomRightBorderDoubleInnerBox=c>0||u>0?po(r.left+y,r.top+v,c-2*C/3,u-2*B/3,Pi.BOTTOM_RIGHT):new lo(r.left+r.width-2*C/3,r.top+r.height-2*B/3),this.bottomLeftBorderDoubleInnerBox=d>0||f>0?po(r.left+2*x/3,r.top+w,d-2*x/3,f-2*B/3,Pi.BOTTOM_LEFT):new lo(r.left+2*x/3,r.top+r.height-2*B/3),this.topLeftBorderStroke=i>0||o>0?po(r.left+x/2,r.top+b/2,i-x/2,o-b/2,Pi.TOP_LEFT):new lo(r.left+x/2,r.top+b/2),this.topRightBorderStroke=i>0||o>0?po(r.left+m,r.top+b/2,s-C/2,A-b/2,Pi.TOP_RIGHT):new lo(r.left+r.width-C/2,r.top+b/2),this.bottomRightBorderStroke=c>0||u>0?po(r.left+y,r.top+v,c-C/2,u-B/2,Pi.BOTTOM_RIGHT):new lo(r.left+r.width-C/2,r.top+r.height-B/2),this.bottomLeftBorderStroke=d>0||f>0?po(r.left+x/2,r.top+w,d-x/2,f-B/2,Pi.BOTTOM_LEFT):new lo(r.left+x/2,r.top+r.height-B/2),this.topLeftBorderBox=i>0||o>0?po(r.left,r.top,i,o,Pi.TOP_LEFT):new lo(r.left,r.top),this.topRightBorderBox=s>0||A>0?po(r.left+m,r.top,s,A,Pi.TOP_RIGHT):new lo(r.left+r.width,r.top),this.bottomRightBorderBox=c>0||u>0?po(r.left+y,r.top+v,c,u,Pi.BOTTOM_RIGHT):new lo(r.left+r.width,r.top+r.height),this.bottomLeftBorderBox=d>0||f>0?po(r.left,r.top+w,d,f,Pi.BOTTOM_LEFT):new lo(r.left,r.top+r.height),this.topLeftPaddingBox=i>0||o>0?po(r.left+x,r.top+b,Math.max(0,i-x),Math.max(0,o-b),Pi.TOP_LEFT):new lo(r.left+x,r.top+b),this.topRightPaddingBox=s>0||A>0?po(r.left+Math.min(m,r.width-C),r.top+b,m>r.width+C?0:Math.max(0,s-C),Math.max(0,A-b),Pi.TOP_RIGHT):new lo(r.left+r.width-C,r.top+b),this.bottomRightPaddingBox=c>0||u>0?po(r.left+Math.min(y,r.width-x),r.top+Math.min(v,r.height-B),Math.max(0,c-C),Math.max(0,u-B),Pi.BOTTOM_RIGHT):new lo(r.left+r.width-C,r.top+r.height-B),this.bottomLeftPaddingBox=d>0||f>0?po(r.left+x,r.top+Math.min(w,r.height-B),Math.max(0,d-x),Math.max(0,f-B),Pi.BOTTOM_LEFT):new lo(r.left+x,r.top+r.height-B),this.topLeftContentBox=i>0||o>0?po(r.left+x+T,r.top+b+E,Math.max(0,i-(x+T)),Math.max(0,o-(b+E)),Pi.TOP_LEFT):new lo(r.left+x+T,r.top+b+E),this.topRightContentBox=s>0||A>0?po(r.left+Math.min(m,r.width+x+T),r.top+b+E,m>r.width+x+T?0:s-x+T,A-(b+E),Pi.TOP_RIGHT):new lo(r.left+r.width-(C+S),r.top+b+E),this.bottomRightContentBox=c>0||u>0?po(r.left+Math.min(y,r.width-(x+T)),r.top+Math.min(v,r.height+b+E),Math.max(0,c-(C+S)),u-(B+k),Pi.BOTTOM_RIGHT):new lo(r.left+r.width-(C+S),r.top+r.height-(B+k)),this.bottomLeftContentBox=d>0||f>0?po(r.left+x+T,r.top+w,Math.max(0,d-(x+T)),f-(B+k),Pi.BOTTOM_LEFT):new lo(r.left+x+T,r.top+r.height-(B+k))};!function(t){t[t.TOP_LEFT=0]="TOP_LEFT",t[t.TOP_RIGHT=1]="TOP_RIGHT",t[t.BOTTOM_RIGHT=2]="BOTTOM_RIGHT",t[t.BOTTOM_LEFT=3]="BOTTOM_LEFT"}(Pi||(Pi={}));var po=function(t,e,r,n,i){var o=(Math.sqrt(2)-1)/3*4,a=r*o,s=n*o,A=t+r,l=e+n;switch(i){case Pi.TOP_LEFT:return new uo(new lo(t,l),new lo(t,l-s),new lo(A-a,e),new lo(A,e));case Pi.TOP_RIGHT:return new uo(new lo(t,e),new lo(t+a,e),new lo(A,l-s),new lo(A,l));case Pi.BOTTOM_RIGHT:return new uo(new lo(A,e),new lo(A,e+s),new lo(t+a,l),new lo(t,l));case Pi.BOTTOM_LEFT:default:return new uo(new lo(A,l),new lo(A-a,l),new lo(t,e+s),new lo(t,e))}},go=function(t){return[t.topLeftBorderBox,t.topRightBorderBox,t.bottomRightBorderBox,t.bottomLeftBorderBox]},mo=function(t){return[t.topLeftPaddingBox,t.topRightPaddingBox,t.bottomRightPaddingBox,t.bottomLeftPaddingBox]},vo=function(t,e,r){this.offsetX=t,this.offsetY=e,this.matrix=r,this.type=0,this.target=6},yo=function(t,e){this.path=t,this.target=e,this.type=1},wo=function(t){this.opacity=t,this.type=2,this.target=6},bo=function(t){return 1===t.type},Co=function(t,e){return t.length===e.length&&t.some((function(t,r){return t===e[r]}))},Bo=function(t){this.element=t,this.inlineLevel=[],this.nonInlineLevel=[],this.negativeZIndex=[],this.zeroOrAutoZIndexOrTransformedOrOpacity=[],this.positiveZIndex=[],this.nonPositionedFloats=[],this.nonPositionedInlineLevel=[]},xo=function(){function t(t,e){if(this.container=t,this.parent=e,this.effects=[],this.curves=new fo(this.container),this.container.styles.opacity<1&&this.effects.push(new wo(this.container.styles.opacity)),null!==this.container.styles.transform){var r=this.container.bounds.left+this.container.styles.transformOrigin[0].number,n=this.container.bounds.top+this.container.styles.transformOrigin[1].number,i=this.container.styles.transform;this.effects.push(new vo(r,n,i))}if(0!==this.container.styles.overflowX){var o=go(this.curves),a=mo(this.curves);Co(o,a)?this.effects.push(new yo(o,6)):(this.effects.push(new yo(o,2)),this.effects.push(new yo(a,4)))}}return t.prototype.getEffects=function(t){for(var e=-1===[2,3].indexOf(this.container.styles.position),r=this.parent,n=this.effects.slice(0);r;){var i=r.effects.filter((function(t){return!bo(t)}));if(e||0!==r.container.styles.position||!r.parent){if(n.unshift.apply(n,i),e=-1===[2,3].indexOf(r.container.styles.position),0!==r.container.styles.overflowX){var o=go(r.curves),a=mo(r.curves);Co(o,a)||n.unshift(new yo(a,6))}}else n.unshift.apply(n,i);r=r.parent}return n.filter((function(e){return Yr(e.target,t)}))},t}(),Eo=function(t,e,r,n){t.container.elements.forEach((function(i){var o=Yr(i.flags,4),a=Yr(i.flags,2),s=new xo(i,t);Yr(i.styles.display,2048)&&n.push(s);var A=Yr(i.flags,8)?[]:n;if(o||a){var l=o||i.styles.isPositioned()?r:e,c=new Bo(s);if(i.styles.isPositioned()||i.styles.opacity<1||i.styles.isTransformed()){var u=i.styles.zIndex.order;if(u<0){var h=0;l.negativeZIndex.some((function(t,e){return u>t.element.container.styles.zIndex.order?(h=e,!1):h>0})),l.negativeZIndex.splice(h,0,c)}else if(u>0){var d=0;l.positiveZIndex.some((function(t,e){return u>=t.element.container.styles.zIndex.order?(d=e+1,!1):d>0})),l.positiveZIndex.splice(d,0,c)}else l.zeroOrAutoZIndexOrTransformedOrOpacity.push(c)}else i.styles.isFloating()?l.nonPositionedFloats.push(c):l.nonPositionedInlineLevel.push(c);Eo(s,c,o?c:r,A)}else i.styles.isInlineLevel()?e.inlineLevel.push(s):e.nonInlineLevel.push(s),Eo(s,e,r,A);Yr(i.flags,8)&&So(i,A)}))},So=function(t,e){for(var r=t instanceof Xn?t.start:1,n=t instanceof Xn&&t.reversed,i=0;i<e.length;i++){var o=e[i];o.container instanceof Yn&&"number"==typeof o.container.value&&0!==o.container.value&&(r=o.container.value),o.listValue=Mi(r,o.container.styles.listStyleType,!0),r+=n?-1:1}},ko=function(t,e){switch(e){case 0:return Fo(t.topLeftBorderBox,t.topLeftPaddingBox,t.topRightBorderBox,t.topRightPaddingBox);case 1:return Fo(t.topRightBorderBox,t.topRightPaddingBox,t.bottomRightBorderBox,t.bottomRightPaddingBox);case 2:return Fo(t.bottomRightBorderBox,t.bottomRightPaddingBox,t.bottomLeftBorderBox,t.bottomLeftPaddingBox);case 3:default:return Fo(t.bottomLeftBorderBox,t.bottomLeftPaddingBox,t.topLeftBorderBox,t.topLeftPaddingBox)}},To=function(t,e){var r=[];return ho(t)?r.push(t.subdivide(.5,!1)):r.push(t),ho(e)?r.push(e.subdivide(.5,!0)):r.push(e),r},Fo=function(t,e,r,n){var i=[];return ho(t)?i.push(t.subdivide(.5,!1)):i.push(t),ho(r)?i.push(r.subdivide(.5,!0)):i.push(r),ho(n)?i.push(n.subdivide(.5,!0).reverse()):i.push(n),ho(e)?i.push(e.subdivide(.5,!1).reverse()):i.push(e),i},Lo=function(t){var e=t.bounds,r=t.styles;return e.add(r.borderLeftWidth,r.borderTopWidth,-(r.borderRightWidth+r.borderLeftWidth),-(r.borderTopWidth+r.borderBottomWidth))},Io=function(t){var e=t.styles,r=t.bounds,n=te(e.paddingLeft,r.width),i=te(e.paddingRight,r.width),o=te(e.paddingTop,r.width),a=te(e.paddingBottom,r.width);return r.add(n+e.borderLeftWidth,o+e.borderTopWidth,-(e.borderRightWidth+e.borderLeftWidth+n+i),-(e.borderTopWidth+e.borderBottomWidth+o+a))},_o=function(t,e,r){var n=function(t,e){return 0===t?e.bounds:2===t?Io(e):Lo(e)}(Qo(t.styles.backgroundOrigin,e),t),i=function(t,e){return 0===t?e.bounds:2===t?Io(e):Lo(e)}(Qo(t.styles.backgroundClip,e),t),o=Do(Qo(t.styles.backgroundSize,e),r,n),a=o[0],s=o[1],A=$t(Qo(t.styles.backgroundPosition,e),n.width-a,n.height-s);return[Mo(Qo(t.styles.backgroundRepeat,e),A,o,n,i),Math.round(n.left+A[0]),Math.round(n.top+A[1]),a,s]},Uo=function(t){return Ht(t)&&t.value===he.AUTO},Oo=function(t){return"number"==typeof t},Do=function(t,e,r){var n=e[0],i=e[1],o=e[2],a=t[0],s=t[1];if(!a)return[0,0];if(Yt(a)&&s&&Yt(s))return[te(a,r.width),te(s,r.height)];var A=Oo(o);if(Ht(a)&&(a.value===he.CONTAIN||a.value===he.COVER))return Oo(o)?r.width/r.height<o!=(a.value===he.COVER)?[r.width,r.width/o]:[r.height*o,r.height]:[r.width,r.height];var l=Oo(n),c=Oo(i),u=l||c;if(Uo(a)&&(!s||Uo(s)))return l&&c?[n,i]:A||u?u&&A?[l?n:i*o,c?i:n/o]:[l?n:r.width,c?i:r.height]:[r.width,r.height];if(A){var h=0,d=0;return Yt(a)?h=te(a,r.width):Yt(s)&&(d=te(s,r.height)),Uo(a)?h=d*o:s&&!Uo(s)||(d=h/o),[h,d]}var f=null,p=null;if(Yt(a)?f=te(a,r.width):s&&Yt(s)&&(p=te(s,r.height)),null===f||s&&!Uo(s)||(p=l&&c?f/n*i:r.height),null!==p&&Uo(a)&&(f=l&&c?p/i*n:r.width),null!==f&&null!==p)return[f,p];throw new Error("Unable to calculate background-size for element")},Qo=function(t,e){var r=t[e];return void 0===r?t[0]:r},Mo=function(t,e,r,n,i){var o=e[0],a=e[1],s=r[0],A=r[1];switch(t){case 2:return[new lo(Math.round(n.left),Math.round(n.top+a)),new lo(Math.round(n.left+n.width),Math.round(n.top+a)),new lo(Math.round(n.left+n.width),Math.round(A+n.top+a)),new lo(Math.round(n.left),Math.round(A+n.top+a))];case 3:return[new lo(Math.round(n.left+o),Math.round(n.top)),new lo(Math.round(n.left+o+s),Math.round(n.top)),new lo(Math.round(n.left+o+s),Math.round(n.height+n.top)),new lo(Math.round(n.left+o),Math.round(n.height+n.top))];case 1:return[new lo(Math.round(n.left+o),Math.round(n.top+a)),new lo(Math.round(n.left+o+s),Math.round(n.top+a)),new lo(Math.round(n.left+o+s),Math.round(n.top+a+A)),new lo(Math.round(n.left+o),Math.round(n.top+a+A))];default:return[new lo(Math.round(i.left),Math.round(i.top)),new lo(Math.round(i.left+i.width),Math.round(i.top)),new lo(Math.round(i.left+i.width),Math.round(i.height+i.top)),new lo(Math.round(i.left),Math.round(i.height+i.top))]}},Ro=function(){function t(t){this._data={},this._document=t}return t.prototype.parseMetrics=function(t,e){var r=this._document.createElement("div"),n=this._document.createElement("img"),i=this._document.createElement("span"),o=this._document.body;r.style.visibility="hidden",r.style.fontFamily=t,r.style.fontSize=e,r.style.margin="0",r.style.padding="0",r.style.whiteSpace="nowrap",o.appendChild(r),n.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",n.width=1,n.height=1,n.style.margin="0",n.style.padding="0",n.style.verticalAlign="baseline",i.style.fontFamily=t,i.style.fontSize=e,i.style.margin="0",i.style.padding="0",i.appendChild(this._document.createTextNode("Hidden Text")),r.appendChild(i),r.appendChild(n);var a=n.offsetTop-i.offsetTop+2;r.removeChild(i),r.appendChild(this._document.createTextNode("Hidden Text")),r.style.lineHeight="normal",n.style.verticalAlign="super";var s=n.offsetTop-r.offsetTop+2;return o.removeChild(r),{baseline:a,middle:s}},t.prototype.getMetrics=function(t,e){var r=t+" "+e;return void 0===this._data[r]&&(this._data[r]=this.parseMetrics(t,e)),this._data[r]},t}(),Po=function(t,e){this.context=t,this.options=e},Ho=function(t){function r(e,r){var n=t.call(this,e,r)||this;return n._activeEffects=[],n.canvas=r.canvas?r.canvas:document.createElement("canvas"),n.ctx=n.canvas.getContext("2d"),r.canvas||(n.canvas.width=Math.floor(r.width*r.scale),n.canvas.height=Math.floor(r.height*r.scale),n.canvas.style.width=r.width+"px",n.canvas.style.height=r.height+"px"),n.fontMetrics=new Ro(document),n.ctx.scale(n.options.scale,n.options.scale),n.ctx.translate(-r.x,-r.y),n.ctx.textBaseline="bottom",n._activeEffects=[],n.context.logger.debug("Canvas renderer initialized ("+r.width+"x"+r.height+") with scale "+r.scale),n}return e(r,t),r.prototype.applyEffects=function(t){for(var e=this;this._activeEffects.length;)this.popEffect();t.forEach((function(t){return e.applyEffect(t)}))},r.prototype.applyEffect=function(t){this.ctx.save(),function(t){return 2===t.type}(t)&&(this.ctx.globalAlpha=t.opacity),function(t){return 0===t.type}(t)&&(this.ctx.translate(t.offsetX,t.offsetY),this.ctx.transform(t.matrix[0],t.matrix[1],t.matrix[2],t.matrix[3],t.matrix[4],t.matrix[5]),this.ctx.translate(-t.offsetX,-t.offsetY)),bo(t)&&(this.path(t.path),this.ctx.clip()),this._activeEffects.push(t)},r.prototype.popEffect=function(){this._activeEffects.pop(),this.ctx.restore()},r.prototype.renderStack=function(t){return n(this,void 0,void 0,(function(){return i(this,(function(e){switch(e.label){case 0:return t.element.container.styles.isVisible()?[4,this.renderStackContent(t)]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}}))}))},r.prototype.renderNode=function(t){return n(this,void 0,void 0,(function(){return i(this,(function(e){switch(e.label){case 0:return Yr(t.container.flags,16),t.container.styles.isVisible()?[4,this.renderNodeBackgroundAndBorders(t)]:[3,3];case 1:return e.sent(),[4,this.renderNodeContent(t)];case 2:e.sent(),e.label=3;case 3:return[2]}}))}))},r.prototype.renderTextWithLetterSpacing=function(t,e,r){var n=this;0===e?this.ctx.fillText(t.text,t.bounds.left,t.bounds.top+r):Mn(t.text).reduce((function(e,i){return n.ctx.fillText(i,e,t.bounds.top+r),e+n.ctx.measureText(i).width}),t.bounds.left)},r.prototype.createFontStyle=function(t){var e=t.fontVariant.filter((function(t){return"normal"===t||"small-caps"===t})).join(""),r=Vo(t.fontFamily).join(", "),n=Rt(t.fontSize)?""+t.fontSize.number+t.fontSize.unit:t.fontSize.number+"px";return[[t.fontStyle,e,t.fontWeight,n,r].join(" "),r,n]},r.prototype.renderTextNode=function(t,e){return n(this,void 0,void 0,(function(){var r,n,o,a,s,A,l,c,u=this;return i(this,(function(i){return r=this.createFontStyle(e),n=r[0],o=r[1],a=r[2],this.ctx.font=n,this.ctx.direction=1===e.direction?"rtl":"ltr",this.ctx.textAlign="left",this.ctx.textBaseline="alphabetic",s=this.fontMetrics.getMetrics(o,a),A=s.baseline,l=s.middle,c=e.paintOrder,t.textBounds.forEach((function(t){c.forEach((function(r){switch(r){case 0:u.ctx.fillStyle=se(e.color),u.renderTextWithLetterSpacing(t,e.letterSpacing,A);var n=e.textShadow;n.length&&t.text.trim().length&&(n.slice(0).reverse().forEach((function(r){u.ctx.shadowColor=se(r.color),u.ctx.shadowOffsetX=r.offsetX.number*u.options.scale,u.ctx.shadowOffsetY=r.offsetY.number*u.options.scale,u.ctx.shadowBlur=r.blur.number,u.renderTextWithLetterSpacing(t,e.letterSpacing,A)})),u.ctx.shadowColor="",u.ctx.shadowOffsetX=0,u.ctx.shadowOffsetY=0,u.ctx.shadowBlur=0),e.textDecorationLine.length&&(u.ctx.fillStyle=se(e.textDecorationColor||e.color),e.textDecorationLine.forEach((function(e){switch(e){case 1:u.ctx.fillRect(t.bounds.left,Math.round(t.bounds.top+A),t.bounds.width,1);break;case 2:u.ctx.fillRect(t.bounds.left,Math.round(t.bounds.top),t.bounds.width,1);break;case 3:u.ctx.fillRect(t.bounds.left,Math.ceil(t.bounds.top+l),t.bounds.width,1)}})));break;case 1:e.webkitTextStrokeWidth&&t.text.trim().length&&(u.ctx.strokeStyle=se(e.webkitTextStrokeColor),u.ctx.lineWidth=e.webkitTextStrokeWidth,u.ctx.lineJoin=window.chrome?"miter":"round",u.ctx.strokeText(t.text,t.bounds.left,t.bounds.top+A)),u.ctx.strokeStyle="",u.ctx.lineWidth=0,u.ctx.lineJoin="miter"}}))})),[2]}))}))},r.prototype.renderReplacedElement=function(t,e,r){if(r&&t.intrinsicWidth>0&&t.intrinsicHeight>0){var n=Io(t),i=mo(e);this.path(i),this.ctx.save(),this.ctx.clip(),this.ctx.drawImage(r,0,0,t.intrinsicWidth,t.intrinsicHeight,n.left,n.top,n.width,n.height),this.ctx.restore()}},r.prototype.renderNodeContent=function(t){return n(this,void 0,void 0,(function(){var e,n,o,s,A,l,c,u,h,d,f,p,g,m,v,y,w,b;return i(this,(function(i){switch(i.label){case 0:this.applyEffects(t.getEffects(4)),e=t.container,n=t.curves,o=e.styles,s=0,A=e.textNodes,i.label=1;case 1:return s<A.length?(l=A[s],[4,this.renderTextNode(l,o)]):[3,4];case 2:i.sent(),i.label=3;case 3:return s++,[3,1];case 4:if(!(e instanceof Vn))return[3,8];i.label=5;case 5:return i.trys.push([5,7,,8]),[4,this.context.cache.match(e.src)];case 6:return v=i.sent(),this.renderReplacedElement(e,n,v),[3,8];case 7:return i.sent(),this.context.logger.error("Error loading image "+e.src),[3,8];case 8:if(e instanceof zn&&this.renderReplacedElement(e,n,e.canvas),!(e instanceof Wn))return[3,12];i.label=9;case 9:return i.trys.push([9,11,,12]),[4,this.context.cache.match(e.svg)];case 10:return v=i.sent(),this.renderReplacedElement(e,n,v),[3,12];case 11:return i.sent(),this.context.logger.error("Error loading svg "+e.svg.substring(0,255)),[3,12];case 12:return e instanceof ri&&e.tree?[4,new r(this.context,{scale:this.options.scale,backgroundColor:e.backgroundColor,x:0,y:0,width:e.width,height:e.height}).render(e.tree)]:[3,14];case 13:c=i.sent(),e.width&&e.height&&this.ctx.drawImage(c,0,0,e.width,e.height,e.bounds.left,e.bounds.top,e.bounds.width,e.bounds.height),i.label=14;case 14:if(e instanceof $n&&(u=Math.min(e.bounds.width,e.bounds.height),"checkbox"===e.type?e.checked&&(this.ctx.save(),this.path([new lo(e.bounds.left+.39363*u,e.bounds.top+.79*u),new lo(e.bounds.left+.16*u,e.bounds.top+.5549*u),new lo(e.bounds.left+.27347*u,e.bounds.top+.44071*u),new lo(e.bounds.left+.39694*u,e.bounds.top+.5649*u),new lo(e.bounds.left+.72983*u,e.bounds.top+.23*u),new lo(e.bounds.left+.84*u,e.bounds.top+.34085*u),new lo(e.bounds.left+.39363*u,e.bounds.top+.79*u)]),this.ctx.fillStyle=se(707406591),this.ctx.fill(),this.ctx.restore()):"radio"===e.type&&e.checked&&(this.ctx.save(),this.ctx.beginPath(),this.ctx.arc(e.bounds.left+u/2,e.bounds.top+u/2,u/4,0,2*Math.PI,!0),this.ctx.fillStyle=se(707406591),this.ctx.fill(),this.ctx.restore())),No(e)&&e.value.length){switch(h=this.createFontStyle(o),w=h[0],d=h[1],f=this.fontMetrics.getMetrics(w,d).baseline,this.ctx.font=w,this.ctx.fillStyle=se(o.color),this.ctx.textBaseline="alphabetic",this.ctx.textAlign=jo(e.styles.textAlign),b=Io(e),p=0,e.styles.textAlign){case 1:p+=b.width/2;break;case 2:p+=b.width}g=b.add(p,0,0,-b.height/2+1),this.ctx.save(),this.path([new lo(b.left,b.top),new lo(b.left+b.width,b.top),new lo(b.left+b.width,b.top+b.height),new lo(b.left,b.top+b.height)]),this.ctx.clip(),this.renderTextWithLetterSpacing(new On(e.value,g),o.letterSpacing,f),this.ctx.restore(),this.ctx.textBaseline="alphabetic",this.ctx.textAlign="left"}if(!Yr(e.styles.display,2048))return[3,20];if(null===e.styles.listStyleImage)return[3,19];if(0!==(m=e.styles.listStyleImage).type)return[3,18];v=void 0,y=m.url,i.label=15;case 15:return i.trys.push([15,17,,18]),[4,this.context.cache.match(y)];case 16:return v=i.sent(),this.ctx.drawImage(v,e.bounds.left-(v.width+10),e.bounds.top),[3,18];case 17:return i.sent(),this.context.logger.error("Error loading list-style-image "+y),[3,18];case 18:return[3,20];case 19:t.listValue&&-1!==e.styles.listStyleType&&(w=this.createFontStyle(o)[0],this.ctx.font=w,this.ctx.fillStyle=se(o.color),this.ctx.textBaseline="middle",this.ctx.textAlign="right",b=new a(e.bounds.left,e.bounds.top+te(e.styles.paddingTop,e.bounds.width),e.bounds.width,ur(o.lineHeight,o.fontSize.number)/2+1),this.renderTextWithLetterSpacing(new On(t.listValue,b),o.letterSpacing,ur(o.lineHeight,o.fontSize.number)/2+2),this.ctx.textBaseline="bottom",this.ctx.textAlign="left"),i.label=20;case 20:return[2]}}))}))},r.prototype.renderStackContent=function(t){return n(this,void 0,void 0,(function(){var e,r,n,o,a,s,A,l,c,u,h,d,f,p,g;return i(this,(function(i){switch(i.label){case 0:return Yr(t.element.container.flags,16),[4,this.renderNodeBackgroundAndBorders(t.element)];case 1:i.sent(),e=0,r=t.negativeZIndex,i.label=2;case 2:return e<r.length?(g=r[e],[4,this.renderStack(g)]):[3,5];case 3:i.sent(),i.label=4;case 4:return e++,[3,2];case 5:return[4,this.renderNodeContent(t.element)];case 6:i.sent(),n=0,o=t.nonInlineLevel,i.label=7;case 7:return n<o.length?(g=o[n],[4,this.renderNode(g)]):[3,10];case 8:i.sent(),i.label=9;case 9:return n++,[3,7];case 10:a=0,s=t.nonPositionedFloats,i.label=11;case 11:return a<s.length?(g=s[a],[4,this.renderStack(g)]):[3,14];case 12:i.sent(),i.label=13;case 13:return a++,[3,11];case 14:A=0,l=t.nonPositionedInlineLevel,i.label=15;case 15:return A<l.length?(g=l[A],[4,this.renderStack(g)]):[3,18];case 16:i.sent(),i.label=17;case 17:return A++,[3,15];case 18:c=0,u=t.inlineLevel,i.label=19;case 19:return c<u.length?(g=u[c],[4,this.renderNode(g)]):[3,22];case 20:i.sent(),i.label=21;case 21:return c++,[3,19];case 22:h=0,d=t.zeroOrAutoZIndexOrTransformedOrOpacity,i.label=23;case 23:return h<d.length?(g=d[h],[4,this.renderStack(g)]):[3,26];case 24:i.sent(),i.label=25;case 25:return h++,[3,23];case 26:f=0,p=t.positiveZIndex,i.label=27;case 27:return f<p.length?(g=p[f],[4,this.renderStack(g)]):[3,30];case 28:i.sent(),i.label=29;case 29:return f++,[3,27];case 30:return[2]}}))}))},r.prototype.mask=function(t){this.ctx.beginPath(),this.ctx.moveTo(0,0),this.ctx.lineTo(this.canvas.width,0),this.ctx.lineTo(this.canvas.width,this.canvas.height),this.ctx.lineTo(0,this.canvas.height),this.ctx.lineTo(0,0),this.formatPath(t.slice(0).reverse()),this.ctx.closePath()},r.prototype.path=function(t){this.ctx.beginPath(),this.formatPath(t),this.ctx.closePath()},r.prototype.formatPath=function(t){var e=this;t.forEach((function(t,r){var n=ho(t)?t.start:t;0===r?e.ctx.moveTo(n.x,n.y):e.ctx.lineTo(n.x,n.y),ho(t)&&e.ctx.bezierCurveTo(t.startControl.x,t.startControl.y,t.endControl.x,t.endControl.y,t.end.x,t.end.y)}))},r.prototype.renderRepeat=function(t,e,r,n){this.path(t),this.ctx.fillStyle=e,this.ctx.translate(r,n),this.ctx.fill(),this.ctx.translate(-r,-n)},r.prototype.resizeImage=function(t,e,r){var n;if(t.width===e&&t.height===r)return t;var i=(null!==(n=this.canvas.ownerDocument)&&void 0!==n?n:document).createElement("canvas");return i.width=Math.max(1,e),i.height=Math.max(1,r),i.getContext("2d").drawImage(t,0,0,t.width,t.height,0,0,e,r),i},r.prototype.renderBackgroundImage=function(t){return n(this,void 0,void 0,(function(){var e,r,n,o,a,s;return i(this,(function(A){switch(A.label){case 0:e=t.styles.backgroundImage.length-1,r=function(r){var o,a,s,A,l,c,u,h,d,f,p,g,m,v,y,w,b,C,B,x,E,S,k,T,F,L,I,_,U,O,D;return i(this,(function(i){switch(i.label){case 0:if(0!==r.type)return[3,5];o=void 0,a=r.url,i.label=1;case 1:return i.trys.push([1,3,,4]),[4,n.context.cache.match(a)];case 2:return o=i.sent(),[3,4];case 3:return i.sent(),n.context.logger.error("Error loading background-image "+a),[3,4];case 4:return o&&(s=_o(t,e,[o.width,o.height,o.width/o.height]),w=s[0],S=s[1],k=s[2],B=s[3],x=s[4],v=n.ctx.createPattern(n.resizeImage(o,B,x),"repeat"),n.renderRepeat(w,v,S,k)),[3,6];case 5:1===r.type?(A=_o(t,e,[null,null,null]),w=A[0],S=A[1],k=A[2],B=A[3],x=A[4],l=be(r.angle,B,x),c=l[0],u=l[1],h=l[2],d=l[3],f=l[4],(p=document.createElement("canvas")).width=B,p.height=x,g=p.getContext("2d"),m=g.createLinearGradient(u,d,h,f),we(r.stops,c).forEach((function(t){return m.addColorStop(t.stop,se(t.color))})),g.fillStyle=m,g.fillRect(0,0,B,x),B>0&&x>0&&(v=n.ctx.createPattern(p,"repeat"),n.renderRepeat(w,v,S,k))):function(t){return 2===t.type}(r)&&(y=_o(t,e,[null,null,null]),w=y[0],b=y[1],C=y[2],B=y[3],x=y[4],E=0===r.position.length?[Jt]:r.position,S=te(E[0],B),k=te(E[E.length-1],x),T=function(t,e,r,n,i){var o=0,a=0;switch(t.size){case 0:0===t.shape?o=a=Math.min(Math.abs(e),Math.abs(e-n),Math.abs(r),Math.abs(r-i)):1===t.shape&&(o=Math.min(Math.abs(e),Math.abs(e-n)),a=Math.min(Math.abs(r),Math.abs(r-i)));break;case 2:if(0===t.shape)o=a=Math.min(Ce(e,r),Ce(e,r-i),Ce(e-n,r),Ce(e-n,r-i));else if(1===t.shape){var s=Math.min(Math.abs(r),Math.abs(r-i))/Math.min(Math.abs(e),Math.abs(e-n)),A=Be(n,i,e,r,!0),l=A[0],c=A[1];a=s*(o=Ce(l-e,(c-r)/s))}break;case 1:0===t.shape?o=a=Math.max(Math.abs(e),Math.abs(e-n),Math.abs(r),Math.abs(r-i)):1===t.shape&&(o=Math.max(Math.abs(e),Math.abs(e-n)),a=Math.max(Math.abs(r),Math.abs(r-i)));break;case 3:if(0===t.shape)o=a=Math.max(Ce(e,r),Ce(e,r-i),Ce(e-n,r),Ce(e-n,r-i));else if(1===t.shape){s=Math.max(Math.abs(r),Math.abs(r-i))/Math.max(Math.abs(e),Math.abs(e-n));var u=Be(n,i,e,r,!1);l=u[0],c=u[1],a=s*(o=Ce(l-e,(c-r)/s))}}return Array.isArray(t.size)&&(o=te(t.size[0],n),a=2===t.size.length?te(t.size[1],i):o),[o,a]}(r,S,k,B,x),F=T[0],L=T[1],F>0&&L>0&&(I=n.ctx.createRadialGradient(b+S,C+k,0,b+S,C+k,F),we(r.stops,2*F).forEach((function(t){return I.addColorStop(t.stop,se(t.color))})),n.path(w),n.ctx.fillStyle=I,F!==L?(_=t.bounds.left+.5*t.bounds.width,U=t.bounds.top+.5*t.bounds.height,D=1/(O=L/F),n.ctx.save(),n.ctx.translate(_,U),n.ctx.transform(1,0,0,O,0,0),n.ctx.translate(-_,-U),n.ctx.fillRect(b,D*(C-U)+U,B,x*D),n.ctx.restore()):n.ctx.fill())),i.label=6;case 6:return e--,[2]}}))},n=this,o=0,a=t.styles.backgroundImage.slice(0).reverse(),A.label=1;case 1:return o<a.length?(s=a[o],[5,r(s)]):[3,4];case 2:A.sent(),A.label=3;case 3:return o++,[3,1];case 4:return[2]}}))}))},r.prototype.renderSolidBorder=function(t,e,r){return n(this,void 0,void 0,(function(){return i(this,(function(n){return this.path(ko(r,e)),this.ctx.fillStyle=se(t),this.ctx.fill(),[2]}))}))},r.prototype.renderDoubleBorder=function(t,e,r,o){return n(this,void 0,void 0,(function(){var n,a;return i(this,(function(i){switch(i.label){case 0:return e<3?[4,this.renderSolidBorder(t,r,o)]:[3,2];case 1:return i.sent(),[2];case 2:return n=function(t,e){switch(e){case 0:return Fo(t.topLeftBorderBox,t.topLeftBorderDoubleOuterBox,t.topRightBorderBox,t.topRightBorderDoubleOuterBox);case 1:return Fo(t.topRightBorderBox,t.topRightBorderDoubleOuterBox,t.bottomRightBorderBox,t.bottomRightBorderDoubleOuterBox);case 2:return Fo(t.bottomRightBorderBox,t.bottomRightBorderDoubleOuterBox,t.bottomLeftBorderBox,t.bottomLeftBorderDoubleOuterBox);case 3:default:return Fo(t.bottomLeftBorderBox,t.bottomLeftBorderDoubleOuterBox,t.topLeftBorderBox,t.topLeftBorderDoubleOuterBox)}}(o,r),this.path(n),this.ctx.fillStyle=se(t),this.ctx.fill(),a=function(t,e){switch(e){case 0:return Fo(t.topLeftBorderDoubleInnerBox,t.topLeftPaddingBox,t.topRightBorderDoubleInnerBox,t.topRightPaddingBox);case 1:return Fo(t.topRightBorderDoubleInnerBox,t.topRightPaddingBox,t.bottomRightBorderDoubleInnerBox,t.bottomRightPaddingBox);case 2:return Fo(t.bottomRightBorderDoubleInnerBox,t.bottomRightPaddingBox,t.bottomLeftBorderDoubleInnerBox,t.bottomLeftPaddingBox);case 3:default:return Fo(t.bottomLeftBorderDoubleInnerBox,t.bottomLeftPaddingBox,t.topLeftBorderDoubleInnerBox,t.topLeftPaddingBox)}}(o,r),this.path(a),this.ctx.fill(),[2]}}))}))},r.prototype.renderNodeBackgroundAndBorders=function(t){return n(this,void 0,void 0,(function(){var e,r,n,o,a,s,A,l,c=this;return i(this,(function(i){switch(i.label){case 0:return this.applyEffects(t.getEffects(2)),e=t.container.styles,r=!ae(e.backgroundColor)||e.backgroundImage.length,n=[{style:e.borderTopStyle,color:e.borderTopColor,width:e.borderTopWidth},{style:e.borderRightStyle,color:e.borderRightColor,width:e.borderRightWidth},{style:e.borderBottomStyle,color:e.borderBottomColor,width:e.borderBottomWidth},{style:e.borderLeftStyle,color:e.borderLeftColor,width:e.borderLeftWidth}],o=Ko(Qo(e.backgroundClip,0),t.curves),r||e.boxShadow.length?(this.ctx.save(),this.path(o),this.ctx.clip(),ae(e.backgroundColor)||(this.ctx.fillStyle=se(e.backgroundColor),this.ctx.fill()),[4,this.renderBackgroundImage(t.container)]):[3,2];case 1:i.sent(),this.ctx.restore(),e.boxShadow.slice(0).reverse().forEach((function(e){c.ctx.save();var r,n,i,o,a,s=go(t.curves),A=e.inset?0:1e4,l=(r=s,n=-A+(e.inset?1:-1)*e.spread.number,i=(e.inset?1:-1)*e.spread.number,o=e.spread.number*(e.inset?-2:2),a=e.spread.number*(e.inset?-2:2),r.map((function(t,e){switch(e){case 0:return t.add(n,i);case 1:return t.add(n+o,i);case 2:return t.add(n+o,i+a);case 3:return t.add(n,i+a)}return t})));e.inset?(c.path(s),c.ctx.clip(),c.mask(l)):(c.mask(s),c.ctx.clip(),c.path(l)),c.ctx.shadowOffsetX=e.offsetX.number+A,c.ctx.shadowOffsetY=e.offsetY.number,c.ctx.shadowColor=se(e.color),c.ctx.shadowBlur=e.blur.number,c.ctx.fillStyle=e.inset?se(e.color):"rgba(0,0,0,1)",c.ctx.fill(),c.ctx.restore()})),i.label=2;case 2:a=0,s=0,A=n,i.label=3;case 3:return s<A.length?0!==(l=A[s]).style&&!ae(l.color)&&l.width>0?2!==l.style?[3,5]:[4,this.renderDashedDottedBorder(l.color,l.width,a,t.curves,2)]:[3,11]:[3,13];case 4:return i.sent(),[3,11];case 5:return 3!==l.style?[3,7]:[4,this.renderDashedDottedBorder(l.color,l.width,a,t.curves,3)];case 6:return i.sent(),[3,11];case 7:return 4!==l.style?[3,9]:[4,this.renderDoubleBorder(l.color,l.width,a,t.curves)];case 8:return i.sent(),[3,11];case 9:return[4,this.renderSolidBorder(l.color,a,t.curves)];case 10:i.sent(),i.label=11;case 11:a++,i.label=12;case 12:return s++,[3,3];case 13:return[2]}}))}))},r.prototype.renderDashedDottedBorder=function(t,e,r,o,a){return n(this,void 0,void 0,(function(){var n,s,A,l,c,u,h,d,f,p,g,m,v,y,w,b;return i(this,(function(i){return this.ctx.save(),n=function(t,e){switch(e){case 0:return To(t.topLeftBorderStroke,t.topRightBorderStroke);case 1:return To(t.topRightBorderStroke,t.bottomRightBorderStroke);case 2:return To(t.bottomRightBorderStroke,t.bottomLeftBorderStroke);case 3:default:return To(t.bottomLeftBorderStroke,t.topLeftBorderStroke)}}(o,r),s=ko(o,r),2===a&&(this.path(s),this.ctx.clip()),ho(s[0])?(A=s[0].start.x,l=s[0].start.y):(A=s[0].x,l=s[0].y),ho(s[1])?(c=s[1].end.x,u=s[1].end.y):(c=s[1].x,u=s[1].y),h=0===r||2===r?Math.abs(A-c):Math.abs(l-u),this.ctx.beginPath(),3===a?this.formatPath(n):this.formatPath(s.slice(0,2)),d=e<3?3*e:2*e,f=e<3?2*e:e,3===a&&(d=e,f=e),p=!0,h<=2*d?p=!1:h<=2*d+f?(d*=g=h/(2*d+f),f*=g):(m=Math.floor((h+f)/(d+f)),v=(h-m*d)/(m-1),f=(y=(h-(m+1)*d)/m)<=0||Math.abs(f-v)<Math.abs(f-y)?v:y),p&&(3===a?this.ctx.setLineDash([0,d+f]):this.ctx.setLineDash([d,f])),3===a?(this.ctx.lineCap="round",this.ctx.lineWidth=e):this.ctx.lineWidth=2*e+1.1,this.ctx.strokeStyle=se(t),this.ctx.stroke(),this.ctx.setLineDash([]),2===a&&(ho(s[0])&&(w=s[3],b=s[0],this.ctx.beginPath(),this.formatPath([new lo(w.end.x,w.end.y),new lo(b.start.x,b.start.y)]),this.ctx.stroke()),ho(s[1])&&(w=s[1],b=s[2],this.ctx.beginPath(),this.formatPath([new lo(w.end.x,w.end.y),new lo(b.start.x,b.start.y)]),this.ctx.stroke())),this.ctx.restore(),[2]}))}))},r.prototype.render=function(t){return n(this,void 0,void 0,(function(){var e;return i(this,(function(r){switch(r.label){case 0:return this.options.backgroundColor&&(this.ctx.fillStyle=se(this.options.backgroundColor),this.ctx.fillRect(this.options.x,this.options.y,this.options.width,this.options.height)),n=new xo(t,null),i=new Bo(n),Eo(n,i,i,o=[]),So(n.container,o),e=i,[4,this.renderStack(e)];case 1:return r.sent(),this.applyEffects([]),[2,this.canvas]}var n,i,o}))}))},r}(Po),No=function(t){return t instanceof ei||t instanceof ti||t instanceof $n&&"radio"!==t.type&&"checkbox"!==t.type},Ko=function(t,e){switch(t){case 0:return go(e);case 2:return function(t){return[t.topLeftContentBox,t.topRightContentBox,t.bottomRightContentBox,t.bottomLeftContentBox]}(e);case 1:default:return mo(e)}},jo=function(t){switch(t){case 1:return"center";case 2:return"right";case 0:default:return"left"}},Go=["-apple-system","system-ui"],Vo=function(t){return/iPhone OS 15_(0|1)/.test(window.navigator.userAgent)?t.filter((function(t){return-1===Go.indexOf(t)})):t},zo=function(t){function r(e,r){var n=t.call(this,e,r)||this;return n.canvas=r.canvas?r.canvas:document.createElement("canvas"),n.ctx=n.canvas.getContext("2d"),n.options=r,n.canvas.width=Math.floor(r.width*r.scale),n.canvas.height=Math.floor(r.height*r.scale),n.canvas.style.width=r.width+"px",n.canvas.style.height=r.height+"px",n.ctx.scale(n.options.scale,n.options.scale),n.ctx.translate(-r.x,-r.y),n.context.logger.debug("EXPERIMENTAL ForeignObject renderer initialized ("+r.width+"x"+r.height+" at "+r.x+","+r.y+") with scale "+r.scale),n}return e(r,t),r.prototype.render=function(t){return n(this,void 0,void 0,(function(){var e,r;return i(this,(function(n){switch(n.label){case 0:return e=In(this.options.width*this.options.scale,this.options.height*this.options.scale,this.options.scale,this.options.scale,t),[4,Wo(e)];case 1:return r=n.sent(),this.options.backgroundColor&&(this.ctx.fillStyle=se(this.options.backgroundColor),this.ctx.fillRect(0,0,this.options.width*this.options.scale,this.options.height*this.options.scale)),this.ctx.drawImage(r,-this.options.x*this.options.scale,-this.options.y*this.options.scale),[2,this.canvas]}}))}))},r}(Po),Wo=function(t){return new Promise((function(e,r){var n=new Image;n.onload=function(){e(n)},n.onerror=r,n.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent((new XMLSerializer).serializeToString(t))}))},Yo=function(){function t(t){var e=t.id,r=t.enabled;this.id=e,this.enabled=r,this.start=Date.now()}return t.prototype.debug=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.debug?console.debug.apply(console,o([this.id,this.getTime()+"ms"],t)):this.info.apply(this,t))},t.prototype.getTime=function(){return Date.now()-this.start},t.prototype.info=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.enabled&&"undefined"!=typeof window&&window.console&&"function"==typeof console.info&&console.info.apply(console,o([this.id,this.getTime()+"ms"],t))},t.prototype.warn=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.warn?console.warn.apply(console,o([this.id,this.getTime()+"ms"],t)):this.info.apply(this,t))},t.prototype.error=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.error?console.error.apply(console,o([this.id,this.getTime()+"ms"],t)):this.info.apply(this,t))},t.instances={},t}(),Xo=function(){function t(e,r){var n;this.windowBounds=r,this.instanceName="#"+t.instanceCount++,this.logger=new Yo({id:this.instanceName,enabled:e.logging}),this.cache=null!==(n=e.cache)&&void 0!==n?n:new to(this,e)}return t.instanceCount=1,t}();"undefined"!=typeof window&&$i.setContext(window);var qo=function(t,e){return n(void 0,void 0,void 0,(function(){var n,o,A,l,c,u,h,d,f,p,g,m,v,y,w,b,C,B,x,E,S,k,T,F,L,I,_,U,O,D,Q,M,R,P,H,N,K,j;return i(this,(function(i){switch(i.label){case 0:if(!t||"object"!=typeof t)return[2,Promise.reject("Invalid element provided as first argument")];if(!(n=t.ownerDocument))throw new Error("Element is not attached to a Document");if(!(o=n.defaultView))throw new Error("Document is not attached to a Window");return A={allowTaint:null!==(k=e.allowTaint)&&void 0!==k&&k,imageTimeout:null!==(T=e.imageTimeout)&&void 0!==T?T:15e3,proxy:e.proxy,useCORS:null!==(F=e.useCORS)&&void 0!==F&&F},l=r({logging:null===(L=e.logging)||void 0===L||L,cache:e.cache},A),c={windowWidth:null!==(I=e.windowWidth)&&void 0!==I?I:o.innerWidth,windowHeight:null!==(_=e.windowHeight)&&void 0!==_?_:o.innerHeight,scrollX:null!==(U=e.scrollX)&&void 0!==U?U:o.pageXOffset,scrollY:null!==(O=e.scrollY)&&void 0!==O?O:o.pageYOffset},u=new a(c.scrollX,c.scrollY,c.windowWidth,c.windowHeight),h=new Xo(l,u),d=null!==(D=e.foreignObjectRendering)&&void 0!==D&&D,f={allowTaint:null!==(Q=e.allowTaint)&&void 0!==Q&&Q,onclone:e.onclone,ignoreElements:e.ignoreElements,inlineImages:d,copyStyles:d},h.logger.debug("Starting document clone with size "+u.width+"x"+u.height+" scrolled to "+-u.left+","+-u.top),p=new Ri(h,t,f),(g=p.clonedReferenceElement)?[4,p.toIFrame(n,u)]:[2,Promise.reject("Unable to find element in cloned iframe")];case 1:return m=i.sent(),v=mi(g)||"HTML"===g.tagName?function(t){var e=t.body,r=t.documentElement;if(!e||!r)throw new Error("Unable to get document size");var n=Math.max(Math.max(e.scrollWidth,r.scrollWidth),Math.max(e.offsetWidth,r.offsetWidth),Math.max(e.clientWidth,r.clientWidth)),i=Math.max(Math.max(e.scrollHeight,r.scrollHeight),Math.max(e.offsetHeight,r.offsetHeight),Math.max(e.clientHeight,r.clientHeight));return new a(0,0,n,i)}(g.ownerDocument):s(h,g),y=v.width,w=v.height,b=v.left,C=v.top,B=Jo(h,g,e.backgroundColor),x={canvas:e.canvas,backgroundColor:B,scale:null!==(R=null!==(M=e.scale)&&void 0!==M?M:o.devicePixelRatio)&&void 0!==R?R:1,x:(null!==(P=e.x)&&void 0!==P?P:0)+b,y:(null!==(H=e.y)&&void 0!==H?H:0)+C,width:null!==(N=e.width)&&void 0!==N?N:Math.ceil(y),height:null!==(K=e.height)&&void 0!==K?K:Math.ceil(w)},d?(h.logger.debug("Document cloned, using foreign object rendering"),[4,new zo(h,x).render(g)]):[3,3];case 2:return E=i.sent(),[3,5];case 3:return h.logger.debug("Document cloned, element located at "+b+","+C+" with size "+y+"x"+w+" using computed rendering"),h.logger.debug("Starting DOM parsing"),S=ai(h,g),B===S.styles.backgroundColor&&(S.styles.backgroundColor=ge.TRANSPARENT),h.logger.debug("Starting renderer for element at "+x.x+","+x.y+" with size "+x.width+"x"+x.height),[4,new Ho(h,x).render(S)];case 4:E=i.sent(),i.label=5;case 5:return(null===(j=e.removeContainer)||void 0===j||j)&&(Ri.destroy(m)||h.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")),h.logger.debug("Finished rendering"),[2,E]}}))}))},Jo=function(t,e,r){var n=e.ownerDocument,i=n.documentElement?pe(t,getComputedStyle(n.documentElement).backgroundColor):ge.TRANSPARENT,o=n.body?pe(t,getComputedStyle(n.body).backgroundColor):ge.TRANSPARENT,a="string"==typeof r?pe(t,r):null===r?ge.TRANSPARENT:4294967295;return e===n.documentElement?ae(i)?ae(o)?a:o:i:a};return function(t,e){return void 0===e&&(e={}),qo(t,e)}}()},wRmb:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/rc-table/es/hooks/useColumns.js ***!
|
|
|
\******************************************************/
|
|
|
/*! exports provided: convertChildrenToColumns, default */
|
|
|
/*! exports used: convertChildrenToColumns, default */function(t,e,r){"use strict";r.d(e,"a",(function(){return c}));var n=r(/*! @babel/runtime/helpers/esm/defineProperty */"rePB"),i=r(/*! @babel/runtime/helpers/esm/toConsumableArray */"KQm4"),o=r(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ"),a=r(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),s=r(/*! react */"q1tI"),A=(r(/*! rc-util/es/warning */"Kwbf"),r(/*! rc-util/es/Children/toArray */"Zm9Q")),l=r(/*! ../utils/legacyUtil */"hW8S");function c(t){return Object(A.a)(t).filter((function(t){return s.isValidElement(t)})).map((function(t){var e=t.key,r=t.props,n=r.children,i=Object(a.a)(r,["children"]),s=Object(o.a)({key:e},i);return n&&(s.children=c(n)),s}))}function u(t){return t.reduce((function(t,e){var r=e.fixed,n=!0===r?"left":r,a=e.children;return a&&a.length>0?[].concat(Object(i.a)(t),Object(i.a)(u(a).map((function(t){return Object(o.a)({fixed:n},t)})))):[].concat(Object(i.a)(t),[Object(o.a)(Object(o.a)({},e),{},{fixed:n})])}),[])}e.b=function(t,e){var r=t.prefixCls,i=t.columns,A=t.children,h=t.expandable,d=t.expandedKeys,f=t.getRowKey,p=t.onTriggerExpand,g=t.expandIcon,m=t.rowExpandable,v=t.expandIconColumnIndex,y=t.direction,w=t.expandRowByClick,b=s.useMemo((function(){return i||c(A)}),[i,A]),C=s.useMemo((function(){if(h){var t,e=v||0,i=b[e],o=(t={},Object(n.a)(t,l.a,{className:"".concat(r,"-expand-icon-col")}),Object(n.a)(t,"title",""),Object(n.a)(t,"fixed",i?i.fixed:null),Object(n.a)(t,"className","".concat(r,"-row-expand-icon-cell")),Object(n.a)(t,"render",(function(t,e,n){var i=f(e,n),o=d.has(i),a=!m||m(e),A=g({prefixCls:r,expanded:o,expandable:a,record:e,onExpand:p});return w?s.createElement("span",{onClick:function(t){return t.stopPropagation()}},A):A})),t),a=b.slice();return e>=0&&a.splice(e,0,o),a}return b}),[h,b,f,d,g,y]),B=s.useMemo((function(){var t=C;return e&&(t=e(t)),t.length||(t=[{render:function(){return null}}]),t}),[e,C,y]),x=s.useMemo((function(){return"rtl"===y?function(t){return t.map((function(t){var e=t.fixed,r=Object(a.a)(t,["fixed"]),n=e;return"left"===e?n="right":"right"===e&&(n="left"),Object(o.a)({fixed:n},r)}))}(u(B)):u(B)}),[B,y]);return[B,x]}},wU8J:
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./node_modules/qr.js/lib/BitBuffer.js ***!
|
|
|
\*********************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){function r(){this.buffer=new Array,this.length=0}r.prototype={get:function(t){var e=Math.floor(t/8);return 1==(this.buffer[e]>>>7-t%8&1)},put:function(t,e){for(var r=0;r<e;r++)this.putBit(1==(t>>>e-r-1&1))},getLengthInBits:function(){return this.length},putBit:function(t){var e=Math.floor(this.length/8);this.buffer.length<=e&&this.buffer.push(0),t&&(this.buffer[e]|=128>>>this.length%8),this.length++}},t.exports=r},x6Kt:
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Rect.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt"),i=r(/*! ../helper/roundRect */"VpOo"),o=r(/*! ../helper/subPixelOptimize */"nPnh").subPixelOptimizeRect,a={},s=n.extend({type:"rect",shape:{r:0,x:0,y:0,width:0,height:0},buildPath:function(t,e){var r,n,s,A;this.subPixelOptimize?(o(a,e,this.style),r=a.x,n=a.y,s=a.width,A=a.height,a.r=e.r,e=a):(r=e.x,n=e.y,s=e.width,A=e.height),e.r?i.buildPath(t,e):t.rect(r,n,s,A),t.closePath()}});t.exports=s},"y+Vt":
|
|
|
/*!**************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/Path.js ***!
|
|
|
\**************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ./Displayable */"Gev7"),i=r(/*! ../core/util */"bYtY"),o=r(/*! ../core/PathProxy */"IMiH"),a=r(/*! ../contain/path */"2DNl"),s=r(/*! ./Pattern */"3C/r").prototype.getCanvasPattern,A=Math.abs,l=new o(!0);function c(t){n.call(this,t),this.path=null}c.prototype={constructor:c,type:"path",__dirtyPath:!0,strokeContainThreshold:5,segmentIgnoreThreshold:0,subPixelOptimize:!1,brush:function(t,e){var r,n=this.style,i=this.path||l,o=n.hasStroke(),a=n.hasFill(),A=n.fill,c=n.stroke,u=a&&!!A.colorStops,h=o&&!!c.colorStops,d=a&&!!A.image,f=o&&!!c.image;(n.bind(t,this,e),this.setTransform(t),this.__dirty)&&(u&&(r=r||this.getBoundingRect(),this._fillGradient=n.getGradient(t,A,r)),h&&(r=r||this.getBoundingRect(),this._strokeGradient=n.getGradient(t,c,r)));u?t.fillStyle=this._fillGradient:d&&(t.fillStyle=s.call(A,t)),h?t.strokeStyle=this._strokeGradient:f&&(t.strokeStyle=s.call(c,t));var p=n.lineDash,g=n.lineDashOffset,m=!!t.setLineDash,v=this.getGlobalScale();if(i.setScale(v[0],v[1],this.segmentIgnoreThreshold),this.__dirtyPath||p&&!m&&o?(i.beginPath(t),p&&!m&&(i.setLineDash(p),i.setLineDashOffset(g)),this.buildPath(i,this.shape,!1),this.path&&(this.__dirtyPath=!1)):(t.beginPath(),this.path.rebuildPath(t)),a)if(null!=n.fillOpacity){var y=t.globalAlpha;t.globalAlpha=n.fillOpacity*n.opacity,i.fill(t),t.globalAlpha=y}else i.fill(t);if(p&&m&&(t.setLineDash(p),t.lineDashOffset=g),o)if(null!=n.strokeOpacity){y=t.globalAlpha;t.globalAlpha=n.strokeOpacity*n.opacity,i.stroke(t),t.globalAlpha=y}else i.stroke(t);p&&m&&t.setLineDash([]),null!=n.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))},buildPath:function(t,e,r){},createPathProxy:function(){this.path=new o},getBoundingRect:function(){var t=this._rect,e=this.style,r=!t;if(r){var n=this.path;n||(n=this.path=new o),this.__dirtyPath&&(n.beginPath(),this.buildPath(n,this.shape,!1)),t=n.getBoundingRect()}if(this._rect=t,e.hasStroke()){var i=this._rectWithStroke||(this._rectWithStroke=t.clone());if(this.__dirty||r){i.copy(t);var a=e.lineWidth,s=e.strokeNoScale?this.getLineScale():1;e.hasFill()||(a=Math.max(a,this.strokeContainThreshold||4)),s>1e-10&&(i.width+=a/s,i.height+=a/s,i.x-=a/s/2,i.y-=a/s/2)}return i}return t},contain:function(t,e){var r=this.transformCoordToLocal(t,e),n=this.getBoundingRect(),i=this.style;if(t=r[0],e=r[1],n.contain(t,e)){var o=this.path.data;if(i.hasStroke()){var s=i.lineWidth,A=i.strokeNoScale?this.getLineScale():1;if(A>1e-10&&(i.hasFill()||(s=Math.max(s,this.strokeContainThreshold)),a.containStroke(o,s/A,t,e)))return!0}if(i.hasFill())return a.contain(o,t,e)}return!1},dirty:function(t){null==t&&(t=!0),t&&(this.__dirtyPath=t,this._rect=null),this.__dirty=this.__dirtyText=!0,this.__zr&&this.__zr.refresh(),this.__clipTarget&&this.__clipTarget.dirty()},animateShape:function(t){return this.animate("shape",t)},attrKV:function(t,e){"shape"===t?(this.setShape(e),this.__dirtyPath=!0,this._rect=null):n.prototype.attrKV.call(this,t,e)},setShape:function(t,e){var r=this.shape;if(r){if(i.isObject(t))for(var n in t)t.hasOwnProperty(n)&&(r[n]=t[n]);else r[t]=e;this.dirty(!0)}return this},getLineScale:function(){var t=this.transform;return t&&A(t[0]-1)>1e-10&&A(t[3]-1)>1e-10?Math.sqrt(A(t[0]*t[3]-t[2]*t[1])):1}},c.extend=function(t){var e=function(e){c.call(this,e),t.style&&this.style.extendFrom(t.style,!1);var r=t.shape;if(r){this.shape=this.shape||{};var n=this.shape;for(var i in r)!n.hasOwnProperty(i)&&r.hasOwnProperty(i)&&(n[i]=r[i])}t.init&&t.init.call(this,e)};for(var r in i.inherits(e,c),t)"style"!==r&&"shape"!==r&&(e.prototype[r]=t[r]);return e},i.inherits(c,n);var u=c;t.exports=u},"y0+3":
|
|
|
/*!********************************************!*\
|
|
|
!*** ./node_modules/rc-util/es/Dom/css.js ***!
|
|
|
\********************************************/
|
|
|
/*! exports provided: get, set, getOuterWidth, getOuterHeight, getDocSize, getClientSize, getScroll, getOffset */
|
|
|
/*! exports used: getClientSize, getOffset */function(t,e,r){"use strict";r.d(e,"a",(function(){return n})),r.d(e,"b",(function(){return i}));function n(){return{width:document.documentElement.clientWidth,height:window.innerHeight||document.documentElement.clientHeight}}function i(t){var e=t.getBoundingClientRect(),r=document.documentElement;return{left:e.left+(window.pageXOffset||r.scrollLeft)-(r.clientLeft||document.body.clientLeft||0),top:e.top+(window.pageYOffset||r.scrollTop)-(r.clientTop||document.body.clientTop||0)}}},y23F:
|
|
|
/*!*****************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/mixin/Draggable.js ***!
|
|
|
\*****************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e){function r(){this.on("mousedown",this._dragStart,this),this.on("mousemove",this._drag,this),this.on("mouseup",this._dragEnd,this)}function n(t,e){return{target:t,topTarget:e&&e.topTarget}}r.prototype={constructor:r,_dragStart:function(t){for(var e=t.target;e&&!e.draggable;)e=e.parent;e&&(this._draggingTarget=e,e.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.dispatchToElement(n(e,t),"dragstart",t.event))},_drag:function(t){var e=this._draggingTarget;if(e){var r=t.offsetX,i=t.offsetY,o=r-this._x,a=i-this._y;this._x=r,this._y=i,e.drift(o,a,t),this.dispatchToElement(n(e,t),"drag",t.event);var s=this.findHover(r,i,e).target,A=this._dropTarget;this._dropTarget=s,e!==s&&(A&&s!==A&&this.dispatchToElement(n(A,t),"dragleave",t.event),s&&s!==A&&this.dispatchToElement(n(s,t),"dragenter",t.event))}},_dragEnd:function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.dispatchToElement(n(e,t),"dragend",t.event),this._dropTarget&&this.dispatchToElement(n(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null}};var i=r;t.exports=i},yxFR:
|
|
|
/*!********************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/graphic/shape/Line.js ***!
|
|
|
\********************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n=r(/*! ../Path */"y+Vt"),i=r(/*! ../helper/subPixelOptimize */"nPnh").subPixelOptimizeLine,o={},a=n.extend({type:"line",shape:{x1:0,y1:0,x2:0,y2:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var r,n,a,s;this.subPixelOptimize?(i(o,e,this.style),r=o.x1,n=o.y1,a=o.x2,s=o.y2):(r=e.x1,n=e.y1,a=e.x2,s=e.y2);var A=e.percent;0!==A&&(t.moveTo(r,n),A<1&&(a=r*(1-A)+a*A,s=n*(1-A)+s*A),t.lineTo(a,s))},pointAt:function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]}});t.exports=a},z9Ch:
|
|
|
/*!*******************************************************************************!*\
|
|
|
!*** ./src/pages/Classrooms/Lists/ShixunHomeworks/Comment/index.less?modules ***!
|
|
|
\*******************************************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! exports used: default */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){t.exports={flex_box_center:"flex_box_center___3OoGm",flex_space_between:"flex_space_between___1T26N",flex_box_vertical_center:"flex_box_vertical_center___1ToJb",flex_box_center_end:"flex_box_center_end___3yWc3",flex_box_column:"flex_box_column___2DqGp",title:"title___27RYc",export:"export___23HFM",title1_right:"title1_right___QCRrC",userPic:"userPic___1IO2N",userInfo:"userInfo___1tmSz",listItem:"listItem___j4sdw",rightInfo:"rightInfo___163Ic",shixunTitle:"shixunTitle___15lHO",shixunWrp:"shixunWrp___O2H0q",footerBar:"footerBar___NH_yZ",footerBarStatic:"footerBarStatic___2dJUI",exitComment:"exitComment___2O-uT",nextComment:"nextComment___2fkhG",modal:"modal___LOSk6",reportContent:"reportContent___27vUc"}},zarK:
|
|
|
/*!******************************************************!*\
|
|
|
!*** ./node_modules/zrender/lib/dom/HandlerProxy.js ***!
|
|
|
\******************************************************/
|
|
|
/*! no static exports found */
|
|
|
/*! all exports used */
|
|
|
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(t,e,r){var n,i,o=r(/*! ../core/event */"YH21"),a=o.addEventListener,s=o.removeEventListener,A=o.normalizeEvent,l=o.getNativeEvent,c=r(/*! ../core/util */"bYtY"),u=r(/*! ../mixin/Eventful */"H6uX"),h=r(/*! ../core/env */"ItGF"),d=h.domSupported,f=(i={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},{mouse:n=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],touch:["touchstart","touchend","touchmove"],pointer:c.map(n,(function(t){var e=t.replace("mouse","pointer");return i.hasOwnProperty(e)?e:t}))}),p=["mousemove","mouseup"],g=["pointermove","pointerup"];function m(t){return"mousewheel"===t&&h.browser.firefox?"DOMMouseScroll":t}function v(t){var e=t.pointerType;return"pen"===e||"touch"===e}function y(t){t&&(t.zrByTouch=!0)}function w(t,e){for(var r=e,n=!1;r&&9!==r.nodeType&&!(n=r.domBelongToZr||r!==e&&r===t.painterRoot);)r=r.parentNode;return n}function b(t,e){this.type=e.type,this.target=this.currentTarget=t.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY}var C=b.prototype;C.stopPropagation=C.stopImmediatePropagation=C.preventDefault=c.noop;var B={mousedown:function(t){t=A(this.dom,t),this._mayPointerCapture=[t.zrX,t.zrY],this.trigger("mousedown",t)},mousemove:function(t){t=A(this.dom,t);var e=this._mayPointerCapture;!e||t.zrX===e[0]&&t.zrY===e[1]||F(this,!0),this.trigger("mousemove",t)},mouseup:function(t){t=A(this.dom,t),F(this,!1),this.trigger("mouseup",t)},mouseout:function(t){t=A(this.dom,t),this._pointerCapturing&&(t.zrEventControl="no_globalout");var e=t.toElement||t.relatedTarget;t.zrIsToLocalDOM=w(this,e),this.trigger("mouseout",t)},touchstart:function(t){y(t=A(this.dom,t)),this._lastTouchMoment=new Date,this.handler.processGesture(t,"start"),B.mousemove.call(this,t),B.mousedown.call(this,t)},touchmove:function(t){y(t=A(this.dom,t)),this.handler.processGesture(t,"change"),B.mousemove.call(this,t)},touchend:function(t){y(t=A(this.dom,t)),this.handler.processGesture(t,"end"),B.mouseup.call(this,t),+new Date-this._lastTouchMoment<300&&B.click.call(this,t)},pointerdown:function(t){B.mousedown.call(this,t)},pointermove:function(t){v(t)||B.mousemove.call(this,t)},pointerup:function(t){B.mouseup.call(this,t)},pointerout:function(t){v(t)||B.mouseout.call(this,t)}};c.each(["click","mousewheel","dblclick","contextmenu"],(function(t){B[t]=function(e){e=A(this.dom,e),this.trigger(t,e)}}));var x={pointermove:function(t){v(t)||x.mousemove.call(this,t)},pointerup:function(t){x.mouseup.call(this,t)},mousemove:function(t){this.trigger("mousemove",t)},mouseup:function(t){var e=this._pointerCapturing;F(this,!1),this.trigger("mouseup",t),e&&(t.zrEventControl="only_globalout",this.trigger("mouseout",t))}};function E(t,e){var r=e.domHandlers;h.pointerEventsSupported?c.each(f.pointer,(function(n){k(e,n,(function(e){r[n].call(t,e)}))})):(h.touchEventsSupported&&c.each(f.touch,(function(n){k(e,n,(function(i){r[n].call(t,i),function(t){t.touching=!0,null!=t.touchTimer&&(clearTimeout(t.touchTimer),t.touchTimer=null),t.touchTimer=setTimeout((function(){t.touching=!1,t.touchTimer=null}),700)}(e)}))})),c.each(f.mouse,(function(n){k(e,n,(function(i){i=l(i),e.touching||r[n].call(t,i)}))})))}function S(t,e){function r(r){k(e,r,(function(n){n=l(n),w(t,n.target)||(n=function(t,e){return A(t.dom,new b(t,e),!0)}(t,n),e.domHandlers[r].call(t,n))}),{capture:!0})}h.pointerEventsSupported?c.each(g,r):h.touchEventsSupported||c.each(p,r)}function k(t,e,r,n){t.mounted[e]=r,t.listenerOpts[e]=n,a(t.domTarget,m(e),r,n)}function T(t){var e=t.mounted;for(var r in e)e.hasOwnProperty(r)&&s(t.domTarget,m(r),e[r],t.listenerOpts[r]);t.mounted={}}function F(t,e){if(t._mayPointerCapture=null,d&&t._pointerCapturing^e){t._pointerCapturing=e;var r=t._globalHandlerScope;e?S(t,r):T(r)}}function L(t,e){this.domTarget=t,this.domHandlers=e,this.mounted={},this.listenerOpts={},this.touchTimer=null,this.touching=!1}function I(t,e){u.call(this),this.dom=t,this.painterRoot=e,this._localHandlerScope=new L(t,B),d&&(this._globalHandlerScope=new L(document,x)),this._pointerCapturing=!1,this._mayPointerCapture=null,E(this,this._localHandlerScope)}var _=I.prototype;_.dispose=function(){T(this._localHandlerScope),d&&T(this._globalHandlerScope)},_.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},c.mixin(I,u);var U=I;t.exports=U}}]); |