(globalThis.webpackChunkweb_stories_wp=globalThis.webpackChunkweb_stories_wp||[]).push([[3573],{88862:function(t,e){!function(t){"use strict";function e(t){var e,r=t.toLowerCase();if("rgb"===r.substring(0,3)){var n=/^rgba?\s*\((\d+),\s*(\d+),\s*(\d+)([^)]*)\)$/.exec(r);e={r:n[1]/255,g:n[2]/255,b:n[3]/255,a:1},n[4]&&(e.a=parseFloat(/^,\s*(.*)$/.exec(n[4])[1]))}else"#"===r.charAt(0)&&(r=r.substr(1)),3===r.length&&(r=r.replace(/^(.)(.)(.)$/,"$1$1$2$2$3$3")),4===r.length&&(r=r.replace(/^(.)(.)(.)(.)$/,"$1$1$2$2$3$3$4$4")),e={r:parseInt(r.substr(0,2),16)/255,g:parseInt(r.substr(2,2),16)/255,b:parseInt(r.substr(4,2),16)/255,a:1},8===r.length&&(e.a=parseInt(r.substr(6,2),16)/255);return e}function r(t){var e,r,n,i=t.r,o=t.g,a=t.b,s=t.a,u=Math.min(i,o,a),c=Math.max(i,o,a),l=c-u;return c===u?e=0:i===c?e=(o-a)/l:o===c?e=2+(a-i)/l:a===c&&(e=4+(i-o)/l),(e=Math.min(60*e,360))<0&&(e+=360),n=(u+c)/2,r=c===u?0:n<=.5?l/(c+u):l/(2-c-u),{h:e,s:r*=100,l:n*=100,a:s}}function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function i(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 o(t){for(var e=1;et.length)&&(e=t.length);for(var r=0,n=new Array(e);r2&&void 0!==arguments[2]&&arguments[2];return t>=3&&(arguments.length>1&&void 0!==arguments[1]?arguments[1]:16)>=18?(e&&console.log(m["min-ratio-3"]),!0):t>=4.5&&(e&&console.log(m["min-ratio-4.5"]),!0)}function b(t){var e=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return t>=4.5&&(arguments.length>1&&void 0!==arguments[1]?arguments[1]:16)>=18?(e&&console.log(m["min-ratio-4.5"]),!0):t>=7&&(e&&console.log(m["min-ratio-7"]),!0)}function S(t,e){var r=t.h,n=t.s,i=t.l,o=t.a,a=e[0],s=e[1],u=e[2],c=(r+a)%360;return c<0&&(c+=360),{h:c,s:Math.min(Math.max(n+s,0),100),l:Math.min(Math.max(i+u,0),100),a:o}}var w=.1;function x(t,n,i){var o,a=t;do{o=g(y(e(d(a=p(S(r(a),[0,0,w]))))),y(n))}while(Math.round(100*o)/100<=i);return a}t.aa=_,t.aaa=b,t.contrast=g,t.getAccesibleHexColor=x,t.hsl2rgb=h,t.hsla2rgba=p,t.hslaVector3=S,t.ratios=m,t.relativeLuminance=y,t.rgb2hex=v,t.rgb2hsl=f,t.rgba2hex=d,t.rgba2hsla=r,t.str2rgba=e,Object.defineProperty(t,"__esModule",{value:!0})}(e)},91703:(t,e,r)=>{const n=r(67294);function i(t){return t&&!Array.isArray(t)&&Object(t)===t}function o(t){let e=null;if(navigator.mediaDevices&&(e=navigator.mediaDevices.getSupportedConstraints()),null===e)return;let r=Object.keys(t).filter((t=>!e[t]));if(0!==r.length){let t=r.join(",");console.error(`The following constraints ${t} are not supported on this browser.`)}}const a=()=>{};t.exports=function({blobOptions:t,recordScreen:e,customMediaStream:r,onStop:s=a,onStart:u=a,onError:c=a,mediaRecorderOptions:l,onDataAvailable:f=a,mediaStreamConstraints:p={}}){let h=n.useRef([]),d=n.useRef(null),v=n.useRef(null),[g,y]=n.useState("idle"),[m,_]=n.useState(null),[b,S]=n.useState(null),[w,x]=n.useState(!1);async function E(){if(m&&_(null),y("acquiring_media"),r&&r instanceof MediaStream)return d.current=r,r;try{let t;if(t=e?await window.navigator.mediaDevices.getDisplayMedia(p):await window.navigator.mediaDevices.getUserMedia(p),e&&p.audio){(await window.navigator.mediaDevices.getUserMedia({audio:p.audio})).getAudioTracks().forEach((e=>t.addTrack(e)))}return d.current=t,y("ready"),t}catch(t){_(t),y("failed")}}function O(){d.current&&(d.current.getTracks().forEach((t=>t.stop())),d.current=null,y("idle"))}function C(t){t.data.size&&h.current.push(t.data),f(t.data)}function k(){let e=new Blob,r=new Blob;if(h.current.length){[r]=h.current;let n=Object.assign({type:r.type},t);e=new Blob(h.current,n),S(e)}y("stopped"),s(e)}function D(t){_(t.error),y("idle"),c(t.error)}function M(t){x(t),d.current&&d.current.getAudioTracks().forEach((e=>{e.enabled=!t}))}return n.useEffect((()=>{if(!window.MediaRecorder)throw new ReferenceError("MediaRecorder is not supported in this browser. Please ensure that you are running the latest version of chrome/firefox/edge.");if(e&&!window.navigator.mediaDevices.getDisplayMedia)throw new ReferenceError("This browser does not support screen capturing.");i(p.video)&&o(p.video),i(p.audio)&&o(p.audio),l&&l.mimeType&&(MediaRecorder.isTypeSupported(l.mimeType)||console.error("The specified MIME type supplied to MediaRecorder is not supported by this browser."))}),[p,l,e]),{error:m,status:g,mediaBlob:b,isAudioMuted:w,stopRecording:function(){v.current&&(y("stopping"),v.current.stop(),v.current.removeEventListener("dataavailable",C),v.current.removeEventListener("stop",k),v.current.removeEventListener("error",D),v.current=null,r||O())},getMediaStream:E,startRecording:async function(t){if(m&&_(null),d.current||await E(),h.current=[],d.current){v.current=new MediaRecorder(d.current,l),v.current.addEventListener("dataavailable",C),v.current.addEventListener("stop",k),v.current.addEventListener("error",D);try{v.current.start(t),y("recording"),u()}catch(t){D({error:t})}}},pauseRecording:function(){v.current&&"recording"===v.current.state&&(v.current.pause(),y("paused"))},resumeRecording:function(){v.current&&"paused"===v.current.state&&(v.current.resume(),y("recording"))},clearMediaStream:O,clearMediaBlob:function(){S(null)},muteAudio:()=>M(!0),unMuteAudio:()=>M(!1),get liveStream(){return d.current?new MediaStream(d.current.getTracks()):null}}}},94184:(t,e)=>{var r;!function(){"use strict";var n={}.hasOwnProperty;function i(){for(var t=[],e=0;e{"use strict";r.d(e,{default:()=>o});var n=r(19013),i=r(13882);function o(t,e){(0,i.default)(2,arguments);var r=(0,n.default)(t),o=(0,n.default)(e);return r.getTime()>o.getTime()}},29042:(t,e,r)=>{"use strict";r.d(e,{default:()=>s});var n=r(83946),i=r(51820),o=r(13882),a=6e4;function s(t,e){return(0,o.default)(2,arguments),function(t,e){(0,o.default)(2,arguments);var r=(0,n.default)(e);return(0,i.default)(t,r*a)}(t,-(0,n.default)(e))}},28789:(t,e,r)=>{"use strict";function n(t){return function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);eU});const u=function(t,e){if(null==t)return e;for(var r=s(e,2),i=r[0],a=r[1],u=o({},i),c=n(a),l=0,f=Object.keys(t);l0&&!(0,m.is)(r,n)&&(i.push([t.slice(o,a),n]),o=a)}return i.push([t.slice(o),r]),i}r(9041);var S,w,x;function E(t,e){var r=Object.keys(t);return Object.getOwnPropertySymbols&&r.push.apply(r,Object.getOwnPropertySymbols(t)),e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r}function O(t){for(var e=1;e",B=/^data-([a-z0-9-]+)$/,q=(D(S={},M,{element:"strong"}),D(S,I,{element:"code"}),D(S,A,{element:"em"}),D(S,R,{element:"del"}),D(S,T,{element:"u"}),S),P=[M,A,T,R,I],j=(D(w={},g.LINK,{url:"href",href:"href",rel:"rel",target:"target",title:"title",className:"class"}),D(w,g.IMAGE,{src:"src",height:"height",width:"width",alt:"alt",className:"class"}),w),L=(D(x={},g.LINK,(function(t,e){for(var r=j.hasOwnProperty(t)?j[t]:{},n=e.getData(),i={},o=0,a=Object.keys(n);o"))}}catch(t){c=!0,l=t}finally{try{u||null==p.return||p.return()}finally{if(c)throw l}}}},{key:"writeEndTag",value:function(t,e){var r=K(t.getType(),e);if(1===r.length)this.output.push("\n"));else{var n=[],i=!0,o=!1,a=void 0;try{for(var s,u=r[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value;n.unshift(""))}}catch(t){o=!0,a=t}finally{try{i||null==u.return||u.return()}finally{if(o)throw a}}this.output.push(n.join("")+"\n")}}},{key:"openWrapperTag",value:function(t){this.wrapperTag=t,this.indent(),this.output.push("<".concat(t,">\n")),this.indentLevel+=1}},{key:"closeWrapperTag",value:function(){var t=this.wrapperTag;t&&(this.indentLevel-=1,this.indent(),this.output.push("\n")),this.wrapperTag=null)}},{key:"indent",value:function(){this.output.push(" ".repeat(this.indentLevel))}},{key:"withCustomInlineStyles",value:function(t,e){if(!this.inlineStyleFn)return t;var r=this.inlineStyleFn(e);if(!r)return t;var n=r.element,i=void 0===n?"span":n,o=r.attributes,a=r.style,s=F(O({},o,{style:a&&d(a)}));return"<".concat(i).concat(s,">").concat(t,"")}},{key:"renderBlockContent",value:function(t){var e=this,r=t.getType(),n=t.getText();if(""===n)return z;var i=function(t,e){for(var r=null,n=null,i=[],o=0,a=0,s=t.length;a0&&r!==n&&(i.push([n,b(t.slice(o,a),e.slice(o,a))]),o=a)}return i.push([r,b(t.slice(o),e.slice(o))]),i}(n=this.preserveWhitespace(n),t.getCharacterList());return i.map((function(t){var n,i=C(t,2),o=i[0],a=i[1].map((function(t){var n=C(t,2),i=n[0],o=n[1],a=function(t){return t.split("&").join("&").split("<").join("<").split(">").join(">").split(" ").join(" ").split("\n").join(z+"\n")}(i),s=!0,u=!1,c=void 0;try{for(var l,f=e.styleOrder[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var p=l.value;if((p!==I||r!==v.CODE)&&o.has(p)){var h=e.inlineStyles[p],g=h.element,y=h.attributes,m=h.style;if(null==g&&(g="span"),y=helpers_normalizeAttributes(y),null!=m){var _=d(m);y=null==y?{style:_}:O({},y,{style:_})}var b=F(y);a="<".concat(g).concat(b,">").concat(a,"")}}}catch(t){u=!0,c=t}finally{try{s||null==f.return||f.return()}finally{if(u)throw c}}return e.withCustomInlineStyles(a,o)})).join(""),s=o?e.contentState.getEntity(o):null,u=null==s?null:s.getType().toUpperCase();if(null!=s&&e.options.entityStyleFn&&(n=e.options.entityStyleFn(s))){var c=n,l=c.element,f=c.attributes,p=c.style;if(null==l&&(l="span"),f=helpers_normalizeAttributes(f),null!=p){var h=d(p);f=null==f?{style:h}:O({},f,{style:h})}var y=F(f);return"<".concat(l).concat(y,">").concat(a,"")}if(null!=u&&u===g.LINK){var m=F(L.hasOwnProperty(u)?L[u](u,s):null);return"").concat(a,"")}if(null!=u&&u===g.IMAGE){var _=F(L.hasOwnProperty(u)?L[u](u,s):null);return"")}return a})).join("")}},{key:"preserveWhitespace",value:function(t){for(var e=t.length,r=new Array(e),n=0;n").join(">").split('"').join("""),'"'))}return e.join("")}function U(t,e){return new N(t,e).generate()}},18454:(t,e,r)=>{"use strict";function n(t,e,r){for(var n=t.text,o=t.characterMeta,a=e.length,s=r.length,u=[],c=o.slice(0,0),l=0,f=n.indexOf(e);-1!==f;)u.push(n.slice(l,f)+r),c=c.concat(o.slice(l,f),i(o.slice(f,f+1),s)),l=f+a,f=n.indexOf(e,l);return u.push(n.slice(l)),c=c.concat(o.slice(l)),{text:u.join(""),characterMeta:c}}function i(t,e){for(var r=t.slice(0,0);e-- >0;)r=r.concat(t);return r}r.d(e,{stateFromHTML:()=>R});var o=r(9041),a=r(35369),s={UNSTYLED:"unstyled",HEADER_ONE:"header-one",HEADER_TWO:"header-two",HEADER_THREE:"header-three",HEADER_FOUR:"header-four",HEADER_FIVE:"header-five",HEADER_SIX:"header-six",UNORDERED_LIST_ITEM:"unordered-list-item",ORDERED_LIST_ITEM:"ordered-list-item",BLOCKQUOTE:"blockquote",PULLQUOTE:"pullquote",CODE:"code-block",ATOMIC:"atomic"},u={LINK:"LINK",IMAGE:"IMAGE",EMBED:"embed"},c={BOLD:"BOLD",CODE:"CODE",ITALIC:"ITALIC",STRIKETHROUGH:"STRIKETHROUGH",UNDERLINE:"UNDERLINE"};new a.OrderedSet;var l={a:1,abbr:1,area:1,audio:1,b:1,bdi:1,bdo:1,br:1,button:1,canvas:1,cite:1,code:1,command:1,datalist:1,del:1,dfn:1,em:1,embed:1,i:1,iframe:1,img:1,input:1,ins:1,kbd:1,keygen:1,label:1,map:1,mark:1,meter:1,noscript:1,object:1,output:1,progress:1,q:1,ruby:1,s:1,samp:1,script:1,select:1,small:1,span:1,strong:1,sub:1,sup:1,textarea:1,time:1,u:1,var:1,video:1,wbr:1,acronym:1,applet:1,basefont:1,big:1,font:1,isindex:1,strike:1,style:1,tt:1},f={area:1,base:1,br:1,col:1,colgroup:1,command:1,dl:1,embed:1,head:1,hgroup:1,hr:1,iframe:1,img:1,input:1,keygen:1,link:1,meta:1,ol:1,optgroup:1,option:1,param:1,script:1,select:1,source:1,style:1,table:1,tbody:1,textarea:1,tfoot:1,thead:1,title:1,tr:1,track:1,ul:1,wbr:1,basefont:1,dialog:1,dir:1,isindex:1},p={img:1};function h(t){return h="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},h(t)}function d(t,e){var r=Object.keys(t);return Object.getOwnPropertySymbols&&r.push.apply(r,Object.getOwnPropertySymbols(t)),e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r}function v(t,e){for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:{};!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,ContentGenerator),g(this,"contentStateForEntities",void 0),g(this,"blockStack",void 0),g(this,"blockList",void 0),g(this,"depth",void 0),g(this,"options",void 0),g(this,"inlineCreators",{Style:function(t){function Style(e){return t.apply(this,arguments)}return Style.toString=function(){return t.toString()},Style}((function(t){return{type:"STYLE",style:t}})),Entity:function Entity(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"MUTABLE";return{type:"ENTITY",entityKey:t.createEntity(e,k(r),n)}}}),this.options=e,this.contentStateForEntities=o.ContentState.createFromBlockArray([]),this.blockStack=[],this.blockList=[],this.depth=0}var t,e,r;return t=ContentGenerator,e=[{key:"process",value:function(t){this.processBlockElement(t);var e=[];return this.blockList.forEach((function(t){var r=function(t){var e="",r=(0,a.Seq)();return t.forEach((function(t){e+=t.text,r=r.concat(t.characterMeta)})),{text:e,characterMeta:r}}(t.textFragments),i=r.text,s=r.characterMeta,u=!1;if(i===S&&(u=!0,i=""),"pre"===t.tagName){var c=function(t,e){return"\n"===t.charAt(0)&&(t=t.slice(1),e=e.slice(1)),{text:t,characterMeta:e}}(i,s);i=c.text,s=c.characterMeta}else{var l=function(t,e){var r=function(t,e){for(;" "===t.charAt(0);)t=t.slice(1),e=e.slice(1);return{text:t,characterMeta:e}}(t=t.replace(/[ \t\n]/g," "),e);t=r.text,e=r.characterMeta;var i=function(t,e){for(;" "===t.slice(-1);)t=t.slice(0,-1),e=e.slice(0,-1);return{text:t,characterMeta:e}}(t,e);t=i.text,e=i.characterMeta;for(var o=t.length;o--;)" "===t.charAt(o)&&" "===t.charAt(o-1)&&(t=t.slice(0,o)+t.slice(o+1),e=e.slice(0,o).concat(e.slice(o+1)));var a=n({text:t,characterMeta:e},"\r ",S);t=a.text,e=a.characterMeta;var s=n({text:t,characterMeta:e}," \r",S);return t=s.text,e=s.characterMeta,{text:t,characterMeta:e}}(i,s);i=l.text,s=l.characterMeta}((i=i.split(S).join("\n")).length||u)&&e.push(new o.ContentBlock({key:(0,o.genKey)(),text:i,type:t.type,characterList:s.toList(),depth:t.depth,data:t.data?(0,a.Map)(t.data):(0,a.Map)()}))})),e.length||(e=[_]),o.ContentState.createFromBlockArray(e,this.contentStateForEntities.getEntityMap())}},{key:"getBlockTypeFromTagName",value:function(t){var e=this.options.blockTypes;if(e&&e[t])return e[t];switch(t){case"li":return"ol"===this.blockStack.slice(-1)[0].tagName?s.ORDERED_LIST_ITEM:s.UNORDERED_LIST_ITEM;case"blockquote":return s.BLOCKQUOTE;case"h1":return s.HEADER_ONE;case"h2":return s.HEADER_TWO;case"h3":return s.HEADER_THREE;case"h4":return s.HEADER_FOUR;case"h5":return s.HEADER_FIVE;case"h6":return s.HEADER_SIX;case"pre":return s.CODE;case"figure":return s.ATOMIC;default:return s.UNSTYLED}}},{key:"processBlockElement",value:function(t){if(t){var e,r,n=this.options.customBlockFn,i=t.nodeName.toLowerCase();if(n){var o=n(t);null!=o&&(e=o.type,r=o.data)}var a=!0;if(null==e&&(a=!1,e=this.getBlockTypeFromTagName(i)),e===s.CODE){var u=t.getAttribute("data-language");u&&(r=function(t){for(var e=1;e{n=n.add(t)}));break;case"ENTITY":i=a.entityKey}else n=function(t,e,r){switch(e){case"b":case"strong":return t.add(c.BOLD);case"i":case"em":return t.add(c.ITALIC);case"u":case"ins":return t.add(c.UNDERLINE);case"code":return t.add(c.CODE);case"s":case"del":return t.add(c.STRIKETHROUGH);default:return r&&r[e]?t.add(r[e]):t}}(n,e,this.options.elementStyles),O.hasOwnProperty(e)&&(i=O[e](this,e,t)||i);r.styleStack.push(n),r.entityStack.push(i),null!=t.childNodes&&Array.from(t.childNodes).forEach(this.processNode,this),p.hasOwnProperty(e)&&this.processText(" "),r.entityStack.pop(),r.styleStack.pop()}else this.processText(S)}},{key:"processTextNode",value:function(t){var e=t.nodeValue;e=(e=e.replace(b,"\n")).split("​").join(S),this.processText(e)}},{key:"processText",value:function(t){var e=this.blockStack.slice(-1)[0],r=e.styleStack.slice(-1)[0],n=e.entityStack.slice(-1)[0],i=o.CharacterMetadata.create({style:r,entity:n}),s=(0,a.Repeat)(i,t.length);e.textFragments.push({text:t,characterMeta:s})}},{key:"processNode",value:function(t){if(1===t.nodeType){var e=t,r=e.nodeName.toLowerCase();l.hasOwnProperty(r)?this.processInlineElement(e):this.processBlockElement(e)}else 3===t.nodeType&&this.processTextNode(t)}},{key:"createEntity",value:function(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"MUTABLE";return this.contentStateForEntities=this.contentStateForEntities.createEntity(t,r,e),this.contentStateForEntities.getLastCreatedEntityKey()}}],e&&v(t.prototype,e),r&&v(t,r),ContentGenerator}();function k(t){var e={};if(null!==t&&"object"===h(t)&&!Array.isArray(t))for(var r=t,n=0,i=Object.keys(r);n=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}var A={};function R(t,e){var r=e||A,n=r.parser,i=I(r,["parser"]);return null==n&&(n=M),D(n(t),i)}},19785:(t,e,r)=>{"use strict";function n(t){for(var e=1;e{"use strict";var n=r(82371).OrderedMap,i={createFromArray:function(t){return n(t.map((function(t){return[t.getKey(),t]})))}};t.exports=i},34365:(t,e,r)=>{"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var i=r(29407),o=r(96495),a=r(82371),s=a.List,u=a.Repeat,c=a.Record,l=function(){return!0},f=c({start:null,end:null}),p=c({start:null,end:null,decoratorKey:null,leaves:null}),h={generate:function(t,e,r){var n=e.getLength();if(!n)return s.of(new p({start:0,end:0,decoratorKey:null,leaves:s.of(new f({start:0,end:0}))}));var o=[],a=r?r.getDecorations(e,t):s(u(null,n)),c=e.getCharacterList();return i(a,v,l,(function(t,e){o.push(new p({start:t,end:e,decoratorKey:a.get(t),leaves:d(c.slice(t,e).toList(),t)}))})),s(o)},fromJS:function(t){var e=t.leaves,r=function(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;n=0||(i[r]=t[r]);return i}(t,["leaves"]);return new p(function(t){for(var e=1;e{"use strict";var n=r(82371),i=n.Map,o=n.OrderedSet,a=n.Record,s=o(),u={style:s,entity:null},c=function(t){var e,r;function CharacterMetadata(){return t.apply(this,arguments)||this}r=t,(e=CharacterMetadata).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r;var n=CharacterMetadata.prototype;return n.getStyle=function(){return this.get("style")},n.getEntity=function(){return this.get("entity")},n.hasStyle=function(t){return this.getStyle().includes(t)},CharacterMetadata.applyStyle=function(t,e){var r=t.set("style",t.getStyle().add(e));return CharacterMetadata.create(r)},CharacterMetadata.removeStyle=function(t,e){var r=t.set("style",t.getStyle().remove(e));return CharacterMetadata.create(r)},CharacterMetadata.applyEntity=function(t,e){var r=t.getEntity()===e?t:t.set("entity",e);return CharacterMetadata.create(r)},CharacterMetadata.create=function(t){if(!t)return l;var e=i({style:s,entity:null}).merge(t),r=f.get(e);if(r)return r;var n=new CharacterMetadata(e);return f=f.set(e,n),n},CharacterMetadata.fromJS=function(t){var e=t.style,r=t.entity;return new CharacterMetadata({style:Array.isArray(e)?o(e):e,entity:Array.isArray(r)?o(r):r})},CharacterMetadata}(a(u)),l=new c,f=i([[i(u),l]]);c.EMPTY=l,t.exports=c},25369:(t,e,r)=>{"use strict";var n=r(82371).List,i=function(){function CompositeDraftDecorator(t){var e,r,n;n=void 0,(r="_decorators")in(e=this)?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,this._decorators=t.slice()}var t=CompositeDraftDecorator.prototype;return t.getDecorations=function(t,e){var r=Array(t.getText().length).fill(null);return this._decorators.forEach((function(n,i){var o=0;(0,n.strategy)(t,(function(t,e){(function(t,e,r){for(var n=e;n{"use strict";var n=r(4516),i=r(29407),o=r(82371),a=o.List,s=o.Map,u=o.OrderedSet,c=o.Record,l=o.Repeat,f=u(),p=c({key:"",type:"unstyled",text:"",characterList:a(),depth:0,data:s()}),h=function(t){var e,r;function ContentBlock(e){return t.call(this,function(t){if(!t)return t;var e=t.characterList,r=t.text;return r&&!e&&(t.characterList=a(l(n.EMPTY,r.length))),t}(e))||this}r=t,(e=ContentBlock).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r;var o=ContentBlock.prototype;return o.getKey=function(){return this.get("key")},o.getType=function(){return this.get("type")},o.getText=function(){return this.get("text")},o.getCharacterList=function(){return this.get("characterList")},o.getLength=function(){return this.getText().length},o.getDepth=function(){return this.get("depth")},o.getData=function(){return this.get("data")},o.getInlineStyleAt=function(t){var e=this.getCharacterList().get(t);return e?e.getStyle():f},o.getEntityAt=function(t){var e=this.getCharacterList().get(t);return e?e.getEntity():null},o.findStyleRanges=function(t,e){i(this.getCharacterList(),d,t,e)},o.findEntityRanges=function(t,e){i(this.getCharacterList(),v,t,e)},ContentBlock}(p);function d(t,e){return t.getStyle()===e.getStyle()}function v(t,e){return t.getEntity()===e.getEntity()}t.exports=h},67953:(t,e,r)=>{"use strict";var n=r(4516),i=r(29407),o=r(82371),a=o.List,s=o.Map,u=o.OrderedSet,c=o.Record,l=o.Repeat,f=u(),p={parent:null,characterList:a(),data:s(),depth:0,key:"",text:"",type:"unstyled",children:a(),prevSibling:null,nextSibling:null},h=function(t,e){return t.getStyle()===e.getStyle()},d=function(t,e){return t.getEntity()===e.getEntity()},v=function(t){var e,r;function ContentBlockNode(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:p;return t.call(this,function(t){if(!t)return t;var e=t.characterList,r=t.text;return r&&!e&&(t.characterList=a(l(n.EMPTY,r.length))),t}(e))||this}r=t,(e=ContentBlockNode).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r;var o=ContentBlockNode.prototype;return o.getKey=function(){return this.get("key")},o.getType=function(){return this.get("type")},o.getText=function(){return this.get("text")},o.getCharacterList=function(){return this.get("characterList")},o.getLength=function(){return this.getText().length},o.getDepth=function(){return this.get("depth")},o.getData=function(){return this.get("data")},o.getInlineStyleAt=function(t){var e=this.getCharacterList().get(t);return e?e.getStyle():f},o.getEntityAt=function(t){var e=this.getCharacterList().get(t);return e?e.getEntity():null},o.getChildKeys=function(){return this.get("children")},o.getParentKey=function(){return this.get("parent")},o.getPrevSiblingKey=function(){return this.get("prevSibling")},o.getNextSiblingKey=function(){return this.get("nextSibling")},o.findStyleRanges=function(t,e){i(this.getCharacterList(),h,t,e)},o.findEntityRanges=function(t,e){i(this.getCharacterList(),d,t,e)},ContentBlockNode}(c(p));t.exports=v},66912:(t,e,r)=>{"use strict";function n(t){for(var e=1;e1||escape(t.first().getText()).replace(/%u200B/g,"").length>0},i.createEntity=function(t,e,r){return c.__create(t,e,r),this},i.mergeEntityData=function(t,e){return c.__mergeData(t,e),this},i.replaceEntityData=function(t,e){return c.__replaceData(t,e),this},i.addEntity=function(t){return c.__add(t),this},i.getEntity=function(t){return c.__get(t)},i.getAllEntities=function(){return c.__getAll()},i.loadWithEntities=function(t){return c.__loadWithEntities(t)},ContentState.createFromBlockArray=function(t,e){var r=Array.isArray(t)?t:t.contentBlocks,n=o.createFromArray(r),i=n.isEmpty()?new l:l.createEmpty(n.first().getKey());return new ContentState({blockMap:n,entityMap:e||c,selectionBefore:i,selectionAfter:i})},ContentState.createFromText=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:/\r\n?|\n/g,r=t.split(e).map((function(t){return t=v(t),new w({key:f(),text:t,type:"unstyled",characterList:g(m(a.EMPTY,t.length))})}));return ContentState.createFromBlockArray(r)},ContentState.fromJS=function(t){return new ContentState(n({},t,{blockMap:b(t.blockMap).map(ContentState.createContentBlockFromJS),selectionBefore:new l(t.selectionBefore),selectionAfter:new l(t.selectionAfter)}))},ContentState.createContentBlockFromJS=function(t){var e=t.characterList;return new w(n({},t,{data:_(t.data),characterList:null!=e?g((Array.isArray(e)?e:p(e)).map((function(t){return a.fromJS(t)}))):void 0}))},ContentState}(S);t.exports=x},13483:(t,e,r)=>{"use strict";var n=r(4516),i=r(82371).Map,o={add:function(t,e,r){return a(t,e,r,!0)},remove:function(t,e,r){return a(t,e,r,!1)}};function a(t,e,r,o){var a=t.getBlockMap(),s=e.getStartKey(),u=e.getStartOffset(),c=e.getEndKey(),l=e.getEndOffset(),f=a.skipUntil((function(t,e){return e===s})).takeUntil((function(t,e){return e===c})).concat(i([[c,a.get(c)]])).map((function(t,e){var i,a;s===c?(i=u,a=l):(i=e===s?u:0,a=e===c?l:t.getLength());for(var f,p=t.getCharacterList();i{"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var i=r(4856),o=r(69270),a=r(48083),s=r(82371),u=r(73759),c=r(22045),l=s.Map,f={subtree:!0,characterData:!0,childList:!0,characterDataOldValue:!1,attributes:!1},p=i.isBrowser("IE <= 11"),h=function(){function DOMObserver(t){var e=this;n(this,"observer",void 0),n(this,"container",void 0),n(this,"mutations",void 0),n(this,"onCharData",void 0),this.container=t,this.mutations=l();var r=a(t);r.MutationObserver&&!p?this.observer=new r.MutationObserver((function(t){return e.registerMutations(t)})):this.onCharData=function(t){t.target instanceof Node||u(!1),e.registerMutation({type:"characterData",target:t.target})}}var t=DOMObserver.prototype;return t.start=function(){this.observer?this.observer.observe(this.container,f):this.container.addEventListener("DOMCharacterDataModified",this.onCharData)},t.stopAndFlushMutations=function(){var t=this.observer;t?(this.registerMutations(t.takeRecords()),t.disconnect()):this.container.removeEventListener("DOMCharacterDataModified",this.onCharData);var e=this.mutations;return this.mutations=l(),e},t.registerMutations=function(t){for(var e=0;e{"use strict";var n=r(67294),i=r(62620),o=(0,r(82371).Map)({"header-one":{element:"h1"},"header-two":{element:"h2"},"header-three":{element:"h3"},"header-four":{element:"h4"},"header-five":{element:"h5"},"header-six":{element:"h6"},section:{element:"section"},article:{element:"article"},"unordered-list-item":{element:"li",wrapper:n.createElement("ul",{className:i("public/DraftStyleDefault/ul")})},"ordered-list-item":{element:"li",wrapper:n.createElement("ol",{className:i("public/DraftStyleDefault/ol")})},blockquote:{element:"blockquote"},atomic:{element:"figure"},"code-block":{element:"pre",wrapper:n.createElement("pre",{className:i("public/DraftStyleDefault/pre")})},unstyled:{element:"div",aliasedElements:["p"]}});t.exports=o},37619:t=>{"use strict";t.exports={BOLD:{fontWeight:"bold"},CODE:{fontFamily:"monospace",wordWrap:"break-word"},ITALIC:{fontStyle:"italic"},STRIKETHROUGH:{textDecoration:"line-through"},UNDERLINE:{textDecoration:"underline"}}},9041:(t,e,r)=>{"use strict";var n=r(19785),i=r(10329),o=r(4516),a=r(25369),s=r(38777),u=r(66912),c=r(526),l=r(37619),f=r(87210),p=r(37898),h=r(82222),d=r(42307),v=r(39006),g=r(14289),y=r(47387),m=r(70054),_=r(41947),b=r(25110),S=r(79981),w=r(99607),x=r(25027),E=r(41714),O=r(96629),C={Editor:f,EditorBlock:p,EditorState:g,CompositeDecorator:a,Entity:h,EntityInstance:v,BlockMapBuilder:i,CharacterMetadata:o,ContentBlock:s,ContentState:u,RawDraftContentState:m,SelectionState:b,AtomicBlockUtils:n,KeyBindingUtil:y,Modifier:d,RichUtils:_,DefaultDraftBlockRenderMap:c,DefaultDraftInlineStyle:l,convertFromHTML:r(67841),convertFromRaw:w,convertToRaw:S,genKey:x,getDefaultKeyBinding:E,getVisibleSelectionRect:O};t.exports=C},87210:(t,e,r)=>{"use strict";var n=r(27418);function i(){return i=n||function(t){for(var e=1;e{"use strict";var n=r(27418);function i(){return i=n||function(t){for(var e=1;e0&&window.scrollTo(o.x,o.y+n+10)}else{y(r)||g(!1),(n=r.offsetHeight+r.offsetTop-(i.offsetTop+i.offsetHeight+o.y))>0&&u.setTop(i,u.getTop(i)+n+10)}}}}},n._renderChildren=function(){var t=this,e=this.props.block,r=e.getKey(),n=e.getText(),u=this.props.tree.size-1,c=_(this.props.selection,r);return this.props.tree.map((function(p,h){var d=p.get("leaves");if(0===d.size)return null;var v=d.size-1,g=d.map((function(i,l){var f=a.encode(r,h,l),p=i.get("start"),d=i.get("end");return s.createElement(o,{key:f,offsetKey:f,block:e,start:p,selection:c?t.props.selection:null,forceSelection:t.props.forceSelection,text:n.slice(p,d),styleSet:e.getInlineStyleAt(p),customStyleMap:t.props.customStyleMap,customStyleFn:t.props.customStyleFn,isLast:h===u&&l===v})})).toArray(),y=p.get("decoratorKey");if(null==y)return g;if(!t.props.decorator)return g;var _=m(t.props.decorator),b=_.getComponentForKey(y);if(!b)return g;var S=_.getPropsForKey(y),w=a.encode(r,h,0),x=d.first().get("start"),E=d.last().get("end"),O=n.slice(x,E),C=e.getEntityAt(p.get("start")),k=f.getHTMLDirIfDifferent(l.getDirection(O),t.props.direction),D={contentState:t.props.contentState,decoratedText:O,dir:k,start:x,end:E,blockKey:r,entityKey:C,offsetKey:w};return s.createElement(b,i({},S,D,{key:w}),g)})).toArray()},n.render=function(){var t=this,e=this.props,r=e.direction,n=e.offsetKey,i=p({"public/DraftStyleDefault/block":!0,"public/DraftStyleDefault/ltr":"LTR"===r,"public/DraftStyleDefault/rtl":"RTL"===r});return s.createElement("div",{"data-offset-key":n,className:i,ref:function(e){return t._node=e}},this._renderChildren())},DraftEditorBlock}(s.Component);t.exports=b},25821:(t,e,r)=>{"use strict";var n=r(27418);function i(){return i=n||function(t){for(var e=1;e0&&window.scrollTo(o.x,o.y+n+10)}else{y(r)||g(!1);var s=r;(n=s.offsetHeight+s.offsetTop-(i.offsetHeight+o.y))>0&&l.setTop(i,l.getTop(i)+n+10)}}}},n.render=function(){var t=this,e=this.props,r=e.block,n=e.blockRenderMap,a=e.blockRendererFn,l=e.blockStyleFn,f=e.contentState,p=e.decorator,h=e.editorKey,d=e.editorState,v=e.customStyleFn,g=e.customStyleMap,y=e.direction,w=e.forceSelection,x=e.selection,E=e.tree,O=null;r.children.size&&(O=r.children.reduce((function(e,r){var i=u.encode(r,0,0),s=f.getBlockForKey(r),p=b(s,a),v=p.CustomComponent||DraftEditorBlockNode,g=_(s,n),y=g.Element,m=g.wrapperTemplate,w=S(s,h,i,l,p,null),x=o({},t.props,{tree:d.getBlockTree(r),blockProps:p.customProps,offsetKey:i,block:s});return e.push(c.createElement(y,w,c.createElement(v,x))),!m||function(t,e){var r=t.getNextSiblingKey();return!!r&&e.getBlockForKey(r).getType()===t.getType()}(s,f)||function(t,e,r){var n=[],i=!0,o=!1,a=void 0;try{for(var s,l=r.reverse()[Symbol.iterator]();!(i=(s=l.next()).done);i=!0){var f=s.value;if(f.type!==e)break;n.push(f)}}catch(t){o=!0,a=t}finally{try{i||null==l.return||l.return()}finally{if(o)throw a}}r.splice(r.indexOf(n[0]),n.length+1);var p=n.reverse(),h=p[0].key;r.push(c.cloneElement(t,{key:"".concat(h,"-wrap"),"data-offset-key":u.encode(h,0,0)},p))}(m,y,e),e}),[]));var C=r.getKey(),k=u.encode(C,0,0),D=b(r,a),M=D.CustomComponent,I=null!=M?c.createElement(M,i({},this.props,{tree:d.getBlockTree(C),blockProps:D.customProps,offsetKey:k,block:r})):c.createElement(s,{block:r,children:O,contentState:f,customStyleFn:v,customStyleMap:g,decorator:p,direction:y,forceSelection:w,hasSelection:m(x,C),selection:x,tree:E});if(r.getParentKey())return I;var A=_(r,n).Element,R=S(r,h,k,l,D,this.wrapperRef);return c.createElement(A,R,I)},DraftEditorBlockNode}(c.Component);t.exports=w},33418:(t,e,r)=>{"use strict";var n=r(77907),i=r(42307),o=r(22146),a=r(14289),s=r(25399),u=r(4856),c=r(14507),l=r(84907),f=r(1244),p=r(42128),h=r(22045),d=u.isBrowser("IE"),v=!1,g=!1,y=null;var m={onCompositionStart:function(t){g=!0,function(t){y||(y=new n(l(t))).start()}(t)},onCompositionEnd:function(t){v=!1,g=!1,setTimeout((function(){v||m.resolveComposition(t)}),20)},onSelect:c,onKeyDown:function(t,e){if(!g)return m.resolveComposition(t),void t._onKeyDown(e);e.which!==s.RIGHT&&e.which!==s.LEFT||e.preventDefault()},onKeyPress:function(t,e){e.which===s.RETURN&&e.preventDefault()},resolveComposition:function(t){if(!g){var e=h(y).stopAndFlushMutations();y=null,v=!0;var r=a.set(t._latestEditorState,{inCompositionMode:!1});if(t.exitCurrentMode(),e.size){var n=r.getCurrentContent();e.forEach((function(t,e){var s=o.decode(e),u=s.blockKey,c=s.decoratorKey,l=s.leafKey,f=r.getBlockTree(u).getIn([c,"leaves",l]),h=f.start,d=f.end,v=r.getSelection().merge({anchorKey:u,focusKey:u,anchorOffset:h,focusOffset:d,isBackward:!1}),g=p(n,v),y=n.getBlockForKey(u).getInlineStyleAt(h);n=i.replaceText(n,v,t,y,g),r=a.set(r,{currentContent:n})}));var s=f(r,l(t)).selectionState;t.restoreEditorDOM();var u=d?a.forceSelection(r,s):a.acceptSelection(r,s);t.update(a.push(u,n,"insert-characters"))}else t.update(r)}}};t.exports=m},88795:(t,e,r)=>{"use strict";var n=r(27418);function i(){return i=n||function(t){for(var e=1;e=4,"public/DraftStyleDefault/listLTR":"LTR"===n,"public/DraftStyleDefault/listRTL":"RTL"===n})},d=function(t){var e,r;function DraftEditorContents(){return t.apply(this,arguments)||this}r=t,(e=DraftEditorContents).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r;var n=DraftEditorContents.prototype;return n.shouldComponentUpdate=function(t){var e=this.props.editorState,r=t.editorState;if(e.getDirectionMap()!==r.getDirectionMap())return!0;if(e.getSelection().getHasFocus()!==r.getSelection().getHasFocus())return!0;var n=r.getNativelyRenderedContent(),i=e.isInCompositionMode(),o=r.isInCompositionMode();if(e===r||null!==n&&r.getCurrentContent()===n||i&&o)return!1;var a=e.getCurrentContent(),s=r.getCurrentContent(),u=e.getDecorator(),c=r.getDecorator();return i!==o||a!==s||u!==c||r.mustForceSelection()},n.render=function(){for(var t=this.props,e=t.blockRenderMap,r=t.blockRendererFn,n=t.blockStyleFn,a=t.customStyleMap,l=t.customStyleFn,d=t.editorState,v=t.editorKey,g=t.preventScroll,y=t.textDirectionality,m=d.getCurrentContent(),_=d.getSelection(),b=d.mustForceSelection(),S=d.getDecorator(),w=p(d.getDirectionMap()),x=m.getBlocksAsArray(),E=[],O=null,C=null,k=0;kO,B));var U=R||s,G={className:F,"data-block":!0,"data-editor":v,"data-offset-key":q,key:M};void 0!==z&&(G=o({},G,{contentEditable:z,suppressContentEditableWarning:!0}));var H=c.createElement(K,G,c.createElement(U,i({},P,{key:M})));E.push({block:H,wrapperTemplate:L,key:M,offsetKey:q}),O=L?D.getDepth():null,C=L}for(var W=[],V=0;V{"use strict";var n=r(68642)("draft_tree_data_support");t.exports=r(n?69459:88795)},69459:(t,e,r)=>{"use strict";var n=r(27418);function i(){return i=n||function(t){for(var e=1;e{"use strict";var n=r(27418);function i(){return i=n||function(t){for(var e=1;e{"use strict";var n=r(44891),i=r(42307),o=r(14289),a=r(69270),s=r(75795),u=r(21738),c=r(94486),l=r(48083),f=r(42177),p=r(22045);var h={onDragEnd:function(t){t.exitCurrentMode(),d(t)},onDrop:function(t,e){var r=new n(e.nativeEvent.dataTransfer),l=t._latestEditorState,h=function(t,e){var r=null,n=null,i=s(t.currentTarget);if("function"==typeof i.caretRangeFromPoint){var o=i.caretRangeFromPoint(t.x,t.y);r=o.startContainer,n=o.startOffset}else{if(!t.rangeParent)return null;r=t.rangeParent,n=t.rangeOffset}r=p(r),n=p(n);var u=p(a(r));return c(e,u,n,u,n)}(e.nativeEvent,l);if(e.preventDefault(),t._dragCount=0,t.exitCurrentMode(),null!=h){var g=r.getFiles();if(g.length>0){if(t.props.handleDroppedFiles&&f(t.props.handleDroppedFiles(h,g)))return;u(g,(function(e){e&&t.update(v(l,h,e))}))}else{var y=t._internalDrag?"internal":"external";t.props.handleDrop&&f(t.props.handleDrop(h,r,y))||(t._internalDrag?t.update(function(t,e){var r=i.moveText(t.getCurrentContent(),t.getSelection(),e);return o.push(t,r,"insert-fragment")}(l,h)):t.update(v(l,h,r.getText()))),d(t)}}}};function d(t){t._internalDrag=!1;var e=t.editorContainer;if(e){var r=new MouseEvent("mouseup",{view:l(e),bubbles:!0,cancelable:!0});e.dispatchEvent(r)}}function v(t,e,r){var n=i.insertText(t.getCurrentContent(),e,r,t.getCurrentInlineStyle());return o.push(t,n,"insert-fragment")}t.exports=h},19394:(t,e,r)=>{"use strict";var n=r(4856),i=r(26396),o=r(43421),a=r(6155),s=r(69328),u=r(88922),c=r(39499),l=r(80981),f=r(62186),p=r(29971),h=r(46397),d=r(6089),v=r(14507),g=n.isBrowser("Chrome"),y=n.isBrowser("Firefox"),m=g||y?v:function(t){},_={onBeforeInput:i,onBlur:o,onCompositionStart:a,onCopy:s,onCut:u,onDragOver:c,onDragStart:l,onFocus:f,onInput:p,onKeyDown:h,onPaste:d,onSelect:v,onMouseUp:m,onKeyUp:m};t.exports=_},4083:(t,e,r)=>{"use strict";var n=r(73935).unstable_flushControlled;t.exports=n},42282:(t,e,r)=>{"use strict";var n=r(27418);var i=r(80052),o=r(67294),a=r(73759),s=r(16581),u=r(45412).setDraftEditorSelection,c=function(t){var e,r;function DraftEditorLeaf(){for(var e,r,n,i,o=arguments.length,a=new Array(o),s=0;s{"use strict";var n=r(3259),i=r(42282),o=r(22146),a=r(82371),s=r(67294),u=r(62620),c=(a.List,function(t){var e,r;function DraftEditorNode(){return t.apply(this,arguments)||this}return r=t,(e=DraftEditorNode).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r,DraftEditorNode.prototype.render=function(){var t=this.props,e=t.block,r=t.contentState,a=t.customStyleFn,c=t.customStyleMap,l=t.decorator,f=t.direction,p=t.forceSelection,h=t.hasSelection,d=t.selection,v=t.tree,g=e.getKey(),y=e.getText(),m=v.size-1,_=this.props.children||v.map((function(t,u){var v=t.get("decoratorKey"),_=t.get("leaves"),b=_.size-1,S=_.map((function(t,r){var n=o.encode(g,u,r),l=t.get("start"),f=t.get("end");return s.createElement(i,{key:n,offsetKey:n,block:e,start:l,selection:h?d:null,forceSelection:p,text:y.slice(l,f),styleSet:e.getInlineStyleAt(l),customStyleMap:c,customStyleFn:a,isLast:v===m&&r===b})})).toArray();return v&&l?s.createElement(n,{block:e,children:S,contentState:r,decorator:l,decoratorKey:v,direction:f,leafSet:t,text:y,key:u}):S})).toArray();return s.createElement("div",{"data-offset-key":o.encode(g,0,0),className:u({"public/DraftStyleDefault/block":!0,"public/DraftStyleDefault/ltr":"LTR"===f,"public/DraftStyleDefault/rtl":"RTL"===f})},_)},DraftEditorNode}(s.Component));t.exports=c},28094:(t,e,r)=>{"use strict";var n=r(67294),i=r(62620),o=function(t){var e,r;function DraftEditorPlaceholder(){return t.apply(this,arguments)||this}r=t,(e=DraftEditorPlaceholder).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r;var o=DraftEditorPlaceholder.prototype;return o.shouldComponentUpdate=function(t){return this.props.text!==t.text||this.props.editorState.getSelection().getHasFocus()!==t.editorState.getSelection().getHasFocus()},o.render=function(){var t=this.props.editorState.getSelection().getHasFocus(),e=i({"public/DraftEditorPlaceholder/root":!0,"public/DraftEditorPlaceholder/hasFocus":t});return n.createElement("div",{className:e},n.createElement("div",{className:i("public/DraftEditorPlaceholder/inner"),id:this.props.accessibilityID,style:{whiteSpace:"pre-wrap"}},this.props.text))},DraftEditorPlaceholder}(n.Component);t.exports=o},80052:(t,e,r)=>{"use strict";function n(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function i(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var o=r(67294),a=r(4856),s=r(73759),u=r(84368),c=a.isBrowser("IE <= 11");var l=function(t){var e,r;function DraftEditorTextNode(e){var r;return i(n(r=t.call(this,e)||this),"_forceFlag",void 0),i(n(r),"_node",void 0),r._forceFlag=!1,r}r=t,(e=DraftEditorTextNode).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r;var a=DraftEditorTextNode.prototype;return a.shouldComponentUpdate=function(t){var e=this._node,r=""===t.children;u(e)||s(!1);var n=e;return r?!function(t){return c?"\n"===t.textContent:"BR"===t.tagName}(n):n.textContent!==t.children},a.componentDidMount=function(){this._forceFlag=!this._forceFlag},a.componentDidUpdate=function(){this._forceFlag=!this._forceFlag},a.render=function(){var t=this;return""===this.props.children?this._forceFlag?function NEWLINE_A(t){return c?o.createElement("span",{key:"A","data-text":"true",ref:t},"\n"):o.createElement("br",{key:"A","data-text":"true",ref:t})}((function(e){return t._node=e})):function NEWLINE_B(t){return c?o.createElement("span",{key:"B","data-text":"true",ref:t},"\n"):o.createElement("br",{key:"B","data-text":"true",ref:t})}((function(e){return t._node=e})):o.createElement("span",{key:this._forceFlag?"A":"B","data-text":"true",ref:function(e){return t._node=e}},this.props.children)},DraftEditorTextNode}(o.Component);t.exports=l},5880:t=>{"use strict";t.exports={initODS:function(){},handleExtensionCausedError:function(){}}},82222:(t,e,r)=>{"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var i=r(39006),o=r(82371),a=r(73759),s=r(76363),u=(0,o.Map)(),c=s();function l(t,e){console.warn("WARNING: "+t+' will be deprecated soon!\nPlease use "'+e+'" instead.')}var f={getLastCreatedEntityKey:function(){return l("DraftEntity.getLastCreatedEntityKey","contentState.getLastCreatedEntityKey"),f.__getLastCreatedEntityKey()},create:function(t,e,r){return l("DraftEntity.create","contentState.createEntity"),f.__create(t,e,r)},add:function(t){return l("DraftEntity.add","contentState.addEntity"),f.__add(t)},get:function(t){return l("DraftEntity.get","contentState.getEntity"),f.__get(t)},__getAll:function __getAll(){return u},__loadWithEntities:function __loadWithEntities(t){u=t,c=s()},mergeData:function(t,e){return l("DraftEntity.mergeData","contentState.mergeEntityData"),f.__mergeData(t,e)},replaceData:function(t,e){return l("DraftEntity.replaceData","contentState.replaceEntityData"),f.__replaceData(t,e)},__getLastCreatedEntityKey:function __getLastCreatedEntityKey(){return c},__create:function __create(t,e,r){return f.__add(new i({type:t,mutability:e,data:r||{}}))},__add:function __add(t){return c=s(),u=u.set(c,t),c},__get:function __get(t){var e=u.get(t);return e||a(!1),e},__mergeData:function __mergeData(t,e){var r=f.__get(t),i=function(t){for(var e=1;e{"use strict";var n=function(t){var e,r;function DraftEntityInstance(){return t.apply(this,arguments)||this}r=t,(e=DraftEntityInstance).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r;var n=DraftEntityInstance.prototype;return n.getType=function(){return this.get("type")},n.getMutability=function(){return this.get("mutability")},n.getData=function(){return this.get("data")},DraftEntityInstance}((0,r(82371).Record)({type:"TOKEN",mutability:"IMMUTABLE",data:Object}));t.exports=n},5195:t=>{"use strict";t.exports={getRemovalRange:function(t,e,r,n,i){var o=r.split(" ");o=o.map((function(t,e){if("forward"===i){if(e>0)return" "+t}else if(e{"use strict";t.exports={logBlockedSelectionEvent:function(){return null},logSelectionStateFailure:function(){return null}}},42307:(t,e,r)=>{"use strict";var n=r(4516),i=r(13483),o=r(68750),a=r(81446),s=r(88687),u=r(82371),c=r(54542),l=r(18467),f=r(73759),p=r(57429),h=r(14017),d=r(54879),v=r(36043),g=u.OrderedSet,y={replaceText:function(t,e,r,i,o){var a=h(t,e),s=d(a,e),u=n.create({style:i||g(),entity:o||null});return l(s,s.getSelectionAfter(),r,u)},insertText:function(t,e,r,n,i){return e.isCollapsed()||f(!1),y.replaceText(t,e,r,n,i)},moveText:function(t,e,r){var n=s(t,e),i=y.removeRange(t,e,"backward");return y.replaceWithFragment(i,r,n)},replaceWithFragment:function(t,e,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"REPLACE_WITH_NEW_DATA",i=h(t,e),o=d(i,e);return c(o,o.getSelectionAfter(),r,n)},removeRange:function(t,e,r){var n,i,o,s;e.getIsBackward()&&(e=e.merge({anchorKey:e.getFocusKey(),anchorOffset:e.getFocusOffset(),focusKey:e.getAnchorKey(),focusOffset:e.getAnchorOffset(),isBackward:!1})),n=e.getAnchorKey(),i=e.getFocusKey(),o=t.getBlockForKey(n),s=t.getBlockForKey(i);var u=e.getStartOffset(),c=e.getEndOffset(),l=o.getEntityAt(u),f=s.getEntityAt(c-1);if(n===i&&l&&l===f){var p=a(t.getEntityMap(),o,s,e,r);return d(t,p)}var v=h(t,e);return d(v,e)},splitBlock:function(t,e){var r=h(t,e),n=d(r,e);return v(n,n.getSelectionAfter())},applyInlineStyle:function(t,e,r){return i.add(t,e,r)},removeInlineStyle:function(t,e,r){return i.remove(t,e,r)},setBlockType:function(t,e,r){return p(t,e,(function(t){return t.merge({type:r,depth:0})}))},setBlockData:function(t,e,r){return p(t,e,(function(t){return t.merge({data:r})}))},mergeBlockData:function(t,e,r){return p(t,e,(function(t){return t.merge({data:t.getData().merge(r)})}))},applyEntity:function(t,e,r){var n=h(t,e);return o(n,e,r)}};t.exports=y},22146:t=>{"use strict";var e="-",r={encode:function(t,r,n){return t+e+r+e+n},decode:function(t){var r=t.split(e).reverse(),n=r[0],i=r[1];return{blockKey:r.slice(2).reverse().join(e),decoratorKey:parseInt(i,10),leafKey:parseInt(n,10)}}};t.exports=r},45712:(t,e,r)=>{"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var i=r(38777),o=r(67953),a=r(67841),s=r(25027),u=r(69769),c=r(68642),l=r(82371),f=r(55283),p=l.List,h=l.Repeat,d=c("draft_tree_data_support"),v=d?o:i,g={processHTML:function(t,e){return a(t,u,e)},processText:function(t,e,r){return t.reduce((function(t,i,o){i=f(i);var a=s(),u={key:a,type:r,text:i,characterList:p(h(e,i.length))};if(d&&0!==o){var c=o-1;u=function(t){for(var e=1;e{"use strict";var n="['‘’]",i="\\s|(?![_])"+r(65724).getPunctuation(),o=new RegExp("^(?:"+i+")*(?:"+n+"|(?!"+i+").)*(?:(?!"+i+").)"),a=new RegExp("(?:(?!"+i+").)(?:"+n+"|(?!"+i+").)*(?:"+i+")*$");function s(t,e){var r=e?a.exec(t):o.exec(t);return r?r[0]:t}var u={getBackward:function(t){return s(t,!0)},getForward:function(t){return s(t,!1)}};t.exports=u},86155:t=>{"use strict";var e={stringify:function(t){return"_"+String(t)},unstringify:function(t){return t.slice(1)}};t.exports=e},68957:(t,e,r)=>{"use strict";function n(t){for(var e=1;e0)||(delete e.children,r.push(e))})),t.blocks=r,n({},t,{blocks:r})):t},fromRawStateToRawTreeState:function(t){var e=[],r=[];return t.blocks.forEach((function(t){var i=s(t),a=t.depth||0,u=n({},t,{children:[]});if(i){var c=r[0];if(null==c&&0===a)e.push(u);else if(null==c||c.depth=a;)r.shift(),c=r[0];a>0?c.children.push(u):e.push(u)}}else e.push(u)})),n({},t,{blocks:e})}};t.exports=u},12119:(t,e,r)=>{"use strict";r(63620);t.exports={isValidBlock:function(t,e){var r=t.getKey(),n=t.getParentKey();if(null!=n&&!e.get(n).getChildKeys().includes(r))return!1;if(!t.getChildKeys().map((function(t){return e.get(t)})).every((function(t){return t.getParentKey()===r})))return!1;var i=t.getPrevSiblingKey();if(null!=i&&e.get(i).getNextSiblingKey()!==r)return!1;var o=t.getNextSiblingKey();if(null!=o&&e.get(o).getPrevSiblingKey()!==r)return!1;return(null===o||null===i||i!==o)&&!(""!=t.text&&t.getChildKeys().size>0)},isConnectedTree:function(t){var e=t.toArray().filter((function(t){return null==t.getParentKey()&&null==t.getPrevSiblingKey()}));if(1!==e.length)return!1;for(var r=0,n=e.shift().getKey(),i=[];null!=n;){var o=t.get(n),a=o.getChildKeys(),s=o.getNextSiblingKey();if(a.size>0){null!=s&&i.unshift(s);var u=a.map((function(e){return t.get(e)})).find((function(t){return null==t.getPrevSiblingKey()}));if(null==u)return!1;n=u.getKey()}else n=null!=o.getNextSiblingKey()?o.getNextSiblingKey():i.shift();r++}return r===t.size},isValidTree:function(t){var e=this;return!!t.toArray().every((function(r){return e.isValidBlock(r,t)}))&&this.isConnectedTree(t)}}},33337:(t,e,r)=>{"use strict";var n,i=r(7902),o=r(82371),a=r(22045),s=o.OrderedMap,u={getDirectionMap:function(t,e){n?n.reset():n=new i;var r=t.getBlockMap(),u=r.valueSeq().map((function(t){return a(n).getDirection(t.getText())})),c=s(r.keySeq().zip(u));return null!=e&&o.is(e,c)?e:c}};t.exports=u},14289:(t,e,r)=>{"use strict";function n(t){for(var e=1;e0)return i.getInlineStyleAt(n-1);if(i.getLength())return i.getInlineStyleAt(0);return _(t,r)}(e,r):function(t,e){var r=e.getStartKey(),n=e.getStartOffset(),i=t.getBlockForKey(r);if(n0)return i.getInlineStyleAt(n-1);return _(t,r)}(e,r)},t.getBlockTree=function(t){return this.getImmutable().getIn(["treeMap",t])},t.isSelectionAtStartOfContent=function(){var t=this.getCurrentContent().getBlockMap().first().getKey();return this.getSelection().hasEdgeWithin(t,0,0)},t.isSelectionAtEndOfContent=function(){var t=this.getCurrentContent().getBlockMap().last(),e=t.getLength();return this.getSelection().hasEdgeWithin(t.getKey(),e,e)},t.getDirectionMap=function(){return this.getImmutable().get("directionMap")},EditorState.acceptSelection=function(t,e){return y(t,e,!1)},EditorState.forceSelection=function(t,e){return e.getHasFocus()||(e=e.set("hasFocus",!0)),y(t,e,!0)},EditorState.moveSelectionToEnd=function(t){var e=t.getCurrentContent().getLastBlock(),r=e.getKey(),n=e.getLength();return EditorState.acceptSelection(t,new u({anchorKey:r,anchorOffset:n,focusKey:r,focusOffset:n,isBackward:!1}))},EditorState.moveFocusToEnd=function(t){var e=EditorState.moveSelectionToEnd(t);return EditorState.forceSelection(e,e.getSelection())},EditorState.push=function(t,e,r){var n=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];if(t.getCurrentContent()===e)return t;var i=s.getDirectionMap(e,t.getDirectionMap());if(!t.getAllowUndo())return EditorState.set(t,{currentContent:e,directionMap:i,lastChangeType:r,selection:e.getSelectionAfter(),forceSelection:n,inlineStyleOverride:null});var o=t.getSelection(),a=t.getCurrentContent(),u=t.getUndoStack(),c=e;o!==a.getSelectionAfter()||function(t,e){var r=t.getLastChangeType();return e!==r||"insert-characters"!==e&&"backspace-character"!==e&&"delete-character"!==e}(t,r)?(u=u.push(a),c=c.set("selectionBefore",o)):"insert-characters"!==r&&"backspace-character"!==r&&"delete-character"!==r||(c=c.set("selectionBefore",a.getSelectionBefore()));var l=t.getInlineStyleOverride();-1===["adjust-depth","change-block-type","split-block"].indexOf(r)&&(l=null);var f={currentContent:c,directionMap:i,undoStack:u,redoStack:p(),lastChangeType:r,selection:e.getSelectionAfter(),forceSelection:n,inlineStyleOverride:l};return EditorState.set(t,f)},EditorState.undo=function(t){if(!t.getAllowUndo())return t;var e=t.getUndoStack(),r=e.peek();if(!r)return t;var n=t.getCurrentContent(),i=s.getDirectionMap(r,t.getDirectionMap());return EditorState.set(t,{currentContent:r,directionMap:i,undoStack:e.shift(),redoStack:t.getRedoStack().push(n),forceSelection:!0,inlineStyleOverride:null,lastChangeType:"undo",nativelyRenderedContent:null,selection:n.getSelectionBefore()})},EditorState.redo=function(t){if(!t.getAllowUndo())return t;var e=t.getRedoStack(),r=e.peek();if(!r)return t;var n=t.getCurrentContent(),i=s.getDirectionMap(r,t.getDirectionMap());return EditorState.set(t,{currentContent:r,directionMap:i,undoStack:t.getUndoStack().push(n),redoStack:e.shift(),forceSelection:!0,inlineStyleOverride:null,lastChangeType:"redo",nativelyRenderedContent:null,selection:r.getSelectionAfter()})},t.getImmutable=function(){return this._immutable},EditorState}();function y(t,e,r){return g.set(t,{selection:e,forceSelection:r,nativelyRenderedContent:null,inlineStyleOverride:null})}function m(t,e){return t.getBlockMap().map((function(r){return o.generate(t,r,e)})).toOrderedMap()}function _(t,e){var r=t.getBlockMap().reverse().skipUntil((function(t,r){return r===e})).skip(1).skipUntil((function(t,e){return t.getLength()})).first();return r?r.getInlineStyleAt(r.getLength()-1):l()}t.exports=g},47387:(t,e,r)=>{"use strict";var n=r(4856),i=r(17797),o=n.isPlatform("Mac OS X"),a={isCtrlKeyCommand:function(t){return!!t.ctrlKey&&!t.altKey},isOptionKeyCommand:function(t){return o&&t.altKey},usesMacOSHeuristics:function(){return o},hasCommandModifier:function(t){return o?!!t.metaKey&&!t.altKey:a.isCtrlKeyCommand(t)},isSoftNewlineEvent:i};t.exports=a},70054:()=>{},41947:(t,e,r)=>{"use strict";var n=r(42307),i=r(14289),o=r(1665),a=r(22045),s={currentBlockContainsLink:function(t){var e=t.getSelection(),r=t.getCurrentContent(),n=r.getEntityMap();return r.getBlockForKey(e.getAnchorKey()).getCharacterList().slice(e.getStartOffset(),e.getEndOffset()).some((function(t){var e=t.getEntity();return!!e&&"LINK"===n.__get(e).getType()}))},getCurrentBlockType:function(t){var e=t.getSelection();return t.getCurrentContent().getBlockForKey(e.getStartKey()).getType()},getDataObjectForLinkURL:function(t){return{url:t.toString()}},handleKeyCommand:function(t,e,r){switch(e){case"bold":return s.toggleInlineStyle(t,"BOLD");case"italic":return s.toggleInlineStyle(t,"ITALIC");case"underline":return s.toggleInlineStyle(t,"UNDERLINE");case"code":return s.toggleCode(t);case"backspace":case"backspace-word":case"backspace-to-start-of-line":return s.onBackspace(t);case"delete":case"delete-word":case"delete-to-end-of-block":return s.onDelete(t);default:return null}},insertSoftNewline:function(t){var e=n.insertText(t.getCurrentContent(),t.getSelection(),"\n",t.getCurrentInlineStyle(),null),r=i.push(t,e,"insert-characters");return i.forceSelection(r,e.getSelectionAfter())},onBackspace:function(t){var e=t.getSelection();if(!e.isCollapsed()||e.getAnchorOffset()||e.getFocusOffset())return null;var r=t.getCurrentContent(),n=e.getStartKey(),o=r.getBlockBefore(n);if(o&&"atomic"===o.getType()){var a=r.getBlockMap().delete(o.getKey()),u=r.merge({blockMap:a,selectionAfter:e});if(u!==r)return i.push(t,u,"remove-range")}var c=s.tryToRemoveBlockStyle(t);return c?i.push(t,c,"change-block-type"):null},onDelete:function(t){var e=t.getSelection();if(!e.isCollapsed())return null;var r=t.getCurrentContent(),o=e.getStartKey(),a=r.getBlockForKey(o).getLength();if(e.getStartOffset(){"use strict";var n=r(42307),i=r(14289),o=r(88687),a=r(22045),s=null,u={cut:function(t){var e=t.getCurrentContent(),r=t.getSelection(),u=null;if(r.isCollapsed()){var c=r.getAnchorKey(),l=e.getBlockForKey(c).getLength();if(l===r.getAnchorOffset()){var f=e.getKeyAfter(c);if(null==f)return t;u=r.set("focusKey",f).set("focusOffset",0)}else u=r.set("focusOffset",l)}else u=r;u=a(u),s=o(e,u);var p=n.removeRange(e,u,"forward");return p===e?t:i.push(t,p,"remove-range")},paste:function(t){if(!s)return t;var e=n.replaceWithFragment(t.getCurrentContent(),t.getSelection(),s);return i.push(t,e,"insert-fragment")}};t.exports=u},25110:(t,e,r)=>{"use strict";var n=function(t){var e,r;function SelectionState(){return t.apply(this,arguments)||this}r=t,(e=SelectionState).prototype=Object.create(r.prototype),e.prototype.constructor=e,e.__proto__=r;var n=SelectionState.prototype;return n.serialize=function(){return"Anchor: "+this.getAnchorKey()+":"+this.getAnchorOffset()+", Focus: "+this.getFocusKey()+":"+this.getFocusOffset()+", Is Backward: "+String(this.getIsBackward())+", Has Focus: "+String(this.getHasFocus())},n.getAnchorKey=function(){return this.get("anchorKey")},n.getAnchorOffset=function(){return this.get("anchorOffset")},n.getFocusKey=function(){return this.get("focusKey")},n.getFocusOffset=function(){return this.get("focusOffset")},n.getIsBackward=function(){return this.get("isBackward")},n.getHasFocus=function(){return this.get("hasFocus")},n.hasEdgeWithin=function(t,e,r){var n=this.getAnchorKey(),i=this.getFocusKey();if(n===i&&n===t){var o=this.getStartOffset(),a=this.getEndOffset();return e<=o&&o<=r||e<=a&&a<=r}if(t!==n&&t!==i)return!1;var s=t===n?this.getAnchorOffset():this.getFocusOffset();return e<=s&&r>=s},n.isCollapsed=function(){return this.getAnchorKey()===this.getFocusKey()&&this.getAnchorOffset()===this.getFocusOffset()},n.getStartKey=function(){return this.getIsBackward()?this.getFocusKey():this.getAnchorKey()},n.getStartOffset=function(){return this.getIsBackward()?this.getFocusOffset():this.getAnchorOffset()},n.getEndKey=function(){return this.getIsBackward()?this.getAnchorKey():this.getFocusKey()},n.getEndOffset=function(){return this.getIsBackward()?this.getAnchorOffset():this.getFocusOffset()},SelectionState.createEmpty=function(t){return new SelectionState({anchorKey:t,anchorOffset:0,focusKey:t,focusOffset:0,isBackward:!1,hasFocus:!1})},SelectionState}((0,r(82371).Record)({anchorKey:"",anchorOffset:0,focusKey:"",focusOffset:0,isBackward:!1,hasFocus:!1}));t.exports=n},1665:t=>{"use strict";t.exports=function(t,e,r,n){var i=e.getStartKey(),o=e.getEndKey(),a=t.getBlockMap(),s=a.toSeq().skipUntil((function(t,e){return e===i})).takeUntil((function(t,e){return e===o})).concat([[o,a.get(o)]]).map((function(t){var e=t.getDepth()+r;return e=Math.max(0,Math.min(e,n)),t.set("depth",e)}));return a=a.merge(s),t.merge({blockMap:a,selectionBefore:e,selectionAfter:e})}},2835:(t,e,r)=>{"use strict";var n=r(4516);t.exports=function(t,e,r,i){for(var o=e,a=t.getCharacterList();o{"use strict";var n=r(2835),i=r(82371);t.exports=function(t,e,r){var o=t.getBlockMap(),a=e.getStartKey(),s=e.getStartOffset(),u=e.getEndKey(),c=e.getEndOffset(),l=o.skipUntil((function(t,e){return e===a})).takeUntil((function(t,e){return e===u})).toOrderedMap().merge(i.OrderedMap([[u,o.get(u)]])).map((function(t,e){var i=e===a?s:0,o=e===u?c:t.getLength();return n(t,i,o,r)}));return t.merge({blockMap:o.merge(l),selectionBefore:e,selectionAfter:e})}},79981:(t,e,r)=>{"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var i=r(38777),o=r(67953),a=r(86155),s=r(56265),u=r(31487),c=r(73759),l=function(t,e){return{key:t.getKey(),text:t.getText(),type:t.getType(),depth:t.getDepth(),inlineStyleRanges:u(t),entityRanges:s(t,e),data:t.getData().toObject()}},f=function(t,e,r,a){if(t instanceof i)r.push(l(t,e));else{t instanceof o||c(!1);var s=t.getParentKey(),u=a[t.getKey()]=function(t){for(var e=1;e{"use strict";var n;function i(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:0;return Object.keys(B).some((function(r){t.classList.contains(r)&&(e=B[r])})),e},L=function(t){if(!b(t))return!1;var e=t;if(!e.href||"http:"!==e.protocol&&"https:"!==e.protocol&&"mailto:"!==e.protocol&&"tel:"!==e.protocol)return!1;try{new f(e.href);return!0}catch(t){return!1}},K=function(t){if(!x(t))return!1;var e=t;return!(!e.attributes.getNamedItem("src")||!e.attributes.getNamedItem("src").value)},N=function(t,e){if(!w(t))return e;var r=t,n=r.style.fontWeight,i=r.style.fontStyle,o=r.style.textDecoration;return e.withMutations((function(t){A.indexOf(n)>=0?t.add("BOLD"):R.indexOf(n)>=0&&t.remove("BOLD"),"italic"===i?t.add("ITALIC"):"normal"===i&&t.remove("ITALIC"),"underline"===o&&t.add("UNDERLINE"),"line-through"===o&&t.add("STRIKETHROUGH"),"none"===o&&(t.remove("UNDERLINE"),t.remove("STRIKETHROUGH"))}))},F=function(t){return"ul"===t||"ol"===t},U=function(){function ContentBlocksBuilder(t,e){o(this,"characterList",y()),o(this,"currentBlockType","unstyled"),o(this,"currentDepth",0),o(this,"currentEntity",null),o(this,"currentText",""),o(this,"wrapper",null),o(this,"blockConfigs",[]),o(this,"contentBlocks",[]),o(this,"entityMap",l),o(this,"blockTypeMap",void 0),o(this,"disambiguate",void 0),this.clear(),this.blockTypeMap=t,this.disambiguate=e}var t=ContentBlocksBuilder.prototype;return t.clear=function(){this.characterList=y(),this.blockConfigs=[],this.currentBlockType="unstyled",this.currentDepth=0,this.currentEntity=null,this.currentText="",this.entityMap=l,this.wrapper=null,this.contentBlocks=[]},t.addDOMNode=function(t){var e;return this.contentBlocks=[],this.currentDepth=0,(e=this.blockConfigs).push.apply(e,this._toBlockConfigs([t],_())),this._trimCurrentText(),""!==this.currentText&&this.blockConfigs.push(this._makeBlockConfig()),this},t.getContentBlocks=function(){return 0===this.contentBlocks.length&&(E?this._toContentBlocks(this.blockConfigs):this._toFlatContentBlocks(this.blockConfigs)),{contentBlocks:this.contentBlocks,entityMap:this.entityMap}},t._makeBlockConfig=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=i({key:t.key||h(),type:this.currentBlockType,text:this.currentText,characterList:this.characterList,depth:this.currentDepth,parent:null,children:y(),prevSibling:null,nextSibling:null,childConfigs:[]},t);return this.characterList=y(),this.currentBlockType="unstyled",this.currentText="",e},t._toBlockConfigs=function(t,e){for(var r=[],n=0;n(r=void 0!==(n=this.characterList.reverse().findEntry((function(t){return null!==t.getEntity()})))?Math.max(r,t-n[0]):r)?(this.currentText="",this.characterList=y()):(this.currentText=this.currentText.slice(e,r),this.characterList=this.characterList.slice(e,r))},t._addTextNode=function(t,e){var r=t.textContent;""===r.trim()&&"pre"!==this.wrapper&&(r=" "),"pre"!==this.wrapper&&(r=(r=r.replace(k,"")).replace(C," ")),this._appendText(r,e)},t._addBreakNode=function(t,e){S(t)&&this._appendText("\n",e)},t._addImgNode=function(t,e){if(x(t)){var r=t,n={};z.forEach((function(t){var e=r.getAttribute(t);e&&(n[t]=e)})),this.currentEntity=this.entityMap.__create("IMAGE","IMMUTABLE",n),v("draftjs_fix_paste_for_img")?"presentation"!==r.getAttribute("role")&&this._appendText("📷",e):this._appendText("📷",e),this.currentEntity=null}},t._addAnchorNode=function(t,e,r){if(b(t)){var n=t,i={};T.forEach((function(t){var e=n.getAttribute(t);e&&(i[t]=e)})),i.url=new f(n.href).toString(),this.currentEntity=this.entityMap.__create("LINK","MUTABLE",i||{}),e.push.apply(e,this._toBlockConfigs(Array.from(t.childNodes),r)),this.currentEntity=null}},t._toContentBlocks=function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,r=t.length-1,n=0;n<=r;n++){var o=t[n];o.parent=e,o.prevSibling=n>0?t[n-1].key:null,o.nextSibling=n2&&void 0!==arguments[2]?arguments[2]:c,r=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:d)(t=t.trim().replace(O,"").replace(D," ").replace(M,"").replace(I,""));if(!r)return null;var n=function(t){var e={};return t.mapKeys((function(t,r){var n=[r.element];void 0!==r.aliasedElements&&n.push.apply(n,r.aliasedElements),n.forEach((function(r){void 0===e[r]?e[r]=t:"string"==typeof e[r]?e[r]=[e[r],t]:e[r].push(t)}))})),m(e)}(e);return new U(n,(function(t,e){return"li"===t?"ol"===e?"ordered-list-item":"unordered-list-item":null})).addDOMNode(r).getContentBlocks()}},99607:(t,e,r)=>{"use strict";function n(t){for(var e=1;e0})),i=m&&!r?c.fromRawStateToRawTreeState(t).blocks:t.blocks;if(!m)return function(t,e){return S(t.map((function(t){var r=new o(w(t,e));return[r.getKey(),r]})))}(r?c.fromRawTreeStateToRawState(t).blocks:i,e);var s=function(t,e){return t.map(E).reduce((function(r,i,o){Array.isArray(i.children)||y(!1);var s=i.children.map(E),u=new a(n({},w(i,e),{prevSibling:0===o?null:t[o-1].key,nextSibling:o===t.length-1?null:t[o+1].key,children:_(s.map((function(t){return t.key})))}));r=r.set(u.getKey(),u);for(var c=O([],s,u);c.length>0;){var l=c.pop(),f=l.parentRef,p=f.getChildKeys(),h=p.indexOf(l.key),d=Array.isArray(l.children);if(!d){d||y(!1);break}var v=l.children.map(E),g=new a(n({},w(l,e),{parent:f.getKey(),children:_(v.map((function(t){return t.key}))),prevSibling:0===h?null:p.get(h-1),nextSibling:h===p.size-1?null:p.get(h+1)}));r=r.set(g.getKey(),g),c=O(c,v,g)}return r}),S())}(i,e);return s};t.exports=function(t){Array.isArray(t.blocks)||y(!1);var e=function(t){var e=t.entityMap,r={};return Object.keys(e).forEach((function(t){var n=e[t],i=n.type,o=n.mutability,a=n.data;r[t]=u.__create(i,o,a||{})})),r}(t),r=C(t,e),n=r.isEmpty()?new l:l.createEmpty(r.first().getKey());return new s({blockMap:r,entityMap:e,selectionBefore:n,selectionAfter:n})}},86019:(t,e,r)=>{"use strict";var n=r(4516),i=r(82371).List;t.exports=function(t,e){var r=t.map((function(t,r){var i=e[r];return n.create({style:t,entity:i})}));return i(r)}},67134:(t,e,r)=>{"use strict";var n=r(38935).substr;t.exports=function(t,e){var r=Array(t.length).fill(null);return e&&e.forEach((function(e){for(var i=n(t,0,e.offset).length,o=i+n(t,e.offset,e.length).length,a=i;a{"use strict";var n=r(38935),i=r(82371).OrderedSet,o=n.substr,a=i();t.exports=function(t,e){var r=Array(t.length).fill(a);return e&&e.forEach((function(e){for(var n=o(t,0,e.offset).length,i=n+o(t,e.offset,e.length).length;n{"use strict";t.exports={notEmptyKey:function(t){return null!=t&&""!=t}}},26396:(t,e,r)=>{"use strict";var n=r(42307),i=r(14289),o=r(4856),a=r(42128),s=r(42177),u=r(40258),c=r(22045),l=r(56926),f="'",p="/",h=o.isBrowser("Firefox");function d(t,e,r,o,a){var s=n.replaceText(t.getCurrentContent(),t.getSelection(),e,r,o);return i.push(t,s,"insert-characters",a)}t.exports=function(t,e){void 0!==t._pendingStateFromBeforeInput&&(t.update(t._pendingStateFromBeforeInput),t._pendingStateFromBeforeInput=void 0);var r=t._latestEditorState,n=e.data;if(n)if(t.props.handleBeforeInput&&s(t.props.handleBeforeInput(n,r,e.timeStamp)))e.preventDefault();else{var o=r.getSelection(),v=o.getStartOffset(),g=o.getAnchorKey();if(!o.isCollapsed())return e.preventDefault(),void t.update(d(r,n,r.getCurrentInlineStyle(),a(r.getCurrentContent(),r.getSelection()),!0));var y,m=d(r,n,r.getCurrentInlineStyle(),a(r.getCurrentContent(),r.getSelection()),!1),_=!1;if(_||(_=u(t._latestCommittedEditorState)),!_){var b=r.getBlockTree(g),S=m.getBlockTree(g);_=b.size!==S.size||b.zip(S).some((function(t){var e=t[0],r=t[1],i=e.get("start"),o=i+(i>=v?n.length:0),a=e.get("end"),s=a+(a>=v?n.length:0),u=r.get("start"),c=r.get("end"),l=r.get("decoratorKey");return e.get("decoratorKey")!==l||e.get("leaves").size!==r.get("leaves").size||o!==u||s!==c||null!=l&&c-u!=a-i}))}if(_||(y=n,_=h&&(y==f||y==p)),_||(_=c(m.getDirectionMap()).get(g)!==c(r.getDirectionMap()).get(g)),_)return e.preventDefault(),m=i.set(m,{forceSelection:!0}),void t.update(m);m=i.set(m,{nativelyRenderedContent:m.getCurrentContent()}),t._pendingStateFromBeforeInput=m,l((function(){void 0!==t._pendingStateFromBeforeInput&&(t.update(t._pendingStateFromBeforeInput),t._pendingStateFromBeforeInput=void 0)}))}}},43421:(t,e,r)=>{"use strict";var n=r(14289),i=r(67476),o=r(31003);t.exports=function(t,e){var r=e.currentTarget.ownerDocument;if(!Boolean(t.props.preserveSelectionOnBlur)&&o(r)===r.body){var a=r.defaultView.getSelection(),s=t.editor;1===a.rangeCount&&i(s,a.anchorNode)&&i(s,a.focusNode)&&a.removeAllRanges()}var u=t._latestEditorState,c=u.getSelection();if(c.getHasFocus()){var l=c.set("hasFocus",!1);t.props.onBlur&&t.props.onBlur(e),t.update(n.acceptSelection(u,l))}}},6155:(t,e,r)=>{"use strict";var n=r(14289);t.exports=function(t,e){t.setMode("composite"),t.update(n.set(t._latestEditorState,{inCompositionMode:!0})),t._onCompositionStart(e)}},69328:(t,e,r)=>{"use strict";var n=r(94882);t.exports=function(t,e){t._latestEditorState.getSelection().isCollapsed()?e.preventDefault():t.setClipboard(n(t._latestEditorState))}},88922:(t,e,r)=>{"use strict";var n=r(42307),i=r(14289),o=r(19051),a=r(94882),s=r(79749),u=r(80809);t.exports=function(t,e){var r,c=t._latestEditorState,l=c.getSelection(),f=e.target;if(l.isCollapsed())e.preventDefault();else{if(u(f)){var p=f;r=s(o.getScrollParent(p))}var h=a(c);t.setClipboard(h),t.setMode("cut"),setTimeout((function(){t.restoreEditorDOM(r),t.exitCurrentMode(),t.update(function(t){var e=n.removeRange(t.getCurrentContent(),t.getSelection(),"forward");return i.push(t,e,"remove-range")}(c))}),0)}}},39499:t=>{"use strict";t.exports=function(t,e){t.setMode("drag"),e.preventDefault()}},80981:t=>{"use strict";t.exports=function(t){t._internalDrag=!0,t.setMode("drag")}},62186:(t,e,r)=>{"use strict";var n=r(14289),i=r(4856);t.exports=function(t,e){var r=t._latestEditorState,o=r.getSelection();if(!o.getHasFocus()){var a=o.set("hasFocus",!0);t.props.onFocus&&t.props.onFocus(e),i.isBrowser("Chrome < 60.0.3081.0")?t.update(n.forceSelection(r,a)):t.update(n.acceptSelection(r,a))}}},29971:(t,e,r)=>{"use strict";var n=r(42307),i=r(22146),o=r(14289),a=r(4856),s=r(99407).notEmptyKey,u=r(69270),c=r(62800),l=r(22045),f=a.isEngine("Gecko");t.exports=function(t,e){void 0!==t._pendingStateFromBeforeInput&&(t.update(t._pendingStateFromBeforeInput),t._pendingStateFromBeforeInput=void 0);var r=t.editor.ownerDocument.defaultView.getSelection(),a=r.anchorNode,p=r.isCollapsed,h=(null==a?void 0:a.nodeType)!==Node.TEXT_NODE&&(null==a?void 0:a.nodeType)!==Node.ELEMENT_NODE;if(null!=a&&!h){if(a.nodeType===Node.TEXT_NODE&&(null!==a.previousSibling||null!==a.nextSibling)){var d=a.parentNode;if(null==d)return;a.nodeValue=d.textContent;for(var v=d.firstChild;null!=v;v=v.nextSibling)v!==a&&d.removeChild(v)}var g=a.textContent,y=t._latestEditorState,m=l(u(a)),_=i.decode(m),b=_.blockKey,S=_.decoratorKey,w=_.leafKey,x=y.getBlockTree(b).getIn([S,"leaves",w]),E=x.start,O=x.end,C=y.getCurrentContent(),k=C.getBlockForKey(b),D=k.getText().slice(E,O);if(g.endsWith("\n\n")&&(g=g.slice(0,-1)),g!==D){var M,I,A,R,T=y.getSelection(),z=T.merge({anchorOffset:E,focusOffset:O,isBackward:!1}),B=k.getEntityAt(E),q=s(B)?C.getEntity(B):null,P="MUTABLE"===(null!=q?q.getMutability():null),j=P?"spellcheck-change":"apply-entity",L=n.replaceText(C,z,g,k.getInlineStyleAt(E),P?k.getEntityAt(E):null);if(f)M=r.anchorOffset,I=r.focusOffset,R=(A=E+Math.min(M,I))+Math.abs(M-I),M=A,I=R;else{var K=g.length-D.length;A=T.getStartOffset(),R=T.getEndOffset(),M=p?R+K:A,I=R+K}var N=L.merge({selectionBefore:C.getSelectionAfter(),selectionAfter:T.merge({anchorOffset:M,focusOffset:I})});t.update(o.push(y,N,j))}else{var F=e.nativeEvent.inputType;if(F){var U=function(t,e){return"deleteContentBackward"===t?c(e):e}(F,y);if(U!==y)return t.restoreEditorDOM(),void t.update(U)}}}}},46397:(t,e,r)=>{"use strict";var n=r(42307),i=r(14289),o=r(47387),a=r(25399),s=r(83751),u=r(4856),c=r(42177),l=r(49779),f=r(51050),p=r(13767),h=r(77978),d=r(67217),v=r(8425),g=r(62800),y=r(13998),m=r(53318),_=r(87051),b=o.isOptionKeyCommand,S=u.isBrowser("Chrome");t.exports=function(t,e){var r=e.which,o=t._latestEditorState;function u(r){var n=t.props[r];return!!n&&(n(e),!0)}switch(r){case a.RETURN:if(e.preventDefault(),t.props.handleReturn&&c(t.props.handleReturn(e,o)))return;break;case a.ESC:if(e.preventDefault(),u("onEscape"))return;break;case a.TAB:if(u("onTab"))return;break;case a.UP:if(u("onUpArrow"))return;break;case a.RIGHT:if(u("onRightArrow"))return;break;case a.DOWN:if(u("onDownArrow"))return;break;case a.LEFT:if(u("onLeftArrow"))return;break;case a.SPACE:S&&b(e)&&e.preventDefault()}var w=t.props.keyBindingFn(e);if(null!=w&&""!==w)if("undo"!==w){if(e.preventDefault(),!t.props.handleKeyCommand||!c(t.props.handleKeyCommand(w,o,e.timeStamp))){var x=function(t,e,r){switch(t){case"redo":return i.redo(e);case"delete":return y(e);case"delete-word":return p(e);case"backspace":return g(e);case"backspace-word":return f(e);case"backspace-to-start-of-line":return l(e,r);case"split-block":return h(e);case"transpose-characters":return m(e);case"move-selection-to-start-of-block":return v(e);case"move-selection-to-end-of-block":return d(e);case"secondary-cut":return s.cut(e);case"secondary-paste":return s.paste(e);default:return e}}(w,o,e);x!==o&&t.update(x)}}else _(e,o,t.update);else if(r===a.SPACE&&S&&b(e)){var E=n.replaceText(o.getCurrentContent(),o.getSelection()," ");t.update(i.push(o,E,"insert-characters"))}}},6089:(t,e,r)=>{"use strict";var n=r(10329),i=r(4516),o=r(44891),a=r(42307),s=r(45712),u=r(14289),c=r(41947),l=r(42128),f=r(21738),p=r(42177),h=r(44300);function d(t,e,r){var n=a.replaceWithFragment(t.getCurrentContent(),t.getSelection(),e);return u.push(t,n.set("entityMap",r),"insert-fragment")}t.exports=function(t,e){e.preventDefault();var r=new o(e.clipboardData);if(!r.isRichText()){var v=r.getFiles(),g=r.getText();if(v.length>0){if(t.props.handlePastedFiles&&p(t.props.handlePastedFiles(v)))return;return void f(v,(function(e){if(e=e||g){var r=t._latestEditorState,o=h(e),f=i.create({style:r.getCurrentInlineStyle(),entity:l(r.getCurrentContent(),r.getSelection())}),p=c.getCurrentBlockType(r),d=s.processText(o,f,p),v=n.createFromArray(d),y=a.replaceWithFragment(r.getCurrentContent(),r.getSelection(),v);t.update(u.push(r,y,"insert-fragment"))}}))}}var y=[],m=r.getText(),_=r.getHTML(),b=t._latestEditorState;if(t.props.formatPastedText){var S=t.props.formatPastedText(m,_);m=S.text,_=S.html}if(!t.props.handlePastedText||!p(t.props.handlePastedText(m,_,b))){if(m&&(y=h(m)),!t.props.stripPastedStyles){var w,x=t.getClipboard();if(!t.props.formatPastedText&&r.isRichText()&&x){if(-1!==(null===(w=_)||void 0===w?void 0:w.indexOf(t.getEditorKey()))||1===y.length&&1===x.size&&x.first().getText()===m)return void t.update(d(t._latestEditorState,x))}else if(x&&r.types.includes("com.apple.webarchive")&&!r.types.includes("text/html")&&function(t,e){return t.length===e.size&&e.valueSeq().every((function(e,r){return e.getText()===t[r]}))}(y,x))return void t.update(d(t._latestEditorState,x));if(_){var E=s.processHTML(_,t.props.blockRenderMap);if(E){var O=E.contentBlocks,C=E.entityMap;if(O){var k=n.createFromArray(O);return void t.update(d(t._latestEditorState,k,C))}}}t.setClipboard(null)}if(y.length){var D=i.create({style:b.getCurrentInlineStyle(),entity:l(b.getCurrentContent(),b.getSelection())}),M=c.getCurrentBlockType(b),I=s.processText(y,D,M),A=n.createFromArray(I);t.update(d(t._latestEditorState,A))}}}},14507:(t,e,r)=>{"use strict";var n=r(97432),i=r(14289),o=r(84907),a=r(1244);t.exports=function(t){if(t._blockSelectEvents||t._latestEditorState!==t.props.editorState){if(t._blockSelectEvents){var e=t.props.editorState.getSelection();n.logBlockedSelectionEvent({anonymizedDom:"N/A",extraParams:JSON.stringify({stacktrace:(new Error).stack}),selectionState:JSON.stringify(e.toJS())})}}else{var r=t.props.editorState,s=a(r,o(t)),u=s.selectionState;u!==r.getSelection()&&(r=s.needsRecovery?i.forceSelection(r,u):i.acceptSelection(r,u),t.update(r))}}},56265:(t,e,r)=>{"use strict";var n=r(86155),i=r(38935).strlen;t.exports=function(t,e){var r=[];return t.findEntityRanges((function(t){return!!t.getEntity()}),(function(o,a){var s=t.getText(),u=t.getEntityAt(o);r.push({offset:i(s.slice(0,o)),length:i(s.slice(o,a)),key:Number(e[n.stringify(u)])})})),r}},31487:(t,e,r)=>{"use strict";var n=r(38935),i=r(29407),o=function(t,e){return t===e},a=function(t){return!!t},s=[];t.exports=function(t){var e=t.getCharacterList().map((function(t){return t.getStyle()})).toList(),r=e.flatten().toSet().map((function(r){return function(t,e,r){var s=[],u=e.map((function(t){return t.has(r)})).toList();return i(u,o,a,(function(e,i){var o=t.getText();s.push({offset:n.strlen(o.slice(0,e)),length:n.strlen(o.slice(e,i)),style:r})})),s}(t,e,r)}));return Array.prototype.concat.apply(s,r.toJS())}},88182:(t,e,r)=>{"use strict";var n=r(38935),i=r(75795),o=r(6092),a=r(73759);function s(t,e){for(var r=1/0,n=1/0,i=-1/0,o=-1/0,a=0;a=0;d--)if(!(null!=h&&d>0&&n.isSurrogatePair(h,d-1))){if(t.setStart(f,d),!s(o(t),r))break;c=f,l=d}if(-1===d||0===f.childNodes.length)break;p=u(f=f.childNodes[d])}return t.setStart(c,l),t}},69270:(t,e,r)=>{"use strict";var n=r(75795),i=r(93578);t.exports=function(t){for(var e=t;e&&e!==n(t).documentElement;){var r=i(e);if(null!=r)return r;e=e.parentNode}return null}},29407:t=>{"use strict";t.exports=function(t,e,r,n){if(t.size){var i=0;t.reduce((function(t,o,a){return e(t,o)||(r(t)&&n(i,a),i=a),o})),r(t.last())&&n(i,t.count())}}},25027:t=>{"use strict";var e={},r=Math.pow(2,24);t.exports=function(){for(var t;void 0===t||e.hasOwnProperty(t)||!isNaN(+t);)t=Math.floor(Math.random()*r).toString(32);return e[t]=!0,t}},81446:(t,e,r)=>{"use strict";var n=r(5195),i=r(64994),o=r(73759);function a(t,e,r,a,s,u,c){var l=r.getStartOffset(),f=r.getEndOffset(),p=t.__get(s).getMutability(),h=c?l:f;if("MUTABLE"===p)return r;var d=i(e,s).filter((function(t){return h<=t.end&&h>=t.start}));1!=d.length&&o(!1);var v=d[0];if("IMMUTABLE"===p)return r.merge({anchorOffset:v.start,focusOffset:v.end,isBackward:!1});u||(c?f=v.end:l=v.start);var g=n.getRemovalRange(l,f,e.getText().slice(v.start,v.end),v.start,a);return r.merge({anchorOffset:g.start,focusOffset:g.end,isBackward:!1})}t.exports=function(t,e,r,n,i){var o=n.getStartOffset(),s=n.getEndOffset(),u=e.getEntityAt(o),c=r.getEntityAt(s-1);if(!u&&!c)return n;var l=n;if(u&&u===c)l=a(t,e,l,i,u,!0,!0);else if(u&&c){var f=a(t,e,l,i,u,!1,!0),p=a(t,r,l,i,c,!1,!1);l=l.merge({anchorOffset:f.getAnchorOffset(),focusOffset:p.getFocusOffset(),isBackward:!1})}else if(u){var h=a(t,e,l,i,u,!1,!0);l=l.merge({anchorOffset:h.getStartOffset(),isBackward:!1})}else if(c){var d=a(t,r,l,i,c,!1,!1);l=l.merge({focusOffset:d.getEndOffset(),isBackward:!1})}return l}},84907:(t,e,r)=>{"use strict";var n=r(73759),i=r(20717);t.exports=function(t){var e=t.editorContainer;return e||n(!1),i(e.firstChild)||n(!1),e.firstChild}},88687:(t,e,r)=>{"use strict";var n=r(98555),i=r(14017);t.exports=function(t,e){var r=e.getStartKey(),o=e.getStartOffset(),a=e.getEndKey(),s=e.getEndOffset(),u=i(t,e).getBlockMap(),c=u.keySeq(),l=c.indexOf(r),f=c.indexOf(a)+1;return n(u.slice(l,f).map((function(t,e){var n=t.getText(),i=t.getCharacterList();return r===a?t.merge({text:n.slice(o,s),characterList:i.slice(o,s)}):e===r?t.merge({text:n.slice(o),characterList:i.slice(o)}):e===a?t.merge({text:n.slice(0,s),characterList:i.slice(0,s)}):t})))}},75795:t=>{"use strict";t.exports=function(t){return t&&t.ownerDocument?t.ownerDocument:document}},41714:(t,e,r)=>{"use strict";var n=r(47387),i=r(25399),o=r(4856),a=o.isPlatform("Mac OS X"),s=a&&o.isBrowser("Firefox < 29"),u=n.hasCommandModifier,c=n.isCtrlKeyCommand;function l(t){return a&&t.altKey||c(t)}t.exports=function(t){switch(t.keyCode){case 66:return u(t)?"bold":null;case 68:return c(t)?"delete":null;case 72:return c(t)?"backspace":null;case 73:return u(t)?"italic":null;case 74:return u(t)?"code":null;case 75:return a&&c(t)?"secondary-cut":null;case 77:case 79:return c(t)?"split-block":null;case 84:return a&&c(t)?"transpose-characters":null;case 85:return u(t)?"underline":null;case 87:return a&&c(t)?"backspace-word":null;case 89:return c(t)?a?"secondary-paste":"redo":null;case 90:return function(t){return u(t)?t.shiftKey?"redo":"undo":null}(t)||null;case i.RETURN:return"split-block";case i.DELETE:return function(t){return!a&&t.shiftKey?null:l(t)?"delete-word":"delete"}(t);case i.BACKSPACE:return function(t){return u(t)&&a?"backspace-to-start-of-line":l(t)?"backspace-word":"backspace"}(t);case i.LEFT:return s&&u(t)?"move-selection-to-start-of-block":null;case i.RIGHT:return s&&u(t)?"move-selection-to-end-of-block":null;default:return null}}},1244:(t,e,r)=>{"use strict";var n=r(8101);t.exports=function(t,e){var r=e.ownerDocument.defaultView.getSelection(),i=r.anchorNode,o=r.anchorOffset,a=r.focusNode,s=r.focusOffset;return 0===r.rangeCount||null==i||null==a?{selectionState:t.getSelection().set("hasFocus",!1),needsRecovery:!1}:n(t,e,i,o,a,s)}},8101:(t,e,r)=>{"use strict";var n=r(69270),i=r(93578),o=r(94486),a=r(73759),s=r(84368),u=r(22045);function c(t,e,r){var o=e,c=n(o);(null!=c||t&&(t===o||t.firstChild===o)||a(!1),t===o)&&(o=o.firstChild,s(o)||a(!1),"true"!==(o=o).getAttribute("data-contents")&&a(!1),r>0&&(r=o.childNodes.length));if(0===r){var f=null;if(null!=c)f=c;else{var p=function(t){for(;t.firstChild&&(s(t.firstChild)&&"true"===t.firstChild.getAttribute("data-blocks")||i(t.firstChild));)t=t.firstChild;return t}(o);f=u(i(p))}return{key:f,offset:0}}var h=o.childNodes[r-1],d=null,v=null;if(i(h)){var g=function(t){for(;t.lastChild&&(s(t.lastChild)&&"true"===t.lastChild.getAttribute("data-blocks")||i(t.lastChild));)t=t.lastChild;return t}(h);d=u(i(g)),v=l(g)}else d=u(c),v=l(h);return{key:d,offset:v}}function l(t){var e=t.textContent;return"\n"===e?0:e.length}t.exports=function(t,e,r,i,a,s){var l=r.nodeType===Node.TEXT_NODE,f=a.nodeType===Node.TEXT_NODE;if(l&&f)return{selectionState:o(t,u(n(r)),i,u(n(a)),s),needsRecovery:!1};var p=null,h=null,d=!0;return l?(p={key:u(n(r)),offset:i},h=c(e,a,s)):f?(h={key:u(n(a)),offset:s},p=c(e,r,i)):(p=c(e,r,i),h=c(e,a,s),r===a&&i===s&&(d=!!r.firstChild&&"BR"!==r.firstChild.nodeName)),{selectionState:o(t,p.key,p.offset,h.key,h.offset),needsRecovery:d}}},42128:(t,e,r)=>{"use strict";var n=r(99407).notEmptyKey;function i(t,e){return n(e)&&"MUTABLE"===t.__get(e).getMutability()?e:null}t.exports=function(t,e){var r;if(e.isCollapsed()){var n=e.getAnchorKey(),o=e.getAnchorOffset();return o>0?(r=t.getBlockForKey(n).getEntityAt(o-1))!==t.getBlockForKey(n).getEntityAt(o)?null:i(t.getEntityMap(),r):null}var a=e.getStartKey(),s=e.getStartOffset(),u=t.getBlockForKey(a);return r=s===u.getLength()?null:u.getEntityAt(s),i(t.getEntityMap(),r)}},94882:(t,e,r)=>{"use strict";var n=r(88687);t.exports=function(t){var e=t.getSelection();return e.isCollapsed()?null:n(t.getCurrentContent(),e)}},39506:(t,e,r)=>{"use strict";var n=r(67953);t.exports=function(t,e){if(!(t instanceof n))return null;var r=t.getNextSiblingKey();if(r)return r;var i=t.getParentKey();if(!i)return null;for(var o=e.get(i);o&&!o.getNextSiblingKey();){var a=o.getParentKey();o=a?e.get(a):null}return o?o.getNextSiblingKey():null}},96495:t=>{"use strict";t.exports=function(t){return Object.keys(t).map((function(e){return t[e]}))}},98056:(t,e,r)=>{"use strict";var n=r(6092);t.exports=function(t){var e=n(t),r=0,i=0,o=0,a=0;if(e.length){if(e.length>1&&0===e[0].width){var s=e[1];r=s.top,i=s.right,o=s.bottom,a=s.left}else{var u=e[0];r=u.top,i=u.right,o=u.bottom,a=u.left}for(var c=1;c{"use strict";var n=r(4856),i=r(73759);var o=n.isBrowser("Chrome")?function(t){for(var e=t.cloneRange(),r=[],n=t.endContainer;null!=n;n=n.parentNode){var o=n===t.commonAncestorContainer;o?e.setStart(t.startContainer,t.startOffset):e.setStart(e.endContainer,0);var a,s=Array.from(e.getClientRects());if(r.push(s),o)return r.reverse(),(a=[]).concat.apply(a,r);e.setEndBefore(n)}i(!1)}:function(t){return Array.from(t.getClientRects())};t.exports=o},64994:(t,e,r)=>{"use strict";var n=r(73759);t.exports=function(t,e){var r=[];return t.findEntityRanges((function(t){return t.getEntity()===e}),(function(t,e){r.push({start:t,end:e})})),r.length||n(!1),r}},69769:(t,e,r)=>{"use strict";var n=r(4856),i=r(73759),o=n.isBrowser("IE <= 9");t.exports=function(t){var e,r=null;return!o&&document.implementation&&document.implementation.createHTMLDocument&&((e=document.implementation.createHTMLDocument("foo")).documentElement||i(!1),e.documentElement.innerHTML=t,r=e.getElementsByTagName("body")[0]),r}},93578:(t,e,r)=>{"use strict";var n=r(84368);t.exports=function t(e){if(n(e)){var r=e,i=r.getAttribute("data-offset-key");if(i)return i;for(var o=0;o{"use strict";var n=r(73759),i=/\.textClipping$/,o={"text/plain":!0,"text/html":!0,"text/rtf":!0};t.exports=function(t,e){var a=0,s=[];t.forEach((function(u){!function(t,e){if(!r.g.FileReader||t.type&&!(t.type in o))return void e("");if(""===t.type){var a="";return i.test(t.name)&&(a=t.name.replace(i,"")),void e(a)}var s=new FileReader;s.onload=function(){var t=s.result;"string"!=typeof t&&n(!1),e(t)},s.onerror=function(){e("")},s.readAsText(t)}(u,(function(r){a++,r&&s.push(r.slice(0,5e3)),a==t.length&&e(s.join("\r"))}))}))}},94486:(t,e,r)=>{"use strict";var n=r(22146),i=r(22045);t.exports=function(t,e,r,o,a){var s=i(t.getSelection());if(!e||!o)return s;var u=n.decode(e),c=u.blockKey,l=t.getBlockTree(c),f=l&&l.getIn([u.decoratorKey,"leaves",u.leafKey]),p=n.decode(o),h=p.blockKey,d=t.getBlockTree(h),v=d&&d.getIn([p.decoratorKey,"leaves",p.leafKey]);if(!f||!v)return s;var g=f.get("start"),y=v.get("start"),m=f?g+r:null,_=v?y+a:null;if(s.getAnchorKey()===c&&s.getAnchorOffset()===m&&s.getFocusKey()===h&&s.getFocusOffset()===_)return s;var b=!1;if(c===h){var S=f.get("end"),w=v.get("end");b=y===g&&w===S?a{"use strict";var n=r(98056);t.exports=function(t){var e=t.getSelection();if(!e.rangeCount)return null;var r=e.getRangeAt(0),i=n(r),o=i.top,a=i.right,s=i.bottom,u=i.left;return 0===o&&0===a&&0===s&&0===u?null:i}},48083:t=>{"use strict";t.exports=function(t){return t&&t.ownerDocument&&t.ownerDocument.defaultView?t.ownerDocument.defaultView:window}},68642:t=>{"use strict";t.exports=function(t){return!("undefined"==typeof window||!window.__DRAFT_GKX)&&!!window.__DRAFT_GKX[t]}},54542:(t,e,r)=>{"use strict";var n=r(10329),i=r(67953),o=r(82371),a=r(40779),s=r(73759),u=r(98555),c=o.List,l=function(t,e,r,o,a,s){var u=r.first()instanceof i,l=[],f=o.size,p=r.get(a),h=o.first(),d=o.last(),v=d.getLength(),g=d.getKey(),y=u&&(!p.getChildKeys().isEmpty()||!h.getChildKeys().isEmpty());r.forEach((function(t,e){e===a?(y?l.push(t):l.push(function(t,e,r){var n=t.getText(),i=t.getCharacterList(),o=n.slice(0,e),a=i.slice(0,e),s=r.first();return t.merge({text:o+s.getText(),characterList:a.concat(s.getCharacterList()),type:o?t.getType():s.getType(),data:s.getData()})}(t,s,o)),o.slice(y?0:1,f-1).forEach((function(t){return l.push(t)})),l.push(function(t,e,r){var n=t.getText(),i=t.getCharacterList(),o=n.length,a=n.slice(e,o),s=i.slice(e,o),u=r.last();return u.merge({text:u.getText()+a,characterList:u.getCharacterList().concat(s),data:u.getData()})}(t,s,o))):l.push(t)}));var m=n.createFromArray(l);return u&&(m=function(t,e,r,n){return t.withMutations((function(e){var i=r.getKey(),o=n.getKey(),a=r.getNextSiblingKey(),s=r.getParentKey(),u=function(t,e){var r=t.getKey(),n=t,i=[];for(e.get(r)&&i.push(r);n&&n.getNextSiblingKey();){var o=n.getNextSiblingKey();if(!o)break;i.push(o),n=e.get(o)}return i}(n,t),l=u[u.length-1];if(e.get(o)?(e.setIn([i,"nextSibling"],o),e.setIn([o,"prevSibling"],i)):(e.setIn([i,"nextSibling"],n.getNextSiblingKey()),e.setIn([n.getNextSiblingKey(),"prevSibling"],i)),e.setIn([l,"nextSibling"],a),a&&e.setIn([a,"prevSibling"],l),u.forEach((function(t){return e.setIn([t,"parent"],s)})),s){var f=t.get(s).getChildKeys(),p=f.indexOf(i)+1,h=f.toArray();h.splice.apply(h,[p,0].concat(u)),e.setIn([s,"children"],c(h))}}))}(m,0,p,h)),t.merge({blockMap:m,selectionBefore:e,selectionAfter:e.merge({anchorKey:g,anchorOffset:v,focusKey:g,focusOffset:v,isBackward:!1})})};t.exports=function(t,e,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"REPLACE_WITH_NEW_DATA";e.isCollapsed()||s(!1);var o=t.getBlockMap(),c=u(r),f=e.getStartKey(),p=e.getStartOffset(),h=o.get(f);return h instanceof i&&(h.getChildKeys().isEmpty()||s(!1)),1===c.size?function(t,e,r,n,i,o){var s=arguments.length>6&&void 0!==arguments[6]?arguments[6]:"REPLACE_WITH_NEW_DATA",u=r.get(i),c=u.getText(),l=u.getCharacterList(),f=i,p=o+n.getText().length,h=null;switch(s){case"MERGE_OLD_DATA_TO_NEW_DATA":h=n.getData().merge(u.getData());break;case"REPLACE_WITH_NEW_DATA":h=n.getData()}var d=u.getType();c&&"unstyled"===d&&(d=n.getType());var v=u.merge({text:c.slice(0,o)+n.getText()+c.slice(o),characterList:a(l,n.getCharacterList(),o),type:d,data:h});return t.merge({blockMap:r.set(i,v),selectionBefore:e,selectionAfter:e.merge({anchorKey:f,anchorOffset:p,focusKey:f,focusOffset:p,isBackward:!1})})}(t,e,o,c.first(),f,p,n):l(t,e,o,c,f,p)}},40779:t=>{"use strict";t.exports=function(t,e,r){var n=t;if(r===n.count())e.forEach((function(t){n=n.push(t)}));else if(0===r)e.reverse().forEach((function(t){n=n.unshift(t)}));else{var i=n.slice(0,r),o=n.slice(r);n=i.concat(e,o).toList()}return n}},18467:(t,e,r)=>{"use strict";var n=r(82371),i=r(40779),o=r(73759),a=n.Repeat;t.exports=function(t,e,r,n){e.isCollapsed()||o(!1);var s=null;if(null!=r&&(s=r.length),null==s||0===s)return t;var u=t.getBlockMap(),c=e.getStartKey(),l=e.getStartOffset(),f=u.get(c),p=f.getText(),h=f.merge({text:p.slice(0,l)+r+p.slice(l,f.getLength()),characterList:i(f.getCharacterList(),a(n,s).toList(),l)}),d=l+s;return t.merge({blockMap:u.set(c,h),selectionAfter:e.merge({anchorOffset:d,focusOffset:d})})}},84368:t=>{"use strict";t.exports=function(t){return!(!t||!t.ownerDocument)&&t.nodeType===Node.ELEMENT_NODE}},42177:t=>{"use strict";t.exports=function(t){return"handled"===t||!0===t}},78241:(t,e,r)=>{"use strict";var n=r(84368);t.exports=function(t){return!(!t||!t.ownerDocument)&&(n(t)&&"A"===t.nodeName)}},16581:(t,e,r)=>{"use strict";var n=r(84368);t.exports=function(t){return!(!t||!t.ownerDocument)&&(n(t)&&"BR"===t.nodeName)}},20717:t=>{"use strict";t.exports=function(t){return!(!t||!t.ownerDocument)&&(t.ownerDocument.defaultView?t instanceof t.ownerDocument.defaultView.HTMLElement:t instanceof HTMLElement)}},35039:(t,e,r)=>{"use strict";var n=r(84368);t.exports=function(t){return!(!t||!t.ownerDocument)&&(n(t)&&"IMG"===t.nodeName)}},80809:t=>{"use strict";t.exports=function(t){if(!t||!("ownerDocument"in t))return!1;if("ownerDocument"in t){var e=t;if(!e.ownerDocument.defaultView)return e instanceof Node;if(e instanceof e.ownerDocument.defaultView.Node)return!0}return!1}},40258:t=>{"use strict";t.exports=function(t){var e=t.getSelection(),r=e.getAnchorKey(),n=t.getBlockTree(r),i=e.getStartOffset(),o=!1;return n.some((function(t){return i===t.get("start")?(o=!0,!0):i{"use strict";var n=r(25399);t.exports=function(t){return t.which===n.RETURN&&(t.getModifierState("Shift")||t.getModifierState("Alt")||t.getModifierState("Control"))}},49779:(t,e,r)=>{"use strict";var n=r(14289),i=r(88182),o=r(8101),a=r(53268),s=r(14730);t.exports=function(t,e){var r=s(t,(function(t){var r=t.getSelection();if(r.isCollapsed()&&0===r.getAnchorOffset())return a(t,1);var n=e.currentTarget.ownerDocument.defaultView.getSelection().getRangeAt(0);return n=i(n),o(t,null,n.endContainer,n.endOffset,n.startContainer,n.startOffset).selectionState}),"backward");return r===t.getCurrentContent()?t:n.push(t,r,"remove-range")}},51050:(t,e,r)=>{"use strict";var n=r(73932),i=r(14289),o=r(53268),a=r(14730);t.exports=function(t){var e=a(t,(function(t){var e=t.getSelection(),r=e.getStartOffset();if(0===r)return o(t,1);var i=e.getStartKey(),a=t.getCurrentContent().getBlockForKey(i).getText().slice(0,r),s=n.getBackward(a);return o(t,s.length||1)}),"backward");return e===t.getCurrentContent()?t:i.push(t,e,"remove-range")}},13767:(t,e,r)=>{"use strict";var n=r(73932),i=r(14289),o=r(19417),a=r(14730);t.exports=function(t){var e=a(t,(function(t){var e=t.getSelection(),r=e.getStartOffset(),i=e.getStartKey(),a=t.getCurrentContent().getBlockForKey(i).getText().slice(r),s=n.getForward(a);return o(t,s.length||1)}),"forward");return e===t.getCurrentContent()?t:i.push(t,e,"remove-range")}},77978:(t,e,r)=>{"use strict";var n=r(42307),i=r(14289);t.exports=function(t){var e=n.splitBlock(t.getCurrentContent(),t.getSelection());return i.push(t,e,"split-block")}},67217:(t,e,r)=>{"use strict";var n=r(14289);t.exports=function(t){var e=t.getSelection(),r=e.getEndKey(),i=t.getCurrentContent().getBlockForKey(r).getLength();return n.set(t,{selection:e.merge({anchorKey:r,anchorOffset:i,focusKey:r,focusOffset:i,isBackward:!1}),forceSelection:!0})}},8425:(t,e,r)=>{"use strict";var n=r(14289);t.exports=function(t){var e=t.getSelection(),r=e.getStartKey();return n.set(t,{selection:e.merge({anchorKey:r,anchorOffset:0,focusKey:r,focusOffset:0,isBackward:!1}),forceSelection:!0})}},62800:(t,e,r)=>{"use strict";var n=r(14289),i=r(38935),o=r(53268),a=r(14730);t.exports=function(t){var e=a(t,(function(t){var e=t.getSelection(),r=t.getCurrentContent(),n=e.getAnchorKey(),a=e.getAnchorOffset(),s=r.getBlockForKey(n).getText()[a-1];return o(t,s?i.getUTF16Length(s,0):1)}),"backward");if(e===t.getCurrentContent())return t;var r=t.getSelection();return n.push(t,e.set("selectionBefore",r),r.isCollapsed()?"backspace-character":"remove-range")}},13998:(t,e,r)=>{"use strict";var n=r(14289),i=r(38935),o=r(19417),a=r(14730);t.exports=function(t){var e=a(t,(function(t){var e=t.getSelection(),r=t.getCurrentContent(),n=e.getAnchorKey(),a=e.getAnchorOffset(),s=r.getBlockForKey(n).getText()[a];return o(t,s?i.getUTF16Length(s,0):1)}),"forward");if(e===t.getCurrentContent())return t;var r=t.getSelection();return n.push(t,e.set("selectionBefore",r),r.isCollapsed()?"delete-character":"remove-range")}},53318:(t,e,r)=>{"use strict";var n=r(42307),i=r(14289),o=r(88687);t.exports=function(t){var e=t.getSelection();if(!e.isCollapsed())return t;var r=e.getAnchorOffset();if(0===r)return t;var a,s,u=e.getAnchorKey(),c=t.getCurrentContent(),l=c.getBlockForKey(u).getLength();if(l<=1)return t;r===l?(a=e.set("anchorOffset",r-1),s=e):s=(a=e.set("focusOffset",r+1)).set("anchorOffset",r+1);var f=o(c,a),p=n.removeRange(c,a,"backward"),h=p.getSelectionAfter(),d=h.getAnchorOffset()-1,v=h.merge({anchorOffset:d,focusOffset:d}),g=n.replaceWithFragment(p,v,f),y=i.push(t,g,"insert-fragment");return i.acceptSelection(y,s)}},87051:(t,e,r)=>{"use strict";var n=r(14289);t.exports=function(t,e,r){var i=n.undo(e);if("spellcheck-change"!==e.getLastChangeType())t.preventDefault(),e.getNativelyRenderedContent()?(r(n.set(e,{nativelyRenderedContent:null})),setTimeout((function(){r(i)}),0)):r(i);else{var o=i.getCurrentContent();r(n.set(i,{nativelyRenderedContent:o}))}}},57429:(t,e,r)=>{"use strict";var n=r(82371).Map;t.exports=function(t,e,r){var i=e.getStartKey(),o=e.getEndKey(),a=t.getBlockMap(),s=a.toSeq().skipUntil((function(t,e){return e===i})).takeUntil((function(t,e){return e===o})).concat(n([[o,a.get(o)]])).map(r);return t.merge({blockMap:a.merge(s),selectionBefore:e,selectionAfter:e})}},61173:(t,e,r)=>{"use strict";var n=r(67953),i=r(39506),o=r(82371),a=r(73759),s=o.OrderedMap,u=o.List,c=function(t,e,r){if(t){var n=e.get(t);n&&e.set(t,r(n))}},l=function(t,e,r,n,i){if(!i)return t;var o="after"===n,a=e.getKey(),s=r.getKey(),l=e.getParentKey(),f=e.getNextSiblingKey(),p=e.getPrevSiblingKey(),h=r.getParentKey(),d=o?r.getNextSiblingKey():s,v=o?s:r.getPrevSiblingKey();return t.withMutations((function(t){c(l,t,(function(t){var e=t.getChildKeys();return t.merge({children:e.delete(e.indexOf(a))})})),c(p,t,(function(t){return t.merge({nextSibling:f})})),c(f,t,(function(t){return t.merge({prevSibling:p})})),c(d,t,(function(t){return t.merge({prevSibling:a})})),c(v,t,(function(t){return t.merge({nextSibling:a})})),c(h,t,(function(t){var e=t.getChildKeys(),r=e.indexOf(s),n=o?r+1:0!==r?r-1:0,i=e.toArray();return i.splice(n,0,a),t.merge({children:u(i)})})),c(a,t,(function(t){return t.merge({nextSibling:d,prevSibling:v,parent:h})}))}))};t.exports=function(t,e,r,o){"replace"===o&&a(!1);var u=r.getKey(),c=e.getKey();c===u&&a(!1);var f=t.getBlockMap(),p=e instanceof n,h=[e],d=f.delete(c);p&&(h=[],d=f.withMutations((function(t){var r=e.getNextSiblingKey(),n=i(e,t);t.toSeq().skipUntil((function(t){return t.getKey()===c})).takeWhile((function(t){var e=t.getKey(),i=e===c,o=r&&e!==r,a=!r&&t.getParentKey()&&(!n||e!==n);return!!(i||o||a)})).forEach((function(e){h.push(e),t.delete(e.getKey())}))})));var v=d.toSeq().takeUntil((function(t){return t===r})),g=d.toSeq().skipUntil((function(t){return t===r})).skip(1),y=h.map((function(t){return[t.getKey(),t]})),m=s();if("before"===o){var _=t.getBlockBefore(u);_&&_.getKey()===e.getKey()&&a(!1),m=v.concat([].concat(y,[[u,r]]),g).toOrderedMap()}else if("after"===o){var b=t.getBlockAfter(u);b&&b.getKey()===c&&a(!1),m=v.concat([[u,r]].concat(y),g).toOrderedMap()}return t.merge({blockMap:l(m,e,r,o,p),selectionBefore:t.getSelectionAfter(),selectionAfter:t.getSelectionAfter().merge({anchorKey:c,focusKey:c})})}},53268:(t,e,r)=>{"use strict";r(63620);t.exports=function(t,e){var r=t.getSelection(),n=t.getCurrentContent(),i=r.getStartKey(),o=r.getStartOffset(),a=i,s=0;if(e>o){var u=n.getKeyBefore(i);if(null==u)a=i;else a=u,s=n.getBlockForKey(u).getText().length}else s=o-e;return r.merge({focusKey:a,focusOffset:s,isBackward:!0})}},19417:(t,e,r)=>{"use strict";r(63620);t.exports=function(t,e){var r,n=t.getSelection(),i=n.getStartKey(),o=n.getStartOffset(),a=t.getCurrentContent(),s=i;return e>a.getBlockForKey(i).getText().length-o?(s=a.getKeyAfter(i),r=0):r=o+e,n.merge({focusKey:s,focusOffset:r})}},98555:(t,e,r)=>{"use strict";var n=r(67953),i=r(25027),o=r(82371).OrderedMap;t.exports=function(t){return t.first()instanceof n?function(t){var e,r={};return o(t.withMutations((function(t){t.forEach((function(n,o){var a=n.getKey(),s=n.getNextSiblingKey(),u=n.getPrevSiblingKey(),c=n.getChildKeys(),l=n.getParentKey(),f=i();if(r[a]=f,s&&(t.get(s)?t.setIn([s,"prevSibling"],f):t.setIn([a,"nextSibling"],null)),u&&(t.get(u)?t.setIn([u,"nextSibling"],f):t.setIn([a,"prevSibling"],null)),l&&t.get(l)){var p=t.get(l).getChildKeys();t.setIn([l,"children"],p.set(p.indexOf(n.getKey()),f))}else t.setIn([a,"parent"],null),e&&(t.setIn([e.getKey(),"nextSibling"],f),t.setIn([a,"prevSibling"],r[e.getKey()])),e=t.get(a);c.forEach((function(e){t.get(e)?t.setIn([e,"parent"],f):t.setIn([a,"children"],n.getChildKeys().filter((function(t){return t!==e})))}))}))})).toArray().map((function(t){return[r[t.getKey()],t.set("key",r[t.getKey()])]})))}(t):function(t){return o(t.toArray().map((function(t){var e=i();return[e,t.set("key",e)]})))}(t)}},14017:(t,e,r)=>{"use strict";var n=r(4516),i=r(29407),o=r(73759);function a(t,e,r){var a=e.getCharacterList(),s=r>0?a.get(r-1):void 0,u=r=r&&(n={start:t,end:e})})),"object"!=typeof n&&o(!1),n}(a,l,r),h=p.start,d=p.end;h{"use strict";var n=r(67953),i=r(39506),o=r(82371),a=(o.List,o.Map),s=function(t,e,r){if(t){var n=e.get(t);n&&e.set(t,r(n))}},u=function(t,e){var r=[];if(!t)return r;for(var n=e.get(t);n&&n.getParentKey();){var i=n.getParentKey();i&&r.push(i),n=i?e.get(i):null}return r},c=function(t,e,r){if(!t)return null;for(var n=r.get(t.getKey()).getNextSiblingKey();n&&!e.get(n);)n=r.get(n).getNextSiblingKey()||null;return n},l=function(t,e,r){if(!t)return null;for(var n=r.get(t.getKey()).getPrevSiblingKey();n&&!e.get(n);)n=r.get(n).getPrevSiblingKey()||null;return n},f=function(t,e,r,n){return t.withMutations((function(o){if(s(e.getKey(),o,(function(t){return t.merge({nextSibling:c(t,o,n),prevSibling:l(t,o,n)})})),s(r.getKey(),o,(function(t){return t.merge({nextSibling:c(t,o,n),prevSibling:l(t,o,n)})})),u(e.getKey(),n).forEach((function(t){return s(t,o,(function(t){return t.merge({children:t.getChildKeys().filter((function(t){return o.get(t)})),nextSibling:c(t,o,n),prevSibling:l(t,o,n)})}))})),s(e.getNextSiblingKey(),o,(function(t){return t.merge({prevSibling:e.getPrevSiblingKey()})})),s(e.getPrevSiblingKey(),o,(function(t){return t.merge({nextSibling:c(t,o,n)})})),s(r.getNextSiblingKey(),o,(function(t){return t.merge({prevSibling:l(t,o,n)})})),s(r.getPrevSiblingKey(),o,(function(t){return t.merge({nextSibling:r.getNextSiblingKey()})})),u(r.getKey(),n).forEach((function(t){s(t,o,(function(t){return t.merge({children:t.getChildKeys().filter((function(t){return o.get(t)})),nextSibling:c(t,o,n),prevSibling:l(t,o,n)})}))})),function(t,e){var r=[];if(!t)return r;for(var n=i(t,e);n&&e.get(n);){var o=e.get(n);r.push(n),n=o.getParentKey()?i(o,e):null}return r}(r,n).forEach((function(t){return s(t,o,(function(t){return t.merge({nextSibling:c(t,o,n),prevSibling:l(t,o,n)})}))})),null==t.get(e.getKey())&&null!=t.get(r.getKey())&&r.getParentKey()===e.getKey()&&null==r.getPrevSiblingKey()){var a=e.getPrevSiblingKey();s(r.getKey(),o,(function(t){return t.merge({prevSibling:a})})),s(a,o,(function(t){return t.merge({nextSibling:r.getKey()})}));var f=a?t.get(a):null,p=f?f.getParentKey():null;if(e.getChildKeys().forEach((function(t){s(t,o,(function(t){return t.merge({parent:p})}))})),null!=p){var h=t.get(p);s(p,o,(function(t){return t.merge({children:h.getChildKeys().concat(e.getChildKeys())})}))}s(e.getChildKeys().find((function(e){return null===t.get(e).getNextSiblingKey()})),o,(function(t){return t.merge({nextSibling:e.getNextSiblingKey()})}))}}))},p=function(t,e,r){if(0===e)for(;ee;)t=t.pop(),r--;else{var n=t.slice(0,e),i=t.slice(r);t=n.concat(i).toList()}return t};t.exports=function(t,e){if(e.isCollapsed())return t;var r,o=t.getBlockMap(),s=e.getStartKey(),c=e.getStartOffset(),l=e.getEndKey(),h=e.getEndOffset(),d=o.get(s),v=o.get(l),g=d instanceof n,y=[];if(g){var m=v.getChildKeys(),_=u(l,o);v.getNextSiblingKey()&&(y=y.concat(_)),m.isEmpty()||(y=y.concat(_.concat([l]))),y=y.concat(u(i(v,o),o))}r=d===v?p(d.getCharacterList(),c,h):d.getCharacterList().slice(0,c).concat(v.getCharacterList().slice(h));var b=d.merge({text:d.getText().slice(0,c)+v.getText().slice(h),characterList:r}),S=g&&0===c&&0===h&&v.getParentKey()===s&&null==v.getPrevSiblingKey()?a([[s,null]]):o.toSeq().skipUntil((function(t,e){return e===s})).takeUntil((function(t,e){return e===l})).filter((function(t,e){return-1===y.indexOf(e)})).concat(a([[l,null]])).map((function(t,e){return e===s?b:null})),w=o.merge(S).filter((function(t){return!!t}));return g&&d!==v&&(w=f(w,d,v,o)),t.merge({blockMap:w,selectionBefore:e,selectionAfter:e.merge({anchorKey:s,anchorOffset:c,focusKey:s,focusOffset:c,isBackward:!1})})}},14730:(t,e,r)=>{"use strict";var n=r(42307),i=r(68642)("draft_tree_data_support");t.exports=function(t,e,r){var o=t.getSelection(),a=t.getCurrentContent(),s=o,u=o.getAnchorKey(),c=o.getFocusKey(),l=a.getBlockForKey(u);if(i&&"forward"===r&&u!==c)return a;if(o.isCollapsed()){if("forward"===r){if(t.isSelectionAtEndOfContent())return a;if(i)if(o.getAnchorOffset()===a.getBlockForKey(u).getLength()){var f=a.getBlockForKey(l.nextSibling);if(!f||0===f.getLength())return a}}else if(t.isSelectionAtStartOfContent())return a;if((s=e(t))===o)return a}return n.removeRange(a,s,r)}},55283:t=>{"use strict";var e=new RegExp("\r","g");t.exports=function(t){return t.replace(e,"")}},45412:(t,e,r)=>{"use strict";var n=r(5880),i=r(97432),o=r(4856),a=r(67476),s=r(31003),u=r(75795),c=r(73759),l=r(84368),f=o.isBrowser("IE");function p(t,e){if(!t)return"[empty]";var r=h(t,e);return r.nodeType===Node.TEXT_NODE?r.textContent:(l(r)||c(!1),r.outerHTML)}function h(t,e){var r=void 0!==e?e(t):[];if(t.nodeType===Node.TEXT_NODE){var n=t.textContent.length;return u(t).createTextNode("[text "+n+(r.length?" | "+r.join(", "):"")+"]")}var i=t.cloneNode();1===i.nodeType&&r.length&&i.setAttribute("data-labels",r.join(", "));for(var o=t.childNodes,a=0;av(e)&&i.logSelectionStateFailure({anonymizedDom:d(e),extraParams:JSON.stringify({offset:r}),selectionState:JSON.stringify(n.toJS())});var u=e===t.focusNode;try{t.rangeCount>0&&t.extend&&t.extend(e,r)}catch(a){throw i.logSelectionStateFailure({anonymizedDom:d(e,(function(e){var r=[];return e===o&&r.push("active element"),e===t.anchorNode&&r.push("selection anchor node"),e===t.focusNode&&r.push("selection focus node"),r})),extraParams:JSON.stringify({activeElementName:o?o.nodeName:null,nodeIsFocus:e===t.focusNode,nodeWasFocus:u,selectionRangeCount:t.rangeCount,selectionAnchorNodeName:t.anchorNode?t.anchorNode.nodeName:null,selectionAnchorOffset:t.anchorOffset,selectionFocusNodeName:t.focusNode?t.focusNode.nodeName:null,selectionFocusOffset:t.focusOffset,message:a?""+a:null,offset:r},null,2),selectionState:JSON.stringify(n.toJS(),null,2)}),a}}else if(e&&t.rangeCount>0){var c=t.getRangeAt(0);c.setEnd(e,r),t.addRange(c.cloneRange())}}function y(t,e,r,o){var a=u(e).createRange();if(r>v(e)&&(i.logSelectionStateFailure({anonymizedDom:d(e),extraParams:JSON.stringify({offset:r}),selectionState:JSON.stringify(o.toJS())}),n.handleExtensionCausedError()),a.setStart(e,r),f)try{t.addRange(a)}catch(t){0}else t.addRange(a)}t.exports={setDraftEditorSelection:function(t,e,r,n,i){var o=u(e);if(a(o.documentElement,e)){var s=o.defaultView.getSelection(),c=t.getAnchorKey(),l=t.getAnchorOffset(),f=t.getFocusKey(),p=t.getFocusOffset(),h=t.getIsBackward();if(!s.extend&&h){var d=c,v=l;c=f,l=p,f=d,p=v,h=!1}var m=c===r&&n<=l&&i>=l,_=f===r&&n<=p&&i>=p;if(m&&_)return s.removeAllRanges(),y(s,e,l-n,t),void g(s,e,p-n,t);if(h){if(_&&(s.removeAllRanges(),y(s,e,p-n,t)),m){var b=s.focusNode,S=s.focusOffset;s.removeAllRanges(),y(s,e,l-n,t),g(s,b,S,t)}}else m&&(s.removeAllRanges(),y(s,e,l-n,t)),_&&g(s,e,p-n,t)}},addFocusToSelection:g}},36043:(t,e,r)=>{"use strict";var n=r(67953),i=r(25027),o=r(82371),a=r(73759),s=r(57429),u=o.List,c=o.Map,l=function(t,e,r){if(t){var n=e.get(t);n&&e.set(t,r(n))}};t.exports=function(t,e){e.isCollapsed()||a(!1);var r=e.getAnchorKey(),o=t.getBlockMap(),f=o.get(r),p=f.getText();if(!p){var h=f.getType();if("unordered-list-item"===h||"ordered-list-item"===h)return s(t,e,(function(t){return t.merge({type:"unstyled",depth:0})}))}var d=e.getAnchorOffset(),v=f.getCharacterList(),g=i(),y=f instanceof n,m=f.merge({text:p.slice(0,d),characterList:v.slice(0,d)}),_=m.merge({key:g,text:p.slice(d),characterList:v.slice(d),data:c()}),b=o.toSeq().takeUntil((function(t){return t===f})),S=o.toSeq().skipUntil((function(t){return t===f})).rest(),w=b.concat([[r,m],[g,_]],S).toOrderedMap();return y&&(f.getChildKeys().isEmpty()||a(!1),w=function(t,e,r){return t.withMutations((function(t){var n=e.getKey(),i=r.getKey();l(e.getParentKey(),t,(function(t){var e=t.getChildKeys(),r=e.indexOf(n)+1,o=e.toArray();return o.splice(r,0,i),t.merge({children:u(o)})})),l(e.getNextSiblingKey(),t,(function(t){return t.merge({prevSibling:i})})),l(n,t,(function(t){return t.merge({nextSibling:i})})),l(i,t,(function(t){return t.merge({prevSibling:n})}))}))}(w,m,_)),t.merge({blockMap:w,selectionBefore:e,selectionAfter:e.merge({anchorKey:g,anchorOffset:0,focusKey:g,focusOffset:0,isBackward:!1})})}},44300:t=>{"use strict";var e=/\r\n?|\n/g;t.exports=function(t){return t.split(e)}},76363:t=>{"use strict";t.exports=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var e=16*Math.random()|0;return("x"==t?e:3&e|8).toString(16)}))}},82371:function(t){t.exports=function(){"use strict";var t=Array.prototype.slice;function e(t,e){e&&(t.prototype=Object.create(e.prototype)),t.prototype.constructor=t}function Iterable(t){return r(t)?t:Seq(t)}function KeyedIterable(t){return n(t)?t:KeyedSeq(t)}function IndexedIterable(t){return i(t)?t:IndexedSeq(t)}function SetIterable(t){return r(t)&&!o(t)?t:SetSeq(t)}function r(t){return!(!t||!t[s])}function n(t){return!(!t||!t[u])}function i(t){return!(!t||!t[c])}function o(t){return n(t)||i(t)}function a(t){return!(!t||!t[l])}e(KeyedIterable,Iterable),e(IndexedIterable,Iterable),e(SetIterable,Iterable),Iterable.isIterable=r,Iterable.isKeyed=n,Iterable.isIndexed=i,Iterable.isAssociative=o,Iterable.isOrdered=a,Iterable.Keyed=KeyedIterable,Iterable.Indexed=IndexedIterable,Iterable.Set=SetIterable;var s="@@__IMMUTABLE_ITERABLE__@@",u="@@__IMMUTABLE_KEYED__@@",c="@@__IMMUTABLE_INDEXED__@@",l="@@__IMMUTABLE_ORDERED__@@",f="delete",p=5,h=1<>>0;if(""+r!==e||4294967295===r)return NaN;e=r}return e<0?_(t)+e:e}function S(){return!0}function w(t,e,r){return(0===t||void 0!==r&&t<=-r)&&(void 0===e||void 0!==r&&e>=r)}function x(t,e){return O(t,e,0)}function E(t,e){return O(t,e,e)}function O(t,e,r){return void 0===t?r:t<0?Math.max(0,e+t):void 0===e?t:Math.min(e,t)}var C=0,k=1,D=2,M="function"==typeof Symbol&&Symbol.iterator,I="@@iterator",A=M||I;function Iterator(t){this.next=t}function R(t,e,r,n){var i=0===t?e:1===t?r:[e,r];return n?n.value=i:n={value:i,done:!1},n}function T(){return{value:void 0,done:!0}}function z(t){return!!P(t)}function B(t){return t&&"function"==typeof t.next}function q(t){var e=P(t);return e&&e.call(t)}function P(t){var e=t&&(M&&t[M]||t[I]);if("function"==typeof e)return e}function j(t){return t&&"number"==typeof t.length}function Seq(t){return null==t?G():r(t)?t.toSeq():V(t)}function KeyedSeq(t){return null==t?G().toKeyedSeq():r(t)?n(t)?t.toSeq():t.fromEntrySeq():H(t)}function IndexedSeq(t){return null==t?G():r(t)?n(t)?t.entrySeq():t.toIndexedSeq():W(t)}function SetSeq(t){return(null==t?G():r(t)?n(t)?t.entrySeq():t:W(t)).toSetSeq()}Iterator.prototype.toString=function(){return"[Iterator]"},Iterator.KEYS=C,Iterator.VALUES=k,Iterator.ENTRIES=D,Iterator.prototype.inspect=Iterator.prototype.toSource=function(){return this.toString()},Iterator.prototype[A]=function(){return this},e(Seq,Iterable),Seq.of=function(){return Seq(arguments)},Seq.prototype.toSeq=function(){return this},Seq.prototype.toString=function(){return this.__toString("Seq {","}")},Seq.prototype.cacheResult=function(){return!this._cache&&this.__iterateUncached&&(this._cache=this.entrySeq().toArray(),this.size=this._cache.length),this},Seq.prototype.__iterate=function(t,e){return X(this,t,e,!0)},Seq.prototype.__iterator=function(t,e){return $(this,t,e,!0)},e(KeyedSeq,Seq),KeyedSeq.prototype.toKeyedSeq=function(){return this},e(IndexedSeq,Seq),IndexedSeq.of=function(){return IndexedSeq(arguments)},IndexedSeq.prototype.toIndexedSeq=function(){return this},IndexedSeq.prototype.toString=function(){return this.__toString("Seq [","]")},IndexedSeq.prototype.__iterate=function(t,e){return X(this,t,e,!1)},IndexedSeq.prototype.__iterator=function(t,e){return $(this,t,e,!1)},e(SetSeq,Seq),SetSeq.of=function(){return SetSeq(arguments)},SetSeq.prototype.toSetSeq=function(){return this},Seq.isSeq=U,Seq.Keyed=KeyedSeq,Seq.Set=SetSeq,Seq.Indexed=IndexedSeq;var L,K,N,F="@@__IMMUTABLE_SEQ__@@";function ArraySeq(t){this._array=t,this.size=t.length}function ObjectSeq(t){var e=Object.keys(t);this._object=t,this._keys=e,this.size=e.length}function IterableSeq(t){this._iterable=t,this.size=t.length||t.size}function IteratorSeq(t){this._iterator=t,this._iteratorCache=[]}function U(t){return!(!t||!t[F])}function G(){return L||(L=new ArraySeq([]))}function H(t){var e=Array.isArray(t)?new ArraySeq(t).fromEntrySeq():B(t)?new IteratorSeq(t).fromEntrySeq():z(t)?new IterableSeq(t).fromEntrySeq():"object"==typeof t?new ObjectSeq(t):void 0;if(!e)throw new TypeError("Expected Array or iterable object of [k, v] entries, or keyed object: "+t);return e}function W(t){var e=Y(t);if(!e)throw new TypeError("Expected Array or iterable object of values: "+t);return e}function V(t){var e=Y(t)||"object"==typeof t&&new ObjectSeq(t);if(!e)throw new TypeError("Expected Array or iterable object of values, or keyed object: "+t);return e}function Y(t){return j(t)?new ArraySeq(t):B(t)?new IteratorSeq(t):z(t)?new IterableSeq(t):void 0}function X(t,e,r,n){var i=t._cache;if(i){for(var o=i.length-1,a=0;a<=o;a++){var s=i[r?o-a:a];if(!1===e(s[1],n?s[0]:a,t))return a+1}return a}return t.__iterateUncached(e,r)}function $(t,e,r,n){var i=t._cache;if(i){var o=i.length-1,a=0;return new Iterator((function(){var t=i[r?o-a:a];return a++>o?T():R(e,n?t[0]:a-1,t[1])}))}return t.__iteratorUncached(e,r)}function J(t,e){return e?Z(e,t,"",{"":t}):Q(t)}function Z(t,e,r,n){return Array.isArray(e)?t.call(n,r,IndexedSeq(e).map((function(r,n){return Z(t,r,n,e)}))):tt(e)?t.call(n,r,KeyedSeq(e).map((function(r,n){return Z(t,r,n,e)}))):e}function Q(t){return Array.isArray(t)?IndexedSeq(t).map(Q).toList():tt(t)?KeyedSeq(t).map(Q).toMap():t}function tt(t){return t&&(t.constructor===Object||void 0===t.constructor)}function et(t,e){if(t===e||t!=t&&e!=e)return!0;if(!t||!e)return!1;if("function"==typeof t.valueOf&&"function"==typeof e.valueOf){if((t=t.valueOf())===(e=e.valueOf())||t!=t&&e!=e)return!0;if(!t||!e)return!1}return!("function"!=typeof t.equals||"function"!=typeof e.equals||!t.equals(e))}function rt(t,e){if(t===e)return!0;if(!r(e)||void 0!==t.size&&void 0!==e.size&&t.size!==e.size||void 0!==t.__hash&&void 0!==e.__hash&&t.__hash!==e.__hash||n(t)!==n(e)||i(t)!==i(e)||a(t)!==a(e))return!1;if(0===t.size&&0===e.size)return!0;var s=!o(t);if(a(t)){var u=t.entries();return e.every((function(t,e){var r=u.next().value;return r&&et(r[1],t)&&(s||et(r[0],e))}))&&u.next().done}var c=!1;if(void 0===t.size)if(void 0===e.size)"function"==typeof t.cacheResult&&t.cacheResult();else{c=!0;var l=t;t=e,e=l}var f=!0,p=e.__iterate((function(e,r){if(s?!t.has(e):c?!et(e,t.get(r,v)):!et(t.get(r,v),e))return f=!1,!1}));return f&&t.size===p}function Repeat(t,e){if(!(this instanceof Repeat))return new Repeat(t,e);if(this._value=t,this.size=void 0===e?1/0:Math.max(0,e),0===this.size){if(K)return K;K=this}}function nt(t,e){if(!t)throw new Error(e)}function Range(t,e,r){if(!(this instanceof Range))return new Range(t,e,r);if(nt(0!==r,"Cannot step a Range by 0"),t=t||0,void 0===e&&(e=1/0),r=void 0===r?1:Math.abs(r),en?T():R(t,i,r[e?n-i++:i++])}))},e(ObjectSeq,KeyedSeq),ObjectSeq.prototype.get=function(t,e){return void 0===e||this.has(t)?this._object[t]:e},ObjectSeq.prototype.has=function(t){return this._object.hasOwnProperty(t)},ObjectSeq.prototype.__iterate=function(t,e){for(var r=this._object,n=this._keys,i=n.length-1,o=0;o<=i;o++){var a=n[e?i-o:o];if(!1===t(r[a],a,this))return o+1}return o},ObjectSeq.prototype.__iterator=function(t,e){var r=this._object,n=this._keys,i=n.length-1,o=0;return new Iterator((function(){var a=n[e?i-o:o];return o++>i?T():R(t,a,r[a])}))},ObjectSeq.prototype[l]=!0,e(IterableSeq,IndexedSeq),IterableSeq.prototype.__iterateUncached=function(t,e){if(e)return this.cacheResult().__iterate(t,e);var r=q(this._iterable),n=0;if(B(r))for(var i;!(i=r.next()).done&&!1!==t(i.value,n++,this););return n},IterableSeq.prototype.__iteratorUncached=function(t,e){if(e)return this.cacheResult().__iterator(t,e);var r=q(this._iterable);if(!B(r))return new Iterator(T);var n=0;return new Iterator((function(){var e=r.next();return e.done?e:R(t,n++,e.value)}))},e(IteratorSeq,IndexedSeq),IteratorSeq.prototype.__iterateUncached=function(t,e){if(e)return this.cacheResult().__iterate(t,e);for(var r,n=this._iterator,i=this._iteratorCache,o=0;o=n.length){var e=r.next();if(e.done)return e;n[i]=e.value}return R(t,i,n[i++])}))},e(Repeat,IndexedSeq),Repeat.prototype.toString=function(){return 0===this.size?"Repeat []":"Repeat [ "+this._value+" "+this.size+" times ]"},Repeat.prototype.get=function(t,e){return this.has(t)?this._value:e},Repeat.prototype.includes=function(t){return et(this._value,t)},Repeat.prototype.slice=function(t,e){var r=this.size;return w(t,e,r)?this:new Repeat(this._value,E(e,r)-x(t,r))},Repeat.prototype.reverse=function(){return this},Repeat.prototype.indexOf=function(t){return et(this._value,t)?0:-1},Repeat.prototype.lastIndexOf=function(t){return et(this._value,t)?this.size:-1},Repeat.prototype.__iterate=function(t,e){for(var r=0;r1?" by "+this._step:"")+" ]"},Range.prototype.get=function(t,e){return this.has(t)?this._start+b(this,t)*this._step:e},Range.prototype.includes=function(t){var e=(t-this._start)/this._step;return e>=0&&e=0&&rr?T():R(t,o++,a)}))},Range.prototype.equals=function(t){return t instanceof Range?this._start===t._start&&this._end===t._end&&this._step===t._step:rt(this,t)},e(Collection,Iterable),e(KeyedCollection,Collection),e(IndexedCollection,Collection),e(SetCollection,Collection),Collection.Keyed=KeyedCollection,Collection.Indexed=IndexedCollection,Collection.Set=SetCollection;var it="function"==typeof Math.imul&&-2===Math.imul(4294967295,2)?Math.imul:function(t,e){var r=65535&(t|=0),n=65535&(e|=0);return r*n+((t>>>16)*n+r*(e>>>16)<<16>>>0)|0};function ot(t){return t>>>1&1073741824|3221225471&t}function at(t){if(!1===t||null==t)return 0;if("function"==typeof t.valueOf&&(!1===(t=t.valueOf())||null==t))return 0;if(!0===t)return 1;var e=typeof t;if("number"===e){var r=0|t;for(r!==t&&(r^=4294967295*t);t>4294967295;)r^=t/=4294967295;return ot(r)}if("string"===e)return t.length>yt?st(t):ut(t);if("function"==typeof t.hashCode)return t.hashCode();if("object"===e)return ct(t);if("function"==typeof t.toString)return ut(t.toString());throw new Error("Value type "+e+" cannot be hashed.")}function st(t){var e=bt[t];return void 0===e&&(e=ut(t),_t===mt&&(_t=0,bt={}),_t++,bt[t]=e),e}function ut(t){for(var e=0,r=0;r0)switch(t.nodeType){case 1:return t.uniqueID;case 9:return t.documentElement&&t.documentElement.uniqueID}}var ht,dt="function"==typeof WeakMap;dt&&(ht=new WeakMap);var vt=0,gt="__immutablehash__";"function"==typeof Symbol&&(gt=Symbol(gt));var yt=16,mt=255,_t=0,bt={};function St(t){nt(t!==1/0,"Cannot perform this action with an infinite size.")}function Map(t){return null==t?Mt():wt(t)&&!a(t)?t:Mt().withMutations((function(e){var r=KeyedIterable(t);St(r.size),r.forEach((function(t,r){return e.set(r,t)}))}))}function wt(t){return!(!t||!t[Et])}e(Map,KeyedCollection),Map.prototype.toString=function(){return this.__toString("Map {","}")},Map.prototype.get=function(t,e){return this._root?this._root.get(0,void 0,t,e):e},Map.prototype.set=function(t,e){return It(this,t,e)},Map.prototype.setIn=function(t,e){return this.updateIn(t,v,(function(){return e}))},Map.prototype.remove=function(t){return It(this,t,v)},Map.prototype.deleteIn=function(t){return this.updateIn(t,(function(){return v}))},Map.prototype.update=function(t,e,r){return 1===arguments.length?t(this):this.updateIn([t],e,r)},Map.prototype.updateIn=function(t,e,r){r||(r=e,e=void 0);var n=Nt(this,Le(t),e,r);return n===v?void 0:n},Map.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):Mt()},Map.prototype.merge=function(){return Pt(this,void 0,arguments)},Map.prototype.mergeWith=function(e){return Pt(this,e,t.call(arguments,1))},Map.prototype.mergeIn=function(e){var r=t.call(arguments,1);return this.updateIn(e,Mt(),(function(t){return"function"==typeof t.merge?t.merge.apply(t,r):r[r.length-1]}))},Map.prototype.mergeDeep=function(){return Pt(this,jt,arguments)},Map.prototype.mergeDeepWith=function(e){var r=t.call(arguments,1);return Pt(this,Lt(e),r)},Map.prototype.mergeDeepIn=function(e){var r=t.call(arguments,1);return this.updateIn(e,Mt(),(function(t){return"function"==typeof t.mergeDeep?t.mergeDeep.apply(t,r):r[r.length-1]}))},Map.prototype.sort=function(t){return OrderedMap(De(this,t))},Map.prototype.sortBy=function(t,e){return OrderedMap(De(this,e,t))},Map.prototype.withMutations=function(t){var e=this.asMutable();return t(e),e.wasAltered()?e.__ensureOwner(this.__ownerID):this},Map.prototype.asMutable=function(){return this.__ownerID?this:this.__ensureOwner(new OwnerID)},Map.prototype.asImmutable=function(){return this.__ensureOwner()},Map.prototype.wasAltered=function(){return this.__altered},Map.prototype.__iterator=function(t,e){return new MapIterator(this,t,e)},Map.prototype.__iterate=function(t,e){var r=this,n=0;return this._root&&this._root.iterate((function(e){return n++,t(e[1],e[0],r)}),e),n},Map.prototype.__ensureOwner=function(t){return t===this.__ownerID?this:t?Dt(this.size,this._root,t,this.__hash):(this.__ownerID=t,this.__altered=!1,this)},Map.isMap=wt;var xt,Et="@@__IMMUTABLE_MAP__@@",Ot=Map.prototype;function ArrayMapNode(t,e){this.ownerID=t,this.entries=e}function BitmapIndexedNode(t,e,r){this.ownerID=t,this.bitmap=e,this.nodes=r}function HashArrayMapNode(t,e,r){this.ownerID=t,this.count=e,this.nodes=r}function HashCollisionNode(t,e,r){this.ownerID=t,this.keyHash=e,this.entries=r}function ValueNode(t,e,r){this.ownerID=t,this.keyHash=e,this.entry=r}function MapIterator(t,e,r){this._type=e,this._reverse=r,this._stack=t._root&&kt(t._root)}function Ct(t,e){return R(t,e[0],e[1])}function kt(t,e){return{node:t,index:0,__prev:e}}function Dt(t,e,r,n){var i=Object.create(Ot);return i.size=t,i._root=e,i.__ownerID=r,i.__hash=n,i.__altered=!1,i}function Mt(){return xt||(xt=Dt(0))}function It(t,e,r){var n,i;if(t._root){var o=MakeRef(g),a=MakeRef(y);if(n=At(t._root,t.__ownerID,0,void 0,e,r,o,a),!a.value)return t;i=t.size+(o.value?r===v?-1:1:0)}else{if(r===v)return t;i=1,n=new ArrayMapNode(t.__ownerID,[[e,r]])}return t.__ownerID?(t.size=i,t._root=n,t.__hash=void 0,t.__altered=!0,t):n?Dt(i,n):Mt()}function At(t,e,r,n,i,o,a,s){return t?t.update(e,r,n,i,o,a,s):o===v?t:(SetRef(s),SetRef(a),new ValueNode(e,n,[i,o]))}function Rt(t){return t.constructor===ValueNode||t.constructor===HashCollisionNode}function Tt(t,e,r,n,i){if(t.keyHash===n)return new HashCollisionNode(e,n,[t.entry,i]);var o,a=(0===r?t.keyHash:t.keyHash>>>r)&d,s=(0===r?n:n>>>r)&d;return new BitmapIndexedNode(e,1<>>=1)a[s]=1&r?e[o++]:void 0;return a[n]=i,new HashArrayMapNode(t,o+1,a)}function Pt(t,e,n){for(var i=[],o=0;o>1&1431655765))+(t>>2&858993459))+(t>>4)&252645135,t+=t>>8,127&(t+=t>>16)}function Ut(t,e,r,n){var i=n?t:m(t);return i[e]=r,i}function Gt(t,e,r,n){var i=t.length+1;if(n&&e+1===i)return t[e]=r,t;for(var o=new Array(i),a=0,s=0;s=Wt)return zt(t,u,n,i);var p=t&&t===this.ownerID,h=p?u:m(u);return f?s?c===l-1?h.pop():h[c]=h.pop():h[c]=[n,i]:h.push([n,i]),p?(this.entries=h,this):new ArrayMapNode(t,h)}},BitmapIndexedNode.prototype.get=function(t,e,r,n){void 0===e&&(e=at(r));var i=1<<((0===t?e:e>>>t)&d),o=this.bitmap;return 0==(o&i)?n:this.nodes[Ft(o&i-1)].get(t+p,e,r,n)},BitmapIndexedNode.prototype.update=function(t,e,r,n,i,o,a){void 0===r&&(r=at(n));var s=(0===e?r:r>>>e)&d,u=1<=Vt)return qt(t,h,c,s,y);if(l&&!y&&2===h.length&&Rt(h[1^f]))return h[1^f];if(l&&y&&1===h.length&&Rt(y))return y;var m=t&&t===this.ownerID,_=l?y?c:c^u:c|u,b=l?y?Ut(h,f,y,m):Ht(h,f,m):Gt(h,f,y,m);return m?(this.bitmap=_,this.nodes=b,this):new BitmapIndexedNode(t,_,b)},HashArrayMapNode.prototype.get=function(t,e,r,n){void 0===e&&(e=at(r));var i=(0===t?e:e>>>t)&d,o=this.nodes[i];return o?o.get(t+p,e,r,n):n},HashArrayMapNode.prototype.update=function(t,e,r,n,i,o,a){void 0===r&&(r=at(n));var s=(0===e?r:r>>>e)&d,u=i===v,c=this.nodes,l=c[s];if(u&&!l)return this;var f=At(l,t,e+p,r,n,i,o,a);if(f===l)return this;var h=this.count;if(l){if(!f&&--h0&&n=0&&t>>e&d;if(n>=this.array.length)return new VNode([],t);var i,o=0===n;if(e>0){var a=this.array[n];if((i=a&&a.removeBefore(t,e-p,r))===a&&o)return this}if(o&&!i)return this;var s=ae(this,t);if(!o)for(var u=0;u>>e&d;if(i>=this.array.length)return this;if(e>0){var o=this.array[i];if((n=o&&o.removeAfter(t,e-p,r))===o&&i===this.array.length-1)return this}var a=ae(this,t);return a.array.splice(i+1),n&&(a.array[i]=n),a};var Zt,Qt,te={};function ee(t,e){var r=t._origin,n=t._capacity,i=le(n),o=t._tail;return a(t._root,t._level,0);function a(t,e,r){return 0===e?s(t,r):u(t,e,r)}function s(t,a){var s=a===i?o&&o.array:t&&t.array,u=a>r?0:r-a,c=n-a;return c>h&&(c=h),function(){if(u===c)return te;var t=e?--c:u++;return s&&s[t]}}function u(t,i,o){var s,u=t&&t.array,c=o>r?0:r-o>>i,l=1+(n-o>>i);return l>h&&(l=h),function(){for(;;){if(s){var t=s();if(t!==te)return t;s=null}if(c===l)return te;var r=e?--l:c++;s=a(u&&u[r],i-p,o+(r<=t.size||e<0)return t.withMutations((function(t){e<0?ue(t,e).set(0,r):ue(t,0,e+1).set(e,r)}));e+=t._origin;var n=t._tail,i=t._root,o=MakeRef(y);return e>=le(t._capacity)?n=oe(n,t.__ownerID,0,e,r,o):i=oe(i,t.__ownerID,t._level,e,r,o),o.value?t.__ownerID?(t._root=i,t._tail=n,t.__hash=void 0,t.__altered=!0,t):re(t._origin,t._capacity,t._level,i,n):t}function oe(t,e,r,n,i,o){var a,s=n>>>r&d,u=t&&s0){var c=t&&t.array[s],l=oe(c,e,r-p,n,i,o);return l===c?t:((a=ae(t,e)).array[s]=l,a)}return u&&t.array[s]===i?t:(SetRef(o),a=ae(t,e),void 0===i&&s===a.array.length-1?a.array.pop():a.array[s]=i,a)}function ae(t,e){return e&&t&&e===t.ownerID?t:new VNode(t?t.array.slice():[],e)}function se(t,e){if(e>=le(t._capacity))return t._tail;if(e<1<0;)r=r.array[e>>>n&d],n-=p;return r}}function ue(t,e,r){void 0!==e&&(e|=0),void 0!==r&&(r|=0);var n=t.__ownerID||new OwnerID,i=t._origin,o=t._capacity,a=i+e,s=void 0===r?o:r<0?o+r:i+r;if(a===i&&s===o)return t;if(a>=s)return t.clear();for(var u=t._level,c=t._root,l=0;a+l<0;)c=new VNode(c&&c.array.length?[void 0,c]:[],n),l+=1<<(u+=p);l&&(a+=l,i+=l,s+=l,o+=l);for(var f=le(o),h=le(s);h>=1<f?new VNode([],n):v;if(v&&h>f&&ap;m-=p){var _=f>>>m&d;y=y.array[_]=ae(y.array[_],n)}y.array[f>>>p&d]=v}if(s=h)a-=h,s-=h,u=p,c=null,g=g&&g.removeBefore(n,0,a);else if(a>i||h>>u&d;if(b!==h>>>u&d)break;b&&(l+=(1<i&&(c=c.removeBefore(n,u,a-l)),c&&ho&&(o=u.size),r(s)||(u=u.map((function(t){return J(t)}))),i.push(u)}return o>t.size&&(t=t.setSize(o)),Kt(t,e,i)}function le(t){return t>>p<=h&&a.size>=2*o.size?(n=(i=a.filter((function(t,e){return void 0!==t&&s!==e}))).toKeyedSeq().map((function(t){return t[0]})).flip().toMap(),t.__ownerID&&(n.__ownerID=i.__ownerID=t.__ownerID)):(n=o.remove(e),i=s===a.size-1?a.pop():a.set(s,void 0))}else if(u){if(r===a.get(s)[1])return t;n=o,i=a.set(s,[e,r])}else n=o.set(e,a.size),i=a.set(a.size,[e,r]);return t.__ownerID?(t.size=n.size,t._map=n,t._list=i,t.__hash=void 0,t):pe(n,i)}function ToKeyedSequence(t,e){this._iter=t,this._useKeys=e,this.size=t.size}function ToIndexedSequence(t){this._iter=t,this.size=t.size}function ToSetSequence(t){this._iter=t,this.size=t.size}function FromEntriesSequence(t){this._iter=t,this.size=t.size}function ve(t){var e=qe(t);return e._iter=t,e.size=t.size,e.flip=function(){return t},e.reverse=function(){var e=t.reverse.apply(this);return e.flip=function(){return t.reverse()},e},e.has=function(e){return t.includes(e)},e.includes=function(e){return t.has(e)},e.cacheResult=Pe,e.__iterateUncached=function(e,r){var n=this;return t.__iterate((function(t,r){return!1!==e(r,t,n)}),r)},e.__iteratorUncached=function(e,r){if(e===D){var n=t.__iterator(e,r);return new Iterator((function(){var t=n.next();if(!t.done){var e=t.value[0];t.value[0]=t.value[1],t.value[1]=e}return t}))}return t.__iterator(e===k?C:k,r)},e}function ge(t,e,r){var n=qe(t);return n.size=t.size,n.has=function(e){return t.has(e)},n.get=function(n,i){var o=t.get(n,v);return o===v?i:e.call(r,o,n,t)},n.__iterateUncached=function(n,i){var o=this;return t.__iterate((function(t,i,a){return!1!==n(e.call(r,t,i,a),i,o)}),i)},n.__iteratorUncached=function(n,i){var o=t.__iterator(D,i);return new Iterator((function(){var i=o.next();if(i.done)return i;var a=i.value,s=a[0];return R(n,s,e.call(r,a[1],s,t),i)}))},n}function ye(t,e){var r=qe(t);return r._iter=t,r.size=t.size,r.reverse=function(){return t},t.flip&&(r.flip=function(){var e=ve(t);return e.reverse=function(){return t.flip()},e}),r.get=function(r,n){return t.get(e?r:-1-r,n)},r.has=function(r){return t.has(e?r:-1-r)},r.includes=function(e){return t.includes(e)},r.cacheResult=Pe,r.__iterate=function(e,r){var n=this;return t.__iterate((function(t,r){return e(t,r,n)}),!r)},r.__iterator=function(e,r){return t.__iterator(e,!r)},r}function me(t,e,r,n){var i=qe(t);return n&&(i.has=function(n){var i=t.get(n,v);return i!==v&&!!e.call(r,i,n,t)},i.get=function(n,i){var o=t.get(n,v);return o!==v&&e.call(r,o,n,t)?o:i}),i.__iterateUncached=function(i,o){var a=this,s=0;return t.__iterate((function(t,o,u){if(e.call(r,t,o,u))return s++,i(t,n?o:s-1,a)}),o),s},i.__iteratorUncached=function(i,o){var a=t.__iterator(D,o),s=0;return new Iterator((function(){for(;;){var o=a.next();if(o.done)return o;var u=o.value,c=u[0],l=u[1];if(e.call(r,l,c,t))return R(i,n?c:s++,l,o)}}))},i}function _e(t,e,r){var n=Map().asMutable();return t.__iterate((function(i,o){n.update(e.call(r,i,o,t),0,(function(t){return t+1}))})),n.asImmutable()}function be(t,e,r){var i=n(t),o=(a(t)?OrderedMap():Map()).asMutable();t.__iterate((function(n,a){o.update(e.call(r,n,a,t),(function(t){return(t=t||[]).push(i?[a,n]:n),t}))}));var s=Be(t);return o.map((function(e){return Re(t,s(e))}))}function Se(t,e,r,n){var i=t.size;if(void 0!==e&&(e|=0),void 0!==r&&(r|=0),w(e,r,i))return t;var o=x(e,i),a=E(r,i);if(o!=o||a!=a)return Se(t.toSeq().cacheResult(),e,r,n);var s,u=a-o;u==u&&(s=u<0?0:u);var c=qe(t);return c.size=0===s?s:t.size&&s||void 0,!n&&U(t)&&s>=0&&(c.get=function(e,r){return(e=b(this,e))>=0&&es)return T();var t=i.next();return n||e===k?t:R(e,u-1,e===C?void 0:t.value[1],t)}))},c}function we(t,e,r){var n=qe(t);return n.__iterateUncached=function(n,i){var o=this;if(i)return this.cacheResult().__iterate(n,i);var a=0;return t.__iterate((function(t,i,s){return e.call(r,t,i,s)&&++a&&n(t,i,o)})),a},n.__iteratorUncached=function(n,i){var o=this;if(i)return this.cacheResult().__iterator(n,i);var a=t.__iterator(D,i),s=!0;return new Iterator((function(){if(!s)return T();var t=a.next();if(t.done)return t;var i=t.value,u=i[0],c=i[1];return e.call(r,c,u,o)?n===D?t:R(n,u,c,t):(s=!1,T())}))},n}function xe(t,e,r,n){var i=qe(t);return i.__iterateUncached=function(i,o){var a=this;if(o)return this.cacheResult().__iterate(i,o);var s=!0,u=0;return t.__iterate((function(t,o,c){if(!s||!(s=e.call(r,t,o,c)))return u++,i(t,n?o:u-1,a)})),u},i.__iteratorUncached=function(i,o){var a=this;if(o)return this.cacheResult().__iterator(i,o);var s=t.__iterator(D,o),u=!0,c=0;return new Iterator((function(){var t,o,l;do{if((t=s.next()).done)return n||i===k?t:R(i,c++,i===C?void 0:t.value[1],t);var f=t.value;o=f[0],l=f[1],u&&(u=e.call(r,l,o,a))}while(u);return i===D?t:R(i,o,l,t)}))},i}function Ee(t,e){var o=n(t),a=[t].concat(e).map((function(t){return r(t)?o&&(t=KeyedIterable(t)):t=o?H(t):W(Array.isArray(t)?t:[t]),t})).filter((function(t){return 0!==t.size}));if(0===a.length)return t;if(1===a.length){var s=a[0];if(s===t||o&&n(s)||i(t)&&i(s))return s}var u=new ArraySeq(a);return o?u=u.toKeyedSeq():i(t)||(u=u.toSetSeq()),(u=u.flatten(!0)).size=a.reduce((function(t,e){if(void 0!==t){var r=e.size;if(void 0!==r)return t+r}}),0),u}function Oe(t,e,n){var i=qe(t);return i.__iterateUncached=function(i,o){var a=0,s=!1;function u(t,c){var l=this;t.__iterate((function(t,o){return(!e||c0}function Ae(t,e,r){var n=qe(t);return n.size=new ArraySeq(r).map((function(t){return t.size})).min(),n.__iterate=function(t,e){for(var r,n=this.__iterator(k,e),i=0;!(r=n.next()).done&&!1!==t(r.value,i++,this););return i},n.__iteratorUncached=function(t,n){var i=r.map((function(t){return t=Iterable(t),q(n?t.reverse():t)})),o=0,a=!1;return new Iterator((function(){var r;return a||(r=i.map((function(t){return t.next()})),a=r.some((function(t){return t.done}))),a?T():R(t,o++,e.apply(null,r.map((function(t){return t.value}))))}))},n}function Re(t,e){return U(t)?e:t.constructor(e)}function Te(t){if(t!==Object(t))throw new TypeError("Expected [K, V] tuple: "+t)}function ze(t){return St(t.size),_(t)}function Be(t){return n(t)?KeyedIterable:i(t)?IndexedIterable:SetIterable}function qe(t){return Object.create((n(t)?KeyedSeq:i(t)?IndexedSeq:SetSeq).prototype)}function Pe(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):Seq.prototype.cacheResult.call(this)}function je(t,e){return t>e?1:t=0;r--)e={value:arguments[r],next:e};return this.__ownerID?(this.size=t,this._head=e,this.__hash=void 0,this.__altered=!0,this):sr(t,e)},Stack.prototype.pushAll=function(t){if(0===(t=IndexedIterable(t)).size)return this;St(t.size);var e=this.size,r=this._head;return t.reverse().forEach((function(t){e++,r={value:t,next:r}})),this.__ownerID?(this.size=e,this._head=r,this.__hash=void 0,this.__altered=!0,this):sr(e,r)},Stack.prototype.pop=function(){return this.slice(1)},Stack.prototype.unshift=function(){return this.push.apply(this,arguments)},Stack.prototype.unshiftAll=function(t){return this.pushAll(t)},Stack.prototype.shift=function(){return this.pop.apply(this,arguments)},Stack.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):ur()},Stack.prototype.slice=function(t,e){if(w(t,e,this.size))return this;var r=x(t,this.size);if(E(e,this.size)!==this.size)return IndexedCollection.prototype.slice.call(this,t,e);for(var n=this.size-r,i=this._head;r--;)i=i.next;return this.__ownerID?(this.size=n,this._head=i,this.__hash=void 0,this.__altered=!0,this):sr(n,i)},Stack.prototype.__ensureOwner=function(t){return t===this.__ownerID?this:t?sr(this.size,this._head,t,this.__hash):(this.__ownerID=t,this.__altered=!1,this)},Stack.prototype.__iterate=function(t,e){if(e)return this.reverse().__iterate(t);for(var r=0,n=this._head;n&&!1!==t(n.value,r++,this);)n=n.next;return r},Stack.prototype.__iterator=function(t,e){if(e)return this.reverse().__iterator(t);var r=0,n=this._head;return new Iterator((function(){if(n){var e=n.value;return n=n.next,R(t,r++,e)}return T()}))},Stack.isStack=nr;var ir,or="@@__IMMUTABLE_STACK__@@",ar=Stack.prototype;function sr(t,e,r,n){var i=Object.create(ar);return i.size=t,i._head=e,i.__ownerID=r,i.__hash=n,i.__altered=!1,i}function ur(){return ir||(ir=sr(0))}function cr(t,e){var r=function(r){t.prototype[r]=e[r]};return Object.keys(e).forEach(r),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(e).forEach(r),t}ar[or]=!0,ar.withMutations=Ot.withMutations,ar.asMutable=Ot.asMutable,ar.asImmutable=Ot.asImmutable,ar.wasAltered=Ot.wasAltered,Iterable.Iterator=Iterator,cr(Iterable,{toArray:function(){St(this.size);var t=new Array(this.size||0);return this.valueSeq().__iterate((function(e,r){t[r]=e})),t},toIndexedSeq:function(){return new ToIndexedSequence(this)},toJS:function(){return this.toSeq().map((function(t){return t&&"function"==typeof t.toJS?t.toJS():t})).__toJS()},toJSON:function(){return this.toSeq().map((function(t){return t&&"function"==typeof t.toJSON?t.toJSON():t})).__toJS()},toKeyedSeq:function(){return new ToKeyedSequence(this,!0)},toMap:function(){return Map(this.toKeyedSeq())},toObject:function(){St(this.size);var t={};return this.__iterate((function(e,r){t[r]=e})),t},toOrderedMap:function(){return OrderedMap(this.toKeyedSeq())},toOrderedSet:function(){return OrderedSet(n(this)?this.valueSeq():this)},toSet:function(){return Set(n(this)?this.valueSeq():this)},toSetSeq:function(){return new ToSetSequence(this)},toSeq:function(){return i(this)?this.toIndexedSeq():n(this)?this.toKeyedSeq():this.toSetSeq()},toStack:function(){return Stack(n(this)?this.valueSeq():this)},toList:function(){return List(n(this)?this.valueSeq():this)},toString:function(){return"[Iterable]"},__toString:function(t,e){return 0===this.size?t+e:t+" "+this.toSeq().map(this.__toStringMapper).join(", ")+" "+e},concat:function(){return Re(this,Ee(this,t.call(arguments,0)))},includes:function(t){return this.some((function(e){return et(e,t)}))},entries:function(){return this.__iterator(D)},every:function(t,e){St(this.size);var r=!0;return this.__iterate((function(n,i,o){if(!t.call(e,n,i,o))return r=!1,!1})),r},filter:function(t,e){return Re(this,me(this,t,e,!0))},find:function(t,e,r){var n=this.findEntry(t,e);return n?n[1]:r},findEntry:function(t,e){var r;return this.__iterate((function(n,i,o){if(t.call(e,n,i,o))return r=[i,n],!1})),r},findLastEntry:function(t,e){return this.toSeq().reverse().findEntry(t,e)},forEach:function(t,e){return St(this.size),this.__iterate(e?t.bind(e):t)},join:function(t){St(this.size),t=void 0!==t?""+t:",";var e="",r=!0;return this.__iterate((function(n){r?r=!1:e+=t,e+=null!=n?n.toString():""})),e},keys:function(){return this.__iterator(C)},map:function(t,e){return Re(this,ge(this,t,e))},reduce:function(t,e,r){var n,i;return St(this.size),arguments.length<2?i=!0:n=e,this.__iterate((function(e,o,a){i?(i=!1,n=e):n=t.call(r,n,e,o,a)})),n},reduceRight:function(t,e,r){var n=this.toKeyedSeq().reverse();return n.reduce.apply(n,arguments)},reverse:function(){return Re(this,ye(this,!0))},slice:function(t,e){return Re(this,Se(this,t,e,!0))},some:function(t,e){return!this.every(dr(t),e)},sort:function(t){return Re(this,De(this,t))},values:function(){return this.__iterator(k)},butLast:function(){return this.slice(0,-1)},isEmpty:function(){return void 0!==this.size?0===this.size:!this.some((function(){return!0}))},count:function(t,e){return _(t?this.toSeq().filter(t,e):this)},countBy:function(t,e){return _e(this,t,e)},equals:function(t){return rt(this,t)},entrySeq:function(){var t=this;if(t._cache)return new ArraySeq(t._cache);var e=t.toSeq().map(hr).toIndexedSeq();return e.fromEntrySeq=function(){return t.toSeq()},e},filterNot:function(t,e){return this.filter(dr(t),e)},findLast:function(t,e,r){return this.toKeyedSeq().reverse().find(t,e,r)},first:function(){return this.find(S)},flatMap:function(t,e){return Re(this,Ce(this,t,e))},flatten:function(t){return Re(this,Oe(this,t,!0))},fromEntrySeq:function(){return new FromEntriesSequence(this)},get:function(t,e){return this.find((function(e,r){return et(r,t)}),void 0,e)},getIn:function(t,e){for(var r,n=this,i=Le(t);!(r=i.next()).done;){var o=r.value;if((n=n&&n.get?n.get(o,v):v)===v)return e}return n},groupBy:function(t,e){return be(this,t,e)},has:function(t){return this.get(t,v)!==v},hasIn:function(t){return this.getIn(t,v)!==v},isSubset:function(t){return t="function"==typeof t.includes?t:Iterable(t),this.every((function(e){return t.includes(e)}))},isSuperset:function(t){return(t="function"==typeof t.isSubset?t:Iterable(t)).isSubset(this)},keySeq:function(){return this.toSeq().map(pr).toIndexedSeq()},last:function(){return this.toSeq().reverse().first()},max:function(t){return Me(this,t)},maxBy:function(t,e){return Me(this,e,t)},min:function(t){return Me(this,t?vr(t):mr)},minBy:function(t,e){return Me(this,e?vr(e):mr,t)},rest:function(){return this.slice(1)},skip:function(t){return this.slice(Math.max(0,t))},skipLast:function(t){return Re(this,this.toSeq().reverse().skip(t).reverse())},skipWhile:function(t,e){return Re(this,xe(this,t,e,!0))},skipUntil:function(t,e){return this.skipWhile(dr(t),e)},sortBy:function(t,e){return Re(this,De(this,e,t))},take:function(t){return this.slice(0,Math.max(0,t))},takeLast:function(t){return Re(this,this.toSeq().reverse().take(t).reverse())},takeWhile:function(t,e){return Re(this,we(this,t,e))},takeUntil:function(t,e){return this.takeWhile(dr(t),e)},valueSeq:function(){return this.toIndexedSeq()},hashCode:function(){return this.__hash||(this.__hash=_r(this))}});var lr=Iterable.prototype;lr[s]=!0,lr[A]=lr.values,lr.__toJS=lr.toArray,lr.__toStringMapper=gr,lr.inspect=lr.toSource=function(){return this.toString()},lr.chain=lr.flatMap,lr.contains=lr.includes,function(){try{Object.defineProperty(lr,"length",{get:function(){if(!Iterable.noLengthWarning){var t;try{throw new Error}catch(e){t=e.stack}if(-1===t.indexOf("_wrapObject"))return console&&console.warn&&console.warn("iterable.length has been deprecated, use iterable.size or iterable.count(). This warning will become a silent error in a future version. "+t),this.size}}})}catch(t){}}(),cr(KeyedIterable,{flip:function(){return Re(this,ve(this))},findKey:function(t,e){var r=this.findEntry(t,e);return r&&r[0]},findLastKey:function(t,e){return this.toSeq().reverse().findKey(t,e)},keyOf:function(t){return this.findKey((function(e){return et(e,t)}))},lastKeyOf:function(t){return this.findLastKey((function(e){return et(e,t)}))},mapEntries:function(t,e){var r=this,n=0;return Re(this,this.toSeq().map((function(i,o){return t.call(e,[o,i],n++,r)})).fromEntrySeq())},mapKeys:function(t,e){var r=this;return Re(this,this.toSeq().flip().map((function(n,i){return t.call(e,n,i,r)})).flip())}});var fr=KeyedIterable.prototype;function pr(t,e){return e}function hr(t,e){return[e,t]}function dr(t){return function(){return!t.apply(this,arguments)}}function vr(t){return function(){return-t.apply(this,arguments)}}function gr(t){return"string"==typeof t?JSON.stringify(t):t}function yr(){return m(arguments)}function mr(t,e){return te?-1:0}function _r(t){if(t.size===1/0)return 0;var e=a(t),r=n(t),i=e?1:0;return br(t.__iterate(r?e?function(t,e){i=31*i+Sr(at(t),at(e))|0}:function(t,e){i=i+Sr(at(t),at(e))|0}:e?function(t){i=31*i+at(t)|0}:function(t){i=i+at(t)|0}),i)}function br(t,e){return e=it(e,3432918353),e=it(e<<15|e>>>-15,461845907),e=it(e<<13|e>>>-13,5),e=it((e=(e+3864292196|0)^t)^e>>>16,2246822507),e=ot((e=it(e^e>>>13,3266489909))^e>>>16)}function Sr(t,e){return t^e+2654435769+(t<<6)+(t>>2)|0}return fr[u]=!0,fr[A]=lr.entries,fr.__toJS=lr.toObject,fr.__toStringMapper=function(t,e){return JSON.stringify(e)+": "+gr(t)},cr(IndexedIterable,{toKeyedSeq:function(){return new ToKeyedSequence(this,!1)},filter:function(t,e){return Re(this,me(this,t,e,!1))},findIndex:function(t,e){var r=this.findEntry(t,e);return r?r[0]:-1},indexOf:function(t){var e=this.toKeyedSeq().keyOf(t);return void 0===e?-1:e},lastIndexOf:function(t){var e=this.toKeyedSeq().reverse().keyOf(t);return void 0===e?-1:e},reverse:function(){return Re(this,ye(this,!1))},slice:function(t,e){return Re(this,Se(this,t,e,!1))},splice:function(t,e){var r=arguments.length;if(e=Math.max(0|e,0),0===r||2===r&&!e)return this;t=x(t,t<0?this.count():this.size);var n=this.slice(0,t);return Re(this,1===r?n:n.concat(m(arguments,2),this.slice(t+e)))},findLastIndex:function(t,e){var r=this.toKeyedSeq().findLastKey(t,e);return void 0===r?-1:r},first:function(){return this.get(0)},flatten:function(t){return Re(this,Oe(this,t,!1))},get:function(t,e){return(t=b(this,t))<0||this.size===1/0||void 0!==this.size&&t>this.size?e:this.find((function(e,r){return r===t}),void 0,e)},has:function(t){return(t=b(this,t))>=0&&(void 0!==this.size?this.size===1/0||t{"use strict";r.d(e,{filterEditorState:()=>S});var n=r(9041);const i="atomic",o="unstyled",a="unordered-list-item",s="ordered-list-item",u=t=>{const e=t.getBlockMap(),r=e.filter((t=>{const e=t.getText(),r=t.getEntityAt(0);return Boolean(r)&&["📷"," ","📷 "].includes(e)})).map((t=>t.set("type",i)));return 0!==r.size?t.merge({blockMap:e.merge(r)}):t},c=t=>{let e=t.getBlockMap();const r=e.filter((t=>t.getType()===i&&(" "!==t.getText()||0!==t.getInlineStyleAt(0).size))).map((t=>{const e=t.getCharacterList().slice(0,1).map((t=>{let e=t;return t.getStyle().forEach((t=>{e=n.CharacterMetadata.removeStyle(e,t)})),e}));return t.merge({text:" ",characterList:e})}));return 0!==r.size&&(e=e.merge(r)),t.merge({blockMap:e})},l=(t,e)=>{const r=e.getBlockMap(),n=r.filter((r=>{if(r.getType()!==i)return!0;const n=r.getEntityAt(0);let o;if(n){const r=e.getEntity(n).getType();o=t.some((t=>t.type===r))}else o=!1;return o}));return n.size!==r.size?e.merge({blockMap:n}):e},f=t=>{const e=t.getBlockMap(),r=e.filter((t=>[a,s].includes(t.getType())||0===t.getDepth()));return r.size!==e.size?t.merge({blockMap:r}):t},p=(t,e)=>{const r=e.getBlockMap(),n=r.filter((t=>"unstyled"===t.getType())).map((e=>{const r=e.getText();let n,i=e;const o=t.find((t=>(n=new RegExp(t.test).exec(r),null!==n)));if(o&&n&&n[0]){const t=i.getText();if(i.getEntityAt(0)&&n[0]===t)return i;const e=n[0].length;let r=i.getCharacterList(),a=0;for(;a{const r=e.getBlockMap(),n=r.filter((e=>e.getDepth()>t)).map((e=>e.set("depth",t)));return 0===n.size?e:e.merge({blockMap:r.merge(n)})},d=(t,e)=>{const r=e.getBlockMap(),n=r.filter((e=>!t.includes(e.getType()))).map((t=>t.merge({type:o,depth:0})));return 0===n.size?e:e.merge({blockMap:r.merge(n)})},v=(t,e)=>{const r=e.getBlockMap(),i=r.map((e=>{let r=!1;const i=e.getCharacterList().map((e=>{let i=e;return e.getStyle().filter((e=>!t.includes(e))).forEach((t=>{r=!0,i=n.CharacterMetadata.removeStyle(i,t)})),i}));return r?e.set("characterList",i):e}));return e.merge({blockMap:r.merge(i)})},g=t=>{let e=t;const r=e.getBlockMap(),i=[],o=t=>{const e=t.getEntity();if(e){if(i.includes(e))return!0;i.push(e)}return!1},a=r.map((t=>{let r=t.getCharacterList(),i=!1;return t.findEntityRanges(o,((t,o)=>{const a=r.get(t).getEntity(),s=e.getEntity(a);e=e.createEntity(s.getType(),s.getMutability(),s.getData());const u=e.getLastCreatedEntityKey();r=r.map(((e,r)=>t<=r&&r<=o?n.CharacterMetadata.applyEntity(e,u):e)),i=!0})),i?t.set("characterList",r):t}));return e.merge({blockMap:r.merge(a)})},y=(t,e)=>{const r=e.getBlockMap(),i=r.map((r=>{let i=!1;const o=r.getCharacterList().map((o=>{const a=o.getEntity();if(a){if(!t(e,a,r))return i=!0,n.CharacterMetadata.applyEntity(o,null)}return o}));return i?r.set("characterList",o):r}));return e.merge({blockMap:r.merge(i)})},m=(t,e)=>{let r=e;const n={};return r.getBlockMap().forEach((t=>{t.findEntityRanges((t=>{const e=t.getEntity();if(e){const t=r.getEntity(e);n[e]=t}return!1}))})),Object.keys(n).forEach((e=>{const i=n[e],o=i.getData(),a=t.find((t=>t.type===i.getType())),s=a?a.attributes:null;if(!s)return o;const u=s.reduce(((t,e)=>(o.hasOwnProperty(e)&&(t[e]=o[e]),t)),{});r=r.replaceEntityData(e,u)})),r},_=(t,e)=>{const r=e.getBlockMap(),n=r.map((e=>{const r=e.getText(),n=t.reduce(((t,e)=>t.replace(new RegExp(e,"g")," ".repeat(e.length))),r);return r!==n?e.set("text",n):e}));return e.merge({blockMap:r.merge(n)})},b=[{test:"^(· |•\t|•|📷 |\t| \t)",type:"unordered-list-item",depth:0},{test:"^(◦|o |o\t)",type:"unordered-list-item",depth:1},{test:"^(§ |\t|◾)",type:"unordered-list-item",depth:2},{test:"^1{0,1}\\d\\.[ \t]",type:"ordered-list-item",depth:0},{test:"^x{0,1}(i|ii|iii|iv|v|vi|vii|viii|ix|x)\\.[ \t]",type:"ordered-list-item",depth:2},{test:"^[a-z]\\.[ \t]",type:"ordered-list-item",depth:1}],S=(t,e)=>{const{blocks:r,styles:a,entities:s,maxNesting:S,whitespacedCharacters:w,blockTextRules:x=b}=t,E=[f,p.bind(null,x),h.bind(null,S),v.bind(null,a),d.bind(null,r.concat([o,i])),u,c,y.bind(null,((t,e,r)=>{const n=t.getEntity(e),o=n.getData(),a=n.getType(),u=r.getType();return c=a,s.some((t=>t.type===c))&&((t,e,r)=>{const n=t.find((t=>t.type===e)),i=n&&n.allowlist?n.allowlist:n&&n.whitelist?n.whitelist:{};return Object.keys(i).every((t=>{const e=i[t];if("boolean"==typeof e){const n=r.hasOwnProperty(t);return e?n:!n}return new RegExp(e).test(r[t])}))})(s,a,o)&&!((t,e)=>"IMAGE"===t&&e!==i)(a,u);var c})),l.bind(null,s),m.bind(null,s),g,_.bind(null,w)],O=e.getCurrentContent();return((t,e,r)=>{if(r===e)return t;if(0===r.getBlockMap().size)return n.EditorState.moveFocusToEnd(n.EditorState.set(t,{currentContent:n.ContentState.createFromText("")}));const i=n.EditorState.set(t,{currentContent:r}),o=t.getSelection(),a=o.getAnchorKey(),s=r.getBlockForKey(a);if(!o.isCollapsed()||s)return i;const u=r.getBlockMap().keySeq().reverse().find((t=>e.getKeyAfter(t)!==r.getKeyAfter(t)));if(u){const t=r.getBlockForKey(u).getText().length,e=o.merge({anchorKey:u,focusKey:u,anchorOffset:t,focusOffset:t});return n.EditorState.acceptSelection(i,e)}return i})(e,O,E.reduce(((t,e)=>e(t)),O))}},44891:(t,e,r)=>{"use strict";var n=r(51006),i=r(89825),o=r(60139),a=new RegExp("\r\n","g"),s={"text/rtf":1,"text/html":1};function u(t){if("file"==t.kind)return t.getAsFile()}var c=function(){function DataTransfer(t){this.data=t,this.types=t.types?i(t.types):[]}var t=DataTransfer.prototype;return t.isRichText=function(){return!(!this.getHTML()||!this.getText())||!this.isImage()&&this.types.some((function(t){return s[t]}))},t.getText=function(){var t;return this.data.getData&&(this.types.length?-1!=this.types.indexOf("text/plain")&&(t=this.data.getData("text/plain")):t=this.data.getData("Text")),t?t.replace(a,"\n"):null},t.getHTML=function(){if(this.data.getData){if(!this.types.length)return this.data.getData("Text");if(-1!=this.types.indexOf("text/html"))return this.data.getData("text/html")}},t.isLink=function(){return this.types.some((function(t){return-1!=t.indexOf("Url")||-1!=t.indexOf("text/uri-list")||t.indexOf("text/x-moz-url")}))},t.getLink=function(){return this.data.getData?-1!=this.types.indexOf("text/x-moz-url")?this.data.getData("text/x-moz-url").split("\n")[0]:-1!=this.types.indexOf("text/uri-list")?this.data.getData("text/uri-list"):this.data.getData("url"):null},t.isImage=function(){var t=this.types.some((function(t){return-1!=t.indexOf("application/x-moz-file")}));if(t)return!0;for(var e=this.getFiles(),r=0;r0},DataTransfer}();t.exports=c},25399:t=>{"use strict";t.exports={BACKSPACE:8,TAB:9,RETURN:13,ALT:18,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46,COMMA:188,PERIOD:190,A:65,Z:90,ZERO:48,NUMPAD_0:96,NUMPAD_9:105}},51006:t=>{"use strict";var e={isImage:function(t){return"image"===r(t)[0]},isJpeg:function(t){var n=r(t);return e.isImage(t)&&("jpeg"===n[1]||"pjpeg"===n[1])}};function r(t){return t.split("/")}t.exports=e},65994:t=>{"use strict";function e(t,e){return!!e&&(t===e.documentElement||t===e.body)}var r={getTop:function(t){var r=t.ownerDocument;return e(t,r)?r.body.scrollTop||r.documentElement.scrollTop:t.scrollTop},setTop:function(t,r){var n=t.ownerDocument;e(t,n)?n.body.scrollTop=n.documentElement.scrollTop=r:t.scrollTop=r},getLeft:function(t){var r=t.ownerDocument;return e(t,r)?r.body.scrollLeft||r.documentElement.scrollLeft:t.scrollLeft},setLeft:function(t,r){var n=t.ownerDocument;e(t,n)?n.body.scrollLeft=n.documentElement.scrollLeft=r:t.scrollLeft=r}};t.exports=r},19051:(t,e,r)=>{"use strict";function n(t,e){var r=i.get(t,e);return"auto"===r||"scroll"===r}var i={get:r(85466),getScrollParent:function(t){if(!t)return null;for(var e=t.ownerDocument;t&&t!==e.body;){if(n(t,"overflow")||n(t,"overflowY")||n(t,"overflowX"))return t;t=t.parentNode}return e.defaultView||e.parentWindow}};t.exports=i},65724:t=>{"use strict";t.exports={getPunctuation:function(){return"[.,+*?$|#{}()'\\^\\-\\[\\]\\\\\\/!@%\"~=<>_:;・、。〈-】〔-〟:-?!-/[-`{-・⸮؟٪-٬؛،؍﴾﴿᠁।၊။‐-‧‰-⁞¡-±´-¸º»¿]"}}},61425:t=>{"use strict";var e=function(){function URI(t){var e,r,n;n=void 0,(r="_uri")in(e=this)?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,this._uri=t}return URI.prototype.toString=function(){return this._uri},URI}();t.exports=e},54191:(t,e,r)=>{"use strict";var n=r(16633),i=r(73759),o="֐־׀׃׆׈-׏א-ת׫-ׯװ-ײ׳-״׵-׿߀-߉ߊ-ߪߴ-ߵߺ߻-߿ࠀ-ࠕࠚࠤࠨ࠮-࠯࠰-࠾࠿ࡀ-ࡘ࡜-࡝࡞࡟-࢟‏יִײַ-ﬨשׁ-זּ﬷טּ-לּ﬽מּ﬿נּ-סּ﭂ףּ-פּ﭅צּ-ﭏ",a="؈؋؍؛؜؝؞-؟ؠ-ؿـف-ي٭ٮ-ٯٱ-ۓ۔ەۥ-ۦۮ-ۯۺ-ۼ۽-۾ۿ܀-܍܎܏ܐܒ-ܯ݋-݌ݍ-ޥޱ޲-޿ࢠ-ࢲࢳ-ࣣﭐ-ﮱ﮲-﯁﯂-﯒ﯓ-ﴽ﵀-﵏ﵐ-ﶏ﶐-﶑ﶒ-ﷇ﷈-﷏ﷰ-ﷻ﷼﷾-﷿ﹰ-ﹴ﹵ﹶ-ﻼ﻽-﻾",s=new RegExp("["+"A-Za-zªµºÀ-ÖØ-öø-ƺƻƼ-ƿǀ-ǃDŽ-ʓʔʕ-ʯʰ-ʸʻ-ˁː-ˑˠ-ˤˮͰ-ͳͶ-ͷͺͻ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁ҂Ҋ-ԯԱ-Ֆՙ՚-՟ա-և։ःऄ-हऻऽा-ीॉ-ौॎ-ॏॐक़-ॡ।-॥०-९॰ॱॲ-ঀং-ঃঅ-ঌএ-ঐও-নপ-রলশ-হঽা-ীে-ৈো-ৌৎৗড়-ঢ়য়-ৡ০-৯ৰ-ৱ৴-৹৺ਃਅ-ਊਏ-ਐਓ-ਨਪ-ਰਲ-ਲ਼ਵ-ਸ਼ਸ-ਹਾ-ੀਖ਼-ੜਫ਼੦-੯ੲ-ੴઃઅ-ઍએ-ઑઓ-નપ-રલ-ળવ-હઽા-ીૉો-ૌૐૠ-ૡ૦-૯૰ଂ-ଃଅ-ଌଏ-ଐଓ-ନପ-ରଲ-ଳଵ-ହଽାୀେ-ୈୋ-ୌୗଡ଼-ଢ଼ୟ-ୡ୦-୯୰ୱ୲-୷ஃஅ-ஊஎ-ஐஒ-கங-சஜஞ-டண-தந-பம-ஹா-ிு-ூெ-ைொ-ௌௐௗ௦-௯௰-௲ఁ-ఃఅ-ఌఎ-ఐఒ-నప-హఽు-ౄౘ-ౙౠ-ౡ౦-౯౿ಂ-ಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽಾಿೀ-ೄೆೇ-ೈೊ-ೋೕ-ೖೞೠ-ೡ೦-೯ೱ-ೲം-ഃഅ-ഌഎ-ഐഒ-ഺഽാ-ീെ-ൈൊ-ൌൎൗൠ-ൡ൦-൯൰-൵൹ൺ-ൿං-ඃඅ-ඖක-නඳ-රලව-ෆා-ෑෘ-ෟ෦-෯ෲ-ෳ෴ก-ะา-ำเ-ๅๆ๏๐-๙๚-๛ກ-ຂຄງ-ຈຊຍດ-ທນ-ຟມ-ຣລວສ-ຫອ-ະາ-ຳຽເ-ໄໆ໐-໙ໜ-ໟༀ༁-༃༄-༒༓༔༕-༗༚-༟༠-༩༪-༳༴༶༸༾-༿ཀ-ཇཉ-ཬཿ྅ྈ-ྌ྾-࿅࿇-࿌࿎-࿏࿐-࿔࿕-࿘࿙-࿚က-ဪါ-ာေးျ-ြဿ၀-၉၊-၏ၐ-ၕၖ-ၗၚ-ၝၡၢ-ၤၥ-ၦၧ-ၭၮ-ၰၵ-ႁႃ-ႄႇ-ႌႎႏ႐-႙ႚ-ႜ႞-႟Ⴀ-ჅჇჍა-ჺ჻ჼჽ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፠-፨፩-፼ᎀ-ᎏᎠ-Ᏼᐁ-ᙬ᙭-᙮ᙯ-ᙿᚁ-ᚚᚠ-ᛪ᛫-᛭ᛮ-ᛰᛱ-ᛸᜀ-ᜌᜎ-ᜑᜠ-ᜱ᜵-᜶ᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳាើ-ៅះ-ៈ។-៖ៗ៘-៚ៜ០-៩᠐-᠙ᠠ-ᡂᡃᡄ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᤣ-ᤦᤩ-ᤫᤰ-ᤱᤳ-ᤸ᥆-᥏ᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧀᧁ-ᧇᧈ-ᧉ᧐-᧙᧚ᨀ-ᨖᨙ-ᨚ᨞-᨟ᨠ-ᩔᩕᩗᩡᩣ-ᩤᩭ-ᩲ᪀-᪉᪐-᪙᪠-᪦ᪧ᪨-᪭ᬄᬅ-ᬳᬵᬻᬽ-ᭁᭃ-᭄ᭅ-ᭋ᭐-᭙᭚-᭠᭡-᭪᭴-᭼ᮂᮃ-ᮠᮡᮦ-ᮧ᮪ᮮ-ᮯ᮰-᮹ᮺ-ᯥᯧᯪ-ᯬᯮ᯲-᯳᯼-᯿ᰀ-ᰣᰤ-ᰫᰴ-ᰵ᰻-᰿᱀-᱉ᱍ-ᱏ᱐-᱙ᱚ-ᱷᱸ-ᱽ᱾-᱿᳀-᳇᳓᳡ᳩ-ᳬᳮ-ᳱᳲ-ᳳᳵ-ᳶᴀ-ᴫᴬ-ᵪᵫ-ᵷᵸᵹ-ᶚᶛ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‎ⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℴℵ-ℸℹℼ-ℿⅅ-ⅉⅎ⅏Ⅰ-ↂↃ-ↄↅ-ↈ⌶-⍺⎕⒜-ⓩ⚬⠀-⣿Ⰰ-Ⱞⰰ-ⱞⱠ-ⱻⱼ-ⱽⱾ-ⳤⳫ-ⳮⳲ-ⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵰ⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々〆〇〡-〩〮-〯〱-〵〸-〺〻〼ぁ-ゖゝ-ゞゟァ-ヺー-ヾヿㄅ-ㄭㄱ-ㆎ㆐-㆑㆒-㆕㆖-㆟ㆠ-ㆺㇰ-ㇿ㈀-㈜㈠-㈩㈪-㉇㉈-㉏㉠-㉻㉿㊀-㊉㊊-㊰㋀-㋋㋐-㋾㌀-㍶㍻-㏝㏠-㏾㐀-䶵一-鿌ꀀ-ꀔꀕꀖ-ꒌꓐ-ꓷꓸ-ꓽ꓾-꓿ꔀ-ꘋꘌꘐ-ꘟ꘠-꘩ꘪ-ꘫꙀ-ꙭꙮꚀ-ꚛꚜ-ꚝꚠ-ꛥꛦ-ꛯ꛲-꛷Ꜣ-ꝯꝰꝱ-ꞇ꞉-꞊Ꞌ-ꞎꞐ-ꞭꞰ-Ʇꟷꟸ-ꟹꟺꟻ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꠣ-ꠤꠧ꠰-꠵꠶-꠷ꡀ-ꡳꢀ-ꢁꢂ-ꢳꢴ-ꣃ꣎-꣏꣐-꣙ꣲ-ꣷ꣸-꣺ꣻ꤀-꤉ꤊ-ꤥ꤮-꤯ꤰ-ꥆꥒ-꥓꥟ꥠ-ꥼꦃꦄ-ꦲꦴ-ꦵꦺ-ꦻꦽ-꧀꧁-꧍ꧏ꧐-꧙꧞-꧟ꧠ-ꧤꧦꧧ-ꧯ꧰-꧹ꧺ-ꧾꨀ-ꨨꨯ-ꨰꨳ-ꨴꩀ-ꩂꩄ-ꩋꩍ꩐-꩙꩜-꩟ꩠ-ꩯꩰꩱ-ꩶ꩷-꩹ꩺꩻꩽꩾ-ꪯꪱꪵ-ꪶꪹ-ꪽꫀꫂꫛ-ꫜꫝ꫞-꫟ꫠ-ꫪꫫꫮ-ꫯ꫰-꫱ꫲꫳ-ꫴꫵꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚ꭛ꭜ-ꭟꭤ-ꭥꯀ-ꯢꯣ-ꯤꯦ-ꯧꯩ-ꯪ꯫꯬꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ-豈-舘並-龎ff-stﬓ-ﬗA-Za-zヲ-ッーア-ン゙-゚ᅠ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ"+o+a+"]"),u=new RegExp("["+o+a+"]");function c(t){var e=s.exec(t);return null==e?null:e[0]}function l(t){var e=c(t);return null==e?n.NEUTRAL:u.exec(e)?n.RTL:n.LTR}function f(t,e){if(e=e||n.NEUTRAL,!t.length)return e;var r=l(t);return r===n.NEUTRAL?e:r}function p(t,e){return e||(e=n.getGlobalDir()),n.isStrong(e)||i(!1),f(t,e)}var h={firstStrongChar:c,firstStrongCharDir:l,resolveBlockDir:f,getDirection:p,isDirectionLTR:function(t,e){return p(t,e)===n.LTR},isDirectionRTL:function(t,e){return p(t,e)===n.RTL}};t.exports=h},16633:(t,e,r)=>{"use strict";var n=r(73759),i="LTR",o="RTL",a=null;function s(t){return t===i||t===o}function u(t){return s(t)||n(!1),t===i?"ltr":"rtl"}function c(t){a=t}var l={NEUTRAL:"NEUTRAL",LTR:i,RTL:o,isStrong:s,getHTMLDir:u,getHTMLDirIfDifferent:function(t,e){return s(t)||n(!1),s(e)||n(!1),t===e?null:u(t)},setGlobalDir:c,initGlobalDir:function(){c(i)},getGlobalDir:function(){return a||this.initGlobalDir(),a||n(!1),a}};t.exports=l},7902:(t,e,r)=>{"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var i=r(54191),o=r(16633),a=r(73759),s=function(){function UnicodeBidiService(t){n(this,"_defaultDir",void 0),n(this,"_lastDir",void 0),t?o.isStrong(t)||a(!1):t=o.getGlobalDir(),this._defaultDir=t,this.reset()}var t=UnicodeBidiService.prototype;return t.reset=function(){this._lastDir=this._defaultDir},t.getDirection=function(t){return this._lastDir=i.getDirection(t,this._lastDir),this._lastDir},UnicodeBidiService}();t.exports=s},38935:(t,e,r)=>{"use strict";var n=r(73759),i=55296,o=57343,a=/[\uD800-\uDFFF]/;function s(t){return i<=t&&t<=o}function u(t){return a.test(t)}function c(t,e){return 1+s(t.charCodeAt(e))}function l(t,e,r){if(e=e||0,r=void 0===r?1/0:r||0,!u(t))return t.substr(e,r);var n=t.length;if(n<=0||e>n||r<=0)return"";var i=0;if(e>0){for(;e>0&&i=n)return""}else if(e<0){for(i=n;e<0&&00&&o{"use strict";var n=r(95845),i=r(59859),o=r(79467),a=r(51767);function s(t,e,r,n){if(t===r)return!0;if(!r.startsWith(t))return!1;var o=r.slice(t.length);return!!e&&(o=n?n(o):o,i.contains(o,e))}function u(t){return"Windows"===n.platformName?t.replace(/^\s*NT/,""):t}var c={isBrowser:function(t){return s(n.browserName,n.browserFullVersion,t)},isBrowserArchitecture:function(t){return s(n.browserArchitecture,null,t)},isDevice:function(t){return s(n.deviceName,null,t)},isEngine:function(t){return s(n.engineName,n.engineVersion,t)},isPlatform:function(t){return s(n.platformName,n.platformFullVersion,t,u)},isPlatformArchitecture:function(t){return s(n.platformArchitecture,null,t)}};t.exports=o(c,a)},95845:(t,e,r)=>{"use strict";var n=r(42238),i="Unknown",o={"Mac OS":"Mac OS X"};var a,s=(new n).getResult(),u=function(t){if(!t)return{major:"",minor:""};var e=t.split(".");return{major:e[0],minor:e[1]}}(s.browser.version),c={browserArchitecture:s.cpu.architecture||i,browserFullVersion:s.browser.version||i,browserMinorVersion:u.minor||i,browserName:s.browser.name||i,browserVersion:s.browser.major||i,deviceName:s.device.model||i,engineName:s.engine.name||i,engineVersion:s.engine.version||i,platformArchitecture:s.cpu.architecture||i,platformName:(a=s.os.name,o[a]||a||i),platformVersion:s.os.version||i,platformFullVersion:s.os.version||i};t.exports=c},59859:(t,e,r)=>{"use strict";var n=r(73759),i=/\./,o=/\|\|/,a=/\s+\-\s+/,s=/^(<=|<|=|>=|~>|~|>|)?\s*(.+)/,u=/^(\d*)(.*)/;function c(t,e){var r=t.split(o);return r.length>1?r.some((function(t){return b.contains(t,e)})):function(t,e){var r=t.split(a);if(r.length>0&&r.length<=2||n(!1),1===r.length)return l(r[0],e);var i=r[0],o=r[1];return v(i)&&v(o)||n(!1),l(">="+i,e)&&l("<="+o,e)}(t=r[0].trim(),e)}function l(t,e){if(""===(t=t.trim()))return!0;var r,n=e.split(i),o=h(t),a=o.modifier,s=o.rangeComponents;switch(a){case"<":return f(n,s);case"<=":return-1===(r=_(n,s))||0===r;case">=":return p(n,s);case">":return function(t,e){return 1===_(t,e)}(n,s);case"~":case"~>":return function(t,e){var r=e.slice(),n=e.slice();n.length>1&&n.pop();var i=n.length-1,o=parseInt(n[i],10);d(o)&&(n[i]=o+1+"");return p(t,r)&&f(t,n)}(n,s);default:return function(t,e){return 0===_(t,e)}(n,s)}}function f(t,e){return-1===_(t,e)}function p(t,e){var r=_(t,e);return 1===r||0===r}function h(t){var e=t.split(i),r=e[0].match(s);return r||n(!1),{modifier:r[1],rangeComponents:[r[2]].concat(e.slice(1))}}function d(t){return!isNaN(t)&&isFinite(t)}function v(t){return!h(t).modifier}function g(t,e){for(var r=t.length;re?1:t{"use strict";var e=/-(.)/g;t.exports=function(t){return t.replace(e,(function(t,e){return e.toUpperCase()}))}},67476:(t,e,r)=>{"use strict";var n=r(52334);t.exports=function t(e,r){return!(!e||!r)&&(e===r||!n(e)&&(n(r)?t(e,r.parentNode):"contains"in e?e.contains(r):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(r))))}},89825:(t,e,r)=>{"use strict";var n=r(73759);t.exports=function(t){return function(t){return!!t&&("object"==typeof t||"function"==typeof t)&&"length"in t&&!("setInterval"in t)&&"number"!=typeof t.nodeType&&(Array.isArray(t)||"callee"in t||"item"in t)}(t)?Array.isArray(t)?t.slice():function(t){var e=t.length;if((Array.isArray(t)||"object"!=typeof t&&"function"!=typeof t)&&n(!1),"number"!=typeof e&&n(!1),0===e||e-1 in t||n(!1),"function"==typeof t.callee&&n(!1),t.hasOwnProperty)try{return Array.prototype.slice.call(t)}catch(t){}for(var r=Array(e),i=0;i{"use strict";function e(t){return t.replace(/\//g,"-")}t.exports=function(t){return"object"==typeof t?Object.keys(t).filter((function(e){return t[e]})).map(e).join(" "):Array.prototype.map.call(arguments,e).join(" ")}},60139:t=>{"use strict";function e(t){return function(){return t}}var r=function(){};r.thatReturns=e,r.thatReturnsFalse=e(!1),r.thatReturnsTrue=e(!0),r.thatReturnsNull=e(null),r.thatReturnsThis=function(){return this},r.thatReturnsArgument=function(t){return t},t.exports=r},31003:t=>{"use strict";t.exports=function(t){if(void 0===(t=t||("undefined"!=typeof document?document:void 0)))return null;try{return t.activeElement||t.body}catch(e){return t.body}}},35179:t=>{"use strict";var e="undefined"!=typeof navigator&&navigator.userAgent.indexOf("AppleWebKit")>-1;t.exports=function(t){return(t=t||document).scrollingElement?t.scrollingElement:e||"CSS1Compat"!==t.compatMode?t.body:t.documentElement}},55258:(t,e,r)=>{"use strict";var n=r(23123);t.exports=function(t){var e=n(t);return{x:e.left,y:e.top,width:e.right-e.left,height:e.bottom-e.top}}},23123:(t,e,r)=>{"use strict";var n=r(67476);t.exports=function(t){var e=t.ownerDocument.documentElement;if(!("getBoundingClientRect"in t)||!n(e,t))return{left:0,right:0,top:0,bottom:0};var r=t.getBoundingClientRect();return{left:Math.round(r.left)-e.clientLeft,right:Math.round(r.right)-e.clientLeft,top:Math.round(r.top)-e.clientTop,bottom:Math.round(r.bottom)-e.clientTop}}},79749:(t,e,r)=>{"use strict";var n=r(35179),i=r(30787);t.exports=function(t){var e=n(t.ownerDocument||t.document);t.Window&&t instanceof t.Window&&(t=e);var r=i(t),o=t===e?t.ownerDocument.documentElement:t,a=t.scrollWidth-o.clientWidth,s=t.scrollHeight-o.clientHeight;return r.x=Math.max(0,Math.min(r.x,a)),r.y=Math.max(0,Math.min(r.y,s)),r}},85466:(t,e,r)=>{"use strict";var n=r(52297),i=r(89349);function o(t){return null==t?t:String(t)}t.exports=function(t,e){var r;if(window.getComputedStyle&&(r=window.getComputedStyle(t,null)))return o(r.getPropertyValue(i(e)));if(document.defaultView&&document.defaultView.getComputedStyle){if(r=document.defaultView.getComputedStyle(t,null))return o(r.getPropertyValue(i(e)));if("display"===e)return"none"}return t.currentStyle?o("float"===e?t.currentStyle.cssFloat||t.currentStyle.styleFloat:t.currentStyle[n(e)]):o(t.style&&t.style[n(e)])}},30787:t=>{"use strict";t.exports=function(t){return t.Window&&t instanceof t.Window?{x:t.pageXOffset||t.document.documentElement.scrollLeft,y:t.pageYOffset||t.document.documentElement.scrollTop}:{x:t.scrollLeft,y:t.scrollTop}}},70746:t=>{"use strict";function e(){var t;return document.documentElement&&(t=document.documentElement.clientWidth),!t&&document.body&&(t=document.body.clientWidth),t||0}function r(){var t;return document.documentElement&&(t=document.documentElement.clientHeight),!t&&document.body&&(t=document.body.clientHeight),t||0}function n(){return{width:window.innerWidth||e(),height:window.innerHeight||r()}}n.withoutScrollbars=function(){return{width:e(),height:r()}},t.exports=n},89349:t=>{"use strict";var e=/([A-Z])/g;t.exports=function(t){return t.replace(e,"-$1").toLowerCase()}},73759:t=>{"use strict";var e=function(t){};t.exports=function(t,r){for(var n=arguments.length,i=new Array(n>2?n-2:0),o=2;o{"use strict";t.exports=function(t){var e=(t?t.ownerDocument||t:document).defaultView||window;return!(!t||!("function"==typeof e.Node?t instanceof e.Node:"object"==typeof t&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName))}},52334:(t,e,r)=>{"use strict";var n=r(20901);t.exports=function(t){return n(t)&&3==t.nodeType}},71108:t=>{"use strict";t.exports=function(t){var e=t||"",r=arguments.length;if(r>1)for(var n=1;n{"use strict";var e=Object.prototype.hasOwnProperty;t.exports=function(t,r,n){if(!t)return null;var i={};for(var o in t)e.call(t,o)&&(i[o]=r.call(n,t[o],o,t));return i}},51767:t=>{"use strict";t.exports=function(t){var e={};return function(r){return e.hasOwnProperty(r)||(e[r]=t.call(this,r)),e[r]}}},22045:t=>{"use strict";t.exports=function(t){if(null!=t)return t;throw new Error("Got unexpected null or undefined")}},56926:(t,e,r)=>{"use strict";r(24889),t.exports=r.g.setImmediate},63620:(t,e,r)=>{"use strict";var n=r(60139);t.exports=n},35369:(t,e,r)=>{"use strict";r.d(e,{List:()=>rr,Map:()=>Re,OrderedSet:()=>nn,Repeat:()=>gn,Seq:()=>X,is:()=>ft});var n="delete",i=5,o=1<>>0;if(""+r!==e||4294967295===r)return NaN;e=r}return e<0?u(t)+e:e}function l(){return!0}function f(t,e,r){return(0===t&&!v(t)||void 0!==r&&t<=-r)&&(void 0===e||void 0!==r&&e>=r)}function p(t,e){return d(t,e,0)}function h(t,e){return d(t,e,e)}function d(t,e,r){return void 0===t?r:v(t)?e===1/0?e:0|Math.max(0,e+t):void 0===e||e===t?t:0|Math.min(e,t)}function v(t){return t<0||0===t&&1/t==-1/0}var g="@@__IMMUTABLE_ITERABLE__@@";function y(t){return Boolean(t&&t[g])}var m="@@__IMMUTABLE_KEYED__@@";function _(t){return Boolean(t&&t[m])}var b="@@__IMMUTABLE_INDEXED__@@";function S(t){return Boolean(t&&t[b])}function w(t){return _(t)||S(t)}var x=function Collection(t){return y(t)?t:X(t)},E=function(t){function KeyedCollection(t){return _(t)?t:$(t)}return t&&(KeyedCollection.__proto__=t),KeyedCollection.prototype=Object.create(t&&t.prototype),KeyedCollection.prototype.constructor=KeyedCollection,KeyedCollection}(x),O=function(t){function IndexedCollection(t){return S(t)?t:J(t)}return t&&(IndexedCollection.__proto__=t),IndexedCollection.prototype=Object.create(t&&t.prototype),IndexedCollection.prototype.constructor=IndexedCollection,IndexedCollection}(x),C=function(t){function SetCollection(t){return y(t)&&!w(t)?t:Z(t)}return t&&(SetCollection.__proto__=t),SetCollection.prototype=Object.create(t&&t.prototype),SetCollection.prototype.constructor=SetCollection,SetCollection}(x);x.Keyed=E,x.Indexed=O,x.Set=C;var k="@@__IMMUTABLE_SEQ__@@";function D(t){return Boolean(t&&t[k])}var M="@@__IMMUTABLE_RECORD__@@";function I(t){return Boolean(t&&t[M])}function A(t){return y(t)||I(t)}var R="@@__IMMUTABLE_ORDERED__@@";function T(t){return Boolean(t&&t[R])}var z=0,B=1,q=2,P="function"==typeof Symbol&&Symbol.iterator,j="@@iterator",L=P||j,K=function Iterator(t){this.next=t};function N(t,e,r,n){var i=0===t?e:1===t?r:[e,r];return n?n.value=i:n={value:i,done:!1},n}function F(){return{value:void 0,done:!0}}function U(t){return!!Array.isArray(t)||!!W(t)}function G(t){return t&&"function"==typeof t.next}function H(t){var e=W(t);return e&&e.call(t)}function W(t){var e=t&&(P&&t[P]||t[j]);if("function"==typeof e)return e}K.prototype.toString=function(){return"[Iterator]"},K.KEYS=z,K.VALUES=B,K.ENTRIES=q,K.prototype.inspect=K.prototype.toSource=function(){return this.toString()},K.prototype[L]=function(){return this};var V=Object.prototype.hasOwnProperty;function Y(t){return!(!Array.isArray(t)&&"string"!=typeof t)||t&&"object"==typeof t&&Number.isInteger(t.length)&&t.length>=0&&(0===t.length?1===Object.keys(t).length:t.hasOwnProperty(t.length-1))}var X=function(t){function Seq(t){return null==t?nt():A(t)?t.toSeq():function(t){var e=at(t);if(e)return(n=W(r=t))&&n===r.entries?e.fromEntrySeq():function(t){var e=W(t);return e&&e===t.keys}(t)?e.toSetSeq():e;var r,n;if("object"==typeof t)return new tt(t);throw new TypeError("Expected Array or collection object of values, or keyed object: "+t)}(t)}return t&&(Seq.__proto__=t),Seq.prototype=Object.create(t&&t.prototype),Seq.prototype.constructor=Seq,Seq.prototype.toSeq=function(){return this},Seq.prototype.toString=function(){return this.__toString("Seq {","}")},Seq.prototype.cacheResult=function(){return!this._cache&&this.__iterateUncached&&(this._cache=this.entrySeq().toArray(),this.size=this._cache.length),this},Seq.prototype.__iterate=function __iterate(t,e){var r=this._cache;if(r){for(var n=r.length,i=0;i!==n;){var o=r[e?n-++i:i++];if(!1===t(o[1],o[0],this))break}return i}return this.__iterateUncached(t,e)},Seq.prototype.__iterator=function __iterator(t,e){var r=this._cache;if(r){var n=r.length,i=0;return new K((function(){if(i===n)return{value:void 0,done:!0};var o=r[e?n-++i:i++];return N(t,o[0],o[1])}))}return this.__iteratorUncached(t,e)},Seq}(x),$=function(t){function KeyedSeq(t){return null==t?nt().toKeyedSeq():y(t)?_(t)?t.toSeq():t.fromEntrySeq():I(t)?t.toSeq():it(t)}return t&&(KeyedSeq.__proto__=t),KeyedSeq.prototype=Object.create(t&&t.prototype),KeyedSeq.prototype.constructor=KeyedSeq,KeyedSeq.prototype.toKeyedSeq=function(){return this},KeyedSeq}(X),J=function(t){function IndexedSeq(t){return null==t?nt():y(t)?_(t)?t.entrySeq():t.toIndexedSeq():I(t)?t.toSeq().entrySeq():ot(t)}return t&&(IndexedSeq.__proto__=t),IndexedSeq.prototype=Object.create(t&&t.prototype),IndexedSeq.prototype.constructor=IndexedSeq,IndexedSeq.of=function(){return IndexedSeq(arguments)},IndexedSeq.prototype.toIndexedSeq=function(){return this},IndexedSeq.prototype.toString=function(){return this.__toString("Seq [","]")},IndexedSeq}(X),Z=function(t){function SetSeq(t){return(y(t)&&!w(t)?t:J(t)).toSetSeq()}return t&&(SetSeq.__proto__=t),SetSeq.prototype=Object.create(t&&t.prototype),SetSeq.prototype.constructor=SetSeq,SetSeq.of=function(){return SetSeq(arguments)},SetSeq.prototype.toSetSeq=function(){return this},SetSeq}(X);X.isSeq=D,X.Keyed=$,X.Set=Z,X.Indexed=J,X.prototype[k]=!0;var Q=function(t){function ArraySeq(t){this._array=t,this.size=t.length}return t&&(ArraySeq.__proto__=t),ArraySeq.prototype=Object.create(t&&t.prototype),ArraySeq.prototype.constructor=ArraySeq,ArraySeq.prototype.get=function(t,e){return this.has(t)?this._array[c(this,t)]:e},ArraySeq.prototype.__iterate=function __iterate(t,e){for(var r=this._array,n=r.length,i=0;i!==n;){var o=e?n-++i:i++;if(!1===t(r[o],o,this))break}return i},ArraySeq.prototype.__iterator=function __iterator(t,e){var r=this._array,n=r.length,i=0;return new K((function(){if(i===n)return{value:void 0,done:!0};var o=e?n-++i:i++;return N(t,o,r[o])}))},ArraySeq}(J),tt=function(t){function ObjectSeq(t){var e=Object.keys(t).concat(Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t):[]);this._object=t,this._keys=e,this.size=e.length}return t&&(ObjectSeq.__proto__=t),ObjectSeq.prototype=Object.create(t&&t.prototype),ObjectSeq.prototype.constructor=ObjectSeq,ObjectSeq.prototype.get=function(t,e){return void 0===e||this.has(t)?this._object[t]:e},ObjectSeq.prototype.has=function(t){return V.call(this._object,t)},ObjectSeq.prototype.__iterate=function __iterate(t,e){for(var r=this._object,n=this._keys,i=n.length,o=0;o!==i;){var a=n[e?i-++o:o++];if(!1===t(r[a],a,this))break}return o},ObjectSeq.prototype.__iterator=function __iterator(t,e){var r=this._object,n=this._keys,i=n.length,o=0;return new K((function(){if(o===i)return{value:void 0,done:!0};var a=n[e?i-++o:o++];return N(t,a,r[a])}))},ObjectSeq}($);tt.prototype[R]=!0;var et,rt=function(t){function CollectionSeq(t){this._collection=t,this.size=t.length||t.size}return t&&(CollectionSeq.__proto__=t),CollectionSeq.prototype=Object.create(t&&t.prototype),CollectionSeq.prototype.constructor=CollectionSeq,CollectionSeq.prototype.__iterateUncached=function __iterateUncached(t,e){if(e)return this.cacheResult().__iterate(t,e);var r=H(this._collection),n=0;if(G(r))for(var i;!(i=r.next()).done&&!1!==t(i.value,n++,this););return n},CollectionSeq.prototype.__iteratorUncached=function __iteratorUncached(t,e){if(e)return this.cacheResult().__iterator(t,e);var r=H(this._collection);if(!G(r))return new K(F);var n=0;return new K((function(){var e=r.next();return e.done?e:N(t,n++,e.value)}))},CollectionSeq}(J);function nt(){return et||(et=new Q([]))}function it(t){var e=at(t);if(e)return e.fromEntrySeq();if("object"==typeof t)return new tt(t);throw new TypeError("Expected Array or collection object of [k, v] entries, or keyed object: "+t)}function ot(t){var e=at(t);if(e)return e;throw new TypeError("Expected Array or collection object of values: "+t)}function at(t){return Y(t)?new Q(t):U(t)?new rt(t):void 0}var st="@@__IMMUTABLE_MAP__@@";function ut(t){return Boolean(t&&t[st])}function ct(t){return ut(t)&&T(t)}function lt(t){return Boolean(t&&"function"==typeof t.equals&&"function"==typeof t.hashCode)}function ft(t,e){if(t===e||t!=t&&e!=e)return!0;if(!t||!e)return!1;if("function"==typeof t.valueOf&&"function"==typeof e.valueOf){if((t=t.valueOf())===(e=e.valueOf())||t!=t&&e!=e)return!0;if(!t||!e)return!1}return!!(lt(t)&<(e)&&t.equals(e))}var pt="function"==typeof Math.imul&&-2===Math.imul(4294967295,2)?Math.imul:function(t,e){var r=65535&(t|=0),n=65535&(e|=0);return r*n+((t>>>16)*n+r*(e>>>16)<<16>>>0)|0};function ht(t){return t>>>1&1073741824|3221225471&t}var dt=Object.prototype.valueOf;function vt(t){if(null==t)return gt(t);if("function"==typeof t.hashCode)return ht(t.hashCode(t));var e,r=(e=t).valueOf!==dt&&"function"==typeof e.valueOf?e.valueOf(e):e;if(null==r)return gt(r);switch(typeof r){case"boolean":return r?1108378657:1108378656;case"number":return function(t){if(t!=t||t===1/0)return 0;var e=0|t;e!==t&&(e^=4294967295*t);for(;t>4294967295;)e^=t/=4294967295;return ht(e)}(r);case"string":return r.length>Ct?function(t){var e=Mt[t];void 0===e&&(e=yt(t),Dt===kt&&(Dt=0,Mt={}),Dt++,Mt[t]=e);return e}(r):yt(r);case"object":case"function":return function(t){var e;if(wt&&void 0!==(e=St.get(t)))return e;if(e=t[Ot],void 0!==e)return e;if(!_t){if(void 0!==(e=t.propertyIsEnumerable&&t.propertyIsEnumerable[Ot]))return e;if(void 0!==(e=function(t){if(t&&t.nodeType>0)switch(t.nodeType){case 1:return t.uniqueID;case 9:return t.documentElement&&t.documentElement.uniqueID}}(t)))return e}if(e=bt(),wt)St.set(t,e);else{if(void 0!==mt&&!1===mt(t))throw new Error("Non-extensible objects are not allowed as keys.");if(_t)Object.defineProperty(t,Ot,{enumerable:!1,configurable:!1,writable:!1,value:e});else if(void 0!==t.propertyIsEnumerable&&t.propertyIsEnumerable===t.constructor.prototype.propertyIsEnumerable)t.propertyIsEnumerable=function(){return this.constructor.prototype.propertyIsEnumerable.apply(this,arguments)},t.propertyIsEnumerable[Ot]=e;else{if(void 0===t.nodeType)throw new Error("Unable to set a non-enumerable property on object.");t[Ot]=e}}return e}(r);case"symbol":return function(t){var e=xt[t];if(void 0!==e)return e;return e=bt(),xt[t]=e,e}(r);default:if("function"==typeof r.toString)return yt(r.toString());throw new Error("Value type "+typeof r+" cannot be hashed.")}}function gt(t){return null===t?1108378658:1108378659}function yt(t){for(var e=0,r=0;r=0&&(l.get=function(e,r){return(e=c(this,e))>=0&&es)return{value:void 0,done:!0};var t=i.next();return n||e===B||t.done?t:N(e,u-1,e===z?void 0:t.value[1],t)}))},l}function Lt(t,e,r,n){var i=Yt(t);return i.__iterateUncached=function(i,o){var a=this;if(o)return this.cacheResult().__iterate(i,o);var s=!0,u=0;return t.__iterate((function(t,o,c){if(!s||!(s=e.call(r,t,o,c)))return u++,i(t,n?o:u-1,a)})),u},i.__iteratorUncached=function(i,o){var a=this;if(o)return this.cacheResult().__iterator(i,o);var s=t.__iterator(q,o),u=!0,c=0;return new K((function(){var t,o,l;do{if((t=s.next()).done)return n||i===B?t:N(i,c++,i===z?void 0:t.value[1],t);var f=t.value;o=f[0],l=f[1],u&&(u=e.call(r,l,o,a))}while(u);return i===q?t:N(i,o,l,t)}))},i}function Kt(t,e,r){var n=Yt(t);return n.__iterateUncached=function(i,o){if(o)return this.cacheResult().__iterate(i,o);var a=0,s=!1;return function t(u,c){u.__iterate((function(o,u){return(!e||c0}function Gt(t,e,r,n){var i=Yt(t),o=new Q(r).map((function(t){return t.size}));return i.size=n?o.max():o.min(),i.__iterate=function(t,e){for(var r,n=this.__iterator(B,e),i=0;!(r=n.next()).done&&!1!==t(r.value,i++,this););return i},i.__iteratorUncached=function(t,i){var o=r.map((function(t){return t=x(t),H(i?t.reverse():t)})),a=0,s=!1;return new K((function(){var r;return s||(r=o.map((function(t){return t.next()})),s=n?r.every((function(t){return t.done})):r.some((function(t){return t.done}))),s?{value:void 0,done:!0}:N(t,a++,e.apply(null,r.map((function(t){return t.value}))))}))},i}function Ht(t,e){return t===e?t:D(t)?e:t.constructor(e)}function Wt(t){if(t!==Object(t))throw new TypeError("Expected [K, V] tuple: "+t)}function Vt(t){return _(t)?E:S(t)?O:C}function Yt(t){return Object.create((_(t)?$:S(t)?J:Z).prototype)}function Xt(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):X.prototype.cacheResult.call(this)}function $t(t,e){return void 0===t&&void 0===e?0:void 0===t?1:void 0===e?-1:t>e?1:t0;)e[r]=arguments[r+1];if("function"!=typeof t)throw new TypeError("Invalid merger function: "+t);return Se(this,e,t)}function Se(t,e,r){for(var n=[],i=0;i0;)e[r]=arguments[r+1];return we(this,e,t)}function Ce(t){for(var e=[],r=arguments.length-1;r-- >0;)e[r]=arguments[r+1];return le(this,t,Ge(),(function(t){return xe(t,e)}))}function ke(t){for(var e=[],r=arguments.length-1;r-- >0;)e[r]=arguments[r+1];return le(this,t,Ge(),(function(t){return we(t,e)}))}function De(t){var e=this.asMutable();return t(e),e.wasAltered()?e.__ensureOwner(this.__ownerID):this}function Me(){return this.__ownerID?this:this.__ensureOwner(new OwnerID)}function Ie(){return this.__ensureOwner()}function Ae(){return this.__altered}var Re=function(t){function Map(e){return null==e?Ge():ut(e)&&!T(e)?e:Ge().withMutations((function(r){var n=t(e);Qt(n.size),n.forEach((function(t,e){return r.set(e,t)}))}))}return t&&(Map.__proto__=t),Map.prototype=Object.create(t&&t.prototype),Map.prototype.constructor=Map,Map.of=function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];return Ge().withMutations((function(e){for(var r=0;r=t.length)throw new Error("Missing value for key: "+t[r]);e.set(t[r],t[r+1])}}))},Map.prototype.toString=function(){return this.__toString("Map {","}")},Map.prototype.get=function(t,e){return this._root?this._root.get(0,void 0,t,e):e},Map.prototype.set=function(t,e){return He(this,t,e)},Map.prototype.remove=function(t){return He(this,t,s)},Map.prototype.deleteAll=function(t){var e=x(t);return 0===e.size?this:this.withMutations((function(t){e.forEach((function(e){return t.remove(e)}))}))},Map.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):Ge()},Map.prototype.sort=function(t){return gr(Nt(this,t))},Map.prototype.sortBy=function(t,e){return gr(Nt(this,e,t))},Map.prototype.map=function(t,e){var r=this;return this.withMutations((function(n){n.forEach((function(i,o){n.set(o,t.call(e,i,o,r))}))}))},Map.prototype.__iterator=function __iterator(t,e){return new Ke(this,t,e)},Map.prototype.__iterate=function __iterate(t,e){var r=this,n=0;return this._root&&this._root.iterate((function(e){return n++,t(e[1],e[0],r)}),e),n},Map.prototype.__ensureOwner=function __ensureOwner(t){return t===this.__ownerID?this:t?Ue(this.size,this._root,t,this.__hash):0===this.size?Ge():(this.__ownerID=t,this.__altered=!1,this)},Map}(E);Re.isMap=ut;var Te=Re.prototype;Te[st]=!0,Te[n]=Te.remove,Te.removeAll=Te.deleteAll,Te.setIn=he,Te.removeIn=Te.deleteIn=ve,Te.update=ye,Te.updateIn=me,Te.merge=Te.concat=_e,Te.mergeWith=be,Te.mergeDeep=Ee,Te.mergeDeepWith=Oe,Te.mergeIn=Ce,Te.mergeDeepIn=ke,Te.withMutations=De,Te.wasAltered=Ae,Te.asImmutable=Ie,Te["@@transducer/init"]=Te.asMutable=Me,Te["@@transducer/step"]=function(t,e){return t.set(e[0],e[1])},Te["@@transducer/result"]=function(t){return t.asImmutable()};var ze=function ArrayMapNode(t,e){this.ownerID=t,this.entries=e};ze.prototype.get=function(t,e,r,n){for(var i=this.entries,o=0,a=i.length;o=Je)return function(t,e,r,n){t||(t=new OwnerID);for(var i=new je(t,vt(r),[r,n]),o=0;o>>t)&a),s=this.bitmap;return 0==(s&o)?n:this.nodes[Xe(s&o-1)].get(t+i,e,r,n)},Be.prototype.update=function(t,e,r,n,u,c,l){void 0===r&&(r=vt(n));var f=(0===e?r:r>>>e)&a,p=1<=Ze)return function(t,e,r,n,i){for(var a=0,s=new Array(o),u=0;0!==r;u++,r>>>=1)s[u]=1&r?e[a++]:void 0;return s[n]=i,new qe(t,a+1,s)}(t,g,h,f,m);if(d&&!m&&2===g.length&&Ve(g[1^v]))return g[1^v];if(d&&m&&1===g.length&&Ve(m))return m;var _=t&&t===this.ownerID,b=d?m?h:h^p:h|p,S=d?m?$e(g,v,m,_):function(t,e,r){var n=t.length-1;if(r&&e===n)return t.pop(),t;for(var i=new Array(n),o=0,a=0;a>>t)&a,s=this.nodes[o];return s?s.get(t+i,e,r,n):n},qe.prototype.update=function(t,e,r,n,o,u,c){void 0===r&&(r=vt(n));var l=(0===e?r:r>>>e)&a,f=o===s,p=this.nodes,h=p[l];if(f&&!h)return this;var d=We(h,t,e+i,r,n,o,u,c);if(d===h)return this;var v=this.count;if(h){if(!d&&--v>>r)&a,c=(0===r?n:n>>>r)&a,l=u===c?[Ye(t,e,r+i,n,o)]:(s=new je(e,n,o),u>1&1431655765))+(t>>2&858993459))+(t>>4)&252645135,t+=t>>8,127&(t+=t>>16)}function $e(t,e,r,n){var i=n?t:Jt(t);return i[e]=r,i}var Je=o/4,Ze=o/2,Qe=o/4,tr="@@__IMMUTABLE_LIST__@@";function er(t){return Boolean(t&&t[tr])}var rr=function(t){function List(e){var r=cr();if(null==e)return r;if(er(e))return e;var n=t(e),a=n.size;return 0===a?r:(Qt(a),a>0&&a=0&&t=t.size||e<0)return t.withMutations((function(t){e<0?hr(t,e).set(0,r):hr(t,0,e+1).set(e,r)}));e+=t._origin;var n=t._tail,i=t._root,o={value:!1};e>=dr(t._capacity)?n=lr(n,t.__ownerID,0,e,r,o):i=lr(i,t.__ownerID,t._level,e,r,o);if(!o.value)return t;if(t.__ownerID)return t._root=i,t._tail=n,t.__hash=void 0,t.__altered=!0,t;return ur(t._origin,t._capacity,t._level,i,n)}(this,t,e)},List.prototype.remove=function(t){return this.has(t)?0===t?this.shift():t===this.size-1?this.pop():this.splice(t,1):this},List.prototype.insert=function(t,e){return this.splice(t,0,e)},List.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=this._origin=this._capacity=0,this._level=i,this._root=this._tail=this.__hash=void 0,this.__altered=!0,this):cr()},List.prototype.push=function(){var t=arguments,e=this.size;return this.withMutations((function(r){hr(r,0,e+t.length);for(var n=0;n>>e&a;if(n>=this.array.length)return new ir([],t);var o,s=0===n;if(e>0){var u=this.array[n];if((o=u&&u.removeBefore(t,e-i,r))===u&&s)return this}if(s&&!o)return this;var c=fr(this,t);if(!s)for(var l=0;l>>e&a;if(o>=this.array.length)return this;if(e>0){var s=this.array[o];if((n=s&&s.removeAfter(t,e-i,r))===s&&o===this.array.length-1)return this}var u=fr(this,t);return u.array.splice(o+1),n&&(u.array[o]=n),u};var or,ar={};function sr(t,e){var r=t._origin,n=t._capacity,a=dr(n),s=t._tail;return u(t._root,t._level,0);function u(t,c,l){return 0===c?function(t,i){var u=i===a?s&&s.array:t&&t.array,c=i>r?0:r-i,l=n-i;l>o&&(l=o);return function(){if(c===l)return ar;var t=e?--l:c++;return u&&u[t]}}(t,l):function(t,a,s){var c,l=t&&t.array,f=s>r?0:r-s>>a,p=1+(n-s>>a);p>o&&(p=o);return function(){for(;;){if(c){var t=c();if(t!==ar)return t;c=null}if(f===p)return ar;var r=e?--p:f++;c=u(l&&l[r],a-i,s+(r<>>r&a,l=t&&c0){var f=t&&t.array[c],p=lr(f,e,r-i,n,o,s);return p===f?t:((u=fr(t,e)).array[c]=p,u)}return l&&t.array[c]===o?t:(s&&SetRef(s),u=fr(t,e),void 0===o&&c===u.array.length-1?u.array.pop():u.array[c]=o,u)}function fr(t,e){return e&&t&&e===t.ownerID?t:new ir(t?t.array.slice():[],e)}function pr(t,e){if(e>=dr(t._capacity))return t._tail;if(e<1<0;)r=r.array[e>>>n&a],n-=i;return r}}function hr(t,e,r){void 0!==e&&(e|=0),void 0!==r&&(r|=0);var n=t.__ownerID||new OwnerID,o=t._origin,s=t._capacity,u=o+e,c=void 0===r?s:r<0?s+r:o+r;if(u===o&&c===s)return t;if(u>=c)return t.clear();for(var l=t._level,f=t._root,p=0;u+p<0;)f=new ir(f&&f.array.length?[void 0,f]:[],n),p+=1<<(l+=i);p&&(u+=p,o+=p,c+=p,s+=p);for(var h=dr(s),d=dr(c);d>=1<h?new ir([],n):v;if(v&&d>h&&ui;m-=i){var _=h>>>m&a;y=y.array[_]=fr(y.array[_],n)}y.array[h>>>i&a]=v}if(c=d)u-=d,c-=d,l=i,f=null,g=g&&g.removeBefore(n,0,u);else if(u>o||d>>l&a;if(b!==d>>>l&a)break;b&&(p+=(1<o&&(f=f.removeBefore(n,l,u-p)),f&&d>>i<=o&&u.size>=2*a.size?(n=(i=u.filter((function(t,e){return void 0!==t&&c!==e}))).toKeyedSeq().map((function(t){return t[0]})).flip().toMap(),t.__ownerID&&(n.__ownerID=i.__ownerID=t.__ownerID)):(n=a.remove(e),i=c===u.size-1?u.pop():u.set(c,void 0))}else if(l){if(r===u.get(c)[1])return t;n=a,i=u.set(c,[e,r])}else n=a.set(e,u.size),i=u.set(u.size,[e,r]);return t.__ownerID?(t.size=n.size,t._map=n,t._list=i,t.__hash=void 0,t.__altered=!0,t):yr(n,i)}gr.isOrderedMap=ct,gr.prototype[R]=!0,gr.prototype[n]=gr.prototype.remove;var br="@@__IMMUTABLE_STACK__@@";function Sr(t){return Boolean(t&&t[br])}var wr=function(t){function Stack(t){return null==t?Cr():Sr(t)?t:Cr().pushAll(t)}return t&&(Stack.__proto__=t),Stack.prototype=Object.create(t&&t.prototype),Stack.prototype.constructor=Stack,Stack.of=function(){return this(arguments)},Stack.prototype.toString=function(){return this.__toString("Stack [","]")},Stack.prototype.get=function(t,e){var r=this._head;for(t=c(this,t);r&&t--;)r=r.next;return r?r.value:e},Stack.prototype.peek=function(){return this._head&&this._head.value},Stack.prototype.push=function(){var t=arguments;if(0===arguments.length)return this;for(var e=this.size+arguments.length,r=this._head,n=arguments.length-1;n>=0;n--)r={value:t[n],next:r};return this.__ownerID?(this.size=e,this._head=r,this.__hash=void 0,this.__altered=!0,this):Or(e,r)},Stack.prototype.pushAll=function(e){if(0===(e=t(e)).size)return this;if(0===this.size&&Sr(e))return e;Qt(e.size);var r=this.size,n=this._head;return e.__iterate((function(t){r++,n={value:t,next:n}}),!0),this.__ownerID?(this.size=r,this._head=n,this.__hash=void 0,this.__altered=!0,this):Or(r,n)},Stack.prototype.pop=function(){return this.slice(1)},Stack.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):Cr()},Stack.prototype.slice=function(e,r){if(f(e,r,this.size))return this;var n=p(e,this.size);if(h(r,this.size)!==this.size)return t.prototype.slice.call(this,e,r);for(var i=this.size-n,o=this._head;n--;)o=o.next;return this.__ownerID?(this.size=i,this._head=o,this.__hash=void 0,this.__altered=!0,this):Or(i,o)},Stack.prototype.__ensureOwner=function __ensureOwner(t){return t===this.__ownerID?this:t?Or(this.size,this._head,t,this.__hash):0===this.size?Cr():(this.__ownerID=t,this.__altered=!1,this)},Stack.prototype.__iterate=function __iterate(t,e){var r=this;if(e)return new Q(this.toArray()).__iterate((function(e,n){return t(e,n,r)}),e);for(var n=0,i=this._head;i&&!1!==t(i.value,n++,this);)i=i.next;return n},Stack.prototype.__iterator=function __iterator(t,e){if(e)return new Q(this.toArray()).__iterator(t,e);var r=0,n=this._head;return new K((function(){if(n){var e=n.value;return n=n.next,N(t,r++,e)}return{value:void 0,done:!0}}))},Stack}(O);wr.isStack=Sr;var xr,Er=wr.prototype;function Or(t,e,r,n){var i=Object.create(Er);return i.size=t,i._head=e,i.__ownerID=r,i.__hash=n,i.__altered=!1,i}function Cr(){return xr||(xr=Or(0))}Er[br]=!0,Er.shift=Er.pop,Er.unshift=Er.push,Er.unshiftAll=Er.pushAll,Er.withMutations=De,Er.wasAltered=Ae,Er.asImmutable=Ie,Er["@@transducer/init"]=Er.asMutable=Me,Er["@@transducer/step"]=function(t,e){return t.unshift(e)},Er["@@transducer/result"]=function(t){return t.asImmutable()};var kr="@@__IMMUTABLE_SET__@@";function Dr(t){return Boolean(t&&t[kr])}function Mr(t){return Dr(t)&&T(t)}function Ir(t,e){if(t===e)return!0;if(!y(e)||void 0!==t.size&&void 0!==e.size&&t.size!==e.size||void 0!==t.__hash&&void 0!==e.__hash&&t.__hash!==e.__hash||_(t)!==_(e)||S(t)!==S(e)||T(t)!==T(e))return!1;if(0===t.size&&0===e.size)return!0;var r=!w(t);if(T(t)){var n=t.entries();return e.every((function(t,e){var i=n.next().value;return i&&ft(i[1],t)&&(r||ft(i[0],e))}))&&n.next().done}var i=!1;if(void 0===t.size)if(void 0===e.size)"function"==typeof t.cacheResult&&t.cacheResult();else{i=!0;var o=t;t=e,e=o}var a=!0,u=e.__iterate((function(e,n){if(r?!t.has(e):i?!ft(e,t.get(n,s)):!ft(t.get(n,s),e))return a=!1,!1}));return a&&t.size===u}function Ar(t,e){var r=function(r){t.prototype[r]=e[r]};return Object.keys(e).forEach(r),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(e).forEach(r),t}function Rr(t){if(!t||"object"!=typeof t)return t;if(!y(t)){if(!ne(t))return t;t=X(t)}if(_(t)){var e={};return t.__iterate((function(t,r){e[r]=Rr(t)})),e}var r=[];return t.__iterate((function(t){r.push(Rr(t))})),r}var Tr=function(t){function Set(e){return null==e?jr():Dr(e)&&!T(e)?e:jr().withMutations((function(r){var n=t(e);Qt(n.size),n.forEach((function(t){return r.add(t)}))}))}return t&&(Set.__proto__=t),Set.prototype=Object.create(t&&t.prototype),Set.prototype.constructor=Set,Set.of=function(){return this(arguments)},Set.fromKeys=function(t){return this(E(t).keySeq())},Set.intersect=function(t){return(t=x(t).toArray()).length?Br.intersect.apply(Set(t.pop()),t):jr()},Set.union=function(t){return(t=x(t).toArray()).length?Br.union.apply(Set(t.pop()),t):jr()},Set.prototype.toString=function(){return this.__toString("Set {","}")},Set.prototype.has=function(t){return this._map.has(t)},Set.prototype.add=function(t){return qr(this,this._map.set(t,t))},Set.prototype.remove=function(t){return qr(this,this._map.remove(t))},Set.prototype.clear=function(){return qr(this,this._map.clear())},Set.prototype.map=function(t,e){var r=this,n=!1,i=qr(this,this._map.mapEntries((function(i){var o=i[1],a=t.call(e,o,o,r);return a!==o&&(n=!0),[a,a]}),e));return n?i:this},Set.prototype.union=function(){for(var e=[],r=arguments.length;r--;)e[r]=arguments[r];return 0===(e=e.filter((function(t){return 0!==t.size}))).length?this:0!==this.size||this.__ownerID||1!==e.length?this.withMutations((function(r){for(var n=0;n=0&&e=0&&r>>-15,461845907),e=pt(e<<13|e>>>-13,5),e=(e+3864292196|0)^t,e=pt(e^e>>>16,2246822507),e=pt(e^e>>>13,3266489909),e=ht(e^e>>>16),e}(t.__iterate(r?e?function(t,e){n=31*n+rn(vt(t),vt(e))|0}:function(t,e){n=n+rn(vt(t),vt(e))|0}:e?function(t){n=31*n+vt(t)|0}:function(t){n=n+vt(t)|0}),n)}(this))}});var Hr=x.prototype;Hr[g]=!0,Hr[L]=Hr.values,Hr.toJSON=Hr.toArray,Hr.__toStringMapper=ie,Hr.inspect=Hr.toSource=function(){return this.toString()},Hr.chain=Hr.flatMap,Hr.contains=Hr.includes,Ar(E,{flip:function(){return Ht(this,zt(this))},mapEntries:function(t,e){var r=this,n=0;return Ht(this,this.toSeq().map((function(i,o){return t.call(e,[o,i],n++,r)})).fromEntrySeq())},mapKeys:function(t,e){var r=this;return Ht(this,this.toSeq().flip().map((function(n,i){return t.call(e,n,i,r)})).flip())}});var Wr=E.prototype;Wr[m]=!0,Wr[L]=Hr.entries,Wr.toJSON=Gr,Wr.__toStringMapper=function(t,e){return ie(e)+": "+ie(t)},Ar(O,{toKeyedSeq:function(){return new It(this,!1)},filter:function(t,e){return Ht(this,Pt(this,t,e,!1))},findIndex:function(t,e){var r=this.findEntry(t,e);return r?r[0]:-1},indexOf:function(t){var e=this.keyOf(t);return void 0===e?-1:e},lastIndexOf:function(t){var e=this.lastKeyOf(t);return void 0===e?-1:e},reverse:function(){return Ht(this,qt(this,!1))},slice:function(t,e){return Ht(this,jt(this,t,e,!1))},splice:function(t,e){var r=arguments.length;if(e=Math.max(e||0,0),0===r||2===r&&!e)return this;t=p(t,t<0?this.count():this.size);var n=this.slice(0,t);return Ht(this,1===r?n:n.concat(Jt(arguments,2),this.slice(t+e)))},findLastIndex:function(t,e){var r=this.findLastEntry(t,e);return r?r[0]:-1},first:function(t){return this.get(0,t)},flatten:function(t){return Ht(this,Kt(this,t,!1))},get:function(t,e){return(t=c(this,t))<0||this.size===1/0||void 0!==this.size&&t>this.size?e:this.find((function(e,r){return r===t}),void 0,e)},has:function(t){return(t=c(this,t))>=0&&(void 0!==this.size?this.size===1/0||te?-1:0}function rn(t,e){return t^e+2654435769+(t<<6)+(t>>2)|0}Yr.has=Hr.includes,Yr.contains=Yr.includes,Yr.keys=Yr.values,Ar($,Wr),Ar(J,Vr),Ar(Z,Yr);var nn=function(t){function OrderedSet(t){return null==t?un():Mr(t)?t:un().withMutations((function(e){var r=C(t);Qt(r.size),r.forEach((function(t){return e.add(t)}))}))}return t&&(OrderedSet.__proto__=t),OrderedSet.prototype=Object.create(t&&t.prototype),OrderedSet.prototype.constructor=OrderedSet,OrderedSet.of=function(){return this(arguments)},OrderedSet.fromKeys=function(t){return this(E(t).keySeq())},OrderedSet.prototype.toString=function(){return this.__toString("OrderedSet {","}")},OrderedSet}(Tr);nn.isOrderedSet=Mr;var on,an=nn.prototype;function sn(t,e){var r=Object.create(an);return r.size=t?t.size:0,r._map=t,r.__ownerID=e,r}function un(){return on||(on=sn(mr()))}an[R]=!0,an.zip=Vr.zip,an.zipWith=Vr.zipWith,an.zipAll=Vr.zipAll,an.__empty=un,an.__make=sn;var cn=function Record(t,e){var r;!function(t){if(I(t))throw new Error("Can not call `Record` with an immutable Record as default values. Use a plain javascript object instead.");if(A(t))throw new Error("Can not call `Record` with an immutable Collection as default values. Use a plain javascript object instead.");if(null===t||"object"!=typeof t)throw new Error("Can not call `Record` with a non-object as default values. Use a plain javascript object instead.")}(t);var n=function Record(o){var a=this;if(o instanceof n)return o;if(!(this instanceof n))return new n(o);if(!r){r=!0;var s=Object.keys(t),u=i._indices={};i._name=e,i._keys=s,i._defaultValues=t;for(var c=0;c{"use strict";r.d(e,{parseToRgb:()=>_,readableColor:()=>D,rgbToColorString:()=>M,rgba:()=>x});var n=r(97326),i=r(94578),o=r(52146);var a=function(t){function PolishedError(e){var r;return r=t.call(this,"An error occurred. See https://github.com/styled-components/polished/blob/main/src/internalHelpers/errors.md#"+e+" for more information.")||this,(0,n.default)(r)}return(0,i.default)(PolishedError,t),PolishedError}((0,o.default)(Error));function s(t){return Math.round(255*t)}function u(t,e,r){return s(t)+","+s(e)+","+s(r)}function c(t,e,r,n){if(void 0===n&&(n=u),0===e)return n(r,r,r);var i=(t%360+360)%360/60,o=(1-Math.abs(2*r-1))*e,a=o*(1-Math.abs(i%2-1)),s=0,c=0,l=0;i>=0&&i<1?(s=o,c=a):i>=1&&i<2?(s=a,c=o):i>=2&&i<3?(c=o,l=a):i>=3&&i<4?(c=a,l=o):i>=4&&i<5?(s=a,l=o):i>=5&&i<6&&(s=o,l=a);var f=r-o/2;return n(s+f,c+f,l+f)}var l={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};var f=/^#[a-fA-F0-9]{6}$/,p=/^#[a-fA-F0-9]{8}$/,h=/^#[a-fA-F0-9]{3}$/,d=/^#[a-fA-F0-9]{4}$/,v=/^rgb\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*\)$/i,g=/^rgb(?:a)?\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i,y=/^hsl\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*\)$/i,m=/^hsl(?:a)?\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i;function _(t){if("string"!=typeof t)throw new a(3);var e=function(t){if("string"!=typeof t)return t;var e=t.toLowerCase();return l[e]?"#"+l[e]:t}(t);if(e.match(f))return{red:parseInt(""+e[1]+e[2],16),green:parseInt(""+e[3]+e[4],16),blue:parseInt(""+e[5]+e[6],16)};if(e.match(p)){var r=parseFloat((parseInt(""+e[7]+e[8],16)/255).toFixed(2));return{red:parseInt(""+e[1]+e[2],16),green:parseInt(""+e[3]+e[4],16),blue:parseInt(""+e[5]+e[6],16),alpha:r}}if(e.match(h))return{red:parseInt(""+e[1]+e[1],16),green:parseInt(""+e[2]+e[2],16),blue:parseInt(""+e[3]+e[3],16)};if(e.match(d)){var n=parseFloat((parseInt(""+e[4]+e[4],16)/255).toFixed(2));return{red:parseInt(""+e[1]+e[1],16),green:parseInt(""+e[2]+e[2],16),blue:parseInt(""+e[3]+e[3],16),alpha:n}}var i=v.exec(e);if(i)return{red:parseInt(""+i[1],10),green:parseInt(""+i[2],10),blue:parseInt(""+i[3],10)};var o=g.exec(e.substring(0,50));if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10),alpha:parseFloat(""+o[4])>1?parseFloat(""+o[4])/100:parseFloat(""+o[4])};var s=y.exec(e);if(s){var u="rgb("+c(parseInt(""+s[1],10),parseInt(""+s[2],10)/100,parseInt(""+s[3],10)/100)+")",_=v.exec(u);if(!_)throw new a(4,e,u);return{red:parseInt(""+_[1],10),green:parseInt(""+_[2],10),blue:parseInt(""+_[3],10)}}var b=m.exec(e.substring(0,50));if(b){var S="rgb("+c(parseInt(""+b[1],10),parseInt(""+b[2],10)/100,parseInt(""+b[3],10)/100)+")",w=v.exec(S);if(!w)throw new a(4,e,S);return{red:parseInt(""+w[1],10),green:parseInt(""+w[2],10),blue:parseInt(""+w[3],10),alpha:parseFloat(""+b[4])>1?parseFloat(""+b[4])/100:parseFloat(""+b[4])}}throw new a(5)}var b=function(t){return 7===t.length&&t[1]===t[2]&&t[3]===t[4]&&t[5]===t[6]?"#"+t[1]+t[3]+t[5]:t};function S(t){var e=t.toString(16);return 1===e.length?"0"+e:e}function w(t,e,r){if("number"==typeof t&&"number"==typeof e&&"number"==typeof r)return b("#"+S(t)+S(e)+S(r));if("object"==typeof t&&void 0===e&&void 0===r)return b("#"+S(t.red)+S(t.green)+S(t.blue));throw new a(6)}function x(t,e,r,n){if("string"==typeof t&&"number"==typeof e){var i=_(t);return"rgba("+i.red+","+i.green+","+i.blue+","+e+")"}if("number"==typeof t&&"number"==typeof e&&"number"==typeof r&&"number"==typeof n)return n>=1?w(t,e,r):"rgba("+t+","+e+","+r+","+n+")";if("object"==typeof t&&void 0===e&&void 0===r&&void 0===n)return t.alpha>=1?w(t.red,t.green,t.blue):"rgba("+t.red+","+t.green+","+t.blue+","+t.alpha+")";throw new a(7)}function E(t){if("transparent"===t)return 0;var e=_(t),r=Object.keys(e).map((function(t){var r=e[t]/255;return r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4)})),n=r[0],i=r[1],o=r[2];return parseFloat((.2126*n+.7152*i+.0722*o).toFixed(3))}function O(t,e){var r=E(t),n=E(e);return parseFloat((r>n?(r+.05)/(n+.05):(n+.05)/(r+.05)).toFixed(2))}var C="#000",k="#fff";function D(t,e,r,n){void 0===e&&(e=C),void 0===r&&(r=k),void 0===n&&(n=!0);var i=E(t)>.179,o=i?e:r;return!n||O(t,o)>=4.5?o:i?C:k}function M(t){if("object"==typeof t&&"number"==typeof t.red&&"number"==typeof t.green&&"number"==typeof t.blue)return"number"==typeof t.alpha?x({red:t.red,green:t.green,blue:t.blue,alpha:t.alpha}):w({red:t.red,green:t.green,blue:t.blue});throw new a(46)}},38698:(t,e,r)=>{"use strict";var n=r(27418),i=r(67294);function o(t){for(var e="https://reactjs.org/docs/error-decoder.html?invariant="+t,r=1;rD;D++)k[D]=D+1;k[15]=0;var M=/^[: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][: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\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,I=Object.prototype.hasOwnProperty,A={},R={};function T(t){return!!I.call(R,t)||!I.call(A,t)&&(M.test(t)?R[t]=!0:(A[t]=!0,!1))}function z(t,e,r,n,i,o,a){this.acceptsBooleans=2===e||3===e||4===e,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=t,this.type=e,this.sanitizeURL=o,this.removeEmptyString=a}var B={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(t){B[t]=new z(t,0,!1,t,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(t){var e=t[0];B[e]=new z(e,1,!1,t[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(t){B[t]=new z(t,2,!1,t.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(t){B[t]=new z(t,2,!1,t,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(t){B[t]=new z(t,3,!1,t.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(t){B[t]=new z(t,3,!0,t,null,!1,!1)})),["capture","download"].forEach((function(t){B[t]=new z(t,4,!1,t,null,!1,!1)})),["cols","rows","size","span"].forEach((function(t){B[t]=new z(t,6,!1,t,null,!1,!1)})),["rowSpan","start"].forEach((function(t){B[t]=new z(t,5,!1,t.toLowerCase(),null,!1,!1)}));var q=/[\-:]([a-z])/g;function P(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(t){var e=t.replace(q,P);B[e]=new z(e,1,!1,t,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(t){var e=t.replace(q,P);B[e]=new z(e,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(t){var e=t.replace(q,P);B[e]=new z(e,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(t){B[t]=new z(t,1,!1,t.toLowerCase(),null,!1,!1)})),B.xlinkHref=new z("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(t){B[t]=new z(t,1,!1,t.toLowerCase(),null,!0,!0)}));var j=/["'&<>]/;function L(t){if("boolean"==typeof t||"number"==typeof t)return""+t;t=""+t;var e=j.exec(t);if(e){var r,n="",i=0;for(r=e.index;re}return!1}(t,e,n,!1)?"":null!==n?(t=n.attributeName,3===(r=n.type)||4===r&&!0===e?t+'=""':(n.sanitizeURL&&(e=""+e),t+'="'+L(e)+'"')):T(t)?t+'="'+L(e)+'"':""}var N="function"==typeof Object.is?Object.is:function(t,e){return t===e&&(0!==t||1/t==1/e)||t!=t&&e!=e},F=null,U=null,G=null,H=!1,W=!1,V=null,Y=0;function X(){if(null===F)throw Error(o(321));return F}function Ba(){if(0Y))throw Error(o(301));if(t===F)if(W=!0,t={action:r,next:null},null===V&&(V=new Map),void 0===(r=V.get(e)))V.set(e,t);else{for(e=r;null!==e.next;)e=e.next;e.next=t}}function Ja(){}var $=null,J={readContext:function(t){var e=$.threadID;return C(t,e),t[e]},useContext:function(t){X();var e=$.threadID;return C(t,e),t[e]},useMemo:Ia,useReducer:Ga,useRef:function(t){F=X();var e=(G=Ca()).memoizedState;return null===e?(t={current:t},G.memoizedState=t):e},useState:function(t){return Ga(Fa,t)},useLayoutEffect:function(){},useCallback:function(t,e){return Ia((function(){return t}),e)},useImperativeHandle:Ja,useEffect:Ja,useDebugValue:Ja,useDeferredValue:function(t){return X(),t},useTransition:function(){return X(),[function(t){t()},!1]},useOpaqueIdentifier:function(){return($.identifierPrefix||"")+"R:"+($.uniqueID++).toString(36)},useMutableSource:function(t,e){return X(),e(t._source)}},Z="http://www.w3.org/1999/xhtml";function Ma(t){switch(t){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}var Q={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},tt=n({menuitem:!0},Q),et={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},rt=["Webkit","ms","Moz","O"];Object.keys(et).forEach((function(t){rt.forEach((function(e){e=e+t.charAt(0).toUpperCase()+t.substring(1),et[e]=et[t]}))}));var nt=/([A-Z])/g,it=/^ms-/,ot=i.Children.toArray,at=E.ReactCurrentDispatcher,st={listing:!0,pre:!0,textarea:!0},ut=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,ct={},lt={};var ft=Object.prototype.hasOwnProperty,pt={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null,suppressHydrationWarning:null};function ht(t,e){if(void 0===t)throw Error(o(152,x(e)||"Component"))}function dt(t,e,r){function a(i,a){var s=a.prototype&&a.prototype.isReactComponent,u=function(t,e,r,n){if(n&&"object"==typeof(n=t.contextType)&&null!==n)return C(n,r),n[r];if(t=t.contextTypes){for(var i in r={},t)r[i]=e[i];e=r}else e=O;return e}(a,e,r,s),c=[],l=!1,f={isMounted:function(){return!1},enqueueForceUpdate:function(){if(null===c)return null},enqueueReplaceState:function(t,e){l=!0,c=[e]},enqueueSetState:function(t,e){if(null===c)return null;c.push(e)}};if(s){if(s=new a(i.props,u,f),"function"==typeof a.getDerivedStateFromProps){var p=a.getDerivedStateFromProps.call(null,i.props,s.state);null!=p&&(s.state=n({},s.state,p))}}else if(F={},s=a(i.props,u,f),null==(s=Da(a,i.props,s,u))||null==s.render)return void ht(t=s,a);if(s.props=i.props,s.context=u,s.updater=f,void 0===(f=s.state)&&(s.state=f=null),"function"==typeof s.UNSAFE_componentWillMount||"function"==typeof s.componentWillMount)if("function"==typeof s.componentWillMount&&"function"!=typeof a.getDerivedStateFromProps&&s.componentWillMount(),"function"==typeof s.UNSAFE_componentWillMount&&"function"!=typeof a.getDerivedStateFromProps&&s.UNSAFE_componentWillMount(),c.length){f=c;var h=l;if(c=null,l=!1,h&&1===f.length)s.state=f[0];else{p=h?f[0]:s.state;var d=!0;for(h=h?1:0;h=u))throw Error(o(304));var c=new Uint16Array(u);for(c.set(a),(k=c)[0]=n+1,a=n;a=s.children.length){var u=s.footer;if(""!==u&&(this.previousWasTextNode=!1),this.stack.pop(),"select"===s.type)this.currentSelectValue=null;else if(null!=s.type&&null!=s.type.type&&s.type.type.$$typeof===l)this.popProvider(s.type);else if(s.type===h){this.suspenseDepth--;var c=n.pop();if(i){i=!1;var f=s.fallbackFrame;if(!f)throw Error(o(303));this.stack.push(f),n[this.suspenseDepth]+="\x3c!--$!--\x3e";continue}n[this.suspenseDepth]+=c}n[this.suspenseDepth]+=u}else{var p=s.children[s.childIndex++],d="";try{d+=this.render(p,s.context,s.domNamespace)}catch(t){if(null!=t&&"function"==typeof t.then)throw Error(o(294));throw t}n.length<=this.suspenseDepth&&n.push(""),n[this.suspenseDepth]+=d}}return n[0]}finally{at.current=r,$=e,Ea()}},e.render=function(t,e,r){if("string"==typeof t||"number"==typeof t)return""===(r=""+t)?"":this.makeStaticMarkup?L(r):this.previousWasTextNode?"\x3c!-- --\x3e"+L(r):(this.previousWasTextNode=!0,L(r));if(t=(e=dt(t,e,this.threadID)).child,e=e.context,null===t||!1===t)return"";if(!i.isValidElement(t)){if(null!=t&&null!=t.$$typeof){if((r=t.$$typeof)===a)throw Error(o(257));throw Error(o(258,r.toString()))}return t=ot(t),this.stack.push({type:null,domNamespace:r,children:t,childIndex:0,context:e,footer:""}),""}var y=t.type;if("string"==typeof y)return this.renderDOM(t,e,r);switch(y){case S:case b:case u:case c:case d:case s:return t=ot(t.props.children),this.stack.push({type:null,domNamespace:r,children:t,childIndex:0,context:e,footer:""}),"";case h:throw Error(o(294));case _:throw Error(o(343))}if("object"==typeof y&&null!==y)switch(y.$$typeof){case p:F={};var w=y.render(t.props,t.ref);return w=Da(y.render,t.props,w,t.ref),w=ot(w),this.stack.push({type:null,domNamespace:r,children:w,childIndex:0,context:e,footer:""}),"";case v:return t=[i.createElement(y.type,n({ref:t.ref},t.props))],this.stack.push({type:null,domNamespace:r,children:t,childIndex:0,context:e,footer:""}),"";case l:return r={type:t,domNamespace:r,children:y=ot(t.props.children),childIndex:0,context:e,footer:""},this.pushProvider(t),this.stack.push(r),"";case f:y=t.type,w=t.props;var x=this.threadID;return C(y,x),y=ot(w.children(y[x])),this.stack.push({type:t,domNamespace:r,children:y,childIndex:0,context:e,footer:""}),"";case m:throw Error(o(338));case g:return y=(w=(y=t.type)._init)(y._payload),t=[i.createElement(y,n({ref:t.ref},t.props))],this.stack.push({type:null,domNamespace:r,children:t,childIndex:0,context:e,footer:""}),""}throw Error(o(130,null==y?y:typeof y,""))},e.renderDOM=function(t,e,r){var a=t.type.toLowerCase();if(r===Z&&Ma(a),!ct.hasOwnProperty(a)){if(!ut.test(a))throw Error(o(65,a));ct[a]=!0}var s=t.props;if("input"===a)s=n({type:void 0},s,{defaultChecked:void 0,defaultValue:void 0,value:null!=s.value?s.value:s.defaultValue,checked:null!=s.checked?s.checked:s.defaultChecked});else if("textarea"===a){var u=s.value;if(null==u){u=s.defaultValue;var c=s.children;if(null!=c){if(null!=u)throw Error(o(92));if(Array.isArray(c)){if(!(1>=c.length))throw Error(o(93));c=c[0]}u=""+c}null==u&&(u="")}s=n({},s,{value:void 0,children:""+u})}else if("select"===a)this.currentSelectValue=null!=s.value?s.value:s.defaultValue,s=n({},s,{value:void 0});else if("option"===a){c=this.currentSelectValue;var l=function Xa(t){if(null==t)return t;var e="";return i.Children.forEach(t,(function(t){null!=t&&(e+=t)})),e}(s.children);if(null!=c){var f=null!=s.value?s.value+"":l;if(u=!1,Array.isArray(c)){for(var p=0;p":(S+=">",u="");t:{if(null!=(c=s.dangerouslySetInnerHTML)){if(null!=c.__html){c=c.__html;break t}}else if("string"==typeof(c=s.children)||"number"==typeof c){c=L(c);break t}c=null}return null!=c?(s=[],st.hasOwnProperty(a)&&"\n"===c.charAt(0)&&(S+="\n"),S+=c):s=ot(s.children),t=t.type,r=null==r||"http://www.w3.org/1999/xhtml"===r?Ma(t):"http://www.w3.org/2000/svg"===r&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":r,this.stack.push({domNamespace:r,type:a,children:s,childIndex:0,context:e,footer:u}),this.previousWasTextNode=!1,S},t}();e.renderToStaticMarkup=function(t,e){t=new vt(t,!0,e);try{return t.read(1/0)}finally{t.destroy()}}},73935:(t,e,r)=>{"use strict";!function t(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(t){console.error(t)}}(),t.exports=r(64448)},97762:(t,e,r)=>{"use strict";t.exports=r(38698)},29154:(t,e,r)=>{"use strict";function n(t,e){for(var r=t.length,n=0;nbs});var p=[{test:"phantomjs",id:"phantomjs"},{test:"whale",id:"whale"},{test:"edgios|edge|edg",id:"edge"},{test:"msie|trident|windows phone",id:"ie",versionTest:"iemobile|msie|rv"},{test:"miuibrowser",id:"miui browser"},{test:"samsungbrowser",id:"samsung internet"},{test:"samsung",id:"samsung internet",versionTest:"version"},{test:"chrome|crios",id:"chrome"},{test:"firefox|fxios",id:"firefox"},{test:"android",id:"android browser",versionTest:"version"},{test:"safari|iphone|ipad|ipod",id:"safari",versionTest:"version"}],h=[{test:"(?=.*applewebkit/(53[0-7]|5[0-2]|[0-4]))(?=.*\\schrome)",id:"chrome",versionTest:"chrome"},{test:"chromium",id:"chrome"},{test:"whale",id:"chrome",versionAlias:"-1",brand:!0}],d=[{test:"applewebkit",id:"webkit",versionTest:"applewebkit|safari"}],v=[{test:"(?=(iphone|ipad))(?!(.*version))",id:"webview"},{test:"(?=(android|iphone|ipad))(?=.*(naver|daum|; wv))",id:"webview"},{test:"webview",id:"webview"}],g=[{test:"windows phone",id:"windows phone"},{test:"windows 2000",id:"window",versionAlias:"5.0"},{test:"windows nt",id:"window"},{test:"win32|windows",id:"window"},{test:"iphone|ipad|ipod",id:"ios",versionTest:"iphone os|cpu os"},{test:"macos|macintel|mac os x",id:"mac"},{test:"android|linux armv81",id:"android"},{test:"tizen",id:"tizen"},{test:"webos|web0s",id:"webos"}];function y(t){return!!c(v,t).preset}function m(t){var e=navigator.userAgentData,r=(e.uaList||e.brands).slice(),a=t&&t.fullVersionList,s=e.mobile||!1,c=r[0],m=(t&&t.platform||e.platform||navigator.platform).toLowerCase(),_={name:c.brand,version:c.version,majorVersion:-1,webkit:!1,webkitVersion:"-1",chromium:!1,chromiumVersion:"-1",webview:!!l(v,r).brand||y(o())},b={name:"unknown",version:"-1",majorVersion:-1};_.webkit=!_.chromium&&n(d,(function(t){return f(r,t)}));var S=l(h,r);if(_.chromium=!!S.brand,_.chromiumVersion=S.version,!_.chromium){var w=l(d,r);_.webkit=!!w.brand,_.webkitVersion=w.version}var x=i(g,(function(t){return new RegExp(""+t.test,"g").exec(m)}));if(b.name=x?x.id:"",t&&(b.version=t.platformVersion),a&&a.length){var E=l(p,a);_.name=E.brand||_.name,_.version=E.version||_.version}else{var O=l(p,r);_.name=O.brand||_.name,_.version=O.brand&&t?t.uaFullVersion:O.version}return _.webkit&&(b.name=s?"ios":"mac"),"ios"===b.name&&_.webview&&(_.version="-1"),b.version=u(b.version),_.version=u(_.version),b.majorVersion=parseInt(b.version,10),_.majorVersion=parseInt(_.version,10),{browser:_,os:b,isMobile:s,isHints:!0}}function _(t){return void 0===t&&s()?m():function(t){var e=o(t),r=!!/mobi/g.exec(e),n={name:"unknown",version:"-1",majorVersion:-1,webview:y(e),chromium:!1,chromiumVersion:"-1",webkit:!1,webkitVersion:"-1"},i={name:"unknown",version:"-1",majorVersion:-1},a=c(p,e),s=a.preset,u=a.version,l=c(g,e),f=l.preset,v=l.version,m=c(h,e);if(n.chromium=!!m.preset,n.chromiumVersion=m.version,!n.chromium){var _=c(d,e);n.webkit=!!_.preset,n.webkitVersion=_.version}return f&&(i.name=f.id,i.version=v,i.majorVersion=parseInt(v,10)),s&&(n.name=s.id,n.version=u,n.webview&&"ios"===i.name&&"safari"!==n.name&&(n.webview=!1)),n.majorVersion=parseInt(n.version,10),{browser:n,os:i,isMobile:r,isHints:!1}}(t)}const b=_;function S(t){for(var e=[],r=1;r-1?t[n]:r}var J=function(){var t=Y(),e=M&&(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame);return e?e.bind(window):function(e){var r=Y();return setTimeout((function(){e(r-t)}),1e3/60)}}(),Z=function(){var t=M&&(window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||window.msCancelAnimationFrame);return t?t.bind(window):function(t){clearTimeout(t)}}();function Q(t){return Object.keys(t)}function tt(t,e){var r=V(t),n=r.value,i=r.unit;if(q(e)){var o=e[i];if(o){if(K(o))return o(n);if(T[i])return T[i](n,o)}}else if("%"===i)return n*e/100;return T[i]?T[i](n):n}function et(t,e,r){return Math.max(e,Math.min(t,r))}function rt(t,e,r,n){return void 0===n&&(n=t[0]/t[1]),[[ut(e[0],R),ut(e[0]/n,R)],[ut(e[1]*n,R),ut(e[1],R)]].filter((function(t){return t.every((function(t,n){var i=e[n],o=ut(i,R);return r?t<=i||t<=o:t>=i||t>=o}))}))[0]||t}function nt(t,e,r,n){if(!n)return t.map((function(t,n){return et(t,e[n],r[n])}));var i=t[0],o=t[1],a=!0===n?i/o:n,s=rt(t,e,!1,a),u=s[0],c=s[1],l=rt(t,r,!0,a),f=l[0],p=l[1];return if||o>p)&&(i=f,o=p),[i,o]}function it(t){for(var e=t.length,r=0,n=e-1;n>=0;--n)r+=t[n];return e?r/e:0}function ot(t,e){var r=e[0]-t[0],n=e[1]-t[1],i=Math.atan2(n,r);return i>=0?i:i+2*Math.PI}function at(t){var e=function(t){return[0,1].map((function(e){return it(t.map((function(t){return t[e]})))}))}(t),r=ot(e,t[0]),n=ot(e,t[1]);return rn&&n-r<-Math.PI?1:-1}function st(t,e){return Math.sqrt(Math.pow((e?e[0]:0)-t[0],2)+Math.pow((e?e[1]:0)-t[1],2))}function ut(t,e){if(!e)return t;var r=1/e;return Math.round(t/e)/r}function ct(t,e){return t.forEach((function(r,n){t[n]=ut(t[n],e)})),t}function lt(t,e){return t.classList?t.classList.contains(e):!!t.className.match(new RegExp("(\\s|^)"+e+"(\\s|$)"))}function ft(t,e){t.classList?t.classList.add(e):t.className+=" "+e}function pt(t,e){if(t.classList)t.classList.remove(e);else{var r=new RegExp("(\\s|^)"+e+"(\\s|$)");t.className=t.className.replace(r," ")}}function ht(t,e,r,n){t.addEventListener(e,r,n)}function dt(t,e,r,n){t.removeEventListener(e,r,n)}function vt(t){return(null==t?void 0:t.ownerDocument)||I}function gt(t){return vt(t).documentElement}function yt(t){return vt(t).body}function mt(t){var e;return(null===(e=null==t?void 0:t.ownerDocument)||void 0===e?void 0:e.defaultView)||window}function _t(t){return t&&"postMessage"in t&&"blur"in t&&"self"in t}function bt(t){return q(t)&&t.nodeName&&t.nodeType&&"ownerDocument"in t}function St(t,e,r,n,i,o){for(var a=0;a-1&&n.splice(i,1)}}else this._events[t]=[];else this._events={};return this},t.once=function(t,e){var r=this;return e&&this._addEvent(t,e,{once:!0}),new Promise((function(e){r._addEvent(t,e,{once:!0})}))},t.emit=function(t,e){var r=this;void 0===e&&(e={});var n=this._events[t];if(!t||!n)return!0;var i=!1;return e.eventType=t,e.stop=function(){i=!0},e.currentTarget=this,function(){for(var t=0,e=0,r=arguments.length;en-o?(s[1]>a.top||ns[1])&&(u[1]=1),a.left>r-o?(s[0]>a.left||rs[0])&&(u[0]=1),!(!u[0]&&!u[1])&&this._continueDrag(le(le({},e),{direction:u,inputEvent:t,isDrag:!0}))}},e.checkScroll=function(t){var e=this;if(this._isWait)return!1;var r=t.prevScrollPos,n=void 0===r?this._prevScrollPos:r,i=t.direction,o=t.throttleTime,a=void 0===o?0:o,s=t.inputEvent,u=t.isDrag,c=this._getScrollPosition(i||[0,0],t),l=c[0]-n[0],f=c[1]-n[1],p=i||[l?Math.abs(l)/l:0,f?Math.abs(f)/f:0];return this._prevScrollPos=c,this._lock=!1,!(!l&&!f)&&(this.emit("move",{offsetX:p[0]?l:0,offsetY:p[1]?f:0,inputEvent:s}),a&&u&&(clearTimeout(this._timer),this._timer=window.setTimeout((function(){e._continueDrag(t)}),a)),!0)},e.dragEnd=function(){this._flag=!1,this._lock=!1,clearTimeout(this._timer),this._unregisterScrollEvent()},e._getScrollPosition=function(t,e){var r=e.container,n=e.getScrollPosition;return(void 0===n?fe:n)({container:he(r),direction:t})},e._continueDrag=function(t){var e,r=this,n=t.container,i=t.direction,o=t.throttleTime,a=t.useScroll,s=t.isDrag,u=t.inputEvent;if(!(!this._flag||s&&this._isWait)){var c=Y(),l=Math.max(o+this._prevTime-c,0);if(l>0)return clearTimeout(this._timer),this._timer=window.setTimeout((function(){r._continueDrag(t)}),l),!1;this._prevTime=c;var f=this._getScrollPosition(i,t);this._prevScrollPos=f,s&&(this._isWait=!0),a||(this._lock=!0);var p={container:he(n),direction:i,inputEvent:u};return null===(e=t.requestScroll)||void 0===e||e.call(t,p),this.emit("scroll",p),this._isWait=!1,a||this.checkScroll(le(le({},t),{prevScrollPos:f,direction:i,inputEvent:u}))}},e._registerScrollEvent=function(t){this._unregisterScrollEvent();var e=t.checkScrollEvent;if(e){var r=!0===e?pe:e,n=he(t.container);!0!==e||n!==document.body&&n!==document.documentElement?this._unregister=r(n,this._onScroll):this._unregister=pe(window,this._onScroll)}},e._unregisterScrollEvent=function(){var t;null===(t=this._unregister)||void 0===t||t.call(this),this._unregister=null},DragScroll}(ue);function ve(){for(var t=0,e=0,r=arguments.length;e=0;--r)e+=t[r];return e}(t.map((function(e,r){var n=t[r+1]||t[0];return e[0]*n[1]-n[0]*e[1]}))))/2}function me(t,e){var r=e.width,n=e.height,i=e.left,o=e.top,a=_e(t),s=a.minX,u=a.minY,c=a.maxX,l=a.maxY,f=r/(c-s),p=n/(l-u);return t.map((function(t){return[i+(t[0]-s)*f,o+(t[1]-u)*p]}))}function _e(t){var e=t.map((function(t){return t[0]})),r=t.map((function(t){return t[1]}));return{minX:Math.min.apply(Math,e),minY:Math.min.apply(Math,r),maxX:Math.max.apply(Math,e),maxY:Math.max.apply(Math,r)}}function be(t,e,r){var n=t[0],i=t[1],o=_e(e),a=o.minX,s=o.maxX,u=[[a,i],[s,i]],c=Se(u[0],u[1]),l=Ee(e),f=[];if(l.forEach((function(e){var r,n=Se(e[0],e[1]),o=e[0];(r=n,c.every((function(t,e){return 0===ge(t-r[e])})))?f.push({pos:t,line:e,type:"line"}):xe(we(c,n),[u,e]).forEach((function(t){e.some((function(e){return n=t,!ge((r=e)[0]-n[0])&&!ge(r[1]-n[1]);var r,n}))?f.push({pos:t,line:e,type:"point"}):0!==ge(o[1]-i)&&f.push({pos:t,line:e,type:"intersection"})}))})),!r&&$(f,(function(t){return t[0]===n})))return!0;var p=0,h={};return f.forEach((function(t){var e=t.pos,r=t.type,o=t.line;if(!(e[0]>n))if("intersection"===r)++p;else{if("line"===r)return;if("point"===r){var a=$(o,(function(t){return t[1]!==i})),s=h[e[0]],u=a[1]>i?1:-1;s?s!==u&&++p:h[e[0]]=u}}})),p%2==1}function Se(t,e){var r=t[0],n=t[1],i=e[0]-r,o=e[1]-n;Math.abs(i)0)return[];n=[[s,a],[u,a]]}}else{var c=Math.max.apply(Math,r.map((function(t){return t[1][0]}))),l=Math.min.apply(Math,r.map((function(t){return t[1][1]})));if(ge(c-l)>0)return[];n=[[o,c],[o,l]]}}return n.length||(n=t.filter((function(t){var e=t[0],n=t[1];return r.every((function(t){return 0<=ge(e-t[0][0])&&0<=ge(t[0][1]-e)&&0<=ge(n-t[1][0])&&0<=ge(t[1][1]-n)}))}))),n.map((function(t){return[ge(t[0]),ge(t[1])]}))}function Ee(t){return ve(t.slice(1),[t[0]]).map((function(e,r){return[t[r],e]}))}function Oe(t,e){var r=t.slice(),n=e.slice();-1===at(r)&&r.reverse(),-1===at(n)&&n.reverse();var i=Ee(r),o=Ee(n),a=i.map((function(t){return Se(t[0],t[1])})),s=o.map((function(t){return Se(t[0],t[1])})),u=[];a.forEach((function(t,e){var r=i[e],a=[];s.forEach((function(n,i){var s=xe(we(t,n),[r,o[i]]);a.push.apply(a,s.map((function(t){return{index1:e,index2:i,pos:t,type:"intersection"}})))})),a.sort((function(t,e){return st(r[0],t.pos)-st(r[0],e.pos)})),u.push.apply(u,a),be(r[1],n)&&u.push({index1:e,index2:-1,pos:r[1],type:"inside"})})),o.forEach((function(t,e){if(be(t[1],r)){var n=!1,i=X(u,(function(t){return t.index2===e?(n=!0,!1):!!n}));-1===i&&(n=!1,i=X(u,(function(t){var r=t.index1,i=t.index2;return-1===r&&i+1===e?(n=!0,!1):!!n}))),-1===i?u.push({index1:-1,index2:e,pos:t[1],type:"inside"}):u.splice(i,0,{index1:-1,index2:e,pos:t[1],type:"inside"})}}));var c={};return u.filter((function(t){var e=t.pos,r=e[0]+"x"+e[1];return!c[r]&&(c[r]=!0,!0)}))}function Ce(t,e){var r=function(t,e){return Oe(t,e).map((function(t){return t.pos}))}(t,e);return ye(r)}var ke=r(67294),De=function(t,e){return De=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])},De(t,e)};var Me=function(){return Me=Object.assign||function __assign(t){for(var e,r=1,n=arguments.length;r=0?o:o+2*Math.PI)/Math.PI);var e,r,n,i,o}function Ae(t){return t?t.touches?function(t){for(var e=Math.min(t.length,2),r=[],n=0;n=-1;if(!n.flag||!r){n._isDragAPI=!0;var i=n.options,o=i.container,a=i.pinchOutside,s=i.preventWheelClick,u=i.preventRightClick,c=i.preventDefault,l=i.checkInput,f=i.dragFocusedInput,p=i.preventClickEventOnDragStart,h=i.preventClickEventOnDrag,d=i.preventClickEventByCondition,v=n._useTouch,g=!n.flag;if(n._isSecondaryButton=3===t.which||2===t.button,s&&(2===t.which||1===t.button)||u&&(3===t.which||2===t.button))return n.stop(),!1;if(g){var y=n._window.document.activeElement,m=t.target;if(m){var _=m.tagName.toLowerCase(),b=Pe.indexOf(_)>-1,S=m.isContentEditable;if(b||S){if(l||!f&&y===m)return!1;if(y&&(y===m||S&&y.isContentEditable&&y.contains(m))){if(!f)return!1;m.blur()}}else if((c||"touchstart"===t.type)&&y){var w=y.tagName.toLowerCase();(y.isContentEditable||Pe.indexOf(w)>-1)&&y.blur()}(p||h||d)&&ht(n._window,"click",n._onClick,!0)}n.clientStores=[new qe(Ae(t))],n._isIdle=!1,n.flag=!0,n.isDrag=!1,n._isTrusted=e,n._dragFlag=!0,n._prevInputEvent=t,n.data={},n.doubleFlag=Y()-n.prevTime<200,n._isMouseEvent=function(t){return t&&(t.type.indexOf("mouse")>-1||"button"in t)}(t),!n._isMouseEvent&&n._preventMouseEvent&&(n._preventMouseEvent=!1),!1===(n._preventMouseEvent||n.emit("dragStart",Me(Me({data:n.data,datas:n.data,inputEvent:t,isMouseEvent:n._isMouseEvent,isSecondaryButton:n._isSecondaryButton,isTrusted:e,isDouble:n.doubleFlag},n.getCurrentStore().getPosition()),{preventDefault:function(){t.preventDefault()},preventDrag:function(){n._dragFlag=!1}})))&&n.stop(),n._isMouseEvent&&n.flag&&c&&t.preventDefault()}if(!n.flag)return!1;var x=0;if(g?(n._attchDragEvent(),v&&a&&(x=setTimeout((function(){ht(o,"touchstart",n.onDragStart,{passive:!1})})))):v&&a&&dt(o,"touchstart",n.onDragStart),n.flag&&function(t){return t.touches&&t.touches.length>=2}(t)){if(clearTimeout(x),g&&t.touches.length!==t.changedTouches.length)return;n.pinchFlag||n.onPinchStart(t)}}}},n.onDrag=function(t,e){if(n.flag){var r=n.options.preventDefault;!n._isMouseEvent&&r&&t.preventDefault(),n._prevInputEvent=t;var i=Ae(t),o=n.moveClients(i,t,!1);if(n._dragFlag){if(n.pinchFlag||o.deltaX||o.deltaY)if(!1===(n._preventMouseEvent||n.emit("drag",Me(Me({},o),{isScroll:!!e,inputEvent:t}))))return void n.stop();n.pinchFlag&&n.onPinch(t,i)}n.getCurrentStore().getPosition(i,!0)}},n.onDragEnd=function(t){if(n.flag){var e=n.options,r=e.pinchOutside,i=e.container,o=e.preventClickEventOnDrag,a=e.preventClickEventOnDragStart,s=e.preventClickEventByCondition,u=n.isDrag;(o||a||s)&&requestAnimationFrame((function(){n._allowClickEvent()})),s||a||!o||u||n._allowClickEvent(),n._useTouch&&r&&dt(i,"touchstart",n.onDragStart),n.pinchFlag&&n.onPinchEnd(t);var c=(null==t?void 0:t.touches)?Ae(t):[];0!==c.length&&n.options.keepDragging?n._addStore(new qe(c)):n.flag=!1;var l=n._getPosition(),f=Y(),p=!u&&n.doubleFlag;n._prevInputEvent=null,n.prevTime=u||p?0:f,n.flag||(n._dettachDragEvent(),n._preventMouseEvent||n.emit("dragEnd",Me({data:n.data,datas:n.data,isDouble:p,isDrag:u,isClick:!u,isMouseEvent:n._isMouseEvent,isSecondaryButton:n._isSecondaryButton,inputEvent:t,isTrusted:n._isTrusted},l)),n.clientStores=[],n._isMouseEvent||(n._preventMouseEvent=!0,requestAnimationFrame((function(){requestAnimationFrame((function(){n._preventMouseEvent=!1}))}))),n._isIdle=!0)}},n.onBlur=function(){n.onDragEnd()},n._allowClickEvent=function(){dt(n._window,"click",n._onClick,!0)},n._onClick=function(t){n._allowClickEvent(),n._preventMouseEvent=!1;var e=n.options.preventClickEventByCondition;(null==e?void 0:e(t))||(t.stopPropagation(),t.preventDefault())},n._onContextMenu=function(t){n.options.preventRightClick?n.onDragEnd(t):t.preventDefault()},n._passCallback=function(){};var i=[].concat(e),o=i[0];n._window=_t(o)?o:mt(o),n.options=Me({checkInput:!1,container:o&&!("document"in o)?mt(o):o,preventRightClick:!0,preventWheelClick:!0,preventClickEventOnDragStart:!1,preventClickEventOnDrag:!1,preventClickEventByCondition:null,preventDefault:!0,checkWindowBlur:!1,keepDragging:!1,pinchThreshold:0,events:["touch","mouse"]},r);var a=n.options,s=a.container,u=a.events,c=a.checkWindowBlur;if(n._useDrag=u.indexOf("drag")>-1,n._useTouch=u.indexOf("touch")>-1,n._useMouse=u.indexOf("mouse")>-1,n.targets=i,n._useDrag&&i.forEach((function(t){ht(t,"dragstart",n.onDragStart)})),n._useMouse&&(i.forEach((function(t){ht(t,"mousedown",n.onDragStart),ht(t,"mousemove",n._passCallback)})),ht(s,"contextmenu",n._onContextMenu)),c&&ht(mt(),"blur",n.onBlur),n._useTouch){var l={passive:!1};i.forEach((function(t){ht(t,"touchstart",n.onDragStart,l),ht(t,"touchmove",n._passCallback,l)}))}return n}return function(t,e){function __(){this.constructor=t}De(t,e),t.prototype=null===e?Object.create(e):(__.prototype=e.prototype,new __)}(Gesto,t),Gesto.prototype.stop=function(){this.isDrag=!1,this.data={},this.clientStores=[],this.pinchFlag=!1,this.doubleFlag=!1,this.prevTime=0,this.flag=!1,this._isIdle=!0,this._allowClickEvent(),this._dettachDragEvent(),this._isDragAPI=!1},Gesto.prototype.getMovement=function(t){return this.getCurrentStore().getMovement(t)+this.clientStores.slice(1).reduce((function(t,e){return t+e.movement}),0)},Gesto.prototype.isDragging=function(){return this.isDrag},Gesto.prototype.isIdle=function(){return this._isIdle},Gesto.prototype.isFlag=function(){return this.flag},Gesto.prototype.isPinchFlag=function(){return this.pinchFlag},Gesto.prototype.isDoubleFlag=function(){return this.doubleFlag},Gesto.prototype.isPinching=function(){return this.isPinch},Gesto.prototype.scrollBy=function(t,e,r,n){void 0===n&&(n=!0),this.flag&&(this.clientStores[0].move(t,e),n&&this.onDrag(r,!0))},Gesto.prototype.move=function(t,e){var r=t[0],n=t[1],i=this.getCurrentStore().prevClients;return this.moveClients(i.map((function(t){var e=t.clientX,i=t.clientY;return{clientX:e+r,clientY:i+n,originalClientX:e,originalClientY:i}})),e,!0)},Gesto.prototype.triggerDragStart=function(t){this.onDragStart(t,!1)},Gesto.prototype.setEventData=function(t){var e=this.data;for(var r in t)e[r]=t[r];return this},Gesto.prototype.setEventDatas=function(t){return this.setEventData(t)},Gesto.prototype.getCurrentEvent=function(t){return void 0===t&&(t=this._prevInputEvent),Me(Me({data:this.data,datas:this.data},this._getPosition()),{movement:this.getMovement(),isDrag:this.isDrag,isPinch:this.isPinch,isScroll:!1,inputEvent:t})},Gesto.prototype.getEventData=function(){return this.data},Gesto.prototype.getEventDatas=function(){return this.data},Gesto.prototype.unset=function(){var t=this,e=this.targets,r=this.options.container;this.off(),dt(this._window,"blur",this.onBlur),this._useDrag&&e.forEach((function(e){dt(e,"dragstart",t.onDragStart)})),this._useMouse&&(e.forEach((function(e){dt(e,"mousedown",t.onDragStart)})),dt(r,"contextmenu",this._onContextMenu)),this._useTouch&&(e.forEach((function(e){dt(e,"touchstart",t.onDragStart)})),dt(r,"touchstart",this.onDragStart)),this._prevInputEvent=null,this._allowClickEvent(),this._dettachDragEvent()},Gesto.prototype.onPinchStart=function(t){var e=this,r=this.options.pinchThreshold;if(!(this.isDrag&&this.getMovement()>r)){var n=new qe(Ae(t));this.pinchFlag=!0,this._addStore(n),!1===this.emit("pinchStart",Me(Me({data:this.data,datas:this.data,angle:n.getAngle(),touches:this.getCurrentStore().getPositions()},n.getPosition()),{inputEvent:t,isTrusted:this._isTrusted,preventDefault:function(){t.preventDefault()},preventDrag:function(){e._dragFlag=!1}}))&&(this.pinchFlag=!1)}},Gesto.prototype.onPinch=function(t,e){if(this.flag&&this.pinchFlag&&!(e.length<2)){var r=this.getCurrentStore();this.isPinch=!0,this.emit("pinch",Me(Me({data:this.data,datas:this.data,movement:this.getMovement(e),angle:r.getAngle(e),rotation:r.getRotation(e),touches:r.getPositions(e),scale:r.getScale(e),distance:r.getDistance(e)},r.getPosition(e)),{inputEvent:t,isTrusted:this._isTrusted}))}},Gesto.prototype.onPinchEnd=function(t){if(this.pinchFlag){var e=this.isPinch;this.isPinch=!1,this.pinchFlag=!1;var r=this.getCurrentStore();this.emit("pinchEnd",Me(Me({data:this.data,datas:this.data,isPinch:e,touches:r.getPositions()},r.getPosition()),{inputEvent:t}))}},Gesto.prototype.getCurrentStore=function(){return this.clientStores[0]},Gesto.prototype.moveClients=function(t,e,r){var n=this._getPosition(t,r),i=this.isDrag;(n.deltaX||n.deltaY)&&(this.isDrag=!0);var o=!1;return!i&&this.isDrag&&(o=!0),Me(Me({data:this.data,datas:this.data},n),{movement:this.getMovement(t),isDrag:this.isDrag,isPinch:this.isPinch,isScroll:!1,isMouseEvent:this._isMouseEvent,isSecondaryButton:this._isSecondaryButton,inputEvent:e,isTrusted:this._isTrusted,isFirstDrag:o})},Gesto.prototype._addStore=function(t){this.clientStores.splice(0,0,t)},Gesto.prototype._getPosition=function(t,e){var r=this.getCurrentStore().getPosition(t,e),n=this.clientStores.slice(1).reduce((function(t,e){var r=e.getPosition();return t.distX+=r.distX,t.distY+=r.distY,t}),r),i=n.distX,o=n.distY;return Me(Me({},r),{distX:i,distY:o})},Gesto.prototype._attchDragEvent=function(){var t=this._window,e=this.options.container,r={passive:!1};this._isDragAPI&&(ht(e,"dragover",this.onDrag,r),ht(t,"dragend",this.onDragEnd)),this._useMouse&&(ht(e,"mousemove",this.onDrag),ht(t,"mouseup",this.onDragEnd)),this._useTouch&&(ht(e,"touchmove",this.onDrag,r),ht(t,"touchend",this.onDragEnd,r),ht(t,"touchcancel",this.onDragEnd,r))},Gesto.prototype._dettachDragEvent=function(){var t=this._window,e=this.options.container;this._isDragAPI&&(dt(e,"dragover",this.onDrag),dt(t,"dragend",this.onDragEnd)),this._useMouse&&(dt(e,"mousemove",this.onDrag),dt(t,"mouseup",this.onDragEnd)),this._useTouch&&(dt(e,"touchstart",this.onDragStart),dt(e,"touchmove",this.onDrag),dt(t,"touchend",this.onDragEnd),dt(t,"touchcancel",this.onDragEnd))},Gesto}(ue);var Le=function(t){for(var e=5381,r=t.length;r;)e=33*e^t.charCodeAt(--r);return e>>>0};function Ke(t,e,r,n,i){var o=vt(n),a=o.createElement("style");return a.setAttribute("type","text/css"),a.setAttribute("data-styled-id",t),a.setAttribute("data-styled-count","1"),r.nonce&&a.setAttribute("nonce",r.nonce),a.innerHTML=function(t,e,r){return r.original?e:e.replace(/([^};{\s}][^};{]*|^\s*){/gm,(function(e,r){var n=r.trim();return(n?H(n):[""]).map((function(e){var r=e.trim();return 0===r.indexOf("@")?r:r.indexOf(":global")>-1?r.replace(/\:global/g,""):r.indexOf(":host")>-1?"".concat(r.replace(/\:host/g,".".concat(t))):r?".".concat(t," ").concat(r):".".concat(t)})).join(", ")+" {"}))}(t,e,r),(i||o.head||o.body).appendChild(a),a}const Ne=function(t){var e="rCS"+Le(t).toString(36);return{className:e,inject:function(r,n){void 0===n&&(n={});var i=function(t){if(t&&t.getRootNode){var e=t.getRootNode();if(11===e.nodeType)return e}}(r),o=(i||r.ownerDocument||document).querySelector('style[data-styled-id="'.concat(e,'"]'));if(o){var a=parseFloat(o.getAttribute("data-styled-count"))||0;o.setAttribute("data-styled-count","".concat(a+1))}else o=Ke(e,t,n,r,i);return{destroy:function(){var t,e=parseFloat(o.getAttribute("data-styled-count"))||0;e<=1?(o.remove?o.remove():null===(t=o.parentNode)||void 0===t||t.removeChild(o),o=null):o.setAttribute("data-styled-count","".concat(e-1))}}}}};var Fe=function(){return Fe=Object.assign||function __assign(t){for(var e,r=1,n=arguments.length;r=109||ir&&or>=109,sr="firefox"===er,ur=parseInt(Ze.browser.webkitVersion,10)>=612||rr>=15,cr="moveable-",lr=Xe.map((function(t){var e="",r="",n="center",i="center",o="calc(var(--moveable-control-padding, 20) * -1px)";return t.indexOf("n")>-1&&(e="top: ".concat(o,";"),i="bottom"),t.indexOf("s")>-1&&(e="top: 0px;",i="top"),t.indexOf("w")>-1&&(r="left: ".concat(o,";"),n="right"),t.indexOf("e")>-1&&(r="left: 0px;",n="left"),'.around-control[data-direction*="'.concat(t,'"] {\n ').concat(r).concat(e,"\n transform-origin: ").concat(n," ").concat(i,";\n }")})).join("\n"),fr="\n{\nposition: absolute;\nwidth: 1px;\nheight: 1px;\nleft: 0;\ntop: 0;\nz-index: 3000;\n--moveable-color: #4af;\n--zoom: 1;\n--zoompx: 1px;\n--moveable-line-padding: 0;\n--moveable-control-padding: 0;\nwill-change: transform;\noutline: 1px solid transparent;\n}\n.control-box {\nz-index: 0;\n}\n.line, .control {\nposition: absolute;\nleft: 0;\ntop: 0;\nwill-change: transform;\n}\n.control {\nwidth: 14px;\nheight: 14px;\nborder-radius: 50%;\nborder: 2px solid #fff;\nbox-sizing: border-box;\nbackground: #4af;\nbackground: var(--moveable-color);\nmargin-top: -7px;\nmargin-left: -7px;\nborder: 2px solid #fff;\nz-index: 10;\n}\n.around-control {\nposition: absolute;\nwill-change: transform;\nwidth: calc(var(--moveable-control-padding, 20) * 1px);\nheight: calc(var(--moveable-control-padding, 20) * 1px);\nleft: calc(var(--moveable-control-padding, 20) * -0.5px);\ntop: calc(var(--moveable-control-padding, 20) * -0.5px);\nbox-sizing: border-box;\nbackground: transparent;\nz-index: 8;\ncursor: alias;\ntransform-origin: center center;\n}\n".concat(lr,"\n.padding {\nposition: absolute;\ntop: 0px;\nleft: 0px;\nwidth: 100px;\nheight: 100px;\ntransform-origin: 0 0;\n}\n.line {\nwidth: 1px;\nheight: 1px;\nbackground: #4af;\nbackground: var(--moveable-color);\ntransform-origin: 0px 50%;\n}\n.line.edge {\nz-index: 1;\nbackground: transparent;\n}\n.line.dashed {\nbox-sizing: border-box;\nbackground: transparent;\n}\n.line.dashed.horizontal {\nborder-top: 1px dashed #4af;\nborder-top-color: #4af;\nborder-top-color: var(--moveable-color);\n}\n.line.dashed.vertical {\nborder-left: 1px dashed #4af;\nborder-left-color: #4af;\nborder-left-color: var(--moveable-color);\n}\n.line.vertical {\ntransform: translateX(-50%);\n}\n.line.horizontal {\ntransform: translateY(-50%);\n}\n.line.vertical.bold {\nwidth: 2px;\n}\n.line.horizontal.bold {\nheight: 2px;\n}\n\n.control.origin {\nborder-color: #f55;\nbackground: #fff;\nwidth: 12px;\nheight: 12px;\nmargin-top: -6px;\nmargin-left: -6px;\npointer-events: none;\n}\n").concat([0,15,30,45,60,75,90,105,120,135,150,165].map((function(t){return'\n.direction[data-rotation="'.concat(t,'"], :global .view-control-rotation').concat(t," {\n").concat(function(t){var e=function(t,e){return'data:image/svg+xml;utf8,')}(1,t),r=45*Math.round(t/45)%180,n="ns-resize";return 135===r?n="nwse-resize":45===r?n="nesw-resize":90===r&&(n="ew-resize"),"cursor:".concat(n,";cursor: url('").concat(e,"') 16 16, ").concat(n,";")}(t),"\n}\n")})).join("\n"),'\n\n.line.direction:before {\ncontent: "";\nposition: absolute;\nwidth: 100%;\nheight: calc(var(--moveable-line-padding, 0) * 1px);\nbottom: 0;\nleft: 0;\n}\n.group {\nz-index: -1;\n}\n.area {\nposition: absolute;\n}\n.area-pieces {\nposition: absolute;\ntop: 0;\nleft: 0;\ndisplay: none;\n}\n.area.avoid, .area.pass {\npointer-events: none;\n}\n.area.avoid+.area-pieces {\ndisplay: block;\n}\n.area-piece {\nposition: absolute;\n}\n\n').concat(tr?':global svg *:before {\ncontent:"";\ntransform-origin: inherit;\n}':"","\n"),pr=[[0,1,2],[1,0,3],[2,0,3],[3,1,2]],hr=1e-4,dr=1e-7,vr=1e-9,gr=Math.pow(10,10),yr=-gr,mr={n:[0,-1],e:[1,0],s:[0,1],w:[-1,0],nw:[-1,-1],ne:[1,-1],sw:[-1,1],se:[1,1]},_r={n:[0,1],e:[1,3],s:[3,2],w:[2,0],nw:[0],ne:[1],sw:[2],se:[3]},br={n:0,s:180,w:270,e:90,nw:315,ne:45,sw:225,se:135},Sr=["isMoveableElement","updateRect","updateTarget","destroy","dragStart","isInside","hitTest","setState","getRect","request","isDragging","getManager","forceUpdate","waitToChangeTarget","updateSelectors","getTargets","stopDrag","getControlBoxElement"];function wr(t,e,r,n,i,o){var a,s;void 0===o&&(o="draggable");var u=null!==(s=null===(a=e.gestos[o])||void 0===a?void 0:a.move(r,t.inputEvent))&&void 0!==s?s:{},c=u.originalDatas||u.datas,l=c[o]||(c[o]={});return We(We({},i?Do(e,u):u),{isPinch:!!n,parentEvent:!0,datas:l,originalDatas:t.originalDatas})}var xr=function(){function CustomGesto(t){var e;void 0===t&&(t="draggable"),this.ableName=t,this.prevX=0,this.prevY=0,this.startX=0,this.startY=0,this.isDrag=!1,this.isFlag=!1,this.datas={draggable:{}},this.datas=((e={})[t]={},e)}var t=CustomGesto.prototype;return t.dragStart=function(t,e){this.isDrag=!1,this.isFlag=!1;var r=e.originalDatas;return this.datas=r,r[this.ableName]||(r[this.ableName]={}),We(We({},this.move(t,e.inputEvent)),{type:"dragstart"})},t.drag=function(t,e){return this.move([t[0]-this.prevX,t[1]-this.prevY],e)},t.move=function(t,e){var r,n,i=!1;if(this.isFlag){var o=this.isDrag;r=this.prevX+t[0],n=this.prevY+t[1],(t[0]||t[1])&&(this.isDrag=!0),!o&&this.isDrag&&(i=!0)}else this.prevX=t[0],this.prevY=t[1],this.startX=t[0],this.startY=t[1],r=t[0],n=t[1],this.isFlag=!0;return this.prevX=r,this.prevY=n,{type:"drag",clientX:r,clientY:n,inputEvent:e,isFirstDrag:i,isDrag:this.isDrag,distX:r-this.startX,distY:n-this.startY,deltaX:t[0],deltaY:t[1],datas:this.datas[this.ableName],originalDatas:this.datas,parentEvent:!0,parentGesto:this}},CustomGesto}();function Er(t,e,r,n){var i=16===t.length?4:3,o=Xi(t,r,n,i),a=o[0],s=a[0],u=a[1],c=o[1],l=c[0],f=c[1],p=o[2],h=p[0],d=p[1],v=o[3],g=v[0],y=v[1],m=Yi(t,e,i),_=m[0],b=m[1],S=Math.min(s,l,h,g),w=Math.min(u,f,d,y),x=Math.max(s,l,h,g);return s=s-S||0,{left:S,top:w,right:x,bottom:Math.max(u,f,d,y),origin:[_=_-S||0,b=b-w||0],pos1:[s,u=u-w||0],pos2:[l=l-S||0,f=f-w||0],pos3:[h=h-S||0,d=d-w||0],pos4:[g=g-S||0,y=y-w||0],direction:Uo(t[0]*t[i+1])}}function Or(t,e){var r=e.clientX,n=e.clientY,i=e.datas,o=t.state,a=o.moveableClientRect,s=o.rootMatrix,u=o.is3d,c=o.pos1,l=Rt(ko(s,[r-a.left,n-a.top],u?4:3),c),f=Rr({datas:i,distX:l[0],distY:l[1]});return[f[0],f[1]]}function Cr(t,e){var r=e.datas,n=t.state,i=n.allMatrix,o=n.beforeMatrix,a=n.is3d,s=n.left,u=n.top,c=n.origin,l=n.offsetMatrix,f=n.targetMatrix,p=n.transformOrigin,h=a?4:3;r.is3d=a,r.matrix=i,r.targetMatrix=f,r.beforeMatrix=o,r.offsetMatrix=l,r.transformOrigin=p,r.inverseMatrix=Ot(i,h),r.inverseBeforeMatrix=Ot(o,h),r.absoluteOrigin=kt(At([s,u],c),h),r.startDragBeforeDist=zt(r.inverseBeforeMatrix,r.absoluteOrigin,h),r.startDragDist=zt(r.inverseMatrix,r.absoluteOrigin,h)}function kr(t,e){var r=t.datas,n=t.originalDatas.beforeRenderable,i=r.transformIndex,o=n.nextTransforms,a=o.length,s=n.nextTransformAppendedIndexes,u=-1;-1===i?("translate"===e?u=0:"rotate"===e&&(u=X(o,(function(t){return t.match(/scale\(/g)}))),-1===u&&(u=o.length),r.transformIndex=u):u=$(s,(function(t){return t.index===i&&t.functionName===e}))?i:i+s.filter((function(t){return t.indexu&&(r.isAppendTransform=!0,n.nextTransformAppendedIndexes=__spreadArray(__spreadArray([],s,!0),[{functionName:e,index:u,isAppend:!0}],!1))}function Dr(t,e,r){return"".concat(t.beforeFunctionTexts.join(" ")," ").concat(t.isAppendTransform?r:e," ").concat(t.afterFunctionTexts.join(" "))}function Mr(t){var e=t.datas,r=Ar({datas:e,distX:t.distX,distY:t.distY});return zt(Ir(e,function(t,e){for(var r=Ut(e),n=0;n=0&&(t[0]>=0&&e.push(3),t[0]<=0&&e.push(2)),t[1]<=0&&(t[0]>=0&&e.push(1),t[0]<=0&&e.push(0)),e}function zr(t,e){var r=(e[0]+1)/2,n=(e[1]+1)/2,i=[z(t[0][0],t[1][0],r,1-r),z(t[0][1],t[1][1],r,1-r)],o=[z(t[2][0],t[3][0],r,1-r),z(t[2][1],t[3][1],r,1-r)];return[z(i[0],o[0],n,1-n),z(i[1],o[1],n,1-n)]}function Br(t,e,r,n){return It(t,qi(e,n,r),n)}function qr(t){var e=Kr(t);return{setTransform:function(r,n){void 0===n&&(n=-1),e.startTransforms=P(r)?r:G(r),jr(t,n)},setTransformIndex:function(e){jr(t,e)}}}function Pr(t,e){jr(t,X(Kr(t).startTransforms,(function(t){return 0===t.indexOf("".concat(e,"("))})))}function jr(t,e){var r=Kr(t),n=t.datas;if(n.transformIndex=e,-1!==e){var i=r.startTransforms[e];if(i){var o=Xt([i]);n.startValue=o[0].functionValue}}}function Lr(t,e){Kr(t).nextTransforms=G(e)}function Kr(t){return t.originalDatas.beforeRenderable}function Nr(t){return t.originalDatas.beforeRenderable.nextTransforms}function Fr(t){return(Nr(t)||[]).join(" ")}function Ur(t){return Kr(t).nextStyle}function Gr(t,e,r,n,i){Lr(i,e);var o=Jn.drag(t,wr(i,t.state,r,n,!1)),a=o?o.transform:e;return We(We({transform:e,drag:o},vo({transform:a},i)),{afterTransform:a})}function Hr(t,e,r,n,i,o){var a=function(t,e,r,n){var i,o=t.transformOrigin,a=t.offsetMatrix,s=t.is3d?4:3;if(j(r)){var u=e.beforeTransform,c=e.afterTransform;i=Dt(n?Vt(r):It(It(u,Vt([r]),4),c,4),4,s)}else i=r;return Br(a,i,o,s)}(t.state,i,e,o),s=function(t,e,r,n){void 0===n&&(n=t.state.allMatrix);var i=t.state,o=i.width,a=i.height,s=i.is3d?4:3,u=[o/2*(1+e[0])+r[0],a/2*(1+e[1])+r[1]];return Yi(n,u,s)}(t,r,n,a);return s}function Wr(t,e,r,n,i,o,a){var s=Hr(t,e,r,i,o,a),u=t.state,c=u.left,l=u.top,f=t.props.groupable,p=f?c:0,h=f?l:0,d=Rt(n,s);return Rt(d,[p,h])}function Vr(t,e,r,n,i,o){var a=t.props.groupable,s=t.state,u=s.transformOrigin,c=s.offsetMatrix,l=s.is3d,f=s.width,p=s.height,h=s.left,d=s.top,v=o.fixedDirection,g=o.nextTargetMatrix||s.targetMatrix,y=l?4:3,m=function(t,e,r,n,i,o){return void 0===n&&(n=e),void 0===i&&(i=r),void 0===o&&(o=[0,0]),t?t.map((function(t,a){var s=V(t),u=s.value,c=s.unit,l=a?i:n,f=a?r:e;return"%"===t||isNaN(u)?f*(l?o[a]/l:0):"%"!==c?u:f*u/100})):o}(i,e,r,f,p,u),_=a?h:0,b=a?d:0,S=function(t,e,r,n,i,o){var a=zr(Xi(e,r,n,i),o);return[t[0]-a[0],t[1]-a[1]]}(n,Br(c,g,m,y),e,r,y,v);return Rt(S,[_,b])}function Yr(t){if(t&&t.getRootNode){var e=t.getRootNode();if(11===e.nodeType)return e}}function Xr(t,e,r){for(var n,i,o,a,s,u=t,c=[],l=gt(t)||yt(t),f=!r&&t===e||t===l,p=f,h=!1,d=3,v=!1,g=Ki(e,e,!0).offsetParent,y=1;u&&!p;){p=f;var m=tn(u),_=m("position"),b=m("scale"),S=Li(u),w="fixed"===_,x=(a=Bi(S),void 0===(s=void 0)&&(s=6===a.length),s?[a[0],a[1],0,a[2],a[3],0,a[4],a[5],1]:a),E=void 0,O=!1,C=!1,k=0,D=0,M=0,I=0,A={hasTransform:!1,fixedContainer:null};w&&(v=!0,g=(A=Gi(u)).fixedContainer);var R=x.length;h||16!==R||(h=!0,d=4,Ui(c),o&&(o=Dt(o,3,4))),h&&9===R&&(x=Dt(x,3,4));var T=Ni(u,t),z=T.tagName,B=T.hasOffset,q=T.isSVG,P=T.origin,j=T.targetOrigin,L=T.offset,K=L[0],N=L[1];"svg"===z&&o&&(c.push({type:"target",target:u,matrix:Vi(u,d)}),c.push({type:"offset",target:u,matrix:Ut(d)}));var F=parseFloat(m("zoom"))||1;if(w)E=A.fixedContainer,O=!0;else{var U=Ki(u,e,!1,!0,m),G=U.offsetZoom;if(E=U.offsetParent,O=U.isEnd,C=U.isStatic,y*=G,(U.isCustomElement||1!==G)&&C)K-=E.offsetLeft,N-=E.offsetTop;else if(sr||ar){if(U.parentSlotElement){for(var H=E,W=0,V=0;H&&Yr(H);)W+=H.offsetLeft,V+=H.offsetTop,H=H.offsetParent;K-=W,N-=V}}}if(!Qe||ur||!B||q||!C||"relative"!==_&&"static"!==_||(K-=E.offsetLeft,N-=E.offsetTop,f=f||O),w)B&&A.hasTransform&&(M=E.clientLeft,I=E.clientTop);else if(B&&g!==E&&(k=E.clientLeft,D=E.clientTop),B&&E===l){var Y=Fi(u,!1);K+=Y[0],N+=Y[1]}if(c.push({type:"target",target:u,matrix:qi(x,d,P)}),b&&"1"!==b&&"none"!==b){var X=b.split(" ").map((function(t){return parseFloat(t)})),$=X[0],J=X[1],Z=Gt([$,void 0===J?$:J],d);c.push({type:"offset",target:u,matrix:Ut(d)}),c.push({type:"target",target:u,matrix:qi(Z,d,P)})}if(B){var Q=u===t,tt=Q?0:u.scrollLeft,et=Q?0:u.scrollTop;c.push({type:"offset",target:u,matrix:Ht([K-tt+k-M,N-et+D-I],d)})}else c.push({type:"offset",target:u,origin:P});if(1!==F&&c.push({type:"zoom",target:u,matrix:qi(Gt([F,F],d),d,[0,0])}),o||(o=x),n||(n=P),i||(i=j),p||w)break;u=E,f=O,r&&u!==l||(p=f)}return o||(o=Ut(d)),n||(n=[0,0]),i||(i=[0,0]),{zoom:y,offsetContainer:g,matrixes:c,targetMatrix:o,transformOrigin:n,targetOrigin:i,is3d:h,hasFixed:v}}var $r=null,Jr=null,Zr=null;function Qr(t){t?(window.Map&&($r=new Map,Jr=new Map),Zr=[]):($r=null,Zr=null,Jr=null)}function tn(t){var e=null==$r?void 0:$r.get(t);if(!e){var r=mt(t).getComputedStyle(t);if(!$r)return function(t){return r[t]};e={style:r,cached:{}},$r.set(t,e)}var n=e.cached,i=e.style;return function(t){return t in n||(n[t]=i[t]),n[t]}}function en(t,e,r){var n=r.originalDatas;n.groupable=n.groupable||{};var i=n.groupable;i.childDatas=i.childDatas||[];var o=i.childDatas;return t.moveables.map((function(t,n){return o[n]=o[n]||{},o[n][e]=o[n][e]||{},We(We({},r),{datas:o[n][e],originalDatas:o[n]})}))}function rn(t,e,r,n,i,o,a){var s=!!r.match(/Start$/g),u=!!r.match(/End$/g),c=i.isPinch,l=i.datas,f=en(t,e.name,i),p=t.moveables,h=f.map((function(t,i){var f=p[i],h=f.state,d=h.gestos,v=t;if(s)v=new xr(a).dragStart(n,t);else{if(d[a]||(d[a]=l.childGestos[i]),!d[a])return;v=wr(t,h,n,c,o,a)}var g=e[r](f,We(We({},v),{parentFlag:!0}));return u&&(d[a]=null),g}));return s&&(l.childGestos=p.map((function(t){return t.state.gestos[a]}))),h}function nn(t,e,r,n,i,o){void 0===i&&(i=function(t,e){return e});var a=!!r.match(/End$/g),s=en(t,e.name,n),u=t.moveables;return s.map((function(t,n){var s,c=u[n];s=i(c,t);var l=e[r](c,We(We({},s),{parentFlag:!0}));return l&&o&&o(c,t,l,n),a&&(c.state.gestos={}),l}))}function on(t,e,r,n){var i=r.fixedDirection,o=r.fixedPosition,a=zr(n.datas.startPositions||fo(e.state),i),s=zt(Ft(-t.rotation/180*Math.PI,3),[a[0]-o[0],a[1]-o[1],1],3),u=s[0],c=s[1];return n.datas.originalX=u,n.datas.originalY=c,n}function an(t,e,r,n){var i=t.getState(),o=i.renderPoses,a=i.rotation,s=i.direction,u=ro(t.props,e).zoom,c=xi(a/Math.PI*180),l={},f=t.renderState;f.renderDirectionMap||(f.renderDirectionMap={});var p=f.renderDirectionMap;r.forEach((function(t){var e=t.dir;l[e]=!0}));var h=Uo(s);return r.map((function(t){var r=t.data,i=t.classNames,s=t.dir,f=_r[s];if(!f||!l[s])return null;p[s]=!0;var d=(ut(c,15)+h*br[s]+720)%180,v={};return Q(r).forEach((function(t){v["data-".concat(t)]=r[t]})),n.createElement("div",We({className:Ti.apply(void 0,__spreadArray(["control","direction",s,e],i,!1)),"data-rotation":d,"data-direction":s},v,{key:"direction-".concat(s),style:eo.apply(void 0,__spreadArray([a,u],f.map((function(t){return o[t]})),!1))}))}))}function sn(t,e,r,n){var i=ro(t.props,r),o=i.renderDirections,a=void 0===o?e:o,s=i.displayAroundControls;if(!a)return[];var u=!0===a?Xe:a;return __spreadArray(__spreadArray([],s?pn(t,n,r,u):[],!0),an(t,r,u.map((function(t){return{data:{},classNames:[],dir:t}})),n),!0)}function un(t,e,r,n,i,o){for(var a=[],s=6;so&&s.push({isBound:!0,offset:o-n,pos:n}),i-1.1||t[0]>e.right&&Go(t[0]-e.right)>.1||t[1].1||t[1]>e.bottom&&Go(t[1]-e.bottom)>.1}))}function yn(t,e,r,n,i){if(!t.props.bounds)return[];var o=i*Math.PI/180,a=dn(t),s=a.left,u=a.top,c=a.right,l=a.bottom,f=s-n[0],p=c-n[0],h=u-n[1],d=l-n[1],v={left:f,top:h,right:p,bottom:d};if(!gn(r,v,0))return[];var g=[];return[[f,0],[p,0],[h,1],[d,1]].forEach((function(t){var n=t[0],i=t[1];r.forEach((function(t){var r=ot([0,0],t);g.push.apply(g,function(t,e,r){var n=Zi(t),i=Math.sqrt(n*n-e*e)||0;return[i,-i].sort((function(e,n){return Go(e-t[r?0:1])-Go(n-t[r?0:1])})).map((function(t){return ot([0,0],r?[t,e]:[e,t])}))}(t,n,i).map((function(t){return o+t-r})).filter((function(t){return!gn(e,v,t)})).map((function(t){return ut(180*t/Math.PI,dr)})))}))})),g}var mn=["left","right","center"],_n=["top","bottom","middle"],bn={start:"left",end:"right",center:"center"},Sn={start:"top",end:"bottom",center:"middle"};function wn(t,e){var r=t.props,n=r.snappable,i=r.bounds,o=r.innerBounds,a=r.verticalGuidelines,s=r.horizontalGuidelines,u=r.snapGridWidth,c=r.snapGridHeight,l=t.state,f=l.guidelines,p=l.enableSnap;return!(!n||!p||e&&!0!==n&&n.indexOf(e)<0)&&!!(u||c||i||o||f&&f.length||a&&a.length||s&&s.length)}function xn(t){return!1===t?{}:!0!==t&&t?t:{left:!0,right:!0,top:!0,bottom:!0}}function En(t,e){var r=function(t,e){var r=xn(t),n={};for(var i in r)i in e&&r[i]&&(n[i]=e[i]);return n}(t,e),n=_n.filter((function(t){return t in r})),i=mn.filter((function(t){return t in r}));return{horizontalNames:n,verticalNames:i,horizontal:n.map((function(t){return r[t]})),vertical:i.map((function(t){return r[t]}))}}function On(t,e,r,n,i,o){void 0===n&&(n=[]),void 0===i&&(i=[]);var a=function(){for(var t=[],e=0;en)})).sort((function(t,e){return t.dist-e.dist}));return{pos:r,index:o,guidelineInfos:u,direction:a}})).filter((function(t){return t.guidelineInfos.length>0})).sort((function(t,e){return t.guidelineInfos[0].dist-e.guidelineInfos[0].dist})),c=u.length>0;return{isSnap:c,index:c?u[0].index:-1,direction:null!==(a=null===(o=u[0])||void 0===o?void 0:o.direction)&&void 0!==a?a:"",posInfos:u}}function An(t,e,r,n){void 0===n&&(n=1);var i=[];r[0]&&r[1]?i=[r,[-r[0],r[1]],[r[0],-r[1]]]:r[0]||r[1]?t.props.keepRatio?i.push([-1,-1],[-1,1],[1,-1],[1,1],r):(i.push.apply(i,function(t,e){return Tr(e).map((function(e){return t[e]}))}([[-1,-1],[1,-1],[-1,-1],[1,1]],r)),i.length>1&&i.push([(i[0][0]+i[1][0])/2,(i[0][1]+i[1][1])/2])):[[-1,-1],[1,-1],[1,1],[-1,1]].forEach((function(t,e,r){var n=r[e+1]||r[0];i.push(t),i.push([(t[0]+n[0])/2,(t[1]+n[1])/2])}));var o=i.map((function(t){return zr(e,t)})),a=On(t,o.map((function(t){return t[0]})),o.map((function(t){return t[1]})),i.map((function(t){return kn(t[0])})),i.map((function(t){return kn(t[1])})),n),s=kn(i.map((function(t){return t[0]}))[a.vertical.index]),u=kn(i.map((function(t){return t[1]}))[a.horizontal.index]);return{vertical:We(We({},a.vertical),{direction:s}),horizontal:We(We({},a.horizontal),{direction:u})}}function Rn(t,e){var r=Go(t.offset),n=Go(e.offset);return t.isBound&&e.isBound?n-r:t.isBound?-1:e.isBound?1:t.isSnap&&e.isSnap?n-r:t.isSnap?-1:e.isSnap||ra||u>a,l=Rr({datas:i,distX:o[0],distY:o[1]});return{offset:[l[0],l[1]],isOutside:c}}function Hn(t,e){return t.isBound?t.offset:e.isSnap?Mn(e).offset:0}function Wn(t,e,r,n,i,o){if(!wn(t,"draggable"))return[{isSnap:!1,isBound:!1,offset:0},{isSnap:!1,isBound:!1,offset:0}];var a=lo(o.absolutePoses,[e,r]),s=$i(a),u=s.left,c=s.right,l=s.top,f=s.bottom,p={horizontal:a.map((function(t){return t[1]})),vertical:a.map((function(t){return t[0]}))},h=Vn(t,i,En(xn(t.props.snapDirections),{left:u,right:c,top:l,bottom:f,center:(u+c)/2,middle:(l+f)/2}),p),d=h.vertical,v=h.horizontal,g=Kn(t,a,o),y=g.vertical,m=g.horizontal,_=d.isSnap,b=v.isSnap,S=d.isBound||y.isBound,w=v.isBound||m.isBound,x=function(t,e,r,n,i){var o=e[0],a=e[1],s=r[0],u=r[1],c=n[0],l=n[1],f=i[0],p=i[1],h=-f,d=-p;if(t&&o&&a){h=0,d=0;var v=[];if(s&&u?v.push([0,p],[f,0]):s?v.push([f,0]):u?v.push([0,p]):c&&l?v.push([0,p],[f,0]):c?v.push([f,0]):l&&v.push([0,p]),v.length){v.sort((function(t,e){return Zi(Rt([o,a],t))-Zi(Rt([o,a],e))}));var g=v[0];if(g[0]&&Go(o)>R)h=-g[0],d=a*Go(o+h)/Go(o)-a;else if(g[1]&&Go(a)>R){var y=a;d=-g[1],h=o*Go(a+d)/Go(y)-o}if(t&&u&&s)if(Go(h)>R&&Go(h)R&&Go(d)0,d=f>0,v={isBound:!1,offset:0,pos:0},g={isBound:!1,offset:0,pos:0};if(0===f&&0===p)return{vertical:v,horizontal:g};if(0===f)h?sc&&(g.pos=o,g.offset=c-o);else if(0===p)d?au&&(v.pos=i,v.offset=u-i);else{var y=p/f,m=r[1]-y*u,_=0,b=0,S=!1;d&&a<=u?(_=y*a+m,b=a,S=!0):!d&&u<=i&&(_=y*i+m,b=i,S=!0),S&&(_s)&&(S=!1),S||(h&&s<=c?(b=((_=s)-m)/y,S=!0):!h&&c<=o&&(b=((_=o)-m)/y,S=!0)),S&&(v.isBound=!0,v.pos=b,v.offset=u-b,g.isBound=!0,g.pos=_,g.offset=c-_)}return{vertical:v,horizontal:g}}(t,e,r),o=i.horizontal,a=i.vertical,s=n?{horizontal:{isSnap:!1},vertical:{isSnap:!1}}:function(t,e,r){var n=r[0],i=r[1],o=e[0],a=e[1],s=Rt(r,e),u=s[0],c=s[1],l=c>0,f=u>0;u=Ao(u),c=Ao(c);var p={isSnap:!1,offset:0,pos:0},h={isSnap:!1,offset:0,pos:0};if(0===u&&0===c)return{vertical:p,horizontal:h};var d=On(t,u?[n]:[],c?[i]:[]),v=d.vertical,g=d.horizontal;v.posInfos.filter((function(t){var e=t.pos;return f?e>=o:e<=o})),g.posInfos.filter((function(t){var e=t.pos;return l?e>=a:e<=a})),v.isSnap=v.posInfos.length>0,g.isSnap=g.posInfos.length>0;var y=Mn(v),m=y.isSnap,_=y.guideline,b=Mn(g),S=b.isSnap,w=b.guideline,x=S?w.pos[1]:0,E=m?_.pos[0]:0;if(0===u)S&&(h.isSnap=!0,h.pos=w.pos[1],h.offset=i-h.pos);else if(0===c)m&&(p.isSnap=!0,p.pos=E,p.offset=n-E);else{var O=c/u,C=r[1]-O*n,k=0,D=0,M=!1;m?(k=O*(D=E)+C,M=!0):S&&(D=((k=x)-C)/O,M=!0),M&&(p.isSnap=!0,p.pos=D,p.offset=n-D,h.isSnap=!0,h.pos=k,h.offset=i-k)}return{vertical:p,horizontal:h}}(t,e,r),u=s.horizontal,c=s.vertical,l=$n(o,u),f=$n(a,c),p=Go(l),h=Go(f);return{horizontal:{isBound:o.isBound,isSnap:u.isSnap,offset:l,dist:p},vertical:{isBound:a.isBound,isSnap:c.isSnap,offset:f,dist:h}}}(t,u,c,i):Vn(t,i,{vertical:[c[0]],horizontal:[c[1]]}),f=l.horizontal,p=f.offset,h=f.isBound,d=f.isSnap,v=l.vertical,g=v.offset,y=v.isBound,m=v.isSnap,_=Rt(s,a);if(!g&&!p)return{isBound:y||h,isSnap:m||d,sign:_,offset:[0,0]};var b=function(t,e,r,n){var i=ot(t,e)/Math.PI*180,o=r.vertical,a=o.isBound,s=o.isSnap,u=o.dist,c=r.horizontal,l=c.isBound,f=c.isSnap,p=i%180,h=p<3||p>177,d=p>87&&p<93;return c.dist0&&(c||l)){var E=v.startDragRotate||0,O=ut(E+180*ot([0,0],[c,l])/Math.PI,m)-E,C=l*Math.abs(Math.cos((O-90)/180*Math.PI)),k=Zi([c*Math.abs(Math.cos(O/180*Math.PI)),C]);_=O*Math.PI/180,c=k*Math.cos(_),l=k*Math.sin(_)}if(!o&&!n&&!i){var D=Wn(t,c,l,m,!s&&u||a,r),M=D[0],I=D[1];b=M.isSnap,S=M.isBound,w=I.isSnap,x=I.isBound,c+=M.offset,l+=I.offset}var A=At(Ar({datas:r,distX:c,distY:l}),d),R=At(Mr({datas:r,distX:c,distY:l}),d);ct(R,dr),ct(A,dr),m||(b||S||(R[0]=ut(R[0],y),A[0]=ut(A[0],y)),w||x||(R[1]=ut(R[1],y),A[1]=ut(A[1],y)));var T=Rt(A,d),z=Rt(R,d),B=Rt(z,p),q=Rt(T,h);r.prevDist=z,r.prevBeforeDist=T,r.passDelta=B,r.passDist=z;var P=r.left+T[0],j=r.top+T[1],L=r.right-T[0],K=r.bottom-T[1],N=Dr(r,"translate(".concat(R[0],"px, ").concat(R[1],"px)"),"translate(".concat(z[0],"px, ").concat(z[1],"px)"));if(Lr(e,N),t.state.dragInfo.dist=n?[0,0]:z,n||g||!B.every((function(t){return!t}))||!q.some((function(t){return!t}))){var F=t.state,U=F.width,G=F.height,H=yo(t,e,We({transform:N,dist:z,delta:B,translate:R,beforeDist:T,beforeDelta:q,beforeTranslate:A,left:P,top:j,right:L,bottom:K,width:U,height:G,isPinch:o},vo({transform:N},e)));return!n&&bo(t,"onDrag",H),H}}}},dragAfter:function(t,e){var r=e.datas,n=r.deltaOffset;return!(!n[0]&&!n[1])&&(r.deltaOffset=[0,0],this.drag(t,We(We({},e),{deltaOffset:n})))},dragEnd:function(t,e){var r=e.parentEvent,n=e.datas;if(t.state.dragInfo=null,n.isDrag){n.isDrag=!1;var i=mo(t,e,{});return!r&&bo(t,"onDragEnd",i),i}},dragGroupStart:function(t,e){var r=e.datas,n=e.clientX,i=e.clientY,o=this.dragStart(t,e);if(!o)return!1;var a=rn(t,this,"dragStart",[n||0,i||0],e,!1,"draggable"),s=bo(t,"onDragGroupStart",We(We({},o),{targets:t.props.targets,events:a}));return r.isDrag=!1!==s,!!r.isDrag&&o},dragGroup:function(t,e){if(e.datas.isDrag){var r=this.drag(t,e),n=rn(t,this,"drag",e.datas.passDelta,e,!1,"draggable");if(r){var i=We({targets:t.props.targets,events:n},r);return bo(t,"onDragGroup",i),i}}},dragGroupEnd:function(t,e){var r=e.isDrag;if(e.datas.isDrag){this.dragEnd(t,e);var n=rn(t,this,"dragEnd",[0,0],e,!1,"draggable");return bo(t,"onDragGroupEnd",mo(t,e,{targets:t.props.targets,events:n})),r}},request:function(t){var e={},r=t.getRect(),n=0,i=0,o=!1;return{isControl:!1,requestStart:function(t){return o=t.useSnap,{datas:e,useSnap:o}},request:function(t){return"x"in t?n=t.x-r.left:"deltaX"in t&&(n+=t.deltaX),"y"in t?i=t.y-r.top:"deltaY"in t&&(i+=t.deltaY),{datas:e,distX:n,distY:i,useSnap:o}},requestEnd:function(){return{datas:e,isDrag:!0,useSnap:o}}}},unset:function(t){t.state.gestos.draggable=null,t.state.dragInfo=null}};function Zn(t,e){return{fixedPosition:zr(t,e),fixedDirection:e,fixedOffset:[0,0]}}function Qn(t,e){var r=t.allMatrix,n=t.is3d,i=t.width,o=t.height,a=n?4:3,s=function(t,e,r){return[e?t[0]/(e/2)-1:0,r?t[1]/(r/2)-1:0]}(e,i,o);return{fixedPosition:Yi(r,e,a),fixedDirection:s,fixedOffset:[i?0:e[0],o?0:e[1]]}}var ti=To("resizable"),ei={name:"resizable",ableGroup:"size",canPinch:!0,props:["resizable","throttleResize","renderDirections","displayAroundControls","keepRatio","resizeFormat","keepRatioFinally","edge","checkResizableError"],events:["resizeStart","beforeResize","resize","resizeEnd","resizeGroupStart","beforeResizeGroup","resizeGroup","resizeGroupEnd"],render:ln("resizable"),dragControlCondition:ti,viewClassName:Ro("resizable"),dragControlStart:function(t,e){var r,n=e.inputEvent,i=e.isPinch,o=e.isGroup,a=e.parentDirection,s=e.parentGesto,u=e.datas,c=e.parentFixedDirection,l=e.parentEvent,f=uo(a,i,n,u),p=t.state,h=p.target,d=p.width,v=p.height,g=p.gestos;if(!f||!h)return!1;if(g.resizable)return!1;g.resizable=s||t.controlGesto,!i&&Cr(t,e),u.datas={},u.direction=f,u.startOffsetWidth=d,u.startOffsetHeight=v,u.prevWidth=0,u.prevHeight=0,u.minSize=[0,0],u.startWidth=p.inlineCSSWidth||p.cssWidth,u.startHeight=p.inlineCSSHeight||p.cssHeight,u.maxSize=[1/0,1/0],o||(u.minSize=[p.minOffsetWidth,p.minOffsetHeight],u.maxSize=[p.maxOffsetWidth,p.maxOffsetHeight]);var y=t.props.transformOrigin||"% %";function m(t){u.ratio=t&&isFinite(t)?t:0}function _(t){var e=Zn(u.startPositions,t);u.fixedDirection=e.fixedDirection,u.fixedPosition=e.fixedPosition,u.fixedOffset=e.fixedOffset}function b(e){var r=Qn(t.state,e);u.fixedDirection=r.fixedDirection,u.fixedPosition=r.fixedPosition,u.fixedOffset=r.fixedOffset}function S(t){u.minSize=[tt("".concat(t[0]),0)||0,tt("".concat(t[1]),0)||0]}function w(t){var e=[t[0]||1/0,t[1]||1/0];L(e[0])&&!isFinite(e[0])||(e[0]=tt("".concat(e[0]),0)||1/0),L(e[1])&&!isFinite(e[1])||(e[1]=tt("".concat(e[1]),0)||1/0),u.maxSize=e}u.transformOrigin=y&&j(y)?y.split(" "):y,u.startOffsetMatrix=p.offsetMatrix,u.startTransformOrigin=p.transformOrigin,u.isWidth=null!==(r=null==e?void 0:e.parentIsWidth)&&void 0!==r?r:!f[0]&&!f[1]||f[0]||!f[1],u.startPositions=fo(t.state),m(d/v),_(c||[-f[0],-f[1]]),u.setFixedDirection=_,u.setFixedPosition=b,u.setMin=S,u.setMax=w;var x=yo(t,e,{direction:f,startRatio:u.ratio,set:function(t){var e=t[0],r=t[1];u.startWidth=e,u.startHeight=r},setMin:S,setMax:w,setRatio:m,setFixedDirection:_,setFixedPosition:b,setOrigin:function(t){u.transformOrigin=t},dragStart:Jn.dragStart(t,(new xr).dragStart([0,0],e))}),E=l||bo(t,"onResizeStart",x);return u.startFixedDirection=u.fixedDirection,u.startFixedPosition=u.fixedPosition,!1!==E&&(u.isResize=!0,t.state.snapRenderInfo={request:e.isRequest,direction:f}),!!u.isResize&&x},dragControl:function(t,e){var r,n=e.datas,i=e.parentFlag,o=e.isPinch,a=e.parentKeepRatio,s=e.dragClient,u=e.parentDist,c=e.useSnap,l=e.isRequest,f=e.isGroup,p=e.parentEvent,h=e.resolveMatrix,d=n.isResize,v=n.transformOrigin,g=n.startWidth,y=n.startHeight,m=n.prevWidth,_=n.prevHeight,b=n.minSize,S=n.maxSize,w=n.ratio,x=n.startOffsetWidth,E=n.startOffsetHeight,O=n.isWidth;if(d){if(h){var C=t.state.is3d,k=n.startOffsetMatrix,D=n.startTransformOrigin,M=C?4:3,I=Vt(Nr(e)),A=Math.sqrt(I.length);M!==A&&(I=Dt(I,A,M));var R=Br(k,I,D,M),T=Xi(R,x,E,M);n.startPositions=T,n.nextTargetMatrix=I,n.nextAllMatrix=R}var z=ro(t.props,"resizable"),B=z.resizeFormat,q=z.throttleResize,P=void 0===q?i?0:1:q,j=z.parentMoveable,L=z.keepRatioFinally,K=n.direction,N=K,F=0,U=0;K[0]||K[1]||(N=[1,1]);var G=w&&(null!=a?a:z.keepRatio)||!1,H=ot(),W=H[0],V=H[1];p||(n.setFixedDirection(n.fixedDirection),bo(t,"onBeforeResize",yo(t,e,{startFixedDirection:n.startFixedDirection,startFixedPosition:n.startFixedPosition,setFixedDirection:function(t){var e;return n.setFixedDirection(t),e=ot(),W=e[0],V=e[1],[W,V]},setFixedPosition:function(t){var e;return n.setFixedPosition(t),e=ot(),W=e[0],V=e[1],[W,V]},boundingWidth:W,boundingHeight:V,setSize:function(t){W=t[0],V=t[1]}},!0)));var Y=s;s||(Y=!i&&o?function(t,e){return zr(fo(t.state),e)}(t,[0,0]):n.fixedPosition);var X=[0,0];if(o||(X=function(t,e,r,n,i,o,a){if(!wn(t,"resizable"))return[0,0];var s=a.fixedDirection,u=a.nextAllMatrix,c=t.state,l=c.allMatrix,f=c.is3d;return wi(t,(function(t,n){return _i(u||l,e+t,r+n,s,i,f)}),e,r,n,i,o,a)}(t,W,V,K,Y,!c&&l,n)),u&&(!u[0]&&(X[0]=0),!u[1]&&(X[1]=0)),G){N[0]&&N[1]&&X[0]&&X[1]&&(Go(X[0])>Go(X[1])?X[1]=0:X[0]=0);var $=!X[0]&&!X[1];$&&at(),N[0]&&!N[1]||X[0]&&!X[1]||$&&O?(W+=X[0],V=W/w):(!N[0]&&N[1]||!X[0]&&X[1]||$&&!O)&&(V+=X[1],W=V*w)}else W+=X[0],V+=X[1],W=Math.max(0,W),V=Math.max(0,V);r=nt([W,V],b,S,!!G&&w),W=r[0],V=r[1],at(),G&&(f||L)&&(O?V=W/w:W=V*w);var J=[(F=W-x)-m,(U=V-E)-_];n.prevWidth=F,n.prevHeight=U;var Z=Vr(t,W,V,Y,v,n);if(j||!J.every((function(t){return!t}))||!Z.every((function(t){return!t}))){var Q=Jn.drag(t,wr(e,t.state,Z,!!o,!1,"draggable")),tt=Q.transform,et=g+F,rt=y+U,it=yo(t,e,We({width:et,height:rt,offsetWidth:Math.round(W),offsetHeight:Math.round(V),startRatio:w,boundingWidth:W,boundingHeight:V,direction:K,dist:[F,U],delta:J,isPinch:!!o,drag:Q},go({style:{width:"".concat(et,"px"),height:"".concat(rt,"px")},transform:tt},Q,e)));return!p&&bo(t,"onResize",it),it}}function ot(){var t=n.fixedDirection,r=jo(N,G,n,e);F=r.distWidth,U=r.distHeight;var i=N[0]-t[0]||G?Math.max(x+F,dr):x,o=N[1]-t[1]||G?Math.max(E+U,dr):E;return G&&x&&E&&(O?o=i/w:i=o*w),[i,o]}function at(){var t;B&&(t=B([W,V]),W=t[0],V=t[1]),W=ut(W,P),V=ut(V,P)}},dragControlAfter:function(t,e){var r=e.datas,n=r.isResize,i=r.startOffsetWidth,o=r.startOffsetHeight,a=r.prevWidth,s=r.prevHeight;if(n&&!1!==t.props.checkResizableError){var u=t.state,c=u.width-(i+a),l=u.height-(o+s),f=Go(c)>3,p=Go(l)>3;return f&&(r.startWidth+=c,r.startOffsetWidth+=c,r.prevWidth+=c),p&&(r.startHeight+=l,r.startOffsetHeight+=l,r.prevHeight+=l),f||p?this.dragControl(t,e):void 0}},dragControlEnd:function(t,e){var r=e.datas,n=e.parentEvent;if(r.isResize){r.isResize=!1;var i=mo(t,e,{});return!n&&bo(t,"onResizeEnd",i),i}},dragGroupControlCondition:ti,dragGroupControlStart:function(t,e){var r=e.datas,n=this.dragControlStart(t,We(We({},e),{isGroup:!0}));if(!n)return!1;var i=en(t,"resizable",e),o=r.startOffsetWidth,a=r.startOffsetHeight;function s(){var t=r.minSize;i.forEach((function(e){var r=e.datas,n=r.minSize,i=r.startOffsetWidth,s=r.startOffsetHeight,u=o*(i?n[0]/i:0),c=a*(s?n[1]/s:0);t[0]=Math.max(t[0],u),t[1]=Math.max(t[1],c)}))}function u(){var t=r.maxSize;i.forEach((function(e){var r=e.datas,n=r.maxSize,i=r.startOffsetWidth,s=r.startOffsetHeight,u=o*(i?n[0]/i:0),c=a*(s?n[1]/s:0);t[0]=Math.min(t[0],u),t[1]=Math.min(t[1],c)}))}var c=nn(t,this,"dragControlStart",e,(function(e,n){return on(t,e,r,n)}));s(),u();var l=function(e){n.setFixedDirection(e),c.forEach((function(n,o){n.setFixedDirection(e),on(t,n.moveable,r,i[o])}))};r.setFixedDirection=l;var f=We(We({},n),{targets:t.props.targets,events:c.map((function(t){return We(We({},t),{setMin:function(e){t.setMin(e),s()},setMax:function(e){t.setMax(e),u()}})})),setFixedDirection:l,setMin:function(t){n.setMin(t),s()},setMax:function(t){n.setMax(t),u()}}),p=bo(t,"onResizeGroupStart",f);return r.isResize=!1!==p,!!r.isResize&&n},dragGroupControl:function(t,e){var r=e.datas;if(r.isResize){var n=ro(t.props,"resizable");_o(t,"onBeforeResize",(function(r){bo(t,"onBeforeResizeGroup",yo(t,e,We(We({},r),{targets:n.targets}),!0))}));var i=this.dragControl(t,We(We({},e),{isGroup:!0}));if(i){var o=i.boundingWidth,a=i.boundingHeight,s=i.dist,u=n.keepRatio,c=[o/(o-s[0]),a/(a-s[1])],l=r.fixedPosition,f=nn(t,this,"dragControl",e,(function(e,r){var n=zt(Ft(t.rotation/180*Math.PI,3),[r.datas.originalX*c[0],r.datas.originalY*c[1],1],3),i=n[0],o=n[1];return We(We({},r),{parentDist:null,parentScale:c,dragClient:At(l,[i,o]),parentKeepRatio:u})})),p=We({targets:n.targets,events:f},i);return bo(t,"onResizeGroup",p),p}}},dragGroupControlEnd:function(t,e){var r=e.isDrag;if(e.datas.isResize){this.dragControlEnd(t,e);var n=nn(t,this,"dragControlEnd",e);return bo(t,"onResizeGroupEnd",mo(t,e,{targets:t.props.targets,events:n})),r}},request:function(t){var e={},r=0,n=0,i=!1,o=t.getRect();return{isControl:!0,requestStart:function(t){var r;return i=t.useSnap,{datas:e,parentDirection:t.direction||[1,1],parentIsWidth:null===(r=null==t?void 0:t.horizontal)||void 0===r||r,useSnap:i}},request:function(t){return"offsetWidth"in t?r=t.offsetWidth-o.offsetWidth:"deltaWidth"in t&&(r+=t.deltaWidth),"offsetHeight"in t?n=t.offsetHeight-o.offsetHeight:"deltaHeight"in t&&(n+=t.deltaHeight),{datas:e,parentDist:[r,n],parentKeepRatio:t.keepRatio,useSnap:i}},requestEnd:function(){return{datas:e,isDrag:!0,useSnap:i}}}},unset:function(t){t.state.gestos.resizable=null}};function ri(t,e,r,n,i){var o=t.props.groupable,a=t.state,s=a.is3d?4:3,u=e.origin,c=Yi(t.state.rootMatrix,Rt([u[0],u[1]],o?[0,0]:[a.left,a.top]),s),l=At([i.left,i.top],c);e.startAbsoluteOrigin=l,e.prevDeg=ot(l,[r,n])/Math.PI*180,e.defaultDeg=e.prevDeg,e.prevSnapDeg=0,e.loop=0,e.startDist=st(l,[r,n])}function ni(t,e,r){var n=r.defaultDeg,i=r.prevDeg,o=i%360,a=Math.floor(i/360);o<0&&(o+=360),o>t&&o>270&&t<90?++a:o270&&--a;var s=e*(360*a+t-n);return r.prevDeg=n+s,s}function ii(t,e,r,n){return ni(ot(n.startAbsoluteOrigin,[t,e])/Math.PI*180,r,n)}function oi(t,e,r,n,i,o){var a=t.props.throttleRotate,s=void 0===a?0:a,u=r.prevSnapDeg,c=0,l=!1;if(o){var f=function(t,e,r,n){var i,o=t.props,a=null!==(i=o[Ii])&&void 0!==i?i:5,s=o[Ai];if(wn(t,"rotatable")){var u=e.pos1,c=e.pos2,l=e.pos3,f=e.pos4,p=e.origin,h=r*Math.PI/180,d=[u,c,l,f].map((function(t){return Rt(t,p)})),v=d.map((function(t){return Lt(t,h)})),g=__spreadArray(__spreadArray([],yn(t,d,v,p,r),!0),Un(t,d,v,p,r),!0);g.sort((function(t,e){return Go(t-r)-Go(e-r)}));var y=g.length>0;if(y)return{isSnap:y,dist:y?g[0]:r}}if((null==s?void 0:s.length)&&a){var m=s.slice().sort((function(t,e){return Oi(t,n)-Oi(e,n)}))[0];if(Oi(m,n)<=a)return{isSnap:!0,dist:r+Ei(n,m)-n}}return{isSnap:!1,dist:r}}(t,e,n,i+n);l=f.isSnap,c=i+f.dist}l||(c=ut(i+n,s));var p=c-i;return r.prevSnapDeg=p,[p-u,p,c]}function ai(t,e,r){var n=e[0],i=e[1],o=e[2],a=e[3];if("none"===t)return[];if(P(t))return t.map((function(t){return ai(t,[n,i,o,a],r)[0]}));var s=(t||"top").split("-"),u=s[0],c=s[1],l=[n,i];"left"===u?l=[o,n]:"right"===u?l=[i,a]:"bottom"===u&&(l=[a,o]);var f=[(l[0][0]+l[1][0])/2,(l[0][1]+l[1][1])/2],p=io(l,r);if(c){var h="top"===c||"left"===c,d="bottom"===u||"left"===u;f=l[h&&!d||!h&&d?0:1]}return[[f,p]]}function si(t,e){if(e.isRequest)return"rotatable"===e.requestAble;var r=e.inputEvent.target;if(lt(r,Ti("rotation-control"))||t.props.rotateAroundControls&<(r,Ti("around-control"))||lt(r,Ti("control"))&<(r,Ti("rotatable")))return!0;var n=t.props.rotationTarget;return!!n&&Bo(n,!0).some((function(t){return!!t&&(r===t||r.contains(t))}))}var ui={name:"rotatable",canPinch:!0,props:["rotatable","rotationPosition","throttleRotate","renderDirections","rotationTarget","rotateAroundControls","edge","resolveAblesWithRotatable","displayAroundControls"],events:["rotateStart","beforeRotate","rotate","rotateEnd","rotateGroupStart","beforeRotateGroup","rotateGroup","rotateGroupEnd"],css:[".rotation {\nposition: absolute;\nheight: 40px;\nwidth: 1px;\ntransform-origin: 50% 100%;\nheight: calc(40px * var(--zoom));\ntop: auto;\nleft: 0;\nbottom: 100%;\nwill-change: transform;\n}\n.rotation .rotation-line {\ndisplay: block;\nwidth: 100%;\nheight: 100%;\ntransform-origin: 50% 50%;\n}\n.rotation .rotation-control {\nborder-color: #4af;\nborder-color: var(--moveable-color);\nbackground:#fff;\ncursor: alias;\n}\n:global .view-rotation-dragging, .rotatable.direction.control {\ncursor: alias;\n}\n.rotatable.direction.control.move {\ncursor: move;\n}\n"],viewClassName:function(t){return t.isDragging("rotatable")?Ti("view-rotation-dragging"):""},render:function(t,e){var r=ro(t.props,"rotatable"),n=r.rotatable,i=r.rotationPosition,o=r.zoom,a=r.renderDirections,s=r.rotateAroundControls,u=r.resolveAblesWithRotatable,c=t.getState(),l=c.renderPoses,f=c.direction;if(!n)return null;var p=ai(i,l,f),h=[];if(p.forEach((function(t,r){var n=t[0],i=t[1];h.push(e.createElement("div",{key:"rotation".concat(r),className:Ti("rotation"),style:{transform:"translate(-50%) translate(".concat(n[0],"px, ").concat(n[1],"px) rotate(").concat(i,"rad)")}},e.createElement("div",{className:Ti("line rotation-line"),style:{transform:"scaleX(".concat(o,")")}}),e.createElement("div",{className:Ti("control rotation-control"),style:{transform:"translate(0.5px) scale(".concat(o,")")}})))})),a){var d=Q(u||{}),v={};d.forEach((function(t){u[t].forEach((function(e){v[e]=t}))}));var g=[];P(a)&&(g=a.map((function(t){var e=v[t];return{data:e?{resolve:e}:{},classNames:e?["move"]:[],dir:t}}))),h.push.apply(h,an(t,"rotatable",g,e))}return s&&h.push.apply(h,pn(t,e)),h},dragControlCondition:si,dragControlStart:function(t,e){var r,n,i=e.datas,o=e.clientX,a=e.clientY,s=e.parentRotate,u=e.parentFlag,c=e.isPinch,l=e.isRequest,f=t.state,p=f.target,h=f.left,d=f.top,v=f.direction,g=f.beforeDirection,y=f.targetTransform,m=f.moveableClientRect,_=f.offsetMatrix,b=f.targetMatrix,S=f.allMatrix,w=f.width,x=f.height;if(!l&&!p)return!1;var E=t.getRect();i.rect=E,i.transform=y,i.left=h,i.top=d;var O=function(e){var r=Qn(t.state,e);i.fixedDirection=r.fixedDirection,i.fixedOffset=r.fixedOffset,i.fixedPosition=r.fixedPosition,P&&P.setFixedPosition(e)},C=function(e){var r=function(t,e){var r=t.allMatrix,n=t.is3d,i=t.width,o=t.height,a=n?4:3;return{fixedPosition:Yi(r,[i/2*(1+e[0]),o/2*(1+e[1])],a),fixedDirection:e,fixedOffset:[0,0]}}(t.state,e);i.fixedDirection=r.fixedDirection,i.fixedOffset=r.fixedOffset,i.fixedPosition=r.fixedPosition,P&&P.setFixedDirection(e)},k=o,D=a;if(l||c||u){var M=s||0;i.beforeInfo={origin:E.beforeOrigin,prevDeg:M,defaultDeg:M,prevSnapDeg:0,startDist:0},i.afterInfo=We(We({},i.beforeInfo),{origin:E.origin}),i.absoluteInfo=We(We({},i.beforeInfo),{origin:E.origin,startValue:M})}else{var I=null===(n=e.inputEvent)||void 0===n?void 0:n.target;if(I){var A=I.getAttribute("data-direction")||"",R=mr[A];if(R){i.isControl=!0,i.isAroundControl=lt(I,Ti("around-control")),i.controlDirection=R;var T=I.getAttribute("data-resolve");T&&(i.resolveAble=T);var z=function(t,e,r){var n=16===t.length?4:3,i=e.map((function(e){return Yi(t,e,n)})),o=r.left,a=r.top;return i.map((function(t){return[t[0]+o,t[1]+a]}))}(f.rootMatrix,f.renderPoses,m);r=zr(z,R),k=r[0],D=r[1]}}i.beforeInfo={origin:E.beforeOrigin},i.afterInfo={origin:E.origin},i.absoluteInfo={origin:E.origin,startValue:E.rotation};var B=O;O=function(e){var r=f.is3d?4:3,n=At(Ct(b,r),e),o=n[0],a=n[1],s=zt(_,kt([o,a],r)),u=zt(S,kt([e[0],e[1]],r));B(e);var c=f.posDelta;i.beforeInfo.origin=Rt(s,c),i.afterInfo.origin=Rt(u,c),i.absoluteInfo.origin=Rt(u,c),ri(t,i.beforeInfo,k,D,m),ri(t,i.afterInfo,k,D,m),ri(t,i.absoluteInfo,k,D,m)},C=function(t){var e=zr([[0,0],[w,0],[0,x],[w,x]],t);O(e)}}i.startClientX=k,i.startClientY=D,i.direction=v,i.beforeDirection=g,i.startValue=0,i.datas={},Pr(e,"rotate");var q=!1,P=!1;i.isControl&&i.resolveAble&&("resizable"===i.resolveAble&&(P=ei.dragControlStart(t,We(We({},new xr("resizable").dragStart([0,0],e)),{parentPosition:i.controlPosition,parentFixedPosition:i.fixedPosition}))));P||(q=Jn.dragStart(t,(new xr).dragStart([0,0],e))),O(function(t){var e=t.props,r=e.groupable,n=e.svgOrigin,i=t.getState(),o=i.offsetWidth,a=i.offsetHeight,s=i.svg,u=i.transformOrigin;if(!r&&s&&n)return Ko(n,o,a);return u}(t));var j=yo(t,e,We(We({set:function(t){i.startValue=t*Math.PI/180},setFixedDirection:C,setFixedPosition:O},qr(e)),{dragStart:q,resizeStart:P})),L=bo(t,"onRotateStart",j);return i.isRotate=!1!==L,f.snapRenderInfo={request:e.isRequest},!!i.isRotate&&j},dragControl:function(t,e){var r,n,i,o=e.datas,a=e.clientDistX,s=e.clientDistY,u=e.parentRotate,c=e.parentFlag,l=e.isPinch,f=e.groupDelta,p=e.resolveMatrix,h=o.beforeDirection,d=o.beforeInfo,v=o.afterInfo,g=o.absoluteInfo,y=o.isRotate,m=o.startValue,_=o.rect,b=o.startClientX,S=o.startClientY;if(y){kr(e,"rotate");var w,x,E,O,C,k,D,M,I,A=function(t){return Er(t.datas.beforeTransform,[50,50],100,100).direction}(e),R=h*A,T=t.props.parentMoveable,z=180/Math.PI*m,B=g.startValue,q=!1,P=b+a,j=S+s;if(!c&&"parentDist"in e){var L=e.parentDist;x=L,C=L,M=L}else l||c?(x=ni(u,h,d),C=ni(u,R,v),M=ni(u,R,g)):(x=ii(P,j,h,d),C=ii(P,j,R,v),M=ii(P,j,R,g),q=!0);if(bo(t,"onBeforeRotate",yo(t,e,{beforeRotation:E=z+x,rotation:k=z+C,absoluteRotation:I=B+M,setRotation:function(t){x=C=t-z,M=C}},!0)),w=(r=oi(t,_,d,x,z,q))[0],x=r[1],E=r[2],O=(n=oi(t,_,v,C,z,q))[0],C=n[1],k=n[2],D=(i=oi(t,_,g,M,B,q))[0],M=i[1],I=i[2],D||O||w||T||p){var K=Dr(o,"rotate(".concat(k,"deg)"),"rotate(".concat(C,"deg)"));p&&(o.fixedPosition=Hr(t,o.targetAllTransform,o.fixedDirection,o.fixedOffset,o));var N=function(t,e,r){var n=r.fixedDirection,i=r.fixedPosition,o=r.fixedOffset;return Wr(t,"rotate(".concat(e,"deg)"),n,i,o,r)}(t,C,o),F=Rt(At(f||[0,0],N),o.prevInverseDist||[0,0]);o.prevInverseDist=N,o.requestValue=null;var U=Gr(t,K,F,l,e),G=U,H=st([P,j],g.startAbsoluteOrigin)-g.startDist,W=void 0;if("resizable"===o.resolveAble){var V=ei.dragControl(t,We(We({},wr(e,t.state,[e.deltaX,e.deltaY],!!l,!1,"resizable")),{resolveMatrix:!0,parentDistance:H}));V&&(W=V,G=go(G,V,e))}var Y=yo(t,e,We(We({delta:O,dist:C,rotate:k,rotation:k,beforeDist:x,beforeDelta:w,beforeRotate:E,beforeRotation:E,absoluteDist:M,absoluteDelta:D,absoluteRotate:I,absoluteRotation:I,isPinch:!!l,resize:W},U),G));return bo(t,"onRotate",Y),Y}}},dragControlEnd:function(t,e){var r=e.datas;if(r.isRotate){r.isRotate=!1;var n=mo(t,e,{});return bo(t,"onRotateEnd",n),n}},dragGroupControlCondition:si,dragGroupControlStart:function(t,e){var r=e.datas,n=t.state,i=n.left,o=n.top,a=n.beforeOrigin,s=this.dragControlStart(t,e);if(!s)return!1;s.set(r.beforeDirection*t.rotation);var u=nn(t,this,"dragControlStart",e,(function(t,e){var r=t.state,n=r.left,s=r.top,u=r.beforeOrigin,c=At(Rt([n,s],[i,o]),Rt(u,a));return e.datas.startGroupClient=c,e.datas.groupClient=c,We(We({},e),{parentRotate:0})})),c=bo(t,"onRotateGroupStart",We(We({},s),{targets:t.props.targets,events:u}));return r.isRotate=!1!==c,!!r.isRotate&&s},dragGroupControl:function(t,e){var r=e.datas;if(r.isRotate){_o(t,"onBeforeRotate",(function(r){bo(t,"onBeforeRotateGroup",yo(t,e,We(We({},r),{targets:t.props.targets}),!0))}));var n=this.dragControl(t,e);if(n){var i=r.beforeDirection,o=n.beforeDist,a=o/180*Math.PI,s=nn(t,this,"dragControl",e,(function(t,e){var r=e.datas.startGroupClient,n=e.datas.groupClient,s=n[0],u=n[1],c=Lt(r,a*i),l=c[0],f=c[1],p=[l-s,f-u];return e.datas.groupClient=[l,f],We(We({},e),{parentRotate:o,groupDelta:p})}));t.rotation=i*n.beforeRotation;var u=We({targets:t.props.targets,events:s,set:function(e){t.rotation=e},setGroupRotation:function(e){t.rotation=e}},n);return bo(t,"onRotateGroup",u),u}}},dragGroupControlEnd:function(t,e){var r=e.isDrag;if(e.datas.isRotate){this.dragControlEnd(t,e);var n=nn(t,this,"dragControlEnd",e);return bo(t,"onRotateGroupEnd",mo(t,e,{targets:t.props.targets,events:n})),r}},request:function(t){var e={},r=0,n=t.getRotation();return{isControl:!0,requestStart:function(){return{datas:e}},request:function(t){return"deltaRotate"in t?r+=t.deltaRotate:"rotate"in t&&(r=t.rotate-n),{datas:e,parentDist:r}},requestEnd:function(){return{datas:e,isDrag:!0}}}}};function ci(t,e){return function(t,e){var r,n=t.direction,i=t.classNames,o=t.size,a=t.pos,s=t.zoom,u=t.key,c="horizontal"===n,l=c?"Y":"X";return e.createElement("div",{key:u,className:i.join(" "),style:(r={},r[c?"width":"height"]="".concat(o),r.transform="translate(".concat(a[0],", ").concat(a[1],") translate").concat(l,"(-50%) scale").concat(l,"(").concat(s,")"),r)})}(We(We({},t),{classNames:__spreadArray([Ti("line","guideline",t.direction)],t.classNames,!0).filter((function(t){return t})),size:t.size||"".concat(t.sizeValue,"px"),pos:t.pos||t.posValue.map((function(t){return"".concat(ut(t,.1),"px")}))}),e)}function li(t,e,r,n,i,o,a,s){var u=t.props.zoom;return r.map((function(t,r){var c=t.type,l=t.pos,f=[0,0];return f[a]=n,f[a?0:1]=-i+l,ci({key:"".concat(e,"TargetGuideline").concat(r),classNames:[Ti("target","bold",c)],posValue:f,sizeValue:o,zoom:u,direction:e},s)}))}function fi(t,e,r,n,i,o){var a=t.props,s=a.zoom,u=a.isDisplayInnerSnapDigit,c="horizontal"===e?bn:Sn,l=i[c.start],f=i[c.end];return r.filter((function(t){var e=t.hide,r=t.elementRect;if(e)return!1;if(u&&r){var n=r.rect;if(n[c.start]<=l&&f<=n[c.end])return!1}return!0})).map((function(t,r){var i=t.pos,a=t.size,u=t.element,c=t.className,l=[-n[0]+i[0],-n[1]+i[1]];return ci({key:"".concat(e,"-default-guideline-").concat(r),classNames:u?[Ti("bold"),c]:[Ti("normal"),c],direction:e,posValue:l,sizeValue:a,zoom:s},o)}))}function pi(t,e,r,n,i,o,a,s){var u,c=t.props,l=c.snapDigit,f=void 0===l?0:l,p=c.isDisplaySnapDigit,h=void 0===p||p,d=c.snapDistFormat,v=void 0===d?function(t,e){return t}:d,g=c.zoom,y="horizontal"===e?"X":"Y",m="vertical"===e?"height":"width",_=Math.abs(i),b=h?parseFloat(_.toFixed(f)):0;return s.createElement("div",{key:"".concat(e,"-").concat(r,"-guideline-").concat(n),className:Ti("guideline-group",e),style:(u={left:"".concat(o[0],"px"),top:"".concat(o[1],"px")},u[m]="".concat(_,"px"),u)},ci({direction:e,classNames:[Ti(r),a],size:"100%",posValue:[0,0],sizeValue:_,zoom:g},s),s.createElement("div",{className:Ti("size-value","gap"),style:{transform:"translate".concat(y,"(-50%) scale(").concat(g,")")}},b>0?v(b,e):""))}function hi(t,e,r,n,i){var o=t.props.isDisplayInnerSnapDigit,a=[];return["vertical","horizontal"].forEach((function(s){var u=e.filter((function(t){return t.type===s})),c="vertical"===s?1:0,l=c?0:1,f=function(t,e,r,n){var i="vertical"===t?0:1,o="vertical"===t?1:0,a=i?bn:Sn,s=r[a.start],u=r[a.end];return Eo(e,(function(t){return t.pos[i]})).map((function(e){var r=[],c=[];return e.forEach((function(e){var l,f,p=e.element,h=e.elementRect.rect;if(h[a.end]0){var u=[0,0];u[c]=r[c]+m[p.start]-d-o,u[l]=y,a.push(pi(t,s,"dashed",a.length,o,u,e.className,i))}m=n})),m=n,f.forEach((function(e){var n=e.elementRect.rect,o=n[p.start]-m[p.end];if(o>0){var u=[0,0];u[c]=r[c]+m[p.end]-d,u[l]=y,a.push(pi(t,s,"dashed",a.length,o,u,e.className,i))}m=n})),g.forEach((function(e){var n=e.elementRect.rect,o=d-n[p.start],u=n[p.end]-v,f=[0,0],h=[0,0];f[c]=r[c]-o,f[l]=y,h[c]=r[c]+v-d,h[l]=y,a.push(pi(t,s,"dashed",a.length,o,f,e.className,i)),a.push(pi(t,s,"dashed",a.length,u,h,e.className,i))}))}))})),a}function di(t){var e=t.state,r=e.containerClientRect,n=e.hasFixed,i=r.overflow,o=r.scrollHeight,a=r.scrollWidth,s=r.clientHeight,u=r.clientWidth,c=r.clientLeft,l=r.clientTop,f=t.props,p=f.snapGap,h=void 0===p||p,d=f.verticalGuidelines,v=f.horizontalGuidelines,g=f.snapThreshold,y=void 0===g?5:g,m=f.snapGridWidth,_=void 0===m?0:m,b=f.snapGridHeight,S=void 0===b?0:b,w=f.maxSnapElementGuidelineDistance,x=void 0===w?1/0:w,E=f.isDisplayGridGuidelines,O=$i(fo(t.state)),C=O.top,k=O.left,D=O.bottom,M=O.right,I={top:C,left:k,bottom:D,right:M,center:(k+M)/2,middle:(C+D)/2},A=function(t){var e=t.state,r=t.props.elementGuidelines,n=void 0===r?[]:r;if(!n.length)return e.elementRects=[],[];var i=(e.elementRects||[]).filter((function(t){return!t.refresh})),o=n.map((function(t){return q(t)&&"element"in t?We(We({},t),{element:zo(t.element,!0)}):{element:zo(t,!0)}})).filter((function(t){return t.element})),a=(l=i.map((function(t){return t.element})),f=o.map((function(t){return t.element})),ee(l,f,oe)),s=a.maintained,u=a.added,c=[];var l,f;s.forEach((function(t){var e=t[0],r=t[1];c[r]=i[e]})),function(t,e){if(!e.length)return[];var r=t.props.groupable,n=t.state,i=n.containerClientRect,o=n.rootMatrix,a=n.is3d,s=n.offsetDelta,u=a?4:3,c=function(t,e,r){var n=Yi(t,[e.clientLeft,e.clientTop],r);return[e.left+n[0],e.top+n[1]]}(o,i,u),l=c[0],f=c[1],p=r?0:s[0],h=r?0:s[1];return e.map((function(t){var e=t.element.getBoundingClientRect(),r=e.left-l-p,n=e.top-f-h,i=n+e.height,a=r+e.width,s=ko(o,[r,n],u),c=s[0],d=s[1],v=ko(o,[a,i],u),g=v[0],y=v[1];return We(We({},t),{rect:{left:c,right:g,top:d,bottom:y,center:(c+g)/2,middle:(d+y)/2}})}))}(t,u.map((function(t){return o[t]}))).map((function(t,e){c[u[e]]=t})),e.elementRects=c;var p=xn(t.props.elementSnapDirections),h=[];return c.forEach((function(t){var e=t.element,r=t.top,n=void 0===r?p.top:r,i=t.left,o=void 0===i?p.left:i,a=t.right,s=void 0===a?p.right:a,u=t.bottom,c=void 0===u?p.bottom:u,l=t.center,f=void 0===l?p.center:l,d=t.middle,v=void 0===d?p.middle:d,g=t.className,y=t.rect,m=En({top:n,right:s,left:o,bottom:c,center:f,middle:v},y),_=m.horizontal,b=m.vertical,S=y.top,w=y.left,x=y.right-w,E=y.bottom-S,O=[x,E];b.forEach((function(r){h.push({type:"vertical",element:e,pos:[ut(r,.1),S],size:E,sizes:O,className:g,elementRect:t,direction:""})})),_.forEach((function(r){h.push({type:"horizontal",element:e,pos:[w,ut(r,.1)],size:x,sizes:O,className:g,elementRect:t,direction:""})}))})),h}(t),R=__spreadArray([],A,!0);h&&R.push.apply(R,function(t,e,r){var n=t.props,i=n.maxSnapElementGuidelineDistance,o=void 0===i?1/0:i,a=n.maxSnapElementGapDistance,s=void 0===a?1/0:a,u=t.state.elementRects,c=[];return[["vertical",bn,Sn],["horizontal",Sn,bn]].forEach((function(t){var n=t[0],i=t[1],a=t[2],l=e[i.start],f=e[i.end],p=e[i.center],h=e[a.start],d=e[a.end];function v(t){var e=t.rect;return e[i.end]d||e[a.end]0})).sort((function(t,e){return v(t)-v(e)})),y=[];g.forEach((function(t){g.forEach((function(e){if(t!==e){var r=t.rect,n=e.rect,i=r[a.start],o=r[a.end],s=n[a.start];i>n[a.end]||s>o||y.push([t,e])}}))})),y.forEach((function(t){var a=t[0],u=t[1],h=a.rect,d=u.rect,v=h[i.start],g=h[i.end],y=d[i.start],m=d[i.end],_=0,b=0,S=!1,w=!1,x=!1;if(g<=l&&f<=y){if(w=!0,Go((b=g+(_=(y-g-(f-l))/2)+(f-l)/2)-p)>r)return}else if(gr)return}else{if(!(gr)return}_&&vi(e,d,n,o)&&(_>s||c.push({type:n,pos:"vertical"===n?[b,0]:[0,b],element:u.element,size:0,className:u.className,isStart:S,isCenter:w,isEnd:x,gap:_,hide:!0,gapRects:[a,u],direction:""}))}))})),c}(t,I,y));var T=We({},e.snapOffset||{left:0,top:0,bottom:0,right:0});if(R.push.apply(R,function(t,e,r,n,i,o,a,s){void 0===i&&(i=0);void 0===o&&(o=0);var u=[],c=a.left,l=a.top;if(e)for(var f=0;f<=n;f+=e)u.push({type:"horizontal",pos:[c,ut(f-o+l,.1)],className:Ti("grid-guideline"),size:r,hide:!s,direction:""});if(t)for(f=0;f<=r;f+=t)u.push({type:"vertical",pos:[ut(f-i+c,.1),l],className:Ti("grid-guideline"),size:n,hide:!s,direction:""});return u}(_,S,i?a:u,i?o:s,c,l,T,E)),n){var z=r.left,B=r.top;T.left+=z,T.top+=B,T.right+=z,T.bottom+=B}return R.push.apply(R,yi(v||!1,d||!1,i?a:u,i?o:s,c,l,T)),R=R.filter((function(t){var e=t.element,r=t.elementRect,n=t.type;if(!e||!r)return!0;var i=r.rect;return vi(I,i,n,x)})),R}function vi(t,e,r,n){return"horizontal"===r?Go(t.right-e.left)<=n||Go(t.left-e.right)<=n||t.left<=e.right&&e.left<=t.right:"vertical"!==r||(Go(t.bottom-e.top)<=n||Go(t.top-e.bottom)<=n||t.top<=e.bottom&&e.top<=t.bottom)}function gi(t,e){return t?t.map((function(t){var r=q(t)?t:{pos:t},n=r.pos;return L(n)?r:We(We({},r),{pos:tt(n,e)})})):[]}function yi(t,e,r,n,i,o,a){void 0===i&&(i=0),void 0===o&&(o=0),void 0===a&&(a={left:0,top:0,right:0,bottom:0});var s=[],u=a.left,c=a.top,l=a.bottom,f=r+a.right-u,p=n+l-c;return gi(t,p).forEach((function(t){s.push({type:"horizontal",pos:[u,ut(t.pos-o+c,.1)],size:f,className:t.className,direction:""})})),gi(e,f).forEach((function(t){s.push({type:"vertical",pos:[ut(t.pos-i+u,.1),c],size:p,className:t.className,direction:""})})),s}function mi(t){var e=t.state,r=e.container,n=t.props.snapContainer||r;if(e.snapContainer===n&&e.guidelines&&e.guidelines.length)return!1;var i=e.containerClientRect,o={left:0,top:0,bottom:0,right:0};if(r!==n){var a=zo(n,!0);if(a){var s=so(a),u=qo(e,[s.left-i.left,s.top-i.top]),c=qo(e,[s.right-i.right,s.bottom-i.bottom]);o.left=ut(u[0],1e-5),o.top=ut(u[1],1e-5),o.right=ut(c[0],1e-5),o.bottom=ut(c[1],1e-5)}}return e.snapContainer=n,e.snapOffset=o,e.guidelines=di(t),e.enableSnap=!0,!0}function _i(t,e,r,n,i,o){var a=Xi(t,e,r,o?4:3);return lo(a,Rt(i,zr(a,n)))}function bi(t){return t?t/Go(t):0}function Si(t,e,r,n,i,o){var a=function(t,e,r){var n=[];if(r)1!==Go(e[0])||1!==Go(e[1])?n.push([e,[-1,-1]],[e,[-1,1]],[e,[1,-1]],[e,[1,1]]):n.push([e,[t[0],-t[1]]],[e,[-t[0],t[1]]]),n.push([e,t]);else if(t[0]&&t[1]||!t[0]&&!t[1]){var i=t[0]?t:[1,1];[1,-1].forEach((function(t){[1,-1].forEach((function(r){var o=[t*i[0],r*i[1]];e[0]===o[0]&&e[1]===o[1]||n.push([e,o])}))}))}else t[0]?(1===Go(e[0])?[1]:[1,-1]).forEach((function(r){n.push([[e[0],-1],[r*t[0],-1]],[[e[0],0],[r*t[0],0]],[[e[0],1],[r*t[0],1]])})):t[1]&&(1===Go(e[1])?[1]:[1,-1]).forEach((function(r){n.push([[-1,e[1]],[-1,r*t[1]]],[[0,e[1]],[0,r*t[1]]],[[1,e[1]],[1,r*t[1]]])}));return n}(r,o.fixedDirection,n),s=Nn(t,e,r,n),u=__spreadArray(__spreadArray([],Xn(t,e,a,n,i,o),!0),Ln(t,s,o),!0),c=Tn(u,0),l=Tn(u,1);return{width:{isBound:c.isBound,offset:c.offset[0]},height:{isBound:l.isBound,offset:l.offset[1]}}}function wi(t,e,r,n,i,o,a,s){for(var u=fo(t.state),c=t.props.keepRatio,l=0,f=0,p=0;p<2;++p){var h=Si(t,e(l,f),i,c,a,s),d=h.width,v=h.height,g=d.isBound,y=v.isBound,m=d.offset,_=v.offset;if(1===p&&(g||(m=0),y||(_=0)),0===p&&a&&!g&&!y)return[0,0];if(c){var b=Go(m)*(r?1/r:1),S=Go(_)*(n?1/n:1);(g&&y?b=0||n.push({type:"bounds",pos:t})})),f.forEach((function(t){X(i,(function(e){var r=e.type,n=e.pos;return"bounds"===r&&n===t}))>=0||i.push({type:"bounds",pos:t})}))}var Mi=To("",["resizable","scalable"]),Ii="snapRotationThreshold",Ai="snapRotationDegrees",Ri={name:"snappable",dragRelation:"strong",props:["snappable","snapContainer","snapDirections","elementSnapDirections","snapGap","snapGridWidth","snapGridHeight","isDisplaySnapDigit","isDisplayInnerSnapDigit","isDisplayGridGuidelines","snapDigit","snapThreshold","snapRenderThreshold",Ii,Ai,"horizontalGuidelines","verticalGuidelines","elementGuidelines","bounds","innerBounds","snapDistFormat","maxSnapElementGuidelineDistance","maxSnapElementGapDistance"],events:["snap"],css:[":host {\n--bounds-color: #d66;\n}\n.guideline {\npointer-events: none;\nz-index: 2;\n}\n.guideline.bounds {\nbackground: #d66;\nbackground: var(--bounds-color);\n}\n.guideline-group {\nposition: absolute;\ntop: 0;\nleft: 0;\n}\n.guideline-group .size-value {\nposition: absolute;\ncolor: #f55;\nfont-size: 12px;\nfont-size: calc(12px * var(--zoom));\nfont-weight: bold;\n}\n.guideline-group.horizontal .size-value {\ntransform-origin: 50% 100%;\ntransform: translateX(-50%);\nleft: 50%;\nbottom: 5px;\nbottom: calc(2px + 3px * var(--zoom));\n}\n.guideline-group.vertical .size-value {\ntransform-origin: 0% 50%;\ntop: 50%;\ntransform: translateY(-50%);\nleft: 5px;\nleft: calc(2px + 3px * var(--zoom));\n}\n.guideline.gap {\nbackground: #f55;\n}\n.size-value.gap {\ncolor: #f55;\n}\n"],render:function(t,e){var r=t.state,n=r.top,i=r.left,o=r.pos1,a=r.pos2,s=r.pos3,u=r.pos4,c=r.snapRenderInfo,l=t.props.snapRenderThreshold,f=void 0===l?1:l;if(!c||!c.render||!wn(t,""))return[];r.guidelines=di(t);var p=Math.min(o[0],a[0],s[0],u[0]),h=Math.min(o[1],a[1],s[1],u[1]),d=c.externalPoses||[],v=fo(t.state),g=[],y=[],m=[],_=[],b=[],S=$i(v),w=S.width,x=S.height,E=S.top,O=S.left,C=S.bottom,k=S.right,D={left:O,right:k,top:E,bottom:C,center:(O+k)/2,middle:(E+C)/2},M=d.length>0,I=M?$i(d):{};if(!c.request){if(c.direction&&b.push(An(t,v,c.direction,f)),c.snap){var A=$i(v);c.center&&(A.middle=(A.top+A.bottom)/2,A.center=(A.left+A.right)/2),b.push(Dn(t,A,f))}M&&(c.center&&(I.middle=(I.top+I.bottom)/2,I.center=(I.left+I.right)/2),b.push(Dn(t,I,f))),b.forEach((function(t){var e=t.vertical.posInfos,r=t.horizontal.posInfos;g.push.apply(g,e.filter((function(t){return t.guidelineInfos.some((function(t){return!t.guideline.hide}))})).map((function(t){return{type:"snap",pos:t.pos}}))),y.push.apply(y,r.filter((function(t){return t.guidelineInfos.some((function(t){return!t.guideline.hide}))})).map((function(t){return{type:"snap",pos:t.pos}}))),m.push.apply(m,ki(e)),_.push.apply(_,ki(r))}))}Di(t,[O,k],[E,C],g,y),M&&Di(t,[I.left,I.right],[I.top,I.bottom],g,y,c.externalBounds);var R=__spreadArray(__spreadArray([],m,!0),_,!0),T=R.filter((function(t){return t.element&&!t.gapRects})),z=R.filter((function(t){return t.gapRects})).sort((function(t,e){return t.gap-e.gap}));return bo(t,"onSnap",{guidelines:R.filter((function(t){return!t.element})),elements:T,gaps:z},!0),__spreadArray(__spreadArray(__spreadArray(__spreadArray(__spreadArray(__spreadArray([],hi(t,T,[p,h],D,e),!0),function(t,e,r,n,i){var o=[];return["horizontal","vertical"].forEach((function(a){var s=e.filter((function(t){return t.type===a})).slice(0,1),u="vertical"===a?0:1,c=u?0:1,l=u?Sn:bn,f=u?bn:Sn,p=n[l.start],h=n[l.end],d=n[f.start],v=n[f.end];s.forEach((function(e){var n=e.gap,a=e.gapRects,s=Math.max.apply(Math,__spreadArray([d],a.map((function(t){return t.rect[f.start]})),!1)),g=Math.min.apply(Math,__spreadArray([v],a.map((function(t){return t.rect[f.end]})),!1)),y=(s+g)/2;s!==g&&y!==(d+v)/2&&a.forEach((function(e){var a=e.rect,s=e.className,f=[r[0],r[1]];if(a[l.end]9),"".concat(e?"matrix3d":"matrix","(").concat(Tt(t,!e).join(","),")")}function Wi(t){var e=t.clientWidth,r=t.clientHeight;if(!t)return{x:0,y:0,width:0,height:0,clientWidth:e,clientHeight:r};var n=t.viewBox,i=n&&n.baseVal||{x:0,y:0,width:0,height:0};return{x:i.x,y:i.y,width:i.width||e,height:i.height||r,clientWidth:e,clientHeight:r}}function Vi(t,e){var r=Wi(t),n=r.width,i=r.height,o=r.clientWidth,a=r.clientHeight,s=o/n,u=a/i,c=t.preserveAspectRatio.baseVal,l=c.align,f=c.meetOrSlice,p=[0,0],h=[s,u],d=[0,0];if(1!==l){var v=(l-2)%3,g=Math.floor((l-2)/3);p[0]=n*v/2,p[1]=i*g/2;var y=2===f?Math.max(u,s):Math.min(s,u);h[0]=y,h[1]=y,d[0]=(o-n)/2*v,d[1]=(a-i)/2*g}var m=Gt(h,e);return m[e*(e-1)]=d[0],m[e*(e-1)+1]=d[1],qi(m,e,p)}function Yi(t,e,r){return zt(t,kt(e,r),r)}function Xi(t,e,r,n){return[[0,0],[e,0],[0,r],[e,r]].map((function(e){return Yi(t,e,n)}))}function $i(t){var e=t.map((function(t){return t[0]})),r=t.map((function(t){return t[1]})),n=Math.min.apply(Math,e),i=Math.min.apply(Math,r),o=Math.max.apply(Math,e),a=Math.max.apply(Math,r);return{left:n,top:i,right:o,bottom:a,width:o-n,height:a-i}}function Ji(t,e,r,n){return $i(Xi(t,e,r,n))}function Zi(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function Qi(t,e){return Zi([e[0]-t[0],e[1]-t[1]])}function to(t,e,r,n){void 0===r&&(r=1),void 0===n&&(n=ot(t,e));var i=Qi(t,e);return{transform:"translateY(-50%) translate(".concat(t[0],"px, ").concat(t[1],"px) rotate(").concat(n,"rad) scaleY(").concat(r,")"),width:"".concat(i,"px")}}function eo(t,e){for(var r=[],n=2;n0?t[0]:t[1],e>0?t[1]:t[0])}function oo(t,e){var r=t===yt(t)||t===gt(t),n={clientLeft:t.clientLeft,clientTop:t.clientTop,clientWidth:t.clientWidth,clientHeight:t.clientHeight,scrollWidth:t.scrollWidth,scrollHeight:t.scrollHeight,overflow:!1};return r&&(n.clientHeight=Math.max(e.height,n.clientHeight),n.scrollHeight=Math.max(e.height,n.scrollHeight)),n.overflow="visible"!==tn(t)("overflow"),We(We({},e),n)}function ao(t,e,r,n){var i=t.left,o=t.right,a=t.top,s=t.bottom,u=e.top,c=e.left,l={left:c+i,top:u+a,right:c+o,bottom:u+s,width:o-i,height:s-a};return r&&n?oo(r,l):l}function so(t,e){var r=0,n=0,i=0,o=0;if(t){var a=t.getBoundingClientRect();r=a.left,n=a.top,i=a.width,o=a.height}var s={left:r,top:n,width:i,height:o,right:r+i,bottom:n+o};return t&&e?oo(t,s):s}function uo(t,e,r,n){var i;if(t)i=t;else if(e)i=[0,0];else{i=co(r.target,n)}return i}function co(t,e){if(t){var r=t.getAttribute("data-rotation")||"",n=t.getAttribute("data-direction");if(e.deg=r,n){var i=[0,0];return n.indexOf("w")>-1&&(i[0]=-1),n.indexOf("e")>-1&&(i[0]=1),n.indexOf("n")>-1&&(i[1]=-1),n.indexOf("s")>-1&&(i[1]=1),i}}}function lo(t,e){return[At(e,t[0]),At(e,t[1]),At(e,t[2]),At(e,t[3])]}function fo(t){var e=t.left,r=t.top;return lo([t.pos1,t.pos2,t.pos3,t.pos4],[e,r])}function po(t,e){t[e?"controlAbles":"targetAbles"].forEach((function(e){e.unset&&e.unset(t)}))}function ho(t,e){var r=e?"controlGesto":"targetGesto",n=t[r];!1===(null==n?void 0:n.isIdle())&&po(t,e),null==n||n.unset(),t[r]=null}function vo(t,e){if(e){var r=Kr(e);r.nextStyle=We(We({},r.nextStyle),t)}return{style:t,cssText:Q(t).map((function(e){return"".concat((r=e,n="-",void 0===n&&(n="-"),r.replace(/([a-z])([A-Z])/g,(function(t,e,r){return""+e+n+r.toLowerCase()}))),": ").concat(t[e],";");var r,n})).join("")}}function go(t,e,r){var n=e.afterTransform||e.transform;return We(We({},vo(We(We(We({},t.style),e.style),{transform:n}),r)),{afterTransform:n,transform:t.transform})}function yo(t,e,r,n){var i=e.datas;i.datas||(i.datas={});var o=We(We({},r),{target:t.state.target,clientX:e.clientX,clientY:e.clientY,inputEvent:e.inputEvent,currentTarget:t,moveable:t,datas:i.datas,isFirstDrag:!!e.isFirstDrag,isTrusted:!1!==e.isTrusted,stopAble:function(){i.isEventStart=!1},stopDrag:function(){var t;null===(t=e.stop)||void 0===t||t.call(e)}});return i.isStartEvent?n||(i.lastEvent=o):i.isStartEvent=!0,o}function mo(t,e,r){var n=e.datas,i="isDrag"in r?r.isDrag:e.isDrag;return n.datas||(n.datas={}),We(We({isDrag:i},r),{moveable:t,target:t.state.target,clientX:e.clientX,clientY:e.clientY,inputEvent:e.inputEvent,currentTarget:t,lastEvent:n.lastEvent,isDouble:e.isDouble,datas:n.datas,isFirstDrag:!!e.isFirstDrag})}function _o(t,e,r){t._emitter.on(e,r)}function bo(t,e,r,n){return t.triggerEvent(e,r,n)}function So(t,e){return mt(t).getComputedStyle(t,e)}function wo(t,e,r){var n={},i={};return t.filter((function(t){var o=t.name;if(n[o]||!e.some((function(e){return t[e]})))return!1;if(!r&&t.ableGroup){if(i[t.ableGroup])return!1;i[t.ableGroup]=!0}return n[o]=!0,!0}))}function xo(t,e){return t===e||null==t&&null==e}function Eo(t,e){var r=[],n=[];return t.forEach((function(i,o){var a=e(i,o,t),s=n.indexOf(a),u=r[s]||[];-1===s&&(n.push(a),r.push(u)),u.push(i)})),r}function Oo(t){return t.reduce((function(t,e){return t.concat(e)}),[])}function Co(){for(var t=[],e=0;eMath.PI/2*3?v-g:v-(g+=Math.PI))>2*Math.PI?y-=2*Math.PI:y>Math.PI?y=2*Math.PI-y:y<-Math.PI&&(y=-2*Math.PI-y);var m=Zi([h+e[0],d+e[1]])*Math.cos(y);s=m*Math.sin(g)-h,u=m*Math.cos(g)-d,n[0]<0&&(s*=-1),n[1]<0&&(u*=-1)}else u=(s=p)/r;else s=(u=p)*r}else s=n[0]*e[0],u=n[1]*e[1];return[s,u]}function jo(t,e,r,n){var i,o=r.ratio,a=r.startOffsetWidth,s=r.startOffsetHeight,u=0,c=0,l=n.distX,f=n.distY,p=n.pinchScale,h=n.parentDistance,d=n.parentDist,v=n.parentScale,g=r.fixedDirection,y=[0,1].map((function(e){return Go(t[e]-g[e])})),m=[0,1].map((function(t){var e=y[t];return 0!==e&&(e=2/e),e}));if(d)u=d[0],c=d[1],e&&(u?c||(c=u/o):u=c*o);else if(L(p))u=(p-1)*a,c=(p-1)*s;else if(v)u=(v[0]-1)*a,c=(v[1]-1)*s;else if(h){var _=a*y[0],b=s*y[1],S=Zi([_,b]);u=h/S*_*m[0],c=h/S*b*m[1]}else{var w=Rr({datas:r,distX:l,distY:f});w=m.map((function(t,e){return w[e]*t})),u=(i=Po([a,s],w,o,t,e))[0],c=i[1]}return{distWidth:u,distHeight:c}}function Lo(t,e){if(e){if("left"===t)return{x:"0%",y:"50%"};if("top"===t)return{x:"50%",y:"50%"};if("center"===t)return{x:"50%",y:"50%"};if("right"===t)return{x:"100%",y:"50%"};if("bottom"===t)return{x:"50%",y:"100%"};var r=t.split(" "),n=r[0],i=r[1],o=Lo(n||""),a=Lo(i||""),s=We(We({},o),a),u={x:"50%",y:"50%"};return s.x&&(u.x=s.x),s.y&&(u.y=s.y),s.value&&(s.x&&!s.y&&(u.y=s.value),!s.x&&s.y&&(u.x=s.value)),u}return"left"===t?{x:"0%"}:"right"===t?{x:"100%"}:"top"===t?{y:"0%"}:"bottom"===t?{y:"100%"}:t?"center"===t?{value:"50%"}:{value:t}:{}}function Ko(t,e,r){var n=Lo(t,!0),i=n.x,o=n.y;return[tt(i,e)||0,tt(o,r)||0]}function No(t,e){return t.length===e.length&&t.every((function(t,r){var n=e[r],i=P(t),o=P(n);return i&&o?No(t,n):!i&&!o&&t===n}))}function Fo(t,e,r,n){var i=t[e];return!(e in t)||i!==r&&n(i)!==n(r)?(t[e]=r,r):i}function Uo(t){return t>=0?1:-1}function Go(t){return Math.abs(t)}function Ho(t,e){return function(t){for(var e=[],r=0;r-1}))).filter((function(t){return t.canPinch&&t[l]})),p=yo(t,e,{});n&&(p.targets=n);var h=bo(t,c,p);r.isPinch=!1!==h,r.ables=f;var d=r.isPinch;return!!d&&(f.forEach((function(r){if(o[r.name]=o[r.name]||{},r[l]){var n=We(We({},e),{datas:o[r.name],parentRotate:i,isPinch:!0});r[l](t,n)}})),t.state.snapRenderInfo={request:e.isRequest,direction:[0,0]},d)},pinch:function(t,e){var r=e.datas,n=e.scale,i=e.distance,o=e.originalDatas,a=e.inputEvent,s=e.targets,u=e.angle;if(r.isPinch){var c=i*(1-1/n),l=yo(t,e,{});s&&(l.targets=s);var f="onPinch".concat(s?"Group":"");bo(t,f,l);var p=r.ables,h="drag".concat(s?"Group":"","Control");return p.forEach((function(r){r[h]&&r[h](t,We(We({},e),{datas:o[r.name],inputEvent:a,resolveMatrix:!0,pinchScale:n,parentDistance:c,parentRotate:u,isPinch:!0}))})),l}},pinchEnd:function(t,e){var r=e.datas,n=e.isPinch,i=e.inputEvent,o=e.targets,a=e.originalDatas;if(r.isPinch){var s="onPinch".concat(o?"Group":"","End"),u=mo(t,e,{isDrag:n});o&&(u.targets=o),bo(t,s,u);var c=r.ables,l="drag".concat(o?"Group":"","ControlEnd");return c.forEach((function(r){r[l]&&r[l](t,We(We({},e),{isDrag:n,datas:a[r.name],inputEvent:i,isPinch:!0}))})),n}},pinchGroupStart:function(t,e){return this.pinchStart(t,We(We({},e),{targets:t.props.targets}))},pinchGroup:function(t,e){return this.pinch(t,We(We({},e),{targets:t.props.targets}))},pinchGroupEnd:function(t,e){return this.pinchEnd(t,We(We({},e),{targets:t.props.targets}))}}),Yo=To("scalable"),Xo={name:"scalable",ableGroup:"size",canPinch:!0,props:["scalable","throttleScale","renderDirections","keepRatio","edge","displayAroundControls"],events:["scaleStart","beforeScale","scale","scaleEnd","scaleGroupStart","beforeScaleGroup","scaleGroup","scaleGroupEnd"],render:ln("scalable"),dragControlCondition:Yo,viewClassName:Ro("scalable"),dragControlStart:function(t,e){var r=e.datas,n=e.isPinch,i=e.inputEvent,o=uo(e.parentDirection,n,i,r),a=t.state,s=a.width,u=a.height,c=a.targetTransform,l=a.target,f=a.pos1,p=a.pos2,h=a.pos4;if(!o||!l)return!1;n||Cr(t,e),r.datas={},r.transform=c,r.prevDist=[1,1],r.direction=o,r.startOffsetWidth=s,r.startOffsetHeight=u,r.startValue=[1,1];var d=!o[0]&&!o[1]||o[0]||!o[1];function v(t){r.ratio=t&&isFinite(t)?t:0}function g(t){var e=Zn(r.startPositions,t);r.fixedDirection=e.fixedDirection,r.fixedPosition=e.fixedPosition,r.fixedOffset=e.fixedOffset}Pr(e,"scale"),r.isWidth=d,r.startPositions=fo(t.state),r.setFixedDirection=g,v(st(f,p)/st(p,h)),g([-o[0],-o[1]]);var y=function(t){r.minScaleSize=t},m=function(t){r.maxScaleSize=t};y([-1/0,-1/0]),m([1/0,1/0]);var _=yo(t,e,We(We({direction:o,set:function(t){r.startValue=t},setRatio:v,setFixedDirection:g,setMinScaleSize:y,setMaxScaleSize:m},qr(e)),{dragStart:Jn.dragStart(t,(new xr).dragStart([0,0],e))})),b=bo(t,"onScaleStart",_);return r.startFixedDirection=r.fixedDirection,!1!==b&&(r.isScale=!0,t.state.snapRenderInfo={request:e.isRequest,direction:o}),!!r.isScale&&_},dragControl:function(t,e){kr(e,"scale");var r=e.datas,n=e.parentKeepRatio,i=e.parentFlag,o=e.isPinch,a=e.dragClient,s=e.isRequest,u=e.useSnap,c=e.resolveMatrix,l=r.prevDist,f=r.direction,p=r.startOffsetWidth,h=r.startOffsetHeight,d=r.isScale,v=r.startValue,g=r.isWidth,y=r.ratio;if(!d)return!1;var m=t.props,_=m.throttleScale,b=m.parentMoveable,S=f;f[0]||f[1]||(S=[1,1]);var w=y&&(null!=n?n:m.keepRatio)||!1,x=t.state,E=[v[0],v[1]];function O(){var t=jo(S,w,r,e),n=t.distWidth,i=t.distHeight,o=p?(p+n)/p:1,a=h?(h+i)/h:1;v[0]||(E[0]=n/p),v[1]||(E[1]=i/h);var s=(S[0]||w?o:1)*E[0],u=(S[1]||w?a:1)*E[1];return 0===s&&(s=Uo(l[0])*vr),0===u&&(u=Uo(l[1])*vr),[s,u]}var C=O();if(!o&&t.props.groupable){var k=(x.snapRenderInfo||{}).direction;P(k)&&(k[0]||k[1])&&(x.snapRenderInfo={direction:f,request:e.isRequest})}bo(t,"onBeforeScale",yo(t,e,{scale:C,setFixedDirection:function(t){return r.setFixedDirection(t),C=O()},startFixedDirection:r.startFixedDirection,setScale:function(t){C=t}},!0));var D,M,I=[C[0]/E[0],C[1]/E[1]],A=a,R=[0,0],T=!a&&!i&&o;if(T||c?A=Hr(t,r.targetAllTransform,[0,0],[0,0],r):a||(A=r.fixedPosition),o||(R=Ci(t,I,f,!u&&s,r)),w){S[0]&&S[1]&&R[0]&&R[1]&&(Math.abs(R[0]*p)>Math.abs(R[1]*h)?R[1]=0:R[0]=0);var z=!R[0]&&!R[1];if(z&&(g?I[0]=ut(I[0]*E[0],_)/E[0]:I[1]=ut(I[1]*E[1],_)/E[1]),S[0]&&!S[1]||R[0]&&!R[1]||z&&g){I[0]+=R[0];var B=p*I[0]*E[0]/y;I[1]=B/h/E[1]}else if(!S[0]&&S[1]||!R[0]&&R[1]||z&&!g){I[1]+=R[1];var q=h*I[1]*E[1]*y;I[0]=q/p/E[0]}}else I[0]+=R[0],I[1]+=R[1],R[0]||(I[0]=ut(I[0]*E[0],_)/E[0]),R[1]||(I[1]=ut(I[1]*E[1],_)/E[1]);0===I[0]&&(I[0]=Uo(l[0])*vr),0===I[1]&&(I[1]=Uo(l[1])*vr),D=I,M=[E[0],E[1]],C=[D[0]*M[0],D[1]*M[1]];var j=[p,h],L=[p*C[0],h*C[1]];L=nt(L,r.minScaleSize,r.maxScaleSize,!!w&&y),C=Ho(2,(function(t){return j[t]?L[t]/j[t]:L[t]})),I=Ho(2,(function(t){return C[t]/E[t]}));var K=Ho(2,(function(t){return l[t]?I[t]/l[t]:I[t]})),N="scale(".concat(I.join(", "),")"),F="scale(".concat(C.join(", "),")"),U=Dr(r,F,N),G=!v[0]||!v[1],H=function(t,e,r,n,i,o,a){return Wr(t,e,r,n,i,o,a)}(t,G?F:N,r.fixedDirection,A,r.fixedOffset,r,G),W=T?H:Rt(H,r.prevInverseDist||[0,0]);if(r.prevDist=I,r.prevInverseDist=H,C[0]===l[0]&&C[1]===l[1]&&W.every((function(t){return!t}))&&!b&&!T)return!1;var V=yo(t,e,We({offsetWidth:p,offsetHeight:h,direction:f,scale:C,dist:I,delta:K,isPinch:!!o},Gr(t,U,W,o,e)));return bo(t,"onScale",V),V},dragControlEnd:function(t,e){var r=e.datas;if(!r.isScale)return!1;r.isScale=!1;var n=mo(t,e,{});return bo(t,"onScaleEnd",n),n},dragGroupControlCondition:Yo,dragGroupControlStart:function(t,e){var r=e.datas,n=this.dragControlStart(t,e);if(!n)return!1;var i=en(t,"resizable",e);r.moveableScale=t.scale;var o=nn(t,this,"dragControlStart",e,(function(e,n){return on(t,e,r,n)})),a=function(e){n.setFixedDirection(e),o.forEach((function(n,o){n.setFixedDirection(e),on(t,n.moveable,r,i[o])}))};r.setFixedDirection=a;var s=We(We({},n),{targets:t.props.targets,events:o,setFixedDirection:a}),u=bo(t,"onScaleGroupStart",s);return r.isScale=!1!==u,!!r.isScale&&s},dragGroupControl:function(t,e){var r=e.datas;if(r.isScale){_o(t,"onBeforeScale",(function(r){bo(t,"onBeforeScaleGroup",yo(t,e,We(We({},r),{targets:t.props.targets}),!0))}));var n=this.dragControl(t,e);if(n){var i=n.dist,o=r.moveableScale;t.scale=[i[0]*o[0],i[1]*o[1]];var a=t.props.keepRatio,s=r.fixedPosition,u=nn(t,this,"dragControl",e,(function(e,r){var n=zt(Ft(t.rotation/180*Math.PI,3),[r.datas.originalX*i[0],r.datas.originalY*i[1],1],3),o=n[0],u=n[1];return We(We({},r),{parentDist:null,parentScale:i,parentKeepRatio:a,dragClient:At(s,[o,u])})})),c=We({targets:t.props.targets,events:u},n);return bo(t,"onScaleGroup",c),c}}},dragGroupControlEnd:function(t,e){var r=e.isDrag;if(e.datas.isScale){this.dragControlEnd(t,e);var n=nn(t,this,"dragControlEnd",e);return bo(t,"onScaleGroupEnd",mo(t,e,{targets:t.props.targets,events:n})),r}},request:function(){var t={},e=0,r=0,n=!1;return{isControl:!0,requestStart:function(e){return n=e.useSnap,{datas:t,parentDirection:e.direction||[1,1],useSnap:n}},request:function(i){return e+=i.deltaWidth,r+=i.deltaHeight,{datas:t,parentDist:[e,r],parentKeepRatio:i.keepRatio,useSnap:n}},requestEnd:function(){return{datas:t,isDrag:!0,useSnap:n}}}}};function $o(t,e){return t.map((function(t,r){return z(t,e[r],1,2)}))}function Jo(t,e,r){var n=ot(t,e),i=ot(t,r)-n;return i>=0?i:i+2*Math.PI}var Zo={name:"warpable",ableGroup:"size",props:["warpable","renderDirections","edge","displayAroundControls"],events:["warpStart","warp","warpEnd"],viewClassName:Ro("warpable"),render:function(t,e){var r=t.props,n=r.resizable,i=r.scalable,o=r.warpable,a=r.zoom;if(n||i||!o)return[];var s=t.state,u=s.pos1,c=s.pos2,l=s.pos3,f=s.pos4,p=$o(u,c),h=$o(c,u),d=$o(u,l),v=$o(l,u),g=$o(l,f),y=$o(f,l),m=$o(c,f),_=$o(f,c);return __spreadArray([e.createElement("div",{className:Ti("line"),key:"middeLine1",style:to(p,g,a)}),e.createElement("div",{className:Ti("line"),key:"middeLine2",style:to(h,y,a)}),e.createElement("div",{className:Ti("line"),key:"middeLine3",style:to(d,m,a)}),e.createElement("div",{className:Ti("line"),key:"middeLine4",style:to(v,_,a)})],fn(t,"warpable",e),!0)},dragControlCondition:function(t,e){if(e.isRequest)return!1;var r=e.inputEvent.target;return lt(r,Ti("direction"))&<(r,Ti("warpable"))},dragControlStart:function(t,e){var r=e.datas,n=e.inputEvent,i=t.props.target,o=co(n.target,r);if(!o||!i)return!1;var a=t.state,s=a.transformOrigin,u=a.is3d,c=a.targetTransform,l=a.targetMatrix,f=a.width,p=a.height,h=a.left,d=a.top;return r.datas={},r.targetTransform=c,r.warpTargetMatrix=u?l:Dt(l,3,4),r.targetInverseMatrix=Et(Ot(r.warpTargetMatrix,4),3,4),r.direction=o,r.left=h,r.top=d,r.poses=[[0,0],[f,0],[0,p],[f,p]].map((function(t){return Rt(t,s)})),r.nextPoses=r.poses.map((function(t){var e=t[0],n=t[1];return zt(r.warpTargetMatrix,[e,n,0,1],4)})),r.startValue=Ut(4),r.prevMatrix=Ut(4),r.absolutePoses=fo(a),r.posIndexes=Tr(o),Cr(t,e),Pr(e,"matrix3d"),a.snapRenderInfo={request:e.isRequest,direction:o},!1!==bo(t,"onWarpStart",yo(t,e,We({set:function(t){r.startValue=t}},qr(e))))&&(r.isWarp=!0),r.isWarp},dragControl:function(t,e){var r=e.datas,n=e.isRequest,i=e.distX,o=e.distY,a=r.targetInverseMatrix,s=r.prevMatrix,u=r.isWarp,c=r.startValue,l=r.poses,f=r.posIndexes,p=r.absolutePoses;if(!u)return!1;if(kr(e,"matrix3d"),wn(t,"warpable")){var h=f.map((function(t){return p[t]}));h.length>1&&h.push([(h[0][0]+h[1][0])/2,(h[0][1]+h[1][1])/2]);var d=Vn(t,n,{horizontal:h.map((function(t){return t[1]+o})),vertical:h.map((function(t){return t[0]+i}))}),v=d.horizontal,g=d.vertical;o-=v.offset,i-=g.offset}var y=Rr({datas:r,distX:i,distY:o},!0),m=r.nextPoses.slice();if(f.forEach((function(t){m[t]=At(m[t],y)})),!pr.every((function(t){return e=t.map((function(t){return l[t]})),r=t.map((function(t){return m[t]})),n=Jo(e[0],e[1],e[2]),i=Jo(r[0],r[1],r[2]),o=Math.PI,!(n>=o&&i<=o||n<=o&&i>=o);var e,r,n,i,o})))return!1;var _=Wt(l[0],l[2],l[1],l[3],m[0],m[2],m[1],m[3]);if(!_.length)return!1;var b=Ir(r,It(a,_,4),!0),S=It(Ot(s,4),b,4);r.prevMatrix=b;var w=It(c,b,4),x=Dr(r,"matrix3d(".concat(w.join(", "),")"),"matrix3d(".concat(b.join(", "),")"));return Lr(e,x),bo(t,"onWarp",yo(t,e,We({delta:S,matrix:w,dist:b,multiply:It,transform:x},vo({transform:x},e)))),!0},dragControlEnd:function(t,e){var r=e.datas,n=e.isDrag;return!!r.isWarp&&(r.isWarp=!1,bo(t,"onWarpEnd",mo(t,e,{})),n)}},Qo=Ti("area-pieces"),ta=Ti("area-piece"),ea=Ti("avoid"),ra=Ti("view-dragging");function na(t){var e=t.areaElement;if(e){var r=t.state,n=r.width,i=r.height;pt(e,ea),e.style.cssText+="left: 0px; top: 0px; width: ".concat(n,"px; height: ").concat(i,"px")}}function ia(t){return t.createElement("div",{key:"area_pieces",className:Qo},t.createElement("div",{className:ta}),t.createElement("div",{className:ta}),t.createElement("div",{className:ta}),t.createElement("div",{className:ta}))}var oa={name:"dragArea",props:["dragArea","passDragArea"],events:["click","clickGroup"],render:function(t,e){var r=t.props,n=r.target,i=r.dragArea,o=r.groupable,a=r.passDragArea,s=t.getState(),u=s.width,c=s.height,l=s.renderPoses,f=a?Ti("area","pass"):Ti("area");if(o)return[e.createElement("div",{key:"area",ref:w(t,"areaElement"),className:f}),ia(e)];if(!n||!i)return[];var p=Wt([0,0],[u,0],[0,c],[u,c],l[0],l[1],l[2],l[3]),h=p.length?Hi(p,!0):"none";return[e.createElement("div",{key:"area",ref:w(t,"areaElement"),className:f,style:{top:"0px",left:"0px",width:"".concat(u,"px"),height:"".concat(c,"px"),transformOrigin:"0 0",transform:h}}),ia(e)]},dragStart:function(t,e){var r=e.datas,n=e.clientX,i=e.clientY;if(!e.inputEvent)return!1;r.isDragArea=!1;var o=t.areaElement,a=t.state,s=a.moveableClientRect,u=a.renderPoses,c=a.rootMatrix,l=a.is3d,f=s.left,p=s.top,h=$i(u),d=h.left,v=h.top,g=h.width,y=h.height,m=ko(c,[n-f,i-p],l?4:3),_=m[0],b=m[1],S=[{left:d,top:v,width:g,height:(b-=v)-10},{left:d,top:v,width:(_-=d)-10,height:y},{left:d,top:v+b+10,width:g,height:y-b-10},{left:d+_+10,top:v,width:g-_-10,height:y}],w=[].slice.call(o.nextElementSibling.children);S.forEach((function(t,e){w[e].style.cssText="left: ".concat(t.left,"px;top: ").concat(t.top,"px; width: ").concat(t.width,"px; height: ").concat(t.height,"px;")})),ft(o,ea),a.disableNativeEvent=!0},drag:function(t,e){var r=e.datas,n=e.inputEvent;if(this.enableNativeEvent(t),!n)return!1;r.isDragArea||(r.isDragArea=!0,na(t))},dragEnd:function(t,e){this.enableNativeEvent(t);var r=e.inputEvent,n=e.datas;if(!r)return!1;n.isDragArea||na(t)},dragGroupStart:function(t,e){return this.dragStart(t,e)},dragGroup:function(t,e){return this.drag(t,e)},dragGroupEnd:function(t,e){return this.dragEnd(t,e)},unset:function(t){na(t),t.state.disableNativeEvent=!1},enableNativeEvent:function(t){var e=t.state;e.disableNativeEvent&&J((function(){e.disableNativeEvent=!1}))}},aa=Ve("origin",{props:["origin","svgOrigin"],render:function(t,e){var r,n=t.props,i=n.zoom,o=n.svgOrigin,a=n.groupable,s=t.getState(),u=s.beforeOrigin,c=s.rotation,l=s.svg,f=s.allMatrix,p=s.is3d,h=s.left,d=s.top,v=s.offsetWidth,g=s.offsetHeight;if(!a&&l&&o){var y=Ko(o,v,g);r=eo(c,i,Rt(Yi(f,[y[0],y[1]],p?4:3),[h,d]))}else r=eo(c,i,u);return[e.createElement("div",{className:Ti("control","origin"),style:r,key:"beforeOrigin"})]}});function sa(t){var e=t.scrollContainer;return[e.scrollLeft,e.scrollTop]}var ua={name:"scrollable",canPinch:!0,props:["scrollable","scrollContainer","scrollThreshold","scrollThrottleTime","getScrollPosition","scrollOptions"],events:["scroll","scrollGroup"],dragRelation:"strong",dragStart:function(t,e){var r=t.props,n=r.scrollContainer,i=void 0===n?t.getContainer():n,o=r.scrollOptions,a=new de,s=zo(i,!0);e.datas.dragScroll=a,t.state.dragScroll=a;var u=e.isControl?"controlGesto":"targetGesto",c=e.targets;a.on("scroll",(function(r){var n=r.container,i=r.direction,o=yo(t,e,{scrollContainer:n,direction:i}),a=c?"onScrollGroup":"onScroll";c&&(o.targets=c),bo(t,a,o)})).on("move",(function(e){var r=e.offsetX,n=e.offsetY,i=e.inputEvent;t[u].scrollBy(r,n,i.inputEvent,!0)})).on("scrollDrag",(function(e){(0,e.next)(t[u].getCurrentEvent())})),a.dragStart(e,We({container:s},o))},checkScroll:function(t,e){var r=e.datas.dragScroll;if(r){var n=t.props,i=n.scrollContainer,o=void 0===i?t.getContainer():i,a=n.scrollThreshold,s=void 0===a?0:a,u=n.scrollThrottleTime,c=void 0===u?0:u,l=n.getScrollPosition,f=void 0===l?sa:l,p=n.scrollOptions;return r.drag(e,We({container:o,threshold:s,throttleTime:c,getScrollPosition:function(t){return f({scrollContainer:t.container,direction:t.direction})}},p)),!0}},drag:function(t,e){return this.checkScroll(t,e)},dragEnd:function(t,e){e.datas.dragScroll.dragEnd(),e.datas.dragScroll=null},dragControlStart:function(t,e){return this.dragStart(t,We(We({},e),{isControl:!0}))},dragControl:function(t,e){return this.drag(t,e)},dragControlEnd:function(t,e){return this.dragEnd(t,e)},dragGroupStart:function(t,e){return this.dragStart(t,We(We({},e),{targets:t.props.targets}))},dragGroup:function(t,e){return this.drag(t,We(We({},e),{targets:t.props.targets}))},dragGroupEnd:function(t,e){return this.dragEnd(t,We(We({},e),{targets:t.props.targets}))},dragGroupControlStart:function(t,e){return this.dragStart(t,We(We({},e),{targets:t.props.targets,isControl:!0}))},dragGroupControl:function(t,e){return this.drag(t,We(We({},e),{targets:t.props.targets}))},dragGroupControEnd:function(t,e){return this.dragEnd(t,We(We({},e),{targets:t.props.targets}))},unset:function(t){var e,r=t.state;null===(e=r.dragScroll)||void 0===e||e.dragEnd(),r.dragScroll=null}},ca={name:"",props:["target","dragTarget","dragContainer","container","warpSelf","rootContainer","useResizeObserver","useMutationObserver","zoom","dragFocusedInput","transformOrigin","ables","className","pinchThreshold","pinchOutside","triggerAblesSimultaneously","checkInput","cspNonce","translateZ","hideDefaultLines","props","flushSync","stopPropagation","preventClickEventOnDrag","preventClickDefault","viewContainer","persistData","useAccuratePosition","firstRenderState","linePadding","controlPadding","preventDefault","requestStyles"],events:["changeTargets"]},la=Ve("padding",{props:["padding"],render:function(t,e){var r=t.props;if(r.dragArea)return[];var n=Wo(r.padding||{}),i=n.left,o=n.top,a=n.right,s=n.bottom,u=t.getState(),c=u.renderPoses,l=[u.pos1,u.pos2,u.pos3,u.pos4],f=[];return i>0&&f.push([0,2]),o>0&&f.push([0,1]),a>0&&f.push([1,3]),s>0&&f.push([2,3]),f.map((function(t,r){var n=t[0],i=t[1],o=Wt([0,0],[100,0],[0,100],[100,100],l[n],l[i],c[n],c[i]);if(o.length)return e.createElement("div",{key:"padding".concat(r),className:Ti("padding"),style:{transform:Hi(o,!0)}})}))}}),fa=["nw","ne","se","sw"];function pa(t,e){var r=t[0]+t[1],n=r>e?e/r:1;return t[0]*=n,t[1]=e-t[1]*n,t}var ha=[1,2,5,6],da=[0,3,4,7],va=[1,-1,-1,1],ga=[1,1,-1,-1];function ya(t,e,r,n,i,o,a,s){void 0===i&&(i=0),void 0===o&&(o=0),void 0===a&&(a=r),void 0===s&&(s=n);var u=[],c=!1,l=t.filter((function(t){return!t.virtual})),f=l.map((function(t){var l=t.horizontal,f=t.vertical,p=t.pos;if(f&&!c&&(c=!0,u.push("/")),c){var h=Math.max(0,1===f?p[1]-o:s-p[1]);return u.push(Io(h,n,e)),h}h=Math.max(0,1===l?p[0]-i:a-p[0]);return u.push(Io(h,r,e)),h}));return{radiusPoses:l,styles:u,raws:f}}function ma(t){for(var e=[0,0],r=[0,0],n=t.length,i=0;i-1?t.slice(0,f):t).length,h=t.slice(0,p),d=t.slice(p+1),v=h.length,g=d.length,y=g>0,m=h[0],_=void 0===m?"0px":m,b=h[1],S=void 0===b?_:b,w=h[2],x=void 0===w?_:w,E=h[3],O=void 0===E?S:E,C=d[0],k=void 0===C?_:C,D=d[1],M=void 0===D?y?k:S:D,I=d[2],A=void 0===I?y?k:x:I,R=d[3],T=void 0===R?y?M:O:R,z=[_,S,x,O].map((function(t){return tt(t,e)})),B=[k,M,A,T].map((function(t){return tt(t,r)})),q=z.slice(),P=B.slice();s=pa([q[0],q[1]],e),q[0]=s[0],q[1]=s[1],u=pa([q[3],q[2]],e),q[3]=u[0],q[2]=u[1],c=pa([P[0],P[3]],r),P[0]=c[0],P[3]=c[1],l=pa([P[1],P[2]],r),P[1]=l[0],P[2]=l[1];var j=a?q:q.slice(0,Math.max(o[0],v)),L=a?P:P.slice(0,Math.max(o[1],g));return __spreadArray(__spreadArray([],j.map((function(t,e){var o=fa[e];return{virtual:e>=v,horizontal:va[e],vertical:0,pos:[n+t,i+(-1===ga[e]?r:0)],sub:!0,raw:z[e],direction:o}})),!0),L.map((function(t,r){var o=fa[r];return{virtual:r>=g,horizontal:0,vertical:ga[r],pos:[n+(-1===va[r]?e:0),i+t],sub:!0,raw:B[r],direction:o}})),!0)}var ba=[[0,-1,"n"],[1,0,"e"]],Sa=[[-1,-1,"nw"],[0,-1,"n"],[1,-1,"ne"],[1,0,"e"],[1,1,"se"],[0,1,"s"],[-1,1,"sw"],[-1,0,"w"]];function wa(t,e,r){var n=t.props.clipRelative,i=t.state,o=i.width,a=i.height,s=e,u=s.type,c=s.poses,l="rect"===u,f="circle"===u;if("polygon"===u)return r.map((function(t){return"".concat(Io(t[0],o,n)," ").concat(Io(t[1],a,n))}));if(l||"inset"===u){var p=r[1][1],h=r[3][0],d=r[7][0],v=r[5][1];if(l)return[p,h,v,d].map((function(t){return"".concat(t,"px")}));var g=[p,o-h,a-v,d].map((function(t,e){return Io(t,e%2?o:a,n)}));if(r.length>8){var y=Rt(r[4],r[0]),m=y[0],_=y[1];g.push.apply(g,__spreadArray(["round"],ya(c.slice(8).map((function(t,e){return We(We({},t),{pos:r[e]})})),n,m,_,d,p,h,v).styles,!1))}return g}if(f||"ellipse"===u){var b=r[0],S=Io(Go(r[1][1]-b[1]),f?Math.sqrt((o*o+a*a)/2):a,n);return(g=f?[S]:[Io(Go(r[2][0]-b[0]),o,n),S]).push("at",Io(b[0],o,n),Io(b[1],a,n)),g}}function xa(t,e,r,n){var i=[n,(n+e)/2,e],o=[t,(t+r)/2,r];return Sa.map((function(t){var e=t[0],r=t[1],n=t[2],a=i[e+1],s=o[r+1];return{vertical:Go(r),horizontal:Go(e),direction:n,pos:[a,s]}}))}function Oa(t){var e=[1/0,-1/0],r=[1/0,-1/0];return t.forEach((function(t){var n=t.pos;e[0]=Math.min(e[0],n[0]),e[1]=Math.max(e[1],n[0]),r[0]=Math.min(r[0],n[1]),r[1]=Math.max(r[1],n[1])})),[Go(e[1]-e[0]),Go(r[1]-r[0])]}function ka(t,e,r,n,i){var o,a,s,u,c,l,f;if(t){var p=i;if(!p){var h=tn(t),d=h("clipPath");p="none"!==d?d:h("clip")}if(p&&"none"!==p&&"auto"!==p||(p=n)){var v=W(p),g=v.prefix,y=void 0===g?p:g,m=v.value,_=void 0===m?"":m,b="circle"===y,S=" ";if("polygon"===y){S=",";var w=(D=H(_||"0% 0%, 100% 0%, 100% 100%, 0% 100%")).map((function(t){var n=t.split(" "),i=n[0],o=n[1];return{vertical:1,horizontal:1,pos:[tt(i,e),tt(o,r)]}})),x=_e(w.map((function(t){return t.pos})));return{type:y,clipText:p,poses:w,splitter:S,left:x.minX,right:x.maxX,top:x.minY,bottom:x.maxY}}if(b||"ellipse"===y){var E="",O="",C=0,k=0,D=G(_);if(b){var M;M=void 0===(o=D[0])?"50%":o,E=void 0===(a=D[2])?"50%":a,O=void 0===(s=D[3])?"50%":s,C=tt(M,Math.sqrt((e*e+r*r)/2)),k=C}else{var I,A;I=void 0===(u=D[0])?"50%":u,A=void 0===(c=D[1])?"50%":c,E=void 0===(l=D[3])?"50%":l,O=void 0===(f=D[4])?"50%":f,C=tt(I,e),k=tt(A,r)}var R=[tt(E,e),tt(O,r)];w=__spreadArray([{vertical:1,horizontal:1,pos:R,direction:"nesw"}],ba.slice(0,b?1:2).map((function(t){return{vertical:Go(t[1]),horizontal:t[0],direction:t[2],sub:!0,pos:[R[0]+t[0]*C,R[1]+t[1]*k]}})),!0);return{type:y,clipText:p,radiusX:C,radiusY:k,left:R[0]-C,top:R[1]-k,right:R[0]+C,bottom:R[1]+k,poses:w,splitter:S}}if("inset"===y){var T=(D=G(_||"0 0 0 0")).indexOf("round"),z=(T>-1?D.slice(0,T):D).length,B=D.slice(z+1),q=D.slice(0,z),P=q[0],j=q[1],L=void 0===j?P:j,K=q[2],N=void 0===K?P:K,F=q[3],U=void 0===F?L:F,Y=[P,N].map((function(t){return tt(t,r)})),X=Y[0],$=Y[1],J=[U,L].map((function(t){return tt(t,e)})),Z=J[0],Q=J[1],et=e-Q,rt=r-$,nt=_a(B,et-Z,rt-X,Z,X);return{type:"inset",clipText:p,poses:w=__spreadArray(__spreadArray([],xa(X,et,rt,Z),!0),nt,!0),top:X,left:Z,right:et,bottom:rt,radius:B,splitter:S}}if("rect"===y){S=",";var it=(D=H(_||"0px, ".concat(e,"px, ").concat(r,"px, 0px"))).map((function(t){return V(t).value}));return{type:"rect",clipText:p,poses:w=xa(X=it[0],Q=it[1],$=it[2],Z=it[3]),top:X,right:Q,bottom:$,left:Z,values:D,splitter:S}}}}}function Aa(t,e){var r=Or(t,e),n=r[0],i=r[1],o=e.datas,a=o.clipPath,s=o.clipIndex,u=a,c=u.type,l=u.poses,f=u.splitter,p=l.map((function(t){return t.pos}));if("polygon"===c)p.splice(s,0,[n,i]);else{if("inset"!==c)return;var h=ha.indexOf(s),d=da.indexOf(s),v=l.length;if(function(t,e,r,n,i,o,a,s,u,c,l){void 0===c&&(c=0),void 0===l&&(l=0);var f=ma(t.slice(r)),p=f.horizontalRange,h=f.verticalRange;if(n>-1)for(var d=1===va[n]?o-c:s-o,v=p[1];v<=n;++v){var g=1===ga[v]?l:u,y=0;if(n===v?y=o:0===v?y=c+d:-1===va[v]&&(y=s-(e[r][0]-c)),t.splice(r+v,0,{horizontal:va[v],vertical:0,pos:[y,g]}),e.splice(r+v,0,[y,g]),0===v)break}else if(i>-1){var m=1===ga[i]?a-l:u-a;if(0===p[1]&&0===h[1]){var _=[c+m,l];t.push({horizontal:va[0],vertical:0,pos:_}),e.push(_)}var b=h[0];for(v=h[1];v<=i&&(y=1===va[v]?c:s,g=0,i===v?g=a:0===v?g=l+m:1===ga[v]?g=e[r+b][1]:-1===ga[v]&&(g=u-(e[r+b][1]-l)),t.push({horizontal:0,vertical:ga[v],pos:[y,g]}),e.push([y,g]),0!==v);++v);}}(l,p,8,h,d,n,i,p[4][0],p[4][1],p[0][0],p[0][1]),v===l.length)return}var g=wa(t,a,p),y="".concat(c,"(").concat(g.join(f),")");bo(t,"onClip",yo(t,e,We({clipEventType:"added",clipType:c,poses:p,clipStyles:g,clipStyle:y,distX:0,distY:0},vo({clipPath:y},e))))}function Ra(t,e){var r=e.datas,n=r.clipPath,i=r.clipIndex,o=n,a=o.type,s=o.poses,u=o.splitter,c=s.map((function(t){return t.pos})),l=c.length;if("polygon"===a)s.splice(i,1),c.splice(i,1);else{if("inset"!==a)return;if(i<8)return;if(function(t,e,r,n,i){void 0===i&&(i=e.length);var o=ma(t.slice(n)),a=o.horizontalRange,s=o.verticalRange,u=r-n,c=0;if(0===u)c=i;else if(u>0&&u=s[0]))return;c=s[0]+s[1]-u}t.splice(r,c),e.splice(r,c)}(s,c,i,8,l),l===s.length)return}var f=wa(t,n,c),p="".concat(a,"(").concat(f.join(u),")");bo(t,"onClip",yo(t,e,We({clipEventType:"removed",clipType:a,poses:c,clipStyles:f,clipStyle:p,distX:0,distY:0},vo({clipPath:p},e))))}var Ta={name:"clippable",props:["clippable","defaultClipPath","customClipPath","keepRatio","clipRelative","clipArea","dragWithClip","clipTargetBounds","clipVerticalGuidelines","clipHorizontalGuidelines","clipSnapThreshold"],events:["clipStart","clip","clipEnd"],css:[".control.clip-control {\nbackground: #6d6;\ncursor: pointer;\n}\n.control.clip-control.clip-radius {\nbackground: #d66;\n}\n.line.clip-line {\nbackground: #6e6;\ncursor: move;\nz-index: 1;\n}\n.clip-area {\nposition: absolute;\ntop: 0;\nleft: 0;\n}\n.clip-ellipse {\nposition: absolute;\ncursor: move;\nborder: 1px solid #6d6;\nborder: var(--zoompx) solid #6d6;\nborder-radius: 50%;\ntransform-origin: 0px 0px;\n}",":host {\n--bounds-color: #d66;\n}",".guideline {\npointer-events: none;\nz-index: 2;\n}",".line.guideline.bounds {\nbackground: #d66;\nbackground: var(--bounds-color);\n}"],render:function(t,e){var r=t.props,n=r.customClipPath,i=r.defaultClipPath,o=r.clipArea,a=r.zoom,s=r.groupable,u=t.getState(),c=u.target,l=u.width,f=u.height,p=u.allMatrix,h=u.is3d,d=u.left,v=u.top,g=u.pos1,y=u.pos2,m=u.pos3,_=u.pos4,b=u.clipPathState,S=u.snapBoundInfos,w=u.rotation;if(!c||s)return[];var x=ka(c,l,f,i||"inset",b||n);if(!x)return[];var E=h?4:3,O=x.type,C=x.poses.map((function(t){var e=Yi(p,t.pos,E);return[e[0]-d,e[1]-v]})),k=[],D=[],M="rect"===O,I="inset"===O,A="polygon"===O;if(M||I||A){var R=I?C.slice(0,8):C;D=R.map((function(t,r){var n=0===r?R[R.length-1]:R[r-1],i=ot(n,t),o=Qi(n,t);return e.createElement("div",{key:"clipLine".concat(r),className:Ti("line","clip-line","snap-control"),"data-clip-index":r,style:{width:"".concat(o,"px"),transform:"translate(".concat(n[0],"px, ").concat(n[1],"px) rotate(").concat(i,"rad) scaleY(").concat(a,")")}})}))}if(k=C.map((function(t,r){return e.createElement("div",{key:"clipControl".concat(r),className:Ti("control","clip-control","snap-control"),"data-clip-index":r,style:{transform:"translate(".concat(t[0],"px, ").concat(t[1],"px) rotate(").concat(w,"rad) scale(").concat(a,")")}})})),I&&k.push.apply(k,C.slice(8).map((function(t,r){return e.createElement("div",{key:"clipRadiusControl".concat(r),className:Ti("control","clip-control","clip-radius","snap-control"),"data-clip-index":8+r,style:{transform:"translate(".concat(t[0],"px, ").concat(t[1],"px) rotate(").concat(w,"rad) scale(").concat(a,")")}})}))),"circle"===O||"ellipse"===O){var T=x.left,z=x.top,B=x.radiusX,q=x.radiusY,P=Rt(Yi(p,[T,z],E),Yi(p,[0,0],E)),j=P[0],L=P[1],K="none";if(!o){for(var N=Math.max(10,B/5,q/5),F=[],U=0;U<=N;++U){var G=2*Math.PI/N*U;F.push([B+(B-a)*Math.cos(G),q+(q-a)*Math.sin(G)])}F.push([B,-2]),F.push([-2,-2]),F.push([-2,2*q+2]),F.push([2*B+2,2*q+2]),F.push([2*B+2,-2]),F.push([B,-2]),K="polygon(".concat(F.map((function(t){return"".concat(t[0],"px ").concat(t[1],"px")})).join(", "),")")}k.push(e.createElement("div",{key:"clipEllipse",className:Ti("clip-ellipse","snap-control"),style:{width:"".concat(2*B,"px"),height:"".concat(2*q,"px"),clipPath:K,transform:"translate(".concat(-d+j,"px, ").concat(-v+L,"px) ").concat(Hi(p))}}))}if(o){var H=$i(__spreadArray([g,y,m,_],C,!0)),W=H.width,V=H.height,Y=H.left,X=H.top;if(A||M||I){F=I?C.slice(0,8):C;k.push(e.createElement("div",{key:"clipArea",className:Ti("clip-area","snap-control"),style:{width:"".concat(W,"px"),height:"".concat(V,"px"),transform:"translate(".concat(Y,"px, ").concat(X,"px)"),clipPath:"polygon(".concat(F.map((function(t){return"".concat(t[0]-Y,"px ").concat(t[1]-X,"px")})).join(", "),")")}}))}}return S&&["vertical","horizontal"].forEach((function(t){var r=S[t],n="horizontal"===t;r.isSnap&&D.push.apply(D,r.snap.posInfos.map((function(r,i){var o=r.pos,s=Rt(Yi(p,n?[0,o]:[o,0],E),[d,v]),u=Rt(Yi(p,n?[l,o]:[o,f],E),[d,v]);return un(e,"",s,u,a,"clip".concat(t,"snap").concat(i),"guideline")}))),r.isBound&&D.push.apply(D,r.bounds.map((function(r,i){var o=r.pos,s=Rt(Yi(p,n?[0,o]:[o,0],E),[d,v]),u=Rt(Yi(p,n?[l,o]:[o,f],E),[d,v]);return un(e,"",s,u,a,"clip".concat(t,"bounds").concat(i),"guideline","bounds","bold")})))})),__spreadArray(__spreadArray([],k,!0),D,!0)},dragControlCondition:function(t,e){return e.inputEvent&&(e.inputEvent.target.getAttribute("class")||"").indexOf("clip")>-1},dragStart:function(t,e){var r=t.props.dragWithClip;return!(void 0===r||r)&&this.dragControlStart(t,e)},drag:function(t,e){return this.dragControl(t,We(We({},e),{isDragTarget:!0}))},dragEnd:function(t,e){return this.dragControlEnd(t,e)},dragControlStart:function(t,e){var r=t.state,n=t.props,i=n.defaultClipPath,o=n.customClipPath,a=r.target,s=r.width,u=r.height,c=e.inputEvent?e.inputEvent.target:null,l=c&&c.getAttribute("class")||"",f=e.datas,p=ka(a,s,u,i||"inset",o);if(!p)return!1;var h=p.clipText;return!1===bo(t,"onClipStart",yo(t,e,{clipType:p.type,clipStyle:h,poses:p.poses.map((function(t){return t.pos}))}))?(f.isClipStart=!1,!1):(f.isControl=l&&l.indexOf("clip-control")>-1,f.isLine=l.indexOf("clip-line")>-1,f.isArea=l.indexOf("clip-area")>-1||l.indexOf("clip-ellipse")>-1,f.clipIndex=c?parseInt(c.getAttribute("data-clip-index"),10):-1,f.clipPath=p,f.isClipStart=!0,r.clipPathState=h,Cr(t,e),!0)},dragControl:function(t,e){var r,n,i=e.datas,o=e.originalDatas,a=e.isDragTarget;if(!i.isClipStart)return!1;var s=i,u=s.isControl,c=s.isLine,l=s.isArea,f=s.clipIndex,p=s.clipPath;if(!p)return!1;var h=ro(t.props,"clippable"),d=h.keepRatio,v=0,g=0,y=o.draggable,m=Rr(e);a&&y?(r=y.prevBeforeDist,v=r[0],g=r[1]):(v=m[0],g=m[1]);var _=[v,g],b=t.state,S=b.width,w=b.height,x=!l&&!u&&!c,E=p.type,O=p.poses,C=p.splitter,k=O.map((function(t){return t.pos}));x&&(v=-v,g=-g);var D=!u||"nesw"===O[f].direction,M="inset"===E||"rect"===E,I=O.map((function(){return[0,0]}));if(u&&!D){var A=O[f],R=A.horizontal,T=A.vertical,z=[v*Go(R),g*Go(T)];I=function(t,e,r,n,i){var o=t[e],a=o.direction,s=o.sub,u=t.map((function(){return[0,0]})),c=a?a.split(""):[];if(n&&e<8){var l=c.filter((function(t){return"w"===t||"e"===t})),f=c.filter((function(t){return"n"===t||"s"===t})),p=l[0],h=f[0];u[e]=r;var d=Oa(t),v=d[0],g=d[1],y=v&&g?v/g:0;if(y&&i){var m=t[(e+4)%8].pos,_=[0,0];a.indexOf("w")>-1?_[0]=-1:a.indexOf("e")>-1&&(_[0]=1),a.indexOf("n")>-1?_[1]=-1:a.indexOf("s")>-1&&(_[1]=1);var b=Po([v,g],r,y,_,!0),S=v+b[0],w=g+b[1],x=m[1],E=m[1],O=m[0],C=m[0];-1===_[0]?O=C-S:1===_[0]?C=O+S:(O-=S/2,C+=S/2),-1===_[1]?x=E-w:E=1===_[1]?x+w:(x=E-w/2)+w;var k=xa(x,C,E,O);t.forEach((function(t,e){u[e][0]=k[e].pos[0]-t.pos[0],u[e][1]=k[e].pos[1]-t.pos[1]}))}else t.forEach((function(t,e){var n=t.direction;n&&(n.indexOf(p)>-1&&(u[e][0]=r[0]),n.indexOf(h)>-1&&(u[e][1]=r[1]))})),p&&(u[1][0]=r[0]/2,u[5][0]=r[0]/2),h&&(u[3][1]=r[1]/2,u[7][1]=r[1]/2)}else a&&!s?c.forEach((function(e){var n="n"===e||"s"===e;t.forEach((function(t,i){var o=t.direction,a=t.horizontal,s=t.vertical;o&&-1!==o.indexOf(e)&&(u[i]=[n||!a?0:r[0],n&&s?r[1]:0])}))})):u[e]=r;return u}(O,f,z,M,d)}else D&&(I=k.map((function(){return[v,g]})));var B=k.map((function(t,e){return At(t,I[e])})),q=__spreadArray([],B,!0);b.snapBoundInfos=null;var P="circle"===p.type,j="ellipse"===p.type;if(P||j){var L=Go((rt=$i(B)).bottom-rt.top),K=Go(j?rt.right-rt.left:L),N=B[0][1]+L,F=B[0][0]-K,U=B[0][0]+K;P&&(q.push([U,rt.bottom]),I.push([1,0])),q.push([rt.left,N]),I.push([0,1]),q.push([F,rt.bottom]),I.push([1,0])}var G=yi((h.clipHorizontalGuidelines||[]).map((function(t){return tt("".concat(t),w)})),(h.clipVerticalGuidelines||[]).map((function(t){return tt("".concat(t),S)})),S,w),H=[],W=[];if(P||j)H=[q[4][0],q[2][0]],W=[q[1][1],q[3][1]];else if(M){var V=[q[0],q[2],q[4],q[6]],Y=[I[0],I[2],I[4],I[6]];H=V.filter((function(t,e){return Y[e][0]})).map((function(t){return t[0]})),W=V.filter((function(t,e){return Y[e][1]})).map((function(t){return t[1]}))}else H=q.filter((function(t,e){return I[e][0]})).map((function(t){return t[0]})),W=q.filter((function(t,e){return I[e][1]})).map((function(t){return t[1]}));var X=[0,0],$=Yn(G,h.clipTargetBounds&&{left:0,top:0,right:S,bottom:w},H,W,5),J=$.horizontal,Z=$.vertical,Q=J.offset,et=Z.offset;if(J.isBound&&(X[1]+=Q),Z.isBound&&(X[0]+=et),(j||P)&&0===I[0][0]&&0===I[0][1]){var rt,nt=(rt=$i(B)).bottom-rt.top,it=j?rt.right-rt.left:nt;it-=Z.isBound?Go(et):0===Z.snapIndex?-et:et,nt-=J.isBound?Go(Q):0===J.snapIndex?-Q:Q,P&&(it=nt=Rn(Z,J)>0?nt:it);var ot=q[0];q[1][1]=ot[1]-nt,q[2][0]=ot[0]+it,q[3][1]=ot[1]+nt,q[4][0]=ot[0]-it}else if(M&&d&&u){var at=Oa(O),st=at[0],ut=at[1],ct=st&&ut?st/ut:0,lt=O[f].direction||"",ft=q[1][1];N=q[5][1],F=q[7][0],U=q[3][0];Go(Q)<=Go(et)?Q=Uo(Q)*Go(et)/ct:et=Uo(et)*Go(Q)*ct,lt.indexOf("w")>-1?F-=et:lt.indexOf("e")>-1?U-=et:(F+=et/2,U-=et/2),lt.indexOf("n")>-1?ft-=Q:lt.indexOf("s")>-1?N-=Q:(ft+=Q/2,N-=Q/2);var pt=xa(ft,U,N,F);q.forEach((function(t,e){var r;r=pt[e].pos,t[0]=r[0],t[1]=r[1]}))}else q.forEach((function(t,e){var r=I[e];r[0]&&(t[0]-=et),r[1]&&(t[1]-=Q)}));var ht=wa(t,p,B),dt="".concat(E,"(").concat(ht.join(C),")");if(b.clipPathState=dt,P||j)H=[q[4][0],q[2][0]],W=[q[1][1],q[3][1]];else if(M){H=(V=[q[0],q[2],q[4],q[6]]).map((function(t){return t[0]})),W=V.map((function(t){return t[1]}))}else H=q.map((function(t){return t[0]})),W=q.map((function(t){return t[1]}));if(b.snapBoundInfos=Yn(G,h.clipTargetBounds&&{left:0,top:0,right:S,bottom:w},H,W,1),y){var vt=b.is3d,gt=b.allMatrix,yt=vt?4:3,mt=X;a&&(mt=[_[0]+X[0]-m[0],_[1]+X[1]-m[1]]),y.deltaOffset=It(gt,[mt[0],mt[1],0,0],yt)}return bo(t,"onClip",yo(t,e,We({clipEventType:"changed",clipType:E,poses:B,clipStyle:dt,clipStyles:ht,distX:v,distY:g},vo(((n={})["rect"===E?"clip":"clipPath"]=dt,n),e)))),!0},dragControlEnd:function(t,e){this.unset(t);var r=e.isDrag,n=e.datas,i=e.isDouble,o=n.isLine,a=n.isClipStart,s=n.isControl;return!!a&&(bo(t,"onClipEnd",mo(t,e,{})),i&&(s?Ra(t,e):o&&Aa(t,e)),i||r)},unset:function(t){t.state.clipPathState="",t.state.snapBoundInfos=null}},za={name:"originDraggable",props:["originDraggable","originRelative"],events:["dragOriginStart","dragOrigin","dragOriginEnd"],css:[":host[data-able-origindraggable] .control.origin {\npointer-events: auto;\n}"],dragControlCondition:function(t,e){return e.isRequest?"originDraggable"===e.requestAble:lt(e.inputEvent.target,Ti("origin"))},dragControlStart:function(t,e){var r=e.datas;Cr(t,e);var n=yo(t,e,{dragStart:Jn.dragStart(t,(new xr).dragStart([0,0],e))}),i=bo(t,"onDragOriginStart",n);return r.startOrigin=t.state.transformOrigin,r.startTargetOrigin=t.state.targetOrigin,r.prevOrigin=[0,0],r.isDragOrigin=!0,!1===i?(r.isDragOrigin=!1,!1):n},dragControl:function(t,e){var r=e.datas,n=e.isPinch,i=e.isRequest;if(!r.isDragOrigin)return!1;var o=Rr(e),a=o[0],s=o[1],u=t.state,c=u.width,l=u.height,f=u.offsetMatrix,p=u.targetMatrix,h=u.is3d,d=t.props.originRelative,v=void 0===d||d,g=h?4:3,y=[a,s];if(i){var m=e.distOrigin;(m[0]||m[1])&&(y=m)}var _=At(r.startOrigin,y),b=At(r.startTargetOrigin,y),S=Rt(y,r.prevOrigin),w=Br(f,p,_,g),x=t.getRect(),E=$i(Xi(w,c,l,g)),O=[x.left-E.left,x.top-E.top];r.prevOrigin=y;var C=[Io(b[0],c,v),Io(b[1],l,v)].join(" "),k=Jn.drag(t,wr(e,t.state,O,!!n,!1)),D=yo(t,e,We(We({width:c,height:l,origin:_,dist:y,delta:S,transformOrigin:C,drag:k},vo({transformOrigin:C,transform:k.transform},e)),{afterTransform:k.transform}));return bo(t,"onDragOrigin",D),D},dragControlEnd:function(t,e){return!!e.datas.isDragOrigin&&(bo(t,"onDragOriginEnd",mo(t,e,{})),!0)},dragGroupControlCondition:function(t,e){return this.dragControlCondition(t,e)},dragGroupControlStart:function(t,e){return!!this.dragControlStart(t,e)},dragGroupControl:function(t,e){var r=this.dragControl(t,e);return!!r&&(t.transformOrigin=r.transformOrigin,!0)},request:function(t){var e={},r=t.getRect(),n=0,i=0,o=r.transformOrigin,a=[0,0];return{isControl:!0,requestStart:function(){return{datas:e}},request:function(t){return"deltaOrigin"in t?(a[0]+=t.deltaOrigin[0],a[1]+=t.deltaOrigin[1]):"origin"in t?(a[0]=t.origin[0]-o[0],a[1]=t.origin[1]-o[1]):("x"in t?n=t.x-r.left:"deltaX"in t&&(n+=t.deltaX),"y"in t?i=t.y-r.top:"deltaY"in t&&(i+=t.deltaY)),{datas:e,distX:n,distY:i,distOrigin:a}},requestEnd:function(){return{datas:e,isDrag:!0}}}}};function qa(t,e,r,n,i){void 0===n&&(n=[0,0]);return _a(t&&"0px"!==t?G(t):[],e,r,0,0,n,i)}function Pa(t,e,r,n,i){var o=t.state,a=o.width,s=o.height,u=ya(i,t.props.roundRelative,a,s),c=u.raws,l=u.styles,f=function(t,e){return void 0===e&&(e=t.map((function(t){return t.raw}))),{horizontals:t.map((function(t,r){return t.horizontal?e[r]:null})).filter((function(t){return null!=t})),verticals:t.map((function(t,r){return t.vertical?e[r]:null})).filter((function(t){return null!=t}))}}(u.radiusPoses,c),p=f.horizontals,h=f.verticals,d=l.join(" ");o.borderRadiusState=d;var v=yo(t,e,We({horizontals:p,verticals:h,borderRadius:d,width:a,height:s,delta:n,dist:r},vo({borderRadius:d},e)));return bo(t,"onRound",v),v}function ja(t){var e,r,n=t.getState().style,i=n.borderRadius||"";if(!i&&t.props.groupable){var o=t.moveables[0],a=t.getTargets()[0];a&&((null==o?void 0:o.props.target)===a?(i=null!==(r=null===(e=t.moveables[0])||void 0===e?void 0:e.state.style.borderRadius)&&void 0!==r?r:"",n.borderRadius=i):(i=So(a).borderRadius,n.borderRadius=i))}return i}var La={name:"roundable",props:["roundable","roundRelative","minRoundControls","maxRoundControls","roundClickable","roundPadding","isDisplayShadowRoundControls"],events:["roundStart","round","roundEnd","roundGroupStart","roundGroup","roundGroupEnd"],css:[".control.border-radius {\nbackground: #d66;\ncursor: pointer;\nz-index: 3;\n}",".control.border-radius.vertical {\nbackground: #d6d;\nz-index: 2;\n}",".control.border-radius.virtual {\nopacity: 0.5;\nz-index: 1;\n}",":host.round-line-clickable .line.direction {\ncursor: pointer;\n}"],className:function(t){var e=t.props.roundClickable;return!0===e||"line"===e?Ti("round-line-clickable"):""},requestStyle:function(){return["borderRadius"]},requestChildStyle:function(){return["borderRadius"]},render:function(t,e){var r=t.getState(),n=r.target,i=r.width,o=r.height,a=r.allMatrix,s=r.is3d,u=r.left,c=r.top,l=r.borderRadiusState,f=t.props,p=f.minRoundControls,h=void 0===p?[0,0]:p,d=f.maxRoundControls,v=void 0===d?[4,4]:d,g=f.zoom,y=f.roundPadding,m=void 0===y?0:y,_=f.isDisplayShadowRoundControls,b=f.groupable;if(!n)return null;var S=l||ja(t),w=s?4:3,x=qa(S,i,o,h,!0);if(!x)return null;var E=0,O=0,C=b?[0,0]:[u,c];return x.map((function(t,r){var n=t.horizontal,i=t.vertical,o=t.direction||"",s=__spreadArray([],t.pos,!0);O+=Math.abs(n),E+=Math.abs(i),n&&o.indexOf("n")>-1&&(s[1]-=m),i&&o.indexOf("w")>-1&&(s[0]-=m),n&&o.indexOf("s")>-1&&(s[1]+=m),i&&o.indexOf("e")>-1&&(s[0]+=m);var u=Rt(Yi(a,s,w),C),c=t.vertical?E<=v[1]&&(_||!t.virtual):O<=v[0]&&(_||!t.virtual);return e.createElement("div",{key:"borderRadiusControl".concat(r),className:Ti("control","border-radius",t.vertical?"vertical":"",t.virtual?"virtual":""),"data-radius-index":r,style:{display:c?"block":"none",transform:"translate(".concat(u[0],"px, ").concat(u[1],"px) scale(").concat(g,")")}})}))},dragControlCondition:function(t,e){if(!e.inputEvent||e.isRequest)return!1;var r=e.inputEvent.target.getAttribute("class")||"";return r.indexOf("border-radius")>-1||r.indexOf("moveable-line")>-1&&r.indexOf("moveable-direction")>-1},dragGroupControlCondition:function(t,e){return this.dragControlCondition(t,e)},dragControlStart:function(t,e){var r=e.inputEvent,n=e.datas,i=r.target,o=i.getAttribute("class")||"",a=o.indexOf("border-radius")>-1,s=o.indexOf("moveable-line")>-1&&o.indexOf("moveable-direction")>-1,u=a?parseInt(i.getAttribute("data-radius-index"),10):-1,c=-1;if(s){var l=i.getAttribute("data-line-key")||"";l&&(c=parseInt(l.replace(/render-line-/g,""),10),isNaN(c)&&(c=-1))}if(!a&&!s)return!1;var f=yo(t,e,{});if(!1===bo(t,"onRoundStart",f))return!1;n.lineIndex=c,n.controlIndex=u,n.isControl=a,n.isLine=s,Cr(t,e);var p=t.props,h=p.roundRelative,d=p.minRoundControls,v=void 0===d?[0,0]:d,g=t.state,y=g.width,m=g.height;n.isRound=!0,n.prevDist=[0,0];var _=qa(ja(t)||"",y,m,v,!0)||[];return n.controlPoses=_,g.borderRadiusState=ya(_,h,y,m).styles.join(" "),f},dragControl:function(t,e){var r=e.datas,n=r.controlPoses;if(!r.isRound||!r.isControl||!n.length)return!1;var i=r.controlIndex,o=Rr(e),a=o[0],s=o[1],u=[a,s],c=Rt(u,r.prevDist),l=t.props.maxRoundControls,f=void 0===l?[4,4]:l,p=t.state,h=p.width,d=p.height,v=n[i],g=v.vertical,y=v.horizontal,m=n.map((function(t){var e=t.horizontal,r=t.vertical,n=[e*y*u[0],r*g*u[1]];if(e){if(1===f[0])return n;if(f[0]<4&&e!==y)return n}else{if(0===f[1])return n[1]=r*y*u[0]/h*d,n;if(g){if(1===f[1])return n;if(f[1]<4&&r!==g)return n}}return[0,0]}));m[i]=u;var _=n.map((function(t,e){return We(We({},t),{pos:At(t.pos,m[e])})}));return i<4?_.slice(0,i+1).forEach((function(t){t.virtual=!1})):_.slice(4,i+1).forEach((function(t){t.virtual=!1})),r.prevDist=[a,s],Pa(t,e,u,c,_)},dragControlEnd:function(t,e){var r=t.state;r.borderRadiusState="";var n=e.datas,i=e.isDouble;if(!n.isRound)return!1;var o=n.isControl,a=n.controlIndex,s=n.isLine,u=n.lineIndex,c=n.controlPoses,l=c.filter((function(t){return t.virtual})).length,f=t.props.roundClickable,p=void 0===f||f;if(i&&p){if(!o||!0!==p&&"control"!==p){if(s&&(!0===p||"line"===p)){var h=Or(t,e);!function(t,e,r,n){var i=t.filter((function(t){var e=t.virtual;return t.horizontal&&!e})).length,o=t.filter((function(t){var e=t.virtual;return t.vertical&&!e})).length,a=-1;if(0===e&&(0===i?a=0:1===i&&(a=1)),2===e&&(i<=2?a=2:i<=3&&(a=3)),3===e&&(0===o?a=4:o<4&&(a=7)),1===e&&(o<=1?a=5:o<=2&&(a=6)),-1!==a&&t[a].virtual){var s=t[a];!function(t,e){e<4?t.slice(0,e+1).forEach((function(t){t.virtual=!1})):(t[0].virtual&&(t[0].virtual=!1),t.slice(4,e+1).forEach((function(t){t.virtual=!1})))}(t,a),a<4?s.pos[0]=r:s.pos[1]=n}}(c,u,h[0],h[1])}}else!function(t,e){e<4?t.slice(e,4).forEach((function(t){t.virtual=!0})):t.slice(e).forEach((function(t){t.virtual=!0}))}(c,a);l!==c.filter((function(t){return t.virtual})).length&&Pa(t,e,[0,0],[0,0],c)}var d=mo(t,e,{});return bo(t,"onRoundEnd",d),r.borderRadiusState="",d},dragGroupControlStart:function(t,e){var r=this.dragControlStart(t,e);if(!r)return!1;var n=t.moveables,i=t.props.targets,o=en(t,"roundable",e);return bo(t,"onRoundGroupStart",We({targets:t.props.targets,events:o.map((function(t,e){return We(We({},t),{target:i[e],moveable:n[e],currentTarget:n[e]})}))},r)),r},dragGroupControl:function(t,e){var r=this.dragControl(t,e);if(!r)return!1;var n=t.moveables,i=t.props.targets,o=en(t,"roundable",e),a=We({targets:t.props.targets,events:o.map((function(t,e){return We(We(We({},t),{target:i[e],moveable:n[e],currentTarget:n[e]}),vo({borderRadius:r.borderRadius},t))}))},r);return bo(t,"onRoundGroup",a),a},dragGroupControlEnd:function(t,e){var r=t.moveables,n=t.props.targets,i=en(t,"roundable",e);_o(t,"onRound",(function(e){var o=We({targets:t.props.targets,events:i.map((function(t,i){return We(We(We({},t),{target:n[i],moveable:r[i],currentTarget:r[i]}),vo({borderRadius:e.borderRadius},t))}))},e);bo(t,"onRoundGroup",o)}));var o=this.dragControlEnd(t,e);if(!o)return!1;var a=We({targets:t.props.targets,events:i.map((function(t,e){var i;return We(We({},t),{target:n[e],moveable:r[e],currentTarget:r[e],lastEvent:null===(i=t.datas)||void 0===i?void 0:i.lastEvent})}))},o);return bo(t,"onRoundGroupEnd",a),a},unset:function(t){t.state.borderRadiusState=""}};var Ka={isPinch:!0,name:"beforeRenderable",props:[],events:["beforeRenderStart","beforeRender","beforeRenderEnd","beforeRenderGroupStart","beforeRenderGroup","beforeRenderGroupEnd"],dragRelation:"weak",setTransform:function(t,e){var r=t.state,n=r.is3d,i=r.targetMatrix,o=r.inlineTransform,a=n?"matrix3d(".concat(i.join(","),")"):"matrix(".concat(Tt(i,!0),")"),s=o&&"none"!==o?o:a;e.datas.startTransforms=function(t,e){var r=Ut(e?4:3);return t==="matrix".concat(e?"3d":"","(").concat(r.join(","),")")||"matrix(1,0,0,1,0,0)"===t}(s,n)?[]:G(s)},resetStyle:function(t){var e=t.datas;e.nextStyle={},e.nextTransforms=t.datas.startTransforms,e.nextTransformAppendedIndexes=[]},fillDragStartParams:function(t,e){return yo(t,e,{setTransform:function(t){e.datas.startTransforms=P(t)?t:G(t)},isPinch:!!e.isPinch})},fillDragParams:function(t,e){return yo(t,e,{isPinch:!!e.isPinch})},dragStart:function(t,e){this.setTransform(t,e),this.resetStyle(e),bo(t,"onBeforeRenderStart",this.fillDragStartParams(t,e))},drag:function(t,e){e.datas.startTransforms||this.setTransform(t,e),this.resetStyle(e),bo(t,"onBeforeRender",yo(t,e,{isPinch:!!e.isPinch}))},dragEnd:function(t,e){e.datas.startTransforms||(this.setTransform(t,e),this.resetStyle(e)),bo(t,"onBeforeRenderEnd",yo(t,e,{isPinch:!!e.isPinch,isDrag:e.isDrag}))},dragGroupStart:function(t,e){var r=this;this.dragStart(t,e);var n=en(t,"beforeRenderable",e),i=t.moveables,o=n.map((function(t,e){var n=i[e];return r.setTransform(n,t),r.resetStyle(t),r.fillDragStartParams(n,t)}));bo(t,"onBeforeRenderGroupStart",yo(t,e,{isPinch:!!e.isPinch,targets:t.props.targets,setTransform:function(){},events:o}))},dragGroup:function(t,e){var r=this;this.drag(t,e);var n=en(t,"beforeRenderable",e),i=t.moveables,o=n.map((function(t,e){var n=i[e];return r.resetStyle(t),r.fillDragParams(n,t)}));bo(t,"onBeforeRenderGroup",yo(t,e,{isPinch:!!e.isPinch,targets:t.props.targets,events:o}))},dragGroupEnd:function(t,e){this.dragEnd(t,e),bo(t,"onBeforeRenderGroupEnd",yo(t,e,{isPinch:!!e.isPinch,isDrag:e.isDrag,targets:t.props.targets}))},dragControlStart:function(t,e){return this.dragStart(t,e)},dragControl:function(t,e){return this.drag(t,e)},dragControlEnd:function(t,e){return this.dragEnd(t,e)},dragGroupControlStart:function(t,e){return this.dragGroupStart(t,e)},dragGroupControl:function(t,e){return this.dragGroup(t,e)},dragGroupControlEnd:function(t,e){return this.dragGroupEnd(t,e)}},Na={name:"renderable",props:[],events:["renderStart","render","renderEnd","renderGroupStart","renderGroup","renderGroupEnd"],dragRelation:"weak",dragStart:function(t,e){bo(t,"onRenderStart",yo(t,e,{isPinch:!!e.isPinch}))},drag:function(t,e){bo(t,"onRender",this.fillDragParams(t,e))},dragAfter:function(t,e){return this.drag(t,e)},dragEnd:function(t,e){bo(t,"onRenderEnd",this.fillDragEndParams(t,e))},dragGroupStart:function(t,e){bo(t,"onRenderGroupStart",yo(t,e,{isPinch:!!e.isPinch,targets:t.props.targets}))},dragGroup:function(t,e){var r=this,n=en(t,"beforeRenderable",e),i=t.moveables,o=n.map((function(t,e){var n=i[e];return r.fillDragParams(n,t)}));bo(t,"onRenderGroup",yo(t,e,We(We({isPinch:!!e.isPinch,targets:t.props.targets,transform:Fr(e),transformObject:{}},vo(Ur(e))),{events:o})))},dragGroupEnd:function(t,e){var r=this,n=en(t,"beforeRenderable",e),i=t.moveables,o=n.map((function(t,e){var n=i[e];return r.fillDragEndParams(n,t)}));bo(t,"onRenderGroupEnd",yo(t,e,We({isPinch:!!e.isPinch,isDrag:e.isDrag,targets:t.props.targets,events:o,transformObject:{},transform:Fr(e)},vo(Ur(e)))))},dragControlStart:function(t,e){return this.dragStart(t,e)},dragControl:function(t,e){return this.drag(t,e)},dragControlAfter:function(t,e){return this.dragAfter(t,e)},dragControlEnd:function(t,e){return this.dragEnd(t,e)},dragGroupControlStart:function(t,e){return this.dragGroupStart(t,e)},dragGroupControl:function(t,e){return this.dragGroup(t,e)},dragGroupControlEnd:function(t,e){return this.dragGroupEnd(t,e)},fillDragParams:function(t,e){var r={};return Xt(Nr(e)||[]).forEach((function(t){r[t.name]=t.functionValue})),yo(t,e,We({isPinch:!!e.isPinch,transformObject:r,transform:Fr(e)},vo(Ur(e))))},fillDragEndParams:function(t,e){var r={};return Xt(Nr(e)||[]).forEach((function(t){r[t.name]=t.functionValue})),yo(t,e,We({isPinch:!!e.isPinch,isDrag:e.isDrag,transformObject:r,transform:Fr(e)},vo(Ur(e))))}};function Ua(t,e,r,n,i,o,a){o.clientDistX=o.distX,o.clientDistY=o.distY;var s="Start"===i,u="End"===i,c="After"===i,l=t.state.target,f=o.isRequest,p=n.indexOf("Control")>-1;if(!l||s&&p&&!f&&t.areaElement===o.inputEvent.target)return!1;var h=__spreadArray([],t[e],!0);if(f){var d=o.requestAble;h.some((function(t){return t.name===d}))||h.push.apply(h,t.props.ables.filter((function(t){return t.name===d})))}if(!h.length||h.every((function(t){return t.dragRelation})))return!1;var v,g=o.inputEvent;u&&g&&(v=document.elementFromPoint(o.clientX,o.clientY)||g.target);var y=!1,m=function(){var t;y=!0,null===(t=o.stop)||void 0===t||t.call(o)},_=s&&(!t.targetGesto||!t.controlGesto||!t.targetGesto.isFlag()||!t.controlGesto.isFlag());_&&t.updateRect(i,!0,!1);var b=o.datas,S=p?"controlGesto":"targetGesto",w=t[S],x=function(e,r,n){if(!(r in e)||w!==t[S])return!1;var i=e.name,a=b[i]||(b[i]={});if(s&&(a.isEventStart=!n||!e[n]||e[n](t,o)),!a.isEventStart)return!1;var u=e[r](t,We(We({},o),{stop:m,datas:a,originalDatas:b,inputTarget:v}));return t._emitter.off(),s&&!1===u&&(a.isEventStart=!1),u};_&&h.forEach((function(e){e.unset&&e.unset(t)})),x(Ka,"drag".concat(n).concat(i));var E=0,O=0;r.forEach((function(e){if(y)return!1;var r="".concat(e).concat(n).concat(i),a="".concat(e).concat(n,"Condition");""!==i||f||Do(t.state,o);var u=h.filter((function(t){return t[r]})),c=(u=u.filter((function(t,e){return t.name&&u.indexOf(t)===e}))).filter((function(t){return x(t,r,a)})).length;y&&++E,c&&++O,!y&&s&&u.length&&!c&&(E+=u.filter((function(t){var e=t.name;return!!b[e].isEventStart&&"strong"!==t.dragRelation})).length?1:0)})),c&&!O||x(Na,"drag".concat(n).concat(i));var C=w!==t[S]||E===r.length;if((u||y||C)&&(t.state.gestos={},t.moveables&&t.moveables.forEach((function(t){t.state.gestos={}})),h.forEach((function(e){e.unset&&e.unset(t)}))),s&&!C&&!f&&O&&t.props.preventDefault&&(null==o||o.preventDefault()),t.isUnmounted||C)return!1;(!s&&O&&!a||u)&&(t.props.flushSync||zi)((function(){t.updateRect(u?i:"",!0,!1),t.forceUpdate()}));return s||u||c||!O||a||Ua(t,e,r,n,i+"After",o),!0}function Wa(t){return function(e){var r,n=e.inputEvent.target,i=t.areaElement,o=t._dragTarget;return!(!o||(null===(r=t.controlGesto)||void 0===r?void 0:r.isFlag()))&&(n===o||o.contains(n)||n===i||!t.isMoveableElement(n)&&!t.controlBox.contains(n)||lt(n,"moveable-area")||lt(n,"moveable-padding")||lt(n,"moveable-edgeDraggable"))}}function Va(t,e,r){var n=t.controlBox,i=[],o=t.props.dragTarget;return i.push(n),t.props.dragArea&&!o||i.push(e),Ya(t,i,"targetAbles",r,{dragStart:Wa(t),pinchStart:Wa(t)})}function Ya(t,e,r,n,i){void 0===i&&(i={});var o="targetAbles"===r,a=t.props,s=a.pinchOutside,u=a.pinchThreshold,c=a.preventClickEventOnDrag,l=a.preventClickDefault,f=a.checkInput,p=a.dragFocusedInput,h=a.preventDefault,d={preventDefault:void 0===h||h,preventRightClick:!0,preventWheelClick:!0,container:zo(a.dragContainer,!0)||mt(t.getControlBoxElement()),pinchThreshold:u,pinchOutside:s,preventClickEventOnDrag:!!o&&c,preventClickEventOnDragStart:!!o&&l,preventClickEventByCondition:o?null:function(e){return t.controlBox.contains(e.target)},checkInput:!!o&&f,dragFocusedInput:p},v=new je(e,d),g="Control"===n;return["drag","pinch"].forEach((function(e){["Start","","End"].forEach((function(o){v.on("".concat(e).concat(o),(function(a){var s,u=a.eventType,c="drag"===e&&a.isPinch;!i[u]||i[u](a)?c||(Ua(t,r,"drag"===e?[e]:["drag",e],n,o,a)?(t.props.stopPropagation||"Start"===o&&g)&&(null===(s=null==a?void 0:a.inputEvent)||void 0===s||s.stopPropagation()):a.stop()):a.stop()}))}))})),v}var $a=function(){function EventManager(t,e,r){var n=this;this.target=t,this.moveable=e,this.eventName=r,this.ables=[],this._onEvent=function(t){var e=n.eventName,r=n.moveable;r.state.disableNativeEvent||n.ables.forEach((function(n){n[e](r,{inputEvent:t})}))},t.addEventListener(r.toLowerCase(),this._onEvent)}var t=EventManager.prototype;return t.setAbles=function(t){this.ables=t},t.destroy=function(){this.target.removeEventListener(this.eventName.toLowerCase(),this._onEvent),this.target=null,this.moveable=null},EventManager}();function Za(t,e,r,n){var i;void 0===r&&(r=e);var o=Xr(t,e),a=o.matrixes,s=o.is3d,u=o.targetMatrix,c=o.transformOrigin,l=o.targetOrigin,f=o.offsetContainer,p=o.hasFixed,h=o.zoom,d=function(t,e){if(Zr){var r=$(Zr,(function(r){return r[0][0]==t&&r[0][1]==e}));if(r)return r[1]}var n=Xr(t,e,!0);return Zr&&Zr.push([[t,e],n]),n}(f,r),v=d.matrixes,g=d.is3d,y=d.offsetContainer,m=d.zoom,_=n||g||s,b=_?4:3,S="svg"!==t.tagName.toLowerCase()&&"ownerSVGElement"in t,w=u,x=Ut(b),E=Ut(b),O=Ut(b),C=Ut(b),k=a.length,D=v.map((function(t){return We(We({},t),{matrix:t.matrix?__spreadArray([],t.matrix,!0):void 0})})).reverse();a.reverse(),!s&&_&&(w=Dt(w,3,4),Ui(a)),!g&&_&&Ui(D),D.forEach((function(t){E=It(E,t.matrix,b)}));var M=r||yt(t),I=(null===(i=D[0])||void 0===i?void 0:i.target)||Ki(M,M,!0).offsetParent,A=D.slice(1).reduce((function(t,e){return It(t,e.matrix,b)}),Ut(b));a.forEach((function(t,e){if(k-2===e&&(O=x.slice()),k-1===e&&(C=x.slice()),!t.matrix){var r=function(t,e,r,n,i){var o,a=t.target,s=t.origin,u=e.matrix,c=no(a),l=c.offsetWidth,f=c.offsetHeight,p=r.getBoundingClientRect(),h=[0,0];r===yt(r)&&(h=Fi(a,!0));for(var d=a.getBoundingClientRect(),v=d.left-p.left+r.scrollLeft-(r.clientLeft||0)+h[0],g=d.top-p.top+r.scrollTop-(r.clientTop||0)+h[1],y=d.width,m=d.height,_=Mt(n,i,u),b=Ji(_,l,f,n),S=b.left,w=b.top,x=b.width,E=b.height,O=Yi(_,s,n),C=Rt(O,[S,w]),k=[v+C[0]*y/x,g+C[1]*m/E],D=[0,0],M=0;++M<10;){var I=Ot(i,n);o=Rt(Yi(I,k,n),Yi(I,O,n)),D[0]=o[0],D[1]=o[1];var A=Ji(Mt(n,i,Ht(D,n),u),l,f,n),R=A.left-v,T=A.top-g;if(Go(R)<2&&Go(T)<2)break;k[0]-=R,k[1]-=T}return D.map((function(t){return Math.round(t)}))}(t,a[e+1],I,b,It(A,x,b));t.matrix=Ht(r,b)}x=It(x,t.matrix,b)}));var R=!S&&s;w||(w=Ut(R?4:3));var T=Hi(S&&16===w.length?Dt(w,4,3):w,R),z=E;return E=Et(E,b,b),{hasZoom:1!==h||1!==m,hasFixed:p,matrixes:a,rootMatrix:E,originalRootMatrix:z,beforeMatrix:O,offsetMatrix:C,allMatrix:x,targetMatrix:w,targetTransform:T,inlineTransform:t.style.transform,transformOrigin:c,targetOrigin:l,is3d:_,offsetContainer:f,offsetRootContainer:y}}function Qa(t,e,r,n){void 0===r&&(r=e);var i=0,o=0,a=0,s={},u=no(t);if(t&&(i=u.offsetWidth,o=u.offsetHeight),t){var c=Za(t,e,r,n),l=Er(c.allMatrix,c.transformOrigin,i,o);s=We(We({},c),l);var f=Er(c.allMatrix,[50,50],100,100);a=io([f.pos1,f.pos2],f.direction)}var p=n?4:3;return We(We(We({hasZoom:!1,width:i,height:o,rotation:a},u),{originalRootMatrix:Ut(p),rootMatrix:Ut(p),beforeMatrix:Ut(p),offsetMatrix:Ut(p),allMatrix:Ut(p),targetMatrix:Ut(p),targetTransform:"",inlineTransform:"",transformOrigin:[0,0],targetOrigin:[0,0],is3d:!!n,left:0,top:0,right:0,bottom:0,origin:[0,0],pos1:[0,0],pos2:[0,0],pos3:[0,0],pos4:[0,0],direction:1,hasFixed:!1,offsetContainer:null,offsetRootContainer:null,matrixes:[]}),s)}function ts(t,e,r,n,i,o){void 0===o&&(o=[]);var a=1,s=[0,0],u={left:0,top:0,width:0,height:0,right:0,bottom:0,clientLeft:0,clientTop:0,clientWidth:0,clientHeight:0,scrollWidth:0,scrollHeight:0},c={left:0,top:0,width:0,height:0,right:0,bottom:0,clientLeft:0,clientTop:0,clientWidth:0,clientHeight:0,scrollWidth:0,scrollHeight:0},l={left:0,top:0,width:0,height:0,right:0,bottom:0,clientLeft:0,clientTop:0,clientWidth:0,clientHeight:0,scrollWidth:0,scrollHeight:0},f={left:0,top:0,width:0,height:0,right:0,bottom:0,clientLeft:0,clientTop:0,clientWidth:0,clientHeight:0,scrollWidth:0,scrollHeight:0},p=[0,0],h={},d=Qa(e,r,i,!0);if(e){var v=tn(e);o.forEach((function(t){h[t]=v(t)}));var g=d.is3d?4:3,y=Er(d.offsetMatrix,At(d.transformOrigin,Ct(d.targetMatrix,g)),d.width,d.height);a=y.direction,s=At(y.origin,[y.left-d.left,y.top-d.top]),f=so(d.offsetRootContainer);var m=Ki(n,n,!0).offsetParent||d.offsetRootContainer;if(d.hasZoom){var _=Er(It(d.originalRootMatrix,d.allMatrix),d.transformOrigin,d.width,d.height),b=Er(d.originalRootMatrix,ji(tn(m)("transformOrigin")).map((function(t){return parseFloat(t)})),m.offsetWidth,m.offsetHeight);if(u=ao(_,f),l=ao(b,f,m,!0),t){var S=_.left,w=_.top;c=ao({left:S,top:w,bottom:w,right:w},f)}}else{u=so(e),l=function(t){var e=null==Jr?void 0:Jr.get(t);if(e)return e;var r=so(t,!0);return Jr&&Jr.set(t,r),r}(m),t&&(c=so(t));var x=l.left,E=l.top,O=l.clientLeft,C=l.clientTop,k=[u.left-x,u.top-E];p=Rt(ko(d.rootMatrix,k,4),[O+d.left,C+d.top])}}return We({targetClientRect:u,containerClientRect:l,moveableClientRect:c,rootContainerClientRect:f,beforeDirection:a,beforeOrigin:s,originalBeforeOrigin:s,target:e,style:h,offsetDelta:p},d)}function es(t){var e=t.pos1,r=t.pos2,n=t.pos3,i=t.pos4;if(!(e&&r&&n&&i))return null;var o=_e([e,r,n,i]),a=[o.minX,o.minY],s=Rt(t.origin,a);return e=Rt(e,a),r=Rt(r,a),n=Rt(n,a),i=Rt(i,a),We(We({},t),{left:t.left,top:t.top,posDelta:a,pos1:e,pos2:r,pos3:n,pos4:i,origin:s,beforeOrigin:s,isPersisted:!0})}var rs=function(t){function MoveableManager(){var e=null!==t&&t.apply(this,arguments)||this;return e.state=We({container:null,gestos:{},renderPoses:[[0,0],[0,0],[0,0],[0,0]],disableNativeEvent:!1,posDelta:[0,0]},ts(null)),e.renderState={},e.enabledAbles=[],e.targetAbles=[],e.controlAbles=[],e.rotation=0,e.scale=[1,1],e.isMoveableMounted=!1,e.isUnmounted=!1,e.events={mouseEnter:null,mouseLeave:null},e._emitter=new ue,e._prevDragTarget=null,e._dragTarget=null,e._prevDragArea=!1,e._isPropTargetChanged=!1,e._hasFirstTarget=!1,e._reiszeObserver=null,e._observerId=0,e._mutationObserver=null,e._rootContainer=null,e._viewContainer=null,e._viewClassNames=[],e._store={},e.checkUpdateRect=function(){if(!e.isDragging()){var t=e.props.parentMoveable;t?t.checkUpdateRect():(Z(e._observerId),e._observerId=J((function(){e.isDragging()||e.updateRect()})))}},e._onPreventClick=function(t){t.stopPropagation(),t.preventDefault()},e}He(MoveableManager,t);var e=MoveableManager.prototype;return e.render=function(){var t=this.props,e=this.getState(),r=t.parentPosition,n=t.className,i=t.target,o=t.zoom,a=t.cspNonce,s=t.translateZ,u=t.cssStyled,c=t.groupable,l=t.linePadding,f=t.controlPadding;this._checkUpdateRootContainer(),this.checkUpdate(),this.updateRenderPoses();var p=r||[0,0],h=p[0],d=p[1],v=e.left,g=e.top,y=e.target,m=e.direction,_=e.hasFixed,b=e.offsetDelta,S=t.targets,x=this.isDragging(),E={};this.getEnabledAbles().forEach((function(t){E["data-able-".concat(t.name.toLowerCase())]=!0}));var O=this._getAbleClassName(),C=S&&S.length&&(y||c)||i||!this._hasFirstTarget&&this.state.isPersisted,k=this.controlBox||this.props.firstRenderState||this.props.persistData,D=[v-h,g-d];!c&&t.useAccuratePosition&&(D[0]+=b[0],D[1]+=b[1]);var M={position:_?"fixed":"absolute",display:C?"block":"none",visibility:k?"visible":"hidden",transform:"translate3d(".concat(D[0],"px, ").concat(D[1],"px, ").concat(s,")"),"--zoom":o,"--zoompx":"".concat(o,"px")};return l&&(M["--moveable-line-padding"]=l),f&&(M["--moveable-control-padding"]=f),ke.createElement(u,We({cspNonce:a,ref:w(this,"controlBox"),className:"".concat(Ti("control-box",-1===m?"reverse":"",x?"dragging":"")," ").concat(O," ").concat(n)},E,{onClick:this._onPreventClick,style:M}),this.renderAbles(),this._renderLines())},e.componentDidMount=function(){this.isMoveableMounted=!0,this.isUnmounted=!1;var t=this.props,e=t.parentMoveable,r=t.container;this._checkUpdateRootContainer(),this._checkUpdateViewContainer(),this._updateTargets(),this._updateNativeEvents(),this._updateEvents(),this.updateCheckInput(),this._updateObserver(this.props),r||e||this.state.isPersisted||(this.updateRect("",!1,!1),this.forceUpdate())},e.componentDidUpdate=function(t){this._checkUpdateRootContainer(),this._checkUpdateViewContainer(),this._updateNativeEvents(),this._updateTargets(),this._updateEvents(),this.updateCheckInput(),this._updateObserver(t)},e.componentWillUnmount=function(){var t,e;this.isMoveableMounted=!1,this.isUnmounted=!0,this._emitter.off(),null===(t=this._reiszeObserver)||void 0===t||t.disconnect(),null===(e=this._mutationObserver)||void 0===e||e.disconnect(),this._viewContainer&&this._changeAbleViewClassNames([]),ho(this,!1),ho(this,!0);var r=this.events;for(var n in r){var i=r[n];i&&i.destroy()}},e.getTargets=function(){var t=this.props.target;return t?[t]:[]},e.getAble=function(t){return $(this.props.ables||[],(function(e){return e.name===t}))},e.getContainer=function(){var t=this.props,e=t.parentMoveable,r=t.wrapperMoveable;return t.container||r&&r.getContainer()||e&&e.getContainer()||this.controlBox.parentElement},e.getControlBoxElement=function(){return this.controlBox},e.isMoveableElement=function(t){var e;return t&&((null===(e=t.getAttribute)||void 0===e?void 0:e.call(t,"class"))||"").indexOf(cr)>-1},e.dragStart=function(t){var e=this.targetGesto,r=this.controlGesto;return e&&Wa(this)({inputEvent:t})?e.isFlag()||e.triggerDragStart(t):r&&this.isMoveableElement(t.target)&&(r.isFlag()||r.triggerDragStart(t)),this},e.hitTest=function(t){var e,r=this.state,n=r.target,i=r.pos1,o=r.pos2,a=r.pos3,s=r.pos4,u=r.targetClientRect;if(!n)return 0;if(bt(t)){var c=t.getBoundingClientRect();e={left:c.left,top:c.top,width:c.width,height:c.height}}else e=We({width:0,height:0},t);var l=e.left,f=e.top,p=e.width,h=e.height,d=me([i,o,s,a],u),v=Ce(d,[[l,f],[l+p,f],[l+p,f+h],[l,f+h]]),g=ye(d);return v&&g?Math.min(100,v/g*100):0},e.isInside=function(t,e){var r=this.state,n=r.target,i=r.pos1,o=r.pos2,a=r.pos3,s=r.pos4,u=r.targetClientRect;return!!n&&be([t,e],me([i,o,s,a],u))},e.updateRect=function(t,e,r){void 0===r&&(r=!0);var n=this.props,i=!n.parentPosition&&!n.wrapperMoveable;i&&Qr(!0);var o=n.parentMoveable,a=this.state.target||n.target,s=this.getContainer(),u=o?o._rootContainer:this._rootContainer,c=ts(this.controlBox,a,s,s,u||s,this._getRequestStyles());if(!a&&this._hasFirstTarget&&n.persistData){var l=es(n.persistData);for(var f in l)c[f]=l[f]}i&&Qr(),this.updateState(c,!o&&r)},e.isDragging=function(t){var e,r,n=this.targetGesto,i=this.controlGesto;return(null==n?void 0:n.isFlag())?!t||!!(null===(e=n.getEventData()[t])||void 0===e?void 0:e.isEventStart):!!(null==i?void 0:i.isFlag())&&(!t||!!(null===(r=i.getEventData()[t])||void 0===r?void 0:r.isEventStart))},e.updateTarget=function(t){this.updateRect(t,!0)},e.getRect=function(){var t=this.state,e=fo(this.state),r=e[0],n=e[1],i=e[2],o=e[3],a=$i(e),s=t.width,u=t.height,c=a.width,l=a.height,f=a.left,p=a.top,h=[t.left,t.top],d=At(h,t.origin);return{width:c,height:l,left:f,top:p,pos1:r,pos2:n,pos3:i,pos4:o,offsetWidth:s,offsetHeight:u,beforeOrigin:At(h,t.beforeOrigin),origin:d,transformOrigin:t.transformOrigin,rotation:this.getRotation()}},e.getManager=function(){return this},e.stopDrag=function(t){var e;t&&"target"!==t||(!1===(null==(e=this.targetGesto)?void 0:e.isIdle())&&po(this,!1),null==e||e.stop());t&&"control"!==t||(!1===(null==(e=this.controlGesto)?void 0:e.isIdle())&&po(this,!0),null==e||e.stop())},e.getRotation=function(){var t=this.state;return function(t,e,r){var n=ot(t,e)/Math.PI*180;return(n=r>=0?n:180-n)>=0?n:360+n}(t.pos1,t.pos2,t.direction)},e.request=function(t,e,r){void 0===e&&(e={});var n=this.props,i=n.ables,o=n.groupable,a=i.filter((function(e){return e.name===t}))[0];if(this.isDragging()||!a||!a.request)return{request:function(){return this},requestEnd:function(){return this}};var s=this,u=a.request(this),c=r||e.isInstant,l=u.isControl?"controlAbles":"targetAbles",f="".concat(o?"Group":"").concat(u.isControl?"Control":""),p={request:function(e){return Ua(s,l,["drag"],f,"",We(We({},u.request(e)),{requestAble:t,isRequest:!0}),c),this},requestEnd:function(){return Ua(s,l,["drag"],f,"End",We(We({},u.requestEnd()),{requestAble:t,isRequest:!0}),c),this}};return Ua(s,l,["drag"],f,"Start",We(We({},u.requestStart(e)),{requestAble:t,isRequest:!0}),c),c?p.request(e).requestEnd():p},e.destroy=function(){this.componentWillUnmount()},e.updateRenderPoses=function(){var t=this.getState(),e=this.props,r=e.padding,n=t.originalBeforeOrigin,i=t.transformOrigin,o=t.allMatrix,a=t.is3d,s=t.pos1,u=t.pos2,c=t.pos3,l=t.pos4,f=t.left,p=t.top,h=t.isPersisted;if(r){var d=Wo(r),v=d.left,g=d.top,y=d.bottom,m=d.right,_=a?4:3,b=Mt(_,Ht((h?i:this.controlBox&&e.groupable?n:At(n,[f,p])).map((function(t){return-t})),_),o,Ht(i,_));t.renderPoses=[Mo(b,s,[-v,-g],_),Mo(b,u,[m,-g],_),Mo(b,c,[-v,y],_),Mo(b,l,[m,y],_)]}else t.renderPoses=[s,u,c,l]},e.checkUpdate=function(){this._isPropTargetChanged=!1;var t=this.props,e=t.target,r=t.container,n=t.parentMoveable,i=this.state,o=i.target,a=i.container;if(o||e){this.updateAbles();var s=!xo(o,e);if(s||!xo(a,r)){var u=r||this.controlBox;u&&this.unsetAbles(),this.updateState({target:e,container:r}),!n&&u&&this.updateRect("End",!1,!1),this._isPropTargetChanged=s}}},e.waitToChangeTarget=function(){return new Promise((function(){}))},e.triggerEvent=function(t,e){this._emitter.trigger(t,e);var r=this.props[t];return r&&r(e)},e.useCSS=function(t,e){var r=this.props.customStyledMap,n=t+e;return r[n]||(r[n]=Ue(t,e)),r[n]},e.getState=function(){var t,e=this.props;(e.target||(null===(t=e.targets)||void 0===t?void 0:t.length))&&(this._hasFirstTarget=!0);var r=this.controlBox,n=e.persistData,i=e.firstRenderState;if(i&&!r)return i;if(!this._hasFirstTarget&&n){var o=es(n);if(o)return this.updateState(o,!1),this.state}return this.state.isPersisted=!1,this.state},e.updateSelectors=function(){},e.unsetAbles=function(){var t=this;this.targetAbles.forEach((function(e){e.unset&&e.unset(t)}))},e.updateAbles=function(t,e){void 0===t&&(t=this.props.ables),void 0===e&&(e="");var r=this.props.triggerAblesSimultaneously,n=this.getEnabledAbles(t),i="drag".concat(e,"Start"),o="pinch".concat(e,"Start"),a="drag".concat(e,"ControlStart"),s=wo(n,[i,o],r),u=wo(n,[a],r);this.enabledAbles=n,this.targetAbles=s,this.controlAbles=u},e.updateState=function(t,e){if(e){if(this.isUnmounted)return;this.setState(t)}else{var r=this.state;for(var n in t)r[n]=t[n]}},e.getEnabledAbles=function(t){void 0===t&&(t=this.props.ables);var e=this.props;return t.filter((function(t){return t&&(t.always&&!1!==e[t.name]||e[t.name])}))},e.renderAbles=function(){var t,e,r,n,i=this,o=this.props.triggerAblesSimultaneously,a={createElement:ke.createElement};return this.renderState={},(t=Oo(wo(this.getEnabledAbles(),["render"],o).map((function(t){return(0,t.render)(i,a)||[]}))).filter((function(t){return t})),e=function(t){return t.key},r=[],n={},t.forEach((function(i,o){var a=e(i,o,t),s=n[a];s||(s=[],n[a]=s,r.push(s)),s.push(i)})),r).map((function(t){return t[0]}))},e.updateCheckInput=function(){this.targetGesto&&(this.targetGesto.options.checkInput=this.props.checkInput)},e._getRequestStyles=function(){return this.getEnabledAbles().reduce((function(t,e){var r,n,i=null!==(n=null===(r=e.requestStyle)||void 0===r?void 0:r.call(e))&&void 0!==n?n:[];return __spreadArray(__spreadArray([],t,!0),i,!0)}),__spreadArray([],this.props.requestStyles||[],!0))},e._updateObserver=function(t){this._updateResizeObserver(t),this._updateMutationObserver(t)},e._updateEvents=function(){var t=this.controlBox,e=this.targetAbles.length,r=this.controlAbles.length,n=this._dragTarget;(!e&&this.targetGesto||this._isTargetChanged(!0))&&(ho(this,!1),this.updateState({gestos:{}})),r||ho(this,!0),n&&e&&!this.targetGesto&&(this.targetGesto=Va(this,n,"")),!this.controlGesto&&r&&(this.controlGesto=Ya(this,t,"controlAbles","Control"))},e._updateTargets=function(){var t=this.props;this._prevDragTarget=t.dragTarget||t.target,this._dragTarget=zo(this._prevDragTarget,!0),this._prevDragArea=t.dragArea},e._renderLines=function(){var t=this.props,e=t.zoom,r=t.hideDefaultLines,n=t.hideChildMoveableDefaultLines,i=t.parentMoveable;if(r||i&&n)return[];var o=this.getState().renderPoses,a={createElement:ke.createElement};return[[0,1],[1,3],[3,2],[2,0]].map((function(t,r){var n=t[0],i=t[1];return un(a,"",o[n],o[i],e,"render-line-".concat(r))}))},e._isTargetChanged=function(t){var e=this.props,r=e.dragTarget||e.target,n=this._prevDragTarget,i=this._prevDragArea,o=e.dragArea;return!o&&n!==r||(t||o)&&i!==o},e._updateNativeEvents=function(){var t=this,e=this.props.dragArea?this.areaElement:this.state.target,r=this.events,n=Q(r);if(this._isTargetChanged())for(var i in r){var o=r[i];o&&o.destroy(),r[i]=null}if(e){var a=this.enabledAbles;n.forEach((function(n){var i=wo(a,[n]),o=i.length>0,s=r[n];o?(s||(s=new $a(e,t,n),r[n]=s),s.setAbles(i)):s&&(s.destroy(),r[n]=null)}))}},e._checkUpdateRootContainer=function(){var t=this.props.rootContainer;!this._rootContainer&&t&&(this._rootContainer=zo(t,!0))},e._checkUpdateViewContainer=function(){var t=this.props.viewContainer;!this._viewContainer&&t&&(this._viewContainer=zo(t,!0)),this._viewContainer&&this._changeAbleViewClassNames(__spreadArray(__spreadArray([],this._getAbleViewClassNames(),!0),[this.isDragging()?ra:""],!1))},e._changeAbleViewClassNames=function(t){var e=this._viewContainer,r=Eo(t.filter(Boolean),(function(t){return t})).map((function(t){return t[0]})),n=this._viewClassNames,i=ee(n,r),o=i.removed,a=i.added;o.forEach((function(t){pt(e,n[t])})),a.forEach((function(t){ft(e,r[t])})),this._viewClassNames=r},e._getAbleViewClassNames=function(){var t=this;return(this.getEnabledAbles().map((function(e){var r;return(null===(r=e.viewClassName)||void 0===r?void 0:r.call(e,t))||""})).join(" ")+" ".concat(this._getAbleClassName("-view"))).split(/\s+/g)},e._getAbleClassName=function(t){var e=this;void 0===t&&(t="");var r=this.getEnabledAbles(),n=this.targetGesto,i=this.controlGesto,o=(null==n?void 0:n.isFlag())?n.getEventData():{},a=(null==i?void 0:i.isFlag())?i.getEventData():{};return r.map((function(r){var n,i,s,u=r.name,c=(null===(n=r.className)||void 0===n?void 0:n.call(r,e))||"";return((null===(i=o[u])||void 0===i?void 0:i.isEventStart)||(null===(s=a[u])||void 0===s?void 0:s.isEventStart))&&(c+=" ".concat(Ti("".concat(u).concat(t,"-dragging")))),c.trim()})).filter(Boolean).join(" ")},e._updateResizeObserver=function(t){var e,r=this.props,n=r.target,i=mt(this.getControlBoxElement());if(i.ResizeObserver&&n&&r.useResizeObserver){if(t.target!==n||!this._reiszeObserver){var o=new i.ResizeObserver(this.checkUpdateRect);o.observe(n,{box:"border-box"}),this._reiszeObserver=o}}else null===(e=this._reiszeObserver)||void 0===e||e.disconnect()},e._updateMutationObserver=function(t){var e,r=this,n=this.props,i=n.target,o=mt(this.getControlBoxElement());if(o.MutationObserver&&i&&n.useMutationObserver){if(t.target!==i||!this._mutationObserver){var a=new o.MutationObserver((function(t){for(var e=0,n=t;e-1,s=!1;-1===o&&(s=(o=X(i,(function(t){return t.contains(n)})))>-1),bo(t,"onClickGroup",yo(t,e,{isDouble:e.isDouble,targets:i,inputTarget:n,targetIndex:o,isTarget:a,containsTarget:s,moveableTarget:i[o]}))}},dragControlEnd:function(t,e){this.dragEnd(t,e)},dragGroupControlEnd:function(t,e){this.dragEnd(t,e)}});function os(t){var e=t.originalDatas.draggable;return e||(t.originalDatas.draggable={},e=t.originalDatas.draggable),We(We({},t),{datas:e})}var as=Ve("edgeDraggable",{css:[".edge.edgeDraggable.line {\ncursor: move;\n}"],render:function(t,e){var r=t.props,n=r.edgeDraggable;return n?cn(e,"edgeDraggable",n,t.getState().renderPoses,r.zoom):[]},dragCondition:function(t,e){var r,n=t.props,i=null===(r=e.inputEvent)||void 0===r?void 0:r.target;return!(!n.edgeDraggable||!i)&&(!n.draggable&<(i,Ti("direction"))&<(i,Ti("edge"))&<(i,Ti("edgeDraggable")))},dragStart:function(t,e){return Jn.dragStart(t,os(e))},drag:function(t,e){return Jn.drag(t,os(e))},dragEnd:function(t,e){return Jn.dragEnd(t,os(e))},dragGroupCondition:function(t,e){var r,n=t.props,i=null===(r=e.inputEvent)||void 0===r?void 0:r.target;return!(!n.edgeDraggable||!i)&&(!n.draggable&<(i,Ti("direction"))&<(i,Ti("line")))},dragGroupStart:function(t,e){return Jn.dragGroupStart(t,os(e))},dragGroup:function(t,e){return Jn.dragGroup(t,os(e))},dragGroupEnd:function(t,e){return Jn.dragGroupEnd(t,os(e))},unset:function(t){return Jn.unset(t)}}),ss={name:"individualGroupable",props:["individualGroupable","individualGroupableProps"],events:[]},us=[Ka,ca,Ri,Vo,Jn,as,ei,Xo,Zo,ui,ua,la,aa,za,Ta,La,ns,ss,is,oa,Na];function cs(t,e){var r=t[0],n=t[1],i=t[2];return(r*e[0]+n*e[1]+i)/Math.sqrt(r*r+n*n)}function ls(t,e){var r=t[0],n=t[1];return-r*e[0]-n*e[1]}function fs(t,e){return Math.max.apply(Math,t.map((function(t){var r=t[0],n=t[1],i=t[2],o=t[3];return Math.max(r[e],n[e],i[e],o[e])})))}function ps(t,e){return Math.min.apply(Math,t.map((function(t){var r=t[0],n=t[1],i=t[2],o=t[3];return Math.min(r[e],n[e],i[e],o[e])})))}function hs(t,e){var r=e.map((function(e){if(P(e)){var r=hs(t,e),n=r.length;return n>1?r:1===n?r[0]:null}var i=$(t,(function(t){return t.manager.props.target===e}));return i?(i.finded=!0,i.manager):null})).filter(Boolean);return 1===r.length&&P(r[0])?r[0]:r}var ds=function(t){function MoveableGroup(){var e=null!==t&&t.apply(this,arguments)||this;return e.differ=new ae,e.moveables=[],e.transformOrigin="50% 50%",e.renderGroupRects=[],e._targetGroups=[],e._hasFirstTargets=!1,e}He(MoveableGroup,t);var e=MoveableGroup.prototype;return e.componentDidMount=function(){t.prototype.componentDidMount.call(this)},e.checkUpdate=function(){this._isPropTargetChanged=!1,this.updateAbles()},e.getTargets=function(){return this.props.targets},e.updateRect=function(t,e,r){var n;void 0===r&&(r=!0);var i=this.state;if(this.controlBox&&!i.isPersisted){Qr(!0),this.moveables.forEach((function(e){e.updateRect(t,!1,!1)}));var o=this.props,a=this.moveables,s=i.target||o.target,u=a.map((function(t){return{finded:!1,manager:t}})),c=this.props.targetGroups||[],l=hs(u,c),f=o.useDefaultGroupRotate;l.push.apply(l,u.filter((function(t){return!t.finded})).map((function(t){return t.manager})));var p=[],h=!e||""!==t&&o.updateGroup,d=o.defaultGroupRotate||0;if(!this._hasFirstTargets){var v=null===(n=o.persistData)||void 0===n?void 0:n.rotation;null!=v&&(d=v)}var g=function t(e,r,n){var i=e.map((function(e){if(P(e)){var n=t(e,r),i=[n.pos1,n.pos2,n.pos3,n.pos4];return p.push(n),{poses:i,rotation:n.rotation}}return{poses:fo(e.state),rotation:e.getRotation()}})),o=i.map((function(t){return t.rotation})),a=0,s=o[0],u=o.every((function(t){return Math.abs(s-t)<.1}));a=h?!f&&u?s:d:f||n||!u?r:s;var c=i.map((function(t){return t.poses})),l=function(t,e){var r,n=[0,0],i=[0,0],o=[0,0],a=[0,0],s=0,u=0;if(!t.length)return{pos1:n,pos2:i,pos3:o,pos4:a,minX:0,minY:0,maxX:0,maxY:0,width:s,height:u,rotation:e};var c=ut(e,dr);if(c%90){var l=c/180*Math.PI,f=Math.tan(l),p=-1/f,h=[gr,yr],d=[[0,0],[0,0]],v=[gr,yr],g=[[0,0],[0,0]];t.forEach((function(t){t.forEach((function(t){var e=cs([-f,1,0],t),r=cs([-p,1,0],t);h[0]>e&&(d[0]=t,h[0]=e),h[1]r&&(g[0]=t,v[0]=r),v[1]180&&(n=(O=[a,o,i,n])[0],i=O[1],o=O[2],a=O[3]);var I=_e([n,i,o,a]);return{pos1:n,pos2:i,pos3:o,pos4:a,width:s,height:u,minX:I.minX,minY:I.minY,maxX:I.maxX,maxY:I.maxY,rotation:e}}(c,a);return l}(l,this.rotation,!0);h&&(this.rotation=g.rotation,this.transformOrigin=o.defaultGroupOrigin||"50% 50%",this.scale=[1,1]),this._targetGroups=c,this.renderGroupRects=p;var y,m,_,b,S,w=this.transformOrigin,x=this.rotation,E=this.scale,O=g.width,C=g.height,k=g.minX,D=g.minY,M=(y=[[0,0],[O,0],[0,C],[O,C]],m=Ko(w,O,C),_=this.rotation/180*Math.PI,b=y.map((function(t){return Rt(t,m)})),S=b.map((function(t){return Lt(t,_)})),{prev:b,next:S,result:S.map((function(t){return At(t,m)}))}),I=_e(M.result),A=I.minX,R=I.minY,T=" rotate(".concat(x,"deg)")+" scale(".concat(Uo(E[0]),", ").concat(Uo(E[1]),")"),z="translate(".concat(-A,"px, ").concat(-R,"px)").concat(T);this.controlBox.style.transform="translate3d(".concat(k,"px, ").concat(D,"px, ").concat(this.props.translateZ||0,")"),s.style.cssText+="left:0px;top:0px;"+"transform-origin:".concat(w,";")+"width:".concat(O,"px;height:").concat(C,"px;")+"transform: ".concat(z),i.width=O,i.height=C;var B=this.getContainer(),q=ts(this.controlBox,s,this.controlBox,this.getContainer(),this._rootContainer||B,[]),j=[q.left,q.top],L=fo(q),K=L[0],N=L[1],F=L[2],U=L[3],G=_e([K,N,F,U]),H=[G.minX,G.minY],W=Uo(E[0]*E[1]);q.pos1=Rt(K,H),q.pos2=Rt(N,H),q.pos3=Rt(F,H),q.pos4=Rt(U,H),q.left=k-q.left+H[0],q.top=D-q.top+H[1],q.origin=Rt(At(j,q.origin),H),q.beforeOrigin=Rt(At(j,q.beforeOrigin),H),q.originalBeforeOrigin=At(j,q.originalBeforeOrigin),q.transformOrigin=Rt(At(j,q.transformOrigin),H),s.style.transform="translate(".concat(-A-H[0],"px, ").concat(-R-H[1],"px)")+T,Qr(),this.updateState(We(We({},q),{posDelta:H,direction:W,beforeDirection:W}),r)}},e.getRect=function(){return We(We({},t.prototype.getRect.call(this)),{children:this.moveables.map((function(t){return t.getRect()}))})},e.triggerEvent=function(e,r,n){if(n||e.indexOf("Group")>-1)return t.prototype.triggerEvent.call(this,e,r);this._emitter.trigger(e,r)},e.getRequestChildStyles=function(){return this.getEnabledAbles().reduce((function(t,e){var r,n,i=null!==(n=null===(r=e.requestChildStyle)||void 0===r?void 0:r.call(e))&&void 0!==n?n:[];return __spreadArray(__spreadArray([],t,!0),i,!0)}),[])},e.updateAbles=function(){t.prototype.updateAbles.call(this,__spreadArray(__spreadArray([],this.props.ables,!0),[ns],!1),"Group")},e._updateTargets=function(){t.prototype._updateTargets.call(this),this._prevDragTarget=this.props.dragTarget||this.areaElement,this._dragTarget=zo(this._prevDragTarget,!0)},e._updateEvents=function(){var t=this.state,e=this.props,r=this._prevDragTarget,n=e.dragTarget||this.areaElement,i=e.targets,o=this.differ.update(i),a=o.added,s=o.changed,u=o.removed,c=a.length||u.length;(c||r!==n)&&(ho(this,!1),ho(this,!0),this.updateState({gestos:{}})),r!==n&&(t.target=null),t.target||(t.target=this.areaElement,this.controlBox.style.display="block"),t.target&&(this.targetGesto||(this.targetGesto=Va(this,this._dragTarget,"Group")),this.controlGesto||(this.controlGesto=Ya(this,this.controlBox,"controlAbles","GroupControl")));var l=!xo(t.container,e.container);l&&(t.container=e.container),(l||c||this.transformOrigin!==(e.defaultGroupOrigin||"50% 50%")||s.length||i.length&&!No(this._targetGroups,e.targetGroups||[]))&&(this.updateRect(),this._hasFirstTargets=!0),this._isPropTargetChanged=!!c},e._updateObserver=function(){},MoveableGroup.defaultProps=We(We({},rs.defaultProps),{transformOrigin:["50%","50%"],groupable:!0,dragArea:!0,keepRatio:!0,targets:[],defaultGroupRotate:0,defaultGroupOrigin:"50% 50%"}),MoveableGroup}(rs),vs=function(t){function MoveableIndividualGroup(){var e=null!==t&&t.apply(this,arguments)||this;return e.moveables=[],e}He(MoveableIndividualGroup,t);var e=MoveableIndividualGroup.prototype;return e.render=function(){var t,e=this,r=this.props,n=r.cspNonce,i=r.cssStyled,o=r.persistData,a=r.targets||[],s=a.length,u=this.isUnmounted||!s,c=null!==(t=null==o?void 0:o.children)&&void 0!==t?t:[];return u&&!s&&c.length?a=c.map((function(){return null})):u||(c=[]),ke.createElement(i,{cspNonce:n,ref:w(this,"controlBox"),className:Ti("control-box")},a.map((function(t,n){var i,o,a=null!==(o=null===(i=r.individualGroupableProps)||void 0===i?void 0:i.call(r,t,n))&&void 0!==o?o:{};return ke.createElement(rs,We({key:"moveable"+n,ref:x(e,"moveables",n)},r,a,{target:t,wrapperMoveable:e,isWrapperMounted:e.isMoveableMounted,persistData:c[n]}))})))},e.componentDidMount=function(){},e.componentDidUpdate=function(){},e.getTargets=function(){return this.props.targets},e.updateRect=function(t,e,r){void 0===r&&(r=!0),Qr(!0),this.moveables.forEach((function(n){n.updateRect(t,e,r)})),Qr()},e.getRect=function(){return We(We({},t.prototype.getRect.call(this)),{children:this.moveables.map((function(t){return t.getRect()}))})},e.request=function(){return{request:function(){return this},requestEnd:function(){return this}}},e.dragStart=function(){return this},e.hitTest=function(){return 0},e.isInside=function(){return!1},e.isDragging=function(){return!1},e.updateRenderPoses=function(){},e.checkUpdate=function(){},e.triggerEvent=function(){},e.updateAbles=function(){},e._updateEvents=function(){},e._updateObserver=function(){},MoveableIndividualGroup}(rs);function gs(t,e){var r=[];return t.forEach((function(t){t&&(j(t)?e[t]&&r.push.apply(r,e[t]):P(t)?r.push.apply(r,gs(t,e)):r.push(t))})),r}function ys(t,e){var r=[];return t.forEach((function(t){t&&(j(t)?e[t]&&r.push.apply(r,e[t]):P(t)?r.push(ys(t,e)):r.push(t))})),r}function ms(t,e){return t.length!==e.length||t.some((function(t,r){var n=e[r];return!(!t&&!n)&&(t!=n&&(!P(t)||!P(n)||ms(t,n)))}))}var _s=function(t){function InitialMoveable(){var e=null!==t&&t.apply(this,arguments)||this;return e.refTargets=[],e.selectorMap={},e._differ=new ae,e._elementTargets=[],e._onChangeTargets=null,e}He(InitialMoveable,t);var e,r,n=InitialMoveable.prototype;return InitialMoveable.makeStyled=function(){var t={};this.getTotalAbles().forEach((function(e){var r=e.css;r&&r.forEach((function(e){t[e]=!0}))}));var e=Q(t).join("\n");this.defaultStyled=Ue("div",function(t,e){return e.replace(/([^}{]*){/gm,(function(e,r){return r.replace(/\.([^{,\s\d.]+)/g,"."+t+"$1")+"{"}))}(cr,fr+e))},InitialMoveable.getTotalAbles=function(){return __spreadArray([ca,ns,ss,oa],this.defaultAbles,!0)},n.render=function(){var t,e=this.constructor;e.defaultStyled||e.makeStyled();var r=this.props,n=r.ables,i=r.props,o=function(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(t);i1,c=__spreadArray(__spreadArray([],e.getTotalAbles(),!0),n||[],!0),l=We(We(We({},o),i||{}),{ables:c,cssStyled:e.defaultStyled,customStyledMap:e.customStyledMap});this._elementTargets=s;var f=null,p=this.moveable,h=o.persistData;if((null==h?void 0:h.children)&&(u=!0),o.individualGroupable)return ke.createElement(vs,We({key:"individual-group",ref:w(this,"moveable")},l,{target:null,targets:s}));if(u){var d=ys(a,this.selectorMap);if(p&&!p.props.groupable&&!p.props.individualGroupable){var v=p.props.target;v&&s.indexOf(v)>-1&&(f=We({},p.state))}return ke.createElement(ds,We({key:"group",ref:w(this,"moveable")},l,null!==(t=o.groupableProps)&&void 0!==t?t:{},{target:null,targets:s,targetGroups:d,firstRenderState:f}))}var g=s[0];if(p&&(p.props.groupable||p.props.individualGroupable)){var y=$(p.moveables||[],(function(t){return t.props.target===g}));y&&(f=We({},y.state))}return ke.createElement(rs,We({key:"single",ref:w(this,"moveable")},l,{target:g,firstRenderState:f}))},n.componentDidMount=function(){this._checkChangeTargets(),this._updateRefs()},n.componentDidUpdate=function(){this._checkChangeTargets()},n.componentWillUnmount=function(){this.selectorMap={},this.refTargets=[]},n.getTargets=function(){var t,e;return null!==(e=null===(t=this.moveable)||void 0===t?void 0:t.getTargets())&&void 0!==e?e:[]},n.updateSelectors=function(){this.selectorMap={},this._updateRefs()},n.waitToChangeTarget=function(){var t,e=this;return this._onChangeTargets=function(){e._onChangeTargets=null,t()},new Promise((function(e){t=e}))},n.waitToChangeTargets=function(){return this.waitToChangeTarget()},n.getManager=function(){return this.moveable},n._updateRefs=function(t){var e=this.refTargets,r=Bo(this.props.target||this.props.targets),n="undefined"!=typeof document,i=ms(e,r),o=this.selectorMap,a={};return this.refTargets.forEach((function t(e){j(e)?o[e]?a[e]=o[e]:n&&(i=!0,a[e]=[].slice.call(document.querySelectorAll(e))):P(e)&&e.forEach(t)})),this.refTargets=r,this.selectorMap=a,!t&&i&&this.forceUpdate(),r},n._checkChangeTargets=function(){var t,e,r,n=this._differ.update(this._elementTargets),i=n.added,o=n.removed;(i.length||o.length)&&(null===(e=(t=this.props).onChangeTargets)||void 0===e||e.call(t,{moveable:this.moveable,targets:this._elementTargets}),null===(r=this._onChangeTargets)||void 0===r||r.call(this)),this._updateRefs()},InitialMoveable.defaultAbles=[],InitialMoveable.customStyledMap={},InitialMoveable.defaultStyled=null,function __decorate(t,e,r,n){var i,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,r,n);else for(var s=t.length-1;s>=0;s--)(i=t[s])&&(a=(o<3?i(a):o>3?i(e,r,a):i(e,r))||a);return o>3&&a&&Object.defineProperty(e,r,a),a}([(e=Sr,void 0===r&&(r={}),function(t,n){e.forEach((function(e){var i=r[e]||e;i in t||(t[i]=function(){for(var t,r=[],i=0;i{"use strict";t.exports=r(72408)},76826:t=>{var e={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",Ấ:"A",Ắ:"A",Ẳ:"A",Ẵ:"A",Ặ:"A",Æ:"AE",Ầ:"A",Ằ:"A",Ȃ:"A",Ả:"A",Ạ:"A",Ẩ:"A",Ẫ:"A",Ậ:"A",Ç:"C",Ḉ:"C",È:"E",É:"E",Ê:"E",Ë:"E",Ế:"E",Ḗ:"E",Ề:"E",Ḕ:"E",Ḝ:"E",Ȇ:"E",Ẻ:"E",Ẽ:"E",Ẹ:"E",Ể:"E",Ễ:"E",Ệ:"E",Ì:"I",Í:"I",Î:"I",Ï:"I",Ḯ:"I",Ȋ:"I",Ỉ:"I",Ị:"I",Ð:"D",Ñ:"N",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",Ố:"O",Ṍ:"O",Ṓ:"O",Ȏ:"O",Ỏ:"O",Ọ:"O",Ổ:"O",Ỗ:"O",Ộ:"O",Ờ:"O",Ở:"O",Ỡ:"O",Ớ:"O",Ợ:"O",Ù:"U",Ú:"U",Û:"U",Ü:"U",Ủ:"U",Ụ:"U",Ử:"U",Ữ:"U",Ự:"U",Ý:"Y",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",ấ:"a",ắ:"a",ẳ:"a",ẵ:"a",ặ:"a",æ:"ae",ầ:"a",ằ:"a",ȃ:"a",ả:"a",ạ:"a",ẩ:"a",ẫ:"a",ậ:"a",ç:"c",ḉ:"c",è:"e",é:"e",ê:"e",ë:"e",ế:"e",ḗ:"e",ề:"e",ḕ:"e",ḝ:"e",ȇ:"e",ẻ:"e",ẽ:"e",ẹ:"e",ể:"e",ễ:"e",ệ:"e",ì:"i",í:"i",î:"i",ï:"i",ḯ:"i",ȋ:"i",ỉ:"i",ị:"i",ð:"d",ñ:"n",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",ố:"o",ṍ:"o",ṓ:"o",ȏ:"o",ỏ:"o",ọ:"o",ổ:"o",ỗ:"o",ộ:"o",ờ:"o",ở:"o",ỡ:"o",ớ:"o",ợ:"o",ù:"u",ú:"u",û:"u",ü:"u",ủ:"u",ụ:"u",ử:"u",ữ:"u",ự:"u",ý:"y",ÿ:"y",Ā:"A",ā:"a",Ă:"A",ă:"a",Ą:"A",ą:"a",Ć:"C",ć:"c",Ĉ:"C",ĉ:"c",Ċ:"C",ċ:"c",Č:"C",č:"c",C̆:"C",c̆:"c",Ď:"D",ď:"d",Đ:"D",đ:"d",Ē:"E",ē:"e",Ĕ:"E",ĕ:"e",Ė:"E",ė:"e",Ę:"E",ę:"e",Ě:"E",ě:"e",Ĝ:"G",Ǵ:"G",ĝ:"g",ǵ:"g",Ğ:"G",ğ:"g",Ġ:"G",ġ:"g",Ģ:"G",ģ:"g",Ĥ:"H",ĥ:"h",Ħ:"H",ħ:"h",Ḫ:"H",ḫ:"h",Ĩ:"I",ĩ:"i",Ī:"I",ī:"i",Ĭ:"I",ĭ:"i",Į:"I",į:"i",İ:"I",ı:"i",IJ:"IJ",ij:"ij",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",Ḱ:"K",ḱ:"k",K̆:"K",k̆:"k",Ĺ:"L",ĺ:"l",Ļ:"L",ļ:"l",Ľ:"L",ľ:"l",Ŀ:"L",ŀ:"l",Ł:"l",ł:"l",Ḿ:"M",ḿ:"m",M̆:"M",m̆:"m",Ń:"N",ń:"n",Ņ:"N",ņ:"n",Ň:"N",ň:"n",ʼn:"n",N̆:"N",n̆:"n",Ō:"O",ō:"o",Ŏ:"O",ŏ:"o",Ő:"O",ő:"o",Œ:"OE",œ:"oe",P̆:"P",p̆:"p",Ŕ:"R",ŕ:"r",Ŗ:"R",ŗ:"r",Ř:"R",ř:"r",R̆:"R",r̆:"r",Ȓ:"R",ȓ:"r",Ś:"S",ś:"s",Ŝ:"S",ŝ:"s",Ş:"S",Ș:"S",ș:"s",ş:"s",Š:"S",š:"s",Ţ:"T",ţ:"t",ț:"t",Ț:"T",Ť:"T",ť:"t",Ŧ:"T",ŧ:"t",T̆:"T",t̆:"t",Ũ:"U",ũ:"u",Ū:"U",ū:"u",Ŭ:"U",ŭ:"u",Ů:"U",ů:"u",Ű:"U",ű:"u",Ų:"U",ų:"u",Ȗ:"U",ȗ:"u",V̆:"V",v̆:"v",Ŵ:"W",ŵ:"w",Ẃ:"W",ẃ:"w",X̆:"X",x̆:"x",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Y̆:"Y",y̆:"y",Ź:"Z",ź:"z",Ż:"Z",ż:"z",Ž:"Z",ž:"z",ſ:"s",ƒ:"f",Ơ:"O",ơ:"o",Ư:"U",ư:"u",Ǎ:"A",ǎ:"a",Ǐ:"I",ǐ:"i",Ǒ:"O",ǒ:"o",Ǔ:"U",ǔ:"u",Ǖ:"U",ǖ:"u",Ǘ:"U",ǘ:"u",Ǚ:"U",ǚ:"u",Ǜ:"U",ǜ:"u",Ứ:"U",ứ:"u",Ṹ:"U",ṹ:"u",Ǻ:"A",ǻ:"a",Ǽ:"AE",ǽ:"ae",Ǿ:"O",ǿ:"o",Þ:"TH",þ:"th",Ṕ:"P",ṕ:"p",Ṥ:"S",ṥ:"s",X́:"X",x́:"x",Ѓ:"Г",ѓ:"г",Ќ:"К",ќ:"к",A̋:"A",a̋:"a",E̋:"E",e̋:"e",I̋:"I",i̋:"i",Ǹ:"N",ǹ:"n",Ồ:"O",ồ:"o",Ṑ:"O",ṑ:"o",Ừ:"U",ừ:"u",Ẁ:"W",ẁ:"w",Ỳ:"Y",ỳ:"y",Ȁ:"A",ȁ:"a",Ȅ:"E",ȅ:"e",Ȉ:"I",ȉ:"i",Ȍ:"O",ȍ:"o",Ȑ:"R",ȑ:"r",Ȕ:"U",ȕ:"u",B̌:"B",b̌:"b",Č̣:"C",č̣:"c",Ê̌:"E",ê̌:"e",F̌:"F",f̌:"f",Ǧ:"G",ǧ:"g",Ȟ:"H",ȟ:"h",J̌:"J",ǰ:"j",Ǩ:"K",ǩ:"k",M̌:"M",m̌:"m",P̌:"P",p̌:"p",Q̌:"Q",q̌:"q",Ř̩:"R",ř̩:"r",Ṧ:"S",ṧ:"s",V̌:"V",v̌:"v",W̌:"W",w̌:"w",X̌:"X",x̌:"x",Y̌:"Y",y̌:"y",A̧:"A",a̧:"a",B̧:"B",b̧:"b",Ḑ:"D",ḑ:"d",Ȩ:"E",ȩ:"e",Ɛ̧:"E",ɛ̧:"e",Ḩ:"H",ḩ:"h",I̧:"I",i̧:"i",Ɨ̧:"I",ɨ̧:"i",M̧:"M",m̧:"m",O̧:"O",o̧:"o",Q̧:"Q",q̧:"q",U̧:"U",u̧:"u",X̧:"X",x̧:"x",Z̧:"Z",z̧:"z",й:"и",Й:"И",ё:"е",Ё:"Е"},r=Object.keys(e).join("|"),n=new RegExp(r,"g"),i=new RegExp(r,"");function o(t){return e[t]}var a=function(t){return t.replace(n,o)};t.exports=a,t.exports.has=function(t){return!!t.match(i)},t.exports.remove=a},63594:function(t,e,r){var n,i;!function(o,a){"use strict";void 0===(i="function"==typeof(n=function(){var t={};function Vector(t,e){this.x=t||0,this.y=e||0}function Circle(t,e){this.pos=t||new Vector,this.r=e||0,this.offset=new Vector}function Polygon(t,e){this.pos=t||new Vector,this.angle=0,this.offset=new Vector,this.setPoints(e||[])}function Box(t,e,r){this.pos=t||new Vector,this.w=e||0,this.h=r||0}function Response(){this.a=null,this.b=null,this.overlapN=new Vector,this.overlapV=new Vector,this.clear()}t.Vector=Vector,t.V=Vector,Vector.prototype.copy=Vector.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},Vector.prototype.clone=Vector.prototype.clone=function(){return new Vector(this.x,this.y)},Vector.prototype.perp=Vector.prototype.perp=function(){var t=this.x;return this.x=this.y,this.y=-t,this},Vector.prototype.rotate=Vector.prototype.rotate=function(t){var e=this.x,r=this.y;return this.x=e*Math.cos(t)-r*Math.sin(t),this.y=e*Math.sin(t)+r*Math.cos(t),this},Vector.prototype.reverse=Vector.prototype.reverse=function(){return this.x=-this.x,this.y=-this.y,this},Vector.prototype.normalize=Vector.prototype.normalize=function(){var t=this.len();return t>0&&(this.x=this.x/t,this.y=this.y/t),this},Vector.prototype.add=Vector.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},Vector.prototype.sub=Vector.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},Vector.prototype.scale=Vector.prototype.scale=function(t,e){return this.x*=t,this.y*=void 0!==e?e:t,this},Vector.prototype.project=Vector.prototype.project=function(t){var e=this.dot(t)/t.len2();return this.x=e*t.x,this.y=e*t.y,this},Vector.prototype.projectN=Vector.prototype.projectN=function(t){var e=this.dot(t);return this.x=e*t.x,this.y=e*t.y,this},Vector.prototype.reflect=Vector.prototype.reflect=function(t){var e=this.x,r=this.y;return this.project(t).scale(2),this.x-=e,this.y-=r,this},Vector.prototype.reflectN=Vector.prototype.reflectN=function(t){var e=this.x,r=this.y;return this.projectN(t).scale(2),this.x-=e,this.y-=r,this},Vector.prototype.dot=Vector.prototype.dot=function(t){return this.x*t.x+this.y*t.y},Vector.prototype.len2=Vector.prototype.len2=function(){return this.dot(this)},Vector.prototype.len=Vector.prototype.len=function(){return Math.sqrt(this.len2())},t.Circle=Circle,Circle.prototype.getAABBAsBox=Circle.prototype.getAABBAsBox=function(){var t=this.r;return new Box(this.pos.clone().add(this.offset).sub(new Vector(t,t)),2*t,2*t)},Circle.prototype.getAABB=Circle.prototype.getAABB=function(){return this.getAABBAsBox().toPolygon()},Circle.prototype.setOffset=Circle.prototype.setOffset=function(t){return this.offset=t,this},t.Polygon=Polygon,Polygon.prototype.setPoints=Polygon.prototype.setPoints=function(t){if(!this.points||this.points.length!==t.length){var e,r=this.calcPoints=[],n=this.edges=[],i=this.normals=[];for(e=0;ei&&(i=s.x),s.yo&&(o=s.y)}return new Box(this.pos.clone().add(new Vector(r,n)),i-r,o-n)},Polygon.prototype.getAABB=Polygon.prototype.getAABB=function(){return this.getAABBAsBox().toPolygon()},Polygon.prototype.getCentroid=Polygon.prototype.getCentroid=function(){for(var t=this.calcPoints,e=t.length,r=0,n=0,i=0,o=0;oi&&(i=s)}r[0]=n,r[1]=i}function s(t,r,i,o,s,u){var c=n.pop(),l=n.pop(),f=e.pop().copy(r).sub(t),p=f.dot(s);if(a(i,s,c),a(o,s,l),l[0]+=p,l[1]+=p,c[0]>l[1]||l[0]>c[1])return e.push(f),n.push(c),n.push(l),!0;if(u){var h,d,v=0;if(c[0]l[1])v=c[0]-l[1],u.aInB=!1;else v=(h=c[1]-l[0])<(d=l[1]-c[0])?h:-d;var g=Math.abs(v);gr?f:l}t.isSeparatingAxis=s;var c=-1,l=0,f=1;function p(t,r){var n=e.pop().copy(t).sub(r.pos).sub(r.offset),i=r.r*r.r,o=n.len2();return e.push(n),o<=i}function h(t,e){o.pos.copy(t),i.clear();var r=y(o,e,i);return r&&(r=i.aInB),r}function d(t,r,n){var i=e.pop().copy(r.pos).add(r.offset).sub(t.pos).sub(t.offset),o=t.r+r.r,a=o*o,s=i.len2();if(s>a)return e.push(i),!1;if(n){var u=Math.sqrt(s);n.a=t,n.b=r,n.overlap=o-u,n.overlapN.copy(i.normalize()),n.overlapV.copy(i).scale(n.overlap),n.aInB=t.r<=r.r&&u<=r.r-t.r,n.bInA=r.r<=t.r&&u<=t.r-r.r}return e.push(i),!0}function v(t,r,n){for(var i=e.pop().copy(r.pos).add(r.offset).sub(t.pos),o=r.r,a=o*o,s=t.calcPoints,l=s.length,p=e.pop(),h=e.pop(),d=0;da&&(n.aInB=!1);var _=u(p,h);if(_===c){p.copy(t.edges[g]);var b=e.pop().copy(i).sub(s[g]);if((_=u(p,b))===f){if((w=h.len())>o)return e.push(i),e.push(p),e.push(h),e.push(b),!1;n&&(n.bInA=!1,m=h.normalize(),y=o-w)}e.push(b)}else if(_===f){if(p.copy(t.edges[v]),h.copy(i).sub(s[v]),(_=u(p,h))===c){if((w=h.len())>o)return e.push(i),e.push(p),e.push(h),!1;n&&(n.bInA=!1,m=h.normalize(),y=o-w)}}else{var S=p.perp().normalize(),w=h.dot(S),x=Math.abs(w);if(w>0&&x>o)return e.push(i),e.push(S),e.push(h),!1;n&&(m=S,y=o-w,(w>=0||y<2*o)&&(n.bInA=!1))}m&&n&&Math.abs(y)0?2===s.length?typeof s[1]==a?this[s[0]]=s[1].call(this,l):this[s[0]]=s[1]:3===s.length?typeof s[1]!==a||s[1].exec&&s[1].test?this[s[0]]=l?l.replace(s[1],s[2]):o:this[s[0]]=l?s[1].call(this,l,s[2]):o:4===s.length&&(this[s[0]]=l?s[3].call(this,l.replace(s[1],s[2])):o):this[s]=l||o;f+=2}},H=function(t,e){for(var r in e)if(typeof e[r]===u&&e[r].length>0){for(var n=0;n255?U(t,255):t,this},this.setUA(r),this};UAParser.VERSION="0.7.31",UAParser.BROWSER=K([f,d,"major"]),UAParser.CPU=K([v]),UAParser.DEVICE=K([l,h,p,g,y,_,m,b,S]),UAParser.ENGINE=UAParser.OS=K([f,d]),typeof e!==s?(t.exports&&(e=t.exports=UAParser),e.UAParser=UAParser):r.amdO?(n=function(){return UAParser}.call(e,r,e,t))===o||(t.exports=n):typeof i!==s&&(i.UAParser=UAParser);var Y=typeof i!==s&&(i.jQuery||i.Zepto);if(Y&&!Y.ua){var X=new UAParser;Y.ua=X.getResult(),Y.ua.get=function(){return X.getUA()},Y.ua.set=function(t){X.setUA(t);var e=X.getResult();for(var r in e)Y.ua[r]=e[r]}}}("object"==typeof window?window:this)},49349:(t,e,r)=>{"use strict";r.d(e,{default:()=>i});var n=r(67294);function i(t,e,r=!1){const[i,o]=(0,n.useReducer)(function(t){return(e,r)=>r&&r.type&&t[r.type]?t[r.type](e,r):e}(e),t),a=(0,n.useMemo)((()=>function(t,e,r){const n=Object.keys(t);return n.reduce(((t,n)=>(t[n]||(t[n]=t=>{const i={type:n,payload:t};e(i),r&&console.log(i)}),t)),{})}(e,o,r)),[e]);return[i,a]}},20477:t=>{"use strict";t.exports=function(t,e,r,n){var i=self||window;try{try{var o;try{o=new i.Blob([t])}catch(e){(o=new(i.BlobBuilder||i.WebKitBlobBuilder||i.MozBlobBuilder||i.MSBlobBuilder)).append(t),o=o.getBlob()}var a=i.URL||i.webkitURL,s=a.createObjectURL(o),u=new i[e](s,r);return a.revokeObjectURL(s),u}catch(n){return new i[e]("data:application/javascript,".concat(encodeURIComponent(t)),r)}}catch(t){if(!n)throw Error("Inline worker is not supported");return new i[e](n,r)}}},68672:(t,e,r)=>{"use strict";r.d(e,{default:()=>c});const n={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let i;const o=new Uint8Array(16);function a(){if(!i&&(i="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!i))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return i(o)}const s=[];for(let t=0;t<256;++t)s.push((t+256).toString(16).slice(1));function u(t,e=0){return s[t[e+0]]+s[t[e+1]]+s[t[e+2]]+s[t[e+3]]+"-"+s[t[e+4]]+s[t[e+5]]+"-"+s[t[e+6]]+s[t[e+7]]+"-"+s[t[e+8]]+s[t[e+9]]+"-"+s[t[e+10]]+s[t[e+11]]+s[t[e+12]]+s[t[e+13]]+s[t[e+14]]+s[t[e+15]]}const c=function(t,e,r){if(n.randomUUID&&!e&&!t)return n.randomUUID();const i=(t=t||{}).random||(t.rng||a)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,e){r=r||0;for(let t=0;t<16;++t)e[r+t]=i[t];return e}return u(i)}},34199:(t,e,r)=>{"use strict";r.d(e,{default:()=>c});const n={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let i;const o=new Uint8Array(16);function a(){if(!i&&(i="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!i))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return i(o)}const s=[];for(let t=0;t<256;++t)s.push((t+256).toString(16).slice(1));function u(t,e=0){return s[t[e+0]]+s[t[e+1]]+s[t[e+2]]+s[t[e+3]]+"-"+s[t[e+4]]+s[t[e+5]]+"-"+s[t[e+6]]+s[t[e+7]]+"-"+s[t[e+8]]+s[t[e+9]]+"-"+s[t[e+10]]+s[t[e+11]]+s[t[e+12]]+s[t[e+13]]+s[t[e+14]]+s[t[e+15]]}const c=function(t,e,r){if(n.randomUUID&&!e&&!t)return n.randomUUID();const i=(t=t||{}).random||(t.rng||a)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,e){r=r||0;for(let t=0;t<16;++t)e[r+t]=i[t];return e}return u(i)}},1114:(t,e,r)=>{"use strict";r.d(e,{default:()=>c});const n={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let i;const o=new Uint8Array(16);function a(){if(!i&&(i="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!i))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return i(o)}const s=[];for(let t=0;t<256;++t)s.push((t+256).toString(16).slice(1));function u(t,e=0){return s[t[e+0]]+s[t[e+1]]+s[t[e+2]]+s[t[e+3]]+"-"+s[t[e+4]]+s[t[e+5]]+"-"+s[t[e+6]]+s[t[e+7]]+"-"+s[t[e+8]]+s[t[e+9]]+"-"+s[t[e+10]]+s[t[e+11]]+s[t[e+12]]+s[t[e+13]]+s[t[e+14]]+s[t[e+15]]}const c=function(t,e,r){if(n.randomUUID&&!e&&!t)return n.randomUUID();const i=(t=t||{}).random||(t.rng||a)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,e){r=r||0;for(let t=0;t<16;++t)e[r+t]=i[t];return e}return u(i)}},17137:t=>{"use strict";function Mime(){this._types=Object.create(null),this._extensions=Object.create(null);for(let t=0;t{"use strict";let n=r(17137);t.exports=new n(r(94776))},94776:t=>{t.exports={"application/andrew-inset":["ez"],"application/applixware":["aw"],"application/atom+xml":["atom"],"application/atomcat+xml":["atomcat"],"application/atomdeleted+xml":["atomdeleted"],"application/atomsvc+xml":["atomsvc"],"application/atsc-dwd+xml":["dwd"],"application/atsc-held+xml":["held"],"application/atsc-rsat+xml":["rsat"],"application/bdoc":["bdoc"],"application/calendar+xml":["xcs"],"application/ccxml+xml":["ccxml"],"application/cdfx+xml":["cdfx"],"application/cdmi-capability":["cdmia"],"application/cdmi-container":["cdmic"],"application/cdmi-domain":["cdmid"],"application/cdmi-object":["cdmio"],"application/cdmi-queue":["cdmiq"],"application/cu-seeme":["cu"],"application/dash+xml":["mpd"],"application/davmount+xml":["davmount"],"application/docbook+xml":["dbk"],"application/dssc+der":["dssc"],"application/dssc+xml":["xdssc"],"application/ecmascript":["es","ecma"],"application/emma+xml":["emma"],"application/emotionml+xml":["emotionml"],"application/epub+zip":["epub"],"application/exi":["exi"],"application/express":["exp"],"application/fdt+xml":["fdt"],"application/font-tdpfr":["pfr"],"application/geo+json":["geojson"],"application/gml+xml":["gml"],"application/gpx+xml":["gpx"],"application/gxf":["gxf"],"application/gzip":["gz"],"application/hjson":["hjson"],"application/hyperstudio":["stk"],"application/inkml+xml":["ink","inkml"],"application/ipfix":["ipfix"],"application/its+xml":["its"],"application/java-archive":["jar","war","ear"],"application/java-serialized-object":["ser"],"application/java-vm":["class"],"application/javascript":["js","mjs"],"application/json":["json","map"],"application/json5":["json5"],"application/jsonml+json":["jsonml"],"application/ld+json":["jsonld"],"application/lgr+xml":["lgr"],"application/lost+xml":["lostxml"],"application/mac-binhex40":["hqx"],"application/mac-compactpro":["cpt"],"application/mads+xml":["mads"],"application/manifest+json":["webmanifest"],"application/marc":["mrc"],"application/marcxml+xml":["mrcx"],"application/mathematica":["ma","nb","mb"],"application/mathml+xml":["mathml"],"application/mbox":["mbox"],"application/mediaservercontrol+xml":["mscml"],"application/metalink+xml":["metalink"],"application/metalink4+xml":["meta4"],"application/mets+xml":["mets"],"application/mmt-aei+xml":["maei"],"application/mmt-usd+xml":["musd"],"application/mods+xml":["mods"],"application/mp21":["m21","mp21"],"application/mp4":["mp4s","m4p"],"application/msword":["doc","dot"],"application/mxf":["mxf"],"application/n-quads":["nq"],"application/n-triples":["nt"],"application/node":["cjs"],"application/octet-stream":["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"],"application/oda":["oda"],"application/oebps-package+xml":["opf"],"application/ogg":["ogx"],"application/omdoc+xml":["omdoc"],"application/onenote":["onetoc","onetoc2","onetmp","onepkg"],"application/oxps":["oxps"],"application/p2p-overlay+xml":["relo"],"application/patch-ops-error+xml":["xer"],"application/pdf":["pdf"],"application/pgp-encrypted":["pgp"],"application/pgp-signature":["asc","sig"],"application/pics-rules":["prf"],"application/pkcs10":["p10"],"application/pkcs7-mime":["p7m","p7c"],"application/pkcs7-signature":["p7s"],"application/pkcs8":["p8"],"application/pkix-attr-cert":["ac"],"application/pkix-cert":["cer"],"application/pkix-crl":["crl"],"application/pkix-pkipath":["pkipath"],"application/pkixcmp":["pki"],"application/pls+xml":["pls"],"application/postscript":["ai","eps","ps"],"application/provenance+xml":["provx"],"application/pskc+xml":["pskcxml"],"application/raml+yaml":["raml"],"application/rdf+xml":["rdf","owl"],"application/reginfo+xml":["rif"],"application/relax-ng-compact-syntax":["rnc"],"application/resource-lists+xml":["rl"],"application/resource-lists-diff+xml":["rld"],"application/rls-services+xml":["rs"],"application/route-apd+xml":["rapd"],"application/route-s-tsid+xml":["sls"],"application/route-usd+xml":["rusd"],"application/rpki-ghostbusters":["gbr"],"application/rpki-manifest":["mft"],"application/rpki-roa":["roa"],"application/rsd+xml":["rsd"],"application/rss+xml":["rss"],"application/rtf":["rtf"],"application/sbml+xml":["sbml"],"application/scvp-cv-request":["scq"],"application/scvp-cv-response":["scs"],"application/scvp-vp-request":["spq"],"application/scvp-vp-response":["spp"],"application/sdp":["sdp"],"application/senml+xml":["senmlx"],"application/sensml+xml":["sensmlx"],"application/set-payment-initiation":["setpay"],"application/set-registration-initiation":["setreg"],"application/shf+xml":["shf"],"application/sieve":["siv","sieve"],"application/smil+xml":["smi","smil"],"application/sparql-query":["rq"],"application/sparql-results+xml":["srx"],"application/srgs":["gram"],"application/srgs+xml":["grxml"],"application/sru+xml":["sru"],"application/ssdl+xml":["ssdl"],"application/ssml+xml":["ssml"],"application/swid+xml":["swidtag"],"application/tei+xml":["tei","teicorpus"],"application/thraud+xml":["tfi"],"application/timestamped-data":["tsd"],"application/toml":["toml"],"application/trig":["trig"],"application/ttml+xml":["ttml"],"application/ubjson":["ubj"],"application/urc-ressheet+xml":["rsheet"],"application/urc-targetdesc+xml":["td"],"application/voicexml+xml":["vxml"],"application/wasm":["wasm"],"application/widget":["wgt"],"application/winhlp":["hlp"],"application/wsdl+xml":["wsdl"],"application/wspolicy+xml":["wspolicy"],"application/xaml+xml":["xaml"],"application/xcap-att+xml":["xav"],"application/xcap-caps+xml":["xca"],"application/xcap-diff+xml":["xdf"],"application/xcap-el+xml":["xel"],"application/xcap-ns+xml":["xns"],"application/xenc+xml":["xenc"],"application/xhtml+xml":["xhtml","xht"],"application/xliff+xml":["xlf"],"application/xml":["xml","xsl","xsd","rng"],"application/xml-dtd":["dtd"],"application/xop+xml":["xop"],"application/xproc+xml":["xpl"],"application/xslt+xml":["*xsl","xslt"],"application/xspf+xml":["xspf"],"application/xv+xml":["mxml","xhvml","xvml","xvm"],"application/yang":["yang"],"application/yin+xml":["yin"],"application/zip":["zip"],"audio/3gpp":["*3gpp"],"audio/adpcm":["adp"],"audio/amr":["amr"],"audio/basic":["au","snd"],"audio/midi":["mid","midi","kar","rmi"],"audio/mobile-xmf":["mxmf"],"audio/mp3":["*mp3"],"audio/mp4":["m4a","mp4a"],"audio/mpeg":["mpga","mp2","mp2a","mp3","m2a","m3a"],"audio/ogg":["oga","ogg","spx","opus"],"audio/s3m":["s3m"],"audio/silk":["sil"],"audio/wav":["wav"],"audio/wave":["*wav"],"audio/webm":["weba"],"audio/xm":["xm"],"font/collection":["ttc"],"font/otf":["otf"],"font/ttf":["ttf"],"font/woff":["woff"],"font/woff2":["woff2"],"image/aces":["exr"],"image/apng":["apng"],"image/avif":["avif"],"image/bmp":["bmp"],"image/cgm":["cgm"],"image/dicom-rle":["drle"],"image/emf":["emf"],"image/fits":["fits"],"image/g3fax":["g3"],"image/gif":["gif"],"image/heic":["heic"],"image/heic-sequence":["heics"],"image/heif":["heif"],"image/heif-sequence":["heifs"],"image/hej2k":["hej2"],"image/hsj2":["hsj2"],"image/ief":["ief"],"image/jls":["jls"],"image/jp2":["jp2","jpg2"],"image/jpeg":["jpeg","jpg","jpe"],"image/jph":["jph"],"image/jphc":["jhc"],"image/jpm":["jpm"],"image/jpx":["jpx","jpf"],"image/jxr":["jxr"],"image/jxra":["jxra"],"image/jxrs":["jxrs"],"image/jxs":["jxs"],"image/jxsc":["jxsc"],"image/jxsi":["jxsi"],"image/jxss":["jxss"],"image/ktx":["ktx"],"image/ktx2":["ktx2"],"image/png":["png"],"image/sgi":["sgi"],"image/svg+xml":["svg","svgz"],"image/t38":["t38"],"image/tiff":["tif","tiff"],"image/tiff-fx":["tfx"],"image/webp":["webp"],"image/wmf":["wmf"],"message/disposition-notification":["disposition-notification"],"message/global":["u8msg"],"message/global-delivery-status":["u8dsn"],"message/global-disposition-notification":["u8mdn"],"message/global-headers":["u8hdr"],"message/rfc822":["eml","mime"],"model/3mf":["3mf"],"model/gltf+json":["gltf"],"model/gltf-binary":["glb"],"model/iges":["igs","iges"],"model/mesh":["msh","mesh","silo"],"model/mtl":["mtl"],"model/obj":["obj"],"model/step+xml":["stpx"],"model/step+zip":["stpz"],"model/step-xml+zip":["stpxz"],"model/stl":["stl"],"model/vrml":["wrl","vrml"],"model/x3d+binary":["*x3db","x3dbz"],"model/x3d+fastinfoset":["x3db"],"model/x3d+vrml":["*x3dv","x3dvz"],"model/x3d+xml":["x3d","x3dz"],"model/x3d-vrml":["x3dv"],"text/cache-manifest":["appcache","manifest"],"text/calendar":["ics","ifb"],"text/coffeescript":["coffee","litcoffee"],"text/css":["css"],"text/csv":["csv"],"text/html":["html","htm","shtml"],"text/jade":["jade"],"text/jsx":["jsx"],"text/less":["less"],"text/markdown":["markdown","md"],"text/mathml":["mml"],"text/mdx":["mdx"],"text/n3":["n3"],"text/plain":["txt","text","conf","def","list","log","in","ini"],"text/richtext":["rtx"],"text/rtf":["*rtf"],"text/sgml":["sgml","sgm"],"text/shex":["shex"],"text/slim":["slim","slm"],"text/spdx":["spdx"],"text/stylus":["stylus","styl"],"text/tab-separated-values":["tsv"],"text/troff":["t","tr","roff","man","me","ms"],"text/turtle":["ttl"],"text/uri-list":["uri","uris","urls"],"text/vcard":["vcard"],"text/vtt":["vtt"],"text/xml":["*xml"],"text/yaml":["yaml","yml"],"video/3gpp":["3gp","3gpp"],"video/3gpp2":["3g2"],"video/h261":["h261"],"video/h263":["h263"],"video/h264":["h264"],"video/iso.segment":["m4s"],"video/jpeg":["jpgv"],"video/jpm":["*jpm","jpgm"],"video/mj2":["mj2","mjp2"],"video/mp2t":["ts"],"video/mp4":["mp4","mp4v","mpg4"],"video/mpeg":["mpeg","mpg","mpe","m1v","m2v"],"video/ogg":["ogv"],"video/quicktime":["qt","mov"],"video/webm":["webm"]}},19112:(t,e,r)=>{"use strict";r.d(e,{default:()=>c});const n={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let i;const o=new Uint8Array(16);function a(){if(!i&&(i="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!i))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return i(o)}const s=[];for(let t=0;t<256;++t)s.push((t+256).toString(16).slice(1));function u(t,e=0){return s[t[e+0]]+s[t[e+1]]+s[t[e+2]]+s[t[e+3]]+"-"+s[t[e+4]]+s[t[e+5]]+"-"+s[t[e+6]]+s[t[e+7]]+"-"+s[t[e+8]]+s[t[e+9]]+"-"+s[t[e+10]]+s[t[e+11]]+s[t[e+12]]+s[t[e+13]]+s[t[e+14]]+s[t[e+15]]}const c=function(t,e,r){if(n.randomUUID&&!e&&!t)return n.randomUUID();const i=(t=t||{}).random||(t.rng||a)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,e){r=r||0;for(let t=0;t<16;++t)e[r+t]=i[t];return e}return u(i)}},32697:(t,e,r)=>{"use strict";r.d(e,{Map:()=>Re});var n="delete",i=5,o=1<>>0;if(""+r!==e||4294967295===r)return NaN;e=r}return e<0?u(t)+e:e}function l(){return!0}function f(t,e,r){return(0===t&&!v(t)||void 0!==r&&t<=-r)&&(void 0===e||void 0!==r&&e>=r)}function p(t,e){return d(t,e,0)}function h(t,e){return d(t,e,e)}function d(t,e,r){return void 0===t?r:v(t)?e===1/0?e:0|Math.max(0,e+t):void 0===e||e===t?t:0|Math.min(e,t)}function v(t){return t<0||0===t&&1/t==-1/0}var g="@@__IMMUTABLE_ITERABLE__@@";function y(t){return Boolean(t&&t[g])}var m="@@__IMMUTABLE_KEYED__@@";function _(t){return Boolean(t&&t[m])}var b="@@__IMMUTABLE_INDEXED__@@";function S(t){return Boolean(t&&t[b])}function w(t){return _(t)||S(t)}var x=function Collection(t){return y(t)?t:X(t)},E=function(t){function KeyedCollection(t){return _(t)?t:$(t)}return t&&(KeyedCollection.__proto__=t),KeyedCollection.prototype=Object.create(t&&t.prototype),KeyedCollection.prototype.constructor=KeyedCollection,KeyedCollection}(x),O=function(t){function IndexedCollection(t){return S(t)?t:J(t)}return t&&(IndexedCollection.__proto__=t),IndexedCollection.prototype=Object.create(t&&t.prototype),IndexedCollection.prototype.constructor=IndexedCollection,IndexedCollection}(x),C=function(t){function SetCollection(t){return y(t)&&!w(t)?t:Z(t)}return t&&(SetCollection.__proto__=t),SetCollection.prototype=Object.create(t&&t.prototype),SetCollection.prototype.constructor=SetCollection,SetCollection}(x);x.Keyed=E,x.Indexed=O,x.Set=C;var k="@@__IMMUTABLE_SEQ__@@";function D(t){return Boolean(t&&t[k])}var M="@@__IMMUTABLE_RECORD__@@";function I(t){return Boolean(t&&t[M])}function A(t){return y(t)||I(t)}var R="@@__IMMUTABLE_ORDERED__@@";function T(t){return Boolean(t&&t[R])}var z=0,B=1,q=2,P="function"==typeof Symbol&&Symbol.iterator,j="@@iterator",L=P||j,K=function Iterator(t){this.next=t};function N(t,e,r,n){var i=0===t?e:1===t?r:[e,r];return n?n.value=i:n={value:i,done:!1},n}function F(){return{value:void 0,done:!0}}function U(t){return!!Array.isArray(t)||!!W(t)}function G(t){return t&&"function"==typeof t.next}function H(t){var e=W(t);return e&&e.call(t)}function W(t){var e=t&&(P&&t[P]||t[j]);if("function"==typeof e)return e}K.prototype.toString=function(){return"[Iterator]"},K.KEYS=z,K.VALUES=B,K.ENTRIES=q,K.prototype.inspect=K.prototype.toSource=function(){return this.toString()},K.prototype[L]=function(){return this};var V=Object.prototype.hasOwnProperty;function Y(t){return!(!Array.isArray(t)&&"string"!=typeof t)||t&&"object"==typeof t&&Number.isInteger(t.length)&&t.length>=0&&(0===t.length?1===Object.keys(t).length:t.hasOwnProperty(t.length-1))}var X=function(t){function Seq(t){return null==t?nt():A(t)?t.toSeq():function(t){var e=at(t);if(e)return(n=W(r=t))&&n===r.entries?e.fromEntrySeq():function(t){var e=W(t);return e&&e===t.keys}(t)?e.toSetSeq():e;var r,n;if("object"==typeof t)return new tt(t);throw new TypeError("Expected Array or collection object of values, or keyed object: "+t)}(t)}return t&&(Seq.__proto__=t),Seq.prototype=Object.create(t&&t.prototype),Seq.prototype.constructor=Seq,Seq.prototype.toSeq=function(){return this},Seq.prototype.toString=function(){return this.__toString("Seq {","}")},Seq.prototype.cacheResult=function(){return!this._cache&&this.__iterateUncached&&(this._cache=this.entrySeq().toArray(),this.size=this._cache.length),this},Seq.prototype.__iterate=function __iterate(t,e){var r=this._cache;if(r){for(var n=r.length,i=0;i!==n;){var o=r[e?n-++i:i++];if(!1===t(o[1],o[0],this))break}return i}return this.__iterateUncached(t,e)},Seq.prototype.__iterator=function __iterator(t,e){var r=this._cache;if(r){var n=r.length,i=0;return new K((function(){if(i===n)return{value:void 0,done:!0};var o=r[e?n-++i:i++];return N(t,o[0],o[1])}))}return this.__iteratorUncached(t,e)},Seq}(x),$=function(t){function KeyedSeq(t){return null==t?nt().toKeyedSeq():y(t)?_(t)?t.toSeq():t.fromEntrySeq():I(t)?t.toSeq():it(t)}return t&&(KeyedSeq.__proto__=t),KeyedSeq.prototype=Object.create(t&&t.prototype),KeyedSeq.prototype.constructor=KeyedSeq,KeyedSeq.prototype.toKeyedSeq=function(){return this},KeyedSeq}(X),J=function(t){function IndexedSeq(t){return null==t?nt():y(t)?_(t)?t.entrySeq():t.toIndexedSeq():I(t)?t.toSeq().entrySeq():ot(t)}return t&&(IndexedSeq.__proto__=t),IndexedSeq.prototype=Object.create(t&&t.prototype),IndexedSeq.prototype.constructor=IndexedSeq,IndexedSeq.of=function(){return IndexedSeq(arguments)},IndexedSeq.prototype.toIndexedSeq=function(){return this},IndexedSeq.prototype.toString=function(){return this.__toString("Seq [","]")},IndexedSeq}(X),Z=function(t){function SetSeq(t){return(y(t)&&!w(t)?t:J(t)).toSetSeq()}return t&&(SetSeq.__proto__=t),SetSeq.prototype=Object.create(t&&t.prototype),SetSeq.prototype.constructor=SetSeq,SetSeq.of=function(){return SetSeq(arguments)},SetSeq.prototype.toSetSeq=function(){return this},SetSeq}(X);X.isSeq=D,X.Keyed=$,X.Set=Z,X.Indexed=J,X.prototype[k]=!0;var Q=function(t){function ArraySeq(t){this._array=t,this.size=t.length}return t&&(ArraySeq.__proto__=t),ArraySeq.prototype=Object.create(t&&t.prototype),ArraySeq.prototype.constructor=ArraySeq,ArraySeq.prototype.get=function(t,e){return this.has(t)?this._array[c(this,t)]:e},ArraySeq.prototype.__iterate=function __iterate(t,e){for(var r=this._array,n=r.length,i=0;i!==n;){var o=e?n-++i:i++;if(!1===t(r[o],o,this))break}return i},ArraySeq.prototype.__iterator=function __iterator(t,e){var r=this._array,n=r.length,i=0;return new K((function(){if(i===n)return{value:void 0,done:!0};var o=e?n-++i:i++;return N(t,o,r[o])}))},ArraySeq}(J),tt=function(t){function ObjectSeq(t){var e=Object.keys(t).concat(Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t):[]);this._object=t,this._keys=e,this.size=e.length}return t&&(ObjectSeq.__proto__=t),ObjectSeq.prototype=Object.create(t&&t.prototype),ObjectSeq.prototype.constructor=ObjectSeq,ObjectSeq.prototype.get=function(t,e){return void 0===e||this.has(t)?this._object[t]:e},ObjectSeq.prototype.has=function(t){return V.call(this._object,t)},ObjectSeq.prototype.__iterate=function __iterate(t,e){for(var r=this._object,n=this._keys,i=n.length,o=0;o!==i;){var a=n[e?i-++o:o++];if(!1===t(r[a],a,this))break}return o},ObjectSeq.prototype.__iterator=function __iterator(t,e){var r=this._object,n=this._keys,i=n.length,o=0;return new K((function(){if(o===i)return{value:void 0,done:!0};var a=n[e?i-++o:o++];return N(t,a,r[a])}))},ObjectSeq}($);tt.prototype[R]=!0;var et,rt=function(t){function CollectionSeq(t){this._collection=t,this.size=t.length||t.size}return t&&(CollectionSeq.__proto__=t),CollectionSeq.prototype=Object.create(t&&t.prototype),CollectionSeq.prototype.constructor=CollectionSeq,CollectionSeq.prototype.__iterateUncached=function __iterateUncached(t,e){if(e)return this.cacheResult().__iterate(t,e);var r=H(this._collection),n=0;if(G(r))for(var i;!(i=r.next()).done&&!1!==t(i.value,n++,this););return n},CollectionSeq.prototype.__iteratorUncached=function __iteratorUncached(t,e){if(e)return this.cacheResult().__iterator(t,e);var r=H(this._collection);if(!G(r))return new K(F);var n=0;return new K((function(){var e=r.next();return e.done?e:N(t,n++,e.value)}))},CollectionSeq}(J);function nt(){return et||(et=new Q([]))}function it(t){var e=at(t);if(e)return e.fromEntrySeq();if("object"==typeof t)return new tt(t);throw new TypeError("Expected Array or collection object of [k, v] entries, or keyed object: "+t)}function ot(t){var e=at(t);if(e)return e;throw new TypeError("Expected Array or collection object of values: "+t)}function at(t){return Y(t)?new Q(t):U(t)?new rt(t):void 0}var st="@@__IMMUTABLE_MAP__@@";function ut(t){return Boolean(t&&t[st])}function ct(t){return ut(t)&&T(t)}function lt(t){return Boolean(t&&"function"==typeof t.equals&&"function"==typeof t.hashCode)}function ft(t,e){if(t===e||t!=t&&e!=e)return!0;if(!t||!e)return!1;if("function"==typeof t.valueOf&&"function"==typeof e.valueOf){if((t=t.valueOf())===(e=e.valueOf())||t!=t&&e!=e)return!0;if(!t||!e)return!1}return!!(lt(t)&<(e)&&t.equals(e))}var pt="function"==typeof Math.imul&&-2===Math.imul(4294967295,2)?Math.imul:function(t,e){var r=65535&(t|=0),n=65535&(e|=0);return r*n+((t>>>16)*n+r*(e>>>16)<<16>>>0)|0};function ht(t){return t>>>1&1073741824|3221225471&t}var dt=Object.prototype.valueOf;function vt(t){if(null==t)return gt(t);if("function"==typeof t.hashCode)return ht(t.hashCode(t));var e,r=(e=t).valueOf!==dt&&"function"==typeof e.valueOf?e.valueOf(e):e;if(null==r)return gt(r);switch(typeof r){case"boolean":return r?1108378657:1108378656;case"number":return function(t){if(t!=t||t===1/0)return 0;var e=0|t;e!==t&&(e^=4294967295*t);for(;t>4294967295;)e^=t/=4294967295;return ht(e)}(r);case"string":return r.length>Ct?function(t){var e=Mt[t];void 0===e&&(e=yt(t),Dt===kt&&(Dt=0,Mt={}),Dt++,Mt[t]=e);return e}(r):yt(r);case"object":case"function":return function(t){var e;if(wt&&void 0!==(e=St.get(t)))return e;if(e=t[Ot],void 0!==e)return e;if(!_t){if(void 0!==(e=t.propertyIsEnumerable&&t.propertyIsEnumerable[Ot]))return e;if(void 0!==(e=function(t){if(t&&t.nodeType>0)switch(t.nodeType){case 1:return t.uniqueID;case 9:return t.documentElement&&t.documentElement.uniqueID}}(t)))return e}if(e=bt(),wt)St.set(t,e);else{if(void 0!==mt&&!1===mt(t))throw new Error("Non-extensible objects are not allowed as keys.");if(_t)Object.defineProperty(t,Ot,{enumerable:!1,configurable:!1,writable:!1,value:e});else if(void 0!==t.propertyIsEnumerable&&t.propertyIsEnumerable===t.constructor.prototype.propertyIsEnumerable)t.propertyIsEnumerable=function(){return this.constructor.prototype.propertyIsEnumerable.apply(this,arguments)},t.propertyIsEnumerable[Ot]=e;else{if(void 0===t.nodeType)throw new Error("Unable to set a non-enumerable property on object.");t[Ot]=e}}return e}(r);case"symbol":return function(t){var e=xt[t];if(void 0!==e)return e;return e=bt(),xt[t]=e,e}(r);default:if("function"==typeof r.toString)return yt(r.toString());throw new Error("Value type "+typeof r+" cannot be hashed.")}}function gt(t){return null===t?1108378658:1108378659}function yt(t){for(var e=0,r=0;r=0&&(l.get=function(e,r){return(e=c(this,e))>=0&&es)return{value:void 0,done:!0};var t=i.next();return n||e===B||t.done?t:N(e,u-1,e===z?void 0:t.value[1],t)}))},l}function Lt(t,e,r,n){var i=Yt(t);return i.__iterateUncached=function(i,o){var a=this;if(o)return this.cacheResult().__iterate(i,o);var s=!0,u=0;return t.__iterate((function(t,o,c){if(!s||!(s=e.call(r,t,o,c)))return u++,i(t,n?o:u-1,a)})),u},i.__iteratorUncached=function(i,o){var a=this;if(o)return this.cacheResult().__iterator(i,o);var s=t.__iterator(q,o),u=!0,c=0;return new K((function(){var t,o,l;do{if((t=s.next()).done)return n||i===B?t:N(i,c++,i===z?void 0:t.value[1],t);var f=t.value;o=f[0],l=f[1],u&&(u=e.call(r,l,o,a))}while(u);return i===q?t:N(i,o,l,t)}))},i}function Kt(t,e,r){var n=Yt(t);return n.__iterateUncached=function(i,o){if(o)return this.cacheResult().__iterate(i,o);var a=0,s=!1;return function t(u,c){u.__iterate((function(o,u){return(!e||c0}function Gt(t,e,r,n){var i=Yt(t),o=new Q(r).map((function(t){return t.size}));return i.size=n?o.max():o.min(),i.__iterate=function(t,e){for(var r,n=this.__iterator(B,e),i=0;!(r=n.next()).done&&!1!==t(r.value,i++,this););return i},i.__iteratorUncached=function(t,i){var o=r.map((function(t){return t=x(t),H(i?t.reverse():t)})),a=0,s=!1;return new K((function(){var r;return s||(r=o.map((function(t){return t.next()})),s=n?r.every((function(t){return t.done})):r.some((function(t){return t.done}))),s?{value:void 0,done:!0}:N(t,a++,e.apply(null,r.map((function(t){return t.value}))))}))},i}function Ht(t,e){return t===e?t:D(t)?e:t.constructor(e)}function Wt(t){if(t!==Object(t))throw new TypeError("Expected [K, V] tuple: "+t)}function Vt(t){return _(t)?E:S(t)?O:C}function Yt(t){return Object.create((_(t)?$:S(t)?J:Z).prototype)}function Xt(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):X.prototype.cacheResult.call(this)}function $t(t,e){return void 0===t&&void 0===e?0:void 0===t?1:void 0===e?-1:t>e?1:t0;)e[r]=arguments[r+1];if("function"!=typeof t)throw new TypeError("Invalid merger function: "+t);return Se(this,e,t)}function Se(t,e,r){for(var n=[],i=0;i0;)e[r]=arguments[r+1];return we(this,e,t)}function Ce(t){for(var e=[],r=arguments.length-1;r-- >0;)e[r]=arguments[r+1];return le(this,t,Ge(),(function(t){return xe(t,e)}))}function ke(t){for(var e=[],r=arguments.length-1;r-- >0;)e[r]=arguments[r+1];return le(this,t,Ge(),(function(t){return we(t,e)}))}function De(t){var e=this.asMutable();return t(e),e.wasAltered()?e.__ensureOwner(this.__ownerID):this}function Me(){return this.__ownerID?this:this.__ensureOwner(new OwnerID)}function Ie(){return this.__ensureOwner()}function Ae(){return this.__altered}var Re=function(t){function Map(e){return null==e?Ge():ut(e)&&!T(e)?e:Ge().withMutations((function(r){var n=t(e);Qt(n.size),n.forEach((function(t,e){return r.set(e,t)}))}))}return t&&(Map.__proto__=t),Map.prototype=Object.create(t&&t.prototype),Map.prototype.constructor=Map,Map.of=function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];return Ge().withMutations((function(e){for(var r=0;r=t.length)throw new Error("Missing value for key: "+t[r]);e.set(t[r],t[r+1])}}))},Map.prototype.toString=function(){return this.__toString("Map {","}")},Map.prototype.get=function(t,e){return this._root?this._root.get(0,void 0,t,e):e},Map.prototype.set=function(t,e){return He(this,t,e)},Map.prototype.remove=function(t){return He(this,t,s)},Map.prototype.deleteAll=function(t){var e=x(t);return 0===e.size?this:this.withMutations((function(t){e.forEach((function(e){return t.remove(e)}))}))},Map.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):Ge()},Map.prototype.sort=function(t){return gr(Nt(this,t))},Map.prototype.sortBy=function(t,e){return gr(Nt(this,e,t))},Map.prototype.map=function(t,e){var r=this;return this.withMutations((function(n){n.forEach((function(i,o){n.set(o,t.call(e,i,o,r))}))}))},Map.prototype.__iterator=function __iterator(t,e){return new Ke(this,t,e)},Map.prototype.__iterate=function __iterate(t,e){var r=this,n=0;return this._root&&this._root.iterate((function(e){return n++,t(e[1],e[0],r)}),e),n},Map.prototype.__ensureOwner=function __ensureOwner(t){return t===this.__ownerID?this:t?Ue(this.size,this._root,t,this.__hash):0===this.size?Ge():(this.__ownerID=t,this.__altered=!1,this)},Map}(E);Re.isMap=ut;var Te=Re.prototype;Te[st]=!0,Te[n]=Te.remove,Te.removeAll=Te.deleteAll,Te.setIn=he,Te.removeIn=Te.deleteIn=ve,Te.update=ye,Te.updateIn=me,Te.merge=Te.concat=_e,Te.mergeWith=be,Te.mergeDeep=Ee,Te.mergeDeepWith=Oe,Te.mergeIn=Ce,Te.mergeDeepIn=ke,Te.withMutations=De,Te.wasAltered=Ae,Te.asImmutable=Ie,Te["@@transducer/init"]=Te.asMutable=Me,Te["@@transducer/step"]=function(t,e){return t.set(e[0],e[1])},Te["@@transducer/result"]=function(t){return t.asImmutable()};var ze=function ArrayMapNode(t,e){this.ownerID=t,this.entries=e};ze.prototype.get=function(t,e,r,n){for(var i=this.entries,o=0,a=i.length;o=Je)return function(t,e,r,n){t||(t=new OwnerID);for(var i=new je(t,vt(r),[r,n]),o=0;o>>t)&a),s=this.bitmap;return 0==(s&o)?n:this.nodes[Xe(s&o-1)].get(t+i,e,r,n)},Be.prototype.update=function(t,e,r,n,u,c,l){void 0===r&&(r=vt(n));var f=(0===e?r:r>>>e)&a,p=1<=Ze)return function(t,e,r,n,i){for(var a=0,s=new Array(o),u=0;0!==r;u++,r>>>=1)s[u]=1&r?e[a++]:void 0;return s[n]=i,new qe(t,a+1,s)}(t,g,h,f,m);if(d&&!m&&2===g.length&&Ve(g[1^v]))return g[1^v];if(d&&m&&1===g.length&&Ve(m))return m;var _=t&&t===this.ownerID,b=d?m?h:h^p:h|p,S=d?m?$e(g,v,m,_):function(t,e,r){var n=t.length-1;if(r&&e===n)return t.pop(),t;for(var i=new Array(n),o=0,a=0;a>>t)&a,s=this.nodes[o];return s?s.get(t+i,e,r,n):n},qe.prototype.update=function(t,e,r,n,o,u,c){void 0===r&&(r=vt(n));var l=(0===e?r:r>>>e)&a,f=o===s,p=this.nodes,h=p[l];if(f&&!h)return this;var d=We(h,t,e+i,r,n,o,u,c);if(d===h)return this;var v=this.count;if(h){if(!d&&--v>>r)&a,c=(0===r?n:n>>>r)&a,l=u===c?[Ye(t,e,r+i,n,o)]:(s=new je(e,n,o),u>1&1431655765))+(t>>2&858993459))+(t>>4)&252645135,t+=t>>8,127&(t+=t>>16)}function $e(t,e,r,n){var i=n?t:Jt(t);return i[e]=r,i}var Je=o/4,Ze=o/2,Qe=o/4,tr="@@__IMMUTABLE_LIST__@@";function er(t){return Boolean(t&&t[tr])}var rr=function(t){function List(e){var r=cr();if(null==e)return r;if(er(e))return e;var n=t(e),a=n.size;return 0===a?r:(Qt(a),a>0&&a=0&&t=t.size||e<0)return t.withMutations((function(t){e<0?hr(t,e).set(0,r):hr(t,0,e+1).set(e,r)}));e+=t._origin;var n=t._tail,i=t._root,o={value:!1};e>=dr(t._capacity)?n=lr(n,t.__ownerID,0,e,r,o):i=lr(i,t.__ownerID,t._level,e,r,o);if(!o.value)return t;if(t.__ownerID)return t._root=i,t._tail=n,t.__hash=void 0,t.__altered=!0,t;return ur(t._origin,t._capacity,t._level,i,n)}(this,t,e)},List.prototype.remove=function(t){return this.has(t)?0===t?this.shift():t===this.size-1?this.pop():this.splice(t,1):this},List.prototype.insert=function(t,e){return this.splice(t,0,e)},List.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=this._origin=this._capacity=0,this._level=i,this._root=this._tail=this.__hash=void 0,this.__altered=!0,this):cr()},List.prototype.push=function(){var t=arguments,e=this.size;return this.withMutations((function(r){hr(r,0,e+t.length);for(var n=0;n>>e&a;if(n>=this.array.length)return new ir([],t);var o,s=0===n;if(e>0){var u=this.array[n];if((o=u&&u.removeBefore(t,e-i,r))===u&&s)return this}if(s&&!o)return this;var c=fr(this,t);if(!s)for(var l=0;l>>e&a;if(o>=this.array.length)return this;if(e>0){var s=this.array[o];if((n=s&&s.removeAfter(t,e-i,r))===s&&o===this.array.length-1)return this}var u=fr(this,t);return u.array.splice(o+1),n&&(u.array[o]=n),u};var or,ar={};function sr(t,e){var r=t._origin,n=t._capacity,a=dr(n),s=t._tail;return u(t._root,t._level,0);function u(t,c,l){return 0===c?function(t,i){var u=i===a?s&&s.array:t&&t.array,c=i>r?0:r-i,l=n-i;l>o&&(l=o);return function(){if(c===l)return ar;var t=e?--l:c++;return u&&u[t]}}(t,l):function(t,a,s){var c,l=t&&t.array,f=s>r?0:r-s>>a,p=1+(n-s>>a);p>o&&(p=o);return function(){for(;;){if(c){var t=c();if(t!==ar)return t;c=null}if(f===p)return ar;var r=e?--p:f++;c=u(l&&l[r],a-i,s+(r<>>r&a,l=t&&c0){var f=t&&t.array[c],p=lr(f,e,r-i,n,o,s);return p===f?t:((u=fr(t,e)).array[c]=p,u)}return l&&t.array[c]===o?t:(s&&SetRef(s),u=fr(t,e),void 0===o&&c===u.array.length-1?u.array.pop():u.array[c]=o,u)}function fr(t,e){return e&&t&&e===t.ownerID?t:new ir(t?t.array.slice():[],e)}function pr(t,e){if(e>=dr(t._capacity))return t._tail;if(e<1<0;)r=r.array[e>>>n&a],n-=i;return r}}function hr(t,e,r){void 0!==e&&(e|=0),void 0!==r&&(r|=0);var n=t.__ownerID||new OwnerID,o=t._origin,s=t._capacity,u=o+e,c=void 0===r?s:r<0?s+r:o+r;if(u===o&&c===s)return t;if(u>=c)return t.clear();for(var l=t._level,f=t._root,p=0;u+p<0;)f=new ir(f&&f.array.length?[void 0,f]:[],n),p+=1<<(l+=i);p&&(u+=p,o+=p,c+=p,s+=p);for(var h=dr(s),d=dr(c);d>=1<h?new ir([],n):v;if(v&&d>h&&ui;m-=i){var _=h>>>m&a;y=y.array[_]=fr(y.array[_],n)}y.array[h>>>i&a]=v}if(c=d)u-=d,c-=d,l=i,f=null,g=g&&g.removeBefore(n,0,u);else if(u>o||d>>l&a;if(b!==d>>>l&a)break;b&&(p+=(1<o&&(f=f.removeBefore(n,l,u-p)),f&&d>>i<=o&&u.size>=2*a.size?(n=(i=u.filter((function(t,e){return void 0!==t&&c!==e}))).toKeyedSeq().map((function(t){return t[0]})).flip().toMap(),t.__ownerID&&(n.__ownerID=i.__ownerID=t.__ownerID)):(n=a.remove(e),i=c===u.size-1?u.pop():u.set(c,void 0))}else if(l){if(r===u.get(c)[1])return t;n=a,i=u.set(c,[e,r])}else n=a.set(e,u.size),i=u.set(u.size,[e,r]);return t.__ownerID?(t.size=n.size,t._map=n,t._list=i,t.__hash=void 0,t.__altered=!0,t):yr(n,i)}gr.isOrderedMap=ct,gr.prototype[R]=!0,gr.prototype[n]=gr.prototype.remove;var br="@@__IMMUTABLE_STACK__@@";function Sr(t){return Boolean(t&&t[br])}var wr=function(t){function Stack(t){return null==t?Cr():Sr(t)?t:Cr().pushAll(t)}return t&&(Stack.__proto__=t),Stack.prototype=Object.create(t&&t.prototype),Stack.prototype.constructor=Stack,Stack.of=function(){return this(arguments)},Stack.prototype.toString=function(){return this.__toString("Stack [","]")},Stack.prototype.get=function(t,e){var r=this._head;for(t=c(this,t);r&&t--;)r=r.next;return r?r.value:e},Stack.prototype.peek=function(){return this._head&&this._head.value},Stack.prototype.push=function(){var t=arguments;if(0===arguments.length)return this;for(var e=this.size+arguments.length,r=this._head,n=arguments.length-1;n>=0;n--)r={value:t[n],next:r};return this.__ownerID?(this.size=e,this._head=r,this.__hash=void 0,this.__altered=!0,this):Or(e,r)},Stack.prototype.pushAll=function(e){if(0===(e=t(e)).size)return this;if(0===this.size&&Sr(e))return e;Qt(e.size);var r=this.size,n=this._head;return e.__iterate((function(t){r++,n={value:t,next:n}}),!0),this.__ownerID?(this.size=r,this._head=n,this.__hash=void 0,this.__altered=!0,this):Or(r,n)},Stack.prototype.pop=function(){return this.slice(1)},Stack.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):Cr()},Stack.prototype.slice=function(e,r){if(f(e,r,this.size))return this;var n=p(e,this.size);if(h(r,this.size)!==this.size)return t.prototype.slice.call(this,e,r);for(var i=this.size-n,o=this._head;n--;)o=o.next;return this.__ownerID?(this.size=i,this._head=o,this.__hash=void 0,this.__altered=!0,this):Or(i,o)},Stack.prototype.__ensureOwner=function __ensureOwner(t){return t===this.__ownerID?this:t?Or(this.size,this._head,t,this.__hash):0===this.size?Cr():(this.__ownerID=t,this.__altered=!1,this)},Stack.prototype.__iterate=function __iterate(t,e){var r=this;if(e)return new Q(this.toArray()).__iterate((function(e,n){return t(e,n,r)}),e);for(var n=0,i=this._head;i&&!1!==t(i.value,n++,this);)i=i.next;return n},Stack.prototype.__iterator=function __iterator(t,e){if(e)return new Q(this.toArray()).__iterator(t,e);var r=0,n=this._head;return new K((function(){if(n){var e=n.value;return n=n.next,N(t,r++,e)}return{value:void 0,done:!0}}))},Stack}(O);wr.isStack=Sr;var xr,Er=wr.prototype;function Or(t,e,r,n){var i=Object.create(Er);return i.size=t,i._head=e,i.__ownerID=r,i.__hash=n,i.__altered=!1,i}function Cr(){return xr||(xr=Or(0))}Er[br]=!0,Er.shift=Er.pop,Er.unshift=Er.push,Er.unshiftAll=Er.pushAll,Er.withMutations=De,Er.wasAltered=Ae,Er.asImmutable=Ie,Er["@@transducer/init"]=Er.asMutable=Me,Er["@@transducer/step"]=function(t,e){return t.unshift(e)},Er["@@transducer/result"]=function(t){return t.asImmutable()};var kr="@@__IMMUTABLE_SET__@@";function Dr(t){return Boolean(t&&t[kr])}function Mr(t){return Dr(t)&&T(t)}function Ir(t,e){if(t===e)return!0;if(!y(e)||void 0!==t.size&&void 0!==e.size&&t.size!==e.size||void 0!==t.__hash&&void 0!==e.__hash&&t.__hash!==e.__hash||_(t)!==_(e)||S(t)!==S(e)||T(t)!==T(e))return!1;if(0===t.size&&0===e.size)return!0;var r=!w(t);if(T(t)){var n=t.entries();return e.every((function(t,e){var i=n.next().value;return i&&ft(i[1],t)&&(r||ft(i[0],e))}))&&n.next().done}var i=!1;if(void 0===t.size)if(void 0===e.size)"function"==typeof t.cacheResult&&t.cacheResult();else{i=!0;var o=t;t=e,e=o}var a=!0,u=e.__iterate((function(e,n){if(r?!t.has(e):i?!ft(e,t.get(n,s)):!ft(t.get(n,s),e))return a=!1,!1}));return a&&t.size===u}function Ar(t,e){var r=function(r){t.prototype[r]=e[r]};return Object.keys(e).forEach(r),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(e).forEach(r),t}function Rr(t){if(!t||"object"!=typeof t)return t;if(!y(t)){if(!ne(t))return t;t=X(t)}if(_(t)){var e={};return t.__iterate((function(t,r){e[r]=Rr(t)})),e}var r=[];return t.__iterate((function(t){r.push(Rr(t))})),r}var Tr=function(t){function Set(e){return null==e?jr():Dr(e)&&!T(e)?e:jr().withMutations((function(r){var n=t(e);Qt(n.size),n.forEach((function(t){return r.add(t)}))}))}return t&&(Set.__proto__=t),Set.prototype=Object.create(t&&t.prototype),Set.prototype.constructor=Set,Set.of=function(){return this(arguments)},Set.fromKeys=function(t){return this(E(t).keySeq())},Set.intersect=function(t){return(t=x(t).toArray()).length?Br.intersect.apply(Set(t.pop()),t):jr()},Set.union=function(t){return(t=x(t).toArray()).length?Br.union.apply(Set(t.pop()),t):jr()},Set.prototype.toString=function(){return this.__toString("Set {","}")},Set.prototype.has=function(t){return this._map.has(t)},Set.prototype.add=function(t){return qr(this,this._map.set(t,t))},Set.prototype.remove=function(t){return qr(this,this._map.remove(t))},Set.prototype.clear=function(){return qr(this,this._map.clear())},Set.prototype.map=function(t,e){var r=this,n=!1,i=qr(this,this._map.mapEntries((function(i){var o=i[1],a=t.call(e,o,o,r);return a!==o&&(n=!0),[a,a]}),e));return n?i:this},Set.prototype.union=function(){for(var e=[],r=arguments.length;r--;)e[r]=arguments[r];return 0===(e=e.filter((function(t){return 0!==t.size}))).length?this:0!==this.size||this.__ownerID||1!==e.length?this.withMutations((function(r){for(var n=0;n=0&&e=0&&r>>-15,461845907),e=pt(e<<13|e>>>-13,5),e=(e+3864292196|0)^t,e=pt(e^e>>>16,2246822507),e=pt(e^e>>>13,3266489909),e=ht(e^e>>>16),e}(t.__iterate(r?e?function(t,e){n=31*n+rn(vt(t),vt(e))|0}:function(t,e){n=n+rn(vt(t),vt(e))|0}:e?function(t){n=31*n+vt(t)|0}:function(t){n=n+vt(t)|0}),n)}(this))}});var Hr=x.prototype;Hr[g]=!0,Hr[L]=Hr.values,Hr.toJSON=Hr.toArray,Hr.__toStringMapper=ie,Hr.inspect=Hr.toSource=function(){return this.toString()},Hr.chain=Hr.flatMap,Hr.contains=Hr.includes,Ar(E,{flip:function(){return Ht(this,zt(this))},mapEntries:function(t,e){var r=this,n=0;return Ht(this,this.toSeq().map((function(i,o){return t.call(e,[o,i],n++,r)})).fromEntrySeq())},mapKeys:function(t,e){var r=this;return Ht(this,this.toSeq().flip().map((function(n,i){return t.call(e,n,i,r)})).flip())}});var Wr=E.prototype;Wr[m]=!0,Wr[L]=Hr.entries,Wr.toJSON=Gr,Wr.__toStringMapper=function(t,e){return ie(e)+": "+ie(t)},Ar(O,{toKeyedSeq:function(){return new It(this,!1)},filter:function(t,e){return Ht(this,Pt(this,t,e,!1))},findIndex:function(t,e){var r=this.findEntry(t,e);return r?r[0]:-1},indexOf:function(t){var e=this.keyOf(t);return void 0===e?-1:e},lastIndexOf:function(t){var e=this.lastKeyOf(t);return void 0===e?-1:e},reverse:function(){return Ht(this,qt(this,!1))},slice:function(t,e){return Ht(this,jt(this,t,e,!1))},splice:function(t,e){var r=arguments.length;if(e=Math.max(e||0,0),0===r||2===r&&!e)return this;t=p(t,t<0?this.count():this.size);var n=this.slice(0,t);return Ht(this,1===r?n:n.concat(Jt(arguments,2),this.slice(t+e)))},findLastIndex:function(t,e){var r=this.findLastEntry(t,e);return r?r[0]:-1},first:function(t){return this.get(0,t)},flatten:function(t){return Ht(this,Kt(this,t,!1))},get:function(t,e){return(t=c(this,t))<0||this.size===1/0||void 0!==this.size&&t>this.size?e:this.find((function(e,r){return r===t}),void 0,e)},has:function(t){return(t=c(this,t))>=0&&(void 0!==this.size?this.size===1/0||te?-1:0}function rn(t,e){return t^e+2654435769+(t<<6)+(t>>2)|0}Yr.has=Hr.includes,Yr.contains=Yr.includes,Yr.keys=Yr.values,Ar($,Wr),Ar(J,Vr),Ar(Z,Yr);var nn=function(t){function OrderedSet(t){return null==t?un():Mr(t)?t:un().withMutations((function(e){var r=C(t);Qt(r.size),r.forEach((function(t){return e.add(t)}))}))}return t&&(OrderedSet.__proto__=t),OrderedSet.prototype=Object.create(t&&t.prototype),OrderedSet.prototype.constructor=OrderedSet,OrderedSet.of=function(){return this(arguments)},OrderedSet.fromKeys=function(t){return this(E(t).keySeq())},OrderedSet.prototype.toString=function(){return this.__toString("OrderedSet {","}")},OrderedSet}(Tr);nn.isOrderedSet=Mr;var on,an=nn.prototype;function sn(t,e){var r=Object.create(an);return r.size=t?t.size:0,r._map=t,r.__ownerID=e,r}function un(){return on||(on=sn(mr()))}an[R]=!0,an.zip=Vr.zip,an.zipWith=Vr.zipWith,an.zipAll=Vr.zipAll,an.__empty=un,an.__make=sn;var cn=function Record(t,e){var r;!function(t){if(I(t))throw new Error("Can not call `Record` with an immutable Record as default values. Use a plain javascript object instead.");if(A(t))throw new Error("Can not call `Record` with an immutable Collection as default values. Use a plain javascript object instead.");if(null===t||"object"!=typeof t)throw new Error("Can not call `Record` with a non-object as default values. Use a plain javascript object instead.")}(t);var n=function Record(o){var a=this;if(o instanceof n)return o;if(!(this instanceof n))return new n(o);if(!r){r=!0;var s=Object.keys(t),u=i._indices={};i._name=e,i._keys=s,i._defaultValues=t;for(var c=0;c{"use strict";r.d(e,{FlagsProvider:()=>FlagsProvider,useFeature:()=>u,useFeatures:()=>s});var n=r(67294);function i(){return i=Object.assign?Object.assign.bind():function(t){for(var e=1;e{"use strict";r.d(e,{Blurhash:()=>C});var n=r(67294),i=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","#","$","%","*","+",",","-",".",":",";","=","?","@","[","]","^","_","{","|","}","~"],o=t=>{let e=0;for(let r=0;r{let e=t/255;return e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)},s=t=>{let e=Math.max(0,Math.min(1,t));return e<=.0031308?Math.trunc(12.92*e*255+.5):Math.trunc(255*(1.055*Math.pow(e,.4166666666666667)-.055)+.5)},u=(t,e)=>(t=>t<0?-1:1)(t)*Math.pow(Math.abs(t),e),c=class extends Error{constructor(t){super(t),this.name="ValidationError",this.message=t}},l=t=>{if(!t||t.length<6)throw new c("The blurhash string must be at least 6 characters");let e=o(t[0]),r=Math.floor(e/9)+1,n=e%9+1;if(t.length!==4+2*n*r)throw new c(`blurhash length mismatch: length is ${t.length} but it should be ${4+2*n*r}`)},f=t=>{let e=t>>8&255,r=255&t;return[a(t>>16),a(e),a(r)]},p=(t,e)=>{let r=Math.floor(t/361),n=Math.floor(t/19)%19,i=t%19;return[u((r-9)/9,2)*e,u((n-9)/9,2)*e,u((i-9)/9,2)*e]},h=(t,e,r,n)=>{l(t),n|=1;let i=o(t[0]),a=Math.floor(i/9)+1,u=i%9+1,c=(o(t[1])+1)/166,h=new Array(u*a);for(let e=0;ee in t?d(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,S=(t,e)=>{for(var r in e||(e={}))m.call(e,r)&&b(t,r,e[r]);if(y)for(var r of y(e))_.call(e,r)&&b(t,r,e[r]);return t},w=(t,e)=>v(t,g(e)),x=(t,e)=>{var r={};for(var n in t)m.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(null!=t&&y)for(var n of y(t))e.indexOf(n)<0&&_.call(t,n)&&(r[n]=t[n]);return r},E=class extends n.PureComponent{constructor(){super(...arguments),this.canvas=null,this.handleRef=t=>{this.canvas=t,this.draw()},this.draw=()=>{let{hash:t,height:e,punch:r,width:n}=this.props;if(this.canvas){let i=h(t,n,e,r),o=this.canvas.getContext("2d"),a=o.createImageData(n,e);a.data.set(i),o.putImageData(a,0,0)}}}componentDidUpdate(){this.draw()}render(){let t=this.props,{hash:e,height:r,width:i}=t,o=x(t,["hash","height","width"]);return n.createElement("canvas",w(S({},o),{height:r,width:i,ref:this.handleRef}))}};E.defaultProps={height:128,width:128};var O={position:"absolute",top:0,bottom:0,left:0,right:0,width:"100%",height:"100%"},C=class extends n.PureComponent{componentDidUpdate(){if(this.props.resolutionX<=0)throw new Error("resolutionX must be larger than zero");if(this.props.resolutionY<=0)throw new Error("resolutionY must be larger than zero")}render(){let t=this.props,{hash:e,height:r,width:i,punch:o,resolutionX:a,resolutionY:s,style:u}=t,c=x(t,["hash","height","width","punch","resolutionX","resolutionY","style"]);return n.createElement("div",w(S({},c),{style:w(S({display:"inline-block",height:r,width:i},u),{position:"relative"})}),n.createElement(E,{hash:e,height:s,width:a,punch:o,style:O}))}};C.defaultProps={height:128,width:128,resolutionX:32,resolutionY:32}},3961:(t,e,r)=>{"use strict";r.d(e,{default:()=>c});const n={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let i;const o=new Uint8Array(16);function a(){if(!i&&(i="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!i))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return i(o)}const s=[];for(let t=0;t<256;++t)s.push((t+256).toString(16).slice(1));function u(t,e=0){return s[t[e+0]]+s[t[e+1]]+s[t[e+2]]+s[t[e+3]]+"-"+s[t[e+4]]+s[t[e+5]]+"-"+s[t[e+6]]+s[t[e+7]]+"-"+s[t[e+8]]+s[t[e+9]]+"-"+s[t[e+10]]+s[t[e+11]]+s[t[e+12]]+s[t[e+13]]+s[t[e+14]]+s[t[e+15]]}const c=function(t,e,r){if(n.randomUUID&&!e&&!t)return n.randomUUID();const i=(t=t||{}).random||(t.rng||a)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,e){r=r||0;for(let t=0;t<16;++t)e[r+t]=i[t];return e}return u(i)}},23550:(t,e,r)=>{"use strict";var n=r(69985),i=String,o=TypeError;t.exports=function(t){if("object"==typeof t||n(t))return t;throw new o("Can't set "+i(t)+" as a prototype")}},47146:t=>{"use strict";t.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},33050:(t,e,r)=>{"use strict";var n=r(52743),i=r(6648),o=TypeError;t.exports=n(ArrayBuffer.prototype,"byteLength","get")||function(t){if("ArrayBuffer"!==i(t))throw new o("ArrayBuffer expected");return t.byteLength}},22961:(t,e,r)=>{"use strict";var n=r(68844),i=r(33050),o=n(ArrayBuffer.prototype.slice);t.exports=function(t){if(0!==i(t))return!1;try{return o(t,0,0),!1}catch(t){return!0}}},29195:(t,e,r)=>{"use strict";var n=r(19037),i=r(68844),o=r(52743),a=r(19842),s=r(22961),u=r(33050),c=r(21420),l=r(63514),f=n.structuredClone,p=n.ArrayBuffer,h=n.DataView,d=n.TypeError,v=Math.min,g=p.prototype,y=h.prototype,m=i(g.slice),_=o(g,"resizable","get"),b=o(g,"maxByteLength","get"),S=i(y.getInt8),w=i(y.setInt8);t.exports=(l||c)&&function(t,e,r){var n,i=u(t),o=void 0===e?i:a(e),g=!_||!_(t);if(s(t))throw new d("ArrayBuffer is detached");if(l&&(t=f(t,{transfer:[t]}),i===o&&(r||g)))return t;if(i>=o&&(!r||g))n=m(t,0,o);else{var y=r&&!g&&b?{maxByteLength:b(t)}:void 0;n=new p(o,y);for(var x=new h(t),E=new h(n),O=v(o,i),C=0;C{"use strict";var n,i,o,a=r(47146),s=r(67697),u=r(19037),c=r(69985),l=r(48999),f=r(36812),p=r(50926),h=r(23691),d=r(75773),v=r(11880),g=r(62148),y=r(23622),m=r(61868),_=r(49385),b=r(44201),S=r(14630),w=r(618),x=w.enforce,E=w.get,O=u.Int8Array,C=O&&O.prototype,k=u.Uint8ClampedArray,D=k&&k.prototype,M=O&&m(O),I=C&&m(C),A=Object.prototype,R=u.TypeError,T=b("toStringTag"),z=S("TYPED_ARRAY_TAG"),B="TypedArrayConstructor",q=a&&!!_&&"Opera"!==p(u.opera),P=!1,j={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},L={BigInt64Array:8,BigUint64Array:8},K=function(t){var e=m(t);if(l(e)){var r=E(e);return r&&f(r,B)?r[B]:K(e)}},N=function(t){if(!l(t))return!1;var e=p(t);return f(j,e)||f(L,e)};for(n in j)(o=(i=u[n])&&i.prototype)?x(o)[B]=i:q=!1;for(n in L)(o=(i=u[n])&&i.prototype)&&(x(o)[B]=i);if((!q||!c(M)||M===Function.prototype)&&(M=function TypedArray(){throw new R("Incorrect invocation")},q))for(n in j)u[n]&&_(u[n],M);if((!q||!I||I===A)&&(I=M.prototype,q))for(n in j)u[n]&&_(u[n].prototype,I);if(q&&m(D)!==I&&_(D,I),s&&!f(I,T))for(n in P=!0,g(I,T,{configurable:!0,get:function(){return l(this)?this[z]:void 0}}),j)u[n]&&d(u[n],z,n);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:q,TYPED_ARRAY_TAG:P&&z,aTypedArray:function(t){if(N(t))return t;throw new R("Target is not a typed array")},aTypedArrayConstructor:function(t){if(c(t)&&(!_||y(M,t)))return t;throw new R(h(t)+" is not a typed array constructor")},exportTypedArrayMethod:function(t,e,r,n){if(s){if(r)for(var i in j){var o=u[i];if(o&&f(o.prototype,t))try{delete o.prototype[t]}catch(r){try{o.prototype[t]=e}catch(t){}}}I[t]&&!r||v(I,t,r?e:q&&C[t]||e,n)}},exportTypedArrayStaticMethod:function(t,e,r){var n,i;if(s){if(_){if(r)for(n in j)if((i=u[n])&&f(i,t))try{delete i[t]}catch(t){}if(M[t]&&!r)return;try{return v(M,t,r?e:q&&M[t]||e)}catch(t){}}for(n in j)!(i=u[n])||i[t]&&!r||v(i,t,e)}},getTypedArrayConstructor:K,isView:function(t){if(!l(t))return!1;var e=p(t);return"DataView"===e||f(j,e)||f(L,e)},isTypedArray:N,TypedArray:M,TypedArrayPrototype:I}},61969:(t,e,r)=>{"use strict";var n=r(54071),i=r(94413),o=r(90690),a=r(6310),s=function(t){var e=1===t;return function(r,s,u){for(var c,l=o(r),f=i(l),p=n(s,u),h=a(f);h-- >0;)if(p(c=f[h],h,l))switch(t){case 0:return c;case 1:return h}return e?-1:void 0}};t.exports={findLast:s(0),findLastIndex:s(1)}},26166:(t,e,r)=>{"use strict";var n=r(6310);t.exports=function(t,e){for(var r=n(t),i=new e(r),o=0;o{"use strict";var n=r(6310),i=r(68700),o=RangeError;t.exports=function(t,e,r,a){var s=n(t),u=i(r),c=u<0?s+u:u;if(c>=s||c<0)throw new o("Incorrect index");for(var l=new e(s),f=0;f{"use strict";var n=r(23691),i=TypeError;t.exports=function(t,e){if(!delete t[e])throw new i("Cannot delete property "+n(e)+" of "+n(t))}},21420:(t,e,r)=>{"use strict";var n,i,o,a,s=r(19037),u=r(21905),c=r(63514),l=s.structuredClone,f=s.ArrayBuffer,p=s.MessageChannel,h=!1;if(c)h=function(t){l(t,{transfer:[t]})};else if(f)try{p||(n=u("worker_threads"))&&(p=n.MessageChannel),p&&(i=new p,o=new f(2),a=function(t){i.port1.postMessage(null,[t])},2===o.byteLength&&(a(o),0===o.byteLength&&(h=a)))}catch(t){}t.exports=h},37136:t=>{"use strict";t.exports={IndexSizeError:{s:"INDEX_SIZE_ERR",c:1,m:1},DOMStringSizeError:{s:"DOMSTRING_SIZE_ERR",c:2,m:0},HierarchyRequestError:{s:"HIERARCHY_REQUEST_ERR",c:3,m:1},WrongDocumentError:{s:"WRONG_DOCUMENT_ERR",c:4,m:1},InvalidCharacterError:{s:"INVALID_CHARACTER_ERR",c:5,m:1},NoDataAllowedError:{s:"NO_DATA_ALLOWED_ERR",c:6,m:0},NoModificationAllowedError:{s:"NO_MODIFICATION_ALLOWED_ERR",c:7,m:1},NotFoundError:{s:"NOT_FOUND_ERR",c:8,m:1},NotSupportedError:{s:"NOT_SUPPORTED_ERR",c:9,m:1},InUseAttributeError:{s:"INUSE_ATTRIBUTE_ERR",c:10,m:1},InvalidStateError:{s:"INVALID_STATE_ERR",c:11,m:1},SyntaxError:{s:"SYNTAX_ERR",c:12,m:1},InvalidModificationError:{s:"INVALID_MODIFICATION_ERR",c:13,m:1},NamespaceError:{s:"NAMESPACE_ERR",c:14,m:1},InvalidAccessError:{s:"INVALID_ACCESS_ERR",c:15,m:1},ValidationError:{s:"VALIDATION_ERR",c:16,m:0},TypeMismatchError:{s:"TYPE_MISMATCH_ERR",c:17,m:1},SecurityError:{s:"SECURITY_ERR",c:18,m:1},NetworkError:{s:"NETWORK_ERR",c:19,m:1},AbortError:{s:"ABORT_ERR",c:20,m:1},URLMismatchError:{s:"URL_MISMATCH_ERR",c:21,m:1},QuotaExceededError:{s:"QUOTA_EXCEEDED_ERR",c:22,m:1},TimeoutError:{s:"TIMEOUT_ERR",c:23,m:1},InvalidNodeTypeError:{s:"INVALID_NODE_TYPE_ERR",c:24,m:1},DataCloneError:{s:"DATA_CLONE_ERR",c:25,m:1}}},72532:(t,e,r)=>{"use strict";var n=r(88563),i=r(50806);t.exports=!n&&!i&&"object"==typeof window&&"object"==typeof document},88563:t=>{"use strict";t.exports="object"==typeof Deno&&Deno&&"object"==typeof Deno.version},50806:(t,e,r)=>{"use strict";var n=r(19037),i=r(6648);t.exports="process"===i(n.process)},56610:(t,e,r)=>{"use strict";var n=r(68844),i=Error,o=n("".replace),a=String(new i("zxcasd").stack),s=/\n\s*at [^:]*:[^\n]*/,u=s.test(a);t.exports=function(t,e){if(u&&"string"==typeof t&&!i.prepareStackTrace)for(;e--;)t=o(t,s,"");return t}},49599:(t,e,r)=>{"use strict";var n=r(3689),i=r(75684);t.exports=!n((function(){var t=new Error("a");return!("stack"in t)||(Object.defineProperty(t,"stack",i(1,7)),7!==t.stack)}))},33457:(t,e,r)=>{"use strict";var n=r(69985),i=r(48999),o=r(49385);t.exports=function(t,e,r){var a,s;return o&&n(a=e.constructor)&&a!==r&&i(s=a.prototype)&&s!==r.prototype&&o(t,s),t}},9401:(t,e,r)=>{"use strict";var n=r(50926);t.exports=function(t){var e=n(t);return"BigInt64Array"===e||"BigUint64Array"===e}},19429:(t,e,r)=>{"use strict";var n=r(68844),i=r(3689),o=r(69985),a=r(50926),s=r(76058),u=r(6738),c=function(){},l=[],f=s("Reflect","construct"),p=/^\s*(?:class|function)\b/,h=n(p.exec),d=!p.test(c),v=function(t){if(!o(t))return!1;try{return f(c,l,t),!0}catch(t){return!1}},g=function(t){if(!o(t))return!1;switch(a(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return d||!!h(p,u(t))}catch(t){return!0}};g.sham=!0,t.exports=!f||i((function(){var t;return v(v.call)||!v(Object)||!v((function(){t=!0}))||t}))?g:v},83914:(t,e,r)=>{"use strict";var n=r(68844),i=Map.prototype;t.exports={Map,set:n(i.set),get:n(i.get),has:n(i.has),remove:n(i.delete),proto:i}},13841:(t,e,r)=>{"use strict";var n=r(34327);t.exports=function(t,e){return void 0===t?arguments.length<2?"":e:n(t)}},49385:(t,e,r)=>{"use strict";var n=r(52743),i=r(85027),o=r(23550);t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,r={};try{(t=n(Object.prototype,"__proto__","set"))(r,[]),e=r instanceof Array}catch(t){}return function(r,n){return i(r),o(n),e?t(r,n):r.__proto__=n,r}}():void 0)},69633:(t,e,r)=>{"use strict";var n=r(85027);t.exports=function(){var t=n(this),e="";return t.hasIndices&&(e+="d"),t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.unicodeSets&&(e+="v"),t.sticky&&(e+="y"),e}},63477:(t,e,r)=>{"use strict";var n=r(22615),i=r(36812),o=r(23622),a=r(69633),s=RegExp.prototype;t.exports=function(t){var e=t.flags;return void 0!==e||"flags"in s||i(t,"flags")||!o(s,t)?e:n(a,t)}},63514:(t,e,r)=>{"use strict";var n=r(19037),i=r(3689),o=r(3615),a=r(72532),s=r(88563),u=r(50806),c=n.structuredClone;t.exports=!!c&&!i((function(){if(s&&o>92||u&&o>94||a&&o>97)return!1;var t=new ArrayBuffer(8),e=c(t,{transfer:[t]});return 0!==t.byteLength||8!==e.byteLength}))},71530:(t,e,r)=>{"use strict";var n=r(88732),i=TypeError;t.exports=function(t){var e=n(t,"number");if("number"==typeof e)throw new i("Can't convert number to bigint");return BigInt(e)}},19842:(t,e,r)=>{"use strict";var n=r(68700),i=r(43126),o=RangeError;t.exports=function(t){if(void 0===t)return 0;var e=n(t),r=i(e);if(e!==r)throw new o("Wrong length or index");return r}},21905:(t,e,r)=>{"use strict";var n=r(50806);t.exports=function(t){try{if(n)return Function('return require("'+t+'")')()}catch(t){}}},92176:(t,e,r)=>{"use strict";var n=r(79989),i=r(90690),o=r(6310),a=r(68700),s=r(87370);n({target:"Array",proto:!0},{at:function(t){var e=i(this),r=o(e),n=a(t),s=n>=0?n:r+n;return s<0||s>=r?void 0:e[s]}}),s("at")},93383:(t,e,r)=>{"use strict";var n=r(79989),i=r(61969).findLastIndex,o=r(87370);n({target:"Array",proto:!0},{findLastIndex:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o("findLastIndex")},91719:(t,e,r)=>{"use strict";var n=r(79989),i=r(90690),o=r(6310),a=r(5649),s=r(98494),u=r(55565);n({target:"Array",proto:!0,arity:1,forced:1!==[].unshift(0)||!function(){try{Object.defineProperty([],"length",{writable:!1}).unshift()}catch(t){return t instanceof TypeError}}()},{unshift:function(t){var e=i(this),r=o(e),n=arguments.length;if(n){u(r+n);for(var c=r;c--;){var l=c+n;c in e?e[l]=e[c]:s(e,l)}for(var f=0;f{"use strict";var n=r(79989),i=r(68844),o=r(74684),a=r(68700),s=r(34327),u=r(3689),c=i("".charAt);n({target:"String",proto:!0,forced:u((function(){return"\ud842"!=="𠮷".at(-2)}))},{at:function(t){var e=s(o(this)),r=e.length,n=a(t),i=n>=0?n:r+n;return i<0||i>=r?void 0:c(e,i)}})},95194:(t,e,r)=>{"use strict";var n=r(54872),i=r(6310),o=r(68700),a=n.aTypedArray;(0,n.exportTypedArrayMethod)("at",(function(t){var e=a(this),r=i(e),n=o(t),s=n>=0?n:r+n;return s<0||s>=r?void 0:e[s]}))},82:(t,e,r)=>{"use strict";var n=r(54872),i=r(61969).findLastIndex,o=n.aTypedArray;(0,n.exportTypedArrayMethod)("findLastIndex",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},20522:(t,e,r)=>{"use strict";var n=r(54872),i=r(61969).findLast,o=n.aTypedArray;(0,n.exportTypedArrayMethod)("findLast",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},24224:(t,e,r)=>{"use strict";var n=r(26166),i=r(54872),o=i.aTypedArray,a=i.exportTypedArrayMethod,s=i.getTypedArrayConstructor;a("toReversed",(function(){return n(o(this),s(this))}))},61121:(t,e,r)=>{"use strict";var n=r(54872),i=r(68844),o=r(10509),a=r(59976),s=n.aTypedArray,u=n.getTypedArrayConstructor,c=n.exportTypedArrayMethod,l=i(n.TypedArrayPrototype.sort);c("toSorted",(function(t){void 0!==t&&o(t);var e=s(this),r=a(u(e),e);return l(r,t)}))},37133:(t,e,r)=>{"use strict";var n=r(16134),i=r(54872),o=r(9401),a=r(68700),s=r(71530),u=i.aTypedArray,c=i.getTypedArrayConstructor,l=i.exportTypedArrayMethod,f=!!function(){try{new Int8Array(1).with(2,{valueOf:function(){throw 8}})}catch(t){return 8===t}}();l("with",{with:function(t,e){var r=u(this),i=a(t),l=o(r)?s(e):+e;return n(r,c(r),i,l)}}.with,!f)},86247:(t,e,r)=>{"use strict";var n=r(67697),i=r(62148),o=r(22961),a=ArrayBuffer.prototype;n&&!("detached"in a)&&i(a,"detached",{configurable:!0,get:function(){return o(this)}})},43097:(t,e,r)=>{"use strict";var n=r(79989),i=r(29195);i&&n({target:"ArrayBuffer",proto:!0},{transferToFixedLength:function(){return i(this,arguments.length?arguments[0]:void 0,!1)}})},21412:(t,e,r)=>{"use strict";var n=r(79989),i=r(29195);i&&n({target:"ArrayBuffer",proto:!0},{transfer:function(){return i(this,arguments.length?arguments[0]:void 0,!0)}})},58429:(t,e,r)=>{"use strict";var n=r(79989),i=r(85027),o=r(18734),a=r(22302),s=[].push;n({target:"Iterator",proto:!0,real:!0},{toArray:function(){var t=[];return o(a(i(this)),s,{that:t,IS_RECORD:!0}),t}})},13429:(t,e,r)=>{"use strict";var n=r(79989),i=r(19037),o=r(76058),a=r(75684),s=r(72560).f,u=r(36812),c=r(767),l=r(33457),f=r(13841),p=r(37136),h=r(56610),d=r(67697),v=r(53931),g="DOMException",y=o("Error"),m=o(g),_=function DOMException(){c(this,b);var t=arguments.length,e=f(t<1?void 0:arguments[0]),r=f(t<2?void 0:arguments[1],"Error"),n=new m(e,r),i=new y(e);return i.name=g,s(n,"stack",a(1,h(i.stack,1))),l(n,this,_),n},b=_.prototype=m.prototype,S="stack"in new y(g),w="stack"in new m(1,2),x=m&&d&&Object.getOwnPropertyDescriptor(i,g),E=!(!x||x.writable&&x.configurable),O=S&&!E&&!w;n({global:!0,constructor:!0,forced:v||O},{DOMException:O?_:m});var C=o(g),k=C.prototype;if(k.constructor!==C)for(var D in v||s(k,"constructor",a(1,C)),p)if(u(p,D)){var M=p[D],I=M.s;u(C,I)||s(C,I,a(6,M.c))}},25564:(t,e,r)=>{"use strict";var n,i=r(53931),o=r(79989),a=r(19037),s=r(76058),u=r(68844),c=r(3689),l=r(14630),f=r(69985),p=r(19429),h=r(981),d=r(48999),v=r(30734),g=r(18734),y=r(85027),m=r(50926),_=r(36812),b=r(76522),S=r(75773),w=r(6310),x=r(21500),E=r(63477),O=r(83914),C=r(61034),k=r(48774),D=r(21420),M=r(49599),I=r(63514),A=a.Object,R=a.Array,T=a.Date,z=a.Error,B=a.TypeError,q=a.PerformanceMark,P=s("DOMException"),j=O.Map,L=O.has,K=O.get,N=O.set,F=C.Set,U=C.add,G=C.has,H=s("Object","keys"),W=u([].push),V=u((!0).valueOf),Y=u(1..valueOf),X=u("".valueOf),$=u(T.prototype.getTime),J=l("structuredClone"),Z="DataCloneError",Q="Transferring",tt=function(t){return!c((function(){var e=new a.Set([7]),r=t(e),n=t(A(7));return r===e||!r.has(7)||!d(n)||7!=+n}))&&t},et=function(t,e){return!c((function(){var r=new e,n=t({a:r,b:r});return!(n&&n.a===n.b&&n.a instanceof e&&n.a.stack===r.stack)}))},rt=a.structuredClone,nt=i||!et(rt,z)||!et(rt,P)||(n=rt,!!c((function(){var t=n(new a.AggregateError([1],J,{cause:3}));return"AggregateError"!==t.name||1!==t.errors[0]||t.message!==J||3!==t.cause}))),it=!rt&&tt((function(t){return new q(J,{detail:t}).detail})),ot=tt(rt)||it,at=function(t){throw new P("Uncloneable type: "+t,Z)},st=function(t,e){throw new P((e||"Cloning")+" of "+t+" cannot be properly polyfilled in this engine",Z)},ut=function(t,e){return ot||st(e),ot(t)},ct=function(t,e,r){if(L(e,t))return K(e,t);var n,i,o,s,u,c;if("SharedArrayBuffer"===(r||m(t)))n=ot?ot(t):t;else{var l=a.DataView;l||f(t.slice)||st("ArrayBuffer");try{if(f(t.slice)&&!t.resizable)n=t.slice(0);else{i=t.byteLength,o="maxByteLength"in t?{maxByteLength:t.maxByteLength}:void 0,n=new ArrayBuffer(i,o),s=new l(t),u=new l(n);for(c=0;c1&&!h(arguments[1])?y(arguments[1]):void 0,i=n?n.transfer:void 0;void 0!==i&&(r=function(t,e){if(!d(t))throw new B("Transfer option cannot be converted to a sequence");var r=[];g(t,(function(t){W(r,y(t))}));for(var n,i,o,s,u,c=0,l=w(r),h=new F;c{"use strict";r.d(e,{useVirtual:()=>g});var n=r(67294);function i(){return i=Object.assign||function(t){for(var e=1;e=0&&r.callbacks.splice(n,1),r.callbacks.length||s.delete(t),s.size||cancelAnimationFrame(o)}}});return r.observe(),function(){r.unobserve()}}}),[i]),p}function f(t,e){var r=e.rect;return t.height!==r.height||t.width!==r.width?r:t}var p=function(){return 50},h=function(t){return t},d=function(t,e){return t[e?"offsetWidth":"offsetHeight"]},v=function(t){for(var e=Math.max(t.start-t.overscan,0),r=Math.min(t.end+t.overscan,t.size-1),n=[],i=e;i<=r;i++)n.push(i);return n};function g(t){var e,r=t.size,o=void 0===r?0:r,a=t.estimateSize,s=void 0===a?p:a,u=t.overscan,f=void 0===u?1:u,g=t.paddingStart,m=void 0===g?0:g,_=t.paddingEnd,b=void 0===_?0:_,S=t.parentRef,w=t.horizontal,x=t.scrollToFn,E=t.useObserver,O=t.initialRect,C=t.onScrollElement,k=t.scrollOffsetFn,D=t.keyExtractor,M=void 0===D?h:D,I=t.measureSize,A=void 0===I?d:I,R=t.rangeExtractor,T=void 0===R?v:R,z=w?"width":"height",B=w?"scrollLeft":"scrollTop",q=n.useRef({scrollOffset:0,measurements:[]}),P=n.useState(0),j=P[0],L=P[1];q.current.scrollOffset=j;var K=(E||l)(S,O)[z];q.current.outerSize=K;var N=n.useCallback((function(t){S.current&&(S.current[B]=t)}),[S,B]),F=x||N;x=n.useCallback((function(t){F(t,N)}),[N,F]);var U=n.useState({}),G=U[0],H=U[1],W=n.useCallback((function(){return H({})}),[]),V=n.useRef([]),Y=n.useMemo((function(){var t=V.current.length>0?Math.min.apply(Math,V.current):0;V.current=[];for(var e=q.current.measurements.slice(0,t),r=t;r=o+a?"end":"start"),"start"===n?x(t):"end"===n?x(t-a):"center"===n&&x(t-a/2)}),[x]),at=n.useCallback((function(t,e){var r=void 0===e?{}:e,n=r.align,a=void 0===n?"auto":n,s=function(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;n=0||(i[r]=t[r]);return i}(r,["align"]),u=q.current,c=u.measurements,l=u.scrollOffset,f=u.outerSize,p=c[Math.max(0,Math.min(t,o-1))];if(p){if("auto"===a)if(p.end>=l+f)a="end";else{if(!(p.start<=l))return;a="start"}var h="center"===a?p.start+p.size/2:"end"===a?p.end:p.start;ot(h,i({align:a},s))}}),[ot,o]),st=n.useCallback((function(){for(var t=arguments.length,e=new Array(t),r=0;rn))return i;e=i-1}}return t>0?t-1:0}},8718:(t,e,r)=>{"use strict";r.d(e,{current:()=>U,produce:()=>W});var n=Symbol.for("immer-nothing"),i=Symbol.for("immer-draftable"),o=Symbol.for("immer-state");function a(t,...e){throw new Error(`[Immer] minified error nr: ${t}. Full error at: https://bit.ly/3cXEKWf`)}var s=Object.getPrototypeOf;function u(t){return!!t&&!!t[o]}function c(t){return!!t&&(f(t)||Array.isArray(t)||!!t[i]||!!t.constructor?.[i]||g(t)||y(t))}var l=Object.prototype.constructor.toString();function f(t){if(!t||"object"!=typeof t)return!1;const e=s(t);if(null===e)return!0;const r=Object.hasOwnProperty.call(e,"constructor")&&e.constructor;return r===Object||"function"==typeof r&&Function.toString.call(r)===l}function p(t,e){0===h(t)?Object.entries(t).forEach((([r,n])=>{e(r,n,t)})):t.forEach(((r,n)=>e(n,r,t)))}function h(t){const e=t[o];return e?e.type_:Array.isArray(t)?1:g(t)?2:y(t)?3:0}function d(t,e){return 2===h(t)?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function v(t,e,r){const n=h(t);2===n?t.set(e,r):3===n?t.add(r):t[e]=r}function g(t){return t instanceof Map}function y(t){return t instanceof Set}function m(t){return t.copy_||t.base_}function _(t,e){if(g(t))return new Map(t);if(y(t))return new Set(t);if(Array.isArray(t))return Array.prototype.slice.call(t);if(!e&&f(t)){if(!s(t)){const e=Object.create(null);return Object.assign(e,t)}return{...t}}const r=Object.getOwnPropertyDescriptors(t);delete r[o];let n=Reflect.ownKeys(r);for(let e=0;e1&&(t.set=t.add=t.clear=t.delete=S),Object.freeze(t),e&&p(t,((t,e)=>b(e,!0)))),t}function S(){a(2)}function w(t){return Object.isFrozen(t)}var x,E={};function O(t){const e=E[t];return e||a(0),e}function C(){return x}function k(t,e){e&&(O("Patches"),t.patches_=[],t.inversePatches_=[],t.patchListener_=e)}function D(t){M(t),t.drafts_.forEach(A),t.drafts_=null}function M(t){t===x&&(x=t.parent_)}function I(t){return x={drafts_:[],parent_:x,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function A(t){const e=t[o];0===e.type_||1===e.type_?e.revoke_():e.revoked_=!0}function R(t,e){e.unfinalizedDrafts_=e.drafts_.length;const r=e.drafts_[0];return void 0!==t&&t!==r?(r[o].modified_&&(D(e),a(4)),c(t)&&(t=T(e,t),e.parent_||B(e,t)),e.patches_&&O("Patches").generateReplacementPatches_(r[o].base_,t,e.patches_,e.inversePatches_)):t=T(e,r,[]),D(e),e.patches_&&e.patchListener_(e.patches_,e.inversePatches_),t!==n?t:void 0}function T(t,e,r){if(w(e))return e;const n=e[o];if(!n)return p(e,((i,o)=>z(t,n,e,i,o,r))),e;if(n.scope_!==t)return e;if(!n.modified_)return B(t,n.base_,!0),n.base_;if(!n.finalized_){n.finalized_=!0,n.scope_.unfinalizedDrafts_--;const e=n.copy_;let i=e,o=!1;3===n.type_&&(i=new Set(e),e.clear(),o=!0),p(i,((i,a)=>z(t,n,e,i,a,r,o))),B(t,e,!1),r&&t.patches_&&O("Patches").generatePatches_(n,r,t.patches_,t.inversePatches_)}return n.copy_}function z(t,e,r,n,i,o,a){if(u(i)){const a=T(t,i,o&&e&&3!==e.type_&&!d(e.assigned_,n)?o.concat(n):void 0);if(v(r,n,a),!u(a))return;t.canAutoFreeze_=!1}else a&&r.add(i);if(c(i)&&!w(i)){if(!t.immer_.autoFreeze_&&t.unfinalizedDrafts_<1)return;T(t,i),e&&e.scope_.parent_||B(t,i)}}function B(t,e,r=!1){!t.parent_&&t.immer_.autoFreeze_&&t.canAutoFreeze_&&b(e,r)}var q={get(t,e){if(e===o)return t;const r=m(t);if(!d(r,e))return function(t,e,r){const n=L(e,r);return n?"value"in n?n.value:n.get?.call(t.draft_):void 0}(t,r,e);const n=r[e];return t.finalized_||!c(n)?n:n===j(t.base_,e)?(N(t),t.copy_[e]=F(n,t)):n},has:(t,e)=>e in m(t),ownKeys:t=>Reflect.ownKeys(m(t)),set(t,e,r){const n=L(m(t),e);if(n?.set)return n.set.call(t.draft_,r),!0;if(!t.modified_){const n=j(m(t),e),s=n?.[o];if(s&&s.base_===r)return t.copy_[e]=r,t.assigned_[e]=!1,!0;if(((i=r)===(a=n)?0!==i||1/i==1/a:i!=i&&a!=a)&&(void 0!==r||d(t.base_,e)))return!0;N(t),K(t)}var i,a;return t.copy_[e]===r&&(void 0!==r||e in t.copy_)||Number.isNaN(r)&&Number.isNaN(t.copy_[e])||(t.copy_[e]=r,t.assigned_[e]=!0),!0},deleteProperty:(t,e)=>(void 0!==j(t.base_,e)||e in t.base_?(t.assigned_[e]=!1,N(t),K(t)):delete t.assigned_[e],t.copy_&&delete t.copy_[e],!0),getOwnPropertyDescriptor(t,e){const r=m(t),n=Reflect.getOwnPropertyDescriptor(r,e);return n?{writable:!0,configurable:1!==t.type_||"length"!==e,enumerable:n.enumerable,value:r[e]}:n},defineProperty(){a(11)},getPrototypeOf:t=>s(t.base_),setPrototypeOf(){a(12)}},P={};function j(t,e){const r=t[o];return(r?m(r):t)[e]}function L(t,e){if(!(e in t))return;let r=s(t);for(;r;){const t=Object.getOwnPropertyDescriptor(r,e);if(t)return t;r=s(r)}}function K(t){t.modified_||(t.modified_=!0,t.parent_&&K(t.parent_))}function N(t){t.copy_||(t.copy_=_(t.base_,t.scope_.immer_.useStrictShallowCopy_))}p(q,((t,e)=>{P[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}})),P.deleteProperty=function(t,e){return P.set.call(this,t,e,void 0)},P.set=function(t,e,r){return q.set.call(this,t[0],e,r,t[0])};function F(t,e){const r=g(t)?O("MapSet").proxyMap_(t,e):y(t)?O("MapSet").proxySet_(t,e):function(t,e){const r=Array.isArray(t),n={type_:r?1:0,scope_:e?e.scope_:C(),modified_:!1,finalized_:!1,assigned_:{},parent_:e,base_:t,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=n,o=q;r&&(i=[n],o=P);const{revoke:a,proxy:s}=Proxy.revocable(i,o);return n.draft_=s,n.revoke_=a,s}(t,e);return(e?e.scope_:C()).drafts_.push(r),r}function U(t){return u(t)||a(10),G(t)}function G(t){if(!c(t)||w(t))return t;const e=t[o];let r;if(e){if(!e.modified_)return e.base_;e.finalized_=!0,r=_(t,e.scope_.immer_.useStrictShallowCopy_)}else r=_(t,!0);return p(r,((t,e)=>{v(r,t,G(e))})),e&&(e.finalized_=!1),r}var H=new class{constructor(t){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,e,r)=>{if("function"==typeof t&&"function"!=typeof e){const r=e;e=t;const n=this;return function(t=r,...i){return n.produce(t,(t=>e.call(this,t,...i)))}}let i;if("function"!=typeof e&&a(6),void 0!==r&&"function"!=typeof r&&a(7),c(t)){const n=I(this),o=F(t,void 0);let a=!0;try{i=e(o),a=!1}finally{a?D(n):M(n)}return k(n,r),R(i,n)}if(!t||"object"!=typeof t){if(i=e(t),void 0===i&&(i=t),i===n&&(i=void 0),this.autoFreeze_&&b(i,!0),r){const e=[],n=[];O("Patches").generateReplacementPatches_(t,i,e,n),r(e,n)}return i}a(1)},this.produceWithPatches=(t,e)=>{if("function"==typeof t)return(e,...r)=>this.produceWithPatches(e,(e=>t(e,...r)));let r,n;return[this.produce(t,e,((t,e)=>{r=t,n=e})),r,n]},"boolean"==typeof t?.autoFreeze&&this.setAutoFreeze(t.autoFreeze),"boolean"==typeof t?.useStrictShallowCopy&&this.setUseStrictShallowCopy(t.useStrictShallowCopy)}createDraft(t){c(t)||a(8),u(t)&&(t=U(t));const e=I(this),r=F(t,void 0);return r[o].isManual_=!0,M(e),r}finishDraft(t,e){const r=t&&t[o];r&&r.isManual_||a(9);const{scope_:n}=r;return k(n,e),R(void 0,n)}setAutoFreeze(t){this.autoFreeze_=t}setUseStrictShallowCopy(t){this.useStrictShallowCopy_=t}applyPatches(t,e){let r;for(r=e.length-1;r>=0;r--){const n=e[r];if(0===n.path.length&&"replace"===n.op){t=n.value;break}}r>-1&&(e=e.slice(r+1));const n=O("Patches").applyPatches_;return u(t)?n(t,e):this.produce(t,(t=>n(t,e)))}},W=H.produce;H.produceWithPatches.bind(H),H.setAutoFreeze.bind(H),H.setUseStrictShallowCopy.bind(H),H.applyPatches.bind(H),H.createDraft.bind(H),H.finishDraft.bind(H)}}]);