openc3-cosmos-tool-bucketexplorer 6.9.1 → 6.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/tools/bucketexplorer/ArrayWidget-C59wpWWk-c29b423ae0d8262b2f0a.js +2 -0
- data/tools/bucketexplorer/{ArrayplotWidget-CoRsUxHG-69aff0ec99abb0cfb89c.js → ArrayplotWidget-tKqIV461-b5499d34d939770ea784.js} +1 -1
- data/tools/bucketexplorer/{BarColumn-DHP-zQ4R-e506a6473165264550cb.js → BarColumn-CUO9ur6W-86ab3fa1dcc50ce2447e.js} +1 -1
- data/tools/bucketexplorer/{BlockWidget-BmHSFvOq-37d0b4524b3e0502f054.js → BlockWidget-BdlMR_1A-2fe67a604620baf681bb.js} +2 -2
- data/tools/bucketexplorer/BucketExplorer-d47f020ec811df931ab8.js +1506 -0
- data/tools/bucketexplorer/{ButtonWidget-C3ZWRjZZ-1b84bd302121903ced21.js → ButtonWidget-C2JVmh3p-3a560b6aa04088e4573c.js} +2 -2
- data/tools/bucketexplorer/{CanvasWidget-CL-XzPF4-fa1079a0fb1aa90e7667.js → CanvasWidget-BRbdw1fu-4ba8bfc99930cac644a9.js} +1 -1
- data/tools/bucketexplorer/CanvasdotWidget-C8T_w03p-fd7ef4459bf342fc37fa.js +1 -0
- data/tools/bucketexplorer/{CanvasimageWidget-DHSGK_tD-e636224e09d62e89562e.js → CanvasimageWidget-C1w2vSsG-4c0415ae1f856627e881.js} +1 -1
- data/tools/bucketexplorer/{CanvasimagevalueWidget-Btt_fQfC-691f4c4362434686a095.js → CanvasimagevalueWidget-BMv2SmEq-1708540633c2cf544f63.js} +1 -1
- data/tools/bucketexplorer/{CanvaslabelWidget-BF_8RTjv-7d4318e6543a67674bfb.js → CanvaslabelWidget-LEBZQ3DR-13febb8d925636c6b249.js} +1 -1
- data/tools/bucketexplorer/{CanvaslabelvalueWidget-scbwaujI-9f951c75ecb3e7816c10.js → CanvaslabelvalueWidget-Q6UdEanF-f775a32e761f967dd6fd.js} +1 -1
- data/tools/bucketexplorer/{CanvaslineWidget-gRvm_-TT-82e4bf6e84b66c2a0a5d.js → CanvaslineWidget-BhvBCDoS-e7c8904fc932aca8f668.js} +1 -1
- data/tools/bucketexplorer/{CanvaslinevalueWidget-CljziRek-7df5eb7e9906ae379f85.js → CanvaslinevalueWidget-EaASC9TU-e4374af5ec39128028f5.js} +1 -1
- data/tools/bucketexplorer/CheckbuttonWidget-C3bjQwrp-2d8036a8c21d34f2abeb.js +1 -0
- data/tools/bucketexplorer/ComboboxWidget-CmruSbJy-f4cf90673018861cf481.js +1 -0
- data/tools/bucketexplorer/{DateWidget-BTqLCtLS-329773e8eab7a51fc2be.js → DateWidget-CcUxRlJ2-8cce8aebe5541d7f0e90.js} +1 -1
- data/tools/bucketexplorer/{DetailsDialog-BNCS3QAe-88b8558745b2a4487712.js → DetailsDialog-DxYZre4A-dd3f920be5c6e413a8f1.js} +1 -1
- data/tools/bucketexplorer/{DynamicWidget-CfMtj7H8-b39395d11f5b0ac3c788.js → DynamicWidget-DHL7pbgW-440606a95b21f754bf6e.js} +1 -1
- data/tools/bucketexplorer/{FormatvalueWidget-CLYx8qbg-d2e2d8f2ad31549a7c99.js → FormatvalueWidget-Lk5K0wTL-db7245b0435a2517ab47.js} +1 -1
- data/tools/bucketexplorer/Graph-CjEE2WxX-c0e7941078b06d7759c8.js +1 -0
- data/tools/bucketexplorer/{GraphWidget-Cb6Ozf54-d599377c4ab0c4ac7c08.js → GraphWidget-BaO2FpKo-4d1a473e6a51fa54ee37.js} +1 -1
- data/tools/bucketexplorer/{HorizontalWidget-AY2M01qP-54337c6057536b2fbf9f.js → HorizontalWidget-D3Q5IUQg-420b839020884c7c7e07.js} +1 -1
- data/tools/bucketexplorer/{HorizontalboxWidget-2MEKvq_C-c596b1c23358ff8e9ab1.js → HorizontalboxWidget-D7bUUqfG-8741d3deca1aed1b4431.js} +1 -1
- data/tools/bucketexplorer/HorizontallineWidget-DZcIetQh-60fb1bda60b18d799e32.js +1 -0
- data/tools/bucketexplorer/{IframeWidget-UKKUl7k5-c86b3b96984c22a11d07.js → IframeWidget-Df7vTYZj-6c22de0cd801300c4f14.js} +1 -1
- data/tools/bucketexplorer/{ImageLoader-C-CIL4YD-2685eda412550901a0aa.js → ImageLoader-DpKY46fX-9de5e271333e34b94db5.js} +1 -1
- data/tools/bucketexplorer/{ImageviewerWidget-DhuQH5Io-59da4ecb7c8510629978.js → ImageviewerWidget-wHbhv08x-9650a0f5e234dc516aa0.js} +1 -1
- data/tools/bucketexplorer/{LabelWidget-SO9zqcNN-38e54a0a3a02bc308a87.js → LabelWidget-BehwzOCR-26c050fdc9bbd572445f.js} +1 -1
- data/tools/bucketexplorer/LabelledWidget-DJKR8ikj-443ee356d5da714cdca2.js +1 -0
- data/tools/bucketexplorer/LabelprogressbarWidget-D4Qzq894-728880b742e5832d041e.js +1 -0
- data/tools/bucketexplorer/LabelsparklineWidget-CwCOklZG-749b8d00a4735f6670be.js +1 -0
- data/tools/bucketexplorer/LabelvalueWidget-DW8Q7BTX-a2e934f71c772a24a39f.js +1 -0
- data/tools/bucketexplorer/{LabelvaluedescWidget-CxfL-H9C-3df05fff707099126f61.js → LabelvaluedescWidget-DgNX7tK2-f0a007238371f0fb5f5b.js} +1 -1
- data/tools/bucketexplorer/{LabelvaluelimitsbarWidget-BT5k9mHv-2f6d994aef7c66cbad34.js → LabelvaluelimitsbarWidget-DAEBW0hU-eda6f35727241e989e29.js} +1 -1
- data/tools/bucketexplorer/LabelvaluelimitscolumnWidget-Dok-of6n-bd66c32eff88c32bd1d3.js +1 -0
- data/tools/bucketexplorer/{LabelvaluerangebarWidget-DexAc2UB-d3d9fb778bddec699de3.js → LabelvaluerangebarWidget-CQ0xCUFU-a5d35da52e8d36d1623f.js} +1 -1
- data/tools/bucketexplorer/{Layout-Dd6dRf3R-61d478321eac32c375ab.js → Layout-CrCMUbtG-c3911102370c1b053a87.js} +1 -1
- data/tools/bucketexplorer/{LedWidget-D1RwHb_V-d4f1daa83e42249c55fc.js → LedWidget-DzQNEDF7-d37d23e6b6929ce92320.js} +1 -1
- data/tools/bucketexplorer/{LimitsbarWidget-ClOmoV50-260f04efe0f16fe75bcd.js → LimitsbarWidget-zkoAz9SQ-1eabbb0af56fc8c00067.js} +1 -1
- data/tools/bucketexplorer/{LimitscolorWidget-CBUoEYKp-4022b425c25e91003b49.js → LimitscolorWidget-dez316Rk-a0a22e420f93800e2a41.js} +1 -1
- data/tools/bucketexplorer/{LimitscolumnWidget-hsHkmY-_-a1055964f40299795e0b.js → LimitscolumnWidget-D-IPNDVg-7736aa68a84a0d3ff9d6.js} +1 -1
- data/tools/bucketexplorer/{LinegraphWidget-CXrKtxOo-737ab187a3b4e925c178.js → LinegraphWidget-CicnZgjt-3af17e3f0ebc4706f047.js} +1 -1
- data/tools/bucketexplorer/{MatrixbycolumnsWidget-CsogVU9c-7b2776b33e5f5505192a.js → MatrixbycolumnsWidget-D3qN6GTr-701b9edde6e2e974b630.js} +1 -1
- data/tools/bucketexplorer/{ProgressbarWidget-CO6CEkxP-963e59066fd77c7c5632.js → ProgressbarWidget-CLilcPBe-bb665936f8d0042abf17.js} +1 -1
- data/tools/bucketexplorer/RadiobuttonWidget-Dsy01RJ--87c221bf986287a5f52e.js +1 -0
- data/tools/bucketexplorer/RadiogroupWidget-BNcVGNj1-f4eda7322a6ab05f613b.js +1 -0
- data/tools/bucketexplorer/{RangebarWidget-5uQTfLMP-86618d6a23b6aa528121.js → RangebarWidget-DhcoIdNf-b7dcc81f5c7d4886e69f.js} +1 -1
- data/tools/bucketexplorer/{RollupWidget-B0DCULnu-8956fce5c9446c38df14.js → RollupWidget-BypuPvE7-18a4f21aea29ec5c964f.js} +1 -1
- data/tools/bucketexplorer/{ScrollwindowWidget-BOkZQgtf-ab233fc96d9604707a1f.js → ScrollwindowWidget-DNQgHoNO-9da5b53e610fdec82a1e.js} +1 -1
- data/tools/bucketexplorer/{SignalWidget-Cis0Xkea-b45d3eaa4e2fb0a83609.js → SignalWidget-BHwyScCG-19f5731f4747778e177e.js} +1 -1
- data/tools/bucketexplorer/SpacerWidget-CFxXXTm7-96909274c687e8c56a97.js +1 -0
- data/tools/bucketexplorer/SparklineWidget-C0lRpRrp-e2aab2e51ee8ed9f2958.js +1 -0
- data/tools/bucketexplorer/{TabbookWidget-uucd-zsX-b7360161bdaa29628149.js → TabbookWidget-CeeBOYOt-2d84863ad653202184a0.js} +1 -1
- data/tools/bucketexplorer/TextboxWidget-DoA2b3YU-601d09a9adfcc39657d8.js +1 -0
- data/tools/bucketexplorer/{TextfieldWidget--HTv9ddk-f27e1bbd68c4f05e149e.js → TextfieldWidget-Dj4DV74o-b7a295018140a8b14709.js} +1 -1
- data/tools/bucketexplorer/{TimeWidget-CPNVZaUM-779adefb852d8be79d14.js → TimeWidget-DAQDQ0UM-d4213c64f9f64c553427.js} +1 -1
- data/tools/bucketexplorer/TitleWidget-Ct0JlY9s-368213abe1d8b7a3440f.js +1 -0
- data/tools/bucketexplorer/{VWidget-DQGJRgAk-6db46d9d23556e521bd1.js → VWidget-A802LGvR-8aaeb7b0a0e99dc59d72.js} +1 -1
- data/tools/bucketexplorer/ValueWidget-QaBYsiZz-809550055fb9541a8d5e.js +1 -0
- data/tools/bucketexplorer/ValuelimitsbarWidget-CFToRM7w-d42ceb8b66bc86d1bc27.js +1 -0
- data/tools/bucketexplorer/{ValuelimitscolumnWidget-BTT90uyX-a86d92b28ab30583d15d.js → ValuelimitscolumnWidget-BG7naMYx-5d5684b1d6f0aa5da261.js} +1 -1
- data/tools/bucketexplorer/ValuerangebarWidget-CChK2Lmm-513caec4b39e8d9fc987.js +1 -0
- data/tools/bucketexplorer/{VerticalWidget-CNtFQv3R-9199310dd1a6b20ac3c0.js → VerticalWidget-C8iN5DJK-1686c13b55184829b8f7.js} +1 -1
- data/tools/bucketexplorer/{VerticalboxWidget-Yxmz1SnU-f69d585f217fc0632b64.js → VerticalboxWidget-CXwUSWrP-727f58426e2529e9a06b.js} +1 -1
- data/tools/bucketexplorer/{Widget-LsyjS7ZS-18fe8d361b119e9432c5.js → Widget-Cx1jBJHK-a30d0f04853e372ad536.js} +1 -1
- data/tools/bucketexplorer/main-0d493b63e559b38d7841.js +9 -0
- data/tools/bucketexplorer/main.js +1 -1
- metadata +68 -68
- data/tools/bucketexplorer/ArrayWidget-DLfNWDzN-6cf597cbb28fca7fb30d.js +0 -2
- data/tools/bucketexplorer/BucketExplorer-d32b853e70b6f16af406.js +0 -1506
- data/tools/bucketexplorer/CanvasdotWidget-D8Y9DgVE-5e34d41998bf6097dba4.js +0 -1
- data/tools/bucketexplorer/CheckbuttonWidget-BOabI_jE-e240f02f8e0f6a7bfcae.js +0 -1
- data/tools/bucketexplorer/ComboboxWidget-BLXNYFiY-524b7e5268016eaba6bf.js +0 -1
- data/tools/bucketexplorer/Graph-BliBYJxD-9da9f1c51691ddabe8b8.js +0 -1
- data/tools/bucketexplorer/HorizontallineWidget-DgpOPA7q-bf28825fdec1dea90e25.js +0 -1
- data/tools/bucketexplorer/LabelledWidget-DWoM5AJ5-c1e11d86f4c2e443ac59.js +0 -1
- data/tools/bucketexplorer/LabelprogressbarWidget-D3vnkvQZ-43934b3362d5d7859560.js +0 -1
- data/tools/bucketexplorer/LabelsparklineWidget-DO0T-Jot-291c5f3a704371c5e5fa.js +0 -1
- data/tools/bucketexplorer/LabelvalueWidget-B6BbNFnk-81a3bab119f07861c678.js +0 -1
- data/tools/bucketexplorer/LabelvaluelimitscolumnWidget-DUbmxh4p-f345a5a4c5b2fe21dd8b.js +0 -1
- data/tools/bucketexplorer/RadiobuttonWidget-DrxUclws-3f0ef791208621909b58.js +0 -1
- data/tools/bucketexplorer/RadiogroupWidget-DN9C38cg-d9ed5aa79c74f9b80108.js +0 -1
- data/tools/bucketexplorer/SpacerWidget-CLcqC2Qk-8a1a47ea7c6c4e346c7d.js +0 -1
- data/tools/bucketexplorer/SparklineWidget-CTp83eZ--63ac582b2c26a7dd8a57.js +0 -1
- data/tools/bucketexplorer/TextboxWidget-C2n38ti5-f5c6b8e22bf05e88fb3c.js +0 -1
- data/tools/bucketexplorer/TitleWidget-Cp0cb6V8-79ad62557619f8484ca9.js +0 -1
- data/tools/bucketexplorer/ValueWidget-Bk1RFjks-95b1e2f1c8332bd8d6a5.js +0 -1
- data/tools/bucketexplorer/ValuelimitsbarWidget-C0HIBYh2-50a3c79084d7c0054d8c.js +0 -1
- data/tools/bucketexplorer/ValuerangebarWidget-CcQw_XK9-79e2d1ff2b1e10026cbe.js +0 -1
- data/tools/bucketexplorer/main-6b345e62aee40c1b04c9.js +0 -9
|
@@ -0,0 +1,1506 @@
|
|
|
1
|
+
System.register(["./main-0d493b63e559b38d7841.js","vue","single-spa"],function(Pi,at){"use strict";var ot,Ku,bp,Gu,wp,Ot,Vn,zt,Je,et,cr,Ir,An,xp,Vr,So,Ko,Yu,Xu,oo,Qu,vs,Zu;return{setters:[an=>{ot=an._,Ku=an.d,bp=an.a,Gu=an.r},an=>{wp=an.defineAsyncComponent,Ot=an.resolveComponent,Vn=an.createBlock,zt=an.openBlock,Je=an.withCtx,et=an.createVNode,cr=an.createElementVNode,Ir=an.toDisplayString,An=an.createTextVNode,xp=an.Teleport,Vr=an.createElementBlock,So=an.Fragment,Ko=an.renderList,Yu=an.mergeProps,Xu=an.createSlots,oo=an.createCommentVNode,Qu=an.normalizeStyle,vs=an.withModifiers,Zu=an.withKeys},null],execute:function(){var an=document.createElement("style");an.textContent=`.font-size[data-v-e31865ed]{font-size:1rem}.small-font-size[data-v-e31865ed]{font-size:.8rem}.file-input[data-v-e31865ed]{padding-top:0;margin-top:0}
|
|
2
|
+
/*$vite$:1*/`,document.head.appendChild(an),Pi({$:pg,c:DL,f:Sr,l:vn,y:Kn,z:df});var Kx=Object.defineProperty,Gx=(n,e,t)=>e in n?Kx(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,kp=(n,e,t)=>Gx(n,e+"",t);function Sp(n,e){return function(){return n.apply(e,arguments)}}const{toString:Yx}=Object.prototype,{getPrototypeOf:Ju}=Object,{iterator:Yl,toStringTag:_p}=Symbol,Xl=(n=>e=>{const t=Yx.call(e);return n[t]||(n[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),Bi=n=>(n=n.toLowerCase(),e=>Xl(e)===n),Ql=n=>e=>typeof e===n,{isArray:sa}=Array,aa=Ql("undefined");function Ya(n){return n!==null&&!aa(n)&&n.constructor!==null&&!aa(n.constructor)&&Kr(n.constructor.isBuffer)&&n.constructor.isBuffer(n)}const Cp=Bi("ArrayBuffer");function Xx(n){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(n):e=n&&n.buffer&&Cp(n.buffer),e}const Qx=Ql("string"),Kr=Ql("function"),$p=Ql("number"),Xa=n=>n!==null&&typeof n=="object",Zx=n=>n===!0||n===!1,Zl=n=>{if(Xl(n)!=="object")return!1;const e=Ju(n);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(_p in n)&&!(Yl in n)},Jx=n=>{if(!Xa(n)||Ya(n))return!1;try{return Object.keys(n).length===0&&Object.getPrototypeOf(n)===Object.prototype}catch{return!1}},e1=Bi("Date"),t1=Bi("File"),n1=Bi("Blob"),r1=Bi("FileList"),i1=n=>Xa(n)&&Kr(n.pipe),o1=n=>{let e;return n&&(typeof FormData=="function"&&n instanceof FormData||Kr(n.append)&&((e=Xl(n))==="formdata"||e==="object"&&Kr(n.toString)&&n.toString()==="[object FormData]"))},s1=Bi("URLSearchParams"),[a1,l1,c1,u1]=["ReadableStream","Request","Response","Headers"].map(Bi),h1=n=>n.trim?n.trim():n.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Qa(n,e,{allOwnKeys:t=!1}={}){if(n===null||typeof n>"u")return;let r,l;if(typeof n!="object"&&(n=[n]),sa(n))for(r=0,l=n.length;r<l;r++)e.call(null,n[r],r,n);else{if(Ya(n))return;const d=t?Object.getOwnPropertyNames(n):Object.keys(n),h=d.length;let b;for(r=0;r<h;r++)b=d[r],e.call(null,n[b],b,n)}}function Ap(n,e){if(Ya(n))return null;e=e.toLowerCase();const t=Object.keys(n);let r=t.length,l;for(;r-- >0;)if(l=t[r],e===l.toLowerCase())return l;return null}const ys=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Ep=n=>!aa(n)&&n!==ys;function eh(){const{caseless:n,skipUndefined:e}=Ep(this)&&this||{},t={},r=(l,d)=>{const h=n&&Ap(t,d)||d;Zl(t[h])&&Zl(l)?t[h]=eh(t[h],l):Zl(l)?t[h]=eh({},l):sa(l)?t[h]=l.slice():(!e||!aa(l))&&(t[h]=l)};for(let l=0,d=arguments.length;l<d;l++)arguments[l]&&Qa(arguments[l],r);return t}const d1=(n,e,t,{allOwnKeys:r}={})=>(Qa(e,(l,d)=>{t&&Kr(l)?n[d]=Sp(l,t):n[d]=l},{allOwnKeys:r}),n),f1=n=>(n.charCodeAt(0)===65279&&(n=n.slice(1)),n),p1=(n,e,t,r)=>{n.prototype=Object.create(e.prototype,r),n.prototype.constructor=n,Object.defineProperty(n,"super",{value:e.prototype}),t&&Object.assign(n.prototype,t)},g1=(n,e,t,r)=>{let l,d,h;const b={};if(e=e||{},n==null)return e;do{for(l=Object.getOwnPropertyNames(n),d=l.length;d-- >0;)h=l[d],(!r||r(h,n,e))&&!b[h]&&(e[h]=n[h],b[h]=!0);n=t!==!1&&Ju(n)}while(n&&(!t||t(n,e))&&n!==Object.prototype);return e},m1=(n,e,t)=>{n=String(n),(t===void 0||t>n.length)&&(t=n.length),t-=e.length;const r=n.indexOf(e,t);return r!==-1&&r===t},v1=n=>{if(!n)return null;if(sa(n))return n;let e=n.length;if(!$p(e))return null;const t=new Array(e);for(;e-- >0;)t[e]=n[e];return t},y1=(n=>e=>n&&e instanceof n)(typeof Uint8Array<"u"&&Ju(Uint8Array)),b1=(n,e)=>{const t=(n&&n[Yl]).call(n);let r;for(;(r=t.next())&&!r.done;){const l=r.value;e.call(n,l[0],l[1])}},w1=(n,e)=>{let t;const r=[];for(;(t=n.exec(e))!==null;)r.push(t);return r},x1=Bi("HTMLFormElement"),k1=n=>n.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,r){return t.toUpperCase()+r}),Tp=(({hasOwnProperty:n})=>(e,t)=>n.call(e,t))(Object.prototype),S1=Bi("RegExp"),Rp=(n,e)=>{const t=Object.getOwnPropertyDescriptors(n),r={};Qa(t,(l,d)=>{let h;(h=e(l,d,n))!==!1&&(r[d]=h||l)}),Object.defineProperties(n,r)},_1=n=>{Rp(n,(e,t)=>{if(Kr(n)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const r=n[t];if(Kr(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},C1=(n,e)=>{const t={},r=l=>{l.forEach(d=>{t[d]=!0})};return sa(n)?r(n):r(String(n).split(e)),t},$1=()=>{},A1=(n,e)=>n!=null&&Number.isFinite(n=+n)?n:e;function E1(n){return!!(n&&Kr(n.append)&&n[_p]==="FormData"&&n[Yl])}const T1=n=>{const e=new Array(10),t=(r,l)=>{if(Xa(r)){if(e.indexOf(r)>=0)return;if(Ya(r))return r;if(!("toJSON"in r)){e[l]=r;const d=sa(r)?[]:{};return Qa(r,(h,b)=>{const p=t(h,l+1);!aa(p)&&(d[b]=p)}),e[l]=void 0,d}}return r};return t(n,0)},R1=Bi("AsyncFunction"),M1=n=>n&&(Xa(n)||Kr(n))&&Kr(n.then)&&Kr(n.catch),Mp=((n,e)=>n?setImmediate:e?((t,r)=>(ys.addEventListener("message",({source:l,data:d})=>{l===ys&&d===t&&r.length&&r.shift()()},!1),l=>{r.push(l),ys.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",Kr(ys.postMessage)),L1=typeof queueMicrotask<"u"?queueMicrotask.bind(ys):typeof process<"u"&&process.nextTick||Mp,O1=n=>n!=null&&Kr(n[Yl]),Se={isArray:sa,isArrayBuffer:Cp,isBuffer:Ya,isFormData:o1,isArrayBufferView:Xx,isString:Qx,isNumber:$p,isBoolean:Zx,isObject:Xa,isPlainObject:Zl,isEmptyObject:Jx,isReadableStream:a1,isRequest:l1,isResponse:c1,isHeaders:u1,isUndefined:aa,isDate:e1,isFile:t1,isBlob:n1,isRegExp:S1,isFunction:Kr,isStream:i1,isURLSearchParams:s1,isTypedArray:y1,isFileList:r1,forEach:Qa,merge:eh,extend:d1,trim:h1,stripBOM:f1,inherits:p1,toFlatObject:g1,kindOf:Xl,kindOfTest:Bi,endsWith:m1,toArray:v1,forEachEntry:b1,matchAll:w1,isHTMLForm:x1,hasOwnProperty:Tp,hasOwnProp:Tp,reduceDescriptors:Rp,freezeMethods:_1,toObjectSet:C1,toCamelCase:k1,noop:$1,toFiniteNumber:A1,findKey:Ap,global:ys,isContextDefined:Ep,isSpecCompliantForm:E1,toJSONObject:T1,isAsyncFn:R1,isThenable:M1,setImmediate:Mp,asap:L1,isIterable:O1};function kt(n,e,t,r,l){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=n,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),r&&(this.request=r),l&&(this.response=l,this.status=l.status?l.status:null)}Se.inherits(kt,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:Se.toJSONObject(this.config),code:this.code,status:this.status}}});const Lp=kt.prototype,Op={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(n=>{Op[n]={value:n}}),Object.defineProperties(kt,Op),Object.defineProperty(Lp,"isAxiosError",{value:!0}),kt.from=(n,e,t,r,l,d)=>{const h=Object.create(Lp);Se.toFlatObject(n,h,function(g){return g!==Error.prototype},g=>g!=="isAxiosError");const b=n&&n.message?n.message:"Error",p=e==null&&n?n.code:e;return kt.call(h,b,p,t,r,l),n&&h.cause==null&&Object.defineProperty(h,"cause",{value:n,configurable:!0}),h.name=n&&n.name||"Error",d&&Object.assign(h,d),h};const I1=null;function th(n){return Se.isPlainObject(n)||Se.isArray(n)}function Ip(n){return Se.endsWith(n,"[]")?n.slice(0,-2):n}function Np(n,e,t){return n?n.concat(e).map(function(r,l){return r=Ip(r),!t&&l?"["+r+"]":r}).join(t?".":""):e}function N1(n){return Se.isArray(n)&&!n.some(th)}const D1=Se.toFlatObject(Se,{},null,function(n){return/^is[A-Z]/.test(n)});function Jl(n,e,t){if(!Se.isObject(n))throw new TypeError("target must be an object");e=e||new FormData,t=Se.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(u,i){return!Se.isUndefined(i[u])});const r=t.metaTokens,l=t.visitor||g,d=t.dots,h=t.indexes,b=(t.Blob||typeof Blob<"u"&&Blob)&&Se.isSpecCompliantForm(e);if(!Se.isFunction(l))throw new TypeError("visitor must be a function");function p(u){if(u===null)return"";if(Se.isDate(u))return u.toISOString();if(Se.isBoolean(u))return u.toString();if(!b&&Se.isBlob(u))throw new kt("Blob is not supported. Use a Buffer instead.");return Se.isArrayBuffer(u)||Se.isTypedArray(u)?b&&typeof Blob=="function"?new Blob([u]):Buffer.from(u):u}function g(u,i,a){let m=u;if(u&&!a&&typeof u=="object"){if(Se.endsWith(i,"{}"))i=r?i:i.slice(0,-2),u=JSON.stringify(u);else if(Se.isArray(u)&&N1(u)||(Se.isFileList(u)||Se.endsWith(i,"[]"))&&(m=Se.toArray(u)))return i=Ip(i),m.forEach(function(w,x){!(Se.isUndefined(w)||w===null)&&e.append(h===!0?Np([i],x,d):h===null?i:i+"[]",p(w))}),!1}return th(u)?!0:(e.append(Np(a,i,d),p(u)),!1)}const o=[],c=Object.assign(D1,{defaultVisitor:g,convertValue:p,isVisitable:th});function f(u,i){if(!Se.isUndefined(u)){if(o.indexOf(u)!==-1)throw Error("Circular reference detected in "+i.join("."));o.push(u),Se.forEach(u,function(a,m){(!(Se.isUndefined(a)||a===null)&&l.call(e,a,Se.isString(m)?m.trim():m,i,c))===!0&&f(a,i?i.concat(m):[m])}),o.pop()}}if(!Se.isObject(n))throw new TypeError("data must be an object");return f(n),e}function Dp(n){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(n).replace(/[!'()~]|%20|%00/g,function(t){return e[t]})}function nh(n,e){this._pairs=[],n&&Jl(n,this,e)}const Fp=nh.prototype;Fp.append=function(n,e){this._pairs.push([n,e])},Fp.toString=function(n){const e=n?function(t){return n.call(this,t,Dp)}:Dp;return this._pairs.map(function(t){return e(t[0])+"="+e(t[1])},"").join("&")};function F1(n){return encodeURIComponent(n).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Pp(n,e,t){if(!e)return n;const r=t&&t.encode||F1;Se.isFunction(t)&&(t={serialize:t});const l=t&&t.serialize;let d;if(l?d=l(e,t):d=Se.isURLSearchParams(e)?e.toString():new nh(e,t).toString(r),d){const h=n.indexOf("#");h!==-1&&(n=n.slice(0,h)),n+=(n.indexOf("?")===-1?"?":"&")+d}return n}let Bp=class{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){Se.forEach(this.handlers,function(t){t!==null&&e(t)})}};const jp={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},P1=typeof URLSearchParams<"u"?URLSearchParams:nh,B1=typeof FormData<"u"?FormData:null,j1=typeof Blob<"u"?Blob:null,W1={isBrowser:!0,classes:{URLSearchParams:P1,FormData:B1,Blob:j1},protocols:["http","https","file","blob","url","data"]},rh=typeof window<"u"&&typeof document<"u",ih=typeof navigator=="object"&&navigator||void 0,z1=rh&&(!ih||["ReactNative","NativeScript","NS"].indexOf(ih.product)<0),H1=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",U1=rh&&window.location.href||"http://localhost",q1=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:rh,hasStandardBrowserEnv:z1,hasStandardBrowserWebWorkerEnv:H1,navigator:ih,origin:U1},Symbol.toStringTag,{value:"Module"})),xr={...q1,...W1};function V1(n,e){return Jl(n,new xr.classes.URLSearchParams,{visitor:function(t,r,l,d){return xr.isNode&&Se.isBuffer(t)?(this.append(r,t.toString("base64")),!1):d.defaultVisitor.apply(this,arguments)},...e})}function K1(n){return Se.matchAll(/\w+|\[(\w*)]/g,n).map(e=>e[0]==="[]"?"":e[1]||e[0])}function G1(n){const e={},t=Object.keys(n);let r;const l=t.length;let d;for(r=0;r<l;r++)d=t[r],e[d]=n[d];return e}function Wp(n){function e(t,r,l,d){let h=t[d++];if(h==="__proto__")return!0;const b=Number.isFinite(+h),p=d>=t.length;return h=!h&&Se.isArray(l)?l.length:h,p?(Se.hasOwnProp(l,h)?l[h]=[l[h],r]:l[h]=r,!b):((!l[h]||!Se.isObject(l[h]))&&(l[h]=[]),e(t,r,l[h],d)&&Se.isArray(l[h])&&(l[h]=G1(l[h])),!b)}if(Se.isFormData(n)&&Se.isFunction(n.entries)){const t={};return Se.forEachEntry(n,(r,l)=>{e(K1(r),l,t,0)}),t}return null}function Y1(n,e,t){if(Se.isString(n))try{return(e||JSON.parse)(n),Se.trim(n)}catch(r){if(r.name!=="SyntaxError")throw r}return(t||JSON.stringify)(n)}const Za={transitional:jp,adapter:["xhr","http","fetch"],transformRequest:[function(n,e){const t=e.getContentType()||"",r=t.indexOf("application/json")>-1,l=Se.isObject(n);if(l&&Se.isHTMLForm(n)&&(n=new FormData(n)),Se.isFormData(n))return r?JSON.stringify(Wp(n)):n;if(Se.isArrayBuffer(n)||Se.isBuffer(n)||Se.isStream(n)||Se.isFile(n)||Se.isBlob(n)||Se.isReadableStream(n))return n;if(Se.isArrayBufferView(n))return n.buffer;if(Se.isURLSearchParams(n))return e.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),n.toString();let d;if(l){if(t.indexOf("application/x-www-form-urlencoded")>-1)return V1(n,this.formSerializer).toString();if((d=Se.isFileList(n))||t.indexOf("multipart/form-data")>-1){const h=this.env&&this.env.FormData;return Jl(d?{"files[]":n}:n,h&&new h,this.formSerializer)}}return l||r?(e.setContentType("application/json",!1),Y1(n)):n}],transformResponse:[function(n){const e=this.transitional||Za.transitional,t=e&&e.forcedJSONParsing,r=this.responseType==="json";if(Se.isResponse(n)||Se.isReadableStream(n))return n;if(n&&Se.isString(n)&&(t&&!this.responseType||r)){const l=!(e&&e.silentJSONParsing)&&r;try{return JSON.parse(n,this.parseReviver)}catch(d){if(l)throw d.name==="SyntaxError"?kt.from(d,kt.ERR_BAD_RESPONSE,this,null,this.response):d}}return n}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:xr.classes.FormData,Blob:xr.classes.Blob},validateStatus:function(n){return n>=200&&n<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};Se.forEach(["delete","get","head","post","put","patch"],n=>{Za.headers[n]={}});const X1=Se.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Q1=n=>{const e={};let t,r,l;return n&&n.split(`
|
|
3
|
+
`).forEach(function(d){l=d.indexOf(":"),t=d.substring(0,l).trim().toLowerCase(),r=d.substring(l+1).trim(),!(!t||e[t]&&X1[t])&&(t==="set-cookie"?e[t]?e[t].push(r):e[t]=[r]:e[t]=e[t]?e[t]+", "+r:r)}),e},zp=Symbol("internals");function Ja(n){return n&&String(n).trim().toLowerCase()}function ec(n){return n===!1||n==null?n:Se.isArray(n)?n.map(ec):String(n)}function Z1(n){const e=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=t.exec(n);)e[r[1]]=r[2];return e}const J1=n=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(n.trim());function oh(n,e,t,r,l){if(Se.isFunction(r))return r.call(this,e,t);if(l&&(e=t),!!Se.isString(e)){if(Se.isString(r))return e.indexOf(r)!==-1;if(Se.isRegExp(r))return r.test(e)}}function ek(n){return n.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r)}function tk(n,e){const t=Se.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(n,r+t,{value:function(l,d,h){return this[r].call(this,e,l,d,h)},configurable:!0})})}let Gr=class{constructor(e){e&&this.set(e)}set(e,t,r){const l=this;function d(b,p,g){const o=Ja(p);if(!o)throw new Error("header name must be a non-empty string");const c=Se.findKey(l,o);(!c||l[c]===void 0||g===!0||g===void 0&&l[c]!==!1)&&(l[c||p]=ec(b))}const h=(b,p)=>Se.forEach(b,(g,o)=>d(g,o,p));if(Se.isPlainObject(e)||e instanceof this.constructor)h(e,t);else if(Se.isString(e)&&(e=e.trim())&&!J1(e))h(Q1(e),t);else if(Se.isObject(e)&&Se.isIterable(e)){let b={},p,g;for(const o of e){if(!Se.isArray(o))throw TypeError("Object iterator must return a key-value pair");b[g=o[0]]=(p=b[g])?Se.isArray(p)?[...p,o[1]]:[p,o[1]]:o[1]}h(b,t)}else e!=null&&d(t,e,r);return this}get(e,t){if(e=Ja(e),e){const r=Se.findKey(this,e);if(r){const l=this[r];if(!t)return l;if(t===!0)return Z1(l);if(Se.isFunction(t))return t.call(this,l,r);if(Se.isRegExp(t))return t.exec(l);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Ja(e),e){const r=Se.findKey(this,e);return!!(r&&this[r]!==void 0&&(!t||oh(this,this[r],r,t)))}return!1}delete(e,t){const r=this;let l=!1;function d(h){if(h=Ja(h),h){const b=Se.findKey(r,h);b&&(!t||oh(r,r[b],b,t))&&(delete r[b],l=!0)}}return Se.isArray(e)?e.forEach(d):d(e),l}clear(e){const t=Object.keys(this);let r=t.length,l=!1;for(;r--;){const d=t[r];(!e||oh(this,this[d],d,e,!0))&&(delete this[d],l=!0)}return l}normalize(e){const t=this,r={};return Se.forEach(this,(l,d)=>{const h=Se.findKey(r,d);if(h){t[h]=ec(l),delete t[d];return}const b=e?ek(d):String(d).trim();b!==d&&delete t[d],t[b]=ec(l),r[b]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return Se.forEach(this,(r,l)=>{r!=null&&r!==!1&&(t[l]=e&&Se.isArray(r)?r.join(", "):r)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join(`
|
|
4
|
+
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const r=new this(e);return t.forEach(l=>r.set(l)),r}static accessor(e){const t=(this[zp]=this[zp]={accessors:{}}).accessors,r=this.prototype;function l(d){const h=Ja(d);t[h]||(tk(r,d),t[h]=!0)}return Se.isArray(e)?e.forEach(l):l(e),this}};Gr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Se.reduceDescriptors(Gr.prototype,({value:n},e)=>{let t=e[0].toUpperCase()+e.slice(1);return{get:()=>n,set(r){this[t]=r}}}),Se.freezeMethods(Gr);function sh(n,e){const t=this||Za,r=e||t,l=Gr.from(r.headers);let d=r.data;return Se.forEach(n,function(h){d=h.call(t,d,l.normalize(),e?e.status:void 0)}),l.normalize(),d}function Hp(n){return!!(n&&n.__CANCEL__)}function la(n,e,t){kt.call(this,n??"canceled",kt.ERR_CANCELED,e,t),this.name="CanceledError"}Se.inherits(la,kt,{__CANCEL__:!0});function Up(n,e,t){const r=t.config.validateStatus;!t.status||!r||r(t.status)?n(t):e(new kt("Request failed with status code "+t.status,[kt.ERR_BAD_REQUEST,kt.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function nk(n){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(n);return e&&e[1]||""}function rk(n,e){n=n||10;const t=new Array(n),r=new Array(n);let l=0,d=0,h;return e=e!==void 0?e:1e3,function(b){const p=Date.now(),g=r[d];h||(h=p),t[l]=b,r[l]=p;let o=d,c=0;for(;o!==l;)c+=t[o++],o=o%n;if(l=(l+1)%n,l===d&&(d=(d+1)%n),p-h<e)return;const f=g&&p-g;return f?Math.round(c*1e3/f):void 0}}function ik(n,e){let t=0,r=1e3/e,l,d;const h=(b,p=Date.now())=>{t=p,l=null,d&&(clearTimeout(d),d=null),n(...b)};return[(...b)=>{const p=Date.now(),g=p-t;g>=r?h(b,p):(l=b,d||(d=setTimeout(()=>{d=null,h(l)},r-g)))},()=>l&&h(l)]}const tc=(n,e,t=3)=>{let r=0;const l=rk(50,250);return ik(d=>{const h=d.loaded,b=d.lengthComputable?d.total:void 0,p=h-r,g=l(p),o=h<=b;r=h;const c={loaded:h,total:b,progress:b?h/b:void 0,bytes:p,rate:g||void 0,estimated:g&&b&&o?(b-h)/g:void 0,event:d,lengthComputable:b!=null,[e?"download":"upload"]:!0};n(c)},t)},qp=(n,e)=>{const t=n!=null;return[r=>e[0]({lengthComputable:t,total:n,loaded:r}),e[1]]},Vp=n=>(...e)=>Se.asap(()=>n(...e)),ok=xr.hasStandardBrowserEnv?((n,e)=>t=>(t=new URL(t,xr.origin),n.protocol===t.protocol&&n.host===t.host&&(e||n.port===t.port)))(new URL(xr.origin),xr.navigator&&/(msie|trident)/i.test(xr.navigator.userAgent)):()=>!0,sk=xr.hasStandardBrowserEnv?{write(n,e,t,r,l,d,h){if(typeof document>"u")return;const b=[`${n}=${encodeURIComponent(e)}`];Se.isNumber(t)&&b.push(`expires=${new Date(t).toUTCString()}`),Se.isString(r)&&b.push(`path=${r}`),Se.isString(l)&&b.push(`domain=${l}`),d===!0&&b.push("secure"),Se.isString(h)&&b.push(`SameSite=${h}`),document.cookie=b.join("; ")},read(n){if(typeof document>"u")return null;const e=document.cookie.match(new RegExp("(?:^|; )"+n+"=([^;]*)"));return e?decodeURIComponent(e[1]):null},remove(n){this.write(n,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function ak(n){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(n)}function lk(n,e){return e?n.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):n}function Kp(n,e,t){let r=!ak(e);return n&&(r||t==!1)?lk(n,e):e}const Gp=n=>n instanceof Gr?{...n}:n;function bs(n,e){e=e||{};const t={};function r(g,o,c,f){return Se.isPlainObject(g)&&Se.isPlainObject(o)?Se.merge.call({caseless:f},g,o):Se.isPlainObject(o)?Se.merge({},o):Se.isArray(o)?o.slice():o}function l(g,o,c,f){if(Se.isUndefined(o)){if(!Se.isUndefined(g))return r(void 0,g,c,f)}else return r(g,o,c,f)}function d(g,o){if(!Se.isUndefined(o))return r(void 0,o)}function h(g,o){if(Se.isUndefined(o)){if(!Se.isUndefined(g))return r(void 0,g)}else return r(void 0,o)}function b(g,o,c){if(c in e)return r(g,o);if(c in n)return r(void 0,g)}const p={url:d,method:d,data:d,baseURL:h,transformRequest:h,transformResponse:h,paramsSerializer:h,timeout:h,timeoutMessage:h,withCredentials:h,withXSRFToken:h,adapter:h,responseType:h,xsrfCookieName:h,xsrfHeaderName:h,onUploadProgress:h,onDownloadProgress:h,decompress:h,maxContentLength:h,maxBodyLength:h,beforeRedirect:h,transport:h,httpAgent:h,httpsAgent:h,cancelToken:h,socketPath:h,responseEncoding:h,validateStatus:b,headers:(g,o,c)=>l(Gp(g),Gp(o),c,!0)};return Se.forEach(Object.keys({...n,...e}),function(g){const o=p[g]||l,c=o(n[g],e[g],g);Se.isUndefined(c)&&o!==b||(t[g]=c)}),t}const Yp=n=>{const e=bs({},n);let{data:t,withXSRFToken:r,xsrfHeaderName:l,xsrfCookieName:d,headers:h,auth:b}=e;if(e.headers=h=Gr.from(h),e.url=Pp(Kp(e.baseURL,e.url,e.allowAbsoluteUrls),n.params,n.paramsSerializer),b&&h.set("Authorization","Basic "+btoa((b.username||"")+":"+(b.password?unescape(encodeURIComponent(b.password)):""))),Se.isFormData(t)){if(xr.hasStandardBrowserEnv||xr.hasStandardBrowserWebWorkerEnv)h.setContentType(void 0);else if(Se.isFunction(t.getHeaders)){const p=t.getHeaders(),g=["content-type","content-length"];Object.entries(p).forEach(([o,c])=>{g.includes(o.toLowerCase())&&h.set(o,c)})}}if(xr.hasStandardBrowserEnv&&(r&&Se.isFunction(r)&&(r=r(e)),r||r!==!1&&ok(e.url))){const p=l&&d&&sk.read(d);p&&h.set(l,p)}return e},ck=typeof XMLHttpRequest<"u",uk=ck&&function(n){return new Promise(function(e,t){const r=Yp(n);let l=r.data;const d=Gr.from(r.headers).normalize();let{responseType:h,onUploadProgress:b,onDownloadProgress:p}=r,g,o,c,f,u;function i(){f&&f(),u&&u(),r.cancelToken&&r.cancelToken.unsubscribe(g),r.signal&&r.signal.removeEventListener("abort",g)}let a=new XMLHttpRequest;a.open(r.method.toUpperCase(),r.url,!0),a.timeout=r.timeout;function m(){if(!a)return;const x=Gr.from("getAllResponseHeaders"in a&&a.getAllResponseHeaders()),M={data:!h||h==="text"||h==="json"?a.responseText:a.response,status:a.status,statusText:a.statusText,headers:x,config:n,request:a};Up(function($){e($),i()},function($){t($),i()},M),a=null}"onloadend"in a?a.onloadend=m:a.onreadystatechange=function(){!a||a.readyState!==4||a.status===0&&!(a.responseURL&&a.responseURL.indexOf("file:")===0)||setTimeout(m)},a.onabort=function(){a&&(t(new kt("Request aborted",kt.ECONNABORTED,n,a)),a=null)},a.onerror=function(x){const M=x&&x.message?x.message:"Network Error",$=new kt(M,kt.ERR_NETWORK,n,a);$.event=x||null,t($),a=null},a.ontimeout=function(){let x=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const M=r.transitional||jp;r.timeoutErrorMessage&&(x=r.timeoutErrorMessage),t(new kt(x,M.clarifyTimeoutError?kt.ETIMEDOUT:kt.ECONNABORTED,n,a)),a=null},l===void 0&&d.setContentType(null),"setRequestHeader"in a&&Se.forEach(d.toJSON(),function(x,M){a.setRequestHeader(M,x)}),Se.isUndefined(r.withCredentials)||(a.withCredentials=!!r.withCredentials),h&&h!=="json"&&(a.responseType=r.responseType),p&&([c,u]=tc(p,!0),a.addEventListener("progress",c)),b&&a.upload&&([o,f]=tc(b),a.upload.addEventListener("progress",o),a.upload.addEventListener("loadend",f)),(r.cancelToken||r.signal)&&(g=x=>{a&&(t(!x||x.type?new la(null,n,a):x),a.abort(),a=null)},r.cancelToken&&r.cancelToken.subscribe(g),r.signal&&(r.signal.aborted?g():r.signal.addEventListener("abort",g)));const w=nk(r.url);if(w&&xr.protocols.indexOf(w)===-1){t(new kt("Unsupported protocol "+w+":",kt.ERR_BAD_REQUEST,n));return}a.send(l||null)})},hk=(n,e)=>{const{length:t}=n=n?n.filter(Boolean):[];if(e||t){let r=new AbortController,l;const d=function(g){if(!l){l=!0,b();const o=g instanceof Error?g:this.reason;r.abort(o instanceof kt?o:new la(o instanceof Error?o.message:o))}};let h=e&&setTimeout(()=>{h=null,d(new kt(`timeout ${e} of ms exceeded`,kt.ETIMEDOUT))},e);const b=()=>{n&&(h&&clearTimeout(h),h=null,n.forEach(g=>{g.unsubscribe?g.unsubscribe(d):g.removeEventListener("abort",d)}),n=null)};n.forEach(g=>g.addEventListener("abort",d));const{signal:p}=r;return p.unsubscribe=()=>Se.asap(b),p}},dk=function*(n,e){let t=n.byteLength;if(t<e){yield n;return}let r=0,l;for(;r<t;)l=r+e,yield n.slice(r,l),r=l},fk=async function*(n,e){for await(const t of pk(n))yield*dk(t,e)},pk=async function*(n){if(n[Symbol.asyncIterator]){yield*n;return}const e=n.getReader();try{for(;;){const{done:t,value:r}=await e.read();if(t)break;yield r}}finally{await e.cancel()}},Xp=(n,e,t,r)=>{const l=fk(n,e);let d=0,h,b=p=>{h||(h=!0,r&&r(p))};return new ReadableStream({async pull(p){try{const{done:g,value:o}=await l.next();if(g){b(),p.close();return}let c=o.byteLength;if(t){let f=d+=c;t(f)}p.enqueue(new Uint8Array(o))}catch(g){throw b(g),g}},cancel(p){return b(p),l.return()}},{highWaterMark:2})},Qp=64*1024,{isFunction:nc}=Se,gk=(({Request:n,Response:e})=>({Request:n,Response:e}))(Se.global),{ReadableStream:Zp,TextEncoder:Jp}=Se.global,eg=(n,...e)=>{try{return!!n(...e)}catch{return!1}},mk=n=>{n=Se.merge.call({skipUndefined:!0},gk,n);const{fetch:e,Request:t,Response:r}=n,l=e?nc(e):typeof fetch=="function",d=nc(t),h=nc(r);if(!l)return!1;const b=l&&nc(Zp),p=l&&(typeof Jp=="function"?(i=>a=>i.encode(a))(new Jp):async i=>new Uint8Array(await new t(i).arrayBuffer())),g=d&&b&&eg(()=>{let i=!1;const a=new t(xr.origin,{body:new Zp,method:"POST",get duplex(){return i=!0,"half"}}).headers.has("Content-Type");return i&&!a}),o=h&&b&&eg(()=>Se.isReadableStream(new r("").body)),c={stream:o&&(i=>i.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(i=>{!c[i]&&(c[i]=(a,m)=>{let w=a&&a[i];if(w)return w.call(a);throw new kt(`Response type '${i}' is not supported`,kt.ERR_NOT_SUPPORT,m)})});const f=async i=>{if(i==null)return 0;if(Se.isBlob(i))return i.size;if(Se.isSpecCompliantForm(i))return(await new t(xr.origin,{method:"POST",body:i}).arrayBuffer()).byteLength;if(Se.isArrayBufferView(i)||Se.isArrayBuffer(i))return i.byteLength;if(Se.isURLSearchParams(i)&&(i=i+""),Se.isString(i))return(await p(i)).byteLength},u=async(i,a)=>Se.toFiniteNumber(i.getContentLength())??f(a);return async i=>{let{url:a,method:m,data:w,signal:x,cancelToken:M,timeout:$,onDownloadProgress:S,onUploadProgress:k,responseType:T,headers:D,withCredentials:L="same-origin",fetchOptions:O}=Yp(i),z=e||fetch;T=T?(T+"").toLowerCase():"text";let P=hk([x,M&&M.toAbortSignal()],$),N=null;const A=P&&P.unsubscribe&&(()=>{P.unsubscribe()});let _;try{if(k&&g&&m!=="get"&&m!=="head"&&(_=await u(D,w))!==0){let J=new t(a,{method:"POST",body:w,duplex:"half"}),ae;if(Se.isFormData(w)&&(ae=J.headers.get("content-type"))&&D.setContentType(ae),J.body){const[ne,se]=qp(_,tc(Vp(k)));w=Xp(J.body,Qp,ne,se)}}Se.isString(L)||(L=L?"include":"omit");const I=d&&"credentials"in t.prototype,j={...O,signal:P,method:m.toUpperCase(),headers:D.normalize().toJSON(),body:w,duplex:"half",credentials:I?L:void 0};N=d&&new t(a,j);let U=await(d?z(N,O):z(a,j));const K=o&&(T==="stream"||T==="response");if(o&&(S||K&&A)){const J={};["status","statusText","headers"].forEach(ce=>{J[ce]=U[ce]});const ae=Se.toFiniteNumber(U.headers.get("content-length")),[ne,se]=S&&qp(ae,tc(Vp(S),!0))||[];U=new r(Xp(U.body,Qp,ne,()=>{se&&se(),A&&A()}),J)}T=T||"text";let Z=await c[Se.findKey(c,T)||"text"](U,i);return!K&&A&&A(),await new Promise((J,ae)=>{Up(J,ae,{data:Z,headers:Gr.from(U.headers),status:U.status,statusText:U.statusText,config:i,request:N})})}catch(I){throw A&&A(),I&&I.name==="TypeError"&&/Load failed|fetch/i.test(I.message)?Object.assign(new kt("Network Error",kt.ERR_NETWORK,i,N),{cause:I.cause||I}):kt.from(I,I&&I.code,i,N)}}},vk=new Map,tg=n=>{let e=n&&n.env||{};const{fetch:t,Request:r,Response:l}=e,d=[r,l,t];let h=d.length,b=h,p,g,o=vk;for(;b--;)p=d[b],g=o.get(p),g===void 0&&o.set(p,g=b?new Map:mk(e)),o=g;return g};tg();const ah={http:I1,xhr:uk,fetch:{get:tg}};Se.forEach(ah,(n,e)=>{if(n){try{Object.defineProperty(n,"name",{value:e})}catch{}Object.defineProperty(n,"adapterName",{value:e})}});const ng=n=>`- ${n}`,yk=n=>Se.isFunction(n)||n===null||n===!1;function bk(n,e){n=Se.isArray(n)?n:[n];const{length:t}=n;let r,l;const d={};for(let h=0;h<t;h++){r=n[h];let b;if(l=r,!yk(r)&&(l=ah[(b=String(r)).toLowerCase()],l===void 0))throw new kt(`Unknown adapter '${b}'`);if(l&&(Se.isFunction(l)||(l=l.get(e))))break;d[b||"#"+h]=l}if(!l){const h=Object.entries(d).map(([p,g])=>`adapter ${p} `+(g===!1?"is not supported by the environment":"is not available in the build"));let b=t?h.length>1?`since :
|
|
5
|
+
`+h.map(ng).join(`
|
|
6
|
+
`):" "+ng(h[0]):"as no adapter specified";throw new kt("There is no suitable adapter to dispatch the request "+b,"ERR_NOT_SUPPORT")}return l}const rg={getAdapter:bk,adapters:ah};function lh(n){if(n.cancelToken&&n.cancelToken.throwIfRequested(),n.signal&&n.signal.aborted)throw new la(null,n)}function ig(n){return lh(n),n.headers=Gr.from(n.headers),n.data=sh.call(n,n.transformRequest),["post","put","patch"].indexOf(n.method)!==-1&&n.headers.setContentType("application/x-www-form-urlencoded",!1),rg.getAdapter(n.adapter||Za.adapter,n)(n).then(function(e){return lh(n),e.data=sh.call(n,n.transformResponse,e),e.headers=Gr.from(e.headers),e},function(e){return Hp(e)||(lh(n),e&&e.response&&(e.response.data=sh.call(n,n.transformResponse,e.response),e.response.headers=Gr.from(e.response.headers))),Promise.reject(e)})}const og="1.13.1",rc={};["object","boolean","number","function","string","symbol"].forEach((n,e)=>{rc[n]=function(t){return typeof t===n||"a"+(e<1?"n ":" ")+n}});const sg={};rc.transitional=function(n,e,t){function r(l,d){return"[Axios v"+og+"] Transitional option '"+l+"'"+d+(t?". "+t:"")}return(l,d,h)=>{if(n===!1)throw new kt(r(d," has been removed"+(e?" in "+e:"")),kt.ERR_DEPRECATED);return e&&!sg[d]&&(sg[d]=!0,console.warn(r(d," has been deprecated since v"+e+" and will be removed in the near future"))),n?n(l,d,h):!0}},rc.spelling=function(n){return(e,t)=>(console.warn(`${t} is likely a misspelling of ${n}`),!0)};function wk(n,e,t){if(typeof n!="object")throw new kt("options must be an object",kt.ERR_BAD_OPTION_VALUE);const r=Object.keys(n);let l=r.length;for(;l-- >0;){const d=r[l],h=e[d];if(h){const b=n[d],p=b===void 0||h(b,d,n);if(p!==!0)throw new kt("option "+d+" must be "+p,kt.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new kt("Unknown option "+d,kt.ERR_BAD_OPTION)}}const ic={assertOptions:wk,validators:rc},so=ic.validators;let ws=class{constructor(e){this.defaults=e||{},this.interceptors={request:new Bp,response:new Bp}}async request(e,t){try{return await this._request(e,t)}catch(r){if(r instanceof Error){let l={};Error.captureStackTrace?Error.captureStackTrace(l):l=new Error;const d=l.stack?l.stack.replace(/^.+\n/,""):"";try{r.stack?d&&!String(r.stack).endsWith(d.replace(/^.+\n.+\n/,""))&&(r.stack+=`
|
|
7
|
+
`+d):r.stack=d}catch{}}throw r}}_request(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=bs(this.defaults,t);const{transitional:r,paramsSerializer:l,headers:d}=t;r!==void 0&&ic.assertOptions(r,{silentJSONParsing:so.transitional(so.boolean),forcedJSONParsing:so.transitional(so.boolean),clarifyTimeoutError:so.transitional(so.boolean)},!1),l!=null&&(Se.isFunction(l)?t.paramsSerializer={serialize:l}:ic.assertOptions(l,{encode:so.function,serialize:so.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),ic.assertOptions(t,{baseUrl:so.spelling("baseURL"),withXsrfToken:so.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let h=d&&Se.merge(d.common,d[t.method]);d&&Se.forEach(["delete","get","head","post","put","patch","common"],i=>{delete d[i]}),t.headers=Gr.concat(h,d);const b=[];let p=!0;this.interceptors.request.forEach(function(i){typeof i.runWhen=="function"&&i.runWhen(t)===!1||(p=p&&i.synchronous,b.unshift(i.fulfilled,i.rejected))});const g=[];this.interceptors.response.forEach(function(i){g.push(i.fulfilled,i.rejected)});let o,c=0,f;if(!p){const i=[ig.bind(this),void 0];for(i.unshift(...b),i.push(...g),f=i.length,o=Promise.resolve(t);c<f;)o=o.then(i[c++],i[c++]);return o}f=b.length;let u=t;for(;c<f;){const i=b[c++],a=b[c++];try{u=i(u)}catch(m){a.call(this,m);break}}try{o=ig.call(this,u)}catch(i){return Promise.reject(i)}for(c=0,f=g.length;c<f;)o=o.then(g[c++],g[c++]);return o}getUri(e){e=bs(this.defaults,e);const t=Kp(e.baseURL,e.url,e.allowAbsoluteUrls);return Pp(t,e.params,e.paramsSerializer)}};Se.forEach(["delete","get","head","options"],function(n){ws.prototype[n]=function(e,t){return this.request(bs(t||{},{method:n,url:e,data:(t||{}).data}))}}),Se.forEach(["post","put","patch"],function(n){function e(t){return function(r,l,d){return this.request(bs(d||{},{method:n,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:l}))}}ws.prototype[n]=e(),ws.prototype[n+"Form"]=e(!0)});let xk=class Hx{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(l){t=l});const r=this;this.promise.then(l=>{if(!r._listeners)return;let d=r._listeners.length;for(;d-- >0;)r._listeners[d](l);r._listeners=null}),this.promise.then=l=>{let d;const h=new Promise(b=>{r.subscribe(b),d=b}).then(l);return h.cancel=function(){r.unsubscribe(d)},h},e(function(l,d,h){r.reason||(r.reason=new la(l,d,h),t(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=r=>{e.abort(r)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new Hx(function(t){e=t}),cancel:e}}};function kk(n){return function(e){return n.apply(null,e)}}function Sk(n){return Se.isObject(n)&&n.isAxiosError===!0}const ch={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(ch).forEach(([n,e])=>{ch[e]=n});function ag(n){const e=new ws(n),t=Sp(ws.prototype.request,e);return Se.extend(t,ws.prototype,e,{allOwnKeys:!0}),Se.extend(t,e,null,{allOwnKeys:!0}),t.create=function(r){return ag(bs(n,r))},t}const Nn=ag(Za);Nn.Axios=ws,Nn.CanceledError=la,Nn.CancelToken=xk,Nn.isCancel=Hp,Nn.VERSION=og,Nn.toFormData=Jl,Nn.AxiosError=kt,Nn.Cancel=Nn.CanceledError,Nn.all=function(n){return Promise.all(n)},Nn.spread=kk,Nn.isAxiosError=Sk,Nn.mergeConfig=bs,Nn.AxiosHeaders=Gr,Nn.formToJSON=n=>Wp(Se.isHTMLForm(n)?new FormData(n):n),Nn.getAdapter=rg.getAdapter,Nn.HttpStatusCode=ch,Nn.default=Nn;const{Axios:kB,AxiosError:SB,CanceledError:_B,isCancel:CB,CancelToken:$B,VERSION:AB,all:EB,Cancel:TB,isAxiosError:RB,spread:MB,toFormData:LB,AxiosHeaders:OB,HttpStatusCode:IB,formToJSON:NB,getAdapter:DB,mergeConfig:FB}=Nn,lg=Nn.create({baseURL:location.origin,timeout:6e4,params:{}});lg.interceptors.response.use(n=>n,n=>{var e,t,r,l,d,h,b,p,g,o,c;if(n.response){if(n.response.status===401&&OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity,!0).then(function(i){i&&OpenC3Auth.setTokens()}),n.response.config.headers["Ignore-Errors"]&&n.response.config.headers["Ignore-Errors"].includes(n.response.status.toString()))return Promise.reject(n);let f=`HTTP ${n.response.status} - `;(e=n.response)!=null&&e.statusText&&(f+=`${n.response.statusText} `),(r=(t=n.response)==null?void 0:t.config)!=null&&r.data&&(f+=`${n.response.config.data} `),(d=(l=n.response)==null?void 0:l.data)!=null&&d.message?f+=`${n.response.data.message}`:(b=(h=n.response)==null?void 0:h.data)!=null&&b.exception?f+=`${n.response.data.exception}`:(o=(g=(p=n.response)==null?void 0:p.data)==null?void 0:g.error)!=null&&o.message?(n.response.data.error.class&&(f+=`${n.response.data.error.class} `),f+=`${n.response.data.error.message}`):f+=`${(c=n.response)==null?void 0:c.data}`;const{$cosmosNotify:u}=window;throw u&&u.serious({title:"Network error",body:f}),n}else throw n});const oc=async function(n,e,{data:t,params:r={},headers:l,noAuth:d=!1,noScope:h=!1,onUploadProgress:b=!1}={}){if(!d){try{await OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity)&&OpenC3Auth.setTokens()}catch{OpenC3Auth.login()}l.Authorization=localStorage.openc3Token}return l.manual=!0,!h&&!r.scope&&(r.scope=window.openc3Scope),lg({method:n,url:e,data:t,params:r,headers:l,onUploadProgress:b})},uh={Accept:"application/json"},cg={...uh,"Content-Type":"application/json"},xs={get:function(n,{params:e,headers:t=uh,noScope:r,noAuth:l,onUploadProgress:d}={}){return oc("get",n,{params:e,headers:t,noScope:r,noAuth:l,onUploadProgress:d})},put:function(n,{data:e,params:t,headers:r=cg,noScope:l,noAuth:d,onUploadProgress:h}={}){return oc("put",n,{data:e,params:t,headers:r,noScope:l,noAuth:d,onUploadProgress:h})},post:function(n,{data:e,params:t,headers:r=cg,noScope:l,noAuth:d,onUploadProgress:h}={}){return oc("post",n,{data:e,params:t,headers:r,noScope:l,noAuth:d,onUploadProgress:h})},delete:function(n,{params:e,headers:t=uh,noScope:r,noAuth:l,onUploadProgress:d}={}){return oc("delete",n,{params:e,headers:t,noScope:r,noAuth:l,onUploadProgress:d})}};let _k=()=>({emit(n,...e){for(let t=this.events[n]||[],r=0,l=t.length;r<l;r++)t[r](...e)},events:{},on(n,e){var t;return((t=this.events)[n]||(t[n]=[])).push(e),()=>{var r;this.events[n]=(r=this.events[n])==null?void 0:r.filter(l=>e!==l)}}}),Ck=class extends Error{constructor(e,t){e instanceof Error?(super(e.message),this.cause=e):super(e),this.reason=t,this.name="ReasonError"}};function $k(n){return n?`{${Object.keys(n).sort().filter(e=>n[e]!==void 0).map(e=>{let t=JSON.stringify(n[e]);return`${JSON.stringify(e)}:${t}`}).join(",")}}`:""}class Ak{constructor(e){this.channel=e,this.listeners=[]}watch(){this.listeners.push(this.channel.on("presence",e=>{if(e.type==="info"){this._state||(this._state=this.stateFromInfo(e));return}this._state&&(e.type==="join"?this._state[e.id]=e.info:e.type==="leave"&&delete this._state[e.id])}))}reset(){delete this._state}dispose(){delete this._info,delete this._state,this.listeners.forEach(e=>e()),this.listeners.length=0}async join(e,t){if(!this._info)return this._info={id:e,info:t},this.channel.perform("$presence:join",this._info)}async leave(){if(!this._info)return;let e=await this.channel.perform("$presence:leave");return delete this._info,e}async info(){return this._state?this._state:(this._promise||(this._promise=this._sync()),await this._promise,this._state)}async _sync(){this.watch();try{let e=await this.channel.perform("$presence:info",{});return this._state=this.stateFromInfo(e),this._state}finally{delete this._promise}}stateFromInfo(e){return e.records.reduce((t,{id:r,info:l})=>(t[r]=l,t),{})}}const ks=Symbol("state");let ug=class{constructor(e={}){this.emitter=_k(),this.params=Object.freeze(e),this.presence=new Ak(this),this.initialConnect=!0,this[ks]="idle"}get identifier(){return this._identifier?this._identifier:(this._identifier=$k({channel:this.channelId,...this.params}),this._identifier)}get channelId(){return this.constructor.identifier}get state(){return this[ks]}attached(e){if(this.receiver){if(this.receiver!==e)throw Error("Already connected to a different receiver");return!1}return this.receiver=e,!0}connecting(){this[ks]="connecting"}connected(){if(this.state==="connected"||this.state==="closed")return;this[ks]="connected";let e=!1;this.initialConnect?(this.initialConnect=!1,this.emit("connect",{reconnect:!1,restored:e})):this.emit("connect",{reconnect:!0,restored:e})}restored(){if(this.state==="connected")throw Error("Already connected");this[ks]="connected";let e=!0,t=!0;this.initialConnect=!1,this.emit("connect",{reconnect:t,restored:e})}disconnected(e){this.state==="disconnected"||this.state==="closed"||(this[ks]="disconnected",this.presence.reset(),this.emit("disconnect",e))}closed(e){this.state!=="closed"&&(this[ks]="closed",delete this.receiver,this.initialConnect=!0,this.presence.dispose(),this.emit("close",e))}disconnect(){this.state==="idle"||this.state==="closed"||this.receiver.unsubscribe(this)}async perform(e,t){if(this.state==="idle"||this.state==="closed")throw Error("Channel is not subscribed");return this.receiver.perform(this.identifier,e,t)}async send(e){return this.perform(void 0,e)}async whisper(e){try{await this.perform("$whisper",e)}catch(t){let r=this.receiver?this.receiver.logger:null;r&&r.warn("whisper failed: ",t)}}receive(e,t){this.emit("message",e,t)}on(e,t){return this.emitter.on(e,t)}once(e,t){let r=this.emitter.on(e,(...l)=>{r(),t(...l)});return r}emit(e,...t){return this.emitter.emit(e,...t)}ensureSubscribed(){return this.state==="connected"?Promise.resolve():this.state==="closed"?Promise.reject(Error("Channel is unsubscribed")):this.pendingSubscribe()}pendingSubscribe(){return this._pendingSubscribe?this._pendingSubscribe:(this._pendingSubscribe=new Promise((e,t)=>{let r=[()=>delete this._pendingSubscribe];r.push(this.on("connect",()=>{r.forEach(l=>l()),e()})),r.push(this.on("close",l=>{r.forEach(d=>d()),t(l||new Ck("Channel was disconnected before subscribing","canceled"))}))}),this._pendingSubscribe)}};kp(class extends ug{constructor(e,t){super(t),this.channelId=e}set channelId(e){this._channelId=e}get channelId(){return this._channelId}},"identifier","__ghost__"),kp(class extends ug{async perform(e,t){if(e.startsWith("$"))return super.perform(e,t);throw Error("not implemented")}},"identifier","$pubsub");const sc=6e4,hh=36e5,Ek=1e3,hg=Symbol.for("constructDateFrom");function Kn(n,e){return typeof n=="function"?n(e):n&&typeof n=="object"&&hg in n?n[hg](e):n instanceof Date?new n.constructor(e):new Date(e)}function vn(n,e){return Kn(e||n,n)}let Tk={};function ca(){return Tk}function Go(n,e){var t,r,l,d;const h=ca(),b=(e==null?void 0:e.weekStartsOn)??((r=(t=e==null?void 0:e.locale)==null?void 0:t.options)==null?void 0:r.weekStartsOn)??h.weekStartsOn??((d=(l=h.locale)==null?void 0:l.options)==null?void 0:d.weekStartsOn)??0,p=vn(n,e==null?void 0:e.in),g=p.getDay(),o=(g<b?7:0)+g-b;return p.setDate(p.getDate()-o),p.setHours(0,0,0,0),p}function ua(n,e){return Go(n,{...e,weekStartsOn:1})}function dg(n,e){const t=vn(n,void 0),r=t.getFullYear(),l=Kn(t,0);l.setFullYear(r+1,0,4),l.setHours(0,0,0,0);const d=ua(l),h=Kn(t,0);h.setFullYear(r,0,4),h.setHours(0,0,0,0);const b=ua(h);return t.getTime()>=d.getTime()?r+1:t.getTime()>=b.getTime()?r:r-1}function ac(n){const e=vn(n),t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),+n-+t}function Rk(n,...e){const t=Kn.bind(null,e.find(r=>typeof r=="object"));return e.map(t)}function fg(n,e){const t=vn(n,void 0);return t.setHours(0,0,0,0),t}function Mk(n,e,t){const[r,l]=Rk(void 0,n,e),d=fg(r),h=fg(l),b=+d-ac(d),p=+h-ac(h);return Math.round((b-p)/864e5)}function Lk(n,e){const t=dg(n),r=Kn(n,0);return r.setFullYear(t,0,4),r.setHours(0,0,0,0),ua(r)}function Ok(n){return n instanceof Date||typeof n=="object"&&Object.prototype.toString.call(n)==="[object Date]"}function pg(n){return!(!Ok(n)&&typeof n!="number"||isNaN(+vn(n)))}function Ik(n,e){const t=vn(n,void 0);return t.setFullYear(t.getFullYear(),0,1),t.setHours(0,0,0,0),t}const Nk={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Dk=(n,e,t)=>{let r;const l=Nk[n];return typeof l=="string"?r=l:e===1?r=l.one:r=l.other.replace("{{count}}",e.toString()),t!=null&&t.addSuffix?t.comparison&&t.comparison>0?"in "+r:r+" ago":r};function dh(n){return(e={})=>{const t=e.width?String(e.width):n.defaultWidth;return n.formats[t]||n.formats[n.defaultWidth]}}const Fk={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Pk={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Bk={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},jk={date:dh({formats:Fk,defaultWidth:"full"}),time:dh({formats:Pk,defaultWidth:"full"}),dateTime:dh({formats:Bk,defaultWidth:"full"})},Wk={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},zk=(n,e,t,r)=>Wk[n];function el(n){return(e,t)=>{const r=t!=null&&t.context?String(t.context):"standalone";let l;if(r==="formatting"&&n.formattingValues){const h=n.defaultFormattingWidth||n.defaultWidth,b=t!=null&&t.width?String(t.width):h;l=n.formattingValues[b]||n.formattingValues[h]}else{const h=n.defaultWidth,b=t!=null&&t.width?String(t.width):n.defaultWidth;l=n.values[b]||n.values[h]}const d=n.argumentCallback?n.argumentCallback(e):e;return l[d]}}const Hk={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Uk={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},qk={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Vk={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Kk={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Gk={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},Yk=(n,e)=>{const t=Number(n),r=t%100;if(r>20||r<10)switch(r%10){case 1:return t+"st";case 2:return t+"nd";case 3:return t+"rd"}return t+"th"},Xk={ordinalNumber:Yk,era:el({values:Hk,defaultWidth:"wide"}),quarter:el({values:Uk,defaultWidth:"wide",argumentCallback:n=>n-1}),month:el({values:qk,defaultWidth:"wide"}),day:el({values:Vk,defaultWidth:"wide"}),dayPeriod:el({values:Kk,defaultWidth:"wide",formattingValues:Gk,defaultFormattingWidth:"wide"})};function tl(n){return(e,t={})=>{const r=t.width,l=r&&n.matchPatterns[r]||n.matchPatterns[n.defaultMatchWidth],d=e.match(l);if(!d)return null;const h=d[0],b=r&&n.parsePatterns[r]||n.parsePatterns[n.defaultParseWidth],p=Array.isArray(b)?Zk(b,c=>c.test(h)):Qk(b,c=>c.test(h));let g;g=n.valueCallback?n.valueCallback(p):p,g=t.valueCallback?t.valueCallback(g):g;const o=e.slice(h.length);return{value:g,rest:o}}}function Qk(n,e){for(const t in n)if(Object.prototype.hasOwnProperty.call(n,t)&&e(n[t]))return t}function Zk(n,e){for(let t=0;t<n.length;t++)if(e(n[t]))return t}function Jk(n){return(e,t={})=>{const r=e.match(n.matchPattern);if(!r)return null;const l=r[0],d=e.match(n.parsePattern);if(!d)return null;let h=n.valueCallback?n.valueCallback(d[0]):d[0];h=t.valueCallback?t.valueCallback(h):h;const b=e.slice(l.length);return{value:h,rest:b}}}const eS=/^(\d+)(th|st|nd|rd)?/i,tS=/\d+/i,nS={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},rS={any:[/^b/i,/^(a|c)/i]},iS={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},oS={any:[/1/i,/2/i,/3/i,/4/i]},sS={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},aS={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},lS={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},cS={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},uS={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},hS={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},dS={ordinalNumber:Jk({matchPattern:eS,parsePattern:tS,valueCallback:n=>parseInt(n,10)}),era:tl({matchPatterns:nS,defaultMatchWidth:"wide",parsePatterns:rS,defaultParseWidth:"any"}),quarter:tl({matchPatterns:iS,defaultMatchWidth:"wide",parsePatterns:oS,defaultParseWidth:"any",valueCallback:n=>n+1}),month:tl({matchPatterns:sS,defaultMatchWidth:"wide",parsePatterns:aS,defaultParseWidth:"any"}),day:tl({matchPatterns:lS,defaultMatchWidth:"wide",parsePatterns:cS,defaultParseWidth:"any"}),dayPeriod:tl({matchPatterns:uS,defaultMatchWidth:"any",parsePatterns:hS,defaultParseWidth:"any"})},gg={code:"en-US",formatDistance:Dk,formatLong:jk,formatRelative:zk,localize:Xk,match:dS,options:{weekStartsOn:0,firstWeekContainsDate:1}};function fS(n,e){const t=vn(n,void 0);return Mk(t,Ik(t))+1}function mg(n,e){const t=vn(n,void 0),r=+ua(t)-+Lk(t);return Math.round(r/6048e5)+1}function fh(n,e){var t,r,l,d;const h=vn(n,e==null?void 0:e.in),b=h.getFullYear(),p=ca(),g=(e==null?void 0:e.firstWeekContainsDate)??((r=(t=e==null?void 0:e.locale)==null?void 0:t.options)==null?void 0:r.firstWeekContainsDate)??p.firstWeekContainsDate??((d=(l=p.locale)==null?void 0:l.options)==null?void 0:d.firstWeekContainsDate)??1,o=Kn((e==null?void 0:e.in)||n,0);o.setFullYear(b+1,0,g),o.setHours(0,0,0,0);const c=Go(o,e),f=Kn((e==null?void 0:e.in)||n,0);f.setFullYear(b,0,g),f.setHours(0,0,0,0);const u=Go(f,e);return+h>=+c?b+1:+h>=+u?b:b-1}function pS(n,e){var t,r,l,d;const h=ca(),b=(e==null?void 0:e.firstWeekContainsDate)??((r=(t=e==null?void 0:e.locale)==null?void 0:t.options)==null?void 0:r.firstWeekContainsDate)??h.firstWeekContainsDate??((d=(l=h.locale)==null?void 0:l.options)==null?void 0:d.firstWeekContainsDate)??1,p=fh(n,e),g=Kn((e==null?void 0:e.in)||n,0);return g.setFullYear(p,0,b),g.setHours(0,0,0,0),Go(g,e)}function vg(n,e){const t=vn(n,e==null?void 0:e.in),r=+Go(t,e)-+pS(t,e);return Math.round(r/6048e5)+1}function en(n,e){const t=n<0?"-":"",r=Math.abs(n).toString().padStart(e,"0");return t+r}const Yo={y(n,e){const t=n.getFullYear(),r=t>0?t:1-t;return en(e==="yy"?r%100:r,e.length)},M(n,e){const t=n.getMonth();return e==="M"?String(t+1):en(t+1,2)},d(n,e){return en(n.getDate(),e.length)},a(n,e){const t=n.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return t.toUpperCase();case"aaa":return t;case"aaaaa":return t[0];case"aaaa":default:return t==="am"?"a.m.":"p.m."}},h(n,e){return en(n.getHours()%12||12,e.length)},H(n,e){return en(n.getHours(),e.length)},m(n,e){return en(n.getMinutes(),e.length)},s(n,e){return en(n.getSeconds(),e.length)},S(n,e){const t=e.length,r=n.getMilliseconds(),l=Math.trunc(r*Math.pow(10,t-3));return en(l,e.length)}},ha={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},yg={G:function(n,e,t){const r=n.getFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return t.era(r,{width:"abbreviated"});case"GGGGG":return t.era(r,{width:"narrow"});case"GGGG":default:return t.era(r,{width:"wide"})}},y:function(n,e,t){if(e==="yo"){const r=n.getFullYear(),l=r>0?r:1-r;return t.ordinalNumber(l,{unit:"year"})}return Yo.y(n,e)},Y:function(n,e,t,r){const l=fh(n,r),d=l>0?l:1-l;if(e==="YY"){const h=d%100;return en(h,2)}return e==="Yo"?t.ordinalNumber(d,{unit:"year"}):en(d,e.length)},R:function(n,e){const t=dg(n);return en(t,e.length)},u:function(n,e){const t=n.getFullYear();return en(t,e.length)},Q:function(n,e,t){const r=Math.ceil((n.getMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return en(r,2);case"Qo":return t.ordinalNumber(r,{unit:"quarter"});case"QQQ":return t.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return t.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return t.quarter(r,{width:"wide",context:"formatting"})}},q:function(n,e,t){const r=Math.ceil((n.getMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return en(r,2);case"qo":return t.ordinalNumber(r,{unit:"quarter"});case"qqq":return t.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return t.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return t.quarter(r,{width:"wide",context:"standalone"})}},M:function(n,e,t){const r=n.getMonth();switch(e){case"M":case"MM":return Yo.M(n,e);case"Mo":return t.ordinalNumber(r+1,{unit:"month"});case"MMM":return t.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return t.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return t.month(r,{width:"wide",context:"formatting"})}},L:function(n,e,t){const r=n.getMonth();switch(e){case"L":return String(r+1);case"LL":return en(r+1,2);case"Lo":return t.ordinalNumber(r+1,{unit:"month"});case"LLL":return t.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return t.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return t.month(r,{width:"wide",context:"standalone"})}},w:function(n,e,t,r){const l=vg(n,r);return e==="wo"?t.ordinalNumber(l,{unit:"week"}):en(l,e.length)},I:function(n,e,t){const r=mg(n);return e==="Io"?t.ordinalNumber(r,{unit:"week"}):en(r,e.length)},d:function(n,e,t){return e==="do"?t.ordinalNumber(n.getDate(),{unit:"date"}):Yo.d(n,e)},D:function(n,e,t){const r=fS(n);return e==="Do"?t.ordinalNumber(r,{unit:"dayOfYear"}):en(r,e.length)},E:function(n,e,t){const r=n.getDay();switch(e){case"E":case"EE":case"EEE":return t.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return t.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return t.day(r,{width:"short",context:"formatting"});case"EEEE":default:return t.day(r,{width:"wide",context:"formatting"})}},e:function(n,e,t,r){const l=n.getDay(),d=(l-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(d);case"ee":return en(d,2);case"eo":return t.ordinalNumber(d,{unit:"day"});case"eee":return t.day(l,{width:"abbreviated",context:"formatting"});case"eeeee":return t.day(l,{width:"narrow",context:"formatting"});case"eeeeee":return t.day(l,{width:"short",context:"formatting"});case"eeee":default:return t.day(l,{width:"wide",context:"formatting"})}},c:function(n,e,t,r){const l=n.getDay(),d=(l-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(d);case"cc":return en(d,e.length);case"co":return t.ordinalNumber(d,{unit:"day"});case"ccc":return t.day(l,{width:"abbreviated",context:"standalone"});case"ccccc":return t.day(l,{width:"narrow",context:"standalone"});case"cccccc":return t.day(l,{width:"short",context:"standalone"});case"cccc":default:return t.day(l,{width:"wide",context:"standalone"})}},i:function(n,e,t){const r=n.getDay(),l=r===0?7:r;switch(e){case"i":return String(l);case"ii":return en(l,e.length);case"io":return t.ordinalNumber(l,{unit:"day"});case"iii":return t.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return t.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return t.day(r,{width:"short",context:"formatting"});case"iiii":default:return t.day(r,{width:"wide",context:"formatting"})}},a:function(n,e,t){const r=n.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return t.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return t.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return t.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaa":default:return t.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(n,e,t){const r=n.getHours();let l;switch(r===12?l=ha.noon:r===0?l=ha.midnight:l=r/12>=1?"pm":"am",e){case"b":case"bb":return t.dayPeriod(l,{width:"abbreviated",context:"formatting"});case"bbb":return t.dayPeriod(l,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return t.dayPeriod(l,{width:"narrow",context:"formatting"});case"bbbb":default:return t.dayPeriod(l,{width:"wide",context:"formatting"})}},B:function(n,e,t){const r=n.getHours();let l;switch(r>=17?l=ha.evening:r>=12?l=ha.afternoon:r>=4?l=ha.morning:l=ha.night,e){case"B":case"BB":case"BBB":return t.dayPeriod(l,{width:"abbreviated",context:"formatting"});case"BBBBB":return t.dayPeriod(l,{width:"narrow",context:"formatting"});case"BBBB":default:return t.dayPeriod(l,{width:"wide",context:"formatting"})}},h:function(n,e,t){if(e==="ho"){let r=n.getHours()%12;return r===0&&(r=12),t.ordinalNumber(r,{unit:"hour"})}return Yo.h(n,e)},H:function(n,e,t){return e==="Ho"?t.ordinalNumber(n.getHours(),{unit:"hour"}):Yo.H(n,e)},K:function(n,e,t){const r=n.getHours()%12;return e==="Ko"?t.ordinalNumber(r,{unit:"hour"}):en(r,e.length)},k:function(n,e,t){let r=n.getHours();return r===0&&(r=24),e==="ko"?t.ordinalNumber(r,{unit:"hour"}):en(r,e.length)},m:function(n,e,t){return e==="mo"?t.ordinalNumber(n.getMinutes(),{unit:"minute"}):Yo.m(n,e)},s:function(n,e,t){return e==="so"?t.ordinalNumber(n.getSeconds(),{unit:"second"}):Yo.s(n,e)},S:function(n,e){return Yo.S(n,e)},X:function(n,e,t){const r=n.getTimezoneOffset();if(r===0)return"Z";switch(e){case"X":return wg(r);case"XXXX":case"XX":return Ss(r);case"XXXXX":case"XXX":default:return Ss(r,":")}},x:function(n,e,t){const r=n.getTimezoneOffset();switch(e){case"x":return wg(r);case"xxxx":case"xx":return Ss(r);case"xxxxx":case"xxx":default:return Ss(r,":")}},O:function(n,e,t){const r=n.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+bg(r,":");case"OOOO":default:return"GMT"+Ss(r,":")}},z:function(n,e,t){const r=n.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+bg(r,":");case"zzzz":default:return"GMT"+Ss(r,":")}},t:function(n,e,t){const r=Math.trunc(+n/1e3);return en(r,e.length)},T:function(n,e,t){return en(+n,e.length)}};function bg(n,e=""){const t=n>0?"-":"+",r=Math.abs(n),l=Math.trunc(r/60),d=r%60;return d===0?t+String(l):t+String(l)+e+en(d,2)}function wg(n,e){return n%60===0?(n>0?"-":"+")+en(Math.abs(n)/60,2):Ss(n,e)}function Ss(n,e=""){const t=n>0?"-":"+",r=Math.abs(n),l=en(Math.trunc(r/60),2),d=en(r%60,2);return t+l+e+d}const xg=(n,e)=>{switch(n){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});case"PPPP":default:return e.date({width:"full"})}},kg=(n,e)=>{switch(n){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});case"pppp":default:return e.time({width:"full"})}},gS=(n,e)=>{const t=n.match(/(P+)(p+)?/)||[],r=t[1],l=t[2];if(!l)return xg(n,e);let d;switch(r){case"P":d=e.dateTime({width:"short"});break;case"PP":d=e.dateTime({width:"medium"});break;case"PPP":d=e.dateTime({width:"long"});break;case"PPPP":default:d=e.dateTime({width:"full"});break}return d.replace("{{date}}",xg(r,e)).replace("{{time}}",kg(l,e))},ph={p:kg,P:gS},mS=/^D+$/,vS=/^Y+$/,yS=["D","DD","YY","YYYY"];function Sg(n){return mS.test(n)}function _g(n){return vS.test(n)}function gh(n,e,t){const r=bS(n,e,t);if(console.warn(r),yS.includes(n))throw new RangeError(r)}function bS(n,e,t){const r=n[0]==="Y"?"years":"days of the month";return`Use \`${n.toLowerCase()}\` instead of \`${n}\` (in \`${e}\`) for formatting ${r} to the input \`${t}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const wS=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,xS=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,kS=/^'([^]*?)'?$/,SS=/''/g,_S=/[a-zA-Z]/;function _s(n,e,t){var r,l,d,h,b,p,g,o;const c=ca(),f=(t==null?void 0:t.locale)??c.locale??gg,u=(t==null?void 0:t.firstWeekContainsDate)??((l=(r=t==null?void 0:t.locale)==null?void 0:r.options)==null?void 0:l.firstWeekContainsDate)??c.firstWeekContainsDate??((h=(d=c.locale)==null?void 0:d.options)==null?void 0:h.firstWeekContainsDate)??1,i=(t==null?void 0:t.weekStartsOn)??((p=(b=t==null?void 0:t.locale)==null?void 0:b.options)==null?void 0:p.weekStartsOn)??c.weekStartsOn??((o=(g=c.locale)==null?void 0:g.options)==null?void 0:o.weekStartsOn)??0,a=vn(n,t==null?void 0:t.in);if(!pg(a))throw new RangeError("Invalid time value");let m=e.match(xS).map(x=>{const M=x[0];if(M==="p"||M==="P"){const $=ph[M];return $(x,f.formatLong)}return x}).join("").match(wS).map(x=>{if(x==="''")return{isToken:!1,value:"'"};const M=x[0];if(M==="'")return{isToken:!1,value:CS(x)};if(yg[M])return{isToken:!0,value:x};if(M.match(_S))throw new RangeError("Format string contains an unescaped latin alphabet character `"+M+"`");return{isToken:!1,value:x}});f.localize.preprocessor&&(m=f.localize.preprocessor(a,m));const w={firstWeekContainsDate:u,weekStartsOn:i,locale:f};return m.map(x=>{if(!x.isToken)return x.value;const M=x.value;(!(t!=null&&t.useAdditionalWeekYearTokens)&&_g(M)||!(t!=null&&t.useAdditionalDayOfYearTokens)&&Sg(M))&&gh(M,e,String(n));const $=yg[M[0]];return $(a,M,f.localize,w)}).join("")}function CS(n){const e=n.match(kS);return e?e[1].replace(SS,"'"):n}var Xo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function lc(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Cg={exports:{}},$g;function $S(){return $g||($g=1,function(n,e){(function(){var t="ace",r=function(){return this}();!r&&typeof window<"u"&&(r=window);var l=function(o,c,f){if(typeof o!="string"){l.original?l.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace());return}arguments.length==2&&(f=c),l.modules[o]||(l.payloads[o]=f,l.modules[o]=null)};l.modules={},l.payloads={};var d=function(o,c,f){if(typeof c=="string"){var u=p(o,c);if(u!=null)return f&&f(),u}else if(Object.prototype.toString.call(c)==="[object Array]"){for(var i=[],a=0,m=c.length;a<m;++a){var w=p(o,c[a]);if(w==null&&h.original)return;i.push(w)}return f&&f.apply(null,i)||!0}},h=function(o,c){var f=d("",o,c);return f==null&&h.original?h.original.apply(this,arguments):f},b=function(o,c){if(c.indexOf("!")!==-1){var f=c.split("!");return b(o,f[0])+"!"+b(o,f[1])}if(c.charAt(0)=="."){var u=o.split("/").slice(0,-1).join("/");for(c=u+"/"+c;c.indexOf(".")!==-1&&i!=c;){var i=c;c=c.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return c},p=function(o,c){c=b(o,c);var f=l.modules[c];if(!f){if(f=l.payloads[c],typeof f=="function"){var u={},i={id:c,uri:"",exports:u,packaged:!0},a=function(w,x){return d(c,w,x)},m=f(a,u,i);u=m||i.exports,l.modules[c]=u,delete l.payloads[c]}f=l.modules[c]=u||f}return f};function g(o){var c=r;r[o]||(r[o]={}),c=r[o],(!c.define||!c.define.packaged)&&(l.original=c.define,c.define=l,c.define.packaged=!0),(!c.require||!c.require.packaged)&&(h.original=c.require,c.require=h,c.require.packaged=!0)}g(t)})(),ace.define("ace/lib/es6-shim",["require","exports","module"],function(t,r,l){function d(h,b,p){Object.defineProperty(h,b,{value:p,enumerable:!1,writable:!0,configurable:!0})}String.prototype.startsWith||d(String.prototype,"startsWith",function(h,b){return b=b||0,this.lastIndexOf(h,b)===b}),String.prototype.endsWith||d(String.prototype,"endsWith",function(h,b){var p=this;(b===void 0||b>p.length)&&(b=p.length),b-=h.length;var g=p.indexOf(h,b);return g!==-1&&g===b}),String.prototype.repeat||d(String.prototype,"repeat",function(h){for(var b="",p=this;h>0;)h&1&&(b+=p),(h>>=1)&&(p+=p);return b}),String.prototype.includes||d(String.prototype,"includes",function(h,b){return this.indexOf(h,b)!=-1}),Object.assign||(Object.assign=function(h){if(h==null)throw new TypeError("Cannot convert undefined or null to object");for(var b=Object(h),p=1;p<arguments.length;p++){var g=arguments[p];g!=null&&Object.keys(g).forEach(function(o){b[o]=g[o]})}return b}),Object.values||(Object.values=function(h){return Object.keys(h).map(function(b){return h[b]})}),Array.prototype.find||d(Array.prototype,"find",function(h){for(var b=this.length,p=arguments[1],g=0;g<b;g++){var o=this[g];if(h.call(p,o,g,this))return o}}),Array.prototype.findIndex||d(Array.prototype,"findIndex",function(h){for(var b=this.length,p=arguments[1],g=0;g<b;g++){var o=this[g];if(h.call(p,o,g,this))return g}}),Array.prototype.includes||d(Array.prototype,"includes",function(h,b){return this.indexOf(h,b)!=-1}),Array.prototype.fill||d(Array.prototype,"fill",function(h){for(var b=this,p=b.length>>>0,g=arguments[1],o=g>>0,c=o<0?Math.max(p+o,0):Math.min(o,p),f=arguments[2],u=f===void 0?p:f>>0,i=u<0?Math.max(p+u,0):Math.min(u,p);c<i;)b[c]=h,c++;return b}),Array.of||d(Array,"of",function(){return Array.prototype.slice.call(arguments)})}),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/es6-shim"],function(t,r,l){t("./es6-shim")}),ace.define("ace/lib/deep_copy",["require","exports","module"],function(t,r,l){r.deepCopy=function d(h){if(typeof h!="object"||!h)return h;var b;if(Array.isArray(h)){b=[];for(var p=0;p<h.length;p++)b[p]=d(h[p]);return b}if(Object.prototype.toString.call(h)!=="[object Object]")return h;b={};for(var p in h)b[p]=d(h[p]);return b}}),ace.define("ace/lib/lang",["require","exports","module","ace/lib/deep_copy"],function(t,r,l){r.last=function(b){return b[b.length-1]},r.stringReverse=function(b){return b.split("").reverse().join("")},r.stringRepeat=function(b,p){for(var g="";p>0;)p&1&&(g+=b),(p>>=1)&&(b+=b);return g};var d=/^\s\s*/,h=/\s\s*$/;r.stringTrimLeft=function(b){return b.replace(d,"")},r.stringTrimRight=function(b){return b.replace(h,"")},r.copyObject=function(b){var p={};for(var g in b)p[g]=b[g];return p},r.copyArray=function(b){for(var p=[],g=0,o=b.length;g<o;g++)b[g]&&typeof b[g]=="object"?p[g]=this.copyObject(b[g]):p[g]=b[g];return p},r.deepCopy=t("./deep_copy").deepCopy,r.arrayToMap=function(b){for(var p={},g=0;g<b.length;g++)p[b[g]]=1;return p},r.createMap=function(b){var p=Object.create(null);for(var g in b)p[g]=b[g];return p},r.arrayRemove=function(b,p){for(var g=0;g<=b.length;g++)p===b[g]&&b.splice(g,1)},r.escapeRegExp=function(b){return b.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},r.escapeHTML=function(b){return(""+b).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<")},r.getMatchOffsets=function(b,p){var g=[];return b.replace(p,function(o){g.push({offset:arguments[arguments.length-2],length:o.length})}),g},r.deferredCall=function(b){var p=null,g=function(){p=null,b()},o=function(c){return o.cancel(),p=setTimeout(g,c||0),o};return o.schedule=o,o.call=function(){return this.cancel(),b(),o},o.cancel=function(){return clearTimeout(p),p=null,o},o.isPending=function(){return p},o},r.delayedCall=function(b,p){var g=null,o=function(){g=null,b()},c=function(f){g==null&&(g=setTimeout(o,f||p))};return c.delay=function(f){g&&clearTimeout(g),g=setTimeout(o,f||p)},c.schedule=c,c.call=function(){this.cancel(),b()},c.cancel=function(){g&&clearTimeout(g),g=null},c.isPending=function(){return g},c},r.supportsLookbehind=function(){try{new RegExp("(?<=.)")}catch{return!1}return!0},r.skipEmptyMatch=function(b,p,g){return g&&b.codePointAt(p)>65535?2:1}}),ace.define("ace/lib/useragent",["require","exports","module"],function(t,r,l){r.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},r.getOS=function(){return r.isMac?r.OS.MAC:r.isLinux?r.OS.LINUX:r.OS.WINDOWS};var d=typeof navigator=="object"?navigator:{},h=(/mac|win|linux/i.exec(d.platform)||["other"])[0].toLowerCase(),b=d.userAgent||"",p=d.appName||"";r.isWin=h=="win",r.isMac=h=="mac",r.isLinux=h=="linux",r.isIE=p=="Microsoft Internet Explorer"||p.indexOf("MSAppHost")>=0?parseFloat((b.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((b.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),r.isOldIE=r.isIE&&r.isIE<9,r.isGecko=r.isMozilla=b.match(/ Gecko\/\d+/),r.isOpera=typeof opera=="object"&&Object.prototype.toString.call(window.opera)=="[object Opera]",r.isWebKit=parseFloat(b.split("WebKit/")[1])||void 0,r.isChrome=parseFloat(b.split(" Chrome/")[1])||void 0,r.isSafari=parseFloat(b.split(" Safari/")[1])&&!r.isChrome||void 0,r.isEdge=parseFloat(b.split(" Edge/")[1])||void 0,r.isAIR=b.indexOf("AdobeAIR")>=0,r.isAndroid=b.indexOf("Android")>=0,r.isChromeOS=b.indexOf(" CrOS ")>=0,r.isIOS=/iPad|iPhone|iPod/.test(b)&&!window.MSStream,r.isIOS&&(r.isMac=!0),r.isMobile=r.isIOS||r.isAndroid}),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],function(t,r,l){var d=t("./useragent"),h="http://www.w3.org/1999/xhtml";r.buildDom=function f(u,i,a){if(typeof u=="string"&&u){var m=document.createTextNode(u);return i&&i.appendChild(m),m}if(!Array.isArray(u))return u&&u.appendChild&&i&&i.appendChild(u),u;if(typeof u[0]!="string"||!u[0]){for(var w=[],x=0;x<u.length;x++){var M=f(u[x],i,a);M&&w.push(M)}return w}var $=document.createElement(u[0]),S=u[1],k=1;S&&typeof S=="object"&&!Array.isArray(S)&&(k=2);for(var x=k;x<u.length;x++)f(u[x],$,a);return k==2&&Object.keys(S).forEach(function(T){var D=S[T];T==="class"?$.className=Array.isArray(D)?D.join(" "):D:typeof D=="function"||T=="value"||T[0]=="$"?$[T]=D:T==="ref"?a&&(a[D]=$):T==="style"?typeof D=="string"&&($.style.cssText=D):D!=null&&$.setAttribute(T,D)}),i&&i.appendChild($),$},r.getDocumentHead=function(f){return f||(f=document),f.head||f.getElementsByTagName("head")[0]||f.documentElement},r.createElement=function(f,u){return document.createElementNS?document.createElementNS(u||h,f):document.createElement(f)},r.removeChildren=function(f){f.innerHTML=""},r.createTextNode=function(f,u){var i=u?u.ownerDocument:document;return i.createTextNode(f)},r.createFragment=function(f){var u=f?f.ownerDocument:document;return u.createDocumentFragment()},r.hasCssClass=function(f,u){var i=(f.className+"").split(/\s+/g);return i.indexOf(u)!==-1},r.addCssClass=function(f,u){r.hasCssClass(f,u)||(f.className+=" "+u)},r.removeCssClass=function(f,u){for(var i=f.className.split(/\s+/g);;){var a=i.indexOf(u);if(a==-1)break;i.splice(a,1)}f.className=i.join(" ")},r.toggleCssClass=function(f,u){for(var i=f.className.split(/\s+/g),a=!0;;){var m=i.indexOf(u);if(m==-1)break;a=!1,i.splice(m,1)}return a&&i.push(u),f.className=i.join(" "),a},r.setCssClass=function(f,u,i){i?r.addCssClass(f,u):r.removeCssClass(f,u)},r.hasCssString=function(f,u){var i=0,a;if(u=u||document,a=u.querySelectorAll("style")){for(;i<a.length;)if(a[i++].id===f)return!0}},r.removeElementById=function(f,u){u=u||document,u.getElementById(f)&&u.getElementById(f).remove()};var b,p=[];r.useStrictCSP=function(f){b=f,f==!1?g():p||(p=[])};function g(){var f=p;p=null,f&&f.forEach(function(u){o(u[0],u[1])})}function o(f,u,i){if(!(typeof document>"u")){if(p){if(i)g();else if(i===!1)return p.push([f,u])}if(!b){var a=i;!i||!i.getRootNode?a=document:(a=i.getRootNode(),(!a||a==i)&&(a=document));var m=a.ownerDocument||a;if(u&&r.hasCssString(u,a))return null;u&&(f+=`
|
|
8
|
+
/*# sourceURL=ace/css/`+u+" */");var w=r.createElement("style");w.appendChild(m.createTextNode(f)),u&&(w.id=u),a==m&&(a=r.getDocumentHead(m)),a.insertBefore(w,a.firstChild)}}}if(r.importCssString=o,r.importCssStylsheet=function(f,u){r.buildDom(["link",{rel:"stylesheet",href:f}],r.getDocumentHead(u))},r.$fixPositionBug=function(f){var u=f.getBoundingClientRect();if(f.style.left){var i=parseFloat(f.style.left),a=+u.left;Math.abs(i-a)>1&&(f.style.left=2*i-a+"px")}if(f.style.right){var i=parseFloat(f.style.right),a=window.innerWidth-u.right;Math.abs(i-a)>1&&(f.style.right=2*i-a+"px")}if(f.style.top){var i=parseFloat(f.style.top),a=+u.top;Math.abs(i-a)>1&&(f.style.top=2*i-a+"px")}if(f.style.bottom){var i=parseFloat(f.style.bottom),a=window.innerHeight-u.bottom;Math.abs(i-a)>1&&(f.style.bottom=2*i-a+"px")}},r.scrollbarWidth=function(f){var u=r.createElement("ace_inner");u.style.width="100%",u.style.minWidth="0px",u.style.height="200px",u.style.display="block";var i=r.createElement("ace_outer"),a=i.style;a.position="absolute",a.left="-10000px",a.overflow="hidden",a.width="200px",a.minWidth="0px",a.height="150px",a.display="block",i.appendChild(u);var m=f&&f.documentElement||document&&document.documentElement;if(!m)return 0;m.appendChild(i);var w=u.offsetWidth;a.overflow="scroll";var x=u.offsetWidth;return w===x&&(x=i.clientWidth),m.removeChild(i),w-x},r.computedStyle=function(f,u){return window.getComputedStyle(f,"")||{}},r.setStyle=function(f,u,i){f[u]!==i&&(f[u]=i)},r.HAS_CSS_ANIMATION=!1,r.HAS_CSS_TRANSFORMS=!1,r.HI_DPI=d.isWin?typeof window<"u"&&window.devicePixelRatio>=1.5:!0,d.isChromeOS&&(r.HI_DPI=!1),typeof document<"u"){var c=document.createElement("div");r.HI_DPI&&c.style.transform!==void 0&&(r.HAS_CSS_TRANSFORMS=!0),!d.isEdge&&typeof c.style.animationName<"u"&&(r.HAS_CSS_ANIMATION=!0),c=null}r.HAS_CSS_TRANSFORMS?r.translate=function(f,u,i){f.style.transform="translate("+Math.round(u)+"px, "+Math.round(i)+"px)"}:r.translate=function(f,u,i){f.style.top=Math.round(i)+"px",f.style.left=Math.round(u)+"px"}}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(t,r,l){/*
|
|
9
|
+
* based on code from:
|
|
10
|
+
*
|
|
11
|
+
* @license RequireJS text 0.25.0 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.
|
|
12
|
+
* Available via the MIT or new BSD license.
|
|
13
|
+
* see: http://github.com/jrburke/requirejs for details
|
|
14
|
+
*/var d=t("./dom");r.get=function(h,b){var p=new XMLHttpRequest;p.open("GET",h,!0),p.onreadystatechange=function(){p.readyState===4&&b(p.responseText)},p.send(null)},r.loadScript=function(h,b){var p=d.getDocumentHead(),g=document.createElement("script");g.src=h,p.appendChild(g),g.onload=g.onreadystatechange=function(o,c){(c||!g.readyState||g.readyState=="loaded"||g.readyState=="complete")&&(g=g.onload=g.onreadystatechange=null,c||b())}},r.qualifyURL=function(h){var b=document.createElement("a");return b.href=h,b.href}}),ace.define("ace/lib/oop",["require","exports","module"],function(t,r,l){r.inherits=function(d,h){d.super_=h,d.prototype=Object.create(h.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}})},r.mixin=function(d,h){for(var b in h)d[b]=h[b];return d},r.implement=function(d,h){r.mixin(d,h)}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(t,r,l){var d={},h=function(){this.propagationStopped=!0},b=function(){this.defaultPrevented=!0};d._emit=d._dispatchEvent=function(p,g){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var o=this._eventRegistry[p]||[],c=this._defaultHandlers[p];if(!(!o.length&&!c)){(typeof g!="object"||!g)&&(g={}),g.type||(g.type=p),g.stopPropagation||(g.stopPropagation=h),g.preventDefault||(g.preventDefault=b),o=o.slice();for(var f=0;f<o.length&&(o[f](g,this),!g.propagationStopped);f++);if(c&&!g.defaultPrevented)return c(g,this)}},d._signal=function(p,g){var o=(this._eventRegistry||{})[p];if(o){o=o.slice();for(var c=0;c<o.length;c++)o[c](g,this)}},d.once=function(p,g){var o=this;if(this.on(p,function c(){o.off(p,c),g.apply(null,arguments)}),!g)return new Promise(function(c){g=c})},d.setDefaultHandler=function(p,g){var o=this._defaultHandlers;if(o||(o=this._defaultHandlers={_disabled_:{}}),o[p]){var c=o[p],f=o._disabled_[p];f||(o._disabled_[p]=f=[]),f.push(c);var u=f.indexOf(g);u!=-1&&f.splice(u,1)}o[p]=g},d.removeDefaultHandler=function(p,g){var o=this._defaultHandlers;if(o){var c=o._disabled_[p];if(o[p]==g)c&&this.setDefaultHandler(p,c.pop());else if(c){var f=c.indexOf(g);f!=-1&&c.splice(f,1)}}},d.on=d.addEventListener=function(p,g,o){this._eventRegistry=this._eventRegistry||{};var c=this._eventRegistry[p];return c||(c=this._eventRegistry[p]=[]),c.indexOf(g)==-1&&c[o?"unshift":"push"](g),g},d.off=d.removeListener=d.removeEventListener=function(p,g){this._eventRegistry=this._eventRegistry||{};var o=this._eventRegistry[p];if(o){var c=o.indexOf(g);c!==-1&&o.splice(c,1)}},d.removeAllListeners=function(p){p||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[p]=void 0),this._defaultHandlers&&(this._defaultHandlers[p]=void 0)},r.EventEmitter=d}),ace.define("ace/lib/report_error",["require","exports","module"],function(t,r,l){r.reportError=function(d,h){var b=new Error(d);b.data=h,typeof console=="object"&&console.error&&console.error(b),setTimeout(function(){throw b})}}),ace.define("ace/lib/default_english_messages",["require","exports","module"],function(t,r,l){var d={"autocomplete.popup.aria-roledescription":"Autocomplete suggestions","autocomplete.popup.aria-label":"Autocomplete suggestions","autocomplete.popup.item.aria-roledescription":"item","autocomplete.loading":"Loading...","editor.scroller.aria-roledescription":"editor","editor.scroller.aria-label":"Editor content, press Enter to start editing, press Escape to exit","editor.gutter.aria-roledescription":"editor gutter","editor.gutter.aria-label":"Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit","error-marker.good-state":"Looks good!","prompt.recently-used":"Recently used","prompt.other-commands":"Other commands","prompt.no-matching-commands":"No matching commands","search-box.find.placeholder":"Search for","search-box.find-all.text":"All","search-box.replace.placeholder":"Replace with","search-box.replace-next.text":"Replace","search-box.replace-all.text":"All","search-box.toggle-replace.title":"Toggle Replace mode","search-box.toggle-regexp.title":"RegExp Search","search-box.toggle-case.title":"CaseSensitive Search","search-box.toggle-whole-word.title":"Whole Word Search","search-box.toggle-in-selection.title":"Search In Selection","search-box.search-counter":"$0 of $1","text-input.aria-roledescription":"editor","text-input.aria-label":"Cursor at row $0","gutter.code-folding.range.aria-label":"Toggle code folding, rows $0 through $1","gutter.code-folding.closed.aria-label":"Toggle code folding, rows $0 through $1","gutter.code-folding.open.aria-label":"Toggle code folding, row $0","gutter.code-folding.closed.title":"Unfold code","gutter.code-folding.open.title":"Fold code","gutter.annotation.aria-label.error":"Error, read annotations row $0","gutter.annotation.aria-label.warning":"Warning, read annotations row $0","gutter.annotation.aria-label.info":"Info, read annotations row $0","inline-fold.closed.title":"Unfold code","gutter-tooltip.aria-label.error.singular":"error","gutter-tooltip.aria-label.error.plural":"errors","gutter-tooltip.aria-label.warning.singular":"warning","gutter-tooltip.aria-label.warning.plural":"warnings","gutter-tooltip.aria-label.info.singular":"information message","gutter-tooltip.aria-label.info.plural":"information messages","gutter.annotation.aria-label.security":"Security finding, read annotations row $0","gutter.annotation.aria-label.hint":"Suggestion, read annotations row $0","gutter-tooltip.aria-label.security.singular":"security finding","gutter-tooltip.aria-label.security.plural":"security findings","gutter-tooltip.aria-label.hint.singular":"suggestion","gutter-tooltip.aria-label.hint.plural":"suggestions","editor.tooltip.disable-editing":"Editing is disabled"};r.defaultEnglishMessages=d}),ace.define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/report_error","ace/lib/default_english_messages"],function(t,r,l){"no use strict";var d=t("./oop"),h=t("./event_emitter").EventEmitter,b=t("./report_error").reportError,p=t("./default_english_messages").defaultEnglishMessages,g={setOptions:function(i){Object.keys(i).forEach(function(a){this.setOption(a,i[a])},this)},getOptions:function(i){var a={};if(i)Array.isArray(i)||(i=Object.keys(i));else{var m=this.$options;i=Object.keys(m).filter(function(w){return!m[w].hidden})}return i.forEach(function(w){a[w]=this.getOption(w)},this),a},setOption:function(i,a){if(this["$"+i]!==a){var m=this.$options[i];if(!m)return o('misspelled option "'+i+'"');if(m.forwardTo)return this[m.forwardTo]&&this[m.forwardTo].setOption(i,a);m.handlesSet||(this["$"+i]=a),m&&m.set&&m.set.call(this,a)}},getOption:function(i){var a=this.$options[i];return a?a.forwardTo?this[a.forwardTo]&&this[a.forwardTo].getOption(i):a&&a.get?a.get.call(this):this["$"+i]:o('misspelled option "'+i+'"')}};function o(i){typeof console<"u"&&console.warn&&console.warn.apply(console,arguments)}var c,f,u=function(){function i(){this.$defaultOptions={},c=p,f="dollarSigns"}return i.prototype.defineOptions=function(a,m,w){return a.$options||(this.$defaultOptions[m]=a.$options={}),Object.keys(w).forEach(function(x){var M=w[x];typeof M=="string"&&(M={forwardTo:M}),M.name||(M.name=x),a.$options[M.name]=M,"initialValue"in M&&(a["$"+M.name]=M.initialValue)}),d.implement(a,g),this},i.prototype.resetOptions=function(a){Object.keys(a.$options).forEach(function(m){var w=a.$options[m];"value"in w&&a.setOption(m,w.value)})},i.prototype.setDefaultValue=function(a,m,w){if(!a){for(a in this.$defaultOptions)if(this.$defaultOptions[a][m])break;if(!this.$defaultOptions[a][m])return!1}var x=this.$defaultOptions[a]||(this.$defaultOptions[a]={});x[m]&&(x.forwardTo?this.setDefaultValue(x.forwardTo,m,w):x[m].value=w)},i.prototype.setDefaultValues=function(a,m){Object.keys(m).forEach(function(w){this.setDefaultValue(a,w,m[w])},this)},i.prototype.setMessages=function(a,m){c=a,m&&m.placeholders&&(f=m.placeholders)},i.prototype.nls=function(a,m,w){c[a]||(o("No message found for the key '"+a+"' in messages with id "+c.$id+", trying to find a translation for the default string '"+m+"'."),c[m]||o("No message found for the default string '"+m+"' in the provided messages. Falling back to the default English message."));var x=c[a]||c[m]||m;return w&&(f==="dollarSigns"&&(x=x.replace(/\$(\$|[\d]+)/g,function(M,$){return $=="$"?"$":w[$]})),f==="curlyBrackets"&&(x=x.replace(/\{([^\}]+)\}/g,function(M,$){return w[$]}))),x},i}();u.prototype.warn=o,u.prototype.reportError=b,d.implement(u.prototype,h),r.AppConfig=u}),ace.define("ace/theme/textmate-css",["require","exports","module"],function(t,r,l){l.exports=`.ace-tm .ace_gutter {
|
|
15
|
+
background: #f0f0f0;
|
|
16
|
+
color: #333;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.ace-tm .ace_print-margin {
|
|
20
|
+
width: 1px;
|
|
21
|
+
background: #e8e8e8;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.ace-tm .ace_fold {
|
|
25
|
+
background-color: #6B72E6;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.ace-tm {
|
|
29
|
+
background-color: #FFFFFF;
|
|
30
|
+
color: black;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.ace-tm .ace_cursor {
|
|
34
|
+
color: black;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.ace-tm .ace_invisible {
|
|
38
|
+
color: rgb(191, 191, 191);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.ace-tm .ace_storage,
|
|
42
|
+
.ace-tm .ace_keyword {
|
|
43
|
+
color: blue;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.ace-tm .ace_constant {
|
|
47
|
+
color: rgb(197, 6, 11);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.ace-tm .ace_constant.ace_buildin {
|
|
51
|
+
color: rgb(88, 72, 246);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.ace-tm .ace_constant.ace_language {
|
|
55
|
+
color: rgb(88, 92, 246);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.ace-tm .ace_constant.ace_library {
|
|
59
|
+
color: rgb(6, 150, 14);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.ace-tm .ace_invalid {
|
|
63
|
+
background-color: rgba(255, 0, 0, 0.1);
|
|
64
|
+
color: red;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.ace-tm .ace_support.ace_function {
|
|
68
|
+
color: rgb(60, 76, 114);
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.ace-tm .ace_support.ace_constant {
|
|
72
|
+
color: rgb(6, 150, 14);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.ace-tm .ace_support.ace_type,
|
|
76
|
+
.ace-tm .ace_support.ace_class {
|
|
77
|
+
color: rgb(109, 121, 222);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.ace-tm .ace_keyword.ace_operator {
|
|
81
|
+
color: rgb(104, 118, 135);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.ace-tm .ace_string {
|
|
85
|
+
color: rgb(3, 106, 7);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.ace-tm .ace_comment {
|
|
89
|
+
color: rgb(76, 136, 107);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.ace-tm .ace_comment.ace_doc {
|
|
93
|
+
color: rgb(0, 102, 255);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.ace-tm .ace_comment.ace_doc.ace_tag {
|
|
97
|
+
color: rgb(128, 159, 191);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.ace-tm .ace_constant.ace_numeric {
|
|
101
|
+
color: rgb(0, 0, 205);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.ace-tm .ace_variable {
|
|
105
|
+
color: rgb(49, 132, 149);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.ace-tm .ace_xml-pe {
|
|
109
|
+
color: rgb(104, 104, 91);
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.ace-tm .ace_entity.ace_name.ace_function {
|
|
113
|
+
color: #0000A2;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
.ace-tm .ace_heading {
|
|
118
|
+
color: rgb(12, 7, 255);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.ace-tm .ace_list {
|
|
122
|
+
color:rgb(185, 6, 144);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
.ace-tm .ace_meta.ace_tag {
|
|
126
|
+
color:rgb(0, 22, 142);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.ace-tm .ace_string.ace_regex {
|
|
130
|
+
color: rgb(255, 0, 0)
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.ace-tm .ace_marker-layer .ace_selection {
|
|
134
|
+
background: rgb(181, 213, 255);
|
|
135
|
+
}
|
|
136
|
+
.ace-tm.ace_multiselect .ace_selection.ace_start {
|
|
137
|
+
box-shadow: 0 0 3px 0px white;
|
|
138
|
+
}
|
|
139
|
+
.ace-tm .ace_marker-layer .ace_step {
|
|
140
|
+
background: rgb(252, 255, 0);
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.ace-tm .ace_marker-layer .ace_stack {
|
|
144
|
+
background: rgb(164, 229, 101);
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.ace-tm .ace_marker-layer .ace_bracket {
|
|
148
|
+
margin: -1px 0 0 -1px;
|
|
149
|
+
border: 1px solid rgb(192, 192, 192);
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
.ace-tm .ace_marker-layer .ace_active-line {
|
|
153
|
+
background: rgba(0, 0, 0, 0.07);
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.ace-tm .ace_gutter-active-line {
|
|
157
|
+
background-color : #dcdcdc;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.ace-tm .ace_marker-layer .ace_selected-word {
|
|
161
|
+
background: rgb(250, 250, 255);
|
|
162
|
+
border: 1px solid rgb(200, 200, 250);
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.ace-tm .ace_indent-guide {
|
|
166
|
+
background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.ace-tm .ace_indent-guide-active {
|
|
170
|
+
background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC") right repeat-y;
|
|
171
|
+
}
|
|
172
|
+
`}),ace.define("ace/theme/textmate",["require","exports","module","ace/theme/textmate-css","ace/lib/dom"],function(t,r,l){r.isDark=!1,r.cssClass="ace-tm",r.cssText=t("./textmate-css"),r.$id="ace/theme/textmate";var d=t("../lib/dom");d.importCssString(r.cssText,r.cssClass,!1)}),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/net","ace/lib/dom","ace/lib/app_config","ace/theme/textmate"],function(t,r,l){"no use strict";var d=t("./lib/lang"),h=t("./lib/net"),b=t("./lib/dom"),p=t("./lib/app_config").AppConfig;l.exports=r=new p;var g={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{},loadWorkerFromBlob:!0,sharedPopups:!1,useStrictCSP:null};r.get=function(u){if(!g.hasOwnProperty(u))throw new Error("Unknown config key: "+u);return g[u]},r.set=function(u,i){if(g.hasOwnProperty(u))g[u]=i;else if(this.setDefaultValue("",u,i)==!1)throw new Error("Unknown config key: "+u);u=="useStrictCSP"&&b.useStrictCSP(i)},r.all=function(){return d.copyObject(g)},r.$modes={},r.moduleUrl=function(u,i){if(g.$moduleUrls[u])return g.$moduleUrls[u];var a=u.split("/");i=i||a[a.length-2]||"";var m=i=="snippets"?"/":"-",w=a[a.length-1];if(i=="worker"&&m=="-"){var x=new RegExp("^"+i+"[\\-_]|[\\-_]"+i+"$","g");w=w.replace(x,"")}(!w||w==i)&&a.length>1&&(w=a[a.length-2]);var M=g[i+"Path"];return M==null?M=g.basePath:m=="/"&&(i=m=""),M&&M.slice(-1)!="/"&&(M+="/"),M+i+m+w+this.get("suffix")},r.setModuleUrl=function(u,i){return g.$moduleUrls[u]=i};var o=function(u,i){if(u==="ace/theme/textmate"||u==="./theme/textmate")return i(null,t("./theme/textmate"));if(c)return c(u,i);console.error("loader is not configured")},c;r.setLoader=function(u){c=u},r.dynamicModules=Object.create(null),r.$loading={},r.$loaded={},r.loadModule=function(u,i){var a;if(Array.isArray(u))var m=u[0],w=u[1];else if(typeof u=="string")var w=u;var x=function(M){if(M&&!r.$loading[w])return i&&i(M);if(r.$loading[w]||(r.$loading[w]=[]),r.$loading[w].push(i),!(r.$loading[w].length>1)){var $=function(){o(w,function(S,k){k&&(r.$loaded[w]=k),r._emit("load.module",{name:w,module:k});var T=r.$loading[w];r.$loading[w]=null,T.forEach(function(D){D&&D(k)})})};if(!r.get("packaged"))return $();h.loadScript(r.moduleUrl(w,m),$),f()}};if(r.dynamicModules[w])r.dynamicModules[w]().then(function(M){M.default?x(M.default):x(M)});else{try{a=this.$require(w)}catch{}x(a||r.$loaded[w])}},r.$require=function(u){if(typeof l.require=="function"){var i="require";return l[i](u)}},r.setModuleLoader=function(u,i){r.dynamicModules[u]=i};var f=function(){!g.basePath&&!g.workerPath&&!g.modePath&&!g.themePath&&!Object.keys(g.$moduleUrls).length&&(console.error("Unable to infer path to ace from script src,","use ace.config.set('basePath', 'path') to enable dynamic loading of modes and themes","or with webpack use ace/webpack-resolver"),f=function(){})};r.version="1.43.4"}),ace.define("ace/loader_build",["require","exports","module","ace/lib/fixoldbrowsers","ace/config"],function(t,r,l){t("./lib/fixoldbrowsers");var d=t("./config");d.setLoader(function(g,o){t([g],function(c){o(null,c)})});var h=function(){return this||typeof window<"u"&&window}();l.exports=function(g){d.init=b,d.$require=t,g.require=t},b(!0);function b(g){if(!(!h||!h.document)){d.set("packaged",g||t.packaged||l.packaged||h.define&&(void 0).packaged);var o={},c="",f=document.currentScript||document._currentScript,u=f&&f.ownerDocument||document;f&&f.src&&(c=f.src.split(/[?#]/)[0].split("/").slice(0,-1).join("/")||"");for(var i=u.getElementsByTagName("script"),a=0;a<i.length;a++){var m=i[a],w=m.src||m.getAttribute("src");if(w){for(var x=m.attributes,M=0,$=x.length;M<$;M++){var S=x[M];S.name.indexOf("data-ace-")===0&&(o[p(S.name.replace(/^data-ace-/,""))]=S.value)}var k=w.match(/^(.*)\/ace([\-.]\w+)?\.js(\?|$)/);k&&(c=k[1])}}c&&(o.base=o.base||c,o.packaged=!0),o.basePath=o.base,o.workerPath=o.workerPath||o.base,o.modePath=o.modePath||o.base,o.themePath=o.themePath||o.base,delete o.base;for(var T in o)typeof o[T]<"u"&&d.set(T,o[T])}}function p(g){return g.replace(/-(.)/g,function(o,c){return c.toUpperCase()})}}),ace.define("ace/range",["require","exports","module"],function(t,r,l){var d=function(){function h(b,p,g,o){this.start={row:b,column:p},this.end={row:g,column:o}}return h.prototype.isEqual=function(b){return this.start.row===b.start.row&&this.end.row===b.end.row&&this.start.column===b.start.column&&this.end.column===b.end.column},h.prototype.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},h.prototype.contains=function(b,p){return this.compare(b,p)==0},h.prototype.compareRange=function(b){var p,g=b.end,o=b.start;return p=this.compare(g.row,g.column),p==1?(p=this.compare(o.row,o.column),p==1?2:p==0?1:0):p==-1?-2:(p=this.compare(o.row,o.column),p==-1?-1:p==1?42:0)},h.prototype.comparePoint=function(b){return this.compare(b.row,b.column)},h.prototype.containsRange=function(b){return this.comparePoint(b.start)==0&&this.comparePoint(b.end)==0},h.prototype.intersects=function(b){var p=this.compareRange(b);return p==-1||p==0||p==1},h.prototype.isEnd=function(b,p){return this.end.row==b&&this.end.column==p},h.prototype.isStart=function(b,p){return this.start.row==b&&this.start.column==p},h.prototype.setStart=function(b,p){typeof b=="object"?(this.start.column=b.column,this.start.row=b.row):(this.start.row=b,this.start.column=p)},h.prototype.setEnd=function(b,p){typeof b=="object"?(this.end.column=b.column,this.end.row=b.row):(this.end.row=b,this.end.column=p)},h.prototype.inside=function(b,p){return this.compare(b,p)==0?!(this.isEnd(b,p)||this.isStart(b,p)):!1},h.prototype.insideStart=function(b,p){return this.compare(b,p)==0?!this.isEnd(b,p):!1},h.prototype.insideEnd=function(b,p){return this.compare(b,p)==0?!this.isStart(b,p):!1},h.prototype.compare=function(b,p){return!this.isMultiLine()&&b===this.start.row?p<this.start.column?-1:p>this.end.column?1:0:b<this.start.row?-1:b>this.end.row?1:this.start.row===b?p>=this.start.column?0:-1:this.end.row===b?p<=this.end.column?0:1:0},h.prototype.compareStart=function(b,p){return this.start.row==b&&this.start.column==p?-1:this.compare(b,p)},h.prototype.compareEnd=function(b,p){return this.end.row==b&&this.end.column==p?1:this.compare(b,p)},h.prototype.compareInside=function(b,p){return this.end.row==b&&this.end.column==p?1:this.start.row==b&&this.start.column==p?-1:this.compare(b,p)},h.prototype.clipRows=function(b,p){if(this.end.row>p)var g={row:p+1,column:0};else if(this.end.row<b)var g={row:b,column:0};if(this.start.row>p)var o={row:p+1,column:0};else if(this.start.row<b)var o={row:b,column:0};return h.fromPoints(o||this.start,g||this.end)},h.prototype.extend=function(b,p){var g=this.compare(b,p);if(g==0)return this;if(g==-1)var o={row:b,column:p};else var c={row:b,column:p};return h.fromPoints(o||this.start,c||this.end)},h.prototype.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},h.prototype.isMultiLine=function(){return this.start.row!==this.end.row},h.prototype.clone=function(){return h.fromPoints(this.start,this.end)},h.prototype.collapseRows=function(){return this.end.column==0?new h(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new h(this.start.row,0,this.end.row,0)},h.prototype.toScreenRange=function(b){var p=b.documentToScreenPosition(this.start),g=b.documentToScreenPosition(this.end);return new h(p.row,p.column,g.row,g.column)},h.prototype.moveBy=function(b,p){this.start.row+=b,this.start.column+=p,this.end.row+=b,this.end.column+=p},h}();d.fromPoints=function(h,b){return new d(h.row,h.column,b.row,b.column)},d.comparePoints=function(h,b){return h.row-b.row||h.column-b.column},r.Range=d}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],function(t,r,l){for(var d=t("./oop"),h={MODIFIER_KEYS:{16:"Shift",17:"Ctrl",18:"Alt",224:"Meta",91:"MetaLeft",92:"MetaRight",93:"ContextMenu"},KEY_MODS:{ctrl:1,alt:2,option:2,shift:4,super:8,meta:8,command:8,cmd:8,control:1},FUNCTION_KEYS:{8:"Backspace",9:"Tab",13:"Return",19:"Pause",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"Print",45:"Insert",46:"Delete","-13":"NumpadEnter",144:"Numlock",145:"Scrolllock"},PRINTABLE_KEYS:{32:" ",59:";",61:"=",107:"+",109:"-",110:".",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",111:"/",106:"*"}},b={Command:224,Backspace:8,Tab:9,Return:13,Enter:13,Pause:19,Escape:27,PageUp:33,PageDown:34,End:35,Home:36,Insert:45,Delete:46,ArrowLeft:37,ArrowUp:38,ArrowRight:39,ArrowDown:40,Backquote:192,Minus:189,Equal:187,BracketLeft:219,Backslash:220,BracketRight:221,Semicolon:186,Quote:222,Comma:188,Period:190,Slash:191,Space:32,NumpadAdd:107,NumpadDecimal:110,NumpadSubtract:109,NumpadDivide:111,NumpadMultiply:106},p=0;p<10;p++)b["Digit"+p]=48+p,b["Numpad"+p]=96+p,h.PRINTABLE_KEYS[48+p]=""+p,h.FUNCTION_KEYS[96+p]="Numpad"+p;for(var p=65;p<91;p++){var g=String.fromCharCode(p+32);b["Key"+g.toUpperCase()]=p,h.PRINTABLE_KEYS[p]=g}for(var p=1;p<13;p++)b["F"+p]=111+p,h.FUNCTION_KEYS[111+p]="F"+p;var o={Shift:16,Control:17,Alt:18,Meta:224};for(var c in o)b[c]=b[c+"Left"]=b[c+"Right"]=o[c];r.$codeToKeyCode=b,h.PRINTABLE_KEYS[173]="-";for(var f in h.FUNCTION_KEYS){var u=h.FUNCTION_KEYS[f].toLowerCase();h[u]=parseInt(f,10)}for(var f in h.PRINTABLE_KEYS){var u=h.PRINTABLE_KEYS[f].toLowerCase();h[u]=parseInt(f,10)}d.mixin(h,h.MODIFIER_KEYS),d.mixin(h,h.PRINTABLE_KEYS),d.mixin(h,h.FUNCTION_KEYS),h.enter=h.return,h.escape=h.esc,h.del=h.delete,function(){for(var i=["cmd","ctrl","alt","shift"],a=Math.pow(2,i.length);a--;)h.KEY_MODS[a]=i.filter(function(m){return a&h.KEY_MODS[m]}).join("-")+"-"}(),h.KEY_MODS[0]="",h.KEY_MODS[-1]="input-",d.mixin(r,h),r.default=r,r.keyCodeToString=function(i){var a=h[i];return typeof a!="string"&&(a=String.fromCharCode(i)),a.toLowerCase()}}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(t,r,l){var d=t("./keys"),h=t("./useragent"),b=null,p=0,g;function o(){g=!1;try{document.createComment("").addEventListener("test",function(){},{get passive(){return g={passive:!1},!0}})}catch{}}function c(){return g==null&&o(),g}function f(M,$,S){this.elem=M,this.type=$,this.callback=S}f.prototype.destroy=function(){i(this.elem,this.type,this.callback),this.elem=this.type=this.callback=void 0};var u=r.addListener=function(M,$,S,k){M.addEventListener($,S,c()),k&&k.$toDestroy.push(new f(M,$,S))},i=r.removeListener=function(M,$,S){M.removeEventListener($,S,c())};r.stopEvent=function(M){return r.stopPropagation(M),r.preventDefault(M),!1},r.stopPropagation=function(M){M.stopPropagation&&M.stopPropagation()},r.preventDefault=function(M){M.preventDefault&&M.preventDefault()},r.getButton=function(M){return M.type=="dblclick"?0:M.type=="contextmenu"||h.isMac&&M.ctrlKey&&!M.altKey&&!M.shiftKey?2:M.button},r.capture=function(M,$,S){var k=M&&M.ownerDocument||document;function T(D){$&&$(D),S&&S(D),i(k,"mousemove",$),i(k,"mouseup",T),i(k,"dragstart",T)}return u(k,"mousemove",$),u(k,"mouseup",T),u(k,"dragstart",T),T},r.addMouseWheelListener=function(M,$,S){u(M,"wheel",function(k){var T=.15,D=k.deltaX||0,L=k.deltaY||0;switch(k.deltaMode){case k.DOM_DELTA_PIXEL:k.wheelX=D*T,k.wheelY=L*T;break;case k.DOM_DELTA_LINE:var O=15;k.wheelX=D*O,k.wheelY=L*O;break;case k.DOM_DELTA_PAGE:var z=150;k.wheelX=D*z,k.wheelY=L*z;break}$(k)},S)},r.addMultiMouseDownListener=function(M,$,S,k,T){var D=0,L,O,z,P={2:"dblclick",3:"tripleclick",4:"quadclick"};function N(A){if(r.getButton(A)!==0?D=0:A.detail>1?(D++,D>4&&(D=1)):D=1,h.isIE){var _=Math.abs(A.clientX-L)>5||Math.abs(A.clientY-O)>5;(!z||_)&&(D=1),z&&clearTimeout(z),z=setTimeout(function(){z=null},$[D-1]||600),D==1&&(L=A.clientX,O=A.clientY)}if(A._clicks=D,S[k]("mousedown",A),D>4)D=0;else if(D>1)return S[k](P[D],A)}Array.isArray(M)||(M=[M]),M.forEach(function(A){u(A,"mousedown",N,T)})};function a(M){return 0|(M.ctrlKey?1:0)|(M.altKey?2:0)|(M.shiftKey?4:0)|(M.metaKey?8:0)}r.getModifierString=function(M){return d.KEY_MODS[a(M)]};function m(M,$,S){var k=a($);if(!S&&$.code&&(S=d.$codeToKeyCode[$.code]||S),!h.isMac&&b){if($.getModifierState&&($.getModifierState("OS")||$.getModifierState("Win"))&&(k|=8),b.altGr)if((3&k)!=3)b.altGr=0;else return;if(S===18||S===17){var T=$.location;if(S===17&&T===1)b[S]==1&&(p=$.timeStamp);else if(S===18&&k===3&&T===2){var D=$.timeStamp-p;D<50&&(b.altGr=!0)}}}if(S in d.MODIFIER_KEYS&&(S=-1),!(!k&&S===13&&$.location===3&&(M($,k,-S),$.defaultPrevented))){if(h.isChromeOS&&k&8){if(M($,k,S),$.defaultPrevented)return;k&=-9}return!k&&!(S in d.FUNCTION_KEYS)&&!(S in d.PRINTABLE_KEYS)?!1:M($,k,S)}}r.addCommandKeyListener=function(M,$,S){var k=null;u(M,"keydown",function(T){b[T.keyCode]=(b[T.keyCode]||0)+1;var D=m($,T,T.keyCode);return k=T.defaultPrevented,D},S),u(M,"keypress",function(T){k&&(T.ctrlKey||T.altKey||T.shiftKey||T.metaKey)&&(r.stopEvent(T),k=null)},S),u(M,"keyup",function(T){b[T.keyCode]=null},S),b||(w(),u(window,"focus",w))};function w(){b=Object.create(null)}if(typeof window=="object"&&window.postMessage&&!h.isOldIE){var x=1;r.nextTick=function(M,$){$=$||window;var S="zero-timeout-message-"+x++,k=function(T){T.data==S&&(r.stopPropagation(T),i($,"message",k),M())};u($,"message",k),$.postMessage(S,"*")}}r.$idleBlocked=!1,r.onIdle=function(M,$){return setTimeout(function S(){r.$idleBlocked?setTimeout(S,100):M()},$)},r.$idleBlockId=null,r.blockIdle=function(M){r.$idleBlockId&&clearTimeout(r.$idleBlockId),r.$idleBlocked=!0,r.$idleBlockId=setTimeout(function(){r.$idleBlocked=!1},M||100)},r.nextFrame=typeof window=="object"&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),r.nextFrame?r.nextFrame=r.nextFrame.bind(window):r.nextFrame=function(M){setTimeout(M,17)}}),ace.define("ace/clipboard",["require","exports","module"],function(t,r,l){var d;l.exports={lineMode:!1,pasteCancelled:function(){return d&&d>Date.now()-50?!0:d=!1},cancel:function(){d=Date.now()}}}),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/config","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/clipboard","ace/lib/keys"],function(t,r,l){var d=t("../lib/event"),h=t("../config").nls,b=t("../lib/useragent"),p=t("../lib/dom"),g=t("../lib/lang"),o=t("../clipboard"),c=b.isChrome<18,f=b.isIE,u=b.isChrome>63,i=400,a=t("../lib/keys"),m=a.KEY_MODS,w=b.isIOS,x=w?/\s/:/\n/,M=b.isMobile,$=function(){function S(k,T){var D=this;this.host=T,this.text=p.createElement("textarea"),this.text.className="ace_text-input",this.text.setAttribute("wrap","off"),this.text.setAttribute("autocomplete","off"),this.text.setAttribute("autocorrect","off"),this.text.setAttribute("autocapitalize","off"),this.text.setAttribute("spellcheck","false"),this.text.style.opacity="0",k.insertBefore(this.text,k.firstChild),this.copied=!1,this.pasted=!1,this.inComposition=!1,this.sendingText=!1,this.tempStyle="",M||(this.text.style.fontSize="1px"),this.commandMode=!1,this.ignoreFocusEvents=!1,this.lastValue="",this.lastSelectionStart=0,this.lastSelectionEnd=0,this.lastRestoreEnd=0,this.rowStart=Number.MAX_SAFE_INTEGER,this.rowEnd=Number.MIN_SAFE_INTEGER,this.numberOfExtraLines=0;try{this.$isFocused=document.activeElement===this.text}catch{}this.cancelComposition=this.cancelComposition.bind(this),this.setAriaOptions({role:"textbox"}),d.addListener(this.text,"blur",function(L){D.ignoreFocusEvents||(T.onBlur(L),D.$isFocused=!1)},T),d.addListener(this.text,"focus",function(L){if(!D.ignoreFocusEvents){if(D.$isFocused=!0,b.isEdge)try{if(!document.hasFocus())return}catch{}T.onFocus(L),b.isEdge?setTimeout(D.resetSelection.bind(D)):D.resetSelection()}},T),this.$focusScroll=!1,T.on("beforeEndOperation",function(){var L=T.curOp,O=L&&L.command&&L.command.name;if(O!="insertstring"){var z=O&&(L.docChanged||L.selectionChanged);D.inComposition&&z&&(D.lastValue=D.text.value="",D.onCompositionEnd()),D.resetSelection()}}),T.on("changeSelection",this.setAriaLabel.bind(this)),this.resetSelection=w?this.$resetSelectionIOS:this.$resetSelection,this.$isFocused&&T.onFocus(),this.inputHandler=null,this.afterContextMenu=!1,d.addCommandKeyListener(this.text,function(L,O,z){if(!D.inComposition)return T.onCommandKey(L,O,z)},T),d.addListener(this.text,"select",this.onSelect.bind(this),T),d.addListener(this.text,"input",this.onInput.bind(this),T),d.addListener(this.text,"cut",this.onCut.bind(this),T),d.addListener(this.text,"copy",this.onCopy.bind(this),T),d.addListener(this.text,"paste",this.onPaste.bind(this),T),(!("oncut"in this.text)||!("oncopy"in this.text)||!("onpaste"in this.text))&&d.addListener(k,"keydown",function(L){if(!(b.isMac&&!L.metaKey||!L.ctrlKey))switch(L.keyCode){case 67:D.onCopy(L);break;case 86:D.onPaste(L);break;case 88:D.onCut(L);break}},T),this.syncComposition=g.delayedCall(this.onCompositionUpdate.bind(this),50).schedule.bind(null,null),d.addListener(this.text,"compositionstart",this.onCompositionStart.bind(this),T),d.addListener(this.text,"compositionupdate",this.onCompositionUpdate.bind(this),T),d.addListener(this.text,"keyup",this.onKeyup.bind(this),T),d.addListener(this.text,"keydown",this.syncComposition.bind(this),T),d.addListener(this.text,"compositionend",this.onCompositionEnd.bind(this),T),this.closeTimeout,d.addListener(this.text,"mouseup",this.$onContextMenu.bind(this),T),d.addListener(this.text,"mousedown",function(L){L.preventDefault(),D.onContextMenuClose()},T),d.addListener(T.renderer.scroller,"contextmenu",this.$onContextMenu.bind(this),T),d.addListener(this.text,"contextmenu",this.$onContextMenu.bind(this),T),w&&this.addIosSelectionHandler(k,T,this.text)}return S.prototype.addIosSelectionHandler=function(k,T,D){var L=this,O=null,z=!1;D.addEventListener("keydown",function(N){O&&clearTimeout(O),z=!0},!0),D.addEventListener("keyup",function(N){O=setTimeout(function(){z=!1},100)},!0);var P=function(N){if(document.activeElement===D&&!(z||L.inComposition||T.$mouseHandler.isMousePressed)&&!L.copied){var A=D.selectionStart,_=D.selectionEnd,I=null,j=0;if(A==0?I=a.up:A==1?I=a.home:_>L.lastSelectionEnd&&L.lastValue[_]==`
|
|
173
|
+
`?I=a.end:A<L.lastSelectionStart&&L.lastValue[A-1]==" "?(I=a.left,j=m.option):A<L.lastSelectionStart||A==L.lastSelectionStart&&L.lastSelectionEnd!=L.lastSelectionStart&&A==_?I=a.left:_>L.lastSelectionEnd&&L.lastValue.slice(0,_).split(`
|
|
174
|
+
`).length>2?I=a.down:_>L.lastSelectionEnd&&L.lastValue[_-1]==" "?(I=a.right,j=m.option):(_>L.lastSelectionEnd||_==L.lastSelectionEnd&&L.lastSelectionEnd!=L.lastSelectionStart&&A==_)&&(I=a.right),A!==_&&(j|=m.shift),I){var U=T.onCommandKey({},j,I);if(!U&&T.commands){I=a.keyCodeToString(I);var K=T.commands.findKeyCommand(j,I);K&&T.execCommand(K)}L.lastSelectionStart=A,L.lastSelectionEnd=_,L.resetSelection("")}}};document.addEventListener("selectionchange",P),T.on("destroy",function(){document.removeEventListener("selectionchange",P)})},S.prototype.onContextMenuClose=function(){var k=this;clearTimeout(this.closeTimeout),this.closeTimeout=setTimeout(function(){k.tempStyle&&(k.text.style.cssText=k.tempStyle,k.tempStyle=""),k.host.renderer.$isMousePressed=!1,k.host.renderer.$keepTextAreaAtCursor&&k.host.renderer.$moveTextAreaToCursor()},0)},S.prototype.$onContextMenu=function(k){this.host.textInput.onContextMenu(k),this.onContextMenuClose()},S.prototype.onKeyup=function(k){k.keyCode==27&&this.text.value.length<this.text.selectionStart&&(this.inComposition||(this.lastValue=this.text.value),this.lastSelectionStart=this.lastSelectionEnd=-1,this.resetSelection()),this.syncComposition()},S.prototype.cancelComposition=function(){this.ignoreFocusEvents=!0,this.text.blur(),this.text.focus(),this.ignoreFocusEvents=!1},S.prototype.onCompositionStart=function(k){if(!(this.inComposition||!this.host.onCompositionStart||this.host.$readOnly)&&(this.inComposition={},!this.commandMode)){k.data&&(this.inComposition.useTextareaForIME=!1),setTimeout(this.onCompositionUpdate.bind(this),0),this.host._signal("compositionStart"),this.host.on("mousedown",this.cancelComposition);var T=this.host.getSelectionRange();T.end.row=T.start.row,T.end.column=T.start.column,this.inComposition.markerRange=T,this.inComposition.selectionStart=this.lastSelectionStart,this.host.onCompositionStart(this.inComposition),this.inComposition.useTextareaForIME?(this.lastValue=this.text.value="",this.lastSelectionStart=0,this.lastSelectionEnd=0):(this.text.msGetInputContext&&(this.inComposition.context=this.text.msGetInputContext()),this.text.getInputContext&&(this.inComposition.context=this.text.getInputContext()))}},S.prototype.onCompositionUpdate=function(){if(!(!this.inComposition||!this.host.onCompositionUpdate||this.host.$readOnly)){if(this.commandMode)return this.cancelComposition();if(this.inComposition.useTextareaForIME)this.host.onCompositionUpdate(this.text.value);else{var k=this.text.value;this.sendText(k),this.inComposition.markerRange&&(this.inComposition.context&&(this.inComposition.markerRange.start.column=this.inComposition.selectionStart=this.inComposition.context.compositionStartOffset),this.inComposition.markerRange.end.column=this.inComposition.markerRange.start.column+this.lastSelectionEnd-this.inComposition.selectionStart+this.lastRestoreEnd)}}},S.prototype.onCompositionEnd=function(k){!this.host.onCompositionEnd||this.host.$readOnly||(this.inComposition=!1,this.host.onCompositionEnd(),this.host.off("mousedown",this.cancelComposition),k&&this.onInput())},S.prototype.onCut=function(k){this.doCopy(k,!0)},S.prototype.onCopy=function(k){this.doCopy(k,!1)},S.prototype.onPaste=function(k){var T=this.handleClipboardData(k);o.pasteCancelled()||(typeof T=="string"?(T&&this.host.onPaste(T,k),b.isIE&&setTimeout(this.resetSelection),d.preventDefault(k)):(this.text.value="",this.pasted=!0))},S.prototype.doCopy=function(k,T){var D=this,L=this.host.getCopyText();if(!L)return d.preventDefault(k);this.handleClipboardData(k,L)?(w&&(this.resetSelection(L),this.copied=L,setTimeout(function(){D.copied=!1},10)),T?this.host.onCut():this.host.onCopy(),d.preventDefault(k)):(this.copied=!0,this.text.value=L,this.text.select(),setTimeout(function(){D.copied=!1,D.resetSelection(),T?D.host.onCut():D.host.onCopy()}))},S.prototype.handleClipboardData=function(k,T,D){var L=k.clipboardData||window.clipboardData;if(!(!L||c)){var O=f||D?"Text":"text/plain";try{return T?L.setData(O,T)!==!1:L.getData(O)}catch(z){if(!D)return this.handleClipboardData(z,T,!0)}}},S.prototype.onInput=function(k){if(this.inComposition)return this.onCompositionUpdate();if(k&&k.inputType){if(k.inputType=="historyUndo")return this.host.execCommand("undo");if(k.inputType=="historyRedo")return this.host.execCommand("redo")}var T=this.text.value,D=this.sendText(T,!0);(T.length>i+100||x.test(D)||M&&this.lastSelectionStart<1&&this.lastSelectionStart==this.lastSelectionEnd)&&this.resetSelection()},S.prototype.sendText=function(k,T){if(this.afterContextMenu&&(this.afterContextMenu=!1),this.pasted)return this.resetSelection(),k&&this.host.onPaste(k),this.pasted=!1,"";for(var D=this.text.selectionStart,L=this.text.selectionEnd,O=this.lastSelectionStart,z=this.lastValue.length-this.lastSelectionEnd,P=k,N=k.length-D,A=k.length-L,_=0;O>0&&this.lastValue[_]==k[_];)_++,O--;for(P=P.slice(_),_=1;z>0&&this.lastValue.length-_>this.lastSelectionStart-1&&this.lastValue[this.lastValue.length-_]==k[k.length-_];)_++,z--;N-=_-1,A-=_-1;var I=P.length-_+1;if(I<0&&(O=-I,I=0),P=P.slice(0,I),!T&&!P&&!N&&!O&&!z&&!A)return"";this.sendingText=!0;var j=!1;return b.isAndroid&&P==". "&&(P=" ",j=!0),P&&!O&&!z&&!N&&!A||this.commandMode?this.host.onTextInput(P):this.host.onTextInput(P,{extendLeft:O,extendRight:z,restoreStart:N,restoreEnd:A}),this.sendingText=!1,this.lastValue=k,this.lastSelectionStart=D,this.lastSelectionEnd=L,this.lastRestoreEnd=A,j?`
|
|
175
|
+
`:P},S.prototype.onSelect=function(k){var T=this;if(!this.inComposition){var D=function(L){return L.selectionStart===0&&L.selectionEnd>=T.lastValue.length&&L.value===T.lastValue&&T.lastValue&&L.selectionEnd!==T.lastSelectionEnd};this.copied?this.copied=!1:D(this.text)?(this.host.selectAll(),this.resetSelection()):M&&this.text.selectionStart!=this.lastSelectionStart&&this.resetSelection()}},S.prototype.$resetSelectionIOS=function(k){if(!(!this.$isFocused||this.copied&&!k||this.sendingText)){k||(k="");var T=`
|
|
176
|
+
ab`+k+`cde fg
|
|
177
|
+
`;T!=this.text.value&&(this.text.value=this.lastValue=T);var D=4,L=4+(k.length||(this.host.selection.isEmpty()?0:1));(this.lastSelectionStart!=D||this.lastSelectionEnd!=L)&&this.text.setSelectionRange(D,L),this.lastSelectionStart=D,this.lastSelectionEnd=L}},S.prototype.$resetSelection=function(){var k=this;if(!(this.inComposition||this.sendingText)&&!(!this.$isFocused&&!this.afterContextMenu)){this.inComposition=!0;var T=0,D=0,L="",O=function(K,Z){for(var J=Z,ae=1;ae<=K-k.rowStart&&ae<2*k.numberOfExtraLines+1;ae++)J+=k.host.session.getLine(K-ae).length+1;return J};if(this.host.session){var z=this.host.selection,P=z.getRange(),N=z.cursor.row;N===this.rowEnd+1?(this.rowStart=this.rowEnd+1,this.rowEnd=this.rowStart+2*this.numberOfExtraLines):N===this.rowStart-1?(this.rowEnd=this.rowStart-1,this.rowStart=this.rowEnd-2*this.numberOfExtraLines):(N<this.rowStart-1||N>this.rowEnd+1)&&(this.rowStart=N>this.numberOfExtraLines?N-this.numberOfExtraLines:0,this.rowEnd=N>this.numberOfExtraLines?N+this.numberOfExtraLines:2*this.numberOfExtraLines);for(var A=[],_=this.rowStart;_<=this.rowEnd;_++)A.push(this.host.session.getLine(_));if(L=A.join(`
|
|
178
|
+
`),T=O(P.start.row,P.start.column),D=O(P.end.row,P.end.column),P.start.row<this.rowStart){var I=this.host.session.getLine(this.rowStart-1);T=P.start.row<this.rowStart-1?0:T,D+=I.length+1,L=I+`
|
|
179
|
+
`+L}else if(P.end.row>this.rowEnd){var j=this.host.session.getLine(this.rowEnd+1);D=P.end.row>this.rowEnd+1?j.length:P.end.column,D+=L.length+1,L=L+`
|
|
180
|
+
`+j}else M&&N>0&&(L=`
|
|
181
|
+
`+L,D+=1,T+=1);L.length>i&&(T<i&&D<i?L=L.slice(0,i):(L=`
|
|
182
|
+
`,T==D?T=D=0:(T=0,D=1)));var U=L+`
|
|
183
|
+
|
|
184
|
+
`;U!=this.lastValue&&(this.text.value=this.lastValue=U,this.lastSelectionStart=this.lastSelectionEnd=U.length)}if(this.afterContextMenu&&(this.lastSelectionStart=this.text.selectionStart,this.lastSelectionEnd=this.text.selectionEnd),this.lastSelectionEnd!=D||this.lastSelectionStart!=T||this.text.selectionEnd!=this.lastSelectionEnd)try{this.text.setSelectionRange(T,D),this.lastSelectionStart=T,this.lastSelectionEnd=D}catch{}this.inComposition=!1}},S.prototype.setHost=function(k){this.host=k},S.prototype.setNumberOfExtraLines=function(k){if(this.rowStart=Number.MAX_SAFE_INTEGER,this.rowEnd=Number.MIN_SAFE_INTEGER,k<0){this.numberOfExtraLines=0;return}this.numberOfExtraLines=k},S.prototype.setAriaLabel=function(){var k="";if(this.host.$textInputAriaLabel&&(k+="".concat(this.host.$textInputAriaLabel,", ")),this.host.session){var T=this.host.session.selection.cursor.row;k+=h("text-input.aria-label","Cursor at row $0",[T+1])}this.text.setAttribute("aria-label",k)},S.prototype.setAriaOptions=function(k){k.activeDescendant?(this.text.setAttribute("aria-haspopup","true"),this.text.setAttribute("aria-autocomplete",k.inline?"both":"list"),this.text.setAttribute("aria-activedescendant",k.activeDescendant)):(this.text.setAttribute("aria-haspopup","false"),this.text.setAttribute("aria-autocomplete","both"),this.text.removeAttribute("aria-activedescendant")),k.role&&this.text.setAttribute("role",k.role),k.setLabel&&(this.text.setAttribute("aria-roledescription",h("text-input.aria-roledescription","editor")),this.setAriaLabel())},S.prototype.focus=function(){var k=this;if(this.setAriaOptions({setLabel:this.host.renderer.enableKeyboardAccessibility}),this.tempStyle||u||this.$focusScroll=="browser")return this.text.focus({preventScroll:!0});var T=this.text.style.top;this.text.style.position="fixed",this.text.style.top="0px";try{var D=this.text.getBoundingClientRect().top!=0}catch{return}var L=[];if(D)for(var O=this.text.parentElement;O&&O.nodeType==1;)L.push(O),O.setAttribute("ace_nocontext","true"),!O.parentElement&&O.getRootNode?O=O.getRootNode().host:O=O.parentElement;this.text.focus({preventScroll:!0}),D&&L.forEach(function(z){z.removeAttribute("ace_nocontext")}),setTimeout(function(){k.text.style.position="",k.text.style.top=="0px"&&(k.text.style.top=T)},0)},S.prototype.blur=function(){this.text.blur()},S.prototype.isFocused=function(){return this.$isFocused},S.prototype.setInputHandler=function(k){this.inputHandler=k},S.prototype.getInputHandler=function(){return this.inputHandler},S.prototype.getElement=function(){return this.text},S.prototype.setCommandMode=function(k){this.commandMode=k,this.text.readOnly=!1},S.prototype.setReadOnly=function(k){this.commandMode||(this.text.readOnly=k)},S.prototype.setCopyWithEmptySelection=function(k){},S.prototype.onContextMenu=function(k){this.afterContextMenu=!0,this.resetSelection(),this.host._emit("nativecontextmenu",{target:this.host,domEvent:k}),this.moveToMouse(k,!0)},S.prototype.moveToMouse=function(k,T){var D=this;this.tempStyle||(this.tempStyle=this.text.style.cssText),this.text.style.cssText=(T?"z-index:100000;":"")+(b.isIE?"opacity:0.1;":"")+"text-indent: -"+(this.lastSelectionStart+this.lastSelectionEnd)*this.host.renderer.characterWidth*.5+"px;";var L=this.host.container.getBoundingClientRect(),O=p.computedStyle(this.host.container),z=L.top+(parseInt(O.borderTopWidth)||0),P=L.left+(parseInt(O.borderLeftWidth)||0),N=L.bottom-z-this.text.clientHeight-2,A=function(_){p.translate(D.text,_.clientX-P-2,Math.min(_.clientY-z-2,N))};A(k),k.type=="mousedown"&&(this.host.renderer.$isMousePressed=!0,clearTimeout(this.closeTimeout),b.isWin&&d.capture(this.host.container,A,this.onContextMenuClose.bind(this)))},S.prototype.destroy=function(){this.text.parentElement&&this.text.parentElement.removeChild(this.text)},S}();r.TextInput=$,r.$setUserAgentForTests=function(S,k){M=S,w=k}}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],function(t,r,l){var d=t("../lib/useragent"),h=0,b=550,p=function(){function c(f){f.$clickSelection=null;var u=f.editor;u.setDefaultHandler("mousedown",this.onMouseDown.bind(f)),u.setDefaultHandler("dblclick",this.onDoubleClick.bind(f)),u.setDefaultHandler("tripleclick",this.onTripleClick.bind(f)),u.setDefaultHandler("quadclick",this.onQuadClick.bind(f)),u.setDefaultHandler("mousewheel",this.onMouseWheel.bind(f));var i=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];i.forEach(function(a){f[a]=this[a]},this),f.selectByLines=this.extendSelectionBy.bind(f,"getLineRange"),f.selectByWords=this.extendSelectionBy.bind(f,"getWordRange")}return c.prototype.onMouseDown=function(f){var u=f.inSelection(),i=f.getDocumentPosition();this.mousedownEvent=f;var a=this.editor,m=f.getButton();if(m!==0){var w=a.getSelectionRange(),x=w.isEmpty();(x||m==1)&&a.selection.moveToPosition(i),m==2&&(a.textInput.onContextMenu(f.domEvent),d.isMozilla||f.preventDefault());return}if(this.mousedownEvent.time=Date.now(),u&&!a.isFocused()&&(a.focus(),this.$focusTimeout&&!this.$clickSelection&&!a.inMultiSelectMode)){this.setState("focusWait"),this.captureMouse(f);return}return this.captureMouse(f),this.startSelect(i,f.domEvent._clicks>1),f.preventDefault()},c.prototype.startSelect=function(f,u){f=f||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var i=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?i.selection.selectToPosition(f):u||i.selection.moveToPosition(f),u||this.select(),i.setStyle("ace_selecting"),this.setState("select"))},c.prototype.select=function(){var f,u=this.editor,i=u.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var a=this.$clickSelection.comparePoint(i);if(a==-1)f=this.$clickSelection.end;else if(a==1)f=this.$clickSelection.start;else{var m=o(this.$clickSelection,i,u.session);i=m.cursor,f=m.anchor}u.selection.setSelectionAnchor(f.row,f.column)}u.selection.selectToPosition(i),u.renderer.scrollCursorIntoView()},c.prototype.extendSelectionBy=function(f){var u,i=this.editor,a=i.renderer.screenToTextCoordinates(this.x,this.y),m=i.selection[f](a.row,a.column);if(this.$clickSelection){var w=this.$clickSelection.comparePoint(m.start),x=this.$clickSelection.comparePoint(m.end);if(w==-1&&x<=0)u=this.$clickSelection.end,(m.end.row!=a.row||m.end.column!=a.column)&&(a=m.start);else if(x==1&&w>=0)u=this.$clickSelection.start,(m.start.row!=a.row||m.start.column!=a.column)&&(a=m.end);else if(w==-1&&x==1)a=m.end,u=m.start;else{var M=o(this.$clickSelection,a,i.session);a=M.cursor,u=M.anchor}i.selection.setSelectionAnchor(u.row,u.column)}i.selection.selectToPosition(a),i.renderer.scrollCursorIntoView()},c.prototype.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting")},c.prototype.focusWait=function(){var f=g(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),u=Date.now();(f>h||u-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},c.prototype.onDoubleClick=function(f){var u=f.getDocumentPosition(),i=this.editor,a=i.session,m=a.getBracketRange(u);m?(m.isEmpty()&&(m.start.column--,m.end.column++),this.setState("select")):(m=i.selection.getWordRange(u.row,u.column),this.setState("selectByWords")),this.$clickSelection=m,this.select()},c.prototype.onTripleClick=function(f){var u=f.getDocumentPosition(),i=this.editor;this.setState("selectByLines");var a=i.getSelectionRange();a.isMultiLine()&&a.contains(u.row,u.column)?(this.$clickSelection=i.selection.getLineRange(a.start.row),this.$clickSelection.end=i.selection.getLineRange(a.end.row).end):this.$clickSelection=i.selection.getLineRange(u.row),this.select()},c.prototype.onQuadClick=function(f){var u=this.editor;u.selectAll(),this.$clickSelection=u.getSelectionRange(),this.setState("selectAll")},c.prototype.onMouseWheel=function(f){if(!f.getAccelKey()){f.getShiftKey()&&f.wheelY&&!f.wheelX&&(f.wheelX=f.wheelY,f.wheelY=0);var u=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var i=this.$lastScroll,a=f.domEvent.timeStamp,m=a-i.t,w=m?f.wheelX/m:i.vx,x=m?f.wheelY/m:i.vy;m<b&&(w=(w+i.vx)/2,x=(x+i.vy)/2);var M=Math.abs(w/x),$=!1;if(M>=1&&u.renderer.isScrollableBy(f.wheelX*f.speed,0)&&($=!0),M<=1&&u.renderer.isScrollableBy(0,f.wheelY*f.speed)&&($=!0),$)i.allowed=a;else if(a-i.allowed<b){var S=Math.abs(w)<=1.5*Math.abs(i.vx)&&Math.abs(x)<=1.5*Math.abs(i.vy);S?($=!0,i.allowed=a):i.allowed=0}if(i.t=a,i.vx=w,i.vy=x,$)return u.renderer.scrollBy(f.wheelX*f.speed,f.wheelY*f.speed),f.stop()}},c}();p.prototype.selectEnd=p.prototype.selectByLinesEnd,p.prototype.selectAllEnd=p.prototype.selectByLinesEnd,p.prototype.selectByWordsEnd=p.prototype.selectByLinesEnd,r.DefaultHandlers=p;function g(c,f,u,i){return Math.sqrt(Math.pow(u-c,2)+Math.pow(i-f,2))}function o(c,f,u){if(c.start.row==c.end.row)var i=2*f.column-c.start.column-c.end.column;else if(c.start.row==c.end.row-1&&!c.start.column&&!c.end.column)var i=3*f.column-2*u.getLine(c.start.row).length;else var i=2*f.row-c.start.row-c.end.row;return i<0?{cursor:c.start,anchor:c.end}:{cursor:c.end,anchor:c.start}}}),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(t,r,l){var d=t("../lib/event"),h=t("../lib/useragent"),b=function(){function p(g,o){this.speed,this.wheelX,this.wheelY,this.domEvent=g,this.editor=o,this.x=this.clientX=g.clientX,this.y=this.clientY=g.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1}return p.prototype.stopPropagation=function(){d.stopPropagation(this.domEvent),this.propagationStopped=!0},p.prototype.preventDefault=function(){d.preventDefault(this.domEvent),this.defaultPrevented=!0},p.prototype.stop=function(){this.stopPropagation(),this.preventDefault()},p.prototype.getDocumentPosition=function(){return this.$pos?this.$pos:(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY),this.$pos)},p.prototype.getGutterRow=function(){var g=this.getDocumentPosition().row,o=this.editor.session.documentToScreenRow(g,0),c=this.editor.session.documentToScreenRow(this.editor.renderer.$gutterLayer.$lines.get(0).row,0);return o-c},p.prototype.inSelection=function(){if(this.$inSelection!==null)return this.$inSelection;var g=this.editor,o=g.getSelectionRange();if(o.isEmpty())this.$inSelection=!1;else{var c=this.getDocumentPosition();this.$inSelection=o.contains(c.row,c.column)}return this.$inSelection},p.prototype.getButton=function(){return d.getButton(this.domEvent)},p.prototype.getShiftKey=function(){return this.domEvent.shiftKey},p.prototype.getAccelKey=function(){return h.isMac?this.domEvent.metaKey:this.domEvent.ctrlKey},p}();r.MouseEvent=b}),ace.define("ace/lib/scroll",["require","exports","module"],function(t,r,l){r.preventParentScroll=function(d){d.stopPropagation();var h=d.currentTarget,b=h.scrollHeight>h.clientHeight;b||d.preventDefault()}}),ace.define("ace/tooltip",["require","exports","module","ace/lib/dom","ace/lib/event","ace/range","ace/lib/scroll"],function(t,r,l){var d=this&&this.__extends||function(){var a=function(m,w){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,M){x.__proto__=M}||function(x,M){for(var $ in M)Object.prototype.hasOwnProperty.call(M,$)&&(x[$]=M[$])},a(m,w)};return function(m,w){if(typeof w!="function"&&w!==null)throw new TypeError("Class extends value "+String(w)+" is not a constructor or null");a(m,w);function x(){this.constructor=m}m.prototype=w===null?Object.create(w):(x.prototype=w.prototype,new x)}}(),h=this&&this.__values||function(a){var m=typeof Symbol=="function"&&Symbol.iterator,w=m&&a[m],x=0;if(w)return w.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&x>=a.length&&(a=void 0),{value:a&&a[x++],done:!a}}};throw new TypeError(m?"Object is not iterable.":"Symbol.iterator is not defined.")},b=t("./lib/dom");t("./lib/event");var p=t("./range").Range,g=t("./lib/scroll").preventParentScroll,o="ace_tooltip",c=function(){function a(m){this.isOpen=!1,this.$element=null,this.$parentNode=m}return a.prototype.$init=function(){return this.$element=b.createElement("div"),this.$element.className=o,this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},a.prototype.getElement=function(){return this.$element||this.$init()},a.prototype.setText=function(m){this.getElement().textContent=m},a.prototype.setHtml=function(m){this.getElement().innerHTML=m},a.prototype.setPosition=function(m,w){this.getElement().style.left=m+"px",this.getElement().style.top=w+"px"},a.prototype.setClassName=function(m){b.addCssClass(this.getElement(),m)},a.prototype.setTheme=function(m){this.theme&&(this.theme.isDark&&b.removeCssClass(this.getElement(),"ace_dark"),this.theme.cssClass&&b.removeCssClass(this.getElement(),this.theme.cssClass)),m.isDark&&b.addCssClass(this.getElement(),"ace_dark"),m.cssClass&&b.addCssClass(this.getElement(),m.cssClass),this.theme={isDark:m.isDark,cssClass:m.cssClass}},a.prototype.show=function(m,w,x){m!=null&&this.setText(m),w!=null&&x!=null&&this.setPosition(w,x),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},a.prototype.hide=function(m){this.isOpen&&(this.getElement().style.display="none",this.getElement().className=o,this.isOpen=!1)},a.prototype.getHeight=function(){return this.getElement().offsetHeight},a.prototype.getWidth=function(){return this.getElement().offsetWidth},a.prototype.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)},a}(),f=function(){function a(){this.popups=[]}return a.prototype.addPopup=function(m){this.popups.push(m),this.updatePopups()},a.prototype.removePopup=function(m){var w=this.popups.indexOf(m);w!==-1&&(this.popups.splice(w,1),this.updatePopups())},a.prototype.updatePopups=function(){var m,w,x,M;this.popups.sort(function(P,N){return N.priority-P.priority});var $=[];try{for(var S=h(this.popups),k=S.next();!k.done;k=S.next()){var T=k.value,D=!0;try{for(var L=(x=void 0,h($)),O=L.next();!O.done;O=L.next()){var z=O.value;if(this.doPopupsOverlap(z,T)){D=!1;break}}}catch(P){x={error:P}}finally{try{O&&!O.done&&(M=L.return)&&M.call(L)}finally{if(x)throw x.error}}D?$.push(T):T.hide()}}catch(P){m={error:P}}finally{try{k&&!k.done&&(w=S.return)&&w.call(S)}finally{if(m)throw m.error}}},a.prototype.doPopupsOverlap=function(m,w){var x=m.getElement().getBoundingClientRect(),M=w.getElement().getBoundingClientRect();return x.left<M.right&&x.right>M.left&&x.top<M.bottom&&x.bottom>M.top},a}(),u=new f;r.popupManager=u,r.Tooltip=c;var i=function(a){d(m,a);function m(w){w===void 0&&(w=document.body);var x=a.call(this,w)||this;x.timeout=void 0,x.lastT=0,x.idleTime=350,x.lastEvent=void 0,x.onMouseOut=x.onMouseOut.bind(x),x.onMouseMove=x.onMouseMove.bind(x),x.waitForHover=x.waitForHover.bind(x),x.hide=x.hide.bind(x);var M=x.getElement();return M.style.whiteSpace="pre-wrap",M.style.pointerEvents="auto",M.addEventListener("mouseout",x.onMouseOut),M.tabIndex=-1,M.addEventListener("blur",(function(){M.contains(document.activeElement)||this.hide()}).bind(x)),M.addEventListener("wheel",g),x}return m.prototype.addToEditor=function(w){w.on("mousemove",this.onMouseMove),w.on("mousedown",this.hide);var x=w.renderer.getMouseEventTarget();x&&typeof x.removeEventListener=="function"&&x.addEventListener("mouseout",this.onMouseOut,!0)},m.prototype.removeFromEditor=function(w){w.off("mousemove",this.onMouseMove),w.off("mousedown",this.hide);var x=w.renderer.getMouseEventTarget();x&&typeof x.removeEventListener=="function"&&x.removeEventListener("mouseout",this.onMouseOut,!0),this.timeout&&(clearTimeout(this.timeout),this.timeout=null)},m.prototype.onMouseMove=function(w,x){this.lastEvent=w,this.lastT=Date.now();var M=x.$mouseHandler.isMousePressed;if(this.isOpen){var $=this.lastEvent&&this.lastEvent.getDocumentPosition();(!this.range||!this.range.contains($.row,$.column)||M||this.isOutsideOfText(this.lastEvent))&&this.hide()}this.timeout||M||(this.lastEvent=w,this.timeout=setTimeout(this.waitForHover,this.idleTime))},m.prototype.waitForHover=function(){this.timeout&&clearTimeout(this.timeout);var w=Date.now()-this.lastT;if(this.idleTime-w>10){this.timeout=setTimeout(this.waitForHover,this.idleTime-w);return}this.timeout=null,this.lastEvent&&!this.isOutsideOfText(this.lastEvent)&&this.$gatherData(this.lastEvent,this.lastEvent.editor)},m.prototype.isOutsideOfText=function(w){var x=w.editor,M=w.getDocumentPosition(),$=x.session.getLine(M.row);if(M.column==$.length){var S=x.renderer.pixelToScreenCoordinates(w.clientX,w.clientY),k=x.session.documentToScreenPosition(M.row,M.column);if(k.column!=S.column||k.row!=S.row)return!0}return!1},m.prototype.setDataProvider=function(w){this.$gatherData=w},m.prototype.showForRange=function(w,x,M,$){if(!($&&$!=this.lastEvent)&&!(this.isOpen&&document.activeElement==this.getElement())){var S=w.renderer;this.isOpen||(u.addPopup(this),this.$registerCloseEvents(),this.setTheme(S.theme)),this.isOpen=!0,this.range=p.fromPoints(x.start,x.end);var k=S.textToScreenCoordinates(x.start.row,x.start.column),T=S.scroller.getBoundingClientRect();k.pageX<T.left&&(k.pageX=T.left);var D=this.getElement();D.innerHTML="",D.appendChild(M),D.style.maxHeight="",D.style.display="block",this.$setPosition(w,k,!0,x),b.$fixPositionBug(D)}},m.prototype.$setPosition=function(w,x,M,$){var S=10;M&&this.addMarker($,w.session);var k=w.renderer,T=this.getElement(),D=T.offsetHeight,L=T.offsetWidth,O=x.pageY,z=x.pageX,P=window.innerHeight-O-k.lineHeight,N=this.$shouldPlaceAbove(D,O,P-S);T.style.maxHeight=(N?O:P)-S+"px",T.style.top=N?"":O+k.lineHeight+"px",T.style.bottom=N?window.innerHeight-O+"px":"",T.style.left=Math.min(z,window.innerWidth-L-S)+"px"},m.prototype.$shouldPlaceAbove=function(w,x,M){return!(x-w<0&&x<M)},m.prototype.addMarker=function(w,x){this.marker&&this.$markerSession.removeMarker(this.marker),this.$markerSession=x,this.marker=x&&x.addMarker(w,"ace_highlight-marker","text")},m.prototype.hide=function(w){w&&this.$fromKeyboard&&w.type=="keydown"&&w.code=="Escape"||!w&&document.activeElement==this.getElement()||w&&w.target&&(w.type!="keydown"||w.ctrlKey||w.metaKey)&&this.$element.contains(w.target)||(this.lastEvent=null,this.timeout&&clearTimeout(this.timeout),this.timeout=null,this.addMarker(null),this.isOpen&&(this.$fromKeyboard=!1,this.$removeCloseEvents(),this.getElement().style.display="none",this.isOpen=!1,u.removePopup(this)))},m.prototype.$registerCloseEvents=function(){window.addEventListener("keydown",this.hide,!0),window.addEventListener("wheel",this.hide,!0),window.addEventListener("mousedown",this.hide,!0)},m.prototype.$removeCloseEvents=function(){window.removeEventListener("keydown",this.hide,!0),window.removeEventListener("wheel",this.hide,!0),window.removeEventListener("mousedown",this.hide,!0)},m.prototype.onMouseOut=function(w){this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.lastEvent=null,this.isOpen&&(!w.relatedTarget||this.getElement().contains(w.relatedTarget)||w&&w.currentTarget.contains(w.relatedTarget)||w.relatedTarget.classList.contains("ace_content")||this.hide())},m}(c);r.HoverTooltip=i}),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/mouse/mouse_event","ace/tooltip","ace/config","ace/range"],function(t,r,l){var d=this&&this.__extends||function(){var i=function(a,m){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(w,x){w.__proto__=x}||function(w,x){for(var M in x)Object.prototype.hasOwnProperty.call(x,M)&&(w[M]=x[M])},i(a,m)};return function(a,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");i(a,m);function w(){this.constructor=a}a.prototype=m===null?Object.create(m):(w.prototype=m.prototype,new w)}}(),h=this&&this.__values||function(i){var a=typeof Symbol=="function"&&Symbol.iterator,m=a&&i[a],w=0;if(m)return m.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&w>=i.length&&(i=void 0),{value:i&&i[w++],done:!i}}};throw new TypeError(a?"Object is not iterable.":"Symbol.iterator is not defined.")},b=t("../lib/dom"),p=t("./mouse_event").MouseEvent,g=t("../tooltip").HoverTooltip,o=t("../config").nls,c=t("../range").Range;function f(i){var a=i.editor,m=a.renderer.$gutterLayer;i.$tooltip=new u(a),i.$tooltip.addToEditor(a),i.$tooltip.setDataProvider(function(w,x){var M=w.getDocumentPosition().row;i.$tooltip.showTooltip(M)}),i.editor.setDefaultHandler("guttermousedown",function(w){if(!(!a.isFocused()||w.getButton()!=0)){var x=m.getRegion(w);if(x!="foldWidgets"){var M=w.getDocumentPosition().row,$=a.session.selection;if(w.getShiftKey())$.selectTo(M,0);else{if(w.domEvent.detail==2)return a.selectAll(),w.preventDefault();i.$clickSelection=a.selection.getLineRange(M)}return i.setState("selectByLines"),i.captureMouse(w),w.preventDefault()}}})}r.GutterHandler=f;var u=function(i){d(a,i);function a(m){var w=i.call(this,m.container)||this;w.id="gt"+ ++a.$uid,w.editor=m,w.visibleTooltipRow;var x=w.getElement();return x.setAttribute("role","tooltip"),x.setAttribute("id",w.id),x.style.pointerEvents="auto",w.idleTime=50,w.onDomMouseMove=w.onDomMouseMove.bind(w),w.onDomMouseOut=w.onDomMouseOut.bind(w),w.setClassName("ace_gutter-tooltip"),w}return a.prototype.onDomMouseMove=function(m){var w=new p(m,this.editor);this.onMouseMove(w,this.editor)},a.prototype.onDomMouseOut=function(m){var w=new p(m,this.editor);this.onMouseOut(w)},a.prototype.addToEditor=function(m){var w=m.renderer.$gutter;w.addEventListener("mousemove",this.onDomMouseMove),w.addEventListener("mouseout",this.onDomMouseOut),i.prototype.addToEditor.call(this,m)},a.prototype.removeFromEditor=function(m){var w=m.renderer.$gutter;w.removeEventListener("mousemove",this.onDomMouseMove),w.removeEventListener("mouseout",this.onDomMouseOut),i.prototype.removeFromEditor.call(this,m)},a.prototype.destroy=function(){this.editor&&this.removeFromEditor(this.editor),i.prototype.destroy.call(this)},Object.defineProperty(a,"annotationLabels",{get:function(){return{error:{singular:o("gutter-tooltip.aria-label.error.singular","error"),plural:o("gutter-tooltip.aria-label.error.plural","errors")},security:{singular:o("gutter-tooltip.aria-label.security.singular","security finding"),plural:o("gutter-tooltip.aria-label.security.plural","security findings")},warning:{singular:o("gutter-tooltip.aria-label.warning.singular","warning"),plural:o("gutter-tooltip.aria-label.warning.plural","warnings")},info:{singular:o("gutter-tooltip.aria-label.info.singular","information message"),plural:o("gutter-tooltip.aria-label.info.plural","information messages")},hint:{singular:o("gutter-tooltip.aria-label.hint.singular","suggestion"),plural:o("gutter-tooltip.aria-label.hint.plural","suggestions")}}},enumerable:!1,configurable:!0}),a.prototype.showTooltip=function(m){var w,x=this.editor.renderer.$gutterLayer,M=x.$annotations[m],$;M?$={displayText:Array.from(M.displayText),type:Array.from(M.type)}:$={displayText:[],type:[]};var S=x.session.getFoldLine(m);if(S&&x.$showFoldedAnnotations){for(var k={error:[],security:[],warning:[],info:[],hint:[]},T={error:1,security:2,warning:3,info:4,hint:5},D,L=m+1;L<=S.end.row;L++)if(x.$annotations[L])for(var O=0;O<x.$annotations[L].text.length;O++){var z=x.$annotations[L].type[O];k[z].push(x.$annotations[L].text[O]),(!D||T[z]<T[D])&&(D=z)}if(["error","security","warning"].includes(D)){var P="".concat(a.annotationsToSummaryString(k)," in folded code.");$.displayText.push(P),$.type.push(D+"_fold")}}if($.displayText.length===0)return this.hide();for(var N={error:[],security:[],warning:[],info:[],hint:[]},A=x.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",L=0;L<$.displayText.length;L++){var _=b.createElement("span"),I=b.createElement("span");(w=I.classList).add.apply(w,["ace_".concat($.type[L]),A]),I.setAttribute("aria-label","".concat(a.annotationLabels[$.type[L].replace("_fold","")].singular)),I.setAttribute("role","img"),I.appendChild(b.createTextNode(" ")),_.appendChild(I),_.appendChild(b.createTextNode($.displayText[L])),_.appendChild(b.createElement("br")),N[$.type[L].replace("_fold","")].push(_)}var j=b.createElement("span");N.error.forEach(function(Z){return j.appendChild(Z)}),N.security.forEach(function(Z){return j.appendChild(Z)}),N.warning.forEach(function(Z){return j.appendChild(Z)}),N.info.forEach(function(Z){return j.appendChild(Z)}),N.hint.forEach(function(Z){return j.appendChild(Z)}),j.setAttribute("aria-live","polite");var U=this.$findLinkedAnnotationNode(m);U&&U.setAttribute("aria-describedby",this.id);var K=c.fromPoints({row:m,column:0},{row:m,column:0});this.showForRange(this.editor,K,j),this.visibleTooltipRow=m,this.editor._signal("showGutterTooltip",this)},a.prototype.$setPosition=function(m,w,x,M){var $=this.$findCellByRow(M.start.row);if($){var S=$&&$.element,k=S&&S.querySelector(".ace_gutter_annotation");if(k){var T=k.getBoundingClientRect();if(T){var D={pageX:T.right,pageY:T.top};return i.prototype.$setPosition.call(this,m,D,!1,M)}}}},a.prototype.$shouldPlaceAbove=function(m,w,x){return x<m},a.prototype.$findLinkedAnnotationNode=function(m){var w=this.$findCellByRow(m);if(w){var x=w.element;if(x.childNodes.length>2)return x.childNodes[2]}},a.prototype.$findCellByRow=function(m){return this.editor.renderer.$gutterLayer.$lines.cells.find(function(w){return w.row===m})},a.prototype.hide=function(m){if(this.isOpen){if(this.$element.removeAttribute("aria-live"),this.visibleTooltipRow!=null){var w=this.$findLinkedAnnotationNode(this.visibleTooltipRow);w&&w.removeAttribute("aria-describedby")}this.visibleTooltipRow=void 0,this.editor._signal("hideGutterTooltip",this),i.prototype.hide.call(this,m)}},a.annotationsToSummaryString=function(m){var w,x,M=[],$=["error","security","warning","info","hint"];try{for(var S=h($),k=S.next();!k.done;k=S.next()){var T=k.value;if(m[T].length){var D=m[T].length===1?a.annotationLabels[T].singular:a.annotationLabels[T].plural;M.push("".concat(m[T].length," ").concat(D))}}}catch(L){w={error:L}}finally{try{k&&!k.done&&(x=S.return)&&x.call(S)}finally{if(w)throw w.error}}return M.join(", ")},a.prototype.isOutsideOfText=function(m){var w=m.editor,x=w.renderer.$gutter.getBoundingClientRect();return!(m.clientX>=x.left&&m.clientX<=x.right&&m.clientY>=x.top&&m.clientY<=x.bottom)},a}(g);u.$uid=0,r.GutterTooltip=u}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(t,r,l){var d=t("../lib/dom"),h=t("../lib/event"),b=t("../lib/useragent"),p=200,g=200,o=5;function c(u){var i=u.editor,a=d.createElement("div");a.style.cssText="top:-100px;position:absolute;z-index:2147483647;opacity:0.5",a.textContent=" ";var m=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];m.forEach(function(ne){u[ne]=this[ne]},this),i.on("mousedown",this.onMouseDown.bind(u));var w=i.container,x,M,$,S,k,T,D=0,L,O,z,P,N;this.onDragStart=function(ne){if(this.cancelDrag||!w.draggable){var se=this;return setTimeout(function(){se.startSelect(),se.captureMouse(ne)},0),ne.preventDefault()}k=i.getSelectionRange();var ce=ne.dataTransfer;ce.effectAllowed=i.getReadOnly()?"copy":"copyMove",i.container.appendChild(a),ce.setDragImage&&ce.setDragImage(a,0,0),setTimeout(function(){i.container.removeChild(a)}),ce.clearData(),ce.setData("Text",i.session.getTextRange()),O=!0,this.setState("drag")},this.onDragEnd=function(ne){if(w.draggable=!1,O=!1,this.setState(null),!i.getReadOnly()){var se=ne.dataTransfer.dropEffect;!L&&se=="move"&&i.session.remove(i.getSelectionRange()),i.$resetCursorStyle()}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(ne){if(!(i.getReadOnly()||!J(ne.dataTransfer)))return M=ne.clientX,$=ne.clientY,x||j(),D++,ne.dataTransfer.dropEffect=L=ae(ne),h.preventDefault(ne)},this.onDragOver=function(ne){if(!(i.getReadOnly()||!J(ne.dataTransfer)))return M=ne.clientX,$=ne.clientY,x||(j(),D++),K!==null&&(K=null),ne.dataTransfer.dropEffect=L=ae(ne),h.preventDefault(ne)},this.onDragLeave=function(ne){if(D--,D<=0&&x)return U(),L=null,h.preventDefault(ne)},this.onDrop=function(ne){if(T){var se=ne.dataTransfer;if(O)switch(L){case"move":k.contains(T.row,T.column)?k={start:T,end:T}:k=i.moveText(k,T);break;case"copy":k=i.moveText(k,T,!0);break}else{var ce=se.getData("Text");k={start:T,end:i.session.insert(T,ce)},i.focus(),L=null}return U(),h.preventDefault(ne)}},h.addListener(w,"dragstart",this.onDragStart.bind(u),i),h.addListener(w,"dragend",this.onDragEnd.bind(u),i),h.addListener(w,"dragenter",this.onDragEnter.bind(u),i),h.addListener(w,"dragover",this.onDragOver.bind(u),i),h.addListener(w,"dragleave",this.onDragLeave.bind(u),i),h.addListener(w,"drop",this.onDrop.bind(u),i);function A(ne,se){var ce=Date.now(),he=!se||ne.row!=se.row,ge=!se||ne.column!=se.column;if(!P||he||ge)i.moveCursorToPosition(ne),P=ce,N={x:M,y:$};else{var Ee=f(N.x,N.y,M,$);Ee>o?P=null:ce-P>=g&&(i.renderer.scrollCursorIntoView(),P=null)}}function _(ne,se){var ce=Date.now(),he=i.renderer.layerConfig.lineHeight,ge=i.renderer.layerConfig.characterWidth,Ee=i.renderer.scroller.getBoundingClientRect(),Te={x:{left:M-Ee.left,right:Ee.right-M},y:{top:$-Ee.top,bottom:Ee.bottom-$}},Me=Math.min(Te.x.left,Te.x.right),Xe=Math.min(Te.y.top,Te.y.bottom),Ke={row:ne.row,column:ne.column};Me/ge<=2&&(Ke.column+=Te.x.left<Te.x.right?-3:2),Xe/he<=1&&(Ke.row+=Te.y.top<Te.y.bottom?-1:1);var dt=ne.row!=Ke.row,rt=ne.column!=Ke.column,gt=!se||ne.row!=se.row;dt||rt&&!gt?z?ce-z>=p&&i.renderer.scrollCursorIntoView(Ke):z=ce:z=null}function I(){var ne=T;T=i.renderer.screenToTextCoordinates(M,$),A(T,ne),_(T,ne)}function j(){k=i.selection.toOrientedRange(),x=i.session.addMarker(k,"ace_selection",i.getSelectionStyle()),i.clearSelection(),i.isFocused()&&i.renderer.$cursorLayer.setBlinking(!1),clearInterval(S),I(),S=setInterval(I,20),D=0,h.addListener(document,"mousemove",Z)}function U(){clearInterval(S),i.session.removeMarker(x),x=null,i.selection.fromOrientedRange(k),i.isFocused()&&!O&&i.$resetCursorStyle(),k=null,T=null,D=0,z=null,P=null,h.removeListener(document,"mousemove",Z)}var K=null;function Z(){K==null&&(K=setTimeout(function(){K!=null&&x&&U()},20))}function J(ne){var se=ne.types;return!se||Array.prototype.some.call(se,function(ce){return ce=="text/plain"||ce=="Text"})}function ae(ne){var se=["copy","copymove","all","uninitialized"],ce=["move","copymove","linkmove","all","uninitialized"],he=b.isMac?ne.altKey:ne.ctrlKey,ge="uninitialized";try{ge=ne.dataTransfer.effectAllowed.toLowerCase()}catch{}var Ee="none";return he&&se.indexOf(ge)>=0?Ee="copy":ce.indexOf(ge)>=0?Ee="move":se.indexOf(ge)>=0&&(Ee="copy"),Ee}}(function(){this.dragWait=function(){var u=Date.now()-this.mousedownEvent.time;u>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var u=this.editor.container;u.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(u){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var u=this.editor,i=u.container;i.draggable=!0,u.renderer.$cursorLayer.setBlinking(!1),u.setStyle("ace_dragging");var a=b.isWin?"default":"move";u.renderer.setCursorStyle(a),this.setState("dragReady")},this.onMouseDrag=function(u){var i=this.editor.container;if(b.isIE&&this.state=="dragReady"){var a=f(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);a>3&&i.dragDrop()}if(this.state==="dragWait"){var a=f(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);a>0&&(i.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(u){if(this.$dragEnabled){this.mousedownEvent=u;var i=this.editor,a=u.inSelection(),m=u.getButton(),w=u.domEvent.detail||1;if(w===1&&m===0&&a){if(u.editor.inMultiSelectMode&&(u.getAccelKey()||u.getShiftKey()))return;this.mousedownEvent.time=Date.now();var x=u.domEvent.target||u.domEvent.srcElement;if("unselectable"in x&&(x.unselectable="on"),i.getDragDelay()){if(b.isWebKit){this.cancelDrag=!0;var M=i.container;M.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(u,this.onMouseDrag.bind(this)),u.defaultPrevented=!0}}}}).call(c.prototype);function f(u,i,a,m){return Math.sqrt(Math.pow(a-u,2)+Math.pow(m-i,2))}r.DragdropHandler=c}),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],function(t,r,l){var d=t("./mouse_event").MouseEvent,h=t("../lib/event"),b=t("../lib/dom");r.addTouchListeners=function(p,g){var o="scroll",c,f,u,i,a,m,w=0,x,M=0,$=0,S=0,k,T;function D(){var A=window.navigator&&window.navigator.clipboard,_=!1,I=function(){var K=g.getCopyText(),Z=g.session.getUndoManager().hasUndo();T.replaceChild(b.buildDom(_?["span",!K&&j("selectall")&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],K&&j("copy")&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],K&&j("cut")&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],A&&j("paste")&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],Z&&j("undo")&&["span",{class:"ace_mobile-button",action:"undo"},"Undo"],j("find")&&["span",{class:"ace_mobile-button",action:"find"},"Find"],j("openCommandPalette")&&["span",{class:"ace_mobile-button",action:"openCommandPalette"},"Palette"]]:["span"]),T.firstChild)},j=function(K){return g.commands.canExecute(K,g)},U=function(K){var Z=K.target.getAttribute("action");if(Z=="more"||!_)return _=!_,I();Z=="paste"?A.readText().then(function(J){g.execCommand(Z,J)}):Z&&((Z=="cut"||Z=="copy")&&(A?A.writeText(g.getCopyText()):document.execCommand("copy")),g.execCommand(Z)),T.firstChild.style.display="none",_=!1,Z!="openCommandPalette"&&g.focus()};T=b.buildDom(["div",{class:"ace_mobile-menu",ontouchstart:function(K){o="menu",K.stopPropagation(),K.preventDefault(),g.textInput.focus()},ontouchend:function(K){K.stopPropagation(),K.preventDefault(),U(K)},onclick:U},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],g.container)}function L(){if(!g.getOption("enableMobileMenu")){T&&O();return}T||D();var A=g.selection.cursor,_=g.renderer.textToScreenCoordinates(A.row,A.column),I=g.renderer.textToScreenCoordinates(0,0).pageX,j=g.renderer.scrollLeft,U=g.container.getBoundingClientRect();T.style.top=_.pageY-U.top-3+"px",_.pageX-U.left<U.width-70?(T.style.left="",T.style.right="10px"):(T.style.right="",T.style.left=I+j-U.left+"px"),T.style.display="",T.firstChild.style.display="none",g.on("input",O)}function O(A){T&&(T.style.display="none"),g.off("input",O)}function z(){a=null,clearTimeout(a);var A=g.selection.getRange(),_=A.contains(x.row,x.column);(A.isEmpty()||!_)&&(g.selection.moveToPosition(x),g.selection.selectWord()),o="wait",L()}function P(){a=null,clearTimeout(a),g.selection.moveToPosition(x);var A=M>=2?g.selection.getLineRange(x.row):g.session.getBracketRange(x);A&&!A.isEmpty()?g.selection.setRange(A):g.selection.selectWord(),o="wait"}h.addListener(p,"contextmenu",function(A){if(k){var _=g.textInput.getElement();_.focus()}},g),h.addListener(p,"touchstart",function(A){var _=A.touches;if(a||_.length>1){clearTimeout(a),a=null,u=-1,o="zoom";return}k=g.$mouseHandler.isMousePressed=!0;var I=g.renderer.layerConfig.lineHeight,j=g.renderer.layerConfig.lineHeight,U=A.timeStamp;i=U;var K=_[0],Z=K.clientX,J=K.clientY;Math.abs(c-Z)+Math.abs(f-J)>I&&(u=-1),c=A.clientX=Z,f=A.clientY=J,$=S=0;var ae=new d(A,g);if(x=ae.getDocumentPosition(),U-u<500&&_.length==1&&!w)M++,A.preventDefault(),A.button=0,P();else{M=0;var ne=g.selection.cursor,se=g.selection.isEmpty()?ne:g.selection.anchor,ce=g.renderer.$cursorLayer.getPixelPosition(ne,!0),he=g.renderer.$cursorLayer.getPixelPosition(se,!0),ge=g.renderer.scroller.getBoundingClientRect(),Ee=g.renderer.layerConfig.offset,Te=g.renderer.scrollLeft,Me=function(dt,rt){return dt=dt/j,rt=rt/I-.75,dt*dt+rt*rt};if(A.clientX<ge.left){o="zoom";return}var Xe=Me(A.clientX-ge.left-ce.left+Te,A.clientY-ge.top-ce.top+Ee),Ke=Me(A.clientX-ge.left-he.left+Te,A.clientY-ge.top-he.top+Ee);Xe<3.5&&Ke<3.5&&(o=Xe>Ke?"cursor":"anchor"),Ke<3.5?o="anchor":Xe<3.5?o="cursor":o="scroll",a=setTimeout(z,450)}u=U},g),h.addListener(p,"touchend",function(A){k=g.$mouseHandler.isMousePressed=!1,m&&clearInterval(m),o=="zoom"?(o="",w=0):a?(g.selection.moveToPosition(x),w=0,L()):o=="scroll"?(N(),O()):L(),clearTimeout(a),a=null},g),h.addListener(p,"touchmove",function(A){a&&(clearTimeout(a),a=null);var _=A.touches;if(!(_.length>1||o=="zoom")){var I=_[0],j=c-I.clientX,U=f-I.clientY;if(o=="wait")if(j*j+U*U>4)o="cursor";else return A.preventDefault();c=I.clientX,f=I.clientY,A.clientX=I.clientX,A.clientY=I.clientY;var K=A.timeStamp,Z=K-i;if(i=K,o=="scroll"){var J=new d(A,g);J.speed=1,J.wheelX=j,J.wheelY=U,10*Math.abs(j)<Math.abs(U)&&(j=0),10*Math.abs(U)<Math.abs(j)&&(U=0),Z!=0&&($=j/Z,S=U/Z),g._emit("mousewheel",J),J.propagationStopped||($=S=0)}else{var ae=new d(A,g),ne=ae.getDocumentPosition();o=="cursor"?g.selection.moveCursorToPosition(ne):o=="anchor"&&g.selection.setSelectionAnchor(ne.row,ne.column),g.renderer.scrollCursorIntoView(ne),A.preventDefault()}}},g);function N(){w+=60,m=setInterval(function(){w--<=0&&(clearInterval(m),m=null),Math.abs($)<.01&&($=0),Math.abs(S)<.01&&(S=0),w<20&&($=.9*$),w<20&&(S=.9*S);var A=g.session.getScrollTop();g.renderer.scrollBy(10*$,10*S),A==g.session.getScrollTop()&&(w=0)},10)}}}),ace.define("ace/mouse/mouse_handler",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/mouse/default_handlers","ace/mouse/default_gutter_handler","ace/mouse/mouse_event","ace/mouse/dragdrop_handler","ace/mouse/touch_handler","ace/config"],function(t,r,l){var d=t("../lib/event"),h=t("../lib/useragent"),b=t("./default_handlers").DefaultHandlers,p=t("./default_gutter_handler").GutterHandler,g=t("./mouse_event").MouseEvent,o=t("./dragdrop_handler").DragdropHandler,c=t("./touch_handler").addTouchListeners,f=t("../config"),u=function(){function i(a){this.$dragDelay,this.$dragEnabled,this.$mouseMoved,this.mouseEvent,this.$focusTimeout;var m=this;this.editor=a,new b(this),new p(this),new o(this);var w=function($){var S=!document.hasFocus||!document.hasFocus()||!a.isFocused()&&document.activeElement==(a.textInput&&a.textInput.getElement());S&&window.focus(),a.focus(),setTimeout(function(){a.isFocused()||a.focus()})},x=a.renderer.getMouseEventTarget();d.addListener(x,"click",this.onMouseEvent.bind(this,"click"),a),d.addListener(x,"mousemove",this.onMouseMove.bind(this,"mousemove"),a),d.addMultiMouseDownListener([x,a.renderer.scrollBarV&&a.renderer.scrollBarV.inner,a.renderer.scrollBarH&&a.renderer.scrollBarH.inner,a.textInput&&a.textInput.getElement()].filter(Boolean),[400,300,250],this,"onMouseEvent",a),d.addMouseWheelListener(a.container,this.onMouseWheel.bind(this,"mousewheel"),a),c(a.container,a);var M=a.renderer.$gutter;d.addListener(M,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"),a),d.addListener(M,"click",this.onMouseEvent.bind(this,"gutterclick"),a),d.addListener(M,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"),a),d.addListener(M,"mousemove",this.onMouseEvent.bind(this,"guttermousemove"),a),d.addListener(x,"mousedown",w,a),d.addListener(M,"mousedown",w,a),h.isIE&&a.renderer.scrollBarV&&(d.addListener(a.renderer.scrollBarV.element,"mousedown",w,a),d.addListener(a.renderer.scrollBarH.element,"mousedown",w,a)),a.on("mousemove",function($){if(!(m.state||m.$dragDelay||!m.$dragEnabled)){var S=a.renderer.screenToTextCoordinates($.x,$.y),k=a.session.selection.getRange(),T=a.renderer;!k.isEmpty()&&k.insideStart(S.row,S.column)?T.setCursorStyle("default"):T.setCursorStyle("")}},a)}return i.prototype.onMouseEvent=function(a,m){this.editor.session&&this.editor._emit(a,new g(m,this.editor))},i.prototype.onMouseMove=function(a,m){var w=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;!w||!w.length||this.editor._emit(a,new g(m,this.editor))},i.prototype.onMouseWheel=function(a,m){var w=new g(m,this.editor);w.speed=this.$scrollSpeed*2,w.wheelX=m.wheelX,w.wheelY=m.wheelY,this.editor._emit(a,w)},i.prototype.setState=function(a){this.state=a},i.prototype.captureMouse=function(a,m){this.x=a.x,this.y=a.y,this.isMousePressed=!0;var w=this.editor,x=this.editor.renderer;x.$isMousePressed=!0;var M=this,$=!0,S=function(O){if(O){if(h.isWebKit&&!O.which&&M.releaseMouse)return M.releaseMouse();M.x=O.clientX,M.y=O.clientY,m&&m(O),M.mouseEvent=new g(O,M.editor),M.$mouseMoved=!0}},k=function(O){w.off("beforeEndOperation",L),$=!1,w.session&&T(),M[M.state+"End"]&&M[M.state+"End"](O),M.state="",M.isMousePressed=x.$isMousePressed=!1,x.$keepTextAreaAtCursor&&x.$moveTextAreaToCursor(),M.$onCaptureMouseMove=M.releaseMouse=null,O&&M.onMouseEvent("mouseup",O),w.endOperation()},T=function(){M[M.state]&&M[M.state](),M.$mouseMoved=!1},D=function(){$&&(T(),d.nextFrame(D))};if(h.isOldIE&&a.domEvent.type=="dblclick")return setTimeout(function(){k(a)});var L=function(O){M.releaseMouse&&w.curOp.command.name&&w.curOp.selectionChanged&&(M[M.state+"End"]&&M[M.state+"End"](),M.state="",M.releaseMouse())};w.on("beforeEndOperation",L),w.startOperation({command:{name:"mouse"}}),M.$onCaptureMouseMove=S,M.releaseMouse=d.capture(this.editor.container,S,k),D()},i.prototype.cancelContextMenu=function(){var a=(function(m){m&&m.domEvent&&m.domEvent.type!="contextmenu"||(this.editor.off("nativecontextmenu",a),m&&m.domEvent&&d.stopEvent(m.domEvent))}).bind(this);setTimeout(a,10),this.editor.on("nativecontextmenu",a)},i.prototype.destroy=function(){this.releaseMouse&&this.releaseMouse(),this.$tooltip&&this.$tooltip.destroy()},i}();u.prototype.releaseMouse=null,f.defineOptions(u.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:h.isMac?150:0},dragEnabled:{initialValue:!0},focusTimeout:{initialValue:0}}),r.MouseHandler=u}),ace.define("ace/mouse/fold_handler",["require","exports","module","ace/lib/dom"],function(t,r,l){var d=t("../lib/dom"),h=function(){function b(p){p.on("click",function(g){var o=g.getDocumentPosition(),c=p.session,f=c.getFoldAt(o.row,o.column,1);f&&(g.getAccelKey()?c.removeFold(f):c.expandFold(f),g.stop());var u=g.domEvent&&g.domEvent.target;u&&d.hasCssClass(u,"ace_inline_button")&&d.hasCssClass(u,"ace_toggle_wrap")&&(c.setOption("wrap",!c.getUseWrapMode()),p.renderer.scrollCursorIntoView())}),p.on("gutterclick",function(g){var o=p.renderer.$gutterLayer.getRegion(g);if(o=="foldWidgets"){var c=g.getDocumentPosition().row,f=p.session;f.foldWidgets&&f.foldWidgets[c]&&p.session.onFoldWidgetClick(c,g),p.isFocused()||p.focus(),g.stop()}}),p.on("gutterdblclick",function(g){var o=p.renderer.$gutterLayer.getRegion(g);if(o=="foldWidgets"){var c=g.getDocumentPosition().row,f=p.session,u=f.getParentFoldRangeData(c,!0),i=u.range||u.firstRange;if(i){c=i.start.row;var a=f.getFoldAt(c,f.getLine(c).length,1);a?f.removeFold(a):(f.addFold("...",i),p.renderer.scrollCursorIntoView({row:i.start.row,column:0}))}g.stop()}})}return b}();r.FoldHandler=h}),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(t,r,l){var d=t("../lib/keys"),h=t("../lib/event"),b=function(){function p(g){this.$editor=g,this.$data={editor:g},this.$handlers=[],this.setDefaultHandler(g.commands)}return p.prototype.setDefaultHandler=function(g){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=g,this.addKeyboardHandler(g,0)},p.prototype.setKeyboardHandler=function(g){var o=this.$handlers;if(o[o.length-1]!=g){for(;o[o.length-1]&&o[o.length-1]!=this.$defaultHandler;)this.removeKeyboardHandler(o[o.length-1]);this.addKeyboardHandler(g,1)}},p.prototype.addKeyboardHandler=function(g,o){if(g){typeof g=="function"&&!g.handleKeyboard&&(g.handleKeyboard=g);var c=this.$handlers.indexOf(g);c!=-1&&this.$handlers.splice(c,1),o==null?this.$handlers.push(g):this.$handlers.splice(o,0,g),c==-1&&g.attach&&g.attach(this.$editor)}},p.prototype.removeKeyboardHandler=function(g){var o=this.$handlers.indexOf(g);return o==-1?!1:(this.$handlers.splice(o,1),g.detach&&g.detach(this.$editor),!0)},p.prototype.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},p.prototype.getStatusText=function(){var g=this.$data,o=g.editor;return this.$handlers.map(function(c){return c.getStatusText&&c.getStatusText(o,g)||""}).filter(Boolean).join(" ")},p.prototype.$callKeyboardHandlers=function(g,o,c,f){for(var u,i=!1,a=this.$editor.commands,m=this.$handlers.length;m--&&(u=this.$handlers[m].handleKeyboard(this.$data,g,o,c,f),!(!(!u||!u.command)&&(u.command=="null"?i=!0:i=a.exec(u.command,this.$editor,u.args,f),i&&f&&g!=-1&&u.passEvent!=!0&&u.command.passEvent!=!0&&h.stopEvent(f),i))););return!i&&g==-1&&(u={command:"insertstring"},i=a.exec("insertstring",this.$editor,o)),i&&this.$editor._signal&&this.$editor._signal("keyboardActivity",u),i},p.prototype.onCommandKey=function(g,o,c){var f=d.keyCodeToString(c);return this.$callKeyboardHandlers(o,f,c,g)},p.prototype.onTextInput=function(g){return this.$callKeyboardHandlers(-1,g)},p}();r.KeyBinding=b}),ace.define("ace/lib/bidiutil",["require","exports","module"],function(t,r,l){var d=0,h=0,b=!1,p=!1,g=!1,o=[[0,3,0,1,0,0,0],[0,3,0,1,2,2,0],[0,3,0,17,2,0,1],[0,3,5,5,4,1,0],[0,3,21,21,4,0,1],[0,3,5,5,4,2,0]],c=[[2,0,1,1,0,1,0],[2,0,1,1,0,2,0],[2,0,2,1,3,2,0],[2,0,2,33,3,1,1]],f=0,u=1,i=0,a=1,m=2,w=3,x=4,M=5,$=6,S=7,k=8,T=9,D=10,L=11,O=12,z=13,P=14,N=15,A=16,_=17,I=18,j=[I,I,I,I,I,I,I,I,I,$,M,$,k,M,I,I,I,I,I,I,I,I,I,I,I,I,I,I,M,M,M,$,k,x,x,L,L,L,x,x,x,x,x,D,T,D,T,T,m,m,m,m,m,m,m,m,m,m,T,x,x,x,x,x,x,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,x,x,x,x,x,x,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,x,x,x,x,I,I,I,I,I,I,M,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,I,T,x,L,L,L,L,x,x,x,x,i,x,x,I,x,x,L,L,m,m,x,i,x,x,x,m,i,x,x,x,x,x],U=[k,k,k,k,k,k,k,k,k,k,k,I,I,I,i,a,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,k,M,z,P,N,A,_,T,L,L,L,L,L,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,T,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,k];function K(ne,se,ce,he){var ge=d?c:o,Ee=null,Te=null,Me=null,Xe=0,Ke=null,dt=null,rt=-1,gt=null,tn=null,jn=[];if(!he)for(gt=0,he=[];gt<ce;gt++)he[gt]=ae(ne[gt]);for(h=d,b=!1,p=!1,g=!1,tn=0;tn<ce;tn++){if(Ee=Xe,jn[tn]=Te=J(ne,he,jn,tn),Xe=ge[Ee][Te],Ke=Xe&240,Xe&=15,se[tn]=Me=ge[Xe][5],Ke>0)if(Ke==16){for(gt=rt;gt<tn;gt++)se[gt]=1;rt=-1}else rt=-1;if(dt=ge[Xe][6],dt)rt==-1&&(rt=tn);else if(rt>-1){for(gt=rt;gt<tn;gt++)se[gt]=Me;rt=-1}he[tn]==M&&(se[tn]=0),h|=Me}if(g){for(gt=0;gt<ce;gt++)if(he[gt]==$){se[gt]=d;for(var Zt=gt-1;Zt>=0&&he[Zt]==k;Zt--)se[Zt]=d}}}function Z(ne,se,ce){if(!(h<ne)){if(ne==1&&d==u&&!p){ce.reverse();return}for(var he=ce.length,ge=0,Ee,Te,Me,Xe;ge<he;){if(se[ge]>=ne){for(Ee=ge+1;Ee<he&&se[Ee]>=ne;)Ee++;for(Te=ge,Me=Ee-1;Te<Me;Te++,Me--)Xe=ce[Te],ce[Te]=ce[Me],ce[Me]=Xe;ge=Ee}ge++}}}function J(ne,se,ce,he){var ge=se[he],Ee,Te,Me,Xe;switch(ge){case i:case a:b=!1;case x:case w:return ge;case m:return b?w:m;case S:return b=!0,a;case k:return x;case T:return he<1||he+1>=se.length||(Ee=ce[he-1])!=m&&Ee!=w||(Te=se[he+1])!=m&&Te!=w?x:(b&&(Te=w),Te==Ee?Te:x);case D:return Ee=he>0?ce[he-1]:M,Ee==m&&he+1<se.length&&se[he+1]==m?m:x;case L:if(he>0&&ce[he-1]==m)return m;if(b)return x;for(Xe=he+1,Me=se.length;Xe<Me&&se[Xe]==L;)Xe++;return Xe<Me&&se[Xe]==m?m:x;case O:for(Me=se.length,Xe=he+1;Xe<Me&&se[Xe]==O;)Xe++;if(Xe<Me){var Ke=ne[he],dt=Ke>=1425&&Ke<=2303||Ke==64286;if(Ee=se[Xe],dt&&(Ee==a||Ee==S))return a}return he<1||(Ee=se[he-1])==M?x:ce[he-1];case M:return b=!1,p=!0,d;case $:return g=!0,x;case z:case P:case A:case _:case N:b=!1;case I:return x}}function ae(ne){var se=ne.charCodeAt(0),ce=se>>8;return ce==0?se>191?i:j[se]:ce==5?/[\u0591-\u05f4]/.test(ne)?a:i:ce==6?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(ne)?O:/[\u0660-\u0669\u066b-\u066c]/.test(ne)?w:se==1642?L:/[\u06f0-\u06f9]/.test(ne)?m:S:ce==32&&se<=8287?U[se&255]:ce==254&&se>=65136?S:x}r.L=i,r.R=a,r.EN=m,r.ON_R=3,r.AN=4,r.R_H=5,r.B=6,r.RLE=7,r.DOT="·",r.doBidiReorder=function(ne,se,ce){if(ne.length<2)return{};var he=ne.split(""),ge=new Array(he.length),Ee=new Array(he.length),Te=[];d=ce?u:f,K(he,Te,he.length,se);for(var Me=0;Me<ge.length;ge[Me]=Me,Me++);Z(2,Te,ge),Z(1,Te,ge);for(var Me=0;Me<ge.length-1;Me++)se[Me]===w?Te[Me]=r.AN:Te[Me]===a&&(se[Me]>S&&se[Me]<z||se[Me]===x||se[Me]===I)?Te[Me]=r.ON_R:Me>0&&he[Me-1]==="ل"&&/\u0622|\u0623|\u0625|\u0627/.test(he[Me])&&(Te[Me-1]=Te[Me]=r.R_H,Me++);he[he.length-1]===r.DOT&&(Te[he.length-1]=r.B),he[0]===""&&(Te[0]=r.RLE);for(var Me=0;Me<ge.length;Me++)Ee[Me]=Te[ge[Me]];return{logicalFromVisual:ge,bidiLevels:Ee}},r.hasBidiCharacters=function(ne,se){for(var ce=!1,he=0;he<ne.length;he++)se[he]=ae(ne.charAt(he)),!ce&&(se[he]==a||se[he]==S||se[he]==w)&&(ce=!0);return ce},r.getVisualFromLogicalIdx=function(ne,se){for(var ce=0;ce<se.logicalFromVisual.length;ce++)if(se.logicalFromVisual[ce]==ne)return ce;return 0}}),ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang"],function(t,r,l){var d=t("./lib/bidiutil"),h=t("./lib/lang"),b=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\u202B]/,p=function(){function g(o){this.session=o,this.bidiMap={},this.currentRow=null,this.bidiUtil=d,this.charWidths=[],this.EOL="¬",this.showInvisibles=!0,this.isRtlDir=!1,this.$isRtl=!1,this.line="",this.wrapIndent=0,this.EOF="¶",this.RLE="",this.contentWidth=0,this.fontMetrics=null,this.rtlLineOffset=0,this.wrapOffset=0,this.isMoveLeftOperation=!1,this.seenBidi=b.test(o.getValue())}return g.prototype.isBidiRow=function(o,c,f){return this.seenBidi?(o!==this.currentRow&&(this.currentRow=o,this.updateRowLine(c,f),this.updateBidiMap()),this.bidiMap.bidiLevels):!1},g.prototype.onChange=function(o){this.seenBidi?this.currentRow=null:o.action=="insert"&&b.test(o.lines.join(`
|
|
185
|
+
`))&&(this.seenBidi=!0,this.currentRow=null)},g.prototype.getDocumentRow=function(){var o=0,c=this.session.$screenRowCache;if(c.length){var f=this.session.$getRowCacheIndex(c,this.currentRow);f>=0&&(o=this.session.$docRowCache[f])}return o},g.prototype.getSplitIndex=function(){var o=0,c=this.session.$screenRowCache;if(c.length)for(var f,u=this.session.$getRowCacheIndex(c,this.currentRow);this.currentRow-o>0&&(f=this.session.$getRowCacheIndex(c,this.currentRow-o-1),f===u);)u=f,o++;else o=this.currentRow;return o},g.prototype.updateRowLine=function(o,c){o===void 0&&(o=this.getDocumentRow());var f=o===this.session.getLength()-1,u=f?this.EOF:this.EOL;if(this.wrapIndent=0,this.line=this.session.getLine(o),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE,this.session.$useWrapMode){var i=this.session.$wrapData[o];i&&(c===void 0&&(c=this.getSplitIndex()),c>0&&i.length?(this.wrapIndent=i.indent,this.wrapOffset=this.wrapIndent*this.charWidths[d.L],this.line=c<i.length?this.line.substring(i[c-1],i[c]):this.line.substring(i[i.length-1])):this.line=this.line.substring(0,i[c]),c==i.length&&(this.line+=this.showInvisibles?u:d.DOT))}else this.line+=this.showInvisibles?u:d.DOT;var a=this.session,m=0,w;this.line=this.line.replace(/\t|[\u1100-\u2029, \u202F-\uFFE6]/g,function(x,M){return x===" "||a.isFullWidth(x.charCodeAt(0))?(w=x===" "?a.getScreenTabSize(M+m):2,m+=w-1,h.stringRepeat(d.DOT,w)):x}),this.isRtlDir&&(this.fontMetrics.$main.textContent=this.line.charAt(this.line.length-1)==d.DOT?this.line.substr(0,this.line.length-1):this.line,this.rtlLineOffset=this.contentWidth-this.fontMetrics.$main.getBoundingClientRect().width)},g.prototype.updateBidiMap=function(){var o=[];d.hasBidiCharacters(this.line,o)||this.isRtlDir?this.bidiMap=d.doBidiReorder(this.line,o,this.isRtlDir):this.bidiMap={}},g.prototype.markAsDirty=function(){this.currentRow=null},g.prototype.updateCharacterWidths=function(o){if(this.characterWidth!==o.$characterSize.width){this.fontMetrics=o;var c=this.characterWidth=o.$characterSize.width,f=o.$measureCharWidth("ה");this.charWidths[d.L]=this.charWidths[d.EN]=this.charWidths[d.ON_R]=c,this.charWidths[d.R]=this.charWidths[d.AN]=f,this.charWidths[d.R_H]=f*.45,this.charWidths[d.B]=this.charWidths[d.RLE]=0,this.currentRow=null}},g.prototype.setShowInvisibles=function(o){this.showInvisibles=o,this.currentRow=null},g.prototype.setEolChar=function(o){this.EOL=o},g.prototype.setContentWidth=function(o){this.contentWidth=o},g.prototype.isRtlLine=function(o){return this.$isRtl?!0:o!=null?this.session.getLine(o).charAt(0)==this.RLE:this.isRtlDir},g.prototype.setRtlDirection=function(o,c){for(var f=o.getCursorPosition(),u=o.selection.getSelectionAnchor().row;u<=f.row;u++)!c&&o.session.getLine(u).charAt(0)===o.session.$bidiHandler.RLE?o.session.doc.removeInLine(u,0,1):c&&o.session.getLine(u).charAt(0)!==o.session.$bidiHandler.RLE&&o.session.doc.insert({column:0,row:u},o.session.$bidiHandler.RLE)},g.prototype.getPosLeft=function(o){o-=this.wrapIndent;var c=this.line.charAt(0)===this.RLE?1:0,f=o>c?this.session.getOverwrite()?o:o-1:c,u=d.getVisualFromLogicalIdx(f,this.bidiMap),i=this.bidiMap.bidiLevels,a=0;!this.session.getOverwrite()&&o<=c&&i[u]%2!==0&&u++;for(var m=0;m<u;m++)a+=this.charWidths[i[m]];return!this.session.getOverwrite()&&o>c&&i[u]%2===0&&(a+=this.charWidths[i[u]]),this.wrapIndent&&(a+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(a+=this.rtlLineOffset),a},g.prototype.getSelections=function(o,c){var f=this.bidiMap,u=f.bidiLevels,i,a=[],m=0,w=Math.min(o,c)-this.wrapIndent,x=Math.max(o,c)-this.wrapIndent,M=!1,$=!1,S=0;this.wrapIndent&&(m+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var k,T=0;T<u.length;T++)k=f.logicalFromVisual[T],i=u[T],M=k>=w&&k<x,M&&!$?S=m:!M&&$&&a.push({left:S,width:m-S}),m+=this.charWidths[i],$=M;if(M&&T===u.length&&a.push({left:S,width:m-S}),this.isRtlDir)for(var D=0;D<a.length;D++)a[D].left+=this.rtlLineOffset;return a},g.prototype.offsetToCol=function(f){this.isRtlDir&&(f-=this.rtlLineOffset);var c=0,f=Math.max(f,0),u=0,i=0,a=this.bidiMap.bidiLevels,m=this.charWidths[a[i]];for(this.wrapIndent&&(f-=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);f>u+m/2;){if(u+=m,i===a.length-1){m=0;break}m=this.charWidths[a[++i]]}return i>0&&a[i-1]%2!==0&&a[i]%2===0?(f<u&&i--,c=this.bidiMap.logicalFromVisual[i]):i>0&&a[i-1]%2===0&&a[i]%2!==0?c=1+(f>u?this.bidiMap.logicalFromVisual[i]:this.bidiMap.logicalFromVisual[i-1]):this.isRtlDir&&i===a.length-1&&m===0&&a[i-1]%2===0||!this.isRtlDir&&i===0&&a[i]%2!==0?c=1+this.bidiMap.logicalFromVisual[i]:(i>0&&a[i-1]%2!==0&&m!==0&&i--,c=this.bidiMap.logicalFromVisual[i]),c===0&&this.isRtlDir&&c++,c+this.wrapIndent},g}();r.BidiHandler=p}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(t,r,l){var d=t("./lib/oop"),h=t("./lib/lang"),b=t("./lib/event_emitter").EventEmitter,p=t("./range").Range,g=function(){function o(c){this.session=c,this.doc=c.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var f=this;this.cursor.on("change",function(u){f.$cursorChanged=!0,f.$silent||f._emit("changeCursor"),!f.$isEmpty&&!f.$silent&&f._emit("changeSelection"),!f.$keepDesiredColumnOnChange&&u.old.column!=u.value.column&&(f.$desiredColumn=null)}),this.anchor.on("change",function(){f.$anchorChanged=!0,!f.$isEmpty&&!f.$silent&&f._emit("changeSelection")})}return o.prototype.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},o.prototype.isMultiLine=function(){return!this.$isEmpty&&this.anchor.row!=this.cursor.row},o.prototype.getCursor=function(){return this.lead.getPosition()},o.prototype.setAnchor=function(c,f){this.$isEmpty=!1,this.anchor.setPosition(c,f)},o.prototype.getAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},o.prototype.getSelectionLead=function(){return this.lead.getPosition()},o.prototype.isBackwards=function(){var c=this.anchor,f=this.lead;return c.row>f.row||c.row==f.row&&c.column>f.column},o.prototype.getRange=function(){var c=this.anchor,f=this.lead;return this.$isEmpty?p.fromPoints(f,f):this.isBackwards()?p.fromPoints(f,c):p.fromPoints(c,f)},o.prototype.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},o.prototype.selectAll=function(){this.$setSelection(0,0,Number.MAX_VALUE,Number.MAX_VALUE)},o.prototype.setRange=function(c,f){var u=f?c.end:c.start,i=f?c.start:c.end;this.$setSelection(u.row,u.column,i.row,i.column)},o.prototype.$setSelection=function(c,f,u,i){if(!this.$silent){var a=this.$isEmpty,m=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(c,f),this.cursor.setPosition(u,i),this.$isEmpty=!p.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||a!=this.$isEmpty||m)&&this._emit("changeSelection")}},o.prototype.$moveSelection=function(c){var f=this.lead;this.$isEmpty&&this.setSelectionAnchor(f.row,f.column),c.call(this)},o.prototype.selectTo=function(c,f){this.$moveSelection(function(){this.moveCursorTo(c,f)})},o.prototype.selectToPosition=function(c){this.$moveSelection(function(){this.moveCursorToPosition(c)})},o.prototype.moveTo=function(c,f){this.clearSelection(),this.moveCursorTo(c,f)},o.prototype.moveToPosition=function(c){this.clearSelection(),this.moveCursorToPosition(c)},o.prototype.selectUp=function(){this.$moveSelection(this.moveCursorUp)},o.prototype.selectDown=function(){this.$moveSelection(this.moveCursorDown)},o.prototype.selectRight=function(){this.$moveSelection(this.moveCursorRight)},o.prototype.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},o.prototype.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},o.prototype.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},o.prototype.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},o.prototype.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},o.prototype.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},o.prototype.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},o.prototype.getWordRange=function(c,f){if(typeof f>"u"){var u=c||this.lead;c=u.row,f=u.column}return this.session.getWordRange(c,f)},o.prototype.selectWord=function(){this.setSelectionRange(this.getWordRange())},o.prototype.selectAWord=function(){var c=this.getCursor(),f=this.session.getAWordRange(c.row,c.column);this.setSelectionRange(f)},o.prototype.getLineRange=function(c,f){var u=typeof c=="number"?c:this.lead.row,i,a=this.session.getFoldLine(u);return a?(u=a.start.row,i=a.end.row):i=u,f===!0?new p(u,0,i,this.session.getLine(i).length):new p(u,0,i+1,0)},o.prototype.selectLine=function(){this.setSelectionRange(this.getLineRange())},o.prototype.moveCursorUp=function(){this.moveCursorBy(-1,0)},o.prototype.moveCursorDown=function(){this.moveCursorBy(1,0)},o.prototype.wouldMoveIntoSoftTab=function(c,f,u){var i=c.column,a=c.column+f;return u<0&&(i=c.column-f,a=c.column),this.session.isTabStop(c)&&this.doc.getLine(c.row).slice(i,a).split(" ").length-1==f},o.prototype.moveCursorLeft=function(){var c=this.lead.getPosition(),f;if(f=this.session.getFoldAt(c.row,c.column,-1))this.moveCursorTo(f.start.row,f.start.column);else if(c.column===0)c.row>0&&this.moveCursorTo(c.row-1,this.doc.getLine(c.row-1).length);else{var u=this.session.getTabSize();this.wouldMoveIntoSoftTab(c,u,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-u):this.moveCursorBy(0,-1)}},o.prototype.moveCursorRight=function(){var c=this.lead.getPosition(),f;if(f=this.session.getFoldAt(c.row,c.column,1))this.moveCursorTo(f.end.row,f.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row<this.doc.getLength()-1&&this.moveCursorTo(this.lead.row+1,0);else{var u=this.session.getTabSize(),c=this.lead;this.wouldMoveIntoSoftTab(c,u,1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,u):this.moveCursorBy(0,1)}},o.prototype.moveCursorLineStart=function(){var c=this.lead.row,f=this.lead.column,u=this.session.documentToScreenRow(c,f),i=this.session.screenToDocumentPosition(u,0),a=this.session.getDisplayLine(c,null,i.row,i.column),m=a.match(/^\s*/);m[0].length!=f&&!this.session.$useEmacsStyleLineStart&&(i.column+=m[0].length),this.moveCursorToPosition(i)},o.prototype.moveCursorLineEnd=function(){var c=this.lead,f=this.session.getDocumentLastRowColumnPosition(c.row,c.column);if(this.lead.column==f.column){var u=this.session.getLine(f.row);if(f.column==u.length){var i=u.search(/\s+$/);i>0&&(f.column=i)}}this.moveCursorTo(f.row,f.column)},o.prototype.moveCursorFileEnd=function(){var c=this.doc.getLength()-1,f=this.doc.getLine(c).length;this.moveCursorTo(c,f)},o.prototype.moveCursorFileStart=function(){this.moveCursorTo(0,0)},o.prototype.moveCursorLongWordRight=function(){var c=this.lead.row,f=this.lead.column,u=this.doc.getLine(c),i=u.substring(f);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var a=this.session.getFoldAt(c,f,1);if(a){this.moveCursorTo(a.end.row,a.end.column);return}if(this.session.nonTokenRe.exec(i)&&(f+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,i=u.substring(f)),f>=u.length){this.moveCursorTo(c,u.length),this.moveCursorRight(),c<this.doc.getLength()-1&&this.moveCursorWordRight();return}this.session.tokenRe.exec(i)&&(f+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(c,f)},o.prototype.moveCursorLongWordLeft=function(){var c=this.lead.row,f=this.lead.column,u;if(u=this.session.getFoldAt(c,f,-1)){this.moveCursorTo(u.start.row,u.start.column);return}var i=this.session.getFoldStringAt(c,f,-1);i==null&&(i=this.doc.getLine(c).substring(0,f));var a=h.stringReverse(i);if(this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(a)&&(f-=this.session.nonTokenRe.lastIndex,a=a.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0),f<=0){this.moveCursorTo(c,0),this.moveCursorLeft(),c>0&&this.moveCursorWordLeft();return}this.session.tokenRe.exec(a)&&(f-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(c,f)},o.prototype.$shortWordEndIndex=function(c){var f=0,u,i=/\s/,a=this.session.tokenRe;if(a.lastIndex=0,this.session.tokenRe.exec(c))f=this.session.tokenRe.lastIndex;else{for(;(u=c[f])&&i.test(u);)f++;if(f<1){for(a.lastIndex=0;(u=c[f])&&!a.test(u);)if(a.lastIndex=0,f++,i.test(u))if(f>2){f--;break}else{for(;(u=c[f])&&i.test(u);)f++;if(f>2)break}}}return a.lastIndex=0,f},o.prototype.moveCursorShortWordRight=function(){var c=this.lead.row,f=this.lead.column,u=this.doc.getLine(c),i=u.substring(f),a=this.session.getFoldAt(c,f,1);if(a)return this.moveCursorTo(a.end.row,a.end.column);if(f==u.length){var m=this.doc.getLength();do c++,i=this.doc.getLine(c);while(c<m&&/^\s*$/.test(i));/^\s+/.test(i)||(i=""),f=0}var w=this.$shortWordEndIndex(i);this.moveCursorTo(c,f+w)},o.prototype.moveCursorShortWordLeft=function(){var c=this.lead.row,f=this.lead.column,u;if(u=this.session.getFoldAt(c,f,-1))return this.moveCursorTo(u.start.row,u.start.column);var i=this.session.getLine(c).substring(0,f);if(f===0){do c--,i=this.doc.getLine(c);while(c>0&&/^\s*$/.test(i));f=i.length,/\s+$/.test(i)||(i="")}var a=h.stringReverse(i),m=this.$shortWordEndIndex(a);return this.moveCursorTo(c,f-m)},o.prototype.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},o.prototype.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},o.prototype.moveCursorBy=function(c,f){var u=this.session.documentToScreenPosition(this.lead.row,this.lead.column),i;if(f===0&&(c!==0&&(this.session.$bidiHandler.isBidiRow(u.row,this.lead.row)?(i=this.session.$bidiHandler.getPosLeft(u.column),u.column=Math.round(i/this.session.$bidiHandler.charWidths[0])):i=u.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?u.column=this.$desiredColumn:this.$desiredColumn=u.column),c!=0&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var a=this.session.lineWidgets[this.lead.row];c<0?c-=a.rowsAbove||0:c>0&&(c+=a.rowCount-(a.rowsAbove||0))}var m=this.session.screenToDocumentPosition(u.row+c,u.column,i);c!==0&&f===0&&m.row===this.lead.row&&(m.column,this.lead.column),this.moveCursorTo(m.row,m.column+f,f===0)},o.prototype.moveCursorToPosition=function(c){this.moveCursorTo(c.row,c.column)},o.prototype.moveCursorTo=function(c,f,u){var i=this.session.getFoldAt(c,f,1);i&&(c=i.start.row,f=i.start.column),this.$keepDesiredColumnOnChange=!0;var a=this.session.getLine(c);/[\uDC00-\uDFFF]/.test(a.charAt(f))&&a.charAt(f-1)&&(this.lead.row==c&&this.lead.column==f+1?f=f-1:f=f+1),this.lead.setPosition(c,f),this.$keepDesiredColumnOnChange=!1,u||(this.$desiredColumn=null)},o.prototype.moveCursorToScreen=function(c,f,u){var i=this.session.screenToDocumentPosition(c,f);this.moveCursorTo(i.row,i.column,u)},o.prototype.detach=function(){this.lead.detach(),this.anchor.detach()},o.prototype.fromOrientedRange=function(c){this.setSelectionRange(c,c.cursor==c.start),this.$desiredColumn=c.desiredColumn||this.$desiredColumn},o.prototype.toOrientedRange=function(c){var f=this.getRange();return c?(c.start.column=f.start.column,c.start.row=f.start.row,c.end.column=f.end.column,c.end.row=f.end.row):c=f,c.cursor=this.isBackwards()?c.start:c.end,c.desiredColumn=this.$desiredColumn,c},o.prototype.getRangeOfMovements=function(c){var f=this.getCursor();try{c(this);var u=this.getCursor();return p.fromPoints(f,u)}catch{return p.fromPoints(f,f)}finally{this.moveCursorToPosition(f)}},o.prototype.toJSON=function(){if(this.rangeCount)var c=this.ranges.map(function(f){var u=f.clone();return u.isBackwards=f.cursor==f.start,u});else{var c=this.getRange();c.isBackwards=this.isBackwards()}return c},o.prototype.fromJSON=function(c){if(c.start==null)if(this.rangeList&&c.length>1){this.toSingleRange(c[0]);for(var f=c.length;f--;){var u=p.fromPoints(c[f].start,c[f].end);c[f].isBackwards&&(u.cursor=u.start),this.addRange(u,!0)}return}else c=c[0];this.rangeList&&this.toSingleRange(c),this.setSelectionRange(c,c.isBackwards)},o.prototype.isEqual=function(c){if((c.length||this.rangeCount)&&c.length!=this.rangeCount)return!1;if(!c.length||!this.ranges)return this.getRange().isEqual(c);for(var f=this.ranges.length;f--;)if(!this.ranges[f].isEqual(c[f]))return!1;return!0},o}();g.prototype.setSelectionAnchor=g.prototype.setAnchor,g.prototype.getSelectionAnchor=g.prototype.getAnchor,g.prototype.setSelectionRange=g.prototype.setRange,d.implement(g.prototype,b),r.Selection=g}),ace.define("ace/tokenizer",["require","exports","module","ace/lib/report_error"],function(t,r,l){var d=t("./lib/report_error").reportError,h=2e3,b=function(){function p(g){this.splitRegex,this.states=g,this.regExps={},this.matchMappings={};for(var o in this.states){for(var c=this.states[o],f=[],u=0,i=this.matchMappings[o]={defaultToken:"text"},a="g",m=[],w=0;w<c.length;w++){var x=c[w];if(x.defaultToken&&(i.defaultToken=x.defaultToken),x.caseInsensitive&&a.indexOf("i")===-1&&(a+="i"),x.unicode&&a.indexOf("u")===-1&&(a+="u"),x.regex!=null){x.regex instanceof RegExp&&(x.regex=x.regex.toString().slice(1,-1));var M=x.regex,$=new RegExp("(?:("+M+")|(.))").exec("a").length-2;Array.isArray(x.token)?x.token.length==1||$==1?x.token=x.token[0]:$-1!=x.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:x,groupCount:$-1}),x.token=x.token[0]):(x.tokenArray=x.token,x.token=null,x.onMatch=this.$arrayTokens):typeof x.token=="function"&&!x.onMatch&&($>1?x.onMatch=this.$applyToken:x.onMatch=x.token),$>1&&(/\\\d/.test(x.regex)?M=x.regex.replace(/\\([0-9]+)/g,function(S,k){return"\\"+(parseInt(k,10)+u+1)}):($=1,M=this.removeCapturingGroups(x.regex)),!x.splitRegex&&typeof x.token!="string"&&m.push(x)),i[u]=w,u+=$,f.push(M),x.onMatch||(x.onMatch=null)}}f.length||(i[0]=0,f.push("$")),m.forEach(function(S){S.splitRegex=this.createSplitterRegexp(S.regex,a)},this),this.regExps[o]=new RegExp("("+f.join(")|(")+")|($)",a)}}return p.prototype.$setMaxTokenCount=function(g){h=g|0},p.prototype.$applyToken=function(g){var o=this.splitRegex.exec(g).slice(1),c=this.token.apply(this,o);if(typeof c=="string")return[{type:c,value:g}];for(var f=[],u=0,i=c.length;u<i;u++)o[u]&&(f[f.length]={type:c[u],value:o[u]});return f},p.prototype.$arrayTokens=function(g){if(!g)return[];var o=this.splitRegex.exec(g);if(!o)return"text";for(var c=[],f=this.tokenArray,u=0,i=f.length;u<i;u++)o[u+1]&&(c[c.length]={type:f[u],value:o[u+1]});return c},p.prototype.removeCapturingGroups=function(g){var o=g.replace(/\\.|\[(?:\\.|[^\\\]])*|\(\?[:=!<]|(\()/g,function(c,f){return f?"(?:":c});return o},p.prototype.createSplitterRegexp=function(g,o){if(g.indexOf("(?=")!=-1){var c=0,f=!1,u={};g.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(i,a,m,w,x,M){return f?f=x!="]":x?f=!0:w?(c==u.stack&&(u.end=M+1,u.stack=-1),c--):m&&(c++,m.length!=1&&(u.stack=c,u.start=M)),i}),u.end!=null&&/^\)*$/.test(g.substr(u.end))&&(g=g.substring(0,u.start)+g.substr(u.end))}return g.charAt(0)!="^"&&(g="^"+g),g.charAt(g.length-1)!="$"&&(g+="$"),new RegExp(g,(o||"").replace("g",""))},p.prototype.getLineTokens=function(g,o){if(o&&typeof o!="string"){var c=o.slice(0);o=c[0],o==="#tmp"&&(c.shift(),o=c.shift())}else var c=[];var f=o||"start",u=this.states[f];u||(f="start",u=this.states[f]);var i=this.matchMappings[f],a=this.regExps[f];a.lastIndex=0;for(var m,w=[],x=0,M=0,$={type:null,value:""};m=a.exec(g);){var S=i.defaultToken,k=null,T=m[0],D=a.lastIndex;if(D-T.length>x){var L=g.substring(x,D-T.length);$.type==S?$.value+=L:($.type&&w.push($),$={type:S,value:L})}for(var O=0;O<m.length-2;O++)if(m[O+1]!==void 0){k=u[i[O]],k.onMatch?S=k.onMatch(T,f,c,g):S=k.token,k.next&&(typeof k.next=="string"?f=k.next:f=k.next(f,c),u=this.states[f],u||(this.reportError("state doesn't exist",f),f="start",u=this.states[f]),i=this.matchMappings[f],x=D,a=this.regExps[f],a.lastIndex=D),k.consumeLineEnd&&(x=D);break}if(T){if(typeof S=="string")(!k||k.merge!==!1)&&$.type===S?$.value+=T:($.type&&w.push($),$={type:S,value:T});else if(S){$.type&&w.push($),$={type:null,value:""};for(var O=0;O<S.length;O++)w.push(S[O])}}if(x==g.length)break;if(x=D,M++>h){for(M>2*g.length&&this.reportError("infinite loop with in ace tokenizer",{startState:o,line:g});x<g.length;)$.type&&w.push($),$={value:g.substring(x,x+=500),type:"overflow"};f="start",c=[];break}}return $.type&&w.push($),c.length>1&&c[0]!==f&&c.unshift("#tmp",f),{tokens:w,state:c.length?c:f}},p}();b.prototype.reportError=d,r.Tokenizer=b}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/deep_copy"],function(t,r,l){var d=t("../lib/deep_copy").deepCopy,h;h=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}},(function(){this.addRules=function(g,o){if(!o){for(var c in g)this.$rules[c]=g[c];return}for(var c in g){for(var f=g[c],u=0;u<f.length;u++){var i=f[u];(i.next||i.onMatch)&&(typeof i.next=="string"&&i.next.indexOf(o)!==0&&(i.next=o+i.next),i.nextState&&i.nextState.indexOf(o)!==0&&(i.nextState=o+i.nextState))}this.$rules[o+c]=f}},this.getRules=function(){return this.$rules},this.embedRules=function(g,o,c,f,u){var i=typeof g=="function"?new g().getRules():g;if(f)for(var a=0;a<f.length;a++)f[a]=o+f[a];else{f=[];for(var m in i)f.push(o+m)}if(this.addRules(i,o),c)for(var w=Array.prototype[u?"push":"unshift"],a=0;a<f.length;a++)w.apply(this.$rules[f[a]],d(c));this.$embeds||(this.$embeds=[]),this.$embeds.push(o)},this.getEmbeds=function(){return this.$embeds};var b=function(g,o){return(g!="start"||o.length)&&o.unshift(this.nextState,g),this.nextState},p=function(g,o){return o.shift(),o.shift()||"start"};this.normalizeRules=function(){var g=0,o=this.$rules;function c(f){var u=o[f];u.processed=!0;for(var i=0;i<u.length;i++){var a=u[i],m=null;Array.isArray(a)&&(m=a,a={}),!a.regex&&a.start&&(a.regex=a.start,a.next||(a.next=[]),a.next.push({defaultToken:a.token},{token:a.token+".end",regex:a.end||a.start,next:"pop"}),a.token=a.token+".start",a.push=!0);var w=a.next||a.push;if(w&&Array.isArray(w)){var x=a.stateName;x||(x=a.token,typeof x!="string"&&(x=x[0]||""),o[x]&&(x+=g++)),o[x]=w,a.next=x,c(x)}else w=="pop"&&(a.next=p);if(a.push&&(a.nextState=a.next||a.push,a.next=b,delete a.push),a.rules)for(var M in a.rules)o[M]?o[M].push&&o[M].push.apply(o[M],a.rules[M]):o[M]=a.rules[M];var $=typeof a=="string"?a:a.include;if($&&($==="$self"&&($="start"),Array.isArray($)?m=$.map(function(k){return o[k]}):m=o[$]),m){var S=[i,1].concat(m);a.noEscape&&(S=S.filter(function(k){return!k.next})),u.splice.apply(u,S),i--}a.keywordMap&&(a.token=this.createKeywordMapper(a.keywordMap,a.defaultToken||"text",a.caseInsensitive),delete a.defaultToken)}}Object.keys(o).forEach(c,this)},this.createKeywordMapper=function(g,o,c,f){var u=Object.create(null);return this.$keywordList=[],Object.keys(g).forEach(function(i){for(var a=g[i],m=a.split(f||"|"),w=m.length;w--;){var x=m[w];this.$keywordList.push(x),c&&(x=x.toLowerCase()),u[x]=i}},this),g=null,c?function(i){return u[i.toLowerCase()]||o}:function(i){return u[i]||o}},this.getKeywords=function(){return this.$keywords}}).call(h.prototype),r.TextHighlightRules=h}),ace.define("ace/mode/behaviour",["require","exports","module"],function(t,r,l){var d;d=function(){this.$behaviours={}},(function(){this.add=function(h,b,p){switch(void 0){case this.$behaviours:this.$behaviours={};case this.$behaviours[h]:this.$behaviours[h]={}}this.$behaviours[h][b]=p},this.addBehaviours=function(h){for(var b in h)for(var p in h[b])this.add(b,p,h[b][p])},this.remove=function(h){this.$behaviours&&this.$behaviours[h]&&delete this.$behaviours[h]},this.inherit=function(h,b){if(typeof h=="function")var p=new h().getBehaviours(b);else var p=h.getBehaviours(b);this.addBehaviours(p)},this.getBehaviours=function(h){if(h){for(var b={},p=0;p<h.length;p++)this.$behaviours[h[p]]&&(b[h[p]]=this.$behaviours[h[p]]);return b}else return this.$behaviours}}).call(d.prototype),r.Behaviour=d}),ace.define("ace/token_iterator",["require","exports","module","ace/range"],function(t,r,l){var d=t("./range").Range,h=function(){function b(p,g,o){this.$session=p,this.$row=g,this.$rowTokens=p.getTokens(g);var c=p.getTokenAt(g,o);this.$tokenIndex=c?c.index:-1}return b.prototype.stepBackward=function(){for(this.$tokenIndex-=1;this.$tokenIndex<0;){if(this.$row-=1,this.$row<0)return this.$row=0,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=this.$rowTokens.length-1}return this.$rowTokens[this.$tokenIndex]},b.prototype.stepForward=function(){this.$tokenIndex+=1;for(var p;this.$tokenIndex>=this.$rowTokens.length;){if(this.$row+=1,p||(p=this.$session.getLength()),this.$row>=p)return this.$row=p-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},b.prototype.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},b.prototype.getCurrentTokenRow=function(){return this.$row},b.prototype.getCurrentTokenColumn=function(){var p=this.$rowTokens,g=this.$tokenIndex,o=p[g].start;if(o!==void 0)return o;for(o=0;g>0;)g-=1,o+=p[g].value.length;return o},b.prototype.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},b.prototype.getCurrentTokenRange=function(){var p=this.$rowTokens[this.$tokenIndex],g=this.getCurrentTokenColumn();return new d(this.$row,g,this.$row,g+p.value.length)},b}();r.TokenIterator=h}),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],function(t,r,l){var d=t("../../lib/oop"),h=t("../behaviour").Behaviour,b=t("../../token_iterator").TokenIterator,p=t("../../lib/lang"),g=["text","paren.rparen","rparen","paren","punctuation.operator"],o=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],c,f={},u={'"':'"',"'":"'"},i=function(w){var x=-1;if(w.multiSelect&&(x=w.selection.index,f.rangeCount!=w.multiSelect.rangeCount&&(f={rangeCount:w.multiSelect.rangeCount})),f[x])return c=f[x];c=f[x]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},a=function(w,x,M,$){var S=w.end.row-w.start.row;return{text:M+x+$,selection:[0,w.start.column+1,S,w.end.column+(S?0:1)]}},m;m=function(w){w=w||{},this.add("braces","insertion",function(x,M,$,S,k){var T=$.getCursorPosition(),D=S.doc.getLine(T.row);if(k=="{"){i($);var L=$.getSelectionRange(),O=S.doc.getTextRange(L),z=S.getTokenAt(T.row,T.column);if(O!==""&&O!=="{"&&$.getWrapBehavioursEnabled())return a(L,O,"{","}");if(z&&/(?:string)\.quasi|\.xml/.test(z.type)){var P=[/tag\-(?:open|name)/,/attribute\-name/];return P.some(function(K){return K.test(z.type)})||/(string)\.quasi/.test(z.type)&&z.value[T.column-z.start-1]!=="$"?void 0:(m.recordAutoInsert($,S,"}"),{text:"{}",selection:[1,1]})}else if(m.isSaneInsertion($,S))return/[\]\}\)]/.test(D[T.column])||$.inMultiSelectMode||w.braces?(m.recordAutoInsert($,S,"}"),{text:"{}",selection:[1,1]}):(m.recordMaybeInsert($,S,"{"),{text:"{",selection:[1,1]})}else if(k=="}"){i($);var N=D.substring(T.column,T.column+1);if(N=="}"){var A=S.$findOpeningBracket("}",{column:T.column+1,row:T.row});if(A!==null&&m.isAutoInsertedClosing(T,D,k))return m.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else if(k==`
|
|
186
|
+
`||k==`\r
|
|
187
|
+
`){i($);var _="";m.isMaybeInsertedClosing(T,D)&&(_=p.stringRepeat("}",c.maybeInsertedBrackets),m.clearMaybeInsertedClosing());var N=D.substring(T.column,T.column+1);if(N==="}"){var I=S.findMatchingBracket({row:T.row,column:T.column+1},"}");if(!I)return null;var j=this.$getIndent(S.getLine(I.row))}else if(_)var j=this.$getIndent(D);else{m.clearMaybeInsertedClosing();return}var U=j+S.getTabString();return{text:`
|
|
188
|
+
`+U+`
|
|
189
|
+
`+j+_,selection:[1,U.length,1,U.length]}}else m.clearMaybeInsertedClosing()}),this.add("braces","deletion",function(x,M,$,S,k){var T=S.doc.getTextRange(k);if(!k.isMultiLine()&&T=="{"){i($);var D=S.doc.getLine(k.start.row),L=D.substring(k.end.column,k.end.column+1);if(L=="}")return k.end.column++,k;c.maybeInsertedBrackets--}}),this.add("parens","insertion",function(x,M,$,S,k){if(k=="("){i($);var T=$.getSelectionRange(),D=S.doc.getTextRange(T);if(D!==""&&$.getWrapBehavioursEnabled())return a(T,D,"(",")");if(m.isSaneInsertion($,S))return m.recordAutoInsert($,S,")"),{text:"()",selection:[1,1]}}else if(k==")"){i($);var L=$.getCursorPosition(),O=S.doc.getLine(L.row),z=O.substring(L.column,L.column+1);if(z==")"){var P=S.$findOpeningBracket(")",{column:L.column+1,row:L.row});if(P!==null&&m.isAutoInsertedClosing(L,O,k))return m.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("parens","deletion",function(x,M,$,S,k){var T=S.doc.getTextRange(k);if(!k.isMultiLine()&&T=="("){i($);var D=S.doc.getLine(k.start.row),L=D.substring(k.start.column+1,k.start.column+2);if(L==")")return k.end.column++,k}}),this.add("brackets","insertion",function(x,M,$,S,k){if(k=="["){i($);var T=$.getSelectionRange(),D=S.doc.getTextRange(T);if(D!==""&&$.getWrapBehavioursEnabled())return a(T,D,"[","]");if(m.isSaneInsertion($,S))return m.recordAutoInsert($,S,"]"),{text:"[]",selection:[1,1]}}else if(k=="]"){i($);var L=$.getCursorPosition(),O=S.doc.getLine(L.row),z=O.substring(L.column,L.column+1);if(z=="]"){var P=S.$findOpeningBracket("]",{column:L.column+1,row:L.row});if(P!==null&&m.isAutoInsertedClosing(L,O,k))return m.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("brackets","deletion",function(x,M,$,S,k){var T=S.doc.getTextRange(k);if(!k.isMultiLine()&&T=="["){i($);var D=S.doc.getLine(k.start.row),L=D.substring(k.start.column+1,k.start.column+2);if(L=="]")return k.end.column++,k}}),this.add("string_dquotes","insertion",function(x,M,$,S,k){var T=S.$mode.$quotes||u;if(k.length==1&&T[k]){if(this.lineCommentStart&&this.lineCommentStart.indexOf(k)!=-1)return;i($);var D=k,L=$.getSelectionRange(),O=S.doc.getTextRange(L);if(O!==""&&(O.length!=1||!T[O])&&$.getWrapBehavioursEnabled())return a(L,O,D,D);if(!O){var z=$.getCursorPosition(),P=S.doc.getLine(z.row),N=P.substring(z.column-1,z.column),A=P.substring(z.column,z.column+1),_=S.getTokenAt(z.row,z.column),I=S.getTokenAt(z.row,z.column+1);if(N=="\\"&&_&&/escape/.test(_.type))return null;var j=_&&/string|escape/.test(_.type),U=!I||/string|escape/.test(I.type),K;if(A==D)K=j!==U,K&&/string\.end/.test(I.type)&&(K=!1);else{if(j&&!U||j&&U)return null;var Z=S.$mode.tokenRe;Z.lastIndex=0;var J=Z.test(N);Z.lastIndex=0;var ae=Z.test(A),ne=S.$mode.$pairQuotesAfter,se=ne&&ne[D]&&ne[D].test(N);if(!se&&J||ae||A&&!/[\s;,.})\]\\]/.test(A))return null;var ce=P[z.column-2];if(N==D&&(ce==D||Z.test(ce)))return null;K=!0}return{text:K?D+D:"",selection:[1,1]}}}}),this.add("string_dquotes","deletion",function(x,M,$,S,k){var T=S.$mode.$quotes||u,D=S.doc.getTextRange(k);if(!k.isMultiLine()&&T.hasOwnProperty(D)){i($);var L=S.doc.getLine(k.start.row),O=L.substring(k.start.column+1,k.start.column+2);if(O==D)return k.end.column++,k}}),w.closeDocComment!==!1&&this.add("doc comment end","insertion",function(x,M,$,S,k){if(x==="doc-start"&&(k===`
|
|
190
|
+
`||k===`\r
|
|
191
|
+
`)&&$.selection.isEmpty()){var T=$.getCursorPosition();if(T.column===0)return;for(var D=S.doc.getLine(T.row),L=S.doc.getLine(T.row+1),O=S.getTokens(T.row),z=0,P=0;P<O.length;P++){z+=O[P].value.length;var N=O[P];if(z>=T.column){if(z===T.column){if(!/\.doc/.test(N.type))return;if(/\*\//.test(N.value)){var A=O[P+1];if(!A||!/\.doc/.test(A.type))return}}var _=T.column-(z-N.value.length),I=N.value.indexOf("*/"),j=N.value.indexOf("/**",I>-1?I+2:0);if(j!==-1&&_>j&&_<j+3||I!==-1&&j!==-1&&_>=I&&_<=j||!/\.doc/.test(N.type))return;break}}var U=this.$getIndent(D);if(/\s*\*/.test(L))return/^\s*\*/.test(D)?{text:k+U+"* ",selection:[1,2+U.length,1,2+U.length]}:{text:k+U+" * ",selection:[1,3+U.length,1,3+U.length]};if(/\/\*\*/.test(D.substring(0,T.column)))return{text:k+U+" * "+k+" "+U+"*/",selection:[1,4+U.length,1,4+U.length]}}})},m.isSaneInsertion=function(w,x){var M=w.getCursorPosition(),$=new b(x,M.row,M.column);if(!this.$matchTokenType($.getCurrentToken()||"text",g)){if(/[)}\]]/.test(w.session.getLine(M.row)[M.column]))return!0;var S=new b(x,M.row,M.column+1);if(!this.$matchTokenType(S.getCurrentToken()||"text",g))return!1}return $.stepForward(),$.getCurrentTokenRow()!==M.row||this.$matchTokenType($.getCurrentToken()||"text",o)},m.$matchTokenType=function(w,x){return x.indexOf(w.type||w)>-1},m.recordAutoInsert=function(w,x,M){var $=w.getCursorPosition(),S=x.doc.getLine($.row);this.isAutoInsertedClosing($,S,c.autoInsertedLineEnd[0])||(c.autoInsertedBrackets=0),c.autoInsertedRow=$.row,c.autoInsertedLineEnd=M+S.substr($.column),c.autoInsertedBrackets++},m.recordMaybeInsert=function(w,x,M){var $=w.getCursorPosition(),S=x.doc.getLine($.row);this.isMaybeInsertedClosing($,S)||(c.maybeInsertedBrackets=0),c.maybeInsertedRow=$.row,c.maybeInsertedLineStart=S.substr(0,$.column)+M,c.maybeInsertedLineEnd=S.substr($.column),c.maybeInsertedBrackets++},m.isAutoInsertedClosing=function(w,x,M){return c.autoInsertedBrackets>0&&w.row===c.autoInsertedRow&&M===c.autoInsertedLineEnd[0]&&x.substr(w.column)===c.autoInsertedLineEnd},m.isMaybeInsertedClosing=function(w,x){return c.maybeInsertedBrackets>0&&w.row===c.maybeInsertedRow&&x.substr(w.column)===c.maybeInsertedLineEnd&&x.substr(0,w.column)==c.maybeInsertedLineStart},m.popAutoInsertedClosing=function(){c.autoInsertedLineEnd=c.autoInsertedLineEnd.substr(1),c.autoInsertedBrackets--},m.clearMaybeInsertedClosing=function(){c&&(c.maybeInsertedBrackets=0,c.maybeInsertedRow=-1)},d.inherits(m,h),r.CstyleBehaviour=m}),ace.define("ace/unicode",["require","exports","module"],function(t,r,l){for(var d=[48,9,8,25,5,0,2,25,48,0,11,0,5,0,6,22,2,30,2,457,5,11,15,4,8,0,2,0,18,116,2,1,3,3,9,0,2,2,2,0,2,19,2,82,2,138,2,4,3,155,12,37,3,0,8,38,10,44,2,0,2,1,2,1,2,0,9,26,6,2,30,10,7,61,2,9,5,101,2,7,3,9,2,18,3,0,17,58,3,100,15,53,5,0,6,45,211,57,3,18,2,5,3,11,3,9,2,1,7,6,2,2,2,7,3,1,3,21,2,6,2,0,4,3,3,8,3,1,3,3,9,0,5,1,2,4,3,11,16,2,2,5,5,1,3,21,2,6,2,1,2,1,2,1,3,0,2,4,5,1,3,2,4,0,8,3,2,0,8,15,12,2,2,8,2,2,2,21,2,6,2,1,2,4,3,9,2,2,2,2,3,0,16,3,3,9,18,2,2,7,3,1,3,21,2,6,2,1,2,4,3,8,3,1,3,2,9,1,5,1,2,4,3,9,2,0,17,1,2,5,4,2,2,3,4,1,2,0,2,1,4,1,4,2,4,11,5,4,4,2,2,3,3,0,7,0,15,9,18,2,2,7,2,2,2,22,2,9,2,4,4,7,2,2,2,3,8,1,2,1,7,3,3,9,19,1,2,7,2,2,2,22,2,9,2,4,3,8,2,2,2,3,8,1,8,0,2,3,3,9,19,1,2,7,2,2,2,22,2,15,4,7,2,2,2,3,10,0,9,3,3,9,11,5,3,1,2,17,4,23,2,8,2,0,3,6,4,0,5,5,2,0,2,7,19,1,14,57,6,14,2,9,40,1,2,0,3,1,2,0,3,0,7,3,2,6,2,2,2,0,2,0,3,1,2,12,2,2,3,4,2,0,2,5,3,9,3,1,35,0,24,1,7,9,12,0,2,0,2,0,5,9,2,35,5,19,2,5,5,7,2,35,10,0,58,73,7,77,3,37,11,42,2,0,4,328,2,3,3,6,2,0,2,3,3,40,2,3,3,32,2,3,3,6,2,0,2,3,3,14,2,56,2,3,3,66,5,0,33,15,17,84,13,619,3,16,2,25,6,74,22,12,2,6,12,20,12,19,13,12,2,2,2,1,13,51,3,29,4,0,5,1,3,9,34,2,3,9,7,87,9,42,6,69,11,28,4,11,5,11,11,39,3,4,12,43,5,25,7,10,38,27,5,62,2,28,3,10,7,9,14,0,89,75,5,9,18,8,13,42,4,11,71,55,9,9,4,48,83,2,2,30,14,230,23,280,3,5,3,37,3,5,3,7,2,0,2,0,2,0,2,30,3,52,2,6,2,0,4,2,2,6,4,3,3,5,5,12,6,2,2,6,67,1,20,0,29,0,14,0,17,4,60,12,5,0,4,11,18,0,5,0,3,9,2,0,4,4,7,0,2,0,2,0,2,3,2,10,3,3,6,4,5,0,53,1,2684,46,2,46,2,132,7,6,15,37,11,53,10,0,17,22,10,6,2,6,2,6,2,6,2,6,2,6,2,6,2,6,2,31,48,0,470,1,36,5,2,4,6,1,5,85,3,1,3,2,2,89,2,3,6,40,4,93,18,23,57,15,513,6581,75,20939,53,1164,68,45,3,268,4,27,21,31,3,13,13,1,2,24,9,69,11,1,38,8,3,102,3,1,111,44,25,51,13,68,12,9,7,23,4,0,5,45,3,35,13,28,4,64,15,10,39,54,10,13,3,9,7,22,4,1,5,66,25,2,227,42,2,1,3,9,7,11171,13,22,5,48,8453,301,3,61,3,105,39,6,13,4,6,11,2,12,2,4,2,0,2,1,2,1,2,107,34,362,19,63,3,53,41,11,5,15,17,6,13,1,25,2,33,4,2,134,20,9,8,25,5,0,2,25,12,88,4,5,3,5,3,5,3,2],h=0,b=[],p=0;p<d.length;p+=2)b.push(h+=d[p]),d[p+1]&&b.push(45,h+=d[p+1]);r.wordChars=String.fromCharCode.apply(null,b)}),ace.define("ace/mode/text",["require","exports","module","ace/config","ace/tokenizer","ace/mode/text_highlight_rules","ace/mode/behaviour/cstyle","ace/unicode","ace/lib/lang","ace/token_iterator","ace/range"],function(t,r,l){var d=t("../config"),h=t("../tokenizer").Tokenizer,b=t("./text_highlight_rules").TextHighlightRules,p=t("./behaviour/cstyle").CstyleBehaviour,g=t("../unicode"),o=t("../lib/lang"),c=t("../token_iterator").TokenIterator,f=t("../range").Range,u;u=function(){this.HighlightRules=b},(function(){this.$defaultBehaviour=new p,this.tokenRe=new RegExp("^["+g.wordChars+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+g.wordChars+"\\$_]|\\s])+","g"),this.getTokenizer=function(){return this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules(this.$highlightRuleConfig),this.$tokenizer=new h(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(i,a,m,w){var x=a.doc,M=!0,$=!0,S=1/0,k=a.getTabSize(),T=!1;if(this.lineCommentStart){if(Array.isArray(this.lineCommentStart))var D=this.lineCommentStart.map(o.escapeRegExp).join("|"),L=this.lineCommentStart[0];else var D=o.escapeRegExp(this.lineCommentStart),L=this.lineCommentStart;D=new RegExp("^(\\s*)(?:"+D+") ?"),T=a.getUseSoftTabs();var O=function(K,Z){var J=K.match(D);if(J){var ae=J[1].length,ne=J[0].length;!A(K,ae,ne)&&J[0][ne-1]==" "&&ne--,x.removeInLine(Z,ae,ne)}},z=L+" ",P=function(K,Z){(!M||/\S/.test(K))&&(A(K,S,S)?x.insertInLine({row:Z,column:S},z):x.insertInLine({row:Z,column:S},L))},N=function(K,Z){return D.test(K)},A=function(K,Z,J){for(var ae=0;Z--&&K.charAt(Z)==" ";)ae++;if(ae%k!=0)return!1;for(var ae=0;K.charAt(J++)==" ";)ae++;return k>2?ae%k!=k-1:ae%k==0}}else{if(!this.blockComment)return!1;var L=this.blockComment.start,_=this.blockComment.end,D=new RegExp("^(\\s*)(?:"+o.escapeRegExp(L)+")"),I=new RegExp("(?:"+o.escapeRegExp(_)+")\\s*$"),P=function(se,ce){N(se,ce)||(!M||/\S/.test(se))&&(x.insertInLine({row:ce,column:se.length},_),x.insertInLine({row:ce,column:S},L))},O=function(se,ce){var he;(he=se.match(I))&&x.removeInLine(ce,se.length-he[0].length,se.length),(he=se.match(D))&&x.removeInLine(ce,he[1].length,he[0].length)},N=function(se,ce){if(D.test(se))return!0;for(var he=a.getTokens(ce),ge=0;ge<he.length;ge++)if(he[ge].type==="comment")return!0}}function j(K){for(var Z=m;Z<=w;Z++)K(x.getLine(Z),Z)}var U=1/0;j(function(K,Z){var J=K.search(/\S/);J!==-1?(J<S&&(S=J),$&&!N(K,Z)&&($=!1)):U>K.length&&(U=K.length)}),S==1/0&&(S=U,M=!1,$=!1),T&&S%k!=0&&(S=Math.floor(S/k)*k),j($?O:P)},this.toggleBlockComment=function(i,a,m,w){var x=this.blockComment;if(x){!x.start&&x[0]&&(x=x[0]);var M=new c(a,w.row,w.column),$=M.getCurrentToken();a.selection;var S=a.selection.toOrientedRange(),k,T;if($&&/comment/.test($.type)){for(var D,L;$&&/comment/.test($.type);){var O=$.value.indexOf(x.start);if(O!=-1){var z=M.getCurrentTokenRow(),P=M.getCurrentTokenColumn()+O;D=new f(z,P,z,P+x.start.length);break}$=M.stepBackward()}for(var M=new c(a,w.row,w.column),$=M.getCurrentToken();$&&/comment/.test($.type);){var O=$.value.indexOf(x.end);if(O!=-1){var z=M.getCurrentTokenRow(),P=M.getCurrentTokenColumn()+O;L=new f(z,P,z,P+x.end.length);break}$=M.stepForward()}L&&a.remove(L),D&&(a.remove(D),k=D.start.row,T=-x.start.length)}else T=x.start.length,k=m.start.row,a.insert(m.end,x.end),a.insert(m.start,x.start);S.start.row==k&&(S.start.column+=T),S.end.row==k&&(S.end.column+=T),a.selection.fromOrientedRange(S)}},this.getNextLineIndent=function(i,a,m){return this.$getIndent(a)},this.checkOutdent=function(i,a,m){return!1},this.autoOutdent=function(i,a,m){},this.$getIndent=function(i){return i.match(/^\s*/)[0]},this.createWorker=function(i){return null},this.createModeDelegates=function(i){this.$embeds=[],this.$modes={};for(var a in i)if(i[a]){var m=i[a],w=m.prototype.$id,x=d.$modes[w];x||(d.$modes[w]=x=new m),d.$modes[a]||(d.$modes[a]=x),this.$embeds.push(a),this.$modes[a]=x}for(var M=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"],$=function(T){(function(D){var L=M[T],O=D[L];D[M[T]]=function(){return this.$delegator(L,arguments,O)}})(S)},S=this,a=0;a<M.length;a++)$(a)},this.$delegator=function(i,a,m){var w=a[0]||"start";if(typeof w!="string"){if(Array.isArray(w[2])){var x=w[2][w[2].length-1],M=this.$modes[x];if(M)return M[i].apply(M,[w[1]].concat([].slice.call(a,1)))}w=w[0]||"start"}for(var $=0;$<this.$embeds.length;$++)if(this.$modes[this.$embeds[$]]){var S=w.split(this.$embeds[$]);if(!S[0]&&S[1]){a[0]=S[1];var M=this.$modes[this.$embeds[$]];return M[i].apply(M,a)}}var k=m.apply(this,a);return m?k:void 0},this.transformAction=function(i,a,m,w,x){if(this.$behaviour){var M=this.$behaviour.getBehaviours();for(var $ in M)if(M[$][a]){var S=M[$][a].apply(this,arguments);if(S)return S}}},this.getKeywords=function(i){if(!this.completionKeywords){var a=this.$tokenizer.rules,m=[];for(var w in a)for(var x=a[w],M=0,$=x.length;M<$;M++)if(typeof x[M].token=="string")/keyword|support|storage/.test(x[M].token)&&m.push(x[M].regex);else if(typeof x[M].token=="object"){for(var S=0,k=x[M].token.length;S<k;S++)if(/keyword|support|storage/.test(x[M].token[S])){var w=x[M].regex.match(/\(.+?\)/g)[S];m.push(w.substr(1,w.length-2))}}this.completionKeywords=m}return i?m.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(i,a,m,w){var x=this.$keywordList||this.$createKeywordList();return x.map(function(M){return{name:M,value:M,score:0,meta:"keyword"}})},this.$id="ace/mode/text"}).call(u.prototype),r.Mode=u}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],function(t,r,l){var d=t("./lib/dom"),h=function(){function b(p){this.session=p,this.session.widgetManager=this,this.session.getRowLength=this.getRowLength,this.session.$getWidgetScreenLength=this.$getWidgetScreenLength,this.updateOnChange=this.updateOnChange.bind(this),this.renderWidgets=this.renderWidgets.bind(this),this.measureWidgets=this.measureWidgets.bind(this),this.session._changedWidgets=[],this.$onChangeEditor=this.$onChangeEditor.bind(this),this.session.on("change",this.updateOnChange),this.session.on("changeFold",this.updateOnFold),this.session.on("changeEditor",this.$onChangeEditor)}return b.prototype.getRowLength=function(p){var g;return this.lineWidgets?g=this.lineWidgets[p]&&this.lineWidgets[p].rowCount||0:g=0,!this.$useWrapMode||!this.$wrapData[p]?1+g:this.$wrapData[p].length+1+g},b.prototype.$getWidgetScreenLength=function(){var p=0;return this.lineWidgets.forEach(function(g){g&&g.rowCount&&!g.hidden&&(p+=g.rowCount)}),p},b.prototype.$onChangeEditor=function(p){this.attach(p.editor)},b.prototype.attach=function(p){p&&p.widgetManager&&p.widgetManager!=this&&p.widgetManager.detach(),this.editor!=p&&(this.detach(),this.editor=p,p&&(p.widgetManager=this,p.renderer.on("beforeRender",this.measureWidgets),p.renderer.on("afterRender",this.renderWidgets)))},b.prototype.detach=function(p){var g=this.editor;if(g){this.editor=null,g.widgetManager=null,g.renderer.off("beforeRender",this.measureWidgets),g.renderer.off("afterRender",this.renderWidgets);var o=this.session.lineWidgets;o&&o.forEach(function(c){c&&c.el&&c.el.parentNode&&(c._inDocument=!1,c.el.parentNode.removeChild(c.el))})}},b.prototype.updateOnFold=function(p,g){var o=g.lineWidgets;if(!(!o||!p.action)){for(var c=p.data,f=c.start.row,u=c.end.row,i=p.action=="add",a=f+1;a<u;a++)o[a]&&(o[a].hidden=i);o[u]&&(i?o[f]?o[u].hidden=i:o[f]=o[u]:(o[f]==o[u]&&(o[f]=void 0),o[u].hidden=i))}},b.prototype.updateOnChange=function(p){var g=this.session.lineWidgets;if(g){var o=p.start.row,c=p.end.row-o;if(c!==0)if(p.action=="remove"){var f=g.splice(o+1,c);!g[o]&&f[f.length-1]&&(g[o]=f.pop()),f.forEach(function(i){i&&this.removeLineWidget(i)},this),this.$updateRows()}else{var u=new Array(c);g[o]&&g[o].column!=null&&p.start.column>g[o].column&&o++,u.unshift(o,0),g.splice.apply(g,u),this.$updateRows()}}},b.prototype.$updateRows=function(){var p=this.session.lineWidgets;if(p){var g=!0;p.forEach(function(o,c){if(o)for(g=!1,o.row=c;o.$oldWidget;)o.$oldWidget.row=c,o=o.$oldWidget}),g&&(this.session.lineWidgets=null)}},b.prototype.$registerLineWidget=function(p){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var g=this.session.lineWidgets[p.row];return g&&(p.$oldWidget=g,g.el&&g.el.parentNode&&(g.el.parentNode.removeChild(g.el),g._inDocument=!1)),this.session.lineWidgets[p.row]=p,p},b.prototype.addLineWidget=function(p){if(this.$registerLineWidget(p),p.session=this.session,!this.editor)return p;var g=this.editor.renderer;p.html&&!p.el&&(p.el=d.createElement("div"),p.el.innerHTML=p.html),p.text&&!p.el&&(p.el=d.createElement("div"),p.el.textContent=p.text),p.el&&(d.addCssClass(p.el,"ace_lineWidgetContainer"),p.className&&d.addCssClass(p.el,p.className),p.el.style.position="absolute",p.el.style.zIndex="5",g.container.appendChild(p.el),p._inDocument=!0,p.coverGutter||(p.el.style.zIndex="3"),p.pixelHeight==null&&(p.pixelHeight=p.el.offsetHeight)),p.rowCount==null&&(p.rowCount=p.pixelHeight/g.layerConfig.lineHeight);var o=this.session.getFoldAt(p.row,0);if(p.$fold=o,o){var c=this.session.lineWidgets;p.row==o.end.row&&!c[o.start.row]?c[o.start.row]=p:p.hidden=!0}return this.session._emit("changeFold",{data:{start:{row:p.row}}}),this.$updateRows(),this.renderWidgets(null,g),this.onWidgetChanged(p),p},b.prototype.removeLineWidget=function(p){if(p._inDocument=!1,p.session=null,p.el&&p.el.parentNode&&p.el.parentNode.removeChild(p.el),p.editor&&p.editor.destroy)try{p.editor.destroy()}catch{}if(this.session.lineWidgets){var g=this.session.lineWidgets[p.row];if(g==p)this.session.lineWidgets[p.row]=p.$oldWidget,p.$oldWidget&&this.onWidgetChanged(p.$oldWidget);else for(;g;){if(g.$oldWidget==p){g.$oldWidget=p.$oldWidget;break}g=g.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:p.row}}}),this.$updateRows()},b.prototype.getWidgetsAtRow=function(p){for(var g=this.session.lineWidgets,o=g&&g[p],c=[];o;)c.push(o),o=o.$oldWidget;return c},b.prototype.onWidgetChanged=function(p){this.session._changedWidgets.push(p),this.editor&&this.editor.renderer.updateFull()},b.prototype.measureWidgets=function(p,g){var o=this.session._changedWidgets,c=g.layerConfig;if(!(!o||!o.length)){for(var f=1/0,u=0;u<o.length;u++){var i=o[u];if(!(!i||!i.el)&&i.session==this.session){if(!i._inDocument){if(this.session.lineWidgets[i.row]!=i)continue;i._inDocument=!0,g.container.appendChild(i.el)}i.h=i.el.offsetHeight,i.fixedWidth||(i.w=i.el.offsetWidth,i.screenWidth=Math.ceil(i.w/c.characterWidth));var a=i.h/c.lineHeight;i.coverLine&&(a-=this.session.getRowLineCount(i.row),a<0&&(a=0)),i.rowCount!=a&&(i.rowCount=a,i.row<f&&(f=i.row))}}f!=1/0&&(this.session._emit("changeFold",{data:{start:{row:f}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]}},b.prototype.renderWidgets=function(p,g){var o=g.layerConfig,c=this.session.lineWidgets;if(c){for(var f=Math.min(this.firstRow,o.firstRow),u=Math.max(this.lastRow,o.lastRow,c.length);f>0&&!c[f];)f--;this.firstRow=o.firstRow,this.lastRow=o.lastRow,g.$cursorLayer.config=o;for(var i=f;i<=u;i++){var a=c[i];if(!(!a||!a.el)){if(a.hidden){a.el.style.top=-100-(a.pixelHeight||0)+"px";continue}a._inDocument||(a._inDocument=!0,g.container.appendChild(a.el));var m=g.$cursorLayer.getPixelPosition({row:i,column:0},!0).top;a.coverLine||(m+=o.lineHeight*this.session.getRowLineCount(a.row)),a.el.style.top=m-o.offset+"px";var w=a.coverGutter?0:g.gutterWidth;a.fixedWidth||(w-=g.scrollLeft),a.el.style.left=w+"px",a.fullWidth&&a.screenWidth&&(a.el.style.minWidth=o.width+2*o.padding+"px"),a.fixedWidth?a.el.style.right=g.scrollBar.getWidth()+"px":a.el.style.right=""}}}},b}();r.LineWidgets=h}),ace.define("ace/apply_delta",["require","exports","module"],function(t,r,l){r.applyDelta=function(d,h,b){var p=h.start.row,g=h.start.column,o=d[p]||"";switch(h.action){case"insert":var c=h.lines;if(c.length===1)d[p]=o.substring(0,g)+h.lines[0]+o.substring(g);else{var f=[p,1].concat(h.lines);d.splice.apply(d,f),d[p]=o.substring(0,g)+d[p],d[p+h.lines.length-1]+=o.substring(g)}break;case"remove":var u=h.end.column,i=h.end.row;p===i?d[p]=o.substring(0,g)+o.substring(u):d.splice(p,i-p+1,o.substring(0,g)+d[i].substring(u));break}}}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(t,r,l){var d=t("./lib/oop"),h=t("./lib/event_emitter").EventEmitter,b=function(){function o(c,f,u){this.$onChange=this.onChange.bind(this),this.attach(c),typeof f!="number"?this.setPosition(f.row,f.column):this.setPosition(f,u)}return o.prototype.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},o.prototype.getDocument=function(){return this.document},o.prototype.onChange=function(c){if(!(c.start.row==c.end.row&&c.start.row!=this.row)&&!(c.start.row>this.row)){var f=g(c,{row:this.row,column:this.column},this.$insertRight);this.setPosition(f.row,f.column,!0)}},o.prototype.setPosition=function(c,f,u){var i;if(u?i={row:c,column:f}:i=this.$clipPositionToDocument(c,f),!(this.row==i.row&&this.column==i.column)){var a={row:this.row,column:this.column};this.row=i.row,this.column=i.column,this._signal("change",{old:a,value:i})}},o.prototype.detach=function(){this.document.off("change",this.$onChange)},o.prototype.attach=function(c){this.document=c||this.document,this.document.on("change",this.$onChange)},o.prototype.$clipPositionToDocument=function(c,f){var u={};return c>=this.document.getLength()?(u.row=Math.max(0,this.document.getLength()-1),u.column=this.document.getLine(u.row).length):c<0?(u.row=0,u.column=0):(u.row=c,u.column=Math.min(this.document.getLine(u.row).length,Math.max(0,f))),f<0&&(u.column=0),u},o}();b.prototype.$insertRight=!1,d.implement(b.prototype,h);function p(o,c,f){var u=f?o.column<=c.column:o.column<c.column;return o.row<c.row||o.row==c.row&&u}function g(o,c,f){var u=o.action=="insert",i=(u?1:-1)*(o.end.row-o.start.row),a=(u?1:-1)*(o.end.column-o.start.column),m=o.start,w=u?m:o.end;return p(c,m,f)?{row:c.row,column:c.column}:p(w,c,!f)?{row:c.row+i,column:c.column+(c.row==w.row?a:0)}:{row:m.row,column:m.column}}r.Anchor=b}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],function(t,r,l){var d=t("./lib/oop"),h=t("./apply_delta").applyDelta,b=t("./lib/event_emitter").EventEmitter,p=t("./range").Range,g=t("./anchor").Anchor,o=function(){function c(f){this.$lines=[""],f.length===0?this.$lines=[""]:Array.isArray(f)?this.insertMergedLines({row:0,column:0},f):this.insert({row:0,column:0},f)}return c.prototype.setValue=function(f){var u=this.getLength()-1;this.remove(new p(0,0,u,this.getLine(u).length)),this.insert({row:0,column:0},f||"")},c.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},c.prototype.createAnchor=function(f,u){return new g(this,f,u)},c.prototype.$detectNewLine=function(f){var u=f.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=u?u[1]:`
|
|
192
|
+
`,this._signal("changeNewLineMode")},c.prototype.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return`\r
|
|
193
|
+
`;case"unix":return`
|
|
194
|
+
`;default:return this.$autoNewLine||`
|
|
195
|
+
`}},c.prototype.setNewLineMode=function(f){this.$newLineMode!==f&&(this.$newLineMode=f,this._signal("changeNewLineMode"))},c.prototype.getNewLineMode=function(){return this.$newLineMode},c.prototype.isNewLine=function(f){return f==`\r
|
|
196
|
+
`||f=="\r"||f==`
|
|
197
|
+
`},c.prototype.getLine=function(f){return this.$lines[f]||""},c.prototype.getLines=function(f,u){return this.$lines.slice(f,u+1)},c.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},c.prototype.getLength=function(){return this.$lines.length},c.prototype.getTextRange=function(f){return this.getLinesForRange(f).join(this.getNewLineCharacter())},c.prototype.getLinesForRange=function(f){var u;if(f.start.row===f.end.row)u=[this.getLine(f.start.row).substring(f.start.column,f.end.column)];else{u=this.getLines(f.start.row,f.end.row),u[0]=(u[0]||"").substring(f.start.column);var i=u.length-1;f.end.row-f.start.row==i&&(u[i]=u[i].substring(0,f.end.column))}return u},c.prototype.insertLines=function(f,u){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(f,u)},c.prototype.removeLines=function(f,u){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(f,u)},c.prototype.insertNewLine=function(f){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(f,["",""])},c.prototype.insert=function(f,u){return this.getLength()<=1&&this.$detectNewLine(u),this.insertMergedLines(f,this.$split(u))},c.prototype.insertInLine=function(f,u){var i=this.clippedPos(f.row,f.column),a=this.pos(f.row,f.column+u.length);return this.applyDelta({start:i,end:a,action:"insert",lines:[u]},!0),this.clonePos(a)},c.prototype.clippedPos=function(f,u){var i=this.getLength();f===void 0?f=i:f<0?f=0:f>=i&&(f=i-1,u=void 0);var a=this.getLine(f);return u==null&&(u=a.length),u=Math.min(Math.max(u,0),a.length),{row:f,column:u}},c.prototype.clonePos=function(f){return{row:f.row,column:f.column}},c.prototype.pos=function(f,u){return{row:f,column:u}},c.prototype.$clipPosition=function(f){var u=this.getLength();return f.row>=u?(f.row=Math.max(0,u-1),f.column=this.getLine(u-1).length):(f.row=Math.max(0,f.row),f.column=Math.min(Math.max(f.column,0),this.getLine(f.row).length)),f},c.prototype.insertFullLines=function(f,u){f=Math.min(Math.max(f,0),this.getLength());var i=0;f<this.getLength()?(u=u.concat([""]),i=0):(u=[""].concat(u),f--,i=this.$lines[f].length),this.insertMergedLines({row:f,column:i},u)},c.prototype.insertMergedLines=function(f,u){var i=this.clippedPos(f.row,f.column),a={row:i.row+u.length-1,column:(u.length==1?i.column:0)+u[u.length-1].length};return this.applyDelta({start:i,end:a,action:"insert",lines:u}),this.clonePos(a)},c.prototype.remove=function(f){var u=this.clippedPos(f.start.row,f.start.column),i=this.clippedPos(f.end.row,f.end.column);return this.applyDelta({start:u,end:i,action:"remove",lines:this.getLinesForRange({start:u,end:i})}),this.clonePos(u)},c.prototype.removeInLine=function(f,u,i){var a=this.clippedPos(f,u),m=this.clippedPos(f,i);return this.applyDelta({start:a,end:m,action:"remove",lines:this.getLinesForRange({start:a,end:m})},!0),this.clonePos(a)},c.prototype.removeFullLines=function(f,u){f=Math.min(Math.max(0,f),this.getLength()-1),u=Math.min(Math.max(0,u),this.getLength()-1);var i=u==this.getLength()-1&&f>0,a=u<this.getLength()-1,m=i?f-1:f,w=i?this.getLine(m).length:0,x=a?u+1:u,M=a?0:this.getLine(x).length,$=new p(m,w,x,M),S=this.$lines.slice(f,u+1);return this.applyDelta({start:$.start,end:$.end,action:"remove",lines:this.getLinesForRange($)}),S},c.prototype.removeNewLine=function(f){f<this.getLength()-1&&f>=0&&this.applyDelta({start:this.pos(f,this.getLine(f).length),end:this.pos(f+1,0),action:"remove",lines:["",""]})},c.prototype.replace=function(f,u){if(f instanceof p||(f=p.fromPoints(f.start,f.end)),u.length===0&&f.isEmpty())return f.start;if(u==this.getTextRange(f))return f.end;this.remove(f);var i;return u?i=this.insert(f.start,u):i=f.start,i},c.prototype.applyDeltas=function(f){for(var u=0;u<f.length;u++)this.applyDelta(f[u])},c.prototype.revertDeltas=function(f){for(var u=f.length-1;u>=0;u--)this.revertDelta(f[u])},c.prototype.applyDelta=function(f,u){var i=f.action=="insert";(i?f.lines.length<=1&&!f.lines[0]:!p.comparePoints(f.start,f.end))||(i&&f.lines.length>2e4?this.$splitAndapplyLargeDelta(f,2e4):(h(this.$lines,f,u),this._signal("change",f)))},c.prototype.$safeApplyDelta=function(f){var u=this.$lines.length;(f.action=="remove"&&f.start.row<u&&f.end.row<u||f.action=="insert"&&f.start.row<=u)&&this.applyDelta(f)},c.prototype.$splitAndapplyLargeDelta=function(f,u){for(var i=f.lines,a=i.length-u+1,m=f.start.row,w=f.start.column,x=0,M=0;x<a;x=M){M+=u-1;var $=i.slice(x,M);$.push(""),this.applyDelta({start:this.pos(m+x,w),end:this.pos(m+M,w=0),action:f.action,lines:$},!0)}f.lines=i.slice(x),f.start.row=m+x,f.start.column=w,this.applyDelta(f,!0)},c.prototype.revertDelta=function(f){this.$safeApplyDelta({start:this.clonePos(f.start),end:this.clonePos(f.end),action:f.action=="insert"?"remove":"insert",lines:f.lines.slice()})},c.prototype.indexToPosition=function(f,u){for(var i=this.$lines||this.getAllLines(),a=this.getNewLineCharacter().length,m=u||0,w=i.length;m<w;m++)if(f-=i[m].length+a,f<0)return{row:m,column:f+i[m].length+a};return{row:w-1,column:f+i[w-1].length+a}},c.prototype.positionToIndex=function(f,u){for(var i=this.$lines||this.getAllLines(),a=this.getNewLineCharacter().length,m=0,w=Math.min(f.row,i.length),x=u||0;x<w;++x)m+=i[x].length+a;return m+f.column},c.prototype.$split=function(f){return f.split(/\r\n|\r|\n/)},c}();o.prototype.$autoNewLine="",o.prototype.$newLineMode="auto",d.implement(o.prototype,b),r.Document=o}),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(t,r,l){var d=t("./lib/oop"),h=t("./lib/event_emitter").EventEmitter,b=function(){function p(g,o){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=g;var c=this;this.$worker=function(){if(c.running){for(var f=new Date,u=c.currentLine,i=-1,a=c.doc,m=u;c.lines[u];)u++;var w=a.getLength(),x=0;for(c.running=!1;u<w;){c.$tokenizeRow(u),i=u;do u++;while(c.lines[u]);if(x++,x%5===0&&new Date-f>20){c.running=setTimeout(c.$worker,20);break}}c.currentLine=u,i==-1&&(i=u),m<=i&&c.fireUpdateEvent(m,i)}}}return p.prototype.setTokenizer=function(g){this.tokenizer=g,this.lines=[],this.states=[],this.start(0)},p.prototype.setDocument=function(g){this.doc=g,this.lines=[],this.states=[],this.stop()},p.prototype.fireUpdateEvent=function(g,o){var c={first:g,last:o};this._signal("update",{data:c})},p.prototype.start=function(g){this.currentLine=Math.min(g||0,this.currentLine,this.doc.getLength()),this.lines.splice(this.currentLine,this.lines.length),this.states.splice(this.currentLine,this.states.length),this.stop(),this.running=setTimeout(this.$worker,700)},p.prototype.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},p.prototype.$updateOnChange=function(g){var o=g.start.row,c=g.end.row-o;if(c===0)this.lines[o]=null;else if(g.action=="remove")this.lines.splice(o,c+1,null),this.states.splice(o,c+1,null);else{var f=Array(c+1);f.unshift(o,1),this.lines.splice.apply(this.lines,f),this.states.splice.apply(this.states,f)}this.currentLine=Math.min(o,this.currentLine,this.doc.getLength()),this.stop()},p.prototype.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},p.prototype.getTokens=function(g){return this.lines[g]||this.$tokenizeRow(g)},p.prototype.getState=function(g){return this.currentLine==g&&this.$tokenizeRow(g),this.states[g]||"start"},p.prototype.$tokenizeRow=function(g){var o=this.doc.getLine(g),c=this.states[g-1],f=this.tokenizer.getLineTokens(o,c,g);return this.states[g]+""!=f.state+""?(this.states[g]=f.state,this.lines[g+1]=null,this.currentLine>g+1&&(this.currentLine=g+1)):this.currentLine==g&&(this.currentLine=g+1),this.lines[g]=f.tokens},p.prototype.cleanup=function(){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.removeAllListeners()},p}();d.implement(b.prototype,h),r.BackgroundTokenizer=b}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/range"],function(t,r,l){var d=t("./lib/lang"),h=t("./range").Range,b=function(){function p(g,o,c){c===void 0&&(c="text"),this.setRegexp(g),this.clazz=o,this.type=c,this.docLen=0}return p.prototype.setRegexp=function(g){this.regExp+""!=g+""&&(this.regExp=g,this.cache=[])},p.prototype.update=function(g,o,c,f){if(this.regExp){for(var u=f.firstRow,i=f.lastRow,a={},m=c.$editor&&c.$editor.$search,w=m&&m.$isMultilineSearch(c.$editor.getLastSearchOptions()),x=u;x<=i;x++){var M=this.cache[x];if(M==null||c.getValue().length!=this.docLen){if(w){M=[];var $=m.$multiLineForward(c,this.regExp,x,i);if($){var S=$.endRow<=i?$.endRow-1:i;S>x&&(x=S),M.push(new h($.startRow,$.startCol,$.endRow,$.endCol))}M.length>this.MAX_RANGES&&(M=M.slice(0,this.MAX_RANGES))}else M=d.getMatchOffsets(c.getLine(x),this.regExp),M.length>this.MAX_RANGES&&(M=M.slice(0,this.MAX_RANGES)),M=M.map(function(L){return new h(x,L.offset,x,L.offset+L.length)});this.cache[x]=M.length?M:""}if(M.length!==0)for(var k=M.length;k--;){var T=M[k].toScreenRange(c),D=T.toString();a[D]||(a[D]=!0,o.drawSingleLineMarker(g,T,this.clazz,f))}}this.docLen=c.getValue().length}},p}();b.prototype.MAX_RANGES=500,r.SearchHighlight=b}),ace.define("ace/undomanager",["require","exports","module","ace/range"],function(t,r,l){var d=function(){function S(){this.$keepRedoStack,this.$maxRev=0,this.$fromUndo=!1,this.$undoDepth=1/0,this.reset()}return S.prototype.addSession=function(k){this.$session=k},S.prototype.add=function(k,T,D){if(!this.$fromUndo&&k!=this.$lastDelta){if(this.$keepRedoStack||(this.$redoStack.length=0),T===!1||!this.lastDeltas){this.lastDeltas=[];var L=this.$undoStack.length;L>this.$undoDepth-1&&this.$undoStack.splice(0,L-this.$undoDepth+1),this.$undoStack.push(this.lastDeltas),k.id=this.$rev=++this.$maxRev}(k.action=="remove"||k.action=="insert")&&(this.$lastDelta=k),this.lastDeltas.push(k)}},S.prototype.addSelection=function(k,T){this.selections.push({value:k,rev:T||this.$rev})},S.prototype.startNewGroup=function(){return this.lastDeltas=null,this.$rev},S.prototype.markIgnored=function(k,T){T==null&&(T=this.$rev+1);for(var D=this.$undoStack,L=D.length;L--;){var O=D[L][0];if(O.id<=k)break;O.id<T&&(O.ignore=!0)}this.lastDeltas=null},S.prototype.getSelection=function(k,T){for(var D=this.selections,L=D.length;L--;){var O=D[L];if(O.rev<k)return T&&(O=D[L+1]),O}},S.prototype.getRevision=function(){return this.$rev},S.prototype.getDeltas=function(k,T){T==null&&(T=this.$rev+1);for(var D=this.$undoStack,L=null,O=0,z=D.length;z--;){var P=D[z][0];if(P.id<T&&!L&&(L=z+1),P.id<=k){O=z+1;break}}return D.slice(O,L)},S.prototype.getChangedRanges=function(k,T){T==null&&(T=this.$rev+1)},S.prototype.getChangedLines=function(k,T){T==null&&(T=this.$rev+1)},S.prototype.undo=function(k,T){this.lastDeltas=null;var D=this.$undoStack;if(h(D,D.length)){k||(k=this.$session),this.$redoStackBaseRev!==this.$rev&&this.$redoStack.length&&(this.$redoStack=[]),this.$fromUndo=!0;var L=D.pop(),O=null;return L&&(O=k.undoChanges(L,T),this.$redoStack.push(L),this.$syncRev()),this.$fromUndo=!1,O}},S.prototype.redo=function(k,T){if(this.lastDeltas=null,k||(k=this.$session),this.$fromUndo=!0,this.$redoStackBaseRev!=this.$rev){var D=this.getDeltas(this.$redoStackBaseRev,this.$rev+1);$(this.$redoStack,D),this.$redoStackBaseRev=this.$rev,this.$redoStack.forEach(function(z){z[0].id=++this.$maxRev},this)}var L=this.$redoStack.pop(),O=null;return L&&(O=k.redoChanges(L,T),this.$undoStack.push(L),this.$syncRev()),this.$fromUndo=!1,O},S.prototype.$syncRev=function(){var k=this.$undoStack,T=k[k.length-1],D=T&&T[0].id||0;this.$redoStackBaseRev=D,this.$rev=D},S.prototype.reset=function(){this.lastDeltas=null,this.$lastDelta=null,this.$undoStack=[],this.$redoStack=[],this.$rev=0,this.mark=0,this.$redoStackBaseRev=this.$rev,this.selections=[]},S.prototype.canUndo=function(){return this.$undoStack.length>0},S.prototype.canRedo=function(){return this.$redoStack.length>0},S.prototype.bookmark=function(k){k==null&&(k=this.$rev),this.mark=k},S.prototype.isAtBookmark=function(){return this.$rev===this.mark},S.prototype.toJSON=function(){return{$redoStack:this.$redoStack,$undoStack:this.$undoStack}},S.prototype.fromJSON=function(k){this.reset(),this.$undoStack=k.$undoStack,this.$redoStack=k.$redoStack},S.prototype.$prettyPrint=function(k){return k?c(k):c(this.$undoStack)+`
|
|
198
|
+
---
|
|
199
|
+
`+c(this.$redoStack)},S}();d.prototype.hasUndo=d.prototype.canUndo,d.prototype.hasRedo=d.prototype.canRedo,d.prototype.isClean=d.prototype.isAtBookmark,d.prototype.markClean=d.prototype.bookmark;function h(S,k){for(var T=k;T--;){var D=S[T];if(D&&!D[0].ignore){for(;T<k-1;){var L=i(S[T],S[T+1]);S[T]=L[0],S[T+1]=L[1],T++}return!0}}}var b=t("./range").Range,p=b.comparePoints;b.comparePoints;function g(S){return{row:S.row,column:S.column}}function o(S){return{start:g(S.start),end:g(S.end),action:S.action,lines:S.lines.slice()}}function c(S){if(S=S||this,Array.isArray(S))return S.map(c).join(`
|
|
200
|
+
`);var k="";return S.action?(k=S.action=="insert"?"+":"-",k+="["+S.lines+"]"):S.value&&(Array.isArray(S.value)?k=S.value.map(f).join(`
|
|
201
|
+
`):k=f(S.value)),S.start&&(k+=f(S)),(S.id||S.rev)&&(k+=" ("+(S.id||S.rev)+")"),k}function f(S){return S.start.row+":"+S.start.column+"=>"+S.end.row+":"+S.end.column}function u(S,k){var T=S.action=="insert",D=k.action=="insert";if(T&&D)if(p(k.start,S.end)>=0)m(k,S,-1);else if(p(k.start,S.start)<=0)m(S,k,1);else return null;else if(T&&!D)if(p(k.start,S.end)>=0)m(k,S,-1);else if(p(k.end,S.start)<=0)m(S,k,-1);else return null;else if(!T&&D)if(p(k.start,S.start)>=0)m(k,S,1);else if(p(k.start,S.start)<=0)m(S,k,1);else return null;else if(!T&&!D)if(p(k.start,S.start)>=0)m(k,S,1);else if(p(k.end,S.start)<=0)m(S,k,-1);else return null;return[k,S]}function i(S,k){for(var T=S.length;T--;)for(var D=0;D<k.length;D++)if(!u(S[T],k[D])){for(;T<S.length;){for(;D--;)u(k[D],S[T]);D=k.length,T++}return[S,k]}return S.selectionBefore=k.selectionBefore=S.selectionAfter=k.selectionAfter=null,[k,S]}function a(S,k){var T=S.action=="insert",D=k.action=="insert";if(T&&D)p(S.start,k.start)<0?m(k,S,1):m(S,k,1);else if(T&&!D)p(S.start,k.end)>=0?m(S,k,-1):(p(S.start,k.start)<=0||m(S,b.fromPoints(k.start,S.start),-1),m(k,S,1));else if(!T&&D)p(k.start,S.end)>=0?m(k,S,-1):(p(k.start,S.start)<=0||m(k,b.fromPoints(S.start,k.start),-1),m(S,k,1));else if(!T&&!D)if(p(k.start,S.end)>=0)m(k,S,-1);else if(p(k.end,S.start)<=0)m(S,k,-1);else{var L,O;return p(S.start,k.start)<0&&(L=S,S=x(S,k.start)),p(S.end,k.end)>0&&(O=x(S,k.end)),w(k.end,S.start,S.end,-1),O&&!L&&(S.lines=O.lines,S.start=O.start,S.end=O.end,O=S),[k,L,O].filter(Boolean)}return[k,S]}function m(S,k,T){w(S.start,k.start,k.end,T),w(S.end,k.start,k.end,T)}function w(S,k,T,D){S.row==(D==1?k:T).row&&(S.column+=D*(T.column-k.column)),S.row+=D*(T.row-k.row)}function x(S,k){var T=S.lines,D=S.end;S.end=g(k);var L=S.end.row-S.start.row,O=T.splice(L,T.length),z=L?k.column:k.column-S.start.column;T.push(O[0].substring(0,z)),O[0]=O[0].substr(z);var P={start:g(k),end:D,lines:O,action:S.action};return P}function M(S,k){k=o(k);for(var T=S.length;T--;){for(var D=S[T],L=0;L<D.length;L++){var O=D[L],z=a(O,k);k=z[0],z.length!=2&&(z[2]?(D.splice(L+1,1,z[1],z[2]),L++):z[1]||(D.splice(L,1),L--))}D.length||S.splice(T,1)}return S}function $(S,k){for(var T=0;T<k.length;T++)for(var D=k[T],L=0;L<D.length;L++)M(S,D[L])}r.UndoManager=d}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(t,r,l){var d=t("../range").Range,h=function(){function b(p,g){this.foldData=p,Array.isArray(g)?this.folds=g:g=this.folds=[g];var o=g[g.length-1];this.range=new d(g[0].start.row,g[0].start.column,o.end.row,o.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach(function(c){c.setFoldLine(this)},this)}return b.prototype.shiftRow=function(p){this.start.row+=p,this.end.row+=p,this.folds.forEach(function(g){g.start.row+=p,g.end.row+=p})},b.prototype.addFold=function(p){if(p.sameRow){if(p.start.row<this.startRow||p.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(p),this.folds.sort(function(g,o){return-g.range.compareEnd(o.start.row,o.start.column)}),this.range.compareEnd(p.start.row,p.start.column)>0?(this.end.row=p.end.row,this.end.column=p.end.column):this.range.compareStart(p.end.row,p.end.column)<0&&(this.start.row=p.start.row,this.start.column=p.start.column)}else if(p.start.row==this.end.row)this.folds.push(p),this.end.row=p.end.row,this.end.column=p.end.column;else if(p.end.row==this.start.row)this.folds.unshift(p),this.start.row=p.start.row,this.start.column=p.start.column;else throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");p.foldLine=this},b.prototype.containsRow=function(p){return p>=this.start.row&&p<=this.end.row},b.prototype.walk=function(p,g,o){var c=0,f=this.folds,u,i,a,m=!0;g==null&&(g=this.end.row,o=this.end.column);for(var w=0;w<f.length;w++){if(u=f[w],i=u.range.compareStart(g,o),i==-1){p(null,g,o,c,m);return}if(a=p(null,u.start.row,u.start.column,c,m),a=!a&&p(u.placeholder,u.start.row,u.start.column,c),a||i===0)return;m=!u.sameRow,c=u.end.column}p(null,g,o,c,m)},b.prototype.getNextFoldTo=function(p,g){for(var o,c,f=0;f<this.folds.length;f++){if(o=this.folds[f],c=o.range.compareEnd(p,g),c==-1)return{fold:o,kind:"after"};if(c===0)return{fold:o,kind:"inside"}}return null},b.prototype.addRemoveChars=function(p,g,o){var c=this.getNextFoldTo(p,g),f,u;if(c){if(f=c.fold,c.kind=="inside"&&f.start.column!=g&&f.start.row!=p)window.console&&window.console.log(p,g,f);else if(f.start.row==p){u=this.folds;var i=u.indexOf(f);for(i===0&&(this.start.column+=o),i;i<u.length;i++){if(f=u[i],f.start.column+=o,!f.sameRow)return;f.end.column+=o}this.end.column+=o}}},b.prototype.split=function(p,g){var o=this.getNextFoldTo(p,g);if(!o||o.kind=="inside")return null;var c=o.fold,f=this.folds,u=this.foldData,i=f.indexOf(c),a=f[i-1];this.end.row=a.end.row,this.end.column=a.end.column,f=f.splice(i,f.length-i);var m=new b(u,f);return u.splice(u.indexOf(this)+1,0,m),m},b.prototype.merge=function(p){for(var g=p.folds,o=0;o<g.length;o++)this.addFold(g[o]);var c=this.foldData;c.splice(c.indexOf(p),1)},b.prototype.toString=function(){var p=[this.range.toString()+": ["];return this.folds.forEach(function(g){p.push(" "+g.toString())}),p.push("]"),p.join(`
|
|
202
|
+
`)},b.prototype.idxToPosition=function(p){for(var g=0,o=0;o<this.folds.length;o++){var c=this.folds[o];if(p-=c.start.column-g,p<0)return{row:c.start.row,column:c.start.column+p};if(p-=c.placeholder.length,p<0)return c.start;g=c.end.column}return{row:this.end.row,column:this.end.column+p}},b}();r.FoldLine=h}),ace.define("ace/range_list",["require","exports","module","ace/range"],function(t,r,l){var d=t("./range").Range,h=d.comparePoints,b=function(){function p(){this.ranges=[],this.$bias=1}return p.prototype.pointIndex=function(g,o,c){for(var f=this.ranges,u=c||0;u<f.length;u++){var i=f[u],a=h(g,i.end);if(!(a>0)){var m=h(g,i.start);return a===0?o&&m!==0?-u-2:u:m>0||m===0&&!o?u:-u-1}}return-u-1},p.prototype.add=function(g){var o=!g.isEmpty(),c=this.pointIndex(g.start,o);c<0&&(c=-c-1);var f=this.pointIndex(g.end,o,c);return f<0?f=-f-1:f++,this.ranges.splice(c,f-c,g)},p.prototype.addList=function(g){for(var o=[],c=g.length;c--;)o.push.apply(o,this.add(g[c]));return o},p.prototype.substractPoint=function(g){var o=this.pointIndex(g);if(o>=0)return this.ranges.splice(o,1)},p.prototype.merge=function(){var g=[],o=this.ranges;o=o.sort(function(a,m){return h(a.start,m.start)});for(var c=o[0],f,u=1;u<o.length;u++){f=c,c=o[u];var i=h(f.end,c.start);i<0||i==0&&!f.isEmpty()&&!c.isEmpty()||(h(f.end,c.end)<0&&(f.end.row=c.end.row,f.end.column=c.end.column),o.splice(u,1),g.push(c),c=f,u--)}return this.ranges=o,g},p.prototype.contains=function(g,o){return this.pointIndex({row:g,column:o})>=0},p.prototype.containsPoint=function(g){return this.pointIndex(g)>=0},p.prototype.rangeAtPoint=function(g){var o=this.pointIndex(g);if(o>=0)return this.ranges[o]},p.prototype.clipRows=function(g,o){var c=this.ranges;if(c[0].start.row>o||c[c.length-1].start.row<g)return[];var f=this.pointIndex({row:g,column:0});f<0&&(f=-f-1);var u=this.pointIndex({row:o,column:0},f);u<0&&(u=-u-1);for(var i=[],a=f;a<u;a++)i.push(c[a]);return i},p.prototype.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},p.prototype.attach=function(g){this.session&&this.detach(),this.session=g,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},p.prototype.detach=function(){this.session&&(this.session.removeListener("change",this.onChange),this.session=null)},p.prototype.$onChange=function(g){for(var o=g.start,c=g.end,f=o.row,u=c.row,i=this.ranges,a=0,m=i.length;a<m;a++){var w=i[a];if(w.end.row>=f)break}if(g.action=="insert")for(var x=u-f,M=-o.column+c.column;a<m;a++){var w=i[a];if(w.start.row>f)break;if(w.start.row==f&&w.start.column>=o.column&&(w.start.column==o.column&&this.$bias<=0||(w.start.column+=M,w.start.row+=x)),w.end.row==f&&w.end.column>=o.column){if(w.end.column==o.column&&this.$bias<0)continue;w.end.column==o.column&&M>0&&a<m-1&&w.end.column>w.start.column&&w.end.column==i[a+1].start.column&&(w.end.column-=M),w.end.column+=M,w.end.row+=x}}else for(var x=f-u,M=o.column-c.column;a<m;a++){var w=i[a];if(w.start.row>u)break;w.end.row<u&&(f<w.end.row||f==w.end.row&&o.column<w.end.column)?(w.end.row=f,w.end.column=o.column):w.end.row==u?w.end.column<=c.column?(x||w.end.column>o.column)&&(w.end.column=o.column,w.end.row=o.row):(w.end.column+=M,w.end.row+=x):w.end.row>u&&(w.end.row+=x),w.start.row<u&&(f<w.start.row||f==w.start.row&&o.column<w.start.column)?(w.start.row=f,w.start.column=o.column):w.start.row==u?w.start.column<=c.column?(x||w.start.column>o.column)&&(w.start.column=o.column,w.start.row=o.row):(w.start.column+=M,w.start.row+=x):w.start.row>u&&(w.start.row+=x)}if(x!=0&&a<m)for(;a<m;a++){var w=i[a];w.start.row+=x,w.end.row+=x}},p}();b.prototype.comparePoints=h,r.RangeList=b}),ace.define("ace/edit_session/fold",["require","exports","module","ace/range_list"],function(t,r,l){var d=this&&this.__extends||function(){var f=function(u,i){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,m){a.__proto__=m}||function(a,m){for(var w in m)Object.prototype.hasOwnProperty.call(m,w)&&(a[w]=m[w])},f(u,i)};return function(u,i){if(typeof i!="function"&&i!==null)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");f(u,i);function a(){this.constructor=u}u.prototype=i===null?Object.create(i):(a.prototype=i.prototype,new a)}}(),h=t("../range_list").RangeList,b=function(f){d(u,f);function u(i,a){var m=f.call(this)||this;return m.foldLine=null,m.placeholder=a,m.range=i,m.start=i.start,m.end=i.end,m.sameRow=i.start.row==i.end.row,m.subFolds=m.ranges=[],m}return u.prototype.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},u.prototype.setFoldLine=function(i){this.foldLine=i,this.subFolds.forEach(function(a){a.setFoldLine(i)})},u.prototype.clone=function(){var i=this.range.clone(),a=new u(i,this.placeholder);return this.subFolds.forEach(function(m){a.subFolds.push(m.clone())}),a.collapseChildren=this.collapseChildren,a},u.prototype.addSubFold=function(i){if(!this.range.isEqual(i)){g(i,this.start);for(var a=i.start.row,m=i.start.column,w=0,x=-1;w<this.subFolds.length&&(x=this.subFolds[w].range.compare(a,m),x==1);w++);var M=this.subFolds[w],$=0;if(x==0){if(M.range.containsRange(i))return M.addSubFold(i);$=1}for(var a=i.range.end.row,m=i.range.end.column,S=w,x=-1;S<this.subFolds.length&&(x=this.subFolds[S].range.compare(a,m),x==1);S++);x==0&&S++;for(var k=this.subFolds.splice(w,S-w,i),T=x==0?k.length-1:k.length,D=$;D<T;D++)i.addSubFold(k[D]);return i.setFoldLine(this.foldLine),i}},u.prototype.restoreRange=function(i){return c(i,this.start)},u}(h);function p(f,u){f.row-=u.row,f.row==0&&(f.column-=u.column)}function g(f,u){p(f.start,u),p(f.end,u)}function o(f,u){f.row==0&&(f.column+=u.column),f.row+=u.row}function c(f,u){o(f.start,u),o(f.end,u)}r.Fold=b}),ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator","ace/mouse/mouse_event"],function(t,r,l){var d=t("../range").Range,h=t("./fold_line").FoldLine,b=t("./fold").Fold,p=t("../token_iterator").TokenIterator,g=t("../mouse/mouse_event").MouseEvent;function o(){this.getFoldAt=function(c,f,u){var i=this.getFoldLine(c);if(!i)return null;for(var a=i.folds,m=0;m<a.length;m++){var w=a[m].range;if(w.contains(c,f)){if(u==1&&w.isEnd(c,f)&&!w.isEmpty()||u==-1&&w.isStart(c,f)&&!w.isEmpty())continue;return a[m]}}},this.getFoldsInRange=function(c){var f=c.start,u=c.end,i=this.$foldData,a=[];f.column+=1,u.column-=1;for(var m=0;m<i.length;m++){var w=i[m].range.compareRange(c);if(w!=2){if(w==-2)break;for(var x=i[m].folds,M=0;M<x.length;M++){var $=x[M];if(w=$.range.compareRange(c),w==-2)break;if(w!=2){if(w==42)break;a.push($)}}}}return f.column-=1,u.column+=1,a},this.getFoldsInRangeList=function(c){if(Array.isArray(c)){var f=[];c.forEach(function(i){f=f.concat(this.getFoldsInRange(i))},this)}else var f=this.getFoldsInRange(c);return f},this.getAllFolds=function(){for(var c=[],f=this.$foldData,u=0;u<f.length;u++)for(var i=0;i<f[u].folds.length;i++)c.push(f[u].folds[i]);return c},this.getFoldStringAt=function(c,f,u,i){if(i=i||this.getFoldLine(c),!i)return null;for(var a={end:{column:0}},m,w,x=0;x<i.folds.length;x++){w=i.folds[x];var M=w.range.compareEnd(c,f);if(M==-1){m=this.getLine(w.start.row).substring(a.end.column,w.start.column);break}else if(M===0)return null;a=w}return m||(m=this.getLine(w.start.row).substring(a.end.column)),u==-1?m.substring(0,f-a.end.column):u==1?m.substring(f-a.end.column):m},this.getFoldLine=function(c,f){var u=this.$foldData,i=0;for(f&&(i=u.indexOf(f)),i==-1&&(i=0),i;i<u.length;i++){var a=u[i];if(a.start.row<=c&&a.end.row>=c)return a;if(a.end.row>c)return null}return null},this.getNextFoldLine=function(c,f){var u=this.$foldData,i=0;for(f&&(i=u.indexOf(f)),i==-1&&(i=0),i;i<u.length;i++){var a=u[i];if(a.end.row>=c)return a}return null},this.getFoldedRowCount=function(c,f){for(var u=this.$foldData,i=f-c+1,a=0;a<u.length;a++){var m=u[a],w=m.end.row,x=m.start.row;if(w>=f){x<f&&(x>=c?i-=f-x:i=0);break}else w>=c&&(x>=c?i-=w-x:i-=w-c+1)}return i},this.$addFoldLine=function(c){return this.$foldData.push(c),this.$foldData.sort(function(f,u){return f.start.row-u.start.row}),c},this.addFold=function(c,f){var u=this.$foldData,i=!1,a;c instanceof b?a=c:(a=new b(f,c),a.collapseChildren=f.collapseChildren),this.$clipRangeToDocument(a.range);var m=a.start.row,w=a.start.column,x=a.end.row,M=a.end.column,$=this.getFoldAt(m,w,1),S=this.getFoldAt(x,M,-1);if($&&S==$)return $.addSubFold(a);$&&!$.range.isStart(m,w)&&this.removeFold($),S&&!S.range.isEnd(x,M)&&this.removeFold(S);var k=this.getFoldsInRange(a.range);k.length>0&&(this.removeFolds(k),a.collapseChildren||k.forEach(function(O){a.addSubFold(O)}));for(var T=0;T<u.length;T++){var D=u[T];if(x==D.start.row){D.addFold(a),i=!0;break}else if(m==D.end.row){if(D.addFold(a),i=!0,!a.sameRow){var L=u[T+1];if(L&&L.start.row==x){D.merge(L);break}}break}else if(x<=D.start.row)break}return i||(D=this.$addFoldLine(new h(this.$foldData,a))),this.$useWrapMode?this.$updateWrapData(D.start.row,D.start.row):this.$updateRowLengthCache(D.start.row,D.start.row),this.$modified=!0,this._signal("changeFold",{data:a,action:"add"}),a},this.addFolds=function(c){c.forEach(function(f){this.addFold(f)},this)},this.removeFold=function(c){var f=c.foldLine,u=f.start.row,i=f.end.row,a=this.$foldData,m=f.folds;if(m.length==1)a.splice(a.indexOf(f),1);else if(f.range.isEnd(c.end.row,c.end.column))m.pop(),f.end.row=m[m.length-1].end.row,f.end.column=m[m.length-1].end.column;else if(f.range.isStart(c.start.row,c.start.column))m.shift(),f.start.row=m[0].start.row,f.start.column=m[0].start.column;else if(c.sameRow)m.splice(m.indexOf(c),1);else{var w=f.split(c.start.row,c.start.column);m=w.folds,m.shift(),w.start.row=m[0].start.row,w.start.column=m[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(u,i):this.$updateRowLengthCache(u,i)),this.$modified=!0,this._signal("changeFold",{data:c,action:"remove"})},this.removeFolds=function(c){for(var f=[],u=0;u<c.length;u++)f.push(c[u]);f.forEach(function(i){this.removeFold(i)},this),this.$modified=!0},this.expandFold=function(c){this.removeFold(c),c.subFolds.forEach(function(f){c.restoreRange(f),this.addFold(f)},this),c.collapseChildren>0&&this.foldAll(c.start.row+1,c.end.row,c.collapseChildren-1),c.subFolds=[]},this.expandFolds=function(c){c.forEach(function(f){this.expandFold(f)},this)},this.unfold=function(c,f){var u,i;if(c==null)u=new d(0,0,this.getLength(),0),f==null&&(f=!0);else if(typeof c=="number")u=new d(c,0,c,this.getLine(c).length);else if("row"in c)u=d.fromPoints(c,c);else{if(Array.isArray(c))return i=[],c.forEach(function(m){i=i.concat(this.unfold(m))},this),i;u=c}i=this.getFoldsInRangeList(u);for(var a=i;i.length==1&&d.comparePoints(i[0].start,u.start)<0&&d.comparePoints(i[0].end,u.end)>0;)this.expandFolds(i),i=this.getFoldsInRangeList(u);if(f!=!1?this.removeFolds(i):this.expandFolds(i),a.length)return a},this.isRowFolded=function(c,f){return!!this.getFoldLine(c,f)},this.getRowFoldEnd=function(c,f){var u=this.getFoldLine(c,f);return u?u.end.row:c},this.getRowFoldStart=function(c,f){var u=this.getFoldLine(c,f);return u?u.start.row:c},this.getFoldDisplayLine=function(c,f,u,i,a){i==null&&(i=c.start.row),a==null&&(a=0),f==null&&(f=c.end.row),u==null&&(u=this.getLine(f).length);var m=this.doc,w="";return c.walk(function(x,M,$,S){if(!(M<i)){if(M==i){if($<a)return;S=Math.max(a,S)}x!=null?w+=x:w+=m.getLine(M).substring(S,$)}},f,u),w},this.getDisplayLine=function(c,f,u,i){var a=this.getFoldLine(c);if(a)return this.getFoldDisplayLine(a,c,f,u,i);var m;return m=this.doc.getLine(c),m.substring(i||0,f||m.length)},this.$cloneFoldData=function(){var c=[];return c=this.$foldData.map(function(f){var u=f.folds.map(function(i){return i.clone()});return new h(c,u)}),c},this.toggleFold=function(c){var f=this.selection,u=f.getRange(),i,a;if(u.isEmpty()){var m=u.start;if(i=this.getFoldAt(m.row,m.column),i){this.expandFold(i);return}else if(c){var w=this.getFoldLine(m.row);w&&this.expandFolds(w.folds);return}else(a=this.findMatchingBracket(m))?u.comparePoint(a)==1?u.end=a:(u.start=a,u.start.column++,u.end.column--):(a=this.findMatchingBracket({row:m.row,column:m.column+1}))?(u.comparePoint(a)==1?u.end=a:u.start=a,u.start.column++):u=this.getCommentFoldRange(m.row,m.column)||u}else{var x=this.getFoldsInRange(u);if(c&&x.length){this.expandFolds(x);return}else x.length==1&&(i=x[0])}if(i||(i=this.getFoldAt(u.start.row,u.start.column)),i&&i.range.toString()==u.toString()){this.expandFold(i);return}var M="...";if(!u.isMultiLine()){if(M=this.getTextRange(u),M.length<4)return;M=M.trim().substring(0,2)+".."}this.addFold(M,u)},this.getCommentFoldRange=function(c,f,u){var i=new p(this,c,f),a=i.getCurrentToken(),m=a&&a.type;if(a&&/^comment|string/.test(m)){m=m.match(/comment|string/)[0],m=="comment"&&(m+="|doc-start|\\.doc");var w=new RegExp(m),x=new d;if(u!=1){do a=i.stepBackward();while(a&&w.test(a.type));a=i.stepForward()}x.start.row=i.getCurrentTokenRow(),x.start.column=i.getCurrentTokenColumn()+a.value.length,i=new p(this,c,f);var M=this.getState(i.$row);if(u!=-1){var $=-1;do if(a=i.stepForward(),$==-1){var S=this.getState(i.$row);M.toString()!==S.toString()&&($=i.$row)}else if(i.$row>$)break;while(a&&w.test(a.type));a=i.stepBackward()}else a=i.getCurrentToken();return x.end.row=i.getCurrentTokenRow(),x.end.column=i.getCurrentTokenColumn(),x.start.row==x.end.row&&x.start.column>x.end.column?void 0:x}},this.foldAll=function(c,f,u,i){u==null&&(u=1e5);var a=this.foldWidgets;if(a){f=f||this.getLength(),c=c||0;for(var m=c;m<f;m++)if(a[m]==null&&(a[m]=this.getFoldWidget(m)),a[m]=="start"&&!(i&&!i(m))){var w=this.getFoldWidgetRange(m);w&&w.isMultiLine()&&w.end.row<=f&&w.start.row>=c&&(m=w.end.row,w.collapseChildren=u,this.addFold("...",w))}}},this.foldToLevel=function(c){for(this.foldAll();c-- >0;)this.unfold(null,!1)},this.foldAllComments=function(){var c=this;this.foldAll(null,null,null,function(f){for(var u=c.getTokens(f),i=0;i<u.length;i++){var a=u[i];if(!(a.type=="text"&&/^\s+$/.test(a.value)))return!!/comment/.test(a.type)}})},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(c){if(!this.$foldStyles[c])throw new Error("invalid fold style: "+c+"["+Object.keys(this.$foldStyles).join(", ")+"]");if(this.$foldStyle!=c){this.$foldStyle=c,c=="manual"&&this.unfold();var f=this.$foldMode;this.$setFolding(null),this.$setFolding(f)}},this.$setFolding=function(c){if(this.$foldMode!=c){if(this.$foldMode=c,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._signal("changeAnnotation"),!c||this.$foldStyle=="manual"){this.foldWidgets=null;return}this.foldWidgets=[],this.getFoldWidget=c.getFoldWidget.bind(c,this,this.$foldStyle),this.getFoldWidgetRange=c.getFoldWidgetRange.bind(c,this,this.$foldStyle),this.$updateFoldWidgets=this.updateFoldWidgets.bind(this),this.$tokenizerUpdateFoldWidgets=this.tokenizerUpdateFoldWidgets.bind(this),this.on("change",this.$updateFoldWidgets),this.on("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets)}},this.getParentFoldRangeData=function(c,f){var u=this.foldWidgets;if(!u||f&&u[c])return{};for(var i=c-1,a;i>=0;){var m=u[i];if(m==null&&(m=u[i]=this.getFoldWidget(i)),m=="start"){var w=this.getFoldWidgetRange(i);if(a||(a=w),w&&w.end.row>=c)break}i--}return{range:i!==-1&&w,firstRange:a}},this.onFoldWidgetClick=function(c,f){f instanceof g&&(f=f.domEvent);var u={children:f.shiftKey,all:f.ctrlKey||f.metaKey,siblings:f.altKey},i=this.$toggleFoldWidget(c,u);if(!i){var a=f.target||f.srcElement;a&&/ace_fold-widget/.test(a.className)&&(a.className+=" ace_invalid")}},this.$toggleFoldWidget=function(c,f){if(this.getFoldWidget){var u=this.getFoldWidget(c),i=this.getLine(c),a=u==="end"?-1:1,m=this.getFoldAt(c,a===-1?0:i.length,a);if(m)return f.children||f.all?this.removeFold(m):this.expandFold(m),m;var w=this.getFoldWidgetRange(c,!0);if(w&&!w.isMultiLine()&&(m=this.getFoldAt(w.start.row,w.start.column,1),m&&w.isEqual(m.range)))return this.removeFold(m),m;if(f.siblings){var x=this.getParentFoldRangeData(c);if(x.range)var M=x.range.start.row+1,$=x.range.end.row;this.foldAll(M,$,f.all?1e4:0)}else f.children?($=w?w.end.row:this.getLength(),this.foldAll(c+1,$,f.all?1e4:0)):w&&(f.all&&(w.collapseChildren=1e4),this.addFold("...",w));return w}},this.toggleFoldWidget=function(c){var f=this.selection.getCursor().row;f=this.getRowFoldStart(f);var u=this.$toggleFoldWidget(f,{});if(!u){var i=this.getParentFoldRangeData(f,!0);if(u=i.range||i.firstRange,u){f=u.start.row;var a=this.getFoldAt(f,this.getLine(f).length,1);a?this.removeFold(a):this.addFold("...",u)}}},this.updateFoldWidgets=function(c){var f=c.start.row,u=c.end.row-f;if(u===0)this.foldWidgets[f]=null;else if(c.action=="remove")this.foldWidgets.splice(f,u+1,null);else{var i=Array(u+1);i.unshift(f,1),this.foldWidgets.splice.apply(this.foldWidgets,i)}},this.tokenizerUpdateFoldWidgets=function(c){var f=c.data;f.first!=f.last&&this.foldWidgets.length>f.first&&this.foldWidgets.splice(f.first,this.foldWidgets.length)}}r.Folding=o}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(t,r,l){var d=t("../token_iterator").TokenIterator,h=t("../range").Range;function b(){this.findMatchingBracket=function(p,g){if(p.column==0)return null;var o=g||this.getLine(p.row).charAt(p.column-1);if(o=="")return null;var c=o.match(/([\(\[\{])|([\)\]\}])/);return c?c[1]?this.$findClosingBracket(c[1],p):this.$findOpeningBracket(c[2],p):null},this.getBracketRange=function(p){var g=this.getLine(p.row),o=!0,c,f=g.charAt(p.column-1),u=f&&f.match(/([\(\[\{])|([\)\]\}])/);if(u||(f=g.charAt(p.column),p={row:p.row,column:p.column+1},u=f&&f.match(/([\(\[\{])|([\)\]\}])/),o=!1),!u)return null;if(u[1]){var i=this.$findClosingBracket(u[1],p);if(!i)return null;c=h.fromPoints(p,i),o||(c.end.column++,c.start.column--),c.cursor=c.end}else{var i=this.$findOpeningBracket(u[2],p);if(!i)return null;c=h.fromPoints(i,p),o||(c.start.column++,c.end.column--),c.cursor=c.start}return c},this.getMatchingBracketRanges=function(p,g){var o=this.getLine(p.row),c=/([\(\[\{])|([\)\]\}])/,f=!g&&o.charAt(p.column-1),u=f&&f.match(c);if(u||(f=(g===void 0||g)&&o.charAt(p.column),p={row:p.row,column:p.column+1},u=f&&f.match(c)),!u)return null;var i=new h(p.row,p.column-1,p.row,p.column),a=u[1]?this.$findClosingBracket(u[1],p):this.$findOpeningBracket(u[2],p);if(!a)return[i];var m=new h(a.row,a.column,a.row,a.column+1);return[i,m]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(p,g,o){var c=this.$brackets[p],f=1,u=new d(this,g.row,g.column),i=u.getCurrentToken();if(i||(i=u.stepForward()),!!i){o||(o=new RegExp("(\\.?"+i.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)").replace(/-close\b/,"-(close|open)")+")+"));for(var a=g.column-u.getCurrentTokenColumn()-2,m=i.value;;){for(;a>=0;){var w=m.charAt(a);if(w==c){if(f-=1,f==0)return{row:u.getCurrentTokenRow(),column:a+u.getCurrentTokenColumn()}}else w==p&&(f+=1);a-=1}do i=u.stepBackward();while(i&&!o.test(i.type));if(i==null)break;m=i.value,a=m.length-1}return null}},this.$findClosingBracket=function(p,g,o){var c=this.$brackets[p],f=1,u=new d(this,g.row,g.column),i=u.getCurrentToken();if(i||(i=u.stepForward()),!!i){o||(o=new RegExp("(\\.?"+i.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)").replace(/-open\b/,"-(close|open)")+")+"));for(var a=g.column-u.getCurrentTokenColumn();;){for(var m=i.value,w=m.length;a<w;){var x=m.charAt(a);if(x==c){if(f-=1,f==0)return{row:u.getCurrentTokenRow(),column:a+u.getCurrentTokenColumn()}}else x==p&&(f+=1);a+=1}do i=u.stepForward();while(i&&!o.test(i.type));if(i==null)break;a=0}return null}},this.getMatchingTags=function(p){var g=new d(this,p.row,p.column),o=this.$findTagName(g);if(o){var c=g.stepBackward();return c.value==="<"?this.$findClosingTag(g,o):this.$findOpeningTag(g,o)}},this.$findTagName=function(p){var g=p.getCurrentToken(),o=!1,c=!1;if(g&&g.type.indexOf("tag-name")===-1)do c?g=p.stepBackward():g=p.stepForward(),g&&(g.value==="/>"?c=!0:g.type.indexOf("tag-name")!==-1&&(o=!0));while(g&&!o);return g},this.$findClosingTag=function(p,g){var o,c=g.value,f=g.value,u=0,i=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+1);g=p.stepForward();var a=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+g.value.length),m=!1;do{if(o=g,o.type.indexOf("tag-close")!==-1&&!m){var w=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+1);m=!0}if(g=p.stepForward(),g){if(g.value===">"&&!m){var w=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+1);m=!0}if(g.type.indexOf("tag-name")!==-1){if(c=g.value,f===c){if(o.value==="<")u++;else if(o.value==="</"&&(u--,u<0)){p.stepBackward();var x=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+2);g=p.stepForward();var M=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+g.value.length);if(g.type.indexOf("tag-close")===-1&&(g=p.stepForward()),g&&g.value===">")var $=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+1);else return}}}else if(f===c&&g.value==="/>"&&(u--,u<0))var x=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+2),M=x,$=M,w=new h(a.end.row,a.end.column,a.end.row,a.end.column+1)}}while(g&&u>=0);if(i&&w&&x&&$&&a&&M)return{openTag:new h(i.start.row,i.start.column,w.end.row,w.end.column),closeTag:new h(x.start.row,x.start.column,$.end.row,$.end.column),openTagName:a,closeTagName:M}},this.$findOpeningTag=function(p,g){var o=p.getCurrentToken(),c=g.value,f=0,u=p.getCurrentTokenRow(),i=p.getCurrentTokenColumn(),a=i+2,m=new h(u,i,u,a);p.stepForward();var w=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+g.value.length);if(g.type.indexOf("tag-close")===-1&&(g=p.stepForward()),!(!g||g.value!==">")){var x=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+1);p.stepBackward(),p.stepBackward();do if(g=o,u=p.getCurrentTokenRow(),i=p.getCurrentTokenColumn(),a=i+g.value.length,o=p.stepBackward(),g){if(g.type.indexOf("tag-name")!==-1){if(c===g.value)if(o.value==="<"){if(f++,f>0){var M=new h(u,i,u,a),$=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+1);do g=p.stepForward();while(g&&g.value!==">");var S=new h(p.getCurrentTokenRow(),p.getCurrentTokenColumn(),p.getCurrentTokenRow(),p.getCurrentTokenColumn()+1)}}else o.value==="</"&&f--}else if(g.value==="/>"){for(var k=0,T=o;T;){if(T.type.indexOf("tag-name")!==-1&&T.value===c){f--;break}else if(T.value==="<")break;T=p.stepBackward(),k++}for(var D=0;D<k;D++)p.stepForward()}}while(o&&f<=0);if($&&S&&m&&x&&M&&w)return{openTag:new h($.start.row,$.start.column,S.end.row,S.end.column),closeTag:new h(m.start.row,m.start.column,x.end.row,x.end.column),openTagName:M,closeTagName:w}}}}r.BracketMatch=b}),ace.define("ace/edit_session",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/bidihandler","ace/config","ace/lib/event_emitter","ace/selection","ace/mode/text","ace/range","ace/line_widgets","ace/document","ace/background_tokenizer","ace/search_highlight","ace/undomanager","ace/edit_session/folding","ace/edit_session/bracket_match"],function(t,r,l){var d=t("./lib/oop"),h=t("./lib/lang"),b=t("./bidihandler").BidiHandler,p=t("./config"),g=t("./lib/event_emitter").EventEmitter,o=t("./selection").Selection,c=t("./mode/text").Mode,f=t("./range").Range,u=t("./line_widgets").LineWidgets,i=t("./document").Document,a=t("./background_tokenizer").BackgroundTokenizer,m=t("./search_highlight").SearchHighlight,w=t("./undomanager").UndoManager,x=function(){function P(N,A){this.doc,this.$breakpoints=[],this.$decorations=[],this.$frontMarkers={},this.$backMarkers={},this.$markerId=1,this.$undoSelect=!0,this.$editor=null,this.prevOp={},this.$foldData=[],this.id="session"+ ++P.$uid,this.$foldData.toString=function(){return this.join(`
|
|
203
|
+
`)},this.$gutterCustomWidgets={},this.bgTokenizer=new a(new c().getTokenizer(),this);var _=this;this.bgTokenizer.on("update",function(I){_._signal("tokenizerUpdate",I)}),this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this),(typeof N!="object"||!N.getLine)&&(N=new i(N)),this.setDocument(N),this.selection=new o(this),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.selection.on("changeCursor",this.$onSelectionChange),this.$bidiHandler=new b(this),p.resetOptions(this),this.setMode(A),p._signal("session",this),this.destroyed=!1,this.$initOperationListeners()}return P.prototype.$initOperationListeners=function(){var N=this;this.curOp=null,this.on("change",function(){N.curOp||(N.startOperation(),N.curOp.selectionBefore=N.$lastSel),N.curOp.docChanged=!0},!0),this.on("changeSelection",function(){N.curOp||(N.startOperation(),N.curOp.selectionBefore=N.$lastSel),N.curOp.selectionChanged=!0},!0),this.$operationResetTimer=h.delayedCall(this.endOperation.bind(this,!0))},P.prototype.startOperation=function(N){if(this.curOp){if(!N||this.curOp.command)return;this.prevOp=this.curOp}N||(N={}),this.$operationResetTimer.schedule(),this.curOp={command:N.command||{},args:N.args},this.curOp.selectionBefore=this.selection.toJSON(),this._signal("startOperation",N)},P.prototype.endOperation=function(N){if(this.curOp){if(N&&N.returnValue===!1){this.curOp=null,this._signal("endOperation",N);return}if(N==!0&&this.curOp.command&&this.curOp.command.name=="mouse")return;var A=this.selection.toJSON();this.curOp.selectionAfter=A,this.$lastSel=this.selection.toJSON(),this.getUndoManager().addSelection(A),this._signal("beforeEndOperation"),this.prevOp=this.curOp,this.curOp=null,this._signal("endOperation",N)}},P.prototype.setDocument=function(N){this.doc&&this.doc.off("change",this.$onChange),this.doc=N,N.on("change",this.$onChange,!0),this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},P.prototype.getDocument=function(){return this.doc},Object.defineProperty(P.prototype,"widgetManager",{get:function(){var N=new u(this);return this.widgetManager=N,this.$editor&&N.attach(this.$editor),N},set:function(N){Object.defineProperty(this,"widgetManager",{writable:!0,enumerable:!0,configurable:!0,value:N})},enumerable:!1,configurable:!0}),P.prototype.$resetRowCache=function(N){if(!N){this.$docRowCache=[],this.$screenRowCache=[];return}var A=this.$docRowCache.length,_=this.$getRowCacheIndex(this.$docRowCache,N)+1;A>_&&(this.$docRowCache.splice(_,A),this.$screenRowCache.splice(_,A))},P.prototype.$getRowCacheIndex=function(N,A){for(var _=0,I=N.length-1;_<=I;){var j=_+I>>1,U=N[j];if(A>U)_=j+1;else if(A<U)I=j-1;else return j}return _-1},P.prototype.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.destroyed||this.bgTokenizer.start(0)},P.prototype.onChangeFold=function(N){var A=N.data;this.$resetRowCache(A.start.row)},P.prototype.onChange=function(N){this.$modified=!0,this.$bidiHandler.onChange(N),this.$resetRowCache(N.start.row);var A=this.$updateInternalDataOnChange(N);!this.$fromUndo&&this.$undoManager&&(A&&A.length&&(this.$undoManager.add({action:"removeFolds",folds:A},this.mergeUndoDeltas),this.mergeUndoDeltas=!0),this.$undoManager.add(N,this.mergeUndoDeltas),this.mergeUndoDeltas=!0,this.$informUndoManager.schedule()),this.bgTokenizer.$updateOnChange(N),this._signal("change",N)},P.prototype.onSelectionChange=function(){this._signal("changeSelection")},P.prototype.setValue=function(N){this.doc.setValue(N),this.selection.moveTo(0,0),this.$resetRowCache(0),this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},P.fromJSON=function(N){typeof N=="string"&&(N=JSON.parse(N));var A=new w;A.$undoStack=N.history.undo,A.$redoStack=N.history.redo,A.mark=N.history.mark,A.$rev=N.history.rev;var _=new P(N.value);return N.folds.forEach(function(I){_.addFold("...",f.fromPoints(I.start,I.end))}),_.setAnnotations(N.annotations),_.setBreakpoints(N.breakpoints),_.setMode(N.mode),_.setScrollLeft(N.scrollLeft),_.setScrollTop(N.scrollTop),_.setUndoManager(A),_.selection.fromJSON(N.selection),_},P.prototype.toJSON=function(){return{annotations:this.$annotations,breakpoints:this.$breakpoints,folds:this.getAllFolds().map(function(N){return N.range}),history:this.getUndoManager(),mode:this.$mode.$id,scrollLeft:this.$scrollLeft,scrollTop:this.$scrollTop,selection:this.selection.toJSON(),value:this.doc.getValue()}},P.prototype.toString=function(){return this.doc.getValue()},P.prototype.getSelection=function(){return this.selection},P.prototype.getState=function(N){return this.bgTokenizer.getState(N)},P.prototype.getTokens=function(N){return this.bgTokenizer.getTokens(N)},P.prototype.getTokenAt=function(N,A){var _=this.bgTokenizer.getTokens(N),I,j=0;if(A==null){var U=_.length-1;j=this.getLine(N).length}else for(var U=0;U<_.length&&(j+=_[U].value.length,!(j>=A));U++);return I=_[U],I?(I.index=U,I.start=j-I.value.length,I):null},P.prototype.setUndoManager=function(N){if(this.$undoManager=N,this.$informUndoManager&&this.$informUndoManager.cancel(),N){var A=this;N.addSession(this),this.$syncInformUndoManager=function(){A.$informUndoManager.cancel(),A.mergeUndoDeltas=!1},this.$informUndoManager=h.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},P.prototype.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},P.prototype.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},P.prototype.getTabString=function(){return this.getUseSoftTabs()?h.stringRepeat(" ",this.getTabSize()):" "},P.prototype.setUseSoftTabs=function(N){this.setOption("useSoftTabs",N)},P.prototype.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},P.prototype.setTabSize=function(N){this.setOption("tabSize",N)},P.prototype.getTabSize=function(){return this.$tabSize},P.prototype.isTabStop=function(N){return this.$useSoftTabs&&N.column%this.$tabSize===0},P.prototype.setNavigateWithinSoftTabs=function(N){this.setOption("navigateWithinSoftTabs",N)},P.prototype.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},P.prototype.setOverwrite=function(N){this.setOption("overwrite",N)},P.prototype.getOverwrite=function(){return this.$overwrite},P.prototype.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},P.prototype.addGutterDecoration=function(N,A){this.$decorations[N]||(this.$decorations[N]=""),this.$decorations[N]+=" "+A,this._signal("changeBreakpoint",{})},P.prototype.removeGutterCustomWidget=function(N){this.$editor&&this.$editor.renderer.$gutterLayer.$removeCustomWidget(N)},P.prototype.addGutterCustomWidget=function(N,A){this.$editor&&this.$editor.renderer.$gutterLayer.$addCustomWidget(N,A)},P.prototype.removeGutterDecoration=function(N,A){this.$decorations[N]=(this.$decorations[N]||"").replace(" "+A,""),this._signal("changeBreakpoint",{})},P.prototype.getBreakpoints=function(){return this.$breakpoints},P.prototype.setBreakpoints=function(N){this.$breakpoints=[];for(var A=0;A<N.length;A++)this.$breakpoints[N[A]]="ace_breakpoint";this._signal("changeBreakpoint",{})},P.prototype.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},P.prototype.setBreakpoint=function(N,A){A===void 0&&(A="ace_breakpoint"),A?this.$breakpoints[N]=A:delete this.$breakpoints[N],this._signal("changeBreakpoint",{})},P.prototype.clearBreakpoint=function(N){delete this.$breakpoints[N],this._signal("changeBreakpoint",{})},P.prototype.addMarker=function(N,A,_,I){var j=this.$markerId++,U={range:N,type:_||"line",renderer:typeof _=="function"?_:null,clazz:A,inFront:!!I,id:j};return I?(this.$frontMarkers[j]=U,this._signal("changeFrontMarker")):(this.$backMarkers[j]=U,this._signal("changeBackMarker")),j},P.prototype.addDynamicMarker=function(N,A){if(N.update){var _=this.$markerId++;return N.id=_,N.inFront=!!A,A?(this.$frontMarkers[_]=N,this._signal("changeFrontMarker")):(this.$backMarkers[_]=N,this._signal("changeBackMarker")),N}},P.prototype.removeMarker=function(N){var A=this.$frontMarkers[N]||this.$backMarkers[N];if(A){var _=A.inFront?this.$frontMarkers:this.$backMarkers;delete _[N],this._signal(A.inFront?"changeFrontMarker":"changeBackMarker")}},P.prototype.getMarkers=function(N){return N?this.$frontMarkers:this.$backMarkers},P.prototype.highlight=function(N){if(!this.$searchHighlight){var A=new m(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(A)}this.$searchHighlight.setRegexp(N)},P.prototype.highlightLines=function(N,A,_,I){typeof A!="number"&&(_=A,A=N),_||(_="ace_step");var j=new f(N,0,A,1/0);return j.id=this.addMarker(j,_,"fullLine",I),j},P.prototype.setAnnotations=function(N){this.$annotations=N,this._signal("changeAnnotation",{})},P.prototype.getAnnotations=function(){return this.$annotations||[]},P.prototype.clearAnnotations=function(){this.setAnnotations([])},P.prototype.$detectNewLine=function(N){var A=N.match(/^.*?(\r?\n)/m);A?this.$autoNewLine=A[1]:this.$autoNewLine=`
|
|
204
|
+
`},P.prototype.getWordRange=function(N,A){var _=this.getLine(N),I=!1;if(A>0&&(I=!!_.charAt(A-1).match(this.tokenRe)),I||(I=!!_.charAt(A).match(this.tokenRe)),I)var j=this.tokenRe;else if(/^\s+$/.test(_.slice(A-1,A+1)))var j=/\s/;else var j=this.nonTokenRe;var U=A;if(U>0){do U--;while(U>=0&&_.charAt(U).match(j));U++}for(var K=A;K<_.length&&_.charAt(K).match(j);)K++;return new f(N,U,N,K)},P.prototype.getAWordRange=function(N,A){for(var _=this.getWordRange(N,A),I=this.getLine(_.end.row);I.charAt(_.end.column).match(/[ \t]/);)_.end.column+=1;return _},P.prototype.setNewLineMode=function(N){this.doc.setNewLineMode(N)},P.prototype.getNewLineMode=function(){return this.doc.getNewLineMode()},P.prototype.setUseWorker=function(N){this.setOption("useWorker",N)},P.prototype.getUseWorker=function(){return this.$useWorker},P.prototype.onReloadTokenizer=function(N){var A=N.data;this.bgTokenizer.start(A.first),this._signal("tokenizerUpdate",N)},P.prototype.setMode=function(N,A){if(N&&typeof N=="object"){if(N.getTokenizer)return this.$onChangeMode(N);var _=N,I=_.path}else I=N||"ace/mode/text";if(this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new c),this.$modes[I]&&!_){this.$onChangeMode(this.$modes[I]),A&&A();return}this.$modeId=I,p.loadModule(["mode",I],(function(j){if(!this.destroyed){if(this.$modeId!==I)return A&&A();this.$modes[I]&&!_?this.$onChangeMode(this.$modes[I]):j&&j.Mode&&(j=new j.Mode(_),_||(this.$modes[I]=j,j.$id=I),this.$onChangeMode(j)),A&&A()}}).bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},P.prototype.$onChangeMode=function(N,A){if(A||(this.$modeId=N.$id),this.$mode!==N){var _=this.$mode;this.$mode=N,this.$stopWorker(),this.$useWorker&&this.$startWorker();var I=N.getTokenizer();if(I.on!==void 0){var j=this.onReloadTokenizer.bind(this);I.on("update",j)}this.bgTokenizer.setTokenizer(I),this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=N.tokenRe,this.nonTokenRe=N.nonTokenRe,A||(N.attachToSession&&N.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(N.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode",{oldMode:_,mode:N}))}},P.prototype.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},P.prototype.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(N){p.warn("Could not load worker",N),this.$worker=null}},P.prototype.getMode=function(){return this.$mode},P.prototype.setScrollTop=function(N){this.$scrollTop===N||isNaN(N)||(this.$scrollTop=N,this._signal("changeScrollTop",N))},P.prototype.getScrollTop=function(){return this.$scrollTop},P.prototype.setScrollLeft=function(N){this.$scrollLeft===N||isNaN(N)||(this.$scrollLeft=N,this._signal("changeScrollLeft",N))},P.prototype.getScrollLeft=function(){return this.$scrollLeft},P.prototype.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},P.prototype.getLineWidgetMaxWidth=function(){if(this.lineWidgetsWidth!=null)return this.lineWidgetsWidth;var N=0;return this.lineWidgets.forEach(function(A){A&&A.screenWidth>N&&(N=A.screenWidth)}),this.lineWidgetWidth=N},P.prototype.$computeWidth=function(N){if(this.$modified||N){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var A=this.doc.getAllLines(),_=this.$rowLengthCache,I=0,j=0,U=this.$foldData[j],K=U?U.start.row:1/0,Z=A.length,J=0;J<Z;J++){if(J>K){if(J=U.end.row+1,J>=Z)break;U=this.$foldData[j++],K=U?U.start.row:1/0}_[J]==null&&(_[J]=this.$getStringScreenWidth(A[J])[0]),_[J]>I&&(I=_[J])}this.screenWidth=I}},P.prototype.getLine=function(N){return this.doc.getLine(N)},P.prototype.getLines=function(N,A){return this.doc.getLines(N,A)},P.prototype.getLength=function(){return this.doc.getLength()},P.prototype.getTextRange=function(N){return this.doc.getTextRange(N||this.selection.getRange())},P.prototype.insert=function(N,A){return this.doc.insert(N,A)},P.prototype.remove=function(N){return this.doc.remove(N)},P.prototype.removeFullLines=function(N,A){return this.doc.removeFullLines(N,A)},P.prototype.undoChanges=function(N,A){if(N.length){this.$fromUndo=!0;for(var _=N.length-1;_!=-1;_--){var I=N[_];I.action=="insert"||I.action=="remove"?this.doc.revertDelta(I):I.folds&&this.addFolds(I.folds)}!A&&this.$undoSelect&&(N.selectionBefore?this.selection.fromJSON(N.selectionBefore):this.selection.setRange(this.$getUndoSelection(N,!0))),this.$fromUndo=!1}},P.prototype.redoChanges=function(N,A){if(N.length){this.$fromUndo=!0;for(var _=0;_<N.length;_++){var I=N[_];(I.action=="insert"||I.action=="remove")&&this.doc.$safeApplyDelta(I)}!A&&this.$undoSelect&&(N.selectionAfter?this.selection.fromJSON(N.selectionAfter):this.selection.setRange(this.$getUndoSelection(N,!1))),this.$fromUndo=!1}},P.prototype.setUndoSelect=function(N){this.$undoSelect=N},P.prototype.$getUndoSelection=function(N,A){function _(Z){return A?Z.action!=="insert":Z.action==="insert"}for(var I,j,U=0;U<N.length;U++){var K=N[U];if(K.start){if(!I){_(K)?I=f.fromPoints(K.start,K.end):I=f.fromPoints(K.start,K.start);continue}_(K)?(j=K.start,I.compare(j.row,j.column)==-1&&I.setStart(j),j=K.end,I.compare(j.row,j.column)==1&&I.setEnd(j)):(j=K.start,I.compare(j.row,j.column)==-1&&(I=f.fromPoints(K.start,K.start)))}}return I},P.prototype.replace=function(N,A){return this.doc.replace(N,A)},P.prototype.moveText=function(N,A,_){var I=this.getTextRange(N),j=this.getFoldsInRange(N),U=f.fromPoints(A,A);if(!_){this.remove(N);var K=N.start.row-N.end.row,Z=K?-N.end.column:N.start.column-N.end.column;Z&&(U.start.row==N.end.row&&U.start.column>N.end.column&&(U.start.column+=Z),U.end.row==N.end.row&&U.end.column>N.end.column&&(U.end.column+=Z)),K&&U.start.row>=N.end.row&&(U.start.row+=K,U.end.row+=K)}if(U.end=this.insert(U.start,I),j.length){var J=N.start,ae=U.start,K=ae.row-J.row,Z=ae.column-J.column;this.addFolds(j.map(function(ce){return ce=ce.clone(),ce.start.row==J.row&&(ce.start.column+=Z),ce.end.row==J.row&&(ce.end.column+=Z),ce.start.row+=K,ce.end.row+=K,ce}))}return U},P.prototype.indentRows=function(N,A,_){_=_.replace(/\t/g,this.getTabString());for(var I=N;I<=A;I++)this.doc.insertInLine({row:I,column:0},_)},P.prototype.outdentRows=function(N){for(var A=N.collapseRows(),_=new f(0,0,0,0),I=this.getTabSize(),j=A.start.row;j<=A.end.row;++j){var U=this.getLine(j);_.start.row=j,_.end.row=j;for(var K=0;K<I&&U.charAt(K)==" ";++K);K<I&&U.charAt(K)==" "?(_.start.column=K,_.end.column=K+1):(_.start.column=0,_.end.column=K),this.remove(_)}},P.prototype.$moveLines=function(N,A,_){if(N=this.getRowFoldStart(N),A=this.getRowFoldEnd(A),_<0){var I=this.getRowFoldStart(N+_);if(I<0)return 0;var j=I-N}else if(_>0){var I=this.getRowFoldEnd(A+_);if(I>this.doc.getLength()-1)return 0;var j=I-A}else{N=this.$clipRowToDocument(N),A=this.$clipRowToDocument(A);var j=A-N+1}var U=new f(N,0,A,Number.MAX_VALUE),K=this.getFoldsInRange(U).map(function(J){return J=J.clone(),J.start.row+=j,J.end.row+=j,J}),Z=_==0?this.doc.getLines(N,A):this.doc.removeFullLines(N,A);return this.doc.insertFullLines(N+j,Z),K.length&&this.addFolds(K),j},P.prototype.moveLinesUp=function(N,A){return this.$moveLines(N,A,-1)},P.prototype.moveLinesDown=function(N,A){return this.$moveLines(N,A,1)},P.prototype.duplicateLines=function(N,A){return this.$moveLines(N,A,0)},P.prototype.$clipRowToDocument=function(N){return Math.max(0,Math.min(N,this.doc.getLength()-1))},P.prototype.$clipColumnToRow=function(N,A){return A<0?0:Math.min(this.doc.getLine(N).length,A)},P.prototype.$clipPositionToDocument=function(N,A){if(A=Math.max(0,A),N<0)N=0,A=0;else{var _=this.doc.getLength();N>=_?(N=_-1,A=this.doc.getLine(_-1).length):A=Math.min(this.doc.getLine(N).length,A)}return{row:N,column:A}},P.prototype.$clipRangeToDocument=function(N){N.start.row<0?(N.start.row=0,N.start.column=0):N.start.column=this.$clipColumnToRow(N.start.row,N.start.column);var A=this.doc.getLength()-1;return N.end.row>A?(N.end.row=A,N.end.column=this.doc.getLine(A).length):N.end.column=this.$clipColumnToRow(N.end.row,N.end.column),N},P.prototype.setUseWrapMode=function(N){if(N!=this.$useWrapMode){if(this.$useWrapMode=N,this.$modified=!0,this.$resetRowCache(0),N){var A=this.getLength();this.$wrapData=Array(A),this.$updateWrapData(0,A-1)}this._signal("changeWrapMode")}},P.prototype.getUseWrapMode=function(){return this.$useWrapMode},P.prototype.setWrapLimitRange=function(N,A){(this.$wrapLimitRange.min!==N||this.$wrapLimitRange.max!==A)&&(this.$wrapLimitRange={min:N,max:A},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},P.prototype.adjustWrapLimit=function(N,A){var _=this.$wrapLimitRange;_.max<0&&(_={min:A,max:A});var I=this.$constrainWrapLimit(N,_.min,_.max);return I!=this.$wrapLimit&&I>1?(this.$wrapLimit=I,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1},P.prototype.$constrainWrapLimit=function(N,A,_){return A&&(N=Math.max(A,N)),_&&(N=Math.min(_,N)),N},P.prototype.getWrapLimit=function(){return this.$wrapLimit},P.prototype.setWrapLimit=function(N){this.setWrapLimitRange(N,N)},P.prototype.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},P.prototype.$updateInternalDataOnChange=function(N){var A=this.$useWrapMode,_=N.action,I=N.start,j=N.end,U=I.row,K=j.row,Z=K-U,J=null;if(this.$updating=!0,Z!=0)if(_==="remove"){this[A?"$wrapData":"$rowLengthCache"].splice(U,Z);var ae=this.$foldData;J=this.getFoldsInRange(N),this.removeFolds(J);var ne=this.getFoldLine(j.row),se=0;if(ne){ne.addRemoveChars(j.row,j.column,I.column-j.column),ne.shiftRow(-Z);var ce=this.getFoldLine(U);ce&&ce!==ne&&(ce.merge(ne),ne=ce),se=ae.indexOf(ne)+1}for(se;se<ae.length;se++){var ne=ae[se];ne.start.row>=j.row&&ne.shiftRow(-Z)}K=U}else{var he=Array(Z);he.unshift(U,0);var ge=A?this.$wrapData:this.$rowLengthCache;ge.splice.apply(ge,he);var ae=this.$foldData,ne=this.getFoldLine(U),se=0;if(ne){var Ee=ne.range.compareInside(I.row,I.column);Ee==0?(ne=ne.split(I.row,I.column),ne&&(ne.shiftRow(Z),ne.addRemoveChars(K,0,j.column-I.column))):Ee==-1&&(ne.addRemoveChars(U,0,j.column-I.column),ne.shiftRow(Z)),se=ae.indexOf(ne)+1}for(se;se<ae.length;se++){var ne=ae[se];ne.start.row>=U&&ne.shiftRow(Z)}}else{Z=Math.abs(N.start.column-N.end.column),_==="remove"&&(J=this.getFoldsInRange(N),this.removeFolds(J),Z=-Z);var ne=this.getFoldLine(U);ne&&ne.addRemoveChars(U,I.column,Z)}return A&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,A?this.$updateWrapData(U,K):this.$updateRowLengthCache(U,K),J},P.prototype.$updateRowLengthCache=function(N,A){this.$rowLengthCache[N]=null,this.$rowLengthCache[A]=null},P.prototype.$updateWrapData=function(N,A){var _=this.doc.getAllLines(),I=this.getTabSize(),j=this.$wrapData,U=this.$wrapLimit,K,Z,J=N;for(A=Math.min(A,_.length-1);J<=A;)Z=this.getFoldLine(J,Z),Z?(K=[],Z.walk((function(ae,ne,se,ce){var he;if(ae!=null){he=this.$getDisplayTokens(ae,K.length),he[0]=S;for(var ge=1;ge<he.length;ge++)he[ge]=k}else he=this.$getDisplayTokens(_[ne].substring(ce,se),K.length);K=K.concat(he)}).bind(this),Z.end.row,_[Z.end.row].length+1),j[Z.start.row]=this.$computeWrapSplits(K,U,I),J=Z.end.row+1):(K=this.$getDisplayTokens(_[J]),j[J]=this.$computeWrapSplits(K,U,I),J++)},P.prototype.$computeWrapSplits=function(N,A,_){if(N.length==0)return[];var I=[],j=N.length,U=0,K=0,Z=this.$wrapAsCode,J=this.$indentedSoftWrap,ae=A<=Math.max(2*_,8)||J===!1?0:Math.floor(A/2);function ne(){var Ee=0;if(ae===0)return Ee;if(J)for(var Te=0;Te<N.length;Te++){var Me=N[Te];if(Me==D)Ee+=1;else if(Me==L)Ee+=_;else{if(Me==O)continue;break}}return Z&&J!==!1&&(Ee+=_),Math.min(Ee,ae)}function se(Ee){for(var Te=Ee-U,Me=U;Me<Ee;Me++){var Xe=N[Me];(Xe===12||Xe===2)&&(Te-=1)}I.length||(ce=ne(),I.indent=ce),K+=Te,I.push(K),U=Ee}for(var ce=0;j-U>A-ce;){var he=U+A-ce;if(N[he-1]>=D&&N[he]>=D){se(he);continue}if(N[he]==S||N[he]==k){for(he;he!=U-1&&N[he]!=S;he--);if(he>U){se(he);continue}for(he=U+A,he;he<N.length&&N[he]==k;he++);if(he==N.length)break;se(he);continue}for(var ge=Math.max(he-(A-(A>>2)),U-1);he>ge&&N[he]<S;)he--;if(Z){for(;he>ge&&N[he]<S;)he--;for(;he>ge&&N[he]==T;)he--}else for(;he>ge&&N[he]<D;)he--;if(he>ge){se(++he);continue}he=U+A,N[he]==$&&he--,se(he-ce)}return I},P.prototype.$getDisplayTokens=function(N,A){var _=[],I;A=A||0;for(var j=0;j<N.length;j++){var U=N.charCodeAt(j);if(U==9){I=this.getScreenTabSize(_.length+A),_.push(L);for(var K=1;K<I;K++)_.push(O)}else U==32?_.push(D):U>39&&U<48||U>57&&U<64?_.push(T):U>=4352&&z(U)?_.push(M,$):_.push(M)}return _},P.prototype.$getStringScreenWidth=function(N,A,_){if(A==0)return[0,0];A==null&&(A=1/0),_=_||0;var I,j;for(j=0;j<N.length&&(I=N.charCodeAt(j),I==9?_+=this.getScreenTabSize(_):I>=4352&&z(I)?_+=2:_+=1,!(_>A));j++);return[_,j]},P.prototype.getRowLength=function(N){var A=1;return this.lineWidgets&&(A+=this.lineWidgets[N]&&this.lineWidgets[N].rowCount||0),!this.$useWrapMode||!this.$wrapData[N]?A:this.$wrapData[N].length+A},P.prototype.getRowLineCount=function(N){return!this.$useWrapMode||!this.$wrapData[N]?1:this.$wrapData[N].length+1},P.prototype.getRowWrapIndent=function(N){if(this.$useWrapMode){var A=this.screenToDocumentPosition(N,Number.MAX_VALUE),_=this.$wrapData[A.row];return _.length&&_[0]<A.column?_.indent:0}else return 0},P.prototype.getScreenLastRowColumn=function(N){var A=this.screenToDocumentPosition(N,Number.MAX_VALUE);return this.documentToScreenColumn(A.row,A.column)},P.prototype.getDocumentLastRowColumn=function(N,A){var _=this.documentToScreenRow(N,A);return this.getScreenLastRowColumn(_)},P.prototype.getDocumentLastRowColumnPosition=function(N,A){var _=this.documentToScreenRow(N,A);return this.screenToDocumentPosition(_,Number.MAX_VALUE/10)},P.prototype.getRowSplitData=function(N){if(this.$useWrapMode)return this.$wrapData[N]},P.prototype.getScreenTabSize=function(N){return this.$tabSize-(N%this.$tabSize|0)},P.prototype.screenToDocumentRow=function(N,A){return this.screenToDocumentPosition(N,A).row},P.prototype.screenToDocumentColumn=function(N,A){return this.screenToDocumentPosition(N,A).column},P.prototype.screenToDocumentPosition=function(N,A,_){if(N<0)return{row:0,column:0};var I,se=0,j=0,U,ne=0,K=0,Z=this.$screenRowCache,J=this.$getRowCacheIndex(Z,N),ae=Z.length;if(ae&&J>=0)var ne=Z[J],se=this.$docRowCache[J],ce=N>Z[ae-1];else var ce=!ae;for(var he=this.getLength()-1,ge=this.getNextFoldLine(se),Ee=ge?ge.start.row:1/0;ne<=N&&(K=this.getRowLength(se),!(ne+K>N||se>=he));)ne+=K,se++,se>Ee&&(se=ge.end.row+1,ge=this.getNextFoldLine(se,ge),Ee=ge?ge.start.row:1/0),ce&&(this.$docRowCache.push(se),this.$screenRowCache.push(ne));if(ge&&ge.start.row<=se)I=this.getFoldDisplayLine(ge),se=ge.start.row;else{if(ne+K<=N||se>he)return{row:he,column:this.getLine(he).length};I=this.getLine(se),ge=null}var Te=0,Me=Math.floor(N-ne);if(this.$useWrapMode){var Xe=this.$wrapData[se];Xe&&(U=Xe[Me],Me>0&&Xe.length&&(Te=Xe.indent,j=Xe[Me-1]||Xe[Xe.length-1],I=I.substring(j)))}return _!==void 0&&this.$bidiHandler.isBidiRow(ne+Me,se,Me)&&(A=this.$bidiHandler.offsetToCol(_)),j+=this.$getStringScreenWidth(I,A-Te)[1],this.$useWrapMode&&j>=U&&(j=U-1),ge?ge.idxToPosition(j):{row:se,column:j}},P.prototype.documentToScreenPosition=function(N,A){if(typeof A>"u")var _=this.$clipPositionToDocument(N.row,N.column);else _=this.$clipPositionToDocument(N,A);N=_.row,A=_.column;var ne=0,I=null,j=null;j=this.getFoldAt(N,A,1),j&&(N=j.start.row,A=j.start.column);var U,ae=0,K=this.$docRowCache,Z=this.$getRowCacheIndex(K,N),J=K.length;if(J&&Z>=0)var ae=K[Z],ne=this.$screenRowCache[Z],se=N>K[J-1];else var se=!J;for(var ce=this.getNextFoldLine(ae),he=ce?ce.start.row:1/0;ae<N;){if(ae>=he){if(U=ce.end.row+1,U>N)break;ce=this.getNextFoldLine(U,ce),he=ce?ce.start.row:1/0}else U=ae+1;ne+=this.getRowLength(ae),ae=U,se&&(this.$docRowCache.push(ae),this.$screenRowCache.push(ne))}var ge="";ce&&ae>=he?(ge=this.getFoldDisplayLine(ce,N,A),I=ce.start.row):(ge=this.getLine(N).substring(0,A),I=N);var Ee=0;if(this.$useWrapMode){var Te=this.$wrapData[I];if(Te){for(var Me=0;ge.length>=Te[Me];)ne++,Me++;ge=ge.substring(Te[Me-1]||0,ge.length),Ee=Me>0?Te.indent:0}}return this.lineWidgets&&this.lineWidgets[ae]&&this.lineWidgets[ae].rowsAbove&&(ne+=this.lineWidgets[ae].rowsAbove),{row:ne,column:Ee+this.$getStringScreenWidth(ge)[0]}},P.prototype.documentToScreenColumn=function(N,A){return this.documentToScreenPosition(N,A).column},P.prototype.documentToScreenRow=function(N,A){return this.documentToScreenPosition(N,A).row},P.prototype.getScreenLength=function(){var N=0,A=null;if(this.$useWrapMode)for(var _=this.$wrapData.length,I=0,j=0,A=this.$foldData[j++],U=A?A.start.row:1/0;I<_;){var K=this.$wrapData[I];N+=K?K.length+1:1,I++,I>U&&(I=A.end.row+1,A=this.$foldData[j++],U=A?A.start.row:1/0)}else{N=this.getLength();for(var Z=this.$foldData,j=0;j<Z.length;j++)A=Z[j],N-=A.end.row-A.start.row}return this.lineWidgets&&(N+=this.$getWidgetScreenLength()),N},P.prototype.$setFontMetrics=function(N){this.$enableVarChar&&(this.$getStringScreenWidth=function(A,_,I){if(_===0)return[0,0];_||(_=1/0),I=I||0;var j,U;for(U=0;U<A.length&&(j=A.charAt(U),j===" "?I+=this.getScreenTabSize(I):I+=N.getCharacterWidth(j),!(I>_));U++);return[I,U]})},P.prototype.getPrecedingCharacter=function(){var N=this.selection.getCursor();if(N.column===0)return N.row===0?"":this.doc.getNewLineCharacter();var A=this.getLine(N.row);return A[N.column-1]},P.prototype.destroy=function(){this.destroyed||(this.bgTokenizer.setDocument(null),this.bgTokenizer.cleanup(),this.destroyed=!0),this.endOperation(),this.$stopWorker(),this.removeAllListeners(),this.doc&&this.doc.off("change",this.$onChange),this.selection&&(this.selection.off("changeCursor",this.$onSelectionChange),this.selection.off("changeSelection",this.$onSelectionChange)),this.selection.detach()},P}();x.$uid=0,x.prototype.$modes=p.$modes,x.prototype.getValue=x.prototype.toString,x.prototype.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},x.prototype.$overwrite=!1,x.prototype.$mode=null,x.prototype.$modeId=null,x.prototype.$scrollTop=0,x.prototype.$scrollLeft=0,x.prototype.$wrapLimit=80,x.prototype.$useWrapMode=!1,x.prototype.$wrapLimitRange={min:null,max:null},x.prototype.lineWidgets=null,x.prototype.isFullWidth=z,d.implement(x.prototype,g);var M=1,$=2,S=3,k=4,T=9,D=10,L=11,O=12;function z(P){return P<4352?!1:P>=4352&&P<=4447||P>=4515&&P<=4519||P>=4602&&P<=4607||P>=9001&&P<=9002||P>=11904&&P<=11929||P>=11931&&P<=12019||P>=12032&&P<=12245||P>=12272&&P<=12283||P>=12288&&P<=12350||P>=12353&&P<=12438||P>=12441&&P<=12543||P>=12549&&P<=12589||P>=12593&&P<=12686||P>=12688&&P<=12730||P>=12736&&P<=12771||P>=12784&&P<=12830||P>=12832&&P<=12871||P>=12880&&P<=13054||P>=13056&&P<=19903||P>=19968&&P<=42124||P>=42128&&P<=42182||P>=43360&&P<=43388||P>=44032&&P<=55203||P>=55216&&P<=55238||P>=55243&&P<=55291||P>=63744&&P<=64255||P>=65040&&P<=65049||P>=65072&&P<=65106||P>=65108&&P<=65126||P>=65128&&P<=65131||P>=65281&&P<=65376||P>=65504&&P<=65510}t("./edit_session/folding").Folding.call(x.prototype),t("./edit_session/bracket_match").BracketMatch.call(x.prototype),p.defineOptions(x.prototype,"session",{wrap:{set:function(P){if(!P||P=="off"?P=!1:P=="free"?P=!0:P=="printMargin"?P=-1:typeof P=="string"&&(P=parseInt(P,10)||!1),this.$wrap!=P)if(this.$wrap=P,!P)this.setUseWrapMode(!1);else{var N=typeof P=="number"?P:null;this.setWrapLimitRange(N,N),this.setUseWrapMode(!0)}},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(P){P=P=="auto"?this.$mode.type!="text":P!="text",P!=this.$wrapAsCode&&(this.$wrapAsCode=P,this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0)))},initialValue:"auto"},indentedSoftWrap:{set:function(){this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0))},initialValue:!0},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(P){this.$useWorker=P,this.$stopWorker(),P&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(P){P=parseInt(P),P>0&&this.$tabSize!==P&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=P,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(P){this.setFoldStyle(P)},handlesSet:!0},overwrite:{set:function(P){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(P){this.doc.setNewLineMode(P)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(P){this.setMode(P)},get:function(){return this.$modeId},handlesSet:!0}}),r.EditSession=x}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(t,r,l){var d=t("./lib/lang"),h=t("./lib/oop"),b=t("./range").Range,p=function(){function f(){this.$options={}}return f.prototype.set=function(u){return h.mixin(this.$options,u),this},f.prototype.getOptions=function(){return d.copyObject(this.$options)},f.prototype.setOptions=function(u){this.$options=u},f.prototype.find=function(u){var i=this.$options,a=this.$matchIterator(u,i);if(!a)return!1;var m=null;return a.forEach(function(w,x,M,$){return m=new b(w,x,M,$),x==$&&i.start&&i.start.start&&i.skipCurrent!=!1&&m.isEqual(i.start)?(m=null,!1):!0}),m},f.prototype.findAll=function(u){var i=this.$options;if(!i.needle)return[];this.$assembleRegExp(i);var a=i.range,m=a?u.getLines(a.start.row,a.end.row):u.doc.getAllLines(),w=[],x=i.re;if(i.$isMultiLine){var M=x.length,$=m.length-M,S;e:for(var k=x.offset||0;k<=$;k++){for(var T=0;T<M;T++)if(m[k+T].search(x[T])==-1)continue e;var D=m[k],L=m[k+M-1],O=D.length-D.match(x[0])[0].length,z=L.match(x[M-1])[0].length;S&&S.end.row===k&&S.end.column>O||(w.push(S=new b(k,O,k+M-1,z)),M>2&&(k=k+M-2))}}else for(var P,N=0;N<m.length;N++)if(this.$isMultilineSearch(i)){var A=m.length-1;if(P=this.$multiLineForward(u,x,N,A),P){var _=P.endRow<=A?P.endRow-1:A;_>N&&(N=_),w.push(new b(P.startRow,P.startCol,P.endRow,P.endCol))}}else{P=d.getMatchOffsets(m[N],x);for(var T=0;T<P.length;T++){var I=P[T];w.push(new b(N,I.offset,N,I.offset+I.length))}}if(a){for(var j=a.start.column,U=a.end.column,N=0,T=w.length-1;N<T&&w[N].start.column<j&&w[N].start.row==0;)N++;for(var K=a.end.row-a.start.row;N<T&&w[T].end.column>U&&w[T].end.row==K;)T--;for(w=w.slice(N,T+1),N=0,T=w.length;N<T;N++)w[N].start.row+=a.start.row,w[N].end.row+=a.start.row}return w},f.prototype.parseReplaceString=function(u){for(var i={DollarSign:36,Ampersand:38,Digit0:48,Digit1:49,Digit9:57,Backslash:92,n:110,t:116},a="",m=0,w=u.length;m<w;m++){var x=u.charCodeAt(m);if(x===i.Backslash){if(m++,m>=w){a+="\\";break}var M=u.charCodeAt(m);switch(M){case i.Backslash:a+="\\";break;case i.n:a+=`
|
|
205
|
+
`;break;case i.t:a+=" ";break}continue}if(x===i.DollarSign){if(m++,m>=w){a+="$";break}var $=u.charCodeAt(m);if($===i.DollarSign){a+="$$";continue}if($===i.Digit0||$===i.Ampersand){a+="$&";continue}if(i.Digit1<=$&&$<=i.Digit9){a+="$"+u[m];continue}}a+=u[m]}return a||u},f.prototype.replace=function(u,i){var a=this.$options,m=this.$assembleRegExp(a);if(a.$isMultiLine)return i;if(m){var w=this.$isMultilineSearch(a);w&&(u=u.replace(/\r\n|\r|\n/g,`
|
|
206
|
+
`));var x=m.exec(u);if(!x||!w&&x[0].length!=u.length)return null;if(i=a.regExp?this.parseReplaceString(i):i.replace(/\$/g,"$$$$"),i=u.replace(m,i),a.preserveCase){i=i.split("");for(var M=Math.min(u.length,u.length);M--;){var $=u[M];$&&$.toLowerCase()!=$?i[M]=i[M].toUpperCase():i[M]=i[M].toLowerCase()}i=i.join("")}return i}},f.prototype.$assembleRegExp=function(u,i){if(u.needle instanceof RegExp)return u.re=u.needle;var a=u.needle;if(!u.needle)return u.re=!1;u.regExp||(a=d.escapeRegExp(a));var m=u.caseSensitive?"gm":"gmi";try{new RegExp(a,"u"),u.$supportsUnicodeFlag=!0,m+="u"}catch{u.$supportsUnicodeFlag=!1}if(u.wholeWord&&(a=g(a,u)),u.$isMultiLine=!i&&/[\n\r]/.test(a),u.$isMultiLine)return u.re=this.$assembleMultilineRegExp(a,m);try{var w=new RegExp(a,m)}catch{w=!1}return u.re=w},f.prototype.$assembleMultilineRegExp=function(u,i){for(var a=u.replace(/\r\n|\r|\n/g,`$
|
|
207
|
+
^`).split(`
|
|
208
|
+
`),m=[],w=0;w<a.length;w++)try{m.push(new RegExp(a[w],i))}catch{return!1}return m},f.prototype.$isMultilineSearch=function(u){return u.re&&/\\r\\n|\\r|\\n/.test(u.re.source)&&u.regExp&&!u.$isMultiLine},f.prototype.$multiLineForward=function(u,i,a,m){for(var w,x=c(u,a),M=a;M<=m;){for(var $=0;$<x&&!(M>m);$++){var S=u.getLine(M++);w=w==null?S:w+`
|
|
209
|
+
`+S}var k=i.exec(w);if(i.lastIndex=0,k){var T=w.slice(0,k.index).split(`
|
|
210
|
+
`),D=k[0].split(`
|
|
211
|
+
`),L=a+T.length-1,O=T[T.length-1].length,z=L+D.length-1,P=D.length==1?O+D[0].length:D[D.length-1].length;return{startRow:L,startCol:O,endRow:z,endCol:P}}}return null},f.prototype.$multiLineBackward=function(u,i,a,m,w){for(var x,M=c(u,m),$=u.getLine(m).length-a,S=m;S>=w;){for(var k=0;k<M&&S>=w;k++){var T=u.getLine(S--);x=x==null?T:T+`
|
|
212
|
+
`+x}var D=o(x,i,$);if(D){var L=x.slice(0,D.index).split(`
|
|
213
|
+
`),O=D[0].split(`
|
|
214
|
+
`),z=S+L.length,P=L[L.length-1].length,N=z+O.length-1,A=O.length==1?P+O[0].length:O[O.length-1].length;return{startRow:z,startCol:P,endRow:N,endCol:A}}}return null},f.prototype.$matchIterator=function(u,i){var a=this.$assembleRegExp(i);if(!a)return!1;var m=this.$isMultilineSearch(i),w=this.$multiLineForward,x=this.$multiLineBackward,M=i.backwards==!0,$=i.skipCurrent!=!1,S=a.unicode,k=i.range,T=i.start;T||(T=k?k[M?"end":"start"]:u.selection.getRange()),T.start&&(T=T[$!=M?"end":"start"]);var D=k?k.start.row:0,L=k?k.end.row:u.getLength()-1;if(M)var O=function(N){var A=T.row;if(!P(A,T.column,N)){for(A--;A>=D;A--)if(P(A,Number.MAX_VALUE,N))return;if(i.wrap!=!1){for(A=L,D=T.row;A>=D;A--)if(P(A,Number.MAX_VALUE,N))return}}};else var O=function(N){var A=T.row;if(!P(A,T.column,N)){for(A=A+1;A<=L;A++)if(P(A,0,N))return;if(i.wrap!=!1){for(A=D,L=T.row;A<=L;A++)if(P(A,0,N))return}}};if(i.$isMultiLine)var z=a.length,P=function(N,A,_){var I=M?N-z+1:N;if(!(I<0||I+z>u.getLength())){var j=u.getLine(I),U=j.search(a[0]);if(!(!M&&U<A||U===-1)){for(var K=1;K<z;K++)if(j=u.getLine(I+K),j.search(a[K])==-1)return;var Z=j.match(a[z-1])[0].length;if(!(M&&Z>A)&&_(I,U,I+z-1,Z))return!0}}};else if(M)var P=function(N,A,_){if(m){var I=x(u,a,A,N,D);if(!I)return!1;if(_(I.startRow,I.startCol,I.endRow,I.endCol))return!0}else{var j=u.getLine(N),U=[],K,Z=0;for(a.lastIndex=0;K=a.exec(j);){var J=K[0].length;if(Z=K.index,!J){if(Z>=j.length)break;a.lastIndex=Z+=d.skipEmptyMatch(j,Z,S)}if(K.index+J>A)break;U.push(K.index,J)}for(var ae=U.length-1;ae>=0;ae-=2){var ne=U[ae-1],J=U[ae];if(_(N,ne,N,ne+J))return!0}}};else var P=function(N,A,_){if(a.lastIndex=A,m){var I=w(u,a,N,L);if(I){var j=I.endRow<=L?I.endRow-1:L;j>N&&(N=j)}if(!I)return!1;if(_(I.startRow,I.startCol,I.endRow,I.endCol))return!0}else for(var U=u.getLine(N),K,Z;Z=a.exec(U);){var J=Z[0].length;if(K=Z.index,_(N,K,N,K+J))return!0;if(!J&&(a.lastIndex=K+=d.skipEmptyMatch(U,K,S),K>=U.length))return!1}};return{forEach:O}},f}();function g(f,u){var i=d.supportsLookbehind();function a(M,$){$===void 0&&($=!0);var S=i&&u.$supportsUnicodeFlag?new RegExp("[\\p{L}\\p{N}_]","u"):new RegExp("\\w");return S.test(M)||u.regExp?i&&u.$supportsUnicodeFlag?$?"(?<=^|[^\\p{L}\\p{N}_])":"(?=[^\\p{L}\\p{N}_]|$)":"\\b":""}var m=Array.from(f),w=m[0],x=m[m.length-1];return a(w)+f+a(x,!1)}function o(f,u,i){for(var a=null,m=0;m<=f.length;){u.lastIndex=m;var w=u.exec(f);if(!w)break;var x=w.index+w[0].length;if(x>f.length-i)break;(!a||x>a.index+a[0].length)&&(a=w),m=w.index+1}return a}function c(f,u){var i=5e3,a={row:u,column:0},m=f.doc.positionToIndex(a),w=m+i,x=f.doc.indexToPosition(w),M=x.row;return M+1}r.Search=p}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(t,r,l){var d=this&&this.__extends||function(){var f=function(u,i){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,m){a.__proto__=m}||function(a,m){for(var w in m)Object.prototype.hasOwnProperty.call(m,w)&&(a[w]=m[w])},f(u,i)};return function(u,i){if(typeof i!="function"&&i!==null)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");f(u,i);function a(){this.constructor=u}u.prototype=i===null?Object.create(i):(a.prototype=i.prototype,new a)}}(),h=t("../lib/keys"),b=t("../lib/useragent"),p=h.KEY_MODS,g=function(){function f(u,i){this.$init(u,i,!1)}return f.prototype.$init=function(u,i,a){this.platform=i||(b.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(u),this.$singleCommand=a},f.prototype.addCommand=function(u){this.commands[u.name]&&this.removeCommand(u),this.commands[u.name]=u,u.bindKey&&this._buildKeyHash(u)},f.prototype.removeCommand=function(u,i){var a=u&&(typeof u=="string"?u:u.name);u=this.commands[a],i||delete this.commands[a];var m=this.commandKeyBinding;for(var w in m){var x=m[w];if(x==u)delete m[w];else if(Array.isArray(x)){var M=x.indexOf(u);M!=-1&&(x.splice(M,1),x.length==1&&(m[w]=x[0]))}}},f.prototype.bindKey=function(u,i,a){if(typeof u=="object"&&u&&(a==null&&(a=u.position),u=u[this.platform]),!!u){if(typeof i=="function")return this.addCommand({exec:i,bindKey:u,name:i.name||u});u.split("|").forEach(function(m){var w="";if(m.indexOf(" ")!=-1){var x=m.split(/\s+/);m=x.pop(),x.forEach(function(S){var k=this.parseKeys(S),T=p[k.hashId]+k.key;w+=(w?" ":"")+T,this._addCommandToBinding(w,"chainKeys")},this),w+=" "}var M=this.parseKeys(m),$=p[M.hashId]+M.key;this._addCommandToBinding(w+$,i,a)},this)}},f.prototype._addCommandToBinding=function(u,i,a){var m=this.commandKeyBinding,w;if(!i)delete m[u];else if(!m[u]||this.$singleCommand)m[u]=i;else{Array.isArray(m[u])?(w=m[u].indexOf(i))!=-1&&m[u].splice(w,1):m[u]=[m[u]],typeof a!="number"&&(a=o(i));var x=m[u];for(w=0;w<x.length;w++){var M=x[w],$=o(M);if($>a)break}x.splice(w,0,i)}},f.prototype.addCommands=function(u){u&&Object.keys(u).forEach(function(i){var a=u[i];if(a){if(typeof a=="string")return this.bindKey(a,i);typeof a=="function"&&(a={exec:a}),typeof a=="object"&&(a.name||(a.name=i),this.addCommand(a))}},this)},f.prototype.removeCommands=function(u){Object.keys(u).forEach(function(i){this.removeCommand(u[i])},this)},f.prototype.bindKeys=function(u){Object.keys(u).forEach(function(i){this.bindKey(i,u[i])},this)},f.prototype._buildKeyHash=function(u){this.bindKey(u.bindKey,u)},f.prototype.parseKeys=function(u){var i=u.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function($){return $}),a=i.pop(),m=h[a];if(h.FUNCTION_KEYS[m])a=h.FUNCTION_KEYS[m].toLowerCase();else if(i.length){if(i.length==1&&i[0]=="shift")return{key:a.toUpperCase(),hashId:-1}}else return{key:a,hashId:-1};for(var w=0,x=i.length;x--;){var M=h.KEY_MODS[i[x]];if(M==null)return typeof console<"u"&&console.error("invalid modifier "+i[x]+" in "+u),!1;w|=M}return{key:a,hashId:w}},f.prototype.findKeyCommand=function(u,i){var a=p[u]+i;return this.commandKeyBinding[a]},f.prototype.handleKeyboard=function(u,i,a,m){if(!(m<0)){var w=p[i]+a,x=this.commandKeyBinding[w];return u.$keyChain&&(u.$keyChain+=" "+w,x=this.commandKeyBinding[u.$keyChain]||x),x&&(x=="chainKeys"||x[x.length-1]=="chainKeys")?(u.$keyChain=u.$keyChain||w,{command:"null"}):(u.$keyChain&&((!i||i==4)&&a.length==1?u.$keyChain=u.$keyChain.slice(0,-w.length-1):(i==-1||m>0)&&(u.$keyChain="")),{command:x})}},f.prototype.getStatusText=function(u,i){return i.$keyChain||""},f}();function o(f){return typeof f=="object"&&f.bindKey&&f.bindKey.position||(f.isDefault?-100:0)}var c=function(f){d(u,f);function u(i,a){var m=f.call(this,i,a)||this;return m.$singleCommand=!0,m}return u}(g);c.call=function(f,u,i){g.prototype.$init.call(f,u,i,!0)},g.call=function(f,u,i){g.prototype.$init.call(f,u,i,!1)},r.HashHandler=c,r.MultiHashHandler=g}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(t,r,l){var d=this&&this.__extends||function(){var o=function(c,f){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,i){u.__proto__=i}||function(u,i){for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(u[a]=i[a])},o(c,f)};return function(c,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");o(c,f);function u(){this.constructor=c}c.prototype=f===null?Object.create(f):(u.prototype=f.prototype,new u)}}(),h=t("../lib/oop"),b=t("../keyboard/hash_handler").MultiHashHandler,p=t("../lib/event_emitter").EventEmitter,g=function(o){d(c,o);function c(f,u){var i=o.call(this,u,f)||this;return i.byName=i.commands,i.setDefaultHandler("exec",function(a){return a.args?a.command.exec(a.editor,a.args,a.event,!1):a.command.exec(a.editor,{},a.event,!0)}),i}return c.prototype.exec=function(f,u,i){if(Array.isArray(f)){for(var a=f.length;a--;)if(this.exec(f[a],u,i))return!0;return!1}typeof f=="string"&&(f=this.commands[f]);var m={editor:u,command:f,args:i};return this.canExecute(f,u)?(m.returnValue=this._emit("exec",m),this._signal("afterExec",m),m.returnValue!==!1):(this._signal("commandUnavailable",m),!1)},c.prototype.canExecute=function(f,u){return typeof f=="string"&&(f=this.commands[f]),!(!f||u&&u.$readOnly&&!f.readOnly||this.$checkCommandState!=!1&&f.isAvailable&&!f.isAvailable(u))},c.prototype.toggleRecording=function(f){if(!this.$inReplay)return f&&f._emit("changeStatus"),this.recording?(this.macro.pop(),this.off("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=!1):(this.$addCommandToMacro||(this.$addCommandToMacro=(function(u){this.macro.push([u.command,u.args])}).bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},c.prototype.replay=function(f){if(!(this.$inReplay||!this.macro)){if(this.recording)return this.toggleRecording(f);try{this.$inReplay=!0,this.macro.forEach(function(u){typeof u=="string"?this.exec(u,f):this.exec(u[0],f,u[1])},this)}finally{this.$inReplay=!1}}},c.prototype.trimMacro=function(f){return f.map(function(u){return typeof u[0]!="string"&&(u[0]=u[0].name),u[1]||(u=u[0]),u})},c}(b);h.implement(g.prototype,p),r.CommandManager=g}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(t,r,l){var d=t("../lib/lang"),h=t("../config"),b=t("../range").Range;function p(o,c){return{win:o,mac:c}}r.commands=[{name:"showSettingsMenu",description:"Show settings menu",bindKey:p("Ctrl-,","Command-,"),exec:function(o){h.loadModule("ace/ext/settings_menu",function(c){c.init(o),o.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",description:"Go to next error",bindKey:p("Alt-E","F4"),exec:function(o){h.loadModule("ace/ext/error_marker",function(c){c.showErrorMarker(o,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",description:"Go to previous error",bindKey:p("Alt-Shift-E","Shift-F4"),exec:function(o){h.loadModule("ace/ext/error_marker",function(c){c.showErrorMarker(o,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:p("Ctrl-A","Command-A"),exec:function(o){o.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:p(null,"Ctrl-L"),exec:function(o){o.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:p("Ctrl-L","Command-L"),exec:function(o,c){typeof c=="number"&&!isNaN(c)&&o.gotoLine(c),o.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:p("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(o){o.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:p("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(o){o.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",description:"Toggle fold widget",bindKey:p("F2","F2"),exec:function(o){o.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",description:"Toggle parent fold widget",bindKey:p("Alt-F2","Alt-F2"),exec:function(o){o.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:p(null,"Ctrl-Command-Option-0"),exec:function(o){o.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:p(null,"Ctrl-Command-Option-0"),exec:function(o){o.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:p("Alt-0","Command-Option-0"),exec:function(o){o.session.foldAll(),o.session.unfold(o.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:p("Alt-Shift-0","Command-Option-Shift-0"),exec:function(o){o.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:p("Ctrl-K","Command-G"),exec:function(o){o.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:p("Ctrl-Shift-K","Command-Shift-G"),exec:function(o){o.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:p("Alt-K","Ctrl-G"),exec:function(o){o.selection.isEmpty()?o.selection.selectWord():o.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:p("Alt-Shift-K","Ctrl-Shift-G"),exec:function(o){o.selection.isEmpty()?o.selection.selectWord():o.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:p("Ctrl-F","Command-F"),exec:function(o){h.loadModule("ace/ext/searchbox",function(c){c.Search(o)})},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(o){o.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:p("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(o){o.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",description:"Go to start",bindKey:p("Ctrl-Home","Command-Home|Command-Up"),exec:function(o){o.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",description:"Select up",bindKey:p("Shift-Up","Shift-Up|Ctrl-Shift-P"),exec:function(o){o.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:p("Up","Up|Ctrl-P"),exec:function(o,c){o.navigateUp(c.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",description:"Select to end",bindKey:p("Ctrl-Shift-End","Command-Shift-End|Command-Shift-Down"),exec:function(o){o.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",description:"Go to end",bindKey:p("Ctrl-End","Command-End|Command-Down"),exec:function(o){o.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",description:"Select down",bindKey:p("Shift-Down","Shift-Down|Ctrl-Shift-N"),exec:function(o){o.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:p("Down","Down|Ctrl-N"),exec:function(o,c){o.navigateDown(c.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:p("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(o){o.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:p("Ctrl-Left","Option-Left"),exec:function(o){o.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:p("Alt-Shift-Left","Command-Shift-Left|Ctrl-Shift-A"),exec:function(o){o.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",description:"Go to line start",bindKey:p("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(o){o.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:p("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(o){o.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:p("Left","Left|Ctrl-B"),exec:function(o,c){o.navigateLeft(c.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:p("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(o){o.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:p("Ctrl-Right","Option-Right"),exec:function(o){o.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:p("Alt-Shift-Right","Command-Shift-Right|Shift-End|Ctrl-Shift-E"),exec:function(o){o.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",description:"Go to line end",bindKey:p("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(o){o.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:p("Shift-Right","Shift-Right"),exec:function(o){o.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:p("Right","Right|Ctrl-F"),exec:function(o,c){o.navigateRight(c.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(o){o.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:p(null,"Option-PageDown"),exec:function(o){o.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:p("PageDown","PageDown|Ctrl-V"),exec:function(o){o.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(o){o.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:p(null,"Option-PageUp"),exec:function(o){o.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(o){o.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:p("Ctrl-Up",null),exec:function(o){o.renderer.scrollBy(0,-2*o.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:p("Ctrl-Down",null),exec:function(o){o.renderer.scrollBy(0,2*o.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(o){o.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(o){o.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:p("Ctrl-Alt-E","Command-Option-E"),exec:function(o){o.commands.toggleRecording(o)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:p("Ctrl-Shift-E","Command-Shift-E"),exec:function(o){o.commands.replay(o)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:p("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(o){o.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:p("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(o){o.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:p("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(o){o.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",description:"Pass keys to browser",bindKey:p(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",description:"Copy",exec:function(o){},readOnly:!0},{name:"cut",description:"Cut",exec:function(o){var c=o.$copyWithEmptySelection&&o.selection.isEmpty(),f=c?o.selection.getLineRange():o.selection.getRange();o._emit("cut",f),f.isEmpty()||o.session.remove(f),o.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(o,c){o.$handlePaste(c)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:p("Ctrl-D","Command-D"),exec:function(o){o.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:p("Ctrl-Shift-D","Command-Shift-D"),exec:function(o){o.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:p("Ctrl-Alt-S","Command-Alt-S"),exec:function(o){o.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:p("Ctrl-/","Command-/"),exec:function(o){o.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:p("Ctrl-Shift-/","Command-Shift-/"),exec:function(o){o.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:p("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(o){o.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:p("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(o){o.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:p("Ctrl-H","Command-Option-F"),exec:function(o){h.loadModule("ace/ext/searchbox",function(c){c.Search(o,!0)})}},{name:"undo",description:"Undo",bindKey:p("Ctrl-Z","Command-Z"),exec:function(o){o.undo()}},{name:"redo",description:"Redo",bindKey:p("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(o){o.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:p("Alt-Shift-Up","Command-Option-Up"),exec:function(o){o.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:p("Alt-Up","Option-Up"),exec:function(o){o.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:p("Alt-Shift-Down","Command-Option-Down"),exec:function(o){o.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:p("Alt-Down","Option-Down"),exec:function(o){o.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:p("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(o){o.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:p("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(o){o.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:p("Shift-Delete",null),exec:function(o){if(o.selection.isEmpty())o.remove("left");else return!1},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:p("Alt-Backspace","Command-Backspace"),exec:function(o){o.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:p("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(o){o.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:p("Ctrl-Shift-Backspace",null),exec:function(o){var c=o.selection.getRange();c.start.column=0,o.session.remove(c)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:p("Ctrl-Shift-Delete",null),exec:function(o){var c=o.selection.getRange();c.end.column=Number.MAX_VALUE,o.session.remove(c)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:p("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(o){o.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:p("Ctrl-Delete","Alt-Delete"),exec:function(o){o.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:p("Shift-Tab","Shift-Tab"),exec:function(o){o.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:p("Tab","Tab"),exec:function(o){o.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:p("Ctrl-[","Ctrl-["),exec:function(o){o.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:p("Ctrl-]","Ctrl-]"),exec:function(o){o.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(o,c){o.insert(c)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(o,c){o.insert(d.stringRepeat(c.text||"",c.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:p(null,"Ctrl-O"),exec:function(o){o.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:p("Alt-Shift-X","Ctrl-T"),exec:function(o){o.transposeLetters()},multiSelectAction:function(o){o.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:p("Ctrl-U","Ctrl-U"),exec:function(o){o.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:p("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(o){o.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:p(null,null),exec:function(o){o.autoIndent()},scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:p("Ctrl-Shift-L","Command-Shift-L"),exec:function(o){var c=o.selection.getRange();c.start.column=c.end.column=0,c.end.row++,o.selection.setRange(c,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"openlink",bindKey:p("Ctrl+F3","F3"),exec:function(o){o.openLink()}},{name:"joinlines",description:"Join lines",bindKey:p(null,null),exec:function(o){for(var c=o.selection.isBackwards(),f=c?o.selection.getSelectionLead():o.selection.getSelectionAnchor(),u=c?o.selection.getSelectionAnchor():o.selection.getSelectionLead(),i=o.session.doc.getLine(f.row).length,a=o.session.doc.getTextRange(o.selection.getRange()),m=a.replace(/\n\s*/," ").length,w=o.session.doc.getLine(f.row),x=f.row+1;x<=u.row+1;x++){var M=d.stringTrimLeft(d.stringTrimRight(o.session.doc.getLine(x)));M.length!==0&&(M=" "+M),w+=M}u.row+1<o.session.doc.getLength()-1&&(w+=o.session.doc.getNewLineCharacter()),o.clearSelection(),o.session.doc.replace(new b(f.row,0,u.row+2,0),w),m>0?(o.selection.moveCursorTo(f.row,f.column),o.selection.selectTo(f.row,f.column+m)):(i=o.session.doc.getLine(f.row).length>i?i+1:i,o.selection.moveCursorTo(f.row,i))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:p(null,null),exec:function(o){var c=o.session.doc.getLength()-1,f=o.session.doc.getLine(c).length,u=o.selection.rangeList.ranges,i=[];u.length<1&&(u=[o.selection.getRange()]);for(var a=0;a<u.length;a++)a==u.length-1&&(u[a].end.row===c&&u[a].end.column===f||i.push(new b(u[a].end.row,u[a].end.column,c,f))),a===0?u[a].start.row===0&&u[a].start.column===0||i.push(new b(0,0,u[a].start.row,u[a].start.column)):i.push(new b(u[a-1].end.row,u[a-1].end.column,u[a].start.row,u[a].start.column));o.exitMultiSelectMode(),o.clearSelection();for(var a=0;a<i.length;a++)o.selection.addRange(i[a],!1)},readOnly:!0,scrollIntoView:"none"},{name:"addLineAfter",description:"Add new line after the current line",exec:function(o){o.selection.clearSelection(),o.navigateLineEnd(),o.insert(`
|
|
215
|
+
`)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"addLineBefore",description:"Add new line before the current line",exec:function(o){o.selection.clearSelection();var c=o.getCursorPosition();o.selection.moveTo(c.row-1,Number.MAX_VALUE),o.insert(`
|
|
216
|
+
`),c.row===0&&o.navigateUp()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"openCommandPallete",exec:function(o){console.warn("This is an obsolete command. Please use `openCommandPalette` instead."),o.prompt({$type:"commands"})},readOnly:!0},{name:"openCommandPalette",description:"Open command palette",bindKey:p("F1","F1"),exec:function(o){o.prompt({$type:"commands"})},readOnly:!0},{name:"modeSelect",description:"Change language mode...",bindKey:p(null,null),exec:function(o){o.prompt({$type:"modes"})},readOnly:!0}];for(var g=1;g<9;g++)r.commands.push({name:"foldToLevel"+g,description:"Fold To Level "+g,level:g,exec:function(o){o.session.foldToLevel(this.level)},scrollIntoView:"center",readOnly:!0})}),ace.define("ace/keyboard/gutter_handler",["require","exports","module","ace/lib/keys"],function(t,r,l){var d=t("../lib/keys"),h=function(){function p(g){this.editor=g,this.gutterLayer=g.renderer.$gutterLayer,this.element=g.renderer.$gutter,this.lines=g.renderer.$gutterLayer.$lines,this.activeRowIndex=null,this.activeLane=null,this.annotationTooltip=this.editor.$mouseHandler.$tooltip}return p.prototype.addListener=function(){this.element.addEventListener("keydown",this.$onGutterKeyDown.bind(this)),this.element.addEventListener("focusout",this.$blurGutter.bind(this)),this.editor.on("mousewheel",this.$blurGutter.bind(this))},p.prototype.removeListener=function(){this.element.removeEventListener("keydown",this.$onGutterKeyDown.bind(this)),this.element.removeEventListener("focusout",this.$blurGutter.bind(this)),this.editor.off("mousewheel",this.$blurGutter.bind(this))},p.prototype.$onGutterKeyDown=function(g){if(this.annotationTooltip.isOpen){g.preventDefault(),g.keyCode===d.escape&&this.annotationTooltip.hide();return}if(g.target===this.element){if(g.keyCode!=d.enter)return;g.preventDefault();var o=this.editor.getCursorPosition().row;this.editor.isRowVisible(o)||this.editor.scrollToLine(o,!0,!0),setTimeout((function(){var c=this.$rowToRowIndex(this.gutterLayer.$cursorCell.row),f=this.$findNearestFoldLaneWidget(c),u=this.$findNearestAnnotation(c);if(!(f===null&&u===null)){var i=this.$findClosestNumber(f,u,c);if(i===f)if(this.activeLane="fold",this.activeRowIndex=f,this.$isCustomWidgetVisible(f)){this.$focusCustomWidget(this.activeRowIndex);return}else{this.$focusFoldWidget(this.activeRowIndex);return}else{this.activeRowIndex=u,this.activeLane="annotation",this.$focusAnnotation(this.activeRowIndex);return}}}).bind(this),10);return}this.$handleGutterKeyboardInteraction(g),setTimeout((function(){this.editor._signal("gutterkeydown",new b(g,this))}).bind(this),10)},p.prototype.$handleGutterKeyboardInteraction=function(g){if(g.keyCode===d.tab){g.preventDefault();return}if(g.keyCode===d.escape){g.preventDefault(),this.$blurGutter(),this.element.focus(),this.lane=null;return}if(g.keyCode===d.up){switch(g.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetUp();break;case"annotation":this.$moveAnnotationUp();break}return}if(g.keyCode===d.down){switch(g.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetDown();break;case"annotation":this.$moveAnnotationDown();break}return}if(g.keyCode===d.left){g.preventDefault(),this.$switchLane("annotation");return}if(g.keyCode===d.right){g.preventDefault(),this.$switchLane("fold");return}if(g.keyCode===d.enter||g.keyCode===d.space){switch(g.preventDefault(),this.activeLane){case"fold":var o=this.$rowIndexToRow(this.activeRowIndex),c=this.editor.session.$gutterCustomWidgets[o];if(c)c.callbacks&&c.callbacks.onClick&&c.callbacks.onClick(g,o);else if(this.gutterLayer.session.foldWidgets[o]==="start"){this.editor.session.onFoldWidgetClick(this.$rowIndexToRow(this.activeRowIndex),g),setTimeout((function(){this.$rowIndexToRow(this.activeRowIndex)!==o&&(this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=this.$rowToRowIndex(o),this.$focusFoldWidget(this.activeRowIndex))}).bind(this),10);break}else if(this.gutterLayer.session.foldWidgets[this.$rowIndexToRow(this.activeRowIndex)]==="end")break;return;case"annotation":this.annotationTooltip.showTooltip(this.$rowIndexToRow(this.activeRowIndex)),this.annotationTooltip.$fromKeyboard=!0;break}return}},p.prototype.$blurGutter=function(){if(this.activeRowIndex!==null)switch(this.activeLane){case"fold":this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex);break;case"annotation":this.$blurAnnotation(this.activeRowIndex);break}this.annotationTooltip.isOpen&&this.annotationTooltip.hide()},p.prototype.$isFoldWidgetVisible=function(g){var o=this.editor.isRowFullyVisible(this.$rowIndexToRow(g)),c=this.$getFoldWidget(g).style.display!=="none";return o&&c},p.prototype.$isCustomWidgetVisible=function(g){var o=this.editor.isRowFullyVisible(this.$rowIndexToRow(g)),c=!!this.$getCustomWidget(g);return o&&c},p.prototype.$isAnnotationVisible=function(g){var o=this.editor.isRowFullyVisible(this.$rowIndexToRow(g)),c=this.$getAnnotation(g).style.display!=="none";return o&&c},p.prototype.$getFoldWidget=function(g){var o=this.lines.get(g),c=o.element;return c.childNodes[1]},p.prototype.$getCustomWidget=function(g){var o=this.lines.get(g),c=o.element;return c.childNodes[3]},p.prototype.$getAnnotation=function(g){var o=this.lines.get(g),c=o.element;return c.childNodes[2]},p.prototype.$findNearestFoldLaneWidget=function(g){if(this.$isCustomWidgetVisible(g)||this.$isFoldWidgetVisible(g))return g;for(var o=0;g-o>0||g+o<this.lines.getLength()-1;){if(o++,g-o>=0&&this.$isCustomWidgetVisible(g-o))return g-o;if(g+o<=this.lines.getLength()-1&&this.$isCustomWidgetVisible(g+o))return g+o;if(g-o>=0&&this.$isFoldWidgetVisible(g-o))return g-o;if(g+o<=this.lines.getLength()-1&&this.$isFoldWidgetVisible(g+o))return g+o}return null},p.prototype.$findNearestAnnotation=function(g){if(this.$isAnnotationVisible(g))return g;for(var o=0;g-o>0||g+o<this.lines.getLength()-1;){if(o++,g-o>=0&&this.$isAnnotationVisible(g-o))return g-o;if(g+o<=this.lines.getLength()-1&&this.$isAnnotationVisible(g+o))return g+o}return null},p.prototype.$focusFoldWidget=function(g){if(g!=null){var o=this.$getFoldWidget(g);o.classList.add(this.editor.renderer.keyboardFocusClassName),o.focus()}},p.prototype.$focusCustomWidget=function(g){if(g!=null){var o=this.$getCustomWidget(g);o&&(o.classList.add(this.editor.renderer.keyboardFocusClassName),o.focus())}},p.prototype.$focusAnnotation=function(g){if(g!=null){var o=this.$getAnnotation(g);o.classList.add(this.editor.renderer.keyboardFocusClassName),o.focus()}},p.prototype.$blurFoldWidget=function(g){var o=this.$getFoldWidget(g);o.classList.remove(this.editor.renderer.keyboardFocusClassName),o.blur()},p.prototype.$blurCustomWidget=function(g){var o=this.$getCustomWidget(g);o&&(o.classList.remove(this.editor.renderer.keyboardFocusClassName),o.blur())},p.prototype.$blurAnnotation=function(g){var o=this.$getAnnotation(g);o.classList.remove(this.editor.renderer.keyboardFocusClassName),o.blur()},p.prototype.$moveFoldWidgetUp=function(){for(var g=this.activeRowIndex;g>0;)if(g--,this.$isFoldWidgetVisible(g)||this.$isCustomWidgetVisible(g)){this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex),this.activeRowIndex=g,this.$isFoldWidgetVisible(g)?this.$focusFoldWidget(this.activeRowIndex):this.$focusCustomWidget(this.activeRowIndex);return}},p.prototype.$moveFoldWidgetDown=function(){for(var g=this.activeRowIndex;g<this.lines.getLength()-1;)if(g++,this.$isFoldWidgetVisible(g)||this.$isCustomWidgetVisible(g)){this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex),this.activeRowIndex=g,this.$isFoldWidgetVisible(g)?this.$focusFoldWidget(this.activeRowIndex):this.$focusCustomWidget(this.activeRowIndex);return}},p.prototype.$moveAnnotationUp=function(){for(var g=this.activeRowIndex;g>0;)if(g--,this.$isAnnotationVisible(g)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=g,this.$focusAnnotation(this.activeRowIndex);return}},p.prototype.$moveAnnotationDown=function(){for(var g=this.activeRowIndex;g<this.lines.getLength()-1;)if(g++,this.$isAnnotationVisible(g)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=g,this.$focusAnnotation(this.activeRowIndex);return}},p.prototype.$findClosestNumber=function(g,o,c){return g===null?o:o===null||Math.abs(c-g)<=Math.abs(c-o)?g:o},p.prototype.$switchLane=function(g){switch(g){case"annotation":if(this.activeLane==="annotation")break;var o=this.$findNearestAnnotation(this.activeRowIndex);if(o==null)break;this.activeLane="annotation",this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex),this.activeRowIndex=o,this.$focusAnnotation(this.activeRowIndex);break;case"fold":if(this.activeLane==="fold")break;var c=this.$findNearestFoldLaneWidget(this.activeRowIndex);if(c===null)break;this.activeLane="fold",this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=c,this.$isCustomWidgetVisible(c)?this.$focusCustomWidget(this.activeRowIndex):this.$focusFoldWidget(this.activeRowIndex);break}},p.prototype.$rowIndexToRow=function(g){var o=this.lines.get(g);return o?o.row:null},p.prototype.$rowToRowIndex=function(g){for(var o=0;o<this.lines.getLength();o++){var c=this.lines.get(o);if(c.row==g)return o}return null},p}();r.GutterKeyboardHandler=h;var b=function(){function p(g,o){this.gutterKeyboardHandler=o,this.domEvent=g}return p.prototype.getKey=function(){return d.keyCodeToString(this.domEvent.keyCode)},p.prototype.getRow=function(){return this.gutterKeyboardHandler.$rowIndexToRow(this.gutterKeyboardHandler.activeRowIndex)},p.prototype.isInAnnotationLane=function(){return this.gutterKeyboardHandler.activeLane==="annotation"},p.prototype.isInFoldLane=function(){return this.gutterKeyboardHandler.activeLane==="fold"},p}();r.GutterKeyboardEvent=b}),ace.define("ace/editor",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/keyboard/textinput","ace/mouse/mouse_handler","ace/mouse/fold_handler","ace/keyboard/keybinding","ace/edit_session","ace/search","ace/range","ace/lib/event_emitter","ace/commands/command_manager","ace/commands/default_commands","ace/config","ace/token_iterator","ace/keyboard/gutter_handler","ace/config","ace/clipboard","ace/lib/keys","ace/lib/event","ace/tooltip"],function(t,r,l){var d=this&&this.__values||function(A){var _=typeof Symbol=="function"&&Symbol.iterator,I=_&&A[_],j=0;if(I)return I.call(A);if(A&&typeof A.length=="number")return{next:function(){return A&&j>=A.length&&(A=void 0),{value:A&&A[j++],done:!A}}};throw new TypeError(_?"Object is not iterable.":"Symbol.iterator is not defined.")},h=t("./lib/oop"),b=t("./lib/dom"),p=t("./lib/lang"),g=t("./lib/useragent"),o=t("./keyboard/textinput").TextInput,c=t("./mouse/mouse_handler").MouseHandler,f=t("./mouse/fold_handler").FoldHandler,u=t("./keyboard/keybinding").KeyBinding,i=t("./edit_session").EditSession,a=t("./search").Search,m=t("./range").Range,w=t("./lib/event_emitter").EventEmitter,x=t("./commands/command_manager").CommandManager,M=t("./commands/default_commands").commands,$=t("./config"),S=t("./token_iterator").TokenIterator,k=t("./keyboard/gutter_handler").GutterKeyboardHandler,T=t("./config").nls,D=t("./clipboard"),L=t("./lib/keys"),O=t("./lib/event"),z=t("./tooltip").HoverTooltip,P=function(){function A(_,I,j){this.id="editor"+ ++A.$uid,this.session,this.$toDestroy=[];var U=_.getContainerElement();this.container=U,this.renderer=_,this.commands=new x(g.isMac?"mac":"win",M),typeof document=="object"&&(this.textInput=new o(_.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new c(this),new f(this)),this.keyBinding=new u(this),this.$search=new a().set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=p.delayedCall((function(){this._signal("input",{}),this.session&&!this.session.destroyed&&this.session.bgTokenizer.scheduleStart()}).bind(this)),this.on("change",function(K,Z){Z._$emitInputEvent.schedule(31)}),this.setSession(I||j&&j.session||new i("")),$.resetOptions(this),j&&this.setOptions(j),$._signal("editor",this)}return A.prototype.$initOperationListeners=function(){this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0)},A.prototype.startOperation=function(_){this.session.startOperation(_)},A.prototype.endOperation=function(_){this.session.endOperation(_)},A.prototype.onStartOperation=function(_){this.curOp=this.session.curOp,this.curOp.scrollTop=this.renderer.scrollTop,this.prevOp=this.session.prevOp,_||(this.previousCommand=null)},A.prototype.onEndOperation=function(_){if(this.curOp&&this.session){if(_&&_.returnValue===!1){this.curOp=null;return}if(this._signal("beforeEndOperation"),!this.curOp)return;var I=this.curOp.command,j=I&&I.scrollIntoView;if(j){switch(j){case"center-animate":j="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var U=this.selection.getRange(),K=this.renderer.layerConfig;(U.start.row>=K.lastRow||U.end.row<=K.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break}j=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.$lastSel=this.session.selection.toJSON(),this.prevOp=this.curOp,this.curOp=null}},A.prototype.$historyTracker=function(_){if(this.$mergeUndoDeltas){var I=this.prevOp,j=this.$mergeableCommands,U=I.command&&_.command.name==I.command.name;if(_.command.name=="insertstring"){var K=_.args;this.mergeNextCommand===void 0&&(this.mergeNextCommand=!0),U=U&&this.mergeNextCommand&&(!/\s/.test(K)||/\s/.test(I.args)),this.mergeNextCommand=!0}else U=U&&j.indexOf(_.command.name)!==-1;this.$mergeUndoDeltas!="always"&&Date.now()-this.sequenceStartTime>2e3&&(U=!1),U?this.session.mergeUndoDeltas=!0:j.indexOf(_.command.name)!==-1&&(this.sequenceStartTime=Date.now())}},A.prototype.setKeyboardHandler=function(_,I){if(_&&typeof _=="string"&&_!="ace"){this.$keybindingId=_;var j=this;$.loadModule(["keybinding",_],function(U){j.$keybindingId==_&&j.keyBinding.setKeyboardHandler(U&&U.handler),I&&I()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(_),I&&I()},A.prototype.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},A.prototype.setSession=function(_){if(this.session!=_){this.curOp&&this.endOperation(),this.curOp={};var I=this.session;if(I){this.session.off("change",this.$onDocumentChange),this.session.off("changeMode",this.$onChangeMode),this.session.off("tokenizerUpdate",this.$onTokenizerUpdate),this.session.off("changeTabSize",this.$onChangeTabSize),this.session.off("changeWrapLimit",this.$onChangeWrapLimit),this.session.off("changeWrapMode",this.$onChangeWrapMode),this.session.off("changeFold",this.$onChangeFold),this.session.off("changeFrontMarker",this.$onChangeFrontMarker),this.session.off("changeBackMarker",this.$onChangeBackMarker),this.session.off("changeBreakpoint",this.$onChangeBreakpoint),this.session.off("changeAnnotation",this.$onChangeAnnotation),this.session.off("changeOverwrite",this.$onCursorChange),this.session.off("changeScrollTop",this.$onScrollTopChange),this.session.off("changeScrollLeft",this.$onScrollLeftChange),this.session.off("startOperation",this.$onStartOperation),this.session.off("endOperation",this.$onEndOperation);var j=this.session.getSelection();j.off("changeCursor",this.$onCursorChange),j.off("changeSelection",this.$onSelectionChange)}this.session=_,_?(this.$onDocumentChange=this.onDocumentChange.bind(this),_.on("change",this.$onDocumentChange),this.renderer.setSession(_),this.$onChangeMode=this.onChangeMode.bind(this),_.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),_.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),_.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),_.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),_.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),_.on("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.on("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.on("changeBackMarker",this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.on("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.on("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.on("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.on("changeScrollTop",this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.on("changeScrollLeft",this.$onScrollLeftChange),this.selection=_.getSelection(),this.selection.on("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.$onStartOperation=this.onStartOperation.bind(this),this.session.on("startOperation",this.$onStartOperation),this.$onEndOperation=this.onEndOperation.bind(this),this.session.on("endOperation",this.$onEndOperation),this.onChangeMode(),this.onCursorChange(),this.onScrollTopChange(),this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(_)),this._signal("changeSession",{session:_,oldSession:I}),this.curOp=null,I&&I._signal("changeEditor",{oldEditor:this}),I&&(I.$editor=null),_&&_._signal("changeEditor",{editor:this}),_&&(_.$editor=this),_&&!_.destroyed&&_.bgTokenizer.scheduleStart()}},A.prototype.getSession=function(){return this.session},A.prototype.setValue=function(_,I){return this.session.doc.setValue(_),I?I==1?this.navigateFileEnd():I==-1&&this.navigateFileStart():this.selectAll(),_},A.prototype.getValue=function(){return this.session.getValue()},A.prototype.getSelection=function(){return this.selection},A.prototype.resize=function(_){this.renderer.onResize(_)},A.prototype.setTheme=function(_,I){this.renderer.setTheme(_,I)},A.prototype.getTheme=function(){return this.renderer.getTheme()},A.prototype.setStyle=function(_,I){this.renderer.setStyle(_,I)},A.prototype.unsetStyle=function(_){this.renderer.unsetStyle(_)},A.prototype.getFontSize=function(){return this.getOption("fontSize")||b.computedStyle(this.container).fontSize},A.prototype.setFontSize=function(_){this.setOption("fontSize",_)},A.prototype.$highlightBrackets=function(){if(!this.$highlightPending){var _=this;this.$highlightPending=!0,setTimeout(function(){_.$highlightPending=!1;var I=_.session;if(!(!I||I.destroyed)){I.$bracketHighlight&&(I.$bracketHighlight.markerIds.forEach(function(ce){I.removeMarker(ce)}),I.$bracketHighlight=null);var j=_.getCursorPosition(),U=_.getKeyboardHandler(),K=U&&U.$getDirectionForHighlight&&U.$getDirectionForHighlight(_),Z=I.getMatchingBracketRanges(j,K);if(!Z){var J=new S(I,j.row,j.column),ae=J.getCurrentToken();if(ae&&/\b(?:tag-open|tag-name)/.test(ae.type)){var ne=I.getMatchingTags(j);ne&&(Z=[ne.openTagName.isEmpty()?ne.openTag:ne.openTagName,ne.closeTagName.isEmpty()?ne.closeTag:ne.closeTagName])}}if(!Z&&I.$mode.getMatching&&(Z=I.$mode.getMatching(_.session)),!Z){_.getHighlightIndentGuides()&&_.renderer.$textLayer.$highlightIndentGuide();return}var se="ace_bracket";Array.isArray(Z)?Z.length==1&&(se="ace_error_bracket"):Z=[Z],Z.length==2&&(m.comparePoints(Z[0].end,Z[1].start)==0?Z=[m.fromPoints(Z[0].start,Z[1].end)]:m.comparePoints(Z[0].start,Z[1].end)==0&&(Z=[m.fromPoints(Z[1].start,Z[0].end)])),I.$bracketHighlight={ranges:Z,markerIds:Z.map(function(ce){return I.addMarker(ce,se,"text")})},_.getHighlightIndentGuides()&&_.renderer.$textLayer.$highlightIndentGuide()}},50)}},A.prototype.focus=function(){this.textInput.focus()},A.prototype.isFocused=function(){return this.textInput.isFocused()},A.prototype.blur=function(){this.textInput.blur()},A.prototype.onFocus=function(_){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",_))},A.prototype.onBlur=function(_){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",_))},A.prototype.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$updateHighlightActiveLine()},A.prototype.onDocumentChange=function(_){var I=this.session.$useWrapMode,j=_.start.row==_.end.row?_.end.row:1/0;this.renderer.updateLines(_.start.row,j,I),this._signal("change",_),this.$cursorChange()},A.prototype.onTokenizerUpdate=function(_){var I=_.data;this.renderer.updateLines(I.first,I.last)},A.prototype.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},A.prototype.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},A.prototype.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},A.prototype.$updateHighlightActiveLine=function(){var _=this.getSession(),I;if(this.$highlightActiveLine&&((this.$selectionStyle!="line"||!this.selection.isMultiLine())&&(I=this.getCursorPosition()),this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(I=!1),this.renderer.$maxLines&&this.session.getLength()===1&&!(this.renderer.$minLines>1)&&(I=!1)),_.$highlightLineMarker&&!I)_.removeMarker(_.$highlightLineMarker.id),_.$highlightLineMarker=null;else if(!_.$highlightLineMarker&&I){var j=new m(I.row,I.column,I.row,1/0);j.id=_.addMarker(j,"ace_active-line","screenLine"),_.$highlightLineMarker=j}else I&&(_.$highlightLineMarker.start.row=I.row,_.$highlightLineMarker.end.row=I.row,_.$highlightLineMarker.start.column=I.column,_._signal("changeBackMarker"))},A.prototype.onSelectionChange=function(_){var I=this.session;if(I.$selectionMarker&&I.removeMarker(I.$selectionMarker),I.$selectionMarker=null,this.selection.isEmpty())this.$updateHighlightActiveLine();else{var j=this.selection.getRange(),U=this.getSelectionStyle();I.$selectionMarker=I.addMarker(j,"ace_selection",U)}var K=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(K),this._signal("changeSelection")},A.prototype.$getSelectionHighLightRegexp=function(){var _=this.session,I=this.getSelectionRange();if(!(I.isEmpty()||I.isMultiLine())){var j=I.start.column,U=I.end.column,K=_.getLine(I.start.row),Z=K.substring(j,U);if(!(Z.length>5e3||!/[\w\d]/.test(Z))){var J=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:Z}),ae=K.substring(j-1,U+1);if(J.test(ae))return J}}},A.prototype.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},A.prototype.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},A.prototype.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},A.prototype.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},A.prototype.onChangeMode=function(_){this.renderer.updateText(),this._emit("changeMode",_)},A.prototype.onChangeWrapLimit=function(){this.renderer.updateFull()},A.prototype.onChangeWrapMode=function(){this.renderer.onResize(!0)},A.prototype.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},A.prototype.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},A.prototype.getCopyText=function(){var _=this.getSelectedText(),I=this.session.doc.getNewLineCharacter(),j=!1;if(!_&&this.$copyWithEmptySelection){j=!0;for(var U=this.selection.getAllRanges(),K=0;K<U.length;K++){var Z=U[K];K&&U[K-1].start.row==Z.start.row||(_+=this.session.getLine(Z.start.row)+I)}}var J={text:_};return this._signal("copy",J),D.lineMode=j?J.text:!1,J.text},A.prototype.onCopy=function(){this.commands.exec("copy",this)},A.prototype.onCut=function(){this.commands.exec("cut",this)},A.prototype.onPaste=function(_,I){var j={text:_,event:I};this.commands.exec("paste",this,j)},A.prototype.$handlePaste=function(_){typeof _=="string"&&(_={text:_}),this._signal("paste",_);var I=_.text,j=I===D.lineMode,U=this.session;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)j?U.insert({row:this.selection.lead.row,column:0},I):this.insert(I);else if(j)this.selection.rangeList.ranges.forEach(function(se){U.insert({row:se.start.row,column:0},I)});else{var K=I.split(/\r\n|\r|\n/),Z=this.selection.rangeList.ranges,J=K.length==2&&(!K[0]||!K[1]);if(K.length!=Z.length||J)return this.commands.exec("insertstring",this,I);for(var ae=Z.length;ae--;){var ne=Z[ae];ne.isEmpty()||U.remove(ne),U.insert(ne.start,K[ae])}}},A.prototype.execCommand=function(_,I){return this.commands.exec(_,this,I)},A.prototype.insert=function(_,I){var j=this.session,U=j.getMode(),K=this.getCursorPosition();if(this.getBehavioursEnabled()&&!I){var Z=U.transformAction(j.getState(K.row),"insertion",this,j,_);Z&&(_!==Z.text&&(this.inVirtualSelectionMode||(this.session.mergeUndoDeltas=!1,this.mergeNextCommand=!1)),_=Z.text)}if(_==" "&&(_=this.session.getTabString()),this.selection.isEmpty()){if(this.session.getOverwrite()&&_.indexOf(`
|
|
217
|
+
`)==-1){var J=m.fromPoints(K,K);J.end.column+=_.length,this.session.remove(J)}}else{var J=this.getSelectionRange();K=this.session.remove(J),this.clearSelection()}if(_==`
|
|
218
|
+
`||_==`\r
|
|
219
|
+
`){var ce=j.getLine(K.row);if(K.column>ce.search(/\S|$/)){var ae=ce.substr(K.column).search(/\S|$/);j.doc.removeInLine(K.row,K.column,K.column+ae)}}this.clearSelection();var ne=K.column,se=j.getState(K.row),ce=j.getLine(K.row),he=U.checkOutdent(se,ce,_);if(j.insert(K,_),Z&&Z.selection&&(Z.selection.length==2?this.selection.setSelectionRange(new m(K.row,ne+Z.selection[0],K.row,ne+Z.selection[1])):this.selection.setSelectionRange(new m(K.row+Z.selection[0],Z.selection[1],K.row+Z.selection[2],Z.selection[3]))),this.$enableAutoIndent){if(j.getDocument().isNewLine(_)){var ge=U.getNextLineIndent(se,ce.slice(0,K.column),j.getTabString());j.insert({row:K.row+1,column:0},ge)}he&&U.autoOutdent(se,j,K.row)}},A.prototype.autoIndent=function(){for(var _=this.session,I=_.getMode(),j=this.selection.isEmpty()?[new m(0,0,_.doc.getLength()-1,0)]:this.selection.getAllRanges(),U="",K="",Z="",J=_.getTabString(),ae=0;ae<j.length;ae++)for(var ne=j[ae].start.row,se=j[ae].end.row,ce=ne;ce<=se;ce++){ce>0&&(U=_.getState(ce-1),K=_.getLine(ce-1),Z=I.getNextLineIndent(U,K,J));var he=_.getLine(ce),ge=I.$getIndent(he);if(Z!==ge){if(ge.length>0){var Ee=new m(ce,0,ce,ge.length);_.remove(Ee)}Z.length>0&&_.insert({row:ce,column:0},Z)}I.autoOutdent(U,_,ce)}},A.prototype.onTextInput=function(_,I){if(!I)return this.keyBinding.onTextInput(_);this.startOperation({command:{name:"insertstring"}});var j=this.applyComposition.bind(this,_,I);this.selection.rangeCount?this.forEachSelection(j):j(),this.endOperation()},A.prototype.applyComposition=function(_,I){if(I.extendLeft||I.extendRight){var j=this.selection.getRange();j.start.column-=I.extendLeft,j.end.column+=I.extendRight,j.start.column<0&&(j.start.row--,j.start.column+=this.session.getLine(j.start.row).length+1),this.selection.setRange(j),!_&&!j.isEmpty()&&this.remove()}if((_||!this.selection.isEmpty())&&this.insert(_,!0),I.restoreStart||I.restoreEnd){var j=this.selection.getRange();j.start.column-=I.restoreStart,j.end.column-=I.restoreEnd,this.selection.setRange(j)}},A.prototype.onCommandKey=function(_,I,j){return this.keyBinding.onCommandKey(_,I,j)},A.prototype.setOverwrite=function(_){this.session.setOverwrite(_)},A.prototype.getOverwrite=function(){return this.session.getOverwrite()},A.prototype.toggleOverwrite=function(){this.session.toggleOverwrite()},A.prototype.setScrollSpeed=function(_){this.setOption("scrollSpeed",_)},A.prototype.getScrollSpeed=function(){return this.getOption("scrollSpeed")},A.prototype.setDragDelay=function(_){this.setOption("dragDelay",_)},A.prototype.getDragDelay=function(){return this.getOption("dragDelay")},A.prototype.setSelectionStyle=function(_){this.setOption("selectionStyle",_)},A.prototype.getSelectionStyle=function(){return this.getOption("selectionStyle")},A.prototype.setHighlightActiveLine=function(_){this.setOption("highlightActiveLine",_)},A.prototype.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},A.prototype.setHighlightGutterLine=function(_){this.setOption("highlightGutterLine",_)},A.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},A.prototype.setHighlightSelectedWord=function(_){this.setOption("highlightSelectedWord",_)},A.prototype.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},A.prototype.setAnimatedScroll=function(_){this.renderer.setAnimatedScroll(_)},A.prototype.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},A.prototype.setShowInvisibles=function(_){this.renderer.setShowInvisibles(_)},A.prototype.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},A.prototype.setDisplayIndentGuides=function(_){this.renderer.setDisplayIndentGuides(_)},A.prototype.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},A.prototype.setHighlightIndentGuides=function(_){this.renderer.setHighlightIndentGuides(_)},A.prototype.getHighlightIndentGuides=function(){return this.renderer.getHighlightIndentGuides()},A.prototype.setShowPrintMargin=function(_){this.renderer.setShowPrintMargin(_)},A.prototype.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},A.prototype.setPrintMarginColumn=function(_){this.renderer.setPrintMarginColumn(_)},A.prototype.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},A.prototype.setReadOnly=function(_){this.setOption("readOnly",_)},A.prototype.getReadOnly=function(){return this.getOption("readOnly")},A.prototype.setBehavioursEnabled=function(_){this.setOption("behavioursEnabled",_)},A.prototype.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},A.prototype.setWrapBehavioursEnabled=function(_){this.setOption("wrapBehavioursEnabled",_)},A.prototype.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},A.prototype.setShowFoldWidgets=function(_){this.setOption("showFoldWidgets",_)},A.prototype.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},A.prototype.setFadeFoldWidgets=function(_){this.setOption("fadeFoldWidgets",_)},A.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},A.prototype.remove=function(_){this.selection.isEmpty()&&(_=="left"?this.selection.selectLeft():this.selection.selectRight());var I=this.getSelectionRange();if(this.getBehavioursEnabled()){var j=this.session,U=j.getState(I.start.row),K=j.getMode().transformAction(U,"deletion",this,j,I);if(I.end.column===0){var Z=j.getTextRange(I);if(Z[Z.length-1]==`
|
|
220
|
+
`){var J=j.getLine(I.end.row);/^\s+$/.test(J)&&(I.end.column=J.length)}}K&&(I=K)}this.session.remove(I),this.clearSelection()},A.prototype.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},A.prototype.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},A.prototype.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},A.prototype.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var _=this.getSelectionRange();_.start.column==_.end.column&&_.start.row==_.end.row&&(_.end.column=0,_.end.row++),this.session.remove(_),this.clearSelection()},A.prototype.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var _=this.getCursorPosition();this.insert(`
|
|
221
|
+
`),this.moveCursorToPosition(_)},A.prototype.setGhostText=function(_,I){this.renderer.setGhostText(_,I)},A.prototype.removeGhostText=function(){this.renderer.removeGhostText()},A.prototype.transposeLetters=function(){if(this.selection.isEmpty()){var _=this.getCursorPosition(),I=_.column;if(I!==0){var j=this.session.getLine(_.row),U,K;I<j.length?(U=j.charAt(I)+j.charAt(I-1),K=new m(_.row,I-1,_.row,I+1)):(U=j.charAt(I-1)+j.charAt(I-2),K=new m(_.row,I-2,_.row,I)),this.session.replace(K,U),this.session.selection.moveToPosition(K.end)}}},A.prototype.toLowerCase=function(){var _=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var I=this.getSelectionRange(),j=this.session.getTextRange(I);this.session.replace(I,j.toLowerCase()),this.selection.setSelectionRange(_)},A.prototype.toUpperCase=function(){var _=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var I=this.getSelectionRange(),j=this.session.getTextRange(I);this.session.replace(I,j.toUpperCase()),this.selection.setSelectionRange(_)},A.prototype.indent=function(){var _=this.session,I=this.getSelectionRange();if(I.start.row<I.end.row){var j=this.$getSelectedRows();_.indentRows(j.first,j.last," ");return}else if(I.start.column<I.end.column){var U=_.getTextRange(I);if(!/^\s+$/.test(U)){var j=this.$getSelectedRows();_.indentRows(j.first,j.last," ");return}}var K=_.getLine(I.start.row),Z=I.start,J=_.getTabSize(),ae=_.documentToScreenColumn(Z.row,Z.column);if(this.session.getUseSoftTabs())var ne=J-ae%J,se=p.stringRepeat(" ",ne);else{for(var ne=ae%J;K[I.start.column-1]==" "&≠)I.start.column--,ne--;this.selection.setSelectionRange(I),se=" "}return this.insert(se)},A.prototype.blockIndent=function(){var _=this.$getSelectedRows();this.session.indentRows(_.first,_.last," ")},A.prototype.blockOutdent=function(){var _=this.session.getSelection();this.session.outdentRows(_.getRange())},A.prototype.sortLines=function(){for(var _=this.$getSelectedRows(),I=this.session,j=[],U=_.first;U<=_.last;U++)j.push(I.getLine(U));j.sort(function(J,ae){return J.toLowerCase()<ae.toLowerCase()?-1:J.toLowerCase()>ae.toLowerCase()?1:0});for(var K=new m(0,0,0,0),U=_.first;U<=_.last;U++){var Z=I.getLine(U);K.start.row=U,K.end.row=U,K.end.column=Z.length,I.replace(K,j[U-_.first])}},A.prototype.toggleCommentLines=function(){var _=this.session.getState(this.getCursorPosition().row),I=this.$getSelectedRows();this.session.getMode().toggleCommentLines(_,this.session,I.first,I.last)},A.prototype.toggleBlockComment=function(){var _=this.getCursorPosition(),I=this.session.getState(_.row),j=this.getSelectionRange();this.session.getMode().toggleBlockComment(I,this.session,j,_)},A.prototype.getNumberAt=function(_,I){var j=/[\-]?[0-9]+(?:\.[0-9]+)?/g;j.lastIndex=0;for(var U=this.session.getLine(_);j.lastIndex<I;){var K=j.exec(U);if(K.index<=I&&K.index+K[0].length>=I){var Z={value:K[0],start:K.index,end:K.index+K[0].length};return Z}}return null},A.prototype.modifyNumber=function(_){var I=this.selection.getCursor().row,j=this.selection.getCursor().column,U=new m(I,j-1,I,j),K=this.session.getTextRange(U);if(!isNaN(parseFloat(K))&&isFinite(K)){var Z=this.getNumberAt(I,j);if(Z){var J=Z.value.indexOf(".")>=0?Z.start+Z.value.indexOf(".")+1:Z.end,ae=Z.start+Z.value.length-J,ne=parseFloat(Z.value);ne*=Math.pow(10,ae),J!==Z.end&&j<J?_*=Math.pow(10,Z.end-j-1):_*=Math.pow(10,Z.end-j),ne+=_,ne/=Math.pow(10,ae);var se=ne.toFixed(ae),ce=new m(I,Z.start,I,Z.end);this.session.replace(ce,se),this.moveCursorTo(I,Math.max(Z.start+1,j+se.length-Z.value.length))}}else this.toggleWord()},A.prototype.toggleWord=function(){var _=this.selection.getCursor().row,I=this.selection.getCursor().column;this.selection.selectWord();var j=this.getSelectedText(),U=this.selection.getWordRange().start.column,K=j.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g,"$1 ").split(/\s/),Z=I-U-1;Z<0&&(Z=0);var J=0,ae=0,ne=this;j.match(/[A-Za-z0-9_]+/)&&K.forEach(function(Ke,dt){ae=J+Ke.length,Z>=J&&Z<=ae&&(j=Ke,ne.selection.clearSelection(),ne.moveCursorTo(_,J+U),ne.selection.selectTo(_,ae+U)),J=ae});for(var se=this.$toggleWordPairs,ce,he=0;he<se.length;he++)for(var ge=se[he],Ee=0;Ee<=1;Ee++){var Te=+!Ee,Me=j.match(new RegExp("^\\s?_?("+p.escapeRegExp(ge[Ee])+")\\s?$","i"));if(Me){var Xe=j.match(new RegExp("([_]|^|\\s)("+p.escapeRegExp(Me[1])+")($|\\s)","g"));Xe&&(ce=j.replace(new RegExp(p.escapeRegExp(ge[Ee]),"i"),function(Ke){var dt=ge[Te];return Ke.toUpperCase()==Ke?dt=dt.toUpperCase():Ke.charAt(0).toUpperCase()==Ke.charAt(0)&&(dt=dt.substr(0,0)+ge[Te].charAt(0).toUpperCase()+dt.substr(1)),dt}),this.insert(ce),ce="")}}},A.prototype.findLinkAt=function(_,I){var j,U,K=this.session.getLine(_),Z=K.split(/((?:https?|ftp):\/\/[\S]+)/),J=I;J<0&&(J=0);var ae=0,ne=0,se;try{for(var ce=d(Z),he=ce.next();!he.done;he=ce.next()){var ge=he.value;if(ne=ae+ge.length,J>=ae&&J<=ne&&ge.match(/((?:https?|ftp):\/\/[\S]+)/)){se=ge.replace(/[\s:.,'";}\]]+$/,"");break}ae=ne}}catch(Ee){j={error:Ee}}finally{try{he&&!he.done&&(U=ce.return)&&U.call(ce)}finally{if(j)throw j.error}}return se},A.prototype.openLink=function(){var _=this.selection.getCursor(),I=this.findLinkAt(_.row,_.column);return I&&window.open(I,"_blank"),I!=null},A.prototype.removeLines=function(){var _=this.$getSelectedRows();this.session.removeFullLines(_.first,_.last),this.clearSelection()},A.prototype.duplicateSelection=function(){var _=this.selection,I=this.session,j=_.getRange(),U=_.isBackwards();if(j.isEmpty()){var K=j.start.row;I.duplicateLines(K,K)}else{var Z=U?j.start:j.end,J=I.insert(Z,I.getTextRange(j));j.start=Z,j.end=J,_.setSelectionRange(j,U)}},A.prototype.moveLinesDown=function(){this.$moveLines(1,!1)},A.prototype.moveLinesUp=function(){this.$moveLines(-1,!1)},A.prototype.moveText=function(_,I,j){return this.session.moveText(_,I,j)},A.prototype.copyLinesUp=function(){this.$moveLines(-1,!0)},A.prototype.copyLinesDown=function(){this.$moveLines(1,!0)},A.prototype.$moveLines=function(_,I){var j,U,K=this.selection;if(!K.inMultiSelectMode||this.inVirtualSelectionMode){var Z=K.toOrientedRange();j=this.$getSelectedRows(Z),U=this.session.$moveLines(j.first,j.last,I?0:_),I&&_==-1&&(U=0),Z.moveBy(U,0),K.fromOrientedRange(Z)}else{var J=K.rangeList.ranges;K.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;for(var ae=0,ne=0,se=J.length,ce=0;ce<se;ce++){var he=ce;J[ce].moveBy(ae,0),j=this.$getSelectedRows(J[ce]);for(var ge=j.first,Ee=j.last;++ce<se;){ne&&J[ce].moveBy(ne,0);var Te=this.$getSelectedRows(J[ce]);if(I&&Te.first!=Ee||!I&&Te.first>Ee+1)break;Ee=Te.last}for(ce--,ae=this.session.$moveLines(ge,Ee,I?0:_),I&&_==-1&&(he=ce+1);he<=ce;)J[he].moveBy(ae,0),he++;I||(ae=0),ne+=ae}K.fromOrientedRange(K.ranges[0]),K.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},A.prototype.$getSelectedRows=function(_){return _=(_||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(_.start.row),last:this.session.getRowFoldEnd(_.end.row)}},A.prototype.onCompositionStart=function(_){this.renderer.showComposition(_)},A.prototype.onCompositionUpdate=function(_){this.renderer.setCompositionText(_)},A.prototype.onCompositionEnd=function(){this.renderer.hideComposition()},A.prototype.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},A.prototype.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},A.prototype.isRowVisible=function(_){return _>=this.getFirstVisibleRow()&&_<=this.getLastVisibleRow()},A.prototype.isRowFullyVisible=function(_){return _>=this.renderer.getFirstFullyVisibleRow()&&_<=this.renderer.getLastFullyVisibleRow()},A.prototype.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},A.prototype.$moveByPage=function(_,I){var j=this.renderer,U=this.renderer.layerConfig,K=_*Math.floor(U.height/U.lineHeight);I===!0?this.selection.$moveSelection(function(){this.moveCursorBy(K,0)}):I===!1&&(this.selection.moveCursorBy(K,0),this.selection.clearSelection());var Z=j.scrollTop;j.scrollBy(0,K*U.lineHeight),I!=null&&j.scrollCursorIntoView(null,.5),j.animateScrolling(Z)},A.prototype.selectPageDown=function(){this.$moveByPage(1,!0)},A.prototype.selectPageUp=function(){this.$moveByPage(-1,!0)},A.prototype.gotoPageDown=function(){this.$moveByPage(1,!1)},A.prototype.gotoPageUp=function(){this.$moveByPage(-1,!1)},A.prototype.scrollPageDown=function(){this.$moveByPage(1)},A.prototype.scrollPageUp=function(){this.$moveByPage(-1)},A.prototype.scrollToRow=function(_){this.renderer.scrollToRow(_)},A.prototype.scrollToLine=function(_,I,j,U){this.renderer.scrollToLine(_,I,j,U)},A.prototype.centerSelection=function(){var _=this.getSelectionRange(),I={row:Math.floor(_.start.row+(_.end.row-_.start.row)/2),column:Math.floor(_.start.column+(_.end.column-_.start.column)/2)};this.renderer.alignCursor(I,.5)},A.prototype.getCursorPosition=function(){return this.selection.getCursor()},A.prototype.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},A.prototype.getSelectionRange=function(){return this.selection.getRange()},A.prototype.selectAll=function(){this.selection.selectAll()},A.prototype.clearSelection=function(){this.selection.clearSelection()},A.prototype.moveCursorTo=function(_,I){this.selection.moveCursorTo(_,I)},A.prototype.moveCursorToPosition=function(_){this.selection.moveCursorToPosition(_)},A.prototype.jumpToMatching=function(_,I){var j=this.getCursorPosition(),U=new S(this.session,j.row,j.column),K=U.getCurrentToken(),Z=0;K&&K.type.indexOf("tag-name")!==-1&&(K=U.stepBackward());var J=K||U.stepForward();if(J){var ae,ne=!1,se={},ce=j.column-J.start,he,ge={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(J.value.match(/[{}()\[\]]/g)){for(;ce<J.value.length&&!ne;ce++)if(ge[J.value[ce]])switch(he=ge[J.value[ce]]+"."+J.type.replace("rparen","lparen"),isNaN(se[he])&&(se[he]=0),J.value[ce]){case"(":case"[":case"{":se[he]++;break;case")":case"]":case"}":se[he]--,se[he]===-1&&(ae="bracket",ne=!0);break}}else J.type.indexOf("tag-name")!==-1&&(isNaN(se[J.value])&&(se[J.value]=0),K.value==="<"&&Z>1?se[J.value]++:K.value==="</"&&se[J.value]--,se[J.value]===-1&&(ae="tag",ne=!0));ne||(K=J,Z++,J=U.stepForward(),ce=0)}while(J&&!ne);if(ae){var Ee,Te;if(ae==="bracket")Ee=this.session.getBracketRange(j),Ee||(Ee=new m(U.getCurrentTokenRow(),U.getCurrentTokenColumn()+ce-1,U.getCurrentTokenRow(),U.getCurrentTokenColumn()+ce-1),Te=Ee.start,(I||Te.row===j.row&&Math.abs(Te.column-j.column)<2)&&(Ee=this.session.getBracketRange(Te)));else if(ae==="tag"){if(!J||J.type.indexOf("tag-name")===-1)return;if(Ee=new m(U.getCurrentTokenRow(),U.getCurrentTokenColumn()-2,U.getCurrentTokenRow(),U.getCurrentTokenColumn()-2),Ee.compare(j.row,j.column)===0){var Me=this.session.getMatchingTags(j);Me&&(Me.openTag.contains(j.row,j.column)?(Ee=Me.closeTag,Te=Ee.start):(Ee=Me.openTag,Me.closeTag.start.row===j.row&&Me.closeTag.start.column===j.column?Te=Ee.end:Te=Ee.start))}Te=Te||Ee.start}Te=Ee&&Ee.cursor||Te,Te&&(_?Ee&&I?this.selection.setRange(Ee):Ee&&Ee.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(Te.row,Te.column):this.selection.moveTo(Te.row,Te.column))}}},A.prototype.gotoLine=function(_,I,j){this.selection.clearSelection(),this.session.unfold({row:_-1,column:I||0}),this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(_-1,I||0),this.isRowFullyVisible(_-1)||this.scrollToLine(_-1,!0,j)},A.prototype.navigateTo=function(_,I){this.selection.moveTo(_,I)},A.prototype.navigateUp=function(_){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var I=this.selection.anchor.getPosition();return this.moveCursorToPosition(I)}this.selection.clearSelection(),this.selection.moveCursorBy(-_||-1,0)},A.prototype.navigateDown=function(_){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var I=this.selection.anchor.getPosition();return this.moveCursorToPosition(I)}this.selection.clearSelection(),this.selection.moveCursorBy(_||1,0)},A.prototype.navigateLeft=function(_){if(this.selection.isEmpty())for(_=_||1;_--;)this.selection.moveCursorLeft();else{var I=this.getSelectionRange().start;this.moveCursorToPosition(I)}this.clearSelection()},A.prototype.navigateRight=function(_){if(this.selection.isEmpty())for(_=_||1;_--;)this.selection.moveCursorRight();else{var I=this.getSelectionRange().end;this.moveCursorToPosition(I)}this.clearSelection()},A.prototype.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},A.prototype.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},A.prototype.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},A.prototype.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},A.prototype.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},A.prototype.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},A.prototype.replace=function(_,I){I&&this.$search.set(I);var j=this.$search.find(this.session),U=0;return j&&(this.$tryReplace(j,_)&&(U=1),this.selection.setSelectionRange(j),this.renderer.scrollSelectionIntoView(j.start,j.end)),U},A.prototype.replaceAll=function(_,I){I&&this.$search.set(I);var j=this.$search.findAll(this.session),U=0;if(!j.length)return U;var K=this.getSelectionRange();this.selection.moveTo(0,0);for(var Z=j.length-1;Z>=0;--Z)this.$tryReplace(j[Z],_)&&U++;return this.selection.setSelectionRange(K),U},A.prototype.$tryReplace=function(_,I){var j=this.session.getTextRange(_);return I=this.$search.replace(j,I),I!==null?(_.end=this.session.replace(_,I),_):null},A.prototype.getLastSearchOptions=function(){return this.$search.getOptions()},A.prototype.find=function(_,I,j){I||(I={}),typeof _=="string"||_ instanceof RegExp?I.needle=_:typeof _=="object"&&h.mixin(I,_);var U=this.selection.getRange();I.needle==null&&(_=this.session.getTextRange(U)||this.$search.$options.needle,_||(U=this.session.getWordRange(U.start.row,U.start.column),_=this.session.getTextRange(U)),this.$search.set({needle:_})),this.$search.set(I),I.start||this.$search.set({start:U});var K=this.$search.find(this.session);if(I.preventScroll)return K;if(K)return this.revealRange(K,j),K;I.backwards?U.start=U.end:U.end=U.start,this.selection.setRange(U)},A.prototype.findNext=function(_,I){this.find({skipCurrent:!0,backwards:!1},_,I)},A.prototype.findPrevious=function(_,I){this.find(_,{skipCurrent:!0,backwards:!0},I)},A.prototype.revealRange=function(_,I){this.session.unfold(_),this.selection.setSelectionRange(_);var j=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(_.start,_.end,.5),I!==!1&&this.renderer.animateScrolling(j)},A.prototype.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},A.prototype.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},A.prototype.destroy=function(){this.destroyed=!0,this.$toDestroy&&(this.$toDestroy.forEach(function(_){_.destroy()}),this.$toDestroy=[]),this.$mouseHandler&&this.$mouseHandler.destroy(),this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy(),this._$emitInputEvent&&this._$emitInputEvent.cancel(),this.removeAllListeners()},A.prototype.setAutoScrollEditorIntoView=function(_){if(_){var I,j=this,U=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var K=this.$scrollAnchor;K.style.cssText="position:absolute",this.container.insertBefore(K,this.container.firstChild);var Z=this.on("changeSelection",function(){U=!0}),J=this.renderer.on("beforeRender",function(){U&&(I=j.renderer.container.getBoundingClientRect())}),ae=this.renderer.on("afterRender",function(){if(U&&I&&(j.isFocused()||j.searchBox&&j.searchBox.isFocused())){var ne=j.renderer,se=ne.$cursorLayer.$pixelPos,ce=ne.layerConfig,he=se.top-ce.offset;se.top>=0&&he+I.top<0?U=!0:se.top<ce.height&&se.top+I.top+ce.lineHeight>window.innerHeight?U=!1:U=null,U!=null&&(K.style.top=he+"px",K.style.left=se.left+"px",K.style.height=ce.lineHeight+"px",K.scrollIntoView(U)),U=I=null}});this.setAutoScrollEditorIntoView=function(ne){ne||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",Z),this.renderer.off("afterRender",ae),this.renderer.off("beforeRender",J))}}},A.prototype.$resetCursorStyle=function(){var _=this.$cursorStyle||"ace",I=this.renderer.$cursorLayer;I&&(I.setSmoothBlinking(/smooth/.test(_)),I.isBlinking=!this.$readOnly&&_!="wide",b.setCssClass(I.element,"ace_slim-cursors",/slim/.test(_)))},A.prototype.prompt=function(_,I,j){var U=this;$.loadModule("ace/ext/prompt",function(K){K.prompt(U,_,I,j)})},A}();P.$uid=0,P.prototype.curOp=null,P.prototype.prevOp={},P.prototype.$mergeableCommands=["backspace","del","insertstring"],P.prototype.$toggleWordPairs=[["first","last"],["true","false"],["yes","no"],["width","height"],["top","bottom"],["right","left"],["on","off"],["x","y"],["get","set"],["max","min"],["horizontal","vertical"],["show","hide"],["add","remove"],["up","down"],["before","after"],["even","odd"],["in","out"],["inside","outside"],["next","previous"],["increase","decrease"],["attach","detach"],["&&","||"],["==","!="]],h.implement(P.prototype,w),$.defineOptions(P.prototype,"editor",{selectionStyle:{set:function(A){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:A})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(A){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(A){var _=this;if(this.textInput.setReadOnly(A),!this.destroyed){this.$resetCursorStyle(),this.$readOnlyCallback||(this.$readOnlyCallback=function(j){var U=!1;if(j&&j.type=="keydown"){if(j&&j.key&&!j.ctrlKey&&!j.metaKey&&(j.key==" "&&j.preventDefault(),U=j.key.length==1),!U)return}else j&&j.type!=="exec"&&(U=!0);if(U){_.hoverTooltip||(_.hoverTooltip=new z);var K=b.createElement("div");K.textContent=T("editor.tooltip.disable-editing","Editing is disabled"),_.hoverTooltip.isOpen||_.hoverTooltip.showForRange(_,_.getSelectionRange(),K)}else _.hoverTooltip&&_.hoverTooltip.isOpen&&_.hoverTooltip.hide()});var I=this.textInput.getElement();A?(O.addListener(I,"keydown",this.$readOnlyCallback,this),this.commands.on("exec",this.$readOnlyCallback),this.commands.on("commandUnavailable",this.$readOnlyCallback)):(O.removeListener(I,"keydown",this.$readOnlyCallback),this.commands.off("exec",this.$readOnlyCallback),this.commands.off("commandUnavailable",this.$readOnlyCallback),this.hoverTooltip&&(this.hoverTooltip.destroy(),this.hoverTooltip=null))}},initialValue:!1},copyWithEmptySelection:{set:function(A){this.textInput.setCopyWithEmptySelection(A)},initialValue:!1},cursorStyle:{set:function(A){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},enableAutoIndent:{initialValue:!0},autoScrollEditorIntoView:{set:function(A){this.setAutoScrollEditorIntoView(A)}},keyboardHandler:{set:function(A){this.setKeyboardHandler(A)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(A){this.session.setValue(A)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(A){this.setSession(A)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(A){this.renderer.$gutterLayer.setShowLineNumbers(A),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),A&&this.$relativeLineNumbers?N.attach(this):N.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(A){this.$showLineNumbers&&A?N.attach(this):N.detach(this)}},placeholder:{set:function(A){this.$updatePlaceholder||(this.$updatePlaceholder=(function(){var _=this.session&&(this.renderer.$composition||this.session.getLength()>1||this.session.getLine(0).length>0);if(_&&this.renderer.placeholderNode)this.renderer.off("afterRender",this.$updatePlaceholder),b.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null;else if(!_&&!this.renderer.placeholderNode){this.renderer.on("afterRender",this.$updatePlaceholder),b.addCssClass(this.container,"ace_hasPlaceholder");var I=b.createElement("div");I.className="ace_placeholder",I.textContent=this.$placeholder||"",this.renderer.placeholderNode=I,this.renderer.content.appendChild(this.renderer.placeholderNode)}else!_&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||"")}).bind(this),this.on("input",this.$updatePlaceholder)),this.$updatePlaceholder()}},enableKeyboardAccessibility:{set:function(A){var _={name:"blurTextInput",description:"Set focus to the editor content div to allow tabbing through the page",bindKey:"Esc",exec:function(U){U.blur(),U.renderer.scroller.focus()},readOnly:!0},I=function(U){if(U.target==this.renderer.scroller&&U.keyCode===L.enter){U.preventDefault();var K=this.getCursorPosition().row;this.isRowVisible(K)||this.scrollToLine(K,!0,!0),this.focus()}},j;A?(this.renderer.enableKeyboardAccessibility=!0,this.renderer.keyboardFocusClassName="ace_keyboard-focus",this.textInput.getElement().setAttribute("tabindex",-1),this.textInput.setNumberOfExtraLines(g.isWin?3:0),this.renderer.scroller.setAttribute("tabindex",0),this.renderer.scroller.setAttribute("role","group"),this.renderer.scroller.setAttribute("aria-roledescription",T("editor.scroller.aria-roledescription","editor")),this.renderer.scroller.classList.add(this.renderer.keyboardFocusClassName),this.renderer.scroller.setAttribute("aria-label",T("editor.scroller.aria-label","Editor content, press Enter to start editing, press Escape to exit")),this.renderer.scroller.addEventListener("keyup",I.bind(this)),this.commands.addCommand(_),this.renderer.$gutter.setAttribute("tabindex",0),this.renderer.$gutter.setAttribute("aria-hidden",!1),this.renderer.$gutter.setAttribute("role","group"),this.renderer.$gutter.setAttribute("aria-roledescription",T("editor.gutter.aria-roledescription","editor gutter")),this.renderer.$gutter.setAttribute("aria-label",T("editor.gutter.aria-label","Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit")),this.renderer.$gutter.classList.add(this.renderer.keyboardFocusClassName),this.renderer.content.setAttribute("aria-hidden",!0),j||(j=new k(this)),j.addListener(),this.textInput.setAriaOptions({setLabel:!0})):(this.renderer.enableKeyboardAccessibility=!1,this.textInput.getElement().setAttribute("tabindex",0),this.textInput.setNumberOfExtraLines(0),this.renderer.scroller.setAttribute("tabindex",-1),this.renderer.scroller.removeAttribute("role"),this.renderer.scroller.removeAttribute("aria-roledescription"),this.renderer.scroller.classList.remove(this.renderer.keyboardFocusClassName),this.renderer.scroller.removeAttribute("aria-label"),this.renderer.scroller.removeEventListener("keyup",I.bind(this)),this.commands.removeCommand(_),this.renderer.content.removeAttribute("aria-hidden"),this.renderer.$gutter.setAttribute("tabindex",-1),this.renderer.$gutter.setAttribute("aria-hidden",!0),this.renderer.$gutter.removeAttribute("role"),this.renderer.$gutter.removeAttribute("aria-roledescription"),this.renderer.$gutter.removeAttribute("aria-label"),this.renderer.$gutter.classList.remove(this.renderer.keyboardFocusClassName),j&&j.removeListener())},initialValue:!1},textInputAriaLabel:{set:function(A){this.$textInputAriaLabel=A},initialValue:""},enableMobileMenu:{set:function(A){this.$enableMobileMenu=A},initialValue:!0},customScrollbar:"renderer",hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",displayIndentGuides:"renderer",highlightIndentGuides:"renderer",showGutter:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",hasCssTransforms:"renderer",maxPixelHeight:"renderer",useTextareaForIME:"renderer",useResizeObserver:"renderer",useSvgGutterIcons:"renderer",showFoldedAnnotations:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimeout:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",navigateWithinSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});var N={getText:function(A,_){return(Math.abs(A.selection.lead.row-_)||_+1+(_<9?"·":""))+""},getWidth:function(A,_,I){return Math.max(_.toString().length,(I.lastRow+1).toString().length,2)*I.characterWidth},update:function(A,_){_.renderer.$loop.schedule(_.renderer.CHANGE_GUTTER)},attach:function(A){A.renderer.$gutterLayer.$renderer=this,A.on("changeSelection",this.update),this.update(null,A)},detach:function(A){A.renderer.$gutterLayer.$renderer==this&&(A.renderer.$gutterLayer.$renderer=null),A.off("changeSelection",this.update),this.update(null,A)}};r.Editor=P}),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],function(t,r,l){var d=t("../lib/dom"),h=function(){function b(p,g){this.element=p,this.canvasHeight=g||5e5,this.element.style.height=this.canvasHeight*2+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0}return b.prototype.moveContainer=function(p){d.translate(this.element,0,-(p.firstRowScreen*p.lineHeight%this.canvasHeight)-p.offset*this.$offsetCoefficient)},b.prototype.pageChanged=function(p,g){return Math.floor(p.firstRowScreen*p.lineHeight/this.canvasHeight)!==Math.floor(g.firstRowScreen*g.lineHeight/this.canvasHeight)},b.prototype.computeLineTop=function(p,g,o){var c=g.firstRowScreen*g.lineHeight,f=Math.floor(c/this.canvasHeight),u=o.documentToScreenRow(p,0)*g.lineHeight;return u-f*this.canvasHeight},b.prototype.computeLineHeight=function(p,g,o){return g.lineHeight*o.getRowLineCount(p)},b.prototype.getLength=function(){return this.cells.length},b.prototype.get=function(p){return this.cells[p]},b.prototype.shift=function(){this.$cacheCell(this.cells.shift())},b.prototype.pop=function(){this.$cacheCell(this.cells.pop())},b.prototype.push=function(p){if(Array.isArray(p)){this.cells.push.apply(this.cells,p);for(var g=d.createFragment(this.element),o=0;o<p.length;o++)g.appendChild(p[o].element);this.element.appendChild(g)}else this.cells.push(p),this.element.appendChild(p.element)},b.prototype.unshift=function(p){if(Array.isArray(p)){this.cells.unshift.apply(this.cells,p);for(var g=d.createFragment(this.element),o=0;o<p.length;o++)g.appendChild(p[o].element);this.element.firstChild?this.element.insertBefore(g,this.element.firstChild):this.element.appendChild(g)}else this.cells.unshift(p),this.element.insertAdjacentElement("afterbegin",p.element)},b.prototype.last=function(){return this.cells.length?this.cells[this.cells.length-1]:null},b.prototype.$cacheCell=function(p){p&&(p.element.remove(),this.cellCache.push(p))},b.prototype.createCell=function(p,g,o,c){var f=this.cellCache.pop();if(!f){var u=d.createElement("div");c&&c(u),this.element.appendChild(u),f={element:u,text:"",row:p}}return f.row=p,f},b}();r.Lines=h}),ace.define("ace/layer/gutter",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/layer/lines","ace/config"],function(t,r,l){var d=t("../lib/dom"),h=t("../lib/oop"),b=t("../lib/lang"),p=t("../lib/event_emitter").EventEmitter,g=t("./lines").Lines,o=t("../config").nls,c=function(){function u(i){this.$showCursorMarker=null,this.element=d.createElement("div"),this.element.className="ace_layer ace_gutter-layer",i.appendChild(this.element),this.setShowFoldWidgets(this.$showFoldWidgets),this.gutterWidth=0,this.$annotations=[],this.$updateAnnotations=this.$updateAnnotations.bind(this),this.$lines=new g(this.element),this.$lines.$offsetCoefficient=1}return u.prototype.setSession=function(i){this.session&&this.session.off("change",this.$updateAnnotations),this.session=i,i&&i.on("change",this.$updateAnnotations)},u.prototype.addGutterDecoration=function(i,a){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(i,a)},u.prototype.removeGutterDecoration=function(i,a){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(i,a)},u.prototype.setAnnotations=function(i){this.$annotations=[];for(var a=0;a<i.length;a++){var m=i[a],w=m.row,x=this.$annotations[w];x||(x=this.$annotations[w]={text:[],type:[],displayText:[]});var M=m.text,$=m.text,S=m.type;M=M?b.escapeHTML(M):m.html||"",$=$||m.html||"",x.text.indexOf(M)===-1&&(x.text.push(M),x.type.push(S),x.displayText.push($));var k=m.className;k?x.className=k:S==="error"?x.className=" ace_error":S==="security"&&!/\bace_error\b/.test(x.className)?x.className=" ace_security":S==="warning"&&!/\bace_(error|security)\b/.test(x.className)?x.className=" ace_warning":S==="info"&&!x.className?x.className=" ace_info":S==="hint"&&!x.className&&(x.className=" ace_hint")}},u.prototype.$updateAnnotations=function(i){if(this.$annotations.length){var a=i.start.row,m=i.end.row-a;if(m!==0)if(i.action=="remove")this.$annotations.splice(a,m+1,null);else{var w=new Array(m+1);w.unshift(a,1),this.$annotations.splice.apply(this.$annotations,w)}}},u.prototype.update=function(i){this.config=i;var a=this.session,m=i.firstRow,w=Math.min(i.lastRow+i.gutterOffset,a.getLength()-1);this.oldLastRow=w,this.config=i,this.$lines.moveContainer(i),this.$updateCursorRow();for(var x=a.getNextFoldLine(m),M=x?x.start.row:1/0,$=null,S=-1,k=m;;){if(k>M&&(k=x.end.row+1,x=a.getNextFoldLine(k,x),M=x?x.start.row:1/0),k>w){for(;this.$lines.getLength()>S+1;)this.$lines.pop();break}$=this.$lines.get(++S),$?$.row=k:($=this.$lines.createCell(k,i,this.session,f),this.$lines.push($)),this.$renderCell($,i,x,k),k++}this._signal("afterRender"),this.$updateGutterWidth(i),this.$showCursorMarker&&this.$highlightGutterLine&&this.$updateCursorMarker()},u.prototype.$updateGutterWidth=function(i){var a=this.session,m=a.gutterRenderer||this.$renderer,w=a.$firstLineNumber,x=this.$lines.last()?this.$lines.last().text:"";(this.$fixedWidth||a.$useWrapMode)&&(x=a.getLength()+w-1);var M=m?m.getWidth(a,x,i):x.toString().length*i.characterWidth,$=this.$padding||this.$computePadding();M+=$.left+$.right,M!==this.gutterWidth&&!isNaN(M)&&(this.gutterWidth=M,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",M))},u.prototype.$updateCursorRow=function(){if(this.$highlightGutterLine){var i=this.session.selection.getCursor();this.$cursorRow!==i.row&&(this.$cursorRow=i.row)}},u.prototype.updateLineHighlight=function(){if(this.$showCursorMarker&&this.$updateCursorMarker(),!!this.$highlightGutterLine){var i=this.session.selection.cursor.row;if(this.$cursorRow=i,!(this.$cursorCell&&this.$cursorCell.row==i)){this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ",""));var a=this.$lines.cells;this.$cursorCell=null;for(var m=0;m<a.length;m++){var w=a[m];if(w.row>=this.$cursorRow){if(w.row>this.$cursorRow){var x=this.session.getFoldLine(this.$cursorRow);if(m>0&&x&&x.start.row==a[m-1].row)w=a[m-1];else break}w.element.className="ace_gutter-active-line "+w.element.className,this.$cursorCell=w;break}}}}},u.prototype.$updateCursorMarker=function(){if(this.session){var i=this.session;this.$highlightElement||(this.$highlightElement=d.createElement("div"),this.$highlightElement.className="ace_gutter-cursor",this.$highlightElement.style.pointerEvents="none",this.element.appendChild(this.$highlightElement));var a=i.selection.cursor,m=this.config,w=this.$lines,x=m.firstRowScreen*m.lineHeight,M=Math.floor(x/w.canvasHeight),$=i.documentToScreenRow(a)*m.lineHeight,S=$-M*w.canvasHeight;d.setStyle(this.$highlightElement.style,"height",m.lineHeight+"px"),d.setStyle(this.$highlightElement.style,"top",S+"px")}},u.prototype.scrollLines=function(i){var a=this.config;if(this.config=i,this.$updateCursorRow(),this.$lines.pageChanged(a,i))return this.update(i);this.$lines.moveContainer(i);var m=Math.min(i.lastRow+i.gutterOffset,this.session.getLength()-1),w=this.oldLastRow;if(this.oldLastRow=m,!a||w<i.firstRow)return this.update(i);if(m<a.firstRow)return this.update(i);if(a.firstRow<i.firstRow)for(var x=this.session.getFoldedRowCount(a.firstRow,i.firstRow-1);x>0;x--)this.$lines.shift();if(w>m)for(var x=this.session.getFoldedRowCount(m+1,w);x>0;x--)this.$lines.pop();i.firstRow<a.firstRow&&this.$lines.unshift(this.$renderLines(i,i.firstRow,a.firstRow-1)),m>w&&this.$lines.push(this.$renderLines(i,w+1,m)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(i)},u.prototype.$renderLines=function(i,a,m){for(var w=[],x=a,M=this.session.getNextFoldLine(x),$=M?M.start.row:1/0;x>$&&(x=M.end.row+1,M=this.session.getNextFoldLine(x,M),$=M?M.start.row:1/0),!(x>m);){var S=this.$lines.createCell(x,i,this.session,f);this.$renderCell(S,i,M,x),w.push(S),x++}return w},u.prototype.$renderCell=function(i,a,m,w){var x=i.element,M=this.session,$=x.childNodes[0],S=x.childNodes[1],k=x.childNodes[2],T=x.childNodes[3],D=k.firstChild,L=M.$firstLineNumber,O=M.$breakpoints,z=M.$decorations,P=M.gutterRenderer||this.$renderer,N=this.$showFoldWidgets&&M.foldWidgets,A=m?m.start.row:Number.MAX_VALUE,_=a.lineHeight+"px",I=this.$useSvgGutterIcons?"ace_gutter-cell_svg-icons ":"ace_gutter-cell ",j=this.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",U=(P?P.getText(M,w):w+L).toString();if(this.$highlightGutterLine&&(w==this.$cursorRow||m&&w<this.$cursorRow&&w>=A&&this.$cursorRow<=m.end.row)&&(I+="ace_gutter-active-line ",this.$cursorCell!=i&&(this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ","")),this.$cursorCell=i)),O[w]&&(I+=O[w]),z[w]&&(I+=z[w]),this.$annotations[w]&&w!==A&&(I+=this.$annotations[w].className),N){var K=N[w];K==null&&(K=N[w]=M.getFoldWidget(w))}if(K){var Z="ace_fold-widget ace_"+K,J=K=="start"&&w==A&&w<m.end.row;if(J){Z+=" ace_closed";for(var ae="",ne=!1,se=w+1;se<=m.end.row;se++)if(this.$annotations[se]){if(this.$annotations[se].className===" ace_error"){ne=!0,ae=" ace_error_fold";break}this.$annotations[se].className===" ace_security"?(ne=!0,ae=" ace_security_fold"):this.$annotations[se].className===" ace_warning"&&ae!==" ace_security_fold"&&(ne=!0,ae=" ace_warning_fold")}I+=ae}else Z+=" ace_open";S.className!=Z&&(S.className=Z),d.setStyle(S.style,"height",_),d.setStyle(S.style,"display","inline-block"),S.setAttribute("role","button"),S.setAttribute("tabindex","-1");var ce=M.getFoldWidgetRange(w);ce?S.setAttribute("aria-label",o("gutter.code-folding.range.aria-label","Toggle code folding, rows $0 through $1",[ce.start.row+1,ce.end.row+1])):m?S.setAttribute("aria-label",o("gutter.code-folding.closed.aria-label","Toggle code folding, rows $0 through $1",[m.start.row+1,m.end.row+1])):S.setAttribute("aria-label",o("gutter.code-folding.open.aria-label","Toggle code folding, row $0",[w+1])),J?(S.setAttribute("aria-expanded","false"),S.setAttribute("title",o("gutter.code-folding.closed.title","Unfold code"))):(S.setAttribute("aria-expanded","true"),S.setAttribute("title",o("gutter.code-folding.open.title","Fold code")))}else S&&(d.setStyle(S.style,"display","none"),S.setAttribute("tabindex","0"),S.removeAttribute("role"),S.removeAttribute("aria-label"));var he=this.session.$gutterCustomWidgets[w];if(he?this.$addCustomWidget(w,he,i):T&&this.$removeCustomWidget(w,i),ne&&this.$showFoldedAnnotations){k.className="ace_gutter_annotation",D.className=j,D.className+=ae,d.setStyle(D.style,"height",_),d.setStyle(k.style,"display","block"),d.setStyle(k.style,"height",_);var ge;switch(ae){case" ace_error_fold":ge=o("gutter.annotation.aria-label.error","Error, read annotations row $0",[U]);break;case" ace_security_fold":ge=o("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[U]);break;case" ace_warning_fold":ge=o("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[U]);break}k.setAttribute("aria-label",ge),k.setAttribute("tabindex","-1"),k.setAttribute("role","button")}else if(this.$annotations[w]){k.className="ace_gutter_annotation",D.className=j,this.$useSvgGutterIcons?D.className+=this.$annotations[w].className:x.classList.add(this.$annotations[w].className.replace(" ","")),d.setStyle(D.style,"height",_),d.setStyle(k.style,"display","block"),d.setStyle(k.style,"height",_);var ge;switch(this.$annotations[w].className){case" ace_error":ge=o("gutter.annotation.aria-label.error","Error, read annotations row $0",[U]);break;case" ace_security":ge=o("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[U]);break;case" ace_warning":ge=o("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[U]);break;case" ace_info":ge=o("gutter.annotation.aria-label.info","Info, read annotations row $0",[U]);break;case" ace_hint":ge=o("gutter.annotation.aria-label.hint","Suggestion, read annotations row $0",[U]);break}k.setAttribute("aria-label",ge),k.setAttribute("tabindex","-1"),k.setAttribute("role","button")}else d.setStyle(k.style,"display","none"),k.removeAttribute("aria-label"),k.removeAttribute("role"),k.setAttribute("tabindex","0");return U!==$.data&&($.data=U),x.className!=I&&(x.className=I),d.setStyle(i.element.style,"height",this.$lines.computeLineHeight(w,a,M)+"px"),d.setStyle(i.element.style,"top",this.$lines.computeLineTop(w,a,M)+"px"),i.text=U,k.style.display==="none"&&S.style.display==="none"&&!he?i.element.setAttribute("aria-hidden",!0):i.element.setAttribute("aria-hidden",!1),i},u.prototype.setHighlightGutterLine=function(i){this.$highlightGutterLine=i,!i&&this.$highlightElement&&(this.$highlightElement.remove(),this.$highlightElement=null)},u.prototype.setShowLineNumbers=function(i){this.$renderer=!i&&{getWidth:function(){return 0},getText:function(){return""}}},u.prototype.getShowLineNumbers=function(){return this.$showLineNumbers},u.prototype.setShowFoldWidgets=function(i){i?d.addCssClass(this.element,"ace_folding-enabled"):d.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=i,this.$padding=null},u.prototype.getShowFoldWidgets=function(){return this.$showFoldWidgets},u.prototype.$hideFoldWidget=function(i,a){var m=a||this.$getGutterCell(i);if(m&&m.element){var w=m.element.childNodes[1];w&&d.setStyle(w.style,"display","none")}},u.prototype.$showFoldWidget=function(i,a){var m=a||this.$getGutterCell(i);if(m&&m.element){var w=m.element.childNodes[1];w&&this.session.foldWidgets&&this.session.foldWidgets[m.row]&&d.setStyle(w.style,"display","inline-block")}},u.prototype.$getGutterCell=function(i){var a=this.$lines.cells,m=0,w=a.length-1;if(!(i<a[0].row||i>a[w].row)){for(;m<=w;){var x=Math.floor((m+w)/2),M=a[x];if(M.row>i)w=x-1;else if(M.row<i)m=x+1;else return M}return M}},u.prototype.$addCustomWidget=function(i,a,m){var w=a.className,x=a.label,M=a.title,$=a.callbacks;this.session.$gutterCustomWidgets[i]={className:w,label:x,title:M,callbacks:$},this.$hideFoldWidget(i,m);var S=m||this.$getGutterCell(i);if(S&&S.element){var k=S.element.querySelector(".ace_custom-widget");k&&k.remove(),k=d.createElement("span"),k.className="ace_custom-widget ".concat(w),k.setAttribute("tabindex","-1"),k.setAttribute("role","button"),k.setAttribute("aria-label",x),k.setAttribute("title",M),d.setStyle(k.style,"display","inline-block"),d.setStyle(k.style,"height","inherit"),$&&$.onClick&&k.addEventListener("click",function(T){$.onClick(T,i),T.stopPropagation()}),S.element.appendChild(k)}},u.prototype.$removeCustomWidget=function(i,a){delete this.session.$gutterCustomWidgets[i],this.$showFoldWidget(i,a);var m=a||this.$getGutterCell(i);if(m&&m.element){var w=m.element.querySelector(".ace_custom-widget");w&&m.element.removeChild(w)}},u.prototype.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var i=d.computedStyle(this.element.firstChild);return this.$padding={},this.$padding.left=(parseInt(i.borderLeftWidth)||0)+(parseInt(i.paddingLeft)||0)+1,this.$padding.right=(parseInt(i.borderRightWidth)||0)+(parseInt(i.paddingRight)||0),this.$padding},u.prototype.getRegion=function(i){var a=this.$padding||this.$computePadding(),m=this.element.getBoundingClientRect();if(i.x<a.left+m.left)return"markers";if(this.$showFoldWidgets&&i.x>m.right-a.right)return"foldWidgets"},u}();c.prototype.$fixedWidth=!1,c.prototype.$highlightGutterLine=!0,c.prototype.$renderer=void 0,c.prototype.$showLineNumbers=!0,c.prototype.$showFoldWidgets=!0,h.implement(c.prototype,p);function f(u){var i=document.createTextNode("");u.appendChild(i);var a=d.createElement("span");u.appendChild(a);var m=d.createElement("span");u.appendChild(m);var w=d.createElement("span");return m.appendChild(w),u}r.Gutter=c}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(t,r,l){var d=t("../range").Range,h=t("../lib/dom"),b=function(){function g(o){this.element=h.createElement("div"),this.element.className="ace_layer ace_marker-layer",o.appendChild(this.element)}return g.prototype.setPadding=function(o){this.$padding=o},g.prototype.setSession=function(o){this.session=o},g.prototype.setMarkers=function(o){this.markers=o},g.prototype.elt=function(o,c){var f=this.i!=-1&&this.element.childNodes[this.i];f?this.i++:(f=document.createElement("div"),this.element.appendChild(f),this.i=-1),f.style.cssText=c,f.className=o},g.prototype.update=function(o){if(o){this.config=o,this.i=0;var c;for(var f in this.markers){var u=this.markers[f];if(!u.range){u.update(c,this,this.session,o);continue}var i=u.range.clipRows(o.firstRow,o.lastRow);if(!i.isEmpty())if(i=i.toScreenRange(this.session),u.renderer){var a=this.$getTop(i.start.row,o),m=this.$padding+i.start.column*o.characterWidth;u.renderer(c,i,m,a,o)}else u.type=="fullLine"?this.drawFullLineMarker(c,i,u.clazz,o):u.type=="screenLine"?this.drawScreenLineMarker(c,i,u.clazz,o):i.isMultiLine()?u.type=="text"?this.drawTextMarker(c,i,u.clazz,o):this.drawMultiLineMarker(c,i,u.clazz,o):this.drawSingleLineMarker(c,i,u.clazz+" ace_start ace_br15",o)}if(this.i!=-1)for(;this.i<this.element.childElementCount;)this.element.removeChild(this.element.lastChild)}},g.prototype.$getTop=function(o,c){return(o-c.firstRowScreen)*c.lineHeight},g.prototype.drawTextMarker=function(o,c,f,u,i){for(var a=this.session,m=c.start.row,w=c.end.row,x=m,M=0,$=0,S=a.getScreenLastRowColumn(x),k=new d(x,c.start.column,x,$);x<=w;x++)k.start.row=k.end.row=x,k.start.column=x==m?c.start.column:a.getRowWrapIndent(x),k.end.column=S,M=$,$=S,S=x+1<w?a.getScreenLastRowColumn(x+1):x==w?0:c.end.column,this.drawSingleLineMarker(o,k,f+(x==m?" ace_start":"")+" ace_br"+p(x==m||x==m+1&&c.start.column,M<$,$>S,x==w),u,x==w?0:1,i)},g.prototype.drawMultiLineMarker=function(o,c,f,u,i){var a=this.$padding,m=u.lineHeight,w=this.$getTop(c.start.row,u),x=a+c.start.column*u.characterWidth;if(i=i||"",this.session.$bidiHandler.isBidiRow(c.start.row)){var M=c.clone();M.end.row=M.start.row,M.end.column=this.session.getLine(M.start.row).length,this.drawBidiSingleLineMarker(o,M,f+" ace_br1 ace_start",u,null,i)}else this.elt(f+" ace_br1 ace_start","height:"+m+"px;right:"+a+"px;top:"+w+"px;left:"+x+"px;"+(i||""));if(this.session.$bidiHandler.isBidiRow(c.end.row)){var M=c.clone();M.start.row=M.end.row,M.start.column=0,this.drawBidiSingleLineMarker(o,M,f+" ace_br12",u,null,i)}else{w=this.$getTop(c.end.row,u);var $=c.end.column*u.characterWidth;this.elt(f+" ace_br12","height:"+m+"px;width:"+$+"px;top:"+w+"px;left:"+a+"px;"+(i||""))}if(m=(c.end.row-c.start.row-1)*u.lineHeight,!(m<=0)){w=this.$getTop(c.start.row+1,u);var S=(c.start.column?1:0)|(c.end.column?0:8);this.elt(f+(S?" ace_br"+S:""),"height:"+m+"px;right:"+a+"px;top:"+w+"px;left:"+a+"px;"+(i||""))}},g.prototype.drawSingleLineMarker=function(o,c,f,u,i,a){if(this.session.$bidiHandler.isBidiRow(c.start.row))return this.drawBidiSingleLineMarker(o,c,f,u,i,a);var m=u.lineHeight,w=(c.end.column+(i||0)-c.start.column)*u.characterWidth,x=this.$getTop(c.start.row,u),M=this.$padding+c.start.column*u.characterWidth;this.elt(f,"height:"+m+"px;width:"+w+"px;top:"+x+"px;left:"+M+"px;"+(a||""))},g.prototype.drawBidiSingleLineMarker=function(o,c,f,u,i,a){var m=u.lineHeight,w=this.$getTop(c.start.row,u),x=this.$padding,M=this.session.$bidiHandler.getSelections(c.start.column,c.end.column);M.forEach(function($){this.elt(f,"height:"+m+"px;width:"+($.width+(i||0))+"px;top:"+w+"px;left:"+(x+$.left)+"px;"+(a||""))},this)},g.prototype.drawFullLineMarker=function(o,c,f,u,i){var a=this.$getTop(c.start.row,u),m=u.lineHeight;c.start.row!=c.end.row&&(m+=this.$getTop(c.end.row,u)-a),this.elt(f,"height:"+m+"px;top:"+a+"px;left:0;right:0;"+(i||""))},g.prototype.drawScreenLineMarker=function(o,c,f,u,i){var a=this.$getTop(c.start.row,u),m=u.lineHeight;this.elt(f,"height:"+m+"px;top:"+a+"px;left:0;right:0;"+(i||""))},g}();b.prototype.$padding=0;function p(g,o,c,f){return(g?1:0)|(o?2:0)|(c?4:0)|(f?8:0)}r.Marker=b}),ace.define("ace/layer/text_util",["require","exports","module"],function(t,r,l){var d=new Set(["text","rparen","lparen"]);r.isTextToken=function(h){return d.has(h)}}),ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/layer/lines","ace/lib/event_emitter","ace/config","ace/layer/text_util"],function(t,r,l){var d=t("../lib/oop"),h=t("../lib/dom"),b=t("../lib/lang"),p=t("./lines").Lines,g=t("../lib/event_emitter").EventEmitter,o=t("../config").nls,c=t("./text_util").isTextToken,f=function(){function u(i){this.dom=h,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",i.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new p(this.element)}return u.prototype.$updateEolChar=function(){var i=this.session.doc,a=i.getNewLineCharacter()==`
|
|
222
|
+
`&&i.getNewLineMode()!="windows",m=a?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=m)return this.EOL_CHAR=m,!0},u.prototype.setPadding=function(i){this.$padding=i,this.element.style.margin="0 "+i+"px"},u.prototype.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},u.prototype.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},u.prototype.$setFontMetrics=function(i){this.$fontMetrics=i,this.$fontMetrics.on("changeCharacterSize",(function(a){this._signal("changeCharacterSize",a)}).bind(this)),this.$pollSizeChanges()},u.prototype.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},u.prototype.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},u.prototype.setSession=function(i){this.session=i,i&&this.$computeTabString()},u.prototype.setShowInvisibles=function(i){return this.showInvisibles==i?!1:(this.showInvisibles=i,typeof i=="string"?(this.showSpaces=/tab/i.test(i),this.showTabs=/space/i.test(i),this.showEOL=/eol/i.test(i)):this.showSpaces=this.showTabs=this.showEOL=i,this.$computeTabString(),!0)},u.prototype.setDisplayIndentGuides=function(i){return this.displayIndentGuides==i?!1:(this.displayIndentGuides=i,this.$computeTabString(),!0)},u.prototype.setHighlightIndentGuides=function(i){return this.$highlightIndentGuides===i?!1:(this.$highlightIndentGuides=i,i)},u.prototype.$computeTabString=function(){var i=this.session.getTabSize();this.tabSize=i;for(var a=this.$tabStrings=[0],m=1;m<i+1;m++)if(this.showTabs){var w=this.dom.createElement("span");w.className="ace_invisible ace_invisible_tab",w.textContent=b.stringRepeat(this.TAB_CHAR,m),a.push(w)}else a.push(this.dom.createTextNode(b.stringRepeat(" ",m),this.element));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var x="ace_indent-guide",M=this.showSpaces?" ace_invisible ace_invisible_space":"",$=this.showSpaces?b.stringRepeat(this.SPACE_CHAR,this.tabSize):b.stringRepeat(" ",this.tabSize),S=this.showTabs?" ace_invisible ace_invisible_tab":"",k=this.showTabs?b.stringRepeat(this.TAB_CHAR,this.tabSize):$,w=this.dom.createElement("span");w.className=x+M,w.textContent=$,this.$tabStrings[" "]=w;var w=this.dom.createElement("span");w.className=x+S,w.textContent=k,this.$tabStrings[" "]=w}},u.prototype.updateLines=function(i,a,m){if(this.config.lastRow!=i.lastRow||this.config.firstRow!=i.firstRow)return this.update(i);this.config=i;for(var w=Math.max(a,i.firstRow),x=Math.min(m,i.lastRow),M=this.element.childNodes,$=0,S=i.firstRow;S<w;S++){var k=this.session.getFoldLine(S);if(k)if(k.containsRow(w)){w=k.start.row;break}else S=k.end.row;$++}for(var T=!1,S=w,k=this.session.getNextFoldLine(S),D=k?k.start.row:1/0;S>D&&(S=k.end.row+1,k=this.session.getNextFoldLine(S,k),D=k?k.start.row:1/0),!(S>x);){var L=M[$++];if(L){this.dom.removeChildren(L),this.$renderLine(L,S,S==D?k:!1),T&&(L.style.top=this.$lines.computeLineTop(S,i,this.session)+"px");var O=i.lineHeight*this.session.getRowLength(S)+"px";L.style.height!=O&&(T=!0,L.style.height=O)}S++}if(T)for(;$<this.$lines.cells.length;){var z=this.$lines.cells[$++];z.element.style.top=this.$lines.computeLineTop(z.row,i,this.session)+"px"}},u.prototype.scrollLines=function(i){var a=this.config;if(this.config=i,this.$lines.pageChanged(a,i))return this.update(i);this.$lines.moveContainer(i);var m=i.lastRow,w=a?a.lastRow:-1;if(!a||w<i.firstRow)return this.update(i);if(m<a.firstRow)return this.update(i);if(!a||a.lastRow<i.firstRow)return this.update(i);if(i.lastRow<a.firstRow)return this.update(i);if(a.firstRow<i.firstRow)for(var x=this.session.getFoldedRowCount(a.firstRow,i.firstRow-1);x>0;x--)this.$lines.shift();if(a.lastRow>i.lastRow)for(var x=this.session.getFoldedRowCount(i.lastRow+1,a.lastRow);x>0;x--)this.$lines.pop();i.firstRow<a.firstRow&&this.$lines.unshift(this.$renderLinesFragment(i,i.firstRow,a.firstRow-1)),i.lastRow>a.lastRow&&this.$lines.push(this.$renderLinesFragment(i,a.lastRow+1,i.lastRow)),this.$highlightIndentGuide()},u.prototype.$renderLinesFragment=function(i,a,m){for(var w=[],x=a,M=this.session.getNextFoldLine(x),$=M?M.start.row:1/0;x>$&&(x=M.end.row+1,M=this.session.getNextFoldLine(x,M),$=M?M.start.row:1/0),!(x>m);){var S=this.$lines.createCell(x,i,this.session),k=S.element;this.dom.removeChildren(k),h.setStyle(k.style,"height",this.$lines.computeLineHeight(x,i,this.session)+"px"),h.setStyle(k.style,"top",this.$lines.computeLineTop(x,i,this.session)+"px"),this.$renderLine(k,x,x==$?M:!1),this.$useLineGroups()?k.className="ace_line_group":k.className="ace_line",w.push(S),x++}return w},u.prototype.update=function(i){this.$lines.moveContainer(i),this.config=i;for(var a=i.firstRow,m=i.lastRow,w=this.$lines;w.getLength();)w.pop();w.push(this.$renderLinesFragment(i,a,m))},u.prototype.$renderToken=function(i,a,m,w){for(var x=this,M=/(\t)|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\uFEFF\uFFF9-\uFFFC\u2066\u2067\u2068\u202A\u202B\u202D\u202E\u202C\u2069\u2060\u2061\u2062\u2063\u2064\u206A\u206B\u206B\u206C\u206D\u206E\u206F]+)|(\u3000)|([\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3001-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]|[\uD800-\uDBFF][\uDC00-\uDFFF])/g,$=this.dom.createFragment(this.element),S,k=0;S=M.exec(w);){var T=S[1],D=S[2],L=S[3],O=S[4],z=S[5];if(!(!x.showSpaces&&D)){var P=k!=S.index?w.slice(k,S.index):"";if(k=S.index+S[0].length,P&&$.appendChild(this.dom.createTextNode(P,this.element)),T){var N=x.session.getScreenTabSize(a+S.index),A=x.$tabStrings[N].cloneNode(!0);A.charCount=1,$.appendChild(A),a+=N-1}else if(D)if(x.showSpaces){var _=this.dom.createElement("span");_.className="ace_invisible ace_invisible_space",_.textContent=b.stringRepeat(x.SPACE_CHAR,D.length),$.appendChild(_)}else $.appendChild(this.dom.createTextNode(D,this.element));else if(L){var _=this.dom.createElement("span");_.className="ace_invisible ace_invisible_space ace_invalid",_.textContent=b.stringRepeat(x.SPACE_CHAR,L.length),$.appendChild(_)}else if(O){a+=1;var _=this.dom.createElement("span");_.style.width=x.config.characterWidth*2+"px",_.className=x.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",_.textContent=x.showSpaces?x.SPACE_CHAR:O,$.appendChild(_)}else if(z){a+=1;var _=this.dom.createElement("span");_.style.width=x.config.characterWidth*2+"px",_.className="ace_cjk",_.textContent=z,$.appendChild(_)}}}if($.appendChild(this.dom.createTextNode(k?w.slice(k):w,this.element)),c(m.type))i.appendChild($);else{var I="ace_"+m.type.replace(/\./g," ace_"),_=this.dom.createElement("span");m.type=="fold"&&(_.style.width=m.value.length*this.config.characterWidth+"px",_.setAttribute("title",o("inline-fold.closed.title","Unfold code"))),_.className=I,_.appendChild($),i.appendChild(_)}return a+w.length},u.prototype.renderIndentGuide=function(i,a,m){var w=a.search(this.$indentGuideRe);if(w<=0||w>=m)return a;if(a[0]==" "){w-=w%this.tabSize;for(var x=w/this.tabSize,M=0;M<x;M++)i.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),a.substr(w)}else if(a[0]==" "){for(var M=0;M<w;M++)i.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),a.substr(w)}return this.$highlightIndentGuide(),a},u.prototype.$highlightIndentGuide=function(){if(!(!this.$highlightIndentGuides||!this.displayIndentGuides)){this.$highlightIndentGuideMarker={indentLevel:void 0,start:void 0,end:void 0,dir:void 0};var i=this.session.doc.$lines;if(i){var a=this.session.selection.getCursor(),m=/^\s*/.exec(this.session.doc.getLine(a.row))[0].length,w=Math.floor(m/this.tabSize);this.$highlightIndentGuideMarker={indentLevel:w,start:a.row};var x=this.session.$bracketHighlight;if(x){for(var M=this.session.$bracketHighlight.ranges,$=0;$<M.length;$++)if(a.row!==M[$].start.row){this.$highlightIndentGuideMarker.end=M[$].start.row+1,a.row>M[$].start.row?this.$highlightIndentGuideMarker.dir=-1:this.$highlightIndentGuideMarker.dir=1;break}}if(!this.$highlightIndentGuideMarker.end&&i[a.row]!==""&&a.column===i[a.row].length){this.$highlightIndentGuideMarker.dir=1;for(var $=a.row+1;$<i.length;$++){var S=i[$],k=/^\s*/.exec(S)[0].length;if(S!==""&&(this.$highlightIndentGuideMarker.end=$,k<=m))break}}this.$renderHighlightIndentGuide()}}},u.prototype.$clearActiveIndentGuide=function(){for(var i=this.element.querySelectorAll(".ace_indent-guide-active"),a=0;a<i.length;a++)i[a].classList.remove("ace_indent-guide-active")},u.prototype.$setIndentGuideActive=function(i,a){var m=this.session.doc.getLine(i.row);if(m!==""){var w=i.element;if(i.element.classList&&i.element.classList.contains("ace_line_group"))if(i.element.childNodes.length>0)w=i.element.childNodes[0];else return;var x=w.childNodes;if(x){var M=x[a-1];M&&M.classList&&M.classList.contains("ace_indent-guide")&&M.classList.add("ace_indent-guide-active")}}},u.prototype.$renderHighlightIndentGuide=function(){if(this.$lines){var i=this.$lines.cells;this.$clearActiveIndentGuide();var a=this.$highlightIndentGuideMarker.indentLevel;if(a!==0)if(this.$highlightIndentGuideMarker.dir===1)for(var m=0;m<i.length;m++){var w=i[m];if(this.$highlightIndentGuideMarker.end&&w.row>=this.$highlightIndentGuideMarker.start+1){if(w.row>=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(w,a)}}else for(var m=i.length-1;m>=0;m--){var w=i[m];if(this.$highlightIndentGuideMarker.end&&w.row<this.$highlightIndentGuideMarker.start){if(w.row<this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(w,a)}}}},u.prototype.$createLineElement=function(i){var a=this.dom.createElement("div");return a.className="ace_line",a.style.height=this.config.lineHeight+"px",a},u.prototype.$renderWrappedLine=function(i,a,m){var w=0,x=0,M=m[0],$=0,S=this.$createLineElement();i.appendChild(S);for(var k=0;k<a.length;k++){var T=a[k],D=T.value;if(k==0&&this.displayIndentGuides){if(w=D.length,D=this.renderIndentGuide(S,D,M),!D)continue;w-=D.length}if(w+D.length<M)$=this.$renderToken(S,$,T,D),w+=D.length;else{for(;w+D.length>=M;){$=this.$renderToken(S,$,T,D.substring(0,M-w)),D=D.substring(M-w),w=M,S=this.$createLineElement(),i.appendChild(S);var L=this.dom.createTextNode(b.stringRepeat(" ",m.indent),this.element);L.charCount=0,S.appendChild(L),x++,$=0,M=m[x]||Number.MAX_VALUE}D.length!=0&&(w+=D.length,$=this.$renderToken(S,$,T,D))}}m[m.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(S,$,null,"",!0)},u.prototype.$renderSimpleLine=function(i,a){for(var m=0,w=0;w<a.length;w++){var x=a[w],M=x.value;if(!(w==0&&this.displayIndentGuides&&(M=this.renderIndentGuide(i,M),!M))){if(m+M.length>this.MAX_LINE_LENGTH)return this.$renderOverflowMessage(i,m,x,M);m=this.$renderToken(i,m,x,M)}}},u.prototype.$renderOverflowMessage=function(i,a,m,w,x){m&&this.$renderToken(i,a,m,w.slice(0,this.MAX_LINE_LENGTH-a));var M=this.dom.createElement("span");M.className="ace_inline_button ace_keyword ace_toggle_wrap",M.textContent=x?"<hide>":"<click to see more...>",i.appendChild(M)},u.prototype.$renderLine=function(i,a,m){if(!m&&m!=!1&&(m=this.session.getFoldLine(a)),m)var w=this.$getFoldLineTokens(a,m);else var w=this.session.getTokens(a);var x=i;if(w.length){var M=this.session.getRowSplitData(a);if(M&&M.length){this.$renderWrappedLine(i,w,M);var x=i.lastChild}else{var x=i;this.$useLineGroups()&&(x=this.$createLineElement(),i.appendChild(x)),this.$renderSimpleLine(x,w)}}else this.$useLineGroups()&&(x=this.$createLineElement(),i.appendChild(x));if(this.showEOL&&x){m&&(a=m.end.row);var $=this.dom.createElement("span");$.className="ace_invisible ace_invisible_eol",$.textContent=a==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,x.appendChild($)}},u.prototype.$getFoldLineTokens=function(i,a){var m=this.session,w=[];function x($,S,k){for(var T=0,D=0;D+$[T].value.length<S;)if(D+=$[T].value.length,T++,T==$.length)return;if(D!=S){var L=$[T].value.substring(S-D);L.length>k-S&&(L=L.substring(0,k-S)),w.push({type:$[T].type,value:L}),D=S+L.length,T+=1}for(;D<k&&T<$.length;){var L=$[T].value;L.length+D>k?w.push({type:$[T].type,value:L.substring(0,k-D)}):w.push($[T]),D+=L.length,T+=1}}var M=m.getTokens(i);return a.walk(function($,S,k,T,D){$!=null?w.push({type:"fold",value:$}):(D&&(M=m.getTokens(S)),M.length&&x(M,T,k))},a.end.row,this.session.getLine(a.end.row).length),w},u.prototype.$useLineGroups=function(){return this.session.getUseWrapMode()},u}();f.prototype.EOF_CHAR="¶",f.prototype.EOL_CHAR_LF="¬",f.prototype.EOL_CHAR_CRLF="¤",f.prototype.EOL_CHAR=f.prototype.EOL_CHAR_LF,f.prototype.TAB_CHAR="—",f.prototype.SPACE_CHAR="·",f.prototype.$padding=0,f.prototype.MAX_LINE_LENGTH=1e4,f.prototype.showInvisibles=!1,f.prototype.showSpaces=!1,f.prototype.showTabs=!1,f.prototype.showEOL=!1,f.prototype.displayIndentGuides=!0,f.prototype.$highlightIndentGuides=!0,f.prototype.$tabStrings=[],f.prototype.destroy={},f.prototype.onChangeTabSize=f.prototype.$computeTabString,d.implement(f.prototype,g),r.Text=f}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(t,r,l){var d=t("../lib/dom"),h=function(){function b(p){this.element=d.createElement("div"),this.element.className="ace_layer ace_cursor-layer",p.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),d.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)}return b.prototype.$updateOpacity=function(p){for(var g=this.cursors,o=g.length;o--;)d.setStyle(g[o].style,"opacity",p?"":"0")},b.prototype.$startCssAnimation=function(){for(var p=this.cursors,g=p.length;g--;)p[g].style.animationDuration=this.blinkInterval+"ms";this.$isAnimating=!0,setTimeout((function(){this.$isAnimating&&d.addCssClass(this.element,"ace_animate-blinking")}).bind(this))},b.prototype.$stopCssAnimation=function(){this.$isAnimating=!1,d.removeCssClass(this.element,"ace_animate-blinking")},b.prototype.setPadding=function(p){this.$padding=p},b.prototype.setSession=function(p){this.session=p},b.prototype.setBlinking=function(p){p!=this.isBlinking&&(this.isBlinking=p,this.restartTimer())},b.prototype.setBlinkInterval=function(p){p!=this.blinkInterval&&(this.blinkInterval=p,this.restartTimer())},b.prototype.setSmoothBlinking=function(p){p!=this.smoothBlinking&&(this.smoothBlinking=p,d.setCssClass(this.element,"ace_smooth-blinking",p),this.$updateCursors(!0),this.restartTimer())},b.prototype.addCursor=function(){var p=d.createElement("div");return p.className="ace_cursor",this.element.appendChild(p),this.cursors.push(p),p},b.prototype.removeCursor=function(){if(this.cursors.length>1){var p=this.cursors.pop();return p.parentNode.removeChild(p),p}},b.prototype.hideCursor=function(){this.isVisible=!1,d.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},b.prototype.showCursor=function(){this.isVisible=!0,d.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},b.prototype.restartTimer=function(){var p=this.$updateCursors;if(clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&(this.$isSmoothBlinking=!1,d.removeCssClass(this.element,"ace_smooth-blinking")),p(!0),!this.isBlinking||!this.blinkInterval||!this.isVisible){this.$stopCssAnimation();return}if(this.smoothBlinking&&(this.$isSmoothBlinking=!0,setTimeout((function(){this.$isSmoothBlinking&&d.addCssClass(this.element,"ace_smooth-blinking")}).bind(this))),d.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var g=(function(){this.timeoutId=setTimeout(function(){p(!1)},.6*this.blinkInterval)}).bind(this);this.intervalId=setInterval(function(){p(!0),g()},this.blinkInterval),g()}},b.prototype.getPixelPosition=function(p,g){if(!this.config||!this.session)return{left:0,top:0};p||(p=this.session.selection.getCursor());var o=this.session.documentToScreenPosition(p),c=this.$padding+(this.session.$bidiHandler.isBidiRow(o.row,p.row)?this.session.$bidiHandler.getPosLeft(o.column):o.column*this.config.characterWidth),f=(o.row-(g?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:c,top:f}},b.prototype.isCursorInView=function(p,g){return p.top>=0&&p.top<g.maxHeight},b.prototype.update=function(p){this.config=p;var g=this.session.$selectionMarkers,o=0,c=0;(g===void 0||g.length===0)&&(g=[{cursor:null}]);for(var o=0,f=g.length;o<f;o++){var u=this.getPixelPosition(g[o].cursor,!0);if(!((u.top>p.height+p.offset||u.top<0)&&o>1)){var i=this.cursors[c++]||this.addCursor(),a=i.style;this.drawCursor?this.drawCursor(i,u,p,g[o],this.session):this.isCursorInView(u,p)?(d.setStyle(a,"display","block"),d.translate(i,u.left,u.top),d.setStyle(a,"width",Math.round(p.characterWidth)+"px"),d.setStyle(a,"height",p.lineHeight+"px")):d.setStyle(a,"display","none")}}for(;this.cursors.length>c;)this.removeCursor();var m=this.session.getOverwrite();this.$setOverwrite(m),this.$pixelPos=u,this.restartTimer()},b.prototype.$setOverwrite=function(p){p!=this.overwrite&&(this.overwrite=p,p?d.addCssClass(this.element,"ace_overwrite-cursors"):d.removeCssClass(this.element,"ace_overwrite-cursors"))},b.prototype.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)},b}();h.prototype.$padding=0,h.prototype.drawCursor=null,r.Cursor=h}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(t,r,l){var d=this&&this.__extends||function(){var i=function(a,m){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(w,x){w.__proto__=x}||function(w,x){for(var M in x)Object.prototype.hasOwnProperty.call(x,M)&&(w[M]=x[M])},i(a,m)};return function(a,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");i(a,m);function w(){this.constructor=a}a.prototype=m===null?Object.create(m):(w.prototype=m.prototype,new w)}}(),h=t("./lib/oop"),b=t("./lib/dom"),p=t("./lib/event"),g=t("./lib/event_emitter").EventEmitter,o=32768,c=function(){function i(a,m){this.element=b.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+m,this.inner=b.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent=" ",this.element.appendChild(this.inner),a.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,p.addListener(this.element,"scroll",this.onScroll.bind(this)),p.addListener(this.element,"mousedown",p.preventDefault)}return i.prototype.setVisible=function(a){this.element.style.display=a?"":"none",this.isVisible=a,this.coeff=1},i}();h.implement(c.prototype,g);var f=function(i){d(a,i);function a(m,w){var x=i.call(this,m,"-v")||this;return x.scrollTop=0,x.scrollHeight=0,w.$scrollbarWidth=x.width=b.scrollbarWidth(m.ownerDocument),x.inner.style.width=x.element.style.width=(x.width||15)+5+"px",x.$minWidth=0,x}return a.prototype.onScroll=function(){if(!this.skipEvent){if(this.scrollTop=this.element.scrollTop,this.coeff!=1){var m=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-m)/(this.coeff-m)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},a.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},a.prototype.setHeight=function(m){this.element.style.height=m+"px"},a.prototype.setScrollHeight=function(m){this.scrollHeight=m,m>o?(this.coeff=o/m,m=o):this.coeff!=1&&(this.coeff=1),this.inner.style.height=m+"px"},a.prototype.setScrollTop=function(m){this.scrollTop!=m&&(this.skipEvent=!0,this.scrollTop=m,this.element.scrollTop=m*this.coeff)},a}(c);f.prototype.setInnerHeight=f.prototype.setScrollHeight;var u=function(i){d(a,i);function a(m,w){var x=i.call(this,m,"-h")||this;return x.scrollLeft=0,x.height=w.$scrollbarWidth,x.inner.style.height=x.element.style.height=(x.height||15)+5+"px",x}return a.prototype.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},a.prototype.getHeight=function(){return this.isVisible?this.height:0},a.prototype.setWidth=function(m){this.element.style.width=m+"px"},a.prototype.setInnerWidth=function(m){this.inner.style.width=m+"px"},a.prototype.setScrollWidth=function(m){this.inner.style.width=m+"px"},a.prototype.setScrollLeft=function(m){this.scrollLeft!=m&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=m)},a}(c);r.ScrollBar=f,r.ScrollBarV=f,r.ScrollBarH=u,r.VScrollBar=f,r.HScrollBar=u}),ace.define("ace/scrollbar_custom",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(t,r,l){var d=this&&this.__extends||function(){var u=function(i,a){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,w){m.__proto__=w}||function(m,w){for(var x in w)Object.prototype.hasOwnProperty.call(w,x)&&(m[x]=w[x])},u(i,a)};return function(i,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");u(i,a);function m(){this.constructor=i}i.prototype=a===null?Object.create(a):(m.prototype=a.prototype,new m)}}(),h=t("./lib/oop"),b=t("./lib/dom"),p=t("./lib/event"),g=t("./lib/event_emitter").EventEmitter;b.importCssString(`.ace_editor>.ace_sb-v div, .ace_editor>.ace_sb-h div{
|
|
223
|
+
position: absolute;
|
|
224
|
+
background: rgba(128, 128, 128, 0.6);
|
|
225
|
+
-moz-box-sizing: border-box;
|
|
226
|
+
box-sizing: border-box;
|
|
227
|
+
border: 1px solid #bbb;
|
|
228
|
+
border-radius: 2px;
|
|
229
|
+
z-index: 8;
|
|
230
|
+
}
|
|
231
|
+
.ace_editor>.ace_sb-v, .ace_editor>.ace_sb-h {
|
|
232
|
+
position: absolute;
|
|
233
|
+
z-index: 6;
|
|
234
|
+
background: none;
|
|
235
|
+
overflow: hidden!important;
|
|
236
|
+
}
|
|
237
|
+
.ace_editor>.ace_sb-v {
|
|
238
|
+
z-index: 6;
|
|
239
|
+
right: 0;
|
|
240
|
+
top: 0;
|
|
241
|
+
width: 12px;
|
|
242
|
+
}
|
|
243
|
+
.ace_editor>.ace_sb-v div {
|
|
244
|
+
z-index: 8;
|
|
245
|
+
right: 0;
|
|
246
|
+
width: 100%;
|
|
247
|
+
}
|
|
248
|
+
.ace_editor>.ace_sb-h {
|
|
249
|
+
bottom: 0;
|
|
250
|
+
left: 0;
|
|
251
|
+
height: 12px;
|
|
252
|
+
}
|
|
253
|
+
.ace_editor>.ace_sb-h div {
|
|
254
|
+
bottom: 0;
|
|
255
|
+
height: 100%;
|
|
256
|
+
}
|
|
257
|
+
.ace_editor>.ace_sb_grabbed {
|
|
258
|
+
z-index: 8;
|
|
259
|
+
background: #000;
|
|
260
|
+
}`,"ace_scrollbar.css",!1);var o=function(){function u(i,a){this.element=b.createElement("div"),this.element.className="ace_sb"+a,this.inner=b.createElement("div"),this.inner.className="",this.element.appendChild(this.inner),this.VScrollWidth=12,this.HScrollHeight=12,i.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,p.addMultiMouseDownListener(this.element,[500,300,300],this,"onMouseDown")}return u.prototype.setVisible=function(i){this.element.style.display=i?"":"none",this.isVisible=i,this.coeff=1},u}();h.implement(o.prototype,g);var c=function(u){d(i,u);function i(a,m){var w=u.call(this,a,"-v")||this;return w.scrollTop=0,w.scrollHeight=0,w.parent=a,w.width=w.VScrollWidth,w.renderer=m,w.inner.style.width=w.element.style.width=(w.width||15)+"px",w.$minWidth=0,w}return i.prototype.onMouseDown=function(a,m){if(a==="mousedown"&&!(p.getButton(m)!==0||m.detail===2)){if(m.target===this.inner){var w=this,x=m.clientY,M=function(O){x=O.clientY},$=function(){clearInterval(D)},S=m.clientY,k=this.thumbTop,T=function(){if(x!==void 0){var O=w.scrollTopFromThumbTop(k+x-S);O!==w.scrollTop&&w._emit("scroll",{data:O})}};p.capture(this.inner,M,$);var D=setInterval(T,20);return p.preventDefault(m)}var L=m.clientY-this.element.getBoundingClientRect().top-this.thumbHeight/2;return this._emit("scroll",{data:this.scrollTopFromThumbTop(L)}),p.preventDefault(m)}},i.prototype.getHeight=function(){return this.height},i.prototype.scrollTopFromThumbTop=function(a){var m=a*(this.pageHeight-this.viewHeight)/(this.slideHeight-this.thumbHeight);return m=m>>0,m<0?m=0:m>this.pageHeight-this.viewHeight&&(m=this.pageHeight-this.viewHeight),m},i.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},i.prototype.setHeight=function(a){this.height=Math.max(0,a),this.slideHeight=this.height,this.viewHeight=this.height,this.setScrollHeight(this.pageHeight,!0)},i.prototype.setScrollHeight=function(a,m){this.pageHeight===a&&!m||(this.pageHeight=a,this.thumbHeight=this.slideHeight*this.viewHeight/this.pageHeight,this.thumbHeight>this.slideHeight&&(this.thumbHeight=this.slideHeight),this.thumbHeight<15&&(this.thumbHeight=15),this.inner.style.height=this.thumbHeight+"px",this.scrollTop>this.pageHeight-this.viewHeight&&(this.scrollTop=this.pageHeight-this.viewHeight,this.scrollTop<0&&(this.scrollTop=0),this._emit("scroll",{data:this.scrollTop})))},i.prototype.setScrollTop=function(a){this.scrollTop=a,a<0&&(a=0),this.thumbTop=a*(this.slideHeight-this.thumbHeight)/(this.pageHeight-this.viewHeight),this.inner.style.top=this.thumbTop+"px"},i}(o);c.prototype.setInnerHeight=c.prototype.setScrollHeight;var f=function(u){d(i,u);function i(a,m){var w=u.call(this,a,"-h")||this;return w.scrollLeft=0,w.scrollWidth=0,w.height=w.HScrollHeight,w.inner.style.height=w.element.style.height=(w.height||12)+"px",w.renderer=m,w}return i.prototype.onMouseDown=function(a,m){if(a==="mousedown"&&!(p.getButton(m)!==0||m.detail===2)){if(m.target===this.inner){var w=this,x=m.clientX,M=function(O){x=O.clientX},$=function(){clearInterval(D)},S=m.clientX,k=this.thumbLeft,T=function(){if(x!==void 0){var O=w.scrollLeftFromThumbLeft(k+x-S);O!==w.scrollLeft&&w._emit("scroll",{data:O})}};p.capture(this.inner,M,$);var D=setInterval(T,20);return p.preventDefault(m)}var L=m.clientX-this.element.getBoundingClientRect().left-this.thumbWidth/2;return this._emit("scroll",{data:this.scrollLeftFromThumbLeft(L)}),p.preventDefault(m)}},i.prototype.getHeight=function(){return this.isVisible?this.height:0},i.prototype.scrollLeftFromThumbLeft=function(a){var m=a*(this.pageWidth-this.viewWidth)/(this.slideWidth-this.thumbWidth);return m=m>>0,m<0?m=0:m>this.pageWidth-this.viewWidth&&(m=this.pageWidth-this.viewWidth),m},i.prototype.setWidth=function(a){this.width=Math.max(0,a),this.element.style.width=this.width+"px",this.slideWidth=this.width,this.viewWidth=this.width,this.setScrollWidth(this.pageWidth,!0)},i.prototype.setScrollWidth=function(a,m){this.pageWidth===a&&!m||(this.pageWidth=a,this.thumbWidth=this.slideWidth*this.viewWidth/this.pageWidth,this.thumbWidth>this.slideWidth&&(this.thumbWidth=this.slideWidth),this.thumbWidth<15&&(this.thumbWidth=15),this.inner.style.width=this.thumbWidth+"px",this.scrollLeft>this.pageWidth-this.viewWidth&&(this.scrollLeft=this.pageWidth-this.viewWidth,this.scrollLeft<0&&(this.scrollLeft=0),this._emit("scroll",{data:this.scrollLeft})))},i.prototype.setScrollLeft=function(a){this.scrollLeft=a,a<0&&(a=0),this.thumbLeft=a*(this.slideWidth-this.thumbWidth)/(this.pageWidth-this.viewWidth),this.inner.style.left=this.thumbLeft+"px"},i}(o);f.prototype.setInnerWidth=f.prototype.setScrollWidth,r.ScrollBar=c,r.ScrollBarV=c,r.ScrollBarH=f,r.VScrollBar=c,r.HScrollBar=f}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(t,r,l){var d=t("./lib/event"),h=function(){function b(p,g){this.onRender=p,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=g||window;var o=this;this._flush=function(c){o.pending=!1;var f=o.changes;if(f&&(d.blockIdle(100),o.changes=0,o.onRender(f)),o.changes){if(o.$recursionLimit--<0)return;o.schedule()}else o.$recursionLimit=2}}return b.prototype.schedule=function(p){this.changes=this.changes|p,this.changes&&!this.pending&&(d.nextFrame(this._flush),this.pending=!0)},b.prototype.clear=function(p){var g=this.changes;return this.changes=0,g},b}();r.RenderLoop=h}),ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/lib/useragent","ace/lib/event_emitter"],function(t,r,l){var d=t("../lib/oop"),h=t("../lib/dom"),b=t("../lib/lang"),p=t("../lib/event"),g=t("../lib/useragent"),o=t("../lib/event_emitter").EventEmitter,c=512,f=typeof ResizeObserver=="function",u=200,i=function(){function a(m){this.el=h.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=h.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=h.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),m.appendChild(this.el),this.$measureNode.textContent=b.stringRepeat("X",c),this.$characterSize={width:0,height:0},f?this.$addObserver():this.checkForSizeChanges()}return a.prototype.$setMeasureNodeStyles=function(m,w){m.width=m.height="auto",m.left=m.top="0px",m.visibility="hidden",m.position="absolute",m.whiteSpace="pre",g.isIE<8?m["font-family"]="inherit":m.font="inherit",m.overflow=w?"hidden":"visible"},a.prototype.checkForSizeChanges=function(m){if(m===void 0&&(m=this.$measureSizes()),m&&(this.$characterSize.width!==m.width||this.$characterSize.height!==m.height)){this.$measureNode.style.fontWeight="bold";var w=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=m,this.charSizes=Object.create(null),this.allowBoldFonts=w&&w.width===m.width&&w.height===m.height,this._emit("changeCharacterSize",{data:m})}},a.prototype.$addObserver=function(){var m=this;this.$observer=new window.ResizeObserver(function(w){m.checkForSizeChanges()}),this.$observer.observe(this.$measureNode)},a.prototype.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var m=this;return this.$pollSizeChangesTimer=p.onIdle(function w(){m.checkForSizeChanges(),p.onIdle(w,500)},500)},a.prototype.setPolling=function(m){m?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},a.prototype.$measureSizes=function(m){var w={height:(m||this.$measureNode).clientHeight,width:(m||this.$measureNode).clientWidth/c};return w.width===0||w.height===0?null:w},a.prototype.$measureCharWidth=function(m){this.$main.textContent=b.stringRepeat(m,c);var w=this.$main.getBoundingClientRect();return w.width/c},a.prototype.getCharacterWidth=function(m){var w=this.charSizes[m];return w===void 0&&(w=this.charSizes[m]=this.$measureCharWidth(m)/this.$characterSize.width),w},a.prototype.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},a.prototype.$getZoom=function(m){return!m||!m.parentElement?1:(Number(window.getComputedStyle(m).zoom)||1)*this.$getZoom(m.parentElement)},a.prototype.$initTransformMeasureNodes=function(){var m=function(w,x){return["div",{style:"position: absolute;top:"+w+"px;left:"+x+"px;"}]};this.els=h.buildDom([m(0,0),m(u,0),m(0,u),m(u,u)],this.el)},a.prototype.transformCoordinates=function(m,w){if(m){var x=this.$getZoom(this.el);m=k(1/x,m)}function M(Z,J,ae){var ne=Z[1]*J[0]-Z[0]*J[1];return[(-J[1]*ae[0]+J[0]*ae[1])/ne,(+Z[1]*ae[0]-Z[0]*ae[1])/ne]}function $(Z,J){return[Z[0]-J[0],Z[1]-J[1]]}function S(Z,J){return[Z[0]+J[0],Z[1]+J[1]]}function k(Z,J){return[Z*J[0],Z*J[1]]}this.els||this.$initTransformMeasureNodes();function T(Z){var J=Z.getBoundingClientRect();return[J.left,J.top]}var D=T(this.els[0]),L=T(this.els[1]),O=T(this.els[2]),z=T(this.els[3]),P=M($(z,L),$(z,O),$(S(L,O),S(z,D))),N=k(1+P[0],$(L,D)),A=k(1+P[1],$(O,D));if(w){var _=w,I=P[0]*_[0]/u+P[1]*_[1]/u+1,j=S(k(_[0],N),k(_[1],A));return S(k(1/I/u,j),D)}var U=$(m,D),K=M($(N,k(P[0],U)),$(A,k(P[1],U)),U);return k(u,K)},a}();i.prototype.$characterSize={width:0,height:0},d.implement(i.prototype,o),r.FontMetrics=i}),ace.define("ace/css/editor-css",["require","exports","module"],function(t,r,l){l.exports=`
|
|
261
|
+
.ace_br1 {border-top-left-radius : 3px;}
|
|
262
|
+
.ace_br2 {border-top-right-radius : 3px;}
|
|
263
|
+
.ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;}
|
|
264
|
+
.ace_br4 {border-bottom-right-radius: 3px;}
|
|
265
|
+
.ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;}
|
|
266
|
+
.ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;}
|
|
267
|
+
.ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;}
|
|
268
|
+
.ace_br8 {border-bottom-left-radius : 3px;}
|
|
269
|
+
.ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;}
|
|
270
|
+
.ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;}
|
|
271
|
+
.ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;}
|
|
272
|
+
.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
|
|
273
|
+
.ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
|
|
274
|
+
.ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
|
|
275
|
+
.ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
|
|
276
|
+
|
|
277
|
+
|
|
278
|
+
.ace_editor {
|
|
279
|
+
position: relative;
|
|
280
|
+
overflow: hidden;
|
|
281
|
+
padding: 0;
|
|
282
|
+
font: 12px/normal 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'Source Code Pro', 'source-code-pro', monospace;
|
|
283
|
+
direction: ltr;
|
|
284
|
+
text-align: left;
|
|
285
|
+
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
|
|
286
|
+
forced-color-adjust: none;
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
.ace_scroller {
|
|
290
|
+
position: absolute;
|
|
291
|
+
overflow: hidden;
|
|
292
|
+
top: 0;
|
|
293
|
+
bottom: 0;
|
|
294
|
+
background-color: inherit;
|
|
295
|
+
-ms-user-select: none;
|
|
296
|
+
-moz-user-select: none;
|
|
297
|
+
-webkit-user-select: none;
|
|
298
|
+
user-select: none;
|
|
299
|
+
cursor: text;
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
.ace_content {
|
|
303
|
+
position: absolute;
|
|
304
|
+
box-sizing: border-box;
|
|
305
|
+
min-width: 100%;
|
|
306
|
+
contain: style size layout;
|
|
307
|
+
font-variant-ligatures: no-common-ligatures;
|
|
308
|
+
}
|
|
309
|
+
.ace_invisible {
|
|
310
|
+
font-variant-ligatures: none;
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
.ace_keyboard-focus:focus {
|
|
314
|
+
box-shadow: inset 0 0 0 2px #5E9ED6;
|
|
315
|
+
outline: none;
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
.ace_dragging .ace_scroller:before{
|
|
319
|
+
position: absolute;
|
|
320
|
+
top: 0;
|
|
321
|
+
left: 0;
|
|
322
|
+
right: 0;
|
|
323
|
+
bottom: 0;
|
|
324
|
+
content: '';
|
|
325
|
+
background: rgba(250, 250, 250, 0.01);
|
|
326
|
+
z-index: 1000;
|
|
327
|
+
}
|
|
328
|
+
.ace_dragging.ace_dark .ace_scroller:before{
|
|
329
|
+
background: rgba(0, 0, 0, 0.01);
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
.ace_gutter {
|
|
333
|
+
position: absolute;
|
|
334
|
+
overflow : hidden;
|
|
335
|
+
width: auto;
|
|
336
|
+
top: 0;
|
|
337
|
+
bottom: 0;
|
|
338
|
+
left: 0;
|
|
339
|
+
cursor: default;
|
|
340
|
+
z-index: 4;
|
|
341
|
+
-ms-user-select: none;
|
|
342
|
+
-moz-user-select: none;
|
|
343
|
+
-webkit-user-select: none;
|
|
344
|
+
user-select: none;
|
|
345
|
+
contain: style size layout;
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
.ace_gutter-active-line {
|
|
349
|
+
position: absolute;
|
|
350
|
+
left: 0;
|
|
351
|
+
right: 0;
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
.ace_scroller.ace_scroll-left:after {
|
|
355
|
+
content: "";
|
|
356
|
+
position: absolute;
|
|
357
|
+
top: 0;
|
|
358
|
+
right: 0;
|
|
359
|
+
bottom: 0;
|
|
360
|
+
left: 0;
|
|
361
|
+
box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;
|
|
362
|
+
pointer-events: none;
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
.ace_gutter-cell, .ace_gutter-cell_svg-icons {
|
|
366
|
+
position: absolute;
|
|
367
|
+
top: 0;
|
|
368
|
+
left: 0;
|
|
369
|
+
right: 0;
|
|
370
|
+
padding-left: 19px;
|
|
371
|
+
padding-right: 6px;
|
|
372
|
+
background-repeat: no-repeat;
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
.ace_gutter-cell_svg-icons .ace_gutter_annotation {
|
|
376
|
+
margin-left: -14px;
|
|
377
|
+
float: left;
|
|
378
|
+
}
|
|
379
|
+
|
|
380
|
+
.ace_gutter-cell .ace_gutter_annotation {
|
|
381
|
+
margin-left: -19px;
|
|
382
|
+
float: left;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
.ace_gutter-cell.ace_error, .ace_icon.ace_error, .ace_icon.ace_error_fold, .ace_gutter-cell.ace_security, .ace_icon.ace_security, .ace_icon.ace_security_fold {
|
|
386
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");
|
|
387
|
+
background-repeat: no-repeat;
|
|
388
|
+
background-position: 2px center;
|
|
389
|
+
}
|
|
390
|
+
|
|
391
|
+
.ace_gutter-cell.ace_warning, .ace_icon.ace_warning, .ace_icon.ace_warning_fold {
|
|
392
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");
|
|
393
|
+
background-repeat: no-repeat;
|
|
394
|
+
background-position: 2px center;
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
.ace_gutter-cell.ace_info, .ace_icon.ace_info, .ace_gutter-cell.ace_hint, .ace_icon.ace_hint {
|
|
398
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");
|
|
399
|
+
background-repeat: no-repeat;
|
|
400
|
+
background-position: 2px center;
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
.ace_dark .ace_gutter-cell.ace_info, .ace_dark .ace_icon.ace_info, .ace_dark .ace_gutter-cell.ace_hint, .ace_dark .ace_icon.ace_hint {
|
|
404
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
.ace_icon_svg.ace_error {
|
|
408
|
+
-webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJyZWQiIHNoYXBlLXJlbmRlcmluZz0iZ2VvbWV0cmljUHJlY2lzaW9uIj4KPGNpcmNsZSBmaWxsPSJub25lIiBjeD0iOCIgY3k9IjgiIHI9IjciIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPGxpbmUgeDE9IjExIiB5MT0iNSIgeDI9IjUiIHkyPSIxMSIvPgo8bGluZSB4MT0iMTEiIHkxPSIxMSIgeDI9IjUiIHkyPSI1Ii8+CjwvZz4KPC9zdmc+");
|
|
409
|
+
background-color: crimson;
|
|
410
|
+
}
|
|
411
|
+
.ace_icon_svg.ace_security {
|
|
412
|
+
-webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0iZGFya29yYW5nZSIgZmlsbD0ibm9uZSIgc2hhcGUtcmVuZGVyaW5nPSJnZW9tZXRyaWNQcmVjaXNpb24iPgogICAgICAgIDxwYXRoIGNsYXNzPSJzdHJva2UtbGluZWpvaW4tcm91bmQiIGQ9Ik04IDE0LjgzMDdDOCAxNC44MzA3IDIgMTIuOTA0NyAyIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOEM3Ljk4OTk5IDEuMzQ5MTggMTAuNjkgMy4yNjU0OCAxNCAzLjI2NTQ4VjguMDg5OTJDMTQgMTIuOTA0NyA4IDE0LjgzMDcgOCAxNC44MzA3WiIvPgogICAgICAgIDxwYXRoIGQ9Ik0yIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOCIvPgogICAgICAgIDxwYXRoIGQ9Ik0xMy45OSA4LjA4OTkyVjMuMjY1NDhDMTAuNjggMy4yNjU0OCA4IDEuMzQ5MTggOCAxLjM0OTE4Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggNFY5Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggMTBWMTIiLz4KICAgIDwvZz4KPC9zdmc+");
|
|
413
|
+
background-color: crimson;
|
|
414
|
+
}
|
|
415
|
+
.ace_icon_svg.ace_warning {
|
|
416
|
+
-webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJkYXJrb3JhbmdlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+Cjxwb2x5Z29uIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGZpbGw9Im5vbmUiIHBvaW50cz0iOCAxIDE1IDE1IDEgMTUgOCAxIi8+CjxyZWN0IHg9IjgiIHk9IjEyIiB3aWR0aD0iMC4wMSIgaGVpZ2h0PSIwLjAxIi8+CjxsaW5lIHgxPSI4IiB5MT0iNiIgeDI9IjgiIHkyPSIxMCIvPgo8L2c+Cjwvc3ZnPg==");
|
|
417
|
+
background-color: darkorange;
|
|
418
|
+
}
|
|
419
|
+
.ace_icon_svg.ace_info {
|
|
420
|
+
-webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJibHVlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CjxjaXJjbGUgZmlsbD0ibm9uZSIgY3g9IjgiIGN5PSI4IiByPSI3IiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+Cjxwb2x5bGluZSBwb2ludHM9IjggMTEgOCA4Ii8+Cjxwb2x5bGluZSBwb2ludHM9IjkgOCA2IDgiLz4KPGxpbmUgeDE9IjEwIiB5MT0iMTEiIHgyPSI2IiB5Mj0iMTEiLz4KPHJlY3QgeD0iOCIgeT0iNSIgd2lkdGg9IjAuMDEiIGhlaWdodD0iMC4wMSIvPgo8L2c+Cjwvc3ZnPg==");
|
|
421
|
+
background-color: royalblue;
|
|
422
|
+
}
|
|
423
|
+
.ace_icon_svg.ace_hint {
|
|
424
|
+
-webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0ic2lsdmVyIiBmaWxsPSJub25lIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTYgMTRIMTAiLz4KICAgICAgICA8cGF0aCBkPSJNOCAxMUg5QzkgOS40NzAwMiAxMiA4LjU0MDAyIDEyIDUuNzYwMDJDMTIuMDIgNC40MDAwMiAxMS4zOSAzLjM2MDAyIDEwLjQzIDIuNjcwMDJDOSAxLjY0MDAyIDcuMDAwMDEgMS42NDAwMiA1LjU3MDAxIDIuNjcwMDJDNC42MTAwMSAzLjM2MDAyIDMuOTggNC40MDAwMiA0IDUuNzYwMDJDNCA4LjU0MDAyIDcuMDAwMDEgOS40NzAwMiA3LjAwMDAxIDExSDhaIi8+CiAgICA8L2c+Cjwvc3ZnPg==");
|
|
425
|
+
background-color: silver;
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
.ace_icon_svg.ace_error_fold {
|
|
429
|
+
-webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiIgZmlsbD0ibm9uZSI+CiAgPHBhdGggZD0ibSAxOC45Mjk4NTEsNy44Mjk4MDc2IGMgMC4xNDYzNTMsNi4zMzc0NjA0IC02LjMyMzE0Nyw3Ljc3Nzg0NDQgLTcuNDc3OTEyLDcuNzc3ODQ0NCAtMi4xMDcyNzI2LC0wLjEyODc1IDUuMTE3Njc4LDAuMzU2MjQ5IDUuMDUxNjk4LC03Ljg3MDA2MTggLTAuNjA0NjcyLC04LjAwMzk3MzQ5IC03LjA3NzI3MDYsLTcuNTYzMTE4OSAtNC44NTczLC03LjQzMDM5NTU2IDEuNjA2LC0wLjExNTE0MjI1IDYuODk3NDg1LDEuMjYyNTQ1OTYgNy4yODM1MTQsNy41MjI2MTI5NiB6IiBmaWxsPSJjcmltc29uIiBzdHJva2Utd2lkdGg9IjIiLz4KICA8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0ibSA4LjExNDc1NjIsMi4wNTI5ODI4IGMgMy4zNDkxNjk4LDAgNi4wNjQxMzI4LDIuNjc2ODYyNyA2LjA2NDEzMjgsNS45Nzg5NTMgMCwzLjMwMjExMjIgLTIuNzE0OTYzLDUuOTc4OTIwMiAtNi4wNjQxMzI4LDUuOTc4OTIwMiAtMy4zNDkxNDczLDAgLTYuMDY0MTc3MiwtMi42NzY4MDggLTYuMDY0MTc3MiwtNS45Nzg5MjAyIDAuMDA1MzksLTMuMjk5ODg2MSAyLjcxNzI2NTYsLTUuOTczNjQwOCA2LjA2NDE3NzIsLTUuOTc4OTUzIHogbSAwLC0xLjczNTgyNzE5IGMgLTQuMzIxNDgzNiwwIC03LjgyNDc0MDM4LDMuNDU0MDE4NDkgLTcuODI0NzQwMzgsNy43MTQ3ODAxOSAwLDQuMjYwNzI4MiAzLjUwMzI1Njc4LDcuNzE0NzQ1MiA3LjgyNDc0MDM4LDcuNzE0NzQ1MiA0LjMyMTQ0OTgsMCA3LjgyNDY5OTgsLTMuNDU0MDE3IDcuODI0Njk5OCwtNy43MTQ3NDUyIDAsLTIuMDQ2MDkxNCAtMC44MjQzOTIsLTQuMDA4MzY3MiAtMi4yOTE3NTYsLTUuNDU1MTc0NiBDIDEyLjE4MDIyNSwxLjEyOTk2NDggMTAuMTkwMDEzLDAuMzE3MTU1NjEgOC4xMTQ3NTYyLDAuMzE3MTU1NjEgWiBNIDYuOTM3NDU2Myw4LjI0MDU5ODUgNC42NzE4Njg1LDEwLjQ4NTg1MiA2LjAwODY4MTQsMTEuODc2NzI4IDguMzE3MDAzNSw5LjYwMDc5MTEgMTAuNjI1MzM3LDExLjg3NjcyOCAxMS45NjIxMzgsMTAuNDg1ODUyIDkuNjk2NTUwOCw4LjI0MDU5ODUgMTEuOTYyMTM4LDYuMDA2ODA2NiAxMC41NzMyNDYsNC42Mzc0MzM1IDguMzE3MDAzNSw2Ljg3MzQyOTcgNi4wNjA3NjA3LDQuNjM3NDMzNSA0LjY3MTg2ODUsNi4wMDY4MDY2IFoiIGZpbGw9ImNyaW1zb24iIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");
|
|
430
|
+
background-color: crimson;
|
|
431
|
+
}
|
|
432
|
+
.ace_icon_svg.ace_security_fold {
|
|
433
|
+
-webkit-mask-image: url("data:image/svg+xml;base64,CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMTcgMTQiIGZpbGw9Im5vbmUiPgogICAgPHBhdGggZD0iTTEwLjAwMDEgMTMuNjk5MkMxMC4wMDAxIDEzLjY5OTIgMTEuOTI0MSAxMy40NzYzIDEzIDEyLjY5OTJDMTQuNDEzOSAxMS42NzgxIDE2IDEwLjUgMTYuMTI1MSA2LjgxMTI2VjIuNTg5ODdDMTYuMTI1MSAyLjU0NzY4IDE2LjEyMjEgMi41MDYxOSAxNi4xMTY0IDIuNDY1NTlWMS43MTQ4NUgxNS4yNDE0TDE1LjIzMDcgMS43MTQ4NEwxNC42MjUxIDEuNjk5MjJWNi44MTEyM0MxNC42MjUxIDguNTEwNjEgMTQuNjI1MSA5LjQ2NDYxIDEyLjc4MjQgMTEuNzIxQzEyLjE1ODYgMTIuNDg0OCAxMC4wMDAxIDEzLjY5OTIgMTAuMDAwMSAxMy42OTkyWiIgZmlsbD0iY3JpbXNvbiIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgICA8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTcuMzM2MDkgMC4zNjc0NzVDNy4wMzIxNCAwLjE1MjY1MiA2LjYyNTQ4IDAuMTUzNjE0IDYuMzIyNTMgMC4zNjk5OTdMNi4zMDg2OSAwLjM3OTU1NEM2LjI5NTUzIDAuMzg4NTg4IDYuMjczODggMC40MDMyNjYgNi4yNDQxNyAwLjQyMjc4OUM2LjE4NDcxIDAuNDYxODYgNi4wOTMyMSAwLjUyMDE3MSA1Ljk3MzEzIDAuNTkxMzczQzUuNzMyNTEgMC43MzQwNTkgNS4zNzk5IDAuOTI2ODY0IDQuOTQyNzkgMS4xMjAwOUM0LjA2MTQ0IDEuNTA5NyAyLjg3NTQxIDEuODgzNzcgMS41ODk4NCAxLjg4Mzc3SDAuNzE0ODQ0VjIuNzU4NzdWNi45ODAxNUMwLjcxNDg0NCA5LjQ5Mzc0IDIuMjg4NjYgMTEuMTk3MyAzLjcwMjU0IDEyLjIxODVDNC40MTg0NSAxMi43MzU1IDUuMTI4NzQgMTMuMTA1MyA1LjY1NzMzIDEzLjM0NTdDNS45MjI4NCAxMy40NjY0IDYuMTQ1NjYgMTMuNTU1OSA2LjMwNDY1IDEzLjYxNjFDNi4zODQyMyAxMy42NDYyIDYuNDQ4MDUgMTMuNjY5IDYuNDkzNDkgMTMuNjg0OEM2LjUxNjIyIDEzLjY5MjcgNi41MzQzOCAxMy42OTg5IDYuNTQ3NjQgMTMuNzAzM0w2LjU2MzgyIDEzLjcwODdMNi41NjkwOCAxMy43MTA0TDYuNTcwOTkgMTMuNzExTDYuODM5ODQgMTMuNzUzM0w2LjU3MjQyIDEzLjcxMTVDNi43NDYzMyAxMy43NjczIDYuOTMzMzUgMTMuNzY3MyA3LjEwNzI3IDEzLjcxMTVMNy4xMDg3IDEzLjcxMUw3LjExMDYxIDEzLjcxMDRMNy4xMTU4NyAxMy43MDg3TDcuMTMyMDUgMTMuNzAzM0M3LjE0NTMxIDEzLjY5ODkgNy4xNjM0NiAxMy42OTI3IDcuMTg2MTkgMTMuNjg0OEM3LjIzMTY0IDEzLjY2OSA3LjI5NTQ2IDEzLjY0NjIgNy4zNzUwMyAxMy42MTYxQzcuNTM0MDMgMTMuNTU1OSA3Ljc1Njg1IDEzLjQ2NjQgOC4wMjIzNiAxMy4zNDU3QzguNTUwOTUgMTMuMTA1MyA5LjI2MTIzIDEyLjczNTUgOS45NzcxNSAxMi4yMTg1QzExLjM5MSAxMS4xOTczIDEyLjk2NDggOS40OTM3NyAxMi45NjQ4IDYuOTgwMThWMi43NTg4QzEyLjk2NDggMi43MTY2IDEyLjk2MTkgMi42NzUxMSAxMi45NTYxIDIuNjM0NTFWMS44ODM3N0gxMi4wODExQzEyLjA3NzUgMS44ODM3NyAxMi4wNzQgMS44ODM3NyAxMi4wNzA0IDEuODgzNzdDMTAuNzk3OSAxLjg4MDA0IDkuNjE5NjIgMS41MTEwMiA4LjczODk0IDEuMTI0ODZDOC43MzUzNCAxLjEyMzI3IDguNzMxNzQgMS4xMjE2OCA4LjcyODE0IDEuMTIwMDlDOC4yOTEwMyAwLjkyNjg2NCA3LjkzODQyIDAuNzM0MDU5IDcuNjk3NzkgMC41OTEzNzNDNy41Nzc3MiAwLjUyMDE3MSA3LjQ4NjIyIDAuNDYxODYgNy40MjY3NiAwLjQyMjc4OUM3LjM5NzA1IDAuNDAzMjY2IDcuMzc1MzkgMC4zODg1ODggNy4zNjIyNCAwLjM3OTU1NEw3LjM0ODk2IDAuMzcwMzVDNy4zNDg5NiAwLjM3MDM1IDcuMzQ4NDcgMC4zNzAwMiA3LjM0NTYzIDAuMzc0MDU0TDcuMzM3NzkgMC4zNjg2NTlMNy4zMzYwOSAwLjM2NzQ3NVpNOC4wMzQ3MSAyLjcyNjkxQzguODYwNCAzLjA5MDYzIDkuOTYwNjYgMy40NjMwOSAxMS4yMDYxIDMuNTg5MDdWNi45ODAxNUgxMS4yMTQ4QzExLjIxNDggOC42Nzk1MyAxMC4xNjM3IDkuOTI1MDcgOC45NTI1NCAxMC43OTk4QzguMzU1OTUgMTEuMjMwNiA3Ljc1Mzc0IDExLjU0NTQgNy4yOTc5NiAxMS43NTI3QzcuMTE2NzEgMTEuODM1MSA2Ljk2MDYyIDExLjg5OTYgNi44Mzk4NCAxMS45NDY5QzYuNzE5MDYgMTEuODk5NiA2LjU2Mjk3IDExLjgzNTEgNi4zODE3MyAxMS43NTI3QzUuOTI1OTUgMTEuNTQ1NCA1LjMyMzczIDExLjIzMDYgNC43MjcxNSAxMC43OTk4QzMuNTE2MDMgOS45MjUwNyAyLjQ2NDg0IDguNjc5NTUgMi40NjQ4NCA2Ljk4MDE4VjMuNTg5MDlDMy43MTczOCAzLjQ2MjM5IDQuODIzMDggMy4wODYzOSA1LjY1MDMzIDIuNzIwNzFDNi4xNDIyOCAyLjUwMzI0IDYuNTQ0ODUgMi4yODUzNyA2LjgzMjU0IDIuMTE2MjRDNy4xMjE4MSAyLjI4NTM1IDcuNTI3IDIuNTAzNTIgOC4wMjE5NiAyLjcyMTMxQzguMDI2MiAyLjcyMzE3IDguMDMwNDUgMi43MjUwNCA4LjAzNDcxIDIuNzI2OTFaTTUuOTY0ODQgMy40MDE0N1Y3Ljc3NjQ3SDcuNzE0ODRWMy40MDE0N0g1Ljk2NDg0Wk01Ljk2NDg0IDEwLjQwMTVWOC42NTE0N0g3LjcxNDg0VjEwLjQwMTVINS45NjQ4NFoiIGZpbGw9ImNyaW1zb24iIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");
|
|
434
|
+
background-color: crimson;
|
|
435
|
+
}
|
|
436
|
+
.ace_icon_svg.ace_warning_fold {
|
|
437
|
+
-webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjAiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAyMCAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xNC43NzY5IDE0LjczMzdMOC42NTE5MiAyLjQ4MzY5QzguMzI5NDYgMS44Mzg3NyA3LjQwOTEzIDEuODM4NzcgNy4wODY2NyAyLjQ4MzY5TDAuOTYxNjY5IDE0LjczMzdDMC42NzA3NzUgMTUuMzE1NSAxLjA5MzgzIDE2IDEuNzQ0MjkgMTZIMTMuOTk0M0MxNC42NDQ4IDE2IDE1LjA2NzggMTUuMzE1NSAxNC43NzY5IDE0LjczMzdaTTMuMTYwMDcgMTQuMjVMNy44NjkyOSA0LjgzMTU2TDEyLjU3ODUgMTQuMjVIMy4xNjAwN1pNOC43NDQyOSAxMS42MjVWMTMuMzc1SDYuOTk0MjlWMTEuNjI1SDguNzQ0MjlaTTYuOTk0MjkgMTAuNzVWNy4yNUg4Ljc0NDI5VjEwLjc1SDYuOTk0MjlaIiBmaWxsPSIjRUM3MjExIi8+CjxwYXRoIGQ9Ik0xMS4xOTkxIDIuOTUyMzhDMTAuODgwOSAyLjMxNDY3IDEwLjM1MzcgMS44MDUyNiA5LjcwNTUgMS41MDlMMTEuMDQxIDEuMDY5NzhDMTEuNjg4MyAwLjk0OTgxNCAxMi4zMzcgMS4yNzI2MyAxMi42MzE3IDEuODYxNDFMMTcuNjEzNiAxMS44MTYxQzE4LjM1MjcgMTMuMjkyOSAxNy41OTM4IDE1LjA4MDQgMTYuMDE4IDE1LjU3NDVDMTYuNDA0NCAxNC40NTA3IDE2LjMyMzEgMTMuMjE4OCAxNS43OTI0IDEyLjE1NTVMMTEuMTk5MSAyLjk1MjM4WiIgZmlsbD0iI0VDNzIxMSIvPgo8L3N2Zz4=");
|
|
438
|
+
background-color: darkorange;
|
|
439
|
+
}
|
|
440
|
+
|
|
441
|
+
.ace_scrollbar {
|
|
442
|
+
contain: strict;
|
|
443
|
+
position: absolute;
|
|
444
|
+
right: 0;
|
|
445
|
+
bottom: 0;
|
|
446
|
+
z-index: 6;
|
|
447
|
+
}
|
|
448
|
+
|
|
449
|
+
.ace_scrollbar-inner {
|
|
450
|
+
position: absolute;
|
|
451
|
+
cursor: text;
|
|
452
|
+
left: 0;
|
|
453
|
+
top: 0;
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
.ace_scrollbar-v{
|
|
457
|
+
overflow-x: hidden;
|
|
458
|
+
overflow-y: scroll;
|
|
459
|
+
top: 0;
|
|
460
|
+
}
|
|
461
|
+
|
|
462
|
+
.ace_scrollbar-h {
|
|
463
|
+
overflow-x: scroll;
|
|
464
|
+
overflow-y: hidden;
|
|
465
|
+
left: 0;
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
.ace_print-margin {
|
|
469
|
+
position: absolute;
|
|
470
|
+
height: 100%;
|
|
471
|
+
}
|
|
472
|
+
|
|
473
|
+
.ace_text-input {
|
|
474
|
+
position: absolute;
|
|
475
|
+
z-index: 0;
|
|
476
|
+
width: 0.5em;
|
|
477
|
+
height: 1em;
|
|
478
|
+
opacity: 0;
|
|
479
|
+
background: transparent;
|
|
480
|
+
-moz-appearance: none;
|
|
481
|
+
appearance: none;
|
|
482
|
+
border: none;
|
|
483
|
+
resize: none;
|
|
484
|
+
outline: none;
|
|
485
|
+
overflow: hidden;
|
|
486
|
+
font: inherit;
|
|
487
|
+
padding: 0 1px;
|
|
488
|
+
margin: 0 -1px;
|
|
489
|
+
contain: strict;
|
|
490
|
+
-ms-user-select: text;
|
|
491
|
+
-moz-user-select: text;
|
|
492
|
+
-webkit-user-select: text;
|
|
493
|
+
user-select: text;
|
|
494
|
+
/*with \`pre-line\` chrome inserts instead of space*/
|
|
495
|
+
white-space: pre!important;
|
|
496
|
+
}
|
|
497
|
+
.ace_text-input.ace_composition {
|
|
498
|
+
background: transparent;
|
|
499
|
+
color: inherit;
|
|
500
|
+
z-index: 1000;
|
|
501
|
+
opacity: 1;
|
|
502
|
+
}
|
|
503
|
+
.ace_composition_placeholder { color: transparent }
|
|
504
|
+
.ace_composition_marker {
|
|
505
|
+
border-bottom: 1px solid;
|
|
506
|
+
position: absolute;
|
|
507
|
+
border-radius: 0;
|
|
508
|
+
margin-top: 1px;
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
[ace_nocontext=true] {
|
|
512
|
+
transform: none!important;
|
|
513
|
+
filter: none!important;
|
|
514
|
+
clip-path: none!important;
|
|
515
|
+
mask : none!important;
|
|
516
|
+
contain: none!important;
|
|
517
|
+
perspective: none!important;
|
|
518
|
+
mix-blend-mode: initial!important;
|
|
519
|
+
z-index: auto;
|
|
520
|
+
}
|
|
521
|
+
|
|
522
|
+
.ace_layer {
|
|
523
|
+
z-index: 1;
|
|
524
|
+
position: absolute;
|
|
525
|
+
overflow: hidden;
|
|
526
|
+
/* workaround for chrome bug https://github.com/ajaxorg/ace/issues/2312*/
|
|
527
|
+
word-wrap: normal;
|
|
528
|
+
white-space: pre;
|
|
529
|
+
height: 100%;
|
|
530
|
+
width: 100%;
|
|
531
|
+
box-sizing: border-box;
|
|
532
|
+
/* setting pointer-events: auto; on node under the mouse, which changes
|
|
533
|
+
during scroll, will break mouse wheel scrolling in Safari */
|
|
534
|
+
pointer-events: none;
|
|
535
|
+
}
|
|
536
|
+
|
|
537
|
+
.ace_gutter-layer {
|
|
538
|
+
position: relative;
|
|
539
|
+
width: auto;
|
|
540
|
+
text-align: right;
|
|
541
|
+
pointer-events: auto;
|
|
542
|
+
height: 1000000px;
|
|
543
|
+
contain: style size layout;
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
.ace_text-layer {
|
|
547
|
+
font: inherit !important;
|
|
548
|
+
position: absolute;
|
|
549
|
+
height: 1000000px;
|
|
550
|
+
width: 1000000px;
|
|
551
|
+
contain: style size layout;
|
|
552
|
+
}
|
|
553
|
+
|
|
554
|
+
.ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group {
|
|
555
|
+
contain: style size layout;
|
|
556
|
+
position: absolute;
|
|
557
|
+
top: 0;
|
|
558
|
+
left: 0;
|
|
559
|
+
right: 0;
|
|
560
|
+
}
|
|
561
|
+
|
|
562
|
+
.ace_hidpi .ace_text-layer,
|
|
563
|
+
.ace_hidpi .ace_gutter-layer,
|
|
564
|
+
.ace_hidpi .ace_content,
|
|
565
|
+
.ace_hidpi .ace_gutter {
|
|
566
|
+
contain: strict;
|
|
567
|
+
}
|
|
568
|
+
.ace_hidpi .ace_text-layer > .ace_line,
|
|
569
|
+
.ace_hidpi .ace_text-layer > .ace_line_group {
|
|
570
|
+
contain: strict;
|
|
571
|
+
}
|
|
572
|
+
|
|
573
|
+
.ace_cjk {
|
|
574
|
+
display: inline-block;
|
|
575
|
+
text-align: center;
|
|
576
|
+
}
|
|
577
|
+
|
|
578
|
+
.ace_cursor-layer {
|
|
579
|
+
z-index: 4;
|
|
580
|
+
}
|
|
581
|
+
|
|
582
|
+
.ace_cursor {
|
|
583
|
+
z-index: 4;
|
|
584
|
+
position: absolute;
|
|
585
|
+
box-sizing: border-box;
|
|
586
|
+
border-left: 2px solid;
|
|
587
|
+
/* workaround for smooth cursor repaintng whole screen in chrome */
|
|
588
|
+
transform: translatez(0);
|
|
589
|
+
}
|
|
590
|
+
|
|
591
|
+
.ace_multiselect .ace_cursor {
|
|
592
|
+
border-left-width: 1px;
|
|
593
|
+
}
|
|
594
|
+
|
|
595
|
+
.ace_slim-cursors .ace_cursor {
|
|
596
|
+
border-left-width: 1px;
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
.ace_overwrite-cursors .ace_cursor {
|
|
600
|
+
border-left-width: 0;
|
|
601
|
+
border-bottom: 1px solid;
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
.ace_hidden-cursors .ace_cursor {
|
|
605
|
+
opacity: 0.2;
|
|
606
|
+
}
|
|
607
|
+
|
|
608
|
+
.ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {
|
|
609
|
+
opacity: 0;
|
|
610
|
+
}
|
|
611
|
+
|
|
612
|
+
.ace_smooth-blinking .ace_cursor {
|
|
613
|
+
transition: opacity 0.18s;
|
|
614
|
+
}
|
|
615
|
+
|
|
616
|
+
.ace_animate-blinking .ace_cursor {
|
|
617
|
+
animation-duration: 1000ms;
|
|
618
|
+
animation-timing-function: step-end;
|
|
619
|
+
animation-name: blink-ace-animate;
|
|
620
|
+
animation-iteration-count: infinite;
|
|
621
|
+
}
|
|
622
|
+
|
|
623
|
+
.ace_animate-blinking.ace_smooth-blinking .ace_cursor {
|
|
624
|
+
animation-duration: 1000ms;
|
|
625
|
+
animation-timing-function: ease-in-out;
|
|
626
|
+
animation-name: blink-ace-animate-smooth;
|
|
627
|
+
}
|
|
628
|
+
|
|
629
|
+
@keyframes blink-ace-animate {
|
|
630
|
+
from, to { opacity: 1; }
|
|
631
|
+
60% { opacity: 0; }
|
|
632
|
+
}
|
|
633
|
+
|
|
634
|
+
@keyframes blink-ace-animate-smooth {
|
|
635
|
+
from, to { opacity: 1; }
|
|
636
|
+
45% { opacity: 1; }
|
|
637
|
+
60% { opacity: 0; }
|
|
638
|
+
85% { opacity: 0; }
|
|
639
|
+
}
|
|
640
|
+
|
|
641
|
+
.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {
|
|
642
|
+
position: absolute;
|
|
643
|
+
z-index: 3;
|
|
644
|
+
}
|
|
645
|
+
|
|
646
|
+
.ace_marker-layer .ace_selection {
|
|
647
|
+
position: absolute;
|
|
648
|
+
z-index: 5;
|
|
649
|
+
}
|
|
650
|
+
|
|
651
|
+
.ace_marker-layer .ace_bracket {
|
|
652
|
+
position: absolute;
|
|
653
|
+
z-index: 6;
|
|
654
|
+
}
|
|
655
|
+
|
|
656
|
+
.ace_marker-layer .ace_error_bracket {
|
|
657
|
+
position: absolute;
|
|
658
|
+
border-bottom: 1px solid #DE5555;
|
|
659
|
+
border-radius: 0;
|
|
660
|
+
}
|
|
661
|
+
|
|
662
|
+
.ace_marker-layer .ace_active-line {
|
|
663
|
+
position: absolute;
|
|
664
|
+
z-index: 2;
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
.ace_marker-layer .ace_selected-word {
|
|
668
|
+
position: absolute;
|
|
669
|
+
z-index: 4;
|
|
670
|
+
box-sizing: border-box;
|
|
671
|
+
}
|
|
672
|
+
|
|
673
|
+
.ace_line .ace_fold {
|
|
674
|
+
box-sizing: border-box;
|
|
675
|
+
|
|
676
|
+
display: inline-block;
|
|
677
|
+
height: 11px;
|
|
678
|
+
margin-top: -2px;
|
|
679
|
+
vertical-align: middle;
|
|
680
|
+
|
|
681
|
+
background-image:
|
|
682
|
+
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),
|
|
683
|
+
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");
|
|
684
|
+
background-repeat: no-repeat, repeat-x;
|
|
685
|
+
background-position: center center, top left;
|
|
686
|
+
color: transparent;
|
|
687
|
+
|
|
688
|
+
border: 1px solid black;
|
|
689
|
+
border-radius: 2px;
|
|
690
|
+
|
|
691
|
+
cursor: pointer;
|
|
692
|
+
pointer-events: auto;
|
|
693
|
+
}
|
|
694
|
+
|
|
695
|
+
.ace_dark .ace_fold {
|
|
696
|
+
}
|
|
697
|
+
|
|
698
|
+
.ace_fold:hover{
|
|
699
|
+
background-image:
|
|
700
|
+
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),
|
|
701
|
+
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");
|
|
702
|
+
}
|
|
703
|
+
|
|
704
|
+
.ace_tooltip {
|
|
705
|
+
background-color: #f5f5f5;
|
|
706
|
+
border: 1px solid gray;
|
|
707
|
+
border-radius: 1px;
|
|
708
|
+
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
|
|
709
|
+
color: black;
|
|
710
|
+
padding: 3px 4px;
|
|
711
|
+
position: fixed;
|
|
712
|
+
z-index: 999999;
|
|
713
|
+
box-sizing: border-box;
|
|
714
|
+
cursor: default;
|
|
715
|
+
white-space: pre-wrap;
|
|
716
|
+
word-wrap: break-word;
|
|
717
|
+
line-height: normal;
|
|
718
|
+
font-style: normal;
|
|
719
|
+
font-weight: normal;
|
|
720
|
+
letter-spacing: normal;
|
|
721
|
+
pointer-events: none;
|
|
722
|
+
overflow: auto;
|
|
723
|
+
max-width: min(33em, 66vw);
|
|
724
|
+
overscroll-behavior: contain;
|
|
725
|
+
}
|
|
726
|
+
.ace_tooltip pre {
|
|
727
|
+
white-space: pre-wrap;
|
|
728
|
+
}
|
|
729
|
+
|
|
730
|
+
.ace_tooltip.ace_dark {
|
|
731
|
+
background-color: #636363;
|
|
732
|
+
color: #fff;
|
|
733
|
+
}
|
|
734
|
+
|
|
735
|
+
.ace_tooltip:focus {
|
|
736
|
+
outline: 1px solid #5E9ED6;
|
|
737
|
+
}
|
|
738
|
+
|
|
739
|
+
.ace_icon {
|
|
740
|
+
display: inline-block;
|
|
741
|
+
width: 18px;
|
|
742
|
+
vertical-align: top;
|
|
743
|
+
}
|
|
744
|
+
|
|
745
|
+
.ace_icon_svg {
|
|
746
|
+
display: inline-block;
|
|
747
|
+
width: 12px;
|
|
748
|
+
vertical-align: top;
|
|
749
|
+
-webkit-mask-repeat: no-repeat;
|
|
750
|
+
-webkit-mask-size: 12px;
|
|
751
|
+
-webkit-mask-position: center;
|
|
752
|
+
}
|
|
753
|
+
|
|
754
|
+
.ace_folding-enabled > .ace_gutter-cell, .ace_folding-enabled > .ace_gutter-cell_svg-icons {
|
|
755
|
+
padding-right: 13px;
|
|
756
|
+
}
|
|
757
|
+
|
|
758
|
+
.ace_fold-widget, .ace_custom-widget {
|
|
759
|
+
box-sizing: border-box;
|
|
760
|
+
|
|
761
|
+
margin: 0 -12px 0 1px;
|
|
762
|
+
display: none;
|
|
763
|
+
width: 11px;
|
|
764
|
+
vertical-align: top;
|
|
765
|
+
|
|
766
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");
|
|
767
|
+
background-repeat: no-repeat;
|
|
768
|
+
background-position: center;
|
|
769
|
+
|
|
770
|
+
border-radius: 3px;
|
|
771
|
+
|
|
772
|
+
border: 1px solid transparent;
|
|
773
|
+
cursor: pointer;
|
|
774
|
+
pointer-events: auto;
|
|
775
|
+
}
|
|
776
|
+
|
|
777
|
+
.ace_custom-widget {
|
|
778
|
+
background: none;
|
|
779
|
+
}
|
|
780
|
+
|
|
781
|
+
.ace_folding-enabled .ace_fold-widget {
|
|
782
|
+
display: inline-block;
|
|
783
|
+
}
|
|
784
|
+
|
|
785
|
+
.ace_fold-widget.ace_end {
|
|
786
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");
|
|
787
|
+
}
|
|
788
|
+
|
|
789
|
+
.ace_fold-widget.ace_closed {
|
|
790
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");
|
|
791
|
+
}
|
|
792
|
+
|
|
793
|
+
.ace_fold-widget:hover {
|
|
794
|
+
border: 1px solid rgba(0, 0, 0, 0.3);
|
|
795
|
+
background-color: rgba(255, 255, 255, 0.2);
|
|
796
|
+
box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);
|
|
797
|
+
}
|
|
798
|
+
|
|
799
|
+
.ace_fold-widget:active {
|
|
800
|
+
border: 1px solid rgba(0, 0, 0, 0.4);
|
|
801
|
+
background-color: rgba(0, 0, 0, 0.05);
|
|
802
|
+
box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);
|
|
803
|
+
}
|
|
804
|
+
/**
|
|
805
|
+
* Dark version for fold widgets
|
|
806
|
+
*/
|
|
807
|
+
.ace_dark .ace_fold-widget {
|
|
808
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");
|
|
809
|
+
}
|
|
810
|
+
.ace_dark .ace_fold-widget.ace_end {
|
|
811
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");
|
|
812
|
+
}
|
|
813
|
+
.ace_dark .ace_fold-widget.ace_closed {
|
|
814
|
+
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");
|
|
815
|
+
}
|
|
816
|
+
.ace_dark .ace_fold-widget:hover {
|
|
817
|
+
box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
|
|
818
|
+
background-color: rgba(255, 255, 255, 0.1);
|
|
819
|
+
}
|
|
820
|
+
.ace_dark .ace_fold-widget:active {
|
|
821
|
+
box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
|
|
822
|
+
}
|
|
823
|
+
|
|
824
|
+
.ace_inline_button {
|
|
825
|
+
border: 1px solid lightgray;
|
|
826
|
+
display: inline-block;
|
|
827
|
+
margin: -1px 8px;
|
|
828
|
+
padding: 0 5px;
|
|
829
|
+
pointer-events: auto;
|
|
830
|
+
cursor: pointer;
|
|
831
|
+
}
|
|
832
|
+
.ace_inline_button:hover {
|
|
833
|
+
border-color: gray;
|
|
834
|
+
background: rgba(200,200,200,0.2);
|
|
835
|
+
display: inline-block;
|
|
836
|
+
pointer-events: auto;
|
|
837
|
+
}
|
|
838
|
+
|
|
839
|
+
.ace_fold-widget.ace_invalid {
|
|
840
|
+
background-color: #FFB4B4;
|
|
841
|
+
border-color: #DE5555;
|
|
842
|
+
}
|
|
843
|
+
|
|
844
|
+
.ace_fade-fold-widgets .ace_fold-widget {
|
|
845
|
+
transition: opacity 0.4s ease 0.05s;
|
|
846
|
+
opacity: 0;
|
|
847
|
+
}
|
|
848
|
+
|
|
849
|
+
.ace_fade-fold-widgets:hover .ace_fold-widget {
|
|
850
|
+
transition: opacity 0.05s ease 0.05s;
|
|
851
|
+
opacity:1;
|
|
852
|
+
}
|
|
853
|
+
|
|
854
|
+
.ace_underline {
|
|
855
|
+
text-decoration: underline;
|
|
856
|
+
}
|
|
857
|
+
|
|
858
|
+
.ace_bold {
|
|
859
|
+
font-weight: bold;
|
|
860
|
+
}
|
|
861
|
+
|
|
862
|
+
.ace_nobold .ace_bold {
|
|
863
|
+
font-weight: normal;
|
|
864
|
+
}
|
|
865
|
+
|
|
866
|
+
.ace_italic {
|
|
867
|
+
font-style: italic;
|
|
868
|
+
}
|
|
869
|
+
|
|
870
|
+
|
|
871
|
+
.ace_error-marker {
|
|
872
|
+
background-color: rgba(255, 0, 0,0.2);
|
|
873
|
+
position: absolute;
|
|
874
|
+
z-index: 9;
|
|
875
|
+
}
|
|
876
|
+
|
|
877
|
+
.ace_highlight-marker {
|
|
878
|
+
background-color: rgba(255, 255, 0,0.2);
|
|
879
|
+
position: absolute;
|
|
880
|
+
z-index: 8;
|
|
881
|
+
}
|
|
882
|
+
|
|
883
|
+
.ace_mobile-menu {
|
|
884
|
+
position: absolute;
|
|
885
|
+
line-height: 1.5;
|
|
886
|
+
border-radius: 4px;
|
|
887
|
+
-ms-user-select: none;
|
|
888
|
+
-moz-user-select: none;
|
|
889
|
+
-webkit-user-select: none;
|
|
890
|
+
user-select: none;
|
|
891
|
+
background: white;
|
|
892
|
+
box-shadow: 1px 3px 2px grey;
|
|
893
|
+
border: 1px solid #dcdcdc;
|
|
894
|
+
color: black;
|
|
895
|
+
}
|
|
896
|
+
.ace_dark > .ace_mobile-menu {
|
|
897
|
+
background: #333;
|
|
898
|
+
color: #ccc;
|
|
899
|
+
box-shadow: 1px 3px 2px grey;
|
|
900
|
+
border: 1px solid #444;
|
|
901
|
+
|
|
902
|
+
}
|
|
903
|
+
.ace_mobile-button {
|
|
904
|
+
padding: 2px;
|
|
905
|
+
cursor: pointer;
|
|
906
|
+
overflow: hidden;
|
|
907
|
+
}
|
|
908
|
+
.ace_mobile-button:hover {
|
|
909
|
+
background-color: #eee;
|
|
910
|
+
opacity:1;
|
|
911
|
+
}
|
|
912
|
+
.ace_mobile-button:active {
|
|
913
|
+
background-color: #ddd;
|
|
914
|
+
}
|
|
915
|
+
|
|
916
|
+
.ace_placeholder {
|
|
917
|
+
position: relative;
|
|
918
|
+
font-family: arial;
|
|
919
|
+
transform: scale(0.9);
|
|
920
|
+
transform-origin: left;
|
|
921
|
+
white-space: pre;
|
|
922
|
+
opacity: 0.7;
|
|
923
|
+
margin: 0 10px;
|
|
924
|
+
z-index: 1;
|
|
925
|
+
}
|
|
926
|
+
|
|
927
|
+
.ace_ghost_text {
|
|
928
|
+
opacity: 0.5;
|
|
929
|
+
font-style: italic;
|
|
930
|
+
}
|
|
931
|
+
|
|
932
|
+
.ace_ghost_text_container > div {
|
|
933
|
+
white-space: pre;
|
|
934
|
+
}
|
|
935
|
+
|
|
936
|
+
.ghost_text_line_wrapped::after {
|
|
937
|
+
content: "↩";
|
|
938
|
+
position: absolute;
|
|
939
|
+
}
|
|
940
|
+
|
|
941
|
+
.ace_lineWidgetContainer.ace_ghost_text {
|
|
942
|
+
margin: 0px 4px
|
|
943
|
+
}
|
|
944
|
+
|
|
945
|
+
.ace_screenreader-only {
|
|
946
|
+
position:absolute;
|
|
947
|
+
left:-10000px;
|
|
948
|
+
top:auto;
|
|
949
|
+
width:1px;
|
|
950
|
+
height:1px;
|
|
951
|
+
overflow:hidden;
|
|
952
|
+
}
|
|
953
|
+
|
|
954
|
+
.ace_hidden_token {
|
|
955
|
+
display: none;
|
|
956
|
+
}`}),ace.define("ace/layer/decorators",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter"],function(t,r,l){var d=t("../lib/dom"),h=t("../lib/oop"),b=t("../lib/event_emitter").EventEmitter,p=function(){function g(o,c){this.renderer=c,this.pixelRatio=1,this.maxHeight=c.layerConfig.maxHeight,this.lineHeight=c.layerConfig.lineHeight,this.minDecorationHeight=2*this.pixelRatio|0,this.halfMinDecorationHeight=this.minDecorationHeight/2|0,this.colors={},this.colors.dark={error:"rgba(255, 18, 18, 1)",warning:"rgba(18, 136, 18, 1)",info:"rgba(18, 18, 136, 1)"},this.colors.light={error:"rgb(255,51,51)",warning:"rgb(32,133,72)",info:"rgb(35,68,138)"},this.setScrollBarV(o)}return g.prototype.$createCanvas=function(){this.canvas=d.createElement("canvas"),this.canvas.style.top="0px",this.canvas.style.right="0px",this.canvas.style.zIndex="7",this.canvas.style.position="absolute"},g.prototype.setScrollBarV=function(o){this.$createCanvas(),this.scrollbarV=o,o.element.appendChild(this.canvas),this.setDimensions()},g.prototype.$updateDecorators=function(o){if(typeof this.canvas.getContext!="function")return;var c=this.renderer.theme.isDark===!0?this.colors.dark:this.colors.light;this.setDimensions(o);var f=this.canvas.getContext("2d");function u(N,A){return N.priority<A.priority?-1:N.priority>A.priority?1:0}var i=this.renderer.session.$annotations;if(f.clearRect(0,0,this.canvas.width,this.canvas.height),i){var a={info:1,warning:2,error:3};i.forEach(function(N){N.priority=a[N.type]||null}),i=i.sort(u);for(var m=0;m<i.length;m++){var w=i[m].row,x=this.getVerticalOffsetForRow(w),M=x+this.lineHeight,$=Math.round(this.heightRatio*x),S=Math.round(this.heightRatio*M),k=Math.round(($+S)/2),T=S-k;T<this.halfMinDecorationHeight&&(T=this.halfMinDecorationHeight),k-T<0&&(k=T),k+T>this.canvasHeight&&(k=this.canvasHeight-T);var D=k-T,L=k+T,O=L-D;f.fillStyle=c[i[m].type]||null,f.fillRect(0,D,Math.round(this.oneZoneWidth-1),O)}}var z=this.renderer.session.selection.getCursor();if(z){var P=Math.round(this.getVerticalOffsetForRow(z.row)*this.heightRatio);f.fillStyle="rgba(0, 0, 0, 0.5)",f.fillRect(0,P,this.canvasWidth,2)}},g.prototype.getVerticalOffsetForRow=function(o){o=o|0;var c=this.renderer.session.documentToScreenRow(o,0)*this.lineHeight;return c},g.prototype.setDimensions=function(o){o=o||this.renderer.layerConfig,this.maxHeight=o.maxHeight,this.lineHeight=o.lineHeight,this.canvasHeight=o.height,this.canvasWidth=this.scrollbarV.width||this.canvasWidth,this.setZoneWidth(),this.canvas.width=this.canvasWidth,this.canvas.height=this.canvasHeight,this.maxHeight<this.canvasHeight?this.heightRatio=1:this.heightRatio=this.canvasHeight/this.maxHeight},g.prototype.setZoneWidth=function(){this.oneZoneWidth=this.canvasWidth},g.prototype.destroy=function(){this.canvas.parentNode.removeChild(this.canvas)},g}();h.implement(p.prototype,b),r.Decorator=p}),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/config","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/scrollbar_custom","ace/scrollbar_custom","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter","ace/css/editor-css","ace/layer/decorators","ace/lib/useragent","ace/layer/text_util"],function(t,r,l){var d=t("./lib/oop"),h=t("./lib/dom"),b=t("./lib/lang"),p=t("./config"),g=t("./layer/gutter").Gutter,o=t("./layer/marker").Marker,c=t("./layer/text").Text,f=t("./layer/cursor").Cursor,u=t("./scrollbar").HScrollBar,i=t("./scrollbar").VScrollBar,a=t("./scrollbar_custom").HScrollBar,m=t("./scrollbar_custom").VScrollBar,w=t("./renderloop").RenderLoop,x=t("./layer/font_metrics").FontMetrics,M=t("./lib/event_emitter").EventEmitter,$=t("./css/editor-css"),S=t("./layer/decorators").Decorator,k=t("./lib/useragent"),T=t("./layer/text_util").isTextToken;h.importCssString($,"ace_editor.css",!1);var D=function(){function L(O,z){var P=this;this.container=O||h.createElement("div"),h.addCssClass(this.container,"ace_editor"),h.HI_DPI&&h.addCssClass(this.container,"ace_hidpi"),this.setTheme(z),p.get("useStrictCSP")==null&&p.set("useStrictCSP",!1),this.$gutter=h.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden","true"),this.scroller=h.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=h.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new g(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new o(this.content);var N=this.$textLayer=new c(this.content);this.canvas=N.element,this.$markerFront=new o(this.content),this.$cursorLayer=new f(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new i(this.container,this),this.scrollBarH=new u(this.container,this),this.scrollBarV.on("scroll",function(A){P.$scrollAnimation||P.session.setScrollTop(A.data-P.scrollMargin.top)}),this.scrollBarH.on("scroll",function(A){P.$scrollAnimation||P.session.setScrollLeft(A.data-P.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new x(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",function(A){P.updateCharacterSize(),P.onResize(!0,P.gutterWidth,P.$size.width,P.$size.height),P._signal("changeCharacterSize",A)}),this.$size={width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0},this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.margin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.$keepTextAreaAtCursor=!k.isIOS,this.$loop=new w(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),this.$addResizeObserver(),p.resetOptions(this),p._signal("renderer",this)}return L.prototype.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts)),this.layerConfig.characterWidth=this.characterWidth=this.$textLayer.getCharacterWidth(),this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight(),this.$updatePrintMargin(),h.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},L.prototype.setSession=function(O){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=O,O&&this.scrollMargin.top&&O.getScrollTop()<=0&&O.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(O),this.$markerBack.setSession(O),this.$markerFront.setSession(O),this.$gutterLayer.setSession(O),this.$textLayer.setSession(O),O&&(this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode))},L.prototype.updateLines=function(O,z,P){if(z===void 0&&(z=1/0),this.$changedLines?(this.$changedLines.firstRow>O&&(this.$changedLines.firstRow=O),this.$changedLines.lastRow<z&&(this.$changedLines.lastRow=z)):this.$changedLines={firstRow:O,lastRow:z},this.$changedLines.lastRow<this.layerConfig.firstRow)if(P)this.$changedLines.lastRow=this.layerConfig.lastRow;else return;this.$changedLines.firstRow>this.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},L.prototype.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},L.prototype.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},L.prototype.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},L.prototype.updateFull=function(O){O?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},L.prototype.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},L.prototype.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},L.prototype.onResize=function(O,z,P,N){if(!(this.resizing>2)){this.resizing>0?this.resizing++:this.resizing=O?1:0;var A=this.container;N||(N=A.clientHeight||A.scrollHeight),!N&&this.$maxLines&&this.lineHeight>1&&(!A.style.height||A.style.height=="0px")&&(A.style.height="1px",N=A.clientHeight||A.scrollHeight),P||(P=A.clientWidth||A.scrollWidth);var _=this.$updateCachedSize(O,z,P,N);if(this.$resizeTimer&&this.$resizeTimer.cancel(),!this.$size.scrollerHeight||!P&&!N)return this.resizing=0;O&&(this.$gutterLayer.$padding=null),O?this.$renderChanges(_|this.$changes,!0):this.$loop.schedule(_|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.$customScrollbar&&this.$updateCustomScrollbar(!0)}},L.prototype.$updateCachedSize=function(O,z,P,N){N-=this.$extraHeight||0;var A=0,_=this.$size,I={width:_.width,height:_.height,scrollerHeight:_.scrollerHeight,scrollerWidth:_.scrollerWidth};if(N&&(O||_.height!=N)&&(_.height=N,A|=this.CHANGE_SIZE,_.scrollerHeight=_.height,this.$horizScroll&&(_.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.setHeight(_.scrollerHeight),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",A=A|this.CHANGE_SCROLL),P&&(O||_.width!=P)){A|=this.CHANGE_SIZE,_.width=P,z==null&&(z=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=z,h.setStyle(this.scrollBarH.element.style,"left",z+"px"),h.setStyle(this.scroller.style,"left",z+this.margin.left+"px"),_.scrollerWidth=Math.max(0,P-z-this.scrollBarV.getWidth()-this.margin.h),h.setStyle(this.$gutter.style,"left",this.margin.left+"px");var j=this.scrollBarV.getWidth()+"px";h.setStyle(this.scrollBarH.element.style,"right",j),h.setStyle(this.scroller.style,"right",j),h.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),this.scrollBarH.setWidth(_.scrollerWidth),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||O)&&(A|=this.CHANGE_FULL)}return _.$dirty=!P||!N,A&&this._signal("resize",I),A},L.prototype.onGutterResize=function(O){var z=this.$showGutter?O:0;z!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,z,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()?this.$loop.schedule(this.CHANGE_FULL):this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):this.$computeLayerConfig()},L.prototype.adjustWrapLimit=function(){var O=this.$size.scrollerWidth-this.$padding*2,z=Math.floor(O/this.characterWidth);return this.session.adjustWrapLimit(z,this.$showPrintMargin&&this.$printMarginColumn)},L.prototype.setAnimatedScroll=function(O){this.setOption("animatedScroll",O)},L.prototype.getAnimatedScroll=function(){return this.$animatedScroll},L.prototype.setShowInvisibles=function(O){this.setOption("showInvisibles",O),this.session.$bidiHandler.setShowInvisibles(O)},L.prototype.getShowInvisibles=function(){return this.getOption("showInvisibles")},L.prototype.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},L.prototype.setDisplayIndentGuides=function(O){this.setOption("displayIndentGuides",O)},L.prototype.getHighlightIndentGuides=function(){return this.getOption("highlightIndentGuides")},L.prototype.setHighlightIndentGuides=function(O){this.setOption("highlightIndentGuides",O)},L.prototype.setShowPrintMargin=function(O){this.setOption("showPrintMargin",O)},L.prototype.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},L.prototype.setPrintMarginColumn=function(O){this.setOption("printMarginColumn",O)},L.prototype.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},L.prototype.getShowGutter=function(){return this.getOption("showGutter")},L.prototype.setShowGutter=function(O){return this.setOption("showGutter",O)},L.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},L.prototype.setFadeFoldWidgets=function(O){this.setOption("fadeFoldWidgets",O)},L.prototype.setHighlightGutterLine=function(O){this.setOption("highlightGutterLine",O)},L.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},L.prototype.$updatePrintMargin=function(){if(!(!this.$showPrintMargin&&!this.$printMarginEl)){if(!this.$printMarginEl){var O=h.createElement("div");O.className="ace_layer ace_print-margin-layer",this.$printMarginEl=h.createElement("div"),this.$printMarginEl.className="ace_print-margin",O.appendChild(this.$printMarginEl),this.content.insertBefore(O,this.content.firstChild)}var z=this.$printMarginEl.style;z.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",z.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit()}},L.prototype.getContainerElement=function(){return this.container},L.prototype.getMouseEventTarget=function(){return this.scroller},L.prototype.getTextAreaContainer=function(){return this.container},L.prototype.$moveTextAreaToCursor=function(){if(!this.$isMousePressed){var O=this.textarea.style,z=this.$composition;if(!this.$keepTextAreaAtCursor&&!z){h.translate(this.textarea,-100,0);return}var P=this.$cursorLayer.$pixelPos;if(P){z&&z.markerRange&&(P=this.$cursorLayer.getPixelPosition(z.markerRange.start,!0));var N=this.layerConfig,A=P.top,_=P.left;A-=N.offset;var I=z&&z.useTextareaForIME||k.isMobile?this.lineHeight:1;if(A<0||A>N.height-I){h.translate(this.textarea,0,0);return}var j=1,U=this.$size.height-I;if(!z)A+=this.lineHeight;else if(z.useTextareaForIME){var K=this.textarea.value;j=this.characterWidth*this.session.$getStringScreenWidth(K)[0]}else A+=this.lineHeight+2;_-=this.scrollLeft,_>this.$size.scrollerWidth-j&&(_=this.$size.scrollerWidth-j),_+=this.gutterWidth+this.margin.left,h.setStyle(O,"height",I+"px"),h.setStyle(O,"width",j+"px"),h.translate(this.textarea,Math.min(_,this.$size.scrollerWidth-j),Math.min(A,U))}}},L.prototype.getFirstVisibleRow=function(){return this.layerConfig.firstRow},L.prototype.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},L.prototype.getLastFullyVisibleRow=function(){var O=this.layerConfig,z=O.lastRow,P=this.session.documentToScreenRow(z,0)*O.lineHeight;return P-this.session.getScrollTop()>O.height-O.lineHeight?z-1:z},L.prototype.getLastVisibleRow=function(){return this.layerConfig.lastRow},L.prototype.setPadding=function(O){this.$padding=O,this.$textLayer.setPadding(O),this.$cursorLayer.setPadding(O),this.$markerFront.setPadding(O),this.$markerBack.setPadding(O),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},L.prototype.setScrollMargin=function(O,z,P,N){var A=this.scrollMargin;A.top=O|0,A.bottom=z|0,A.right=N|0,A.left=P|0,A.v=A.top+A.bottom,A.h=A.left+A.right,A.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-A.top),this.updateFull()},L.prototype.setMargin=function(O,z,P,N){var A=this.margin;A.top=O|0,A.bottom=z|0,A.right=N|0,A.left=P|0,A.v=A.top+A.bottom,A.h=A.left+A.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},L.prototype.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},L.prototype.setHScrollBarAlwaysVisible=function(O){this.setOption("hScrollBarAlwaysVisible",O)},L.prototype.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},L.prototype.setVScrollBarAlwaysVisible=function(O){this.setOption("vScrollBarAlwaysVisible",O)},L.prototype.$updateScrollBarV=function(){var O=this.layerConfig.maxHeight,z=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(O-=(z-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>O-z&&(O=this.scrollTop+z,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(O+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},L.prototype.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},L.prototype.freeze=function(){this.$frozen=!0},L.prototype.unfreeze=function(){this.$frozen=!1},L.prototype.$renderChanges=function(O,z){if(this.$changes&&(O|=this.$changes,this.$changes=0),!this.session||!this.container.offsetWidth||this.$frozen||!O&&!z){this.$changes|=O;return}if(this.$size.$dirty)return this.$changes|=O,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",O),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var P=this.layerConfig;if(O&this.CHANGE_FULL||O&this.CHANGE_SIZE||O&this.CHANGE_TEXT||O&this.CHANGE_LINES||O&this.CHANGE_SCROLL||O&this.CHANGE_H_SCROLL){if(O|=this.$computeLayerConfig()|this.$loop.clear(),P.firstRow!=this.layerConfig.firstRow&&P.firstRowScreen==this.layerConfig.firstRowScreen){var N=this.scrollTop+(P.firstRow-Math.max(this.layerConfig.firstRow,0))*this.lineHeight;N>0&&(this.scrollTop=N,O=O|this.CHANGE_SCROLL,O|=this.$computeLayerConfig()|this.$loop.clear())}P=this.layerConfig,this.$updateScrollBarV(),O&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),h.translate(this.content,-this.scrollLeft,-P.offset);var A=P.width+2*this.$padding+"px",_=P.minHeight+"px";h.setStyle(this.content.style,"width",A),h.setStyle(this.content.style,"height",_)}if(O&this.CHANGE_H_SCROLL&&(h.translate(this.content,-this.scrollLeft,-P.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller ":"ace_scroller ace_scroll-left ",this.enableKeyboardAccessibility&&(this.scroller.className+=this.keyboardFocusClassName)),O&this.CHANGE_FULL){this.$changedLines=null,this.$textLayer.update(P),this.$showGutter&&this.$gutterLayer.update(P),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(P),this.$markerBack.update(P),this.$markerFront.update(P),this.$cursorLayer.update(P),this.$moveTextAreaToCursor(),this._signal("afterRender",O);return}if(O&this.CHANGE_SCROLL){this.$changedLines=null,O&this.CHANGE_TEXT||O&this.CHANGE_LINES?this.$textLayer.update(P):this.$textLayer.scrollLines(P),this.$showGutter&&(O&this.CHANGE_GUTTER||O&this.CHANGE_LINES?this.$gutterLayer.update(P):this.$gutterLayer.scrollLines(P)),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(P),this.$markerBack.update(P),this.$markerFront.update(P),this.$cursorLayer.update(P),this.$moveTextAreaToCursor(),this._signal("afterRender",O);return}O&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(P),this.$showGutter&&this.$gutterLayer.update(P),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(P)):O&this.CHANGE_LINES?((this.$updateLines()||O&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(P),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(P)):O&this.CHANGE_TEXT||O&this.CHANGE_GUTTER?(this.$showGutter&&this.$gutterLayer.update(P),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(P)):O&this.CHANGE_CURSOR&&(this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(P),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(P)),O&this.CHANGE_CURSOR&&(this.$cursorLayer.update(P),this.$moveTextAreaToCursor()),O&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(P),O&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(P),this._signal("afterRender",O)},L.prototype.$autosize=function(){var O=this.session.getScreenLength()*this.lineHeight,z=this.$maxLines*this.lineHeight,P=Math.min(z,Math.max((this.$minLines||1)*this.lineHeight,O))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(P+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&P>this.$maxPixelHeight&&(P=this.$maxPixelHeight);var N=P<=2*this.lineHeight,A=!N&&O>z;if(P!=this.desiredHeight||this.$size.height!=this.desiredHeight||A!=this.$vScroll){A!=this.$vScroll&&(this.$vScroll=A,this.scrollBarV.setVisible(A));var _=this.container.clientWidth;this.container.style.height=P+"px",this.$updateCachedSize(!0,this.$gutterWidth,_,P),this.desiredHeight=P,this._signal("autosize")}},L.prototype.$computeLayerConfig=function(){var O=this.session,z=this.$size,P=z.height<=2*this.lineHeight,N=this.session.getScreenLength(),A=N*this.lineHeight,_=this.$getLongestLine(),I=!P&&(this.$hScrollBarAlwaysVisible||z.scrollerWidth-_-2*this.$padding<0),j=this.$horizScroll!==I;j&&(this.$horizScroll=I,this.scrollBarH.setVisible(I));var U=this.$vScroll;this.$maxLines&&this.lineHeight>1&&(this.$autosize(),P=z.height<=2*this.lineHeight);var K=z.scrollerHeight+this.lineHeight,Z=!this.$maxLines&&this.$scrollPastEnd?(z.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;A+=Z;var J=this.scrollMargin;this.session.setScrollTop(Math.max(-J.top,Math.min(this.scrollTop,A-z.scrollerHeight+J.bottom))),this.session.setScrollLeft(Math.max(-J.left,Math.min(this.scrollLeft,_+2*this.$padding-z.scrollerWidth+J.right)));var ae=!P&&(this.$vScrollBarAlwaysVisible||z.scrollerHeight-A+Z<0||this.scrollTop>J.top),ne=U!==ae;ne&&(this.$vScroll=ae,this.scrollBarV.setVisible(ae));var se=this.scrollTop%this.lineHeight,ce=Math.ceil(K/this.lineHeight)-1,he=Math.max(0,Math.round((this.scrollTop-se)/this.lineHeight)),ge=he+ce,Ee,Te,Me=this.lineHeight;he=O.screenToDocumentRow(he,0);var Xe=O.getFoldLine(he);Xe&&(he=Xe.start.row),Ee=O.documentToScreenRow(he,0),Te=O.getRowLength(he)*Me,ge=Math.min(O.screenToDocumentRow(ge,0),O.getLength()-1),K=z.scrollerHeight+O.getRowLength(ge)*Me+Te,se=this.scrollTop-Ee*Me,se<0&&Ee>0&&(Ee=Math.max(0,Ee+Math.floor(se/Me)),se=this.scrollTop-Ee*Me);var Ke=0;return(this.layerConfig.width!=_||j)&&(Ke=this.CHANGE_H_SCROLL),(j||ne)&&(Ke|=this.$updateCachedSize(!0,this.gutterWidth,z.width,z.height),this._signal("scrollbarVisibilityChanged"),ne&&(_=this.$getLongestLine())),this.layerConfig={width:_,padding:this.$padding,firstRow:he,firstRowScreen:Ee,lastRow:ge,lineHeight:Me,characterWidth:this.characterWidth,minHeight:K,maxHeight:A,offset:se,gutterOffset:Me?Math.max(0,Math.ceil((se+z.height-z.scrollerHeight)/Me)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(_-this.$padding),Ke},L.prototype.$updateLines=function(){if(this.$changedLines){var O=this.$changedLines.firstRow,z=this.$changedLines.lastRow;this.$changedLines=null;var P=this.layerConfig;if(!(O>P.lastRow+1)&&!(z<P.firstRow)){if(z===1/0){this.$showGutter&&this.$gutterLayer.update(P),this.$textLayer.update(P);return}return this.$textLayer.updateLines(P,O,z),!0}}},L.prototype.$getLongestLine=function(){var O=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(O+=1),this.$textLayer&&O>this.$textLayer.MAX_LINE_LENGTH&&(O=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(O*this.characterWidth))},L.prototype.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},L.prototype.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},L.prototype.addGutterDecoration=function(O,z){this.$gutterLayer.addGutterDecoration(O,z)},L.prototype.removeGutterDecoration=function(O,z){this.$gutterLayer.removeGutterDecoration(O,z)},L.prototype.updateBreakpoints=function(O){this._rows=O,this.$loop.schedule(this.CHANGE_GUTTER)},L.prototype.setAnnotations=function(O){this.$gutterLayer.setAnnotations(O),this.$loop.schedule(this.CHANGE_GUTTER)},L.prototype.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},L.prototype.hideCursor=function(){this.$cursorLayer.hideCursor()},L.prototype.showCursor=function(){this.$cursorLayer.showCursor()},L.prototype.scrollSelectionIntoView=function(O,z,P){this.scrollCursorIntoView(O,P),this.scrollCursorIntoView(z,P)},L.prototype.scrollCursorIntoView=function(O,z,P){if(this.$size.scrollerHeight!==0){var N=this.$cursorLayer.getPixelPosition(O),A=N.left,_=N.top,I=P&&P.top||0,j=P&&P.bottom||0;this.$scrollAnimation&&(this.$stopAnimation=!0);var U=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;U+I>_?(z&&U+I>_+this.lineHeight&&(_-=z*this.$size.scrollerHeight),_===0&&(_=-this.scrollMargin.top),this.session.setScrollTop(_)):U+this.$size.scrollerHeight-j<_+this.lineHeight&&(z&&U+this.$size.scrollerHeight-j<_-this.lineHeight&&(_+=z*this.$size.scrollerHeight),this.session.setScrollTop(_+this.lineHeight+j-this.$size.scrollerHeight));var K=this.scrollLeft,Z=2*this.layerConfig.characterWidth;A-Z<K?(A-=Z,A<this.$padding+Z&&(A=-this.scrollMargin.left),this.session.setScrollLeft(A)):(A+=Z,K+this.$size.scrollerWidth<A+this.characterWidth?this.session.setScrollLeft(Math.round(A+this.characterWidth-this.$size.scrollerWidth)):K<=this.$padding&&A-K<this.characterWidth&&this.session.setScrollLeft(0))}},L.prototype.getScrollTop=function(){return this.session.getScrollTop()},L.prototype.getScrollLeft=function(){return this.session.getScrollLeft()},L.prototype.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},L.prototype.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},L.prototype.scrollToRow=function(O){this.session.setScrollTop(O*this.lineHeight)},L.prototype.alignCursor=function(O,z){typeof O=="number"&&(O={row:O,column:0});var P=this.$cursorLayer.getPixelPosition(O),N=this.$size.scrollerHeight-this.lineHeight,A=P.top-N*(z||0);return this.session.setScrollTop(A),A},L.prototype.$calcSteps=function(O,z){var P=0,N=this.STEPS,A=[],_=function(I,j,U){return U*(Math.pow(I-1,3)+1)+j};for(P=0;P<N;++P)A.push(_(P/this.STEPS,O,z-O));return A},L.prototype.scrollToLine=function(O,z,P,N){var A=this.$cursorLayer.getPixelPosition({row:O,column:0}),_=A.top;z&&(_-=this.$size.scrollerHeight/2);var I=this.scrollTop;this.session.setScrollTop(_),P!==!1&&this.animateScrolling(I,N)},L.prototype.animateScrolling=function(O,z){var P=this.scrollTop;if(!this.$animatedScroll)return;var N=this;if(O==P)return;if(this.$scrollAnimation){var A=this.$scrollAnimation.steps;if(A.length&&(O=A[0],O==P))return}var _=N.$calcSteps(O,P);this.$scrollAnimation={from:O,to:P,steps:_},clearInterval(this.$timer),N.session.setScrollTop(_.shift()),N.session.$scrollTop=P;function I(){N.$timer=clearInterval(N.$timer),N.$scrollAnimation=null,N.$stopAnimation=!1,z&&z()}this.$timer=setInterval(function(){if(N.$stopAnimation){I();return}if(!N.session)return clearInterval(N.$timer);_.length?(N.session.setScrollTop(_.shift()),N.session.$scrollTop=P):P!=null?(N.session.$scrollTop=-1,N.session.setScrollTop(P),P=null):I()},10)},L.prototype.scrollToY=function(O){this.scrollTop!==O&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=O)},L.prototype.scrollToX=function(O){this.scrollLeft!==O&&(this.scrollLeft=O),this.$loop.schedule(this.CHANGE_H_SCROLL)},L.prototype.scrollTo=function(O,z){this.session.setScrollTop(z),this.session.setScrollLeft(O)},L.prototype.scrollBy=function(O,z){z&&this.session.setScrollTop(this.session.getScrollTop()+z),O&&this.session.setScrollLeft(this.session.getScrollLeft()+O)},L.prototype.isScrollableBy=function(O,z){if(z<0&&this.session.getScrollTop()>=1-this.scrollMargin.top||z>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||O<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||O>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0},L.prototype.pixelToScreenCoordinates=function(O,z){var P;if(this.$hasCssTransforms){P={top:0,left:0};var N=this.$fontMetrics.transformCoordinates([O,z]);O=N[1]-this.gutterWidth-this.margin.left,z=N[0]}else P=this.scroller.getBoundingClientRect();var A=O+this.scrollLeft-P.left-this.$padding,_=A/this.characterWidth,I=Math.floor((z+this.scrollTop-P.top)/this.lineHeight),j=this.$blockCursor?Math.floor(_):Math.round(_);return{row:I,column:j,side:_-j>0?1:-1,offsetX:A}},L.prototype.screenToTextCoordinates=function(O,z){var P;if(this.$hasCssTransforms){P={top:0,left:0};var N=this.$fontMetrics.transformCoordinates([O,z]);O=N[1]-this.gutterWidth-this.margin.left,z=N[0]}else P=this.scroller.getBoundingClientRect();var A=O+this.scrollLeft-P.left-this.$padding,_=A/this.characterWidth,I=this.$blockCursor?Math.floor(_):Math.round(_),j=Math.floor((z+this.scrollTop-P.top)/this.lineHeight);return this.session.screenToDocumentPosition(j,Math.max(I,0),A)},L.prototype.textToScreenCoordinates=function(O,z){var P=this.scroller.getBoundingClientRect(),N=this.session.documentToScreenPosition(O,z),A=this.$padding+(this.session.$bidiHandler.isBidiRow(N.row,O)?this.session.$bidiHandler.getPosLeft(N.column):Math.round(N.column*this.characterWidth)),_=N.row*this.lineHeight;return{pageX:P.left+A-this.scrollLeft,pageY:P.top+_-this.scrollTop}},L.prototype.visualizeFocus=function(){h.addCssClass(this.container,"ace_focus")},L.prototype.visualizeBlur=function(){h.removeCssClass(this.container,"ace_focus")},L.prototype.showComposition=function(O){this.$composition=O,O.cssText||(O.cssText=this.textarea.style.cssText),O.useTextareaForIME==null&&(O.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(h.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):O.markerId=this.session.addMarker(O.markerRange,"ace_composition_marker","text")},L.prototype.setCompositionText=function(O){var z=this.session.selection.cursor;this.addToken(O,"composition_placeholder",z.row,z.column),this.$moveTextAreaToCursor()},L.prototype.hideComposition=function(){if(this.$composition){this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),h.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText;var O=this.session.selection.cursor;this.removeExtraToken(O.row,O.column),this.$composition=null,this.$cursorLayer.element.style.display=""}},L.prototype.setGhostText=function(O,z){var P=this.session.selection.cursor,N=z||{row:P.row,column:P.column};this.removeGhostText();var A=this.$calculateWrappedTextChunks(O,N);this.addToken(A[0].text,"ghost_text",N.row,N.column),this.$ghostText={text:O,position:{row:N.row,column:N.column}};var _=h.createElement("div");if(A.length>1){var I=this.hideTokensAfterPosition(N.row,N.column),j;A.slice(1).forEach(function(ne){var se=h.createElement("div"),ce=h.createElement("span");ce.className="ace_ghost_text",ne.wrapped&&(se.className="ghost_text_line_wrapped"),ne.text.length===0&&(ne.text=" "),ce.appendChild(h.createTextNode(ne.text)),se.appendChild(ce),_.appendChild(se),j=se}),I.forEach(function(ne){var se=h.createElement("span");T(ne.type)||(se.className="ace_"+ne.type.replace(/\./g," ace_")),se.appendChild(h.createTextNode(ne.value)),j.appendChild(se)}),this.$ghostTextWidget={el:_,row:N.row,column:N.column,className:"ace_ghost_text_container"},this.session.widgetManager.addLineWidget(this.$ghostTextWidget);var U=this.$cursorLayer.getPixelPosition(N,!0),K=this.container,Z=K.getBoundingClientRect().height,J=A.length*this.lineHeight,ae=J<Z-U.top;if(ae)return;J<Z?this.scrollBy(0,(A.length-1)*this.lineHeight):this.scrollToRow(N.row)}},L.prototype.$calculateWrappedTextChunks=function(O,z){var P=this.$size.scrollerWidth-this.$padding*2,N=Math.floor(P/this.characterWidth)-2;N=N<=0?60:N;for(var A=O.split(/\r?\n/),_=[],I=0;I<A.length;I++){var j=this.session.$getDisplayTokens(A[I],z.column),U=this.session.$computeWrapSplits(j,N,this.session.$tabSize);if(U.length>0){var K=0;U.push(A[I].length);for(var Z=0;Z<U.length;Z++){var J=A[I].slice(K,U[Z]);_.push({text:J,wrapped:!0}),K=U[Z]}}else _.push({text:A[I],wrapped:!1})}return _},L.prototype.removeGhostText=function(){if(this.$ghostText){var O=this.$ghostText.position;this.removeExtraToken(O.row,O.column),this.$ghostTextWidget&&(this.session.widgetManager.removeLineWidget(this.$ghostTextWidget),this.$ghostTextWidget=null),this.$ghostText=null}},L.prototype.addToken=function(O,z,P,N){var A=this.session;A.bgTokenizer.lines[P]=null;var _={type:z,value:O},I=A.getTokens(P);if(N==null||!I.length)I.push(_);else for(var j=0,U=0;U<I.length;U++){var K=I[U];if(j+=K.value.length,N<=j){var Z=K.value.length-(j-N),J=K.value.slice(0,Z),ae=K.value.slice(Z);I.splice(U,1,{type:K.type,value:J},_,{type:K.type,value:ae});break}}this.updateLines(P,P)},L.prototype.hideTokensAfterPosition=function(O,z){for(var P=this.session.getTokens(O),N=0,A=!1,_=[],I=0;I<P.length;I++){var j=P[I];if(N+=j.value.length,j.type!=="ghost_text"){if(A){_.push({type:j.type,value:j.value}),j.type="hidden_token";continue}N===z&&(A=!0)}}return this.updateLines(O,O),_},L.prototype.removeExtraToken=function(O,z){this.session.bgTokenizer.lines[O]=null,this.updateLines(O,O)},L.prototype.setTheme=function(O,z){var P=this;if(this.$themeId=O,P._dispatchEvent("themeChange",{theme:O}),!O||typeof O=="string"){var N=O||this.$options.theme.initialValue;p.loadModule(["theme",N],A)}else A(O);function A(_){if(P.$themeId!=O)return z&&z();if(!_||!_.cssClass)throw new Error("couldn't load module "+O+" or it didn't call define");_.$id&&(P.$themeId=_.$id),h.importCssString(_.cssText,_.cssClass,P.container),P.theme&&h.removeCssClass(P.container,P.theme.cssClass);var I="padding"in _?_.padding:"padding"in(P.theme||{})?4:P.$padding;if(P.$padding&&I!=P.$padding&&P.setPadding(I),P.$gutterLayer){var j=_.$showGutterCursorMarker;j&&!P.$gutterLayer.$showCursorMarker?P.$gutterLayer.$showCursorMarker="theme":!j&&P.$gutterLayer.$showCursorMarker=="theme"&&(P.$gutterLayer.$showCursorMarker=null)}P.$theme=_.cssClass,P.theme=_,h.addCssClass(P.container,_.cssClass),h.setCssClass(P.container,"ace_dark",_.isDark),P.$size&&(P.$size.width=0,P.$updateSizeAsync()),P._dispatchEvent("themeLoaded",{theme:_}),z&&z(),k.isSafari&&P.scroller&&(P.scroller.style.background="red",P.scroller.style.background="")}},L.prototype.getTheme=function(){return this.$themeId},L.prototype.setStyle=function(O,z){h.setCssClass(this.container,O,z!==!1)},L.prototype.unsetStyle=function(O){h.removeCssClass(this.container,O)},L.prototype.setCursorStyle=function(O){h.setStyle(this.scroller.style,"cursor",O)},L.prototype.setMouseCursor=function(O){h.setStyle(this.scroller.style,"cursor",O)},L.prototype.attachToShadowRoot=function(){h.importCssString($,"ace_editor.css",this.container)},L.prototype.destroy=function(){this.freeze(),this.$fontMetrics.destroy(),this.$cursorLayer.destroy(),this.removeAllListeners(),this.container.textContent="",this.setOption("useResizeObserver",!1)},L.prototype.$updateCustomScrollbar=function(O){var z=this;this.$horizScroll=this.$vScroll=null,this.scrollBarV.element.remove(),this.scrollBarH.element.remove(),O===!0?(this.scrollBarV=new m(this.container,this),this.scrollBarH=new a(this.container,this),this.scrollBarV.setHeight(this.$size.scrollerHeight),this.scrollBarH.setWidth(this.$size.scrollerWidth),this.scrollBarV.addEventListener("scroll",function(P){z.$scrollAnimation||z.session.setScrollTop(P.data-z.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(P){z.$scrollAnimation||z.session.setScrollLeft(P.data-z.scrollMargin.left)}),this.$scrollDecorator?(this.$scrollDecorator.setScrollBarV(this.scrollBarV),this.$scrollDecorator.$updateDecorators()):(this.$scrollDecorator=new S(this.scrollBarV,this),this.$scrollDecorator.$updateDecorators())):(this.scrollBarV=new i(this.container,this),this.scrollBarH=new u(this.container,this),this.scrollBarV.addEventListener("scroll",function(P){z.$scrollAnimation||z.session.setScrollTop(P.data-z.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(P){z.$scrollAnimation||z.session.setScrollLeft(P.data-z.scrollMargin.left)}))},L.prototype.$addResizeObserver=function(){if(!(!window.ResizeObserver||this.$resizeObserver)){var O=this;this.$resizeTimer=b.delayedCall(function(){O.destroyed||O.onResize()},50),this.$resizeObserver=new window.ResizeObserver(function(z){var P=z[0].contentRect.width,N=z[0].contentRect.height;Math.abs(O.$size.width-P)>1||Math.abs(O.$size.height-N)>1?O.$resizeTimer.delay():O.$resizeTimer.cancel()}),this.$resizeObserver.observe(this.container)}},L}();D.prototype.CHANGE_CURSOR=1,D.prototype.CHANGE_MARKER=2,D.prototype.CHANGE_GUTTER=4,D.prototype.CHANGE_SCROLL=8,D.prototype.CHANGE_LINES=16,D.prototype.CHANGE_TEXT=32,D.prototype.CHANGE_SIZE=64,D.prototype.CHANGE_MARKER_BACK=128,D.prototype.CHANGE_MARKER_FRONT=256,D.prototype.CHANGE_FULL=512,D.prototype.CHANGE_H_SCROLL=1024,D.prototype.$changes=0,D.prototype.$padding=null,D.prototype.$frozen=!1,D.prototype.STEPS=8,d.implement(D.prototype,M),p.defineOptions(D.prototype,"renderer",{useResizeObserver:{set:function(L){!L&&this.$resizeObserver?(this.$resizeObserver.disconnect(),this.$resizeTimer.cancel(),this.$resizeTimer=this.$resizeObserver=null):L&&!this.$resizeObserver&&this.$addResizeObserver()}},animatedScroll:{initialValue:!1},showInvisibles:{set:function(L){this.$textLayer.setShowInvisibles(L)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!1},showPrintMargin:{set:function(){this.$updatePrintMargin()},initialValue:!0},printMarginColumn:{set:function(){this.$updatePrintMargin()},initialValue:80},printMargin:{set:function(L){typeof L=="number"&&(this.$printMarginColumn=L),this.$showPrintMargin=!!L,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(L){this.$gutter.style.display=L?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},useSvgGutterIcons:{set:function(L){this.$gutterLayer.$useSvgGutterIcons=L},initialValue:!1},showFoldedAnnotations:{set:function(L){this.$gutterLayer.$showFoldedAnnotations=L},initialValue:!1},fadeFoldWidgets:{set:function(L){h.setCssClass(this.$gutter,"ace_fade-fold-widgets",L)},initialValue:!1},showFoldWidgets:{set:function(L){this.$gutterLayer.setShowFoldWidgets(L),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(L){this.$textLayer.setDisplayIndentGuides(L)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightIndentGuides:{set:function(L){this.$textLayer.setHighlightIndentGuides(L)==!0?this.$textLayer.$highlightIndentGuide():this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells)},initialValue:!0},highlightGutterLine:{set:function(L){this.$gutterLayer.setHighlightGutterLine(L),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(L){(!this.$hScrollBarAlwaysVisible||!this.$horizScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(L){(!this.$vScrollBarAlwaysVisible||!this.$vScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(L){typeof L=="number"&&(L=L+"px"),this.container.style.fontSize=L,this.updateFontSize()},initialValue:12},fontFamily:{set:function(L){this.container.style.fontFamily=L,this.updateFontSize()}},maxLines:{set:function(L){this.updateFull()}},minLines:{set:function(L){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(L){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(L){L=+L||0,this.$scrollPastEnd!=L&&(this.$scrollPastEnd=L,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(L){this.$gutterLayer.$fixedWidth=!!L,this.$loop.schedule(this.CHANGE_GUTTER)}},customScrollbar:{set:function(L){this.$updateCustomScrollbar(L)},initialValue:!1},theme:{set:function(L){this.setTheme(L)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!k.isMobile&&!k.isIE}}),r.VirtualRenderer=D}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(t,r,l){var d=t("../lib/oop"),h=t("../lib/net"),b=t("../lib/event_emitter").EventEmitter,p=t("../config");function g(u){var i="importScripts('"+h.qualifyURL(u)+"');";try{return new Blob([i],{type:"application/javascript"})}catch{var a=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,m=new a;return m.append(i),m.getBlob("application/javascript")}}function o(u){if(typeof Worker>"u")return{postMessage:function(){},terminate:function(){}};if(p.get("loadWorkerFromBlob")){var i=g(u),a=window.URL||window.webkitURL,m=a.createObjectURL(i);return new Worker(m)}return new Worker(u)}var c=function(u){u.postMessage||(u=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=u,this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.onMessage=this.onMessage.bind(this),this.callbackId=1,this.callbacks={},this.$worker.onmessage=this.onMessage};(function(){d.implement(this,b),this.$createWorkerFromOldConfig=function(u,i,a,m,w){if(t.nameToUrl&&!t.toUrl&&(t.toUrl=t.nameToUrl),p.get("packaged")||!t.toUrl)m=m||p.moduleUrl(i,"worker");else{var x=this.$normalizePath;m=m||x(t.toUrl("ace/worker/worker.js",null,"_"));var M={};u.forEach(function($){M[$]=x(t.toUrl($,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}return this.$worker=o(m),w&&this.send("importScripts",w),this.$worker.postMessage({init:!0,tlns:M,module:i,classname:a}),this.$worker},this.onMessage=function(u){var i=u.data;switch(i.type){case"event":this._signal(i.name,{data:i.data});break;case"call":var a=this.callbacks[i.id];a&&(a(i.data),delete this.callbacks[i.id]);break;case"error":this.reportError(i.data);break;case"log":window.console&&console.log&&console.log.apply(console,i.data);break}},this.reportError=function(u){window.console&&console.error&&console.error(u)},this.$normalizePath=function(u){return h.qualifyURL(u)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker.onerror=function(u){u.preventDefault()},this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(u,i){this.$worker.postMessage({command:u,args:i})},this.call=function(u,i,a){if(a){var m=this.callbackId++;this.callbacks[m]=a,i.push(m)}this.send(u,i)},this.emit=function(u,i){try{i.data&&i.data.err&&(i.data.err={message:i.data.err.message,stack:i.data.err.stack,code:i.data.err.code}),this.$worker&&this.$worker.postMessage({event:u,data:{data:i.data}})}catch(a){console.error(a.stack)}},this.attachToDocument=function(u){this.$doc&&this.terminate(),this.$doc=u,this.call("setValue",[u.getValue()]),u.on("change",this.changeListener,!0)},this.changeListener=function(u){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),u.action=="insert"?this.deltaQueue.push(u.start,u.lines):this.deltaQueue.push(u.start,u.end)},this.$sendDeltaQueue=function(){var u=this.deltaQueue;u&&(this.deltaQueue=null,u.length>50&&u.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:u}))}}).call(c.prototype);var f=function(u,i,a){var m=null,w=!1,x=Object.create(b),M=[],$=new c({messageBuffer:M,terminate:function(){},postMessage:function(k){M.push(k),m&&(w?setTimeout(S):S())}});$.setEmitSync=function(k){w=k};var S=function(){var k=M.shift();k.command?m[k.command].apply(m,k.args):k.event&&x._signal(k.event,k.data)};return x.postMessage=function(k){$.onMessage({data:k})},x.callback=function(k,T){this.postMessage({type:"call",id:T,data:k})},x.emit=function(k,T){this.postMessage({type:"event",name:k,data:T})},p.loadModule(["worker",i],function(k){for(m=new k[a](x);M.length;)S()}),$};r.UIWorkerClient=f,r.WorkerClient=c,r.createWorker=o}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(t,r,l){var d=t("./range").Range,h=t("./lib/event_emitter").EventEmitter,b=t("./lib/oop"),p=function(){function g(o,c,f,u,i,a){var m=this;this.length=c,this.session=o,this.doc=o.getDocument(),this.mainClass=i,this.othersClass=a,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate,!0),this.$others=u,this.$onCursorChange=function(){setTimeout(function(){m.onCursorChange()})},this.$pos=f;var w=o.getUndoManager().$undoStack||o.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=w.length,this.setup(),o.selection.on("changeCursor",this.$onCursorChange)}return g.prototype.setup=function(){var o=this,c=this.doc,f=this.session;this.selectionBefore=f.selection.toJSON(),f.selection.inMultiSelectMode&&f.selection.toSingleRange(),this.pos=c.createAnchor(this.$pos.row,this.$pos.column);var u=this.pos;u.$insertRight=!0,u.detach(),u.markerId=f.addMarker(new d(u.row,u.column,u.row,u.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach(function(i){var a=c.createAnchor(i.row,i.column);a.$insertRight=!0,a.detach(),o.others.push(a)}),f.setUndoSelect(!1)},g.prototype.showOtherMarkers=function(){if(!this.othersActive){var o=this.session,c=this;this.othersActive=!0,this.others.forEach(function(f){f.markerId=o.addMarker(new d(f.row,f.column,f.row,f.column+c.length),c.othersClass,null,!1)})}},g.prototype.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var o=0;o<this.others.length;o++)this.session.removeMarker(this.others[o].markerId)}},g.prototype.onUpdate=function(o){if(this.$updating)return this.updateAnchors(o);var c=o;if(c.start.row===c.end.row&&c.start.row===this.pos.row){this.$updating=!0;var f=o.action==="insert"?c.end.column-c.start.column:c.start.column-c.end.column,u=c.start.column>=this.pos.column&&c.start.column<=this.pos.column+this.length+1,i=c.start.column-this.pos.column;if(this.updateAnchors(o),u&&(this.length+=f),u&&!this.session.$fromUndo){if(o.action==="insert")for(var a=this.others.length-1;a>=0;a--){var m=this.others[a],w={row:m.row,column:m.column+i};this.doc.insertMergedLines(w,o.lines)}else if(o.action==="remove")for(var a=this.others.length-1;a>=0;a--){var m=this.others[a],w={row:m.row,column:m.column+i};this.doc.remove(new d(w.row,w.column,w.row,w.column-f))}}this.$updating=!1,this.updateMarkers()}},g.prototype.updateAnchors=function(o){this.pos.onChange(o);for(var c=this.others.length;c--;)this.others[c].onChange(o);this.updateMarkers()},g.prototype.updateMarkers=function(){if(!this.$updating){var o=this,c=this.session,f=function(i,a){c.removeMarker(i.markerId),i.markerId=c.addMarker(new d(i.row,i.column,i.row,i.column+o.length),a,null,!1)};f(this.pos,this.mainClass);for(var u=this.others.length;u--;)f(this.others[u],this.othersClass)}},g.prototype.onCursorChange=function(o){if(!(this.$updating||!this.session)){var c=this.session.selection.getCursor();c.row===this.pos.row&&c.column>=this.pos.column&&c.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",o)):(this.hideOtherMarkers(),this._emit("cursorLeave",o))}},g.prototype.detach=function(){this.session.removeMarker(this.pos&&this.pos.markerId),this.hideOtherMarkers(),this.doc.off("change",this.$onUpdate),this.session.selection.off("changeCursor",this.$onCursorChange),this.session.setUndoSelect(!0),this.session=null},g.prototype.cancel=function(){if(this.$undoStackDepth!==-1){for(var o=this.session.getUndoManager(),c=(o.$undoStack||o.$undostack).length-this.$undoStackDepth,f=0;f<c;f++)o.undo(this.session,!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}},g}();b.implement(p.prototype,h),r.PlaceHolder=p}),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(t,r,l){var d=t("../lib/event"),h=t("../lib/useragent");function b(g,o){return g.row==o.row&&g.column==o.column}function p(g){var o=g.domEvent,c=o.altKey,f=o.shiftKey,u=o.ctrlKey,i=g.getAccelKey(),a=g.getButton();if(u&&h.isMac&&(a=o.button),g.editor.inMultiSelectMode&&a==2){g.editor.textInput.onContextMenu(g.domEvent);return}if(!u&&!c&&!i){a===0&&g.editor.inMultiSelectMode&&g.editor.exitMultiSelectMode();return}if(a===0){var m=g.editor,w=m.selection,x=m.inMultiSelectMode,M=g.getDocumentPosition(),$=w.getCursor(),S=g.inSelection()||w.isEmpty()&&b(M,$),k=g.x,T=g.y,D=function(J){k=J.clientX,T=J.clientY},L=m.session,O=m.renderer.pixelToScreenCoordinates(k,T),z=O,P;if(m.$mouseHandler.$enableJumpToDef)u&&c||i&&c?P=f?"block":"add":c&&m.$blockSelectEnabled&&(P="block");else if(i&&!c){if(P="add",!x&&f)return}else c&&m.$blockSelectEnabled&&(P="block");if(P&&h.isMac&&o.ctrlKey&&m.$mouseHandler.cancelContextMenu(),P=="add"){if(!x&&S)return;if(!x){var N=w.toOrientedRange();m.addSelectionMarker(N)}var A=w.rangeList.rangeAtPoint(M);m.inVirtualSelectionMode=!0,f&&(A=null,N=w.ranges[0]||N,m.removeSelectionMarker(N)),m.once("mouseup",function(){var J=w.toOrientedRange();A&&J.isEmpty()&&b(A.cursor,J.cursor)?w.substractPoint(J.cursor):(f?w.substractPoint(N.cursor):N&&(m.removeSelectionMarker(N),w.addRange(N)),w.addRange(J)),m.inVirtualSelectionMode=!1})}else if(P=="block"){g.stop(),m.inVirtualSelectionMode=!0;var _,I=[],j=function(){var J=m.renderer.pixelToScreenCoordinates(k,T),ae=L.screenToDocumentPosition(J.row,J.column,J.offsetX);b(z,J)&&b(ae,w.lead)||(z=J,m.selection.moveToPosition(ae),m.renderer.scrollCursorIntoView(),m.removeSelectionMarkers(I),I=w.rectangularRangeBlock(z,O),m.$mouseHandler.$clickSelection&&I.length==1&&I[0].isEmpty()&&(I[0]=m.$mouseHandler.$clickSelection.clone()),I.forEach(m.addSelectionMarker,m),m.updateSelectionMarkers())};x&&!i?w.toSingleRange():!x&&i&&(_=w.toOrientedRange(),m.addSelectionMarker(_)),f?O=L.documentToScreenPosition(w.lead):w.moveToPosition(M),z={row:-1,column:-1};var U=function(J){j(),clearInterval(Z),m.removeSelectionMarkers(I),I.length||(I=[w.toOrientedRange()]),_&&(m.removeSelectionMarker(_),w.toSingleRange(_));for(var ae=0;ae<I.length;ae++)w.addRange(I[ae]);m.inVirtualSelectionMode=!1,m.$mouseHandler.$clickSelection=null},K=j;d.capture(m.container,D,U);var Z=setInterval(function(){K()},20);return g.preventDefault()}}}r.onMouseDown=p}),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(t,r,l){r.defaultCommands=[{name:"addCursorAbove",description:"Add cursor above",exec:function(h){h.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelow",description:"Add cursor below",exec:function(h){h.selectMoreLines(1)},bindKey:{win:"Ctrl-Alt-Down",mac:"Ctrl-Alt-Down"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorAboveSkipCurrent",description:"Add cursor above (skip current)",exec:function(h){h.selectMoreLines(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Up",mac:"Ctrl-Alt-Shift-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelowSkipCurrent",description:"Add cursor below (skip current)",exec:function(h){h.selectMoreLines(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Down",mac:"Ctrl-Alt-Shift-Down"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreBefore",description:"Select more before",exec:function(h){h.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreAfter",description:"Select more after",exec:function(h){h.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextBefore",description:"Select next before",exec:function(h){h.selectMore(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Left",mac:"Ctrl-Alt-Shift-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextAfter",description:"Select next after",exec:function(h){h.selectMore(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Right",mac:"Ctrl-Alt-Shift-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"toggleSplitSelectionIntoLines",description:"Split selection into lines",exec:function(h){h.multiSelect.rangeCount>1?h.multiSelect.joinSelections():h.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(h){h.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(h){h.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(h){h.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],r.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(h){h.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(h){return h&&h.inMultiSelectMode}}];var d=t("../keyboard/hash_handler").HashHandler;r.keyboardHandler=new d(r.multiSelectCommands)}),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],function(t,r,l){var d=t("./range_list").RangeList,h=t("./range").Range,b=t("./selection").Selection,p=t("./mouse/multi_select_handler").onMouseDown,g=t("./lib/event"),o=t("./lib/lang"),c=t("./commands/multi_select_commands");r.commands=c.defaultCommands.concat(c.multiSelectCommands);var f=t("./search").Search,u=new f;function i($,S,k){return u.$options.wrap=!0,u.$options.needle=S,u.$options.backwards=k==-1,u.find($)}var a=t("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(a.prototype),(function(){this.ranges=null,this.rangeList=null,this.addRange=function($,S){if($){if(!this.inMultiSelectMode&&this.rangeCount===0){var k=this.toOrientedRange();if(this.rangeList.add(k),this.rangeList.add($),this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),S||this.fromOrientedRange($);this.rangeList.removeAll(),this.rangeList.add(k),this.$onAddRange(k)}$.cursor||($.cursor=$.end);var T=this.rangeList.add($);return this.$onAddRange($),T.length&&this.$onRemoveRange(T),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),S||this.fromOrientedRange($)}},this.toSingleRange=function($){$=$||this.ranges[0];var S=this.rangeList.removeAll();S.length&&this.$onRemoveRange(S),$&&this.fromOrientedRange($)},this.substractPoint=function($){var S=this.rangeList.substractPoint($);if(S)return this.$onRemoveRange(S),S[0]},this.mergeOverlappingRanges=function(){var $=this.rangeList.merge();$.length&&this.$onRemoveRange($)},this.$onAddRange=function($){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift($),this._signal("addRange",{range:$})},this.$onRemoveRange=function($){if(this.rangeCount=this.rangeList.ranges.length,this.rangeCount==1&&this.inMultiSelectMode){var S=this.rangeList.ranges.pop();$.push(S),this.rangeCount=0}for(var k=$.length;k--;){var T=this.ranges.indexOf($[k]);this.ranges.splice(T,1)}this._signal("removeRange",{ranges:$}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),S=S||this.ranges[0],S&&!S.isEqual(this.getRange())&&this.fromOrientedRange(S)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new d,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var $=this.ranges.length?this.ranges:[this.getRange()],S=[],k=0;k<$.length;k++){var T=$[k],D=T.start.row,L=T.end.row;if(D===L)S.push(T.clone());else{for(S.push(new h(D,T.start.column,D,this.session.getLine(D).length));++D<L;)S.push(this.getLineRange(D,!0));S.push(new h(L,0,L,T.end.column))}k==0&&!this.isBackwards()&&(S=S.reverse())}this.toSingleRange();for(var k=S.length;k--;)this.addRange(S[k])},this.joinSelections=function(){var $=this.rangeList.ranges,S=$[$.length-1],k=h.fromPoints($[0].start,S.end);this.toSingleRange(),this.setSelectionRange(k,S.cursor==S.start)},this.toggleBlockSelection=function(){if(this.rangeCount>1){var $=this.rangeList.ranges,S=$[$.length-1],k=h.fromPoints($[0].start,S.end);this.toSingleRange(),this.setSelectionRange(k,S.cursor==S.start)}else{var T=this.session.documentToScreenPosition(this.cursor),D=this.session.documentToScreenPosition(this.anchor),L=this.rectangularRangeBlock(T,D);L.forEach(this.addRange,this)}},this.rectangularRangeBlock=function($,S,k){var T=[],D=$.column<S.column;if(D)var L=$.column,O=S.column,z=$.offsetX,P=S.offsetX;else var L=S.column,O=$.column,z=S.offsetX,P=$.offsetX;var N=$.row<S.row;if(N)var A=$.row,_=S.row;else var A=S.row,_=$.row;L<0&&(L=0),A<0&&(A=0),A==_&&(k=!0);for(var I,j=A;j<=_;j++){var U=h.fromPoints(this.session.screenToDocumentPosition(j,L,z),this.session.screenToDocumentPosition(j,O,P));if(U.isEmpty()){if(I&&w(U.end,I))break;I=U.end}U.cursor=D?U.start:U.end,T.push(U)}if(N&&T.reverse(),!k){for(var K=T.length-1;T[K].isEmpty()&&K>0;)K--;if(K>0)for(var Z=0;T[Z].isEmpty();)Z++;for(var J=K;J>=Z;J--)T[J].isEmpty()&&T.splice(J,1)}return T}}).call(b.prototype);var m=t("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function($){$.cursor||($.cursor=$.end);var S=this.getSelectionStyle();return $.marker=this.session.addMarker($,"ace_selection",S),this.session.$selectionMarkers.push($),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,$},this.removeSelectionMarker=function($){if($.marker){this.session.removeMarker($.marker);var S=this.session.$selectionMarkers.indexOf($);S!=-1&&this.session.$selectionMarkers.splice(S,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length}},this.removeSelectionMarkers=function($){for(var S=this.session.$selectionMarkers,k=$.length;k--;){var T=$[k];if(T.marker){this.session.removeMarker(T.marker);var D=S.indexOf(T);D!=-1&&S.splice(D,1)}}this.session.selectionMarkerCount=S.length},this.$onAddRange=function($){this.addSelectionMarker($.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function($){this.removeSelectionMarkers($.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function($){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(c.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())},this.$onSingleSelect=function($){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(c.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))},this.$onMultiSelectExec=function($){var S=$.command,k=$.editor;if(k.multiSelect){if(S.multiSelectAction)S.multiSelectAction=="forEach"?T=k.forEachSelection(S,$.args):S.multiSelectAction=="forEachLine"?T=k.forEachSelection(S,$.args,!0):S.multiSelectAction=="single"?(k.exitMultiSelectMode(),T=S.exec(k,$.args||{})):T=S.multiSelectAction(k,$.args||{});else{var T=S.exec(k,$.args||{});k.multiSelect.addRange(k.multiSelect.toOrientedRange()),k.multiSelect.mergeOverlappingRanges()}return T}},this.forEachSelection=function($,S,k){if(!this.inVirtualSelectionMode){var T=k&&k.keepOrder,D=k==!0||k&&k.$byLines,L=this.session,O=this.selection,z=O.rangeList,P=(T?O:z).ranges,N;if(!P.length)return $.exec?$.exec(this,S||{}):$(this,S||{});var A=O._eventRegistry;O._eventRegistry={};var _=new b(L);this.inVirtualSelectionMode=!0;for(var I=P.length;I--;){if(D)for(;I>0&&P[I].start.row==P[I-1].end.row;)I--;_.fromOrientedRange(P[I]),_.index=I,this.selection=L.selection=_;var j=$.exec?$.exec(this,S||{}):$(this,S||{});!N&&j!==void 0&&(N=j),_.toOrientedRange(P[I])}_.detach(),this.selection=L.selection=O,this.inVirtualSelectionMode=!1,O._eventRegistry=A,O.mergeOverlappingRanges(),O.ranges[0]&&O.fromOrientedRange(O.ranges[0]);var U=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),U&&U.from==U.to&&this.renderer.animateScrolling(U.from),N}},this.exitMultiSelectMode=function(){!this.inMultiSelectMode||this.inVirtualSelectionMode||this.multiSelect.toSingleRange()},this.getSelectedText=function(){var $="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var S=this.multiSelect.rangeList.ranges,k=[],T=0;T<S.length;T++)k.push(this.session.getTextRange(S[T]));var D=this.session.getDocument().getNewLineCharacter();$=k.join(D),$.length==(k.length-1)*D.length&&($="")}else this.selection.isEmpty()||($=this.session.getTextRange(this.getSelectionRange()));return $},this.$checkMultiselectChange=function($,S){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var k=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&S==this.multiSelect.anchor)return;var T=S==this.multiSelect.anchor?k.cursor==k.start?k.end:k.start:k.cursor;T.row!=S.row||this.session.$clipPositionToDocument(T.row,T.column).column!=S.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()}},this.findAll=function($,S,k){if(S=S||{},S.needle=$||S.needle,S.needle==null){var T=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();S.needle=this.session.getTextRange(T)}this.$search.set(S);var D=this.$search.findAll(this.session);if(!D.length)return 0;var L=this.multiSelect;k||L.toSingleRange(D[0]);for(var O=D.length;O--;)L.addRange(D[O],!0);return T&&L.rangeList.rangeAtPoint(T.start)&&L.addRange(T,!0),D.length},this.selectMoreLines=function($,S){var k=this.selection.toOrientedRange(),T=k.cursor==k.end,D=this.session.documentToScreenPosition(k.cursor);this.selection.$desiredColumn&&(D.column=this.selection.$desiredColumn);var L=this.session.screenToDocumentPosition(D.row+$,D.column);if(k.isEmpty())var z=L;else var O=this.session.documentToScreenPosition(T?k.end:k.start),z=this.session.screenToDocumentPosition(O.row+$,O.column);if(T){var P=h.fromPoints(L,z);P.cursor=P.start}else{var P=h.fromPoints(z,L);P.cursor=P.end}if(P.desiredColumn=D.column,!this.selection.inMultiSelectMode)this.selection.addRange(k);else if(S)var N=k.cursor;this.selection.addRange(P),N&&this.selection.substractPoint(N)},this.transposeSelections=function($){for(var S=this.session,k=S.multiSelect,T=k.ranges,D=T.length;D--;){var L=T[D];if(L.isEmpty()){var O=S.getWordRange(L.start.row,L.start.column);L.start.row=O.start.row,L.start.column=O.start.column,L.end.row=O.end.row,L.end.column=O.end.column}}k.mergeOverlappingRanges();for(var z=[],D=T.length;D--;){var L=T[D];z.unshift(S.getTextRange(L))}$<0?z.unshift(z.pop()):z.push(z.shift());for(var D=T.length;D--;){var L=T[D],P=L.clone();S.replace(L,z[D]),L.start.row=P.start.row,L.start.column=P.start.column}k.fromOrientedRange(k.ranges[0])},this.selectMore=function($,S,k){var T=this.session,D=T.multiSelect,L=D.toOrientedRange();if(!(L.isEmpty()&&(L=T.getWordRange(L.start.row,L.start.column),L.cursor=$==-1?L.start:L.end,this.multiSelect.addRange(L),k))){var O=T.getTextRange(L),z=i(T,O,$);z&&(z.cursor=$==-1?z.start:z.end,this.session.unfold(z),this.multiSelect.addRange(z),this.renderer.scrollCursorIntoView(null,.5)),S&&this.multiSelect.substractPoint(L.cursor)}},this.alignCursors=function(){var $=this.session,S=$.multiSelect,k=S.ranges,T=-1,D=k.filter(function(K){if(K.cursor.row==T)return!0;T=K.cursor.row});if(!k.length||D.length==k.length-1){var L=this.selection.getRange(),O=L.start.row,z=L.end.row,P=O==z;if(P){var N=this.session.getLength(),A;do A=this.session.getLine(z);while(/[=:]/.test(A)&&++z<N);do A=this.session.getLine(O);while(/[=:]/.test(A)&&--O>0);O<0&&(O=0),z>=N&&(z=N-1)}var _=this.session.removeFullLines(O,z);_=this.$reAlignText(_,P),this.session.insert({row:O,column:0},_.join(`
|
|
957
|
+
`)+`
|
|
958
|
+
`),P||(L.start.column=0,L.end.column=_[_.length-1].length),this.selection.setRange(L)}else{D.forEach(function(K){S.substractPoint(K.cursor)});var I=0,j=1/0,U=k.map(function(K){var Z=K.cursor,J=$.getLine(Z.row),ae=J.substr(Z.column).search(/\S/g);return ae==-1&&(ae=0),Z.column>I&&(I=Z.column),ae<j&&(j=ae),ae});k.forEach(function(K,Z){var J=K.cursor,ae=I-J.column,ne=U[Z]-j;ae>ne?$.insert(J,o.stringRepeat(" ",ae-ne)):$.remove(new h(J.row,J.column,J.row,J.column-ae+ne)),K.start.column=K.end.column=I,K.start.row=K.end.row=J.row,K.cursor=K.end}),S.fromOrientedRange(k[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}},this.$reAlignText=function($,S){var k=!0,T=!0,D,L,O;return $.map(function(_){var I=_.match(/(\s*)(.*?)(\s*)([=:].*)/);return I?D==null?(D=I[1].length,L=I[2].length,O=I[3].length,I):(D+L+O!=I[1].length+I[2].length+I[3].length&&(T=!1),D!=I[1].length&&(k=!1),D>I[1].length&&(D=I[1].length),L<I[2].length&&(L=I[2].length),O>I[3].length&&(O=I[3].length),I):[_]}).map(S?P:k?T?N:P:A);function z(_){return o.stringRepeat(" ",_)}function P(_){return _[2]?z(D)+_[2]+z(L-_[2].length+O)+_[4].replace(/^([=:])\s+/,"$1 "):_[0]}function N(_){return _[2]?z(D+L-_[2].length)+_[2]+z(O)+_[4].replace(/^([=:])\s+/,"$1 "):_[0]}function A(_){return _[2]?z(D)+_[2]+z(O)+_[4].replace(/^([=:])\s+/,"$1 "):_[0]}}}).call(m.prototype);function w($,S){return $.row==S.row&&$.column==S.column}r.onSessionChange=function($){var S=$.session;S&&!S.multiSelect&&(S.$selectionMarkers=[],S.selection.$initRangeList(),S.multiSelect=S.selection),this.multiSelect=S&&S.multiSelect;var k=$.oldSession;k&&(k.multiSelect.off("addRange",this.$onAddRange),k.multiSelect.off("removeRange",this.$onRemoveRange),k.multiSelect.off("multiSelect",this.$onMultiSelect),k.multiSelect.off("singleSelect",this.$onSingleSelect),k.multiSelect.lead.off("change",this.$checkMultiselectChange),k.multiSelect.anchor.off("change",this.$checkMultiselectChange)),S&&(S.multiSelect.on("addRange",this.$onAddRange),S.multiSelect.on("removeRange",this.$onRemoveRange),S.multiSelect.on("multiSelect",this.$onMultiSelect),S.multiSelect.on("singleSelect",this.$onSingleSelect),S.multiSelect.lead.on("change",this.$checkMultiselectChange),S.multiSelect.anchor.on("change",this.$checkMultiselectChange)),S&&this.inMultiSelectMode!=S.selection.inMultiSelectMode&&(S.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())};function x($){$.$multiselectOnSessionChange||($.$onAddRange=$.$onAddRange.bind($),$.$onRemoveRange=$.$onRemoveRange.bind($),$.$onMultiSelect=$.$onMultiSelect.bind($),$.$onSingleSelect=$.$onSingleSelect.bind($),$.$multiselectOnSessionChange=r.onSessionChange.bind($),$.$checkMultiselectChange=$.$checkMultiselectChange.bind($),$.$multiselectOnSessionChange($),$.on("changeSession",$.$multiselectOnSessionChange),$.on("mousedown",p),$.commands.addCommands(c.defaultCommands),M($))}function M($){if(!$.textInput)return;var S=$.textInput.getElement(),k=!1;g.addListener(S,"keydown",function(D){var L=D.keyCode==18&&!(D.ctrlKey||D.shiftKey||D.metaKey);$.$blockSelectEnabled&&L?k||($.renderer.setMouseCursor("crosshair"),k=!0):k&&T()},$),g.addListener(S,"keyup",T,$),g.addListener(S,"blur",T,$);function T(D){k&&($.renderer.setMouseCursor(""),k=!1)}}r.MultiSelect=x,t("./config").defineOptions(m.prototype,"editor",{enableMultiselect:{set:function($){x(this),$?this.on("mousedown",p):this.off("mousedown",p)},value:!0},enableBlockSelect:{set:function($){this.$blockSelectEnabled=$},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(t,r,l){var d=t("../../range").Range,h=r.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(b,p,g){var o=b.getLine(g);return this.foldingStartMarker.test(o)?"start":p=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(o)?"end":""},this.getFoldWidgetRange=function(b,p,g){return null},this.indentationBlock=function(b,p,g){var o=/\S/,c=b.getLine(p),f=c.search(o);if(f!=-1){for(var u=g||c.length,i=b.getLength(),a=p,m=p;++p<i;){var w=b.getLine(p).search(o);if(w!=-1){if(w<=f){var x=b.getTokenAt(p,0);if(!x||x.type!=="string")break}m=p}}if(m>a){var M=b.getLine(m).length;return new d(a,u,m,M)}}},this.openingBracketBlock=function(b,p,g,o,c){var f={row:g,column:o+1},u=b.$findClosingBracket(p,f,c);if(u){var i=b.foldWidgets[u.row];return i==null&&(i=b.getFoldWidget(u.row)),i=="start"&&u.row>f.row&&(u.row--,u.column=b.getLine(u.row).length),d.fromPoints(f,u)}},this.closingBracketBlock=function(b,p,g,o,c){var f={row:g,column:o},u=b.$findOpeningBracket(p,f);if(u)return u.column++,f.column--,d.fromPoints(u,f)}}).call(h.prototype)}),ace.define("ace/ext/error_marker",["require","exports","module","ace/lib/dom","ace/range","ace/config"],function(t,r,l){var d=t("../lib/dom"),h=t("../range").Range,b=t("../config").nls;function p(o,c,f){for(var u=0,i=o.length-1;u<=i;){var a=u+i>>1,m=f(c,o[a]);if(m>0)u=a+1;else if(m<0)i=a-1;else return a}return-(u+1)}function g(o,c,f){var u=o.getAnnotations().sort(h.comparePoints);if(u.length){var i=p(u,{row:c,column:-1},h.comparePoints);i<0&&(i=-i-1),i>=u.length?i=f>0?0:u.length-1:i===0&&f<0&&(i=u.length-1);var a=u[i];if(!(!a||!f)){if(a.row===c){do a=u[i+=f];while(a&&a.row===c);if(!a)return u.slice()}var m=[];c=a.row;do m[f<0?"unshift":"push"](a),a=u[i+=f];while(a&&a.row==c);return m.length&&m}}}r.showErrorMarker=function(o,c){var f=o.session,u=o.getCursorPosition(),i=u.row,a=f.widgetManager.getWidgetsAtRow(i).filter(function(D){return D.type=="errorMarker"})[0];a?a.destroy():i-=c;var m=g(f,i,c),w;if(m){var x=m[0];u.column=(x.pos&&typeof x.column!="number"?x.pos.sc:x.column)||0,u.row=x.row,w=o.renderer.$gutterLayer.$annotations[u.row]}else{if(a)return;w={displayText:[b("error-marker.good-state","Looks good!")],className:"ace_ok"}}o.session.unfold(u.row),o.selection.moveToPosition(u);var M={row:u.row,fixedWidth:!0,coverGutter:!0,el:d.createElement("div"),type:"errorMarker"},$=M.el.appendChild(d.createElement("div")),S=M.el.appendChild(d.createElement("div"));S.className="error_widget_arrow "+w.className;var k=o.renderer.$cursorLayer.getPixelPosition(u).left;S.style.left=k+o.renderer.gutterWidth-5+"px",M.el.className="error_widget_wrapper",$.className="error_widget "+w.className,w.displayText.forEach(function(D,L){$.appendChild(d.createTextNode(D)),L<w.displayText.length-1&&$.appendChild(d.createElement("br"))}),$.appendChild(d.createElement("div"));var T=function(D,L,O){if(L===0&&(O==="esc"||O==="return"))return M.destroy(),{command:"null"}};M.destroy=function(){o.$mouseHandler.isMousePressed||(o.keyBinding.removeKeyboardHandler(T),f.widgetManager.removeLineWidget(M),o.off("changeSelection",M.destroy),o.off("changeSession",M.destroy),o.off("mouseup",M.destroy),o.off("change",M.destroy))},o.keyBinding.addKeyboardHandler(T),o.on("changeSelection",M.destroy),o.on("changeSession",M.destroy),o.on("mouseup",M.destroy),o.on("change",M.destroy),o.session.widgetManager.addLineWidget(M),M.el.onmousedown=o.focus.bind(o),o.renderer.scrollCursorIntoView(null,.5,{bottom:M.el.offsetHeight})},d.importCssString(`
|
|
959
|
+
.error_widget_wrapper {
|
|
960
|
+
background: inherit;
|
|
961
|
+
color: inherit;
|
|
962
|
+
border:none
|
|
963
|
+
}
|
|
964
|
+
.error_widget {
|
|
965
|
+
border-top: solid 2px;
|
|
966
|
+
border-bottom: solid 2px;
|
|
967
|
+
margin: 5px 0;
|
|
968
|
+
padding: 10px 40px;
|
|
969
|
+
white-space: pre-wrap;
|
|
970
|
+
}
|
|
971
|
+
.error_widget.ace_error, .error_widget_arrow.ace_error{
|
|
972
|
+
border-color: #ff5a5a
|
|
973
|
+
}
|
|
974
|
+
.error_widget.ace_warning, .error_widget_arrow.ace_warning{
|
|
975
|
+
border-color: #F1D817
|
|
976
|
+
}
|
|
977
|
+
.error_widget.ace_info, .error_widget_arrow.ace_info{
|
|
978
|
+
border-color: #5a5a5a
|
|
979
|
+
}
|
|
980
|
+
.error_widget.ace_ok, .error_widget_arrow.ace_ok{
|
|
981
|
+
border-color: #5aaa5a
|
|
982
|
+
}
|
|
983
|
+
.error_widget_arrow {
|
|
984
|
+
position: absolute;
|
|
985
|
+
border: solid 5px;
|
|
986
|
+
border-top-color: transparent!important;
|
|
987
|
+
border-right-color: transparent!important;
|
|
988
|
+
border-left-color: transparent!important;
|
|
989
|
+
top: -5px;
|
|
990
|
+
}
|
|
991
|
+
`,"error_marker.css",!1)}),ace.define("ace/ace",["require","exports","module","ace/lib/dom","ace/range","ace/editor","ace/edit_session","ace/undomanager","ace/virtual_renderer","ace/worker/worker_client","ace/keyboard/hash_handler","ace/placeholder","ace/multi_select","ace/mode/folding/fold_mode","ace/theme/textmate","ace/ext/error_marker","ace/config","ace/loader_build"],function(t,r,l){t("./loader_build")(r);var d=t("./lib/dom"),h=t("./range").Range,b=t("./editor").Editor,p=t("./edit_session").EditSession,g=t("./undomanager").UndoManager,o=t("./virtual_renderer").VirtualRenderer;t("./worker/worker_client"),t("./keyboard/hash_handler"),t("./placeholder"),t("./multi_select"),t("./mode/folding/fold_mode"),t("./theme/textmate"),t("./ext/error_marker"),r.config=t("./config"),r.edit=function(f,u){if(typeof f=="string"){var i=f;if(f=document.getElementById(i),!f)throw new Error("ace.edit can't find div #"+i)}if(f&&f.env&&f.env.editor instanceof b)return f.env.editor;var a="";if(f&&/input|textarea/i.test(f.tagName)){var m=f;a=m.value,f=d.createElement("pre"),m.parentNode.replaceChild(f,m)}else f&&(a=f.textContent,f.innerHTML="");var w=r.createEditSession(a),x=new b(new o(f),w,u),M={document:w,editor:x,onResize:x.resize.bind(x,null)};return m&&(M.textarea=m),x.on("destroy",function(){M.editor.container.env=null}),x.container.env=x.env=M,x},r.createEditSession=function(f,u){var i=new p(f,u);return i.setUndoManager(new g),i},r.Range=h,r.Editor=b,r.EditSession=p,r.UndoManager=g,r.VirtualRenderer=o;var c=r.config.version;r.version=c}),function(){ace.require(["ace/ace"],function(t){t&&(t.config.init(!0),t.define=ace.define);var r=function(){return this}();!r&&typeof window<"u"&&(r=window),!r&&typeof self<"u"&&(r=self),r.ace||(r.ace=t);for(var l in t)t.hasOwnProperty(l)&&(r.ace[l]=t[l]);r.ace.default=r.ace,n&&(n.exports=r.ace)})}()}(Cg)),Cg.exports}var Nr=$S(),Ag={exports:{}},Eg;function AS(){return Eg||(Eg=1,function(n,e){ace.define("ace/mode/ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,l){var d=t("../lib/oop"),h=t("./text_highlight_rules").TextHighlightRules,b=r.constantOtherSymbol={token:"constant.other.symbol.ruby",regex:"[:](?:[A-Za-z_]|[@$](?=[a-zA-Z0-9_]))[a-zA-Z0-9_]*[!=?]?"};r.qString={token:"string",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},r.qqString={token:"string",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'},r.tString={token:"string",regex:"[`](?:(?:\\\\.)|(?:[^'\\\\]))*?[`]"};var p=r.constantNumericHex={token:"constant.numeric",regex:"0[xX][0-9a-fA-F](?:[0-9a-fA-F]|_(?=[0-9a-fA-F]))*\\b"},g=r.constantNumericBinary={token:"constant.numeric",regex:/\b(0[bB][01](?:[01]|_(?=[01]))*)\b/},o=r.constantNumericDecimal={token:"constant.numeric",regex:/\b(0[dD](?:[1-9](?:[\d]|_(?=[\d]))*|0))\b/},c=r.constantNumericOctal={token:"constant.numeric",regex:/\b(0[oO]?(?:[1-7](?:[0-7]|_(?=[0-7]))*|0))\b/},f=r.constantNumericRational={token:"constant.numeric",regex:/\b([\d]+(?:[./][\d]+)?ri?)\b/},u=r.constantNumericComplex={token:"constant.numeric",regex:/\b([\d]i)\b/},i=r.constantNumericFloat={token:"constant.numeric",regex:"[+-]?\\d(?:\\d|_(?=\\d))*(?:(?:\\.\\d(?:\\d|_(?=\\d))*)?(?:[eE][+-]?\\d+)?)?i?\\b"},a=r.instanceVariable={token:"variable.instance",regex:"@{1,2}[a-zA-Z_\\d]+"},m=function(){var w="abort|Array|assert|assert_equal|assert_not_equal|assert_same|assert_not_same|assert_nil|assert_not_nil|assert_match|assert_no_match|assert_in_delta|assert_throws|assert_raise|assert_nothing_raised|assert_instance_of|assert_kind_of|assert_respond_to|assert_operator|assert_send|assert_difference|assert_no_difference|assert_recognizes|assert_generates|assert_response|assert_redirected_to|assert_template|assert_select|assert_select_email|assert_select_rjs|assert_select_encoded|css_select|at_exit|attr|attr_writer|attr_reader|attr_accessor|attr_accessible|autoload|binding|block_given?|callcc|caller|catch|chomp|chomp!|chop|chop!|defined?|delete_via_redirect|eval|exec|exit|exit!|fail|Float|flunk|follow_redirect!|fork|form_for|form_tag|format|gets|global_variables|gsub|gsub!|get_via_redirect|host!|https?|https!|include|Integer|lambda|link_to|link_to_unless_current|link_to_function|link_to_remote|load|local_variables|loop|open|open_session|p|print|printf|proc|putc|puts|post_via_redirect|put_via_redirect|raise|rand|raw|readline|readlines|redirect?|request_via_redirect|require|scan|select|set_trace_func|sleep|split|sprintf|srand|String|stylesheet_link_tag|syscall|system|sub|sub!|test|throw|trace_var|trap|untrace_var|atan2|cos|exp|frexp|ldexp|log|log10|sin|sqrt|tan|render|javascript_include_tag|csrf_meta_tag|label_tag|text_field_tag|submit_tag|check_box_tag|content_tag|radio_button_tag|text_area_tag|password_field_tag|hidden_field_tag|fields_for|select_tag|options_for_select|options_from_collection_for_select|collection_select|time_zone_select|select_date|select_time|select_datetime|date_select|time_select|datetime_select|select_year|select_month|select_day|select_hour|select_minute|select_second|file_field_tag|file_field|respond_to|skip_before_filter|around_filter|after_filter|verify|protect_from_forgery|rescue_from|helper_method|redirect_to|before_filter|send_data|send_file|validates_presence_of|validates_uniqueness_of|validates_length_of|validates_format_of|validates_acceptance_of|validates_associated|validates_exclusion_of|validates_inclusion_of|validates_numericality_of|validates_with|validates_each|authenticate_or_request_with_http_basic|authenticate_or_request_with_http_digest|filter_parameter_logging|match|get|post|resources|redirect|scope|assert_routing|translate|localize|extract_locale_from_tld|caches_page|expire_page|caches_action|expire_action|cache|expire_fragment|expire_cache_for|observe|cache_sweeper|has_many|has_one|belongs_to|has_and_belongs_to_many|p|warn|refine|using|module_function|extend|alias_method|private_class_method|remove_method|undef_method",x="alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|__FILE__|finally|for|gem|if|in|__LINE__|module|next|not|or|private|protected|public|redo|rescue|retry|return|super|then|undef|unless|until|when|while|yield|__ENCODING__|prepend",M="true|TRUE|false|FALSE|nil|NIL|ARGF|ARGV|DATA|ENV|RUBY_PLATFORM|RUBY_RELEASE_DATE|RUBY_VERSION|STDERR|STDIN|STDOUT|TOPLEVEL_BINDING|RUBY_PATCHLEVEL|RUBY_REVISION|RUBY_COPYRIGHT|RUBY_ENGINE|RUBY_ENGINE_VERSION|RUBY_DESCRIPTION",$="$DEBUG|$defout|$FILENAME|$LOAD_PATH|$SAFE|$stdin|$stdout|$stderr|$VERBOSE|$!|root_url|flash|session|cookies|params|request|response|logger|self",S=this.$keywords=this.createKeywordMapper({keyword:x,"constant.language":M,"variable.language":$,"support.function":w,"invalid.deprecated":"debugger"},"identifier"),k=`\\\\(?:n(?:[1-7][0-7]{0,2}|0)|[nsrtvfbae'"\\\\]|c(?:\\\\M-)?.|M-(?:\\\\C-|\\\\c)?.|C-(?:\\\\M-)?.|[0-7]{3}|x[\\da-fA-F]{2}|u[\\da-fA-F]{4}|u{[\\da-fA-F]{1,6}(?:\\s[\\da-fA-F]{1,6})*})`,T={"(":")","[":"]","{":"}","<":">","^":"^","|":"|","%":"%"};this.$rules={start:[{token:"comment",regex:"#.*$"},{token:"comment.multiline",regex:"^=begin(?=$|\\s.*$)",next:"comment"},{token:"string.regexp",regex:/[/](?=.*\/)/,next:"regex"},[{token:["constant.other.symbol.ruby","string.start"],regex:/(:)?(")/,push:[{token:"constant.language.escape",regex:k},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/"/,next:"pop"},{defaultToken:"string"}]},{token:"string.start",regex:/`/,push:[{token:"constant.language.escape",regex:k},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/`/,next:"pop"},{defaultToken:"string"}]},{token:["constant.other.symbol.ruby","string.start"],regex:/(:)?(')/,push:[{token:"constant.language.escape",regex:/\\['\\]/},{token:"string.end",regex:/'/,next:"pop"},{defaultToken:"string"}]},{token:"string.start",regex:/%[qwx]([(\[<{^|%])/,onMatch:function(D,L,O){O.length&&(O=[]);var z=D[D.length-1];return O.unshift(z,L),this.next="qStateWithoutInterpolation",this.token}},{token:"string.start",regex:/%[QWX]?([(\[<{^|%])/,onMatch:function(D,L,O){O.length&&(O=[]);var z=D[D.length-1];return O.unshift(z,L),this.next="qStateWithInterpolation",this.token}},{token:"constant.other.symbol.ruby",regex:/%[si]([(\[<{^|%])/,onMatch:function(D,L,O){O.length&&(O=[]);var z=D[D.length-1];return O.unshift(z,L),this.next="sStateWithoutInterpolation",this.token}},{token:"constant.other.symbol.ruby",regex:/%[SI]([(\[<{^|%])/,onMatch:function(D,L,O){O.length&&(O=[]);var z=D[D.length-1];return O.unshift(z,L),this.next="sStateWithInterpolation",this.token}},{token:"string.regexp",regex:/%[r]([(\[<{^|%])/,onMatch:function(D,L,O){O.length&&(O=[]);var z=D[D.length-1];return O.unshift(z,L),this.next="rState",this.token}}],{token:"punctuation",regex:"::"},a,{token:"variable.global",regex:"[$][a-zA-Z_\\d]+"},{token:"support.class",regex:"[A-Z][a-zA-Z_\\d]*"},{token:["punctuation.operator","support.function"],regex:/(\.)([a-zA-Z_\d]+)(?=\()/},{token:["punctuation.operator","identifier"],regex:/(\.)([a-zA-Z_][a-zA-Z_\d]*)/},{token:"string.character",regex:"\\B\\?(?:"+k+"|\\S)"},{token:"punctuation.operator",regex:/\?(?=.+:)/},f,u,b,p,i,g,o,c,{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:S,regex:"[a-zA-Z_$][a-zA-Z0-9_$]*\\b"},{token:"punctuation.separator.key-value",regex:"=>"},{stateName:"heredoc",onMatch:function(D,L,O){var z=D[2]=="-"||D[2]=="~"?"indentedHeredoc":"heredoc",P=D.split(this.splitRegex);return O.push(z,P[3]),[{type:"constant",value:P[1]},{type:"string",value:P[2]},{type:"support.class",value:P[3]},{type:"string",value:P[4]}]},regex:"(<<[-~]?)(['\"`]?)([\\w]+)(['\"`]?)",rules:{heredoc:[{onMatch:function(D,L,O){return D===O[1]?(O.shift(),O.shift(),this.next=O[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}],indentedHeredoc:[{token:"string",regex:"^ +"},{onMatch:function(D,L,O){return D===O[1]?(O.shift(),O.shift(),this.next=O[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}]}},{regex:"$",token:"empty",next:function(D,L){return L[0]==="heredoc"||L[0]==="indentedHeredoc"?L[0]:D}},{token:"keyword.operator",regex:"!|\\$|%|&|\\*|/|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\||\\b(?:in|instanceof|new|delete|typeof|void)"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]",onMatch:function(D,L,O){return this.next="",D=="}"&&O.length>1&&O[1]!="start"&&(O.shift(),this.next=O.shift()),this.token}},{token:"text",regex:"\\s+"},{token:"punctuation.operator",regex:/[?:,;.]/}],comment:[{token:"comment.multiline",regex:"^=end(?=$|\\s.*$)",next:"start"},{token:"comment",regex:".+"}],qStateWithInterpolation:[{token:"string.start",regex:/[(\[<{]/,onMatch:function(D,L,O){return O.length&&D===O[0]?(O.unshift(D,L),this.token):"string"}},{token:"constant.language.escape",regex:k},{token:"constant.language.escape",regex:/\\./},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/[)\]>}^|%]/,onMatch:function(D,L,O){return O.length&&D===T[O[0]]?(O.shift(),this.next=O.shift(),this.token):(this.next="","string")}},{defaultToken:"string"}],qStateWithoutInterpolation:[{token:"string.start",regex:/[(\[<{]/,onMatch:function(D,L,O){return O.length&&D===O[0]?(O.unshift(D,L),this.token):"string"}},{token:"constant.language.escape",regex:/\\['\\]/},{token:"constant.language.escape",regex:/\\./},{token:"string.end",regex:/[)\]>}^|%]/,onMatch:function(D,L,O){return O.length&&D===T[O[0]]?(O.shift(),this.next=O.shift(),this.token):(this.next="","string")}},{defaultToken:"string"}],sStateWithoutInterpolation:[{token:"constant.other.symbol.ruby",regex:/[(\[<{]/,onMatch:function(D,L,O){return O.length&&D===O[0]?(O.unshift(D,L),this.token):"constant.other.symbol.ruby"}},{token:"constant.other.symbol.ruby",regex:/[)\]>}^|%]/,onMatch:function(D,L,O){return O.length&&D===T[O[0]]?(O.shift(),this.next=O.shift(),this.token):(this.next="","constant.other.symbol.ruby")}},{defaultToken:"constant.other.symbol.ruby"}],sStateWithInterpolation:[{token:"constant.other.symbol.ruby",regex:/[(\[<{]/,onMatch:function(D,L,O){return O.length&&D===O[0]?(O.unshift(D,L),this.token):"constant.other.symbol.ruby"}},{token:"constant.language.escape",regex:k},{token:"constant.language.escape",regex:/\\./},{token:"paren.start",regex:/#{/,push:"start"},{token:"constant.other.symbol.ruby",regex:/[)\]>}^|%]/,onMatch:function(D,L,O){return O.length&&D===T[O[0]]?(O.shift(),this.next=O.shift(),this.token):(this.next="","constant.other.symbol.ruby")}},{defaultToken:"constant.other.symbol.ruby"}],rState:[{token:"string.regexp",regex:/[(\[<{]/,onMatch:function(D,L,O){return O.length&&D===O[0]?(O.unshift(D,L),this.token):"constant.language.escape"}},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.regexp",regex:/\//},{token:"string.regexp",regex:/[)\]>}^|%][imxouesn]*/,onMatch:function(D,L,O){return O.length&&D[0]===T[O[0]]?(O.shift(),this.next=O.shift(),this.token):(this.next="","constant.language.escape")}},{include:"regex"},{defaultToken:"string.regexp"}],regex:[{token:"regexp.keyword",regex:/\\[wWdDhHsS]/},{token:"constant.language.escape",regex:/\\[AGbBzZ]/},{token:"constant.language.escape",regex:/\\g<[a-zA-Z0-9]*>/},{token:["constant.language.escape","regexp.keyword","constant.language.escape"],regex:/(\\p{\^?)(Alnum|Alpha|Blank|Cntrl|Digit|Graph|Lower|Print|Punct|Space|Upper|XDigit|Word|ASCII|Any|Assigned|Arabic|Armenian|Balinese|Bengali|Bopomofo|Braille|Buginese|Buhid|Canadian_Aboriginal|Carian|Cham|Cherokee|Common|Coptic|Cuneiform|Cypriot|Cyrillic|Deseret|Devanagari|Ethiopic|Georgian|Glagolitic|Gothic|Greek|Gujarati|Gurmukhi|Han|Hangul|Hanunoo|Hebrew|Hiragana|Inherited|Kannada|Katakana|Kayah_Li|Kharoshthi|Khmer|Lao|Latin|Lepcha|Limbu|Linear_B|Lycian|Lydian|Malayalam|Mongolian|Myanmar|New_Tai_Lue|Nko|Ogham|Ol_Chiki|Old_Italic|Old_Persian|Oriya|Osmanya|Phags_Pa|Phoenician|Rejang|Runic|Saurashtra|Shavian|Sinhala|Sundanese|Syloti_Nagri|Syriac|Tagalog|Tagbanwa|Tai_Le|Tamil|Telugu|Thaana|Thai|Tibetan|Tifinagh|Ugaritic|Vai|Yi|Ll|Lm|Lt|Lu|Lo|Mn|Mc|Me|Nd|Nl|Pc|Pd|Ps|Pe|Pi|Pf|Po|No|Sm|Sc|Sk|So|Zs|Zl|Zp|Cc|Cf|Cn|Co|Cs|N|L|M|P|S|Z|C)(})/},{token:["constant.language.escape","invalid","constant.language.escape"],regex:/(\\p{\^?)([^/]*)(})/},{token:"regexp.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"string.regexp",regex:/[/][imxouesn]*/,next:"start"},{token:"invalid",regex:/\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/},{token:"constant.language.escape",regex:/\(\?(?:[:=!>]|<'?[a-zA-Z]*'?>|<[=!])|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/},{token:"constant.language.delimiter",regex:/\|/},{token:"regexp.keyword",regex:/\[\[:(?:alnum|alpha|blank|cntrl|digit|graph|lower|print|punct|space|upper|xdigit|word|ascii):\]\]/},{token:"constant.language.escape",regex:/\[\^?/,push:"regex_character_class"},{defaultToken:"string.regexp"}],regex_character_class:[{token:"regexp.keyword",regex:/\\[wWdDhHsS]/},{token:"regexp.charclass.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"constant.language.escape",regex:/&?&?\[\^?/,push:"regex_character_class"},{token:"constant.language.escape",regex:"]",next:"pop"},{token:"constant.language.escape",regex:"-"},{defaultToken:"string.regexp.characterclass"}]},this.normalizeRules()};d.inherits(m,h),r.RubyHighlightRules=m}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(t,r,l){var d=t("../range").Range,h=function(){};(function(){this.checkOutdent=function(b,p){return/^\s+$/.test(b)?/^\s*\}/.test(p):!1},this.autoOutdent=function(b,p){var g=b.getLine(p),o=g.match(/^(\s*\})/);if(!o)return 0;var c=o[1].length,f=b.findMatchingBracket({row:p,column:c});if(!f||f.row==p)return 0;var u=this.$getIndent(b.getLine(f.row));b.replace(new d(p,0,p,c-1),u)},this.$getIndent=function(b){return b.match(/^\s*/)[0]}}).call(h.prototype),r.MatchingBraceOutdent=h}),ace.define("ace/mode/folding/ruby",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range","ace/token_iterator"],function(t,r,l){var d=t("../../lib/oop"),h=t("./fold_mode").FoldMode,b=t("../../range").Range,p=t("../../token_iterator").TokenIterator,g=r.FoldMode=function(){};d.inherits(g,h),(function(){this.indentKeywords={class:1,def:1,module:1,do:1,unless:1,if:1,while:1,for:1,until:1,begin:1,else:0,elsif:0,rescue:0,ensure:0,when:0,end:-1,case:1,"=begin":1,"=end":-1},this.foldingStartMarker=/(?:\s|^)(def|do|while|class|unless|module|if|for|until|begin|else|elsif|case|rescue|ensure|when)\b|({\s*$)|(=begin)/,this.foldingStopMarker=/(=end(?=$|\s.*$))|(^\s*})|\b(end)\b/,this.getFoldWidget=function(o,c,f){var u=o.getLine(f),i=this.foldingStartMarker.test(u),a=this.foldingStopMarker.test(u);if(i&&!a){var m=u.match(this.foldingStartMarker);if(m[1]){if((m[1]=="if"||m[1]=="else"||m[1]=="while"||m[1]=="until"||m[1]=="unless")&&(m[1]=="else"&&/^\s*else\s*$/.test(u)===!1||/^\s*(?:if|else|while|until|unless)\s*/.test(u)===!1)||m[1]=="when"&&/\sthen\s/.test(u)===!0)return;if(o.getTokenAt(f,m.index+2).type==="keyword")return"start"}else if(!m[3]||o.getTokenAt(f,m.index+1).type==="comment.multiline")return"start"}if(c!="markbeginend"||!a||i&&a)return"";var m=u.match(this.foldingStopMarker);if(m[3]==="end"){if(o.getTokenAt(f,m.index+1).type==="keyword")return"end"}else if(!m[1]||o.getTokenAt(f,m.index+1).type==="comment.multiline")return"end"},this.getFoldWidgetRange=function(o,c,f){var u=o.doc.getLine(f),i=this.foldingStartMarker.exec(u);if(i)return i[1]||i[3]?this.rubyBlock(o,f,i.index+2):this.openingBracketBlock(o,"{",f,i.index);var i=this.foldingStopMarker.exec(u);if(i)return i[3]==="end"&&o.getTokenAt(f,i.index+1).type==="keyword"?this.rubyBlock(o,f,i.index+1):i[1]==="=end"&&o.getTokenAt(f,i.index+1).type==="comment.multiline"?this.rubyBlock(o,f,i.index+1):this.closingBracketBlock(o,"}",f,i.index+i[0].length)},this.rubyBlock=function(o,c,f,u){var i=new p(o,c,f),a=i.getCurrentToken();if(!(!a||a.type!="keyword"&&a.type!="comment.multiline")){var m=a.value,w=o.getLine(c);switch(a.value){case"if":case"unless":case"while":case"until":var x=new RegExp("^\\s*"+a.value);if(!x.test(w))return;var M=this.indentKeywords[m];break;case"when":if(/\sthen\s/.test(w))return;case"elsif":case"rescue":case"ensure":var M=1;break;case"else":var x=new RegExp("^\\s*"+a.value+"\\s*$");if(!x.test(w))return;var M=1;break;default:var M=this.indentKeywords[m]}var $=[m];if(M){var S=M===-1?o.getLine(c-1).length:o.getLine(c).length,k=c,T=[];if(T.push(i.getCurrentTokenRange()),i.step=M===-1?i.stepBackward:i.stepForward,a.type=="comment.multiline"){for(;a=i.step();)if(a.type==="comment.multiline"){if(M==1){if(S=6,a.value=="=end")break}else if(a.value=="=begin")break}}else for(;a=i.step();){var D=!1;if(a.type==="keyword"){var L=M*this.indentKeywords[a.value];switch(w=o.getLine(i.getCurrentTokenRow()),a.value){case"do":for(var O=i.$tokenIndex-1;O>=0;O--){var z=i.$rowTokens[O];if(z&&(z.value=="while"||z.value=="until"||z.value=="for")){L=0;break}}break;case"else":var x=new RegExp("^\\s*"+a.value+"\\s*$");(!x.test(w)||m=="case")&&(L=0,D=!0);break;case"if":case"unless":case"while":case"until":var x=new RegExp("^\\s*"+a.value);x.test(w)||(L=0,D=!0);break;case"when":(/\sthen\s/.test(w)||m=="case")&&(L=0,D=!0)}if(L>0)$.unshift(a.value);else if(L<=0&&D===!1){if($.shift(),!$.length&&((m=="while"||m=="until"||m=="for")&&a.value!="do"||a.value=="do"&&M==-1&&L!=0||a.value!="do"))break;L===0&&$.unshift(a.value)}}}if(!a)return null;if(u)return T.push(i.getCurrentTokenRange()),T;var c=i.getCurrentTokenRow();if(M===-1){if(a.type==="comment.multiline")var P=6;else var P=o.getLine(c).length;return new b(c,P,k-1,S)}return new b(k,S,c-1,o.getLine(c-1).length)}}}}).call(g.prototype)}),ace.define("ace/mode/ruby",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ruby_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/folding/ruby"],function(t,r,l){var d=t("../lib/oop"),h=t("./text").Mode,b=t("./ruby_highlight_rules").RubyHighlightRules,p=t("./matching_brace_outdent").MatchingBraceOutdent,g=t("../range").Range,o=t("./folding/ruby").FoldMode,c=function(){this.HighlightRules=b,this.$outdent=new p,this.$behaviour=this.$defaultBehaviour,this.foldingRules=new o,this.indentKeywords=this.foldingRules.indentKeywords};d.inherits(c,h),(function(){this.lineCommentStart="#",this.getNextLineIndent=function(f,u,i){var a=this.$getIndent(u),m=this.getTokenizer().getLineTokens(u,f),w=m.tokens;if(w.length&&w[w.length-1].type=="comment")return a;if(f=="start"){var x=u.match(/^.*[\{\(\[]\s*$/),M=u.match(/^\s*(class|def|module)\s.*$/),$=u.match(/.*do(\s*|\s+\|.*\|\s*)$/),S=u.match(/^\s*(if|else|when|elsif|unless|while|for|begin|rescue|ensure)\s*/);(x||M||$||S)&&(a+=i)}return a},this.checkOutdent=function(f,u,i){return/^\s+(end|else|rescue|ensure)$/.test(u+i)||this.$outdent.checkOutdent(u,i)},this.autoOutdent=function(f,u,i){var a=u.getLine(i);if(/}/.test(a))return this.$outdent.autoOutdent(u,i);var m=this.$getIndent(a),w=u.getLine(i-1),x=this.$getIndent(w),M=u.getTabString();x.length<=m.length&&m.slice(-M.length)==M&&u.remove(new g(i,m.length-M.length,i,m.length))},this.getMatching=function(f,u,i){if(u==null){var a=f.selection.lead;i=a.column,u=a.row}var m=f.getTokenAt(u,i);if(m&&m.value in this.indentKeywords)return this.foldingRules.rubyBlock(f,u,i,!0)},this.$id="ace/mode/ruby",this.snippetFileId="ace/snippets/ruby"}).call(c.prototype),r.Mode=c}),function(){ace.require(["ace/mode/ruby"],function(t){n&&(n.exports=t)})}()}(Ag)),Ag.exports}AS();var Tg={exports:{}},Rg;function ES(){return Rg||(Rg=1,function(n,e){ace.define("ace/mode/python_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,l){var d=t("../lib/oop"),h=t("./text_highlight_rules").TextHighlightRules,b=function(){var p="and|as|assert|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|not|or|pass|print|raise|return|try|while|with|yield|async|await|nonlocal",g="True|False|None|NotImplemented|Ellipsis|__debug__",o="abs|divmod|input|open|staticmethod|all|enumerate|int|ord|str|any|eval|isinstance|pow|sum|basestring|execfile|issubclass|print|super|binfile|bin|iter|property|tuple|bool|filter|len|range|type|bytearray|float|list|raw_input|unichr|callable|format|locals|reduce|unicode|chr|frozenset|long|reload|vars|classmethod|getattr|map|repr|xrange|cmp|globals|max|reversed|zip|compile|hasattr|memoryview|round|__import__|complex|hash|min|apply|delattr|help|next|setattr|set|buffer|dict|hex|object|slice|coerce|dir|id|oct|sorted|intern|ascii|breakpoint|bytes",c=this.createKeywordMapper({"invalid.deprecated":"debugger","support.function":o,"variable.language":"self|cls","constant.language":g,keyword:p},"identifier"),f="[uU]?",u="[rR]",i="[fF]",a="(?:[rR][fF]|[fF][rR])",m="(?:(?:[1-9]\\d*)|(?:0))",w="(?:0[oO]?[0-7]+)",x="(?:0[xX][\\dA-Fa-f]+)",M="(?:0[bB][01]+)",$="(?:"+m+"|"+w+"|"+x+"|"+M+")",S="(?:[eE][+-]?\\d+)",k="(?:\\.\\d+)",T="(?:\\d+)",D="(?:(?:"+T+"?"+k+")|(?:"+T+"\\.))",L="(?:(?:"+D+"|"+T+")"+S+")",O="(?:"+L+"|"+D+")",z=`\\\\(x[0-9A-Fa-f]{2}|[0-7]{3}|[\\\\abfnrtv'"]|U[0-9A-Fa-f]{8}|u[0-9A-Fa-f]{4})`;this.$rules={start:[{token:"comment",regex:"#.*$"},{token:"string",regex:f+'"{3}',next:"qqstring3"},{token:"string",regex:f+'"(?=.)',next:"qqstring"},{token:"string",regex:f+"'{3}",next:"qstring3"},{token:"string",regex:f+"'(?=.)",next:"qstring"},{token:"string",regex:u+'"{3}',next:"rawqqstring3"},{token:"string",regex:u+'"(?=.)',next:"rawqqstring"},{token:"string",regex:u+"'{3}",next:"rawqstring3"},{token:"string",regex:u+"'(?=.)",next:"rawqstring"},{token:"string",regex:i+'"{3}',next:"fqqstring3"},{token:"string",regex:i+'"(?=.)',next:"fqqstring"},{token:"string",regex:i+"'{3}",next:"fqstring3"},{token:"string",regex:i+"'(?=.)",next:"fqstring"},{token:"string",regex:a+'"{3}',next:"rfqqstring3"},{token:"string",regex:a+'"(?=.)',next:"rfqqstring"},{token:"string",regex:a+"'{3}",next:"rfqstring3"},{token:"string",regex:a+"'(?=.)",next:"rfqstring"},{token:"keyword.operator",regex:"\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|%|@|<<|>>|&|\\||\\^|~|<|>|<=|=>|==|!=|<>|="},{token:"punctuation",regex:",|:|;|\\->|\\+=|\\-=|\\*=|\\/=|\\/\\/=|%=|@=|&=|\\|=|^=|>>=|<<=|\\*\\*="},{token:"paren.lparen",regex:"[\\[\\(\\{]"},{token:"paren.rparen",regex:"[\\]\\)\\}]"},{token:["keyword","text","entity.name.function"],regex:"(def|class)(\\s+)([\\u00BF-\\u1FFF\\u2C00-\\uD7FF\\w]+)"},{token:"text",regex:"\\s+"},{include:"constants"}],qqstring3:[{token:"constant.language.escape",regex:z},{token:"string",regex:'"{3}',next:"start"},{defaultToken:"string"}],qstring3:[{token:"constant.language.escape",regex:z},{token:"string",regex:"'{3}",next:"start"},{defaultToken:"string"}],qqstring:[{token:"constant.language.escape",regex:z},{token:"string",regex:"\\\\$",next:"qqstring"},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],qstring:[{token:"constant.language.escape",regex:z},{token:"string",regex:"\\\\$",next:"qstring"},{token:"string",regex:"'|$",next:"start"},{defaultToken:"string"}],rawqqstring3:[{token:"string",regex:'"{3}',next:"start"},{defaultToken:"string"}],rawqstring3:[{token:"string",regex:"'{3}",next:"start"},{defaultToken:"string"}],rawqqstring:[{token:"string",regex:"\\\\$",next:"rawqqstring"},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],rawqstring:[{token:"string",regex:"\\\\$",next:"rawqstring"},{token:"string",regex:"'|$",next:"start"},{defaultToken:"string"}],fqqstring3:[{token:"constant.language.escape",regex:z},{token:"string",regex:'"{3}',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqstring3:[{token:"constant.language.escape",regex:z},{token:"string",regex:"'{3}",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqqstring:[{token:"constant.language.escape",regex:z},{token:"string",regex:"\\\\$",next:"fqqstring"},{token:"string",regex:'"|$',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqstring:[{token:"constant.language.escape",regex:z},{token:"string",regex:"'|$",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],rfqqstring3:[{token:"string",regex:'"{3}',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],rfqstring3:[{token:"string",regex:"'{3}",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],rfqqstring:[{token:"string",regex:"\\\\$",next:"rfqqstring"},{token:"string",regex:'"|$',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],rfqstring:[{token:"string",regex:"'|$",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqstringParRules:[{token:"paren.lparen",regex:"[\\[\\(]"},{token:"paren.rparen",regex:"[\\]\\)]"},{token:"string",regex:"\\s+"},{token:"string",regex:"'[^']*'"},{token:"string",regex:'"[^"]*"'},{token:"function.support",regex:"(!s|!r|!a)"},{include:"constants"},{token:"paren.rparen",regex:"}",next:"pop"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"}],constants:[{token:"constant.numeric",regex:"(?:"+O+"|\\d+)[jJ]\\b"},{token:"constant.numeric",regex:O},{token:"constant.numeric",regex:$+"[lL]\\b"},{token:"constant.numeric",regex:$+"\\b"},{token:["punctuation","function.support"],regex:"(\\.)([a-zA-Z_]+)\\b"},{token:c,regex:"[a-zA-Z_$][a-zA-Z0-9_$]*\\b"}]},this.normalizeRules()};d.inherits(b,h),r.PythonHighlightRules=b}),ace.define("ace/mode/folding/pythonic",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"],function(t,r,l){var d=t("../../lib/oop"),h=t("./fold_mode").FoldMode,b=r.FoldMode=function(p){this.foldingStartMarker=new RegExp("([\\[{])(?:\\s*)$|("+p+")(?:\\s*)(?:#.*)?$")};d.inherits(b,h),(function(){this.getFoldWidgetRange=function(p,g,o){var c=p.getLine(o),f=c.match(this.foldingStartMarker);if(f)return f[1]?this.openingBracketBlock(p,f[1],o,f.index):f[2]?this.indentationBlock(p,o,f.index+f[2].length):this.indentationBlock(p,o)}}).call(b.prototype)}),ace.define("ace/mode/python",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/python_highlight_rules","ace/mode/folding/pythonic","ace/range"],function(t,r,l){var d=t("../lib/oop"),h=t("./text").Mode,b=t("./python_highlight_rules").PythonHighlightRules,p=t("./folding/pythonic").FoldMode,g=t("../range").Range,o=function(){this.HighlightRules=b,this.foldingRules=new p("\\:"),this.$behaviour=this.$defaultBehaviour};d.inherits(o,h),(function(){this.lineCommentStart="#",this.$pairQuotesAfter={"'":/[ruf]/i,'"':/[ruf]/i},this.getNextLineIndent=function(f,u,i){var a=this.$getIndent(u),m=this.getTokenizer().getLineTokens(u,f),w=m.tokens;if(w.length&&w[w.length-1].type=="comment")return a;if(f=="start"){var x=u.match(/^.*[\{\(\[:]\s*$/);x&&(a+=i)}return a};var c={pass:1,return:1,raise:1,break:1,continue:1};this.checkOutdent=function(f,u,i){if(i!==`\r
|
|
992
|
+
`&&i!=="\r"&&i!==`
|
|
993
|
+
`)return!1;var a=this.getTokenizer().getLineTokens(u.trim(),f).tokens;if(!a)return!1;do var m=a.pop();while(m&&(m.type=="comment"||m.type=="text"&&m.value.match(/^\s+$/)));return m?m.type=="keyword"&&c[m.value]:!1},this.autoOutdent=function(f,u,i){i+=1;var a=this.$getIndent(u.getLine(i)),m=u.getTabString();a.slice(-m.length)==m&&u.remove(new g(i,a.length-m.length,i,a.length))},this.$id="ace/mode/python",this.snippetFileId="ace/snippets/python"}).call(o.prototype),r.Mode=o}),function(){ace.require(["ace/mode/python"],function(t){n&&(n.exports=t)})}()}(Tg)),Tg.exports}ES();var Mg={exports:{}},Lg;function TS(){return Lg||(Lg=1,function(n,e){ace.define("ace/mode/json_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,l){var d=t("../lib/oop"),h=t("./text_highlight_rules").TextHighlightRules,b=function(){this.$rules={start:[{token:"variable",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]\\s*(?=:)'},{token:"string",regex:'"',next:"string"},{token:"constant.numeric",regex:"0[xX][0-9a-fA-F]+\\b"},{token:"constant.numeric",regex:"[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"},{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:"text",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},{token:"comment",regex:"\\/\\/.*$"},{token:"comment.start",regex:"\\/\\*",next:"comment"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]"},{token:"punctuation.operator",regex:/[,]/},{token:"text",regex:"\\s+"}],string:[{token:"constant.language.escape",regex:/\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|["\\\/bfnrt])/},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],comment:[{token:"comment.end",regex:"\\*\\/",next:"start"},{defaultToken:"comment"}]}};d.inherits(b,h),r.JsonHighlightRules=b}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(t,r,l){var d=t("../range").Range,h=function(){};(function(){this.checkOutdent=function(b,p){return/^\s+$/.test(b)?/^\s*\}/.test(p):!1},this.autoOutdent=function(b,p){var g=b.getLine(p),o=g.match(/^(\s*\})/);if(!o)return 0;var c=o[1].length,f=b.findMatchingBracket({row:p,column:c});if(!f||f.row==p)return 0;var u=this.$getIndent(b.getLine(f.row));b.replace(new d(p,0,p,c-1),u)},this.$getIndent=function(b){return b.match(/^\s*/)[0]}}).call(h.prototype),r.MatchingBraceOutdent=h}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(t,r,l){var d=t("../../lib/oop"),h=t("../../range").Range,b=t("./fold_mode").FoldMode,p=r.FoldMode=function(g){g&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+g.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+g.end)))};d.inherits(p,b),(function(){this.foldingStartMarker=/([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(g,o,c){var f=g.getLine(c);if(this.singleLineBlockCommentRe.test(f)&&!this.startRegionRe.test(f)&&!this.tripleStarBlockCommentRe.test(f))return"";var u=this._getFoldWidgetBase(g,o,c);return!u&&this.startRegionRe.test(f)?"start":u},this.getFoldWidgetRange=function(g,o,c,f){var u=g.getLine(c);if(this.startRegionRe.test(u))return this.getCommentRegionBlock(g,u,c);var i=u.match(this.foldingStartMarker);if(i){var a=i.index;if(i[1])return this.openingBracketBlock(g,i[1],c,a);var m=g.getCommentFoldRange(c,a+i[0].length,1);return m&&!m.isMultiLine()&&(f?m=this.getSectionRange(g,c):o!="all"&&(m=null)),m}if(o!=="markbegin"){var i=u.match(this.foldingStopMarker);if(i){var a=i.index+i[0].length;return i[1]?this.closingBracketBlock(g,i[1],c,a):g.getCommentFoldRange(c,a,-1)}}},this.getSectionRange=function(g,o){var c=g.getLine(o),f=c.search(/\S/),u=o,i=c.length;o+=1;for(var a=o,m=g.getLength();++o<m;){c=g.getLine(o);var w=c.search(/\S/);if(w!==-1){if(f>w)break;var x=this.getFoldWidgetRange(g,"all",o);if(x){if(x.start.row<=u)break;if(x.isMultiLine())o=x.end.row;else if(f==w)break}a=o}}return new h(u,i,a,g.getLine(a).length)},this.getCommentRegionBlock=function(g,o,c){for(var f=o.search(/\s*$/),u=g.getLength(),i=c,a=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,m=1;++c<u;){o=g.getLine(c);var w=a.exec(o);if(w&&(w[1]?m--:m++,!m))break}var x=c;if(x>i)return new h(i,f,x,o.length)}}).call(p.prototype)}),ace.define("ace/mode/json",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/json_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/cstyle","ace/worker/worker_client"],function(t,r,l){var d=t("../lib/oop"),h=t("./text").Mode,b=t("./json_highlight_rules").JsonHighlightRules,p=t("./matching_brace_outdent").MatchingBraceOutdent,g=t("./folding/cstyle").FoldMode,o=t("../worker/worker_client").WorkerClient,c=function(){this.HighlightRules=b,this.$outdent=new p,this.$behaviour=this.$defaultBehaviour,this.foldingRules=new g};d.inherits(c,h),(function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(f,u,i){var a=this.$getIndent(u);if(f=="start"){var m=u.match(/^.*[\{\(\[]\s*$/);m&&(a+=i)}return a},this.checkOutdent=function(f,u,i){return this.$outdent.checkOutdent(u,i)},this.autoOutdent=function(f,u,i){this.$outdent.autoOutdent(u,i)},this.createWorker=function(f){var u=new o(["ace"],"ace/mode/json_worker","JsonWorker");return u.attachToDocument(f.getDocument()),u.on("annotate",function(i){f.setAnnotations(i.data)}),u.on("terminate",function(){f.clearAnnotations()}),u},this.$id="ace/mode/json"}).call(c.prototype),r.Mode=c}),function(){ace.require(["ace/mode/json"],function(t){n&&(n.exports=t)})}()}(Mg)),Mg.exports}TS();var Og={exports:{}},Ig;function RS(){return Ig||(Ig=1,function(n,e){ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"],function(t,r,l){var d=t("../lib/oop");t("../lib/lang");var h=t("./text_highlight_rules").TextHighlightRules,b=r.supportType="align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|max-zoom|min-height|min-width|min-zoom|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|user-select|user-zoom|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index",p=r.supportFunction="rgb|rgba|url|attr|counter|counters",g=r.supportConstant="absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|flex-end|flex-start|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero|zoom",o=r.supportConstantColor="aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen",c=r.supportConstantFonts="arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace",f=r.numRe="\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))",u=r.pseudoElements="(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b",i=r.pseudoClasses="(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b",a=function(){var m=this.createKeywordMapper({"support.function":p,"support.constant":g,"support.type":b,"support.constant.color":o,"support.constant.fonts":c},"text",!0);this.$rules={start:[{include:["strings","url","comments"]},{token:"paren.lparen",regex:"\\{",next:"ruleset"},{token:"paren.rparen",regex:"\\}"},{token:"string",regex:"@(?!viewport)",next:"media"},{token:"keyword",regex:"#[a-z0-9-_]+"},{token:"keyword",regex:"%"},{token:"variable",regex:"\\.[a-z0-9-_]+"},{token:"string",regex:":[a-z0-9-_]+"},{token:"constant.numeric",regex:f},{token:"constant",regex:"[a-z0-9-_]+"},{caseInsensitive:!0}],media:[{include:["strings","url","comments"]},{token:"paren.lparen",regex:"\\{",next:"start"},{token:"paren.rparen",regex:"\\}",next:"start"},{token:"string",regex:";",next:"start"},{token:"keyword",regex:"(?:media|supports|document|charset|import|namespace|media|supports|document|page|font|keyframes|viewport|counter-style|font-feature-values|swash|ornaments|annotation|stylistic|styleset|character-variant)"}],comments:[{token:"comment",regex:"\\/\\*",push:[{token:"comment",regex:"\\*\\/",next:"pop"},{defaultToken:"comment"}]}],ruleset:[{regex:"-(webkit|ms|moz|o)-",token:"text"},{token:"punctuation.operator",regex:"[:;]"},{token:"paren.rparen",regex:"\\}",next:"start"},{include:["strings","url","comments"]},{token:["constant.numeric","keyword"],regex:"("+f+")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vmax|vmin|vm|vw|%)"},{token:"constant.numeric",regex:f},{token:"constant.numeric",regex:"#[a-f0-9]{6}"},{token:"constant.numeric",regex:"#[a-f0-9]{3}"},{token:["punctuation","entity.other.attribute-name.pseudo-element.css"],regex:u},{token:["punctuation","entity.other.attribute-name.pseudo-class.css"],regex:i},{include:"url"},{token:m,regex:"\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"},{token:"paren.lparen",regex:"\\{"},{caseInsensitive:!0}],url:[{token:"support.function",regex:"(?:url(:?-prefix)?|domain|regexp)\\(",push:[{token:"support.function",regex:"\\)",next:"pop"},{defaultToken:"string"}]}],strings:[{token:"string.start",regex:"'",push:[{token:"string.end",regex:"'|$",next:"pop"},{include:"escapes"},{token:"constant.language.escape",regex:/\\$/,consumeLineEnd:!0},{defaultToken:"string"}]},{token:"string.start",regex:'"',push:[{token:"string.end",regex:'"|$',next:"pop"},{include:"escapes"},{token:"constant.language.escape",regex:/\\$/,consumeLineEnd:!0},{defaultToken:"string"}]}],escapes:[{token:"constant.language.escape",regex:/\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/}]},this.normalizeRules()};d.inherits(a,h),r.CssHighlightRules=a}),ace.define("ace/mode/jsdoc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,l){var d=t("../lib/oop"),h=t("./text_highlight_rules").TextHighlightRules,b=function(){this.$rules={start:[{token:["comment.doc.tag","comment.doc.text","lparen.doc"],regex:"(@(?:param|member|typedef|property|namespace|var|const|callback))(\\s*)({)",push:[{token:"lparen.doc",regex:"{",push:[{include:"doc-syntax"},{token:"rparen.doc",regex:"}|(?=$)",next:"pop"}]},{token:["rparen.doc","text.doc","variable.parameter.doc","lparen.doc","variable.parameter.doc","rparen.doc"],regex:/(})(\s*)(?:([\w=:\/\.]+)|(?:(\[)([\w=:\/\.\-\'\" ]+)(\])))/,next:"pop"},{token:"rparen.doc",regex:"}|(?=$)",next:"pop"},{include:"doc-syntax"},{defaultToken:"text.doc"}]},{token:["comment.doc.tag","text.doc","lparen.doc"],regex:"(@(?:returns?|yields|type|this|suppress|public|protected|private|package|modifies|implements|external|exception|throws|enum|define|extends))(\\s*)({)",push:[{token:"lparen.doc",regex:"{",push:[{include:"doc-syntax"},{token:"rparen.doc",regex:"}|(?=$)",next:"pop"}]},{token:"rparen.doc",regex:"}|(?=$)",next:"pop"},{include:"doc-syntax"},{defaultToken:"text.doc"}]},{token:["comment.doc.tag","text.doc","variable.parameter.doc"],regex:'(@(?:alias|memberof|instance|module|name|lends|namespace|external|this|template|requires|param|implements|function|extends|typedef|mixes|constructor|var|memberof\\!|event|listens|exports|class|constructs|interface|emits|fires|throws|const|callback|borrows|augments))(\\s+)(\\w[\\w#.:/~"\\-]*)?'},{token:["comment.doc.tag","text.doc","variable.parameter.doc"],regex:"(@method)(\\s+)(\\w[\\w.\\(\\)]*)"},{token:"comment.doc.tag",regex:"@access\\s+(?:private|public|protected)"},{token:"comment.doc.tag",regex:"@kind\\s+(?:class|constant|event|external|file|function|member|mixin|module|namespace|typedef)"},{token:"comment.doc.tag",regex:"@\\w+(?=\\s|$)"},b.getTagRule(),{defaultToken:"comment.doc.body",caseInsensitive:!0}],"doc-syntax":[{token:"operator.doc",regex:/[|:]/},{token:"paren.doc",regex:/[\[\]]/}]},this.normalizeRules()};d.inherits(b,h),b.getTagRule=function(p){return{token:"comment.doc.tag.storage.type",regex:"\\b(?:TODO|FIXME|XXX|HACK)\\b"}},b.getStartRule=function(p){return{token:"comment.doc",regex:/\/\*\*(?!\/)/,next:p}},b.getEndRule=function(p){return{token:"comment.doc",regex:"\\*\\/",next:p}},r.JsDocCommentHighlightRules=b}),ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/jsdoc_comment_highlight_rules","ace/mode/text_highlight_rules"],function(t,r,l){function d(){var f=o.replace("\\d","\\d\\-"),u={onMatch:function(a,m,w){var x=a.charAt(1)=="/"?2:1;return x==1?(m!=this.nextState?w.unshift(this.next,this.nextState,0):w.unshift(this.next),w[2]++):x==2&&m==this.nextState&&(w[1]--,(!w[1]||w[1]<0)&&(w.shift(),w.shift())),[{type:"meta.tag.punctuation."+(x==1?"":"end-")+"tag-open.xml",value:a.slice(0,x)},{type:"meta.tag.tag-name.xml",value:a.substr(x)}]},regex:"</?(?:"+f+"|(?=>))",next:"jsxAttributes",nextState:"jsx"};this.$rules.start.unshift(u);var i={regex:"{",token:"paren.quasi.start",push:"start"};this.$rules.jsx=[i,u,{include:"reference"},{defaultToken:"string.xml"}],this.$rules.jsxAttributes=[{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",onMatch:function(a,m,w){return m==w[0]&&w.shift(),a.length==2&&(w[0]==this.nextState&&w[1]--,(!w[1]||w[1]<0)&&w.splice(0,2)),this.next=w[0]||"start",[{type:this.token,value:a}]},nextState:"jsx"},i,h("jsxAttributes"),{token:"entity.other.attribute-name.xml",regex:f},{token:"keyword.operator.attribute-equals.xml",regex:"="},{token:"text.tag-whitespace.xml",regex:"\\s+"},{token:"string.attribute-value.xml",regex:"'",stateName:"jsx_attr_q",push:[{token:"string.attribute-value.xml",regex:"'",next:"pop"},{include:"reference"},{defaultToken:"string.attribute-value.xml"}]},{token:"string.attribute-value.xml",regex:'"',stateName:"jsx_attr_qq",push:[{token:"string.attribute-value.xml",regex:'"',next:"pop"},{include:"reference"},{defaultToken:"string.attribute-value.xml"}]},u],this.$rules.reference=[{token:"constant.language.escape.reference.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}]}function h(f){return[{token:"comment",regex:/\/\*/,next:[p.getTagRule(),{token:"comment",regex:"\\*\\/",next:f||"pop"},{defaultToken:"comment",caseInsensitive:!0}]},{token:"comment",regex:"\\/\\/",next:[p.getTagRule(),{token:"comment",regex:"$|^",next:f||"pop"},{defaultToken:"comment",caseInsensitive:!0}]}]}var b=t("../lib/oop"),p=t("./jsdoc_comment_highlight_rules").JsDocCommentHighlightRules,g=t("./text_highlight_rules").TextHighlightRules,o="[a-zA-Z\\$_¡-][a-zA-Z\\d\\$_¡-]*",c=function(f){var u={"variable.language":"Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|Symbol|Namespace|QName|XML|XMLList|ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|SyntaxError|TypeError|URIError|decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|isNaN|parseFloat|parseInt|JSON|Math|this|arguments|prototype|window|document",keyword:"const|yield|import|get|set|async|await|break|case|catch|continue|default|delete|do|else|finally|for|if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|__parent__|__count__|escape|unescape|with|__proto__|class|enum|extends|super|export|implements|private|public|interface|package|protected|static|constructor","storage.type":"const|let|var|function","constant.language":"null|Infinity|NaN|undefined","support.function":"alert","constant.language.boolean":"true|false"},i=this.createKeywordMapper(u,"identifier"),a="case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void",m="\\\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|u{[0-9a-fA-F]{1,6}}|[0-2][0-7]{0,2}|3[0-7][0-7]?|[4-7][0-7]?|.)",w="(function)(\\s*)(\\*?)",x={token:["identifier","text","paren.lparen"],regex:"(\\b(?!"+Object.values(u).join("|")+"\\b)"+o+")(\\s*)(\\()"};this.$rules={no_regex:[p.getStartRule("doc-start"),h("no_regex"),x,{token:"string",regex:"'(?=.)",next:"qstring"},{token:"string",regex:'"(?=.)',next:"qqstring"},{token:"constant.numeric",regex:/0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/},{token:"constant.numeric",regex:/(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/},{token:["entity.name.function","text","keyword.operator","text","storage.type","text","storage.type","text","paren.lparen"],regex:"("+o+")(\\s*)(=)(\\s*)"+w+"(\\s*)(\\()",next:"function_arguments"},{token:["storage.type","text","storage.type","text","text","entity.name.function","text","paren.lparen"],regex:"(function)(?:(?:(\\s*)(\\*)(\\s*))|(\\s+))("+o+")(\\s*)(\\()",next:"function_arguments"},{token:["entity.name.function","text","punctuation.operator","text","storage.type","text","storage.type","text","paren.lparen"],regex:"("+o+")(\\s*)(:)(\\s*)"+w+"(\\s*)(\\()",next:"function_arguments"},{token:["text","text","storage.type","text","storage.type","text","paren.lparen"],regex:"(:)(\\s*)"+w+"(\\s*)(\\()",next:"function_arguments"},{token:"keyword",regex:`from(?=\\s*('|"))`},{token:"keyword",regex:"(?:"+a+")\\b",next:"start"},{token:"support.constant",regex:/that\b/},{token:["storage.type","punctuation.operator","support.function.firebug"],regex:/(console)(\.)(warn|info|log|error|debug|time|trace|timeEnd|assert)\b/},{token:i,regex:o},{token:"punctuation.operator",regex:/[.](?![.])/,next:"property"},{token:"storage.type",regex:/=>/,next:"start"},{token:"keyword.operator",regex:/--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,next:"start"},{token:"punctuation.operator",regex:/[?:,;.]/,next:"start"},{token:"paren.lparen",regex:/[\[({]/,next:"start"},{token:"paren.rparen",regex:/[\])}]/},{token:"comment",regex:/^#!.*$/}],property:[{token:"text",regex:"\\s+"},{token:"keyword.operator",regex:/=/},{token:["storage.type","text","storage.type","text","paren.lparen"],regex:w+"(\\s*)(\\()",next:"function_arguments"},{token:["storage.type","text","storage.type","text","text","entity.name.function","text","paren.lparen"],regex:"(function)(?:(?:(\\s*)(\\*)(\\s*))|(\\s+))(\\w+)(\\s*)(\\()",next:"function_arguments"},{token:"punctuation.operator",regex:/[.](?![.])/},{token:"support.function",regex:"prototype"},{token:"support.function",regex:/(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|lter|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward|rEach)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/},{token:"support.function.dom",regex:/(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/},{token:"support.constant",regex:/(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/},{token:"identifier",regex:o},{regex:"",token:"empty",next:"no_regex"}],start:[p.getStartRule("doc-start"),h("start"),{token:"string.regexp",regex:"\\/",next:"regex"},{token:"text",regex:"\\s+|^$",next:"start"},{token:"empty",regex:"",next:"no_regex"}],regex:[{token:"regexp.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"string.regexp",regex:"/[sxngimy]*",next:"no_regex"},{token:"invalid",regex:/\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/},{token:"constant.language.escape",regex:/\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/},{token:"constant.language.delimiter",regex:/\|/},{token:"constant.language.escape",regex:/\[\^?/,next:"regex_character_class"},{token:"empty",regex:"$",next:"no_regex"},{defaultToken:"string.regexp"}],regex_character_class:[{token:"regexp.charclass.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"constant.language.escape",regex:"]",next:"regex"},{token:"constant.language.escape",regex:"-"},{token:"empty",regex:"$",next:"no_regex"},{defaultToken:"string.regexp.charachterclass"}],default_parameter:[{token:"string",regex:"'(?=.)",push:[{token:"string",regex:"'|$",next:"pop"},{include:"qstring"}]},{token:"string",regex:'"(?=.)',push:[{token:"string",regex:'"|$',next:"pop"},{include:"qqstring"}]},{token:"constant.language",regex:"null|Infinity|NaN|undefined"},{token:"constant.numeric",regex:/0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/},{token:"constant.numeric",regex:/(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/},{token:"punctuation.operator",regex:",",next:"function_arguments"},{token:"text",regex:"\\s+"},{token:"punctuation.operator",regex:"$"},{token:"empty",regex:"",next:"no_regex"}],function_arguments:[h("function_arguments"),{token:"variable.parameter",regex:o},{token:"punctuation.operator",regex:","},{token:"text",regex:"\\s+"},{token:"punctuation.operator",regex:"$"},{token:"empty",regex:"",next:"no_regex"}],qqstring:[{token:"constant.language.escape",regex:m},{token:"string",regex:"\\\\$",consumeLineEnd:!0},{token:"string",regex:'"|$',next:"no_regex"},{defaultToken:"string"}],qstring:[{token:"constant.language.escape",regex:m},{token:"string",regex:"\\\\$",consumeLineEnd:!0},{token:"string",regex:"'|$",next:"no_regex"},{defaultToken:"string"}]},(!f||!f.noES6)&&(this.$rules.no_regex.unshift({regex:"[{}]",onMatch:function(M,$,S){if(this.next=M=="{"?this.nextState:"",M=="{"&&S.length)S.unshift("start",$);else if(M=="}"&&S.length&&(S.shift(),this.next=S.shift(),this.next.indexOf("string")!=-1||this.next.indexOf("jsx")!=-1))return"paren.quasi.end";return M=="{"?"paren.lparen":"paren.rparen"},nextState:"start"},{token:"string.quasi.start",regex:/`/,push:[{token:"constant.language.escape",regex:m},{token:"paren.quasi.start",regex:/\${/,push:"start"},{token:"string.quasi.end",regex:/`/,next:"pop"},{defaultToken:"string.quasi"}]},{token:["variable.parameter","text"],regex:"("+o+")(\\s*)(?=\\=>)"},{token:"paren.lparen",regex:"(\\()(?=[^\\(]+\\s*=>)",next:"function_arguments"},{token:"variable.language",regex:"(?:(?:(?:Weak)?(?:Set|Map))|Promise)\\b"}),this.$rules.function_arguments.unshift({token:"keyword.operator",regex:"=",next:"default_parameter"},{token:"keyword.operator",regex:"\\.{3}"}),this.$rules.property.unshift({token:"support.function",regex:"(findIndex|repeat|startsWith|endsWith|includes|isSafeInteger|trunc|cbrt|log2|log10|sign|then|catch|finally|resolve|reject|race|any|all|allSettled|keys|entries|isInteger)\\b(?=\\()"},{token:"constant.language",regex:"(?:MAX_SAFE_INTEGER|MIN_SAFE_INTEGER|EPSILON)\\b"}),(!f||f.jsx!=0)&&d.call(this)),this.embedRules(p,"doc-",[p.getEndRule("no_regex")]),this.normalizeRules()};b.inherits(c,g),r.JavaScriptHighlightRules=c}),ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,l){var d=t("../lib/oop"),h=t("./text_highlight_rules").TextHighlightRules,b=function(p){var g="[_:a-zA-ZÀ-][-_:.a-zA-Z0-9À-]*";this.$rules={start:[{token:"string.cdata.xml",regex:"<\\!\\[CDATA\\[",next:"cdata"},{token:["punctuation.instruction.xml","keyword.instruction.xml"],regex:"(<\\?)("+g+")",next:"processing_instruction"},{token:"comment.start.xml",regex:"<\\!--",next:"comment"},{token:["xml-pe.doctype.xml","xml-pe.doctype.xml"],regex:"(<\\!)(DOCTYPE)(?=[\\s])",next:"doctype",caseInsensitive:!0},{include:"tag"},{token:"text.end-tag-open.xml",regex:"</"},{token:"text.tag-open.xml",regex:"<"},{include:"reference"},{defaultToken:"text.xml"}],processing_instruction:[{token:"entity.other.attribute-name.decl-attribute-name.xml",regex:g},{token:"keyword.operator.decl-attribute-equals.xml",regex:"="},{include:"whitespace"},{include:"string"},{token:"punctuation.xml-decl.xml",regex:"\\?>",next:"start"}],doctype:[{include:"whitespace"},{include:"string"},{token:"xml-pe.doctype.xml",regex:">",next:"start"},{token:"xml-pe.xml",regex:"[-_a-zA-Z0-9:]+"},{token:"punctuation.int-subset",regex:"\\[",push:"int_subset"}],int_subset:[{token:"text.xml",regex:"\\s+"},{token:"punctuation.int-subset.xml",regex:"]",next:"pop"},{token:["punctuation.markup-decl.xml","keyword.markup-decl.xml"],regex:"(<\\!)("+g+")",push:[{token:"text",regex:"\\s+"},{token:"punctuation.markup-decl.xml",regex:">",next:"pop"},{include:"string"}]}],cdata:[{token:"string.cdata.xml",regex:"\\]\\]>",next:"start"},{token:"text.xml",regex:"\\s+"},{token:"text.xml",regex:"(?:[^\\]]|\\](?!\\]>))+"}],comment:[{token:"comment.end.xml",regex:"-->",next:"start"},{defaultToken:"comment.xml"}],reference:[{token:"constant.language.escape.reference.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}],attr_reference:[{token:"constant.language.escape.reference.attribute-value.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}],tag:[{token:["meta.tag.punctuation.tag-open.xml","meta.tag.punctuation.end-tag-open.xml","meta.tag.tag-name.xml"],regex:"(?:(<)|(</))((?:"+g+":)?"+g+")",next:[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start"}]}],tag_whitespace:[{token:"text.tag-whitespace.xml",regex:"\\s+"}],whitespace:[{token:"text.whitespace.xml",regex:"\\s+"}],string:[{token:"string.xml",regex:"'",push:[{token:"string.xml",regex:"'",next:"pop"},{defaultToken:"string.xml"}]},{token:"string.xml",regex:'"',push:[{token:"string.xml",regex:'"',next:"pop"},{defaultToken:"string.xml"}]}],attributes:[{token:"entity.other.attribute-name.xml",regex:g},{token:"keyword.operator.attribute-equals.xml",regex:"="},{include:"tag_whitespace"},{include:"attribute_value"}],attribute_value:[{token:"string.attribute-value.xml",regex:"'",push:[{token:"string.attribute-value.xml",regex:"'",next:"pop"},{include:"attr_reference"},{defaultToken:"string.attribute-value.xml"}]},{token:"string.attribute-value.xml",regex:'"',push:[{token:"string.attribute-value.xml",regex:'"',next:"pop"},{include:"attr_reference"},{defaultToken:"string.attribute-value.xml"}]}]},this.constructor===b&&this.normalizeRules()};(function(){this.embedTagRules=function(p,g,o){this.$rules.tag.unshift({token:["meta.tag.punctuation.tag-open.xml","meta.tag."+o+".tag-name.xml"],regex:"(<)("+o+"(?=\\s|>|$))",next:[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:g+"start"}]}),this.$rules[o+"-end"]=[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start",onMatch:function(c,f,u){return u.splice(0),this.token}}],this.embedRules(p,g,[{token:["meta.tag.punctuation.end-tag-open.xml","meta.tag."+o+".tag-name.xml"],regex:"(</)("+o+"(?=\\s|>|$))",next:o+"-end"},{token:"string.cdata.xml",regex:"<\\!\\[CDATA\\["},{token:"string.cdata.xml",regex:"\\]\\]>"}])}}).call(h.prototype),d.inherits(b,h),r.XmlHighlightRules=b}),ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"],function(t,r,l){var d=t("../lib/oop"),h=t("../lib/lang"),b=t("./css_highlight_rules").CssHighlightRules,p=t("./javascript_highlight_rules").JavaScriptHighlightRules,g=t("./xml_highlight_rules").XmlHighlightRules,o=h.createMap({a:"anchor",button:"form",form:"form",img:"image",input:"form",label:"form",option:"form",script:"script",select:"form",textarea:"form",style:"style",table:"table",tbody:"table",td:"table",tfoot:"table",th:"table",tr:"table"}),c=function(){g.call(this),this.addRules({attributes:[{include:"tag_whitespace"},{token:"entity.other.attribute-name.xml",regex:"[-_a-zA-Z0-9:.]+"},{token:"keyword.operator.attribute-equals.xml",regex:"=",push:[{include:"tag_whitespace"},{token:"string.unquoted.attribute-value.html",regex:"[^<>='\"`\\s]+",next:"pop"},{token:"empty",regex:"",next:"pop"}]},{include:"attribute_value"}],tag:[{token:function(f,u){var i=o[u];return["meta.tag.punctuation."+(f=="<"?"":"end-")+"tag-open.xml","meta.tag"+(i?"."+i:"")+".tag-name.xml"]},regex:"(</?)([-_a-zA-Z0-9:.]+)",next:"tag_stuff"}],tag_stuff:[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start"}]}),this.embedTagRules(b,"css-","style"),this.embedTagRules(new p({jsx:!1}).getRules(),"js-","script"),this.constructor===c&&this.normalizeRules()};d.inherits(c,g),r.HtmlHighlightRules=c}),ace.define("ace/mode/markdown_highlight_rules",["require","exports","module","ace/config","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/html_highlight_rules"],function(t,r,l){var d=t("../config").$modes,h=t("../lib/oop"),b=t("../lib/lang"),p=t("./text_highlight_rules").TextHighlightRules,g=t("./html_highlight_rules").HtmlHighlightRules,o=function(f){return"(?:[^"+b.escapeRegExp(f)+"\\\\]|\\\\.)*"},c=function(){g.call(this);var f={token:"support.function",regex:/^\s*(```+[^`]*|~~~+[^~]*)$/,onMatch:function(i,a,m,w){var x=i.match(/^(\s*)([`~]+)(.*)/),M=/[\w-]+|$/.exec(x[3])[0];return d[M]||(M=""),m.unshift("githubblock",[],[x[1],x[2],M],a),this.token},next:"githubblock"},u=[{token:"support.function",regex:".*",onMatch:function(i,a,m,w){var x=m[1],M=m[2][0],$=m[2][1],S=m[2][2],k=/^(\s*)(`+|~+)\s*$/.exec(i);if(k&&k[1].length<M.length+3&&k[2].length>=$.length&&k[2][0]==$[0])return m.splice(0,3),this.next=m.shift(),this.token;if(this.next="",S&&d[S]){var T=d[S].getTokenizer().getLineTokens(i,x.slice(0));return m[1]=T.state,T.tokens}return this.token}}];this.$rules.start.unshift({token:"empty_line",regex:"^$",next:"allowBlock"},{token:"markup.heading.1",regex:"^=+(?=\\s*$)"},{token:"markup.heading.2",regex:"^\\-+(?=\\s*$)"},{token:function(i){return"markup.heading."+i.length},regex:/^#{1,6}(?=\s|$)/,next:"header"},f,{token:"string.blockquote",regex:"^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",next:"blockquote"},{token:"constant",regex:"^ {0,3}(?:(?:\\* ?){3,}|(?:\\- ?){3,}|(?:\\_ ?){3,})\\s*$",next:"allowBlock"},{token:"markup.list",regex:"^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",next:"listblock-start"},{include:"basic"}),this.addRules({basic:[{token:"constant.language.escape",regex:/\\[\\`*_{}\[\]()#+\-.!]/},{token:"support.function",regex:"(`+)(.*?[^`])(\\1)"},{token:["text","constant","text","url","string","text"],regex:'^([ ]{0,3}\\[)([^\\]]+)(\\]:\\s*)([^ ]+)(\\s*(?:["][^"]+["])?(\\s*))$'},{token:["text","string","text","constant","text"],regex:"(\\[)("+o("]")+")(\\]\\s*\\[)("+o("]")+")(\\])"},{token:["text","string","text","markup.underline","string","text"],regex:"(\\!?\\[)("+o("]")+')(\\]\\()((?:[^\\)\\s\\\\]|\\\\.|\\s(?=[^"]))*)(\\s*"'+o('"')+'"\\s*)?(\\))'},{token:"string.strong",regex:"([*]{2}|[_]{2}(?=\\S))(.*?\\S[*_]*)(\\1)"},{token:"string.emphasis",regex:"([*]|[_](?=\\S))(.*?\\S[*_]*)(\\1)"},{token:["text","url","text"],regex:`(<)((?:https?|ftp|dict):[^'">\\s]+|(?:mailto:)?[-.\\w]+\\@[-a-z0-9]+(?:\\.[-a-z0-9]+)*\\.[a-z]+)(>)`}],allowBlock:[{token:"support.function",regex:"^ {4}.+",next:"allowBlock"},{token:"empty_line",regex:"^$",next:"allowBlock"},{token:"empty",regex:"",next:"start"}],header:[{regex:"$",next:"start"},{include:"basic"},{defaultToken:"heading"}],"listblock-start":[{token:"support.variable",regex:/(?:\[[ x]\])?/,next:"listblock"}],listblock:[{token:"empty_line",regex:"^$",next:"start"},{token:"markup.list",regex:"^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",next:"listblock-start"},{include:"basic",noEscape:!0},f,{defaultToken:"list"}],blockquote:[{token:"empty_line",regex:"^\\s*$",next:"start"},{token:"string.blockquote",regex:"^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",next:"blockquote"},{include:"basic",noEscape:!0},{defaultToken:"string.blockquote"}],githubblock:u}),this.normalizeRules()};h.inherits(c,p),r.MarkdownHighlightRules=c}),ace.define("ace/mode/folding/markdown",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"],function(t,r,l){var d=t("../../lib/oop"),h=t("./fold_mode").FoldMode,b=t("../../range").Range,p=r.FoldMode=function(){};d.inherits(p,h),(function(){this.foldingStartMarker=/^(?:[=-]+\s*$|#{1,6} |`{3})/,this.getFoldWidget=function(g,o,c){var f=g.getLine(c);return this.foldingStartMarker.test(f)?f[0]=="`"&&g.bgTokenizer.getState(c)=="start"?"end":"start":""},this.getFoldWidgetRange=function(g,o,c){function f(D){return M=g.getTokens(D)[0],M&&M.type.lastIndexOf($,0)===0}function u(){var D=M.value[0];return D=="="?6:D=="-"?5:7-M.value.search(/[^#]|$/)}var i=g.getLine(c),a=i.length,m=g.getLength(),w=c,x=c;if(i.match(this.foldingStartMarker)){if(i[0]=="`"){if(g.bgTokenizer.getState(c)!=="start"){for(;++c<m&&(i=g.getLine(c),!(i[0]=="`"&i.substring(0,3)=="```")););return new b(w,a,c,0)}for(;c-- >0&&(i=g.getLine(c),!(i[0]=="`"&i.substring(0,3)=="```")););return new b(c,i.length,w,0)}var M,$="markup.heading";if(f(c)){for(var S=u();++c<m;)if(f(c)){var k=u();if(k>=S)break}if(x=c-(!M||["=","-"].indexOf(M.value[0])==-1?1:2),x>w)for(;x>w&&/^\s*$/.test(g.getLine(x));)x--;if(x>w){var T=g.getLine(x).length;return new b(w,a,x,T)}}}}}).call(p.prototype)}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(t,r,l){var d=t("../range").Range,h=function(){};(function(){this.checkOutdent=function(b,p){return/^\s+$/.test(b)?/^\s*\}/.test(p):!1},this.autoOutdent=function(b,p){var g=b.getLine(p),o=g.match(/^(\s*\})/);if(!o)return 0;var c=o[1].length,f=b.findMatchingBracket({row:p,column:c});if(!f||f.row==p)return 0;var u=this.$getIndent(b.getLine(f.row));b.replace(new d(p,0,p,c-1),u)},this.$getIndent=function(b){return b.match(/^\s*/)[0]}}).call(h.prototype),r.MatchingBraceOutdent=h}),ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator"],function(t,r,l){function d(o,c){return o&&o.type.lastIndexOf(c+".xml")>-1}var h=t("../../lib/oop"),b=t("../behaviour").Behaviour,p=t("../../token_iterator").TokenIterator,g=function(){this.add("string_dquotes","insertion",function(o,c,f,u,i){if(i=='"'||i=="'"){var a=i,m=u.doc.getTextRange(f.getSelectionRange());if(m!==""&&m!=="'"&&m!='"'&&f.getWrapBehavioursEnabled())return{text:a+m+a,selection:!1};var w=f.getCursorPosition(),x=u.doc.getLine(w.row),M=x.substring(w.column,w.column+1),$=new p(u,w.row,w.column),S=$.getCurrentToken();if(M==a&&(d(S,"attribute-value")||d(S,"string")))return{text:"",selection:[1,1]};if(S||(S=$.stepBackward()),!S)return;for(;d(S,"tag-whitespace")||d(S,"whitespace");)S=$.stepBackward();var k=!M||M.match(/\s/);if(d(S,"attribute-equals")&&(k||M==">")||d(S,"decl-attribute-equals")&&(k||M=="?"))return{text:a+a,selection:[1,1]}}}),this.add("string_dquotes","deletion",function(o,c,f,u,i){var a=u.doc.getTextRange(i);if(!i.isMultiLine()&&(a=='"'||a=="'")){var m=u.doc.getLine(i.start.row),w=m.substring(i.start.column+1,i.start.column+2);if(w==a)return i.end.column++,i}}),this.add("autoclosing","insertion",function(o,c,f,u,i){if(i==">"){var a=f.getSelectionRange().start,m=new p(u,a.row,a.column),w=m.getCurrentToken()||m.stepBackward();if(!w||!(d(w,"tag-name")||d(w,"tag-whitespace")||d(w,"attribute-name")||d(w,"attribute-equals")||d(w,"attribute-value"))||d(w,"reference.attribute-value"))return;if(d(w,"attribute-value")){var x=m.getCurrentTokenColumn()+w.value.length;if(a.column<x)return;if(a.column==x){var M=m.stepForward();if(M&&d(M,"attribute-value"))return;m.stepBackward()}}if(/^\s*>/.test(u.getLine(a.row).slice(a.column)))return;for(;!d(w,"tag-name");)if(w=m.stepBackward(),w.value=="<"){w=m.stepForward();break}var $=m.getCurrentTokenRow(),S=m.getCurrentTokenColumn();if(d(m.stepBackward(),"end-tag-open"))return;var k=w.value;return $==a.row&&(k=k.substring(0,a.column-S)),this.voidElements&&this.voidElements.hasOwnProperty(k.toLowerCase())?void 0:{text:"></"+k+">",selection:[1,1]}}}),this.add("autoindent","insertion",function(o,c,f,u,i){if(i==`
|
|
994
|
+
`){var a=f.getCursorPosition(),m=u.getLine(a.row),w=new p(u,a.row,a.column),x=w.getCurrentToken();if(d(x,"")&&x.type.indexOf("tag-close")!==-1){if(x.value=="/>")return;for(;x&&x.type.indexOf("tag-name")===-1;)x=w.stepBackward();if(!x)return;var M=x.value,$=w.getCurrentTokenRow();if(x=w.stepBackward(),!x||x.type.indexOf("end-tag")!==-1)return;if(this.voidElements&&!this.voidElements[M]||!this.voidElements){var S=u.getTokenAt(a.row,a.column+1),m=u.getLine($),k=this.$getIndent(m),T=k+u.getTabString();return S&&S.value==="</"?{text:`
|
|
995
|
+
`+T+`
|
|
996
|
+
`+k,selection:[1,T.length,1,T.length]}:{text:`
|
|
997
|
+
`+T}}}}})};h.inherits(g,b),r.XmlBehaviour=g}),ace.define("ace/mode/behaviour/javascript",["require","exports","module","ace/lib/oop","ace/token_iterator","ace/mode/behaviour/cstyle","ace/mode/behaviour/xml"],function(t,r,l){var d=t("../../lib/oop"),h=t("../../token_iterator").TokenIterator,b=t("../behaviour/cstyle").CstyleBehaviour,p=t("../behaviour/xml").XmlBehaviour,g=function(){var o=new p({closeCurlyBraces:!0}).getBehaviours();this.addBehaviours(o),this.inherit(b),this.add("autoclosing-fragment","insertion",function(c,f,u,i,a){if(a==">"){var m=u.getSelectionRange().start,w=new h(i,m.row,m.column),x=w.getCurrentToken()||w.stepBackward();if(!x)return;if(x.value=="<")return{text:"></>",selection:[1,1]}}})};d.inherits(g,b),r.JavaScriptBehaviour=g}),ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(t,r,l){function d(c,f){return c&&c.type&&c.type.lastIndexOf(f+".xml")>-1}var h=t("../../lib/oop"),b=t("../../range").Range,p=t("./fold_mode").FoldMode,g=r.FoldMode=function(c,f){p.call(this),this.voidElements=c||{},this.optionalEndTags=h.mixin({},this.voidElements),f&&h.mixin(this.optionalEndTags,f)};h.inherits(g,p);var o=function(){this.tagName="",this.closing=!1,this.selfClosing=!1,this.start={row:0,column:0},this.end={row:0,column:0}};(function(){this.getFoldWidget=function(c,f,u){var i=this._getFirstTagInLine(c,u);return i?i.closing||!i.tagName&&i.selfClosing?f==="markbeginend"?"end":"":!i.tagName||i.selfClosing||this.voidElements.hasOwnProperty(i.tagName.toLowerCase())||this._findEndTagInLine(c,u,i.tagName,i.end.column)?"":"start":this.getCommentFoldWidget(c,u)},this.getCommentFoldWidget=function(c,f){return/comment/.test(c.getState(f))&&/<!-/.test(c.getLine(f))?"start":""},this._getFirstTagInLine=function(c,f){for(var u=c.getTokens(f),i=new o,a=0;a<u.length;a++){var m=u[a];if(d(m,"tag-open")){if(i.end.column=i.start.column+m.value.length,i.closing=d(m,"end-tag-open"),m=u[++a],!m)return null;if(i.tagName=m.value,m.value===""){if(m=u[++a],!m)return null;i.tagName=m.value}for(i.end.column+=m.value.length,a++;a<u.length;a++)if(m=u[a],i.end.column+=m.value.length,d(m,"tag-close")){i.selfClosing=m.value=="/>";break}return i}if(d(m,"tag-close"))return i.selfClosing=m.value=="/>",i;i.start.column+=m.value.length}return null},this._findEndTagInLine=function(c,f,u,i){for(var a=c.getTokens(f),m=0,w=0;w<a.length;w++){var x=a[w];if(m+=x.value.length,!(m<i-1)&&d(x,"end-tag-open")&&(x=a[w+1],d(x,"tag-name")&&x.value===""&&(x=a[w+2]),x&&x.value==u))return!0}return!1},this.getFoldWidgetRange=function(c,f,u){var i=this._getFirstTagInLine(c,u);if(!i)return this.getCommentFoldWidget(c,u)&&c.getCommentFoldRange(u,c.getLine(u).length);var a=c.getMatchingTags({row:u,column:0});if(a)return new b(a.openTag.end.row,a.openTag.end.column,a.closeTag.start.row,a.closeTag.start.column)}}).call(g.prototype)}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(t,r,l){var d=t("../../lib/oop"),h=t("../../range").Range,b=t("./fold_mode").FoldMode,p=r.FoldMode=function(g){g&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+g.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+g.end)))};d.inherits(p,b),(function(){this.foldingStartMarker=/([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(g,o,c){var f=g.getLine(c);if(this.singleLineBlockCommentRe.test(f)&&!this.startRegionRe.test(f)&&!this.tripleStarBlockCommentRe.test(f))return"";var u=this._getFoldWidgetBase(g,o,c);return!u&&this.startRegionRe.test(f)?"start":u},this.getFoldWidgetRange=function(g,o,c,f){var u=g.getLine(c);if(this.startRegionRe.test(u))return this.getCommentRegionBlock(g,u,c);var i=u.match(this.foldingStartMarker);if(i){var a=i.index;if(i[1])return this.openingBracketBlock(g,i[1],c,a);var m=g.getCommentFoldRange(c,a+i[0].length,1);return m&&!m.isMultiLine()&&(f?m=this.getSectionRange(g,c):o!="all"&&(m=null)),m}if(o!=="markbegin"){var i=u.match(this.foldingStopMarker);if(i){var a=i.index+i[0].length;return i[1]?this.closingBracketBlock(g,i[1],c,a):g.getCommentFoldRange(c,a,-1)}}},this.getSectionRange=function(g,o){var c=g.getLine(o),f=c.search(/\S/),u=o,i=c.length;o+=1;for(var a=o,m=g.getLength();++o<m;){c=g.getLine(o);var w=c.search(/\S/);if(w!==-1){if(f>w)break;var x=this.getFoldWidgetRange(g,"all",o);if(x){if(x.start.row<=u)break;if(x.isMultiLine())o=x.end.row;else if(f==w)break}a=o}}return new h(u,i,a,g.getLine(a).length)},this.getCommentRegionBlock=function(g,o,c){for(var f=o.search(/\s*$/),u=g.getLength(),i=c,a=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,m=1;++c<u;){o=g.getLine(c);var w=a.exec(o);if(w&&(w[1]?m--:m++,!m))break}var x=c;if(x>i)return new h(i,f,x,o.length)}}).call(p.prototype)}),ace.define("ace/mode/folding/javascript",["require","exports","module","ace/lib/oop","ace/mode/folding/xml","ace/mode/folding/cstyle"],function(t,r,l){var d=t("../../lib/oop"),h=t("./xml").FoldMode,b=t("./cstyle").FoldMode,p=r.FoldMode=function(g){g&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+g.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+g.end))),this.xmlFoldMode=new h};d.inherits(p,b),(function(){this.getFoldWidgetRangeBase=this.getFoldWidgetRange,this.getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(g,o,c){var f=this.getFoldWidgetBase(g,o,c);return f||this.xmlFoldMode.getFoldWidget(g,o,c)},this.getFoldWidgetRange=function(g,o,c,f){var u=this.getFoldWidgetRangeBase(g,o,c,f);return u||this.xmlFoldMode.getFoldWidgetRange(g,o,c)}}).call(p.prototype)}),ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/javascript","ace/mode/folding/javascript"],function(t,r,l){var d=t("../lib/oop"),h=t("./text").Mode,b=t("./javascript_highlight_rules").JavaScriptHighlightRules,p=t("./matching_brace_outdent").MatchingBraceOutdent,g=t("../worker/worker_client").WorkerClient,o=t("./behaviour/javascript").JavaScriptBehaviour,c=t("./folding/javascript").FoldMode,f=function(){this.HighlightRules=b,this.$outdent=new p,this.$behaviour=new o,this.foldingRules=new c};d.inherits(f,h),(function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.$quotes={'"':'"',"'":"'","`":"`"},this.$pairQuotesAfter={"`":/\w/},this.getNextLineIndent=function(u,i,a){var m=this.$getIndent(i),w=this.getTokenizer().getLineTokens(i,u),x=w.tokens,M=w.state;if(x.length&&x[x.length-1].type=="comment")return m;if(u=="start"||u=="no_regex"){var $=i.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);$&&(m+=a)}else if(u=="doc-start"&&(M=="start"||M=="no_regex"))return"";return m},this.checkOutdent=function(u,i,a){return this.$outdent.checkOutdent(i,a)},this.autoOutdent=function(u,i,a){this.$outdent.autoOutdent(i,a)},this.createWorker=function(u){var i=new g(["ace"],"ace/mode/javascript_worker","JavaScriptWorker");return i.attachToDocument(u.getDocument()),i.on("annotate",function(a){u.setAnnotations(a.data)}),i.on("terminate",function(){u.clearAnnotations()}),i},this.$id="ace/mode/javascript",this.snippetFileId="ace/snippets/javascript"}).call(f.prototype),r.Mode=f}),ace.define("ace/mode/css_completions",["require","exports","module"],function(t,r,l){var d={background:{"#$0":1},"background-color":{"#$0":1,transparent:1,fixed:1},"background-image":{"url('/$0')":1},"background-repeat":{repeat:1,"repeat-x":1,"repeat-y":1,"no-repeat":1,inherit:1},"background-position":{bottom:2,center:2,left:2,right:2,top:2,inherit:2},"background-attachment":{scroll:1,fixed:1},"background-size":{cover:1,contain:1},"background-clip":{"border-box":1,"padding-box":1,"content-box":1},"background-origin":{"border-box":1,"padding-box":1,"content-box":1},border:{"solid $0":1,"dashed $0":1,"dotted $0":1,"#$0":1},"border-color":{"#$0":1},"border-style":{solid:2,dashed:2,dotted:2,double:2,groove:2,hidden:2,inherit:2,inset:2,none:2,outset:2,ridged:2},"border-collapse":{collapse:1,separate:1},bottom:{px:1,em:1,"%":1},clear:{left:1,right:1,both:1,none:1},color:{"#$0":1,"rgb(#$00,0,0)":1},cursor:{default:1,pointer:1,move:1,text:1,wait:1,help:1,progress:1,"n-resize":1,"ne-resize":1,"e-resize":1,"se-resize":1,"s-resize":1,"sw-resize":1,"w-resize":1,"nw-resize":1},display:{none:1,block:1,inline:1,"inline-block":1,"table-cell":1},"empty-cells":{show:1,hide:1},float:{left:1,right:1,none:1},"font-family":{Arial:2,"Comic Sans MS":2,Consolas:2,"Courier New":2,Courier:2,Georgia:2,Monospace:2,"Sans-Serif":2,"Segoe UI":2,Tahoma:2,"Times New Roman":2,"Trebuchet MS":2,Verdana:1},"font-size":{px:1,em:1,"%":1},"font-weight":{bold:1,normal:1},"font-style":{italic:1,normal:1},"font-variant":{normal:1,"small-caps":1},height:{px:1,em:1,"%":1},left:{px:1,em:1,"%":1},"letter-spacing":{normal:1},"line-height":{normal:1},"list-style-type":{none:1,disc:1,circle:1,square:1,decimal:1,"decimal-leading-zero":1,"lower-roman":1,"upper-roman":1,"lower-greek":1,"lower-latin":1,"upper-latin":1,georgian:1,"lower-alpha":1,"upper-alpha":1},margin:{px:1,em:1,"%":1},"margin-right":{px:1,em:1,"%":1},"margin-left":{px:1,em:1,"%":1},"margin-top":{px:1,em:1,"%":1},"margin-bottom":{px:1,em:1,"%":1},"max-height":{px:1,em:1,"%":1},"max-width":{px:1,em:1,"%":1},"min-height":{px:1,em:1,"%":1},"min-width":{px:1,em:1,"%":1},overflow:{hidden:1,visible:1,auto:1,scroll:1},"overflow-x":{hidden:1,visible:1,auto:1,scroll:1},"overflow-y":{hidden:1,visible:1,auto:1,scroll:1},padding:{px:1,em:1,"%":1},"padding-top":{px:1,em:1,"%":1},"padding-right":{px:1,em:1,"%":1},"padding-bottom":{px:1,em:1,"%":1},"padding-left":{px:1,em:1,"%":1},"page-break-after":{auto:1,always:1,avoid:1,left:1,right:1},"page-break-before":{auto:1,always:1,avoid:1,left:1,right:1},position:{absolute:1,relative:1,fixed:1,static:1},right:{px:1,em:1,"%":1},"table-layout":{fixed:1,auto:1},"text-decoration":{none:1,underline:1,"line-through":1,blink:1},"text-align":{left:1,right:1,center:1,justify:1},"text-transform":{capitalize:1,uppercase:1,lowercase:1,none:1},top:{px:1,em:1,"%":1},"vertical-align":{top:1,bottom:1},visibility:{hidden:1,visible:1},"white-space":{nowrap:1,normal:1,pre:1,"pre-line":1,"pre-wrap":1},width:{px:1,em:1,"%":1},"word-spacing":{normal:1},filter:{"alpha(opacity=$0100)":1},"text-shadow":{"$02px 2px 2px #777":1},"text-overflow":{"ellipsis-word":1,clip:1,ellipsis:1},"-moz-border-radius":1,"-moz-border-radius-topright":1,"-moz-border-radius-bottomright":1,"-moz-border-radius-topleft":1,"-moz-border-radius-bottomleft":1,"-webkit-border-radius":1,"-webkit-border-top-right-radius":1,"-webkit-border-top-left-radius":1,"-webkit-border-bottom-right-radius":1,"-webkit-border-bottom-left-radius":1,"-moz-box-shadow":1,"-webkit-box-shadow":1,transform:{"rotate($00deg)":1,"skew($00deg)":1},"-moz-transform":{"rotate($00deg)":1,"skew($00deg)":1},"-webkit-transform":{"rotate($00deg)":1,"skew($00deg)":1}},h=function(){};(function(){this.completionsDefined=!1,this.defineCompletions=function(){if(document){var b=document.createElement("c").style;for(var p in b)if(typeof b[p]=="string"){var g=p.replace(/[A-Z]/g,function(o){return"-"+o.toLowerCase()});d.hasOwnProperty(g)||(d[g]=1)}}this.completionsDefined=!0},this.getCompletions=function(b,p,g,o){if(this.completionsDefined||this.defineCompletions(),b==="ruleset"||p.$mode.$id=="ace/mode/scss"){var c=p.getLine(g.row).substr(0,g.column),f=/\([^)]*$/.test(c);return f&&(c=c.substr(c.lastIndexOf("(")+1)),/:[^;]+$/.test(c)?this.getPropertyValueCompletions(b,p,g,o):this.getPropertyCompletions(b,p,g,o,f)}return[]},this.getPropertyCompletions=function(b,p,g,o,c){c=c||!1;var f=Object.keys(d);return f.map(function(u){return{caption:u,snippet:u+": $0"+(c?"":";"),meta:"property",score:1e6}})},this.getPropertyValueCompletions=function(b,p,g,o){var c=p.getLine(g.row).substr(0,g.column),f=(/([\w\-]+):[^:]*$/.exec(c)||{})[1];if(!f)return[];var u=[];return f in d&&typeof d[f]=="object"&&(u=Object.keys(d[f])),u.map(function(i){return{caption:i,snippet:i,meta:"property value",score:1e6}})}}).call(h.prototype),r.CssCompletions=h}),ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"],function(t,r,l){var d=t("../../lib/oop");t("../behaviour").Behaviour;var h=t("./cstyle").CstyleBehaviour,b=t("../../token_iterator").TokenIterator,p=function(){this.inherit(h),this.add("colon","insertion",function(g,o,c,f,u){if(u===":"&&c.selection.isEmpty()){var i=c.getCursorPosition(),a=new b(f,i.row,i.column),m=a.getCurrentToken();if(m&&m.value.match(/\s+/)&&(m=a.stepBackward()),m&&m.type==="support.type"){var w=f.doc.getLine(i.row),x=w.substring(i.column,i.column+1);if(x===":")return{text:"",selection:[1,1]};if(/^(\s+[^;]|\s*$)/.test(w.substring(i.column)))return{text:":;",selection:[1,1]}}}}),this.add("colon","deletion",function(g,o,c,f,u){var i=f.doc.getTextRange(u);if(!u.isMultiLine()&&i===":"){var a=c.getCursorPosition(),m=new b(f,a.row,a.column),w=m.getCurrentToken();if(w&&w.value.match(/\s+/)&&(w=m.stepBackward()),w&&w.type==="support.type"){var x=f.doc.getLine(u.start.row),M=x.substring(u.end.column,u.end.column+1);if(M===";")return u.end.column++,u}}}),this.add("semicolon","insertion",function(g,o,c,f,u){if(u===";"&&c.selection.isEmpty()){var i=c.getCursorPosition(),a=f.doc.getLine(i.row),m=a.substring(i.column,i.column+1);if(m===";")return{text:"",selection:[1,1]}}}),this.add("!important","insertion",function(g,o,c,f,u){if(u==="!"&&c.selection.isEmpty()){var i=c.getCursorPosition(),a=f.doc.getLine(i.row);if(/^\s*(;|}|$)/.test(a.substring(i.column)))return{text:"!important",selection:[10,10]}}})};d.inherits(p,h),r.CssBehaviour=p}),ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"],function(t,r,l){var d=t("../lib/oop"),h=t("./text").Mode,b=t("./css_highlight_rules").CssHighlightRules,p=t("./matching_brace_outdent").MatchingBraceOutdent,g=t("../worker/worker_client").WorkerClient,o=t("./css_completions").CssCompletions,c=t("./behaviour/css").CssBehaviour,f=t("./folding/cstyle").FoldMode,u=function(){this.HighlightRules=b,this.$outdent=new p,this.$behaviour=new c,this.$completer=new o,this.foldingRules=new f};d.inherits(u,h),(function(){this.foldingRules="cStyle",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(i,a,m){var w=this.$getIndent(a),x=this.getTokenizer().getLineTokens(a,i).tokens;if(x.length&&x[x.length-1].type=="comment")return w;var M=a.match(/^.*\{\s*$/);return M&&(w+=m),w},this.checkOutdent=function(i,a,m){return this.$outdent.checkOutdent(a,m)},this.autoOutdent=function(i,a,m){this.$outdent.autoOutdent(a,m)},this.getCompletions=function(i,a,m,w){return this.$completer.getCompletions(i,a,m,w)},this.createWorker=function(i){var a=new g(["ace"],"ace/mode/css_worker","Worker");return a.attachToDocument(i.getDocument()),a.on("annotate",function(m){i.setAnnotations(m.data)}),a.on("terminate",function(){i.clearAnnotations()}),a},this.$id="ace/mode/css",this.snippetFileId="ace/snippets/css"}).call(u.prototype),r.Mode=u}),ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"],function(t,r,l){var d=t("../../lib/oop"),h=t("./fold_mode").FoldMode,b=r.FoldMode=function(p,g){this.defaultMode=p,this.subModes=g};d.inherits(b,h),(function(){this.$getMode=function(p){typeof p!="string"&&(p=p[0]);for(var g in this.subModes)if(p.indexOf(g)===0)return this.subModes[g];return null},this.$tryMode=function(p,g,o,c){var f=this.$getMode(p);return f?f.getFoldWidget(g,o,c):""},this.getFoldWidget=function(p,g,o){return this.$tryMode(p.getState(o-1),p,g,o)||this.$tryMode(p.getState(o),p,g,o)||this.defaultMode.getFoldWidget(p,g,o)},this.getFoldWidgetRange=function(p,g,o){var c=this.$getMode(p.getState(o-1));return(!c||!c.getFoldWidget(p,g,o))&&(c=this.$getMode(p.getState(o))),(!c||!c.getFoldWidget(p,g,o))&&(c=this.defaultMode),c.getFoldWidgetRange(p,g,o)}}).call(b.prototype)}),ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"],function(t,r,l){var d=t("../../lib/oop"),h=t("./mixed").FoldMode,b=t("./xml").FoldMode,p=t("./cstyle").FoldMode,g=r.FoldMode=function(o,c){h.call(this,new b(o,c),{"js-":new p,"css-":new p})};d.inherits(g,h)}),ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"],function(t,r,l){function d(a,m){return a.type.lastIndexOf(m+".xml")>-1}function h(a,m){for(var w=new p(a,m.row,m.column),x=w.getCurrentToken();x&&!d(x,"tag-name");)x=w.stepBackward();if(x)return x.value}function b(a,m){for(var w=new p(a,m.row,m.column),x=w.getCurrentToken();x&&!d(x,"attribute-name");)x=w.stepBackward();if(x)return x.value}var p=t("../token_iterator").TokenIterator,g=["accesskey","class","contenteditable","contextmenu","dir","draggable","dropzone","hidden","id","inert","itemid","itemprop","itemref","itemscope","itemtype","lang","spellcheck","style","tabindex","title","translate"],o=["onabort","onblur","oncancel","oncanplay","oncanplaythrough","onchange","onclick","onclose","oncontextmenu","oncuechange","ondblclick","ondrag","ondragend","ondragenter","ondragleave","ondragover","ondragstart","ondrop","ondurationchange","onemptied","onended","onerror","onfocus","oninput","oninvalid","onkeydown","onkeypress","onkeyup","onload","onloadeddata","onloadedmetadata","onloadstart","onmousedown","onmousemove","onmouseout","onmouseover","onmouseup","onmousewheel","onpause","onplay","onplaying","onprogress","onratechange","onreset","onscroll","onseeked","onseeking","onselect","onshow","onstalled","onsubmit","onsuspend","ontimeupdate","onvolumechange","onwaiting"],c=g.concat(o),f={a:{href:1,target:{_blank:1,top:1},ping:1,rel:{nofollow:1,alternate:1,author:1,bookmark:1,help:1,license:1,next:1,noreferrer:1,prefetch:1,prev:1,search:1,tag:1},media:1,hreflang:1,type:1},abbr:{},address:{},area:{shape:1,coords:1,href:1,hreflang:1,alt:1,target:1,media:1,rel:1,ping:1,type:1},article:{pubdate:1},aside:{},audio:{src:1,autobuffer:1,autoplay:{autoplay:1},loop:{loop:1},controls:{controls:1},muted:{muted:1},preload:{auto:1,metadata:1,none:1}},b:{},base:{href:1,target:1},bdi:{},bdo:{},blockquote:{cite:1},body:{onafterprint:1,onbeforeprint:1,onbeforeunload:1,onhashchange:1,onmessage:1,onoffline:1,onpopstate:1,onredo:1,onresize:1,onstorage:1,onundo:1,onunload:1},br:{},button:{autofocus:1,disabled:{disabled:1},form:1,formaction:1,formenctype:1,formmethod:1,formnovalidate:1,formtarget:1,name:1,value:1,type:{button:1,submit:1}},canvas:{width:1,height:1},caption:{},cite:{},code:{},col:{span:1},colgroup:{span:1},command:{type:1,label:1,icon:1,disabled:1,checked:1,radiogroup:1,command:1},data:{},datalist:{},dd:{},del:{cite:1,datetime:1},details:{open:1},dfn:{},dialog:{open:1},div:{},dl:{},dt:{},em:{},embed:{src:1,height:1,width:1,type:1},fieldset:{disabled:1,form:1,name:1},figcaption:{},figure:{},footer:{},form:{"accept-charset":1,action:1,autocomplete:1,enctype:{"multipart/form-data":1,"application/x-www-form-urlencoded":1},method:{get:1,post:1},name:1,novalidate:1,target:{_blank:1,top:1}},h1:{},h2:{},h3:{},h4:{},h5:{},h6:{},head:{},header:{},hr:{},html:{manifest:1},i:{},iframe:{name:1,src:1,height:1,width:1,sandbox:{"allow-same-origin":1,"allow-top-navigation":1,"allow-forms":1,"allow-scripts":1},seamless:{seamless:1}},img:{alt:1,src:1,height:1,width:1,usemap:1,ismap:1},input:{type:{text:1,password:1,hidden:1,checkbox:1,submit:1,radio:1,file:1,button:1,reset:1,image:31,color:1,date:1,datetime:1,"datetime-local":1,email:1,month:1,number:1,range:1,search:1,tel:1,time:1,url:1,week:1},accept:1,alt:1,autocomplete:{on:1,off:1},autofocus:{autofocus:1},checked:{checked:1},disabled:{disabled:1},form:1,formaction:1,formenctype:{"application/x-www-form-urlencoded":1,"multipart/form-data":1,"text/plain":1},formmethod:{get:1,post:1},formnovalidate:{formnovalidate:1},formtarget:{_blank:1,_self:1,_parent:1,_top:1},height:1,list:1,max:1,maxlength:1,min:1,multiple:{multiple:1},name:1,pattern:1,placeholder:1,readonly:{readonly:1},required:{required:1},size:1,src:1,step:1,width:1,files:1,value:1},ins:{cite:1,datetime:1},kbd:{},keygen:{autofocus:1,challenge:{challenge:1},disabled:{disabled:1},form:1,keytype:{rsa:1,dsa:1,ec:1},name:1},label:{form:1,for:1},legend:{},li:{value:1},link:{href:1,hreflang:1,rel:{stylesheet:1,icon:1},media:{all:1,screen:1,print:1},type:{"text/css":1,"image/png":1,"image/jpeg":1,"image/gif":1},sizes:1},main:{},map:{name:1},mark:{},math:{},menu:{type:1,label:1},meta:{"http-equiv":{"content-type":1},name:{description:1,keywords:1},content:{"text/html; charset=UTF-8":1},charset:1},meter:{value:1,min:1,max:1,low:1,high:1,optimum:1},nav:{},noscript:{href:1},object:{param:1,data:1,type:1,height:1,width:1,usemap:1,name:1,form:1,classid:1},ol:{start:1,reversed:1},optgroup:{disabled:1,label:1},option:{disabled:1,selected:1,label:1,value:1},output:{for:1,form:1,name:1},p:{},param:{name:1,value:1},pre:{},progress:{value:1,max:1},q:{cite:1},rp:{},rt:{},ruby:{},s:{},samp:{},script:{charset:1,type:{"text/javascript":1},src:1,defer:1,async:1},select:{autofocus:1,disabled:1,form:1,multiple:{multiple:1},name:1,size:1,readonly:{readonly:1}},small:{},source:{src:1,type:1,media:1},span:{},strong:{},style:{type:1,media:{all:1,screen:1,print:1},scoped:1},sub:{},sup:{},svg:{},table:{summary:1},tbody:{},td:{headers:1,rowspan:1,colspan:1},textarea:{autofocus:{autofocus:1},disabled:{disabled:1},form:1,maxlength:1,name:1,placeholder:1,readonly:{readonly:1},required:{required:1},rows:1,cols:1,wrap:{on:1,off:1,hard:1,soft:1}},tfoot:{},th:{headers:1,rowspan:1,colspan:1,scope:1},thead:{},time:{datetime:1},title:{},tr:{},track:{kind:1,src:1,srclang:1,label:1,default:1},section:{},summary:{},u:{},ul:{},var:{},video:{src:1,autobuffer:1,autoplay:{autoplay:1},loop:{loop:1},controls:{controls:1},width:1,height:1,poster:1,muted:{muted:1},preload:{auto:1,metadata:1,none:1}},wbr:{}},u=Object.keys(f),i=function(){};(function(){this.getCompletions=function(a,m,w,x){var M=m.getTokenAt(w.row,w.column);if(!M)return[];if(d(M,"tag-name")||d(M,"tag-open")||d(M,"end-tag-open"))return this.getTagCompletions(a,m,w,x);if(d(M,"tag-whitespace")||d(M,"attribute-name"))return this.getAttributeCompletions(a,m,w,x);if(d(M,"attribute-value"))return this.getAttributeValueCompletions(a,m,w,x);var $=m.getLine(w.row).substr(0,w.column);return/&[a-z]*$/i.test($)?this.getHTMLEntityCompletions(a,m,w,x):[]},this.getTagCompletions=function(a,m,w,x){return u.map(function(M){return{value:M,meta:"tag",score:1e6}})},this.getAttributeCompletions=function(a,m,w,x){var M=h(m,w);if(!M)return[];var $=c;return M in f&&($=$.concat(Object.keys(f[M]))),$.map(function(S){return{caption:S,snippet:S+'="$0"',meta:"attribute",score:1e6}})},this.getAttributeValueCompletions=function(a,m,w,x){var M=h(m,w),$=b(m,w);if(!M)return[];var S=[];return M in f&&$ in f[M]&&typeof f[M][$]=="object"&&(S=Object.keys(f[M][$])),S.map(function(k){return{caption:k,snippet:k,meta:"attribute value",score:1e6}})},this.getHTMLEntityCompletions=function(a,m,w,x){var M=["Aacute;","aacute;","Acirc;","acirc;","acute;","AElig;","aelig;","Agrave;","agrave;","alefsym;","Alpha;","alpha;","amp;","and;","ang;","Aring;","aring;","asymp;","Atilde;","atilde;","Auml;","auml;","bdquo;","Beta;","beta;","brvbar;","bull;","cap;","Ccedil;","ccedil;","cedil;","cent;","Chi;","chi;","circ;","clubs;","cong;","copy;","crarr;","cup;","curren;","Dagger;","dagger;","dArr;","darr;","deg;","Delta;","delta;","diams;","divide;","Eacute;","eacute;","Ecirc;","ecirc;","Egrave;","egrave;","empty;","emsp;","ensp;","Epsilon;","epsilon;","equiv;","Eta;","eta;","ETH;","eth;","Euml;","euml;","euro;","exist;","fnof;","forall;","frac12;","frac14;","frac34;","frasl;","Gamma;","gamma;","ge;","gt;","hArr;","harr;","hearts;","hellip;","Iacute;","iacute;","Icirc;","icirc;","iexcl;","Igrave;","igrave;","image;","infin;","int;","Iota;","iota;","iquest;","isin;","Iuml;","iuml;","Kappa;","kappa;","Lambda;","lambda;","lang;","laquo;","lArr;","larr;","lceil;","ldquo;","le;","lfloor;","lowast;","loz;","lrm;","lsaquo;","lsquo;","lt;","macr;","mdash;","micro;","middot;","minus;","Mu;","mu;","nabla;","nbsp;","ndash;","ne;","ni;","not;","notin;","nsub;","Ntilde;","ntilde;","Nu;","nu;","Oacute;","oacute;","Ocirc;","ocirc;","OElig;","oelig;","Ograve;","ograve;","oline;","Omega;","omega;","Omicron;","omicron;","oplus;","or;","ordf;","ordm;","Oslash;","oslash;","Otilde;","otilde;","otimes;","Ouml;","ouml;","para;","part;","permil;","perp;","Phi;","phi;","Pi;","pi;","piv;","plusmn;","pound;","Prime;","prime;","prod;","prop;","Psi;","psi;","quot;","radic;","rang;","raquo;","rArr;","rarr;","rceil;","rdquo;","real;","reg;","rfloor;","Rho;","rho;","rlm;","rsaquo;","rsquo;","sbquo;","Scaron;","scaron;","sdot;","sect;","shy;","Sigma;","sigma;","sigmaf;","sim;","spades;","sub;","sube;","sum;","sup;","sup1;","sup2;","sup3;","supe;","szlig;","Tau;","tau;","there4;","Theta;","theta;","thetasym;","thinsp;","THORN;","thorn;","tilde;","times;","trade;","Uacute;","uacute;","uArr;","uarr;","Ucirc;","ucirc;","Ugrave;","ugrave;","uml;","upsih;","Upsilon;","upsilon;","Uuml;","uuml;","weierp;","Xi;","xi;","Yacute;","yacute;","yen;","Yuml;","yuml;","Zeta;","zeta;","zwj;","zwnj;"];return M.map(function($){return{caption:$,snippet:$,meta:"html entity",score:1e6}})}}).call(i.prototype),r.HtmlCompletions=i}),ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"],function(t,r,l){var d=t("../lib/oop"),h=t("../lib/lang"),b=t("./text").Mode,p=t("./javascript").Mode,g=t("./css").Mode,o=t("./html_highlight_rules").HtmlHighlightRules,c=t("./behaviour/xml").XmlBehaviour,f=t("./folding/html").FoldMode,u=t("./html_completions").HtmlCompletions,i=t("../worker/worker_client").WorkerClient,a=["area","base","br","col","embed","hr","img","input","keygen","link","meta","menuitem","param","source","track","wbr"],m=["li","dt","dd","p","rt","rp","optgroup","option","colgroup","td","th"],w=function(x){this.fragmentContext=x&&x.fragmentContext,this.HighlightRules=o,this.$behaviour=new c,this.$completer=new u,this.createModeDelegates({"js-":p,"css-":g}),this.foldingRules=new f(this.voidElements,h.arrayToMap(m))};d.inherits(w,b),(function(){this.blockComment={start:"<!--",end:"-->"},this.voidElements=h.arrayToMap(a),this.getNextLineIndent=function(x,M,$){return this.$getIndent(M)},this.checkOutdent=function(x,M,$){return!1},this.getCompletions=function(x,M,$,S){return this.$completer.getCompletions(x,M,$,S)},this.createWorker=function(x){if(this.constructor==w){var M=new i(["ace"],"ace/mode/html_worker","Worker");return M.attachToDocument(x.getDocument()),this.fragmentContext&&M.call("setOptions",[{context:this.fragmentContext}]),M.on("error",function($){x.setAnnotations($.data)}),M.on("terminate",function(){x.clearAnnotations()}),M}},this.$id="ace/mode/html",this.snippetFileId="ace/snippets/html"}).call(w.prototype),r.Mode=w}),ace.define("ace/mode/sh_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,l){var d=t("../lib/oop"),h=t("./text_highlight_rules").TextHighlightRules,b=r.reservedKeywords="!|{|}|case|do|done|elif|else|esac|fi|for|if|in|then|until|while|&|;|export|local|read|typeset|unset|elif|select|set|function|declare|readonly",p=r.languageConstructs="[|]|alias|bg|bind|break|builtin|cd|command|compgen|complete|continue|dirs|disown|echo|enable|eval|exec|exit|fc|fg|getopts|hash|help|history|jobs|kill|let|logout|popd|printf|pushd|pwd|return|set|shift|shopt|source|suspend|test|times|trap|type|ulimit|umask|unalias|wait",g=function(){var o=this.createKeywordMapper({keyword:b,"support.function.builtin":p,"invalid.deprecated":"debugger"},"identifier"),c="(?:(?:[1-9]\\d*)|(?:0))",f="(?:\\.\\d+)",u="(?:\\d+)",i="(?:(?:"+u+"?"+f+")|(?:"+u+"\\.))",a="(?:(?:"+i+"|"+u+"))",m="(?:"+a+"|"+i+")",w="(?:&"+u+")",x="[a-zA-Z_][a-zA-Z0-9_]*",M="(?:"+x+"(?==))",$="(?:\\$(?:SHLVL|\\$|\\!|\\?))",S="(?:"+x+"\\s*\\(\\))";this.$rules={start:[{token:"constant",regex:/\\./},{token:["text","comment"],regex:/(^|\s)(#.*)$/},{token:"string.start",regex:'"',push:[{token:"constant.language.escape",regex:/\\(?:[$`"\\]|$)/},{include:"variables"},{token:"keyword.operator",regex:/`/},{token:"string.end",regex:'"',next:"pop"},{defaultToken:"string"}]},{token:"string",regex:"\\$'",push:[{token:"constant.language.escape",regex:/\\(?:[abeEfnrtv\\'"]|x[a-fA-F\d]{1,2}|u[a-fA-F\d]{4}([a-fA-F\d]{4})?|c.|\d{1,3})/},{token:"string",regex:"'",next:"pop"},{defaultToken:"string"}]},{regex:"<<<",token:"keyword.operator"},{stateName:"heredoc",regex:"(<<-?)(\\s*)(['\"`]?)([\\w\\-]+)(['\"`]?)",onMatch:function(k,T,D){var L=k[2]=="-"?"indentedHeredoc":"heredoc",O=k.split(this.splitRegex);return D.push(L,O[4]),[{type:"constant",value:O[1]},{type:"text",value:O[2]},{type:"string",value:O[3]},{type:"support.class",value:O[4]},{type:"string",value:O[5]}]},rules:{heredoc:[{onMatch:function(k,T,D){return k===D[1]?(D.shift(),D.shift(),this.next=D[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}],indentedHeredoc:[{token:"string",regex:"^ +"},{onMatch:function(k,T,D){return k===D[1]?(D.shift(),D.shift(),this.next=D[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}]}},{regex:"$",token:"empty",next:function(k,T){return T[0]==="heredoc"||T[0]==="indentedHeredoc"?T[0]:k}},{token:["keyword","text","text","text","variable"],regex:/(declare|local|readonly)(\s+)(?:(-[fixar]+)(\s+))?([a-zA-Z_][a-zA-Z0-9_]*\b)/},{token:"variable.language",regex:$},{token:"variable",regex:M},{include:"variables"},{token:"support.function",regex:S},{token:"support.function",regex:w},{token:"string",start:"'",end:"'"},{token:"constant.numeric",regex:m},{token:"constant.numeric",regex:c+"\\b"},{token:o,regex:"[a-zA-Z_][a-zA-Z0-9_]*\\b"},{token:"keyword.operator",regex:"\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|~|<|>|<=|=>|=|!=|[%&|`]"},{token:"punctuation.operator",regex:";"},{token:"paren.lparen",regex:"[\\[\\(\\{]"},{token:"paren.rparen",regex:"[\\]]"},{token:"paren.rparen",regex:"[\\)\\}]",next:"pop"}],variables:[{token:"variable",regex:/(\$)(\w+)/},{token:["variable","paren.lparen"],regex:/(\$)(\()/,push:"start"},{token:["variable","paren.lparen","keyword.operator","variable","keyword.operator"],regex:/(\$)(\{)([#!]?)(\w+|[*@#?\-$!0_])(:[?+\-=]?|##?|%%?|,,?\/|\^\^?)?/,push:"start"},{token:"variable",regex:/\$[*@#?\-$!0_]/},{token:["variable","paren.lparen"],regex:/(\$)(\{)/,push:"start"}]},this.normalizeRules()};d.inherits(g,h),r.ShHighlightRules=g}),ace.define("ace/mode/sh",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sh_highlight_rules","ace/range","ace/mode/folding/cstyle"],function(t,r,l){var d=t("../lib/oop"),h=t("./text").Mode,b=t("./sh_highlight_rules").ShHighlightRules,p=t("../range").Range,g=t("./folding/cstyle").FoldMode,o=function(){this.HighlightRules=b,this.foldingRules=new g,this.$behaviour=this.$defaultBehaviour};d.inherits(o,h),(function(){this.lineCommentStart="#",this.getNextLineIndent=function(f,u,i){var a=this.$getIndent(u),m=this.getTokenizer().getLineTokens(u,f),w=m.tokens;if(w.length&&w[w.length-1].type=="comment")return a;if(f=="start"){var x=u.match(/^.*[\{\(\[:]\s*$/);x&&(a+=i)}return a};var c={pass:1,return:1,raise:1,break:1,continue:1};this.checkOutdent=function(f,u,i){if(i!==`\r
|
|
998
|
+
`&&i!=="\r"&&i!==`
|
|
999
|
+
`)return!1;var a=this.getTokenizer().getLineTokens(u.trim(),f).tokens;if(!a)return!1;do var m=a.pop();while(m&&(m.type=="comment"||m.type=="text"&&m.value.match(/^\s+$/)));return m?m.type=="keyword"&&c[m.value]:!1},this.autoOutdent=function(f,u,i){i+=1;var a=this.$getIndent(u.getLine(i)),m=u.getTabString();a.slice(-m.length)==m&&u.remove(new p(i,a.length-m.length,i,a.length))},this.$id="ace/mode/sh",this.snippetFileId="ace/snippets/sh"}).call(o.prototype),r.Mode=o}),ace.define("ace/mode/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/xml_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/xml","ace/worker/worker_client"],function(t,r,l){var d=t("../lib/oop"),h=t("../lib/lang"),b=t("./text").Mode,p=t("./xml_highlight_rules").XmlHighlightRules,g=t("./behaviour/xml").XmlBehaviour,o=t("./folding/xml").FoldMode,c=t("../worker/worker_client").WorkerClient,f=function(){this.HighlightRules=p,this.$behaviour=new g,this.foldingRules=new o};d.inherits(f,b),(function(){this.voidElements=h.arrayToMap([]),this.blockComment={start:"<!--",end:"-->"},this.createWorker=function(u){var i=new c(["ace"],"ace/mode/xml_worker","Worker");return i.attachToDocument(u.getDocument()),i.on("error",function(a){u.setAnnotations(a.data)}),i.on("terminate",function(){u.clearAnnotations()}),i},this.$id="ace/mode/xml"}).call(f.prototype),r.Mode=f}),ace.define("ace/mode/markdown",["require","exports","module","ace/lib/oop","ace/mode/behaviour/cstyle","ace/mode/text","ace/mode/markdown_highlight_rules","ace/mode/folding/markdown","ace/mode/javascript","ace/mode/html","ace/mode/sh","ace/mode/sh","ace/mode/xml","ace/mode/css"],function(t,r,l){var d=t("../lib/oop"),h=t("./behaviour/cstyle").CstyleBehaviour,b=t("./text").Mode,p=t("./markdown_highlight_rules").MarkdownHighlightRules,g=t("./folding/markdown").FoldMode,o=function(){this.HighlightRules=p,this.createModeDelegates({javascript:t("./javascript").Mode,html:t("./html").Mode,bash:t("./sh").Mode,sh:t("./sh").Mode,xml:t("./xml").Mode,css:t("./css").Mode}),this.foldingRules=new g,this.$behaviour=new h({braces:!0})};d.inherits(o,b),(function(){this.type="text",this.blockComment={start:"<!--",end:"-->"},this.$quotes={'"':'"',"`":"`"},this.getNextLineIndent=function(c,f,u){if(c=="listblock"){var i=/^(\s*)(?:([-+*])|(\d+)\.)(\s+)/.exec(f);if(!i)return"";var a=i[2];return a||(a=parseInt(i[3],10)+1+"."),i[1]+a+i[4]}return this.$getIndent(f)},this.$id="ace/mode/markdown",this.snippetFileId="ace/snippets/markdown"}).call(o.prototype),r.Mode=o}),function(){ace.require(["ace/mode/markdown"],function(t){n&&(n.exports=t)})}()}(Og)),Og.exports}RS();var Ng={exports:{}},Dg;function MS(){return Dg||(Dg=1,function(n,e){ace.define("ace/theme/twilight-css",["require","exports","module"],function(t,r,l){l.exports=`.ace-twilight .ace_gutter {
|
|
1000
|
+
background: #232323;
|
|
1001
|
+
color: #E2E2E2
|
|
1002
|
+
}
|
|
1003
|
+
|
|
1004
|
+
.ace-twilight .ace_print-margin {
|
|
1005
|
+
width: 1px;
|
|
1006
|
+
background: #232323
|
|
1007
|
+
}
|
|
1008
|
+
|
|
1009
|
+
.ace-twilight {
|
|
1010
|
+
background-color: #141414;
|
|
1011
|
+
color: #F8F8F8
|
|
1012
|
+
}
|
|
1013
|
+
|
|
1014
|
+
.ace-twilight .ace_cursor {
|
|
1015
|
+
color: #A7A7A7
|
|
1016
|
+
}
|
|
1017
|
+
|
|
1018
|
+
.ace-twilight .ace_marker-layer .ace_selection {
|
|
1019
|
+
background: rgba(221, 240, 255, 0.20)
|
|
1020
|
+
}
|
|
1021
|
+
|
|
1022
|
+
.ace-twilight.ace_multiselect .ace_selection.ace_start {
|
|
1023
|
+
box-shadow: 0 0 3px 0px #141414;
|
|
1024
|
+
}
|
|
1025
|
+
|
|
1026
|
+
.ace-twilight .ace_marker-layer .ace_step {
|
|
1027
|
+
background: rgb(102, 82, 0)
|
|
1028
|
+
}
|
|
1029
|
+
|
|
1030
|
+
.ace-twilight .ace_marker-layer .ace_bracket {
|
|
1031
|
+
margin: -1px 0 0 -1px;
|
|
1032
|
+
border: 1px solid rgba(255, 255, 255, 0.25)
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
.ace-twilight .ace_marker-layer .ace_active-line {
|
|
1036
|
+
background: rgba(255, 255, 255, 0.031)
|
|
1037
|
+
}
|
|
1038
|
+
|
|
1039
|
+
.ace-twilight .ace_gutter-active-line {
|
|
1040
|
+
background-color: rgba(255, 255, 255, 0.031)
|
|
1041
|
+
}
|
|
1042
|
+
|
|
1043
|
+
.ace-twilight .ace_marker-layer .ace_selected-word {
|
|
1044
|
+
border: 1px solid rgba(221, 240, 255, 0.20)
|
|
1045
|
+
}
|
|
1046
|
+
|
|
1047
|
+
.ace-twilight .ace_invisible {
|
|
1048
|
+
color: rgba(255, 255, 255, 0.25)
|
|
1049
|
+
}
|
|
1050
|
+
|
|
1051
|
+
.ace-twilight .ace_keyword,
|
|
1052
|
+
.ace-twilight .ace_meta {
|
|
1053
|
+
color: #CDA869
|
|
1054
|
+
}
|
|
1055
|
+
|
|
1056
|
+
.ace-twilight .ace_constant,
|
|
1057
|
+
.ace-twilight .ace_constant.ace_character,
|
|
1058
|
+
.ace-twilight .ace_constant.ace_character.ace_escape,
|
|
1059
|
+
.ace-twilight .ace_constant.ace_other,
|
|
1060
|
+
.ace-twilight .ace_heading,
|
|
1061
|
+
.ace-twilight .ace_markup.ace_heading,
|
|
1062
|
+
.ace-twilight .ace_support.ace_constant {
|
|
1063
|
+
color: #CF6A4C
|
|
1064
|
+
}
|
|
1065
|
+
|
|
1066
|
+
.ace-twilight .ace_invalid.ace_illegal {
|
|
1067
|
+
color: #F8F8F8;
|
|
1068
|
+
background-color: rgba(86, 45, 86, 0.75)
|
|
1069
|
+
}
|
|
1070
|
+
|
|
1071
|
+
.ace-twilight .ace_invalid.ace_deprecated {
|
|
1072
|
+
text-decoration: underline;
|
|
1073
|
+
font-style: italic;
|
|
1074
|
+
color: #D2A8A1
|
|
1075
|
+
}
|
|
1076
|
+
|
|
1077
|
+
.ace-twilight .ace_support {
|
|
1078
|
+
color: #9B859D
|
|
1079
|
+
}
|
|
1080
|
+
|
|
1081
|
+
.ace-twilight .ace_fold {
|
|
1082
|
+
background-color: #AC885B;
|
|
1083
|
+
border-color: #F8F8F8
|
|
1084
|
+
}
|
|
1085
|
+
|
|
1086
|
+
.ace-twilight .ace_support.ace_function {
|
|
1087
|
+
color: #DAD085
|
|
1088
|
+
}
|
|
1089
|
+
|
|
1090
|
+
.ace-twilight .ace_list,
|
|
1091
|
+
.ace-twilight .ace_markup.ace_list,
|
|
1092
|
+
.ace-twilight .ace_storage {
|
|
1093
|
+
color: #F9EE98
|
|
1094
|
+
}
|
|
1095
|
+
|
|
1096
|
+
.ace-twilight .ace_entity.ace_name.ace_function,
|
|
1097
|
+
.ace-twilight .ace_meta.ace_tag {
|
|
1098
|
+
color: #AC885B
|
|
1099
|
+
}
|
|
1100
|
+
|
|
1101
|
+
.ace-twilight .ace_string {
|
|
1102
|
+
color: #8F9D6A
|
|
1103
|
+
}
|
|
1104
|
+
|
|
1105
|
+
.ace-twilight .ace_string.ace_regexp {
|
|
1106
|
+
color: #E9C062
|
|
1107
|
+
}
|
|
1108
|
+
|
|
1109
|
+
.ace-twilight .ace_comment {
|
|
1110
|
+
font-style: italic;
|
|
1111
|
+
color: #5F5A60
|
|
1112
|
+
}
|
|
1113
|
+
|
|
1114
|
+
.ace-twilight .ace_variable {
|
|
1115
|
+
color: #7587A6
|
|
1116
|
+
}
|
|
1117
|
+
|
|
1118
|
+
.ace-twilight .ace_xml-pe {
|
|
1119
|
+
color: #494949
|
|
1120
|
+
}
|
|
1121
|
+
|
|
1122
|
+
.ace-twilight .ace_indent-guide {
|
|
1123
|
+
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWMQERFpYLC1tf0PAAgOAnPnhxyiAAAAAElFTkSuQmCC) right repeat-y
|
|
1124
|
+
}
|
|
1125
|
+
|
|
1126
|
+
.ace-twilight .ace_indent-guide-active {
|
|
1127
|
+
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQIW2PQ1dX9zzBz5sz/ABCcBFFentLlAAAAAElFTkSuQmCC) right repeat-y;
|
|
1128
|
+
}
|
|
1129
|
+
`}),ace.define("ace/theme/twilight",["require","exports","module","ace/theme/twilight-css","ace/lib/dom"],function(t,r,l){r.isDark=!0,r.cssClass="ace-twilight",r.cssText=t("./twilight-css");var d=t("../lib/dom");d.importCssString(r.cssText,r.cssClass,!1)}),function(){ace.require(["ace/theme/twilight"],function(t){n&&(n.exports=t)})}()}(Ng)),Ng.exports}MS();var Fg={exports:{}},Pg;function LS(){return Pg||(Pg=1,function(n,e){ace.define("ace/snippets",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/range_list","ace/keyboard/hash_handler","ace/tokenizer","ace/clipboard","ace/editor"],function(t,r,l){function d(k){var T=new Date().toLocaleString("en-us",k);return T.length==1?"0"+T:T}var h=t("./lib/dom"),b=t("./lib/oop"),p=t("./lib/event_emitter").EventEmitter,g=t("./lib/lang"),o=t("./range").Range,c=t("./range_list").RangeList,f=t("./keyboard/hash_handler").HashHandler,u=t("./tokenizer").Tokenizer,i=t("./clipboard"),a={CURRENT_WORD:function(k){return k.session.getTextRange(k.session.getWordRange())},SELECTION:function(k,T,D){var L=k.session.getTextRange();return D?L.replace(/\n\r?([ \t]*\S)/g,`
|
|
1130
|
+
`+D+"$1"):L},CURRENT_LINE:function(k){return k.session.getLine(k.getCursorPosition().row)},PREV_LINE:function(k){return k.session.getLine(k.getCursorPosition().row-1)},LINE_INDEX:function(k){return k.getCursorPosition().row},LINE_NUMBER:function(k){return k.getCursorPosition().row+1},SOFT_TABS:function(k){return k.session.getUseSoftTabs()?"YES":"NO"},TAB_SIZE:function(k){return k.session.getTabSize()},CLIPBOARD:function(k){return i.getText&&i.getText()},FILENAME:function(k){return/[^/\\]*$/.exec(this.FILEPATH(k))[0]},FILENAME_BASE:function(k){return/[^/\\]*$/.exec(this.FILEPATH(k))[0].replace(/\.[^.]*$/,"")},DIRECTORY:function(k){return this.FILEPATH(k).replace(/[^/\\]*$/,"")},FILEPATH:function(k){return"/not implemented.txt"},WORKSPACE_NAME:function(){return"Unknown"},FULLNAME:function(){return"Unknown"},BLOCK_COMMENT_START:function(k){var T=k.session.$mode||{};return T.blockComment&&T.blockComment.start||""},BLOCK_COMMENT_END:function(k){var T=k.session.$mode||{};return T.blockComment&&T.blockComment.end||""},LINE_COMMENT:function(k){var T=k.session.$mode||{};return T.lineCommentStart||""},CURRENT_YEAR:d.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:d.bind(null,{year:"2-digit"}),CURRENT_MONTH:d.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:d.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:d.bind(null,{month:"short"}),CURRENT_DATE:d.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:d.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:d.bind(null,{weekday:"short"}),CURRENT_HOUR:d.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:d.bind(null,{minute:"2-digit"}),CURRENT_SECOND:d.bind(null,{second:"2-digit"})};a.SELECTED_TEXT=a.SELECTION;var m=function(){function k(){this.snippetMap={},this.snippetNameMap={},this.variables=a}return k.prototype.getTokenizer=function(){return k.$tokenizer||this.createTokenizer()},k.prototype.createTokenizer=function(){function T(O){return O=O.substr(1),/^\d+$/.test(O)?[{tabstopId:parseInt(O,10)}]:[{text:O}]}function D(O){return"(?:[^\\\\"+O+"]|\\\\.)"}var L={regex:"/("+D("/")+"+)/",onMatch:function(O,z,P){var N=P[0];return N.fmtString=!0,N.guard=O.slice(1,-1),N.flag="",""},next:"formatString"};return k.$tokenizer=new u({start:[{regex:/\\./,onMatch:function(O,z,P){var N=O[1];return(N=="}"&&P.length||"`$\\".indexOf(N)!=-1)&&(O=N),[O]}},{regex:/}/,onMatch:function(O,z,P){return[P.length?P.shift():O]}},{regex:/\$(?:\d+|\w+)/,onMatch:T},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(O,z,P){var N=T(O.substr(1));return P.unshift(N[0]),N},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+D("\\|")+"*\\|",onMatch:function(O,z,P){var N=O.slice(1,-1).replace(/\\[,|\\]|,/g,function(A){return A.length==2?A[1]:"\0"}).split("\0").map(function(A){return{value:A}});return P[0].choices=N,[N[0]]},next:"start"},L,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(O,z,P){return P.length&&P[0].expectElse?(P[0].expectElse=!1,P[0].ifEnd={elseEnd:P[0]},[P[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(O,z,P){var N=O[1];return N=="}"&&P.length||"`$\\".indexOf(N)!=-1?O=N:N=="n"?O=`
|
|
1131
|
+
`:N=="t"?O=" ":"ulULE".indexOf(N)!=-1&&(O={changeCase:N,local:N>"a"}),[O]}},{regex:"/\\w*}",onMatch:function(O,z,P){var N=P.shift();return N&&(N.flag=O.slice(1,-1)),this.next=N&&N.tabstopId?"start":"",[N||O]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(O,z,P){return[{text:O.slice(1)}]}},{regex:/\${\w+/,onMatch:function(O,z,P){var N={text:O.slice(2)};return P.unshift(N),[N]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(O,z,P){var N=P.shift();return this.next=N&&N.tabstopId?"start":"",[N||O]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(O,z,P){var N=P[0];return N.formatFunction=O.slice(2,-1),[P.shift()]},next:"formatString"},L,{regex:/:[\?\-+]?/,onMatch:function(O,z,P){O[1]=="+"&&(P[0].ifEnd=P[0]),O[1]=="?"&&(P[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]}),k.$tokenizer},k.prototype.tokenizeTmSnippet=function(T,D){return this.getTokenizer().getLineTokens(T,D).tokens.map(function(L){return L.value||L})},k.prototype.getVariableValue=function(T,D,L){if(/^\d+$/.test(D))return(this.variables.__||{})[D]||"";if(/^[A-Z]\d+$/.test(D))return(this.variables[D[0]+"__"]||{})[D.substr(1)]||"";if(D=D.replace(/^TM_/,""),!this.variables.hasOwnProperty(D))return"";var O=this.variables[D];return typeof O=="function"&&(O=this.variables[D](T,D,L)),O??""},k.prototype.tmStrFormat=function(T,D,L){if(!D.fmt)return T;var O=D.flag||"",z=D.guard;z=new RegExp(z,O.replace(/[^gim]/g,""));var P=typeof D.fmt=="string"?this.tokenizeTmSnippet(D.fmt,"formatString"):D.fmt,N=this,A=T.replace(z,function(){var _=N.variables.__;N.variables.__=[].slice.call(arguments);for(var I=N.resolveVariables(P,L),j="E",U=0;U<I.length;U++){var K=I[U];if(typeof K=="object")if(I[U]="",K.changeCase&&K.local){var Z=I[U+1];Z&&typeof Z=="string"&&(K.changeCase=="u"?I[U]=Z[0].toUpperCase():I[U]=Z[0].toLowerCase(),I[U+1]=Z.substr(1))}else K.changeCase&&(j=K.changeCase);else j=="U"?I[U]=K.toUpperCase():j=="L"&&(I[U]=K.toLowerCase())}return N.variables.__=_,I.join("")});return A},k.prototype.tmFormatFunction=function(T,D,L){return D.formatFunction=="upcase"?T.toUpperCase():D.formatFunction=="downcase"?T.toLowerCase():T},k.prototype.resolveVariables=function(T,D){function L(j){var U=T.indexOf(j,N+1);U!=-1&&(N=U)}for(var O=[],z="",P=!0,N=0;N<T.length;N++){var A=T[N];if(typeof A=="string"){O.push(A),A==`
|
|
1132
|
+
`?(P=!0,z=""):P&&(z=/^\t*/.exec(A)[0],P=/\S/.test(A));continue}if(A){if(P=!1,A.fmtString){var _=T.indexOf(A,N+1);_==-1&&(_=T.length),A.fmt=T.slice(N+1,_),N=_}if(A.text){var I=this.getVariableValue(D,A.text,z)+"";A.fmtString&&(I=this.tmStrFormat(I,A,D)),A.formatFunction&&(I=this.tmFormatFunction(I,A,D)),I&&!A.ifEnd?(O.push(I),L(A)):!I&&A.ifEnd&&L(A.ifEnd)}else A.elseEnd?L(A.elseEnd):(A.tabstopId!=null||A.changeCase!=null)&&O.push(A)}}return O},k.prototype.getDisplayTextForSnippet=function(T,D){var L=w.call(this,T,D);return L.text},k.prototype.insertSnippetForSelection=function(T,D,L){L===void 0&&(L={});var O=w.call(this,T,D,L),z=T.getSelectionRange(),P=T.session.replace(z,O.text),N=new x(T),A=T.inVirtualSelectionMode&&T.selection.index;N.addTabstops(O.tabstops,z.start,P,A)},k.prototype.insertSnippet=function(T,D,L){L===void 0&&(L={});var O=this;if(T.inVirtualSelectionMode)return O.insertSnippetForSelection(T,D,L);T.forEachSelection(function(){O.insertSnippetForSelection(T,D,L)},null,{keepOrder:!0}),T.tabstopManager&&T.tabstopManager.tabNext()},k.prototype.$getScope=function(T){var D=T.session.$mode.$id||"";if(D=D.split("/").pop(),D==="html"||D==="php"){D==="php"&&!T.session.$mode.inlinePhp&&(D="html");var L=T.getCursorPosition(),O=T.session.getState(L.row);typeof O=="object"&&(O=O[0]),O.substring&&(O.substring(0,3)=="js-"?D="javascript":O.substring(0,4)=="css-"?D="css":O.substring(0,4)=="php-"&&(D="php"))}return D},k.prototype.getActiveScopes=function(T){var D=this.$getScope(T),L=[D],O=this.snippetMap;return O[D]&&O[D].includeScopes&&L.push.apply(L,O[D].includeScopes),L.push("_"),L},k.prototype.expandWithTab=function(T,D){var L=this,O=T.forEachSelection(function(){return L.expandSnippetForSelection(T,D)},null,{keepOrder:!0});return O&&T.tabstopManager&&T.tabstopManager.tabNext(),O},k.prototype.expandSnippetForSelection=function(T,D){var L=T.getCursorPosition(),O=T.session.getLine(L.row),z=O.substring(0,L.column),P=O.substr(L.column),N=this.snippetMap,A;return this.getActiveScopes(T).some(function(_){var I=N[_];return I&&(A=this.findMatchingSnippet(I,z,P)),!!A},this),A?(D&&D.dryRun||(T.session.doc.removeInLine(L.row,L.column-A.replaceBefore.length,L.column+A.replaceAfter.length),this.variables.M__=A.matchBefore,this.variables.T__=A.matchAfter,this.insertSnippetForSelection(T,A.content),this.variables.M__=this.variables.T__=null),!0):!1},k.prototype.findMatchingSnippet=function(T,D,L){for(var O=T.length;O--;){var z=T[O];if(!(z.startRe&&!z.startRe.test(D))&&!(z.endRe&&!z.endRe.test(L))&&!(!z.startRe&&!z.endRe))return z.matchBefore=z.startRe?z.startRe.exec(D):[""],z.matchAfter=z.endRe?z.endRe.exec(L):[""],z.replaceBefore=z.triggerRe?z.triggerRe.exec(D)[0]:"",z.replaceAfter=z.endTriggerRe?z.endTriggerRe.exec(L)[0]:"",z}},k.prototype.register=function(T,D){function L(_){return _&&!/^\^?\(.*\)\$?$|^\\b$/.test(_)&&(_="(?:"+_+")"),_||""}function O(_,I,j){return _=L(_),I=L(I),_=I+_,_&&_[_.length-1]!="$"&&(_+="$"),new RegExp(_)}function z(_){_.scope||(_.scope=D||"_"),D=_.scope,P[D]||(P[D]=[],N[D]={});var I=N[D];if(_.name){var j=I[_.name];j&&A.unregister(j),I[_.name]=_}P[D].push(_),_.prefix&&(_.tabTrigger=_.prefix),!_.content&&_.body&&(_.content=Array.isArray(_.body)?_.body.join(`
|
|
1133
|
+
`):_.body),_.tabTrigger&&!_.trigger&&(!_.guard&&/^\w/.test(_.tabTrigger)&&(_.guard="\\b"),_.trigger=g.escapeRegExp(_.tabTrigger)),!(!_.trigger&&!_.guard&&!_.endTrigger&&!_.endGuard)&&(_.startRe=O(_.trigger,_.guard),_.triggerRe=new RegExp(_.trigger),_.endRe=O(_.endTrigger,_.endGuard),_.endTriggerRe=new RegExp(_.endTrigger))}var P=this.snippetMap,N=this.snippetNameMap,A=this;T||(T=[]),Array.isArray(T)?T.forEach(z):Object.keys(T).forEach(function(_){z(T[_])}),this._signal("registerSnippets",{scope:D})},k.prototype.unregister=function(T,D){function L(P){var N=z[P.scope||D];if(N&&N[P.name]){delete N[P.name];var A=O[P.scope||D],_=A&&A.indexOf(P);_>=0&&A.splice(_,1)}}var O=this.snippetMap,z=this.snippetNameMap;T.content?L(T):Array.isArray(T)&&T.forEach(L)},k.prototype.parseSnippetFile=function(T){T=T.replace(/\r/g,"");for(var D=[],L={},O=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,z;z=O.exec(T);){if(z[1])try{L=JSON.parse(z[1]),D.push(L)}catch{}if(z[4])L.content=z[4].replace(/^\t/gm,""),D.push(L),L={};else{var P=z[2],N=z[3];if(P=="regex"){var A=/\/((?:[^\/\\]|\\.)*)|$/g;L.guard=A.exec(N)[1],L.trigger=A.exec(N)[1],L.endTrigger=A.exec(N)[1],L.endGuard=A.exec(N)[1]}else P=="snippet"?(L.tabTrigger=N.match(/^\S*/)[0],L.name||(L.name=N)):P&&(L[P]=N)}}return D},k.prototype.getSnippetByName=function(T,D){var L=this.snippetNameMap,O;return this.getActiveScopes(D).some(function(z){var P=L[z];return P&&(O=P[T]),!!O},this),O},k}();b.implement(m.prototype,p);var w=function(k,T,D){function L(he){for(var ge=[],Ee=0;Ee<he.length;Ee++){var Te=he[Ee];if(typeof Te=="object"){if(I[Te.tabstopId])continue;var Me=he.lastIndexOf(Te,Ee-1);Te=ge[Me]||{tabstopId:Te.tabstopId}}ge[Ee]=Te}return ge}D===void 0&&(D={});var O=k.getCursorPosition(),z=k.session.getLine(O.row),P=k.session.getTabString(),N=z.match(/^\s*/)[0];O.column<N.length&&(N=N.slice(0,O.column)),T=T.replace(/\r/g,"");var A=this.tokenizeTmSnippet(T);A=this.resolveVariables(A,k),A=A.map(function(he){return he==`
|
|
1134
|
+
`&&!D.excludeExtraIndent?he+N:typeof he=="string"?he.replace(/\t/g,P):he});var _=[];A.forEach(function(he,ge){if(typeof he=="object"){var Ee=he.tabstopId,Te=_[Ee];if(Te||(Te=_[Ee]=[],Te.index=Ee,Te.value="",Te.parents={}),Te.indexOf(he)===-1){he.choices&&!Te.choices&&(Te.choices=he.choices),Te.push(he);var Me=A.indexOf(he,ge+1);if(Me!==-1){var Xe=A.slice(ge+1,Me),Ke=Xe.some(function(dt){return typeof dt=="object"});Ke&&!Te.value?Te.value=Xe:Xe.length&&(!Te.value||typeof Te.value!="string")&&(Te.value=Xe.join(""))}}}}),_.forEach(function(he){he.length=0});for(var I={},j=0;j<A.length;j++){var U=A[j];if(typeof U=="object"){var K=U.tabstopId,Z=_[K],J=A.indexOf(U,j+1);if(I[K]){I[K]===U&&(delete I[K],Object.keys(I).forEach(function(he){Z.parents[he]=!0}));continue}I[K]=U;var ae=Z.value;typeof ae!="string"?ae=L(ae):U.fmt&&(ae=this.tmStrFormat(ae,U,k)),A.splice.apply(A,[j+1,Math.max(0,J-j)].concat(ae,U)),Z.indexOf(U)===-1&&Z.push(U)}}var ne=0,se=0,ce="";return A.forEach(function(he){if(typeof he=="string"){var ge=he.split(`
|
|
1135
|
+
`);ge.length>1?(se=ge[ge.length-1].length,ne+=ge.length-1):se+=he.length,ce+=he}else he&&(he.start?he.end={row:ne,column:se}:he.start={row:ne,column:se})}),{text:ce,tabstops:_,tokens:A}},x=function(){function k(T){if(this.index=0,this.ranges=[],this.tabstops=[],T.tabstopManager)return T.tabstopManager;T.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=g.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(T)}return k.prototype.attach=function(T){this.$openTabstops=null,this.selectedTabstop=null,this.editor=T,this.session=T.session,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},k.prototype.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges.length=0,this.tabstops.length=0,this.selectedTabstop=null,this.editor.off("change",this.$onChange),this.editor.off("changeSelection",this.$onChangeSelection),this.editor.off("changeSession",this.$onChangeSession),this.editor.commands.off("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.session=null,this.editor=null},k.prototype.onChange=function(T){for(var D=T.action[0]=="r",L=this.selectedTabstop||{},O=L.parents||{},z=this.tabstops.slice(),P=0;P<z.length;P++){var N=z[P],A=N==L||O[N.index];if(N.rangeList.$bias=A?0:1,T.action=="remove"&&N!==L){var _=N.parents&&N.parents[L.index],I=N.rangeList.pointIndex(T.start,_);I=I<0?-I-1:I+1;var j=N.rangeList.pointIndex(T.end,_);j=j<0?-j-1:j-1;for(var U=N.rangeList.ranges.slice(I,j),K=0;K<U.length;K++)this.removeRange(U[K])}N.rangeList.$onChange(T)}var Z=this.session;!this.$inChange&&D&&Z.getLength()==1&&!Z.getValue()&&this.detach()},k.prototype.updateLinkedFields=function(){var T=this.selectedTabstop;if(!(!T||!T.hasLinkedRanges||!T.firstNonLinked)){this.$inChange=!0;for(var D=this.session,L=D.getTextRange(T.firstNonLinked),O=0;O<T.length;O++){var z=T[O];if(z.linked){var P=z.original,N=r.snippetManager.tmStrFormat(L,P,this.editor);D.replace(z,N)}}this.$inChange=!1}},k.prototype.onAfterExec=function(T){T.command&&!T.command.readOnly&&this.updateLinkedFields()},k.prototype.onChangeSelection=function(){if(this.editor){for(var T=this.editor.selection.lead,D=this.editor.selection.anchor,L=this.editor.selection.isEmpty(),O=0;O<this.ranges.length;O++)if(!this.ranges[O].linked){var z=this.ranges[O].contains(T.row,T.column),P=L||this.ranges[O].contains(D.row,D.column);if(z&&P)return}this.detach()}},k.prototype.onChangeSession=function(){this.detach()},k.prototype.tabNext=function(T){var D=this.tabstops.length,L=this.index+(T||1);L=Math.min(Math.max(L,1),D),L==D&&(L=0),this.selectTabstop(L),this.updateTabstopMarkers(),L===0&&this.detach()},k.prototype.selectTabstop=function(T){this.$openTabstops=null;var D=this.tabstops[this.index];if(D&&this.addTabstopMarkers(D),this.index=T,D=this.tabstops[this.index],!(!D||!D.length)){this.selectedTabstop=D;var L=D.firstNonLinked||D;if(D.choices&&(L.cursor=L.start),this.editor.inVirtualSelectionMode)this.editor.selection.fromOrientedRange(L);else{var O=this.editor.multiSelect;O.toSingleRange(L);for(var z=0;z<D.length;z++)D.hasLinkedRanges&&D[z].linked||O.addRange(D[z].clone(),!0)}this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler),this.selectedTabstop&&this.selectedTabstop.choices&&this.editor.execCommand("startAutocomplete",{matches:this.selectedTabstop.choices})}},k.prototype.addTabstops=function(T,D,L){var O=this.useLink||!this.editor.getOption("enableMultiselect");if(this.$openTabstops||(this.$openTabstops=[]),!T[0]){var z=o.fromPoints(L,L);$(z.start,D),$(z.end,D),T[0]=[z],T[0].index=0}var P=this.index,N=[P+1,0],A=this.ranges,_=this.snippetId=(this.snippetId||0)+1;T.forEach(function(I,j){var U=this.$openTabstops[j]||I;U.snippetId=_;for(var K=0;K<I.length;K++){var Z=I[K],J=o.fromPoints(Z.start,Z.end||Z.start);M(J.start,D),M(J.end,D),J.original=Z,J.tabstop=U,A.push(J),U!=I?U.unshift(J):U[K]=J,Z.fmtString||U.firstNonLinked&&O?(J.linked=!0,U.hasLinkedRanges=!0):U.firstNonLinked||(U.firstNonLinked=J)}U.firstNonLinked||(U.hasLinkedRanges=!1),U===I&&(N.push(U),this.$openTabstops[j]=U),this.addTabstopMarkers(U),U.rangeList=U.rangeList||new c,U.rangeList.$bias=0,U.rangeList.addList(U)},this),N.length>2&&(this.tabstops.length&&N.push(N.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,N))},k.prototype.addTabstopMarkers=function(T){var D=this.session;T.forEach(function(L){L.markerId||(L.markerId=D.addMarker(L,"ace_snippet-marker","text"))})},k.prototype.removeTabstopMarkers=function(T){var D=this.session;T.forEach(function(L){D.removeMarker(L.markerId),L.markerId=null})},k.prototype.updateTabstopMarkers=function(){if(this.selectedTabstop){var T=this.selectedTabstop.snippetId;this.selectedTabstop.index===0&&T--,this.tabstops.forEach(function(D){D.snippetId===T?this.addTabstopMarkers(D):this.removeTabstopMarkers(D)},this)}},k.prototype.removeRange=function(T){var D=T.tabstop.indexOf(T);D!=-1&&T.tabstop.splice(D,1),D=this.ranges.indexOf(T),D!=-1&&this.ranges.splice(D,1),D=T.tabstop.rangeList.ranges.indexOf(T),D!=-1&&T.tabstop.splice(D,1),this.session.removeMarker(T.markerId),T.tabstop.length||(D=this.tabstops.indexOf(T.tabstop),D!=-1&&this.tabstops.splice(D,1),this.tabstops.length||this.detach())},k}();x.prototype.keyboardHandler=new f,x.prototype.keyboardHandler.bindKeys({Tab:function(k){r.snippetManager&&r.snippetManager.expandWithTab(k)||(k.tabstopManager.tabNext(1),k.renderer.scrollCursorIntoView())},"Shift-Tab":function(k){k.tabstopManager.tabNext(-1),k.renderer.scrollCursorIntoView()},Esc:function(k){k.tabstopManager.detach()}});var M=function(k,T){k.row==0&&(k.column+=T.column),k.row+=T.row},$=function(k,T){k.row==T.row&&(k.column-=T.column),k.row-=T.row};h.importCssString(`
|
|
1136
|
+
.ace_snippet-marker {
|
|
1137
|
+
-moz-box-sizing: border-box;
|
|
1138
|
+
box-sizing: border-box;
|
|
1139
|
+
background: rgba(194, 193, 208, 0.09);
|
|
1140
|
+
border: 1px dotted rgba(211, 208, 235, 0.62);
|
|
1141
|
+
position: absolute;
|
|
1142
|
+
}`,"snippets.css",!1),r.snippetManager=new m;var S=t("./editor").Editor;(function(){this.insertSnippet=function(k,T){return r.snippetManager.insertSnippet(this,k,T)},this.expandSnippet=function(k){return r.snippetManager.expandWithTab(this,k)}}).call(S.prototype)}),ace.define("ace/autocomplete/popup",["require","exports","module","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom","ace/config","ace/lib/useragent"],function(t,r,l){var d=t("../virtual_renderer").VirtualRenderer,h=t("../editor").Editor,b=t("../range").Range,p=t("../lib/event"),g=t("../lib/lang"),o=t("../lib/dom"),c=t("../config").nls,f=t("./../lib/useragent"),u=function(M){return"suggest-aria-id:".concat(M)},i=f.isSafari?"menu":"listbox",a=f.isSafari?"menuitem":"option",m=f.isSafari?"aria-current":"aria-selected",w=function(M){var $=new d(M);$.$maxLines=4;var S=new h($);return S.setHighlightActiveLine(!1),S.setShowPrintMargin(!1),S.renderer.setShowGutter(!1),S.renderer.setHighlightGutterLine(!1),S.$mouseHandler.$focusTimeout=0,S.$highlightTagPending=!0,S},x=function(){function M($){var S=o.createElement("div"),k=w(S);$&&$.appendChild(S),S.style.display="none",k.renderer.content.style.cursor="default",k.renderer.setStyle("ace_autocomplete"),k.renderer.$textLayer.element.setAttribute("role",i),k.renderer.$textLayer.element.setAttribute("aria-roledescription",c("autocomplete.popup.aria-roledescription","Autocomplete suggestions")),k.renderer.$textLayer.element.setAttribute("aria-label",c("autocomplete.popup.aria-label","Autocomplete suggestions")),k.renderer.textarea.setAttribute("aria-hidden","true"),k.setOption("displayIndentGuides",!1),k.setOption("dragDelay",150);var T=function(){};k.focus=T,k.$isFocused=!0,k.renderer.$cursorLayer.restartTimer=T,k.renderer.$cursorLayer.element.style.opacity="0",k.renderer.$maxLines=8,k.renderer.$keepTextAreaAtCursor=!1,k.setHighlightActiveLine(!1),k.session.highlight(""),k.session.$searchHighlight.clazz="ace_highlight-marker",k.on("mousedown",function(A){var _=A.getDocumentPosition();k.selection.moveToPosition(_),O.start.row=O.end.row=_.row,A.stop()});var D,L=new b(-1,0,-1,1/0),O=new b(-1,0,-1,1/0);O.id=k.session.addMarker(O,"ace_active-line","fullLine"),k.setSelectOnHover=function(A){A?L.id&&(k.session.removeMarker(L.id),L.id=null):L.id=k.session.addMarker(L,"ace_line-hover","fullLine")},k.setSelectOnHover(!1),k.on("mousemove",function(A){if(!D){D=A;return}if(!(D.x==A.x&&D.y==A.y)){D=A,D.scrollTop=k.renderer.scrollTop,k.isMouseOver=!0;var _=D.getDocumentPosition().row;L.start.row!=_&&(L.id||k.setRow(_),P(_))}}),k.renderer.on("beforeRender",function(){if(D&&L.start.row!=-1){D.$pos=null;var A=D.getDocumentPosition().row;L.id||k.setRow(A),P(A,!0)}}),k.renderer.on("afterRender",function(){for(var A=k.renderer.$textLayer,_=A.config.firstRow,I=A.config.lastRow;_<=I;_++){var j=A.element.childNodes[_-A.config.firstRow];j.setAttribute("role",a),j.setAttribute("aria-roledescription",c("autocomplete.popup.item.aria-roledescription","item")),j.setAttribute("aria-setsize",k.data.length),j.setAttribute("aria-describedby","doc-tooltip"),j.setAttribute("aria-posinset",_+1);var U=k.getData(_);if(U){var K="".concat(U.caption||U.value).concat(U.meta?", ".concat(U.meta):"");j.setAttribute("aria-label",K)}var Z=j.querySelectorAll(".ace_completion-highlight");Z.forEach(function(J){J.setAttribute("role","mark")})}}),k.renderer.on("afterRender",function(){var A=k.getRow(),_=k.renderer.$textLayer,I=_.element.childNodes[A-_.config.firstRow],j=document.activeElement;if(I!==k.selectedNode&&k.selectedNode&&(o.removeCssClass(k.selectedNode,"ace_selected"),k.selectedNode.removeAttribute(m),k.selectedNode.removeAttribute("id")),j.removeAttribute("aria-activedescendant"),k.selectedNode=I,I){var U=u(A);o.addCssClass(I,"ace_selected"),I.id=U,_.element.setAttribute("aria-activedescendant",U),j.setAttribute("aria-activedescendant",U),I.setAttribute(m,"true")}});var z=function(){P(-1)},P=function(A,_){A!==L.start.row&&(L.start.row=L.end.row=A,_||k.session._emit("changeBackMarker"),k._emit("changeHoverMarker"))};k.getHoveredRow=function(){return L.start.row},p.addListener(k.container,"mouseout",function(){k.isMouseOver=!1,z()}),k.on("hide",z),k.on("changeSelection",z),k.session.doc.getLength=function(){return k.data.length},k.session.doc.getLine=function(A){var _=k.data[A];return typeof _=="string"?_:_&&_.value||""};var N=k.session.bgTokenizer;return N.$tokenizeRow=function(A){function _(he,ge){he&&j.push({type:(I.className||"")+(ge||""),value:he})}var I=k.data[A],j=[];if(!I)return j;typeof I=="string"&&(I={value:I});for(var U=I.caption||I.value||I.name,K=U.toLowerCase(),Z=(k.filterText||"").toLowerCase(),J=0,ae=0,ne=0;ne<=Z.length;ne++)if(ne!=ae&&(I.matchMask&1<<ne||ne==Z.length)){var se=Z.slice(ae,ne);ae=ne;var ce=K.indexOf(se,J);if(ce==-1)continue;_(U.slice(J,ce),""),J=ce+se.length,_(U.slice(ce,J),"completion-highlight")}return _(U.slice(J,U.length),""),j.push({type:"completion-spacer",value:" "}),I.meta&&j.push({type:"completion-meta",value:I.meta}),I.message&&j.push({type:"completion-message",value:I.message}),j},N.$updateOnChange=T,N.start=T,k.session.$computeWidth=function(){return this.screenWidth=0},k.isOpen=!1,k.isTopdown=!1,k.autoSelect=!0,k.filterText="",k.isMouseOver=!1,k.data=[],k.setData=function(A,_){k.filterText=_||"",k.setValue(g.stringRepeat(`
|
|
1143
|
+
`,A.length),-1),k.data=A||[],k.setRow(0)},k.getData=function(A){return k.data[A]},k.getRow=function(){return O.start.row},k.setRow=function(A){A=Math.max(this.autoSelect?0:-1,Math.min(this.data.length-1,A)),O.start.row!=A&&(k.selection.clearSelection(),O.start.row=O.end.row=A||0,k.session._emit("changeBackMarker"),k.moveCursorTo(A||0,0),k.isOpen&&k._signal("select"))},k.on("changeSelection",function(){k.isOpen&&k.setRow(k.selection.lead.row),k.renderer.scrollCursorIntoView()}),k.hide=function(){this.container.style.display="none",k.anchorPos=null,k.anchor=null,k.isOpen&&(k.isOpen=!1,this._signal("hide"))},k.tryShow=function(A,_,I,j){if(!j&&k.isOpen&&k.anchorPos&&k.anchor&&k.anchorPos.top===A.top&&k.anchorPos.left===A.left&&k.anchor===I)return!0;var U=this.container,K=this.renderer.scrollBar.width||10,Z=window.innerHeight-K,J=window.innerWidth-K,ae=this.renderer,ne=ae.$maxLines*_*1.4,se={top:0,bottom:0},ce=Z-A.top-3*this.$borderSize-_,he=A.top-3*this.$borderSize;I||(he<=ce||ce>=ne?I="bottom":I="top"),I==="top"?(se.bottom=A.top-this.$borderSize,se.top=se.bottom-ne):I==="bottom"&&(se.top=A.top+_+this.$borderSize,se.bottom=se.top+ne);var ge=se.top>=0&&se.bottom<=Z;if(!j&&!ge)return!1;ge?ae.$maxPixelHeight=null:I==="top"?ae.$maxPixelHeight=he:ae.$maxPixelHeight=ce,I==="top"?(U.style.top="",U.style.bottom=Z+K-se.bottom+"px",k.isTopdown=!1):(U.style.top=se.top+"px",U.style.bottom="",k.isTopdown=!0),U.style.display="";var Ee=A.left;return Ee+U.offsetWidth>J&&(Ee=J-U.offsetWidth),U.style.left=Ee+"px",U.style.right="",k.isOpen||(k.isOpen=!0,this._signal("show"),D=null),k.anchorPos=A,k.anchor=I,o.$fixPositionBug(U),!0},k.show=function(A,_,I){this.tryShow(A,_,I?"bottom":void 0,!0)},k.goTo=function(A){var _=this.getRow(),I=this.session.getLength()-1;switch(A){case"up":_=_<=0?I:_-1;break;case"down":_=_>=I?-1:_+1;break;case"start":_=0;break;case"end":_=I}this.setRow(_)},k.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},k.$imageSize=0,k.$borderSize=1,k}return M}();o.importCssString(`
|
|
1144
|
+
.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {
|
|
1145
|
+
background-color: #CAD6FA;
|
|
1146
|
+
z-index: 1;
|
|
1147
|
+
}
|
|
1148
|
+
.ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {
|
|
1149
|
+
background-color: #3a674e;
|
|
1150
|
+
}
|
|
1151
|
+
.ace_editor.ace_autocomplete .ace_line-hover {
|
|
1152
|
+
border: 1px solid #abbffe;
|
|
1153
|
+
margin-top: -1px;
|
|
1154
|
+
background: rgba(233,233,253,0.4);
|
|
1155
|
+
position: absolute;
|
|
1156
|
+
z-index: 2;
|
|
1157
|
+
}
|
|
1158
|
+
.ace_dark.ace_editor.ace_autocomplete .ace_line-hover {
|
|
1159
|
+
border: 1px solid rgba(109, 150, 13, 0.8);
|
|
1160
|
+
background: rgba(58, 103, 78, 0.62);
|
|
1161
|
+
}
|
|
1162
|
+
.ace_completion-meta {
|
|
1163
|
+
opacity: 0.5;
|
|
1164
|
+
margin-left: 0.9em;
|
|
1165
|
+
}
|
|
1166
|
+
.ace_completion-message {
|
|
1167
|
+
margin-left: 0.9em;
|
|
1168
|
+
color: blue;
|
|
1169
|
+
}
|
|
1170
|
+
.ace_editor.ace_autocomplete .ace_completion-highlight{
|
|
1171
|
+
color: #2d69c7;
|
|
1172
|
+
}
|
|
1173
|
+
.ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{
|
|
1174
|
+
color: #93ca12;
|
|
1175
|
+
}
|
|
1176
|
+
.ace_editor.ace_autocomplete {
|
|
1177
|
+
width: 300px;
|
|
1178
|
+
z-index: 200000;
|
|
1179
|
+
border: 1px lightgray solid;
|
|
1180
|
+
position: fixed;
|
|
1181
|
+
box-shadow: 2px 3px 5px rgba(0,0,0,.2);
|
|
1182
|
+
line-height: 1.4;
|
|
1183
|
+
background: #fefefe;
|
|
1184
|
+
color: #111;
|
|
1185
|
+
}
|
|
1186
|
+
.ace_dark.ace_editor.ace_autocomplete {
|
|
1187
|
+
border: 1px #484747 solid;
|
|
1188
|
+
box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51);
|
|
1189
|
+
line-height: 1.4;
|
|
1190
|
+
background: #25282c;
|
|
1191
|
+
color: #c1c1c1;
|
|
1192
|
+
}
|
|
1193
|
+
.ace_autocomplete .ace_text-layer {
|
|
1194
|
+
width: calc(100% - 8px);
|
|
1195
|
+
}
|
|
1196
|
+
.ace_autocomplete .ace_line {
|
|
1197
|
+
display: flex;
|
|
1198
|
+
align-items: center;
|
|
1199
|
+
}
|
|
1200
|
+
.ace_autocomplete .ace_line > * {
|
|
1201
|
+
min-width: 0;
|
|
1202
|
+
flex: 0 0 auto;
|
|
1203
|
+
}
|
|
1204
|
+
.ace_autocomplete .ace_line .ace_ {
|
|
1205
|
+
flex: 0 1 auto;
|
|
1206
|
+
overflow: hidden;
|
|
1207
|
+
text-overflow: ellipsis;
|
|
1208
|
+
}
|
|
1209
|
+
.ace_autocomplete .ace_completion-spacer {
|
|
1210
|
+
flex: 1;
|
|
1211
|
+
}
|
|
1212
|
+
.ace_autocomplete.ace_loading:after {
|
|
1213
|
+
content: "";
|
|
1214
|
+
position: absolute;
|
|
1215
|
+
top: 0px;
|
|
1216
|
+
height: 2px;
|
|
1217
|
+
width: 8%;
|
|
1218
|
+
background: blue;
|
|
1219
|
+
z-index: 100;
|
|
1220
|
+
animation: ace_progress 3s infinite linear;
|
|
1221
|
+
animation-delay: 300ms;
|
|
1222
|
+
transform: translateX(-100%) scaleX(1);
|
|
1223
|
+
}
|
|
1224
|
+
@keyframes ace_progress {
|
|
1225
|
+
0% { transform: translateX(-100%) scaleX(1) }
|
|
1226
|
+
50% { transform: translateX(625%) scaleX(2) }
|
|
1227
|
+
100% { transform: translateX(1500%) scaleX(3) }
|
|
1228
|
+
}
|
|
1229
|
+
@media (prefers-reduced-motion) {
|
|
1230
|
+
.ace_autocomplete.ace_loading:after {
|
|
1231
|
+
transform: translateX(625%) scaleX(2);
|
|
1232
|
+
animation: none;
|
|
1233
|
+
}
|
|
1234
|
+
}
|
|
1235
|
+
`,"autocompletion.css",!1),r.AcePopup=x,r.$singleLineEditor=w,r.getAriaId=u}),ace.define("ace/autocomplete/inline_screenreader",["require","exports","module"],function(t,r,l){var d=function(){function h(b){this.editor=b,this.screenReaderDiv=document.createElement("div"),this.screenReaderDiv.classList.add("ace_screenreader-only"),this.editor.container.appendChild(this.screenReaderDiv)}return h.prototype.setScreenReaderContent=function(b){for(!this.popup&&this.editor.completer&&this.editor.completer.popup&&(this.popup=this.editor.completer.popup,this.popup.renderer.on("afterRender",(function(){var g=this.popup.getRow(),o=this.popup.renderer.$textLayer,c=o.element.childNodes[g-o.config.firstRow];if(c){for(var f="doc-tooltip ",u=0;u<this._lines.length;u++)f+="ace-inline-screenreader-line-".concat(u," ");c.setAttribute("aria-describedby",f)}}).bind(this)));this.screenReaderDiv.firstChild;)this.screenReaderDiv.removeChild(this.screenReaderDiv.firstChild);this._lines=b.split(/\r\n|\r|\n/);var p=this.createCodeBlock();this.screenReaderDiv.appendChild(p)},h.prototype.destroy=function(){this.screenReaderDiv.remove()},h.prototype.createCodeBlock=function(){var b=document.createElement("pre");b.setAttribute("id","ace-inline-screenreader");for(var p=0;p<this._lines.length;p++){var g=document.createElement("code");g.setAttribute("id","ace-inline-screenreader-line-".concat(p));var o=document.createTextNode(this._lines[p]);g.appendChild(o),b.appendChild(g)}return b},h}();r.AceInlineScreenReader=d}),ace.define("ace/autocomplete/inline",["require","exports","module","ace/snippets","ace/autocomplete/inline_screenreader"],function(t,r,l){var d=t("../snippets").snippetManager,h=t("./inline_screenreader").AceInlineScreenReader,b=function(){function p(){this.editor=null}return p.prototype.show=function(g,o,c){if(c=c||"",g&&this.editor&&this.editor!==g&&(this.hide(),this.editor=null,this.inlineScreenReader=null),!g||!o)return!1;this.inlineScreenReader||(this.inlineScreenReader=new h(g));var f=o.snippet?d.getDisplayTextForSnippet(g,o.snippet):o.value;return o.hideInlinePreview||!f||!f.startsWith(c)?!1:(this.editor=g,this.inlineScreenReader.setScreenReaderContent(f),f=f.slice(c.length),f===""?g.removeGhostText():g.setGhostText(f),!0)},p.prototype.isOpen=function(){return this.editor?!!this.editor.renderer.$ghostText:!1},p.prototype.hide=function(){return this.editor?(this.editor.removeGhostText(),!0):!1},p.prototype.destroy=function(){this.hide(),this.editor=null,this.inlineScreenReader&&(this.inlineScreenReader.destroy(),this.inlineScreenReader=null)},p}();r.AceInline=b}),ace.define("ace/autocomplete/util",["require","exports","module"],function(t,r,l){r.parForEach=function(h,b,p){var g=0,o=h.length;o===0&&p();for(var c=0;c<o;c++)b(h[c],function(f,u){g++,g===o&&p(f,u)})};var d=/[a-zA-Z_0-9\$\-\u00A2-\u2000\u2070-\uFFFF]/;r.retrievePrecedingIdentifier=function(h,b,p){p=p||d;for(var g=[],o=b-1;o>=0&&p.test(h[o]);o--)g.push(h[o]);return g.reverse().join("")},r.retrieveFollowingIdentifier=function(h,b,p){p=p||d;for(var g=[],o=b;o<h.length&&p.test(h[o]);o++)g.push(h[o]);return g},r.getCompletionPrefix=function(h){var b=h.getCursorPosition(),p=h.session.getLine(b.row),g;return h.completers.forEach((function(o){o.identifierRegexps&&o.identifierRegexps.forEach((function(c){!g&&c&&(g=this.retrievePrecedingIdentifier(p,b.column,c))}).bind(this))}).bind(this)),g||this.retrievePrecedingIdentifier(p,b.column)},r.triggerAutocomplete=function(h,p){var p=p??h.session.getPrecedingCharacter();return h.completers.some(function(g){if(g.triggerCharacters&&Array.isArray(g.triggerCharacters))return g.triggerCharacters.includes(p)})}}),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/inline","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/lang","ace/lib/dom","ace/snippets","ace/config","ace/lib/event","ace/lib/scroll"],function(t,r,l){var d=t("./keyboard/hash_handler").HashHandler,h=t("./autocomplete/popup").AcePopup,b=t("./autocomplete/inline").AceInline,p=t("./autocomplete/popup").getAriaId,g=t("./autocomplete/util"),o=t("./lib/lang"),c=t("./lib/dom"),f=t("./snippets").snippetManager,u=t("./config"),i=t("./lib/event"),a=t("./lib/scroll").preventParentScroll,m=function($,S){S.completer&&S.completer.destroy()},w=function(){function $(){this.autoInsert=!1,this.autoSelect=!0,this.autoShown=!1,this.exactMatch=!1,this.inlineEnabled=!1,this.keyboardHandler=new d,this.keyboardHandler.bindKeys(this.commands),this.parentNode=null,this.setSelectOnHover=!1,this.hasSeen=new Set,this.showLoadingState=!1,this.stickySelectionDelay=500,this.blurListener=this.blurListener.bind(this),this.changeListener=this.changeListener.bind(this),this.mousedownListener=this.mousedownListener.bind(this),this.mousewheelListener=this.mousewheelListener.bind(this),this.onLayoutChange=this.onLayoutChange.bind(this),this.changeTimer=o.delayedCall((function(){this.updateCompletions(!0)}).bind(this)),this.tooltipTimer=o.delayedCall(this.updateDocTooltip.bind(this),50),this.popupTimer=o.delayedCall(this.$updatePopupPosition.bind(this),50),this.stickySelectionTimer=o.delayedCall((function(){this.stickySelection=!0}).bind(this),this.stickySelectionDelay),this.$firstOpenTimer=o.delayedCall((function(){var S=this.completionProvider&&this.completionProvider.initialPosition;this.autoShown||this.popup&&this.popup.isOpen||!S||this.editor.completers.length===0||(this.completions=new M($.completionsForLoading),this.openPopup(this.editor,S.prefix,!1),this.popup.renderer.setStyle("ace_loading",!0))}).bind(this),this.stickySelectionDelay)}return Object.defineProperty($,"completionsForLoading",{get:function(){return[{caption:u.nls("autocomplete.loading","Loading..."),value:""}]},enumerable:!1,configurable:!0}),$.prototype.$init=function(){return this.popup=new h(this.parentNode||document.body||document.documentElement),this.popup.on("click",(function(S){this.insertMatch(),S.stop()}).bind(this)),this.popup.focus=this.editor.focus.bind(this.editor),this.popup.on("show",this.$onPopupShow.bind(this)),this.popup.on("hide",this.$onHidePopup.bind(this)),this.popup.on("select",this.$onPopupChange.bind(this)),i.addListener(this.popup.container,"mouseout",this.mouseOutListener.bind(this)),this.popup.on("changeHoverMarker",this.tooltipTimer.bind(null,null)),this.popup.renderer.on("afterRender",this.$onPopupRender.bind(this)),this.popup},$.prototype.$initInline=function(){if(!(!this.inlineEnabled||this.inlineRenderer))return this.inlineRenderer=new b,this.inlineRenderer},$.prototype.getPopup=function(){return this.popup||this.$init()},$.prototype.$onHidePopup=function(){this.inlineRenderer&&this.inlineRenderer.hide(),this.hideDocTooltip(),this.stickySelectionTimer.cancel(),this.popupTimer.cancel(),this.stickySelection=!1},$.prototype.$seen=function(S){!this.hasSeen.has(S)&&S&&S.completer&&S.completer.onSeen&&typeof S.completer.onSeen=="function"&&(S.completer.onSeen(this.editor,S),this.hasSeen.add(S))},$.prototype.$onPopupChange=function(S){if(this.inlineRenderer&&this.inlineEnabled){var k=S?null:this.popup.getData(this.popup.getRow());if(this.$updateGhostText(k),this.popup.isMouseOver&&this.setSelectOnHover){this.tooltipTimer.call(null,null);return}this.popupTimer.schedule(),this.tooltipTimer.schedule()}else this.popupTimer.call(null,null),this.tooltipTimer.call(null,null)},$.prototype.$updateGhostText=function(S){var k=this.base.row,T=this.base.column,D=this.editor.getCursorPosition().column,L=this.editor.session.getLine(k).slice(T,D);this.inlineRenderer.show(this.editor,S,L)?this.$seen(S):this.inlineRenderer.hide()},$.prototype.$onPopupRender=function(){var S=this.inlineRenderer&&this.inlineEnabled;if(this.completions&&this.completions.filtered&&this.completions.filtered.length>0)for(var k=this.popup.getFirstVisibleRow();k<=this.popup.getLastVisibleRow();k++){var T=this.popup.getData(k);T&&(!S||T.hideInlinePreview)&&this.$seen(T)}},$.prototype.$onPopupShow=function(S){this.$onPopupChange(S),this.stickySelection=!1,this.stickySelectionDelay>=0&&this.stickySelectionTimer.schedule(this.stickySelectionDelay)},$.prototype.observeLayoutChanges=function(){if(!(this.$elements||!this.editor)){window.addEventListener("resize",this.onLayoutChange,{passive:!0}),window.addEventListener("wheel",this.mousewheelListener);for(var S=this.editor.container.parentNode,k=[];S;)k.push(S),S.addEventListener("scroll",this.onLayoutChange,{passive:!0}),S=S.parentNode;this.$elements=k}},$.prototype.unObserveLayoutChanges=function(){var S=this;window.removeEventListener("resize",this.onLayoutChange,{passive:!0}),window.removeEventListener("wheel",this.mousewheelListener),this.$elements&&this.$elements.forEach(function(k){k.removeEventListener("scroll",S.onLayoutChange,{passive:!0})}),this.$elements=null},$.prototype.onLayoutChange=function(){if(!this.popup.isOpen)return this.unObserveLayoutChanges();this.$updatePopupPosition(),this.updateDocTooltip()},$.prototype.$updatePopupPosition=function(){var S=this.editor,k=S.renderer,T=k.layerConfig.lineHeight,D=k.$cursorLayer.getPixelPosition(this.base,!0);D.left-=this.popup.getTextLeftOffset();var L=S.container.getBoundingClientRect();D.top+=L.top-k.layerConfig.offset,D.left+=L.left-S.renderer.scrollLeft,D.left+=k.gutterWidth;var O={top:D.top,left:D.left};k.$ghostText&&k.$ghostTextWidget&&this.base.row===k.$ghostText.position.row&&(O.top+=k.$ghostTextWidget.el.offsetHeight);var z=S.container.getBoundingClientRect().bottom-T,P=z<O.top?{top:z,left:O.left}:O;this.popup.tryShow(P,T,"bottom")||this.popup.tryShow(D,T,"top")||this.popup.show(D,T)},$.prototype.openPopup=function(S,k,T){this.$firstOpenTimer.cancel(),this.popup||this.$init(),this.inlineEnabled&&!this.inlineRenderer&&this.$initInline(),this.popup.autoSelect=this.autoSelect,this.popup.setSelectOnHover(this.setSelectOnHover);var D=this.popup.getRow(),L=this.popup.data[D];this.popup.setData(this.completions.filtered,this.completions.filterText),this.editor.textInput.setAriaOptions&&this.editor.textInput.setAriaOptions({activeDescendant:p(this.popup.getRow()),inline:this.inlineEnabled}),S.keyBinding.addKeyboardHandler(this.keyboardHandler);var O;this.stickySelection&&(O=this.popup.data.indexOf(L)),(!O||O===-1)&&(O=0),this.popup.setRow(this.autoSelect?O:-1),O===D&&L!==this.completions.filtered[O]&&this.$onPopupChange();var z=this.inlineRenderer&&this.inlineEnabled;if(O===D&&z){var P=this.popup.getData(this.popup.getRow());this.$updateGhostText(P)}T||(this.popup.setTheme(S.getTheme()),this.popup.setFontSize(S.getFontSize()),this.$updatePopupPosition(),this.tooltipNode&&this.updateDocTooltip()),this.changeTimer.cancel(),this.observeLayoutChanges()},$.prototype.detach=function(){this.editor&&(this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.off("changeSelection",this.changeListener),this.editor.off("blur",this.blurListener),this.editor.off("mousedown",this.mousedownListener),this.editor.off("mousewheel",this.mousewheelListener)),this.$firstOpenTimer.cancel(),this.changeTimer.cancel(),this.hideDocTooltip(),this.completionProvider&&this.completionProvider.detach(),this.popup&&this.popup.isOpen&&this.popup.hide(),this.popup&&this.popup.renderer&&this.popup.renderer.off("afterRender",this.$onPopupRender),this.base&&this.base.detach(),this.activated=!1,this.completionProvider=this.completions=this.base=null,this.unObserveLayoutChanges()},$.prototype.changeListener=function(S){var k=this.editor.selection.lead;(k.row!=this.base.row||k.column<this.base.column)&&this.detach(),this.activated?this.changeTimer.schedule():this.detach()},$.prototype.blurListener=function(S){var k=document.activeElement,T=this.editor.textInput.getElement(),D=S.relatedTarget&&this.tooltipNode&&this.tooltipNode.contains(S.relatedTarget),L=this.popup&&this.popup.container;k!=T&&k.parentNode!=L&&!D&&k!=this.tooltipNode&&S.relatedTarget!=T&&this.detach()},$.prototype.mousedownListener=function(S){this.detach()},$.prototype.mousewheelListener=function(S){this.popup&&!this.popup.isMouseOver&&this.detach()},$.prototype.mouseOutListener=function(S){this.popup.isOpen&&this.$updatePopupPosition()},$.prototype.goTo=function(S){this.popup.goTo(S)},$.prototype.insertMatch=function(S,k){if(S||(S=this.popup.getData(this.popup.getRow())),!S)return!1;if(S.value==="")return this.detach();var T=this.completions,D=this.getCompletionProvider().insertMatch(this.editor,S,T.filterText,k);return this.completions==T&&this.detach(),D},$.prototype.showPopup=function(S,k){this.editor&&this.detach(),this.activated=!0,this.editor=S,S.completer!=this&&(S.completer&&S.completer.detach(),S.completer=this),S.on("changeSelection",this.changeListener),S.on("blur",this.blurListener),S.on("mousedown",this.mousedownListener),S.on("mousewheel",this.mousewheelListener),this.updateCompletions(!1,k)},$.prototype.getCompletionProvider=function(S){return this.completionProvider||(this.completionProvider=new x(S)),this.completionProvider},$.prototype.gatherCompletions=function(S,k){return this.getCompletionProvider().gatherCompletions(S,k)},$.prototype.updateCompletions=function(S,k){if(S&&this.base&&this.completions){var D=this.editor.getCursorPosition(),L=this.editor.session.getTextRange({start:this.base,end:D});if(L==this.completions.filterText)return;if(this.completions.setFilter(L),!this.completions.filtered.length)return this.detach();if(this.completions.filtered.length==1&&this.completions.filtered[0].value==L&&!this.completions.filtered[0].snippet)return this.detach();this.openPopup(this.editor,L,S);return}if(k&&k.matches){var D=this.editor.getSelectionRange().start;return this.base=this.editor.session.doc.createAnchor(D.row,D.column),this.base.$insertRight=!0,this.completions=new M(k.matches),this.getCompletionProvider().completions=this.completions,this.openPopup(this.editor,"",S)}var T=this.editor.getSession(),D=this.editor.getCursorPosition(),L=g.getCompletionPrefix(this.editor);this.base=T.doc.createAnchor(D.row,D.column-L.length),this.base.$insertRight=!0;var O={exactMatch:this.exactMatch,ignoreCaption:this.ignoreCaption};this.getCompletionProvider({prefix:L,pos:D}).provideCompletions(this.editor,O,(function(z,P,N){var A=P.filtered,_=g.getCompletionPrefix(this.editor);if(this.$firstOpenTimer.cancel(),N){if(!A.length){var I=!this.autoShown&&this.emptyMessage;if(typeof I=="function"&&(I=this.emptyMessage(_)),I){var j=[{caption:I,value:""}];this.completions=new M(j),this.openPopup(this.editor,_,S),this.popup.renderer.setStyle("ace_loading",!1),this.popup.renderer.setStyle("ace_empty-message",!0);return}return this.detach()}if(A.length==1&&A[0].value==_&&!A[0].snippet)return this.detach();if(this.autoInsert&&!this.autoShown&&A.length==1)return this.insertMatch(A[0])}this.completions=!N&&this.showLoadingState?new M($.completionsForLoading.concat(A),P.filterText):P,this.openPopup(this.editor,_,S),this.popup.renderer.setStyle("ace_empty-message",!1),this.popup.renderer.setStyle("ace_loading",!N)}).bind(this)),this.showLoadingState&&!this.autoShown&&(!this.popup||!this.popup.isOpen)&&this.$firstOpenTimer.delay(this.stickySelectionDelay/2)},$.prototype.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()},$.prototype.updateDocTooltip=function(){var S=this.popup,k=this.completions&&this.completions.filtered,T=k&&(k[S.getHoveredRow()]||k[S.getRow()]),D=null;if(!T||!this.editor||!this.popup.isOpen)return this.hideDocTooltip();for(var L=this.editor.completers.length,O=0;O<L;O++){var z=this.editor.completers[O];if(z.getDocTooltip&&T.completerId===z.id){D=z.getDocTooltip(T);break}}if(!D&&typeof T!="string"&&(D=T),typeof D=="string"&&(D={docText:D}),!D||!D.docHTML&&!D.docText)return this.hideDocTooltip();this.showDocTooltip(D)},$.prototype.showDocTooltip=function(S){this.tooltipNode||(this.tooltipNode=c.createElement("div"),this.tooltipNode.style.margin="0",this.tooltipNode.style.pointerEvents="auto",this.tooltipNode.style.overscrollBehavior="contain",this.tooltipNode.tabIndex=-1,this.tooltipNode.onblur=this.blurListener.bind(this),this.tooltipNode.onclick=this.onTooltipClick.bind(this),this.tooltipNode.id="doc-tooltip",this.tooltipNode.setAttribute("role","tooltip"),this.tooltipNode.addEventListener("wheel",a));var k=this.editor.renderer.theme;this.tooltipNode.className="ace_tooltip ace_doc-tooltip "+(k.isDark?"ace_dark ":"")+(k.cssClass||"");var T=this.tooltipNode;S.docHTML?T.innerHTML=S.docHTML:S.docText&&(T.textContent=S.docText),T.parentNode||this.popup.container.appendChild(this.tooltipNode);var D=this.popup,L=D.container.getBoundingClientRect(),O=400,z=300,P=D.renderer.scrollBar.width||10,N=L.left,A=window.innerWidth-L.right-P,_=D.isTopdown?L.top:window.innerHeight-P-L.bottom,I=[Math.min(A/O,1),Math.min(N/O,1),Math.min(_/z*.9)],j=Math.max.apply(Math,I),U=T.style;U.display="block",j==I[0]?(U.left=L.right+1+"px",U.right="",U.maxWidth=O*j+"px",U.top=L.top+"px",U.bottom="",U.maxHeight=Math.min(window.innerHeight-P-L.top,z)+"px"):j==I[1]?(U.right=window.innerWidth-L.left+"px",U.left="",U.maxWidth=O*j+"px",U.top=L.top+"px",U.bottom="",U.maxHeight=Math.min(window.innerHeight-P-L.top,z)+"px"):j==I[2]&&(U.left=window.innerWidth-L.left+"px",U.maxWidth=Math.min(O,window.innerWidth)+"px",D.isTopdown?(U.top=L.bottom+"px",U.left=L.left+"px",U.right="",U.bottom="",U.maxHeight=Math.min(window.innerHeight-P-L.bottom,z)+"px"):(U.top=D.container.offsetTop-T.offsetHeight+"px",U.left=L.left+"px",U.right="",U.bottom="",U.maxHeight=Math.min(D.container.offsetTop,z)+"px"))},$.prototype.hideDocTooltip=function(){if(this.tooltipTimer.cancel(),!!this.tooltipNode){var S=this.tooltipNode;!this.editor.isFocused()&&document.activeElement==S&&this.editor.focus(),this.tooltipNode=null,S.parentNode&&S.parentNode.removeChild(S)}},$.prototype.onTooltipClick=function(S){for(var k=S.target;k&&k!=this.tooltipNode;){if(k.nodeName=="A"&&k.href){k.rel="noreferrer",k.target="_blank";break}k=k.parentNode}},$.prototype.destroy=function(){if(this.detach(),this.popup){this.popup.destroy();var S=this.popup.container;S&&S.parentNode&&S.parentNode.removeChild(S)}this.editor&&this.editor.completer==this&&(this.editor.off("destroy",m),this.editor.completer=null),this.inlineRenderer=this.popup=this.editor=null},$.for=function(S){return S.completer instanceof $||(S.completer&&(S.completer.destroy(),S.completer=null),u.get("sharedPopups")?($.$sharedInstance||($.$sharedInstance=new $),S.completer=$.$sharedInstance):(S.completer=new $,S.once("destroy",m))),S.completer},$}();w.prototype.commands={Up:function($){$.completer.goTo("up")},Down:function($){$.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function($){$.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function($){$.completer.goTo("end")},Esc:function($){$.completer.detach()},Return:function($){return $.completer.insertMatch()},"Shift-Return":function($){$.completer.insertMatch(null,{deleteSuffix:!0})},Tab:function($){var S=$.completer.insertMatch();if(S||$.tabstopManager)return S;$.completer.goTo("down")},Backspace:function($){$.execCommand("backspace");var S=g.getCompletionPrefix($);!S&&$.completer&&$.completer.detach()},PageUp:function($){$.completer.popup.gotoPageUp()},PageDown:function($){$.completer.popup.gotoPageDown()}},w.startCommand={name:"startAutocomplete",exec:function($,S){var k=w.for($);k.autoInsert=!1,k.autoSelect=!0,k.autoShown=!1,k.showPopup($,S),k.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"};var x=function(){function $(S){this.initialPosition=S,this.active=!0}return $.prototype.insertByIndex=function(S,k,T){return!this.completions||!this.completions.filtered?!1:this.insertMatch(S,this.completions.filtered[k],T)},$.prototype.insertMatch=function(S,k,T){if(!k)return!1;if(S.startOperation({command:{name:"insertMatch"}}),k.completer&&k.completer.insertMatch)k.completer.insertMatch(S,k);else{if(!this.completions)return!1;var D=this.completions.filterText.length,L=0;if(k.range&&k.range.start.row===k.range.end.row&&(D-=this.initialPosition.prefix.length,D+=this.initialPosition.pos.column-k.range.start.column,L+=k.range.end.column-this.initialPosition.pos.column),D||L){var O;S.selection.getAllRanges?O=S.selection.getAllRanges():O=[S.getSelectionRange()];for(var z=0,P;P=O[z];z++)P.start.column-=D,P.end.column+=L,S.session.remove(P)}k.snippet?f.insertSnippet(S,k.snippet):this.$insertString(S,k),k.completer&&k.completer.onInsert&&typeof k.completer.onInsert=="function"&&k.completer.onInsert(S,k),k.command&&k.command==="startAutocomplete"&&S.execCommand(k.command)}return S.endOperation(),!0},$.prototype.$insertString=function(S,k){var T=k.value||k;S.execCommand("insertstring",T)},$.prototype.gatherCompletions=function(S,k){var T=S.getSession(),D=S.getCursorPosition(),L=g.getCompletionPrefix(S),O=[];this.completers=S.completers;var z=S.completers.length;return S.completers.forEach(function(P,N){P.getCompletions(S,T,D,L,function(A,_){P.hideInlinePreview&&(_=_.map(function(I){return Object.assign(I,{hideInlinePreview:P.hideInlinePreview})})),!A&&_&&(O=O.concat(_)),k(null,{prefix:g.getCompletionPrefix(S),matches:O,finished:--z===0})})}),!0},$.prototype.provideCompletions=function(S,k,T){var D=(function(P){var N=P.prefix,A=P.matches;this.completions=new M(A),k.exactMatch&&(this.completions.exactMatch=!0),k.ignoreCaption&&(this.completions.ignoreCaption=!0),this.completions.setFilter(N),(P.finished||this.completions.filtered.length)&&T(null,this.completions,P.finished)}).bind(this),L=!0,O=null;if(this.gatherCompletions(S,(function(P,N){if(this.active){P&&(T(P,[],!0),this.detach());var A=N.prefix;if(A.indexOf(N.prefix)===0){if(L){O=N;return}D(N)}}}).bind(this)),L=!1,O){var z=O;O=null,D(z)}},$.prototype.detach=function(){this.active=!1,this.completers&&this.completers.forEach(function(S){typeof S.cancel=="function"&&S.cancel()})},$}(),M=function(){function $(S,k){this.all=S,this.filtered=S,this.filterText=k||"",this.exactMatch=!1,this.ignoreCaption=!1}return $.prototype.setFilter=function(S){if(S.length>this.filterText&&S.lastIndexOf(this.filterText,0)===0)var k=this.filtered;else var k=this.all;this.filterText=S,k=this.filterCompletions(k,this.filterText),k=k.sort(function(D,L){return L.exactMatch-D.exactMatch||L.$score-D.$score||(D.caption||D.value).localeCompare(L.caption||L.value)});var T=null;k=k.filter(function(D){var L=D.snippet||D.caption||D.value;return L===T?!1:(T=L,!0)}),this.filtered=k},$.prototype.filterCompletions=function(S,k){var T=[],D=k.toUpperCase(),L=k.toLowerCase();e:for(var O=0,z;z=S[O];O++){if(z.skipFilter){z.$score=z.score,T.push(z);continue}var P=!this.ignoreCaption&&z.caption||z.value||z.snippet;if(P){var N=-1,A=0,_=0,I,j;if(this.exactMatch){if(k!==P.substr(0,k.length))continue e}else{var U=P.toLowerCase().indexOf(L);if(U>-1)_=U;else for(var K=0;K<k.length;K++){var Z=P.indexOf(L[K],N+1),J=P.indexOf(D[K],N+1);if(I=Z>=0&&(J<0||Z<J)?Z:J,I<0)continue e;j=I-N-1,j>0&&(N===-1&&(_+=10),_+=j,A|=1<<K),N=I}}z.matchMask=A,z.exactMatch=_?0:1,z.$score=(z.score||0)-_,T.push(z)}}return T},$}();r.Autocomplete=w,r.CompletionProvider=x,r.FilteredList=M}),ace.define("ace/marker_group",["require","exports","module"],function(t,r,l){var d=function(){function h(b,p){p&&(this.markerType=p.markerType),this.markers=[],this.session=b,b.addDynamicMarker(this)}return h.prototype.getMarkerAtPosition=function(b){return this.markers.find(function(p){return p.range.contains(b.row,b.column)})},h.prototype.markersComparator=function(b,p){return b.range.start.row-p.range.start.row},h.prototype.setMarkers=function(b){this.markers=b.sort(this.markersComparator).slice(0,this.MAX_MARKERS),this.session._signal("changeBackMarker")},h.prototype.update=function(b,p,g,o){if(!(!this.markers||!this.markers.length))for(var c=o.firstRow,f=o.lastRow,u,i=0,a=0,m=0;m<this.markers.length;m++){var w=this.markers[m];if(!(w.range.end.row<c)&&!(w.range.start.row>f)&&(w.range.start.row===a?i++:(a=w.range.start.row,i=0),!(i>200))){var x=w.range.clipRows(c,f);if(!(x.start.row===x.end.row&&x.start.column===x.end.column)){var M=x.toScreenRange(g);if(M.isEmpty()){u=g.getNextFoldLine(x.end.row,u),u&&u.end.row>x.end.row&&(c=u.end.row);continue}this.markerType==="fullLine"?p.drawFullLineMarker(b,M,w.className,o):M.isMultiLine()?this.markerType==="line"?p.drawMultiLineMarker(b,M,w.className,o):p.drawTextMarker(b,M,w.className,o):p.drawSingleLineMarker(b,M,w.className+" ace_br15",o)}}}},h}();d.prototype.MAX_MARKERS=1e4,r.MarkerGroup=d}),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],function(t,r,l){function d(g,o){var c=g.getTextRange(b.fromPoints({row:0,column:0},o));return c.split(p).length-1}function h(g,o){var c=d(g,o),f=g.getValue().split(p),u=Object.create(null),i=f[c];return f.forEach(function(a,m){if(!(!a||a===i)){var w=Math.abs(c-m),x=f.length-w;u[a]?u[a]=Math.max(x,u[a]):u[a]=x}}),u}var b=t("../range").Range,p=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;r.getCompletions=function(g,o,c,f,u){var i=h(o,c),a=Object.keys(i);u(null,a.map(function(m){return{caption:m,value:m,score:i[m],meta:"local"}}))}}),ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/lib/lang","ace/autocomplete/util","ace/marker_group","ace/autocomplete/text_completer","ace/editor","ace/config"],function(t,r,l){var d=t("../snippets").snippetManager,h=t("../autocomplete").Autocomplete,b=t("../config"),p=t("../lib/lang"),g=t("../autocomplete/util"),o=t("../marker_group").MarkerGroup,c=t("../autocomplete/text_completer"),f={getCompletions:function(L,O,z,P,N){if(O.$mode.completer)return O.$mode.completer.getCompletions(L,O,z,P,N);var A=L.session.getState(z.row),_=O.$mode.getCompletions(A,O,z,P);_=_.map(function(I){return I.completerId=f.id,I}),N(null,_)},id:"keywordCompleter"},u=function(L){var O={};return L.replace(/\${(\d+)(:(.*?))?}/g,function(z,P,N,A){return O[P]=A||""}).replace(/\$(\d+?)/g,function(z,P){return O[P]})},i={getCompletions:function(L,O,z,P,N){var A=[],_=O.getTokenAt(z.row,z.column);_&&_.type.match(/(tag-name|tag-open|tag-whitespace|attribute-name|attribute-value)\.xml$/)?A.push("html-tag"):A=d.getActiveScopes(L);var I=d.snippetMap,j=[];A.forEach(function(U){for(var K=I[U]||[],Z=K.length;Z--;){var J=K[Z],ae=J.name||J.tabTrigger;ae&&j.push({caption:ae,snippet:J.content,meta:J.tabTrigger&&!J.name?J.tabTrigger+"⇥ ":"snippet",completerId:i.id})}},this),N(null,j)},getDocTooltip:function(L){L.snippet&&!L.docHTML&&(L.docHTML=["<b>",p.escapeHTML(L.caption),"</b>","<hr></hr>",p.escapeHTML(u(L.snippet))].join(""))},id:"snippetCompleter"},a=[i,c,f];r.setCompleters=function(L){a.length=0,L&&a.push.apply(a,L)},r.addCompleter=function(L){a.push(L)},r.textCompleter=c,r.keyWordCompleter=f,r.snippetCompleter=i;var m={name:"expandSnippet",exec:function(L){return d.expandWithTab(L)},bindKey:"Tab"},w=function(L,O){x(O.session.$mode)},x=function(L){typeof L=="string"&&(L=b.$modes[L]),L&&(d.files||(d.files={}),M(L.$id,L.snippetFileId),L.modes&&L.modes.forEach(x))},M=function(L,O){!O||!L||d.files[L]||(d.files[L]={},b.loadModule(O,function(z){z&&(d.files[L]=z,!z.snippets&&z.snippetText&&(z.snippets=d.parseSnippetFile(z.snippetText)),d.register(z.snippets||[],z.scope),z.includeScopes&&(d.snippetMap[z.scope].includeScopes=z.includeScopes,z.includeScopes.forEach(function(P){x("ace/mode/"+P)})))}))},$=function(L){var O=L.editor,z=O.completer&&O.completer.activated;if(L.command.name==="backspace")z&&!g.getCompletionPrefix(O)&&O.completer.detach();else if(L.command.name==="insertstring"&&!z){S=L;var P=L.editor.$liveAutocompletionDelay;P?k.delay(P):T(L)}},S,k=p.delayedCall(function(){T(S)},0),T=function(L){var O=L.editor,z=g.getCompletionPrefix(O),P=L.args,N=g.triggerAutocomplete(O,P);if(z&&z.length>=O.$liveAutocompletionThreshold||N){var A=h.for(O);A.autoShown=!0,A.showPopup(O)}},D=t("../editor").Editor;t("../config").defineOptions(D.prototype,"editor",{enableBasicAutocompletion:{set:function(L){L?(h.for(this),this.completers||(this.completers=Array.isArray(L)?L:a),this.commands.addCommand(h.startCommand)):this.commands.removeCommand(h.startCommand)},value:!1},enableLiveAutocompletion:{set:function(L){L?(this.completers||(this.completers=Array.isArray(L)?L:a),this.commands.on("afterExec",$)):this.commands.off("afterExec",$)},value:!1},liveAutocompletionDelay:{initialValue:0},liveAutocompletionThreshold:{initialValue:0},enableSnippets:{set:function(L){L?(this.commands.addCommand(m),this.on("changeMode",w),w(null,this)):(this.commands.removeCommand(m),this.off("changeMode",w))},value:!1}}),r.MarkerGroup=o}),function(){ace.require(["ace/ext/language_tools"],function(t){n&&(n.exports=t)})}()}(Fg)),Fg.exports}LS();var Bg={exports:{}},jg;function OS(){return jg||(jg=1,function(n,e){ace.define("ace/ext/searchbox-css",["require","exports","module"],function(t,r,l){l.exports=`
|
|
1236
|
+
|
|
1237
|
+
/* ------------------------------------------------------------------------------------------
|
|
1238
|
+
* Editor Search Form
|
|
1239
|
+
* --------------------------------------------------------------------------------------- */
|
|
1240
|
+
.ace_search {
|
|
1241
|
+
background-color: #ddd;
|
|
1242
|
+
color: #666;
|
|
1243
|
+
border: 1px solid #cbcbcb;
|
|
1244
|
+
border-top: 0 none;
|
|
1245
|
+
overflow: hidden;
|
|
1246
|
+
margin: 0;
|
|
1247
|
+
padding: 4px 6px 0 4px;
|
|
1248
|
+
position: absolute;
|
|
1249
|
+
top: 0;
|
|
1250
|
+
z-index: 99;
|
|
1251
|
+
white-space: normal;
|
|
1252
|
+
}
|
|
1253
|
+
.ace_search.left {
|
|
1254
|
+
border-left: 0 none;
|
|
1255
|
+
border-radius: 0px 0px 5px 0px;
|
|
1256
|
+
left: 0;
|
|
1257
|
+
}
|
|
1258
|
+
.ace_search.right {
|
|
1259
|
+
border-radius: 0px 0px 0px 5px;
|
|
1260
|
+
border-right: 0 none;
|
|
1261
|
+
right: 0;
|
|
1262
|
+
}
|
|
1263
|
+
|
|
1264
|
+
.ace_search_form, .ace_replace_form {
|
|
1265
|
+
margin: 0 20px 4px 0;
|
|
1266
|
+
overflow: hidden;
|
|
1267
|
+
line-height: 1.9;
|
|
1268
|
+
}
|
|
1269
|
+
.ace_replace_form {
|
|
1270
|
+
margin-right: 0;
|
|
1271
|
+
}
|
|
1272
|
+
.ace_search_form.ace_nomatch {
|
|
1273
|
+
outline: 1px solid red;
|
|
1274
|
+
}
|
|
1275
|
+
|
|
1276
|
+
.ace_search_field {
|
|
1277
|
+
border-radius: 3px 0 0 3px;
|
|
1278
|
+
background-color: white;
|
|
1279
|
+
color: black;
|
|
1280
|
+
border: 1px solid #cbcbcb;
|
|
1281
|
+
border-right: 0 none;
|
|
1282
|
+
outline: 0;
|
|
1283
|
+
padding: 0;
|
|
1284
|
+
font-size: inherit;
|
|
1285
|
+
margin: 0;
|
|
1286
|
+
line-height: inherit;
|
|
1287
|
+
padding: 0 6px;
|
|
1288
|
+
min-width: 17em;
|
|
1289
|
+
vertical-align: top;
|
|
1290
|
+
min-height: 1.8em;
|
|
1291
|
+
box-sizing: content-box;
|
|
1292
|
+
}
|
|
1293
|
+
.ace_searchbtn {
|
|
1294
|
+
border: 1px solid #cbcbcb;
|
|
1295
|
+
line-height: inherit;
|
|
1296
|
+
display: inline-block;
|
|
1297
|
+
padding: 0 6px;
|
|
1298
|
+
background: #fff;
|
|
1299
|
+
border-right: 0 none;
|
|
1300
|
+
border-left: 1px solid #dcdcdc;
|
|
1301
|
+
cursor: pointer;
|
|
1302
|
+
margin: 0;
|
|
1303
|
+
position: relative;
|
|
1304
|
+
color: #666;
|
|
1305
|
+
}
|
|
1306
|
+
.ace_searchbtn:last-child {
|
|
1307
|
+
border-radius: 0 3px 3px 0;
|
|
1308
|
+
border-right: 1px solid #cbcbcb;
|
|
1309
|
+
}
|
|
1310
|
+
.ace_searchbtn:disabled {
|
|
1311
|
+
background: none;
|
|
1312
|
+
cursor: default;
|
|
1313
|
+
}
|
|
1314
|
+
.ace_searchbtn:hover {
|
|
1315
|
+
background-color: #eef1f6;
|
|
1316
|
+
}
|
|
1317
|
+
.ace_searchbtn.prev, .ace_searchbtn.next {
|
|
1318
|
+
padding: 0px 0.7em
|
|
1319
|
+
}
|
|
1320
|
+
.ace_searchbtn.prev:after, .ace_searchbtn.next:after {
|
|
1321
|
+
content: "";
|
|
1322
|
+
border: solid 2px #888;
|
|
1323
|
+
width: 0.5em;
|
|
1324
|
+
height: 0.5em;
|
|
1325
|
+
border-width: 2px 0 0 2px;
|
|
1326
|
+
display:inline-block;
|
|
1327
|
+
transform: rotate(-45deg);
|
|
1328
|
+
}
|
|
1329
|
+
.ace_searchbtn.next:after {
|
|
1330
|
+
border-width: 0 2px 2px 0 ;
|
|
1331
|
+
}
|
|
1332
|
+
.ace_searchbtn_close {
|
|
1333
|
+
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAcCAYAAABRVo5BAAAAZ0lEQVR42u2SUQrAMAhDvazn8OjZBilCkYVVxiis8H4CT0VrAJb4WHT3C5xU2a2IQZXJjiQIRMdkEoJ5Q2yMqpfDIo+XY4k6h+YXOyKqTIj5REaxloNAd0xiKmAtsTHqW8sR2W5f7gCu5nWFUpVjZwAAAABJRU5ErkJggg==) no-repeat 50% 0;
|
|
1334
|
+
border-radius: 50%;
|
|
1335
|
+
border: 0 none;
|
|
1336
|
+
color: #656565;
|
|
1337
|
+
cursor: pointer;
|
|
1338
|
+
font: 16px/16px Arial;
|
|
1339
|
+
padding: 0;
|
|
1340
|
+
height: 14px;
|
|
1341
|
+
width: 14px;
|
|
1342
|
+
top: 9px;
|
|
1343
|
+
right: 7px;
|
|
1344
|
+
position: absolute;
|
|
1345
|
+
}
|
|
1346
|
+
.ace_searchbtn_close:hover {
|
|
1347
|
+
background-color: #656565;
|
|
1348
|
+
background-position: 50% 100%;
|
|
1349
|
+
color: white;
|
|
1350
|
+
}
|
|
1351
|
+
|
|
1352
|
+
.ace_button {
|
|
1353
|
+
margin-left: 2px;
|
|
1354
|
+
cursor: pointer;
|
|
1355
|
+
-webkit-user-select: none;
|
|
1356
|
+
-moz-user-select: none;
|
|
1357
|
+
-o-user-select: none;
|
|
1358
|
+
-ms-user-select: none;
|
|
1359
|
+
user-select: none;
|
|
1360
|
+
overflow: hidden;
|
|
1361
|
+
opacity: 0.7;
|
|
1362
|
+
border: 1px solid rgba(100,100,100,0.23);
|
|
1363
|
+
padding: 1px;
|
|
1364
|
+
box-sizing: border-box!important;
|
|
1365
|
+
color: black;
|
|
1366
|
+
}
|
|
1367
|
+
|
|
1368
|
+
.ace_button:hover {
|
|
1369
|
+
background-color: #eee;
|
|
1370
|
+
opacity:1;
|
|
1371
|
+
}
|
|
1372
|
+
.ace_button:active {
|
|
1373
|
+
background-color: #ddd;
|
|
1374
|
+
}
|
|
1375
|
+
|
|
1376
|
+
.ace_button.checked {
|
|
1377
|
+
border-color: #3399ff;
|
|
1378
|
+
opacity:1;
|
|
1379
|
+
}
|
|
1380
|
+
|
|
1381
|
+
.ace_search_options{
|
|
1382
|
+
margin-bottom: 3px;
|
|
1383
|
+
text-align: right;
|
|
1384
|
+
-webkit-user-select: none;
|
|
1385
|
+
-moz-user-select: none;
|
|
1386
|
+
-o-user-select: none;
|
|
1387
|
+
-ms-user-select: none;
|
|
1388
|
+
user-select: none;
|
|
1389
|
+
clear: both;
|
|
1390
|
+
}
|
|
1391
|
+
|
|
1392
|
+
.ace_search_counter {
|
|
1393
|
+
float: left;
|
|
1394
|
+
font-family: arial;
|
|
1395
|
+
padding: 0 8px;
|
|
1396
|
+
}`}),ace.define("ace/ext/searchbox",["require","exports","module","ace/ext/searchbox","ace/ext/searchbox","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/ext/searchbox-css","ace/keyboard/hash_handler","ace/lib/keys","ace/config"],function(t,r,l){var d=t("../lib/dom"),h=t("../lib/lang"),b=t("../lib/event"),p=t("./searchbox-css"),g=t("../keyboard/hash_handler").HashHandler,o=t("../lib/keys"),c=t("../config").nls,f=999;d.importCssString(p,"ace_searchbox",!1);var u=function(){function m(w,x,M){this.activeInput,this.element=d.buildDom(["div",{class:"ace_search right"},["span",{action:"hide",class:"ace_searchbtn_close"}],["div",{class:"ace_search_form"},["input",{class:"ace_search_field",placeholder:c("search-box.find.placeholder","Search for"),spellcheck:"false"}],["span",{action:"findPrev",class:"ace_searchbtn prev"},""],["span",{action:"findNext",class:"ace_searchbtn next"},""],["span",{action:"findAll",class:"ace_searchbtn",title:"Alt-Enter"},c("search-box.find-all.text","All")]],["div",{class:"ace_replace_form"},["input",{class:"ace_search_field",placeholder:c("search-box.replace.placeholder","Replace with"),spellcheck:"false"}],["span",{action:"replaceAndFindNext",class:"ace_searchbtn"},c("search-box.replace-next.text","Replace")],["span",{action:"replaceAll",class:"ace_searchbtn"},c("search-box.replace-all.text","All")]],["div",{class:"ace_search_options"},["span",{action:"toggleReplace",class:"ace_button",title:c("search-box.toggle-replace.title","Toggle Replace mode"),style:"float:left;margin-top:-2px;padding:0 5px;"},"+"],["span",{class:"ace_search_counter"}],["span",{action:"toggleRegexpMode",class:"ace_button",title:c("search-box.toggle-regexp.title","RegExp Search")},".*"],["span",{action:"toggleCaseSensitive",class:"ace_button",title:c("search-box.toggle-case.title","CaseSensitive Search")},"Aa"],["span",{action:"toggleWholeWords",class:"ace_button",title:c("search-box.toggle-whole-word.title","Whole Word Search")},"\\b"],["span",{action:"searchInSelection",class:"ace_button",title:c("search-box.toggle-in-selection.title","Search In Selection")},"S"]]]),this.setSession=this.setSession.bind(this),this.$onEditorInput=this.onEditorInput.bind(this),this.$init(),this.setEditor(w),d.importCssString(p,"ace_searchbox",w.container),b.addListener(this.element,"touchstart",function($){$.stopPropagation()},w)}return m.prototype.setEditor=function(w){w.searchBox=this,w.renderer.scroller.appendChild(this.element),this.editor=w},m.prototype.setSession=function(w){this.searchRange=null,this.$syncOptions(!0)},m.prototype.onEditorInput=function(){this.find(!1,!1,!0)},m.prototype.$initElements=function(w){this.searchBox=w.querySelector(".ace_search_form"),this.replaceBox=w.querySelector(".ace_replace_form"),this.searchOption=w.querySelector("[action=searchInSelection]"),this.replaceOption=w.querySelector("[action=toggleReplace]"),this.regExpOption=w.querySelector("[action=toggleRegexpMode]"),this.caseSensitiveOption=w.querySelector("[action=toggleCaseSensitive]"),this.wholeWordOption=w.querySelector("[action=toggleWholeWords]"),this.searchInput=this.searchBox.querySelector(".ace_search_field"),this.replaceInput=this.replaceBox.querySelector(".ace_search_field"),this.searchCounter=w.querySelector(".ace_search_counter")},m.prototype.$init=function(){var w=this.element;this.$initElements(w);var x=this;b.addListener(w,"mousedown",function(M){setTimeout(function(){x.activeInput.focus()},0),b.stopPropagation(M)}),b.addListener(w,"click",function(M){var $=M.target||M.srcElement,S=$.getAttribute("action");S&&x[S]?x[S]():x.$searchBarKb.commands[S]&&x.$searchBarKb.commands[S].exec(x),b.stopPropagation(M)}),b.addCommandKeyListener(w,function(M,$,S){var k=o.keyCodeToString(S),T=x.$searchBarKb.findKeyCommand($,k);T&&T.exec&&(T.exec(x),b.stopEvent(M))}),this.$onChange=h.delayedCall(function(){x.find(!1,!1)}),b.addListener(this.searchInput,"input",function(){x.$onChange.schedule(20)}),b.addListener(this.searchInput,"focus",function(){x.activeInput=x.searchInput,x.searchInput.value&&x.highlight()}),b.addListener(this.replaceInput,"focus",function(){x.activeInput=x.replaceInput,x.searchInput.value&&x.highlight()})},m.prototype.setSearchRange=function(w){this.searchRange=w,w?this.searchRangeMarker=this.editor.session.addMarker(w,"ace_active-line"):this.searchRangeMarker&&(this.editor.session.removeMarker(this.searchRangeMarker),this.searchRangeMarker=null)},m.prototype.$syncOptions=function(w){d.setCssClass(this.replaceOption,"checked",this.searchRange),d.setCssClass(this.searchOption,"checked",this.searchOption.checked),this.replaceOption.textContent=this.replaceOption.checked?"-":"+",d.setCssClass(this.regExpOption,"checked",this.regExpOption.checked),d.setCssClass(this.wholeWordOption,"checked",this.wholeWordOption.checked),d.setCssClass(this.caseSensitiveOption,"checked",this.caseSensitiveOption.checked);var x=this.editor.getReadOnly();this.replaceOption.style.display=x?"none":"",this.replaceBox.style.display=this.replaceOption.checked&&!x?"":"none",this.find(!1,!1,w)},m.prototype.highlight=function(w){this.editor.session.highlight(w||this.editor.$search.$options.re),this.editor.renderer.updateBackMarkers()},m.prototype.find=function(w,x,M){if(this.editor.session){var $=this.editor.find(this.searchInput.value,{skipCurrent:w,backwards:x,wrap:!0,regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked,preventScroll:M,range:this.searchRange}),S=!$&&this.searchInput.value;d.setCssClass(this.searchBox,"ace_nomatch",S),this.editor._emit("findSearchBox",{match:!S}),this.highlight(),this.updateCounter()}},m.prototype.updateCounter=function(){var w=this.editor,x=w.$search.$options.re,M=x.unicode,$=0,S=0;if(x){var k=this.searchRange?w.session.getTextRange(this.searchRange):w.getValue();w.$search.$isMultilineSearch(w.getLastSearchOptions())&&(k=k.replace(/\r\n|\r|\n/g,`
|
|
1397
|
+
`),w.session.doc.$autoNewLine=`
|
|
1398
|
+
`);var T=w.session.doc.positionToIndex(w.selection.anchor);this.searchRange&&(T-=w.session.doc.positionToIndex(this.searchRange.start));for(var D=x.lastIndex=0,L;(L=x.exec(k))&&($++,D=L.index,D<=T&&S++,!($>f||!L[0]&&(x.lastIndex=D+=h.skipEmptyMatch(k,D,M),D>=k.length))););}this.searchCounter.textContent=c("search-box.search-counter","$0 of $1",[S,$>f?f+"+":$])},m.prototype.findNext=function(){this.find(!0,!1)},m.prototype.findPrev=function(){this.find(!0,!0)},m.prototype.findAll=function(){var w=this.editor.findAll(this.searchInput.value,{regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked}),x=!w&&this.searchInput.value;d.setCssClass(this.searchBox,"ace_nomatch",x),this.editor._emit("findSearchBox",{match:!x}),this.highlight(),this.hide()},m.prototype.replace=function(){this.editor.getReadOnly()||this.editor.replace(this.replaceInput.value)},m.prototype.replaceAndFindNext=function(){this.editor.getReadOnly()||(this.editor.replace(this.replaceInput.value),this.findNext())},m.prototype.replaceAll=function(){this.editor.getReadOnly()||this.editor.replaceAll(this.replaceInput.value)},m.prototype.hide=function(){this.active=!1,this.setSearchRange(null),this.editor.off("changeSession",this.setSession),this.editor.off("input",this.$onEditorInput),this.element.style.display="none",this.editor.keyBinding.removeKeyboardHandler(this.$closeSearchBarKb),this.editor.focus()},m.prototype.show=function(w,x){this.active=!0,this.editor.on("changeSession",this.setSession),this.editor.on("input",this.$onEditorInput),this.element.style.display="",this.replaceOption.checked=x,this.editor.$search.$options.regExp&&(w=h.escapeRegExp(w)),w!=null&&(this.searchInput.value=w),this.searchInput.focus(),this.searchInput.select(),this.editor.keyBinding.addKeyboardHandler(this.$closeSearchBarKb),this.$syncOptions(!0)},m.prototype.isFocused=function(){var w=document.activeElement;return w==this.searchInput||w==this.replaceInput},m}(),i=new g;i.bindKeys({"Ctrl-f|Command-f":function(m){var w=m.isReplace=!m.isReplace;m.replaceBox.style.display=w?"":"none",m.replaceOption.checked=!1,m.$syncOptions(),m.searchInput.focus()},"Ctrl-H|Command-Option-F":function(m){m.editor.getReadOnly()||(m.replaceOption.checked=!0,m.$syncOptions(),m.replaceInput.focus())},"Ctrl-G|Command-G":function(m){m.findNext()},"Ctrl-Shift-G|Command-Shift-G":function(m){m.findPrev()},esc:function(m){setTimeout(function(){m.hide()})},Return:function(m){m.activeInput==m.replaceInput&&m.replace(),m.findNext()},"Shift-Return":function(m){m.activeInput==m.replaceInput&&m.replace(),m.findPrev()},"Alt-Return":function(m){m.activeInput==m.replaceInput&&m.replaceAll(),m.findAll()},Tab:function(m){(m.activeInput==m.replaceInput?m.searchInput:m.replaceInput).focus()}}),i.addCommands([{name:"toggleRegexpMode",bindKey:{win:"Alt-R|Alt-/",mac:"Ctrl-Alt-R|Ctrl-Alt-/"},exec:function(m){m.regExpOption.checked=!m.regExpOption.checked,m.$syncOptions()}},{name:"toggleCaseSensitive",bindKey:{win:"Alt-C|Alt-I",mac:"Ctrl-Alt-R|Ctrl-Alt-I"},exec:function(m){m.caseSensitiveOption.checked=!m.caseSensitiveOption.checked,m.$syncOptions()}},{name:"toggleWholeWords",bindKey:{win:"Alt-B|Alt-W",mac:"Ctrl-Alt-B|Ctrl-Alt-W"},exec:function(m){m.wholeWordOption.checked=!m.wholeWordOption.checked,m.$syncOptions()}},{name:"toggleReplace",exec:function(m){m.replaceOption.checked=!m.replaceOption.checked,m.$syncOptions()}},{name:"searchInSelection",exec:function(m){m.searchOption.checked=!m.searchRange,m.setSearchRange(m.searchOption.checked&&m.editor.getSelectionRange()),m.$syncOptions()}}]);var a=new g([{bindKey:"Esc",name:"closeSearchBar",exec:function(m){m.searchBox.hide()}}]);u.prototype.$searchBarKb=i,u.prototype.$closeSearchBarKb=a,r.SearchBox=u,r.Search=function(m,w){var x=m.searchBox||new u(m),M=m.session.selection.getRange(),$=M.isMultiLine()?"":m.session.getTextRange(M);x.show($,w)}}),function(){ace.require(["ace/ext/searchbox"],function(t){n&&(n.exports=t)})}()}(Bg)),Bg.exports}OS();var IS=Object.defineProperty,NS=(n,e,t)=>e in n?IS(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,cc=(n,e,t)=>NS(n,typeof e!="symbol"?e+"":e,t);function Wg(n,e){return function(){return n.apply(e,arguments)}}const{toString:DS}=Object.prototype,{getPrototypeOf:mh}=Object,{iterator:uc,toStringTag:zg}=Symbol,hc=(n=>e=>{const t=DS.call(e);return n[t]||(n[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),ji=n=>(n=n.toLowerCase(),e=>hc(e)===n),dc=n=>e=>typeof e===n,{isArray:da}=Array,fa=dc("undefined");function nl(n){return n!==null&&!fa(n)&&n.constructor!==null&&!fa(n.constructor)&&Yr(n.constructor.isBuffer)&&n.constructor.isBuffer(n)}const Hg=ji("ArrayBuffer");function FS(n){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(n):e=n&&n.buffer&&Hg(n.buffer),e}const PS=dc("string"),Yr=dc("function"),Ug=dc("number"),rl=n=>n!==null&&typeof n=="object",BS=n=>n===!0||n===!1,fc=n=>{if(hc(n)!=="object")return!1;const e=mh(n);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(zg in n)&&!(uc in n)},jS=n=>{if(!rl(n)||nl(n))return!1;try{return Object.keys(n).length===0&&Object.getPrototypeOf(n)===Object.prototype}catch{return!1}},WS=ji("Date"),zS=ji("File"),HS=ji("Blob"),US=ji("FileList"),qS=n=>rl(n)&&Yr(n.pipe),VS=n=>{let e;return n&&(typeof FormData=="function"&&n instanceof FormData||Yr(n.append)&&((e=hc(n))==="formdata"||e==="object"&&Yr(n.toString)&&n.toString()==="[object FormData]"))},KS=ji("URLSearchParams"),[GS,YS,XS,QS]=["ReadableStream","Request","Response","Headers"].map(ji),ZS=n=>n.trim?n.trim():n.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function il(n,e,{allOwnKeys:t=!1}={}){if(n===null||typeof n>"u")return;let r,l;if(typeof n!="object"&&(n=[n]),da(n))for(r=0,l=n.length;r<l;r++)e.call(null,n[r],r,n);else{if(nl(n))return;const d=t?Object.getOwnPropertyNames(n):Object.keys(n),h=d.length;let b;for(r=0;r<h;r++)b=d[r],e.call(null,n[b],b,n)}}function qg(n,e){if(nl(n))return null;e=e.toLowerCase();const t=Object.keys(n);let r=t.length,l;for(;r-- >0;)if(l=t[r],e===l.toLowerCase())return l;return null}const Cs=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Vg=n=>!fa(n)&&n!==Cs;function vh(){const{caseless:n,skipUndefined:e}=Vg(this)&&this||{},t={},r=(l,d)=>{const h=n&&qg(t,d)||d;fc(t[h])&&fc(l)?t[h]=vh(t[h],l):fc(l)?t[h]=vh({},l):da(l)?t[h]=l.slice():(!e||!fa(l))&&(t[h]=l)};for(let l=0,d=arguments.length;l<d;l++)arguments[l]&&il(arguments[l],r);return t}const JS=(n,e,t,{allOwnKeys:r}={})=>(il(e,(l,d)=>{t&&Yr(l)?n[d]=Wg(l,t):n[d]=l},{allOwnKeys:r}),n),e_=n=>(n.charCodeAt(0)===65279&&(n=n.slice(1)),n),t_=(n,e,t,r)=>{n.prototype=Object.create(e.prototype,r),n.prototype.constructor=n,Object.defineProperty(n,"super",{value:e.prototype}),t&&Object.assign(n.prototype,t)},n_=(n,e,t,r)=>{let l,d,h;const b={};if(e=e||{},n==null)return e;do{for(l=Object.getOwnPropertyNames(n),d=l.length;d-- >0;)h=l[d],(!r||r(h,n,e))&&!b[h]&&(e[h]=n[h],b[h]=!0);n=t!==!1&&mh(n)}while(n&&(!t||t(n,e))&&n!==Object.prototype);return e},r_=(n,e,t)=>{n=String(n),(t===void 0||t>n.length)&&(t=n.length),t-=e.length;const r=n.indexOf(e,t);return r!==-1&&r===t},i_=n=>{if(!n)return null;if(da(n))return n;let e=n.length;if(!Ug(e))return null;const t=new Array(e);for(;e-- >0;)t[e]=n[e];return t},o_=(n=>e=>n&&e instanceof n)(typeof Uint8Array<"u"&&mh(Uint8Array)),s_=(n,e)=>{const t=(n&&n[uc]).call(n);let r;for(;(r=t.next())&&!r.done;){const l=r.value;e.call(n,l[0],l[1])}},a_=(n,e)=>{let t;const r=[];for(;(t=n.exec(e))!==null;)r.push(t);return r},l_=ji("HTMLFormElement"),c_=n=>n.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,r){return t.toUpperCase()+r}),Kg=(({hasOwnProperty:n})=>(e,t)=>n.call(e,t))(Object.prototype),u_=ji("RegExp"),Gg=(n,e)=>{const t=Object.getOwnPropertyDescriptors(n),r={};il(t,(l,d)=>{let h;(h=e(l,d,n))!==!1&&(r[d]=h||l)}),Object.defineProperties(n,r)},h_=n=>{Gg(n,(e,t)=>{if(Yr(n)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const r=n[t];if(Yr(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},d_=(n,e)=>{const t={},r=l=>{l.forEach(d=>{t[d]=!0})};return da(n)?r(n):r(String(n).split(e)),t},f_=()=>{},p_=(n,e)=>n!=null&&Number.isFinite(n=+n)?n:e;function g_(n){return!!(n&&Yr(n.append)&&n[zg]==="FormData"&&n[uc])}const m_=n=>{const e=new Array(10),t=(r,l)=>{if(rl(r)){if(e.indexOf(r)>=0)return;if(nl(r))return r;if(!("toJSON"in r)){e[l]=r;const d=da(r)?[]:{};return il(r,(h,b)=>{const p=t(h,l+1);!fa(p)&&(d[b]=p)}),e[l]=void 0,d}}return r};return t(n,0)},v_=ji("AsyncFunction"),y_=n=>n&&(rl(n)||Yr(n))&&Yr(n.then)&&Yr(n.catch),Yg=((n,e)=>n?setImmediate:e?((t,r)=>(Cs.addEventListener("message",({source:l,data:d})=>{l===Cs&&d===t&&r.length&&r.shift()()},!1),l=>{r.push(l),Cs.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",Yr(Cs.postMessage)),b_=typeof queueMicrotask<"u"?queueMicrotask.bind(Cs):typeof process<"u"&&process.nextTick||Yg,w_=n=>n!=null&&Yr(n[uc]),_e={isArray:da,isArrayBuffer:Hg,isBuffer:nl,isFormData:VS,isArrayBufferView:FS,isString:PS,isNumber:Ug,isBoolean:BS,isObject:rl,isPlainObject:fc,isEmptyObject:jS,isReadableStream:GS,isRequest:YS,isResponse:XS,isHeaders:QS,isUndefined:fa,isDate:WS,isFile:zS,isBlob:HS,isRegExp:u_,isFunction:Yr,isStream:qS,isURLSearchParams:KS,isTypedArray:o_,isFileList:US,forEach:il,merge:vh,extend:JS,trim:ZS,stripBOM:e_,inherits:t_,toFlatObject:n_,kindOf:hc,kindOfTest:ji,endsWith:r_,toArray:i_,forEachEntry:s_,matchAll:a_,isHTMLForm:l_,hasOwnProperty:Kg,hasOwnProp:Kg,reduceDescriptors:Gg,freezeMethods:h_,toObjectSet:d_,toCamelCase:c_,noop:f_,toFiniteNumber:p_,findKey:qg,global:Cs,isContextDefined:Vg,isSpecCompliantForm:g_,toJSONObject:m_,isAsyncFn:v_,isThenable:y_,setImmediate:Yg,asap:b_,isIterable:w_};function St(n,e,t,r,l){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=n,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),r&&(this.request=r),l&&(this.response=l,this.status=l.status?l.status:null)}_e.inherits(St,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:_e.toJSONObject(this.config),code:this.code,status:this.status}}});const Xg=St.prototype,Qg={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(n=>{Qg[n]={value:n}}),Object.defineProperties(St,Qg),Object.defineProperty(Xg,"isAxiosError",{value:!0}),St.from=(n,e,t,r,l,d)=>{const h=Object.create(Xg);_e.toFlatObject(n,h,function(g){return g!==Error.prototype},g=>g!=="isAxiosError");const b=n&&n.message?n.message:"Error",p=e==null&&n?n.code:e;return St.call(h,b,p,t,r,l),n&&h.cause==null&&Object.defineProperty(h,"cause",{value:n,configurable:!0}),h.name=n&&n.name||"Error",d&&Object.assign(h,d),h};const x_=null;function yh(n){return _e.isPlainObject(n)||_e.isArray(n)}function Zg(n){return _e.endsWith(n,"[]")?n.slice(0,-2):n}function Jg(n,e,t){return n?n.concat(e).map(function(r,l){return r=Zg(r),!t&&l?"["+r+"]":r}).join(t?".":""):e}function k_(n){return _e.isArray(n)&&!n.some(yh)}const S_=_e.toFlatObject(_e,{},null,function(n){return/^is[A-Z]/.test(n)});function pc(n,e,t){if(!_e.isObject(n))throw new TypeError("target must be an object");e=e||new FormData,t=_e.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(u,i){return!_e.isUndefined(i[u])});const r=t.metaTokens,l=t.visitor||g,d=t.dots,h=t.indexes,b=(t.Blob||typeof Blob<"u"&&Blob)&&_e.isSpecCompliantForm(e);if(!_e.isFunction(l))throw new TypeError("visitor must be a function");function p(u){if(u===null)return"";if(_e.isDate(u))return u.toISOString();if(_e.isBoolean(u))return u.toString();if(!b&&_e.isBlob(u))throw new St("Blob is not supported. Use a Buffer instead.");return _e.isArrayBuffer(u)||_e.isTypedArray(u)?b&&typeof Blob=="function"?new Blob([u]):Buffer.from(u):u}function g(u,i,a){let m=u;if(u&&!a&&typeof u=="object"){if(_e.endsWith(i,"{}"))i=r?i:i.slice(0,-2),u=JSON.stringify(u);else if(_e.isArray(u)&&k_(u)||(_e.isFileList(u)||_e.endsWith(i,"[]"))&&(m=_e.toArray(u)))return i=Zg(i),m.forEach(function(w,x){!(_e.isUndefined(w)||w===null)&&e.append(h===!0?Jg([i],x,d):h===null?i:i+"[]",p(w))}),!1}return yh(u)?!0:(e.append(Jg(a,i,d),p(u)),!1)}const o=[],c=Object.assign(S_,{defaultVisitor:g,convertValue:p,isVisitable:yh});function f(u,i){if(!_e.isUndefined(u)){if(o.indexOf(u)!==-1)throw Error("Circular reference detected in "+i.join("."));o.push(u),_e.forEach(u,function(a,m){(!(_e.isUndefined(a)||a===null)&&l.call(e,a,_e.isString(m)?m.trim():m,i,c))===!0&&f(a,i?i.concat(m):[m])}),o.pop()}}if(!_e.isObject(n))throw new TypeError("data must be an object");return f(n),e}function em(n){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(n).replace(/[!'()~]|%20|%00/g,function(t){return e[t]})}function bh(n,e){this._pairs=[],n&&pc(n,this,e)}const tm=bh.prototype;tm.append=function(n,e){this._pairs.push([n,e])},tm.toString=function(n){const e=n?function(t){return n.call(this,t,em)}:em;return this._pairs.map(function(t){return e(t[0])+"="+e(t[1])},"").join("&")};function __(n){return encodeURIComponent(n).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function nm(n,e,t){if(!e)return n;const r=t&&t.encode||__;_e.isFunction(t)&&(t={serialize:t});const l=t&&t.serialize;let d;if(l?d=l(e,t):d=_e.isURLSearchParams(e)?e.toString():new bh(e,t).toString(r),d){const h=n.indexOf("#");h!==-1&&(n=n.slice(0,h)),n+=(n.indexOf("?")===-1?"?":"&")+d}return n}class rm{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){_e.forEach(this.handlers,function(t){t!==null&&e(t)})}}const im={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},C_=typeof URLSearchParams<"u"?URLSearchParams:bh,$_=typeof FormData<"u"?FormData:null,A_=typeof Blob<"u"?Blob:null,E_={isBrowser:!0,classes:{URLSearchParams:C_,FormData:$_,Blob:A_},protocols:["http","https","file","blob","url","data"]},wh=typeof window<"u"&&typeof document<"u",xh=typeof navigator=="object"&&navigator||void 0,T_=wh&&(!xh||["ReactNative","NativeScript","NS"].indexOf(xh.product)<0),R_=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",M_=wh&&window.location.href||"http://localhost",L_=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:wh,hasStandardBrowserEnv:T_,hasStandardBrowserWebWorkerEnv:R_,navigator:xh,origin:M_},Symbol.toStringTag,{value:"Module"})),kr={...L_,...E_};function O_(n,e){return pc(n,new kr.classes.URLSearchParams,{visitor:function(t,r,l,d){return kr.isNode&&_e.isBuffer(t)?(this.append(r,t.toString("base64")),!1):d.defaultVisitor.apply(this,arguments)},...e})}function I_(n){return _e.matchAll(/\w+|\[(\w*)]/g,n).map(e=>e[0]==="[]"?"":e[1]||e[0])}function N_(n){const e={},t=Object.keys(n);let r;const l=t.length;let d;for(r=0;r<l;r++)d=t[r],e[d]=n[d];return e}function om(n){function e(t,r,l,d){let h=t[d++];if(h==="__proto__")return!0;const b=Number.isFinite(+h),p=d>=t.length;return h=!h&&_e.isArray(l)?l.length:h,p?(_e.hasOwnProp(l,h)?l[h]=[l[h],r]:l[h]=r,!b):((!l[h]||!_e.isObject(l[h]))&&(l[h]=[]),e(t,r,l[h],d)&&_e.isArray(l[h])&&(l[h]=N_(l[h])),!b)}if(_e.isFormData(n)&&_e.isFunction(n.entries)){const t={};return _e.forEachEntry(n,(r,l)=>{e(I_(r),l,t,0)}),t}return null}function D_(n,e,t){if(_e.isString(n))try{return(e||JSON.parse)(n),_e.trim(n)}catch(r){if(r.name!=="SyntaxError")throw r}return(t||JSON.stringify)(n)}const ol={transitional:im,adapter:["xhr","http","fetch"],transformRequest:[function(n,e){const t=e.getContentType()||"",r=t.indexOf("application/json")>-1,l=_e.isObject(n);if(l&&_e.isHTMLForm(n)&&(n=new FormData(n)),_e.isFormData(n))return r?JSON.stringify(om(n)):n;if(_e.isArrayBuffer(n)||_e.isBuffer(n)||_e.isStream(n)||_e.isFile(n)||_e.isBlob(n)||_e.isReadableStream(n))return n;if(_e.isArrayBufferView(n))return n.buffer;if(_e.isURLSearchParams(n))return e.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),n.toString();let d;if(l){if(t.indexOf("application/x-www-form-urlencoded")>-1)return O_(n,this.formSerializer).toString();if((d=_e.isFileList(n))||t.indexOf("multipart/form-data")>-1){const h=this.env&&this.env.FormData;return pc(d?{"files[]":n}:n,h&&new h,this.formSerializer)}}return l||r?(e.setContentType("application/json",!1),D_(n)):n}],transformResponse:[function(n){const e=this.transitional||ol.transitional,t=e&&e.forcedJSONParsing,r=this.responseType==="json";if(_e.isResponse(n)||_e.isReadableStream(n))return n;if(n&&_e.isString(n)&&(t&&!this.responseType||r)){const l=!(e&&e.silentJSONParsing)&&r;try{return JSON.parse(n,this.parseReviver)}catch(d){if(l)throw d.name==="SyntaxError"?St.from(d,St.ERR_BAD_RESPONSE,this,null,this.response):d}}return n}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:kr.classes.FormData,Blob:kr.classes.Blob},validateStatus:function(n){return n>=200&&n<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};_e.forEach(["delete","get","head","post","put","patch"],n=>{ol.headers[n]={}});const F_=_e.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),P_=n=>{const e={};let t,r,l;return n&&n.split(`
|
|
1399
|
+
`).forEach(function(d){l=d.indexOf(":"),t=d.substring(0,l).trim().toLowerCase(),r=d.substring(l+1).trim(),!(!t||e[t]&&F_[t])&&(t==="set-cookie"?e[t]?e[t].push(r):e[t]=[r]:e[t]=e[t]?e[t]+", "+r:r)}),e},sm=Symbol("internals");function sl(n){return n&&String(n).trim().toLowerCase()}function gc(n){return n===!1||n==null?n:_e.isArray(n)?n.map(gc):String(n)}function B_(n){const e=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=t.exec(n);)e[r[1]]=r[2];return e}const j_=n=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(n.trim());function kh(n,e,t,r,l){if(_e.isFunction(r))return r.call(this,e,t);if(l&&(e=t),!!_e.isString(e)){if(_e.isString(r))return e.indexOf(r)!==-1;if(_e.isRegExp(r))return r.test(e)}}function W_(n){return n.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r)}function z_(n,e){const t=_e.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(n,r+t,{value:function(l,d,h){return this[r].call(this,e,l,d,h)},configurable:!0})})}let Xr=class{constructor(n){n&&this.set(n)}set(n,e,t){const r=this;function l(h,b,p){const g=sl(b);if(!g)throw new Error("header name must be a non-empty string");const o=_e.findKey(r,g);(!o||r[o]===void 0||p===!0||p===void 0&&r[o]!==!1)&&(r[o||b]=gc(h))}const d=(h,b)=>_e.forEach(h,(p,g)=>l(p,g,b));if(_e.isPlainObject(n)||n instanceof this.constructor)d(n,e);else if(_e.isString(n)&&(n=n.trim())&&!j_(n))d(P_(n),e);else if(_e.isObject(n)&&_e.isIterable(n)){let h={},b,p;for(const g of n){if(!_e.isArray(g))throw TypeError("Object iterator must return a key-value pair");h[p=g[0]]=(b=h[p])?_e.isArray(b)?[...b,g[1]]:[b,g[1]]:g[1]}d(h,e)}else n!=null&&l(e,n,t);return this}get(n,e){if(n=sl(n),n){const t=_e.findKey(this,n);if(t){const r=this[t];if(!e)return r;if(e===!0)return B_(r);if(_e.isFunction(e))return e.call(this,r,t);if(_e.isRegExp(e))return e.exec(r);throw new TypeError("parser must be boolean|regexp|function")}}}has(n,e){if(n=sl(n),n){const t=_e.findKey(this,n);return!!(t&&this[t]!==void 0&&(!e||kh(this,this[t],t,e)))}return!1}delete(n,e){const t=this;let r=!1;function l(d){if(d=sl(d),d){const h=_e.findKey(t,d);h&&(!e||kh(t,t[h],h,e))&&(delete t[h],r=!0)}}return _e.isArray(n)?n.forEach(l):l(n),r}clear(n){const e=Object.keys(this);let t=e.length,r=!1;for(;t--;){const l=e[t];(!n||kh(this,this[l],l,n,!0))&&(delete this[l],r=!0)}return r}normalize(n){const e=this,t={};return _e.forEach(this,(r,l)=>{const d=_e.findKey(t,l);if(d){e[d]=gc(r),delete e[l];return}const h=n?W_(l):String(l).trim();h!==l&&delete e[l],e[h]=gc(r),t[h]=!0}),this}concat(...n){return this.constructor.concat(this,...n)}toJSON(n){const e=Object.create(null);return _e.forEach(this,(t,r)=>{t!=null&&t!==!1&&(e[r]=n&&_e.isArray(t)?t.join(", "):t)}),e}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([n,e])=>n+": "+e).join(`
|
|
1400
|
+
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(n){return n instanceof this?n:new this(n)}static concat(n,...e){const t=new this(n);return e.forEach(r=>t.set(r)),t}static accessor(n){const e=(this[sm]=this[sm]={accessors:{}}).accessors,t=this.prototype;function r(l){const d=sl(l);e[d]||(z_(t,l),e[d]=!0)}return _e.isArray(n)?n.forEach(r):r(n),this}};Xr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),_e.reduceDescriptors(Xr.prototype,({value:n},e)=>{let t=e[0].toUpperCase()+e.slice(1);return{get:()=>n,set(r){this[t]=r}}}),_e.freezeMethods(Xr);function Sh(n,e){const t=this||ol,r=e||t,l=Xr.from(r.headers);let d=r.data;return _e.forEach(n,function(h){d=h.call(t,d,l.normalize(),e?e.status:void 0)}),l.normalize(),d}function am(n){return!!(n&&n.__CANCEL__)}function pa(n,e,t){St.call(this,n??"canceled",St.ERR_CANCELED,e,t),this.name="CanceledError"}_e.inherits(pa,St,{__CANCEL__:!0});function lm(n,e,t){const r=t.config.validateStatus;!t.status||!r||r(t.status)?n(t):e(new St("Request failed with status code "+t.status,[St.ERR_BAD_REQUEST,St.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function H_(n){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(n);return e&&e[1]||""}function U_(n,e){n=n||10;const t=new Array(n),r=new Array(n);let l=0,d=0,h;return e=e!==void 0?e:1e3,function(b){const p=Date.now(),g=r[d];h||(h=p),t[l]=b,r[l]=p;let o=d,c=0;for(;o!==l;)c+=t[o++],o=o%n;if(l=(l+1)%n,l===d&&(d=(d+1)%n),p-h<e)return;const f=g&&p-g;return f?Math.round(c*1e3/f):void 0}}function q_(n,e){let t=0,r=1e3/e,l,d;const h=(b,p=Date.now())=>{t=p,l=null,d&&(clearTimeout(d),d=null),n(...b)};return[(...b)=>{const p=Date.now(),g=p-t;g>=r?h(b,p):(l=b,d||(d=setTimeout(()=>{d=null,h(l)},r-g)))},()=>l&&h(l)]}const mc=(n,e,t=3)=>{let r=0;const l=U_(50,250);return q_(d=>{const h=d.loaded,b=d.lengthComputable?d.total:void 0,p=h-r,g=l(p),o=h<=b;r=h;const c={loaded:h,total:b,progress:b?h/b:void 0,bytes:p,rate:g||void 0,estimated:g&&b&&o?(b-h)/g:void 0,event:d,lengthComputable:b!=null,[e?"download":"upload"]:!0};n(c)},t)},cm=(n,e)=>{const t=n!=null;return[r=>e[0]({lengthComputable:t,total:n,loaded:r}),e[1]]},um=n=>(...e)=>_e.asap(()=>n(...e)),V_=kr.hasStandardBrowserEnv?((n,e)=>t=>(t=new URL(t,kr.origin),n.protocol===t.protocol&&n.host===t.host&&(e||n.port===t.port)))(new URL(kr.origin),kr.navigator&&/(msie|trident)/i.test(kr.navigator.userAgent)):()=>!0,K_=kr.hasStandardBrowserEnv?{write(n,e,t,r,l,d,h){if(typeof document>"u")return;const b=[`${n}=${encodeURIComponent(e)}`];_e.isNumber(t)&&b.push(`expires=${new Date(t).toUTCString()}`),_e.isString(r)&&b.push(`path=${r}`),_e.isString(l)&&b.push(`domain=${l}`),d===!0&&b.push("secure"),_e.isString(h)&&b.push(`SameSite=${h}`),document.cookie=b.join("; ")},read(n){if(typeof document>"u")return null;const e=document.cookie.match(new RegExp("(?:^|; )"+n+"=([^;]*)"));return e?decodeURIComponent(e[1]):null},remove(n){this.write(n,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function G_(n){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(n)}function Y_(n,e){return e?n.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):n}function hm(n,e,t){let r=!G_(e);return n&&(r||t==!1)?Y_(n,e):e}const dm=n=>n instanceof Xr?{...n}:n;function $s(n,e){e=e||{};const t={};function r(g,o,c,f){return _e.isPlainObject(g)&&_e.isPlainObject(o)?_e.merge.call({caseless:f},g,o):_e.isPlainObject(o)?_e.merge({},o):_e.isArray(o)?o.slice():o}function l(g,o,c,f){if(_e.isUndefined(o)){if(!_e.isUndefined(g))return r(void 0,g,c,f)}else return r(g,o,c,f)}function d(g,o){if(!_e.isUndefined(o))return r(void 0,o)}function h(g,o){if(_e.isUndefined(o)){if(!_e.isUndefined(g))return r(void 0,g)}else return r(void 0,o)}function b(g,o,c){if(c in e)return r(g,o);if(c in n)return r(void 0,g)}const p={url:d,method:d,data:d,baseURL:h,transformRequest:h,transformResponse:h,paramsSerializer:h,timeout:h,timeoutMessage:h,withCredentials:h,withXSRFToken:h,adapter:h,responseType:h,xsrfCookieName:h,xsrfHeaderName:h,onUploadProgress:h,onDownloadProgress:h,decompress:h,maxContentLength:h,maxBodyLength:h,beforeRedirect:h,transport:h,httpAgent:h,httpsAgent:h,cancelToken:h,socketPath:h,responseEncoding:h,validateStatus:b,headers:(g,o,c)=>l(dm(g),dm(o),c,!0)};return _e.forEach(Object.keys({...n,...e}),function(g){const o=p[g]||l,c=o(n[g],e[g],g);_e.isUndefined(c)&&o!==b||(t[g]=c)}),t}const fm=n=>{const e=$s({},n);let{data:t,withXSRFToken:r,xsrfHeaderName:l,xsrfCookieName:d,headers:h,auth:b}=e;if(e.headers=h=Xr.from(h),e.url=nm(hm(e.baseURL,e.url,e.allowAbsoluteUrls),n.params,n.paramsSerializer),b&&h.set("Authorization","Basic "+btoa((b.username||"")+":"+(b.password?unescape(encodeURIComponent(b.password)):""))),_e.isFormData(t)){if(kr.hasStandardBrowserEnv||kr.hasStandardBrowserWebWorkerEnv)h.setContentType(void 0);else if(_e.isFunction(t.getHeaders)){const p=t.getHeaders(),g=["content-type","content-length"];Object.entries(p).forEach(([o,c])=>{g.includes(o.toLowerCase())&&h.set(o,c)})}}if(kr.hasStandardBrowserEnv&&(r&&_e.isFunction(r)&&(r=r(e)),r||r!==!1&&V_(e.url))){const p=l&&d&&K_.read(d);p&&h.set(l,p)}return e},X_=typeof XMLHttpRequest<"u",Q_=X_&&function(n){return new Promise(function(e,t){const r=fm(n);let l=r.data;const d=Xr.from(r.headers).normalize();let{responseType:h,onUploadProgress:b,onDownloadProgress:p}=r,g,o,c,f,u;function i(){f&&f(),u&&u(),r.cancelToken&&r.cancelToken.unsubscribe(g),r.signal&&r.signal.removeEventListener("abort",g)}let a=new XMLHttpRequest;a.open(r.method.toUpperCase(),r.url,!0),a.timeout=r.timeout;function m(){if(!a)return;const x=Xr.from("getAllResponseHeaders"in a&&a.getAllResponseHeaders()),M={data:!h||h==="text"||h==="json"?a.responseText:a.response,status:a.status,statusText:a.statusText,headers:x,config:n,request:a};lm(function($){e($),i()},function($){t($),i()},M),a=null}"onloadend"in a?a.onloadend=m:a.onreadystatechange=function(){!a||a.readyState!==4||a.status===0&&!(a.responseURL&&a.responseURL.indexOf("file:")===0)||setTimeout(m)},a.onabort=function(){a&&(t(new St("Request aborted",St.ECONNABORTED,n,a)),a=null)},a.onerror=function(x){const M=x&&x.message?x.message:"Network Error",$=new St(M,St.ERR_NETWORK,n,a);$.event=x||null,t($),a=null},a.ontimeout=function(){let x=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const M=r.transitional||im;r.timeoutErrorMessage&&(x=r.timeoutErrorMessage),t(new St(x,M.clarifyTimeoutError?St.ETIMEDOUT:St.ECONNABORTED,n,a)),a=null},l===void 0&&d.setContentType(null),"setRequestHeader"in a&&_e.forEach(d.toJSON(),function(x,M){a.setRequestHeader(M,x)}),_e.isUndefined(r.withCredentials)||(a.withCredentials=!!r.withCredentials),h&&h!=="json"&&(a.responseType=r.responseType),p&&([c,u]=mc(p,!0),a.addEventListener("progress",c)),b&&a.upload&&([o,f]=mc(b),a.upload.addEventListener("progress",o),a.upload.addEventListener("loadend",f)),(r.cancelToken||r.signal)&&(g=x=>{a&&(t(!x||x.type?new pa(null,n,a):x),a.abort(),a=null)},r.cancelToken&&r.cancelToken.subscribe(g),r.signal&&(r.signal.aborted?g():r.signal.addEventListener("abort",g)));const w=H_(r.url);if(w&&kr.protocols.indexOf(w)===-1){t(new St("Unsupported protocol "+w+":",St.ERR_BAD_REQUEST,n));return}a.send(l||null)})},Z_=(n,e)=>{const{length:t}=n=n?n.filter(Boolean):[];if(e||t){let r=new AbortController,l;const d=function(g){if(!l){l=!0,b();const o=g instanceof Error?g:this.reason;r.abort(o instanceof St?o:new pa(o instanceof Error?o.message:o))}};let h=e&&setTimeout(()=>{h=null,d(new St(`timeout ${e} of ms exceeded`,St.ETIMEDOUT))},e);const b=()=>{n&&(h&&clearTimeout(h),h=null,n.forEach(g=>{g.unsubscribe?g.unsubscribe(d):g.removeEventListener("abort",d)}),n=null)};n.forEach(g=>g.addEventListener("abort",d));const{signal:p}=r;return p.unsubscribe=()=>_e.asap(b),p}},J_=function*(n,e){let t=n.byteLength;if(t<e){yield n;return}let r=0,l;for(;r<t;)l=r+e,yield n.slice(r,l),r=l},eC=async function*(n,e){for await(const t of tC(n))yield*J_(t,e)},tC=async function*(n){if(n[Symbol.asyncIterator]){yield*n;return}const e=n.getReader();try{for(;;){const{done:t,value:r}=await e.read();if(t)break;yield r}}finally{await e.cancel()}},pm=(n,e,t,r)=>{const l=eC(n,e);let d=0,h,b=p=>{h||(h=!0,r&&r(p))};return new ReadableStream({async pull(p){try{const{done:g,value:o}=await l.next();if(g){b(),p.close();return}let c=o.byteLength;if(t){let f=d+=c;t(f)}p.enqueue(new Uint8Array(o))}catch(g){throw b(g),g}},cancel(p){return b(p),l.return()}},{highWaterMark:2})},gm=64*1024,{isFunction:vc}=_e,nC=(({Request:n,Response:e})=>({Request:n,Response:e}))(_e.global),{ReadableStream:mm,TextEncoder:vm}=_e.global,ym=(n,...e)=>{try{return!!n(...e)}catch{return!1}},rC=n=>{n=_e.merge.call({skipUndefined:!0},nC,n);const{fetch:e,Request:t,Response:r}=n,l=e?vc(e):typeof fetch=="function",d=vc(t),h=vc(r);if(!l)return!1;const b=l&&vc(mm),p=l&&(typeof vm=="function"?(i=>a=>i.encode(a))(new vm):async i=>new Uint8Array(await new t(i).arrayBuffer())),g=d&&b&&ym(()=>{let i=!1;const a=new t(kr.origin,{body:new mm,method:"POST",get duplex(){return i=!0,"half"}}).headers.has("Content-Type");return i&&!a}),o=h&&b&&ym(()=>_e.isReadableStream(new r("").body)),c={stream:o&&(i=>i.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(i=>{!c[i]&&(c[i]=(a,m)=>{let w=a&&a[i];if(w)return w.call(a);throw new St(`Response type '${i}' is not supported`,St.ERR_NOT_SUPPORT,m)})});const f=async i=>{if(i==null)return 0;if(_e.isBlob(i))return i.size;if(_e.isSpecCompliantForm(i))return(await new t(kr.origin,{method:"POST",body:i}).arrayBuffer()).byteLength;if(_e.isArrayBufferView(i)||_e.isArrayBuffer(i))return i.byteLength;if(_e.isURLSearchParams(i)&&(i=i+""),_e.isString(i))return(await p(i)).byteLength},u=async(i,a)=>_e.toFiniteNumber(i.getContentLength())??f(a);return async i=>{let{url:a,method:m,data:w,signal:x,cancelToken:M,timeout:$,onDownloadProgress:S,onUploadProgress:k,responseType:T,headers:D,withCredentials:L="same-origin",fetchOptions:O}=fm(i),z=e||fetch;T=T?(T+"").toLowerCase():"text";let P=Z_([x,M&&M.toAbortSignal()],$),N=null;const A=P&&P.unsubscribe&&(()=>{P.unsubscribe()});let _;try{if(k&&g&&m!=="get"&&m!=="head"&&(_=await u(D,w))!==0){let J=new t(a,{method:"POST",body:w,duplex:"half"}),ae;if(_e.isFormData(w)&&(ae=J.headers.get("content-type"))&&D.setContentType(ae),J.body){const[ne,se]=cm(_,mc(um(k)));w=pm(J.body,gm,ne,se)}}_e.isString(L)||(L=L?"include":"omit");const I=d&&"credentials"in t.prototype,j={...O,signal:P,method:m.toUpperCase(),headers:D.normalize().toJSON(),body:w,duplex:"half",credentials:I?L:void 0};N=d&&new t(a,j);let U=await(d?z(N,O):z(a,j));const K=o&&(T==="stream"||T==="response");if(o&&(S||K&&A)){const J={};["status","statusText","headers"].forEach(ce=>{J[ce]=U[ce]});const ae=_e.toFiniteNumber(U.headers.get("content-length")),[ne,se]=S&&cm(ae,mc(um(S),!0))||[];U=new r(pm(U.body,gm,ne,()=>{se&&se(),A&&A()}),J)}T=T||"text";let Z=await c[_e.findKey(c,T)||"text"](U,i);return!K&&A&&A(),await new Promise((J,ae)=>{lm(J,ae,{data:Z,headers:Xr.from(U.headers),status:U.status,statusText:U.statusText,config:i,request:N})})}catch(I){throw A&&A(),I&&I.name==="TypeError"&&/Load failed|fetch/i.test(I.message)?Object.assign(new St("Network Error",St.ERR_NETWORK,i,N),{cause:I.cause||I}):St.from(I,I&&I.code,i,N)}}},iC=new Map,bm=n=>{let e=n&&n.env||{};const{fetch:t,Request:r,Response:l}=e,d=[r,l,t];let h=d.length,b=h,p,g,o=iC;for(;b--;)p=d[b],g=o.get(p),g===void 0&&o.set(p,g=b?new Map:rC(e)),o=g;return g};bm();const _h={http:x_,xhr:Q_,fetch:{get:bm}};_e.forEach(_h,(n,e)=>{if(n){try{Object.defineProperty(n,"name",{value:e})}catch{}Object.defineProperty(n,"adapterName",{value:e})}});const wm=n=>`- ${n}`,oC=n=>_e.isFunction(n)||n===null||n===!1;function sC(n,e){n=_e.isArray(n)?n:[n];const{length:t}=n;let r,l;const d={};for(let h=0;h<t;h++){r=n[h];let b;if(l=r,!oC(r)&&(l=_h[(b=String(r)).toLowerCase()],l===void 0))throw new St(`Unknown adapter '${b}'`);if(l&&(_e.isFunction(l)||(l=l.get(e))))break;d[b||"#"+h]=l}if(!l){const h=Object.entries(d).map(([p,g])=>`adapter ${p} `+(g===!1?"is not supported by the environment":"is not available in the build"));let b=t?h.length>1?`since :
|
|
1401
|
+
`+h.map(wm).join(`
|
|
1402
|
+
`):" "+wm(h[0]):"as no adapter specified";throw new St("There is no suitable adapter to dispatch the request "+b,"ERR_NOT_SUPPORT")}return l}const xm={getAdapter:sC,adapters:_h};function Ch(n){if(n.cancelToken&&n.cancelToken.throwIfRequested(),n.signal&&n.signal.aborted)throw new pa(null,n)}function km(n){return Ch(n),n.headers=Xr.from(n.headers),n.data=Sh.call(n,n.transformRequest),["post","put","patch"].indexOf(n.method)!==-1&&n.headers.setContentType("application/x-www-form-urlencoded",!1),xm.getAdapter(n.adapter||ol.adapter,n)(n).then(function(e){return Ch(n),e.data=Sh.call(n,n.transformResponse,e),e.headers=Xr.from(e.headers),e},function(e){return am(e)||(Ch(n),e&&e.response&&(e.response.data=Sh.call(n,n.transformResponse,e.response),e.response.headers=Xr.from(e.response.headers))),Promise.reject(e)})}const Sm="1.13.1",yc={};["object","boolean","number","function","string","symbol"].forEach((n,e)=>{yc[n]=function(t){return typeof t===n||"a"+(e<1?"n ":" ")+n}});const _m={};yc.transitional=function(n,e,t){function r(l,d){return"[Axios v"+Sm+"] Transitional option '"+l+"'"+d+(t?". "+t:"")}return(l,d,h)=>{if(n===!1)throw new St(r(d," has been removed"+(e?" in "+e:"")),St.ERR_DEPRECATED);return e&&!_m[d]&&(_m[d]=!0,console.warn(r(d," has been deprecated since v"+e+" and will be removed in the near future"))),n?n(l,d,h):!0}},yc.spelling=function(n){return(e,t)=>(console.warn(`${t} is likely a misspelling of ${n}`),!0)};function aC(n,e,t){if(typeof n!="object")throw new St("options must be an object",St.ERR_BAD_OPTION_VALUE);const r=Object.keys(n);let l=r.length;for(;l-- >0;){const d=r[l],h=e[d];if(h){const b=n[d],p=b===void 0||h(b,d,n);if(p!==!0)throw new St("option "+d+" must be "+p,St.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new St("Unknown option "+d,St.ERR_BAD_OPTION)}}const bc={assertOptions:aC,validators:yc},ao=bc.validators;let As=class{constructor(n){this.defaults=n||{},this.interceptors={request:new rm,response:new rm}}async request(n,e){try{return await this._request(n,e)}catch(t){if(t instanceof Error){let r={};Error.captureStackTrace?Error.captureStackTrace(r):r=new Error;const l=r.stack?r.stack.replace(/^.+\n/,""):"";try{t.stack?l&&!String(t.stack).endsWith(l.replace(/^.+\n.+\n/,""))&&(t.stack+=`
|
|
1403
|
+
`+l):t.stack=l}catch{}}throw t}}_request(n,e){typeof n=="string"?(e=e||{},e.url=n):e=n||{},e=$s(this.defaults,e);const{transitional:t,paramsSerializer:r,headers:l}=e;t!==void 0&&bc.assertOptions(t,{silentJSONParsing:ao.transitional(ao.boolean),forcedJSONParsing:ao.transitional(ao.boolean),clarifyTimeoutError:ao.transitional(ao.boolean)},!1),r!=null&&(_e.isFunction(r)?e.paramsSerializer={serialize:r}:bc.assertOptions(r,{encode:ao.function,serialize:ao.function},!0)),e.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?e.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:e.allowAbsoluteUrls=!0),bc.assertOptions(e,{baseUrl:ao.spelling("baseURL"),withXsrfToken:ao.spelling("withXSRFToken")},!0),e.method=(e.method||this.defaults.method||"get").toLowerCase();let d=l&&_e.merge(l.common,l[e.method]);l&&_e.forEach(["delete","get","head","post","put","patch","common"],u=>{delete l[u]}),e.headers=Xr.concat(d,l);const h=[];let b=!0;this.interceptors.request.forEach(function(u){typeof u.runWhen=="function"&&u.runWhen(e)===!1||(b=b&&u.synchronous,h.unshift(u.fulfilled,u.rejected))});const p=[];this.interceptors.response.forEach(function(u){p.push(u.fulfilled,u.rejected)});let g,o=0,c;if(!b){const u=[km.bind(this),void 0];for(u.unshift(...h),u.push(...p),c=u.length,g=Promise.resolve(e);o<c;)g=g.then(u[o++],u[o++]);return g}c=h.length;let f=e;for(;o<c;){const u=h[o++],i=h[o++];try{f=u(f)}catch(a){i.call(this,a);break}}try{g=km.call(this,f)}catch(u){return Promise.reject(u)}for(o=0,c=p.length;o<c;)g=g.then(p[o++],p[o++]);return g}getUri(n){n=$s(this.defaults,n);const e=hm(n.baseURL,n.url,n.allowAbsoluteUrls);return nm(e,n.params,n.paramsSerializer)}};_e.forEach(["delete","get","head","options"],function(n){As.prototype[n]=function(e,t){return this.request($s(t||{},{method:n,url:e,data:(t||{}).data}))}}),_e.forEach(["post","put","patch"],function(n){function e(t){return function(r,l,d){return this.request($s(d||{},{method:n,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:l}))}}As.prototype[n]=e(),As.prototype[n+"Form"]=e(!0)});let lC=class Ux{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(l){t=l});const r=this;this.promise.then(l=>{if(!r._listeners)return;let d=r._listeners.length;for(;d-- >0;)r._listeners[d](l);r._listeners=null}),this.promise.then=l=>{let d;const h=new Promise(b=>{r.subscribe(b),d=b}).then(l);return h.cancel=function(){r.unsubscribe(d)},h},e(function(l,d,h){r.reason||(r.reason=new pa(l,d,h),t(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=r=>{e.abort(r)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new Ux(function(t){e=t}),cancel:e}}};function cC(n){return function(e){return n.apply(null,e)}}function uC(n){return _e.isObject(n)&&n.isAxiosError===!0}const $h={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries($h).forEach(([n,e])=>{$h[e]=n});function Cm(n){const e=new As(n),t=Wg(As.prototype.request,e);return _e.extend(t,As.prototype,e,{allOwnKeys:!0}),_e.extend(t,e,null,{allOwnKeys:!0}),t.create=function(r){return Cm($s(n,r))},t}const Dn=Cm(ol);Dn.Axios=As,Dn.CanceledError=pa,Dn.CancelToken=lC,Dn.isCancel=am,Dn.VERSION=Sm,Dn.toFormData=pc,Dn.AxiosError=St,Dn.Cancel=Dn.CanceledError,Dn.all=function(n){return Promise.all(n)},Dn.spread=cC,Dn.isAxiosError=uC,Dn.mergeConfig=$s,Dn.AxiosHeaders=Xr,Dn.formToJSON=n=>om(_e.isHTMLForm(n)?new FormData(n):n),Dn.getAdapter=xm.getAdapter,Dn.HttpStatusCode=$h,Dn.default=Dn;const{Axios:WB,AxiosError:zB,CanceledError:HB,isCancel:UB,CancelToken:qB,VERSION:VB,all:KB,Cancel:GB,isAxiosError:YB,spread:XB,toFormData:QB,AxiosHeaders:ZB,HttpStatusCode:JB,formToJSON:ej,getAdapter:tj,mergeConfig:nj}=Dn,Ah=Dn.create({baseURL:location.origin,timeout:6e4,params:{}});Ah.interceptors.response.use(n=>n,n=>{var e,t,r,l,d,h,b,p,g,o,c;if(n.response){if(n.response.status===401&&OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity,!0).then(function(i){i&&OpenC3Auth.setTokens()}),n.response.config.headers["Ignore-Errors"]&&n.response.config.headers["Ignore-Errors"].includes(n.response.status.toString()))return Promise.reject(n);let f=`HTTP ${n.response.status} - `;(e=n.response)!=null&&e.statusText&&(f+=`${n.response.statusText} `),(r=(t=n.response)==null?void 0:t.config)!=null&&r.data&&(f+=`${n.response.config.data} `),(d=(l=n.response)==null?void 0:l.data)!=null&&d.message?f+=`${n.response.data.message}`:(b=(h=n.response)==null?void 0:h.data)!=null&&b.exception?f+=`${n.response.data.exception}`:(o=(g=(p=n.response)==null?void 0:p.data)==null?void 0:g.error)!=null&&o.message?(n.response.data.error.class&&(f+=`${n.response.data.error.class} `),f+=`${n.response.data.error.message}`):f+=`${(c=n.response)==null?void 0:c.data}`;const{$cosmosNotify:u}=window;throw u&&u.serious({title:"Network error",body:f}),n}else throw n});const wc=async function(n,e,{data:t,params:r={},headers:l,noAuth:d=!1,noScope:h=!1,onUploadProgress:b=!1}={}){if(!d){try{await OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity)&&OpenC3Auth.setTokens()}catch{OpenC3Auth.login()}l.Authorization=localStorage.openc3Token}return l.manual=!0,!h&&!r.scope&&(r.scope=window.openc3Scope),Ah({method:n,url:e,data:t,params:r,headers:l,onUploadProgress:b})},Eh={Accept:"application/json"},$m={...Eh,"Content-Type":"application/json"},rj=Pi("F",{get:function(n,{params:e,headers:t=Eh,noScope:r,noAuth:l,onUploadProgress:d}={}){return wc("get",n,{params:e,headers:t,noScope:r,noAuth:l,onUploadProgress:d})},put:function(n,{data:e,params:t,headers:r=$m,noScope:l,noAuth:d,onUploadProgress:h}={}){return wc("put",n,{data:e,params:t,headers:r,noScope:l,noAuth:d,onUploadProgress:h})},post:function(n,{data:e,params:t,headers:r=$m,noScope:l,noAuth:d,onUploadProgress:h}={}){return wc("post",n,{data:e,params:t,headers:r,noScope:l,noAuth:d,onUploadProgress:h})},delete:function(n,{params:e,headers:t=Eh,noScope:r,noAuth:l,onUploadProgress:d}={}){return wc("delete",n,{params:e,headers:t,noScope:r,noAuth:l,onUploadProgress:d})}});let xc=()=>({emit(n,...e){for(let t=this.events[n]||[],r=0,l=t.length;r<l;r++)t[r](...e)},events:{},on(n,e){var t;return((t=this.events)[n]||(t[n]=[])).push(e),()=>{var r;this.events[n]=(r=this.events[n])==null?void 0:r.filter(l=>e!==l)}}});class al extends Error{constructor(e,t){e instanceof Error?(super(e.message),this.cause=e):super(e),this.reason=t,this.name="ReasonError"}}class Th extends al{constructor(e){super("Rejected",e),this.name="SubscriptionRejectedError"}}class hC extends al{constructor(e){super(e||"Timed out to receive subscription ack"),this.name="SubscriptionTimeoutError"}}class Wi extends al{constructor(e,t){t?super(e,t):super("Disconnected",e),this.name="DisconnectedError"}}class dC extends Wi{constructor(e){super(e,"stale_connection"),this.name="StaleConnectionError"}}function Am(n){return n?`{${Object.keys(n).sort().filter(e=>n[e]!==void 0).map(e=>{let t=JSON.stringify(n[e]);return`${JSON.stringify(e)}:${t}`}).join(",")}}`:""}class fC{constructor(e){this.channel=e,this.listeners=[]}watch(){this.listeners.push(this.channel.on("presence",e=>{if(e.type==="info"){this._state||(this._state=this.stateFromInfo(e));return}this._state&&(e.type==="join"?this._state[e.id]=e.info:e.type==="leave"&&delete this._state[e.id])}))}reset(){delete this._state}dispose(){delete this._info,delete this._state,this.listeners.forEach(e=>e()),this.listeners.length=0}async join(e,t){if(!this._info)return this._info={id:e,info:t},this.channel.perform("$presence:join",this._info)}async leave(){if(!this._info)return;let e=await this.channel.perform("$presence:leave");return delete this._info,e}async info(){return this._state?this._state:(this._promise||(this._promise=this._sync()),await this._promise,this._state)}async _sync(){this.watch();try{let e=await this.channel.perform("$presence:info",{});return this._state=this.stateFromInfo(e),this._state}finally{delete this._promise}}stateFromInfo(e){return e.records.reduce((t,{id:r,info:l})=>(t[r]=l,t),{})}}const Es=Symbol("state");class Em{constructor(e={}){this.emitter=xc(),this.params=Object.freeze(e),this.presence=new fC(this),this.initialConnect=!0,this[Es]="idle"}get identifier(){return this._identifier?this._identifier:(this._identifier=Am({channel:this.channelId,...this.params}),this._identifier)}get channelId(){return this.constructor.identifier}get state(){return this[Es]}attached(e){if(this.receiver){if(this.receiver!==e)throw Error("Already connected to a different receiver");return!1}return this.receiver=e,!0}connecting(){this[Es]="connecting"}connected(){if(this.state==="connected"||this.state==="closed")return;this[Es]="connected";let e=!1;this.initialConnect?(this.initialConnect=!1,this.emit("connect",{reconnect:!1,restored:e})):this.emit("connect",{reconnect:!0,restored:e})}restored(){if(this.state==="connected")throw Error("Already connected");this[Es]="connected";let e=!0,t=!0;this.initialConnect=!1,this.emit("connect",{reconnect:t,restored:e})}disconnected(e){this.state==="disconnected"||this.state==="closed"||(this[Es]="disconnected",this.presence.reset(),this.emit("disconnect",e))}closed(e){this.state!=="closed"&&(this[Es]="closed",delete this.receiver,this.initialConnect=!0,this.presence.dispose(),this.emit("close",e))}disconnect(){this.state==="idle"||this.state==="closed"||this.receiver.unsubscribe(this)}async perform(e,t){if(this.state==="idle"||this.state==="closed")throw Error("Channel is not subscribed");return this.receiver.perform(this.identifier,e,t)}async send(e){return this.perform(void 0,e)}async whisper(e){try{await this.perform("$whisper",e)}catch(t){let r=this.receiver?this.receiver.logger:null;r&&r.warn("whisper failed: ",t)}}receive(e,t){this.emit("message",e,t)}on(e,t){return this.emitter.on(e,t)}once(e,t){let r=this.emitter.on(e,(...l)=>{r(),t(...l)});return r}emit(e,...t){return this.emitter.emit(e,...t)}ensureSubscribed(){return this.state==="connected"?Promise.resolve():this.state==="closed"?Promise.reject(Error("Channel is unsubscribed")):this.pendingSubscribe()}pendingSubscribe(){return this._pendingSubscribe?this._pendingSubscribe:(this._pendingSubscribe=new Promise((e,t)=>{let r=[()=>delete this._pendingSubscribe];r.push(this.on("connect",()=>{r.forEach(l=>l()),e()})),r.push(this.on("close",l=>{r.forEach(d=>d()),t(l||new al("Channel was disconnected before subscribing","canceled"))}))}),this._pendingSubscribe)}}class pC{constructor(e){this.id=e,this.intent="unsubscribed",this.state="idle",this.channels=[],this.disposed=!1,this._pendings=[]}add(e){this.channels.includes(e)||this.channels.push(e)}remove(e){let t=this.channels.indexOf(e);t>-1&&this.channels.splice(t,1)}notify(e,...t){this.state=e==="restored"?"connected":e,t.length===1?this.channels.forEach(r=>r[e](t[0])):this.channels.forEach(r=>r[e]())}pending(e){this._checkIntent(e);let t=this._pendings[0];return!t||t.intent!==e?Promise.resolve():t.promise}ensureResubscribed(){this.disposed||(this.intent=void 0,this.ensureSubscribed())}ensureSubscribed(){if(this.intent!=="subscribed"){if(this.disposed)throw Error("Subscription is disposed");this.intent="subscribed",!this._mergeWithPending("unsubscribed")&&this.subscriber(this)}}maybeUnsubscribe(){this.disposed||this.intent==="unsubscribed"||this.channels.length>0||(this.intent="unsubscribed",this._mergeWithPending("subscribed"))||this.unsubscriber(this)}async acquire(e){this._checkIntent(e);let t,r={promise:new Promise(d=>{t=d}),intent:e,release:()=>{this._pendings.splice(this._pendings.indexOf(r),1),t(r)},canceled:!1,acquired:!1},l=this._pendingTop;return this._pendings.push(r),l&&await l.promise,this.gvl&&await this.gvl.acquire(r,e),r.acquired=!0,r}close(e){this.disposed=!0,this.intent=void 0,this.notify("closed",e)}_checkIntent(e){if(!(e==="unsubscribed"||e==="subscribed"))throw Error(`Unknown subscription intent: ${e}`)}get _pendingTop(){return this._pendings.length?this._pendings[this._pendings.length-1]:void 0}_mergeWithPending(e){let t=this._pendingTop;return!t||t.acquired||t.intent!==e?!1:(this._pendings.pop(),t.canceled=!0,!0)}}class gC{constructor(){this.queue=[]}async acquire(e,t){t==="subscribed"&&(this.queue.push(e.promise.then(()=>{this.queue.splice(this.queue.indexOf(e),1)})),this.queue.length>1&&await this.queue[this.queue.length-2])}}class mC{constructor(e){e.concurrentSubscribes===!1&&(this.glv=new gC),this._subscriptions={},this._localToRemote={}}all(){return Object.values(this._subscriptions)}get(e){return this._subscriptions[e]}create(e,{subscribe:t,unsubscribe:r}){let l=this._subscriptions[e]=new pC(e);return l.remoteId=this._localToRemote[e],l.subscriber=t,l.unsubscriber=r,l.gvl=this.glv,l}remove(e){delete this._subscriptions[e],delete this._localToRemote[e]}storeRemoteId(e,t){this._localToRemote[e]=t;let r=this.get(e);r&&(r.remoteId=t)}}class vC{constructor(e={}){this.subscriptions=new mC(e),this._pendingMessages=[],this._remoteToLocal={}}subscribe(e,t){this._remoteToLocal[t]=e,this.subscriptions.storeRemoteId(e,t),this.flush(t)}unsubscribe(e){let t=this.subscriptions.get(e);if(!t)return;let r=t.remoteId;r&&delete this._remoteToLocal[r],this.subscriptions.remove(e)}transmit(e,t,r){let l=this._remoteToLocal[e];if(!l){this._pendingMessages.push([e,t,r]);return}let d=this.subscriptions.get(l);d&&d.channels.forEach(h=>{h.receive(t,r)})}notify(e,t,r){let l=this._remoteToLocal[e];if(!l)return;let d=this.subscriptions.get(l);d&&d.channels.forEach(h=>h.emit(t,r))}close(){this._pendingMessages.length=0}get size(){return this.channels.length}get channels(){return this.subscriptions.all().flatMap(e=>e.channels)}flush(e){let t=[];for(let r of this._pendingMessages)r[0]===e?this.transmit(r[0],r[1],r[2]):t.push(r);this._pendingMessages=t}}const Tm={debug:0,info:1,warn:2,error:3};class Rm{constructor(e){this.level=e||"warn"}log(e,t,r){Tm[e]<Tm[this.level]||this.writeLogEntry(e,t,r)}writeLogEntry(){throw Error("Not implemented")}debug(e,t){this.log("debug",e,t)}info(e,t){this.log("info",e,t)}warn(e,t){this.log("warn",e,t)}error(e,t){this.log("error",e,t)}}class ll extends Rm{writeLogEntry(){}}class yC{encode(e){return JSON.stringify(e)}decode(e){try{return JSON.parse(e)}catch{}}}let bC=0;class Mm{constructor(e={}){let{logger:t}=e;this.logger=t||new ll,this.pendingSubscriptions={},this.pendingUnsubscriptions={},this.subscribeCooldownInterval=e.subscribeCooldownInterval||250,this.subscribeRetryInterval=e.subscribeRetryInterval||5e3}attached(e){this.cable=e}subscribe(e,t){let r={channel:e};t&&Object.assign(r,t);let l=Am(r);if(this.pendingUnsubscriptions[l]){let h=this.subscribeCooldownInterval*1.5;return this.logger.debug(`unsubscribed recently, cooldown for ${h}`,l),new Promise(b=>{setTimeout(()=>{b(this.subscribe(e,t))},h)})}if(this.pendingSubscriptions[l])return this.logger.warn("subscription is already pending, skipping",l),Promise.reject(Error("Already subscribing"));let d=this.subscribeRetryInterval;return new Promise((h,b)=>{let p=++bC;this.pendingSubscriptions[l]={resolve:h,reject:b,id:p},this.cable.send(this.buildSubscribeRequest(l)),this.maybeRetrySubscribe(p,l,d)})}buildSubscribeRequest(e){return{command:"subscribe",identifier:e}}maybeRetrySubscribe(e,t,r){setTimeout(()=>{let l=this.pendingSubscriptions[t];l&&l.id===e&&(this.logger.warn(`no subscription ack received in ${r}ms, retrying subscribe`,t),this.cable.send(this.buildSubscribeRequest(t)),this.maybeExpireSubscribe(e,t,r))},r)}maybeExpireSubscribe(e,t,r){setTimeout(()=>{let l=this.pendingSubscriptions[t];l&&l.id===e&&(delete this.pendingSubscriptions[t],l.reject(new hC(`Haven't received subscription ack in ${r*2}ms for ${t}`)))},r)}unsubscribe(e){return this.cable.send({command:"unsubscribe",identifier:e}),this.pendingUnsubscriptions[e]=!0,setTimeout(()=>{delete this.pendingUnsubscriptions[e]},this.subscribeCooldownInterval),Promise.resolve()}perform(e,t,r){return t==="$whisper"?this.whisper(e,r):(r||(r={}),r.action=t,this.cable.send({command:"message",identifier:e,data:JSON.stringify(r)}),Promise.resolve())}whisper(e,t){return this.cable.send({command:"whisper",identifier:e,data:t}),Promise.resolve()}receive(e){if(typeof e!="object"){this.logger.error("unsupported message format",{message:e});return}let{type:t,identifier:r,message:l,reason:d,reconnect:h}=e;if(t==="ping")return this.cable.keepalive(e.message);if(this.cable.keepalive(),t==="welcome"){let b=e.sid;return b&&this.cable.setSessionId(b),this.cable.connected()}if(t==="disconnect"){let b=new Wi(d);this.reset(b),h===!1?this.cable.closed(b):this.cable.disconnected(b);return}if(t==="confirm_subscription"){let b=this.pendingSubscriptions[r];if(!b){this.logger.error("subscription not found, unsubscribing",{type:t,identifier:r}),this.unsubscribe(r);return}return delete this.pendingSubscriptions[r],b.resolve(r)}if(t==="reject_subscription"){let b=this.pendingSubscriptions[r];return b?(delete this.pendingSubscriptions[r],b.reject(new Th)):this.logger.error("subscription not found",{type:t,identifier:r})}if(l)return{identifier:r,message:l};this.logger.warn(`unknown message type: ${t}`,{message:e})}reset(e){for(let t in this.pendingSubscriptions)this.pendingSubscriptions[t].reject(e);this.pendingSubscriptions={}}recoverableClosure(){return!1}}const Lm=()=>Date.now()/1e3|0;class wC extends Mm{constructor(e={}){super(e),this.streamsPositions={},this.subscriptionStreams={},this.pendingHistory={},this.pendingPresence={},this.presenceInfo={},this.restoreSince=e.historyTimestamp,this.disableSessionRecovery=e.disableSessionRecovery,this.restoreSince===void 0&&(this.restoreSince=Lm()),this.sessionId=void 0,this.sendPongs=e.pongs}reset(e){for(let t in this.pendingPresence)this.pendingPresence[t].reject(e);return this.pendingPresence={},super.reset()}receive(e){if(typeof e!="object"){this.logger.error("unsupported message format",{message:e});return}let{type:t,identifier:r,message:l}=e;if(t==="disconnect")return delete this.sessionId,this.cable.setSessionId(""),super.receive(e);if(t==="reject_subscription")return super.receive(e);if(t==="confirm_subscription")return this.subscriptionStreams[r]||(this.subscriptionStreams[r]=new Set),super.receive(e);if(t==="ping")return this.restoreSince&&(this.restoreSince=Lm()),this.sendPongs&&this.sendPong(),this.cable.keepalive(e.message);if(this.cable.keepalive(),t==="confirm_history"){this.logger.debug("history result received",e),this.cable.notify("history_received",r);return}if(t==="reject_history"){this.logger.warn("failed to retrieve history",e),this.cable.notify("history_not_found",r);return}if(t==="welcome"){if(this.disableSessionRecovery||(this.sessionId=e.sid,this.sessionId&&this.cable.setSessionId(this.sessionId)),e.restored){let d=e.restored_ids||Object.keys(this.subscriptionStreams);for(let h of d)this.cable.send({identifier:h,command:"history",history:this.historyRequestFor(h)}),this.presenceInfo[h]&&this.cable.send({identifier:h,command:"join",presence:this.presenceInfo[h]});return this.cable.restored(d)}return this.cable.connected(this.sessionId)}if(t==="presence"){let d=l.type;if(d==="info"){let h=this.pendingPresence[r];h&&(delete this.pendingPresence[r],h.resolve(l))}else if(d==="error"){let h=this.pendingPresence[r];h&&(delete this.pendingPresence[r],h.reject(new Error("failed to retrieve presence")))}return{type:t,identifier:r,message:l}}if(l){let d=this.trackStreamPosition(r,e.stream_id,e.epoch,e.offset);return{identifier:r,message:l,meta:d}}this.logger.warn(`unknown message type: ${t}`,{message:e})}perform(e,t,r){switch(t){case"$presence:join":return this.join(e,r);case"$presence:leave":return this.leave(e,r);case"$presence:info":return this.presence(e,r)}return super.perform(e,t,r)}unsubscribe(e){return delete this.presenceInfo[e],super.unsubscribe(e)}buildSubscribeRequest(e){let t=super.buildSubscribeRequest(e),r=this.historyRequestFor(e);r&&(t.history=r,this.pendingHistory[e]=!0);let l=this.presenceInfo[e];return l&&(t.presence=l),t}recoverableClosure(){return!!this.sessionId}historyRequestFor(e){let t={},r=!1;if(this.subscriptionStreams[e])for(let l of this.subscriptionStreams[e]){let d=this.streamsPositions[l];d&&(r=!0,t[l]=d)}if(!(!r&&!this.restoreSince))return{since:this.restoreSince,streams:t}}trackStreamPosition(e,t,r,l){if(!(!t||!r))return this.subscriptionStreams[e]||(this.subscriptionStreams[e]=new Set),this.subscriptionStreams[e].add(t),this.streamsPositions[t]={epoch:r,offset:l},{stream:t,epoch:r,offset:l}}async sendPong(){await new Promise(e=>setTimeout(e,0)),this.cable.state==="connected"&&this.cable.send({command:"pong"})}async join(e,t){return this.presenceInfo[e]=t,this.cable.send({command:"join",identifier:e,presence:t}),Promise.resolve()}async leave(e,t){return delete this.presenceInfo[e],this.cable.send({command:"leave",identifier:e,presence:t}),Promise.resolve()}presence(e,t){return this.pendingPresence[e]?(this.logger.warn("presence is already pending, skipping",e),Promise.reject(Error("presence request is already pending"))):new Promise((r,l)=>{this.pendingPresence[e]={resolve:r,reject:l},this.cable.send({command:"presence",identifier:e,data:t})})}}class xC extends al{constructor(){super("No connection","closed"),this.name="NoConnectionError"}}class Rh extends Em{constructor(e,t){super(t),this.channelId=e}set channelId(e){this._channelId=e}get channelId(){return this._channelId}}cc(Rh,"identifier","__ghost__");const kC="$pubsub";class Mh extends Em{async perform(e,t){if(e.startsWith("$"))return super.perform(e,t);throw Error("not implemented")}}cc(Mh,"identifier",kC);const Ts=Symbol("state");let SC=class{constructor({transport:n,protocol:e,encoder:t,logger:r,lazy:l,hubOptions:d,performFailures:h,transportConfigurator:b}){this.emitter=xc(),this.transport=n,this.encoder=t,this.logger=r||new ll,this.protocol=e,this.performFailures=h||"throw",this.protocol.attached(this),this.hub=new vC(d||{}),this[Ts]="idle",this.handleClose=this.handleClose.bind(this),this.handleIncoming=this.handleIncoming.bind(this),this.transportConfigurator=b,this.transport.on("close",this.handleClose),this.transport.on("data",this.handleIncoming),this.initialConnect=!0,this.recovering=!1,l===!1&&this.connect().catch(()=>{})}get state(){return this[Ts]}async connect(){if(this.state==="connected")return Promise.resolve();if(this.state==="connecting")return this.pendingConnect();let n=this.state==="idle";this[Ts]="connecting";let e=this.pendingConnect();this.logger.debug("connecting");try{this.transportConfigurator&&await this.transportConfigurator(this.transport,{initial:n}),await this.transport.open()}catch(t){this.handleClose(t)}return e}setSessionId(n){this.sessionId=n,this.transport.setParam("sid",n)}connected(){if(this.state==="connected")return;this.logger.info("connected"),this[Ts]="connected",this.recovering&&this.hub.subscriptions.all().forEach(e=>e.notify("disconnected",new Wi("recovery_failed"))),this.hub.subscriptions.all().forEach(e=>this._resubscribe(e));let n=!1;this.recovering=!1,this.initialConnect?(this.initialConnect=!1,this.emit("connect",{reconnect:!1,restored:n})):this.emit("connect",{reconnect:!0,restored:n})}restored(n){this.logger.info("connection recovered",{remoteIds:n}),this[Ts]="connected",this.hub.subscriptions.all().forEach(r=>{n&&r.remoteId&&n.includes(r.remoteId)?r.notify("restored"):(r.notify("disconnected",new Wi("recovery_failed")),this._resubscribe(r))});let e=!this.initialConnect,t=!0;this.recovering=!1,this.initialConnect=!1,this.emit("connect",{reconnect:e,restored:t})}notify(n,e,t){e&&typeof e!="string"&&(t=e,e=void 0),e?this.hub.notify(e,"info",{type:n,data:t}):this.emit("info",{type:n,data:t})}handleClose(n){this.logger.debug("transport closed",{error:n}),this.disconnected(new Wi(n,"transport_closed"))}disconnected(n){(this.state==="connected"||this.state==="connecting")&&(this.logger.info("disconnected",{reason:n}),this[Ts]="disconnected",this.recovering=this.protocol.recoverableClosure(n),this.recovering?this.hub.subscriptions.all().forEach(e=>e.notify("connecting")):this.hub.subscriptions.all().forEach(e=>{e.notify("disconnected",n)}),this.protocol.reset(n),this.hub.close(),this.transport.close(),this.emit("disconnect",n))}closed(n){if(this.state==="closed"||this.state==="idle")return;let e;n&&(e=n instanceof Wi?n:new Wi(n,void 0)),this.logger.info("closed",{reason:n||"user"}),this[Ts]="closed";let t=e||new Wi("cable_closed");this.hub.subscriptions.all().forEach(r=>r.notify("disconnected",t)),this.hub.close(),this.protocol.reset(),this.transport.close(),this.initialConnect=!0,this.emit("close",e)}disconnect(){this.closed()}handleIncoming(n){if(this.state==="closed"||this.state==="idle")return;let e=this.encoder.decode(n);if(e===void 0){this.logger.error("failed to decode message",{message:n});return}this.logger.debug("incoming data",e);let t=this.protocol.receive(e);if(t){this.logger.debug("processed incoming message",t);let{type:r,identifier:l,message:d,meta:h}=t;r?this.hub.notify(l,r,d):this.hub.transmit(l,d,h)}}send(n){if(this.state==="closed")throw Error("Cable is closed");let e=this.encoder.encode(n);if(e===void 0){this.logger.error("failed to encode message",{message:n});return}this.logger.debug("outgoing message",n),this.transport.send(e)}keepalive(n){this.emit("keepalive",n)}streamFrom(n){let e=new Mh({stream_name:n});return this.subscribe(e)}streamFromSigned(n){let e=new Mh({signed_stream_name:n});return this.subscribe(e)}subscribeTo(n,e){let t,r;return typeof n=="string"&&(r=n,n=Rh),t=r?new n(r,e):new n(e),this.subscribe(t)}subscribe(n){if(!n.attached(this))return n;let e=n.identifier;n.connecting();let t=this.hub.subscriptions.get(e)||this.hub.subscriptions.create(e,{subscribe:r=>this._subscribe(r,n.channelId,n.params),unsubscribe:r=>this._unsubscribe(r)});return t.add(n),t.intent==="subscribed"&&t.state==="connected"&&n.connected(),t.ensureSubscribed(),n}async _resubscribe(n){n.intent!=="subscribed"||!n.channels[0]||(n.notify("connecting"),n.ensureResubscribed())}async _subscribe(n,e,t){let r=n.id;if(this.state==="idle"&&this.connect().catch(()=>{}),this.state!=="connected"){this.logger.debug("cancel subscribe, no connection",{identifier:r});return}this.logger.debug("acquiring subscribe lock",{identifier:r});let l=await n.acquire("subscribed");if(l.canceled){this.logger.debug("subscribe lock has been canceled",{identifier:r}),l.release();return}if(this.logger.debug("subscribe lock has been acquired",{identifier:r}),n.intent!=="subscribed"){this.logger.debug("cancel subscribe request, already unsubscribed"),l.release();return}if(this.state!=="connected"){this.logger.debug("cancel subscribe, no connection",{identifier:r}),l.release();return}if(n.state==="connected"){this.logger.debug("already connected, skip subscribe command",{identifier:r}),n.notify("connected"),l.release();return}let d={identifier:e,params:t};this.logger.debug("subscribing",d);try{let h=await this.protocol.subscribe(e,t);this.hub.subscribe(r,h),this.logger.debug("subscribed",{...d,remoteId:h}),n.notify("connected")}catch(h){if(h){if(h instanceof Th&&this.logger.warn("rejected",d),h instanceof Wi){this.logger.debug("disconnected during subscription; will retry on connect",d),l.release();return}this.logger.error("failed to subscribe",{error:h,...d})}n.close(h),this.hub.unsubscribe(r)}l.release()}unsubscribe(n){let e=n.identifier,t=this.hub.subscriptions.get(e);if(!t)throw Error(`Subscription not found: ${e}`);t.remove(n),n.closed(),t.maybeUnsubscribe()}async _unsubscribe(n){let e=n.id;this.logger.debug("acquiring unsubscribe lock",{identifier:e});let t=await n.acquire("unsubscribed");if(t.canceled){this.logger.debug("unsubscribe lock has been canceled",{identifier:e}),t.release();return}if(this.logger.debug("unsubscribe lock has been acquired",{identifier:e}),n.intent!=="unsubscribed"){this.logger.debug("cancel unsubscribe, no longer needed",{identifier:e,intent:n.intent}),t.release();return}if(n.state==="disconnected"||n.state==="closed"){this.logger.debug(`already ${n.state} connected, skip unsubscribe command`,{identifier:e}),t.release();return}let r=n.remoteId;if(this.logger.debug("unsubscribing...",{remoteId:r}),this.state!=="connected"){this.logger.debug("unsubscribe skipped (cable is not connected)",{id:e}),n.close(),this.hub.unsubscribe(e),t.release();return}try{await this.protocol.unsubscribe(r),this.logger.debug("unsubscribed remotely",{id:e})}catch(l){l&&(l instanceof Wi?this.logger.debug("cable disconnected during the unsubscribe command execution",{id:e,error:l}):this.logger.error("unsubscribe failed",{id:e,error:l}))}n.intent==="unsubscribed"?(n.close(),this.hub.unsubscribe(e)):n.state="closed",t.release()}async perform(n,e,t){if(this.performFailures==="throw")return this._perform(n,e,t);try{return await this._perform(n,e,t)}catch(r){this.performFailures==="warn"&&this.logger.warn("perform failed",{error:r});return}}async _perform(n,e,t){if(this.state==="connecting"&&await this.pendingConnect(),this.state==="closed"||this.state==="disconnected")throw new xC;let r=this.hub.subscriptions.get(n);if(!r)throw Error(`Subscription not found: ${n}`);if(await r.pending("subscribed"),r.intent!=="subscribed")throw Error(`Subscription is closed: ${n}`);let l=r.remoteId,d={id:l,action:e,payload:t};this.logger.debug("perform",d);try{let h=await this.protocol.perform(l,e,t);return h&&this.logger.debug("perform result",{message:h,request:d}),h}catch(h){throw this.logger.error("perform failed",{error:h,request:d}),h}}on(n,e){return this.emitter.on(n,e)}once(n,e){let t=this.emitter.on(n,(...r)=>{t(),e(...r)});return t}emit(n,...e){return this.emitter.emit(n,...e)}pendingConnect(){return this._pendingConnect?this._pendingConnect:(this._pendingConnect=new Promise((n,e)=>{let t=[()=>delete this._pendingConnect];t.push(this.on("connect",()=>{t.forEach(r=>r()),n()})),t.push(this.on("close",r=>{t.forEach(l=>l()),e(r)})),t.push(this.on("disconnect",r=>{t.forEach(l=>l()),e(r)}))}),this._pendingConnect)}};const _C={maxMissingPings:2,maxReconnectAttempts:1/0},ga=()=>Date.now(),Om=(n,e)=>{e=e||{};let{backoffRate:t,jitterRatio:r,maxInterval:l}=e;return t=t||2,r===void 0&&(r=.5),d=>{let h=n*t**d,b=h*t,p=h+(b-h)*Math.random(),g=2*(Math.random()-.5)*r;return p=p*(1+g),l&&l<p&&(p=l),p}};let Im=class{constructor({pingInterval:n,...e}){if(this.pingInterval=n,!this.pingInterval)throw Error(`Incorrect pingInterval is provided: ${n}`);if(e=Object.assign({},_C,e),this.strategy=e.reconnectStrategy,!this.strategy)throw Error("Reconnect strategy must be provided");this.maxMissingPings=e.maxMissingPings,this.maxReconnectAttempts=e.maxReconnectAttempts,this.logger=e.logger||new ll,this.state="pending_connect",this.attempts=0,this.disconnectedAt=ga()}watch(n){this.target=n,this.initListeners()}reconnectNow(){return this.state==="connected"||this.state==="pending_connect"||this.state==="closed"?!1:(this.cancelReconnect(),this.state="pending_connect",this.target.connect().catch(n=>{this.logger.info("Failed at reconnecting: "+n)}),!0)}initListeners(){this.unbind=[],this.unbind.push(this.target.on("connect",()=>{this.attempts=0,this.pingedAt=ga(),this.state="connected",this.cancelReconnect(),this.startPolling()})),this.unbind.push(this.target.on("disconnect",()=>{this.disconnectedAt=ga(),this.state="disconnected",this.stopPolling(),this.scheduleReconnect()})),this.unbind.push(this.target.on("close",()=>{this.disconnectedAt=ga(),this.state="closed",this.cancelReconnect(),this.stopPolling()})),this.unbind.push(this.target.on("keepalive",()=>{this.pingedAt=ga()})),this.unbind.push(()=>{this.cancelReconnect(),this.stopPolling()})}dispose(){delete this.target,this.unbind&&this.unbind.forEach(n=>n()),delete this.unbind}startPolling(){this.pollId&&clearTimeout(this.pollId);let n=this.pingInterval+(Math.random()-.5)*this.pingInterval*.5;this.pollId=setTimeout(()=>{this.checkStale(),this.state==="connected"&&this.startPolling()},n)}stopPolling(){this.pollId&&clearTimeout(this.pollId)}checkStale(){let n=ga()-this.pingedAt;n>this.maxMissingPings*this.pingInterval&&(this.logger.warn(`Stale connection: ${n}ms without pings`),this.state="pending_disconnect",this.target.disconnected(new dC))}scheduleReconnect(){if(this.attempts>=this.maxReconnectAttempts){this.target.close();return}let n=this.strategy(this.attempts);this.attempts++,this.logger.info(`Reconnecting in ${n}ms (${this.attempts} attempt)`),this.state="pending_reconnect",this.reconnnectId=setTimeout(()=>this.reconnectNow(),n)}cancelReconnect(){this.reconnnectId&&(clearTimeout(this.reconnnectId),delete this.reconnnectId)}};class CC{constructor(e,t={}){this.transports=e,this.transport=null,this.emitter=xc(),this.unbind=[],this.logger=t.logger||new ll}displayName(){return"fallbacked transport"}async open(){for(let e=0;e<this.transports.length;e++){let t=this.transports[e];try{this.transport=t,this.resetListeners(),this.logger.debug(`Trying to connect via ${t.displayName()}`),await t.open(),this.logger.debug(`Connected via ${t.displayName()}`);return}catch(r){this.logger.debug(`Failed to connect via ${t.displayName()}: ${r.message}`)}}throw this.transport=null,this.resetListeners(),new Error("Couldn't connect via any available transport")}send(e){if(!this.transport)throw new Error("No transport is open");this.transport.send(e)}async close(){if(!this.transport)throw new Error("No transport is open");await this.transport.close(),this.transport=null}setURL(){throw new Error("Not implemented. Set URL for each transport separately")}setParam(e,t){this.transports.forEach(r=>{r.setParam(e,t)})}setToken(e,t){this.transports.forEach(r=>{r.setToken(e,t)})}on(e,t){return this.emitter.on(e,t)}once(e,t){let r=this.emitter.on(e,(...l)=>{r(),t(...l)});return r}get url(){return this.transport?this.transport.url:""}resetListeners(){this.unbind.forEach(e=>e()),this.unbind.length=0,this.transport&&this.unbind.push(this.transport.on("open",()=>{this.emitter.emit("open")}),this.transport.on("data",e=>{this.emitter.emit("data",e)}),this.transport.on("close",e=>{this.emitter.emit("close",e)}),this.transport.on("error",e=>{this.emitter.emit("error",e)}))}}class $C{constructor(e,t={}){this.url=e;let r=t.websocketImplementation;if(r)this.Impl=r;else if(typeof WebSocket<"u")this.Impl=WebSocket;else throw new Error("No WebSocket support");this.connected=!1,this.emitter=xc();let{format:l,subprotocol:d,authStrategy:h}=t;this.format=l||"text",this.connectionOptions=t.websocketOptions,this.authStrategy=h||"param",this.authProtocol="",this.subprotocol=d}displayName(){return"WebSocket("+this.url+")"}open(){let e=this.subprotocol;return this.authStrategy==="sub-protocol"&&(e=[this.subprotocol,this.authProtocol]),this.connectionOptions?this.ws=new this.Impl(this.url,e,this.connectionOptions):this.ws=new this.Impl(this.url,e),this.ws.binaryType="arraybuffer",this.initListeners(),new Promise((t,r)=>{let l=[];l.push(this.once("open",()=>{l.forEach(d=>d()),t()})),l.push(this.once("close",()=>{l.forEach(d=>d()),r(Error("WS connection closed"))}))})}setURL(e){this.url=e}setParam(e,t){let r=new URL(this.url);r.searchParams.set(e,t);let l=`${r.protocol}//${r.host}${r.pathname}?${r.searchParams}`;this.setURL(l)}setToken(e,t="jid"){if(this.authStrategy==="param")this.setParam(t,e);else if(this.authStrategy==="header"){this.connectionOptions=this.connectionOptions||{},this.connectionOptions.headers=this.connectionOptions.headers||{};let r=`x-${t}`.toLowerCase();r=Object.keys(this.connectionOptions.headers).find(l=>l.toLowerCase()===r)||r,this.connectionOptions.headers[r]=e}else if(this.authStrategy==="sub-protocol")this.authProtocol=`anycable-token.${e}`;else throw new Error("Unknown auth strategy: "+this.authStrategy)}send(e){if(!this.ws||!this.connected)throw Error("WebSocket is not connected");this.ws.send(e)}close(){this.ws?this.onclose():this.connected=!1}on(e,t){return this.emitter.on(e,t)}once(e,t){let r=this.emitter.on(e,(...l)=>{r(),t(...l)});return r}initListeners(){this.ws.onerror=e=>{this.connected&&this.emitter.emit("error",e.error||new Error("WS Error"))},this.ws.onclose=()=>{this.onclose()},this.ws.onmessage=e=>{let t=e.data;this.format==="binary"&&(t=new Uint8Array(t)),this.emitter.emit("data",t)},this.ws.onopen=()=>{this.connected=!0,this.emitter.emit("open")}}onclose(){this.ws.onclose=void 0,this.ws.onmessage=void 0,this.ws.onopen=void 0,this.ws.close(),delete this.ws,this.connected=!1,this.emitter.emit("close")}}const Nm={protocol:"actioncable-v1-json",pingInterval:3e3,maxReconnectAttempts:1/0,maxMissingPings:2,logLevel:"warn",lazy:!0};function AC(n,e){if(typeof n=="object"&&typeof e>"u"&&(e=n,n=void 0),e=e||{},!n&&!e.transport)throw Error("URL or transport must be specified");e=Object.assign({},Nm,e);let{protocol:t,websocketImplementation:r,websocketFormat:l,websocketOptions:d,websocketAuthStrategy:h,fallbacks:b,logLevel:p,logger:g,transport:o,encoder:c,lazy:f,monitor:u,pingInterval:i,reconnectStrategy:a,maxMissingPings:m,maxReconnectAttempts:w,subprotocol:x,tokenRefresher:M,historyTimestamp:$,protocolOptions:S,concurrentSubscribes:k,performFailures:T,transportConfigurator:D,auth:L}=e;if(g=g||new ll(p),typeof t=="string"){x=x||t;let P=t.substring(0,t.lastIndexOf("-")),N=t.substring(t.lastIndexOf("-")+1);if(S=S||{},P==="actioncable-v1")t=new Mm({logger:g,...S});else if(P==="actioncable-v1-ext")t=new wC({logger:g,historyTimestamp:$,...S});else throw Error(`Protocol is not supported yet: ${t}`);if(N==="json")c=c||new yC,l=l||"text";else if(N==="msgpack"){if(l="binary",!c)throw Error("Msgpack encoder must be specified explicitly. Use `@anycable/msgpack-encoder` package or build your own")}else if(N==="protobuf"){if(l=l||"binary",!c)throw Error("Protobuf encoder must be specified explicitly. Use `@anycable/protobuf-encoder` package or build your own")}else throw Error(`Protocol is not supported yet: ${t}`)}if(!t)throw Error("Protocol must be specified");o=o||new $C(n,{websocketImplementation:r,websocketOptions:d,subprotocol:x,authStrategy:h,format:l}),b&&(o=new CC([o,...b],{logger:g})),L&&L.token&&o.setToken(L.token,L.param||"jid"),a=a||Om(i),u!==!1&&(u=u||new Im({pingInterval:i,reconnectStrategy:a,maxMissingPings:m,maxReconnectAttempts:w,logger:g}));let O={concurrentSubscribes:k},z=new SC({protocol:t,transport:o,encoder:c,logger:g,lazy:f,hubOptions:O,performFailures:T,transportConfigurator:D});return u&&(u.watch(z),z.monitor=u),M&&EC(z,async()=>{try{await M(o)}catch(P){return g.error("Failed to refresh authentication token: "+P),!1}return z.connect().catch(()=>{}),!0}),z}function EC(n,e){let t=!1;n.on("connect",()=>t=!1),n.on("close",async r=>{if(r){if(t){n.logger.warn("Token auto-refresh is disabled",r);return}r.reason==="token_expired"&&(t=!0,await e())}})}class TC{constructor(e){this.channel=e}notify(e,...t){typeof this[e]=="function"&&this[e](...t)}perform(e,t={}){this.channel.perform(e,t)}send(e){this.channel.send(e)}get identifier(){return this.channel.identifier}unsubscribe(){return this.channel.disconnect()}}class RC extends Rh{constructor(e,t,r){super(e,t),this.subscription=new TC(this),Object.assign(this.subscription,r),this.on("connect",({reconnect:l})=>this.subscription.notify("connected",{reconnected:l})),this.on("disconnect",()=>this.subscription.notify("disconnected",{allowReconnect:!0})),this.on("message",l=>this.subscription.notify("received",l)),this.on("close",l=>{l&&l instanceof Th?this.subscription.notify("rejected"):this.subscription.notify("disconnected",{allowReconnect:!1})})}}class MC{constructor(e){this.cable=e}create(e,t){let r,l;typeof e=="object"?(r=e.channel,delete e.channel,l=e):(r=e,l={});let d=new RC(r,l,t);return d.subscription.notify("initialized"),this.cable.subscribe(d),d.subscription}findAll(e){return this.cable.hub.channels.filter(t=>t.identifier===e).map(t=>t.subscription)}}class LC{constructor(e){this.cable=e,this.subscriptions=new MC(e)}}class OC extends Rm{writeLogEntry(e,t,r){r?console[e](t,r):console[e](t)}}class IC extends Im{watch(e){super.watch(e),this.initActivityListeners()}initActivityListeners(){if(typeof document<"u"&&typeof window<"u"&&document.addEventListener&&window.addEventListener){let e=()=>{document.hidden||this.reconnectNow()&&this.logger.debug("Trigger reconnect due to visibility change")},t=l=>{this.reconnectNow()&&this.logger.debug("Trigger reconnect",{event:l})},r=()=>this.disconnect(new Wi("page_frozen"));document.addEventListener("visibilitychange",e,!1),window.addEventListener("focus",t,!1),window.addEventListener("online",t,!1),window.addEventListener("resume",t,!1),window.addEventListener("freeze",r,!1),this.unbind.push(()=>{document.removeEventListener("visibilitychange",e,!1),window.removeEventListener("focus",t,!1),window.removeEventListener("online",t,!1),window.removeEventListener("resume",t,!1),window.removeEventListener("freeze",r,!1)})}}disconnect(e){this.state==="disconnected"||this.state==="closed"||(this.logger.info("Disconnecting",{reason:e.message}),this.cancelReconnect(),this.stopPolling(),this.state="pending_disconnect",this.target.disconnected(e))}}const NC=["cable","action-cable"],DC="/cable",kc=(n,e)=>{for(let t of NC){let r=n.head.querySelector(`meta[name='${t}-${e}']`);if(r)return r.getAttribute("content")}},Dm=n=>n.match(/wss?:\/\//)?n:typeof window<"u"?`${window.location.protocol.replace("http","ws")}//${window.location.host}${n}`:n,FC=()=>{if(typeof document<"u"&&document.head){let n=kc(document,"url");if(n)return Dm(n)}return Dm(DC)},PC=()=>{if(typeof document<"u"&&document.head){let n=kc(document,"history-timestamp");if(n)return n|0}},BC=()=>{if(typeof document<"u"&&document.head)return kc(document,"token")},jC=()=>{if(typeof document<"u"&&document.head)return kc(document,"token-param")};function WC(n,e){typeof n=="object"&&typeof e>"u"&&(e=n,n=void 0),n=n||FC(),e=e||{},e.historyTimestamp||(e.historyTimestamp=PC());let t=BC();if(t){let g=jC();e.auth=Object.assign({token:t,param:g},e.auth||{})}e=Object.assign({},Nm,e);let{logLevel:r,logger:l,pingInterval:d,reconnectStrategy:h,maxMissingPings:b,maxReconnectAttempts:p}=e;return l=e.logger=e.logger||new OC(r),h=e.reconnectStrategy=e.reconnectStrategy||Om(d),e.monitor!==!1&&(e.monitor=e.monitor||new IC({pingInterval:d,reconnectStrategy:h,maxMissingPings:b,maxReconnectAttempts:p,logger:l})),AC(n,e)}function zC(n,e){let t=WC(n,e);return new LC(t)}class HC{constructor(e="/openc3-api/cable"){this._cable=null,this._url=e}disconnect(){this._cable&&(this._cable.cable.disconnect(),this._cable=null)}createSubscription(e,t,r={},l={}){return OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity).then(d=>{if(d&&OpenC3Auth.setTokens(),this._cable==null){let h=this._url+"?scope="+encodeURIComponent(t)+"&authorization="+encodeURIComponent(localStorage.openc3Token);h=new URL(h,document.baseURI).href,this._cable=zC(h)}return this._cable.subscriptions.create({channel:e,...l},r)})}recordPing(){}}Pi("P",HC);class UC{constructor(e,t,r="",l=""){this.keyword=e.keyword,this.parameters=e.parameters,this.filename=e.filename,this.line=e.line,this.lineNumber=e.lineNumber,this.message=t,this.usage=r,this.url=l}}Pi("k",UC);function cl(n){return qC.test(n)}const qC=/^-?[0-9]+$/;function Fm(n){return VC.test(n)}const VC=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?$/;function Pm(n,e){if(cl(n))return Number.isSafeInteger(Number.parseInt(n,10));const t=Number.parseFloat(n),r=String(t);if(n===r)return!0;const l=Bm(n),d=Bm(r);return!!(l===d||(e==null?void 0:e.approx)===!0&&!cl(n)&&d.length>=14&&l.startsWith(d.substring(0,14)))}let ul=function(n){return n.underflow="underflow",n.overflow="overflow",n.truncate_integer="truncate_integer",n.truncate_float="truncate_float",n}({});function KC(n){if(Pm(n,{approx:!1}))return;if(cl(n))return ul.truncate_integer;const e=Number.parseFloat(n);return Number.isFinite(e)?e===0?ul.underflow:ul.truncate_float:ul.overflow}function Bm(n){const{start:e,end:t}=GC(n),r=n.substring(e,t),l=r.indexOf(".");return l===-1?r:r.substring(0,l)+r.substring(l+1)}function GC(n){let e=0;for(n[0]==="-"&&e++;n[e]==="0"||n[e]===".";)e++;let t=n.lastIndexOf("e");for(t===-1&&(t=n.lastIndexOf("E")),t===-1&&(t=n.length);(n[t-1]==="0"||n[t-1]===".")&&t>e;)t--;return{start:e,end:t}}class YC{constructor(e){if(cc(this,"isLosslessNumber",!0),!Fm(e))throw new Error(`Invalid number (value: "${e}")`);this.value=e}valueOf(){const e=KC(this.value);if(e===void 0||e===ul.truncate_float)return Number.parseFloat(this.value);if(cl(this.value))return BigInt(this.value);throw new Error(`Cannot safely convert to number: the value '${this.value}' would ${e} and become ${Number.parseFloat(this.value)}`)}toString(){return this.value}}function XC(n){return n&&typeof n=="object"&&n.isLosslessNumber||!1}function QC(n){return new YC(n)}function ZC(n,e){return Lh({"":n},"",n,e)}function Lh(n,e,t,r){return Array.isArray(t)?r.call(n,e,e$(t,r)):t&&typeof t=="object"&&!XC(t)?r.call(n,e,JC(t,r)):r.call(n,e,t)}function JC(n,e){for(const t of Object.keys(n)){const r=Lh(n,t,n[t],e);r!==void 0?n[t]=r:delete n[t]}return n}function e$(n,e){for(let t=0;t<n.length;t++)n[t]=Lh(n,String(t),n[t],e);return n}function t$(n,e,t){const r=typeof t=="function"?{parseNumber:t}:t,l=(r==null?void 0:r.parseNumber)??QC,d=(r==null?void 0:r.onDuplicateKey)??T;let h=0;const b=o();return w(b),M(),e?ZC(b,e):b;function p(){if(n.charCodeAt(h)===a$){h++,f();const j={};let U=!0;for(;h<n.length&&n.charCodeAt(h)!==Wm;){U?U=!1:(a(),f());const K=h,Z=u();if(Z===void 0){k();return}f(),m();const J=o();if(J===void 0){P();return}if(Object.prototype.hasOwnProperty.call(j,Z)&&!Oh(J,j[Z])){const ae=d({key:Z,position:K+1,oldValue:j[Z],newValue:J});ae!==void 0&&(j[Z]=ae)}else j[Z]=J}return n.charCodeAt(h)!==Wm&&D(),h++,j}}function g(){if(n.charCodeAt(h)===l$){h++,f();const j=[];let U=!0;for(;h<n.length&&n.charCodeAt(h)!==zm;){U?U=!1:a();const K=o();x(K),j.push(K)}return n.charCodeAt(h)!==zm&&L(),h++,j}}function o(){f();const j=u()??i()??p()??g()??c("true",!0)??c("false",!1)??c("null",null);return f(),j}function c(j,U){if(n.slice(h,h+j.length)===j)return h+=j.length,U}function f(){for(;n$(n.charCodeAt(h));)h++}function u(){if(n.charCodeAt(h)===Ih){h++;let j="";for(;h<n.length&&n.charCodeAt(h)!==Ih;){if(n.charCodeAt(h)===s$){const U=n[h+1],K=o$[U];K!==void 0?(j+=K,h++):U==="u"?Sc(n.charCodeAt(h+2))&&Sc(n.charCodeAt(h+3))&&Sc(n.charCodeAt(h+4))&&Sc(n.charCodeAt(h+5))?(j+=String.fromCharCode(Number.parseInt(n.slice(h+2,h+6),16)),h+=5):N(h):z(h)}else i$(n.charCodeAt(h))?j+=n[h]:O(n[h]);h++}return S(),h++,j}}function i(){const j=h;if(n.charCodeAt(h)===Hm&&(h++,$(j)),n.charCodeAt(h)===Nh)h++;else if(r$(n.charCodeAt(h)))for(h++;_c(n.charCodeAt(h));)h++;if(n.charCodeAt(h)===m$)for(h++,$(j);_c(n.charCodeAt(h));)h++;if(n.charCodeAt(h)===x$||n.charCodeAt(h)===w$)for(h++,(n.charCodeAt(h)===Hm||n.charCodeAt(h)===f$)&&h++,$(j);_c(n.charCodeAt(h));)h++;if(h>j)return l(n.slice(j,h))}function a(){if(n.charCodeAt(h)!==g$)throw new SyntaxError(`Comma ',' expected after value ${I()}`);h++}function m(){if(n.charCodeAt(h)!==v$)throw new SyntaxError(`Colon ':' expected after property name ${I()}`);h++}function w(j){if(j===void 0)throw new SyntaxError(`JSON value expected ${I()}`)}function x(j){if(j===void 0)throw new SyntaxError(`Array item expected ${I()}`)}function M(){if(h<n.length)throw new SyntaxError(`Expected end of input ${I()}`)}function $(j){if(!_c(n.charCodeAt(h))){const U=n.slice(j,h);throw new SyntaxError(`Invalid number '${U}', expecting a digit ${I()}`)}}function S(){if(n.charCodeAt(h)!==Ih)throw new SyntaxError(`End of string '"' expected ${I()}`)}function k(){throw new SyntaxError(`Quoted object key expected ${I()}`)}function T(j){let{key:U,position:K}=j;throw new SyntaxError(`Duplicate key '${U}' encountered at position ${K}`)}function D(){throw new SyntaxError(`Quoted object key or end of object '}' expected ${I()}`)}function L(){throw new SyntaxError(`Array item or end of array ']' expected ${I()}`)}function O(j){throw new SyntaxError(`Invalid character '${j}' ${A()}`)}function z(j){const U=n.slice(j,j+2);throw new SyntaxError(`Invalid escape character '${U}' ${A()}`)}function P(){throw new SyntaxError(`Object value expected after ':' ${A()}`)}function N(j){const U=n.slice(j,j+6);throw new SyntaxError(`Invalid unicode character '${U}' ${A()}`)}function A(){return`at position ${h}`}function _(){return h<n.length?`but got '${n[h]}'`:"but reached end of input"}function I(){return`${_()} ${A()}`}}function n$(n){return n===c$||n===u$||n===h$||n===d$}function Sc(n){return n>=Nh&&n<=Dh||n>=y$&&n<=k$||n>=b$&&n<=S$}function _c(n){return n>=Nh&&n<=Dh}function r$(n){return n>=p$&&n<=Dh}function i$(n){return n>=32&&n<=1114111}function Oh(n,e){return n===e?!0:Array.isArray(n)&&Array.isArray(e)?n.length===e.length&&n.every((t,r)=>Oh(t,e[r])):jm(n)&&jm(e)?[...new Set([...Object.keys(n),...Object.keys(e)])].every(t=>Oh(n[t],e[t])):!1}function jm(n){return typeof n=="object"&&n!==null}const o$={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:`
|
|
1404
|
+
`,r:"\r",t:" "},s$=92,a$=123,Wm=125,l$=91,zm=93,c$=32,u$=10,h$=9,d$=13,Ih=34,f$=43,Hm=45,Nh=48,p$=49,Dh=57,g$=44,m$=46,v$=58,y$=65,b$=97,w$=69,x$=101,k$=70,S$=102;function Um(n,e,t,r){return l(n);function l(p,g){if(Array.isArray(r)){const o=r.find(c=>c.test(p));if(o){const c=o.stringify(p);if(typeof c!="string"||!Fm(c))throw new Error(`Invalid JSON number: output of a number stringifier must be a string containing a JSON number (output: ${c})`);return c}}if(typeof p=="boolean"||typeof p=="number"||typeof p=="string"||p===null||p instanceof Date||p instanceof Boolean||p instanceof Number||p instanceof String)return JSON.stringify(p);if(p!=null&&p.isLosslessNumber||typeof p=="bigint")return p.toString();if(Array.isArray(p))return d(p);if(p&&typeof p=="object")return h(p)}function d(p,g){if(p.length===0)return"[]";let o="[";for(let c=0;c<p.length;c++){const f=p[c];typeof f<"u"&&typeof f!="function"?o+=l(f):o+="null",c<p.length-1&&(o+=",")}return o+="]",o}function h(p,g){if(typeof p.toJSON=="function")return Um(p.toJSON(),e,t,void 0);const o=Array.isArray(e)?e.map(String):Object.keys(p);if(o.length===0)return"{}";let c=!0,f="{";for(const u of o){const i=p[u];if(b(u,i)){c?c=!1:f+=",";const a=JSON.stringify(u);f+=`${a}:`,f+=l(i)}}return f+="}",f}function b(p,g){return typeof g<"u"&&typeof g!="function"&&typeof g!="symbol"}}function _$(n){return cl(n)&&!Pm(n)?BigInt(n):parseFloat(n)}class qm{constructor(){cc(this,"id",1)}async exec(e,t,r={},l={},d=6e4){try{await OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity)&&OpenC3Auth.setTokens()}catch{OpenC3Auth.login()}this.id=this.id+1;try{return r.scope=window.openc3Scope,l.manual=!0,(await Ah.post("/openc3-api/api",{jsonrpc:"2.0",method:e,params:t,id:this.id,keyword_params:r},{headers:{Authorization:localStorage.openc3Token,"Content-Type":"application/json-rpc",...l},timeout:d,transformRequest:[(h,b)=>Um(h)],transformResponse:[h=>t$(h,void 0,_$)]})).data.result}catch(h){let b=new Error;throw h.response?(b.name=h.response.data.error.data.class,b.message=h.response.data.error.data.message,b.object=h.response.data.error):h.request?(b.name="Request error",b.message="Request error, no response received"):b=h,b}}decode_openc3_type(e){if(e!==null&&typeof e=="object"&&e.json_class=="Float"&&e.raw){if(e.raw=="NaN")return NaN;if(e.raw=="Infinity")return 1/0;if(e.raw=="-Infinity")return-1/0}return null}encode_openc3_type(e){return Number.isNaN(e)?{json_class:"Float",raw:"NaN"}:e==Number.POSITIVE_INFINITY?{json_class:"Float",raw:"Infinity"}:e==Number.NEGATIVE_INFINITY?{json_class:"Float",raw:"-Infinity"}:null}ensure_offline_access(){this.offline_access_needed().then(e=>{e&&(localStorage.openc3OfflineToken?this.set_offline_access(localStorage.openc3OfflineToken).then(()=>{delete localStorage.openc3OfflineToken}):OpenC3Auth.getOfflineAccess())})}offline_access_needed(){return this.exec("offline_access_needed",[])}set_offline_access(e){return this.exec("set_offline_access",[e])}get_all_interface_info(){return this.exec("get_all_interface_info",[])}map_target_to_interface(e,t,r,l,d){return this.exec("map_target_to_interface",[e,t],{cmd_only:r,tlm_only:l,unmap_old:d})}unmap_target_from_interface(e,t,r,l){return this.exec("unmap_target_from_interface",[e,t],{cmd_only:r,tlm_only:l})}connect_interface(e,...t){return t.length>0?this.exec("connect_interface",[e,...t]):this.exec("connect_interface",[e])}disconnect_interface(e){return this.exec("disconnect_interface",[e])}interface_cmd(e,t,...r){return this.exec("interface_cmd",[e,t,...r])}interface_target_enable(e,t,r=!1,l=!1){return this.exec("interface_target_enable",[e,t],{cmd_only:r,tlm_only:l})}interface_target_disable(e,t,r=!1,l=!1){return this.exec("interface_target_disable",[e,t],{cmd_only:r,tlm_only:l})}interface_details(e){return this.exec("interface_details",[e])}get_all_router_info(){return this.exec("get_all_router_info",[])}map_target_to_router(e,t,r,l,d){return this.exec("map_target_to_router",[e,t],{cmd_only:r,tlm_only:l,unmap_old:d})}unmap_target_from_router(e,t,r,l){return this.exec("unmap_target_from_router",[e,t],{cmd_only:r,tlm_only:l})}connect_router(e){return this.exec("connect_router",[e])}disconnect_router(e){return this.exec("disconnect_router",[e])}router_target_enable(e,t,r=!1,l=!1){return this.exec("router_target_enable",[e,t],{cmd_only:r,tlm_only:l})}router_target_disable(e,t,r=!1,l=!1){return this.exec("router_target_disable",[e,t],{cmd_only:r,tlm_only:l})}router_details(e){return this.exec("router_details",[e])}get_target_interfaces(){return this.exec("get_target_interfaces",[])}get_tlm_cnts(e){return this.exec("get_tlm_cnts",[e])}get_item(e,t,r){return this.exec("get_item",[e,t,r])}get_param(e,t,r){return this.exec("get_param",[e,t,r])}get_parameter(e,t,r){return this.exec("get_param",[e,t,r])}get_limits_sets(){return this.exec("get_limits_sets",[])}get_limits_set(){return this.exec("get_limits_set",[])}set_limits_set(e){return this.exec("set_limits_set",[e])}get_target(e){return this.exec("get_target",[e])}get_target_names(){return this.exec("get_target_names",[])}get_target_list(){return this.exec("get_target_names",[])}get_tlm(e,t){return this.exec("get_tlm",[e,t])}get_telemetry(e,t){return this.exec("get_tlm",[e,t])}get_all_tlm(e){return this.exec("get_all_tlm",[e])}get_all_telemetry(e){return this.exec("get_all_tlm",[e])}get_all_tlm_names(e,t=!1){return this.exec("get_all_tlm_names",[e],{hidden:t})}get_all_telemetry_names(e){return this.exec("get_all_tlm_names",[e])}get_all_tlm_item_names(e){return this.exec("get_all_tlm_item_names",[e])}async get_tlm_packet(e,t,r,l=30){const d=await this.exec("get_tlm_packet",[e,t],{type:r,stale_time:l});if(d!=null){let h=d.length,b=null;for(let p=0;p<h;p++)b=this.decode_openc3_type(d[p][1]),b!==null&&(d[p][1]=b)}return d}get_packet_derived_items(e,t){return this.exec("get_packet_derived_items",[e,t])}get_tlm_buffer(e,t){return this.exec("get_tlm_buffer",[e,t])}get_tlm_available(e){return this.exec("get_tlm_available",[e])}async get_tlm_values(e,t=30,r=null,l=null,d=null){let h={stale_time:t};r!==null&&(h.cache_timeout=r),l!==null&&(h.start_time=l.toISOString()),d!==null&&(h.end_time=d.toISOString());const b=await this.exec("get_tlm_values",[e],h,{},1e4);if(b&&b.length>0){let p=b[0].length,g=null;for(let o=0;o<p;o++)g=this.decode_openc3_type(b[0][o]),g!==null&&(b[0][o]=g)}return b}get_limits(e,t,r){return this.exec("get_limits",[e,t,r])}async tlm(e,t,r,l="CONVERTED"){let d=null;if(t===void 0)d=await this.exec("tlm",[e]);else if(r===void 0)if(["RAW","CONVERTED","FORMATTED","WITH_UNITS"].includes(t))d=await this.exec("tlm",[e],{type:t});else{let b=new Error;throw b.name="TypeError",b.message=`Invalid data type ${t}. Valid options are RAW, CONVERTED, FORMATTED, and WITH_UNITS.`,b}else d=await this.exec("tlm",[e,t,r],{type:l});let h=this.decode_openc3_type(d);return h!==null&&(d=h),d}async inject_tlm(e,t,r=null,l="CONVERTED"){await this.exec("inject_tlm",[e,t,r],{type:l})}set_tlm(e,t,r,l){return this.exec("set_tlm",[e,t,r],{type:l})}override_tlm(e,t,r,l){return this.exec("override_tlm",[e,t,r],{type:l})}get_overrides(){return this.exec("get_overrides")}normalize_tlm(e,t,r,l){return this.exec("normalize_tlm",[e,t,r],{type:l})}get_all_cmds(e){return this.exec("get_all_cmds",[e])}get_all_commands(e){return this.exec("get_all_cmds",[e])}get_all_cmd_names(e,t=!1){return this.exec("get_all_cmd_names",[e],{hidden:t})}get_all_command_names(e){return this.exec("get_all_cmd_names",[e])}get_cmd(e,t){return this.exec("get_cmd",[e,t])}get_command(e,t){return this.exec("get_cmd",[e,t])}get_cmd_cnts(e){return this.exec("get_cmd_cnts",[e])}get_cmd_value(e,t,r,l="CONVERTED"){return this.exec("get_cmd_value",[e,t,r,l])}get_cmd_buffer(e,t){return this.exec("get_cmd_buffer",[e,t])}_cmd(e,t,r,l,d,h={}){let b=null;for(let p in l)Object.prototype.hasOwnProperty.call(l,p)&&(b=this.encode_openc3_type(l[p]),b!==null&&(l[p]=b));return this.exec(e,[t,r,l],h,d)}get_cmd_hazardous(e,t,r,l={}){return t===void 0?this.exec("get_cmd_hazardous",e,{},l):this._cmd("get_cmd_hazardous",e,t,r,l)}cmd(e,t,r,l={},d={}){return t===void 0?this.exec("cmd",e,d,l):this._cmd("cmd",e,t,r,l,d)}cmd_no_range_check(e,t,r,l={},d={}){return t===void 0?this.exec("cmd_no_range_check",e,d,l):this._cmd("cmd_no_range_check",e,t,r,l,d)}cmd_raw(e,t,r,l={},d={}){return t===void 0?this.exec("cmd_raw",e,d,l):this._cmd("cmd_raw",e,t,r,l,d)}cmd_raw_no_range_check(e,t,r,l={},d={}){return t===void 0?this.exec("cmd_raw_no_range_check",e,d,l):this._cmd("cmd_raw_no_range_check",e,t,r,l,d)}cmd_no_hazardous_check(e,t,r,l={},d={}){return t===void 0?this.exec("cmd_no_hazardous_check",e,d,l):this._cmd("cmd_no_hazardous_check",e,t,r,l,d)}cmd_no_checks(e,t,r,l={},d={}){return t===void 0?this.exec("cmd_no_checks",e,d,l):this._cmd("cmd_no_checks",e,t,r,l,d)}cmd_raw_no_hazardous_check(e,t,r,l={},d={}){return t===void 0?this.exec("cmd_raw_no_hazardous_check",e,d,l):this._cmd("cmd_raw_no_hazardous_check",e,t,r,l,d)}cmd_raw_no_checks(e,t,r,l={},d={}){return t===void 0?this.exec("cmd_raw_no_checks",e,d,l):this._cmd("cmd_raw_no_checks",e,t,r,l,d)}build_cmd(e,t,r,l={},d={}){return t===void 0?this.exec("build_cmd",e,d,l):this._cmd("build_cmd",e,t,r,l,d)}build_command(e,t,r,l={},d={}){return t===void 0?this.exec("build_cmd",e,d,l):this._cmd("build_cmd",e,t,r,l,d)}get_interface_names(){return this.exec("get_interface_names",[])}get_router_names(){return this.exec("get_router_names",[])}send_raw(e,t){return this.exec("send_raw",[e,t])}list_configs(e){return this.exec("list_configs",[e])}load_config(e,t){return this.exec("load_config",[e,t])}save_config(e,t,r){return this.exec("save_config",[e,t,r])}delete_config(e,t){return this.exec("delete_config",[e,t])}enable_limits(e,t,r){return this.exec("enable_limits",[e,t,r])}disable_limits(e,t,r){return this.exec("disable_limits",[e,t,r])}get_out_of_limits(){return this.exec("get_out_of_limits",[])}get_overall_limits_state(e){return this.exec("get_overall_limits_state",[e])}list_settings(){return this.exec("list_settings",[])}get_all_settings(){return this.exec("get_all_settings",[])}get_setting(e,t){return this.exec("get_setting",[e],t)}get_settings(e,t){return this.exec("get_settings",e,t)}set_setting(e,t){return this.exec("set_setting",[e,t])}update_news(){return this.exec("update_news",[])}update_plugin_store(){return this.exec("update_plugin_store",[])}save_setting(e,t){return this.exec("set_setting",[e,t])}get_metrics(){return this.exec("get_metrics",[])}async hashString(e){if(window.isSecureContext){const t=new TextEncoder().encode(e),r=await crypto.subtle.digest("SHA-256",t),l=new Uint8Array(r);return Array.from(l).map(d=>d.toString(16).padStart(2,"0")).join("")}}}Pi("B",qm);var Vm={exports:{}},Km;function C$(){return Km||(Km=1,function(n,e){ace.define("ace/ext/hardwrap",["require","exports","module","ace/range","ace/editor","ace/config"],function(t,r,l){function d(g,o){function c(L,O,z){if(!(L.length<O)){var P=L.slice(0,O),N=L.slice(O),A=/^(?:(\s+)|(\S+)(\s+))/.exec(N),_=/(?:(\s+)|(\s+)(\S+))$/.exec(P),I=0,j=0;if(_&&!_[2]&&(I=O-_[1].length,j=O),A&&!A[2]&&(I||(I=O),j=O+A[1].length),I)return{start:I,end:j};if(_&&_[2]&&_.index>z)return{start:_.index,end:_.index+_[2].length};if(A&&A[2])return I=O+A[2].length,{start:I,end:I+A[3].length}}}for(var f=o.column||g.getOption("printMarginColumn"),u=o.allowMerge!=0,i=Math.min(o.startRow,o.endRow),a=Math.max(o.startRow,o.endRow),m=g.session;i<=a;){var w=m.getLine(i);if(w.length>f){var x=c(w,f,5);if(x){var M=/^\s*/.exec(w)[0];m.replace(new b(i,x.start,i,x.end),`
|
|
1405
|
+
`+M)}a++}else if(u&&/\S/.test(w)&&i!=a){var $=m.getLine(i+1);if($&&/\S/.test($)){var S=w.replace(/\s+$/,""),k=$.replace(/^\s+/,""),T=S+" "+k,x=c(T,f,5);if(x&&x.start>S.length||T.length<f){var D=new b(i,S.length,i+1,$.length-k.length);m.replace(D," "),i--,a--}else S.length<w.length&&m.remove(new b(i,S.length,i,w.length))}}i++}}function h(g){if(g.command.name=="insertstring"&&/\S/.test(g.args)){var o=g.editor,c=o.selection.cursor;if(c.column<=o.renderer.$printMarginColumn)return;var f=o.session.$undoManager.$lastDelta;d(o,{startRow:c.row,endRow:c.row,allowMerge:!1}),f!=o.session.$undoManager.$lastDelta&&o.session.markUndoGroup()}}var b=t("../range").Range,p=t("../editor").Editor;t("../config").defineOptions(p.prototype,"editor",{hardWrap:{set:function(g){g?this.commands.on("afterExec",h):this.commands.off("afterExec",h)},value:!1}}),r.hardWrap=d}),ace.define("ace/keyboard/vim",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/dom","ace/lib/oop","ace/lib/keys","ace/lib/event","ace/search","ace/lib/useragent","ace/search_highlight","ace/commands/multi_select_commands","ace/mode/text","ace/ext/hardwrap","ace/multi_select"],function(t,r,l){function d(y){return{row:y.line,column:y.ch}}function h(y){return new De(y.row,y.column)}function b(y,E,C){if(E.line===C.line&&E.ch>=C.ch-1){var F=y.getLine(E.line),B=F.charCodeAt(E.ch);55296<=B&&B<=55551&&(C.ch+=1)}return{start:E,end:C}}function p(y){y.setOption("disableInput",!0),y.setOption("showCursorWhenSelecting",!1),Be.signal(y,"vim-mode-change",{mode:"normal"}),y.on("cursorActivity",is),T(y),Be.on(y.getInputField(),"paste",o(y))}function g(y){y.setOption("disableInput",!1),y.off("cursorActivity",is),Be.off(y.getInputField(),"paste",o(y)),y.state.vim=null,fr&&clearTimeout(fr)}function o(y){var E=y.state.vim;return E.onPasteFn||(E.onPasteFn=function(){E.insertMode||(y.setCursor(ge(y.getCursor(),0,1)),Ln.enterInsertMode(y,{},E))}),E.onPasteFn}function c(y,E){return E>=y.firstLine()&&E<=y.lastLine()}function f(y){return/^[a-z]$/.test(y)}function u(y){return"()[]{}".indexOf(y)!=-1}function i(y){return ja.test(y)}function a(y){return Xt.test(y)}function m(y){return/^\s*$/.test(y)}function w(y){return".?!".indexOf(y)!=-1}function x(y,E){for(var C=0;C<E.length;C++)if(E[C]==y)return!0;return!1}function M(y,E,C,F,B){if(E===void 0&&!B)throw Error("defaultValue is required unless callback is provided");if(C||(C="string"),Pt[y]={type:C,defaultValue:E,callback:B},F)for(var W=0;W<F.length;W++)Pt[F[W]]=Pt[y];E&&$(y,E)}function $(y,E,C,F){var B=Pt[y];F=F||{};var W=F.scope;if(!B)return new Error("Unknown option: "+y);if(B.type=="boolean"){if(E&&E!==!0)return new Error("Invalid argument: "+y+"="+E);E!==!1&&(E=!0)}B.callback?(W!=="local"&&B.callback(E,void 0),W!=="global"&&C&&B.callback(E,C)):(W!=="local"&&(B.value=B.type=="boolean"?!!E:E),W!=="global"&&C&&(C.state.vim.options[y]={value:E}))}function S(y,E,C){var F=Pt[y];C=C||{};var B=C.scope;if(!F)return new Error("Unknown option: "+y);if(F.callback){var W=E&&F.callback(void 0,E);return B!=="global"&&W!==void 0?W:B!=="local"?F.callback():void 0}var W=B!=="global"&&E&&E.state.vim.options[y];return(W||B!=="local"&&F||{}).value}function k(){this.latestRegister=void 0,this.isPlaying=!1,this.isRecording=!1,this.replaySearchQueries=[],this.onRecordingDone=void 0,this.lastInsertModeChanges=Rn()}function T(y){return y.state.vim||(y.state.vim={inputState:new A,lastEditInputState:void 0,lastEditActionCommand:void 0,lastHPos:-1,lastHSPos:-1,lastMotion:null,marks:{},insertMode:!1,insertModeReturn:!1,insertModeRepeat:void 0,visualMode:!1,visualLine:!1,visualBlock:!1,lastSelection:null,lastPastedText:null,sel:{},options:{},expectLiteralNext:!1}),y.state.vim}function D(){We={searchQuery:null,searchIsReversed:!1,lastSubstituteReplacePart:void 0,jumpList:Ti(),macroModeState:new k,lastCharacterSearch:{increment:0,forward:!0,selectedCharacter:""},registerController:new K({}),searchHistoryController:new Z,exCommandHistoryController:new Z};for(var y in Pt){var E=Pt[y];E.value=E.defaultValue}}function L(y){function E(Y){typeof Y=="string"?mn.value=Y:mn=null}if(y[0]=="<"){var C=y.toLowerCase().slice(1,-1),F=C.split("-");if(C=F.pop()||"",C=="lt")y="<";else if(C=="space")y=" ";else if(C=="cr")y=`
|
|
1406
|
+
`;else if(Ri[C]){var B=mn.value,W={key:Ri[C],target:{value:B,selectionEnd:B.length,selectionStart:B.length}};mn.onKeyDown&&mn.onKeyDown(W,mn.value,E),mn&&mn.onKeyUp&&mn.onKeyUp(W,mn.value,E);return}}if(y==`
|
|
1407
|
+
`){var V=mn;mn=null,V.onClose&&V.onClose(V.value)}else mn.value=(mn.value||"")+y}function O(y,E,C){var F=on;if(C){if(jr.indexOf(C)!=-1)return;jr.push(C),on=C.noremap!=0}try{for(var B=T(y),W=/<(?:[CSMA]-)*\w+>|./gi,V;V=W.exec(E);){var Y=V[0],Q=B.insertMode;if(mn){L(Y);continue}var re=mt.handleKey(y,Y,"mapping");if(!re&&Q&&B.insertMode){if(Y[0]=="<"){var le=Y.toLowerCase().slice(1,-1),ye=le.split("-");if(le=ye.pop()||"",le=="lt")Y="<";else if(le=="space")Y=" ";else if(le=="cr")Y=`
|
|
1408
|
+
`;else{if(Ri.hasOwnProperty(le)){Y=Ri[le],ss(y,Y);continue}Y=Y[0],W.lastIndex=V.index+1}}y.replaceSelection(Y)}}}finally{if(jr.pop(),on=jr.length?F:!1,!jr.length&&mn){var ke=mn;mn=null,Tr(y,ke)}}}function z(y,E){var C=y.key;if(!Wr[C]){C.length>1&&C[0]=="n"&&(C=C.replace("Numpad","")),C=Zn[C]||C;var F="";if(y.ctrlKey&&(F+="C-"),y.altKey&&(F+="A-"),y.metaKey&&(F+="M-"),Be.isMac&&y.altKey&&!y.metaKey&&!y.ctrlKey&&(F=F.slice(2)),(F||C.length>1)&&y.shiftKey&&(F+="S-"),E&&!E.expectLiteralNext&&C.length==1){if(Hn.keymap&&C in Hn.keymap)(Hn.remapCtrl!=0||!F)&&(C=Hn.keymap[C]);else if(C.charCodeAt(0)>255){var B=y.code&&y.code.slice(-1)||"";y.shiftKey||(B=B.toLowerCase()),B&&(C=B)}}return F+=C,F.length>1&&(F="<"+F+">"),F}}function P(y,E){Hn.string!==y&&(Hn=N(y)),Hn.remapCtrl=E}function N(y){function E(F){return F.split(/\\?(.)/).filter(Boolean)}var C={};return y?(y.split(/((?:[^\\,]|\\.)+),/).map(function(F){if(F){var B=F.split(/((?:[^\\;]|\\.)+);/);if(B.length==3){var W=E(B[1]),V=E(B[2]);if(W.length!==V.length)return;for(var Y=0;Y<W.length;++Y)C[W[Y]]=V[Y]}else if(B.length==1){var Q=E(F);if(Q.length%2!==0)return;for(var Y=0;Y<Q.length;Y+=2)C[Q[Y]]=Q[Y+1]}}}),{keymap:C,string:y}):{keymap:C,string:""}}function A(){this.prefixRepeat=[],this.motionRepeat=[],this.operator=null,this.operatorArgs=null,this.motion=null,this.motionArgs=null,this.keyBuffer=[],this.registerName=null,this.changeQueue=null}function _(y,E){y.state.vim.inputState=new A,y.state.vim.expectLiteralNext=!1,Be.signal(y,"vim-command-done",E)}function I(){this.removed=[],this.inserted=""}function j(y,E,C){this.clear(),this.keyBuffer=[y||""],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!!E,this.blockwise=!!C}function U(y,E){var C=We.registerController.registers;if(!y||y.length!=1)throw Error("Register name must be 1 character");C[y]=E,Yt.push(y)}function K(y){this.registers=y,this.unnamedRegister=y['"']=new j,y["."]=new j,y[":"]=new j,y["/"]=new j,y["+"]=new j}function Z(){this.historyBuffer=[],this.iterator=0,this.initialPrefix=null}function J(y,E){ri[y]=E}function ae(y,E){for(var C=[],F=0;F<E;F++)C.push(y);return C}function ne(y,E){us[y]=E}function se(y,E){Ln[y]=E}function ce(y,E,C){var F=y.state.vim,B=F.insertMode||F.visualMode,W=Math.min(Math.max(y.firstLine(),E.line),y.lastLine()),V=y.getLine(W),Y=V.length-1+ +!!B,Q=Math.min(Math.max(0,E.ch),Y),re=V.charCodeAt(Q);if(56320<=re&&re<=57343){var le=1;C&&C.line==W&&C.ch>Q&&(le=-1),Q+=le,Q>Y&&(Q-=2)}return new De(W,Q)}function he(y){var E={};for(var C in y)y.hasOwnProperty(C)&&(E[C]=y[C]);return E}function ge(y,E,C){return typeof E=="object"&&(C=E.ch,E=E.line),new De(y.line+E,y.ch+C)}function Ee(y,E,C,F){F.operator&&(C="operatorPending");for(var B,W=[],V=[],Y=on?E.length-No:0,Q=Y;Q<E.length;Q++){var re=E[Q];C=="insert"&&re.context!="insert"||re.context&&re.context!=C||F.operator&&re.type=="action"||!(B=Te(y,re.keys))||(B=="partial"&&W.push(re),B=="full"&&V.push(re))}return{partial:W.length&&W,full:V.length&&V}}function Te(y,E){var C=E.slice(-11)=="<character>",F=E.slice(-10)=="<register>";if(C||F){var B=E.length-(C?11:10),W=y.slice(0,B),V=E.slice(0,B);return W==V&&y.length>B?"full":V.indexOf(W)==0?"partial":!1}return y==E?"full":E.indexOf(y)==0?"partial":!1}function Me(y){var E=/^.*(<[^>]+>)$/.exec(y),C=E?E[1]:y.slice(-1);if(C.length>1)switch(C){case"<CR>":C=`
|
|
1409
|
+
`;break;case"<Space>":C=" ";break;default:C=""}return C}function Xe(y,E,C){return function(){for(var F=0;F<C;F++)E(y)}}function Ke(y){return new De(y.line,y.ch)}function dt(y,E){return y.ch==E.ch&&y.line==E.line}function rt(y,E){return y.line<E.line?!0:y.line==E.line&&y.ch<E.ch}function gt(y,E){return arguments.length>2&&(E=gt.apply(void 0,Array.prototype.slice.call(arguments,1))),rt(y,E)?y:E}function tn(y,E){return arguments.length>2&&(E=tn.apply(void 0,Array.prototype.slice.call(arguments,1))),rt(y,E)?E:y}function jn(y,E,C){var F=rt(y,E),B=rt(E,C);return F&&B}function Zt(y,E){return y.getLine(E).length}function hi(y){return y.trim?y.trim():y.replace(/^\s+|\s+$/g,"")}function kn(y){return y.replace(/([.?*+$\[\]\/\\(){}|\-])/g,"\\$1")}function Xn(y,E,C){var F=Zt(y,E),B=new Array(C-F+1).join(" ");y.setCursor(new De(E,F)),y.replaceRange(B,y.getCursor())}function ur(y,E){var C=[],F=y.listSelections(),B=Ke(y.clipPos(E)),W=!dt(E,B),V=y.getCursor("head"),Y=yt(F,V),Q=dt(F[Y].head,F[Y].anchor),re=F.length-1,le=re-Y>Y?re:0,ye=F[le].anchor,ke=Math.min(ye.line,B.line),me=Math.max(ye.line,B.line),be=ye.ch,Ne=B.ch,Ie=F[le].head.ch-be,He=Ne-be;Ie>0&&He<=0?(be++,W||Ne--):Ie<0&&He>=0?(be--,Q||Ne++):Ie<0&&He==-1&&(be--,Ne++);for(var st=ke;st<=me;st++){var Ye={anchor:new De(st,be),head:new De(st,Ne)};C.push(Ye)}return y.setSelections(C),E.ch=Ne,ye.ch=be,ye}function Pr(y,E,C){for(var F=[],B=0;B<C;B++){var W=ge(E,B,0);F.push({anchor:W,head:W})}y.setSelections(F,0)}function yt(y,E,C){for(var F=0;F<y.length;F++){var B=dt(y[F].anchor,E),W=dt(y[F].head,E);if(B||W)return F}return-1}function qe(y,E){var C=E.lastSelection,F=function(){var W=y.listSelections(),V=W[0],Y=W[W.length-1],Q=rt(V.anchor,V.head)?V.anchor:V.head,re=rt(Y.anchor,Y.head)?Y.head:Y.anchor;return[Q,re]},B=function(){var W=y.getCursor(),V=y.getCursor(),Y=C.visualBlock;if(Y){var Q=Y.width,re=Y.height;V=new De(W.line+re,W.ch+Q);for(var le=[],ye=W.line;ye<V.line;ye++){var ke=new De(ye,W.ch),me=new De(ye,V.ch),be={anchor:ke,head:me};le.push(be)}y.setSelections(le)}else{var Ne=C.anchorMark.find(),Ie=C.headMark.find(),He=Ie.line-Ne.line,st=Ie.ch-Ne.ch;V={line:V.line+He,ch:He?V.ch:st+V.ch},C.visualLine&&(W=new De(W.line,0),V=new De(V.line,Zt(y,V.line))),y.setSelection(W,V)}return[W,V]};return E.visualMode?F():B()}function qt(y,E){var C=E.sel.anchor,F=E.sel.head;E.lastPastedText&&(F=y.posFromIndex(y.indexFromPos(C)+E.lastPastedText.length),E.lastPastedText=null),E.lastSelection={anchorMark:y.setBookmark(C),headMark:y.setBookmark(F),anchor:Ke(C),head:Ke(F),visualMode:E.visualMode,visualLine:E.visualLine,visualBlock:E.visualBlock}}function gn(y,E,C,F){var B=y.state.vim.sel,W=F?E:B.head,V=F?E:B.anchor,Y;return rt(C,E)&&(Y=C,C=E,E=Y),rt(W,V)?(W=gt(E,W),V=tn(V,C)):(V=gt(E,V),W=tn(W,C),W=ge(W,0,-1),W.ch==-1&&W.line!=y.firstLine()&&(W=new De(W.line-1,Zt(y,W.line-1)))),[V,W]}function Qn(y,E,B){var F=y.state.vim;E=E||F.sel;var B=B||F.visualLine?"line":F.visualBlock?"block":"char",W=Br(y,E,B);y.setSelections(W.ranges,W.primary)}function Br(y,E,C,F){var B=Ke(E.head),W=Ke(E.anchor);if(C=="char"){var V=!F&&!rt(E.head,E.anchor)?1:0,Y=rt(E.head,E.anchor)?1:0;return B=ge(E.head,0,V),W=ge(E.anchor,0,Y),{ranges:[{anchor:W,head:B}],primary:0}}if(C=="line"){if(rt(E.head,E.anchor))B.ch=0,W.ch=Zt(y,W.line);else{W.ch=0;var Q=y.lastLine();B.line>Q&&(B.line=Q),B.ch=Zt(y,B.line)}return{ranges:[{anchor:W,head:B}],primary:0}}if(C=="block"){var re=Math.min(W.line,B.line),le=W.ch,ye=Math.max(W.line,B.line),ke=B.ch;le<ke?ke+=1:le+=1;for(var me=ye-re+1,be=B.line==re?0:me-1,Ne=[],Ie=0;Ie<me;Ie++)Ne.push({anchor:new De(re+Ie,le),head:new De(re+Ie,ke)});return{ranges:Ne,primary:be}}}function $r(y){var E=y.getCursor("head");return y.getSelection().length==1&&(E=gt(E,y.getCursor("anchor"))),E}function Sn(y,E){var C=y.state.vim;E!==!1&&y.setCursor(ce(y,C.sel.head)),qt(y,C),C.visualMode=!1,C.visualLine=!1,C.visualBlock=!1,C.insertMode||Be.signal(y,"vim-mode-change",{mode:"normal"})}function ir(y,E,C){var F=y.getRange(E,C);if(/\n\s*$/.test(F)){var B=F.split(`
|
|
1410
|
+
`);B.pop();for(var W,W=B.pop();B.length>0&&W&&m(W);W=B.pop())C.line--,C.ch=0;W?(C.line--,C.ch=Zt(y,C.line)):C.ch=0}}function hr(y,E,C){E.ch=0,C.ch=0,C.line++}function nn(y){if(!y)return 0;var E=y.search(/\S/);return E==-1?y.length:E}function or(y,E,C){var F=E.inclusive,B=E.innerWord,W=E.bigWord,V=E.noSymbol,Y=E.multiline,Q=C||$r(y),re=y.getLine(Q.line),le=re,ye=Q.line,ke=ye,me=Q.ch,be,Ne=V?Do[0]:Ei[0];if(B&&/\s/.test(re.charAt(me)))Ne=function(fn){return/\s/.test(fn)};else{for(;!Ne(re.charAt(me));)if(me++,me>=re.length){if(!Y)return null;me--,be=Ao(y,Q,!0,W,!0);break}W?Ne=Ei[0]:(Ne=Do[0],Ne(re.charAt(me))||(Ne=Do[1]))}for(var Ie=me,He=me;Ne(re.charAt(He))&&He>=0;)He--;if(He++,be)Ie=be.to,ke=be.line,le=y.getLine(ke),!le&&Ie==0&&Ie++;else for(;Ne(re.charAt(Ie))&&Ie<re.length;)Ie++;if(F){var st=Ie,Ye=Q.ch<=He&&/\s/.test(re.charAt(Q.ch));if(!Ye)for(;/\s/.test(le.charAt(Ie))&&Ie<le.length;)Ie++;if(st==Ie||Ye){for(var tt=He;/\s/.test(re.charAt(He-1))&&He>0;)He--;!He&&!Ye&&(He=tt)}}return{start:new De(ye,He),end:new De(ke,Ie)}}function $o(y,E,C){var F=E;if(!Be.findMatchingTag||!Be.findEnclosingTag)return{start:F,end:F};var B=Be.findMatchingTag(y,E)||Be.findEnclosingTag(y,E);return!B||!B.open||!B.close?{start:F,end:F}:C?{start:B.open.from,end:B.close.to}:{start:B.open.to,end:B.close.from}}function Ki(y,E,C){dt(E,C)||We.jumpList.add(y,E,C)}function Gi(y,E){We.lastCharacterSearch.increment=y,We.lastCharacterSearch.forward=E.forward,We.lastCharacterSearch.selectedCharacter=E.selectedCharacter}function Yi(y,E,C,F){var B=Ke(y.getCursor()),W=C?1:-1,V=C?y.lineCount():-1,Y=B.ch,Q=B.line,re=y.getLine(Q),le={lineText:re,nextCh:re.charAt(Y),lastCh:null,index:Y,symb:F,reverseSymb:(C?{")":"(","}":"{"}:{"(":")","{":"}"})[F],forward:C,depth:0,curMoveThrough:!1},ye=gi[F];if(!ye)return B;var ke=mi[ye].init,me=mi[ye].isComplete;for(ke&&ke(le);Q!==V&&E;){if(le.index+=W,le.nextCh=le.lineText.charAt(le.index),!le.nextCh){if(Q+=W,le.lineText=y.getLine(Q)||"",W>0)le.index=0;else{var be=le.lineText.length;le.index=be>0?be-1:0}le.nextCh=le.lineText.charAt(le.index)}me(le)&&(B.line=Q,B.ch=le.index,E--)}return le.nextCh||le.curMoveThrough?new De(Q,le.index):B}function Ao(y,E,C,F,B){var W=E.line,V=E.ch,Y=y.getLine(W),Q=C?1:-1,re=F?Ei:Do;if(B&&Y==""){if(W+=Q,Y=y.getLine(W),!c(y,W))return null;V=C?0:Y.length}for(;;){if(B&&Y=="")return{from:0,to:0,line:W};for(var le=Q>0?Y.length:-1,ye=le,ke=le;V!=le;){for(var me=!1,be=0;be<re.length&&!me;++be)if(re[be](Y.charAt(V))){for(ye=V;V!=le&&re[be](Y.charAt(V));)V+=Q;if(ke=V,me=ye!=ke,ye==E.ch&&W==E.line&&ke==ye+Q)continue;return{from:Math.min(ye,ke+1),to:Math.max(ye,ke),line:W}}me||(V+=Q)}if(W+=Q,!c(y,W))return null;Y=y.getLine(W),V=Q>0?0:Y.length}}function vr(y,E,C,F,B,W){var V=Ke(E),Y=[];(F&&!B||!F&&B)&&C++;for(var Q=!F||!B,re=0;re<C;re++){var le=Ao(y,E,F,W,Q);if(!le){var ye=Zt(y,y.lastLine());Y.push(F?{line:y.lastLine(),from:ye,to:ye}:{line:0,from:0,to:0});break}Y.push(le),E=new De(le.line,F?le.to-1:le.from)}var ke=Y.length!=C,me=Y[0],be=Y.pop();return F&&!B?(!ke&&(me.from!=V.ch||me.line!=V.line)&&(be=Y.pop()),new De(be.line,be.from)):F&&B?new De(be.line,be.to-1):!F&&B?(!ke&&(me.to!=V.ch||me.line!=V.line)&&(be=Y.pop()),new De(be.line,be.to)):new De(be.line,be.from)}function Eo(y,E,C,F,B){var W=E,V=new De(W.line+C.repeat-1,1/0),Y=y.clipPos(V);return Y.ch--,B||(F.lastHPos=1/0,F.lastHSPos=y.charCoords(Y,"div").left),V}function Jo(y,E,C,F,B){for(var W=B||y.getCursor(),V=W.ch,Y,Q=0;Q<E;Q++){var re=y.getLine(W.line);if(Y=Ml(V,re,F,C),Y==-1)return null;V=Y}return new De(y.getCursor().line,Y)}function Rl(y,E){var C=y.getCursor().line;return ce(y,new De(C,E-1))}function di(y,E,C,F){!x(C,bo)&&!Vt.test(C)||(E.marks[C]&&E.marks[C].clear(),E.marks[C]=y.setBookmark(F))}function Ml(y,E,C,F,B){var W;return F?(W=E.indexOf(C,y+1),W!=-1):(W=E.lastIndexOf(C,y-1),W!=-1),W}function zs(y,E,C,F,B){function W(He){return!/\S/.test(y.getLine(He))}function V(He,st,Ye){return Ye?W(He)!=W(He+st):!W(He)&&W(He+st)}function Y(He){F=F>0?1:-1;var st=y.ace.session.getFoldLine(He);st&&He+F>st.start.row&&He+F<st.end.row&&(F=(F>0?st.end.row:st.start.row)-He)}var Q=E.line,re=y.firstLine(),le=y.lastLine(),ye,ke,me=Q;if(F){for(;re<=me&&me<=le&&C>0;)Y(me),V(me,F)&&C--,me+=F;return new De(me,0)}var be=y.state.vim;if(be.visualLine&&V(Q,1,!0)){var Ne=be.sel.anchor;V(Ne.line,-1,!0)&&(!B||Ne.line!=Q)&&(Q+=1)}var Ie=W(Q);for(me=Q;me<=le&&C;me++)V(me,1,!0)&&(!B||W(me)!=Ie)&&C--;for(ke=new De(me,0),me>le&&!Ie?Ie=!0:B=!1,me=Q;me>re&&!((!B||W(me)==Ie||me==Q)&&V(me,-1,!0));me--);return ye=new De(me,0),{start:ye,end:ke}}function Oa(y,E,C,F,B){function W(re){re.pos+re.dir<0||re.pos+re.dir>=re.line.length?re.line=null:re.pos+=re.dir}function V(re,le,ye,ke){var me=re.getLine(le),be={line:me,ln:le,pos:ye,dir:ke};if(be.line==="")return{ln:be.ln,pos:be.pos};var Ne=be.pos;for(W(be);be.line!==null;){if(Ne=be.pos,w(be.line[be.pos])){if(!B)return{ln:be.ln,pos:be.pos+1};for(W(be);be.line!==null&&m(be.line[be.pos]);)Ne=be.pos,W(be);return{ln:be.ln,pos:Ne+1}}W(be)}return{ln:be.ln,pos:Ne+1}}function Y(re,le,ye,ke){var me=re.getLine(le),be={line:me,ln:le,pos:ye,dir:ke};if(be.line==="")return{ln:be.ln,pos:be.pos};var Ne=be.pos;for(W(be);be.line!==null;){if(!m(be.line[be.pos])&&!w(be.line[be.pos]))Ne=be.pos;else if(w(be.line[be.pos]))return B?m(be.line[be.pos+1])?{ln:be.ln,pos:be.pos+1}:{ln:be.ln,pos:Ne}:{ln:be.ln,pos:Ne};W(be)}return be.line=me,B&&m(be.line[be.pos])?{ln:be.ln,pos:be.pos}:{ln:be.ln,pos:Ne}}for(var Q={ln:E.line,pos:E.ch};C>0;)F<0?Q=Y(y,Q.ln,Q.pos,F):Q=V(y,Q.ln,Q.pos,F),C--;return new De(Q.ln,Q.pos)}function Xi(y,E,C,F){function B(Q,re){if(re.pos+re.dir<0||re.pos+re.dir>=re.line.length){if(re.ln+=re.dir,!c(Q,re.ln)){re.line=null,re.ln=null,re.pos=null;return}re.line=Q.getLine(re.ln),re.pos=re.dir>0?0:re.line.length-1}else re.pos+=re.dir}function W(Q,re,le,ye){var Ie=Q.getLine(re),ke=Ie==="",me={line:Ie,ln:re,pos:le,dir:ye},be={ln:me.ln,pos:me.pos},Ne=me.line==="";for(B(Q,me);me.line!==null;){if(be.ln=me.ln,be.pos=me.pos,me.line===""&&!Ne)return{ln:me.ln,pos:me.pos};if(ke&&me.line!==""&&!m(me.line[me.pos]))return{ln:me.ln,pos:me.pos};w(me.line[me.pos])&&!ke&&(me.pos===me.line.length-1||m(me.line[me.pos+1]))&&(ke=!0),B(Q,me)}var Ie=Q.getLine(be.ln);be.pos=0;for(var He=Ie.length-1;He>=0;--He)if(!m(Ie[He])){be.pos=He;break}return be}function V(Q,re,le,ye){var Ne=Q.getLine(re),ke={line:Ne,ln:re,pos:le,dir:ye},me={ln:ke.ln,pos:null},be=ke.line==="";for(B(Q,ke);ke.line!==null;){if(ke.line===""&&!be)return me.pos!==null?me:{ln:ke.ln,pos:ke.pos};if(!(!w(ke.line[ke.pos])||me.pos===null||ke.ln===me.ln&&ke.pos+1===me.pos))return me;ke.line!==""&&!m(ke.line[ke.pos])&&(be=!1,me={ln:ke.ln,pos:ke.pos}),B(Q,ke)}var Ne=Q.getLine(me.ln);me.pos=0;for(var Ie=0;Ie<Ne.length;++Ie)if(!m(Ne[Ie])){me.pos=Ie;break}return me}for(var Y={ln:E.line,pos:E.ch};C>0;)F<0?Y=V(y,Y.ln,Y.pos,F):Y=W(y,Y.ln,Y.pos,F),C--;return new De(Y.ln,Y.pos)}function Wn(y,E,C,F){var B=E,W,V,Y={"(":/[()]/,")":/[()]/,"[":/[[\]]/,"]":/[[\]]/,"{":/[{}]/,"}":/[{}]/,"<":/[<>]/,">":/[<>]/}[C],Q={"(":"(",")":"(","[":"[","]":"[","{":"{","}":"{","<":"<",">":"<"}[C],re=y.getLine(B.line).charAt(B.ch),le=re===Q?1:0;if(W=y.scanForBracket(new De(B.line,B.ch+le),-1,void 0,{bracketRegex:Y}),V=y.scanForBracket(new De(B.line,B.ch+le),1,void 0,{bracketRegex:Y}),!W||!V)return null;if(W=W.pos,V=V.pos,W.line==V.line&&W.ch>V.ch||W.line>V.line){var ye=W;W=V,V=ye}return F?V.ch+=1:W.ch+=1,{start:W,end:V}}function Ar(y,E,C,F){var B=Ke(E),W=y.getLine(B.line),V=W.split(""),Y,Q,re,le,ye=V.indexOf(C);if(B.ch<ye)B.ch=ye;else if(ye<B.ch&&V[B.ch]==C){var ke=/string/.test(y.getTokenTypeAt(ge(E,0,1))),me=/string/.test(y.getTokenTypeAt(E)),be=ke&&!me;be||(Q=B.ch,--B.ch)}if(V[B.ch]==C&&!Q)Y=B.ch+1;else for(re=B.ch;re>-1&&!Y;re--)V[re]==C&&(Y=re+1);if(Y&&!Q)for(re=Y,le=V.length;re<le&&!Q;re++)V[re]==C&&(Q=re);return!Y||!Q?{start:B,end:B}:(F&&(--Y,++Q),{start:new De(B.line,Y),end:new De(B.line,Q)})}function Qi(){}function _n(y){var E=y.state.vim;return E.searchState_||(E.searchState_=new Qi)}function Er(y){return Zi(y,"/")}function po(y){return Hs(y,"/")}function Zi(y,E){var C=Hs(y,E)||[];if(!C.length)return[];var F=[];if(C[0]===0){for(var B=0;B<C.length;B++)typeof C[B]=="number"&&F.push(y.substring(C[B]+1,C[B+1]));return F}}function Hs(y,E){E||(E="/");for(var C=!1,F=[],B=0;B<y.length;B++){var W=y.charAt(B);!C&&W==E&&F.push(B),C=!C&&W=="\\"}return F}function Ia(y){for(var E="|(){",C="}",F=!1,B=[],W=-1;W<y.length;W++){var V=y.charAt(W)||"",Y=y.charAt(W+1)||"",Q=Y&&E.indexOf(Y)!=-1;F?((V!=="\\"||!Q)&&B.push(V),F=!1):V==="\\"?(F=!0,Y&&C.indexOf(Y)!=-1&&(Q=!0),(!Q||Y==="\\")&&B.push(V)):(B.push(V),Q&&Y!=="\\"&&B.push("\\"))}return B.join("")}function Ll(y){for(var E=!1,C=[],F=-1;F<y.length;F++){var B=y.charAt(F)||"",W=y.charAt(F+1)||"";Mi[B+W]?(C.push(Mi[B+W]),F++):E?(C.push(B),E=!1):B==="\\"?(E=!0,i(W)||W==="$"?C.push("$"):W!=="/"&&W!=="\\"&&C.push("\\")):(B==="$"&&C.push("$"),C.push(B),W==="/"&&C.push("\\"))}return C.join("")}function Ol(y){for(var E=new Be.StringStream(y),C=[];!E.eol();){for(;E.peek()&&E.peek()!="\\";)C.push(E.next());var F=!1;for(var B in dr)if(E.match(B,!0)){F=!0,C.push(dr[B]);break}F||C.push(E.next())}return C.join("")}function Ji(y,E,C){var F=We.registerController.getRegister("/");if(F.setText(y),y instanceof RegExp)return y;var B=po(y),W,V;if(!B.length)W=y;else{W=y.substring(0,B[0]);var Y=y.substring(B[0]);V=Y.indexOf("i")!=-1}if(!W)return null;S("pcre")||(W=Ia(W)),C&&(E=/^[^A-Z]*$/.test(W));var Q=new RegExp(W,E||V?"im":"m");return Q}function fi(y){typeof y=="string"&&(y=document.createElement(y));for(var E,C=1;C<arguments.length;C++)if(E=arguments[C])if(typeof E!="object"&&(E=document.createTextNode(E)),E.nodeType)y.appendChild(E);else for(var F in E)Object.prototype.hasOwnProperty.call(E,F)&&(F[0]==="$"?y.style[F.slice(1)]=E[F]:y.setAttribute(F,E[F]));return y}function Ft(y,E){var C=fi("div",{$color:"red",$whiteSpace:"pre",class:"cm-vim-message"},E);y.openNotification?y.openNotification(C,{bottom:!0,duration:5e3}):alert(C.innerText)}function Na(y,E){return fi("div",{$display:"flex"},fi("span",{$fontFamily:"monospace",$whiteSpace:"pre",$flex:1},y,fi("input",{type:"text",autocorrect:"off",autocapitalize:"off",spellcheck:"false",$width:"100%"})),E&&fi("span",{$color:"#888"},E))}function Tr(y,E){if(jr.length){E.value||(E.value=""),mn=E;return}var C=Na(E.prefix,E.desc);if(y.openDialog)y.openDialog(C,E.onClose,{onKeyDown:E.onKeyDown,onKeyUp:E.onKeyUp,bottom:!0,selectValueOnOpen:!1,value:E.value});else{var F="";typeof E.prefix!="string"&&E.prefix&&(F+=E.prefix.textContent),E.desc&&(F+=" "+E.desc),E.onClose(prompt(F,""))}}function zn(y,E){if(y instanceof RegExp&&E instanceof RegExp){for(var C=["global","multiline","ignoreCase","source"],F=0;F<C.length;F++){var B=C[F];if(y[B]!==E[B])return!1}return!0}return!1}function hn(y,E,C,F){if(E){var B=_n(y),W=Ji(E,!!C,!!F);if(W)return Ci(y,W),zn(W,B.getQuery())||B.setQuery(W),W}}function Tn(y){if(y.source.charAt(0)=="^")var E=!0;return{token:function(C){if(E&&!C.sol()){C.skipToEnd();return}var F=C.match(y,!1);if(F)return F[0].length==0?(C.next(),"searching"):!C.sol()&&(C.backUp(1),!y.exec(C.next()+F[0]))?(C.next(),null):(C.match(y),"searching");for(;!C.eol()&&(C.next(),!C.match(y,!1)););},query:y}}function Ci(y,E){clearTimeout(fr);var C=_n(y);C.highlightTimeout=fr,fr=setTimeout(function(){if(y.state.vim){var F=_n(y);F.highlightTimeout=null;var B=F.getOverlay();(!B||E!=B.query)&&(B&&y.removeOverlay(B),B=Tn(E),y.addOverlay(B),y.showMatchesOnScrollbar&&(F.getScrollbarAnnotate()&&F.getScrollbarAnnotate().clear(),F.setScrollbarAnnotate(y.showMatchesOnScrollbar(E))),F.setOverlay(B))}},50)}function Rr(y,E,C,F){return F===void 0&&(F=1),y.operation(function(){for(var B=y.getCursor(),W=y.getSearchCursor(C,B),V=0;V<F;V++){var Y=W.find(E);if(V==0&&Y&&dt(W.from(),B)){var Q=E?W.from():W.to();Y=W.find(E),Y&&!Y[0]&&dt(W.from(),Q)&&y.getLine(Q.line).length==Q.ch&&(Y=W.find(E))}if(!Y&&(W=y.getSearchCursor(C,E?new De(y.lastLine()):new De(y.firstLine(),0)),!W.find(E)))return}return W.from()})}function $i(y,E,C,F,B){return F===void 0&&(F=1),y.operation(function(){var W=y.getCursor(),V=y.getSearchCursor(C,W),Y=V.find(!E);!B.visualMode&&Y&&dt(V.from(),W)&&V.find(!E);for(var Q=0;Q<F;Q++)if(Y=V.find(E),!Y&&(V=y.getSearchCursor(C,E?new De(y.lastLine()):new De(y.firstLine(),0)),!V.find(E)))return;return[V.from(),V.to()]})}function es(y){var E=_n(y);E.highlightTimeout&&(clearTimeout(E.highlightTimeout),E.highlightTimeout=null),y.removeOverlay(_n(y).getOverlay()),E.setOverlay(null),E.getScrollbarAnnotate()&&(E.getScrollbarAnnotate().clear(),E.setScrollbarAnnotate(null))}function Us(y,E,C){return typeof y!="number"&&(y=y.line),E instanceof Array?x(y,E):typeof C=="number"?y>=E&&y<=C:y==E}function go(y){var E=y.ace.renderer;return{top:E.getFirstFullyVisibleRow(),bottom:E.getLastFullyVisibleRow()}}function ti(y,E,C){if(C=="'"||C=="`")return We.jumpList.find(y,-1)||new De(0,0);if(C==".")return To(y);var F=E.marks[C];return F&&F.find()}function To(y){if(y.getLastEditEnd)return y.getLastEditEnd();for(var E=y.doc.history.done,C=E.length;C--;)if(E[C].changes)return Ke(E[C].changes[0].to)}function ts(y,E,C,F,B,W,V,Y,Q){function re(){y.operation(function(){for(;!Ne;)le(),ke();me()})}function le(){var Ye=y.getRange(W.from(),W.to()),tt=Ye.replace(V,Y),fn=W.to().line;W.replace(tt),He=W.to().line,B+=He-fn,st=He<fn}function ye(){var Ye=Ie&&Ke(W.to()),tt=W.findNext();return tt&&!tt[0]&&Ye&&dt(W.from(),Ye)&&(tt=W.findNext()),tt}function ke(){for(;ye()&&Us(W.from(),F,B);)if(!(!C&&W.from().line==He&&!st)){y.scrollIntoView(W.from(),30),y.setSelection(W.from(),W.to()),Ie=W.from(),Ne=!1;return}Ne=!0}function me(Ye){if(Ye&&Ye(),y.focus(),Ie){y.setCursor(Ie);var tt=y.state.vim;tt.exMode=!1,tt.lastHPos=tt.lastHSPos=Ie.ch}Q&&Q()}function be(Ye,tt,fn){Be.e_stop(Ye);var lt=z(Ye);switch(lt){case"y":le(),ke();break;case"n":ke();break;case"a":var yn=Q;Q=void 0,y.operation(re),Q=yn;break;case"l":le();case"q":case"<Esc>":case"<C-c>":case"<C-[>":me(fn)}return Ne&&me(fn),!0}y.state.vim.exMode=!0;var Ne=!1,Ie,He,st;if(ke(),Ne){Ft(y,"No matches for "+V.source);return}if(!E){re(),Q&&Q();return}Tr(y,{prefix:fi("span","replace with ",fi("strong",Y)," (y/n/a/q/l)"),onKeyDown:be})}function ni(y,E){var C=y.state.vim,F=We.macroModeState,B=We.registerController.getRegister("."),W=F.isPlaying,V=F.lastInsertModeChanges;W||(y.off("change",Ro),C.insertEnd&&C.insertEnd.clear(),C.insertEnd=null,Be.off(y.getInputField(),"keydown",Gs)),!W&&C.insertModeRepeat>1&&(Da(y,C,C.insertModeRepeat-1,!0),C.lastEditInputState.repeatOverride=C.insertModeRepeat),delete C.insertModeRepeat,C.insertMode=!1,E||y.setCursor(y.getCursor().line,y.getCursor().ch-1),y.setOption("keyMap","vim"),y.setOption("disableInput",!0),y.toggleOverwrite(!1),B.setText(V.changes.join("")),Be.signal(y,"vim-mode-change",{mode:"normal"}),F.isRecording&&sr(F)}function ns(y){Cn.unshift(y)}function qs(y,E,C,F,B){var W={keys:y,type:E};W[E]=C,W[E+"Args"]=F;for(var V in B)W[V]=B[V];ns(W)}function Vs(y,E,C,F){var B=We.registerController.getRegister(F);if(F==":"){B.keyBuffer[0]&&br.processCommand(y,B.keyBuffer[0]),C.isPlaying=!1;return}var W=B.keyBuffer,V=0;C.isPlaying=!0,C.replaySearchQueries=B.searchQueries.slice(0);for(var Y=0;Y<W.length;Y++)for(var Q=W[Y],re,le;Q;)if(re=/<\w+-.+?>|<\w+>|./.exec(Q),le=re[0],Q=Q.substring(re.index+le.length),mt.handleKey(y,le,"macro"),E.insertMode){var ye=B.insertModeChanges[V++].changes;We.macroModeState.lastInsertModeChanges.changes=ye,as(y,ye,1),ni(y)}C.isPlaying=!1}function rs(y,E){if(!y.isPlaying){var C=y.latestRegister,F=We.registerController.getRegister(C);F&&F.pushText(E)}}function sr(y){if(!y.isPlaying){var E=y.latestRegister,C=We.registerController.getRegister(E);C&&C.pushInsertModeChanges&&C.pushInsertModeChanges(y.lastInsertModeChanges)}}function Ks(y,E){if(!y.isPlaying){var C=y.latestRegister,F=We.registerController.getRegister(C);F&&F.pushSearchQuery&&F.pushSearchQuery(E)}}function Ro(y,E){var C=We.macroModeState,F=C.lastInsertModeChanges;if(!C.isPlaying)for(var B=y.state.vim;E;){if(F.expectCursorActivityForChange=!0,F.ignoreCount>1)F.ignoreCount--;else if(E.origin=="+input"||E.origin=="paste"||E.origin===void 0){var W=y.listSelections().length;W>1&&(F.ignoreCount=W);var V=E.text.join(`
|
|
1411
|
+
`);if(F.maybeReset&&(F.changes=[],F.maybeReset=!1),V)if(y.state.overwrite&&!/\n/.test(V))F.changes.push([V]);else{if(V.length>1){var Y=B&&B.insertEnd&&B.insertEnd.find(),Q=y.getCursor();if(Y&&Y.line==Q.line){var re=Y.ch-Q.ch;re>0&&re<V.length&&(F.changes.push([V,re]),V="")}}V&&F.changes.push(V)}}E=E.next}}function is(y){var E=y.state.vim;if(E.insertMode){var C=We.macroModeState;if(C.isPlaying)return;var F=C.lastInsertModeChanges;F.expectCursorActivityForChange?F.expectCursorActivityForChange=!1:(F.maybeReset=!0,E.insertEnd&&E.insertEnd.clear(),E.insertEnd=y.setBookmark(y.getCursor(),{insertLeft:!0}))}else y.curOp.isVimOp||os(y,E)}function os(y,E,C){var F=y.getCursor("anchor"),B=y.getCursor("head");if(E.visualMode&&!y.somethingSelected()?Sn(y,!1):!E.visualMode&&!E.insertMode&&y.somethingSelected()&&(E.visualMode=!0,E.visualLine=!1,Be.signal(y,"vim-mode-change",{mode:"visual"})),E.visualMode){var W=rt(B,F)?0:-1,V=rt(B,F)?-1:0;B=ge(B,0,W),F=ge(F,0,V),E.sel={anchor:F,head:B},di(y,E,"<",gt(B,F)),di(y,E,">",tn(B,F))}else!E.insertMode&&!C&&(E.lastHPos=y.getCursor().ch)}function mo(y,E){this.keyName=y,this.key=E.key,this.ctrlKey=E.ctrlKey,this.altKey=E.altKey,this.metaKey=E.metaKey,this.shiftKey=E.shiftKey}function Gs(y){var E=We.macroModeState,C=E.lastInsertModeChanges,F=Be.keyName?Be.keyName(y):y.key;F&&(F.indexOf("Delete")!=-1||F.indexOf("Backspace")!=-1)&&(C.maybeReset&&(C.changes=[],C.maybeReset=!1),C.changes.push(new mo(F,y)))}function Da(y,E,C,F){function B(){Y?Mn.processAction(y,E,E.lastEditActionCommand):Mn.evalInput(y,E)}function W(le){if(V.lastInsertModeChanges.changes.length>0){le=E.lastEditActionCommand?le:1;var ye=V.lastInsertModeChanges;as(y,ye.changes,le)}}var V=We.macroModeState;V.isPlaying=!0;var Y=!!E.lastEditActionCommand,Q=E.inputState;if(E.inputState=E.lastEditInputState,Y&&E.lastEditActionCommand.interlaceInsertRepeat)for(var re=0;re<C;re++)B(),W(1);else F||B(),W(C);E.inputState=Q,E.insertMode&&!F&&ni(y),V.isPlaying=!1}function ss(y,E){Be.lookupKey(E,"vim-insert",function(C){return typeof C=="string"?Be.commands[C](y):C(y),!0})}function as(y,E,C){var F=y.getCursor("head"),B=We.macroModeState.lastInsertModeChanges.visualBlock;B&&(Pr(y,F,B+1),C=y.listSelections().length,y.setCursor(F));for(var W=0;W<C;W++){B&&y.setCursor(ge(F,W,0));for(var V=0;V<E.length;V++){var Y=E[V];if(Y instanceof mo)ss(y,Y.keyName);else if(typeof Y=="string")y.replaceSelection(Y);else{var Q=y.getCursor(),re=ge(Q,0,Y[0].length-(Y[1]||0));y.replaceRange(Y[0],Q,Y[1]?Q:re),y.setCursor(re)}}}B&&y.setCursor(ge(F,0,1))}function Ys(y,E,C,F){E.length>1&&E[0]=="n"&&(E=E.replace("numpad","")),E=Mr[E]||E;var B="";if(C.ctrlKey&&(B+="C-"),C.altKey&&(B+="A-"),(B||E.length>1)&&C.shiftKey&&(B+="S-"),F&&!F.expectLiteralNext&&E.length==1){if(Hn.keymap&&E in Hn.keymap)(Hn.remapCtrl!==!1||!B)&&(E=Hn.keymap[E]);else if(E.charCodeAt(0)>255){var W=C.code&&C.code.slice(-1)||"";C.shiftKey||(W=W.toLowerCase()),W&&(E=W)}}return B+=E,B.length>1&&(B="<"+B+">"),B}function ls(y){var E=new y.constructor;return Object.keys(y).forEach(function(C){if(C!="insertEnd"){var F=y[C];Array.isArray(F)?F=F.slice():F&&typeof F=="object"&&F.constructor!=Object&&(F=ls(F)),E[C]=F}}),y.sel&&(E.sel={head:y.sel.head&&Ke(y.sel.head),anchor:y.sel.anchor&&Ke(y.sel.anchor)}),E}function Mo(y,E,C){var F=!1,B=mt.maybeInitVimState_(y),W=B.visualBlock||B.wasInVisualBlock,V=y.ace.inMultiSelectMode;if(B.wasInVisualBlock&&!V?B.wasInVisualBlock=!1:V&&B.visualBlock&&(B.wasInVisualBlock=!0),E=="<Esc>"&&!B.insertMode&&!B.visualMode&&V)y.ace.exitMultiSelectMode();else if(W||!V||y.ace.inVirtualSelectionMode)F=mt.handleKey(y,E,C);else{var Y=ls(B),Q=B.inputState.changeQueueList||[];y.operation(function(){y.curOp.isVimOp=!0;var re=0;y.ace.forEachSelection(function(){var le=y.ace.selection;y.state.vim.lastHPos=le.$desiredColumn==null?le.lead.column:le.$desiredColumn,y.state.vim.inputState.changeQueue=Q[re];var ye=y.getCursor("head"),ke=y.getCursor("anchor"),me=rt(ye,ke)?0:-1,be=rt(ye,ke)?-1:0;ye=ge(ye,0,me),ke=ge(ke,0,be),y.state.vim.sel.head=ye,y.state.vim.sel.anchor=ke,F=vi(y,E,C),le.$desiredColumn=y.state.vim.lastHPos==-1?null:y.state.vim.lastHPos,y.ace.inVirtualSelectionMode&&(Q[re]=y.state.vim.inputState.changeQueue),y.virtualSelectionMode()&&(y.state.vim=ls(Y)),re++}),y.curOp.cursorActivity&&!F&&(y.curOp.cursorActivity=!1),B.status=y.state.vim.status,y.state.vim=B,B.inputState.changeQueueList=Q,B.inputState.changeQueue=null},!0)}return F&&!B.visualMode&&!B.insert&&B.visualMode!=y.somethingSelected()&&os(y,B,!0),F}function Ai(y,E){E.off("beforeEndOperation",Ai);var C=E.state.cm.vimCmd;C&&E.execCommand(C.exec?C:C.name,C.args),E.curOp=E.prevOp}var ar=t("../range").Range,vo=t("../lib/event_emitter").EventEmitter,eo=t("../lib/dom"),Fa=t("../lib/oop"),Il=t("../lib/keys"),Lo=t("../lib/event"),to=t("../search").Search,Oo=t("../lib/useragent"),cs=t("../search_highlight").SearchHighlight,Io=t("../commands/multi_select_commands"),Pa=t("../mode/text").Mode.prototype.tokenRe,yo=t("../ext/hardwrap").hardWrap;t("../multi_select");var Be=function(y){this.ace=y,this.state={},this.marks={},this.options={},this.$uid=0,this.onChange=this.onChange.bind(this),this.onSelectionChange=this.onSelectionChange.bind(this),this.onBeforeEndOperation=this.onBeforeEndOperation.bind(this),this.ace.on("change",this.onChange),this.ace.on("changeSelection",this.onSelectionChange),this.ace.on("beforeEndOperation",this.onBeforeEndOperation)};Be.Pos=function(y,E){if(!(this instanceof De))return new De(y,E);this.line=y,this.ch=E},Be.defineOption=function(y,E,C){},Be.commands={redo:function(y){y.ace.redo()},undo:function(y){y.ace.undo()},newlineAndIndent:function(y){y.ace.insert(`
|
|
1412
|
+
`)},goLineLeft:function(y){y.ace.selection.moveCursorLineStart()},goLineRight:function(y){y.ace.selection.moveCursorLineEnd()}},Be.keyMap={},Be.addClass=Be.rmClass=function(){},Be.e_stop=Be.e_preventDefault=Lo.stopEvent,Be.keyName=function(y){var E=Il[y.keyCode]||y.key||"";return E.length==1&&(E=E.toUpperCase()),E=Lo.getModifierString(y).replace(/(^|-)\w/g,function(C){return C.toUpperCase()})+E,E},Be.keyMap.default=function(y){return function(E){var C=E.ace.commands.commandKeyBinding[y.toLowerCase()];return C&&E.ace.execCommand(C)!==!1}},Be.lookupKey=function y(E,C,F){C||(C="default"),typeof C=="string"&&(C=Be.keyMap[C]||Be.keyMap.default);var B=typeof C=="function"?C(E):C[E];if(B===!1)return"nothing";if(B==="...")return"multi";if(B!=null&&F(B))return"handled";if(C.fallthrough){if(!Array.isArray(C.fallthrough))return y(E,C.fallthrough,F);for(var W=0;W<C.fallthrough.length;W++){var V=y(E,C.fallthrough[W],F);if(V)return V}}},Be.findMatchingTag=function(y,E){return y.findMatchingTag(E)},Be.findEnclosingTag=function(y,E){},Be.signal=function(y,E,C){return y._signal(E,C)},Be.on=Lo.addListener,Be.off=Lo.removeListener,Be.isWordChar=function(y){return y<""?/^\w$/.test(y):(Pa.lastIndex=0,Pa.test(y))},(function(){Fa.implement(Be.prototype,vo),this.destroy=function(){this.ace.off("change",this.onChange),this.ace.off("changeSelection",this.onSelectionChange),this.ace.off("beforeEndOperation",this.onBeforeEndOperation),this.removeOverlay()},this.virtualSelectionMode=function(){return this.ace.inVirtualSelectionMode&&this.ace.selection.index},this.onChange=function(C){this.$lineHandleChanges&&this.$lineHandleChanges.push(C);var F={text:C.action[0]=="i"?C.lines:[]},B=this.curOp=this.curOp||{};B.changeHandlers||(B.changeHandlers=this._eventRegistry.change&&this._eventRegistry.change.slice()),B.lastChange?B.lastChange.next=B.lastChange=F:B.lastChange=B.change=F,this.$updateMarkers(C)},this.onSelectionChange=function(){var C=this.curOp=this.curOp||{};C.cursorActivityHandlers||(C.cursorActivityHandlers=this._eventRegistry.cursorActivity&&this._eventRegistry.cursorActivity.slice()),this.curOp.cursorActivity=!0,this.ace.inMultiSelectMode&&this.ace.keyBinding.removeKeyboardHandler(Io.keyboardHandler)},this.operation=function(C,F){if(!F&&this.curOp||F&&this.curOp&&this.curOp.force)return C();if((F||!this.ace.curOp)&&this.curOp&&this.onBeforeEndOperation(),!this.ace.curOp){var B=this.ace.prevOp;this.ace.startOperation({command:{name:"vim",scrollIntoView:"cursor"}})}var W=this.curOp=this.curOp||{};this.curOp.force=F;var V=C();return this.ace.curOp&&this.ace.curOp.command.name=="vim"&&(this.state.dialog&&(this.ace.curOp.command.scrollIntoView=this.ace.curOp.vimDialogScroll),this.ace.endOperation(),!W.cursorActivity&&!W.lastChange&&B&&(this.ace.prevOp=B)),(F||!this.ace.curOp)&&this.curOp&&this.onBeforeEndOperation(),V},this.onBeforeEndOperation=function(){var C=this.curOp;C&&(C.change&&this.signal("change",C.change,C),C&&C.cursorActivity&&this.signal("cursorActivity",null,C),this.curOp=null)},this.signal=function(C,F,B){var W=B?B[C+"Handlers"]:(this._eventRegistry||{})[C];if(W){W=W.slice();for(var V=0;V<W.length;V++)W[V](this,F)}},this.firstLine=function(){return 0},this.lastLine=function(){return this.ace.session.getLength()-1},this.lineCount=function(){return this.ace.session.getLength()},this.setCursor=function(C,F){typeof C=="object"&&(F=C.ch,C=C.line);var B=!this.curOp&&!this.ace.inVirtualSelectionMode;this.ace.inVirtualSelectionMode||this.ace.exitMultiSelectMode(),this.ace.session.unfold({row:C,column:F}),this.ace.selection.moveTo(C,F),B&&(this.ace.renderer.scrollCursorIntoView(),this.ace.endOperation())},this.getCursor=function(C){var F=this.ace.selection,B=C=="anchor"?F.isEmpty()?F.lead:F.anchor:C=="head"||!C?F.lead:F.getRange()[C];return h(B)},this.listSelections=function(C){var F=this.ace.multiSelect.rangeList.ranges;return!F.length||this.ace.inVirtualSelectionMode?[{anchor:this.getCursor("anchor"),head:this.getCursor("head")}]:F.map(function(B){return{anchor:this.clipPos(h(B.cursor==B.end?B.start:B.end)),head:this.clipPos(h(B.cursor))}},this)},this.setSelections=function(C,F){var B=this.ace.multiSelect,W=C.map(function(re){var le=d(re.anchor),ye=d(re.head),ke=ar.comparePoints(le,ye)<0?new ar.fromPoints(le,ye):new ar.fromPoints(ye,le);return ke.cursor=ar.comparePoints(ke.start,ye)?ke.end:ke.start,ke});if(this.ace.inVirtualSelectionMode){this.ace.selection.fromOrientedRange(W[0]);return}F?W[F]&&W.push(W.splice(F,1)[0]):W=W.reverse(),B.toSingleRange(W[0].clone());for(var V=this.ace.session,Y=0;Y<W.length;Y++){var Q=V.$clipRangeToDocument(W[Y]);B.addRange(Q)}},this.setSelection=function(C,F,B){var W=this.ace.selection;W.moveTo(C.line,C.ch),W.selectTo(F.line,F.ch),B&&B.origin=="*mouse"&&this.onBeforeEndOperation()},this.somethingSelected=function(C){return!this.ace.selection.isEmpty()},this.clipPos=function(C){var F=this.ace.session.$clipPositionToDocument(C.line,C.ch);return h(F)},this.foldCode=function(C){this.ace.session.$toggleFoldWidget(C.line,{})},this.markText=function(C){return{clear:function(){},find:function(){}}},this.$updateMarkers=function(C){var F=C.action=="insert",B=C.start,W=C.end,V=(W.row-B.row)*(F?1:-1),Y=(W.column-B.column)*(F?1:-1);F&&(W=B);for(var Q in this.marks){var re=this.marks[Q],le=ar.comparePoints(re,B);if(!(le<0)){if(le===0&&F)if(!re.$insertRight)le=1;else{if(re.bias!=1){re.bias=-1;continue}le=1}var ye=F?le:ar.comparePoints(re,W);if(ye>0){re.row+=V,re.column+=re.row==W.row?Y:0;continue}!F&&ye<=0&&(re.row=B.row,re.column=B.column,ye===0&&(re.bias=1))}}};var y=function(C,F,B,W){this.cm=C,this.id=F,this.row=B,this.column=W,C.marks[this.id]=this};y.prototype.clear=function(){delete this.cm.marks[this.id]},y.prototype.find=function(){return h(this)},this.setBookmark=function(C,F){var B=new y(this,this.$uid++,C.line,C.ch);return(!F||!F.insertLeft)&&(B.$insertRight=!0),this.marks[B.id]=B,B},this.moveH=function(C,F){if(F=="char"){var B=this.ace.selection;B.clearSelection(),B.moveCursorBy(0,C)}},this.findPosV=function(C,F,B,W){if(B=="page"){var V=this.ace.renderer,Y=V.layerConfig;F*=Math.floor(Y.height/Y.lineHeight),B="line"}if(B=="line"){var Q=this.ace.session.documentToScreenPosition(C.line,C.ch);W!=null&&(Q.column=W),Q.row+=F,Q.row=Math.min(Math.max(0,Q.row),this.ace.session.getScreenLength()-1);var re=this.ace.session.screenToDocumentPosition(Q.row,Q.column);return h(re)}debugger},this.charCoords=function(C,F){if(F=="div"||!F){var B=this.ace.session.documentToScreenPosition(C.line,C.ch);return{left:B.column,top:B.row}}if(F=="local"){var W=this.ace.renderer,B=this.ace.session.documentToScreenPosition(C.line,C.ch),V=W.layerConfig.lineHeight,Y=W.layerConfig.characterWidth,Q=V*B.row;return{left:B.column*Y,top:Q,bottom:Q+V}}},this.coordsChar=function(C,F){var B=this.ace.renderer;if(F=="local"){var W=Math.max(0,Math.floor(C.top/B.lineHeight)),V=Math.max(0,Math.floor(C.left/B.characterWidth)),Y=B.session.screenToDocumentPosition(W,V);return h(Y)}if(F=="div")throw"not implemented"},this.getSearchCursor=function(C,F,B){var W=!1,V=!1;C instanceof RegExp&&!C.global&&(W=!C.ignoreCase,C=C.source,V=!0),C=="\\n"&&(C=`
|
|
1413
|
+
`,V=!1);var Y=new to;F.ch==null&&(F.ch=Number.MAX_VALUE);var Q={row:F.line,column:F.ch},re=this,le=null;return{findNext:function(){return this.find(!1)},findPrevious:function(){return this.find(!0)},find:function(ye){Y.setOptions({needle:C,caseSensitive:W,wrap:!1,backwards:ye,regExp:V,start:le||Q});var ke=Y.find(re.ace.session);return le=ke,le&&[!le.isEmpty()]},from:function(){return le&&h(le.start)},to:function(){return le&&h(le.end)},replace:function(ye){le&&(le.end=re.ace.session.doc.replace(le,ye))}}},this.scrollTo=function(C,F){var B=this.ace.renderer,W=B.layerConfig,V=W.maxHeight;V-=(B.$size.scrollerHeight-B.lineHeight)*B.$scrollPastEnd,F!=null&&this.ace.session.setScrollTop(Math.max(0,Math.min(F,V))),C!=null&&this.ace.session.setScrollLeft(Math.max(0,Math.min(C,W.width)))},this.scrollInfo=function(){return 0},this.scrollIntoView=function(C,F){if(C){var B=this.ace.renderer,W={top:0,bottom:F};B.scrollCursorIntoView(d(C),B.lineHeight*2/B.$size.scrollerHeight,W)}},this.getLine=function(C){return this.ace.session.getLine(C)},this.getRange=function(C,F){return this.ace.session.getTextRange(new ar(C.line,C.ch,F.line,F.ch))},this.replaceRange=function(C,F,B){B||(B=F);var W=new ar(F.line,F.ch,B.line,B.ch);return this.ace.session.$clipRangeToDocument(W),this.ace.session.replace(W,C)},this.replaceSelection=this.replaceSelections=function(C){var F=Array.isArray(C)&&C,B=this.ace.selection;if(this.ace.inVirtualSelectionMode){this.ace.session.replace(B.getRange(),F?C[0]||"":C);return}B.inVirtualSelectionMode=!0;var W=B.rangeList.ranges;W.length||(W=[this.ace.multiSelect.getRange()]);for(var V=W.length;V--;)this.ace.session.replace(W[V],F?C[V]||"":C);B.inVirtualSelectionMode=!1},this.getSelection=function(){return this.ace.getSelectedText()},this.getSelections=function(){return this.listSelections().map(function(C){return this.getRange(C.anchor,C.head)},this)},this.getInputField=function(){return this.ace.textInput.getElement()},this.getWrapperElement=function(){return this.ace.container};var E={indentWithTabs:"useSoftTabs",indentUnit:"tabSize",tabSize:"tabSize",firstLineNumber:"firstLineNumber",readOnly:"readOnly"};this.setOption=function(C,F){switch(this.state[C]=F,C){case"indentWithTabs":C=E[C],F=!F;break;case"keyMap":this.state.$keyMap=F;return;default:C=E[C]}C&&this.ace.setOption(C,F)},this.getOption=function(C){var F,B=E[C];switch(B&&(F=this.ace.getOption(B)),C){case"indentWithTabs":return C=E[C],!F;case"keyMap":return this.state.$keyMap||"vim"}return B?F:this.state[C]},this.toggleOverwrite=function(C){return this.state.overwrite=C,this.ace.setOverwrite(C)},this.addOverlay=function(C){if(!this.$searchHighlight||!this.$searchHighlight.session){var F=new cs(null,"ace_highlight-marker","text"),B=this.ace.session.addDynamicMarker(F);F.id=B.id,F.session=this.ace.session,F.destroy=function(V){F.session.off("change",F.updateOnChange),F.session.off("changeEditor",F.destroy),F.session.removeMarker(F.id),F.session=null},F.updateOnChange=function(V){var Y=V.start.row;Y==V.end.row?F.cache[Y]=void 0:F.cache.splice(Y,F.cache.length)},F.session.on("changeEditor",F.destroy),F.session.on("change",F.updateOnChange)}var W=new RegExp(C.query.source,"gmi");this.$searchHighlight=C.highlight=F,this.$searchHighlight.setRegexp(W),this.ace.renderer.updateBackMarkers()},this.removeOverlay=function(C){this.$searchHighlight&&this.$searchHighlight.session&&this.$searchHighlight.destroy()},this.getScrollInfo=function(){var C=this.ace.renderer,F=C.layerConfig;return{left:C.scrollLeft,top:C.scrollTop,height:F.maxHeight,width:F.width,clientHeight:F.height,clientWidth:F.width}},this.getValue=function(){return this.ace.getValue()},this.setValue=function(C){return this.ace.setValue(C,-1)},this.getTokenTypeAt=function(C){var F=this.ace.session.getTokenAt(C.line,C.ch);return F&&/comment|string/.test(F.type)?"string":""},this.findMatchingBracket=function(C){var F=this.ace.session.findMatchingBracket(d(C));return{to:F&&h(F)}},this.findMatchingTag=function(C){var F=this.ace.session.getMatchingTags(d(C));if(F)return{open:{from:h(F.openTag.start),to:h(F.openTag.end)},close:{from:h(F.closeTag.start),to:h(F.closeTag.end)}}},this.indentLine=function(C,F){F===!0?this.ace.session.indentRows(C,C," "):F===!1&&this.ace.session.outdentRows(new ar(C,0,C,0))},this.indexFromPos=function(C){return this.ace.session.doc.positionToIndex(d(C))},this.posFromIndex=function(C){return h(this.ace.session.doc.indexToPosition(C))},this.focus=function(C){return this.ace.textInput.focus()},this.blur=function(C){return this.ace.blur()},this.defaultTextHeight=function(C){return this.ace.renderer.layerConfig.lineHeight},this.scanForBracket=function(C,F,B,W){var V=W.bracketRegex.source,Y=/paren|text|operator|tag/;if(F==1)var Q=this.ace.session.$findClosingBracket(V.slice(1,2),d(C),Y);else{var Q=this.ace.session.$findOpeningBracket(V.slice(-2,-1),{row:C.line,column:C.ch+1},Y);!Q&&W.bracketRegex&&W.bracketRegex.test(this.getLine(C.line)[C.ch-1])&&(Q={row:C.line,column:C.ch-1})}return Q&&{pos:h(Q)}},this.refresh=function(){return this.ace.resize(!0)},this.getMode=function(){return{name:this.getOption("mode")}},this.execCommand=function(C){if(Be.commands.hasOwnProperty(C))return Be.commands[C](this);if(C=="indentAuto")return this.ace.execCommand("autoindent");console.log(C+" is not implemented")},this.getLineNumber=function(C){var F=this.$lineHandleChanges;if(!F)return null;for(var B=C.row,W=0;W<F.length;W++){var V=F[W];if(V.start.row!=V.end.row){if(V.action[0]=="i")V.start.row<B&&(B+=V.end.row-V.start.row);else if(V.start.row<B){if(B<V.end.row||B==V.end.row&&V.start.column>0)return null;B-=V.end.row-V.start.row}}}return B},this.getLineHandle=function(C){return this.$lineHandleChanges||(this.$lineHandleChanges=[]),{text:this.ace.session.getLine(C),row:C}},this.releaseLineHandles=function(){this.$lineHandleChanges=void 0},this.getLastEditEnd=function(){var C=this.ace.session.$undoManager;if(C&&C.$lastDelta)return h(C.$lastDelta.end)}}).call(Be.prototype);var Ba=Be.StringStream=function(y,E){this.pos=this.start=0,this.string=y,this.tabSize=E||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0};Ba.prototype={eol:function(){return this.pos>=this.string.length},sol:function(){return this.pos==this.lineStart},peek:function(){return this.string.charAt(this.pos)||void 0},next:function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},eat:function(y){var E=this.string.charAt(this.pos);if(typeof y=="string")var C=E==y;else var C=E&&(y.test?y.test(E):y(E));if(C)return++this.pos,E},eatWhile:function(y){for(var E=this.pos;this.eat(y););return this.pos>E},eatSpace:function(){for(var y=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>y},skipToEnd:function(){this.pos=this.string.length},skipTo:function(y){var E=this.string.indexOf(y,this.pos);if(E>-1)return this.pos=E,!0},backUp:function(y){this.pos-=y},column:function(){throw"not implemented"},indentation:function(){throw"not implemented"},match:function(y,E,C){if(typeof y!="string"){var F=this.string.slice(this.pos).match(y);return F&&F.index>0?null:(F&&E!==!1&&(this.pos+=F[0].length),F)}var B=function(V){return C?V.toLowerCase():V},W=this.string.substr(this.pos,y.length);if(B(W)==B(y))return E!==!1&&(this.pos+=y.length),!0},current:function(){return this.string.slice(this.start,this.pos)},hideFirstChars:function(y,E){this.lineStart+=y;try{return E()}finally{this.lineStart-=y}}},Be.defineExtension=function(y,E){Be.prototype[y]=E},eo.importCssString(`.normal-mode .ace_cursor{
|
|
1414
|
+
border: none;
|
|
1415
|
+
background-color: rgba(255,0,0,0.5);
|
|
1416
|
+
}
|
|
1417
|
+
.normal-mode .ace_hidden-cursors .ace_cursor{
|
|
1418
|
+
background-color: transparent;
|
|
1419
|
+
border: 1px solid red;
|
|
1420
|
+
opacity: 0.7
|
|
1421
|
+
}
|
|
1422
|
+
.ace_dialog {
|
|
1423
|
+
position: absolute;
|
|
1424
|
+
left: 0; right: 0;
|
|
1425
|
+
background: inherit;
|
|
1426
|
+
z-index: 15;
|
|
1427
|
+
padding: .1em .8em;
|
|
1428
|
+
overflow: hidden;
|
|
1429
|
+
color: inherit;
|
|
1430
|
+
}
|
|
1431
|
+
.ace_dialog-top {
|
|
1432
|
+
border-bottom: 1px solid #444;
|
|
1433
|
+
top: 0;
|
|
1434
|
+
}
|
|
1435
|
+
.ace_dialog-bottom {
|
|
1436
|
+
border-top: 1px solid #444;
|
|
1437
|
+
bottom: 0;
|
|
1438
|
+
}
|
|
1439
|
+
.ace_dialog input {
|
|
1440
|
+
border: none;
|
|
1441
|
+
outline: none;
|
|
1442
|
+
background: transparent;
|
|
1443
|
+
width: 20em;
|
|
1444
|
+
color: inherit;
|
|
1445
|
+
font-family: monospace;
|
|
1446
|
+
}`,"vimMode",!1),function(){function y(C,F,B){var W=C.ace.container,V;return V=W.appendChild(document.createElement("div")),B?V.className="ace_dialog ace_dialog-bottom":V.className="ace_dialog ace_dialog-top",typeof F=="string"?V.innerHTML=F:V.appendChild(F),V}function E(C,F){C.state.currentNotificationClose&&C.state.currentNotificationClose(),C.state.currentNotificationClose=F}Be.defineExtension("openDialog",function(C,F,B){function W(ye){if(typeof ye=="string")re.value=ye;else{if(Y||ye&&ye.type=="blur"&&document.activeElement===re)return;Q.state.dialog==V&&(Q.state.dialog=null,Q.focus()),Y=!0,V.remove(),B.onClose&&B.onClose(V);var ke=Q;ke.state.vim&&(ke.state.vim.status=null,ke.ace._signal("changeStatus"),ke.ace.renderer.$loop.schedule(ke.ace.renderer.CHANGE_CURSOR))}}if(!this.virtualSelectionMode()){B||(B={}),E(this,null);var V=y(this,C,B.bottom),Y=!1,Q=this;this.state.dialog=V;var re=V.getElementsByTagName("input")[0],le;return re?(B.value&&(re.value=B.value,B.selectValueOnOpen!==!1&&re.select()),B.onInput&&Be.on(re,"input",function(ye){B.onInput(ye,re.value,W)}),B.onKeyUp&&Be.on(re,"keyup",function(ye){B.onKeyUp(ye,re.value,W)}),Be.on(re,"keydown",function(ye){B&&B.onKeyDown&&B.onKeyDown(ye,re.value,W)||(ye.keyCode==13&&F(re.value),(ye.keyCode==27||B.closeOnEnter!==!1&&ye.keyCode==13)&&(Be.e_stop(ye),W()))}),B.closeOnBlur!==!1&&Be.on(re,"blur",W),re.focus()):(le=V.getElementsByTagName("button")[0])&&(Be.on(le,"click",function(){W(),Q.focus()}),B.closeOnBlur!==!1&&Be.on(le,"blur",W),le.focus()),W}}),Be.defineExtension("openNotification",function(C,F){function B(){V||(V=!0,clearTimeout(Y),W.remove())}if(!this.virtualSelectionMode()){E(this,B);var W=y(this,C,F&&F.bottom),V=!1,Y,Q=F&&typeof F.duration<"u"?F.duration:5e3;return Be.on(W,"click",function(re){Be.e_preventDefault(re),B()}),Q&&(Y=setTimeout(B,Q)),B}})}();var De=Be.Pos,Cn=[{keys:"<Left>",type:"keyToKey",toKeys:"h"},{keys:"<Right>",type:"keyToKey",toKeys:"l"},{keys:"<Up>",type:"keyToKey",toKeys:"k"},{keys:"<Down>",type:"keyToKey",toKeys:"j"},{keys:"g<Up>",type:"keyToKey",toKeys:"gk"},{keys:"g<Down>",type:"keyToKey",toKeys:"gj"},{keys:"<Space>",type:"keyToKey",toKeys:"l"},{keys:"<BS>",type:"keyToKey",toKeys:"h"},{keys:"<Del>",type:"keyToKey",toKeys:"x"},{keys:"<C-Space>",type:"keyToKey",toKeys:"W"},{keys:"<C-BS>",type:"keyToKey",toKeys:"B"},{keys:"<S-Space>",type:"keyToKey",toKeys:"w"},{keys:"<S-BS>",type:"keyToKey",toKeys:"b"},{keys:"<C-n>",type:"keyToKey",toKeys:"j"},{keys:"<C-p>",type:"keyToKey",toKeys:"k"},{keys:"<C-[>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-c>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-[>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"<C-c>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"<C-Esc>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-Esc>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"s",type:"keyToKey",toKeys:"cl",context:"normal"},{keys:"s",type:"keyToKey",toKeys:"c",context:"visual"},{keys:"S",type:"keyToKey",toKeys:"cc",context:"normal"},{keys:"S",type:"keyToKey",toKeys:"VdO",context:"visual"},{keys:"<Home>",type:"keyToKey",toKeys:"0"},{keys:"<End>",type:"keyToKey",toKeys:"$"},{keys:"<PageUp>",type:"keyToKey",toKeys:"<C-b>"},{keys:"<PageDown>",type:"keyToKey",toKeys:"<C-f>"},{keys:"<CR>",type:"keyToKey",toKeys:"j^",context:"normal"},{keys:"<Ins>",type:"keyToKey",toKeys:"i",context:"normal"},{keys:"<Ins>",type:"action",action:"toggleOverwrite",context:"insert"},{keys:"H",type:"motion",motion:"moveToTopLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"M",type:"motion",motion:"moveToMiddleLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"L",type:"motion",motion:"moveToBottomLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"h",type:"motion",motion:"moveByCharacters",motionArgs:{forward:!1}},{keys:"l",type:"motion",motion:"moveByCharacters",motionArgs:{forward:!0}},{keys:"j",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,linewise:!0}},{keys:"k",type:"motion",motion:"moveByLines",motionArgs:{forward:!1,linewise:!0}},{keys:"gj",type:"motion",motion:"moveByDisplayLines",motionArgs:{forward:!0}},{keys:"gk",type:"motion",motion:"moveByDisplayLines",motionArgs:{forward:!1}},{keys:"w",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!1}},{keys:"W",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!1,bigWord:!0}},{keys:"e",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!0,inclusive:!0}},{keys:"E",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!0,bigWord:!0,inclusive:!0}},{keys:"b",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1}},{keys:"B",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1,bigWord:!0}},{keys:"ge",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!0,inclusive:!0}},{keys:"gE",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!0,bigWord:!0,inclusive:!0}},{keys:"{",type:"motion",motion:"moveByParagraph",motionArgs:{forward:!1,toJumplist:!0}},{keys:"}",type:"motion",motion:"moveByParagraph",motionArgs:{forward:!0,toJumplist:!0}},{keys:"(",type:"motion",motion:"moveBySentence",motionArgs:{forward:!1}},{keys:")",type:"motion",motion:"moveBySentence",motionArgs:{forward:!0}},{keys:"<C-f>",type:"motion",motion:"moveByPage",motionArgs:{forward:!0}},{keys:"<C-b>",type:"motion",motion:"moveByPage",motionArgs:{forward:!1}},{keys:"<C-d>",type:"motion",motion:"moveByScroll",motionArgs:{forward:!0,explicitRepeat:!0}},{keys:"<C-u>",type:"motion",motion:"moveByScroll",motionArgs:{forward:!1,explicitRepeat:!0}},{keys:"gg",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0,toJumplist:!0}},{keys:"G",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!0,explicitRepeat:!0,linewise:!0,toJumplist:!0}},{keys:"g$",type:"motion",motion:"moveToEndOfDisplayLine"},{keys:"g^",type:"motion",motion:"moveToStartOfDisplayLine"},{keys:"g0",type:"motion",motion:"moveToStartOfDisplayLine"},{keys:"0",type:"motion",motion:"moveToStartOfLine"},{keys:"^",type:"motion",motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"+",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,toFirstChar:!0}},{keys:"-",type:"motion",motion:"moveByLines",motionArgs:{forward:!1,toFirstChar:!0}},{keys:"_",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,toFirstChar:!0,repeatOffset:-1}},{keys:"$",type:"motion",motion:"moveToEol",motionArgs:{inclusive:!0}},{keys:"%",type:"motion",motion:"moveToMatchedSymbol",motionArgs:{inclusive:!0,toJumplist:!0}},{keys:"f<character>",type:"motion",motion:"moveToCharacter",motionArgs:{forward:!0,inclusive:!0}},{keys:"F<character>",type:"motion",motion:"moveToCharacter",motionArgs:{forward:!1}},{keys:"t<character>",type:"motion",motion:"moveTillCharacter",motionArgs:{forward:!0,inclusive:!0}},{keys:"T<character>",type:"motion",motion:"moveTillCharacter",motionArgs:{forward:!1}},{keys:";",type:"motion",motion:"repeatLastCharacterSearch",motionArgs:{forward:!0}},{keys:",",type:"motion",motion:"repeatLastCharacterSearch",motionArgs:{forward:!1}},{keys:"'<register>",type:"motion",motion:"goToMark",motionArgs:{toJumplist:!0,linewise:!0}},{keys:"`<register>",type:"motion",motion:"goToMark",motionArgs:{toJumplist:!0}},{keys:"]`",type:"motion",motion:"jumpToMark",motionArgs:{forward:!0}},{keys:"[`",type:"motion",motion:"jumpToMark",motionArgs:{forward:!1}},{keys:"]'",type:"motion",motion:"jumpToMark",motionArgs:{forward:!0,linewise:!0}},{keys:"['",type:"motion",motion:"jumpToMark",motionArgs:{forward:!1,linewise:!0}},{keys:"]p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!0,isEdit:!0,matchIndent:!0}},{keys:"[p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!1,isEdit:!0,matchIndent:!0}},{keys:"]<character>",type:"motion",motion:"moveToSymbol",motionArgs:{forward:!0,toJumplist:!0}},{keys:"[<character>",type:"motion",motion:"moveToSymbol",motionArgs:{forward:!1,toJumplist:!0}},{keys:"|",type:"motion",motion:"moveToColumn"},{keys:"o",type:"motion",motion:"moveToOtherHighlightedEnd",context:"visual"},{keys:"O",type:"motion",motion:"moveToOtherHighlightedEnd",motionArgs:{sameLine:!0},context:"visual"},{keys:"d",type:"operator",operator:"delete"},{keys:"y",type:"operator",operator:"yank"},{keys:"c",type:"operator",operator:"change"},{keys:"=",type:"operator",operator:"indentAuto"},{keys:">",type:"operator",operator:"indent",operatorArgs:{indentRight:!0}},{keys:"<",type:"operator",operator:"indent",operatorArgs:{indentRight:!1}},{keys:"g~",type:"operator",operator:"changeCase"},{keys:"gu",type:"operator",operator:"changeCase",operatorArgs:{toLower:!0},isEdit:!0},{keys:"gU",type:"operator",operator:"changeCase",operatorArgs:{toLower:!1},isEdit:!0},{keys:"n",type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:!0}},{keys:"N",type:"motion",motion:"findNext",motionArgs:{forward:!1,toJumplist:!0}},{keys:"gn",type:"motion",motion:"findAndSelectNextInclusive",motionArgs:{forward:!0}},{keys:"gN",type:"motion",motion:"findAndSelectNextInclusive",motionArgs:{forward:!1}},{keys:"gq",type:"operator",operator:"hardWrap"},{keys:"gw",type:"operator",operator:"hardWrap",operatorArgs:{keepCursor:!0}},{keys:"x",type:"operatorMotion",operator:"delete",motion:"moveByCharacters",motionArgs:{forward:!0},operatorMotionArgs:{visualLine:!1}},{keys:"X",type:"operatorMotion",operator:"delete",motion:"moveByCharacters",motionArgs:{forward:!1},operatorMotionArgs:{visualLine:!0}},{keys:"D",type:"operatorMotion",operator:"delete",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"D",type:"operator",operator:"delete",operatorArgs:{linewise:!0},context:"visual"},{keys:"Y",type:"operatorMotion",operator:"yank",motion:"expandToLine",motionArgs:{linewise:!0},context:"normal"},{keys:"Y",type:"operator",operator:"yank",operatorArgs:{linewise:!0},context:"visual"},{keys:"C",type:"operatorMotion",operator:"change",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"C",type:"operator",operator:"change",operatorArgs:{linewise:!0},context:"visual"},{keys:"~",type:"operatorMotion",operator:"changeCase",motion:"moveByCharacters",motionArgs:{forward:!0},operatorArgs:{shouldMoveCursor:!0},context:"normal"},{keys:"~",type:"operator",operator:"changeCase",context:"visual"},{keys:"<C-u>",type:"operatorMotion",operator:"delete",motion:"moveToStartOfLine",context:"insert"},{keys:"<C-w>",type:"operatorMotion",operator:"delete",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1},context:"insert"},{keys:"<C-w>",type:"idle",context:"normal"},{keys:"<C-i>",type:"action",action:"jumpListWalk",actionArgs:{forward:!0}},{keys:"<C-o>",type:"action",action:"jumpListWalk",actionArgs:{forward:!1}},{keys:"<C-e>",type:"action",action:"scroll",actionArgs:{forward:!0,linewise:!0}},{keys:"<C-y>",type:"action",action:"scroll",actionArgs:{forward:!1,linewise:!0}},{keys:"a",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"charAfter"},context:"normal"},{keys:"A",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"eol"},context:"normal"},{keys:"A",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"endOfSelectedArea"},context:"visual"},{keys:"i",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"inplace"},context:"normal"},{keys:"gi",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"lastEdit"},context:"normal"},{keys:"I",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"firstNonBlank"},context:"normal"},{keys:"gI",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"bol"},context:"normal"},{keys:"I",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"startOfSelectedArea"},context:"visual"},{keys:"o",type:"action",action:"newLineAndEnterInsertMode",isEdit:!0,interlaceInsertRepeat:!0,actionArgs:{after:!0},context:"normal"},{keys:"O",type:"action",action:"newLineAndEnterInsertMode",isEdit:!0,interlaceInsertRepeat:!0,actionArgs:{after:!1},context:"normal"},{keys:"v",type:"action",action:"toggleVisualMode"},{keys:"V",type:"action",action:"toggleVisualMode",actionArgs:{linewise:!0}},{keys:"<C-v>",type:"action",action:"toggleVisualMode",actionArgs:{blockwise:!0}},{keys:"<C-q>",type:"action",action:"toggleVisualMode",actionArgs:{blockwise:!0}},{keys:"gv",type:"action",action:"reselectLastSelection"},{keys:"J",type:"action",action:"joinLines",isEdit:!0},{keys:"gJ",type:"action",action:"joinLines",actionArgs:{keepSpaces:!0},isEdit:!0},{keys:"p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!0,isEdit:!0}},{keys:"P",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!1,isEdit:!0}},{keys:"r<character>",type:"action",action:"replace",isEdit:!0},{keys:"@<register>",type:"action",action:"replayMacro"},{keys:"q<register>",type:"action",action:"enterMacroRecordMode"},{keys:"R",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{replace:!0},context:"normal"},{keys:"R",type:"operator",operator:"change",operatorArgs:{linewise:!0,fullLine:!0},context:"visual",exitVisualBlock:!0},{keys:"u",type:"action",action:"undo",context:"normal"},{keys:"u",type:"operator",operator:"changeCase",operatorArgs:{toLower:!0},context:"visual",isEdit:!0},{keys:"U",type:"operator",operator:"changeCase",operatorArgs:{toLower:!1},context:"visual",isEdit:!0},{keys:"<C-r>",type:"action",action:"redo"},{keys:"m<register>",type:"action",action:"setMark"},{keys:'"<register>',type:"action",action:"setRegister"},{keys:"<C-r><register>",type:"action",action:"insertRegister",context:"insert",isEdit:!0},{keys:"<C-o>",type:"action",action:"oneNormalCommand",context:"insert"},{keys:"zz",type:"action",action:"scrollToCursor",actionArgs:{position:"center"}},{keys:"z.",type:"action",action:"scrollToCursor",actionArgs:{position:"center"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"zt",type:"action",action:"scrollToCursor",actionArgs:{position:"top"}},{keys:"z<CR>",type:"action",action:"scrollToCursor",actionArgs:{position:"top"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"zb",type:"action",action:"scrollToCursor",actionArgs:{position:"bottom"}},{keys:"z-",type:"action",action:"scrollToCursor",actionArgs:{position:"bottom"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:".",type:"action",action:"repeatLastEdit"},{keys:"<C-a>",type:"action",action:"incrementNumberToken",isEdit:!0,actionArgs:{increase:!0,backtrack:!1}},{keys:"<C-x>",type:"action",action:"incrementNumberToken",isEdit:!0,actionArgs:{increase:!1,backtrack:!1}},{keys:"<C-t>",type:"action",action:"indent",actionArgs:{indentRight:!0},context:"insert"},{keys:"<C-d>",type:"action",action:"indent",actionArgs:{indentRight:!1},context:"insert"},{keys:"a<register>",type:"motion",motion:"textObjectManipulation"},{keys:"i<register>",type:"motion",motion:"textObjectManipulation",motionArgs:{textObjectInner:!0}},{keys:"/",type:"search",searchArgs:{forward:!0,querySrc:"prompt",toJumplist:!0}},{keys:"?",type:"search",searchArgs:{forward:!1,querySrc:"prompt",toJumplist:!0}},{keys:"*",type:"search",searchArgs:{forward:!0,querySrc:"wordUnderCursor",wholeWordOnly:!0,toJumplist:!0}},{keys:"#",type:"search",searchArgs:{forward:!1,querySrc:"wordUnderCursor",wholeWordOnly:!0,toJumplist:!0}},{keys:"g*",type:"search",searchArgs:{forward:!0,querySrc:"wordUnderCursor",toJumplist:!0}},{keys:"g#",type:"search",searchArgs:{forward:!1,querySrc:"wordUnderCursor",toJumplist:!0}},{keys:":",type:"ex"}],No=Cn.length,pi=[{name:"colorscheme",shortName:"colo"},{name:"map"},{name:"imap",shortName:"im"},{name:"nmap",shortName:"nm"},{name:"vmap",shortName:"vm"},{name:"omap",shortName:"om"},{name:"noremap",shortName:"no"},{name:"nnoremap",shortName:"nn"},{name:"vnoremap",shortName:"vn"},{name:"inoremap",shortName:"ino"},{name:"onoremap",shortName:"ono"},{name:"unmap"},{name:"mapclear",shortName:"mapc"},{name:"nmapclear",shortName:"nmapc"},{name:"vmapclear",shortName:"vmapc"},{name:"imapclear",shortName:"imapc"},{name:"omapclear",shortName:"omapc"},{name:"write",shortName:"w"},{name:"undo",shortName:"u"},{name:"redo",shortName:"red"},{name:"set",shortName:"se"},{name:"setlocal",shortName:"setl"},{name:"setglobal",shortName:"setg"},{name:"sort",shortName:"sor"},{name:"substitute",shortName:"s",possiblyAsync:!0},{name:"startinsert",shortName:"start"},{name:"nohlsearch",shortName:"noh"},{name:"yank",shortName:"y"},{name:"delmarks",shortName:"delm"},{name:"registers",shortName:"reg",excludeFromCommandHistory:!0},{name:"vglobal",shortName:"v"},{name:"delete",shortName:"d"},{name:"join",shortName:"j"},{name:"normal",shortName:"norm"},{name:"global",shortName:"g"}],Hn=N(""),ja=/[\d]/,Do=[Be.isWordChar,function(y){return y&&!Be.isWordChar(y)&&!/\s/.test(y)}],Ei=[function(y){return/\S/.test(y)}],bo=["<",">"],Yt=["-",'"',".",":","_","/","+"],Vt=/^\w$/,Xt;try{Xt=new RegExp("^[\\p{Lu}]$","u")}catch{Xt=/^[A-Z]$/}var Pt={};M("filetype",void 0,"string",["ft"],function(y,E){if(E!==void 0){if(y===void 0){var C=E.getOption("mode");return C=="null"?"":C}var C=y==""?"null":y;E.setOption("mode",C)}}),M("textwidth",80,"number",["tw"],function(y,E){if(E!==void 0){if(y===void 0){var C=E.getOption("textwidth");return C}var F=Math.round(y);F>1&&E.setOption("textwidth",F)}});var Ti=function(){function y(Q,re,le){function ye(Ne){var Ie=++B%F,He=Y[Ie];He&&He.clear(),Y[Ie]=Q.setBookmark(Ne)}var ke=B%F,me=Y[ke];if(me){var be=me.find();be&&!dt(be,re)&&ye(re)}else ye(re);ye(le),W=B,V=B-F+1,V<0&&(V=0)}function E(Q,re){B+=re,B>W?B=W:B<V&&(B=V);var le=Y[(F+B)%F];if(le&&!le.find()){var ye=re>0?1:-1,ke,me=Q.getCursor();do if(B+=ye,le=Y[(F+B)%F],le&&(ke=le.find())&&!dt(me,ke))break;while(B<W&&B>V)}return le}function C(Q,re){var le=B,ye=E(Q,re);return B=le,ye&&ye.find()}var F=100,B=-1,W=0,V=0,Y=new Array(F);return{cachedCursor:void 0,add:y,find:C,move:E}},Rn=function(y){return y?{changes:y.changes,expectCursorActivityForChange:y.expectCursorActivityForChange}:{changes:[],expectCursorActivityForChange:!1}};k.prototype={exitMacroRecordMode:function(){var y=We.macroModeState;y.onRecordingDone&&y.onRecordingDone(),y.onRecordingDone=void 0,y.isRecording=!1},enterMacroRecordMode:function(y,E){var C=We.registerController.getRegister(E);if(C){if(C.clear(),this.latestRegister=E,y.openDialog){var F=fi("span",{class:"cm-vim-message"},"recording @"+E);this.onRecordingDone=y.openDialog(F,null,{bottom:!0})}this.isRecording=!0}}};var We,dn,mt={enterVimMode:p,leaveVimMode:g,buildKeyMap:function(){},getRegisterController:function(){return We.registerController},resetVimGlobalState_:D,getVimGlobalState_:function(){return We},maybeInitVimState_:T,suppressErrorLogging:!1,InsertModeKey:mo,map:function(y,E,C){br.map(y,E,C)},unmap:function(y,E){return br.unmap(y,E)},noremap:function(y,E,C){br.map(y,E,C,!0)},mapclear:function(y){var E=Cn.length,C=No,F=Cn.slice(0,E-C);if(Cn=Cn.slice(E-C),y)for(var B=F.length-1;B>=0;B--){var W=F[B];if(y!==W.context)if(W.context)this._mapCommand(W);else{var V=["normal","insert","visual"];for(var Y in V)if(V[Y]!==y){var Q={};for(var re in W)Q[re]=W[re];Q.context=V[Y],this._mapCommand(Q)}}}},langmap:P,vimKeyFromEvent:z,setOption:$,getOption:S,defineOption:M,defineEx:function(y,E,C){if(!E)E=y;else if(y.indexOf(E)!==0)throw new Error('(Vim.defineEx) "'+E+'" is not a prefix of "'+y+'", command not registered');Xs[y]=C,br.commandMap_[E]={name:y,shortName:E,type:"api"}},handleKey:function(y,E,C){var F=this.findKey(y,E,C);if(typeof F=="function")return F()},multiSelectHandleKey:Mo,findKey:function(y,E,C){function F(){var re=We.macroModeState;if(re.isRecording){if(E=="q")return re.exitMacroRecordMode(),_(y),!0;C!="mapping"&&rs(re,E)}}function B(){if(E=="<Esc>"){if(Y.visualMode)Sn(y);else{if(!Y.insertMode)return;ni(y)}return _(y),!0}}function W(){if(B())return!0;Y.inputState.keyBuffer.push(E);var re=Y.inputState.keyBuffer.join(""),le=E.length==1,ye=Mn.matchCommand(re,Cn,Y.inputState,"insert"),ke=Y.inputState.changeQueue;if(ye.type=="none")return _(y),!1;if(ye.type=="partial"){if(ye.expectLiteralNext&&(Y.expectLiteralNext=!0),dn&&window.clearTimeout(dn),dn=le&&window.setTimeout(function(){Y.insertMode&&Y.inputState.keyBuffer.length&&_(y)},S("insertModeEscKeysTimeout")),le){var me=y.listSelections();(!ke||ke.removed.length!=me.length)&&(ke=Y.inputState.changeQueue=new I),ke.inserted+=E;for(var be=0;be<me.length;be++){var Ne=gt(me[be].anchor,me[be].head),Ie=tn(me[be].anchor,me[be].head),He=y.getRange(Ne,y.state.overwrite?ge(Ie,0,1):Ie);ke.removed[be]=(ke.removed[be]||"")+He}}return!le}if(Y.expectLiteralNext=!1,dn&&window.clearTimeout(dn),ye.command&&ke){for(var me=y.listSelections(),be=0;be<me.length;be++){var st=me[be].head;y.replaceRange(ke.removed[be]||"",ge(st,0,-ke.inserted.length),st,"+input")}We.macroModeState.lastInsertModeChanges.changes.pop()}return ye.command||_(y),ye.command}function V(){if(F()||B())return!0;Y.inputState.keyBuffer.push(E);var re=Y.inputState.keyBuffer.join("");if(/^[1-9]\d*$/.test(re))return!0;var le=/^(\d*)(.*)$/.exec(re);if(!le)return _(y),!1;var ye=Y.visualMode?"visual":"normal",ke=le[2]||le[1];Y.inputState.operatorShortcut&&Y.inputState.operatorShortcut.slice(-1)==ke&&(ke=Y.inputState.operatorShortcut);var me=Mn.matchCommand(ke,Cn,Y.inputState,ye);return me.type=="none"?(_(y),!1):me.type=="partial"?(me.expectLiteralNext&&(Y.expectLiteralNext=!0),!0):me.type=="clear"?(_(y),!0):(Y.expectLiteralNext=!1,Y.inputState.keyBuffer.length=0,le=/^(\d*)(.*)$/.exec(re),le[1]&&le[1]!="0"&&Y.inputState.pushRepeatDigit(le[1]),me.command)}var Y=T(y),Q;return Y.insertMode?Q=W():Q=V(),Q===!1?!Y.insertMode&&E.length===1?function(){return!0}:void 0:Q===!0?function(){return!0}:function(){if(!((Q.operator||Q.isEdit)&&y.getOption("readOnly")))return y.operation(function(){y.curOp.isVimOp=!0;try{Q.type=="keyToKey"?O(y,Q.toKeys,Q):Mn.processCommand(y,Y,Q)}catch(re){throw y.state.vim=void 0,T(y),mt.suppressErrorLogging||console.log(re),re}return!0})}},handleEx:function(y,E){br.processCommand(y,E)},defineMotion:J,defineAction:se,defineOperator:ne,mapCommand:qs,_mapCommand:ns,defineRegister:U,exitVisualMode:Sn,exitInsertMode:ni},jr=[],on=!1,mn,Zn={Return:"CR",Backspace:"BS",Delete:"Del",Escape:"Esc",Insert:"Ins",ArrowLeft:"Left",ArrowRight:"Right",ArrowUp:"Up",ArrowDown:"Down",Enter:"CR"," ":"Space"},Wr={Shift:1,Alt:1,Command:1,Control:1,CapsLock:1,AltGraph:1,Dead:1,Unidentified:1},Ri={};"Left|Right|Up|Down|End|Home".split("|").concat(Object.keys(Zn)).forEach(function(y){Ri[(Zn[y]||"").toLowerCase()]=Ri[y.toLowerCase()]=y}),M("langmap",void 0,"string",["lmap"],function(y,E){if(y===void 0)return Hn.string;P(y)}),A.prototype.pushRepeatDigit=function(y){this.operator?this.motionRepeat=this.motionRepeat.concat(y):this.prefixRepeat=this.prefixRepeat.concat(y)},A.prototype.getRepeat=function(){var y=0;return(this.prefixRepeat.length>0||this.motionRepeat.length>0)&&(y=1,this.prefixRepeat.length>0&&(y*=parseInt(this.prefixRepeat.join(""),10)),this.motionRepeat.length>0&&(y*=parseInt(this.motionRepeat.join(""),10))),y},j.prototype={setText:function(y,E,C){this.keyBuffer=[y||""],this.linewise=!!E,this.blockwise=!!C},pushText:function(y,E){E&&(this.linewise||this.keyBuffer.push(`
|
|
1447
|
+
`),this.linewise=!0),this.keyBuffer.push(y)},pushInsertModeChanges:function(y){this.insertModeChanges.push(Rn(y))},pushSearchQuery:function(y){this.searchQueries.push(y)},clear:function(){this.keyBuffer=[],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!1},toString:function(){return this.keyBuffer.join("")}},K.prototype={pushText:function(y,E,C,F,B){if(y!=="_"){F&&C.charAt(C.length-1)!==`
|
|
1448
|
+
`&&(C+=`
|
|
1449
|
+
`);var W=this.isValidRegister(y)?this.getRegister(y):null;if(!W){switch(E){case"yank":this.registers[0]=new j(C,F,B);break;case"delete":case"change":C.indexOf(`
|
|
1450
|
+
`)==-1?this.registers["-"]=new j(C,F):(this.shiftNumericRegisters_(),this.registers[1]=new j(C,F))}this.unnamedRegister.setText(C,F,B);return}var V=a(y);V?W.pushText(C,F):W.setText(C,F,B),y==="+"&&typeof navigator<"u"&&typeof navigator.clipboard<"u"&&typeof navigator.clipboard.readText=="function"&&navigator.clipboard.writeText(C),this.unnamedRegister.setText(W.toString(),F)}},getRegister:function(y){return this.isValidRegister(y)?(y=y.toLowerCase(),this.registers[y]||(this.registers[y]=new j),this.registers[y]):this.unnamedRegister},isValidRegister:function(y){return y&&(x(y,Yt)||Vt.test(y))},shiftNumericRegisters_:function(){for(var y=9;y>=2;y--)this.registers[y]=this.getRegister(""+(y-1))}},Z.prototype={nextMatch:function(y,E){var C=this.historyBuffer,F=E?-1:1;this.initialPrefix===null&&(this.initialPrefix=y);for(var B=this.iterator+F;E?B>=0:B<C.length;B+=F)for(var W=C[B],V=0;V<=W.length;V++)if(this.initialPrefix==W.substring(0,V))return this.iterator=B,W;if(B>=C.length)return this.iterator=C.length,this.initialPrefix;if(B<0)return y},pushInput:function(y){var E=this.historyBuffer.indexOf(y);E>-1&&this.historyBuffer.splice(E,1),y.length&&this.historyBuffer.push(y)},reset:function(){this.initialPrefix=null,this.iterator=this.historyBuffer.length}};var Mn={matchCommand:function(y,E,C,F){var B=Ee(y,E,F,C);if(!B.full&&!B.partial)return{type:"none"};if(!B.full&&B.partial)return{type:"partial",expectLiteralNext:B.partial.length==1&&B.partial[0].keys.slice(-11)=="<character>"};for(var W,V=0;V<B.full.length;V++){var Y=B.full[V];W||(W=Y)}if(W.keys.slice(-11)=="<character>"||W.keys.slice(-10)=="<register>"){var Q=Me(y);if(!Q||Q.length>1)return{type:"clear"};C.selectedCharacter=Q}return{type:"full",command:W}},processCommand:function(y,E,C){switch(E.inputState.repeatOverride=C.repeatOverride,C.type){case"motion":this.processMotion(y,E,C);break;case"operator":this.processOperator(y,E,C);break;case"operatorMotion":this.processOperatorMotion(y,E,C);break;case"action":this.processAction(y,E,C);break;case"search":this.processSearch(y,E,C);break;case"ex":case"keyToEx":this.processEx(y,E,C);break}},processMotion:function(y,E,C){E.inputState.motion=C.motion,E.inputState.motionArgs=he(C.motionArgs),this.evalInput(y,E)},processOperator:function(y,E,C){var F=E.inputState;if(F.operator){if(F.operator==C.operator){F.motion="expandToLine",F.motionArgs={linewise:!0},this.evalInput(y,E);return}_(y)}F.operator=C.operator,F.operatorArgs=he(C.operatorArgs),C.keys.length>1&&(F.operatorShortcut=C.keys),C.exitVisualBlock&&(E.visualBlock=!1,Qn(y)),E.visualMode&&this.evalInput(y,E)},processOperatorMotion:function(y,E,C){var F=E.visualMode,B=he(C.operatorMotionArgs);B&&F&&B.visualLine&&(E.visualLine=!0),this.processOperator(y,E,C),F||this.processMotion(y,E,C)},processAction:function(y,E,C){var F=E.inputState,B=F.getRepeat(),W=!!B,V=he(C.actionArgs)||{};F.selectedCharacter&&(V.selectedCharacter=F.selectedCharacter),C.operator&&this.processOperator(y,E,C),C.motion&&this.processMotion(y,E,C),(C.motion||C.operator)&&this.evalInput(y,E),V.repeat=B||1,V.repeatIsExplicit=W,V.registerName=F.registerName,_(y),E.lastMotion=null,C.isEdit&&this.recordLastEdit(E,F,C),Ln[C.action](y,V,E)},processSearch:function(y,E,C){function F(Ie,He,st){We.searchHistoryController.pushInput(Ie),We.searchHistoryController.reset();try{hn(y,Ie,He,st)}catch{Ft(y,"Invalid regex: "+Ie),_(y);return}Mn.processMotion(y,E,{type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:C.searchArgs.toJumplist}})}function B(Ie){F(Ie,!0,!0);var He=We.macroModeState;He.isRecording&&Ks(He,Ie)}function W(Ie,He,st){var Ye=z(Ie),tt,fn;Ye=="<Up>"||Ye=="<Down>"?(tt=Ye=="<Up>",fn=Ie.target?Ie.target.selectionEnd:0,He=We.searchHistoryController.nextMatch(He,tt)||"",st(He),fn&&Ie.target&&(Ie.target.selectionEnd=Ie.target.selectionStart=Math.min(fn,Ie.target.value.length))):Ye&&Ye!="<Left>"&&Ye!="<Right>"&&We.searchHistoryController.reset();var lt;try{lt=hn(y,He,!0,!0)}catch{}lt?y.scrollIntoView(Rr(y,!Y,lt),30):(es(y),y.scrollTo(ye.left,ye.top))}function V(Ie,He,st){var Ye=z(Ie);Ye=="<Esc>"||Ye=="<C-c>"||Ye=="<C-[>"||Ye=="<BS>"&&He==""?(We.searchHistoryController.pushInput(He),We.searchHistoryController.reset(),hn(y,le),es(y),y.scrollTo(ye.left,ye.top),Be.e_stop(Ie),_(y),st(),y.focus()):Ye=="<Up>"||Ye=="<Down>"?Be.e_stop(Ie):Ye=="<C-u>"&&(Be.e_stop(Ie),st(""))}if(y.getSearchCursor){var Y=C.searchArgs.forward,Q=C.searchArgs.wholeWordOnly;_n(y).setReversed(!Y);var re=Y?"/":"?",le=_n(y).getQuery(),ye=y.getScrollInfo();switch(C.searchArgs.querySrc){case"prompt":var ke=We.macroModeState;if(ke.isPlaying){var Ne=ke.replaySearchQueries.shift();F(Ne,!0,!1)}else Tr(y,{onClose:B,prefix:re,desc:"(JavaScript regexp)",onKeyUp:W,onKeyDown:V});break;case"wordUnderCursor":var me=or(y,{noSymbol:!0}),be=!0;if(me||(me=or(y,{noSymbol:!1}),be=!1),!me){Ft(y,"No word under cursor"),_(y);return}var Ne=y.getLine(me.start.line).substring(me.start.ch,me.end.ch);be&&Q?Ne="\\b"+Ne+"\\b":Ne=kn(Ne),We.jumpList.cachedCursor=y.getCursor(),y.setCursor(me.start),F(Ne,!0,!1)}}},processEx:function(y,E,C){function F(W){We.exCommandHistoryController.pushInput(W),We.exCommandHistoryController.reset(),br.processCommand(y,W),y.state.vim&&_(y)}function B(W,V,Y){var Q=z(W),re,le;(Q=="<Esc>"||Q=="<C-c>"||Q=="<C-[>"||Q=="<BS>"&&V=="")&&(We.exCommandHistoryController.pushInput(V),We.exCommandHistoryController.reset(),Be.e_stop(W),_(y),Y(),y.focus()),Q=="<Up>"||Q=="<Down>"?(Be.e_stop(W),re=Q=="<Up>",le=W.target?W.target.selectionEnd:0,V=We.exCommandHistoryController.nextMatch(V,re)||"",Y(V),le&&W.target&&(W.target.selectionEnd=W.target.selectionStart=Math.min(le,W.target.value.length))):Q=="<C-u>"?(Be.e_stop(W),Y("")):Q&&Q!="<Left>"&&Q!="<Right>"&&We.exCommandHistoryController.reset()}C.type=="keyToEx"?br.processCommand(y,C.exArgs.input):E.visualMode?Tr(y,{onClose:F,prefix:":",value:"'<,'>",onKeyDown:B,selectValueOnOpen:!1}):Tr(y,{onClose:F,prefix:":",onKeyDown:B})},evalInput:function(y,E){var C=E.inputState,F=C.motion,B=C.motionArgs||{},W=C.operator,V=C.operatorArgs||{},Y=C.registerName,Q=E.sel,re=Ke(E.visualMode?ce(y,Q.head):y.getCursor("head")),le=Ke(E.visualMode?ce(y,Q.anchor):y.getCursor("anchor")),ye=Ke(re),ke=Ke(le),me,be,Ne;if(W&&this.recordLastEdit(E,C),C.repeatOverride!==void 0?Ne=C.repeatOverride:Ne=C.getRepeat(),Ne>0&&B.explicitRepeat?B.repeatIsExplicit=!0:(B.noRepeat||!B.explicitRepeat&&Ne===0)&&(Ne=1,B.repeatIsExplicit=!1),C.selectedCharacter&&(B.selectedCharacter=V.selectedCharacter=C.selectedCharacter),B.repeat=Ne,_(y),F){var Ie=ri[F](y,re,B,E,C);if(E.lastMotion=ri[F],!Ie)return;if(B.toJumplist){!W&&y.ace.curOp!=null&&(y.ace.curOp.command.scrollIntoView="center-animate");var He=We.jumpList,st=He.cachedCursor;st?(Ki(y,st,Ie),delete He.cachedCursor):Ki(y,re,Ie)}Ie instanceof Array?(be=Ie[0],me=Ie[1]):me=Ie,me||(me=Ke(re)),E.visualMode?((!E.visualBlock||me.ch!==1/0)&&(me=ce(y,me,ye)),be&&(be=ce(y,be)),be=be||ke,Q.anchor=be,Q.head=me,Qn(y),di(y,E,"<",rt(be,me)?be:me),di(y,E,">",rt(be,me)?me:be)):W||(y.ace.curOp&&(y.ace.curOp.vimDialogScroll="center-animate"),me=ce(y,me,ye),y.setCursor(me.line,me.ch))}if(W){if(V.lastSel){be=ke;var Ye=V.lastSel,tt=Math.abs(Ye.head.line-Ye.anchor.line),fn=Math.abs(Ye.head.ch-Ye.anchor.ch);Ye.visualLine?me=new De(ke.line+tt,ke.ch):Ye.visualBlock?me=new De(ke.line+tt,ke.ch+fn):Ye.head.line==Ye.anchor.line?me=new De(ke.line,ke.ch+fn):me=new De(ke.line+tt,ke.ch),E.visualMode=!0,E.visualLine=Ye.visualLine,E.visualBlock=Ye.visualBlock,Q=E.sel={anchor:be,head:me},Qn(y)}else E.visualMode&&(V.lastSel={anchor:Ke(Q.anchor),head:Ke(Q.head),visualBlock:E.visualBlock,visualLine:E.visualLine});var lt,yn,bt,$t,Jn;if(E.visualMode){lt=gt(Q.head,Q.anchor),yn=tn(Q.head,Q.anchor),bt=E.visualLine||V.linewise,$t=E.visualBlock?"block":bt?"line":"char";var pr=b(y,lt,yn);if(Jn=Br(y,{anchor:pr.start,head:pr.end},$t),bt){var bn=Jn.ranges;if($t=="block")for(var q=0;q<bn.length;q++)bn[q].head.ch=Zt(y,bn[q].head.line);else $t=="line"&&(bn[0].head=new De(bn[0].head.line+1,0))}}else{if(lt=Ke(be||ke),yn=Ke(me||ye),rt(yn,lt)){var X=lt;lt=yn,yn=X}bt=B.linewise||V.linewise,bt?hr(y,lt,yn):B.forward&&ir(y,lt,yn),$t="char";var ie=!B.inclusive||bt,pr=b(y,lt,yn);Jn=Br(y,{anchor:pr.start,head:pr.end},$t,ie)}y.setSelections(Jn.ranges,Jn.primary),E.lastMotion=null,V.repeat=Ne,V.registerName=Y,V.linewise=bt;var oe=us[W](y,V,Jn.ranges,ke,me);E.visualMode&&Sn(y,oe!=null),oe&&y.setCursor(oe)}},recordLastEdit:function(y,E,C){var F=We.macroModeState;F.isPlaying||(y.lastEditInputState=E,y.lastEditActionCommand=C,F.lastInsertModeChanges.changes=[],F.lastInsertModeChanges.expectCursorActivityForChange=!1,F.lastInsertModeChanges.visualBlock=y.visualBlock?y.sel.head.line-y.sel.anchor.line:0)}},ri={moveToTopLine:function(y,E,C){var F=go(y).top+C.repeat-1;return new De(F,nn(y.getLine(F)))},moveToMiddleLine:function(y){var E=go(y),C=Math.floor((E.top+E.bottom)*.5);return new De(C,nn(y.getLine(C)))},moveToBottomLine:function(y,E,C){var F=go(y).bottom-C.repeat+1;return new De(F,nn(y.getLine(F)))},expandToLine:function(y,E,C){var F=E;return new De(F.line+C.repeat-1,1/0)},findNext:function(y,E,C){var F=_n(y),B=F.getQuery();if(B){var W=!C.forward;return W=F.isReversed()?!W:W,Ci(y,B),Rr(y,W,B,C.repeat)}},findAndSelectNextInclusive:function(y,E,C,F,B){var W=_n(y),V=W.getQuery();if(V){var Y=!C.forward;Y=W.isReversed()?!Y:Y;var Q=$i(y,Y,V,C.repeat,F);if(Q){if(B.operator)return Q;var re=Q[0],le=new De(Q[1].line,Q[1].ch-1);if(F.visualMode){(F.visualLine||F.visualBlock)&&(F.visualLine=!1,F.visualBlock=!1,Be.signal(y,"vim-mode-change",{mode:"visual",subMode:""}));var ye=F.sel.anchor;if(ye)return W.isReversed()?C.forward?[ye,re]:[ye,le]:C.forward?[ye,le]:[ye,re]}else F.visualMode=!0,F.visualLine=!1,F.visualBlock=!1,Be.signal(y,"vim-mode-change",{mode:"visual",subMode:""});return Y?[le,re]:[re,le]}}},goToMark:function(y,E,C,F){var B=ti(y,F,C.selectedCharacter);return B?C.linewise?{line:B.line,ch:nn(y.getLine(B.line))}:B:null},moveToOtherHighlightedEnd:function(y,E,C,F){if(F.visualBlock&&C.sameLine){var B=F.sel;return[ce(y,new De(B.anchor.line,B.head.ch)),ce(y,new De(B.head.line,B.anchor.ch))]}return[F.sel.head,F.sel.anchor]},jumpToMark:function(y,E,C,F){for(var B=E,W=0;W<C.repeat;W++){var V=B;for(var Y in F.marks)if(f(Y)){var Q=F.marks[Y].find(),re=C.forward?rt(Q,V):rt(V,Q);if(!re&&!(C.linewise&&Q.line==V.line)){var le=dt(V,B),ye=C.forward?jn(V,Q,B):jn(B,Q,V);(le||ye)&&(B=Q)}}}return C.linewise&&(B=new De(B.line,nn(y.getLine(B.line)))),B},moveByCharacters:function(y,E,C){var F=E,B=C.repeat,W=C.forward?F.ch+B:F.ch-B;return new De(F.line,W)},moveByLines:function(y,E,C,F){var B=E,W=B.ch;switch(F.lastMotion){case this.moveByLines:case this.moveByDisplayLines:case this.moveByScroll:case this.moveToColumn:case this.moveToEol:W=F.lastHPos;break;default:F.lastHPos=W}var V=C.repeat+(C.repeatOffset||0),Y=C.forward?B.line+V:B.line-V,Q=y.firstLine(),re=y.lastLine();if(Y<Q&&B.line==Q)return this.moveToStartOfLine(y,E,C,F);if(Y>re&&B.line==re)return Eo(y,E,C,F,!0);var le=y.ace.session.getFoldLine(Y);return le&&(C.forward?Y>le.start.row&&(Y=le.end.row+1):Y=le.start.row),C.toFirstChar&&(W=nn(y.getLine(Y)),F.lastHPos=W),F.lastHSPos=y.charCoords(new De(Y,W),"div").left,new De(Y,W)},moveByDisplayLines:function(y,E,C,F){var B=E;switch(F.lastMotion){case this.moveByDisplayLines:case this.moveByScroll:case this.moveByLines:case this.moveToColumn:case this.moveToEol:break;default:F.lastHSPos=y.charCoords(B,"div").left}var W=C.repeat,Q=y.findPosV(B,C.forward?W:-W,"line",F.lastHSPos);if(Q.hitSide)if(C.forward)var V=y.charCoords(Q,"div"),Y={top:V.top+8,left:F.lastHSPos},Q=y.coordsChar(Y,"div");else{var re=y.charCoords(new De(y.firstLine(),0),"div");re.left=F.lastHSPos,Q=y.coordsChar(re,"div")}return F.lastHPos=Q.ch,Q},moveByPage:function(y,E,C){var F=E,B=C.repeat;return y.findPosV(F,C.forward?B:-B,"page")},moveByParagraph:function(y,E,C){var F=C.forward?1:-1;return zs(y,E,C.repeat,F)},moveBySentence:function(y,E,C){var F=C.forward?1:-1;return Xi(y,E,C.repeat,F)},moveByScroll:function(y,E,C,F){var B=y.getScrollInfo(),W=null,V=C.repeat;V||(V=B.clientHeight/(2*y.defaultTextHeight()));var Y=y.charCoords(E,"local");if(C.repeat=V,W=ri.moveByDisplayLines(y,E,C,F),!W)return null;var Q=y.charCoords(W,"local");return y.scrollTo(null,B.top+Q.top-Y.top),W},moveByWords:function(y,E,C){return vr(y,E,C.repeat,!!C.forward,!!C.wordEnd,!!C.bigWord)},moveTillCharacter:function(y,E,C){var F=C.repeat,B=Jo(y,F,C.forward,C.selectedCharacter,E),W=C.forward?-1:1;return Gi(W,C),B?(B.ch+=W,B):null},moveToCharacter:function(y,E,C){var F=C.repeat;return Gi(0,C),Jo(y,F,C.forward,C.selectedCharacter,E)||E},moveToSymbol:function(y,E,C){var F=C.repeat;return Yi(y,F,C.forward,C.selectedCharacter)||E},moveToColumn:function(y,E,C,F){var B=C.repeat;return F.lastHPos=B-1,F.lastHSPos=y.charCoords(E,"div").left,Rl(y,B)},moveToEol:function(y,E,C,F){return Eo(y,E,C,F,!1)},moveToFirstNonWhiteSpaceCharacter:function(y,E){var C=E;return new De(C.line,nn(y.getLine(C.line)))},moveToMatchedSymbol:function(y,E){for(var C=E,F=C.line,B=C.ch,W=y.getLine(F),V;B<W.length;B++)if(V=W.charAt(B),V&&u(V)){var Y=y.getTokenTypeAt(new De(F,B+1));if(Y!=="string"&&Y!=="comment")break}if(B<W.length){var Q=/[<>]/.test(W[B])?/[(){}[\]<>]/:/[(){}[\]]/,re=y.findMatchingBracket(new De(F,B+1),{bracketRegex:Q});return re.to}return C},moveToStartOfLine:function(y,E){return new De(E.line,0)},moveToLineOrEdgeOfDocument:function(y,E,C){var F=C.forward?y.lastLine():y.firstLine();return C.repeatIsExplicit&&(F=C.repeat-y.getOption("firstLineNumber")),new De(F,nn(y.getLine(F)))},moveToStartOfDisplayLine:function(y){return y.execCommand("goLineLeft"),y.getCursor()},moveToEndOfDisplayLine:function(y){y.execCommand("goLineRight");var E=y.getCursor();return E.sticky=="before"&&E.ch--,E},textObjectManipulation:function(y,E,C,F){var B={"(":")",")":"(","{":"}","}":"{","[":"]","]":"[","<":">",">":"<"},W={"'":!0,'"':!0,"`":!0},V=C.selectedCharacter;V=="b"?V="(":V=="B"&&(V="{");var Y=!C.textObjectInner,Q,re;if(B[V]){if(re=!0,Q=Wn(y,E,V,Y),!Q){var le=y.getSearchCursor(new RegExp("\\"+V,"g"),E);le.find()&&(Q=Wn(y,le.from(),V,Y))}}else if(W[V])re=!0,Q=Ar(y,E,V,Y);else if(V==="W"||V==="w")for(var ye=C.repeat||1;ye-- >0;){var ke=or(y,{inclusive:Y,innerWord:!Y,bigWord:V==="W",noSymbol:V==="W",multiline:!0},Q&&Q.end);ke&&(Q||(Q=ke),Q.end=ke.end)}else if(V==="p")if(Q=zs(y,E,C.repeat,0,Y),C.linewise=!0,F.visualMode)F.visualLine||(F.visualLine=!0);else{var me=F.inputState.operatorArgs;me&&(me.linewise=!0),Q.end.line--}else if(V==="t")Q=$o(y,E,Y);else if(V==="s"){var be=y.getLine(E.line);E.ch>0&&w(be[E.ch])&&(E.ch-=1);var Ne=Oa(y,E,C.repeat,1,Y),Ie=Oa(y,E,C.repeat,-1,Y);m(y.getLine(Ie.line)[Ie.ch])&&m(y.getLine(Ne.line)[Ne.ch-1])&&(Ie={line:Ie.line,ch:Ie.ch+1}),Q={start:Ie,end:Ne}}return Q?y.state.vim.visualMode?gn(y,Q.start,Q.end,re):[Q.start,Q.end]:null},repeatLastCharacterSearch:function(y,E,C){var F=We.lastCharacterSearch,B=C.repeat,W=C.forward===F.forward,V=(F.increment?1:0)*(W?-1:1);y.moveH(-V,"char"),C.inclusive=!!W;var Y=Jo(y,B,W,F.selectedCharacter);return Y?(Y.ch+=V,Y):(y.moveH(V,"char"),E)}},us={change:function(y,E,C){var F,B,W=y.state.vim,V=C[0].anchor,Y=C[0].head;if(W.visualMode)if(E.fullLine)Y.ch=Number.MAX_VALUE,Y.line--,y.setSelection(V,Y),B=y.getSelection(),y.replaceSelection(""),F=V;else{B=y.getSelection();var Q=ae("",C.length);y.replaceSelections(Q),F=gt(C[0].head,C[0].anchor)}else{B=y.getRange(V,Y);var re=W.lastEditInputState||{};if(re.motion=="moveByWords"&&!m(B)){var le=/\s+$/.exec(B);le&&re.motionArgs&&re.motionArgs.forward&&(Y=ge(Y,0,-le[0].length),B=B.slice(0,-le[0].length))}E.linewise&&(V=new De(V.line,nn(y.getLine(V.line))),Y.line>V.line&&(Y=new De(Y.line-1,Number.MAX_VALUE))),y.replaceRange("",V,Y),F=V}We.registerController.pushText(E.registerName,"change",B,E.linewise,C.length>1),Ln.enterInsertMode(y,{head:F},y.state.vim)},delete:function(y,E,C){var F,B,W=y.state.vim;if(W.visualBlock){B=y.getSelection();var V=ae("",C.length);y.replaceSelections(V),F=gt(C[0].head,C[0].anchor)}else{var Y=C[0].anchor,Q=C[0].head;E.linewise&&Q.line!=y.firstLine()&&Y.line==y.lastLine()&&Y.line==Q.line-1&&(Y.line==y.firstLine()?Y.ch=0:Y=new De(Y.line-1,Zt(y,Y.line-1))),B=y.getRange(Y,Q),y.replaceRange("",Y,Q),F=Y,E.linewise&&(F=ri.moveToFirstNonWhiteSpaceCharacter(y,Y))}return We.registerController.pushText(E.registerName,"delete",B,E.linewise,W.visualBlock),ce(y,F)},indent:function(y,E,C){var F=y.state.vim,B=F.visualMode?E.repeat:1;if(F.visualBlock){for(var W=y.getOption("tabSize"),V=y.getOption("indentWithTabs")?" ":" ".repeat(W),Y,Q=C.length-1;Q>=0;Q--)if(Y=gt(C[Q].anchor,C[Q].head),E.indentRight)y.replaceRange(V.repeat(B),Y,Y);else{for(var re=y.getLine(Y.line),le=0,ye=0;ye<B;ye++){var ke=re[Y.ch+le];if(ke==" ")le++;else{if(ke!=" ")break;le++;for(var me=1;me<V.length&&(ke=re[Y.ch+le],ke===" ");me++)le++}}y.replaceRange("",Y,ge(Y,0,le))}return Y}if(y.indentMore)for(var ye=0;ye<B;ye++)E.indentRight?y.indentMore():y.indentLess();else{var be=C[0].anchor.line,Ne=F.visualBlock?C[C.length-1].anchor.line:C[0].head.line;E.linewise&&Ne--;for(var Q=be;Q<=Ne;Q++)for(var ye=0;ye<B;ye++)y.indentLine(Q,E.indentRight)}return ri.moveToFirstNonWhiteSpaceCharacter(y,C[0].anchor)},indentAuto:function(y,E,C){return y.execCommand("indentAuto"),ri.moveToFirstNonWhiteSpaceCharacter(y,C[0].anchor)},hardWrap:function(y,E,C,F,B){if(y.hardWrap){var W=C[0].anchor.line,V=C[0].head.line;E.linewise&&V--;var Y=y.hardWrap({from:W,to:V});return Y>W&&E.linewise&&Y--,E.keepCursor?F:new De(Y,0)}},changeCase:function(y,E,C,F,B){for(var W=y.getSelections(),V=[],Y=E.toLower,Q=0;Q<W.length;Q++){var re=W[Q],le="";if(Y===!0)le=re.toLowerCase();else if(Y===!1)le=re.toUpperCase();else for(var ye=0;ye<re.length;ye++){var ke=re.charAt(ye);le+=a(ke)?ke.toLowerCase():ke.toUpperCase()}V.push(le)}return y.replaceSelections(V),E.shouldMoveCursor?B:!y.state.vim.visualMode&&E.linewise&&C[0].anchor.line+1==C[0].head.line?ri.moveToFirstNonWhiteSpaceCharacter(y,F):E.linewise?F:gt(C[0].anchor,C[0].head)},yank:function(y,E,C,F){var B=y.state.vim,W=y.getSelection(),V=B.visualMode?gt(B.sel.anchor,B.sel.head,C[0].head,C[0].anchor):F;return We.registerController.pushText(E.registerName,"yank",W,E.linewise,B.visualBlock),V}},Ln={jumpListWalk:function(y,E,C){if(!C.visualMode){var F=E.repeat,B=E.forward,W=We.jumpList,V=W.move(y,B?F:-F),Y=V?V.find():void 0;Y=Y||y.getCursor(),y.setCursor(Y),y.ace.curOp.command.scrollIntoView="center-animate"}},scroll:function(y,E,C){if(!C.visualMode){var F=E.repeat||1,B=y.defaultTextHeight(),W=y.getScrollInfo().top,V=B*F,Y=E.forward?W+V:W-V,Q=Ke(y.getCursor()),re=y.charCoords(Q,"local");if(E.forward)Y>re.top?(Q.line+=(Y-re.top)/B,Q.line=Math.ceil(Q.line),y.setCursor(Q),re=y.charCoords(Q,"local"),y.scrollTo(null,re.top)):y.scrollTo(null,Y);else{var le=Y+y.getScrollInfo().clientHeight;le<re.bottom?(Q.line-=(re.bottom-le)/B,Q.line=Math.floor(Q.line),y.setCursor(Q),re=y.charCoords(Q,"local"),y.scrollTo(null,re.bottom-y.getScrollInfo().clientHeight)):y.scrollTo(null,Y)}}},scrollToCursor:function(y,E){var C=y.getCursor().line,F=y.charCoords(new De(C,0),"local"),B=y.getScrollInfo().clientHeight,W=F.top;switch(E.position){case"center":W=F.bottom-B/2;break;case"bottom":var V=new De(C,y.getLine(C).length-1),Y=y.charCoords(V,"local"),Q=Y.bottom-W;W=W-B+Q}y.scrollTo(null,W)},replayMacro:function(y,E,C){var F=E.selectedCharacter,B=E.repeat,W=We.macroModeState;for(F=="@"?F=W.latestRegister:W.latestRegister=F;B--;)Vs(y,C,W,F)},enterMacroRecordMode:function(y,E){var C=We.macroModeState,F=E.selectedCharacter;We.registerController.isValidRegister(F)&&C.enterMacroRecordMode(y,F)},toggleOverwrite:function(y){y.state.overwrite?(y.toggleOverwrite(!1),y.setOption("keyMap","vim-insert"),Be.signal(y,"vim-mode-change",{mode:"insert"})):(y.toggleOverwrite(!0),y.setOption("keyMap","vim-replace"),Be.signal(y,"vim-mode-change",{mode:"replace"}))},enterInsertMode:function(y,E,C){if(!y.getOption("readOnly")){C.insertMode=!0,C.insertModeRepeat=E&&E.repeat||1;var F=E?E.insertAt:null,B=C.sel,W=E.head||y.getCursor("head"),V=y.listSelections().length;if(F=="eol")W=new De(W.line,Zt(y,W.line));else if(F=="bol")W=new De(W.line,0);else if(F=="charAfter"){var Y=b(y,W,ge(W,0,1));W=Y.end}else if(F=="firstNonBlank"){var Y=b(y,W,ri.moveToFirstNonWhiteSpaceCharacter(y,W));W=Y.end}else if(F=="startOfSelectedArea"){if(!C.visualMode)return;C.visualBlock?(W=new De(Math.min(B.head.line,B.anchor.line),Math.min(B.head.ch,B.anchor.ch)),V=Math.abs(B.head.line-B.anchor.line)+1):B.head.line<B.anchor.line?W=B.head:W=new De(B.anchor.line,0)}else if(F=="endOfSelectedArea"){if(!C.visualMode)return;C.visualBlock?(W=new De(Math.min(B.head.line,B.anchor.line),Math.max(B.head.ch,B.anchor.ch)+1),V=Math.abs(B.head.line-B.anchor.line)+1):B.head.line>=B.anchor.line?W=ge(B.head,0,1):W=new De(B.anchor.line,0)}else if(F=="inplace"){if(C.visualMode)return}else F=="lastEdit"&&(W=To(y)||W);y.setOption("disableInput",!1),E&&E.replace?(y.toggleOverwrite(!0),y.setOption("keyMap","vim-replace"),Be.signal(y,"vim-mode-change",{mode:"replace"})):(y.toggleOverwrite(!1),y.setOption("keyMap","vim-insert"),Be.signal(y,"vim-mode-change",{mode:"insert"})),We.macroModeState.isPlaying||(y.on("change",Ro),C.insertEnd&&C.insertEnd.clear(),C.insertEnd=y.setBookmark(W,{insertLeft:!0}),Be.on(y.getInputField(),"keydown",Gs)),C.visualMode&&Sn(y),Pr(y,W,V)}},toggleVisualMode:function(y,E,C){var F=E.repeat,B=y.getCursor(),W;if(C.visualMode)C.visualLine^E.linewise||C.visualBlock^E.blockwise?(C.visualLine=!!E.linewise,C.visualBlock=!!E.blockwise,Be.signal(y,"vim-mode-change",{mode:"visual",subMode:C.visualLine?"linewise":C.visualBlock?"blockwise":""}),Qn(y)):Sn(y);else{C.visualMode=!0,C.visualLine=!!E.linewise,C.visualBlock=!!E.blockwise,W=ce(y,new De(B.line,B.ch+F-1));var V=b(y,B,W);C.sel={anchor:V.start,head:V.end},Be.signal(y,"vim-mode-change",{mode:"visual",subMode:C.visualLine?"linewise":C.visualBlock?"blockwise":""}),Qn(y),di(y,C,"<",gt(B,W)),di(y,C,">",tn(B,W))}},reselectLastSelection:function(y,E,C){var F=C.lastSelection;if(C.visualMode&&qt(y,C),F){var B=F.anchorMark.find(),W=F.headMark.find();if(!B||!W)return;C.sel={anchor:B,head:W},C.visualMode=!0,C.visualLine=F.visualLine,C.visualBlock=F.visualBlock,Qn(y),di(y,C,"<",gt(B,W)),di(y,C,">",tn(B,W)),Be.signal(y,"vim-mode-change",{mode:"visual",subMode:C.visualLine?"linewise":C.visualBlock?"blockwise":""})}},joinLines:function(y,E,C){var F,B;if(C.visualMode){if(F=y.getCursor("anchor"),B=y.getCursor("head"),rt(B,F)){var W=B;B=F,F=W}B.ch=Zt(y,B.line)-1}else{var V=Math.max(E.repeat,2);F=y.getCursor(),B=ce(y,new De(F.line+V-1,1/0))}for(var Y=0,Q=F.line;Q<B.line;Q++){Y=Zt(y,F.line);var re="",le=0;if(!E.keepSpaces){var ye=y.getLine(F.line+1);le=ye.search(/\S/),le==-1?le=ye.length:re=" "}y.replaceRange(re,new De(F.line,Y),new De(F.line+1,le))}var ke=ce(y,new De(F.line,Y));C.visualMode&&Sn(y,!1),y.setCursor(ke)},newLineAndEnterInsertMode:function(y,E,C){C.insertMode=!0;var F=Ke(y.getCursor());if(F.line===y.firstLine()&&!E.after)y.replaceRange(`
|
|
1451
|
+
`,new De(y.firstLine(),0)),y.setCursor(y.firstLine(),0);else{F.line=E.after?F.line:F.line-1,F.ch=Zt(y,F.line),y.setCursor(F);var B=Be.commands.newlineAndIndentContinueComment||Be.commands.newlineAndIndent;B(y)}this.enterInsertMode(y,{repeat:E.repeat},C)},paste:function(y,E,C){var F=this,B=We.registerController.getRegister(E.registerName),W=function(){var V=B.toString();F.continuePaste(y,E,C,V,B)};E.registerName==="+"&&typeof navigator<"u"&&typeof navigator.clipboard<"u"&&typeof navigator.clipboard.readText=="function"?navigator.clipboard.readText().then(function(V){F.continuePaste(y,E,C,V,B)},function(){W()}):W()},continuePaste:function(y,E,C,F,B){var W=Ke(y.getCursor());if(F){if(E.matchIndent){var V=y.getOption("tabSize"),Y=function(bn){var q=bn.split(" ").length-1,X=bn.split(" ").length-1;return q*V+X*1},Q=y.getLine(y.getCursor().line),re=Y(Q.match(/^\s*/)[0]),le=F.replace(/\n$/,""),ye=F!==le,ke=Y(F.match(/^\s*/)[0]),F=le.replace(/^\s*/gm,function(bn){var q=re+(Y(bn)-ke);if(q<0)return"";if(y.getOption("indentWithTabs")){var X=Math.floor(q/V);return Array(X+1).join(" ")}return Array(q+1).join(" ")});F+=ye?`
|
|
1452
|
+
`:""}if(E.repeat>1)var F=Array(E.repeat+1).join(F);var me=B.linewise,be=B.blockwise;if(be){F=F.split(`
|
|
1453
|
+
`),me&&F.pop();for(var Ne=0;Ne<F.length;Ne++)F[Ne]=F[Ne]==""?" ":F[Ne];W.ch+=E.after?1:0,W.ch=Math.min(Zt(y,W.line),W.ch)}else me?C.visualMode?F=C.visualLine?F.slice(0,-1):`
|
|
1454
|
+
`+F.slice(0,F.length-1)+`
|
|
1455
|
+
`:E.after?(F=`
|
|
1456
|
+
`+F.slice(0,F.length-1),W.ch=Zt(y,W.line)):W.ch=0:W.ch+=E.after?1:0;var Ie;if(C.visualMode){C.lastPastedText=F;var He,st=qe(y,C),Ye=st[0],tt=st[1],fn=y.getSelection(),lt=y.listSelections(),yn=new Array(lt.length).join("1").split("1");C.lastSelection&&(He=C.lastSelection.headMark.find()),We.registerController.unnamedRegister.setText(fn),be?(y.replaceSelections(yn),tt=new De(Ye.line+F.length-1,Ye.ch),y.setCursor(Ye),ur(y,tt),y.replaceSelections(F),Ie=Ye):C.visualBlock?(y.replaceSelections(yn),y.setCursor(Ye),y.replaceRange(F,Ye,Ye),Ie=Ye):(y.replaceRange(F,Ye,tt),Ie=y.posFromIndex(y.indexFromPos(Ye)+F.length-1)),He&&(C.lastSelection.headMark=y.setBookmark(He)),me&&(Ie.ch=0)}else if(be){y.setCursor(W);for(var Ne=0;Ne<F.length;Ne++){var bt=W.line+Ne;bt>y.lastLine()&&y.replaceRange(`
|
|
1457
|
+
`,new De(bt,0));var $t=Zt(y,bt);$t<W.ch&&Xn(y,bt,W.ch)}y.setCursor(W),ur(y,new De(W.line+F.length-1,W.ch)),y.replaceSelections(F),Ie=W}else if(y.replaceRange(F,W),me){var bt=E.after?W.line+1:W.line;Ie=new De(bt,nn(y.getLine(bt)))}else Ie=Ke(W),/\n/.test(F)||(Ie.ch+=F.length-(E.after?1:0));C.visualMode&&Sn(y,!1),y.setCursor(Ie)}},undo:function(y,E){y.operation(function(){Xe(y,Be.commands.undo,E.repeat)(),y.setCursor(ce(y,y.getCursor("start")))})},redo:function(y,E){Xe(y,Be.commands.redo,E.repeat)()},setRegister:function(y,E,C){C.inputState.registerName=E.selectedCharacter},insertRegister:function(y,E,C){var F=E.selectedCharacter,B=We.registerController.getRegister(F),W=B&&B.toString();W&&y.replaceSelection(W)},oneNormalCommand:function(y,E,C){ni(y,!0),C.insertModeReturn=!0,Be.on(y,"vim-command-done",function F(){C.visualMode||(C.insertModeReturn&&(C.insertModeReturn=!1,C.insertMode||Ln.enterInsertMode(y,{},C)),Be.off(y,"vim-command-done",F))})},setMark:function(y,E,C){var F=E.selectedCharacter;di(y,C,F,y.getCursor())},replace:function(y,E,C){var F=E.selectedCharacter,B=y.getCursor(),W,V,Y=y.listSelections();if(C.visualMode)B=y.getCursor("start"),V=y.getCursor("end");else{var Q=y.getLine(B.line);W=B.ch+E.repeat,W>Q.length&&(W=Q.length),V=new De(B.line,W)}var re=b(y,B,V);if(B=re.start,V=re.end,F==`
|
|
1458
|
+
`)C.visualMode||y.replaceRange("",B,V),(Be.commands.newlineAndIndentContinueComment||Be.commands.newlineAndIndent)(y);else{var le=y.getRange(B,V);if(le=le.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,F),le=le.replace(/[^\n]/g,F),C.visualBlock){var ye=new Array(y.getOption("tabSize")+1).join(" ");le=y.getSelection(),le=le.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,F),le=le.replace(/\t/g,ye).replace(/[^\n]/g,F).split(`
|
|
1459
|
+
`),y.replaceSelections(le)}else y.replaceRange(le,B,V);C.visualMode?(B=rt(Y[0].anchor,Y[0].head)?Y[0].anchor:Y[0].head,y.setCursor(B),Sn(y,!1)):y.setCursor(ge(V,0,-1))}},incrementNumberToken:function(y,E){for(var C=y.getCursor(),F=y.getLine(C.line),B=/(-?)(?:(0x)([\da-f]+)|(0b|0|)(\d+))/gi,W,V,Y,Q;(W=B.exec(F))!==null&&(V=W.index,Y=V+W[0].length,!(C.ch<Y)););if(!(!E.backtrack&&Y<=C.ch)&&W){var re=W[2]||W[4],le=W[3]||W[5],ye=E.increase?1:-1,ke={"0b":2,0:8,"":10,"0x":16}[re.toLowerCase()],me=parseInt(W[1]+le,ke)+ye*E.repeat;Q=me.toString(ke);var be=re?new Array(le.length-Q.length+1+W[1].length).join("0"):"";Q.charAt(0)==="-"?Q="-"+re+be+Q.substr(1):Q=re+be+Q;var Ne=new De(C.line,V),Ie=new De(C.line,Y);y.replaceRange(Q,Ne,Ie),y.setCursor(new De(C.line,V+Q.length-1))}},repeatLastEdit:function(y,E,C){var F=C.lastEditInputState;if(F){var B=E.repeat;B&&E.repeatIsExplicit?C.lastEditInputState.repeatOverride=B:B=C.lastEditInputState.repeatOverride||B,Da(y,C,B,!1)}},indent:function(y,E){y.indentLine(y.getCursor().line,E.indentRight)},exitInsertMode:ni},gi={"(":"bracket",")":"bracket","{":"bracket","}":"bracket","[":"section","]":"section","*":"comment","/":"comment",m:"method",M:"method","#":"preprocess"},mi={bracket:{isComplete:function(y){if(y.nextCh===y.symb){if(y.depth++,y.depth>=1)return!0}else y.nextCh===y.reverseSymb&&y.depth--;return!1}},section:{init:function(y){y.curMoveThrough=!0,y.symb=(y.forward?"]":"[")===y.symb?"{":"}"},isComplete:function(y){return y.index===0&&y.nextCh===y.symb}},comment:{isComplete:function(y){var E=y.lastCh==="*"&&y.nextCh==="/";return y.lastCh=y.nextCh,E}},method:{init:function(y){y.symb=y.symb==="m"?"{":"}",y.reverseSymb=y.symb==="{"?"}":"{"},isComplete:function(y){return y.nextCh===y.symb}},preprocess:{init:function(y){y.index=0},isComplete:function(y){if(y.nextCh==="#"){var E=y.lineText.match(/^#(\w+)/)[1];if(E==="endif"){if(y.forward&&y.depth===0)return!0;y.depth++}else if(E==="if"){if(!y.forward&&y.depth===0)return!0;y.depth--}if(E==="else"&&y.depth===0)return!0}return!1}}};M("pcre",!0,"boolean"),Qi.prototype={getQuery:function(){return We.query},setQuery:function(y){We.query=y},getOverlay:function(){return this.searchOverlay},setOverlay:function(y){this.searchOverlay=y},isReversed:function(){return We.isReversed},setReversed:function(y){We.isReversed=y},getScrollbarAnnotate:function(){return this.annotate},setScrollbarAnnotate:function(y){this.annotate=y}};var Mi={"\\n":`
|
|
1460
|
+
`,"\\r":"\r","\\t":" "},dr={"\\/":"/","\\\\":"\\","\\n":`
|
|
1461
|
+
`,"\\r":"\r","\\t":" ","\\&":"&"},fr=0,yr=function(){this.buildCommandMap_()};yr.prototype={processCommand:function(y,E,C){var F=this;y.operation(function(){y.curOp.isVimOp=!0,F._processCommand(y,E,C)})},_processCommand:function(y,E,C){var F=y.state.vim,B=We.registerController.getRegister(":"),W=B.toString(),V=new Be.StringStream(E);B.setText(E);var Y=C||{};Y.input=E;try{this.parseInput_(y,V,Y)}catch(le){throw Ft(y,le.toString()),le}F.visualMode&&Sn(y);var Q,re;if(!Y.commandName)Y.line!==void 0&&(re="move");else if(Q=this.matchCommand_(Y.commandName),Q){if(re=Q.name,Q.excludeFromCommandHistory&&B.setText(W),this.parseCommandArgs_(V,Y,Q),Q.type=="exToKey"){O(y,Q.toKeys,Q);return}if(Q.type=="exToEx"){this.processCommand(y,Q.toInput);return}}if(!re){Ft(y,'Not an editor command ":'+E+'"');return}try{Xs[re](y,Y),(!Q||!Q.possiblyAsync)&&Y.callback&&Y.callback()}catch(le){throw Ft(y,le.toString()),le}},parseInput_:function(y,E,C){if(E.eatWhile(":"),E.eat("%")?(C.line=y.firstLine(),C.lineEnd=y.lastLine()):(C.line=this.parseLineSpec_(y,E),C.line!==void 0&&E.eat(",")&&(C.lineEnd=this.parseLineSpec_(y,E))),C.line==null)if(y.state.vim.visualMode){var F=ti(y,y.state.vim,"<");C.selectionLine=F&&F.line,F=ti(y,y.state.vim,">"),C.selectionLineEnd=F&&F.line}else C.selectionLine=y.getCursor().line;else C.selectionLine=C.line,C.selectionLineEnd=C.lineEnd;var B=E.match(/^(\w+|!!|@@|[!#&*<=>@~])/);return B?C.commandName=B[1]:C.commandName=E.match(/.*/)[0],C},parseLineSpec_:function(y,E){var C=E.match(/^(\d+)/);if(C)return parseInt(C[1],10)-1;switch(E.next()){case".":return this.parseLineSpecOffset_(E,y.getCursor().line);case"$":return this.parseLineSpecOffset_(E,y.lastLine());case"'":var F=E.next(),B=ti(y,y.state.vim,F);if(!B)throw new Error("Mark not set");return this.parseLineSpecOffset_(E,B.line);case"-":case"+":return E.backUp(1),this.parseLineSpecOffset_(E,y.getCursor().line);default:return E.backUp(1),void 0}},parseLineSpecOffset_:function(y,E){var C=y.match(/^([+-])?(\d+)/);if(C){var F=parseInt(C[2],10);C[1]=="-"?E-=F:E+=F}return E},parseCommandArgs_:function(y,E,C){if(!y.eol()){E.argString=y.match(/.*/)[0];var F=C.argDelimiter||/\s+/,B=hi(E.argString).split(F);B.length&&B[0]&&(E.args=B)}},matchCommand_:function(y){for(var E=y.length;E>0;E--){var C=y.substring(0,E);if(this.commandMap_[C]){var F=this.commandMap_[C];if(F.name.indexOf(y)===0)return F}}return null},buildCommandMap_:function(){this.commandMap_={};for(var y=0;y<pi.length;y++){var E=pi[y],C=E.shortName||E.name;this.commandMap_[C]=E}},map:function(y,E,C,F){if(y!=":"&&y.charAt(0)==":"){if(C)throw Error("Mode not supported for ex mappings");var B=y.substring(1);E!=":"&&E.charAt(0)==":"?this.commandMap_[B]={name:B,type:"exToEx",toInput:E.substring(1),user:!0}:this.commandMap_[B]={name:B,type:"exToKey",toKeys:E,user:!0}}else{var W={keys:y,type:"keyToKey",toKeys:E,noremap:!!F};C&&(W.context=C),Cn.unshift(W)}},unmap:function(y,E){if(y!=":"&&y.charAt(0)==":"){if(E)throw Error("Mode not supported for ex mappings");var C=y.substring(1);if(this.commandMap_[C]&&this.commandMap_[C].user)return delete this.commandMap_[C],!0}else for(var F=y,B=0;B<Cn.length;B++)if(F==Cn[B].keys&&Cn[B].context===E)return Cn.splice(B,1),!0}};var Xs={colorscheme:function(y,E){if(!E.args||E.args.length<1){Ft(y,y.getOption("theme"));return}y.setOption("theme",E.args[0])},map:function(y,E,C,F){var B=E.args;if(!B||B.length<2){y&&Ft(y,"Invalid mapping: "+E.input);return}br.map(B[0],B[1],C,F)},imap:function(y,E){this.map(y,E,"insert")},nmap:function(y,E){this.map(y,E,"normal")},vmap:function(y,E){this.map(y,E,"visual")},omap:function(y,E){this.map(y,E,"operatorPending")},noremap:function(y,E){this.map(y,E,void 0,!0)},inoremap:function(y,E){this.map(y,E,"insert",!0)},nnoremap:function(y,E){this.map(y,E,"normal",!0)},vnoremap:function(y,E){this.map(y,E,"visual",!0)},onoremap:function(y,E){this.map(y,E,"operatorPending",!0)},unmap:function(y,E,C){var F=E.args;(!F||F.length<1||!br.unmap(F[0],C))&&y&&Ft(y,"No such mapping: "+E.input)},mapclear:function(y,E){mt.mapclear()},imapclear:function(y,E){mt.mapclear("insert")},nmapclear:function(y,E){mt.mapclear("normal")},vmapclear:function(y,E){mt.mapclear("visual")},omapclear:function(y,E){mt.mapclear("operatorPending")},move:function(y,E){Mn.processCommand(y,y.state.vim,{type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0},repeatOverride:E.line+1})},set:function(y,E){var C=E.args,F=E.setCfg||{};if(!C||C.length<1){y&&Ft(y,"Invalid mapping: "+E.input);return}var B=C[0].split("="),W=B[0],V=B[1],Y=!1,Q=!1;if(W.charAt(W.length-1)=="?"){if(V)throw Error("Trailing characters: "+E.argString);W=W.substring(0,W.length-1),Y=!0}else W.charAt(W.length-1)=="!"&&(W=W.substring(0,W.length-1),Q=!0);V===void 0&&W.substring(0,2)=="no"&&(W=W.substring(2),V=!1);var re=Pt[W]&&Pt[W].type=="boolean";if(re&&(Q?V=!S(W,y,F):V==null&&(V=!0)),!re&&V===void 0||Y){var le=S(W,y,F);le instanceof Error?Ft(y,le.message):le===!0||le===!1?Ft(y," "+(le?"":"no")+W):Ft(y," "+W+"="+le)}else{var ye=$(W,V,y,F);ye instanceof Error&&Ft(y,ye.message)}},setlocal:function(y,E){E.setCfg={scope:"local"},this.set(y,E)},setglobal:function(y,E){E.setCfg={scope:"global"},this.set(y,E)},registers:function(y,E){var C=E.args,F=We.registerController.registers,B=`----------Registers----------
|
|
1462
|
+
|
|
1463
|
+
`;if(C){var W;C=C.join("");for(var V=0;V<C.length;V++)if(W=C.charAt(V),!!We.registerController.isValidRegister(W)){var Y=F[W]||new j;B+='"'+W+" "+Y.toString()+`
|
|
1464
|
+
`}}else for(var W in F){var Q=F[W].toString();Q.length&&(B+='"'+W+" "+Q+`
|
|
1465
|
+
`)}Ft(y,B)},sort:function(y,E){function C(){if(E.argString){var bt=new Be.StringStream(E.argString);if(bt.eat("!")&&(W=!0),bt.eol())return;if(!bt.eatSpace())return"Invalid arguments";var $t=bt.match(/([dinuox]+)?\s*(\/.+\/)?\s*/);if(!$t&&!bt.eol())return"Invalid arguments";if($t[1]){V=$t[1].indexOf("i")!=-1,Y=$t[1].indexOf("u")!=-1;var Jn=$t[1].indexOf("d")!=-1||$t[1].indexOf("n")!=-1&&1,pr=$t[1].indexOf("x")!=-1&&1,bn=$t[1].indexOf("o")!=-1&&1;if(Jn+pr+bn>1)return"Invalid arguments";Q=Jn&&"decimal"||pr&&"hex"||bn&&"octal"}$t[2]&&(re=new RegExp($t[2].substr(1,$t[2].length-2),V?"i":""))}}function F(bt,$t){if(W){var Jn;Jn=bt,bt=$t,$t=Jn}V&&(bt=bt.toLowerCase(),$t=$t.toLowerCase());var pr=Q&&Ie.exec(bt),bn=Q&&Ie.exec($t);return pr?(pr=parseInt((pr[1]+pr[2]).toLowerCase(),He),bn=parseInt((bn[1]+bn[2]).toLowerCase(),He),pr-bn):bt<$t?-1:1}function B(bt,$t){if(W){var Jn;Jn=bt,bt=$t,$t=Jn}return V&&(bt[0]=bt[0].toLowerCase(),$t[0]=$t[0].toLowerCase()),bt[0]<$t[0]?-1:1}var W,V,Y,Q,re,le=C();if(le){Ft(y,le+": "+E.argString);return}var ye=E.line||y.firstLine(),ke=E.lineEnd||E.line||y.lastLine();if(ye!=ke){var me=new De(ye,0),be=new De(ke,Zt(y,ke)),Ne=y.getRange(me,be).split(`
|
|
1466
|
+
`),Ie=re||(Q=="decimal"?/(-?)([\d]+)/:Q=="hex"?/(-?)(?:0x)?([0-9a-f]+)/i:Q=="octal"?/([0-7]+)/:null),He=Q=="decimal"?10:Q=="hex"?16:Q=="octal"?8:null,st=[],Ye=[];if(Q||re)for(var tt=0;tt<Ne.length;tt++){var fn=re?Ne[tt].match(re):null;fn&&fn[0]!=""?st.push(fn):!re&&Ie.exec(Ne[tt])?st.push(Ne[tt]):Ye.push(Ne[tt])}else Ye=Ne;if(st.sort(re?B:F),re)for(var tt=0;tt<st.length;tt++)st[tt]=st[tt].input;else Q||Ye.sort(F);if(Ne=W?st.concat(Ye):Ye.concat(st),Y){var lt=Ne,yn;Ne=[];for(var tt=0;tt<lt.length;tt++)lt[tt]!=yn&&Ne.push(lt[tt]),yn=lt[tt]}y.replaceRange(Ne.join(`
|
|
1467
|
+
`),me,be)}},vglobal:function(y,E){this.global(y,E)},normal:function(y,E){var C=E.argString;if(C&&C[0]=="!"&&(C=C.slice(1),on=!0),C=C.trimStart(),!C){Ft(y,"Argument is required.");return}var F=E.line;if(typeof F=="number")for(var B=isNaN(E.lineEnd)?F:E.lineEnd,W=F;W<=B;W++)y.setCursor(W,0),O(y,E.argString.trimStart()),y.state.vim.insertMode&&ni(y,!0);else O(y,E.argString.trimStart()),y.state.vim.insertMode&&ni(y,!0)},global:function(y,E){var C=E.argString;if(!C){Ft(y,"Regular Expression missing from global");return}var F=E.commandName[0]==="v";C[0]==="!"&&E.commandName[0]==="g"&&(F=!0,C=C.slice(1));var B=E.line!==void 0?E.line:y.firstLine(),W=E.lineEnd||E.line||y.lastLine(),V=Er(C),Y=C,Q;if(V.length&&(Y=V[0],Q=V.slice(1,V.length).join("/")),Y)try{hn(y,Y,!0,!0)}catch{Ft(y,"Invalid regex: "+Y);return}for(var re=_n(y).getQuery(),le=[],ye=B;ye<=W;ye++){var ke=y.getLine(ye),me=re.test(ke);me!==F&&le.push(Q?y.getLineHandle(ye):ke)}if(!Q){Ft(y,le.join(`
|
|
1468
|
+
`));return}var be=0,Ne=function(){if(be<le.length){var Ie=le[be++],He=y.getLineNumber(Ie);if(He==null){Ne();return}var st=He+1+Q;br.processCommand(y,st,{callback:Ne})}else y.releaseLineHandles&&y.releaseLineHandles()};Ne()},substitute:function(y,E){if(!y.getSearchCursor)throw new Error("Search feature not available. Requires searchcursor.js or any other getSearchCursor implementation.");var C=E.argString,F=C?Zi(C,C[0]):[],B,W="",V,Y,Q,re=!1,le=!1;if(F.length)B=F[0],S("pcre")&&B!==""&&(B=new RegExp(B).source),W=F[1],W!==void 0&&(S("pcre")?W=Ol(W.replace(/([^\\])&/g,"$1$$&")):W=Ll(W),We.lastSubstituteReplacePart=W),V=F[2]?F[2].split(" "):[];else if(C&&C.length){Ft(y,"Substitutions should be of the form :s/pattern/replace/");return}if(V&&(Y=V[0],Q=parseInt(V[1]),Y&&(Y.indexOf("c")!=-1&&(re=!0),Y.indexOf("g")!=-1&&(le=!0),S("pcre")?B=B+"/"+Y:B=B.replace(/\//g,"\\/")+"/"+Y)),B)try{hn(y,B,!0,!0)}catch{Ft(y,"Invalid regex: "+B);return}if(W=W||We.lastSubstituteReplacePart,W===void 0){Ft(y,"No previous substitute regular expression");return}var ye=_n(y),ke=ye.getQuery(),me=E.line!==void 0?E.line:y.getCursor().line,be=E.lineEnd||me;me==y.firstLine()&&be==y.lastLine()&&(be=1/0),Q&&(me=be,be=me+Q-1);var Ne=ce(y,new De(me,0)),Ie=y.getSearchCursor(ke,Ne);ts(y,re,le,me,be,Ie,ke,W,E.callback)},startinsert:function(y,E){O(y,E.argString=="!"?"A":"i",{})},redo:Be.commands.redo,undo:Be.commands.undo,write:function(y){Be.commands.save?Be.commands.save(y):y.save&&y.save()},nohlsearch:function(y){es(y)},yank:function(y){var E=Ke(y.getCursor()),C=E.line,F=y.getLine(C);We.registerController.pushText("0","yank",F,!0,!0)},delete:function(y,E){var C=E.selectionLine,F=isNaN(E.selectionLineEnd)?C:E.selectionLineEnd;us.delete(y,{linewise:!0},[{anchor:new De(C,0),head:new De(F+1,0)}])},join:function(y,E){var C=E.selectionLine,F=isNaN(E.selectionLineEnd)?C:E.selectionLineEnd;y.setCursor(new De(C,0)),Ln.joinLines(y,{repeat:F-C},y.state.vim)},delmarks:function(y,E){if(!E.argString||!hi(E.argString)){Ft(y,"Argument required");return}for(var C=y.state.vim,F=new Be.StringStream(hi(E.argString));!F.eol();){F.eatSpace();var B=F.pos;if(!F.match(/[a-zA-Z]/,!1)){Ft(y,"Invalid argument: "+E.argString.substring(B));return}var W=F.next();if(F.match("-",!0)){if(!F.match(/[a-zA-Z]/,!1)){Ft(y,"Invalid argument: "+E.argString.substring(B));return}var V=W,Y=F.next();if(!(f(V)&&f(Y)||a(V)&&a(Y))){Ft(y,"Invalid argument: "+V+"-");return}var Q=V.charCodeAt(0),re=Y.charCodeAt(0);if(Q>=re){Ft(y,"Invalid argument: "+E.argString.substring(B));return}for(var le=0;le<=re-Q;le++){var ye=String.fromCharCode(Q+le);delete C.marks[ye]}}else delete C.marks[W]}}},br=new yr;M("insertModeEscKeysTimeout",200,"number"),Be.Vim=mt;var Mr={return:"CR",backspace:"BS",delete:"Del",esc:"Esc",left:"Left",right:"Right",up:"Up",down:"Down",space:"Space",insert:"Ins",home:"Home",end:"End",pageup:"PageUp",pagedown:"PageDown",enter:"CR"},vi=mt.handleKey.bind(mt);mt.handleKey=function(y,E,C){return y.operation(function(){return vi(y,E,C)},!0)},D(),r.CodeMirror=Be;var yi=mt.maybeInitVimState_;r.handler={$id:"ace/keyboard/vim",drawCursor:function(y,E,C,F,B){var W=this.state.vim||{},V=C.characterWidth,Y=C.lineHeight,Q=E.top,re=E.left;if(!W.insertMode){var le=F.cursor?ar.comparePoints(F.cursor,F.start)<=0:B.selection.isBackwards()||B.selection.isEmpty();!le&&re>V&&(re-=V)}!W.insertMode&&W.status&&(Y/=2,Q+=Y),eo.translate(y,re,Q),eo.setStyle(y.style,"width",V+"px"),eo.setStyle(y.style,"height",Y+"px")},$getDirectionForHighlight:function(y){var E=y.state.cm,C=yi(E);if(!C.insertMode)return y.session.selection.isBackwards()||y.session.selection.isEmpty()},handleKeyboard:function(y,E,C,F,B){var W=y.editor,V=W.state.cm,Y=yi(V);if(F!=-1){if(Y.insertMode||(E==-1?(C.charCodeAt(0)>255&&y.inputKey&&(C=y.inputKey,C&&y.inputHash==4&&(C=C.toUpperCase())),y.inputChar=C):E==4||E==0?y.inputKey==C&&y.inputHash==E&&y.inputChar?(C=y.inputChar,E=-1):(y.inputChar=null,y.inputKey=C,y.inputHash=E):y.inputChar=y.inputKey=null),V.state.overwrite&&Y.insertMode&&C=="backspace"&&E==0)return{command:"gotoleft"};if(C=="c"&&E==1&&!Oo.isMac&&W.getCopyText())return W.once("copy",function(){Y.insertMode?W.selection.clearSelection():V.operation(function(){Sn(V)})}),{command:"null",passEvent:!0};if(C=="esc"&&!Y.insertMode&&!Y.visualMode&&!V.ace.inMultiSelectMode){var Q=_n(V),re=Q.getOverlay();re&&V.removeOverlay(re)}if(E==-1||E&1||E===0&&C.length>1){var le=Y.insertMode,ye=Ys(E,C,B||{},Y);Y.status==null&&(Y.status="");var ke=Mo(V,ye,"user");return Y=yi(V),ke&&Y.status!=null?Y.status+=ye:Y.status==null&&(Y.status=""),V._signal("changeStatus"),!ke&&(E!=-1||le)?void 0:{command:"null",passEvent:!ke}}}},attach:function(y){function E(){var F=yi(C).insertMode;C.ace.renderer.setStyle("normal-mode",!F),y.textInput.setCommandMode(!F),y.renderer.$keepTextAreaAtCursor=F,y.renderer.$blockCursor=!F}y.state||(y.state={});var C=new Be(y);y.state.cm=C,y.$vimModeHandler=this,p(C),yi(C).status=null,C.on("vim-command-done",function(){C.virtualSelectionMode()||(yi(C).status=null,C.ace._signal("changeStatus"),C.ace.session.markUndoGroup())}),C.on("changeStatus",function(){C.ace.renderer.updateCursor(),C.ace._signal("changeStatus")}),C.on("vim-mode-change",function(){C.virtualSelectionMode()||(E(),C._signal("changeStatus"))}),E(),y.renderer.$cursorLayer.drawCursor=this.drawCursor.bind(C)},detach:function(y){var E=y.state.cm;g(E),E.destroy(),y.state.cm=null,y.$vimModeHandler=null,y.renderer.$cursorLayer.drawCursor=null,y.renderer.setStyle("normal-mode",!1),y.textInput.setCommandMode(!1),y.renderer.$keepTextAreaAtCursor=!0},getStatusText:function(y){var E=y.state.cm,C=yi(E);if(C.insertMode)return"INSERT";var F="";return C.visualMode&&(F+="VISUAL",C.visualLine&&(F+=" LINE"),C.visualBlock&&(F+=" BLOCK")),C.status&&(F+=(F?" ":"")+C.status),F}},mt.defineOption({name:"wrap",set:function(y,E){E&&E.ace.setOption("wrap",y)},type:"boolean"},!1),mt.defineEx("write","w",function(){console.log(":write is not implemented")}),Cn.push({keys:"zc",type:"action",action:"fold",actionArgs:{open:!1}},{keys:"zC",type:"action",action:"fold",actionArgs:{open:!1,all:!0}},{keys:"zo",type:"action",action:"fold",actionArgs:{open:!0}},{keys:"zO",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"za",type:"action",action:"fold",actionArgs:{toggle:!0}},{keys:"zA",type:"action",action:"fold",actionArgs:{toggle:!0,all:!0}},{keys:"zf",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"zd",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"<C-A-k>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorAbove"}},{keys:"<C-A-j>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorBelow"}},{keys:"<C-A-S-k>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorAboveSkipCurrent"}},{keys:"<C-A-S-j>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorBelowSkipCurrent"}},{keys:"<C-A-h>",type:"action",action:"aceCommand",actionArgs:{name:"selectMoreBefore"}},{keys:"<C-A-l>",type:"action",action:"aceCommand",actionArgs:{name:"selectMoreAfter"}},{keys:"<C-A-S-h>",type:"action",action:"aceCommand",actionArgs:{name:"selectNextBefore"}},{keys:"<C-A-S-l>",type:"action",action:"aceCommand",actionArgs:{name:"selectNextAfter"}}),Cn.push({keys:"gq",type:"operator",operator:"hardWrap"}),mt.defineOperator("hardWrap",function(y,E,C,F,B){var W=C[0].anchor.line,V=C[0].head.line;return E.linewise&&V--,yo(y.ace,{startRow:W,endRow:V}),De(V,0)}),M("textwidth",void 0,"number",["tw"],function(y,E){if(E!==void 0){if(y===void 0){var C=E.ace.getOption("printMarginColumn");return C}var F=Math.round(y);F>1&&E.ace.setOption("printMarginColumn",F)}}),Ln.aceCommand=function(y,E,C){y.vimCmd=E,y.ace.inVirtualSelectionMode?y.ace.on("beforeEndOperation",Ai):Ai(null,y.ace)},Ln.fold=function(y,E,C){y.ace.execCommand(["toggleFoldWidget","toggleFoldWidget","foldOther","unfoldall"][(E.all?2:0)+(E.open?1:0)])},No=Cn.length,r.handler.defaultKeymap=Cn,r.handler.actions=Ln,r.Vim=mt}),function(){ace.require(["ace/keyboard/vim"],function(t){n&&(n.exports=t)})}()}(Vm)),Vm.exports}C$();var Gm={},Ym;function $$(){return Ym||(Ym=1,function(n){(function(){var e={not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function t(b){return l(h(b),arguments)}function r(b,p){return t.apply(null,[b].concat(p||[]))}function l(b,p){var g=1,o=b.length,c,f="",u,i,a,m,w,x,M,$;for(u=0;u<o;u++)if(typeof b[u]=="string")f+=b[u];else if(typeof b[u]=="object"){if(a=b[u],a.keys)for(c=p[g],i=0;i<a.keys.length;i++){if(c==null)throw new Error(t('[sprintf] Cannot access property "%s" of undefined value "%s"',a.keys[i],a.keys[i-1]));c=c[a.keys[i]]}else a.param_no?c=p[a.param_no]:c=p[g++];if(e.not_type.test(a.type)&&e.not_primitive.test(a.type)&&c instanceof Function&&(c=c()),e.numeric_arg.test(a.type)&&typeof c!="number"&&isNaN(c))throw new TypeError(t("[sprintf] expecting number but found %T",c));switch(e.number.test(a.type)&&(M=c>=0),a.type){case"b":c=parseInt(c,10).toString(2);break;case"c":c=String.fromCharCode(parseInt(c,10));break;case"d":case"i":c=parseInt(c,10);break;case"j":c=JSON.stringify(c,null,a.width?parseInt(a.width):0);break;case"e":c=a.precision?parseFloat(c).toExponential(a.precision):parseFloat(c).toExponential();break;case"f":c=a.precision?parseFloat(c).toFixed(a.precision):parseFloat(c);break;case"g":c=a.precision?String(Number(c.toPrecision(a.precision))):parseFloat(c);break;case"o":c=(parseInt(c,10)>>>0).toString(8);break;case"s":c=String(c),c=a.precision?c.substring(0,a.precision):c;break;case"t":c=String(!!c),c=a.precision?c.substring(0,a.precision):c;break;case"T":c=Object.prototype.toString.call(c).slice(8,-1).toLowerCase(),c=a.precision?c.substring(0,a.precision):c;break;case"u":c=parseInt(c,10)>>>0;break;case"v":c=c.valueOf(),c=a.precision?c.substring(0,a.precision):c;break;case"x":c=(parseInt(c,10)>>>0).toString(16);break;case"X":c=(parseInt(c,10)>>>0).toString(16).toUpperCase();break}e.json.test(a.type)?f+=c:(e.number.test(a.type)&&(!M||a.sign)?($=M?"+":"-",c=c.toString().replace(e.sign,"")):$="",w=a.pad_char?a.pad_char==="0"?"0":a.pad_char.charAt(1):" ",x=a.width-($+c).length,m=a.width&&x>0?w.repeat(x):"",f+=a.align?$+c+m:w==="0"?$+m+c:m+$+c)}return f}var d=Object.create(null);function h(b){if(d[b])return d[b];for(var p=b,g,o=[],c=0;p;){if((g=e.text.exec(p))!==null)o.push(g[0]);else if((g=e.modulo.exec(p))!==null)o.push("%");else if((g=e.placeholder.exec(p))!==null){if(g[2]){c|=1;var f=[],u=g[2],i=[];if((i=e.key.exec(u))!==null)for(f.push(i[1]);(u=u.substring(i[0].length))!=="";)if((i=e.key_access.exec(u))!==null)f.push(i[1]);else if((i=e.index_access.exec(u))!==null)f.push(i[1]);else throw new SyntaxError("[sprintf] failed to parse named argument key");else throw new SyntaxError("[sprintf] failed to parse named argument key");g[2]=f}else c|=2;if(c===3)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");o.push({placeholder:g[0],param_no:g[1],keys:g[2],sign:g[3],pad_char:g[4],align:g[5],width:g[6],precision:g[7],type:g[8]})}else throw new SyntaxError("[sprintf] unexpected placeholder");p=p.substring(g[0].length)}return d[b]=o}n.sprintf=t,n.vsprintf=r,typeof window<"u"&&(window.sprintf=t,window.vsprintf=r)})()}(Gm)),Gm}$$();var Cc={exports:{}};/**
|
|
1469
|
+
* @license
|
|
1470
|
+
* Lodash <https://lodash.com/>
|
|
1471
|
+
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
1472
|
+
* Released under MIT license <https://lodash.com/license>
|
|
1473
|
+
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|
1474
|
+
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
1475
|
+
*/var A$=Cc.exports,Xm;function E$(){return Xm||(Xm=1,function(n,e){(function(){var t,r="4.17.21",l=200,d="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",h="Expected a function",b="Invalid `variable` option passed into `_.template`",p="__lodash_hash_undefined__",g=500,o="__lodash_placeholder__",c=1,f=2,u=4,i=1,a=2,m=1,w=2,x=4,M=8,$=16,S=32,k=64,T=128,D=256,L=512,O=30,z="...",P=800,N=16,A=1,_=2,I=3,j=1/0,U=9007199254740991,K=17976931348623157e292,Z=NaN,J=4294967295,ae=J-1,ne=J>>>1,se=[["ary",T],["bind",m],["bindKey",w],["curry",M],["curryRight",$],["flip",L],["partial",S],["partialRight",k],["rearg",D]],ce="[object Arguments]",he="[object Array]",ge="[object AsyncFunction]",Ee="[object Boolean]",Te="[object Date]",Me="[object DOMException]",Xe="[object Error]",Ke="[object Function]",dt="[object GeneratorFunction]",rt="[object Map]",gt="[object Number]",tn="[object Null]",jn="[object Object]",Zt="[object Promise]",hi="[object Proxy]",kn="[object RegExp]",Xn="[object Set]",ur="[object String]",Pr="[object Symbol]",yt="[object Undefined]",qe="[object WeakMap]",qt="[object WeakSet]",gn="[object ArrayBuffer]",Qn="[object DataView]",Br="[object Float32Array]",$r="[object Float64Array]",Sn="[object Int8Array]",ir="[object Int16Array]",hr="[object Int32Array]",nn="[object Uint8Array]",or="[object Uint8ClampedArray]",$o="[object Uint16Array]",Ki="[object Uint32Array]",Gi=/\b__p \+= '';/g,Yi=/\b(__p \+=) '' \+/g,Ao=/(__e\(.*?\)|\b__t\)) \+\n'';/g,vr=/&(?:amp|lt|gt|quot|#39);/g,Eo=/[&<>"']/g,Jo=RegExp(vr.source),Rl=RegExp(Eo.source),di=/<%-([\s\S]+?)%>/g,Ml=/<%([\s\S]+?)%>/g,zs=/<%=([\s\S]+?)%>/g,Oa=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Xi=/^\w*$/,Wn=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ar=/[\\^$.*+?()[\]{}|]/g,Qi=RegExp(Ar.source),_n=/^\s+/,Er=/\s/,po=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Zi=/\{\n\/\* \[wrapped with (.+)\] \*/,Hs=/,? & /,Ia=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Ll=/[()=,{}\[\]\/\s]/,Ol=/\\(\\)?/g,Ji=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,fi=/\w*$/,Ft=/^[-+]0x[0-9a-f]+$/i,Na=/^0b[01]+$/i,Tr=/^\[object .+?Constructor\]$/,zn=/^0o[0-7]+$/i,hn=/^(?:0|[1-9]\d*)$/,Tn=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Ci=/($^)/,Rr=/['\n\r\u2028\u2029\\]/g,$i="\\ud800-\\udfff",es="\\u0300-\\u036f",Us="\\ufe20-\\ufe2f",go="\\u20d0-\\u20ff",ti=es+Us+go,To="\\u2700-\\u27bf",ts="a-z\\xdf-\\xf6\\xf8-\\xff",ni="\\xac\\xb1\\xd7\\xf7",ns="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",qs="\\u2000-\\u206f",Vs=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",rs="A-Z\\xc0-\\xd6\\xd8-\\xde",sr="\\ufe0e\\ufe0f",Ks=ni+ns+qs+Vs,Ro="['’]",is="["+$i+"]",os="["+Ks+"]",mo="["+ti+"]",Gs="\\d+",Da="["+To+"]",ss="["+ts+"]",as="[^"+$i+Ks+Gs+To+ts+rs+"]",Ys="\\ud83c[\\udffb-\\udfff]",ls="(?:"+mo+"|"+Ys+")",Mo="[^"+$i+"]",Ai="(?:\\ud83c[\\udde6-\\uddff]){2}",ar="[\\ud800-\\udbff][\\udc00-\\udfff]",vo="["+rs+"]",eo="\\u200d",Fa="(?:"+ss+"|"+as+")",Il="(?:"+vo+"|"+as+")",Lo="(?:"+Ro+"(?:d|ll|m|re|s|t|ve))?",to="(?:"+Ro+"(?:D|LL|M|RE|S|T|VE))?",Oo=ls+"?",cs="["+sr+"]?",Io="(?:"+eo+"(?:"+[Mo,Ai,ar].join("|")+")"+cs+Oo+")*",Pa="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",yo="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Be=cs+Oo+Io,Ba="(?:"+[Da,Ai,ar].join("|")+")"+Be,De="(?:"+[Mo+mo+"?",mo,Ai,ar,is].join("|")+")",Cn=RegExp(Ro,"g"),No=RegExp(mo,"g"),pi=RegExp(Ys+"(?="+Ys+")|"+De+Be,"g"),Hn=RegExp([vo+"?"+ss+"+"+Lo+"(?="+[os,vo,"$"].join("|")+")",Il+"+"+to+"(?="+[os,vo+Fa,"$"].join("|")+")",vo+"?"+Fa+"+"+Lo,vo+"+"+to,yo,Pa,Gs,Ba].join("|"),"g"),ja=RegExp("["+eo+$i+ti+sr+"]"),Do=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Ei=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],bo=-1,Yt={};Yt[Br]=Yt[$r]=Yt[Sn]=Yt[ir]=Yt[hr]=Yt[nn]=Yt[or]=Yt[$o]=Yt[Ki]=!0,Yt[ce]=Yt[he]=Yt[gn]=Yt[Ee]=Yt[Qn]=Yt[Te]=Yt[Xe]=Yt[Ke]=Yt[rt]=Yt[gt]=Yt[jn]=Yt[kn]=Yt[Xn]=Yt[ur]=Yt[qe]=!1;var Vt={};Vt[ce]=Vt[he]=Vt[gn]=Vt[Qn]=Vt[Ee]=Vt[Te]=Vt[Br]=Vt[$r]=Vt[Sn]=Vt[ir]=Vt[hr]=Vt[rt]=Vt[gt]=Vt[jn]=Vt[kn]=Vt[Xn]=Vt[ur]=Vt[Pr]=Vt[nn]=Vt[or]=Vt[$o]=Vt[Ki]=!0,Vt[Xe]=Vt[Ke]=Vt[qe]=!1;var Xt={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},Pt={"&":"&","<":"<",">":">",'"':""","'":"'"},Ti={"&":"&","<":"<",">":">",""":'"',"'":"'"},Rn={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},We=parseFloat,dn=parseInt,mt=typeof Xo=="object"&&Xo&&Xo.Object===Object&&Xo,jr=typeof self=="object"&&self&&self.Object===Object&&self,on=mt||jr||Function("return this")(),mn=e&&!e.nodeType&&e,Zn=mn&&!0&&n&&!n.nodeType&&n,Wr=Zn&&Zn.exports===mn,Ri=Wr&&mt.process,Mn=function(){try{var fe=Zn&&Zn.require&&Zn.require("util").types;return fe||Ri&&Ri.binding&&Ri.binding("util")}catch{}}(),ri=Mn&&Mn.isArrayBuffer,us=Mn&&Mn.isDate,Ln=Mn&&Mn.isMap,gi=Mn&&Mn.isRegExp,mi=Mn&&Mn.isSet,Mi=Mn&&Mn.isTypedArray;function dr(fe,Ae,xe){switch(xe.length){case 0:return fe.call(Ae);case 1:return fe.call(Ae,xe[0]);case 2:return fe.call(Ae,xe[0],xe[1]);case 3:return fe.call(Ae,xe[0],xe[1],xe[2])}return fe.apply(Ae,xe)}function fr(fe,Ae,xe,ze){for(var ct=-1,At=fe==null?0:fe.length;++ct<At;){var Ht=fe[ct];Ae(ze,Ht,xe(Ht),fe)}return ze}function yr(fe,Ae){for(var xe=-1,ze=fe==null?0:fe.length;++xe<ze&&Ae(fe[xe],xe,fe)!==!1;);return fe}function Xs(fe,Ae){for(var xe=fe==null?0:fe.length;xe--&&Ae(fe[xe],xe,fe)!==!1;);return fe}function br(fe,Ae){for(var xe=-1,ze=fe==null?0:fe.length;++xe<ze;)if(!Ae(fe[xe],xe,fe))return!1;return!0}function Mr(fe,Ae){for(var xe=-1,ze=fe==null?0:fe.length,ct=0,At=[];++xe<ze;){var Ht=fe[xe];Ae(Ht,xe,fe)&&(At[ct++]=Ht)}return At}function vi(fe,Ae){var xe=fe==null?0:fe.length;return!!xe&&le(fe,Ae,0)>-1}function yi(fe,Ae,xe){for(var ze=-1,ct=fe==null?0:fe.length;++ze<ct;)if(xe(Ae,fe[ze]))return!0;return!1}function y(fe,Ae){for(var xe=-1,ze=fe==null?0:fe.length,ct=Array(ze);++xe<ze;)ct[xe]=Ae(fe[xe],xe,fe);return ct}function E(fe,Ae){for(var xe=-1,ze=Ae.length,ct=fe.length;++xe<ze;)fe[ct+xe]=Ae[xe];return fe}function C(fe,Ae,xe,ze){var ct=-1,At=fe==null?0:fe.length;for(ze&&At&&(xe=fe[++ct]);++ct<At;)xe=Ae(xe,fe[ct],ct,fe);return xe}function F(fe,Ae,xe,ze){var ct=fe==null?0:fe.length;for(ze&&ct&&(xe=fe[--ct]);ct--;)xe=Ae(xe,fe[ct],ct,fe);return xe}function B(fe,Ae){for(var xe=-1,ze=fe==null?0:fe.length;++xe<ze;)if(Ae(fe[xe],xe,fe))return!0;return!1}var W=be("length");function V(fe){return fe.split("")}function Y(fe){return fe.match(Ia)||[]}function Q(fe,Ae,xe){var ze;return xe(fe,function(ct,At,Ht){if(Ae(ct,At,Ht))return ze=At,!1}),ze}function re(fe,Ae,xe,ze){for(var ct=fe.length,At=xe+(ze?1:-1);ze?At--:++At<ct;)if(Ae(fe[At],At,fe))return At;return-1}function le(fe,Ae,xe){return Ae===Ae?Qe(fe,Ae,xe):re(fe,ke,xe)}function ye(fe,Ae,xe,ze){for(var ct=xe-1,At=fe.length;++ct<At;)if(ze(fe[ct],Ae))return ct;return-1}function ke(fe){return fe!==fe}function me(fe,Ae){var xe=fe==null?0:fe.length;return xe?st(fe,Ae)/xe:Z}function be(fe){return function(Ae){return Ae==null?t:Ae[fe]}}function Ne(fe){return function(Ae){return fe==null?t:fe[Ae]}}function Ie(fe,Ae,xe,ze,ct){return ct(fe,function(At,Ht,Tt){xe=ze?(ze=!1,At):Ae(xe,At,Ht,Tt)}),xe}function He(fe,Ae){var xe=fe.length;for(fe.sort(Ae);xe--;)fe[xe]=fe[xe].value;return fe}function st(fe,Ae){for(var xe,ze=-1,ct=fe.length;++ze<ct;){var At=Ae(fe[ze]);At!==t&&(xe=xe===t?At:xe+At)}return xe}function Ye(fe,Ae){for(var xe=-1,ze=Array(fe);++xe<fe;)ze[xe]=Ae(xe);return ze}function tt(fe,Ae){return y(Ae,function(xe){return[xe,fe[xe]]})}function fn(fe){return fe&&fe.slice(0,Mt(fe)+1).replace(_n,"")}function lt(fe){return function(Ae){return fe(Ae)}}function yn(fe,Ae){return y(Ae,function(xe){return fe[xe]})}function bt(fe,Ae){return fe.has(Ae)}function $t(fe,Ae){for(var xe=-1,ze=fe.length;++xe<ze&&le(Ae,fe[xe],0)>-1;);return xe}function Jn(fe,Ae){for(var xe=fe.length;xe--&&le(Ae,fe[xe],0)>-1;);return xe}function pr(fe,Ae){for(var xe=fe.length,ze=0;xe--;)fe[xe]===Ae&&++ze;return ze}var bn=Ne(Xt),q=Ne(Pt);function X(fe){return"\\"+Rn[fe]}function ie(fe,Ae){return fe==null?t:fe[Ae]}function oe(fe){return ja.test(fe)}function pe(fe){return Do.test(fe)}function we(fe){for(var Ae,xe=[];!(Ae=fe.next()).done;)xe.push(Ae.value);return xe}function Re(fe){var Ae=-1,xe=Array(fe.size);return fe.forEach(function(ze,ct){xe[++Ae]=[ct,ze]}),xe}function Pe(fe,Ae){return function(xe){return fe(Ae(xe))}}function je(fe,Ae){for(var xe=-1,ze=fe.length,ct=0,At=[];++xe<ze;){var Ht=fe[xe];(Ht===Ae||Ht===o)&&(fe[xe]=o,At[ct++]=xe)}return At}function Ue(fe){var Ae=-1,xe=Array(fe.size);return fe.forEach(function(ze){xe[++Ae]=ze}),xe}function Ge(fe){var Ae=-1,xe=Array(fe.size);return fe.forEach(function(ze){xe[++Ae]=[ze,ze]}),xe}function Qe(fe,Ae,xe){for(var ze=xe-1,ct=fe.length;++ze<ct;)if(fe[ze]===Ae)return ze;return-1}function vt(fe,Ae,xe){for(var ze=xe+1;ze--;)if(fe[ze]===Ae)return ze;return ze}function It(fe){return oe(fe)?it(fe):W(fe)}function wt(fe){return oe(fe)?un(fe):V(fe)}function Mt(fe){for(var Ae=fe.length;Ae--&&Er.test(fe.charAt(Ae)););return Ae}var ut=Ne(Ti);function it(fe){for(var Ae=pi.lastIndex=0;pi.test(fe);)++Ae;return Ae}function un(fe){return fe.match(pi)||[]}function wn(fe){return fe.match(Hn)||[]}var er=function fe(Ae){Ae=Ae==null?on:jt.defaults(on.Object(),Ae,jt.pick(on,Ei));var xe=Ae.Array,ze=Ae.Date,ct=Ae.Error,At=Ae.Function,Ht=Ae.Math,Tt=Ae.Object,zr=Ae.RegExp,Li=Ae.String,sn=Ae.TypeError,gr=xe.prototype,Fo=At.prototype,On=Tt.prototype,Qs=Ae["__core-js_shared__"],fu=Fo.toString,rn=On.hasOwnProperty,vI=0,e0=function(){var s=/[^.]+$/.exec(Qs&&Qs.keys&&Qs.keys.IE_PROTO||"");return s?"Symbol(src)_1."+s:""}(),pu=On.toString,yI=fu.call(Tt),bI=on._,wI=zr("^"+fu.call(rn).replace(Ar,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),gu=Wr?Ae.Buffer:t,hs=Ae.Symbol,mu=Ae.Uint8Array,t0=gu?gu.allocUnsafe:t,vu=Pe(Tt.getPrototypeOf,Tt),n0=Tt.create,r0=On.propertyIsEnumerable,yu=gr.splice,i0=hs?hs.isConcatSpreadable:t,Nl=hs?hs.iterator:t,Zs=hs?hs.toStringTag:t,bu=function(){try{var s=ra(Tt,"defineProperty");return s({},"",{}),s}catch{}}(),xI=Ae.clearTimeout!==on.clearTimeout&&Ae.clearTimeout,kI=ze&&ze.now!==on.Date.now&&ze.now,SI=Ae.setTimeout!==on.setTimeout&&Ae.setTimeout,wu=Ht.ceil,xu=Ht.floor,$f=Tt.getOwnPropertySymbols,_I=gu?gu.isBuffer:t,o0=Ae.isFinite,CI=gr.join,$I=Pe(Tt.keys,Tt),lr=Ht.max,Lr=Ht.min,AI=ze.now,EI=Ae.parseInt,s0=Ht.random,TI=gr.reverse,Af=ra(Ae,"DataView"),Dl=ra(Ae,"Map"),Ef=ra(Ae,"Promise"),Wa=ra(Ae,"Set"),Fl=ra(Ae,"WeakMap"),Pl=ra(Tt,"create"),ku=Fl&&new Fl,za={},RI=ia(Af),MI=ia(Dl),LI=ia(Ef),OI=ia(Wa),II=ia(Fl),Su=hs?hs.prototype:t,Bl=Su?Su.valueOf:t,a0=Su?Su.toString:t;function ee(s){if(In(s)&&!xt(s)&&!(s instanceof Bt)){if(s instanceof Oi)return s;if(rn.call(s,"__wrapped__"))return lx(s)}return new Oi(s)}var Ha=function(){function s(){}return function(v){if(!$n(v))return{};if(n0)return n0(v);s.prototype=v;var R=new s;return s.prototype=t,R}}();function _u(){}function Oi(s,v){this.__wrapped__=s,this.__actions__=[],this.__chain__=!!v,this.__index__=0,this.__values__=t}ee.templateSettings={escape:di,evaluate:Ml,interpolate:zs,variable:"",imports:{_:ee}},ee.prototype=_u.prototype,ee.prototype.constructor=ee,Oi.prototype=Ha(_u.prototype),Oi.prototype.constructor=Oi;function Bt(s){this.__wrapped__=s,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=J,this.__views__=[]}function NI(){var s=new Bt(this.__wrapped__);return s.__actions__=ii(this.__actions__),s.__dir__=this.__dir__,s.__filtered__=this.__filtered__,s.__iteratees__=ii(this.__iteratees__),s.__takeCount__=this.__takeCount__,s.__views__=ii(this.__views__),s}function DI(){if(this.__filtered__){var s=new Bt(this);s.__dir__=-1,s.__filtered__=!0}else s=this.clone(),s.__dir__*=-1;return s}function FI(){var s=this.__wrapped__.value(),v=this.__dir__,R=xt(s),H=v<0,G=R?s.length:0,te=Y2(0,G,this.__views__),ue=te.start,de=te.end,ve=de-ue,Le=H?de:ue-1,Oe=this.__iteratees__,Fe=Oe.length,Ve=0,nt=Lr(ve,this.__takeCount__);if(!R||!H&&G==ve&&nt==ve)return M0(s,this.__actions__);var ft=[];e:for(;ve--&&Ve<nt;){Le+=v;for(var Rt=-1,pt=s[Le];++Rt<Fe;){var Nt=Oe[Rt],Wt=Nt.iteratee,xi=Nt.type,qr=Wt(pt);if(xi==_)pt=qr;else if(!qr){if(xi==A)continue e;break e}}ft[Ve++]=pt}return ft}Bt.prototype=Ha(_u.prototype),Bt.prototype.constructor=Bt;function Js(s){var v=-1,R=s==null?0:s.length;for(this.clear();++v<R;){var H=s[v];this.set(H[0],H[1])}}function PI(){this.__data__=Pl?Pl(null):{},this.size=0}function BI(s){var v=this.has(s)&&delete this.__data__[s];return this.size-=v?1:0,v}function jI(s){var v=this.__data__;if(Pl){var R=v[s];return R===p?t:R}return rn.call(v,s)?v[s]:t}function WI(s){var v=this.__data__;return Pl?v[s]!==t:rn.call(v,s)}function zI(s,v){var R=this.__data__;return this.size+=this.has(s)?0:1,R[s]=Pl&&v===t?p:v,this}Js.prototype.clear=PI,Js.prototype.delete=BI,Js.prototype.get=jI,Js.prototype.has=WI,Js.prototype.set=zI;function Po(s){var v=-1,R=s==null?0:s.length;for(this.clear();++v<R;){var H=s[v];this.set(H[0],H[1])}}function HI(){this.__data__=[],this.size=0}function UI(s){var v=this.__data__,R=Cu(v,s);if(R<0)return!1;var H=v.length-1;return R==H?v.pop():yu.call(v,R,1),--this.size,!0}function qI(s){var v=this.__data__,R=Cu(v,s);return R<0?t:v[R][1]}function VI(s){return Cu(this.__data__,s)>-1}function KI(s,v){var R=this.__data__,H=Cu(R,s);return H<0?(++this.size,R.push([s,v])):R[H][1]=v,this}Po.prototype.clear=HI,Po.prototype.delete=UI,Po.prototype.get=qI,Po.prototype.has=VI,Po.prototype.set=KI;function Bo(s){var v=-1,R=s==null?0:s.length;for(this.clear();++v<R;){var H=s[v];this.set(H[0],H[1])}}function GI(){this.size=0,this.__data__={hash:new Js,map:new(Dl||Po),string:new Js}}function YI(s){var v=Fu(this,s).delete(s);return this.size-=v?1:0,v}function XI(s){return Fu(this,s).get(s)}function QI(s){return Fu(this,s).has(s)}function ZI(s,v){var R=Fu(this,s),H=R.size;return R.set(s,v),this.size+=R.size==H?0:1,this}Bo.prototype.clear=GI,Bo.prototype.delete=YI,Bo.prototype.get=XI,Bo.prototype.has=QI,Bo.prototype.set=ZI;function ea(s){var v=-1,R=s==null?0:s.length;for(this.__data__=new Bo;++v<R;)this.add(s[v])}function JI(s){return this.__data__.set(s,p),this}function e2(s){return this.__data__.has(s)}ea.prototype.add=ea.prototype.push=JI,ea.prototype.has=e2;function no(s){var v=this.__data__=new Po(s);this.size=v.size}function t2(){this.__data__=new Po,this.size=0}function n2(s){var v=this.__data__,R=v.delete(s);return this.size=v.size,R}function r2(s){return this.__data__.get(s)}function i2(s){return this.__data__.has(s)}function o2(s,v){var R=this.__data__;if(R instanceof Po){var H=R.__data__;if(!Dl||H.length<l-1)return H.push([s,v]),this.size=++R.size,this;R=this.__data__=new Bo(H)}return R.set(s,v),this.size=R.size,this}no.prototype.clear=t2,no.prototype.delete=n2,no.prototype.get=r2,no.prototype.has=i2,no.prototype.set=o2;function l0(s,v){var R=xt(s),H=!R&&oa(s),G=!R&&!H&&ms(s),te=!R&&!H&&!G&&Ka(s),ue=R||H||G||te,de=ue?Ye(s.length,Li):[],ve=de.length;for(var Le in s)(v||rn.call(s,Le))&&!(ue&&(Le=="length"||G&&(Le=="offset"||Le=="parent")||te&&(Le=="buffer"||Le=="byteLength"||Le=="byteOffset")||Ho(Le,ve)))&&de.push(Le);return de}function c0(s){var v=s.length;return v?s[Bf(0,v-1)]:t}function s2(s,v){return Pu(ii(s),ta(v,0,s.length))}function a2(s){return Pu(ii(s))}function Tf(s,v,R){(R!==t&&!ro(s[v],R)||R===t&&!(v in s))&&jo(s,v,R)}function jl(s,v,R){var H=s[v];(!(rn.call(s,v)&&ro(H,R))||R===t&&!(v in s))&&jo(s,v,R)}function Cu(s,v){for(var R=s.length;R--;)if(ro(s[R][0],v))return R;return-1}function l2(s,v,R,H){return ds(s,function(G,te,ue){v(H,G,R(G),ue)}),H}function u0(s,v){return s&&xo(v,mr(v),s)}function c2(s,v){return s&&xo(v,si(v),s)}function jo(s,v,R){v=="__proto__"&&bu?bu(s,v,{configurable:!0,enumerable:!0,value:R,writable:!0}):s[v]=R}function Rf(s,v){for(var R=-1,H=v.length,G=xe(H),te=s==null;++R<H;)G[R]=te?t:up(s,v[R]);return G}function ta(s,v,R){return s===s&&(R!==t&&(s=s<=R?s:R),v!==t&&(s=s>=v?s:v)),s}function Ii(s,v,R,H,G,te){var ue,de=v&c,ve=v&f,Le=v&u;if(R&&(ue=G?R(s,H,G,te):R(s)),ue!==t)return ue;if(!$n(s))return s;var Oe=xt(s);if(Oe){if(ue=Q2(s),!de)return ii(s,ue)}else{var Fe=Or(s),Ve=Fe==Ke||Fe==dt;if(ms(s))return I0(s,de);if(Fe==jn||Fe==ce||Ve&&!G){if(ue=ve||Ve?{}:J0(s),!de)return ve?j2(s,c2(ue,s)):B2(s,u0(ue,s))}else{if(!Vt[Fe])return G?s:{};ue=Z2(s,Fe,de)}}te||(te=new no);var nt=te.get(s);if(nt)return nt;te.set(s,ue),Ex(s)?s.forEach(function(pt){ue.add(Ii(pt,v,R,pt,s,te))}):$x(s)&&s.forEach(function(pt,Nt){ue.set(Nt,Ii(pt,v,R,Nt,s,te))});var ft=Le?ve?Xf:Yf:ve?si:mr,Rt=Oe?t:ft(s);return yr(Rt||s,function(pt,Nt){Rt&&(Nt=pt,pt=s[Nt]),jl(ue,Nt,Ii(pt,v,R,Nt,s,te))}),ue}function u2(s){var v=mr(s);return function(R){return h0(R,s,v)}}function h0(s,v,R){var H=R.length;if(s==null)return!H;for(s=Tt(s);H--;){var G=R[H],te=v[G],ue=s[G];if(ue===t&&!(G in s)||!te(ue))return!1}return!0}function d0(s,v,R){if(typeof s!="function")throw new sn(h);return Kl(function(){s.apply(t,R)},v)}function Wl(s,v,R,H){var G=-1,te=vi,ue=!0,de=s.length,ve=[],Le=v.length;if(!de)return ve;R&&(v=y(v,lt(R))),H?(te=yi,ue=!1):v.length>=l&&(te=bt,ue=!1,v=new ea(v));e:for(;++G<de;){var Oe=s[G],Fe=R==null?Oe:R(Oe);if(Oe=H||Oe!==0?Oe:0,ue&&Fe===Fe){for(var Ve=Le;Ve--;)if(v[Ve]===Fe)continue e;ve.push(Oe)}else te(v,Fe,H)||ve.push(Oe)}return ve}var ds=B0(wo),f0=B0(Lf,!0);function h2(s,v){var R=!0;return ds(s,function(H,G,te){return R=!!v(H,G,te),R}),R}function $u(s,v,R){for(var H=-1,G=s.length;++H<G;){var te=s[H],ue=v(te);if(ue!=null&&(de===t?ue===ue&&!wi(ue):R(ue,de)))var de=ue,ve=te}return ve}function d2(s,v,R,H){var G=s.length;for(R=Et(R),R<0&&(R=-R>G?0:G+R),H=H===t||H>G?G:Et(H),H<0&&(H+=G),H=R>H?0:Rx(H);R<H;)s[R++]=v;return s}function p0(s,v){var R=[];return ds(s,function(H,G,te){v(H,G,te)&&R.push(H)}),R}function wr(s,v,R,H,G){var te=-1,ue=s.length;for(R||(R=eN),G||(G=[]);++te<ue;){var de=s[te];v>0&&R(de)?v>1?wr(de,v-1,R,H,G):E(G,de):H||(G[G.length]=de)}return G}var Mf=j0(),g0=j0(!0);function wo(s,v){return s&&Mf(s,v,mr)}function Lf(s,v){return s&&g0(s,v,mr)}function Au(s,v){return Mr(v,function(R){return Uo(s[R])})}function na(s,v){v=ps(v,s);for(var R=0,H=v.length;s!=null&&R<H;)s=s[ko(v[R++])];return R&&R==H?s:t}function m0(s,v,R){var H=v(s);return xt(s)?H:E(H,R(s))}function Hr(s){return s==null?s===t?yt:tn:Zs&&Zs in Tt(s)?G2(s):aN(s)}function Of(s,v){return s>v}function f2(s,v){return s!=null&&rn.call(s,v)}function p2(s,v){return s!=null&&v in Tt(s)}function g2(s,v,R){return s>=Lr(v,R)&&s<lr(v,R)}function If(s,v,R){for(var H=R?yi:vi,G=s[0].length,te=s.length,ue=te,de=xe(te),ve=1/0,Le=[];ue--;){var Oe=s[ue];ue&&v&&(Oe=y(Oe,lt(v))),ve=Lr(Oe.length,ve),de[ue]=!R&&(v||G>=120&&Oe.length>=120)?new ea(ue&&Oe):t}Oe=s[0];var Fe=-1,Ve=de[0];e:for(;++Fe<G&&Le.length<ve;){var nt=Oe[Fe],ft=v?v(nt):nt;if(nt=R||nt!==0?nt:0,!(Ve?bt(Ve,ft):H(Le,ft,R))){for(ue=te;--ue;){var Rt=de[ue];if(!(Rt?bt(Rt,ft):H(s[ue],ft,R)))continue e}Ve&&Ve.push(ft),Le.push(nt)}}return Le}function m2(s,v,R,H){return wo(s,function(G,te,ue){v(H,R(G),te,ue)}),H}function zl(s,v,R){v=ps(v,s),s=rx(s,v);var H=s==null?s:s[ko(Di(v))];return H==null?t:dr(H,s,R)}function v0(s){return In(s)&&Hr(s)==ce}function v2(s){return In(s)&&Hr(s)==gn}function y2(s){return In(s)&&Hr(s)==Te}function Hl(s,v,R,H,G){return s===v?!0:s==null||v==null||!In(s)&&!In(v)?s!==s&&v!==v:b2(s,v,R,H,Hl,G)}function b2(s,v,R,H,G,te){var ue=xt(s),de=xt(v),ve=ue?he:Or(s),Le=de?he:Or(v);ve=ve==ce?jn:ve,Le=Le==ce?jn:Le;var Oe=ve==jn,Fe=Le==jn,Ve=ve==Le;if(Ve&&ms(s)){if(!ms(v))return!1;ue=!0,Oe=!1}if(Ve&&!Oe)return te||(te=new no),ue||Ka(s)?X0(s,v,R,H,G,te):V2(s,v,ve,R,H,G,te);if(!(R&i)){var nt=Oe&&rn.call(s,"__wrapped__"),ft=Fe&&rn.call(v,"__wrapped__");if(nt||ft){var Rt=nt?s.value():s,pt=ft?v.value():v;return te||(te=new no),G(Rt,pt,R,H,te)}}return Ve?(te||(te=new no),K2(s,v,R,H,G,te)):!1}function w2(s){return In(s)&&Or(s)==rt}function Nf(s,v,R,H){var G=R.length,te=G,ue=!H;if(s==null)return!te;for(s=Tt(s);G--;){var de=R[G];if(ue&&de[2]?de[1]!==s[de[0]]:!(de[0]in s))return!1}for(;++G<te;){de=R[G];var ve=de[0],Le=s[ve],Oe=de[1];if(ue&&de[2]){if(Le===t&&!(ve in s))return!1}else{var Fe=new no;if(H)var Ve=H(Le,Oe,ve,s,v,Fe);if(!(Ve===t?Hl(Oe,Le,i|a,H,Fe):Ve))return!1}}return!0}function y0(s){if(!$n(s)||nN(s))return!1;var v=Uo(s)?wI:Tr;return v.test(ia(s))}function x2(s){return In(s)&&Hr(s)==kn}function k2(s){return In(s)&&Or(s)==Xn}function S2(s){return In(s)&&Uu(s.length)&&!!Yt[Hr(s)]}function b0(s){return typeof s=="function"?s:s==null?ai:typeof s=="object"?xt(s)?k0(s[0],s[1]):x0(s):Wx(s)}function Df(s){if(!Vl(s))return $I(s);var v=[];for(var R in Tt(s))rn.call(s,R)&&R!="constructor"&&v.push(R);return v}function _2(s){if(!$n(s))return sN(s);var v=Vl(s),R=[];for(var H in s)H=="constructor"&&(v||!rn.call(s,H))||R.push(H);return R}function Ff(s,v){return s<v}function w0(s,v){var R=-1,H=oi(s)?xe(s.length):[];return ds(s,function(G,te,ue){H[++R]=v(G,te,ue)}),H}function x0(s){var v=Zf(s);return v.length==1&&v[0][2]?tx(v[0][0],v[0][1]):function(R){return R===s||Nf(R,s,v)}}function k0(s,v){return ep(s)&&ex(v)?tx(ko(s),v):function(R){var H=up(R,s);return H===t&&H===v?hp(R,s):Hl(v,H,i|a)}}function Eu(s,v,R,H,G){s!==v&&Mf(v,function(te,ue){if(G||(G=new no),$n(te))C2(s,v,ue,R,Eu,H,G);else{var de=H?H(np(s,ue),te,ue+"",s,v,G):t;de===t&&(de=te),Tf(s,ue,de)}},si)}function C2(s,v,R,H,G,te,ue){var de=np(s,R),ve=np(v,R),Le=ue.get(ve);if(Le){Tf(s,R,Le);return}var Oe=te?te(de,ve,R+"",s,v,ue):t,Fe=Oe===t;if(Fe){var Ve=xt(ve),nt=!Ve&&ms(ve),ft=!Ve&&!nt&&Ka(ve);Oe=ve,Ve||nt||ft?xt(de)?Oe=de:Un(de)?Oe=ii(de):nt?(Fe=!1,Oe=I0(ve,!0)):ft?(Fe=!1,Oe=N0(ve,!0)):Oe=[]:Gl(ve)||oa(ve)?(Oe=de,oa(de)?Oe=Mx(de):(!$n(de)||Uo(de))&&(Oe=J0(ve))):Fe=!1}Fe&&(ue.set(ve,Oe),G(Oe,ve,H,te,ue),ue.delete(ve)),Tf(s,R,Oe)}function S0(s,v){var R=s.length;if(R)return v+=v<0?R:0,Ho(v,R)?s[v]:t}function _0(s,v,R){v.length?v=y(v,function(te){return xt(te)?function(ue){return na(ue,te.length===1?te[0]:te)}:te}):v=[ai];var H=-1;v=y(v,lt(ht()));var G=w0(s,function(te,ue,de){var ve=y(v,function(Le){return Le(te)});return{criteria:ve,index:++H,value:te}});return He(G,function(te,ue){return P2(te,ue,R)})}function $2(s,v){return C0(s,v,function(R,H){return hp(s,H)})}function C0(s,v,R){for(var H=-1,G=v.length,te={};++H<G;){var ue=v[H],de=na(s,ue);R(de,ue)&&Ul(te,ps(ue,s),de)}return te}function A2(s){return function(v){return na(v,s)}}function Pf(s,v,R,H){var G=H?ye:le,te=-1,ue=v.length,de=s;for(s===v&&(v=ii(v)),R&&(de=y(s,lt(R)));++te<ue;)for(var ve=0,Le=v[te],Oe=R?R(Le):Le;(ve=G(de,Oe,ve,H))>-1;)de!==s&&yu.call(de,ve,1),yu.call(s,ve,1);return s}function $0(s,v){for(var R=s?v.length:0,H=R-1;R--;){var G=v[R];if(R==H||G!==te){var te=G;Ho(G)?yu.call(s,G,1):zf(s,G)}}return s}function Bf(s,v){return s+xu(s0()*(v-s+1))}function E2(s,v,R,H){for(var G=-1,te=lr(wu((v-s)/(R||1)),0),ue=xe(te);te--;)ue[H?te:++G]=s,s+=R;return ue}function jf(s,v){var R="";if(!s||v<1||v>U)return R;do v%2&&(R+=s),v=xu(v/2),v&&(s+=s);while(v);return R}function Lt(s,v){return rp(nx(s,v,ai),s+"")}function T2(s){return c0(Ga(s))}function R2(s,v){var R=Ga(s);return Pu(R,ta(v,0,R.length))}function Ul(s,v,R,H){if(!$n(s))return s;v=ps(v,s);for(var G=-1,te=v.length,ue=te-1,de=s;de!=null&&++G<te;){var ve=ko(v[G]),Le=R;if(ve==="__proto__"||ve==="constructor"||ve==="prototype")return s;if(G!=ue){var Oe=de[ve];Le=H?H(Oe,ve,de):t,Le===t&&(Le=$n(Oe)?Oe:Ho(v[G+1])?[]:{})}jl(de,ve,Le),de=de[ve]}return s}var A0=ku?function(s,v){return ku.set(s,v),s}:ai,M2=bu?function(s,v){return bu(s,"toString",{configurable:!0,enumerable:!1,value:fp(v),writable:!0})}:ai;function L2(s){return Pu(Ga(s))}function Ni(s,v,R){var H=-1,G=s.length;v<0&&(v=-v>G?0:G+v),R=R>G?G:R,R<0&&(R+=G),G=v>R?0:R-v>>>0,v>>>=0;for(var te=xe(G);++H<G;)te[H]=s[H+v];return te}function O2(s,v){var R;return ds(s,function(H,G,te){return R=v(H,G,te),!R}),!!R}function Tu(s,v,R){var H=0,G=s==null?H:s.length;if(typeof v=="number"&&v===v&&G<=ne){for(;H<G;){var te=H+G>>>1,ue=s[te];ue!==null&&!wi(ue)&&(R?ue<=v:ue<v)?H=te+1:G=te}return G}return Wf(s,v,ai,R)}function Wf(s,v,R,H){var G=0,te=s==null?0:s.length;if(te===0)return 0;v=R(v);for(var ue=v!==v,de=v===null,ve=wi(v),Le=v===t;G<te;){var Oe=xu((G+te)/2),Fe=R(s[Oe]),Ve=Fe!==t,nt=Fe===null,ft=Fe===Fe,Rt=wi(Fe);if(ue)var pt=H||ft;else Le?pt=ft&&(H||Ve):de?pt=ft&&Ve&&(H||!nt):ve?pt=ft&&Ve&&!nt&&(H||!Rt):nt||Rt?pt=!1:pt=H?Fe<=v:Fe<v;pt?G=Oe+1:te=Oe}return Lr(te,ae)}function E0(s,v){for(var R=-1,H=s.length,G=0,te=[];++R<H;){var ue=s[R],de=v?v(ue):ue;if(!R||!ro(de,ve)){var ve=de;te[G++]=ue===0?0:ue}}return te}function T0(s){return typeof s=="number"?s:wi(s)?Z:+s}function bi(s){if(typeof s=="string")return s;if(xt(s))return y(s,bi)+"";if(wi(s))return a0?a0.call(s):"";var v=s+"";return v=="0"&&1/s==-j?"-0":v}function fs(s,v,R){var H=-1,G=vi,te=s.length,ue=!0,de=[],ve=de;if(R)ue=!1,G=yi;else if(te>=l){var Le=v?null:U2(s);if(Le)return Ue(Le);ue=!1,G=bt,ve=new ea}else ve=v?[]:de;e:for(;++H<te;){var Oe=s[H],Fe=v?v(Oe):Oe;if(Oe=R||Oe!==0?Oe:0,ue&&Fe===Fe){for(var Ve=ve.length;Ve--;)if(ve[Ve]===Fe)continue e;v&&ve.push(Fe),de.push(Oe)}else G(ve,Fe,R)||(ve!==de&&ve.push(Fe),de.push(Oe))}return de}function zf(s,v){return v=ps(v,s),s=rx(s,v),s==null||delete s[ko(Di(v))]}function R0(s,v,R,H){return Ul(s,v,R(na(s,v)),H)}function Ru(s,v,R,H){for(var G=s.length,te=H?G:-1;(H?te--:++te<G)&&v(s[te],te,s););return R?Ni(s,H?0:te,H?te+1:G):Ni(s,H?te+1:0,H?G:te)}function M0(s,v){var R=s;return R instanceof Bt&&(R=R.value()),C(v,function(H,G){return G.func.apply(G.thisArg,E([H],G.args))},R)}function Hf(s,v,R){var H=s.length;if(H<2)return H?fs(s[0]):[];for(var G=-1,te=xe(H);++G<H;)for(var ue=s[G],de=-1;++de<H;)de!=G&&(te[G]=Wl(te[G]||ue,s[de],v,R));return fs(wr(te,1),v,R)}function L0(s,v,R){for(var H=-1,G=s.length,te=v.length,ue={};++H<G;){var de=H<te?v[H]:t;R(ue,s[H],de)}return ue}function Uf(s){return Un(s)?s:[]}function qf(s){return typeof s=="function"?s:ai}function ps(s,v){return xt(s)?s:ep(s,v)?[s]:ax(Jt(s))}var I2=Lt;function gs(s,v,R){var H=s.length;return R=R===t?H:R,!v&&R>=H?s:Ni(s,v,R)}var O0=xI||function(s){return on.clearTimeout(s)};function I0(s,v){if(v)return s.slice();var R=s.length,H=t0?t0(R):new s.constructor(R);return s.copy(H),H}function Vf(s){var v=new s.constructor(s.byteLength);return new mu(v).set(new mu(s)),v}function N2(s,v){var R=v?Vf(s.buffer):s.buffer;return new s.constructor(R,s.byteOffset,s.byteLength)}function D2(s){var v=new s.constructor(s.source,fi.exec(s));return v.lastIndex=s.lastIndex,v}function F2(s){return Bl?Tt(Bl.call(s)):{}}function N0(s,v){var R=v?Vf(s.buffer):s.buffer;return new s.constructor(R,s.byteOffset,s.length)}function D0(s,v){if(s!==v){var R=s!==t,H=s===null,G=s===s,te=wi(s),ue=v!==t,de=v===null,ve=v===v,Le=wi(v);if(!de&&!Le&&!te&&s>v||te&&ue&&ve&&!de&&!Le||H&&ue&&ve||!R&&ve||!G)return 1;if(!H&&!te&&!Le&&s<v||Le&&R&&G&&!H&&!te||de&&R&&G||!ue&&G||!ve)return-1}return 0}function P2(s,v,R){for(var H=-1,G=s.criteria,te=v.criteria,ue=G.length,de=R.length;++H<ue;){var ve=D0(G[H],te[H]);if(ve){if(H>=de)return ve;var Le=R[H];return ve*(Le=="desc"?-1:1)}}return s.index-v.index}function F0(s,v,R,H){for(var G=-1,te=s.length,ue=R.length,de=-1,ve=v.length,Le=lr(te-ue,0),Oe=xe(ve+Le),Fe=!H;++de<ve;)Oe[de]=v[de];for(;++G<ue;)(Fe||G<te)&&(Oe[R[G]]=s[G]);for(;Le--;)Oe[de++]=s[G++];return Oe}function P0(s,v,R,H){for(var G=-1,te=s.length,ue=-1,de=R.length,ve=-1,Le=v.length,Oe=lr(te-de,0),Fe=xe(Oe+Le),Ve=!H;++G<Oe;)Fe[G]=s[G];for(var nt=G;++ve<Le;)Fe[nt+ve]=v[ve];for(;++ue<de;)(Ve||G<te)&&(Fe[nt+R[ue]]=s[G++]);return Fe}function ii(s,v){var R=-1,H=s.length;for(v||(v=xe(H));++R<H;)v[R]=s[R];return v}function xo(s,v,R,H){var G=!R;R||(R={});for(var te=-1,ue=v.length;++te<ue;){var de=v[te],ve=H?H(R[de],s[de],de,R,s):t;ve===t&&(ve=s[de]),G?jo(R,de,ve):jl(R,de,ve)}return R}function B2(s,v){return xo(s,Jf(s),v)}function j2(s,v){return xo(s,Q0(s),v)}function Mu(s,v){return function(R,H){var G=xt(R)?fr:l2,te=v?v():{};return G(R,s,ht(H,2),te)}}function Ua(s){return Lt(function(v,R){var H=-1,G=R.length,te=G>1?R[G-1]:t,ue=G>2?R[2]:t;for(te=s.length>3&&typeof te=="function"?(G--,te):t,ue&&Ur(R[0],R[1],ue)&&(te=G<3?t:te,G=1),v=Tt(v);++H<G;){var de=R[H];de&&s(v,de,H,te)}return v})}function B0(s,v){return function(R,H){if(R==null)return R;if(!oi(R))return s(R,H);for(var G=R.length,te=v?G:-1,ue=Tt(R);(v?te--:++te<G)&&H(ue[te],te,ue)!==!1;);return R}}function j0(s){return function(v,R,H){for(var G=-1,te=Tt(v),ue=H(v),de=ue.length;de--;){var ve=ue[s?de:++G];if(R(te[ve],ve,te)===!1)break}return v}}function W2(s,v,R){var H=v&m,G=ql(s);function te(){var ue=this&&this!==on&&this instanceof te?G:s;return ue.apply(H?R:this,arguments)}return te}function W0(s){return function(v){v=Jt(v);var R=oe(v)?wt(v):t,H=R?R[0]:v.charAt(0),G=R?gs(R,1).join(""):v.slice(1);return H[s]()+G}}function qa(s){return function(v){return C(Bx(Px(v).replace(Cn,"")),s,"")}}function ql(s){return function(){var v=arguments;switch(v.length){case 0:return new s;case 1:return new s(v[0]);case 2:return new s(v[0],v[1]);case 3:return new s(v[0],v[1],v[2]);case 4:return new s(v[0],v[1],v[2],v[3]);case 5:return new s(v[0],v[1],v[2],v[3],v[4]);case 6:return new s(v[0],v[1],v[2],v[3],v[4],v[5]);case 7:return new s(v[0],v[1],v[2],v[3],v[4],v[5],v[6])}var R=Ha(s.prototype),H=s.apply(R,v);return $n(H)?H:R}}function z2(s,v,R){var H=ql(s);function G(){for(var te=arguments.length,ue=xe(te),de=te,ve=Va(G);de--;)ue[de]=arguments[de];var Le=te<3&&ue[0]!==ve&&ue[te-1]!==ve?[]:je(ue,ve);if(te-=Le.length,te<R)return V0(s,v,Lu,G.placeholder,t,ue,Le,t,t,R-te);var Oe=this&&this!==on&&this instanceof G?H:s;return dr(Oe,this,ue)}return G}function z0(s){return function(v,R,H){var G=Tt(v);if(!oi(v)){var te=ht(R,3);v=mr(v),R=function(de){return te(G[de],de,G)}}var ue=s(v,R,H);return ue>-1?G[te?v[ue]:ue]:t}}function H0(s){return zo(function(v){var R=v.length,H=R,G=Oi.prototype.thru;for(s&&v.reverse();H--;){var te=v[H];if(typeof te!="function")throw new sn(h);if(G&&!ue&&Du(te)=="wrapper")var ue=new Oi([],!0)}for(H=ue?H:R;++H<R;){te=v[H];var de=Du(te),ve=de=="wrapper"?Qf(te):t;ve&&tp(ve[0])&&ve[1]==(T|M|S|D)&&!ve[4].length&&ve[9]==1?ue=ue[Du(ve[0])].apply(ue,ve[3]):ue=te.length==1&&tp(te)?ue[de]():ue.thru(te)}return function(){var Le=arguments,Oe=Le[0];if(ue&&Le.length==1&&xt(Oe))return ue.plant(Oe).value();for(var Fe=0,Ve=R?v[Fe].apply(this,Le):Oe;++Fe<R;)Ve=v[Fe].call(this,Ve);return Ve}})}function Lu(s,v,R,H,G,te,ue,de,ve,Le){var Oe=v&T,Fe=v&m,Ve=v&w,nt=v&(M|$),ft=v&L,Rt=Ve?t:ql(s);function pt(){for(var Nt=arguments.length,Wt=xe(Nt),xi=Nt;xi--;)Wt[xi]=arguments[xi];if(nt)var qr=Va(pt),ki=pr(Wt,qr);if(H&&(Wt=F0(Wt,H,G,nt)),te&&(Wt=P0(Wt,te,ue,nt)),Nt-=ki,nt&&Nt<Le){var qn=je(Wt,qr);return V0(s,v,Lu,pt.placeholder,R,Wt,qn,de,ve,Le-Nt)}var io=Fe?R:this,Vo=Ve?io[s]:s;return Nt=Wt.length,de?Wt=lN(Wt,de):ft&&Nt>1&&Wt.reverse(),Oe&&ve<Nt&&(Wt.length=ve),this&&this!==on&&this instanceof pt&&(Vo=Rt||ql(Vo)),Vo.apply(io,Wt)}return pt}function U0(s,v){return function(R,H){return m2(R,s,v(H),{})}}function Ou(s,v){return function(R,H){var G;if(R===t&&H===t)return v;if(R!==t&&(G=R),H!==t){if(G===t)return H;typeof R=="string"||typeof H=="string"?(R=bi(R),H=bi(H)):(R=T0(R),H=T0(H)),G=s(R,H)}return G}}function Kf(s){return zo(function(v){return v=y(v,lt(ht())),Lt(function(R){var H=this;return s(v,function(G){return dr(G,H,R)})})})}function Iu(s,v){v=v===t?" ":bi(v);var R=v.length;if(R<2)return R?jf(v,s):v;var H=jf(v,wu(s/It(v)));return oe(v)?gs(wt(H),0,s).join(""):H.slice(0,s)}function H2(s,v,R,H){var G=v&m,te=ql(s);function ue(){for(var de=-1,ve=arguments.length,Le=-1,Oe=H.length,Fe=xe(Oe+ve),Ve=this&&this!==on&&this instanceof ue?te:s;++Le<Oe;)Fe[Le]=H[Le];for(;ve--;)Fe[Le++]=arguments[++de];return dr(Ve,G?R:this,Fe)}return ue}function q0(s){return function(v,R,H){return H&&typeof H!="number"&&Ur(v,R,H)&&(R=H=t),v=qo(v),R===t?(R=v,v=0):R=qo(R),H=H===t?v<R?1:-1:qo(H),E2(v,R,H,s)}}function Nu(s){return function(v,R){return typeof v=="string"&&typeof R=="string"||(v=Fi(v),R=Fi(R)),s(v,R)}}function V0(s,v,R,H,G,te,ue,de,ve,Le){var Oe=v&M,Fe=Oe?ue:t,Ve=Oe?t:ue,nt=Oe?te:t,ft=Oe?t:te;v|=Oe?S:k,v&=~(Oe?k:S),v&x||(v&=-4);var Rt=[s,v,G,nt,Fe,ft,Ve,de,ve,Le],pt=R.apply(t,Rt);return tp(s)&&ix(pt,Rt),pt.placeholder=H,ox(pt,s,v)}function Gf(s){var v=Ht[s];return function(R,H){if(R=Fi(R),H=H==null?0:Lr(Et(H),292),H&&o0(R)){var G=(Jt(R)+"e").split("e"),te=v(G[0]+"e"+(+G[1]+H));return G=(Jt(te)+"e").split("e"),+(G[0]+"e"+(+G[1]-H))}return v(R)}}var U2=Wa&&1/Ue(new Wa([,-0]))[1]==j?function(s){return new Wa(s)}:mp;function K0(s){return function(v){var R=Or(v);return R==rt?Re(v):R==Xn?Ge(v):tt(v,s(v))}}function Wo(s,v,R,H,G,te,ue,de){var ve=v&w;if(!ve&&typeof s!="function")throw new sn(h);var Le=H?H.length:0;if(Le||(v&=-97,H=G=t),ue=ue===t?ue:lr(Et(ue),0),de=de===t?de:Et(de),Le-=G?G.length:0,v&k){var Oe=H,Fe=G;H=G=t}var Ve=ve?t:Qf(s),nt=[s,v,R,H,G,Oe,Fe,te,ue,de];if(Ve&&oN(nt,Ve),s=nt[0],v=nt[1],R=nt[2],H=nt[3],G=nt[4],de=nt[9]=nt[9]===t?ve?0:s.length:lr(nt[9]-Le,0),!de&&v&(M|$)&&(v&=-25),!v||v==m)var ft=W2(s,v,R);else v==M||v==$?ft=z2(s,v,de):(v==S||v==(m|S))&&!G.length?ft=H2(s,v,R,H):ft=Lu.apply(t,nt);var Rt=Ve?A0:ix;return ox(Rt(ft,nt),s,v)}function G0(s,v,R,H){return s===t||ro(s,On[R])&&!rn.call(H,R)?v:s}function Y0(s,v,R,H,G,te){return $n(s)&&$n(v)&&(te.set(v,s),Eu(s,v,t,Y0,te),te.delete(v)),s}function q2(s){return Gl(s)?t:s}function X0(s,v,R,H,G,te){var ue=R&i,de=s.length,ve=v.length;if(de!=ve&&!(ue&&ve>de))return!1;var Le=te.get(s),Oe=te.get(v);if(Le&&Oe)return Le==v&&Oe==s;var Fe=-1,Ve=!0,nt=R&a?new ea:t;for(te.set(s,v),te.set(v,s);++Fe<de;){var ft=s[Fe],Rt=v[Fe];if(H)var pt=ue?H(Rt,ft,Fe,v,s,te):H(ft,Rt,Fe,s,v,te);if(pt!==t){if(pt)continue;Ve=!1;break}if(nt){if(!B(v,function(Nt,Wt){if(!bt(nt,Wt)&&(ft===Nt||G(ft,Nt,R,H,te)))return nt.push(Wt)})){Ve=!1;break}}else if(!(ft===Rt||G(ft,Rt,R,H,te))){Ve=!1;break}}return te.delete(s),te.delete(v),Ve}function V2(s,v,R,H,G,te,ue){switch(R){case Qn:if(s.byteLength!=v.byteLength||s.byteOffset!=v.byteOffset)return!1;s=s.buffer,v=v.buffer;case gn:return!(s.byteLength!=v.byteLength||!te(new mu(s),new mu(v)));case Ee:case Te:case gt:return ro(+s,+v);case Xe:return s.name==v.name&&s.message==v.message;case kn:case ur:return s==v+"";case rt:var de=Re;case Xn:var ve=H&i;if(de||(de=Ue),s.size!=v.size&&!ve)return!1;var Le=ue.get(s);if(Le)return Le==v;H|=a,ue.set(s,v);var Oe=X0(de(s),de(v),H,G,te,ue);return ue.delete(s),Oe;case Pr:if(Bl)return Bl.call(s)==Bl.call(v)}return!1}function K2(s,v,R,H,G,te){var ue=R&i,de=Yf(s),ve=de.length,Le=Yf(v),Oe=Le.length;if(ve!=Oe&&!ue)return!1;for(var Fe=ve;Fe--;){var Ve=de[Fe];if(!(ue?Ve in v:rn.call(v,Ve)))return!1}var nt=te.get(s),ft=te.get(v);if(nt&&ft)return nt==v&&ft==s;var Rt=!0;te.set(s,v),te.set(v,s);for(var pt=ue;++Fe<ve;){Ve=de[Fe];var Nt=s[Ve],Wt=v[Ve];if(H)var xi=ue?H(Wt,Nt,Ve,v,s,te):H(Nt,Wt,Ve,s,v,te);if(!(xi===t?Nt===Wt||G(Nt,Wt,R,H,te):xi)){Rt=!1;break}pt||(pt=Ve=="constructor")}if(Rt&&!pt){var qr=s.constructor,ki=v.constructor;qr!=ki&&"constructor"in s&&"constructor"in v&&!(typeof qr=="function"&&qr instanceof qr&&typeof ki=="function"&&ki instanceof ki)&&(Rt=!1)}return te.delete(s),te.delete(v),Rt}function zo(s){return rp(nx(s,t,hx),s+"")}function Yf(s){return m0(s,mr,Jf)}function Xf(s){return m0(s,si,Q0)}var Qf=ku?function(s){return ku.get(s)}:mp;function Du(s){for(var v=s.name+"",R=za[v],H=rn.call(za,v)?R.length:0;H--;){var G=R[H],te=G.func;if(te==null||te==s)return G.name}return v}function Va(s){var v=rn.call(ee,"placeholder")?ee:s;return v.placeholder}function ht(){var s=ee.iteratee||pp;return s=s===pp?b0:s,arguments.length?s(arguments[0],arguments[1]):s}function Fu(s,v){var R=s.__data__;return tN(v)?R[typeof v=="string"?"string":"hash"]:R.map}function Zf(s){for(var v=mr(s),R=v.length;R--;){var H=v[R],G=s[H];v[R]=[H,G,ex(G)]}return v}function ra(s,v){var R=ie(s,v);return y0(R)?R:t}function G2(s){var v=rn.call(s,Zs),R=s[Zs];try{s[Zs]=t;var H=!0}catch{}var G=pu.call(s);return H&&(v?s[Zs]=R:delete s[Zs]),G}var Jf=$f?function(s){return s==null?[]:(s=Tt(s),Mr($f(s),function(v){return r0.call(s,v)}))}:vp,Q0=$f?function(s){for(var v=[];s;)E(v,Jf(s)),s=vu(s);return v}:vp,Or=Hr;(Af&&Or(new Af(new ArrayBuffer(1)))!=Qn||Dl&&Or(new Dl)!=rt||Ef&&Or(Ef.resolve())!=Zt||Wa&&Or(new Wa)!=Xn||Fl&&Or(new Fl)!=qe)&&(Or=function(s){var v=Hr(s),R=v==jn?s.constructor:t,H=R?ia(R):"";if(H)switch(H){case RI:return Qn;case MI:return rt;case LI:return Zt;case OI:return Xn;case II:return qe}return v});function Y2(s,v,R){for(var H=-1,G=R.length;++H<G;){var te=R[H],ue=te.size;switch(te.type){case"drop":s+=ue;break;case"dropRight":v-=ue;break;case"take":v=Lr(v,s+ue);break;case"takeRight":s=lr(s,v-ue);break}}return{start:s,end:v}}function X2(s){var v=s.match(Zi);return v?v[1].split(Hs):[]}function Z0(s,v,R){v=ps(v,s);for(var H=-1,G=v.length,te=!1;++H<G;){var ue=ko(v[H]);if(!(te=s!=null&&R(s,ue)))break;s=s[ue]}return te||++H!=G?te:(G=s==null?0:s.length,!!G&&Uu(G)&&Ho(ue,G)&&(xt(s)||oa(s)))}function Q2(s){var v=s.length,R=new s.constructor(v);return v&&typeof s[0]=="string"&&rn.call(s,"index")&&(R.index=s.index,R.input=s.input),R}function J0(s){return typeof s.constructor=="function"&&!Vl(s)?Ha(vu(s)):{}}function Z2(s,v,R){var H=s.constructor;switch(v){case gn:return Vf(s);case Ee:case Te:return new H(+s);case Qn:return N2(s,R);case Br:case $r:case Sn:case ir:case hr:case nn:case or:case $o:case Ki:return N0(s,R);case rt:return new H;case gt:case ur:return new H(s);case kn:return D2(s);case Xn:return new H;case Pr:return F2(s)}}function J2(s,v){var R=v.length;if(!R)return s;var H=R-1;return v[H]=(R>1?"& ":"")+v[H],v=v.join(R>2?", ":" "),s.replace(po,`{
|
|
1476
|
+
/* [wrapped with `+v+`] */
|
|
1477
|
+
`)}function eN(s){return xt(s)||oa(s)||!!(i0&&s&&s[i0])}function Ho(s,v){var R=typeof s;return v=v??U,!!v&&(R=="number"||R!="symbol"&&hn.test(s))&&s>-1&&s%1==0&&s<v}function Ur(s,v,R){if(!$n(R))return!1;var H=typeof v;return(H=="number"?oi(R)&&Ho(v,R.length):H=="string"&&v in R)?ro(R[v],s):!1}function ep(s,v){if(xt(s))return!1;var R=typeof s;return R=="number"||R=="symbol"||R=="boolean"||s==null||wi(s)?!0:Xi.test(s)||!Oa.test(s)||v!=null&&s in Tt(v)}function tN(s){var v=typeof s;return v=="string"||v=="number"||v=="symbol"||v=="boolean"?s!=="__proto__":s===null}function tp(s){var v=Du(s),R=ee[v];if(typeof R!="function"||!(v in Bt.prototype))return!1;if(s===R)return!0;var H=Qf(R);return!!H&&s===H[0]}function nN(s){return!!e0&&e0 in s}var rN=Qs?Uo:yp;function Vl(s){var v=s&&s.constructor,R=typeof v=="function"&&v.prototype||On;return s===R}function ex(s){return s===s&&!$n(s)}function tx(s,v){return function(R){return R==null?!1:R[s]===v&&(v!==t||s in Tt(R))}}function iN(s){var v=zu(s,function(H){return R.size===g&&R.clear(),H}),R=v.cache;return v}function oN(s,v){var R=s[1],H=v[1],G=R|H,te=G<(m|w|T),ue=H==T&&R==M||H==T&&R==D&&s[7].length<=v[8]||H==(T|D)&&v[7].length<=v[8]&&R==M;if(!(te||ue))return s;H&m&&(s[2]=v[2],G|=R&m?0:x);var de=v[3];if(de){var ve=s[3];s[3]=ve?F0(ve,de,v[4]):de,s[4]=ve?je(s[3],o):v[4]}return de=v[5],de&&(ve=s[5],s[5]=ve?P0(ve,de,v[6]):de,s[6]=ve?je(s[5],o):v[6]),de=v[7],de&&(s[7]=de),H&T&&(s[8]=s[8]==null?v[8]:Lr(s[8],v[8])),s[9]==null&&(s[9]=v[9]),s[0]=v[0],s[1]=G,s}function sN(s){var v=[];if(s!=null)for(var R in Tt(s))v.push(R);return v}function aN(s){return pu.call(s)}function nx(s,v,R){return v=lr(v===t?s.length-1:v,0),function(){for(var H=arguments,G=-1,te=lr(H.length-v,0),ue=xe(te);++G<te;)ue[G]=H[v+G];G=-1;for(var de=xe(v+1);++G<v;)de[G]=H[G];return de[v]=R(ue),dr(s,this,de)}}function rx(s,v){return v.length<2?s:na(s,Ni(v,0,-1))}function lN(s,v){for(var R=s.length,H=Lr(v.length,R),G=ii(s);H--;){var te=v[H];s[H]=Ho(te,R)?G[te]:t}return s}function np(s,v){if(!(v==="constructor"&&typeof s[v]=="function")&&v!="__proto__")return s[v]}var ix=sx(A0),Kl=SI||function(s,v){return on.setTimeout(s,v)},rp=sx(M2);function ox(s,v,R){var H=v+"";return rp(s,J2(H,cN(X2(H),R)))}function sx(s){var v=0,R=0;return function(){var H=AI(),G=N-(H-R);if(R=H,G>0){if(++v>=P)return arguments[0]}else v=0;return s.apply(t,arguments)}}function Pu(s,v){var R=-1,H=s.length,G=H-1;for(v=v===t?H:v;++R<v;){var te=Bf(R,G),ue=s[te];s[te]=s[R],s[R]=ue}return s.length=v,s}var ax=iN(function(s){var v=[];return s.charCodeAt(0)===46&&v.push(""),s.replace(Wn,function(R,H,G,te){v.push(G?te.replace(Ol,"$1"):H||R)}),v});function ko(s){if(typeof s=="string"||wi(s))return s;var v=s+"";return v=="0"&&1/s==-j?"-0":v}function ia(s){if(s!=null){try{return fu.call(s)}catch{}try{return s+""}catch{}}return""}function cN(s,v){return yr(se,function(R){var H="_."+R[0];v&R[1]&&!vi(s,H)&&s.push(H)}),s.sort()}function lx(s){if(s instanceof Bt)return s.clone();var v=new Oi(s.__wrapped__,s.__chain__);return v.__actions__=ii(s.__actions__),v.__index__=s.__index__,v.__values__=s.__values__,v}function uN(s,v,R){(R?Ur(s,v,R):v===t)?v=1:v=lr(Et(v),0);var H=s==null?0:s.length;if(!H||v<1)return[];for(var G=0,te=0,ue=xe(wu(H/v));G<H;)ue[te++]=Ni(s,G,G+=v);return ue}function hN(s){for(var v=-1,R=s==null?0:s.length,H=0,G=[];++v<R;){var te=s[v];te&&(G[H++]=te)}return G}function dN(){var s=arguments.length;if(!s)return[];for(var v=xe(s-1),R=arguments[0],H=s;H--;)v[H-1]=arguments[H];return E(xt(R)?ii(R):[R],wr(v,1))}var fN=Lt(function(s,v){return Un(s)?Wl(s,wr(v,1,Un,!0)):[]}),pN=Lt(function(s,v){var R=Di(v);return Un(R)&&(R=t),Un(s)?Wl(s,wr(v,1,Un,!0),ht(R,2)):[]}),gN=Lt(function(s,v){var R=Di(v);return Un(R)&&(R=t),Un(s)?Wl(s,wr(v,1,Un,!0),t,R):[]});function mN(s,v,R){var H=s==null?0:s.length;return H?(v=R||v===t?1:Et(v),Ni(s,v<0?0:v,H)):[]}function vN(s,v,R){var H=s==null?0:s.length;return H?(v=R||v===t?1:Et(v),v=H-v,Ni(s,0,v<0?0:v)):[]}function yN(s,v){return s&&s.length?Ru(s,ht(v,3),!0,!0):[]}function bN(s,v){return s&&s.length?Ru(s,ht(v,3),!0):[]}function wN(s,v,R,H){var G=s==null?0:s.length;return G?(R&&typeof R!="number"&&Ur(s,v,R)&&(R=0,H=G),d2(s,v,R,H)):[]}function cx(s,v,R){var H=s==null?0:s.length;if(!H)return-1;var G=R==null?0:Et(R);return G<0&&(G=lr(H+G,0)),re(s,ht(v,3),G)}function ux(s,v,R){var H=s==null?0:s.length;if(!H)return-1;var G=H-1;return R!==t&&(G=Et(R),G=R<0?lr(H+G,0):Lr(G,H-1)),re(s,ht(v,3),G,!0)}function hx(s){var v=s==null?0:s.length;return v?wr(s,1):[]}function xN(s){var v=s==null?0:s.length;return v?wr(s,j):[]}function kN(s,v){var R=s==null?0:s.length;return R?(v=v===t?1:Et(v),wr(s,v)):[]}function SN(s){for(var v=-1,R=s==null?0:s.length,H={};++v<R;){var G=s[v];H[G[0]]=G[1]}return H}function dx(s){return s&&s.length?s[0]:t}function _N(s,v,R){var H=s==null?0:s.length;if(!H)return-1;var G=R==null?0:Et(R);return G<0&&(G=lr(H+G,0)),le(s,v,G)}function CN(s){var v=s==null?0:s.length;return v?Ni(s,0,-1):[]}var $N=Lt(function(s){var v=y(s,Uf);return v.length&&v[0]===s[0]?If(v):[]}),AN=Lt(function(s){var v=Di(s),R=y(s,Uf);return v===Di(R)?v=t:R.pop(),R.length&&R[0]===s[0]?If(R,ht(v,2)):[]}),EN=Lt(function(s){var v=Di(s),R=y(s,Uf);return v=typeof v=="function"?v:t,v&&R.pop(),R.length&&R[0]===s[0]?If(R,t,v):[]});function TN(s,v){return s==null?"":CI.call(s,v)}function Di(s){var v=s==null?0:s.length;return v?s[v-1]:t}function RN(s,v,R){var H=s==null?0:s.length;if(!H)return-1;var G=H;return R!==t&&(G=Et(R),G=G<0?lr(H+G,0):Lr(G,H-1)),v===v?vt(s,v,G):re(s,ke,G,!0)}function MN(s,v){return s&&s.length?S0(s,Et(v)):t}var LN=Lt(fx);function fx(s,v){return s&&s.length&&v&&v.length?Pf(s,v):s}function ON(s,v,R){return s&&s.length&&v&&v.length?Pf(s,v,ht(R,2)):s}function IN(s,v,R){return s&&s.length&&v&&v.length?Pf(s,v,t,R):s}var NN=zo(function(s,v){var R=s==null?0:s.length,H=Rf(s,v);return $0(s,y(v,function(G){return Ho(G,R)?+G:G}).sort(D0)),H});function DN(s,v){var R=[];if(!(s&&s.length))return R;var H=-1,G=[],te=s.length;for(v=ht(v,3);++H<te;){var ue=s[H];v(ue,H,s)&&(R.push(ue),G.push(H))}return $0(s,G),R}function ip(s){return s==null?s:TI.call(s)}function FN(s,v,R){var H=s==null?0:s.length;return H?(R&&typeof R!="number"&&Ur(s,v,R)?(v=0,R=H):(v=v==null?0:Et(v),R=R===t?H:Et(R)),Ni(s,v,R)):[]}function PN(s,v){return Tu(s,v)}function BN(s,v,R){return Wf(s,v,ht(R,2))}function jN(s,v){var R=s==null?0:s.length;if(R){var H=Tu(s,v);if(H<R&&ro(s[H],v))return H}return-1}function WN(s,v){return Tu(s,v,!0)}function zN(s,v,R){return Wf(s,v,ht(R,2),!0)}function HN(s,v){var R=s==null?0:s.length;if(R){var H=Tu(s,v,!0)-1;if(ro(s[H],v))return H}return-1}function UN(s){return s&&s.length?E0(s):[]}function qN(s,v){return s&&s.length?E0(s,ht(v,2)):[]}function VN(s){var v=s==null?0:s.length;return v?Ni(s,1,v):[]}function KN(s,v,R){return s&&s.length?(v=R||v===t?1:Et(v),Ni(s,0,v<0?0:v)):[]}function GN(s,v,R){var H=s==null?0:s.length;return H?(v=R||v===t?1:Et(v),v=H-v,Ni(s,v<0?0:v,H)):[]}function YN(s,v){return s&&s.length?Ru(s,ht(v,3),!1,!0):[]}function XN(s,v){return s&&s.length?Ru(s,ht(v,3)):[]}var QN=Lt(function(s){return fs(wr(s,1,Un,!0))}),ZN=Lt(function(s){var v=Di(s);return Un(v)&&(v=t),fs(wr(s,1,Un,!0),ht(v,2))}),JN=Lt(function(s){var v=Di(s);return v=typeof v=="function"?v:t,fs(wr(s,1,Un,!0),t,v)});function eD(s){return s&&s.length?fs(s):[]}function tD(s,v){return s&&s.length?fs(s,ht(v,2)):[]}function nD(s,v){return v=typeof v=="function"?v:t,s&&s.length?fs(s,t,v):[]}function op(s){if(!(s&&s.length))return[];var v=0;return s=Mr(s,function(R){if(Un(R))return v=lr(R.length,v),!0}),Ye(v,function(R){return y(s,be(R))})}function px(s,v){if(!(s&&s.length))return[];var R=op(s);return v==null?R:y(R,function(H){return dr(v,t,H)})}var rD=Lt(function(s,v){return Un(s)?Wl(s,v):[]}),iD=Lt(function(s){return Hf(Mr(s,Un))}),oD=Lt(function(s){var v=Di(s);return Un(v)&&(v=t),Hf(Mr(s,Un),ht(v,2))}),sD=Lt(function(s){var v=Di(s);return v=typeof v=="function"?v:t,Hf(Mr(s,Un),t,v)}),aD=Lt(op);function lD(s,v){return L0(s||[],v||[],jl)}function cD(s,v){return L0(s||[],v||[],Ul)}var uD=Lt(function(s){var v=s.length,R=v>1?s[v-1]:t;return R=typeof R=="function"?(s.pop(),R):t,px(s,R)});function gx(s){var v=ee(s);return v.__chain__=!0,v}function hD(s,v){return v(s),s}function Bu(s,v){return v(s)}var dD=zo(function(s){var v=s.length,R=v?s[0]:0,H=this.__wrapped__,G=function(te){return Rf(te,s)};return v>1||this.__actions__.length||!(H instanceof Bt)||!Ho(R)?this.thru(G):(H=H.slice(R,+R+(v?1:0)),H.__actions__.push({func:Bu,args:[G],thisArg:t}),new Oi(H,this.__chain__).thru(function(te){return v&&!te.length&&te.push(t),te}))});function fD(){return gx(this)}function pD(){return new Oi(this.value(),this.__chain__)}function gD(){this.__values__===t&&(this.__values__=Tx(this.value()));var s=this.__index__>=this.__values__.length,v=s?t:this.__values__[this.__index__++];return{done:s,value:v}}function mD(){return this}function vD(s){for(var v,R=this;R instanceof _u;){var H=lx(R);H.__index__=0,H.__values__=t,v?G.__wrapped__=H:v=H;var G=H;R=R.__wrapped__}return G.__wrapped__=s,v}function yD(){var s=this.__wrapped__;if(s instanceof Bt){var v=s;return this.__actions__.length&&(v=new Bt(this)),v=v.reverse(),v.__actions__.push({func:Bu,args:[ip],thisArg:t}),new Oi(v,this.__chain__)}return this.thru(ip)}function bD(){return M0(this.__wrapped__,this.__actions__)}var wD=Mu(function(s,v,R){rn.call(s,R)?++s[R]:jo(s,R,1)});function xD(s,v,R){var H=xt(s)?br:h2;return R&&Ur(s,v,R)&&(v=t),H(s,ht(v,3))}function kD(s,v){var R=xt(s)?Mr:p0;return R(s,ht(v,3))}var SD=z0(cx),_D=z0(ux);function CD(s,v){return wr(ju(s,v),1)}function $D(s,v){return wr(ju(s,v),j)}function AD(s,v,R){return R=R===t?1:Et(R),wr(ju(s,v),R)}function mx(s,v){var R=xt(s)?yr:ds;return R(s,ht(v,3))}function vx(s,v){var R=xt(s)?Xs:f0;return R(s,ht(v,3))}var ED=Mu(function(s,v,R){rn.call(s,R)?s[R].push(v):jo(s,R,[v])});function TD(s,v,R,H){s=oi(s)?s:Ga(s),R=R&&!H?Et(R):0;var G=s.length;return R<0&&(R=lr(G+R,0)),qu(s)?R<=G&&s.indexOf(v,R)>-1:!!G&&le(s,v,R)>-1}var RD=Lt(function(s,v,R){var H=-1,G=typeof v=="function",te=oi(s)?xe(s.length):[];return ds(s,function(ue){te[++H]=G?dr(v,ue,R):zl(ue,v,R)}),te}),MD=Mu(function(s,v,R){jo(s,R,v)});function ju(s,v){var R=xt(s)?y:w0;return R(s,ht(v,3))}function LD(s,v,R,H){return s==null?[]:(xt(v)||(v=v==null?[]:[v]),R=H?t:R,xt(R)||(R=R==null?[]:[R]),_0(s,v,R))}var OD=Mu(function(s,v,R){s[R?0:1].push(v)},function(){return[[],[]]});function ID(s,v,R){var H=xt(s)?C:Ie,G=arguments.length<3;return H(s,ht(v,4),R,G,ds)}function ND(s,v,R){var H=xt(s)?F:Ie,G=arguments.length<3;return H(s,ht(v,4),R,G,f0)}function DD(s,v){var R=xt(s)?Mr:p0;return R(s,Hu(ht(v,3)))}function FD(s){var v=xt(s)?c0:T2;return v(s)}function PD(s,v,R){(R?Ur(s,v,R):v===t)?v=1:v=Et(v);var H=xt(s)?s2:R2;return H(s,v)}function BD(s){var v=xt(s)?a2:L2;return v(s)}function jD(s){if(s==null)return 0;if(oi(s))return qu(s)?It(s):s.length;var v=Or(s);return v==rt||v==Xn?s.size:Df(s).length}function WD(s,v,R){var H=xt(s)?B:O2;return R&&Ur(s,v,R)&&(v=t),H(s,ht(v,3))}var zD=Lt(function(s,v){if(s==null)return[];var R=v.length;return R>1&&Ur(s,v[0],v[1])?v=[]:R>2&&Ur(v[0],v[1],v[2])&&(v=[v[0]]),_0(s,wr(v,1),[])}),Wu=kI||function(){return on.Date.now()};function HD(s,v){if(typeof v!="function")throw new sn(h);return s=Et(s),function(){if(--s<1)return v.apply(this,arguments)}}function yx(s,v,R){return v=R?t:v,v=s&&v==null?s.length:v,Wo(s,T,t,t,t,t,v)}function bx(s,v){var R;if(typeof v!="function")throw new sn(h);return s=Et(s),function(){return--s>0&&(R=v.apply(this,arguments)),s<=1&&(v=t),R}}var sp=Lt(function(s,v,R){var H=m;if(R.length){var G=je(R,Va(sp));H|=S}return Wo(s,H,v,R,G)}),wx=Lt(function(s,v,R){var H=m|w;if(R.length){var G=je(R,Va(wx));H|=S}return Wo(v,H,s,R,G)});function xx(s,v,R){v=R?t:v;var H=Wo(s,M,t,t,t,t,t,v);return H.placeholder=xx.placeholder,H}function kx(s,v,R){v=R?t:v;var H=Wo(s,$,t,t,t,t,t,v);return H.placeholder=kx.placeholder,H}function Sx(s,v,R){var H,G,te,ue,de,ve,Le=0,Oe=!1,Fe=!1,Ve=!0;if(typeof s!="function")throw new sn(h);v=Fi(v)||0,$n(R)&&(Oe=!!R.leading,Fe="maxWait"in R,te=Fe?lr(Fi(R.maxWait)||0,v):te,Ve="trailing"in R?!!R.trailing:Ve);function nt(qn){var io=H,Vo=G;return H=G=t,Le=qn,ue=s.apply(Vo,io),ue}function ft(qn){return Le=qn,de=Kl(Nt,v),Oe?nt(qn):ue}function Rt(qn){var io=qn-ve,Vo=qn-Le,zx=v-io;return Fe?Lr(zx,te-Vo):zx}function pt(qn){var io=qn-ve,Vo=qn-Le;return ve===t||io>=v||io<0||Fe&&Vo>=te}function Nt(){var qn=Wu();if(pt(qn))return Wt(qn);de=Kl(Nt,Rt(qn))}function Wt(qn){return de=t,Ve&&H?nt(qn):(H=G=t,ue)}function xi(){de!==t&&O0(de),Le=0,H=ve=G=de=t}function qr(){return de===t?ue:Wt(Wu())}function ki(){var qn=Wu(),io=pt(qn);if(H=arguments,G=this,ve=qn,io){if(de===t)return ft(ve);if(Fe)return O0(de),de=Kl(Nt,v),nt(ve)}return de===t&&(de=Kl(Nt,v)),ue}return ki.cancel=xi,ki.flush=qr,ki}var UD=Lt(function(s,v){return d0(s,1,v)}),qD=Lt(function(s,v,R){return d0(s,Fi(v)||0,R)});function VD(s){return Wo(s,L)}function zu(s,v){if(typeof s!="function"||v!=null&&typeof v!="function")throw new sn(h);var R=function(){var H=arguments,G=v?v.apply(this,H):H[0],te=R.cache;if(te.has(G))return te.get(G);var ue=s.apply(this,H);return R.cache=te.set(G,ue)||te,ue};return R.cache=new(zu.Cache||Bo),R}zu.Cache=Bo;function Hu(s){if(typeof s!="function")throw new sn(h);return function(){var v=arguments;switch(v.length){case 0:return!s.call(this);case 1:return!s.call(this,v[0]);case 2:return!s.call(this,v[0],v[1]);case 3:return!s.call(this,v[0],v[1],v[2])}return!s.apply(this,v)}}function KD(s){return bx(2,s)}var GD=I2(function(s,v){v=v.length==1&&xt(v[0])?y(v[0],lt(ht())):y(wr(v,1),lt(ht()));var R=v.length;return Lt(function(H){for(var G=-1,te=Lr(H.length,R);++G<te;)H[G]=v[G].call(this,H[G]);return dr(s,this,H)})}),ap=Lt(function(s,v){var R=je(v,Va(ap));return Wo(s,S,t,v,R)}),_x=Lt(function(s,v){var R=je(v,Va(_x));return Wo(s,k,t,v,R)}),YD=zo(function(s,v){return Wo(s,D,t,t,t,v)});function XD(s,v){if(typeof s!="function")throw new sn(h);return v=v===t?v:Et(v),Lt(s,v)}function QD(s,v){if(typeof s!="function")throw new sn(h);return v=v==null?0:lr(Et(v),0),Lt(function(R){var H=R[v],G=gs(R,0,v);return H&&E(G,H),dr(s,this,G)})}function ZD(s,v,R){var H=!0,G=!0;if(typeof s!="function")throw new sn(h);return $n(R)&&(H="leading"in R?!!R.leading:H,G="trailing"in R?!!R.trailing:G),Sx(s,v,{leading:H,maxWait:v,trailing:G})}function JD(s){return yx(s,1)}function eF(s,v){return ap(qf(v),s)}function tF(){if(!arguments.length)return[];var s=arguments[0];return xt(s)?s:[s]}function nF(s){return Ii(s,u)}function rF(s,v){return v=typeof v=="function"?v:t,Ii(s,u,v)}function iF(s){return Ii(s,c|u)}function oF(s,v){return v=typeof v=="function"?v:t,Ii(s,c|u,v)}function sF(s,v){return v==null||h0(s,v,mr(v))}function ro(s,v){return s===v||s!==s&&v!==v}var aF=Nu(Of),lF=Nu(function(s,v){return s>=v}),oa=v0(function(){return arguments}())?v0:function(s){return In(s)&&rn.call(s,"callee")&&!r0.call(s,"callee")},xt=xe.isArray,cF=ri?lt(ri):v2;function oi(s){return s!=null&&Uu(s.length)&&!Uo(s)}function Un(s){return In(s)&&oi(s)}function uF(s){return s===!0||s===!1||In(s)&&Hr(s)==Ee}var ms=_I||yp,hF=us?lt(us):y2;function dF(s){return In(s)&&s.nodeType===1&&!Gl(s)}function fF(s){if(s==null)return!0;if(oi(s)&&(xt(s)||typeof s=="string"||typeof s.splice=="function"||ms(s)||Ka(s)||oa(s)))return!s.length;var v=Or(s);if(v==rt||v==Xn)return!s.size;if(Vl(s))return!Df(s).length;for(var R in s)if(rn.call(s,R))return!1;return!0}function pF(s,v){return Hl(s,v)}function gF(s,v,R){R=typeof R=="function"?R:t;var H=R?R(s,v):t;return H===t?Hl(s,v,t,R):!!H}function lp(s){if(!In(s))return!1;var v=Hr(s);return v==Xe||v==Me||typeof s.message=="string"&&typeof s.name=="string"&&!Gl(s)}function mF(s){return typeof s=="number"&&o0(s)}function Uo(s){if(!$n(s))return!1;var v=Hr(s);return v==Ke||v==dt||v==ge||v==hi}function Cx(s){return typeof s=="number"&&s==Et(s)}function Uu(s){return typeof s=="number"&&s>-1&&s%1==0&&s<=U}function $n(s){var v=typeof s;return s!=null&&(v=="object"||v=="function")}function In(s){return s!=null&&typeof s=="object"}var $x=Ln?lt(Ln):w2;function vF(s,v){return s===v||Nf(s,v,Zf(v))}function yF(s,v,R){return R=typeof R=="function"?R:t,Nf(s,v,Zf(v),R)}function bF(s){return Ax(s)&&s!=+s}function wF(s){if(rN(s))throw new ct(d);return y0(s)}function xF(s){return s===null}function kF(s){return s==null}function Ax(s){return typeof s=="number"||In(s)&&Hr(s)==gt}function Gl(s){if(!In(s)||Hr(s)!=jn)return!1;var v=vu(s);if(v===null)return!0;var R=rn.call(v,"constructor")&&v.constructor;return typeof R=="function"&&R instanceof R&&fu.call(R)==yI}var cp=gi?lt(gi):x2;function SF(s){return Cx(s)&&s>=-U&&s<=U}var Ex=mi?lt(mi):k2;function qu(s){return typeof s=="string"||!xt(s)&&In(s)&&Hr(s)==ur}function wi(s){return typeof s=="symbol"||In(s)&&Hr(s)==Pr}var Ka=Mi?lt(Mi):S2;function _F(s){return s===t}function CF(s){return In(s)&&Or(s)==qe}function $F(s){return In(s)&&Hr(s)==qt}var AF=Nu(Ff),EF=Nu(function(s,v){return s<=v});function Tx(s){if(!s)return[];if(oi(s))return qu(s)?wt(s):ii(s);if(Nl&&s[Nl])return we(s[Nl]());var v=Or(s),R=v==rt?Re:v==Xn?Ue:Ga;return R(s)}function qo(s){if(!s)return s===0?s:0;if(s=Fi(s),s===j||s===-j){var v=s<0?-1:1;return v*K}return s===s?s:0}function Et(s){var v=qo(s),R=v%1;return v===v?R?v-R:v:0}function Rx(s){return s?ta(Et(s),0,J):0}function Fi(s){if(typeof s=="number")return s;if(wi(s))return Z;if($n(s)){var v=typeof s.valueOf=="function"?s.valueOf():s;s=$n(v)?v+"":v}if(typeof s!="string")return s===0?s:+s;s=fn(s);var R=Na.test(s);return R||zn.test(s)?dn(s.slice(2),R?2:8):Ft.test(s)?Z:+s}function Mx(s){return xo(s,si(s))}function TF(s){return s?ta(Et(s),-U,U):s===0?s:0}function Jt(s){return s==null?"":bi(s)}var RF=Ua(function(s,v){if(Vl(v)||oi(v)){xo(v,mr(v),s);return}for(var R in v)rn.call(v,R)&&jl(s,R,v[R])}),Lx=Ua(function(s,v){xo(v,si(v),s)}),Vu=Ua(function(s,v,R,H){xo(v,si(v),s,H)}),MF=Ua(function(s,v,R,H){xo(v,mr(v),s,H)}),LF=zo(Rf);function OF(s,v){var R=Ha(s);return v==null?R:u0(R,v)}var IF=Lt(function(s,v){s=Tt(s);var R=-1,H=v.length,G=H>2?v[2]:t;for(G&&Ur(v[0],v[1],G)&&(H=1);++R<H;)for(var te=v[R],ue=si(te),de=-1,ve=ue.length;++de<ve;){var Le=ue[de],Oe=s[Le];(Oe===t||ro(Oe,On[Le])&&!rn.call(s,Le))&&(s[Le]=te[Le])}return s}),NF=Lt(function(s){return s.push(t,Y0),dr(Ox,t,s)});function DF(s,v){return Q(s,ht(v,3),wo)}function FF(s,v){return Q(s,ht(v,3),Lf)}function PF(s,v){return s==null?s:Mf(s,ht(v,3),si)}function BF(s,v){return s==null?s:g0(s,ht(v,3),si)}function jF(s,v){return s&&wo(s,ht(v,3))}function WF(s,v){return s&&Lf(s,ht(v,3))}function zF(s){return s==null?[]:Au(s,mr(s))}function HF(s){return s==null?[]:Au(s,si(s))}function up(s,v,R){var H=s==null?t:na(s,v);return H===t?R:H}function UF(s,v){return s!=null&&Z0(s,v,f2)}function hp(s,v){return s!=null&&Z0(s,v,p2)}var qF=U0(function(s,v,R){v!=null&&typeof v.toString!="function"&&(v=pu.call(v)),s[v]=R},fp(ai)),VF=U0(function(s,v,R){v!=null&&typeof v.toString!="function"&&(v=pu.call(v)),rn.call(s,v)?s[v].push(R):s[v]=[R]},ht),KF=Lt(zl);function mr(s){return oi(s)?l0(s):Df(s)}function si(s){return oi(s)?l0(s,!0):_2(s)}function GF(s,v){var R={};return v=ht(v,3),wo(s,function(H,G,te){jo(R,v(H,G,te),H)}),R}function YF(s,v){var R={};return v=ht(v,3),wo(s,function(H,G,te){jo(R,G,v(H,G,te))}),R}var XF=Ua(function(s,v,R){Eu(s,v,R)}),Ox=Ua(function(s,v,R,H){Eu(s,v,R,H)}),QF=zo(function(s,v){var R={};if(s==null)return R;var H=!1;v=y(v,function(te){return te=ps(te,s),H||(H=te.length>1),te}),xo(s,Xf(s),R),H&&(R=Ii(R,c|f|u,q2));for(var G=v.length;G--;)zf(R,v[G]);return R});function ZF(s,v){return Ix(s,Hu(ht(v)))}var JF=zo(function(s,v){return s==null?{}:$2(s,v)});function Ix(s,v){if(s==null)return{};var R=y(Xf(s),function(H){return[H]});return v=ht(v),C0(s,R,function(H,G){return v(H,G[0])})}function eP(s,v,R){v=ps(v,s);var H=-1,G=v.length;for(G||(G=1,s=t);++H<G;){var te=s==null?t:s[ko(v[H])];te===t&&(H=G,te=R),s=Uo(te)?te.call(s):te}return s}function tP(s,v,R){return s==null?s:Ul(s,v,R)}function nP(s,v,R,H){return H=typeof H=="function"?H:t,s==null?s:Ul(s,v,R,H)}var Nx=K0(mr),Dx=K0(si);function rP(s,v,R){var H=xt(s),G=H||ms(s)||Ka(s);if(v=ht(v,4),R==null){var te=s&&s.constructor;G?R=H?new te:[]:$n(s)?R=Uo(te)?Ha(vu(s)):{}:R={}}return(G?yr:wo)(s,function(ue,de,ve){return v(R,ue,de,ve)}),R}function iP(s,v){return s==null?!0:zf(s,v)}function oP(s,v,R){return s==null?s:R0(s,v,qf(R))}function sP(s,v,R,H){return H=typeof H=="function"?H:t,s==null?s:R0(s,v,qf(R),H)}function Ga(s){return s==null?[]:yn(s,mr(s))}function aP(s){return s==null?[]:yn(s,si(s))}function lP(s,v,R){return R===t&&(R=v,v=t),R!==t&&(R=Fi(R),R=R===R?R:0),v!==t&&(v=Fi(v),v=v===v?v:0),ta(Fi(s),v,R)}function cP(s,v,R){return v=qo(v),R===t?(R=v,v=0):R=qo(R),s=Fi(s),g2(s,v,R)}function uP(s,v,R){if(R&&typeof R!="boolean"&&Ur(s,v,R)&&(v=R=t),R===t&&(typeof v=="boolean"?(R=v,v=t):typeof s=="boolean"&&(R=s,s=t)),s===t&&v===t?(s=0,v=1):(s=qo(s),v===t?(v=s,s=0):v=qo(v)),s>v){var H=s;s=v,v=H}if(R||s%1||v%1){var G=s0();return Lr(s+G*(v-s+We("1e-"+((G+"").length-1))),v)}return Bf(s,v)}var hP=qa(function(s,v,R){return v=v.toLowerCase(),s+(R?Fx(v):v)});function Fx(s){return dp(Jt(s).toLowerCase())}function Px(s){return s=Jt(s),s&&s.replace(Tn,bn).replace(No,"")}function dP(s,v,R){s=Jt(s),v=bi(v);var H=s.length;R=R===t?H:ta(Et(R),0,H);var G=R;return R-=v.length,R>=0&&s.slice(R,G)==v}function fP(s){return s=Jt(s),s&&Rl.test(s)?s.replace(Eo,q):s}function pP(s){return s=Jt(s),s&&Qi.test(s)?s.replace(Ar,"\\$&"):s}var gP=qa(function(s,v,R){return s+(R?"-":"")+v.toLowerCase()}),mP=qa(function(s,v,R){return s+(R?" ":"")+v.toLowerCase()}),vP=W0("toLowerCase");function yP(s,v,R){s=Jt(s),v=Et(v);var H=v?It(s):0;if(!v||H>=v)return s;var G=(v-H)/2;return Iu(xu(G),R)+s+Iu(wu(G),R)}function bP(s,v,R){s=Jt(s),v=Et(v);var H=v?It(s):0;return v&&H<v?s+Iu(v-H,R):s}function wP(s,v,R){s=Jt(s),v=Et(v);var H=v?It(s):0;return v&&H<v?Iu(v-H,R)+s:s}function xP(s,v,R){return R||v==null?v=0:v&&(v=+v),EI(Jt(s).replace(_n,""),v||0)}function kP(s,v,R){return(R?Ur(s,v,R):v===t)?v=1:v=Et(v),jf(Jt(s),v)}function SP(){var s=arguments,v=Jt(s[0]);return s.length<3?v:v.replace(s[1],s[2])}var _P=qa(function(s,v,R){return s+(R?"_":"")+v.toLowerCase()});function CP(s,v,R){return R&&typeof R!="number"&&Ur(s,v,R)&&(v=R=t),R=R===t?J:R>>>0,R?(s=Jt(s),s&&(typeof v=="string"||v!=null&&!cp(v))&&(v=bi(v),!v&&oe(s))?gs(wt(s),0,R):s.split(v,R)):[]}var $P=qa(function(s,v,R){return s+(R?" ":"")+dp(v)});function AP(s,v,R){return s=Jt(s),R=R==null?0:ta(Et(R),0,s.length),v=bi(v),s.slice(R,R+v.length)==v}function EP(s,v,R){var H=ee.templateSettings;R&&Ur(s,v,R)&&(v=t),s=Jt(s),v=Vu({},v,H,G0);var G=Vu({},v.imports,H.imports,G0),te=mr(G),ue=yn(G,te),de,ve,Le=0,Oe=v.interpolate||Ci,Fe="__p += '",Ve=zr((v.escape||Ci).source+"|"+Oe.source+"|"+(Oe===zs?Ji:Ci).source+"|"+(v.evaluate||Ci).source+"|$","g"),nt="//# sourceURL="+(rn.call(v,"sourceURL")?(v.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++bo+"]")+`
|
|
1478
|
+
`;s.replace(Ve,function(pt,Nt,Wt,xi,qr,ki){return Wt||(Wt=xi),Fe+=s.slice(Le,ki).replace(Rr,X),Nt&&(de=!0,Fe+=`' +
|
|
1479
|
+
__e(`+Nt+`) +
|
|
1480
|
+
'`),qr&&(ve=!0,Fe+=`';
|
|
1481
|
+
`+qr+`;
|
|
1482
|
+
__p += '`),Wt&&(Fe+=`' +
|
|
1483
|
+
((__t = (`+Wt+`)) == null ? '' : __t) +
|
|
1484
|
+
'`),Le=ki+pt.length,pt}),Fe+=`';
|
|
1485
|
+
`;var ft=rn.call(v,"variable")&&v.variable;if(!ft)Fe=`with (obj) {
|
|
1486
|
+
`+Fe+`
|
|
1487
|
+
}
|
|
1488
|
+
`;else if(Ll.test(ft))throw new ct(b);Fe=(ve?Fe.replace(Gi,""):Fe).replace(Yi,"$1").replace(Ao,"$1;"),Fe="function("+(ft||"obj")+`) {
|
|
1489
|
+
`+(ft?"":`obj || (obj = {});
|
|
1490
|
+
`)+"var __t, __p = ''"+(de?", __e = _.escape":"")+(ve?`, __j = Array.prototype.join;
|
|
1491
|
+
function print() { __p += __j.call(arguments, '') }
|
|
1492
|
+
`:`;
|
|
1493
|
+
`)+Fe+`return __p
|
|
1494
|
+
}`;var Rt=jx(function(){return At(te,nt+"return "+Fe).apply(t,ue)});if(Rt.source=Fe,lp(Rt))throw Rt;return Rt}function TP(s){return Jt(s).toLowerCase()}function RP(s){return Jt(s).toUpperCase()}function MP(s,v,R){if(s=Jt(s),s&&(R||v===t))return fn(s);if(!s||!(v=bi(v)))return s;var H=wt(s),G=wt(v),te=$t(H,G),ue=Jn(H,G)+1;return gs(H,te,ue).join("")}function LP(s,v,R){if(s=Jt(s),s&&(R||v===t))return s.slice(0,Mt(s)+1);if(!s||!(v=bi(v)))return s;var H=wt(s),G=Jn(H,wt(v))+1;return gs(H,0,G).join("")}function OP(s,v,R){if(s=Jt(s),s&&(R||v===t))return s.replace(_n,"");if(!s||!(v=bi(v)))return s;var H=wt(s),G=$t(H,wt(v));return gs(H,G).join("")}function IP(s,v){var R=O,H=z;if($n(v)){var G="separator"in v?v.separator:G;R="length"in v?Et(v.length):R,H="omission"in v?bi(v.omission):H}s=Jt(s);var te=s.length;if(oe(s)){var ue=wt(s);te=ue.length}if(R>=te)return s;var de=R-It(H);if(de<1)return H;var ve=ue?gs(ue,0,de).join(""):s.slice(0,de);if(G===t)return ve+H;if(ue&&(de+=ve.length-de),cp(G)){if(s.slice(de).search(G)){var Le,Oe=ve;for(G.global||(G=zr(G.source,Jt(fi.exec(G))+"g")),G.lastIndex=0;Le=G.exec(Oe);)var Fe=Le.index;ve=ve.slice(0,Fe===t?de:Fe)}}else if(s.indexOf(bi(G),de)!=de){var Ve=ve.lastIndexOf(G);Ve>-1&&(ve=ve.slice(0,Ve))}return ve+H}function NP(s){return s=Jt(s),s&&Jo.test(s)?s.replace(vr,ut):s}var DP=qa(function(s,v,R){return s+(R?" ":"")+v.toUpperCase()}),dp=W0("toUpperCase");function Bx(s,v,R){return s=Jt(s),v=R?t:v,v===t?pe(s)?wn(s):Y(s):s.match(v)||[]}var jx=Lt(function(s,v){try{return dr(s,t,v)}catch(R){return lp(R)?R:new ct(R)}}),FP=zo(function(s,v){return yr(v,function(R){R=ko(R),jo(s,R,sp(s[R],s))}),s});function PP(s){var v=s==null?0:s.length,R=ht();return s=v?y(s,function(H){if(typeof H[1]!="function")throw new sn(h);return[R(H[0]),H[1]]}):[],Lt(function(H){for(var G=-1;++G<v;){var te=s[G];if(dr(te[0],this,H))return dr(te[1],this,H)}})}function BP(s){return u2(Ii(s,c))}function fp(s){return function(){return s}}function jP(s,v){return s==null||s!==s?v:s}var WP=H0(),zP=H0(!0);function ai(s){return s}function pp(s){return b0(typeof s=="function"?s:Ii(s,c))}function HP(s){return x0(Ii(s,c))}function UP(s,v){return k0(s,Ii(v,c))}var qP=Lt(function(s,v){return function(R){return zl(R,s,v)}}),VP=Lt(function(s,v){return function(R){return zl(s,R,v)}});function gp(s,v,R){var H=mr(v),G=Au(v,H);R==null&&!($n(v)&&(G.length||!H.length))&&(R=v,v=s,s=this,G=Au(v,mr(v)));var te=!($n(R)&&"chain"in R)||!!R.chain,ue=Uo(s);return yr(G,function(de){var ve=v[de];s[de]=ve,ue&&(s.prototype[de]=function(){var Le=this.__chain__;if(te||Le){var Oe=s(this.__wrapped__),Fe=Oe.__actions__=ii(this.__actions__);return Fe.push({func:ve,args:arguments,thisArg:s}),Oe.__chain__=Le,Oe}return ve.apply(s,E([this.value()],arguments))})}),s}function KP(){return on._===this&&(on._=bI),this}function mp(){}function GP(s){return s=Et(s),Lt(function(v){return S0(v,s)})}var YP=Kf(y),XP=Kf(br),QP=Kf(B);function Wx(s){return ep(s)?be(ko(s)):A2(s)}function ZP(s){return function(v){return s==null?t:na(s,v)}}var JP=q0(),eB=q0(!0);function vp(){return[]}function yp(){return!1}function tB(){return{}}function nB(){return""}function rB(){return!0}function iB(s,v){if(s=Et(s),s<1||s>U)return[];var R=J,H=Lr(s,J);v=ht(v),s-=J;for(var G=Ye(H,v);++R<s;)v(R);return G}function oB(s){return xt(s)?y(s,ko):wi(s)?[s]:ii(ax(Jt(s)))}function sB(s){var v=++vI;return Jt(s)+v}var aB=Ou(function(s,v){return s+v},0),lB=Gf("ceil"),cB=Ou(function(s,v){return s/v},1),uB=Gf("floor");function hB(s){return s&&s.length?$u(s,ai,Of):t}function dB(s,v){return s&&s.length?$u(s,ht(v,2),Of):t}function fB(s){return me(s,ai)}function pB(s,v){return me(s,ht(v,2))}function gB(s){return s&&s.length?$u(s,ai,Ff):t}function mB(s,v){return s&&s.length?$u(s,ht(v,2),Ff):t}var vB=Ou(function(s,v){return s*v},1),yB=Gf("round"),bB=Ou(function(s,v){return s-v},0);function wB(s){return s&&s.length?st(s,ai):0}function xB(s,v){return s&&s.length?st(s,ht(v,2)):0}return ee.after=HD,ee.ary=yx,ee.assign=RF,ee.assignIn=Lx,ee.assignInWith=Vu,ee.assignWith=MF,ee.at=LF,ee.before=bx,ee.bind=sp,ee.bindAll=FP,ee.bindKey=wx,ee.castArray=tF,ee.chain=gx,ee.chunk=uN,ee.compact=hN,ee.concat=dN,ee.cond=PP,ee.conforms=BP,ee.constant=fp,ee.countBy=wD,ee.create=OF,ee.curry=xx,ee.curryRight=kx,ee.debounce=Sx,ee.defaults=IF,ee.defaultsDeep=NF,ee.defer=UD,ee.delay=qD,ee.difference=fN,ee.differenceBy=pN,ee.differenceWith=gN,ee.drop=mN,ee.dropRight=vN,ee.dropRightWhile=yN,ee.dropWhile=bN,ee.fill=wN,ee.filter=kD,ee.flatMap=CD,ee.flatMapDeep=$D,ee.flatMapDepth=AD,ee.flatten=hx,ee.flattenDeep=xN,ee.flattenDepth=kN,ee.flip=VD,ee.flow=WP,ee.flowRight=zP,ee.fromPairs=SN,ee.functions=zF,ee.functionsIn=HF,ee.groupBy=ED,ee.initial=CN,ee.intersection=$N,ee.intersectionBy=AN,ee.intersectionWith=EN,ee.invert=qF,ee.invertBy=VF,ee.invokeMap=RD,ee.iteratee=pp,ee.keyBy=MD,ee.keys=mr,ee.keysIn=si,ee.map=ju,ee.mapKeys=GF,ee.mapValues=YF,ee.matches=HP,ee.matchesProperty=UP,ee.memoize=zu,ee.merge=XF,ee.mergeWith=Ox,ee.method=qP,ee.methodOf=VP,ee.mixin=gp,ee.negate=Hu,ee.nthArg=GP,ee.omit=QF,ee.omitBy=ZF,ee.once=KD,ee.orderBy=LD,ee.over=YP,ee.overArgs=GD,ee.overEvery=XP,ee.overSome=QP,ee.partial=ap,ee.partialRight=_x,ee.partition=OD,ee.pick=JF,ee.pickBy=Ix,ee.property=Wx,ee.propertyOf=ZP,ee.pull=LN,ee.pullAll=fx,ee.pullAllBy=ON,ee.pullAllWith=IN,ee.pullAt=NN,ee.range=JP,ee.rangeRight=eB,ee.rearg=YD,ee.reject=DD,ee.remove=DN,ee.rest=XD,ee.reverse=ip,ee.sampleSize=PD,ee.set=tP,ee.setWith=nP,ee.shuffle=BD,ee.slice=FN,ee.sortBy=zD,ee.sortedUniq=UN,ee.sortedUniqBy=qN,ee.split=CP,ee.spread=QD,ee.tail=VN,ee.take=KN,ee.takeRight=GN,ee.takeRightWhile=YN,ee.takeWhile=XN,ee.tap=hD,ee.throttle=ZD,ee.thru=Bu,ee.toArray=Tx,ee.toPairs=Nx,ee.toPairsIn=Dx,ee.toPath=oB,ee.toPlainObject=Mx,ee.transform=rP,ee.unary=JD,ee.union=QN,ee.unionBy=ZN,ee.unionWith=JN,ee.uniq=eD,ee.uniqBy=tD,ee.uniqWith=nD,ee.unset=iP,ee.unzip=op,ee.unzipWith=px,ee.update=oP,ee.updateWith=sP,ee.values=Ga,ee.valuesIn=aP,ee.without=rD,ee.words=Bx,ee.wrap=eF,ee.xor=iD,ee.xorBy=oD,ee.xorWith=sD,ee.zip=aD,ee.zipObject=lD,ee.zipObjectDeep=cD,ee.zipWith=uD,ee.entries=Nx,ee.entriesIn=Dx,ee.extend=Lx,ee.extendWith=Vu,gp(ee,ee),ee.add=aB,ee.attempt=jx,ee.camelCase=hP,ee.capitalize=Fx,ee.ceil=lB,ee.clamp=lP,ee.clone=nF,ee.cloneDeep=iF,ee.cloneDeepWith=oF,ee.cloneWith=rF,ee.conformsTo=sF,ee.deburr=Px,ee.defaultTo=jP,ee.divide=cB,ee.endsWith=dP,ee.eq=ro,ee.escape=fP,ee.escapeRegExp=pP,ee.every=xD,ee.find=SD,ee.findIndex=cx,ee.findKey=DF,ee.findLast=_D,ee.findLastIndex=ux,ee.findLastKey=FF,ee.floor=uB,ee.forEach=mx,ee.forEachRight=vx,ee.forIn=PF,ee.forInRight=BF,ee.forOwn=jF,ee.forOwnRight=WF,ee.get=up,ee.gt=aF,ee.gte=lF,ee.has=UF,ee.hasIn=hp,ee.head=dx,ee.identity=ai,ee.includes=TD,ee.indexOf=_N,ee.inRange=cP,ee.invoke=KF,ee.isArguments=oa,ee.isArray=xt,ee.isArrayBuffer=cF,ee.isArrayLike=oi,ee.isArrayLikeObject=Un,ee.isBoolean=uF,ee.isBuffer=ms,ee.isDate=hF,ee.isElement=dF,ee.isEmpty=fF,ee.isEqual=pF,ee.isEqualWith=gF,ee.isError=lp,ee.isFinite=mF,ee.isFunction=Uo,ee.isInteger=Cx,ee.isLength=Uu,ee.isMap=$x,ee.isMatch=vF,ee.isMatchWith=yF,ee.isNaN=bF,ee.isNative=wF,ee.isNil=kF,ee.isNull=xF,ee.isNumber=Ax,ee.isObject=$n,ee.isObjectLike=In,ee.isPlainObject=Gl,ee.isRegExp=cp,ee.isSafeInteger=SF,ee.isSet=Ex,ee.isString=qu,ee.isSymbol=wi,ee.isTypedArray=Ka,ee.isUndefined=_F,ee.isWeakMap=CF,ee.isWeakSet=$F,ee.join=TN,ee.kebabCase=gP,ee.last=Di,ee.lastIndexOf=RN,ee.lowerCase=mP,ee.lowerFirst=vP,ee.lt=AF,ee.lte=EF,ee.max=hB,ee.maxBy=dB,ee.mean=fB,ee.meanBy=pB,ee.min=gB,ee.minBy=mB,ee.stubArray=vp,ee.stubFalse=yp,ee.stubObject=tB,ee.stubString=nB,ee.stubTrue=rB,ee.multiply=vB,ee.nth=MN,ee.noConflict=KP,ee.noop=mp,ee.now=Wu,ee.pad=yP,ee.padEnd=bP,ee.padStart=wP,ee.parseInt=xP,ee.random=uP,ee.reduce=ID,ee.reduceRight=ND,ee.repeat=kP,ee.replace=SP,ee.result=eP,ee.round=yB,ee.runInContext=fe,ee.sample=FD,ee.size=jD,ee.snakeCase=_P,ee.some=WD,ee.sortedIndex=PN,ee.sortedIndexBy=BN,ee.sortedIndexOf=jN,ee.sortedLastIndex=WN,ee.sortedLastIndexBy=zN,ee.sortedLastIndexOf=HN,ee.startCase=$P,ee.startsWith=AP,ee.subtract=bB,ee.sum=wB,ee.sumBy=xB,ee.template=EP,ee.times=iB,ee.toFinite=qo,ee.toInteger=Et,ee.toLength=Rx,ee.toLower=TP,ee.toNumber=Fi,ee.toSafeInteger=TF,ee.toString=Jt,ee.toUpper=RP,ee.trim=MP,ee.trimEnd=LP,ee.trimStart=OP,ee.truncate=IP,ee.unescape=NP,ee.uniqueId=sB,ee.upperCase=DP,ee.upperFirst=dp,ee.each=mx,ee.eachRight=vx,ee.first=dx,gp(ee,function(){var s={};return wo(ee,function(v,R){rn.call(ee.prototype,R)||(s[R]=v)}),s}(),{chain:!1}),ee.VERSION=r,yr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(s){ee[s].placeholder=ee}),yr(["drop","take"],function(s,v){Bt.prototype[s]=function(R){R=R===t?1:lr(Et(R),0);var H=this.__filtered__&&!v?new Bt(this):this.clone();return H.__filtered__?H.__takeCount__=Lr(R,H.__takeCount__):H.__views__.push({size:Lr(R,J),type:s+(H.__dir__<0?"Right":"")}),H},Bt.prototype[s+"Right"]=function(R){return this.reverse()[s](R).reverse()}}),yr(["filter","map","takeWhile"],function(s,v){var R=v+1,H=R==A||R==I;Bt.prototype[s]=function(G){var te=this.clone();return te.__iteratees__.push({iteratee:ht(G,3),type:R}),te.__filtered__=te.__filtered__||H,te}}),yr(["head","last"],function(s,v){var R="take"+(v?"Right":"");Bt.prototype[s]=function(){return this[R](1).value()[0]}}),yr(["initial","tail"],function(s,v){var R="drop"+(v?"":"Right");Bt.prototype[s]=function(){return this.__filtered__?new Bt(this):this[R](1)}}),Bt.prototype.compact=function(){return this.filter(ai)},Bt.prototype.find=function(s){return this.filter(s).head()},Bt.prototype.findLast=function(s){return this.reverse().find(s)},Bt.prototype.invokeMap=Lt(function(s,v){return typeof s=="function"?new Bt(this):this.map(function(R){return zl(R,s,v)})}),Bt.prototype.reject=function(s){return this.filter(Hu(ht(s)))},Bt.prototype.slice=function(s,v){s=Et(s);var R=this;return R.__filtered__&&(s>0||v<0)?new Bt(R):(s<0?R=R.takeRight(-s):s&&(R=R.drop(s)),v!==t&&(v=Et(v),R=v<0?R.dropRight(-v):R.take(v-s)),R)},Bt.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},Bt.prototype.toArray=function(){return this.take(J)},wo(Bt.prototype,function(s,v){var R=/^(?:filter|find|map|reject)|While$/.test(v),H=/^(?:head|last)$/.test(v),G=ee[H?"take"+(v=="last"?"Right":""):v],te=H||/^find/.test(v);G&&(ee.prototype[v]=function(){var ue=this.__wrapped__,de=H?[1]:arguments,ve=ue instanceof Bt,Le=de[0],Oe=ve||xt(ue),Fe=function(Nt){var Wt=G.apply(ee,E([Nt],de));return H&&Ve?Wt[0]:Wt};Oe&&R&&typeof Le=="function"&&Le.length!=1&&(ve=Oe=!1);var Ve=this.__chain__,nt=!!this.__actions__.length,ft=te&&!Ve,Rt=ve&&!nt;if(!te&&Oe){ue=Rt?ue:new Bt(this);var pt=s.apply(ue,de);return pt.__actions__.push({func:Bu,args:[Fe],thisArg:t}),new Oi(pt,Ve)}return ft&&Rt?s.apply(this,de):(pt=this.thru(Fe),ft?H?pt.value()[0]:pt.value():pt)})}),yr(["pop","push","shift","sort","splice","unshift"],function(s){var v=gr[s],R=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",H=/^(?:pop|shift)$/.test(s);ee.prototype[s]=function(){var G=arguments;if(H&&!this.__chain__){var te=this.value();return v.apply(xt(te)?te:[],G)}return this[R](function(ue){return v.apply(xt(ue)?ue:[],G)})}}),wo(Bt.prototype,function(s,v){var R=ee[v];if(R){var H=R.name+"";rn.call(za,H)||(za[H]=[]),za[H].push({name:v,func:R})}}),za[Lu(t,w).name]=[{name:"wrapper",func:t}],Bt.prototype.clone=NI,Bt.prototype.reverse=DI,Bt.prototype.value=FI,ee.prototype.at=dD,ee.prototype.chain=fD,ee.prototype.commit=pD,ee.prototype.next=gD,ee.prototype.plant=vD,ee.prototype.reverse=yD,ee.prototype.toJSON=ee.prototype.valueOf=ee.prototype.value=bD,ee.prototype.first=ee.prototype.head,Nl&&(ee.prototype[Nl]=mD),ee},jt=er();Zn?((Zn.exports=jt)._=jt,mn._=jt):on._=jt}).call(A$)}(Cc,Cc.exports)),Cc.exports}var T$=E$();Pi("O",lc(T$)).debounce(function(){this.rebuildDisplayText()},300);var Qm={exports:{}},Zm;function R$(){return Zm||(Zm=1,function(n,e){(function(){ace.require(["ace/mode/text"],function(t){n&&(n.exports=t)})})()}(Qm)),Qm.exports}R$();const M$=!0,tr="u-",L$="uplot",O$=tr+"hz",I$=tr+"vt",N$=tr+"title",D$=tr+"wrap",F$=tr+"under",P$=tr+"over",B$=tr+"axis",Rs=tr+"off",j$=tr+"select",W$=tr+"cursor-x",z$=tr+"cursor-y",H$=tr+"cursor-pt",U$=tr+"legend",q$=tr+"live",V$=tr+"inline",K$=tr+"series",G$=tr+"marker",Jm=tr+"label",Y$=tr+"value",hl="width",dl="height",fl="top",ev="bottom",ma="left",Fh="right",Ph="#000",tv=Ph+"0",Bh="mousemove",nv="mousedown",jh="mouseup",rv="mouseenter",iv="mouseleave",ov="dblclick",X$="resize",Q$="scroll",sv="change",$c="dppxchange",Wh="--",va=typeof window<"u",zh=va?document:null,ya=va?window:null,Z$=va?navigator:null;let Kt,Ac;function Hh(){let n=devicePixelRatio;Kt!=n&&(Kt=n,Ac&&Vh(sv,Ac,Hh),Ac=matchMedia(`(min-resolution: ${Kt-.001}dppx) and (max-resolution: ${Kt+.001}dppx)`),Ms(sv,Ac,Hh),ya.dispatchEvent(new CustomEvent($c)))}function li(n,e){if(e!=null){let t=n.classList;!t.contains(e)&&t.add(e)}}function Uh(n,e){let t=n.classList;t.contains(e)&&t.remove(e)}function pn(n,e,t){n.style[e]=t+"px"}function zi(n,e,t,r){let l=zh.createElement(n);return e!=null&&li(l,e),t!=null&&t.insertBefore(l,r),l}function Si(n,e){return zi("div",n,e)}const av=new WeakMap;function lo(n,e,t,r,l){let d="translate("+e+"px,"+t+"px)",h=av.get(n);d!=h&&(n.style.transform=d,av.set(n,d),e<0||t<0||e>r||t>l?li(n,Rs):Uh(n,Rs))}const lv=new WeakMap;function cv(n,e,t){let r=e+t,l=lv.get(n);r!=l&&(lv.set(n,r),n.style.background=e,n.style.borderColor=t)}const uv=new WeakMap;function hv(n,e,t,r){let l=e+""+t,d=uv.get(n);l!=d&&(uv.set(n,l),n.style.height=t+"px",n.style.width=e+"px",n.style.marginLeft=r?-e/2+"px":0,n.style.marginTop=r?-t/2+"px":0)}const qh={passive:!0},J$={...qh,capture:!0};function Ms(n,e,t,r){e.addEventListener(n,t,r?J$:qh)}function Vh(n,e,t,r){e.removeEventListener(n,t,qh)}va&&Hh();function Hi(n,e,t,r){let l;t=t||0,r=r||e.length-1;let d=r<=2147483647;for(;r-t>1;)l=d?t+r>>1:ui((t+r)/2),e[l]<n?t=l:r=l;return n-e[t]<=e[r]-n?t:r}function dv(n){return(e,t,r)=>{let l=-1,d=-1;for(let h=t;h<=r;h++)if(n(e[h])){l=h;break}for(let h=r;h>=t;h--)if(n(e[h])){d=h;break}return[l,d]}}const fv=n=>n!=null,pv=n=>n!=null&&n>0,Ec=dv(fv),eA=dv(pv);function tA(n,e,t,r=0,l=!1){let d=l?eA:Ec,h=l?pv:fv;[e,t]=d(n,e,t);let b=n[e],p=n[e];if(e>-1)if(r==1)b=n[e],p=n[t];else if(r==-1)b=n[t],p=n[e];else for(let g=e;g<=t;g++){let o=n[g];h(o)&&(o<b?b=o:o>p&&(p=o))}return[b??ln,p??-ln]}function Tc(n,e,t,r){let l=vv(n),d=vv(e);n==e&&(l==-1?(n*=t,e/=t):(n/=t,e*=t));let h=t==10?_o:yv,b=l==1?ui:_i,p=d==1?_i:ui,g=b(h(nr(n))),o=p(h(nr(e))),c=ba(t,g),f=ba(t,o);return t==10&&(g<0&&(c=cn(c,-g)),o<0&&(f=cn(f,-o))),r||t==2?(n=c*l,e=f*d):(n=Cv(n,c),e=Lc(e,f)),[n,e]}function Kh(n,e,t,r){let l=Tc(n,e,t,r);return n==0&&(l[0]=0),e==0&&(l[1]=0),l}const Gh=.1,gv={mode:3,pad:Gh},pl={pad:0,soft:null,mode:0},nA={min:pl,max:pl};function Rc(n,e,t,r){return Oc(t)?mv(n,e,t):(pl.pad=t,pl.soft=r?0:null,pl.mode=r?3:0,mv(n,e,nA))}function Ut(n,e){return n??e}function rA(n,e,t){for(e=Ut(e,0),t=Ut(t,n.length-1);e<=t;){if(n[e]!=null)return!0;e++}return!1}function mv(n,e,t){let r=t.min,l=t.max,d=Ut(r.pad,0),h=Ut(l.pad,0),b=Ut(r.hard,-ln),p=Ut(l.hard,ln),g=Ut(r.soft,ln),o=Ut(l.soft,-ln),c=Ut(r.mode,0),f=Ut(l.mode,0),u=e-n,i=_o(u),a=Dr(nr(n),nr(e)),m=_o(a),w=nr(m-i);(u<1e-24||w>10)&&(u=0,(n==0||e==0)&&(u=1e-24,c==2&&g!=ln&&(d=0),f==2&&o!=-ln&&(h=0)));let x=u||a||1e3,M=_o(x),$=ba(10,ui(M)),S=x*(u==0?n==0?.1:1:d),k=cn(Cv(n-S,$/10),24),T=n>=g&&(c==1||c==3&&k<=g||c==2&&k>=g)?g:ln,D=Dr(b,k<T&&n>=T?T:Ui(T,k)),L=x*(u==0?e==0?.1:1:h),O=cn(Lc(e+L,$/10),24),z=e<=o&&(f==1||f==3&&O>=o||f==2&&O<=o)?o:-ln,P=Ui(p,O>z&&e<=z?z:Dr(z,O));return D==P&&D==0&&(P=100),[D,P]}const iA=new Intl.NumberFormat(va?Z$.language:"en-US"),Yh=n=>iA.format(n),ci=Math,Mc=ci.PI,nr=ci.abs,ui=ci.floor,rr=ci.round,_i=ci.ceil,Ui=ci.min,Dr=ci.max,ba=ci.pow,vv=ci.sign,_o=ci.log10,yv=ci.log2,oA=(n,e=1)=>ci.sinh(n)*e,Xh=(n,e=1)=>ci.asinh(n/e),ln=1/0;function bv(n){return(_o((n^n>>31)-(n>>31))|0)+1}function Qh(n,e,t){return Ui(Dr(n,e),t)}function wv(n){return typeof n=="function"}function Dt(n){return wv(n)?n:()=>n}const sA=()=>{},xv=n=>n,kv=(n,e)=>e,aA=n=>null,Sv=n=>!0,_v=(n,e)=>n==e,lA=/\.\d*?(?=9{6,}|0{6,})/gm,Ls=n=>{if(Av(n)||Qo.has(n))return n;const e=`${n}`,t=e.match(lA);if(t==null)return n;let r=t[0].length-1;if(e.indexOf("e-")!=-1){let[l,d]=e.split("e");return+`${Ls(l)}e${d}`}return cn(n,r)};function Os(n,e){return Ls(cn(Ls(n/e))*e)}function Lc(n,e){return Ls(_i(Ls(n/e))*e)}function Cv(n,e){return Ls(ui(Ls(n/e))*e)}function cn(n,e=0){if(Av(n))return n;let t=10**e,r=n*t*(1+Number.EPSILON);return rr(r)/t}const Qo=new Map;function $v(n){return((""+n).split(".")[1]||"").length}function gl(n,e,t,r){let l=[],d=r.map($v);for(let h=e;h<t;h++){let b=nr(h),p=cn(ba(n,h),b);for(let g=0;g<r.length;g++){let o=n==10?+`${r[g]}e${h}`:r[g]*p,c=(h>=0?0:b)+(h>=d[g]?0:d[g]),f=n==10?o:cn(o,c);l.push(f),Qo.set(f,c)}}return l}const ml={},Zh=[],wa=[null,null],Zo=Array.isArray,Av=Number.isInteger,cA=n=>n===void 0;function Ev(n){return typeof n=="string"}function Oc(n){let e=!1;if(n!=null){let t=n.constructor;e=t==null||t==Object}return e}function uA(n){return n!=null&&typeof n=="object"}const hA=Object.getPrototypeOf(Uint8Array),Tv="__proto__";function xa(n,e=Oc){let t;if(Zo(n)){let r=n.find(l=>l!=null);if(Zo(r)||e(r)){t=Array(n.length);for(let l=0;l<n.length;l++)t[l]=xa(n[l],e)}else t=n.slice()}else if(n instanceof hA)t=n.slice();else if(e(n)){t={};for(let r in n)r!=Tv&&(t[r]=xa(n[r],e))}else t=n;return t}function Gn(n){let e=arguments;for(let t=1;t<e.length;t++){let r=e[t];for(let l in r)l!=Tv&&(Oc(n[l])?Gn(n[l],xa(r[l])):n[l]=xa(r[l]))}return n}const dA=0,fA=1,pA=2;function gA(n,e,t){for(let r=0,l,d=-1;r<e.length;r++){let h=e[r];if(h>d){for(l=h-1;l>=0&&n[l]==null;)n[l--]=null;for(l=h+1;l<t&&n[l]==null;)n[d=l++]=null}}}function mA(n,e){if(bA(n)){let h=n[0].slice();for(let b=1;b<n.length;b++)h.push(...n[b].slice(1));return wA(h[0])||(h=yA(h)),h}let t=new Set;for(let h=0;h<n.length;h++){let b=n[h][0],p=b.length;for(let g=0;g<p;g++)t.add(b[g])}let r=[Array.from(t).sort((h,b)=>h-b)],l=r[0].length,d=new Map;for(let h=0;h<l;h++)d.set(r[0][h],h);for(let h=0;h<n.length;h++){let b=n[h],p=b[0];for(let g=1;g<b.length;g++){let o=b[g],c=Array(l).fill(void 0),f=e?e[h][g]:fA,u=[];for(let i=0;i<o.length;i++){let a=o[i],m=d.get(p[i]);a===null?f!=dA&&(c[m]=a,f==pA&&u.push(m)):c[m]=a}gA(c,u,l),r.push(c)}}return r}const vA=typeof queueMicrotask>"u"?n=>Promise.resolve().then(n):queueMicrotask;function yA(n){let e=n[0],t=e.length,r=Array(t);for(let d=0;d<r.length;d++)r[d]=d;r.sort((d,h)=>e[d]-e[h]);let l=[];for(let d=0;d<n.length;d++){let h=n[d],b=Array(t);for(let p=0;p<t;p++)b[p]=h[r[p]];l.push(b)}return l}function bA(n){let e=n[0][0],t=e.length;for(let r=1;r<n.length;r++){let l=n[r][0];if(l.length!=t)return!1;if(l!=e){for(let d=0;d<t;d++)if(l[d]!=e[d])return!1}}return!0}function wA(n,e=100){const t=n.length;if(t<=1)return!0;let r=0,l=t-1;for(;r<=l&&n[r]==null;)r++;for(;l>=r&&n[l]==null;)l--;if(l<=r)return!0;const d=Dr(1,ui((l-r+1)/e));for(let h=n[r],b=r+d;b<=l;b+=d){const p=n[b];if(p!=null){if(p<=h)return!1;h=p}}return!0}const Rv=["January","February","March","April","May","June","July","August","September","October","November","December"],Mv=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function Lv(n){return n.slice(0,3)}const xA=Mv.map(Lv),kA=Rv.map(Lv),SA={MMMM:Rv,MMM:kA,WWWW:Mv,WWW:xA};function vl(n){return(n<10?"0":"")+n}function _A(n){return(n<10?"00":n<100?"0":"")+n}const CA={YYYY:n=>n.getFullYear(),YY:n=>(n.getFullYear()+"").slice(2),MMMM:(n,e)=>e.MMMM[n.getMonth()],MMM:(n,e)=>e.MMM[n.getMonth()],MM:n=>vl(n.getMonth()+1),M:n=>n.getMonth()+1,DD:n=>vl(n.getDate()),D:n=>n.getDate(),WWWW:(n,e)=>e.WWWW[n.getDay()],WWW:(n,e)=>e.WWW[n.getDay()],HH:n=>vl(n.getHours()),H:n=>n.getHours(),h:n=>{let e=n.getHours();return e==0?12:e>12?e-12:e},AA:n=>n.getHours()>=12?"PM":"AM",aa:n=>n.getHours()>=12?"pm":"am",a:n=>n.getHours()>=12?"p":"a",mm:n=>vl(n.getMinutes()),m:n=>n.getMinutes(),ss:n=>vl(n.getSeconds()),s:n=>n.getSeconds(),fff:n=>_A(n.getMilliseconds())};function Jh(n,e){e=e||SA;let t=[],r=/\{([a-z]+)\}|[^{]+/gi,l;for(;l=r.exec(n);)t.push(l[0][0]=="{"?CA[l[1]]:l[0]);return d=>{let h="";for(let b=0;b<t.length;b++)h+=typeof t[b]=="string"?t[b]:t[b](d,e);return h}}const $A=new Intl.DateTimeFormat().resolvedOptions().timeZone;function AA(n,e){let t;return e=="UTC"||e=="Etc/UTC"?t=new Date(+n+n.getTimezoneOffset()*6e4):e==$A?t=n:(t=new Date(n.toLocaleString("en-US",{timeZone:e})),t.setMilliseconds(n.getMilliseconds())),t}const Ov=n=>n%1==0,Ic=[1,2,2.5,5],EA=gl(10,-32,0,Ic),Iv=gl(10,0,32,Ic),TA=Iv.filter(Ov),Is=EA.concat(Iv),ed=`
|
|
1495
|
+
`,Nv="{YYYY}",Dv=ed+Nv,Fv="{M}/{D}",yl=ed+Fv,Nc=yl+"/{YY}",Pv="{aa}",RA="{h}:{mm}",ka=RA+Pv,Bv=ed+ka,jv=":{ss}",Qt=null;function Wv(n){let e=n*1e3,t=e*60,r=t*60,l=r*24,d=l*30,h=l*365,b=(n==1?gl(10,0,3,Ic).filter(Ov):gl(10,-3,0,Ic)).concat([e,e*5,e*10,e*15,e*30,t,t*5,t*10,t*15,t*30,r,r*2,r*3,r*4,r*6,r*8,r*12,l,l*2,l*3,l*4,l*5,l*6,l*7,l*8,l*9,l*10,l*15,d,d*2,d*3,d*4,d*6,h,h*2,h*5,h*10,h*25,h*50,h*100]);const p=[[h,Nv,Qt,Qt,Qt,Qt,Qt,Qt,1],[l*28,"{MMM}",Dv,Qt,Qt,Qt,Qt,Qt,1],[l,Fv,Dv,Qt,Qt,Qt,Qt,Qt,1],[r,"{h}"+Pv,Nc,Qt,yl,Qt,Qt,Qt,1],[t,ka,Nc,Qt,yl,Qt,Qt,Qt,1],[e,jv,Nc+" "+ka,Qt,yl+" "+ka,Qt,Bv,Qt,1],[n,jv+".{fff}",Nc+" "+ka,Qt,yl+" "+ka,Qt,Bv,Qt,1]];function g(o){return(c,f,u,i,a,m)=>{let w=[],x=a>=h,M=a>=d&&a<h,$=o(u),S=cn($*n,3),k=td($.getFullYear(),x?0:$.getMonth(),M||x?1:$.getDate()),T=cn(k*n,3);if(M||x){let D=M?a/d:0,L=x?a/h:0,O=S==T?S:cn(td(k.getFullYear()+L,k.getMonth()+D,1)*n,3),z=new Date(rr(O/n)),P=z.getFullYear(),N=z.getMonth();for(let A=0;O<=i;A++){let _=td(P+L*A,N+D*A,1),I=_-o(cn(_*n,3));O=cn((+_+I)*n,3),O<=i&&w.push(O)}}else{let D=a>=l?l:a,L=ui(u)-ui(S),O=T+L+Lc(S-T,D);w.push(O);let z=o(O),P=z.getHours()+z.getMinutes()/t+z.getSeconds()/r,N=a/r,A=c.axes[f]._space,_=m/A;for(;O=cn(O+a,n==1?0:3),!(O>i);)if(N>1){let I=ui(cn(P+N,6))%24,j=o(O).getHours()-I;j>1&&(j=-1),O-=j*r,P=(P+N)%24;let U=w[w.length-1];cn((O-U)/a,3)*_>=.7&&w.push(O)}else w.push(O)}return w}}return[b,p,g]}const[MA,LA,OA]=Wv(1),[IA,NA,DA]=Wv(.001);gl(2,-53,53,[1]);function zv(n,e){return n.map(t=>t.map((r,l)=>l==0||l==8||r==null?r:e(l==1||t[8]==0?r:t[1]+r)))}function Hv(n,e){return(t,r,l,d,h)=>{let b=e.find(i=>h>=i[0])||e[e.length-1],p,g,o,c,f,u;return r.map(i=>{let a=n(i),m=a.getFullYear(),w=a.getMonth(),x=a.getDate(),M=a.getHours(),$=a.getMinutes(),S=a.getSeconds(),k=m!=p&&b[2]||w!=g&&b[3]||x!=o&&b[4]||M!=c&&b[5]||$!=f&&b[6]||S!=u&&b[7]||b[1];return p=m,g=w,o=x,c=M,f=$,u=S,k(a)})}}function FA(n,e){let t=Jh(e);return(r,l,d,h,b)=>l.map(p=>t(n(p)))}function td(n,e,t){return new Date(n,e,t)}function Uv(n,e){return e(n)}const PA="{YYYY}-{MM}-{DD} {h}:{mm}{aa}";function qv(n,e){return(t,r,l,d)=>d==null?Wh:e(n(r))}function BA(n,e){let t=n.series[e];return t.width?t.stroke(n,e):t.points.width?t.points.stroke(n,e):null}function jA(n,e){return n.series[e].fill(n,e)}const WA={show:!0,live:!0,isolate:!1,mount:sA,markers:{show:!0,width:2,stroke:BA,fill:jA,dash:"solid"},idx:null,idxs:null,values:[]};function zA(n,e){let t=n.cursor.points,r=Si(),l=t.size(n,e);pn(r,hl,l),pn(r,dl,l);let d=l/-2;pn(r,"marginLeft",d),pn(r,"marginTop",d);let h=t.width(n,e,l);return h&&pn(r,"borderWidth",h),r}function HA(n,e){let t=n.series[e].points;return t._fill||t._stroke}function UA(n,e){let t=n.series[e].points;return t._stroke||t._fill}function qA(n,e){return n.series[e].points.size}const nd=[0,0];function VA(n,e,t){return nd[0]=e,nd[1]=t,nd}function Dc(n,e,t,r=!0){return l=>{l.button==0&&(!r||l.target==e)&&t(l)}}function rd(n,e,t,r=!0){return l=>{(!r||l.target==e)&&t(l)}}const KA={show:!0,x:!0,y:!0,lock:!1,move:VA,points:{one:!1,show:zA,size:qA,width:0,stroke:UA,fill:HA},bind:{mousedown:Dc,mouseup:Dc,click:Dc,dblclick:Dc,mousemove:rd,mouseleave:rd,mouseenter:rd},drag:{setScale:!0,x:!0,y:!1,dist:0,uni:null,click:(n,e)=>{e.stopPropagation(),e.stopImmediatePropagation()},_x:!1,_y:!1},focus:{dist:(n,e,t,r,l)=>r-l,prox:-1,bias:0},hover:{skip:[void 0],prox:null,bias:0},left:-10,top:-10,idx:null,dataIdx:null,idxs:null,event:null},Vv={show:!0,stroke:"rgba(0,0,0,0.07)",width:2},id=Gn({},Vv,{filter:kv}),Kv=Gn({},id,{size:10}),Gv=Gn({},Vv,{show:!1}),od='12px system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"',Yv="bold "+od,Xv=1.5,Qv={show:!0,scale:"x",stroke:Ph,space:50,gap:5,alignTo:1,size:50,labelGap:0,labelSize:30,labelFont:Yv,side:2,grid:id,ticks:Kv,border:Gv,font:od,lineGap:Xv,rotate:0},GA="Value",YA="Time",Zv={show:!0,scale:"x",auto:!1,sorted:1,min:ln,max:-ln,idxs:[]};function XA(n,e,t,r,l){return e.map(d=>d==null?"":Yh(d))}function QA(n,e,t,r,l,d,h){let b=[],p=Qo.get(l)||0;t=h?t:cn(Lc(t,l),p);for(let g=t;g<=r;g=cn(g+l,p))b.push(Object.is(g,-0)?0:g);return b}function sd(n,e,t,r,l,d,h){const b=[],p=n.scales[n.axes[e].scale].log,g=p==10?_o:yv,o=ui(g(t));l=ba(p,o),p==10&&(l=Is[Hi(l,Is)]);let c=t,f=l*p;p==10&&(f=Is[Hi(f,Is)]);do b.push(c),c=c+l,p==10&&!Qo.has(c)&&(c=cn(c,Qo.get(l))),c>=f&&(l=c,f=l*p,p==10&&(f=Is[Hi(f,Is)]));while(c<=r);return b}function ZA(n,e,t,r,l,d,h){let b=n.scales[n.axes[e].scale].asinh,p=r>b?sd(n,e,Dr(b,t),r,l):[b],g=r>=0&&t<=0?[0]:[];return(t<-b?sd(n,e,Dr(b,-r),-t,l):[b]).reverse().map(o=>-o).concat(g,p)}const Jv=/./,JA=/[12357]/,eE=/[125]/,ey=/1/,ad=(n,e,t,r)=>n.map((l,d)=>e==4&&l==0||d%r==0&&t.test(l.toExponential()[l<0?1:0])?l:null);function tE(n,e,t,r,l){let d=n.axes[t],h=d.scale,b=n.scales[h],p=n.valToPos,g=d._space,o=p(10,h),c=p(9,h)-o>=g?Jv:p(7,h)-o>=g?JA:p(5,h)-o>=g?eE:ey;if(c==ey){let f=nr(p(1,h)-o);if(f<g)return ad(e.slice().reverse(),b.distr,c,_i(g/f)).reverse()}return ad(e,b.distr,c,1)}function nE(n,e,t,r,l){let d=n.axes[t],h=d.scale,b=d._space,p=n.valToPos,g=nr(p(1,h)-p(2,h));return g<b?ad(e.slice().reverse(),3,Jv,_i(b/g)).reverse():e}function rE(n,e,t,r){return r==null?Wh:e==null?"":Yh(e)}const ty={show:!0,scale:"y",stroke:Ph,space:30,gap:5,alignTo:1,size:50,labelGap:0,labelSize:30,labelFont:Yv,side:3,grid:id,ticks:Kv,border:Gv,font:od,lineGap:Xv,rotate:0};function iE(n,e){let t=3+(n||1)*2;return cn(t*e,3)}function oE(n,e){let{scale:t,idxs:r}=n.series[0],l=n._data[0],d=n.valToPos(l[r[0]],t,!0),h=n.valToPos(l[r[1]],t,!0),b=nr(h-d),p=n.series[e],g=b/(p.points.space*Kt);return r[1]-r[0]<=g}const ny={scale:null,auto:!0,sorted:0,min:ln,max:-ln},ry=(n,e,t,r,l)=>l,iy={show:!0,auto:!0,sorted:0,gaps:ry,alpha:1,facets:[Gn({},ny,{scale:"x"}),Gn({},ny,{scale:"y"})]},oy={scale:"y",auto:!0,sorted:0,show:!0,spanGaps:!1,gaps:ry,alpha:1,points:{show:oE,filter:null},values:null,min:ln,max:-ln,idxs:[],path:null,clip:null};function sE(n,e,t,r,l){return t/10}const sy={time:M$,auto:!0,distr:1,log:10,asinh:1,min:null,max:null,dir:1,ori:0},aE=Gn({},sy,{time:!1,ori:1}),ay={};function ly(n,e){let t=ay[n];return t||(t={key:n,plots:[],sub(r){t.plots.push(r)},unsub(r){t.plots=t.plots.filter(l=>l!=r)},pub(r,l,d,h,b,p,g){for(let o=0;o<t.plots.length;o++)t.plots[o]!=l&&t.plots[o].pub(r,l,d,h,b,p,g)}},n!=null&&(ay[n]=t)),t}const Sa=1,ld=2;function Ns(n,e,t){const r=n.mode,l=n.series[e],d=r==2?n._data[e]:n._data,h=n.scales,b=n.bbox;let p=d[0],g=r==2?d[1]:d[e],o=r==2?h[l.facets[0].scale]:h[n.series[0].scale],c=r==2?h[l.facets[1].scale]:h[l.scale],f=b.left,u=b.top,i=b.width,a=b.height,m=n.valToPosH,w=n.valToPosV;return o.ori==0?t(l,p,g,o,c,m,w,f,u,i,a,Pc,_a,jc,hy,fy):t(l,p,g,o,c,w,m,u,f,a,i,Bc,Ca,hd,dy,py)}function cd(n,e){let t=0,r=0,l=Ut(n.bands,Zh);for(let d=0;d<l.length;d++){let h=l[d];h.series[0]==e?t=h.dir:h.series[1]==e&&(h.dir==1?r|=1:r|=2)}return[t,r==1?-1:r==2?1:r==3?2:0]}function lE(n,e,t,r,l){let d=n.mode,h=n.series[e],b=d==2?h.facets[1].scale:h.scale,p=n.scales[b];return l==-1?p.min:l==1?p.max:p.distr==3?p.dir==1?p.min:p.max:0}function Co(n,e,t,r,l,d){return Ns(n,e,(h,b,p,g,o,c,f,u,i,a,m)=>{let w=h.pxRound;const x=g.dir*(g.ori==0?1:-1),M=g.ori==0?_a:Ca;let $,S;x==1?($=t,S=r):($=r,S=t);let k=w(c(b[$],g,a,u)),T=w(f(p[$],o,m,i)),D=w(c(b[S],g,a,u)),L=w(f(d==1?o.max:o.min,o,m,i)),O=new Path2D(l);return M(O,D,L),M(O,k,L),M(O,k,T),O})}function Fc(n,e,t,r,l,d){let h=null;if(n.length>0){h=new Path2D;const b=e==0?jc:hd;let p=t;for(let c=0;c<n.length;c++){let f=n[c];if(f[1]>f[0]){let u=f[0]-p;u>0&&b(h,p,r,u,r+d),p=f[1]}}let g=t+l-p,o=10;g>0&&b(h,p,r-o/2,g,r+d+o)}return h}function cE(n,e,t){let r=n[n.length-1];r&&r[0]==e?r[1]=t:n.push([e,t])}function ud(n,e,t,r,l,d,h){let b=[],p=n.length;for(let g=l==1?t:r;g>=t&&g<=r;g+=l)if(e[g]===null){let o=g,c=g;if(l==1)for(;++g<=r&&e[g]===null;)c=g;else for(;--g>=t&&e[g]===null;)c=g;let f=d(n[o]),u=c==o?f:d(n[c]),i=o-l;f=h<=0&&i>=0&&i<p?d(n[i]):f;let a=c+l;u=h>=0&&a>=0&&a<p?d(n[a]):u,u>=f&&b.push([f,u])}return b}function cy(n){return n==0?xv:n==1?rr:e=>Os(e,n)}function uy(n){let e=n==0?Pc:Bc,t=n==0?(l,d,h,b,p,g)=>{l.arcTo(d,h,b,p,g)}:(l,d,h,b,p,g)=>{l.arcTo(h,d,p,b,g)},r=n==0?(l,d,h,b,p)=>{l.rect(d,h,b,p)}:(l,d,h,b,p)=>{l.rect(h,d,p,b)};return(l,d,h,b,p,g=0,o=0)=>{g==0&&o==0?r(l,d,h,b,p):(g=Ui(g,b/2,p/2),o=Ui(o,b/2,p/2),e(l,d+g,h),t(l,d+b,h,d+b,h+p,g),t(l,d+b,h+p,d,h+p,o),t(l,d,h+p,d,h,o),t(l,d,h,d+b,h,g),l.closePath())}}const Pc=(n,e,t)=>{n.moveTo(e,t)},Bc=(n,e,t)=>{n.moveTo(t,e)},_a=(n,e,t)=>{n.lineTo(e,t)},Ca=(n,e,t)=>{n.lineTo(t,e)},jc=uy(0),hd=uy(1),hy=(n,e,t,r,l,d)=>{n.arc(e,t,r,l,d)},dy=(n,e,t,r,l,d)=>{n.arc(t,e,r,l,d)},fy=(n,e,t,r,l,d,h)=>{n.bezierCurveTo(e,t,r,l,d,h)},py=(n,e,t,r,l,d,h)=>{n.bezierCurveTo(t,e,l,r,h,d)};function gy(n){return(e,t,r,l,d)=>Ns(e,t,(h,b,p,g,o,c,f,u,i,a,m)=>{let{pxRound:w,points:x}=h,M,$;g.ori==0?(M=Pc,$=hy):(M=Bc,$=dy);const S=cn(x.width*Kt,3);let k=(x.size-x.width)/2*Kt,T=cn(k*2,3),D=new Path2D,L=new Path2D,{left:O,top:z,width:P,height:N}=e.bbox;jc(L,O-T,z-T,P+T*2,N+T*2);const A=_=>{if(p[_]!=null){let I=w(c(b[_],g,a,u)),j=w(f(p[_],o,m,i));M(D,I+k,j),$(D,I,j,k,0,Mc*2)}};if(d)d.forEach(A);else for(let _=r;_<=l;_++)A(_);return{stroke:S>0?D:null,fill:D,clip:L,flags:Sa|ld}})}function my(n){return(e,t,r,l,d,h)=>{r!=l&&(d!=r&&h!=r&&n(e,t,r),d!=l&&h!=l&&n(e,t,l),n(e,t,h))}}const uE=my(_a),hE=my(Ca);function vy(n){const e=Ut(n==null?void 0:n.alignGaps,0);return(t,r,l,d)=>Ns(t,r,(h,b,p,g,o,c,f,u,i,a,m)=>{[l,d]=Ec(p,l,d);let w=h.pxRound,x=P=>w(c(P,g,a,u)),M=P=>w(f(P,o,m,i)),$,S;g.ori==0?($=_a,S=uE):($=Ca,S=hE);const k=g.dir*(g.ori==0?1:-1),T={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:Sa},D=T.stroke;let L=!1;if(d-l>=a*4){let P=ae=>t.posToVal(ae,g.key,!0),N=null,A=null,_,I,j,U=x(b[k==1?l:d]),K=x(b[l]),Z=x(b[d]),J=P(k==1?K+1:Z-1);for(let ae=k==1?l:d;ae>=l&&ae<=d;ae+=k){let ne=b[ae],se=(k==1?ne<J:ne>J)?U:x(ne),ce=p[ae];se==U?ce!=null?(I=ce,N==null?($(D,se,M(I)),_=N=A=I):I<N?N=I:I>A&&(A=I)):ce===null&&(L=!0):(N!=null&&S(D,U,M(N),M(A),M(_),M(I)),ce!=null?(I=ce,$(D,se,M(I)),N=A=_=I):(N=A=null,ce===null&&(L=!0)),U=se,J=P(U+k))}N!=null&&N!=A&&j!=U&&S(D,U,M(N),M(A),M(_),M(I))}else for(let P=k==1?l:d;P>=l&&P<=d;P+=k){let N=p[P];N===null?L=!0:N!=null&&$(D,x(b[P]),M(N))}let[O,z]=cd(t,r);if(h.fill!=null||O!=0){let P=T.fill=new Path2D(D),N=h.fillTo(t,r,h.min,h.max,O),A=M(N),_=x(b[l]),I=x(b[d]);k==-1&&([I,_]=[_,I]),$(P,I,A),$(P,_,A)}if(!h.spanGaps){let P=[];L&&P.push(...ud(b,p,l,d,k,x,e)),T.gaps=P=h.gaps(t,r,l,d,P),T.clip=Fc(P,g.ori,u,i,a,m)}return z!=0&&(T.band=z==2?[Co(t,r,l,d,D,-1),Co(t,r,l,d,D,1)]:Co(t,r,l,d,D,z)),T})}function dE(n){const e=Ut(n.align,1),t=Ut(n.ascDesc,!1),r=Ut(n.alignGaps,0),l=Ut(n.extend,!1);return(d,h,b,p)=>Ns(d,h,(g,o,c,f,u,i,a,m,w,x,M)=>{[b,p]=Ec(c,b,p);let $=g.pxRound,{left:S,width:k}=d.bbox,T=Z=>$(i(Z,f,x,m)),D=Z=>$(a(Z,u,M,w)),L=f.ori==0?_a:Ca;const O={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:Sa},z=O.stroke,P=f.dir*(f.ori==0?1:-1);let N=D(c[P==1?b:p]),A=T(o[P==1?b:p]),_=A,I=A;l&&e==-1&&(I=S,L(z,I,N)),L(z,A,N);for(let Z=P==1?b:p;Z>=b&&Z<=p;Z+=P){let J=c[Z];if(J==null)continue;let ae=T(o[Z]),ne=D(J);e==1?L(z,ae,N):L(z,_,ne),L(z,ae,ne),N=ne,_=ae}let j=_;l&&e==1&&(j=S+k,L(z,j,N));let[U,K]=cd(d,h);if(g.fill!=null||U!=0){let Z=O.fill=new Path2D(z),J=g.fillTo(d,h,g.min,g.max,U),ae=D(J);L(Z,j,ae),L(Z,I,ae)}if(!g.spanGaps){let Z=[];Z.push(...ud(o,c,b,p,P,T,r));let J=g.width*Kt/2,ae=t||e==1?J:-J,ne=t||e==-1?-J:J;Z.forEach(se=>{se[0]+=ae,se[1]+=ne}),O.gaps=Z=g.gaps(d,h,b,p,Z),O.clip=Fc(Z,f.ori,m,w,x,M)}return K!=0&&(O.band=K==2?[Co(d,h,b,p,z,-1),Co(d,h,b,p,z,1)]:Co(d,h,b,p,z,K)),O})}function yy(n,e,t,r,l,d,h=ln){if(n.length>1){let b=null;for(let p=0,g=1/0;p<n.length;p++)if(e[p]!==void 0){if(b!=null){let o=nr(n[p]-n[b]);o<g&&(g=o,h=nr(t(n[p],r,l,d)-t(n[b],r,l,d)))}b=p}}return h}function fE(n){n=n||ml;const e=Ut(n.size,[.6,ln,1]),t=n.align||0,r=n.gap||0;let l=n.radius;l=l==null?[0,0]:typeof l=="number"?[l,0]:l;const d=Dt(l),h=1-e[0],b=Ut(e[1],ln),p=Ut(e[2],1),g=Ut(n.disp,ml),o=Ut(n.each,u=>{}),{fill:c,stroke:f}=g;return(u,i,a,m)=>Ns(u,i,(w,x,M,$,S,k,T,D,L,O,z)=>{let P=w.pxRound,N=t,A=r*Kt,_=b*Kt,I=p*Kt,j,U;$.ori==0?[j,U]=d(u,i):[U,j]=d(u,i);const K=$.dir*($.ori==0?1:-1);let Z=$.ori==0?jc:hd,J=$.ori==0?o:(qe,qt,gn,Qn,Br,$r,Sn)=>{o(qe,qt,gn,Br,Qn,Sn,$r)},ae=Ut(u.bands,Zh).find(qe=>qe.series[0]==i),ne=ae!=null?ae.dir:0,se=w.fillTo(u,i,w.min,w.max,ne),ce=P(T(se,S,z,L)),he,ge,Ee,Te=O,Me=P(w.width*Kt),Xe=!1,Ke=null,dt=null,rt=null,gt=null;c!=null&&(Me==0||f!=null)&&(Xe=!0,Ke=c.values(u,i,a,m),dt=new Map,new Set(Ke).forEach(qe=>{qe!=null&&dt.set(qe,new Path2D)}),Me>0&&(rt=f.values(u,i,a,m),gt=new Map,new Set(rt).forEach(qe=>{qe!=null&>.set(qe,new Path2D)})));let{x0:tn,size:jn}=g;if(tn!=null&&jn!=null){N=1,x=tn.values(u,i,a,m),tn.unit==2&&(x=x.map(qt=>u.posToVal(D+qt*O,$.key,!0)));let qe=jn.values(u,i,a,m);jn.unit==2?ge=qe[0]*O:ge=k(qe[0],$,O,D)-k(0,$,O,D),Te=yy(x,M,k,$,O,D,Te),Ee=Te-ge+A}else Te=yy(x,M,k,$,O,D,Te),Ee=Te*h+A,ge=Te-Ee;Ee<1&&(Ee=0),Me>=ge/2&&(Me=0),Ee<5&&(P=xv);let Zt=Ee>0,hi=Te-Ee-(Zt?Me:0);ge=P(Qh(hi,I,_)),he=(N==0?ge/2:N==K?0:ge)-N*K*((N==0?A/2:0)+(Zt?Me/2:0));const kn={stroke:null,fill:null,clip:null,band:null,gaps:null,flags:0},Xn=Xe?null:new Path2D;let ur=null;if(ae!=null)ur=u.data[ae.series[1]];else{let{y0:qe,y1:qt}=g;qe!=null&&qt!=null&&(M=qt.values(u,i,a,m),ur=qe.values(u,i,a,m))}let Pr=j*ge,yt=U*ge;for(let qe=K==1?a:m;qe>=a&&qe<=m;qe+=K){let qt=M[qe];if(qt==null)continue;if(ur!=null){let nn=ur[qe]??0;if(qt-nn==0)continue;ce=T(nn,S,z,L)}let gn=$.distr!=2||g!=null?x[qe]:qe,Qn=k(gn,$,O,D),Br=T(Ut(qt,se),S,z,L),$r=P(Qn-he),Sn=P(Dr(Br,ce)),ir=P(Ui(Br,ce)),hr=Sn-ir;if(qt!=null){let nn=qt<0?yt:Pr,or=qt<0?Pr:yt;Xe?(Me>0&&rt[qe]!=null&&Z(gt.get(rt[qe]),$r,ir+ui(Me/2),ge,Dr(0,hr-Me),nn,or),Ke[qe]!=null&&Z(dt.get(Ke[qe]),$r,ir+ui(Me/2),ge,Dr(0,hr-Me),nn,or)):Z(Xn,$r,ir+ui(Me/2),ge,Dr(0,hr-Me),nn,or),J(u,i,qe,$r-Me/2,ir,ge+Me,hr)}}return Me>0?kn.stroke=Xe?gt:Xn:Xe||(kn._fill=w.width==0?w._fill:w._stroke??w._fill,kn.width=0),kn.fill=Xe?dt:Xn,kn})}function pE(n,e){const t=Ut(e==null?void 0:e.alignGaps,0);return(r,l,d,h)=>Ns(r,l,(b,p,g,o,c,f,u,i,a,m,w)=>{[d,h]=Ec(g,d,h);let x=b.pxRound,M=j=>x(f(j,o,m,i)),$=j=>x(u(j,c,w,a)),S,k,T;o.ori==0?(S=Pc,T=_a,k=fy):(S=Bc,T=Ca,k=py);const D=o.dir*(o.ori==0?1:-1);let L=M(p[D==1?d:h]),O=L,z=[],P=[];for(let j=D==1?d:h;j>=d&&j<=h;j+=D)if(g[j]!=null){let U=p[j],K=M(U);z.push(O=K),P.push($(g[j]))}const N={stroke:n(z,P,S,T,k,x),fill:null,clip:null,band:null,gaps:null,flags:Sa},A=N.stroke;let[_,I]=cd(r,l);if(b.fill!=null||_!=0){let j=N.fill=new Path2D(A),U=b.fillTo(r,l,b.min,b.max,_),K=$(U);T(j,O,K),T(j,L,K)}if(!b.spanGaps){let j=[];j.push(...ud(p,g,d,h,D,M,t)),N.gaps=j=b.gaps(r,l,d,h,j),N.clip=Fc(j,o.ori,i,a,m,w)}return I!=0&&(N.band=I==2?[Co(r,l,d,h,A,-1),Co(r,l,d,h,A,1)]:Co(r,l,d,h,A,I)),N})}function gE(n){return pE(mE,n)}function mE(n,e,t,r,l,d){const h=n.length;if(h<2)return null;const b=new Path2D;if(t(b,n[0],e[0]),h==2)r(b,n[1],e[1]);else{let p=Array(h),g=Array(h-1),o=Array(h-1),c=Array(h-1);for(let f=0;f<h-1;f++)o[f]=e[f+1]-e[f],c[f]=n[f+1]-n[f],g[f]=o[f]/c[f];p[0]=g[0];for(let f=1;f<h-1;f++)g[f]===0||g[f-1]===0||g[f-1]>0!=g[f]>0?p[f]=0:(p[f]=3*(c[f-1]+c[f])/((2*c[f]+c[f-1])/g[f-1]+(c[f]+2*c[f-1])/g[f]),isFinite(p[f])||(p[f]=0));p[h-1]=g[h-2];for(let f=0;f<h-1;f++)l(b,n[f]+c[f]/3,e[f]+p[f]*c[f]/3,n[f+1]-c[f]/3,e[f+1]-p[f+1]*c[f]/3,n[f+1],e[f+1])}return b}const dd=new Set;function by(){for(let n of dd)n.syncRect(!0)}va&&(Ms(X$,ya,by),Ms(Q$,ya,by,!0),Ms($c,ya,()=>{Sr.pxRatio=Kt}));const vE=vy(),yE=gy();function wy(n,e,t,r){return(r?[n[0],n[1]].concat(n.slice(2)):[n[0]].concat(n.slice(1))).map((l,d)=>fd(l,d,e,t))}function bE(n,e){return n.map((t,r)=>r==0?{}:Gn({},e,t))}function fd(n,e,t,r){return Gn({},e==0?t:r,n)}function xy(n,e,t){return e==null?wa:[e,t]}const wE=xy;function xE(n,e,t){return e==null?wa:Rc(e,t,Gh,!0)}function ky(n,e,t,r){return e==null?wa:Tc(e,t,n.scales[r].log,!1)}const kE=ky;function Sy(n,e,t,r){return e==null?wa:Kh(e,t,n.scales[r].log,!1)}const SE=Sy;function _E(n,e,t,r,l){let d=Dr(bv(n),bv(e)),h=e-n,b=Hi(l/r*h,t);do{let p=t[b],g=r*p/h;if(g>=l&&d+(p<5?Qo.get(p):0)<=17)return[p,g]}while(++b<t.length);return[0,0]}function _y(n){let e,t;return n=n.replace(/(\d+)px/,(r,l)=>(e=rr((t=+l)*Kt))+"px"),[n,e,t]}function CE(n){n.show&&[n.font,n.labelFont].forEach(e=>{let t=cn(e[2]*Kt,1);e[0]=e[0].replace(/[0-9.]+px/,t+"px"),e[1]=t})}function Sr(n,e,t){const r={mode:Ut(n.mode,1)},l=r.mode;function d(q,X,ie,oe){let pe=X.valToPct(q);return oe+ie*(X.dir==-1?1-pe:pe)}function h(q,X,ie,oe){let pe=X.valToPct(q);return oe+ie*(X.dir==-1?pe:1-pe)}function b(q,X,ie,oe){return X.ori==0?d(q,X,ie,oe):h(q,X,ie,oe)}r.valToPosH=d,r.valToPosV=h;let p=!1;r.status=0;const g=r.root=Si(L$);if(n.id!=null&&(g.id=n.id),li(g,n.class),n.title){let q=Si(N$,g);q.textContent=n.title}const o=zi("canvas"),c=r.ctx=o.getContext("2d"),f=Si(D$,g);Ms("click",f,q=>{q.target===i&&(Xt!=Ei||Pt!=bo)&&Rn.click(r,q)},!0);const u=r.under=Si(F$,f);f.appendChild(o);const i=r.over=Si(P$,f);n=xa(n);const a=+Ut(n.pxAlign,1),m=cy(a);(n.plugins||[]).forEach(q=>{q.opts&&(n=q.opts(r,n)||n)});const w=n.ms||.001,x=r.series=l==1?wy(n.series||[],Zv,oy,!1):bE(n.series||[null],iy),M=r.axes=wy(n.axes||[],Qv,ty,!0),$=r.scales={},S=r.bands=n.bands||[];S.forEach(q=>{q.fill=Dt(q.fill||null),q.dir=Ut(q.dir,-1)});const k=l==2?x[1].facets[0].scale:x[0].scale,T={axes:Lo,series:Da},D=(n.drawOrder||["axes","series"]).map(q=>T[q]);function L(q){const X=q.distr==3?ie=>_o(ie>0?ie:q.clamp(r,ie,q.min,q.max,q.key)):q.distr==4?ie=>Xh(ie,q.asinh):q.distr==100?ie=>q.fwd(ie):ie=>ie;return ie=>{let oe=X(ie),{_min:pe,_max:we}=q,Re=we-pe;return(oe-pe)/Re}}function O(q){let X=$[q];if(X==null){let ie=(n.scales||ml)[q]||ml;if(ie.from!=null){O(ie.from);let oe=Gn({},$[ie.from],ie,{key:q});oe.valToPct=L(oe),$[q]=oe}else{X=$[q]=Gn({},q==k?sy:aE,ie),X.key=q;let oe=X.time,pe=X.range,we=Zo(pe);if((q!=k||l==2&&!oe)&&(we&&(pe[0]==null||pe[1]==null)&&(pe={min:pe[0]==null?gv:{mode:1,hard:pe[0],soft:pe[0]},max:pe[1]==null?gv:{mode:1,hard:pe[1],soft:pe[1]}},we=!1),!we&&Oc(pe))){let Re=pe;pe=(Pe,je,Ue)=>je==null?wa:Rc(je,Ue,Re)}X.range=Dt(pe||(oe?wE:q==k?X.distr==3?kE:X.distr==4?SE:xy:X.distr==3?ky:X.distr==4?Sy:xE)),X.auto=Dt(we?!1:X.auto),X.clamp=Dt(X.clamp||sE),X._min=X._max=null,X.valToPct=L(X)}}}O("x"),O("y"),l==1&&x.forEach(q=>{O(q.scale)}),M.forEach(q=>{O(q.scale)});for(let q in n.scales)O(q);const z=$[k],P=z.distr;let N,A;z.ori==0?(li(g,O$),N=d,A=h):(li(g,I$),N=h,A=d);const _={};for(let q in $){let X=$[q];(X.min!=null||X.max!=null)&&(_[q]={min:X.min,max:X.max},X.min=X.max=null)}const I=n.tzDate||(q=>new Date(rr(q/w))),j=n.fmtDate||Jh,U=w==1?OA(I):DA(I),K=Hv(I,zv(w==1?LA:NA,j)),Z=qv(I,Uv(PA,j)),J=[],ae=r.legend=Gn({},WA,n.legend),ne=r.cursor=Gn({},KA,{drag:{y:l==2}},n.cursor),se=ae.show,ce=ne.show,he=ae.markers;ae.idxs=J,he.width=Dt(he.width),he.dash=Dt(he.dash),he.stroke=Dt(he.stroke),he.fill=Dt(he.fill);let ge,Ee,Te,Me=[],Xe=[],Ke,dt=!1,rt={};if(ae.live){const q=x[1]?x[1].values:null;dt=q!=null,Ke=dt?q(r,1,0):{_:0};for(let X in Ke)rt[X]=Wh}if(se)if(ge=zi("table",U$,g),Te=zi("tbody",null,ge),ae.mount(r,ge),dt){Ee=zi("thead",null,ge,Te);let q=zi("tr",null,Ee);zi("th",null,q);for(var gt in Ke)zi("th",Jm,q).textContent=gt}else li(ge,V$),ae.live&&li(ge,q$);const tn={show:!0},jn={show:!1};function Zt(q,X){if(X==0&&(dt||!ae.live||l==2))return wa;let ie=[],oe=zi("tr",K$,Te,Te.childNodes[X]);li(oe,q.class),q.show||li(oe,Rs);let pe=zi("th",null,oe);if(he.show){let Pe=Si(G$,pe);if(X>0){let je=he.width(r,X);je&&(Pe.style.border=je+"px "+he.dash(r,X)+" "+he.stroke(r,X)),Pe.style.background=he.fill(r,X)}}let we=Si(Jm,pe);q.label instanceof HTMLElement?we.appendChild(q.label):we.textContent=q.label,X>0&&(he.show||(we.style.color=q.width>0?he.stroke(r,X):he.fill(r,X)),kn("click",pe,Pe=>{if(ne._lock)return;Xi(Pe);let je=x.indexOf(q);if((Pe.ctrlKey||Pe.metaKey)!=ae.isolate){let Ue=x.some((Ge,Qe)=>Qe>0&&Qe!=je&&Ge.show);x.forEach((Ge,Qe)=>{Qe>0&&Wr(Qe,Ue?Qe==je?tn:jn:tn,!0,lt.setSeries)})}else Wr(je,{show:!q.show},!0,lt.setSeries)},!1),Qi&&kn(rv,pe,Pe=>{ne._lock||(Xi(Pe),Wr(x.indexOf(q),Mi,!0,lt.setSeries))},!1));for(var Re in Ke){let Pe=zi("td",Y$,oe);Pe.textContent="--",ie.push(Pe)}return[oe,ie]}const hi=new Map;function kn(q,X,ie,oe=!0){const pe=hi.get(X)||{},we=ne.bind[q](r,X,ie,oe);we&&(Ms(q,X,pe[q]=we),hi.set(X,pe))}function Xn(q,X,ie){const oe=hi.get(X)||{};for(let pe in oe)(q==null||pe==q)&&(Vh(pe,X,oe[pe]),delete oe[pe]);q==null&&hi.delete(X)}let ur=0,Pr=0,yt=0,qe=0,qt=0,gn=0,Qn=qt,Br=gn,$r=yt,Sn=qe,ir=0,hr=0,nn=0,or=0;r.bbox={};let $o=!1,Ki=!1,Gi=!1,Yi=!1,Ao=!1,vr=!1;function Eo(q,X,ie){(ie||q!=r.width||X!=r.height)&&Jo(q,X),to(!1),Gi=!0,Ki=!0,yo()}function Jo(q,X){r.width=ur=yt=q,r.height=Pr=qe=X,qt=gn=0,zs(),Oa();let ie=r.bbox;ir=ie.left=Os(qt*Kt,.5),hr=ie.top=Os(gn*Kt,.5),nn=ie.width=Os(yt*Kt,.5),or=ie.height=Os(qe*Kt,.5)}const Rl=3;function di(){let q=!1,X=0;for(;!q;){X++;let ie=Fa(X),oe=Il(X);q=X==Rl||ie&&oe,q||(Jo(r.width,r.height),Ki=!0)}}function Ml({width:q,height:X}){Eo(q,X)}r.setSize=Ml;function zs(){let q=!1,X=!1,ie=!1,oe=!1;M.forEach((pe,we)=>{if(pe.show&&pe._show){let{side:Re,_size:Pe}=pe,je=Re%2,Ue=pe.label!=null?pe.labelSize:0,Ge=Pe+Ue;Ge>0&&(je?(yt-=Ge,Re==3?(qt+=Ge,oe=!0):ie=!0):(qe-=Ge,Re==0?(gn+=Ge,q=!0):X=!0))}}),Ji[0]=q,Ji[1]=ie,Ji[2]=X,Ji[3]=oe,yt-=Tr[1]+Tr[3],qt+=Tr[3],qe-=Tr[2]+Tr[0],gn+=Tr[0]}function Oa(){let q=qt+yt,X=gn+qe,ie=qt,oe=gn;function pe(we,Re){switch(we){case 1:return q+=Re,q-Re;case 2:return X+=Re,X-Re;case 3:return ie-=Re,ie+Re;case 0:return oe-=Re,oe+Re}}M.forEach((we,Re)=>{if(we.show&&we._show){let Pe=we.side;we._pos=pe(Pe,we._size),we.label!=null&&(we._lpos=pe(Pe,we.labelSize))}})}if(ne.dataIdx==null){let q=ne.hover,X=q.skip=new Set(q.skip??[]);X.add(void 0);let ie=q.prox=Dt(q.prox),oe=q.bias??(q.bias=0);ne.dataIdx=(pe,we,Re,Pe)=>{if(we==0)return Re;let je=Re,Ue=ie(pe,we,Re,Pe)??ln,Ge=Ue>=0&&Ue<ln,Qe=z.ori==0?yt:qe,vt=ne.left,It=e[0],wt=e[we];if(X.has(wt[Re])){je=null;let Mt=null,ut=null,it;if(oe==0||oe==-1)for(it=Re;Mt==null&&it-- >0;)X.has(wt[it])||(Mt=it);if(oe==0||oe==1)for(it=Re;ut==null&&it++<wt.length;)X.has(wt[it])||(ut=it);if(Mt!=null||ut!=null)if(Ge){let un=Mt==null?-1/0:N(It[Mt],z,Qe,0),wn=ut==null?1/0:N(It[ut],z,Qe,0),er=vt-un,jt=wn-vt;er<=jt?er<=Ue&&(je=Mt):jt<=Ue&&(je=ut)}else je=ut==null?Mt:Mt==null?ut:Re-Mt<=ut-Re?Mt:ut}else Ge&&nr(vt-N(It[Re],z,Qe,0))>Ue&&(je=null);return je}}const Xi=q=>{ne.event=q};ne.idxs=J,ne._lock=!1;let Wn=ne.points;Wn.show=Dt(Wn.show),Wn.size=Dt(Wn.size),Wn.stroke=Dt(Wn.stroke),Wn.width=Dt(Wn.width),Wn.fill=Dt(Wn.fill);const Ar=r.focus=Gn({},n.focus||{alpha:.3},ne.focus),Qi=Ar.prox>=0,_n=Qi&&Wn.one;let Er=[],po=[],Zi=[];function Hs(q,X){let ie=Wn.show(r,X);if(ie instanceof HTMLElement)return li(ie,H$),li(ie,q.class),lo(ie,-10,-10,yt,qe),i.insertBefore(ie,Er[X]),ie}function Ia(q,X){if(l==1||X>0){let ie=l==1&&$[q.scale].time,oe=q.value;q.value=ie?Ev(oe)?qv(I,Uv(oe,j)):oe||Z:oe||rE,q.label=q.label||(ie?YA:GA)}if(_n||X>0){q.width=q.width==null?1:q.width,q.paths=q.paths||vE||aA,q.fillTo=Dt(q.fillTo||lE),q.pxAlign=+Ut(q.pxAlign,a),q.pxRound=cy(q.pxAlign),q.stroke=Dt(q.stroke||null),q.fill=Dt(q.fill||null),q._stroke=q._fill=q._paths=q._focus=null;let ie=iE(Dr(1,q.width),1),oe=q.points=Gn({},{size:ie,width:Dr(1,ie*.2),stroke:q.stroke,space:ie*2,paths:yE,_stroke:null,_fill:null},q.points);oe.show=Dt(oe.show),oe.filter=Dt(oe.filter),oe.fill=Dt(oe.fill),oe.stroke=Dt(oe.stroke),oe.paths=Dt(oe.paths),oe.pxAlign=q.pxAlign}if(se){let ie=Zt(q,X);Me.splice(X,0,ie[0]),Xe.splice(X,0,ie[1]),ae.values.push(null)}if(ce){J.splice(X,0,null);let ie=null;_n?X==0&&(ie=Hs(q,X)):X>0&&(ie=Hs(q,X)),Er.splice(X,0,ie),po.splice(X,0,0),Zi.splice(X,0,0)}tt("addSeries",X)}function Ll(q,X){X=X??x.length,q=l==1?fd(q,X,Zv,oy):fd(q,X,{},iy),x.splice(X,0,q),Ia(x[X],X)}r.addSeries=Ll;function Ol(q){if(x.splice(q,1),se){ae.values.splice(q,1),Xe.splice(q,1);let X=Me.splice(q,1)[0];Xn(null,X.firstChild),X.remove()}ce&&(J.splice(q,1),Er.splice(q,1)[0].remove(),po.splice(q,1),Zi.splice(q,1)),tt("delSeries",q)}r.delSeries=Ol;const Ji=[!1,!1,!1,!1];function fi(q,X){if(q._show=q.show,q.show){let ie=q.side%2,oe=$[q.scale];oe==null&&(q.scale=ie?x[1].scale:k,oe=$[q.scale]);let pe=oe.time;q.size=Dt(q.size),q.space=Dt(q.space),q.rotate=Dt(q.rotate),Zo(q.incrs)&&q.incrs.forEach(Re=>{!Qo.has(Re)&&Qo.set(Re,$v(Re))}),q.incrs=Dt(q.incrs||(oe.distr==2?TA:pe?w==1?MA:IA:Is)),q.splits=Dt(q.splits||(pe&&oe.distr==1?U:oe.distr==3?sd:oe.distr==4?ZA:QA)),q.stroke=Dt(q.stroke),q.grid.stroke=Dt(q.grid.stroke),q.ticks.stroke=Dt(q.ticks.stroke),q.border.stroke=Dt(q.border.stroke);let we=q.values;q.values=Zo(we)&&!Zo(we[0])?Dt(we):pe?Zo(we)?Hv(I,zv(we,j)):Ev(we)?FA(I,we):we||K:we||XA,q.filter=Dt(q.filter||(oe.distr>=3&&oe.log==10?tE:oe.distr==3&&oe.log==2?nE:kv)),q.font=_y(q.font),q.labelFont=_y(q.labelFont),q._size=q.size(r,null,X,0),q._space=q._rotate=q._incrs=q._found=q._splits=q._values=null,q._size>0&&(Ji[X]=!0,q._el=Si(B$,f))}}function Ft(q,X,ie,oe){let[pe,we,Re,Pe]=ie,je=X%2,Ue=0;return je==0&&(Pe||we)&&(Ue=X==0&&!pe||X==2&&!Re?rr(Qv.size/3):0),je==1&&(pe||Re)&&(Ue=X==1&&!we||X==3&&!Pe?rr(ty.size/2):0),Ue}const Na=r.padding=(n.padding||[Ft,Ft,Ft,Ft]).map(q=>Dt(Ut(q,Ft))),Tr=r._padding=Na.map((q,X)=>q(r,X,Ji,0));let zn,hn=null,Tn=null;const Ci=l==1?x[0].idxs:null;let Rr=null,$i=!1;function es(q,X){if(e=q??[],r.data=r._data=e,l==2){zn=0;for(let ie=1;ie<x.length;ie++)zn+=e[ie][0].length}else{e.length==0&&(r.data=r._data=e=[[]]),Rr=e[0],zn=Rr.length;let ie=e;if(P==2){ie=e.slice();let oe=ie[0]=Array(zn);for(let pe=0;pe<zn;pe++)oe[pe]=pe}r._data=e=ie}if(to(!0),tt("setData"),P==2&&(Gi=!0),X!==!1){let ie=z;ie.auto(r,$i)?Us():Zn(k,ie.min,ie.max),Yi=Yi||ne.left>=0,vr=!0,yo()}}r.setData=es;function Us(){$i=!0;let q,X;l==1&&(zn>0?(hn=Ci[0]=0,Tn=Ci[1]=zn-1,q=e[0][hn],X=e[0][Tn],P==2?(q=hn,X=Tn):q==X&&(P==3?[q,X]=Tc(q,q,z.log,!1):P==4?[q,X]=Kh(q,q,z.log,!1):z.time?X=q+rr(86400/w):[q,X]=Rc(q,X,Gh,!0))):(hn=Ci[0]=q=null,Tn=Ci[1]=X=null)),Zn(k,q,X)}let go,ti,To,ts,ni,ns,qs,Vs,rs,sr;function Ks(q,X,ie,oe,pe,we){q??(q=tv),ie??(ie=Zh),oe??(oe="butt"),pe??(pe=tv),we??(we="round"),q!=go&&(c.strokeStyle=go=q),pe!=ti&&(c.fillStyle=ti=pe),X!=To&&(c.lineWidth=To=X),we!=ni&&(c.lineJoin=ni=we),oe!=ns&&(c.lineCap=ns=oe),ie!=ts&&c.setLineDash(ts=ie)}function Ro(q,X,ie,oe){X!=ti&&(c.fillStyle=ti=X),q!=qs&&(c.font=qs=q),ie!=Vs&&(c.textAlign=Vs=ie),oe!=rs&&(c.textBaseline=rs=oe)}function is(q,X,ie,oe,pe=0){if(oe.length>0&&q.auto(r,$i)&&(X==null||X.min==null)){let we=Ut(hn,0),Re=Ut(Tn,oe.length-1),Pe=ie.min==null?tA(oe,we,Re,pe,q.distr==3):[ie.min,ie.max];q.min=Ui(q.min,ie.min=Pe[0]),q.max=Dr(q.max,ie.max=Pe[1])}}const os={min:null,max:null};function mo(){for(let oe in $){let pe=$[oe];_[oe]==null&&(pe.min==null||_[k]!=null&&pe.auto(r,$i))&&(_[oe]=os)}for(let oe in $){let pe=$[oe];_[oe]==null&&pe.from!=null&&_[pe.from]!=null&&(_[oe]=os)}_[k]!=null&&to(!0);let q={};for(let oe in _){let pe=_[oe];if(pe!=null){let we=q[oe]=xa($[oe],uA);if(pe.min!=null)Gn(we,pe);else if(oe!=k||l==2)if(zn==0&&we.from==null){let Re=we.range(r,null,null,oe);we.min=Re[0],we.max=Re[1]}else we.min=ln,we.max=-ln}}if(zn>0){x.forEach((oe,pe)=>{if(l==1){let we=oe.scale,Re=_[we];if(Re==null)return;let Pe=q[we];if(pe==0){let je=Pe.range(r,Pe.min,Pe.max,we);Pe.min=je[0],Pe.max=je[1],hn=Hi(Pe.min,e[0]),Tn=Hi(Pe.max,e[0]),Tn-hn>1&&(e[0][hn]<Pe.min&&hn++,e[0][Tn]>Pe.max&&Tn--),oe.min=Rr[hn],oe.max=Rr[Tn]}else oe.show&&oe.auto&&is(Pe,Re,oe,e[pe],oe.sorted);oe.idxs[0]=hn,oe.idxs[1]=Tn}else if(pe>0&&oe.show&&oe.auto){let[we,Re]=oe.facets,Pe=we.scale,je=Re.scale,[Ue,Ge]=e[pe],Qe=q[Pe],vt=q[je];Qe!=null&&is(Qe,_[Pe],we,Ue,we.sorted),vt!=null&&is(vt,_[je],Re,Ge,Re.sorted),oe.min=Re.min,oe.max=Re.max}});for(let oe in q){let pe=q[oe],we=_[oe];if(pe.from==null&&(we==null||we.min==null)){let Re=pe.range(r,pe.min==ln?null:pe.min,pe.max==-ln?null:pe.max,oe);pe.min=Re[0],pe.max=Re[1]}}}for(let oe in q){let pe=q[oe];if(pe.from!=null){let we=q[pe.from];if(we.min==null)pe.min=pe.max=null;else{let Re=pe.range(r,we.min,we.max,oe);pe.min=Re[0],pe.max=Re[1]}}}let X={},ie=!1;for(let oe in q){let pe=q[oe],we=$[oe];if(we.min!=pe.min||we.max!=pe.max){we.min=pe.min,we.max=pe.max;let Re=we.distr;we._min=Re==3?_o(we.min):Re==4?Xh(we.min,we.asinh):Re==100?we.fwd(we.min):we.min,we._max=Re==3?_o(we.max):Re==4?Xh(we.max,we.asinh):Re==100?we.fwd(we.max):we.max,X[oe]=ie=!0}}if(ie){x.forEach((oe,pe)=>{l==2?pe>0&&X.y&&(oe._paths=null):X[oe.scale]&&(oe._paths=null)});for(let oe in X)Gi=!0,tt("setScale",oe);ce&&ne.left>=0&&(Yi=vr=!0)}for(let oe in _)_[oe]=null}function Gs(q){let X=Qh(hn-1,0,zn-1),ie=Qh(Tn+1,0,zn-1);for(;q[X]==null&&X>0;)X--;for(;q[ie]==null&&ie<zn-1;)ie++;return[X,ie]}function Da(){if(zn>0){let q=x.some(X=>X._focus)&&sr!=Ar.alpha;q&&(c.globalAlpha=sr=Ar.alpha),x.forEach((X,ie)=>{if(ie>0&&X.show&&(ss(ie,!1),ss(ie,!0),X._paths==null)){let oe=sr;sr!=X.alpha&&(c.globalAlpha=sr=X.alpha);let pe=l==2?[0,e[ie][0].length-1]:Gs(e[ie]);X._paths=X.paths(r,ie,pe[0],pe[1]),sr!=oe&&(c.globalAlpha=sr=oe)}}),x.forEach((X,ie)=>{if(ie>0&&X.show){let oe=sr;sr!=X.alpha&&(c.globalAlpha=sr=X.alpha),X._paths!=null&&as(ie,!1);{let pe=X._paths!=null?X._paths.gaps:null,we=X.points.show(r,ie,hn,Tn,pe),Re=X.points.filter(r,ie,we,pe);(we||Re)&&(X.points._paths=X.points.paths(r,ie,hn,Tn,Re),as(ie,!0))}sr!=oe&&(c.globalAlpha=sr=oe),tt("drawSeries",ie)}}),q&&(c.globalAlpha=sr=1)}}function ss(q,X){let ie=X?x[q].points:x[q];ie._stroke=ie.stroke(r,q),ie._fill=ie.fill(r,q)}function as(q,X){let ie=X?x[q].points:x[q],{stroke:oe,fill:pe,clip:we,flags:Re,_stroke:Pe=ie._stroke,_fill:je=ie._fill,_width:Ue=ie.width}=ie._paths;Ue=cn(Ue*Kt,3);let Ge=null,Qe=Ue%2/2;X&&je==null&&(je=Ue>0?"#fff":Pe);let vt=ie.pxAlign==1&&Qe>0;if(vt&&c.translate(Qe,Qe),!X){let It=ir-Ue/2,wt=hr-Ue/2,Mt=nn+Ue,ut=or+Ue;Ge=new Path2D,Ge.rect(It,wt,Mt,ut)}X?Mo(Pe,Ue,ie.dash,ie.cap,je,oe,pe,Re,we):Ys(q,Pe,Ue,ie.dash,ie.cap,je,oe,pe,Re,Ge,we),vt&&c.translate(-Qe,-Qe)}function Ys(q,X,ie,oe,pe,we,Re,Pe,je,Ue,Ge){let Qe=!1;je!=0&&S.forEach((vt,It)=>{if(vt.series[0]==q){let wt=x[vt.series[1]],Mt=e[vt.series[1]],ut=(wt._paths||ml).band;Zo(ut)&&(ut=vt.dir==1?ut[0]:ut[1]);let it,un=null;wt.show&&ut&&rA(Mt,hn,Tn)?(un=vt.fill(r,It)||we,it=wt._paths.clip):ut=null,Mo(X,ie,oe,pe,un,Re,Pe,je,Ue,Ge,it,ut),Qe=!0}}),Qe||Mo(X,ie,oe,pe,we,Re,Pe,je,Ue,Ge)}const ls=Sa|ld;function Mo(q,X,ie,oe,pe,we,Re,Pe,je,Ue,Ge,Qe){Ks(q,X,ie,oe,pe),(je||Ue||Qe)&&(c.save(),je&&c.clip(je),Ue&&c.clip(Ue)),Qe?(Pe&ls)==ls?(c.clip(Qe),Ge&&c.clip(Ge),ar(pe,Re),Ai(q,we,X)):Pe&ld?(ar(pe,Re),c.clip(Qe),Ai(q,we,X)):Pe&Sa&&(c.save(),c.clip(Qe),Ge&&c.clip(Ge),ar(pe,Re),c.restore(),Ai(q,we,X)):(ar(pe,Re),Ai(q,we,X)),(je||Ue||Qe)&&c.restore()}function Ai(q,X,ie){ie>0&&(X instanceof Map?X.forEach((oe,pe)=>{c.strokeStyle=go=pe,c.stroke(oe)}):X!=null&&q&&c.stroke(X))}function ar(q,X){X instanceof Map?X.forEach((ie,oe)=>{c.fillStyle=ti=oe,c.fill(ie)}):X!=null&&q&&c.fill(X)}function vo(q,X,ie,oe){let pe=M[q],we;if(oe<=0)we=[0,0];else{let Re=pe._space=pe.space(r,q,X,ie,oe),Pe=pe._incrs=pe.incrs(r,q,X,ie,oe,Re);we=_E(X,ie,Pe,oe,Re)}return pe._found=we}function eo(q,X,ie,oe,pe,we,Re,Pe,je,Ue){let Ge=Re%2/2;a==1&&c.translate(Ge,Ge),Ks(Pe,Re,je,Ue,Pe),c.beginPath();let Qe,vt,It,wt,Mt=pe+(oe==0||oe==3?-we:we);ie==0?(vt=pe,wt=Mt):(Qe=pe,It=Mt);for(let ut=0;ut<q.length;ut++)X[ut]!=null&&(ie==0?Qe=It=q[ut]:vt=wt=q[ut],c.moveTo(Qe,vt),c.lineTo(It,wt));c.stroke(),a==1&&c.translate(-Ge,-Ge)}function Fa(q){let X=!0;return M.forEach((ie,oe)=>{if(!ie.show)return;let pe=$[ie.scale];if(pe.min==null){ie._show&&(X=!1,ie._show=!1,to(!1));return}else ie._show||(X=!1,ie._show=!0,to(!1));let we=ie.side,Re=we%2,{min:Pe,max:je}=pe,[Ue,Ge]=vo(oe,Pe,je,Re==0?yt:qe);if(Ge==0)return;let Qe=pe.distr==2,vt=ie._splits=ie.splits(r,oe,Pe,je,Ue,Ge,Qe),It=pe.distr==2?vt.map(it=>Rr[it]):vt,wt=pe.distr==2?Rr[vt[1]]-Rr[vt[0]]:Ue,Mt=ie._values=ie.values(r,ie.filter(r,It,oe,Ge,wt),oe,Ge,wt);ie._rotate=we==2?ie.rotate(r,Mt,oe,Ge):0;let ut=ie._size;ie._size=_i(ie.size(r,Mt,oe,q)),ut!=null&&ie._size!=ut&&(X=!1)}),X}function Il(q){let X=!0;return Na.forEach((ie,oe)=>{let pe=ie(r,oe,Ji,q);pe!=Tr[oe]&&(X=!1),Tr[oe]=pe}),X}function Lo(){for(let q=0;q<M.length;q++){let X=M[q];if(!X.show||!X._show)continue;let ie=X.side,oe=ie%2,pe,we,Re=X.stroke(r,q),Pe=ie==0||ie==3?-1:1,[je,Ue]=X._found;if(X.label!=null){let sn=X.labelGap*Pe,gr=rr((X._lpos+sn)*Kt);Ro(X.labelFont[0],Re,"center",ie==2?fl:ev),c.save(),oe==1?(pe=we=0,c.translate(gr,rr(hr+or/2)),c.rotate((ie==3?-Mc:Mc)/2)):(pe=rr(ir+nn/2),we=gr);let Fo=wv(X.label)?X.label(r,q,je,Ue):X.label;c.fillText(Fo,pe,we),c.restore()}if(Ue==0)continue;let Ge=$[X.scale],Qe=oe==0?nn:or,vt=oe==0?ir:hr,It=X._splits,wt=Ge.distr==2?It.map(sn=>Rr[sn]):It,Mt=Ge.distr==2?Rr[It[1]]-Rr[It[0]]:je,ut=X.ticks,it=X.border,un=ut.show?ut.size:0,wn=rr(un*Kt),er=rr((X.alignTo==2?X._size-un-X.gap:X.gap)*Kt),jt=X._rotate*-Mc/180,fe=m(X._pos*Kt),Ae=(wn+er)*Pe,xe=fe+Ae;we=oe==0?xe:0,pe=oe==1?xe:0;let ze=X.font[0],ct=X.align==1?ma:X.align==2?Fh:jt>0?ma:jt<0?Fh:oe==0?"center":ie==3?Fh:ma,At=jt||oe==1?"middle":ie==2?fl:ev;Ro(ze,Re,ct,At);let Ht=X.font[1]*X.lineGap,Tt=It.map(sn=>m(b(sn,Ge,Qe,vt))),zr=X._values;for(let sn=0;sn<zr.length;sn++){let gr=zr[sn];if(gr!=null){oe==0?pe=Tt[sn]:we=Tt[sn],gr=""+gr;let Fo=gr.indexOf(`
|
|
1496
|
+
`)==-1?[gr]:gr.split(/\n/gm);for(let On=0;On<Fo.length;On++){let Qs=Fo[On];jt?(c.save(),c.translate(pe,we+On*Ht),c.rotate(jt),c.fillText(Qs,0,0),c.restore()):c.fillText(Qs,pe,we+On*Ht)}}}ut.show&&eo(Tt,ut.filter(r,wt,q,Ue,Mt),oe,ie,fe,wn,cn(ut.width*Kt,3),ut.stroke(r,q),ut.dash,ut.cap);let Li=X.grid;Li.show&&eo(Tt,Li.filter(r,wt,q,Ue,Mt),oe,oe==0?2:1,oe==0?hr:ir,oe==0?or:nn,cn(Li.width*Kt,3),Li.stroke(r,q),Li.dash,Li.cap),it.show&&eo([fe],[1],oe==0?1:0,oe==0?1:2,oe==1?hr:ir,oe==1?or:nn,cn(it.width*Kt,3),it.stroke(r,q),it.dash,it.cap)}tt("drawAxes")}function to(q){x.forEach((X,ie)=>{ie>0&&(X._paths=null,q&&(l==1?(X.min=null,X.max=null):X.facets.forEach(oe=>{oe.min=null,oe.max=null})))})}let Oo=!1,cs=!1,Io=[];function Pa(){cs=!1;for(let q=0;q<Io.length;q++)tt(...Io[q]);Io.length=0}function yo(){Oo||(vA(Ba),Oo=!0)}function Be(q,X=!1){Oo=!0,cs=X,q(r),Ba(),X&&Io.length>0&&queueMicrotask(Pa)}r.batch=Be;function Ba(){if($o&&(mo(),$o=!1),Gi&&(di(),Gi=!1),Ki){if(pn(u,ma,qt),pn(u,fl,gn),pn(u,hl,yt),pn(u,dl,qe),pn(i,ma,qt),pn(i,fl,gn),pn(i,hl,yt),pn(i,dl,qe),pn(f,hl,ur),pn(f,dl,Pr),o.width=rr(ur*Kt),o.height=rr(Pr*Kt),M.forEach(({_el:q,_show:X,_size:ie,_pos:oe,side:pe})=>{if(q!=null)if(X){let we=pe===3||pe===0?ie:0,Re=pe%2==1;pn(q,Re?"left":"top",oe-we),pn(q,Re?"width":"height",ie),pn(q,Re?"top":"left",Re?gn:qt),pn(q,Re?"height":"width",Re?qe:yt),Uh(q,Rs)}else li(q,Rs)}),go=ti=To=ni=ns=qs=Vs=rs=ts=null,sr=1,B(!0),qt!=Qn||gn!=Br||yt!=$r||qe!=Sn){to(!1);let q=yt/$r,X=qe/Sn;if(ce&&!Yi&&ne.left>=0){ne.left*=q,ne.top*=X,pi&&lo(pi,rr(ne.left),0,yt,qe),Hn&&lo(Hn,0,rr(ne.top),yt,qe);for(let ie=0;ie<Er.length;ie++){let oe=Er[ie];oe!=null&&(po[ie]*=q,Zi[ie]*=X,lo(oe,_i(po[ie]),_i(Zi[ie]),yt,qe))}}if(mt.show&&!Ao&&mt.left>=0&&mt.width>0){mt.left*=q,mt.width*=q,mt.top*=X,mt.height*=X;for(let ie in Y)pn(jr,ie,mt[ie])}Qn=qt,Br=gn,$r=yt,Sn=qe}tt("setSize"),Ki=!1}ur>0&&Pr>0&&(c.clearRect(0,0,o.width,o.height),tt("drawClear"),D.forEach(q=>q()),tt("draw")),mt.show&&Ao&&(on(mt),Ao=!1),ce&&Yi&&(C(null,!0,!1),Yi=!1),ae.show&&ae.live&&vr&&(y(),vr=!1),p||(p=!0,r.status=1,tt("ready")),$i=!1,Oo=!1}r.redraw=(q,X)=>{Gi=X||!1,q!==!1?Zn(k,z.min,z.max):yo()};function De(q,X){let ie=$[q];if(ie.from==null){if(zn==0){let oe=ie.range(r,X.min,X.max,q);X.min=oe[0],X.max=oe[1]}if(X.min>X.max){let oe=X.min;X.min=X.max,X.max=oe}if(zn>1&&X.min!=null&&X.max!=null&&X.max-X.min<1e-16)return;q==k&&ie.distr==2&&zn>0&&(X.min=Hi(X.min,e[0]),X.max=Hi(X.max,e[0]),X.min==X.max&&X.max++),_[q]=X,$o=!0,yo()}}r.setScale=De;let Cn,No,pi,Hn,ja,Do,Ei,bo,Yt,Vt,Xt,Pt,Ti=!1;const Rn=ne.drag;let We=Rn.x,dn=Rn.y;ce&&(ne.x&&(Cn=Si(W$,i)),ne.y&&(No=Si(z$,i)),z.ori==0?(pi=Cn,Hn=No):(pi=No,Hn=Cn),Xt=ne.left,Pt=ne.top);const mt=r.select=Gn({show:!0,over:!0,left:0,width:0,top:0,height:0},n.select),jr=mt.show?Si(j$,mt.over?i:u):null;function on(q,X){if(mt.show){for(let ie in q)mt[ie]=q[ie],ie in Y&&pn(jr,ie,q[ie]);X!==!1&&tt("setSelect")}}r.setSelect=on;function mn(q){if(x[q].show)se&&Uh(Me[q],Rs);else if(se&&li(Me[q],Rs),ce){let X=_n?Er[0]:Er[q];X!=null&&lo(X,-10,-10,yt,qe)}}function Zn(q,X,ie){De(q,{min:X,max:ie})}function Wr(q,X,ie,oe){X.focus!=null&&dr(q),X.show!=null&&x.forEach((pe,we)=>{we>0&&(q==we||q==null)&&(pe.show=X.show,mn(we),l==2?(Zn(pe.facets[0].scale,null,null),Zn(pe.facets[1].scale,null,null)):Zn(pe.scale,null,null),yo())}),ie!==!1&&tt("setSeries",q,X),oe&&$t("setSeries",r,q,X)}r.setSeries=Wr;function Ri(q,X){Gn(S[q],X)}function Mn(q,X){q.fill=Dt(q.fill||null),q.dir=Ut(q.dir,-1),X=X??S.length,S.splice(X,0,q)}function ri(q){q==null?S.length=0:S.splice(q,1)}r.addBand=Mn,r.setBand=Ri,r.delBand=ri;function us(q,X){x[q].alpha=X,ce&&Er[q]!=null&&(Er[q].style.opacity=X),se&&Me[q]&&(Me[q].style.opacity=X)}let Ln,gi,mi;const Mi={focus:!0};function dr(q){if(q!=mi){let X=q==null,ie=Ar.alpha!=1;x.forEach((oe,pe)=>{if(l==1||pe>0){let we=X||pe==0||pe==q;oe._focus=X?null:we,ie&&us(pe,we?1:Ar.alpha)}}),mi=q,ie&&yo()}}se&&Qi&&kn(iv,ge,q=>{ne._lock||(Xi(q),mi!=null&&Wr(null,Mi,!0,lt.setSeries))});function fr(q,X,ie){let oe=$[X];ie&&(q=q/Kt-(oe.ori==1?gn:qt));let pe=yt;oe.ori==1&&(pe=qe,q=pe-q),oe.dir==-1&&(q=pe-q);let we=oe._min,Re=oe._max,Pe=q/pe,je=we+(Re-we)*Pe,Ue=oe.distr;return Ue==3?ba(10,je):Ue==4?oA(je,oe.asinh):Ue==100?oe.bwd(je):je}function yr(q,X){let ie=fr(q,k,X);return Hi(ie,e[0],hn,Tn)}r.valToIdx=q=>Hi(q,e[0]),r.posToIdx=yr,r.posToVal=fr,r.valToPos=(q,X,ie)=>$[X].ori==0?d(q,$[X],ie?nn:yt,ie?ir:0):h(q,$[X],ie?or:qe,ie?hr:0),r.setCursor=(q,X,ie)=>{Xt=q.left,Pt=q.top,C(null,X,ie)};function Xs(q,X){pn(jr,ma,mt.left=q),pn(jr,hl,mt.width=X)}function br(q,X){pn(jr,fl,mt.top=q),pn(jr,dl,mt.height=X)}let Mr=z.ori==0?Xs:br,vi=z.ori==1?Xs:br;function yi(){if(se&&ae.live)for(let q=l==2?1:0;q<x.length;q++){if(q==0&&dt)continue;let X=ae.values[q],ie=0;for(let oe in X)Xe[q][ie++].firstChild.nodeValue=X[oe]}}function y(q,X){if(q!=null&&(q.idxs?q.idxs.forEach((ie,oe)=>{J[oe]=ie}):cA(q.idx)||J.fill(q.idx),ae.idx=J[0]),se&&ae.live){for(let ie=0;ie<x.length;ie++)(ie>0||l==1&&!dt)&&E(ie,J[ie]);yi()}vr=!1,X!==!1&&tt("setLegend")}r.setLegend=y;function E(q,X){let ie=x[q],oe=q==0&&P==2?Rr:e[q],pe;dt?pe=ie.values(r,q,X)??rt:(pe=ie.value(r,X==null?null:oe[X],q,X),pe=pe==null?rt:{_:pe}),ae.values[q]=pe}function C(q,X,ie){Yt=Xt,Vt=Pt,[Xt,Pt]=ne.move(r,Xt,Pt),ne.left=Xt,ne.top=Pt,ce&&(pi&&lo(pi,rr(Xt),0,yt,qe),Hn&&lo(Hn,0,rr(Pt),yt,qe));let oe,pe=hn>Tn;Ln=ln,gi=null;let we=z.ori==0?yt:qe,Re=z.ori==1?yt:qe;if(Xt<0||zn==0||pe){oe=ne.idx=null;for(let Pe=0;Pe<x.length;Pe++){let je=Er[Pe];je!=null&&lo(je,-10,-10,yt,qe)}Qi&&Wr(null,Mi,!0,q==null&<.setSeries),ae.live&&(J.fill(oe),vr=!0)}else{let Pe,je,Ue;l==1&&(Pe=z.ori==0?Xt:Pt,je=fr(Pe,k),oe=ne.idx=Hi(je,e[0],hn,Tn),Ue=N(e[0][oe],z,we,0));let Ge=-10,Qe=-10,vt=0,It=0,wt=!0,Mt="",ut="";for(let it=l==2?1:0;it<x.length;it++){let un=x[it],wn=J[it],er=wn==null?null:l==1?e[it][wn]:e[it][1][wn],jt=ne.dataIdx(r,it,oe,je),fe=jt==null?null:l==1?e[it][jt]:e[it][1][jt];if(vr=vr||fe!=er||jt!=wn,J[it]=jt,it>0&&un.show){let Ae=jt==null?-10:jt==oe?Ue:N(l==1?e[0][jt]:e[it][0][jt],z,we,0),xe=fe==null?-10:A(fe,l==1?$[un.scale]:$[un.facets[1].scale],Re,0);if(Qi&&fe!=null){let ze=z.ori==1?Xt:Pt,ct=nr(Ar.dist(r,it,jt,xe,ze));if(ct<Ln){let At=Ar.bias;if(At!=0){let Ht=fr(ze,un.scale),Tt=fe>=0?1:-1,zr=Ht>=0?1:-1;zr==Tt&&(zr==1?At==1?fe>=Ht:fe<=Ht:At==1?fe<=Ht:fe>=Ht)&&(Ln=ct,gi=it)}else Ln=ct,gi=it}}if(vr||_n){let ze,ct;z.ori==0?(ze=Ae,ct=xe):(ze=xe,ct=Ae);let At,Ht,Tt,zr,Li,sn,gr=!0,Fo=Wn.bbox;if(Fo!=null){gr=!1;let On=Fo(r,it);Tt=On.left,zr=On.top,At=On.width,Ht=On.height}else Tt=ze,zr=ct,At=Ht=Wn.size(r,it);if(sn=Wn.fill(r,it),Li=Wn.stroke(r,it),_n)it==gi&&Ln<=Ar.prox&&(Ge=Tt,Qe=zr,vt=At,It=Ht,wt=gr,Mt=sn,ut=Li);else{let On=Er[it];On!=null&&(po[it]=Tt,Zi[it]=zr,hv(On,At,Ht,gr),cv(On,sn,Li),lo(On,_i(Tt),_i(zr),yt,qe))}}}}if(_n){let it=Ar.prox,un=mi==null?Ln<=it:Ln>it||gi!=mi;if(vr||un){let wn=Er[0];wn!=null&&(po[0]=Ge,Zi[0]=Qe,hv(wn,vt,It,wt),cv(wn,Mt,ut),lo(wn,_i(Ge),_i(Qe),yt,qe))}}}if(mt.show&&Ti)if(q!=null){let[Pe,je]=lt.scales,[Ue,Ge]=lt.match,[Qe,vt]=q.cursor.sync.scales,It=q.cursor.drag;if(We=It._x,dn=It._y,We||dn){let{left:wt,top:Mt,width:ut,height:it}=q.select,un=q.scales[Qe].ori,wn=q.posToVal,er,jt,fe,Ae,xe,ze=Pe!=null&&Ue(Pe,Qe),ct=je!=null&&Ge(je,vt);ze&&We?(un==0?(er=wt,jt=ut):(er=Mt,jt=it),fe=$[Pe],Ae=N(wn(er,Qe),fe,we,0),xe=N(wn(er+jt,Qe),fe,we,0),Mr(Ui(Ae,xe),nr(xe-Ae))):Mr(0,we),ct&&dn?(un==1?(er=wt,jt=ut):(er=Mt,jt=it),fe=$[je],Ae=A(wn(er,vt),fe,Re,0),xe=A(wn(er+jt,vt),fe,Re,0),vi(Ui(Ae,xe),nr(xe-Ae))):vi(0,Re)}else Q()}else{let Pe=nr(Yt-ja),je=nr(Vt-Do);if(z.ori==1){let vt=Pe;Pe=je,je=vt}We=Rn.x&&Pe>=Rn.dist,dn=Rn.y&&je>=Rn.dist;let Ue=Rn.uni;Ue!=null?We&&dn&&(We=Pe>=Ue,dn=je>=Ue,!We&&!dn&&(je>Pe?dn=!0:We=!0)):Rn.x&&Rn.y&&(We||dn)&&(We=dn=!0);let Ge,Qe;We&&(z.ori==0?(Ge=Ei,Qe=Xt):(Ge=bo,Qe=Pt),Mr(Ui(Ge,Qe),nr(Qe-Ge)),dn||vi(0,Re)),dn&&(z.ori==1?(Ge=Ei,Qe=Xt):(Ge=bo,Qe=Pt),vi(Ui(Ge,Qe),nr(Qe-Ge)),We||Mr(0,we)),!We&&!dn&&(Mr(0,0),vi(0,0))}if(Rn._x=We,Rn._y=dn,q==null){if(ie){if(yn!=null){let[Pe,je]=lt.scales;lt.values[0]=Pe!=null?fr(z.ori==0?Xt:Pt,Pe):null,lt.values[1]=je!=null?fr(z.ori==1?Xt:Pt,je):null}$t(Bh,r,Xt,Pt,yt,qe,oe)}if(Qi){let Pe=ie&<.setSeries,je=Ar.prox;mi==null?Ln<=je&&Wr(gi,Mi,!0,Pe):Ln>je?Wr(null,Mi,!0,Pe):gi!=mi&&Wr(gi,Mi,!0,Pe)}}vr&&(ae.idx=oe,y()),X!==!1&&tt("setCursor")}let F=null;Object.defineProperty(r,"rect",{get(){return F==null&&B(!1),F}});function B(q=!1){q?F=null:(F=i.getBoundingClientRect(),tt("syncRect",F))}function W(q,X,ie,oe,pe,we,Re){ne._lock||Ti&&q!=null&&q.movementX==0&&q.movementY==0||(V(q,X,ie,oe,pe,we,Re,!1,q!=null),q!=null?C(null,!0,!0):C(X,!0,!1))}function V(q,X,ie,oe,pe,we,Re,Pe,je){if(F==null&&B(!1),Xi(q),q!=null)ie=q.clientX-F.left,oe=q.clientY-F.top;else{if(ie<0||oe<0){Xt=-10,Pt=-10;return}let[Ue,Ge]=lt.scales,Qe=X.cursor.sync,[vt,It]=Qe.values,[wt,Mt]=Qe.scales,[ut,it]=lt.match,un=X.axes[0].side%2==1,wn=z.ori==0?yt:qe,er=z.ori==1?yt:qe,jt=un?we:pe,fe=un?pe:we,Ae=un?oe:ie,xe=un?ie:oe;if(wt!=null?ie=ut(Ue,wt)?b(vt,$[Ue],wn,0):-10:ie=wn*(Ae/jt),Mt!=null?oe=it(Ge,Mt)?b(It,$[Ge],er,0):-10:oe=er*(xe/fe),z.ori==1){let ze=ie;ie=oe,oe=ze}}je&&(X==null||X.cursor.event.type==Bh)&&((ie<=1||ie>=yt-1)&&(ie=Os(ie,yt)),(oe<=1||oe>=qe-1)&&(oe=Os(oe,qe))),Pe?(ja=ie,Do=oe,[Ei,bo]=ne.move(r,ie,oe)):(Xt=ie,Pt=oe)}const Y={width:0,height:0,left:0,top:0};function Q(){on(Y,!1)}let re,le,ye,ke;function me(q,X,ie,oe,pe,we,Re){Ti=!0,We=dn=Rn._x=Rn._y=!1,V(q,X,ie,oe,pe,we,Re,!0,!1),q!=null&&(kn(jh,zh,be,!1),$t(nv,r,Ei,bo,yt,qe,null));let{left:Pe,top:je,width:Ue,height:Ge}=mt;re=Pe,le=je,ye=Ue,ke=Ge}function be(q,X,ie,oe,pe,we,Re){Ti=Rn._x=Rn._y=!1,V(q,X,ie,oe,pe,we,Re,!1,!0);let{left:Pe,top:je,width:Ue,height:Ge}=mt,Qe=Ue>0||Ge>0,vt=re!=Pe||le!=je||ye!=Ue||ke!=Ge;if(Qe&&vt&&on(mt),Rn.setScale&&Qe&&vt){let It=Pe,wt=Ue,Mt=je,ut=Ge;if(z.ori==1&&(It=je,wt=Ge,Mt=Pe,ut=Ue),We&&Zn(k,fr(It,k),fr(It+wt,k)),dn)for(let it in $){let un=$[it];it!=k&&un.from==null&&un.min!=ln&&Zn(it,fr(Mt+ut,it),fr(Mt,it))}Q()}else ne.lock&&(ne._lock=!ne._lock,C(X,!0,q!=null));q!=null&&(Xn(jh,zh),$t(jh,r,Xt,Pt,yt,qe,null))}function Ne(q,X,ie,oe,pe,we,Re){if(ne._lock)return;Xi(q);let Pe=Ti;if(Ti){let je=!0,Ue=!0,Ge=10,Qe,vt;z.ori==0?(Qe=We,vt=dn):(Qe=dn,vt=We),Qe&&vt&&(je=Xt<=Ge||Xt>=yt-Ge,Ue=Pt<=Ge||Pt>=qe-Ge),Qe&&je&&(Xt=Xt<Ei?0:yt),vt&&Ue&&(Pt=Pt<bo?0:qe),C(null,!0,!0),Ti=!1}Xt=-10,Pt=-10,J.fill(null),C(null,!0,!0),Pe&&(Ti=Pe)}function Ie(q,X,ie,oe,pe,we,Re){ne._lock||(Xi(q),Us(),Q(),q!=null&&$t(ov,r,Xt,Pt,yt,qe,null))}function He(){M.forEach(CE),Eo(r.width,r.height,!0)}Ms($c,ya,He);const st={};st.mousedown=me,st.mousemove=W,st.mouseup=be,st.dblclick=Ie,st.setSeries=(q,X,ie,oe)=>{let pe=lt.match[2];ie=pe(r,X,ie),ie!=-1&&Wr(ie,oe,!0,!1)},ce&&(kn(nv,i,me),kn(Bh,i,W),kn(rv,i,q=>{Xi(q),B(!1)}),kn(iv,i,Ne),kn(ov,i,Ie),dd.add(r),r.syncRect=B);const Ye=r.hooks=n.hooks||{};function tt(q,X,ie){cs?Io.push([q,X,ie]):q in Ye&&Ye[q].forEach(oe=>{oe.call(null,r,X,ie)})}(n.plugins||[]).forEach(q=>{for(let X in q.hooks)Ye[X]=(Ye[X]||[]).concat(q.hooks[X])});const fn=(q,X,ie)=>ie,lt=Gn({key:null,setSeries:!1,filters:{pub:Sv,sub:Sv},scales:[k,x[1]?x[1].scale:null],match:[_v,_v,fn],values:[null,null]},ne.sync);lt.match.length==2&<.match.push(fn),ne.sync=lt;const yn=lt.key,bt=ly(yn);function $t(q,X,ie,oe,pe,we,Re){lt.filters.pub(q,X,ie,oe,pe,we,Re)&&bt.pub(q,X,ie,oe,pe,we,Re)}bt.sub(r);function Jn(q,X,ie,oe,pe,we,Re){lt.filters.sub(q,X,ie,oe,pe,we,Re)&&st[q](null,X,ie,oe,pe,we,Re)}r.pub=Jn;function pr(){bt.unsub(r),dd.delete(r),hi.clear(),Vh($c,ya,He),g.remove(),ge==null||ge.remove(),tt("destroy")}r.destroy=pr;function bn(){tt("init",n,e),es(e||n.data,!1),_[k]?De(k,_[k]):Us(),Ao=mt.show&&(mt.width>0||mt.height>0),Yi=vr=!0,Eo(n.width,n.height)}return x.forEach(Ia),M.forEach(fi),t?t instanceof HTMLElement?(t.appendChild(g),bn()):t(r,bn):bn(),r}Sr.assign=Gn,Sr.fmtNum=Yh,Sr.rangeNum=Rc,Sr.rangeLog=Tc,Sr.rangeAsinh=Kh,Sr.orient=Ns,Sr.pxRatio=Kt,Sr.join=mA,Sr.fmtDate=Jh,Sr.tzDate=AA,Sr.sync=ly;{Sr.addGap=cE,Sr.clipGaps=Fc;let n=Sr.paths={points:gy};n.linear=vy,n.stepped=dE,n.bars=fE,n.spline=gE}var Cy,$y;function $E(){return $y||($y=1,Cy=function(n,e,t,r,l){var d,h;if(r===void 0)r=0;else if(r=r|0,r<0||r>=n.length)throw new RangeError("invalid lower bound");if(l===void 0)l=n.length-1;else if(l=l|0,l<r||l>=n.length)throw new RangeError("invalid upper bound");for(;r<=l;)if(d=r+(l-r>>>1),h=+t(n[d],e,d,n),h<0)r=d+1;else if(h>0)l=d-1;else return d;return~r}),Cy}var AE=$E();const oj=Pi("a",lc(AE));var pd,Ay;function EE(){if(Ay)return pd;Ay=1;function n(e,t,r){var l=-1,d=e.length;t<0&&(t=-t>d?0:d+t),r=r>d?d:r,r<0&&(r+=d),d=t>r?0:r-t>>>0,t>>>=0;for(var h=Array(d);++l<d;)h[l]=e[l+t];return h}return pd=n,pd}var gd,Ey;function TE(){if(Ey)return gd;Ey=1;var n=EE();function e(t,r,l){var d=t.length;return l=l===void 0?d:l,!r&&l>=d?t:n(t,r,l)}return gd=e,gd}var md,Ty;function Ry(){if(Ty)return md;Ty=1;var n="\\ud800-\\udfff",e="\\u0300-\\u036f",t="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",l=e+t+r,d="\\ufe0e\\ufe0f",h="\\u200d",b=RegExp("["+h+n+l+d+"]");function p(g){return b.test(g)}return md=p,md}var vd,My;function RE(){if(My)return vd;My=1;function n(e){return e.split("")}return vd=n,vd}var yd,Ly;function ME(){if(Ly)return yd;Ly=1;var n="\\ud800-\\udfff",e="\\u0300-\\u036f",t="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",l=e+t+r,d="\\ufe0e\\ufe0f",h="["+n+"]",b="["+l+"]",p="\\ud83c[\\udffb-\\udfff]",g="(?:"+b+"|"+p+")",o="[^"+n+"]",c="(?:\\ud83c[\\udde6-\\uddff]){2}",f="[\\ud800-\\udbff][\\udc00-\\udfff]",u="\\u200d",i=g+"?",a="["+d+"]?",m="(?:"+u+"(?:"+[o,c,f].join("|")+")"+a+i+")*",w=a+i+m,x="(?:"+[o+b+"?",b,c,f,h].join("|")+")",M=RegExp(p+"(?="+p+")|"+x+w,"g");function $(S){return S.match(M)||[]}return yd=$,yd}var bd,Oy;function LE(){if(Oy)return bd;Oy=1;var n=RE(),e=Ry(),t=ME();function r(l){return e(l)?t(l):n(l)}return bd=r,bd}var wd,Iy;function OE(){if(Iy)return wd;Iy=1;var n=typeof Xo=="object"&&Xo&&Xo.Object===Object&&Xo;return wd=n,wd}var xd,Ny;function IE(){if(Ny)return xd;Ny=1;var n=OE(),e=typeof self=="object"&&self&&self.Object===Object&&self,t=n||e||Function("return this")();return xd=t,xd}var kd,Dy;function Sd(){if(Dy)return kd;Dy=1;var n=IE(),e=n.Symbol;return kd=e,kd}var _d,Fy;function NE(){if(Fy)return _d;Fy=1;function n(e,t){for(var r=-1,l=e==null?0:e.length,d=Array(l);++r<l;)d[r]=t(e[r],r,e);return d}return _d=n,_d}var Cd,Py;function DE(){if(Py)return Cd;Py=1;var n=Array.isArray;return Cd=n,Cd}var $d,By;function FE(){if(By)return $d;By=1;var n=Sd(),e=Object.prototype,t=e.hasOwnProperty,r=e.toString,l=n?n.toStringTag:void 0;function d(h){var b=t.call(h,l),p=h[l];try{h[l]=void 0;var g=!0}catch{}var o=r.call(h);return g&&(b?h[l]=p:delete h[l]),o}return $d=d,$d}var Ad,jy;function PE(){if(jy)return Ad;jy=1;var n=Object.prototype,e=n.toString;function t(r){return e.call(r)}return Ad=t,Ad}var Ed,Wy;function BE(){if(Wy)return Ed;Wy=1;var n=Sd(),e=FE(),t=PE(),r="[object Null]",l="[object Undefined]",d=n?n.toStringTag:void 0;function h(b){return b==null?b===void 0?l:r:d&&d in Object(b)?e(b):t(b)}return Ed=h,Ed}var Td,zy;function jE(){if(zy)return Td;zy=1;function n(e){return e!=null&&typeof e=="object"}return Td=n,Td}var Rd,Hy;function WE(){if(Hy)return Rd;Hy=1;var n=BE(),e=jE(),t="[object Symbol]";function r(l){return typeof l=="symbol"||e(l)&&n(l)==t}return Rd=r,Rd}var Md,Uy;function zE(){if(Uy)return Md;Uy=1;var n=Sd(),e=NE(),t=DE(),r=WE(),l=n?n.prototype:void 0,d=l?l.toString:void 0;function h(b){if(typeof b=="string")return b;if(t(b))return e(b,h)+"";if(r(b))return d?d.call(b):"";var p=b+"";return p=="0"&&1/b==-1/0?"-0":p}return Md=h,Md}var Ld,qy;function Wc(){if(qy)return Ld;qy=1;var n=zE();function e(t){return t==null?"":n(t)}return Ld=e,Ld}var Od,Vy;function HE(){if(Vy)return Od;Vy=1;var n=TE(),e=Ry(),t=LE(),r=Wc();function l(d){return function(h){h=r(h);var b=e(h)?t(h):void 0,p=b?b[0]:h.charAt(0),g=b?n(b,1).join(""):h.slice(1);return p[d]()+g}}return Od=l,Od}var Id,Ky;function Gy(){if(Ky)return Id;Ky=1;var n=HE(),e=n("toUpperCase");return Id=e,Id}var UE=Gy();const qE=lc(UE);var Nd,Yy;function VE(){if(Yy)return Nd;Yy=1;var n=Wc(),e=Gy();function t(r){return e(n(r).toLowerCase())}return Nd=t,Nd}var Dd,Xy;function KE(){if(Xy)return Dd;Xy=1;function n(e,t,r,l){var d=-1,h=e==null?0:e.length;for(l&&h&&(r=e[++d]);++d<h;)r=t(r,e[d],d,e);return r}return Dd=n,Dd}var Fd,Qy;function GE(){if(Qy)return Fd;Qy=1;function n(e){return function(t){return e==null?void 0:e[t]}}return Fd=n,Fd}var Pd,Zy;function YE(){if(Zy)return Pd;Zy=1;var n=GE(),e={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},t=n(e);return Pd=t,Pd}var Bd,Jy;function XE(){if(Jy)return Bd;Jy=1;var n=YE(),e=Wc(),t=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,r="\\u0300-\\u036f",l="\\ufe20-\\ufe2f",d="\\u20d0-\\u20ff",h=r+l+d,b="["+h+"]",p=RegExp(b,"g");function g(o){return o=e(o),o&&o.replace(t,n).replace(p,"")}return Bd=g,Bd}var jd,eb;function QE(){if(eb)return jd;eb=1;var n=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function e(t){return t.match(n)||[]}return jd=e,jd}var Wd,tb;function ZE(){if(tb)return Wd;tb=1;var n=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function e(t){return n.test(t)}return Wd=e,Wd}var zd,nb;function JE(){if(nb)return zd;nb=1;var n="\\ud800-\\udfff",e="\\u0300-\\u036f",t="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",l=e+t+r,d="\\u2700-\\u27bf",h="a-z\\xdf-\\xf6\\xf8-\\xff",b="\\xac\\xb1\\xd7\\xf7",p="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",g="\\u2000-\\u206f",o=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",c="A-Z\\xc0-\\xd6\\xd8-\\xde",f="\\ufe0e\\ufe0f",u=b+p+g+o,i="['’]",a="["+u+"]",m="["+l+"]",w="\\d+",x="["+d+"]",M="["+h+"]",$="[^"+n+u+w+d+h+c+"]",S="\\ud83c[\\udffb-\\udfff]",k="(?:"+m+"|"+S+")",T="[^"+n+"]",D="(?:\\ud83c[\\udde6-\\uddff]){2}",L="[\\ud800-\\udbff][\\udc00-\\udfff]",O="["+c+"]",z="\\u200d",P="(?:"+M+"|"+$+")",N="(?:"+O+"|"+$+")",A="(?:"+i+"(?:d|ll|m|re|s|t|ve))?",_="(?:"+i+"(?:D|LL|M|RE|S|T|VE))?",I=k+"?",j="["+f+"]?",U="(?:"+z+"(?:"+[T,D,L].join("|")+")"+j+I+")*",K="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Z="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",J=j+I+U,ae="(?:"+[x,D,L].join("|")+")"+J,ne=RegExp([O+"?"+M+"+"+A+"(?="+[a,O,"$"].join("|")+")",N+"+"+_+"(?="+[a,O+P,"$"].join("|")+")",O+"?"+P+"+"+A,O+"+"+_,Z,K,w,ae].join("|"),"g");function se(ce){return ce.match(ne)||[]}return zd=se,zd}var Hd,rb;function eT(){if(rb)return Hd;rb=1;var n=QE(),e=ZE(),t=Wc(),r=JE();function l(d,h,b){return d=t(d),h=b?void 0:h,h===void 0?e(d)?r(d):n(d):d.match(h)||[]}return Hd=l,Hd}var Ud,ib;function tT(){if(ib)return Ud;ib=1;var n=KE(),e=XE(),t=eT(),r="['’]",l=RegExp(r,"g");function d(h){return function(b){return n(t(e(b).replace(l,"")),h,"")}}return Ud=d,Ud}var qd,ob;function nT(){if(ob)return qd;ob=1;var n=VE(),e=tT(),t=e(function(r,l,d){return l=l.toLowerCase(),r+(d?n(l):l)});return qd=t,qd}var rT=nT();const iT=lc(rT),oT=Object.assign({"./ArrayWidget.vue":()=>ot(()=>at.import("./ArrayWidget-C59wpWWk-c29b423ae0d8262b2f0a.js"),void 0),"./ArrayplotWidget.vue":()=>ot(()=>at.import("./ArrayplotWidget-tKqIV461-b5499d34d939770ea784.js"),void 0),"./BlockWidget.vue":()=>ot(()=>at.import("./BlockWidget-BdlMR_1A-2fe67a604620baf681bb.js"),void 0),"./ButtonWidget.vue":()=>ot(()=>at.import("./ButtonWidget-C2JVmh3p-3a560b6aa04088e4573c.js"),void 0),"./CanvasWidget.vue":()=>ot(()=>at.import("./CanvasWidget-BRbdw1fu-4ba8bfc99930cac644a9.js"),void 0),"./CanvasdotWidget.vue":()=>ot(()=>at.import("./CanvasdotWidget-C8T_w03p-fd7ef4459bf342fc37fa.js"),void 0),"./CanvasimageWidget.vue":()=>ot(()=>at.import("./CanvasimageWidget-C1w2vSsG-4c0415ae1f856627e881.js"),void 0),"./CanvasimagevalueWidget.vue":()=>ot(()=>at.import("./CanvasimagevalueWidget-BMv2SmEq-1708540633c2cf544f63.js"),void 0),"./CanvaslabelWidget.vue":()=>ot(()=>at.import("./CanvaslabelWidget-LEBZQ3DR-13febb8d925636c6b249.js"),void 0),"./CanvaslabelvalueWidget.vue":()=>ot(()=>at.import("./CanvaslabelvalueWidget-Q6UdEanF-f775a32e761f967dd6fd.js"),void 0),"./CanvaslineWidget.vue":()=>ot(()=>at.import("./CanvaslineWidget-BhvBCDoS-e7c8904fc932aca8f668.js"),void 0),"./CanvaslinevalueWidget.vue":()=>ot(()=>at.import("./CanvaslinevalueWidget-EaASC9TU-e4374af5ec39128028f5.js"),void 0),"./CheckbuttonWidget.vue":()=>ot(()=>at.import("./CheckbuttonWidget-C3bjQwrp-2d8036a8c21d34f2abeb.js"),void 0),"./ComboboxWidget.vue":()=>ot(()=>at.import("./ComboboxWidget-CmruSbJy-f4cf90673018861cf481.js"),void 0),"./DateWidget.vue":()=>ot(()=>at.import("./DateWidget-CcUxRlJ2-8cce8aebe5541d7f0e90.js"),void 0),"./DynamicWidget.vue":()=>ot(()=>at.import("./DynamicWidget-DHL7pbgW-440606a95b21f754bf6e.js"),void 0),"./FormatvalueWidget.vue":()=>ot(()=>at.import("./FormatvalueWidget-Lk5K0wTL-db7245b0435a2517ab47.js"),void 0),"./HorizontalWidget.vue":()=>ot(()=>at.import("./HorizontalWidget-D3Q5IUQg-420b839020884c7c7e07.js"),void 0),"./HorizontalboxWidget.vue":()=>ot(()=>at.import("./HorizontalboxWidget-D7bUUqfG-8741d3deca1aed1b4431.js"),void 0),"./HorizontallineWidget.vue":()=>ot(()=>at.import("./HorizontallineWidget-DZcIetQh-60fb1bda60b18d799e32.js"),void 0),"./IframeWidget.vue":()=>ot(()=>at.import("./IframeWidget-Df7vTYZj-6c22de0cd801300c4f14.js"),void 0),"./ImageviewerWidget.vue":()=>ot(()=>at.import("./ImageviewerWidget-wHbhv08x-9650a0f5e234dc516aa0.js"),void 0),"./LabelWidget.vue":()=>ot(()=>at.import("./LabelWidget-BehwzOCR-26c050fdc9bbd572445f.js"),void 0),"./LabelledWidget.vue":()=>ot(()=>at.import("./LabelledWidget-DJKR8ikj-443ee356d5da714cdca2.js"),void 0),"./LabelprogressbarWidget.vue":()=>ot(()=>at.import("./LabelprogressbarWidget-D4Qzq894-728880b742e5832d041e.js"),void 0),"./LabelsparklineWidget.vue":()=>ot(()=>at.import("./LabelsparklineWidget-CwCOklZG-749b8d00a4735f6670be.js"),void 0),"./LabelvalueWidget.vue":()=>ot(()=>at.import("./LabelvalueWidget-DW8Q7BTX-a2e934f71c772a24a39f.js"),void 0),"./LabelvaluedescWidget.vue":()=>ot(()=>at.import("./LabelvaluedescWidget-DgNX7tK2-f0a007238371f0fb5f5b.js"),void 0),"./LabelvaluelimitsbarWidget.vue":()=>ot(()=>at.import("./LabelvaluelimitsbarWidget-DAEBW0hU-eda6f35727241e989e29.js"),void 0),"./LabelvaluelimitscolumnWidget.vue":()=>ot(()=>at.import("./LabelvaluelimitscolumnWidget-Dok-of6n-bd66c32eff88c32bd1d3.js"),void 0),"./LabelvaluerangebarWidget.vue":()=>ot(()=>at.import("./LabelvaluerangebarWidget-CQ0xCUFU-a5d35da52e8d36d1623f.js"),void 0),"./LedWidget.vue":()=>ot(()=>at.import("./LedWidget-DzQNEDF7-d37d23e6b6929ce92320.js"),void 0),"./LimitsbarWidget.vue":()=>ot(()=>at.import("./LimitsbarWidget-zkoAz9SQ-1eabbb0af56fc8c00067.js"),void 0),"./LimitscolorWidget.vue":()=>ot(()=>at.import("./LimitscolorWidget-dez316Rk-a0a22e420f93800e2a41.js"),void 0),"./LimitscolumnWidget.vue":()=>ot(()=>at.import("./LimitscolumnWidget-D-IPNDVg-7736aa68a84a0d3ff9d6.js"),void 0),"./LinegraphWidget.vue":()=>ot(()=>at.import("./LinegraphWidget-CicnZgjt-3af17e3f0ebc4706f047.js"),void 0),"./MatrixbycolumnsWidget.vue":()=>ot(()=>at.import("./MatrixbycolumnsWidget-D3qN6GTr-701b9edde6e2e974b630.js"),void 0),"./ProgressbarWidget.vue":()=>ot(()=>at.import("./ProgressbarWidget-CLilcPBe-bb665936f8d0042abf17.js"),void 0),"./RadiobuttonWidget.vue":()=>ot(()=>at.import("./RadiobuttonWidget-Dsy01RJ--87c221bf986287a5f52e.js"),void 0),"./RadiogroupWidget.vue":()=>ot(()=>at.import("./RadiogroupWidget-BNcVGNj1-f4eda7322a6ab05f613b.js"),void 0),"./RangebarWidget.vue":()=>ot(()=>at.import("./RangebarWidget-DhcoIdNf-b7dcc81f5c7d4886e69f.js"),void 0),"./RollupWidget.vue":()=>ot(()=>at.import("./RollupWidget-BypuPvE7-18a4f21aea29ec5c964f.js"),void 0),"./ScrollwindowWidget.vue":()=>ot(()=>at.import("./ScrollwindowWidget-DNQgHoNO-9da5b53e610fdec82a1e.js"),void 0),"./SignalWidget.vue":()=>ot(()=>at.import("./SignalWidget-BHwyScCG-19f5731f4747778e177e.js"),void 0),"./SpacerWidget.vue":()=>ot(()=>at.import("./SpacerWidget-CFxXXTm7-96909274c687e8c56a97.js"),void 0),"./SparklineWidget.vue":()=>ot(()=>at.import("./SparklineWidget-C0lRpRrp-e2aab2e51ee8ed9f2958.js"),void 0),"./TabbookWidget.vue":()=>ot(()=>at.import("./TabbookWidget-CeeBOYOt-2d84863ad653202184a0.js"),void 0),"./TextboxWidget.vue":()=>ot(()=>at.import("./TextboxWidget-DoA2b3YU-601d09a9adfcc39657d8.js"),void 0),"./TextfieldWidget.vue":()=>ot(()=>at.import("./TextfieldWidget-Dj4DV74o-b7a295018140a8b14709.js"),void 0),"./TimeWidget.vue":()=>ot(()=>at.import("./TimeWidget-DAQDQ0UM-d4213c64f9f64c553427.js"),void 0),"./TitleWidget.vue":()=>ot(()=>at.import("./TitleWidget-Ct0JlY9s-368213abe1d8b7a3440f.js"),void 0),"./ValueWidget.vue":()=>ot(()=>at.import("./ValueWidget-QaBYsiZz-809550055fb9541a8d5e.js"),void 0),"./ValuelimitsbarWidget.vue":()=>ot(()=>at.import("./ValuelimitsbarWidget-CFToRM7w-d42ceb8b66bc86d1bc27.js"),void 0),"./ValuelimitscolumnWidget.vue":()=>ot(()=>at.import("./ValuelimitscolumnWidget-BG7naMYx-5d5684b1d6f0aa5da261.js"),void 0),"./ValuerangebarWidget.vue":()=>ot(()=>at.import("./ValuerangebarWidget-CChK2Lmm-513caec4b39e8d9fc987.js"),void 0),"./VerticalWidget.vue":()=>ot(()=>at.import("./VerticalWidget-C8iN5DJK-1686c13b55184829b8f7.js"),void 0),"./VerticalboxWidget.vue":()=>ot(()=>at.import("./VerticalboxWidget-CXwUSWrP-727f58426e2529e9a06b.js"),void 0)}),sT=Object.entries(oT).reduce((n,[e,t])=>{e=e.split("/").pop();const r=qE(iT(e.replace(/\.\w+$/,"")));return{...n,[r]:wp(t)}},{}),sj=Pi("U",{components:sT}),aT={methods:{buildLanguageMode(n,e){let t=Nr.require("ace/lib/oop"),r=Object.getOwnPropertyNames(qm.prototype).filter(p=>p!=="constructor").filter(p=>p!=="exec").concat(["check","check_raw","check_formatted","check_with_units","check_exception","check_tolerance","check_expression","wait","wait_tolerance","wait_expression","wait_check","wait_check_tolerance","wait_check_expression","wait_packet","wait_check_packet","disable_instrumentation","set_line_delay","get_line_delay","set_max_output","get_max_output"]),l=new RegExp(`(\\b${r.join("\\b|\\b")}\\b)`),d=function(){n.call(this);for(let p in this.$rules)this.$rules[p].unshift({regex:l,token:"support.function"})};t.inherits(d,n);let h=Nr.require("ace/mode/matching_brace_outdent").MatchingBraceOutdent,b=Nr.require("ace/mode/behaviour/cstyle").CstyleBehaviour;return[t,function(){this.HighlightRules=d,this.$outdent=new h,this.$behaviour=new b,this.foldingRules=new e,this.indentKeywords=this.foldingRules.indentKeywords}]},buildRubyMode(){const[n,e]=this.buildLanguageMode(Nr.require("ace/mode/ruby_highlight_rules").RubyHighlightRules,Nr.require("ace/mode/folding/ruby").FoldMode);let t=Nr.require("ace/mode/ruby").Mode;return n.inherits(e,t),(function(){this.$id="ace/mode/openc3"}).call(e.prototype),e},buildPythonMode(){const[n,e]=this.buildLanguageMode(Nr.require("ace/mode/python_highlight_rules").PythonHighlightRules,Nr.require("ace/mode/folding/pythonic").FoldMode);let t=Nr.require("ace/mode/python").Mode;return n.inherits(e,t),(function(){this.$id="ace/mode/openc3"}).call(e.prototype),e},buildJsonMode(){const[n,e]=this.buildLanguageMode(Nr.require("ace/mode/json_highlight_rules").JsonHighlightRules,Nr.require("ace/mode/folding/ruby").FoldMode);let t=Nr.require("ace/mode/json").Mode;return n.inherits(e,t),(function(){this.$id="ace/mode/openc3"}).call(e.prototype),e},buildMarkdownMode(){const[n,e]=this.buildLanguageMode(Nr.require("ace/mode/markdown_highlight_rules").MarkdownHighlightRules,Nr.require("ace/mode/folding/markdown").FoldMode);let t=Nr.require("ace/mode/markdown").Mode;return n.inherits(e,t),(function(){this.$id="ace/mode/openc3"}).call(e.prototype),e}}},lT={mixins:[aT],props:{content:{type:String,required:!0},type:String,name:String,modelValue:Boolean,filename:{type:String,required:!1}},data(){return{editor:null,mode:null}},computed:{show:{get(){return this.modelValue},set(n){this.$emit("update:modelValue",n)}},title:function(){return`${this.type}: ${this.name}`}},mounted(){this.editor=ace.edit(this.$refs.editor),this.editor.setTheme("ace/theme/twilight");let n=null;switch(this.filename?this.filename.split(".").pop():"txt"){case"json":const e=this.buildJsonMode();n=new e,this.editor.setOptions({useWorker:!1});break;case"py":case"pyi":const t=this.buildPythonMode();n=new t;break;case"md":const r=this.buildMarkdownMode();n=new r;break;default:const l=this.buildRubyMode();n=new l;break}this.editor.session.setMode(n),this.editor.session.setUseWrapMode(!0),this.editor.$blockScrolling=1/0,this.editor.setHighlightActiveLine(!1),this.editor.setValue(this.content),this.editor.clearSelection(),this.editor.focus(),this.editor.setReadOnly(!0)},beforeUnmount(){this.editor&&this.editor.destroy()},methods:{close:function(){this.show=!this.show},download:function(){const n=new Blob([this.editor.getValue()],{type:"text/plain"});let e=`${this.type.toLowerCase()}_${this.name.toLowerCase()}.json`;this.filename&&(e=this.filename);const t=document.createElement("a");t.href=URL.createObjectURL(n),t.setAttribute("download",e),t.click()}}},cT=["textContent"],uT={class:"mx-2"},hT={ref:"editor",class:"editor"};function dT(n,e,t,r,l,d){const h=Ot("v-spacer"),b=Ot("v-btn"),p=Ot("v-toolbar"),g=Ot("v-card-text"),o=Ot("v-card-actions"),c=Ot("v-card"),f=Ot("v-dialog");return zt(),Vn(f,{modelValue:d.show,"onUpdate:modelValue":e[1]||(e[1]=u=>d.show=u),width:"85vw"},{default:Je(()=>[et(c,null,{default:Je(()=>[et(p,{height:"24"},{default:Je(()=>[et(h),cr("span",{textContent:Ir(d.title)},null,8,cT),et(h),cr("div",uT,[et(b,{icon:"mdi-download",variant:"text",density:"compact","data-test":"downloadIcon",onClick:d.download},null,8,["onClick"])])]),_:1}),et(g,null,{default:Je(()=>[cr("pre",hT,null,512)]),_:1}),et(o,{class:"pr-6 pb-4 pt-0"},{default:Je(()=>[et(h),et(b,{variant:"flat",onClick:e[0]||(e[0]=u=>d.show=!d.show)},{default:Je(()=>[...e[2]||(e[2]=[An(" Ok ",-1)])]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"])}const fT=Ku(lT,[["render",dT],["__scopeId","data-v-69e71dd8"]]),pT={props:{menus:{type:Array,default:function(){return[]}},title:{type:String,default:""}},methods:{formatDT:function(n){return n.replaceAll(" ","-").toLowerCase()},subMenuClick(n){n.command(n),this.$refs.topmenu[0].isActive=!1}},mounted(){document.title=this.title}},gT={class:"app-title mr-2"};function mT(n,e,t,r,l,d){const h=Ot("v-col"),b=Ot("v-row"),p=Ot("v-icon"),g=Ot("v-btn"),o=Ot("v-divider"),c=Ot("v-list-item-title"),f=Ot("v-list-item"),u=Ot("v-list"),i=Ot("v-menu"),a=Ot("v-radio"),m=Ot("v-list-item-action"),w=Ot("v-radio-group"),x=Ot("v-checkbox");return zt(),Vn(xp,{to:"#openc3-menu"},[et(b,{"no-gutters":""},{default:Je(()=>[et(h,{"align-self":"end"},{default:Je(()=>[cr("span",gT,Ir(t.title),1)]),_:1})]),_:1}),et(b,{dense:"",class:"flex-nowrap"},{default:Je(()=>[(zt(!0),Vr(So,null,Ko(t.menus,(M,$)=>(zt(),Vn(i,{ref_for:!0,ref:"topmenu",key:$},{activator:Je(({props:S})=>[et(g,Yu({ref_for:!0},S,{variant:"outlined",class:"mx-1 menu-button",text:M.label,"data-test":d.formatDT(`${t.title} ${M.label}`)}),{append:Je(()=>[et(p,{class:"menu-button-icon"},{default:Je(()=>[...e[0]||(e[0]=[An(" mdi-menu-down ",-1)])]),_:1})]),_:1},16,["text","data-test"])]),default:Je(()=>[et(u,null,{default:Je(()=>[(zt(!0),Vr(So,null,Ko(M.items,(S,k)=>(zt(),Vr(So,null,[S.divider?(zt(),Vn(o,{key:k+"-divider"})):S.subMenu&&S.subMenu.length>0?(zt(),Vr("div",{key:k+"-submenu"},[(zt(),Vn(i,{"open-on-hover":"",location:"right",key:k},{activator:Je(({props:T})=>[(zt(),Vn(f,Yu({ref_for:!0},T,{disabled:S.disabled,key:k}),Xu({append:Je(()=>[et(p,null,{default:Je(()=>[...e[1]||(e[1]=[An(" mdi-chevron-right ",-1)])]),_:1})]),default:Je(()=>[!S.radio&&!S.checkbox?(zt(),Vn(c,{key:0,style:Qu("cursor: pointer;"+(S.disabled?"opacity: 0.2":""))},{default:Je(()=>[An(Ir(S.label),1)]),_:2},1032,["style"])):oo("",!0)]),_:2},[S.icon?{name:"prepend",fn:Je(()=>[et(p,{disabled:S.disabled},{default:Je(()=>[An(Ir(S.icon),1)]),_:2},1032,["disabled"])]),key:"0"}:void 0]),1040,["disabled"]))]),default:Je(()=>[et(u,null,{default:Je(()=>[(zt(!0),Vr(So,null,Ko(S.subMenu,(T,D)=>(zt(),Vn(f,{key:D,"prepend-icon":T.icon,onClick:L=>d.subMenuClick(T)},{default:Je(()=>[et(c,null,{default:Je(()=>[An(Ir(T.label),1)]),_:2},1024)]),_:2},1032,["prepend-icon","onClick"]))),128))]),_:2},1024)]),_:2},1024))])):S.radioGroup?(zt(),Vn(w,{"model-value":S.value,"onUpdate:modelValue":S.command,key:k+"-radio-group","hide-details":"",density:"compact",class:"ma-0 pa-0"},{default:Je(()=>[(zt(!0),Vr(So,null,Ko(S.choices,(T,D)=>(zt(),Vn(f,{key:D+"-choice"},{default:Je(()=>[et(m,{class:"list-action"},{default:Je(()=>[et(a,{color:"secondary",label:T.label,value:T.value,density:"compact","hide-details":""},null,8,["label","value"])]),_:2},1024)]),_:2},1024))),128))]),_:2},1032,["model-value","onUpdate:modelValue"])):(zt(),Vn(f,{onClick:T=>S.command(S),disabled:S.disabled,"data-test":d.formatDT(`${t.title} ${M.label} ${S.label}`),key:k+"-list"},Xu({default:Je(()=>[S.checkbox?(zt(),Vn(m,{key:0,class:"list-action"},{default:Je(()=>[et(x,{modelValue:S.checked,"onUpdate:modelValue":T=>S.checked=T,label:S.label,color:"secondary",density:"compact","hide-details":""},null,8,["modelValue","onUpdate:modelValue","label"])]),_:2},1024)):oo("",!0),!S.radio&&!S.checkbox?(zt(),Vn(c,{key:1,style:Qu("cursor: pointer;"+(S.disabled?"opacity: 0.2":""))},{default:Je(()=>[An(Ir(S.label),1)]),_:2},1032,["style"])):oo("",!0)]),_:2},[S.icon?{name:"prepend",fn:Je(()=>[et(p,{icon:S.icon,disabled:S.disabled},null,8,["icon","disabled"])]),key:"0"}:void 0]),1032,["onClick","disabled","data-test"]))],64))),256))]),_:2},1024)]),_:2},1024))),128))]),_:1})])}const vT=Ku(pT,[["render",mT],["__scopeId","data-v-4d454b93"]]);function sb(n,e){return function(){return n.apply(e,arguments)}}const{toString:yT}=Object.prototype,{getPrototypeOf:Vd}=Object,{iterator:zc,toStringTag:ab}=Symbol,Hc=(n=>e=>{const t=yT.call(e);return n[t]||(n[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),qi=n=>(n=n.toLowerCase(),e=>Hc(e)===n),Uc=n=>e=>typeof e===n,{isArray:$a}=Array,Aa=Uc("undefined");function bl(n){return n!==null&&!Aa(n)&&n.constructor!==null&&!Aa(n.constructor)&&Qr(n.constructor.isBuffer)&&n.constructor.isBuffer(n)}const lb=qi("ArrayBuffer");function bT(n){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(n):e=n&&n.buffer&&lb(n.buffer),e}const wT=Uc("string"),Qr=Uc("function"),cb=Uc("number"),wl=n=>n!==null&&typeof n=="object",xT=n=>n===!0||n===!1,qc=n=>{if(Hc(n)!=="object")return!1;const e=Vd(n);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(ab in n)&&!(zc in n)},kT=n=>{if(!wl(n)||bl(n))return!1;try{return Object.keys(n).length===0&&Object.getPrototypeOf(n)===Object.prototype}catch{return!1}},ST=qi("Date"),_T=qi("File"),CT=qi("Blob"),$T=qi("FileList"),AT=n=>wl(n)&&Qr(n.pipe),ET=n=>{let e;return n&&(typeof FormData=="function"&&n instanceof FormData||Qr(n.append)&&((e=Hc(n))==="formdata"||e==="object"&&Qr(n.toString)&&n.toString()==="[object FormData]"))},TT=qi("URLSearchParams"),[RT,MT,LT,OT]=["ReadableStream","Request","Response","Headers"].map(qi),IT=n=>n.trim?n.trim():n.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function xl(n,e,{allOwnKeys:t=!1}={}){if(n===null||typeof n>"u")return;let r,l;if(typeof n!="object"&&(n=[n]),$a(n))for(r=0,l=n.length;r<l;r++)e.call(null,n[r],r,n);else{if(bl(n))return;const d=t?Object.getOwnPropertyNames(n):Object.keys(n),h=d.length;let b;for(r=0;r<h;r++)b=d[r],e.call(null,n[b],b,n)}}function ub(n,e){if(bl(n))return null;e=e.toLowerCase();const t=Object.keys(n);let r=t.length,l;for(;r-- >0;)if(l=t[r],e===l.toLowerCase())return l;return null}const Ds=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,hb=n=>!Aa(n)&&n!==Ds;function Kd(){const{caseless:n,skipUndefined:e}=hb(this)&&this||{},t={},r=(l,d)=>{const h=n&&ub(t,d)||d;qc(t[h])&&qc(l)?t[h]=Kd(t[h],l):qc(l)?t[h]=Kd({},l):$a(l)?t[h]=l.slice():(!e||!Aa(l))&&(t[h]=l)};for(let l=0,d=arguments.length;l<d;l++)arguments[l]&&xl(arguments[l],r);return t}const NT=(n,e,t,{allOwnKeys:r}={})=>(xl(e,(l,d)=>{t&&Qr(l)?n[d]=sb(l,t):n[d]=l},{allOwnKeys:r}),n),DT=n=>(n.charCodeAt(0)===65279&&(n=n.slice(1)),n),FT=(n,e,t,r)=>{n.prototype=Object.create(e.prototype,r),n.prototype.constructor=n,Object.defineProperty(n,"super",{value:e.prototype}),t&&Object.assign(n.prototype,t)},PT=(n,e,t,r)=>{let l,d,h;const b={};if(e=e||{},n==null)return e;do{for(l=Object.getOwnPropertyNames(n),d=l.length;d-- >0;)h=l[d],(!r||r(h,n,e))&&!b[h]&&(e[h]=n[h],b[h]=!0);n=t!==!1&&Vd(n)}while(n&&(!t||t(n,e))&&n!==Object.prototype);return e},BT=(n,e,t)=>{n=String(n),(t===void 0||t>n.length)&&(t=n.length),t-=e.length;const r=n.indexOf(e,t);return r!==-1&&r===t},jT=n=>{if(!n)return null;if($a(n))return n;let e=n.length;if(!cb(e))return null;const t=new Array(e);for(;e-- >0;)t[e]=n[e];return t},WT=(n=>e=>n&&e instanceof n)(typeof Uint8Array<"u"&&Vd(Uint8Array)),zT=(n,e)=>{const t=(n&&n[zc]).call(n);let r;for(;(r=t.next())&&!r.done;){const l=r.value;e.call(n,l[0],l[1])}},HT=(n,e)=>{let t;const r=[];for(;(t=n.exec(e))!==null;)r.push(t);return r},UT=qi("HTMLFormElement"),qT=n=>n.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,r){return t.toUpperCase()+r}),db=(({hasOwnProperty:n})=>(e,t)=>n.call(e,t))(Object.prototype),VT=qi("RegExp"),fb=(n,e)=>{const t=Object.getOwnPropertyDescriptors(n),r={};xl(t,(l,d)=>{let h;(h=e(l,d,n))!==!1&&(r[d]=h||l)}),Object.defineProperties(n,r)},KT=n=>{fb(n,(e,t)=>{if(Qr(n)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const r=n[t];if(Qr(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},GT=(n,e)=>{const t={},r=l=>{l.forEach(d=>{t[d]=!0})};return $a(n)?r(n):r(String(n).split(e)),t},YT=()=>{},XT=(n,e)=>n!=null&&Number.isFinite(n=+n)?n:e;function QT(n){return!!(n&&Qr(n.append)&&n[ab]==="FormData"&&n[zc])}const ZT=n=>{const e=new Array(10),t=(r,l)=>{if(wl(r)){if(e.indexOf(r)>=0)return;if(bl(r))return r;if(!("toJSON"in r)){e[l]=r;const d=$a(r)?[]:{};return xl(r,(h,b)=>{const p=t(h,l+1);!Aa(p)&&(d[b]=p)}),e[l]=void 0,d}}return r};return t(n,0)},JT=qi("AsyncFunction"),eR=n=>n&&(wl(n)||Qr(n))&&Qr(n.then)&&Qr(n.catch),pb=((n,e)=>n?setImmediate:e?((t,r)=>(Ds.addEventListener("message",({source:l,data:d})=>{l===Ds&&d===t&&r.length&&r.shift()()},!1),l=>{r.push(l),Ds.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",Qr(Ds.postMessage)),tR=typeof queueMicrotask<"u"?queueMicrotask.bind(Ds):typeof process<"u"&&process.nextTick||pb,nR=n=>n!=null&&Qr(n[zc]),Ce={isArray:$a,isArrayBuffer:lb,isBuffer:bl,isFormData:ET,isArrayBufferView:bT,isString:wT,isNumber:cb,isBoolean:xT,isObject:wl,isPlainObject:qc,isEmptyObject:kT,isReadableStream:RT,isRequest:MT,isResponse:LT,isHeaders:OT,isUndefined:Aa,isDate:ST,isFile:_T,isBlob:CT,isRegExp:VT,isFunction:Qr,isStream:AT,isURLSearchParams:TT,isTypedArray:WT,isFileList:$T,forEach:xl,merge:Kd,extend:NT,trim:IT,stripBOM:DT,inherits:FT,toFlatObject:PT,kindOf:Hc,kindOfTest:qi,endsWith:BT,toArray:jT,forEachEntry:zT,matchAll:HT,isHTMLForm:UT,hasOwnProperty:db,hasOwnProp:db,reduceDescriptors:fb,freezeMethods:KT,toObjectSet:GT,toCamelCase:qT,noop:YT,toFiniteNumber:XT,findKey:ub,global:Ds,isContextDefined:hb,isSpecCompliantForm:QT,toJSONObject:ZT,isAsyncFn:JT,isThenable:eR,setImmediate:pb,asap:tR,isIterable:nR};function _t(n,e,t,r,l){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=n,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),r&&(this.request=r),l&&(this.response=l,this.status=l.status?l.status:null)}Ce.inherits(_t,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:Ce.toJSONObject(this.config),code:this.code,status:this.status}}});const gb=_t.prototype,mb={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(n=>{mb[n]={value:n}}),Object.defineProperties(_t,mb),Object.defineProperty(gb,"isAxiosError",{value:!0}),_t.from=(n,e,t,r,l,d)=>{const h=Object.create(gb);Ce.toFlatObject(n,h,function(g){return g!==Error.prototype},g=>g!=="isAxiosError");const b=n&&n.message?n.message:"Error",p=e==null&&n?n.code:e;return _t.call(h,b,p,t,r,l),n&&h.cause==null&&Object.defineProperty(h,"cause",{value:n,configurable:!0}),h.name=n&&n.name||"Error",d&&Object.assign(h,d),h};const rR=null;function Gd(n){return Ce.isPlainObject(n)||Ce.isArray(n)}function vb(n){return Ce.endsWith(n,"[]")?n.slice(0,-2):n}function yb(n,e,t){return n?n.concat(e).map(function(r,l){return r=vb(r),!t&&l?"["+r+"]":r}).join(t?".":""):e}function iR(n){return Ce.isArray(n)&&!n.some(Gd)}const oR=Ce.toFlatObject(Ce,{},null,function(n){return/^is[A-Z]/.test(n)});function Vc(n,e,t){if(!Ce.isObject(n))throw new TypeError("target must be an object");e=e||new FormData,t=Ce.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(u,i){return!Ce.isUndefined(i[u])});const r=t.metaTokens,l=t.visitor||g,d=t.dots,h=t.indexes,b=(t.Blob||typeof Blob<"u"&&Blob)&&Ce.isSpecCompliantForm(e);if(!Ce.isFunction(l))throw new TypeError("visitor must be a function");function p(u){if(u===null)return"";if(Ce.isDate(u))return u.toISOString();if(Ce.isBoolean(u))return u.toString();if(!b&&Ce.isBlob(u))throw new _t("Blob is not supported. Use a Buffer instead.");return Ce.isArrayBuffer(u)||Ce.isTypedArray(u)?b&&typeof Blob=="function"?new Blob([u]):Buffer.from(u):u}function g(u,i,a){let m=u;if(u&&!a&&typeof u=="object"){if(Ce.endsWith(i,"{}"))i=r?i:i.slice(0,-2),u=JSON.stringify(u);else if(Ce.isArray(u)&&iR(u)||(Ce.isFileList(u)||Ce.endsWith(i,"[]"))&&(m=Ce.toArray(u)))return i=vb(i),m.forEach(function(w,x){!(Ce.isUndefined(w)||w===null)&&e.append(h===!0?yb([i],x,d):h===null?i:i+"[]",p(w))}),!1}return Gd(u)?!0:(e.append(yb(a,i,d),p(u)),!1)}const o=[],c=Object.assign(oR,{defaultVisitor:g,convertValue:p,isVisitable:Gd});function f(u,i){if(!Ce.isUndefined(u)){if(o.indexOf(u)!==-1)throw Error("Circular reference detected in "+i.join("."));o.push(u),Ce.forEach(u,function(a,m){(!(Ce.isUndefined(a)||a===null)&&l.call(e,a,Ce.isString(m)?m.trim():m,i,c))===!0&&f(a,i?i.concat(m):[m])}),o.pop()}}if(!Ce.isObject(n))throw new TypeError("data must be an object");return f(n),e}function bb(n){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(n).replace(/[!'()~]|%20|%00/g,function(t){return e[t]})}function Yd(n,e){this._pairs=[],n&&Vc(n,this,e)}const wb=Yd.prototype;wb.append=function(n,e){this._pairs.push([n,e])},wb.toString=function(n){const e=n?function(t){return n.call(this,t,bb)}:bb;return this._pairs.map(function(t){return e(t[0])+"="+e(t[1])},"").join("&")};function sR(n){return encodeURIComponent(n).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function xb(n,e,t){if(!e)return n;const r=t&&t.encode||sR;Ce.isFunction(t)&&(t={serialize:t});const l=t&&t.serialize;let d;if(l?d=l(e,t):d=Ce.isURLSearchParams(e)?e.toString():new Yd(e,t).toString(r),d){const h=n.indexOf("#");h!==-1&&(n=n.slice(0,h)),n+=(n.indexOf("?")===-1?"?":"&")+d}return n}let kb=class{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){Ce.forEach(this.handlers,function(t){t!==null&&e(t)})}};const Sb={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},aR=typeof URLSearchParams<"u"?URLSearchParams:Yd,lR=typeof FormData<"u"?FormData:null,cR=typeof Blob<"u"?Blob:null,uR={isBrowser:!0,classes:{URLSearchParams:aR,FormData:lR,Blob:cR},protocols:["http","https","file","blob","url","data"]},Xd=typeof window<"u"&&typeof document<"u",Qd=typeof navigator=="object"&&navigator||void 0,hR=Xd&&(!Qd||["ReactNative","NativeScript","NS"].indexOf(Qd.product)<0),dR=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",fR=Xd&&window.location.href||"http://localhost",pR=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Xd,hasStandardBrowserEnv:hR,hasStandardBrowserWebWorkerEnv:dR,navigator:Qd,origin:fR},Symbol.toStringTag,{value:"Module"})),_r={...pR,...uR};function gR(n,e){return Vc(n,new _r.classes.URLSearchParams,{visitor:function(t,r,l,d){return _r.isNode&&Ce.isBuffer(t)?(this.append(r,t.toString("base64")),!1):d.defaultVisitor.apply(this,arguments)},...e})}function mR(n){return Ce.matchAll(/\w+|\[(\w*)]/g,n).map(e=>e[0]==="[]"?"":e[1]||e[0])}function vR(n){const e={},t=Object.keys(n);let r;const l=t.length;let d;for(r=0;r<l;r++)d=t[r],e[d]=n[d];return e}function _b(n){function e(t,r,l,d){let h=t[d++];if(h==="__proto__")return!0;const b=Number.isFinite(+h),p=d>=t.length;return h=!h&&Ce.isArray(l)?l.length:h,p?(Ce.hasOwnProp(l,h)?l[h]=[l[h],r]:l[h]=r,!b):((!l[h]||!Ce.isObject(l[h]))&&(l[h]=[]),e(t,r,l[h],d)&&Ce.isArray(l[h])&&(l[h]=vR(l[h])),!b)}if(Ce.isFormData(n)&&Ce.isFunction(n.entries)){const t={};return Ce.forEachEntry(n,(r,l)=>{e(mR(r),l,t,0)}),t}return null}function yR(n,e,t){if(Ce.isString(n))try{return(e||JSON.parse)(n),Ce.trim(n)}catch(r){if(r.name!=="SyntaxError")throw r}return(t||JSON.stringify)(n)}const kl={transitional:Sb,adapter:["xhr","http","fetch"],transformRequest:[function(n,e){const t=e.getContentType()||"",r=t.indexOf("application/json")>-1,l=Ce.isObject(n);if(l&&Ce.isHTMLForm(n)&&(n=new FormData(n)),Ce.isFormData(n))return r?JSON.stringify(_b(n)):n;if(Ce.isArrayBuffer(n)||Ce.isBuffer(n)||Ce.isStream(n)||Ce.isFile(n)||Ce.isBlob(n)||Ce.isReadableStream(n))return n;if(Ce.isArrayBufferView(n))return n.buffer;if(Ce.isURLSearchParams(n))return e.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),n.toString();let d;if(l){if(t.indexOf("application/x-www-form-urlencoded")>-1)return gR(n,this.formSerializer).toString();if((d=Ce.isFileList(n))||t.indexOf("multipart/form-data")>-1){const h=this.env&&this.env.FormData;return Vc(d?{"files[]":n}:n,h&&new h,this.formSerializer)}}return l||r?(e.setContentType("application/json",!1),yR(n)):n}],transformResponse:[function(n){const e=this.transitional||kl.transitional,t=e&&e.forcedJSONParsing,r=this.responseType==="json";if(Ce.isResponse(n)||Ce.isReadableStream(n))return n;if(n&&Ce.isString(n)&&(t&&!this.responseType||r)){const l=!(e&&e.silentJSONParsing)&&r;try{return JSON.parse(n,this.parseReviver)}catch(d){if(l)throw d.name==="SyntaxError"?_t.from(d,_t.ERR_BAD_RESPONSE,this,null,this.response):d}}return n}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:_r.classes.FormData,Blob:_r.classes.Blob},validateStatus:function(n){return n>=200&&n<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};Ce.forEach(["delete","get","head","post","put","patch"],n=>{kl.headers[n]={}});const bR=Ce.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),wR=n=>{const e={};let t,r,l;return n&&n.split(`
|
|
1497
|
+
`).forEach(function(d){l=d.indexOf(":"),t=d.substring(0,l).trim().toLowerCase(),r=d.substring(l+1).trim(),!(!t||e[t]&&bR[t])&&(t==="set-cookie"?e[t]?e[t].push(r):e[t]=[r]:e[t]=e[t]?e[t]+", "+r:r)}),e},Cb=Symbol("internals");function Sl(n){return n&&String(n).trim().toLowerCase()}function Kc(n){return n===!1||n==null?n:Ce.isArray(n)?n.map(Kc):String(n)}function xR(n){const e=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=t.exec(n);)e[r[1]]=r[2];return e}const kR=n=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(n.trim());function Zd(n,e,t,r,l){if(Ce.isFunction(r))return r.call(this,e,t);if(l&&(e=t),!!Ce.isString(e)){if(Ce.isString(r))return e.indexOf(r)!==-1;if(Ce.isRegExp(r))return r.test(e)}}function SR(n){return n.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r)}function _R(n,e){const t=Ce.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(n,r+t,{value:function(l,d,h){return this[r].call(this,e,l,d,h)},configurable:!0})})}let Zr=class{constructor(e){e&&this.set(e)}set(e,t,r){const l=this;function d(b,p,g){const o=Sl(p);if(!o)throw new Error("header name must be a non-empty string");const c=Ce.findKey(l,o);(!c||l[c]===void 0||g===!0||g===void 0&&l[c]!==!1)&&(l[c||p]=Kc(b))}const h=(b,p)=>Ce.forEach(b,(g,o)=>d(g,o,p));if(Ce.isPlainObject(e)||e instanceof this.constructor)h(e,t);else if(Ce.isString(e)&&(e=e.trim())&&!kR(e))h(wR(e),t);else if(Ce.isObject(e)&&Ce.isIterable(e)){let b={},p,g;for(const o of e){if(!Ce.isArray(o))throw TypeError("Object iterator must return a key-value pair");b[g=o[0]]=(p=b[g])?Ce.isArray(p)?[...p,o[1]]:[p,o[1]]:o[1]}h(b,t)}else e!=null&&d(t,e,r);return this}get(e,t){if(e=Sl(e),e){const r=Ce.findKey(this,e);if(r){const l=this[r];if(!t)return l;if(t===!0)return xR(l);if(Ce.isFunction(t))return t.call(this,l,r);if(Ce.isRegExp(t))return t.exec(l);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Sl(e),e){const r=Ce.findKey(this,e);return!!(r&&this[r]!==void 0&&(!t||Zd(this,this[r],r,t)))}return!1}delete(e,t){const r=this;let l=!1;function d(h){if(h=Sl(h),h){const b=Ce.findKey(r,h);b&&(!t||Zd(r,r[b],b,t))&&(delete r[b],l=!0)}}return Ce.isArray(e)?e.forEach(d):d(e),l}clear(e){const t=Object.keys(this);let r=t.length,l=!1;for(;r--;){const d=t[r];(!e||Zd(this,this[d],d,e,!0))&&(delete this[d],l=!0)}return l}normalize(e){const t=this,r={};return Ce.forEach(this,(l,d)=>{const h=Ce.findKey(r,d);if(h){t[h]=Kc(l),delete t[d];return}const b=e?SR(d):String(d).trim();b!==d&&delete t[d],t[b]=Kc(l),r[b]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return Ce.forEach(this,(r,l)=>{r!=null&&r!==!1&&(t[l]=e&&Ce.isArray(r)?r.join(", "):r)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join(`
|
|
1498
|
+
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const r=new this(e);return t.forEach(l=>r.set(l)),r}static accessor(e){const t=(this[Cb]=this[Cb]={accessors:{}}).accessors,r=this.prototype;function l(d){const h=Sl(d);t[h]||(_R(r,d),t[h]=!0)}return Ce.isArray(e)?e.forEach(l):l(e),this}};Zr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Ce.reduceDescriptors(Zr.prototype,({value:n},e)=>{let t=e[0].toUpperCase()+e.slice(1);return{get:()=>n,set(r){this[t]=r}}}),Ce.freezeMethods(Zr);function Jd(n,e){const t=this||kl,r=e||t,l=Zr.from(r.headers);let d=r.data;return Ce.forEach(n,function(h){d=h.call(t,d,l.normalize(),e?e.status:void 0)}),l.normalize(),d}function $b(n){return!!(n&&n.__CANCEL__)}function Ea(n,e,t){_t.call(this,n??"canceled",_t.ERR_CANCELED,e,t),this.name="CanceledError"}Ce.inherits(Ea,_t,{__CANCEL__:!0});function Ab(n,e,t){const r=t.config.validateStatus;!t.status||!r||r(t.status)?n(t):e(new _t("Request failed with status code "+t.status,[_t.ERR_BAD_REQUEST,_t.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function CR(n){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(n);return e&&e[1]||""}function $R(n,e){n=n||10;const t=new Array(n),r=new Array(n);let l=0,d=0,h;return e=e!==void 0?e:1e3,function(b){const p=Date.now(),g=r[d];h||(h=p),t[l]=b,r[l]=p;let o=d,c=0;for(;o!==l;)c+=t[o++],o=o%n;if(l=(l+1)%n,l===d&&(d=(d+1)%n),p-h<e)return;const f=g&&p-g;return f?Math.round(c*1e3/f):void 0}}function AR(n,e){let t=0,r=1e3/e,l,d;const h=(b,p=Date.now())=>{t=p,l=null,d&&(clearTimeout(d),d=null),n(...b)};return[(...b)=>{const p=Date.now(),g=p-t;g>=r?h(b,p):(l=b,d||(d=setTimeout(()=>{d=null,h(l)},r-g)))},()=>l&&h(l)]}const Gc=(n,e,t=3)=>{let r=0;const l=$R(50,250);return AR(d=>{const h=d.loaded,b=d.lengthComputable?d.total:void 0,p=h-r,g=l(p),o=h<=b;r=h;const c={loaded:h,total:b,progress:b?h/b:void 0,bytes:p,rate:g||void 0,estimated:g&&b&&o?(b-h)/g:void 0,event:d,lengthComputable:b!=null,[e?"download":"upload"]:!0};n(c)},t)},Eb=(n,e)=>{const t=n!=null;return[r=>e[0]({lengthComputable:t,total:n,loaded:r}),e[1]]},Tb=n=>(...e)=>Ce.asap(()=>n(...e)),ER=_r.hasStandardBrowserEnv?((n,e)=>t=>(t=new URL(t,_r.origin),n.protocol===t.protocol&&n.host===t.host&&(e||n.port===t.port)))(new URL(_r.origin),_r.navigator&&/(msie|trident)/i.test(_r.navigator.userAgent)):()=>!0,TR=_r.hasStandardBrowserEnv?{write(n,e,t,r,l,d,h){if(typeof document>"u")return;const b=[`${n}=${encodeURIComponent(e)}`];Ce.isNumber(t)&&b.push(`expires=${new Date(t).toUTCString()}`),Ce.isString(r)&&b.push(`path=${r}`),Ce.isString(l)&&b.push(`domain=${l}`),d===!0&&b.push("secure"),Ce.isString(h)&&b.push(`SameSite=${h}`),document.cookie=b.join("; ")},read(n){if(typeof document>"u")return null;const e=document.cookie.match(new RegExp("(?:^|; )"+n+"=([^;]*)"));return e?decodeURIComponent(e[1]):null},remove(n){this.write(n,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function RR(n){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(n)}function MR(n,e){return e?n.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):n}function Rb(n,e,t){let r=!RR(e);return n&&(r||t==!1)?MR(n,e):e}const Mb=n=>n instanceof Zr?{...n}:n;function Fs(n,e){e=e||{};const t={};function r(g,o,c,f){return Ce.isPlainObject(g)&&Ce.isPlainObject(o)?Ce.merge.call({caseless:f},g,o):Ce.isPlainObject(o)?Ce.merge({},o):Ce.isArray(o)?o.slice():o}function l(g,o,c,f){if(Ce.isUndefined(o)){if(!Ce.isUndefined(g))return r(void 0,g,c,f)}else return r(g,o,c,f)}function d(g,o){if(!Ce.isUndefined(o))return r(void 0,o)}function h(g,o){if(Ce.isUndefined(o)){if(!Ce.isUndefined(g))return r(void 0,g)}else return r(void 0,o)}function b(g,o,c){if(c in e)return r(g,o);if(c in n)return r(void 0,g)}const p={url:d,method:d,data:d,baseURL:h,transformRequest:h,transformResponse:h,paramsSerializer:h,timeout:h,timeoutMessage:h,withCredentials:h,withXSRFToken:h,adapter:h,responseType:h,xsrfCookieName:h,xsrfHeaderName:h,onUploadProgress:h,onDownloadProgress:h,decompress:h,maxContentLength:h,maxBodyLength:h,beforeRedirect:h,transport:h,httpAgent:h,httpsAgent:h,cancelToken:h,socketPath:h,responseEncoding:h,validateStatus:b,headers:(g,o,c)=>l(Mb(g),Mb(o),c,!0)};return Ce.forEach(Object.keys({...n,...e}),function(g){const o=p[g]||l,c=o(n[g],e[g],g);Ce.isUndefined(c)&&o!==b||(t[g]=c)}),t}const Lb=n=>{const e=Fs({},n);let{data:t,withXSRFToken:r,xsrfHeaderName:l,xsrfCookieName:d,headers:h,auth:b}=e;if(e.headers=h=Zr.from(h),e.url=xb(Rb(e.baseURL,e.url,e.allowAbsoluteUrls),n.params,n.paramsSerializer),b&&h.set("Authorization","Basic "+btoa((b.username||"")+":"+(b.password?unescape(encodeURIComponent(b.password)):""))),Ce.isFormData(t)){if(_r.hasStandardBrowserEnv||_r.hasStandardBrowserWebWorkerEnv)h.setContentType(void 0);else if(Ce.isFunction(t.getHeaders)){const p=t.getHeaders(),g=["content-type","content-length"];Object.entries(p).forEach(([o,c])=>{g.includes(o.toLowerCase())&&h.set(o,c)})}}if(_r.hasStandardBrowserEnv&&(r&&Ce.isFunction(r)&&(r=r(e)),r||r!==!1&&ER(e.url))){const p=l&&d&&TR.read(d);p&&h.set(l,p)}return e},LR=typeof XMLHttpRequest<"u",OR=LR&&function(n){return new Promise(function(e,t){const r=Lb(n);let l=r.data;const d=Zr.from(r.headers).normalize();let{responseType:h,onUploadProgress:b,onDownloadProgress:p}=r,g,o,c,f,u;function i(){f&&f(),u&&u(),r.cancelToken&&r.cancelToken.unsubscribe(g),r.signal&&r.signal.removeEventListener("abort",g)}let a=new XMLHttpRequest;a.open(r.method.toUpperCase(),r.url,!0),a.timeout=r.timeout;function m(){if(!a)return;const x=Zr.from("getAllResponseHeaders"in a&&a.getAllResponseHeaders()),M={data:!h||h==="text"||h==="json"?a.responseText:a.response,status:a.status,statusText:a.statusText,headers:x,config:n,request:a};Ab(function($){e($),i()},function($){t($),i()},M),a=null}"onloadend"in a?a.onloadend=m:a.onreadystatechange=function(){!a||a.readyState!==4||a.status===0&&!(a.responseURL&&a.responseURL.indexOf("file:")===0)||setTimeout(m)},a.onabort=function(){a&&(t(new _t("Request aborted",_t.ECONNABORTED,n,a)),a=null)},a.onerror=function(x){const M=x&&x.message?x.message:"Network Error",$=new _t(M,_t.ERR_NETWORK,n,a);$.event=x||null,t($),a=null},a.ontimeout=function(){let x=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const M=r.transitional||Sb;r.timeoutErrorMessage&&(x=r.timeoutErrorMessage),t(new _t(x,M.clarifyTimeoutError?_t.ETIMEDOUT:_t.ECONNABORTED,n,a)),a=null},l===void 0&&d.setContentType(null),"setRequestHeader"in a&&Ce.forEach(d.toJSON(),function(x,M){a.setRequestHeader(M,x)}),Ce.isUndefined(r.withCredentials)||(a.withCredentials=!!r.withCredentials),h&&h!=="json"&&(a.responseType=r.responseType),p&&([c,u]=Gc(p,!0),a.addEventListener("progress",c)),b&&a.upload&&([o,f]=Gc(b),a.upload.addEventListener("progress",o),a.upload.addEventListener("loadend",f)),(r.cancelToken||r.signal)&&(g=x=>{a&&(t(!x||x.type?new Ea(null,n,a):x),a.abort(),a=null)},r.cancelToken&&r.cancelToken.subscribe(g),r.signal&&(r.signal.aborted?g():r.signal.addEventListener("abort",g)));const w=CR(r.url);if(w&&_r.protocols.indexOf(w)===-1){t(new _t("Unsupported protocol "+w+":",_t.ERR_BAD_REQUEST,n));return}a.send(l||null)})},IR=(n,e)=>{const{length:t}=n=n?n.filter(Boolean):[];if(e||t){let r=new AbortController,l;const d=function(g){if(!l){l=!0,b();const o=g instanceof Error?g:this.reason;r.abort(o instanceof _t?o:new Ea(o instanceof Error?o.message:o))}};let h=e&&setTimeout(()=>{h=null,d(new _t(`timeout ${e} of ms exceeded`,_t.ETIMEDOUT))},e);const b=()=>{n&&(h&&clearTimeout(h),h=null,n.forEach(g=>{g.unsubscribe?g.unsubscribe(d):g.removeEventListener("abort",d)}),n=null)};n.forEach(g=>g.addEventListener("abort",d));const{signal:p}=r;return p.unsubscribe=()=>Ce.asap(b),p}},NR=function*(n,e){let t=n.byteLength;if(t<e){yield n;return}let r=0,l;for(;r<t;)l=r+e,yield n.slice(r,l),r=l},DR=async function*(n,e){for await(const t of FR(n))yield*NR(t,e)},FR=async function*(n){if(n[Symbol.asyncIterator]){yield*n;return}const e=n.getReader();try{for(;;){const{done:t,value:r}=await e.read();if(t)break;yield r}}finally{await e.cancel()}},Ob=(n,e,t,r)=>{const l=DR(n,e);let d=0,h,b=p=>{h||(h=!0,r&&r(p))};return new ReadableStream({async pull(p){try{const{done:g,value:o}=await l.next();if(g){b(),p.close();return}let c=o.byteLength;if(t){let f=d+=c;t(f)}p.enqueue(new Uint8Array(o))}catch(g){throw b(g),g}},cancel(p){return b(p),l.return()}},{highWaterMark:2})},Ib=64*1024,{isFunction:Yc}=Ce,PR=(({Request:n,Response:e})=>({Request:n,Response:e}))(Ce.global),{ReadableStream:Nb,TextEncoder:Db}=Ce.global,Fb=(n,...e)=>{try{return!!n(...e)}catch{return!1}},BR=n=>{n=Ce.merge.call({skipUndefined:!0},PR,n);const{fetch:e,Request:t,Response:r}=n,l=e?Yc(e):typeof fetch=="function",d=Yc(t),h=Yc(r);if(!l)return!1;const b=l&&Yc(Nb),p=l&&(typeof Db=="function"?(i=>a=>i.encode(a))(new Db):async i=>new Uint8Array(await new t(i).arrayBuffer())),g=d&&b&&Fb(()=>{let i=!1;const a=new t(_r.origin,{body:new Nb,method:"POST",get duplex(){return i=!0,"half"}}).headers.has("Content-Type");return i&&!a}),o=h&&b&&Fb(()=>Ce.isReadableStream(new r("").body)),c={stream:o&&(i=>i.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(i=>{!c[i]&&(c[i]=(a,m)=>{let w=a&&a[i];if(w)return w.call(a);throw new _t(`Response type '${i}' is not supported`,_t.ERR_NOT_SUPPORT,m)})});const f=async i=>{if(i==null)return 0;if(Ce.isBlob(i))return i.size;if(Ce.isSpecCompliantForm(i))return(await new t(_r.origin,{method:"POST",body:i}).arrayBuffer()).byteLength;if(Ce.isArrayBufferView(i)||Ce.isArrayBuffer(i))return i.byteLength;if(Ce.isURLSearchParams(i)&&(i=i+""),Ce.isString(i))return(await p(i)).byteLength},u=async(i,a)=>Ce.toFiniteNumber(i.getContentLength())??f(a);return async i=>{let{url:a,method:m,data:w,signal:x,cancelToken:M,timeout:$,onDownloadProgress:S,onUploadProgress:k,responseType:T,headers:D,withCredentials:L="same-origin",fetchOptions:O}=Lb(i),z=e||fetch;T=T?(T+"").toLowerCase():"text";let P=IR([x,M&&M.toAbortSignal()],$),N=null;const A=P&&P.unsubscribe&&(()=>{P.unsubscribe()});let _;try{if(k&&g&&m!=="get"&&m!=="head"&&(_=await u(D,w))!==0){let J=new t(a,{method:"POST",body:w,duplex:"half"}),ae;if(Ce.isFormData(w)&&(ae=J.headers.get("content-type"))&&D.setContentType(ae),J.body){const[ne,se]=Eb(_,Gc(Tb(k)));w=Ob(J.body,Ib,ne,se)}}Ce.isString(L)||(L=L?"include":"omit");const I=d&&"credentials"in t.prototype,j={...O,signal:P,method:m.toUpperCase(),headers:D.normalize().toJSON(),body:w,duplex:"half",credentials:I?L:void 0};N=d&&new t(a,j);let U=await(d?z(N,O):z(a,j));const K=o&&(T==="stream"||T==="response");if(o&&(S||K&&A)){const J={};["status","statusText","headers"].forEach(ce=>{J[ce]=U[ce]});const ae=Ce.toFiniteNumber(U.headers.get("content-length")),[ne,se]=S&&Eb(ae,Gc(Tb(S),!0))||[];U=new r(Ob(U.body,Ib,ne,()=>{se&&se(),A&&A()}),J)}T=T||"text";let Z=await c[Ce.findKey(c,T)||"text"](U,i);return!K&&A&&A(),await new Promise((J,ae)=>{Ab(J,ae,{data:Z,headers:Zr.from(U.headers),status:U.status,statusText:U.statusText,config:i,request:N})})}catch(I){throw A&&A(),I&&I.name==="TypeError"&&/Load failed|fetch/i.test(I.message)?Object.assign(new _t("Network Error",_t.ERR_NETWORK,i,N),{cause:I.cause||I}):_t.from(I,I&&I.code,i,N)}}},jR=new Map,Pb=n=>{let e=n&&n.env||{};const{fetch:t,Request:r,Response:l}=e,d=[r,l,t];let h=d.length,b=h,p,g,o=jR;for(;b--;)p=d[b],g=o.get(p),g===void 0&&o.set(p,g=b?new Map:BR(e)),o=g;return g};Pb();const ef={http:rR,xhr:OR,fetch:{get:Pb}};Ce.forEach(ef,(n,e)=>{if(n){try{Object.defineProperty(n,"name",{value:e})}catch{}Object.defineProperty(n,"adapterName",{value:e})}});const Bb=n=>`- ${n}`,WR=n=>Ce.isFunction(n)||n===null||n===!1;function zR(n,e){n=Ce.isArray(n)?n:[n];const{length:t}=n;let r,l;const d={};for(let h=0;h<t;h++){r=n[h];let b;if(l=r,!WR(r)&&(l=ef[(b=String(r)).toLowerCase()],l===void 0))throw new _t(`Unknown adapter '${b}'`);if(l&&(Ce.isFunction(l)||(l=l.get(e))))break;d[b||"#"+h]=l}if(!l){const h=Object.entries(d).map(([p,g])=>`adapter ${p} `+(g===!1?"is not supported by the environment":"is not available in the build"));let b=t?h.length>1?`since :
|
|
1499
|
+
`+h.map(Bb).join(`
|
|
1500
|
+
`):" "+Bb(h[0]):"as no adapter specified";throw new _t("There is no suitable adapter to dispatch the request "+b,"ERR_NOT_SUPPORT")}return l}const jb={getAdapter:zR,adapters:ef};function tf(n){if(n.cancelToken&&n.cancelToken.throwIfRequested(),n.signal&&n.signal.aborted)throw new Ea(null,n)}function Wb(n){return tf(n),n.headers=Zr.from(n.headers),n.data=Jd.call(n,n.transformRequest),["post","put","patch"].indexOf(n.method)!==-1&&n.headers.setContentType("application/x-www-form-urlencoded",!1),jb.getAdapter(n.adapter||kl.adapter,n)(n).then(function(e){return tf(n),e.data=Jd.call(n,n.transformResponse,e),e.headers=Zr.from(e.headers),e},function(e){return $b(e)||(tf(n),e&&e.response&&(e.response.data=Jd.call(n,n.transformResponse,e.response),e.response.headers=Zr.from(e.response.headers))),Promise.reject(e)})}const zb="1.13.1",Xc={};["object","boolean","number","function","string","symbol"].forEach((n,e)=>{Xc[n]=function(t){return typeof t===n||"a"+(e<1?"n ":" ")+n}});const Hb={};Xc.transitional=function(n,e,t){function r(l,d){return"[Axios v"+zb+"] Transitional option '"+l+"'"+d+(t?". "+t:"")}return(l,d,h)=>{if(n===!1)throw new _t(r(d," has been removed"+(e?" in "+e:"")),_t.ERR_DEPRECATED);return e&&!Hb[d]&&(Hb[d]=!0,console.warn(r(d," has been deprecated since v"+e+" and will be removed in the near future"))),n?n(l,d,h):!0}},Xc.spelling=function(n){return(e,t)=>(console.warn(`${t} is likely a misspelling of ${n}`),!0)};function HR(n,e,t){if(typeof n!="object")throw new _t("options must be an object",_t.ERR_BAD_OPTION_VALUE);const r=Object.keys(n);let l=r.length;for(;l-- >0;){const d=r[l],h=e[d];if(h){const b=n[d],p=b===void 0||h(b,d,n);if(p!==!0)throw new _t("option "+d+" must be "+p,_t.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new _t("Unknown option "+d,_t.ERR_BAD_OPTION)}}const Qc={assertOptions:HR,validators:Xc},co=Qc.validators;let Ps=class{constructor(e){this.defaults=e||{},this.interceptors={request:new kb,response:new kb}}async request(e,t){try{return await this._request(e,t)}catch(r){if(r instanceof Error){let l={};Error.captureStackTrace?Error.captureStackTrace(l):l=new Error;const d=l.stack?l.stack.replace(/^.+\n/,""):"";try{r.stack?d&&!String(r.stack).endsWith(d.replace(/^.+\n.+\n/,""))&&(r.stack+=`
|
|
1501
|
+
`+d):r.stack=d}catch{}}throw r}}_request(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=Fs(this.defaults,t);const{transitional:r,paramsSerializer:l,headers:d}=t;r!==void 0&&Qc.assertOptions(r,{silentJSONParsing:co.transitional(co.boolean),forcedJSONParsing:co.transitional(co.boolean),clarifyTimeoutError:co.transitional(co.boolean)},!1),l!=null&&(Ce.isFunction(l)?t.paramsSerializer={serialize:l}:Qc.assertOptions(l,{encode:co.function,serialize:co.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),Qc.assertOptions(t,{baseUrl:co.spelling("baseURL"),withXsrfToken:co.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let h=d&&Ce.merge(d.common,d[t.method]);d&&Ce.forEach(["delete","get","head","post","put","patch","common"],i=>{delete d[i]}),t.headers=Zr.concat(h,d);const b=[];let p=!0;this.interceptors.request.forEach(function(i){typeof i.runWhen=="function"&&i.runWhen(t)===!1||(p=p&&i.synchronous,b.unshift(i.fulfilled,i.rejected))});const g=[];this.interceptors.response.forEach(function(i){g.push(i.fulfilled,i.rejected)});let o,c=0,f;if(!p){const i=[Wb.bind(this),void 0];for(i.unshift(...b),i.push(...g),f=i.length,o=Promise.resolve(t);c<f;)o=o.then(i[c++],i[c++]);return o}f=b.length;let u=t;for(;c<f;){const i=b[c++],a=b[c++];try{u=i(u)}catch(m){a.call(this,m);break}}try{o=Wb.call(this,u)}catch(i){return Promise.reject(i)}for(c=0,f=g.length;c<f;)o=o.then(g[c++],g[c++]);return o}getUri(e){e=Fs(this.defaults,e);const t=Rb(e.baseURL,e.url,e.allowAbsoluteUrls);return xb(t,e.params,e.paramsSerializer)}};Ce.forEach(["delete","get","head","options"],function(n){Ps.prototype[n]=function(e,t){return this.request(Fs(t||{},{method:n,url:e,data:(t||{}).data}))}}),Ce.forEach(["post","put","patch"],function(n){function e(t){return function(r,l,d){return this.request(Fs(d||{},{method:n,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:l}))}}Ps.prototype[n]=e(),Ps.prototype[n+"Form"]=e(!0)});let UR=class qx{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(l){t=l});const r=this;this.promise.then(l=>{if(!r._listeners)return;let d=r._listeners.length;for(;d-- >0;)r._listeners[d](l);r._listeners=null}),this.promise.then=l=>{let d;const h=new Promise(b=>{r.subscribe(b),d=b}).then(l);return h.cancel=function(){r.unsubscribe(d)},h},e(function(l,d,h){r.reason||(r.reason=new Ea(l,d,h),t(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=r=>{e.abort(r)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new qx(function(t){e=t}),cancel:e}}};function qR(n){return function(e){return n.apply(null,e)}}function VR(n){return Ce.isObject(n)&&n.isAxiosError===!0}const nf={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(nf).forEach(([n,e])=>{nf[e]=n});function Ub(n){const e=new Ps(n),t=sb(Ps.prototype.request,e);return Ce.extend(t,Ps.prototype,e,{allOwnKeys:!0}),Ce.extend(t,e,null,{allOwnKeys:!0}),t.create=function(r){return Ub(Fs(n,r))},t}const Yn=Pi("w",Ub(kl));Yn.Axios=Ps,Yn.CanceledError=Ea,Yn.CancelToken=UR,Yn.isCancel=$b,Yn.VERSION=zb,Yn.toFormData=Vc,Yn.AxiosError=_t,Yn.Cancel=Yn.CanceledError,Yn.all=function(n){return Promise.all(n)},Yn.spread=qR,Yn.isAxiosError=VR,Yn.mergeConfig=Fs,Yn.AxiosHeaders=Zr,Yn.formToJSON=n=>_b(Ce.isHTMLForm(n)?new FormData(n):n),Yn.getAdapter=jb.getAdapter,Yn.HttpStatusCode=nf,Yn.default=Yn;const{Axios:aj,AxiosError:lj,CanceledError:cj,isCancel:uj,CancelToken:hj,VERSION:dj,all:fj,Cancel:pj,isAxiosError:gj,spread:mj,toFormData:vj,AxiosHeaders:yj,HttpStatusCode:bj,formToJSON:wj,getAdapter:xj,mergeConfig:kj}=Yn;function qb(){return Object.assign({},ca())}function KR(n,e,t){const r=vn(n,void 0);return r.setTime(r.getTime()+e*sc),r}function GR(n,e){const t=()=>Kn(void 0,NaN),r=ZR(n);let l;if(r.date){const p=JR(r.date,2);l=eM(p.restDateString,p.year)}if(!l||isNaN(+l))return t();const d=+l;let h=0,b;if(r.time&&(h=tM(r.time),isNaN(h)))return t();if(r.timezone){if(b=nM(r.timezone),isNaN(b))return t()}else{const p=new Date(d+h),g=vn(0,void 0);return g.setFullYear(p.getUTCFullYear(),p.getUTCMonth(),p.getUTCDate()),g.setHours(p.getUTCHours(),p.getUTCMinutes(),p.getUTCSeconds(),p.getUTCMilliseconds()),g}return vn(d+h+b,void 0)}const Zc={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},YR=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,XR=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,QR=/^([+-])(\d{2})(?::?(\d{2}))?$/;function ZR(n){const e={},t=n.split(Zc.dateTimeDelimiter);let r;if(t.length>2)return e;if(/:/.test(t[0])?r=t[0]:(e.date=t[0],r=t[1],Zc.timeZoneDelimiter.test(e.date)&&(e.date=n.split(Zc.timeZoneDelimiter)[0],r=n.substr(e.date.length,n.length))),r){const l=Zc.timezone.exec(r);l?(e.time=r.replace(l[1],""),e.timezone=l[1]):e.time=r}return e}function JR(n,e){const t=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+e)+"})|(\\d{2}|[+-]\\d{"+(2+e)+"})$)"),r=n.match(t);if(!r)return{year:NaN,restDateString:""};const l=r[1]?parseInt(r[1]):null,d=r[2]?parseInt(r[2]):null;return{year:d===null?l:d*100,restDateString:n.slice((r[1]||r[2]).length)}}function eM(n,e){if(e===null)return new Date(NaN);const t=n.match(YR);if(!t)return new Date(NaN);const r=!!t[4],l=_l(t[1]),d=_l(t[2])-1,h=_l(t[3]),b=_l(t[4]),p=_l(t[5])-1;if(r)return aM(e,b,p)?rM(e,b,p):new Date(NaN);{const g=new Date(0);return!oM(e,d,h)||!sM(e,l)?new Date(NaN):(g.setUTCFullYear(e,d,Math.max(l,h)),g)}}function _l(n){return n?parseInt(n):1}function tM(n){const e=n.match(XR);if(!e)return NaN;const t=rf(e[1]),r=rf(e[2]),l=rf(e[3]);return lM(t,r,l)?t*hh+r*sc+l*1e3:NaN}function rf(n){return n&&parseFloat(n.replace(",","."))||0}function nM(n){if(n==="Z")return 0;const e=n.match(QR);if(!e)return 0;const t=e[1]==="+"?-1:1,r=parseInt(e[2]),l=e[3]&&parseInt(e[3])||0;return cM(r,l)?t*(r*hh+l*sc):NaN}function rM(n,e,t){const r=new Date(0);r.setUTCFullYear(n,0,4);const l=r.getUTCDay()||7,d=(e-1)*7+t+1-l;return r.setUTCDate(r.getUTCDate()+d),r}const iM=[31,null,31,30,31,30,31,31,30,31,30,31];function Vb(n){return n%400===0||n%4===0&&n%100!==0}function oM(n,e,t){return e>=0&&e<=11&&t>=1&&t<=(iM[e]||(Vb(n)?29:28))}function sM(n,e){return e>=1&&e<=(Vb(n)?366:365)}function aM(n,e,t){return e>=1&&e<=53&&t>=0&&t<=6}function lM(n,e,t){return n===24?e===0&&t===0:t>=0&&t<60&&e>=0&&e<60&&n>=0&&n<25}function cM(n,e){return e>=0&&e<=59}function uM(n,e,t){return KR(n,-e)}function Kb(n,e,t){const r=qb(),l=fM(n,t.timeZone,t.locale??r.locale);return"formatToParts"in l?hM(l,e):dM(l,e)}function hM(n,e){const t=n.formatToParts(e);for(let r=t.length-1;r>=0;--r)if(t[r].type==="timeZoneName")return t[r].value}function dM(n,e){const t=n.format(e).replace(/\u200E/g,""),r=/ [\w-+ ]+$/.exec(t);return r?r[0].substr(1):""}function fM(n,e,t){return new Intl.DateTimeFormat(t?[t.code,"en-US"]:void 0,{timeZone:e,timeZoneName:n})}function pM(n,e){const t=bM(e);return"formatToParts"in t?mM(t,n):vM(t,n)}const gM={year:0,month:1,day:2,hour:3,minute:4,second:5};function mM(n,e){try{const t=n.formatToParts(e),r=[];for(let l=0;l<t.length;l++){const d=gM[t[l].type];d!==void 0&&(r[d]=parseInt(t[l].value,10))}return r}catch(t){if(t instanceof RangeError)return[NaN];throw t}}function vM(n,e){const t=n.format(e),r=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(t);return[parseInt(r[3],10),parseInt(r[1],10),parseInt(r[2],10),parseInt(r[4],10),parseInt(r[5],10),parseInt(r[6],10)]}const of={},Gb=new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:"America/New_York",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date("2014-06-25T04:00:00.123Z")),yM=Gb==="06/25/2014, 00:00:00"||Gb==="06/25/2014 00:00:00";function bM(n){return of[n]||(of[n]=yM?new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:n,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:n,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})),of[n]}function Yb(n,e,t,r,l,d,h){const b=new Date(0);return b.setUTCFullYear(n,e,t),b.setUTCHours(r,l,d,h),b}const Xb=36e5,wM=6e4,sf={timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-])(\d{2}):?(\d{2})$/};function af(n,e,t){if(!n)return 0;let r=sf.timezoneZ.exec(n);if(r)return 0;let l,d;if(r=sf.timezoneHH.exec(n),r)return l=parseInt(r[1],10),Qb(l)?-(l*Xb):NaN;if(r=sf.timezoneHHMM.exec(n),r){l=parseInt(r[2],10);const h=parseInt(r[3],10);return Qb(l,h)?(d=Math.abs(l)*Xb+h*wM,r[1]==="+"?-d:d):NaN}if(SM(n)){e=new Date(e||Date.now());const h=t?e:xM(e),b=lf(h,n);return-(t?b:kM(e,b,n))}return NaN}function xM(n){return Yb(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds())}function lf(n,e){const t=pM(n,e),r=Yb(t[0],t[1]-1,t[2],t[3]%24,t[4],t[5],0).getTime();let l=n.getTime();const d=l%1e3;return l-=d>=0?d:1e3+d,r-l}function kM(n,e,t){let r=n.getTime()-e;const l=lf(new Date(r),t);if(e===l)return e;r-=l-e;const d=lf(new Date(r),t);return l===d?l:Math.max(l,d)}function Qb(n,e){return-23<=n&&n<=23&&(e==null||0<=e&&e<=59)}const Zb={};function SM(n){if(Zb[n])return!0;try{return new Intl.DateTimeFormat(void 0,{timeZone:n}),Zb[n]=!0,!0}catch{return!1}}const _M=60*1e3,CM={X:function(n,e,t){const r=cf(t.timeZone,n);if(r===0)return"Z";switch(e){case"X":return Jb(r);case"XXXX":case"XX":return Ta(r);case"XXXXX":case"XXX":default:return Ta(r,":")}},x:function(n,e,t){const r=cf(t.timeZone,n);switch(e){case"x":return Jb(r);case"xxxx":case"xx":return Ta(r);case"xxxxx":case"xxx":default:return Ta(r,":")}},O:function(n,e,t){const r=cf(t.timeZone,n);switch(e){case"O":case"OO":case"OOO":return"GMT"+$M(r,":");case"OOOO":default:return"GMT"+Ta(r,":")}},z:function(n,e,t){switch(e){case"z":case"zz":case"zzz":return Kb("short",n,t);case"zzzz":default:return Kb("long",n,t)}}};function cf(n,e){const t=n?af(n,e,!0)/_M:(e==null?void 0:e.getTimezoneOffset())??0;if(Number.isNaN(t))throw new RangeError("Invalid time zone specified: "+n);return t}function Jc(n,e){const t=n<0?"-":"";let r=Math.abs(n).toString();for(;r.length<e;)r="0"+r;return t+r}function Ta(n,e=""){const t=n>0?"-":"+",r=Math.abs(n),l=Jc(Math.floor(r/60),2),d=Jc(Math.floor(r%60),2);return t+l+e+d}function Jb(n,e){return n%60===0?(n>0?"-":"+")+Jc(Math.abs(n)/60,2):Ta(n,e)}function $M(n,e=""){const t=n>0?"-":"+",r=Math.abs(n),l=Math.floor(r/60),d=r%60;return d===0?t+String(l):t+String(l)+e+Jc(d,2)}function ew(n){const e=new Date(Date.UTC(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()));return e.setUTCFullYear(n.getFullYear()),+n-+e}const AM=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/,uf=36e5,tw=6e4,EM=2,Fr={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,YY:/^(\d{2})$/,YYY:[/^([+-]\d{2})$/,/^([+-]\d{3})$/,/^([+-]\d{4})$/],YYYY:/^(\d{4})/,YYYYY:[/^([+-]\d{4})/,/^([+-]\d{5})/,/^([+-]\d{6})/],MM:/^-(\d{2})$/,DDD:/^-?(\d{3})$/,MMDD:/^-?(\d{2})-?(\d{2})$/,Www:/^-?W(\d{2})$/,WwwD:/^-?W(\d{2})-?(\d{1})$/,HH:/^(\d{2}([.,]\d*)?)$/,HHMM:/^(\d{2}):?(\d{2}([.,]\d*)?)$/,HHMMSS:/^(\d{2}):?(\d{2}):?(\d{2}([.,]\d*)?)$/,timeZone:AM};function nw(n,e={}){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");if(n===null)return new Date(NaN);const t=e.additionalDigits==null?EM:Number(e.additionalDigits);if(t!==2&&t!==1&&t!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(n instanceof Date||typeof n=="object"&&Object.prototype.toString.call(n)==="[object Date]")return new Date(n.getTime());if(typeof n=="number"||Object.prototype.toString.call(n)==="[object Number]")return new Date(n);if(Object.prototype.toString.call(n)!=="[object String]")return new Date(NaN);const r=TM(n),{year:l,restDateString:d}=RM(r.date,t),h=MM(d,l);if(h===null||isNaN(h.getTime()))return new Date(NaN);if(h){const b=h.getTime();let p=0,g;if(r.time&&(p=LM(r.time),p===null||isNaN(p)))return new Date(NaN);if(r.timeZone||e.timeZone){if(g=af(r.timeZone||e.timeZone,new Date(b+p)),isNaN(g))return new Date(NaN)}else g=ew(new Date(b+p)),g=ew(new Date(b+p+g));return new Date(b+p+g)}else return new Date(NaN)}function TM(n){const e={};let t=Fr.dateTimePattern.exec(n),r;if(t?(e.date=t[1],r=t[3]):(t=Fr.datePattern.exec(n),t?(e.date=t[1],r=t[2]):(e.date=null,r=n)),r){const l=Fr.timeZone.exec(r);l?(e.time=r.replace(l[1],""),e.timeZone=l[1].trim()):e.time=r}return e}function RM(n,e){if(n){const t=Fr.YYY[e],r=Fr.YYYYY[e];let l=Fr.YYYY.exec(n)||r.exec(n);if(l){const d=l[1];return{year:parseInt(d,10),restDateString:n.slice(d.length)}}if(l=Fr.YY.exec(n)||t.exec(n),l){const d=l[1];return{year:parseInt(d,10)*100,restDateString:n.slice(d.length)}}}return{year:null}}function MM(n,e){if(e===null)return null;let t,r,l;if(!n||!n.length)return t=new Date(0),t.setUTCFullYear(e),t;let d=Fr.MM.exec(n);if(d)return t=new Date(0),r=parseInt(d[1],10)-1,ow(e,r)?(t.setUTCFullYear(e,r),t):new Date(NaN);if(d=Fr.DDD.exec(n),d){t=new Date(0);const h=parseInt(d[1],10);return NM(e,h)?(t.setUTCFullYear(e,0,h),t):new Date(NaN)}if(d=Fr.MMDD.exec(n),d){t=new Date(0),r=parseInt(d[1],10)-1;const h=parseInt(d[2],10);return ow(e,r,h)?(t.setUTCFullYear(e,r,h),t):new Date(NaN)}if(d=Fr.Www.exec(n),d)return l=parseInt(d[1],10)-1,sw(l)?rw(e,l):new Date(NaN);if(d=Fr.WwwD.exec(n),d){l=parseInt(d[1],10)-1;const h=parseInt(d[2],10)-1;return sw(l,h)?rw(e,l,h):new Date(NaN)}return null}function LM(n){let e,t,r=Fr.HH.exec(n);if(r)return e=parseFloat(r[1].replace(",",".")),hf(e)?e%24*uf:NaN;if(r=Fr.HHMM.exec(n),r)return e=parseInt(r[1],10),t=parseFloat(r[2].replace(",",".")),hf(e,t)?e%24*uf+t*tw:NaN;if(r=Fr.HHMMSS.exec(n),r){e=parseInt(r[1],10),t=parseInt(r[2],10);const l=parseFloat(r[3].replace(",","."));return hf(e,t,l)?e%24*uf+t*tw+l*1e3:NaN}return null}function rw(n,e,t){e=e||0,t=t||0;const r=new Date(0);r.setUTCFullYear(n,0,4);const l=r.getUTCDay()||7,d=e*7+t+1-l;return r.setUTCDate(r.getUTCDate()+d),r}const OM=[31,28,31,30,31,30,31,31,30,31,30,31],IM=[31,29,31,30,31,30,31,31,30,31,30,31];function iw(n){return n%400===0||n%4===0&&n%100!==0}function ow(n,e,t){if(e<0||e>11)return!1;if(t!=null){if(t<1)return!1;const r=iw(n);if(r&&t>IM[e]||!r&&t>OM[e])return!1}return!0}function NM(n,e){if(e<1)return!1;const t=iw(n);return!(t&&e>366||!t&&e>365)}function sw(n,e){return!(n<0||n>52||e!=null&&(e<0||e>6))}function hf(n,e,t){return!(n<0||n>=25||e!=null&&(e<0||e>=60)||t!=null&&(t<0||t>=60))}const DM=/([xXOz]+)|''|'(''|[^'])+('|$)/g;function FM(n,e,t={}){e=String(e);const r=e.match(DM);if(r){const l=nw(t.originalDate||n,t);e=r.reduce(function(d,h){if(h[0]==="'")return d;const b=d.indexOf(h),p=d[b-1]==="'",g=d.replace(h,"'"+CM[h[0]](l,h,t)+"'");return p?g.substring(0,b-1)+g.substring(b+1):g},e)}return _s(n,e,t)}function PM(n,e,t){n=nw(n,t);const r=af(e,n,!0),l=new Date(n.getTime()-r),d=new Date(0);return d.setFullYear(l.getUTCFullYear(),l.getUTCMonth(),l.getUTCDate()),d.setHours(l.getUTCHours(),l.getUTCMinutes(),l.getUTCSeconds(),l.getUTCMilliseconds()),d}function eu(n,e,t,r){return r={...r,timeZone:e,originalDate:n},FM(PM(n,e,{timeZone:r.timeZone}),t,r)}const tu="yyyy-MM-dd",aw="HH:mm:ss.SSS",lw="HH:mm:ss",nu=`${tu} ${aw}`,cw=`${tu} ${lw}`,Sj=Pi("R",{methods:{parseDateTime(n,e){return n.includes(" ")&&(n=n.replace(" ","T")),e&&e==="UTC"&&(n+="Z"),Date.parse(n)},formatUtcToLocal(n,e){return _s(!e||e==="local"?uM(n,n.getTimezoneOffset()):n,nu)},formatDateTime(n,e){return!e||e==="local"?_s(n,nu):eu(n,e,nu)},formatDateTimeHMS(n,e){return!e||e==="local"?_s(n,cw):eu(n,e,cw)},formatDate:function(n,e){return!e||e==="local"?_s(n,tu):eu(n,this.timeZone,tu)},formatTime:function(n,e,t=aw){return!e||e==="local"?_s(n,t):eu(n,this.timeZone,t)},formatTimeHMS:function(n,e){return this.formatTime(n,e,lw)},formatTimestamp(n,e){return this.formatDateTime(GR(n),e)},formatSeconds(n,e){return this.formatDateTime(new Date(n*1e3),e)},formatNanoseconds(n,e){return this.formatDateTime(new Date(parseInt(n)/1e6),e)}}});var BM=Object.defineProperty,jM=(n,e,t)=>e in n?BM(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,Ze=(n,e,t)=>jM(n,typeof e!="symbol"?e+"":e,t);function df(n,e,t){const r=vn(n,t==null?void 0:t.in);return isNaN(e)?Kn((t==null?void 0:t.in)||n,NaN):(e&&r.setDate(r.getDate()+e),r)}function WM(n,e){const t=vn(n,void 0).getDay();return t===0?7:t}function zM(n,e){const t=HM(e)?new e(0):Kn(e,0);return t.setFullYear(n.getFullYear(),n.getMonth(),n.getDate()),t.setHours(n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()),t}function HM(n){var e;return typeof n=="function"&&((e=n.prototype)==null?void 0:e.constructor)===n}const UM=10;class uw{constructor(){Ze(this,"subPriority",0)}validate(e,t){return!0}}class qM extends uw{constructor(e,t,r,l,d){super(),this.value=e,this.validateValue=t,this.setValue=r,this.priority=l,d&&(this.subPriority=d)}validate(e,t){return this.validateValue(e,this.value,t)}set(e,t,r){return this.setValue(e,t,this.value,r)}}class VM extends uw{constructor(e,t){super(),Ze(this,"priority",UM),Ze(this,"subPriority",-1),this.context=e||(r=>Kn(t,r))}set(e,t){return t.timestampIsSet?e:Kn(e,zM(e,this.context))}}class Gt{run(e,t,r,l){const d=this.parse(e,t,r,l);return d?{setter:new qM(d.value,this.validate,this.set,this.priority,this.subPriority),rest:d.rest}:null}validate(e,t,r){return!0}}class KM extends Gt{constructor(){super(...arguments),Ze(this,"priority",140),Ze(this,"incompatibleTokens",["R","u","t","T"])}parse(e,t,r){switch(t){case"G":case"GG":case"GGG":return r.era(e,{width:"abbreviated"})||r.era(e,{width:"narrow"});case"GGGGG":return r.era(e,{width:"narrow"});case"GGGG":default:return r.era(e,{width:"wide"})||r.era(e,{width:"abbreviated"})||r.era(e,{width:"narrow"})}}set(e,t,r){return t.era=r,e.setFullYear(r,0,1),e.setHours(0,0,0,0),e}}const Fn={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},uo={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function Pn(n,e){return n&&{value:e(n.value),rest:n.rest}}function xn(n,e){const t=e.match(n);return t?{value:parseInt(t[0],10),rest:e.slice(t[0].length)}:null}function ho(n,e){const t=e.match(n);if(!t)return null;if(t[0]==="Z")return{value:0,rest:e.slice(1)};const r=t[1]==="+"?1:-1,l=t[2]?parseInt(t[2],10):0,d=t[3]?parseInt(t[3],10):0,h=t[5]?parseInt(t[5],10):0;return{value:r*(l*hh+d*sc+h*Ek),rest:e.slice(t[0].length)}}function hw(n){return xn(Fn.anyDigitsSigned,n)}function En(n,e){switch(n){case 1:return xn(Fn.singleDigit,e);case 2:return xn(Fn.twoDigits,e);case 3:return xn(Fn.threeDigits,e);case 4:return xn(Fn.fourDigits,e);default:return xn(new RegExp("^\\d{1,"+n+"}"),e)}}function dw(n,e){switch(n){case 1:return xn(Fn.singleDigitSigned,e);case 2:return xn(Fn.twoDigitsSigned,e);case 3:return xn(Fn.threeDigitsSigned,e);case 4:return xn(Fn.fourDigitsSigned,e);default:return xn(new RegExp("^-?\\d{1,"+n+"}"),e)}}function ff(n){switch(n){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function fw(n,e){const t=e>0,r=t?e:1-e;let l;if(r<=50)l=n||100;else{const d=r+50,h=Math.trunc(d/100)*100,b=n>=d%100;l=n+h-(b?100:0)}return t?l:1-l}function pw(n){return n%400===0||n%4===0&&n%100!==0}class GM extends Gt{constructor(){super(...arguments),Ze(this,"priority",130),Ze(this,"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"])}parse(e,t,r){const l=d=>({year:d,isTwoDigitYear:t==="yy"});switch(t){case"y":return Pn(En(4,e),l);case"yo":return Pn(r.ordinalNumber(e,{unit:"year"}),l);default:return Pn(En(t.length,e),l)}}validate(e,t){return t.isTwoDigitYear||t.year>0}set(e,t,r){const l=e.getFullYear();if(r.isTwoDigitYear){const h=fw(r.year,l);return e.setFullYear(h,0,1),e.setHours(0,0,0,0),e}const d=!("era"in t)||t.era===1?r.year:1-r.year;return e.setFullYear(d,0,1),e.setHours(0,0,0,0),e}}class YM extends Gt{constructor(){super(...arguments),Ze(this,"priority",130),Ze(this,"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"])}parse(e,t,r){const l=d=>({year:d,isTwoDigitYear:t==="YY"});switch(t){case"Y":return Pn(En(4,e),l);case"Yo":return Pn(r.ordinalNumber(e,{unit:"year"}),l);default:return Pn(En(t.length,e),l)}}validate(e,t){return t.isTwoDigitYear||t.year>0}set(e,t,r,l){const d=fh(e,l);if(r.isTwoDigitYear){const b=fw(r.year,d);return e.setFullYear(b,0,l.firstWeekContainsDate),e.setHours(0,0,0,0),Go(e,l)}const h=!("era"in t)||t.era===1?r.year:1-r.year;return e.setFullYear(h,0,l.firstWeekContainsDate),e.setHours(0,0,0,0),Go(e,l)}}class XM extends Gt{constructor(){super(...arguments),Ze(this,"priority",130),Ze(this,"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"])}parse(e,t){return dw(t==="R"?4:t.length,e)}set(e,t,r){const l=Kn(e,0);return l.setFullYear(r,0,4),l.setHours(0,0,0,0),ua(l)}}class QM extends Gt{constructor(){super(...arguments),Ze(this,"priority",130),Ze(this,"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"])}parse(e,t){return dw(t==="u"?4:t.length,e)}set(e,t,r){return e.setFullYear(r,0,1),e.setHours(0,0,0,0),e}}class ZM extends Gt{constructor(){super(...arguments),Ze(this,"priority",120),Ze(this,"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"])}parse(e,t,r){switch(t){case"Q":case"QQ":return En(t.length,e);case"Qo":return r.ordinalNumber(e,{unit:"quarter"});case"QQQ":return r.quarter(e,{width:"abbreviated",context:"formatting"})||r.quarter(e,{width:"narrow",context:"formatting"});case"QQQQQ":return r.quarter(e,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(e,{width:"wide",context:"formatting"})||r.quarter(e,{width:"abbreviated",context:"formatting"})||r.quarter(e,{width:"narrow",context:"formatting"})}}validate(e,t){return t>=1&&t<=4}set(e,t,r){return e.setMonth((r-1)*3,1),e.setHours(0,0,0,0),e}}class JM extends Gt{constructor(){super(...arguments),Ze(this,"priority",120),Ze(this,"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"])}parse(e,t,r){switch(t){case"q":case"qq":return En(t.length,e);case"qo":return r.ordinalNumber(e,{unit:"quarter"});case"qqq":return r.quarter(e,{width:"abbreviated",context:"standalone"})||r.quarter(e,{width:"narrow",context:"standalone"});case"qqqqq":return r.quarter(e,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(e,{width:"wide",context:"standalone"})||r.quarter(e,{width:"abbreviated",context:"standalone"})||r.quarter(e,{width:"narrow",context:"standalone"})}}validate(e,t){return t>=1&&t<=4}set(e,t,r){return e.setMonth((r-1)*3,1),e.setHours(0,0,0,0),e}}class eL extends Gt{constructor(){super(...arguments),Ze(this,"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),Ze(this,"priority",110)}parse(e,t,r){const l=d=>d-1;switch(t){case"M":return Pn(xn(Fn.month,e),l);case"MM":return Pn(En(2,e),l);case"Mo":return Pn(r.ordinalNumber(e,{unit:"month"}),l);case"MMM":return r.month(e,{width:"abbreviated",context:"formatting"})||r.month(e,{width:"narrow",context:"formatting"});case"MMMMM":return r.month(e,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(e,{width:"wide",context:"formatting"})||r.month(e,{width:"abbreviated",context:"formatting"})||r.month(e,{width:"narrow",context:"formatting"})}}validate(e,t){return t>=0&&t<=11}set(e,t,r){return e.setMonth(r,1),e.setHours(0,0,0,0),e}}class tL extends Gt{constructor(){super(...arguments),Ze(this,"priority",110),Ze(this,"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"])}parse(e,t,r){const l=d=>d-1;switch(t){case"L":return Pn(xn(Fn.month,e),l);case"LL":return Pn(En(2,e),l);case"Lo":return Pn(r.ordinalNumber(e,{unit:"month"}),l);case"LLL":return r.month(e,{width:"abbreviated",context:"standalone"})||r.month(e,{width:"narrow",context:"standalone"});case"LLLLL":return r.month(e,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(e,{width:"wide",context:"standalone"})||r.month(e,{width:"abbreviated",context:"standalone"})||r.month(e,{width:"narrow",context:"standalone"})}}validate(e,t){return t>=0&&t<=11}set(e,t,r){return e.setMonth(r,1),e.setHours(0,0,0,0),e}}function nL(n,e,t){const r=vn(n,t==null?void 0:t.in),l=vg(r,t)-e;return r.setDate(r.getDate()-l*7),vn(r,t==null?void 0:t.in)}class rL extends Gt{constructor(){super(...arguments),Ze(this,"priority",100),Ze(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"])}parse(e,t,r){switch(t){case"w":return xn(Fn.week,e);case"wo":return r.ordinalNumber(e,{unit:"week"});default:return En(t.length,e)}}validate(e,t){return t>=1&&t<=53}set(e,t,r,l){return Go(nL(e,r,l),l)}}function iL(n,e,t){const r=vn(n,void 0),l=mg(r)-e;return r.setDate(r.getDate()-l*7),r}class oL extends Gt{constructor(){super(...arguments),Ze(this,"priority",100),Ze(this,"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"])}parse(e,t,r){switch(t){case"I":return xn(Fn.week,e);case"Io":return r.ordinalNumber(e,{unit:"week"});default:return En(t.length,e)}}validate(e,t){return t>=1&&t<=53}set(e,t,r){return ua(iL(e,r))}}const sL=[31,28,31,30,31,30,31,31,30,31,30,31],aL=[31,29,31,30,31,30,31,31,30,31,30,31];class lL extends Gt{constructor(){super(...arguments),Ze(this,"priority",90),Ze(this,"subPriority",1),Ze(this,"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"])}parse(e,t,r){switch(t){case"d":return xn(Fn.date,e);case"do":return r.ordinalNumber(e,{unit:"date"});default:return En(t.length,e)}}validate(e,t){const r=e.getFullYear(),l=pw(r),d=e.getMonth();return l?t>=1&&t<=aL[d]:t>=1&&t<=sL[d]}set(e,t,r){return e.setDate(r),e.setHours(0,0,0,0),e}}class cL extends Gt{constructor(){super(...arguments),Ze(this,"priority",90),Ze(this,"subpriority",1),Ze(this,"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"])}parse(e,t,r){switch(t){case"D":case"DD":return xn(Fn.dayOfYear,e);case"Do":return r.ordinalNumber(e,{unit:"date"});default:return En(t.length,e)}}validate(e,t){const r=e.getFullYear();return pw(r)?t>=1&&t<=366:t>=1&&t<=365}set(e,t,r){return e.setMonth(0,r),e.setHours(0,0,0,0),e}}function pf(n,e,t){var r,l,d,h;const b=ca(),p=(t==null?void 0:t.weekStartsOn)??((l=(r=t==null?void 0:t.locale)==null?void 0:r.options)==null?void 0:l.weekStartsOn)??b.weekStartsOn??((h=(d=b.locale)==null?void 0:d.options)==null?void 0:h.weekStartsOn)??0,g=vn(n,t==null?void 0:t.in),o=g.getDay(),c=(e%7+7)%7,f=7-p,u=e<0||e>6?e-(o+f)%7:(c+f)%7-(o+f)%7;return df(g,u,t)}class uL extends Gt{constructor(){super(...arguments),Ze(this,"priority",90),Ze(this,"incompatibleTokens",["D","i","e","c","t","T"])}parse(e,t,r){switch(t){case"E":case"EE":case"EEE":return r.day(e,{width:"abbreviated",context:"formatting"})||r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"});case"EEEEE":return r.day(e,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"});case"EEEE":default:return r.day(e,{width:"wide",context:"formatting"})||r.day(e,{width:"abbreviated",context:"formatting"})||r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"})}}validate(e,t){return t>=0&&t<=6}set(e,t,r,l){return e=pf(e,r,l),e.setHours(0,0,0,0),e}}class hL extends Gt{constructor(){super(...arguments),Ze(this,"priority",90),Ze(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"])}parse(e,t,r,l){const d=h=>{const b=Math.floor((h-1)/7)*7;return(h+l.weekStartsOn+6)%7+b};switch(t){case"e":case"ee":return Pn(En(t.length,e),d);case"eo":return Pn(r.ordinalNumber(e,{unit:"day"}),d);case"eee":return r.day(e,{width:"abbreviated",context:"formatting"})||r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"});case"eeeee":return r.day(e,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"});case"eeee":default:return r.day(e,{width:"wide",context:"formatting"})||r.day(e,{width:"abbreviated",context:"formatting"})||r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"})}}validate(e,t){return t>=0&&t<=6}set(e,t,r,l){return e=pf(e,r,l),e.setHours(0,0,0,0),e}}class dL extends Gt{constructor(){super(...arguments),Ze(this,"priority",90),Ze(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"])}parse(e,t,r,l){const d=h=>{const b=Math.floor((h-1)/7)*7;return(h+l.weekStartsOn+6)%7+b};switch(t){case"c":case"cc":return Pn(En(t.length,e),d);case"co":return Pn(r.ordinalNumber(e,{unit:"day"}),d);case"ccc":return r.day(e,{width:"abbreviated",context:"standalone"})||r.day(e,{width:"short",context:"standalone"})||r.day(e,{width:"narrow",context:"standalone"});case"ccccc":return r.day(e,{width:"narrow",context:"standalone"});case"cccccc":return r.day(e,{width:"short",context:"standalone"})||r.day(e,{width:"narrow",context:"standalone"});case"cccc":default:return r.day(e,{width:"wide",context:"standalone"})||r.day(e,{width:"abbreviated",context:"standalone"})||r.day(e,{width:"short",context:"standalone"})||r.day(e,{width:"narrow",context:"standalone"})}}validate(e,t){return t>=0&&t<=6}set(e,t,r,l){return e=pf(e,r,l),e.setHours(0,0,0,0),e}}function fL(n,e,t){const r=vn(n,void 0),l=WM(r),d=e-l;return df(r,d,t)}class pL extends Gt{constructor(){super(...arguments),Ze(this,"priority",90),Ze(this,"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"])}parse(e,t,r){const l=d=>d===0?7:d;switch(t){case"i":case"ii":return En(t.length,e);case"io":return r.ordinalNumber(e,{unit:"day"});case"iii":return Pn(r.day(e,{width:"abbreviated",context:"formatting"})||r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"}),l);case"iiiii":return Pn(r.day(e,{width:"narrow",context:"formatting"}),l);case"iiiiii":return Pn(r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"}),l);case"iiii":default:return Pn(r.day(e,{width:"wide",context:"formatting"})||r.day(e,{width:"abbreviated",context:"formatting"})||r.day(e,{width:"short",context:"formatting"})||r.day(e,{width:"narrow",context:"formatting"}),l)}}validate(e,t){return t>=1&&t<=7}set(e,t,r){return e=fL(e,r),e.setHours(0,0,0,0),e}}class gL extends Gt{constructor(){super(...arguments),Ze(this,"priority",80),Ze(this,"incompatibleTokens",["b","B","H","k","t","T"])}parse(e,t,r){switch(t){case"a":case"aa":case"aaa":return r.dayPeriod(e,{width:"abbreviated",context:"formatting"})||r.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaaa":return r.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(e,{width:"wide",context:"formatting"})||r.dayPeriod(e,{width:"abbreviated",context:"formatting"})||r.dayPeriod(e,{width:"narrow",context:"formatting"})}}set(e,t,r){return e.setHours(ff(r),0,0,0),e}}class mL extends Gt{constructor(){super(...arguments),Ze(this,"priority",80),Ze(this,"incompatibleTokens",["a","B","H","k","t","T"])}parse(e,t,r){switch(t){case"b":case"bb":case"bbb":return r.dayPeriod(e,{width:"abbreviated",context:"formatting"})||r.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbbb":return r.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(e,{width:"wide",context:"formatting"})||r.dayPeriod(e,{width:"abbreviated",context:"formatting"})||r.dayPeriod(e,{width:"narrow",context:"formatting"})}}set(e,t,r){return e.setHours(ff(r),0,0,0),e}}class vL extends Gt{constructor(){super(...arguments),Ze(this,"priority",80),Ze(this,"incompatibleTokens",["a","b","t","T"])}parse(e,t,r){switch(t){case"B":case"BB":case"BBB":return r.dayPeriod(e,{width:"abbreviated",context:"formatting"})||r.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBBB":return r.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(e,{width:"wide",context:"formatting"})||r.dayPeriod(e,{width:"abbreviated",context:"formatting"})||r.dayPeriod(e,{width:"narrow",context:"formatting"})}}set(e,t,r){return e.setHours(ff(r),0,0,0),e}}class yL extends Gt{constructor(){super(...arguments),Ze(this,"priority",70),Ze(this,"incompatibleTokens",["H","K","k","t","T"])}parse(e,t,r){switch(t){case"h":return xn(Fn.hour12h,e);case"ho":return r.ordinalNumber(e,{unit:"hour"});default:return En(t.length,e)}}validate(e,t){return t>=1&&t<=12}set(e,t,r){const l=e.getHours()>=12;return l&&r<12?e.setHours(r+12,0,0,0):!l&&r===12?e.setHours(0,0,0,0):e.setHours(r,0,0,0),e}}class bL extends Gt{constructor(){super(...arguments),Ze(this,"priority",70),Ze(this,"incompatibleTokens",["a","b","h","K","k","t","T"])}parse(e,t,r){switch(t){case"H":return xn(Fn.hour23h,e);case"Ho":return r.ordinalNumber(e,{unit:"hour"});default:return En(t.length,e)}}validate(e,t){return t>=0&&t<=23}set(e,t,r){return e.setHours(r,0,0,0),e}}class wL extends Gt{constructor(){super(...arguments),Ze(this,"priority",70),Ze(this,"incompatibleTokens",["h","H","k","t","T"])}parse(e,t,r){switch(t){case"K":return xn(Fn.hour11h,e);case"Ko":return r.ordinalNumber(e,{unit:"hour"});default:return En(t.length,e)}}validate(e,t){return t>=0&&t<=11}set(e,t,r){return e.getHours()>=12&&r<12?e.setHours(r+12,0,0,0):e.setHours(r,0,0,0),e}}class xL extends Gt{constructor(){super(...arguments),Ze(this,"priority",70),Ze(this,"incompatibleTokens",["a","b","h","H","K","t","T"])}parse(e,t,r){switch(t){case"k":return xn(Fn.hour24h,e);case"ko":return r.ordinalNumber(e,{unit:"hour"});default:return En(t.length,e)}}validate(e,t){return t>=1&&t<=24}set(e,t,r){const l=r<=24?r%24:r;return e.setHours(l,0,0,0),e}}class kL extends Gt{constructor(){super(...arguments),Ze(this,"priority",60),Ze(this,"incompatibleTokens",["t","T"])}parse(e,t,r){switch(t){case"m":return xn(Fn.minute,e);case"mo":return r.ordinalNumber(e,{unit:"minute"});default:return En(t.length,e)}}validate(e,t){return t>=0&&t<=59}set(e,t,r){return e.setMinutes(r,0,0),e}}class SL extends Gt{constructor(){super(...arguments),Ze(this,"priority",50),Ze(this,"incompatibleTokens",["t","T"])}parse(e,t,r){switch(t){case"s":return xn(Fn.second,e);case"so":return r.ordinalNumber(e,{unit:"second"});default:return En(t.length,e)}}validate(e,t){return t>=0&&t<=59}set(e,t,r){return e.setSeconds(r,0),e}}class _L extends Gt{constructor(){super(...arguments),Ze(this,"priority",30),Ze(this,"incompatibleTokens",["t","T"])}parse(e,t){const r=l=>Math.trunc(l*Math.pow(10,-t.length+3));return Pn(En(t.length,e),r)}set(e,t,r){return e.setMilliseconds(r),e}}class CL extends Gt{constructor(){super(...arguments),Ze(this,"priority",10),Ze(this,"incompatibleTokens",["t","T","x"])}parse(e,t){switch(t){case"X":return ho(uo.basicOptionalMinutes,e);case"XX":return ho(uo.basic,e);case"XXXX":return ho(uo.basicOptionalSeconds,e);case"XXXXX":return ho(uo.extendedOptionalSeconds,e);case"XXX":default:return ho(uo.extended,e)}}set(e,t,r){return t.timestampIsSet?e:Kn(e,e.getTime()-ac(e)-r)}}class $L extends Gt{constructor(){super(...arguments),Ze(this,"priority",10),Ze(this,"incompatibleTokens",["t","T","X"])}parse(e,t){switch(t){case"x":return ho(uo.basicOptionalMinutes,e);case"xx":return ho(uo.basic,e);case"xxxx":return ho(uo.basicOptionalSeconds,e);case"xxxxx":return ho(uo.extendedOptionalSeconds,e);case"xxx":default:return ho(uo.extended,e)}}set(e,t,r){return t.timestampIsSet?e:Kn(e,e.getTime()-ac(e)-r)}}class AL extends Gt{constructor(){super(...arguments),Ze(this,"priority",40),Ze(this,"incompatibleTokens","*")}parse(e){return hw(e)}set(e,t,r){return[Kn(e,r*1e3),{timestampIsSet:!0}]}}class EL extends Gt{constructor(){super(...arguments),Ze(this,"priority",20),Ze(this,"incompatibleTokens","*")}parse(e){return hw(e)}set(e,t,r){return[Kn(e,r),{timestampIsSet:!0}]}}const TL={G:new KM,y:new GM,Y:new YM,R:new XM,u:new QM,Q:new ZM,q:new JM,M:new eL,L:new tL,w:new rL,I:new oL,d:new lL,D:new cL,E:new uL,e:new hL,c:new dL,i:new pL,a:new gL,b:new mL,B:new vL,h:new yL,H:new bL,K:new wL,k:new xL,m:new kL,s:new SL,S:new _L,X:new CL,x:new $L,t:new AL,T:new EL},RL=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,ML=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,LL=/^'([^]*?)'?$/,OL=/''/g,IL=/\S/,NL=/[a-zA-Z]/;function DL(n,e,t,r){var l,d,h,b;const p=()=>Kn(t,NaN),g=qb(),o=g.locale??gg,c=g.firstWeekContainsDate??((d=(l=g.locale)==null?void 0:l.options)==null?void 0:d.firstWeekContainsDate)??1,f=g.weekStartsOn??((b=(h=g.locale)==null?void 0:h.options)==null?void 0:b.weekStartsOn)??0;if(!e)return n?p():vn(t,void 0);const u={firstWeekContainsDate:c,weekStartsOn:f,locale:o},i=[new VM(void 0,t)],a=e.match(ML).map($=>{const S=$[0];if(S in ph){const k=ph[S];return k($,o.formatLong)}return $}).join("").match(RL),m=[];for(let $ of a){_g($)&&gh($,e,n),Sg($)&&gh($,e,n);const S=$[0],k=TL[S];if(k){const{incompatibleTokens:T}=k;if(Array.isArray(T)){const L=m.find(O=>T.includes(O.token)||O.token===S);if(L)throw new RangeError(`The format string mustn't contain \`${L.fullToken}\` and \`${$}\` at the same time`)}else if(k.incompatibleTokens==="*"&&m.length>0)throw new RangeError(`The format string mustn't contain \`${$}\` and any other token at the same time`);m.push({token:S,fullToken:$});const D=k.run(n,$,o.match,u);if(!D)return p();i.push(D.setter),n=D.rest}else{if(S.match(NL))throw new RangeError("Format string contains an unescaped latin alphabet character `"+S+"`");if($==="''"?$="'":S==="'"&&($=FL($)),n.indexOf($)===0)n=n.slice($.length);else return p()}}if(n.length>0&&IL.test(n))return p();const w=i.map($=>$.priority).sort(($,S)=>S-$).filter(($,S,k)=>k.indexOf($)===S).map($=>i.filter(S=>S.priority===$).sort((S,k)=>k.subPriority-S.subPriority)).map($=>$[0]);let x=vn(t,void 0);if(isNaN(+x))return p();const M={};for(const $ of w){if(!$.validate(x,u))return p();const S=$.set(x,M,u);Array.isArray(S)?(x=S[0],Object.assign(M,S[1])):x=S}return x}function FL(n){return n.match(LL)[1].replace(OL,"'")}function gw(n,e){return function(){return n.apply(e,arguments)}}const{toString:PL}=Object.prototype,{getPrototypeOf:gf}=Object,{iterator:ru,toStringTag:mw}=Symbol,iu=(n=>e=>{const t=PL.call(e);return n[t]||(n[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),Vi=n=>(n=n.toLowerCase(),e=>iu(e)===n),ou=n=>e=>typeof e===n,{isArray:Ra}=Array,Ma=ou("undefined");function Cl(n){return n!==null&&!Ma(n)&&n.constructor!==null&&!Ma(n.constructor)&&Jr(n.constructor.isBuffer)&&n.constructor.isBuffer(n)}const vw=Vi("ArrayBuffer");function BL(n){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(n):e=n&&n.buffer&&vw(n.buffer),e}const jL=ou("string"),Jr=ou("function"),yw=ou("number"),$l=n=>n!==null&&typeof n=="object",WL=n=>n===!0||n===!1,su=n=>{if(iu(n)!=="object")return!1;const e=gf(n);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(mw in n)&&!(ru in n)},zL=n=>{if(!$l(n)||Cl(n))return!1;try{return Object.keys(n).length===0&&Object.getPrototypeOf(n)===Object.prototype}catch{return!1}},HL=Vi("Date"),UL=Vi("File"),qL=Vi("Blob"),VL=Vi("FileList"),KL=n=>$l(n)&&Jr(n.pipe),GL=n=>{let e;return n&&(typeof FormData=="function"&&n instanceof FormData||Jr(n.append)&&((e=iu(n))==="formdata"||e==="object"&&Jr(n.toString)&&n.toString()==="[object FormData]"))},YL=Vi("URLSearchParams"),[XL,QL,ZL,JL]=["ReadableStream","Request","Response","Headers"].map(Vi),eO=n=>n.trim?n.trim():n.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Al(n,e,{allOwnKeys:t=!1}={}){if(n===null||typeof n>"u")return;let r,l;if(typeof n!="object"&&(n=[n]),Ra(n))for(r=0,l=n.length;r<l;r++)e.call(null,n[r],r,n);else{if(Cl(n))return;const d=t?Object.getOwnPropertyNames(n):Object.keys(n),h=d.length;let b;for(r=0;r<h;r++)b=d[r],e.call(null,n[b],b,n)}}function bw(n,e){if(Cl(n))return null;e=e.toLowerCase();const t=Object.keys(n);let r=t.length,l;for(;r-- >0;)if(l=t[r],e===l.toLowerCase())return l;return null}const Bs=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,ww=n=>!Ma(n)&&n!==Bs;function mf(){const{caseless:n,skipUndefined:e}=ww(this)&&this||{},t={},r=(l,d)=>{const h=n&&bw(t,d)||d;su(t[h])&&su(l)?t[h]=mf(t[h],l):su(l)?t[h]=mf({},l):Ra(l)?t[h]=l.slice():(!e||!Ma(l))&&(t[h]=l)};for(let l=0,d=arguments.length;l<d;l++)arguments[l]&&Al(arguments[l],r);return t}const tO=(n,e,t,{allOwnKeys:r}={})=>(Al(e,(l,d)=>{t&&Jr(l)?n[d]=gw(l,t):n[d]=l},{allOwnKeys:r}),n),nO=n=>(n.charCodeAt(0)===65279&&(n=n.slice(1)),n),rO=(n,e,t,r)=>{n.prototype=Object.create(e.prototype,r),n.prototype.constructor=n,Object.defineProperty(n,"super",{value:e.prototype}),t&&Object.assign(n.prototype,t)},iO=(n,e,t,r)=>{let l,d,h;const b={};if(e=e||{},n==null)return e;do{for(l=Object.getOwnPropertyNames(n),d=l.length;d-- >0;)h=l[d],(!r||r(h,n,e))&&!b[h]&&(e[h]=n[h],b[h]=!0);n=t!==!1&&gf(n)}while(n&&(!t||t(n,e))&&n!==Object.prototype);return e},oO=(n,e,t)=>{n=String(n),(t===void 0||t>n.length)&&(t=n.length),t-=e.length;const r=n.indexOf(e,t);return r!==-1&&r===t},sO=n=>{if(!n)return null;if(Ra(n))return n;let e=n.length;if(!yw(e))return null;const t=new Array(e);for(;e-- >0;)t[e]=n[e];return t},aO=(n=>e=>n&&e instanceof n)(typeof Uint8Array<"u"&&gf(Uint8Array)),lO=(n,e)=>{const r=(n&&n[ru]).call(n);let l;for(;(l=r.next())&&!l.done;){const d=l.value;e.call(n,d[0],d[1])}},cO=(n,e)=>{let t;const r=[];for(;(t=n.exec(e))!==null;)r.push(t);return r},uO=Vi("HTMLFormElement"),hO=n=>n.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(t,r,l){return r.toUpperCase()+l}),xw=(({hasOwnProperty:n})=>(e,t)=>n.call(e,t))(Object.prototype),dO=Vi("RegExp"),kw=(n,e)=>{const t=Object.getOwnPropertyDescriptors(n),r={};Al(t,(l,d)=>{let h;(h=e(l,d,n))!==!1&&(r[d]=h||l)}),Object.defineProperties(n,r)},fO=n=>{kw(n,(e,t)=>{if(Jr(n)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const r=n[t];if(Jr(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},pO=(n,e)=>{const t={},r=l=>{l.forEach(d=>{t[d]=!0})};return Ra(n)?r(n):r(String(n).split(e)),t},gO=()=>{},mO=(n,e)=>n!=null&&Number.isFinite(n=+n)?n:e;function vO(n){return!!(n&&Jr(n.append)&&n[mw]==="FormData"&&n[ru])}const yO=n=>{const e=new Array(10),t=(r,l)=>{if($l(r)){if(e.indexOf(r)>=0)return;if(Cl(r))return r;if(!("toJSON"in r)){e[l]=r;const d=Ra(r)?[]:{};return Al(r,(h,b)=>{const p=t(h,l+1);!Ma(p)&&(d[b]=p)}),e[l]=void 0,d}}return r};return t(n,0)},bO=Vi("AsyncFunction"),wO=n=>n&&($l(n)||Jr(n))&&Jr(n.then)&&Jr(n.catch),Sw=((n,e)=>n?setImmediate:e?((t,r)=>(Bs.addEventListener("message",({source:l,data:d})=>{l===Bs&&d===t&&r.length&&r.shift()()},!1),l=>{r.push(l),Bs.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",Jr(Bs.postMessage)),xO=typeof queueMicrotask<"u"?queueMicrotask.bind(Bs):typeof process<"u"&&process.nextTick||Sw,$e={isArray:Ra,isArrayBuffer:vw,isBuffer:Cl,isFormData:GL,isArrayBufferView:BL,isString:jL,isNumber:yw,isBoolean:WL,isObject:$l,isPlainObject:su,isEmptyObject:zL,isReadableStream:XL,isRequest:QL,isResponse:ZL,isHeaders:JL,isUndefined:Ma,isDate:HL,isFile:UL,isBlob:qL,isRegExp:dO,isFunction:Jr,isStream:KL,isURLSearchParams:YL,isTypedArray:aO,isFileList:VL,forEach:Al,merge:mf,extend:tO,trim:eO,stripBOM:nO,inherits:rO,toFlatObject:iO,kindOf:iu,kindOfTest:Vi,endsWith:oO,toArray:sO,forEachEntry:lO,matchAll:cO,isHTMLForm:uO,hasOwnProperty:xw,hasOwnProp:xw,reduceDescriptors:kw,freezeMethods:fO,toObjectSet:pO,toCamelCase:hO,noop:gO,toFiniteNumber:mO,findKey:bw,global:Bs,isContextDefined:ww,isSpecCompliantForm:vO,toJSONObject:yO,isAsyncFn:bO,isThenable:wO,setImmediate:Sw,asap:xO,isIterable:n=>n!=null&&Jr(n[ru])};function Ct(n,e,t,r,l){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=n,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),r&&(this.request=r),l&&(this.response=l,this.status=l.status?l.status:null)}$e.inherits(Ct,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:$e.toJSONObject(this.config),code:this.code,status:this.status}}});const _w=Ct.prototype,Cw={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(n=>{Cw[n]={value:n}}),Object.defineProperties(Ct,Cw),Object.defineProperty(_w,"isAxiosError",{value:!0}),Ct.from=(n,e,t,r,l,d)=>{const h=Object.create(_w);$e.toFlatObject(n,h,function(o){return o!==Error.prototype},g=>g!=="isAxiosError");const b=n&&n.message?n.message:"Error",p=e==null&&n?n.code:e;return Ct.call(h,b,p,t,r,l),n&&h.cause==null&&Object.defineProperty(h,"cause",{value:n,configurable:!0}),h.name=n&&n.name||"Error",d&&Object.assign(h,d),h};const kO=null;function vf(n){return $e.isPlainObject(n)||$e.isArray(n)}function $w(n){return $e.endsWith(n,"[]")?n.slice(0,-2):n}function Aw(n,e,t){return n?n.concat(e).map(function(l,d){return l=$w(l),!t&&d?"["+l+"]":l}).join(t?".":""):e}function SO(n){return $e.isArray(n)&&!n.some(vf)}const _O=$e.toFlatObject($e,{},null,function(e){return/^is[A-Z]/.test(e)});function au(n,e,t){if(!$e.isObject(n))throw new TypeError("target must be an object");e=e||new FormData,t=$e.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(a,m){return!$e.isUndefined(m[a])});const r=t.metaTokens,l=t.visitor||o,d=t.dots,h=t.indexes,p=(t.Blob||typeof Blob<"u"&&Blob)&&$e.isSpecCompliantForm(e);if(!$e.isFunction(l))throw new TypeError("visitor must be a function");function g(i){if(i===null)return"";if($e.isDate(i))return i.toISOString();if($e.isBoolean(i))return i.toString();if(!p&&$e.isBlob(i))throw new Ct("Blob is not supported. Use a Buffer instead.");return $e.isArrayBuffer(i)||$e.isTypedArray(i)?p&&typeof Blob=="function"?new Blob([i]):Buffer.from(i):i}function o(i,a,m){let w=i;if(i&&!m&&typeof i=="object"){if($e.endsWith(a,"{}"))a=r?a:a.slice(0,-2),i=JSON.stringify(i);else if($e.isArray(i)&&SO(i)||($e.isFileList(i)||$e.endsWith(a,"[]"))&&(w=$e.toArray(i)))return a=$w(a),w.forEach(function(M,$){!($e.isUndefined(M)||M===null)&&e.append(h===!0?Aw([a],$,d):h===null?a:a+"[]",g(M))}),!1}return vf(i)?!0:(e.append(Aw(m,a,d),g(i)),!1)}const c=[],f=Object.assign(_O,{defaultVisitor:o,convertValue:g,isVisitable:vf});function u(i,a){if(!$e.isUndefined(i)){if(c.indexOf(i)!==-1)throw Error("Circular reference detected in "+a.join("."));c.push(i),$e.forEach(i,function(w,x){(!($e.isUndefined(w)||w===null)&&l.call(e,w,$e.isString(x)?x.trim():x,a,f))===!0&&u(w,a?a.concat(x):[x])}),c.pop()}}if(!$e.isObject(n))throw new TypeError("data must be an object");return u(n),e}function Ew(n){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(n).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function yf(n,e){this._pairs=[],n&&au(n,this,e)}const Tw=yf.prototype;Tw.append=function(e,t){this._pairs.push([e,t])},Tw.toString=function(e){const t=e?function(r){return e.call(this,r,Ew)}:Ew;return this._pairs.map(function(l){return t(l[0])+"="+t(l[1])},"").join("&")};function CO(n){return encodeURIComponent(n).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Rw(n,e,t){if(!e)return n;const r=t&&t.encode||CO;$e.isFunction(t)&&(t={serialize:t});const l=t&&t.serialize;let d;if(l?d=l(e,t):d=$e.isURLSearchParams(e)?e.toString():new yf(e,t).toString(r),d){const h=n.indexOf("#");h!==-1&&(n=n.slice(0,h)),n+=(n.indexOf("?")===-1?"?":"&")+d}return n}class Mw{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){$e.forEach(this.handlers,function(r){r!==null&&e(r)})}}const Lw={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},$O={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:yf,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},bf=typeof window<"u"&&typeof document<"u",wf=typeof navigator=="object"&&navigator||void 0,AO=bf&&(!wf||["ReactNative","NativeScript","NS"].indexOf(wf.product)<0),EO=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",TO=bf&&window.location.href||"http://localhost",Cr={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:bf,hasStandardBrowserEnv:AO,hasStandardBrowserWebWorkerEnv:EO,navigator:wf,origin:TO},Symbol.toStringTag,{value:"Module"})),...$O};function RO(n,e){return au(n,new Cr.classes.URLSearchParams,{visitor:function(t,r,l,d){return Cr.isNode&&$e.isBuffer(t)?(this.append(r,t.toString("base64")),!1):d.defaultVisitor.apply(this,arguments)},...e})}function MO(n){return $e.matchAll(/\w+|\[(\w*)]/g,n).map(e=>e[0]==="[]"?"":e[1]||e[0])}function LO(n){const e={},t=Object.keys(n);let r;const l=t.length;let d;for(r=0;r<l;r++)d=t[r],e[d]=n[d];return e}function Ow(n){function e(t,r,l,d){let h=t[d++];if(h==="__proto__")return!0;const b=Number.isFinite(+h),p=d>=t.length;return h=!h&&$e.isArray(l)?l.length:h,p?($e.hasOwnProp(l,h)?l[h]=[l[h],r]:l[h]=r,!b):((!l[h]||!$e.isObject(l[h]))&&(l[h]=[]),e(t,r,l[h],d)&&$e.isArray(l[h])&&(l[h]=LO(l[h])),!b)}if($e.isFormData(n)&&$e.isFunction(n.entries)){const t={};return $e.forEachEntry(n,(r,l)=>{e(MO(r),l,t,0)}),t}return null}function OO(n,e,t){if($e.isString(n))try{return(e||JSON.parse)(n),$e.trim(n)}catch(r){if(r.name!=="SyntaxError")throw r}return(t||JSON.stringify)(n)}const El={transitional:Lw,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const r=t.getContentType()||"",l=r.indexOf("application/json")>-1,d=$e.isObject(e);if(d&&$e.isHTMLForm(e)&&(e=new FormData(e)),$e.isFormData(e))return l?JSON.stringify(Ow(e)):e;if($e.isArrayBuffer(e)||$e.isBuffer(e)||$e.isStream(e)||$e.isFile(e)||$e.isBlob(e)||$e.isReadableStream(e))return e;if($e.isArrayBufferView(e))return e.buffer;if($e.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let b;if(d){if(r.indexOf("application/x-www-form-urlencoded")>-1)return RO(e,this.formSerializer).toString();if((b=$e.isFileList(e))||r.indexOf("multipart/form-data")>-1){const p=this.env&&this.env.FormData;return au(b?{"files[]":e}:e,p&&new p,this.formSerializer)}}return d||l?(t.setContentType("application/json",!1),OO(e)):e}],transformResponse:[function(e){const t=this.transitional||El.transitional,r=t&&t.forcedJSONParsing,l=this.responseType==="json";if($e.isResponse(e)||$e.isReadableStream(e))return e;if(e&&$e.isString(e)&&(r&&!this.responseType||l)){const h=!(t&&t.silentJSONParsing)&&l;try{return JSON.parse(e,this.parseReviver)}catch(b){if(h)throw b.name==="SyntaxError"?Ct.from(b,Ct.ERR_BAD_RESPONSE,this,null,this.response):b}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Cr.classes.FormData,Blob:Cr.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};$e.forEach(["delete","get","head","post","put","patch"],n=>{El.headers[n]={}});const IO=$e.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),NO=n=>{const e={};let t,r,l;return n&&n.split(`
|
|
1502
|
+
`).forEach(function(h){l=h.indexOf(":"),t=h.substring(0,l).trim().toLowerCase(),r=h.substring(l+1).trim(),!(!t||e[t]&&IO[t])&&(t==="set-cookie"?e[t]?e[t].push(r):e[t]=[r]:e[t]=e[t]?e[t]+", "+r:r)}),e},Iw=Symbol("internals");function Tl(n){return n&&String(n).trim().toLowerCase()}function lu(n){return n===!1||n==null?n:$e.isArray(n)?n.map(lu):String(n)}function DO(n){const e=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=t.exec(n);)e[r[1]]=r[2];return e}const FO=n=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(n.trim());function xf(n,e,t,r,l){if($e.isFunction(r))return r.call(this,e,t);if(l&&(e=t),!!$e.isString(e)){if($e.isString(r))return e.indexOf(r)!==-1;if($e.isRegExp(r))return r.test(e)}}function PO(n){return n.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r)}function BO(n,e){const t=$e.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(n,r+t,{value:function(l,d,h){return this[r].call(this,e,l,d,h)},configurable:!0})})}let ei=class{constructor(e){e&&this.set(e)}set(e,t,r){const l=this;function d(b,p,g){const o=Tl(p);if(!o)throw new Error("header name must be a non-empty string");const c=$e.findKey(l,o);(!c||l[c]===void 0||g===!0||g===void 0&&l[c]!==!1)&&(l[c||p]=lu(b))}const h=(b,p)=>$e.forEach(b,(g,o)=>d(g,o,p));if($e.isPlainObject(e)||e instanceof this.constructor)h(e,t);else if($e.isString(e)&&(e=e.trim())&&!FO(e))h(NO(e),t);else if($e.isObject(e)&&$e.isIterable(e)){let b={},p,g;for(const o of e){if(!$e.isArray(o))throw TypeError("Object iterator must return a key-value pair");b[g=o[0]]=(p=b[g])?$e.isArray(p)?[...p,o[1]]:[p,o[1]]:o[1]}h(b,t)}else e!=null&&d(t,e,r);return this}get(e,t){if(e=Tl(e),e){const r=$e.findKey(this,e);if(r){const l=this[r];if(!t)return l;if(t===!0)return DO(l);if($e.isFunction(t))return t.call(this,l,r);if($e.isRegExp(t))return t.exec(l);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Tl(e),e){const r=$e.findKey(this,e);return!!(r&&this[r]!==void 0&&(!t||xf(this,this[r],r,t)))}return!1}delete(e,t){const r=this;let l=!1;function d(h){if(h=Tl(h),h){const b=$e.findKey(r,h);b&&(!t||xf(r,r[b],b,t))&&(delete r[b],l=!0)}}return $e.isArray(e)?e.forEach(d):d(e),l}clear(e){const t=Object.keys(this);let r=t.length,l=!1;for(;r--;){const d=t[r];(!e||xf(this,this[d],d,e,!0))&&(delete this[d],l=!0)}return l}normalize(e){const t=this,r={};return $e.forEach(this,(l,d)=>{const h=$e.findKey(r,d);if(h){t[h]=lu(l),delete t[d];return}const b=e?PO(d):String(d).trim();b!==d&&delete t[d],t[b]=lu(l),r[b]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return $e.forEach(this,(r,l)=>{r!=null&&r!==!1&&(t[l]=e&&$e.isArray(r)?r.join(", "):r)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join(`
|
|
1503
|
+
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const r=new this(e);return t.forEach(l=>r.set(l)),r}static accessor(e){const r=(this[Iw]=this[Iw]={accessors:{}}).accessors,l=this.prototype;function d(h){const b=Tl(h);r[b]||(BO(l,h),r[b]=!0)}return $e.isArray(e)?e.forEach(d):d(e),this}};ei.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),$e.reduceDescriptors(ei.prototype,({value:n},e)=>{let t=e[0].toUpperCase()+e.slice(1);return{get:()=>n,set(r){this[t]=r}}}),$e.freezeMethods(ei);function kf(n,e){const t=this||El,r=e||t,l=ei.from(r.headers);let d=r.data;return $e.forEach(n,function(b){d=b.call(t,d,l.normalize(),e?e.status:void 0)}),l.normalize(),d}function Nw(n){return!!(n&&n.__CANCEL__)}function La(n,e,t){Ct.call(this,n??"canceled",Ct.ERR_CANCELED,e,t),this.name="CanceledError"}$e.inherits(La,Ct,{__CANCEL__:!0});function Dw(n,e,t){const r=t.config.validateStatus;!t.status||!r||r(t.status)?n(t):e(new Ct("Request failed with status code "+t.status,[Ct.ERR_BAD_REQUEST,Ct.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function jO(n){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(n);return e&&e[1]||""}function WO(n,e){n=n||10;const t=new Array(n),r=new Array(n);let l=0,d=0,h;return e=e!==void 0?e:1e3,function(p){const g=Date.now(),o=r[d];h||(h=g),t[l]=p,r[l]=g;let c=d,f=0;for(;c!==l;)f+=t[c++],c=c%n;if(l=(l+1)%n,l===d&&(d=(d+1)%n),g-h<e)return;const u=o&&g-o;return u?Math.round(f*1e3/u):void 0}}function zO(n,e){let t=0,r=1e3/e,l,d;const h=(g,o=Date.now())=>{t=o,l=null,d&&(clearTimeout(d),d=null),n(...g)};return[(...g)=>{const o=Date.now(),c=o-t;c>=r?h(g,o):(l=g,d||(d=setTimeout(()=>{d=null,h(l)},r-c)))},()=>l&&h(l)]}const cu=(n,e,t=3)=>{let r=0;const l=WO(50,250);return zO(d=>{const h=d.loaded,b=d.lengthComputable?d.total:void 0,p=h-r,g=l(p),o=h<=b;r=h;const c={loaded:h,total:b,progress:b?h/b:void 0,bytes:p,rate:g||void 0,estimated:g&&b&&o?(b-h)/g:void 0,event:d,lengthComputable:b!=null,[e?"download":"upload"]:!0};n(c)},t)},Fw=(n,e)=>{const t=n!=null;return[r=>e[0]({lengthComputable:t,total:n,loaded:r}),e[1]]},Pw=n=>(...e)=>$e.asap(()=>n(...e)),HO=Cr.hasStandardBrowserEnv?((n,e)=>t=>(t=new URL(t,Cr.origin),n.protocol===t.protocol&&n.host===t.host&&(e||n.port===t.port)))(new URL(Cr.origin),Cr.navigator&&/(msie|trident)/i.test(Cr.navigator.userAgent)):()=>!0,UO=Cr.hasStandardBrowserEnv?{write(n,e,t,r,l,d,h){if(typeof document>"u")return;const b=[`${n}=${encodeURIComponent(e)}`];$e.isNumber(t)&&b.push(`expires=${new Date(t).toUTCString()}`),$e.isString(r)&&b.push(`path=${r}`),$e.isString(l)&&b.push(`domain=${l}`),d===!0&&b.push("secure"),$e.isString(h)&&b.push(`SameSite=${h}`),document.cookie=b.join("; ")},read(n){if(typeof document>"u")return null;const e=document.cookie.match(new RegExp("(?:^|; )"+n+"=([^;]*)"));return e?decodeURIComponent(e[1]):null},remove(n){this.write(n,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function qO(n){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(n)}function VO(n,e){return e?n.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):n}function Bw(n,e,t){let r=!qO(e);return n&&(r||t==!1)?VO(n,e):e}const jw=n=>n instanceof ei?{...n}:n;function js(n,e){e=e||{};const t={};function r(g,o,c,f){return $e.isPlainObject(g)&&$e.isPlainObject(o)?$e.merge.call({caseless:f},g,o):$e.isPlainObject(o)?$e.merge({},o):$e.isArray(o)?o.slice():o}function l(g,o,c,f){if($e.isUndefined(o)){if(!$e.isUndefined(g))return r(void 0,g,c,f)}else return r(g,o,c,f)}function d(g,o){if(!$e.isUndefined(o))return r(void 0,o)}function h(g,o){if($e.isUndefined(o)){if(!$e.isUndefined(g))return r(void 0,g)}else return r(void 0,o)}function b(g,o,c){if(c in e)return r(g,o);if(c in n)return r(void 0,g)}const p={url:d,method:d,data:d,baseURL:h,transformRequest:h,transformResponse:h,paramsSerializer:h,timeout:h,timeoutMessage:h,withCredentials:h,withXSRFToken:h,adapter:h,responseType:h,xsrfCookieName:h,xsrfHeaderName:h,onUploadProgress:h,onDownloadProgress:h,decompress:h,maxContentLength:h,maxBodyLength:h,beforeRedirect:h,transport:h,httpAgent:h,httpsAgent:h,cancelToken:h,socketPath:h,responseEncoding:h,validateStatus:b,headers:(g,o,c)=>l(jw(g),jw(o),c,!0)};return $e.forEach(Object.keys({...n,...e}),function(o){const c=p[o]||l,f=c(n[o],e[o],o);$e.isUndefined(f)&&c!==b||(t[o]=f)}),t}const Ww=n=>{const e=js({},n);let{data:t,withXSRFToken:r,xsrfHeaderName:l,xsrfCookieName:d,headers:h,auth:b}=e;if(e.headers=h=ei.from(h),e.url=Rw(Bw(e.baseURL,e.url,e.allowAbsoluteUrls),n.params,n.paramsSerializer),b&&h.set("Authorization","Basic "+btoa((b.username||"")+":"+(b.password?unescape(encodeURIComponent(b.password)):""))),$e.isFormData(t)){if(Cr.hasStandardBrowserEnv||Cr.hasStandardBrowserWebWorkerEnv)h.setContentType(void 0);else if($e.isFunction(t.getHeaders)){const p=t.getHeaders(),g=["content-type","content-length"];Object.entries(p).forEach(([o,c])=>{g.includes(o.toLowerCase())&&h.set(o,c)})}}if(Cr.hasStandardBrowserEnv&&(r&&$e.isFunction(r)&&(r=r(e)),r||r!==!1&&HO(e.url))){const p=l&&d&&UO.read(d);p&&h.set(l,p)}return e},KO=typeof XMLHttpRequest<"u"&&function(n){return new Promise(function(t,r){const l=Ww(n);let d=l.data;const h=ei.from(l.headers).normalize();let{responseType:b,onUploadProgress:p,onDownloadProgress:g}=l,o,c,f,u,i;function a(){u&&u(),i&&i(),l.cancelToken&&l.cancelToken.unsubscribe(o),l.signal&&l.signal.removeEventListener("abort",o)}let m=new XMLHttpRequest;m.open(l.method.toUpperCase(),l.url,!0),m.timeout=l.timeout;function w(){if(!m)return;const M=ei.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),S={data:!b||b==="text"||b==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:M,config:n,request:m};Dw(function(T){t(T),a()},function(T){r(T),a()},S),m=null}"onloadend"in m?m.onloadend=w:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.indexOf("file:")===0)||setTimeout(w)},m.onabort=function(){m&&(r(new Ct("Request aborted",Ct.ECONNABORTED,n,m)),m=null)},m.onerror=function($){const S=$&&$.message?$.message:"Network Error",k=new Ct(S,Ct.ERR_NETWORK,n,m);k.event=$||null,r(k),m=null},m.ontimeout=function(){let $=l.timeout?"timeout of "+l.timeout+"ms exceeded":"timeout exceeded";const S=l.transitional||Lw;l.timeoutErrorMessage&&($=l.timeoutErrorMessage),r(new Ct($,S.clarifyTimeoutError?Ct.ETIMEDOUT:Ct.ECONNABORTED,n,m)),m=null},d===void 0&&h.setContentType(null),"setRequestHeader"in m&&$e.forEach(h.toJSON(),function($,S){m.setRequestHeader(S,$)}),$e.isUndefined(l.withCredentials)||(m.withCredentials=!!l.withCredentials),b&&b!=="json"&&(m.responseType=l.responseType),g&&([f,i]=cu(g,!0),m.addEventListener("progress",f)),p&&m.upload&&([c,u]=cu(p),m.upload.addEventListener("progress",c),m.upload.addEventListener("loadend",u)),(l.cancelToken||l.signal)&&(o=M=>{m&&(r(!M||M.type?new La(null,n,m):M),m.abort(),m=null)},l.cancelToken&&l.cancelToken.subscribe(o),l.signal&&(l.signal.aborted?o():l.signal.addEventListener("abort",o)));const x=jO(l.url);if(x&&Cr.protocols.indexOf(x)===-1){r(new Ct("Unsupported protocol "+x+":",Ct.ERR_BAD_REQUEST,n));return}m.send(d||null)})},GO=(n,e)=>{const{length:t}=n=n?n.filter(Boolean):[];if(e||t){let r=new AbortController,l;const d=function(g){if(!l){l=!0,b();const o=g instanceof Error?g:this.reason;r.abort(o instanceof Ct?o:new La(o instanceof Error?o.message:o))}};let h=e&&setTimeout(()=>{h=null,d(new Ct(`timeout ${e} of ms exceeded`,Ct.ETIMEDOUT))},e);const b=()=>{n&&(h&&clearTimeout(h),h=null,n.forEach(g=>{g.unsubscribe?g.unsubscribe(d):g.removeEventListener("abort",d)}),n=null)};n.forEach(g=>g.addEventListener("abort",d));const{signal:p}=r;return p.unsubscribe=()=>$e.asap(b),p}},YO=function*(n,e){let t=n.byteLength;if(t<e){yield n;return}let r=0,l;for(;r<t;)l=r+e,yield n.slice(r,l),r=l},XO=async function*(n,e){for await(const t of QO(n))yield*YO(t,e)},QO=async function*(n){if(n[Symbol.asyncIterator]){yield*n;return}const e=n.getReader();try{for(;;){const{done:t,value:r}=await e.read();if(t)break;yield r}}finally{await e.cancel()}},zw=(n,e,t,r)=>{const l=XO(n,e);let d=0,h,b=p=>{h||(h=!0,r&&r(p))};return new ReadableStream({async pull(p){try{const{done:g,value:o}=await l.next();if(g){b(),p.close();return}let c=o.byteLength;if(t){let f=d+=c;t(f)}p.enqueue(new Uint8Array(o))}catch(g){throw b(g),g}},cancel(p){return b(p),l.return()}},{highWaterMark:2})},Hw=64*1024,{isFunction:uu}=$e,ZO=(({Request:n,Response:e})=>({Request:n,Response:e}))($e.global),{ReadableStream:Uw,TextEncoder:qw}=$e.global,Vw=(n,...e)=>{try{return!!n(...e)}catch{return!1}},JO=n=>{n=$e.merge.call({skipUndefined:!0},ZO,n);const{fetch:e,Request:t,Response:r}=n,l=e?uu(e):typeof fetch=="function",d=uu(t),h=uu(r);if(!l)return!1;const b=l&&uu(Uw),p=l&&(typeof qw=="function"?(i=>a=>i.encode(a))(new qw):async i=>new Uint8Array(await new t(i).arrayBuffer())),g=d&&b&&Vw(()=>{let i=!1;const a=new t(Cr.origin,{body:new Uw,method:"POST",get duplex(){return i=!0,"half"}}).headers.has("Content-Type");return i&&!a}),o=h&&b&&Vw(()=>$e.isReadableStream(new r("").body)),c={stream:o&&(i=>i.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(i=>{!c[i]&&(c[i]=(a,m)=>{let w=a&&a[i];if(w)return w.call(a);throw new Ct(`Response type '${i}' is not supported`,Ct.ERR_NOT_SUPPORT,m)})});const f=async i=>{if(i==null)return 0;if($e.isBlob(i))return i.size;if($e.isSpecCompliantForm(i))return(await new t(Cr.origin,{method:"POST",body:i}).arrayBuffer()).byteLength;if($e.isArrayBufferView(i)||$e.isArrayBuffer(i))return i.byteLength;if($e.isURLSearchParams(i)&&(i=i+""),$e.isString(i))return(await p(i)).byteLength},u=async(i,a)=>{const m=$e.toFiniteNumber(i.getContentLength());return m??f(a)};return async i=>{let{url:a,method:m,data:w,signal:x,cancelToken:M,timeout:$,onDownloadProgress:S,onUploadProgress:k,responseType:T,headers:D,withCredentials:L="same-origin",fetchOptions:O}=Ww(i),z=e||fetch;T=T?(T+"").toLowerCase():"text";let P=GO([x,M&&M.toAbortSignal()],$),N=null;const A=P&&P.unsubscribe&&(()=>{P.unsubscribe()});let _;try{if(k&&g&&m!=="get"&&m!=="head"&&(_=await u(D,w))!==0){let J=new t(a,{method:"POST",body:w,duplex:"half"}),ae;if($e.isFormData(w)&&(ae=J.headers.get("content-type"))&&D.setContentType(ae),J.body){const[ne,se]=Fw(_,cu(Pw(k)));w=zw(J.body,Hw,ne,se)}}$e.isString(L)||(L=L?"include":"omit");const I=d&&"credentials"in t.prototype,j={...O,signal:P,method:m.toUpperCase(),headers:D.normalize().toJSON(),body:w,duplex:"half",credentials:I?L:void 0};N=d&&new t(a,j);let U=await(d?z(N,O):z(a,j));const K=o&&(T==="stream"||T==="response");if(o&&(S||K&&A)){const J={};["status","statusText","headers"].forEach(ce=>{J[ce]=U[ce]});const ae=$e.toFiniteNumber(U.headers.get("content-length")),[ne,se]=S&&Fw(ae,cu(Pw(S),!0))||[];U=new r(zw(U.body,Hw,ne,()=>{se&&se(),A&&A()}),J)}T=T||"text";let Z=await c[$e.findKey(c,T)||"text"](U,i);return!K&&A&&A(),await new Promise((J,ae)=>{Dw(J,ae,{data:Z,headers:ei.from(U.headers),status:U.status,statusText:U.statusText,config:i,request:N})})}catch(I){throw A&&A(),I&&I.name==="TypeError"&&/Load failed|fetch/i.test(I.message)?Object.assign(new Ct("Network Error",Ct.ERR_NETWORK,i,N),{cause:I.cause||I}):Ct.from(I,I&&I.code,i,N)}}},eI=new Map,Kw=n=>{let e=n&&n.env||{};const{fetch:t,Request:r,Response:l}=e,d=[r,l,t];let h=d.length,b=h,p,g,o=eI;for(;b--;)p=d[b],g=o.get(p),g===void 0&&o.set(p,g=b?new Map:JO(e)),o=g;return g};Kw();const Sf={http:kO,xhr:KO,fetch:{get:Kw}};$e.forEach(Sf,(n,e)=>{if(n){try{Object.defineProperty(n,"name",{value:e})}catch{}Object.defineProperty(n,"adapterName",{value:e})}});const Gw=n=>`- ${n}`,tI=n=>$e.isFunction(n)||n===null||n===!1;function nI(n,e){n=$e.isArray(n)?n:[n];const{length:t}=n;let r,l;const d={};for(let h=0;h<t;h++){r=n[h];let b;if(l=r,!tI(r)&&(l=Sf[(b=String(r)).toLowerCase()],l===void 0))throw new Ct(`Unknown adapter '${b}'`);if(l&&($e.isFunction(l)||(l=l.get(e))))break;d[b||"#"+h]=l}if(!l){const h=Object.entries(d).map(([p,g])=>`adapter ${p} `+(g===!1?"is not supported by the environment":"is not available in the build"));let b=t?h.length>1?`since :
|
|
1504
|
+
`+h.map(Gw).join(`
|
|
1505
|
+
`):" "+Gw(h[0]):"as no adapter specified";throw new Ct("There is no suitable adapter to dispatch the request "+b,"ERR_NOT_SUPPORT")}return l}const Yw={getAdapter:nI,adapters:Sf};function _f(n){if(n.cancelToken&&n.cancelToken.throwIfRequested(),n.signal&&n.signal.aborted)throw new La(null,n)}function Xw(n){return _f(n),n.headers=ei.from(n.headers),n.data=kf.call(n,n.transformRequest),["post","put","patch"].indexOf(n.method)!==-1&&n.headers.setContentType("application/x-www-form-urlencoded",!1),Yw.getAdapter(n.adapter||El.adapter,n)(n).then(function(r){return _f(n),r.data=kf.call(n,n.transformResponse,r),r.headers=ei.from(r.headers),r},function(r){return Nw(r)||(_f(n),r&&r.response&&(r.response.data=kf.call(n,n.transformResponse,r.response),r.response.headers=ei.from(r.response.headers))),Promise.reject(r)})}const Qw="1.13.1",hu={};["object","boolean","number","function","string","symbol"].forEach((n,e)=>{hu[n]=function(r){return typeof r===n||"a"+(e<1?"n ":" ")+n}});const Zw={};hu.transitional=function(e,t,r){function l(d,h){return"[Axios v"+Qw+"] Transitional option '"+d+"'"+h+(r?". "+r:"")}return(d,h,b)=>{if(e===!1)throw new Ct(l(h," has been removed"+(t?" in "+t:"")),Ct.ERR_DEPRECATED);return t&&!Zw[h]&&(Zw[h]=!0,console.warn(l(h," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(d,h,b):!0}},hu.spelling=function(e){return(t,r)=>(console.warn(`${r} is likely a misspelling of ${e}`),!0)};function rI(n,e,t){if(typeof n!="object")throw new Ct("options must be an object",Ct.ERR_BAD_OPTION_VALUE);const r=Object.keys(n);let l=r.length;for(;l-- >0;){const d=r[l],h=e[d];if(h){const b=n[d],p=b===void 0||h(b,d,n);if(p!==!0)throw new Ct("option "+d+" must be "+p,Ct.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new Ct("Unknown option "+d,Ct.ERR_BAD_OPTION)}}const du={assertOptions:rI,validators:hu},fo=du.validators;let Ws=class{constructor(e){this.defaults=e||{},this.interceptors={request:new Mw,response:new Mw}}async request(e,t){try{return await this._request(e,t)}catch(r){if(r instanceof Error){let l={};Error.captureStackTrace?Error.captureStackTrace(l):l=new Error;const d=l.stack?l.stack.replace(/^.+\n/,""):"";try{r.stack?d&&!String(r.stack).endsWith(d.replace(/^.+\n.+\n/,""))&&(r.stack+=`
|
|
1506
|
+
`+d):r.stack=d}catch{}}throw r}}_request(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=js(this.defaults,t);const{transitional:r,paramsSerializer:l,headers:d}=t;r!==void 0&&du.assertOptions(r,{silentJSONParsing:fo.transitional(fo.boolean),forcedJSONParsing:fo.transitional(fo.boolean),clarifyTimeoutError:fo.transitional(fo.boolean)},!1),l!=null&&($e.isFunction(l)?t.paramsSerializer={serialize:l}:du.assertOptions(l,{encode:fo.function,serialize:fo.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),du.assertOptions(t,{baseUrl:fo.spelling("baseURL"),withXsrfToken:fo.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let h=d&&$e.merge(d.common,d[t.method]);d&&$e.forEach(["delete","get","head","post","put","patch","common"],i=>{delete d[i]}),t.headers=ei.concat(h,d);const b=[];let p=!0;this.interceptors.request.forEach(function(a){typeof a.runWhen=="function"&&a.runWhen(t)===!1||(p=p&&a.synchronous,b.unshift(a.fulfilled,a.rejected))});const g=[];this.interceptors.response.forEach(function(a){g.push(a.fulfilled,a.rejected)});let o,c=0,f;if(!p){const i=[Xw.bind(this),void 0];for(i.unshift(...b),i.push(...g),f=i.length,o=Promise.resolve(t);c<f;)o=o.then(i[c++],i[c++]);return o}f=b.length;let u=t;for(;c<f;){const i=b[c++],a=b[c++];try{u=i(u)}catch(m){a.call(this,m);break}}try{o=Xw.call(this,u)}catch(i){return Promise.reject(i)}for(c=0,f=g.length;c<f;)o=o.then(g[c++],g[c++]);return o}getUri(e){e=js(this.defaults,e);const t=Bw(e.baseURL,e.url,e.allowAbsoluteUrls);return Rw(t,e.params,e.paramsSerializer)}};$e.forEach(["delete","get","head","options"],function(e){Ws.prototype[e]=function(t,r){return this.request(js(r||{},{method:e,url:t,data:(r||{}).data}))}}),$e.forEach(["post","put","patch"],function(e){function t(r){return function(d,h,b){return this.request(js(b||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:d,data:h}))}}Ws.prototype[e]=t(),Ws.prototype[e+"Form"]=t(!0)});let iI=class Vx{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(d){t=d});const r=this;this.promise.then(l=>{if(!r._listeners)return;let d=r._listeners.length;for(;d-- >0;)r._listeners[d](l);r._listeners=null}),this.promise.then=l=>{let d;const h=new Promise(b=>{r.subscribe(b),d=b}).then(l);return h.cancel=function(){r.unsubscribe(d)},h},e(function(d,h,b){r.reason||(r.reason=new La(d,h,b),t(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=r=>{e.abort(r)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new Vx(function(l){e=l}),cancel:e}}};function oI(n){return function(t){return n.apply(null,t)}}function sI(n){return $e.isObject(n)&&n.isAxiosError===!0}const Cf={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(Cf).forEach(([n,e])=>{Cf[e]=n});function Jw(n){const e=new Ws(n),t=gw(Ws.prototype.request,e);return $e.extend(t,Ws.prototype,e,{allOwnKeys:!0}),$e.extend(t,e,null,{allOwnKeys:!0}),t.create=function(l){return Jw(js(n,l))},t}const Bn=Jw(El);Bn.Axios=Ws,Bn.CanceledError=La,Bn.CancelToken=iI,Bn.isCancel=Nw,Bn.VERSION=Qw,Bn.toFormData=au,Bn.AxiosError=Ct,Bn.Cancel=Bn.CanceledError,Bn.all=function(e){return Promise.all(e)},Bn.spread=oI,Bn.isAxiosError=sI,Bn.mergeConfig=js,Bn.AxiosHeaders=ei,Bn.formToJSON=n=>Ow($e.isHTMLForm(n)?new FormData(n):n),Bn.getAdapter=Yw.getAdapter,Bn.HttpStatusCode=Cf,Bn.default=Bn;const{Axios:Rj,AxiosError:Mj,CanceledError:Lj,isCancel:Oj,CancelToken:Ij,VERSION:Nj,all:Dj,Cancel:Fj,isAxiosError:Pj,spread:Bj,toFormData:jj,AxiosHeaders:Wj,HttpStatusCode:zj,formToJSON:Hj,getAdapter:Uj,mergeConfig:qj}=Bn,aI={components:{TopBar:vT,OutputDialog:fT},data(){const n="bucketExplorerRefreshInterval",e=Number.parseInt(localStorage.getItem(n))||60;return{title:"Bucket Explorer",search:"",root:"",mode:"bucket",buckets:[],volumes:[],uploadPathDialog:!1,optionsDialog:!1,refreshInterval:e,refreshIntervalKey:n,updater:null,updating:!1,path:"",file:null,files:[],showDialog:!1,dialogName:"",dialogContent:"",dialogFilename:"",sortBy:[{key:"modified",order:"desc"}],headers:[{title:"Name",value:"name",sortable:!0,nowrap:!0},{title:"Size",value:"size",sortable:!0},{title:"ModifiedDate",value:"modified",sortable:!0},{title:"Action",value:"action",align:"end",nowrap:!0}],menus:[{label:"File",items:[{label:"Options",icon:"mdi-cog",command:()=>{this.optionsDialog=!0}}]}]}},computed:{folderTotal(){return Gu(this.files.reduce((n,e)=>n+(e.size?e.size:0),0))},breadcrumbPath(){const n=this.path.split("/");return n.map((e,t)=>({name:e,path:n.slice(0,t+1).join("/")+"/"}))}},watch:{file:async function(){this.file!==null&&(this.uploadFilePath=`${this.path}${this.file.name}`,this.uploadPathDialog=!0)}},created(){var n;if(xs.get("/openc3-api/storage/buckets").then(e=>{this.buckets=e.data}),xs.get("/openc3-api/storage/volumes").then(e=>{this.volumes=e.data}),(n=this.$route.params.path)!=null&&n.length){this.updating=!0;let e=this.$route.params.path[0].split("/");e[0]===""?(this.mode="volume",this.root=`/${e[1]}`,this.path=e.slice(2).join("/")):(this.mode="bucket",this.root=e[0],this.path=e.slice(1).join("/")),this.updateFiles()}this.changeUpdater()},beforeUnmount(){this.clearUpdater()},methods:{isText(n){if(["Rakefile","Dockerfile"].includes(n))return!0;let e=n.split(".").pop();return["txt","md","rb","py","pyi","cfg","html","js","json","info","vue","sh","bat","csv"].includes(e)},gotoPath(n){this.updating||(this.updating=!0,this.path=n,this.update())},update(){this.updating=!0,this.$router.push({name:"Bucket Explorer",params:{path:`${this.root}/${this.path}`}}),this.updateFiles()},saveRefreshInterval(){this.refreshInterval?localStorage.setItem(this.refreshIntervalKey,this.refreshInterval):this.refreshInterval=Number.parseInt(localStorage.getItem(this.refreshIntervalKey))||60,this.optionsDialog=!1,this.changeUpdater()},cancelChangeRefreshInterval(){this.refreshInterval=Number.parseInt(localStorage.getItem(this.refreshIntervalKey))||60,this.optionsDialog=!1},changeUpdater(){this.clearUpdater(),this.updater=setInterval(()=>{this.root&&this.updateFiles()},this.refreshInterval*1e3)},clearUpdater(){this.updater!=null&&(clearInterval(this.updater),this.updater=null)},selectBucket(n){this.updating||(this.updating=!0,this.mode="bucket",this.root=n,this.path="",this.update())},selectVolume(n){this.updating||(this.updating=!0,this.mode="volume",this.root=n,this.path="",this.update())},backArrow(){if(this.path!==""&&!this.updating){this.updating=!0;let n=this.path.split("/");this.path=n.slice(0,n.length-2).join("/"),n.length>2&&(this.path+="/"),this.update()}},fileClick(n,{item:e}){e.icon==="mdi-folder"&&(this.updating||(this.updating=!0,this.root===""?this.root=e.name:this.path+=`${e.name}/`,this.update()))},viewFile(n){let e=this.root.toUpperCase();this.mode==="volume"&&(e=e.slice(1)),xs.get(`/openc3-api/storage/download_file/${encodeURIComponent(this.path)}${n}?${this.mode}=OPENC3_${e}_${this.mode.toUpperCase()}`).then(t=>{this.dialogName=n,this.dialogFilename=n,this.dialogContent=window.atob(t.data.contents),this.showDialog=!0})},downloadFile(n){let e=this.root.toUpperCase(),t="download";this.mode==="volume"&&(t="download_file",e=e.slice(1)),xs.get(`/openc3-api/storage/${t}/${encodeURIComponent(this.path)}${n}?${this.mode}=OPENC3_${e}_${this.mode.toUpperCase()}`).then(r=>{let l=null;if(this.mode==="bucket")l=r.data.url;else{const h=window.atob(r.data.contents),b=new Uint8Array(h.length);for(let g=0;g<h.length;++g)b[g]=h.charCodeAt(g);const p=new Blob([b]);l=URL.createObjectURL(p)}const d=document.createElement("a");d.href=l,d.setAttribute("download",n),d.click()}).catch(r=>{this.$notify.caution({title:`Unable to download file ${this.path}${n} from bucket ${this.root}`})})},async uploadFile(){this.uploadPathDialog=!1,this.uploadFilePath.startsWith("/")&&(this.uploadFilePath=this.uploadFilePath.slice(1));const{data:n}=await xs.get(`/openc3-api/storage/upload/${encodeURIComponent(this.uploadFilePath)}?bucket=OPENC3_${this.root.toUpperCase()}_BUCKET`);await Bn({...n,data:this.file}),this.file=null;let e=this.uploadFilePath.split("/");e.length>1?this.path=e.slice(0,-1).join("/")+"/":this.path="",this.updateFiles()},cancelFileUpload(){this.file=null,this.uploadPathDialog=!1},deleteFile(n){let e=this.root.toUpperCase();this.mode==="volume"&&(e=e.slice(1)),this.$dialog.confirm(`Are you sure you want to delete: ${n}`,{okText:"Delete",cancelText:"Cancel"}).then(t=>xs.delete(`/openc3-api/storage/delete/${encodeURIComponent(this.path)}${n}?${this.mode}=OPENC3_${e}_${this.mode.toUpperCase()}`)).then(t=>{this.updateFiles()}).catch(t=>{})},updateFiles(){let n=this.root.toUpperCase();this.mode==="volume"&&(n=n.slice(1)),xs.get(`/openc3-api/storage/files/OPENC3_${n}_${this.mode.toUpperCase()}/${this.path}`).then(e=>{this.files=e.data[0].map(t=>({name:t,icon:"mdi-folder"})),this.files=this.files.concat(e.data[1].map(t=>({name:t.name,icon:"mdi-file",size:t.size,modified:t.modified}))),this.updating=!1}).catch(({response:e})=>{var t;this.files=[],(t=e.data)!=null&&t.message?this.$notify.caution({title:e.data.message}):this.$notify.caution({title:e.message}),this.updating=!1})},formatBytesToString:Gu}},lI={style:{"padding-left":"5px","padding-top":"5px"}},cI={key:0,style:{"padding-left":"5px"}},uI={class:".text-body-1 ma-2 font-size","data-test":"file-path"},hI=["onClick"],dI={class:"ma-2 font-size"},fI={key:0,class:"ma-2",style:{display:"flex"}},pI={class:"mx-1"},gI={class:"pa-3"};function mI(n,e,t,r,l,d){const h=Ot("top-bar"),b=Ot("v-icon"),p=Ot("v-avatar"),g=Ot("v-chip"),o=Ot("v-spacer"),c=Ot("v-text-field"),f=Ot("v-card-title"),u=Ot("v-btn"),i=Ot("v-file-input"),a=Ot("v-row"),m=Ot("v-data-table"),w=Ot("v-card"),x=Ot("v-toolbar"),M=Ot("v-card-text"),$=Ot("v-dialog"),S=Ot("v-card-actions"),k=Ot("output-dialog");return zt(),Vr("div",null,[et(h,{title:l.title,menus:l.menus},null,8,["title","menus"]),et(w,{width:"100%"},{default:Je(()=>[cr("div",lI,[e[10]||(e[10]=cr("span",{class:"ma-2 font-size"},"Buckets:",-1)),(zt(!0),Vr(So,null,Ko(l.buckets,(T,D)=>(zt(),Vn(g,{key:D,variant:"elevated",color:"primary",class:"ma-2",onClick:vs(L=>d.selectBucket(T),["stop"])},{default:Je(()=>[et(p,{start:""},{default:Je(()=>[et(b,null,{default:Je(()=>[...e[9]||(e[9]=[An("mdi-bucket",-1)])]),_:1})]),_:1}),An(" "+Ir(T),1)]),_:2},1032,["onClick"]))),128))]),l.volumes.length!==0?(zt(),Vr("div",cI,[e[12]||(e[12]=cr("span",{class:"ma-2 font-size"},"Volumes:",-1)),(zt(!0),Vr(So,null,Ko(l.volumes,(T,D)=>(zt(),Vn(g,{key:D,variant:"elevated",color:"primary",class:"ma-2",onClick:vs(L=>d.selectVolume(T),["stop"])},{default:Je(()=>[et(p,{start:""},{default:Je(()=>[et(b,null,{default:Je(()=>[...e[11]||(e[11]=[An("mdi-folder",-1)])]),_:1})]),_:1}),An(" "+Ir(T),1)]),_:2},1032,["onClick"]))),128))])):oo("",!0),et(f,{class:"pt-0 d-flex align-center justify-content-space-between"},{default:Je(()=>[An(Ir(l.root)+" Files ",1),et(o),et(c,{modelValue:l.search,"onUpdate:modelValue":e[0]||(e[0]=T=>l.search=T),label:"Search","prepend-inner-icon":"mdi-magnify",clearable:"",variant:"outlined",density:"compact","single-line":"","hide-details":"",class:"search","data-test":"search-input"},null,8,["modelValue"])]),_:1}),et(m,{"sort-by":l.sortBy,"onUpdate:sortBy":e[2]||(e[2]=T=>l.sortBy=T),headers:l.headers,items:l.files,search:l.search,"items-per-page":-1,"items-per-page-options":[10,20,50,100,-1],"multi-sort":"",density:"compact",hover:"","onClick:row":vs(d.fileClick,["stop"])},{top:Je(()=>[et(a,{class:"ma-0",style:{"background-color":"var(--color-background-surface-header)"}},{default:Je(()=>[et(u,{icon:"mdi-chevron-left-box-outline",variant:"text",density:"compact",class:"ml-3 mt-1","data-test":"be-nav-back","aria-label":"Navigate Back",onClick:vs(d.backArrow,["stop"])},null,8,["onClick"]),cr("div",uI,[(zt(!0),Vr(So,null,Ko(d.breadcrumbPath,(T,D)=>(zt(),Vr("span",{key:D},[e[13]||(e[13]=An(" / ",-1)),cr("a",{style:{cursor:"pointer"},onClick:vs(L=>d.gotoPath(T.path),["prevent"])},Ir(T.name),9,hI)]))),128))]),et(o),cr("div",dI,[An(" Folder Size: "+Ir(d.folderTotal)+" ",1),e[14]||(e[14]=cr("span",{class:"small-font-size"},"(not recursive)",-1))]),et(o),l.mode==="bucket"?(zt(),Vr("div",fI,[e[15]||(e[15]=cr("span",{class:"font-size"},"Upload File",-1)),et(i,{modelValue:l.file,"onUpdate:modelValue":e[1]||(e[1]=T=>l.file=T),"hide-input":"","hide-details":"",class:"mr-1 file-input","prepend-icon":"mdi-upload","data-test":"upload-file"},null,8,["modelValue"])])):oo("",!0)]),_:1})]),"item.name":Je(({item:T})=>[et(b,{class:"mr-2"},{default:Je(()=>[An(Ir(T.icon),1)]),_:2},1024),An(" "+Ir(T.name),1)]),"item.size":Je(({item:T})=>[An(Ir(T.size?d.formatBytesToString(T.size):""),1)]),"item.action":Je(({item:T})=>[T.icon==="mdi-file"&&d.isText(T.name)?(zt(),Vn(u,{key:0,icon:"mdi-eye",variant:"text",density:"compact",class:"mr-3","data-test":"view-file","aria-label":"View File",onClick:D=>d.viewFile(T.name)},null,8,["onClick"])):oo("",!0),T.icon==="mdi-file"?(zt(),Vn(u,{key:1,icon:"mdi-download-box",variant:"text",density:"compact",class:"mr-3","data-test":"download-file","aria-label":"Download File",onClick:D=>d.downloadFile(T.name)},null,8,["onClick"])):oo("",!0),T.icon==="mdi-file"?(zt(),Vn(u,{key:2,icon:"mdi-delete",variant:"text",density:"compact","data-test":"delete-file","aria-label":"Delete File",onClick:D=>d.deleteFile(T.name)},null,8,["onClick"])):oo("",!0)]),_:1},8,["sort-by","headers","items","search","onClick:row"])]),_:1}),et($,{modelValue:l.uploadPathDialog,"onUpdate:modelValue":e[4]||(e[4]=T=>l.uploadPathDialog=T),"max-width":"600",persistent:"",onKeydown:Zu(d.cancelFileUpload,["esc"])},{default:Je(()=>[et(w,null,{default:Je(()=>[et(x,{height:"24"},{default:Je(()=>[et(o),e[16]||(e[16]=cr("span",null," Upload Path ",-1)),et(o)]),_:1}),et(M,null,{default:Je(()=>[cr("div",pI,[et(a,{class:"my-2"},{default:Je(()=>[...e[17]||(e[17]=[cr("span",null," This file path can be modified. New directories will be automatically created. ",-1)])]),_:1}),et(a,null,{default:Je(()=>[et(c,{modelValue:n.uploadFilePath,"onUpdate:modelValue":e[3]||(e[3]=T=>n.uploadFilePath=T),"hide-details":"",label:"File Path","data-test":"upload-file-path"},null,8,["modelValue"])]),_:1}),et(a,{class:"mt-6"},{default:Je(()=>[et(o),et(u,{variant:"outlined",class:"mx-2","data-test":"upload-file-cancel-btn",onClick:d.cancelFileUpload},{default:Je(()=>[...e[18]||(e[18]=[An(" Cancel ",-1)])]),_:1},8,["onClick"]),et(u,{class:"mx-2",color:"primary",type:"submit","data-test":"upload-file-submit-btn",onClick:vs(d.uploadFile,["prevent"])},{default:Je(()=>[...e[19]||(e[19]=[An(" Upload ",-1)])]),_:1},8,["onClick"])]),_:1})])]),_:1})]),_:1})]),_:1},8,["modelValue","onKeydown"]),et($,{modelValue:l.optionsDialog,"onUpdate:modelValue":e[6]||(e[6]=T=>l.optionsDialog=T),"max-width":"300",persistent:"",onKeydown:Zu(d.cancelChangeRefreshInterval,["esc"])},{default:Je(()=>[et(w,null,{default:Je(()=>[et(x,{height:"24"},{default:Je(()=>[et(o),e[20]||(e[20]=cr("span",null,"Options",-1)),et(o)]),_:1}),et(M,null,{default:Je(()=>[cr("div",gI,[et(c,{modelValue:l.refreshInterval,"onUpdate:modelValue":e[5]||(e[5]=T=>l.refreshInterval=T),min:"1",max:"3600",step:"100",type:"number",label:"Refresh Interval (s)","data-test":"refresh-interval"},null,8,["modelValue"])])]),_:1}),et(S,{class:"px-2"},{default:Je(()=>[et(u,{"data-test":"options-close-btn",variant:"outlined",onClick:d.saveRefreshInterval},{default:Je(()=>[...e[21]||(e[21]=[An(" Save ",-1)])]),_:1},8,["onClick"]),et(u,{"data-test":"options-close-btn",variant:"outlined",onClick:d.cancelChangeRefreshInterval},{default:Je(()=>[...e[22]||(e[22]=[An(" Cancel ",-1)])]),_:1},8,["onClick"])]),_:1})]),_:1})]),_:1},8,["modelValue","onKeydown"]),l.showDialog?(zt(),Vn(k,{key:0,modelValue:l.showDialog,"onUpdate:modelValue":e[7]||(e[7]=T=>l.showDialog=T),type:"File",content:l.dialogContent,name:l.dialogName,filename:l.dialogFilename,onSubmit:e[8]||(e[8]=T=>l.showDialog=!1)},null,8,["modelValue","content","name","filename"])):oo("",!0)])}Pi("b",Object.freeze(Object.defineProperty({__proto__:null,default:bp(aI,[["render",mI],["__scopeId","data-v-e31865ed"]])},Symbol.toStringTag,{value:"Module"})))}}});
|